From: Vito Macchia Date: Fri, 13 Nov 2020 11:00:52 +0000 (+0100) Subject: Built motion from commit f651e4b0a7312c0adceb5e57d6684a801a3aaf0d. Version 3.0.0... X-Git-Url: http://repos.xcallymotion.com/base/%22angular-material.themes.css//%22javascript:void%28%27%7BtitleJs%7D%27%29/%22%22%29%20%27?a=commitdiff_plain;h=c315fed6ac4326fd402024d342ce01bf94ba493f;p=motion-next.git Built motion from commit f651e4b0a7312c0adceb5e57d6684a801a3aaf0d. Version 3.0.0-alpha --- diff --git a/apidoc/api_project.js b/apidoc/api_project.js index 33c0f44..dcb6b3d 100644 --- a/apidoc/api_project.js +++ b/apidoc/api_project.js @@ -17,7 +17,7 @@ define({ "apidoc": "0.3.0", "generator": { "name": "apidoc", - "time": "2020-11-12T18:55:37.946Z", + "time": "2020-11-13T10:57:16.132Z", "url": "https://apidocjs.com", "version": "0.25.0" } diff --git a/apidoc/api_project.json b/apidoc/api_project.json index 1b38e80..50b70b2 100644 --- a/apidoc/api_project.json +++ b/apidoc/api_project.json @@ -17,7 +17,7 @@ "apidoc": "0.3.0", "generator": { "name": "apidoc", - "time": "2020-11-12T18:55:37.946Z", + "time": "2020-11-13T10:57:16.132Z", "url": "https://apidocjs.com", "version": "0.25.0" } diff --git a/package-lock.json b/package-lock.json index 45159e5..eeb8a8f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5980,9 +5980,9 @@ } }, "socket.io-adapter": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/socket.io-adapter/-/socket.io-adapter-1.1.2.tgz", - "integrity": "sha512-WzZRUj1kUjrTIrUKpZLEzFZ1OLj5FwLlAFQs9kuZJzJi5DKdU7FsWc36SNmA8iDOtwBQyT8FkrriRM8vXLYz8g==" + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/socket.io-adapter/-/socket.io-adapter-2.0.3.tgz", + "integrity": "sha512-2wo4EXgxOGSFueqvHAdnmi5JLZzWqMArjuP4nqC26AtLh5PoCPsaRbRdah2xhcwTAMooZfjYiNVNkkmmSMaxOQ==" }, "socket.io-emitter": { "version": "3.1.1", @@ -6061,14 +6061,14 @@ } }, "socket.io-redis": { - "version": "5.4.0", - "resolved": "https://registry.npmjs.org/socket.io-redis/-/socket.io-redis-5.4.0.tgz", - "integrity": "sha512-yCQm/Sywd3d08WXUfZRxt6O+JV2vWoPgWK6GVjiM0GkBtq5cpLOk8oILRPKbzTv1VEtSYmK41q0xzcgDinMbmQ==", + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/socket.io-redis/-/socket.io-redis-6.0.0.tgz", + "integrity": "sha512-f657jTlMMYTtlgcfjPkSUmC7kMlXXJQtyMsWC7fHJ5zzax0xPLf5sHiM7MLFe2m3VBIBcdZtgHvEweMuHAflAw==", "requires": { "debug": "~4.1.0", "notepack.io": "~2.2.0", "redis": "^3.0.0", - "socket.io-adapter": "~1.1.0", + "socket.io-adapter": "~2.0.0", "uid2": "0.0.3" }, "dependencies": { diff --git a/package.json b/package.json index d5f9ee9..8fc9179 100644 --- a/package.json +++ b/package.json @@ -97,7 +97,7 @@ "simple-git": "^2.21.0", "socket.io": "^3.0.1", "socket.io-emitter": "^3.1.1", - "socket.io-redis": "^5.4.0", + "socket.io-redis": "^6.0.0", "socketio-jwt": "^4.6.2", "sox": "^0.1.0", "squel": "^5.13.0", @@ -117,10 +117,10 @@ "zip-dir": "^1.0.2" }, "xcally": { - "shortHash": "bfc7a72", + "shortHash": "f651e4b", "branch": "develop", "tag": "", - "committedOn": "2020-11-12T18:54:41.000Z", - "buildDate": "2020-11-12T18:58:10.302Z" + "committedOn": "2020-11-13T10:54:16.000Z", + "buildDate": "2020-11-13T10:59:48.424Z" } } diff --git a/public/769-8e6d4f4f6390a0a4c67f.js b/public/769-8e6d4f4f6390a0a4c67f.js index 2a8c946..d939e99 100644 --- a/public/769-8e6d4f4f6390a0a4c67f.js +++ b/public/769-8e6d4f4f6390a0a4c67f.js @@ -1,2 +1,2 @@ /*! For license information please see 769-8e6d4f4f6390a0a4c67f.js.LICENSE.txt */ -var a2_0x164d=[' \n','',"llength|10 load lrange|10 lrepeat|10 lreplace|10 lreverse|10 lsearch|10 lset|10 lsort|10 ","labelRotation","bdi","_lastX","DDDD","peerconnection:setlocaldescriptionfailed","dddd [i] LT","gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ","onevent","removeListener"," mesen","ram","uploadDate","_closeDuration","rgb(92, 0, 0)","eaGet eaCopy eaCreate eaCreateStandardRoute ","unregisterFn","tydzień","app/directives/label-item/label-item.html","millisecond","maxptime","message enum service","SYSRES_CONST_SEARCHES_EDOC_CONTENT ","രാവിലെ","viensas secunds","Bhi_Ina_Inu_Mab_Ink_Inh_Kho_Igc_Iny_Imp_Lwe_Igo","Opera Mini/[VER]","model.onePanel will be removed from model on next rlease, please use root config e.g. $mdDateRangePicker.show({onePanel}) instead","drop-while while intern condp case reduced cycle split-at split-with repeat replicate ","ugc_sortorder_ForModeration ugc_list_Published ugc_list_VotedOn ","%d Minuten","mapValues","massage","f4a460","SYSRES_CONST_POSITIVE_PICK_VALUE ","gl_TextureMatrixTranspose gl_Vertex gl_VertexID gl_ViewportIndex gl_WorkGroupID gl_WorkGroupSize gl_in gl_out ","_via_transport","plotAddHist plotAddHistF plotAddHistP plotAddPolar plotAddScatter plotAddShape plotAddTextbox plotAddTS plotAddXY plotArea ","SYSREQ_USERS_USER_CERTIFICATE_STATE ","\\b[a-zA-Z][a-zA-Z0-9_-]*","UrlRouter","fontSize","environ vocabularies notations constructors definitions ",")\\b","подключитьрасширениеработыскриптографией подключитьрасширениеработысфайлами подробноепредставлениеошибки ","addGroup","-panel","\\b(\\.\\d+|\\d+\\.\\d+)\\b","СоздатьПапку ","im8bGrayscale ","minibus","reset-meta! commute get-validator alter ref-set ref-history-count ref-min-history ref-max-history ensure sync io! ","dnevoma","PROFILING_SETTINGS_COMMON_SETTINGS_CODE_VALUE ","uib/template/progressbar/progress.html","gridHeight","getTokens","#FF3399",'{{::getText(\'previous\')}}\n',"އަހަރު %d","incrementHours","Windows 3.11","instance_deactivate_layer camera_create camera_create_view ","ain","([*]|[a-zA-Z_$][a-zA-Z0-9_$]*)","split return print reverse grep","sdpOffer","_$mdConstant","typeaheadSelectOnExact","setDisableHeaderCheck","setSelectValueText","_receiveReplaces","SPACE","{{message}}',"isWebsiteHasMicrophonePermissions","addEvent","beforeFooter","mínútur","wdtGroupCollection ",'
\n',"\\bC-22Q|T7-QC|T-17B|T-17P\\b","subdCleanTopology subdCollapse subdDuplicateAndConnect subdEditUV "," minutit","SUBTASK_BLOCK_WAIT_FOR_TASK_COMPLETE_PROPERTY ","січень_лютий_березень_квітень_травень_червень_липень_серпень_вересень_жовтень_листопад_грудень","REFERENCE_LINK_KIND ","extmap:%d","#c6ff00",'localization-map="config.localizationMap || model.localizationMap" ',"icTaskFormEventHandler ","allCurators allCutLayers allDead allDeadMen allDisplays allGroups allMapMarkers allMines ","(greater|less) than( or equal)?|(starts?|ends|begins?) with|",'">',"setAirplaneThrottle setAirportSide setAmmo setAmmoCargo setAmmoOnPylon setAnimSpeedCoef ","en-sg","Unhandled error.","post_office","muted","iPod","exclamation","succeeded","defaultFontSet","एक घण्टा","submitForm","dragon_face","badcfg","pagh_wa’_cha’_wej_loS_vagh_jav_Soch_chorgh_Hut","sort uc defined srand accept package seekdir getprotobyname semop our rename seek if q|0 ","#0091ea","%d منٽ"," (NodeOS) AppleWebKit/",'"domain"',"Argument '{0}' is {1}","decreasePageOffset","backdrop click","powershell","регламентныезадания сериализаторxdto справочники средствагеопозиционирования средствакриптографии средствамультимедиа ","camera_set_end_script camera_set_view_pos camera_set_view_size ","installPropertyInterceptors","maxDate","rice","Sul_Lun_Meu_Mer_Yao_Gwe_Sad"," symbolp symmdifference symmetricp system take_channel take_inference tan","isRelative","pingTimeoutTimer","true false nil","nedelja_ponedeljak_utorak_sreda_četvrtak_petak_subota","lineTension","textareaView","requestError","[Ọ̀la ni] LT","versions","mdPanel: The addClass method is in the process of being deprecated. ","right self Self set static struct subscript super switch throw throws true ","endIndex","round sign sin sqrt tan trunc object_length object_names object_pairs object_inner_pairs object_values ","trait true try type typeof unsafe unsized use virtual where while yield","renderTokens","selinux_policyversion serialnumber sp_ sshdsakey sshecdsakey sshrsakey swapencrypted swapfree swapsize timezone type uniqueid uptime ",'',"SYSRES_CONST_CODE_REQUISITE_DESCRIPTION ",".md-calendar-scroll-mask","NS_RETURNS_INNER_POINTER NS_INLINE NS_AVAILABLE NS_DEPRECATED ","insertTab","Float64Array","formPage","Dolfin/[VER]"," cdf_rank_sum cdf_rayleigh cdf_signed_rank cdf_student_t cdf_weibull cdisplay","spotifyEmbed","Disconnect-CisServer Disconnect-HCXServer Disconnect-NsxLogicalSwitch Disconnect-NsxServer Disconnect-NsxtServer Disconnect-SrmServer ","Buffer","f95","new return throw await else","subContext","translateZ(0)","px,","MⓂMḾṀṂⱮƜ","wiHigh ","$viewVaue","СпрТблСтрКол ",'" to ',"isConnected",'"ip"',"","material.components.card","%s પહેલા","assert failure","moveDownPage",'md-mode="{{::ctrl.mode}}" ',"OCTET_LENGTH GET_BIT GET_BYTE SET_BIT SET_BYTE ","te hēkona ruarua","[\\*&\\s]+)+","MIN_INTER_TONE_GAP","screen","ⴰⵙⴳⴰⵙ","\\.md-","arrayEquals","Precondition Failure","(\\$|\\b)","основноепредставлениепланаобмена основноепредставлениесправочника основноепредставлениесчета перемещениеграницыприпроведении ","[minulú stredu o] LT","isByUserSettings ","product profile/calls profile/cpu put-route quasiquote quote raise range read read-str ","uri","remove3DENLayer removeAction removeAll3DENEventHandlers removeAllActions removeAllAssignedItems ","Индекс ","IHistoryDescription ","SYSRES_CONST_JOB_KIND_CONTROL_JOB ","deActivateKey debriefingText debugFSM debugLog deg delete3DENEntities deleteAt deleteCenter ","=?mdpMinTime","opaque","%d jierren"," / ","complete","calendarFormat","cleanupInteraction","(?:\\W|$)","sort start subst time title tree type ver verify vol ","afterSetDimensions","type union unit unsafe until uses using var virtual raises volatile where while with write xor yield await mapped deprecated stdcall cdecl pascal ","domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato","einer Minute","HH:mm:ss,SSSS","box","ఆది_సోమ_మంగళ_బుధ_గురు_శుక్ర_శని","sizeX","@?mdMenuContainerClass","ctUnknown ","SET_NEXT_CODE_VALUE_RULE_ID ","md-content","Tried to set ","getRightValue","SYSRES_CONST_FILTER_TYPE_USER_NAME ","Mac OS X","شوبات","indexOf","onLoaderSuccess","true false yes no null","instant","flow::","buffer_base64_decode_ext buffer_sizeof buffer_get_address ",".*?","sortedIndexOf","deviceId","ամիս",'opaque="',"mdTheme","_useUTC","IWorkTreeJobNode ","end repeat URL in try into switch to words https token binfile each tenth as ticks tick ","aHrefSanitizationWhitelist","%d ثانیه","008080","چند سیکنڈ","getElementsByTagName","may_not_duplicate affects_liveness does_not_affect_liveness ","steam_create_leaderboard steam_upload_score steam_upload_score_ext ","SYSRES_CONST_IS_PUBLIC_ROLE_REQUISITE_CODE ","originalCanvasStyleHeight","","postProcess","native","oRequestAnimationFrame","aria-disabled","recovery_timer","strtof strtofcplx strtriml strtrimr strtrunc strtruncl strtruncpad strtruncr submat subscat substute subvec sumc sumr ",'">
',"dialog ","getConstraintWidth","minSizeX","$mdGesture","получитьминимальнуюдлинупаролейпользователей получитьнавигационнуюссылку получитьнавигационнуюссылкуинформационнойбазы ","isAndroid","readAsDataURL","-webkit-sticky","params_up return return_value run_children soap_definetag ","ngKeydown","#1e88e5","received binary message:\n\n","%d ปี","An t-Ògmhios","IStringRequisiteDescription ","%d timer","[object FileConstructor]","PRIVILEGE_DEVELOPMENT_IMPORT ","global if import importall let local macro module quote return true try using while ","facebook_request_publish_permissions gamepad_is_supported ","ev_game_end ev_room_start ev_room_end ev_no_more_lives ","CONFIRMED","connecting","%s ішінде","_monthsRegex","SYSRES_CONST_REQUISITE_SECTION_TABLE15 ","tickMarkLength","md-bottom-sheet","_sendInitialRequest","The following parameter values are not valid for state '","u7533","SHORTMONTH","SYSRES_CONST_CONST_POSITIVE_VALUE ","ngResource:\n","ds_queue_head ds_queue_tail ds_queue_write ds_queue_read ","d2b48c","convertUnit copyArray copyFlexor copyKey copySkinWeights cos cpButton cpCache ","endsParent","Content-Type: application/sdp\r\n","cls","chartBar","පෙර වරු","black_square","#CC9933","getSelection","ASCII (character|number)|localized string|","\\n_{4,}$","хвіліна","_positions","emChangeStandardRoute ","\n","labelView","toml","lineArc","md-option","[امروز ساعت] LT","New-ModuleManifest New-PSDrive New-PSSession New-PSSessionConfigurationFile New-PSSessionOption New-PSTransportOption ","(\\.\\.\\.)","mw-question-priority-list-builder.html","getRight","bdb76b","ರಾತ್ರಿ","48px","[:;]","Update-Script Update-ScriptFileInfo Update-Tools Update-VsanHclDatabase ValidateUpdate-ConfigurationData Wait-Debugger Wait-NsxControllerJob Wait-NsxGenericJob Wait-NsxJob ","wavy_dash","sip_uri","isDateComplete","$extractResponseForPriorityQuestion","chartDatasetOverride","tilemap_get_cell_y_at_pixel tilemap_clear draw_tilemap draw_tile ","% - (","phy_joint_max_force phy_debug_render_aabb ",'but "',"STATUS_CANCELED","globally go goto grant grants greatest group group_concat group_id grouping grouping_id groups ","ISelectDialog ","Diluain","radiusLength","_absolute","1 นาที","_md-opaque-leave","getRandomTestNetIP"," өдрийн","IFolder ","randomizationFactor","steam_ugc_query_set_allow_cached_response steam_ugc_send_query ","css`","add","$mdTable.selected","_onOpen","draw_set_halign draw_set_valign draw_text draw_text_ext string_width ","draggedRect","transitionInClass","md-auto-hide","show","CreateConnection ","virtual","maxWait","clbUnchecked clbChecked clbGrayed ","dddd [بوقت] LT","ИДТипСпр ","дан","incrementSeconds","do while select delete by update from","indentPartial","%d วัน","секунда_секунди_секунд","dažām sekundēm","blue brightness color green hue lerpColor red saturation modelX modelY modelZ screenX screenY ","#448aff","So_Ma_Di_Wo_Do_Vr_Sa","ROW_NUMBER RANK DENSE_RANK PERCENT_RANK CUME_DIST NTILE LAG LEAD FIRST_VALUE LAST_VALUE NTH_VALUE ","$mdTable.progress","ui-view: ","sausis_vasaris_kovas_balandis_gegužė_birželis_liepa_rugpjūtis_rugsėjis_spalis_lapkritis_gruodis","smoking","remote_tag","duration_to_str millis str_to_millis millis_to_str millis_to_utc millis_to_zone_name now_millis now_str ","أوت","YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ","$$ngMessageNode","#\\s","libURLFollowHttpRedirects libURLftpUpload libURLftpUploadFile libURLresetAll libUrlSetAuthCallback libURLSetDriver ","de-ch",'.html" ','
\n\t
\n\t\t
\n\t
\n\t\n\t\t\n\t\t\n\t\n\t\n\t\t\n\t\n
\n',"addr and as asm bind block break case cast const continue converter ","insertDTMF","ugc_query_RankedByVote ugc_query_RankedByPublicationDate ","instanceReady","emLock ","encodeAsBinary","onExit","__esModule","colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr","page_with_curl","enger Stonn","http error","-moz-","GaborFilter GaborMatrix GaborWavelet GainMargins GainPhaseMargins GalaxyData GalleryView Gamma GammaDistribution GammaRegularized GapPenalty GARCHProcess GatedRecurrentLayer Gather GatherBy GaugeFaceElementFunction GaugeFaceStyle GaugeFrameElementFunction GaugeFrameSize GaugeFrameStyle GaugeLabels GaugeMarkers GaugeStyle GaussianFilter GaussianIntegers GaussianMatrix GaussianOrthogonalMatrixDistribution GaussianSymplecticMatrixDistribution GaussianUnitaryMatrixDistribution GaussianWindow GCD GegenbauerC General GeneralizedLinearModelFit GenerateAsymmetricKeyPair GenerateConditions GeneratedCell GeneratedDocumentBinding GenerateDerivedKey GenerateDigitalSignature GenerateDocument GeneratedParameters GeneratedQuantityMagnitudes GenerateHTTPResponse GenerateSecuredAuthenticationKey GenerateSymmetricKey GeneratingFunction GeneratorDescription GeneratorHistoryLength GeneratorOutputType Generic GenericCylindricalDecomposition GenomeData GenomeLookup GeoAntipode GeoArea GeoArraySize GeoBackground GeoBoundingBox GeoBounds GeoBoundsRegion GeoBubbleChart GeoCenter GeoCircle GeodesicClosing GeodesicDilation GeodesicErosion GeodesicOpening GeoDestination GeodesyData GeoDirection GeoDisk GeoDisplacement GeoDistance GeoDistanceList GeoElevationData GeoEntities GeoGraphics GeogravityModelData GeoGridDirectionDifference GeoGridLines GeoGridLinesStyle GeoGridPosition GeoGridRange GeoGridRangePadding GeoGridUnitArea GeoGridUnitDistance GeoGridVector GeoGroup GeoHemisphere GeoHemisphereBoundary GeoHistogram GeoIdentify GeoImage GeoLabels GeoLength GeoListPlot GeoLocation GeologicalPeriodData GeomagneticModelData GeoMarker GeometricAssertion GeometricBrownianMotionProcess GeometricDistribution GeometricMean GeometricMeanFilter GeometricScene GeometricTransformation GeometricTransformation3DBox GeometricTransformation3DBoxOptions GeometricTransformationBox GeometricTransformationBoxOptions GeoModel GeoNearest GeoPath GeoPosition GeoPositionENU GeoPositionXYZ GeoProjection GeoProjectionData GeoRange GeoRangePadding GeoRegionValuePlot GeoResolution GeoScaleBar GeoServer GeoSmoothHistogram GeoStreamPlot GeoStyling GeoStylingImageFunction GeoVariant GeoVector GeoVectorENU GeoVectorPlot GeoVectorXYZ GeoVisibleRegion GeoVisibleRegionBoundary GeoWithinQ GeoZoomLevel GestureHandler GestureHandlerTag Get GetBoundingBoxSizePacket GetContext GetEnvironment GetFileName GetFrontEndOptionsDataPacket GetLinebreakInformationPacket GetMenusPacket GetPageBreakInformationPacket Glaisher GlobalClusteringCoefficient GlobalPreferences GlobalSession Glow GoldenAngle GoldenRatio GompertzMakehamDistribution GoodmanKruskalGamma GoodmanKruskalGammaTest Goto Grad Gradient GradientFilter GradientOrientationFilter GrammarApply GrammarRules GrammarToken Graph Graph3D GraphAssortativity GraphAutomorphismGroup GraphCenter GraphComplement GraphData GraphDensity GraphDiameter GraphDifference GraphDisjointUnion GraphDistance GraphDistanceMatrix GraphElementData GraphEmbedding GraphHighlight GraphHighlightStyle GraphHub Graphics Graphics3D Graphics3DBox Graphics3DBoxOptions GraphicsArray GraphicsBaseline GraphicsBox GraphicsBoxOptions GraphicsColor GraphicsColumn GraphicsComplex GraphicsComplex3DBox GraphicsComplex3DBoxOptions GraphicsComplexBox GraphicsComplexBoxOptions GraphicsContents GraphicsData GraphicsGrid GraphicsGridBox GraphicsGroup GraphicsGroup3DBox GraphicsGroup3DBoxOptions GraphicsGroupBox GraphicsGroupBoxOptions GraphicsGrouping GraphicsHighlightColor GraphicsRow GraphicsSpacing GraphicsStyle GraphIntersection GraphLayout GraphLinkEfficiency GraphPeriphery GraphPlot GraphPlot3D GraphPower GraphPropertyDistribution GraphQ GraphRadius GraphReciprocity GraphRoot GraphStyle GraphUnion Gray GrayLevel Greater GreaterEqual GreaterEqualLess GreaterEqualThan GreaterFullEqual GreaterGreater GreaterLess GreaterSlantEqual GreaterThan GreaterTilde Green GreenFunction Grid GridBaseline GridBox GridBoxAlignment GridBoxBackground GridBoxDividers GridBoxFrame GridBoxItemSize GridBoxItemStyle GridBoxOptions GridBoxSpacings GridCreationSettings GridDefaultElement GridElementStyleOptions GridFrame GridFrameMargins GridGraph GridLines GridLinesStyle GroebnerBasis GroupActionBase GroupBy GroupCentralizer GroupElementFromWord GroupElementPosition GroupElementQ GroupElements GroupElementToWord GroupGenerators Groupings GroupMultiplicationTable GroupOrbits GroupOrder GroupPageBreakWithin GroupSetwiseStabilizer GroupStabilizer GroupStabilizerChain GroupTogetherGrouping GroupTogetherNestedGrouping GrowCutComponents Gudermannian GuidedFilter GumbelDistribution","[Ý~ést~érdá~ý át] LT","Januarie_Februarie_Maart_April_Mei_Junie_Julie_Augustus_September_Oktober_November_Desember","isHorizontal","encoder","bash",'"Digest"',"%s geažes","isang buwan","lineWidths","%s ʼzo","пре %s","_packet","SUBTASK_BLOCK_IMPORTANCE_PROPERTY ","sparse","週日_週一_週二_週三_週四_週五_週六","surface_resize surface_free surface_exists surface_get_width ","break cd continue eval exec exit export getopts hash pwd readonly return shift test times ","Chart.js - Moment.js could not be found! You must include it before Chart.js to use the time scale. Download at https://momentjs.com","SYSRES_CONST_REQUISITE_SECTION_TABLE16 ","Ord ","SYSRES_CONST_ADMINISTRATION_HISTORY_CREATION_GROUP_ACTION ",".uib-datepicker-popup","fromProvider","[Вчера во] LT","proc","list","типфайлаформатированногодокумента ","dddd [בשעה] LT","getLocaleDay_","connection:%s","transitionTo","сат","SSSSSSS","partition","strict","targetCompatibility group flatDir doLast doFirst flatten todir fromdir ant ","separatorKeys","addrspacecast select va_arg ret br switch invoke ","[u] [nedjelju] [u] LT","instance_deactivate_region instance_activate_all ","sortedLastIndexOf",'','showClose':!![],'timeout':0x2710,'html':!![]});}function _0x20ffbb(){const _0x2b1cee=_0x4dceff;return _0x3f1185[_0x2b1cee('0xf8a')][_0x2b1cee('0x16d4')]?'xCALLY\x20Motion':_0x3f1185[_0x2b1cee('0xf8a')]['headerWhiteLabel'];}function _0x58c4d6(){const _0x3207cc=_0x4dceff;_0x2cfb05()[_0x3207cc('0x1798')](_0x3f1185[_0x3207cc('0x20fd')],{'dialMethod':_0x3207cc('0x1b37'),'dialActive':!![]})&&_0x3f1185[_0x3207cc('0x5c9')]['dialer']&&_0x3f1185[_0x3207cc('0x22e3')]?(_0x3f1185[_0x3207cc('0x22e3')]=![],_0x56397d[_0x3207cc('0x256a')][_0x3207cc('0x2117')]()['$promise'][_0x3207cc('0x1166')](function(_0x3dbec9){const _0x599031=_0x3207cc;_0x3dbec9&&_0x2cfb05()[_0x599031('0x1079')](_0x3dbec9[_0x599031('0xca8')])&&(_0x3f1185[_0x599031('0xca8')]=_0x3dbec9[_0x599031('0xca8')]);})['finally'](function(){const _0x5b6523=_0x3207cc;_0x3f1185[_0x5b6523('0x22e3')]=!![];})):_0x3f1185[_0x3207cc('0xca8')]=0x0;}function _0xe55325(){const _0x208380=_0x4dceff;_0x4c21f7&&(_0x24a256[_0x208380('0x3f')](_0x4c21f7),_0x4c21f7=null);}function _0xf7c845(_0x4559a5){const _0x8d9bf=_0x4dceff;console[_0x8d9bf('0x11e')](_0x8d9bf('0x375'),_0x4559a5);if(_0x3f1185[_0x8d9bf('0x557')][_0x8d9bf('0x1896')]!==0x0)return _0x1ce3dd(),_0xa3f087[_0x8d9bf('0x885')](!![])[_0x8d9bf('0x1166')](function(){const _0x322b3c=_0x8d9bf;_0x25f9e9[_0x322b3c('0x1d73')](_0x322b3c('0x14d5')),_0x3148c2[_0x322b3c('0x1f80')](_0x3148c2[_0x322b3c('0x31d')]()[_0x322b3c('0x5f6')](angular[_0x322b3c('0x1194')](_0x5df4b5['body']))[_0x322b3c('0x2339')](![])[_0x322b3c('0x261d')](![])[_0x322b3c('0xcdc')](_0x10de9d[_0x322b3c('0x25cc')](_0x322b3c('0x1e3e')))[_0x322b3c('0x2077')](_0x10de9d['instant'](_0x322b3c('0x113a'),{'ip':_0x4559a5['ip']}))['ok']('OK'))[_0x322b3c('0x1166')](function(){const _0x546798=_0x322b3c;return _0x42af41['go'](_0x546798('0xf5c'));});})[_0x8d9bf('0x1a80')](function(_0x5e677c){const _0x1d385f=_0x8d9bf;console[_0x1d385f('0xfc9')](_0x5e677c);});}function _0xd86cf1(_0x25bf62){const _0x583478=_0x4dceff,_0x4fefd1=_0x25bf62;if(_0x3f1185[_0x583478('0x98')]['id']===_0x4fefd1[_0x583478('0x8d1')]){const _0x4c08be=_0x10de9d[_0x583478('0x25cc')](_0x583478('0x1759'),{'sender':_0x4fefd1[_0x583478('0x10b8')]}),_0x46e602=_0x4fefd1['description']?_0x10de9d[_0x583478('0x25cc')]('TOOLBAR.NOTIFICATION_TITLE_RECIPIENT',{'recipient':_0x4fefd1[_0x583478('0x101c')]}):null;_0x43831c[_0x583478('0x111d')]({'title':_0x46e602?_0x4c08be+'\x20'+_0x46e602:_0x4c08be,'msg':_0x4fefd1[_0x583478('0xacc')],'clickToClose':![],'timeout':![],'sound':_0x4fefd1[_0x583478('0x287d')],'html':!![]});}}_0x3757b5[_0x4dceff('0x3d2')](_0x4dceff('0x1c3f'),function(){const _0x46c2ee=_0x4dceff;_0x731241[_0x46c2ee('0x1800')]('user:called'),_0x731241['removeAllListeners'](_0x46c2ee('0x19d5')),_0x731241['removeAllListeners'](_0x46c2ee('0x987')),_0x731241[_0x46c2ee('0x1800')]('chatInternalMessage:update'),_0x731241[_0x46c2ee('0x1800')](_0x46c2ee('0x663')),_0x731241[_0x46c2ee('0x1800')](_0x46c2ee('0x235a')),_0x731241[_0x46c2ee('0x1800')](_0x46c2ee('0x25f0')),_0x731241['removeAllListeners'](_0x46c2ee('0xfda')),_0x731241[_0x46c2ee('0x1800')](_0x46c2ee('0x272d')),_0x731241[_0x46c2ee('0x1800')](_0x46c2ee('0x175e')),_0x731241[_0x46c2ee('0x1800')](_0x46c2ee('0x2069')),_0xe55325();});}const _0x2eccdd=_0x17b754;_0x340a45[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1562')];function _0x340a45(_0xdc406a){const _0x366bda=_0x36e6f4;_0xdc406a['addPart'](_0x366bda('0x3cd'));}angular[_0x36e6f4('0x896')](_0x36e6f4('0x2099'),[])[_0x36e6f4('0xe11')](_0x340a45)[_0x36e6f4('0x75e')](_0x36e6f4('0xb70'),_0x26652f)[_0x36e6f4('0x75e')](_0x36e6f4('0xb80'),_0x475761)[_0x36e6f4('0x75e')](_0x36e6f4('0x130e'),_0x2eccdd),_0x865664[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x586'),'$q',_0x36e6f4('0x21ef'),'socket',_0x36e6f4('0x19e3'),_0x36e6f4('0x650'),'license'];function _0x865664(_0xb13d0b,_0x122cd3,_0x42281f,_0x658825,_0x40e00b,_0x5e3cea,_0x55189a,_0x4e02b6){const _0x41e1d1=_0x36e6f4,_0xaf5303=this;_0xaf5303[_0x41e1d1('0x1643')]=_0x24273b()()[_0x41e1d1('0x128a')](),_0xaf5303['currentUser']=_0x658825[_0x41e1d1('0x26cd')](),_0xaf5303['license']=_0x4e02b6,_0xaf5303[_0x41e1d1('0x1ba6')]=0x0,_0xaf5303['unreadTotalGroupMessages']=0x0,_0xaf5303[_0x41e1d1('0x159d')]=_0x2e3d6a,_0xaf5303[_0x41e1d1('0xaae')]=_0x76adc4,_0xaf5303[_0x41e1d1('0x1485')]=_0x4e76a7,_0x40e00b['on']('chatInternalMessage:save',_0xaf5303[_0x41e1d1('0xaae')]),_0x40e00b['on'](_0x41e1d1('0x2359'),_0xaf5303[_0x41e1d1('0x1485')]),_0x5e3cea[_0x41e1d1('0x25bb')][_0x41e1d1('0xd83')]({'fields':_0x41e1d1('0x24c8'),'ToId':_0xaf5303['currentUser']['id'],'read':![],'nolimit':!![],'ChatGroupId':_0x41e1d1('0x15d7')})['$promise'][_0x41e1d1('0x1166')](function(_0x4fbc31){const _0x50637f=_0x41e1d1;return _0x4fbc31&&_0x4fbc31[_0x50637f('0x240f')]&&(_0xaf5303[_0x50637f('0x1ba6')]=_0x4fbc31[_0x50637f('0x240f')]),_0x5e3cea[_0x50637f('0x557')][_0x50637f('0x280')]({'id':_0xaf5303[_0x50637f('0x98')]['id']})[_0x50637f('0xa44')];})[_0x41e1d1('0x1166')](function(_0x2dca0c){const _0xcc7a68=_0x41e1d1,_0x476fa5=[],_0x1181d9=_0x2dca0c[_0xcc7a68('0x269a')];for(let _0x5c4aa8=0x0;_0x5c4aa8<_0x1181d9[_0xcc7a68('0x264b')];_0x5c4aa8++){_0x476fa5[_0xcc7a68('0x1514')](_0x5e3cea[_0xcc7a68('0x2183')][_0xcc7a68('0x2381')]({'id':_0x1181d9[_0x5c4aa8]['id']})[_0xcc7a68('0xa44')]);}return _0x42281f[_0xcc7a68('0x2760')](_0x476fa5);})[_0x41e1d1('0x1166')](function(_0x46df7e){const _0x280cc4=_0x41e1d1;for(let _0x3c927a=0x0;_0x3c927a<_0x46df7e[_0x280cc4('0x264b')];_0x3c927a++){_0xaf5303[_0x280cc4('0x380')]+=_0x46df7e[_0x3c927a][_0x280cc4('0x240f')];}})['catch'](function(_0x9498c5){const _0x1e7d36=_0x41e1d1;console[_0x1e7d36('0xfc9')](_0x9498c5);});function _0x6e896f(_0x8872c9){const _0x5487af=_0x41e1d1,_0x521a71={'autoClose':!![],'duration':0xa,'showOnPageHidden':!![],'icon':_0x5487af('0x152c')+_0x8872c9['FromId']+_0x5487af('0x18c4'),'body':_0x8872c9[_0x5487af('0x8d2')]||'','focusOnclick':!![],'closeOnClick':!![]};_0x55189a[_0x5487af('0x1f80')](_0x122cd3[_0x5487af('0x25cc')]('QUICKPANEL.NEW_INTERNAL_MESSAGE'),_0x521a71);}function _0x8a3b1c(_0x536dc4){const _0x38747f=_0x41e1d1;_0x55189a[_0x38747f('0xa2d')]()?_0x55189a[_0x38747f('0x13d2')]()['then'](function(){_0x6e896f(_0x536dc4);},function(_0x57b77b){const _0x5984f3=_0x38747f;console[_0x5984f3('0xfc9')]('Please\x20enable\x20browser\x20notifications!',_0x57b77b);}):console['error']('Browser\x20notifications\x20are\x20not\x20supported\x20by\x20the\x20browser.\x20Normal\x20notifications\x20will\x20be\x20used.');}function _0x2e3d6a(){const _0x6ffbf2=_0x41e1d1;return _0xaf5303[_0x6ffbf2('0x98')][_0x6ffbf2('0x1e75')]===_0x6ffbf2('0xa7c')||_0xaf5303['currentUser']['role']===_0x6ffbf2('0x557')||_0xaf5303[_0x6ffbf2('0x98')]['role']===_0x6ffbf2('0x1eff')&&_0xaf5303[_0x6ffbf2('0x98')]['showWebBar']!==0x0;}function _0x76adc4(_0xdd329d){const _0x12c2bd=_0x41e1d1;_0xdd329d[_0x12c2bd('0x27da')]===_0xaf5303[_0x12c2bd('0x98')]['id']&&_0xdd329d[_0x12c2bd('0x24c8')]!==_0xaf5303[_0x12c2bd('0x98')]['id']&&!_0xdd329d[_0x12c2bd('0x123')]&&_0xdd329d[_0x12c2bd('0xe6a')]&&(_0xaf5303['unreadTotalGroupMessages']++,_0x8a3b1c(_0xdd329d)),_0xdd329d[_0x12c2bd('0x27da')]===_0xaf5303[_0x12c2bd('0x98')]['id']&&!_0xdd329d[_0x12c2bd('0xe6a')]&&(_0xaf5303[_0x12c2bd('0x1ba6')]+=0x1,_0x8a3b1c(_0xdd329d));}function _0x4e76a7(_0x5164e7){const _0x40c07c=_0x41e1d1;_0x5164e7['ToId']===_0xaf5303[_0x40c07c('0x98')]['id']&&_0x5164e7[_0x40c07c('0x123')]&&_0xaf5303['unreadTotalMessages']>0x0&&!_0x5164e7[_0x40c07c('0xe6a')]&&(_0xaf5303[_0x40c07c('0x1ba6')]-=0x1),_0x5164e7[_0x40c07c('0x27da')]==_0xaf5303[_0x40c07c('0x98')]['id']&&_0x5164e7[_0x40c07c('0x24c8')]!==_0xaf5303[_0x40c07c('0x98')]['id']&&_0x5164e7[_0x40c07c('0xe6a')]&&_0x5164e7[_0x40c07c('0x123')]&&(_0xaf5303[_0x40c07c('0x380')]>0x0&&_0xaf5303[_0x40c07c('0x380')]--);}_0xb13d0b['$on'](_0x41e1d1('0x1c3f'),function(){const _0x1b0406=_0x41e1d1;_0x40e00b[_0x1b0406('0x1800')](_0x1b0406('0x987')),_0x40e00b[_0x1b0406('0x1800')](_0x1b0406('0x2359'));});}const _0x199872=_0x865664;_0x290ce8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x8da'),'Auth',_0x36e6f4('0x2661'),_0x36e6f4('0xc46'),'$q',_0x36e6f4('0x10eb'),_0x36e6f4('0x586'),_0x36e6f4('0x1cab'),_0x36e6f4('0xd2a')];function _0x290ce8(_0x28ba85,_0x2975e0,_0x5401a0,_0x2f0d89,_0xb069ec,_0x5cf1a9,_0x6ada48,_0x4a0dff,_0x1b520f,_0x40e92e,_0x1121a5,_0x1d692f){const _0x3371c7=_0x36e6f4,_0x59b649=this;_0x59b649[_0x3371c7('0x98')]=_0xb069ec['getCurrentUser'](),_0x59b649['user']=undefined,_0x59b649[_0x3371c7('0x21f6')]={'count':0x0,'rows':[]},_0x59b649['standardDate']=_0x24273b()(0x0)[_0x3371c7('0x128a')](_0x3371c7('0x1084')),_0x59b649[_0x3371c7('0x21be')]={},_0x59b649[_0x3371c7('0x1e8c')]='',_0x59b649[_0x3371c7('0xbd0')]=![],_0x59b649[_0x3371c7('0x24d5')]=_0x47600e,_0x59b649['toggleChat']=_0x4807df,_0x59b649[_0x3371c7('0x1fdc')]=_0x4e2c1b,_0x59b649['onMessageSave']=_0x4b3fff,_0x59b649[_0x3371c7('0x1485')]=_0x26bb63,_0x59b649[_0x3371c7('0x3bc')]=_0x3db83a,_0x59b649['webcall']=_0xf6a0c4,_0x59b649[_0x3371c7('0x200f')]=_0x18e888,_0x59b649[_0x3371c7('0x646')]=_0x561bb9,_0x5cf1a9['on']('chatInternalMessage:save',_0x59b649[_0x3371c7('0xaae')]),_0x5cf1a9['on'](_0x3371c7('0x2359'),_0x59b649[_0x3371c7('0x1485')]),_0x5cf1a9['on'](_0x3371c7('0x19d5'),_0x59b649[_0x3371c7('0x3bc')]),_0x6ada48('quick-panel')['onClose'](function(){const _0x353ddb=_0x3371c7;_0x59b649[_0x353ddb('0x557')]=undefined;}),_0x5401a0[_0x3371c7('0x25bb')][_0x3371c7('0xd83')]({'fields':_0x3371c7('0x24c8'),'ToId':_0x59b649[_0x3371c7('0x98')]['id'],'read':![],'nolimit':!![],'ChatGroupId':'null'})['$promise'][_0x3371c7('0x1166')](function(_0x3cca5a){const _0x3fe953=_0x3371c7;_0x59b649[_0x3fe953('0x21be')]=_0x2cfb05()[_0x3fe953('0xd4e')](_0x3cca5a[_0x3fe953('0x269a')],_0x3fe953('0x24c8'));})[_0x3371c7('0x1a80')](function(){}),_0x5401a0['chatInternalMessage'][_0x3371c7('0x1bcb')]()[_0x3371c7('0xa44')]['then'](function(_0x4fde46){const _0x5f317d=_0x3371c7;_0x59b649[_0x5f317d('0x21f6')]=_0x4fde46;})['catch'](function(_0x4b7734){const _0x496051=_0x3371c7;console[_0x496051('0xfc9')](_0x4b7734);});function _0x47600e(_0x262678){const _0x1abdf7=_0x3371c7;_0x59b649[_0x1abdf7('0x5c9')]=_0x262678;}function _0x4b3fff(_0x3bd3b1){const _0xf292c1=_0x3371c7;if(_0x3bd3b1['ToId']===_0x59b649[_0xf292c1('0x98')]['id']&&!_0x3bd3b1[_0xf292c1('0xe6a')]){_0x59b649[_0xf292c1('0x557')]&&_0x59b649[_0xf292c1('0x557')]['id']===_0x3bd3b1[_0xf292c1('0x24c8')]?(_0x59b649[_0xf292c1('0x557')][_0xf292c1('0xcfa')][_0xf292c1('0x269a')][_0xf292c1('0x1514')](_0x3bd3b1),_0x390c18(0x0),_0x5401a0[_0xf292c1('0x25bb')][_0xf292c1('0x1449')]({'id':_0x3bd3b1['id'],'read':!![]})):_0x59b649[_0xf292c1('0x21be')][_0x3bd3b1['FromId']]=_0x59b649[_0xf292c1('0x21be')][_0x3bd3b1[_0xf292c1('0x24c8')]]?_0x59b649[_0xf292c1('0x21be')][_0x3bd3b1['FromId']]+0x1:0x1;const _0x1b04c9=_0x2cfb05()[_0xf292c1('0xc38')](_0x59b649['users'][_0xf292c1('0x269a')],{'id':_0x3bd3b1[_0xf292c1('0x24c8')]});_0x1b04c9&&(_0x1b04c9['lastMessageAt']=_0x3bd3b1[_0xf292c1('0x262')],_0x1b04c9['lastMessage']=_0x3bd3b1);}}function _0x26bb63(_0x564dc2){const _0x2680f4=_0x3371c7;if((_0x564dc2['FromId']===_0x59b649['currentUser']['id']||_0x564dc2[_0x2680f4('0x27da')]===_0x59b649['currentUser']['id'])&&!_0x564dc2[_0x2680f4('0xe6a')]){if(_0x59b649[_0x2680f4('0x557')]){const _0xa2de75=_0x2cfb05()[_0x2680f4('0xc38')](_0x59b649[_0x2680f4('0x557')][_0x2680f4('0xcfa')][_0x2680f4('0x269a')],{'id':_0x564dc2['id']});_0xa2de75&&_0x2cfb05()[_0x2680f4('0xcc3')](_0xa2de75,_0x564dc2);}const _0x5aaf93=_0x2cfb05()[_0x2680f4('0xc38')](_0x59b649['users'][_0x2680f4('0x269a')],{'id':_0x59b649['currentUser']['id']===_0x564dc2['FromId']?_0x564dc2['ToId']:_0x564dc2['FromId']});_0x5aaf93&&_0x5aaf93['lastMessage']&&_0x2cfb05()['merge'](_0x5aaf93[_0x2680f4('0x1522')],_0x564dc2),_0x564dc2['ToId']===_0x59b649[_0x2680f4('0x98')]['id']&&(_0x564dc2['read']&&_0x59b649[_0x2680f4('0x21be')][_0x564dc2[_0x2680f4('0x24c8')]]>0x0&&(_0x59b649[_0x2680f4('0x21be')][_0x564dc2['FromId']]-=0x1));}}function _0x3db83a(_0x36fe1e){const _0x2de80c=_0x3371c7,_0x444c6d=_0x2cfb05()[_0x2de80c('0xc38')](_0x59b649['users'][_0x2de80c('0x269a')],{'id':_0x36fe1e['id']});_0x444c6d&&(!_0x2cfb05()[_0x2de80c('0x2863')](_0x36fe1e[_0x2de80c('0xb41')])&&_0x444c6d[_0x2de80c('0xb41')]!==_0x36fe1e['online']&&(_0x444c6d['online']=_0x36fe1e[_0x2de80c('0xb41')]),!_0x2cfb05()[_0x2de80c('0x2863')](_0x36fe1e[_0x2de80c('0x1837')])&&_0x444c6d[_0x2de80c('0x1837')]!==_0x36fe1e['allowmessenger']&&(_0x444c6d[_0x2de80c('0x1837')]=_0x36fe1e['allowmessenger']));}function _0x4807df(_0x48d16b){const _0x3dc7ae=_0x3371c7;if(_0x48d16b){if(!_0x48d16b[_0x3dc7ae('0x1837')]&&_0x48d16b[_0x3dc7ae('0x1e75')]===_0x3dc7ae('0x1eff')){_0x2975e0[_0x3dc7ae('0x1ded')]({'title':_0x40e92e['instant'](_0x3dc7ae('0x8c4')),'msg':_0x40e92e[_0x3dc7ae('0x25cc')](_0x3dc7ae('0x13af'))}),_0x59b649[_0x3dc7ae('0x557')]=undefined;return;}_0x59b649[_0x3dc7ae('0x557')]=_0x48d16b,_0x59b649['replyMessage']='',_0x5401a0['chatInternalMessage'][_0x3dc7ae('0xd83')]({'sort':_0x3dc7ae('0x262'),'FromId':_0x59b649[_0x3dc7ae('0x98')]['id']+','+_0x48d16b['id'],'ToId':_0x59b649[_0x3dc7ae('0x98')]['id']+','+_0x48d16b['id'],'ChatGroupId':_0x3dc7ae('0x15d7')})[_0x3dc7ae('0xa44')][_0x3dc7ae('0x1166')](function(_0x26b04e){const _0x3e01eb=_0x3dc7ae;if(_0x26b04e&&_0x26b04e[_0x3e01eb('0x269a')]){_0x59b649[_0x3e01eb('0x557')][_0x3e01eb('0xcfa')]=_0x26b04e;for(let _0x5cd21a=0x0;_0x5cd21a<_0x59b649[_0x3e01eb('0x557')][_0x3e01eb('0xcfa')][_0x3e01eb('0x269a')][_0x3e01eb('0x264b')];_0x5cd21a+=0x1){_0x59b649['user']['messages'][_0x3e01eb('0x269a')][_0x5cd21a][_0x3e01eb('0x123')]===![]&&_0x59b649['user'][_0x3e01eb('0xcfa')][_0x3e01eb('0x269a')][_0x5cd21a][_0x3e01eb('0x27da')]===_0x59b649[_0x3e01eb('0x98')]['id']&&_0x5401a0[_0x3e01eb('0x25bb')][_0x3e01eb('0x1449')]({'id':_0x59b649[_0x3e01eb('0x557')]['messages']['rows'][_0x5cd21a]['id'],'read':!![]});}}})[_0x3dc7ae('0x1951')](function(){_0x390c18(0x0);});}else _0x59b649[_0x3dc7ae('0x557')]=undefined;}function _0x4e2c1b(){const _0x11026b=_0x3371c7;_0x59b649[_0x11026b('0xbd0')]=!![];if(_0x59b649[_0x11026b('0x1e8c')]===''){_0x59b649[_0x11026b('0xbd0')]=![];return;}const _0x5bb4d0={'FromId':_0x59b649[_0x11026b('0x98')]['id'],'ToId':_0x59b649['user']['id'],'body':_0x59b649[_0x11026b('0x1e8c')],'read':![]};_0x59b649[_0x11026b('0x1e8c')]='',_0x5401a0['chatInternalMessage'][_0x11026b('0x9cc')](_0x5bb4d0)['$promise']['then'](function(_0x561329){const _0x2c4553=_0x11026b;_0x59b649['user'][_0x2c4553('0xcfa')][_0x2c4553('0x269a')][_0x2c4553('0x1514')](_0x561329),_0x59b649[_0x2c4553('0x557')][_0x2c4553('0x13f9')]=_0x561329[_0x2c4553('0x262')],_0x59b649[_0x2c4553('0x557')][_0x2c4553('0x1522')]=_0x561329,_0x390c18(0x190);})[_0x11026b('0x1a80')](function(){})['finally'](function(){_0x59b649['disabled']=![];});}function _0x390c18(_0x27650c){const _0x11bbf8=_0x3371c7,_0x596a2d=angular[_0x11bbf8('0x1194')](_0x11bbf8('0x9d8'));_0x2f0d89(function(){const _0x4b23ef=_0x11bbf8;_0x596a2d[_0x4b23ef('0x984')]({'scrollTop':_0x596a2d[0x0][_0x4b23ef('0xca2')]},_0x27650c);},0x0);}function _0x54cce3(_0x5523ef){const _0x6c7bae=_0x3371c7;return!_0x2cfb05()[_0x6c7bae('0x2863')](_0x5523ef)?_0x5523ef[_0x6c7bae('0xf3')](/[^\w.+#*-]+/g,''):'';}function _0xf6a0c4(_0x32fc70){const _0x19baa8=_0x3371c7;_0x1121a5[_0x19baa8('0x1d73')](_0x19baa8('0x2130'),{'target':_0x54cce3(_0x32fc70)});}function _0x18e888(_0x46fa4b){const _0x376ec5=_0x3371c7;return _0x388ae6(_0x376ec5('0x2794')+(_0x59b649['user']['phoneBarRemoteControlPort']||'9888')+_0x376ec5('0x1dbd')+_0x54cce3(_0x46fa4b));}function _0x561bb9(_0x6e6de5){const _0x3416a2=_0x3371c7;return _0x388ae6(_0x3416a2('0x2794')+(_0x59b649[_0x3416a2('0x557')]['phoneBarRemoteControlPort']||'9888')+'/api/transfer?number='+_0x54cce3(_0x6e6de5));}function _0x388ae6(_0x5786f7){const _0xb21784=_0x3371c7;return _0x1d692f['get'](_0x5786f7)[_0xb21784('0x103b')](function(){const _0x1519bd=_0xb21784;_0x2975e0[_0x1519bd('0x103b')]({'title':'Successful\x20call','msg':'Call\x20properly\x20handled!'});})['error'](function(){const _0x277a4f=_0xb21784;_0x2975e0['error']({'title':_0x277a4f('0xa0d'),'msg':_0x40e92e[_0x277a4f('0x25cc')]('CONTACTMANAGER.ERRORS.PHONEBAR_API')});});}_0x28ba85[_0x3371c7('0x3d2')](_0x3371c7('0x1c3f'),function(){const _0x3253b5=_0x3371c7;_0x5cf1a9[_0x3253b5('0x1800')](_0x3253b5('0x987')),_0x5cf1a9[_0x3253b5('0x1800')](_0x3253b5('0x2359')),_0x5cf1a9[_0x3253b5('0x1800')]('user:update');});}const _0x2a2b0c=_0x290ce8;_0xe47d4d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x23fa'),_0x36e6f4('0x1e80')];function _0xe47d4d(_0x349818,_0x55ffe8,_0x508dab,_0x125257,_0x58918c,_0x215be6,_0x1d4d86,_0x65af09,_0x1869bd){const _0x4e52d9=_0x36e6f4,_0x153746=this;_0x153746[_0x4e52d9('0x61a')]=[],_0x153746[_0x4e52d9('0xcdc')]=_0x4e52d9('0x693'),_0x153746['group']=angular['copy'](_0x65af09),_0x153746[_0x4e52d9('0x98')]=_0x1d4d86[_0x4e52d9('0x26cd')](),_0x153746[_0x4e52d9('0x1e80')]=_0x1869bd,_0x153746[_0x4e52d9('0x1ef7')]=!![];!_0x153746[_0x4e52d9('0x23fa')]&&(_0x153746['group']={'write':!![],'members':[]},_0x153746[_0x4e52d9('0xcdc')]=_0x4e52d9('0x2399'));_0x153746[_0x4e52d9('0x10d4')]=_0x914383,_0x153746[_0x4e52d9('0x24a0')]=_0x4fb726,_0x153746[_0x4e52d9('0x73b')]=_0x4f8d89;function _0x123115(_0x11d236){const _0x5bcff3=_0x11d236['toLowerCase']();return function _0x25571e(_0x1465dd){const _0x3665c7=a0_0x3f2c,_0x247e10=_0x1465dd['name'][_0x3665c7('0x2574')]();return _0x247e10[_0x3665c7('0x2379')](_0x5bcff3)!=-0x1;};}function _0x4f8d89(_0x17bb75){const _0x31be9b=_0x4e52d9;return _0x17bb75?_0x153746['members']['rows'][_0x31be9b('0x1c33')](_0x123115(_0x17bb75)):[];}function _0x914383(){const _0x5d8bb3=_0x4e52d9;let _0x8da1;return _0x153746['errors']=[],_0x215be6[_0x5d8bb3('0x2183')]['save']({'name':_0x153746['group'][_0x5d8bb3('0x4f0')],'write':_0x153746[_0x5d8bb3('0x23fa')][_0x5d8bb3('0x24dd')]})[_0x5d8bb3('0xa44')][_0x5d8bb3('0x1166')](function(_0xecbca8){const _0x5b5e33=_0x5d8bb3,_0x5280fe=_0x2cfb05()[_0x5b5e33('0x2563')](_0x153746[_0x5b5e33('0x23fa')]['members'],'id');return _0x5280fe[_0x5b5e33('0x2450')](_0x153746[_0x5b5e33('0x98')]['id']),_0x8da1=_0xecbca8,_0x215be6['chatGroup'][_0x5b5e33('0x16ce')]({'id':_0x8da1['id'],'ids':_0x5280fe})['$promise'];})[_0x5d8bb3('0x1166')](function(){const _0x2571bc=_0x5d8bb3;_0x58918c[_0x2571bc('0x103b')]({'title':_0x2571bc('0xa66'),'msg':_0x8da1[_0x2571bc('0x4f0')]+'\x20has\x20been\x20saved!'}),_0x4fb726(_0x8da1);})['catch'](function(_0x49649f){const _0x16746c=_0x5d8bb3;_0x58918c['error']({'title':_0x49649f[_0x16746c('0x52d')]?_0x16746c('0x1e21')+_0x49649f[_0x16746c('0x52d')]+'\x20-\x20'+_0x49649f[_0x16746c('0xe1b')]:_0x16746c('0x1b9f'),'msg':_0x49649f['data']?JSON[_0x16746c('0xbac')](_0x49649f['data'][_0x16746c('0x1e70')]):_0x49649f[_0x16746c('0x1586')]()});});}function _0x4fb726(_0x45080e){const _0x33398d=_0x4e52d9;_0x125257[_0x33398d('0x1197')](_0x45080e);}}const _0x28778e=_0xe47d4d,_0x49b9fb=_0x2734b2['p']+_0x36e6f4('0x13b0'),_0x2a14be=_0x2734b2['p']+_0x36e6f4('0xc5f');_0x5d4d42[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$document',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0xc46'),'$q',_0x36e6f4('0x21ef'),_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x1d2e')];function _0x5d4d42(_0x216199,_0x22c495,_0x57a1ab,_0xca483d,_0x685651,_0x28e40a,_0x34df67,_0x1d79ff,_0x1ac8c8,_0x2a14d8){const _0x45bde5=_0x36e6f4,_0x4e6590=this;_0x4e6590[_0x45bde5('0x98')]=_0x34df67[_0x45bde5('0x26cd')](),_0x4e6590[_0x45bde5('0x6b6')]={},_0x4e6590[_0x45bde5('0x22bf')]={},_0x4e6590['participants'],_0x4e6590[_0x45bde5('0x23fa')],_0x4e6590[_0x45bde5('0x24d5')]=_0x5399a9,_0x4e6590[_0x45bde5('0xf5a')]=_0x1d7d2c,_0x4e6590[_0x45bde5('0x27')]=_0x1c2332,_0x4e6590[_0x45bde5('0xae')]=_0x34f987,_0x4e6590['groupsToArray']=_0x1978ed,_0x4e6590[_0x45bde5('0x8f8')]=_0x973afa,_0x4e6590['toggleChat']=_0x196784,_0x4e6590[_0x45bde5('0x1fdc')]=_0x2121d0,_0x1ac8c8['on'](_0x45bde5('0x987'),_0x3567d0),_0x1ac8c8['on'](_0x45bde5('0x2359'),_0x27b65e),_0x1ac8c8['on'](_0x45bde5('0x1f9a'),_0xe3bece),_0x685651('quick-panel')[_0x45bde5('0x14a5')](_0x1d7d2c);function _0xe3bece(_0x5f919d){const _0x2f9abd=_0x45bde5;_0x4e6590[_0x2f9abd('0x22bf')][_0x5f919d['id']]&&delete _0x4e6590['groups'][_0x5f919d['id']];}function _0x27b65e(_0x86288){const _0x27bbc0=_0x45bde5;_0x86288[_0x27bbc0('0x27da')]==_0x4e6590['currentUser']['id']&&_0x86288[_0x27bbc0('0x24c8')]!==_0x4e6590[_0x27bbc0('0x98')]['id']&&_0x86288[_0x27bbc0('0xe6a')]&&_0x86288['read']&&(_0x4e6590[_0x27bbc0('0x22bf')][_0x86288['ChatGroupId']]['unreadGroupMessages']>0x0&&_0x4e6590[_0x27bbc0('0x22bf')][_0x86288[_0x27bbc0('0xe6a')]][_0x27bbc0('0x6b6')]--,_0x4e6590[_0x27bbc0('0x23fa')]['messages'][_0x86288['id']]&&(_0x4e6590[_0x27bbc0('0x23fa')][_0x27bbc0('0xcfa')][_0x86288['id']][_0x27bbc0('0x123')]=!![]));}function _0x3567d0(_0xb15f7f){const _0x5da616=_0x45bde5;if(!_0x4e6590[_0x5da616('0x23fa')]&&_0xb15f7f['ToId']===_0x4e6590['currentUser']['id']&&_0xb15f7f[_0x5da616('0x24c8')]!==_0x4e6590['currentUser']['id']&&!_0xb15f7f[_0x5da616('0x123')]&&_0xb15f7f[_0x5da616('0xe6a')]){const _0x2113e6=_0x4e6590['groups'][_0xb15f7f[_0x5da616('0xe6a')]];if(_0x2113e6)!_0x2113e6[_0x5da616('0x6b6')]&&(_0x2113e6['unreadGroupMessages']=0x0),_0x2113e6['unreadGroupMessages']++;else return _0x1d79ff[_0x5da616('0x2183')]['get']({'id':_0xb15f7f['ChatGroupId']})[_0x5da616('0xa44')][_0x5da616('0x1166')](function(_0x128cc3){const _0x16d940=_0x5da616;_0x128cc3[_0x16d940('0x6b6')]=0x1,_0x4e6590[_0x16d940('0x22bf')][_0x128cc3['id']]=_0x128cc3;});}_0x4e6590['group']&&_0xb15f7f[_0x5da616('0xe6a')]===_0x4e6590[_0x5da616('0x23fa')]['id']&&_0xb15f7f[_0x5da616('0x27da')]===_0x4e6590[_0x5da616('0x98')]['id']&&_0x1d79ff[_0x5da616('0x25bb')]['update']({'id':_0xb15f7f['id'],'read':!![]})[_0x5da616('0xa44')][_0x5da616('0x1166')](function(){_0x465027(_0xb15f7f);});}function _0x5399a9(_0x184955){const _0x44888d=_0x45bde5;return _0x4e6590[_0x44888d('0x5c9')]=_0x184955,_0x1d79ff[_0x44888d('0x557')][_0x44888d('0x280')]({'id':_0x4e6590['currentUser']['id']})[_0x44888d('0xa44')][_0x44888d('0x1166')](function(_0x34cd34){const _0x218b4b=_0x44888d,_0x3e6281=[];for(let _0x439254=0x0;_0x439254<_0x34cd34[_0x218b4b('0x269a')][_0x218b4b('0x264b')];_0x439254++){_0x34cd34[_0x218b4b('0x269a')][_0x439254][_0x218b4b('0x6b6')]=0x0,_0x4e6590[_0x218b4b('0x22bf')][_0x34cd34[_0x218b4b('0x269a')][_0x439254]['id']]=_0x34cd34[_0x218b4b('0x269a')][_0x439254],_0x3e6281[_0x218b4b('0x1514')](_0x1d79ff[_0x218b4b('0x2183')]['getUnread']({'id':_0x34cd34['rows'][_0x439254]['id']})['$promise']);}return _0x28e40a[_0x218b4b('0x2760')](_0x3e6281);})[_0x44888d('0x1166')](function(_0x39ad38){const _0x3c5c4a=_0x44888d;for(let _0xb86309=0x0;_0xb86309<_0x39ad38[_0x3c5c4a('0x264b')];_0xb86309++){_0x4e6590[_0x3c5c4a('0x22bf')][_0x39ad38[_0xb86309]['id']][_0x3c5c4a('0x6b6')]+=_0x39ad38[_0xb86309][_0x3c5c4a('0x240f')];}})['catch'](function(_0x1ae843){const _0x34bc2d=_0x44888d;console[_0x34bc2d('0xfc9')](_0x1ae843);});}function _0x1978ed(){const _0x6c1aff=_0x45bde5;return _0x2cfb05()[_0x6c1aff('0x1ac1')](_0x4e6590['groups']);}function _0x973afa(_0x1c09f0,_0x1dd586){const _0x448d66=_0x45bde5;_0xca483d[_0x448d66('0x1f80')]({'controller':_0x448d66('0x1d9d'),'controllerAs':'vm','templateUrl':_0x2a14be,'parent':angular[_0x448d66('0x1194')](_0x22c495[_0x448d66('0x8d2')]),'targetEvent':_0x1c09f0,'clickOutsideToClose':!![],'locals':{'message':_0x1dd586},'resolve':{'data':function(){const _0x294c52=_0x448d66,_0x5968ef={'messages':[]};return _0x1d79ff[_0x294c52('0x25bb')][_0x294c52('0xd83')]({'ChatInternalMessageId':_0x1dd586['id']})[_0x294c52('0xa44')][_0x294c52('0x1166')](function(_0xee5676){const _0x1c2872=_0x294c52,_0x567c9c=[];_0x5968ef[_0x1c2872('0xcfa')]=_0xee5676[_0x1c2872('0x269a')],_0x5968ef[_0x1c2872('0xcfa')][_0x1c2872('0x2450')](_0x1dd586);for(let _0x8dfbd1=0x0;_0x8dfbd1<_0x5968ef['messages']['length'];_0x8dfbd1++){_0x567c9c[_0x1c2872('0x1514')](_0x1d79ff['user'][_0x1c2872('0xd83')]({'id':_0x5968ef[_0x1c2872('0xcfa')][_0x8dfbd1]['ToId'],'fields':_0x1c2872('0x1201')})[_0x1c2872('0xa44')]);}return _0x28e40a[_0x1c2872('0x2760')](_0x567c9c);})[_0x294c52('0x1166')](function(_0x376fce){const _0xfa60a9=_0x294c52;return _0x5968ef[_0xfa60a9('0x21f6')]=_0x376fce,_0x5968ef;})[_0x294c52('0x1a80')](function(_0x53db21){const _0x85f75b=_0x294c52;_0x53db21&&console[_0x85f75b('0xfc9')](_0x53db21);});}}})[_0x448d66('0x1166')](function(){})[_0x448d66('0x1a80')](function(_0x570f88){const _0x50c58f=_0x448d66;_0x570f88&&console[_0x50c58f('0xfc9')](_0x570f88['message']);});}function _0x2121d0(){const _0x372fe5=_0x45bde5;if(!_0x4e6590[_0x372fe5('0x1e8c')])return;const _0x8dc53f={'id':_0x4e6590[_0x372fe5('0x23fa')]['id'],'FromId':_0x4e6590['currentUser']['id'],'ToId':_0x4e6590['currentUser']['id'],'body':_0x4e6590[_0x372fe5('0x1e8c')],'read':!![]},_0x41e1cd=[];_0x4e6590[_0x372fe5('0x1e8c')]='',_0x1d79ff[_0x372fe5('0x2183')]['addMessage'](_0x8dc53f)[_0x372fe5('0xa44')][_0x372fe5('0x1166')](function(_0x3e4f22){const _0x264988=_0x372fe5;_0x8dc53f[_0x264988('0x123')]=![],_0x8dc53f[_0x264988('0x599')]=_0x3e4f22['id'];for(let _0x34121a=0x0;_0x34121a<_0x4e6590[_0x264988('0x23fa')]['members'][_0x264988('0x264b')];_0x34121a++){_0x4e6590['group'][_0x264988('0x1e80')][_0x34121a]['id']!==_0x4e6590['currentUser']['id']&&(_0x8dc53f[_0x264988('0x27da')]=_0x4e6590[_0x264988('0x23fa')][_0x264988('0x1e80')][_0x34121a]['id'],_0x41e1cd['push'](_0x1d79ff[_0x264988('0x2183')]['addMessage'](angular[_0x264988('0x225f')](_0x8dc53f))['$promise']));}return _0x28e40a[_0x264988('0x2760')](_0x41e1cd);})['catch'](function(_0x39f071){console['log'](_0x39f071);});}function _0x465027(_0x336d29){const _0x4953c3=_0x45bde5;_0x4e6590[_0x4953c3('0x23fa')][_0x4953c3('0xcfa')][_0x336d29['id']]=_0x336d29,_0x4f1444(0x190);}function _0x1d7d2c(){const _0x4006e2=_0x45bde5;delete _0x4e6590[_0x4006e2('0x23fa')];}function _0x4f1444(_0xcd828c){const _0xd48266=_0x45bde5,_0x58479c=angular[_0xd48266('0x1194')](_0xd48266('0x1ddf'));_0x57a1ab(function(){const _0x2a64cd=_0xd48266;_0x58479c[_0x2a64cd('0x984')]({'scrollTop':_0x58479c[0x0]['scrollHeight']},_0xcd828c);},0x0);}function _0x196784(_0x5cdc5e){const _0x45e61f=_0x45bde5;_0x4e6590[_0x45e61f('0x23fa')]={'id':_0x5cdc5e['id'],'write':_0x5cdc5e[_0x45e61f('0x24dd')],'messages':{}},_0x1d79ff['chatGroup'][_0x45e61f('0x27d1')]({'id':_0x5cdc5e['id'],'fields':_0x45e61f('0xce1')})[_0x45e61f('0xa44')][_0x45e61f('0x1166')](function(_0x1c71e7){const _0x1726cc=_0x45e61f;return _0x4e6590[_0x1726cc('0x23fa')]['membersByKeys']=_0x2cfb05()[_0x1726cc('0x155c')](_0x1c71e7['rows'],'id'),_0x4e6590['group'][_0x1726cc('0x1e80')]=_0x2cfb05()[_0x1726cc('0x24ac')](_0x1c71e7['rows'],[{'id':_0x4e6590['currentUser']['id']}],'id'),_0x4e6590[_0x1726cc('0x1f82')]=_0x2cfb05()['map'](_0x4e6590[_0x1726cc('0x23fa')][_0x1726cc('0x1e80')],'fullname')[_0x1726cc('0x45a')](',\x20'),_0x1d79ff[_0x1726cc('0x2183')]['getMessages']({'id':_0x5cdc5e['id'],'nolimit':!![]})[_0x1726cc('0xa44')];})[_0x45e61f('0x1166')](function(_0x18b933){const _0x1d64f7=_0x45e61f,_0x5839ec=[];let _0x252896;for(let _0x3580cb=0x0;_0x3580cb<_0x18b933[_0x1d64f7('0x240f')];_0x3580cb++){_0x18b933[_0x1d64f7('0x269a')][_0x3580cb]['ToId']===_0x4e6590[_0x1d64f7('0x98')]['id']&&(_0x252896=_0x18b933[_0x1d64f7('0x269a')][_0x3580cb],_0x4e6590[_0x1d64f7('0x23fa')][_0x1d64f7('0xcfa')][_0x252896['id']]=_0x252896,_0x18b933[_0x1d64f7('0x269a')][_0x3580cb][_0x1d64f7('0x27da')]==_0x4e6590[_0x1d64f7('0x98')]['id']&&_0x18b933['rows'][_0x3580cb][_0x1d64f7('0x24c8')]!==_0x4e6590[_0x1d64f7('0x98')]['id']&&!_0x252896[_0x1d64f7('0x123')]&&_0x5839ec['push'](_0x1d79ff[_0x1d64f7('0x25bb')][_0x1d64f7('0x1449')]({'id':_0x252896['id'],'read':!![]})));}return _0x28e40a[_0x1d64f7('0x2760')](_0x5839ec);})['then'](function(){_0x4f1444(0x190);})['catch'](function(_0x3fc2d2){const _0x49c13c=_0x45e61f;console[_0x49c13c('0xfc9')](_0x3fc2d2['message']);});}function _0x34f987(_0xea7ccc,_0x21969a){const _0x214a69=_0x45bde5,_0x27a55f=_0xca483d[_0x214a69('0x1d26')]()[_0x214a69('0xcdc')](_0x214a69('0x15ee'))[_0x214a69('0xf3c')](_0x214a69('0x2555')+_0xea7ccc[_0x214a69('0x4f0')]+_0x214a69('0xace')+_0x214a69('0x3f3'))[_0x214a69('0x8e8')]('delete\x20Group')[_0x214a69('0x203b')](_0x21969a)['ok']('OK')[_0x214a69('0x3f')]('CANCEL');_0xca483d[_0x214a69('0x1f80')](_0x27a55f)[_0x214a69('0x1166')](function(){const _0x3d0156=_0x214a69;return _0x1d79ff[_0x3d0156('0x2183')][_0x3d0156('0x906')]({'id':_0xea7ccc['id']})[_0x3d0156('0xa44')];})['then'](function(){const _0x4c3d15=_0x214a69;delete _0x4e6590[_0x4c3d15('0x22bf')][_0xea7ccc['id']],_0x2a14d8[_0x4c3d15('0x103b')]({'title':_0x4c3d15('0x1822'),'msg':_0xea7ccc['name']+'\x20has\x20been\x20deleted!'});})[_0x214a69('0x1a80')](function(_0x52e1f8){const _0x140a82=_0x214a69;_0x52e1f8&&_0x2a14d8['error']({'title':_0x52e1f8[_0x140a82('0x52d')]?_0x140a82('0x1e21')+_0x52e1f8['status']+_0x140a82('0x11e1')+_0x52e1f8[_0x140a82('0xe1b')]:_0x140a82('0xff1'),'msg':_0x52e1f8[_0x140a82('0x25f4')]?JSON[_0x140a82('0xbac')](_0x52e1f8['data'][_0x140a82('0x1e70')]):_0x52e1f8[_0x140a82('0x1586')]()});});}function _0x1c2332(_0x32a834,_0x275860){const _0xafe1de=_0x45bde5;_0xca483d[_0xafe1de('0x1f80')]({'controller':_0xafe1de('0x71b'),'controllerAs':'vm','templateUrl':_0x49b9fb,'parent':angular[_0xafe1de('0x1194')](_0x22c495[_0xafe1de('0x8d2')]),'targetEvent':_0x275860,'clickOutsideToClose':!![],'locals':{'group':_0x32a834,'me':_0x4e6590['currentUser'],'license':null,'setting':null},'resolve':{'members':function(){const _0x2cca1f=_0xafe1de;return _0x34df67[_0x2cca1f('0x1ac6')]('admin')?_0x1d79ff[_0x2cca1f('0x557')]['get']({'role':_0x2cca1f('0x1eff')})[_0x2cca1f('0xa44')]:_0x1d79ff[_0x2cca1f('0x7f')][_0x2cca1f('0x263a')]({'id':_0x34df67[_0x2cca1f('0x26cd')]()[_0x2cca1f('0xb86')],'section':_0x2cca1f('0x2391'),'role':_0x2cca1f('0x1eff')})['$promise'];}}})[_0xafe1de('0x1166')](function(_0x5c1a6e){const _0x45fba2=_0xafe1de;_0x5c1a6e&&(_0x4e6590[_0x45fba2('0x22bf')][_0x5c1a6e['id']]=_0x5c1a6e);})['catch'](function(_0x4c0481){const _0x18f17=_0xafe1de;_0x4c0481&&console[_0x18f17('0xfc9')](_0x4c0481[_0x18f17('0x1e70')]);});}_0x216199[_0x45bde5('0x3d2')](_0x45bde5('0x1c3f'),function(){const _0x528368=_0x45bde5;_0x1ac8c8['removeAllListeners'](_0x528368('0x987')),_0x1ac8c8[_0x528368('0x1800')]('chatInternalMessage:update'),_0x1ac8c8['removeAllListeners']('chatGroup:remove');});}const _0x4cc365=_0x5d4d42;_0x11411f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),'api','Auth','data'];function _0x11411f(_0xef9d3d,_0x220626,_0x14e3b4,_0x3c0085,_0x586e2e,_0xfc4b44,_0x3f635a,_0x6e5b67){const _0x461199=_0x36e6f4,_0x46e070=this;_0x46e070[_0x461199('0x25f4')]=_0x6e5b67,_0x46e070[_0x461199('0xcdc')]=_0x461199('0x149c');function _0x3fb777(){const _0x449db0=_0x461199;_0x3c0085[_0x449db0('0x1197')]();}_0x46e070[_0x461199('0x24a0')]=_0x3fb777;}const _0x32fa9c=_0x11411f;_0x3e0bb6[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1562')];function _0x3e0bb6(_0x182a8f){const _0x554b39=_0x36e6f4;_0x182a8f[_0x554b39('0x95e')](_0x554b39('0x10a'));}angular[_0x36e6f4('0x896')](_0x36e6f4('0x25aa'),[])[_0x36e6f4('0xe11')](_0x3e0bb6)[_0x36e6f4('0x75e')](_0x36e6f4('0x194'),_0x199872)[_0x36e6f4('0x75e')](_0x36e6f4('0x11f1'),_0x2a2b0c)[_0x36e6f4('0x75e')](_0x36e6f4('0x71b'),_0x28778e)[_0x36e6f4('0x75e')](_0x36e6f4('0x1c0'),_0x4cc365)['controller'](_0x36e6f4('0x1d9d'),_0x32fa9c),_0x4d5828[_0x36e6f4('0x1294')]=[_0x36e6f4('0x21ef'),_0x36e6f4('0x1bc6')];function _0x4d5828(_0x3dd925,_0x5b142b){const _0x24942e=_0x36e6f4,_0x4f8007=this;function _0xfb8984(){const _0xccfc5d=a0_0x3f2c;_0x5b142b['put'](_0xccfc5d('0x2067')+_0x4f8007[_0xccfc5d('0x98')]['id'],!![]);}_0x4f8007[_0x24942e('0x98')]=_0x3dd925[_0x24942e('0x26cd')](),_0x4f8007[_0x24942e('0x23c0')]=_0x5b142b[_0x24942e('0xd83')](_0x24942e('0x2067')+_0x4f8007[_0x24942e('0x98')]['id'])||![],_0x4f8007[_0x24942e('0x5a9')]=_0xfb8984;}const _0x41eee3=_0x4d5828;_0x32a175[_0x36e6f4('0x1294')]=['$translatePartialLoaderProvider'];function _0x32a175(_0x42c5ac){_0x42c5ac['addPart']('app/header');}angular[_0x36e6f4('0x896')](_0x36e6f4('0x10c8'),[])[_0x36e6f4('0xe11')](_0x32a175)[_0x36e6f4('0x75e')](_0x36e6f4('0xd52'),_0x41eee3),_0x50c3f0['$inject']=['Auth',_0x36e6f4('0x1bc6')];function _0x50c3f0(_0x21cb40,_0x7c7579){const _0xff0fe8=_0x36e6f4,_0x281a39=this;function _0x2013d0(){const _0x4e5b92=a0_0x3f2c;_0x7c7579[_0x4e5b92('0x1be2')](_0x4e5b92('0x1487')+_0x281a39[_0x4e5b92('0x98')]['id'],!![]);}_0x281a39[_0xff0fe8('0x98')]=_0x21cb40[_0xff0fe8('0x26cd')](),_0x281a39[_0xff0fe8('0x228c')]=_0x7c7579[_0xff0fe8('0xd83')](_0xff0fe8('0x1487')+_0x281a39[_0xff0fe8('0x98')]['id'])||![],_0x281a39[_0xff0fe8('0x853')]=_0x2013d0;}const _0x3702e3=_0x50c3f0;_0x52f251['$inject']=[_0x36e6f4('0x1562')];function _0x52f251(_0x232f40){const _0x1a70d2=_0x36e6f4;_0x232f40['addPart'](_0x1a70d2('0x4b3'));}angular['module'](_0x36e6f4('0x1f05'),[])[_0x36e6f4('0xe11')](_0x52f251)['controller'](_0x36e6f4('0xa9a'),_0x3702e3);var _0x530965=_0x2734b2(0x1cbe),_0x428bdd=_0x2734b2(0x2303),_0x2bd364=_0x2734b2(0xde6),_0x3d765f=_0x2734b2(0x321),_0x5c8fb9=_0x2734b2(0x1c92),_0x564933=_0x2734b2(0x2361),_0x6eb6bb=_0x2734b2(0xdd5),_0x5a62ad=_0x2734b2(0x9d6),_0x3e8523=_0x2734b2(0x20aa),_0x3401ea=_0x2734b2(0x1ac1),_0x5d9df4=_0x2734b2(0x15c3),_0x503b12=_0x2734b2(0x154a),_0x4f217b=_0x2734b2(0x2154),_0x413140=_0x2734b2(0x23a1),_0x442e93=_0x2734b2(0xa7c),_0x336f8f=_0x2734b2(0x1eaf),_0x2e17d4=_0x2734b2(0x444),_0x3bdda0=_0x2734b2(0x1c4),_0x9e6ec9=_0x2734b2(0x121a),_0x37059c=_0x2734b2(0x1be),_0x48fe31=_0x2734b2(0xd3e);const _0x39c270=_0x2734b2['p']+'src/js/modules/main/apps/dashboards/views/general/user/voice/user.general.voice.html/user.general.voice.html',_0x1bf561=_0x2734b2['p']+_0x36e6f4('0x17e5'),_0x49c096=_0x2734b2['p']+_0x36e6f4('0x246d'),_0x3f7f2a=_0x2734b2['p']+'src/js/modules/main/apps/dashboards/views/general/user/mail/user.general.mail.html/user.general.mail.html',_0x2d53ef=_0x2734b2['p']+'src/js/modules/main/apps/dashboards/views/general/user/sms/user.general.sms.html/user.general.sms.html',_0x30d8a7=_0x2734b2['p']+_0x36e6f4('0x26ac'),_0x3bce68=_0x2734b2['p']+_0x36e6f4('0x244d'),_0x1eae26=_0x2734b2['p']+_0x36e6f4('0x131d');_0x24d9e8[_0x36e6f4('0x1294')]=['$scope','socket','chatInteractions','chatWebsites'];function _0x24d9e8(_0x499ad1,_0x4302a1,_0x1a7363,_0x310623){const _0x335cc2=_0x36e6f4,_0x422df3=this,_0x1d7fed=[];_0x422df3[_0x335cc2('0xe11')]={'format':'hh:mm:ss','unit':_0x335cc2('0x1aa6'),'trim':![]},_0x422df3[_0x335cc2('0x14d8')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x335cc2('0x5ca'),'avgTalkTime':_0x335cc2('0x5ca'),'answerRate':0x0,'abandonRate':0x0},_0x422df3[_0x335cc2('0x2136')]=_0x310623?_0x2cfb05()[_0x335cc2('0x155c')](_0x310623[_0x335cc2('0x269a')]?_0x310623['rows']:[],'id'):{},_0x422df3['onSaveChatInteraction']=_0x3f4261,_0x422df3[_0x335cc2('0xd31')]=_0x4ce25c,_0x4302a1['on'](_0x335cc2('0x2724'),_0x422df3['onSaveChatInteraction']),_0x4302a1['on'](_0x335cc2('0x2021'),_0x422df3[_0x335cc2('0xd31')]),_0x4c788b();function _0x34dfda(_0x41a08e,_0x45a608){const _0x306b0a=_0x335cc2;!_0x41a08e['closed']&&!_0x41a08e[_0x306b0a('0x122a')]&&_0x45a608&&(_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x288a')]+=0x1);!_0x41a08e[_0x306b0a('0xa5b')]&&_0x41a08e[_0x306b0a('0x122a')]&&!_0x2cfb05()[_0x306b0a('0x1257')](_0x1d7fed,_0x41a08e['id'])&&(_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x46a')]+=0x1,_0x1d7fed[_0x306b0a('0x1514')](_0x41a08e['id']),!_0x45a608&&_0x422df3[_0x306b0a('0x14d8')]['waiting']&&(_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x288a')]-=0x1));if(_0x41a08e[_0x306b0a('0xa5b')]&&_0x41a08e[_0x306b0a('0x12e8')]==='abandoned')_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x183f')]+=0x1,!_0x45a608&&_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x288a')]&&(_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x288a')]-=0x1);else{if(_0x41a08e[_0x306b0a('0xa5b')]&&!_0x41a08e[_0x306b0a('0x122a')]&&_0x41a08e[_0x306b0a('0x12e8')])_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x15a7')]+=0x1,!_0x45a608&&_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x288a')]&&(_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x288a')]-=0x1);else _0x41a08e[_0x306b0a('0xa5b')]&&_0x41a08e[_0x306b0a('0x122a')]&&(_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0xb76')]+=_0x24273b()(_0x41a08e[_0x306b0a('0x1dc6')])[_0x306b0a('0x884')](_0x24273b()(_0x41a08e[_0x306b0a('0x981')]),_0x422df3['config'][_0x306b0a('0x17db')]),_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x4c9')]+=_0x24273b()(_0x41a08e[_0x306b0a('0x981')])[_0x306b0a('0x884')](_0x24273b()(_0x41a08e['createdAt']),_0x422df3['config'][_0x306b0a('0x17db')]),_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x13d')]+=0x1,!_0x45a608&&_0x422df3[_0x306b0a('0x14d8')][_0x306b0a('0x46a')]&&(_0x422df3[_0x306b0a('0x14d8')]['talking']-=0x1));}_0x45a608&&(_0x422df3['inbound'][_0x306b0a('0x25e7')]+=0x1);}function _0x262f97(){const _0x25c90b=_0x335cc2;_0x422df3['inbound']['abandonRate']=Math['round']((_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0x183f')]+_0x422df3[_0x25c90b('0x14d8')]['unmanaged'])/(_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0x25e7')]-_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0x46a')]-_0x422df3[_0x25c90b('0x14d8')]['waiting'])*0x64,-0x2),_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0xc4f')]=Math[_0x25c90b('0xef')](_0x422df3['inbound'][_0x25c90b('0x13d')]/(_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0x25e7')]-_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0x46a')]-_0x422df3[_0x25c90b('0x14d8')]['waiting'])*0x64,-0x2),_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0x90a')]=_0x24273b()['duration'](Math[_0x25c90b('0xef')](_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0x4c9')]/_0x422df3['inbound'][_0x25c90b('0x13d')]),_0x422df3[_0x25c90b('0xe11')]['unit'])[_0x25c90b('0x128a')](_0x422df3[_0x25c90b('0xe11')]['format'],_0x422df3[_0x25c90b('0xe11')]),_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0x99c')]=_0x24273b()['duration'](Math[_0x25c90b('0xef')](_0x422df3['inbound'][_0x25c90b('0xb76')]/_0x422df3[_0x25c90b('0x14d8')][_0x25c90b('0x13d')]),_0x422df3[_0x25c90b('0xe11')][_0x25c90b('0x17db')])[_0x25c90b('0x128a')](_0x422df3[_0x25c90b('0xe11')][_0x25c90b('0x128a')],_0x422df3['config']);}function _0x4c788b(){const _0x35142a=_0x335cc2;if(Object[_0x35142a('0x14a4')](_0x422df3[_0x35142a('0x2136')])[_0x35142a('0x264b')]>0x0)for(let _0xac1188=0x0;_0xac1188<_0x1a7363[_0x35142a('0x269a')][_0x35142a('0x264b')];_0xac1188+=0x1){if(_0x3d6256(_0x1a7363['rows'][_0xac1188])){const _0x108de3=_0x1a7363['rows'][_0xac1188];_0x34dfda(_0x108de3,!![]),_0x262f97();}}}function _0x3d6256(_0x230cc8){const _0x584f06=_0x335cc2;if(_0x2cfb05()[_0x584f06('0x1798')](_0x422df3[_0x584f06('0x2136')],{'id':_0x2cfb05()[_0x584f06('0xa53')](_0x230cc8[_0x584f06('0x1e02')])}))return!![];return![];}function _0x1b7aa3(_0x4da9f6){const _0x22236d=_0x335cc2,_0x41fb60=_0x24273b()()['utcOffset'](0x0,!![])[_0x22236d('0x1659')](_0x22236d('0x16a')),_0x214221=_0x24273b()()[_0x22236d('0x13f2')](0x0,!![])[_0x22236d('0x2589')]('day');return _0x24273b()(_0x4da9f6)['utcOffset'](0x0,!![])['isBetween'](_0x41fb60,_0x214221);}function _0x3f4261(_0x1b49da){const _0x577804=_0x335cc2;_0x3d6256(_0x1b49da)&&_0x1b7aa3(_0x1b49da[_0x577804('0x262')])&&(_0x34dfda(_0x1b49da,!![]),_0x262f97());}function _0x4ce25c(_0x2c98ed){const _0x14baa6=_0x335cc2;_0x3d6256(_0x2c98ed)&&_0x1b7aa3(_0x2c98ed[_0x14baa6('0x262')])&&(_0x34dfda(_0x2c98ed,![]),_0x262f97());}_0x499ad1[_0x335cc2('0x3d2')](_0x335cc2('0x1c3f'),function(){const _0x283099=_0x335cc2;_0x4302a1[_0x283099('0x1800')](_0x283099('0x2724')),_0x4302a1['removeAllListeners']('chatInteraction:update');});}const _0x4daa12=_0x24d9e8;_0x315663[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x10eb'),_0x36e6f4('0x2661'),_0x36e6f4('0xfe3'),_0x36e6f4('0x744'),_0x36e6f4('0x13e7'),'initializeRealtimeCampaign','rpcCampaigns'];function _0x315663(_0x486f73,_0x11c0bb,_0x4c9d69,_0x101685,_0x49b8a1,_0x4a347e,_0x11956c,_0x30aba9){const _0x4d80b4=_0x36e6f4,_0x486001=this;_0x486001[_0x4d80b4('0xfe3')]=_0x101685?_0x2cfb05()[_0x4d80b4('0x155c')](_0x101685[_0x4d80b4('0x269a')]?_0x101685[_0x4d80b4('0x269a')]:[],'id'):{},_0x486001[_0x4d80b4('0x744')]=_0x49b8a1?_0x2cfb05()['keyBy'](_0x49b8a1[_0x4d80b4('0x269a')]?_0x49b8a1[_0x4d80b4('0x269a')]:[],'id'):{},_0x486001[_0x4d80b4('0x218f')]=_0x30aba9?_0x2cfb05()[_0x4d80b4('0x155c')](_0x30aba9[_0x4d80b4('0x269a')]?_0x30aba9[_0x4d80b4('0x269a')]:[],'id'):{},_0x486001[_0x4d80b4('0x681')]={'originated':0x0,'limitCalls':0x0},_0x486001[_0x4d80b4('0x14d8')]={'waiting':0x0,'talking':0x0,'pTalking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':'00:00:00','avgTalkTime':_0x4d80b4('0x5ca'),'answerRate':0x0,'abandonRate':0x0,'outboundDropCallsDayCallersExit':0x0,'outboundDropCallsDayTimeout':0x0},_0x486001['onSaveQueue']=_0x24d0f4,_0x486001[_0x4d80b4('0x1be7')]=_0x40732e,_0x4c9d69['onWithoutApply']('voice_queue:save',_0x486001[_0x4d80b4('0xefb')]),_0x486001[_0x4d80b4('0x277c')]=_0x11c0bb(function(){_0xfd2536(),_0x2ae867();},0x3e7),_0x4c9d69[_0x4d80b4('0xe82')](_0x4d80b4('0x3c8'),_0x486001[_0x4d80b4('0x1be7')]),_0xfd2536(),_0x2ae867();function _0xfd2536(){const _0xefe086=_0x4d80b4;_0x4a347e({'queues':_0x486001[_0xefe086('0xfe3')],'rpcQueues':_0x486001['rpcQueues']})[_0xefe086('0x1166')](function(_0x421882){const _0x2f3ab0=_0xefe086;_0x486001[_0x2f3ab0('0x14d8')]=_0x421882;});}function _0x2ae867(){const _0x50b36e=_0x4d80b4;_0x11956c({'rpcCampaigns':_0x486001[_0x50b36e('0x218f')]})[_0x50b36e('0x1166')](function(_0x139a86){const _0x4076c1=_0x50b36e;_0x486001[_0x4076c1('0x681')]=_0x139a86;});}function _0x24d0f4(_0x123723){const _0x1ee684=_0x4d80b4;_0x486001[_0x1ee684('0xfe3')][_0x123723['id']]&&(_0x486001['rpcQueues'][_0x123723['id']]&&(_0x486001[_0x1ee684('0x744')][_0x123723['id']]=_0x123723));}function _0x40732e(_0x3c9642){const _0x9c6f12=_0x4d80b4;_0x486001[_0x9c6f12('0x218f')][_0x3c9642['id']]&&(_0x486001[_0x9c6f12('0x218f')][_0x3c9642['id']]=_0x3c9642);}_0x486f73[_0x4d80b4('0x3d2')]('$destroy',function(){const _0xe98bd0=_0x4d80b4;_0x4c9d69['removeAllListeners']('voice_queue:save'),_0x4c9d69[_0xe98bd0('0x1800')](_0xe98bd0('0x3c8')),_0x486001['interval']&&_0x11c0bb[_0xe98bd0('0x3f')](_0x486001[_0xe98bd0('0x277c')]);});}const _0x57e5c7=_0x315663;_0x4a4161['$inject']=['$scope',_0x36e6f4('0x2661'),_0x36e6f4('0x2712'),'faxAccounts'];function _0x4a4161(_0x38ebf5,_0xbb2c5c,_0x1459ae,_0x181c62){const _0x29527f=_0x36e6f4,_0x59ac17=this,_0x2705a8=[];_0x59ac17[_0x29527f('0xe11')]={'format':_0x29527f('0x1c7e'),'unit':_0x29527f('0x1aa6'),'trim':![]},_0x59ac17[_0x29527f('0x14d8')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x29527f('0x5ca'),'avgTalkTime':_0x29527f('0x5ca'),'answerRate':0x0,'abandonRate':0x0},_0x59ac17['faxAccounts']=_0x181c62?_0x2cfb05()[_0x29527f('0x155c')](_0x181c62[_0x29527f('0x269a')]?_0x181c62['rows']:[],'id'):{},_0x59ac17[_0x29527f('0x273a')]=_0x142a81,_0x59ac17[_0x29527f('0x2637')]=_0x3fc070,_0xbb2c5c['on'](_0x29527f('0x1dc2'),_0x59ac17['onSaveFaxInteraction']),_0xbb2c5c['on'](_0x29527f('0x109c'),_0x59ac17[_0x29527f('0x2637')]),_0x5d6dc7();function _0x2079bc(_0x27b4d4,_0xefc79d){const _0x5cc110=_0x29527f;!_0x27b4d4[_0x5cc110('0xa5b')]&&!_0x27b4d4[_0x5cc110('0x122a')]&&_0xefc79d&&(_0x59ac17[_0x5cc110('0x14d8')]['waiting']+=0x1),!_0x27b4d4[_0x5cc110('0xa5b')]&&_0x27b4d4['UserId']&&!_0x2cfb05()['includes'](_0x2705a8,_0x27b4d4['id'])&&(_0x59ac17[_0x5cc110('0x14d8')][_0x5cc110('0x46a')]+=0x1,_0x2705a8[_0x5cc110('0x1514')](_0x27b4d4['id']),!_0xefc79d&&_0x59ac17['inbound'][_0x5cc110('0x288a')]&&(_0x59ac17['inbound'][_0x5cc110('0x288a')]-=0x1)),_0x27b4d4[_0x5cc110('0xa5b')]&&_0x27b4d4[_0x5cc110('0x122a')]&&(_0x59ac17[_0x5cc110('0x14d8')][_0x5cc110('0xb76')]+=_0x24273b()(_0x27b4d4[_0x5cc110('0x1dc6')])['diff'](_0x24273b()(_0x27b4d4[_0x5cc110('0x981')]),_0x59ac17[_0x5cc110('0xe11')][_0x5cc110('0x17db')]),_0x59ac17[_0x5cc110('0x14d8')][_0x5cc110('0x4c9')]+=_0x24273b()(_0x27b4d4[_0x5cc110('0x981')])['diff'](_0x24273b()(_0x27b4d4['createdAt']),_0x59ac17[_0x5cc110('0xe11')][_0x5cc110('0x17db')]),_0x59ac17[_0x5cc110('0x14d8')]['answered']+=0x1,!_0xefc79d&&_0x59ac17['inbound'][_0x5cc110('0x46a')]&&(_0x59ac17[_0x5cc110('0x14d8')][_0x5cc110('0x46a')]-=0x1)),_0x27b4d4[_0x5cc110('0xa5b')]&&!_0x27b4d4[_0x5cc110('0x122a')]&&(_0x59ac17[_0x5cc110('0x14d8')][_0x5cc110('0x15a7')]+=0x1,!_0xefc79d&&_0x59ac17[_0x5cc110('0x14d8')]['waiting']&&(_0x59ac17[_0x5cc110('0x14d8')]['waiting']-=0x1)),_0xefc79d&&(_0x59ac17[_0x5cc110('0x14d8')][_0x5cc110('0x25e7')]+=0x1);}function _0x3d03fd(){const _0x26491c=_0x29527f;_0x59ac17[_0x26491c('0x14d8')]['abandonRate']=Math[_0x26491c('0xef')]((_0x59ac17[_0x26491c('0x14d8')]['abandoned']+_0x59ac17[_0x26491c('0x14d8')][_0x26491c('0x15a7')])/(_0x59ac17[_0x26491c('0x14d8')]['total']-_0x59ac17[_0x26491c('0x14d8')][_0x26491c('0x46a')]-_0x59ac17['inbound'][_0x26491c('0x288a')])*0x64,-0x2),_0x59ac17[_0x26491c('0x14d8')][_0x26491c('0xc4f')]=Math['round'](_0x59ac17[_0x26491c('0x14d8')][_0x26491c('0x13d')]/(_0x59ac17[_0x26491c('0x14d8')][_0x26491c('0x25e7')]-_0x59ac17['inbound'][_0x26491c('0x46a')]-_0x59ac17['inbound']['waiting'])*0x64,-0x2),_0x59ac17[_0x26491c('0x14d8')][_0x26491c('0x90a')]=_0x24273b()[_0x26491c('0x12fc')](Math[_0x26491c('0xef')](_0x59ac17[_0x26491c('0x14d8')][_0x26491c('0x4c9')]/_0x59ac17[_0x26491c('0x14d8')]['answered']),_0x59ac17[_0x26491c('0xe11')][_0x26491c('0x17db')])['format'](_0x59ac17[_0x26491c('0xe11')][_0x26491c('0x128a')],_0x59ac17[_0x26491c('0xe11')]),_0x59ac17[_0x26491c('0x14d8')]['avgTalkTime']=_0x24273b()['duration'](Math['round'](_0x59ac17['inbound'][_0x26491c('0xb76')]/_0x59ac17[_0x26491c('0x14d8')][_0x26491c('0x13d')]),_0x59ac17[_0x26491c('0xe11')][_0x26491c('0x17db')])['format'](_0x59ac17[_0x26491c('0xe11')][_0x26491c('0x128a')],_0x59ac17[_0x26491c('0xe11')]);}function _0x5d6dc7(){const _0x3758c0=_0x29527f;if(Object['keys'](_0x59ac17[_0x3758c0('0xd6c')])[_0x3758c0('0x264b')]>0x0)for(let _0x447033=0x0;_0x447033<_0x1459ae[_0x3758c0('0x269a')][_0x3758c0('0x264b')];_0x447033+=0x1){if(_0x3298ed(_0x1459ae[_0x3758c0('0x269a')][_0x447033])){const _0x24fb6f=_0x1459ae[_0x3758c0('0x269a')][_0x447033];_0x2079bc(_0x24fb6f,!![]),_0x3d03fd();}}}function _0x3298ed(_0xd4b1a){const _0x42b106=_0x29527f;if(_0x2cfb05()['some'](_0x59ac17[_0x42b106('0xd6c')],{'id':_0x2cfb05()['toNumber'](_0xd4b1a['FaxAccountId'])}))return!![];return![];}function _0x1896ac(_0xa3d8d6){const _0x3503c8=_0x29527f,_0x4387b2=_0x24273b()()[_0x3503c8('0x13f2')](0x0,!![])[_0x3503c8('0x1659')](_0x3503c8('0x16a')),_0xaaf3f6=_0x24273b()()[_0x3503c8('0x13f2')](0x0,!![])['endOf'](_0x3503c8('0x16a'));return _0x24273b()(_0xa3d8d6)[_0x3503c8('0x13f2')](0x0,!![])[_0x3503c8('0x3a6')](_0x4387b2,_0xaaf3f6);}function _0x142a81(_0x43a04a){const _0x3e02f5=_0x29527f;_0x3298ed(_0x43a04a)&&_0x1896ac(_0x43a04a[_0x3e02f5('0x262')])&&(_0x2079bc(_0x43a04a,!![]),_0x3d03fd());}function _0x3fc070(_0x52eb34){const _0x532da9=_0x29527f;_0x3298ed(_0x52eb34)&&_0x1896ac(_0x52eb34[_0x532da9('0x262')])&&(_0x2079bc(_0x52eb34,![]),_0x3d03fd());}_0x38ebf5['$on']('$destroy',function(){const _0xd0c367=_0x29527f;_0xbb2c5c['removeAllListeners']('faxInteraction:save'),_0xbb2c5c['removeAllListeners'](_0xd0c367('0x109c'));});}const _0x2e85f7=_0x4a4161;_0x38fabd[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x2661'),_0x36e6f4('0x17c0'),'mailAccounts'];function _0x38fabd(_0x45ec8e,_0x13a1e5,_0x2dabdd,_0x11921d){const _0x51ed25=_0x36e6f4,_0x51935a=this,_0x36ff9=[];_0x51935a[_0x51ed25('0xe11')]={'format':'hh:mm:ss','unit':'seconds','trim':![]},_0x51935a[_0x51ed25('0x14d8')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x51ed25('0x5ca'),'avgTalkTime':_0x51ed25('0x5ca'),'answerRate':0x0,'abandonRate':0x0},_0x51935a[_0x51ed25('0xf85')]=_0x11921d?_0x2cfb05()[_0x51ed25('0x155c')](_0x11921d[_0x51ed25('0x269a')]?_0x11921d['rows']:[],'id'):{},_0x51935a['onSaveMailInteraction']=_0x312a69,_0x51935a['onUpdateMailInteraction']=_0x313190,_0x13a1e5['on']('mailInteraction:save',_0x51935a[_0x51ed25('0xc1b')]),_0x13a1e5['on'](_0x51ed25('0x248c'),_0x51935a[_0x51ed25('0x1d0e')]),_0x5c2d4e();function _0x48e5d9(_0x4c80ff,_0x21f030){const _0x10d0d2=_0x51ed25;!_0x4c80ff[_0x10d0d2('0xa5b')]&&!_0x4c80ff[_0x10d0d2('0x122a')]&&_0x21f030&&(_0x51935a[_0x10d0d2('0x14d8')][_0x10d0d2('0x288a')]+=0x1),!_0x4c80ff['closed']&&_0x4c80ff[_0x10d0d2('0x122a')]&&!_0x2cfb05()['includes'](_0x36ff9,_0x4c80ff['id'])&&(_0x51935a[_0x10d0d2('0x14d8')][_0x10d0d2('0x46a')]+=0x1,_0x36ff9['push'](_0x4c80ff['id']),!_0x21f030&&_0x51935a[_0x10d0d2('0x14d8')][_0x10d0d2('0x288a')]&&(_0x51935a[_0x10d0d2('0x14d8')]['waiting']-=0x1)),_0x4c80ff[_0x10d0d2('0xa5b')]&&_0x4c80ff[_0x10d0d2('0x122a')]&&(_0x51935a['inbound'][_0x10d0d2('0xb76')]+=_0x24273b()(_0x4c80ff[_0x10d0d2('0x1dc6')])[_0x10d0d2('0x884')](_0x24273b()(_0x4c80ff[_0x10d0d2('0x981')]),_0x51935a[_0x10d0d2('0xe11')][_0x10d0d2('0x17db')]),_0x51935a[_0x10d0d2('0x14d8')][_0x10d0d2('0x4c9')]+=_0x24273b()(_0x4c80ff[_0x10d0d2('0x981')])[_0x10d0d2('0x884')](_0x24273b()(_0x4c80ff[_0x10d0d2('0x262')]),_0x51935a[_0x10d0d2('0xe11')][_0x10d0d2('0x17db')]),_0x51935a['inbound']['answered']+=0x1,!_0x21f030&&_0x51935a[_0x10d0d2('0x14d8')][_0x10d0d2('0x46a')]&&(_0x51935a['inbound']['talking']-=0x1)),_0x4c80ff[_0x10d0d2('0xa5b')]&&!_0x4c80ff[_0x10d0d2('0x122a')]&&(_0x51935a['inbound'][_0x10d0d2('0x15a7')]+=0x1,!_0x21f030&&_0x51935a[_0x10d0d2('0x14d8')][_0x10d0d2('0x288a')]&&(_0x51935a[_0x10d0d2('0x14d8')][_0x10d0d2('0x288a')]-=0x1)),_0x21f030&&(_0x51935a['inbound'][_0x10d0d2('0x25e7')]+=0x1);}function _0x240fe8(){const _0x4d3a2e=_0x51ed25;_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x2245')]=Math[_0x4d3a2e('0xef')]((_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x183f')]+_0x51935a['inbound'][_0x4d3a2e('0x15a7')])/(_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x25e7')]-_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x46a')]-_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x288a')])*0x64,-0x2),_0x51935a['inbound'][_0x4d3a2e('0xc4f')]=Math[_0x4d3a2e('0xef')](_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x13d')]/(_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x25e7')]-_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x46a')]-_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x288a')])*0x64,-0x2),_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x90a')]=_0x24273b()[_0x4d3a2e('0x12fc')](Math[_0x4d3a2e('0xef')](_0x51935a[_0x4d3a2e('0x14d8')][_0x4d3a2e('0x4c9')]/_0x51935a['inbound'][_0x4d3a2e('0x13d')]),_0x51935a['config'][_0x4d3a2e('0x17db')])[_0x4d3a2e('0x128a')](_0x51935a[_0x4d3a2e('0xe11')][_0x4d3a2e('0x128a')],_0x51935a[_0x4d3a2e('0xe11')]),_0x51935a['inbound'][_0x4d3a2e('0x99c')]=_0x24273b()[_0x4d3a2e('0x12fc')](Math[_0x4d3a2e('0xef')](_0x51935a[_0x4d3a2e('0x14d8')]['sumBillable']/_0x51935a['inbound'][_0x4d3a2e('0x13d')]),_0x51935a[_0x4d3a2e('0xe11')]['unit'])['format'](_0x51935a[_0x4d3a2e('0xe11')][_0x4d3a2e('0x128a')],_0x51935a['config']);}function _0x5c2d4e(){const _0x4934f2=_0x51ed25;if(Object[_0x4934f2('0x14a4')](_0x51935a[_0x4934f2('0xf85')])[_0x4934f2('0x264b')]>0x0)for(let _0xe755b1=0x0;_0xe755b1<_0x2dabdd[_0x4934f2('0x269a')]['length'];_0xe755b1+=0x1){if(_0x54480b(_0x2dabdd[_0x4934f2('0x269a')][_0xe755b1])){const _0x41ee1b=_0x2dabdd[_0x4934f2('0x269a')][_0xe755b1];_0x48e5d9(_0x41ee1b,!![]),_0x240fe8();}}}function _0x54480b(_0x5c6fd1){const _0x53a037=_0x51ed25;if(_0x2cfb05()[_0x53a037('0x1798')](_0x51935a['mailAccounts'],{'id':_0x2cfb05()['toNumber'](_0x5c6fd1[_0x53a037('0x56')])}))return!![];return![];}function _0x4e4db8(_0x58cacd){const _0x11da83=_0x51ed25,_0x12246b=_0x24273b()()[_0x11da83('0x13f2')](0x0,!![])['startOf'](_0x11da83('0x16a')),_0x3f88c0=_0x24273b()()['utcOffset'](0x0,!![])[_0x11da83('0x2589')]('day');return _0x24273b()(_0x58cacd)[_0x11da83('0x13f2')](0x0,!![])[_0x11da83('0x3a6')](_0x12246b,_0x3f88c0);}function _0x312a69(_0x2ef2a0){const _0x58d979=_0x51ed25;_0x54480b(_0x2ef2a0)&&_0x4e4db8(_0x2ef2a0[_0x58d979('0x262')])&&(_0x48e5d9(_0x2ef2a0,!![]),_0x240fe8());}function _0x313190(_0x4e7a90){const _0x1405d1=_0x51ed25;_0x54480b(_0x4e7a90)&&_0x4e4db8(_0x4e7a90[_0x1405d1('0x262')])&&(_0x48e5d9(_0x4e7a90,![]),_0x240fe8());}_0x45ec8e[_0x51ed25('0x3d2')](_0x51ed25('0x1c3f'),function(){const _0x177f25=_0x51ed25;_0x13a1e5['removeAllListeners'](_0x177f25('0x2332')),_0x13a1e5[_0x177f25('0x1800')](_0x177f25('0x248c'));});}const _0x38f322=_0x38fabd;_0x28e5e7[_0x36e6f4('0x1294')]=['$scope','socket',_0x36e6f4('0x1388'),_0x36e6f4('0x28ff')];function _0x28e5e7(_0x5676bd,_0x319906,_0x283fa7,_0x1de08f){const _0x2c9cda=_0x36e6f4,_0x40871d=this,_0x43b41b=[];_0x40871d[_0x2c9cda('0xe11')]={'format':_0x2c9cda('0x1c7e'),'unit':_0x2c9cda('0x1aa6'),'trim':![]},_0x40871d[_0x2c9cda('0x14d8')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':'00:00:00','avgTalkTime':'00:00:00','answerRate':0x0,'abandonRate':0x0},_0x40871d[_0x2c9cda('0x28ff')]=_0x1de08f?_0x2cfb05()[_0x2c9cda('0x155c')](_0x1de08f[_0x2c9cda('0x269a')]?_0x1de08f[_0x2c9cda('0x269a')]:[],'id'):{},_0x40871d[_0x2c9cda('0x7a9')]=_0x4a49cd,_0x40871d[_0x2c9cda('0x1769')]=_0x1ff516,_0x319906['on'](_0x2c9cda('0x14c9'),_0x40871d[_0x2c9cda('0x7a9')]),_0x319906['on'](_0x2c9cda('0x130b'),_0x40871d['onUpdateOpenchannelInteraction']),_0x1fb1e9();function _0x2a0e4f(_0x2eb6c5,_0x44d042){const _0x2ee02e=_0x2c9cda;!_0x2eb6c5[_0x2ee02e('0xa5b')]&&!_0x2eb6c5[_0x2ee02e('0x122a')]&&_0x44d042&&(_0x40871d[_0x2ee02e('0x14d8')][_0x2ee02e('0x288a')]+=0x1),!_0x2eb6c5['closed']&&_0x2eb6c5[_0x2ee02e('0x122a')]&&!_0x2cfb05()['includes'](_0x43b41b,_0x2eb6c5['id'])&&(_0x40871d[_0x2ee02e('0x14d8')][_0x2ee02e('0x46a')]+=0x1,_0x43b41b['push'](_0x2eb6c5['id']),!_0x44d042&&_0x40871d[_0x2ee02e('0x14d8')]['waiting']&&(_0x40871d['inbound'][_0x2ee02e('0x288a')]-=0x1)),_0x2eb6c5['closed']&&_0x2eb6c5[_0x2ee02e('0x122a')]&&(_0x40871d[_0x2ee02e('0x14d8')]['sumBillable']+=_0x24273b()(_0x2eb6c5['closedAt'])[_0x2ee02e('0x884')](_0x24273b()(_0x2eb6c5['read1stAt']),_0x40871d[_0x2ee02e('0xe11')][_0x2ee02e('0x17db')]),_0x40871d[_0x2ee02e('0x14d8')]['sumHoldTime']+=_0x24273b()(_0x2eb6c5[_0x2ee02e('0x981')])[_0x2ee02e('0x884')](_0x24273b()(_0x2eb6c5[_0x2ee02e('0x262')]),_0x40871d[_0x2ee02e('0xe11')][_0x2ee02e('0x17db')]),_0x40871d[_0x2ee02e('0x14d8')][_0x2ee02e('0x13d')]+=0x1,!_0x44d042&&_0x40871d[_0x2ee02e('0x14d8')][_0x2ee02e('0x46a')]&&(_0x40871d['inbound'][_0x2ee02e('0x46a')]-=0x1)),_0x2eb6c5['closed']&&!_0x2eb6c5[_0x2ee02e('0x122a')]&&(_0x40871d[_0x2ee02e('0x14d8')]['unmanaged']+=0x1,!_0x44d042&&_0x40871d[_0x2ee02e('0x14d8')]['waiting']&&(_0x40871d[_0x2ee02e('0x14d8')][_0x2ee02e('0x288a')]-=0x1)),_0x44d042&&(_0x40871d[_0x2ee02e('0x14d8')][_0x2ee02e('0x25e7')]+=0x1);}function _0x1ac468(){const _0x494f3d=_0x2c9cda;_0x40871d[_0x494f3d('0x14d8')][_0x494f3d('0x2245')]=Math[_0x494f3d('0xef')]((_0x40871d['inbound']['abandoned']+_0x40871d[_0x494f3d('0x14d8')]['unmanaged'])/(_0x40871d[_0x494f3d('0x14d8')][_0x494f3d('0x25e7')]-_0x40871d['inbound'][_0x494f3d('0x46a')]-_0x40871d[_0x494f3d('0x14d8')]['waiting'])*0x64,-0x2),_0x40871d['inbound'][_0x494f3d('0xc4f')]=Math[_0x494f3d('0xef')](_0x40871d['inbound'][_0x494f3d('0x13d')]/(_0x40871d[_0x494f3d('0x14d8')][_0x494f3d('0x25e7')]-_0x40871d[_0x494f3d('0x14d8')]['talking']-_0x40871d[_0x494f3d('0x14d8')][_0x494f3d('0x288a')])*0x64,-0x2),_0x40871d[_0x494f3d('0x14d8')][_0x494f3d('0x90a')]=_0x24273b()[_0x494f3d('0x12fc')](Math['round'](_0x40871d[_0x494f3d('0x14d8')][_0x494f3d('0x4c9')]/_0x40871d[_0x494f3d('0x14d8')][_0x494f3d('0x13d')]),_0x40871d[_0x494f3d('0xe11')]['unit'])[_0x494f3d('0x128a')](_0x40871d[_0x494f3d('0xe11')][_0x494f3d('0x128a')],_0x40871d[_0x494f3d('0xe11')]),_0x40871d[_0x494f3d('0x14d8')][_0x494f3d('0x99c')]=_0x24273b()[_0x494f3d('0x12fc')](Math[_0x494f3d('0xef')](_0x40871d[_0x494f3d('0x14d8')]['sumBillable']/_0x40871d['inbound'][_0x494f3d('0x13d')]),_0x40871d[_0x494f3d('0xe11')]['unit'])['format'](_0x40871d['config'][_0x494f3d('0x128a')],_0x40871d[_0x494f3d('0xe11')]);}function _0x1fb1e9(){const _0x4b642e=_0x2c9cda;if(Object[_0x4b642e('0x14a4')](_0x40871d['openchannelAccounts'])[_0x4b642e('0x264b')]>0x0)for(let _0xfcdbad=0x0;_0xfcdbad<_0x283fa7[_0x4b642e('0x269a')][_0x4b642e('0x264b')];_0xfcdbad+=0x1){if(_0x40c44a(_0x283fa7[_0x4b642e('0x269a')][_0xfcdbad])){const _0x995870=_0x283fa7['rows'][_0xfcdbad];_0x2a0e4f(_0x995870,!![]),_0x1ac468();}}}function _0x40c44a(_0x5c7964){const _0x577f49=_0x2c9cda;if(_0x2cfb05()[_0x577f49('0x1798')](_0x40871d[_0x577f49('0x28ff')],{'id':_0x2cfb05()['toNumber'](_0x5c7964[_0x577f49('0xb8')])}))return!![];return![];}function _0x3d651f(_0x30f888){const _0x5a6944=_0x2c9cda,_0x513afd=_0x24273b()()[_0x5a6944('0x13f2')](0x0,!![])['startOf'](_0x5a6944('0x16a')),_0x3ece49=_0x24273b()()['utcOffset'](0x0,!![])[_0x5a6944('0x2589')](_0x5a6944('0x16a'));return _0x24273b()(_0x30f888)[_0x5a6944('0x13f2')](0x0,!![])[_0x5a6944('0x3a6')](_0x513afd,_0x3ece49);}function _0x4a49cd(_0x367b42){const _0x3bd09b=_0x2c9cda;_0x40c44a(_0x367b42)&&_0x3d651f(_0x367b42[_0x3bd09b('0x262')])&&(_0x2a0e4f(_0x367b42,!![]),_0x1ac468());}function _0x1ff516(_0x477fff){_0x40c44a(_0x477fff)&&_0x3d651f(_0x477fff['createdAt'])&&(_0x2a0e4f(_0x477fff,![]),_0x1ac468());}_0x5676bd['$on']('$destroy',function(){const _0x1cfac5=_0x2c9cda;_0x319906[_0x1cfac5('0x1800')](_0x1cfac5('0x14c9')),_0x319906[_0x1cfac5('0x1800')](_0x1cfac5('0x130b'));});}const _0x49dfe1=_0x28e5e7;_0x9ac439['$inject']=[_0x36e6f4('0x36f'),'socket',_0x36e6f4('0xb0e'),_0x36e6f4('0x1d76')];function _0x9ac439(_0x5eab51,_0x424f01,_0x234b1f,_0x1201c2){const _0x2bd5fb=_0x36e6f4,_0x38d33c=this,_0x10fbb5=[];_0x38d33c[_0x2bd5fb('0xe11')]={'format':'hh:mm:ss','unit':'seconds','trim':![]},_0x38d33c[_0x2bd5fb('0x14d8')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x2bd5fb('0x5ca'),'avgTalkTime':_0x2bd5fb('0x5ca'),'answerRate':0x0,'abandonRate':0x0},_0x38d33c[_0x2bd5fb('0x1d76')]=_0x1201c2?_0x2cfb05()[_0x2bd5fb('0x155c')](_0x1201c2[_0x2bd5fb('0x269a')]?_0x1201c2[_0x2bd5fb('0x269a')]:[],'id'):{},_0x38d33c[_0x2bd5fb('0x129e')]=_0x2e3bd9,_0x38d33c[_0x2bd5fb('0xc2f')]=_0x2b51ac,_0x424f01['on']('smsInteraction:save',_0x38d33c['onSaveSmsInteraction']),_0x424f01['on'](_0x2bd5fb('0xd0'),_0x38d33c[_0x2bd5fb('0xc2f')]),_0x10a2f7();function _0x1d0a86(_0x22bb67,_0x33a0f4){const _0x24e792=_0x2bd5fb;!_0x22bb67[_0x24e792('0xa5b')]&&!_0x22bb67[_0x24e792('0x122a')]&&_0x33a0f4&&(_0x38d33c['inbound']['waiting']+=0x1),!_0x22bb67[_0x24e792('0xa5b')]&&_0x22bb67[_0x24e792('0x122a')]&&!_0x2cfb05()[_0x24e792('0x1257')](_0x10fbb5,_0x22bb67['id'])&&(_0x38d33c[_0x24e792('0x14d8')][_0x24e792('0x46a')]+=0x1,_0x10fbb5[_0x24e792('0x1514')](_0x22bb67['id']),!_0x33a0f4&&_0x38d33c[_0x24e792('0x14d8')]['waiting']&&(_0x38d33c[_0x24e792('0x14d8')][_0x24e792('0x288a')]-=0x1)),_0x22bb67[_0x24e792('0xa5b')]&&_0x22bb67[_0x24e792('0x122a')]&&(_0x38d33c[_0x24e792('0x14d8')][_0x24e792('0xb76')]+=_0x24273b()(_0x22bb67['closedAt'])[_0x24e792('0x884')](_0x24273b()(_0x22bb67[_0x24e792('0x981')]),_0x38d33c['config'][_0x24e792('0x17db')]),_0x38d33c[_0x24e792('0x14d8')][_0x24e792('0x4c9')]+=_0x24273b()(_0x22bb67['read1stAt'])['diff'](_0x24273b()(_0x22bb67[_0x24e792('0x262')]),_0x38d33c[_0x24e792('0xe11')]['unit']),_0x38d33c[_0x24e792('0x14d8')][_0x24e792('0x13d')]+=0x1,!_0x33a0f4&&_0x38d33c['inbound']['talking']&&(_0x38d33c[_0x24e792('0x14d8')]['talking']-=0x1)),_0x22bb67[_0x24e792('0xa5b')]&&!_0x22bb67[_0x24e792('0x122a')]&&(_0x38d33c[_0x24e792('0x14d8')]['unmanaged']+=0x1,!_0x33a0f4&&_0x38d33c[_0x24e792('0x14d8')][_0x24e792('0x288a')]&&(_0x38d33c[_0x24e792('0x14d8')][_0x24e792('0x288a')]-=0x1)),_0x33a0f4&&(_0x38d33c['inbound'][_0x24e792('0x25e7')]+=0x1);}function _0x76236a(){const _0x13b9e0=_0x2bd5fb;_0x38d33c[_0x13b9e0('0x14d8')]['abandonRate']=Math['round']((_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0x183f')]+_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0x15a7')])/(_0x38d33c['inbound'][_0x13b9e0('0x25e7')]-_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0x46a')]-_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0x288a')])*0x64,-0x2),_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0xc4f')]=Math[_0x13b9e0('0xef')](_0x38d33c[_0x13b9e0('0x14d8')]['answered']/(_0x38d33c['inbound']['total']-_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0x46a')]-_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0x288a')])*0x64,-0x2),_0x38d33c[_0x13b9e0('0x14d8')]['avgHoldTime']=_0x24273b()[_0x13b9e0('0x12fc')](Math[_0x13b9e0('0xef')](_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0x4c9')]/_0x38d33c['inbound'][_0x13b9e0('0x13d')]),_0x38d33c[_0x13b9e0('0xe11')][_0x13b9e0('0x17db')])[_0x13b9e0('0x128a')](_0x38d33c['config'][_0x13b9e0('0x128a')],_0x38d33c[_0x13b9e0('0xe11')]),_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0x99c')]=_0x24273b()['duration'](Math[_0x13b9e0('0xef')](_0x38d33c[_0x13b9e0('0x14d8')]['sumBillable']/_0x38d33c[_0x13b9e0('0x14d8')][_0x13b9e0('0x13d')]),_0x38d33c[_0x13b9e0('0xe11')][_0x13b9e0('0x17db')])[_0x13b9e0('0x128a')](_0x38d33c[_0x13b9e0('0xe11')][_0x13b9e0('0x128a')],_0x38d33c[_0x13b9e0('0xe11')]);}function _0x10a2f7(){const _0x227ac6=_0x2bd5fb;if(Object['keys'](_0x38d33c['smsAccounts'])['length']>0x0)for(let _0xba4a32=0x0;_0xba4a32<_0x234b1f[_0x227ac6('0x269a')][_0x227ac6('0x264b')];_0xba4a32+=0x1){if(_0x38e227(_0x234b1f[_0x227ac6('0x269a')][_0xba4a32])){const _0x2e2adc=_0x234b1f[_0x227ac6('0x269a')][_0xba4a32];_0x1d0a86(_0x2e2adc,!![]),_0x76236a();}}}function _0x38e227(_0x817e7c){const _0xbac722=_0x2bd5fb;if(_0x2cfb05()['some'](_0x38d33c[_0xbac722('0x1d76')],{'id':_0x2cfb05()[_0xbac722('0xa53')](_0x817e7c[_0xbac722('0xa74')])}))return!![];return![];}function _0x4b0eee(_0x15329e){const _0x1e045a=_0x2bd5fb,_0x10bcc2=_0x24273b()()[_0x1e045a('0x13f2')](0x0,!![])[_0x1e045a('0x1659')](_0x1e045a('0x16a')),_0x5d7c39=_0x24273b()()['utcOffset'](0x0,!![])[_0x1e045a('0x2589')](_0x1e045a('0x16a'));return _0x24273b()(_0x15329e)[_0x1e045a('0x13f2')](0x0,!![])[_0x1e045a('0x3a6')](_0x10bcc2,_0x5d7c39);}function _0x2e3bd9(_0x2f83b9){const _0x1ba39b=_0x2bd5fb;_0x38e227(_0x2f83b9)&&_0x4b0eee(_0x2f83b9[_0x1ba39b('0x262')])&&(_0x1d0a86(_0x2f83b9,!![]),_0x76236a());}function _0x2b51ac(_0x213c2){const _0x1cdb55=_0x2bd5fb;_0x38e227(_0x213c2)&&_0x4b0eee(_0x213c2[_0x1cdb55('0x262')])&&(_0x1d0a86(_0x213c2,![]),_0x76236a());}_0x5eab51[_0x2bd5fb('0x3d2')]('$destroy',function(){const _0x117df0=_0x2bd5fb;_0x424f01[_0x117df0('0x1800')]('smsInteraction:save'),_0x424f01[_0x117df0('0x1800')](_0x117df0('0xd0'));});}const _0x11056b=_0x9ac439;_0x4b7a3e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x21ef'),'license'],_0x18c074['$inject']=['$q'],_0x4c6969[_0x36e6f4('0x1294')]=['$q'];function _0x4c6969(_0x3e63a1){const _0x49eaa4=[],_0x260b3d=function(){const _0x5e1aa9=a0_0x3f2c,_0x4f7c6a=_0x49eaa4[0x0],_0x228962={'waiting':0x0,'talking':0x0,'pTalking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':'00:00:00','avgTalkTime':_0x5e1aa9('0x5ca'),'answerRate':0x0,'abandonRate':0x0,'originated':0x0,'outboundDropCallsDayCallersExit':0x0,'outboundDropCallsDayTimeout':0x0};_0x2cfb05()[_0x5e1aa9('0x941')](_0x4f7c6a[_0x5e1aa9('0x7a7')],function(_0x322392,_0x192a78){const _0x3262e7=_0x5e1aa9;_0x4f7c6a[_0x3262e7('0x744')][_0x192a78]&&(_0x228962[_0x3262e7('0x288a')]+=_0x4f7c6a[_0x3262e7('0x744')][_0x192a78][_0x3262e7('0x288a')]||0x0,_0x228962['talking']+=(_0x4f7c6a[_0x3262e7('0x744')][_0x192a78]['talking']||0x0)+(_0x4f7c6a['rpcQueues'][_0x192a78][_0x3262e7('0x67d')]||0x0),_0x228962[_0x3262e7('0x13d')]+=_0x4f7c6a[_0x3262e7('0x744')][_0x192a78]['answered']||0x0,_0x228962[_0x3262e7('0x183f')]+=_0x4f7c6a[_0x3262e7('0x744')][_0x192a78][_0x3262e7('0x183f')]||0x0,_0x228962[_0x3262e7('0x4c9')]+=_0x4f7c6a[_0x3262e7('0x744')][_0x192a78][_0x3262e7('0x4c9')]||0x0,_0x228962['sumBillable']+=_0x4f7c6a[_0x3262e7('0x744')][_0x192a78]['sumBillable']||0x0,_0x228962[_0x3262e7('0x25e7')]+=_0x4f7c6a['rpcQueues'][_0x192a78][_0x3262e7('0x25e7')]||0x0,_0x228962[_0x3262e7('0x20ab')]+=_0x4f7c6a[_0x3262e7('0x744')][_0x192a78][_0x3262e7('0x20ab')]||0x0,_0x228962['outboundDropCallsDayCallersExit']+=_0x4f7c6a[_0x3262e7('0x744')][_0x192a78][_0x3262e7('0xa56')]||0x0,_0x228962['outboundDropCallsDayTimeout']+=_0x4f7c6a[_0x3262e7('0x744')][_0x192a78][_0x3262e7('0xb51')]||0x0);});const _0x26c495=_0x228962[_0x5e1aa9('0x25e7')]-_0x228962[_0x5e1aa9('0x13d')]-_0x228962[_0x5e1aa9('0x183f')];_0x228962['unmanaged']=_0x26c495>0x0?_0x26c495:0x0,_0x228962['avgHoldTime']=Math[_0x5e1aa9('0xef')](_0x228962[_0x5e1aa9('0x25e7')]>0x0?_0x228962['sumHoldTime']/_0x228962[_0x5e1aa9('0x25e7')]:0x0),_0x228962[_0x5e1aa9('0x90a')]=new Date(_0x228962[_0x5e1aa9('0x90a')]*0x3e8)[_0x5e1aa9('0x10ee')]()[_0x5e1aa9('0x186a')](0xb,0x8),_0x228962[_0x5e1aa9('0x99c')]=Math[_0x5e1aa9('0xef')](_0x228962['answered']>0x0?_0x228962[_0x5e1aa9('0xb76')]/_0x228962[_0x5e1aa9('0x13d')]:0x0),_0x228962[_0x5e1aa9('0x99c')]=new Date(_0x228962['avgTalkTime']*0x3e8)[_0x5e1aa9('0x10ee')]()['substr'](0xb,0x8),_0x228962[_0x5e1aa9('0xc4f')]=Math[_0x5e1aa9('0xef')]((_0x228962[_0x5e1aa9('0x25e7')]>0x0?_0x228962['answered']/_0x228962[_0x5e1aa9('0x25e7')]*0x64:0x0)*Math[_0x5e1aa9('0x1834')](0xa,0x1))/Math[_0x5e1aa9('0x1834')](0xa,0x1),_0x228962[_0x5e1aa9('0x2245')]=Math[_0x5e1aa9('0xef')]((_0x228962['total']>0x0?_0x228962[_0x5e1aa9('0x183f')]/_0x228962[_0x5e1aa9('0x25e7')]*0x64:0x0)*Math[_0x5e1aa9('0x1834')](0xa,0x1))/Math[_0x5e1aa9('0x1834')](0xa,0x1),_0x228962[_0x5e1aa9('0x1c00')]=Math[_0x5e1aa9('0xef')]((_0x228962[_0x5e1aa9('0x25e7')]>0x0?_0x228962[_0x5e1aa9('0xb51')]/_0x228962[_0x5e1aa9('0x25e7')]*0x64:0x0)*Math[_0x5e1aa9('0x1834')](0xa,0x1))/Math[_0x5e1aa9('0x1834')](0xa,0x1),_0x228962['outboundAbandonRate']=Math[_0x5e1aa9('0xef')]((_0x228962[_0x5e1aa9('0x25e7')]>0x0?_0x228962[_0x5e1aa9('0xa56')]/_0x228962['total']*0x64:0x0)*Math[_0x5e1aa9('0x1834')](0xa,0x1))/Math[_0x5e1aa9('0x1834')](0xa,0x1),_0x228962[_0x5e1aa9('0xa6f')]=0x64-_0x228962['outboundDropRate']-_0x228962[_0x5e1aa9('0x2903')]>0x0&&(_0x228962[_0x5e1aa9('0x25e7')]||0x0>0x0)?0x64-_0x228962[_0x5e1aa9('0x1c00')]-_0x228962[_0x5e1aa9('0x2903')]:0x0,_0x49eaa4[_0x5e1aa9('0x49b')](),_0x4f7c6a[_0x5e1aa9('0x24d8')][_0x5e1aa9('0x18af')](_0x228962),_0x49eaa4[_0x5e1aa9('0x264b')]>0x0&&_0x260b3d();};return function(_0x206703){const _0x5ef6de=a0_0x3f2c,_0x4b44e5=_0x3e63a1['defer']();return _0x49eaa4[_0x5ef6de('0x1514')]({'queues':_0x206703[_0x5ef6de('0x7a7')],'rpcQueues':_0x206703['rpcQueues'],'defer':_0x4b44e5}),_0x49eaa4['length']===0x1&&_0x260b3d(),_0x4b44e5[_0x5ef6de('0x1f48')];};}function _0x18c074(_0x201ff0){const _0x10ddc3=[],_0x46eba9=function(){const _0x28037e=a0_0x3f2c,_0x204d0d=_0x10ddc3[0x0],_0x587609={'originated':0x0,'limitCalls':0x0};_0x2cfb05()[_0x28037e('0x941')](_0x204d0d[_0x28037e('0x218f')],function(_0x24d76a,_0x43cb33){const _0x3d9bb7=_0x28037e;_0x204d0d[_0x3d9bb7('0x218f')][_0x43cb33]&&(_0x587609[_0x3d9bb7('0x20ab')]+=_0x204d0d[_0x3d9bb7('0x218f')][_0x43cb33][_0x3d9bb7('0x20ab')]||0x0,_0x587609[_0x3d9bb7('0x1271')]+=_0x204d0d['rpcCampaigns'][_0x43cb33][_0x3d9bb7('0x1271')]||0x0);}),_0x10ddc3['shift'](),_0x204d0d[_0x28037e('0x24d8')]['resolve'](_0x587609),_0x10ddc3[_0x28037e('0x264b')]>0x0&&_0x46eba9();};return function(_0x1acef1){const _0x54fbb0=a0_0x3f2c,_0x1f9465=_0x201ff0[_0x54fbb0('0x24d8')]();return _0x10ddc3[_0x54fbb0('0x1514')]({'rpcCampaigns':_0x1acef1[_0x54fbb0('0x218f')],'defer':_0x1f9465}),_0x10ddc3['length']===0x1&&_0x46eba9(),_0x1f9465[_0x54fbb0('0x1f48')];};}function _0x3fc1a7(){return function(_0x161fcd){const _0x4964a3=a0_0x3f2c;return new Date(_0x161fcd*0x3e8)['toISOString']()[_0x4964a3('0x186a')](0xb,0x8);};}function _0x4b7a3e(_0x108d47,_0x2f0315,_0x519682){const _0x2aca40=_0x36e6f4,_0x44fef5=this;_0x44fef5[_0x2aca40('0x5c9')]=_0x519682,_0x44fef5[_0x2aca40('0xae0')]=_0x341405;function _0x341405(){const _0x283ed9=_0x2aca40;_0x44fef5[_0x283ed9('0x82b')]=_0x2f0315['hasRole'](_0x283ed9('0x557'))?_0x2f0315[_0x283ed9('0x1167')](0x65):!![];if(_0x44fef5['hasDashboardPermissions']){const _0x133e22=_0x108d47[_0x283ed9('0x22b5')]['name'];switch(_0x133e22){case _0x283ed9('0x202e'):_0x5e12ab();break;case _0x283ed9('0xeaf'):_0x44fef5[_0x283ed9('0x2669')]=0x0;break;case _0x283ed9('0xab3'):_0x44fef5[_0x283ed9('0x2669')]=0x1;break;case _0x283ed9('0x11da'):_0x44fef5[_0x283ed9('0x2669')]=0x2;break;case'app.dashboards.general.mail':_0x44fef5['selectedTab']=0x3;break;case'app.dashboards.general.sms':_0x44fef5[_0x283ed9('0x2669')]=0x4;break;case'app.dashboards.general.openchannel':_0x44fef5[_0x283ed9('0x2669')]=0x5;break;case _0x283ed9('0x26e2'):_0x44fef5[_0x283ed9('0x2669')]=0x6;break;case _0x283ed9('0x27ee'):_0x44fef5['selectedTab']=0x7;break;}}}function _0x5e12ab(){const _0x5a48dd=_0x2aca40,_0x1ca627=[];_0x44fef5[_0x5a48dd('0x5c9')][_0x5a48dd('0x21da')]&&_0x1ca627[_0x5a48dd('0x1514')](_0x5a48dd('0xeaf')),_0x44fef5['license'][_0x5a48dd('0x21ee')]&&_0x1ca627['push']('app.dashboards.general.dialer'),_0x44fef5['license']['chat']&&_0x1ca627[_0x5a48dd('0x1514')]('app.dashboards.general.chat'),_0x44fef5[_0x5a48dd('0x5c9')][_0x5a48dd('0x1bfa')]&&_0x1ca627['push']('app.dashboards.general.mail'),_0x44fef5['license']['messaging']&&_0x1ca627[_0x5a48dd('0x1514')](_0x5a48dd('0xad3')),_0x44fef5[_0x5a48dd('0x5c9')]['openchannel']&&_0x1ca627[_0x5a48dd('0x1514')]('app.dashboards.general.openchannel'),_0x44fef5[_0x5a48dd('0x5c9')][_0x5a48dd('0x1fc7')]&&_0x1ca627[_0x5a48dd('0x1514')](_0x5a48dd('0x26e2')),_0x44fef5['license'][_0x5a48dd('0x116e')]&&_0x1ca627['push']('app.dashboards.general.whatsapp');if(_0x1ca627[_0x5a48dd('0x264b')]>0x0)_0x108d47['go'](_0x2cfb05()['first'](_0x1ca627));}}_0x2dc54d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'socket',_0x36e6f4('0x1315'),_0x36e6f4('0x744'),'outbound','initializeRealtimeQueue'];function _0x2dc54d(_0x2fddf5,_0x11452b,_0x11358e,_0x2b073f,_0x336968,_0x3de972){const _0x2c409d=_0x36e6f4,_0xf55e95=this;_0xf55e95[_0x2c409d('0x1315')]=_0x11358e?_0x2cfb05()[_0x2c409d('0x155c')](_0x11358e['rows']?_0x11358e[_0x2c409d('0x269a')]:[],'id'):{},_0xf55e95['rpcQueues']=_0x2b073f?_0x2cfb05()[_0x2c409d('0x155c')](_0x2b073f[_0x2c409d('0x269a')]?_0x2b073f[_0x2c409d('0x269a')]:[],'id'):{},_0xf55e95['inbound']={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x2c409d('0x5ca'),'avgTalkTime':_0x2c409d('0x5ca'),'answerRate':0x0,'abandonRate':0x0},_0xf55e95[_0x2c409d('0x587')]=_0x336968||{'answered':0x0,'sumBillable':0x0,'sumDuration':0x0,'sumHoldTime':0x0,'total':0x0},_0xf55e95[_0x2c409d('0xefb')]=_0x15092a,_0xf55e95[_0x2c409d('0x22c0')]=_0x2ecc39,_0x11452b['on'](_0x2c409d('0xa60'),_0xf55e95[_0x2c409d('0xefb')]),_0x11452b['on'](_0x2c409d('0x24a5'),_0xf55e95['onSaveOutbound']),_0xdc19fc();function _0xdc19fc(){const _0x3adf25=_0x2c409d;_0x3de972({'queues':_0xf55e95[_0x3adf25('0x1315')],'rpcQueues':_0xf55e95[_0x3adf25('0x744')]})['then'](function(_0x1d7830){const _0x23e542=_0x3adf25;_0xf55e95[_0x23e542('0x14d8')]=_0x1d7830;});}function _0x15092a(_0x29efbc){const _0x30c825=_0x2c409d;_0xf55e95['inboundQueues'][_0x29efbc['id']]&&(_0xf55e95[_0x30c825('0x744')][_0x29efbc['id']]&&(_0xf55e95[_0x30c825('0x744')][_0x29efbc['id']]=_0x29efbc,_0xdc19fc()));}function _0x2ecc39(_0x17fdbe){const _0x3e4c21=_0x2c409d;_0xf55e95[_0x3e4c21('0x587')]=_0x17fdbe;}_0x2fddf5[_0x2c409d('0x3d2')](_0x2c409d('0x1c3f'),function(){const _0x20fe1f=_0x2c409d;_0x11452b[_0x20fe1f('0x1800')](_0x20fe1f('0xa60')),_0x11452b[_0x20fe1f('0x1800')](_0x20fe1f('0x24a5'));});}const _0x46eb28=_0x2dc54d;_0x38170d[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x2661'),_0x36e6f4('0x631'),_0x36e6f4('0x1974')];function _0x38170d(_0x472910,_0x231c5c,_0x48c45a,_0x2c3a33){const _0x575aa2=_0x36e6f4,_0x25e88d=this,_0x260b6f=[];_0x25e88d['config']={'format':_0x575aa2('0x1c7e'),'unit':_0x575aa2('0x1aa6'),'trim':![]},_0x25e88d[_0x575aa2('0x14d8')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x575aa2('0x5ca'),'avgTalkTime':_0x575aa2('0x5ca'),'answerRate':0x0,'abandonRate':0x0},_0x25e88d[_0x575aa2('0x1974')]=_0x2c3a33?_0x2cfb05()['keyBy'](_0x2c3a33['rows']?_0x2c3a33[_0x575aa2('0x269a')]:[],'id'):{},_0x25e88d[_0x575aa2('0x1066')]=_0x1434f3,_0x25e88d[_0x575aa2('0x938')]=_0x1a4498,_0x231c5c['on'](_0x575aa2('0x935'),_0x25e88d[_0x575aa2('0x1066')]),_0x231c5c['on'](_0x575aa2('0xfb5'),_0x25e88d[_0x575aa2('0x938')]),_0x1226b0();function _0x39e92f(_0x3afd59,_0x3368ed){const _0x1f20a4=_0x575aa2;!_0x3afd59[_0x1f20a4('0xa5b')]&&!_0x3afd59[_0x1f20a4('0x122a')]&&_0x3368ed&&(_0x25e88d[_0x1f20a4('0x14d8')]['waiting']+=0x1),!_0x3afd59['closed']&&_0x3afd59[_0x1f20a4('0x122a')]&&!_0x2cfb05()[_0x1f20a4('0x1257')](_0x260b6f,_0x3afd59['id'])&&(_0x25e88d['inbound'][_0x1f20a4('0x46a')]+=0x1,_0x260b6f[_0x1f20a4('0x1514')](_0x3afd59['id']),!_0x3368ed&&_0x25e88d['inbound'][_0x1f20a4('0x288a')]&&(_0x25e88d[_0x1f20a4('0x14d8')][_0x1f20a4('0x288a')]-=0x1)),_0x3afd59[_0x1f20a4('0xa5b')]&&_0x3afd59[_0x1f20a4('0x122a')]&&(_0x25e88d[_0x1f20a4('0x14d8')][_0x1f20a4('0xb76')]+=_0x24273b()(_0x3afd59[_0x1f20a4('0x1dc6')])['diff'](_0x24273b()(_0x3afd59[_0x1f20a4('0x981')]),_0x25e88d[_0x1f20a4('0xe11')][_0x1f20a4('0x17db')]),_0x25e88d[_0x1f20a4('0x14d8')][_0x1f20a4('0x4c9')]+=_0x24273b()(_0x3afd59['read1stAt'])[_0x1f20a4('0x884')](_0x24273b()(_0x3afd59[_0x1f20a4('0x262')]),_0x25e88d['config']['unit']),_0x25e88d['inbound'][_0x1f20a4('0x13d')]+=0x1,!_0x3368ed&&_0x25e88d[_0x1f20a4('0x14d8')]['talking']&&(_0x25e88d['inbound'][_0x1f20a4('0x46a')]-=0x1)),_0x3afd59[_0x1f20a4('0xa5b')]&&!_0x3afd59[_0x1f20a4('0x122a')]&&(_0x25e88d[_0x1f20a4('0x14d8')][_0x1f20a4('0x15a7')]+=0x1,!_0x3368ed&&_0x25e88d[_0x1f20a4('0x14d8')][_0x1f20a4('0x288a')]&&(_0x25e88d[_0x1f20a4('0x14d8')][_0x1f20a4('0x288a')]-=0x1)),_0x3368ed&&(_0x25e88d[_0x1f20a4('0x14d8')][_0x1f20a4('0x25e7')]+=0x1);}function _0x1a0635(){const _0x5440f4=_0x575aa2;_0x25e88d[_0x5440f4('0x14d8')][_0x5440f4('0x2245')]=Math[_0x5440f4('0xef')]((_0x25e88d[_0x5440f4('0x14d8')][_0x5440f4('0x183f')]+_0x25e88d['inbound'][_0x5440f4('0x15a7')])/(_0x25e88d[_0x5440f4('0x14d8')]['total']-_0x25e88d[_0x5440f4('0x14d8')]['talking']-_0x25e88d[_0x5440f4('0x14d8')][_0x5440f4('0x288a')])*0x64,-0x2),_0x25e88d[_0x5440f4('0x14d8')][_0x5440f4('0xc4f')]=Math[_0x5440f4('0xef')](_0x25e88d[_0x5440f4('0x14d8')][_0x5440f4('0x13d')]/(_0x25e88d['inbound'][_0x5440f4('0x25e7')]-_0x25e88d[_0x5440f4('0x14d8')][_0x5440f4('0x46a')]-_0x25e88d[_0x5440f4('0x14d8')]['waiting'])*0x64,-0x2),_0x25e88d[_0x5440f4('0x14d8')]['avgHoldTime']=_0x24273b()[_0x5440f4('0x12fc')](Math[_0x5440f4('0xef')](_0x25e88d[_0x5440f4('0x14d8')][_0x5440f4('0x4c9')]/_0x25e88d[_0x5440f4('0x14d8')][_0x5440f4('0x13d')]),_0x25e88d['config']['unit'])[_0x5440f4('0x128a')](_0x25e88d[_0x5440f4('0xe11')][_0x5440f4('0x128a')],_0x25e88d['config']),_0x25e88d[_0x5440f4('0x14d8')]['avgTalkTime']=_0x24273b()[_0x5440f4('0x12fc')](Math[_0x5440f4('0xef')](_0x25e88d[_0x5440f4('0x14d8')]['sumBillable']/_0x25e88d[_0x5440f4('0x14d8')]['answered']),_0x25e88d['config']['unit'])[_0x5440f4('0x128a')](_0x25e88d[_0x5440f4('0xe11')][_0x5440f4('0x128a')],_0x25e88d['config']);}function _0x1226b0(){const _0x22b518=_0x575aa2;if(Object[_0x22b518('0x14a4')](_0x25e88d[_0x22b518('0x1974')])['length']>0x0)for(let _0x1e8d9a=0x0;_0x1e8d9a<_0x48c45a['rows'][_0x22b518('0x264b')];_0x1e8d9a+=0x1){if(_0x24e8bc(_0x48c45a[_0x22b518('0x269a')][_0x1e8d9a])){const _0x24403b=_0x48c45a[_0x22b518('0x269a')][_0x1e8d9a];_0x39e92f(_0x24403b,!![]),_0x1a0635();}}}function _0x24e8bc(_0x26fdab){const _0x1b93ae=_0x575aa2;if(_0x2cfb05()[_0x1b93ae('0x1798')](_0x25e88d[_0x1b93ae('0x1974')],{'id':_0x2cfb05()[_0x1b93ae('0xa53')](_0x26fdab[_0x1b93ae('0x1b88')])}))return!![];return![];}function _0x4b1bb2(_0x4e9166){const _0x4188f1=_0x575aa2,_0x59e55f=_0x24273b()()['utcOffset'](0x0,!![])['startOf'](_0x4188f1('0x16a')),_0x4dc6a6=_0x24273b()()[_0x4188f1('0x13f2')](0x0,!![])[_0x4188f1('0x2589')](_0x4188f1('0x16a'));return _0x24273b()(_0x4e9166)[_0x4188f1('0x13f2')](0x0,!![])['isBetween'](_0x59e55f,_0x4dc6a6);}function _0x1434f3(_0x4e3ba3){_0x24e8bc(_0x4e3ba3)&&_0x4b1bb2(_0x4e3ba3['createdAt'])&&(_0x39e92f(_0x4e3ba3,!![]),_0x1a0635());}function _0x1a4498(_0x36fc63){const _0x356b85=_0x575aa2;_0x24e8bc(_0x36fc63)&&_0x4b1bb2(_0x36fc63[_0x356b85('0x262')])&&(_0x39e92f(_0x36fc63,![]),_0x1a0635());}_0x472910[_0x575aa2('0x3d2')](_0x575aa2('0x1c3f'),function(){const _0x1a7b03=_0x575aa2;_0x231c5c['removeAllListeners'](_0x1a7b03('0x935')),_0x231c5c['removeAllListeners'](_0x1a7b03('0xfb5'));});}const _0x4b7f9c=_0x38170d;_0x1bf8f6[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x1bf8f6(_0x2efea1){const _0x1d164a=_0x36e6f4;_0x2efea1['state'](_0x1d164a('0xeaf'),{'url':_0x1d164a('0x11be'),'data':{'selectedTab':0x0},'views':{'voice':{'templateUrl':_0x39c270,'controller':_0x1d164a('0xb21')}},'resolve':{'rpcQueues':[_0x1d164a('0x1fbc'),function(_0x3b708b){const _0x4b1cdf=_0x1d164a;return _0x3b708b[_0x4b1cdf('0x18af')](_0x4b1cdf('0x85d'));}],'inboundQueues':[_0x1d164a('0x1fbc'),'Auth',function(_0x298eea,_0x14a79b){const _0x3ac713=_0x1d164a;return _0x14a79b[_0x3ac713('0x1ac6')]('admin')?_0x298eea[_0x3ac713('0x18af')]('voiceQueue@get',{'fields':_0x3ac713('0x1776'),'type':_0x3ac713('0x14d8'),'nolimit':!![]}):_0x298eea[_0x3ac713('0x18af')]('userProfile@getResources',{'id':_0x14a79b[_0x3ac713('0x26cd')]()[_0x3ac713('0xb86')],'section':_0x3ac713('0x1ba2'),'fields':_0x3ac713('0x1776'),'type':_0x3ac713('0x14d8'),'channel':_0x3ac713('0x21da'),'nolimit':!![]});}],'outbound':['apiResolver',function(_0x2659a7){const _0x54fc52=_0x1d164a;return _0x2659a7[_0x54fc52('0x18af')](_0x54fc52('0x14c'));}]},'authenticate':!![],'bodyClass':_0x1d164a('0xc87')})[_0x1d164a('0x63f')](_0x1d164a('0xab3'),{'url':_0x1d164a('0x1f50'),'data':{'selectedTab':0x1},'views':{'dialer':{'templateUrl':_0x1bf561,'controller':_0x1d164a('0x2678')}},'resolve':{'rpcQueues':[_0x1d164a('0x1fbc'),function(_0x2c4153){const _0x53ccdf=_0x1d164a;return _0x2c4153[_0x53ccdf('0x18af')](_0x53ccdf('0x85d'));}],'outboundQueues':['apiResolver',_0x1d164a('0x21ef'),function(_0x3a091d,_0xf3718b){const _0x505df5=_0x1d164a;return _0xf3718b['hasRole'](_0x505df5('0xa7c'))?_0x3a091d['resolve'](_0x505df5('0x2700'),{'fields':_0x505df5('0x1776'),'type':'outbound','nolimit':!![]}):_0x3a091d[_0x505df5('0x18af')](_0x505df5('0x17c4'),{'id':_0xf3718b['getCurrentUser']()['userProfileId'],'section':_0x505df5('0x9f4'),'fields':'id,name','type':_0x505df5('0x587'),'channel':_0x505df5('0x21da'),'nolimit':!![]});}],'rpcCampaigns':[_0x1d164a('0x1fbc'),function(_0x5961a9){const _0x3a12a8=_0x1d164a;return _0x5961a9[_0x3a12a8('0x18af')]('rpc@getCampaigns');}]},'authenticate':!![],'bodyClass':_0x1d164a('0xc87')})[_0x1d164a('0x63f')]('app.dashboards.general.chat',{'url':_0x1d164a('0x828'),'data':{'selectedTab':0x2},'views':{'chat':{'templateUrl':_0x49c096,'controller':_0x1d164a('0x1484')}},'resolve':{'chatInteractions':['apiResolver',function(_0x38586b){const _0x4ab829=_0x1d164a;return _0x38586b[_0x4ab829('0x18af')](_0x4ab829('0x2826'),{'createdAt':{'$gte':_0x24273b()()[_0x4ab829('0x1659')]('day')['utcOffset'](0x0,!![])[_0x4ab829('0x128a')](),'$lte':_0x24273b()()[_0x4ab829('0x2589')](_0x4ab829('0x16a'))[_0x4ab829('0x13f2')](0x0,!![])[_0x4ab829('0x128a')]()},'nolimit':!![]});}],'chatWebsites':['apiResolver','Auth',function(_0x133b78,_0x48d645){const _0x1750c1=_0x1d164a;return _0x48d645[_0x1750c1('0x1ac6')](_0x1750c1('0xa7c'))?_0x133b78['resolve'](_0x1750c1('0x1794'),{'fields':_0x1750c1('0x1fdd'),'sort':_0x1750c1('0x14dc'),'limit':0xa,'offset':0x0}):_0x133b78['resolve'](_0x1750c1('0x17c4'),{'id':_0x48d645['getCurrentUser']()[_0x1750c1('0xb86')],'section':'ChatWebsites','fields':'createdAt,updatedAt,id,token,agentIdentifier,customerAlias,messageFontSize,name,key,address,remote,ListId,fidelity,timeout,agentAlias,closingQuestion,formSubmitSuccessMessage,formSubmitFailureMessage,color,color_focus,color_button,textColor,backgroundColor,fontSize,header_shape,showAgentAvatar,showCustomerAvatar,alignment,verticalAlignment,messagesAlignment,defaultTitle,animation,defaultWhiteLabel,whiteLabel,defaultLogo,conditionAgreement,autoclose,enableUnmanagedNote,unmanagedMessage,skipUnmanaged,sendUnmanaged,enableCustomerWriting,waitingTitle,waitingMessage,closingMessage,noteTitle,placeholderMessage,skipMessageButton,enableRating,ratingType,ratingStarsNumber,enableFeedback,forwardTranscript,forwardTranscriptMessage,closingMessageButton,download_transcript,enableCustomerAttachment,systemAlias,enquiry_enable,enquiry_forwarding,enquiry_forwarding_address,name_title,username_placeholder,email_title,email_placeholder,header_online,hideWhenOffline,header_offline,start_chat_button,offline_chat_button,offlineMessageSubject,offlineMessageBody,header_offline,offline_message,message_title,enquiry_message_placeholder,enquiry_button,rating_message,rating_send,rating_skip,acceptMethod,acceptUrl,rejectMethod,rejectUrl,closeMethod,closeUrl,onlineForm,offlineForm,mapKey,mapKeyOffline,forwardTranscript,forwardOffline,forwardOfflineAddress,IntervalId,timezone,waitForTheAssignedAgent,description,notificationSound,notificationShake,notificationTemplate','sort':_0x1750c1('0x14dc'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':_0x1d164a('0xc87')})[_0x1d164a('0x63f')](_0x1d164a('0x1c'),{'url':'/mail','data':{'selectedTab':0x3},'views':{'mail':{'templateUrl':_0x3f7f2a,'controller':_0x1d164a('0x12af')}},'resolve':{'mailInteractions':[_0x1d164a('0x1fbc'),function(_0x28ecad){const _0x2585d7=_0x1d164a;return _0x28ecad[_0x2585d7('0x18af')](_0x2585d7('0x2823'),{'createdAt':{'$gte':_0x24273b()()['startOf'](_0x2585d7('0x16a'))[_0x2585d7('0x13f2')](0x0,!![])[_0x2585d7('0x128a')](),'$lte':_0x24273b()()[_0x2585d7('0x2589')]('day')[_0x2585d7('0x13f2')](0x0,!![])[_0x2585d7('0x128a')]()},'nolimit':!![]});}],'mailAccounts':[_0x1d164a('0x1fbc'),_0x1d164a('0x21ef'),function(_0xc13807,_0x3a72db){const _0x5672c5=_0x1d164a;return _0x3a72db[_0x5672c5('0x1ac6')](_0x5672c5('0xa7c'))?_0xc13807[_0x5672c5('0x18af')]('mailAccount@get',{'fields':_0x5672c5('0x639'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0xc13807[_0x5672c5('0x18af')](_0x5672c5('0x17c4'),{'id':_0x3a72db[_0x5672c5('0x26cd')]()[_0x5672c5('0xb86')],'section':_0x5672c5('0x17bd'),'fields':_0x5672c5('0x639'),'sort':_0x5672c5('0x14dc'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':'dashboards'})[_0x1d164a('0x63f')](_0x1d164a('0xad3'),{'url':'/sms','data':{'selectedTab':0x4},'views':{'sms':{'templateUrl':_0x2d53ef,'controller':_0x1d164a('0x371')}},'resolve':{'smsInteractions':['apiResolver',function(_0x4deb21){const _0xb892b3=_0x1d164a;return _0x4deb21['resolve']('smsInteraction@get',{'createdAt':{'$gte':_0x24273b()()[_0xb892b3('0x1659')](_0xb892b3('0x16a'))['utcOffset'](0x0,!![])[_0xb892b3('0x128a')](),'$lte':_0x24273b()()['endOf'](_0xb892b3('0x16a'))[_0xb892b3('0x13f2')](0x0,!![])[_0xb892b3('0x128a')]()},'nolimit':!![]});}],'smsAccounts':[_0x1d164a('0x1fbc'),'Auth',function(_0x8c7a64,_0x26c288){const _0xcc0bd1=_0x1d164a;return _0x26c288[_0xcc0bd1('0x1ac6')](_0xcc0bd1('0xa7c'))?_0x8c7a64[_0xcc0bd1('0x18af')](_0xcc0bd1('0x1b3'),{'fields':'createdAt,updatedAt,id,name,key,token,remote,ListId,phone,type,accountSid,authId,authToken,smsMethod,username,password,senderString,deliveryReport,waitForTheAssignedAgent,description,receiveUrl,deliveryReportUrl,notificationSound,notificationShake,notificationTemplate','sort':_0xcc0bd1('0x14dc'),'limit':0xa,'offset':0x0}):_0x8c7a64[_0xcc0bd1('0x18af')](_0xcc0bd1('0x17c4'),{'id':_0x26c288[_0xcc0bd1('0x26cd')]()[_0xcc0bd1('0xb86')],'section':_0xcc0bd1('0x1442'),'fields':'createdAt,updatedAt,id,name,key,token,remote,ListId,phone,type,accountSid,authId,authToken,smsMethod,username,password,senderString,deliveryReport,waitForTheAssignedAgent,description,receiveUrl,deliveryReportUrl,notificationSound,notificationShake,notificationTemplate','sort':_0xcc0bd1('0x14dc'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':_0x1d164a('0xc87')})[_0x1d164a('0x63f')](_0x1d164a('0x153'),{'url':'/openchannel','data':{'selectedTab':0x5},'views':{'openchannel':{'templateUrl':_0x30d8a7,'controller':_0x1d164a('0x1c1d')}},'resolve':{'openchannelInteractions':[_0x1d164a('0x1fbc'),function(_0x230d05){const _0x4d2e93=_0x1d164a;return _0x230d05[_0x4d2e93('0x18af')]('openchannelInteraction@get',{'createdAt':{'$gte':_0x24273b()()[_0x4d2e93('0x1659')](_0x4d2e93('0x16a'))['utcOffset'](0x0,!![])[_0x4d2e93('0x128a')](),'$lte':_0x24273b()()['endOf']('day')[_0x4d2e93('0x13f2')](0x0,!![])[_0x4d2e93('0x128a')]()},'nolimit':!![]});}],'openchannelAccounts':[_0x1d164a('0x1fbc'),_0x1d164a('0x21ef'),function(_0x11d491,_0x24e6cc){const _0x23eab3=_0x1d164a;return _0x24e6cc[_0x23eab3('0x1ac6')]('admin')?_0x11d491[_0x23eab3('0x18af')](_0x23eab3('0x1ccb'),{'fields':_0x23eab3('0x1b2d'),'sort':_0x23eab3('0x14dc'),'nolimit':!![]}):_0x11d491[_0x23eab3('0x18af')](_0x23eab3('0x17c4'),{'id':_0x24e6cc[_0x23eab3('0x26cd')]()[_0x23eab3('0xb86')],'section':_0x23eab3('0x1575'),'fields':'createdAt,updatedAt,id,name,key,token,replyUri,ListId,waitForTheAssignedAgent,mapKey,description,receiveUri,notificationSound,notificationShake,notificationTemplate','sort':'-updatedAt','nolimit':!![]});}]},'authenticate':!![],'bodyClass':'dashboards'})[_0x1d164a('0x63f')](_0x1d164a('0x26e2'),{'url':_0x1d164a('0xfbe'),'data':{'selectedTab':0x6},'views':{'fax':{'templateUrl':_0x3bce68,'controller':'UserFaxDashboardGeneralController\x20as\x20vm'}},'resolve':{'faxInteractions':[_0x1d164a('0x1fbc'),function(_0x2c7963){const _0x3575a1=_0x1d164a;return _0x2c7963[_0x3575a1('0x18af')](_0x3575a1('0x14e7'),{'createdAt':{'$gte':_0x24273b()()[_0x3575a1('0x1659')]('day')['utcOffset'](0x0,!![])[_0x3575a1('0x128a')](),'$lte':_0x24273b()()[_0x3575a1('0x2589')](_0x3575a1('0x16a'))[_0x3575a1('0x13f2')](0x0,!![])[_0x3575a1('0x128a')]()},'nolimit':!![]});}],'faxAccounts':['apiResolver','Auth',function(_0x36141e,_0xff1bf1){const _0x398114=_0x1d164a;return _0xff1bf1[_0x398114('0x1ac6')](_0x398114('0xa7c'))?_0x36141e[_0x398114('0x18af')](_0x398114('0x217d'),{'fields':_0x398114('0x1d7b'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x36141e['resolve'](_0x398114('0x17c4'),{'id':_0xff1bf1[_0x398114('0x26cd')]()[_0x398114('0xb86')],'section':_0x398114('0x1c3b'),'fields':_0x398114('0x1d7b'),'sort':_0x398114('0x14dc'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':_0x1d164a('0xc87')})['state'](_0x1d164a('0x27ee'),{'url':_0x1d164a('0xd58'),'data':{'selectedTab':0x7},'views':{'whatsapp':{'templateUrl':_0x1eae26,'controller':_0x1d164a('0xa4')}},'resolve':{'whatsappInteractions':['apiResolver',function(_0x29bb1d){const _0x472fe0=_0x1d164a;return _0x29bb1d[_0x472fe0('0x18af')](_0x472fe0('0x1040'),{'createdAt':{'$gte':_0x24273b()()[_0x472fe0('0x1659')](_0x472fe0('0x16a'))[_0x472fe0('0x13f2')](0x0,!![])[_0x472fe0('0x128a')](),'$lte':_0x24273b()()['endOf'](_0x472fe0('0x16a'))[_0x472fe0('0x13f2')](0x0,!![])[_0x472fe0('0x128a')]()},'nolimit':!![]});}],'whatsappAccounts':['apiResolver','Auth',function(_0x4e4811,_0x589da3){const _0x2d085a=_0x1d164a;return _0x589da3[_0x2d085a('0x1ac6')](_0x2d085a('0xa7c'))?_0x4e4811[_0x2d085a('0x18af')](_0x2d085a('0x27bb'),{'fields':_0x2d085a('0x1ef8'),'sort':_0x2d085a('0x14dc'),'limit':0xa,'offset':0x0}):_0x4e4811[_0x2d085a('0x18af')](_0x2d085a('0x17c4'),{'id':_0x589da3[_0x2d085a('0x26cd')]()[_0x2d085a('0xb86')],'section':_0x2d085a('0x171a'),'fields':_0x2d085a('0x1ef8'),'sort':_0x2d085a('0x14dc'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':_0x1d164a('0xc87')});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x6bb'),[])[_0x36e6f4('0xe11')](_0x1bf8f6)[_0x36e6f4('0x75e')](_0x36e6f4('0x65a'),_0x4daa12)[_0x36e6f4('0x75e')](_0x36e6f4('0x25d1'),_0x57e5c7)['controller'](_0x36e6f4('0x1699'),_0x2e85f7)['controller'](_0x36e6f4('0x3c6'),_0x38f322)[_0x36e6f4('0x75e')](_0x36e6f4('0x19cf'),_0x49dfe1)[_0x36e6f4('0x75e')](_0x36e6f4('0x1df2'),_0x11056b)['filter'](_0x36e6f4('0x1a05'),_0x3fc1a7)[_0x36e6f4('0x87c')](_0x36e6f4('0x13e7'),_0x4c6969)[_0x36e6f4('0x87c')]('initializeRealtimeCampaign',_0x18c074)[_0x36e6f4('0x75e')](_0x36e6f4('0x1175'),_0x4b7a3e)[_0x36e6f4('0x75e')](_0x36e6f4('0x1bf9'),_0x46eb28)['controller']('UserWhatsappDashboardGeneralController',_0x4b7f9c);const _0x25a3f3=_0x2734b2['p']+_0x36e6f4('0x1775'),_0x1aa062=_0x2734b2['p']+_0x36e6f4('0x13a');var _0x92ddc1=_0x2734b2(0x1d2),_0x5f0cec=_0x2734b2['n'](_0x92ddc1);_0x495c1e['$inject']=[_0x36e6f4('0x1cab'),_0x36e6f4('0x586'),_0x36e6f4('0x1566'),_0x36e6f4('0x21ef')],_0x508ce7[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1566'),'$translate',_0x36e6f4('0x1c90'),_0x36e6f4('0x21ef'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xa5a'),'globalLists',_0x36e6f4('0x69'),_0x36e6f4('0x1430'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x650'),_0x36e6f4('0x1f36')];function _0x508ce7(_0x1cf4cf,_0x3f7ce5,_0x593a2e,_0x2894cd,_0x4b2314,_0x30ee62,_0x2a6371,_0x2d99e3,_0x1821d8,_0x592424,_0x1a39e0,_0x4e0301,_0x4847ba,_0x6d3909,_0x1d1cc4,_0x13a09e,_0x5b0409,_0x1706dd){const _0x31a29d=_0x36e6f4,_0x1883bc=this;_0x1883bc[_0x31a29d('0x5c9')]=_0x1d1cc4,_0x1883bc[_0x31a29d('0xf8a')]=_0x13a09e,_0x1883bc[_0x31a29d('0x2694')]=_0x1706dd[_0x31a29d('0x2694')](),_0x1883bc['user']=_0x2a6371[_0x31a29d('0x26cd')](),_0x1883bc['currentTab']=0x0,_0x1883bc[_0x31a29d('0x210')]={},_0x1883bc[_0x31a29d('0x137f')]={},_0x1883bc[_0x31a29d('0x1a6d')]={},_0x1883bc['globalUserLists']=_0x1a39e0||{'count':0x0,'rows':[]},_0x1883bc[_0x31a29d('0x2072')]=_0x4e0301||{'count':0x0,'rows':[]},_0x1883bc[_0x31a29d('0x69')]=_0x4847ba||{'count':0x0,'rows':[]},_0x1883bc['globalTags']=_0x6d3909||{'count':0x0,'rows':[]},_0x1883bc[_0x31a29d('0x25b5')]=_0x41809e,_0x1883bc[_0x31a29d('0x20a7')]=_0x2cbe2b,_0x1883bc[_0x31a29d('0x28e4')]=_0x31a2d3,_0x1883bc[_0x31a29d('0x247b')]=_0x40ca7c,_0x1883bc[_0x31a29d('0x126e')]=_0x1d7c9b,_0x1883bc['addTab']=_0x1bb0da,_0x1883bc[_0x31a29d('0x1b93')]=_0x1f183e,_0x1883bc[_0x31a29d('0x1a4f')]=_0xd64d1c,_0x1883bc[_0x31a29d('0x11a3')]=_0x4129ec,_0x1821d8['on']('trigger:contactmanager',_0x348925),_0x1821d8['on'](_0x31a29d('0x1e35'),_0x2a3a2d),_0x1821d8['on'](_0x31a29d('0x10b9'),_0x2613ea),_0x1821d8['on'](_0x31a29d('0x1349'),_0x2e2158),_0x1821d8['on'](_0x31a29d('0x26ea'),_0xd9be86),_0x1821d8['on'](_0x31a29d('0x13f7'),_0x4cd6a9),_0x1821d8['on'](_0x31a29d('0x4cb'),_0x5150f3),_0x1821d8['on'](_0x31a29d('0x14fe'),_0x3e6f7b),_0x1821d8['on'](_0x31a29d('0x125c'),_0x3e6f7b),_0x1efa4c();function _0x1efa4c(){const _0x7f4eeb=_0x31a29d;let _0x19b88a=_0x2894cd[_0x7f4eeb('0x275')][_0x7f4eeb('0x15f7')](_0x7f4eeb('0xfb7')+_0x1883bc[_0x7f4eeb('0x557')]['id']);if(_0x19b88a)try{_0x19b88a=JSON[_0x7f4eeb('0x1295')](_0x19b88a),_0x1883bc[_0x7f4eeb('0x137f')]=_0x19b88a[_0x7f4eeb('0x137f')]?_0x19b88a['tabs']:{},_0x1883bc[_0x7f4eeb('0x623')]=_0x19b88a['currentTab']?_0x19b88a[_0x7f4eeb('0x623')]:0x0,_0x53e9ca(_0x1883bc[_0x7f4eeb('0x137f')][_0x1883bc[_0x7f4eeb('0x623')]]);}catch(_0x3f9f4b){console[_0x7f4eeb('0xfc9')](_0x3f9f4b);}}function _0xd64d1c(_0x3a3c18){const _0x17294f=_0x31a29d,_0x47dcfb={};for(const _0x53901a in _0x1883bc[_0x17294f('0x137f')]){typeof _0x1883bc[_0x17294f('0x137f')][_0x53901a]!=='undefined'&&(_0x47dcfb[_0x53901a]=_0x2cfb05()['pick'](_0x1883bc[_0x17294f('0x137f')][_0x53901a],[_0x17294f('0x1345'),_0x17294f('0xcdc'),_0x17294f('0x1298'),'icon',_0x17294f('0x1b22'),_0x17294f('0x166c'),'id',_0x17294f('0x26ae'),_0x17294f('0x1d12')]),!_0x2cfb05()[_0x17294f('0x2863')](_0x1883bc[_0x17294f('0x137f')][_0x53901a]['contact'])&&(_0x47dcfb[_0x53901a][_0x17294f('0x26db')]=_0x2cfb05()['pick'](_0x1883bc['tabs'][_0x53901a][_0x17294f('0x26db')],['id',_0x17294f('0x23c')])),!_0x2cfb05()[_0x17294f('0x2863')](_0x1883bc[_0x17294f('0x137f')][_0x53901a][_0x17294f('0x807')])&&(_0x47dcfb[_0x53901a]['calls']=_0x1883bc[_0x17294f('0x137f')][_0x53901a][_0x17294f('0x807')]),_0x1883bc['tabs'][_0x53901a][_0x17294f('0x25e6')]&&(_0x47dcfb[_0x53901a][_0x17294f('0x25e6')]=_0x2cfb05()[_0x17294f('0x1a08')](_0x1883bc['tabs'][_0x53901a][_0x17294f('0x25e6')],['id',_0x17294f('0xb8'),_0x17294f('0x56'),_0x17294f('0x1e02'),_0x17294f('0x18fe'),_0x17294f('0xa74'),'WhatsappAccountId',_0x17294f('0xa5b'),_0x17294f('0xfca')])));}let _0x101cde=JSON[_0x17294f('0x1295')](_0x2894cd['localStorage'][_0x17294f('0x15f7')](_0x17294f('0xfb7')+_0x1883bc[_0x17294f('0x557')]['id']));_0x101cde?(_0x101cde[_0x17294f('0x137f')]=_0x47dcfb,_0x101cde['currentTab']=_0x1883bc[_0x17294f('0x623')]):_0x101cde={'tabs':_0x47dcfb,'currentTab':_0x1883bc[_0x17294f('0x623')]},_0x2894cd[_0x17294f('0x275')]['setItem'](_0x17294f('0xfb7')+_0x1883bc[_0x17294f('0x557')]['id'],JSON[_0x17294f('0xbac')](_0x101cde)),_0x3a3c18&&_0x53e9ca(_0x3a3c18);}function _0x53e9ca(_0x4a29c9){const _0x46cd64=_0x31a29d;if(_0x2cfb05()[_0x46cd64('0x2863')](_0x4a29c9)||_0x4a29c9&&_0x4a29c9['type']===_0x46cd64('0x25e6')){const _0x2a18ef={'id':_0x1883bc[_0x46cd64('0x557')]['id'],'online':!![],'capacity':{'mail':0x0,'fax':0x0,'sms':0x0,'whatsapp':0x0,'openchannel':0x0,'chat':0x0},'interaction':{'mail':[],'fax':[],'sms':[],'whatsapp':[],'openchannel':[],'chat':[]}};for(const _0xd86d24 in _0x1883bc[_0x46cd64('0x137f')]){typeof _0x1883bc[_0x46cd64('0x137f')][_0xd86d24]!==_0x46cd64('0x1048')&&(typeof _0x2a18ef[_0x46cd64('0x42e')][_0x1883bc[_0x46cd64('0x137f')][_0xd86d24]['channel']]!==_0x46cd64('0x1048')&&_0x1883bc[_0x46cd64('0x137f')][_0xd86d24][_0x46cd64('0x25e6')]&&!_0x1883bc[_0x46cd64('0x137f')][_0xd86d24][_0x46cd64('0x25e6')][_0x46cd64('0xa5b')]&&(_0x2a18ef[_0x46cd64('0x42e')][_0x1883bc[_0x46cd64('0x137f')][_0xd86d24][_0x46cd64('0x1298')]]+=0x1,_0x2a18ef[_0x46cd64('0x25e6')][_0x1883bc[_0x46cd64('0x137f')][_0xd86d24][_0x46cd64('0x1298')]][_0x46cd64('0x1514')](_0x1883bc[_0x46cd64('0x137f')][_0xd86d24][_0x46cd64('0x25e6')]['id'])));}if(!_0x2cfb05()[_0x46cd64('0x4ec')](_0x1883bc['agentCapacity'],_0x2a18ef[_0x46cd64('0x42e')]))return _0x1883bc['agentCapacity']=_0x2a18ef[_0x46cd64('0x42e')],_0x2d99e3[_0x46cd64('0x13fa')][_0x46cd64('0x1c1b')](_0x2a18ef);}}function _0x4129ec(_0xef1e56){const _0x28e0d5=_0x31a29d;let _0x2a02d6=![];const _0x53aca5=_0x593a2e[_0x28e0d5('0x1d26')]()[_0x28e0d5('0xcdc')](_0xef1e56[_0x28e0d5('0x1345')]===_0x28e0d5('0x25e6')?_0x28e0d5('0x1d5c'):_0x28e0d5('0x68f')+_0xef1e56[_0x28e0d5('0x1345')]+'?')[_0x28e0d5('0x2077')](_0xef1e56['type']===_0x28e0d5('0x25e6')?'':_0x28e0d5('0x135f')+_0xef1e56['type']+_0x28e0d5('0x105c'))['ariaLabel'](_0x28e0d5('0xca9'))['ok'](_0xef1e56[_0x28e0d5('0x1345')]===_0x28e0d5('0x25e6')?_0x28e0d5('0x188f'):'OK')[_0x28e0d5('0x3f')](_0xef1e56[_0x28e0d5('0x1345')]==='interaction'?'NO':_0x28e0d5('0x2d3'));if(_0xef1e56[_0x28e0d5('0x26ae')]){let _0x58c48f=![];_0x2cfb05()['forEach'](_0xef1e56['calls'],function(_0x3a8884){const _0x25ddea=_0x28e0d5;_0x3a8884[_0x25ddea('0x10d0')]&&(_0x58c48f=!![]);});if(_0xef1e56[_0x28e0d5('0x1345')]===_0x28e0d5('0x26db')&&_0xef1e56[_0x28e0d5('0x807')][_0x28e0d5('0x264b')]>0x0){let _0x49dfa0=undefined;if(_0x58c48f)_0x49dfa0=_0x593a2e[_0x28e0d5('0x31d')]()[_0x28e0d5('0xcdc')](_0x28e0d5('0x9f8'))[_0x28e0d5('0x2077')](_0x28e0d5('0xd85'))['ok']('OK'),_0x593a2e[_0x28e0d5('0x1f80')](_0x49dfa0)[_0x28e0d5('0x1951')](function(){_0x49dfa0=undefined;});else return _0x53aca5[_0x28e0d5('0x2097')][_0x28e0d5('0x2077')]=_0x28e0d5('0xd85'),_0x593a2e[_0x28e0d5('0x1f80')](_0x53aca5)[_0x28e0d5('0x1166')](function(){_0x1f183e(_0xef1e56);});}else _0x1f183e(_0xef1e56);}else{const _0x14d6db=_0x1883bc['user'][_0x28e0d5('0x2540')]||_0x1883bc[_0x28e0d5('0x557')]['chatPause']||_0x1883bc[_0x28e0d5('0x557')]['mailPause']||_0x1883bc[_0x28e0d5('0x557')][_0x28e0d5('0x287f')]||_0x1883bc[_0x28e0d5('0x557')][_0x28e0d5('0x5aa')];return _0x2a02d6=![],_0xef1e56[_0x28e0d5('0x1345')]===_0x28e0d5('0x25e6')&&(_0x2a02d6=_0xef1e56['interaction'][_0x28e0d5('0x1758')][_0x28e0d5('0x10d0')]),_0x593a2e['show'](_0x53aca5)[_0x28e0d5('0x1166')](function(){const _0x5b86fd=_0x28e0d5;_0xef1e56['type']===_0x5b86fd('0x25e6')&&_0x593a2e[_0x5b86fd('0x1f80')]({'controller':_0x5b86fd('0xa39'),'controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular['element'](_0x30ee62[_0x5b86fd('0x8d2')]),'onRemoving':function(){const _0x516caf=_0x5b86fd;_0x1883bc[_0x516caf('0x557')]&&_0x2a02d6&&!_0x14d6db&&_0x2d99e3['user'][_0x516caf('0x20eb')]({'id':_0x1883bc['user']['id']})[_0x516caf('0xa44')][_0x516caf('0x1a80')](function(_0x24eb7c){console['error'](_0x24eb7c);});},'clickOutsideToClose':!_0x2a02d6,'escapeToClose':!_0x2a02d6,'locals':{'user':_0x1883bc['user'],'channel':_0xef1e56[_0x5b86fd('0x1298')],'interaction':_0xef1e56[_0x5b86fd('0x25e6')]}}),_0x1f183e(_0xef1e56);})[_0x28e0d5('0x1a80')](function(){_0xef1e56['type']==='interaction'&&_0x1f183e(_0xef1e56);});}}function _0x360b5e(_0x4ba0a1){const _0x5ba983=_0x31a29d;if(_0x4ba0a1[_0x5ba983('0x1298')]&&_0x4ba0a1[_0x5ba983('0x25e6')])return _0x2d99e3['user'][_0x5ba983('0x127f')+_0x2cfb05()[_0x5ba983('0x114b')](_0x4ba0a1[_0x5ba983('0x1298')])+_0x5ba983('0x7b3')]({'id':_0x1883bc[_0x5ba983('0x557')]['id'],'ids':[_0x4ba0a1['interaction']['id']]})[_0x5ba983('0xa44')][_0x5ba983('0x1a80')](function(_0x1efa30){console['error'](_0x1efa30);});}function _0x1f183e(_0x3f41b4){const _0x4cba84=_0x31a29d;if(_0x1883bc['tabs'][_0x3f41b4['id']]){_0x360b5e(_0x1883bc[_0x4cba84('0x137f')][_0x3f41b4['id']]),delete _0x1883bc[_0x4cba84('0x137f')][_0x3f41b4['id']],_0x1883bc[_0x4cba84('0x623')]=0x0,_0xd64d1c(_0x3f41b4);if(_0x3f41b4['type']==='interaction')return _0x2d99e3[_0x3f41b4[_0x4cba84('0x1298')]+'Interaction']['get']({'id':_0x3f41b4[_0x4cba84('0x25e6')]['id']})[_0x4cba84('0xa44')]['then'](function(_0x58f5d8){const _0x3cde30=_0x4cba84;return _0x2d99e3[_0x3cde30('0x557')][_0x3cde30('0x127f')+_0x2cfb05()[_0x3cde30('0x114b')](_0x3f41b4[_0x3cde30('0x1298')])+_0x3cde30('0x7b3')]({'id':_0x1883bc[_0x3cde30('0x557')]['id'],'ids':[_0x58f5d8['id']]})[_0x3cde30('0xa44')];})[_0x4cba84('0x1a80')](function(_0x1e3905){const _0x5e8581=_0x4cba84;console[_0x5e8581('0xfc9')](_0x1e3905);});}}function _0x1bb0da(_0x2f9587){const _0x26216d=_0x31a29d;_0x2f9587['id']=_0x2cfb05()[_0x26216d('0x2010')](0x2540be400),_0x2f9587[_0x26216d('0x87f')]=new Date(),_0x2f9587[_0x26216d('0x26ae')]=![],_0x2f9587['badges']=0x0,_0x1883bc['tabs'][_0x2f9587['id']]=_0x2f9587,_0x1883bc[_0x26216d('0x623')]=_0x2f9587['id'],_0xd64d1c(_0x2f9587);}function _0x2cbe2b(_0x2f841a){return _0x2f841a===_0x1883bc['currentTab'];}function _0x41809e(_0x4f3758){const _0x3dee17=_0x31a29d;_0x1883bc[_0x3dee17('0x623')]=_0x4f3758,_0xd64d1c(_0x1883bc[_0x3dee17('0x137f')][_0x4f3758]);}function _0x31a2d3(_0x85836c){const _0x4d9ba7=_0x31a29d;return _0x2cfb05()[_0x4d9ba7('0xc38')](_0x1883bc[_0x4d9ba7('0x137f')],function(_0x2b3b91){const _0x340af9=_0x4d9ba7;return _0x2b3b91[_0x340af9('0x1345')]===_0x340af9('0x25e6')&&_0x2b3b91['interaction']&&_0x2b3b91[_0x340af9('0x25e6')]['id']==_0x85836c['interactionId']&&_0x2b3b91[_0x340af9('0x1298')]==_0x85836c[_0x340af9('0x1298')];});}function _0x2c4f71(_0x238a38){const _0x52039d=_0x31a29d;let _0x8536fb='';if(_0x238a38){if(_0x238a38[_0x52039d('0x18cb')]||_0x238a38[_0x52039d('0xeb0')])_0x238a38[_0x52039d('0x18cb')]&&(_0x8536fb+=_0x238a38[_0x52039d('0x18cb')]+'\x20'),_0x238a38['lastName']&&(_0x8536fb+=_0x238a38[_0x52039d('0xeb0')]);else _0x238a38[_0x52039d('0x2026')]&&(_0x8536fb=_0x238a38[_0x52039d('0x2026')]);}return _0x8536fb;}function _0x3426d6(_0x232e7d){const _0x33ba2a=_0x31a29d;switch(_0x232e7d){case _0x33ba2a('0xde2'):return _0x33ba2a('0xc49');case _0x33ba2a('0x1bfa'):return _0x33ba2a('0x142d');case _0x33ba2a('0x146c'):return _0x33ba2a('0x1392');case'openchannel':return'icon-google-earth';case _0x33ba2a('0x1fc7'):return _0x33ba2a('0x23fb');case _0x33ba2a('0x116e'):return'icon-whatsapp';default:return _0x33ba2a('0xc49');}}function _0x57d555(_0x19b0d6){const _0x47e7bb=_0x31a29d;switch(_0x19b0d6){case'chat':return'green-A700';case _0x47e7bb('0x1bfa'):return _0x47e7bb('0x28e8');case _0x47e7bb('0x146c'):return _0x47e7bb('0x1adc');case _0x47e7bb('0x26c'):return _0x47e7bb('0xb1e');case _0x47e7bb('0x1fc7'):return _0x47e7bb('0x1917');case'whatsapp':return _0x47e7bb('0xe6d');default:return _0x47e7bb('0x1733');}}function _0x40ca7c(_0x1cdab5,_0x5af5c7){const _0x5d4de3=_0x31a29d,_0x412df4={'type':_0x5d4de3('0x26db'),'title':_0x1cdab5?_0x2c4f71(_0x1cdab5):_0x4b2314[_0x5d4de3('0x25cc')](_0x5d4de3('0x239a')),'icon':'icon-account-circle','color':_0x5d4de3('0x21e2'),'contact':_0x1cdab5,'calls':_0x5af5c7?[_0x5af5c7]:[],'autoCreate':_0x5af5c7?_0x5af5c7[_0x5d4de3('0x166c')]:0x0};if(_0x5af5c7){if(_0x5af5c7[_0x5d4de3('0x20d6')]&&_0x5af5c7['xmd-cdrtype']===_0x5d4de3('0x21ee'))_0x5af5c7['answeredAt']=_0x5af5c7[_0x5d4de3('0x2e1')]?_0x24273b()(_0x5af5c7[_0x5d4de3('0x2e1')],_0x5d4de3('0x1084'))[_0x5d4de3('0x24d3')]():new Date();else{if(_0x5af5c7['uniqueid']){const _0x1661e7=_0x5af5c7[_0x5d4de3('0x1c21')][_0x5d4de3('0x25c8')]('.')[0x0];_0x5af5c7[_0x5d4de3('0x223b')]=_0x1661e7?new Date(parseInt(_0x1661e7)*0x3e8):new Date();}}(_0x5af5c7[_0x5d4de3('0xa7d')]||_0x5af5c7[_0x5d4de3('0x22e9')])&&_0x503609(_0x5af5c7);}if(_0x1cdab5){const _0x5f15ab=_0x2cfb05()[_0x5d4de3('0xc38')](_0x1883bc[_0x5d4de3('0x137f')],function(_0x38d152){const _0x41b4b4=_0x5d4de3;if(_0x38d152[_0x41b4b4('0x26db')]&&_0x38d152[_0x41b4b4('0x26db')]['id'])return _0x38d152[_0x41b4b4('0x1345')]===_0x41b4b4('0x26db')&&_0x38d152[_0x41b4b4('0x26db')]&&_0x38d152['contact']['id']==_0x1cdab5['id'];return _0x38d152[_0x41b4b4('0x1345')]==='contact'&&_0x38d152[_0x41b4b4('0x26db')]&&_0x38d152[_0x41b4b4('0x26db')]['phone']==_0x1cdab5[_0x41b4b4('0x2026')];});if(_0x5f15ab){if(_0x5af5c7)return _0x2d99e3[_0x5d4de3('0x26e0')]['get']({'uniqueid':_0x5af5c7['uniqueid']})['$promise'][_0x5d4de3('0x1166')](function(_0x4e3f01){const _0x528c57=_0x5d4de3;_0x4e3f01&&_0x4e3f01['rows'][_0x528c57('0x264b')]>0x0&&(_0x5af5c7['disposedAt']=_0x2cfb05()['first'](_0x4e3f01[_0x528c57('0x269a')])['endtime']);if(_0x5f15ab[_0x528c57('0x807')]){const _0x292a90=_0x2cfb05()[_0x528c57('0xc38')](_0x5f15ab['calls'],function(_0x56cb09){const _0x5e002a=_0x528c57;return _0x56cb09[_0x5e002a('0x1c21')]===_0x5af5c7[_0x5e002a('0x1c21')];});!_0x292a90&&_0x5f15ab[_0x528c57('0x807')]['push'](_0x5af5c7);}else _0x5f15ab[_0x528c57('0x807')]=[_0x5af5c7];_0x1883bc['currentTab']=_0x5f15ab['id'];});}else{if(_0x1cdab5['ListId'])return _0x2d99e3[_0x5d4de3('0x12e8')][_0x5d4de3('0xd83')]({'ListId':_0x1cdab5['ListId']})[_0x5d4de3('0xa44')][_0x5d4de3('0x1166')](function(_0xf4362b){const _0x4a56fa=_0x5d4de3;return _0x412df4[_0x4a56fa('0x4ea')]=_0xf4362b,_0x2d99e3[_0x4a56fa('0xdd9')][_0x4a56fa('0x1bb')]({'id':_0x1cdab5['ListId']})[_0x4a56fa('0xa44')];})[_0x5d4de3('0x1166')](function(_0x34997e){const _0x3c2172=_0x5d4de3;_0x412df4[_0x3c2172('0x23d7')]=_0x34997e;})['catch'](_0x14a1f7())[_0x5d4de3('0x1951')](function(){_0x1bb0da(_0x412df4);});else _0x1bb0da(_0x412df4);}}else _0x1bb0da(_0x412df4);}function _0x1d7c9b(_0x21799e,_0x3d605e){const _0x2536c5=_0x31a29d;let _0x3b11d3=_0x2cfb05()[_0x2536c5('0xc38')](_0x1883bc['tabs'],function(_0x30f995){const _0x1bc3c3=_0x2536c5;return _0x30f995[_0x1bc3c3('0x1345')]==='interaction'&&_0x30f995['interaction']&&_0x30f995[_0x1bc3c3('0x25e6')]['id']===_0x3d605e['id']&&_0x30f995[_0x1bc3c3('0x1298')]===_0x21799e;});_0x3b11d3?(_0x3b11d3[_0x2536c5('0x2471')]=_0x3d605e[_0x2536c5('0x2471')]||![],_0x1883bc[_0x2536c5('0x623')]=_0x3b11d3['id']):(_0x3b11d3={'type':'interaction','title':_0x21799e?_0x21799e[_0x2536c5('0x1387')]():_0x2536c5('0x26c'),'icon':_0x3426d6(_0x21799e),'color':_0x57d555(_0x21799e),'channel':_0x21799e,'interaction':_0x3d605e,'isDraft':_0x3d605e[_0x2536c5('0x2471')]||![]},_0x1bb0da(_0x3b11d3));}function _0x38562f(_0x22348c){const _0x302123=_0x31a29d,_0x565af4={'autoClose':!![],'duration':0xa,'showOnPageHidden':!![],'icon':_0x302123('0x7ff'),'body':_0x22348c[_0x302123('0x1d3e')]?_0x302123('0x18bf')+_0x22348c['queue']:'','focusOnclick':!![],'closeOnClick':!![]};_0x5b0409['show'](_0x22348c[_0x302123('0xcdc')],_0x565af4);}function _0x32cabd(_0x4339db){const _0x42eeba=_0x31a29d;_0x5b0409[_0x42eeba('0xa2d')]()?_0x5b0409['requestPermission']()[_0x42eeba('0x1166')](function(){_0x38562f(_0x4339db);},function(_0x2d7052){const _0x3cdb9a=_0x42eeba;console[_0x3cdb9a('0xfc9')](_0x3cdb9a('0x1a1'),_0x2d7052);}):console['error'](_0x42eeba('0x2813'));}function _0x4cd6a9(_0x4d9f83){const _0x17c062=_0x31a29d;if(_0x4d9f83&&_0x4d9f83[_0x17c062('0x1c21')]){_0x32cabd(_0x4d9f83);const _0xb15b44=_0x31a2d3(_0x4d9f83);if(_0xb15b44){if(_0x2d99e3[_0x4d9f83[_0x17c062('0x1298')]+_0x17c062('0x1720')])return _0x1883bc[_0x17c062('0x623')]!==_0xb15b44['id']&&(_0xb15b44[_0x17c062('0x1d12')]+=0x1),_0x2d99e3[_0x4d9f83[_0x17c062('0x1298')]+_0x17c062('0x1720')][_0x17c062('0x2384')]({'id':_0x4d9f83['id'],'UserId':_0x1883bc[_0x17c062('0x557')]['id']})[_0x17c062('0xa44')][_0x17c062('0x1a80')](_0x14a1f7());}else _0x592424[_0x17c062('0x111d')]({'title':_0x4d9f83[_0x17c062('0xcdc')],'msg':_0x4d9f83[_0x17c062('0x1ff3')]||'','showClose':![],'clickToClose':![],'timeout':![],'sound':_0x4d9f83[_0x17c062('0x960')],'html':!![],'shake':_0x4d9f83[_0x17c062('0x15cc')]||![],'onAdd':function(){const _0x44707e=_0x17c062;_0x1883bc[_0x44707e('0x210')][_0x4d9f83[_0x44707e('0x1c21')]]=this['id'];},'onAccept':function(){const _0x22f976=_0x17c062;_0x5150f3(_0x4d9f83);if(_0x2d99e3[_0x4d9f83[_0x22f976('0x1298')]+_0x22f976('0x1720')])return _0x2d99e3[_0x4d9f83[_0x22f976('0x1298')]+_0x22f976('0x1720')][_0x22f976('0x2384')]({'id':_0x4d9f83['id'],'UserId':_0x1883bc['user']['id'],'manual':!![]})['$promise'][_0x22f976('0x1166')](function(_0xd444df){const _0x47059b=_0x22f976;_0x1d7c9b(_0xd444df[_0x47059b('0x1298')],_0xd444df[_0x47059b('0x25e6')]),_0x592424[_0x47059b('0x103b')]({'title':_0x47059b('0x1ee7'),'msg':_0x47059b('0xfd2')});})[_0x22f976('0x1a80')](_0x14a1f7());},'onReject':function(){const _0x3b3314=_0x17c062;_0x5150f3(_0x4d9f83);if(_0x2d99e3[_0x4d9f83['channel']+'Message'])return _0x2d99e3[_0x4d9f83[_0x3b3314('0x1298')]+_0x3b3314('0x1720')][_0x3b3314('0x21bf')]({'id':_0x4d9f83['id'],'UserId':_0x1883bc[_0x3b3314('0x557')]['id']})['$promise'][_0x3b3314('0x1166')](function(){const _0x20ad52=_0x3b3314;_0x592424[_0x20ad52('0x103b')]({'title':_0x20ad52('0x24e6'),'msg':_0x20ad52('0x2198')});})['catch'](_0x14a1f7());}});}}function _0x5150f3(_0x466423){const _0x506348=_0x31a29d;_0x466423&&_0x466423[_0x506348('0x1c21')]&&(_0x1883bc['notifications'][_0x466423[_0x506348('0x1c21')]]&&(_0x592424[_0x506348('0x1657')](_0x1883bc[_0x506348('0x210')][_0x466423[_0x506348('0x1c21')]]),delete _0x1883bc[_0x506348('0x210')][_0x466423[_0x506348('0x1c21')]]));}function _0x348925(_0x2a9303){const _0x44f93d=_0x31a29d;if(!_0x2a9303[_0x44f93d('0xca8')]){_0x40ca7c(_0x2a9303['contact'],_0x2a9303[_0x44f93d('0x1242')]);return;}_0x593a2e['show']({'controller':_0x44f93d('0x166'),'controllerAs':'vm','templateUrl':_0x1aa062,'parent':angular[_0x44f93d('0x1194')](_0x30ee62[_0x44f93d('0x8d2')]),'locals':{'contacts':_0x2a9303[_0x44f93d('0xca8')],'callNumber':_0x2a9303[_0x44f93d('0x1242')][_0x44f93d('0x2423')]?_0x2a9303['evt'][_0x44f93d('0x2841')]:_0x2a9303[_0x44f93d('0x1242')][_0x44f93d('0x26a8')]}})[_0x44f93d('0x1166')](function(_0x310b9d){const _0x202d94=_0x44f93d;_0x40ca7c(_0x310b9d,_0x2a9303[_0x202d94('0x1242')]);});}function _0x2a3a2d(_0x565fd1){const _0x27b6c6=_0x31a29d;return _0x2d99e3[_0x27b6c6('0x129b')]['get']({'id':_0x565fd1[_0x27b6c6('0xc41')]})[_0x27b6c6('0xa44')][_0x27b6c6('0x1166')](function(_0x398d0b){const _0x4dd462=_0x27b6c6;if(_0x398d0b){if(_0x2cfb05()[_0x4dd462('0xe66')](_0x565fd1['xmd-contactid'])){try{_0x398d0b[_0x4dd462('0x1ff2')]=_0x5f0cec()[_0x4dd462('0x26a1')](_0x398d0b[_0x4dd462('0x1ff2')],_0x2cfb05()[_0x4dd462('0xcc3')](_0x565fd1,{'user':_0x1883bc[_0x4dd462('0x557')]}));}catch(_0x258ff8){console[_0x4dd462('0xfc9')](_0x258ff8);}_0x1bb0da({'type':_0x4dd462('0x179f'),'title':_0x398d0b[_0x4dd462('0x4f0')],'icon':_0x4dd462('0x865'),'color':_0x4dd462('0x1733'),'project':_0x398d0b,'call':_0x565fd1});}else return _0x2d99e3['cmContact']['get']({'id':_0x565fd1[_0x4dd462('0x2730')]})['$promise'][_0x4dd462('0x1166')](function(_0x3adcae){const _0x111dfd=_0x4dd462;try{_0x398d0b[_0x111dfd('0x1ff2')]=_0x5f0cec()[_0x111dfd('0x26a1')](_0x398d0b['formData'],_0x2cfb05()[_0x111dfd('0xcc3')](_0x565fd1,{'user':_0x1883bc[_0x111dfd('0x557')],'contact':_0x3adcae}));}catch(_0x367d6a){console[_0x111dfd('0xfc9')](_0x367d6a);}_0x1bb0da({'type':'jscripty','title':_0x398d0b[_0x111dfd('0x4f0')],'icon':_0x111dfd('0x865'),'color':_0x111dfd('0x1733'),'project':_0x398d0b,'call':_0x565fd1,'contact':_0x3adcae});})['catch'](_0x14a1f7());}})[_0x27b6c6('0x1a80')](_0x14a1f7());}function _0x2e2158(_0x54f515){const _0x1fc10a=_0x31a29d;if(_0x54f515&&_0x54f515['uri']){_0x54f515[_0x1fc10a('0x19ed')]=_0x2cfb05()['replace'](_0x54f515[_0x1fc10a('0x19ed')],_0x1fc10a('0x1d8b'),''),_0x54f515['uri']=_0x2cfb05()[_0x1fc10a('0xf3')](_0x54f515['uri'],_0x1fc10a('0x38b'),'');if(_0x54f515['uriLocation'])switch(_0x54f515[_0x1fc10a('0x1095')]){case'0':_0x2894cd[_0x1fc10a('0x1be3')](_0x54f515[_0x1fc10a('0x19ed')]);break;case'1':_0x2894cd[_0x1fc10a('0x1be3')](_0x54f515['uri'],'_blank',_0x1fc10a('0x2793')+(_0x54f515[_0x1fc10a('0x1196')]||_0x1fc10a('0x5ff'))+_0x1fc10a('0x1d7d')+_0x54f515[_0x1fc10a('0x11e2')]||0x0);break;case'2':{const _0x581e30={'type':_0x1fc10a('0x8ae'),'title':_0x54f515[_0x1fc10a('0x19ed')],'icon':_0x1fc10a('0x2052'),'color':_0x1fc10a('0x2708'),'src':_0x54f515['uri']};_0x1bb0da(_0x581e30);}break;default:_0x2894cd[_0x1fc10a('0x1be3')](_0x54f515[_0x1fc10a('0x19ed')]);}else _0x2894cd[_0x1fc10a('0x1be3')](_0x54f515[_0x1fc10a('0x19ed')]);}}function _0xd9be86(_0x1926de){const _0x220e8c=_0x31a29d;_0x1926de&&_0x1926de[_0x220e8c('0x1fe3')]&&_0x1bb0da({'type':_0x220e8c('0x15a0'),'title':_0x1926de['calleridnum']||_0x220e8c('0x15a0'),'icon':'icon-tablet','color':_0x220e8c('0x1733'),'html':_0x1926de[_0x220e8c('0x1fe3')]});}function _0x2613ea(_0x384a2e){const _0x2919a9=_0x31a29d,_0x41baed=_0x384a2e[_0x2919a9('0x1f24')]&&_0x384a2e[_0x2919a9('0x1f24')]!==_0x2919a9('0x1bf0')?_0x384a2e[_0x2919a9('0x1f24')]:_0x384a2e[_0x2919a9('0x26a8')],_0x1d67c3=_0x384a2e[_0x2919a9('0x26a8')];return _0x2d99e3[_0x2919a9('0xc3e')]['get']({'fields':'id','limit':0x1,'offset':0x0,'uniqueid':_0x384a2e[_0x2919a9('0x1c21')]})[_0x2919a9('0xa44')][_0x2919a9('0x1166')](function(_0x25ca48){const _0x28b643=_0x2919a9;_0x25ca48[_0x28b643('0x240f')]&&_0x1bb0da({'type':_0x28b643('0x1438'),'title':_0x41baed+'\x20<'+_0x1d67c3+'>','icon':_0x28b643('0x125a'),'color':_0x28b643('0x2324'),'data':{'uniqueid':_0x384a2e[_0x28b643('0x1c21')]}});});}function _0x3e6f7b(_0x10cd40){const _0xc8758d=_0x31a29d;console[_0xc8758d('0x11e')](_0xc8758d('0xbeb'),_0x10cd40);for(const _0x28b5b9 in _0x1883bc[_0xc8758d('0x137f')]){if(typeof _0x1883bc[_0xc8758d('0x137f')][_0x28b5b9]!=='undefined'){const _0x27ab3e=_0x1883bc[_0xc8758d('0x137f')][_0x28b5b9];if(_0x27ab3e[_0xc8758d('0x807')]){console[_0xc8758d('0x11e')](_0xc8758d('0xfc8'),_0x28b5b9,_0x27ab3e,_0x27ab3e[_0xc8758d('0x807')]);const _0x5e488c=_0x2cfb05()[_0xc8758d('0xede')](_0x27ab3e[_0xc8758d('0x807')],function(_0x942a8b){const _0x3f1879=_0xc8758d;return _0x942a8b[_0x3f1879('0x1c21')]===_0x10cd40[_0x3f1879('0x1c21')];});_0x5e488c>=0x0&&!_0x27ab3e[_0xc8758d('0x807')][_0x5e488c][_0xc8758d('0xf2c')]?(console['debug'](_0xc8758d('0x1e38'),_0x10cd40[_0xc8758d('0x1c21')]),_0x503609(_0x27ab3e[_0xc8758d('0x807')][_0x5e488c])):console['debug']('Call\x20%s\x20not\x20found\x20or\x20already\x20completed',_0x10cd40['uniqueid']),_0x1883bc['contact']&&_0x1883bc[_0xc8758d('0x26db')]['id']&&_0x3f7ce5(_0x15bdf6(_0x10cd40['uniqueid'],_0x1883bc['contact']['id'],_0x27ab3e),0x3e8);}}}_0xd64d1c();}function _0x15bdf6(_0xcf9931,_0xe29ada,_0x5d38ec){return function(){const _0x5501c1=a0_0x3f2c,_0x2c26ba=_0x2cfb05()[_0x5501c1('0xc38')](_0x5d38ec['calls'],function(_0x4eb218){const _0x48d367=_0x5501c1;return _0x4eb218[_0x48d367('0x1c21')]===_0xcf9931;});if(_0x2c26ba)return _0x2d99e3[_0x5501c1('0x26e0')][_0x5501c1('0x1449')]({'id':_0xcf9931,'ContactId':_0xe29ada})['$promise'][_0x5501c1('0x1a80')](function(_0x155942){const _0x181546=_0x5501c1;console[_0x181546('0xfc9')](_0x155942);});};}function _0x503609(_0x477a0c){const _0x46618d=_0x31a29d;_0x477a0c[_0x46618d('0xf2c')]=new Date();}function _0x14a1f7(){return function(_0x2d3fd0){const _0x333d78=a0_0x3f2c;if(_0x2d3fd0[_0x333d78('0x52d')]===0x194)_0x592424[_0x333d78('0x1ded')]({'title':_0x4b2314[_0x333d78('0x25cc')]('DASHBOARDS.ATTENTION'),'msg':_0x4b2314['instant'](_0x333d78('0x1e6e'))});else{if(_0x2d3fd0[_0x333d78('0x25f4')]&&_0x2d3fd0[_0x333d78('0x25f4')][_0x333d78('0x61a')]&&_0x2d3fd0[_0x333d78('0x25f4')][_0x333d78('0x61a')][_0x333d78('0x264b')]){_0x1883bc['errors']=_0x2d3fd0[_0x333d78('0x25f4')]['errors']||[{'message':_0x2d3fd0[_0x333d78('0x1586')](),'type':_0x333d78('0x253')}];for(let _0x4ccf4a=0x0;_0x4ccf4a<_0x2d3fd0['data'][_0x333d78('0x61a')][_0x333d78('0x264b')];_0x4ccf4a+=0x1){_0x592424[_0x333d78('0xfc9')]({'title':_0x2d3fd0[_0x333d78('0x25f4')][_0x333d78('0x61a')][_0x4ccf4a][_0x333d78('0x1345')],'msg':_0x2d3fd0[_0x333d78('0x25f4')][_0x333d78('0x61a')][_0x4ccf4a][_0x333d78('0x1e70')]});}}else _0x592424[_0x333d78('0xfc9')]({'title':_0x2d3fd0['status']?'API:'+_0x2d3fd0[_0x333d78('0x52d')]+_0x333d78('0x11e1')+_0x2d3fd0[_0x333d78('0xe1b')]:_0x333d78('0x253'),'msg':_0x2d3fd0[_0x333d78('0x25f4')]?JSON[_0x333d78('0xbac')](_0x2d3fd0[_0x333d78('0x25f4')]['message']):_0x2d3fd0[_0x333d78('0x1586')]()});}};}_0x1cf4cf[_0x31a29d('0x3d2')]('$destroy',function(){const _0x166613=_0x31a29d;for(const _0x35cf30 in _0x1883bc['notifications']){typeof _0x1883bc[_0x166613('0x210')][_0x35cf30]!==_0x166613('0x1048')&&_0x5150f3({'uniqueid':_0x35cf30});}_0x1821d8[_0x166613('0x1800')]('trigger:contactmanager'),_0x1821d8['removeAllListeners']('trigger:jscripty'),_0x1821d8[_0x166613('0x1800')](_0x166613('0x1349')),_0x1821d8['removeAllListeners'](_0x166613('0x26ea')),_0x1821d8[_0x166613('0x1800')](_0x166613('0x13f7')),_0x1821d8[_0x166613('0x1800')](_0x166613('0x4cb')),_0x1821d8[_0x166613('0x1800')](_0x166613('0x14fe')),_0x1821d8[_0x166613('0x1800')](_0x166613('0x125c'));});}function _0x495c1e(_0x132d3c,_0x4ca830,_0x20d467,_0x459bfb){const _0x3d9f73=_0x36e6f4,_0x24af6c={};let _0xddfaf5={},_0x5539df={},_0xb4cfe={};_0x24af6c[_0x3d9f73('0x24d5')]=function(){const _0x52ec8b=_0x3d9f73;_0x24af6c[_0x52ec8b('0x7a8')]=_0x22f18b();},_0x24af6c['getByInteraction']=function(_0x3b6b03){const _0xc260e2=_0x3d9f73;return _0x24af6c[_0xc260e2('0x7a8')]=_0x22f18b(),_0x2cfb05()[_0xc260e2('0xc38')](_0x2cfb05()[_0xc260e2('0x1ac1')](_0x24af6c[_0xc260e2('0x7a8')]),function(_0x41342b){const _0x496de5=_0xc260e2;return _0x41342b[_0x496de5('0x25e6')]&&_0x41342b[_0x496de5('0x25e6')]['id']===_0x3b6b03;});},_0x24af6c['removeByInteraction']=function(_0x2c6468){const _0x2e4b36=_0x3d9f73;_0x24af6c[_0x2e4b36('0x7a8')]=_0x22f18b();const _0x301b24=_0x2cfb05()[_0x2e4b36('0xc38')](_0x2cfb05()[_0x2e4b36('0x1ac1')](_0x24af6c[_0x2e4b36('0x7a8')]),function(_0x4972cf){const _0x4a2dc9=_0x2e4b36;return _0x4972cf[_0x4a2dc9('0x25e6')]&&_0x4972cf[_0x4a2dc9('0x25e6')]['id']===_0x2c6468;});_0x301b24&&(delete _0x24af6c['drafts'][_0x301b24['id']],_0x218281());},_0x24af6c['add']=function(_0x12d3b2){const _0x1a22c4=_0x3d9f73;_0x24af6c[_0x1a22c4('0x7a8')]=_0x22f18b();let _0x11ffd9=_0x4ca830[_0x1a22c4('0x25cc')](_0x1a22c4('0xecd'));if(_0x12d3b2[_0x1a22c4('0x26db')])_0x11ffd9=_0x12d3b2['contact'][_0x1a22c4('0x18cb')]||_0x12d3b2['contact'][_0x1a22c4('0x66f')];else!_0x2cfb05()['isEmpty'](_0x12d3b2[_0x1a22c4('0x1e70')][_0x1a22c4('0x210d')])&&(_0x11ffd9=_0x12d3b2[_0x1a22c4('0x1e70')][_0x1a22c4('0x210d')]);const _0x22e2cd={'type':_0x1a22c4('0xfca'),'title':_0x12d3b2[_0x1a22c4('0x1a32')][_0x1a22c4('0x7ca')]+'\x20-\x20'+_0x11ffd9,'channel':_0x12d3b2[_0x1a22c4('0x1298')],'content':_0x12d3b2[_0x1a22c4('0x1e70')],'account':_0x12d3b2[_0x1a22c4('0x1a32')],'interaction':_0x12d3b2[_0x1a22c4('0x25e6')],'id':_0x2cfb05()[_0x1a22c4('0x2010')](0x2540be400),'openedAt':new Date(),'saved':![]};_0x24af6c[_0x1a22c4('0x7a8')][_0x22e2cd['id']]=_0x22e2cd,_0x218281();},_0x24af6c[_0x3d9f73('0x1449')]=function(_0x2bdcd){const _0x22dfe5=_0x3d9f73;_0x24af6c[_0x22dfe5('0x7a8')]=_0x22f18b();const _0xb5762=_0x24af6c[_0x22dfe5('0x7a8')][_0x2bdcd['id']];_0xb5762&&(_0xb5762['content']=_0x2bdcd[_0x22dfe5('0x1e70')],_0x24af6c[_0x22dfe5('0x7a8')][_0x2bdcd['id']]=_0xb5762,_0x218281());},_0x24af6c[_0x3d9f73('0x1be3')]=function(_0x182058){const _0x56c1e9=_0x3d9f73;_0x24af6c[_0x56c1e9('0x7a8')]=_0x22f18b();const _0x23e631=_0x24af6c['drafts'][_0x182058];_0x23e631&&_0x132d3c[_0x56c1e9('0x1d73')]('open'+_0x2cfb05()[_0x56c1e9('0xb35')](_0x5539df)+_0x56c1e9('0x29a'),_0x23e631);},_0x24af6c[_0x3d9f73('0x127f')]=function(_0x284349){const _0x13c1ce=_0x3d9f73;_0x24af6c[_0x13c1ce('0x7a8')]=_0x22f18b(),_0x24af6c[_0x13c1ce('0x7a8')][_0x284349]&&(delete _0x24af6c[_0x13c1ce('0x7a8')][_0x284349],_0x218281());};function _0x22f18b(){const _0x4bdc70=_0x3d9f73;_0xddfaf5=_0x459bfb[_0x4bdc70('0x26cd')]();const _0xed6c76=_0x20d467[_0x4bdc70('0x275')][_0x4bdc70('0x15f7')](_0x4bdc70('0x1daa')+_0xddfaf5['id']);_0xed6c76?_0x5539df=JSON[_0x4bdc70('0x1295')](_0xed6c76)[_0x4bdc70('0x6d8')]:_0x5539df=_0x4bdc70('0xba2');_0xb4cfe=_0x20d467[_0x4bdc70('0x275')][_0x4bdc70('0x15f7')]('motion2.home.'+_0x5539df+':'+_0xddfaf5['id']);if(_0xb4cfe){const _0x446f70=JSON['parse'](_0xb4cfe);!_0x446f70[_0x4bdc70('0x7a8')]&&(_0x446f70['drafts']={}),_0xb4cfe=_0x446f70;}else _0xb4cfe={'drafts':{}};return _0xb4cfe[_0x4bdc70('0x7a8')];}function _0x218281(){const _0x5007ac=_0x3d9f73;_0x2cfb05()['isEmpty'](_0x24af6c[_0x5007ac('0x7a8')])?delete _0xb4cfe[_0x5007ac('0x7a8')]:_0xb4cfe[_0x5007ac('0x7a8')]=_0x24af6c[_0x5007ac('0x7a8')],_0x20d467[_0x5007ac('0x275')][_0x5007ac('0xa26')](_0x5007ac('0xec6')+_0x5539df+':'+_0xddfaf5['id'],JSON['stringify'](_0xb4cfe));}return _0x24af6c;}function _0x3807c3(){const _0x266fc6=_0x36e6f4,_0x1175f6={'autoClose':!![],'duration':0x5,'showOnPageHidden':![]};return{'config':_0x79dac4,'$get':['$q','$timeout',_0x266fc6('0x1566'),_0x266fc6('0x1c96'),_0x5e3f59]};function _0x79dac4(_0x30276a){const _0x41317a=_0x266fc6;for(const _0x128442 in _0x30276a){typeof _0x1175f6[_0x128442]!=='undefined'&&typeof _0x30276a[_0x128442]!==_0x41317a('0x1048')&&(_0x1175f6[_0x128442]=_0x30276a[_0x128442]);}}function _0x5e3f59(_0x39afe3,_0x38e4ec,_0x1a52af,_0x391a88){const _0x3289f9=_0x266fc6,_0x14f98a=_0x1a52af[_0x3289f9('0x14a0')]||_0x1a52af['mozNotification']||_0x1a52af['webkitNotification'],_0x2962b9={'isSupported':_0x8ba7a5,'currentPermission':_0x59da39,'requestPermission':_0x5d8a01,'show':_0x5511fd,'permissions':{'default':_0x391a88[_0x3289f9('0xbbf')],'granted':_0x391a88[_0x3289f9('0x4c8')],'denied':_0x391a88['DENIED']}};return _0x2962b9;function _0x8ba7a5(){const _0x430989=_0x3289f9;return!(typeof _0x14f98a===_0x430989('0x1048'));}function _0x59da39(){const _0x1f1063=_0x3289f9;return(_0x14f98a||{})[_0x1f1063('0x14ec')];}function _0x5d8a01(){const _0x449533=_0x3289f9;if(!_0x8ba7a5())return _0x39afe3[_0x449533('0x21bf')](_0x449533('0x170a'));const _0x24d927=_0x39afe3[_0x449533('0x24d8')]();return Promise[_0x449533('0x18af')](_0x14f98a[_0x449533('0x13d2')])==_0x14f98a['requestPermission']?_0x14f98a[_0x449533('0x13d2')]()[_0x449533('0x1166')](function(_0x42f4f3){const _0x24f74f=_0x449533;_0x391a88[_0x24f74f('0x4c8')]===_0x42f4f3?_0x24d927['resolve'](_0x42f4f3):_0x24d927['reject'](_0x42f4f3);}):_0x14f98a[_0x449533('0x13d2')](function(_0x4a8eeb){const _0xebb9d2=_0x449533;_0x391a88[_0xebb9d2('0x4c8')]===_0x4a8eeb?_0x24d927[_0xebb9d2('0x18af')](_0x4a8eeb):_0x24d927[_0xebb9d2('0x21bf')](_0x4a8eeb);}),_0x24d927[_0x449533('0x1f48')];}function _0x5511fd(_0x54c6b5,_0x55615c){const _0x515b64=_0x3289f9;_0x55615c=_0x55615c||{};if(!_0x8ba7a5()||!_0x425d11(_0x54c6b5,_0x55615c)||_0x4c1728(_0x55615c[_0x515b64('0xaeb')])||_0x59da39()!==_0x391a88['GRANTED'])return;const _0x36e4b4=new _0x14f98a(_0x54c6b5,_0x55615c),_0x39dd58=_0x55615c[_0x515b64('0x12fc')]||_0x1175f6['duration'],_0x57036a=_0x55615c['autoClose']===undefined?_0x1175f6[_0x515b64('0x229a')]:_0x55615c[_0x515b64('0x229a')];_0x36e4b4[_0x515b64('0x2508')]=function(){const _0x5482c0=_0x515b64;_0x55615c[_0x5482c0('0x1cd6')]&&_0x55615c[_0x5482c0('0x1cd6')](),_0x55615c[_0x5482c0('0xbe6')]&&window[_0x5482c0('0x22')](),_0x55615c[_0x5482c0('0xb32')]&&_0x36e4b4[_0x5482c0('0x1a7b')]();};if(_0x57036a)_0x42f45b(_0x36e4b4,_0x39dd58);return _0x36e4b4;}function _0x425d11(_0x122b11,_0x1b2278){const _0x247a06=_0x3289f9,_0x1330ba=angular[_0x247a06('0xd25')](_0x122b11),_0x4a5c12=!_0x1b2278[_0x247a06('0x1cd6')]||angular[_0x247a06('0x1a21')](_0x1b2278[_0x247a06('0x1cd6')]);return _0x1330ba&&_0x4a5c12;}function _0x4c1728(_0x2b636b){const _0xfbb302=_0x3289f9;if(!_0x2b636b&&!_0x1175f6['showOnPageHidden'])return;return!(window[_0xfbb302('0x136d')]['hidden']||window['document']['mozHidden']||window[_0xfbb302('0x136d')][_0xfbb302('0x3f8')]);}function _0x42f45b(_0x15e35e,_0x7282e7){const _0x5a9962=_0x7282e7*0x3e8;_0x38e4ec(_0x15e35e['close']['bind'](_0x15e35e),_0x5a9962,![]);}}}function _0x3d435d(){const _0x1b14df=_0x36e6f4,_0x2b9391=angular[_0x1b14df('0x4ed')](['ng'])[_0x1b14df('0xd83')](_0x1b14df('0x12de')),_0x37e5f1=[],_0x5dded4=this;_0x5dded4[_0x1b14df('0x13b8')]=_0x25d54a,_0x5dded4['deleteItem']=_0x4cc18d;function _0x25d54a(_0x3f70eb,_0x56fd72){const _0xe02a4d=_0x1b14df;if(!angular[_0xe02a4d('0xd25')](_0x3f70eb)){_0x2b9391[_0xe02a4d('0xfc9')](_0xe02a4d('0x1fd'));return;}const _0x252340=_0x3f70eb[_0xe02a4d('0x25c8')]('.'),_0x58e958=_0x252340[_0x252340[_0xe02a4d('0x264b')]-0x1],_0x570065=_0x8ef8b4(_0x252340);let _0x4fab22=![];for(let _0x1fd28c=0x0;_0x1fd28c<_0x570065[_0xe02a4d('0x264b')];_0x1fd28c++){if(_0x570065[_0x1fd28c][_0xe02a4d('0x1e25')]===_0x58e958){_0x4fab22=_0x570065[_0x1fd28c];break;}}_0x4fab22?(angular[_0xe02a4d('0x25a1')](_0x4fab22,_0x56fd72),_0x4fab22[_0xe02a4d('0x1c1c')]=_0x364936(_0x4fab22)):(_0x56fd72['children']=[],(angular[_0xe02a4d('0xe66')](_0x56fd72[_0xe02a4d('0x1f54')])||!angular[_0xe02a4d('0x1079')](_0x56fd72['weight']))&&(_0x56fd72[_0xe02a4d('0x1f54')]=0x1),_0x56fd72['_id']=_0x58e958,_0x56fd72[_0xe02a4d('0x2100')]=_0x3f70eb,_0x56fd72[_0xe02a4d('0x1c1c')]=_0x364936(_0x56fd72),_0x570065[_0xe02a4d('0x1514')](_0x56fd72));}function _0x4cc18d(_0x286f68){const _0x818fb=_0x1b14df;if(!angular[_0x818fb('0xd25')](_0x286f68)){_0x2b9391[_0x818fb('0xfc9')](_0x818fb('0x1fd'));return;}let _0x2a6e92=_0x37e5f1;const _0x4c0e6c=_0x286f68[_0x818fb('0x25c8')]('.');for(let _0x4ff453=0x0;_0x4ff453<_0x4c0e6c[_0x818fb('0x264b')];_0x4ff453++){const _0x72fcb6=_0x4c0e6c[_0x4ff453];for(let _0x142b84=0x0;_0x142b84<_0x2a6e92['length'];_0x142b84++){if(_0x2a6e92[_0x142b84][_0x818fb('0x1e25')]===_0x72fcb6){if(_0x2a6e92[_0x142b84]['_path']===_0x286f68)return _0x2a6e92[_0x818fb('0x57b')](_0x142b84,0x1),!![];_0x2a6e92=_0x2a6e92[_0x142b84]['children'];break;}}}return![];}function _0x8ef8b4(_0x447524){const _0x3e7bb8=_0x1b14df;let _0xbd2675=_0x37e5f1;if(_0x447524[_0x3e7bb8('0x264b')]===0x1)return _0xbd2675;_0x447524[_0x3e7bb8('0xf65')]();for(let _0x20a8ba=0x0;_0x20a8ba<_0x447524[_0x3e7bb8('0x264b')];_0x20a8ba++){const _0x5df58b=_0x447524[_0x20a8ba];let _0x3ff58b=!![];for(let _0x4461cb=0x0;_0x4461cb<_0xbd2675['length'];_0x4461cb++){if(_0xbd2675[_0x4461cb][_0x3e7bb8('0x1e25')]===_0x5df58b){_0xbd2675=_0xbd2675[_0x4461cb][_0x3e7bb8('0x9df')],_0x3ff58b=![];break;}}if(_0x3ff58b){const _0x4d2c6c={'_id':_0x5df58b,'_path':_0x447524[_0x3e7bb8('0x45a')]('.'),'title':_0x5df58b,'weight':0x1,'children':[]};_0xbd2675['push'](_0x4d2c6c),_0xbd2675=_0x4d2c6c[_0x3e7bb8('0x9df')];}}return _0xbd2675;}function _0x364936(_0x1c3ac9){const _0x56a1d6=_0x1b14df;let _0x2124a4='';return angular['isDefined'](_0x1c3ac9[_0x56a1d6('0x63f')])&&(_0x2124a4=_0x1c3ac9['state'],angular[_0x56a1d6('0x1e3f')](_0x1c3ac9[_0x56a1d6('0x1677')])&&angular[_0x56a1d6('0x235f')](_0x1c3ac9[_0x56a1d6('0x1677')])&&(_0x2124a4=_0x2124a4+'('+angular[_0x56a1d6('0xd2')](_0x1c3ac9['stateParams'])+')')),_0x2124a4;}this['$get']=function(){const _0x2b5400={'saveItem':_0x25d54a,'getNavigation':_0x437ca5};return _0x2b5400;function _0x437ca5(_0x1c74c2){const _0x3cf90d=a0_0x3f2c;if(_0x1c74c2){for(let _0x270f04=0x0;_0x270f04<_0x37e5f1['length'];_0x270f04++){if(_0x37e5f1[_0x270f04][_0x3cf90d('0x1e25')]===_0x1c74c2)return[_0x37e5f1[_0x270f04]];}return null;}return _0x37e5f1;}};}const _0x2ac441={'DEFAULT':_0x36e6f4('0x1526'),'GRANTED':'granted','DENIED':'denied'};_0x14656f['$inject']=[_0x36e6f4('0x19e3')];function _0x14656f(_0x278770){const _0x59a86f=_0x36e6f4,_0x1b0eef=this;_0x1b0eef[_0x59a86f('0xf8a')]={},_0x1b0eef['messages']={'count':0x0,'rows':[]},_0x1b0eef[_0x59a86f('0x1f3')]=![];function _0x535fa3(_0x3d41fc,_0x4ee7ae){const _0x52d41d=_0x59a86f;_0x1b0eef[_0x52d41d('0xf8a')]=_0x4ee7ae,_0x1b0eef[_0x52d41d('0xbe3')]=_0x3d41fc,_0x1b0eef[_0x52d41d('0xbe3')][_0x52d41d('0x26ae')]=!![];if(_0x1b0eef[_0x52d41d('0xbe3')]&&_0x1b0eef['tab'][_0x52d41d('0x25f4')]&&_0x1b0eef[_0x52d41d('0xbe3')][_0x52d41d('0x25f4')][_0x52d41d('0x1c21')])return _0x278770[_0x52d41d('0xc3e')][_0x52d41d('0xd83')]({'uniqueid':_0x1b0eef[_0x52d41d('0xbe3')][_0x52d41d('0x25f4')]['uniqueid']})['$promise'][_0x52d41d('0x1166')](function(_0x5ab085){const _0x152c4b=_0x52d41d;_0x1b0eef[_0x152c4b('0xcfa')]=_0x5ab085;})[_0x52d41d('0x1951')](function(){_0x1b0eef['showInteraction']=!![];});else _0x1b0eef[_0x52d41d('0x1f3')]=!![];}function _0x2953c5(_0x2ccb76){const _0x568de2=_0x59a86f;switch(_0x1b0eef[_0x568de2('0xf8a')]['messagesAlignment']){case _0x568de2('0xb0'):if(_0x2ccb76[_0x568de2('0x2788')]=='in')return _0x2ccb76['direction'];return _0x568de2('0x2497');case _0x568de2('0x8e4'):if(_0x2ccb76['direction']=='in')return'in-right-aligned';return _0x2ccb76[_0x568de2('0x2788')];default:return _0x2ccb76[_0x568de2('0x2788')];}}_0x1b0eef[_0x59a86f('0x24d5')]=_0x535fa3,_0x1b0eef[_0x59a86f('0x1ef')]=_0x2953c5;}const _0x342ae2=_0x14656f,_0x5b62a4=_0x2734b2['p']+_0x36e6f4('0x26ca'),_0x18c924=_0x2734b2['p']+_0x36e6f4('0xef2'),_0x5ccf28=_0x2734b2['p']+_0x36e6f4('0x2305'),_0x2d50de=_0x2734b2['p']+_0x36e6f4('0x193'),_0x5f05e0=_0x2734b2['p']+'src/js/modules/main/apps/dashboards/views/general/agent/interaction/composeMail/dialog.html/dialog.html',_0x283752=_0x2734b2['p']+_0x36e6f4('0x772'),_0x45ce09=_0x2734b2['p']+_0x36e6f4('0x260e'),_0x4b4a31=_0x2734b2['p']+_0x36e6f4('0x2875');_0x3de42b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),'$scope','$q','api','toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x586'),_0x36e6f4('0x1f36')];const _0x27e6b3={'fax':_0x2d50de,'mail':_0x5f05e0,'openchannel':_0x283752,'sms':_0x45ce09,'whatsapp':_0x4b4a31};function _0x3de42b(_0x212fa9,_0x4d08d9,_0x4c5bd7,_0x938ac,_0x2c6447,_0x54a0d8,_0x5dbf7e,_0xc7c6a0,_0xce7301,_0x4e63fe){const _0x383907=_0x36e6f4,_0x148f8c=this;_0x148f8c[_0x383907('0x557')]=_0xc7c6a0[_0x383907('0x26cd')](),_0x148f8c['detectBrowser']=_0x4e63fe[_0x383907('0x2694')](),_0x148f8c[_0x383907('0x227e')]=[],_0x148f8c[_0x383907('0x20b4')]={'fields':'id,phone,scheduledat','sort':_0x383907('0x14dc'),'limit':0xa,'page':0x1},_0x148f8c[_0x383907('0x25ca')]={'fields':_0x383907('0x353'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x148f8c[_0x383907('0x687')]={'fields':_0x383907('0xa91'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x148f8c[_0x383907('0x28c4')]={'rows':[],'count':0x0},_0x148f8c['finals']={'rows':[],'count':0x0},_0x148f8c['histories']={'rows':[],'count':0x0},_0x148f8c[_0x383907('0x2387')]=new Date(_0x24273b()()[_0x383907('0x1659')](_0x383907('0x2e7'))[_0x383907('0x6ab')](0x1,_0x383907('0x1aa6'))[_0x383907('0x13f2')](0x0,!![])[_0x383907('0x128a')]()),_0x148f8c[_0x383907('0x7dc')]=new Date(_0x24273b()()[_0x383907('0x2589')](_0x383907('0x2e7'))[_0x383907('0x6ab')](0x1,_0x383907('0x16a'))[_0x383907('0x13f2')](0x0,!![])[_0x383907('0x128a')]()),_0x148f8c[_0x383907('0xf58')]=_0x441f26,_0x148f8c[_0x383907('0x1aae')]=_0x52f6c3,_0x148f8c[_0x383907('0x1bb')]=_0x97d6be,_0x148f8c[_0x383907('0x200f')]=_0x938ac['$parent']['vm'][_0x383907('0x200f')],_0x148f8c['disposeCall']=_0x119041,_0x148f8c[_0x383907('0x22de')]=_0x71cdcd,_0x148f8c['mergeContact']=_0x51aee9,_0x148f8c[_0x383907('0x1a9c')]=_0x4eb680,_0x148f8c[_0x383907('0x1f9d')]=_0x5f4064,_0x148f8c[_0x383907('0xfee')]=_0x418327,_0x148f8c[_0x383907('0x2e6')]=_0x5f4fd3,_0x148f8c[_0x383907('0xe86')]=_0xc6ac69,_0x148f8c[_0x383907('0x1fc6')]=_0x174f94,_0x148f8c[_0x383907('0xf73')]=_0xd6fe9,_0x148f8c[_0x383907('0x1f63')]=_0x42af2d,_0x148f8c[_0x383907('0x1f5d')]=_0x131f3e,_0x148f8c[_0x383907('0x22a4')]=_0x5e1404,_0x148f8c[_0x383907('0xc48')]=_0x3de42a,_0x148f8c[_0x383907('0x36d')]=_0x99bfdf,_0x148f8c[_0x383907('0x5a1')]=_0xbd1fc3,_0x148f8c['composeInteraction']=_0x240947,_0x148f8c[_0x383907('0x24d5')]=_0x18af3d,_0x148f8c['hasPermission']=_0x409e41,_0x148f8c[_0x383907('0x12ea')]=_0x5763c5,_0x148f8c[_0x383907('0x3cb')]=_0x170b97,_0x148f8c[_0x383907('0x24c3')]=_0x2afbc0,_0x148f8c[_0x383907('0x1fc6')]();function _0x2afbc0(_0x5b57c6){const _0x8d8bc8=_0x383907;if(_0x5b57c6[_0x8d8bc8('0x18fe')])return _0x2cfb05()[_0x8d8bc8('0x1257')](_0x2cfb05()[_0x8d8bc8('0x2563')](_0x148f8c[_0x8d8bc8('0xd6c')]?_0x148f8c[_0x8d8bc8('0xd6c')][_0x8d8bc8('0x269a')]:[],'id'),_0x5b57c6[_0x8d8bc8('0x18fe')]);else{if(_0x5b57c6[_0x8d8bc8('0xb8')])return _0x2cfb05()['includes'](_0x2cfb05()[_0x8d8bc8('0x2563')](_0x148f8c[_0x8d8bc8('0x28ff')]?_0x148f8c[_0x8d8bc8('0x28ff')][_0x8d8bc8('0x269a')]:[],'id'),_0x5b57c6[_0x8d8bc8('0xb8')]);else{if(_0x5b57c6['SmsAccountId'])return _0x2cfb05()[_0x8d8bc8('0x1257')](_0x2cfb05()['map'](_0x148f8c[_0x8d8bc8('0x1d76')]?_0x148f8c[_0x8d8bc8('0x1d76')][_0x8d8bc8('0x269a')]:[],'id'),_0x5b57c6[_0x8d8bc8('0xa74')]);else{if(_0x5b57c6[_0x8d8bc8('0x1b88')])return _0x2cfb05()['includes'](_0x2cfb05()[_0x8d8bc8('0x2563')](_0x148f8c[_0x8d8bc8('0x1974')]?_0x148f8c[_0x8d8bc8('0x1974')]['rows']:[],'id'),_0x5b57c6[_0x8d8bc8('0x1b88')]);else{if(_0x5b57c6[_0x8d8bc8('0x56')])return _0x2cfb05()[_0x8d8bc8('0x1257')](_0x2cfb05()[_0x8d8bc8('0x2563')](_0x148f8c[_0x8d8bc8('0xf85')]?_0x148f8c['mailAccounts']['rows']:[],'id'),_0x5b57c6[_0x8d8bc8('0x56')]);else{if(_0x5b57c6[_0x8d8bc8('0x1e02')])return _0x2cfb05()['includes'](_0x2cfb05()[_0x8d8bc8('0x2563')](_0x148f8c['chatAccounts']?_0x148f8c[_0x8d8bc8('0x20e0')][_0x8d8bc8('0x269a')]:[],'id'),_0x5b57c6[_0x8d8bc8('0x1e02')]);else{if(_0x5b57c6[_0x8d8bc8('0x1f2c')])return!![];}}}}}}return![];}function _0x5763c5(_0x1b202b,_0x36f0e8){const _0x16910e=_0x383907;try{if(_0x36f0e8['MailAccountId'])return _0x938ac[_0x16910e('0x23ac')]['$parent'][_0x16910e('0x23ac')]['vm']['addInteractionTab'](_0x16910e('0x1bfa'),_0x36f0e8);else{if(_0x36f0e8[_0x16910e('0x1e02')])return _0x938ac[_0x16910e('0x23ac')][_0x16910e('0x23ac')][_0x16910e('0x23ac')]['vm']['addInteractionTab']('chat',_0x36f0e8);else{if(_0x36f0e8[_0x16910e('0xa74')])return _0x938ac['$parent'][_0x16910e('0x23ac')][_0x16910e('0x23ac')]['vm']['addInteractionTab'](_0x16910e('0x146c'),_0x36f0e8);else{if(_0x36f0e8[_0x16910e('0x1b88')])return _0x938ac[_0x16910e('0x23ac')][_0x16910e('0x23ac')]['$parent']['vm'][_0x16910e('0x126e')]('whatsapp',_0x36f0e8);else{if(_0x36f0e8[_0x16910e('0xb8')])return _0x938ac[_0x16910e('0x23ac')]['$parent'][_0x16910e('0x23ac')]['vm']['addInteractionTab']('openchannel',_0x36f0e8);else{if(_0x36f0e8['FaxAccountId'])return _0x938ac[_0x16910e('0x23ac')]['$parent'][_0x16910e('0x23ac')]['vm'][_0x16910e('0x126e')](_0x16910e('0x1fc7'),_0x36f0e8);}}}}}}catch(_0x49366d){_0x5dbf7e[_0x16910e('0xfc9')]({'title':_0x16910e('0x10ef'),'msg':_0x16910e('0x1330')});}}function _0x4ad2de(_0x59b6f4){const _0x16efe2=_0x383907;if(!_0x59b6f4['disposition'])return'('+_0xce7301['instant'](_0x16efe2('0x991'))+')';const _0x54f8a7=_0x2cfb05()['compact']([_0x59b6f4[_0x16efe2('0x12e8')],_0x59b6f4[_0x16efe2('0xe18')],_0x59b6f4[_0x16efe2('0x228e')]]);return'('+_0x54f8a7[_0x16efe2('0x45a')](_0x16efe2('0x11e1'))+')';}function _0x1bd5ac(_0x446f43){const _0x430724=_0x383907;_0x446f43&&_0x446f43[_0x430724('0x240f')]&&_0x446f43[_0x430724('0x269a')][_0x430724('0x264b')]&&(_0x148f8c[_0x430724('0x227e')]=_0x2cfb05()[_0x430724('0x1c6a')](_0x148f8c[_0x430724('0x227e')],_0x446f43[_0x430724('0x269a')]),_0x148f8c[_0x430724('0x227e')][_0x430724('0x2782')](function(_0x3a77e4){const _0x37d274=_0x430724;_0x3a77e4[_0x37d274('0x267e')]=_0x4ad2de(_0x3a77e4);}));}function _0x4e665c(_0x758764){const _0x2207cd=_0x383907,_0x4c9c28=['mail',_0x2207cd('0xde2'),_0x2207cd('0x146c'),_0x2207cd('0x26c'),_0x2207cd('0x1fc7'),_0x2207cd('0x116e')];if(_0x758764&&_0x758764['id']){for(let _0xdcf02c=0x0;_0xdcf02c<_0x4c9c28['length'];_0xdcf02c++){_0x54a0d8[_0x4c9c28[_0xdcf02c]+'Interaction']['get']({'ContactId':_0x758764['id'],'journey':!![],'includeAll':!![]})[_0x2207cd('0xa44')]['then'](_0x1bd5ac);}_0x54a0d8[_0x2207cd('0x26e0')][_0x2207cd('0xd83')]({'ContactId':_0x758764['id'],'includeAll':!![]})['$promise'][_0x2207cd('0x1166')](_0x1bd5ac)[_0x2207cd('0x1a80')](function(_0x4a888e){const _0x17ac40=_0x2207cd;console[_0x17ac40('0xfc9')](_0x4a888e);});}}function _0x19a4f6(_0x122c34){const _0x4affdb=_0x383907;switch(_0x122c34){case'chat':return _0x4affdb('0x1d17');case'mail':return'teal';case _0x4affdb('0x146c'):return _0x4affdb('0x1adc');case _0x4affdb('0x26c'):return _0x4affdb('0xb1e');case'fax':return'blue-grey-A200';case _0x4affdb('0x116e'):return _0x4affdb('0xe6d');default:return _0x4affdb('0x432');}}function _0x170b97(_0x404e44){const _0x55962b=_0x383907;let _0x2644e8='';if(_0x404e44[_0x55962b('0x18fe')])_0x2644e8=_0x55962b('0x1fc7');else{if(_0x404e44['OpenchannelAccountId'])_0x2644e8='openchannel';else{if(_0x404e44['SmsAccountId'])_0x2644e8=_0x55962b('0x146c');else{if(_0x404e44[_0x55962b('0x1b88')])_0x2644e8=_0x55962b('0x116e');else{if(_0x404e44[_0x55962b('0x56')])_0x2644e8='mail';else{if(_0x404e44[_0x55962b('0x1e02')])_0x2644e8=_0x55962b('0xde2');else _0x404e44[_0x55962b('0x1f2c')]&&(_0x2644e8=_0x55962b('0x21da'));}}}}}return _0x19a4f6(_0x2644e8);}function _0x18af3d(_0x3ce5b0,_0x54e08a){const _0x32db26=_0x383907;return _0x148f8c[_0x32db26('0xbe3')]=_0x3ce5b0,_0x938ac[_0x32db26('0x10d7')]([_0x32db26('0x2865'),_0x32db26('0x2046')],function(_0x2f16b5){const _0x5da685=_0x32db26;_0x148f8c['tab'][_0x5da685('0x26ae')]=_0x2f16b5[0x0]&&_0x2f16b5[0x1];}),_0x148f8c[_0x32db26('0x5c9')]=_0x54e08a,_0x148f8c[_0x32db26('0x26db')]=_0x148f8c[_0x32db26('0xbe3')][_0x32db26('0x26db')],_0x148f8c['newContact']=![],_0x148f8c[_0x32db26('0x623')]=0x0,_0x54a0d8[_0x32db26('0x557')][_0x32db26('0xd83')]({'fields':_0x32db26('0x1217'),'nolimit':!![]})[_0x32db26('0xa44')][_0x32db26('0x1166')](function(_0x5e8841){const _0x296624=_0x32db26;_0x148f8c['users']=_0x5e8841||{'count':0x0,'rows':[]},_0x148f8c[_0x296624('0x7b5')]=_0x2cfb05()[_0x296624('0x1f4d')](_0x2cfb05()[_0x296624('0x155c')](_0x148f8c[_0x296624('0x21f6')][_0x296624('0x269a')],'id'),_0x296624('0x6e1'));return;})[_0x32db26('0x1166')](function(){const _0x182f85=_0x32db26,_0x11204e=[];for(let _0x433a8b=0x0;_0x433a8b<_0x148f8c[_0x182f85('0xbe3')][_0x182f85('0x807')][_0x182f85('0x264b')];_0x433a8b++){const _0x41133a=_0x148f8c['tab'][_0x182f85('0x807')][_0x433a8b];_0x11204e[_0x182f85('0x1514')](_0x54a0d8[_0x182f85('0x26e0')][_0x182f85('0xd83')]({'uniqueid':_0x41133a[_0x182f85('0x1c21')]})[_0x182f85('0xa44')][_0x182f85('0x1166')](function(_0xe666f5){const _0x34bb35=_0x182f85;_0xe666f5&&_0xe666f5[_0x34bb35('0x269a')][_0x34bb35('0x264b')]>0x0&&(_0x41133a[_0x34bb35('0xf2c')]=_0x2cfb05()[_0x34bb35('0x215c')](_0xe666f5[_0x34bb35('0x269a')])[_0x34bb35('0x22e9')]);return;}));}return _0x2c6447[_0x182f85('0x2760')](_0x11204e);})[_0x32db26('0x1166')](function(){const _0x383be1=_0x32db26;if(_0x148f8c[_0x383be1('0x26db')]&&_0x148f8c[_0x383be1('0x26db')]['id']){const _0x8ff1c={'id':_0x148f8c[_0x383be1('0x26db')]['id'],'ListId':_0x148f8c['contact'][_0x383be1('0x23c')],'limit':0x1,'offset':0x0,'sort':_0x383be1('0x14dc')};return _0x54a0d8['cmContact'][_0x383be1('0xd83')](_0x8ff1c)[_0x383be1('0xa44')][_0x383be1('0x1166')](function(_0x550e42){const _0x521cfc=_0x383be1;return _0x148f8c[_0x521cfc('0x26db')]=_0x550e42,_0x148f8c['tab'][_0x521cfc('0x26db')]=_0x550e42,_0x54a0d8['user']['addContacts']({'id':_0x148f8c[_0x521cfc('0x557')]['id'],'ids':[_0x148f8c[_0x521cfc('0x26db')]['id']]});})[_0x383be1('0x1166')](function(){const _0x1f9f53=_0x383be1;if(_0x148f8c['contact'][_0x1f9f53('0x23c')])return _0x54a0d8[_0x1f9f53('0x12e8')][_0x1f9f53('0xd83')]({'ListId':_0x148f8c[_0x1f9f53('0x26db')][_0x1f9f53('0x23c')]})[_0x1f9f53('0xa44')][_0x1f9f53('0x1166')](function(_0x5522b6){const _0x2292ac=_0x1f9f53;return _0x148f8c['tab']['dispositions']=_0x5522b6,_0x54a0d8[_0x2292ac('0xdd9')][_0x2292ac('0x1bb')]({'id':_0x148f8c[_0x2292ac('0x26db')]['ListId']})[_0x2292ac('0xa44')];})['then'](function(_0x40b640){const _0x50f029=_0x1f9f53;_0x148f8c[_0x50f029('0xbe3')][_0x50f029('0x23d7')]=_0x40b640;return;});return;})[_0x383be1('0x1166')](function(){const _0x4d1029=_0x383be1;try{_0x148f8c[_0x4d1029('0xbe3')][_0x4d1029('0x2179')]=_0x938ac['$parent'][_0x4d1029('0x23ac')]['$parent']['vm']['globalUserLists'],_0x148f8c[_0x4d1029('0xbe3')][_0x4d1029('0x8de')]=_0x938ac['$parent'][_0x4d1029('0x23ac')][_0x4d1029('0x23ac')]['vm']['globalLists'],_0x148f8c[_0x4d1029('0xbe3')][_0x4d1029('0xfd1')]=_0x938ac[_0x4d1029('0x23ac')][_0x4d1029('0x23ac')][_0x4d1029('0x23ac')]['vm'][_0x4d1029('0x69')],_0x148f8c[_0x4d1029('0xbe3')]['tags']=_0x938ac[_0x4d1029('0x23ac')][_0x4d1029('0x23ac')][_0x4d1029('0x23ac')]['vm']['globalTags'],_0x148f8c['tab'][_0x4d1029('0x166c')]=0x0,_0x148f8c[_0x4d1029('0x26db')][_0x4d1029('0x23c')]&&(_0x148f8c[_0x4d1029('0xbe3')][_0x4d1029('0x2179')][_0x4d1029('0x269a')]=_0x2cfb05()[_0x4d1029('0x2231')](_0x148f8c[_0x4d1029('0xbe3')]['userLists']['rows'],_0x2cfb05()[_0x4d1029('0x1c33')](_0x148f8c[_0x4d1029('0xbe3')][_0x4d1029('0x8de')][_0x4d1029('0x269a')],{'id':_0x148f8c[_0x4d1029('0x26db')][_0x4d1029('0x23c')]}),'id'),_0x148f8c[_0x4d1029('0x1480')]=_0x2cfb05()['find'](_0x148f8c['tab'][_0x4d1029('0x2179')]['rows'],{'id':_0x148f8c[_0x4d1029('0x26db')][_0x4d1029('0x23c')]}));}catch(_0xa4c738){}_0x148f8c[_0x4d1029('0xfee')](),_0x148f8c[_0x4d1029('0x2e6')](),_0x148f8c[_0x4d1029('0xe86')](),_0x148f8c[_0x4d1029('0xf73')](),_0x148f8c['getFaxAccounts'](),_0x148f8c['getSmsAccounts'](),_0x148f8c[_0x4d1029('0x22a4')](),_0x148f8c[_0x4d1029('0xc48')](),_0x148f8c[_0x4d1029('0x36d')](),_0x148f8c[_0x4d1029('0x5a1')]();return;})[_0x383be1('0x1166')](function(){const _0x59c7fe=_0x383be1;return _0x54a0d8[_0x59c7fe('0x149e')][_0x59c7fe('0x1524')]({'id':_0x148f8c[_0x59c7fe('0x26db')]['id']})[_0x59c7fe('0xa44')][_0x59c7fe('0x1166')](function(_0x554e75){const _0x2bb62f=_0x59c7fe;_0x148f8c[_0x2bb62f('0xbe3')][_0x2bb62f('0x21c2')]=_0x2cfb05()['map'](_0x554e75['rows'],'id');return;});});}else{_0x148f8c[_0x383be1('0x1018')]=!![];if(_0x3ce5b0[_0x383be1('0x166c')])return console[_0x383be1('0x455')](_0x383be1('0x166c')),_0x148f8c[_0x383be1('0xf58')]();return;}})['then'](_0x4e665c(_0x148f8c[_0x32db26('0x26db')]));}function _0x240947(_0xfe9cfc,_0x44c2a0,_0x40c0be,_0x5d98d7){const _0x3576c4=_0x383907,_0x1bf780=_0x44c2a0[_0x3576c4('0x2574')]();_0x212fa9[_0x3576c4('0x1f80')]({'controller':_0x3576c4('0x13ab')+_0x44c2a0+_0x3576c4('0x9ee'),'controllerAs':'vm','templateUrl':_0x27e6b3[_0x1bf780],'parent':angular[_0x3576c4('0x1194')](_0x4d08d9[_0x3576c4('0x8d2')]),'clickOutsideToClose':![],'locals':{'account':_0x40c0be,'message':{'to':_0x1bf780==_0x3576c4('0x1bfa')?_0x5d98d7:_0x5d98d7[_0x3576c4('0x25c8')](',')},'type':_0x3576c4('0xd11'),'interaction':{'Contact':_0x148f8c[_0x3576c4('0x26db')]}},'fullscreen':!![]})[_0x3576c4('0x1166')](function(_0x53686c){const _0x581eae=_0x3576c4;return _0x54a0d8[_0x1bf780+_0x581eae('0x1758')]['send']({'id':_0x40c0be['id']},_0x53686c)['$promise'][_0x581eae('0x1166')](function(_0x240796){const _0x4bc3d4=_0x581eae;if(_0x44c2a0===_0x4bc3d4('0x22e7')){const _0x44a880=_0x240796;if(_0x44a880&&_0x44a880['Messages']&&_0x44a880[_0x4bc3d4('0x116c')][_0x4bc3d4('0x264b')]){if(_0x53686c[_0x4bc3d4('0x1e1d')]&&_0x53686c['attachments'][_0x4bc3d4('0x264b')])for(let _0x5e86b7=0x0;_0x5e86b7<_0x53686c['attachments']['length'];_0x5e86b7+=0x1){_0x54a0d8[_0x4bc3d4('0x21bc')]['update']({'id':_0x53686c['attachments'][_0x5e86b7]['id']},{'MailMessageId':_0x2cfb05()[_0x4bc3d4('0x345')](_0x44a880[_0x4bc3d4('0x116c')])['id']});}_0x5dbf7e[_0x4bc3d4('0x103b')]({'title':_0x4bc3d4('0x11ac'),'msg':_0x4bc3d4('0x1605')});if(_0x44a880[_0x4bc3d4('0xa5b')]){_0x44a880['disposition']=null;const _0x46eaed=!_0x40c0be[_0x4bc3d4('0x10d0')],_0x33897f=_0x148f8c['user'][_0x4bc3d4('0x2540')]||_0x148f8c[_0x4bc3d4('0x557')][_0x4bc3d4('0x1c5c')]||_0x148f8c['user'][_0x4bc3d4('0xb4')]||_0x148f8c[_0x4bc3d4('0x557')][_0x4bc3d4('0x287f')]||_0x148f8c['user'][_0x4bc3d4('0x5aa')];_0x212fa9[_0x4bc3d4('0x1f80')]({'controller':_0x4bc3d4('0xa39'),'controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular['element'](_0x4d08d9['body']),'onRemoving':function(){const _0x145ee9=_0x4bc3d4;_0x148f8c['user']&&_0x40c0be[_0x145ee9('0x10d0')]&&!_0x33897f&&_0x54a0d8[_0x145ee9('0x557')][_0x145ee9('0x20eb')]({'id':_0x148f8c[_0x145ee9('0x557')]['id']})[_0x145ee9('0xa44')][_0x145ee9('0x1a80')](function(_0x20b252){const _0x91fabe=_0x145ee9;console[_0x91fabe('0xfc9')](_0x20b252);});},'clickOutsideToClose':_0x46eaed,'escapeToClose':_0x46eaed,'locals':{'user':_0x148f8c[_0x4bc3d4('0x557')],'channel':_0x4bc3d4('0x1bfa'),'interaction':_0x44a880}});}else _0x938ac[_0x4bc3d4('0x23ac')]['vm'][_0x4bc3d4('0x126e')](_0x4bc3d4('0x1bfa'),_0x44a880);}}else _0x5dbf7e[_0x4bc3d4('0x103b')]({'title':_0x4bc3d4('0x11ac'),'msg':'Message\x20has\x20been\x20sent!'}),_0x938ac[_0x4bc3d4('0x23ac')]['vm'][_0x4bc3d4('0x126e')](_0x1bf780,_0x240796);})[_0x581eae('0x1a80')](function(_0x54d435){const _0x53ca28=_0x581eae;if(_0x54d435['data']&&_0x54d435['data']['errors']&&_0x54d435[_0x53ca28('0x25f4')][_0x53ca28('0x61a')][_0x53ca28('0x264b')])for(let _0x58de4e=0x0;_0x58de4e<_0x54d435[_0x53ca28('0x25f4')][_0x53ca28('0x61a')][_0x53ca28('0x264b')];_0x58de4e+=0x1){_0x5dbf7e[_0x53ca28('0xfc9')]({'title':_0x54d435[_0x53ca28('0x25f4')][_0x53ca28('0x61a')][_0x58de4e][_0x53ca28('0x1345')],'msg':_0x54d435[_0x53ca28('0x25f4')]['errors'][_0x58de4e][_0x53ca28('0x1e70')]});}else _0x1bf780===_0x53ca28('0x1fc7')?_0x5dbf7e['error']({'title':'FAX:SEND','msg':_0x54d435['data']?JSON['stringify'](_0x54d435[_0x53ca28('0x25f4')]):_0x54d435[_0x53ca28('0x1e70')]||_0x54d435['toString']()}):_0x5dbf7e[_0x53ca28('0xfc9')]({'title':_0x54d435[_0x53ca28('0x52d')]?_0x53ca28('0x1e21')+_0x54d435[_0x53ca28('0x52d')]+_0x53ca28('0x11e1')+_0x54d435['statusText']:_0x44c2a0['toUpperCase']()+_0x53ca28('0x45b'),'msg':_0x54d435[_0x53ca28('0x25f4')]?JSON[_0x53ca28('0xbac')](_0x54d435[_0x53ca28('0x25f4')][_0x53ca28('0x1e70')]):_0x54d435[_0x53ca28('0x1e70')]||_0x54d435[_0x53ca28('0x1586')]()});});});}function _0x441f26(){const _0x11c1d0=_0x383907;_0x148f8c[_0x11c1d0('0x61a')]=[],_0x54a0d8[_0x11c1d0('0x149e')][_0x11c1d0('0x9cc')](_0x148f8c[_0x11c1d0('0x26db')])[_0x11c1d0('0xa44')][_0x11c1d0('0x1166')](function(_0x33d274){const _0x1054de=_0x11c1d0;return _0x148f8c['contact']['id']=_0x33d274['id'],_0x148f8c[_0x1054de('0x1018')]=![],_0x148f8c[_0x1054de('0xbe3')][_0x1054de('0xcdc')]=_0x33d274[_0x1054de('0x18cb')]||_0x33d274[_0x1054de('0x2026')],_0x148f8c[_0x1054de('0xbe3')][_0x1054de('0x26db')]=_0x148f8c[_0x1054de('0x26db')],_0x54a0d8['user'][_0x1054de('0x22f4')]({'id':_0xc7c6a0[_0x1054de('0x26cd')]()['id'],'ids':[_0x33d274['id']]});})[_0x11c1d0('0x1166')](function(){const _0x15663f=_0x11c1d0;_0x148f8c[_0x15663f('0x1dd')][_0x15663f('0x514')]=!![],_0x148f8c[_0x15663f('0x1ef6')]['$pristine']=!![],_0x5dbf7e[_0x15663f('0x103b')]({'title':_0x15663f('0x254d'),'msg':_0x148f8c['contact'][_0x15663f('0x18cb')]?_0x148f8c[_0x15663f('0x26db')]['firstName']+_0x15663f('0x1eda'):''});})[_0x11c1d0('0x1166')](function(){const _0x1cf89f=_0x11c1d0;return _0x54a0d8['cmContact']['setTags']({'id':_0x148f8c[_0x1cf89f('0x26db')]['id'],'ids':_0x148f8c[_0x1cf89f('0xbe3')][_0x1cf89f('0x21c2')]})[_0x1cf89f('0xa44')];})[_0x11c1d0('0x1a80')](function(_0x1c46e0){const _0xcecb29=_0x11c1d0;if(_0x1c46e0['data']&&_0x1c46e0[_0xcecb29('0x25f4')][_0xcecb29('0x61a')]&&_0x1c46e0[_0xcecb29('0x25f4')][_0xcecb29('0x61a')][_0xcecb29('0x264b')]){_0x148f8c[_0xcecb29('0x61a')]=_0x1c46e0['data'][_0xcecb29('0x61a')]||[{'message':_0x1c46e0[_0xcecb29('0x1586')](),'type':_0xcecb29('0x257f')}];for(let _0x59c587=0x0;_0x59c587<_0x1c46e0[_0xcecb29('0x25f4')][_0xcecb29('0x61a')][_0xcecb29('0x264b')];_0x59c587+=0x1){_0x5dbf7e['error']({'title':_0x1c46e0['data'][_0xcecb29('0x61a')][_0x59c587][_0xcecb29('0x1345')],'msg':_0x1c46e0[_0xcecb29('0x25f4')]['errors'][_0x59c587][_0xcecb29('0x1e70')]});}}else _0x5dbf7e[_0xcecb29('0xfc9')]({'title':_0x1c46e0[_0xcecb29('0x52d')]?_0xcecb29('0x1e21')+_0x1c46e0[_0xcecb29('0x52d')]+_0xcecb29('0x11e1')+_0x1c46e0[_0xcecb29('0xe1b')]:_0xcecb29('0x257f'),'msg':_0x1c46e0['data']?JSON[_0xcecb29('0xbac')](_0x1c46e0[_0xcecb29('0x25f4')][_0xcecb29('0x1e70')]):_0x1c46e0[_0xcecb29('0x1586')]()});});}function _0x52f6c3(){const _0x400dbc=_0x383907;_0x148f8c[_0x400dbc('0x61a')]=[],_0x54a0d8[_0x400dbc('0x149e')][_0x400dbc('0x1449')]({'id':_0x148f8c[_0x400dbc('0x26db')]['id']},_0x148f8c[_0x400dbc('0x26db')])['$promise'][_0x400dbc('0x1166')](function(_0x1fafc4){const _0x417e4c=_0x400dbc;return _0x148f8c[_0x417e4c('0xbe3')][_0x417e4c('0xcdc')]=_0x1fafc4[_0x417e4c('0x18cb')]||_0x1fafc4[_0x417e4c('0x2026')],_0x148f8c[_0x417e4c('0xbe3')][_0x417e4c('0x26db')]=_0x148f8c['contact'],_0x938ac[_0x417e4c('0x23ac')]['vm'][_0x417e4c('0x1a4f')](),_0x54a0d8['user'][_0x417e4c('0x22f4')]({'id':_0xc7c6a0[_0x417e4c('0x26cd')]()['id'],'ids':[_0x1fafc4['id']]});})[_0x400dbc('0x1166')](function(){const _0x1d6c73=_0x400dbc;return _0x54a0d8[_0x1d6c73('0x149e')][_0x1d6c73('0x61b')]({'id':_0x148f8c[_0x1d6c73('0x26db')]['id'],'ids':_0x148f8c[_0x1d6c73('0xbe3')][_0x1d6c73('0x21c2')]})[_0x1d6c73('0xa44')];})['then'](function(){const _0x4bf687=_0x400dbc;_0x148f8c['detailForm'][_0x4bf687('0x514')]=!![],_0x148f8c[_0x4bf687('0x1ef6')]['$pristine']=!![],_0x5dbf7e[_0x4bf687('0x103b')]({'title':_0x4bf687('0x2386'),'msg':_0x148f8c[_0x4bf687('0x26db')][_0x4bf687('0x4f0')]?_0x148f8c[_0x4bf687('0x26db')][_0x4bf687('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x400dbc('0x1a80')](function(_0xca03f4){const _0x1e67c1=_0x400dbc;if(_0xca03f4[_0x1e67c1('0x25f4')]&&_0xca03f4[_0x1e67c1('0x25f4')][_0x1e67c1('0x61a')]&&_0xca03f4[_0x1e67c1('0x25f4')][_0x1e67c1('0x61a')][_0x1e67c1('0x264b')]){_0x148f8c[_0x1e67c1('0x61a')]=_0xca03f4[_0x1e67c1('0x25f4')][_0x1e67c1('0x61a')]||[{'message':_0xca03f4['toString'](),'type':'api.contact.save'}];for(let _0x197fdc=0x0;_0x197fdc<_0xca03f4[_0x1e67c1('0x25f4')]['errors'][_0x1e67c1('0x264b')];_0x197fdc+=0x1){_0x5dbf7e['error']({'title':_0xca03f4[_0x1e67c1('0x25f4')][_0x1e67c1('0x61a')][_0x197fdc]['type'],'msg':_0xca03f4[_0x1e67c1('0x25f4')][_0x1e67c1('0x61a')][_0x197fdc][_0x1e67c1('0x1e70')]});}}else _0x5dbf7e[_0x1e67c1('0xfc9')]({'title':_0xca03f4[_0x1e67c1('0x52d')]?'API:'+_0xca03f4['status']+_0x1e67c1('0x11e1')+_0xca03f4[_0x1e67c1('0xe1b')]:_0x1e67c1('0x257f'),'msg':_0xca03f4[_0x1e67c1('0x25f4')]?JSON[_0x1e67c1('0xbac')](_0xca03f4[_0x1e67c1('0x25f4')][_0x1e67c1('0x1e70')]):_0xca03f4[_0x1e67c1('0x1586')]()});});}_0x938ac[_0x383907('0xe83')](_0x383907('0x623'),function(){const _0x24a155=_0x383907;_0x148f8c[_0x24a155('0x623')]===0x1&&(_0x148f8c[_0x24a155('0xfee')](),_0x148f8c[_0x24a155('0x2e6')](),_0x148f8c[_0x24a155('0xe86')]());});let _0x4ed3d2=!![],_0x29ffcc=0x1;_0x938ac['$watch'](_0x383907('0x221f'),function(_0x5e79f8,_0x42a1c2){const _0x20bfe6=_0x383907;_0x4ed3d2?_0x4c5bd7(function(){_0x4ed3d2=![];}):(!_0x42a1c2&&(_0x29ffcc=_0x148f8c['queryHopper'][_0x20bfe6('0x1a43')]),_0x5e79f8!==_0x42a1c2&&(_0x148f8c[_0x20bfe6('0x20b4')][_0x20bfe6('0x1a43')]=0x1),!_0x5e79f8&&(_0x148f8c[_0x20bfe6('0x20b4')][_0x20bfe6('0x1a43')]=_0x29ffcc),_0x148f8c['getHoppers']());}),_0x938ac[_0x383907('0xe83')](_0x383907('0x221e'),function(_0x5f0784,_0xb7e6b4){const _0x714dc3=_0x383907;_0x4ed3d2?_0x4c5bd7(function(){_0x4ed3d2=![];}):(!_0xb7e6b4&&(_0x29ffcc=_0x148f8c[_0x714dc3('0x25ca')]['page']),_0x5f0784!==_0xb7e6b4&&(_0x148f8c[_0x714dc3('0x25ca')][_0x714dc3('0x1a43')]=0x1),!_0x5f0784&&(_0x148f8c['queryFinal'][_0x714dc3('0x1a43')]=_0x29ffcc),_0x148f8c['getFinals']());}),_0x938ac['$watch']('queryHistory.filter',function(_0x10af25,_0x4c51b8){const _0x1fcacf=_0x383907;_0x4ed3d2?_0x4c5bd7(function(){_0x4ed3d2=![];}):(!_0x4c51b8&&(_0x29ffcc=_0x148f8c[_0x1fcacf('0x687')][_0x1fcacf('0x1a43')]),_0x10af25!==_0x4c51b8&&(_0x148f8c[_0x1fcacf('0x687')][_0x1fcacf('0x1a43')]=0x1),!_0x10af25&&(_0x148f8c['queryHistory'][_0x1fcacf('0x1a43')]=_0x29ffcc),_0x148f8c['getHistories']());});function _0x5ef23a(_0x328a4a){return function(_0x4b50fb){_0x148f8c[_0x328a4a]=_0x4b50fb||{'count':0x0,'rows':[]};};}function _0x418327(){const _0x18ec26=_0x383907;_0x148f8c[_0x18ec26('0x26db')]&&_0x148f8c[_0x18ec26('0x26db')]['id']&&(_0x148f8c[_0x18ec26('0x20b4')][_0x18ec26('0x1a17')]=_0x148f8c['contact']['id'],_0x148f8c['queryHopper'][_0x18ec26('0x1098')]=(_0x148f8c[_0x18ec26('0x20b4')]['page']-0x1)*_0x148f8c[_0x18ec26('0x20b4')][_0x18ec26('0x163f')],_0x148f8c['promise']=_0x54a0d8[_0x18ec26('0x256a')][_0x18ec26('0xd83')](_0x148f8c[_0x18ec26('0x20b4')],_0x5ef23a(_0x18ec26('0x28c4')))[_0x18ec26('0xa44')]);}function _0x5f4fd3(){const _0x202381=_0x383907;_0x148f8c[_0x202381('0x26db')]&&_0x148f8c['contact']['id']&&(_0x148f8c[_0x202381('0x25ca')]['ContactId']=_0x148f8c[_0x202381('0x26db')]['id'],_0x148f8c[_0x202381('0x25ca')][_0x202381('0x1098')]=(_0x148f8c['queryFinal'][_0x202381('0x1a43')]-0x1)*_0x148f8c[_0x202381('0x25ca')]['limit'],_0x148f8c['promise']=_0x54a0d8[_0x202381('0x1806')][_0x202381('0xd83')](_0x148f8c['queryFinal'],_0x5ef23a(_0x202381('0x17d9')))['$promise']);}function _0xc6ac69(){const _0x46d790=_0x383907;_0x148f8c['contact']&&_0x148f8c['contact']['id']&&(_0x148f8c['queryHistory'][_0x46d790('0x1a17')]=_0x148f8c[_0x46d790('0x26db')]['id'],_0x148f8c[_0x46d790('0x687')][_0x46d790('0x1098')]=(_0x148f8c[_0x46d790('0x687')]['page']-0x1)*_0x148f8c[_0x46d790('0x687')]['limit'],_0x148f8c[_0x46d790('0x1f48')]=_0x54a0d8[_0x46d790('0x1a26')][_0x46d790('0xd83')](_0x148f8c[_0x46d790('0x687')],_0x5ef23a(_0x46d790('0x1f7c')))[_0x46d790('0xa44')]);}function _0x174f94(){const _0x56b497=_0x383907;_0x54a0d8[_0x56b497('0x129b')][_0x56b497('0xd83')]({'fields':_0x56b497('0xa87'),'sort':_0x56b497('0x14dc'),'nolimit':!![]})[_0x56b497('0xa44')][_0x56b497('0x1166')](function(_0x3a5209){const _0x32c1c9=_0x56b497;_0x148f8c[_0x32c1c9('0x15e4')]=_0x3a5209||{'count':0x0,'rows':[]};})[_0x56b497('0x1a80')](function(_0x916a94){const _0x5990dc=_0x56b497;if(_0x916a94['data']&&_0x916a94['data'][_0x5990dc('0x61a')]&&_0x916a94['data'][_0x5990dc('0x61a')][_0x5990dc('0x264b')]){_0x148f8c[_0x5990dc('0x61a')]=_0x916a94[_0x5990dc('0x25f4')][_0x5990dc('0x61a')]||[{'message':_0x916a94[_0x5990dc('0x1586')](),'type':_0x5990dc('0x12c6')}];for(let _0x2387da=0x0;_0x2387da<_0x916a94[_0x5990dc('0x25f4')]['errors'][_0x5990dc('0x264b')];_0x2387da+=0x1){_0x5dbf7e[_0x5990dc('0xfc9')]({'title':_0x916a94[_0x5990dc('0x25f4')][_0x5990dc('0x61a')][_0x2387da][_0x5990dc('0x1345')],'msg':_0x916a94[_0x5990dc('0x25f4')][_0x5990dc('0x61a')][_0x2387da][_0x5990dc('0x1e70')]});}}else _0x5dbf7e[_0x5990dc('0xfc9')]({'title':_0x916a94[_0x5990dc('0x52d')]?_0x5990dc('0x1e21')+_0x916a94[_0x5990dc('0x52d')]+_0x5990dc('0x11e1')+_0x916a94[_0x5990dc('0xe1b')]:_0x5990dc('0x12c6'),'msg':_0x916a94[_0x5990dc('0x25f4')]?JSON[_0x5990dc('0xbac')](_0x916a94['data'][_0x5990dc('0x1e70')]):_0x916a94['toString']()});});}function _0xd6fe9(){const _0x4497da=_0x383907;_0x54a0d8[_0x4497da('0x557')][_0x4497da('0xf73')]({'id':_0x148f8c[_0x4497da('0x557')]['id'],'nolimit':!![]})[_0x4497da('0xa44')][_0x4497da('0x1166')](function(_0x4667e2){const _0x11c057=_0x4497da;_0x148f8c[_0x11c057('0xf85')]=_0x4667e2||{'count':0x0,'rows':[]};})[_0x4497da('0x1a80')](function(_0x2894c3){const _0x337567=_0x4497da;if(_0x2894c3['data']&&_0x2894c3[_0x337567('0x25f4')][_0x337567('0x61a')]&&_0x2894c3[_0x337567('0x25f4')]['errors'][_0x337567('0x264b')]){_0x148f8c[_0x337567('0x61a')]=_0x2894c3['data'][_0x337567('0x61a')]||[{'message':_0x2894c3[_0x337567('0x1586')](),'type':'api.mail.account'}];for(let _0x166a94=0x0;_0x166a94<_0x2894c3[_0x337567('0x25f4')][_0x337567('0x61a')][_0x337567('0x264b')];_0x166a94+=0x1){_0x5dbf7e['error']({'title':_0x2894c3[_0x337567('0x25f4')][_0x337567('0x61a')][_0x166a94][_0x337567('0x1345')],'msg':_0x2894c3[_0x337567('0x25f4')][_0x337567('0x61a')][_0x166a94][_0x337567('0x1e70')]});}}else _0x5dbf7e['error']({'title':_0x2894c3[_0x337567('0x52d')]?_0x337567('0x1e21')+_0x2894c3[_0x337567('0x52d')]+_0x337567('0x11e1')+_0x2894c3[_0x337567('0xe1b')]:_0x337567('0x200e'),'msg':_0x2894c3[_0x337567('0x25f4')]?JSON[_0x337567('0xbac')](_0x2894c3['data']['message']):_0x2894c3[_0x337567('0x1586')]()});});}function _0x42af2d(){const _0x52251e=_0x383907;_0x54a0d8[_0x52251e('0x557')]['getFaxAccounts']({'id':_0x148f8c[_0x52251e('0x557')]['id'],'nolimit':!![]})['$promise'][_0x52251e('0x1166')](function(_0x34185f){const _0x317729=_0x52251e;_0x148f8c[_0x317729('0xd6c')]=_0x34185f||{'count':0x0,'rows':[]};})[_0x52251e('0x1a80')](function(_0x5ee452){const _0x583466=_0x52251e;if(_0x5ee452['data']&&_0x5ee452[_0x583466('0x25f4')][_0x583466('0x61a')]&&_0x5ee452[_0x583466('0x25f4')][_0x583466('0x61a')][_0x583466('0x264b')]){_0x148f8c[_0x583466('0x61a')]=_0x5ee452[_0x583466('0x25f4')][_0x583466('0x61a')]||[{'message':_0x5ee452['toString'](),'type':_0x583466('0x50')}];for(let _0x130784=0x0;_0x130784<_0x5ee452['data'][_0x583466('0x61a')][_0x583466('0x264b')];_0x130784+=0x1){_0x5dbf7e[_0x583466('0xfc9')]({'title':_0x5ee452[_0x583466('0x25f4')]['errors'][_0x130784][_0x583466('0x1345')],'msg':_0x5ee452[_0x583466('0x25f4')][_0x583466('0x61a')][_0x130784]['message']});}}else _0x5dbf7e[_0x583466('0xfc9')]({'title':_0x5ee452['status']?_0x583466('0x1e21')+_0x5ee452[_0x583466('0x52d')]+_0x583466('0x11e1')+_0x5ee452[_0x583466('0xe1b')]:_0x583466('0x50'),'msg':_0x5ee452['data']?JSON[_0x583466('0xbac')](_0x5ee452[_0x583466('0x25f4')][_0x583466('0x1e70')]):_0x5ee452['toString']()});});}function _0x131f3e(){const _0x56ac39=_0x383907;_0x54a0d8[_0x56ac39('0x557')][_0x56ac39('0x1f5d')]({'id':_0x148f8c['user']['id'],'nolimit':!![]})['$promise'][_0x56ac39('0x1166')](function(_0x50cbc6){_0x148f8c['smsAccounts']=_0x50cbc6||{'count':0x0,'rows':[]};})[_0x56ac39('0x1a80')](function(_0x3eff2b){const _0x285685=_0x56ac39;if(_0x3eff2b[_0x285685('0x25f4')]&&_0x3eff2b['data'][_0x285685('0x61a')]&&_0x3eff2b[_0x285685('0x25f4')][_0x285685('0x61a')][_0x285685('0x264b')]){_0x148f8c['errors']=_0x3eff2b[_0x285685('0x25f4')][_0x285685('0x61a')]||[{'message':_0x3eff2b[_0x285685('0x1586')](),'type':_0x285685('0x1f0f')}];for(let _0x16b124=0x0;_0x16b124<_0x3eff2b[_0x285685('0x25f4')][_0x285685('0x61a')]['length'];_0x16b124+=0x1){_0x5dbf7e[_0x285685('0xfc9')]({'title':_0x3eff2b['data'][_0x285685('0x61a')][_0x16b124][_0x285685('0x1345')],'msg':_0x3eff2b[_0x285685('0x25f4')][_0x285685('0x61a')][_0x16b124][_0x285685('0x1e70')]});}}else _0x5dbf7e[_0x285685('0xfc9')]({'title':_0x3eff2b[_0x285685('0x52d')]?_0x285685('0x1e21')+_0x3eff2b[_0x285685('0x52d')]+_0x285685('0x11e1')+_0x3eff2b[_0x285685('0xe1b')]:'api.sms.account','msg':_0x3eff2b[_0x285685('0x25f4')]?JSON[_0x285685('0xbac')](_0x3eff2b[_0x285685('0x25f4')][_0x285685('0x1e70')]):_0x3eff2b[_0x285685('0x1586')]()});});}function _0x5e1404(){const _0x16f148=_0x383907;_0x54a0d8[_0x16f148('0x557')][_0x16f148('0x22a4')]({'id':_0x148f8c[_0x16f148('0x557')]['id'],'nolimit':!![]})[_0x16f148('0xa44')]['then'](function(_0x5bba06){_0x148f8c['whatsappAccounts']=_0x5bba06||{'count':0x0,'rows':[]};})[_0x16f148('0x1a80')](function(_0x376902){const _0x5eb4b8=_0x16f148;if(_0x376902[_0x5eb4b8('0x25f4')]&&_0x376902[_0x5eb4b8('0x25f4')][_0x5eb4b8('0x61a')]&&_0x376902[_0x5eb4b8('0x25f4')][_0x5eb4b8('0x61a')][_0x5eb4b8('0x264b')]){_0x148f8c[_0x5eb4b8('0x61a')]=_0x376902['data'][_0x5eb4b8('0x61a')]||[{'message':_0x376902[_0x5eb4b8('0x1586')](),'type':'api.whatsapp.account'}];for(let _0x3003e2=0x0;_0x3003e2<_0x376902['data'][_0x5eb4b8('0x61a')][_0x5eb4b8('0x264b')];_0x3003e2+=0x1){_0x5dbf7e[_0x5eb4b8('0xfc9')]({'title':_0x376902[_0x5eb4b8('0x25f4')]['errors'][_0x3003e2][_0x5eb4b8('0x1345')],'msg':_0x376902['data'][_0x5eb4b8('0x61a')][_0x3003e2]['message']});}}else _0x5dbf7e[_0x5eb4b8('0xfc9')]({'title':_0x376902['status']?_0x5eb4b8('0x1e21')+_0x376902[_0x5eb4b8('0x52d')]+_0x5eb4b8('0x11e1')+_0x376902[_0x5eb4b8('0xe1b')]:_0x5eb4b8('0x28b7'),'msg':_0x376902['data']?JSON[_0x5eb4b8('0xbac')](_0x376902[_0x5eb4b8('0x25f4')][_0x5eb4b8('0x1e70')]):_0x376902[_0x5eb4b8('0x1586')]()});});}function _0x3de42a(){const _0x34796c=_0x383907;_0x54a0d8['user'][_0x34796c('0xc48')]({'id':_0x148f8c[_0x34796c('0x557')]['id'],'nolimit':!![]})['$promise']['then'](function(_0x500bb5){_0x148f8c['openchannelAccounts']=_0x500bb5||{'count':0x0,'rows':[]};})[_0x34796c('0x1a80')](function(_0x17fbe5){const _0x9b3a0c=_0x34796c;if(_0x17fbe5[_0x9b3a0c('0x25f4')]&&_0x17fbe5['data'][_0x9b3a0c('0x61a')]&&_0x17fbe5[_0x9b3a0c('0x25f4')][_0x9b3a0c('0x61a')]['length']){_0x148f8c['errors']=_0x17fbe5['data'][_0x9b3a0c('0x61a')]||[{'message':_0x17fbe5[_0x9b3a0c('0x1586')](),'type':_0x9b3a0c('0x24a1')}];for(let _0x237a49=0x0;_0x237a49<_0x17fbe5[_0x9b3a0c('0x25f4')][_0x9b3a0c('0x61a')][_0x9b3a0c('0x264b')];_0x237a49+=0x1){_0x5dbf7e[_0x9b3a0c('0xfc9')]({'title':_0x17fbe5[_0x9b3a0c('0x25f4')][_0x9b3a0c('0x61a')][_0x237a49][_0x9b3a0c('0x1345')],'msg':_0x17fbe5[_0x9b3a0c('0x25f4')]['errors'][_0x237a49]['message']});}}else _0x5dbf7e[_0x9b3a0c('0xfc9')]({'title':_0x17fbe5[_0x9b3a0c('0x52d')]?_0x9b3a0c('0x1e21')+_0x17fbe5['status']+_0x9b3a0c('0x11e1')+_0x17fbe5[_0x9b3a0c('0xe1b')]:_0x9b3a0c('0x24a1'),'msg':_0x17fbe5[_0x9b3a0c('0x25f4')]?JSON[_0x9b3a0c('0xbac')](_0x17fbe5[_0x9b3a0c('0x25f4')][_0x9b3a0c('0x1e70')]):_0x17fbe5[_0x9b3a0c('0x1586')]()});});}function _0x99bfdf(){const _0x4ed311=_0x383907;_0x54a0d8[_0x4ed311('0x557')][_0x4ed311('0x36d')]({'id':_0x148f8c[_0x4ed311('0x557')]['id'],'nolimit':!![]})[_0x4ed311('0xa44')]['then'](function(_0x256a8f){const _0x3c9c4d=_0x4ed311;_0x148f8c[_0x3c9c4d('0x20e0')]=_0x256a8f||{'count':0x0,'rows':[]};})['catch'](function(_0x348fba){const _0x19adfe=_0x4ed311;if(_0x348fba[_0x19adfe('0x25f4')]&&_0x348fba[_0x19adfe('0x25f4')][_0x19adfe('0x61a')]&&_0x348fba['data'][_0x19adfe('0x61a')]['length']){_0x148f8c[_0x19adfe('0x61a')]=_0x348fba[_0x19adfe('0x25f4')][_0x19adfe('0x61a')]||[{'message':_0x348fba[_0x19adfe('0x1586')](),'type':_0x19adfe('0x231e')}];for(let _0x3098e8=0x0;_0x3098e8<_0x348fba[_0x19adfe('0x25f4')][_0x19adfe('0x61a')][_0x19adfe('0x264b')];_0x3098e8+=0x1){_0x5dbf7e[_0x19adfe('0xfc9')]({'title':_0x348fba[_0x19adfe('0x25f4')][_0x19adfe('0x61a')][_0x3098e8][_0x19adfe('0x1345')],'msg':_0x348fba['data'][_0x19adfe('0x61a')][_0x3098e8][_0x19adfe('0x1e70')]});}}else _0x5dbf7e['error']({'title':_0x348fba['status']?_0x19adfe('0x1e21')+_0x348fba['status']+_0x19adfe('0x11e1')+_0x348fba[_0x19adfe('0xe1b')]:_0x19adfe('0x231e'),'msg':_0x348fba[_0x19adfe('0x25f4')]?JSON[_0x19adfe('0xbac')](_0x348fba[_0x19adfe('0x25f4')]['message']):_0x348fba[_0x19adfe('0x1586')]()});});}function _0xbd1fc3(){const _0x559481=_0x383907;_0x54a0d8[_0x559481('0x557')][_0x559481('0x5a1')]({'id':_0x148f8c[_0x559481('0x557')]['id'],'nolimit':!![]})[_0x559481('0xa44')][_0x559481('0x1166')](function(_0x1bb594){const _0x35c660=_0x559481;_0x148f8c[_0x35c660('0x8de')]=_0x1bb594||{'count':0x0,'rows':[]};})[_0x559481('0x1a80')](function(_0x13b10a){const _0x113ebe=_0x559481;if(_0x13b10a['data']&&_0x13b10a[_0x113ebe('0x25f4')][_0x113ebe('0x61a')]&&_0x13b10a['data'][_0x113ebe('0x61a')][_0x113ebe('0x264b')]){_0x148f8c['errors']=_0x13b10a[_0x113ebe('0x25f4')][_0x113ebe('0x61a')]||[{'message':_0x13b10a[_0x113ebe('0x1586')](),'type':'api.cm.lists'}];for(let _0xa9e1a2=0x0;_0xa9e1a2<_0x13b10a[_0x113ebe('0x25f4')][_0x113ebe('0x61a')][_0x113ebe('0x264b')];_0xa9e1a2+=0x1){_0x5dbf7e[_0x113ebe('0xfc9')]({'title':_0x13b10a['data']['errors'][_0xa9e1a2]['type'],'msg':_0x13b10a['data'][_0x113ebe('0x61a')][_0xa9e1a2][_0x113ebe('0x1e70')]});}}else _0x5dbf7e[_0x113ebe('0xfc9')]({'title':_0x13b10a['status']?_0x113ebe('0x1e21')+_0x13b10a[_0x113ebe('0x52d')]+'\x20-\x20'+_0x13b10a[_0x113ebe('0xe1b')]:_0x113ebe('0x117c'),'msg':_0x13b10a[_0x113ebe('0x25f4')]?JSON[_0x113ebe('0xbac')](_0x13b10a[_0x113ebe('0x25f4')][_0x113ebe('0x1e70')]):_0x13b10a[_0x113ebe('0x1586')]()});});}function _0x71cdcd(_0x3cd35d){const _0x334c49=_0x383907;_0x212fa9[_0x334c49('0x1f80')]({'controller':_0x334c49('0x15ad'),'controllerAs':'vm','templateUrl':_0x5b62a4,'parent':angular[_0x334c49('0x1194')](_0x4d08d9[_0x334c49('0x8d2')]),'targetEvent':_0x3cd35d,'clickOutsideToClose':!![],'resolve':{'contact':[_0x334c49('0x1fbc'),function(_0x2b0b8f){const _0x226d35=_0x334c49;return _0x2b0b8f[_0x226d35('0x18af')](_0x226d35('0x111c'),{'id':_0x148f8c[_0x226d35('0x26db')]['id']});}],'lists':[_0x334c49('0x1fbc'),function(_0x1fd41c){const _0x10bd9c=_0x334c49;return _0x1fd41c['resolve'](_0x10bd9c('0x273f'),{'id':_0xc7c6a0[_0x10bd9c('0x26cd')]()['id'],'fields':_0x10bd9c('0x1776')});}]},'locals':{'contacts':[]}});}function _0x51aee9(_0x32072a){const _0x255565=_0x383907;_0x212fa9['show']({'controller':_0x255565('0xcd1'),'controllerAs':'vm','templateUrl':_0x18c924,'parent':angular['element'](_0x4d08d9[_0x255565('0x8d2')]),'targetEvent':_0x32072a,'clickOutsideToClose':!![],'resolve':{'contact':[_0x255565('0x1fbc'),function(_0x5248d7){const _0x9a5b8a=_0x255565;return _0x5248d7[_0x9a5b8a('0x18af')]('cmContact@get',{'id':_0x148f8c[_0x9a5b8a('0x26db')]['id']});}],'lists':['apiResolver',function(_0x56a6e0){const _0x429287=_0x255565;return _0x56a6e0[_0x429287('0x18af')](_0x429287('0x273f'),{'id':_0xc7c6a0[_0x429287('0x26cd')]()['id'],'fields':'id,name'});}]},'locals':{'contacts':[]}})['then'](function(_0x1222c6){const _0x461878=_0x255565;if(_0x1222c6){for(const _0x14f685 in _0x938ac['$parent']['$parent'][_0x461878('0x23ac')]['vm'][_0x461878('0x137f')]){if(typeof _0x938ac[_0x461878('0x23ac')][_0x461878('0x23ac')][_0x461878('0x23ac')]['vm'][_0x461878('0x137f')][_0x14f685]!==_0x461878('0x1048')){const _0x1efd55=_0x938ac[_0x461878('0x23ac')][_0x461878('0x23ac')]['$parent']['vm'][_0x461878('0x137f')][_0x14f685];_0x1efd55&&_0x1efd55['contact']&&(_0x1222c6[_0x461878('0x661')]&&_0x1222c6[_0x461878('0x661')]['id']&&_0x1222c6[_0x461878('0x661')]['id']===_0x1efd55[_0x461878('0x26db')]['id']&&_0x938ac['$parent'][_0x461878('0x23ac')][_0x461878('0x23ac')]['vm'][_0x461878('0x1b93')](_0x1efd55),_0x1222c6['to']&&_0x1222c6['to']['id']&&_0x1222c6['to']['id']===_0x1efd55['contact']['id']&&_0x938ac['$parent']['$parent'][_0x461878('0x23ac')]['vm'][_0x461878('0x1b93')](_0x1efd55));}}_0x1222c6[_0x461878('0xd11')]&&_0x938ac['$parent'][_0x461878('0x23ac')][_0x461878('0x23ac')]['vm']['addContactTab'](_0x1222c6[_0x461878('0xd11')]);}});}function _0x119041(_0x3ff1c2,_0x36b4f9){const _0x5994b4=_0x383907,_0x5e0920=_0x148f8c[_0x5994b4('0x557')][_0x5994b4('0x2540')]||_0x148f8c[_0x5994b4('0x557')][_0x5994b4('0x1c5c')]||_0x148f8c[_0x5994b4('0x557')]['mailPause']||_0x148f8c[_0x5994b4('0x557')][_0x5994b4('0x287f')]||_0x148f8c['user'][_0x5994b4('0x5aa')],_0x21434f=_0x36b4f9['mandatoryDisposition'];if(_0x148f8c[_0x5994b4('0x1018')]){_0x5dbf7e[_0x5994b4('0xfc9')]({'title':'ATTENTION','msg':_0x5994b4('0x2075')});return;}_0x212fa9['show']({'controller':_0x5994b4('0x1fab'),'controllerAs':'vm','templateUrl':_0x5ccf28,'parent':angular[_0x5994b4('0x1194')](_0x4d08d9[_0x5994b4('0x8d2')]),'targetEvent':_0x36b4f9,'clickOutsideToClose':!_0x36b4f9[_0x5994b4('0x10d0')],'escapeToClose':!_0x36b4f9['mandatoryDisposition'],'resolve':{'globalDispositions':[_0x5994b4('0x1fbc'),function(_0x27b98c){const _0x16a3ff=_0x5994b4;return _0x27b98c[_0x16a3ff('0x18af')](_0x16a3ff('0x1e98'),{'MailAccountId':_0x16a3ff('0x15d7'),'FaxAccountId':_0x16a3ff('0x15d7'),'SmsAccountId':_0x16a3ff('0x15d7'),'WhatsappAccountId':_0x16a3ff('0x15d7'),'OpenchannelAccountId':_0x16a3ff('0x15d7'),'ChatWebsiteId':'null','ListId':_0x16a3ff('0x15d7')});}]},'onRemoving':function(){const _0x371612=_0x5994b4;_0x148f8c[_0x371612('0x557')]&&_0x21434f&&!_0x5e0920&&_0x54a0d8[_0x371612('0x557')][_0x371612('0x20eb')]({'id':_0x148f8c[_0x371612('0x557')]['id']})['$promise']['catch'](function(_0x523c29){const _0x2be26f=_0x371612;console[_0x2be26f('0xfc9')](_0x523c29);});},'locals':{'dispositions':_0x148f8c[_0x5994b4('0xbe3')][_0x5994b4('0x4ea')],'contact':_0x148f8c[_0x5994b4('0x26db')],'call':_0x36b4f9}})[_0x5994b4('0x1166')](function(_0x41b2a2){const _0x3346be=_0x5994b4;if(_0x41b2a2){if(_0x41b2a2===_0x3346be('0xe97'))_0x5dbf7e['success']({'title':_0xce7301[_0x3346be('0x25cc')](_0x3346be('0x2869')),'msg':_0xce7301[_0x3346be('0x25cc')](_0x3346be('0xff3'))+'\x20'+_0x41b2a2});else{if(_0x41b2a2==='RECALLME'||_0x41b2a2===_0x3346be('0x23b7')){}else _0x5dbf7e['success']({'title':_0xce7301[_0x3346be('0x25cc')](_0x3346be('0x2869')),'msg':_0xce7301['instant'](_0x3346be('0x27ff'))});}}for(const _0x172490 in _0x938ac[_0x3346be('0x23ac')][_0x3346be('0x23ac')][_0x3346be('0x23ac')]['vm'][_0x3346be('0x137f')]){if(typeof _0x938ac[_0x3346be('0x23ac')]['$parent'][_0x3346be('0x23ac')]['vm'][_0x3346be('0x137f')][_0x172490]!==_0x3346be('0x1048')){const _0xbf42bb=_0x938ac[_0x3346be('0x23ac')][_0x3346be('0x23ac')][_0x3346be('0x23ac')]['vm'][_0x3346be('0x137f')][_0x172490];_0x2cfb05()[_0x3346be('0x127f')](_0xbf42bb[_0x3346be('0x807')],function(_0x955910){const _0x41be55=_0x3346be;return _0x955910[_0x41be55('0x1c21')]===_0x36b4f9[_0x41be55('0x1c21')];});}}_0x938ac[_0x3346be('0x23ac')]['vm'][_0x3346be('0x1a4f')]();});}function _0x97d6be(_0x56574e){const _0x5a8992=_0x383907;return _0x54a0d8[_0x5a8992('0xdd9')][_0x5a8992('0x1bb')]({'id':_0x56574e})[_0x5a8992('0xa44')][_0x5a8992('0x1166')](function(_0x2fbc79){const _0x3fdd16=_0x5a8992;_0x148f8c['tab'][_0x3fdd16('0x23d7')]=_0x2fbc79;})[_0x5a8992('0x1a80')](function(_0x326431){const _0x418591=_0x5a8992;_0x5dbf7e['error']({'title':_0x326431[_0x418591('0x52d')]?'API:'+_0x326431['status']+_0x418591('0x11e1')+_0x326431[_0x418591('0xe1b')]:'LIST:GETCustomFields','msg':_0x326431[_0x418591('0x25f4')]?JSON[_0x418591('0xbac')](_0x326431[_0x418591('0x25f4')]):_0x326431[_0x418591('0x1586')]()});});}function _0x4eb680(_0x26438d){return _0x26438d===null?undefined:new Date(_0x26438d);}function _0x5f4064(_0x5052ee){const _0x2337ce=_0x383907;try{_0x5052ee[_0x2337ce('0x1ff2')]=_0x5f0cec()[_0x2337ce('0x26a1')](_0x5052ee[_0x2337ce('0x1ff2')],{'contact':_0x148f8c[_0x2337ce('0x26db')],'user':_0x148f8c['user']});}catch(_0xf21f2a){console['error'](_0xf21f2a);}try{_0x938ac[_0x2337ce('0x23ac')][_0x2337ce('0x23ac')][_0x2337ce('0x23ac')]['vm'][_0x2337ce('0x18ac')]({'type':_0x2337ce('0x179f'),'title':_0x5052ee['name'],'icon':_0x2337ce('0x865'),'color':_0x2337ce('0x1733'),'project':_0x5052ee,'contact':_0x148f8c[_0x2337ce('0x26db')]});}catch(_0x36dc59){_0x5dbf7e[_0x2337ce('0xfc9')]({'title':'ERROR\x20OPENING\x20JSCRIPTY\x20PROJECT','msg':_0x2337ce('0x2634')+JSON['stringify'](_0x36dc59)});}}function _0x409e41(_0x4a7e6a){const _0x459fdc=_0x383907;return _0xc7c6a0[_0x459fdc('0x1167')](_0x4a7e6a);}_0x938ac[_0x383907('0x3d2')](_0x383907('0x1c3f'),function(){});}const _0x425f7b=_0x3de42b;_0x39644c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty','api',_0x36e6f4('0x4ea'),'globalDispositions',_0x36e6f4('0x200f'),_0x36e6f4('0x26db'),_0x36e6f4('0x21ef'),_0x36e6f4('0x586')];function _0x39644c(_0x3d0451,_0x504429,_0x1a3f5b,_0x2d06df,_0x1dc112,_0x2c8e7a,_0x168630,_0x10b5de,_0x3a15e9,_0x9dd2af){const _0xc1f9f4=_0x36e6f4,_0x43d837=this;_0x43d837[_0xc1f9f4('0x15b7')]=![],_0x43d837[_0xc1f9f4('0xc10')]=![],_0x43d837[_0xc1f9f4('0x1915')]=undefined,_0x43d837[_0xc1f9f4('0x182c')]={'count':0x0,'rows':[]},_0x43d837['dispositions']=_0x1dc112['rows'],_0x43d837['globalDispositions']=_0x2c8e7a[_0xc1f9f4('0x269a')],_0x43d837[_0xc1f9f4('0x26db')]=_0x10b5de,_0x43d837['call']=_0x168630,_0x43d837[_0xc1f9f4('0x2b1')]=_0x43d837[_0xc1f9f4('0x200f')][_0xc1f9f4('0x2b1')]||undefined,_0x43d837[_0xc1f9f4('0x1b7d')]=![],_0x43d837[_0xc1f9f4('0x110c')]=![],_0x43d837[_0xc1f9f4('0x1d98')]={'minDate':new Date(),'dateTime':new Date()};_0x43d837[_0xc1f9f4('0x200f')]&&_0x43d837['call'][_0xc1f9f4('0x57a')]&&_0x43d837['call']['variables']['xmd-voicequeueid']?(_0x43d837[_0xc1f9f4('0x1b7d')]=!![],_0x2d06df[_0xc1f9f4('0x1943')][_0xc1f9f4('0x7c8')]({'id':_0x43d837[_0xc1f9f4('0x200f')][_0xc1f9f4('0x57a')][_0xc1f9f4('0xf38')]})[_0xc1f9f4('0xa44')][_0xc1f9f4('0x1166')](function(_0x413388){const _0x517894=_0xc1f9f4;_0x413388&&_0x413388[_0x517894('0x269a')]&&_0x413388[_0x517894('0x269a')]['length']>0x0&&(_0x43d837[_0x517894('0x110c')]=!![]);})[_0xc1f9f4('0x1a80')](function(_0x4212f5){const _0x86392b=_0xc1f9f4;_0x1a3f5b[_0x86392b('0xfc9')]({'title':_0x4212f5[_0x86392b('0x52d')]?'API:'+_0x4212f5[_0x86392b('0x52d')]+'\x20-\x20'+_0x4212f5[_0x86392b('0xe1b')]:'api.voiceQueue.getBlackLists','msg':_0x4212f5[_0x86392b('0x25f4')]?JSON[_0x86392b('0xbac')](_0x4212f5[_0x86392b('0x25f4')]):_0x4212f5[_0x86392b('0x1586')]()});})):_0x2d06df[_0xc1f9f4('0x557')][_0xc1f9f4('0x152a')]({'id':_0x3a15e9[_0xc1f9f4('0x26cd')]()['id'],'fields':_0xc1f9f4('0x223c'),'channel':_0xc1f9f4('0x21da'),'type':'outbound','nolimit':!![]})[_0xc1f9f4('0xa44')]['then'](function(_0x34eb72){_0x43d837['queueCampaigns']=_0x34eb72||{'count':0x0,'rows':[]};})['catch'](function(_0x597522){const _0x87eeb5=_0xc1f9f4;console[_0x87eeb5('0xfc9')](_0x597522);});_0x43d837[_0xc1f9f4('0xe8d')]=_0x5c7534,_0x43d837[_0xc1f9f4('0x13fb')]=_0x54bc7f,_0x43d837['saveDisposition']=_0x1b8783,_0x43d837[_0xc1f9f4('0x24a0')]=_0x49539f,_0x43d837[_0xc1f9f4('0x24f2')]=_0x32df13;function _0x5c7534(_0xa9e2db){const _0x5caa40=_0xc1f9f4,_0x37cd3d=_0x2cfb05()[_0x5caa40('0x2231')](_0x43d837['dispositions'],_0x43d837[_0x5caa40('0x1004')],'id');switch(_0xa9e2db){case'first':_0x43d837[_0x5caa40('0x279b')]=_0x43d837[_0x5caa40('0x1a44')],_0x43d837['anySecondLevelDisposition']=_0x2cfb05()[_0x5caa40('0x1798')](_0x37cd3d,[_0x5caa40('0x11fa'),_0x43d837[_0x5caa40('0x1a44')]['id']]),_0x43d837[_0x5caa40('0x2092')]=undefined,_0x43d837[_0x5caa40('0x649')]=undefined,_0x43d837[_0x5caa40('0x266a')]=![];break;case _0x5caa40('0x161a'):_0x43d837[_0x5caa40('0x279b')]=_0x43d837[_0x5caa40('0x2092')],_0x43d837[_0x5caa40('0x266a')]=_0x2cfb05()[_0x5caa40('0x1798')](_0x37cd3d,[_0x5caa40('0x11fa'),_0x43d837[_0x5caa40('0x2092')]['id']]);break;case'third':_0x43d837['selectedDisposition']=_0x43d837['thirdLevelDisposition'];break;}}function _0x54bc7f(_0x42df9b){const _0x45350e=_0xc1f9f4;if(_0x42df9b===_0x45350e('0x161a'))_0x43d837[_0x45350e('0x2092')]=undefined,_0x43d837[_0x45350e('0x649')]=undefined,_0x43d837[_0x45350e('0x279b')]=_0x43d837[_0x45350e('0x1a44')];else _0x42df9b===_0x45350e('0x15e9')&&(_0x43d837[_0x45350e('0x649')]=undefined,_0x43d837[_0x45350e('0x279b')]=_0x43d837['secondLevelDisposition']);}function _0x4f4c83(){const _0x464af9=_0xc1f9f4,_0x3b2699=_0x43d837['selectedDisposition']?_0x43d837[_0x464af9('0x279b')][_0x464af9('0x4f0')][_0x464af9('0x2574')]():undefined;return{'id':_0x43d837['call'][_0x464af9('0x1c21')],'disposition':_0x43d837[_0x464af9('0x1a44')]?_0x43d837[_0x464af9('0x1a44')][_0x464af9('0x4f0')]:null,'secondDisposition':_0x43d837['secondLevelDisposition']?_0x43d837['secondLevelDisposition'][_0x464af9('0x4f0')]:null,'thirdDisposition':_0x43d837[_0x464af9('0x649')]?_0x43d837[_0x464af9('0x649')][_0x464af9('0x4f0')]:null,'dispositionat':_0x24273b()(),'amd':_0x3b2699===_0x464af9('0x162e'),'fax':_0x3b2699===_0x464af9('0x1fc7'),'blacklist':_0x3b2699===_0x464af9('0x736'),'recallme':_0x3b2699===_0x464af9('0xc10'),'UserId':_0x3b2699===_0x464af9('0xc10')?_0x3a15e9[_0x464af9('0x26cd')]()['id']:null,'OwnerId':_0x3a15e9[_0x464af9('0x26cd')]()['id']};}function _0x36f3c7(){const _0x4b2792=_0xc1f9f4;return _0x2d06df['voiceCallReport'][_0x4b2792('0x1449')]({'id':_0x43d837[_0x4b2792('0x200f')][_0x4b2792('0x1c21')],'userDisposition':_0x43d837[_0x4b2792('0x1a44')]?_0x43d837[_0x4b2792('0x1a44')]['name']:null,'userSecondDisposition':_0x43d837['secondLevelDisposition']?_0x43d837[_0x4b2792('0x2092')][_0x4b2792('0x4f0')]:null,'userThirdDisposition':_0x43d837[_0x4b2792('0x649')]?_0x43d837[_0x4b2792('0x649')][_0x4b2792('0x4f0')]:null,'note':_0x43d837[_0x4b2792('0x2b1')],'UserId':_0x3a15e9[_0x4b2792('0x26cd')]()['id'],'ContactId':_0x43d837[_0x4b2792('0x26db')]['id']})[_0x4b2792('0xa44')][_0x4b2792('0x1a80')](function(_0x2e2784){const _0x2f5f20=_0x4b2792;_0x1a3f5b[_0x2f5f20('0xfc9')]({'title':_0x2e2784[_0x2f5f20('0x52d')]?_0x2f5f20('0x1e21')+_0x2e2784[_0x2f5f20('0x52d')]+_0x2f5f20('0x11e1')+_0x2e2784[_0x2f5f20('0xe1b')]:_0x2f5f20('0x1968'),'msg':_0x2e2784[_0x2f5f20('0x25f4')]?JSON[_0x2f5f20('0xbac')](_0x2e2784['data']):_0x2e2784[_0x2f5f20('0x1586')]()});});}function _0x3997ca(){const _0x33d96f=_0xc1f9f4;return _0x2d06df[_0x33d96f('0x1825')][_0x33d96f('0xd83')]({'uniqueid':_0x43d837[_0x33d96f('0x200f')][_0x33d96f('0x1c21')]})[_0x33d96f('0xa44')][_0x33d96f('0x1166')](function(_0x1e06ba){const _0x34e690=_0x33d96f;if(_0x1e06ba)for(let _0x13b965=0x0;_0x13b965<_0x1e06ba[_0x34e690('0x269a')][_0x34e690('0x264b')];_0x13b965+=0x1){_0x2d06df[_0x34e690('0x1825')][_0x34e690('0x1449')]({'id':_0x1e06ba[_0x34e690('0x269a')][_0x13b965]['id'],'userDisposition':_0x43d837[_0x34e690('0x1a44')]?_0x43d837[_0x34e690('0x1a44')][_0x34e690('0x4f0')]:null,'userSecondDisposition':_0x43d837[_0x34e690('0x2092')]?_0x43d837[_0x34e690('0x2092')]['name']:null,'userThirdDisposition':_0x43d837[_0x34e690('0x649')]?_0x43d837[_0x34e690('0x649')][_0x34e690('0x4f0')]:null})[_0x34e690('0xa44')]['catch'](function(_0x49692d){const _0x34e02f=_0x34e690;_0x1a3f5b['error']({'title':_0x49692d[_0x34e02f('0x52d')]?'API:'+_0x49692d['status']+_0x34e02f('0x11e1')+_0x49692d[_0x34e02f('0xe1b')]:_0x34e02f('0x2c7'),'msg':_0x49692d[_0x34e02f('0x25f4')]?JSON[_0x34e02f('0xbac')](_0x49692d[_0x34e02f('0x25f4')]):_0x49692d['toString']()});});}})[_0x33d96f('0x1a80')](function(_0x3bcfa7){const _0x48b32f=_0x33d96f;_0x1a3f5b['error']({'title':_0x3bcfa7[_0x48b32f('0x52d')]?_0x48b32f('0x1e21')+_0x3bcfa7[_0x48b32f('0x52d')]+_0x48b32f('0x11e1')+_0x3bcfa7[_0x48b32f('0xe1b')]:'SYSTEM:UPDATEVOICERECORDING','msg':_0x3bcfa7[_0x48b32f('0x25f4')]?JSON[_0x48b32f('0xbac')](_0x3bcfa7[_0x48b32f('0x25f4')]):_0x3bcfa7['toString']()});});}function _0x1de5ff(){const _0x5a47eb=_0xc1f9f4;return _0x2d06df[_0x5a47eb('0x1806')][_0x5a47eb('0x1449')](_0x4f4c83())['$promise'][_0x5a47eb('0x1a80')](function(_0x7dfb12){const _0x95049f=_0x5a47eb;_0x1a3f5b[_0x95049f('0xfc9')]({'title':_0x7dfb12[_0x95049f('0x52d')]?_0x95049f('0x1e21')+_0x7dfb12[_0x95049f('0x52d')]+_0x95049f('0x11e1')+_0x7dfb12[_0x95049f('0xe1b')]:_0x95049f('0x1065'),'msg':_0x7dfb12[_0x95049f('0x25f4')]?JSON[_0x95049f('0xbac')](_0x7dfb12['data']):_0x7dfb12['toString']()});});}function _0x321018(){const _0x374792=_0xc1f9f4;return _0x2d06df['cmHopperHistory'][_0x374792('0x1449')](_0x4f4c83())[_0x374792('0xa44')]['catch'](function(_0x20037a){const _0x42f644=_0x374792;_0x1a3f5b[_0x42f644('0xfc9')]({'title':_0x20037a['status']?_0x42f644('0x1e21')+_0x20037a[_0x42f644('0x52d')]+_0x42f644('0x11e1')+_0x20037a[_0x42f644('0xe1b')]:_0x42f644('0x1fe4'),'msg':_0x20037a[_0x42f644('0x25f4')]?JSON[_0x42f644('0xbac')](_0x20037a[_0x42f644('0x25f4')]):_0x20037a['toString']()});});}function _0x1aaa92(_0x315ad6){const _0x4c46af=_0xc1f9f4;if(_0x315ad6)return _0x2d06df[_0x4c46af('0x1943')][_0x4c46af('0x7c8')]({'id':_0x315ad6,'type':'outbound','fields':'id'})[_0x4c46af('0xa44')][_0x4c46af('0x1166')](function(_0x2ca460){const _0x41a385=_0x4c46af,_0x89478b=[];if(_0x2ca460&&_0x2ca460[_0x41a385('0x240f')]>0x0){for(let _0xf7906=0x0;_0xf7906<_0x2ca460[_0x41a385('0x269a')][_0x41a385('0x264b')];_0xf7906+=0x1){const _0x32be34=angular[_0x41a385('0x225f')](_0x43d837['contact']);delete _0x32be34['id'],_0x32be34[_0x41a385('0x23c')]=_0x2ca460['rows'][_0xf7906]['id'],_0x89478b[_0x41a385('0x1514')](_0x2d06df[_0x41a385('0x149e')][_0x41a385('0x9cc')](_0x32be34)[_0x41a385('0xa44')]);}return _0x504429[_0x41a385('0x2760')](_0x89478b);}_0x1a3f5b[_0x41a385('0x103b')]({'title':_0x9dd2af[_0x41a385('0x25cc')]('DASHBOARDS.INFO'),'msg':_0x9dd2af[_0x41a385('0x25cc')](_0x41a385('0x1abf'))+'\x20'+_0x43d837['selectedDisposition']}),_0x43d837[_0x41a385('0x279b')]=undefined;return;})[_0x4c46af('0x1166')](function(_0x477944){const _0x8e1077=_0x4c46af;_0x477944&&_0x3d0451[_0x8e1077('0x1197')](_0x43d837['selectedDisposition']?_0x43d837[_0x8e1077('0x279b')][_0x8e1077('0x4f0')][_0x8e1077('0x1387')]():'');})[_0x4c46af('0x1a80')](function(_0xb52b03){const _0xd49e3f=_0x4c46af;_0x1a3f5b['error']({'title':_0xb52b03['status']?'API:'+_0xb52b03[_0xd49e3f('0x52d')]+_0xd49e3f('0x11e1')+_0xb52b03[_0xd49e3f('0xe1b')]:'SYSTEM:UPDATEBLACKLIST','msg':_0xb52b03[_0xd49e3f('0x25f4')]?JSON[_0xd49e3f('0xbac')](_0xb52b03[_0xd49e3f('0x25f4')]):_0xb52b03[_0xd49e3f('0x1586')]()}),_0x3d0451[_0xd49e3f('0x1197')](_0x43d837[_0xd49e3f('0x279b')]?_0x43d837['selectedDisposition'][_0xd49e3f('0x4f0')]['toUpperCase']():'');});}function _0x1b8783(_0xae9218){const _0x5b2eb2=_0xc1f9f4;_0x43d837['selectedDisposition']=_0x2cfb05()[_0x5b2eb2('0x2863')](_0xae9218)?_0x43d837[_0x5b2eb2('0x279b')]:{'name':_0xae9218};_0xae9218&&(_0x43d837[_0x5b2eb2('0x1a44')]=_0x43d837['selectedDisposition']);_0x43d837[_0x5b2eb2('0x200f')][_0x5b2eb2('0x2b1')]=_0x43d837[_0x5b2eb2('0x2b1')],_0x36f3c7(),_0x3997ca();_0x43d837[_0x5b2eb2('0x1b7d')]&&(_0x1de5ff(),_0x321018());if(!_0x2cfb05()[_0x5b2eb2('0x2863')](_0x43d837['selectedDisposition']))switch(_0x43d837[_0x5b2eb2('0x279b')]['name']['toLowerCase']()){case _0x5b2eb2('0x736'):_0x43d837[_0x5b2eb2('0x200f')]&&_0x43d837[_0x5b2eb2('0x200f')][_0x5b2eb2('0x57a')]&&_0x43d837[_0x5b2eb2('0x200f')][_0x5b2eb2('0x57a')][_0x5b2eb2('0xf38')]&&_0x1aaa92(_0x43d837[_0x5b2eb2('0x200f')][_0x5b2eb2('0x57a')][_0x5b2eb2('0xf38')]);break;case'reschedule':_0x43d837['isReschedule']=!![],_0x43d837[_0x5b2eb2('0xc10')]=![];break;case _0x5b2eb2('0xc10'):_0x43d837['isReschedule']=!![],_0x43d837[_0x5b2eb2('0xc10')]=!![];break;default:_0x3d0451[_0x5b2eb2('0x1197')](_0x43d837[_0x5b2eb2('0x279b')]?_0x43d837['selectedDisposition'][_0x5b2eb2('0x4f0')][_0x5b2eb2('0x1387')]():'');}else _0x3d0451[_0x5b2eb2('0x1197')](_0x43d837[_0x5b2eb2('0x279b')]?_0x43d837['selectedDisposition'][_0x5b2eb2('0x4f0')][_0x5b2eb2('0x1387')]():'');}function _0x49539f(){const _0x447099=_0xc1f9f4;_0x3d0451[_0x447099('0x3f')]();}function _0x32df13(){const _0x218fc7=_0xc1f9f4;return _0x43d837[_0x218fc7('0x27bf')]=!![],_0x2d06df[_0x218fc7('0x256a')][_0x218fc7('0x9cc')]({'phone':_0x43d837[_0x218fc7('0x26db')][_0x218fc7('0x2026')],'UserId':_0x43d837[_0x218fc7('0xc10')]?_0x3a15e9[_0x218fc7('0x26cd')]()['id']:null,'ContactId':_0x43d837[_0x218fc7('0x26db')]['id'],'ListId':_0x43d837[_0x218fc7('0x26db')][_0x218fc7('0x23c')],'VoiceQueueId':_0x43d837['dialerCall']?Number(_0x43d837[_0x218fc7('0x200f')][_0x218fc7('0xf38')]):_0x43d837[_0x218fc7('0x1915')]?_0x43d837['queueCampaign']['id']:null,'scheduledat':_0x24273b()(_0x43d837['hopper'][_0x218fc7('0xc7f')])[_0x218fc7('0x128a')](_0x218fc7('0x1084')),'priority':0x3,'recallme':_0x43d837[_0x218fc7('0xc10')],'OwnerId':_0x3a15e9[_0x218fc7('0x26cd')]()['id']})[_0x218fc7('0xa44')][_0x218fc7('0x1166')](function(){const _0xc86003=_0x218fc7;_0x43d837[_0xc86003('0x1b7d')]&&_0x2d06df[_0xc86003('0x1806')][_0xc86003('0x1449')]({'id':_0x43d837[_0xc86003('0x200f')][_0xc86003('0x1c21')],'rescheduled':!![],'rescheduledat':_0x24273b()(_0x43d837['hopper']['dateTime'])[_0xc86003('0x128a')]('YYYY-MM-DD\x20HH:mm:ss'),'recallme':_0x43d837[_0xc86003('0xc10')]})[_0xc86003('0xa44')][_0xc86003('0x1a80')](function(_0x370b53){console['log'](_0x370b53);});})['then'](function(){const _0x46180e=_0x218fc7;_0x1a3f5b[_0x46180e('0x103b')]({'title':_0x9dd2af[_0x46180e('0x25cc')](_0x46180e('0x2869')),'msg':_0x9dd2af[_0x46180e('0x25cc')](_0x46180e('0xff3'))+'\x20'+(_0x43d837[_0x46180e('0xc10')]?_0x9dd2af['instant'](_0x46180e('0x98c')):_0x9dd2af[_0x46180e('0x25cc')](_0x46180e('0x217b')))});})[_0x218fc7('0x1a80')](function(){const _0x36fe58=_0x218fc7;_0x3d0451['hide'](_0x43d837[_0x36fe58('0x279b')]?_0x43d837['selectedDisposition'][_0x36fe58('0x4f0')][_0x36fe58('0x1387')]():'');})['finally'](function(){const _0x54b887=_0x218fc7;_0x43d837[_0x54b887('0x27bf')]=![],_0x3d0451[_0x54b887('0x1197')](_0x43d837[_0x54b887('0x279b')]?_0x43d837[_0x54b887('0x279b')][_0x54b887('0x4f0')][_0x54b887('0x1387')]():'');});}}const _0x1e1ccb=_0x39644c;_0x55af9b['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x8da'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'contact',_0x36e6f4('0x200f'),_0x36e6f4('0x21ef'),_0x36e6f4('0xc10'),'$translate'];function _0x55af9b(_0x36169d,_0x1a8ed2,_0x3d0bd5,_0x1898df,_0x35c9b9,_0x2fa4b0,_0x2861c3,_0x11ed9e,_0x217734,_0x4c4508,_0x56c5b2,_0x4e88a0){const _0x2ac07a=_0x36e6f4,_0x2c09d9=this;_0x2c09d9[_0x2ac07a('0x200f')]=_0x217734,_0x2c09d9[_0x2ac07a('0x26db')]=_0x11ed9e,_0x2c09d9[_0x2ac07a('0x1d98')]={'minDate':new Date(),'dateTime':new Date()};function _0x110ed7(){const _0x34390d=_0x2ac07a;return _0x2c09d9[_0x34390d('0x27bf')]=!![],_0x2861c3[_0x34390d('0x256a')][_0x34390d('0x9cc')]({'phone':_0x2c09d9[_0x34390d('0x26db')]['phone'],'UserId':_0x56c5b2?_0x4c4508[_0x34390d('0x26cd')]()['id']:null,'ContactId':_0x2c09d9['contact']['id'],'ListId':_0x2c09d9['contact'][_0x34390d('0x23c')],'VoiceQueueId':Number(_0x2c09d9[_0x34390d('0x200f')][_0x34390d('0xf38')]),'scheduledat':_0x24273b()(_0x2c09d9[_0x34390d('0x1d98')]['dateTime'])[_0x34390d('0x128a')](_0x34390d('0x1084')),'priority':0x3,'recallme':_0x56c5b2,'OwnerId':_0x4c4508[_0x34390d('0x26cd')]()['id']})['$promise']['then'](function(){const _0x4934bd=_0x34390d;_0x2861c3[_0x4934bd('0x1806')]['update']({'id':_0x2c09d9['call'][_0x4934bd('0x1c21')],'rescheduled':!![],'rescheduledat':_0x24273b()(_0x2c09d9[_0x4934bd('0x1d98')][_0x4934bd('0xc7f')])[_0x4934bd('0x128a')](_0x4934bd('0x1084')),'recallme':_0x56c5b2})[_0x4934bd('0xa44')];})['then'](function(){const _0x40fbc7=_0x34390d;_0x2fa4b0['success']({'title':_0x4e88a0['instant'](_0x40fbc7('0x2869')),'msg':_0x4e88a0[_0x40fbc7('0x25cc')]('DASHBOARDS.CALL_DISPOSED')+'\x20'+(_0x56c5b2?_0x4e88a0[_0x40fbc7('0x25cc')](_0x40fbc7('0x98c')):_0x4e88a0[_0x40fbc7('0x25cc')](_0x40fbc7('0x217b')))}),_0x1898df['hide']();})[_0x34390d('0x1a80')](function(_0x227de4){const _0x1061d7=_0x34390d;_0x1898df[_0x1061d7('0x3f')](_0x227de4);})['finally'](function(){const _0x24bdf3=_0x34390d;_0x2c09d9[_0x24bdf3('0x27bf')]=![];});}function _0x1aa8ae(){const _0x422d5e=_0x2ac07a;_0x1898df[_0x422d5e('0x3f')]();}_0x2c09d9[_0x2ac07a('0x24a0')]=_0x1aa8ae,_0x2c09d9[_0x2ac07a('0x1b5d')]=_0x110ed7;}const _0x341168=_0x55af9b;_0x210348[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$translate','api',_0x36e6f4('0xca8'),_0x36e6f4('0x1554'),_0x36e6f4('0x1d2e')];function _0x210348(_0x3b735d,_0x524080,_0xe37f57,_0x53f2ca,_0x7776f2,_0x3a0a4e){const _0x7333c0=_0x36e6f4,_0x40dc5e=this;_0x40dc5e[_0x7333c0('0x1554')]=_0x7776f2,_0x40dc5e[_0x7333c0('0x1a43')]=0x1;function _0x5f0faa(){const _0x2d2d6a=_0x7333c0;_0xe37f57[_0x2d2d6a('0xdd9')]['get']({'fields':_0x2d2d6a('0x1776'),'nolimit':!![]})['$promise'][_0x2d2d6a('0x1166')](function(_0xf1c559){const _0x2da3a2=_0x2d2d6a;_0x40dc5e['lists']=_0x2cfb05()['chain'](_0xf1c559['rows'])[_0x2da3a2('0x155c')]('id')[_0x2da3a2('0x1f4d')](_0x2da3a2('0x4f0'))['value'](),_0xe37f57['cmCustomField'][_0x2da3a2('0xd83')]({'fields':_0x2da3a2('0x2276'),'nolimit':!![]})[_0x2da3a2('0xa44')][_0x2da3a2('0x1166')](function(_0x2344d9){const _0x1a40f5=_0x2da3a2;_0x40dc5e[_0x1a40f5('0x23d7')]=_0x2344d9[_0x1a40f5('0x269a')],_0x40dc5e['contacts']=_0x2cfb05()['map'](_0x53f2ca,function(_0x56213f){const _0x2edbe7=_0x1a40f5;return Object[_0x2edbe7('0x14a4')](_0x56213f)[_0x2edbe7('0x2782')](function(_0x5ca7e4){const _0x5ee54e=_0x2edbe7;if(Number(_0x56213f[_0x5ca7e4])===Number(_0x40dc5e[_0x5ee54e('0x1554')])){if(_0x5ca7e4[_0x5ee54e('0x1783')](_0x5ee54e('0x711'))){const _0x283300=_0x2cfb05()['find'](_0x40dc5e[_0x5ee54e('0x23d7')],['id',Number(_0x2cfb05()[_0x5ee54e('0x19db')](_0x5ca7e4,_0x5ee54e('0x711')))]);_0x56213f[_0x5ee54e('0xd71')]=_0x283300?_0x283300[_0x5ee54e('0x4e')]:_0x524080[_0x5ee54e('0x25cc')]('DASHBOARDS.UNKNOWN');}else _0x56213f[_0x5ee54e('0xd71')]=_0x5ca7e4;}}),_0x56213f;});});})['then'](function(){const _0x5c3795=_0x2d2d6a;_0x40dc5e[_0x5c3795('0x27dc')]=_0x2cfb05()['chunk'](_0x53f2ca,0x4);})[_0x2d2d6a('0x1a80')](function(_0x5ad792){const _0x2385fd=_0x2d2d6a;_0x3a0a4e[_0x2385fd('0xfc9')]({'title':_0x5ad792[_0x2385fd('0x52d')]?'API:'+_0x5ad792[_0x2385fd('0x52d')]+_0x2385fd('0x11e1')+_0x5ad792[_0x2385fd('0xe1b')]:_0x2385fd('0x20ff'),'msg':_0x5ad792[_0x2385fd('0x25f4')]?JSON[_0x2385fd('0xbac')](_0x5ad792[_0x2385fd('0x25f4')][_0x2385fd('0x1e70')]):_0x5ad792[_0x2385fd('0x1586')]()});});}function _0x226219(){const _0x46248c=_0x7333c0;_0x3b735d[_0x46248c('0x1197')](_0x40dc5e[_0x46248c('0x13ac')]);}_0x40dc5e[_0x7333c0('0xae0')]=_0x5f0faa,_0x40dc5e[_0x7333c0('0x14cc')]=_0x226219;}const _0x5e407d=_0x210348;_0x38fc76[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x10eb')];function _0x38fc76(_0x428846,_0x2c7152){const _0x18085d=_0x36e6f4;let _0x62c4f7=_0x2c7152(function(){},0x3e7);_0x428846[_0x18085d('0x3d2')](_0x18085d('0x1c3f'),function(){const _0xb78540=_0x18085d;_0x62c4f7&&(_0x2c7152[_0xb78540('0x3f')](_0x62c4f7),_0x62c4f7=null);});}const _0x2daa65=_0x38fc76;_0x9084d2[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$window',_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x2661')];function _0x9084d2(_0x39027c,_0x5374ef,_0x35e5af,_0x210c93,_0x24d286,_0x1ec65a,_0x5d1d2d,_0x3a1745,_0x64fc6c){const _0x56233f=_0x36e6f4,_0x416aa2=this;_0x416aa2[_0x56233f('0xc6e')]=![],_0x416aa2[_0x56233f('0x1a73')]=!![],_0x416aa2[_0x56233f('0x27bf')]=[],_0x416aa2[_0x56233f('0x4ea')]={'count':0x0,'rows':[]},_0x416aa2[_0x56233f('0x98')]=_0x3a1745['getCurrentUser'](),_0x416aa2[_0x56233f('0x7a7')]={},_0x416aa2[_0x56233f('0x224c')]={'count':0x0,'rows':[]},_0x416aa2[_0x56233f('0x2218')]={'fields':_0x56233f('0x1cd1'),'type':'outbound','queuecallerexitreason':_0x56233f('0x197b')+','+_0x56233f('0x1866'),'sort':_0x56233f('0x14dc'),'limit':0xa,'page':0x1},_0x416aa2[_0x56233f('0x17df')]=_0x95f2bc,_0x416aa2['refreshAbandonedCalls']=_0x40476f,_0x416aa2[_0x56233f('0xae0')]=_0x59611a,_0x416aa2[_0x56233f('0xd23')]=_0x4e5edf,_0x416aa2[_0x56233f('0xbb5')]=_0x179a59,_0x416aa2[_0x56233f('0x200f')]=_0x39027c[_0x56233f('0x23ac')]['$parent']['$parent'][_0x56233f('0x23ac')]['vm'][_0x56233f('0x200f')],_0x416aa2[_0x56233f('0x646')]=_0x39027c[_0x56233f('0x23ac')][_0x56233f('0x23ac')][_0x56233f('0x23ac')][_0x56233f('0x23ac')]['vm']['transfer'],_0x416aa2[_0x56233f('0xf91')]=_0x39027c[_0x56233f('0x23ac')][_0x56233f('0x23ac')]['$parent']['$parent']['vm'][_0x56233f('0xf91')],_0x416aa2[_0x56233f('0x1270')]=_0x39027c[_0x56233f('0x23ac')][_0x56233f('0x23ac')][_0x56233f('0x23ac')]['$parent']['vm'][_0x56233f('0x1270')],_0x416aa2[_0x56233f('0x109e')]=_0x48e25d,_0x416aa2[_0x56233f('0x3c5')]=_0x182351,_0x64fc6c[_0x56233f('0xe82')](_0x56233f('0x2615'),_0x2999db),_0x64fc6c['onWithoutApply'](_0x56233f('0x4b0'),_0x10e6b1),_0x59611a();function _0x59611a(){const _0x453b42=_0x56233f;return _0x5d1d2d[_0x453b42('0x12e8')][_0x453b42('0xd83')]({'MailAccountId':_0x453b42('0x15d7'),'FaxAccountId':_0x453b42('0x15d7'),'SmsAccountId':_0x453b42('0x15d7'),'WhatsappAccountId':_0x453b42('0x15d7'),'OpenchannelAccountId':_0x453b42('0x15d7'),'ChatWebsiteId':_0x453b42('0x15d7')})[_0x453b42('0xa44')][_0x453b42('0x1166')](function(_0xd2a177){const _0x47943e=_0x453b42;return _0x416aa2[_0x47943e('0x4ea')]=_0xd2a177?_0xd2a177[_0x47943e('0x269a')]:[],_0x5d1d2d['user']['getQueues']({'id':_0x3a1745[_0x47943e('0x26cd')]()['id'],'fields':_0x47943e('0x1776'),'channel':_0x47943e('0x21da'),'type':'outbound','nolimit':!![]})[_0x47943e('0xa44')];})[_0x453b42('0x1166')](function(_0x376d08){const _0x5df87f=_0x453b42;_0x416aa2[_0x5df87f('0x7a7')]=_0x376d08||{'count':0x0,'rows':[]},_0x416aa2['queuesMap']=_0x2cfb05()[_0x5df87f('0x1f4d')](_0x2cfb05()['keyBy'](_0x416aa2[_0x5df87f('0x7a7')]['rows'],_0x5df87f('0x4f0')),_0x5df87f('0x4f0')),_0x416aa2[_0x5df87f('0x12eb')]=_0x416aa2['queues'][_0x5df87f('0x269a')]?_0x2cfb05()[_0x5df87f('0x2563')](_0x416aa2['queues'][_0x5df87f('0x269a')],_0x5df87f('0x4f0'))[_0x5df87f('0x45a')](','):undefined;})[_0x453b42('0x1166')](function(){_0x416aa2['quickFilters']=_0x21aa27();})[_0x453b42('0x1a80')](function(_0x53a064){const _0x45307e=_0x453b42;console[_0x45307e('0x455')](_0x53a064);})[_0x453b42('0x1951')](function(){const _0x4a0fbd=_0x453b42;let _0x356376=_0x24d286[_0x4a0fbd('0x275')][_0x4a0fbd('0x15f7')](_0x4a0fbd('0x5ed')+_0x416aa2['currentUser']['id']);if(_0x356376)_0x356376=JSON[_0x4a0fbd('0x1295')](_0x356376),_0x356376[_0x4a0fbd('0x2218')]&&(_0x416aa2[_0x4a0fbd('0x2218')]=_0x2cfb05()[_0x4a0fbd('0xcc3')](_0x356376[_0x4a0fbd('0x2218')],_0x2cfb05()[_0x4a0fbd('0x1414')](_0x416aa2[_0x4a0fbd('0x2218')],[_0x4a0fbd('0x1aba'),_0x4a0fbd('0x163f'),_0x4a0fbd('0x1a43')])),_0x416aa2[_0x4a0fbd('0x2218')]=_0x2cfb05()[_0x4a0fbd('0x1414')](_0x416aa2[_0x4a0fbd('0x2218')],_0x4a0fbd('0x1c33')));else{const _0x27104d={'$gte':_0x24273b()()[_0x4a0fbd('0x1659')](_0x4a0fbd('0x2e7'))[_0x4a0fbd('0x13f2')](0x0,!![])[_0x4a0fbd('0x128a')](),'$lte':_0x24273b()()['endOf'](_0x4a0fbd('0x2e7'))[_0x4a0fbd('0x13f2')](0x0,!![])['format']()};_0x416aa2[_0x4a0fbd('0x2218')][_0x4a0fbd('0x262')]=_0x27104d;}_0x416aa2[_0x4a0fbd('0x7cc')]=_0x416aa2[_0x4a0fbd('0x2218')][_0x4a0fbd('0x1c33')]?!![]:![],_0x416aa2[_0x4a0fbd('0x17df')]();});}function _0x21aa27(){const _0x1af5ba=_0x56233f;return[{'name':'Start\x20Date','key':_0x1af5ba('0x262'),'type':_0x1af5ba('0x1643'),'label':_0x1af5ba('0x16d9')},{'name':_0x1af5ba('0x89b'),'key':'UserId','type':_0x1af5ba('0x88a'),'label':'DASHBOARDS.SELECT_AGENT','customOptions':[{'value':_0x416aa2[_0x1af5ba('0x98')]['id'],'translate':'DASHBOARDS.ME'},{'value':_0x1af5ba('0x1c08'),'translate':'DASHBOARDS.NOT_ASSIGNED'},{'value':undefined,'translate':_0x1af5ba('0x2150')}]},{'name':_0x1af5ba('0xaaf'),'key':_0x1af5ba('0x1d3e'),'type':_0x1af5ba('0x2162'),'label':_0x1af5ba('0x1428'),'options':_0x416aa2[_0x1af5ba('0x7a7')]['rows'],'ngValue':_0x1af5ba('0x4f0'),'clearAll':![]}];}function _0x95f2bc(){const _0x3d0726=_0x56233f;_0x416aa2[_0x3d0726('0x2218')][_0x3d0726('0x1d3e')]=_0x416aa2['query'][_0x3d0726('0x1d3e')]||_0x416aa2[_0x3d0726('0x12eb')][_0x3d0726('0x25c8')](','),_0x416aa2[_0x3d0726('0x2218')]['offset']=(_0x416aa2[_0x3d0726('0x2218')][_0x3d0726('0x1a43')]-0x1)*_0x416aa2[_0x3d0726('0x2218')][_0x3d0726('0x163f')];const _0x5b6d69={'query':_0x416aa2[_0x3d0726('0x2218')]};_0x24d286['localStorage']['setItem'](_0x3d0726('0x5ed')+_0x416aa2['currentUser']['id'],JSON[_0x3d0726('0xbac')](_0x5b6d69)),_0x416aa2['promise']=_0x5d1d2d[_0x3d0726('0x1ede')][_0x3d0726('0x1cdb')](_0x416aa2[_0x3d0726('0x2218')],_0xbbbae)[_0x3d0726('0xa44')];}function _0xbbbae(_0x4cd38e){const _0x57f7b6=_0x56233f;_0x416aa2[_0x57f7b6('0x224c')]=_0x4cd38e||{'count':0x0,'rows':[]},_0x416aa2['refresh']=!![];}function _0x179a59(_0x15558f){const _0x2a2700=_0x56233f;_0x35e5af[_0x2a2700('0x1f80')]({'controller':_0x2a2700('0x2c1'),'controllerAs':'vm','templateUrl':_0x2a2700('0x23b0'),'parent':angular[_0x2a2700('0x1194')](_0x210c93[_0x2a2700('0x8d2')]),'targetEvent':_0x15558f,'resolve':{'globalDispositions':[_0x2a2700('0x1fbc'),function(_0x3c74d1){const _0x451f53=_0x2a2700;return _0x3c74d1[_0x451f53('0x18af')](_0x451f53('0x1e98'),{'MailAccountId':_0x451f53('0x15d7'),'FaxAccountId':_0x451f53('0x15d7'),'SmsAccountId':'null','WhatsappAccountId':_0x451f53('0x15d7'),'OpenchannelAccountId':_0x451f53('0x15d7'),'ChatWebsiteId':'null','ListId':_0x451f53('0x15d7')});}]},'locals':{'dispositions':_0x416aa2[_0x2a2700('0x4ea')],'call':_0x15558f}})[_0x2a2700('0x1166')](function(_0x1ce66d){const _0x47410f=_0x2a2700;if(_0x1ce66d){_0x416aa2[_0x47410f('0x27bf')][_0x15558f['id']]=!![];const _0x3c79a3={'id':_0x15558f['id'],'lastAssignedTo':_0x15558f[_0x47410f('0x3b9')]?_0x416aa2[_0x47410f('0x98')][_0x47410f('0x4f0')]:null,'assigned':_0x15558f[_0x47410f('0x3b9')],'disposition':_0x1ce66d['firstLevel']||null,'secondDisposition':_0x1ce66d[_0x47410f('0xefe')]||null,'thirdDisposition':_0x1ce66d[_0x47410f('0x1d91')]||null};_0x5d1d2d[_0x47410f('0x1ede')][_0x47410f('0x1449')](_0x3c79a3)[_0x47410f('0xa44')]['catch'](function(_0x2407b0){const _0x70269a=_0x47410f;console[_0x70269a('0x455')](_0x2407b0);})[_0x47410f('0x1951')](function(){const _0x1c4cf9=_0x47410f;_0x416aa2[_0x1c4cf9('0x27bf')][_0x15558f['id']]=![];});}});}function _0x48e25d(){const _0x44b7e7=_0x56233f;_0x416aa2[_0x44b7e7('0x2218')]['filter']=undefined,_0x416aa2['isSearchBarVisible']=![];}function _0x182351(){_0x416aa2['isSearchBarVisible']=!![];}let _0x1709c5=!![],_0xb25706=0x1;_0x39027c['$watch'](_0x56233f('0x21e3'),function(_0x4d6c89,_0x48e259){const _0x33f19c=_0x56233f;_0x1709c5?_0x5374ef(function(){_0x1709c5=![];}):(!_0x48e259&&(_0xb25706=_0x416aa2[_0x33f19c('0x2218')][_0x33f19c('0x1a43')]),_0x4d6c89!==_0x48e259&&(_0x416aa2[_0x33f19c('0x2218')][_0x33f19c('0x1a43')]=0x1),!_0x4d6c89&&(_0x416aa2['query'][_0x33f19c('0x1a43')]=_0xb25706),_0x416aa2['getAbandonedCalls']());});function _0x40476f(){const _0x5113f7=_0x56233f;_0x416aa2[_0x5113f7('0xc6e')]=![],_0x416aa2[_0x5113f7('0x17df')]();}function _0x4e5edf(_0x3843c6){const _0x3a365b=_0x56233f;_0x3843c6&&(_0x416aa2[_0x3a365b('0x27bf')][_0x3843c6['id']]=!![],_0x5d1d2d['voiceQueueReport'][_0x3a365b('0x1449')]({'id':_0x3843c6['id'],'lastAssignedTo':_0x3843c6['assigned']?_0x416aa2[_0x3a365b('0x98')][_0x3a365b('0x4f0')]:null,'assigned':_0x3843c6['assigned']})[_0x3a365b('0xa44')]['catch'](function(_0x429c89){const _0x3fb75d=_0x3a365b;console[_0x3fb75d('0x455')](_0x429c89);})[_0x3a365b('0x1951')](function(){const _0x34571b=_0x3a365b;_0x416aa2[_0x34571b('0x27bf')][_0x3843c6['id']]=![];}));}function _0x2999db(_0x5c580b){const _0x42eceb=_0x56233f;_0x416aa2[_0x42eceb('0x2392')]&&_0x5c580b[_0x42eceb('0x1345')]===_0x42eceb('0x587')&&_0x416aa2['queuesMap'][_0x5c580b[_0x42eceb('0x1d3e')]]&&(_0x416aa2[_0x42eceb('0xc6e')]=!![]);}function _0x10e6b1(_0x30d832){const _0xc26170=_0x56233f;if(_0x30d832){const _0x3d51cc=_0x2cfb05()['findIndex'](_0x416aa2['abandonedCalls'][_0xc26170('0x269a')],['id',_0x30d832['id']]);_0x3d51cc>=0x0&&_0x2cfb05()['merge'](_0x416aa2['abandonedCalls'][_0xc26170('0x269a')][_0x3d51cc],_0x30d832);}}_0x39027c[_0x56233f('0x3d2')](_0x56233f('0x1c3f'),function(){const _0x3715b4=_0x56233f;_0x64fc6c[_0x3715b4('0x1800')]('voiceQueueReport:save'),_0x64fc6c['removeAllListeners']('voiceQueueReport:update');});}const _0x2fe1ea=_0x9084d2;_0x3ac412['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x4ea'),_0x36e6f4('0x1004'),_0x36e6f4('0x200f')];function _0x3ac412(_0x203fba,_0x25bacf,_0x2e7f18,_0x252ced){const _0x35d213=_0x36e6f4,_0x5670e5=this;_0x5670e5[_0x35d213('0x4ea')]=_0x25bacf[_0x35d213('0x269a')],_0x5670e5[_0x35d213('0x1004')]=_0x2e7f18[_0x35d213('0x269a')],_0x5670e5[_0x35d213('0x200f')]=_0x252ced,_0x5670e5[_0x35d213('0x2b1')]=_0x5670e5[_0x35d213('0x200f')][_0x35d213('0x2b1')]||undefined,_0x5670e5[_0x35d213('0xe8d')]=_0x12e4c4,_0x5670e5['clearDispositionSelection']=_0x4dd4ba,_0x5670e5['saveDisposition']=_0x3cd9ed,_0x5670e5[_0x35d213('0x24a0')]=_0x21ed65;function _0x12e4c4(_0x378758){const _0xf58583=_0x35d213,_0x328285=_0x2cfb05()[_0xf58583('0x2231')](_0x5670e5[_0xf58583('0x4ea')],_0x5670e5[_0xf58583('0x1004')],'id');switch(_0x378758){case'first':_0x5670e5['selectedDisposition']=_0x5670e5['firstLevelDisposition'],_0x5670e5[_0xf58583('0x2280')]=_0x2cfb05()[_0xf58583('0x1798')](_0x328285,[_0xf58583('0x11fa'),_0x5670e5[_0xf58583('0x1a44')]['id']]),_0x5670e5[_0xf58583('0x2092')]=undefined,_0x5670e5[_0xf58583('0x649')]=undefined,_0x5670e5['anyThirdLevelDisposition']=![];break;case'second':_0x5670e5[_0xf58583('0x279b')]=_0x5670e5[_0xf58583('0x2092')],_0x5670e5[_0xf58583('0x266a')]=_0x2cfb05()[_0xf58583('0x1798')](_0x328285,[_0xf58583('0x11fa'),_0x5670e5[_0xf58583('0x2092')]['id']]);break;case _0xf58583('0x15e9'):_0x5670e5[_0xf58583('0x279b')]=_0x5670e5[_0xf58583('0x649')];break;}}function _0x4dd4ba(_0x5d78cc){const _0x2d1308=_0x35d213;if(_0x5d78cc===_0x2d1308('0x161a'))_0x5670e5[_0x2d1308('0x2092')]=undefined,_0x5670e5[_0x2d1308('0x649')]=undefined,_0x5670e5[_0x2d1308('0x279b')]=_0x5670e5[_0x2d1308('0x1a44')];else _0x5d78cc===_0x2d1308('0x15e9')&&(_0x5670e5[_0x2d1308('0x649')]=undefined,_0x5670e5[_0x2d1308('0x279b')]=_0x5670e5[_0x2d1308('0x2092')]);}function _0x3cd9ed(){const _0xeee88d=_0x35d213;_0x5670e5[_0xeee88d('0x200f')][_0xeee88d('0x2b1')]=_0x5670e5[_0xeee88d('0x2b1')];const _0x177b2e={'firstLevel':_0x5670e5[_0xeee88d('0x1a44')]?_0x5670e5['firstLevelDisposition'][_0xeee88d('0x4f0')]:undefined,'secondLevel':_0x5670e5[_0xeee88d('0x2092')]?_0x5670e5[_0xeee88d('0x2092')][_0xeee88d('0x4f0')]:undefined,'thirdLevel':_0x5670e5[_0xeee88d('0x649')]?_0x5670e5[_0xeee88d('0x649')][_0xeee88d('0x4f0')]:undefined};_0x203fba[_0xeee88d('0x1197')](_0x177b2e);}function _0x21ed65(){const _0x4484c2=_0x35d213;_0x203fba[_0x4484c2('0x3f')]();}}const _0x197a7c=_0x3ac412;_0x12ad8b[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$window',_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x2661')];function _0x12ad8b(_0x442773,_0x265d16,_0x4fa7ad,_0x9ba5ca,_0x5195ec,_0x3479f2,_0x1fe0e2,_0x271dac,_0x58bd40){const _0xa86ef6=_0x36e6f4,_0x48943a=this;_0x48943a[_0xa86ef6('0xc6e')]=![],_0x48943a[_0xa86ef6('0x1a73')]=!![],_0x48943a[_0xa86ef6('0x27bf')]=[],_0x48943a[_0xa86ef6('0x4ea')]={'count':0x0,'rows':[]},_0x48943a[_0xa86ef6('0x98')]=_0x271dac[_0xa86ef6('0x26cd')](),_0x48943a[_0xa86ef6('0x7a7')]={},_0x48943a[_0xa86ef6('0x224c')]={'count':0x0,'rows':[]},_0x48943a[_0xa86ef6('0x2218')]={'fields':_0xa86ef6('0x1cd1'),'type':'inbound','queuecallerexitreason':_0xa86ef6('0x197b')+','+'ABANDONED','sort':'-updatedAt','limit':0xa,'page':0x1},_0x48943a[_0xa86ef6('0x17df')]=_0x56e910,_0x48943a[_0xa86ef6('0x1def')]=_0xd2d519,_0x48943a['onInit']=_0x39236a,_0x48943a['reserved']=_0x1b7c6c,_0x48943a[_0xa86ef6('0xbb5')]=_0x535d16,_0x48943a['call']=_0x442773[_0xa86ef6('0x23ac')][_0xa86ef6('0x23ac')][_0xa86ef6('0x23ac')][_0xa86ef6('0x23ac')]['vm'][_0xa86ef6('0x200f')],_0x48943a['transfer']=_0x442773['$parent']['$parent'][_0xa86ef6('0x23ac')][_0xa86ef6('0x23ac')]['vm'][_0xa86ef6('0x646')],_0x48943a[_0xa86ef6('0xf91')]=_0x442773[_0xa86ef6('0x23ac')][_0xa86ef6('0x23ac')][_0xa86ef6('0x23ac')][_0xa86ef6('0x23ac')]['vm'][_0xa86ef6('0xf91')],_0x48943a[_0xa86ef6('0x1270')]=_0x442773[_0xa86ef6('0x23ac')][_0xa86ef6('0x23ac')]['$parent'][_0xa86ef6('0x23ac')]['vm'][_0xa86ef6('0x1270')],_0x48943a[_0xa86ef6('0x109e')]=_0x3d4b80,_0x48943a[_0xa86ef6('0x3c5')]=_0x5ed694,_0x58bd40['onWithoutApply'](_0xa86ef6('0x2615'),_0x26c0fb),_0x58bd40[_0xa86ef6('0xe82')](_0xa86ef6('0x4b0'),_0x44a468),_0x39236a();function _0x39236a(){const _0x292d36=_0xa86ef6;return _0x1fe0e2['disposition'][_0x292d36('0xd83')]({'MailAccountId':_0x292d36('0x15d7'),'FaxAccountId':_0x292d36('0x15d7'),'SmsAccountId':_0x292d36('0x15d7'),'WhatsappAccountId':'null','OpenchannelAccountId':_0x292d36('0x15d7'),'ChatWebsiteId':'null'})[_0x292d36('0xa44')][_0x292d36('0x1166')](function(_0xf920e3){const _0x378fba=_0x292d36;return _0x48943a['dispositions']=_0xf920e3?_0xf920e3[_0x378fba('0x269a')]:[],_0x1fe0e2[_0x378fba('0x557')][_0x378fba('0x152a')]({'id':_0x271dac[_0x378fba('0x26cd')]()['id'],'fields':_0x378fba('0x1776'),'channel':_0x378fba('0x21da'),'type':_0x378fba('0x14d8'),'nolimit':!![]})['$promise'];})[_0x292d36('0x1166')](function(_0x275d44){const _0x55d66b=_0x292d36;_0x48943a[_0x55d66b('0x7a7')]=_0x275d44||{'count':0x0,'rows':[]},_0x48943a[_0x55d66b('0x2392')]=_0x2cfb05()['mapValues'](_0x2cfb05()['keyBy'](_0x48943a['queues']['rows'],_0x55d66b('0x4f0')),_0x55d66b('0x4f0')),_0x48943a[_0x55d66b('0x12eb')]=_0x48943a['queues']['rows']?_0x2cfb05()[_0x55d66b('0x2563')](_0x48943a[_0x55d66b('0x7a7')][_0x55d66b('0x269a')],_0x55d66b('0x4f0'))[_0x55d66b('0x45a')](','):undefined;})[_0x292d36('0x1166')](function(){const _0x11c577=_0x292d36;_0x48943a[_0x11c577('0x6cb')]=_0x556407();})[_0x292d36('0x1a80')](function(_0xf918c0){const _0x44b850=_0x292d36;console[_0x44b850('0x455')](_0xf918c0);})['finally'](function(){const _0x2e44f1=_0x292d36;let _0x486b56=_0x5195ec[_0x2e44f1('0x275')][_0x2e44f1('0x15f7')]('motion2.home.abandoned.voice.calls:'+_0x48943a[_0x2e44f1('0x98')]['id']);if(_0x486b56)_0x486b56=JSON[_0x2e44f1('0x1295')](_0x486b56),_0x486b56['query']&&(_0x48943a[_0x2e44f1('0x2218')]=_0x2cfb05()[_0x2e44f1('0xcc3')](_0x486b56['query'],_0x2cfb05()[_0x2e44f1('0x1414')](_0x48943a[_0x2e44f1('0x2218')],[_0x2e44f1('0x1aba'),_0x2e44f1('0x163f'),_0x2e44f1('0x1a43')])),_0x48943a['query']=_0x2cfb05()[_0x2e44f1('0x1414')](_0x48943a[_0x2e44f1('0x2218')],_0x2e44f1('0x1c33')));else{const _0x1c8fb9={'$gte':_0x24273b()()[_0x2e44f1('0x1659')](_0x2e44f1('0x2e7'))['utcOffset'](0x0,!![])[_0x2e44f1('0x128a')](),'$lte':_0x24273b()()[_0x2e44f1('0x2589')](_0x2e44f1('0x2e7'))[_0x2e44f1('0x13f2')](0x0,!![])[_0x2e44f1('0x128a')]()};_0x48943a['query'][_0x2e44f1('0x262')]=_0x1c8fb9;}_0x48943a[_0x2e44f1('0x7cc')]=_0x48943a[_0x2e44f1('0x2218')]['filter']?!![]:![],_0x48943a[_0x2e44f1('0x17df')]();});}function _0x556407(){const _0x363270=_0xa86ef6;return[{'name':_0x363270('0x2567'),'key':_0x363270('0x262'),'type':'date','label':_0x363270('0x16d9')},{'name':_0x363270('0x89b'),'key':_0x363270('0x122a'),'type':_0x363270('0x88a'),'label':_0x363270('0x1db1'),'customOptions':[{'value':_0x48943a[_0x363270('0x98')]['id'],'translate':'DASHBOARDS.ME'},{'value':_0x363270('0x1c08'),'translate':_0x363270('0x216b')},{'value':undefined,'translate':_0x363270('0x2150')}]},{'name':_0x363270('0xaaf'),'key':'queue','type':_0x363270('0x2162'),'label':'DASHBOARDS.SELECT_QUEUE','options':_0x48943a[_0x363270('0x7a7')][_0x363270('0x269a')],'ngValue':_0x363270('0x4f0'),'clearAll':![]}];}function _0x56e910(){const _0x4c2d05=_0xa86ef6;_0x48943a[_0x4c2d05('0x2218')][_0x4c2d05('0x1d3e')]=_0x48943a[_0x4c2d05('0x2218')][_0x4c2d05('0x1d3e')]||_0x48943a[_0x4c2d05('0x12eb')][_0x4c2d05('0x25c8')](','),_0x48943a[_0x4c2d05('0x2218')][_0x4c2d05('0x1098')]=(_0x48943a[_0x4c2d05('0x2218')]['page']-0x1)*_0x48943a[_0x4c2d05('0x2218')][_0x4c2d05('0x163f')];const _0x1f3142={'query':_0x48943a[_0x4c2d05('0x2218')]};_0x5195ec[_0x4c2d05('0x275')][_0x4c2d05('0xa26')](_0x4c2d05('0x22e4')+_0x48943a[_0x4c2d05('0x98')]['id'],JSON[_0x4c2d05('0xbac')](_0x1f3142)),_0x48943a['promise']=_0x1fe0e2['voiceQueueReport'][_0x4c2d05('0x1cdb')](_0x48943a['query'],_0x1ff158)[_0x4c2d05('0xa44')];}function _0x1ff158(_0x3a6ed4){const _0x56def1=_0xa86ef6;_0x48943a[_0x56def1('0x224c')]=_0x3a6ed4||{'count':0x0,'rows':[]},_0x48943a[_0x56def1('0x1a73')]=!![];}function _0x535d16(_0x27648d){const _0x3051dd=_0xa86ef6;_0x4fa7ad[_0x3051dd('0x1f80')]({'controller':'DisposeAbandonedCallDialogController','controllerAs':'vm','templateUrl':_0x3051dd('0x23b0'),'parent':angular[_0x3051dd('0x1194')](_0x9ba5ca[_0x3051dd('0x8d2')]),'targetEvent':_0x27648d,'resolve':{'globalDispositions':[_0x3051dd('0x1fbc'),function(_0x346b5a){const _0x489495=_0x3051dd;return _0x346b5a['resolve']('disposition@get',{'MailAccountId':_0x489495('0x15d7'),'FaxAccountId':_0x489495('0x15d7'),'SmsAccountId':_0x489495('0x15d7'),'WhatsappAccountId':_0x489495('0x15d7'),'OpenchannelAccountId':'null','ChatWebsiteId':_0x489495('0x15d7'),'ListId':_0x489495('0x15d7')});}]},'locals':{'dispositions':_0x48943a[_0x3051dd('0x4ea')],'call':_0x27648d}})[_0x3051dd('0x1166')](function(_0x18be6a){const _0x222495=_0x3051dd;if(_0x18be6a){_0x48943a[_0x222495('0x27bf')][_0x27648d['id']]=!![];const _0x421f12={'id':_0x27648d['id'],'lastAssignedTo':_0x27648d['assigned']?_0x48943a[_0x222495('0x98')][_0x222495('0x4f0')]:null,'assigned':_0x27648d[_0x222495('0x3b9')],'disposition':_0x18be6a[_0x222495('0xdc6')]||null,'secondDisposition':_0x18be6a['secondLevel']||null,'thirdDisposition':_0x18be6a[_0x222495('0x1d91')]||null};_0x1fe0e2[_0x222495('0x1ede')][_0x222495('0x1449')](_0x421f12)[_0x222495('0xa44')][_0x222495('0x1a80')](function(_0x4397c1){const _0xb98782=_0x222495;console[_0xb98782('0x455')](_0x4397c1);})['finally'](function(){const _0x1e7a4e=_0x222495;_0x48943a[_0x1e7a4e('0x27bf')][_0x27648d['id']]=![];});}});}function _0x3d4b80(){const _0x4d35ed=_0xa86ef6;_0x48943a['query'][_0x4d35ed('0x1c33')]=undefined,_0x48943a[_0x4d35ed('0x7cc')]=![];}function _0x5ed694(){_0x48943a['isSearchBarVisible']=!![];}let _0xe78cc1=!![],_0x5d5153=0x1;_0x442773[_0xa86ef6('0xe83')](_0xa86ef6('0x3c9'),function(_0x22a8d9,_0x44f67b){const _0x136a6d=_0xa86ef6;_0xe78cc1?_0x265d16(function(){_0xe78cc1=![];}):(!_0x44f67b&&(_0x5d5153=_0x48943a[_0x136a6d('0x2218')][_0x136a6d('0x1a43')]),_0x22a8d9!==_0x44f67b&&(_0x48943a[_0x136a6d('0x2218')]['page']=0x1),!_0x22a8d9&&(_0x48943a[_0x136a6d('0x2218')][_0x136a6d('0x1a43')]=_0x5d5153),_0x48943a[_0x136a6d('0x17df')]());});function _0xd2d519(){const _0x30e740=_0xa86ef6;_0x48943a['showTooltip']=![],_0x48943a[_0x30e740('0x17df')]();}function _0x1b7c6c(_0x3980b4){const _0x1cbd4e=_0xa86ef6;_0x3980b4&&(_0x48943a[_0x1cbd4e('0x27bf')][_0x3980b4['id']]=!![],_0x1fe0e2[_0x1cbd4e('0x1ede')][_0x1cbd4e('0x1449')]({'id':_0x3980b4['id'],'lastAssignedTo':_0x3980b4['assigned']?_0x48943a[_0x1cbd4e('0x98')]['name']:null,'assigned':_0x3980b4['assigned']})['$promise'][_0x1cbd4e('0x1a80')](function(_0x3017e8){console['log'](_0x3017e8);})[_0x1cbd4e('0x1951')](function(){const _0x3baa1a=_0x1cbd4e;_0x48943a[_0x3baa1a('0x27bf')][_0x3980b4['id']]=![];}));}function _0x26c0fb(_0x2bddd0){const _0x538ff5=_0xa86ef6;_0x48943a[_0x538ff5('0x2392')]&&_0x2bddd0[_0x538ff5('0x1345')]===_0x538ff5('0x14d8')&&_0x48943a[_0x538ff5('0x2392')][_0x2bddd0[_0x538ff5('0x1d3e')]]&&(_0x48943a[_0x538ff5('0xc6e')]=!![]);}function _0x44a468(_0x35d894){const _0x486b5b=_0xa86ef6;if(_0x35d894){const _0x1f6482=_0x2cfb05()[_0x486b5b('0xede')](_0x48943a['abandonedCalls'][_0x486b5b('0x269a')],['id',_0x35d894['id']]);_0x1f6482>=0x0&&_0x2cfb05()[_0x486b5b('0xcc3')](_0x48943a['abandonedCalls'][_0x486b5b('0x269a')][_0x1f6482],_0x35d894);}}_0x442773[_0xa86ef6('0x3d2')]('$destroy',function(){const _0x5b4d9f=_0xa86ef6;_0x58bd40[_0x5b4d9f('0x1800')](_0x5b4d9f('0x2615')),_0x58bd40[_0x5b4d9f('0x1800')](_0x5b4d9f('0x4b0'));});}const _0x5bfe67=_0x12ad8b;_0x320bed[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),'Auth',_0x36e6f4('0x2256'),_0x36e6f4('0x102a')];function _0x320bed(_0x57fa15,_0x4e48fd,_0x3d516a,_0x243e24,_0x46f241){const _0x2b0745=_0x36e6f4,_0x36608c=this;_0x36608c[_0x2b0745('0x557')]=_0x3d516a[_0x2b0745('0x26cd')](),_0x36608c[_0x2b0745('0x5c9')]={},_0x36608c[_0x2b0745('0xc0e')]={},_0x36608c[_0x2b0745('0xf8a')]={},_0x36608c[_0x2b0745('0x234f')]=_0x2b0745('0xba2'),_0x36608c[_0x2b0745('0x102a')]=_0x46f241,_0x36608c[_0x2b0745('0x15ea')]=_0x243e24[_0x2b0745('0x1568')](),_0x36608c[_0x2b0745('0x247b')]=_0x57fa15[_0x2b0745('0x23ac')]['vm'][_0x2b0745('0x247b')],_0x36608c[_0x2b0745('0x126e')]=_0x57fa15[_0x2b0745('0x23ac')]['vm'][_0x2b0745('0x126e')],_0x36608c[_0x2b0745('0x24d5')]=_0x3285dc,_0x36608c['changeSidebarTab']=_0x1be39b,_0x36608c[_0x2b0745('0x1167')]=_0x2cbfbc;function _0x3285dc(_0x44e9e1,_0x45d57a){const _0x55c35c=_0x2b0745;_0x36608c[_0x55c35c('0x5c9')]=_0x44e9e1,_0x36608c[_0x55c35c('0xf8a')]=_0x45d57a;let _0x3fe3c6=_0x4e48fd['localStorage'][_0x55c35c('0x15f7')](_0x55c35c('0x1daa')+_0x36608c[_0x55c35c('0x557')]['id']);if(_0x3fe3c6){try{_0x3fe3c6=JSON[_0x55c35c('0x1295')](_0x3fe3c6),_0x36608c['sidebar']=_0x3fe3c6['currentSidebarTab']?_0x3fe3c6[_0x55c35c('0x6d8')]:_0x55c35c('0xba2');}catch(_0x2e5c98){console[_0x55c35c('0xfc9')](_0x2e5c98),_0x36608c[_0x55c35c('0x234f')]=_0x55c35c('0xba2');}_0x36608c[_0x55c35c('0x234f')]===_0x55c35c('0x1bfa')&&_0x36608c[_0x55c35c('0x102a')][_0x55c35c('0x24d5')]();}}function _0x2cbfbc(_0xc58bd7){const _0x5de9e8=_0x2b0745;return _0x3d516a[_0x5de9e8('0x1167')](_0xc58bd7);}function _0x1be39b(_0x25f3fc){const _0x41b954=_0x2b0745;_0x36608c['sidebar']=_0x25f3fc[_0x41b954('0x14ac')],_0x36608c['sidebar']===_0x41b954('0xc0e')&&(_0x36608c[_0x41b954('0xc0e')]=_0x25f3fc[_0x41b954('0x1677')],_0x36608c[_0x41b954('0x2191')]=_0x25f3fc['id'],_0x57fa15[_0x41b954('0x1d73')]('pluginUpdated',{'plugin':_0x36608c[_0x41b954('0xc0e')]})),_0x4e48fd['localStorage'][_0x41b954('0xa26')](_0x41b954('0x1daa')+_0x36608c['user']['id'],JSON[_0x41b954('0xbac')]({'currentSidebarTab':_0x25f3fc[_0x41b954('0x14ac')]}));}_0x57fa15[_0x2b0745('0xe83')](_0x2b0745('0x190f'),function(_0x2883bc){const _0x5790b9=_0x2b0745;_0x2883bc===_0x5790b9('0x1bfa')?_0x36608c[_0x5790b9('0x102a')][_0x5790b9('0x24d5')]():_0x36608c[_0x5790b9('0x102a')][_0x5790b9('0x7a8')]={};});}const _0x302c19=_0x320bed,_0x120bea=_0x2734b2['p']+_0x36e6f4('0x924');_0x5b82c6['$inject']=['$scope',_0x36e6f4('0x8da'),'$mdDialog',_0x36e6f4('0x1c90'),'$window','$translate',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x2661'),_0x36e6f4('0x1d2e')];function _0x5b82c6(_0x550052,_0x4c7d06,_0x39ea1e,_0x52b331,_0x19c8e0,_0x542832,_0x4fdf9a,_0x3a2556,_0x5b2e8b,_0x2ddfbd){const _0x375643=_0x36e6f4,_0x2a5902=this;_0x2a5902[_0x375643('0x557')]=_0x3a2556[_0x375643('0x26cd')](),_0x2a5902[_0x375643('0x5c9')]={},_0x2a5902['setting']={},_0x2a5902[_0x375643('0xb38')]={'count':0x0,'rows':[]},_0x2a5902[_0x375643('0x209e')]={'count':0x0,'rows':[]},_0x2a5902['query']={'includeAll':!![],'sort':_0x375643('0x14dc'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x2a5902[_0x375643('0x1291')]={'fields':[{'name':'Id','column':'id','type':_0x375643('0xc45')},{'name':'Contact','column':'Contact','type':_0x375643('0x1a01'),'options':{'searchFields':['firstName','lastName','email'],'route':{'model':'cmContact','action':_0x375643('0xd83'),'params':{'fields':'id,firstName,lastName,email','Contact':_0x375643('0x145b'),'nolimit':!![]}},'extraOperators':[_0x375643('0x2836')],'excludedOperators':[_0x375643('0x2646')]}},{'name':_0x375643('0xe1'),'column':'body','type':'text','options':{'excludedOperators':[_0x375643('0x110'),'$ne']}},{'name':_0x375643('0x28f6'),'column':_0x375643('0xa5b'),'type':_0x375643('0x88a'),'values':[{'id':0x0,'translate':_0x375643('0xdeb')},{'id':0x1,'translate':_0x375643('0x58f')}],'options':{'excludedOperators':['$ne']}},{'name':_0x375643('0x174'),'column':_0x375643('0x159f'),'type':_0x375643('0x1640'),'options':{'excludedOperators':[_0x375643('0x110'),'$ne',_0x375643('0x19ba'),_0x375643('0x1ae')]}},{'name':_0x375643('0x89b'),'column':_0x375643('0x1a6f'),'type':_0x375643('0x1a01'),'options':{'table':'i','route':{'model':'user','action':'get','params':{'role':_0x375643('0x1eff'),'fields':_0x375643('0xce1'),'nolimit':!![]}},'searchFields':[_0x375643('0x6e1'),'name'],'extraOperators':[_0x375643('0x2836')],'excludedOperators':['$ne']}},{'name':_0x375643('0x13b6'),'column':_0x375643('0x1e02'),'type':_0x375643('0x2162'),'options':{'route':{'model':_0x375643('0x557'),'action':_0x375643('0x36d'),'params':{'id':_0x2a5902[_0x375643('0x557')]['id'],'nolimit':!![]}}}},{'name':_0x375643('0x21c2'),'column':_0x375643('0x1b35'),'type':'multiselect','options':{'route':{'model':'tag','action':'get','params':{'nolimit':!![]}},'excludedOperators':[_0x375643('0x18d')]}},{'name':_0x375643('0x2567'),'column':_0x375643('0x262'),'type':_0x375643('0x1643'),'options':{'excludedOperators':[_0x375643('0x2646')]}},{'name':'Read','column':_0x375643('0x723'),'type':_0x375643('0x88a'),'values':[{'id':0x1,'translate':'DASHBOARDS.READ'},{'id':0x0,'translate':'DASHBOARDS.UNREAD'}],'options':{'excludedOperators':['$ne']}}]},_0x2a5902['sectionColor']=_0x375643('0x1d17'),_0x2a5902['onInit']=_0x52d322,_0x2a5902['success']=_0xd1d42f,_0x2a5902[_0x375643('0x12ce')]=_0x5947cf,_0x2a5902[_0x375643('0x26e')]=_0x58c7c2,_0x2a5902['downloadChatInteraction']=_0x3fe4a2,_0x2a5902[_0x375643('0xb52')]=_0x1db173,_0x2a5902[_0x375643('0x250c')]=_0x5bd374,_0x2a5902[_0x375643('0x2253')]=_0x2b5f9e,_0x2a5902[_0x375643('0x262c')]=_0x18a4db,_0x2a5902['onSearchBarCollapse']=_0x9986a1,_0x2a5902[_0x375643('0x3c5')]=_0x438ad5,_0x2a5902['openAdvancedSearch']=_0x14d04a;function _0x52d322(_0x30f7bc,_0xd0c401){const _0x4fb6a5=_0x375643;return _0x2a5902[_0x4fb6a5('0x5c9')]=_0x30f7bc,_0x2a5902[_0x4fb6a5('0xf8a')]=_0xd0c401,_0x4fdf9a[_0x4fb6a5('0x557')][_0x4fb6a5('0xd83')+_0x2cfb05()[_0x4fb6a5('0x114b')](_0x4fb6a5('0xbe9'))]({'id':_0x2a5902[_0x4fb6a5('0x557')]['id'],'nolimit':!![]})[_0x4fb6a5('0xa44')]['then'](function(_0x587880){const _0x4b2499=_0x4fb6a5;return _0x2a5902['chatAccounts']=_0x587880||{'count':0x0,'rows':[]},_0x4fdf9a['tag'][_0x4b2499('0xd83')]()[_0x4b2499('0xa44')];})[_0x4fb6a5('0x1166')](function(_0xac95e0){const _0x54660d=_0x4fb6a5;_0x2a5902[_0x54660d('0xb38')]=_0xac95e0||{'count':0x0,'rows':[]};})[_0x4fb6a5('0x1166')](function(){const _0x46a6d5=_0x4fb6a5;_0x2a5902[_0x46a6d5('0x6cb')]=_0x4466a5();})['catch'](function(_0x16a1a2){const _0x339bf3=_0x4fb6a5;console[_0x339bf3('0xfc9')](_0x16a1a2);})[_0x4fb6a5('0x1951')](function(){const _0x163fef=_0x4fb6a5;let _0x2c6c16=_0x19c8e0['localStorage']['getItem']('motion2.home.chat:'+_0x2a5902[_0x163fef('0x557')]['id']);if(_0x2c6c16)try{_0x2c6c16=JSON[_0x163fef('0x1295')](_0x2c6c16);if(_0x2c6c16[_0x163fef('0x2218')]){_0x2a5902['query']=_0x2cfb05()[_0x163fef('0xcc3')](_0x2a5902[_0x163fef('0x2218')],_0x2c6c16['query']);if(_0x2cfb05()[_0x163fef('0x1081')](_0x2a5902[_0x163fef('0x20e0')][_0x163fef('0x269a')]))_0x2a5902[_0x163fef('0x2218')][_0x163fef('0x1e02')]=[];else _0x2cfb05()[_0x163fef('0x1081')](_0x2a5902[_0x163fef('0x2218')][_0x163fef('0x1e02')])&&(_0x2a5902[_0x163fef('0x2218')][_0x163fef('0x1e02')]=_0x2cfb05()(_0x2a5902[_0x163fef('0x20e0')][_0x163fef('0x269a')])[_0x163fef('0x2563')]('id')['take']()['value']());_0x2a5902[_0x163fef('0x2218')]['sort']&&_0x2a5902['query'][_0x163fef('0x1aba')][_0x163fef('0x2379')]('lastMessage')>=0x0&&(_0x2a5902['query']=_0x2cfb05()[_0x163fef('0x1414')](_0x2a5902[_0x163fef('0x2218')],_0x163fef('0x1aba'))),_0x2a5902[_0x163fef('0x2218')]['includeAll']=!![],_0x2a5902[_0x163fef('0x7cc')]=_0x2a5902[_0x163fef('0x2218')]['filter']?!![]:![];}}catch(_0x27dff5){console['error'](_0x27dff5);}else{const _0x439338={'$gte':_0x24273b()()[_0x163fef('0x1659')](_0x163fef('0x2e7'))['utcOffset'](0x0,!![])['format'](),'$lte':_0x24273b()()[_0x163fef('0x2589')]('month')['utcOffset'](0x0,!![])[_0x163fef('0x128a')]()},_0x1cfc2e={'ChatWebsiteId':_0x2cfb05()[_0x163fef('0x2563')](_0x2a5902[_0x163fef('0x20e0')][_0x163fef('0x269a')],'id'),'createdAt':_0x439338};_0x2a5902['query']=_0x2cfb05()[_0x163fef('0xcc3')](_0x2a5902['query'],_0x1cfc2e);}_0x5b2e8b['on'](_0x163fef('0x2724'),_0x47a63d),_0x5b2e8b['on']('chatInteraction:update',_0x47a63d),_0x5b2e8b['on']('chatInteractionTags:save',_0x7ce48d),_0x5b2e8b['on']('chatMessage:save',_0x5a7402),_0x5b2e8b['on'](_0x163fef('0xddd'),_0x5a7402),_0x5b2e8b['on']('user_has_chat_interactions:save',_0x54c1aa),_0x5b2e8b['on'](_0x163fef('0x19c3'),_0x34639a),_0x5947cf(_0x2a5902['query'][_0x163fef('0x1a43')]);});}function _0x4466a5(){const _0x5b9fa2=_0x375643;return[{'name':_0x5b9fa2('0x2567'),'key':_0x5b9fa2('0x262'),'type':_0x5b9fa2('0x1643'),'label':'DASHBOARDS.SELECT_DATE'},{'name':_0x5b9fa2('0x116c'),'key':'read','type':'select','label':_0x5b9fa2('0x379'),'customOptions':[{'value':0x0,'translate':_0x5b9fa2('0x2c8')},{'value':0x1,'translate':_0x5b9fa2('0x1057')},{'value':null,'translate':_0x5b9fa2('0x2150')}]},{'name':'Status','key':_0x5b9fa2('0xa5b'),'type':_0x5b9fa2('0x88a'),'label':_0x5b9fa2('0xe32'),'customOptions':[{'value':0x0,'translate':_0x5b9fa2('0xdeb')},{'value':0x1,'translate':_0x5b9fa2('0x58f')},{'value':null,'translate':_0x5b9fa2('0x2150')}]},{'name':'Website','key':_0x5b9fa2('0x1e02'),'type':_0x5b9fa2('0x2162'),'label':_0x5b9fa2('0x6da'),'options':_0x2a5902[_0x5b9fa2('0x20e0')][_0x5b9fa2('0x269a')],'clearAll':![]},{'name':_0x5b9fa2('0x89b'),'key':'UserId','type':_0x5b9fa2('0x88a'),'label':'DASHBOARDS.SELECT_AGENT','customOptions':[{'value':_0x2a5902[_0x5b9fa2('0x557')]['id'],'translate':_0x5b9fa2('0x15ae')},{'value':_0x5b9fa2('0x15d7'),'translate':_0x5b9fa2('0x216b')},{'value':undefined,'translate':'DASHBOARDS.ALL'}]},{'name':_0x5b9fa2('0x1b35'),'key':_0x5b9fa2('0x1446'),'type':_0x5b9fa2('0x2162'),'label':_0x5b9fa2('0x1669'),'options':_0x2a5902[_0x5b9fa2('0xb38')][_0x5b9fa2('0x269a')],'placeholder':_0x5b9fa2('0x2223')}];}function _0xd1d42f(_0x59961c){const _0x19e422=_0x375643;_0x2a5902[_0x19e422('0x293')]=![],_0x2a5902['chatInteractions']=_0x59961c||{'count':0x0,'rows':[]};for(let _0xbd0a10=0x0;_0xbd0a10<_0x2a5902['chatInteractions']['rows'][_0x19e422('0x264b')];_0xbd0a10+=0x1){_0x5bd374(_0x2a5902[_0x19e422('0x209e')][_0x19e422('0x269a')][_0xbd0a10]);}}function _0x5947cf(_0x321f4a){const _0x5ee9fb=_0x375643;_0x2a5902['searchInProgress']=!![];!_0x321f4a&&(_0x2a5902[_0x5ee9fb('0x2218')][_0x5ee9fb('0x1a43')]=0x1);_0x2a5902['query'][_0x5ee9fb('0x1098')]=(_0x2a5902[_0x5ee9fb('0x2218')][_0x5ee9fb('0x1a43')]-0x1)*_0x2a5902[_0x5ee9fb('0x2218')][_0x5ee9fb('0x163f')];let _0x3b47c6=_0x19c8e0[_0x5ee9fb('0x275')][_0x5ee9fb('0x15f7')]('motion2.home.chat:'+_0x2a5902[_0x5ee9fb('0x557')]['id']);_0x3b47c6=_0x3b47c6?JSON[_0x5ee9fb('0x1295')](_0x3b47c6):{},_0x3b47c6['query']=_0x2a5902['query'],_0x19c8e0['localStorage'][_0x5ee9fb('0xa26')]('motion2.home.chat:'+_0x2a5902['user']['id'],JSON['stringify'](_0x3b47c6)),_0x2a5902[_0x5ee9fb('0x1f48')]=_0x4fdf9a['chatInteraction'][_0x5ee9fb('0xd83')](_0x2a5902[_0x5ee9fb('0x2218')],_0xd1d42f)[_0x5ee9fb('0xa44')];}function _0x58c7c2(_0x33e887,_0xa4ec53){const _0x3f3ba3=_0x375643;_0x550052[_0x3f3ba3('0x23ac')]['vm'][_0x3f3ba3('0x126e')]('chat',_0xa4ec53);}function _0x3fe4a2(_0x4633d7,_0x1d443f,_0x2d1b8f){const _0x35ff6a=_0x375643;_0x4fdf9a[_0x35ff6a('0x1162')][_0x35ff6a('0x2ad')]({'id':_0x1d443f['id'],'attachments':_0x2d1b8f})[_0x35ff6a('0xa44')][_0x35ff6a('0x1166')](function(_0xe4aede){const _0x217aa1=_0x35ff6a,_0xce3b76=[_0xe4aede[_0x217aa1('0x20ed')]],_0x187c5d=_0x217aa1('0x22c3')+_0x1d443f['id']+_0x217aa1('0x806'),_0xdc27ee=new Blob(_0xce3b76,{'type':_0xe4aede[_0x217aa1('0x1345')]}),_0x4ad67a=window[_0x217aa1('0x136d')][_0x217aa1('0xdd')]('a');_0x4ad67a['setAttribute']('href',URL[_0x217aa1('0x215a')](_0xdc27ee)),_0x4ad67a['setAttribute'](_0x217aa1('0x2ad'),_0x187c5d),document[_0x217aa1('0x8d2')]['appendChild'](_0x4ad67a),_0x4ad67a[_0x217aa1('0x3b4')]();})[_0x35ff6a('0x1a80')](function(_0x4ff484){const _0x2bbc3f=_0x35ff6a;if(_0x4ff484[_0x2bbc3f('0x25f4')]&&_0x4ff484[_0x2bbc3f('0x25f4')]['errors']&&_0x4ff484['data'][_0x2bbc3f('0x61a')][_0x2bbc3f('0x264b')])for(let _0x44b4de=0x0;_0x44b4de<_0x4ff484[_0x2bbc3f('0x25f4')][_0x2bbc3f('0x61a')][_0x2bbc3f('0x264b')];_0x44b4de+=0x1){_0x2ddfbd[_0x2bbc3f('0xfc9')]({'title':_0x4ff484[_0x2bbc3f('0x25f4')][_0x2bbc3f('0x61a')][_0x44b4de][_0x2bbc3f('0x1345')],'msg':_0x4ff484['data']['errors'][_0x44b4de]['message']});}else _0x2ddfbd[_0x2bbc3f('0xfc9')]({'title':_0x4ff484['status']?_0x2bbc3f('0x1e21')+_0x4ff484['status']+'\x20-\x20'+_0x4ff484['statusText']:_0x2bbc3f('0x2438'),'msg':_0x4ff484[_0x2bbc3f('0x25f4')]?JSON[_0x2bbc3f('0xbac')](_0x4ff484['data'][_0x2bbc3f('0x1e70')]):_0x4ff484[_0x2bbc3f('0x1586')]()});});}function _0x1db173(_0x3830a3,_0x20c215){const _0x7d14ec=_0x375643,_0x2f6024=_0x2a5902['user']['voicePause']||_0x2a5902[_0x7d14ec('0x557')][_0x7d14ec('0x1c5c')]||_0x2a5902[_0x7d14ec('0x557')]['mailPause']||_0x2a5902[_0x7d14ec('0x557')][_0x7d14ec('0x287f')]||_0x2a5902['user'][_0x7d14ec('0x5aa')],_0x54e917=!_0x20c215[_0x7d14ec('0x1758')][_0x7d14ec('0x10d0')];_0x39ea1e[_0x7d14ec('0x1f80')]({'controller':'DisposeInteractionDialogController','controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular[_0x7d14ec('0x1194')](_0x52b331[_0x7d14ec('0x8d2')]),'clickOutsideToClose':_0x54e917,'escapeToClose':_0x54e917,'onRemoving':function(){const _0x339fad=_0x7d14ec;_0x2a5902[_0x339fad('0x557')]&&_0x20c215['Account'][_0x339fad('0x10d0')]&&!_0x2f6024&&_0x4fdf9a['user'][_0x339fad('0x20eb')]({'id':_0x2a5902[_0x339fad('0x557')]['id']})[_0x339fad('0xa44')][_0x339fad('0x1a80')](function(_0x1cc668){const _0x5bc013=_0x339fad;console[_0x5bc013('0xfc9')](_0x1cc668);});},'locals':{'user':_0x2a5902[_0x7d14ec('0x557')],'channel':_0x7d14ec('0xde2'),'interaction':_0x20c215}});}function _0x5bd374(_0x455b70){const _0x4c2602=_0x375643;_0x455b70[_0x4c2602('0x21a4')]?_0x455b70[_0x4c2602('0x15cf')]=(_0x455b70['Contact'][_0x4c2602('0x18cb')]||'')+'\x20'+(_0x455b70[_0x4c2602('0x21a4')][_0x4c2602('0xeb0')]||''):_0x455b70[_0x4c2602('0x15cf')]=_0x542832[_0x4c2602('0x25cc')](_0x4c2602('0x148c'));}function _0x2b5f9e(_0x4e1d78){const _0x5d2351=_0x375643;if(_0x4e1d78[_0x5d2351('0x122a')])return _0x4e1d78[_0x5d2351('0x122a')]===_0x2a5902[_0x5d2351('0x557')]['id']?_0x542832[_0x5d2351('0x25cc')](_0x5d2351('0x15ae')):_0x4e1d78[_0x5d2351('0x121b')][_0x5d2351('0x6e1')]+'\x20<'+_0x4e1d78[_0x5d2351('0x121b')][_0x5d2351('0x1eef')]+'>';return _0x542832[_0x5d2351('0x25cc')](_0x5d2351('0x216b'));}function _0x18a4db(_0x2fa637){const _0x27dd34=_0x375643;if(_0x2fa637[_0x27dd34('0x1758')])return _0x2fa637['Account'][_0x27dd34('0x7ca')];return _0x542832[_0x27dd34('0x25cc')]('DASHBOARDS.UNKNOWN');}function _0x54c1aa(_0x162fc0){const _0x41eca4=_0x375643;let _0x2d0374;const _0x5436e2=_0x2cfb05()[_0x41eca4('0xc38')](_0x2a5902['chatInteractions']['rows'],{'id':_0x162fc0[_0x41eca4('0x2315')]});_0x5436e2&&_0x5436e2[_0x41eca4('0x1bc7')]&&(_0x2d0374=_0x2cfb05()[_0x41eca4('0xc38')](_0x5436e2[_0x41eca4('0x1bc7')],{'id':_0x162fc0[_0x41eca4('0x122a')]}),!_0x2d0374&&_0x5436e2[_0x41eca4('0x1bc7')][_0x41eca4('0x1514')]({'id':_0x162fc0[_0x41eca4('0x122a')]}));}function _0x34639a(_0x299e70){const _0x53dc4a=_0x375643,_0x127da9=_0x2cfb05()[_0x53dc4a('0xc38')](_0x2a5902[_0x53dc4a('0x209e')][_0x53dc4a('0x269a')],{'id':_0x299e70['ChatInteractionId']});_0x127da9&&_0x127da9[_0x53dc4a('0x1bc7')]&&_0x2cfb05()[_0x53dc4a('0x127f')](_0x127da9[_0x53dc4a('0x1bc7')],{'id':_0x299e70['UserId']});}function _0x47a63d(_0x22668e){const _0x3e13e3=_0x375643;if(_0x22668e){const _0xa5d48=_0x2cfb05()[_0x3e13e3('0xc38')](_0x2a5902[_0x3e13e3('0x209e')]['rows'],{'id':_0x22668e['id']});if(_0xa5d48){_0xa5d48[_0x3e13e3('0x1bc7')]=[];_0x22668e['closed']&&(_0xa5d48[_0x3e13e3('0x723')]=0x0);if(_0x2a5902[_0x3e13e3('0x2218')]['sort']){const _0x10b54c=_0x2cfb05()[_0x3e13e3('0x1783')](_0x2a5902[_0x3e13e3('0x2218')][_0x3e13e3('0x1aba')],'-')?'desc':'asc';_0x2a5902['chatInteractions'][_0x3e13e3('0x269a')]=_0x2cfb05()['orderBy'](_0x2a5902[_0x3e13e3('0x209e')]['rows'],_0x2cfb05()[_0x3e13e3('0x19db')](_0x2a5902[_0x3e13e3('0x2218')][_0x3e13e3('0x1aba')],'-'),_0x10b54c);}_0x2cfb05()[_0x3e13e3('0xcc3')](_0xa5d48,_0x2cfb05()[_0x3e13e3('0x1a08')](_0x22668e,_0x2cfb05()[_0x3e13e3('0x14a4')](_0xa5d48)));}else _0x5947cf(_0x2a5902[_0x3e13e3('0x2218')][_0x3e13e3('0x1a43')]);}}function _0x7ce48d(_0x36eed1){const _0x436e2a=_0x375643;if(_0x36eed1){const _0x57a659=_0x2cfb05()[_0x436e2a('0xc38')](_0x2a5902[_0x436e2a('0x209e')]['rows'],{'id':_0x36eed1['id']});_0x57a659&&(_0x57a659[_0x436e2a('0x21c2')]=_0x36eed1['tags']||[],_0x2cfb05()[_0x436e2a('0xcc3')](_0x57a659,_0x2cfb05()['pick'](_0x36eed1,_0x2cfb05()[_0x436e2a('0x14a4')](_0x57a659))));}}function _0x5a7402(_0x1959b5){const _0x47cc1a=_0x375643;if(_0x1959b5&&!_0x1959b5['secret']){const _0x214ef0=_0x2cfb05()[_0x47cc1a('0xc38')](_0x2a5902[_0x47cc1a('0x209e')]['rows'],{'id':_0x1959b5[_0x47cc1a('0x2315')]});if(_0x214ef0){const _0x5bac0d=_0x2cfb05()[_0x47cc1a('0xc38')](_0x214ef0[_0x47cc1a('0x116c')],{'id':_0x1959b5['id']});_0x5bac0d?_0x2cfb05()['merge'](_0x5bac0d,_0x2cfb05()[_0x47cc1a('0x1a08')](_0x1959b5,_0x2cfb05()[_0x47cc1a('0x14a4')](_0x5bac0d))):(_0x2cfb05()[_0x47cc1a('0x2863')](_0x214ef0[_0x47cc1a('0x116c')])&&(_0x214ef0['Messages']={'count':0x0}),!_0x1959b5[_0x47cc1a('0x123')]&&(_0x214ef0['Messages']['count']+=0x1));}}}function _0x9986a1(){const _0x260683=_0x375643;_0x2a5902[_0x260683('0x7cc')]=![];}function _0x438ad5(){const _0x5df77a=_0x375643;_0x2a5902[_0x5df77a('0x7cc')]=!![];}function _0x14d04a(){const _0x30772a=_0x375643;_0x2a5902['isSearchBarVisible']=![],_0x39ea1e[_0x30772a('0x1f80')]({'controller':'AdvancedSearchController','controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0x30772a('0x1194')](_0x52b331[_0x30772a('0x8d2')]),'clickOutsideToClose':![],'locals':{'color':_0x2a5902['sectionColor'],'fields':_0x2a5902[_0x30772a('0x1291')][_0x30772a('0xfe2')],'storagePath':'home.chat'},'fullscreen':!![]})[_0x30772a('0x1166')](function(_0x370e79){const _0x4e1653=_0x30772a;_0x2a5902[_0x4e1653('0x2218')]['search']=_0x370e79===![]?undefined:_0x370e79;if(_0x2a5902[_0x4e1653('0x2218')]['search']||_0x370e79===![])_0x5947cf();})[_0x30772a('0x1a80')](function(_0x529e8d){const _0x1c5a6a=_0x30772a;_0x2ddfbd[_0x1c5a6a('0xfc9')]({'title':'ERROR','msg':_0x529e8d[_0x1c5a6a('0x25f4')]?JSON['stringify'](_0x529e8d['data']['message']):_0x529e8d[_0x1c5a6a('0x1586')]()});});}let _0x33dd8d=!![],_0x37ef1b=0x1;_0x550052['$watch'](_0x375643('0x12d8'),function(_0x5a9a8b,_0x4e573c){const _0x504365=_0x375643;_0x33dd8d?_0x4c7d06(function(){_0x33dd8d=![];}):(!_0x4e573c&&(_0x37ef1b=_0x2a5902['query'][_0x504365('0x1a43')]),_0x5a9a8b!==_0x4e573c&&(_0x2a5902['query']['page']=0x1),!_0x5a9a8b&&(_0x2a5902[_0x504365('0x2218')][_0x504365('0x1a43')]=_0x37ef1b),_0x5947cf(_0x2a5902[_0x504365('0x2218')][_0x504365('0x1a43')]));}),_0x550052['$on'](_0x375643('0x1c3f'),function(){const _0x53cd58=_0x375643;_0x5b2e8b[_0x53cd58('0x1800')](_0x53cd58('0x7fd')),_0x5b2e8b[_0x53cd58('0x1800')]('chatMessage:update'),_0x5b2e8b[_0x53cd58('0x1800')](_0x53cd58('0x2724')),_0x5b2e8b[_0x53cd58('0x1800')](_0x53cd58('0x105b')),_0x5b2e8b[_0x53cd58('0x1800')](_0x53cd58('0x2021')),_0x5b2e8b[_0x53cd58('0x1800')]('user_has_chat_interactions:save'),_0x5b2e8b[_0x53cd58('0x1800')](_0x53cd58('0x19c3'));});}const _0x2bb04f=_0x5b82c6;_0x352752[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1c90'),_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1566'),_0x36e6f4('0x21ef'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e')];function _0x352752(_0x300cb9,_0x24cac9,_0x57b5d8,_0x4cba51,_0x4d05b6,_0xffc17f,_0x9c34df,_0x5a1365){const _0x41453a=_0x36e6f4,_0x49a6df=this;_0x49a6df['currentUser']=_0xffc17f[_0x41453a('0x26cd')](),_0x49a6df['lists']={},_0x49a6df[_0x41453a('0xca8')]={'count':0x0,'rows':[]},_0x49a6df[_0x41453a('0xb38')]={'count':0x0,'rows':[]},_0x49a6df[_0x41453a('0x2218')]={'includeAll':!![],'sort':_0x41453a('0x14dc'),'limit':0xa,'page':0x1},_0x49a6df['advancedSearch']={'fields':[]},_0x49a6df[_0x41453a('0xb1f')]=_0x41453a('0x21e2'),_0x49a6df[_0x41453a('0x2738')]=_0x4f0245,_0x49a6df[_0x41453a('0x2587')]=_0x2756cf,_0x49a6df['mergeContact']=_0x3cc9df,_0x49a6df[_0x41453a('0x22de')]=_0x17cdb0,_0x49a6df['openContact']=_0x5795b4,_0x49a6df[_0x41453a('0x200f')]=_0x24cac9[_0x41453a('0x23ac')]['vm'][_0x41453a('0x200f')],_0x49a6df[_0x41453a('0xae0')]=_0x50e22f,_0x49a6df[_0x41453a('0x109e')]=_0x3109dd,_0x49a6df['onSearchBarExpand']=_0x496adc,_0x49a6df[_0x41453a('0x138b')]=_0x4d0245;function _0x50e22f(){const _0xfab917=_0x41453a;_0x9c34df['user']['getLists']({'id':_0x49a6df['currentUser']['id'],'fields':_0xfab917('0x27b'),'sort':_0xfab917('0x4f0'),'nolimit':!![]})[_0xfab917('0xa44')][_0xfab917('0x1166')](function(_0x2201a2){const _0x94d0ee=_0xfab917;return _0x49a6df[_0x94d0ee('0x8de')]=_0x2201a2||{'count':0x0,'rows':[]},_0x49a6df['listsMap']=_0x2cfb05()[_0x94d0ee('0x155c')](_0x49a6df['lists'][_0x94d0ee('0x269a')],'id'),_0x9c34df['tag']['get']()[_0x94d0ee('0xa44')];})[_0xfab917('0x1166')](function(_0x812954){_0x49a6df['tags']=_0x812954||{'count':0x0,'rows':[]};})[_0xfab917('0x1166')](function(){const _0xc1e65d=_0xfab917;_0x49a6df[_0xc1e65d('0x6cb')]=_0x2b0a34();})['catch'](function(_0x109bc7){console['error'](_0x109bc7);})[_0xfab917('0x1951')](function(){const _0x3a1638=_0xfab917;let _0x498872=_0x4d05b6[_0x3a1638('0x275')][_0x3a1638('0x15f7')]('motion2.home.contacts:'+_0x49a6df[_0x3a1638('0x98')]['id']);if(_0x498872)try{_0x498872=JSON[_0x3a1638('0x1295')](_0x498872);if(_0x498872['query']){_0x49a6df['query']=_0x2cfb05()[_0x3a1638('0xcc3')](_0x49a6df[_0x3a1638('0x2218')],_0x498872[_0x3a1638('0x2218')]);if(_0x2cfb05()['isEmpty'](_0x49a6df[_0x3a1638('0x8de')]['rows']))_0x49a6df['query']['ListId']=[];else _0x2cfb05()[_0x3a1638('0x1081')](_0x49a6df['query'][_0x3a1638('0x23c')])&&(_0x49a6df[_0x3a1638('0x2218')][_0x3a1638('0x23c')]=_0x2cfb05()(_0x49a6df['lists'][_0x3a1638('0x269a')])[_0x3a1638('0x2563')]('id')[_0x3a1638('0x23a2')]()[_0x3a1638('0x18e0')]());}}catch(_0x4488e2){console[_0x3a1638('0x455')](_0x4488e2);}else _0x49a6df[_0x3a1638('0x2218')][_0x3a1638('0x23c')]=_0x2cfb05()['map'](_0x49a6df[_0x3a1638('0x8de')][_0x3a1638('0x269a')],'id');_0x49a6df[_0x3a1638('0x7cc')]=_0x49a6df['query']['filter']?!![]:![],_0x4f0245();});}function _0x2b0a34(){const _0x5e2901=_0x41453a;return[{'name':'List','key':_0x5e2901('0x23c'),'type':_0x5e2901('0x2162'),'label':_0x5e2901('0x257a'),'options':_0x49a6df[_0x5e2901('0x8de')][_0x5e2901('0x269a')],'clearAll':![]},{'name':'Tag','key':_0x5e2901('0x1446'),'type':_0x5e2901('0x2162'),'label':_0x5e2901('0x1669'),'options':_0x49a6df['tags'][_0x5e2901('0x269a')],'placeholder':_0x5e2901('0x2223')}];}function _0x3496b4(_0x2ecce2){_0x49a6df['searchInProgress']=![],_0x49a6df['contacts']=_0x2ecce2||{'count':0x0,'rows':[]};}function _0x4f0245(_0x5b6bca){const _0x56e4e2=_0x41453a;_0x49a6df[_0x56e4e2('0x293')]=!![],_0x3e36b7();!_0x5b6bca&&(_0x49a6df[_0x56e4e2('0x2218')][_0x56e4e2('0x1a43')]=0x1);_0x49a6df[_0x56e4e2('0x2218')][_0x56e4e2('0x1098')]=(_0x49a6df[_0x56e4e2('0x2218')][_0x56e4e2('0x1a43')]-0x1)*_0x49a6df[_0x56e4e2('0x2218')][_0x56e4e2('0x163f')];let _0x2de238=_0x4d05b6['localStorage'][_0x56e4e2('0x15f7')](_0x56e4e2('0x2420')+_0x49a6df['currentUser']['id']);_0x2de238=_0x2de238?JSON['parse'](_0x2de238):{},_0x2de238[_0x56e4e2('0x2218')]=_0x49a6df[_0x56e4e2('0x2218')],_0x4d05b6[_0x56e4e2('0x275')]['setItem'](_0x56e4e2('0x2420')+_0x49a6df[_0x56e4e2('0x98')]['id'],JSON[_0x56e4e2('0xbac')](_0x2de238)),_0x49a6df[_0x56e4e2('0x1f48')]=_0x9c34df[_0x56e4e2('0x149e')][_0x56e4e2('0xd83')](_0x49a6df[_0x56e4e2('0x2218')],_0x3496b4)[_0x56e4e2('0xa44')];}function _0x5795b4(_0xc110a9){const _0x3c5cf=_0x41453a;return _0x9c34df['cmContact'][_0x3c5cf('0xd83')]({'id':_0xc110a9})[_0x3c5cf('0xa44')][_0x3c5cf('0x1166')](function(_0x3335ac){const _0x547434=_0x3c5cf;_0x24cac9[_0x547434('0x23ac')]['vm'][_0x547434('0x247b')](_0x3335ac);});}function _0x2756cf(){_0x4f0245();}function _0x17cdb0(_0x334687,_0x148bbc){const _0xd929ac=_0x41453a;_0x4cba51[_0xd929ac('0x1f80')]({'controller':'DuplicateContactDialogController','controllerAs':'vm','templateUrl':_0x5b62a4,'parent':angular[_0xd929ac('0x1194')](_0x300cb9[_0xd929ac('0x8d2')]),'targetEvent':_0x334687,'clickOutsideToClose':!![],'resolve':{'contact':[_0xd929ac('0x1fbc'),function(_0x3281d9){return _0x3281d9['resolve']('cmContact@get',{'id':_0x148bbc['id']});}],'lists':[_0xd929ac('0x1fbc'),function(_0x3dd66b){const _0x57c340=_0xd929ac;return _0x3dd66b[_0x57c340('0x18af')]('user@getLists',{'id':_0x49a6df[_0x57c340('0x98')]['id'],'fields':'id,name'});}]},'locals':{'contacts':_0x49a6df[_0xd929ac('0xca8')][_0xd929ac('0x269a')]}});}function _0x3cc9df(_0xcbe4ad,_0x55368a){const _0x23189d=_0x41453a;_0x4cba51[_0x23189d('0x1f80')]({'controller':_0x23189d('0xcd1'),'controllerAs':'vm','templateUrl':_0x18c924,'parent':angular['element'](_0x300cb9[_0x23189d('0x8d2')]),'targetEvent':_0xcbe4ad,'clickOutsideToClose':!![],'resolve':{'contact':[_0x23189d('0x1fbc'),function(_0x248729){const _0x3319f1=_0x23189d;return _0x248729[_0x3319f1('0x18af')]('cmContact@get',{'id':_0x55368a['id']});}],'lists':[_0x23189d('0x1fbc'),function(_0x46ebf4){const _0x292555=_0x23189d;return _0x46ebf4['resolve'](_0x292555('0x273f'),{'id':_0x49a6df[_0x292555('0x98')]['id'],'fields':_0x292555('0x1776')});}]},'locals':{'contacts':_0x49a6df['contacts']['rows']}});}function _0x3109dd(){const _0xaf83ce=_0x41453a;_0x49a6df[_0xaf83ce('0x7cc')]=![];}function _0x496adc(){const _0x5b0494=_0x41453a;_0x49a6df[_0x5b0494('0x7cc')]=!![];}function _0x3e36b7(){const _0x3119f3=_0x41453a;return _0x9c34df[_0x3119f3('0x149e')][_0x3119f3('0x23d0')]({'id':_0x49a6df[_0x3119f3('0x2218')][_0x3119f3('0x23c')]})[_0x3119f3('0xa44')][_0x3119f3('0x1166')](function(_0x318ddc){const _0x44199b=_0x3119f3;return _0x2cfb05()(_0x318ddc[_0x44199b('0x2876')]())['omit'](_0x44199b('0x122a'))[_0x44199b('0x1ac1')]()[_0x44199b('0x2563')](function(_0x336c77){return _0x4cb363(_0x336c77);})['value']();})[_0x3119f3('0x1166')](function(_0x1574b7){const _0x24f7cd=_0x3119f3;_0x49a6df[_0x24f7cd('0x1291')][_0x24f7cd('0xfe2')]=_0x1574b7;const _0xbdc8db={'name':_0x24f7cd('0x21c2'),'column':'Tag','type':'multiselect','options':{'route':{'model':_0x24f7cd('0x1446'),'action':_0x24f7cd('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':[_0x24f7cd('0x18d')]}};let _0x768d9a=_0x2cfb05()[_0x24f7cd('0xede')](_0x1574b7,function(_0x43745a){const _0xdd32de=_0x24f7cd;return _0x2cfb05()[_0xdd32de('0x1783')](_0x43745a['column'],_0xdd32de('0x711'));})||_0x1574b7[_0x24f7cd('0x264b')]-0x1;if(_0x768d9a<0x0)_0x768d9a=_0x1574b7[_0x24f7cd('0x264b')];_0x49a6df[_0x24f7cd('0x1291')][_0x24f7cd('0xfe2')][_0x24f7cd('0x57b')](_0x768d9a,0x0,_0xbdc8db);})['catch'](function(_0x55d559){const _0x38914b=_0x3119f3;_0x5a1365[_0x38914b('0xfc9')]({'title':_0x55d559['status']?'API:'+_0x55d559['status']+_0x38914b('0x11e1')+_0x55d559[_0x38914b('0xe1b')]:_0x38914b('0x7'),'msg':_0x55d559[_0x38914b('0x25f4')]?JSON[_0x38914b('0xbac')](_0x55d559[_0x38914b('0x25f4')]['message']):_0x55d559['toString']()});});}function _0x4cb363(_0x3e9dcd){const _0x504d8d=_0x41453a,_0x222227={'name':_0x2cfb05()['startCase'](_0x3e9dcd['displayName']),'column':_0x3e9dcd[_0x504d8d('0x24b3')],'options':{}};if(_0x3e9dcd[_0x504d8d('0x2853')])switch(_0x3e9dcd[_0x504d8d('0x2853')][_0x504d8d('0x1345')]){case _0x504d8d('0x1640'):_0x222227['type']=_0x504d8d('0x1640');break;case _0x504d8d('0x88a'):_0x222227[_0x504d8d('0x1345')]=_0x504d8d('0x2162'),_0x222227['values']=_0x2cfb05()['map'](JSON[_0x504d8d('0x1295')](_0x3e9dcd['custom']['values']),function(_0xe83282,_0x216762){const _0x53e69e=_0x504d8d;return{'id':_0x216762,'name':_0xe83282['value'],'value':_0xe83282[_0x53e69e('0x18e0')]};}),_0x222227[_0x504d8d('0xd39')][_0x504d8d('0x22f3')]=_0x504d8d('0x4f0');break;case'switch':_0x222227[_0x504d8d('0x1345')]=_0x504d8d('0x88a'),_0x222227[_0x504d8d('0x1ac1')]=[{'id':0x1,'translate':'DASHBOARDS.ENABLED'},{'id':0x0,'translate':_0x504d8d('0x2190')}],_0x222227[_0x504d8d('0xd39')]['excludedOperators']=[_0x504d8d('0x2646')];break;case _0x504d8d('0xc45'):_0x222227[_0x504d8d('0x1345')]=_0x504d8d('0xc45');break;case _0x504d8d('0x7db'):_0x222227[_0x504d8d('0x1345')]=_0x504d8d('0x1643');break;}else switch(_0x3e9dcd[_0x504d8d('0x24b3')]){case _0x504d8d('0x17a0'):_0x222227[_0x504d8d('0x1345')]=_0x504d8d('0x1643');break;case _0x504d8d('0x537'):_0x222227[_0x504d8d('0x4f0')]=_0x504d8d('0xb82'),_0x222227[_0x504d8d('0x1345')]=_0x504d8d('0x1a01'),_0x222227[_0x504d8d('0xd39')][_0x504d8d('0x16a8')]={'model':_0x504d8d('0xc39'),'action':'get','params':{'fields':_0x504d8d('0x1776'),'nolimit':!![]}},_0x222227[_0x504d8d('0xd39')][_0x504d8d('0x4d2')]=[_0x504d8d('0x4f0')],_0x222227[_0x504d8d('0xd39')][_0x504d8d('0x6f5')]=[_0x504d8d('0x2646')];break;case _0x504d8d('0x23c'):_0x222227[_0x504d8d('0x4f0')]='List',_0x222227[_0x504d8d('0x1345')]=_0x504d8d('0x1a01'),_0x222227[_0x504d8d('0xd39')]['route']={'model':_0x504d8d('0x557'),'action':_0x504d8d('0x5a1'),'params':{'id':_0x49a6df[_0x504d8d('0x98')]['id'],'fields':_0x504d8d('0x1776'),'nolimit':!![]}},_0x222227[_0x504d8d('0xd39')]['searchFields']=[_0x504d8d('0x4f0')],_0x222227[_0x504d8d('0xd39')][_0x504d8d('0x6f5')]=['$ne'];break;default:if(_0x2cfb05()[_0x504d8d('0x1257')](_0x3e9dcd['type']['toLowerCase'](),_0x504d8d('0x15eb')))_0x222227['type']=_0x504d8d('0xc45');else _0x2cfb05()[_0x504d8d('0x1257')](_0x3e9dcd['type'][_0x504d8d('0x2574')](),_0x504d8d('0x1643'))?_0x222227[_0x504d8d('0x1345')]='date':_0x222227[_0x504d8d('0x1345')]='text';break;}return _0x222227;}function _0x4d0245(){const _0xfa3c31=_0x41453a;_0x49a6df['isSearchBarVisible']=![],_0x4cba51[_0xfa3c31('0x1f80')]({'controller':'AdvancedSearchController','controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0xfa3c31('0x1194')](_0x300cb9[_0xfa3c31('0x8d2')]),'clickOutsideToClose':![],'locals':{'color':_0x49a6df['sectionColor'],'fields':_0x49a6df[_0xfa3c31('0x1291')][_0xfa3c31('0xfe2')],'storagePath':_0xfa3c31('0x141')},'fullscreen':!![]})[_0xfa3c31('0x1166')](function(_0x39b4b5){const _0x323a60=_0xfa3c31;_0x49a6df[_0x323a60('0x2218')]['search']=_0x39b4b5===![]?undefined:_0x39b4b5;if(_0x49a6df[_0x323a60('0x2218')][_0x323a60('0xe07')]||_0x39b4b5===![])_0x4f0245();})[_0xfa3c31('0x1a80')](function(_0x3ff112){const _0x2cb8b3=_0xfa3c31;_0x5a1365[_0x2cb8b3('0xfc9')]({'title':'ERROR','msg':_0x3ff112[_0x2cb8b3('0x25f4')]?JSON[_0x2cb8b3('0xbac')](_0x3ff112[_0x2cb8b3('0x25f4')][_0x2cb8b3('0x1e70')]):_0x3ff112[_0x2cb8b3('0x1586')]()});});}let _0x300687=!![],_0x43f766=0x1;_0x24cac9['$watch']('vm.query.filter',function(_0x5a3ffc,_0x12549a){const _0x46e4bb=_0x41453a;_0x300687?_0x57b5d8(function(){_0x300687=![];}):(!_0x12549a&&(_0x43f766=_0x49a6df['query']['page']),_0x5a3ffc!==_0x12549a&&(_0x49a6df[_0x46e4bb('0x2218')][_0x46e4bb('0x1a43')]=0x1),!_0x5a3ffc&&(_0x49a6df[_0x46e4bb('0x2218')]['page']=_0x43f766),_0x4f0245());});}const _0x244443=_0x352752;_0x1ed2ec[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x10eb')];function _0x1ed2ec(_0x14e814,_0x472bcf){const _0x26a4c1=_0x36e6f4;let _0x1de253=_0x472bcf(function(){},0x3e7);_0x14e814[_0x26a4c1('0x3d2')](_0x26a4c1('0x1c3f'),function(){_0x1de253&&(_0x472bcf['cancel'](_0x1de253),_0x1de253=null);});}const _0x2d5616=_0x1ed2ec;_0x1d9cb2['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1566'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x2661')];function _0x1d9cb2(_0x57ad3c,_0x26a416,_0x278b62,_0x49f3dd,_0x1cf41d,_0x2126e8,_0x1f6ee3,_0xe052f5,_0x2f8bfe){const _0x5e0879=_0x36e6f4,_0x136b8d=this,_0x119ff=[_0x5e0879('0x1345'),_0x5e0879('0x288a'),'dialMethod','dialActive'];_0x136b8d['voiceQueues']={},_0x136b8d[_0x5e0879('0x193f')]=0x0,_0x136b8d[_0x5e0879('0x1245')]={},_0x136b8d[_0x5e0879('0x680')]={},_0x136b8d[_0x5e0879('0x2177')]={},_0x136b8d[_0x5e0879('0x200b')]={},_0x136b8d['deleteVoiceQueuesChannels']=[],_0x136b8d[_0x5e0879('0x173f')]=!![],_0x136b8d[_0x5e0879('0x2218')]={'id':_0xe052f5['getCurrentUser']()['id'],'fields':'id,name,type,dialMethod,dialActive','channel':'voice','type':'outbound','limit':0xa,'page':0x1},_0x136b8d[_0x5e0879('0x1c05')]={'limit':0xa,'page':0x1},_0x136b8d['success']=_0x130c28,_0x136b8d[_0x5e0879('0x680')]=_0x2e209b,_0x136b8d[_0x5e0879('0x1c4d')]=_0x4dcd71,_0x136b8d[_0x5e0879('0xefb')]=_0x213990,_0x136b8d[_0x5e0879('0xf77')]=_0x2390a3,_0x136b8d['onUserVoiceQueue']=_0x46671c,_0x136b8d[_0x5e0879('0x1ff4')]=_0x2001b7,_0x136b8d[_0x5e0879('0x1e8e')]=_0x5c51dd,_0x136b8d[_0x5e0879('0x1b68')]=_0x8813f,_0x2f8bfe['onWithoutApply'](_0x5e0879('0xa60'),_0x136b8d[_0x5e0879('0xefb')]),_0x2f8bfe[_0x5e0879('0xe82')](_0x5e0879('0x196a'),_0x136b8d[_0x5e0879('0xf77')]),_0x2f8bfe['onWithoutApply']('userVoiceQueue:save',_0x136b8d[_0x5e0879('0x23da')]),_0x2f8bfe[_0x5e0879('0xe82')](_0x5e0879('0x25f0'),_0x136b8d['onUserVoiceQueue']),_0x2f8bfe[_0x5e0879('0xe82')](_0x5e0879('0x235a'),_0x136b8d[_0x5e0879('0x1ff4')]),_0x2f8bfe['onWithoutApply'](_0x5e0879('0xfda'),_0x136b8d[_0x5e0879('0x1b68')]),_0x2f8bfe[_0x5e0879('0xe82')](_0x5e0879('0x272d'),_0x136b8d[_0x5e0879('0x1e8e')]),_0x1f6ee3[_0x5e0879('0x13fa')][_0x5e0879('0x680')]()[_0x5e0879('0xa44')][_0x5e0879('0x1166')](function(_0x623a29){const _0x30411b=_0x5e0879;return _0x136b8d[_0x30411b('0x1245')]=_0x623a29?_0x2cfb05()[_0x30411b('0x155c')](_0x623a29[_0x30411b('0x269a')]?_0x623a29[_0x30411b('0x269a')]:[],'id'):{},_0x1f6ee3[_0x30411b('0x13fa')][_0x30411b('0x1fd4')]()[_0x30411b('0xa44')];})[_0x5e0879('0x1166')](function(_0x5471cc){const _0x5e1c17=_0x5e0879;_0x136b8d[_0x5e1c17('0x2177')]=_0x5471cc?_0x2cfb05()[_0x5e1c17('0x155c')](_0x5471cc[_0x5e1c17('0x269a')]?_0x2cfb05()[_0x5e1c17('0x1c33')](_0x5471cc[_0x5e1c17('0x269a')],{'type':_0x5e1c17('0x587'),'queuecallerleaveAt':null}):[],_0x5e1c17('0x1c21')):{};})['catch'](function(_0x437818){const _0x230ab2=_0x5e0879;console[_0x230ab2('0xfc9')](_0x437818);})[_0x5e0879('0x1951')](function(){const _0x367e87=_0x5e0879;_0x2cfb05()['merge'](_0x136b8d['rpcVoiceQueuesChannels'],_0x136b8d[_0x367e87('0x200b')]);for(let _0x449e74=0x0;_0x449e74<_0x136b8d[_0x367e87('0x157f')]['length'];_0x449e74+=0x1){delete _0x136b8d[_0x367e87('0x2177')][_0x136b8d[_0x367e87('0x157f')][_0x449e74]];}_0x136b8d['load']=![],_0x136b8d['addVoiceQueuesChannels']={},_0x136b8d[_0x367e87('0x157f')]=[],_0x136b8d[_0x367e87('0x680')]();});function _0x130c28(_0x3dc564){const _0x29d400=_0x5e0879;_0x136b8d[_0x29d400('0x193f')]=_0x3dc564[_0x29d400('0x240f')]?_0x3dc564['count']:0x0,_0x136b8d[_0x29d400('0x20fd')]=_0x3dc564?_0x2cfb05()[_0x29d400('0x155c')](_0x3dc564[_0x29d400('0x269a')]?_0x3dc564[_0x29d400('0x269a')]:[],'id'):{},_0x413696();}function _0x2e209b(){const _0xa9da49=_0x5e0879;_0x136b8d[_0xa9da49('0x2218')][_0xa9da49('0x1098')]=(_0x136b8d['query'][_0xa9da49('0x1a43')]-0x1)*_0x136b8d[_0xa9da49('0x2218')]['limit'],_0x136b8d[_0xa9da49('0x1f48')]=_0x1f6ee3[_0xa9da49('0x557')][_0xa9da49('0x152a')](_0x136b8d[_0xa9da49('0x2218')],_0x130c28)[_0xa9da49('0xa44')];}let _0x2dc3ed=!![],_0x4ddd29=0x1;_0x57ad3c[_0x5e0879('0xe83')](_0x5e0879('0x28b4'),function(_0x2d60fa,_0x51d741){const _0x32bc2=_0x5e0879;_0x2dc3ed?_0x26a416(function(){_0x2dc3ed=![];}):(!_0x51d741&&(_0x4ddd29=_0x136b8d[_0x32bc2('0x2218')][_0x32bc2('0x1a43')]),_0x2d60fa!==_0x51d741&&(_0x136b8d[_0x32bc2('0x2218')][_0x32bc2('0x1a43')]=0x1),!_0x2d60fa&&(_0x136b8d['query']['page']=_0x4ddd29),_0x136b8d[_0x32bc2('0x680')]());});function _0x4dcd71(_0x5f555e){return _0x2cfb05()['size'](_0x5f555e);}function _0x413696(){const _0x42ff2c=_0x5e0879;_0x2cfb05()['forIn'](_0x136b8d[_0x42ff2c('0x20fd')],function(_0x572dea,_0x1a8247){const _0x3f5754=_0x42ff2c;_0x136b8d['rpcVoiceQueues'][_0x1a8247]&&(_0x136b8d[_0x3f5754('0x20fd')][_0x1a8247][_0x3f5754('0x288a')]=_0x136b8d[_0x3f5754('0x1245')][_0x1a8247][_0x3f5754('0x288a')]||0x0);});}function _0x213990(_0x1e57e8){const _0x4ff2f7=_0x5e0879;_0x136b8d['voiceQueues'][_0x1e57e8['id']]&&(_0x136b8d[_0x4ff2f7('0x1245')][_0x1e57e8['id']]&&(_0x136b8d['rpcVoiceQueues'][_0x1e57e8['id']]=_0x1e57e8,_0x2cfb05()[_0x4ff2f7('0xcc3')](_0x136b8d[_0x4ff2f7('0x20fd')][_0x1e57e8['id']],_0x2cfb05()['pick'](_0x1e57e8,_0x119ff))));}function _0x2390a3(_0x23d523){const _0x45696e=_0x5e0879;_0x23d523[_0x45696e('0x1345')]===_0x45696e('0x587')&&(_0x23d523[_0x45696e('0x9de')]?(delete _0x136b8d['rpcVoiceQueuesChannels'][_0x23d523[_0x45696e('0x1c21')]],_0x136b8d[_0x45696e('0x173f')]&&_0x136b8d['deleteVoiceQueuesChannels'][_0x45696e('0x1514')](_0x23d523[_0x45696e('0x1c21')])):(_0x136b8d[_0x45696e('0x2177')][_0x23d523[_0x45696e('0x1c21')]]=_0x23d523,_0x136b8d[_0x45696e('0x173f')]&&(_0x136b8d[_0x45696e('0x200b')][_0x23d523[_0x45696e('0x1c21')]]=_0x23d523)));}function _0x2001b7(_0x4e4e9c){const _0x150929=_0x5e0879;!_0x2cfb05()[_0x150929('0x2863')](_0x4e4e9c)&&(_0x136b8d[_0x150929('0x1245')][_0x4e4e9c['id']]=_0x2cfb05()[_0x150929('0x1a08')](_0x4e4e9c,_0x119ff));}function _0x5c51dd(_0x4cf3be){const _0x142111=_0x5e0879;!_0x2cfb05()[_0x142111('0x2863')](_0x4cf3be)&&(_0x136b8d['rpcVoiceQueues'][_0x4cf3be['id']]&&_0x2cfb05()[_0x142111('0xcc3')](_0x136b8d[_0x142111('0x1245')][_0x4cf3be['id']],_0x2cfb05()[_0x142111('0x1a08')](_0x4cf3be,_0x119ff)),_0x136b8d[_0x142111('0x20fd')][_0x4cf3be['id']]&&_0x2cfb05()['merge'](_0x136b8d['voiceQueues'][_0x4cf3be['id']],_0x2cfb05()[_0x142111('0x1a08')](_0x4cf3be,_0x119ff)));}function _0x8813f(_0x5541ea){const _0xbf647c=_0x5e0879;!_0x2cfb05()[_0xbf647c('0x2863')](_0x5541ea)&&(delete _0x136b8d[_0xbf647c('0x1245')][_0x5541ea['id']],delete _0x136b8d['voiceQueues'][_0x5541ea['id']]);}function _0x46671c(_0x19e47f){const _0x54afe2=_0x5e0879;_0x2cfb05()['toInteger'](_0x19e47f[_0x54afe2('0x122a')])===_0xe052f5[_0x54afe2('0x26cd')]()['id']&&_0x136b8d[_0x54afe2('0x680')]();}_0x57ad3c[_0x5e0879('0x3d2')](_0x5e0879('0x1c3f'),function(){const _0x2d37be=_0x5e0879;_0x2f8bfe['removeAllListeners'](_0x2d37be('0xa60')),_0x2f8bfe['removeAllListeners']('voice_queue_channel:save'),_0x2f8bfe['removeAllListeners'](_0x2d37be('0x663')),_0x2f8bfe['removeAllListeners'](_0x2d37be('0x25f0')),_0x2f8bfe[_0x2d37be('0x1800')](_0x2d37be('0x235a')),_0x2f8bfe['removeAllListeners'](_0x2d37be('0x272d')),_0x2f8bfe['removeAllListeners']('voiceQueue:remove');});}const _0x2771d0=_0x1d9cb2;_0x3ca506[_0x36e6f4('0x1294')]=['$scope','$timeout','$mdDialog','$document',_0x36e6f4('0x1566'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x2661')];function _0x3ca506(_0x451902,_0x4bfc99,_0x1cbdde,_0x27a245,_0x407e39,_0x1fe28f,_0xbfd67f,_0x22025a,_0x3417a6){const _0x3099da=_0x36e6f4,_0x953967=this,_0x472317=['id',_0x3099da('0x4f0'),_0x3099da('0x227a'),_0x3099da('0x288a')];let _0x1724e5=!![];_0x953967[_0x3099da('0x3a1')]={},_0x953967[_0x3099da('0x6cf')]=0x0,_0x953967['rpcChatQueues']={},_0x953967[_0x3099da('0x1fd8')]=[],_0x953967[_0x3099da('0x1f65')]=[],_0x953967['rpcChatQueuesWaitingInteractions']={},_0x953967[_0x3099da('0x2218')]={'id':_0x22025a['getCurrentUser']()['id'],'channel':_0x3099da('0xde2'),'fields':_0x3099da('0x28cc'),'limit':0xa,'page':0x1},_0x953967['queryChannels']={'limit':0xa,'page':0x1},_0x953967[_0x3099da('0x103b')]=_0x15acda,_0x953967[_0x3099da('0x2832')]=_0x208965,_0x953967[_0x3099da('0x1c4d')]=_0x21794a,_0x953967[_0x3099da('0x12bb')]=_0x31cd2b,_0x953967[_0x3099da('0x2654')]=_0x288fc6,_0x953967[_0x3099da('0xefb')]=_0x3290c7,_0x953967[_0x3099da('0x758')]=_0x4b4c11,_0x953967['onUpdateChatQueue']=_0x10c1f3,_0x953967[_0x3099da('0x989')]=_0x45958b,_0x953967['onSaveUserChatQueue']=_0x4d9015,_0x953967[_0x3099da('0xf63')]=_0x587455,_0x953967['onSaveChatQueueChannel']=_0x521422,_0x953967[_0x3099da('0x1f72')]=_0x50ffbc,_0x3417a6[_0x3099da('0xe82')](_0x3099da('0x612'),_0x953967[_0x3099da('0xefb')]),_0x3417a6['onWithoutApply'](_0x3099da('0xf70'),_0x953967[_0x3099da('0x758')]),_0x3417a6[_0x3099da('0xe82')](_0x3099da('0x1cfe'),_0x953967[_0x3099da('0x6fa')]),_0x3417a6[_0x3099da('0xe82')]('chatQueue:remove',_0x953967['onRemoveChatQueue']),_0x3417a6[_0x3099da('0xe82')](_0x3099da('0x268e'),_0x953967[_0x3099da('0xcb0')]),_0x3417a6[_0x3099da('0xe82')]('userChatQueue:remove',_0x953967[_0x3099da('0xf63')]),_0x3417a6[_0x3099da('0xe82')](_0x3099da('0x19d4'),_0x953967[_0x3099da('0xeac')]),_0x3417a6[_0x3099da('0xe82')](_0x3099da('0xb5b'),_0x953967[_0x3099da('0x1f72')]),_0xbfd67f[_0x3099da('0x13fa')][_0x3099da('0x2832')]()[_0x3099da('0xa44')][_0x3099da('0x1166')](function(_0x34bcb4){const _0x1579c6=_0x3099da;_0x953967[_0x1579c6('0x22ed')]=_0x34bcb4?_0x2cfb05()[_0x1579c6('0x155c')](_0x34bcb4['rows']?_0x34bcb4['rows']:[],'id'):{};})[_0x3099da('0x1166')](function(){const _0xb9143c=_0x3099da;return _0xbfd67f['user']['getQueues']({'id':_0x22025a['getCurrentUser']()['id'],'channel':_0xb9143c('0xde2')})[_0xb9143c('0xa44')];})['then'](function(_0x3c53ac){const _0x127232=_0x3099da;return _0x953967[_0x127232('0x12b1')]=_0x3c53ac[_0x127232('0x269a')],_0xbfd67f[_0x127232('0x13fa')]['getChatQueuesWaitingInteractions']()['$promise'];})[_0x3099da('0x1166')](function(_0x3dc870){const _0x282a32=_0x3099da,_0xd5fd35=_0x2cfb05()['filter'](_0x3dc870[_0x282a32('0x269a')],function(_0x43eeae){const _0x487da6=_0x282a32;return _0x2cfb05()[_0x487da6('0x1257')](_0x953967[_0x487da6('0x12b1')],{'id':_0x43eeae[_0x487da6('0x1e04')]});});_0x3dc870[_0x282a32('0x269a')]=_0xd5fd35,_0x3dc870[_0x282a32('0x240f')]=_0xd5fd35[_0x282a32('0x264b')],_0x2cfb05()[_0x282a32('0xcc3')](_0x953967['rpcChatQueuesWaitingInteractions'],_0x3dc870?_0x2cfb05()['keyBy'](_0x3dc870[_0x282a32('0x269a')]?_0x3dc870[_0x282a32('0x269a')]:[],'id'):{});})[_0x3099da('0x1a80')](function(_0x54bff8){console['error'](_0x54bff8);})['finally'](function(){const _0x462682=_0x3099da;for(let _0x23c170=0x0;_0x23c170<_0x953967[_0x462682('0x1f65')][_0x462682('0x264b')];_0x23c170+=0x1){delete _0x953967['rpcChatQueuesWaitingInteractions'][_0x953967[_0x462682('0x1f65')][_0x23c170]];}_0x1724e5=![],_0x953967[_0x462682('0x1f65')]=[],_0x208965(),_0x288fc6();});function _0x288fc6(){const _0x1b6f19=_0x3099da,_0x46ac27=(_0x953967[_0x1b6f19('0x1c05')][_0x1b6f19('0x1a43')]-0x1)*_0x953967[_0x1b6f19('0x1c05')][_0x1b6f19('0x163f')];_0x953967[_0x1b6f19('0x1fd8')]=_0x2cfb05()['orderBy'](_0x953967[_0x1b6f19('0x1527')],[_0x1b6f19('0x3eb')],[_0x1b6f19('0x1dc3')]),_0x953967['interactions']=_0x2cfb05()[_0x1b6f19('0x3e5')](_0x953967[_0x1b6f19('0x1fd8')],_0x46ac27)['slice'](0x0,_0x953967[_0x1b6f19('0x1c05')][_0x1b6f19('0x163f')]);}function _0x15acda(_0x4ba330){const _0x2d53cb=_0x3099da;_0x953967['chatQueuesTotal']=_0x4ba330['count']?_0x4ba330[_0x2d53cb('0x240f')]:0x0,_0x953967[_0x2d53cb('0x3a1')]=_0x4ba330?_0x2cfb05()[_0x2d53cb('0x155c')](_0x4ba330['rows']?_0x4ba330[_0x2d53cb('0x269a')]:[],'id'):{},_0x4a24e7();}function _0x208965(){const _0x1e7eb8=_0x3099da;_0x953967[_0x1e7eb8('0x2218')][_0x1e7eb8('0x1098')]=(_0x953967[_0x1e7eb8('0x2218')]['page']-0x1)*_0x953967[_0x1e7eb8('0x2218')][_0x1e7eb8('0x163f')],_0x953967[_0x1e7eb8('0x1f48')]=_0xbfd67f['user']['getQueues'](_0x953967['query'],_0x15acda)[_0x1e7eb8('0xa44')];}let _0x405d61=!![],_0x137362=0x1;_0x451902['$watch'](_0x3099da('0x28b4'),function(_0x47f94d,_0x5251b4){const _0x10af60=_0x3099da;_0x405d61?_0x4bfc99(function(){_0x405d61=![];}):(!_0x5251b4&&(_0x137362=_0x953967[_0x10af60('0x2218')][_0x10af60('0x1a43')]),_0x47f94d!==_0x5251b4&&(_0x953967['query'][_0x10af60('0x1a43')]=0x1),!_0x47f94d&&(_0x953967['query'][_0x10af60('0x1a43')]=_0x137362),_0x953967[_0x10af60('0x2832')]());});function _0x21794a(_0xe87ec6){const _0x3bec0e=_0x3099da;return _0x2cfb05()[_0x3bec0e('0x2340')](_0xe87ec6);}function _0x4a24e7(){const _0x26e134=_0x3099da;_0x2cfb05()[_0x26e134('0x941')](_0x953967[_0x26e134('0x3a1')],function(_0x2d3020,_0x38cc7a){const _0xb010f6=_0x26e134;_0x953967[_0xb010f6('0x22ed')][_0x38cc7a]&&(_0x953967[_0xb010f6('0x3a1')][_0x38cc7a]['waiting']=_0x953967[_0xb010f6('0x22ed')][_0x38cc7a][_0xb010f6('0x288a')]||0x0);});}function _0x3290c7(_0x5e4815){const _0xb7ff88=_0x3099da;_0x953967[_0xb7ff88('0x3a1')][_0x5e4815['id']]&&(_0x953967['rpcChatQueues'][_0x5e4815['id']]&&(_0x2cfb05()['merge'](_0x953967['rpcChatQueues'][_0x5e4815['id']],_0x2cfb05()[_0xb7ff88('0x1a08')](_0x5e4815,_0x472317)),_0x2cfb05()['merge'](_0x953967[_0xb7ff88('0x3a1')][_0x5e4815['id']],_0x2cfb05()[_0xb7ff88('0x1a08')](_0x5e4815,_0x472317))));}function _0x4b4c11(_0x5d7fa4){const _0x310e9a=_0x3099da;!_0x2cfb05()[_0x310e9a('0x2863')](_0x5d7fa4)&&(_0x953967[_0x310e9a('0x22ed')][_0x5d7fa4['id']]=_0x2cfb05()[_0x310e9a('0x1a08')](_0x5d7fa4,_0x472317));}function _0x10c1f3(_0x420033){const _0x5196eb=_0x3099da;!_0x2cfb05()[_0x5196eb('0x2863')](_0x420033)&&(_0x953967[_0x5196eb('0x22ed')][_0x420033['id']]&&_0x2cfb05()['merge'](_0x953967[_0x5196eb('0x22ed')][_0x420033['id']],_0x2cfb05()['pick'](_0x420033,_0x472317)),_0x953967[_0x5196eb('0x3a1')][_0x420033['id']]&&_0x2cfb05()[_0x5196eb('0xcc3')](_0x953967[_0x5196eb('0x3a1')][_0x420033['id']],_0x2cfb05()[_0x5196eb('0x1a08')](_0x420033,_0x472317)));}function _0x45958b(_0x1d26f0){const _0x542cef=_0x3099da;!_0x2cfb05()[_0x542cef('0x2863')](_0x1d26f0)&&(delete _0x953967['rpcChatQueues'][_0x1d26f0['id']],delete _0x953967[_0x542cef('0x3a1')][_0x1d26f0['id']]);}function _0x4d9015(_0x79e6f0){const _0x51474a=_0x3099da;_0x2cfb05()['toInteger'](_0x79e6f0[_0x51474a('0x122a')])===_0x22025a[_0x51474a('0x26cd')]()['id']&&_0x953967[_0x51474a('0x2832')]();}function _0x587455(_0x2c8a81){const _0x49d175=_0x3099da;_0x2cfb05()[_0x49d175('0x1edd')](_0x2c8a81[_0x49d175('0x122a')])===_0x22025a[_0x49d175('0x26cd')]()['id']&&_0x953967['getChatQueues']();}function _0x521422(_0x4b2225){const _0x25bade=_0x3099da;_0x953967['chatQueues'][_0x4b2225[_0x25bade('0x1e04')]]&&(_0x953967[_0x25bade('0x1527')][_0x4b2225['id']]=_0x4b2225,_0x288fc6());}function _0x50ffbc(_0x284401){const _0x2026bd=_0x3099da;delete _0x953967['rpcChatQueuesWaitingInteractions'][_0x284401['id']],_0x1724e5&&_0x953967[_0x2026bd('0x1f65')]['push'](_0x284401['id']),_0x288fc6();}function _0x31cd2b(_0x52d67d){const _0xfd64bb=_0x3099da;switch(_0x52d67d){case _0xfd64bb('0xde2'):return _0xfd64bb('0x2027');case _0xfd64bb('0x1bfa'):return _0xfd64bb('0x8aa');case _0xfd64bb('0x146c'):return _0xfd64bb('0x78a');case'whatsapp':return _0xfd64bb('0x2673');case'openchannel':return _0xfd64bb('0x467');case _0xfd64bb('0x1fc7'):return _0xfd64bb('0xc56');default:return _0xfd64bb('0xa10');}}_0x451902[_0x3099da('0x3d2')](_0x3099da('0x1c3f'),function(){const _0x2a505a=_0x3099da;_0x3417a6['removeAllListeners'](_0x2a505a('0x612')),_0x3417a6[_0x2a505a('0x1800')](_0x2a505a('0xf70')),_0x3417a6[_0x2a505a('0x1800')](_0x2a505a('0x1cfe')),_0x3417a6[_0x2a505a('0x1800')](_0x2a505a('0xc96')),_0x3417a6[_0x2a505a('0x1800')](_0x2a505a('0x268e')),_0x3417a6[_0x2a505a('0x1800')](_0x2a505a('0x28fa')),_0x3417a6[_0x2a505a('0x1800')](_0x2a505a('0x19d4')),_0x3417a6[_0x2a505a('0x1800')](_0x2a505a('0xb5b'));});}const _0x2ed108=_0x3ca506;_0x2fe3e9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1566'),'$translate','api',_0x36e6f4('0x21ef'),'socket'];function _0x2fe3e9(_0x2fd3d6,_0x10cd6f,_0x4fd016,_0x33a1d8,_0x98d45c,_0x4e1ab9,_0x2f87d1,_0x490d1d,_0x256654){const _0xa37700=_0x36e6f4,_0x226f28=this,_0x503bf0=['id',_0xa37700('0x4f0'),_0xa37700('0x227a'),_0xa37700('0x288a')];let _0x1fc2b9=!![];_0x226f28['faxQueues']={},_0x226f28[_0xa37700('0x1603')]=0x0,_0x226f28[_0xa37700('0xf8d')]={},_0x226f28[_0xa37700('0x1fd8')]=[],_0x226f28[_0xa37700('0x434')]=[],_0x226f28['rpcFaxQueuesWaitingInteractions']={},_0x226f28['query']={'id':_0x490d1d['getCurrentUser']()['id'],'channel':_0xa37700('0x1fc7'),'fields':_0xa37700('0x28cc'),'limit':0xa,'page':0x1},_0x226f28[_0xa37700('0x1c05')]={'limit':0xa,'page':0x1},_0x226f28['success']=_0x4b3f66,_0x226f28[_0xa37700('0x7a')]=_0x7a059b,_0x226f28[_0xa37700('0x1c4d')]=_0x4303bd,_0x226f28[_0xa37700('0x12bb')]=_0x34ba88,_0x226f28[_0xa37700('0x2654')]=_0x497945,_0x226f28['onSaveQueue']=_0x2dc823,_0x226f28[_0xa37700('0xfef')]=_0x481786,_0x226f28[_0xa37700('0x1ec8')]=_0x51c055,_0x226f28[_0xa37700('0x1bec')]=_0x344fe7,_0x226f28[_0xa37700('0x1d38')]=_0x4895c2,_0x226f28[_0xa37700('0x5bf')]=_0x2157d1,_0x226f28['onSaveFaxQueueChannel']=_0x7434c,_0x226f28[_0xa37700('0x1503')]=_0x5cd6b5,_0x256654[_0xa37700('0xe82')](_0xa37700('0x2241'),_0x226f28[_0xa37700('0xefb')]),_0x256654['onWithoutApply'](_0xa37700('0x52f'),_0x226f28[_0xa37700('0xfef')]),_0x256654[_0xa37700('0xe82')]('faxQueue:update',_0x226f28['onUpdateFaxQueue']),_0x256654[_0xa37700('0xe82')](_0xa37700('0x1efe'),_0x226f28[_0xa37700('0x1bec')]),_0x256654[_0xa37700('0xe82')](_0xa37700('0x169d'),_0x226f28[_0xa37700('0x1d38')]),_0x256654[_0xa37700('0xe82')](_0xa37700('0x268b'),_0x226f28[_0xa37700('0x5bf')]),_0x256654['onWithoutApply'](_0xa37700('0x24aa'),_0x226f28[_0xa37700('0x2d2')]),_0x256654[_0xa37700('0xe82')](_0xa37700('0x1b00'),_0x226f28['onRemoveFaxQueueChannel']),_0x2f87d1[_0xa37700('0x13fa')][_0xa37700('0x7a')]()[_0xa37700('0xa44')]['then'](function(_0x158e73){const _0x5f30f5=_0xa37700;_0x226f28[_0x5f30f5('0xf8d')]=_0x158e73?_0x2cfb05()[_0x5f30f5('0x155c')](_0x158e73[_0x5f30f5('0x269a')]?_0x158e73[_0x5f30f5('0x269a')]:[],'id'):{};})['then'](function(){const _0x3ddb47=_0xa37700;return _0x2f87d1[_0x3ddb47('0x557')][_0x3ddb47('0x152a')]({'id':_0x490d1d['getCurrentUser']()['id'],'channel':_0x3ddb47('0x1fc7')})[_0x3ddb47('0xa44')];})['then'](function(_0x2b39d5){const _0x4a5951=_0xa37700;return _0x226f28[_0x4a5951('0x12b1')]=_0x2b39d5[_0x4a5951('0x269a')],_0x2f87d1[_0x4a5951('0x13fa')][_0x4a5951('0x67')]()[_0x4a5951('0xa44')];})[_0xa37700('0x1166')](function(_0x4ad928){const _0xc62436=_0xa37700,_0x237445=_0x2cfb05()[_0xc62436('0x1c33')](_0x4ad928['rows'],function(_0xad461c){const _0x2949e5=_0xc62436;return _0x2cfb05()[_0x2949e5('0x1257')](_0x226f28[_0x2949e5('0x12b1')],{'id':_0xad461c[_0x2949e5('0x1e04')]});});_0x4ad928[_0xc62436('0x269a')]=_0x237445,_0x4ad928[_0xc62436('0x240f')]=_0x237445[_0xc62436('0x264b')],_0x2cfb05()['merge'](_0x226f28[_0xc62436('0xd5c')],_0x4ad928?_0x2cfb05()[_0xc62436('0x155c')](_0x4ad928[_0xc62436('0x269a')]?_0x4ad928[_0xc62436('0x269a')]:[],'id'):{});})[_0xa37700('0x1a80')](function(_0x5c3225){console['error'](_0x5c3225);})[_0xa37700('0x1951')](function(){const _0x20720c=_0xa37700;for(let _0x3d8ea3=0x0;_0x3d8ea3<_0x226f28[_0x20720c('0x434')][_0x20720c('0x264b')];_0x3d8ea3+=0x1){delete _0x226f28['rpcFaxQueuesWaitingInteractions'][_0x226f28[_0x20720c('0x434')][_0x3d8ea3]];}_0x1fc2b9=![],_0x226f28['deleteFaxQueuesWaitingInteractions']=[],_0x7a059b(),_0x497945();});function _0x497945(){const _0x2f6fe5=_0xa37700,_0x2f4a65=(_0x226f28['queryChannels'][_0x2f6fe5('0x1a43')]-0x1)*_0x226f28[_0x2f6fe5('0x1c05')][_0x2f6fe5('0x163f')];_0x226f28[_0x2f6fe5('0x1fd8')]=_0x2cfb05()[_0x2f6fe5('0xe63')](_0x226f28[_0x2f6fe5('0xd5c')],['joinAt'],[_0x2f6fe5('0x1dc3')]),_0x226f28['interactions']=_0x2cfb05()[_0x2f6fe5('0x3e5')](_0x226f28[_0x2f6fe5('0x1fd8')],_0x2f4a65)[_0x2f6fe5('0x233')](0x0,_0x226f28[_0x2f6fe5('0x1c05')]['limit']);}function _0x4b3f66(_0x17980b){const _0xd1103b=_0xa37700;_0x226f28[_0xd1103b('0x1603')]=_0x17980b['count']?_0x17980b[_0xd1103b('0x240f')]:0x0,_0x226f28[_0xd1103b('0x2382')]=_0x17980b?_0x2cfb05()[_0xd1103b('0x155c')](_0x17980b['rows']?_0x17980b['rows']:[],'id'):{},_0x9a85a6();}function _0x7a059b(){const _0x4e5e60=_0xa37700;_0x226f28[_0x4e5e60('0x2218')][_0x4e5e60('0x1098')]=(_0x226f28[_0x4e5e60('0x2218')][_0x4e5e60('0x1a43')]-0x1)*_0x226f28[_0x4e5e60('0x2218')]['limit'],_0x226f28['promise']=_0x2f87d1['user']['getQueues'](_0x226f28['query'],_0x4b3f66)[_0x4e5e60('0xa44')];}let _0x512a5f=!![],_0x450e22=0x1;_0x2fd3d6['$watch'](_0xa37700('0x28b4'),function(_0x2fe587,_0x43542c){const _0x5895cc=_0xa37700;_0x512a5f?_0x10cd6f(function(){_0x512a5f=![];}):(!_0x43542c&&(_0x450e22=_0x226f28[_0x5895cc('0x2218')]['page']),_0x2fe587!==_0x43542c&&(_0x226f28[_0x5895cc('0x2218')]['page']=0x1),!_0x2fe587&&(_0x226f28[_0x5895cc('0x2218')]['page']=_0x450e22),_0x226f28['getFaxQueues']());});function _0x4303bd(_0xaa3096){const _0x359f19=_0xa37700;return _0x2cfb05()[_0x359f19('0x2340')](_0xaa3096);}function _0x9a85a6(){const _0x11e634=_0xa37700;_0x2cfb05()[_0x11e634('0x941')](_0x226f28[_0x11e634('0x2382')],function(_0x49aaa5,_0x1f1f13){const _0x2fef86=_0x11e634;_0x226f28[_0x2fef86('0xf8d')][_0x1f1f13]&&(_0x226f28[_0x2fef86('0x2382')][_0x1f1f13][_0x2fef86('0x288a')]=_0x226f28['rpcFaxQueues'][_0x1f1f13]['waiting']||0x0);});}function _0x2dc823(_0xd0acf4){const _0x3fa776=_0xa37700;_0x226f28[_0x3fa776('0x2382')][_0xd0acf4['id']]&&(_0x226f28[_0x3fa776('0xf8d')][_0xd0acf4['id']]&&(_0x2cfb05()[_0x3fa776('0xcc3')](_0x226f28[_0x3fa776('0xf8d')][_0xd0acf4['id']],_0x2cfb05()[_0x3fa776('0x1a08')](_0xd0acf4,_0x503bf0)),_0x2cfb05()['merge'](_0x226f28[_0x3fa776('0x2382')][_0xd0acf4['id']],_0x2cfb05()[_0x3fa776('0x1a08')](_0xd0acf4,_0x503bf0))));}function _0x481786(_0x1e800b){const _0x485948=_0xa37700;!_0x2cfb05()[_0x485948('0x2863')](_0x1e800b)&&(_0x226f28[_0x485948('0xf8d')][_0x1e800b['id']]=_0x2cfb05()['pick'](_0x1e800b,_0x503bf0));}function _0x51c055(_0x545ba4){const _0x3e4e42=_0xa37700;!_0x2cfb05()[_0x3e4e42('0x2863')](_0x545ba4)&&(_0x226f28[_0x3e4e42('0xf8d')][_0x545ba4['id']]&&_0x2cfb05()[_0x3e4e42('0xcc3')](_0x226f28[_0x3e4e42('0xf8d')][_0x545ba4['id']],_0x2cfb05()['pick'](_0x545ba4,_0x503bf0)),_0x226f28[_0x3e4e42('0x2382')][_0x545ba4['id']]&&_0x2cfb05()[_0x3e4e42('0xcc3')](_0x226f28['faxQueues'][_0x545ba4['id']],_0x2cfb05()[_0x3e4e42('0x1a08')](_0x545ba4,_0x503bf0)));}function _0x344fe7(_0x10b286){const _0x1d30d7=_0xa37700;!_0x2cfb05()[_0x1d30d7('0x2863')](_0x10b286)&&(delete _0x226f28[_0x1d30d7('0xf8d')][_0x10b286['id']],delete _0x226f28[_0x1d30d7('0x2382')][_0x10b286['id']]);}function _0x4895c2(_0x337e7d){const _0x13e771=_0xa37700;_0x2cfb05()['toInteger'](_0x337e7d[_0x13e771('0x122a')])===_0x490d1d[_0x13e771('0x26cd')]()['id']&&_0x226f28[_0x13e771('0x7a')]();}function _0x2157d1(_0x37bf16){const _0x3553ba=_0xa37700;_0x2cfb05()[_0x3553ba('0x1edd')](_0x37bf16[_0x3553ba('0x122a')])===_0x490d1d['getCurrentUser']()['id']&&_0x226f28[_0x3553ba('0x7a')]();}function _0x7434c(_0x948c3){const _0x12c95c=_0xa37700;_0x226f28[_0x12c95c('0x2382')][_0x948c3[_0x12c95c('0x1e04')]]&&(_0x226f28['rpcFaxQueuesWaitingInteractions'][_0x948c3['id']]=_0x948c3,_0x497945());}function _0x5cd6b5(_0x5bc60e){const _0xf3fbf=_0xa37700;delete _0x226f28[_0xf3fbf('0xd5c')][_0x5bc60e['id']],_0x1fc2b9&&_0x226f28[_0xf3fbf('0x434')][_0xf3fbf('0x1514')](_0x5bc60e['id']),_0x497945();}function _0x34ba88(_0x277427){const _0x1c3d4e=_0xa37700;switch(_0x277427){case _0x1c3d4e('0xde2'):return _0x1c3d4e('0x2027');case _0x1c3d4e('0x1bfa'):return _0x1c3d4e('0x8aa');case'sms':return _0x1c3d4e('0x78a');case'whatsapp':return'lime-A700-bg';case'openchannel':return _0x1c3d4e('0x467');case _0x1c3d4e('0x1fc7'):return _0x1c3d4e('0xc56');default:return _0x1c3d4e('0xa10');}}_0x2fd3d6[_0xa37700('0x3d2')]('$destroy',function(){const _0x4f9954=_0xa37700;_0x256654[_0x4f9954('0x1800')](_0x4f9954('0x2241')),_0x256654[_0x4f9954('0x1800')](_0x4f9954('0x52f')),_0x256654[_0x4f9954('0x1800')](_0x4f9954('0x16c')),_0x256654[_0x4f9954('0x1800')]('faxQueue:remove'),_0x256654['removeAllListeners'](_0x4f9954('0x169d')),_0x256654[_0x4f9954('0x1800')](_0x4f9954('0x268b')),_0x256654['removeAllListeners'](_0x4f9954('0x24aa')),_0x256654[_0x4f9954('0x1800')](_0x4f9954('0x1b00'));});}const _0x35fc53=_0x2fe3e9;_0x1769c7[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1566'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'socket'];function _0x1769c7(_0x19d9cf,_0x50a861,_0x5d1c75,_0x455515,_0x513d7f,_0x436af4,_0x2b3f30,_0x2f0f16,_0x30dad6){const _0x22c225=_0x36e6f4,_0xb27549=this,_0x1e43eb=['id',_0x22c225('0x4f0'),_0x22c225('0x227a'),_0x22c225('0x288a')];let _0x4a401a=!![];_0xb27549[_0x22c225('0x273')]={},_0xb27549[_0x22c225('0xafd')]=0x0,_0xb27549[_0x22c225('0x3b6')]={},_0xb27549[_0x22c225('0x1fd8')]=[],_0xb27549[_0x22c225('0x2515')]=[],_0xb27549[_0x22c225('0x112f')]={},_0xb27549[_0x22c225('0x2218')]={'id':_0x2f0f16[_0x22c225('0x26cd')]()['id'],'channel':_0x22c225('0x1bfa'),'fields':'id,name,mapAgentsId,waiting','limit':0xa,'page':0x1},_0xb27549[_0x22c225('0x1c05')]={'limit':0xa,'page':0x1},_0xb27549[_0x22c225('0x103b')]=_0x338910,_0xb27549['getMailQueues']=_0x1e4844,_0xb27549[_0x22c225('0x1c4d')]=_0x37d75b,_0xb27549['getColorByChannel']=_0x4b7141,_0xb27549[_0x22c225('0x2654')]=_0x4d6e23,_0xb27549[_0x22c225('0xefb')]=_0x48c3ed,_0xb27549[_0x22c225('0x1d72')]=_0x1d89dc,_0xb27549[_0x22c225('0x207b')]=_0xabfdd8,_0xb27549['onRemoveMailQueue']=_0x51358b,_0xb27549[_0x22c225('0x201a')]=_0x2bc136,_0xb27549[_0x22c225('0x19cb')]=_0x2d3e4f,_0xb27549[_0x22c225('0x26ff')]=_0x55a28e,_0xb27549[_0x22c225('0x3cf')]=_0x377410,_0x30dad6[_0x22c225('0xe82')](_0x22c225('0x2056'),_0xb27549[_0x22c225('0xefb')]),_0x30dad6[_0x22c225('0xe82')](_0x22c225('0x1ec1'),_0xb27549[_0x22c225('0x1d72')]),_0x30dad6['onWithoutApply'](_0x22c225('0x53e'),_0xb27549['onUpdateMailQueue']),_0x30dad6['onWithoutApply'](_0x22c225('0x1787'),_0xb27549[_0x22c225('0x155a')]),_0x30dad6['onWithoutApply'](_0x22c225('0x11b2'),_0xb27549[_0x22c225('0x201a')]),_0x30dad6[_0x22c225('0xe82')](_0x22c225('0x5a'),_0xb27549[_0x22c225('0x19cb')]),_0x30dad6['onWithoutApply'](_0x22c225('0x2263'),_0xb27549[_0x22c225('0x26ff')]),_0x30dad6[_0x22c225('0xe82')](_0x22c225('0x192c'),_0xb27549[_0x22c225('0x3cf')]),_0x2b3f30['rpc']['getMailQueues']()['$promise'][_0x22c225('0x1166')](function(_0x2381e3){const _0x1b026a=_0x22c225;_0xb27549[_0x1b026a('0x3b6')]=_0x2381e3?_0x2cfb05()[_0x1b026a('0x155c')](_0x2381e3[_0x1b026a('0x269a')]?_0x2381e3['rows']:[],'id'):{};})['then'](function(){const _0x18a84f=_0x22c225;return _0x2b3f30['user'][_0x18a84f('0x152a')]({'id':_0x2f0f16['getCurrentUser']()['id'],'channel':_0x18a84f('0x1bfa')})[_0x18a84f('0xa44')];})[_0x22c225('0x1166')](function(_0x307aef){const _0x2e3df8=_0x22c225;return _0xb27549[_0x2e3df8('0x12b1')]=_0x307aef[_0x2e3df8('0x269a')],_0x2b3f30[_0x2e3df8('0x13fa')][_0x2e3df8('0x1b1e')]()['$promise'];})[_0x22c225('0x1166')](function(_0x5ed9c6){const _0x2efd1e=_0x22c225,_0x3c15cf=_0x2cfb05()[_0x2efd1e('0x1c33')](_0x5ed9c6[_0x2efd1e('0x269a')],function(_0x5c0f2e){const _0x1a26a6=_0x2efd1e;return _0x2cfb05()[_0x1a26a6('0x1257')](_0xb27549[_0x1a26a6('0x12b1')],{'id':_0x5c0f2e[_0x1a26a6('0x1e04')]});});_0x5ed9c6[_0x2efd1e('0x269a')]=_0x3c15cf,_0x5ed9c6[_0x2efd1e('0x240f')]=_0x3c15cf[_0x2efd1e('0x264b')],_0x2cfb05()['merge'](_0xb27549[_0x2efd1e('0x112f')],_0x5ed9c6?_0x2cfb05()[_0x2efd1e('0x155c')](_0x5ed9c6[_0x2efd1e('0x269a')]?_0x5ed9c6['rows']:[],'id'):{});})[_0x22c225('0x1a80')](function(_0x466dd3){const _0x3c8c4e=_0x22c225;console[_0x3c8c4e('0xfc9')](_0x466dd3);})[_0x22c225('0x1951')](function(){const _0x4a92f1=_0x22c225;for(let _0x169c71=0x0;_0x169c71<_0xb27549['deleteMailQueuesWaitingInteractions']['length'];_0x169c71+=0x1){delete _0xb27549['rpcMailQueuesWaitingInteractions'][_0xb27549[_0x4a92f1('0x2515')][_0x169c71]];}_0x4a401a=![],_0xb27549[_0x4a92f1('0x2515')]=[],_0x1e4844(),_0x4d6e23();});function _0x4d6e23(){const _0x553e03=_0x22c225,_0x2c55fc=(_0xb27549[_0x553e03('0x1c05')][_0x553e03('0x1a43')]-0x1)*_0xb27549[_0x553e03('0x1c05')][_0x553e03('0x163f')];_0xb27549[_0x553e03('0x1fd8')]=_0x2cfb05()['orderBy'](_0xb27549['rpcMailQueuesWaitingInteractions'],['joinAt'],[_0x553e03('0x1dc3')]),_0xb27549[_0x553e03('0x1624')]=_0x2cfb05()[_0x553e03('0x3e5')](_0xb27549[_0x553e03('0x1fd8')],_0x2c55fc)[_0x553e03('0x233')](0x0,_0xb27549[_0x553e03('0x1c05')][_0x553e03('0x163f')]);}function _0x338910(_0x2d097f){const _0x4b9188=_0x22c225;_0xb27549[_0x4b9188('0xafd')]=_0x2d097f[_0x4b9188('0x240f')]?_0x2d097f['count']:0x0,_0xb27549[_0x4b9188('0x273')]=_0x2d097f?_0x2cfb05()['keyBy'](_0x2d097f[_0x4b9188('0x269a')]?_0x2d097f['rows']:[],'id'):{},_0x34a76b();}function _0x1e4844(){const _0x209f44=_0x22c225;_0xb27549[_0x209f44('0x2218')][_0x209f44('0x1098')]=(_0xb27549[_0x209f44('0x2218')]['page']-0x1)*_0xb27549['query'][_0x209f44('0x163f')],_0xb27549['promise']=_0x2b3f30[_0x209f44('0x557')][_0x209f44('0x152a')](_0xb27549[_0x209f44('0x2218')],_0x338910)[_0x209f44('0xa44')];}let _0x18e795=!![],_0x3abb87=0x1;_0x19d9cf[_0x22c225('0xe83')](_0x22c225('0x28b4'),function(_0x4a1c60,_0x2fbda9){const _0x314fa1=_0x22c225;_0x18e795?_0x50a861(function(){_0x18e795=![];}):(!_0x2fbda9&&(_0x3abb87=_0xb27549[_0x314fa1('0x2218')][_0x314fa1('0x1a43')]),_0x4a1c60!==_0x2fbda9&&(_0xb27549[_0x314fa1('0x2218')]['page']=0x1),!_0x4a1c60&&(_0xb27549[_0x314fa1('0x2218')]['page']=_0x3abb87),_0xb27549[_0x314fa1('0xf84')]());});function _0x37d75b(_0x3574b2){const _0x3ae719=_0x22c225;return _0x2cfb05()[_0x3ae719('0x2340')](_0x3574b2);}function _0x34a76b(){const _0x44179b=_0x22c225;_0x2cfb05()['forIn'](_0xb27549[_0x44179b('0x273')],function(_0x4d90c5,_0x1d52a1){const _0x3d39d1=_0x44179b;_0xb27549['rpcMailQueues'][_0x1d52a1]&&(_0xb27549[_0x3d39d1('0x273')][_0x1d52a1][_0x3d39d1('0x288a')]=_0xb27549[_0x3d39d1('0x3b6')][_0x1d52a1]['waiting']||0x0);});}function _0x48c3ed(_0x6f3021){const _0x43a133=_0x22c225;_0xb27549[_0x43a133('0x273')][_0x6f3021['id']]&&(_0xb27549['rpcMailQueues'][_0x6f3021['id']]&&(_0x2cfb05()[_0x43a133('0xcc3')](_0xb27549[_0x43a133('0x3b6')][_0x6f3021['id']],_0x2cfb05()['pick'](_0x6f3021,_0x1e43eb)),_0x2cfb05()[_0x43a133('0xcc3')](_0xb27549['mailQueues'][_0x6f3021['id']],_0x2cfb05()[_0x43a133('0x1a08')](_0x6f3021,_0x1e43eb))));}function _0x1d89dc(_0x2b1c73){const _0x3630b8=_0x22c225;!_0x2cfb05()[_0x3630b8('0x2863')](_0x2b1c73)&&(_0xb27549[_0x3630b8('0x3b6')][_0x2b1c73['id']]=_0x2cfb05()[_0x3630b8('0x1a08')](_0x2b1c73,_0x1e43eb));}function _0xabfdd8(_0x225d46){const _0x3b1f1a=_0x22c225;!_0x2cfb05()[_0x3b1f1a('0x2863')](_0x225d46)&&(_0xb27549[_0x3b1f1a('0x3b6')][_0x225d46['id']]&&_0x2cfb05()[_0x3b1f1a('0xcc3')](_0xb27549[_0x3b1f1a('0x3b6')][_0x225d46['id']],_0x2cfb05()[_0x3b1f1a('0x1a08')](_0x225d46,_0x1e43eb)),_0xb27549[_0x3b1f1a('0x273')][_0x225d46['id']]&&_0x2cfb05()['merge'](_0xb27549[_0x3b1f1a('0x273')][_0x225d46['id']],_0x2cfb05()[_0x3b1f1a('0x1a08')](_0x225d46,_0x1e43eb)));}function _0x51358b(_0x22f1cc){const _0x180177=_0x22c225;!_0x2cfb05()['isNil'](_0x22f1cc)&&(delete _0xb27549[_0x180177('0x3b6')][_0x22f1cc['id']],delete _0xb27549['mailQueues'][_0x22f1cc['id']]);}function _0x2bc136(_0x378710){const _0x48f361=_0x22c225;_0x2cfb05()[_0x48f361('0x1edd')](_0x378710['UserId'])===_0x2f0f16[_0x48f361('0x26cd')]()['id']&&_0xb27549['getMailQueues']();}function _0x2d3e4f(_0x16b2af){const _0x52bc5e=_0x22c225;_0x2cfb05()[_0x52bc5e('0x1edd')](_0x16b2af[_0x52bc5e('0x122a')])===_0x2f0f16['getCurrentUser']()['id']&&_0xb27549[_0x52bc5e('0xf84')]();}function _0x55a28e(_0x2366ab){const _0x16637e=_0x22c225;_0xb27549[_0x16637e('0x273')][_0x2366ab[_0x16637e('0x1e04')]]&&(_0xb27549[_0x16637e('0x112f')][_0x2366ab['id']]=_0x2366ab,_0x4d6e23());}function _0x377410(_0x3c1183){const _0x59d438=_0x22c225;delete _0xb27549[_0x59d438('0x112f')][_0x3c1183['id']],_0x4a401a&&_0xb27549[_0x59d438('0x2515')][_0x59d438('0x1514')](_0x3c1183['id']),_0x4d6e23();}function _0x4b7141(_0x52f1eb){const _0x2aa579=_0x22c225;switch(_0x52f1eb){case _0x2aa579('0xde2'):return _0x2aa579('0x2027');case _0x2aa579('0x1bfa'):return _0x2aa579('0x8aa');case _0x2aa579('0x146c'):return'orange-bg';case'whatsapp':return'lime-A700-bg';case'openchannel':return'amber-A200-bg';case _0x2aa579('0x1fc7'):return _0x2aa579('0xc56');default:return _0x2aa579('0xa10');}}_0x19d9cf[_0x22c225('0x3d2')](_0x22c225('0x1c3f'),function(){const _0x40eca2=_0x22c225;_0x30dad6[_0x40eca2('0x1800')](_0x40eca2('0x2056')),_0x30dad6[_0x40eca2('0x1800')](_0x40eca2('0x1ec1')),_0x30dad6[_0x40eca2('0x1800')](_0x40eca2('0x53e')),_0x30dad6['removeAllListeners'](_0x40eca2('0x1787')),_0x30dad6[_0x40eca2('0x1800')]('userMailQueue:save'),_0x30dad6[_0x40eca2('0x1800')](_0x40eca2('0x5a')),_0x30dad6[_0x40eca2('0x1800')](_0x40eca2('0x2263')),_0x30dad6['removeAllListeners'](_0x40eca2('0x192c'));});}const _0x57e4aa=_0x1769c7;_0x4729ef[_0x36e6f4('0x1294')]=['$scope','$timeout',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1566'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'socket'];function _0x4729ef(_0x6e5418,_0x2af33c,_0x5e9c57,_0x5410f9,_0x49ce1e,_0x41da9c,_0x2644c3,_0x52be78,_0x376594){const _0x42058f=_0x36e6f4,_0x55006b=this,_0x28a88e=['id',_0x42058f('0x4f0'),'mapAgentsId',_0x42058f('0x288a')];let _0x3bb2ed=!![];_0x55006b[_0x42058f('0xaf6')]={},_0x55006b[_0x42058f('0x1678')]=0x0,_0x55006b[_0x42058f('0xf28')]={},_0x55006b[_0x42058f('0x1fd8')]=[],_0x55006b[_0x42058f('0xcd2')]=[],_0x55006b[_0x42058f('0x1f44')]={},_0x55006b[_0x42058f('0x2218')]={'id':_0x52be78[_0x42058f('0x26cd')]()['id'],'channel':_0x42058f('0x26c'),'fields':_0x42058f('0x28cc'),'limit':0xa,'page':0x1},_0x55006b['queryChannels']={'limit':0xa,'page':0x1},_0x55006b[_0x42058f('0x103b')]=_0x3692dd,_0x55006b[_0x42058f('0x2bb')]=_0xb755ea,_0x55006b[_0x42058f('0x1c4d')]=_0xeaac63,_0x55006b[_0x42058f('0x12bb')]=_0x3f2692,_0x55006b[_0x42058f('0x2654')]=_0x3b9c90,_0x55006b[_0x42058f('0xefb')]=_0x3a3492,_0x55006b[_0x42058f('0x1acd')]=_0x64dac7,_0x55006b[_0x42058f('0x41a')]=_0x1f1cd7,_0x55006b[_0x42058f('0xafc')]=_0x232640,_0x55006b[_0x42058f('0x2cf')]=_0x4c288a,_0x55006b[_0x42058f('0x1379')]=_0x155f02,_0x55006b[_0x42058f('0xfff')]=_0x3a826a,_0x55006b['onRemoveOpenchannelQueueChannel']=_0x3a1169,_0x376594['onWithoutApply'](_0x42058f('0x9b1'),_0x55006b[_0x42058f('0xefb')]),_0x376594[_0x42058f('0xe82')](_0x42058f('0x1078'),_0x55006b[_0x42058f('0x1acd')]),_0x376594[_0x42058f('0xe82')](_0x42058f('0x57'),_0x55006b[_0x42058f('0x41a')]),_0x376594[_0x42058f('0xe82')](_0x42058f('0x2861'),_0x55006b[_0x42058f('0xafc')]),_0x376594[_0x42058f('0xe82')]('userOpenchannelQueue:save',_0x55006b['onSaveUserOpenchannelQueue']),_0x376594['onWithoutApply']('userOpenchannelQueue:remove',_0x55006b[_0x42058f('0x1379')]),_0x376594['onWithoutApply'](_0x42058f('0x1eee'),_0x55006b[_0x42058f('0xfff')]),_0x376594[_0x42058f('0xe82')](_0x42058f('0x1b63'),_0x55006b['onRemoveOpenchannelQueueChannel']),_0x2644c3['rpc'][_0x42058f('0x2bb')]()[_0x42058f('0xa44')][_0x42058f('0x1166')](function(_0xe05a75){const _0x1d254b=_0x42058f;_0x55006b['rpcOpenchannelQueues']=_0xe05a75?_0x2cfb05()['keyBy'](_0xe05a75[_0x1d254b('0x269a')]?_0xe05a75['rows']:[],'id'):{};})[_0x42058f('0x1166')](function(){const _0x5292cf=_0x42058f;return _0x2644c3['user'][_0x5292cf('0x152a')]({'id':_0x52be78[_0x5292cf('0x26cd')]()['id'],'channel':_0x5292cf('0x26c')})[_0x5292cf('0xa44')];})[_0x42058f('0x1166')](function(_0xd6eb92){const _0x1b3564=_0x42058f;return _0x55006b[_0x1b3564('0x12b1')]=_0xd6eb92[_0x1b3564('0x269a')],_0x2644c3[_0x1b3564('0x13fa')]['getOpenchannelQueuesWaitingInteractions']()[_0x1b3564('0xa44')];})['then'](function(_0x1c2f84){const _0x45d873=_0x42058f,_0xeee2dc=_0x2cfb05()['filter'](_0x1c2f84[_0x45d873('0x269a')],function(_0x4dce6d){const _0x45f61a=_0x45d873;return _0x2cfb05()['includes'](_0x55006b[_0x45f61a('0x12b1')],{'id':_0x4dce6d[_0x45f61a('0x1e04')]});});_0x1c2f84[_0x45d873('0x269a')]=_0xeee2dc,_0x1c2f84[_0x45d873('0x240f')]=_0xeee2dc[_0x45d873('0x264b')],_0x2cfb05()[_0x45d873('0xcc3')](_0x55006b[_0x45d873('0x1f44')],_0x1c2f84?_0x2cfb05()[_0x45d873('0x155c')](_0x1c2f84[_0x45d873('0x269a')]?_0x1c2f84[_0x45d873('0x269a')]:[],'id'):{});})['catch'](function(_0x1f2c7c){console['error'](_0x1f2c7c);})[_0x42058f('0x1951')](function(){const _0x38a06c=_0x42058f;for(let _0x29527e=0x0;_0x29527e<_0x55006b[_0x38a06c('0xcd2')][_0x38a06c('0x264b')];_0x29527e+=0x1){delete _0x55006b['rpcOpenchannelQueuesWaitingInteractions'][_0x55006b['deleteOpenchannelQueuesWaitingInteractions'][_0x29527e]];}_0x3bb2ed=![],_0x55006b[_0x38a06c('0xcd2')]=[],_0xb755ea(),_0x3b9c90();});function _0x3b9c90(){const _0x1b94be=_0x42058f,_0x3b2178=(_0x55006b['queryChannels'][_0x1b94be('0x1a43')]-0x1)*_0x55006b[_0x1b94be('0x1c05')][_0x1b94be('0x163f')];_0x55006b[_0x1b94be('0x1fd8')]=_0x2cfb05()[_0x1b94be('0xe63')](_0x55006b[_0x1b94be('0x1f44')],[_0x1b94be('0x3eb')],[_0x1b94be('0x1dc3')]),_0x55006b[_0x1b94be('0x1624')]=_0x2cfb05()['drop'](_0x55006b['paginatedInteractions'],_0x3b2178)[_0x1b94be('0x233')](0x0,_0x55006b[_0x1b94be('0x1c05')][_0x1b94be('0x163f')]);}function _0x3692dd(_0x13cad7){const _0x328460=_0x42058f;_0x55006b[_0x328460('0x1678')]=_0x13cad7[_0x328460('0x240f')]?_0x13cad7[_0x328460('0x240f')]:0x0,_0x55006b[_0x328460('0xaf6')]=_0x13cad7?_0x2cfb05()['keyBy'](_0x13cad7[_0x328460('0x269a')]?_0x13cad7['rows']:[],'id'):{},_0x1b7947();}function _0xb755ea(){const _0x48d95c=_0x42058f;_0x55006b[_0x48d95c('0x2218')][_0x48d95c('0x1098')]=(_0x55006b[_0x48d95c('0x2218')][_0x48d95c('0x1a43')]-0x1)*_0x55006b[_0x48d95c('0x2218')]['limit'],_0x55006b[_0x48d95c('0x1f48')]=_0x2644c3[_0x48d95c('0x557')]['getQueues'](_0x55006b['query'],_0x3692dd)[_0x48d95c('0xa44')];}let _0x101f78=!![],_0x52277d=0x1;_0x6e5418[_0x42058f('0xe83')]('vm_dc.query.filter',function(_0x24e67e,_0x2548bc){const _0x54ba41=_0x42058f;_0x101f78?_0x2af33c(function(){_0x101f78=![];}):(!_0x2548bc&&(_0x52277d=_0x55006b[_0x54ba41('0x2218')][_0x54ba41('0x1a43')]),_0x24e67e!==_0x2548bc&&(_0x55006b[_0x54ba41('0x2218')]['page']=0x1),!_0x24e67e&&(_0x55006b[_0x54ba41('0x2218')][_0x54ba41('0x1a43')]=_0x52277d),_0x55006b['getOpenchannelQueues']());});function _0xeaac63(_0x158ab9){return _0x2cfb05()['size'](_0x158ab9);}function _0x1b7947(){const _0x2c5968=_0x42058f;_0x2cfb05()[_0x2c5968('0x941')](_0x55006b['openchannelQueues'],function(_0x300a1,_0x9c5282){const _0x356b56=_0x2c5968;_0x55006b[_0x356b56('0xf28')][_0x9c5282]&&(_0x55006b[_0x356b56('0xaf6')][_0x9c5282][_0x356b56('0x288a')]=_0x55006b[_0x356b56('0xf28')][_0x9c5282][_0x356b56('0x288a')]||0x0);});}function _0x3a3492(_0x19b5be){const _0x502471=_0x42058f;_0x55006b['openchannelQueues'][_0x19b5be['id']]&&(_0x55006b[_0x502471('0xf28')][_0x19b5be['id']]&&(_0x2cfb05()[_0x502471('0xcc3')](_0x55006b[_0x502471('0xf28')][_0x19b5be['id']],_0x2cfb05()[_0x502471('0x1a08')](_0x19b5be,_0x28a88e)),_0x2cfb05()[_0x502471('0xcc3')](_0x55006b[_0x502471('0xaf6')][_0x19b5be['id']],_0x2cfb05()[_0x502471('0x1a08')](_0x19b5be,_0x28a88e))));}function _0x64dac7(_0x125843){const _0xc1e86c=_0x42058f;!_0x2cfb05()[_0xc1e86c('0x2863')](_0x125843)&&(_0x55006b[_0xc1e86c('0xf28')][_0x125843['id']]=_0x2cfb05()['pick'](_0x125843,_0x28a88e));}function _0x1f1cd7(_0x5740a9){const _0x5074d5=_0x42058f;!_0x2cfb05()['isNil'](_0x5740a9)&&(_0x55006b[_0x5074d5('0xf28')][_0x5740a9['id']]&&_0x2cfb05()['merge'](_0x55006b[_0x5074d5('0xf28')][_0x5740a9['id']],_0x2cfb05()[_0x5074d5('0x1a08')](_0x5740a9,_0x28a88e)),_0x55006b['openchannelQueues'][_0x5740a9['id']]&&_0x2cfb05()[_0x5074d5('0xcc3')](_0x55006b[_0x5074d5('0xaf6')][_0x5740a9['id']],_0x2cfb05()['pick'](_0x5740a9,_0x28a88e)));}function _0x232640(_0x2322ad){const _0x4fe11a=_0x42058f;!_0x2cfb05()[_0x4fe11a('0x2863')](_0x2322ad)&&(delete _0x55006b[_0x4fe11a('0xf28')][_0x2322ad['id']],delete _0x55006b[_0x4fe11a('0xaf6')][_0x2322ad['id']]);}function _0x4c288a(_0x5bb829){const _0x4ad643=_0x42058f;_0x2cfb05()['toInteger'](_0x5bb829[_0x4ad643('0x122a')])===_0x52be78[_0x4ad643('0x26cd')]()['id']&&_0x55006b[_0x4ad643('0x2bb')]();}function _0x155f02(_0x1ab45e){const _0x2acb2b=_0x42058f;_0x2cfb05()[_0x2acb2b('0x1edd')](_0x1ab45e[_0x2acb2b('0x122a')])===_0x52be78[_0x2acb2b('0x26cd')]()['id']&&_0x55006b[_0x2acb2b('0x2bb')]();}function _0x3a826a(_0x537a7f){const _0x1b973a=_0x42058f;_0x55006b[_0x1b973a('0xaf6')][_0x537a7f['queue_id']]&&(_0x55006b[_0x1b973a('0x1f44')][_0x537a7f['id']]=_0x537a7f,_0x3b9c90());}function _0x3a1169(_0x827ebc){const _0x587fa6=_0x42058f;delete _0x55006b[_0x587fa6('0x1f44')][_0x827ebc['id']],_0x3bb2ed&&_0x55006b[_0x587fa6('0xcd2')][_0x587fa6('0x1514')](_0x827ebc['id']),_0x3b9c90();}function _0x3f2692(_0x4e40a5){const _0x32f32b=_0x42058f;switch(_0x4e40a5){case _0x32f32b('0xde2'):return _0x32f32b('0x2027');case _0x32f32b('0x1bfa'):return _0x32f32b('0x8aa');case _0x32f32b('0x146c'):return _0x32f32b('0x78a');case _0x32f32b('0x116e'):return _0x32f32b('0x2673');case _0x32f32b('0x26c'):return _0x32f32b('0x467');case _0x32f32b('0x1fc7'):return _0x32f32b('0xc56');default:return _0x32f32b('0xa10');}}_0x6e5418[_0x42058f('0x3d2')](_0x42058f('0x1c3f'),function(){const _0x256805=_0x42058f;_0x376594[_0x256805('0x1800')](_0x256805('0x9b1')),_0x376594[_0x256805('0x1800')](_0x256805('0x1078')),_0x376594['removeAllListeners'](_0x256805('0x57')),_0x376594['removeAllListeners'](_0x256805('0x2861')),_0x376594[_0x256805('0x1800')](_0x256805('0x1523')),_0x376594[_0x256805('0x1800')]('userOpenchannelQueue:remove'),_0x376594[_0x256805('0x1800')](_0x256805('0x1eee')),_0x376594[_0x256805('0x1800')]('openchannel_queue_waiting_interaction:remove');});}const _0x26f3a0=_0x4729ef;_0x2519bc[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$timeout',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1566'),_0x36e6f4('0x586'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x2661')];function _0x2519bc(_0x3dc580,_0x53f506,_0x3c8acf,_0x261773,_0x4bcf7a,_0x6964e5,_0x97a4cd,_0x4f0ba6,_0x3959d7){const _0x55461f=_0x36e6f4,_0x42e71b=this,_0x1e07e8=['id',_0x55461f('0x4f0'),'mapAgentsId',_0x55461f('0x288a')];let _0x1cf8eb=!![];_0x42e71b[_0x55461f('0x20c0')]={},_0x42e71b['smsQueuesTotal']=0x0,_0x42e71b[_0x55461f('0x1681')]={},_0x42e71b[_0x55461f('0x1fd8')]=[],_0x42e71b['deleteSmsQueuesWaitingInteractions']=[],_0x42e71b[_0x55461f('0x1989')]={},_0x42e71b['query']={'id':_0x4f0ba6[_0x55461f('0x26cd')]()['id'],'channel':_0x55461f('0x146c'),'fields':_0x55461f('0x28cc'),'limit':0xa,'page':0x1},_0x42e71b[_0x55461f('0x1c05')]={'limit':0xa,'page':0x1},_0x42e71b[_0x55461f('0x103b')]=_0x3f6440,_0x42e71b[_0x55461f('0x1c6f')]=_0x1acd7c,_0x42e71b[_0x55461f('0x1c4d')]=_0x5e9c7e,_0x42e71b[_0x55461f('0x12bb')]=_0x545e59,_0x42e71b[_0x55461f('0x2654')]=_0x22f0fa,_0x42e71b['onSaveQueue']=_0x51280c,_0x42e71b[_0x55461f('0x286a')]=_0xc61edc,_0x42e71b[_0x55461f('0x166a')]=_0x584e8e,_0x42e71b[_0x55461f('0x2053')]=_0x40b2a8,_0x42e71b[_0x55461f('0x6eb')]=_0x1299df,_0x42e71b[_0x55461f('0x448')]=_0xcf117e,_0x42e71b['onSaveSmsQueueChannel']=_0x32998a,_0x42e71b[_0x55461f('0x8ea')]=_0x57000c,_0x3959d7[_0x55461f('0xe82')](_0x55461f('0x565'),_0x42e71b[_0x55461f('0xefb')]),_0x3959d7[_0x55461f('0xe82')](_0x55461f('0x1fc5'),_0x42e71b[_0x55461f('0x286a')]),_0x3959d7[_0x55461f('0xe82')](_0x55461f('0xb05'),_0x42e71b[_0x55461f('0x166a')]),_0x3959d7[_0x55461f('0xe82')](_0x55461f('0x65f'),_0x42e71b[_0x55461f('0x2053')]),_0x3959d7[_0x55461f('0xe82')]('userSmsQueue:save',_0x42e71b[_0x55461f('0x6eb')]),_0x3959d7[_0x55461f('0xe82')]('userSmsQueue:remove',_0x42e71b[_0x55461f('0x448')]),_0x3959d7[_0x55461f('0xe82')](_0x55461f('0xd0b'),_0x42e71b[_0x55461f('0xfbd')]),_0x3959d7[_0x55461f('0xe82')](_0x55461f('0x233a'),_0x42e71b['onRemoveSmsQueueChannel']),_0x97a4cd['rpc'][_0x55461f('0x1c6f')]()[_0x55461f('0xa44')][_0x55461f('0x1166')](function(_0x5bdd90){const _0x40a876=_0x55461f;_0x42e71b[_0x40a876('0x1681')]=_0x5bdd90?_0x2cfb05()[_0x40a876('0x155c')](_0x5bdd90[_0x40a876('0x269a')]?_0x5bdd90[_0x40a876('0x269a')]:[],'id'):{};})[_0x55461f('0x1166')](function(){const _0x26ebe8=_0x55461f;return _0x97a4cd[_0x26ebe8('0x557')]['getQueues']({'id':_0x4f0ba6['getCurrentUser']()['id'],'channel':_0x26ebe8('0x146c')})['$promise'];})[_0x55461f('0x1166')](function(_0x5e009e){const _0x5a2f24=_0x55461f;return _0x42e71b[_0x5a2f24('0x12b1')]=_0x5e009e[_0x5a2f24('0x269a')],_0x97a4cd['rpc'][_0x5a2f24('0x2748')]()[_0x5a2f24('0xa44')];})['then'](function(_0x1775a4){const _0x197741=_0x55461f,_0x2d9bbe=_0x2cfb05()[_0x197741('0x1c33')](_0x1775a4[_0x197741('0x269a')],function(_0x523a23){const _0x4b25e9=_0x197741;return _0x2cfb05()[_0x4b25e9('0x1257')](_0x42e71b['myQueues'],{'id':_0x523a23[_0x4b25e9('0x1e04')]});});_0x1775a4[_0x197741('0x269a')]=_0x2d9bbe,_0x1775a4[_0x197741('0x240f')]=_0x2d9bbe[_0x197741('0x264b')],_0x2cfb05()[_0x197741('0xcc3')](_0x42e71b[_0x197741('0x1989')],_0x1775a4?_0x2cfb05()[_0x197741('0x155c')](_0x1775a4[_0x197741('0x269a')]?_0x1775a4[_0x197741('0x269a')]:[],'id'):{});})[_0x55461f('0x1a80')](function(_0xdfbccb){console['error'](_0xdfbccb);})[_0x55461f('0x1951')](function(){const _0x410581=_0x55461f;for(let _0x13ed7d=0x0;_0x13ed7d<_0x42e71b[_0x410581('0x1a99')][_0x410581('0x264b')];_0x13ed7d+=0x1){delete _0x42e71b[_0x410581('0x1989')][_0x42e71b['deleteSmsQueuesWaitingInteractions'][_0x13ed7d]];}_0x1cf8eb=![],_0x42e71b[_0x410581('0x1a99')]=[],_0x1acd7c(),_0x22f0fa();});function _0x22f0fa(){const _0x21984a=_0x55461f,_0x4bf04e=(_0x42e71b[_0x21984a('0x1c05')][_0x21984a('0x1a43')]-0x1)*_0x42e71b['queryChannels'][_0x21984a('0x163f')];_0x42e71b[_0x21984a('0x1fd8')]=_0x2cfb05()[_0x21984a('0xe63')](_0x42e71b[_0x21984a('0x1989')],[_0x21984a('0x3eb')],[_0x21984a('0x1dc3')]),_0x42e71b[_0x21984a('0x1624')]=_0x2cfb05()[_0x21984a('0x3e5')](_0x42e71b['paginatedInteractions'],_0x4bf04e)['slice'](0x0,_0x42e71b['queryChannels'][_0x21984a('0x163f')]);}function _0x3f6440(_0x4c7357){const _0x498fa4=_0x55461f;_0x42e71b[_0x498fa4('0x3b3')]=_0x4c7357[_0x498fa4('0x240f')]?_0x4c7357[_0x498fa4('0x240f')]:0x0,_0x42e71b[_0x498fa4('0x20c0')]=_0x4c7357?_0x2cfb05()[_0x498fa4('0x155c')](_0x4c7357[_0x498fa4('0x269a')]?_0x4c7357['rows']:[],'id'):{},_0x1c9884();}function _0x1acd7c(){const _0x4aa7a4=_0x55461f;_0x42e71b[_0x4aa7a4('0x2218')][_0x4aa7a4('0x1098')]=(_0x42e71b[_0x4aa7a4('0x2218')][_0x4aa7a4('0x1a43')]-0x1)*_0x42e71b[_0x4aa7a4('0x2218')][_0x4aa7a4('0x163f')],_0x42e71b['promise']=_0x97a4cd[_0x4aa7a4('0x557')][_0x4aa7a4('0x152a')](_0x42e71b[_0x4aa7a4('0x2218')],_0x3f6440)[_0x4aa7a4('0xa44')];}let _0x3fe83a=!![],_0x25680f=0x1;_0x3dc580[_0x55461f('0xe83')](_0x55461f('0x28b4'),function(_0x58ce25,_0x174a9a){const _0x3c9dce=_0x55461f;_0x3fe83a?_0x53f506(function(){_0x3fe83a=![];}):(!_0x174a9a&&(_0x25680f=_0x42e71b[_0x3c9dce('0x2218')]['page']),_0x58ce25!==_0x174a9a&&(_0x42e71b[_0x3c9dce('0x2218')][_0x3c9dce('0x1a43')]=0x1),!_0x58ce25&&(_0x42e71b['query']['page']=_0x25680f),_0x42e71b['getSmsQueues']());});function _0x5e9c7e(_0x5b0fa2){const _0x293d5a=_0x55461f;return _0x2cfb05()[_0x293d5a('0x2340')](_0x5b0fa2);}function _0x1c9884(){const _0x34a62d=_0x55461f;_0x2cfb05()[_0x34a62d('0x941')](_0x42e71b[_0x34a62d('0x20c0')],function(_0x3dfa45,_0x5e7216){const _0xe75abf=_0x34a62d;_0x42e71b[_0xe75abf('0x1681')][_0x5e7216]&&(_0x42e71b['smsQueues'][_0x5e7216][_0xe75abf('0x288a')]=_0x42e71b[_0xe75abf('0x1681')][_0x5e7216]['waiting']||0x0);});}function _0x51280c(_0x5d250d){const _0x4ee535=_0x55461f;_0x42e71b[_0x4ee535('0x20c0')][_0x5d250d['id']]&&(_0x42e71b[_0x4ee535('0x1681')][_0x5d250d['id']]&&(_0x2cfb05()[_0x4ee535('0xcc3')](_0x42e71b[_0x4ee535('0x1681')][_0x5d250d['id']],_0x2cfb05()['pick'](_0x5d250d,_0x1e07e8)),_0x2cfb05()['merge'](_0x42e71b[_0x4ee535('0x20c0')][_0x5d250d['id']],_0x2cfb05()[_0x4ee535('0x1a08')](_0x5d250d,_0x1e07e8))));}function _0xc61edc(_0x2e4619){const _0x1c6b3c=_0x55461f;!_0x2cfb05()[_0x1c6b3c('0x2863')](_0x2e4619)&&(_0x42e71b[_0x1c6b3c('0x1681')][_0x2e4619['id']]=_0x2cfb05()[_0x1c6b3c('0x1a08')](_0x2e4619,_0x1e07e8));}function _0x584e8e(_0x45b747){const _0x4d277a=_0x55461f;!_0x2cfb05()[_0x4d277a('0x2863')](_0x45b747)&&(_0x42e71b[_0x4d277a('0x1681')][_0x45b747['id']]&&_0x2cfb05()['merge'](_0x42e71b['rpcSmsQueues'][_0x45b747['id']],_0x2cfb05()[_0x4d277a('0x1a08')](_0x45b747,_0x1e07e8)),_0x42e71b[_0x4d277a('0x20c0')][_0x45b747['id']]&&_0x2cfb05()[_0x4d277a('0xcc3')](_0x42e71b[_0x4d277a('0x20c0')][_0x45b747['id']],_0x2cfb05()[_0x4d277a('0x1a08')](_0x45b747,_0x1e07e8)));}function _0x40b2a8(_0x2452a6){const _0x507517=_0x55461f;!_0x2cfb05()[_0x507517('0x2863')](_0x2452a6)&&(delete _0x42e71b[_0x507517('0x1681')][_0x2452a6['id']],delete _0x42e71b[_0x507517('0x20c0')][_0x2452a6['id']]);}function _0x1299df(_0x38c678){const _0x25cd1d=_0x55461f;_0x2cfb05()['toInteger'](_0x38c678[_0x25cd1d('0x122a')])===_0x4f0ba6['getCurrentUser']()['id']&&_0x42e71b[_0x25cd1d('0x1c6f')]();}function _0xcf117e(_0x15016e){const _0x4ca150=_0x55461f;_0x2cfb05()[_0x4ca150('0x1edd')](_0x15016e[_0x4ca150('0x122a')])===_0x4f0ba6[_0x4ca150('0x26cd')]()['id']&&_0x42e71b[_0x4ca150('0x1c6f')]();}function _0x32998a(_0x2cc57d){const _0x549a16=_0x55461f;_0x42e71b[_0x549a16('0x20c0')][_0x2cc57d[_0x549a16('0x1e04')]]&&(_0x42e71b[_0x549a16('0x1989')][_0x2cc57d['id']]=_0x2cc57d,_0x22f0fa());}function _0x57000c(_0x146ff3){const _0xe3a280=_0x55461f;delete _0x42e71b[_0xe3a280('0x1989')][_0x146ff3['id']],_0x1cf8eb&&_0x42e71b[_0xe3a280('0x1a99')][_0xe3a280('0x1514')](_0x146ff3['id']),_0x22f0fa();}function _0x545e59(_0x5c62db){const _0x3c4836=_0x55461f;switch(_0x5c62db){case _0x3c4836('0xde2'):return _0x3c4836('0x2027');case _0x3c4836('0x1bfa'):return _0x3c4836('0x8aa');case _0x3c4836('0x146c'):return _0x3c4836('0x78a');case'whatsapp':return'lime-A700-bg';case'openchannel':return _0x3c4836('0x467');case _0x3c4836('0x1fc7'):return'blue-grey-A200-bg';default:return _0x3c4836('0xa10');}}_0x3dc580[_0x55461f('0x3d2')]('$destroy',function(){const _0x1f5c1f=_0x55461f;_0x3959d7[_0x1f5c1f('0x1800')](_0x1f5c1f('0x565')),_0x3959d7[_0x1f5c1f('0x1800')]('smsQueue:save'),_0x3959d7[_0x1f5c1f('0x1800')]('smsQueue:update'),_0x3959d7[_0x1f5c1f('0x1800')](_0x1f5c1f('0x65f')),_0x3959d7[_0x1f5c1f('0x1800')](_0x1f5c1f('0x36')),_0x3959d7['removeAllListeners'](_0x1f5c1f('0x2070')),_0x3959d7[_0x1f5c1f('0x1800')](_0x1f5c1f('0xd0b')),_0x3959d7['removeAllListeners'](_0x1f5c1f('0x233a'));});}const _0x532aa9=_0x2519bc;_0x38741e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$timeout','$mdDialog',_0x36e6f4('0x1c90'),'$window','$translate',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x2661')];function _0x38741e(_0x5de5ca,_0x43e0e4,_0x381c4c,_0x599673,_0x325746,_0x10d91c,_0x1feab5,_0x1cf790,_0x1417c9){const _0x3d985b=_0x36e6f4,_0x29633a=this,_0x1a0cbd=[_0x3d985b('0x1345'),_0x3d985b('0x288a'),_0x3d985b('0x20ae'),_0x3d985b('0x6c9')];_0x29633a[_0x3d985b('0x20fd')]={},_0x29633a[_0x3d985b('0x193f')]=0x0,_0x29633a[_0x3d985b('0x1245')]={},_0x29633a[_0x3d985b('0x680')]={},_0x29633a[_0x3d985b('0x2177')]={},_0x29633a['addVoiceQueuesChannels']={},_0x29633a[_0x3d985b('0x157f')]=[],_0x29633a['load']=!![],_0x29633a['query']={'id':_0x1cf790[_0x3d985b('0x26cd')]()['id'],'fields':_0x3d985b('0xa05'),'channel':_0x3d985b('0x21da'),'type':_0x3d985b('0x14d8'),'limit':0xa,'page':0x1},_0x29633a['queryChannels']={'limit':0xa,'page':0x1},_0x29633a[_0x3d985b('0x103b')]=_0x20a320,_0x29633a[_0x3d985b('0x680')]=_0xee1076,_0x29633a[_0x3d985b('0x1c4d')]=_0x13efba,_0x29633a[_0x3d985b('0xefb')]=_0x413229,_0x29633a[_0x3d985b('0xf77')]=_0x5bdb70,_0x29633a[_0x3d985b('0x23da')]=_0x37e3a9,_0x29633a[_0x3d985b('0x1ff4')]=_0x3a1bde,_0x29633a[_0x3d985b('0x1e8e')]=_0x131ebb,_0x29633a[_0x3d985b('0x1b68')]=_0x5d0a6c,_0x1417c9[_0x3d985b('0xe82')](_0x3d985b('0xa60'),_0x29633a[_0x3d985b('0xefb')]),_0x1417c9[_0x3d985b('0xe82')]('voice_queue_channel:save',_0x29633a[_0x3d985b('0xf77')]),_0x1417c9[_0x3d985b('0xe82')]('userVoiceQueue:save',_0x29633a[_0x3d985b('0x23da')]),_0x1417c9[_0x3d985b('0xe82')](_0x3d985b('0x25f0'),_0x29633a[_0x3d985b('0x23da')]),_0x1417c9[_0x3d985b('0xe82')](_0x3d985b('0x235a'),_0x29633a[_0x3d985b('0x1ff4')]),_0x1417c9[_0x3d985b('0xe82')](_0x3d985b('0xfda'),_0x29633a[_0x3d985b('0x1b68')]),_0x1417c9[_0x3d985b('0xe82')](_0x3d985b('0x272d'),_0x29633a[_0x3d985b('0x1e8e')]),_0x1feab5['user'][_0x3d985b('0x152a')](_0x29633a['query'])[_0x3d985b('0xa44')][_0x3d985b('0x1166')](function(_0x3ca6cd){const _0x4584f3=_0x3d985b;return _0x29633a[_0x4584f3('0x12b1')]=_0x3ca6cd,_0x1feab5[_0x4584f3('0x13fa')]['getVoiceQueues']()[_0x4584f3('0xa44')];})['then'](function(_0x43083a){const _0x46762f=_0x3d985b,_0x204b0d=_0x43083a[_0x46762f('0x269a')],_0x22a232=_0x2cfb05()[_0x46762f('0x155c')](_0x204b0d,'id');for(let _0x3db1cd=0x0;_0x3db1cd<_0x29633a[_0x46762f('0x12b1')][_0x46762f('0x240f')];_0x3db1cd++){const _0x576621=_0x29633a[_0x46762f('0x12b1')][_0x46762f('0x269a')][_0x3db1cd];_0x29633a['rpcVoiceQueues'][_0x576621['id']]=_0x22a232[_0x576621['id']];}return _0x1feab5[_0x46762f('0x13fa')]['getVoiceQueuesChannels']()['$promise'];})['then'](function(_0x39218c){const _0x2ddb0e=_0x3d985b;_0x29633a[_0x2ddb0e('0x2177')]=_0x39218c?_0x2cfb05()['keyBy'](_0x39218c[_0x2ddb0e('0x269a')]?_0x2cfb05()[_0x2ddb0e('0x1c33')](_0x39218c['rows'],function(_0x2d1599){const _0x173917=_0x2ddb0e;if(_0x2d1599[_0x173917('0x1345')]==='inbound'&&!_0x2d1599[_0x173917('0x9de')]&&_0x2cfb05()[_0x173917('0xc38')](_0x29633a[_0x173917('0x12b1')][_0x173917('0x269a')],{'name':_0x2d1599[_0x173917('0x1d3e')]}))return!![];return![];}):[],_0x2ddb0e('0x1c21')):{};})[_0x3d985b('0x1a80')](function(_0x12c151){const _0x2313e6=_0x3d985b;console[_0x2313e6('0xfc9')](_0x12c151);})[_0x3d985b('0x1951')](function(){const _0x596138=_0x3d985b;_0x2cfb05()[_0x596138('0xcc3')](_0x29633a['rpcVoiceQueuesChannels'],_0x29633a[_0x596138('0x200b')]);for(let _0x4584f2=0x0;_0x4584f2<_0x29633a[_0x596138('0x157f')]['length'];_0x4584f2+=0x1){delete _0x29633a['rpcVoiceQueuesChannels'][_0x29633a['deleteVoiceQueuesChannels'][_0x4584f2]];}_0x29633a['load']=![],_0x29633a[_0x596138('0x200b')]={},_0x29633a[_0x596138('0x157f')]=[],_0x29633a['getVoiceQueues']();});function _0x20a320(_0x13b5e9){const _0x212642=_0x3d985b;_0x29633a[_0x212642('0x193f')]=_0x13b5e9[_0x212642('0x240f')]?_0x13b5e9[_0x212642('0x240f')]:0x0,_0x29633a[_0x212642('0x20fd')]=_0x13b5e9?_0x2cfb05()[_0x212642('0x155c')](_0x13b5e9[_0x212642('0x269a')]?_0x13b5e9['rows']:[],'id'):{},_0x414e8a();}function _0xee1076(){const _0x5238f3=_0x3d985b;_0x29633a[_0x5238f3('0x2218')][_0x5238f3('0x1098')]=(_0x29633a[_0x5238f3('0x2218')]['page']-0x1)*_0x29633a[_0x5238f3('0x2218')][_0x5238f3('0x163f')],_0x29633a['promise']=_0x1feab5[_0x5238f3('0x557')][_0x5238f3('0x152a')](_0x29633a[_0x5238f3('0x2218')],_0x20a320)['$promise'];}let _0x3895cc=!![],_0x3ee665=0x1;_0x5de5ca[_0x3d985b('0xe83')](_0x3d985b('0x28b4'),function(_0x598678,_0x55a0ac){const _0x317551=_0x3d985b;_0x3895cc?_0x43e0e4(function(){_0x3895cc=![];}):(!_0x55a0ac&&(_0x3ee665=_0x29633a[_0x317551('0x2218')][_0x317551('0x1a43')]),_0x598678!==_0x55a0ac&&(_0x29633a[_0x317551('0x2218')]['page']=0x1),!_0x598678&&(_0x29633a[_0x317551('0x2218')][_0x317551('0x1a43')]=_0x3ee665),_0x29633a[_0x317551('0x680')]());});function _0x13efba(_0x1aaf15){return _0x2cfb05()['size'](_0x1aaf15);}function _0x414e8a(){const _0x30db52=_0x3d985b;_0x2cfb05()[_0x30db52('0x941')](_0x29633a[_0x30db52('0x20fd')],function(_0x2a473d,_0x599226){const _0x96789a=_0x30db52;_0x29633a[_0x96789a('0x1245')][_0x599226]&&(_0x29633a['voiceQueues'][_0x599226][_0x96789a('0x288a')]=_0x29633a[_0x96789a('0x1245')][_0x599226][_0x96789a('0x288a')]||0x0);});}function _0x413229(_0x1b6ba8){const _0x24ed57=_0x3d985b;_0x29633a[_0x24ed57('0x20fd')][_0x1b6ba8['id']]&&(_0x29633a[_0x24ed57('0x1245')][_0x1b6ba8['id']]&&(_0x29633a['rpcVoiceQueues'][_0x1b6ba8['id']]=_0x1b6ba8,_0x2cfb05()['merge'](_0x29633a[_0x24ed57('0x20fd')][_0x1b6ba8['id']],_0x2cfb05()['pick'](_0x1b6ba8,_0x1a0cbd))));}function _0x5bdb70(_0x5cea80){const _0x59047c=_0x3d985b;_0x5cea80[_0x59047c('0x1345')]===_0x59047c('0x14d8')&&(_0x5cea80[_0x59047c('0x9de')]?(delete _0x29633a[_0x59047c('0x2177')][_0x5cea80[_0x59047c('0x1c21')]],_0x29633a[_0x59047c('0x173f')]&&_0x29633a[_0x59047c('0x157f')][_0x59047c('0x1514')](_0x5cea80[_0x59047c('0x1c21')])):(_0x29633a[_0x59047c('0x2177')][_0x5cea80['uniqueid']]=_0x5cea80,_0x29633a[_0x59047c('0x173f')]&&(_0x29633a[_0x59047c('0x200b')][_0x5cea80[_0x59047c('0x1c21')]]=_0x5cea80)));}function _0x3a1bde(_0x641e4e){const _0xaa4ba0=_0x3d985b;!_0x2cfb05()['isNil'](_0x641e4e)&&(_0x29633a[_0xaa4ba0('0x1245')][_0x641e4e['id']]=_0x2cfb05()[_0xaa4ba0('0x1a08')](_0x641e4e,_0x1a0cbd));}function _0x131ebb(_0x5715b0){const _0x457dcf=_0x3d985b;!_0x2cfb05()[_0x457dcf('0x2863')](_0x5715b0)&&(_0x29633a[_0x457dcf('0x1245')][_0x5715b0['id']]&&_0x2cfb05()[_0x457dcf('0xcc3')](_0x29633a[_0x457dcf('0x1245')][_0x5715b0['id']],_0x2cfb05()[_0x457dcf('0x1a08')](_0x5715b0,_0x1a0cbd)),_0x29633a[_0x457dcf('0x20fd')][_0x5715b0['id']]&&_0x2cfb05()[_0x457dcf('0xcc3')](_0x29633a[_0x457dcf('0x20fd')][_0x5715b0['id']],_0x2cfb05()[_0x457dcf('0x1a08')](_0x5715b0,_0x1a0cbd)));}function _0x5d0a6c(_0x3791db){const _0x15ea97=_0x3d985b;!_0x2cfb05()[_0x15ea97('0x2863')](_0x3791db)&&(delete _0x29633a[_0x15ea97('0x1245')][_0x3791db['id']],delete _0x29633a['voiceQueues'][_0x3791db['id']]);}function _0x37e3a9(_0x360ae1){const _0x95d4c1=_0x3d985b;_0x2cfb05()['toInteger'](_0x360ae1[_0x95d4c1('0x122a')])===_0x1cf790[_0x95d4c1('0x26cd')]()['id']&&_0x29633a[_0x95d4c1('0x680')]();}_0x5de5ca[_0x3d985b('0x3d2')](_0x3d985b('0x1c3f'),function(){const _0xcd62c1=_0x3d985b;_0x1417c9[_0xcd62c1('0x1800')](_0xcd62c1('0xa60')),_0x1417c9[_0xcd62c1('0x1800')]('voice_queue_channel:save'),_0x1417c9[_0xcd62c1('0x1800')](_0xcd62c1('0x663')),_0x1417c9[_0xcd62c1('0x1800')]('userVoiceQueue:remove'),_0x1417c9['removeAllListeners'](_0xcd62c1('0x235a')),_0x1417c9['removeAllListeners'](_0xcd62c1('0x272d')),_0x1417c9[_0xcd62c1('0x1800')](_0xcd62c1('0xfda'));});}const _0x52f2b9=_0x38741e;_0x1a38b7[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$window',_0x36e6f4('0x586'),'api','Auth',_0x36e6f4('0x2661')];function _0x1a38b7(_0x4a025a,_0x444e20,_0x4a179f,_0x37c818,_0x983a97,_0x12324a,_0xad181f,_0x4a4489,_0xcdd57c){const _0x73fcc8=_0x36e6f4,_0x45bfc1=this,_0x448c83=['id',_0x73fcc8('0x4f0'),'mapAgentsId',_0x73fcc8('0x288a')];let _0x2619ce=!![];_0x45bfc1['whatsappQueues']={},_0x45bfc1[_0x73fcc8('0xec4')]=0x0,_0x45bfc1[_0x73fcc8('0xf30')]={},_0x45bfc1[_0x73fcc8('0x1fd8')]=[],_0x45bfc1[_0x73fcc8('0x1fa3')]=[],_0x45bfc1[_0x73fcc8('0x1f3f')]={},_0x45bfc1[_0x73fcc8('0x2218')]={'id':_0x4a4489[_0x73fcc8('0x26cd')]()['id'],'channel':_0x73fcc8('0x116e'),'fields':_0x73fcc8('0x28cc'),'limit':0xa,'page':0x1},_0x45bfc1[_0x73fcc8('0x1c05')]={'limit':0xa,'page':0x1},_0x45bfc1[_0x73fcc8('0x103b')]=_0x969b8a,_0x45bfc1[_0x73fcc8('0xfb1')]=_0x5838f3,_0x45bfc1['getSize']=_0x5cdf40,_0x45bfc1['getColorByChannel']=_0x26a1fc,_0x45bfc1['paginate']=_0x4baa1e,_0x45bfc1[_0x73fcc8('0xefb')]=_0x20ae73,_0x45bfc1[_0x73fcc8('0x1d74')]=_0x1b849b,_0x45bfc1[_0x73fcc8('0x15ef')]=_0x1a4f1e,_0x45bfc1[_0x73fcc8('0x1a2a')]=_0x117c12,_0x45bfc1[_0x73fcc8('0x2286')]=_0x25c657,_0x45bfc1[_0x73fcc8('0x1a3d')]=_0x5dc4b0,_0x45bfc1['onSaveWhatsappQueueChannel']=_0x434ba0,_0x45bfc1[_0x73fcc8('0x2306')]=_0x2e5205,_0xcdd57c['onWithoutApply'](_0x73fcc8('0x2476'),_0x45bfc1['onSaveQueue']),_0xcdd57c['onWithoutApply'](_0x73fcc8('0x26e3'),_0x45bfc1[_0x73fcc8('0x1d74')]),_0xcdd57c[_0x73fcc8('0xe82')]('whatsappQueue:update',_0x45bfc1[_0x73fcc8('0x15ef')]),_0xcdd57c[_0x73fcc8('0xe82')]('whatsappQueue:remove',_0x45bfc1[_0x73fcc8('0x1a2a')]),_0xcdd57c[_0x73fcc8('0xe82')](_0x73fcc8('0x842'),_0x45bfc1['onSaveUserWhatsappQueue']),_0xcdd57c[_0x73fcc8('0xe82')](_0x73fcc8('0x259b'),_0x45bfc1['onRemoveUserWhatsappQueue']),_0xcdd57c[_0x73fcc8('0xe82')](_0x73fcc8('0x2044'),_0x45bfc1[_0x73fcc8('0x1281')]),_0xcdd57c[_0x73fcc8('0xe82')](_0x73fcc8('0x77b'),_0x45bfc1[_0x73fcc8('0x2306')]),_0xad181f[_0x73fcc8('0x13fa')][_0x73fcc8('0xfb1')]()[_0x73fcc8('0xa44')][_0x73fcc8('0x1166')](function(_0x5e8545){const _0x116a1a=_0x73fcc8;_0x45bfc1[_0x116a1a('0xf30')]=_0x5e8545?_0x2cfb05()[_0x116a1a('0x155c')](_0x5e8545['rows']?_0x5e8545[_0x116a1a('0x269a')]:[],'id'):{};})[_0x73fcc8('0x1166')](function(){const _0x4e337c=_0x73fcc8;return _0xad181f[_0x4e337c('0x557')][_0x4e337c('0x152a')]({'id':_0x4a4489[_0x4e337c('0x26cd')]()['id'],'channel':_0x4e337c('0x116e')})[_0x4e337c('0xa44')];})['then'](function(_0x386097){const _0x1e7df4=_0x73fcc8;return _0x45bfc1[_0x1e7df4('0x12b1')]=_0x386097[_0x1e7df4('0x269a')],_0xad181f['rpc'][_0x1e7df4('0x24fe')]()[_0x1e7df4('0xa44')];})[_0x73fcc8('0x1166')](function(_0x41107e){const _0x1a10e4=_0x73fcc8,_0x3fca41=_0x2cfb05()['filter'](_0x41107e[_0x1a10e4('0x269a')],function(_0x30ff33){const _0x5853d1=_0x1a10e4;return _0x2cfb05()[_0x5853d1('0x1257')](_0x45bfc1[_0x5853d1('0x12b1')],{'id':_0x30ff33[_0x5853d1('0x1e04')]});});_0x41107e[_0x1a10e4('0x269a')]=_0x3fca41,_0x41107e[_0x1a10e4('0x240f')]=_0x3fca41[_0x1a10e4('0x264b')],_0x2cfb05()[_0x1a10e4('0xcc3')](_0x45bfc1[_0x1a10e4('0x1f3f')],_0x41107e?_0x2cfb05()[_0x1a10e4('0x155c')](_0x41107e[_0x1a10e4('0x269a')]?_0x41107e['rows']:[],'id'):{});})[_0x73fcc8('0x1a80')](function(_0x1638bf){const _0x29f13b=_0x73fcc8;console[_0x29f13b('0xfc9')](_0x1638bf);})['finally'](function(){const _0x2a84d1=_0x73fcc8;for(let _0x5595d9=0x0;_0x5595d9<_0x45bfc1[_0x2a84d1('0x1fa3')][_0x2a84d1('0x264b')];_0x5595d9+=0x1){delete _0x45bfc1['rpcWhatsappQueuesWaitingInteractions'][_0x45bfc1[_0x2a84d1('0x1fa3')][_0x5595d9]];}_0x2619ce=![],_0x45bfc1['deleteWhatsappQueuesWaitingInteractions']=[],_0x5838f3(),_0x4baa1e();});function _0x4baa1e(){const _0x27de31=_0x73fcc8,_0x98de31=(_0x45bfc1[_0x27de31('0x1c05')]['page']-0x1)*_0x45bfc1[_0x27de31('0x1c05')][_0x27de31('0x163f')];_0x45bfc1[_0x27de31('0x1fd8')]=_0x2cfb05()['orderBy'](_0x45bfc1[_0x27de31('0x1f3f')],[_0x27de31('0x3eb')],[_0x27de31('0x1dc3')]),_0x45bfc1[_0x27de31('0x1624')]=_0x2cfb05()[_0x27de31('0x3e5')](_0x45bfc1[_0x27de31('0x1fd8')],_0x98de31)[_0x27de31('0x233')](0x0,_0x45bfc1[_0x27de31('0x1c05')]['limit']);}function _0x969b8a(_0x13da5c){const _0x104fc1=_0x73fcc8;_0x45bfc1['whatsappQueuesTotal']=_0x13da5c['count']?_0x13da5c['count']:0x0,_0x45bfc1[_0x104fc1('0x147f')]=_0x13da5c?_0x2cfb05()[_0x104fc1('0x155c')](_0x13da5c['rows']?_0x13da5c[_0x104fc1('0x269a')]:[],'id'):{},_0x48328e();}function _0x5838f3(){const _0x12bda0=_0x73fcc8;_0x45bfc1[_0x12bda0('0x2218')][_0x12bda0('0x1098')]=(_0x45bfc1['query'][_0x12bda0('0x1a43')]-0x1)*_0x45bfc1[_0x12bda0('0x2218')]['limit'],_0x45bfc1[_0x12bda0('0x1f48')]=_0xad181f['user'][_0x12bda0('0x152a')](_0x45bfc1[_0x12bda0('0x2218')],_0x969b8a)[_0x12bda0('0xa44')];}let _0x2d9485=!![],_0x3d68f3=0x1;_0x4a025a[_0x73fcc8('0xe83')](_0x73fcc8('0x28b4'),function(_0xaa5c5c,_0x45365c){const _0x504b8a=_0x73fcc8;_0x2d9485?_0x444e20(function(){_0x2d9485=![];}):(!_0x45365c&&(_0x3d68f3=_0x45bfc1['query']['page']),_0xaa5c5c!==_0x45365c&&(_0x45bfc1[_0x504b8a('0x2218')][_0x504b8a('0x1a43')]=0x1),!_0xaa5c5c&&(_0x45bfc1[_0x504b8a('0x2218')][_0x504b8a('0x1a43')]=_0x3d68f3),_0x45bfc1[_0x504b8a('0xfb1')]());});function _0x5cdf40(_0x202e02){const _0x439a75=_0x73fcc8;return _0x2cfb05()[_0x439a75('0x2340')](_0x202e02);}function _0x48328e(){const _0x25b39b=_0x73fcc8;_0x2cfb05()[_0x25b39b('0x941')](_0x45bfc1[_0x25b39b('0x147f')],function(_0x55041c,_0x201482){const _0xfd985b=_0x25b39b;_0x45bfc1[_0xfd985b('0xf30')][_0x201482]&&(_0x45bfc1['whatsappQueues'][_0x201482][_0xfd985b('0x288a')]=_0x45bfc1[_0xfd985b('0xf30')][_0x201482][_0xfd985b('0x288a')]||0x0);});}function _0x20ae73(_0x430bea){const _0x23d6b3=_0x73fcc8;_0x45bfc1[_0x23d6b3('0x147f')][_0x430bea['id']]&&(_0x45bfc1[_0x23d6b3('0xf30')][_0x430bea['id']]&&(_0x2cfb05()[_0x23d6b3('0xcc3')](_0x45bfc1[_0x23d6b3('0xf30')][_0x430bea['id']],_0x2cfb05()[_0x23d6b3('0x1a08')](_0x430bea,_0x448c83)),_0x2cfb05()[_0x23d6b3('0xcc3')](_0x45bfc1['whatsappQueues'][_0x430bea['id']],_0x2cfb05()['pick'](_0x430bea,_0x448c83))));}function _0x1b849b(_0x752ef0){const _0x4c0259=_0x73fcc8;!_0x2cfb05()['isNil'](_0x752ef0)&&(_0x45bfc1[_0x4c0259('0xf30')][_0x752ef0['id']]=_0x2cfb05()['pick'](_0x752ef0,_0x448c83));}function _0x1a4f1e(_0x504f29){const _0x150e70=_0x73fcc8;!_0x2cfb05()['isNil'](_0x504f29)&&(_0x45bfc1[_0x150e70('0xf30')][_0x504f29['id']]&&_0x2cfb05()[_0x150e70('0xcc3')](_0x45bfc1[_0x150e70('0xf30')][_0x504f29['id']],_0x2cfb05()['pick'](_0x504f29,_0x448c83)),_0x45bfc1[_0x150e70('0x147f')][_0x504f29['id']]&&_0x2cfb05()[_0x150e70('0xcc3')](_0x45bfc1[_0x150e70('0x147f')][_0x504f29['id']],_0x2cfb05()['pick'](_0x504f29,_0x448c83)));}function _0x117c12(_0x1d6fa2){const _0x3a8c21=_0x73fcc8;!_0x2cfb05()[_0x3a8c21('0x2863')](_0x1d6fa2)&&(delete _0x45bfc1[_0x3a8c21('0xf30')][_0x1d6fa2['id']],delete _0x45bfc1[_0x3a8c21('0x147f')][_0x1d6fa2['id']]);}function _0x25c657(_0x336b91){const _0x429a47=_0x73fcc8;_0x2cfb05()[_0x429a47('0x1edd')](_0x336b91[_0x429a47('0x122a')])===_0x4a4489['getCurrentUser']()['id']&&_0x45bfc1['getWhatsappQueues']();}function _0x5dc4b0(_0x1f75e3){const _0x1d247d=_0x73fcc8;_0x2cfb05()[_0x1d247d('0x1edd')](_0x1f75e3[_0x1d247d('0x122a')])===_0x4a4489['getCurrentUser']()['id']&&_0x45bfc1[_0x1d247d('0xfb1')]();}function _0x434ba0(_0x13bd08){const _0x222728=_0x73fcc8;_0x45bfc1[_0x222728('0x147f')][_0x13bd08[_0x222728('0x1e04')]]&&(_0x45bfc1[_0x222728('0x1f3f')][_0x13bd08['id']]=_0x13bd08,_0x4baa1e());}function _0x2e5205(_0xfb1e0e){const _0x19ab89=_0x73fcc8;delete _0x45bfc1[_0x19ab89('0x1f3f')][_0xfb1e0e['id']],_0x2619ce&&_0x45bfc1[_0x19ab89('0x1fa3')][_0x19ab89('0x1514')](_0xfb1e0e['id']),_0x4baa1e();}function _0x26a1fc(_0x240598){const _0x43c04d=_0x73fcc8;switch(_0x240598){case _0x43c04d('0xde2'):return _0x43c04d('0x2027');case _0x43c04d('0x1bfa'):return'teal-bg';case'sms':return _0x43c04d('0x78a');case _0x43c04d('0x116e'):return'lime-A700-bg';case _0x43c04d('0x26c'):return _0x43c04d('0x467');case _0x43c04d('0x1fc7'):return _0x43c04d('0xc56');default:return _0x43c04d('0xa10');}}_0x4a025a['$on']('$destroy',function(){const _0x3672cb=_0x73fcc8;_0xcdd57c[_0x3672cb('0x1800')](_0x3672cb('0x2476')),_0xcdd57c[_0x3672cb('0x1800')]('whatsappQueue:save'),_0xcdd57c['removeAllListeners'](_0x3672cb('0x927')),_0xcdd57c[_0x3672cb('0x1800')](_0x3672cb('0x1c7a')),_0xcdd57c['removeAllListeners'](_0x3672cb('0x842')),_0xcdd57c[_0x3672cb('0x1800')]('userWhatsappQueue:remove'),_0xcdd57c[_0x3672cb('0x1800')](_0x3672cb('0x2044')),_0xcdd57c[_0x3672cb('0x1800')]('whatsapp_queue_waiting_interaction:remove');});}const _0x4e9482=_0x1a38b7;_0xa0702d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$window','$translate',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x2661'),'toasty',_0x36e6f4('0x102a')];function _0xa0702d(_0x17e119,_0x5c7790,_0x364ddb,_0x5c38a0,_0xdc4e07,_0x180777,_0x22ab38,_0x28ca89,_0x2516b6,_0x3996a5,_0x4ad41e){const _0x11f5c4=_0x36e6f4,_0x542b4e=this;_0x542b4e[_0x11f5c4('0x557')]=_0x28ca89[_0x11f5c4('0x26cd')](),_0x542b4e[_0x11f5c4('0x5c9')]={},_0x542b4e[_0x11f5c4('0xf8a')]={},_0x542b4e[_0x11f5c4('0xb38')]={'count':0x0,'rows':[]},_0x542b4e[_0x11f5c4('0x2712')]={'count':0x0,'rows':[]},_0x542b4e[_0x11f5c4('0x2218')]={'includeAll':!![],'sort':_0x11f5c4('0x14dc'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x542b4e[_0x11f5c4('0x1291')]={'fields':[{'name':'Id','column':'id','type':_0x11f5c4('0xc45')},{'name':_0x11f5c4('0x21a4'),'column':_0x11f5c4('0x21a4'),'type':'autocomplete','options':{'searchFields':[_0x11f5c4('0x18cb'),_0x11f5c4('0xeb0'),_0x11f5c4('0x66f')],'route':{'model':'cmContact','action':_0x11f5c4('0xd83'),'params':{'fields':_0x11f5c4('0x18eb'),'Contact':_0x11f5c4('0x145b'),'nolimit':!![]}},'extraOperators':[_0x11f5c4('0x2836')],'excludedOperators':[_0x11f5c4('0x2646')]}},{'name':_0x11f5c4('0xe1'),'column':_0x11f5c4('0x8d2'),'type':_0x11f5c4('0x1640'),'options':{'excludedOperators':['$eq','$ne']}},{'name':_0x11f5c4('0x28f6'),'column':'closed','type':_0x11f5c4('0x88a'),'values':[{'id':0x0,'translate':_0x11f5c4('0xdeb')},{'id':0x1,'translate':_0x11f5c4('0x58f')}],'options':{'excludedOperators':['$ne']}},{'name':_0x11f5c4('0x89b'),'column':_0x11f5c4('0x1a6f'),'type':_0x11f5c4('0x1a01'),'options':{'table':'i','route':{'model':_0x11f5c4('0x557'),'action':_0x11f5c4('0xd83'),'params':{'role':_0x11f5c4('0x1eff'),'fields':_0x11f5c4('0xce1'),'nolimit':!![]}},'searchFields':[_0x11f5c4('0x6e1'),'name'],'extraOperators':[_0x11f5c4('0x2836')],'excludedOperators':[_0x11f5c4('0x2646')]}},{'name':_0x11f5c4('0x1758'),'column':_0x11f5c4('0x18fe'),'type':_0x11f5c4('0x2162'),'options':{'route':{'model':'user','action':_0x11f5c4('0x1f63'),'params':{'id':_0x542b4e[_0x11f5c4('0x557')]['id'],'nolimit':!![]}}}},{'name':'Tags','column':_0x11f5c4('0x1b35'),'type':_0x11f5c4('0x2162'),'options':{'route':{'model':_0x11f5c4('0x1446'),'action':_0x11f5c4('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':[_0x11f5c4('0x18d')]}},{'name':'Start\x20Date','column':_0x11f5c4('0x262'),'type':_0x11f5c4('0x1643'),'options':{'excludedOperators':['$ne']}},{'name':'Read','column':_0x11f5c4('0x723'),'type':_0x11f5c4('0x88a'),'values':[{'id':0x1,'translate':_0x11f5c4('0x1057')},{'id':0x0,'translate':_0x11f5c4('0x2c8')}],'options':{'excludedOperators':[_0x11f5c4('0x2646')]}}]},_0x542b4e[_0x11f5c4('0xb1f')]='blue-grey',_0x542b4e[_0x11f5c4('0xae0')]=_0x38f51c,_0x542b4e[_0x11f5c4('0x103b')]=_0x1b2a66,_0x542b4e[_0x11f5c4('0x1ee3')]=_0x191e12,_0x542b4e[_0x11f5c4('0x12f')]=_0x2420ed,_0x542b4e[_0x11f5c4('0x1d02')]=_0x56b3f1,_0x542b4e[_0x11f5c4('0xb52')]=_0x1ff33c,_0x542b4e[_0x11f5c4('0x250c')]=_0x2734bd,_0x542b4e[_0x11f5c4('0x2253')]=_0x5b6bc3,_0x542b4e[_0x11f5c4('0x2695')]=_0x547a6c,_0x542b4e[_0x11f5c4('0xb78')]=_0x32a7b6,_0x542b4e[_0x11f5c4('0x109e')]=_0x5adea3,_0x542b4e[_0x11f5c4('0x3c5')]=_0x1c97f6,_0x542b4e[_0x11f5c4('0x138b')]=_0x243324;function _0x38f51c(_0x126051,_0x26636a){const _0x20153c=_0x11f5c4;return _0x542b4e[_0x20153c('0x5c9')]=_0x126051,_0x542b4e['setting']=_0x26636a,_0x22ab38[_0x20153c('0x557')][_0x20153c('0xd83')+_0x2cfb05()[_0x20153c('0x114b')](_0x20153c('0xd6c'))]({'id':_0x542b4e[_0x20153c('0x557')]['id'],'nolimit':!![]})[_0x20153c('0xa44')][_0x20153c('0x1166')](function(_0x3c092c){const _0x3a8e1b=_0x20153c;return _0x542b4e[_0x3a8e1b('0xd6c')]=_0x3c092c||{'count':0x0,'rows':[]},_0x22ab38[_0x3a8e1b('0x1446')][_0x3a8e1b('0xd83')]()['$promise'];})['then'](function(_0x10d30f){_0x542b4e['tags']=_0x10d30f||{'count':0x0,'rows':[]};})[_0x20153c('0x1166')](function(){_0x542b4e['quickFilters']=_0x47ee03();})[_0x20153c('0x1a80')](function(_0xba12e5){const _0x1ded1b=_0x20153c;console[_0x1ded1b('0xfc9')](_0xba12e5);})[_0x20153c('0x1951')](function(){const _0x2b7d1f=_0x20153c;let _0x5da222=_0xdc4e07[_0x2b7d1f('0x275')]['getItem'](_0x2b7d1f('0x1b')+_0x542b4e[_0x2b7d1f('0x557')]['id']);if(_0x5da222)try{_0x5da222=JSON[_0x2b7d1f('0x1295')](_0x5da222);if(_0x5da222[_0x2b7d1f('0x2218')]){_0x542b4e[_0x2b7d1f('0x2218')]=_0x2cfb05()[_0x2b7d1f('0xcc3')](_0x542b4e[_0x2b7d1f('0x2218')],_0x5da222[_0x2b7d1f('0x2218')]);if(_0x2cfb05()['isEmpty'](_0x542b4e[_0x2b7d1f('0xd6c')][_0x2b7d1f('0x269a')]))_0x542b4e[_0x2b7d1f('0x2218')][_0x2b7d1f('0x18fe')]=[];else _0x2cfb05()['isEmpty'](_0x542b4e[_0x2b7d1f('0x2218')][_0x2b7d1f('0x18fe')])&&(_0x542b4e[_0x2b7d1f('0x2218')]['FaxAccountId']=_0x2cfb05()(_0x542b4e['faxAccounts']['rows'])[_0x2b7d1f('0x2563')]('id')['take']()[_0x2b7d1f('0x18e0')]());_0x542b4e[_0x2b7d1f('0x2218')][_0x2b7d1f('0x1aba')]&&_0x542b4e[_0x2b7d1f('0x2218')]['sort'][_0x2b7d1f('0x2379')]('lastMessage')>=0x0&&(_0x542b4e['query']=_0x2cfb05()[_0x2b7d1f('0x1414')](_0x542b4e[_0x2b7d1f('0x2218')],_0x2b7d1f('0x1aba'))),_0x542b4e[_0x2b7d1f('0x2218')][_0x2b7d1f('0x220e')]=!![],_0x542b4e[_0x2b7d1f('0x7cc')]=_0x542b4e['query'][_0x2b7d1f('0x1c33')]?!![]:![];}}catch(_0x2530bd){console[_0x2b7d1f('0xfc9')](_0x2530bd);}else{const _0xb54eba={'$gte':_0x24273b()()['startOf'](_0x2b7d1f('0x2e7'))[_0x2b7d1f('0x13f2')](0x0,!![])['format'](),'$lte':_0x24273b()()[_0x2b7d1f('0x2589')]('month')[_0x2b7d1f('0x13f2')](0x0,!![])[_0x2b7d1f('0x128a')]()},_0x38d255={'FaxAccountId':_0x2cfb05()['map'](_0x542b4e[_0x2b7d1f('0xd6c')][_0x2b7d1f('0x269a')],'id'),'createdAt':_0xb54eba};_0x542b4e['query']=_0x2cfb05()[_0x2b7d1f('0xcc3')](_0x542b4e[_0x2b7d1f('0x2218')],_0x38d255);}_0x2516b6['on'](_0x2b7d1f('0x1dc2'),_0xb22a3e),_0x2516b6['on'](_0x2b7d1f('0x109c'),_0xb22a3e),_0x2516b6['on']('faxInteractionTags:save',_0xe83795),_0x2516b6['on'](_0x2b7d1f('0x1c76'),_0x4610b6),_0x2516b6['on'](_0x2b7d1f('0x1ceb'),_0x4610b6),_0x2516b6['on'](_0x2b7d1f('0x27a3'),_0x59d304),_0x2516b6['on'](_0x2b7d1f('0xdfd'),_0x3d70d2),_0x191e12(_0x542b4e[_0x2b7d1f('0x2218')][_0x2b7d1f('0x1a43')]);});}function _0x47ee03(){const _0xf53599=_0x11f5c4;return[{'name':'Start\x20Date','key':_0xf53599('0x262'),'type':'date','label':_0xf53599('0x16d9')},{'name':'Messages','key':_0xf53599('0x123'),'type':_0xf53599('0x88a'),'label':'DASHBOARDS.SELECT_READ_UNREAD','customOptions':[{'value':0x0,'translate':_0xf53599('0x2c8')},{'value':0x1,'translate':'DASHBOARDS.READ'},{'value':null,'translate':'DASHBOARDS.ALL'}]},{'name':_0xf53599('0x28f6'),'key':_0xf53599('0xa5b'),'type':_0xf53599('0x88a'),'label':_0xf53599('0xe32'),'customOptions':[{'value':0x0,'translate':_0xf53599('0xdeb')},{'value':0x1,'translate':_0xf53599('0x58f')},{'value':null,'translate':_0xf53599('0x2150')}]},{'name':_0xf53599('0x1758'),'key':'FaxAccountId','type':_0xf53599('0x2162'),'label':_0xf53599('0x6da'),'options':_0x542b4e[_0xf53599('0xd6c')]['rows'],'clearAll':![]},{'name':_0xf53599('0x89b'),'key':_0xf53599('0x122a'),'type':_0xf53599('0x88a'),'label':'DASHBOARDS.SELECT_AGENT','customOptions':[{'value':_0x542b4e[_0xf53599('0x557')]['id'],'translate':'DASHBOARDS.ME'},{'value':'null','translate':_0xf53599('0x216b')},{'value':undefined,'translate':_0xf53599('0x2150')}]},{'name':_0xf53599('0x1b35'),'key':_0xf53599('0x1446'),'type':_0xf53599('0x2162'),'label':_0xf53599('0x1669'),'options':_0x542b4e[_0xf53599('0xb38')]['rows'],'placeholder':'DASHBOARDS.TAGS'}];}function _0x1b2a66(_0x1d7844){const _0x106d60=_0x11f5c4;_0x542b4e[_0x106d60('0x293')]=![],_0x542b4e[_0x106d60('0x2712')]=_0x1d7844||{'count':0x0,'rows':[]};for(let _0x5c1c95=0x0;_0x5c1c95<_0x542b4e[_0x106d60('0x2712')][_0x106d60('0x269a')][_0x106d60('0x264b')];_0x5c1c95+=0x1){_0x2734bd(_0x542b4e[_0x106d60('0x2712')][_0x106d60('0x269a')][_0x5c1c95]);}}function _0x191e12(_0x2fbced){const _0x519fef=_0x11f5c4;_0x542b4e[_0x519fef('0x293')]=!![];!_0x2fbced&&(_0x542b4e[_0x519fef('0x2218')][_0x519fef('0x1a43')]=0x1);_0x542b4e['query']['offset']=(_0x542b4e[_0x519fef('0x2218')][_0x519fef('0x1a43')]-0x1)*_0x542b4e[_0x519fef('0x2218')][_0x519fef('0x163f')];let _0x29e8b9=_0xdc4e07[_0x519fef('0x275')][_0x519fef('0x15f7')]('motion2.home.fax:'+_0x542b4e[_0x519fef('0x557')]['id']);_0x29e8b9=_0x29e8b9?JSON['parse'](_0x29e8b9):{},_0x29e8b9[_0x519fef('0x2218')]=_0x542b4e[_0x519fef('0x2218')],_0xdc4e07[_0x519fef('0x275')]['setItem'](_0x519fef('0x1b')+_0x542b4e[_0x519fef('0x557')]['id'],JSON['stringify'](_0x29e8b9)),_0x542b4e['promise']=_0x22ab38[_0x519fef('0x1342')][_0x519fef('0xd83')](_0x542b4e[_0x519fef('0x2218')],_0x1b2a66)[_0x519fef('0xa44')];}function _0x2420ed(_0x55c0b3,_0x402748){const _0x4da13c=_0x11f5c4;_0x17e119[_0x4da13c('0x23ac')]['vm'][_0x4da13c('0x126e')](_0x4da13c('0x1fc7'),_0x402748);}function _0x56b3f1(_0x5bf575,_0x105859,_0x5eccaa){const _0x13884c=_0x11f5c4;_0x22ab38[_0x13884c('0x1342')][_0x13884c('0x2ad')]({'id':_0x105859['id'],'attachments':_0x5eccaa})[_0x13884c('0xa44')][_0x13884c('0x1166')](function(_0x2aa301){const _0x220b46=_0x13884c,_0x9e6de4=[_0x2aa301[_0x220b46('0x20ed')]],_0xd9c6e=_0x220b46('0x1319')+_0x105859['id']+_0x220b46('0x806'),_0x7a5f2c=new Blob(_0x9e6de4,{'type':_0x2aa301[_0x220b46('0x1345')]}),_0x5b41d0=window['document'][_0x220b46('0xdd')]('a');_0x5b41d0[_0x220b46('0xffd')](_0x220b46('0x14f9'),URL[_0x220b46('0x215a')](_0x7a5f2c)),_0x5b41d0[_0x220b46('0xffd')](_0x220b46('0x2ad'),_0xd9c6e),document[_0x220b46('0x8d2')][_0x220b46('0x21a')](_0x5b41d0),_0x5b41d0[_0x220b46('0x3b4')]();})[_0x13884c('0x1a80')](function(_0x5b4fa7){const _0x2bb892=_0x13884c;if(_0x5b4fa7[_0x2bb892('0x25f4')]&&_0x5b4fa7[_0x2bb892('0x25f4')]['errors']&&_0x5b4fa7[_0x2bb892('0x25f4')]['errors'][_0x2bb892('0x264b')])for(let _0x31b76f=0x0;_0x31b76f<_0x5b4fa7[_0x2bb892('0x25f4')][_0x2bb892('0x61a')][_0x2bb892('0x264b')];_0x31b76f+=0x1){_0x3996a5[_0x2bb892('0xfc9')]({'title':_0x5b4fa7[_0x2bb892('0x25f4')]['errors'][_0x31b76f][_0x2bb892('0x1345')],'msg':_0x5b4fa7[_0x2bb892('0x25f4')][_0x2bb892('0x61a')][_0x31b76f]['message']});}else _0x3996a5[_0x2bb892('0xfc9')]({'title':_0x5b4fa7['status']?_0x2bb892('0x1e21')+_0x5b4fa7[_0x2bb892('0x52d')]+_0x2bb892('0x11e1')+_0x5b4fa7[_0x2bb892('0xe1b')]:'downloadFaxInteraction','msg':_0x5b4fa7['data']?JSON['stringify'](_0x5b4fa7[_0x2bb892('0x25f4')][_0x2bb892('0x1e70')]):_0x5b4fa7['toString']()});});}function _0x1ff33c(_0x1e5024,_0x4ee83a){const _0x17e6a0=_0x11f5c4,_0x6d38ea=_0x542b4e[_0x17e6a0('0x557')][_0x17e6a0('0x2540')]||_0x542b4e['user'][_0x17e6a0('0x1c5c')]||_0x542b4e[_0x17e6a0('0x557')]['mailPause']||_0x542b4e[_0x17e6a0('0x557')][_0x17e6a0('0x287f')]||_0x542b4e[_0x17e6a0('0x557')]['faxPause'],_0x401f5d=!_0x4ee83a[_0x17e6a0('0x1758')][_0x17e6a0('0x10d0')];_0x364ddb[_0x17e6a0('0x1f80')]({'controller':_0x17e6a0('0xa39'),'controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular['element'](_0x5c38a0[_0x17e6a0('0x8d2')]),'clickOutsideToClose':_0x401f5d,'escapeToClose':_0x401f5d,'onRemoving':function(){const _0x174171=_0x17e6a0;_0x542b4e[_0x174171('0x557')]&&_0x4ee83a['Account'][_0x174171('0x10d0')]&&!_0x6d38ea&&_0x22ab38['user'][_0x174171('0x20eb')]({'id':_0x542b4e['user']['id']})['$promise'][_0x174171('0x1a80')](function(_0x19a13a){const _0x29f2d7=_0x174171;console[_0x29f2d7('0xfc9')](_0x19a13a);});},'locals':{'user':_0x542b4e['user'],'channel':_0x17e6a0('0x1fc7'),'interaction':_0x4ee83a}});}function _0x2734bd(_0x5cc3ba){const _0xaf9daf=_0x11f5c4;_0x5cc3ba[_0xaf9daf('0x21a4')]?(_0x5cc3ba[_0xaf9daf('0x15cf')]=(_0x5cc3ba[_0xaf9daf('0x21a4')][_0xaf9daf('0x18cb')]||'')+'\x20'+(_0x5cc3ba[_0xaf9daf('0x21a4')][_0xaf9daf('0xeb0')]||''),_0x5cc3ba[_0xaf9daf('0x1ce2')]=_0x5cc3ba[_0xaf9daf('0x21a4')][_0xaf9daf('0x1fc7')]):_0x5cc3ba['contactName']=_0x180777[_0xaf9daf('0x25cc')]('DASHBOARDS.UNKNOWN');}function _0x5b6bc3(_0x38df5b){const _0x338bf9=_0x11f5c4;if(_0x38df5b['UserId'])return _0x38df5b['UserId']===_0x542b4e[_0x338bf9('0x557')]['id']?_0x180777[_0x338bf9('0x25cc')](_0x338bf9('0x15ae')):_0x38df5b[_0x338bf9('0x121b')]['fullname']+'\x20<'+_0x38df5b['Owner'][_0x338bf9('0x1eef')]+'>';return _0x180777[_0x338bf9('0x25cc')](_0x338bf9('0x216b'));}function _0x547a6c(_0x3c8306){const _0x4806bb=_0x11f5c4;if(_0x3c8306['Account'])return _0x3c8306[_0x4806bb('0x1758')]['key'];return _0x180777[_0x4806bb('0x25cc')]('DASHBOARDS.UNKNOWN');}function _0x32a7b6(_0x3574fa,_0x57097e){const _0x268730=_0x11f5c4;_0x364ddb[_0x268730('0x1f80')]({'controller':_0x268730('0x14e2'),'controllerAs':'vm','templateUrl':_0x2d50de,'parent':angular['element'](_0x5c38a0[_0x268730('0x8d2')]),'clickOutsideToClose':![],'locals':{'account':_0x57097e,'message':{},'type':_0x268730('0xd11'),'interaction':{}},'fullscreen':!![]})[_0x268730('0x1166')](function(_0x5e51ea){const _0x25d67f=_0x268730;if(_0x5e51ea){if(_0x5e51ea[_0x25d67f('0x1e70')]&&_0x5e51ea['message'][_0x25d67f('0x34f')]){const _0x551a91={'channel':_0x25d67f('0x1fc7'),'account':_0x57097e,'message':_0x5e51ea[_0x25d67f('0x1e70')],'contact':_0x5e51ea[_0x25d67f('0x26db')]};_0x4ad41e[_0x25d67f('0x126a')](_0x551a91);}else{const _0x30ac49=_0x5e51ea;return _0x22ab38['faxAccount']['send']({'id':_0x57097e['id']},_0x30ac49)[_0x25d67f('0xa44')]['then'](function(_0x62ce7f){const _0x1eb357=_0x25d67f;_0x3996a5[_0x1eb357('0x103b')]({'title':_0x1eb357('0x11ac'),'msg':'Message\x20has\x20been\x20sent!'}),_0x17e119[_0x1eb357('0x23ac')]['vm'][_0x1eb357('0x126e')](_0x1eb357('0x1fc7'),_0x62ce7f);})[_0x25d67f('0x1a80')](function(_0x559ae7){const _0x4d9a52=_0x25d67f;if(_0x559ae7[_0x4d9a52('0x25f4')]&&_0x559ae7[_0x4d9a52('0x25f4')][_0x4d9a52('0x61a')]&&_0x559ae7[_0x4d9a52('0x25f4')][_0x4d9a52('0x61a')][_0x4d9a52('0x264b')])for(let _0x13a956=0x0;_0x13a956<_0x559ae7[_0x4d9a52('0x25f4')][_0x4d9a52('0x61a')][_0x4d9a52('0x264b')];_0x13a956++){_0x3996a5[_0x4d9a52('0xfc9')]({'title':_0x559ae7[_0x4d9a52('0x25f4')][_0x4d9a52('0x61a')][_0x13a956]['type'],'msg':_0x559ae7['data'][_0x4d9a52('0x61a')][_0x13a956][_0x4d9a52('0x1e70')]});}else _0x3996a5[_0x4d9a52('0xfc9')]({'title':_0x4d9a52('0x73e'),'msg':_0x559ae7[_0x4d9a52('0x25f4')]?JSON[_0x4d9a52('0xbac')](_0x559ae7[_0x4d9a52('0x25f4')]):_0x559ae7[_0x4d9a52('0x1e70')]||_0x559ae7[_0x4d9a52('0x1586')]()});});}}});}function _0x59d304(_0xcca671){const _0x40b866=_0x11f5c4;let _0x656e90;const _0x2cf8c0=_0x2cfb05()[_0x40b866('0xc38')](_0x542b4e[_0x40b866('0x2712')]['rows'],{'id':_0xcca671[_0x40b866('0x6cc')]});_0x2cf8c0&&_0x2cf8c0[_0x40b866('0x1bc7')]&&(_0x656e90=_0x2cfb05()[_0x40b866('0xc38')](_0x2cf8c0[_0x40b866('0x1bc7')],{'id':_0xcca671[_0x40b866('0x122a')]}),!_0x656e90&&_0x2cf8c0[_0x40b866('0x1bc7')]['push']({'id':_0xcca671['UserId']}));}function _0x3d70d2(_0x3462f7){const _0x35cf51=_0x11f5c4,_0xf08344=_0x2cfb05()['find'](_0x542b4e[_0x35cf51('0x2712')][_0x35cf51('0x269a')],{'id':_0x3462f7[_0x35cf51('0x6cc')]});_0xf08344&&_0xf08344[_0x35cf51('0x1bc7')]&&_0x2cfb05()[_0x35cf51('0x127f')](_0xf08344[_0x35cf51('0x1bc7')],{'id':_0x3462f7[_0x35cf51('0x122a')]});}function _0xb22a3e(_0x1defb7){const _0x41c402=_0x11f5c4;if(_0x1defb7){const _0x3e2c38=_0x2cfb05()[_0x41c402('0xc38')](_0x542b4e['faxInteractions'][_0x41c402('0x269a')],{'id':_0x1defb7['id']});if(_0x3e2c38){_0x3e2c38['Users']=[];_0x1defb7[_0x41c402('0xa5b')]&&(_0x3e2c38[_0x41c402('0x723')]=0x0);if(_0x542b4e[_0x41c402('0x2218')][_0x41c402('0x1aba')]){const _0x1153ca=_0x2cfb05()[_0x41c402('0x1783')](_0x542b4e[_0x41c402('0x2218')][_0x41c402('0x1aba')],'-')?_0x41c402('0x1dc3'):_0x41c402('0x17d');_0x542b4e[_0x41c402('0x2712')][_0x41c402('0x269a')]=_0x2cfb05()[_0x41c402('0xe63')](_0x542b4e[_0x41c402('0x2712')][_0x41c402('0x269a')],_0x2cfb05()[_0x41c402('0x19db')](_0x542b4e[_0x41c402('0x2218')][_0x41c402('0x1aba')],'-'),_0x1153ca);}_0x2cfb05()[_0x41c402('0xcc3')](_0x3e2c38,_0x2cfb05()[_0x41c402('0x1a08')](_0x1defb7,_0x2cfb05()[_0x41c402('0x14a4')](_0x3e2c38)));}else _0x191e12(_0x542b4e[_0x41c402('0x2218')][_0x41c402('0x1a43')]);}}function _0xe83795(_0x568086){const _0x8e24db=_0x11f5c4;if(_0x568086){const _0xf766c1=_0x2cfb05()[_0x8e24db('0xc38')](_0x542b4e[_0x8e24db('0x2712')][_0x8e24db('0x269a')],{'id':_0x568086['id']});_0xf766c1&&(_0xf766c1[_0x8e24db('0x21c2')]=_0x568086[_0x8e24db('0xb38')]||[],_0x2cfb05()[_0x8e24db('0xcc3')](_0xf766c1,_0x2cfb05()[_0x8e24db('0x1a08')](_0x568086,_0x2cfb05()[_0x8e24db('0x14a4')](_0xf766c1))));}}function _0x4610b6(_0x221698){const _0x45470d=_0x11f5c4;if(_0x221698&&!_0x221698[_0x45470d('0x1908')]){const _0x32b76b=_0x2cfb05()['find'](_0x542b4e[_0x45470d('0x2712')][_0x45470d('0x269a')],{'id':_0x221698[_0x45470d('0x6cc')]});if(_0x32b76b){const _0x570a4c=_0x2cfb05()[_0x45470d('0xc38')](_0x32b76b['Messages'],{'id':_0x221698['id']});_0x570a4c?_0x2cfb05()[_0x45470d('0xcc3')](_0x570a4c,_0x2cfb05()[_0x45470d('0x1a08')](_0x221698,_0x2cfb05()[_0x45470d('0x14a4')](_0x570a4c))):(_0x2cfb05()[_0x45470d('0x2863')](_0x32b76b['Messages'])&&(_0x32b76b[_0x45470d('0x116c')]={'count':0x0}),!_0x221698['read']&&(_0x32b76b['Messages'][_0x45470d('0x240f')]+=0x1));}}}function _0x5adea3(){_0x542b4e['isSearchBarVisible']=![];}function _0x1c97f6(){const _0xff5d45=_0x11f5c4;_0x542b4e[_0xff5d45('0x7cc')]=!![];}function _0x243324(){const _0x1b2389=_0x11f5c4;_0x542b4e[_0x1b2389('0x7cc')]=![],_0x364ddb[_0x1b2389('0x1f80')]({'controller':_0x1b2389('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0x1b2389('0x1194')](_0x5c38a0['body']),'clickOutsideToClose':![],'locals':{'color':_0x542b4e[_0x1b2389('0xb1f')],'fields':_0x542b4e['advancedSearch'][_0x1b2389('0xfe2')],'storagePath':_0x1b2389('0x3')},'fullscreen':!![]})[_0x1b2389('0x1166')](function(_0x368aac){const _0x52c011=_0x1b2389;_0x542b4e[_0x52c011('0x2218')]['search']=_0x368aac===![]?undefined:_0x368aac;if(_0x542b4e['query'][_0x52c011('0xe07')]||_0x368aac===![])_0x191e12();})[_0x1b2389('0x1a80')](function(_0x2b24f8){const _0x4e4886=_0x1b2389;_0x3996a5[_0x4e4886('0xfc9')]({'title':_0x4e4886('0x2272'),'msg':_0x2b24f8[_0x4e4886('0x25f4')]?JSON[_0x4e4886('0xbac')](_0x2b24f8[_0x4e4886('0x25f4')][_0x4e4886('0x1e70')]):_0x2b24f8[_0x4e4886('0x1586')]()});});}let _0x404ce0=!![],_0x18919d=0x1;_0x17e119[_0x11f5c4('0xe83')](_0x11f5c4('0x12d8'),function(_0xf5e4f1,_0x278755){const _0x754fa3=_0x11f5c4;_0x404ce0?_0x5c7790(function(){_0x404ce0=![];}):(!_0x278755&&(_0x18919d=_0x542b4e[_0x754fa3('0x2218')][_0x754fa3('0x1a43')]),_0xf5e4f1!==_0x278755&&(_0x542b4e[_0x754fa3('0x2218')]['page']=0x1),!_0xf5e4f1&&(_0x542b4e[_0x754fa3('0x2218')][_0x754fa3('0x1a43')]=_0x18919d),_0x191e12(_0x542b4e[_0x754fa3('0x2218')][_0x754fa3('0x1a43')]));}),_0x17e119[_0x11f5c4('0x3d2')](_0x11f5c4('0x1c3f'),function(){const _0x4c526e=_0x11f5c4;_0x2516b6[_0x4c526e('0x1800')](_0x4c526e('0x1c76')),_0x2516b6[_0x4c526e('0x1800')](_0x4c526e('0x1ceb')),_0x2516b6[_0x4c526e('0x1800')](_0x4c526e('0x1dc2')),_0x2516b6[_0x4c526e('0x1800')](_0x4c526e('0x1208')),_0x2516b6[_0x4c526e('0x1800')](_0x4c526e('0x109c')),_0x2516b6[_0x4c526e('0x1800')](_0x4c526e('0x27a3')),_0x2516b6[_0x4c526e('0x1800')](_0x4c526e('0xdfd'));});}const _0x19cca7=_0xa0702d;_0x14bab5['$inject']=['$scope',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$window','$translate','api','Auth',_0x36e6f4('0x2661'),'toasty','draftManager'];function _0x14bab5(_0x46274e,_0x2f4a3b,_0xffef58,_0x5ad34b,_0x5ce38e,_0x9fedba,_0x1993e1,_0x57e37e,_0x2ea72d,_0x25a598,_0x1435c9){const _0x4dd97e=_0x36e6f4,_0x53bf96=this;_0x53bf96[_0x4dd97e('0x557')]=_0x57e37e[_0x4dd97e('0x26cd')](),_0x53bf96[_0x4dd97e('0x5c9')]={},_0x53bf96[_0x4dd97e('0xf8a')]={},_0x53bf96[_0x4dd97e('0xb38')]={'count':0x0,'rows':[]},_0x53bf96['mailInteractions']={'count':0x0,'rows':[]},_0x53bf96[_0x4dd97e('0x2218')]={'includeAll':!![],'sort':_0x4dd97e('0x14dc'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x53bf96[_0x4dd97e('0x1291')]={'fields':[{'name':'Id','column':'id','type':'number'},{'name':_0x4dd97e('0x21a4'),'column':'Contact','type':'autocomplete','options':{'searchFields':[_0x4dd97e('0x18cb'),_0x4dd97e('0xeb0'),_0x4dd97e('0x66f')],'route':{'model':_0x4dd97e('0x149e'),'action':_0x4dd97e('0xd83'),'params':{'fields':_0x4dd97e('0x18eb'),'Contact':_0x4dd97e('0x145b'),'nolimit':!![]}},'extraOperators':[_0x4dd97e('0x2836')],'excludedOperators':['$ne']}},{'name':_0x4dd97e('0x36e'),'column':_0x4dd97e('0x210d'),'type':_0x4dd97e('0x1640'),'options':{'excludedOperators':[_0x4dd97e('0x110'),_0x4dd97e('0x2646')]}},{'name':_0x4dd97e('0xe1'),'column':_0x4dd97e('0x26d2'),'type':'text','options':{'excludedOperators':[_0x4dd97e('0x110'),_0x4dd97e('0x2646')]}},{'name':_0x4dd97e('0x28f6'),'column':_0x4dd97e('0xa5b'),'type':_0x4dd97e('0x88a'),'values':[{'id':0x0,'translate':'DASHBOARDS.OPENED'},{'id':0x1,'translate':_0x4dd97e('0x58f')}],'options':{'excludedOperators':[_0x4dd97e('0x2646')]}},{'name':_0x4dd97e('0x1b50'),'column':_0x4dd97e('0xcfc'),'type':_0x4dd97e('0x2162'),'options':{'field':_0x4dd97e('0x4f0'),'route':{'model':'mailSubstatus','action':_0x4dd97e('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':[_0x4dd97e('0x18d')]}},{'name':_0x4dd97e('0x89b'),'column':_0x4dd97e('0x1a6f'),'type':_0x4dd97e('0x1a01'),'options':{'table':'i','route':{'model':'user','action':_0x4dd97e('0xd83'),'params':{'role':_0x4dd97e('0x1eff'),'fields':'id,name,fullname','nolimit':!![]}},'searchFields':['fullname',_0x4dd97e('0x4f0')],'extraOperators':[_0x4dd97e('0x2836')],'excludedOperators':[_0x4dd97e('0x2646')]}},{'name':'Account','column':_0x4dd97e('0x56'),'type':'multiselect','options':{'route':{'model':_0x4dd97e('0x557'),'action':_0x4dd97e('0xf73'),'params':{'id':_0x53bf96['user']['id'],'nolimit':!![]}}}},{'name':'Tags','column':'Tag','type':'multiselect','options':{'route':{'model':_0x4dd97e('0x1446'),'action':_0x4dd97e('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':[_0x4dd97e('0x18d')]}},{'name':'Start\x20Date','column':_0x4dd97e('0x262'),'type':_0x4dd97e('0x1643'),'options':{'excludedOperators':[_0x4dd97e('0x2646')]}},{'name':'Read','column':_0x4dd97e('0x723'),'type':'select','values':[{'id':0x1,'translate':_0x4dd97e('0x1057')},{'id':0x0,'translate':_0x4dd97e('0x2c8')}],'options':{'excludedOperators':[_0x4dd97e('0x2646')]}}]},_0x53bf96[_0x4dd97e('0xb1f')]=_0x4dd97e('0x28e8'),_0x53bf96['onInit']=_0x585622,_0x53bf96[_0x4dd97e('0x103b')]=_0x19ca05,_0x53bf96[_0x4dd97e('0x17c1')]=_0x30d7ef,_0x53bf96[_0x4dd97e('0x1513')]=_0x4888a4,_0x53bf96[_0x4dd97e('0xf32')]=_0x1ec347,_0x53bf96[_0x4dd97e('0xb52')]=_0x2b305f,_0x53bf96[_0x4dd97e('0x250c')]=_0xfe1c95,_0x53bf96[_0x4dd97e('0x2253')]=_0x1078a4,_0x53bf96[_0x4dd97e('0x1baf')]=_0x339e4b,_0x53bf96[_0x4dd97e('0xd62')]=_0x9d6db0,_0x53bf96[_0x4dd97e('0x109e')]=_0x41fd27,_0x53bf96['onSearchBarExpand']=_0x339db4,_0x53bf96[_0x4dd97e('0x138b')]=_0x213be7,_0x46274e[_0x4dd97e('0x3d2')](_0x4dd97e('0x16b0'),_0x57de49);function _0x585622(_0x4c32d3,_0x4b9d99){const _0x2f1c3f=_0x4dd97e;return _0x53bf96['license']=_0x4c32d3,_0x53bf96[_0x2f1c3f('0xf8a')]=_0x4b9d99,_0x1993e1[_0x2f1c3f('0x557')][_0x2f1c3f('0xd83')+_0x2cfb05()[_0x2f1c3f('0x114b')](_0x2f1c3f('0xf85'))]({'id':_0x53bf96[_0x2f1c3f('0x557')]['id'],'nolimit':!![]})[_0x2f1c3f('0xa44')]['then'](function(_0x2cd14e){const _0x456452=_0x2f1c3f;return _0x53bf96[_0x456452('0xf85')]=_0x2cd14e||{'count':0x0,'rows':[]},_0x1993e1[_0x456452('0x1446')]['get']()[_0x456452('0xa44')];})[_0x2f1c3f('0x1166')](function(_0x13fce5){const _0x330364=_0x2f1c3f;_0x53bf96[_0x330364('0xb38')]=_0x13fce5||{'count':0x0,'rows':[]};})[_0x2f1c3f('0x1166')](function(){const _0x4a7be0=_0x2f1c3f;return _0x1993e1[_0x4a7be0('0x1c44')]['get']({'nolimit':!![]})[_0x4a7be0('0xa44')];})[_0x2f1c3f('0x1166')](function(_0x1dfd1f){const _0x1aaa82=_0x2f1c3f;_0x53bf96[_0x1aaa82('0x1ed2')]=_0x1dfd1f||{'count':0x0,'rows':[]};})[_0x2f1c3f('0x1166')](function(){const _0xb2c8b7=_0x2f1c3f;_0x53bf96[_0xb2c8b7('0x6cb')]=_0x55d5f4();})['catch'](function(_0x519e82){console['error'](_0x519e82);})[_0x2f1c3f('0x1951')](function(){const _0x5845ac=_0x2f1c3f;let _0x3ffc5=_0x5ce38e['localStorage']['getItem']('motion2.home.mail:'+_0x53bf96[_0x5845ac('0x557')]['id']);if(_0x3ffc5)try{_0x3ffc5=JSON[_0x5845ac('0x1295')](_0x3ffc5);if(_0x3ffc5[_0x5845ac('0x2218')]){_0x53bf96[_0x5845ac('0x2218')]=_0x2cfb05()[_0x5845ac('0xcc3')](_0x53bf96['query'],_0x3ffc5[_0x5845ac('0x2218')]);if(_0x2cfb05()[_0x5845ac('0x1081')](_0x53bf96[_0x5845ac('0xf85')][_0x5845ac('0x269a')]))_0x53bf96['query'][_0x5845ac('0x56')]=[];else _0x2cfb05()[_0x5845ac('0x1081')](_0x53bf96[_0x5845ac('0x2218')][_0x5845ac('0x56')])&&(_0x53bf96[_0x5845ac('0x2218')][_0x5845ac('0x56')]=_0x2cfb05()(_0x53bf96['mailAccounts'][_0x5845ac('0x269a')])[_0x5845ac('0x2563')]('id')['take']()['value']());_0x53bf96['query'][_0x5845ac('0x1aba')]&&_0x53bf96[_0x5845ac('0x2218')][_0x5845ac('0x1aba')][_0x5845ac('0x2379')](_0x5845ac('0x1522'))>=0x0&&(_0x53bf96[_0x5845ac('0x2218')]=_0x2cfb05()['omit'](_0x53bf96[_0x5845ac('0x2218')],_0x5845ac('0x1aba'))),_0x53bf96[_0x5845ac('0x2218')][_0x5845ac('0x220e')]=!![],_0x53bf96[_0x5845ac('0x7cc')]=_0x53bf96[_0x5845ac('0x2218')][_0x5845ac('0x1c33')]?!![]:![];}}catch(_0x401b33){console['error'](_0x401b33);}else{const _0x3e7647={'$gte':_0x24273b()()['startOf']('month')[_0x5845ac('0x13f2')](0x0,!![])[_0x5845ac('0x128a')](),'$lte':_0x24273b()()[_0x5845ac('0x2589')]('month')[_0x5845ac('0x13f2')](0x0,!![])['format']()},_0x5d3bdf={'MailAccountId':_0x2cfb05()[_0x5845ac('0x2563')](_0x53bf96[_0x5845ac('0xf85')]['rows'],'id'),'createdAt':_0x3e7647};_0x53bf96[_0x5845ac('0x2218')]=_0x2cfb05()[_0x5845ac('0xcc3')](_0x53bf96[_0x5845ac('0x2218')],_0x5d3bdf);}_0x2ea72d['on'](_0x5845ac('0x2332'),_0x287f0c),_0x2ea72d['on'](_0x5845ac('0x248c'),_0x287f0c),_0x2ea72d['on'](_0x5845ac('0x118b'),_0x50eca1),_0x2ea72d['on']('mailMessage:save',_0x35515a),_0x2ea72d['on'](_0x5845ac('0x214b'),_0x35515a),_0x2ea72d['on'](_0x5845ac('0x185c'),_0xa02a61),_0x2ea72d['on'](_0x5845ac('0x1928'),_0x356740),_0x30d7ef(_0x53bf96[_0x5845ac('0x2218')][_0x5845ac('0x1a43')]);});}function _0x55d5f4(){const _0x2be05b=_0x4dd97e;return[{'name':_0x2be05b('0x2567'),'key':_0x2be05b('0x262'),'type':_0x2be05b('0x1643'),'label':_0x2be05b('0x16d9')},{'name':_0x2be05b('0x116c'),'key':_0x2be05b('0x123'),'type':_0x2be05b('0x88a'),'label':_0x2be05b('0x379'),'customOptions':[{'value':0x0,'translate':'DASHBOARDS.UNREAD'},{'value':0x1,'translate':_0x2be05b('0x1057')},{'value':null,'translate':_0x2be05b('0x2150')}]},{'name':'Status','key':'closed','type':_0x2be05b('0x88a'),'label':_0x2be05b('0xe32'),'customOptions':[{'value':0x0,'translate':_0x2be05b('0xdeb')},{'value':0x1,'translate':'DASHBOARDS.CLOSED'},{'value':null,'translate':'DASHBOARDS.ALL'}]},{'name':'Substatus','key':_0x2be05b('0xcfc'),'type':_0x2be05b('0x88a'),'label':_0x2be05b('0x221b'),'options':_0x53bf96['subStatuses'][_0x2be05b('0x269a')],'customOptions':[{'value':'null','translate':_0x2be05b('0x25db')},{'value':undefined,'translate':_0x2be05b('0x2150')}],'ngValue':'name','ngIf':_0x2be05b('0x168f')},{'name':'Account','key':_0x2be05b('0x56'),'type':'multiselect','label':_0x2be05b('0x6da'),'options':_0x53bf96['mailAccounts'][_0x2be05b('0x269a')],'clearAll':![]},{'name':_0x2be05b('0x89b'),'key':_0x2be05b('0x122a'),'type':_0x2be05b('0x88a'),'label':_0x2be05b('0x1db1'),'customOptions':[{'value':_0x53bf96[_0x2be05b('0x557')]['id'],'translate':'DASHBOARDS.ME'},{'value':_0x2be05b('0x15d7'),'translate':_0x2be05b('0x216b')},{'value':undefined,'translate':'DASHBOARDS.ALL'}]},{'name':'Tag','key':_0x2be05b('0x1446'),'type':'multiselect','label':_0x2be05b('0x1669'),'options':_0x53bf96['tags'][_0x2be05b('0x269a')],'placeholder':_0x2be05b('0x2223')}];}function _0x19ca05(_0x5a6626){const _0x53b4bc=_0x4dd97e;_0x53bf96[_0x53b4bc('0x293')]=![],_0x53bf96[_0x53b4bc('0x17c0')]=_0x5a6626||{'count':0x0,'rows':[]};for(let _0x5945e8=0x0;_0x5945e8<_0x53bf96[_0x53b4bc('0x17c0')][_0x53b4bc('0x269a')][_0x53b4bc('0x264b')];_0x5945e8+=0x1){_0xfe1c95(_0x53bf96['mailInteractions'][_0x53b4bc('0x269a')][_0x5945e8]);}}function _0x30d7ef(_0x292ce0){const _0x2a1cc2=_0x4dd97e;_0x53bf96[_0x2a1cc2('0x293')]=!![];!_0x292ce0&&(_0x53bf96['query'][_0x2a1cc2('0x1a43')]=0x1);_0x53bf96[_0x2a1cc2('0x2218')][_0x2a1cc2('0x1098')]=(_0x53bf96[_0x2a1cc2('0x2218')][_0x2a1cc2('0x1a43')]-0x1)*_0x53bf96['query'][_0x2a1cc2('0x163f')];let _0x3af71f=_0x5ce38e[_0x2a1cc2('0x275')][_0x2a1cc2('0x15f7')](_0x2a1cc2('0x16c9')+_0x53bf96['user']['id']);_0x3af71f=_0x3af71f?JSON['parse'](_0x3af71f):{},_0x3af71f[_0x2a1cc2('0x2218')]=_0x53bf96[_0x2a1cc2('0x2218')],_0x5ce38e[_0x2a1cc2('0x275')][_0x2a1cc2('0xa26')]('motion2.home.mail:'+_0x53bf96[_0x2a1cc2('0x557')]['id'],JSON[_0x2a1cc2('0xbac')](_0x3af71f)),_0x53bf96[_0x2a1cc2('0x1f48')]=_0x1993e1[_0x2a1cc2('0x382')][_0x2a1cc2('0xd83')](_0x53bf96[_0x2a1cc2('0x2218')],_0x19ca05)[_0x2a1cc2('0xa44')];}function _0x4888a4(_0x57781e,_0x55a40f){const _0x481ae5=_0x4dd97e;_0x46274e[_0x481ae5('0x23ac')]['vm'][_0x481ae5('0x126e')](_0x481ae5('0x1bfa'),_0x55a40f);}function _0x1ec347(_0x5bd8f7,_0x40cad7,_0x58b4c4){const _0x2bb54d=_0x4dd97e;_0x1993e1['mailInteraction'][_0x2bb54d('0x2ad')]({'id':_0x40cad7['id'],'attachments':_0x58b4c4})[_0x2bb54d('0xa44')][_0x2bb54d('0x1166')](function(_0x1e2df8){const _0x3e8f78=_0x2bb54d,_0xebb9ec=[_0x1e2df8[_0x3e8f78('0x20ed')]],_0xf2c5d6=_0x3e8f78('0xe36')+_0x40cad7['id']+_0x3e8f78('0x806'),_0x13a4b6=new Blob(_0xebb9ec,{'type':_0x1e2df8[_0x3e8f78('0x1345')]}),_0x21a2fd=window[_0x3e8f78('0x136d')][_0x3e8f78('0xdd')]('a');_0x21a2fd[_0x3e8f78('0xffd')](_0x3e8f78('0x14f9'),URL['createObjectURL'](_0x13a4b6)),_0x21a2fd[_0x3e8f78('0xffd')](_0x3e8f78('0x2ad'),_0xf2c5d6),document[_0x3e8f78('0x8d2')]['appendChild'](_0x21a2fd),_0x21a2fd['click']();})[_0x2bb54d('0x1a80')](function(_0x2da9ee){const _0x1bd35b=_0x2bb54d;if(_0x2da9ee['data']&&_0x2da9ee['data'][_0x1bd35b('0x61a')]&&_0x2da9ee[_0x1bd35b('0x25f4')]['errors'][_0x1bd35b('0x264b')])for(let _0x4ea428=0x0;_0x4ea428<_0x2da9ee[_0x1bd35b('0x25f4')][_0x1bd35b('0x61a')]['length'];_0x4ea428+=0x1){_0x25a598[_0x1bd35b('0xfc9')]({'title':_0x2da9ee[_0x1bd35b('0x25f4')][_0x1bd35b('0x61a')][_0x4ea428][_0x1bd35b('0x1345')],'msg':_0x2da9ee[_0x1bd35b('0x25f4')][_0x1bd35b('0x61a')][_0x4ea428][_0x1bd35b('0x1e70')]});}else _0x25a598[_0x1bd35b('0xfc9')]({'title':_0x2da9ee[_0x1bd35b('0x52d')]?_0x1bd35b('0x1e21')+_0x2da9ee[_0x1bd35b('0x52d')]+_0x1bd35b('0x11e1')+_0x2da9ee[_0x1bd35b('0xe1b')]:_0x1bd35b('0xf32'),'msg':_0x2da9ee[_0x1bd35b('0x25f4')]?JSON[_0x1bd35b('0xbac')](_0x2da9ee['data']['message']):_0x2da9ee[_0x1bd35b('0x1586')]()});});}function _0x2b305f(_0xd3d7,_0x3a9360){const _0x3b716d=_0x4dd97e,_0x1b9b8f=_0x53bf96['user'][_0x3b716d('0x2540')]||_0x53bf96[_0x3b716d('0x557')][_0x3b716d('0x1c5c')]||_0x53bf96['user'][_0x3b716d('0xb4')]||_0x53bf96[_0x3b716d('0x557')]['openchannelPause']||_0x53bf96[_0x3b716d('0x557')][_0x3b716d('0x5aa')],_0x4c491b=!_0x3a9360['Account'][_0x3b716d('0x10d0')];_0xffef58[_0x3b716d('0x1f80')]({'controller':_0x3b716d('0xa39'),'controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular[_0x3b716d('0x1194')](_0x5ad34b['body']),'clickOutsideToClose':_0x4c491b,'escapeToClose':_0x4c491b,'onRemoving':function(){const _0x293a40=_0x3b716d;_0x53bf96['user']&&_0x3a9360[_0x293a40('0x1758')][_0x293a40('0x10d0')]&&!_0x1b9b8f&&_0x1993e1[_0x293a40('0x557')][_0x293a40('0x20eb')]({'id':_0x53bf96[_0x293a40('0x557')]['id']})[_0x293a40('0xa44')]['catch'](function(_0x343c33){const _0x529407=_0x293a40;console[_0x529407('0xfc9')](_0x343c33);});},'locals':{'user':_0x53bf96[_0x3b716d('0x557')],'channel':_0x3b716d('0x1bfa'),'interaction':_0x3a9360}});}function _0xfe1c95(_0x290446){const _0x21c1c1=_0x4dd97e;if(!_0x2cfb05()[_0x21c1c1('0x1081')](_0x290446['to'])&&_0x290446['Account']&&!_0x2cfb05()[_0x21c1c1('0x1257')](_0x290446['to'],_0x290446[_0x21c1c1('0x1758')][_0x21c1c1('0x66f')]))_0x290446[_0x21c1c1('0x15cf')]=_0x290446['to'][_0x21c1c1('0x25c8')]('\x20<')[0x0],_0x290446['contactInfo']=_0x290446['to'][_0x21c1c1('0x25c8')]('<')[_0x21c1c1('0xf65')]()[_0x21c1c1('0x25c8')]('>')[0x0];else _0x290446[_0x21c1c1('0x21a4')]?(_0x290446['contactName']=(_0x290446[_0x21c1c1('0x21a4')]['firstName']||'')+'\x20'+(_0x290446[_0x21c1c1('0x21a4')][_0x21c1c1('0xeb0')]||''),_0x290446['contactInfo']=_0x290446[_0x21c1c1('0x21a4')][_0x21c1c1('0x66f')]||''):_0x290446['contactName']=_0x9fedba[_0x21c1c1('0x25cc')](_0x21c1c1('0x148c'));}function _0x1078a4(_0x40402e){const _0x43b6f8=_0x4dd97e;if(_0x40402e['UserId'])return _0x40402e[_0x43b6f8('0x122a')]===_0x53bf96['user']['id']?_0x9fedba['instant']('DASHBOARDS.ME'):_0x40402e[_0x43b6f8('0x121b')][_0x43b6f8('0x6e1')]+'\x20<'+_0x40402e[_0x43b6f8('0x121b')][_0x43b6f8('0x1eef')]+'>';return _0x9fedba[_0x43b6f8('0x25cc')](_0x43b6f8('0x216b'));}function _0x339e4b(_0x2164f7){const _0x22955a=_0x4dd97e;if(_0x2164f7['Account'])return _0x2164f7[_0x22955a('0x1758')][_0x22955a('0x7ca')];return _0x9fedba[_0x22955a('0x25cc')](_0x22955a('0x148c'));}function _0x57de49(_0x4a1c1f,_0x2dc5ba){const _0x4a84ab=_0x4dd97e;_0x2dc5ba[_0x4a84ab('0x25e6')]?(_0x2dc5ba[_0x4a84ab('0x25e6')]['isDraft']=!![],_0x4888a4(null,_0x2dc5ba[_0x4a84ab('0x25e6')])):_0xffef58[_0x4a84ab('0x1f80')]({'controller':_0x4a84ab('0x2709'),'controllerAs':'vm','templateUrl':_0x5f05e0,'parent':angular[_0x4a84ab('0x1194')](_0x5ad34b[_0x4a84ab('0x8d2')]),'clickOutsideToClose':![],'locals':{'account':_0x2dc5ba['account'],'message':_0x2dc5ba['content'],'type':'draft','interaction':{}},'fullscreen':!![]})[_0x4a84ab('0x1166')](function(_0x3d2a68){const _0x46a26c=_0x4a84ab;if(_0x3d2a68){if(_0x3d2a68[_0x46a26c('0x1e70')]&&_0x3d2a68['message']['savedAsDraft']){const _0x2718fd={'id':_0x2dc5ba['id'],'channel':_0x46a26c('0x1bfa'),'account':_0x3d2a68[_0x46a26c('0x1a32')],'message':_0x3d2a68['message']};_0x1435c9[_0x46a26c('0x1449')](_0x2718fd);}else{const _0x25df9e=_0x3d2a68;return _0x1993e1[_0x46a26c('0x21b9')][_0x46a26c('0x20ba')]({'id':_0x2dc5ba[_0x46a26c('0x1a32')]['id']},_0x25df9e)[_0x46a26c('0xa44')][_0x46a26c('0x1166')](function(_0x458baa){const _0x4f0d64=_0x46a26c;_0x1435c9[_0x4f0d64('0x127f')](_0x2dc5ba['id']);if(_0x458baa&&_0x458baa[_0x4f0d64('0x116c')]&&_0x458baa[_0x4f0d64('0x116c')]['length']){if(_0x25df9e[_0x4f0d64('0x1e1d')]&&_0x25df9e[_0x4f0d64('0x1e1d')][_0x4f0d64('0x264b')])for(let _0x218bfd=0x0;_0x218bfd<_0x25df9e[_0x4f0d64('0x1e1d')]['length'];_0x218bfd+=0x1){_0x1993e1[_0x4f0d64('0x21bc')][_0x4f0d64('0x1449')]({'id':_0x25df9e['attachments'][_0x218bfd]['id']},{'MailMessageId':_0x2cfb05()['head'](_0x458baa[_0x4f0d64('0x116c')])['id']});}_0x25a598[_0x4f0d64('0x103b')]({'title':_0x4f0d64('0x11ac'),'msg':'Message\x20has\x20been\x20sent!'});if(_0x458baa[_0x4f0d64('0xa5b')]){_0x458baa['disposition']=null;const _0x165377=!_0x2dc5ba[_0x4f0d64('0x1a32')][_0x4f0d64('0x10d0')],_0x2c2357=_0x53bf96['user'][_0x4f0d64('0x2540')]||_0x53bf96[_0x4f0d64('0x557')][_0x4f0d64('0x1c5c')]||_0x53bf96['user'][_0x4f0d64('0xb4')]||_0x53bf96[_0x4f0d64('0x557')][_0x4f0d64('0x287f')]||_0x53bf96[_0x4f0d64('0x557')][_0x4f0d64('0x5aa')];_0xffef58[_0x4f0d64('0x1f80')]({'controller':'DisposeInteractionDialogController','controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular[_0x4f0d64('0x1194')](_0x5ad34b[_0x4f0d64('0x8d2')]),'onRemoving':function(){const _0x2a767b=_0x4f0d64;_0x53bf96[_0x2a767b('0x557')]&&_0x2dc5ba['account'][_0x2a767b('0x10d0')]&&!_0x2c2357&&_0x1993e1['user']['unpause']({'id':_0x53bf96[_0x2a767b('0x557')]['id']})[_0x2a767b('0xa44')]['catch'](function(_0x4585e7){const _0x1a32e0=_0x2a767b;console[_0x1a32e0('0xfc9')](_0x4585e7);});},'clickOutsideToClose':_0x165377,'escapeToClose':_0x165377,'locals':{'user':_0x53bf96[_0x4f0d64('0x557')],'channel':_0x4f0d64('0x1bfa'),'interaction':_0x458baa}});}else _0x46274e[_0x4f0d64('0x23ac')]['vm'][_0x4f0d64('0x126e')](_0x4f0d64('0x1bfa'),_0x458baa);}})[_0x46a26c('0x1a80')](function(_0x1e637c){const _0x222008=_0x46a26c;if(_0x1e637c[_0x222008('0x25f4')]&&_0x1e637c[_0x222008('0x25f4')]['errors']&&_0x1e637c['data'][_0x222008('0x61a')]['length'])for(let _0x2f2487=0x0;_0x2f2487<_0x1e637c[_0x222008('0x25f4')][_0x222008('0x61a')][_0x222008('0x264b')];_0x2f2487++){_0x25a598[_0x222008('0xfc9')]({'title':_0x1e637c[_0x222008('0x25f4')][_0x222008('0x61a')][_0x2f2487]['type'],'msg':_0x1e637c[_0x222008('0x25f4')][_0x222008('0x61a')][_0x2f2487]['message']});}else _0x25a598[_0x222008('0xfc9')]({'title':_0x1e637c[_0x222008('0x52d')]?_0x222008('0x1e21')+_0x1e637c[_0x222008('0x52d')]+_0x222008('0x11e1')+_0x1e637c[_0x222008('0xe1b')]:_0x222008('0x3fc'),'msg':_0x1e637c[_0x222008('0x25f4')]?JSON[_0x222008('0xbac')](_0x1e637c['data'][_0x222008('0x1e70')]):_0x1e637c[_0x222008('0x1e70')]||_0x1e637c['toString']()});});}}});}function _0x9d6db0(_0x167d33,_0x4b5759){const _0x4fea73=_0x4dd97e;_0xffef58[_0x4fea73('0x1f80')]({'controller':_0x4fea73('0x2709'),'controllerAs':'vm','templateUrl':_0x5f05e0,'parent':angular[_0x4fea73('0x1194')](_0x5ad34b[_0x4fea73('0x8d2')]),'clickOutsideToClose':![],'locals':{'account':_0x4b5759,'message':{},'type':_0x4fea73('0xd11'),'interaction':{}},'fullscreen':!![]})[_0x4fea73('0x1166')](function(_0x596830){const _0x1c068c=_0x4fea73;if(_0x596830){if(_0x596830[_0x1c068c('0x1e70')]&&_0x596830[_0x1c068c('0x1e70')]['savedAsDraft']){const _0x5800c3={'channel':_0x1c068c('0x1bfa'),'account':_0x4b5759,'message':_0x596830[_0x1c068c('0x1e70')],'contact':_0x596830[_0x1c068c('0x26db')]};_0x1435c9['add'](_0x5800c3);}else{const _0x1a6eb4=_0x596830;return _0x1993e1[_0x1c068c('0x21b9')][_0x1c068c('0x20ba')]({'id':_0x4b5759['id']},_0x1a6eb4)[_0x1c068c('0xa44')][_0x1c068c('0x1166')](function(_0x138f81){const _0x3566b4=_0x1c068c;if(_0x138f81&&_0x138f81[_0x3566b4('0x116c')]&&_0x138f81[_0x3566b4('0x116c')][_0x3566b4('0x264b')]){if(_0x1a6eb4[_0x3566b4('0x1e1d')]&&_0x1a6eb4[_0x3566b4('0x1e1d')]['length'])for(let _0x165170=0x0;_0x165170<_0x1a6eb4[_0x3566b4('0x1e1d')][_0x3566b4('0x264b')];_0x165170+=0x1){_0x1993e1[_0x3566b4('0x21bc')][_0x3566b4('0x1449')]({'id':_0x1a6eb4[_0x3566b4('0x1e1d')][_0x165170]['id']},{'MailMessageId':_0x2cfb05()[_0x3566b4('0x345')](_0x138f81[_0x3566b4('0x116c')])['id']});}_0x25a598[_0x3566b4('0x103b')]({'title':_0x3566b4('0x11ac'),'msg':'Message\x20has\x20been\x20sent!'});if(_0x138f81[_0x3566b4('0xa5b')]){_0x138f81['disposition']=null;const _0x42e3ac=!_0x4b5759[_0x3566b4('0x10d0')],_0xa20a35=_0x53bf96[_0x3566b4('0x557')]['voicePause']||_0x53bf96[_0x3566b4('0x557')][_0x3566b4('0x1c5c')]||_0x53bf96[_0x3566b4('0x557')][_0x3566b4('0xb4')]||_0x53bf96['user']['openchannelPause']||_0x53bf96[_0x3566b4('0x557')][_0x3566b4('0x5aa')];_0xffef58[_0x3566b4('0x1f80')]({'controller':_0x3566b4('0xa39'),'controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular[_0x3566b4('0x1194')](_0x5ad34b[_0x3566b4('0x8d2')]),'onRemoving':function(){const _0x2069cb=_0x3566b4;_0x53bf96['user']&&_0x4b5759[_0x2069cb('0x10d0')]&&!_0xa20a35&&_0x1993e1[_0x2069cb('0x557')][_0x2069cb('0x20eb')]({'id':_0x53bf96[_0x2069cb('0x557')]['id']})[_0x2069cb('0xa44')][_0x2069cb('0x1a80')](function(_0x1c68f6){const _0x5e78f4=_0x2069cb;console[_0x5e78f4('0xfc9')](_0x1c68f6);});},'clickOutsideToClose':_0x42e3ac,'escapeToClose':_0x42e3ac,'locals':{'user':_0x53bf96[_0x3566b4('0x557')],'channel':'mail','interaction':_0x138f81}});}else _0x46274e['$parent']['vm'][_0x3566b4('0x126e')](_0x3566b4('0x1bfa'),_0x138f81);}})[_0x1c068c('0x1a80')](function(_0x222eb7){const _0x519bd8=_0x1c068c;if(_0x222eb7[_0x519bd8('0x25f4')]&&_0x222eb7['data'][_0x519bd8('0x61a')]&&_0x222eb7[_0x519bd8('0x25f4')][_0x519bd8('0x61a')][_0x519bd8('0x264b')])for(let _0x1a4b36=0x0;_0x1a4b36<_0x222eb7['data']['errors']['length'];_0x1a4b36++){_0x25a598['error']({'title':_0x222eb7[_0x519bd8('0x25f4')][_0x519bd8('0x61a')][_0x1a4b36][_0x519bd8('0x1345')],'msg':_0x222eb7[_0x519bd8('0x25f4')][_0x519bd8('0x61a')][_0x1a4b36][_0x519bd8('0x1e70')]});}else _0x25a598[_0x519bd8('0xfc9')]({'title':_0x222eb7['status']?'API:'+_0x222eb7[_0x519bd8('0x52d')]+_0x519bd8('0x11e1')+_0x222eb7[_0x519bd8('0xe1b')]:_0x519bd8('0x3fc'),'msg':_0x222eb7[_0x519bd8('0x25f4')]?JSON[_0x519bd8('0xbac')](_0x222eb7[_0x519bd8('0x25f4')][_0x519bd8('0x1e70')]):_0x222eb7['message']||_0x222eb7[_0x519bd8('0x1586')]()});});}}});}function _0xa02a61(_0x3cdb9e){const _0x43668c=_0x4dd97e;let _0xcad357;const _0x478258=_0x2cfb05()[_0x43668c('0xc38')](_0x53bf96[_0x43668c('0x17c0')]['rows'],{'id':_0x3cdb9e[_0x43668c('0x20ea')]});_0x478258&&_0x478258['Users']&&(_0xcad357=_0x2cfb05()[_0x43668c('0xc38')](_0x478258['Users'],{'id':_0x3cdb9e[_0x43668c('0x122a')]}),!_0xcad357&&_0x478258['Users']['push']({'id':_0x3cdb9e['UserId']}));}function _0x356740(_0x2e2c05){const _0x4e813d=_0x4dd97e,_0x533bd1=_0x2cfb05()[_0x4e813d('0xc38')](_0x53bf96[_0x4e813d('0x17c0')][_0x4e813d('0x269a')],{'id':_0x2e2c05[_0x4e813d('0x20ea')]});_0x533bd1&&_0x533bd1[_0x4e813d('0x1bc7')]&&_0x2cfb05()['remove'](_0x533bd1['Users'],{'id':_0x2e2c05[_0x4e813d('0x122a')]});}function _0x287f0c(_0x50b873){const _0x542363=_0x4dd97e;if(_0x50b873){const _0x517c56=_0x2cfb05()[_0x542363('0xc38')](_0x53bf96[_0x542363('0x17c0')][_0x542363('0x269a')],{'id':_0x50b873['id']});if(_0x517c56){_0x517c56[_0x542363('0x1bc7')]=[];_0x50b873['closed']&&(_0x517c56[_0x542363('0x723')]=0x0);if(_0x53bf96[_0x542363('0x2218')][_0x542363('0x1aba')]){const _0x47bc80=_0x2cfb05()[_0x542363('0x1783')](_0x53bf96[_0x542363('0x2218')][_0x542363('0x1aba')],'-')?_0x542363('0x1dc3'):_0x542363('0x17d');_0x53bf96[_0x542363('0x17c0')][_0x542363('0x269a')]=_0x2cfb05()[_0x542363('0xe63')](_0x53bf96[_0x542363('0x17c0')][_0x542363('0x269a')],_0x2cfb05()['trimStart'](_0x53bf96[_0x542363('0x2218')][_0x542363('0x1aba')],'-'),_0x47bc80);}_0x2cfb05()[_0x542363('0xcc3')](_0x517c56,_0x2cfb05()[_0x542363('0x1a08')](_0x50b873,_0x2cfb05()[_0x542363('0x14a4')](_0x517c56)));}else _0x30d7ef(_0x53bf96['query']['page']);}}function _0x50eca1(_0x4014da){const _0x6ca368=_0x4dd97e;if(_0x4014da){const _0x106613=_0x2cfb05()[_0x6ca368('0xc38')](_0x53bf96[_0x6ca368('0x17c0')][_0x6ca368('0x269a')],{'id':_0x4014da['id']});_0x106613&&(_0x106613[_0x6ca368('0x21c2')]=_0x4014da[_0x6ca368('0xb38')]||[],_0x2cfb05()[_0x6ca368('0xcc3')](_0x106613,_0x2cfb05()[_0x6ca368('0x1a08')](_0x4014da,_0x2cfb05()[_0x6ca368('0x14a4')](_0x106613))));}}function _0x35515a(_0x38dd96){const _0x47b74d=_0x4dd97e;if(_0x38dd96&&!_0x38dd96[_0x47b74d('0x1908')]){const _0x118a01=_0x2cfb05()['find'](_0x53bf96[_0x47b74d('0x17c0')][_0x47b74d('0x269a')],{'id':_0x38dd96[_0x47b74d('0x20ea')]});if(_0x118a01){const _0x40453f=_0x2cfb05()[_0x47b74d('0xc38')](_0x118a01[_0x47b74d('0x116c')],{'id':_0x38dd96['id']});_0x40453f?_0x2cfb05()[_0x47b74d('0xcc3')](_0x40453f,_0x2cfb05()[_0x47b74d('0x1a08')](_0x38dd96,_0x2cfb05()[_0x47b74d('0x14a4')](_0x40453f))):(_0x2cfb05()[_0x47b74d('0x2863')](_0x118a01['Messages'])&&(_0x118a01[_0x47b74d('0x116c')]={'count':0x0}),!_0x38dd96[_0x47b74d('0x123')]&&(_0x118a01[_0x47b74d('0x116c')]['count']+=0x1));}}}function _0x41fd27(){const _0x5a9ae7=_0x4dd97e;_0x53bf96[_0x5a9ae7('0x7cc')]=![];}function _0x339db4(){const _0x2f7383=_0x4dd97e;_0x53bf96[_0x2f7383('0x7cc')]=!![];}function _0x213be7(){const _0x956e63=_0x4dd97e;_0x53bf96[_0x956e63('0x7cc')]=![],_0xffef58[_0x956e63('0x1f80')]({'controller':_0x956e63('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0x956e63('0x1194')](_0x5ad34b[_0x956e63('0x8d2')]),'clickOutsideToClose':![],'locals':{'color':_0x53bf96['sectionColor'],'fields':_0x53bf96[_0x956e63('0x1291')]['fields'],'storagePath':_0x956e63('0x1b67')},'fullscreen':!![]})[_0x956e63('0x1166')](function(_0x1197bf){const _0xaff5eb=_0x956e63;_0x53bf96[_0xaff5eb('0x2218')]['search']=_0x1197bf===![]?undefined:_0x1197bf;if(_0x53bf96[_0xaff5eb('0x2218')][_0xaff5eb('0xe07')]||_0x1197bf===![])_0x30d7ef();})[_0x956e63('0x1a80')](function(_0x483ecd){const _0x57dc0c=_0x956e63;_0x25a598[_0x57dc0c('0xfc9')]({'title':'ERROR','msg':_0x483ecd[_0x57dc0c('0x25f4')]?JSON['stringify'](_0x483ecd[_0x57dc0c('0x25f4')][_0x57dc0c('0x1e70')]):_0x483ecd['toString']()});});}let _0x44751f=!![],_0x28f4ae=0x1;_0x46274e[_0x4dd97e('0xe83')](_0x4dd97e('0x12d8'),function(_0x420162,_0x44e5d5){const _0x99ad=_0x4dd97e;_0x44751f?_0x2f4a3b(function(){_0x44751f=![];}):(!_0x44e5d5&&(_0x28f4ae=_0x53bf96[_0x99ad('0x2218')][_0x99ad('0x1a43')]),_0x420162!==_0x44e5d5&&(_0x53bf96[_0x99ad('0x2218')][_0x99ad('0x1a43')]=0x1),!_0x420162&&(_0x53bf96[_0x99ad('0x2218')]['page']=_0x28f4ae),_0x30d7ef(_0x53bf96[_0x99ad('0x2218')][_0x99ad('0x1a43')]));}),_0x46274e[_0x4dd97e('0x3d2')]('$destroy',function(){const _0x56a1ad=_0x4dd97e;_0x2ea72d['removeAllListeners'](_0x56a1ad('0x601')),_0x2ea72d[_0x56a1ad('0x1800')](_0x56a1ad('0x214b')),_0x2ea72d[_0x56a1ad('0x1800')](_0x56a1ad('0x2332')),_0x2ea72d[_0x56a1ad('0x1800')]('mailInteractionTags:save'),_0x2ea72d[_0x56a1ad('0x1800')](_0x56a1ad('0x248c')),_0x2ea72d[_0x56a1ad('0x1800')](_0x56a1ad('0x185c')),_0x2ea72d['removeAllListeners'](_0x56a1ad('0x1928'));});}const _0x547a09=_0x14bab5;_0x2c3840[_0x36e6f4('0x1294')]=['$document',_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x21ef'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1566'),_0x36e6f4('0x1d2e')];function _0x2c3840(_0x259d6a,_0x3a1149,_0x172f15,_0x1f65e3,_0x4dbc48,_0x861c2c,_0x27e276,_0xf2ae32){const _0x567733=_0x36e6f4,_0x47802c=this;_0x47802c[_0x567733('0x98')]=_0x4dbc48['getCurrentUser'](),_0x47802c['lists']={},_0x47802c['contacts']={'count':0x0,'rows':[]},_0x47802c[_0x567733('0xb38')]={'count':0x0,'rows':[]},_0x47802c[_0x567733('0x2218')]={'includeAll':!![],'id':_0x47802c['currentUser']['id'],'sort':'-updatedAt','limit':0xa,'page':0x1},_0x47802c[_0x567733('0x1291')]={'fields':[]},_0x47802c[_0x567733('0xb1f')]=_0x567733('0x21e2'),_0x47802c[_0x567733('0x2738')]=_0x55d8f7,_0x47802c[_0x567733('0x2587')]=_0xb4d157,_0x47802c[_0x567733('0x23f3')]=_0x399601,_0x47802c[_0x567733('0x22de')]=_0x69d209,_0x47802c[_0x567733('0x65e')]=_0x1c2a66,_0x47802c[_0x567733('0x200f')]=_0x3a1149[_0x567733('0x23ac')]['vm'][_0x567733('0x200f')],_0x47802c[_0x567733('0xae0')]=_0xc59357,_0x47802c[_0x567733('0x109e')]=_0x52456f,_0x47802c[_0x567733('0x3c5')]=_0x5d0964,_0x47802c['openAdvancedSearch']=_0x262584;function _0xc59357(){const _0x9fa0d0=_0x567733;_0x861c2c[_0x9fa0d0('0xdd9')][_0x9fa0d0('0xd83')]({'fields':_0x9fa0d0('0x27b'),'sort':_0x9fa0d0('0x4f0'),'nolimit':!![]})[_0x9fa0d0('0xa44')][_0x9fa0d0('0x1166')](function(_0x1263de){const _0x24a013=_0x9fa0d0;return _0x47802c[_0x24a013('0x8de')]=_0x1263de||{'count':0x0,'rows':[]},_0x47802c['listsMap']=_0x2cfb05()['keyBy'](_0x47802c['lists'][_0x24a013('0x269a')],'id'),_0x861c2c[_0x24a013('0x1446')][_0x24a013('0xd83')]()[_0x24a013('0xa44')];})[_0x9fa0d0('0x1166')](function(_0x56f5b9){const _0x2fda55=_0x9fa0d0;_0x47802c[_0x2fda55('0xb38')]=_0x56f5b9||{'count':0x0,'rows':[]};})[_0x9fa0d0('0x1166')](function(){const _0x2c72e4=_0x9fa0d0;_0x47802c[_0x2c72e4('0x6cb')]=_0x54493b();})[_0x9fa0d0('0x1a80')](function(_0x7979e9){const _0x1623a9=_0x9fa0d0;console[_0x1623a9('0xfc9')](_0x7979e9);})[_0x9fa0d0('0x1951')](function(){const _0x2e5c45=_0x9fa0d0;let _0x27ca10=_0x27e276['localStorage']['getItem'](_0x2e5c45('0xfcc')+_0x47802c[_0x2e5c45('0x98')]['id']);if(_0x27ca10)try{_0x27ca10=JSON[_0x2e5c45('0x1295')](_0x27ca10);if(_0x27ca10[_0x2e5c45('0x2218')]){_0x47802c[_0x2e5c45('0x2218')]=_0x2cfb05()['merge'](_0x47802c[_0x2e5c45('0x2218')],_0x27ca10['query']);if(_0x2cfb05()['isEmpty'](_0x47802c[_0x2e5c45('0x8de')]['rows']))_0x47802c[_0x2e5c45('0x2218')][_0x2e5c45('0x23c')]=[];else _0x2cfb05()['isEmpty'](_0x47802c[_0x2e5c45('0x2218')][_0x2e5c45('0x23c')])&&(_0x47802c[_0x2e5c45('0x2218')][_0x2e5c45('0x23c')]=_0x2cfb05()(_0x47802c[_0x2e5c45('0x8de')][_0x2e5c45('0x269a')])[_0x2e5c45('0x2563')]('id')['take']()['value']());}}catch(_0x26b5d7){console[_0x2e5c45('0xfc9')](_0x26b5d7);}else _0x47802c[_0x2e5c45('0x2218')][_0x2e5c45('0x23c')]=_0x2cfb05()[_0x2e5c45('0x2563')](_0x47802c['lists'][_0x2e5c45('0x269a')],'id');_0x47802c['isSearchBarVisible']=_0x47802c[_0x2e5c45('0x2218')][_0x2e5c45('0x1c33')]?!![]:![],_0x55d8f7();});}function _0x54493b(){const _0xd23055=_0x567733;return[{'name':_0xd23055('0xe22'),'key':_0xd23055('0x23c'),'type':'multiselect','label':_0xd23055('0x257a'),'options':_0x47802c[_0xd23055('0x8de')][_0xd23055('0x269a')],'clearAll':![]},{'name':'Tag','key':_0xd23055('0x1446'),'type':_0xd23055('0x2162'),'label':_0xd23055('0x1669'),'options':_0x47802c['tags'][_0xd23055('0x269a')],'placeholder':_0xd23055('0x2223')}];}function _0x3ee6f5(_0x5bf63a){_0x47802c['searchInProgress']=![],_0x47802c['contacts']=_0x5bf63a||{'count':0x0,'rows':[]};}function _0x55d8f7(_0x4c32f1){const _0x33909a=_0x567733;_0x47802c[_0x33909a('0x293')]=!![],_0xc3180();!_0x4c32f1&&(_0x47802c['query']['page']=0x1);_0x47802c[_0x33909a('0x2218')][_0x33909a('0x1098')]=(_0x47802c[_0x33909a('0x2218')][_0x33909a('0x1a43')]-0x1)*_0x47802c[_0x33909a('0x2218')][_0x33909a('0x163f')];let _0x4cc779=_0x27e276[_0x33909a('0x275')][_0x33909a('0x15f7')](_0x33909a('0xfcc')+_0x47802c[_0x33909a('0x98')]['id']);_0x4cc779=_0x4cc779?JSON[_0x33909a('0x1295')](_0x4cc779):{},_0x4cc779[_0x33909a('0x2218')]=_0x47802c['query'],_0x27e276[_0x33909a('0x275')][_0x33909a('0xa26')](_0x33909a('0xfcc')+_0x47802c[_0x33909a('0x98')]['id'],JSON['stringify'](_0x4cc779));if(_0x47802c[_0x33909a('0x2218')][_0x33909a('0xe07')])_0x47802c[_0x33909a('0x23c2')]=_0x2cfb05()[_0x33909a('0x1414')](_0x47802c[_0x33909a('0x2218')],'id');_0x47802c[_0x33909a('0x1f48')]=_0x47802c[_0x33909a('0x2218')][_0x33909a('0xe07')]?_0x861c2c['cmContact'][_0x33909a('0xd83')](_0x47802c[_0x33909a('0x23c2')],_0x3ee6f5)[_0x33909a('0xa44')]:_0x861c2c['user'][_0x33909a('0x2738')](_0x47802c[_0x33909a('0x2218')],_0x3ee6f5)[_0x33909a('0xa44')];}function _0x1c2a66(_0x10fa72,_0x158570){const _0x5a08b8=_0x567733;_0x3a1149[_0x5a08b8('0x23ac')]['vm'][_0x5a08b8('0x247b')](_0x158570);}function _0xb4d157(){_0x55d8f7();}function _0x69d209(_0x5d00cb,_0xd3082f){const _0xeeda86=_0x567733;_0x1f65e3[_0xeeda86('0x1f80')]({'controller':'DuplicateContactDialogController','controllerAs':'vm','templateUrl':_0x5b62a4,'parent':angular[_0xeeda86('0x1194')](_0x259d6a[_0xeeda86('0x8d2')]),'targetEvent':_0x5d00cb,'clickOutsideToClose':!![],'resolve':{'contact':['apiResolver',function(_0x1339bf){const _0x3237d1=_0xeeda86;return _0x1339bf['resolve'](_0x3237d1('0x111c'),{'id':_0xd3082f['id']});}],'lists':[_0xeeda86('0x1fbc'),function(_0x57a9d1){const _0xbbe70d=_0xeeda86;return _0x57a9d1[_0xbbe70d('0x18af')](_0xbbe70d('0x273f'),{'id':_0x47802c[_0xbbe70d('0x98')]['id'],'fields':'id,name'});}]},'locals':{'contacts':_0x47802c[_0xeeda86('0xca8')][_0xeeda86('0x269a')]}});}function _0x399601(_0x3cfe9d,_0x242ab2){const _0x5dbba4=_0x567733;_0x1f65e3['show']({'controller':_0x5dbba4('0xcd1'),'controllerAs':'vm','templateUrl':_0x18c924,'parent':angular[_0x5dbba4('0x1194')](_0x259d6a[_0x5dbba4('0x8d2')]),'targetEvent':_0x3cfe9d,'clickOutsideToClose':!![],'resolve':{'contact':[_0x5dbba4('0x1fbc'),function(_0x17907e){const _0x18e15e=_0x5dbba4;return _0x17907e[_0x18e15e('0x18af')](_0x18e15e('0x111c'),{'id':_0x242ab2['id']});}],'lists':[_0x5dbba4('0x1fbc'),function(_0x1777bd){const _0x2b0c63=_0x5dbba4;return _0x1777bd['resolve'](_0x2b0c63('0x273f'),{'id':_0x47802c[_0x2b0c63('0x98')]['id'],'fields':_0x2b0c63('0x1776')});}]},'locals':{'contacts':_0x47802c[_0x5dbba4('0xca8')][_0x5dbba4('0x269a')]}});}function _0x52456f(){const _0xb32bbf=_0x567733;_0x47802c[_0xb32bbf('0x7cc')]=![];}function _0x5d0964(){const _0x470242=_0x567733;_0x47802c[_0x470242('0x7cc')]=!![];}function _0xc3180(){const _0x10fc07=_0x567733;return _0x861c2c[_0x10fc07('0x149e')][_0x10fc07('0x23d0')]({'id':_0x47802c[_0x10fc07('0x2218')][_0x10fc07('0x23c')]})[_0x10fc07('0xa44')][_0x10fc07('0x1166')](function(_0x2e7d27){const _0x3dcab1=_0x10fc07;return _0x2cfb05()(_0x2e7d27[_0x3dcab1('0x2876')]())[_0x3dcab1('0x1414')](_0x3dcab1('0x122a'))[_0x3dcab1('0x1ac1')]()[_0x3dcab1('0x2563')](function(_0x204524){return _0x454b00(_0x204524);})['value']();})['then'](function(_0x42c412){const _0x3303bc=_0x10fc07;_0x47802c['advancedSearch'][_0x3303bc('0xfe2')]=_0x42c412;const _0x410663={'name':_0x3303bc('0x21c2'),'column':'Tag','type':'multiselect','options':{'route':{'model':'tag','action':_0x3303bc('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':['$notIn']}};let _0x4e745f=_0x2cfb05()[_0x3303bc('0xede')](_0x42c412,function(_0x24cc4e){const _0xd0be00=_0x3303bc;return _0x2cfb05()['startsWith'](_0x24cc4e[_0xd0be00('0x226d')],_0xd0be00('0x711'));})||_0x42c412[_0x3303bc('0x264b')]-0x1;if(_0x4e745f<0x0)_0x4e745f=_0x42c412[_0x3303bc('0x264b')];_0x47802c[_0x3303bc('0x1291')][_0x3303bc('0xfe2')][_0x3303bc('0x57b')](_0x4e745f,0x0,_0x410663);})[_0x10fc07('0x1a80')](function(_0x2cc740){const _0x438a79=_0x10fc07;_0xf2ae32[_0x438a79('0xfc9')]({'title':_0x2cc740[_0x438a79('0x52d')]?_0x438a79('0x1e21')+_0x2cc740['status']+_0x438a79('0x11e1')+_0x2cc740['statusText']:_0x438a79('0x7'),'msg':_0x2cc740[_0x438a79('0x25f4')]?JSON[_0x438a79('0xbac')](_0x2cc740[_0x438a79('0x25f4')][_0x438a79('0x1e70')]):_0x2cc740[_0x438a79('0x1586')]()});});}function _0x454b00(_0x740b2a){const _0x223ba2=_0x567733,_0x4a8b27={'name':_0x2cfb05()[_0x223ba2('0xb35')](_0x740b2a[_0x223ba2('0x123d')]),'column':_0x740b2a[_0x223ba2('0x24b3')],'options':{}};if(_0x740b2a[_0x223ba2('0x2853')])switch(_0x740b2a[_0x223ba2('0x2853')]['type']){case _0x223ba2('0x1640'):_0x4a8b27[_0x223ba2('0x1345')]=_0x223ba2('0x1640');break;case _0x223ba2('0x88a'):_0x4a8b27[_0x223ba2('0x1345')]=_0x223ba2('0x2162'),_0x4a8b27[_0x223ba2('0x1ac1')]=_0x2cfb05()[_0x223ba2('0x2563')](JSON[_0x223ba2('0x1295')](_0x740b2a[_0x223ba2('0x2853')][_0x223ba2('0x1ac1')]),function(_0x24648f,_0x42aac8){const _0x226c53=_0x223ba2;return{'id':_0x42aac8,'name':_0x24648f[_0x226c53('0x18e0')],'value':_0x24648f[_0x226c53('0x18e0')]};}),_0x4a8b27[_0x223ba2('0xd39')]['field']=_0x223ba2('0x4f0');break;case _0x223ba2('0x6f4'):_0x4a8b27[_0x223ba2('0x1345')]='select',_0x4a8b27[_0x223ba2('0x1ac1')]=[{'id':0x1,'translate':'DASHBOARDS.ENABLED'},{'id':0x0,'translate':_0x223ba2('0x2190')}],_0x4a8b27[_0x223ba2('0xd39')][_0x223ba2('0x6f5')]=[_0x223ba2('0x2646')];break;case'number':_0x4a8b27[_0x223ba2('0x1345')]=_0x223ba2('0xc45');break;case _0x223ba2('0x7db'):_0x4a8b27['type']=_0x223ba2('0x1643');break;}else switch(_0x740b2a[_0x223ba2('0x24b3')]){case _0x223ba2('0x17a0'):_0x4a8b27[_0x223ba2('0x1345')]=_0x223ba2('0x1643');break;case _0x223ba2('0x537'):_0x4a8b27[_0x223ba2('0x4f0')]=_0x223ba2('0xb82'),_0x4a8b27[_0x223ba2('0x1345')]='autocomplete',_0x4a8b27[_0x223ba2('0xd39')]['route']={'model':_0x223ba2('0xc39'),'action':_0x223ba2('0xd83'),'params':{'fields':_0x223ba2('0x1776'),'nolimit':!![]}},_0x4a8b27[_0x223ba2('0xd39')][_0x223ba2('0x4d2')]=['name'],_0x4a8b27[_0x223ba2('0xd39')][_0x223ba2('0x6f5')]=[_0x223ba2('0x2646')];break;case _0x223ba2('0x23c'):_0x4a8b27['name']='List',_0x4a8b27[_0x223ba2('0x1345')]=_0x223ba2('0x1a01'),_0x4a8b27[_0x223ba2('0xd39')][_0x223ba2('0x16a8')]={'model':_0x223ba2('0x557'),'action':_0x223ba2('0x5a1'),'params':{'id':_0x47802c[_0x223ba2('0x98')]['id'],'fields':'id,name','nolimit':!![]}},_0x4a8b27['options'][_0x223ba2('0x4d2')]=[_0x223ba2('0x4f0')],_0x4a8b27[_0x223ba2('0xd39')][_0x223ba2('0x6f5')]=[_0x223ba2('0x2646')];break;default:if(_0x2cfb05()[_0x223ba2('0x1257')](_0x740b2a['type'][_0x223ba2('0x2574')](),_0x223ba2('0x15eb')))_0x4a8b27[_0x223ba2('0x1345')]=_0x223ba2('0xc45');else _0x2cfb05()[_0x223ba2('0x1257')](_0x740b2a[_0x223ba2('0x1345')]['toLowerCase'](),_0x223ba2('0x1643'))?_0x4a8b27[_0x223ba2('0x1345')]=_0x223ba2('0x1643'):_0x4a8b27[_0x223ba2('0x1345')]=_0x223ba2('0x1640');break;}return _0x4a8b27;}function _0x262584(){const _0x33af14=_0x567733;_0x47802c[_0x33af14('0x7cc')]=![],_0x1f65e3[_0x33af14('0x1f80')]({'controller':_0x33af14('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0x33af14('0x1194')](_0x259d6a[_0x33af14('0x8d2')]),'clickOutsideToClose':![],'locals':{'color':_0x47802c[_0x33af14('0xb1f')],'fields':_0x47802c['advancedSearch']['fields'],'storagePath':'home.mycontacts'},'fullscreen':!![]})['then'](function(_0x41e684){const _0x5db800=_0x33af14;_0x47802c[_0x5db800('0x2218')][_0x5db800('0xe07')]=_0x41e684===![]?undefined:_0x41e684;if(_0x41e684===![])_0x55d8f7();else _0x47802c[_0x5db800('0x2218')][_0x5db800('0xe07')]&&(_0x47802c[_0x5db800('0x2218')][_0x5db800('0xe07')]+=_0x5db800('0x17a5')+_0x47802c[_0x5db800('0x98')]['id']+']',_0x55d8f7());})[_0x33af14('0x1a80')](function(_0x532e60){const _0x2fd605=_0x33af14;_0xf2ae32['error']({'title':'ERROR','msg':_0x532e60[_0x2fd605('0x25f4')]?JSON[_0x2fd605('0xbac')](_0x532e60[_0x2fd605('0x25f4')][_0x2fd605('0x1e70')]):_0x532e60[_0x2fd605('0x1586')]()});});}let _0x3c0fea=!![],_0x2af876=0x1;_0x3a1149['$watch']('vm.query.filter',function(_0x23939c,_0x5411e5){const _0x45617a=_0x567733;_0x3c0fea?_0x172f15(function(){_0x3c0fea=![];}):(!_0x5411e5&&(_0x2af876=_0x47802c['query']['page']),_0x23939c!==_0x5411e5&&(_0x47802c['query'][_0x45617a('0x1a43')]=0x1),!_0x23939c&&(_0x47802c[_0x45617a('0x2218')][_0x45617a('0x1a43')]=_0x2af876),_0x55d8f7());});}const _0x1d2614=_0x2c3840;_0x26c598['$inject']=['$scope','$timeout',_0x36e6f4('0x265d'),'$document','$window',_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'socket','toasty',_0x36e6f4('0x102a')];function _0x26c598(_0xc5202d,_0xa71f71,_0x47be93,_0x3c4a90,_0x4025ce,_0x2053af,_0x277419,_0xedf049,_0x4cde77,_0x28a4c3,_0x44de6b){const _0x1487f5=_0x36e6f4,_0x4d2a46=this;_0x4d2a46[_0x1487f5('0x557')]=_0xedf049['getCurrentUser'](),_0x4d2a46['license']={},_0x4d2a46['setting']={},_0x4d2a46[_0x1487f5('0xb38')]={'count':0x0,'rows':[]},_0x4d2a46['openchannelInteractions']={'count':0x0,'rows':[]},_0x4d2a46['query']={'includeAll':!![],'sort':_0x1487f5('0x14dc'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x4d2a46['advancedSearch']={'fields':[{'name':'Id','column':'id','type':_0x1487f5('0xc45')},{'name':_0x1487f5('0x21a4'),'column':_0x1487f5('0x21a4'),'type':_0x1487f5('0x1a01'),'options':{'searchFields':['firstName',_0x1487f5('0xeb0'),_0x1487f5('0x66f')],'route':{'model':_0x1487f5('0x149e'),'action':'get','params':{'fields':_0x1487f5('0x18eb'),'Contact':_0x1487f5('0x145b'),'nolimit':!![]}},'extraOperators':[_0x1487f5('0x2836')],'excludedOperators':[_0x1487f5('0x2646')]}},{'name':_0x1487f5('0xe1'),'column':_0x1487f5('0x8d2'),'type':_0x1487f5('0x1640'),'options':{'excludedOperators':[_0x1487f5('0x110'),'$ne']}},{'name':_0x1487f5('0x28f6'),'column':'closed','type':_0x1487f5('0x88a'),'values':[{'id':0x0,'translate':_0x1487f5('0xdeb')},{'id':0x1,'translate':_0x1487f5('0x58f')}],'options':{'excludedOperators':[_0x1487f5('0x2646')]}},{'name':'Agent','column':_0x1487f5('0x1a6f'),'type':_0x1487f5('0x1a01'),'options':{'table':'i','route':{'model':_0x1487f5('0x557'),'action':'get','params':{'role':'agent','fields':_0x1487f5('0xce1'),'nolimit':!![]}},'searchFields':[_0x1487f5('0x6e1'),_0x1487f5('0x4f0')],'extraOperators':[_0x1487f5('0x2836')],'excludedOperators':['$ne']}},{'name':_0x1487f5('0x1758'),'column':_0x1487f5('0xb8'),'type':'multiselect','options':{'route':{'model':_0x1487f5('0x557'),'action':_0x1487f5('0xc48'),'params':{'id':_0x4d2a46[_0x1487f5('0x557')]['id'],'nolimit':!![]}}}},{'name':_0x1487f5('0x21c2'),'column':_0x1487f5('0x1b35'),'type':_0x1487f5('0x2162'),'options':{'route':{'model':_0x1487f5('0x1446'),'action':'get','params':{'nolimit':!![]}},'excludedOperators':[_0x1487f5('0x18d')]}},{'name':_0x1487f5('0x2567'),'column':_0x1487f5('0x262'),'type':_0x1487f5('0x1643'),'options':{'excludedOperators':[_0x1487f5('0x2646')]}},{'name':_0x1487f5('0xf43'),'column':_0x1487f5('0x723'),'type':_0x1487f5('0x88a'),'values':[{'id':0x1,'translate':_0x1487f5('0x1057')},{'id':0x0,'translate':_0x1487f5('0x2c8')}],'options':{'excludedOperators':['$ne']}}]},_0x4d2a46['sectionColor']=_0x1487f5('0x47b'),_0x4d2a46[_0x1487f5('0xae0')]=_0x2d7995,_0x4d2a46[_0x1487f5('0x103b')]=_0x49948d,_0x4d2a46['getOpenchannelInteractions']=_0x5478ca,_0x4d2a46[_0x1487f5('0x1854')]=_0x596efe,_0x4d2a46['downloadOpenchannelInteraction']=_0xc323a9,_0x4d2a46[_0x1487f5('0xb52')]=_0x45203a,_0x4d2a46[_0x1487f5('0x250c')]=_0xd7db0b,_0x4d2a46[_0x1487f5('0x2253')]=_0x13d3a3,_0x4d2a46['getOpenchannelAccountLabel']=_0x3a1a09,_0x4d2a46[_0x1487f5('0x4db')]=_0x1202a8,_0x4d2a46[_0x1487f5('0x109e')]=_0x2874ec,_0x4d2a46[_0x1487f5('0x3c5')]=_0x13b7dd,_0x4d2a46[_0x1487f5('0x138b')]=_0x79cfe;function _0x2d7995(_0x525910,_0x105a1e){const _0x5969ce=_0x1487f5;return _0x4d2a46[_0x5969ce('0x5c9')]=_0x525910,_0x4d2a46[_0x5969ce('0xf8a')]=_0x105a1e,_0x277419['user'][_0x5969ce('0xd83')+_0x2cfb05()[_0x5969ce('0x114b')](_0x5969ce('0x28ff'))]({'id':_0x4d2a46[_0x5969ce('0x557')]['id'],'nolimit':!![]})[_0x5969ce('0xa44')]['then'](function(_0x246bd8){const _0xd26f51=_0x5969ce;return _0x4d2a46[_0xd26f51('0x28ff')]=_0x246bd8||{'count':0x0,'rows':[]},_0x277419[_0xd26f51('0x1446')]['get']()['$promise'];})['then'](function(_0x362fc3){const _0xd8f94d=_0x5969ce;_0x4d2a46[_0xd8f94d('0xb38')]=_0x362fc3||{'count':0x0,'rows':[]};})[_0x5969ce('0x1166')](function(){const _0x25e1f3=_0x5969ce;_0x4d2a46[_0x25e1f3('0x6cb')]=_0x3e84ae();})[_0x5969ce('0x1a80')](function(_0x54ae77){console['error'](_0x54ae77);})[_0x5969ce('0x1951')](function(){const _0x394e43=_0x5969ce;let _0x591200=_0x4025ce[_0x394e43('0x275')]['getItem'](_0x394e43('0x1ae0')+_0x4d2a46[_0x394e43('0x557')]['id']);if(_0x591200)try{_0x591200=JSON[_0x394e43('0x1295')](_0x591200);if(_0x591200[_0x394e43('0x2218')]){_0x4d2a46[_0x394e43('0x2218')]=_0x2cfb05()[_0x394e43('0xcc3')](_0x4d2a46['query'],_0x591200[_0x394e43('0x2218')]);if(_0x2cfb05()[_0x394e43('0x1081')](_0x4d2a46[_0x394e43('0x28ff')][_0x394e43('0x269a')]))_0x4d2a46[_0x394e43('0x2218')][_0x394e43('0xb8')]=[];else _0x2cfb05()[_0x394e43('0x1081')](_0x4d2a46['query'][_0x394e43('0xb8')])&&(_0x4d2a46[_0x394e43('0x2218')]['OpenchannelAccountId']=_0x2cfb05()(_0x4d2a46[_0x394e43('0x28ff')]['rows'])['map']('id')['take']()[_0x394e43('0x18e0')]());_0x4d2a46[_0x394e43('0x2218')][_0x394e43('0x1aba')]&&_0x4d2a46['query'][_0x394e43('0x1aba')][_0x394e43('0x2379')](_0x394e43('0x1522'))>=0x0&&(_0x4d2a46[_0x394e43('0x2218')]=_0x2cfb05()[_0x394e43('0x1414')](_0x4d2a46['query'],_0x394e43('0x1aba'))),_0x4d2a46['query'][_0x394e43('0x220e')]=!![],_0x4d2a46['isSearchBarVisible']=_0x4d2a46[_0x394e43('0x2218')]['filter']?!![]:![];}}catch(_0xd438b4){console['error'](_0xd438b4);}else{const _0x1905bd={'$gte':_0x24273b()()['startOf'](_0x394e43('0x2e7'))[_0x394e43('0x13f2')](0x0,!![])[_0x394e43('0x128a')](),'$lte':_0x24273b()()['endOf'](_0x394e43('0x2e7'))[_0x394e43('0x13f2')](0x0,!![])['format']()},_0x47f7c6={'OpenchannelAccountId':_0x2cfb05()[_0x394e43('0x2563')](_0x4d2a46[_0x394e43('0x28ff')]['rows'],'id'),'createdAt':_0x1905bd};_0x4d2a46['query']=_0x2cfb05()[_0x394e43('0xcc3')](_0x4d2a46[_0x394e43('0x2218')],_0x47f7c6);}_0x4cde77['on']('openchannelInteraction:save',_0x5eaf95),_0x4cde77['on'](_0x394e43('0x130b'),_0x5eaf95),_0x4cde77['on'](_0x394e43('0x103c'),_0x520cca),_0x4cde77['on'](_0x394e43('0x11eb'),_0x233baf),_0x4cde77['on'](_0x394e43('0x239e'),_0x233baf),_0x4cde77['on']('user_has_openchannel_interactions:save',_0x4124ea),_0x4cde77['on'](_0x394e43('0x2791'),_0x215185),_0x5478ca(_0x4d2a46[_0x394e43('0x2218')][_0x394e43('0x1a43')]);});}function _0x3e84ae(){const _0x558332=_0x1487f5;return[{'name':'Start\x20Date','key':'createdAt','type':_0x558332('0x1643'),'label':_0x558332('0x16d9')},{'name':_0x558332('0x116c'),'key':_0x558332('0x123'),'type':_0x558332('0x88a'),'label':'DASHBOARDS.SELECT_READ_UNREAD','customOptions':[{'value':0x0,'translate':_0x558332('0x2c8')},{'value':0x1,'translate':_0x558332('0x1057')},{'value':null,'translate':_0x558332('0x2150')}]},{'name':_0x558332('0x28f6'),'key':_0x558332('0xa5b'),'type':_0x558332('0x88a'),'label':'DASHBOARDS.SELECT_STATUS','customOptions':[{'value':0x0,'translate':_0x558332('0xdeb')},{'value':0x1,'translate':_0x558332('0x58f')},{'value':null,'translate':_0x558332('0x2150')}]},{'name':_0x558332('0x1758'),'key':_0x558332('0xb8'),'type':_0x558332('0x2162'),'label':'DASHBOARDS.SELECT_ACCOUNT','options':_0x4d2a46[_0x558332('0x28ff')]['rows'],'clearAll':![]},{'name':_0x558332('0x89b'),'key':'UserId','type':_0x558332('0x88a'),'label':_0x558332('0x1db1'),'customOptions':[{'value':_0x4d2a46['user']['id'],'translate':'DASHBOARDS.ME'},{'value':_0x558332('0x15d7'),'translate':_0x558332('0x216b')},{'value':undefined,'translate':_0x558332('0x2150')}]},{'name':'Tag','key':_0x558332('0x1446'),'type':_0x558332('0x2162'),'label':_0x558332('0x1669'),'options':_0x4d2a46[_0x558332('0xb38')][_0x558332('0x269a')],'placeholder':_0x558332('0x2223')}];}function _0x49948d(_0x55468c){const _0x376776=_0x1487f5;_0x4d2a46[_0x376776('0x293')]=![],_0x4d2a46['openchannelInteractions']=_0x55468c||{'count':0x0,'rows':[]};for(let _0x1ff9c1=0x0;_0x1ff9c1<_0x4d2a46[_0x376776('0x1388')][_0x376776('0x269a')][_0x376776('0x264b')];_0x1ff9c1+=0x1){_0xd7db0b(_0x4d2a46[_0x376776('0x1388')][_0x376776('0x269a')][_0x1ff9c1]);}}function _0x5478ca(_0x21b01f){const _0x3f95e7=_0x1487f5;_0x4d2a46['searchInProgress']=!![];!_0x21b01f&&(_0x4d2a46[_0x3f95e7('0x2218')][_0x3f95e7('0x1a43')]=0x1);_0x4d2a46[_0x3f95e7('0x2218')][_0x3f95e7('0x1098')]=(_0x4d2a46['query'][_0x3f95e7('0x1a43')]-0x1)*_0x4d2a46[_0x3f95e7('0x2218')][_0x3f95e7('0x163f')];let _0x3626b6=_0x4025ce[_0x3f95e7('0x275')]['getItem']('motion2.home.openchannel:'+_0x4d2a46[_0x3f95e7('0x557')]['id']);_0x3626b6=_0x3626b6?JSON[_0x3f95e7('0x1295')](_0x3626b6):{},_0x3626b6[_0x3f95e7('0x2218')]=_0x4d2a46['query'],_0x4025ce[_0x3f95e7('0x275')][_0x3f95e7('0xa26')](_0x3f95e7('0x1ae0')+_0x4d2a46[_0x3f95e7('0x557')]['id'],JSON[_0x3f95e7('0xbac')](_0x3626b6)),_0x4d2a46[_0x3f95e7('0x1f48')]=_0x277419['openchannelInteraction'][_0x3f95e7('0xd83')](_0x4d2a46['query'],_0x49948d)[_0x3f95e7('0xa44')];}function _0x596efe(_0xe4f095,_0x547804){const _0x173fdb=_0x1487f5;_0xc5202d['$parent']['vm'][_0x173fdb('0x126e')](_0x173fdb('0x26c'),_0x547804);}function _0xc323a9(_0x52be68,_0x4a5857,_0x219c66){const _0x62c7c6=_0x1487f5;_0x277419[_0x62c7c6('0x1b9e')]['download']({'id':_0x4a5857['id'],'attachments':_0x219c66})['$promise'][_0x62c7c6('0x1166')](function(_0x455403){const _0x3fead9=_0x62c7c6,_0x28fc4a=[_0x455403[_0x3fead9('0x20ed')]],_0x7c2af5='openchannel-interaction'+_0x4a5857['id']+'.zip',_0x4fd975=new Blob(_0x28fc4a,{'type':_0x455403[_0x3fead9('0x1345')]}),_0x25e1a2=window[_0x3fead9('0x136d')][_0x3fead9('0xdd')]('a');_0x25e1a2[_0x3fead9('0xffd')](_0x3fead9('0x14f9'),URL[_0x3fead9('0x215a')](_0x4fd975)),_0x25e1a2[_0x3fead9('0xffd')](_0x3fead9('0x2ad'),_0x7c2af5),document[_0x3fead9('0x8d2')][_0x3fead9('0x21a')](_0x25e1a2),_0x25e1a2[_0x3fead9('0x3b4')]();})['catch'](function(_0x558c5c){const _0x178b2a=_0x62c7c6;if(_0x558c5c[_0x178b2a('0x25f4')]&&_0x558c5c['data'][_0x178b2a('0x61a')]&&_0x558c5c[_0x178b2a('0x25f4')][_0x178b2a('0x61a')][_0x178b2a('0x264b')])for(let _0xcd399f=0x0;_0xcd399f<_0x558c5c[_0x178b2a('0x25f4')]['errors'][_0x178b2a('0x264b')];_0xcd399f+=0x1){_0x28a4c3[_0x178b2a('0xfc9')]({'title':_0x558c5c[_0x178b2a('0x25f4')][_0x178b2a('0x61a')][_0xcd399f][_0x178b2a('0x1345')],'msg':_0x558c5c[_0x178b2a('0x25f4')][_0x178b2a('0x61a')][_0xcd399f][_0x178b2a('0x1e70')]});}else _0x28a4c3['error']({'title':_0x558c5c[_0x178b2a('0x52d')]?'API:'+_0x558c5c[_0x178b2a('0x52d')]+_0x178b2a('0x11e1')+_0x558c5c[_0x178b2a('0xe1b')]:_0x178b2a('0xe19'),'msg':_0x558c5c[_0x178b2a('0x25f4')]?JSON[_0x178b2a('0xbac')](_0x558c5c[_0x178b2a('0x25f4')]['message']):_0x558c5c['toString']()});});}function _0x45203a(_0x32072,_0x5996c6){const _0x4a8324=_0x1487f5,_0x4e3c85=_0x4d2a46[_0x4a8324('0x557')][_0x4a8324('0x2540')]||_0x4d2a46[_0x4a8324('0x557')][_0x4a8324('0x1c5c')]||_0x4d2a46[_0x4a8324('0x557')][_0x4a8324('0xb4')]||_0x4d2a46['user']['openchannelPause']||_0x4d2a46[_0x4a8324('0x557')]['faxPause'],_0x2c2bfb=!_0x5996c6[_0x4a8324('0x1758')][_0x4a8324('0x10d0')];_0x47be93[_0x4a8324('0x1f80')]({'controller':_0x4a8324('0xa39'),'controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular[_0x4a8324('0x1194')](_0x3c4a90['body']),'clickOutsideToClose':_0x2c2bfb,'escapeToClose':_0x2c2bfb,'onRemoving':function(){const _0x137771=_0x4a8324;_0x4d2a46[_0x137771('0x557')]&&_0x5996c6[_0x137771('0x1758')]['mandatoryDisposition']&&!_0x4e3c85&&_0x277419[_0x137771('0x557')][_0x137771('0x20eb')]({'id':_0x4d2a46[_0x137771('0x557')]['id']})[_0x137771('0xa44')]['catch'](function(_0xa070b9){console['error'](_0xa070b9);});},'locals':{'user':_0x4d2a46['user'],'channel':'openchannel','interaction':_0x5996c6}});}function _0xd7db0b(_0x5d9b12){const _0x254f33=_0x1487f5;if(_0x5d9b12[_0x254f33('0x661')])_0x5d9b12['contactName']=_0x5d9b12['from'];else _0x5d9b12[_0x254f33('0x21a4')]?_0x5d9b12[_0x254f33('0x15cf')]=(_0x5d9b12[_0x254f33('0x21a4')][_0x254f33('0x18cb')]||'')+'\x20'+(_0x5d9b12[_0x254f33('0x21a4')][_0x254f33('0xeb0')]||''):_0x5d9b12['contactName']=_0x2053af['instant'](_0x254f33('0x148c'));}function _0x13d3a3(_0x1619b4){const _0x456bb8=_0x1487f5;if(_0x1619b4[_0x456bb8('0x122a')])return _0x1619b4['UserId']===_0x4d2a46['user']['id']?_0x2053af['instant'](_0x456bb8('0x15ae')):_0x1619b4['Owner'][_0x456bb8('0x6e1')]+'\x20<'+_0x1619b4['Owner'][_0x456bb8('0x1eef')]+'>';return _0x2053af[_0x456bb8('0x25cc')]('DASHBOARDS.NOT_ASSIGNED');}function _0x3a1a09(_0x513d74){const _0x293df0=_0x1487f5;if(_0x513d74[_0x293df0('0x1758')])return _0x513d74['Account'][_0x293df0('0x7ca')];return _0x2053af[_0x293df0('0x25cc')](_0x293df0('0x148c'));}function _0x1202a8(_0x5a9350,_0x99d51a){const _0x519366=_0x1487f5;_0x47be93[_0x519366('0x1f80')]({'controller':'ComposeOpenchannelInteractionDialogController','controllerAs':'vm','templateUrl':_0x283752,'parent':angular['element'](_0x3c4a90['body']),'clickOutsideToClose':![],'locals':{'account':_0x99d51a,'message':{},'type':_0x519366('0xd11'),'interaction':{}},'fullscreen':!![]})['then'](function(_0xdc2ad4){const _0xbd1d4b=_0x519366;if(_0xdc2ad4){if(_0xdc2ad4['message']&&_0xdc2ad4['message']['savedAsDraft']){const _0x358784={'channel':'openchannel','account':_0x99d51a,'message':_0xdc2ad4['message'],'contact':_0xdc2ad4[_0xbd1d4b('0x26db')]};_0x44de6b['add'](_0x358784);}else{const _0x2afcac=_0xdc2ad4;return _0x277419['openchannelAccount'][_0xbd1d4b('0x20ba')]({'id':_0x99d51a['id']},_0x2afcac)[_0xbd1d4b('0xa44')][_0xbd1d4b('0x1166')](function(_0x23d98d){const _0x1d0f91=_0xbd1d4b;_0x28a4c3['success']({'title':_0x1d0f91('0x11ac'),'msg':_0x1d0f91('0x1605')}),_0xc5202d[_0x1d0f91('0x23ac')]['vm'][_0x1d0f91('0x126e')](_0x1d0f91('0x26c'),_0x23d98d);})[_0xbd1d4b('0x1a80')](function(_0x72f13c){const _0x305e3f=_0xbd1d4b;if(_0x72f13c['data']&&_0x72f13c[_0x305e3f('0x25f4')][_0x305e3f('0x61a')]&&_0x72f13c['data'][_0x305e3f('0x61a')][_0x305e3f('0x264b')])for(let _0x258d65=0x0;_0x258d65<_0x72f13c[_0x305e3f('0x25f4')][_0x305e3f('0x61a')][_0x305e3f('0x264b')];_0x258d65++){_0x28a4c3[_0x305e3f('0xfc9')]({'title':_0x72f13c['data']['errors'][_0x258d65][_0x305e3f('0x1345')],'msg':_0x72f13c[_0x305e3f('0x25f4')][_0x305e3f('0x61a')][_0x258d65][_0x305e3f('0x1e70')]});}else _0x28a4c3['error']({'title':_0x72f13c[_0x305e3f('0x52d')]?'API:'+_0x72f13c[_0x305e3f('0x52d')]+'\x20-\x20'+_0x72f13c['statusText']:_0x305e3f('0x210e'),'msg':_0x72f13c[_0x305e3f('0x25f4')]?JSON[_0x305e3f('0xbac')](_0x72f13c[_0x305e3f('0x25f4')]['message']):_0x72f13c[_0x305e3f('0x1e70')]||_0x72f13c[_0x305e3f('0x1586')]()});});}}});}function _0x4124ea(_0x1375ef){const _0x423a0d=_0x1487f5;let _0x5b7832;const _0x52f911=_0x2cfb05()[_0x423a0d('0xc38')](_0x4d2a46['openchannelInteractions'][_0x423a0d('0x269a')],{'id':_0x1375ef[_0x423a0d('0x236b')]});_0x52f911&&_0x52f911[_0x423a0d('0x1bc7')]&&(_0x5b7832=_0x2cfb05()[_0x423a0d('0xc38')](_0x52f911[_0x423a0d('0x1bc7')],{'id':_0x1375ef[_0x423a0d('0x122a')]}),!_0x5b7832&&_0x52f911[_0x423a0d('0x1bc7')][_0x423a0d('0x1514')]({'id':_0x1375ef[_0x423a0d('0x122a')]}));}function _0x215185(_0x215926){const _0x21a725=_0x1487f5,_0x5469b4=_0x2cfb05()[_0x21a725('0xc38')](_0x4d2a46[_0x21a725('0x1388')][_0x21a725('0x269a')],{'id':_0x215926[_0x21a725('0x236b')]});_0x5469b4&&_0x5469b4['Users']&&_0x2cfb05()[_0x21a725('0x127f')](_0x5469b4[_0x21a725('0x1bc7')],{'id':_0x215926['UserId']});}function _0x5eaf95(_0x5a0367){const _0x4b12d7=_0x1487f5;if(_0x5a0367){const _0x5744bd=_0x2cfb05()[_0x4b12d7('0xc38')](_0x4d2a46[_0x4b12d7('0x1388')][_0x4b12d7('0x269a')],{'id':_0x5a0367['id']});if(_0x5744bd){_0x5744bd[_0x4b12d7('0x1bc7')]=[];_0x5a0367[_0x4b12d7('0xa5b')]&&(_0x5744bd['unreadMessages']=0x0);if(_0x4d2a46[_0x4b12d7('0x2218')]['sort']){const _0x356673=_0x2cfb05()[_0x4b12d7('0x1783')](_0x4d2a46[_0x4b12d7('0x2218')][_0x4b12d7('0x1aba')],'-')?'desc':_0x4b12d7('0x17d');_0x4d2a46[_0x4b12d7('0x1388')][_0x4b12d7('0x269a')]=_0x2cfb05()[_0x4b12d7('0xe63')](_0x4d2a46[_0x4b12d7('0x1388')][_0x4b12d7('0x269a')],_0x2cfb05()[_0x4b12d7('0x19db')](_0x4d2a46[_0x4b12d7('0x2218')][_0x4b12d7('0x1aba')],'-'),_0x356673);}_0x2cfb05()['merge'](_0x5744bd,_0x2cfb05()[_0x4b12d7('0x1a08')](_0x5a0367,_0x2cfb05()[_0x4b12d7('0x14a4')](_0x5744bd)));}else _0x5478ca(_0x4d2a46['query'][_0x4b12d7('0x1a43')]);}}function _0x520cca(_0x58c51d){const _0x510d49=_0x1487f5;if(_0x58c51d){const _0x5ce74e=_0x2cfb05()[_0x510d49('0xc38')](_0x4d2a46[_0x510d49('0x1388')]['rows'],{'id':_0x58c51d['id']});_0x5ce74e&&(_0x5ce74e[_0x510d49('0x21c2')]=_0x58c51d[_0x510d49('0xb38')]||[],_0x2cfb05()[_0x510d49('0xcc3')](_0x5ce74e,_0x2cfb05()[_0x510d49('0x1a08')](_0x58c51d,_0x2cfb05()[_0x510d49('0x14a4')](_0x5ce74e))));}}function _0x233baf(_0x24bf1f){const _0xdee404=_0x1487f5;if(_0x24bf1f&&!_0x24bf1f['secret']){const _0x3389e1=_0x2cfb05()[_0xdee404('0xc38')](_0x4d2a46[_0xdee404('0x1388')][_0xdee404('0x269a')],{'id':_0x24bf1f[_0xdee404('0x236b')]});if(_0x3389e1){const _0x2ed405=_0x2cfb05()[_0xdee404('0xc38')](_0x3389e1[_0xdee404('0x116c')],{'id':_0x24bf1f['id']});_0x2ed405?_0x2cfb05()[_0xdee404('0xcc3')](_0x2ed405,_0x2cfb05()['pick'](_0x24bf1f,_0x2cfb05()[_0xdee404('0x14a4')](_0x2ed405))):(_0x2cfb05()[_0xdee404('0x2863')](_0x3389e1[_0xdee404('0x116c')])&&(_0x3389e1[_0xdee404('0x116c')]={'count':0x0}),!_0x24bf1f[_0xdee404('0x123')]&&(_0x3389e1[_0xdee404('0x116c')]['count']+=0x1));}}}function _0x2874ec(){const _0x1ec891=_0x1487f5;_0x4d2a46[_0x1ec891('0x7cc')]=![];}function _0x13b7dd(){const _0x3b4f55=_0x1487f5;_0x4d2a46[_0x3b4f55('0x7cc')]=!![];}function _0x79cfe(){const _0x8f01fd=_0x1487f5;_0x4d2a46['isSearchBarVisible']=![],_0x47be93[_0x8f01fd('0x1f80')]({'controller':_0x8f01fd('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0x8f01fd('0x1194')](_0x3c4a90[_0x8f01fd('0x8d2')]),'clickOutsideToClose':![],'locals':{'color':_0x4d2a46['sectionColor'],'fields':_0x4d2a46[_0x8f01fd('0x1291')][_0x8f01fd('0xfe2')],'storagePath':_0x8f01fd('0xb3e')},'fullscreen':!![]})['then'](function(_0x289884){const _0x3c5f8d=_0x8f01fd;_0x4d2a46[_0x3c5f8d('0x2218')][_0x3c5f8d('0xe07')]=_0x289884===![]?undefined:_0x289884;if(_0x4d2a46['query'][_0x3c5f8d('0xe07')]||_0x289884===![])_0x5478ca();})[_0x8f01fd('0x1a80')](function(_0x12f908){const _0x5d60b4=_0x8f01fd;_0x28a4c3[_0x5d60b4('0xfc9')]({'title':_0x5d60b4('0x2272'),'msg':_0x12f908[_0x5d60b4('0x25f4')]?JSON[_0x5d60b4('0xbac')](_0x12f908[_0x5d60b4('0x25f4')][_0x5d60b4('0x1e70')]):_0x12f908[_0x5d60b4('0x1586')]()});});}let _0x43ecec=!![],_0x38a68a=0x1;_0xc5202d['$watch']('vm.query.filter',function(_0x427b83,_0x41b2c6){const _0x8be898=_0x1487f5;_0x43ecec?_0xa71f71(function(){_0x43ecec=![];}):(!_0x41b2c6&&(_0x38a68a=_0x4d2a46[_0x8be898('0x2218')][_0x8be898('0x1a43')]),_0x427b83!==_0x41b2c6&&(_0x4d2a46[_0x8be898('0x2218')][_0x8be898('0x1a43')]=0x1),!_0x427b83&&(_0x4d2a46[_0x8be898('0x2218')][_0x8be898('0x1a43')]=_0x38a68a),_0x5478ca(_0x4d2a46[_0x8be898('0x2218')]['page']));}),_0xc5202d[_0x1487f5('0x3d2')](_0x1487f5('0x1c3f'),function(){const _0x214d0c=_0x1487f5;_0x4cde77[_0x214d0c('0x1800')]('openchannelMessage:save'),_0x4cde77['removeAllListeners']('openchannelMessage:update'),_0x4cde77[_0x214d0c('0x1800')](_0x214d0c('0x14c9')),_0x4cde77[_0x214d0c('0x1800')](_0x214d0c('0x103c')),_0x4cde77[_0x214d0c('0x1800')](_0x214d0c('0x130b')),_0x4cde77[_0x214d0c('0x1800')](_0x214d0c('0x79')),_0x4cde77['removeAllListeners'](_0x214d0c('0x2791'));});}const _0x4ac074=_0x26c598;_0x330be8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1c90'),_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$stateParams',_0x36e6f4('0x5e3'),_0x36e6f4('0x21ef')];function _0x330be8(_0x1f55c8,_0x480ccb,_0x341e9c,_0x55428b,_0x174212,_0x3fbf1c,_0x51f59a){const _0x3ec963=_0x36e6f4,_0x3255e6=this;_0x3255e6[_0x3ec963('0x98')]=_0x51f59a[_0x3ec963('0x26cd')](),_0x3255e6['plugin']={};function _0x39daf5(_0x4504c7,_0x93936c,_0x41aecc){const _0x47162c=_0x3ec963;_0x3255e6[_0x47162c('0x5c9')]=_0x4504c7,_0x3255e6[_0x47162c('0xf8a')]=_0x93936c,_0x3255e6[_0x47162c('0xc0e')]=_0x41aecc;}function _0x2d5599(){const _0x142d12=_0x3ec963;return _0x3fbf1c[_0x142d12('0xd8c')](_0x3255e6[_0x142d12('0xc0e')][_0x142d12('0x86')]);}_0x480ccb[_0x3ec963('0x3d2')]('pluginUpdated',function(_0x5cbc0b,_0x474e55){_0x3255e6['plugin']=_0x474e55['plugin'];}),_0x3255e6[_0x3ec963('0xae0')]=_0x39daf5,_0x3255e6[_0x3ec963('0x159a')]=_0x2d5599,_0x39daf5();}const _0x2d27a7=_0x330be8;_0x6bf0f7['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x8da'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x6bf0f7(_0x1a669b,_0xff6643,_0x4fe09e,_0x4d46d3,_0x2776dd,_0x1483ae){const _0x511b9a=_0x36e6f4,_0x56a850=this;_0x56a850['currentUser']=_0x1483ae[_0x511b9a('0x26cd')](),_0x56a850[_0x511b9a('0x25d9')]={},_0x56a850['table']=_0x511b9a('0x25d9'),_0x56a850[_0x511b9a('0x2218')]={'UserId':_0x56a850[_0x511b9a('0x98')]['id'],'fields':_0x511b9a('0x7a5'),'sort':_0x511b9a('0x14dc'),'limit':0xa,'page':0x1,'type':null},_0x56a850['downloadfile']=_0xc525eb,_0x56a850[_0x511b9a('0x1ee4')]=_0x2c4de8,_0x56a850['success']=_0x424e4b,_0x56a850['getVoiceRecordings']=_0x2626b2,_0x56a850[_0x511b9a('0xae0')]=_0x1650c1,_0x56a850[_0x511b9a('0x109e')]=_0x1e6e5d,_0x56a850[_0x511b9a('0x3c5')]=_0x149e0a;function _0x1650c1(){const _0x5a2e75=_0x511b9a;_0x56a850[_0x5a2e75('0x6cb')]=_0x48de61();let _0x23ea1b=_0xff6643['localStorage'][_0x5a2e75('0x15f7')]('motion2.home.recordings:'+_0x56a850[_0x5a2e75('0x98')]['id']);if(_0x23ea1b)try{_0x23ea1b=JSON[_0x5a2e75('0x1295')](_0x23ea1b),_0x23ea1b[_0x5a2e75('0x2218')]&&(_0x56a850[_0x5a2e75('0x2218')]=_0x2cfb05()[_0x5a2e75('0x1414')](_0x23ea1b['query'],[_0x5a2e75('0x1c33'),'id']),_0x56a850[_0x5a2e75('0x2218')][_0x5a2e75('0xfe2')]=_0x5a2e75('0x488'),_0x56a850[_0x5a2e75('0x2218')][_0x5a2e75('0x122a')]=_0x56a850[_0x5a2e75('0x98')]['id']);}catch(_0x846b7a){console[_0x5a2e75('0xfc9')](_0x846b7a);}else{const _0xdf93dd={'$gte':_0x24273b()()[_0x5a2e75('0x1659')](_0x5a2e75('0x2e7'))['utcOffset'](0x0,!![])[_0x5a2e75('0x128a')](),'$lte':_0x24273b()()['endOf'](_0x5a2e75('0x2e7'))['utcOffset'](0x0,!![])[_0x5a2e75('0x128a')]()};_0x56a850['query'][_0x5a2e75('0x262')]=_0xdf93dd;}_0x56a850[_0x5a2e75('0x7cc')]=_0x56a850[_0x5a2e75('0x2218')][_0x5a2e75('0x1c33')]?!![]:![],_0x56a850[_0x5a2e75('0x1773')]();}function _0xc525eb(_0x1eb93a){const _0x439200=_0x511b9a;return _0x4d46d3[_0x439200('0x1825')]['download']({'id':_0x1eb93a['id'],'exists':!![]})[_0x439200('0xa44')][_0x439200('0x1166')](function(_0x4782bc){const _0x326592=_0x439200,_0x235d3a=[_0x4782bc[_0x326592('0x20ed')]],_0x510f97=new Blob(_0x235d3a,{'type':_0x4782bc[_0x326592('0x1345')]}),_0x5aa07a=window[_0x326592('0x136d')][_0x326592('0xdd')]('a');_0x5aa07a[_0x326592('0xffd')](_0x326592('0x14f9'),URL[_0x326592('0x215a')](_0x510f97)),_0x5aa07a[_0x326592('0xffd')](_0x326592('0x2ad'),_0x1eb93a['uniqueid']+_0x1eb93a[_0x326592('0x128a')]),_0x5aa07a[_0x326592('0x3b4')]();})[_0x439200('0x1a80')](function(_0x975346){const _0x464758=_0x439200;_0x2776dd['error']({'title':_0x975346['status']?'API:'+_0x975346[_0x464758('0x52d')]+'\x20-\x20'+_0x975346[_0x464758('0xe1b')]:_0x464758('0x9e7'),'msg':_0x975346['data']?JSON['stringify'](_0x975346[_0x464758('0x25f4')]):_0x975346['toString']()});});}function _0x2c4de8(_0x42f52c){const _0xfea3b0=_0x511b9a;return _0x4d46d3[_0xfea3b0('0x1825')]['downloadTranscribe']({'id':_0x42f52c['id']})[_0xfea3b0('0xa44')]['then'](function(_0x336e7a){const _0x202c0b=_0xfea3b0,_0x2917fe=[_0x336e7a[_0x202c0b('0x20ed')]];let _0x30de0f=_0x202c0b('0x2ad');const _0x237f6c=new Blob(_0x2917fe,{'type':_0x336e7a['type']});_0x30de0f=_0x42f52c[_0x202c0b('0x1c21')];const _0x231250=window[_0x202c0b('0x136d')][_0x202c0b('0xdd')]('a');_0x231250[_0x202c0b('0xffd')](_0x202c0b('0x14f9'),URL[_0x202c0b('0x215a')](_0x237f6c)),_0x231250[_0x202c0b('0xffd')](_0x202c0b('0x2ad'),_0x30de0f),document[_0x202c0b('0x8d2')][_0x202c0b('0x21a')](_0x231250),_0x231250[_0x202c0b('0x3b4')]();})[_0xfea3b0('0x1a80')](function(_0x39f5f6){const _0x334735=_0xfea3b0;_0x2776dd[_0x334735('0xfc9')]({'title':_0x39f5f6['status']?'API:'+_0x39f5f6['status']+_0x334735('0x11e1')+_0x39f5f6[_0x334735('0xe1b')]:'SYSTEM:GETvoiceRecording','msg':_0x39f5f6[_0x334735('0x25f4')]?JSON[_0x334735('0xbac')](_0x39f5f6[_0x334735('0x25f4')]):_0x39f5f6[_0x334735('0x1586')]()});});}function _0x48de61(){const _0x1a4d9d=_0x511b9a;return[{'name':_0x1a4d9d('0x2567'),'key':_0x1a4d9d('0x262'),'type':'date','label':_0x1a4d9d('0x16d9')},{'name':_0x1a4d9d('0x1981'),'key':'type','type':_0x1a4d9d('0x88a'),'label':'VOICE.SELECT_TYPE','customOptions':[{'value':_0x1a4d9d('0x1eef'),'translate':'VOICE.INTERNAL'},{'value':_0x1a4d9d('0x14d8'),'translate':_0x1a4d9d('0x255d')},{'value':'outbound','translate':'VOICE.OUTBOUND'},{'value':'dialer','translate':_0x1a4d9d('0x26aa')},{'value':null,'translate':_0x1a4d9d('0x1c5')}]}];}function _0x424e4b(_0x56b09c){const _0x11aa80=_0x511b9a;_0x56a850[_0x11aa80('0x293')]=![],_0x56a850['voiceRecordings']=_0x56b09c||{'count':0x0,'rows':[]};}function _0x2626b2(){const _0xca5966=_0x511b9a;_0x56a850[_0xca5966('0x293')]=!![],_0x56a850[_0xca5966('0x2218')][_0xca5966('0x1098')]=(_0x56a850['query']['page']-0x1)*_0x56a850['query']['limit'];const _0x7971ed={'query':_0x56a850[_0xca5966('0x2218')]};_0xff6643['localStorage'][_0xca5966('0xa26')](_0xca5966('0x71d')+_0x56a850[_0xca5966('0x98')]['id'],JSON['stringify'](_0x7971ed)),_0x56a850[_0xca5966('0x1f48')]=_0x4d46d3[_0xca5966('0x1825')][_0xca5966('0xd83')](_0x56a850['query'],_0x424e4b)[_0xca5966('0xa44')];}function _0x1e6e5d(){const _0x395fb3=_0x511b9a;_0x56a850[_0x395fb3('0x2218')]['filter']=undefined,_0x56a850[_0x395fb3('0x7cc')]=![];}function _0x149e0a(){_0x56a850['isSearchBarVisible']=!![];}let _0x3ec85f=!![],_0xafbe65=0x1;_0x1a669b[_0x511b9a('0xe83')]('vm.query.filter',function(_0x613942,_0x21e88d){const _0x13236b=_0x511b9a;_0x3ec85f?_0x4fe09e(function(){_0x3ec85f=![];}):(!_0x21e88d&&(_0xafbe65=_0x56a850['query'][_0x13236b('0x1a43')]),_0x613942!==_0x21e88d&&(_0x56a850['query'][_0x13236b('0x1a43')]=0x1),!_0x613942&&(_0x56a850[_0x13236b('0x2218')][_0x13236b('0x1a43')]=_0xafbe65),_0x56a850[_0x13236b('0x1773')]());});}const _0x40329e=_0x6bf0f7,_0x8db371=_0x2734b2['p']+'src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/hoppers/dialog.html/dialog.html';_0x4b0d66[_0x36e6f4('0x1294')]=['$scope','$window','$timeout',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x4b0d66(_0x5779a1,_0x12f6ec,_0x3c0251,_0x3b9eea,_0x4d408f,_0x53dfea,_0x1ad4f0,_0x54b3b8){const _0x2bfc71=_0x36e6f4,_0x44fc45=this;_0x44fc45[_0x2bfc71('0x98')]=_0x54b3b8['getCurrentUser'](),_0x44fc45[_0x2bfc71('0x1e69')]=[_0x2bfc71('0x4'),_0x2bfc71('0x2572'),_0x2bfc71('0x3e9'),_0x2bfc71('0xf95'),_0x2bfc71('0xb06')],_0x44fc45[_0x2bfc71('0x243c')]={'readOnly':![],'canEdit':!![],'canDelete':!![]},_0x44fc45[_0x2bfc71('0x1757')]={},_0x44fc45[_0x2bfc71('0x2218')]={'id':_0x44fc45[_0x2bfc71('0x98')]['id'],'fields':_0x2bfc71('0x1ce8'),'sort':_0x2bfc71('0x1c5e'),'limit':0xa,'page':0x1},_0x44fc45[_0x2bfc71('0x182c')]={'rows':[],'count':0x0},_0x44fc45[_0x2bfc71('0x103b')]=_0x3436bb,_0x44fc45['getScheduledCalls']=_0x1bd0af,_0x44fc45[_0x2bfc71('0xae0')]=_0x3e8ecb,_0x44fc45[_0x2bfc71('0x1aa2')]=_0x435b55,_0x44fc45['createOrEditQueueCampaignHopper']=_0x20b5a0,_0x44fc45[_0x2bfc71('0x8a2')]=_0x173922;function _0x3e8ecb(){const _0x5c6e79=_0x2bfc71;_0x1ad4f0[_0x5c6e79('0x557')][_0x5c6e79('0x152a')]({'id':_0x54b3b8[_0x5c6e79('0x26cd')]()['id'],'fields':_0x5c6e79('0x1776'),'channel':'voice','type':_0x5c6e79('0x587'),'nolimit':!![]})[_0x5c6e79('0xa44')]['then'](function(_0x5df5e6){const _0x2bb370=_0x5c6e79;_0x44fc45[_0x2bb370('0x182c')]=_0x5df5e6||{'count':0x0,'rows':[]};})[_0x5c6e79('0x1166')](function(){const _0x3a63fd=_0x5c6e79;_0x44fc45[_0x3a63fd('0x6cb')]=_0x541c30();})[_0x5c6e79('0x1a80')](function(_0x1730ad){const _0x43177e=_0x5c6e79;console[_0x43177e('0xfc9')](_0x1730ad);})[_0x5c6e79('0x1951')](function(){const _0x98e619=_0x5c6e79;let _0x54de00=_0x12f6ec['localStorage'][_0x98e619('0x15f7')](_0x98e619('0x1e64')+_0x44fc45['currentUser']['id']);if(_0x54de00)try{_0x54de00=JSON[_0x98e619('0x1295')](_0x54de00),_0x54de00[_0x98e619('0x2218')]&&(_0x44fc45['query']=_0x2cfb05()[_0x98e619('0x1414')](_0x54de00[_0x98e619('0x2218')],[_0x98e619('0x1c33')]));}catch(_0x412a98){console[_0x98e619('0xfc9')](_0x412a98);}else{const _0x4f7e1f={'$gte':_0x24273b()()['startOf']('month')['utcOffset'](0x0,!![])[_0x98e619('0x128a')](),'$lte':_0x24273b()()[_0x98e619('0x2589')](_0x98e619('0x2e7'))[_0x98e619('0x13f2')](0x0,!![])[_0x98e619('0x128a')]()};_0x44fc45[_0x98e619('0x2218')][_0x98e619('0x262')]=_0x4f7e1f;}_0x44fc45[_0x98e619('0x207d')]();});}function _0x3436bb(_0x33c37f){const _0xe93623=_0x2bfc71;_0x44fc45[_0xe93623('0x293')]=![],_0x44fc45['scheduledCalls']=_0x33c37f||{'count':0x0,'rows':[]};}function _0x541c30(){const _0x39fd91=_0x2bfc71;return[{'name':_0x39fd91('0x2567'),'key':_0x39fd91('0x262'),'type':_0x39fd91('0x1643'),'label':_0x39fd91('0x16d9')},{'name':_0x39fd91('0x1d8c'),'key':_0x39fd91('0xc69'),'type':_0x39fd91('0x2162'),'label':'MOTIONDIALER.SELECT_CAMPAIGN','options':_0x44fc45[_0x39fd91('0x182c')][_0x39fd91('0x269a')]}];}function _0x1bd0af(){const _0x40fac8=_0x2bfc71;_0x44fc45[_0x40fac8('0x293')]=!![],_0x44fc45['query']['id']=_0x44fc45['currentUser']['id'],_0x44fc45[_0x40fac8('0x2218')][_0x40fac8('0x220e')]=!![],_0x44fc45['query'][_0x40fac8('0x1098')]=(_0x44fc45[_0x40fac8('0x2218')][_0x40fac8('0x1a43')]-0x1)*_0x44fc45['query']['limit'];const _0x50b498={'query':_0x44fc45[_0x40fac8('0x2218')]};_0x12f6ec[_0x40fac8('0x275')][_0x40fac8('0xa26')](_0x40fac8('0x1e64')+_0x44fc45['currentUser']['id'],JSON[_0x40fac8('0xbac')](_0x50b498)),_0x44fc45['promise']=_0x1ad4f0[_0x40fac8('0x557')]['getScheduledCalls'](_0x44fc45[_0x40fac8('0x2218')],_0x3436bb)['$promise'];}function _0x20b5a0(_0xe1d4df,_0x22184a){const _0x2f0dcf=_0x2bfc71;_0x3b9eea[_0x2f0dcf('0x1f80')]({'controller':_0x2f0dcf('0x1c8c'),'controllerAs':'vm','templateUrl':_0x8db371,'parent':angular[_0x2f0dcf('0x1194')](_0x4d408f['body']),'targetEvent':_0xe1d4df,'clickOutsideToClose':!![],'locals':{'queueCampaign':null,'hopper':_0x22184a,'hoppers':_0x44fc45[_0x2f0dcf('0x1757')][_0x2f0dcf('0x269a')],'license':null,'setting':null,'crudPermissions':_0x44fc45[_0x2f0dcf('0x243c')]}});}function _0x1600d0(_0x47e232){const _0x44e98a=_0x2bfc71;_0x1ad4f0[_0x44e98a('0x256a')][_0x44e98a('0x906')]({'id':_0x47e232['id']})[_0x44e98a('0xa44')][_0x44e98a('0x1166')](function(){const _0x52ce6b=_0x44e98a;_0x2cfb05()[_0x52ce6b('0x127f')](_0x44fc45[_0x52ce6b('0x1757')][_0x52ce6b('0x269a')],{'id':_0x47e232['id']}),_0x44fc45[_0x52ce6b('0x1757')][_0x52ce6b('0x240f')]-=0x1,!_0x44fc45['scheduledCalls'][_0x52ce6b('0x269a')][_0x52ce6b('0x264b')]&&_0x44fc45[_0x52ce6b('0x207d')](),_0x53dfea[_0x52ce6b('0x103b')]({'title':_0x52ce6b('0x10db'),'msg':_0x47e232[_0x52ce6b('0x4f0')]?_0x52ce6b('0x818'):''});})['catch'](function(_0x9e3a06){const _0x4bd153=_0x44e98a;if(_0x9e3a06['data']&&_0x9e3a06['data']['errors']&&_0x9e3a06[_0x4bd153('0x25f4')]['errors'][_0x4bd153('0x264b')]){_0x44fc45[_0x4bd153('0x61a')]=_0x9e3a06[_0x4bd153('0x25f4')][_0x4bd153('0x61a')]||[{'message':_0x9e3a06['toString'](),'type':_0x4bd153('0x363')}];for(let _0x4d9e1f=0x0;_0x4d9e1f<_0x9e3a06['data'][_0x4bd153('0x61a')][_0x4bd153('0x264b')];_0x4d9e1f++){_0x53dfea[_0x4bd153('0xfc9')]({'title':_0x9e3a06[_0x4bd153('0x25f4')][_0x4bd153('0x61a')][_0x4d9e1f][_0x4bd153('0x1345')],'msg':_0x9e3a06[_0x4bd153('0x25f4')][_0x4bd153('0x61a')][_0x4d9e1f][_0x4bd153('0x1e70')]});}}else _0x53dfea['error']({'title':_0x9e3a06[_0x4bd153('0x52d')]?_0x4bd153('0x1e21')+_0x9e3a06['status']+'\x20-\x20'+_0x9e3a06[_0x4bd153('0xe1b')]:_0x4bd153('0x363'),'msg':_0x9e3a06[_0x4bd153('0x25f4')]?JSON[_0x4bd153('0xbac')](_0x9e3a06['data'][_0x4bd153('0x1e70')]):_0x9e3a06['message']||_0x9e3a06[_0x4bd153('0x1586')]()});});}function _0x173922(_0x338ed5,_0x248f7c){const _0x176ed6=_0x2bfc71,_0x460835=_0x3b9eea[_0x176ed6('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20scheduled\x20call?')[_0x176ed6('0xf3c')](_0x176ed6('0x2367')+_0x176ed6('0x3f3'))[_0x176ed6('0x8e8')](_0x176ed6('0x18c0'))[_0x176ed6('0x203b')](_0x248f7c)['ok']('OK')[_0x176ed6('0x3f')]('CANCEL');_0x3b9eea['show'](_0x460835)[_0x176ed6('0x1166')](function(){_0x1600d0(_0x338ed5);},function(){console['log']('CANCEL');});}function _0x435b55(_0x3e8b3e){const _0x4f88ba=_0x2bfc71;return _0x24273b()(_0x3e8b3e)[_0x4f88ba('0x22fb')](_0x24273b()());}let _0x560e5e=!![],_0xe55786=0x1;_0x5779a1[_0x2bfc71('0xe83')](_0x2bfc71('0x12d8'),function(_0x5d0fa2,_0x5665a8){const _0x332ab4=_0x2bfc71;_0x560e5e?_0x3c0251(function(){_0x560e5e=![];}):(!_0x5665a8&&(_0xe55786=_0x44fc45['query'][_0x332ab4('0x1a43')]),_0x5d0fa2!==_0x5665a8&&(_0x44fc45[_0x332ab4('0x2218')][_0x332ab4('0x1a43')]=0x1),!_0x5d0fa2&&(_0x44fc45[_0x332ab4('0x2218')][_0x332ab4('0x1a43')]=_0xe55786),_0x44fc45[_0x332ab4('0x207d')]());});}const _0x15dbdd=_0x4b0d66;_0x4a22d1[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$window',_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),'Auth','socket','toasty','draftManager'];function _0x4a22d1(_0x48f4ad,_0xadca1b,_0x2d2136,_0x215f2a,_0x1ea317,_0x31f1a5,_0x4f8f47,_0x5e452a,_0x322901,_0x3d8d8d,_0x45c323){const _0x50ec12=_0x36e6f4,_0x57d983=this;_0x57d983[_0x50ec12('0x557')]=_0x5e452a['getCurrentUser'](),_0x57d983[_0x50ec12('0x5c9')]={},_0x57d983[_0x50ec12('0xf8a')]={},_0x57d983['tags']={'count':0x0,'rows':[]},_0x57d983[_0x50ec12('0xb0e')]={'count':0x0,'rows':[]},_0x57d983['query']={'includeAll':!![],'sort':_0x50ec12('0x14dc'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x57d983[_0x50ec12('0x1291')]={'fields':[{'name':'Id','column':'id','type':_0x50ec12('0xc45')},{'name':'Contact','column':_0x50ec12('0x21a4'),'type':_0x50ec12('0x1a01'),'options':{'searchFields':[_0x50ec12('0x18cb'),'lastName','email'],'route':{'model':_0x50ec12('0x149e'),'action':'get','params':{'fields':_0x50ec12('0x18eb'),'Contact':_0x50ec12('0x145b'),'nolimit':!![]}},'extraOperators':['$substring'],'excludedOperators':[_0x50ec12('0x2646')]}},{'name':_0x50ec12('0xe1'),'column':_0x50ec12('0x8d2'),'type':_0x50ec12('0x1640'),'options':{'excludedOperators':[_0x50ec12('0x110'),_0x50ec12('0x2646')]}},{'name':_0x50ec12('0x28f6'),'column':_0x50ec12('0xa5b'),'type':_0x50ec12('0x88a'),'values':[{'id':0x0,'translate':_0x50ec12('0xdeb')},{'id':0x1,'translate':_0x50ec12('0x58f')}],'options':{'excludedOperators':['$ne']}},{'name':_0x50ec12('0x89b'),'column':_0x50ec12('0x1a6f'),'type':_0x50ec12('0x1a01'),'options':{'table':'i','route':{'model':_0x50ec12('0x557'),'action':'get','params':{'role':_0x50ec12('0x1eff'),'fields':_0x50ec12('0xce1'),'nolimit':!![]}},'searchFields':[_0x50ec12('0x6e1'),_0x50ec12('0x4f0')],'extraOperators':[_0x50ec12('0x2836')],'excludedOperators':[_0x50ec12('0x2646')]}},{'name':_0x50ec12('0x1758'),'column':'SmsAccountId','type':'multiselect','options':{'route':{'model':_0x50ec12('0x557'),'action':_0x50ec12('0x1f5d'),'params':{'id':_0x57d983[_0x50ec12('0x557')]['id'],'nolimit':!![]}}}},{'name':'Tags','column':_0x50ec12('0x1b35'),'type':'multiselect','options':{'route':{'model':'tag','action':_0x50ec12('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':[_0x50ec12('0x18d')]}},{'name':_0x50ec12('0x2567'),'column':'createdAt','type':_0x50ec12('0x1643'),'options':{'excludedOperators':[_0x50ec12('0x2646')]}},{'name':'Read','column':_0x50ec12('0x723'),'type':_0x50ec12('0x88a'),'values':[{'id':0x1,'translate':'DASHBOARDS.READ'},{'id':0x0,'translate':_0x50ec12('0x2c8')}],'options':{'excludedOperators':[_0x50ec12('0x2646')]}}]},_0x57d983[_0x50ec12('0xb1f')]=_0x50ec12('0x1adc'),_0x57d983[_0x50ec12('0xae0')]=_0x54fdd1,_0x57d983['success']=_0x55beeb,_0x57d983[_0x50ec12('0x632')]=_0x452870,_0x57d983['showSmsInteraction']=_0xd03aa,_0x57d983[_0x50ec12('0xd8d')]=_0x5db3c2,_0x57d983[_0x50ec12('0xb52')]=_0x2f7a2d,_0x57d983['getContactLabel']=_0x54a424,_0x57d983[_0x50ec12('0x2253')]=_0x15b23d,_0x57d983[_0x50ec12('0x13dd')]=_0x5aa765,_0x57d983[_0x50ec12('0x1a77')]=_0x357cc6,_0x57d983[_0x50ec12('0x109e')]=_0x85f569,_0x57d983[_0x50ec12('0x3c5')]=_0x30f0e2,_0x57d983[_0x50ec12('0x138b')]=_0x450430;function _0x54fdd1(_0x1a73e3,_0x2573a9){const _0x3009a7=_0x50ec12;return _0x57d983[_0x3009a7('0x5c9')]=_0x1a73e3,_0x57d983['setting']=_0x2573a9,_0x4f8f47['user'][_0x3009a7('0xd83')+_0x2cfb05()[_0x3009a7('0x114b')]('smsAccounts')]({'id':_0x57d983[_0x3009a7('0x557')]['id'],'nolimit':!![]})['$promise'][_0x3009a7('0x1166')](function(_0x2666b6){const _0x58b5f6=_0x3009a7;return _0x57d983[_0x58b5f6('0x1d76')]=_0x2666b6||{'count':0x0,'rows':[]},_0x4f8f47['tag'][_0x58b5f6('0xd83')]()[_0x58b5f6('0xa44')];})[_0x3009a7('0x1166')](function(_0x4c9753){const _0x49dd90=_0x3009a7;_0x57d983[_0x49dd90('0xb38')]=_0x4c9753||{'count':0x0,'rows':[]};})[_0x3009a7('0x1166')](function(){const _0x32fff5=_0x3009a7;_0x57d983[_0x32fff5('0x6cb')]=_0x5d0b19();})['catch'](function(_0x39acc9){const _0x35baa5=_0x3009a7;console[_0x35baa5('0xfc9')](_0x39acc9);})['finally'](function(){const _0x146df9=_0x3009a7;let _0x3cce6b=_0x1ea317[_0x146df9('0x275')][_0x146df9('0x15f7')](_0x146df9('0x281')+_0x57d983['user']['id']);if(_0x3cce6b)try{_0x3cce6b=JSON[_0x146df9('0x1295')](_0x3cce6b);if(_0x3cce6b[_0x146df9('0x2218')]){_0x57d983[_0x146df9('0x2218')]=_0x2cfb05()[_0x146df9('0xcc3')](_0x57d983['query'],_0x3cce6b[_0x146df9('0x2218')]);if(_0x2cfb05()[_0x146df9('0x1081')](_0x57d983[_0x146df9('0x1d76')][_0x146df9('0x269a')]))_0x57d983['query']['SmsAccountId']=[];else _0x2cfb05()['isEmpty'](_0x57d983[_0x146df9('0x2218')][_0x146df9('0xa74')])&&(_0x57d983[_0x146df9('0x2218')]['SmsAccountId']=_0x2cfb05()(_0x57d983[_0x146df9('0x1d76')]['rows'])['map']('id')[_0x146df9('0x23a2')]()[_0x146df9('0x18e0')]());_0x57d983[_0x146df9('0x2218')]['sort']&&_0x57d983[_0x146df9('0x2218')][_0x146df9('0x1aba')][_0x146df9('0x2379')](_0x146df9('0x1522'))>=0x0&&(_0x57d983[_0x146df9('0x2218')]=_0x2cfb05()[_0x146df9('0x1414')](_0x57d983[_0x146df9('0x2218')],_0x146df9('0x1aba'))),_0x57d983[_0x146df9('0x2218')][_0x146df9('0x220e')]=!![],_0x57d983['isSearchBarVisible']=_0x57d983['query'][_0x146df9('0x1c33')]?!![]:![];}}catch(_0x500567){console[_0x146df9('0xfc9')](_0x500567);}else{const _0x4b73df={'$gte':_0x24273b()()[_0x146df9('0x1659')](_0x146df9('0x2e7'))['utcOffset'](0x0,!![])['format'](),'$lte':_0x24273b()()[_0x146df9('0x2589')](_0x146df9('0x2e7'))[_0x146df9('0x13f2')](0x0,!![])['format']()},_0x5b4236={'SmsAccountId':_0x2cfb05()[_0x146df9('0x2563')](_0x57d983[_0x146df9('0x1d76')][_0x146df9('0x269a')],'id'),'createdAt':_0x4b73df};_0x57d983[_0x146df9('0x2218')]=_0x2cfb05()[_0x146df9('0xcc3')](_0x57d983[_0x146df9('0x2218')],_0x5b4236);}_0x322901['on'](_0x146df9('0x25bf'),_0x34479e),_0x322901['on']('smsInteraction:update',_0x34479e),_0x322901['on'](_0x146df9('0x481'),_0x34c9c3),_0x322901['on'](_0x146df9('0xe7'),_0x179f59),_0x322901['on'](_0x146df9('0x15fc'),_0x179f59),_0x322901['on'](_0x146df9('0x216e'),_0x278354),_0x322901['on'](_0x146df9('0x190a'),_0x4c52fa),_0x452870(_0x57d983['query'][_0x146df9('0x1a43')]);});}function _0x5d0b19(){const _0x37dc6a=_0x50ec12;return[{'name':_0x37dc6a('0x2567'),'key':_0x37dc6a('0x262'),'type':_0x37dc6a('0x1643'),'label':_0x37dc6a('0x16d9')},{'name':_0x37dc6a('0x116c'),'key':'read','type':_0x37dc6a('0x88a'),'label':_0x37dc6a('0x379'),'customOptions':[{'value':0x0,'translate':_0x37dc6a('0x2c8')},{'value':0x1,'translate':'DASHBOARDS.READ'},{'value':null,'translate':_0x37dc6a('0x2150')}]},{'name':'Status','key':_0x37dc6a('0xa5b'),'type':_0x37dc6a('0x88a'),'label':_0x37dc6a('0xe32'),'customOptions':[{'value':0x0,'translate':_0x37dc6a('0xdeb')},{'value':0x1,'translate':_0x37dc6a('0x58f')},{'value':null,'translate':_0x37dc6a('0x2150')}]},{'name':_0x37dc6a('0x1758'),'key':_0x37dc6a('0xa74'),'type':_0x37dc6a('0x2162'),'label':_0x37dc6a('0x6da'),'options':_0x57d983[_0x37dc6a('0x1d76')]['rows'],'clearAll':![]},{'name':'Agent','key':_0x37dc6a('0x122a'),'type':_0x37dc6a('0x88a'),'label':_0x37dc6a('0x1db1'),'customOptions':[{'value':_0x57d983[_0x37dc6a('0x557')]['id'],'translate':_0x37dc6a('0x15ae')},{'value':_0x37dc6a('0x15d7'),'translate':_0x37dc6a('0x216b')},{'value':undefined,'translate':_0x37dc6a('0x2150')}]},{'name':_0x37dc6a('0x1b35'),'key':'tag','type':_0x37dc6a('0x2162'),'label':'DASHBOARDS.SELECT_TAG','options':_0x57d983[_0x37dc6a('0xb38')][_0x37dc6a('0x269a')],'placeholder':_0x37dc6a('0x2223')}];}function _0x55beeb(_0x43d481){const _0x21aaef=_0x50ec12;_0x57d983[_0x21aaef('0x293')]=![],_0x57d983[_0x21aaef('0xb0e')]=_0x43d481||{'count':0x0,'rows':[]};for(let _0x477db1=0x0;_0x477db1<_0x57d983[_0x21aaef('0xb0e')][_0x21aaef('0x269a')][_0x21aaef('0x264b')];_0x477db1+=0x1){_0x54a424(_0x57d983[_0x21aaef('0xb0e')][_0x21aaef('0x269a')][_0x477db1]);}}function _0x452870(_0x1c9e8f){const _0x21e616=_0x50ec12;_0x57d983[_0x21e616('0x293')]=!![];!_0x1c9e8f&&(_0x57d983[_0x21e616('0x2218')][_0x21e616('0x1a43')]=0x1);_0x57d983['query']['offset']=(_0x57d983[_0x21e616('0x2218')]['page']-0x1)*_0x57d983['query']['limit'];let _0x43218a=_0x1ea317[_0x21e616('0x275')]['getItem'](_0x21e616('0x281')+_0x57d983[_0x21e616('0x557')]['id']);_0x43218a=_0x43218a?JSON[_0x21e616('0x1295')](_0x43218a):{},_0x43218a[_0x21e616('0x2218')]=_0x57d983[_0x21e616('0x2218')],_0x1ea317[_0x21e616('0x275')]['setItem'](_0x21e616('0x281')+_0x57d983[_0x21e616('0x557')]['id'],JSON['stringify'](_0x43218a)),_0x57d983[_0x21e616('0x1f48')]=_0x4f8f47[_0x21e616('0x14c3')]['get'](_0x57d983[_0x21e616('0x2218')],_0x55beeb)[_0x21e616('0xa44')];}function _0xd03aa(_0x1f5ce1,_0x41b961){const _0x21ab8f=_0x50ec12;_0x48f4ad[_0x21ab8f('0x23ac')]['vm'][_0x21ab8f('0x126e')]('sms',_0x41b961);}function _0x5db3c2(_0x7fe5f6,_0x22d1aa,_0x47e8b4){const _0x3babae=_0x50ec12;_0x4f8f47['smsInteraction'][_0x3babae('0x2ad')]({'id':_0x22d1aa['id'],'attachments':_0x47e8b4})[_0x3babae('0xa44')][_0x3babae('0x1166')](function(_0x29c802){const _0x554c36=_0x3babae,_0x26e7a8=[_0x29c802[_0x554c36('0x20ed')]],_0x4edf91='sms-interaction'+_0x22d1aa['id']+'.zip',_0x3f9720=new Blob(_0x26e7a8,{'type':_0x29c802[_0x554c36('0x1345')]}),_0x1d52df=window[_0x554c36('0x136d')][_0x554c36('0xdd')]('a');_0x1d52df['setAttribute']('href',URL[_0x554c36('0x215a')](_0x3f9720)),_0x1d52df['setAttribute'](_0x554c36('0x2ad'),_0x4edf91),document[_0x554c36('0x8d2')][_0x554c36('0x21a')](_0x1d52df),_0x1d52df[_0x554c36('0x3b4')]();})[_0x3babae('0x1a80')](function(_0x2990e1){const _0x2ae798=_0x3babae;if(_0x2990e1['data']&&_0x2990e1[_0x2ae798('0x25f4')][_0x2ae798('0x61a')]&&_0x2990e1[_0x2ae798('0x25f4')]['errors']['length'])for(let _0x36929e=0x0;_0x36929e<_0x2990e1[_0x2ae798('0x25f4')]['errors'][_0x2ae798('0x264b')];_0x36929e+=0x1){_0x3d8d8d[_0x2ae798('0xfc9')]({'title':_0x2990e1['data'][_0x2ae798('0x61a')][_0x36929e][_0x2ae798('0x1345')],'msg':_0x2990e1[_0x2ae798('0x25f4')][_0x2ae798('0x61a')][_0x36929e]['message']});}else _0x3d8d8d[_0x2ae798('0xfc9')]({'title':_0x2990e1[_0x2ae798('0x52d')]?_0x2ae798('0x1e21')+_0x2990e1[_0x2ae798('0x52d')]+_0x2ae798('0x11e1')+_0x2990e1[_0x2ae798('0xe1b')]:'downloadSmsInteraction','msg':_0x2990e1[_0x2ae798('0x25f4')]?JSON['stringify'](_0x2990e1[_0x2ae798('0x25f4')][_0x2ae798('0x1e70')]):_0x2990e1['toString']()});});}function _0x2f7a2d(_0x19d1e8,_0x403a86){const _0x5df1df=_0x50ec12,_0x408acb=_0x57d983['user'][_0x5df1df('0x2540')]||_0x57d983[_0x5df1df('0x557')][_0x5df1df('0x1c5c')]||_0x57d983[_0x5df1df('0x557')][_0x5df1df('0xb4')]||_0x57d983[_0x5df1df('0x557')][_0x5df1df('0x287f')]||_0x57d983[_0x5df1df('0x557')][_0x5df1df('0x5aa')],_0x2868f4=!_0x403a86[_0x5df1df('0x1758')]['mandatoryDisposition'];_0x2d2136[_0x5df1df('0x1f80')]({'controller':_0x5df1df('0xa39'),'controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular[_0x5df1df('0x1194')](_0x215f2a[_0x5df1df('0x8d2')]),'clickOutsideToClose':_0x2868f4,'escapeToClose':_0x2868f4,'onRemoving':function(){const _0x249782=_0x5df1df;_0x57d983['user']&&_0x403a86[_0x249782('0x1758')][_0x249782('0x10d0')]&&!_0x408acb&&_0x4f8f47['user'][_0x249782('0x20eb')]({'id':_0x57d983[_0x249782('0x557')]['id']})[_0x249782('0xa44')][_0x249782('0x1a80')](function(_0x2802c8){console['error'](_0x2802c8);});},'locals':{'user':_0x57d983[_0x5df1df('0x557')],'channel':_0x5df1df('0x146c'),'interaction':_0x403a86}});}function _0x54a424(_0x52d506){const _0x14ac59=_0x50ec12;_0x52d506[_0x14ac59('0x21a4')]?(_0x52d506[_0x14ac59('0x15cf')]=(_0x52d506['Contact'][_0x14ac59('0x18cb')]||'')+'\x20'+(_0x52d506[_0x14ac59('0x21a4')][_0x14ac59('0xeb0')]||''),_0x52d506[_0x14ac59('0x1ce2')]=_0x52d506[_0x14ac59('0x21a4')][_0x14ac59('0x2459')]):_0x52d506[_0x14ac59('0x15cf')]=_0x31f1a5[_0x14ac59('0x25cc')]('DASHBOARDS.UNKNOWN');}function _0x15b23d(_0x2bda8f){const _0x5f595d=_0x50ec12;if(_0x2bda8f[_0x5f595d('0x122a')])return _0x2bda8f[_0x5f595d('0x122a')]===_0x57d983[_0x5f595d('0x557')]['id']?_0x31f1a5['instant'](_0x5f595d('0x15ae')):_0x2bda8f['Owner'][_0x5f595d('0x6e1')]+'\x20<'+_0x2bda8f['Owner']['internal']+'>';return _0x31f1a5[_0x5f595d('0x25cc')](_0x5f595d('0x216b'));}function _0x5aa765(_0x51fc8f){const _0x476d4f=_0x50ec12;if(_0x51fc8f[_0x476d4f('0x1758')])return _0x51fc8f[_0x476d4f('0x1758')][_0x476d4f('0x7ca')];return _0x31f1a5['instant'](_0x476d4f('0x148c'));}function _0x357cc6(_0x3266a3,_0xc19f4c){const _0x4fee2e=_0x50ec12;_0x2d2136[_0x4fee2e('0x1f80')]({'controller':_0x4fee2e('0xd15'),'controllerAs':'vm','templateUrl':_0x45ce09,'parent':angular[_0x4fee2e('0x1194')](_0x215f2a['body']),'clickOutsideToClose':![],'locals':{'account':_0xc19f4c,'message':{},'type':_0x4fee2e('0xd11'),'interaction':{}},'fullscreen':!![]})[_0x4fee2e('0x1166')](function(_0x31b9cf){const _0x115e1d=_0x4fee2e;if(_0x31b9cf){if(_0x31b9cf[_0x115e1d('0x1e70')]&&_0x31b9cf[_0x115e1d('0x1e70')][_0x115e1d('0x34f')]){const _0x3ae88f={'channel':_0x115e1d('0x146c'),'account':_0xc19f4c,'message':_0x31b9cf[_0x115e1d('0x1e70')],'contact':_0x31b9cf[_0x115e1d('0x26db')]};_0x45c323['add'](_0x3ae88f);}else{const _0x181a9e=_0x31b9cf;return _0x4f8f47[_0x115e1d('0x27e5')][_0x115e1d('0x20ba')]({'id':_0xc19f4c['id']},_0x181a9e)[_0x115e1d('0xa44')][_0x115e1d('0x1166')](function(_0x18fe37){const _0x217991=_0x115e1d;_0x3d8d8d['success']({'title':_0x217991('0x11ac'),'msg':_0x217991('0x1605')}),_0x48f4ad[_0x217991('0x23ac')]['vm'][_0x217991('0x126e')]('sms',_0x18fe37);})[_0x115e1d('0x1a80')](function(_0x551f81){const _0x76f5d1=_0x115e1d;if(_0x551f81[_0x76f5d1('0x25f4')]&&_0x551f81[_0x76f5d1('0x25f4')]['errors']&&_0x551f81[_0x76f5d1('0x25f4')][_0x76f5d1('0x61a')]['length'])for(let _0x43daa4=0x0;_0x43daa4<_0x551f81[_0x76f5d1('0x25f4')][_0x76f5d1('0x61a')][_0x76f5d1('0x264b')];_0x43daa4++){_0x3d8d8d[_0x76f5d1('0xfc9')]({'title':_0x551f81['data']['errors'][_0x43daa4][_0x76f5d1('0x1345')],'msg':_0x551f81['data'][_0x76f5d1('0x61a')][_0x43daa4][_0x76f5d1('0x1e70')]});}else _0x3d8d8d[_0x76f5d1('0xfc9')]({'title':_0x551f81['status']?_0x76f5d1('0x1e21')+_0x551f81[_0x76f5d1('0x52d')]+_0x76f5d1('0x11e1')+_0x551f81[_0x76f5d1('0xe1b')]:'SMSACCOUNT:SEND','msg':_0x551f81[_0x76f5d1('0x25f4')]?JSON[_0x76f5d1('0xbac')](_0x551f81[_0x76f5d1('0x25f4')]['message']):_0x551f81[_0x76f5d1('0x1e70')]||_0x551f81[_0x76f5d1('0x1586')]()});});}}});}function _0x278354(_0x54aa15){const _0x1dc2ff=_0x50ec12;let _0xefd259;const _0x9f689d=_0x2cfb05()['find'](_0x57d983[_0x1dc2ff('0xb0e')][_0x1dc2ff('0x269a')],{'id':_0x54aa15[_0x1dc2ff('0xbb8')]});_0x9f689d&&_0x9f689d[_0x1dc2ff('0x1bc7')]&&(_0xefd259=_0x2cfb05()[_0x1dc2ff('0xc38')](_0x9f689d[_0x1dc2ff('0x1bc7')],{'id':_0x54aa15[_0x1dc2ff('0x122a')]}),!_0xefd259&&_0x9f689d[_0x1dc2ff('0x1bc7')][_0x1dc2ff('0x1514')]({'id':_0x54aa15[_0x1dc2ff('0x122a')]}));}function _0x4c52fa(_0x53c302){const _0x1fe761=_0x50ec12,_0x1be576=_0x2cfb05()[_0x1fe761('0xc38')](_0x57d983[_0x1fe761('0xb0e')][_0x1fe761('0x269a')],{'id':_0x53c302[_0x1fe761('0xbb8')]});_0x1be576&&_0x1be576[_0x1fe761('0x1bc7')]&&_0x2cfb05()[_0x1fe761('0x127f')](_0x1be576[_0x1fe761('0x1bc7')],{'id':_0x53c302[_0x1fe761('0x122a')]});}function _0x34479e(_0x442cf9){const _0x4b6e98=_0x50ec12;if(_0x442cf9){const _0x574350=_0x2cfb05()[_0x4b6e98('0xc38')](_0x57d983[_0x4b6e98('0xb0e')]['rows'],{'id':_0x442cf9['id']});if(_0x574350){_0x574350[_0x4b6e98('0x1bc7')]=[];_0x442cf9[_0x4b6e98('0xa5b')]&&(_0x574350[_0x4b6e98('0x723')]=0x0);if(_0x57d983['query']['sort']){const _0x1cc04c=_0x2cfb05()[_0x4b6e98('0x1783')](_0x57d983[_0x4b6e98('0x2218')][_0x4b6e98('0x1aba')],'-')?_0x4b6e98('0x1dc3'):_0x4b6e98('0x17d');_0x57d983[_0x4b6e98('0xb0e')]['rows']=_0x2cfb05()['orderBy'](_0x57d983[_0x4b6e98('0xb0e')]['rows'],_0x2cfb05()['trimStart'](_0x57d983[_0x4b6e98('0x2218')]['sort'],'-'),_0x1cc04c);}_0x2cfb05()[_0x4b6e98('0xcc3')](_0x574350,_0x2cfb05()[_0x4b6e98('0x1a08')](_0x442cf9,_0x2cfb05()[_0x4b6e98('0x14a4')](_0x574350)));}else _0x452870(_0x57d983[_0x4b6e98('0x2218')][_0x4b6e98('0x1a43')]);}}function _0x34c9c3(_0x47be5a){const _0x52a333=_0x50ec12;if(_0x47be5a){const _0x2b011f=_0x2cfb05()['find'](_0x57d983['smsInteractions'][_0x52a333('0x269a')],{'id':_0x47be5a['id']});_0x2b011f&&(_0x2b011f[_0x52a333('0x21c2')]=_0x47be5a['tags']||[],_0x2cfb05()[_0x52a333('0xcc3')](_0x2b011f,_0x2cfb05()['pick'](_0x47be5a,_0x2cfb05()[_0x52a333('0x14a4')](_0x2b011f))));}}function _0x179f59(_0x3bb709){const _0x4723dd=_0x50ec12;if(_0x3bb709&&!_0x3bb709['secret']){const _0x37d363=_0x2cfb05()[_0x4723dd('0xc38')](_0x57d983[_0x4723dd('0xb0e')]['rows'],{'id':_0x3bb709[_0x4723dd('0xbb8')]});if(_0x37d363){const _0x168218=_0x2cfb05()[_0x4723dd('0xc38')](_0x37d363[_0x4723dd('0x116c')],{'id':_0x3bb709['id']});_0x168218?_0x2cfb05()['merge'](_0x168218,_0x2cfb05()[_0x4723dd('0x1a08')](_0x3bb709,_0x2cfb05()[_0x4723dd('0x14a4')](_0x168218))):(_0x2cfb05()[_0x4723dd('0x2863')](_0x37d363['Messages'])&&(_0x37d363[_0x4723dd('0x116c')]={'count':0x0}),!_0x3bb709[_0x4723dd('0x123')]&&(_0x37d363[_0x4723dd('0x116c')][_0x4723dd('0x240f')]+=0x1));}}}function _0x85f569(){_0x57d983['isSearchBarVisible']=![];}function _0x30f0e2(){const _0x1f891a=_0x50ec12;_0x57d983[_0x1f891a('0x7cc')]=!![];}function _0x450430(){const _0x1f729b=_0x50ec12;_0x57d983[_0x1f729b('0x7cc')]=![],_0x2d2136[_0x1f729b('0x1f80')]({'controller':_0x1f729b('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular['element'](_0x215f2a[_0x1f729b('0x8d2')]),'clickOutsideToClose':![],'locals':{'color':_0x57d983['sectionColor'],'fields':_0x57d983[_0x1f729b('0x1291')]['fields'],'storagePath':_0x1f729b('0x16eb')},'fullscreen':!![]})[_0x1f729b('0x1166')](function(_0x2d57ca){const _0x2e717c=_0x1f729b;_0x57d983[_0x2e717c('0x2218')][_0x2e717c('0xe07')]=_0x2d57ca===![]?undefined:_0x2d57ca;if(_0x57d983[_0x2e717c('0x2218')][_0x2e717c('0xe07')]||_0x2d57ca===![])_0x452870();})['catch'](function(_0x4eb1c7){const _0x209976=_0x1f729b;_0x3d8d8d[_0x209976('0xfc9')]({'title':_0x209976('0x2272'),'msg':_0x4eb1c7[_0x209976('0x25f4')]?JSON[_0x209976('0xbac')](_0x4eb1c7[_0x209976('0x25f4')]['message']):_0x4eb1c7[_0x209976('0x1586')]()});});}let _0xb648ad=!![],_0x189423=0x1;_0x48f4ad[_0x50ec12('0xe83')](_0x50ec12('0x12d8'),function(_0x23c208,_0x28ceb7){const _0xab4af7=_0x50ec12;_0xb648ad?_0xadca1b(function(){_0xb648ad=![];}):(!_0x28ceb7&&(_0x189423=_0x57d983[_0xab4af7('0x2218')][_0xab4af7('0x1a43')]),_0x23c208!==_0x28ceb7&&(_0x57d983[_0xab4af7('0x2218')]['page']=0x1),!_0x23c208&&(_0x57d983[_0xab4af7('0x2218')][_0xab4af7('0x1a43')]=_0x189423),_0x452870(_0x57d983[_0xab4af7('0x2218')][_0xab4af7('0x1a43')]));}),_0x48f4ad[_0x50ec12('0x3d2')]('$destroy',function(){const _0x156472=_0x50ec12;_0x322901['removeAllListeners'](_0x156472('0xe7')),_0x322901[_0x156472('0x1800')]('smsMessage:update'),_0x322901[_0x156472('0x1800')](_0x156472('0x25bf')),_0x322901[_0x156472('0x1800')]('smsInteractionTags:save'),_0x322901['removeAllListeners'](_0x156472('0xd0')),_0x322901[_0x156472('0x1800')](_0x156472('0x216e')),_0x322901['removeAllListeners']('user_has_sms_interactions:remove');});}const _0x38b10c=_0x4a22d1,_0x25c77b=_0x2734b2['p']+_0x36e6f4('0x2500');_0x295482[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'api','toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x1566'),_0x36e6f4('0x36f'),_0x36e6f4('0x8da')];function _0x295482(_0x232e2d,_0x246cf9,_0x5073ea,_0x532669,_0x19771a,_0x513413,_0x4dcfe2,_0x367f32){const _0x5861e6=_0x36e6f4,_0x5afeea=this;_0x5afeea[_0x5861e6('0x98')]=_0x19771a[_0x5861e6('0x26cd')](),_0x5afeea['voiceCalls']={},_0x5afeea[_0x5861e6('0x916')]=_0x5861e6('0x1e49'),_0x5afeea['query']={'UserId':_0x5afeea['currentUser']['id'],'fields':'id,type,uniqueid,tag,starttime,endtime,source,destination,userDisposition,userSecondDisposition,userThirdDisposition,note,duration,billableseconds,answertime','sort':'-updatedAt','limit':0xa,'page':0x1,'type':null},_0x5afeea[_0x5861e6('0x103b')]=_0x21bcce,_0x5afeea[_0x5861e6('0x149')]=_0xbcadbe,_0x5afeea[_0x5861e6('0xae0')]=_0x4e243a,_0x5afeea[_0x5861e6('0x2559')]=_0x538f01,_0x5afeea[_0x5861e6('0x109e')]=_0x418fcd,_0x5afeea['onSearchBarExpand']=_0xb2d99c;function _0x4e243a(){const _0x95cccf=_0x5861e6;return _0x5073ea[_0x95cccf('0x1446')][_0x95cccf('0xd83')]()[_0x95cccf('0xa44')]['then'](function(_0x5a0994){const _0x39572f=_0x95cccf;_0x5afeea[_0x39572f('0xb38')]=_0x5a0994||{'count':0x0,'rows':[]};})['then'](function(){const _0x8230e9=_0x95cccf;_0x5afeea[_0x8230e9('0x6cb')]=_0x183e89();})[_0x95cccf('0x1a80')](function(_0x531220){const _0x3a7f6b=_0x95cccf;_0x532669[_0x3a7f6b('0xfc9')]({'title':_0x3a7f6b('0xa6c'),'msg':_0x531220[_0x3a7f6b('0x25f4')]?JSON[_0x3a7f6b('0xbac')](_0x531220['data'][_0x3a7f6b('0x1e70')]):_0x531220[_0x3a7f6b('0x1e70')]||_0x531220[_0x3a7f6b('0x1586')]()}),_0x5afeea[_0x3a7f6b('0xb38')]={'count':0x0,'rows':[]};})[_0x95cccf('0x1951')](function(){const _0x3306a4=_0x95cccf;let _0x1c41af=_0x513413[_0x3306a4('0x275')][_0x3306a4('0x15f7')]('motion2.home.voice:'+_0x5afeea[_0x3306a4('0x98')]['id']);if(_0x1c41af)try{_0x1c41af=JSON[_0x3306a4('0x1295')](_0x1c41af),_0x1c41af['query']&&(_0x5afeea[_0x3306a4('0x2218')]=_0x2cfb05()[_0x3306a4('0x1414')](_0x1c41af[_0x3306a4('0x2218')],'filter'));}catch(_0x2b3be1){console[_0x3306a4('0xfc9')](_0x2b3be1);}else{const _0x43d390={'$gte':_0x24273b()()[_0x3306a4('0x1659')]('month')['utcOffset'](0x0,!![])['format'](),'$lte':_0x24273b()()[_0x3306a4('0x2589')](_0x3306a4('0x2e7'))['utcOffset'](0x0,!![])[_0x3306a4('0x128a')]()};_0x5afeea[_0x3306a4('0x2218')][_0x3306a4('0x262')]=_0x43d390;}_0xbcadbe();});}function _0x183e89(){const _0x3a0c8e=_0x5861e6;return[{'name':'Start\x20Date','key':_0x3a0c8e('0x262'),'type':_0x3a0c8e('0x1643'),'label':_0x3a0c8e('0x16d9')},{'name':'Type','key':_0x3a0c8e('0x1345'),'type':'select','label':'VOICE.SELECT_TYPE','customOptions':[{'value':_0x3a0c8e('0x1eef'),'translate':_0x3a0c8e('0xf7c')},{'value':_0x3a0c8e('0x14d8'),'translate':_0x3a0c8e('0x255d')},{'value':_0x3a0c8e('0x587'),'translate':_0x3a0c8e('0xad1')},{'value':_0x3a0c8e('0x21ee'),'translate':_0x3a0c8e('0x26aa')},{'value':null,'translate':'VOICE.ALL'}]}];}function _0x21bcce(_0x1467ed){const _0x6b5b2d=_0x5861e6;_0x5afeea[_0x6b5b2d('0x293')]=![],_0x5afeea[_0x6b5b2d('0x1e49')]=_0x1467ed||{'count':0x0,'rows':[]};}function _0xbcadbe(){const _0x588e27=_0x5861e6;_0x5afeea['searchInProgress']=!![],_0x5afeea[_0x588e27('0x2218')][_0x588e27('0x1098')]=(_0x5afeea[_0x588e27('0x2218')]['page']-0x1)*_0x5afeea[_0x588e27('0x2218')][_0x588e27('0x163f')];const _0x26c79c={'query':_0x5afeea['query']};_0x513413['localStorage'][_0x588e27('0xa26')](_0x588e27('0x1461')+_0x5afeea[_0x588e27('0x98')]['id'],JSON[_0x588e27('0xbac')](_0x26c79c)),_0x5afeea['promise']=_0x5073ea[_0x588e27('0x26e0')]['get'](_0x5afeea[_0x588e27('0x2218')],_0x21bcce)[_0x588e27('0xa44')];}function _0x538f01(_0x65ac4e){const _0x5e42bf=_0x5861e6;_0x232e2d['show']({'controller':_0x5e42bf('0x171c'),'controllerAs':'vm','templateUrl':_0x25c77b,'parent':angular[_0x5e42bf('0x1194')](_0x246cf9[_0x5e42bf('0x8d2')]),'clickOutsideToClose':!![],'locals':{'call':_0x65ac4e}});}function _0x418fcd(){const _0x544ebc=_0x5861e6;_0x5afeea['query'][_0x544ebc('0x1c33')]=undefined,_0x5afeea[_0x544ebc('0x7cc')]=![];}function _0xb2d99c(){const _0x198d4a=_0x5861e6;_0x5afeea[_0x198d4a('0x7cc')]=!![];}let _0x21a130=!![],_0x30a33f=0x1;_0x4dcfe2[_0x5861e6('0xe83')](_0x5861e6('0x12d8'),function(_0x5a53a5,_0x2bc49a){const _0x49735e=_0x5861e6;_0x21a130?_0x367f32(function(){_0x21a130=![];}):(!_0x2bc49a&&(_0x30a33f=_0x5afeea[_0x49735e('0x2218')]['page']),_0x5a53a5!==_0x2bc49a&&(_0x5afeea[_0x49735e('0x2218')][_0x49735e('0x1a43')]=0x1),!_0x5a53a5&&(_0x5afeea[_0x49735e('0x2218')][_0x49735e('0x1a43')]=_0x30a33f),_0x5afeea['getVoiceCalls']());});}const _0x3a958a=_0x295482;_0x398367['$inject']=['$mdDialog',_0x36e6f4('0x200f')];function _0x398367(_0x448c02,_0x4a9ce9){const _0x40da59=_0x36e6f4,_0x3d3644=this;_0x3d3644[_0x40da59('0x200f')]=_0x4a9ce9;function _0x5bfcd0(){const _0x55394b=_0x40da59;_0x448c02[_0x55394b('0x1197')]();}_0x3d3644[_0x40da59('0x24a0')]=_0x5bfcd0;}const _0x2f7c12=_0x398367;_0x15aec1['$inject']=[_0x36e6f4('0x36f'),'$timeout',_0x36e6f4('0x265d'),'$document','$window',_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'socket','toasty',_0x36e6f4('0x102a')];function _0x15aec1(_0x11b0ac,_0x36d6fb,_0x1ff4a1,_0x4bede1,_0x9e239a,_0x418d4d,_0x595526,_0x6d4625,_0x132c42,_0x242a09,_0x4660e8){const _0x518611=_0x36e6f4,_0x4e0d35=this;_0x4e0d35[_0x518611('0x557')]=_0x6d4625[_0x518611('0x26cd')](),_0x4e0d35['license']={},_0x4e0d35[_0x518611('0xf8a')]={},_0x4e0d35['tags']={'count':0x0,'rows':[]},_0x4e0d35[_0x518611('0x631')]={'count':0x0,'rows':[]},_0x4e0d35[_0x518611('0x2218')]={'includeAll':!![],'sort':'-updatedAt','limit':0xa,'page':0x1,'read':null,'closed':null},_0x4e0d35[_0x518611('0x1291')]={'fields':[{'name':'Id','column':'id','type':_0x518611('0xc45')},{'name':_0x518611('0x21a4'),'column':'Contact','type':_0x518611('0x1a01'),'options':{'searchFields':[_0x518611('0x18cb'),_0x518611('0xeb0'),'email'],'route':{'model':'cmContact','action':_0x518611('0xd83'),'params':{'fields':_0x518611('0x18eb'),'Contact':_0x518611('0x145b'),'nolimit':!![]}},'extraOperators':['$substring'],'excludedOperators':[_0x518611('0x2646')]}},{'name':_0x518611('0xe1'),'column':_0x518611('0x8d2'),'type':_0x518611('0x1640'),'options':{'excludedOperators':['$eq','$ne']}},{'name':_0x518611('0x28f6'),'column':_0x518611('0xa5b'),'type':_0x518611('0x88a'),'values':[{'id':0x0,'translate':_0x518611('0xdeb')},{'id':0x1,'translate':_0x518611('0x58f')}],'options':{'excludedOperators':[_0x518611('0x2646')]}},{'name':_0x518611('0x89b'),'column':'User','type':_0x518611('0x1a01'),'options':{'table':'i','route':{'model':_0x518611('0x557'),'action':_0x518611('0xd83'),'params':{'role':_0x518611('0x1eff'),'fields':_0x518611('0xce1'),'nolimit':!![]}},'searchFields':[_0x518611('0x6e1'),'name'],'extraOperators':['$substring'],'excludedOperators':[_0x518611('0x2646')]}},{'name':_0x518611('0x1758'),'column':_0x518611('0x1b88'),'type':_0x518611('0x2162'),'options':{'route':{'model':_0x518611('0x557'),'action':_0x518611('0x22a4'),'params':{'id':_0x4e0d35[_0x518611('0x557')]['id'],'nolimit':!![]}}}},{'name':_0x518611('0x21c2'),'column':_0x518611('0x1b35'),'type':'multiselect','options':{'route':{'model':_0x518611('0x1446'),'action':_0x518611('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':[_0x518611('0x18d')]}},{'name':_0x518611('0x2567'),'column':_0x518611('0x262'),'type':'date','options':{'excludedOperators':[_0x518611('0x2646')]}},{'name':'Read','column':_0x518611('0x723'),'type':_0x518611('0x88a'),'values':[{'id':0x1,'translate':_0x518611('0x1057')},{'id':0x0,'translate':_0x518611('0x2c8')}],'options':{'excludedOperators':[_0x518611('0x2646')]}}]},_0x4e0d35['sectionColor']=_0x518611('0xe6d'),_0x4e0d35[_0x518611('0xae0')]=_0x785ea5,_0x4e0d35[_0x518611('0x103b')]=_0x594190,_0x4e0d35[_0x518611('0x1f1e')]=_0x450ad7,_0x4e0d35['showWhatsappInteraction']=_0x390884,_0x4e0d35[_0x518611('0x8b2')]=_0x3003dc,_0x4e0d35[_0x518611('0xb52')]=_0x35993a,_0x4e0d35[_0x518611('0x250c')]=_0x46ee58,_0x4e0d35[_0x518611('0x2253')]=_0x42e8f8,_0x4e0d35[_0x518611('0x17cc')]=_0x17da18,_0x4e0d35['composeWhatsappInteraction']=_0x2b5ec9,_0x4e0d35[_0x518611('0x109e')]=_0x7c4b78,_0x4e0d35[_0x518611('0x3c5')]=_0x55a776,_0x4e0d35[_0x518611('0x138b')]=_0x5ad28c;function _0x785ea5(_0x243084,_0x237967){const _0x330f94=_0x518611;return _0x4e0d35[_0x330f94('0x5c9')]=_0x243084,_0x4e0d35[_0x330f94('0xf8a')]=_0x237967,_0x595526[_0x330f94('0x557')][_0x330f94('0xd83')+_0x2cfb05()[_0x330f94('0x114b')](_0x330f94('0x1974'))]({'id':_0x4e0d35[_0x330f94('0x557')]['id'],'nolimit':!![]})[_0x330f94('0xa44')]['then'](function(_0x21a517){const _0x94ba6a=_0x330f94;return _0x4e0d35[_0x94ba6a('0x1974')]=_0x21a517||{'count':0x0,'rows':[]},_0x595526[_0x94ba6a('0x1446')][_0x94ba6a('0xd83')]()[_0x94ba6a('0xa44')];})['then'](function(_0x370a20){const _0x21f07a=_0x330f94;_0x4e0d35[_0x21f07a('0xb38')]=_0x370a20||{'count':0x0,'rows':[]};})[_0x330f94('0x1166')](function(){const _0x5197e9=_0x330f94;_0x4e0d35[_0x5197e9('0x6cb')]=_0x5e4cd2();})['catch'](function(_0x403af6){console['error'](_0x403af6);})['finally'](function(){const _0x2db6f5=_0x330f94;let _0x469366=_0x9e239a['localStorage']['getItem'](_0x2db6f5('0x16c5')+_0x4e0d35[_0x2db6f5('0x557')]['id']);if(_0x469366)try{_0x469366=JSON[_0x2db6f5('0x1295')](_0x469366);if(_0x469366[_0x2db6f5('0x2218')]){_0x4e0d35[_0x2db6f5('0x2218')]=_0x2cfb05()[_0x2db6f5('0xcc3')](_0x4e0d35['query'],_0x469366[_0x2db6f5('0x2218')]);if(_0x2cfb05()['isEmpty'](_0x4e0d35['whatsappAccounts'][_0x2db6f5('0x269a')]))_0x4e0d35[_0x2db6f5('0x2218')][_0x2db6f5('0x1b88')]=[];else _0x2cfb05()[_0x2db6f5('0x1081')](_0x4e0d35[_0x2db6f5('0x2218')]['WhatsappAccountId'])&&(_0x4e0d35['query']['WhatsappAccountId']=_0x2cfb05()(_0x4e0d35[_0x2db6f5('0x1974')][_0x2db6f5('0x269a')])[_0x2db6f5('0x2563')]('id')['take']()[_0x2db6f5('0x18e0')]());_0x4e0d35['query'][_0x2db6f5('0x1aba')]&&_0x4e0d35[_0x2db6f5('0x2218')][_0x2db6f5('0x1aba')][_0x2db6f5('0x2379')](_0x2db6f5('0x1522'))>=0x0&&(_0x4e0d35['query']=_0x2cfb05()[_0x2db6f5('0x1414')](_0x4e0d35[_0x2db6f5('0x2218')],_0x2db6f5('0x1aba'))),_0x4e0d35[_0x2db6f5('0x2218')][_0x2db6f5('0x220e')]=!![],_0x4e0d35[_0x2db6f5('0x7cc')]=_0x4e0d35[_0x2db6f5('0x2218')][_0x2db6f5('0x1c33')]?!![]:![];}}catch(_0x502c2b){console['error'](_0x502c2b);}else{const _0x5b895f={'$gte':_0x24273b()()[_0x2db6f5('0x1659')](_0x2db6f5('0x2e7'))['utcOffset'](0x0,!![])[_0x2db6f5('0x128a')](),'$lte':_0x24273b()()['endOf'](_0x2db6f5('0x2e7'))[_0x2db6f5('0x13f2')](0x0,!![])[_0x2db6f5('0x128a')]()},_0x4ac31c={'WhatsappAccountId':_0x2cfb05()['map'](_0x4e0d35[_0x2db6f5('0x1974')][_0x2db6f5('0x269a')],'id'),'createdAt':_0x5b895f};_0x4e0d35['query']=_0x2cfb05()['merge'](_0x4e0d35['query'],_0x4ac31c);}_0x132c42['on'](_0x2db6f5('0x935'),_0x2cec67),_0x132c42['on'](_0x2db6f5('0xfb5'),_0x2cec67),_0x132c42['on'](_0x2db6f5('0xd36'),_0x5ba3f2),_0x132c42['on'](_0x2db6f5('0x180e'),_0x5249d5),_0x132c42['on'](_0x2db6f5('0x286b'),_0x5249d5),_0x132c42['on'](_0x2db6f5('0x116'),_0xe88adf),_0x132c42['on'](_0x2db6f5('0x2180'),_0x13a187),_0x450ad7(_0x4e0d35['query'][_0x2db6f5('0x1a43')]);});}function _0x5e4cd2(){const _0x13eaeb=_0x518611;return[{'name':'Start\x20Date','key':'createdAt','type':_0x13eaeb('0x1643'),'label':_0x13eaeb('0x16d9')},{'name':_0x13eaeb('0x116c'),'key':_0x13eaeb('0x123'),'type':_0x13eaeb('0x88a'),'label':_0x13eaeb('0x379'),'customOptions':[{'value':0x0,'translate':_0x13eaeb('0x2c8')},{'value':0x1,'translate':_0x13eaeb('0x1057')},{'value':null,'translate':_0x13eaeb('0x2150')}]},{'name':_0x13eaeb('0x28f6'),'key':_0x13eaeb('0xa5b'),'type':_0x13eaeb('0x88a'),'label':_0x13eaeb('0xe32'),'customOptions':[{'value':0x0,'translate':_0x13eaeb('0xdeb')},{'value':0x1,'translate':_0x13eaeb('0x58f')},{'value':null,'translate':_0x13eaeb('0x2150')}]},{'name':_0x13eaeb('0x1758'),'key':'WhatsappAccountId','type':'multiselect','label':_0x13eaeb('0x6da'),'options':_0x4e0d35[_0x13eaeb('0x1974')][_0x13eaeb('0x269a')],'clearAll':![]},{'name':'Agent','key':_0x13eaeb('0x122a'),'type':'select','label':'DASHBOARDS.SELECT_AGENT','customOptions':[{'value':_0x4e0d35['user']['id'],'translate':_0x13eaeb('0x15ae')},{'value':'null','translate':_0x13eaeb('0x216b')},{'value':undefined,'translate':_0x13eaeb('0x2150')}]},{'name':'Tag','key':'tag','type':'multiselect','label':_0x13eaeb('0x1669'),'options':_0x4e0d35[_0x13eaeb('0xb38')][_0x13eaeb('0x269a')],'placeholder':_0x13eaeb('0x2223')}];}function _0x594190(_0x3b6482){const _0x12ca67=_0x518611;_0x4e0d35[_0x12ca67('0x293')]=![],_0x4e0d35[_0x12ca67('0x631')]=_0x3b6482||{'count':0x0,'rows':[]};for(let _0x2892b3=0x0;_0x2892b3<_0x4e0d35[_0x12ca67('0x631')][_0x12ca67('0x269a')][_0x12ca67('0x264b')];_0x2892b3+=0x1){_0x46ee58(_0x4e0d35[_0x12ca67('0x631')]['rows'][_0x2892b3]);}}function _0x450ad7(_0xeb704e){const _0x316e6b=_0x518611;_0x4e0d35[_0x316e6b('0x293')]=!![];!_0xeb704e&&(_0x4e0d35['query'][_0x316e6b('0x1a43')]=0x1);_0x4e0d35[_0x316e6b('0x2218')][_0x316e6b('0x1098')]=(_0x4e0d35[_0x316e6b('0x2218')][_0x316e6b('0x1a43')]-0x1)*_0x4e0d35[_0x316e6b('0x2218')][_0x316e6b('0x163f')];let _0xb49771=_0x9e239a[_0x316e6b('0x275')][_0x316e6b('0x15f7')](_0x316e6b('0x16c5')+_0x4e0d35[_0x316e6b('0x557')]['id']);_0xb49771=_0xb49771?JSON[_0x316e6b('0x1295')](_0xb49771):{},_0xb49771[_0x316e6b('0x2218')]=_0x4e0d35[_0x316e6b('0x2218')],_0x9e239a[_0x316e6b('0x275')][_0x316e6b('0xa26')](_0x316e6b('0x16c5')+_0x4e0d35['user']['id'],JSON['stringify'](_0xb49771)),_0x4e0d35['promise']=_0x595526[_0x316e6b('0x2073')]['get'](_0x4e0d35[_0x316e6b('0x2218')],_0x594190)[_0x316e6b('0xa44')];}function _0x390884(_0x343074,_0x4d26b7){_0x11b0ac['$parent']['vm']['addInteractionTab']('whatsapp',_0x4d26b7);}function _0x3003dc(_0x1f8c05,_0x12cba6,_0x3320eb){const _0x1d008b=_0x518611;_0x595526[_0x1d008b('0x2073')][_0x1d008b('0x2ad')]({'id':_0x12cba6['id'],'attachments':_0x3320eb})['$promise'][_0x1d008b('0x1166')](function(_0x199dc7){const _0x3a8f8a=_0x1d008b,_0x3f17b3=[_0x199dc7['buffer']],_0x4929ba=_0x3a8f8a('0x44c')+_0x12cba6['id']+_0x3a8f8a('0x806'),_0x410103=new Blob(_0x3f17b3,{'type':_0x199dc7[_0x3a8f8a('0x1345')]}),_0x53e214=window[_0x3a8f8a('0x136d')][_0x3a8f8a('0xdd')]('a');_0x53e214[_0x3a8f8a('0xffd')](_0x3a8f8a('0x14f9'),URL[_0x3a8f8a('0x215a')](_0x410103)),_0x53e214[_0x3a8f8a('0xffd')](_0x3a8f8a('0x2ad'),_0x4929ba),document['body'][_0x3a8f8a('0x21a')](_0x53e214),_0x53e214[_0x3a8f8a('0x3b4')]();})[_0x1d008b('0x1a80')](function(_0xcbdee2){const _0x4a409d=_0x1d008b;if(_0xcbdee2[_0x4a409d('0x25f4')]&&_0xcbdee2[_0x4a409d('0x25f4')][_0x4a409d('0x61a')]&&_0xcbdee2[_0x4a409d('0x25f4')][_0x4a409d('0x61a')][_0x4a409d('0x264b')])for(let _0x231b25=0x0;_0x231b25<_0xcbdee2[_0x4a409d('0x25f4')][_0x4a409d('0x61a')][_0x4a409d('0x264b')];_0x231b25+=0x1){_0x242a09[_0x4a409d('0xfc9')]({'title':_0xcbdee2[_0x4a409d('0x25f4')]['errors'][_0x231b25][_0x4a409d('0x1345')],'msg':_0xcbdee2[_0x4a409d('0x25f4')]['errors'][_0x231b25][_0x4a409d('0x1e70')]});}else _0x242a09[_0x4a409d('0xfc9')]({'title':_0xcbdee2[_0x4a409d('0x52d')]?_0x4a409d('0x1e21')+_0xcbdee2[_0x4a409d('0x52d')]+_0x4a409d('0x11e1')+_0xcbdee2['statusText']:_0x4a409d('0x8b2'),'msg':_0xcbdee2['data']?JSON[_0x4a409d('0xbac')](_0xcbdee2['data']['message']):_0xcbdee2[_0x4a409d('0x1586')]()});});}function _0x35993a(_0x56217b,_0x195e64){const _0xb14e8d=_0x518611,_0x13de98=_0x4e0d35['user'][_0xb14e8d('0x2540')]||_0x4e0d35[_0xb14e8d('0x557')][_0xb14e8d('0x1c5c')]||_0x4e0d35[_0xb14e8d('0x557')][_0xb14e8d('0xb4')]||_0x4e0d35['user']['openchannelPause']||_0x4e0d35['user'][_0xb14e8d('0x5aa')],_0x3f3974=!_0x195e64[_0xb14e8d('0x1758')]['mandatoryDisposition'];_0x1ff4a1[_0xb14e8d('0x1f80')]({'controller':_0xb14e8d('0xa39'),'controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular[_0xb14e8d('0x1194')](_0x4bede1[_0xb14e8d('0x8d2')]),'clickOutsideToClose':_0x3f3974,'escapeToClose':_0x3f3974,'onRemoving':function(){const _0x2b79dd=_0xb14e8d;_0x4e0d35[_0x2b79dd('0x557')]&&_0x195e64['Account'][_0x2b79dd('0x10d0')]&&!_0x13de98&&_0x595526['user']['unpause']({'id':_0x4e0d35[_0x2b79dd('0x557')]['id']})[_0x2b79dd('0xa44')][_0x2b79dd('0x1a80')](function(_0x3843b5){console['error'](_0x3843b5);});},'locals':{'user':_0x4e0d35[_0xb14e8d('0x557')],'channel':_0xb14e8d('0x116e'),'interaction':_0x195e64}});}function _0x46ee58(_0x15732a){const _0x32906d=_0x518611;_0x15732a[_0x32906d('0x21a4')]?(_0x15732a[_0x32906d('0x15cf')]=(_0x15732a['Contact'][_0x32906d('0x18cb')]||'')+'\x20'+(_0x15732a[_0x32906d('0x21a4')][_0x32906d('0xeb0')]||''),_0x15732a[_0x32906d('0x1ce2')]=_0x15732a[_0x32906d('0x21a4')][_0x32906d('0x2459')]):_0x15732a['contactName']=_0x418d4d[_0x32906d('0x25cc')](_0x32906d('0x148c'));}function _0x42e8f8(_0x3d93bc){const _0x4550a8=_0x518611;if(_0x3d93bc[_0x4550a8('0x122a')])return _0x3d93bc['UserId']===_0x4e0d35['user']['id']?_0x418d4d[_0x4550a8('0x25cc')](_0x4550a8('0x15ae')):_0x3d93bc['Owner'][_0x4550a8('0x6e1')]+'\x20<'+_0x3d93bc[_0x4550a8('0x121b')][_0x4550a8('0x1eef')]+'>';return _0x418d4d[_0x4550a8('0x25cc')](_0x4550a8('0x216b'));}function _0x17da18(_0x741c70){const _0x5d80cf=_0x518611;if(_0x741c70[_0x5d80cf('0x1758')])return _0x741c70[_0x5d80cf('0x1758')]['key'];return _0x418d4d[_0x5d80cf('0x25cc')](_0x5d80cf('0x148c'));}function _0x2b5ec9(_0x39164d,_0x2b93e5){const _0x40cddc=_0x518611;_0x1ff4a1[_0x40cddc('0x1f80')]({'controller':_0x40cddc('0xa2e'),'controllerAs':'vm','templateUrl':_0x4b4a31,'parent':angular['element'](_0x4bede1['body']),'clickOutsideToClose':![],'locals':{'account':_0x2b93e5,'message':{},'type':_0x40cddc('0xd11'),'interaction':{}},'fullscreen':!![]})['then'](function(_0x1691e0){const _0x3a76ae=_0x40cddc;if(_0x1691e0){if(_0x1691e0[_0x3a76ae('0x1e70')]&&_0x1691e0[_0x3a76ae('0x1e70')]['savedAsDraft']){const _0x3da7a0={'channel':_0x3a76ae('0x116e'),'account':_0x2b93e5,'message':_0x1691e0[_0x3a76ae('0x1e70')],'contact':_0x1691e0['contact']};_0x4660e8[_0x3a76ae('0x126a')](_0x3da7a0);}else{const _0xe7ede6=_0x1691e0;return _0x595526['whatsappAccount'][_0x3a76ae('0x20ba')]({'id':_0x2b93e5['id']},_0xe7ede6)[_0x3a76ae('0xa44')][_0x3a76ae('0x1166')](function(_0x17ec57){const _0x2aeec1=_0x3a76ae;_0x242a09[_0x2aeec1('0x103b')]({'title':'Message\x20properly\x20sent!','msg':_0x2aeec1('0x1605')}),_0x11b0ac[_0x2aeec1('0x23ac')]['vm'][_0x2aeec1('0x126e')](_0x2aeec1('0x116e'),_0x17ec57);})[_0x3a76ae('0x1a80')](function(_0xd2c0ab){const _0x494b08=_0x3a76ae;if(_0xd2c0ab[_0x494b08('0x25f4')]&&_0xd2c0ab[_0x494b08('0x25f4')][_0x494b08('0x61a')]&&_0xd2c0ab['data'][_0x494b08('0x61a')]['length'])for(let _0x210713=0x0;_0x210713<_0xd2c0ab[_0x494b08('0x25f4')][_0x494b08('0x61a')][_0x494b08('0x264b')];_0x210713++){_0x242a09['error']({'title':_0xd2c0ab[_0x494b08('0x25f4')][_0x494b08('0x61a')][_0x210713][_0x494b08('0x1345')],'msg':_0xd2c0ab[_0x494b08('0x25f4')][_0x494b08('0x61a')][_0x210713]['message']});}else _0x242a09[_0x494b08('0xfc9')]({'title':_0xd2c0ab['status']?_0x494b08('0x1e21')+_0xd2c0ab['status']+_0x494b08('0x11e1')+_0xd2c0ab[_0x494b08('0xe1b')]:_0x494b08('0x1f9f'),'msg':_0xd2c0ab[_0x494b08('0x25f4')]?JSON[_0x494b08('0xbac')](_0xd2c0ab[_0x494b08('0x25f4')][_0x494b08('0x1e70')]):_0xd2c0ab[_0x494b08('0x1e70')]||_0xd2c0ab[_0x494b08('0x1586')]()});});}}});}function _0xe88adf(_0x225158){const _0x5600f3=_0x518611;let _0x88ed0a;const _0x5cb210=_0x2cfb05()[_0x5600f3('0xc38')](_0x4e0d35[_0x5600f3('0x631')][_0x5600f3('0x269a')],{'id':_0x225158[_0x5600f3('0xa1c')]});_0x5cb210&&_0x5cb210[_0x5600f3('0x1bc7')]&&(_0x88ed0a=_0x2cfb05()[_0x5600f3('0xc38')](_0x5cb210['Users'],{'id':_0x225158[_0x5600f3('0x122a')]}),!_0x88ed0a&&_0x5cb210[_0x5600f3('0x1bc7')][_0x5600f3('0x1514')]({'id':_0x225158[_0x5600f3('0x122a')]}));}function _0x13a187(_0x4471ae){const _0x24fa1d=_0x518611,_0x42e196=_0x2cfb05()[_0x24fa1d('0xc38')](_0x4e0d35[_0x24fa1d('0x631')]['rows'],{'id':_0x4471ae[_0x24fa1d('0xa1c')]});_0x42e196&&_0x42e196['Users']&&_0x2cfb05()[_0x24fa1d('0x127f')](_0x42e196[_0x24fa1d('0x1bc7')],{'id':_0x4471ae[_0x24fa1d('0x122a')]});}function _0x2cec67(_0x373b42){const _0x27715d=_0x518611;if(_0x373b42){const _0x198eed=_0x2cfb05()[_0x27715d('0xc38')](_0x4e0d35['whatsappInteractions'][_0x27715d('0x269a')],{'id':_0x373b42['id']});if(_0x198eed){_0x198eed[_0x27715d('0x1bc7')]=[];_0x373b42[_0x27715d('0xa5b')]&&(_0x198eed['unreadMessages']=0x0);if(_0x4e0d35[_0x27715d('0x2218')][_0x27715d('0x1aba')]){const _0x12b2a4=_0x2cfb05()[_0x27715d('0x1783')](_0x4e0d35[_0x27715d('0x2218')][_0x27715d('0x1aba')],'-')?_0x27715d('0x1dc3'):_0x27715d('0x17d');_0x4e0d35[_0x27715d('0x631')]['rows']=_0x2cfb05()[_0x27715d('0xe63')](_0x4e0d35[_0x27715d('0x631')][_0x27715d('0x269a')],_0x2cfb05()['trimStart'](_0x4e0d35[_0x27715d('0x2218')][_0x27715d('0x1aba')],'-'),_0x12b2a4);}_0x2cfb05()[_0x27715d('0xcc3')](_0x198eed,_0x2cfb05()[_0x27715d('0x1a08')](_0x373b42,_0x2cfb05()[_0x27715d('0x14a4')](_0x198eed)));}else _0x450ad7(_0x4e0d35[_0x27715d('0x2218')][_0x27715d('0x1a43')]);}}function _0x5ba3f2(_0x192f6f){const _0x3e7d6b=_0x518611;if(_0x192f6f){const _0x5320b1=_0x2cfb05()['find'](_0x4e0d35[_0x3e7d6b('0x631')][_0x3e7d6b('0x269a')],{'id':_0x192f6f['id']});_0x5320b1&&(_0x5320b1[_0x3e7d6b('0x21c2')]=_0x192f6f[_0x3e7d6b('0xb38')]||[],_0x2cfb05()['merge'](_0x5320b1,_0x2cfb05()[_0x3e7d6b('0x1a08')](_0x192f6f,_0x2cfb05()[_0x3e7d6b('0x14a4')](_0x5320b1))));}}function _0x5249d5(_0x513ee3){const _0x216f11=_0x518611;if(_0x513ee3&&!_0x513ee3[_0x216f11('0x1908')]){const _0x2a193d=_0x2cfb05()['find'](_0x4e0d35[_0x216f11('0x631')][_0x216f11('0x269a')],{'id':_0x513ee3['WhatsappInteractionId']});if(_0x2a193d){const _0x4ff18b=_0x2cfb05()[_0x216f11('0xc38')](_0x2a193d['Messages'],{'id':_0x513ee3['id']});_0x4ff18b?_0x2cfb05()[_0x216f11('0xcc3')](_0x4ff18b,_0x2cfb05()[_0x216f11('0x1a08')](_0x513ee3,_0x2cfb05()[_0x216f11('0x14a4')](_0x4ff18b))):(_0x2cfb05()[_0x216f11('0x2863')](_0x2a193d[_0x216f11('0x116c')])&&(_0x2a193d[_0x216f11('0x116c')]={'count':0x0}),!_0x513ee3['read']&&(_0x2a193d['Messages'][_0x216f11('0x240f')]+=0x1));}}}function _0x7c4b78(){const _0xed8c2a=_0x518611;_0x4e0d35[_0xed8c2a('0x7cc')]=![];}function _0x55a776(){const _0x45e3e8=_0x518611;_0x4e0d35[_0x45e3e8('0x7cc')]=!![];}function _0x5ad28c(){const _0x553879=_0x518611;_0x4e0d35[_0x553879('0x7cc')]=![],_0x1ff4a1[_0x553879('0x1f80')]({'controller':_0x553879('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular['element'](_0x4bede1[_0x553879('0x8d2')]),'clickOutsideToClose':![],'locals':{'color':_0x4e0d35['sectionColor'],'fields':_0x4e0d35[_0x553879('0x1291')][_0x553879('0xfe2')],'storagePath':'home.whatsapp'},'fullscreen':!![]})['then'](function(_0x3fa659){const _0x3fdf96=_0x553879;_0x4e0d35[_0x3fdf96('0x2218')][_0x3fdf96('0xe07')]=_0x3fa659===![]?undefined:_0x3fa659;if(_0x4e0d35[_0x3fdf96('0x2218')][_0x3fdf96('0xe07')]||_0x3fa659===![])_0x450ad7();})[_0x553879('0x1a80')](function(_0x3e74e6){const _0x303be9=_0x553879;_0x242a09[_0x303be9('0xfc9')]({'title':'ERROR','msg':_0x3e74e6['data']?JSON[_0x303be9('0xbac')](_0x3e74e6[_0x303be9('0x25f4')]['message']):_0x3e74e6[_0x303be9('0x1586')]()});});}let _0x494fcb=!![],_0x1ea32a=0x1;_0x11b0ac[_0x518611('0xe83')](_0x518611('0x12d8'),function(_0x27cf24,_0x26b82b){const _0x2c457f=_0x518611;_0x494fcb?_0x36d6fb(function(){_0x494fcb=![];}):(!_0x26b82b&&(_0x1ea32a=_0x4e0d35['query'][_0x2c457f('0x1a43')]),_0x27cf24!==_0x26b82b&&(_0x4e0d35[_0x2c457f('0x2218')][_0x2c457f('0x1a43')]=0x1),!_0x27cf24&&(_0x4e0d35[_0x2c457f('0x2218')][_0x2c457f('0x1a43')]=_0x1ea32a),_0x450ad7(_0x4e0d35[_0x2c457f('0x2218')]['page']));}),_0x11b0ac[_0x518611('0x3d2')]('$destroy',function(){const _0x216cf2=_0x518611;_0x132c42['removeAllListeners'](_0x216cf2('0x180e')),_0x132c42[_0x216cf2('0x1800')](_0x216cf2('0x286b')),_0x132c42[_0x216cf2('0x1800')](_0x216cf2('0x935')),_0x132c42[_0x216cf2('0x1800')]('whatsappInteractionTags:save'),_0x132c42[_0x216cf2('0x1800')](_0x216cf2('0xfb5')),_0x132c42[_0x216cf2('0x1800')]('user_has_whatsapp_interactions:save'),_0x132c42[_0x216cf2('0x1800')](_0x216cf2('0x2180'));});}const _0x1861c9=_0x15aec1;_0x15ed6e[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x5e3')];function _0x15ed6e(_0x39eefa,_0x57377e){const _0x15dbd5=_0x36e6f4,_0xdf1fdc=this;_0xdf1fdc['setting']={},_0xdf1fdc[_0x15dbd5('0xcfa')]={'count':0x0,'rows':[]},_0xdf1fdc[_0x15dbd5('0x1f3')]=![];function _0x4a4517(_0x19c8d7,_0x235298){const _0x4fdf3f=_0x15dbd5;_0xdf1fdc[_0x4fdf3f('0xf8a')]=_0x235298,_0xdf1fdc['tab']=_0x19c8d7,_0xdf1fdc[_0x4fdf3f('0xbe3')]['saved']=!![];}function _0x4de407(){const _0x48fe6a=_0x15dbd5;return _0x57377e[_0x48fe6a('0xd8c')](_0xdf1fdc[_0x48fe6a('0xbe3')][_0x48fe6a('0x2244')]);}_0xdf1fdc[_0x15dbd5('0x24d5')]=_0x4a4517,_0xdf1fdc['getTrustedURL']=_0x4de407;}const _0x146ac5=_0x15ed6e,_0x45fe34=_0x2734b2['p']+_0x36e6f4('0x4be'),_0x19613f=_0x2734b2['p']+_0x36e6f4('0x8e7');_0x40b913[_0x36e6f4('0x1294')]=[_0x36e6f4('0x5e3')],_0x41517a['$inject']=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x8da'),_0x36e6f4('0x1c90'),_0x36e6f4('0x36f'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x25e0'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x2661'),_0x36e6f4('0x1f36'),_0x36e6f4('0x102a')];function _0x41517a(_0x421395,_0x39c17e,_0x129e92,_0x401c2e,_0x183f97,_0x45b187,_0x3191a,_0x3735d7,_0x4af9b0,_0x377926,_0x2eeb6f,_0xfba886,_0x27dc3e,_0x216e25){const _0x250716=_0x36e6f4,_0x1cf994=this,_0x389ee9=0x19,_0x43bc9a=_0x389ee9*0x400*0x400;_0x1cf994['showFooter']=![],_0x1cf994[_0x250716('0x1f3')]=![],_0x1cf994[_0x250716('0x557')]=_0x2eeb6f[_0x250716('0x26cd')](),_0x1cf994[_0x250716('0x2694')]=_0x27dc3e['detectBrowser'](),_0x1cf994['journey']=[],_0x1cf994[_0x250716('0x1517')]=[],_0x1cf994['omniChannels']=[_0x250716('0x1bfa'),_0x250716('0xde2'),'sms',_0x250716('0x26c'),_0x250716('0x1fc7'),_0x250716('0x116e')],_0x1cf994[_0x250716('0xd67')]={'target':_0x250716('0x27fe'),'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x43bc9a,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x1cf994[_0x250716('0xe57')]={'flow':{}},_0x1cf994['selectedMailShowDetails']={},_0x1cf994[_0x250716('0x1b2f')]={},_0x1cf994[_0x250716('0xf8a')]={},_0x1cf994[_0x250716('0x1b47')]={},_0x1cf994[_0x250716('0x949')]={'fontSmiley':!![],'sanitizeHtml':!![],'emoji':!![],'link':!![],'linkTarget':_0x250716('0x180c')},_0x1cf994[_0x250716('0x2387')]=new Date(_0x24273b()()[_0x250716('0x1659')]('month')[_0x250716('0x6ab')](0x1,_0x250716('0x1aa6'))[_0x250716('0x13f2')](0x0,!![])[_0x250716('0x128a')]()),_0x1cf994['lastDayMonth']=new Date(_0x24273b()()[_0x250716('0x2589')](_0x250716('0x2e7'))['subtract'](0x1,'day')[_0x250716('0x13f2')](0x0,!![])[_0x250716('0x128a')]()),_0x1cf994[_0x250716('0x24d5')]=_0x46e4db,_0x1cf994[_0x250716('0xfed')]=_0x4bd92c,_0x1cf994[_0x250716('0x65e')]=_0x425e87,_0x1cf994['openInteraction']=_0x4ea81b,_0x1cf994['disposeInteraction']=_0x3c79c4,_0x1cf994[_0x250716('0x1c24')]=_0x166b68,_0x1cf994[_0x250716('0xd62')]=_0x79eab7,_0x1cf994[_0x250716('0xb78')]=_0x255e08,_0x1cf994[_0x250716('0x1a77')]=_0x4de84f,_0x1cf994['composeWhatsappInteraction']=_0x47e3f7,_0x1cf994[_0x250716('0x2665')]=_0x30e5d9,_0x1cf994[_0x250716('0x35e')]=_0x4b3d5d,_0x1cf994[_0x250716('0xaee')]=_0x3d1142,_0x1cf994['openDraft']=_0x178667,_0x1cf994[_0x250716('0xcee')]=_0x143373,_0x1cf994[_0x250716('0xf73')]=_0x6abae8,_0x1cf994[_0x250716('0x1f63')]=_0x1f72e3,_0x1cf994[_0x250716('0x1f5d')]=_0x19cfe7,_0x1cf994[_0x250716('0x22a4')]=_0x9d489e,_0x1cf994[_0x250716('0xc48')]=_0x1caa1a,_0x1cf994[_0x250716('0x36d')]=_0x52aa80,_0x1cf994[_0x250716('0x5a1')]=_0x1e9b49,_0x1cf994[_0x250716('0x1fdc')]=_0x198d5a,_0x1cf994[_0x250716('0x1d40')]=_0x267f60,_0x1cf994[_0x250716('0xd20')]=_0x17702b,_0x1cf994['fileSuccess']=_0x4cb3d9,_0x1cf994[_0x250716('0xaae')]=_0x4e88d3,_0x1cf994[_0x250716('0x1bc5')]=_0x53d514,_0x1cf994[_0x250716('0x6dc')]=_0x465cdd,_0x1cf994[_0x250716('0x138d')]=_0x18e283,_0x1cf994[_0x250716('0x25ec')]=_0xff9c6e,_0x1cf994['getColorByChannel']=_0x1cd247,_0x1cf994[_0x250716('0x3cb')]=_0x643d30,_0x1cf994[_0x250716('0x1ef')]=_0x2758cb,_0x1cf994[_0x250716('0xa71')]=![],_0x1cf994[_0x250716('0x23c1')]=_0x4ef9b9,_0x1cf994[_0x250716('0x21ac')]=_0x7877eb,_0x1cf994[_0x250716('0x1cc1')]=_0x29cf8b,_0x1cf994['isMyAccount']=_0x107380,_0x1cf994['getAttachments']=_0x2ae86d,_0x1cf994[_0x250716('0x27fa')]=_0x3040a8,_0x1cf994['htmlToPlaintext']=_0x272e43,_0x1cf994[_0x250716('0xac1')]=_0x2dc28e,_0x1cf994[_0x250716('0x1cda')]=_0x5338f1,_0x1cf994[_0x250716('0x236e')]=_0x5f54f1,_0x1cf994['timelineOptions']={'scrollEl':_0x250716('0x2166')};function _0x52aa80(){const _0x417fd2=_0x250716;_0x4af9b0[_0x417fd2('0x557')]['getChatWebsites']({'id':_0x1cf994[_0x417fd2('0x557')]['id'],'nolimit':!![]})['$promise'][_0x417fd2('0x1166')](function(_0x1567b8){const _0x2beb4a=_0x417fd2;_0x1cf994[_0x2beb4a('0x20e0')]=_0x1567b8||{'count':0x0,'rows':[]};});}function _0x1e9b49(){const _0x40f2bc=_0x250716;_0x4af9b0[_0x40f2bc('0x557')][_0x40f2bc('0x5a1')]({'id':_0x1cf994[_0x40f2bc('0x557')]['id'],'nolimit':!![]})['$promise'][_0x40f2bc('0x1166')](function(_0x290e9a){const _0x169cae=_0x40f2bc;_0x1cf994[_0x169cae('0x2039')]=_0x290e9a||{'count':0x0,'rows':[]};});}function _0x1caa1a(){const _0x41a337=_0x250716;_0x4af9b0[_0x41a337('0x557')][_0x41a337('0xc48')]({'id':_0x1cf994['user']['id'],'nolimit':!![]})[_0x41a337('0xa44')][_0x41a337('0x1166')](function(_0x29b7b7){const _0x53f420=_0x41a337;_0x1cf994[_0x53f420('0x28ff')]=_0x29b7b7||{'count':0x0,'rows':[]};})[_0x41a337('0x1a80')](function(_0x200246){const _0x219c24=_0x41a337;if(_0x200246[_0x219c24('0x25f4')]&&_0x200246['data']['errors']&&_0x200246['data']['errors'][_0x219c24('0x264b')]){_0x1cf994[_0x219c24('0x61a')]=_0x200246['data'][_0x219c24('0x61a')]||[{'message':_0x200246[_0x219c24('0x1586')](),'type':_0x219c24('0x200e')}];for(let _0x5010c0=0x0;_0x5010c0<_0x200246['data'][_0x219c24('0x61a')][_0x219c24('0x264b')];_0x5010c0+=0x1){_0x377926[_0x219c24('0xfc9')]({'title':_0x200246[_0x219c24('0x25f4')][_0x219c24('0x61a')][_0x5010c0][_0x219c24('0x1345')],'msg':_0x200246[_0x219c24('0x25f4')][_0x219c24('0x61a')][_0x5010c0][_0x219c24('0x1e70')]});}}else _0x377926['error']({'title':_0x200246['status']?_0x219c24('0x1e21')+_0x200246[_0x219c24('0x52d')]+_0x219c24('0x11e1')+_0x200246[_0x219c24('0xe1b')]:'api.mail.account','msg':_0x200246[_0x219c24('0x25f4')]?JSON[_0x219c24('0xbac')](_0x200246[_0x219c24('0x25f4')][_0x219c24('0x1e70')]):_0x200246['toString']()});});}function _0x6abae8(){const _0x536988=_0x250716;_0x4af9b0[_0x536988('0x557')][_0x536988('0xf73')]({'id':_0x1cf994[_0x536988('0x557')]['id'],'nolimit':!![]})['$promise'][_0x536988('0x1166')](function(_0x4e330c){const _0xbff16d=_0x536988;_0x1cf994[_0xbff16d('0xf85')]=_0x4e330c||{'count':0x0,'rows':[]};});}function _0x1f72e3(){const _0x58be67=_0x250716;_0x4af9b0[_0x58be67('0x557')]['getFaxAccounts']({'id':_0x1cf994[_0x58be67('0x557')]['id'],'nolimit':!![]})[_0x58be67('0xa44')]['then'](function(_0x2e91a1){_0x1cf994['faxAccounts']=_0x2e91a1||{'count':0x0,'rows':[]};});}function _0x19cfe7(){const _0x4982b8=_0x250716;_0x4af9b0['user']['getSmsAccounts']({'id':_0x1cf994[_0x4982b8('0x557')]['id'],'nolimit':!![]})['$promise'][_0x4982b8('0x1166')](function(_0x6cc365){const _0x2a5240=_0x4982b8;_0x1cf994[_0x2a5240('0x1d76')]=_0x6cc365||{'count':0x0,'rows':[]};});}function _0x9d489e(){const _0x27f8e0=_0x250716;_0x4af9b0[_0x27f8e0('0x557')][_0x27f8e0('0x22a4')]({'id':_0x1cf994[_0x27f8e0('0x557')]['id'],'nolimit':!![]})['$promise'][_0x27f8e0('0x1166')](function(_0x9e6fe9){const _0x439f09=_0x27f8e0;_0x1cf994[_0x439f09('0x1974')]=_0x9e6fe9||{'count':0x0,'rows':[]};});}function _0x5f54f1(){const _0x5486e5=_0x250716,_0x24e46a=_0x45b187[_0x5486e5('0x24d8')]();if(_0x1cf994[_0x5486e5('0x15c1')])return _0x1cf994[_0x5486e5('0x15c1')][_0x5486e5('0x1098')]=_0x1cf994[_0x5486e5('0xcfa')][_0x5486e5('0x269a')][_0x5486e5('0x264b')],_0x4af9b0[_0x1cf994[_0x5486e5('0xbe3')]['channel']+_0x5486e5('0x7ee')]['getMessages'](_0x1cf994[_0x5486e5('0x15c1')])[_0x5486e5('0xa44')]['then'](function(_0x352d82){const _0x343b10=_0x5486e5;for(let _0x3015e3=0x0;_0x3015e3<_0x352d82[_0x343b10('0x269a')][_0x343b10('0x264b')];_0x3015e3+=0x1){_0x1cf994[_0x343b10('0xcfa')][_0x343b10('0x269a')][_0x343b10('0x1514')](_0x352d82[_0x343b10('0x269a')][_0x3015e3]),!_0x1cf994[_0x343b10('0x25e6')][_0x343b10('0xa5b')]&&_0x352d82[_0x343b10('0x269a')][_0x3015e3][_0x343b10('0x2788')]==='in'&&!_0x352d82[_0x343b10('0x269a')][_0x3015e3][_0x343b10('0x123')]&&(_0x4af9b0[_0x1cf994['tab']['channel']+_0x343b10('0x1720')][_0x343b10('0x2384')]({'id':_0x352d82['rows'][_0x3015e3]['id'],'UserId':_0x1cf994[_0x343b10('0x557')]['id']}),_0x1cf994['acceptedMessages'][_0x343b10('0x1514')](_0x352d82['rows'][_0x3015e3]['id']));}return _0x24e46a[_0x343b10('0x18af')](_0x352d82);})[_0x5486e5('0x1a80')](function(_0x2d88c0){const _0x351c2e=_0x5486e5;return _0x24e46a[_0x351c2e('0x21bf')](_0x2d88c0);});return _0x24e46a[_0x5486e5('0x21bf')]();}function _0x46e4db(_0x299738,_0x53cb9b){const _0x5d3ad9=_0x250716;_0x1cf994[_0x5d3ad9('0xbe3')]=_0x299738,_0x1cf994[_0x5d3ad9('0xbe3')][_0x5d3ad9('0x26ae')]=!![],_0x1cf994[_0x5d3ad9('0xbe3')][_0x5d3ad9('0x1d12')]=0x0,_0x1cf994[_0x5d3ad9('0xf8a')]=_0x53cb9b||{},_0x1cf994['tab']&&_0x1cf994['tab'][_0x5d3ad9('0x1298')]&&_0x1cf994['tab']['interaction']&&(_0x1cf994['interaction']=_0x1cf994['tab'][_0x5d3ad9('0x25e6')],_0x4af9b0[_0x1cf994[_0x5d3ad9('0xbe3')][_0x5d3ad9('0x1298')]+_0x5d3ad9('0x7ee')][_0x5d3ad9('0xd83')]({'id':_0x1cf994['tab'][_0x5d3ad9('0x25e6')]['id'],'includeAll':!![]})['$promise']['then'](function(_0x37931a){const _0x3fa903=_0x5d3ad9;return _0x37931a&&(_0x1cf994['interaction']=_0x37931a,_0x1cf994[_0x3fa903('0xbe3')]['interaction']=_0x37931a),_0x1cf994[_0x3fa903('0xbe3')][_0x3fa903('0x26ae')]=_0x1cf994[_0x3fa903('0x25e6')][_0x3fa903('0xa5b')],_0x1cf994[_0x3fa903('0x15c1')]={'id':_0x1cf994['interaction']['id'],'includeAll':!![]},_0x1cf994[_0x3fa903('0xbe3')][_0x3fa903('0x1298')]===_0x3fa903('0x1bfa')?(_0x1cf994[_0x3fa903('0x15c1')][_0x3fa903('0x1aba')]=_0x3fa903('0x83'),_0x1cf994[_0x3fa903('0x15c1')][_0x3fa903('0x1098')]=0x0,_0x1cf994[_0x3fa903('0x15c1')][_0x3fa903('0x163f')]=0x3):(_0x1cf994[_0x3fa903('0x15c1')]['sort']='id',_0x1cf994[_0x3fa903('0x15c1')][_0x3fa903('0x49d')]=!![]),_0x4af9b0[_0x1cf994['tab'][_0x3fa903('0x1298')]+_0x3fa903('0x7ee')][_0x3fa903('0x16f2')](_0x1cf994[_0x3fa903('0x15c1')])[_0x3fa903('0xa44')];})[_0x5d3ad9('0x1166')](function(_0x2d0297){const _0x1e3b9c=_0x5d3ad9;return _0x1cf994[_0x1e3b9c('0xcfa')]=_0x2d0297||{'count':0x0,'rows':[]},_0x4af9b0[_0x1cf994[_0x1e3b9c('0xbe3')][_0x1e3b9c('0x1298')]==='chat'?_0x1e3b9c('0x1864'):_0x1cf994['tab'][_0x1e3b9c('0x1298')]+_0x1e3b9c('0x1758')]['get']({'id':_0x1cf994[_0x1e3b9c('0x25e6')][_0x1cf994[_0x1e3b9c('0xbe3')]['channel']===_0x1e3b9c('0xde2')?_0x1e3b9c('0x1e02'):_0x2cfb05()[_0x1e3b9c('0x92c')](_0x1cf994['tab']['channel'])+'AccountId']})['$promise'];})['then'](function(_0x34f821){const _0xa134c8=_0x5d3ad9;_0x1cf994['account']=_0x34f821,_0x1cf994[_0xa134c8('0xbe3')]['title']=_0x1cf994[_0xa134c8('0x1a32')][_0xa134c8('0x7ca')]||_0x1cf994[_0xa134c8('0x1a32')][_0xa134c8('0x4f0')];if(_0x1cf994[_0xa134c8('0x25e6')]['ContactId'])return _0x4af9b0[_0xa134c8('0x149e')][_0xa134c8('0xd83')]({'id':_0x1cf994[_0xa134c8('0x25e6')]['ContactId']})[_0xa134c8('0xa44')];})['then'](function(_0x1bc13c){const _0x459648=_0x5d3ad9;return _0x1bc13c&&(_0x1cf994[_0x459648('0x26db')]=_0x1bc13c),_0x1cf994[_0x459648('0x1f3')]=!![],_0x1cf994['contact']?(_0x241c4d(_0x1cf994[_0x459648('0x26db')]),_0x1cf994[_0x459648('0xbe3')][_0x459648('0xcdc')]+=_0x459648('0x11e1')+_0x1cf994[_0x459648('0x26db')]['firstName']):_0x1cf994['tab'][_0x459648('0xcdc')]+=_0x459648('0x11e1')+_0x3735d7[_0x459648('0x25cc')](_0x1cf994['tab']['channel'][_0x459648('0x1387')]()+'.UNKNOWN'),_0x4af9b0[_0x459648('0x557')][_0x459648('0xd83')]({'fields':_0x459648('0x1217'),'nolimit':!![]})[_0x459648('0xa44')];})[_0x5d3ad9('0x1166')](function(_0xab4cbc){const _0xd45454=_0x5d3ad9;_0x1cf994['users']=_0xab4cbc||{'count':0x0,'rows':[]},_0x1cf994[_0xd45454('0x7b5')]=_0x2cfb05()[_0xd45454('0x1f4d')](_0x2cfb05()[_0xd45454('0x155c')](_0x1cf994[_0xd45454('0x21f6')][_0xd45454('0x269a')],'id'),_0xd45454('0x6e1'));})[_0x5d3ad9('0x1166')](function(){const _0x3e2628=_0x5d3ad9;if(_0x1cf994[_0x3e2628('0xbe3')][_0x3e2628('0x1298')]&&_0x1cf994[_0x3e2628('0x25e6')])return _0x4af9b0[_0x3e2628('0x557')][_0x3e2628('0x126a')+_0x2cfb05()['upperFirst'](_0x1cf994['tab'][_0x3e2628('0x1298')])+_0x3e2628('0x7b3')]({'id':_0x1cf994[_0x3e2628('0x557')]['id'],'ids':[_0x1cf994[_0x3e2628('0x25e6')]['id']]});})[_0x5d3ad9('0x1166')](function(){const _0x430a5b=_0x5d3ad9;return _0x4af9b0[_0x430a5b('0x1c44')][_0x430a5b('0xd83')]({'sort':_0x430a5b('0x4f0'),'nolimit':!![]})[_0x430a5b('0xa44')];})['then'](function(_0x15b296){const _0x22be59=_0x5d3ad9;_0x1cf994[_0x22be59('0x1ed2')]=_0x15b296||{'count':0x0,'rows':[]};})[_0x5d3ad9('0x1166')](function(){const _0x3129d4=_0x5d3ad9;return _0x1cf994[_0x3129d4('0xf73')]();})[_0x5d3ad9('0x1166')](function(){return _0x1cf994['getFaxAccounts']();})[_0x5d3ad9('0x1166')](function(){return _0x1cf994['getSmsAccounts']();})['then'](function(){const _0x4445d=_0x5d3ad9;return _0x1cf994[_0x4445d('0x22a4')]();})['then'](function(){const _0x34579a=_0x5d3ad9;return _0x1cf994[_0x34579a('0xc48')]();})[_0x5d3ad9('0x1166')](function(){const _0xb98d4e=_0x5d3ad9;return _0x1cf994[_0xb98d4e('0x36d')]();})[_0x5d3ad9('0x1166')](function(){const _0x26c05c=_0x5d3ad9;return _0x1cf994[_0x26c05c('0x5a1')]();})[_0x5d3ad9('0x1a80')](function(){const _0x4741b9=_0x5d3ad9;_0x1cf994[_0x4741b9('0x1f3')]=!![];})['finally'](function(){const _0x377f7d=_0x5d3ad9;_0x1524a0(),_0xc2ea2b(),_0xfba886['on'](_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x1298')]+_0x377f7d('0x191b'),_0x1cf994[_0x377f7d('0xaae')]),_0xfba886['on'](_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x1298')]+_0x377f7d('0x444'),_0x1cf994[_0x377f7d('0xaae')]),_0xfba886['on'](_0x1cf994[_0x377f7d('0xbe3')]['channel']+_0x377f7d('0x1f6f'),_0x1cf994[_0x377f7d('0x1bc5')]),_0xfba886['on'](_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x1298')]+_0x377f7d('0x6ee'),_0x1cf994['onInteractionSave']),_0xfba886['on'](_0x377f7d('0x208a')+_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x1298')]+'_interactions:save',_0x1cf994[_0x377f7d('0xac1')]),_0xfba886['on']('user_has_'+_0x1cf994['tab']['channel']+_0x377f7d('0xac7'),_0x1cf994[_0x377f7d('0x1cda')]),_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x472')]=_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x472')]?_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x472')]:'',_0x1cf994[_0x377f7d('0x1f61')]=!![],_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x1298')]===_0x377f7d('0x1bfa')&&(_0x1cf994['draft']=_0x216e25[_0x377f7d('0xec7')](_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x25e6')]['id']),_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x2471')]&&(_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x25e6')][_0x377f7d('0xa5b')]?(_0x216e25[_0x377f7d('0x6ff')](_0x1cf994[_0x377f7d('0xbe3')][_0x377f7d('0x25e6')]['id']),_0x1cf994[_0x377f7d('0xfca')]=null):_0x178667()));}));}function _0x107380(_0x2857d3){const _0x1322ae=_0x250716;if(_0x2857d3[_0x1322ae('0x18fe')])return _0x2cfb05()[_0x1322ae('0x1257')](_0x2cfb05()['map'](_0x1cf994['faxAccounts']?_0x1cf994['faxAccounts']['rows']:[],'id'),_0x2857d3[_0x1322ae('0x18fe')]);else{if(_0x2857d3[_0x1322ae('0xb8')])return _0x2cfb05()[_0x1322ae('0x1257')](_0x2cfb05()[_0x1322ae('0x2563')](_0x1cf994[_0x1322ae('0x28ff')]?_0x1cf994[_0x1322ae('0x28ff')][_0x1322ae('0x269a')]:[],'id'),_0x2857d3['OpenchannelAccountId']);else{if(_0x2857d3[_0x1322ae('0xa74')])return _0x2cfb05()[_0x1322ae('0x1257')](_0x2cfb05()['map'](_0x1cf994['smsAccounts']?_0x1cf994[_0x1322ae('0x1d76')][_0x1322ae('0x269a')]:[],'id'),_0x2857d3[_0x1322ae('0xa74')]);else{if(_0x2857d3[_0x1322ae('0x1b88')])return _0x2cfb05()[_0x1322ae('0x1257')](_0x2cfb05()[_0x1322ae('0x2563')](_0x1cf994[_0x1322ae('0x1974')]?_0x1cf994[_0x1322ae('0x1974')]['rows']:[],'id'),_0x2857d3[_0x1322ae('0x1b88')]);else{if(_0x2857d3[_0x1322ae('0x56')])return _0x2cfb05()[_0x1322ae('0x1257')](_0x2cfb05()[_0x1322ae('0x2563')](_0x1cf994[_0x1322ae('0xf85')]?_0x1cf994['mailAccounts']['rows']:[],'id'),_0x2857d3[_0x1322ae('0x56')]);else{if(_0x2857d3[_0x1322ae('0x1e02')])return _0x2cfb05()[_0x1322ae('0x1257')](_0x2cfb05()['map'](_0x1cf994[_0x1322ae('0x20e0')]?_0x1cf994['chatAccounts'][_0x1322ae('0x269a')]:[],'id'),_0x2857d3['ChatWebsiteId']);else{if(_0x2857d3[_0x1322ae('0x1f2c')])return!![];}}}}}}return![];}function _0x2dc28e(_0x15e1b7){const _0x14fdda=_0x250716;let _0x4b63f8;_0x1cf994[_0x14fdda('0x25e6')]['id']==_0x15e1b7[_0x2cfb05()[_0x14fdda('0x114b')](_0x1cf994[_0x14fdda('0xbe3')][_0x14fdda('0x1298')])+'InteractionId']&&(_0x1cf994[_0x14fdda('0x25e6')][_0x14fdda('0x1bc7')]&&(_0x4b63f8=_0x2cfb05()[_0x14fdda('0xc38')](_0x1cf994['interaction'][_0x14fdda('0x1bc7')],{'id':_0x15e1b7[_0x14fdda('0x122a')]})),!_0x4b63f8&&_0x1cf994['interaction'][_0x14fdda('0x1bc7')]['push']({'id':_0x15e1b7[_0x14fdda('0x122a')]}));}function _0x5338f1(_0x5e7dbf){const _0xe63a28=_0x250716;_0x1cf994[_0xe63a28('0x25e6')]['id']==_0x5e7dbf[_0x2cfb05()[_0xe63a28('0x114b')](_0x1cf994[_0xe63a28('0xbe3')][_0xe63a28('0x1298')])+_0xe63a28('0x18e8')]&&(_0x1cf994[_0xe63a28('0x25e6')][_0xe63a28('0x1bc7')]&&_0x2cfb05()[_0xe63a28('0x127f')](_0x1cf994[_0xe63a28('0x25e6')][_0xe63a28('0x1bc7')],{'id':_0x5e7dbf[_0xe63a28('0x122a')]}));}function _0x18e283(_0x3f6d93){const _0x4fd5d0=_0x250716;if(_0x3f6d93){try{_0x2cfb05()['templateSettings'][_0x4fd5d0('0x1e87')]=/{{([\s\S]+?)}}/g;const _0x1608b3=_0x2cfb05()[_0x4fd5d0('0x243')](_0x3f6d93['value']),_0x2e96ff={'user':_0x1cf994[_0x4fd5d0('0x557')],'account':_0x1cf994['account'],'interaction':_0x1cf994['interaction'],'contact':_0x1cf994[_0x4fd5d0('0x25e6')]&&_0x1cf994['interaction'][_0x4fd5d0('0x21a4')]?_0x1cf994['interaction'][_0x4fd5d0('0x21a4')]:{}};_0x1cf994[_0x4fd5d0('0xbe3')][_0x4fd5d0('0x472')]+='\x20'+_0x1608b3(_0x2e96ff),_0x1cf994[_0x4fd5d0('0x1b47')][_0x4fd5d0('0xe96')](_0x1cf994[_0x4fd5d0('0xbe3')][_0x4fd5d0('0x472')]);}catch(_0x2bb039){_0x1cf994[_0x4fd5d0('0xbe3')]['areaText']+='\x20'+_0x3f6d93[_0x4fd5d0('0x18e0')],_0x1cf994[_0x4fd5d0('0x1b47')][_0x4fd5d0('0xe96')](_0x1cf994[_0x4fd5d0('0xbe3')][_0x4fd5d0('0x472')]);}_0x1cf994['selectedItem']=null,_0x1cf994[_0x4fd5d0('0x23c1')]();}}function _0x465cdd(_0x4ec9bf){const _0x5efeaf=_0x250716,_0x155f56=_0x45b187['defer']();let _0x1b3720=[];const _0x2e0bec={},_0xa7ace=_0x1cf994[_0x5efeaf('0xbe3')][_0x5efeaf('0x1298')]===_0x5efeaf('0xde2')?'ChatWebsiteId':_0x2cfb05()[_0x5efeaf('0x92c')](_0x1cf994[_0x5efeaf('0xbe3')]['channel'])+'AccountId';return _0x2e0bec[_0x5efeaf('0x1c33')]=_0x4ec9bf,_0x2e0bec[_0xa7ace]=_0x1cf994[_0x5efeaf('0x1a32')]['id'],_0x4af9b0[_0x5efeaf('0x1b1f')]['get'](_0x2e0bec)['$promise'][_0x5efeaf('0x1166')](function(_0x2cc133){const _0x3c28ab=_0x5efeaf;return _0x1b3720=_0x2cfb05()[_0x3c28ab('0x1c6a')](_0x1b3720,_0x2cc133[_0x3c28ab('0x269a')]),_0x4af9b0[_0x3c28ab('0x1b1f')][_0x3c28ab('0xd83')]({'filter':_0x4ec9bf})['$promise'];})[_0x5efeaf('0x1166')](function(_0x115279){const _0x38ba62=_0x5efeaf;_0x1b3720=_0x2cfb05()[_0x38ba62('0x1c6a')](_0x1b3720,_0x2cfb05()['filter'](_0x115279[_0x38ba62('0x269a')],function(_0x3b9b22){const _0x308f86=_0x38ba62;return!_0x3b9b22[_0x308f86('0x56')]&&!_0x3b9b22[_0x308f86('0x18fe')]&&!_0x3b9b22['SmsAccountId']&&!_0x3b9b22[_0x308f86('0x1b88')]&&!_0x3b9b22[_0x308f86('0xb8')]&&!_0x3b9b22[_0x308f86('0x1e02')];})),_0x155f56['resolve'](_0x1b3720);})['catch'](function(_0xb254ad){const _0x1d3796=_0x5efeaf;_0x155f56[_0x1d3796('0x21bf')](_0xb254ad);}),_0x155f56[_0x5efeaf('0x1f48')];}function _0x425e87(_0x2632df,_0x462991){const _0x41f3ec=_0x250716;try{_0x1cf994[_0x41f3ec('0xbe3')]&&!_0x1cf994['tab'][_0x41f3ec('0xbca')]&&_0x401c2e[_0x41f3ec('0x23ac')][_0x41f3ec('0x23ac')][_0x41f3ec('0x23ac')]['vm'][_0x41f3ec('0x247b')](_0x462991||_0x1cf994[_0x41f3ec('0x26db')]);}catch(_0x6f11f3){_0x377926[_0x41f3ec('0xfc9')]({'title':'ERROR\x20OPEN\x20CONTACT','msg':'Unable\x20to\x20open\x20the\x20contact'});}}function _0x4ea81b(_0x309624,_0x13af73){const _0x305ab2=_0x250716;try{if(_0x13af73[_0x305ab2('0x56')])return _0x401c2e[_0x305ab2('0x23ac')][_0x305ab2('0x23ac')]['$parent']['vm'][_0x305ab2('0x126e')](_0x305ab2('0x1bfa'),_0x13af73);else{if(_0x13af73[_0x305ab2('0x1e02')])return _0x401c2e[_0x305ab2('0x23ac')][_0x305ab2('0x23ac')][_0x305ab2('0x23ac')]['vm'][_0x305ab2('0x126e')](_0x305ab2('0xde2'),_0x13af73);else{if(_0x13af73['SmsAccountId'])return _0x401c2e[_0x305ab2('0x23ac')]['$parent']['$parent']['vm'][_0x305ab2('0x126e')]('sms',_0x13af73);else{if(_0x13af73['WhatsappAccountId'])return _0x401c2e[_0x305ab2('0x23ac')]['$parent'][_0x305ab2('0x23ac')]['vm'][_0x305ab2('0x126e')](_0x305ab2('0x116e'),_0x13af73);else{if(_0x13af73[_0x305ab2('0xb8')])return _0x401c2e[_0x305ab2('0x23ac')]['$parent'][_0x305ab2('0x23ac')]['vm'][_0x305ab2('0x126e')](_0x305ab2('0x26c'),_0x13af73);else{if(_0x13af73[_0x305ab2('0x18fe')])return _0x401c2e[_0x305ab2('0x23ac')][_0x305ab2('0x23ac')]['$parent']['vm']['addInteractionTab'](_0x305ab2('0x1fc7'),_0x13af73);}}}}}}catch(_0x476bb6){_0x377926[_0x305ab2('0xfc9')]({'title':_0x305ab2('0x10ef'),'msg':_0x305ab2('0x1330')});}}function _0x166b68(){const _0x466501=_0x250716;_0x183f97[_0x466501('0x1f80')]({'controller':_0x466501('0x2668'),'controllerAs':'vm','templateUrl':_0x45fe34,'parent':angular[_0x466501('0x1194')](_0x129e92[_0x466501('0x8d2')]),'clickOutsideToClose':!![],'skipHide':Boolean(_0x1cf994['tab'][_0x466501('0xbca')]),'resolve':{'tags':[_0x466501('0x1fbc'),function(_0x3a27b1){const _0x41ce2a=_0x466501;return _0x3a27b1['resolve'](_0x41ce2a('0x1dfc'),{'sort':'name','nolimit':!![],'fields':_0x41ce2a('0x1341')});}]},'locals':{'channel':_0x1cf994['tab']['channel'],'interaction':_0x1cf994[_0x466501('0xbe3')][_0x466501('0x25e6')]}});}function _0x3c79c4(){const _0x5e57d0=_0x250716,_0x514130=_0x1cf994[_0x5e57d0('0x557')][_0x5e57d0('0x2540')]||_0x1cf994[_0x5e57d0('0x557')][_0x5e57d0('0x1c5c')]||_0x1cf994['user'][_0x5e57d0('0xb4')]||_0x1cf994[_0x5e57d0('0x557')][_0x5e57d0('0x287f')]||_0x1cf994['user'][_0x5e57d0('0x5aa')],_0x46e996=!_0x1cf994['tab'][_0x5e57d0('0x25e6')][_0x5e57d0('0x1758')][_0x5e57d0('0x10d0')];_0x183f97[_0x5e57d0('0x1f80')]({'controller':_0x5e57d0('0xa39'),'controllerAs':'vm','templateUrl':_0x25a3f3,'parent':angular[_0x5e57d0('0x1194')](_0x129e92[_0x5e57d0('0x8d2')]),'clickOutsideToClose':_0x46e996,'escapeToClose':_0x46e996,'onRemoving':function(){const _0x400f57=_0x5e57d0;_0x1cf994['user']&&_0x1cf994['interaction'][_0x400f57('0x1758')][_0x400f57('0x10d0')]&&!_0x514130&&_0x4af9b0[_0x400f57('0x557')][_0x400f57('0x20eb')]({'id':_0x1cf994[_0x400f57('0x557')]['id']})[_0x400f57('0xa44')]['catch'](function(_0x447238){console['error'](_0x447238);});},'locals':{'user':_0x1cf994[_0x5e57d0('0x557')],'channel':_0x1cf994['tab'][_0x5e57d0('0x1298')],'interaction':_0x1cf994[_0x5e57d0('0xbe3')]['interaction']}})[_0x5e57d0('0x1166')](function(_0xecc95b){const _0x3cfc8c=_0x5e57d0;_0x1cf994[_0x3cfc8c('0xbe3')]['saved']=Boolean(_0xecc95b),_0xecc95b&&_0x401c2e[_0x3cfc8c('0x23ac')]['$parent'][_0x3cfc8c('0x23ac')]['vm'][_0x3cfc8c('0x11a3')](_0x1cf994[_0x3cfc8c('0xbe3')]);});}function _0x10950e(_0x365870,_0x40730d){const _0xdf33d3=_0x250716;_0x1cf994[_0xdf33d3('0xbe3')][_0xdf33d3('0x1e70')]=_0x40730d,_0x183f97[_0xdf33d3('0x1f80')]({'controller':_0xdf33d3('0x2709'),'controllerAs':'vm','templateUrl':_0x5f05e0,'parent':angular['element'](_0x129e92['body']),'clickOutsideToClose':![],'locals':{'account':_0x1cf994[_0xdf33d3('0x1a32')],'message':_0x1cf994[_0xdf33d3('0xbe3')][_0xdf33d3('0x1e70')],'type':_0x365870,'interaction':_0x1cf994[_0xdf33d3('0x25e6')]},'fullscreen':!![],'skipHide':Boolean(_0x1cf994[_0xdf33d3('0xbe3')]['spy'])})['then'](function(_0x384eec){const _0x3069f1=_0xdf33d3;if(_0x384eec){if(_0x384eec[_0x3069f1('0x1e70')]&&_0x384eec[_0x3069f1('0x1e70')][_0x3069f1('0x34f')])_0x1cf994[_0x3069f1('0xfca')]?_0x216e25[_0x3069f1('0x1449')]({'id':_0x1cf994[_0x3069f1('0xfca')]['id'],'channel':_0x3069f1('0x1bfa'),'account':_0x1cf994['account'],'message':_0x384eec[_0x3069f1('0x1e70')],'contact':_0x1cf994[_0x3069f1('0x26db')],'interaction':_0x1cf994[_0x3069f1('0x25e6')]}):_0x216e25[_0x3069f1('0x126a')]({'channel':_0x3069f1('0x1bfa'),'account':_0x1cf994[_0x3069f1('0x1a32')],'message':_0x384eec['message'],'contact':_0x1cf994[_0x3069f1('0x26db')],'interaction':_0x1cf994[_0x3069f1('0x25e6')]}),_0x1cf994[_0x3069f1('0xfca')]=_0x216e25[_0x3069f1('0xec7')](_0x1cf994[_0x3069f1('0xbe3')][_0x3069f1('0x25e6')]['id']);else{const _0x30bda2=_0x384eec;_0x30bda2&&_0x309f05(_0x30bda2),_0x30bda2[_0x3069f1('0x7ee')]&&_0x1cf994[_0x3069f1('0x25e6')]&&_0x1cf994[_0x3069f1('0x25e6')]['id']&&(_0x30bda2[_0x3069f1('0x7ee')]['id']=_0x1cf994[_0x3069f1('0x25e6')]['id'],_0x4af9b0[_0x3069f1('0x382')][_0x3069f1('0x1449')](_0x30bda2[_0x3069f1('0x7ee')])[_0x3069f1('0xa44')][_0x3069f1('0x1166')](function(_0x374bc2){const _0x2da003=_0x3069f1;if(_0x374bc2&&_0x374bc2[_0x2da003('0xa5b')])_0x1cf994[_0x2da003('0xbe3')][_0x2da003('0x26ae')]=!![],_0x1cf994[_0x2da003('0x25e6')][_0x2da003('0xa5b')]=!![],_0x3c79c4();else _0x30bda2['Interaction'][_0x2da003('0xcfc')]!==null&&(_0x1cf994[_0x2da003('0xbe3')]['saved']=!![],_0x1cf994[_0x2da003('0xbe3')][_0x2da003('0x25e6')][_0x2da003('0xcfc')]=_0x30bda2[_0x2da003('0x7ee')][_0x2da003('0xcfc')],_0x401c2e[_0x2da003('0x23ac')][_0x2da003('0x23ac')][_0x2da003('0x23ac')]['vm'][_0x2da003('0x11a3')](_0x1cf994['tab']));})[_0x3069f1('0x1a80')](function(_0x4ccd1a){const _0x3223cd=_0x3069f1;console[_0x3223cd('0xfc9')](_0x4ccd1a);}));}}})[_0xdf33d3('0x1951')](function(){const _0x3e56a5=_0xdf33d3;_0x1cf994['tab'][_0x3e56a5('0x2471')]=![];});}function _0x79eab7(_0x6e782c,_0x479e27){const _0x58297f=_0x250716;if(_0x479e27['inReplyTo']){const _0x39b021=_0x2cfb05()[_0x58297f('0xc38')](_0x1cf994[_0x58297f('0xcfa')][_0x58297f('0x269a')],{'messageId':_0x479e27[_0x58297f('0x1472')]});if(_0x39b021)_0x10950e(_0x6e782c,_0x39b021);else return _0x4af9b0['mailMessage'][_0x58297f('0xd83')]({'messageId':_0x479e27[_0x58297f('0x1472')]})[_0x58297f('0xa44')][_0x58297f('0x1166')](function(_0x4a4624){const _0x1f8c73=_0x58297f;_0x10950e(_0x6e782c,_0x4a4624&&_0x4a4624[_0x1f8c73('0x240f')]?_0x4a4624[_0x1f8c73('0x269a')][0x0]:undefined);})[_0x58297f('0x1a80')](function(_0x1652bf){const _0x3ccde0=_0x58297f;console[_0x3ccde0('0xfc9')](_0x1652bf),_0x10950e(_0x6e782c,undefined);});}else _0x10950e(_0x6e782c,_0x479e27);}function _0x255e08(_0x165678){const _0x36d1a5=_0x250716,_0x347766={'to':[]};_0x347766['to'][_0x36d1a5('0x1514')](_0x1cf994['contact'][_0x36d1a5('0x1fc7')]),_0x183f97[_0x36d1a5('0x1f80')]({'controller':_0x36d1a5('0x14e2'),'controllerAs':'vm','templateUrl':_0x2d50de,'parent':angular[_0x36d1a5('0x1194')](_0x129e92[_0x36d1a5('0x8d2')]),'clickOutsideToClose':![],'locals':{'account':_0x1cf994[_0x36d1a5('0x1a32')],'message':_0x347766,'type':_0x165678},'fullscreen':!![]})[_0x36d1a5('0x1166')](function(_0x570c03){const _0x10a8cf=_0x36d1a5;return _0x4af9b0[_0x10a8cf('0x2085')][_0x10a8cf('0x20ba')]({'id':_0x1cf994[_0x10a8cf('0x1a32')]['id']},_0x570c03)[_0x10a8cf('0xa44')][_0x10a8cf('0x1166')](function(_0x37839b){const _0x174b55=_0x10a8cf;_0x377926[_0x174b55('0x103b')]({'title':_0x174b55('0x11ac'),'msg':_0x174b55('0x1605')}),_0x401c2e[_0x174b55('0x23ac')]['vm'][_0x174b55('0x126e')](_0x174b55('0x1fc7'),_0x37839b);})[_0x10a8cf('0x1a80')](function(_0x263dfc){const _0x25502f=_0x10a8cf;if(_0x263dfc['data']&&_0x263dfc['data']['errors']&&_0x263dfc['data'][_0x25502f('0x61a')][_0x25502f('0x264b')])for(let _0x376364=0x0;_0x376364<_0x263dfc[_0x25502f('0x25f4')]['errors'][_0x25502f('0x264b')];_0x376364++){_0x377926['error']({'title':_0x263dfc[_0x25502f('0x25f4')][_0x25502f('0x61a')][_0x376364][_0x25502f('0x1345')],'msg':_0x263dfc[_0x25502f('0x25f4')][_0x25502f('0x61a')][_0x376364][_0x25502f('0x1e70')]});}else _0x377926[_0x25502f('0xfc9')]({'title':_0x25502f('0x73e'),'msg':_0x263dfc[_0x25502f('0x25f4')]?JSON[_0x25502f('0xbac')](_0x263dfc[_0x25502f('0x25f4')]):_0x263dfc[_0x25502f('0x1e70')]||_0x263dfc[_0x25502f('0x1586')]()});});});}function _0x4de84f(_0x4b7f02,_0xdfdd14){const _0x4623b0=_0x250716;_0x183f97['show']({'controller':_0x4623b0('0xd15'),'controllerAs':'vm','templateUrl':_0x45ce09,'parent':angular['element'](_0x129e92[_0x4623b0('0x8d2')]),'clickOutsideToClose':![],'locals':{'account':_0x1cf994[_0x4623b0('0x1a32')],'message':_0xdfdd14,'type':_0x4b7f02},'fullscreen':!![],'skipHide':Boolean(_0x1cf994[_0x4623b0('0xbe3')][_0x4623b0('0xbca')])})[_0x4623b0('0x1166')](function(_0x2a3356){_0x2a3356&&_0x309f05(_0x2a3356);});}function _0x47e3f7(_0x79c6a8,_0x55f3eb){const _0x5cb347=_0x250716;_0x183f97[_0x5cb347('0x1f80')]({'controller':_0x5cb347('0xa2e'),'controllerAs':'vm','templateUrl':_0x4b4a31,'parent':angular['element'](_0x129e92[_0x5cb347('0x8d2')]),'clickOutsideToClose':![],'locals':{'account':_0x1cf994[_0x5cb347('0x1a32')],'message':_0x55f3eb,'type':_0x79c6a8},'fullscreen':!![],'skipHide':Boolean(_0x1cf994['tab']['spy'])})[_0x5cb347('0x1166')](function(_0x40f7ba){_0x40f7ba&&_0x309f05(_0x40f7ba);});}function _0x30e5d9(){const _0x2058b4=_0x250716;if(_0x1cf994[_0x2058b4('0x25e6')]){const _0x4b9a2c=_0x2cfb05()[_0x2058b4('0x1716')](_0x1cf994[_0x2058b4('0xcfa')][_0x2058b4('0x269a')],function(_0x3ad37a){return _0x3ad37a['direction']==='in';});_0x4b9a2c?_0x183f97[_0x2058b4('0x1f80')]({'controller':_0x2058b4('0xf6a'),'controllerAs':'vm','templateUrl':_0x19613f,'parent':angular['element'](_0x129e92[_0x2058b4('0x8d2')]),'clickOutsideToClose':![],'locals':{'account':_0x1cf994[_0x2058b4('0x1a32')],'interaction':_0x1cf994['interaction'],'message':_0x4b9a2c,'channel':_0x1cf994[_0x2058b4('0xbe3')]['channel']}})[_0x2058b4('0x1166')](function(_0x171a66){const _0x25dd71=_0x2058b4;_0x1cf994[_0x25dd71('0xbe3')][_0x25dd71('0x26ae')]=Boolean(_0x171a66),_0x171a66&&_0x401c2e[_0x25dd71('0x23ac')][_0x25dd71('0x23ac')][_0x25dd71('0x23ac')]['vm'][_0x25dd71('0x11a3')](_0x1cf994[_0x25dd71('0xbe3')]);}):_0x377926[_0x2058b4('0xfc9')]({'title':_0x2058b4('0x559'),'msg':_0x2058b4('0x1c04')});}}function _0x42b283(_0x10eca0){const _0x18823e=_0x250716,_0x175cf6={},_0x5e7ba7=_0x1cf994['tab']['channel']===_0x18823e('0xde2')?_0x18823e('0x1e02'):_0x2cfb05()[_0x18823e('0x92c')](_0x1cf994[_0x18823e('0xbe3')]['channel'])+'AccountId';return _0x175cf6[_0x5e7ba7]=_0x1cf994['interaction'][_0x5e7ba7]['toString'](),_0x175cf6[_0x2cfb05()[_0x18823e('0x92c')](_0x1cf994[_0x18823e('0xbe3')][_0x18823e('0x1298')])+_0x18823e('0x18e8')]=_0x1cf994['interaction']['id'],(_0x1cf994[_0x18823e('0xbe3')][_0x18823e('0x1298')]==='sms'||_0x1cf994[_0x18823e('0xbe3')]['channel']===_0x18823e('0x116e'))&&(_0x175cf6['phone']=_0x1cf994[_0x18823e('0x25e6')][_0x18823e('0x2026')]),_0x10eca0&&(_0x175cf6['UserId']=_0x1cf994[_0x18823e('0x557')]['id'],_0x175cf6['ContactId']=_0x1cf994['interaction']['ContactId'],_0x175cf6[_0x18823e('0x8d2')]=_0x10eca0),_0x175cf6;}function _0x17702b(_0x3e1128){const _0x330f69=_0x250716;if(_0x3e1128['size']>_0x43bc9a)return _0x377926[_0x330f69('0xfc9')]({'title':_0x330f69('0x11e6'),'msg':'The\x20max\x20allowed\x20size\x20is\x20'+_0x389ee9+'MB'}),![];return!![];}function _0x4cb3d9(_0xe3b0f6,_0x2d88f8){const _0x4aa1d8=_0x250716,_0x2ba270=JSON[_0x4aa1d8('0x1295')](_0x2d88f8);let _0x8c3ace=_0x2ba270[_0x4aa1d8('0x4f0')];_0x1cf994['tab']['channel']===_0x4aa1d8('0xde2')&&(_0x8c3ace=_0x4aa1d8('0x1322')+(_0x1cf994[_0x4aa1d8('0x1a32')][_0x4aa1d8('0x6ed')]?_0x1cf994['account']['remote']:_0x3191a[_0x4aa1d8('0x6f1')]()+'://'+_0x3191a[_0x4aa1d8('0x1690')]())+_0x4aa1d8('0xc5')+_0x1cf994[_0x4aa1d8('0x25e6')]['id']+_0x4aa1d8('0x1663')+_0x2ba270['id']+_0x4aa1d8('0x18e6')+_0x1cf994['account'][_0x4aa1d8('0x1f67')]+'\x22\x20target=\x22_self\x22>'+_0x2ba270[_0x4aa1d8('0x4f0')]+_0x4aa1d8('0x1959')),_0x309f05({'body':_0x8c3ace,'AttachmentId':_0x2ba270['id']});}function _0x267f60(){const _0x5102c3=_0x250716;_0x1cf994[_0x5102c3('0xe57')][_0x5102c3('0x13d1')][_0x5102c3('0x1ca3')][_0x5102c3('0x5fb')]={'X-Requested-With':'XMLHttpRequest','Authorization':'Bearer\x20'+_0x421395[_0x5102c3('0xd83')]('motion.token')},_0x1cf994[_0x5102c3('0xe57')][_0x5102c3('0x13d1')]['upload']();}function _0x198d5a(_0x333412,_0x36628b){const _0x4f4890=_0x250716;if(_0x333412&&_0x333412[_0x4f4890('0x150')]===0xd&&_0x333412[_0x4f4890('0x108e')])return;if(_0x333412&&_0x333412[_0x4f4890('0x150')]!==0xd)return;if(_0x36628b['trim']()==='')return;_0x309f05(_0x42b283(_0x36628b['replace'](/\n$/,'')));}function _0xc2ea2b(){const _0x39381e=_0x250716;_0x1cf994[_0x39381e('0xbe3')]['channel']!==_0x39381e('0x1bfa')&&_0x39c17e(function(){const _0x9eecb2=_0x39381e,_0x1890ec=angular[_0x9eecb2('0x1194')](_0x129e92['find'](_0x9eecb2('0x195d')+_0x1cf994[_0x9eecb2('0xbe3')]['id']+'\x27]'));_0x1890ec&&_0x1890ec[0x0]&&(_0x1890ec[0x0][_0x9eecb2('0x216')]=_0x1890ec[0x0]['scrollHeight']);},0x0);}function _0x4bd92c(_0x16abec){const _0x345b11=_0x250716,_0x20d520='loading...';if(_0x16abec){if(_0x16abec[_0x345b11('0x2788')]==='in')return _0x16abec[_0x345b11('0x21a4')]?_0x16abec['Contact']['firstName']||_0x345b11('0x3b7'):_0x20d520;else{if(_0x16abec[_0x345b11('0x122a')])return _0x1cf994[_0x345b11('0x7b5')]?_0x1cf994[_0x345b11('0x7b5')][_0x16abec[_0x345b11('0x122a')]]:_0x20d520;}return'System'||0x0;}}function _0x4b3d5d(_0x26052e,_0x5ab477){const _0x15ec5e=_0x250716;_0x1cf994[_0x15ec5e('0xbe3')]['channel']&&_0x26052e['id']&&_0x4af9b0[_0x1cf994['tab'][_0x15ec5e('0x1298')]+_0x15ec5e('0x1720')][_0x15ec5e('0x2ad')]({'id':_0x26052e['id'],'attachments':_0x5ab477})['$promise'][_0x15ec5e('0x1166')](function(_0x3c4285){const _0x2477d5=_0x15ec5e,_0x596885=[_0x3c4285['buffer']];let _0x410741=_0x2477d5('0x2ad');const _0x580337=new Blob(_0x596885,{'type':_0x3c4285[_0x2477d5('0x1345')]});_0x410741=_0x1cf994['tab']['channel']+_0x2477d5('0x951')+_0x26052e['id']+_0x2477d5('0x1707');const _0x46a8af=window[_0x2477d5('0x136d')][_0x2477d5('0xdd')]('a');_0x46a8af[_0x2477d5('0xffd')]('href',URL['createObjectURL'](_0x580337)),_0x46a8af[_0x2477d5('0xffd')](_0x2477d5('0x2ad'),_0x410741),document[_0x2477d5('0x8d2')]['appendChild'](_0x46a8af),_0x46a8af[_0x2477d5('0x3b4')]();})['catch'](function(_0x57be75){const _0x359b2c=_0x15ec5e;if(_0x57be75['data']&&_0x57be75[_0x359b2c('0x25f4')][_0x359b2c('0x61a')]&&_0x57be75[_0x359b2c('0x25f4')][_0x359b2c('0x61a')][_0x359b2c('0x264b')])for(let _0x53ebfe=0x0;_0x53ebfe<_0x57be75['data'][_0x359b2c('0x61a')][_0x359b2c('0x264b')];_0x53ebfe+=0x1){_0x377926[_0x359b2c('0xfc9')]({'title':_0x57be75[_0x359b2c('0x25f4')]['errors'][_0x53ebfe][_0x359b2c('0x1345')],'msg':_0x57be75['data'][_0x359b2c('0x61a')][_0x53ebfe]['message']});}else _0x377926['error']({'title':_0x57be75['status']?'API:'+_0x57be75[_0x359b2c('0x52d')]+'\x20-\x20'+_0x57be75[_0x359b2c('0xe1b')]:_0x359b2c('0x2103'),'msg':_0x57be75[_0x359b2c('0x25f4')]?JSON[_0x359b2c('0xbac')](_0x57be75[_0x359b2c('0x25f4')]['message']):_0x57be75['toString']()});});}function _0x3d1142(_0x39d176,_0x30b661){const _0x204502=_0x250716;_0x1cf994[_0x204502('0xbe3')][_0x204502('0x1298')]&&_0x39d176['id']&&_0x4af9b0[_0x1cf994[_0x204502('0xbe3')][_0x204502('0x1298')]+_0x204502('0x7ee')][_0x204502('0x2ad')]({'id':_0x39d176['id'],'attachments':_0x30b661})['$promise']['then'](function(_0xfab32b){const _0x338ef9=_0x204502,_0x4825ab=[_0xfab32b['buffer']],_0x18a857=_0x1cf994[_0x338ef9('0xbe3')][_0x338ef9('0x1298')]+_0x338ef9('0x762')+_0x39d176['id']+_0x338ef9('0x806'),_0x488f94=new Blob(_0x4825ab,{'type':_0xfab32b[_0x338ef9('0x1345')]}),_0x968b20=window[_0x338ef9('0x136d')][_0x338ef9('0xdd')]('a');_0x968b20[_0x338ef9('0xffd')](_0x338ef9('0x14f9'),URL[_0x338ef9('0x215a')](_0x488f94)),_0x968b20['setAttribute'](_0x338ef9('0x2ad'),_0x18a857),document[_0x338ef9('0x8d2')][_0x338ef9('0x21a')](_0x968b20),_0x968b20['click']();})[_0x204502('0x1a80')](function(_0x3fed9e){const _0x263883=_0x204502;if(_0x3fed9e['data']&&_0x3fed9e['data'][_0x263883('0x61a')]&&_0x3fed9e[_0x263883('0x25f4')][_0x263883('0x61a')]['length'])for(let _0x5a0f30=0x0;_0x5a0f30<_0x3fed9e['data']['errors'][_0x263883('0x264b')];_0x5a0f30+=0x1){_0x377926[_0x263883('0xfc9')]({'title':_0x3fed9e[_0x263883('0x25f4')][_0x263883('0x61a')][_0x5a0f30][_0x263883('0x1345')],'msg':_0x3fed9e[_0x263883('0x25f4')]['errors'][_0x5a0f30][_0x263883('0x1e70')]});}else _0x377926[_0x263883('0xfc9')]({'title':_0x3fed9e[_0x263883('0x52d')]?_0x263883('0x1e21')+_0x3fed9e[_0x263883('0x52d')]+_0x263883('0x11e1')+_0x3fed9e[_0x263883('0xe1b')]:_0x263883('0x6'),'msg':_0x3fed9e['data']?JSON[_0x263883('0xbac')](_0x3fed9e['data'][_0x263883('0x1e70')]):_0x3fed9e[_0x263883('0x1586')]()});});}function _0x309f05(_0x4d0b99){const _0x1de417=_0x250716;if(_0x4d0b99)return _0x4d0b99[_0x1cf994[_0x1de417('0xbe3')][_0x1de417('0x1298')]===_0x1de417('0xde2')?_0x1de417('0x1e02'):_0x2cfb05()[_0x1de417('0x92c')](_0x1cf994[_0x1de417('0xbe3')][_0x1de417('0x1298')])+_0x1de417('0x96a')]=_0x1cf994['interaction'][_0x1cf994[_0x1de417('0xbe3')]['channel']===_0x1de417('0xde2')?'ChatWebsiteId':_0x2cfb05()[_0x1de417('0x92c')](_0x1cf994['tab'][_0x1de417('0x1298')])+_0x1de417('0x96a')],_0x4d0b99[_0x2cfb05()[_0x1de417('0x92c')](_0x1cf994[_0x1de417('0xbe3')][_0x1de417('0x1298')])+_0x1de417('0x18e8')]=_0x1cf994['interaction']['id'],_0x4d0b99[_0x1de417('0x122a')]=_0x1cf994[_0x1de417('0x557')]['id'],_0x4d0b99[_0x1de417('0x1a17')]=_0x1cf994[_0x1de417('0x25e6')][_0x1de417('0x1a17')],_0x4d0b99['direction']=_0x1de417('0x15ff'),_0x4d0b99[_0x1de417('0x1908')]=Boolean(_0x1cf994[_0x1de417('0xbe3')]['spy']||_0x4d0b99['secret']),_0x4af9b0[_0x1cf994[_0x1de417('0xbe3')][_0x1de417('0x1298')]+_0x1de417('0x1720')][_0x1de417('0x9cc')](_0x4d0b99)[_0x1de417('0xa44')][_0x1de417('0x1166')](function(_0x1d096f){const _0xa9028f=_0x1de417;if(_0x1d096f&&_0x1d096f['id']){if(!_0x2cfb05()[_0xa9028f('0x1081')](_0x4d0b99['attachments'])){const _0x557f16=[];for(let _0x1f8bdc=0x0;_0x1f8bdc<_0x4d0b99['attachments']['length'];_0x1f8bdc++){const _0x79a945=_0x4d0b99[_0xa9028f('0x1e1d')][_0x1f8bdc];_0x79a945['MailMessageId']?_0x557f16[_0xa9028f('0x1514')](_0x4af9b0[_0xa9028f('0x21bc')]['clone']({'id':_0x79a945['id']},{'name':_0x79a945[_0xa9028f('0x4f0')],'basename':_0x79a945[_0xa9028f('0xa38')],'type':_0x79a945['type'],'MailMessageId':_0x1d096f['id']})[_0xa9028f('0xa44')]):_0x557f16[_0xa9028f('0x1514')](_0x4af9b0['attachment'][_0xa9028f('0x1449')]({'id':_0x79a945['id']},{'MailMessageId':_0x1d096f['id']})[_0xa9028f('0xa44')]);}return _0x45b187[_0xa9028f('0x2760')](_0x557f16);}}})[_0x1de417('0x1a80')](function(_0x4a77eb){const _0x45217d=_0x1de417;_0x377926[_0x45217d('0xfc9')]({'title':_0x4a77eb[_0x45217d('0x52d')]?_0x45217d('0x1e21')+_0x4a77eb['status']+_0x45217d('0x11e1')+_0x4a77eb['statusText']:_0x45217d('0x20db'),'msg':_0x4a77eb[_0x45217d('0x25f4')]?JSON['stringify'](_0x4a77eb['data']):_0x4a77eb['toString']()});})[_0x1de417('0x1951')](function(){const _0x62746d=_0x1de417;_0x1cf994['tab'][_0x62746d('0x1298')]===_0x62746d('0x1bfa')&&(_0x4d0b99[_0x62746d('0x2471')]&&(_0x216e25['removeByInteraction'](_0x1cf994[_0x62746d('0x25e6')]['id']),_0x1cf994[_0x62746d('0xfca')]=null)),_0x1cf994[_0x62746d('0xbe3')][_0x62746d('0x472')]='',_0xc2ea2b();});}function _0x7877eb(_0xa4d707){const _0x17ea57=_0x250716;_0x1cf994[_0x17ea57('0xbe3')][_0x17ea57('0x1298')]&&_0x1cf994[_0x17ea57('0x25e6')]&&_0x1cf994[_0x17ea57('0x25e6')]['id']&&_0x4af9b0[_0x1cf994[_0x17ea57('0xbe3')][_0x17ea57('0x1298')]+'Interaction'][_0x17ea57('0x1449')]({'id':_0x1cf994[_0x17ea57('0x25e6')]['id'],'substatus':_0xa4d707})[_0x17ea57('0xa44')][_0x17ea57('0x1a80')](function(_0xff07c1){console['error'](_0xff07c1);});}function _0x29cf8b(){const _0x2f9eea=_0x250716;if(_0x1cf994[_0x2f9eea('0xbe3')][_0x2f9eea('0x1298')]&&_0x1cf994['interaction']&&_0x1cf994['interaction']['id']){if(_0x1cf994[_0x2f9eea('0x1517')]['length'])for(let _0x387656=0x0;_0x387656<_0x1cf994['acceptedMessages'][_0x2f9eea('0x264b')];_0x387656+=0x1){_0x4af9b0[_0x1cf994[_0x2f9eea('0xbe3')][_0x2f9eea('0x1298')]+_0x2f9eea('0x1720')]['update']({'id':_0x1cf994[_0x2f9eea('0x1517')][_0x387656],'read':![],'UserId':null});}else for(let _0x55994f=0x0;_0x55994f<_0x1cf994['messages']['rows'][_0x2f9eea('0x264b')];_0x55994f+=0x1){if(_0x1cf994[_0x2f9eea('0xcfa')][_0x2f9eea('0x269a')][_0x55994f]['direction']==='in'){_0x1cf994[_0x2f9eea('0xcfa')][_0x2f9eea('0x269a')][_0x55994f][_0x2f9eea('0x122a')]===_0x1cf994[_0x2f9eea('0x557')]['id']?_0x4af9b0[_0x1cf994[_0x2f9eea('0xbe3')]['channel']+_0x2f9eea('0x1720')][_0x2f9eea('0x1449')]({'id':_0x1cf994[_0x2f9eea('0xcfa')][_0x2f9eea('0x269a')][_0x55994f]['id'],'read':![],'UserId':null}):_0x377926[_0x2f9eea('0xfc9')]({'title':'You\x20can\x27t\x20mark\x20as\x20unread','msg':_0x2f9eea('0x1368')});break;}}}_0x1cf994[_0x2f9eea('0xbe3')][_0x2f9eea('0x26ae')]=!![],_0x401c2e['$parent'][_0x2f9eea('0x23ac')]['$parent']['vm'][_0x2f9eea('0x11a3')](_0x1cf994[_0x2f9eea('0xbe3')]);}function _0x53d514(_0x1c13c8){const _0x1b4341=_0x250716;if(_0x1c13c8&&_0x1cf994['interaction']['id']!==_0x1c13c8['id'])return;_0x1c13c8['closed']&&(_0x1cf994[_0x1b4341('0xbe3')][_0x1b4341('0x26ae')]=!![]),_0x2cfb05()['merge'](_0x1cf994['interaction'],_0x1c13c8);}function _0x4e88d3(_0x34263e){const _0x14fe57=_0x250716;if(_0x34263e&&_0x1cf994[_0x14fe57('0x25e6')]['id']!=_0x34263e[_0x2cfb05()[_0x14fe57('0x92c')](_0x1cf994[_0x14fe57('0xbe3')][_0x14fe57('0x1298')])+_0x14fe57('0x18e8')])return;let _0x34f231=![];_0x1cf994['messages']?_0x34f231=_0x2cfb05()[_0x14fe57('0xc38')](_0x1cf994[_0x14fe57('0xcfa')][_0x14fe57('0x269a')],{'id':_0x34263e['id']}):_0x1cf994[_0x14fe57('0xcfa')]={'rows':[],'count':0x0},_0x34f231?_0x2cfb05()[_0x14fe57('0xcc3')](_0x34f231,_0x34263e):(_0x1cf994['tab'][_0x14fe57('0x1298')]===_0x14fe57('0x1bfa')?_0x1cf994[_0x14fe57('0xcfa')][_0x14fe57('0x269a')][_0x14fe57('0x2450')](_0x34263e):_0x1cf994[_0x14fe57('0xcfa')][_0x14fe57('0x269a')][_0x14fe57('0x1514')](_0x34263e),_0xc2ea2b());}function _0xff9c6e(_0x1c9eec){const _0x44db23=_0x250716;switch(_0x1c9eec){case _0x44db23('0xde2'):return _0x44db23('0xc49');case'mail':return _0x44db23('0x142d');case _0x44db23('0x146c'):return _0x44db23('0x1392');case _0x44db23('0x116e'):return'icon-whatsapp';case'openchannel':return _0x44db23('0x2052');case _0x44db23('0x1fc7'):return _0x44db23('0x23fb');default:return _0x44db23('0xc49');}}function _0x1cd247(_0x114591){const _0x384a26=_0x250716;switch(_0x114591){case _0x384a26('0xde2'):return'green-A700';case _0x384a26('0x1bfa'):return _0x384a26('0x28e8');case _0x384a26('0x146c'):return _0x384a26('0x1adc');case _0x384a26('0x26c'):return _0x384a26('0xb1e');case _0x384a26('0x1fc7'):return _0x384a26('0x1917');case _0x384a26('0x116e'):return _0x384a26('0xe6d');default:return _0x384a26('0x432');}}function _0x643d30(_0x5e6828){const _0x48ccc2=_0x250716;let _0x263521='';if(_0x5e6828[_0x48ccc2('0x18fe')])_0x263521=_0x48ccc2('0x1fc7');else{if(_0x5e6828[_0x48ccc2('0xb8')])_0x263521=_0x48ccc2('0x26c');else{if(_0x5e6828['SmsAccountId'])_0x263521=_0x48ccc2('0x146c');else{if(_0x5e6828['WhatsappAccountId'])_0x263521='whatsapp';else{if(_0x5e6828['MailAccountId'])_0x263521=_0x48ccc2('0x1bfa');else{if(_0x5e6828[_0x48ccc2('0x1e02')])_0x263521='chat';else _0x5e6828[_0x48ccc2('0x1f2c')]&&(_0x263521=_0x48ccc2('0x21da'));}}}}}return _0x1cd247(_0x263521);}function _0x2758cb(_0x5c184a){const _0xe216d7=_0x250716;if(_0x5c184a[_0xe216d7('0x1908')]&&_0x1cf994[_0xe216d7('0x557')]['id']!=_0x5c184a['UserId'])return'in';switch(_0x1cf994['setting'][_0xe216d7('0x15c2')]){case'left':if(_0x5c184a['direction']=='in')return _0x5c184a[_0xe216d7('0x2788')];return'out-left-aligned';case'right':if(_0x5c184a[_0xe216d7('0x2788')]=='in')return _0xe216d7('0x5c6');return _0x5c184a['direction'];default:return _0x5c184a[_0xe216d7('0x2788')];}}function _0x4ef9b9(){const _0x25dd65=_0x250716;_0x1cf994[_0x25dd65('0xa71')]=!_0x1cf994[_0x25dd65('0xa71')];}function _0x2ae86d(_0x5d63b5){const _0x10e30c=_0x250716;return _0x4af9b0['attachment'][_0x10e30c('0xd83')]({'MailMessageId':_0x5d63b5['id']})['$promise'][_0x10e30c('0x1166')](function(_0x28e657){const _0x4e1285=_0x10e30c;_0x28e657&&_0x28e657[_0x4e1285('0x269a')]&&(_0x5d63b5[_0x4e1285('0x1e1d')]=_0x28e657[_0x4e1285('0x269a')]);})[_0x10e30c('0x1a80')](function(_0x18821d){const _0x188f7c=_0x10e30c;_0x377926[_0x188f7c('0xfc9')]({'title':_0x18821d[_0x188f7c('0x52d')]?_0x188f7c('0x1e21')+_0x18821d[_0x188f7c('0x52d')]+_0x188f7c('0x11e1')+_0x18821d['statusText']:'ATTACHMENTS:GET','msg':_0x18821d[_0x188f7c('0x25f4')]?JSON[_0x188f7c('0xbac')](_0x18821d[_0x188f7c('0x25f4')]):_0x18821d[_0x188f7c('0x1586')]()});});}function _0x3040a8(_0x2ab9c){const _0x10728c=_0x250716;return _0x4af9b0[_0x10728c('0x21bc')]['download']({'id':_0x2ab9c['id']})['$promise'][_0x10728c('0x1166')](function(_0x240e8c){const _0x45a22e=_0x10728c;if(_0x240e8c){const _0x20dc64=new Blob([_0x240e8c[_0x45a22e('0x20ed')]],{'type':_0x240e8c[_0x45a22e('0x1345')]}),_0x15d03b=document[_0x45a22e('0xdd')]('a'),_0x1257ab=window[_0x45a22e('0x308')][_0x45a22e('0x215a')](_0x20dc64);_0x15d03b[_0x45a22e('0x14f9')]=_0x1257ab,_0x15d03b[_0x45a22e('0x21cc')]='_self',_0x15d03b[_0x45a22e('0x2ad')]=_0x2ab9c[_0x45a22e('0x4f0')],document[_0x45a22e('0x8d2')][_0x45a22e('0x21a')](_0x15d03b),_0x15d03b['click'](),setTimeout(function(){const _0x220c3c=_0x45a22e;document[_0x220c3c('0x8d2')][_0x220c3c('0x2b')](_0x15d03b),window[_0x220c3c('0x308')][_0x220c3c('0x16ee')](_0x1257ab);},0x64);}})[_0x10728c('0x1a80')](function(_0x81f021){const _0x27ccc0=_0x10728c;_0x377926['error']({'title':_0x81f021[_0x27ccc0('0x52d')]?_0x27ccc0('0x1e21')+_0x81f021[_0x27ccc0('0x52d')]+'\x20-\x20'+_0x81f021[_0x27ccc0('0xe1b')]:_0x27ccc0('0xd97'),'msg':_0x81f021[_0x27ccc0('0x25f4')]?JSON[_0x27ccc0('0xbac')](_0x81f021[_0x27ccc0('0x25f4')]):_0x81f021[_0x27ccc0('0x1586')]()});});}function _0x1524a0(){const _0x5dc97d=_0x250716;if(!_0x1cf994[_0x5dc97d('0xbe3')][_0x5dc97d('0xbca')]&&!_0x1cf994[_0x5dc97d('0x25e6')][_0x5dc97d('0xa5b')])for(let _0x43e0ca=0x0;_0x43e0ca<_0x1cf994['messages'][_0x5dc97d('0x269a')]['length'];_0x43e0ca+=0x1){_0x1cf994[_0x5dc97d('0xcfa')]['rows'][_0x43e0ca][_0x5dc97d('0x2788')]==='in'&&!_0x1cf994['messages'][_0x5dc97d('0x269a')][_0x43e0ca][_0x5dc97d('0x123')]&&(_0x4af9b0[_0x1cf994[_0x5dc97d('0xbe3')]['channel']+_0x5dc97d('0x1720')][_0x5dc97d('0x2384')]({'id':_0x1cf994[_0x5dc97d('0xcfa')][_0x5dc97d('0x269a')][_0x43e0ca]['id'],'UserId':_0x1cf994[_0x5dc97d('0x557')]['id']}),_0x1cf994['acceptedMessages'][_0x5dc97d('0x1514')](_0x1cf994[_0x5dc97d('0xcfa')]['rows'][_0x43e0ca]['id']));}}function _0x5f2af3(_0x3e2b34){const _0x52adeb=_0x250716;if(!_0x3e2b34[_0x52adeb('0x12e8')])return'('+_0x3735d7[_0x52adeb('0x25cc')](_0x52adeb('0x991'))+')';const _0x36f023=_0x2cfb05()[_0x52adeb('0xc4')]([_0x3e2b34[_0x52adeb('0x12e8')],_0x3e2b34[_0x52adeb('0xe18')],_0x3e2b34[_0x52adeb('0x228e')]]);return'('+_0x36f023['join'](_0x52adeb('0x11e1'))+')';}function _0x12666b(_0xf7a28){const _0x32c7d4=_0x250716;_0xf7a28&&_0xf7a28[_0x32c7d4('0x240f')]&&_0xf7a28[_0x32c7d4('0x269a')][_0x32c7d4('0x264b')]&&(_0x1cf994[_0x32c7d4('0x227e')]=_0x2cfb05()['concat'](_0x1cf994['journey'],_0xf7a28[_0x32c7d4('0x269a')]),_0x1cf994[_0x32c7d4('0x227e')][_0x32c7d4('0x2782')](function(_0x274c77){const _0x253e5e=_0x32c7d4;_0x274c77[_0x253e5e('0x267e')]=_0x5f2af3(_0x274c77);}));}function _0x241c4d(_0x3c6c96){const _0x2b0379=_0x250716;if(_0x3c6c96&&_0x3c6c96['id']){for(let _0x4103b5=0x0;_0x4103b5<_0x1cf994[_0x2b0379('0x19d')]['length'];_0x4103b5++){_0x4af9b0[_0x1cf994[_0x2b0379('0x19d')][_0x4103b5]+_0x2b0379('0x7ee')][_0x2b0379('0xd83')]({'ContactId':_0x3c6c96['id'],'journey':!![],'includeAll':!![]})[_0x2b0379('0xa44')][_0x2b0379('0x1166')](_0x12666b);}_0x4af9b0[_0x2b0379('0x26e0')][_0x2b0379('0xd83')]({'ContactId':_0x3c6c96['id'],'includeAll':!![]})['$promise'][_0x2b0379('0x1166')](_0x12666b);}}function _0x272e43(_0x31f592){const _0x23d994=_0x250716;return _0x31f592?String(_0x31f592)[_0x23d994('0xf3')](/<[^>]+>/gm,''):'';}function _0x178667(_0x4b13fe){const _0x2fd312=_0x250716;switch(_0x1cf994[_0x2fd312('0xbe3')]['channel']){case _0x2fd312('0x1bfa'):_0x1cf994[_0x2fd312('0xfca')][_0x2fd312('0xacc')][_0x2fd312('0x1560')]=_0x4b13fe?_0x2cfb05()[_0x2fd312('0xc38')](_0x1cf994[_0x2fd312('0x25e6')]['Messages'],['id',_0x4b13fe]):_0x1cf994[_0x2fd312('0x25e6')][_0x2fd312('0x116c')][_0x1cf994[_0x2fd312('0x25e6')][_0x2fd312('0x116c')]['length']-0x1],_0x10950e(_0x1cf994[_0x2fd312('0xfca')][_0x2fd312('0x1345')],_0x1cf994['draft']['content']);break;case _0x2fd312('0x1fc7'):break;case _0x2fd312('0x26c'):break;case _0x2fd312('0x146c'):break;case _0x2fd312('0x116e'):break;}}_0x401c2e['$on'](_0x250716('0x1c3f'),function(){const _0x1ac0ff=_0x250716;_0xfba886[_0x1ac0ff('0x1800')](_0x1cf994[_0x1ac0ff('0xbe3')]['channel']+_0x1ac0ff('0x191b')),_0xfba886[_0x1ac0ff('0x1800')](_0x1cf994['tab'][_0x1ac0ff('0x1298')]+_0x1ac0ff('0x444')),_0xfba886[_0x1ac0ff('0x1800')](_0x1cf994[_0x1ac0ff('0xbe3')]['channel']+_0x1ac0ff('0x1f6f')),_0xfba886[_0x1ac0ff('0x1800')](_0x1cf994[_0x1ac0ff('0xbe3')]['channel']+'Interaction:update'),_0xfba886[_0x1ac0ff('0x1800')](_0x1ac0ff('0x208a')+_0x1cf994['tab']['channel']+'_interactions:save'),_0xfba886[_0x1ac0ff('0x1800')](_0x1ac0ff('0x208a')+_0x1cf994['tab'][_0x1ac0ff('0x1298')]+_0x1ac0ff('0xac7'));});function _0x143373(_0x19b1c0){const _0x49821e=_0x250716,_0x5c429b={'id':_0x19b1c0['id']};return _0x4af9b0[_0x49821e('0x1162')][_0x49821e('0xcee')](_0x5c429b)[_0x49821e('0xa44')][_0x49821e('0x1166')](function(){const _0x475b84=_0x49821e;_0x377926[_0x475b84('0x103b')]({'title':_0x475b84('0x7cb'),'msg':_0x475b84('0x1f62')});})[_0x49821e('0x1a80')](function(){const _0x518940=_0x49821e;_0x377926['error']({'title':_0x518940('0x7cb'),'msg':_0x518940('0xa94')});});}}function _0x40b913(_0x37fd2e){return{'scope':{'ngBindHtmlUnsafe':'='},'template':'','link':function(_0x34e590){const _0x36061f=a0_0x3f2c;function _0xf39282(){const _0x335ce2=a0_0x3f2c,_0x260d6d=_0x335ce2('0x1762')+Math[_0x335ce2('0x813')](Math[_0x335ce2('0x2010')]()*0x270f+0x1);return _0x335ce2('0xde')+_0x260d6d+_0x335ce2('0x1f55')+_0x260d6d+_0x335ce2('0x159b');}_0x34e590[_0x36061f('0xef9')]=function(){const _0x49df42=_0x36061f,_0x200007=_0x2cfb05()['replace'](_0x34e590[_0x49df42('0xfb4')],_0x49df42('0x5df'),_0xf39282());_0x34e590['trustedHtml']=_0x37fd2e[_0x49df42('0x1181')](_0x200007);},_0x34e590[_0x36061f('0xe83')](_0x36061f('0xfb4'),function(_0x37ea0){const _0x2afd62=_0x36061f;_0x34e590[_0x2afd62('0xef9')](_0x37ea0);});}};}function _0x1b98ef(){return function(_0x1aa66d,_0x3054b8,_0x1e8c34,_0x1296b2){const _0x8c833c=a0_0x3f2c,_0x43f1b7=[];for(let _0x24a9c3=0x0;_0x24a9c3<_0x1aa66d[_0x8c833c('0x264b')];_0x24a9c3+=0x1){let _0x10a9fa=!![];switch(_0x3054b8){case _0x8c833c('0x21da'):_0x10a9fa=Boolean(_0x1aa66d[_0x24a9c3][_0x8c833c('0x1c21')]);break;case'chat':_0x10a9fa=Boolean(_0x1aa66d[_0x24a9c3][_0x8c833c('0x1e02')]);break;case _0x8c833c('0x1bfa'):_0x10a9fa=Boolean(_0x1aa66d[_0x24a9c3][_0x8c833c('0x56')]);break;case _0x8c833c('0x146c'):_0x10a9fa=Boolean(_0x1aa66d[_0x24a9c3][_0x8c833c('0xa74')]);break;case'whatsapp':_0x10a9fa=Boolean(_0x1aa66d[_0x24a9c3]['WhatsappAccountId']);break;case'fax':_0x10a9fa=Boolean(_0x1aa66d[_0x24a9c3][_0x8c833c('0x18fe')]);break;case _0x8c833c('0x26c'):_0x10a9fa=Boolean(_0x1aa66d[_0x24a9c3][_0x8c833c('0xb8')]);break;default:_0x10a9fa=!![];break;}_0x10a9fa&&(_0x1e8c34&&_0x1296b2&&(_0x10a9fa=_0x24273b()(_0x1aa66d[_0x24a9c3][_0x8c833c('0x262')])[_0x8c833c('0x3a6')](_0x24273b()(_0x1e8c34)[_0x8c833c('0x13f2')](0x0,!![]),_0x24273b()(_0x1296b2)[_0x8c833c('0x13f2')](0x0,!![])[_0x8c833c('0x126a')](0x17,_0x8c833c('0xf08'))['add'](0x3b,'minutes')['add'](0x3b,_0x8c833c('0x1aa6'))))),_0x10a9fa&&_0x43f1b7['push'](_0x1aa66d[_0x24a9c3]);}return _0x43f1b7;};}function _0x3943f4(){const _0x51c543=_0x36e6f4;return{'watchEmbedData':![],'sanitizeHtml':![],'fontSmiley':![],'emoji':!![],'link':!![],'linkTarget':_0x51c543('0x180c'),'pdf':{'embed':!![]},'image':{'embed':!![]},'audio':{'embed':!![]},'basicVideo':![],'gdevAuth':_0x51c543('0x1067'),'video':{'embed':![],'width':null,'height':null,'ytTheme':_0x51c543('0x1b86'),'details':![],'thumbnailQuality':'medium','autoPlay':!![]},'twitchtvEmbed':!![],'dailymotionEmbed':!![],'tedEmbed':!![],'dotsubEmbed':!![],'liveleakEmbed':!![],'ustreamEmbed':!![],'soundCloudEmbed':!![],'soundCloudOptions':{'height':0xa0,'themeColor':_0x51c543('0xfe1'),'autoPlay':![],'hideRelated':![],'showComments':!![],'showUser':!![],'showReposts':![],'visual':![],'download':![]},'spotifyEmbed':!![],'tweetEmbed':!![],'tweetOptions':{'maxWidth':0x226,'hideMedia':![],'hideThread':![],'align':_0x51c543('0x192'),'lang':'en'},'code':{'highlight':!![],'lineNumbers':![]},'codepenEmbed':!![],'codepenHeight':0x12c,'jsfiddleEmbed':!![],'jsfiddleHeight':0x12c,'jsbinEmbed':!![],'jsbinHeight':0x12c,'plunkerEmbed':!![],'githubgistEmbed':!![],'ideoneEmbed':!![],'ideoneHeight':0x12c};}const _0xdf42ab=_0x3943f4;_0x50534a['$inject']=['$cookies',_0x36e6f4('0x1566'),_0x36e6f4('0x265d'),_0x36e6f4('0x1ca5'),_0x36e6f4('0x1a32'),'message',_0x36e6f4('0x1345'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e')];function _0x50534a(_0x122b49,_0x50139b,_0x530919,_0x4a9227,_0x251f92,_0x273bcc,_0x416051,_0x43f00d,_0x5858ac){const _0x1cc176=_0x36e6f4,_0x3d6546=this,_0x5c2d66=0x19,_0x3100fa=_0x5c2d66*0x400*0x400;_0x3d6546[_0x1cc176('0x104a')]=[_0x4a9227[_0x1cc176('0x70c')][_0x1cc176('0x859')],_0x4a9227[_0x1cc176('0x70c')][_0x1cc176('0xb3f')],_0x4a9227[_0x1cc176('0x70c')][_0x1cc176('0x3b8')]],_0x3d6546['message']={'from':_0x251f92[_0x1cc176('0x1ca8')],'to':_0x2cfb05()[_0x1cc176('0x2863')](_0x273bcc['to'])||_0x2cfb05()[_0x1cc176('0x1081')](_0x273bcc['to'])?[]:_0x273bcc['to'],'attachments':[]},_0x3d6546['ngFlowOptions']={'target':_0x1cc176('0x27fe'),'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x3100fa,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x3d6546[_0x1cc176('0xe57')]={'flow':{}},_0x3d6546[_0x1cc176('0x20ba')]=_0x5578dc,_0x3d6546['upload']=_0x429193,_0x3d6546[_0x1cc176('0x1dea')]=_0xfd0639,_0x3d6546[_0x1cc176('0xd20')]=_0x448c8b,_0x3d6546[_0x1cc176('0x184e')]=_0x35abd1,_0x3d6546['contactSearch']=_0x213a35,_0x3d6546['transformContact']=_0x3dcea4,_0x3d6546[_0x1cc176('0x24a0')]=_0x9c2fae;function _0x1bf893(){const _0x19ec7d=_0x1cc176;_0x530919['hide']({'from':_0x3d6546[_0x19ec7d('0x1e70')]['from'],'to':_0x3d6546['message']['to'],'attach':_0x3d6546[_0x19ec7d('0x1e70')]['attachments']['length'],'attachments':_0x3d6546[_0x19ec7d('0x1e70')][_0x19ec7d('0x1e1d')]});}function _0x5578dc(){const _0x1bc724=_0x1cc176;_0x3d6546[_0x1bc724('0x1e70')][_0x1bc724('0x1e1d')][_0x1bc724('0x264b')]===0x1?_0x3d6546[_0x1bc724('0x1e70')]['to']['length']?(_0x273bcc[_0x1bc724('0xfca')]=undefined,_0x1bf893()):_0x5858ac[_0x1bc724('0xfc9')](_0x1bc724('0x1839')):_0x5858ac[_0x1bc724('0xfc9')]('Attachment\x20is\x20mandatory');}function _0x429193(){const _0x2d68d7=_0x1cc176;_0x3d6546[_0x2d68d7('0xe57')][_0x2d68d7('0x13d1')][_0x2d68d7('0x1ca3')]['headers']={'X-Requested-With':'XMLHttpRequest','Authorization':_0x2d68d7('0x24d4')+_0x122b49[_0x2d68d7('0xd83')]('motion.token')},_0x3d6546[_0x2d68d7('0xe57')][_0x2d68d7('0x13d1')]['upload']();}function _0x448c8b(_0x55a48e){const _0x2ec3c3=_0x1cc176,_0x31c585=[_0x2ec3c3('0x2686'),_0x2ec3c3('0x230f')];if(!_0x2cfb05()[_0x2ec3c3('0x1257')](_0x31c585,_0x55a48e[_0x2ec3c3('0x26a5')]()))return _0x5858ac[_0x2ec3c3('0xfc9')]({'title':_0x2ec3c3('0x27fb')+_0x55a48e['getExtension'](),'msg':_0x2ec3c3('0xe0')+_0x31c585['join']()}),![];if(_0x55a48e[_0x2ec3c3('0x2340')]>_0x3100fa)return _0x5858ac[_0x2ec3c3('0xfc9')]({'title':_0x2ec3c3('0x11e6'),'msg':_0x2ec3c3('0x12c0')+_0x5c2d66+'MB'}),![];return!![];}function _0xfd0639(_0x3b665b,_0x167168){const _0x27c335=_0x1cc176;try{_0x167168=JSON[_0x27c335('0x1295')](_0x167168),_0x167168[_0x27c335('0x2340')]=_0x3b665b[_0x27c335('0x2340')],_0x3d6546[_0x27c335('0x1e70')]['attachments']['push'](_0x167168);}catch(_0xd18ef9){console[_0x27c335('0xfc9')](_0xd18ef9);}}function _0x35abd1(_0x590bcd){const _0x4c55de=_0x1cc176;let _0x36f323='';return _0x590bcd[_0x4c55de('0x18cb')]&&_0x590bcd['firstName']!==_0x590bcd[_0x4c55de('0x1fc7')]&&(_0x36f323+=_0x590bcd[_0x4c55de('0x18cb')]+'\x20'),_0x590bcd[_0x4c55de('0xeb0')]&&_0x590bcd[_0x4c55de('0xeb0')]!==_0x590bcd[_0x4c55de('0x1fc7')]&&(_0x36f323+=_0x590bcd[_0x4c55de('0xeb0')]+'\x20'),_0x36f323+='<'+_0x590bcd['fax']+'>';}function _0x3dcea4(_0x4731b8){const _0x5a06da=_0x1cc176,_0x1fa5e8=_0x4731b8;if(_0x2cfb05()[_0x5a06da('0x235f')](_0x4731b8))return _0x4731b8[_0x5a06da('0x1fc7')];if(_0x3bae60(_0x1fa5e8))return _0x1fa5e8;return _0x5858ac['error'](_0x5a06da('0x10b7')+_0x1fa5e8+_0x5a06da('0x167f')),null;}function _0x3bae60(_0x5edeff){const _0x1d0c5b=_0x1cc176,_0x5de86a=/[&/\\#,()$~%.'":;*?<>{}\s\\|a-zA-Z\pS!òàùè…_§°çéì-]/;return!_0x5de86a[_0x1d0c5b('0x45d')](_0x5edeff);}function _0x213a35(_0x5bfe43){const _0xe13d3d=_0x1cc176;return _0x251f92&&_0x251f92[_0xe13d3d('0x23c')]?_0x43f00d[_0xe13d3d('0x149e')][_0xe13d3d('0xd83')]({'ListId':_0x251f92[_0xe13d3d('0x23c')],'nolimit':!![],'filter':_0x5bfe43,'fields':_0xe13d3d('0x19aa')})['$promise'][_0xe13d3d('0x1166')](function(_0x50fbfc){const _0x54035b=_0xe13d3d;return _0x50fbfc[_0x54035b('0x269a')];}):[];}function _0x9c2fae(){const _0x4f1a38=_0x1cc176;_0x273bcc['draft']=_0x3d6546[_0x4f1a38('0x1e70')],_0x530919['cancel']();}}const _0x211cbe=_0x50534a;_0x36d2b4[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x1566'),_0x36e6f4('0x265d'),_0x36e6f4('0x1ca5'),_0x36e6f4('0x586'),_0x36e6f4('0x1a32'),_0x36e6f4('0x1e70'),_0x36e6f4('0x1345'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),'$q',_0x36e6f4('0x21ef'),_0x36e6f4('0x25e6'),'draftManager'];function _0x36d2b4(_0x4f4284,_0x309129,_0x10b39c,_0x5693d1,_0x1dbd05,_0x3c4fc1,_0x2db506,_0x2fb23b,_0x50fd09,_0x4522f0,_0x225ce4,_0x21a667,_0x4b51e9,_0x454ecb){const _0x4bd9bf=_0x36e6f4,_0x4f4180=this,_0x385a8c=0x19,_0x4be76f=_0x385a8c*0x400*0x400;_0x4f4180['currentUser']=_0x21a667['getCurrentUser'](),_0x4f4180[_0x4bd9bf('0x1908')]=_0x2fb23b===_0x4bd9bf('0x2b1')?!![]:![],_0x4f4180['hiddenCC']=!![],_0x4f4180['hiddenBCC']=!![],_0x4f4180[_0x4bd9bf('0x1126')]=!![],_0x4f4180[_0x4bd9bf('0x61a')]=[],_0x4f4180[_0x4bd9bf('0x104a')]=[_0x5693d1[_0x4bd9bf('0x70c')][_0x4bd9bf('0x859')],_0x5693d1[_0x4bd9bf('0x70c')]['COMMA'],_0x5693d1[_0x4bd9bf('0x70c')][_0x4bd9bf('0x3b8')]],_0x4f4180[_0x4bd9bf('0x6dc')]=_0x500e28,_0x4f4180['selectedItemChange']=_0x2cca00,_0x4f4180['onReadyEditor']=_0x19f828,_0x2cfb05()[_0x4bd9bf('0x1af4')][_0x4bd9bf('0x1e87')]=/{{([\s\S]+?)}}/g,_0x4f4180[_0x4bd9bf('0x24bb')]=_0x2cfb05()['template'](_0x4bd9bf('0x4fd')),_0x4f4180['replyTemplate']=_0x2cfb05()[_0x4bd9bf('0x243')]('On\x20{{\x20date\x20}},\x20at\x20{{\x20time\x20}},\x20{{\x20from\x20}}\x20wrote:'),_0x4f4180[_0x4bd9bf('0x1dc4')]=_0x2cfb05()[_0x4bd9bf('0x243')](_0x4bd9bf('0x1b9d')),_0x4f4180['message']={'from':_0x4f4180[_0x4bd9bf('0x24bb')]({'name':_0x3c4fc1[_0x4bd9bf('0x4f0')],'email':_0x3c4fc1[_0x4bd9bf('0x66f')]||_0x3c4fc1[_0x4bd9bf('0x1c57')][_0x4bd9bf('0x557')]}),'to':[],'cc':[],'bcc':[],'body':_0x598be7(),'type':_0x2fb23b,'attachments':[],'showLastMessage':!![]},_0x4f4180[_0x4bd9bf('0xfca')]=null,_0x4f4180[_0x4bd9bf('0x8e9')]={'skin':'office2013','startupFocus':!![],'language':'en','allowedContent':!![],'extraPlugins':_0x4bd9bf('0x104'),'toolbarGroups':[{'name':_0x4bd9bf('0x471'),'groups':[_0x4bd9bf('0x471')]},{'name':'clipboard','groups':[_0x4bd9bf('0x190')]},{'name':_0x4bd9bf('0x245b'),'groups':[_0x4bd9bf('0x245b')]},{'name':'basicstyles','groups':[_0x4bd9bf('0x180f')]},{'name':_0x4bd9bf('0x1781'),'groups':['list','indent',_0x4bd9bf('0x16e5')]}],'autoGrow_onStartup':!![],'autoGrow_minHeight':_0x4f4180[_0x4bd9bf('0x1908')]?0xa0:0x12c,'autoGrow_maxHeight':_0x309129[_0x4bd9bf('0xd1e')]-0x190,'autocorrect_enabled':!![],'disableNativeSpellChecker':![],'enterMode':window[_0x4bd9bf('0x14cf')][_0x4bd9bf('0x1630')],'font_defaultLabel':_0x3c4fc1[_0x4bd9bf('0x14e5')]?_0x3c4fc1[_0x4bd9bf('0x14e5')]['split'](',')[0x0]:_0x4bd9bf('0x123b'),'fontSize_defaultLabel':_0x3c4fc1['fontSize']||'12','removePlugins':'magicline'};const _0x4d2121=[];for(let _0x464c4c=0x8;_0x464c4c<=0x48;_0x464c4c++){_0x4d2121[_0x4bd9bf('0x1514')](_0x464c4c+'/'+_0x464c4c+'pt');}_0x4f4180[_0x4bd9bf('0x8e9')]['fontSize_sizes']=_0x4d2121[_0x4bd9bf('0x45a')](';'),_0x4f4180[_0x4bd9bf('0xd67')]={'target':_0x4bd9bf('0x27fe'),'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x4be76f,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x4f4180[_0x4bd9bf('0xe57')]={'flow':{}},_0x4f4180[_0x4bd9bf('0x1fdc')]=_0xd000,_0x4f4180[_0x4bd9bf('0x63d')]=_0x448bc1,_0x4f4180[_0x4bd9bf('0x1417')]=_0x4bcb3e,_0x4f4180[_0x4bd9bf('0xdad')]=_0x28b729,_0x4f4180['send']=_0x4cdb69,_0x4f4180[_0x4bd9bf('0x2b1')]=_0x38813e,_0x4f4180[_0x4bd9bf('0x19e1')]=_0x487964,_0x4f4180['upload']=_0x4226f5,_0x4f4180[_0x4bd9bf('0x1dea')]=_0x5303fb,_0x4f4180[_0x4bd9bf('0xcd9')]=_0x3f6260,_0x4f4180['fileAdded']=_0x9d4e62,_0x4f4180[_0x4bd9bf('0x184e')]=_0x7f7441,_0x4f4180[_0x4bd9bf('0x154a')]=_0x2abecb,_0x4f4180['transformContact']=_0x101468,_0x4f4180[_0x4bd9bf('0x786')]=_0x488f1d,_0x4f4180[_0x4bd9bf('0x24a0')]=_0x54ddf3,_0x4f4180[_0x4bd9bf('0x20f5')]=_0x24248f;switch(_0x2fb23b){case _0x4bd9bf('0x1fdc'):_0x4f4180[_0x4bd9bf('0x1fdc')](![]);break;case _0x4bd9bf('0x265b'):_0x4f4180[_0x4bd9bf('0x1fdc')](!![]);break;case _0x4bd9bf('0x1417'):_0x4f4180[_0x4bd9bf('0x1417')]();break;case _0x4bd9bf('0xfca'):_0x4f4180[_0x4bd9bf('0xdad')]();break;case _0x4bd9bf('0xd11'):_0x4f4180[_0x4bd9bf('0x63d')]();break;case _0x4bd9bf('0x2b1'):_0x4f4180[_0x4bd9bf('0x2b1')]();break;}_0x50fd09[_0x4bd9bf('0x1c44')][_0x4bd9bf('0xd83')]({'nolimit':!![]})['$promise'][_0x4bd9bf('0x1166')](function(_0x1e1275){_0x4f4180['subStatuses']=_0x1e1275||{'count':0x0,'rows':[]};})[_0x4bd9bf('0x1a80')](function(_0x207a6a){const _0x11f06f=_0x4bd9bf;console[_0x11f06f('0xfc9')](_0x207a6a);});!_0x4f4180[_0x4bd9bf('0x1908')]&&_0x1b5b87();function _0xd000(_0x3d95ab){const _0x573116=_0x4bd9bf;angular[_0x573116('0x1e3f')](_0x2db506)&&(_0x4f4180[_0x573116('0x1e70')][_0x573116('0x1345')]=_0x573116('0x1fdc'),_0x4f4180['message']['to']=_0x2db506[_0x573116('0x2788')]==='in'?_0x2db506[_0x573116('0x661')][_0x573116('0x25c8')](','):_0x2db506['to']['split'](','),_0x4f4180['message'][_0x573116('0x210d')]=_0x2cfb05()[_0x573116('0x1783')](_0x2db506[_0x573116('0x210d')],_0x573116('0x2309'))?_0x2db506[_0x573116('0x210d')]:_0x573116('0x28c')+_0x2db506[_0x573116('0x210d')],_0x4f4180['message'][_0x573116('0x1472')]=_0x2db506['messageId'],_0x4f4180[_0x573116('0x1e70')][_0x573116('0x8d2')]=_0x598be7(),_0x4f4180[_0x573116('0x1e70')][_0x573116('0x1e1d')]=[],_0x3d95ab&&_0x2db506['cc']&&(_0x4f4180['hiddenCC']=![],_0x4f4180[_0x573116('0x1e70')]['cc']=_0x2db506['cc'][_0x573116('0x25c8')](',')),_0x4f4180[_0x573116('0x1e70')][_0x573116('0x4c1')]=![]);}function _0x448bc1(){const _0x1011f1=_0x4bd9bf;angular['isDefined'](_0x2db506)&&(_0x4f4180['message']['type']=_0x1011f1('0xd11'),_0x4f4180[_0x1011f1('0x1e70')]['to']=_0x2db506['to']?_0x2db506['to'][_0x1011f1('0x25c8')](','):[]);}function _0x28b729(){const _0xd8424f=_0x4bd9bf;_0x4f4180[_0xd8424f('0x2471')]=!![],angular[_0xd8424f('0x1e3f')](_0x2db506)&&(_0x2db506[_0xd8424f('0x34f')]=![],_0x4f4180[_0xd8424f('0x1e70')]=angular[_0xd8424f('0x225f')](_0x2db506),!_0x2cfb05()['isEmpty'](_0x4f4180[_0xd8424f('0x1e70')]['cc'])&&(_0x4f4180[_0xd8424f('0x51e')]=![]),!_0x2cfb05()[_0xd8424f('0x1081')](_0x4f4180[_0xd8424f('0x1e70')][_0xd8424f('0x209')])&&(_0x4f4180[_0xd8424f('0x8c9')]=![]));}function _0x4bcb3e(){const _0x38f45c=_0x4bd9bf;if(angular[_0x38f45c('0x1e3f')](_0x2db506)){_0x4f4180[_0x38f45c('0x1e70')][_0x38f45c('0x1345')]=_0x38f45c('0x1417'),_0x4f4180['message'][_0x38f45c('0x210d')]=_0x2cfb05()[_0x38f45c('0x1783')](_0x2db506[_0x38f45c('0x210d')],'Fwd:')?_0x2db506[_0x38f45c('0x210d')]:_0x38f45c('0x2789')+_0x2db506[_0x38f45c('0x210d')],_0x4f4180[_0x38f45c('0x1e70')][_0x38f45c('0x8d2')]=_0x598be7();if(_0x2db506[_0x38f45c('0x35b')]&&_0x2db506[_0x38f45c('0x35b')][_0x38f45c('0x264b')])for(let _0x9b7788=0x0;_0x9b7788<_0x2db506['Attachments'][_0x38f45c('0x264b')];_0x9b7788++){_0x4f4180[_0x38f45c('0x1e70')][_0x38f45c('0x1e1d')][_0x38f45c('0x1514')](_0x2db506['Attachments'][_0x9b7788]);}_0x4f4180[_0x38f45c('0x1e70')][_0x38f45c('0x4c1')]=![];}}function _0x38813e(){const _0x54d002=_0x4bd9bf;_0x4f4180[_0x54d002('0x1345')]='note',_0x4f4180['secret']=!![],_0x4f4180[_0x54d002('0x1e70')]['body']=_0x54d002('0x221a')+_0x3c4fc1[_0x54d002('0x14e5')]+_0x54d002('0x2275')+_0x3c4fc1[_0x54d002('0x183d')]+'pt\x22>

';}function _0x57491c(_0x27da62,_0x2acccb){const _0x4ffe35=_0x4bd9bf,_0x14256b={'from':_0x4f4180['message']['from'],'to':_0x4f4180['message']['to'][_0x4ffe35('0x45a')](','),'cc':_0x4f4180[_0x4ffe35('0x1e70')]['cc'][_0x4ffe35('0x45a')](','),'bcc':_0x4f4180[_0x4ffe35('0x1e70')][_0x4ffe35('0x209')][_0x4ffe35('0x45a')](','),'subject':_0x4f4180[_0x4ffe35('0x1e70')]['subject'],'body':_0x4f4180[_0x4ffe35('0x1e70')][_0x4ffe35('0x4c1')]?_0x4f4180[_0x4ffe35('0x1e70')][_0x4ffe35('0x8d2')]:_0x4f4180[_0x4ffe35('0x1e70')]['body']+_0x2ed59d(_0x4f4180[_0x4ffe35('0x1e70')]['type']),'inReplyTo':_0x4f4180[_0x4ffe35('0x1e70')][_0x4ffe35('0x1472')],'attach':_0x4f4180[_0x4ffe35('0x1e70')][_0x4ffe35('0x1e1d')][_0x4ffe35('0x264b')],'attachments':_0x4f4180[_0x4ffe35('0x1e70')]['attachments'],'Interaction':{'lastMsgDirection':'out','lastMsgBody':_0x4f4180[_0x4ffe35('0x1e70')][_0x4ffe35('0x8d2')],'substatus':_0x2acccb},'isDraft':_0x4f4180['isDraft']};_0x14256b[_0x4ffe35('0x1fe3')]=_0x4ffe35('0x9aa')+_0x2cfb05()[_0x4ffe35('0xf3')](_0x14256b[_0x4ffe35('0x8d2')],_0x4ffe35('0x5df'),_0x4ffe35('0x8b3'))+'',_0x27da62&&(_0x14256b['Interaction'][_0x4ffe35('0xa5b')]=!![]),_0x10b39c[_0x4ffe35('0x1197')](_0x14256b);}function _0x4cdb69(_0x2b4cf4,_0x1afba9,_0x708f39){const _0x271f39=_0x4bd9bf;if(_0x4f4180[_0x271f39('0x1e70')]['to']&&_0x4f4180['message'][_0x271f39('0x8d2')]){if(_0x4f4180[_0x271f39('0x1e70')]['to'][_0x271f39('0x264b')]){if(_0x2cfb05()[_0x271f39('0x1081')](_0x4f4180[_0x271f39('0x1e70')][_0x271f39('0x210d')])){const _0xbe3619=_0x10b39c[_0x271f39('0x1d26')]({'skipHide':!![]})[_0x271f39('0xcdc')](_0x271f39('0x9f8'))['textContent'](_0x271f39('0xb24'))[_0x271f39('0x8e8')](_0x271f39('0x9f8'))[_0x271f39('0x203b')](_0x2b4cf4)['ok'](_0x271f39('0x2372'))[_0x271f39('0x3f')]('Cancel');_0x10b39c['show'](_0xbe3619)['then'](function(){_0x57491c(_0x1afba9,_0x708f39);});}else _0x57491c(_0x1afba9,_0x708f39);}else _0x4522f0[_0x271f39('0xfc9')](_0x271f39('0x1839'));}}function _0x487964(){const _0x28bf1f=_0x4bd9bf;_0x4f4180[_0x28bf1f('0x1e70')][_0x28bf1f('0x8d2')]&&_0x10b39c['hide']({'secret':!![],'body':_0x4f4180[_0x28bf1f('0x1e70')][_0x28bf1f('0x8d2')],'attach':_0x4f4180['message'][_0x28bf1f('0x1e1d')][_0x28bf1f('0x264b')],'attachments':_0x4f4180[_0x28bf1f('0x1e70')][_0x28bf1f('0x1e1d')]});}function _0x2cca00(_0x130af9){const _0x177733=_0x4bd9bf;if(_0x130af9&&_0x130af9[_0x177733('0x18e0')]&&_0x4f4180[_0x177733('0x295')])try{const _0x389128=_0x2cfb05()[_0x177733('0x243')](_0x130af9[_0x177733('0x18e0')]),_0x2e99f6={'user':_0x4f4180[_0x177733('0x98')],'account':_0x3c4fc1,'interaction':_0x4b51e9,'contact':_0x4b51e9&&_0x4b51e9[_0x177733('0x21a4')]?_0x4b51e9[_0x177733('0x21a4')]:{}};_0x4f4180[_0x177733('0x295')][_0x177733('0x2439')](_0x389128(_0x2e99f6));}catch(_0x474868){console[_0x177733('0xfc9')](_0x474868),_0x4f4180['ckEditorInstance'][_0x177733('0x2439')](_0x130af9['value']);}document[_0x177733('0xc47')](_0x177733('0x28e2'))[_0x177733('0x22')](),_0x4f4180[_0x177733('0x1511')]=null;}function _0x500e28(_0x327af7){const _0x3d2bd9=_0x4bd9bf,_0x56821a=_0x225ce4[_0x3d2bd9('0x24d8')]();let _0x26e35c=[];return _0x50fd09['cannedAnswer']['get']({'filter':_0x327af7,'MailAccountId':_0x3c4fc1['id']})['$promise']['then'](function(_0x54934b){const _0x4dc5b8=_0x3d2bd9;return _0x26e35c=_0x2cfb05()['concat'](_0x26e35c,_0x54934b[_0x4dc5b8('0x269a')]),_0x50fd09[_0x4dc5b8('0x1b1f')][_0x4dc5b8('0xd83')]({'filter':_0x327af7})['$promise'];})['then'](function(_0x5f2f0b){const _0x1bba38=_0x3d2bd9;_0x26e35c=_0x2cfb05()[_0x1bba38('0x1c6a')](_0x26e35c,_0x2cfb05()[_0x1bba38('0x1c33')](_0x5f2f0b[_0x1bba38('0x269a')],function(_0x291bfb){const _0x29cacf=_0x1bba38;return!_0x291bfb[_0x29cacf('0x56')]&&!_0x291bfb[_0x29cacf('0x18fe')]&&!_0x291bfb[_0x29cacf('0xa74')]&&!_0x291bfb['WhatsappAccountId']&&!_0x291bfb[_0x29cacf('0xb8')]&&!_0x291bfb[_0x29cacf('0x1e02')];})),_0x56821a['resolve'](_0x26e35c);})['catch'](function(_0xe30436){const _0x442ddf=_0x3d2bd9;_0x56821a[_0x442ddf('0x21bf')](_0xe30436);}),_0x56821a[_0x3d2bd9('0x1f48')];}function _0x19f828(){const _0x5c9008=_0x4bd9bf;try{_0x4f4180['ckEditorInstance']=window[_0x5c9008('0x14cf')][_0x5c9008('0x214a')][_0x5c9008('0x28e2')];}catch(_0x334dd0){console[_0x5c9008('0xfc9')](_0x5c9008('0x2358'),_0x334dd0);}}function _0x1b5b87(){const _0x4ff6eb=_0x4bd9bf;return _0x50fd09['mailAccount'][_0x4ff6eb('0x1126')]({'id':_0x3c4fc1['id']})[_0x4ff6eb('0xa44')]['catch'](function(_0x2636f){const _0x5302d5=_0x4ff6eb;_0x4f4180[_0x5302d5('0x1126')]=![],_0x4f4180['errors'][_0x5302d5('0x1514')]({'message':_0x2636f[_0x5302d5('0x25f4')],'type':_0x2636f[_0x5302d5('0x52d')]}),_0x4f4180[_0x5302d5('0x61a')]['push']({'message':_0x5302d5('0x26e7'),'type':_0x5302d5('0x27f8')});});}function _0x9d4e62(_0x367e15){const _0x37d36e=_0x4bd9bf;if(_0x367e15[_0x37d36e('0x2340')]>_0x4be76f)return _0x4522f0['error']({'title':_0x37d36e('0x11e6'),'msg':'The\x20max\x20allowed\x20size\x20is\x20'+_0x385a8c+'MB'}),![];return!![];}function _0x4226f5(){const _0x5667a0=_0x4bd9bf;_0x4f4180['ngFlow']['flow']['opts'][_0x5667a0('0x5fb')]={'X-Requested-With':_0x5667a0('0x1bc1'),'Authorization':_0x5667a0('0x24d4')+_0x4f4284[_0x5667a0('0xd83')](_0x5667a0('0x10b6'))},_0x4f4180[_0x5667a0('0xe57')][_0x5667a0('0x13d1')]['upload']();}function _0x5303fb(_0xd523c3,_0x3953f9){const _0x36afbd=_0x4bd9bf;try{_0x3953f9=JSON[_0x36afbd('0x1295')](_0x3953f9),_0x3953f9[_0x36afbd('0x2340')]=_0xd523c3[_0x36afbd('0x2340')],_0x4f4180[_0x36afbd('0x1e70')][_0x36afbd('0x1e1d')][_0x36afbd('0x1514')](_0x3953f9);}catch(_0x255d7d){console[_0x36afbd('0xfc9')](_0x255d7d);}}function _0x3f6260(_0x18a600){const _0x339b47=_0x4bd9bf;_0x4f4180[_0x339b47('0x1e70')][_0x339b47('0x1e1d')]=_0x2cfb05()[_0x339b47('0x21bf')](_0x4f4180[_0x339b47('0x1e70')]['attachments'],{'id':_0x18a600['id']}),!_0x18a600[_0x339b47('0x115c')]&&_0x50fd09[_0x339b47('0x21bc')][_0x339b47('0x906')]({'id':_0x18a600['id']})['$promise'][_0x339b47('0x1a80')](function(_0x4e7eab){const _0x46777e=_0x339b47;_0x4522f0['error']({'title':_0x4e7eab[_0x46777e('0x52d')]?'API:'+_0x4e7eab[_0x46777e('0x52d')]+_0x46777e('0x11e1')+_0x4e7eab[_0x46777e('0xe1b')]:'api.attachment.delete','msg':_0x4e7eab['data']?JSON[_0x46777e('0xbac')](_0x4e7eab[_0x46777e('0x25f4')][_0x46777e('0x1e70')]):_0x4e7eab[_0x46777e('0x1586')]()});});}function _0x7f7441(_0x5c62e0){const _0x5d6869=_0x4bd9bf;let _0x537c20='';return _0x5c62e0[_0x5d6869('0x18cb')]&&_0x5c62e0['firstName']!==_0x5c62e0[_0x5d6869('0x66f')]&&(_0x537c20+=_0x5c62e0[_0x5d6869('0x18cb')]+'\x20'),_0x5c62e0[_0x5d6869('0xeb0')]&&_0x5c62e0[_0x5d6869('0xeb0')]!==_0x5c62e0[_0x5d6869('0x66f')]&&(_0x537c20+=_0x5c62e0['lastName']+'\x20'),_0x537c20+='<'+_0x5c62e0[_0x5d6869('0x66f')]+'>';}function _0x101468(_0x4881a9,_0x44c80b){const _0x33e4eb=_0x4bd9bf;if(_0x2cfb05()[_0x33e4eb('0x235f')](_0x4881a9))return _0x4f4180[_0x33e4eb('0x26db')]=_0x4881a9,_0x4881a9[_0x33e4eb('0x66f')];if(_0x2cfb05()['isString'](_0x4881a9)){if(_0x2aa770(_0x4881a9))return _0x4f4180[_0x33e4eb('0x26db')]={'email':_0x4881a9},_0x4881a9;else{const _0x4a8581=_0x4881a9[_0x33e4eb('0x25c8')](',');for(let _0xa871ae=0x0;_0xa871ae<_0x4a8581[_0x33e4eb('0x264b')];_0xa871ae+=0x1){_0x2aa770(_0x4a8581[_0xa871ae])?_0x2cfb05()[_0x33e4eb('0xd06')](_0x44c80b)&&_0x2cfb05()['indexOf'](_0x44c80b,_0x4a8581[_0xa871ae])<0x0&&_0x44c80b[_0x33e4eb('0x1514')](_0x4a8581[_0xa871ae]):_0x4522f0[_0x33e4eb('0xfc9')](_0x33e4eb('0xc86')+_0x4a8581[_0xa871ae]+'\x20is\x20not\x20valid');}return _0x4f4180[_0x33e4eb('0x26db')]={'email':_0x4881a9[_0x33e4eb('0x25c8')](',')[0x0]},null;}}return _0x4522f0[_0x33e4eb('0xfc9')]('Email\x20field\x20is\x20not\x20valid'),null;}function _0x2abecb(_0x2048d6){const _0x36f9c3=_0x4bd9bf;return _0x3c4fc1&&_0x3c4fc1[_0x36f9c3('0x23c')]?_0x50fd09[_0x36f9c3('0x149e')][_0x36f9c3('0xd83')]({'ListId':_0x3c4fc1[_0x36f9c3('0x23c')],'nolimit':!![],'filter':_0x2048d6,'fields':_0x36f9c3('0x242f')})[_0x36f9c3('0xa44')][_0x36f9c3('0x1166')](function(_0x45c5e1){const _0x4755da=_0x36f9c3;return _0x45c5e1[_0x4755da('0x269a')];}):[];}function _0x488f1d(){const _0x7557cb=_0x4bd9bf;_0x4f4180[_0x7557cb('0x1e70')][_0x7557cb('0x34f')]=!![],_0x4f4180[_0x7557cb('0xfca')]=_0x454ecb[_0x7557cb('0xec7')](_0x4b51e9['id']);const _0x40975f={'account':_0x3c4fc1,'message':_0x4f4180[_0x7557cb('0x1e70')],'contact':_0x4f4180['contact'],'interaction':_0x4b51e9};if(_0x4f4180[_0x7557cb('0xfca')]&&!_0x4f4180[_0x7557cb('0x2471')]){const _0x3fee38=_0x10b39c[_0x7557cb('0x1d26')]({'skipHide':!![]})[_0x7557cb('0xcdc')](_0x1dbd05[_0x7557cb('0x25cc')]('DASHBOARDS.DRAFT_SAVE_WARNING_TITLE'))[_0x7557cb('0xacc')](_0x1dbd05[_0x7557cb('0x25cc')](_0x7557cb('0x1cad')))['ariaLabel'](_0x7557cb('0x4c3'))['ok'](_0x1dbd05[_0x7557cb('0x25cc')]('DASHBOARDS.OVERWRITE'))['cancel'](_0x1dbd05[_0x7557cb('0x25cc')](_0x7557cb('0x8c2')));_0x10b39c[_0x7557cb('0x1f80')](_0x3fee38)[_0x7557cb('0x1166')](function(){const _0x2691d9=_0x7557cb;_0x10b39c[_0x2691d9('0x1197')](_0x40975f);});}else _0x10b39c['hide'](_0x40975f);}function _0x54ddf3(){_0x10b39c['cancel']();}function _0x2aa770(_0xfb09cf){const _0x538c41=/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;return _0x538c41['test'](_0xfb09cf);}function _0x15c0fe(_0xfc69c1){const _0x890573=/]*>([^]*)<\/body/m,_0x1711cc=_0xfc69c1['match'](_0x890573);if(_0x1711cc)return _0x1711cc[0x1];return _0xfc69c1;}function _0x51894e(){const _0x1037a4=_0x4bd9bf;if(_0x2cfb05()[_0x1037a4('0x2863')](_0x3c4fc1[_0x1037a4('0x243')]))return'';try{const _0x120344=_0x2cfb05()[_0x1037a4('0x243')](_0x3c4fc1[_0x1037a4('0x243')]),_0xb801bc={'user':_0x4f4180[_0x1037a4('0x98')],'account':_0x3c4fc1,'interaction':_0x4b51e9,'contact':_0x4b51e9&&_0x4b51e9['Contact']?_0x4b51e9[_0x1037a4('0x21a4')]:{}};return _0x120344(_0xb801bc);}catch(_0x2caaff){return console[_0x1037a4('0xfc9')](_0x2caaff),'';}}function _0x598be7(){const _0x3451c8=_0x4bd9bf;return'';}function _0x2ed59d(_0x58e678){const _0x5bd53f=_0x4bd9bf;let _0x54d07d=_0x5bd53f('0x510');switch(_0x58e678){case'reply':case _0x5bd53f('0x265b'):_0x54d07d+=_0x4f4180[_0x5bd53f('0x10b0')]({'date':_0x24273b()(_0x2db506[_0x5bd53f('0x262')])['format'](_0x5bd53f('0x1a34'))||'','time':_0x24273b()(_0x2db506['createdAt'])['format'](_0x5bd53f('0x307'))||'','from':_0x2cfb05()[_0x5bd53f('0x24c')](_0x2db506[_0x5bd53f('0x661')])||''});break;case _0x5bd53f('0x1417'):_0x54d07d+=_0x4f4180[_0x5bd53f('0x1dc4')]({'date':_0x24273b()(_0x2db506[_0x5bd53f('0x262')])[_0x5bd53f('0x128a')](_0x5bd53f('0x1a34'))||'','time':_0x24273b()(_0x2db506['createdAt'])['format'](_0x5bd53f('0x307'))||'','from':_0x2cfb05()[_0x5bd53f('0x24c')](_0x2db506['from'])||'','to':_0x2cfb05()[_0x5bd53f('0x24c')](_0x2db506['to'])||'','subject':_0x2cfb05()[_0x5bd53f('0x24c')](_0x2db506[_0x5bd53f('0x210d')])||''});break;}const _0x2ad5fa=_0x4f4180['message'][_0x5bd53f('0x4c1')]&&_0x2db506[_0x5bd53f('0x1560')]?_0x2db506['originalMessage'][_0x5bd53f('0x8d2')]:_0x2db506['body'];return _0x54d07d+=_0x5bd53f('0x925'),_0x54d07d+=_0x15c0fe(_0x2ad5fa?_0x2cfb05()[_0x5bd53f('0xf3')](_0x2ad5fa,_0x5bd53f('0x5df'),_0x5bd53f('0x8b3')):''),_0x54d07d+='',_0x58e678?_0x54d07d:'';}function _0x24248f(){const _0x40053c=_0x4bd9bf;_0x4f4180[_0x40053c('0x1e70')][_0x40053c('0x8d2')]+=_0x2ed59d(_0x4f4180['message'][_0x40053c('0x1345')]);}}const _0x5a0f7b=_0x36d2b4;_0x18f1c8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x8da'),'$window',_0x36e6f4('0x265d'),'$mdConstant',_0x36e6f4('0x1a32'),'message',_0x36e6f4('0x1345'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x21ef')];function _0x18f1c8(_0x374a50,_0x2ea4c0,_0x1da336,_0x40f4a9,_0x7e9910,_0x397fbd,_0x4680a5,_0x2b5b39,_0x338bcc,_0x16cf94,_0x43287b,_0x154e1a,_0x3d8d87){const _0x1ef919=_0x36e6f4,_0x32a5f6=this;_0x32a5f6[_0x1ef919('0x98')]=_0x3d8d87[_0x1ef919('0x26cd')](),_0x32a5f6['errors']=[],_0x32a5f6['separatorKeys']=[_0x7e9910[_0x1ef919('0x70c')][_0x1ef919('0x859')],_0x7e9910[_0x1ef919('0x70c')][_0x1ef919('0xb3f')],_0x7e9910[_0x1ef919('0x70c')]['TAB']],_0x32a5f6[_0x1ef919('0x6dc')]=_0x52032a,_0x32a5f6['selectedItemChange']=_0x5f2bd8,_0x32a5f6[_0x1ef919('0x2b1')]=_0x7e13b2,_0x32a5f6[_0x1ef919('0x19e1')]=_0x35369c,_0x32a5f6['ctrlMethods']={},_0x32a5f6[_0x1ef919('0x1e70')]={'from':_0x397fbd['phone'],'to':_0x2cfb05()[_0x1ef919('0x2863')](_0x4680a5['to'])||_0x2cfb05()[_0x1ef919('0x1081')](_0x4680a5['to'])?[]:_0x4680a5['to'],'body':''},_0x32a5f6[_0x1ef919('0x20ba')]=_0x475073,_0x32a5f6[_0x1ef919('0x184e')]=_0x1f09dd,_0x32a5f6[_0x1ef919('0x24a0')]=_0x35e1fb,_0x32a5f6[_0x1ef919('0x154a')]=_0x5cc50c,_0x32a5f6[_0x1ef919('0x364')]=_0x1db471;switch(_0x2b5b39){case _0x1ef919('0x2b1'):_0x32a5f6[_0x1ef919('0x2b1')]();break;}function _0x478deb(_0x4282aa){const _0x315d39=_0x1ef919;_0x40f4a9[_0x315d39('0x1197')]({'to':_0x32a5f6[_0x315d39('0x1e70')]['to'][_0x315d39('0x45a')](','),'body':_0x4282aa});}function _0x475073(){const _0x2c7ce9=_0x1ef919;_0x32a5f6[_0x2c7ce9('0x1e70')]['to']&&_0x32a5f6['message'][_0x2c7ce9('0x8d2')]&&(_0x32a5f6[_0x2c7ce9('0x1e70')]['to'][_0x2c7ce9('0x264b')]?_0x478deb(_0x32a5f6[_0x2c7ce9('0x1e70')]['body']):_0x16cf94[_0x2c7ce9('0xfc9')](_0x2c7ce9('0x1839')));}function _0x5f2bd8(_0x19c90a){const _0xb42112=_0x1ef919;if(_0x19c90a){try{_0x2cfb05()[_0xb42112('0x1af4')][_0xb42112('0x1e87')]=/{{([\s\S]+?)}}/g;const _0xd1d78e=_0x2cfb05()[_0xb42112('0x243')](_0x19c90a[_0xb42112('0x18e0')]),_0x23e4f1={'user':_0x32a5f6[_0xb42112('0x98')],'account':_0x397fbd};_0x32a5f6['message']['body']+='\x20'+_0xd1d78e(_0x23e4f1),_0x32a5f6[_0xb42112('0x1b47')]['setText'](_0x32a5f6[_0xb42112('0x1e70')][_0xb42112('0x8d2')]);}catch(_0x641042){_0x32a5f6['message'][_0xb42112('0x8d2')]+='\x20'+_0x19c90a[_0xb42112('0x18e0')],_0x32a5f6[_0xb42112('0x1b47')][_0xb42112('0xe96')](_0x32a5f6[_0xb42112('0x1e70')]['body']);}_0x32a5f6[_0xb42112('0x1511')]=null;}}function _0x52032a(_0x38ca2c){const _0x4b8a7c=_0x1ef919,_0x46087e=_0x43287b[_0x4b8a7c('0x24d8')]();let _0x2d32ac=[];return _0x338bcc[_0x4b8a7c('0x1b1f')]['get']({'filter':_0x38ca2c,'OpenchannelAccountId':_0x397fbd['id']})['$promise'][_0x4b8a7c('0x1166')](function(_0x252abe){const _0x5842be=_0x4b8a7c;return _0x2d32ac=_0x2cfb05()[_0x5842be('0x1c6a')](_0x2d32ac,_0x252abe[_0x5842be('0x269a')]),_0x338bcc[_0x5842be('0x1b1f')]['get']({'filter':_0x38ca2c})['$promise'];})['then'](function(_0x434865){const _0x2d3d0e=_0x4b8a7c;_0x2d32ac=_0x2cfb05()[_0x2d3d0e('0x1c6a')](_0x2d32ac,_0x2cfb05()[_0x2d3d0e('0x1c33')](_0x434865['rows'],function(_0x3af6cb){const _0xf3b20c=_0x2d3d0e;return!_0x3af6cb[_0xf3b20c('0x56')]&&!_0x3af6cb[_0xf3b20c('0x18fe')]&&!_0x3af6cb['SmsAccountId']&&!_0x3af6cb[_0xf3b20c('0x1b88')]&&!_0x3af6cb[_0xf3b20c('0xb8')]&&!_0x3af6cb[_0xf3b20c('0x1e02')];})),_0x46087e[_0x2d3d0e('0x18af')](_0x2d32ac);})[_0x4b8a7c('0x1a80')](function(_0x2729b3){const _0x52e938=_0x4b8a7c;_0x46087e[_0x52e938('0x21bf')](_0x2729b3);}),_0x46087e[_0x4b8a7c('0x1f48')];}function _0x1f09dd(_0x12307f){const _0x5bb3d3=_0x1ef919;let _0x596c50='';return _0x12307f[_0x5bb3d3('0x18cb')]&&_0x12307f[_0x5bb3d3('0x18cb')]!==_0x12307f[_0x397fbd[_0x5bb3d3('0xb28')]]&&(_0x596c50+=_0x12307f[_0x5bb3d3('0x18cb')]+'\x20'),_0x12307f[_0x5bb3d3('0xeb0')]&&_0x12307f[_0x5bb3d3('0xeb0')]!==_0x12307f[_0x397fbd[_0x5bb3d3('0xb28')]]&&(_0x596c50+=_0x12307f[_0x5bb3d3('0xeb0')]+'\x20'),_0x596c50+='<'+_0x12307f[_0x397fbd[_0x5bb3d3('0xb28')]]+'>';}function _0x1db471(_0x5df025){const _0x435716=_0x1ef919,_0x1493ed=_0x5df025;if(_0x2cfb05()[_0x435716('0x235f')](_0x1493ed))return _0x5df025[_0x397fbd[_0x435716('0xb28')]];return _0x1493ed;}function _0x5cc50c(_0x3ec271){const _0x48e56c=_0x1ef919;if(_0x397fbd&&_0x397fbd[_0x48e56c('0x23c')]){let _0x4b6309=_0x48e56c('0x199d');return _0x397fbd[_0x48e56c('0xb28')]&&(_0x4b6309+=','+_0x397fbd[_0x48e56c('0xb28')]),_0x338bcc[_0x48e56c('0x149e')][_0x48e56c('0xd83')]({'ListId':_0x397fbd[_0x48e56c('0x23c')],'nolimit':!![],'filter':_0x3ec271,'fields':_0x4b6309})[_0x48e56c('0xa44')][_0x48e56c('0x1166')](function(_0x13f019){const _0x5cee5a=_0x48e56c;return _0x13f019[_0x5cee5a('0x269a')];});}return[];}function _0x35e1fb(){_0x40f4a9['cancel']();}function _0x7e13b2(){const _0x2d97a5=_0x1ef919;_0x32a5f6[_0x2d97a5('0x1908')]=!![];}function _0x35369c(){const _0x50c644=_0x1ef919;_0x32a5f6[_0x50c644('0x1e70')][_0x50c644('0x8d2')]&&_0x40f4a9[_0x50c644('0x1197')]({'secret':!![],'body':_0x32a5f6[_0x50c644('0x1e70')][_0x50c644('0x8d2')]});}}const _0x4068f3=_0x18f1c8;_0x4d9c08[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),'$timeout',_0x36e6f4('0x1566'),_0x36e6f4('0x265d'),_0x36e6f4('0x1ca5'),_0x36e6f4('0x1a32'),_0x36e6f4('0x1e70'),_0x36e6f4('0x1345'),'api',_0x36e6f4('0x1d2e'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x21ef')];function _0x4d9c08(_0x5a2176,_0x20855f,_0x15d4d2,_0xb1082e,_0x465a4a,_0x25e987,_0xd322bf,_0x36bc56,_0x28bc08,_0x46428b,_0x3dcaa9,_0x11fe2d,_0x15a44d){const _0x36c449=_0x36e6f4,_0x1e9654=this;_0x1e9654[_0x36c449('0x98')]=_0x15a44d[_0x36c449('0x26cd')](),_0x1e9654[_0x36c449('0x61a')]=[],_0x1e9654[_0x36c449('0x104a')]=[_0x465a4a[_0x36c449('0x70c')][_0x36c449('0x859')],_0x465a4a['KEY_CODE']['COMMA'],_0x465a4a[_0x36c449('0x70c')][_0x36c449('0x3b8')]],_0x1e9654['searchTextChange']=_0x2941cf,_0x1e9654[_0x36c449('0x138d')]=_0x237562,_0x1e9654[_0x36c449('0x2b1')]=_0xab84c3,_0x1e9654['addNote']=_0x26a139,_0x1e9654[_0x36c449('0x1b47')]={},_0x1e9654[_0x36c449('0x1e70')]={'from':_0x25e987['phone'],'to':_0x2cfb05()[_0x36c449('0x2863')](_0xd322bf['to'])||_0x2cfb05()[_0x36c449('0x1081')](_0xd322bf['to'])?[]:_0xd322bf['to'],'body':''},_0x1e9654[_0x36c449('0x20ba')]=_0x515154,_0x1e9654[_0x36c449('0x184e')]=_0x4093d2,_0x1e9654[_0x36c449('0x24a0')]=_0x219a5b,_0x1e9654['contactSearch']=_0x4d8257,_0x1e9654[_0x36c449('0x364')]=_0x4af54b;switch(_0x36bc56){case _0x36c449('0x2b1'):_0x1e9654['note']();break;}function _0x20e2c0(_0x3e3b2b){const _0x28f040=_0x36c449;_0xb1082e[_0x28f040('0x1197')]({'to':_0x1e9654[_0x28f040('0x1e70')]['to'][_0x28f040('0x45a')](','),'body':_0x3e3b2b});}function _0x515154(){const _0x35bacb=_0x36c449;_0x1e9654[_0x35bacb('0x1e70')]['to']&&_0x1e9654[_0x35bacb('0x1e70')][_0x35bacb('0x8d2')]&&(_0x1e9654[_0x35bacb('0x1e70')]['to'][_0x35bacb('0x264b')]?_0x20e2c0(_0x1e9654[_0x35bacb('0x1e70')][_0x35bacb('0x8d2')]):_0x46428b[_0x35bacb('0xfc9')](_0x35bacb('0x1839')));}function _0x237562(_0x5c7999){const _0x269528=_0x36c449;if(_0x5c7999){try{_0x2cfb05()[_0x269528('0x1af4')][_0x269528('0x1e87')]=/{{([\s\S]+?)}}/g;const _0x36b4ed=_0x2cfb05()[_0x269528('0x243')](_0x5c7999[_0x269528('0x18e0')]),_0x33f5a9={'user':_0x1e9654['currentUser'],'account':_0x25e987};_0x1e9654[_0x269528('0x1e70')]['body']+='\x20'+_0x36b4ed(_0x33f5a9),_0x1e9654[_0x269528('0x1b47')][_0x269528('0xe96')](_0x1e9654[_0x269528('0x1e70')][_0x269528('0x8d2')]);}catch(_0x193076){_0x1e9654[_0x269528('0x1e70')][_0x269528('0x8d2')]+='\x20'+_0x5c7999[_0x269528('0x18e0')],_0x1e9654[_0x269528('0x1b47')]['setText'](_0x1e9654['message'][_0x269528('0x8d2')]);}_0x1e9654['selectedItem']=null;}}function _0x2941cf(_0x1e3383){const _0x184111=_0x36c449,_0x595295=_0x3dcaa9['defer']();let _0x4d4fe7=[];return _0x28bc08[_0x184111('0x1b1f')][_0x184111('0xd83')]({'filter':_0x1e3383,'SmsAccountId':_0x25e987['id']})[_0x184111('0xa44')][_0x184111('0x1166')](function(_0x1acde4){const _0x34ba06=_0x184111;return _0x4d4fe7=_0x2cfb05()[_0x34ba06('0x1c6a')](_0x4d4fe7,_0x1acde4[_0x34ba06('0x269a')]),_0x28bc08[_0x34ba06('0x1b1f')]['get']({'filter':_0x1e3383})[_0x34ba06('0xa44')];})['then'](function(_0x1e5560){const _0x3e7130=_0x184111;_0x4d4fe7=_0x2cfb05()[_0x3e7130('0x1c6a')](_0x4d4fe7,_0x2cfb05()[_0x3e7130('0x1c33')](_0x1e5560[_0x3e7130('0x269a')],function(_0x54fe1c){const _0x5c680d=_0x3e7130;return!_0x54fe1c[_0x5c680d('0x56')]&&!_0x54fe1c['FaxAccountId']&&!_0x54fe1c[_0x5c680d('0xa74')]&&!_0x54fe1c[_0x5c680d('0xb8')]&&!_0x54fe1c[_0x5c680d('0x1e02')];})),_0x595295[_0x3e7130('0x18af')](_0x4d4fe7);})[_0x184111('0x1a80')](function(_0x6d2814){const _0x32f763=_0x184111;_0x595295[_0x32f763('0x21bf')](_0x6d2814);}),_0x595295[_0x184111('0x1f48')];}function _0x4093d2(_0x39b3bd){const _0x4722ab=_0x36c449;let _0x2512df='';return _0x39b3bd['firstName']&&_0x39b3bd[_0x4722ab('0x18cb')]!==_0x39b3bd[_0x4722ab('0x2459')]&&(_0x2512df+=_0x39b3bd[_0x4722ab('0x18cb')]+'\x20'),_0x39b3bd[_0x4722ab('0xeb0')]&&_0x39b3bd['lastName']!==_0x39b3bd[_0x4722ab('0x2459')]&&(_0x2512df+=_0x39b3bd[_0x4722ab('0xeb0')]+'\x20'),_0x2512df+='<'+_0x39b3bd[_0x4722ab('0x2459')]+'>';}function _0x4af54b(_0x2729a2){const _0x2362a5=_0x36c449,_0x28e101=_0x2729a2;if(_0x2cfb05()[_0x2362a5('0x235f')](_0x28e101))return _0x2729a2[_0x2362a5('0x2459')];if(_0x833d16(_0x28e101))return _0x28e101;return _0x46428b[_0x2362a5('0xfc9')](_0x2362a5('0x16f0')+_0x28e101+'\x20is\x20not\x20valid'),null;}function _0x4d8257(_0x1d89aa){const _0x5892bc=_0x36c449;if(_0x25e987&&_0x25e987[_0x5892bc('0x23c')])return _0x28bc08['cmContact'][_0x5892bc('0xd83')]({'ListId':_0x25e987[_0x5892bc('0x23c')],'nolimit':!![],'filter':_0x1d89aa,'fields':_0x5892bc('0x2083')})[_0x5892bc('0xa44')][_0x5892bc('0x1166')](function(_0x3561a3){const _0x21e88a=_0x5892bc;return _0x3561a3[_0x21e88a('0x269a')];});return[];}function _0x219a5b(){const _0x8b74ab=_0x36c449;_0xb1082e[_0x8b74ab('0x3f')]();}function _0x833d16(_0x11bf4e){const _0x310205=_0x36c449,_0x4bd5fa=/^(\+|\d)[0-9]{7,16}$/;return _0x4bd5fa[_0x310205('0x45d')](_0x11bf4e);}function _0xab84c3(){const _0x22b918=_0x36c449;_0x1e9654[_0x22b918('0x1908')]=!![];}function _0x26a139(){const _0x45ef24=_0x36c449;_0x1e9654[_0x45ef24('0x1e70')][_0x45ef24('0x8d2')]&&_0xb1082e[_0x45ef24('0x1197')]({'secret':!![],'body':_0x1e9654[_0x45ef24('0x1e70')][_0x45ef24('0x8d2')]});}}const _0x58ca6c=_0x4d9c08;_0x555b0b['$inject']=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x8da'),_0x36e6f4('0x1566'),'$mdDialog','$mdConstant','account','message',_0x36e6f4('0x1345'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x21ef')];function _0x555b0b(_0x440832,_0x4610c9,_0x4d9695,_0xbde5c3,_0xb1d312,_0xcdaf0a,_0xf71b5a,_0x2a8678,_0x53cfc2,_0x5bb8ae,_0x3d231b,_0xac0577,_0x3456e8){const _0x48e58=_0x36e6f4,_0x48ebcf=this;_0x48ebcf[_0x48e58('0x98')]=_0x3456e8[_0x48e58('0x26cd')](),_0x48ebcf[_0x48e58('0x61a')]=[],_0x48ebcf[_0x48e58('0x104a')]=[_0xb1d312[_0x48e58('0x70c')]['ENTER'],_0xb1d312[_0x48e58('0x70c')]['COMMA'],_0xb1d312[_0x48e58('0x70c')][_0x48e58('0x3b8')]],_0x48ebcf[_0x48e58('0x6dc')]=_0x53e076,_0x48ebcf[_0x48e58('0x138d')]=_0x341166,_0x48ebcf[_0x48e58('0x2b1')]=_0x3f5c20,_0x48ebcf[_0x48e58('0x19e1')]=_0x2808ff,_0x48ebcf[_0x48e58('0x1b47')]={},_0x48ebcf['message']={'from':_0xcdaf0a[_0x48e58('0x2026')],'to':_0x2cfb05()[_0x48e58('0x2863')](_0xf71b5a['to'])||_0x2cfb05()[_0x48e58('0x1081')](_0xf71b5a['to'])?[]:_0xf71b5a['to'],'body':''},_0x48ebcf[_0x48e58('0x20ba')]=_0x32656b,_0x48ebcf[_0x48e58('0x184e')]=_0x147100,_0x48ebcf['closeDialog']=_0xc44dd,_0x48ebcf[_0x48e58('0x154a')]=_0x5b6f9a,_0x48ebcf[_0x48e58('0x364')]=_0x5b96fc;switch(_0x2a8678){case _0x48e58('0x2b1'):_0x48ebcf['note']();break;}function _0x4cc884(_0x6b6637){const _0x1592e4=_0x48e58;_0xbde5c3[_0x1592e4('0x1197')]({'to':_0x48ebcf[_0x1592e4('0x1e70')]['to'][_0x1592e4('0x45a')](','),'body':_0x6b6637});}function _0x32656b(){const _0x2a5c3c=_0x48e58;_0x48ebcf[_0x2a5c3c('0x1e70')]['to']&&_0x48ebcf[_0x2a5c3c('0x1e70')][_0x2a5c3c('0x8d2')]&&(_0x48ebcf['message']['to'][_0x2a5c3c('0x264b')]?_0x4cc884(_0x48ebcf['message']['body']):_0x5bb8ae['error'](_0x2a5c3c('0x1839')));}function _0x341166(_0x2b72cb){const _0x2876c1=_0x48e58;if(_0x2b72cb){try{_0x2cfb05()[_0x2876c1('0x1af4')][_0x2876c1('0x1e87')]=/{{([\s\S]+?)}}/g;const _0x699aef=_0x2cfb05()['template'](_0x2b72cb[_0x2876c1('0x18e0')]),_0x5d927f={'user':_0x48ebcf[_0x2876c1('0x98')],'account':_0xcdaf0a};_0x48ebcf['message'][_0x2876c1('0x8d2')]+='\x20'+_0x699aef(_0x5d927f),_0x48ebcf['ctrlMethods']['setText'](_0x48ebcf[_0x2876c1('0x1e70')]['body']);}catch(_0xb72c73){_0x48ebcf['message'][_0x2876c1('0x8d2')]+='\x20'+_0x2b72cb[_0x2876c1('0x18e0')],_0x48ebcf['ctrlMethods'][_0x2876c1('0xe96')](_0x48ebcf['message'][_0x2876c1('0x8d2')]);}_0x48ebcf[_0x2876c1('0x1511')]=null;}}function _0x53e076(_0x26a8e9){const _0x14434c=_0x48e58,_0xfb9b44=_0x3d231b[_0x14434c('0x24d8')]();let _0x18c7c1=[];return _0x53cfc2[_0x14434c('0x1b1f')][_0x14434c('0xd83')]({'filter':_0x26a8e9,'WhatsappAccountId':_0xcdaf0a['id']})['$promise']['then'](function(_0x5d1d49){const _0x29dff4=_0x14434c;return _0x18c7c1=_0x2cfb05()['concat'](_0x18c7c1,_0x5d1d49[_0x29dff4('0x269a')]),_0x53cfc2[_0x29dff4('0x1b1f')][_0x29dff4('0xd83')]({'filter':_0x26a8e9})['$promise'];})[_0x14434c('0x1166')](function(_0x49a95f){const _0x5a6e86=_0x14434c;_0x18c7c1=_0x2cfb05()[_0x5a6e86('0x1c6a')](_0x18c7c1,_0x2cfb05()[_0x5a6e86('0x1c33')](_0x49a95f[_0x5a6e86('0x269a')],function(_0x5c6ad2){const _0x5960cf=_0x5a6e86;return!_0x5c6ad2[_0x5960cf('0x56')]&&!_0x5c6ad2['FaxAccountId']&&!_0x5c6ad2[_0x5960cf('0x1b88')]&&!_0x5c6ad2[_0x5960cf('0xb8')]&&!_0x5c6ad2[_0x5960cf('0x1e02')];})),_0xfb9b44[_0x5a6e86('0x18af')](_0x18c7c1);})[_0x14434c('0x1a80')](function(_0x9fba96){_0xfb9b44['reject'](_0x9fba96);}),_0xfb9b44[_0x14434c('0x1f48')];}function _0x147100(_0x715d2b){const _0x3cff18=_0x48e58;let _0x4d4fb3='';return _0x715d2b[_0x3cff18('0x18cb')]&&_0x715d2b[_0x3cff18('0x18cb')]!==_0x715d2b['mobile']&&(_0x4d4fb3+=_0x715d2b['firstName']+'\x20'),_0x715d2b['lastName']&&_0x715d2b[_0x3cff18('0xeb0')]!==_0x715d2b[_0x3cff18('0x2459')]&&(_0x4d4fb3+=_0x715d2b[_0x3cff18('0xeb0')]+'\x20'),_0x4d4fb3+='<'+_0x715d2b[_0x3cff18('0x2459')]+'>';}function _0x5b96fc(_0x11d133){const _0x122e0f=_0x48e58,_0x3172ae=_0x11d133;if(_0x2cfb05()[_0x122e0f('0x235f')](_0x3172ae))return _0x11d133[_0x122e0f('0x2459')];if(_0x4a8af7(_0x3172ae))return _0x3172ae;return _0x5bb8ae[_0x122e0f('0xfc9')](_0x122e0f('0x16f0')+_0x3172ae+_0x122e0f('0x167f')),null;}function _0x5b6f9a(_0x432d1a){const _0x5e098c=_0x48e58;if(_0xcdaf0a&&_0xcdaf0a['ListId'])return _0x53cfc2['cmContact']['get']({'ListId':_0xcdaf0a['ListId'],'nolimit':!![],'filter':_0x432d1a,'fields':_0x5e098c('0x2083')})[_0x5e098c('0xa44')][_0x5e098c('0x1166')](function(_0x425bc8){const _0x247973=_0x5e098c;return _0x425bc8[_0x247973('0x269a')];});return[];}function _0xc44dd(){const _0x557442=_0x48e58;_0xbde5c3[_0x557442('0x3f')]();}function _0x4a8af7(_0x222924){const _0x339d72=/^(\+|\d)[0-9]{7,16}$/;return _0x339d72['test'](_0x222924);}function _0x3f5c20(){const _0xcbbb28=_0x48e58;_0x48ebcf[_0xcbbb28('0x1908')]=!![];}function _0x2808ff(){const _0x1c11d6=_0x48e58;_0x48ebcf[_0x1c11d6('0x1e70')]['body']&&_0xbde5c3[_0x1c11d6('0x1197')]({'secret':!![],'body':_0x48ebcf[_0x1c11d6('0x1e70')][_0x1c11d6('0x8d2')]});}}const _0x440eb1=_0x555b0b;_0x51036c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x25e6'),_0x36e6f4('0x1298'),_0x36e6f4('0x557'),'draftManager'];function _0x51036c(_0x2856f1,_0x170a93,_0x2db282,_0x15dc58,_0x472cd3,_0x4ff71a,_0x12ca12){const _0x2c29d8=_0x36e6f4,_0x2255a8=this;_0x2255a8[_0x2c29d8('0x61a')]=[],_0x2255a8['dispositions']=[],_0x2255a8['interaction']=angular['copy'](_0x15dc58);!_0x2255a8[_0x2c29d8('0x25e6')][_0x2c29d8('0x12e8')]&&(_0x2255a8[_0x2c29d8('0x25e6')][_0x2c29d8('0x12e8')]=null);_0x2255a8[_0x2c29d8('0x1298')]=_0x472cd3,_0x2255a8[_0x2c29d8('0x19dc')]=_0x2255a8[_0x2c29d8('0x1298')]+_0x2c29d8('0x7ee'),_0x2255a8['apiAccountRoute']=_0x2255a8['channel']+(_0x2255a8[_0x2c29d8('0x1298')]==='chat'?_0x2c29d8('0x13b6'):_0x2c29d8('0x1758')),_0x2255a8[_0x2c29d8('0x1c54')]=_0x2cfb05()[_0x2c29d8('0x92c')](_0x2255a8[_0x2c29d8('0x1298')])+(_0x2255a8[_0x2c29d8('0x1298')]===_0x2c29d8('0xde2')?'Website':'Account')+'Id',_0x2255a8['firstLevelDisposition']=null,_0x2255a8[_0x2c29d8('0x10d0')]=![],_0x2255a8['mandatoryDispositionPause']='',_0x2255a8[_0x2c29d8('0x15e5')]=_0x4ff71a[_0x2c29d8('0x2540')]||_0x4ff71a[_0x2c29d8('0x1c5c')]||_0x4ff71a[_0x2c29d8('0xb4')]||_0x4ff71a[_0x2c29d8('0x287f')]||_0x4ff71a[_0x2c29d8('0x5aa')],_0x2255a8[_0x2c29d8('0xe8d')]=_0xfd28c2,_0x2255a8[_0x2c29d8('0x13fb')]=_0x9ec06a,_0x2255a8[_0x2c29d8('0x9da')]=_0x48ebe9,_0x2255a8[_0x2c29d8('0x24a0')]=_0x280573;function _0x4f6e31(){const _0x2819df=_0x2c29d8;let _0x5b4956=[];const _0x408171={'fields':_0x2819df('0x1061'),'sort':_0x2819df('0x4f0'),'nolimit':!![]};_0x408171[_0x2255a8[_0x2819df('0x1c54')]]=_0x15dc58[_0x2255a8[_0x2819df('0x1c54')]],_0x2db282[_0x2255a8[_0x2819df('0xc4c')]][_0x2819df('0xd83')]({'id':_0x15dc58[_0x2255a8[_0x2819df('0x1c54')]]})[_0x2819df('0xa44')][_0x2819df('0x1166')](function(_0x132c4f){const _0xf494c1=_0x2819df;return _0x2255a8[_0xf494c1('0x10d0')]=_0x132c4f['mandatoryDisposition'],_0x2255a8[_0xf494c1('0x10d0')]&&(_0x2255a8[_0xf494c1('0x1410')]=_0x132c4f['mandatoryDispositionPause'][_0xf494c1('0x4f0')]),_0x2db282[_0xf494c1('0x12e8')]['get'](_0x408171)[_0xf494c1('0xa44')];})[_0x2819df('0x1166')](function(_0x2a3cfd){const _0x181952=_0x2819df;return _0x2a3cfd[_0x181952('0x269a')][_0x181952('0x264b')]&&(_0x5b4956=_0x2cfb05()[_0x181952('0x1c6a')](_0x5b4956,_0x2a3cfd['rows'])),_0x2db282[_0x181952('0x12e8')]['get']({'MailAccountId':'null','FaxAccountId':_0x181952('0x15d7'),'SmsAccountId':_0x181952('0x15d7'),'WhatsappAccountId':_0x181952('0x15d7'),'OpenchannelAccountId':_0x181952('0x15d7'),'ChatWebsiteId':_0x181952('0x15d7'),'ListId':_0x181952('0x15d7')})[_0x181952('0xa44')];})[_0x2819df('0x1166')](function(_0x5e7093){const _0x3ef779=_0x2819df;_0x5e7093[_0x3ef779('0x269a')][_0x3ef779('0x264b')]&&(_0x5b4956=_0x2cfb05()[_0x3ef779('0x1c6a')](_0x5b4956,_0x5e7093[_0x3ef779('0x269a')]));})[_0x2819df('0x1a80')](function(_0x520a2b){console['error'](_0x520a2b);})[_0x2819df('0x1951')](function(){const _0x9b11e0=_0x2819df;_0x2255a8[_0x9b11e0('0x4ea')]=_0x2cfb05()[_0x9b11e0('0xe63')](_0x5b4956,[_0x9b11e0('0x4f0')],[_0x9b11e0('0x17d')]),_0x8d9538();});}function _0x8d9538(){const _0x34be0c=_0x2c29d8;_0x2255a8[_0x34be0c('0x10d0')]&&!_0x2255a8[_0x34be0c('0x15e5')]&&_0x2db282[_0x34be0c('0x557')][_0x34be0c('0x1e77')]({'id':_0x4ff71a['id'],'type':_0x2255a8['mandatoryDispositionPause']||_0x34be0c('0x2192')})['$promise'][_0x34be0c('0x1166')](function(){})[_0x34be0c('0x1a80')](function(_0x457c47){console['error'](_0x457c47);});}function _0xfd28c2(_0xde694f){const _0x49a531=_0x2c29d8;if(_0xde694f===_0x49a531('0x215c')){_0x2255a8[_0x49a531('0x2280')]=_0x2255a8['firstLevelDisposition']?_0x2cfb05()[_0x49a531('0x1798')](_0x2255a8['dispositions'],[_0x49a531('0x11fa'),_0x2255a8[_0x49a531('0x1a44')]['id']]):![];if(!_0x2255a8[_0x49a531('0x1a44')])_0x2255a8[_0x49a531('0x2092')]=undefined;}else _0xde694f==='second'&&(_0x2255a8[_0x49a531('0x266a')]=_0x2cfb05()['some'](_0x2255a8[_0x49a531('0x4ea')],[_0x49a531('0x11fa'),_0x2255a8[_0x49a531('0x2092')]['id']]));}function _0x9ec06a(_0x1b0d97){const _0x4f212f=_0x2c29d8;if(_0x1b0d97===_0x4f212f('0x161a'))_0x2255a8[_0x4f212f('0x2092')]=undefined,_0x2255a8[_0x4f212f('0x649')]=undefined;else _0x1b0d97===_0x4f212f('0x15e9')&&(_0x2255a8['thirdLevelDisposition']=undefined);}function _0x48ebe9(){const _0x206ad1=_0x2c29d8;_0x2255a8['errors']=[],_0x2255a8[_0x206ad1('0x25e6')][_0x206ad1('0x122a')]=_0x4ff71a['id'],_0x2255a8[_0x206ad1('0x25e6')][_0x206ad1('0xa5b')]=!![],_0x2255a8['interaction'][_0x206ad1('0xe92')]=_0x206ad1('0x1eff'),_0x2255a8[_0x206ad1('0x25e6')][_0x206ad1('0x12e8')]=_0x2255a8[_0x206ad1('0x1a44')]?_0x2255a8[_0x206ad1('0x1a44')]['name']:null,_0x2255a8[_0x206ad1('0x25e6')][_0x206ad1('0xe18')]=_0x2255a8[_0x206ad1('0x2092')]?_0x2255a8[_0x206ad1('0x2092')]['name']:undefined,_0x2255a8[_0x206ad1('0x25e6')][_0x206ad1('0x228e')]=_0x2255a8['thirdLevelDisposition']?_0x2255a8[_0x206ad1('0x649')][_0x206ad1('0x4f0')]:undefined,_0x2db282[_0x2255a8[_0x206ad1('0x19dc')]]?_0x2db282[_0x2255a8[_0x206ad1('0x19dc')]]['update'](_0x2cfb05()[_0x206ad1('0x1a08')](_0x2255a8[_0x206ad1('0x25e6')],[_0x206ad1('0x56'),_0x206ad1('0x18fe'),'SmsAccountId',_0x206ad1('0x1b88'),_0x206ad1('0x1e02'),_0x206ad1('0xb8'),'closed','closeReason',_0x206ad1('0x12e8'),_0x206ad1('0xe18'),_0x206ad1('0x228e'),'id',_0x206ad1('0x2b1'),_0x206ad1('0x122a')]))[_0x206ad1('0xa44')][_0x206ad1('0x1166')](function(_0x7ac8bc){const _0x524389=_0x206ad1;_0x2255a8[_0x524389('0x25e6')]=_0x7ac8bc,_0x2255a8[_0x524389('0x1298')]==='mail'&&_0x12ca12['removeByInteraction'](_0x2255a8[_0x524389('0x25e6')]['id']),_0x170a93[_0x524389('0x103b')]({'title':_0x524389('0x811'),'msg':_0x524389('0x1a67')});})[_0x206ad1('0x1166')](function(){_0x280573(!![]);})[_0x206ad1('0x1a80')](function(_0xde3bad){const _0xedbd43=_0x206ad1;if(_0xde3bad['data']&&_0xde3bad[_0xedbd43('0x25f4')]['errors']&&_0xde3bad[_0xedbd43('0x25f4')]['errors'][_0xedbd43('0x264b')]){_0x2255a8[_0xedbd43('0x61a')]=_0xde3bad[_0xedbd43('0x25f4')][_0xedbd43('0x61a')]||[{'message':_0xde3bad[_0xedbd43('0x1586')](),'type':_0xedbd43('0x141b')}];for(let _0x55def1=0x0;_0x55def1<_0xde3bad[_0xedbd43('0x25f4')][_0xedbd43('0x61a')][_0xedbd43('0x264b')];_0x55def1++){_0x170a93[_0xedbd43('0xfc9')]({'title':_0xde3bad[_0xedbd43('0x25f4')][_0xedbd43('0x61a')][_0x55def1][_0xedbd43('0x1345')],'msg':_0xde3bad[_0xedbd43('0x25f4')][_0xedbd43('0x61a')][_0x55def1][_0xedbd43('0x1e70')]});}}else _0x170a93[_0xedbd43('0xfc9')]({'title':_0xde3bad[_0xedbd43('0x52d')]?'API:'+_0xde3bad[_0xedbd43('0x52d')]+_0xedbd43('0x11e1')+_0xde3bad['statusText']:_0xedbd43('0x141b'),'msg':_0xde3bad[_0xedbd43('0x25f4')]?JSON[_0xedbd43('0xbac')](_0xde3bad[_0xedbd43('0x25f4')]['message']):_0xde3bad['toString']()});}):_0x280573(![]);}function _0x280573(_0x43c8e7){const _0x312e3c=_0x2c29d8;_0x2856f1[_0x312e3c('0x1197')](_0x43c8e7);}_0x4f6e31();}const _0x1f78af=_0x51036c;_0x26ffa0['$inject']=[_0x36e6f4('0x265d'),'toasty','api',_0x36e6f4('0x25e6'),_0x36e6f4('0x1298'),_0x36e6f4('0xb38')];function _0x26ffa0(_0x14dd20,_0x2690d5,_0xa20bb8,_0x35597b,_0x4d0a28,_0x5255dd){const _0x22347f=_0x36e6f4,_0x5dca0e=this;_0x5dca0e[_0x22347f('0x61a')]=[],_0x5dca0e[_0x22347f('0xb38')]=_0x5255dd,_0x5dca0e[_0x22347f('0x25e6')]=angular['copy'](_0x35597b),_0x5dca0e['interaction']['Tags']=_0x2cfb05()[_0x22347f('0x2563')](_0x5dca0e[_0x22347f('0x25e6')][_0x22347f('0x21c2')],function(_0x13c5e0){const _0x5971ef=_0x22347f;return{'id':_0x13c5e0['id'],'name':_0x13c5e0[_0x5971ef('0x4f0')],'color':_0x13c5e0['color']};}),_0x5dca0e[_0x22347f('0x1298')]=_0x4d0a28,_0x5dca0e[_0x22347f('0x1d9a')]=!![],_0x5dca0e['saveTag']=_0x62adbf,_0x5dca0e[_0x22347f('0x24a0')]=_0x525874,_0x5dca0e[_0x22347f('0x19dc')]=_0x5dca0e[_0x22347f('0x1298')]+'Interaction';function _0x62adbf(){const _0x5e7164=_0x22347f;_0x5dca0e['errors']=[];if(_0xa20bb8[_0x5dca0e[_0x5e7164('0x19dc')]])return _0xa20bb8[_0x5dca0e[_0x5e7164('0x19dc')]][_0x5e7164('0x22a5')]({'id':_0x5dca0e[_0x5e7164('0x25e6')]['id'],'ids':_0x2cfb05()[_0x5e7164('0x2563')](_0x5dca0e['interaction'][_0x5e7164('0x21c2')],'id')})['$promise'][_0x5e7164('0x1166')](function(){const _0x5497c8=_0x5e7164;_0x2690d5[_0x5497c8('0x103b')]({'title':'Interaction\x20properly\x20tagged!','msg':_0x5497c8('0x1b3f')}),_0x35597b['Tags']=_0x5dca0e[_0x5497c8('0x25e6')][_0x5497c8('0x21c2')],_0x525874(!![]);})[_0x5e7164('0x1a80')](function(_0x30623f){const _0x51bc9e=_0x5e7164;if(_0x30623f[_0x51bc9e('0x25f4')]&&_0x30623f[_0x51bc9e('0x25f4')][_0x51bc9e('0x61a')]&&_0x30623f[_0x51bc9e('0x25f4')]['errors'][_0x51bc9e('0x264b')])for(let _0x29e018=0x0;_0x29e018<_0x30623f['data'][_0x51bc9e('0x61a')][_0x51bc9e('0x264b')];_0x29e018+=0x1){_0x2690d5[_0x51bc9e('0xfc9')]({'title':_0x30623f[_0x51bc9e('0x25f4')][_0x51bc9e('0x61a')][_0x29e018][_0x51bc9e('0x1345')],'msg':_0x30623f[_0x51bc9e('0x25f4')]['errors'][_0x29e018][_0x51bc9e('0x1e70')]});}else _0x2690d5['error']({'title':_0x30623f[_0x51bc9e('0x52d')]?_0x51bc9e('0x1e21')+_0x30623f[_0x51bc9e('0x52d')]+_0x51bc9e('0x11e1')+_0x30623f[_0x51bc9e('0xe1b')]:_0x51bc9e('0x141b'),'msg':_0x30623f[_0x51bc9e('0x25f4')]?JSON[_0x51bc9e('0xbac')](_0x30623f[_0x51bc9e('0x25f4')][_0x51bc9e('0x1e70')]):_0x30623f[_0x51bc9e('0x1586')]()});});else _0x525874(![]);}function _0x525874(_0x3e3e10){const _0x13b7d5=_0x22347f;_0x14dd20[_0x13b7d5('0x1197')](_0x3e3e10);}}const _0x464c1b=_0x26ffa0;_0x242c61[_0x36e6f4('0x1294')]=['$mdDialog',_0x36e6f4('0x8da'),'Auth','api',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1298'),_0x36e6f4('0x1e70'),_0x36e6f4('0x1a32')];function _0x242c61(_0x2a5ccd,_0x4a9829,_0x42e35f,_0x5a4fd6,_0x2a3c01,_0x1bd68f,_0x4b598b,_0xf4e8e0){const _0x31c00f=_0x36e6f4,_0x4293b4=this;_0x4293b4['currentUser']=_0x42e35f[_0x31c00f('0x26cd')](),_0x4293b4[_0x31c00f('0x1298')]=_0x1bd68f[_0x31c00f('0x2574')](),_0x4293b4[_0x31c00f('0x1e70')]=_0x4b598b,_0x4293b4[_0x31c00f('0x1a32')]=_0xf4e8e0,_0x4293b4[_0x31c00f('0x646')]={'id':0x0,'type':_0x31c00f('0x1d3e')},_0x4293b4['queues']={'count':0x0,'rows':[]},_0x4293b4[_0x31c00f('0x1f7e')]=_0x4293b4[_0x31c00f('0x7a7')],_0x4293b4[_0x31c00f('0x20c3')]=_0x4293b4['channel']+_0x31c00f('0x28ba'),_0x4293b4[_0x31c00f('0x79c')]=_0x4293b4[_0x31c00f('0x1298')]+_0x31c00f('0x19f9'),_0x4293b4[_0x31c00f('0x1ffb')]=_0x179a4f,_0x4293b4[_0x31c00f('0x24a0')]=_0x42dcc8,_0x4293b4[_0x31c00f('0x24d5')]=_0x1f6702,_0x4293b4['init']();function _0x1f6702(){const _0x205662=_0x31c00f;return _0x5a4fd6[_0x205662('0x557')][_0x205662('0xd83')]({'fields':_0x205662('0x1776'),'role':_0x205662('0x1eff'),'sort':_0x205662('0x4f0'),'nolimit':!![]})[_0x205662('0xa44')][_0x205662('0x1166')](function(_0x28ddc7){const _0x42005f=_0x205662;return _0x4293b4['agents']=_0x28ddc7||{'count':0x0,'rows':[]},_0x5a4fd6[_0x4293b4[_0x42005f('0x20c3')]][_0x42005f('0xd83')]({'fields':_0x42005f('0x1776'),'sort':_0x42005f('0x4f0'),'nolimit':!![]})[_0x42005f('0xa44')];})['then'](function(_0x25d7b3){_0x4293b4['queues']=_0x25d7b3||{'count':0x0,'rows':[]};})[_0x205662('0x1a80')](function(_0x14daea){const _0x9b8652=_0x205662;console[_0x9b8652('0xfc9')](_0x14daea);});}function _0x42dcc8(_0x34a965){const _0x2586ba=_0x31c00f;_0x2a5ccd[_0x2586ba('0x1197')](_0x34a965);}function _0x179a4f(){_0x42dcc8(!![]),_0x4a9829(function(){const _0x2148c1=a0_0x3f2c;return _0x5a4fd6[_0x2148c1('0x13fa')][_0x4293b4['transfer'][_0x2148c1('0x1345')]===_0x2148c1('0x1eff')?_0x2148c1('0x246'):_0x4293b4[_0x2148c1('0x79c')]]({'id':_0x4293b4[_0x2148c1('0x646')]['id'],'messageId':_0x4293b4[_0x2148c1('0x1e70')]['id'],'channel':_0x4293b4[_0x2148c1('0x1298')]})[_0x2148c1('0xa44')][_0x2148c1('0x1166')](function(){const _0x2ba15e=_0x2148c1;_0x2a3c01['success']({'title':'Trasfer\x20properly\x20done!','msg':_0x2ba15e('0x28f3')+_0x4293b4[_0x2ba15e('0x646')][_0x2ba15e('0x1345')]+'\x20has\x20been\x20done!'});})[_0x2148c1('0x1a80')](function(_0x2631ff){const _0x541972=_0x2148c1;if(_0x2631ff['data']&&_0x2631ff[_0x541972('0x25f4')]['errors']&&_0x2631ff['data'][_0x541972('0x61a')][_0x541972('0x264b')]){_0x4293b4[_0x541972('0x61a')]=_0x2631ff['data']['errors']||[{'message':_0x2631ff[_0x541972('0x1586')](),'type':_0x541972('0x1e55')}];for(let _0x3a4f47=0x0;_0x3a4f47<_0x2631ff['data']['errors'][_0x541972('0x264b')];_0x3a4f47++){_0x2a3c01[_0x541972('0xfc9')]({'title':_0x2631ff[_0x541972('0x25f4')][_0x541972('0x61a')][_0x3a4f47]['type'],'msg':_0x2631ff[_0x541972('0x25f4')]['errors'][_0x3a4f47][_0x541972('0x1e70')]});}}else _0x2a3c01[_0x541972('0xfc9')]({'title':_0x2631ff[_0x541972('0x52d')]?'API:'+_0x2631ff[_0x541972('0x52d')]+_0x541972('0x11e1')+_0x2631ff[_0x541972('0xe1b')]:'api.rpc.notify','msg':_0x2631ff[_0x541972('0x25f4')]?JSON[_0x541972('0xbac')](_0x2631ff[_0x541972('0x25f4')][_0x541972('0x1e70')]):_0x2631ff[_0x541972('0x1586')]()});});},0x1388);}}const _0x2529b2=_0x242c61;_0x3e756a['$inject']=[_0x36e6f4('0x36f'),'$q',_0x36e6f4('0x265d'),'mwFormResponseUtils',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x586'),_0x36e6f4('0x1cab'),_0x36e6f4('0x8da'),_0x36e6f4('0x1f36')];function _0x3e756a(_0x3d4fe7,_0x1a146e,_0x50b32e,_0x584eea,_0x2c2bf2,_0x364425,_0x262427,_0xc8e1ac,_0x3da91c,_0x41295f,_0x44a38d){const _0x5a1dea=_0x36e6f4,_0x5b2c90=this;_0x5b2c90['formViewer']={},_0x5b2c90[_0x5a1dea('0x93a')]=!![],_0x5b2c90[_0x5a1dea('0x10f1')]=![],_0x5b2c90[_0x5a1dea('0x2694')]=_0x44a38d[_0x5a1dea('0x2694')](),_0x5b2c90[_0x5a1dea('0xfd8')]=_0xe2da02,_0x5b2c90['openContact']=_0x4a5715,_0x5b2c90[_0x5a1dea('0x617')]=_0x1ede48,_0x5b2c90[_0x5a1dea('0xd5f')]=_0x328313,_0x5b2c90['getResponseSheetRow']=_0x5f052d,_0x5b2c90[_0x5a1dea('0x1598')]=_0x25b4f8,_0x5b2c90[_0x5a1dea('0xb14')]=_0x22c307,_0x5b2c90[_0x5a1dea('0x24d5')]=_0x4703b6,_0x5b2c90[_0x5a1dea('0x19ef')]=function(_0x124f09){const _0x32c51f=_0x5a1dea;if(_0x5b2c90[_0x32c51f('0x1c5d')][_0x32c51f('0x1aa')]){const _0x1fbcb2=_0x50b32e[_0x32c51f('0x1d26')]()[_0x32c51f('0xcdc')](_0xc8e1ac[_0x32c51f('0x25cc')](_0x32c51f('0x1efc')))['content'](_0xc8e1ac[_0x32c51f('0x25cc')](_0x32c51f('0x2635')))[_0x32c51f('0x2077')]('')[_0x32c51f('0x8e8')](_0x32c51f('0xa'))['targetEvent'](_0x124f09)['ok'](_0xc8e1ac[_0x32c51f('0x25cc')](_0x32c51f('0x113e')))['cancel'](_0xc8e1ac['instant'](_0x32c51f('0xe89')));_0x50b32e['show'](_0x1fbcb2)[_0x32c51f('0x1166')](function(){const _0x4f98ec=_0x32c51f;_0x5b2c90[_0x4f98ec('0x10f1')]=![],_0x5b2c90['project'][_0x4f98ec('0x25c5')]=undefined,_0x19d407(),_0x5b2c90['formViewer'][_0x4f98ec('0x1aa')]();});}};function _0x19d407(){const _0x1a442c=_0x5a1dea;try{_0x3d4fe7[_0x1a442c('0x23ac')]['$parent'][_0x1a442c('0x23ac')]['vm'][_0x1a442c('0x1a4f')]();}catch(_0xabf6c3){_0x364425[_0x1a442c('0xfc9')]({'title':_0x1a442c('0x845'),'msg':_0x1a442c('0x369')});}}function _0x4703b6(_0x379c6d){const _0x1c86a1=_0x5a1dea;_0x5b2c90[_0x1c86a1('0xbe3')]=_0x379c6d;if(_0x5b2c90[_0x1c86a1('0xbe3')]){_0x5b2c90[_0x1c86a1('0x200f')]=_0x5b2c90[_0x1c86a1('0xbe3')][_0x1c86a1('0x200f')],_0x5b2c90['starttime']=_0x5b2c90['tab'][_0x1c86a1('0x87f')],_0x5b2c90[_0x1c86a1('0x26db')]=_0x5b2c90[_0x1c86a1('0xbe3')][_0x1c86a1('0x26db')],_0x5b2c90['project']=_0x5b2c90[_0x1c86a1('0xbe3')][_0x1c86a1('0x2588')];if(_0x5b2c90[_0x1c86a1('0x2588')]){if(_0x2cfb05()[_0x1c86a1('0x186')](_0x5b2c90['project'][_0x1c86a1('0x1ff2')])){}else _0x5b2c90[_0x1c86a1('0x617')](_0x5b2c90[_0x1c86a1('0x2588')][_0x1c86a1('0x1ff2')])?_0x5b2c90[_0x1c86a1('0x2588')][_0x1c86a1('0x1ff2')]=JSON[_0x1c86a1('0x1295')](_0x5b2c90['project'][_0x1c86a1('0x1ff2')]):_0x5b2c90['project']['formData']=undefined;_0x5b2c90[_0x1c86a1('0x2588')][_0x1c86a1('0x6de')]=_0x5b2c90[_0x1c86a1('0x2588')]['responseData']||{},_0x5b2c90[_0x1c86a1('0x2588')][_0x1c86a1('0x25c5')]!==undefined&&_0x41295f(function(){const _0x2061ce=_0x1c86a1;_0x3da91c[_0x2061ce('0x1d73')](_0x2061ce('0x2383'),{'page':_0x5b2c90['project']['currentPage']});}),_0x3d4fe7[_0x1c86a1('0x3d2')]('mwForm.pageEvents.pageCurrentChanged',function(_0x14d846,_0x26948e){const _0x2ac8e2=_0x1c86a1;if(_0x26948e[_0x2ac8e2('0x25c5')]){_0x5b2c90[_0x2ac8e2('0x2588')][_0x2ac8e2('0x25c5')]=_0x26948e[_0x2ac8e2('0x25c5')]['number']-0x1,_0x19d407();_0x5b2c90[_0x2ac8e2('0x2588')][_0x2ac8e2('0x11a1')]&&(_0x26948e['currentPage'][_0x2ac8e2('0xc45')]>=0x1&&_0x26948e['currentPage']['number']<_0x5b2c90['project'][_0x2ac8e2('0x1ff2')][_0x2ac8e2('0x4a8')][_0x2ac8e2('0x264b')]?_0x5b2c90[_0x2ac8e2('0x10f1')]=!![]:_0x5b2c90[_0x2ac8e2('0x10f1')]=![]);if(_0x5b2c90[_0x2ac8e2('0x2588')][_0x2ac8e2('0x1ff2')]&&_0x5b2c90[_0x2ac8e2('0x2588')]['formData']['pages'])for(let _0x363904=0x0,_0x51bf45=_0x5b2c90[_0x2ac8e2('0x2588')][_0x2ac8e2('0x1ff2')][_0x2ac8e2('0x4a8')][_0x2ac8e2('0x264b')];_0x363904<_0x51bf45;_0x363904++){if(_0x26948e[_0x2ac8e2('0x25c5')][_0x2ac8e2('0xc45')]<_0x363904+0x1&&_0x5b2c90[_0x2ac8e2('0x2588')]['formData'][_0x2ac8e2('0x4a8')][_0x363904]['elements'])for(let _0x2f4573=0x0,_0x20bef7=_0x5b2c90[_0x2ac8e2('0x2588')][_0x2ac8e2('0x1ff2')]['pages'][_0x363904][_0x2ac8e2('0x17d1')]['length'];_0x2f4573<_0x20bef7;_0x2f4573++){_0x5b2c90[_0x2ac8e2('0x2588')]['formData'][_0x2ac8e2('0x4a8')][_0x363904]['elements'][_0x2f4573][_0x2ac8e2('0x1345')]===_0x2ac8e2('0x9b')&&_0x5b2c90['project'][_0x2ac8e2('0x1ff2')][_0x2ac8e2('0x4a8')][_0x363904]['elements'][_0x2f4573][_0x2ac8e2('0x9b')]&&delete _0x5b2c90['project']['responseData'][_0x5b2c90[_0x2ac8e2('0x2588')][_0x2ac8e2('0x1ff2')][_0x2ac8e2('0x4a8')][_0x363904][_0x2ac8e2('0x17d1')][_0x2f4573]['question']['id']];}}}});}}}function _0x1ede48(_0x36514b){const _0x59b29a=_0x5a1dea;if(_0x2cfb05()[_0x59b29a('0x2863')](_0x36514b))return![];try{JSON[_0x59b29a('0x1295')](_0x36514b);}catch(_0x5df33e){return![];}return!![];}function _0x4a5715(_0x4bbdb2,_0x1e9938){const _0x1a0713=_0x5a1dea;try{_0x3d4fe7['$parent'][_0x1a0713('0x23ac')][_0x1a0713('0x23ac')]['vm'][_0x1a0713('0x247b')](_0x1e9938);}catch(_0x5dff2a){_0x364425[_0x1a0713('0xfc9')]({'title':_0x1a0713('0x1b20'),'msg':_0x1a0713('0xfb2')});}}function _0x668212(_0x5eb55e){const _0x39f0a2=_0x5a1dea,_0x3d2614=_0x1a146e[_0x39f0a2('0x24d8')]();return _0x5b2c90[_0x39f0a2('0x2588')][_0x39f0a2('0x1c87')]?_0x2c2bf2['user']['unpause']({'id':_0x5eb55e['id']})[_0x39f0a2('0xa44')][_0x39f0a2('0x1166')](function(){const _0x5cc590=_0x39f0a2;_0x3d2614[_0x5cc590('0x18af')]();})[_0x39f0a2('0x1a80')](function(){const _0x4771b0=_0x39f0a2;console[_0x4771b0('0x455')]('err'),_0x3d2614[_0x4771b0('0x18af')]();}):_0x3d2614[_0x39f0a2('0x18af')](),_0x3d2614[_0x39f0a2('0x1f48')];}function _0x4f3db6(_0x13166d,_0x3e41eb){const _0x1c6317=_0x5a1dea,_0x45dc0b=[],_0x4faa21=[],_0x24af61=_0x262427[_0x1c6317('0x26cd')]();_0x668212(_0x24af61)[_0x1c6317('0x1166')](function(){const _0x52833d=_0x1c6317;return _0x2c2bf2[_0x52833d('0x3ed')][_0x52833d('0x9cc')]({'starttime':_0x5b2c90[_0x52833d('0x539')],'membername':_0x5b2c90['call']&&_0x5b2c90[_0x52833d('0x200f')][_0x52833d('0x256b')]?_0x5b2c90[_0x52833d('0x200f')][_0x52833d('0x256b')]:_0x24af61[_0x52833d('0x4f0')],'calleridname':_0x5b2c90[_0x52833d('0x200f')]&&_0x5b2c90['call'][_0x52833d('0x1f24')]?_0x5b2c90[_0x52833d('0x200f')]['calleridname']:undefined,'calleridnum':_0x5b2c90['call']&&_0x5b2c90[_0x52833d('0x200f')][_0x52833d('0x26a8')]?_0x5b2c90[_0x52833d('0x200f')][_0x52833d('0x26a8')]:undefined,'queue':_0x5b2c90[_0x52833d('0x200f')]&&_0x5b2c90[_0x52833d('0x200f')][_0x52833d('0x1d3e')]?_0x5b2c90[_0x52833d('0x200f')]['queue']:undefined,'uniqueid':_0x5b2c90[_0x52833d('0x200f')]&&_0x5b2c90[_0x52833d('0x200f')][_0x52833d('0x1c21')]?_0x5b2c90[_0x52833d('0x200f')][_0x52833d('0x1c21')]:undefined,'VoiceQueueId':_0x5b2c90[_0x52833d('0x200f')]&&_0x5b2c90[_0x52833d('0x200f')][_0x52833d('0xf38')]?_0x5b2c90[_0x52833d('0x200f')][_0x52833d('0xf38')]:undefined,'ProjectId':_0x5b2c90['project']&&_0x5b2c90[_0x52833d('0x2588')]['id']?_0x5b2c90[_0x52833d('0x2588')]['id']:undefined,'projectname':_0x5b2c90[_0x52833d('0x2588')]&&_0x5b2c90[_0x52833d('0x2588')][_0x52833d('0x4f0')]?_0x5b2c90['project']['name']:undefined,'ContactId':_0x5b2c90[_0x52833d('0x26db')]&&_0x5b2c90[_0x52833d('0x26db')]['id']?_0x5b2c90[_0x52833d('0x26db')]['id']:undefined,'completed':_0x3e41eb})['$promise'];})['then'](function(_0x1cbb73){const _0x26f687=_0x1c6317;if(_0x1cbb73){const _0x4af6f7=_0x5b2c90[_0x26f687('0x1598')](),_0xf83dc8=_0x5b2c90[_0x26f687('0x17ea')](),_0x6540e9=_0x5b2c90[_0x26f687('0xb14')]();for(let _0x51764c=0x0;_0x51764c<_0x4af6f7[_0x26f687('0x264b')];_0x51764c+=0x1){if(!_0x2cfb05()[_0x26f687('0x1081')](String(_0xf83dc8[_0x51764c]))){try{_0x45dc0b[_0x26f687('0x1514')](_0x2c2bf2[_0x26f687('0x816')][_0x26f687('0x9cc')]({'question':_0x4af6f7[_0x51764c],'answer':_0x6540e9[_0x51764c][_0x26f687('0x1345')]==='date'?_0x24273b()(String(_0xf83dc8[_0x51764c]))[_0x26f687('0x128a')]('YYYY-MM-DD'):_0x6540e9[_0x51764c][_0x26f687('0x1345')]===_0x26f687('0x12bf')?_0x24273b()(String(_0xf83dc8[_0x51764c]))[_0x26f687('0x128a')](_0x26f687('0x307')):String(_0xf83dc8[_0x51764c]),'questionId':_0x6540e9[_0x51764c]['id'],'membername':_0x5b2c90[_0x26f687('0x200f')]&&_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x256b')]?_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x256b')]:_0x24af61['name'],'calleridname':_0x5b2c90[_0x26f687('0x200f')]&&_0x5b2c90[_0x26f687('0x200f')]['calleridname']?_0x5b2c90[_0x26f687('0x200f')]['calleridname']:undefined,'calleridnum':_0x5b2c90['call']&&_0x5b2c90['call']['calleridnum']?_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x26a8')]:undefined,'queue':_0x5b2c90[_0x26f687('0x200f')]&&_0x5b2c90['call'][_0x26f687('0x1d3e')]?_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x1d3e')]:undefined,'uniqueid':_0x5b2c90['call']&&_0x5b2c90['call']['uniqueid']?_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x1c21')]:undefined,'SessionId':_0x1cbb73['id'],'ProjectId':_0x5b2c90['project']['id'],'projectname':_0x5b2c90[_0x26f687('0x2588')][_0x26f687('0x4f0')]}));}catch(_0x301df6){console[_0x26f687('0xfc9')](_0x26f687('0x20a'),_0x301df6);}const _0x30a7de=String(_0xf83dc8[_0x51764c])[_0x26f687('0x25c8')](';');for(let _0x26b4f5=0x0;_0x26b4f5<_0x30a7de['length'];_0x26b4f5+=0x1){const _0x3dfe65=_0x30a7de[_0x26b4f5]['trim']();try{_0x4faa21[_0x26f687('0x1514')](_0x2c2bf2[_0x26f687('0x228b')][_0x26f687('0x9cc')]({'question':_0x4af6f7[_0x51764c],'questionId':_0x6540e9[_0x51764c]['id'],'answer':_0x6540e9[_0x51764c][_0x26f687('0x1345')]===_0x26f687('0x1643')?_0x24273b()(_0x3dfe65)['format'](_0x26f687('0x1356')):_0x6540e9[_0x51764c][_0x26f687('0x1345')]==='time'?_0x24273b()(_0x3dfe65)[_0x26f687('0x128a')](_0x26f687('0x307')):_0x3dfe65,'membername':_0x5b2c90[_0x26f687('0x200f')]&&_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x256b')]?_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x256b')]:_0x24af61['name'],'calleridname':_0x5b2c90[_0x26f687('0x200f')]&&_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x1f24')]?_0x5b2c90['call'][_0x26f687('0x1f24')]:undefined,'calleridnum':_0x5b2c90[_0x26f687('0x200f')]&&_0x5b2c90[_0x26f687('0x200f')]['calleridnum']?_0x5b2c90[_0x26f687('0x200f')]['calleridnum']:undefined,'queue':_0x5b2c90['call']&&_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x1d3e')]?_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x1d3e')]:undefined,'uniqueid':_0x5b2c90[_0x26f687('0x200f')]&&_0x5b2c90[_0x26f687('0x200f')]['uniqueid']?_0x5b2c90[_0x26f687('0x200f')][_0x26f687('0x1c21')]:undefined,'SessionId':_0x1cbb73['id'],'ProjectId':_0x5b2c90[_0x26f687('0x2588')]['id'],'projectname':_0x5b2c90[_0x26f687('0x2588')]['name']}));}catch(_0x29b2cd){console[_0x26f687('0xfc9')](_0x26f687('0xee7'),_0x29b2cd);}}}}}return _0x1a146e[_0x26f687('0x2760')](_0x45dc0b)[_0x26f687('0x1166')](function(){const _0x9adbfa=_0x26f687;return _0x1a146e['all'](_0x4faa21)[_0x9adbfa('0x1166')](function(){return _0x1cbb73;});});})['then'](function(_0x410257){const _0x810cae=_0x1c6317;_0x410257?_0x13166d[_0x810cae('0x18af')](!![]):_0x13166d[_0x810cae('0x21bf')]();})[_0x1c6317('0x1a80')](function(_0x242abb){const _0x47a761=_0x1c6317;if(_0x242abb[_0x47a761('0x25f4')]&&_0x242abb[_0x47a761('0x25f4')]['errors']&&_0x242abb['data']['errors']['length']){_0x5b2c90[_0x47a761('0x61a')]=_0x242abb[_0x47a761('0x25f4')][_0x47a761('0x61a')]||[{'message':_0x242abb[_0x47a761('0x1586')](),'type':'api.contact.save'}];for(let _0xe7d6ff=0x0;_0xe7d6ff<_0x242abb[_0x47a761('0x25f4')][_0x47a761('0x61a')][_0x47a761('0x264b')];_0xe7d6ff+=0x1){_0x364425['error']({'title':_0x242abb[_0x47a761('0x25f4')][_0x47a761('0x61a')][_0xe7d6ff][_0x47a761('0x1345')],'msg':_0x242abb['data'][_0x47a761('0x61a')][_0xe7d6ff][_0x47a761('0x1e70')]});}}else _0x364425['error']({'title':_0x242abb[_0x47a761('0x52d')]?'API:'+_0x242abb['status']+_0x47a761('0x11e1')+_0x242abb[_0x47a761('0xe1b')]:'api.contact.save','msg':_0x242abb[_0x47a761('0x25f4')]?JSON[_0x47a761('0xbac')](_0x242abb[_0x47a761('0x25f4')][_0x47a761('0x1e70')]):_0x242abb[_0x47a761('0x1586')]()});_0x13166d['reject']();});}function _0x44e0de(_0x11acfe){const _0xd451d1=_0x5a1dea;try{_0x3d4fe7[_0xd451d1('0x23ac')][_0xd451d1('0x23ac')][_0xd451d1('0x23ac')]['vm'][_0xd451d1('0x1b93')](_0x11acfe);}catch(_0x1aca96){_0x364425[_0xd451d1('0xfc9')]({'title':'ERROR\x20REMOVE\x20TAB','msg':_0xd451d1('0x2737')});}}function _0xe2da02(_0x317b50,_0x222685){const _0x2de3fc=_0x5a1dea,_0x16d6b5=_0x1a146e['defer']();if(_0x222685){const _0x31060a=_0x50b32e[_0x2de3fc('0x1d26')]()[_0x2de3fc('0xcdc')](_0x2de3fc('0x1714'))[_0x2de3fc('0x2077')]('')[_0x2de3fc('0x8e8')](_0x2de3fc('0xa'))['targetEvent'](_0x317b50)['ok']('YES')[_0x2de3fc('0x3f')]('NO');_0x50b32e[_0x2de3fc('0x1f80')](_0x31060a)[_0x2de3fc('0x1166')](function(){_0x4f3db6(_0x16d6b5,![]);},function(){_0x16d6b5['resolve']();});}else _0x4f3db6(_0x16d6b5,!![]);return _0x16d6b5[_0x2de3fc('0x1f48')]['then'](function(_0x2a5aea){const _0x581fcd=_0x2de3fc;_0x2a5aea&&(_0x364425[_0x581fcd('0x103b')]({'title':_0x581fcd('0x94e'),'msg':_0x581fcd('0x15f5')}),_0x44e0de(_0x5b2c90[_0x581fcd('0xbe3')]));})[_0x2de3fc('0x1a80')](function(){const _0x590a28=_0x2de3fc;_0x364425[_0x590a28('0xfc9')]({'title':_0x590a28('0x690'),'msg':_0x590a28('0x14a9')});});}function _0x328313(){const _0x10d2e0=_0x5a1dea;return _0x584eea[_0x10d2e0('0xd5f')](_0x5b2c90['project'][_0x10d2e0('0x1ff2')],_0x5b2c90['project'][_0x10d2e0('0x6de')],![]);}function _0x5f052d(){const _0x48bd85=_0x5a1dea;return _0x584eea[_0x48bd85('0x17ea')](_0x5b2c90[_0x48bd85('0x2588')]['formData'],_0x5b2c90['project'][_0x48bd85('0x6de')]);}function _0x25b4f8(){const _0xd65c1f=_0x5a1dea;return _0x584eea[_0xd65c1f('0x1598')](_0x5b2c90['project'][_0xd65c1f('0x1ff2')],![]);}function _0x22c307(){const _0x48b035=_0x5a1dea;return _0x584eea['getQuestionWithResponseList'](_0x5b2c90['project'][_0x48b035('0x1ff2')],_0x5b2c90[_0x48b035('0x2588')][_0x48b035('0x6de')]);}}const _0x3cf98d=_0x3e756a;_0x291bf1[_0x36e6f4('0x1294')]=[_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'notification',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x291bf1(_0x37cda1,_0x1703f9,_0x4012c6,_0x2937ff,_0x27d86f){const _0x56fea8=_0x36e6f4,_0x33ad46=this;_0x33ad46[_0x56fea8('0x10b3')]=_0x4012c6,_0x33ad46[_0x56fea8('0x557')]=_0x27d86f['getCurrentUser']();function _0x1a9b53(){return function(_0x15184b){const _0x46aadb=a0_0x3f2c;if(_0x15184b[_0x46aadb('0x52d')]===0x194)_0x1703f9[_0x46aadb('0x1fa1')]({'title':_0x37cda1[_0x46aadb('0x25cc')](_0x46aadb('0x3d3')),'msg':_0x37cda1[_0x46aadb('0x25cc')](_0x46aadb('0x1e6e'))});else{if(_0x15184b[_0x46aadb('0x25f4')]&&_0x15184b[_0x46aadb('0x25f4')]['errors']&&_0x15184b[_0x46aadb('0x25f4')][_0x46aadb('0x61a')][_0x46aadb('0x264b')]){_0x33ad46[_0x46aadb('0x61a')]=_0x15184b[_0x46aadb('0x25f4')][_0x46aadb('0x61a')]||[{'message':_0x15184b[_0x46aadb('0x1586')](),'type':_0x46aadb('0x253')}];for(let _0x46b427=0x0;_0x46b427<_0x15184b[_0x46aadb('0x25f4')]['errors'][_0x46aadb('0x264b')];_0x46b427+=0x1){_0x1703f9['error']({'title':_0x15184b[_0x46aadb('0x25f4')]['errors'][_0x46b427]['type'],'msg':_0x15184b[_0x46aadb('0x25f4')][_0x46aadb('0x61a')][_0x46b427][_0x46aadb('0x1e70')]});}}else _0x1703f9[_0x46aadb('0xfc9')]({'title':_0x15184b[_0x46aadb('0x52d')]?_0x46aadb('0x1e21')+_0x15184b['status']+_0x46aadb('0x11e1')+_0x15184b[_0x46aadb('0xe1b')]:_0x46aadb('0x253'),'msg':_0x15184b[_0x46aadb('0x25f4')]?JSON[_0x46aadb('0xbac')](_0x15184b['data'][_0x46aadb('0x1e70')]):_0x15184b[_0x46aadb('0x1586')]()});}};}function _0x32162a(){const _0x1bb7ed=_0x56fea8;if(_0x2937ff[_0x33ad46[_0x1bb7ed('0x10b3')][_0x1bb7ed('0x1298')]+_0x1bb7ed('0x1720')])return _0x2937ff[_0x33ad46[_0x1bb7ed('0x10b3')][_0x1bb7ed('0x1298')]+_0x1bb7ed('0x1720')][_0x1bb7ed('0x2384')]({'id':_0x33ad46[_0x1bb7ed('0x10b3')]['id'],'UserId':_0x33ad46['user']['id'],'manual':!![]})['$promise'][_0x1bb7ed('0x1166')](function(){const _0x30281a=_0x1bb7ed;_0x1703f9[_0x30281a('0x103b')]({'title':'Message\x20properly\x20accepted!','msg':_0x30281a('0xfd2')});})[_0x1bb7ed('0x1a80')](_0x1a9b53());else _0x1703f9[_0x1bb7ed('0xfc9')]({'title':'API:ERROR','msg':_0x1bb7ed('0x41b')+_0x33ad46[_0x1bb7ed('0x10b3')][_0x1bb7ed('0x1298')]+_0x1bb7ed('0x1720')});}function _0x54e18c(){const _0x25f90e=_0x56fea8;if(_0x2937ff[_0x33ad46['notification'][_0x25f90e('0x1298')]+'Message'])return _0x2937ff[_0x33ad46[_0x25f90e('0x10b3')]['channel']+'Message'][_0x25f90e('0x21bf')]({'id':_0x33ad46['notification']['id'],'UserId':_0x33ad46[_0x25f90e('0x557')]['id']})['$promise']['then'](function(){const _0x4b62bb=_0x25f90e;_0x1703f9[_0x4b62bb('0x103b')]({'title':_0x4b62bb('0x24e6'),'msg':_0x4b62bb('0x2198')});})[_0x25f90e('0x1a80')](_0x1a9b53());else _0x1703f9[_0x25f90e('0xfc9')]({'title':'API:ERROR','msg':_0x25f90e('0x1cfb')+_0x33ad46[_0x25f90e('0x10b3')][_0x25f90e('0x1298')]+'Message'});}_0x33ad46[_0x56fea8('0x2384')]=_0x32162a,_0x33ad46['reject']=_0x54e18c;}const _0x308100=_0x291bf1;function _0x3f50c5(){const _0x3624f5=_0x36e6f4,_0x3002ef=this;function _0x4cee92(_0x253078){const _0x4766a8=a0_0x3f2c;_0x3002ef['tab']=_0x253078,_0x3002ef[_0x4766a8('0xbe3')]&&(_0x3002ef[_0x4766a8('0xbe3')][_0x4766a8('0x26ae')]=!![],_0x3002ef['html']=_0x3002ef['tab'][_0x4766a8('0x1fe3')]);}_0x3002ef[_0x3624f5('0x24d5')]=_0x4cee92;}const _0x419109=_0x3f50c5,_0x3c7c20=_0x2734b2['p']+_0x36e6f4('0x1012'),_0x1528e1=_0x2734b2['p']+'src/js/modules/main/apps/dashboards/views/general/agent/agent.general.html/agent.general.html';_0x3078e6[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x3078e6(_0x1f9b69){const _0x5d64eb=_0x36e6f4;_0x1f9b69[_0x5d64eb('0x63f')](_0x5d64eb('0x202e'),{'url':_0x5d64eb('0x19e4'),'views':{'content@app':{'templateProvider':[_0x5d64eb('0xf75'),_0x5d64eb('0xd84'),_0x5d64eb('0x21ef'),function(_0x1e1dda,_0x5710c7,_0x300aa3){const _0x387655=_0x5d64eb;return _0x300aa3[_0x387655('0x1d6f')]()?_0x5710c7['fromUrl'](_0x1528e1,_0x1e1dda):_0x5710c7[_0x387655('0x459')](_0x3c7c20,_0x1e1dda);}],'controllerProvider':[_0x5d64eb('0x21ef'),function(_0x5a0bec){const _0x417210=_0x5d64eb;return _0x5a0bec[_0x417210('0x1d6f')]()?_0x417210('0x2033'):_0x417210('0x174e');}]}},'resolve':{'globalUserLists':[_0x5d64eb('0x1fbc'),_0x5d64eb('0x21ef'),function(_0x2d5a0f,_0x452543){const _0x16c9ef=_0x5d64eb;return _0x2d5a0f[_0x16c9ef('0x18af')](_0x16c9ef('0x273f'),{'id':_0x452543['getCurrentUser']()['id'],'sort':_0x16c9ef('0x4f0'),'nolimit':!![]});}],'globalLists':[_0x5d64eb('0x1fbc'),function(_0x5d4893){const _0x417fbb=_0x5d64eb;return _0x5d4893[_0x417fbb('0x18af')](_0x417fbb('0x4ee'),{'sort':_0x417fbb('0x4f0'),'nolimit':!![]});}],'globalTags':[_0x5d64eb('0x1fbc'),function(_0x5f15d8){const _0x37ee3d=_0x5d64eb;return _0x5f15d8[_0x37ee3d('0x18af')](_0x37ee3d('0x1dfc'),{'sort':_0x37ee3d('0x4f0'),'nolimit':!![]});}],'globalCompanies':['apiResolver',function(_0x803070){const _0x21ed4d=_0x5d64eb;return _0x803070['resolve']('cmCompany@get',{'sort':_0x21ed4d('0x4f0'),'nolimit':!![]});}]},'authenticate':!![],'bodyClass':_0x5d64eb('0xc87')});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x202e'),['ngMaterialDateRangePicker',_0x36e6f4('0x6bb')])[_0x36e6f4('0xe11')](_0x3078e6)[_0x36e6f4('0x75e')](_0x36e6f4('0x12d4'),_0x508ce7)[_0x36e6f4('0x87c')](_0x36e6f4('0x102a'),_0x495c1e)[_0x36e6f4('0x1b21')]('desktopNotification',_0x3807c3)[_0x36e6f4('0x1b21')](_0x36e6f4('0x2256'),_0x3d435d)['constant'](_0x36e6f4('0x1c96'),_0x2ac441)[_0x36e6f4('0x75e')]('AgentGeneralBotController',_0x342ae2)[_0x36e6f4('0x75e')](_0x36e6f4('0x130'),_0x425f7b)['controller']('DisposeCallDialogController',_0x1e1ccb)[_0x36e6f4('0x75e')]('RescheduleCallDialogController',_0x341168)['controller'](_0x36e6f4('0x166'),_0x5e407d)['controller'](_0x36e6f4('0xf29'),_0x2daa65)['controller'](_0x36e6f4('0x27ea'),_0x2fe1ea)['controller'](_0x36e6f4('0x2c1'),_0x197a7c)[_0x36e6f4('0x75e')](_0x36e6f4('0x21d2'),_0x5bfe67)[_0x36e6f4('0x75e')](_0x36e6f4('0x25ce'),_0x302c19)['controller'](_0x36e6f4('0x1876'),_0x2bb04f)[_0x36e6f4('0x75e')](_0x36e6f4('0x1f88'),_0x244443)['controller']('AgentHomeDashboardController',_0x2d5616)[_0x36e6f4('0x75e')](_0x36e6f4('0x1639'),_0x2771d0)[_0x36e6f4('0x75e')](_0x36e6f4('0x16c8'),_0x2ed108)['controller'](_0x36e6f4('0x16d8'),_0x35fc53)['controller'](_0x36e6f4('0xa16'),_0x57e4aa)[_0x36e6f4('0x75e')]('AgentHomeDashboardMultiChannelOpenchannelController',_0x26f3a0)[_0x36e6f4('0x75e')](_0x36e6f4('0x2442'),_0x532aa9)[_0x36e6f4('0x75e')](_0x36e6f4('0x289d'),_0x52f2b9)[_0x36e6f4('0x75e')](_0x36e6f4('0x2758'),_0x4e9482)[_0x36e6f4('0x75e')](_0x36e6f4('0x685'),_0x19cca7)[_0x36e6f4('0x75e')](_0x36e6f4('0x2ba'),_0x547a09)[_0x36e6f4('0x75e')](_0x36e6f4('0x769'),_0x1d2614)[_0x36e6f4('0x75e')]('AgentHomeOpenchannelController',_0x4ac074)[_0x36e6f4('0x75e')]('AgentHomePluginsController',_0x2d27a7)['controller'](_0x36e6f4('0x841'),_0x40329e)['controller'](_0x36e6f4('0x2312'),_0x15dbdd)[_0x36e6f4('0x75e')](_0x36e6f4('0x27a5'),_0x38b10c)['controller']('AgentHomeVoiceController',_0x3a958a)[_0x36e6f4('0x75e')](_0x36e6f4('0x171c'),_0x2f7c12)['controller'](_0x36e6f4('0x21f8'),_0x1861c9)[_0x36e6f4('0x75e')](_0x36e6f4('0x1519'),_0x146ac5)[_0x36e6f4('0x22e6')]('ngBindHtmlUnsafe',_0x40b913)['filter'](_0x36e6f4('0xf0e'),_0x1b98ef)[_0x36e6f4('0x75e')](_0x36e6f4('0x19ad'),_0x41517a)[_0x36e6f4('0x87c')](_0x36e6f4('0x819'),_0xdf42ab)[_0x36e6f4('0x75e')]('ComposeFaxInteractionDialogController',_0x211cbe)['controller'](_0x36e6f4('0x2709'),_0x5a0f7b)[_0x36e6f4('0x75e')](_0x36e6f4('0x1416'),_0x4068f3)['controller'](_0x36e6f4('0xd15'),_0x58ca6c)[_0x36e6f4('0x75e')](_0x36e6f4('0xa2e'),_0x440eb1)[_0x36e6f4('0x75e')](_0x36e6f4('0xa39'),_0x1f78af)['controller']('TagInteractionDialogController',_0x464c1b)[_0x36e6f4('0x75e')](_0x36e6f4('0xf6a'),_0x2529b2)[_0x36e6f4('0x75e')](_0x36e6f4('0x34'),_0x3cf98d)['controller'](_0x36e6f4('0x611'),_0x308100)[_0x36e6f4('0x75e')](_0x36e6f4('0x1877'),_0x419109);const _0x1684e9=_0x2734b2['p']+_0x36e6f4('0x1b53');_0x54506a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x10eb'),_0x36e6f4('0x36f'),_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x21ef'),_0x36e6f4('0x20fd'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa')];function _0x54506a(_0x20a662,_0x5740d0,_0x1baa42,_0x5dcda4,_0x909277,_0x2fbdd9,_0x4e985c,_0x319177,_0x4a1475){const _0x1edc40=_0x36e6f4,_0xdd0eb4=this;_0xdd0eb4[_0x1edc40('0x98')]=_0x2fbdd9['getCurrentUser'](),_0xdd0eb4['userProfile']=_0x319177,_0xdd0eb4['userProfileSection']=_0x4a1475&&_0x4a1475[_0x1edc40('0x240f')]==0x1?_0x4a1475['rows'][0x0]:null,_0xdd0eb4[_0x1edc40('0x243c')]=_0x2fbdd9[_0x1edc40('0xd87')](_0xdd0eb4[_0x1edc40('0x17aa')]?_0xdd0eb4['userProfileSection'][_0x1edc40('0x243c')]:null),_0xdd0eb4['customDashboard']={},_0xdd0eb4[_0x1edc40('0x20fd')]=_0x4e985c&&_0x4e985c[_0x1edc40('0x240f')]?_0x4e985c:{'count':0x0,'rows':[]},_0xdd0eb4[_0x1edc40('0xe15')]=_0x4e985c&&_0x4e985c[_0x1edc40('0x240f')]?_0x2cfb05()[_0x1edc40('0x2563')](_0x4e985c[_0x1edc40('0x269a')],'id'):[],_0xdd0eb4[_0x1edc40('0x277c')]=_0x5740d0(function(){},0x3e8),_0xdd0eb4['onChangeVoiceQueues']=_0xf49494,_0xdd0eb4[_0x1edc40('0x25fa')]=_0x26efa0,_0x909277['onWithoutApply']('voice_queue:save',_0x2791e1),_0x5dcda4[_0x1edc40('0xba2')]['get']({'id':_0x20a662[_0x1edc40('0x23f')]['id']})['$promise'][_0x1edc40('0x1166')](function(_0x2d1c1f){const _0x556b64=_0x1edc40;if(_0x2d1c1f)return _0xdd0eb4['customDashboard']=_0x2d1c1f,_0xdd0eb4[_0x556b64('0x5a8')]['widgets']=[],_0xdd0eb4['customDashboard'][_0x556b64('0x1b37')]=!![],_0xdd0eb4[_0x556b64('0x5a8')]['draggable']={'enabled':![]},_0xdd0eb4[_0x556b64('0x5a8')][_0x556b64('0x2273')]={'enabled':![]},_0x5dcda4[_0x556b64('0xba2')]['getItems']({'id':_0xdd0eb4[_0x556b64('0x5a8')]['id']})['$promise'];})['then'](function(_0xe62f68){const _0x5da274=_0x1edc40;if(_0xe62f68&&_0xe62f68[_0x5da274('0x240f')]&&_0xe62f68[_0x5da274('0x269a')])for(let _0x11f4cc=0x0;_0x11f4cc<_0xe62f68[_0x5da274('0x269a')][_0x5da274('0x264b')];_0x11f4cc+=0x1){_0xe62f68[_0x5da274('0x269a')][_0x11f4cc][_0x5da274('0x12a8')]=_0x5da274('0x1cf0')+_0xe62f68['rows'][_0x11f4cc][_0x5da274('0x1345')]+_0x5da274('0x1299')+_0xe62f68[_0x5da274('0x269a')][_0x11f4cc]['type']+'.html',_0xe62f68['rows'][_0x11f4cc][_0x5da274('0x20fd')]=_0xdd0eb4[_0x5da274('0x20fd')],_0xe62f68[_0x5da274('0x269a')][_0x11f4cc][_0x5da274('0xe15')]=_0xdd0eb4[_0x5da274('0xe15')],_0xdd0eb4[_0x5da274('0x5a8')][_0x5da274('0x135')][_0x5da274('0x1514')](_0xe62f68[_0x5da274('0x269a')][_0x11f4cc]);}})[_0x1edc40('0x1a80')](function(){const _0x3a27d5=_0x1edc40;_0xdd0eb4[_0x3a27d5('0x5a8')]=undefined;});function _0x2791e1(_0x4d7d12){const _0x43566b=_0x1edc40,_0x2fb35a=_0x2cfb05()[_0x43566b('0xc38')](_0xdd0eb4['voiceQueues']['rows'],{'id':_0x4d7d12['id']});_0x2fb35a&&_0x2cfb05()[_0x43566b('0xcc3')](_0x2fb35a,_0x2cfb05()['pick'](_0x4d7d12,_0x2cfb05()[_0x43566b('0x14a4')](_0x2fb35a)));}function _0xf49494(){const _0x2ac297=_0x1edc40;for(let _0x3111b9=0x0;_0x3111b9<_0xdd0eb4['customDashboard'][_0x2ac297('0x135')][_0x2ac297('0x264b')];_0x3111b9+=0x1){_0xdd0eb4['customDashboard'][_0x2ac297('0x135')][_0x3111b9][_0x2ac297('0xe15')]=_0xdd0eb4['voiceQueuesSelected'];}}function _0x26efa0(){const _0x31df90=_0x1edc40;_0x20a662['go']('app.tools.customDashboards.edit',{'id':_0xdd0eb4[_0x31df90('0x5a8')]['id'],'tab':0x1});}_0x1baa42[_0x1edc40('0x3d2')](_0x1edc40('0x1c3f'),function(){const _0x5ec649=_0x1edc40;_0x909277[_0x5ec649('0x1800')](_0x5ec649('0xa60')),_0xdd0eb4[_0x5ec649('0x277c')]&&_0x5740d0[_0x5ec649('0x3f')](_0xdd0eb4['interval']);});}const _0x1eaffb=_0x54506a;_0x5c4648[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x5c4648(_0x5c00ce){const _0x146f8b=_0x36e6f4;_0x5c00ce[_0x146f8b('0x63f')](_0x146f8b('0x20d7'),{'url':'/custom/:id','views':{'content@app':{'templateUrl':_0x1684e9,'controller':_0x146f8b('0x673')}},'resolve':{'voiceQueues':[_0x146f8b('0x1fbc'),_0x146f8b('0x21ef'),function(_0x32c8d3,_0x553caf){const _0x1caadb=_0x146f8b;let _0xfeb159;const _0x1f408e=_0x553caf[_0x1caadb('0x1ac6')]('admin')?_0x32c8d3[_0x1caadb('0x18af')](_0x1caadb('0x2700'),{'fields':_0x1caadb('0x1776'),'nolimit':!![]}):_0x32c8d3['resolve']('userProfile@getResources',{'id':_0x553caf[_0x1caadb('0x26cd')]()[_0x1caadb('0xb86')],'section':_0x1caadb('0x1ba2'),'mergeResources':!![],'fields':_0x1caadb('0x1776'),'channel':_0x1caadb('0x21da'),'nolimit':!![]});return _0x1f408e[_0x1caadb('0x1166')](function(_0x5aa302){const _0x1ec1fa=_0x1caadb;return _0xfeb159=_0x5aa302,_0x32c8d3[_0x1ec1fa('0x18af')](_0x1ec1fa('0x85d'));})['then'](function(_0x59c22a){const _0x5e9784=_0x1caadb;if(_0x59c22a)for(let _0x28c505=0x0,_0x2aa2c3;_0x28c505<_0x59c22a[_0x5e9784('0x269a')][_0x5e9784('0x264b')];_0x28c505+=0x1){_0x2aa2c3=_0x2cfb05()[_0x5e9784('0xc38')](_0xfeb159[_0x5e9784('0x269a')],{'id':_0x59c22a[_0x5e9784('0x269a')][_0x28c505]['id']}),_0x2aa2c3&&_0x2cfb05()[_0x5e9784('0xcc3')](_0x2aa2c3,_0x2cfb05()['pick'](_0x59c22a[_0x5e9784('0x269a')][_0x28c505],[_0x5e9784('0x288a'),'total','talking',_0x5e9784('0x13d'),'unmanaged','abandoned']));}return _0xfeb159;});}],'userProfile':['apiResolver',_0x146f8b('0x21ef'),function(_0x3c06f7,_0x542083){const _0x3dc922=_0x146f8b;return _0x3c06f7[_0x3dc922('0x18af')](_0x3dc922('0x697'),{'fields':_0x3dc922('0x686'),'id':_0x542083[_0x3dc922('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x146f8b('0x1fbc'),'Auth',function(_0x290444,_0x301804){const _0x56cec3=_0x146f8b;return _0x290444[_0x56cec3('0x18af')]('userProfileSection@get',{'fields':_0x56cec3('0xe26'),'userProfileId':_0x301804['getCurrentUser']()['userProfileId'],'sectionId':0x64});}]},'authenticate':!![],'bodyClass':'dashboards'});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x20d7'),[])[_0x36e6f4('0xe11')](_0x5c4648)[_0x36e6f4('0x75e')](_0x36e6f4('0x23ea'),_0x1eaffb),_0x3345fc[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),'$translatePartialLoaderProvider'];function _0x3345fc(_0x13ab7e,_0xa0ca9b){const _0x3d2d5e=_0x36e6f4;_0x13ab7e[_0x3d2d5e('0x63f')](_0x3d2d5e('0x6a1'),{'abstract':!![],'url':_0x3d2d5e('0xa85')}),_0xa0ca9b[_0x3d2d5e('0x95e')]('app/main/apps/dashboards');}angular[_0x36e6f4('0x896')]('app.dashboards',[_0x36e6f4('0x441'),'ngPassword',_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),'mdColorPicker',_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),'mwFormViewer','mwFormUtils',_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),'chart.js',_0x36e6f4('0x411'),_0x36e6f4('0x202e'),_0x36e6f4('0x20d7')])[_0x36e6f4('0xe11')](_0x3345fc);const _0x45d8ae=_0x2734b2['p']+_0x36e6f4('0x11ed'),_0x4b83e4=_0x2734b2['p']+'src/js/modules/main/apps/staff/views/agents/create/dialog.html/dialog.html';_0x5081ce[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'agents','userProfile',_0x36e6f4('0x17aa'),'api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x5081ce(_0x475350,_0x1f0f5f,_0x4f49cd,_0x3d804b,_0x2617be,_0x1a509c,_0x39b6c9,_0x31190d,_0x3a60a4,_0x380b0f,_0x2acdb3,_0x8258b6,_0x355f5c,_0x39e0e7,_0x145368,_0x5f263d,_0xd65f70){const _0x124116=_0x36e6f4,_0x12dc81=this;_0x12dc81[_0x124116('0x5c9')]=_0x5f263d,_0x12dc81[_0x124116('0xf8a')]=_0xd65f70,_0x12dc81[_0x124116('0x98')]=_0x145368[_0x124116('0x26cd')](),_0x12dc81[_0x124116('0x1f7e')]=_0x3a60a4||{'count':0x0,'rows':[]},_0x12dc81[_0x124116('0x7f')]=_0x380b0f,_0x12dc81['userProfileSection']=_0x2acdb3&&_0x2acdb3['count']==0x1?_0x2acdb3[_0x124116('0x269a')][0x0]:null,_0x12dc81[_0x124116('0x243c')]=_0x145368[_0x124116('0xd87')](_0x12dc81[_0x124116('0x17aa')]?_0x12dc81['userProfileSection']['crudPermissions']:null),_0x12dc81['table']=_0x124116('0x1f7e'),_0x12dc81[_0x124116('0xef5')]='',_0x12dc81[_0x124116('0x104c')]=null,_0x12dc81[_0x124116('0x2158')]=[],_0x12dc81[_0x124116('0x2218')]={'fields':_0x124116('0x58b'),'role':_0x124116('0x1eff'),'sort':_0x124116('0x14dc'),'limit':0xa,'page':0x1},_0x12dc81['arrayshowWebBar']=_0x2cfb05()[_0x124116('0x155c')]([{'option':'Phonebar','value':'0'},{'option':_0x124116('0x1a41'),'value':'1'},{'option':_0x124116('0x1426'),'value':'2'}],function(_0x13b66a){const _0x224742=_0x124116;return _0x2cfb05()[_0x224742('0xf3')](_0x13b66a['value'],new RegExp('\x27','g'),'');}),_0x12dc81[_0x124116('0x1170')]=_0x2cfb05()[_0x124116('0x155c')]([{'option':_0x124116('0x8fc'),'value':_0x124116('0xc29')},{'option':'tcp','value':_0x124116('0x1d5e')},{'option':'ws','value':_0x124116('0x1eb6'),'ngIf':_0x124116('0x24f6')},{'option':'wss','value':'\x27wss\x27','ngIf':_0x124116('0x24f6')},{'option':'tls','value':_0x124116('0x1db6'),'ngIf':_0x124116('0x24f6')}],function(_0x16a247){const _0x35d342=_0x124116;return _0x2cfb05()['replace'](_0x16a247[_0x35d342('0x18e0')],new RegExp('\x27','g'),'');}),_0x12dc81[_0x124116('0x1c9')]=_0x2cfb05()['keyBy']([{'option':_0x124116('0x976'),'value':'\x27force_rport\x27'},{'option':_0x124116('0x232d'),'value':'\x27comedia\x27'},{'option':_0x124116('0x55d'),'value':_0x124116('0x20b3')},{'option':'no','value':'\x27no\x27'},{'option':_0x124116('0x122f'),'value':_0x124116('0x130c')},{'option':_0x124116('0x16a8'),'value':_0x124116('0x1375')}],function(_0x173861){const _0x4f07d8=_0x124116;return _0x2cfb05()[_0x4f07d8('0xf3')](_0x173861[_0x4f07d8('0x18e0')],new RegExp('\x27','g'),'');}),_0x12dc81[_0x124116('0x2736')]=_0x2cfb05()[_0x124116('0x155c')]([{'option':_0x124116('0x542'),'value':_0x124116('0x1d41')},{'option':_0x124116('0x1a6f'),'value':_0x124116('0x247a')},{'option':'Peer','value':_0x124116('0xcb3')}],function(_0x352b1e){const _0x36e7cf=_0x124116;return _0x2cfb05()[_0x36e7cf('0xf3')](_0x352b1e['value'],new RegExp('\x27','g'),'');}),_0x12dc81['arrayallow']=_0x2cfb05()['keyBy']([{'option':_0x124116('0x1838'),'value':_0x124116('0x166f')},{'option':_0x124116('0x157'),'value':_0x124116('0x1573')},{'option':_0x124116('0x1cd9'),'value':_0x124116('0xd74')},{'option':_0x124116('0x27f0'),'value':_0x124116('0x1ae2')},{'option':_0x124116('0x19b7'),'value':_0x124116('0x48d')},{'option':_0x124116('0x1f1d'),'value':_0x124116('0x1fbd')},{'option':_0x124116('0x173a'),'value':_0x124116('0x2398')}],function(_0x43f689){const _0x37eca4=_0x124116;return _0x2cfb05()[_0x37eca4('0xf3')](_0x43f689[_0x37eca4('0x18e0')],new RegExp('\x27','g'),'');}),_0x12dc81[_0x124116('0x1f32')]=_0x2cfb05()[_0x124116('0x155c')]([{'option':'Yes','value':_0x124116('0x20b3')},{'option':'No','value':_0x124116('0x119b')},{'option':'Always','value':_0x124116('0x312')}],function(_0x2c394d){const _0x326b8b=_0x124116;return _0x2cfb05()[_0x326b8b('0xf3')](_0x2c394d[_0x326b8b('0x18e0')],new RegExp('\x27','g'),'');}),_0x12dc81[_0x124116('0xc16')]=_0x2cfb05()[_0x124116('0x155c')]([{'option':_0x124116('0x1882'),'value':'\x27\x27'},{'option':_0x124116('0xdef'),'value':_0x124116('0x91c')},{'option':'wav49','value':'\x27WAV\x27'},{'option':_0x124116('0x1cd9'),'value':'\x27gsm\x27'}],function(_0x2d5aaa){const _0x42f94c=_0x124116;return _0x2cfb05()[_0x42f94c('0xf3')](_0x2d5aaa['value'],new RegExp('\x27','g'),'');}),_0x12dc81[_0x124116('0x1ff6')]=_0x222868,_0x12dc81[_0x124116('0x292')]=_0x1905c0,_0x12dc81['deleteconfirm']=_0x3fca8b,_0x12dc81[_0x124116('0x103b')]=_0xbcbf83,_0x12dc81[_0x124116('0x261c')]=_0x510747,_0x12dc81['createOrEditAgent']=_0x768f6d,_0x12dc81[_0x124116('0x396')]=_0x22a9a5,_0x12dc81[_0x124116('0xd99')]=_0x5b81e6,_0x12dc81[_0x124116('0x1e60')]=_0xfbcd0b,_0x12dc81[_0x124116('0x1b9b')]=_0x31ced9,_0x12dc81['selectAllAgents']=_0x249d40;function _0x222868(_0x4bd203){const _0x2b3b83=_0x124116;_0x4f49cd['go'](_0x2b3b83('0x1583'),{'id':_0x4bd203['id'],'agent':_0x4bd203,'crudPermissions':_0x12dc81[_0x2b3b83('0x243c')]});}function _0x1905c0(_0x4a74f3,_0x281e9a){const _0x11f129=_0x124116;_0x2617be[_0x11f129('0x1f80')]({'controller':_0x11f129('0xd4b'),'controllerAs':'vm','templateUrl':_0x45d8ae,'parent':angular['element'](_0x1a509c[_0x11f129('0x8d2')]),'targetEvent':_0x281e9a,'clickOutsideToClose':!![],'locals':{'agent':_0x4a74f3,'agents':_0x12dc81[_0x11f129('0x1f7e')]?_0x12dc81['agents']['rows']:[],'crudPermissions':_0x12dc81['crudPermissions']}});}function _0x3fca8b(_0x6774e3,_0x5ee475){const _0x3447bb=_0x124116,_0x398639=_0x2617be['confirm']()[_0x3447bb('0xcdc')](_0x3447bb('0x288d')+_0x2cfb05()['startCase'](_0x3447bb('0x1eff'))+'?')['htmlContent'](_0x3447bb('0x12b5')+(_0x6774e3[_0x3447bb('0x4f0')]||_0x3447bb('0x1eff'))+_0x3447bb('0xace')+_0x3447bb('0x3f3'))['ariaLabel'](_0x3447bb('0x1153'))[_0x3447bb('0x203b')](_0x5ee475)['ok']('OK')[_0x3447bb('0x3f')](_0x3447bb('0x2d3'));_0x2617be['show'](_0x398639)[_0x3447bb('0x1166')](function(){_0x22a9a5(_0x6774e3);},function(){const _0x1e3205=_0x3447bb;console['log'](_0x1e3205('0x2d3'));});}let _0xaf6dcf=!![],_0x5bba33=0x1;_0x475350[_0x124116('0xe83')](_0x124116('0x12d8'),function(_0x1ec860,_0x5b612c){const _0x4370bb=_0x124116;_0xaf6dcf?_0x39b6c9(function(){_0xaf6dcf=![];}):(!_0x5b612c&&(_0x5bba33=_0x12dc81[_0x4370bb('0x2218')][_0x4370bb('0x1a43')]),_0x1ec860!==_0x5b612c&&(_0x12dc81[_0x4370bb('0x2218')][_0x4370bb('0x1a43')]=0x1),!_0x1ec860&&(_0x12dc81[_0x4370bb('0x2218')]['page']=_0x5bba33),_0x12dc81['getAgents']());});function _0xbcbf83(_0x4f7a28){const _0x66c5a2=_0x124116;_0x12dc81[_0x66c5a2('0x1f7e')]=_0x4f7a28||{'count':0x0,'rows':[]};}function _0x510747(){const _0x569a55=_0x124116;_0x12dc81[_0x569a55('0x2218')]['offset']=(_0x12dc81[_0x569a55('0x2218')][_0x569a55('0x1a43')]-0x1)*_0x12dc81[_0x569a55('0x2218')][_0x569a55('0x163f')],_0x145368[_0x569a55('0x1ac6')](_0x569a55('0xa7c'))?_0x12dc81[_0x569a55('0x1f48')]=_0x8258b6[_0x569a55('0x557')][_0x569a55('0xd83')](_0x12dc81['query'],_0xbcbf83)[_0x569a55('0xa44')]:(_0x12dc81[_0x569a55('0x2218')]['id']=_0x12dc81[_0x569a55('0x7f')]['id'],_0x12dc81[_0x569a55('0x2218')][_0x569a55('0xe60')]=_0x569a55('0x2391'),_0x12dc81[_0x569a55('0x1f48')]=_0x8258b6[_0x569a55('0x7f')]['getResources'](_0x12dc81['query'],_0xbcbf83)[_0x569a55('0xa44')]);}function _0x768f6d(_0x45cc51,_0x40e04d){const _0x482636=_0x124116;_0x2617be[_0x482636('0x1f80')]({'controller':_0x482636('0xc04'),'controllerAs':'vm','templateUrl':_0x4b83e4,'parent':angular['element'](_0x1a509c['body']),'targetEvent':_0x45cc51,'clickOutsideToClose':!![],'locals':{'agent':_0x40e04d,'agents':_0x12dc81[_0x482636('0x1f7e')][_0x482636('0x269a')],'license':_0x12dc81[_0x482636('0x5c9')],'setting':_0x12dc81['setting'],'crudPermissions':_0x12dc81[_0x482636('0x243c')]}});}function _0x22a9a5(_0x4c50da){const _0x3b2281=_0x124116;_0x8258b6[_0x3b2281('0x557')]['delete']({'id':_0x4c50da['id']})['$promise'][_0x3b2281('0x1166')](function(){const _0x1350ff=_0x3b2281;_0x2cfb05()[_0x1350ff('0x127f')](_0x12dc81[_0x1350ff('0x1f7e')]['rows'],{'id':_0x4c50da['id']}),_0x12dc81[_0x1350ff('0x1f7e')][_0x1350ff('0x240f')]-=0x1,!_0x12dc81[_0x1350ff('0x1f7e')][_0x1350ff('0x269a')][_0x1350ff('0x264b')]&&_0x12dc81['getAgents'](),_0x39e0e7[_0x1350ff('0x103b')]({'title':_0x2cfb05()[_0x1350ff('0xb35')](_0x1350ff('0x89b'))+'\x20deleted!','msg':_0x4c50da[_0x1350ff('0x4f0')]?_0x4c50da[_0x1350ff('0x4f0')]+_0x1350ff('0x7cd'):''});})[_0x3b2281('0x1a80')](function(_0x2fe99f){const _0x1ce847=_0x3b2281;if(_0x2fe99f['data']&&_0x2fe99f[_0x1ce847('0x25f4')][_0x1ce847('0x61a')]&&_0x2fe99f[_0x1ce847('0x25f4')][_0x1ce847('0x61a')][_0x1ce847('0x264b')]){_0x12dc81[_0x1ce847('0x61a')]=_0x2fe99f['data'][_0x1ce847('0x61a')]||[{'message':_0x2fe99f['toString'](),'type':'SYSTEM:DELETEuser'}];for(let _0x3ece0e=0x0;_0x3ece0e<_0x2fe99f[_0x1ce847('0x25f4')]['errors'][_0x1ce847('0x264b')];_0x3ece0e++){_0x39e0e7['error']({'title':_0x2fe99f[_0x1ce847('0x25f4')][_0x1ce847('0x61a')][_0x3ece0e]['type'],'msg':_0x2fe99f['data'][_0x1ce847('0x61a')][_0x3ece0e][_0x1ce847('0x1e70')]});}}else _0x39e0e7['error']({'title':_0x2fe99f['status']?_0x1ce847('0x1e21')+_0x2fe99f[_0x1ce847('0x52d')]+'\x20-\x20'+_0x2fe99f[_0x1ce847('0xe1b')]:'SYSTEM:DELETEuser','msg':_0x2fe99f[_0x1ce847('0x25f4')]?JSON[_0x1ce847('0xbac')](_0x2fe99f[_0x1ce847('0x25f4')][_0x1ce847('0x1e70')]):_0x2fe99f[_0x1ce847('0x1e70')]||_0x2fe99f['toString']()});});}function _0x5b81e6(){const _0x25f79e=_0x124116,_0x44714e=angular[_0x25f79e('0x225f')](_0x12dc81[_0x25f79e('0x2158')]);return _0x12dc81['selectedAgents']=[],_0x44714e;}function _0xfbcd0b(_0x5d7ece){const _0xe7dba8=_0x124116,_0x53904f=_0x2617be['confirm']()[_0xe7dba8('0xcdc')](_0xe7dba8('0xde9'))[_0xe7dba8('0xf3c')](''+_0x12dc81[_0xe7dba8('0x2158')][_0xe7dba8('0x264b')]+_0xe7dba8('0x196d')+_0xe7dba8('0x3f3'))[_0xe7dba8('0x8e8')]('delete\x20Agents')[_0xe7dba8('0x203b')](_0x5d7ece)['ok']('OK')[_0xe7dba8('0x3f')](_0xe7dba8('0x2d3'));_0x2617be[_0xe7dba8('0x1f80')](_0x53904f)[_0xe7dba8('0x1166')](function(){const _0x5a5a00=_0xe7dba8;_0x12dc81['selectedAgents'][_0x5a5a00('0x2782')](function(_0x190644){_0x22a9a5(_0x190644);}),_0x12dc81[_0x5a5a00('0x2158')]=[];});}function _0x31ced9(){const _0x4db441=_0x124116;_0x12dc81[_0x4db441('0x2158')]=[];}function _0x249d40(){const _0x465b5a=_0x124116;_0x12dc81[_0x465b5a('0x2158')]=_0x12dc81[_0x465b5a('0x1f7e')]['rows'];}}const _0x4b6ee6=_0x5081ce;_0x458abf[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x1f7e'),_0x36e6f4('0x1eff'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x458abf(_0x52e9c4,_0x7fe5d,_0x5e8c5e,_0xa78885,_0x304c37,_0x246307,_0x3b8c35,_0x390c4f,_0x1a86d0,_0x2f00a1,_0x537fc8,_0x52a5fe,_0x2daaca,_0x5b644c){const _0x288584=_0x36e6f4,_0x3f51b1=this;_0x3f51b1[_0x288584('0x98')]=_0x537fc8[_0x288584('0x26cd')](),_0x3f51b1[_0x288584('0x61a')]=[],_0x3f51b1['setting']=_0x2daaca,_0x3f51b1[_0x288584('0x5c9')]=_0x52a5fe,_0x3f51b1[_0x288584('0x243c')]=_0x5b644c,_0x3f51b1[_0x288584('0x128b')]={},_0x3f51b1[_0x288584('0x2900')]=_0x3f51b1['setting']&&_0x3f51b1[_0x288584('0xf8a')][_0x288584('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3f51b1['title']=_0x288584('0xca7'),_0x3f51b1['agent']=angular[_0x288584('0x225f')](_0x1a86d0),_0x3f51b1[_0x288584('0x1f7e')]=_0x390c4f,_0x3f51b1[_0x288584('0x6b7')]=![];!_0x3f51b1[_0x288584('0x1eff')]&&(_0x3f51b1[_0x288584('0x1eff')]={'role':_0x288584('0x1eff'),'showWebBar':'0','autointernal':!![],'type':'friend','context':_0x288584('0xb31'),'phoneBarRemoteControl':!![],'phoneBarRemoteControlPort':0x26a0,'allowmessenger':!![]},_0x3f51b1[_0x288584('0xcdc')]='STAFF.NEW_AGENT',_0x3f51b1[_0x288584('0x6b7')]=!![]);_0x3f51b1[_0x288584('0x71c')]=_0x26da6f,_0x3f51b1['saveAgent']=_0x31fea2,_0x3f51b1['deleteAgent']=_0x48e450,_0x3f51b1[_0x288584('0x1a9c')]=_0x12ce7d,_0x3f51b1[_0x288584('0x24a0')]=_0x1d2f77;function _0x26da6f(){const _0x5a1cdc=_0x288584;_0x3f51b1[_0x5a1cdc('0x61a')]=[],_0x2f00a1[_0x5a1cdc('0x557')][_0x5a1cdc('0x9cc')](_0x3f51b1['agent'])[_0x5a1cdc('0xa44')][_0x5a1cdc('0x1166')](function(_0x43f4c2){const _0x478fec=_0x5a1cdc;_0x3f51b1[_0x478fec('0x1f7e')][_0x478fec('0x2450')](_0x43f4c2['toJSON']()),_0x3b8c35[_0x478fec('0x103b')]({'title':'Agent\x20properly\x20created','msg':_0x3f51b1[_0x478fec('0x1eff')][_0x478fec('0x4f0')]?_0x3f51b1[_0x478fec('0x1eff')][_0x478fec('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x1d2f77(_0x43f4c2);})[_0x5a1cdc('0x1a80')](function(_0x4fbc72){const _0x36900a=_0x5a1cdc;if(_0x4fbc72[_0x36900a('0x25f4')]&&_0x4fbc72['data']['errors']&&_0x4fbc72[_0x36900a('0x25f4')][_0x36900a('0x61a')][_0x36900a('0x264b')]){_0x3f51b1[_0x36900a('0x61a')]=_0x4fbc72['data'][_0x36900a('0x61a')]||[{'message':_0x4fbc72[_0x36900a('0x1586')](),'type':_0x36900a('0xe5d')}];for(let _0x5774ff=0x0;_0x5774ff<_0x4fbc72['data']['errors']['length'];_0x5774ff+=0x1){_0x3b8c35[_0x36900a('0xfc9')]({'title':_0x4fbc72[_0x36900a('0x25f4')][_0x36900a('0x61a')][_0x5774ff][_0x36900a('0x1345')],'msg':_0x4fbc72[_0x36900a('0x25f4')][_0x36900a('0x61a')][_0x5774ff]['message']});}}else _0x3b8c35[_0x36900a('0xfc9')]({'title':_0x4fbc72[_0x36900a('0x52d')]?_0x36900a('0x1e21')+_0x4fbc72[_0x36900a('0x52d')]+_0x36900a('0x11e1')+_0x4fbc72[_0x36900a('0xe1b')]:_0x36900a('0xe5d'),'msg':_0x4fbc72[_0x36900a('0x25f4')]?JSON[_0x36900a('0xbac')](_0x4fbc72[_0x36900a('0x25f4')][_0x36900a('0x1e70')]):_0x4fbc72['toString']()});});}function _0x31fea2(){const _0x23f024=_0x288584;_0x3f51b1['errors']=[],_0x2f00a1['user'][_0x23f024('0x1449')]({'id':_0x3f51b1[_0x23f024('0x1eff')]['id']},_0x3f51b1[_0x23f024('0x1eff')])[_0x23f024('0xa44')]['then'](function(_0x51c039){const _0x2b7e87=_0x23f024,_0x3f362a=_0x2cfb05()[_0x2b7e87('0xc38')](_0x3f51b1[_0x2b7e87('0x1f7e')],{'id':_0x51c039['id']});_0x3f362a&&_0x2cfb05()[_0x2b7e87('0xcc3')](_0x3f362a,_0x2cfb05()[_0x2b7e87('0x1a08')](_0x51c039[_0x2b7e87('0x2876')](),_0x2cfb05()['keys'](_0x3f362a))),_0x3b8c35[_0x2b7e87('0x103b')]({'title':_0x2b7e87('0x1da8'),'msg':_0x3f51b1['agent'][_0x2b7e87('0x4f0')]?_0x3f51b1[_0x2b7e87('0x1eff')]['name']+_0x2b7e87('0x7d'):''}),_0x1d2f77(_0x51c039);})[_0x23f024('0x1a80')](function(_0x1d0c6f){const _0x3d89f0=_0x23f024;if(_0x1d0c6f[_0x3d89f0('0x25f4')]&&_0x1d0c6f[_0x3d89f0('0x25f4')][_0x3d89f0('0x61a')]&&_0x1d0c6f[_0x3d89f0('0x25f4')][_0x3d89f0('0x61a')]['length']){_0x3f51b1[_0x3d89f0('0x61a')]=_0x1d0c6f['data']['errors']||[{'message':_0x1d0c6f[_0x3d89f0('0x1586')](),'type':_0x3d89f0('0x1103')}];for(let _0x5b4fff=0x0;_0x5b4fff<_0x1d0c6f[_0x3d89f0('0x25f4')][_0x3d89f0('0x61a')]['length'];_0x5b4fff++){_0x3b8c35['error']({'title':_0x1d0c6f[_0x3d89f0('0x25f4')][_0x3d89f0('0x61a')][_0x5b4fff][_0x3d89f0('0x1345')],'msg':_0x1d0c6f[_0x3d89f0('0x25f4')][_0x3d89f0('0x61a')][_0x5b4fff]['message']});}}else _0x3b8c35[_0x3d89f0('0xfc9')]({'title':_0x1d0c6f[_0x3d89f0('0x52d')]?_0x3d89f0('0x1e21')+_0x1d0c6f[_0x3d89f0('0x52d')]+_0x3d89f0('0x11e1')+_0x1d0c6f[_0x3d89f0('0xe1b')]:_0x3d89f0('0x1103'),'msg':_0x1d0c6f[_0x3d89f0('0x25f4')]?JSON['stringify'](_0x1d0c6f[_0x3d89f0('0x25f4')][_0x3d89f0('0x1e70')]):_0x1d0c6f[_0x3d89f0('0x1586')]()});});}function _0x48e450(_0x5b0072){const _0x4cb8fe=_0x288584;_0x3f51b1['errors']=[];const _0xed83ae=_0xa78885[_0x4cb8fe('0x1d26')]()[_0x4cb8fe('0xcdc')](_0x4cb8fe('0x7fb'))[_0x4cb8fe('0xacc')]('The\x20agent\x20will\x20be\x20deleted.')['ariaLabel'](_0x4cb8fe('0xbed'))['ok'](_0x4cb8fe('0x18'))[_0x4cb8fe('0x3f')](_0x4cb8fe('0x497'))[_0x4cb8fe('0x203b')](_0x5b0072);_0xa78885[_0x4cb8fe('0x1f80')](_0xed83ae)[_0x4cb8fe('0x1166')](function(){const _0x2d1e07=_0x4cb8fe;_0x2f00a1[_0x2d1e07('0x557')][_0x2d1e07('0x906')]({'id':_0x3f51b1[_0x2d1e07('0x1eff')]['id']})[_0x2d1e07('0xa44')][_0x2d1e07('0x1166')](function(){const _0x729213=_0x2d1e07;_0x2cfb05()[_0x729213('0x127f')](_0x3f51b1[_0x729213('0x1f7e')],{'id':_0x3f51b1[_0x729213('0x1eff')]['id']}),_0x3b8c35[_0x729213('0x103b')]({'title':_0x729213('0x80e'),'msg':(_0x3f51b1[_0x729213('0x1eff')]['name']||_0x729213('0x1eff'))+'\x20has\x20been\x20deleted!'}),_0x1d2f77(_0x3f51b1[_0x729213('0x1eff')]);})[_0x2d1e07('0x1a80')](function(_0x12da6e){const _0xbf3866=_0x2d1e07;if(_0x12da6e[_0xbf3866('0x25f4')]&&_0x12da6e['data']['errors']&&_0x12da6e[_0xbf3866('0x25f4')]['errors'][_0xbf3866('0x264b')]){_0x3f51b1[_0xbf3866('0x61a')]=_0x12da6e[_0xbf3866('0x25f4')][_0xbf3866('0x61a')]||[{'message':_0x12da6e[_0xbf3866('0x1586')](),'type':'api.user.delete'}];for(let _0x866481=0x0;_0x866481<_0x12da6e[_0xbf3866('0x25f4')]['errors'][_0xbf3866('0x264b')];_0x866481++){_0x3b8c35[_0xbf3866('0xfc9')]({'title':_0x12da6e[_0xbf3866('0x25f4')][_0xbf3866('0x61a')][_0x866481][_0xbf3866('0x1345')],'msg':_0x12da6e[_0xbf3866('0x25f4')][_0xbf3866('0x61a')][_0x866481][_0xbf3866('0x1e70')]});}}else _0x3b8c35[_0xbf3866('0xfc9')]({'title':_0x12da6e[_0xbf3866('0x52d')]?_0xbf3866('0x1e21')+_0x12da6e[_0xbf3866('0x52d')]+_0xbf3866('0x11e1')+_0x12da6e[_0xbf3866('0xe1b')]:_0xbf3866('0x1304'),'msg':_0x12da6e['data']?JSON[_0xbf3866('0xbac')](_0x12da6e['data'][_0xbf3866('0x1e70')]):_0x12da6e[_0xbf3866('0x1e70')]||_0x12da6e[_0xbf3866('0x1586')]()});});},function(){});}function _0x12ce7d(_0x4eaa98){return _0x4eaa98===null?undefined:new Date(_0x4eaa98);}function _0x1d2f77(_0x447d1e){const _0x6cb468=_0x288584;_0xa78885[_0x6cb468('0x1197')](_0x447d1e);}}const _0x6f212=_0x458abf;_0x5d3408[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x1d2e')];function _0x5d3408(_0x408b09,_0x48612b){const _0x8beb59=_0x36e6f4,_0x5a8e2a=this,_0x14b899=0x8,_0x3646df=_0x14b899*0x400*0x400;_0x5a8e2a['agent']={},_0x5a8e2a[_0x8beb59('0x243c')],_0x5a8e2a['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x3646df,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x5a8e2a['ngFlow']={'flow':{}},_0x5a8e2a[_0x8beb59('0x1a5c')]=![],_0x5a8e2a[_0x8beb59('0xd20')]=_0x45b90c,_0x5a8e2a[_0x8beb59('0x1d40')]=_0x1178e7,_0x5a8e2a[_0x8beb59('0x1dea')]=_0x5bb24c,_0x5a8e2a['init']=_0x1d7f9a;function _0x1d7f9a(_0x45c15b,_0x25c5a0){const _0x334654=_0x8beb59;_0x5a8e2a[_0x334654('0x1eff')]=angular[_0x334654('0x225f')](_0x45c15b),_0x5a8e2a[_0x334654('0x243c')]=typeof _0x25c5a0!==_0x334654('0x1048')?_0x25c5a0:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x5a8e2a[_0x334654('0xd67')][_0x334654('0x21cc')]=_0x334654('0x152c')+_0x5a8e2a[_0x334654('0x1eff')]['id']+_0x334654('0x18c4'),_0x5a8e2a[_0x334654('0x1eff')][_0x334654('0x1b17')]=[];}function _0x45b90c(_0x5482e3){const _0xa5dcd9=_0x8beb59,_0x32e51b=['png','jpg'];if(!_0x2cfb05()['includes'](_0x32e51b,_0x5482e3['getExtension']()))return _0x48612b['error']({'title':_0xa5dcd9('0x27fb')+_0x5482e3[_0xa5dcd9('0x26a5')](),'msg':_0xa5dcd9('0x1020')+_0x32e51b[_0xa5dcd9('0x45a')]()}),![];if(_0x5482e3[_0xa5dcd9('0x2340')]>_0x3646df)return _0x48612b[_0xa5dcd9('0xfc9')]({'title':_0xa5dcd9('0x11e6'),'msg':_0xa5dcd9('0x12c0')+_0x14b899+'MB'}),![];const _0xa39c96={'id':_0x5482e3[_0xa5dcd9('0x20f4')],'file':_0x5482e3,'type':_0xa5dcd9('0x32f')};return _0x5a8e2a[_0xa5dcd9('0x1eff')]['images'][_0xa5dcd9('0x2450')](_0xa39c96),!![];}function _0x1178e7(){const _0x11f81d=_0x8beb59;_0x5a8e2a[_0x11f81d('0xe57')][_0x11f81d('0x13d1')][_0x11f81d('0x1ca3')]['headers']={'X-Requested-With':_0x11f81d('0x1bc1'),'Authorization':_0x11f81d('0x24d4')+_0x408b09[_0x11f81d('0xd83')](_0x11f81d('0x10b6'))},_0x5a8e2a['ngFlow'][_0x11f81d('0x13d1')][_0x11f81d('0x1d40')]();}function _0x5bb24c(_0x1c7ddd){const _0x4b32a6=_0x8beb59;angular['forEach'](_0x5a8e2a[_0x4b32a6('0x1eff')][_0x4b32a6('0x1b17')],function(_0x2dfeb6){const _0x211558=_0x4b32a6;if(_0x2dfeb6['id']===_0x1c7ddd[_0x211558('0x20f4')]){const _0x1f0665=new FileReader();_0x1f0665['readAsDataURL'](_0x2dfeb6['file'][_0x211558('0x6bd')]),_0x1f0665['onload']=function(_0x53266d){const _0x1955e8=_0x211558;_0x2dfeb6[_0x1955e8('0xcac')]=_0x53266d['target'][_0x1955e8('0x15b5')];},_0x2dfeb6[_0x211558('0x1345')]=_0x211558('0x19f5');}});}}const _0x3a0051=_0x5d3408;_0x43de9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$mdDialog',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1eff'),_0x36e6f4('0xf8a'),'Auth'];function _0x43de9(_0x2732bc,_0x172f05,_0x457af8,_0x292eae,_0x17bea6,_0x2163f8,_0x2dd1b2){const _0x431f67=_0x36e6f4,_0x37ca11=this;_0x37ca11[_0x431f67('0x98')]=_0x2dd1b2[_0x431f67('0x26cd')](),_0x37ca11[_0x431f67('0x61a')]=[],_0x37ca11[_0x431f67('0xf8a')]=_0x2163f8,_0x37ca11[_0x431f67('0x2900')]=_0x37ca11[_0x431f67('0xf8a')][_0x431f67('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x37ca11[_0x431f67('0x1eff')]=_0x17bea6,_0x37ca11[_0x431f67('0x26e8')]='',_0x37ca11[_0x431f67('0x27f2')]='',_0x37ca11['savePassword']=_0x27e9cd,_0x37ca11['closeDialog']=_0x26c70a,_0x2732bc['$watch'](_0x431f67('0x2560'),function(_0x417281){const _0x34d05f=_0x431f67;!_0x2cfb05()[_0x34d05f('0x2863')](_0x37ca11[_0x34d05f('0x27f2')])&&(_0x417281===_0x37ca11[_0x34d05f('0x27f2')]?_0x2732bc[_0x34d05f('0x1a49')][_0x34d05f('0x26e8')][_0x34d05f('0x28c9')]('oldPasswordMatch',![]):_0x2732bc[_0x34d05f('0x1a49')][_0x34d05f('0x26e8')]['$setValidity'](_0x34d05f('0x25a9'),!![]));});function _0x27e9cd(){const _0x431389=_0x431f67;_0x37ca11[_0x431389('0x61a')]=[];const _0x3f63ee={'id':_0x37ca11[_0x431389('0x1eff')]['id'],'newPassword':_0x37ca11['password']};_0x37ca11['currentUser']['id']==_0x37ca11[_0x431389('0x1eff')]['id']&&(_0x3f63ee[_0x431389('0x27f2')]=_0x37ca11[_0x431389('0x27f2')]),_0x292eae[_0x431389('0x557')]['changePassword'](_0x3f63ee)['$promise'][_0x431389('0x1166')](function(){const _0x451b8c=_0x431389;_0x457af8[_0x451b8c('0x103b')]({'title':_0x451b8c('0x17cd')}),_0x26c70a();})[_0x431389('0x1a80')](function(_0x17a4cb){const _0x339bdc=_0x431389;_0x457af8[_0x339bdc('0xfc9')]({'title':_0x17a4cb[_0x339bdc('0x52d')]?'API:'+_0x17a4cb['status']+_0x339bdc('0x11e1')+_0x17a4cb['statusText']:_0x339bdc('0x104f'),'msg':_0x17a4cb['data']?JSON[_0x339bdc('0xbac')](_0x17a4cb['data'][_0x339bdc('0x1e70')]):_0x17a4cb['toString']()}),_0x37ca11[_0x339bdc('0x61a')]=_0x17a4cb[_0x339bdc('0x25f4')][_0x339bdc('0x61a')]||[{'message':_0x17a4cb[_0x339bdc('0x1586')](),'type':_0x339bdc('0x2042')}];});}function _0x26c70a(){const _0xe69afa=_0x431f67;_0x172f05[_0xe69afa('0x1197')]();}}const _0x374218=_0x43de9;_0x4fd8ea[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1c90'),_0x36e6f4('0x265d'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2256'),_0x36e6f4('0x1d2e')];function _0x4fd8ea(_0x323583,_0x446b1d,_0x1d699c,_0x5c97d8,_0x528141){const _0x7c80e1=_0x36e6f4,_0x517b99=this;_0x517b99[_0x7c80e1('0x1eff')]={},_0x517b99[_0x7c80e1('0x15ea')]=_0x5c97d8[_0x7c80e1('0x1568')](),_0x517b99['crudPermissions'],_0x517b99[_0x7c80e1('0x24d5')]=_0x485a5e,_0x517b99[_0x7c80e1('0x272e')]=_0x5133fb;function _0x485a5e(_0xb69e5d,_0xddb4ed){const _0x53dae1=_0x7c80e1;_0x517b99[_0x53dae1('0x1eff')]=_0xb69e5d,_0x517b99['crudPermissions']=typeof _0xddb4ed!==_0x53dae1('0x1048')?_0xddb4ed:{'readOnly':!![],'canEdit':![],'canDelete':![]};}function _0x5133fb(_0xdae20e,_0x4171ec){const _0x2fd57d=_0x7c80e1,_0xa40c4b=_0x4171ec||_0xdae20e;if(_0xa40c4b[_0x2fd57d('0xc27')]){if(_0x4171ec)_0x4171ec[_0x2fd57d('0xc27')]=!![],_0x517b99['agent']['permissions'][_0x2fd57d('0x1514')](_0x4171ec['id']);else for(let _0x328992=0x0;_0x328992<_0xdae20e[_0x2fd57d('0x9df')]['length'];_0x328992++){_0xdae20e['children'][_0x328992][_0x2fd57d('0xc27')]=!![],_0x517b99[_0x2fd57d('0x1eff')]['permissions'][_0x2fd57d('0x1514')](_0xdae20e[_0x2fd57d('0x9df')][_0x328992]['id']);}_0xdae20e[_0x2fd57d('0xc27')]=!![],_0x517b99[_0x2fd57d('0x1eff')][_0x2fd57d('0x2868')]['push'](_0xdae20e['id']);}else{if(_0x4171ec)_0x4171ec['enabled']=![],_0x2cfb05()['remove'](_0x517b99[_0x2fd57d('0x1eff')][_0x2fd57d('0x2868')],function(_0x67636d){return _0x4171ec['id']===_0x67636d;}),_0x2cfb05()[_0x2fd57d('0x1c33')](_0xdae20e[_0x2fd57d('0x9df')],{'enabled':![]})['length']===_0xdae20e['children']['length']&&(_0xdae20e[_0x2fd57d('0xc27')]=![],_0x2cfb05()[_0x2fd57d('0x127f')](_0x517b99['agent'][_0x2fd57d('0x2868')],function(_0x22f994){return _0xdae20e['id']===_0x22f994;}));else{_0xdae20e[_0x2fd57d('0xc27')]=![],_0x2cfb05()['remove'](_0x517b99[_0x2fd57d('0x1eff')][_0x2fd57d('0x2868')],function(_0x4ad7c6){return _0xdae20e['id']===_0x4ad7c6;});for(let _0x550129=0x0;_0x550129<_0xdae20e[_0x2fd57d('0x9df')][_0x2fd57d('0x264b')];_0x550129++){_0xdae20e['children'][_0x550129][_0x2fd57d('0xc27')]=![],_0x2cfb05()['remove'](_0x517b99[_0x2fd57d('0x1eff')]['permissions'],function(_0x3cbb4d){return _0xdae20e['children'][_0x550129]['id']===_0x3cbb4d;});}}}return _0x1d699c[_0x2fd57d('0x557')]['update']({'id':_0x517b99[_0x2fd57d('0x1eff')]['id'],'permissions':_0x2cfb05()[_0x2fd57d('0x7ae')](_0x517b99[_0x2fd57d('0x1eff')]['permissions'])})['$promise']['then'](function(){const _0x25f7b4=_0x2fd57d;_0x528141[_0x25f7b4('0x103b')]({'title':_0x25f7b4('0xc24'),'msg':_0x517b99['agent'][_0x25f7b4('0x4f0')]?_0x517b99[_0x25f7b4('0x1eff')]['name']+_0x25f7b4('0xa17'):''});})[_0x2fd57d('0x1a80')](function(_0x3fe9fe){const _0x112e9e=_0x2fd57d;console[_0x112e9e('0xfc9')](_0x3fe9fe);});}}const _0x3df295=_0x4fd8ea;_0x402e9b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0x1eff'),'channel',_0x36e6f4('0x2788'),_0x36e6f4('0x586'),'Auth','crudPermissions'];function _0x402e9b(_0x2a8d3f,_0x2d6082,_0x49000f,_0x133f8b,_0xc94e0c,_0x452643,_0x1e8639,_0x3b9935,_0x4dc922,_0xf9d196){const _0x4086a2=_0x36e6f4,_0x3ce12f=this;_0x3ce12f[_0x4086a2('0x98')]=_0x4dc922[_0x4086a2('0x26cd')](),_0x3ce12f[_0x4086a2('0x1eff')]=_0xc94e0c,_0x3ce12f[_0x4086a2('0x243c')]=_0xf9d196,_0x3ce12f[_0x4086a2('0x23af')]=0x0,_0x3ce12f[_0x4086a2('0x1298')]=_0x452643,_0x3ce12f[_0x4086a2('0x2788')]=_0x1e8639,_0x3ce12f[_0x4086a2('0x2677')]=_0x3ce12f[_0x4086a2('0x1298')]+_0x4086a2('0x28ba'),_0x3ce12f[_0x4086a2('0xcdc')]=_0x3b9935['instant']('STAFF.QUEUEADD_AGENT_'+_0x3ce12f[_0x4086a2('0x1298')][_0x4086a2('0x1387')]()+'_'+_0x3ce12f['direction'][_0x4086a2('0x1387')]()),_0x3ce12f[_0x4086a2('0xbd7')]=[],_0x3ce12f['allowedItems']=[],_0x3ce12f[_0x4086a2('0x18e1')]=[],_0x3ce12f['startingAllowedItems']=[],_0x3ce12f[_0x4086a2('0x2781')]=[],_0x3ce12f[_0x4086a2('0x14d7')]=![],_0x3ce12f[_0x4086a2('0xc68')]={'readOnly':!_0x3ce12f[_0x4086a2('0x243c')]['canEdit'],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x4086a2('0x4f0'),'line1':'name','line2':_0x4086a2('0x1345'),'line3':_0x3ce12f[_0x4086a2('0x1298')]===_0x4086a2('0x21da')?_0x4086a2('0x23af'):'','labelAll':_0x3b9935[_0x4086a2('0x25cc')](_0x4086a2('0x243b')+_0x3ce12f[_0x4086a2('0x1298')][_0x4086a2('0x1387')]()+'_'+_0x3ce12f['direction'][_0x4086a2('0x1387')]()),'labelSelected':_0x3b9935[_0x4086a2('0x25cc')](_0x4086a2('0x11f7')+_0x3ce12f[_0x4086a2('0x1298')][_0x4086a2('0x1387')]()+'_'+_0x3ce12f[_0x4086a2('0x2788')][_0x4086a2('0x1387')]()),'transferCallback':function(_0x4a05a0,_0x1edfa6){const _0x29bf06=_0x4086a2;_0x1edfa6?_0x4a05a0[_0x29bf06('0x2782')](function(_0x107572){_0x107572['penalty']=undefined;}):_0x4a05a0[_0x29bf06('0x2782')](function(_0x55fbce){const _0x111598=_0x29bf06;_0x55fbce['penalty']=_0x111598('0x11e8')+_0x3ce12f[_0x111598('0x23af')];});const _0x4351dd=_0x2cfb05()[_0x29bf06('0x1c71')](_0x3ce12f[_0x29bf06('0x2781')],_0x3ce12f[_0x29bf06('0x18e1')],function(_0x3b2af9,_0x153e3a){const _0x427992=_0x29bf06;return _0x3b2af9['id']===_0x153e3a['id']&&_0x3b2af9[_0x427992('0x23af')]===_0x153e3a[_0x427992('0x23af')];});_0x3ce12f[_0x29bf06('0x14d7')]=_0x2cfb05()['isEmpty'](_0x4351dd)?![]:!![];}},_0x3ce12f[_0x4086a2('0xae0')]=_0x136379,_0x3ce12f[_0x4086a2('0x2219')]=_0x2723da,_0x3ce12f[_0x4086a2('0x24a0')]=_0x59d566;function _0x136379(){const _0x488920=_0x4086a2;return _0x4dc922[_0x488920('0x1ac6')](_0x488920('0xa7c'))?_0x4ee3b1()[_0x488920('0x1a80')](function(_0x2baef5){const _0x86e581=_0x488920;_0x49000f['error']({'title':_0x2baef5[_0x86e581('0x52d')]?_0x86e581('0x1e21')+_0x2baef5[_0x86e581('0x52d')]+'\x20-\x20'+_0x2baef5[_0x86e581('0xe1b')]:_0x86e581('0x2029'),'msg':_0x2baef5['status']?JSON[_0x86e581('0xbac')](_0x2baef5[_0x86e581('0x25f4')]):_0x2baef5['toString']()});}):_0x4e3352()[_0x488920('0x1166')](function(_0x42020e){const _0x2ec9c0=_0x488920;return _0x3ce12f[_0x2ec9c0('0xe60')]=_0x42020e,_0x4ee3b1();})['catch'](function(_0x332817){const _0x2be523=_0x488920;_0x49000f[_0x2be523('0xfc9')]({'title':_0x332817[_0x2be523('0x52d')]?_0x2be523('0x1e21')+_0x332817[_0x2be523('0x52d')]+_0x2be523('0x11e1')+_0x332817['statusText']:'SYSTEM:GET_QUEUES','msg':_0x332817[_0x2be523('0x52d')]?JSON[_0x2be523('0xbac')](_0x332817['data']):_0x332817[_0x2be523('0x1586')]()});});}function _0x4e3352(){return _0x2d6082(function(_0x12f16e,_0x436c0a){const _0xf11040=a0_0x3f2c;let _0x17d85e;switch(_0x3ce12f[_0xf11040('0x1298')]){case _0xf11040('0x21da'):switch(_0x3ce12f['direction']){case _0xf11040('0x14d8'):_0x17d85e='VoiceQueues';break;case _0xf11040('0x587'):_0x17d85e=_0xf11040('0x9f4');break;}break;case _0xf11040('0xde2'):_0x17d85e='ChatQueues';break;case _0xf11040('0x1bfa'):_0x17d85e=_0xf11040('0x5f8');break;case'sms':_0x17d85e=_0xf11040('0x24e4');break;case _0xf11040('0x26c'):_0x17d85e=_0xf11040('0x1eb3');break;case _0xf11040('0x1fc7'):_0x17d85e=_0xf11040('0x1e54');break;}_0x133f8b[_0xf11040('0x17aa')][_0xf11040('0xd83')]({'userProfileId':_0x3ce12f[_0xf11040('0x98')][_0xf11040('0xb86')],'name':_0x17d85e})[_0xf11040('0xa44')][_0xf11040('0x1166')](function(_0xd6894){const _0x31e874=_0xf11040,_0x2698c5=_0xd6894&&_0xd6894[_0x31e874('0x269a')]?_0xd6894['rows'][0x0]:null;_0x12f16e(_0x2698c5);})[_0xf11040('0x1a80')](function(_0xc0632a){_0x436c0a(_0xc0632a);});});}function _0x4ee3b1(){return _0x2d6082(function(_0x1f1250,_0x54aab2){const _0x24d189=a0_0x3f2c;return _0x4b258d()[_0x24d189('0x1166')](function(_0x507e3f){const _0x7308cc=_0x24d189;return _0x3ce12f[_0x7308cc('0xbd7')]=_0x507e3f['rows']?_0x507e3f[_0x7308cc('0x269a')]:[],_0x4dc922[_0x7308cc('0x1ac6')]('admin')?_0x507e3f:_0x3ce12f[_0x7308cc('0xe60')]?_0x3ce12f[_0x7308cc('0xe60')][_0x7308cc('0x1a2b')]?_0x507e3f:_0x503273():null;})[_0x24d189('0x1166')](function(_0x58063b){const _0x43020a=_0x24d189,_0x186436=_0x58063b&&_0x58063b[_0x43020a('0x269a')]?_0x58063b[_0x43020a('0x269a')]:[];return _0x3ce12f[_0x43020a('0x10ab')]=_0x2cfb05()[_0x43020a('0x2563')](_0x186436,function(_0x1ba269){const _0x576f83=_0x43020a;return _0x2cfb05()[_0x576f83('0xc38')](_0x3ce12f[_0x576f83('0xbd7')],{'id':_0x4dc922[_0x576f83('0x1ac6')]('admin')||_0x3ce12f[_0x576f83('0xe60')][_0x576f83('0x1a2b')]?_0x1ba269['id']:_0x1ba269[_0x576f83('0x24e8')]});}),_0x3ce12f['startingAllowedItems']=angular[_0x43020a('0x225f')](_0x3ce12f[_0x43020a('0x10ab')]),_0x3ce12f[_0x43020a('0xbd7')]['forEach'](function(_0x5db30c){const _0xec5d06=_0x43020a,_0x187dc9=_0x2cfb05()['find'](_0x3ce12f[_0xec5d06('0x10ab')],{'id':_0x5db30c['id']});_0x4dc922['hasRole'](_0xec5d06('0xa7c'))?_0x5db30c[_0xec5d06('0x26ef')]=!![]:_0x5db30c[_0xec5d06('0x26ef')]=typeof _0x187dc9!==_0xec5d06('0x1048')?!![]:![];}),_0x411814();})['then'](function(_0x2fdbb5){const _0x382189=_0x24d189,_0x5069c2=_0x2fdbb5&&_0x2fdbb5[_0x382189('0x269a')]?_0x2fdbb5[_0x382189('0x269a')]:[];_0x3ce12f[_0x382189('0x18e1')]=_0x2cfb05()[_0x382189('0x2563')](_0x5069c2,function(_0x299b74){const _0x2abefc=_0x382189,_0xac771f=_0x2cfb05()[_0x2abefc('0xc38')](_0x3ce12f[_0x2abefc('0xbd7')],{'id':_0x299b74['id']});return _0x3ce12f[_0x2abefc('0x1298')]==='voice'&&(_0xac771f[_0x2abefc('0x23af')]=typeof _0xac771f!=='undefined'&&typeof _0x299b74[_0x2abefc('0x1dcc')]!==_0x2abefc('0x1048')?_0x2abefc('0x11e8')+_0x299b74['UserVoiceQueue'][_0x2abefc('0x23af')]:_0x2abefc('0x11e8')+0x0),_0xac771f;}),_0x3ce12f[_0x382189('0x2781')]=angular[_0x382189('0x225f')](_0x3ce12f[_0x382189('0x18e1')]),_0x3ce12f[_0x382189('0xc68')][_0x382189('0x18e1')]=_0x3ce12f[_0x382189('0x18e1')],_0x3ce12f[_0x382189('0xc68')]['items']=_0x2cfb05()[_0x382189('0x24ac')](_0x3ce12f[_0x382189('0x10ab')],_0x3ce12f[_0x382189('0xc68')][_0x382189('0x18e1')],'id'),_0x1f1250();})[_0x24d189('0x1a80')](function(_0x12c583){_0x54aab2(_0x12c583);});});}function _0x503273(){return _0x2d6082(function(_0x5e2a15,_0x5971e8){const _0x704e29=a0_0x3f2c;return _0x133f8b[_0x704e29('0x4b5')]['get']({'sectionId':_0x3ce12f[_0x704e29('0xe60')]['id'],'nolimit':!![]})['$promise'][_0x704e29('0x1166')](function(_0x2b5c54){_0x5e2a15(_0x2b5c54);})[_0x704e29('0x1a80')](function(_0x8bee85){_0x5971e8(_0x8bee85);});});}function _0x411814(){return _0x2d6082(function(_0x2b4a76,_0x27ca11){const _0x3b329f=a0_0x3f2c;return _0x133f8b['user']['getQueues']({'id':_0x3ce12f[_0x3b329f('0x1eff')]['id'],'fields':_0x3b329f('0x112d'),'nolimit':!![],'type':_0x3ce12f['direction'],'channel':_0x3ce12f[_0x3b329f('0x1298')]})['$promise'][_0x3b329f('0x1166')](function(_0x42228e){_0x2b4a76(_0x42228e);})[_0x3b329f('0x1a80')](function(_0x1e1237){_0x27ca11(_0x1e1237);});});}function _0x4b258d(){return _0x2d6082(function(_0x3fb9e5,_0x2e801c){const _0x433d58=a0_0x3f2c;return _0x133f8b[_0x3ce12f['apiName']][_0x433d58('0xd83')]({'fields':_0x433d58('0x1ad1'),'channel':_0x3ce12f[_0x433d58('0x1298')]==='bull'?_0x433d58('0x21da'):_0x3ce12f[_0x433d58('0x1298')],'type':_0x3ce12f[_0x433d58('0x2788')],'nolimit':!![]})[_0x433d58('0xa44')]['then'](function(_0x2f7a12){_0x3fb9e5(_0x2f7a12);})['catch'](function(_0x2b5c39){_0x2e801c(_0x2b5c39);});});}function _0x4d27c0(_0x57ecdb){return _0x2d6082(function(_0x318aff,_0x120138){const _0x2c7058=a0_0x3f2c;if(_0x2cfb05()[_0x2c7058('0x1081')](_0x57ecdb))_0x318aff();else{if(_0x3ce12f[_0x2c7058('0x1298')]===_0x2c7058('0x21da')){const _0x191dda=[],_0x162a2e=_0x2cfb05()['groupBy'](_0x57ecdb,_0x2c7058('0x23af'));for(let _0x1b6ae3=0x0;_0x1b6ae3':'',_0x2babf3;}),_0x24c78b[_0x5f3d6e('0x2781')]=angular[_0x5f3d6e('0x225f')](_0x24c78b[_0x5f3d6e('0x18e1')]),_0x24c78b['dualMultiselectOptions'][_0x5f3d6e('0x18e1')]=_0x24c78b[_0x5f3d6e('0x18e1')],_0x24c78b[_0x5f3d6e('0xc68')]['items']=_0x2cfb05()[_0x5f3d6e('0x24ac')](_0x24c78b[_0x5f3d6e('0x10ab')],_0x24c78b[_0x5f3d6e('0xc68')]['selectedItems'],'id'),_0x1a1880();})[_0x1c7f9b('0x1a80')](function(_0x1195b8){_0x11600a(_0x1195b8);});});}function _0x56a7f6(){return _0xabb3d2(function(_0x547fb3,_0x42d694){const _0x1298c1=a0_0x3f2c;return _0x274d84['userProfileResource']['get']({'sectionId':_0x24c78b[_0x1298c1('0xe60')]['id'],'nolimit':!![]})[_0x1298c1('0xa44')][_0x1298c1('0x1166')](function(_0x4c6460){_0x547fb3(_0x4c6460);})['catch'](function(_0x6fd0a4){_0x42d694(_0x6fd0a4);});});}function _0x32688a(){return _0xabb3d2(function(_0x2a7a64,_0x517841){const _0x6c8a93=a0_0x3f2c;return _0x274d84[_0x6c8a93('0x1e37')][_0x6c8a93('0x261c')]({'id':_0x24c78b['team']['id'],'fields':_0x6c8a93('0x1459'),'nolimit':!![],'role':_0x6c8a93('0x1eff')})[_0x6c8a93('0xa44')]['then'](function(_0x13c84d){_0x2a7a64(_0x13c84d);})[_0x6c8a93('0x1a80')](function(_0x226693){_0x517841(_0x226693);});});}function _0x2b0402(){return _0xabb3d2(function(_0x334aae,_0x708a06){const _0x561276=a0_0x3f2c;return _0x274d84[_0x561276('0x557')][_0x561276('0xd83')]({'fields':_0x561276('0x1459'),'nolimit':!![],'role':_0x561276('0x1eff')})['$promise']['then'](function(_0x5dd075){_0x334aae(_0x5dd075);})['catch'](function(_0x3d504b){_0x708a06(_0x3d504b);});});}function _0x10762a(_0x32e600){return _0xabb3d2(function(_0x368657,_0x1996f4){const _0x570e48=a0_0x3f2c;_0x2cfb05()['isEmpty'](_0x32e600)?_0x368657():_0x274d84[_0x570e48('0x1e37')]['addAgents']({'id':_0x24c78b[_0x570e48('0x1e37')]['id'],'ids':_0x2cfb05()[_0x570e48('0x2563')](_0x32e600,'id')})[_0x570e48('0xa44')][_0x570e48('0x1166')](function(){_0x368657();})['catch'](function(_0x4f5a43){_0x1996f4(_0x4f5a43);});});}function _0x5b8660(_0x58d1c){return _0xabb3d2(function(_0x5b18bb,_0x295d5c){const _0x5c5ac1=a0_0x3f2c;_0x2cfb05()[_0x5c5ac1('0x1081')](_0x58d1c)?_0x5b18bb():_0x274d84['team']['removeAgents']({'id':_0x24c78b['team']['id'],'ids':_0x2cfb05()[_0x5c5ac1('0x2563')](_0x58d1c,'id')})['$promise'][_0x5c5ac1('0x1166')](function(){_0x5b18bb();})[_0x5c5ac1('0x1a80')](function(_0x61774c){_0x295d5c(_0x61774c);});});}function _0xc11e71(){const _0x52354f=_0x54800a,_0x19a257=_0x2cfb05()['differenceBy'](_0x24c78b[_0x52354f('0x2781')],_0x24c78b[_0x52354f('0x18e1')],'id'),_0x589897=_0x2cfb05()[_0x52354f('0x24ac')](_0x24c78b[_0x52354f('0x18e1')],_0x24c78b['startingSelectedItems'],'id');return _0x5b8660(_0x19a257)[_0x52354f('0x1166')](function(){return _0x10762a(_0x589897);})[_0x52354f('0x1166')](function(){const _0x326b2c=_0x52354f;_0x24c78b[_0x326b2c('0x14d7')]=![],_0x24c78b[_0x326b2c('0x2111')]=angular[_0x326b2c('0x225f')](_0x24c78b['allowedItems']),_0x24c78b[_0x326b2c('0x2781')]=angular[_0x326b2c('0x225f')](_0x24c78b[_0x326b2c('0x18e1')]),_0x5dfce3['success']({'title':_0x326b2c('0x983'),'msg':'Agents\x20association\x20has\x20been\x20updated!'});})[_0x52354f('0x1a80')](function(_0xabe3ec){const _0x548ca4=_0x52354f;_0x5dfce3['error']({'title':_0xabe3ec[_0x548ca4('0x52d')]?_0x548ca4('0x1e21')+_0xabe3ec[_0x548ca4('0x52d')]+_0x548ca4('0x11e1')+_0xabe3ec[_0x548ca4('0xe1b')]:_0x548ca4('0x1b29'),'msg':_0xabe3ec['status']?JSON[_0x548ca4('0xbac')](_0xabe3ec[_0x548ca4('0x25f4')]):_0xabe3ec[_0x548ca4('0x1586')]()});});}function _0x5bcbbf(){_0x5046cf['hide']();}}const _0x2bebe8=_0x2495a9,_0x4bc154=_0x2734b2['p']+_0x36e6f4('0x6ec'),_0x54c588=_0x2734b2['p']+_0x36e6f4('0x14ba');_0x3a8dcf['$inject']=[_0x36e6f4('0x36f'),'$window',_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x53'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x3a8dcf(_0x3795ba,_0x321b1f,_0x2823a6,_0x2d345c,_0x1730d4,_0x5e5fc0,_0x3531ef,_0x1a3abb,_0x24a388,_0x70d8ea,_0x16d7a5,_0x5cd410,_0x54d5d4,_0x496488,_0x59f039,_0x290201,_0x130bfa){const _0x29e74d=_0x36e6f4,_0x2f188e=this;_0x2f188e['license']=_0x290201,_0x2f188e['setting']=_0x130bfa,_0x2f188e[_0x29e74d('0x98')]=_0x59f039['getCurrentUser'](),_0x2f188e[_0x29e74d('0x53')]=_0x24a388||{'count':0x0,'rows':[]},_0x2f188e[_0x29e74d('0x7f')]=_0x70d8ea,_0x2f188e['userProfileSection']=_0x16d7a5&&_0x16d7a5[_0x29e74d('0x240f')]==0x1?_0x16d7a5[_0x29e74d('0x269a')][0x0]:null,_0x2f188e[_0x29e74d('0x243c')]=_0x59f039['parseCrudPermissions'](_0x2f188e[_0x29e74d('0x17aa')]?_0x2f188e[_0x29e74d('0x17aa')][_0x29e74d('0x243c')]:null),_0x2f188e[_0x29e74d('0x916')]=_0x29e74d('0x53'),_0x2f188e[_0x29e74d('0xef5')]='',_0x2f188e[_0x29e74d('0x104c')]=null,_0x2f188e['selectedTeams']=[],_0x2f188e[_0x29e74d('0x2218')]={'fields':_0x29e74d('0x208e'),'sort':_0x29e74d('0x14dc'),'limit':0xa,'page':0x1},_0x2f188e[_0x29e74d('0x1f8e')]=_0x64fd72,_0x2f188e[_0x29e74d('0x1728')]=_0x405fcd,_0x2f188e['deleteconfirm']=_0x11c567,_0x2f188e[_0x29e74d('0x103b')]=_0x2582f7,_0x2f188e[_0x29e74d('0x1448')]=_0x4485ee,_0x2f188e['createOrEditTeam']=_0xdc8ee,_0x2f188e[_0x29e74d('0x25d5')]=_0x687d1f,_0x2f188e[_0x29e74d('0xe44')]=_0x4c451c,_0x2f188e[_0x29e74d('0x590')]=_0x46fe01,_0x2f188e[_0x29e74d('0x1922')]=_0x3d9be0,_0x2f188e[_0x29e74d('0x1dda')]=_0x1051c6;function _0x64fd72(_0x38a6d9,_0x57b956){const _0x547e31=_0x29e74d;_0x1730d4[_0x547e31('0x1f80')]({'controller':_0x547e31('0x1161'),'controllerAs':'vm','templateUrl':_0x4bc154,'parent':angular[_0x547e31('0x1194')](_0x5e5fc0[_0x547e31('0x8d2')]),'targetEvent':_0x57b956,'clickOutsideToClose':!![],'locals':{'team':_0x38a6d9,'teams':_0x2f188e[_0x547e31('0x53')][_0x547e31('0x269a')],'license':_0x2f188e['license'],'setting':null,'crudPermissions':_0x2f188e[_0x547e31('0x243c')]}});}function _0x405fcd(_0x5e0d81,_0x51a772){const _0x236fbd=_0x29e74d;_0x1730d4[_0x236fbd('0x1f80')]({'controller':'TeamagentaddController','controllerAs':'vm','templateUrl':_0x54c588,'parent':angular[_0x236fbd('0x1194')](_0x5e5fc0[_0x236fbd('0x8d2')]),'targetEvent':_0x51a772,'clickOutsideToClose':!![],'locals':{'team':_0x5e0d81,'teams':_0x2f188e[_0x236fbd('0x53')]?_0x2f188e['teams'][_0x236fbd('0x269a')]:[],'crudPermissions':_0x2f188e[_0x236fbd('0x243c')],'realtime':![]}});}function _0x11c567(_0x60b3a7,_0x489e5b){const _0x1ba502=_0x29e74d,_0x4bccf5=_0x1730d4[_0x1ba502('0x1d26')]()[_0x1ba502('0xcdc')](_0x1ba502('0x288d')+_0x2cfb05()[_0x1ba502('0xb35')](_0x1ba502('0x1e37'))+'?')[_0x1ba502('0xf3c')](''+(_0x60b3a7[_0x1ba502('0x4f0')]||_0x1ba502('0x1e37'))+_0x1ba502('0xace')+_0x1ba502('0x3f3'))[_0x1ba502('0x8e8')](_0x1ba502('0x1ba5'))[_0x1ba502('0x203b')](_0x489e5b)['ok']('OK')[_0x1ba502('0x3f')](_0x1ba502('0x2d3'));_0x1730d4[_0x1ba502('0x1f80')](_0x4bccf5)[_0x1ba502('0x1166')](function(){_0x687d1f(_0x60b3a7);},function(){const _0x5bbdd8=_0x1ba502;console[_0x5bbdd8('0x455')]('CANCEL');});}let _0x278d60=!![],_0x15e8fc=0x1;_0x3795ba[_0x29e74d('0xe83')](_0x29e74d('0x12d8'),function(_0x185f2f,_0x2d5dc5){const _0x4370e2=_0x29e74d;_0x278d60?_0x3531ef(function(){_0x278d60=![];}):(!_0x2d5dc5&&(_0x15e8fc=_0x2f188e[_0x4370e2('0x2218')]['page']),_0x185f2f!==_0x2d5dc5&&(_0x2f188e['query'][_0x4370e2('0x1a43')]=0x1),!_0x185f2f&&(_0x2f188e['query'][_0x4370e2('0x1a43')]=_0x15e8fc),_0x2f188e[_0x4370e2('0x1448')]());});function _0x2582f7(_0x36823f){const _0x150f41=_0x29e74d;_0x2f188e[_0x150f41('0x53')]=_0x36823f||{'count':0x0,'rows':[]};}function _0x4485ee(){const _0x326fc2=_0x29e74d;_0x2f188e[_0x326fc2('0x2218')]['offset']=(_0x2f188e[_0x326fc2('0x2218')]['page']-0x1)*_0x2f188e['query'][_0x326fc2('0x163f')],_0x59f039[_0x326fc2('0x1ac6')](_0x326fc2('0xa7c'))?_0x2f188e[_0x326fc2('0x1f48')]=_0x5cd410['team']['get'](_0x2f188e[_0x326fc2('0x2218')],_0x2582f7)[_0x326fc2('0xa44')]:(_0x2f188e[_0x326fc2('0x2218')]['id']=_0x2f188e['userProfile']['id'],_0x2f188e[_0x326fc2('0x2218')][_0x326fc2('0xe60')]='Teams',_0x2f188e[_0x326fc2('0x1f48')]=_0x5cd410['userProfile'][_0x326fc2('0x263a')](_0x2f188e[_0x326fc2('0x2218')],_0x2582f7)[_0x326fc2('0xa44')]);}function _0xdc8ee(_0x4b19dd,_0x33c992){const _0xe6c2d2=_0x29e74d;_0x1730d4[_0xe6c2d2('0x1f80')]({'controller':'CreateOrEditTeamDialogController','controllerAs':'vm','templateUrl':_0x4bc154,'parent':angular['element'](_0x5e5fc0[_0xe6c2d2('0x8d2')]),'targetEvent':_0x4b19dd,'clickOutsideToClose':!![],'locals':{'team':_0x33c992,'teams':_0x2f188e[_0xe6c2d2('0x53')][_0xe6c2d2('0x269a')],'license':_0x2f188e[_0xe6c2d2('0x5c9')],'setting':_0x2f188e[_0xe6c2d2('0xf8a')],'crudPermissions':_0x2f188e['crudPermissions']}});}function _0x687d1f(_0x1e5fac){const _0x83585f=_0x29e74d;_0x5cd410[_0x83585f('0x1e37')][_0x83585f('0x906')]({'id':_0x1e5fac['id']})[_0x83585f('0xa44')][_0x83585f('0x1166')](function(){const _0x590f38=_0x83585f;_0x2cfb05()[_0x590f38('0x127f')](_0x2f188e[_0x590f38('0x53')]['rows'],{'id':_0x1e5fac['id']}),_0x2f188e['teams'][_0x590f38('0x240f')]-=0x1,!_0x2f188e[_0x590f38('0x53')]['rows'][_0x590f38('0x264b')]&&_0x2f188e[_0x590f38('0x1448')](),_0x496488['success']({'title':_0x2cfb05()['startCase'](_0x590f38('0x64'))+_0x590f38('0x2b6'),'msg':_0x1e5fac[_0x590f38('0x4f0')]?_0x1e5fac[_0x590f38('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0x83585f('0x1a80')](function(_0x1ff914){const _0x3cc06f=_0x83585f;if(_0x1ff914['data']&&_0x1ff914['data'][_0x3cc06f('0x61a')]&&_0x1ff914[_0x3cc06f('0x25f4')][_0x3cc06f('0x61a')][_0x3cc06f('0x264b')]){_0x2f188e[_0x3cc06f('0x61a')]=_0x1ff914[_0x3cc06f('0x25f4')][_0x3cc06f('0x61a')]||[{'message':_0x1ff914[_0x3cc06f('0x1586')](),'type':'SYSTEM:DELETEteam'}];for(let _0x4c9ece=0x0;_0x4c9ece<_0x1ff914['data']['errors'][_0x3cc06f('0x264b')];_0x4c9ece++){_0x496488['error']({'title':_0x1ff914[_0x3cc06f('0x25f4')][_0x3cc06f('0x61a')][_0x4c9ece][_0x3cc06f('0x1345')],'msg':_0x1ff914['data']['errors'][_0x4c9ece][_0x3cc06f('0x1e70')]});}}else _0x496488[_0x3cc06f('0xfc9')]({'title':_0x1ff914[_0x3cc06f('0x52d')]?_0x3cc06f('0x1e21')+_0x1ff914[_0x3cc06f('0x52d')]+_0x3cc06f('0x11e1')+_0x1ff914[_0x3cc06f('0xe1b')]:_0x3cc06f('0x11a9'),'msg':_0x1ff914[_0x3cc06f('0x25f4')]?JSON[_0x3cc06f('0xbac')](_0x1ff914[_0x3cc06f('0x25f4')][_0x3cc06f('0x1e70')]):_0x1ff914[_0x3cc06f('0x1e70')]||_0x1ff914[_0x3cc06f('0x1586')]()});});}function _0x4c451c(){const _0x4ff919=_0x29e74d,_0x2f7584=angular[_0x4ff919('0x225f')](_0x2f188e[_0x4ff919('0x22fc')]);return _0x2f188e['selectedTeams']=[],_0x2f7584;}function _0x46fe01(_0x46eed4){const _0x446a17=_0x29e74d,_0x3faa2b=_0x1730d4[_0x446a17('0x1d26')]()[_0x446a17('0xcdc')](_0x446a17('0x503'))[_0x446a17('0xf3c')](_0x446a17('0x12b5')+_0x2f188e[_0x446a17('0x22fc')][_0x446a17('0x264b')]+_0x446a17('0x196d')+_0x446a17('0x3f3'))['ariaLabel']('delete\x20Teams')[_0x446a17('0x203b')](_0x46eed4)['ok']('OK')[_0x446a17('0x3f')](_0x446a17('0x2d3'));_0x1730d4[_0x446a17('0x1f80')](_0x3faa2b)[_0x446a17('0x1166')](function(){const _0x39cbbd=_0x446a17;_0x2f188e['selectedTeams'][_0x39cbbd('0x2782')](function(_0xc7a644){_0x687d1f(_0xc7a644);}),_0x2f188e['selectedTeams']=[];});}function _0x3d9be0(){const _0x560194=_0x29e74d;_0x2f188e[_0x560194('0x22fc')]=[];}function _0x1051c6(){const _0x590e4e=_0x29e74d;_0x2f188e[_0x590e4e('0x22fc')]=_0x2f188e[_0x590e4e('0x53')][_0x590e4e('0x269a')];}}const _0x1220da=_0x3a8dcf;_0x185208[_0x36e6f4('0x1294')]=['$scope','$state','$location',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x20f9'),_0x36e6f4('0x887'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x185208(_0x5cb52a,_0x56fe0f,_0x5de8fb,_0x9e234f,_0x3f2fc8,_0x95832b,_0x31d838,_0x4fe92a,_0x509731,_0x36ce63,_0x233783,_0x80e35a,_0x213b6b,_0x2cb0f3){const _0x3c5be7=_0x36e6f4,_0xa2fd0f=this;_0xa2fd0f[_0x3c5be7('0x98')]=_0x233783['getCurrentUser'](),_0xa2fd0f['errors']=[],_0xa2fd0f[_0x3c5be7('0xf8a')]=_0x213b6b,_0xa2fd0f[_0x3c5be7('0x5c9')]=_0x80e35a,_0xa2fd0f[_0x3c5be7('0x243c')]=_0x2cb0f3,_0xa2fd0f[_0x3c5be7('0x128b')]={},_0xa2fd0f[_0x3c5be7('0x2900')]=_0xa2fd0f['setting']&&_0xa2fd0f[_0x3c5be7('0xf8a')][_0x3c5be7('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xa2fd0f[_0x3c5be7('0xcdc')]=_0x3c5be7('0x138e'),_0xa2fd0f[_0x3c5be7('0x887')]=angular[_0x3c5be7('0x225f')](_0x509731),_0xa2fd0f['telephones']=_0x4fe92a,_0xa2fd0f[_0x3c5be7('0x1150')]=![];!_0xa2fd0f[_0x3c5be7('0x887')]&&(_0xa2fd0f[_0x3c5be7('0x887')]={'role':_0x3c5be7('0x887'),'autointernal':!![],'context':_0x3c5be7('0xb31')},_0xa2fd0f['title']=_0x3c5be7('0x1daf'),_0xa2fd0f[_0x3c5be7('0x1150')]=!![]);_0xa2fd0f[_0x3c5be7('0x109')]=_0x231052,_0xa2fd0f['saveTelephone']=_0x469c13,_0xa2fd0f[_0x3c5be7('0x164b')]=_0xaf6d0b,_0xa2fd0f['getDateFromString']=_0x5f21d2,_0xa2fd0f[_0x3c5be7('0x24a0')]=_0x444566;function _0x231052(){const _0x799c8f=_0x3c5be7;_0xa2fd0f['errors']=[],_0x36ce63[_0x799c8f('0x557')][_0x799c8f('0x9cc')](_0xa2fd0f[_0x799c8f('0x887')])[_0x799c8f('0xa44')][_0x799c8f('0x1166')](function(_0x3a6c9c){const _0x2de845=_0x799c8f;_0xa2fd0f['telephones'][_0x2de845('0x2450')](_0x3a6c9c['toJSON']()),_0x31d838['success']({'title':_0x2de845('0x19ce'),'msg':_0xa2fd0f[_0x2de845('0x887')]['name']?_0xa2fd0f[_0x2de845('0x887')]['name']+_0x2de845('0x1eda'):''}),_0x444566(_0x3a6c9c);})[_0x799c8f('0x1a80')](function(_0x3c9666){const _0x268f74=_0x799c8f;if(_0x3c9666[_0x268f74('0x25f4')]&&_0x3c9666[_0x268f74('0x25f4')]['errors']&&_0x3c9666[_0x268f74('0x25f4')][_0x268f74('0x61a')][_0x268f74('0x264b')]){_0xa2fd0f['errors']=_0x3c9666[_0x268f74('0x25f4')][_0x268f74('0x61a')]||[{'message':_0x3c9666['toString'](),'type':'api.user.save'}];for(let _0x44dab1=0x0;_0x44dab1<_0x3c9666['data'][_0x268f74('0x61a')]['length'];_0x44dab1+=0x1){_0x31d838[_0x268f74('0xfc9')]({'title':_0x3c9666[_0x268f74('0x25f4')]['errors'][_0x44dab1][_0x268f74('0x1345')],'msg':_0x3c9666[_0x268f74('0x25f4')][_0x268f74('0x61a')][_0x44dab1][_0x268f74('0x1e70')]});}}else _0x31d838[_0x268f74('0xfc9')]({'title':_0x3c9666[_0x268f74('0x52d')]?'API:'+_0x3c9666[_0x268f74('0x52d')]+_0x268f74('0x11e1')+_0x3c9666[_0x268f74('0xe1b')]:_0x268f74('0xe5d'),'msg':_0x3c9666['data']?JSON[_0x268f74('0xbac')](_0x3c9666[_0x268f74('0x25f4')][_0x268f74('0x1e70')]):_0x3c9666['toString']()});});}function _0x469c13(){const _0x2ea56b=_0x3c5be7;_0xa2fd0f[_0x2ea56b('0x61a')]=[],_0x36ce63[_0x2ea56b('0x557')][_0x2ea56b('0x1449')]({'id':_0xa2fd0f[_0x2ea56b('0x887')]['id']},_0xa2fd0f['telephone'])['$promise'][_0x2ea56b('0x1166')](function(_0x4308fa){const _0xfbbc8a=_0x2ea56b,_0x526227=_0x2cfb05()['find'](_0xa2fd0f[_0xfbbc8a('0x20f9')],{'id':_0x4308fa['id']});_0x526227&&_0x2cfb05()[_0xfbbc8a('0xcc3')](_0x526227,_0x2cfb05()[_0xfbbc8a('0x1a08')](_0x4308fa['toJSON'](),_0x2cfb05()['keys'](_0x526227))),_0x31d838[_0xfbbc8a('0x103b')]({'title':_0xfbbc8a('0xd0d'),'msg':_0xa2fd0f[_0xfbbc8a('0x887')]['name']?_0xa2fd0f[_0xfbbc8a('0x887')][_0xfbbc8a('0x4f0')]+_0xfbbc8a('0x7d'):''}),_0x444566(_0x4308fa);})[_0x2ea56b('0x1a80')](function(_0x3b970d){const _0x8f93d0=_0x2ea56b;if(_0x3b970d[_0x8f93d0('0x25f4')]&&_0x3b970d[_0x8f93d0('0x25f4')][_0x8f93d0('0x61a')]&&_0x3b970d[_0x8f93d0('0x25f4')][_0x8f93d0('0x61a')][_0x8f93d0('0x264b')]){_0xa2fd0f['errors']=_0x3b970d[_0x8f93d0('0x25f4')][_0x8f93d0('0x61a')]||[{'message':_0x3b970d['toString'](),'type':_0x8f93d0('0x1103')}];for(let _0x200c84=0x0;_0x200c84<_0x3b970d[_0x8f93d0('0x25f4')][_0x8f93d0('0x61a')]['length'];_0x200c84++){_0x31d838[_0x8f93d0('0xfc9')]({'title':_0x3b970d[_0x8f93d0('0x25f4')][_0x8f93d0('0x61a')][_0x200c84]['type'],'msg':_0x3b970d['data']['errors'][_0x200c84][_0x8f93d0('0x1e70')]});}}else _0x31d838['error']({'title':_0x3b970d[_0x8f93d0('0x52d')]?_0x8f93d0('0x1e21')+_0x3b970d[_0x8f93d0('0x52d')]+_0x8f93d0('0x11e1')+_0x3b970d[_0x8f93d0('0xe1b')]:_0x8f93d0('0x1103'),'msg':_0x3b970d[_0x8f93d0('0x25f4')]?JSON[_0x8f93d0('0xbac')](_0x3b970d[_0x8f93d0('0x25f4')][_0x8f93d0('0x1e70')]):_0x3b970d['toString']()});});}function _0xaf6d0b(_0x1e652a){const _0x5c5005=_0x3c5be7;_0xa2fd0f[_0x5c5005('0x61a')]=[];const _0x22abe0=_0x9e234f[_0x5c5005('0x1d26')]()[_0x5c5005('0xcdc')](_0x5c5005('0x7fb'))[_0x5c5005('0xacc')](_0x5c5005('0x692'))[_0x5c5005('0x8e8')](_0x5c5005('0x1cc9'))['ok'](_0x5c5005('0x18'))[_0x5c5005('0x3f')](_0x5c5005('0x497'))[_0x5c5005('0x203b')](_0x1e652a);_0x9e234f[_0x5c5005('0x1f80')](_0x22abe0)[_0x5c5005('0x1166')](function(){const _0x16e1a9=_0x5c5005;_0x36ce63[_0x16e1a9('0x557')][_0x16e1a9('0x906')]({'id':_0xa2fd0f[_0x16e1a9('0x887')]['id']})[_0x16e1a9('0xa44')][_0x16e1a9('0x1166')](function(){const _0xb4a30d=_0x16e1a9;_0x2cfb05()['remove'](_0xa2fd0f[_0xb4a30d('0x20f9')],{'id':_0xa2fd0f[_0xb4a30d('0x887')]['id']}),_0x31d838[_0xb4a30d('0x103b')]({'title':_0xb4a30d('0xa32'),'msg':(_0xa2fd0f[_0xb4a30d('0x887')][_0xb4a30d('0x4f0')]||_0xb4a30d('0x887'))+_0xb4a30d('0x7cd')}),_0x444566(_0xa2fd0f['telephone']);})[_0x16e1a9('0x1a80')](function(_0x6feda){const _0x182cc1=_0x16e1a9;if(_0x6feda[_0x182cc1('0x25f4')]&&_0x6feda[_0x182cc1('0x25f4')][_0x182cc1('0x61a')]&&_0x6feda[_0x182cc1('0x25f4')]['errors'][_0x182cc1('0x264b')]){_0xa2fd0f['errors']=_0x6feda[_0x182cc1('0x25f4')][_0x182cc1('0x61a')]||[{'message':_0x6feda[_0x182cc1('0x1586')](),'type':'api.user.delete'}];for(let _0xc5eb06=0x0;_0xc5eb06<_0x6feda[_0x182cc1('0x25f4')][_0x182cc1('0x61a')][_0x182cc1('0x264b')];_0xc5eb06++){_0x31d838['error']({'title':_0x6feda[_0x182cc1('0x25f4')]['errors'][_0xc5eb06][_0x182cc1('0x1345')],'msg':_0x6feda['data'][_0x182cc1('0x61a')][_0xc5eb06][_0x182cc1('0x1e70')]});}}else _0x31d838['error']({'title':_0x6feda[_0x182cc1('0x52d')]?'API:'+_0x6feda[_0x182cc1('0x52d')]+_0x182cc1('0x11e1')+_0x6feda[_0x182cc1('0xe1b')]:_0x182cc1('0x1304'),'msg':_0x6feda[_0x182cc1('0x25f4')]?JSON['stringify'](_0x6feda[_0x182cc1('0x25f4')][_0x182cc1('0x1e70')]):_0x6feda[_0x182cc1('0x1e70')]||_0x6feda[_0x182cc1('0x1586')]()});});},function(){});}function _0x5f21d2(_0x255020){return _0x255020===null?undefined:new Date(_0x255020);}function _0x444566(_0x1af689){const _0x3fe303=_0x3c5be7;_0x9e234f[_0x3fe303('0x1197')](_0x1af689);}}const _0x94164c=_0x185208;_0x2fd9be[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x887'),_0x36e6f4('0xf8a'),_0x36e6f4('0x21ef')];function _0x2fd9be(_0x198a7a,_0x3672e2,_0x25e3ce,_0x2a588b,_0x573793,_0x429015,_0x1f4d1c){const _0x1af52d=_0x36e6f4,_0x268ebe=this;_0x268ebe[_0x1af52d('0x98')]=_0x1f4d1c[_0x1af52d('0x26cd')](),_0x268ebe['errors']=[],_0x268ebe[_0x1af52d('0xf8a')]=_0x429015,_0x268ebe['passwordPattern']=_0x268ebe[_0x1af52d('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x268ebe[_0x1af52d('0x887')]=_0x573793,_0x268ebe[_0x1af52d('0x26e8')]='',_0x268ebe[_0x1af52d('0x27f2')]='',_0x268ebe['savePassword']=_0x1e41f6,_0x268ebe[_0x1af52d('0x24a0')]=_0x3d5569,_0x198a7a['$watch'](_0x1af52d('0x2560'),function(_0x463405){const _0x2986bd=_0x1af52d;!_0x2cfb05()[_0x2986bd('0x2863')](_0x268ebe['oldPassword'])&&(_0x463405===_0x268ebe[_0x2986bd('0x27f2')]?_0x198a7a[_0x2986bd('0x1a0a')][_0x2986bd('0x26e8')]['$setValidity']('oldPasswordMatch',![]):_0x198a7a[_0x2986bd('0x1a0a')][_0x2986bd('0x26e8')][_0x2986bd('0x28c9')](_0x2986bd('0x25a9'),!![]));});function _0x1e41f6(){const _0xc95b5b=_0x1af52d;_0x268ebe[_0xc95b5b('0x61a')]=[];const _0x3c77f7={'id':_0x268ebe[_0xc95b5b('0x887')]['id'],'newPassword':_0x268ebe[_0xc95b5b('0x26e8')]};_0x268ebe[_0xc95b5b('0x98')]['id']==_0x268ebe['telephone']['id']&&(_0x3c77f7[_0xc95b5b('0x27f2')]=_0x268ebe[_0xc95b5b('0x27f2')]),_0x2a588b[_0xc95b5b('0x557')]['changePassword'](_0x3c77f7)[_0xc95b5b('0xa44')][_0xc95b5b('0x1166')](function(){_0x25e3ce['success']({'title':'Telephone\x20password\x20properly\x20updated!'}),_0x3d5569();})[_0xc95b5b('0x1a80')](function(_0x1b614){const _0x2a8db5=_0xc95b5b;_0x25e3ce['error']({'title':_0x1b614[_0x2a8db5('0x52d')]?_0x2a8db5('0x1e21')+_0x1b614[_0x2a8db5('0x52d')]+'\x20-\x20'+_0x1b614[_0x2a8db5('0xe1b')]:_0x2a8db5('0x78c'),'msg':_0x1b614[_0x2a8db5('0x25f4')]?JSON['stringify'](_0x1b614[_0x2a8db5('0x25f4')][_0x2a8db5('0x1e70')]):_0x1b614[_0x2a8db5('0x1586')]()}),_0x268ebe['errors']=_0x1b614[_0x2a8db5('0x25f4')][_0x2a8db5('0x61a')]||[{'message':_0x1b614['toString'](),'type':_0x2a8db5('0x1ad')}];});}function _0x3d5569(){_0x3672e2['hide']();}}const _0x389520=_0x2fd9be,_0x1a6427=_0x2734b2['p']+'src/js/modules/main/apps/staff/views/telephones/edit/changepassword/changepassword.html/changepassword.html';_0x38ab44[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x887'),_0x36e6f4('0x17aa')];function _0x38ab44(_0x43fa43,_0x127f4c,_0x300466,_0xddde8e,_0x453608,_0x13c8fb,_0x373165,_0x3b9691,_0x3139a4,_0xea49ff,_0x686724,_0x481357){const _0x284901=_0x36e6f4,_0x3e01b7=this;_0x3e01b7[_0x284901('0x98')]=_0xea49ff['getCurrentUser'](),_0x3e01b7[_0x284901('0x5c9')]=_0x13c8fb,_0x3e01b7[_0x284901('0xf8a')]=_0x373165,_0x3e01b7[_0x284901('0x2900')]=_0x3e01b7[_0x284901('0xf8a')][_0x284901('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3e01b7[_0x284901('0x246b')]=_0x127f4c['protocol']()+_0x284901('0xc51')+_0x127f4c[_0x284901('0x1690')](),_0x3e01b7[_0x284901('0x887')]=_0x686724||_0x43fa43[_0x284901('0x23f')][_0x284901('0x887')]||{},_0x3e01b7[_0x284901('0x17aa')]=_0x481357&&_0x481357[_0x284901('0x240f')]==0x1?_0x481357[_0x284901('0x269a')][0x0]:null,_0x3e01b7[_0x284901('0x243c')]=_0xea49ff['parseCrudPermissions'](_0x3e01b7[_0x284901('0x17aa')]?_0x3e01b7['userProfileSection'][_0x284901('0x243c')]:null),_0x3e01b7[_0x284901('0x128b')]={},_0x3e01b7['selectedTab']=_0x43fa43[_0x284901('0x23f')]['tab']||0x0,_0x3e01b7[_0x284901('0x824')]=_0x5ac6c7,_0x3e01b7[_0x284901('0x31d')]=_0x3139a4[_0x284901('0x1fa1')],_0x3e01b7[_0x284901('0x1a89')]=_0x4e7357,_0x3e01b7['saveTelephone']=_0x100e2b,_0xea49ff[_0x284901('0x1ac6')](_0x284901('0xa7c'))?_0x3b9691[_0x284901('0x23b1')][_0x284901('0xd83')]({'fields':_0x284901('0x1776'),'sort':_0x284901('0x4f0')})['$promise'][_0x284901('0x1166')](function(_0x5a53ad){const _0x309aab=_0x284901;_0x3e01b7[_0x309aab('0x160a')]=_0x5a53ad[_0x309aab('0x269a')]||[];})[_0x284901('0x1a80')](function(_0x508ca7){const _0x2476d7=_0x284901;_0x3139a4[_0x2476d7('0xfc9')]({'title':_0x508ca7[_0x2476d7('0x52d')]?_0x2476d7('0x1e21')+_0x508ca7[_0x2476d7('0x52d')]+_0x2476d7('0x11e1')+_0x508ca7[_0x2476d7('0xe1b')]:_0x2476d7('0x140d'),'msg':_0x508ca7['data']?JSON[_0x2476d7('0xbac')](_0x508ca7[_0x2476d7('0x25f4')]):_0x508ca7[_0x2476d7('0x1586')]()});}):_0x3b9691[_0x284901('0x23b1')][_0x284901('0xd83')]({'fields':'id,name','sort':_0x284901('0x4f0')})['$promise'][_0x284901('0x1166')](function(_0x35d2db){const _0x103f04=_0x284901;_0x3e01b7[_0x103f04('0x160a')]=_0x35d2db['rows']||[];})[_0x284901('0x1166')](function(){const _0x3e7273=_0x284901;return _0x3b9691[_0x3e7273('0x17aa')]['get']({'userProfileId':_0x3e01b7[_0x3e7273('0x98')][_0x3e7273('0xb86')],'sectionId':0x195})[_0x3e7273('0xa44')];})['then'](function(_0x10f971){const _0x23d456=_0x284901,_0x502105=_0x10f971&&_0x10f971[_0x23d456('0x269a')]?_0x10f971[_0x23d456('0x269a')][0x0]:null;if(!_0x502105)return _0x3b9691[_0x23d456('0x23b1')][_0x23d456('0xd83')]({'fields':_0x23d456('0x1776'),'sort':'name','defaultEntry':0x1})[_0x23d456('0xa44')][_0x23d456('0x1166')](function(_0x14d2ca){const _0x4cabaa=_0x23d456;_0x3e01b7[_0x4cabaa('0x160a')]=_0x14d2ca['rows']||[];});else{if(!_0x502105[_0x23d456('0x1a2b')])return _0x3b9691['userProfileResource'][_0x23d456('0xd83')]({'sectionId':_0x502105['id']})[_0x23d456('0xa44')][_0x23d456('0x1166')](function(_0x5ec272){const _0x3281ae=_0x23d456,_0x18d1b9=_0x2cfb05()[_0x3281ae('0x2563')](_0x5ec272[_0x3281ae('0x269a')],function(_0x1efaa5){const _0x3b3189=_0x3281ae;return _0x2cfb05()[_0x3b3189('0xc38')](_0x3e01b7[_0x3b3189('0x160a')],{'id':_0x1efaa5[_0x3b3189('0x24e8')]});});let _0x46241c=null;_0x3e01b7['telephone']&&(_0x46241c=_0x2cfb05()[_0x3281ae('0xc38')](_0x3e01b7[_0x3281ae('0x160a')],{'name':_0x3e01b7[_0x3281ae('0x887')]['context']}));if(_0x46241c&&!_0x2cfb05()['some'](_0x18d1b9,['id',_0x46241c['id']])){const _0x579b44=_0x2cfb05()['find'](_0x3e01b7[_0x3281ae('0x160a')],{'id':_0x46241c['id']});_0x579b44[_0x3281ae('0x2378')]=![],_0x18d1b9[_0x3281ae('0x1514')](_0x579b44);}_0x3e01b7['contexts']=_0x18d1b9;});}})[_0x284901('0x1a80')](function(_0x487094){const _0x15e70a=_0x284901;_0x3139a4[_0x15e70a('0xfc9')]({'title':_0x487094[_0x15e70a('0x52d')]?_0x15e70a('0x1e21')+_0x487094['status']+_0x15e70a('0x11e1')+_0x487094[_0x15e70a('0xe1b')]:'SYSTEM:GETcontexts','msg':_0x487094[_0x15e70a('0x25f4')]?JSON[_0x15e70a('0xbac')](_0x487094[_0x15e70a('0x25f4')]):_0x487094['toString']()});});function _0x5ac6c7(_0x9153ca,_0x3498cd){const _0x116d8e=_0x284901;_0x300466['show']({'controller':_0x116d8e('0x2024'),'controllerAs':'vm','templateUrl':_0x1a6427,'parent':angular[_0x116d8e('0x1194')](_0xddde8e[_0x116d8e('0x8d2')]),'targetEvent':_0x3498cd,'clickOutsideToClose':!![],'locals':{'telephone':_0x9153ca,'setting':_0x373165,'telephones':_0x3e01b7[_0x116d8e('0x20f9')]?_0x3e01b7[_0x116d8e('0x20f9')][_0x116d8e('0x269a')]:[],'crudPermissions':_0x3e01b7[_0x116d8e('0x243c')]}});}function _0x4e7357(){const _0xe5bde8=_0x284901;_0x43fa43['go'](_0xe5bde8('0x1e59'),{},{'reload':'app.staff.telephones'});}function _0x100e2b(){const _0x6477fc=_0x284901;_0x3b9691[_0x6477fc('0x557')][_0x6477fc('0x1449')]({'id':_0x3e01b7[_0x6477fc('0x887')]['id']},_0x3e01b7[_0x6477fc('0x887')])['$promise']['then'](function(){const _0xd72c02=_0x6477fc;_0x3139a4['success']({'title':_0xd72c02('0xfdd'),'msg':_0x3e01b7[_0xd72c02('0x887')][_0xd72c02('0x4f0')]?_0x3e01b7[_0xd72c02('0x887')][_0xd72c02('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x6477fc('0x1a80')](function(_0x303c68){const _0x374b6d=_0x6477fc;_0x3139a4[_0x374b6d('0xfc9')]({'title':_0x303c68['status']?_0x374b6d('0x1e21')+_0x303c68['status']+_0x374b6d('0x11e1')+_0x303c68[_0x374b6d('0xe1b')]:_0x374b6d('0xf82'),'msg':_0x303c68[_0x374b6d('0x25f4')]?JSON[_0x374b6d('0xbac')](_0x303c68[_0x374b6d('0x25f4')]):_0x303c68[_0x374b6d('0x1586')]()});});}}const _0x2e9e52=_0x38ab44,_0x47a2a1=_0x2734b2['p']+'src/js/modules/main/apps/staff/views/telephones/create/dialog.html/dialog.html';_0x380998[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),'$document','$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x20f9'),'userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x380998(_0x481c29,_0x1eb3dc,_0x51ef5b,_0x1353c2,_0x26f60d,_0x5bf4cf,_0x44a684,_0x399636,_0x4b5fe2,_0x173a98,_0x412788,_0x2b0fd0,_0x5b7ad3,_0x5c7330,_0x1929bd,_0x126e98,_0x246fd8){const _0xa2e29c=_0x36e6f4,_0x434333=this;_0x434333[_0xa2e29c('0x5c9')]=_0x126e98,_0x434333[_0xa2e29c('0xf8a')]=_0x246fd8,_0x434333[_0xa2e29c('0x98')]=_0x1929bd[_0xa2e29c('0x26cd')](),_0x434333[_0xa2e29c('0x20f9')]=_0x4b5fe2||{'count':0x0,'rows':[]},_0x434333[_0xa2e29c('0x7f')]=_0x173a98,_0x434333[_0xa2e29c('0x17aa')]=_0x412788&&_0x412788['count']==0x1?_0x412788[_0xa2e29c('0x269a')][0x0]:null,_0x434333[_0xa2e29c('0x243c')]=_0x1929bd[_0xa2e29c('0xd87')](_0x434333['userProfileSection']?_0x434333[_0xa2e29c('0x17aa')][_0xa2e29c('0x243c')]:null),_0x434333[_0xa2e29c('0x916')]='telephones',_0x434333[_0xa2e29c('0xef5')]='',_0x434333['listOrderAsc']=null,_0x434333[_0xa2e29c('0x1fea')]=[],_0x434333['query']={'fields':_0xa2e29c('0xd5b'),'role':_0xa2e29c('0x887'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x434333['arraytransport']=_0x2cfb05()[_0xa2e29c('0x155c')]([{'option':_0xa2e29c('0x8fc'),'value':'\x27udp\x27'},{'option':'tcp','value':'\x27tcp\x27'},{'option':'ws','value':_0xa2e29c('0x1eb6')},{'option':_0xa2e29c('0x83a'),'value':_0xa2e29c('0x28da')},{'option':_0xa2e29c('0xf49'),'value':_0xa2e29c('0x1db6')}],function(_0x24d787){const _0x4a9760=_0xa2e29c;return _0x2cfb05()[_0x4a9760('0xf3')](_0x24d787[_0x4a9760('0x18e0')],new RegExp('\x27','g'),'');}),_0x434333[_0xa2e29c('0x1c9')]=_0x2cfb05()[_0xa2e29c('0x155c')]([{'option':'force_rport','value':_0xa2e29c('0x553')},{'option':_0xa2e29c('0x232d'),'value':_0xa2e29c('0x3e6')},{'option':'yes','value':'\x27yes\x27'},{'option':'no','value':_0xa2e29c('0x119b')},{'option':_0xa2e29c('0x122f'),'value':_0xa2e29c('0x130c')},{'option':_0xa2e29c('0x16a8'),'value':_0xa2e29c('0x1375')}],function(_0x33af70){const _0x4314c4=_0xa2e29c;return _0x2cfb05()[_0x4314c4('0xf3')](_0x33af70[_0x4314c4('0x18e0')],new RegExp('\x27','g'),'');}),_0x434333[_0xa2e29c('0x140')]=_0x2cfb05()[_0xa2e29c('0x155c')]([{'option':_0xa2e29c('0x1838'),'value':_0xa2e29c('0x166f')},{'option':'alaw','value':'\x27alaw\x27'},{'option':_0xa2e29c('0x1cd9'),'value':_0xa2e29c('0xd74')},{'option':_0xa2e29c('0x27f0'),'value':_0xa2e29c('0x1ae2')},{'option':_0xa2e29c('0x19b7'),'value':'\x27g729\x27'},{'option':'opus','value':_0xa2e29c('0x1fbd')},{'option':_0xa2e29c('0x173a'),'value':'\x27h264\x27'}],function(_0x213d06){const _0x567f65=_0xa2e29c;return _0x2cfb05()[_0x567f65('0xf3')](_0x213d06[_0x567f65('0x18e0')],new RegExp('\x27','g'),'');}),_0x434333[_0xa2e29c('0x1f32')]=_0x2cfb05()[_0xa2e29c('0x155c')]([{'option':_0xa2e29c('0x193c'),'value':_0xa2e29c('0x20b3')},{'option':'No','value':_0xa2e29c('0x119b')},{'option':_0xa2e29c('0x70f'),'value':_0xa2e29c('0x312')}],function(_0x3b9857){const _0x53f443=_0xa2e29c;return _0x2cfb05()['replace'](_0x3b9857[_0x53f443('0x18e0')],new RegExp('\x27','g'),'');}),_0x434333[_0xa2e29c('0xf48')]=_0x2cfb05()['keyBy']([{'option':_0xa2e29c('0x55d'),'value':_0xa2e29c('0x20b3')},{'option':'no','value':'\x27no\x27'}],function(_0xe1949b){const _0x37db29=_0xa2e29c;return _0x2cfb05()[_0x37db29('0xf3')](_0xe1949b[_0x37db29('0x18e0')],new RegExp('\x27','g'),'');}),_0x434333[_0xa2e29c('0x1ff6')]=_0x4ae28b,_0x434333[_0xa2e29c('0x8d8')]=_0xb9045e,_0x434333[_0xa2e29c('0x103b')]=_0x503181,_0x434333['getTelephones']=_0x428230,_0x434333[_0xa2e29c('0x898')]=_0x5330fc,_0x434333[_0xa2e29c('0x164b')]=_0x568343,_0x434333[_0xa2e29c('0x24e')]=_0x9fc5e4,_0x434333['deleteSelectedTelephones']=_0x35dbf1,_0x434333[_0xa2e29c('0xffa')]=_0x257395,_0x434333[_0xa2e29c('0x260c')]=_0x278080;function _0x4ae28b(_0xa5e9b7){const _0x126220=_0xa2e29c;_0x51ef5b['go'](_0x126220('0x153c'),{'id':_0xa5e9b7['id'],'telephone':_0xa5e9b7,'crudPermissions':_0x434333[_0x126220('0x243c')]});}function _0xb9045e(_0x34b872,_0x2029fd){const _0x2222a1=_0xa2e29c,_0x309c44=_0x26f60d[_0x2222a1('0x1d26')]()[_0x2222a1('0xcdc')](_0x2222a1('0x288d')+_0x2cfb05()['startCase'](_0x2222a1('0x887'))+'?')['htmlContent'](_0x2222a1('0x12b5')+(_0x34b872[_0x2222a1('0x4f0')]||_0x2222a1('0x887'))+_0x2222a1('0xace')+_0x2222a1('0x3f3'))[_0x2222a1('0x8e8')](_0x2222a1('0x26da'))['targetEvent'](_0x2029fd)['ok']('OK')[_0x2222a1('0x3f')](_0x2222a1('0x2d3'));_0x26f60d['show'](_0x309c44)[_0x2222a1('0x1166')](function(){_0x568343(_0x34b872);},function(){const _0x6bbdf4=_0x2222a1;console[_0x6bbdf4('0x455')](_0x6bbdf4('0x2d3'));});}let _0x523cc9=!![],_0x23c7c3=0x1;_0x481c29[_0xa2e29c('0xe83')](_0xa2e29c('0x12d8'),function(_0x107ed5,_0x355e2d){const _0x284511=_0xa2e29c;_0x523cc9?_0x44a684(function(){_0x523cc9=![];}):(!_0x355e2d&&(_0x23c7c3=_0x434333[_0x284511('0x2218')]['page']),_0x107ed5!==_0x355e2d&&(_0x434333['query'][_0x284511('0x1a43')]=0x1),!_0x107ed5&&(_0x434333[_0x284511('0x2218')]['page']=_0x23c7c3),_0x434333[_0x284511('0x907')]());});function _0x503181(_0x16f05){const _0x48854a=_0xa2e29c;_0x434333[_0x48854a('0x20f9')]=_0x16f05||{'count':0x0,'rows':[]};}function _0x428230(){const _0x493f35=_0xa2e29c;_0x434333[_0x493f35('0x2218')][_0x493f35('0x1098')]=(_0x434333['query'][_0x493f35('0x1a43')]-0x1)*_0x434333[_0x493f35('0x2218')][_0x493f35('0x163f')],_0x1929bd['hasRole']('admin')?_0x434333['promise']=_0x2b0fd0[_0x493f35('0x557')][_0x493f35('0xd83')](_0x434333[_0x493f35('0x2218')],_0x503181)[_0x493f35('0xa44')]:(_0x434333[_0x493f35('0x2218')]['id']=_0x434333[_0x493f35('0x7f')]['id'],_0x434333[_0x493f35('0x2218')][_0x493f35('0xe60')]=_0x493f35('0x2323'),_0x434333['promise']=_0x2b0fd0[_0x493f35('0x7f')][_0x493f35('0x263a')](_0x434333['query'],_0x503181)[_0x493f35('0xa44')]);}function _0x5330fc(_0x10df7f,_0x3924ab){const _0x5e5767=_0xa2e29c;_0x26f60d[_0x5e5767('0x1f80')]({'controller':'CreateOrEditTelephoneDialogController','controllerAs':'vm','templateUrl':_0x47a2a1,'parent':angular[_0x5e5767('0x1194')](_0x5bf4cf[_0x5e5767('0x8d2')]),'targetEvent':_0x10df7f,'clickOutsideToClose':!![],'locals':{'telephone':_0x3924ab,'telephones':_0x434333[_0x5e5767('0x20f9')][_0x5e5767('0x269a')],'license':_0x434333['license'],'setting':_0x434333[_0x5e5767('0xf8a')],'crudPermissions':_0x434333[_0x5e5767('0x243c')]}});}function _0x568343(_0x7f2bbd){const _0x4aaa19=_0xa2e29c;_0x2b0fd0[_0x4aaa19('0x557')][_0x4aaa19('0x906')]({'id':_0x7f2bbd['id']})['$promise']['then'](function(){const _0x5bf3c4=_0x4aaa19;_0x2cfb05()[_0x5bf3c4('0x127f')](_0x434333[_0x5bf3c4('0x20f9')][_0x5bf3c4('0x269a')],{'id':_0x7f2bbd['id']}),_0x434333[_0x5bf3c4('0x20f9')]['count']-=0x1,!_0x434333[_0x5bf3c4('0x20f9')][_0x5bf3c4('0x269a')][_0x5bf3c4('0x264b')]&&_0x434333[_0x5bf3c4('0x907')](),_0x5c7330[_0x5bf3c4('0x103b')]({'title':_0x2cfb05()[_0x5bf3c4('0xb35')](_0x5bf3c4('0xf2f'))+_0x5bf3c4('0x2b6'),'msg':_0x7f2bbd[_0x5bf3c4('0x4f0')]?_0x7f2bbd[_0x5bf3c4('0x4f0')]+_0x5bf3c4('0x7cd'):''});})[_0x4aaa19('0x1a80')](function(_0x467397){const _0x4d6636=_0x4aaa19;if(_0x467397[_0x4d6636('0x25f4')]&&_0x467397[_0x4d6636('0x25f4')]['errors']&&_0x467397['data']['errors'][_0x4d6636('0x264b')]){_0x434333[_0x4d6636('0x61a')]=_0x467397[_0x4d6636('0x25f4')][_0x4d6636('0x61a')]||[{'message':_0x467397[_0x4d6636('0x1586')](),'type':_0x4d6636('0x1f16')}];for(let _0xb9bdf5=0x0;_0xb9bdf5<_0x467397['data'][_0x4d6636('0x61a')][_0x4d6636('0x264b')];_0xb9bdf5++){_0x5c7330['error']({'title':_0x467397[_0x4d6636('0x25f4')][_0x4d6636('0x61a')][_0xb9bdf5][_0x4d6636('0x1345')],'msg':_0x467397[_0x4d6636('0x25f4')][_0x4d6636('0x61a')][_0xb9bdf5][_0x4d6636('0x1e70')]});}}else _0x5c7330[_0x4d6636('0xfc9')]({'title':_0x467397[_0x4d6636('0x52d')]?'API:'+_0x467397[_0x4d6636('0x52d')]+_0x4d6636('0x11e1')+_0x467397[_0x4d6636('0xe1b')]:_0x4d6636('0x1f16'),'msg':_0x467397[_0x4d6636('0x25f4')]?JSON['stringify'](_0x467397[_0x4d6636('0x25f4')][_0x4d6636('0x1e70')]):_0x467397[_0x4d6636('0x1e70')]||_0x467397[_0x4d6636('0x1586')]()});});}function _0x9fc5e4(){const _0x7fa240=_0xa2e29c,_0x23003f=angular[_0x7fa240('0x225f')](_0x434333[_0x7fa240('0x1fea')]);return _0x434333[_0x7fa240('0x1fea')]=[],_0x23003f;}function _0x35dbf1(_0x5a9f5e){const _0x2f2082=_0xa2e29c,_0x2804eb=_0x26f60d[_0x2f2082('0x1d26')]()[_0x2f2082('0xcdc')](_0x2f2082('0xdea'))[_0x2f2082('0xf3c')](_0x2f2082('0x12b5')+_0x434333[_0x2f2082('0x1fea')][_0x2f2082('0x264b')]+_0x2f2082('0x196d')+_0x2f2082('0x3f3'))[_0x2f2082('0x8e8')](_0x2f2082('0x5bc'))['targetEvent'](_0x5a9f5e)['ok']('OK')[_0x2f2082('0x3f')](_0x2f2082('0x2d3'));_0x26f60d[_0x2f2082('0x1f80')](_0x2804eb)[_0x2f2082('0x1166')](function(){const _0xa5f1d1=_0x2f2082;_0x434333[_0xa5f1d1('0x1fea')][_0xa5f1d1('0x2782')](function(_0x1c60e6){_0x568343(_0x1c60e6);}),_0x434333[_0xa5f1d1('0x1fea')]=[];});}function _0x257395(){_0x434333['selectedTelephones']=[];}function _0x278080(){const _0x2d3eb2=_0xa2e29c;_0x434333[_0x2d3eb2('0x1fea')]=_0x434333[_0x2d3eb2('0x20f9')][_0x2d3eb2('0x269a')];}}const _0x524483=_0x380998;_0x20c138[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x11e3'),_0x36e6f4('0x7f'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting','crudPermissions'];function _0x20c138(_0x3fb422,_0x1c1f47,_0x33a991,_0x3ee84e,_0x4fede2,_0x12e74f,_0x54bd4c,_0x23298,_0x15ccf7,_0x5563e0,_0x297f0d,_0x178fff,_0x3adf92,_0x443293){const _0x2916b9=_0x36e6f4,_0x228edb=this;_0x228edb[_0x2916b9('0x98')]=_0x297f0d[_0x2916b9('0x26cd')](),_0x228edb[_0x2916b9('0x61a')]=[],_0x228edb['setting']=_0x3adf92,_0x228edb[_0x2916b9('0x5c9')]=_0x178fff,_0x228edb[_0x2916b9('0x243c')]=_0x443293,_0x228edb[_0x2916b9('0x128b')]={},_0x228edb['passwordPattern']=_0x228edb['setting']&&_0x228edb[_0x2916b9('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x228edb['title']=_0x2916b9('0x1094'),_0x228edb[_0x2916b9('0x7f')]=angular[_0x2916b9('0x225f')](_0x15ccf7),_0x228edb[_0x2916b9('0x11e3')]=_0x23298,_0x228edb['newUserProfile']=![];!_0x228edb[_0x2916b9('0x7f')]&&(_0x228edb['userProfile']={'crudPermissions':['r']},_0x228edb[_0x2916b9('0xcdc')]=_0x2916b9('0x6d6'),_0x228edb['newUserProfile']=!![]);_0x228edb[_0x2916b9('0x14a')]=_0x56ad4a,_0x228edb['saveUserProfile']=_0x2956f4,_0x228edb['deleteUserProfile']=_0x145280,_0x228edb[_0x2916b9('0x1a9c')]=_0x8038c4,_0x228edb[_0x2916b9('0x24a0')]=_0x4c26c7;function _0x56ad4a(){const _0x4a1c33=_0x2916b9;_0x228edb[_0x4a1c33('0x61a')]=[],_0x5563e0[_0x4a1c33('0x7f')][_0x4a1c33('0x9cc')](_0x228edb[_0x4a1c33('0x7f')])[_0x4a1c33('0xa44')][_0x4a1c33('0x1166')](function(_0x1368bd){const _0x1c77ce=_0x4a1c33;_0x24317d(_0x1368bd),_0x228edb[_0x1c77ce('0x11e3')][_0x1c77ce('0x2450')](_0x1368bd['toJSON']()),_0x54bd4c['success']({'title':_0x1c77ce('0x118d'),'msg':_0x228edb[_0x1c77ce('0x7f')][_0x1c77ce('0x4f0')]?_0x228edb['userProfile'][_0x1c77ce('0x4f0')]+_0x1c77ce('0x1eda'):''}),_0x4c26c7(_0x1368bd);})[_0x4a1c33('0x1a80')](function(_0x2ee5e6){const _0x2718b8=_0x4a1c33;if(_0x2ee5e6[_0x2718b8('0x25f4')]&&_0x2ee5e6['data'][_0x2718b8('0x61a')]&&_0x2ee5e6[_0x2718b8('0x25f4')]['errors'][_0x2718b8('0x264b')]){_0x228edb[_0x2718b8('0x61a')]=_0x2ee5e6[_0x2718b8('0x25f4')]['errors']||[{'message':_0x2ee5e6[_0x2718b8('0x1586')](),'type':_0x2718b8('0x1f0b')}];for(let _0x5e1289=0x0;_0x5e1289<_0x2ee5e6['data']['errors'][_0x2718b8('0x264b')];_0x5e1289+=0x1){_0x54bd4c['error']({'title':_0x2ee5e6[_0x2718b8('0x25f4')][_0x2718b8('0x61a')][_0x5e1289][_0x2718b8('0x1345')],'msg':_0x2ee5e6[_0x2718b8('0x25f4')]['errors'][_0x5e1289][_0x2718b8('0x1e70')]});}}else _0x54bd4c[_0x2718b8('0xfc9')]({'title':_0x2ee5e6[_0x2718b8('0x52d')]?_0x2718b8('0x1e21')+_0x2ee5e6[_0x2718b8('0x52d')]+'\x20-\x20'+_0x2ee5e6['statusText']:_0x2718b8('0x1f0b'),'msg':_0x2ee5e6['data']?JSON[_0x2718b8('0xbac')](_0x2ee5e6['data']['message']):_0x2ee5e6[_0x2718b8('0x1586')]()});});}function _0x2956f4(){const _0x2c45c3=_0x2916b9;_0x228edb[_0x2c45c3('0x61a')]=[],_0x5563e0[_0x2c45c3('0x7f')][_0x2c45c3('0x1449')]({'id':_0x228edb['userProfile']['id']},_0x228edb[_0x2c45c3('0x7f')])[_0x2c45c3('0xa44')][_0x2c45c3('0x1166')](function(_0x1d47e1){const _0x227a3f=_0x2c45c3,_0x16c617=_0x2cfb05()['find'](_0x228edb[_0x227a3f('0x11e3')],{'id':_0x1d47e1['id']});_0x16c617&&_0x2cfb05()[_0x227a3f('0xcc3')](_0x16c617,_0x2cfb05()[_0x227a3f('0x1a08')](_0x1d47e1['toJSON'](),_0x2cfb05()[_0x227a3f('0x14a4')](_0x16c617))),_0x54bd4c[_0x227a3f('0x103b')]({'title':_0x227a3f('0x1c01'),'msg':_0x228edb['userProfile'][_0x227a3f('0x4f0')]?_0x228edb[_0x227a3f('0x7f')][_0x227a3f('0x4f0')]+_0x227a3f('0x7d'):''}),_0x4c26c7(_0x1d47e1);})['catch'](function(_0x49c58b){const _0x32e2a1=_0x2c45c3;if(_0x49c58b[_0x32e2a1('0x25f4')]&&_0x49c58b[_0x32e2a1('0x25f4')][_0x32e2a1('0x61a')]&&_0x49c58b['data'][_0x32e2a1('0x61a')]['length']){_0x228edb['errors']=_0x49c58b[_0x32e2a1('0x25f4')]['errors']||[{'message':_0x49c58b[_0x32e2a1('0x1586')](),'type':'api.userProfile.update'}];for(let _0x4b9fee=0x0;_0x4b9fee<_0x49c58b[_0x32e2a1('0x25f4')][_0x32e2a1('0x61a')][_0x32e2a1('0x264b')];_0x4b9fee++){_0x54bd4c[_0x32e2a1('0xfc9')]({'title':_0x49c58b[_0x32e2a1('0x25f4')][_0x32e2a1('0x61a')][_0x4b9fee][_0x32e2a1('0x1345')],'msg':_0x49c58b[_0x32e2a1('0x25f4')][_0x32e2a1('0x61a')][_0x4b9fee]['message']});}}else _0x54bd4c[_0x32e2a1('0xfc9')]({'title':_0x49c58b[_0x32e2a1('0x52d')]?_0x32e2a1('0x1e21')+_0x49c58b[_0x32e2a1('0x52d')]+_0x32e2a1('0x11e1')+_0x49c58b[_0x32e2a1('0xe1b')]:_0x32e2a1('0xdb7'),'msg':_0x49c58b[_0x32e2a1('0x25f4')]?JSON[_0x32e2a1('0xbac')](_0x49c58b['data'][_0x32e2a1('0x1e70')]):_0x49c58b[_0x32e2a1('0x1586')]()});});}function _0x145280(_0x213297){const _0x3ea06c=_0x2916b9;_0x228edb[_0x3ea06c('0x61a')]=[];const _0x211c2b=_0x3ee84e[_0x3ea06c('0x1d26')]()[_0x3ea06c('0xcdc')](_0x3ea06c('0x7fb'))[_0x3ea06c('0xacc')]('The\x20userProfile\x20will\x20be\x20deleted.')[_0x3ea06c('0x8e8')](_0x3ea06c('0x2a6'))['ok']('Delete')[_0x3ea06c('0x3f')](_0x3ea06c('0x497'))[_0x3ea06c('0x203b')](_0x213297);_0x3ee84e[_0x3ea06c('0x1f80')](_0x211c2b)[_0x3ea06c('0x1166')](function(){const _0x335d55=_0x3ea06c;_0x5563e0[_0x335d55('0x7f')]['delete']({'id':_0x228edb[_0x335d55('0x7f')]['id']})[_0x335d55('0xa44')]['then'](function(){const _0x30113a=_0x335d55;_0x2cfb05()[_0x30113a('0x127f')](_0x228edb[_0x30113a('0x11e3')],{'id':_0x228edb[_0x30113a('0x7f')]['id']}),_0x54bd4c[_0x30113a('0x103b')]({'title':'UserProfile\x20properly\x20deleted!','msg':(_0x228edb[_0x30113a('0x7f')][_0x30113a('0x4f0')]||_0x30113a('0x7f'))+_0x30113a('0x7cd')}),_0x4c26c7(_0x228edb[_0x30113a('0x7f')]);})[_0x335d55('0x1a80')](function(_0x27d854){const _0x2872f2=_0x335d55;if(_0x27d854[_0x2872f2('0x25f4')]&&_0x27d854[_0x2872f2('0x25f4')][_0x2872f2('0x61a')]&&_0x27d854[_0x2872f2('0x25f4')][_0x2872f2('0x61a')]['length']){_0x228edb[_0x2872f2('0x61a')]=_0x27d854[_0x2872f2('0x25f4')]['errors']||[{'message':_0x27d854[_0x2872f2('0x1586')](),'type':'api.userProfile.delete'}];for(let _0xb6a9d=0x0;_0xb6a9d<_0x27d854[_0x2872f2('0x25f4')]['errors'][_0x2872f2('0x264b')];_0xb6a9d++){_0x54bd4c[_0x2872f2('0xfc9')]({'title':_0x27d854[_0x2872f2('0x25f4')]['errors'][_0xb6a9d][_0x2872f2('0x1345')],'msg':_0x27d854[_0x2872f2('0x25f4')][_0x2872f2('0x61a')][_0xb6a9d][_0x2872f2('0x1e70')]});}}else _0x54bd4c['error']({'title':_0x27d854[_0x2872f2('0x52d')]?_0x2872f2('0x1e21')+_0x27d854[_0x2872f2('0x52d')]+_0x2872f2('0x11e1')+_0x27d854[_0x2872f2('0xe1b')]:_0x2872f2('0x32d'),'msg':_0x27d854[_0x2872f2('0x25f4')]?JSON['stringify'](_0x27d854[_0x2872f2('0x25f4')]['message']):_0x27d854[_0x2872f2('0x1e70')]||_0x27d854[_0x2872f2('0x1586')]()});});},function(){});}function _0x24317d(_0x57aa95){const _0x525fd6=_0x2916b9,_0xac232e=[];_0x57aa95['crudPermissions'][_0x525fd6('0x2782')](function(_0x2b5565){const _0x2d4665=_0x525fd6;let _0x1ef052;switch(_0x2b5565){case'r':_0x1ef052=_0x2d4665('0x1f1b');break;case'e':_0x1ef052='EDIT_PERMISSION';break;case'd':_0x1ef052=_0x2d4665('0x508');break;}_0xac232e[_0x2d4665('0x1514')](_0x12e74f[_0x2d4665('0x25cc')](_0x2d4665('0x1a8b')+_0x1ef052));}),_0x57aa95[_0x525fd6('0x1011')]=_0xac232e[_0x525fd6('0x45a')](',\x20');}function _0x8038c4(_0x5d2bbb){return _0x5d2bbb===null?undefined:new Date(_0x5d2bbb);}function _0x4c26c7(_0x95fdf6){const _0x5e8bd8=_0x2916b9;_0x3ee84e[_0x5e8bd8('0x1197')](_0x95fdf6);}}const _0x48a031=_0x20c138;_0x1c79b7[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x7b9'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x7f'),_0x36e6f4('0x11e3'),_0x36e6f4('0x586')];function _0x1c79b7(_0x4db4af,_0x55ed17,_0x1b9d96,_0xe03db6,_0x11a0c5,_0x16d3bd,_0x2d5d58){const _0x35f773=_0x36e6f4,_0x257b26=this;_0x257b26['newUserProfile']=!![],_0x257b26[_0x35f773('0x7f')]=angular[_0x35f773('0x225f')](_0x11a0c5),_0x257b26[_0x35f773('0x11e3')]=_0x16d3bd,_0x257b26[_0x35f773('0xcdc')]=_0x2d5d58[_0x35f773('0x25cc')](_0x35f773('0x223f'));_0x11a0c5&&_0x11a0c5[_0x35f773('0x4f0')]&&(_0x257b26[_0x35f773('0xcdc')]+=':\x20'+_0x11a0c5[_0x35f773('0x4f0')]);_0x257b26['cloneUserProfile']=_0x4e1195,_0x257b26[_0x35f773('0x24a0')]=_0x226304;function _0x4e1195(){const _0x4d2a28=_0x35f773;return _0xe03db6['userProfile']['clone']({'id':_0x11a0c5['id']},_0x257b26['userProfile'])[_0x4d2a28('0xa44')][_0x4d2a28('0x1166')](function(_0x2c8252){const _0x167d9e=_0x4d2a28;_0x23b4a2(_0x2c8252),_0x257b26['userProfiles'][_0x167d9e('0x2450')](_0x2c8252[_0x167d9e('0x2876')]()),_0x1b9d96[_0x167d9e('0x103b')]({'title':'UserProfile\x20properly\x20cloned','msg':_0x257b26[_0x167d9e('0x7f')][_0x167d9e('0x4f0')]?_0x257b26[_0x167d9e('0x7f')][_0x167d9e('0x4f0')]+_0x167d9e('0x1273'):''}),_0x55ed17['go'](_0x167d9e('0x24d7'),{'id':_0x2c8252['id']}),_0x226304(_0x2c8252);})[_0x4d2a28('0x1a80')](function(_0x1edbd1){const _0x12d527=_0x4d2a28;if(_0x1edbd1[_0x12d527('0x25f4')]&&_0x1edbd1[_0x12d527('0x25f4')]['errors']&&_0x1edbd1[_0x12d527('0x25f4')][_0x12d527('0x61a')]['length']){_0x257b26[_0x12d527('0x61a')]=_0x1edbd1[_0x12d527('0x25f4')]['errors']||[{'message':_0x1edbd1[_0x12d527('0x1586')](),'type':_0x12d527('0x2d')}];for(let _0x77bcf7=0x0;_0x77bcf7<_0x1edbd1['data']['errors'][_0x12d527('0x264b')];_0x77bcf7+=0x1){_0x1b9d96[_0x12d527('0xfc9')]({'title':_0x1edbd1['data']['errors'][_0x77bcf7][_0x12d527('0x1345')],'msg':_0x1edbd1[_0x12d527('0x25f4')]['errors'][_0x77bcf7]['message']});}}else _0x1b9d96[_0x12d527('0xfc9')]({'title':_0x1edbd1[_0x12d527('0x52d')]?_0x12d527('0x1e21')+_0x1edbd1[_0x12d527('0x52d')]+_0x12d527('0x11e1')+_0x1edbd1[_0x12d527('0xe1b')]:_0x12d527('0x2d'),'msg':_0x1edbd1[_0x12d527('0x25f4')]?JSON[_0x12d527('0xbac')](_0x1edbd1[_0x12d527('0x25f4')][_0x12d527('0x1e70')]):_0x1edbd1['toString']()});});}function _0x23b4a2(_0x315360){const _0x574430=_0x35f773,_0x4c67e3=[];_0x315360['crudPermissions'][_0x574430('0x2782')](function(_0x2c18a4){const _0x2fa306=_0x574430;let _0x4b25e2;switch(_0x2c18a4){case'r':_0x4b25e2=_0x2fa306('0x1f1b');break;case'e':_0x4b25e2=_0x2fa306('0x1912');break;case'd':_0x4b25e2=_0x2fa306('0x508');break;}_0x4c67e3[_0x2fa306('0x1514')](_0x2d5d58['instant']('STAFF.'+_0x4b25e2));}),_0x315360['selectedcrudPermissions']=_0x4c67e3['join'](',\x20');}function _0x226304(_0x3b112e){const _0x28058e=_0x35f773;_0x4db4af[_0x28058e('0x1197')](_0x3b112e);}}const _0x3501ca=_0x1c79b7,_0x73208f=_0x2734b2['p']+_0x36e6f4('0xbbc');_0x1619cd[_0x36e6f4('0x1294')]=['$document','$mdDialog',_0x36e6f4('0x586'),'$q',_0x36e6f4('0x19e3'),_0x36e6f4('0x770'),_0x36e6f4('0x21ef'),'toasty'];function _0x1619cd(_0xa42ff,_0x58bcfd,_0x44b0ec,_0x96b795,_0x2d5b17,_0x13d78b,_0x4ff6c5,_0x568dc2){const _0x1c63d9=_0x36e6f4,_0xa6a176=this;_0xa6a176[_0x1c63d9('0x7f')]={},_0xa6a176[_0x1c63d9('0x5c9')]={},_0xa6a176[_0x1c63d9('0x15ea')]=_0x13d78b[_0x1c63d9('0x1568')](),_0xa6a176[_0x1c63d9('0x1219')]=_0xa6a176[_0x1c63d9('0x15ea')][0x0]['children'],_0xa6a176[_0x1c63d9('0x174c')]=[{'id':0x0,'name':_0x1c63d9('0x204a'),'color':_0x1c63d9('0x2027'),'info':_0x1c63d9('0x28d'),'tag':_0x1c63d9('0x1c4c')},{'id':0x1,'name':_0x1c63d9('0x2511'),'color':_0x1c63d9('0x127'),'info':_0x1c63d9('0x10cf'),'tag':_0x1c63d9('0x9f0')},{'id':0x2,'name':'Disabled','color':'grey-A400-bg','info':_0x1c63d9('0x1d7f'),'tag':_0x1c63d9('0xbd0')},{'id':0x3,'name':_0x1c63d9('0x1044'),'color':_0x1c63d9('0x1ddb'),'info':_0x1c63d9('0x1e66'),'tag':_0x1c63d9('0x1d3a')},{'id':0x4,'name':_0x1c63d9('0x22ad'),'color':'grey-A700-bg','info':_0x1c63d9('0xb63'),'tag':_0x1c63d9('0x22d5')}],_0xa6a176[_0x1c63d9('0x28d6')]=[{'title':'Dashboards','translate':_0x1c63d9('0x24a3'),'id':0x64}],_0xa6a176[_0x1c63d9('0x24d5')]=_0x41f619,_0xa6a176[_0x1c63d9('0x19e8')]=_0x38daf3,_0xa6a176[_0x1c63d9('0x2294')]=_0x562594,_0xa6a176[_0x1c63d9('0x2247')]=_0x491c56;function _0x41f619(_0x25e052,_0x23fe57){const _0x3ce8c8=_0x1c63d9;_0xa6a176[_0x3ce8c8('0x7f')]=_0x25e052,_0xa6a176['license']=_0x23fe57;}function _0x38daf3(_0x347701){const _0x4a208c=_0x1c63d9,_0x1b3003=typeof _0x347701[_0x4a208c('0x2868')]!==_0x4a208c('0x1048')&&!_0x347701['permissions'][_0x4a208c('0x103a')]?!![]:![],_0x462831=_0x347701[_0x4a208c('0xcdc')]===_0x4a208c('0x22b4')?_0x4a208c('0x783'):_0x347701[_0x4a208c('0xcdc')];if(_0x347701[_0x4a208c('0x52d')][_0x4a208c('0x4f0')]!==_0x4a208c('0x204a')){const _0x31c35d=[];if(!_0x1b3003){const _0x3b428c=_0x58bcfd['confirm']({'skipHide':!![]})[_0x4a208c('0xcdc')](_0x4a208c('0x9f8'))[_0x4a208c('0x2077')](_0x44b0ec[_0x4a208c('0x25cc')](_0x4a208c('0x2604'),{'sectionName':_0x44b0ec[_0x4a208c('0x25cc')](_0x347701[_0x4a208c('0x1139')])}))['ariaLabel']('Warning')['ok'](_0x44b0ec[_0x4a208c('0x25cc')](_0x4a208c('0xdfa')))[_0x4a208c('0x3f')](_0x44b0ec[_0x4a208c('0x25cc')](_0x4a208c('0x2506')));_0x58bcfd[_0x4a208c('0x1f80')](_0x3b428c)[_0x4a208c('0x1166')](function(){const _0x53ef21=_0x4a208c;switch(_0x462831){case _0x53ef21('0x20c8'):_0x2cfb05()[_0x53ef21('0x2563')](_0xa6a176['dashboardSections'],function(_0xa595ed){const _0x350c61=_0x53ef21;_0x31c35d['push']({'category':_0x462831,'sectionId':_0xa595ed['id'],'name':_0xa595ed[_0x350c61('0xcdc')],'enabled':!![],'autoAssociation':!![],'crudPermissions':_0x2cfb05()[_0x350c61('0x2563')](_0xa6a176[_0x350c61('0x7f')][_0x350c61('0x243c')])['join']('')});});break;default:_0x2cfb05()['map'](_0x347701[_0x53ef21('0x9df')],function(_0x25de7d){const _0x244a9e=_0x53ef21,_0x211f96=typeof _0x25de7d['permissions']!=_0x244a9e('0x1048')&&_0x25de7d[_0x244a9e('0x2868')][_0x244a9e('0x17d6')]?!![]:![];if(!_0x211f96){let _0x49d853=_0x25de7d[_0x244a9e('0xcdc')];switch(_0x462831){case'CallySquare':_0x49d853=_0x49d853===_0x244a9e('0xda5')?_0x244a9e('0x2503'):_0x49d853;break;}_0x31c35d[_0x244a9e('0x1514')]({'category':_0x462831,'sectionId':_0x25de7d['id'],'name':_0x49d853,'enabled':!![],'autoAssociation':!![],'crudPermissions':_0x2cfb05()[_0x244a9e('0x2563')](_0xa6a176[_0x244a9e('0x7f')][_0x244a9e('0x243c')])[_0x244a9e('0x45a')]('')});}});break;}return _0x2d5b17[_0x53ef21('0x7f')][_0x53ef21('0xc66')]({'id':_0xa6a176['userProfile']['id']},_0x31c35d)['$promise']['then'](function(){const _0x44a2a7=_0x53ef21;_0x347701[_0x44a2a7('0x52d')]=_0x3d121b(_0x347701,'full'),_0x568dc2[_0x44a2a7('0x103b')]({'title':_0x44b0ec['instant']('STAFF.NOTIFICATIONS.PERMISSIONS_ENABLED_ALL_SUCCESS_TITLE',{'sectionName':_0x44b0ec[_0x44a2a7('0x25cc')](_0x347701[_0x44a2a7('0x1139')]),'userProfileName':_0xa6a176[_0x44a2a7('0x7f')][_0x44a2a7('0x4f0')]}),'msg':_0x44b0ec['instant'](_0x44a2a7('0x21'),{'sectionName':_0x44b0ec[_0x44a2a7('0x25cc')](_0x347701['translate']),'userProfileName':_0xa6a176[_0x44a2a7('0x7f')][_0x44a2a7('0x4f0')]})});});})[_0x4a208c('0x1a80')](function(_0x3b4ac3){const _0x2b494a=_0x4a208c;_0x3b4ac3?_0x568dc2[_0x2b494a('0xfc9')]({'title':_0x3b4ac3[_0x2b494a('0x52d')]?_0x2b494a('0x1e21')+_0x3b4ac3[_0x2b494a('0x52d')]+'\x20-\x20'+_0x3b4ac3[_0x2b494a('0xe1b')]:_0x2b494a('0x1932'),'msg':_0x3b4ac3[_0x2b494a('0x52d')]?JSON[_0x2b494a('0xbac')](_0x3b4ac3[_0x2b494a('0x25f4')]):_0x3b4ac3[_0x2b494a('0x1586')]()}):_0x347701[_0x2b494a('0x52d')]=_0x3d121b(_0x347701,_0x347701['status']['tag']);});}else return _0x31c35d[_0x4a208c('0x1514')]({'category':_0x462831,'sectionId':_0x347701['id'],'name':_0x462831,'enabled':!![],'crudPermissions':_0x4a208c('0x21e2')}),_0x2d5b17[_0x4a208c('0x7f')][_0x4a208c('0xc66')]({'id':_0xa6a176[_0x4a208c('0x7f')]['id']},_0x31c35d)[_0x4a208c('0xa44')]['then'](function(){const _0x308332=_0x4a208c;_0x347701[_0x308332('0x52d')]=_0x3d121b(_0x347701,_0x308332('0x1c4c')),_0x568dc2[_0x308332('0x103b')]({'title':_0x44b0ec['instant'](_0x308332('0xdc'),{'sectionName':_0x44b0ec[_0x308332('0x25cc')](_0x347701['translate']),'userProfileName':_0xa6a176[_0x308332('0x7f')][_0x308332('0x4f0')]}),'msg':_0x44b0ec[_0x308332('0x25cc')](_0x308332('0x122d'),{'sectionName':_0x44b0ec['instant'](_0x347701['translate']),'userProfileName':_0xa6a176[_0x308332('0x7f')][_0x308332('0x4f0')]})});})['catch'](function(_0x5e4f54){const _0x3d3d55=_0x4a208c;_0x568dc2[_0x3d3d55('0xfc9')]({'title':_0x5e4f54[_0x3d3d55('0x52d')]?_0x3d3d55('0x1e21')+_0x5e4f54[_0x3d3d55('0x52d')]+_0x3d3d55('0x11e1')+_0x5e4f54[_0x3d3d55('0xe1b')]:_0x3d3d55('0x1932'),'msg':_0x5e4f54[_0x3d3d55('0x52d')]?JSON[_0x3d3d55('0xbac')](_0x5e4f54[_0x3d3d55('0x25f4')]):_0x5e4f54[_0x3d3d55('0x1586')]()});});}else{if(_0x347701[_0x4a208c('0x52d')][_0x4a208c('0x4f0')]==='Fully\x20Enabled'){_0x347701['status']=_0x3d121b(_0x347701,'disabled');let _0x5bae4d=[];switch(_0x462831){case _0x4a208c('0xa33'):case _0x4a208c('0xeae'):_0x5bae4d=[_0x347701['id']];break;case'Dashboards':_0x5bae4d=_0x2cfb05()[_0x4a208c('0x2563')](_0xa6a176[_0x4a208c('0x28d6')],function(_0x3bbabd){return _0x3bbabd['id'];});break;default:_0x5bae4d=_0x2cfb05()[_0x4a208c('0x2563')](_0x347701[_0x4a208c('0x9df')],function(_0x5bf83f){return _0x5bf83f['id'];});break;}return _0x2d5b17[_0x4a208c('0x7f')][_0x4a208c('0x1d7c')]({'id':_0xa6a176[_0x4a208c('0x7f')]['id'],'ids':_0x5bae4d})[_0x4a208c('0xa44')][_0x4a208c('0x1166')](function(){const _0x3334b9=_0x4a208c;_0x568dc2[_0x3334b9('0x103b')]({'title':_0x44b0ec[_0x3334b9('0x25cc')](_0x3334b9('0x13f3'),{'sectionName':_0x44b0ec[_0x3334b9('0x25cc')](_0x347701[_0x3334b9('0x1139')]),'userProfileName':_0xa6a176['userProfile'][_0x3334b9('0x4f0')]}),'msg':_0x44b0ec[_0x3334b9('0x25cc')](_0x3334b9('0x7b0'),{'sectionName':_0x44b0ec[_0x3334b9('0x25cc')](_0x347701[_0x3334b9('0x1139')]),'userProfileName':_0xa6a176[_0x3334b9('0x7f')]['name']})});})[_0x4a208c('0x1a80')](function(_0x155096){const _0x41db17=_0x4a208c;_0x568dc2[_0x41db17('0xfc9')]({'title':_0x155096[_0x41db17('0x52d')]?'API:'+_0x155096[_0x41db17('0x52d')]+_0x41db17('0x11e1')+_0x155096[_0x41db17('0xe1b')]:'SYSTEM:USERPROFILE.REMOVESECTIONS','msg':_0x155096[_0x41db17('0x52d')]?JSON[_0x41db17('0xbac')](_0x155096[_0x41db17('0x25f4')]):_0x155096[_0x41db17('0x1586')]()});});}}}function _0x562594(_0x402ae7,_0x46abc0){const _0x37a644=_0x1c63d9,_0x21346b=_0x58bcfd[_0x37a644('0x1f80')]({'controller':_0x37a644('0xd1'),'controllerAs':'vm','templateUrl':_0x73208f,'parent':angular['element'](_0xa42ff['body']),'targetEvent':_0x46abc0,'clickOutsideToClose':![],'locals':{'userProfile':_0xa6a176[_0x37a644('0x7f')],'userProfiles':[],'section':_0x402ae7}});_0x21346b[_0x37a644('0x1166')](function(){_0x491c56(_0x402ae7);});}function _0x3d121b(_0x420bf8,_0x1be349){const _0x524434=_0x1c63d9;_0x420bf8['allResourcesEnabled']=_0x46e505(_0x1be349);switch(_0x1be349){case _0x524434('0x1c4c'):return _0x2cfb05()['find'](_0xa6a176[_0x524434('0x174c')],[_0x524434('0x1446'),_0x524434('0x1c4c')]);case _0x524434('0x9f0'):return _0x2cfb05()[_0x524434('0xc38')](_0xa6a176[_0x524434('0x174c')],[_0x524434('0x1446'),_0x524434('0x9f0')]);case _0x524434('0xbd0'):return _0x2cfb05()[_0x524434('0xc38')](_0xa6a176[_0x524434('0x174c')],[_0x524434('0x1446'),_0x524434('0xbd0')]);case _0x524434('0x1d3a'):return _0x2cfb05()[_0x524434('0xc38')](_0xa6a176[_0x524434('0x174c')],[_0x524434('0x1446'),'unlicensed']);case _0x524434('0x22d5'):return _0x2cfb05()[_0x524434('0xc38')](_0xa6a176['statusList'],[_0x524434('0x1446'),_0x524434('0x22d5')]);default:return _0x2cfb05()['find'](_0xa6a176[_0x524434('0x174c')],[_0x524434('0x1446'),'unknown']);}}function _0x400259(_0x188886){return _0x96b795(function(_0x346302,_0x2a85b5){const _0x4fd8da=a0_0x3f2c,_0x4083e5=typeof _0x188886[_0x4fd8da('0x1298')]!=='undefined'&&_0x2cfb05()['includes'](_0x188886['route'],_0x4fd8da('0x28ba'));_0x4083e5?_0x3c1c00(_0x188886)[_0x4fd8da('0x1166')](function(_0x4968fc){_0x346302(_0x4968fc);})[_0x4fd8da('0x1a80')](function(_0x2eb5bf){_0x2a85b5(_0x2eb5bf);}):_0x524cc8(_0x188886)[_0x4fd8da('0x1166')](function(_0x3fdb4a){_0x346302(_0x3fdb4a);})['catch'](function(_0x4a164d){_0x2a85b5(_0x4a164d);});});}function _0x3c1c00(_0x29c1da){return _0x96b795(function(_0x16fbc3,_0x32ff78){const _0x8bc0aa=a0_0x3f2c,_0x49d2ff=typeof _0x29c1da[_0x8bc0aa('0x1298')]!==_0x8bc0aa('0x1048')&&_0x29c1da[_0x8bc0aa('0x1298')]==='bull'?'outbound':_0x8bc0aa('0x14d8');return _0x2d5b17[_0x29c1da[_0x8bc0aa('0x16a8')]][_0x8bc0aa('0xd83')]({'fields':'id,name,strategy,type','channel':_0x29c1da['channel']===_0x8bc0aa('0x1957')?_0x8bc0aa('0x21da'):_0x29c1da[_0x8bc0aa('0x1298')],'type':_0x49d2ff,'nolimit':!![]})[_0x8bc0aa('0xa44')][_0x8bc0aa('0x1166')](function(_0x10638e){_0x16fbc3(_0x10638e);})[_0x8bc0aa('0x1a80')](function(_0x212e32){_0x32ff78(_0x212e32);});});}function _0x524cc8(_0x35d3af){return _0x96b795(function(_0x5b1e5d,_0x3583c2){const _0x1d9fc7=a0_0x3f2c;let _0x4dee84,_0x5d9a3d,_0x4feb0e=![],_0x3d6fd4=![];switch(_0x35d3af[_0x1d9fc7('0x16a8')]){case _0x1d9fc7('0x1deb'):switch(_0x35d3af[_0x1d9fc7('0xcdc')]){case _0x1d9fc7('0x679'):_0x4dee84=_0x1d9fc7('0x14d8');break;case _0x1d9fc7('0x21f5'):_0x4dee84='outbound';break;case _0x1d9fc7('0x21ce'):_0x4dee84='internal';break;}break;case _0x1d9fc7('0x277c'):_0x4feb0e=!![];break;case _0x1d9fc7('0x12e8'):_0x3d6fd4=!![];break;case'user':switch(_0x35d3af[_0x1d9fc7('0xcdc')]){case _0x1d9fc7('0x2391'):_0x5d9a3d=_0x1d9fc7('0x1eff');break;case _0x1d9fc7('0x2323'):_0x5d9a3d=_0x1d9fc7('0x887');break;case _0x1d9fc7('0x1bc7'):_0x5d9a3d=_0x1d9fc7('0x557');break;}break;}if(_0x35d3af[_0x1d9fc7('0xcdc')]===_0x1d9fc7('0x2165')){if(_0x35d3af[_0x1d9fc7('0x2518')])switch(_0x35d3af[_0x1d9fc7('0x2518')]){case _0x1d9fc7('0x1526'):_0x35d3af[_0x1d9fc7('0x16a8')]=_0x1d9fc7('0x17c2');break;case _0x1d9fc7('0x2853'):_0x35d3af[_0x1d9fc7('0x16a8')]=_0x1d9fc7('0x1ff5');break;}else return _0x2d5b17[_0x1d9fc7('0x17c2')][_0x1d9fc7('0xd83')]({'nolimit':!![]})[_0x1d9fc7('0xa44')]['then'](function(_0x39e37b){const _0x41150d=_0x1d9fc7;_0x2d5b17[_0x41150d('0x1ff5')][_0x41150d('0xd83')]({'nolimit':!![]})[_0x41150d('0xa44')][_0x41150d('0x1166')](function(_0x16137f){const _0xd28b89=_0x41150d,_0x16e40d=_0x2cfb05()[_0xd28b89('0x1190')](_0x39e37b[_0xd28b89('0x269a')],_0x16137f[_0xd28b89('0x269a')]);_0x5b1e5d({'count':_0x16e40d[_0xd28b89('0x264b')],'rows':_0x16e40d[_0xd28b89('0x269a')]});});})[_0x1d9fc7('0x1a80')](function(_0x3eb1e5){_0x3583c2(_0x3eb1e5);});}return _0x2d5b17[_0x35d3af[_0x1d9fc7('0x16a8')]][_0x1d9fc7('0xd83')]({'role':_0x5d9a3d?_0x5d9a3d:undefined,'type':_0x4dee84?_0x4dee84:undefined,'VoiceExtensionId':_0x4dee84?'null':undefined,'IntervalId':_0x4feb0e?'null':undefined,'MailAccountId':_0x3d6fd4?_0x1d9fc7('0x15d7'):undefined,'FaxAccountId':_0x3d6fd4?_0x1d9fc7('0x15d7'):undefined,'SmsAccountId':_0x3d6fd4?_0x1d9fc7('0x15d7'):undefined,'OpenchannelAccountId':_0x3d6fd4?_0x1d9fc7('0x15d7'):undefined,'ChatWebsiteId':_0x3d6fd4?_0x1d9fc7('0x15d7'):undefined,'WhatsappAccountId':_0x3d6fd4?_0x1d9fc7('0x15d7'):undefined,'ListId':_0x3d6fd4?_0x1d9fc7('0x15d7'):undefined,'nolimit':!![]})['$promise'][_0x1d9fc7('0x1166')](function(_0x10468f){_0x5b1e5d(_0x10468f);})['catch'](function(_0x5eab62){_0x3583c2(_0x5eab62);});});}function _0x32b341(_0x30c5b7,_0x4bfaf4){return _0x96b795(function(_0x2e2b11,_0x1267b2){const _0x499cfa=a0_0x3f2c;_0x2d5b17[_0x499cfa('0x4b5')][_0x499cfa('0xd83')]({'sectionId':_0x4bfaf4})['$promise'][_0x499cfa('0x1166')](function(_0x518514){const _0x54488a=_0x499cfa;return _0x400259(_0x30c5b7)[_0x54488a('0x1166')](function(_0x48ccb3){const _0x557332=_0x54488a;return _0x2cfb05()[_0x557332('0x24ac')](_0x518514['rows'],_0x48ccb3[_0x557332('0x269a')],'id');});})['then'](function(_0x32b452){const _0x5a2df7=_0x499cfa;_0x2cfb05()[_0x5a2df7('0x1081')](_0x32b452)?_0x2e2b11():_0x1267b2();})[_0x499cfa('0x1a80')](function(_0x54f458){_0x1267b2(_0x54f458);});});}function _0x1029aa(_0x1afc76,_0x21fc59,_0x4d8150){const _0x22436b=_0x1c63d9,_0x36242c=_0x1afc76&&_0x1afc76['length']>0x0?_0x1afc76[0x0]:null;if(!_0x36242c)return _0x4d8150;const _0x29349d=_0x2cfb05()[_0x22436b('0xc38')](_0x21fc59,['sectionId',_0x36242c['id']]);if(_0x29349d)return _0x21fc59=_0x2cfb05()[_0x22436b('0x127f')](_0x21fc59,['sectionId',_0x36242c['id']]),_0x32b341(_0x36242c,_0x29349d['id'])[_0x22436b('0x1166')](function(){const _0x13edfe=_0x22436b;return _0x4d8150=_0x13edfe('0x1c4c'),_0x1029aa(_0x1afc76['shift'](),_0x21fc59,_0x4d8150);})['catch'](function(_0x3bb286){return _0x96b795['reject'](_0x3bb286);});}function _0x491c56(_0xa17bb9){const _0x1df02d=_0x1c63d9,_0x27c9ba=_0xa17bb9['title']===_0x1df02d('0x22b4')?_0x1df02d('0x783'):_0xa17bb9[_0x1df02d('0xcdc')];if(!_0xa6a176['license']){_0xa17bb9['status']=_0x3d121b(_0xa17bb9,'unknown');return;}typeof _0xa17bb9[_0x1df02d('0x2868')]!==_0x1df02d('0x1048')&&!_0xa17bb9[_0x1df02d('0x2868')]['association']?_0x2d5b17[_0x1df02d('0x17aa')][_0x1df02d('0xd83')]({'userProfileId':_0xa6a176['userProfile']['id'],'sectionId':_0xa17bb9['id']})[_0x1df02d('0xa44')][_0x1df02d('0x1166')](function(_0x23d27f){const _0x5205ff=_0x1df02d,_0x19792c=_0x23d27f&&_0x23d27f[_0x5205ff('0x269a')][_0x5205ff('0x264b')]===0x1?_0x23d27f[_0x5205ff('0x269a')][0x0]:null,_0x2a11fe=_0x19792c?_0x5205ff('0x1c4c'):_0x5205ff('0xbd0');_0xa17bb9['status']=_0x3d121b(_0xa17bb9,_0x2a11fe);}):typeof _0xa17bb9[_0x1df02d('0x5c9')]!==_0x1df02d('0x1048')&&!_0xa6a176[_0x1df02d('0x5c9')][_0xa17bb9['license']]?_0xa17bb9[_0x1df02d('0x52d')]=_0x3d121b(_0xa17bb9,_0x1df02d('0x1d3a')):_0x2d5b17['userProfileSection'][_0x1df02d('0xd83')]({'userProfileId':_0xa6a176['userProfile']['id'],'category':_0x27c9ba})[_0x1df02d('0xa44')]['then'](function(_0x1059c5){const _0x17ae9c=_0x1df02d,_0x31d0bd=_0x1059c5&&_0x1059c5[_0x17ae9c('0x269a')]&&_0x1059c5['rows'][_0x17ae9c('0x264b')]>0x0?_0x1059c5[_0x17ae9c('0x269a')]:[];if(_0xa17bb9['title']==='Dashboards')return _0x2cfb05()['isEmpty'](_0x31d0bd)?_0x17ae9c('0xbd0'):_0x31d0bd[0x0][_0x17ae9c('0x1a2b')]?_0x17ae9c('0x1c4c'):_0x2d5b17[_0x17ae9c('0x4b5')]['get']({'sectionId':_0x31d0bd[0x0]['id'],'resourceId':0x65})[_0x17ae9c('0xa44')][_0x17ae9c('0x1166')](function(_0x347f17){const _0x422606=_0x17ae9c,_0x134159=_0x347f17&&_0x347f17['rows']?_0x347f17[_0x422606('0x269a')][0x0]:null;return _0x134159?_0x422606('0x1c4c'):_0x422606('0x9f0');});else{const _0x57604e=_0x2cfb05()['filter'](_0xa17bb9[_0x17ae9c('0x9df')],function(_0xafd5c2){const _0x217c64=_0x17ae9c;return typeof _0xafd5c2[_0x217c64('0x2868')]!==_0x217c64('0x1048')&&_0xafd5c2[_0x217c64('0x2868')]['hidden']?undefined:_0xafd5c2;});if(_0x31d0bd[_0x17ae9c('0x264b')]===_0x57604e['length']){if(_0x2cfb05()[_0x17ae9c('0x2285')](_0x31d0bd,[_0x17ae9c('0x1a2b'),!![]]))return'full';else{const _0x141c21=_0x2cfb05()['filter'](_0x57604e,function(_0x16ba56){const _0x21d391=_0x17ae9c;return typeof _0x16ba56[_0x21d391('0x2868')]!=='undefined'&&!_0x16ba56[_0x21d391('0x2868')][_0x21d391('0x103a')]?undefined:_0x16ba56;});return _0x1029aa(_0x141c21,_0x31d0bd,_0x17ae9c('0x9f0'));}}else return _0x31d0bd[_0x17ae9c('0x264b')]===0x0?'disabled':_0x17ae9c('0x9f0');}})[_0x1df02d('0x1166')](function(_0x16d07a){const _0x12e7e8=_0x1df02d;_0xa17bb9[_0x12e7e8('0x52d')]=_0x3d121b(_0xa17bb9,_0x16d07a);})[_0x1df02d('0x1a80')](function(_0x3c8f59){const _0x315d23=_0x1df02d,_0x2c7918=_0x3c8f59?_0x315d23('0x22d5'):'partial';_0xa17bb9[_0x315d23('0x52d')]=_0x3d121b(_0xa17bb9,_0x2c7918),_0x3c8f59&&_0x568dc2[_0x315d23('0xfc9')]({'title':_0x3c8f59[_0x315d23('0x52d')]?_0x315d23('0x1e21')+_0x3c8f59[_0x315d23('0x52d')]+_0x315d23('0x11e1')+_0x3c8f59['statusText']:_0x315d23('0x1168')+_0x27c9ba['toUpperCase']()+')','msg':_0x3c8f59[_0x315d23('0x52d')]?JSON[_0x315d23('0xbac')](_0x3c8f59['data']):_0x3c8f59['toString']()});});}function _0x46e505(_0x3909d8){return _0x3909d8==='full'?!![]:![];}}const _0x3a4a8c=_0x1619cd;_0x36a833[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x7f'),'userProfiles','$translate','Auth',_0x36e6f4('0xe60')];function _0x36a833(_0x59829a,_0x3d0b1c,_0x4d77f2,_0x1cde2b,_0x46cc7a,_0x2c7ef7,_0x56c9aa,_0x28f960,_0x28a3b6,_0x48dec9){const _0x300072=_0x36e6f4,_0x3815e8=this;_0x3815e8[_0x300072('0x7f')]=_0x2c7ef7,_0x3815e8[_0x300072('0x23af')]=0x0,_0x3815e8[_0x300072('0xe60')]=angular[_0x300072('0x225f')](_0x48dec9),_0x3815e8[_0x300072('0xcdc')]=_0x28f960[_0x300072('0x25cc')](_0x300072('0x16db'),{'sectionName':_0x28f960[_0x300072('0x25cc')](_0x3815e8[_0x300072('0xe60')][_0x300072('0x1139')])}),_0x3815e8[_0x300072('0xbd7')]=[],_0x3815e8['selectedItems']=[],_0x3815e8['subsections']=_0x2cfb05()[_0x300072('0x1c33')](_0x3815e8[_0x300072('0xe60')][_0x300072('0x9df')],function(_0x11e9c7){const _0x7877c7=_0x300072;return typeof _0x11e9c7['permissions']!=_0x7877c7('0x1048')&&_0x11e9c7[_0x7877c7('0x2868')][_0x7877c7('0x17d6')]?undefined:_0x11e9c7;}),_0x3815e8[_0x300072('0x28d6')]=[{'title':_0x300072('0x20c8'),'translate':'DASHBOARDS.DASHBOARDS','id':0x64}],_0x3815e8[_0x300072('0x2522')]=[];_0x3815e8[_0x300072('0xe60')][_0x300072('0xcdc')]==='Dashboards'&&(_0x3815e8['dashboardItems']=_0x3815e8[_0x300072('0xc75')],_0x3815e8[_0x300072('0xc75')]=_0x3815e8[_0x300072('0x28d6')]);_0x3815e8[_0x300072('0x218b')]=null,_0x3815e8[_0x300072('0xdb1')]=null,_0x3815e8[_0x300072('0x34c')]=[],_0x3815e8[_0x300072('0x24a0')]=_0xa64108,_0x3815e8[_0x300072('0x133c')]=_0x3e8b6c,_0x3815e8[_0x300072('0x698')]=_0x114b29,_0x3815e8['onChangeAutoAssociation']=_0x3b0a61,_0x3815e8[_0x300072('0x999')]=_0x165e7c,_0x3815e8[_0x300072('0x148e')]=_0x26099d,_0x3815e8['saveSection']=_0x5c5614,_0x3815e8['dualMultiselectOptions']={'readOnly':![],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x300072('0x4f0'),'line1':_0x300072('0x4f0'),'line2':'','line3':'','line4':'fullPath','labelAll':_0x28f960[_0x300072('0x25cc')](_0x300072('0x1fcf')),'labelSelected':_0x28f960[_0x300072('0x25cc')](_0x300072('0xb6f')),'labelSearch':_0x28f960['instant'](_0x300072('0x1bf2')),'transferCallback':function(_0x195c25,_0xf58ab2){const _0x5464b3=_0x300072;_0x48e7fa(!![]),_0xf58ab2?(_0x3815e8[_0x5464b3('0x218b')][_0x5464b3('0x18e1')]=_0x2cfb05()['pullAllBy'](_0x3815e8['selectedSection'][_0x5464b3('0x18e1')],_0x195c25,'id'),_0x3815e8['selectedSection']['autoAssociation']=![]):_0x3815e8[_0x5464b3('0x218b')][_0x5464b3('0x18e1')]=_0x2cfb05()[_0x5464b3('0x2231')](_0x3815e8[_0x5464b3('0x218b')][_0x5464b3('0x18e1')],_0x195c25,'id'),_0x3815e8[_0x5464b3('0x218b')][_0x5464b3('0xcdc')]===_0x5464b3('0x2165')&&_0x4d0427();}};function _0x544bdb(){return _0x4d77f2(function(_0x1f3ca3,_0x38e567){const _0x1e89f3=a0_0x3f2c,_0x108f1e=typeof _0x3815e8[_0x1e89f3('0x218b')][_0x1e89f3('0x1298')]!=='undefined'&&_0x3815e8[_0x1e89f3('0x218b')][_0x1e89f3('0x1298')]===_0x1e89f3('0x1957')?_0x1e89f3('0x587'):_0x1e89f3('0x14d8');return _0x46cc7a[_0x3815e8[_0x1e89f3('0x218b')]['route']][_0x1e89f3('0xd83')]({'fields':_0x1e89f3('0x1ad1'),'channel':_0x3815e8[_0x1e89f3('0x218b')][_0x1e89f3('0x1298')]===_0x1e89f3('0x1957')?'voice':_0x3815e8[_0x1e89f3('0x218b')]['channel'],'type':_0x108f1e,'nolimit':!![]})[_0x1e89f3('0xa44')][_0x1e89f3('0x1166')](function(_0x4f60e2){_0x1f3ca3(_0x4f60e2);})[_0x1e89f3('0x1a80')](function(_0x180908){_0x38e567(_0x180908);});});}function _0x205484(){return _0x4d77f2(function(_0x2d1fc2,_0x21b22c){const _0x1492b5=a0_0x3f2c;let _0x5bbfc3,_0x33b644,_0x87d736=![],_0x4f69d0=![];if(_0x3815e8['selectedSection'][_0x1492b5('0x16a8')]===_0x1492b5('0x1deb'))switch(_0x3815e8[_0x1492b5('0x218b')][_0x1492b5('0xcdc')]){case _0x1492b5('0x679'):_0x5bbfc3='inbound';break;case _0x1492b5('0x21f5'):_0x5bbfc3=_0x1492b5('0x587');break;case _0x1492b5('0x21ce'):_0x5bbfc3=_0x1492b5('0x1eef');break;}if(_0x3815e8[_0x1492b5('0x218b')][_0x1492b5('0x16a8')]==='user')switch(_0x3815e8[_0x1492b5('0x218b')][_0x1492b5('0xcdc')]){case'Agents':_0x33b644=_0x1492b5('0x1eff');break;case _0x1492b5('0x2323'):_0x33b644=_0x1492b5('0x887');break;case _0x1492b5('0x1bc7'):_0x33b644=_0x1492b5('0x557');break;}_0x3815e8['selectedSection'][_0x1492b5('0x16a8')]===_0x1492b5('0x277c')&&(_0x87d736=!![]);_0x3815e8[_0x1492b5('0x218b')]['route']===_0x1492b5('0x12e8')&&(_0x4f69d0=!![]);_0x3815e8[_0x1492b5('0x218b')]['title']===_0x1492b5('0x2165')&&(_0x3815e8[_0x1492b5('0x218b')]['route']=_0x3815e8[_0x1492b5('0x218b')][_0x1492b5('0x2518')]===_0x1492b5('0x1526')?_0x1492b5('0x17c2'):_0x1492b5('0x1ff5'));if(_0x3815e8['selectedSection']['title']==='Dashboards')_0x2d1fc2({'count':0x1,'rows':[{'id':0x65,'name':_0x28f960['instant'](_0x1492b5('0x8dd'))}]});else return _0x46cc7a[_0x3815e8[_0x1492b5('0x218b')][_0x1492b5('0x16a8')]]['get']({'role':_0x33b644?_0x33b644:undefined,'type':_0x5bbfc3?_0x5bbfc3:undefined,'VoiceExtensionId':_0x5bbfc3?_0x1492b5('0x15d7'):undefined,'IntervalId':_0x87d736?_0x1492b5('0x15d7'):undefined,'MailAccountId':_0x4f69d0?_0x1492b5('0x15d7'):undefined,'FaxAccountId':_0x4f69d0?_0x1492b5('0x15d7'):undefined,'SmsAccountId':_0x4f69d0?_0x1492b5('0x15d7'):undefined,'OpenchannelAccountId':_0x4f69d0?_0x1492b5('0x15d7'):undefined,'ChatWebsiteId':_0x4f69d0?'null':undefined,'WhatsappAccountId':_0x4f69d0?_0x1492b5('0x15d7'):undefined,'ListId':_0x4f69d0?_0x1492b5('0x15d7'):undefined,'nolimit':!![]})[_0x1492b5('0xa44')]['then'](function(_0x11c9eb){_0x2d1fc2(_0x11c9eb);})['catch'](function(_0x11b83b){_0x21b22c(_0x11b83b);});});}function _0x580103(){const _0x29ad06=_0x300072,_0x30cb72=typeof _0x3815e8[_0x29ad06('0x218b')]['pending']!='undefined'?_0x3815e8[_0x29ad06('0x218b')][_0x29ad06('0xfa1')]:![];return _0x4d77f2(function(_0x57a410,_0x8c2978){const _0x11a2ff=_0x29ad06;_0x46cc7a['userProfileSection'][_0x11a2ff('0xd83')]({'userProfileId':_0x3815e8[_0x11a2ff('0x7f')]['id'],'sectionId':_0x3815e8[_0x11a2ff('0x218b')]['id']})[_0x11a2ff('0xa44')][_0x11a2ff('0x1166')](function(_0x135129){const _0x356579=_0x11a2ff,_0x5195f7=_0x135129&&_0x135129[_0x356579('0x269a')]?_0x135129[_0x356579('0x269a')][0x0]:null;!_0x30cb72&&(_0x3815e8[_0x356579('0x218b')][_0x356579('0xc27')]=_0x5195f7?!!_0x5195f7[_0x356579('0xc27')]:![],_0x3815e8[_0x356579('0x218b')][_0x356579('0x1a2b')]=_0x5195f7?!!_0x5195f7['autoAssociation']:![],_0x3815e8[_0x356579('0x218b')][_0x356579('0x243c')]=_0x5195f7?_0x417c5d(_0x5195f7[_0x356579('0x243c')]):_0x417c5d(_0x3815e8[_0x356579('0x7f')][_0x356579('0x243c')])),_0x57a410(_0x5195f7);})[_0x11a2ff('0x1a80')](function(_0x128a6f){_0x8c2978(_0x128a6f);});});}function _0x274a81(){return _0x4d77f2(function(_0x35beec,_0x211f18){const _0x203168=a0_0x3f2c;!_0x3815e8[_0x203168('0xdb1')]?_0x35beec(null):_0x46cc7a[_0x203168('0x4b5')][_0x203168('0xd83')]({'sectionId':_0x3815e8[_0x203168('0xdb1')]['id'],'nolimit':!![]})[_0x203168('0xa44')]['then'](function(_0x228f3f){_0x35beec(_0x228f3f);})[_0x203168('0x1a80')](function(_0xd9f0dc){_0x211f18(_0xd9f0dc);});});}function _0xecea98(){return _0x4d77f2(function(_0x35b74b,_0x179192){const _0x43aa08=a0_0x3f2c,_0x520fec=typeof _0x3815e8['selectedSection'][_0x43aa08('0x1298')]!=='undefined'&&_0x2cfb05()['includes'](_0x3815e8[_0x43aa08('0x218b')][_0x43aa08('0x16a8')],_0x43aa08('0x28ba'));_0x520fec?_0x544bdb()[_0x43aa08('0x1166')](function(_0x5eecab){_0x35b74b(_0x5eecab);})[_0x43aa08('0x1a80')](function(_0x83a2c6){_0x179192(_0x83a2c6);}):_0x205484()[_0x43aa08('0x1166')](function(_0x1fb453){_0x35b74b(_0x1fb453);})['catch'](function(_0x63a1b6){_0x179192(_0x63a1b6);});});}function _0xd27b16(){const _0x4d3291=_0x300072,_0x3562d7=typeof _0x3815e8['selectedSection'][_0x4d3291('0xfa1')]!=_0x4d3291('0x1048')?_0x3815e8[_0x4d3291('0x218b')][_0x4d3291('0xfa1')]:![];let _0x460db6=[];return _0x274a81()[_0x4d3291('0x1166')](function(_0x483c19){const _0x472e18=_0x4d3291;return _0x460db6=_0x483c19&&_0x483c19['rows']?_0x483c19[_0x472e18('0x269a')]:[],_0x3815e8[_0x472e18('0x218b')][_0x472e18('0xcdc')]==='Reports'&&(_0x3815e8['associatedReports']=!_0x3815e8[_0x472e18('0x22c7')]?_0x460db6:_0x3815e8[_0x472e18('0x22c7')],_0x460db6=_0x42fbcd(_0x3815e8[_0x472e18('0x22c7')])),typeof _0x3815e8[_0x472e18('0x218b')][_0x472e18('0x2868')]!==_0x472e18('0x1048')&&!_0x3815e8[_0x472e18('0x218b')][_0x472e18('0x2868')][_0x472e18('0x103a')]?{'rows':[]}:_0xecea98();})[_0x4d3291('0x1166')](function(_0x56771f){const _0x53361c=_0x4d3291;_0x3815e8[_0x53361c('0xbd7')]=_0x56771f[_0x53361c('0x269a')]?_0x2cfb05()['map'](_0x56771f[_0x53361c('0x269a')],function(_0x500920){const _0x537356=_0x53361c;return _0x3815e8[_0x537356('0x218b')][_0x537356('0xcdc')]===_0x537356('0x2165')&&(_0x500920['fullPath']=_0x8647fc(_0x500920[_0x537356('0x5f6')])['replace']('\x20','_')),_0x500920['isValid']=!![],_0x500920;}):[];!_0x3562d7&&(_0x3815e8[_0x53361c('0x218b')][_0x53361c('0x18e1')]=_0x2cfb05()[_0x53361c('0x2563')](_0x460db6,function(_0xafa170){const _0x33f87a=_0x53361c;return _0x2cfb05()['find'](_0x3815e8[_0x33f87a('0xbd7')],{'id':_0xafa170['resourceId']});}));const _0x1820bc=_0x2cfb05()[_0x53361c('0x24ac')](_0x3815e8[_0x53361c('0x218b')][_0x53361c('0x18e1')],_0x3815e8[_0x53361c('0xbd7')],'id');!_0x2cfb05()[_0x53361c('0x1081')](_0x1820bc)&&(_0x3815e8[_0x53361c('0x218b')][_0x53361c('0x18e1')]=_0x2cfb05()[_0x53361c('0x271')](_0x3815e8['selectedSection']['selectedItems'],_0x1820bc,'id'));let _0x46d474;switch(_0x3815e8['selectedSection'][_0x53361c('0xcdc')]){case _0x53361c('0x136e'):_0x3815e8[_0x53361c('0x218b')][_0x53361c('0x18e1')]=_0x2cfb05()[_0x53361c('0x1c33')](_0x3815e8[_0x53361c('0xbd7')],function(_0x53af7b){const _0x205304=_0x53361c;if(_0x53af7b[_0x205304('0x1b0b')])return _0x53af7b[_0x205304('0x26ef')]=![],_0x53af7b;else{const _0x1d9ef2=_0x2cfb05()[_0x205304('0xc38')](_0x460db6,{'resourceId':_0x53af7b['id']});if(typeof _0x1d9ef2!==_0x205304('0x1048'))return _0x53af7b[_0x205304('0x26ef')]=!![],_0x53af7b;}});break;case'MusicOnHolds':_0x3815e8[_0x53361c('0x218b')][_0x53361c('0x18e1')]=_0x2cfb05()[_0x53361c('0x1c33')](_0x3815e8[_0x53361c('0xbd7')],function(_0xce7d68){const _0x3e1131=_0x53361c;if(_0xce7d68['defaultEntry'])return _0xce7d68[_0x3e1131('0x26ef')]=![],_0xce7d68;else{const _0x3d901b=_0x2cfb05()['find'](_0x460db6,{'resourceId':_0xce7d68['id']});if(typeof _0x3d901b!=='undefined')return _0xce7d68[_0x3e1131('0x26ef')]=!![],_0xce7d68;}});break;case'Reports':_0x46d474=_0x271490(_0x3815e8[_0x53361c('0x34c')]),_0x3815e8['selectedSection'][_0x53361c('0x18e1')]=_0x5b3112(_0x3815e8[_0x53361c('0x218b')][_0x53361c('0x18e1')]),_0x3815e8[_0x53361c('0x218b')][_0x53361c('0x18e1')]=_0x2cfb05()[_0x53361c('0x2231')](_0x3815e8[_0x53361c('0x218b')][_0x53361c('0x18e1')],_0x46d474,'id');break;}_0x3815e8[_0x53361c('0xc68')][_0x53361c('0x18e1')]=_0x3815e8[_0x53361c('0x218b')]['selectedItems'],_0x3815e8[_0x53361c('0xc68')]['items']=_0x2cfb05()['differenceBy'](_0x3815e8[_0x53361c('0xbd7')],_0x3815e8[_0x53361c('0xc68')][_0x53361c('0x18e1')],'id');})[_0x4d3291('0x1a80')](function(_0x32b437){const _0x57b2d6=_0x4d3291;_0x1cde2b[_0x57b2d6('0xfc9')]({'title':_0x32b437[_0x57b2d6('0x52d')]?_0x57b2d6('0x1e21')+_0x32b437[_0x57b2d6('0x52d')]+_0x57b2d6('0x11e1')+_0x32b437[_0x57b2d6('0xe1b')]:'SYSTEM:GET'+_0x3815e8[_0x57b2d6('0x218b')][_0x57b2d6('0xcdc')][_0x57b2d6('0x1387')](),'msg':_0x32b437[_0x57b2d6('0x52d')]?JSON[_0x57b2d6('0xbac')](_0x32b437[_0x57b2d6('0x25f4')]):_0x32b437['toString']()});});}function _0x3e8b6c(){return _0x580103()['then'](function(_0x2c96e0){const _0x2593ad=a0_0x3f2c;_0x3815e8['loadedSection']=_0x2c96e0;if(_0x3815e8[_0x2593ad('0x218b')][_0x2593ad('0xcdc')]===_0x2593ad('0x2165'))return _0x3db198()['then'](function(){const _0x4b1afb=_0x2593ad;if(!_0x3815e8[_0x4b1afb('0x218b')][_0x4b1afb('0x2518')])return _0x274a81()[_0x4b1afb('0x1166')](function(_0x462070){const _0x10eca2=_0x4b1afb;_0x3815e8[_0x10eca2('0x34c')]=_0x462070?_0x2cfb05()['map'](_0x462070['rows'],function(_0x5cac9f){const _0x212532=_0x10eca2;return{'id':_0x5cac9f[_0x212532('0x24e8')],'name':_0x5cac9f[_0x212532('0x4f0')],'type':_0x5cac9f['type']};}):[];});})[_0x2593ad('0x1a80')](function(_0x10154e){const _0x1ac6a9=_0x2593ad;_0x1cde2b[_0x1ac6a9('0xfc9')]({'title':_0x10154e[_0x1ac6a9('0x52d')]?'API:'+_0x10154e['status']+_0x1ac6a9('0x11e1')+_0x10154e[_0x1ac6a9('0xe1b')]:_0x1ac6a9('0x1d00'),'msg':_0x10154e[_0x1ac6a9('0x25f4')]?JSON[_0x1ac6a9('0xbac')](_0x10154e[_0x1ac6a9('0x25f4')]):_0x10154e[_0x1ac6a9('0x1586')]()});});else _0xd27b16();})['catch'](function(_0x352a72){const _0x3eb9f7=a0_0x3f2c;_0x1cde2b[_0x3eb9f7('0xfc9')]({'title':_0x352a72[_0x3eb9f7('0x52d')]?_0x3eb9f7('0x1e21')+_0x352a72[_0x3eb9f7('0x52d')]+'\x20-\x20'+_0x352a72[_0x3eb9f7('0xe1b')]:'SYSTEM:GET'+_0x3815e8[_0x3eb9f7('0x218b')][_0x3eb9f7('0xcdc')]['toUpperCase'](),'msg':_0x352a72[_0x3eb9f7('0x52d')]?JSON[_0x3eb9f7('0xbac')](_0x352a72[_0x3eb9f7('0x25f4')]):_0x352a72['toString']()});});}function _0x417c5d(_0x3755e5){const _0x161500=_0x300072;return _0x3755e5&&(_0x3815e8[_0x161500('0x218b')][_0x161500('0x1f6c')]=_0x2cfb05()[_0x161500('0x1257')](_0x3755e5,'e')?!![]:![],_0x3815e8[_0x161500('0x218b')][_0x161500('0x1c93')]=_0x2cfb05()['includes'](_0x3755e5,'d')?!![]:![]),_0x57b923();}function _0x57b923(){const _0x7fd7b0=_0x300072,_0x3a7a50=['r'];if(_0x3815e8[_0x7fd7b0('0x218b')]['allowEdit'])_0x3a7a50[_0x7fd7b0('0x1514')]('e');else{const _0x2117e8=_0x2cfb05()['indexOf'](_0x3a7a50,['e']);_0x2117e8>0x0&&_0x3815e8[_0x7fd7b0('0x218b')]['crudPermissions'][_0x7fd7b0('0xf3')]('e','');}if(_0x3815e8['selectedSection'][_0x7fd7b0('0x1c93')])_0x3a7a50['push']('d');else{const _0x23d34c=_0x2cfb05()[_0x7fd7b0('0x2379')](_0x3a7a50,['d']);_0x23d34c>0x0&&_0x3815e8[_0x7fd7b0('0x218b')][_0x7fd7b0('0x243c')][_0x7fd7b0('0xf3')]('d','');}return _0x3a7a50;}function _0x114b29(){const _0x27e2fa=_0x300072;_0x3815e8[_0x27e2fa('0x218b')]['enabled']=!_0x3815e8[_0x27e2fa('0x218b')]['enabled'],_0x48e7fa(!![]);}function _0x3b0a61(){const _0x58c44e=_0x300072;if(!_0x3815e8[_0x58c44e('0x218b')][_0x58c44e('0x1a2b')]){const _0x586cbe=[];for(let _0x2a1fee=0x0;_0x2a1fee<_0x3815e8[_0x58c44e('0xc68')][_0x58c44e('0xbd7')][_0x58c44e('0x264b')];_0x2a1fee++){_0x586cbe[_0x58c44e('0x1514')](_0x3815e8[_0x58c44e('0xc68')][_0x58c44e('0xbd7')][_0x2a1fee]),_0x3815e8['dualMultiselectOptions']['selectedItems'][_0x58c44e('0x1514')](_0x3815e8[_0x58c44e('0xc68')][_0x58c44e('0xbd7')][_0x2a1fee]);}_0x3815e8['dualMultiselectOptions']['items']=[],_0x3815e8[_0x58c44e('0xc68')][_0x58c44e('0x28bf')](_0x586cbe,![]);}_0x48e7fa(!![]);}function _0x165e7c(){const _0x385ed3=_0x300072;_0x3815e8[_0x385ed3('0x635')]=_0x341048(),_0x3815e8['selectedSection'][_0x385ed3('0x18e1')]&&(_0x3815e8[_0x385ed3('0x34c')]=_0x5b3112(_0x3815e8['allReportsSelected']),_0x4d0427()),_0xd27b16();}function _0x26099d(_0x1fba1e){const _0x494d1e=_0x300072;if(_0x1fba1e===_0x494d1e('0x171f'))_0x3815e8[_0x494d1e('0x218b')][_0x494d1e('0x1f6c')]=!_0x3815e8[_0x494d1e('0x218b')][_0x494d1e('0x1f6c')];else _0x1fba1e==='delete'&&(_0x3815e8[_0x494d1e('0x218b')]['allowDelete']=!_0x3815e8[_0x494d1e('0x218b')][_0x494d1e('0x1c93')]);_0x3815e8[_0x494d1e('0x218b')]['crudPermissions']=_0x417c5d(),_0x48e7fa(!![]);}function _0x5c5614(){const _0xdba39a=_0x300072,_0x4b99cb=_0x3815e8[_0xdba39a('0xe60')]['title']==='Marketplace'?_0xdba39a('0x783'):_0x3815e8[_0xdba39a('0xe60')][_0xdba39a('0xcdc')],_0x2decc2=_0x2cfb05()(_0x3815e8[_0xdba39a('0xc75')])[_0xdba39a('0x1c33')]({'pending':!![]})[_0xdba39a('0x2563')](function(_0x3e6e86){const _0x164f1f=_0xdba39a,_0x235eaf=_0x4b99cb===_0x164f1f('0x678')&&_0x3e6e86[_0x164f1f('0xcdc')]==='Projects'?'SquareProjects':_0x3e6e86[_0x164f1f('0xcdc')],_0x5b701b=_0x235eaf===_0x164f1f('0x2165')?_0x3815e8['allReportsSelected']:_0x3e6e86[_0x164f1f('0x18e1')];return _0x4b99cb===_0x164f1f('0x897')&&(_0x3e6e86[_0x164f1f('0x1a2b')]=!![]),{'category':_0x4b99cb,'sectionId':_0x3e6e86['id'],'name':_0x235eaf,'enabled':_0x3e6e86[_0x164f1f('0xc27')],'autoAssociation':_0x3e6e86[_0x164f1f('0x1a2b')],'crudPermissions':_0x2cfb05()[_0x164f1f('0x2563')](_0x3e6e86[_0x164f1f('0x243c')])[_0x164f1f('0x45a')](''),'Resources':_0x2cfb05()['map'](_0x5b701b,function(_0x27b4f3){const _0xf4f305=_0x164f1f;return{'name':_0x27b4f3[_0xf4f305('0x4f0')],'resourceId':_0x27b4f3['id'],'type':_0xfac8f8(_0x235eaf,_0x27b4f3)};})};})['value']();return _0x46cc7a[_0xdba39a('0x7f')][_0xdba39a('0xc66')]({'id':_0x3815e8[_0xdba39a('0x7f')]['id']},_0x2decc2)[_0xdba39a('0xa44')][_0xdba39a('0x1166')](function(){const _0x2f040d=_0xdba39a;_0x3815e8[_0x2f040d('0xc75')][_0x2f040d('0x2782')](function(_0x216ee8){const _0x55052f=_0x2f040d;_0x216ee8[_0x55052f('0xfa1')]=undefined;}),_0x3815e8[_0x2f040d('0x22c7')]=null,_0x398bf0(),_0x3815e8[_0x2f040d('0x218b')]['title']===_0x2f040d('0x2165')&&!_0x3815e8[_0x2f040d('0x218b')][_0x2f040d('0x2518')]&&_0x59829a['userProfileForm'][_0x2f040d('0x25b6')](),_0x1cde2b['success']({'title':_0x28f960[_0x2f040d('0x25cc')](_0x2f040d('0x179e'),{'sectionName':_0x28f960[_0x2f040d('0x25cc')](_0x4b99cb[_0x2f040d('0x1139')])}),'msg':_0x28f960[_0x2f040d('0x25cc')](_0x2f040d('0x7fe'))});})[_0xdba39a('0x1166')](function(){const _0x3cd920=_0xdba39a;return _0x580103()[_0x3cd920('0x1166')](function(_0x14b200){_0x3815e8['loadedSection']=_0x14b200;});})[_0xdba39a('0x1a80')](function(_0x47524b){const _0x495575=_0xdba39a;_0x1cde2b[_0x495575('0xfc9')]({'title':_0x47524b[_0x495575('0x52d')]?_0x495575('0x1e21')+_0x47524b[_0x495575('0x52d')]+_0x495575('0x11e1')+_0x47524b[_0x495575('0xe1b')]:'SYSTEM:USERPROFILE.ADDSECTIONS','msg':_0x47524b[_0x495575('0x52d')]?JSON['stringify'](_0x47524b[_0x495575('0x25f4')]):_0x47524b[_0x495575('0x1586')]()});});}function _0x48e7fa(_0x222238){const _0x541912=_0x300072,_0x1c7e7a=_0x2cfb05()[_0x541912('0xede')](_0x3815e8[_0x541912('0xc75')],function(_0x147805){const _0x2a4fba=_0x541912;return _0x147805['id']==_0x3815e8[_0x2a4fba('0x218b')]['id'];});_0x3815e8['subsections'][_0x1c7e7a]['pending']=_0x222238,_0x398bf0();}function _0x398bf0(){const _0x31b51a=_0x300072;return _0x3815e8[_0x31b51a('0x14d7')]=_0x2cfb05()['some'](_0x3815e8[_0x31b51a('0xc75')],['pending',!![]]);}function _0x341048(){const _0x56e462=_0x300072;let _0x43b590={};return _0x3815e8[_0x56e462('0x218b')]['reportType']==='default'?_0x43b590=_0x3815e8['treeReports'][0x0]?angular[_0x56e462('0x2524')](_0x3815e8[_0x56e462('0x14c7')][0x0]['tree']):[]:_0x43b590=_0x3815e8[_0x56e462('0x14c7')][0x1]?angular[_0x56e462('0x2524')](_0x3815e8[_0x56e462('0x14c7')][0x1]['tree']):[],_0x43b590;}function _0x3db198(){return _0x4d77f2(function(_0x10e3dd,_0x2be144){const _0x4acbdc=a0_0x3f2c;_0x46cc7a['analyticTreeReport'][_0x4acbdc('0xd83')]({})['$promise'][_0x4acbdc('0x1166')](function(_0x36409c){const _0xac99bc=_0x4acbdc;_0x3815e8['treeReports']=_0x36409c[_0xac99bc('0x269a')]||[],_0x10e3dd(_0x3815e8[_0xac99bc('0x14c7')]);})['catch'](function(_0x53b7c1){_0x2be144(_0x53b7c1);});});}function _0x8647fc(_0x3d5fa4){const _0x9ea8e1=_0x300072;let _0x512d1a=_0x3815e8[_0x9ea8e1('0x635')][0x0][_0x9ea8e1('0x1640')];return _0x512d1a=_0x1eb2c9(_0x512d1a,_0x3d5fa4,_0x3815e8['treeStructure'][0x0]),_0x512d1a;}function _0x1eb2c9(_0x2bc59d,_0xc653da,_0x4a7266){const _0x1e5533=_0x300072;if(_0x4a7266&&!_0x2cfb05()[_0x1e5533('0x1081')](_0x4a7266[_0x1e5533('0x9df')]))_0x4a7266=_0x2cfb05()[_0x1e5533('0xc38')](_0x4a7266[_0x1e5533('0x9df')],function(_0x37f291){return _0x2cfb05()['includes'](_0xc653da,_0x37f291['id'])?_0x37f291:undefined;}),_0x2bc59d+=_0x4a7266?'/'+_0x4a7266[_0x1e5533('0x1640')]:'';else return _0x2bc59d;return _0x1eb2c9(_0x2bc59d,_0xc653da,_0x4a7266);}function _0x42fbcd(_0x28f996){const _0x34f979=_0x300072;return _0x2cfb05()[_0x34f979('0x1c33')](_0x28f996,{'type':_0x3815e8[_0x34f979('0x218b')]['reportType']==='default'?_0x34f979('0x2243'):_0x34f979('0x1cc5')});}function _0x271490(_0x424956){const _0x4b653e=_0x300072;return _0x2cfb05()[_0x4b653e('0x1c33')](_0x424956,function(_0x29cdf7){const _0x12e213=_0x4b653e;return _0x2cfb05()['startsWith'](_0x29cdf7[_0x12e213('0x5f6')],_0x3815e8[_0x12e213('0x218b')][_0x12e213('0x2518')]===_0x12e213('0x1526')?_0x12e213('0x26f3'):'custom');});}function _0x5b3112(_0x2d80ee){const _0x80f1ad=_0x300072;return _0x2cfb05()[_0x80f1ad('0x127f')](_0x2d80ee,function(_0x301226){const _0x4d3ab8=_0x80f1ad;return _0x2cfb05()[_0x4d3ab8('0x1783')](_0x301226[_0x4d3ab8('0x5f6')],_0x3815e8[_0x4d3ab8('0x218b')][_0x4d3ab8('0x2518')]==='default'?_0x4d3ab8('0x26f3'):'custom');});}function _0x4d0427(){const _0x330fbe=_0x300072;_0x2cfb05()[_0x330fbe('0x1081')](_0x3815e8['selectedSection']['selectedItems'])?_0x3815e8['allReportsSelected']=_0x2cfb05()[_0x330fbe('0x127f')](_0x3815e8[_0x330fbe('0x34c')],function(_0x59e3dc){const _0x3a12f9=_0x330fbe;return _0x59e3dc[_0x3a12f9('0x1345')]===(_0x3815e8[_0x3a12f9('0x218b')][_0x3a12f9('0x2518')]===_0x3a12f9('0x1526')?_0x3a12f9('0x1cc5'):_0x3a12f9('0x2243'));}):_0x3815e8['selectedSection'][_0x330fbe('0x18e1')][_0x330fbe('0x2782')](function(_0x5747c6){const _0x465577=_0x330fbe,_0x3c80c=_0x2cfb05()[_0x465577('0x1798')](_0x3815e8[_0x465577('0x34c')],{'id':_0x5747c6['id'],'parent':_0x5747c6[_0x465577('0x5f6')]});!_0x3c80c&&_0x3815e8['allReportsSelected']['push'](_0x5747c6);});}function _0xfac8f8(_0x13af4a,_0x5d163c){const _0x20ebc7=_0x300072;if(_0x13af4a===_0x20ebc7('0x2165')){if(_0x5d163c[_0x20ebc7('0x5f6')]){const _0x1dcff4=_0x2cfb05()['startsWith'](_0x5d163c[_0x20ebc7('0x5f6')],_0x20ebc7('0x26f3'))?_0x20ebc7('0x1cb5'):_0x20ebc7('0x117f');return _0x1dcff4+_0x13af4a;}else return _0x5d163c[_0x20ebc7('0x1345')];}return _0x13af4a;}function _0xa64108(_0x2b4023){const _0x179370=_0x300072;if(_0x3815e8[_0x179370('0x14d7')]){const _0xebca98=_0x3d0b1c[_0x179370('0x1d26')]({'skipHide':!![]})[_0x179370('0xcdc')](_0x179370('0x9f8'))[_0x179370('0x2077')](_0x28f960['instant'](_0x179370('0x2408')))[_0x179370('0x8e8')]('Warning')[_0x179370('0x203b')](_0x2b4023)['ok'](_0x28f960[_0x179370('0x25cc')](_0x179370('0x14a1')))[_0x179370('0x3f')](_0x28f960['instant']('STAFF.CANCEL'));_0x3d0b1c['show'](_0xebca98)['then'](function(){const _0x24dfc9=_0x179370;_0x3d0b1c[_0x24dfc9('0x1197')]();});}else _0x3d0b1c['hide']();}}const _0x504cae=_0x36a833,_0x25f4de=_0x2734b2['p']+_0x36e6f4('0x27cf');_0x5c5608[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$translate',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),'toasty','Auth',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa')];function _0x5c5608(_0x8f03f5,_0x54903f,_0x5833c8,_0x31c92f,_0x2d1266,_0x29ac28,_0x170564,_0x471293,_0x10d8df,_0x597217,_0xe713f1,_0xd2627a){const _0x3b26f5=_0x36e6f4,_0x342618=this;_0x342618[_0x3b26f5('0x98')]=_0x597217['getCurrentUser'](),_0x342618[_0x3b26f5('0x5c9')]=_0x29ac28,_0x342618[_0x3b26f5('0xf8a')]=_0x170564,_0x342618['passwordPattern']=_0x342618[_0x3b26f5('0xf8a')][_0x3b26f5('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x342618[_0x3b26f5('0x246b')]=_0x54903f[_0x3b26f5('0x6f1')]()+_0x3b26f5('0xc51')+_0x54903f[_0x3b26f5('0x1690')](),_0x342618[_0x3b26f5('0x7f')]=_0xe713f1||_0x8f03f5[_0x3b26f5('0x23f')][_0x3b26f5('0x7f')]||{},_0x342618['userProfileSection']=_0xd2627a&&_0xd2627a[_0x3b26f5('0x240f')]==0x1?_0xd2627a['rows'][0x0]:null,_0x342618[_0x3b26f5('0x243c')]=_0x597217['parseCrudPermissions'](_0x342618[_0x3b26f5('0x17aa')]?_0x342618[_0x3b26f5('0x17aa')][_0x3b26f5('0x243c')]:null),_0x342618[_0x3b26f5('0x128b')]={},_0x342618['selectedTab']=_0x8f03f5[_0x3b26f5('0x23f')]['tab']||0x0,_0x342618['permissionsmanagedialog']=_0x2ac7bc,_0x342618['clonedialog']=_0x5b4295,_0x342618[_0x3b26f5('0x31d')]=_0x10d8df[_0x3b26f5('0x1fa1')],_0x342618[_0x3b26f5('0x6ba')]=_0x484326,_0x342618[_0x3b26f5('0x529')]=_0x2cc006;function _0x2ac7bc(_0x105c5c,_0x2b1a1e){const _0xb7476e=_0x3b26f5;_0x5833c8[_0xb7476e('0x1f80')]({'controller':_0xb7476e('0xd1'),'controllerAs':'vm','templateUrl':_0x73208f,'parent':angular[_0xb7476e('0x1194')](_0x31c92f['body']),'targetEvent':_0x2b1a1e,'clickOutsideToClose':!![],'locals':{'userProfile':_0x105c5c,'userProfiles':_0x342618[_0xb7476e('0x11e3')]?_0x342618[_0xb7476e('0x11e3')][_0xb7476e('0x269a')]:[],'crudPermissions':_0x342618[_0xb7476e('0x243c')]}});}function _0x5b4295(_0x783e,_0x893349){const _0x3001b7=_0x3b26f5;_0x5833c8[_0x3001b7('0x1f80')]({'controller':_0x3001b7('0x26b8'),'controllerAs':'vm','templateUrl':_0x25f4de,'parent':angular[_0x3001b7('0x1194')](_0x31c92f['body']),'targetEvent':_0x893349,'clickOutsideToClose':!![],'locals':{'userProfile':_0x783e,'userProfiles':_0x342618['userProfiles']?_0x342618[_0x3001b7('0x11e3')][_0x3001b7('0x269a')]:[],'crudPermissions':_0x342618[_0x3001b7('0x243c')]}});}function _0x484326(){const _0x4a0b99=_0x3b26f5;_0x8f03f5['go'](_0x4a0b99('0xf4a'),{},{'reload':_0x4a0b99('0xf4a')});}function _0x2cc006(){const _0x496d91=_0x3b26f5;_0x471293[_0x496d91('0x7f')][_0x496d91('0x1449')]({'id':_0x342618['userProfile']['id']},_0x342618[_0x496d91('0x7f')])['$promise'][_0x496d91('0x1166')](function(){const _0x4462b6=_0x496d91;_0x10d8df[_0x4462b6('0x103b')]({'title':_0x4462b6('0x131e'),'msg':_0x342618[_0x4462b6('0x7f')]['name']?_0x342618[_0x4462b6('0x7f')][_0x4462b6('0x4f0')]+_0x4462b6('0xa17'):''});})[_0x496d91('0x1a80')](function(_0xf804c3){const _0x4613da=_0x496d91;_0x10d8df[_0x4613da('0xfc9')]({'title':_0xf804c3['status']?_0x4613da('0x1e21')+_0xf804c3[_0x4613da('0x52d')]+_0x4613da('0x11e1')+_0xf804c3[_0x4613da('0xe1b')]:_0x4613da('0x1cb0'),'msg':_0xf804c3[_0x4613da('0x25f4')]?JSON[_0x4613da('0xbac')](_0xf804c3[_0x4613da('0x25f4')]):_0xf804c3[_0x4613da('0x1586')]()});});}}const _0x230307=_0x5c5608,_0x5db1cb=_0x2734b2['p']+_0x36e6f4('0x1316');_0xdb37c6[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x11e3'),_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0xdb37c6(_0x1a559b,_0x121a4a,_0x26ff0d,_0x2a9abc,_0x5e36ea,_0x5ec7f6,_0x529ef7,_0x1ba41e,_0x737a8a,_0x339b5d,_0x3f8e21,_0x52b2df,_0x5b08a4,_0x44704d,_0x46ec50,_0x50362d,_0x440409){const _0x216bc8=_0x36e6f4,_0x34a94f=this;_0x34a94f[_0x216bc8('0x5c9')]=_0x50362d,_0x34a94f[_0x216bc8('0xf8a')]=_0x440409,_0x34a94f[_0x216bc8('0x98')]=_0x46ec50[_0x216bc8('0x26cd')](),_0x34a94f[_0x216bc8('0x11e3')]=_0x737a8a||{'count':0x0,'rows':[]},_0x34a94f[_0x216bc8('0x7f')]=_0x339b5d,_0x34a94f[_0x216bc8('0x17aa')]=_0x3f8e21&&_0x3f8e21[_0x216bc8('0x240f')]==0x1?_0x3f8e21[_0x216bc8('0x269a')][0x0]:null,_0x34a94f['crudPermissions']=_0x46ec50[_0x216bc8('0xd87')](_0x34a94f[_0x216bc8('0x17aa')]?_0x34a94f['userProfileSection'][_0x216bc8('0x243c')]:null),_0x34a94f[_0x216bc8('0x916')]=_0x216bc8('0x11e3'),_0x34a94f['listOrder']='',_0x34a94f['listOrderAsc']=null,_0x34a94f[_0x216bc8('0xe14')]=[],_0x34a94f[_0x216bc8('0x2218')]={'fields':_0x216bc8('0x7df'),'sort':_0x216bc8('0x14dc'),'limit':0xa,'page':0x1},_0x34a94f[_0x216bc8('0x146e')]=_0x2cfb05()[_0x216bc8('0x155c')]([{'option':_0x216bc8('0x1cb4'),'value':_0x216bc8('0xe06'),'disabled':!![]},{'option':'Edit_permission','value':_0x216bc8('0xfbf')},{'option':_0x216bc8('0x23d5'),'value':_0x216bc8('0x1e57')}],function(_0x469947){return _0x2cfb05()['replace'](_0x469947['value'],new RegExp('\x27','g'),'');});_0x34a94f['userProfiles']&&_0x34a94f[_0x216bc8('0x11e3')][_0x216bc8('0x240f')]>0x0&&_0x34a94f[_0x216bc8('0x11e3')][_0x216bc8('0x269a')][_0x216bc8('0x2782')](function(_0x22fbc8){const _0x4be26e=_0x216bc8,_0x2c5508=[];_0x22fbc8[_0x4be26e('0x243c')][_0x4be26e('0x2782')](function(_0x3eb51b){const _0x5417c5=_0x4be26e;_0x2c5508[_0x5417c5('0x1514')](_0x34a94f[_0x5417c5('0x146e')][_0x3eb51b][_0x5417c5('0x66e')]);});const _0x4b0371=[];_0x2c5508[_0x4be26e('0x2782')](function(_0x3c153b){const _0x2528ce=_0x4be26e;_0x4b0371['push'](_0x1ba41e[_0x2528ce('0x25cc')]('STAFF.'+_0x3c153b[_0x2528ce('0x1387')]()));}),_0x22fbc8[_0x4be26e('0x1011')]=_0x4b0371[_0x4be26e('0x45a')](',\x20');});_0x34a94f[_0x216bc8('0x1ff6')]=_0x16534a,_0x34a94f['clonedialog']=_0x4078c9,_0x34a94f[_0x216bc8('0x8d8')]=_0x1a2265,_0x34a94f[_0x216bc8('0x103b')]=_0x1f4c67,_0x34a94f[_0x216bc8('0x1a54')]=_0x4f4751,_0x34a94f[_0x216bc8('0x112e')]=_0x15bfe9,_0x34a94f[_0x216bc8('0x8c1')]=_0x57549f,_0x34a94f[_0x216bc8('0x2429')]=_0x2aa988,_0x34a94f[_0x216bc8('0xcd4')]=_0x4e1d93,_0x34a94f['deselectUserProfiles']=_0x28e485,_0x34a94f['selectAllUserProfiles']=_0x12dfb7;function _0x16534a(_0xbe8a1c){const _0x3ad3c1=_0x216bc8;_0x26ff0d['go'](_0x3ad3c1('0x24d7'),{'id':_0xbe8a1c['id'],'userProfile':_0xbe8a1c,'crudPermissions':_0x34a94f['crudPermissions']});}function _0x4078c9(_0x133797,_0x2c976b){const _0x2d28b2=_0x216bc8;_0x5e36ea[_0x2d28b2('0x1f80')]({'controller':'UserProfilecloneController','controllerAs':'vm','templateUrl':_0x25f4de,'parent':angular[_0x2d28b2('0x1194')](_0x5ec7f6[_0x2d28b2('0x8d2')]),'targetEvent':_0x2c976b,'clickOutsideToClose':!![],'locals':{'userProfile':_0x133797,'userProfiles':_0x34a94f[_0x2d28b2('0x11e3')]?_0x34a94f['userProfiles'][_0x2d28b2('0x269a')]:[],'crudPermissions':_0x34a94f['crudPermissions']}});}function _0x1a2265(_0x334fae,_0x313c71){const _0x4c3200=_0x216bc8,_0x21d2d1=_0x5e36ea[_0x4c3200('0x1d26')]()[_0x4c3200('0xcdc')](_0x4c3200('0x288d')+_0x2cfb05()[_0x4c3200('0xb35')]('userProfile')+'?')[_0x4c3200('0xf3c')](_0x4c3200('0x12b5')+(_0x334fae['name']||_0x4c3200('0x7f'))+_0x4c3200('0xace')+_0x4c3200('0x3f3'))[_0x4c3200('0x8e8')](_0x4c3200('0x147b'))[_0x4c3200('0x203b')](_0x313c71)['ok']('OK')[_0x4c3200('0x3f')]('CANCEL');_0x5e36ea[_0x4c3200('0x1f80')](_0x21d2d1)[_0x4c3200('0x1166')](function(){_0x57549f(_0x334fae);},function(){const _0x44aeed=_0x4c3200;console[_0x44aeed('0x455')](_0x44aeed('0x2d3'));});}let _0x5b7a21=!![],_0x5aa988=0x1;_0x1a559b[_0x216bc8('0xe83')](_0x216bc8('0x12d8'),function(_0x6ba211,_0xd1f33c){const _0x1dfe33=_0x216bc8;_0x5b7a21?_0x529ef7(function(){_0x5b7a21=![];}):(!_0xd1f33c&&(_0x5aa988=_0x34a94f[_0x1dfe33('0x2218')][_0x1dfe33('0x1a43')]),_0x6ba211!==_0xd1f33c&&(_0x34a94f[_0x1dfe33('0x2218')][_0x1dfe33('0x1a43')]=0x1),!_0x6ba211&&(_0x34a94f[_0x1dfe33('0x2218')]['page']=_0x5aa988),_0x34a94f['getUserProfiles']());});function _0x1f4c67(_0x1baf69){const _0x5d7e49=_0x216bc8;_0x34a94f[_0x5d7e49('0x11e3')]=_0x1baf69||{'count':0x0,'rows':[]};}function _0x4f4751(){const _0x81ab73=_0x216bc8;_0x34a94f[_0x81ab73('0x2218')]['offset']=(_0x34a94f[_0x81ab73('0x2218')][_0x81ab73('0x1a43')]-0x1)*_0x34a94f[_0x81ab73('0x2218')][_0x81ab73('0x163f')],_0x46ec50[_0x81ab73('0x1ac6')](_0x81ab73('0xa7c'))?_0x34a94f[_0x81ab73('0x1f48')]=_0x52b2df[_0x81ab73('0x7f')][_0x81ab73('0xd83')](_0x34a94f['query'],_0x1f4c67)[_0x81ab73('0xa44')]:(_0x34a94f[_0x81ab73('0x2218')]['id']=_0x34a94f[_0x81ab73('0x7f')]['id'],_0x34a94f[_0x81ab73('0x2218')][_0x81ab73('0xe60')]=_0x81ab73('0x137a'),_0x34a94f[_0x81ab73('0x1f48')]=_0x52b2df[_0x81ab73('0x7f')][_0x81ab73('0x263a')](_0x34a94f[_0x81ab73('0x2218')],_0x1f4c67)[_0x81ab73('0xa44')]);}function _0x15bfe9(_0x5abed6,_0xdf1c43){const _0x144ebf=_0x216bc8;_0x5e36ea[_0x144ebf('0x1f80')]({'controller':'CreateOrEditUserProfileDialogController','controllerAs':'vm','templateUrl':_0x5db1cb,'parent':angular[_0x144ebf('0x1194')](_0x5ec7f6['body']),'targetEvent':_0x5abed6,'clickOutsideToClose':!![],'locals':{'userProfile':_0xdf1c43,'userProfiles':_0x34a94f[_0x144ebf('0x11e3')]['rows'],'license':_0x34a94f[_0x144ebf('0x5c9')],'setting':_0x34a94f['setting'],'crudPermissions':_0x34a94f['crudPermissions']}});}function _0x57549f(_0x1f0ea3){const _0x252f0f=_0x216bc8;_0x52b2df['userProfile']['delete']({'id':_0x1f0ea3['id']})['$promise'][_0x252f0f('0x1166')](function(){const _0x53b49a=_0x252f0f;_0x2cfb05()[_0x53b49a('0x127f')](_0x34a94f[_0x53b49a('0x11e3')][_0x53b49a('0x269a')],{'id':_0x1f0ea3['id']}),_0x34a94f[_0x53b49a('0x11e3')]['count']-=0x1,!_0x34a94f['userProfiles'][_0x53b49a('0x269a')][_0x53b49a('0x264b')]&&_0x34a94f[_0x53b49a('0x1a54')](),_0x44704d['success']({'title':_0x2cfb05()[_0x53b49a('0xb35')](_0x53b49a('0x64e'))+'\x20deleted!','msg':_0x1f0ea3[_0x53b49a('0x4f0')]?_0x1f0ea3[_0x53b49a('0x4f0')]+_0x53b49a('0x7cd'):''});})[_0x252f0f('0x1a80')](function(_0x545b3d){const _0x466cd2=_0x252f0f;if(_0x545b3d[_0x466cd2('0x25f4')]&&_0x545b3d[_0x466cd2('0x25f4')][_0x466cd2('0x61a')]&&_0x545b3d[_0x466cd2('0x25f4')][_0x466cd2('0x61a')]['length']){_0x34a94f[_0x466cd2('0x61a')]=_0x545b3d[_0x466cd2('0x25f4')][_0x466cd2('0x61a')]||[{'message':_0x545b3d[_0x466cd2('0x1586')](),'type':_0x466cd2('0x1e34')}];for(let _0x5c3a40=0x0;_0x5c3a40<_0x545b3d['data']['errors'][_0x466cd2('0x264b')];_0x5c3a40++){_0x44704d[_0x466cd2('0xfc9')]({'title':_0x545b3d[_0x466cd2('0x25f4')]['errors'][_0x5c3a40][_0x466cd2('0x1345')],'msg':_0x545b3d[_0x466cd2('0x25f4')]['errors'][_0x5c3a40][_0x466cd2('0x1e70')]});}}else _0x44704d['error']({'title':_0x545b3d['status']?_0x466cd2('0x1e21')+_0x545b3d[_0x466cd2('0x52d')]+'\x20-\x20'+_0x545b3d[_0x466cd2('0xe1b')]:_0x466cd2('0x1e34'),'msg':_0x545b3d[_0x466cd2('0x25f4')]?JSON[_0x466cd2('0xbac')](_0x545b3d[_0x466cd2('0x25f4')][_0x466cd2('0x1e70')]):_0x545b3d[_0x466cd2('0x1e70')]||_0x545b3d['toString']()});});}function _0x2aa988(){const _0x5c359e=_0x216bc8,_0x2c5e5c=angular[_0x5c359e('0x225f')](_0x34a94f[_0x5c359e('0xe14')]);return _0x34a94f[_0x5c359e('0xe14')]=[],_0x2c5e5c;}function _0x4e1d93(_0x46a6fd){const _0x2c6a6f=_0x216bc8,_0x5c8d72=_0x5e36ea['confirm']()[_0x2c6a6f('0xcdc')](_0x2c6a6f('0xf81'))['htmlContent'](''+_0x34a94f[_0x2c6a6f('0xe14')][_0x2c6a6f('0x264b')]+_0x2c6a6f('0x196d')+_0x2c6a6f('0x3f3'))[_0x2c6a6f('0x8e8')](_0x2c6a6f('0xf9e'))[_0x2c6a6f('0x203b')](_0x46a6fd)['ok']('OK')[_0x2c6a6f('0x3f')]('CANCEL');_0x5e36ea[_0x2c6a6f('0x1f80')](_0x5c8d72)[_0x2c6a6f('0x1166')](function(){const _0x33e4b6=_0x2c6a6f;_0x34a94f['selectedUserProfiles'][_0x33e4b6('0x2782')](function(_0x40e510){_0x57549f(_0x40e510);}),_0x34a94f[_0x33e4b6('0xe14')]=[];});}function _0x28e485(){const _0x5f5228=_0x216bc8;_0x34a94f[_0x5f5228('0xe14')]=[];}function _0x12dfb7(){const _0x3850b3=_0x216bc8;_0x34a94f['selectedUserProfiles']=_0x34a94f[_0x3850b3('0x11e3')][_0x3850b3('0x269a')];}}const _0x589990=_0xdb37c6;_0x4a329b[_0x36e6f4('0x1294')]=['$scope','$state','$location','$mdDialog','$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0x21f6'),_0x36e6f4('0x557'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),'crudPermissions'];function _0x4a329b(_0x1d0f1e,_0x2380ad,_0x571fe4,_0x3222b0,_0x270d6f,_0xf6047e,_0x78ff69,_0x4a8631,_0x3460dd,_0x4627d3,_0x57582,_0x49794b,_0x47a737,_0x3b5492){const _0x1d142b=_0x36e6f4,_0x591c2d=this;_0x591c2d['currentUser']=_0x57582[_0x1d142b('0x26cd')](),_0x591c2d['errors']=[],_0x591c2d[_0x1d142b('0xf8a')]=_0x47a737,_0x591c2d[_0x1d142b('0x5c9')]=_0x49794b,_0x591c2d[_0x1d142b('0x243c')]=_0x3b5492,_0x591c2d[_0x1d142b('0x128b')]={},_0x591c2d[_0x1d142b('0x2900')]=_0x591c2d[_0x1d142b('0xf8a')]&&_0x591c2d[_0x1d142b('0xf8a')][_0x1d142b('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x591c2d[_0x1d142b('0xcdc')]=_0x1d142b('0x2739'),_0x591c2d['user']=angular['copy'](_0x3460dd),_0x591c2d[_0x1d142b('0x21f6')]=_0x4a8631,_0x591c2d[_0x1d142b('0x1363')]=![];!_0x591c2d['user']&&(_0x591c2d[_0x1d142b('0x557')]={'role':_0x1d142b('0x557'),'autointernal':!![],'context':_0x1d142b('0xb31')},_0x591c2d[_0x1d142b('0xcdc')]=_0x1d142b('0x1278'),_0x591c2d[_0x1d142b('0x1363')]=!![]);_0x591c2d['addNewUser']=_0x378548,_0x591c2d[_0x1d142b('0x1b40')]=_0x4f0092,_0x591c2d[_0x1d142b('0x1d3c')]=_0xa45010,_0x591c2d[_0x1d142b('0x1a9c')]=_0x437fd8,_0x591c2d['closeDialog']=_0x380260,_0x4627d3[_0x1d142b('0x7f')][_0x1d142b('0xd83')]({'fields':_0x1d142b('0x1776'),'sort':_0x1d142b('0x4f0')})[_0x1d142b('0xa44')]['then'](function(_0x10edee){const _0x367e7d=_0x1d142b;_0x591c2d[_0x367e7d('0x11e3')]=_0x10edee['rows']||[];})[_0x1d142b('0x1a80')](function(_0x12092f){const _0x213795=_0x1d142b;_0x78ff69['error']({'title':_0x12092f[_0x213795('0x52d')]?'API:'+_0x12092f['status']+_0x213795('0x11e1')+_0x12092f[_0x213795('0xe1b')]:'SYSTEM:GET_USERPROFILES','msg':_0x12092f[_0x213795('0x25f4')]?JSON[_0x213795('0xbac')](_0x12092f[_0x213795('0x25f4')]):_0x12092f[_0x213795('0x1586')]()});});function _0x378548(){const _0x7647c6=_0x1d142b;_0x591c2d['errors']=[],_0x4627d3[_0x7647c6('0x557')][_0x7647c6('0x9cc')](_0x591c2d[_0x7647c6('0x557')])['$promise']['then'](function(_0x172975){const _0x25539c=_0x7647c6;_0x591c2d[_0x25539c('0x21f6')][_0x25539c('0x2450')](_0x172975[_0x25539c('0x2876')]()),_0x78ff69[_0x25539c('0x103b')]({'title':_0x25539c('0xa77'),'msg':_0x591c2d['user']['name']?_0x591c2d['user'][_0x25539c('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x380260(_0x172975);})['catch'](function(_0x5268b2){const _0x59dcf2=_0x7647c6;if(_0x5268b2[_0x59dcf2('0x25f4')]&&_0x5268b2[_0x59dcf2('0x25f4')][_0x59dcf2('0x61a')]&&_0x5268b2[_0x59dcf2('0x25f4')]['errors'][_0x59dcf2('0x264b')]){_0x591c2d[_0x59dcf2('0x61a')]=_0x5268b2[_0x59dcf2('0x25f4')][_0x59dcf2('0x61a')]||[{'message':_0x5268b2['toString'](),'type':_0x59dcf2('0xe5d')}];for(let _0x386366=0x0;_0x386366<_0x5268b2['data'][_0x59dcf2('0x61a')]['length'];_0x386366+=0x1){_0x78ff69[_0x59dcf2('0xfc9')]({'title':_0x5268b2[_0x59dcf2('0x25f4')]['errors'][_0x386366]['type'],'msg':_0x5268b2['data'][_0x59dcf2('0x61a')][_0x386366]['message']});}}else _0x78ff69[_0x59dcf2('0xfc9')]({'title':_0x5268b2['status']?_0x59dcf2('0x1e21')+_0x5268b2[_0x59dcf2('0x52d')]+_0x59dcf2('0x11e1')+_0x5268b2[_0x59dcf2('0xe1b')]:'api.user.save','msg':_0x5268b2[_0x59dcf2('0x25f4')]?JSON['stringify'](_0x5268b2[_0x59dcf2('0x25f4')]['message']):_0x5268b2['toString']()});});}function _0x4f0092(){const _0x4c63ee=_0x1d142b;_0x591c2d['errors']=[],_0x4627d3[_0x4c63ee('0x557')][_0x4c63ee('0x1449')]({'id':_0x591c2d[_0x4c63ee('0x557')]['id']},_0x591c2d[_0x4c63ee('0x557')])['$promise'][_0x4c63ee('0x1166')](function(_0x4d095a){const _0x4ff3ae=_0x4c63ee,_0x5e01fe=_0x2cfb05()[_0x4ff3ae('0xc38')](_0x591c2d[_0x4ff3ae('0x21f6')],{'id':_0x4d095a['id']});_0x5e01fe&&_0x2cfb05()[_0x4ff3ae('0xcc3')](_0x5e01fe,_0x2cfb05()[_0x4ff3ae('0x1a08')](_0x4d095a[_0x4ff3ae('0x2876')](),_0x2cfb05()[_0x4ff3ae('0x14a4')](_0x5e01fe))),_0x78ff69[_0x4ff3ae('0x103b')]({'title':_0x4ff3ae('0x18c1'),'msg':_0x591c2d[_0x4ff3ae('0x557')]['name']?_0x591c2d[_0x4ff3ae('0x557')][_0x4ff3ae('0x4f0')]+_0x4ff3ae('0x7d'):''}),_0x380260(_0x4d095a);})[_0x4c63ee('0x1a80')](function(_0xe2d4cb){const _0x1ba942=_0x4c63ee;if(_0xe2d4cb[_0x1ba942('0x25f4')]&&_0xe2d4cb['data']['errors']&&_0xe2d4cb[_0x1ba942('0x25f4')]['errors'][_0x1ba942('0x264b')]){_0x591c2d[_0x1ba942('0x61a')]=_0xe2d4cb[_0x1ba942('0x25f4')][_0x1ba942('0x61a')]||[{'message':_0xe2d4cb['toString'](),'type':_0x1ba942('0x1103')}];for(let _0x2ac31f=0x0;_0x2ac31f<_0xe2d4cb['data'][_0x1ba942('0x61a')][_0x1ba942('0x264b')];_0x2ac31f++){_0x78ff69[_0x1ba942('0xfc9')]({'title':_0xe2d4cb[_0x1ba942('0x25f4')][_0x1ba942('0x61a')][_0x2ac31f][_0x1ba942('0x1345')],'msg':_0xe2d4cb['data'][_0x1ba942('0x61a')][_0x2ac31f][_0x1ba942('0x1e70')]});}}else _0x78ff69['error']({'title':_0xe2d4cb[_0x1ba942('0x52d')]?_0x1ba942('0x1e21')+_0xe2d4cb[_0x1ba942('0x52d')]+_0x1ba942('0x11e1')+_0xe2d4cb['statusText']:'api.user.update','msg':_0xe2d4cb[_0x1ba942('0x25f4')]?JSON['stringify'](_0xe2d4cb['data']['message']):_0xe2d4cb[_0x1ba942('0x1586')]()});});}function _0xa45010(_0x525601){const _0x167b5e=_0x1d142b,_0x447d87=_0x57582[_0x167b5e('0x26cd')]();if(_0x447d87['id']===_0x591c2d[_0x167b5e('0x557')]['id'])return _0x78ff69['error']({'title':_0x167b5e('0x1d49'),'msg':_0x167b5e('0x15c')});_0x591c2d[_0x167b5e('0x61a')]=[];const _0x2ac18a=_0x3222b0['confirm']()[_0x167b5e('0xcdc')](_0x167b5e('0x7fb'))['content'](_0x167b5e('0xa2a'))[_0x167b5e('0x8e8')](_0x167b5e('0x2437'))['ok'](_0x167b5e('0x18'))['cancel'](_0x167b5e('0x497'))['targetEvent'](_0x525601);_0x3222b0['show'](_0x2ac18a)[_0x167b5e('0x1166')](function(){const _0x58dd01=_0x167b5e;_0x4627d3[_0x58dd01('0x557')][_0x58dd01('0x906')]({'id':_0x591c2d[_0x58dd01('0x557')]['id']})[_0x58dd01('0xa44')][_0x58dd01('0x1166')](function(){const _0x3ef9a0=_0x58dd01;_0x2cfb05()[_0x3ef9a0('0x127f')](_0x591c2d[_0x3ef9a0('0x21f6')],{'id':_0x591c2d[_0x3ef9a0('0x557')]['id']}),_0x78ff69['success']({'title':'User\x20properly\x20deleted!','msg':(_0x591c2d[_0x3ef9a0('0x557')][_0x3ef9a0('0x4f0')]||_0x3ef9a0('0x557'))+_0x3ef9a0('0x7cd')}),_0x380260(_0x591c2d[_0x3ef9a0('0x557')]);})[_0x58dd01('0x1a80')](function(_0x583e1a){const _0x2dfbb3=_0x58dd01;if(_0x583e1a[_0x2dfbb3('0x25f4')]&&_0x583e1a[_0x2dfbb3('0x25f4')][_0x2dfbb3('0x61a')]&&_0x583e1a[_0x2dfbb3('0x25f4')][_0x2dfbb3('0x61a')]['length']){_0x591c2d['errors']=_0x583e1a['data'][_0x2dfbb3('0x61a')]||[{'message':_0x583e1a[_0x2dfbb3('0x1586')](),'type':_0x2dfbb3('0x1304')}];for(let _0x5def09=0x0;_0x5def09<_0x583e1a[_0x2dfbb3('0x25f4')]['errors'][_0x2dfbb3('0x264b')];_0x5def09++){_0x78ff69[_0x2dfbb3('0xfc9')]({'title':_0x583e1a['data'][_0x2dfbb3('0x61a')][_0x5def09]['type'],'msg':_0x583e1a[_0x2dfbb3('0x25f4')][_0x2dfbb3('0x61a')][_0x5def09][_0x2dfbb3('0x1e70')]});}}else _0x78ff69[_0x2dfbb3('0xfc9')]({'title':_0x583e1a[_0x2dfbb3('0x52d')]?_0x2dfbb3('0x1e21')+_0x583e1a[_0x2dfbb3('0x52d')]+_0x2dfbb3('0x11e1')+_0x583e1a['statusText']:_0x2dfbb3('0x1304'),'msg':_0x583e1a[_0x2dfbb3('0x25f4')]?JSON['stringify'](_0x583e1a[_0x2dfbb3('0x25f4')][_0x2dfbb3('0x1e70')]):_0x583e1a[_0x2dfbb3('0x1e70')]||_0x583e1a[_0x2dfbb3('0x1586')]()});});},function(){});}function _0x437fd8(_0x373e4d){return _0x373e4d===null?undefined:new Date(_0x373e4d);}function _0x380260(_0x265c81){const _0x1fde92=_0x1d142b;_0x3222b0[_0x1fde92('0x1197')](_0x265c81);}}const _0x3d2ef3=_0x4a329b;_0x1860a5[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x557'),_0x36e6f4('0x21ef')];function _0x1860a5(_0x147cc6,_0x413f05,_0x30ebbd,_0x979279,_0x57cf06){const _0x459082=_0x36e6f4,_0x553408=this;_0x553408[_0x459082('0x98')]=_0x57cf06[_0x459082('0x26cd')](),_0x553408[_0x459082('0x61a')]=[],_0x553408['user']=_0x979279,_0x553408[_0x459082('0x26c2')]=_0x4fb60d,_0x553408[_0x459082('0x1e92')]=_0x55cea5,_0x553408[_0x459082('0x24a0')]=_0x4381d1;function _0x4fb60d(){const _0x2b6212=_0x459082;_0x553408[_0x2b6212('0x61a')]=[],_0x30ebbd['user'][_0x2b6212('0x28b3')]({'id':_0x553408['user']['id']})['$promise'][_0x2b6212('0x1166')](function(_0x5bf148){const _0x262db6=_0x2b6212;_0x553408['user'][_0x262db6('0x1a04')]=_0x5bf148[_0x262db6('0x246f')]||_0x262db6('0x4b1'),_0x413f05[_0x262db6('0x103b')]({'title':_0x262db6('0x212f')}),_0x4381d1();})[_0x2b6212('0x1a80')](function(_0x173830){const _0x44771f=_0x2b6212;_0x413f05[_0x44771f('0xfc9')]({'title':_0x173830['status']?_0x44771f('0x1e21')+_0x173830['status']+_0x44771f('0x11e1')+_0x173830[_0x44771f('0xe1b')]:_0x44771f('0xc1d'),'msg':_0x173830[_0x44771f('0x25f4')]?JSON[_0x44771f('0xbac')](_0x173830['data']['message']):_0x173830[_0x44771f('0x1586')]()}),_0x553408[_0x44771f('0x61a')]=_0x173830['data'][_0x44771f('0x61a')]||[{'message':_0x173830[_0x44771f('0x1586')](),'type':'api.user.createApiKey'}];});}function _0x55cea5(){const _0x52b4e0=_0x459082;_0x553408['errors']=[],_0x30ebbd[_0x52b4e0('0x557')][_0x52b4e0('0x1e92')]({'id':_0x553408[_0x52b4e0('0x557')]['id']})[_0x52b4e0('0xa44')][_0x52b4e0('0x1166')](function(){const _0x49ed0e=_0x52b4e0;_0x553408[_0x49ed0e('0x557')][_0x49ed0e('0x1a04')]=_0x49ed0e('0x4b1'),_0x413f05['success']({'title':_0x49ed0e('0x2236')}),_0x4381d1();})[_0x52b4e0('0x1a80')](function(_0x2b0916){const _0xc79d8=_0x52b4e0;_0x413f05[_0xc79d8('0xfc9')]({'title':_0x2b0916[_0xc79d8('0x52d')]?'API:'+_0x2b0916[_0xc79d8('0x52d')]+_0xc79d8('0x11e1')+_0x2b0916['statusText']:'api.user.removeApiKey','msg':_0x2b0916[_0xc79d8('0x25f4')]?JSON[_0xc79d8('0xbac')](_0x2b0916[_0xc79d8('0x25f4')]['message']):_0x2b0916[_0xc79d8('0x1586')]()}),_0x553408[_0xc79d8('0x61a')]=_0x2b0916[_0xc79d8('0x25f4')][_0xc79d8('0x61a')]||[{'message':_0x2b0916[_0xc79d8('0x1586')](),'type':_0xc79d8('0x409')}];});}function _0x4381d1(){const _0x3a7278=_0x459082;_0x147cc6[_0x3a7278('0x1197')]();}}const _0x43a409=_0x1860a5;_0x5a5980[_0x36e6f4('0x1294')]=['$cookies','toasty'];function _0x5a5980(_0x1d8c59,_0x57b408){const _0xf9fd7c=_0x36e6f4,_0x11a8a5=this,_0x211daa=0x8,_0x20e145=_0x211daa*0x400*0x400;_0x11a8a5[_0xf9fd7c('0x557')]={},_0x11a8a5[_0xf9fd7c('0x243c')],_0x11a8a5['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x20e145,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x11a8a5[_0xf9fd7c('0xe57')]={'flow':{}},_0x11a8a5[_0xf9fd7c('0x1a5c')]=![],_0x11a8a5[_0xf9fd7c('0xd20')]=_0x4f0c3d,_0x11a8a5[_0xf9fd7c('0x1d40')]=_0x4e22fe,_0x11a8a5[_0xf9fd7c('0x1dea')]=_0x3adb92,_0x11a8a5[_0xf9fd7c('0x24d5')]=_0x300e8f;function _0x300e8f(_0x13d410,_0x345ec8){const _0x4658dd=_0xf9fd7c;_0x11a8a5[_0x4658dd('0x557')]=angular[_0x4658dd('0x225f')](_0x13d410),_0x11a8a5[_0x4658dd('0x243c')]=typeof _0x345ec8!==_0x4658dd('0x1048')?_0x345ec8:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x11a8a5[_0x4658dd('0xd67')][_0x4658dd('0x21cc')]='api/users/'+_0x11a8a5[_0x4658dd('0x557')]['id']+_0x4658dd('0x18c4'),_0x11a8a5[_0x4658dd('0x557')]['images']=[];}function _0x4f0c3d(_0x3da1b3){const _0xdf5dd0=_0xf9fd7c,_0x4ddf30=['png','jpg'];if(!_0x2cfb05()[_0xdf5dd0('0x1257')](_0x4ddf30,_0x3da1b3[_0xdf5dd0('0x26a5')]()))return _0x57b408[_0xdf5dd0('0xfc9')]({'title':'Invalid\x20extension:\x20'+_0x3da1b3[_0xdf5dd0('0x26a5')](),'msg':'Supported\x20extension:\x20'+_0x4ddf30[_0xdf5dd0('0x45a')]()}),![];if(_0x3da1b3[_0xdf5dd0('0x2340')]>_0x20e145)return _0x57b408[_0xdf5dd0('0xfc9')]({'title':_0xdf5dd0('0x11e6'),'msg':_0xdf5dd0('0x12c0')+_0x211daa+'MB'}),![];const _0x441eec={'id':_0x3da1b3[_0xdf5dd0('0x20f4')],'file':_0x3da1b3,'type':_0xdf5dd0('0x32f')};return _0x11a8a5['user'][_0xdf5dd0('0x1b17')]['unshift'](_0x441eec),!![];}function _0x4e22fe(){const _0x1f4e03=_0xf9fd7c;_0x11a8a5[_0x1f4e03('0xe57')][_0x1f4e03('0x13d1')]['opts'][_0x1f4e03('0x5fb')]={'X-Requested-With':_0x1f4e03('0x1bc1'),'Authorization':_0x1f4e03('0x24d4')+_0x1d8c59[_0x1f4e03('0xd83')](_0x1f4e03('0x10b6'))},_0x11a8a5['ngFlow'][_0x1f4e03('0x13d1')][_0x1f4e03('0x1d40')]();}function _0x3adb92(_0x16979e){const _0x342c7e=_0xf9fd7c;angular[_0x342c7e('0x2782')](_0x11a8a5[_0x342c7e('0x557')]['images'],function(_0x3b0c25){const _0x4075b5=_0x342c7e;if(_0x3b0c25['id']===_0x16979e[_0x4075b5('0x20f4')]){const _0x431301=new FileReader();_0x431301[_0x4075b5('0x2030')](_0x3b0c25[_0x4075b5('0x6bd')][_0x4075b5('0x6bd')]),_0x431301['onload']=function(_0x67ebdb){const _0x3dd2bd=_0x4075b5;_0x3b0c25[_0x3dd2bd('0xcac')]=_0x67ebdb[_0x3dd2bd('0x21cc')]['result'];},_0x3b0c25[_0x4075b5('0x1345')]=_0x4075b5('0x19f5');}});}}const _0x9c2c35=_0x5a5980;_0x119e2c['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x557'),_0x36e6f4('0xf8a'),_0x36e6f4('0x21ef')];function _0x119e2c(_0x2a41f9,_0x467f69,_0x35fe33,_0x5d0dd7,_0xf7a838,_0x1b090f,_0x52ce8c){const _0x395dc8=_0x36e6f4,_0x4adcd8=this;_0x4adcd8[_0x395dc8('0x98')]=_0x52ce8c[_0x395dc8('0x26cd')](),_0x4adcd8[_0x395dc8('0x61a')]=[],_0x4adcd8[_0x395dc8('0xf8a')]=_0x1b090f,_0x4adcd8[_0x395dc8('0x2900')]=_0x4adcd8[_0x395dc8('0xf8a')][_0x395dc8('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4adcd8[_0x395dc8('0x557')]=_0xf7a838,_0x4adcd8[_0x395dc8('0x26e8')]='',_0x4adcd8[_0x395dc8('0x27f2')]='',_0x4adcd8[_0x395dc8('0x2639')]=_0x43a352,_0x4adcd8['closeDialog']=_0x507bc1,_0x2a41f9[_0x395dc8('0xe83')](_0x395dc8('0x2560'),function(_0x20f5cf){const _0x6290d5=_0x395dc8;!_0x2cfb05()['isNil'](_0x4adcd8[_0x6290d5('0x27f2')])&&(_0x20f5cf===_0x4adcd8['oldPassword']?_0x2a41f9[_0x6290d5('0x116b')][_0x6290d5('0x26e8')]['$setValidity']('oldPasswordMatch',![]):_0x2a41f9[_0x6290d5('0x116b')]['password'][_0x6290d5('0x28c9')](_0x6290d5('0x25a9'),!![]));});function _0x43a352(){const _0x5219a4=_0x395dc8;_0x4adcd8['errors']=[];const _0xcc06cf={'id':_0x4adcd8['user']['id'],'newPassword':_0x4adcd8['password']};_0x4adcd8[_0x5219a4('0x98')]['id']==_0x4adcd8[_0x5219a4('0x557')]['id']&&(_0xcc06cf[_0x5219a4('0x27f2')]=_0x4adcd8[_0x5219a4('0x27f2')]),_0x5d0dd7[_0x5219a4('0x557')][_0x5219a4('0xa78')](_0xcc06cf)['$promise'][_0x5219a4('0x1166')](function(){const _0x15f96d=_0x5219a4;_0x35fe33[_0x15f96d('0x103b')]({'title':_0x15f96d('0xd03')}),_0x507bc1();})['catch'](function(_0x3a3a7c){const _0x56b218=_0x5219a4;_0x35fe33[_0x56b218('0xfc9')]({'title':_0x3a3a7c[_0x56b218('0x52d')]?_0x56b218('0x1e21')+_0x3a3a7c[_0x56b218('0x52d')]+_0x56b218('0x11e1')+_0x3a3a7c[_0x56b218('0xe1b')]:_0x56b218('0xe5d'),'msg':_0x3a3a7c['data']?JSON[_0x56b218('0xbac')](_0x3a3a7c[_0x56b218('0x25f4')][_0x56b218('0x1e70')]):_0x3a3a7c[_0x56b218('0x1586')]()}),_0x4adcd8['errors']=_0x3a3a7c[_0x56b218('0x25f4')]['errors']||[{'message':_0x3a3a7c[_0x56b218('0x1586')](),'type':_0x56b218('0x35d')}];});}function _0x507bc1(){const _0x12e45d=_0x395dc8;_0x467f69[_0x12e45d('0x1197')]();}}const _0x5efec4=_0x119e2c,_0x5c82b6=_0x2734b2['p']+_0x36e6f4('0x252b'),_0x33e15b=_0x2734b2['p']+'src/js/modules/main/apps/staff/views/users/edit/changepassword/changepassword.html/changepassword.html';_0x4f580d['$inject']=[_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),'setting','api','toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x557'),'userProfileSection'];function _0x4f580d(_0x294c17,_0x22400b,_0x34b797,_0x5340ab,_0x11921e,_0x51c31b,_0x592d2e,_0x2643c3,_0x355fa6,_0x3e7581,_0x337109,_0x34c762){const _0x1f2f34=_0x36e6f4,_0x4c6ba8=this;_0x4c6ba8['currentUser']=_0x3e7581[_0x1f2f34('0x26cd')](),_0x4c6ba8['license']=_0x51c31b,_0x4c6ba8[_0x1f2f34('0xf8a')]=_0x592d2e,_0x4c6ba8[_0x1f2f34('0x2900')]=_0x4c6ba8['setting'][_0x1f2f34('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4c6ba8[_0x1f2f34('0x246b')]=_0x22400b['protocol']()+_0x1f2f34('0xc51')+_0x22400b[_0x1f2f34('0x1690')](),_0x4c6ba8['user']=_0x337109||_0x294c17['params'][_0x1f2f34('0x557')]||{},_0x4c6ba8['userProfileSection']=_0x34c762&&_0x34c762[_0x1f2f34('0x240f')]==0x1?_0x34c762[_0x1f2f34('0x269a')][0x0]:null,_0x4c6ba8['crudPermissions']=_0x3e7581['parseCrudPermissions'](_0x4c6ba8[_0x1f2f34('0x17aa')]?_0x4c6ba8[_0x1f2f34('0x17aa')][_0x1f2f34('0x243c')]:null),_0x4c6ba8[_0x1f2f34('0x128b')]={},_0x4c6ba8[_0x1f2f34('0x2669')]=_0x294c17[_0x1f2f34('0x23f')][_0x1f2f34('0xbe3')]||0x0,_0x4c6ba8['apikeymanagerdialog']=_0x4d9430,_0x4c6ba8['changepassworddialog']=_0x2463fb,_0x4c6ba8[_0x1f2f34('0x31d')]=_0x355fa6[_0x1f2f34('0x1fa1')],_0x4c6ba8[_0x1f2f34('0x667')]=_0x401fb4,_0x4c6ba8[_0x1f2f34('0x1b40')]=_0x43ca8f,_0x2643c3[_0x1f2f34('0x23b1')]['get']({'fields':_0x1f2f34('0x1776'),'sort':_0x1f2f34('0x4f0')})['$promise'][_0x1f2f34('0x1166')](function(_0x249804){const _0xf7c4b6=_0x1f2f34;_0x4c6ba8[_0xf7c4b6('0x160a')]=_0x249804[_0xf7c4b6('0x269a')]||[];})['catch'](function(_0x544e55){const _0x13dd71=_0x1f2f34;_0x355fa6[_0x13dd71('0xfc9')]({'title':_0x544e55[_0x13dd71('0x52d')]?_0x13dd71('0x1e21')+_0x544e55['status']+'\x20-\x20'+_0x544e55['statusText']:_0x13dd71('0x140d'),'msg':_0x544e55[_0x13dd71('0x25f4')]?JSON[_0x13dd71('0xbac')](_0x544e55[_0x13dd71('0x25f4')]):_0x544e55[_0x13dd71('0x1586')]()});}),_0x2643c3[_0x1f2f34('0x7f')][_0x1f2f34('0xd83')]({'fields':_0x1f2f34('0x1776'),'sort':_0x1f2f34('0x4f0')})[_0x1f2f34('0xa44')][_0x1f2f34('0x1166')](function(_0x36fa22){const _0x3c52fd=_0x1f2f34;_0x4c6ba8[_0x3c52fd('0x11e3')]=_0x36fa22[_0x3c52fd('0x269a')]||[];})[_0x1f2f34('0x1a80')](function(_0x3d6f52){const _0x4016e9=_0x1f2f34;_0x355fa6[_0x4016e9('0xfc9')]({'title':_0x3d6f52['status']?_0x4016e9('0x1e21')+_0x3d6f52[_0x4016e9('0x52d')]+_0x4016e9('0x11e1')+_0x3d6f52['statusText']:_0x4016e9('0x1da5'),'msg':_0x3d6f52[_0x4016e9('0x25f4')]?JSON['stringify'](_0x3d6f52[_0x4016e9('0x25f4')]):_0x3d6f52[_0x4016e9('0x1586')]()});}),_0x2643c3['user']['getApiKey']({'id':_0x4c6ba8['user']['id']})[_0x1f2f34('0xa44')][_0x1f2f34('0x1166')](function(_0x2f2e7f){const _0x551aa8=_0x1f2f34;_0x4c6ba8['user'][_0x551aa8('0x1a04')]=_0x2f2e7f[_0x551aa8('0x246f')]?_0x2f2e7f['api_key']:_0x551aa8('0x4b1');})[_0x1f2f34('0x1a80')](function(_0x17738c){const _0x16507b=_0x1f2f34;_0x355fa6[_0x16507b('0xfc9')]({'title':_0x17738c[_0x16507b('0x52d')]?_0x16507b('0x1e21')+_0x17738c[_0x16507b('0x52d')]+_0x16507b('0x11e1')+_0x17738c['statusText']:_0x16507b('0xae4'),'msg':_0x17738c['data']?JSON[_0x16507b('0xbac')](_0x17738c['data']):_0x17738c[_0x16507b('0x1586')]()});});function _0x4d9430(_0x594c81,_0x38b9c0){const _0x237266=_0x1f2f34;_0x34b797[_0x237266('0x1f80')]({'controller':'UserapikeymanagerController','controllerAs':'vm','templateUrl':_0x5c82b6,'parent':angular['element'](_0x5340ab['body']),'targetEvent':_0x38b9c0,'clickOutsideToClose':!![],'locals':{'user':_0x594c81,'users':_0x4c6ba8['users']?_0x4c6ba8['users'][_0x237266('0x269a')]:[],'crudPermissions':_0x4c6ba8[_0x237266('0x243c')]}});}function _0x2463fb(_0x15ffa5,_0x4682f9){const _0x4edf8d=_0x1f2f34;_0x34b797[_0x4edf8d('0x1f80')]({'controller':_0x4edf8d('0x96d'),'controllerAs':'vm','templateUrl':_0x33e15b,'parent':angular[_0x4edf8d('0x1194')](_0x5340ab[_0x4edf8d('0x8d2')]),'targetEvent':_0x4682f9,'clickOutsideToClose':!![],'locals':{'user':_0x15ffa5,'setting':_0x592d2e,'users':_0x4c6ba8['users']?_0x4c6ba8[_0x4edf8d('0x21f6')][_0x4edf8d('0x269a')]:[],'crudPermissions':_0x4c6ba8[_0x4edf8d('0x243c')]}});}function _0x401fb4(){const _0x16bbab=_0x1f2f34;_0x294c17['go']('app.staff.users',{},{'reload':_0x16bbab('0x218d')});}function _0x43ca8f(){const _0x1e5dd4=_0x1f2f34;_0x4c6ba8[_0x1e5dd4('0x557')]=_0x2cfb05()[_0x1e5dd4('0x1414')](_0x4c6ba8[_0x1e5dd4('0x557')],'userpic'),_0x2643c3[_0x1e5dd4('0x557')][_0x1e5dd4('0x1449')]({'id':_0x4c6ba8['user']['id']},_0x4c6ba8[_0x1e5dd4('0x557')])[_0x1e5dd4('0xa44')]['then'](function(){const _0x209e96=_0x1e5dd4;_0x355fa6['success']({'title':_0x209e96('0xb85'),'msg':_0x4c6ba8[_0x209e96('0x557')]['name']?_0x4c6ba8[_0x209e96('0x557')][_0x209e96('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x1e5dd4('0x1a80')](function(_0x1ee6d8){const _0x37df49=_0x1e5dd4;_0x355fa6['error']({'title':_0x1ee6d8[_0x37df49('0x52d')]?_0x37df49('0x1e21')+_0x1ee6d8[_0x37df49('0x52d')]+_0x37df49('0x11e1')+_0x1ee6d8[_0x37df49('0xe1b')]:_0x37df49('0xf82'),'msg':_0x1ee6d8['data']?JSON[_0x37df49('0xbac')](_0x1ee6d8[_0x37df49('0x25f4')]):_0x1ee6d8[_0x37df49('0x1586')]()});});}}const _0x8597de=_0x4f580d,_0x57b9d6=_0x2734b2['p']+_0x36e6f4('0x2733');_0xcee327[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x21f6'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),'api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0xcee327(_0x4baab4,_0x342669,_0x516e17,_0x2359e6,_0x54b624,_0x2debd9,_0x3d4e90,_0x5a2be4,_0x192132,_0x17ce67,_0x1b4c60,_0xf264ea,_0x29da32,_0x4ba724,_0x395e6a,_0x3a4069,_0x2c6f4f){const _0x19d39a=_0x36e6f4,_0x17b784=this;_0x17b784[_0x19d39a('0x5c9')]=_0x3a4069,_0x17b784['setting']=_0x2c6f4f,_0x17b784['currentUser']=_0x395e6a[_0x19d39a('0x26cd')](),_0x17b784['users']=_0x192132||{'count':0x0,'rows':[]},_0x17b784[_0x19d39a('0x7f')]=_0x17ce67,_0x17b784['userProfileSection']=_0x1b4c60&&_0x1b4c60[_0x19d39a('0x240f')]==0x1?_0x1b4c60['rows'][0x0]:null,_0x17b784[_0x19d39a('0x243c')]=_0x395e6a[_0x19d39a('0xd87')](_0x17b784[_0x19d39a('0x17aa')]?_0x17b784[_0x19d39a('0x17aa')][_0x19d39a('0x243c')]:null),_0x17b784[_0x19d39a('0x916')]='users',_0x17b784['listOrder']='',_0x17b784[_0x19d39a('0x104c')]=null,_0x17b784[_0x19d39a('0x144')]=[],_0x17b784[_0x19d39a('0x2218')]={'fields':_0x19d39a('0xeec'),'role':_0x19d39a('0xe8f'),'sort':_0x19d39a('0x14dc'),'limit':0xa,'page':0x1},_0x17b784['arrayrole']=_0x2cfb05()[_0x19d39a('0x155c')]([{'option':_0x19d39a('0x28c3'),'value':_0x19d39a('0x19f4')},{'option':_0x19d39a('0x1a6f'),'value':_0x19d39a('0x247a')}],function(_0xaead3a){const _0x19298a=_0x19d39a;return _0x2cfb05()[_0x19298a('0xf3')](_0xaead3a[_0x19298a('0x18e0')],new RegExp('\x27','g'),'');}),_0x17b784['arraytransport']=_0x2cfb05()[_0x19d39a('0x155c')]([{'option':_0x19d39a('0x8fc'),'value':_0x19d39a('0xc29')},{'option':_0x19d39a('0xe31'),'value':_0x19d39a('0x1d5e')},{'option':'ws','value':_0x19d39a('0x1eb6')},{'option':_0x19d39a('0x83a'),'value':_0x19d39a('0x28da')},{'option':'tls','value':'\x27tls\x27'}],function(_0x38ff1c){const _0x509116=_0x19d39a;return _0x2cfb05()[_0x509116('0xf3')](_0x38ff1c['value'],new RegExp('\x27','g'),'');}),_0x17b784[_0x19d39a('0x1c9')]=_0x2cfb05()['keyBy']([{'option':_0x19d39a('0x976'),'value':_0x19d39a('0x553')},{'option':_0x19d39a('0x232d'),'value':_0x19d39a('0x3e6')},{'option':_0x19d39a('0x55d'),'value':'\x27yes\x27'},{'option':'no','value':_0x19d39a('0x119b')},{'option':_0x19d39a('0x122f'),'value':_0x19d39a('0x130c')},{'option':_0x19d39a('0x16a8'),'value':'\x27route\x27'}],function(_0x161ca3){const _0x257ab3=_0x19d39a;return _0x2cfb05()[_0x257ab3('0xf3')](_0x161ca3[_0x257ab3('0x18e0')],new RegExp('\x27','g'),'');}),_0x17b784[_0x19d39a('0x140')]=_0x2cfb05()[_0x19d39a('0x155c')]([{'option':_0x19d39a('0x1838'),'value':_0x19d39a('0x166f')},{'option':'alaw','value':_0x19d39a('0x1573')},{'option':_0x19d39a('0x1cd9'),'value':_0x19d39a('0xd74')},{'option':'g722','value':_0x19d39a('0x1ae2')},{'option':_0x19d39a('0x19b7'),'value':_0x19d39a('0x48d')},{'option':'opus','value':_0x19d39a('0x1fbd')},{'option':_0x19d39a('0x173a'),'value':'\x27h264\x27'}],function(_0x17f626){const _0x26251f=_0x19d39a;return _0x2cfb05()[_0x26251f('0xf3')](_0x17f626[_0x26251f('0x18e0')],new RegExp('\x27','g'),'');}),_0x17b784[_0x19d39a('0x1f32')]=_0x2cfb05()[_0x19d39a('0x155c')]([{'option':'Yes','value':_0x19d39a('0x20b3')},{'option':'No','value':_0x19d39a('0x119b')},{'option':'Always','value':_0x19d39a('0x312')}],function(_0x27bea4){const _0x555673=_0x19d39a;return _0x2cfb05()[_0x555673('0xf3')](_0x27bea4[_0x555673('0x18e0')],new RegExp('\x27','g'),'');}),_0x17b784['editstate']=_0x10d184,_0x17b784['deleteconfirm']=_0x4a3928,_0x17b784[_0x19d39a('0x103b')]=_0xc7f46e,_0x17b784[_0x19d39a('0x1bcb')]=_0x1ca4ce,_0x17b784[_0x19d39a('0x19b2')]=_0x596c1d,_0x17b784[_0x19d39a('0x1d3c')]=_0x33102e,_0x17b784[_0x19d39a('0x275a')]=_0x3c2ebe,_0x17b784[_0x19d39a('0xb91')]=_0x438dc9,_0x17b784[_0x19d39a('0x2422')]=_0x5c2ee8,_0x17b784[_0x19d39a('0x18b4')]=_0x1235fb,_0xf264ea[_0x19d39a('0x7f')]['get']({'fields':_0x19d39a('0x1776'),'sort':_0x19d39a('0x4f0')})[_0x19d39a('0xa44')][_0x19d39a('0x1166')](function(_0x3ae2fe){const _0x235d2d=_0x19d39a;_0x17b784[_0x235d2d('0x11e3')]=_0x3ae2fe['rows']||[];})['catch'](function(_0x10f5d3){const _0x4f21c8=_0x19d39a;_0x4ba724[_0x4f21c8('0xfc9')]({'title':_0x10f5d3[_0x4f21c8('0x52d')]?_0x4f21c8('0x1e21')+_0x10f5d3[_0x4f21c8('0x52d')]+_0x4f21c8('0x11e1')+_0x10f5d3['statusText']:_0x4f21c8('0x1da5'),'msg':_0x10f5d3[_0x4f21c8('0x25f4')]?JSON[_0x4f21c8('0xbac')](_0x10f5d3['data']):_0x10f5d3[_0x4f21c8('0x1586')]()});});function _0x10d184(_0x5e85ef){const _0x46ca33=_0x19d39a;_0x516e17['go'](_0x46ca33('0x26a'),{'id':_0x5e85ef['id'],'user':_0x5e85ef,'crudPermissions':_0x17b784[_0x46ca33('0x243c')]});}function _0x4a3928(_0xf433bb,_0x1ca28b){const _0x5d28a6=_0x19d39a,_0x4c9636=_0x54b624[_0x5d28a6('0x1d26')]()[_0x5d28a6('0xcdc')](_0x5d28a6('0x288d')+_0x2cfb05()[_0x5d28a6('0xb35')]('user')+'?')[_0x5d28a6('0xf3c')](''+(_0xf433bb[_0x5d28a6('0x4f0')]||_0x5d28a6('0x557'))+_0x5d28a6('0xace')+'\x20will\x20be\x20deleted.')[_0x5d28a6('0x8e8')](_0x5d28a6('0x1b73'))[_0x5d28a6('0x203b')](_0x1ca28b)['ok']('OK')['cancel']('CANCEL');_0x54b624['show'](_0x4c9636)['then'](function(){_0x33102e(_0xf433bb);},function(){console['log']('CANCEL');});}let _0x145662=!![],_0x8c5899=0x1;_0x4baab4[_0x19d39a('0xe83')]('vm.query.filter',function(_0x40d87d,_0x5ca4d2){const _0x9c5f63=_0x19d39a;_0x145662?_0x3d4e90(function(){_0x145662=![];}):(!_0x5ca4d2&&(_0x8c5899=_0x17b784[_0x9c5f63('0x2218')][_0x9c5f63('0x1a43')]),_0x40d87d!==_0x5ca4d2&&(_0x17b784['query'][_0x9c5f63('0x1a43')]=0x1),!_0x40d87d&&(_0x17b784['query']['page']=_0x8c5899),_0x17b784[_0x9c5f63('0x1bcb')]());});function _0xc7f46e(_0x1411c0){const _0x136946=_0x19d39a;_0x17b784[_0x136946('0x21f6')]=_0x1411c0||{'count':0x0,'rows':[]};}function _0x1ca4ce(){const _0x5dcaff=_0x19d39a;_0x17b784['query']['offset']=(_0x17b784[_0x5dcaff('0x2218')]['page']-0x1)*_0x17b784[_0x5dcaff('0x2218')][_0x5dcaff('0x163f')],_0x395e6a['hasRole'](_0x5dcaff('0xa7c'))?_0x17b784[_0x5dcaff('0x1f48')]=_0xf264ea[_0x5dcaff('0x557')][_0x5dcaff('0xd83')](_0x17b784[_0x5dcaff('0x2218')],_0xc7f46e)['$promise']:(_0x17b784[_0x5dcaff('0x2218')]['id']=_0x17b784[_0x5dcaff('0x7f')]['id'],_0x17b784[_0x5dcaff('0x2218')][_0x5dcaff('0xe60')]=_0x5dcaff('0x1bc7'),_0x17b784[_0x5dcaff('0x1f48')]=_0xf264ea[_0x5dcaff('0x7f')]['getResources'](_0x17b784[_0x5dcaff('0x2218')],_0xc7f46e)['$promise']);}function _0x596c1d(_0x230d0c,_0xf37073){const _0x13a87f=_0x19d39a;_0x54b624['show']({'controller':_0x13a87f('0x173c'),'controllerAs':'vm','templateUrl':_0x57b9d6,'parent':angular[_0x13a87f('0x1194')](_0x2debd9[_0x13a87f('0x8d2')]),'targetEvent':_0x230d0c,'clickOutsideToClose':!![],'locals':{'user':_0xf37073,'users':_0x17b784[_0x13a87f('0x21f6')][_0x13a87f('0x269a')],'license':_0x17b784[_0x13a87f('0x5c9')],'setting':_0x17b784['setting'],'crudPermissions':_0x17b784[_0x13a87f('0x243c')]}});}function _0x33102e(_0x3fa291){const _0x3288b9=_0x19d39a;_0xf264ea[_0x3288b9('0x557')][_0x3288b9('0x906')]({'id':_0x3fa291['id']})['$promise'][_0x3288b9('0x1166')](function(){const _0x2bdc70=_0x3288b9;_0x2cfb05()['remove'](_0x17b784[_0x2bdc70('0x21f6')]['rows'],{'id':_0x3fa291['id']}),_0x17b784[_0x2bdc70('0x21f6')]['count']-=0x1,!_0x17b784['users'][_0x2bdc70('0x269a')][_0x2bdc70('0x264b')]&&_0x17b784[_0x2bdc70('0x1bcb')](),_0x4ba724[_0x2bdc70('0x103b')]({'title':_0x2cfb05()[_0x2bdc70('0xb35')](_0x2bdc70('0x1a6f'))+_0x2bdc70('0x2b6'),'msg':_0x3fa291[_0x2bdc70('0x4f0')]?_0x3fa291[_0x2bdc70('0x4f0')]+_0x2bdc70('0x7cd'):''});})[_0x3288b9('0x1a80')](function(_0x1048e1){const _0x2b0866=_0x3288b9;if(_0x1048e1[_0x2b0866('0x25f4')]&&_0x1048e1[_0x2b0866('0x25f4')][_0x2b0866('0x61a')]&&_0x1048e1[_0x2b0866('0x25f4')][_0x2b0866('0x61a')][_0x2b0866('0x264b')]){_0x17b784[_0x2b0866('0x61a')]=_0x1048e1[_0x2b0866('0x25f4')][_0x2b0866('0x61a')]||[{'message':_0x1048e1[_0x2b0866('0x1586')](),'type':_0x2b0866('0x1f16')}];for(let _0x30a823=0x0;_0x30a823<_0x1048e1[_0x2b0866('0x25f4')][_0x2b0866('0x61a')]['length'];_0x30a823++){_0x4ba724[_0x2b0866('0xfc9')]({'title':_0x1048e1['data']['errors'][_0x30a823][_0x2b0866('0x1345')],'msg':_0x1048e1['data'][_0x2b0866('0x61a')][_0x30a823]['message']});}}else _0x4ba724['error']({'title':_0x1048e1[_0x2b0866('0x52d')]?'API:'+_0x1048e1[_0x2b0866('0x52d')]+_0x2b0866('0x11e1')+_0x1048e1['statusText']:_0x2b0866('0x1f16'),'msg':_0x1048e1[_0x2b0866('0x25f4')]?JSON['stringify'](_0x1048e1[_0x2b0866('0x25f4')]['message']):_0x1048e1[_0x2b0866('0x1e70')]||_0x1048e1[_0x2b0866('0x1586')]()});});}function _0x3c2ebe(){const _0x10e8d6=_0x19d39a,_0x346e15=angular[_0x10e8d6('0x225f')](_0x17b784['selectedUsers']);return _0x17b784[_0x10e8d6('0x144')]=[],_0x346e15;}function _0x438dc9(_0x259206){const _0x1978f6=_0x19d39a,_0x4c7763=_0x54b624['confirm']()[_0x1978f6('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20users?')['htmlContent'](_0x1978f6('0x12b5')+_0x17b784[_0x1978f6('0x144')]['length']+_0x1978f6('0x196d')+'\x20will\x20be\x20deleted.')[_0x1978f6('0x8e8')](_0x1978f6('0x1c7d'))['targetEvent'](_0x259206)['ok']('OK')['cancel'](_0x1978f6('0x2d3'));_0x54b624['show'](_0x4c7763)[_0x1978f6('0x1166')](function(){const _0x154289=_0x1978f6;_0x17b784[_0x154289('0x144')][_0x154289('0x2782')](function(_0x44c7db){_0x33102e(_0x44c7db);}),_0x17b784[_0x154289('0x144')]=[];});}function _0x5c2ee8(){_0x17b784['selectedUsers']=[];}function _0x1235fb(){const _0x489ae2=_0x19d39a;_0x17b784['selectedUsers']=_0x17b784[_0x489ae2('0x21f6')][_0x489ae2('0x269a')];}}const _0x426005=_0xcee327,_0x547051=_0x2734b2['p']+_0x36e6f4('0x148a'),_0x5abb5=_0x2734b2['p']+_0x36e6f4('0x128c'),_0x57f11b=_0x2734b2['p']+_0x36e6f4('0x2277'),_0x57196b=_0x2734b2['p']+'src/js/modules/main/apps/staff/views/agents/edit/view.html/view.html',_0xb32ccc=_0x2734b2['p']+_0x36e6f4('0x1978'),_0xc747d1=_0x2734b2['p']+_0x36e6f4('0x2063'),_0x1d51e6=_0x2734b2['p']+'src/js/modules/main/apps/staff/views/teams/teams.html/teams.html',_0x355c64=_0x2734b2['p']+_0x36e6f4('0x185f'),_0x1e6c74=_0x2734b2['p']+_0x36e6f4('0x512');_0x38caec[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x38caec(_0x58a758,_0xf0b783){const _0x409e32=_0x36e6f4;_0x58a758['state'](_0x409e32('0x957'),{'abstract':!![],'url':_0x409e32('0xfc1')})[_0x409e32('0x63f')]('app.staff.users',{'url':_0x409e32('0x27d3'),'views':{'content@app':{'templateUrl':_0x547051,'controller':'UsersController\x20as\x20vm'}},'resolve':{'users':[_0x409e32('0x1fbc'),function(_0x469cd1){const _0x1f3a6b=_0x409e32;return _0x469cd1[_0x1f3a6b('0x18af')](_0x1f3a6b('0x1c80'),{'fields':'createdAt,updatedAt,role,userProfileId,id,fullname,name,email,phone,mobile,userpic,password,description,autointernal,internal,transport,nat,allow,context,callgroup,pickupgroup,passwordResetAt,apiKey,videosupport,disabled,blocked','role':_0x1f3a6b('0xe8f'),'sort':_0x1f3a6b('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x409e32('0x21ef'),function(_0x1a631e,_0x2d54e8){const _0x485af5=_0x409e32;return _0x2d54e8[_0x485af5('0x1ac6')]('admin')?null:_0x1a631e[_0x485af5('0x18af')](_0x485af5('0x697'),{'fields':_0x485af5('0x686'),'id':_0x2d54e8['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x409e32('0x1fbc'),_0x409e32('0x21ef'),function(_0x621ca,_0x56861c){const _0x2a732e=_0x409e32;return _0x56861c[_0x2a732e('0x1ac6')](_0x2a732e('0xa7c'))?null:_0x621ca[_0x2a732e('0x18af')](_0x2a732e('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x56861c[_0x2a732e('0x26cd')]()[_0x2a732e('0xb86')],'sectionId':0xc9});}]},'authenticate':!![],'permissionId':0xc9,'bodyClass':'staff'})['state'](_0x409e32('0x26a'),{'url':_0x409e32('0x2233'),'params':{'user':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x5abb5,'controller':_0x409e32('0x530')}},'resolve':{'user':[_0x409e32('0x1fbc'),_0x409e32('0xf75'),function(_0x1eae84,_0x154b8f){const _0x3eb0a2=_0x409e32;return _0x1eae84[_0x3eb0a2('0x18af')](_0x3eb0a2('0x1c80'),{'fields':'createdAt,updatedAt,role,userProfileId,id,fullname,name,email,phone,mobile,userpic,password,description,autointernal,internal,transport,nat,allow,context,callgroup,pickupgroup,passwordResetAt,apiKey,videosupport,disabled,blocked','id':_0x154b8f['id']});}],'userProfileSection':[_0x409e32('0x1fbc'),'Auth',function(_0x321397,_0x483b94){const _0x1be930=_0x409e32;return _0x321397[_0x1be930('0x18af')](_0x1be930('0xaf'),{'fields':_0x1be930('0xe26'),'userProfileId':_0x483b94[_0x1be930('0x26cd')]()[_0x1be930('0xb86')],'sectionId':0xc9});}]},'authenticate':!![],'permissionId':0xc9,'bodyClass':'staff'})[_0x409e32('0x63f')](_0x409e32('0x2484'),{'url':_0x409e32('0x730'),'views':{'content@app':{'templateUrl':_0x57f11b,'controller':'AgentsController\x20as\x20vm'}},'resolve':{'agents':[_0x409e32('0x1fbc'),'Auth',function(_0x287bae,_0x33a913){const _0x5265fc=_0x409e32;return _0x33a913[_0x5265fc('0x1ac6')](_0x5265fc('0xa7c'))?_0x287bae[_0x5265fc('0x18af')](_0x5265fc('0x1c80'),{'fields':'createdAt,updatedAt,id,role,fullname,name,alias,showWebBar,email,phone,mobile,userpic,password,hotdesk,autointernal,internal,loginInPause,description,dtlscertfile,dtlsprivatekey,voicemail,transport,host,nat,type,allow,callerid,context,callgroup,pickupgroup,chanspy,videosupport,extensionMonitor,chatCapacity,mailCapacity,smsCapacity,openchannelCapacity,faxCapacity,whatsappCapacity,phoneBarEnableSettings,phoneBarAutoAnswer,phoneBarAutoAnswerDelay,phoneBarRingInUse,phoneBarEnableRecording,phoneBarEnableDtmfTone,phoneBarDnd,phoneBarUnansweredCallBadge,phoneBarEnableJaws,phoneBarOutboundProxy,phoneBarUnconditional,phoneBarUnconditionalNumber,phoneBarRemoteControl,phoneBarRemoteControlPort,phoneBarExpires,phoneBarListenPort,permissions,allowmessenger,phoneBarPrefixRequired,passwordResetAt,disabled,blocked,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0x5265fc('0x1eff'),'sort':_0x5265fc('0x14dc'),'limit':0xa,'offset':0x0}):_0x287bae['resolve']('userProfile@getResources',{'id':_0x33a913['getCurrentUser']()[_0x5265fc('0xb86')],'section':_0x5265fc('0x2391'),'fields':_0x5265fc('0x58b'),'role':_0x5265fc('0x1eff'),'sort':_0x5265fc('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver','Auth',function(_0x21ec29,_0x4c2456){const _0xdb9957=_0x409e32;return _0x4c2456[_0xdb9957('0x1ac6')](_0xdb9957('0xa7c'))?null:_0x21ec29['resolve'](_0xdb9957('0x697'),{'fields':_0xdb9957('0x686'),'id':_0x4c2456['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x409e32('0x1fbc'),_0x409e32('0x21ef'),function(_0x491966,_0x4dc25c){const _0x4172a3=_0x409e32;return _0x4dc25c[_0x4172a3('0x1ac6')](_0x4172a3('0xa7c'))?null:_0x491966[_0x4172a3('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x4dc25c[_0x4172a3('0x26cd')]()[_0x4172a3('0xb86')],'sectionId':0xca});}]},'authenticate':!![],'permissionId':0xca,'bodyClass':'staff'})[_0x409e32('0x63f')](_0x409e32('0x1583'),{'url':'/:id?tab','params':{'agent':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x57196b,'controller':'AgentController\x20as\x20vm'}},'resolve':{'agent':['apiResolver','$stateParams',function(_0x14448d,_0x4ac754){const _0x61627=_0x409e32;return _0x14448d[_0x61627('0x18af')](_0x61627('0x1c80'),{'fields':_0x61627('0x58b'),'id':_0x4ac754['id']});}],'userProfileSection':[_0x409e32('0x1fbc'),_0x409e32('0x21ef'),function(_0x16f8c0,_0x2c6271){const _0x3ca6d1=_0x409e32;return _0x16f8c0[_0x3ca6d1('0x18af')](_0x3ca6d1('0xaf'),{'fields':_0x3ca6d1('0xe26'),'userProfileId':_0x2c6271['getCurrentUser']()['userProfileId'],'sectionId':0xca});}]},'authenticate':!![],'permissionId':0xca,'bodyClass':_0x409e32('0xbea')})[_0x409e32('0x63f')](_0x409e32('0x1e59'),{'url':_0x409e32('0xaa'),'views':{'content@app':{'templateUrl':_0xb32ccc,'controller':_0x409e32('0x3b')}},'resolve':{'telephones':['apiResolver','Auth',function(_0x45cf35,_0x9a16fa){const _0x57e38d=_0x409e32;return _0x9a16fa[_0x57e38d('0x1ac6')](_0x57e38d('0xa7c'))?_0x45cf35[_0x57e38d('0x18af')](_0x57e38d('0x1c80'),{'fields':_0x57e38d('0xd5b'),'role':_0x57e38d('0x887'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x45cf35[_0x57e38d('0x18af')](_0x57e38d('0x17c4'),{'id':_0x9a16fa[_0x57e38d('0x26cd')]()[_0x57e38d('0xb86')],'section':_0x57e38d('0x2323'),'fields':'createdAt,updatedAt,id,role,fullname,name,email,password,description,autointernal,internal,voicemail,transport,nat,allow,callerid,context,callgroup,pickupgroup,videosupport,encryption,phone,mobile','role':_0x57e38d('0x887'),'sort':_0x57e38d('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x409e32('0x1fbc'),_0x409e32('0x21ef'),function(_0x5ac87c,_0x404acc){const _0x3e7969=_0x409e32;return _0x404acc['hasRole'](_0x3e7969('0xa7c'))?null:_0x5ac87c[_0x3e7969('0x18af')](_0x3e7969('0x697'),{'fields':_0x3e7969('0x686'),'id':_0x404acc['getCurrentUser']()[_0x3e7969('0xb86')]});}],'userProfileSection':[_0x409e32('0x1fbc'),_0x409e32('0x21ef'),function(_0x97bead,_0x2f05dd){const _0x1c1049=_0x409e32;return _0x2f05dd[_0x1c1049('0x1ac6')](_0x1c1049('0xa7c'))?null:_0x97bead['resolve'](_0x1c1049('0xaf'),{'fields':_0x1c1049('0xe26'),'userProfileId':_0x2f05dd[_0x1c1049('0x26cd')]()[_0x1c1049('0xb86')],'sectionId':0xcb});}]},'authenticate':!![],'permissionId':0xcb,'bodyClass':_0x409e32('0xbea')})['state'](_0x409e32('0x153c'),{'url':_0x409e32('0x2233'),'params':{'telephone':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0xc747d1,'controller':_0x409e32('0x657')}},'resolve':{'telephone':[_0x409e32('0x1fbc'),'$stateParams',function(_0x538395,_0x31292e){const _0x2b9eeb=_0x409e32;return _0x538395['resolve'](_0x2b9eeb('0x1c80'),{'fields':_0x2b9eeb('0xd5b'),'id':_0x31292e['id']});}],'userProfileSection':['apiResolver','Auth',function(_0x48be9c,_0x57dd22){const _0x470124=_0x409e32;return _0x48be9c[_0x470124('0x18af')]('userProfileSection@get',{'fields':_0x470124('0xe26'),'userProfileId':_0x57dd22['getCurrentUser']()[_0x470124('0xb86')],'sectionId':0xcb});}]},'authenticate':!![],'permissionId':0xcb,'bodyClass':_0x409e32('0xbea')})[_0x409e32('0x63f')](_0x409e32('0x1055'),{'url':_0x409e32('0x1350'),'views':{'content@app':{'templateUrl':_0x1d51e6,'controller':_0x409e32('0x21d7')}},'resolve':{'teams':[_0x409e32('0x1fbc'),_0x409e32('0x21ef'),function(_0xbf64cf,_0x2cc18f){const _0x338460=_0x409e32;return _0x2cc18f[_0x338460('0x1ac6')](_0x338460('0xa7c'))?_0xbf64cf['resolve'](_0x338460('0x1097'),{'fields':_0x338460('0x208e'),'sort':_0x338460('0x14dc'),'limit':0xa,'offset':0x0}):_0xbf64cf['resolve'](_0x338460('0x17c4'),{'id':_0x2cc18f[_0x338460('0x26cd')]()[_0x338460('0xb86')],'section':'Teams','fields':'createdAt,updatedAt,id,name,description','sort':_0x338460('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x409e32('0x1fbc'),_0x409e32('0x21ef'),function(_0x56c23e,_0x23639b){const _0x43b9e0=_0x409e32;return _0x23639b['hasRole'](_0x43b9e0('0xa7c'))?null:_0x56c23e[_0x43b9e0('0x18af')](_0x43b9e0('0x697'),{'fields':_0x43b9e0('0x686'),'id':_0x23639b[_0x43b9e0('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x409e32('0x1fbc'),_0x409e32('0x21ef'),function(_0x58b7a1,_0x347213){const _0x520364=_0x409e32;return _0x347213[_0x520364('0x1ac6')]('admin')?null:_0x58b7a1[_0x520364('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x347213[_0x520364('0x26cd')]()[_0x520364('0xb86')],'sectionId':0xcc});}]},'authenticate':!![],'permissionId':0xcc,'bodyClass':_0x409e32('0xbea')})['state'](_0x409e32('0xf4a'),{'url':_0x409e32('0x8f4'),'views':{'content@app':{'templateUrl':_0x355c64,'controller':'UserProfilesController\x20as\x20vm'}},'resolve':{'userProfiles':[_0x409e32('0x1fbc'),function(_0x1fa292){const _0x518dd7=_0x409e32;return _0x1fa292['resolve'](_0x518dd7('0x697'),{'fields':_0x518dd7('0x7df'),'sort':_0x518dd7('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x409e32('0x1fbc'),_0x409e32('0x21ef'),function(_0x12d2ff,_0x2eca95){const _0xda1e41=_0x409e32;return _0x2eca95['hasRole'](_0xda1e41('0xa7c'))?null:_0x12d2ff[_0xda1e41('0x18af')](_0xda1e41('0x697'),{'fields':_0xda1e41('0x686'),'id':_0x2eca95[_0xda1e41('0x26cd')]()[_0xda1e41('0xb86')]});}],'userProfileSection':['apiResolver','Auth',function(_0x5f1518,_0x2138eb){const _0x39653e=_0x409e32;return _0x2138eb[_0x39653e('0x1ac6')](_0x39653e('0xa7c'))?null:_0x5f1518[_0x39653e('0x18af')](_0x39653e('0xaf'),{'fields':_0x39653e('0xe26'),'userProfileId':_0x2138eb['getCurrentUser']()['userProfileId'],'sectionId':0xcd});}]},'authenticate':!![],'permissionId':0xcd,'bodyClass':_0x409e32('0xbea')})[_0x409e32('0x63f')](_0x409e32('0x24d7'),{'url':_0x409e32('0x2233'),'params':{'userProfile':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x1e6c74,'controller':_0x409e32('0x660')}},'resolve':{'userProfile':[_0x409e32('0x1fbc'),_0x409e32('0xf75'),function(_0x4e1a86,_0x3d8686){const _0x353e3e=_0x409e32;return _0x4e1a86['resolve'](_0x353e3e('0x697'),{'fields':_0x353e3e('0x7df'),'id':_0x3d8686['id']});}],'userProfileSection':['apiResolver',_0x409e32('0x21ef'),function(_0x519535,_0x55d787){const _0x53d5c5=_0x409e32;return _0x519535[_0x53d5c5('0x18af')](_0x53d5c5('0xaf'),{'fields':_0x53d5c5('0xe26'),'userProfileId':_0x55d787[_0x53d5c5('0x26cd')]()[_0x53d5c5('0xb86')],'sectionId':0xcd});}]},'authenticate':!![],'permissionId':0xcd,'bodyClass':_0x409e32('0xbea')}),_0xf0b783[_0x409e32('0x95e')](_0x409e32('0x2118'));}angular[_0x36e6f4('0x896')]('app.staff',[_0x36e6f4('0x441'),'ngPassword','md.data.table',_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),'mdPickers',_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),'angular-cron-jobs',_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411')])[_0x36e6f4('0xe11')](_0x38caec)[_0x36e6f4('0x75e')](_0x36e6f4('0x1c0d'),_0x4b6ee6)[_0x36e6f4('0x75e')]('CreateOrEditAgentDialogController',_0x6f212)[_0x36e6f4('0x75e')]('Agentchange_avatarController',_0x3a0051)[_0x36e6f4('0x75e')](_0x36e6f4('0xc2'),_0x374218)[_0x36e6f4('0x75e')]('AgentPermissionsController',_0x3df295)['controller'](_0x36e6f4('0xf19'),_0x51e10c)['controller'](_0x36e6f4('0xd4b'),_0x3f2d82)[_0x36e6f4('0x75e')](_0x36e6f4('0x9be'),_0xcb840f)[_0x36e6f4('0x75e')](_0x36e6f4('0x1161'),_0xb1ba29)[_0x36e6f4('0x75e')](_0x36e6f4('0x1a6'),_0x2bebe8)[_0x36e6f4('0x75e')]('TeamsController',_0x1220da)[_0x36e6f4('0x75e')](_0x36e6f4('0x516'),_0x94164c)['controller'](_0x36e6f4('0x2024'),_0x389520)[_0x36e6f4('0x75e')](_0x36e6f4('0x42d'),_0x2e9e52)[_0x36e6f4('0x75e')](_0x36e6f4('0x1337'),_0x524483)['controller']('CreateOrEditUserProfileDialogController',_0x48a031)[_0x36e6f4('0x75e')](_0x36e6f4('0x26b8'),_0x3501ca)['controller'](_0x36e6f4('0x27ab'),_0x3a4a8c)['controller'](_0x36e6f4('0xd1'),_0x504cae)[_0x36e6f4('0x75e')](_0x36e6f4('0x13eb'),_0x230307)[_0x36e6f4('0x75e')]('UserProfilesController',_0x589990)['controller'](_0x36e6f4('0x173c'),_0x3d2ef3)[_0x36e6f4('0x75e')](_0x36e6f4('0x106a'),_0x43a409)[_0x36e6f4('0x75e')]('Userchange_avatarController',_0x9c2c35)[_0x36e6f4('0x75e')](_0x36e6f4('0x96d'),_0x5efec4)[_0x36e6f4('0x75e')](_0x36e6f4('0x2715'),_0x8597de)['controller'](_0x36e6f4('0x2366'),_0x426005);const _0xd769fd=_0x2734b2['p']+_0x36e6f4('0xd3f'),_0x1a4aea=_0x2734b2['p']+_0x36e6f4('0x6e');_0x1e0b9c[_0x36e6f4('0x1294')]=['$scope','$document',_0x36e6f4('0x8da'),_0x36e6f4('0x7b9'),_0x36e6f4('0xf75'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0xca8'),_0x36e6f4('0x8de'),_0x36e6f4('0x27ca'),_0x36e6f4('0xfd1'),'companiesMap',_0x36e6f4('0xb38'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9')];function _0x1e0b9c(_0x5644a4,_0x1e72f1,_0x382ea6,_0x2aa098,_0x5c0f4b,_0x51a77b,_0x25e9ed,_0xd98cbd,_0x3ab10e,_0xfee850,_0x175e05,_0x10ba8b,_0x5617dd,_0x5f02ed,_0x1dc0c6,_0x28688a,_0x26de54,_0x52a9d2,_0x1b09ae){const _0x1350b3=_0x36e6f4,_0x15fa77=this;_0x15fa77[_0x1350b3('0x98')]=_0x52a9d2['getCurrentUser'](),_0x15fa77[_0x1350b3('0x5c9')]=_0x1b09ae,_0x15fa77[_0x1350b3('0x7f')]=_0xd98cbd,_0x15fa77[_0x1350b3('0x17aa')]=_0x3ab10e&&_0x3ab10e['count']==0x1?_0x3ab10e[_0x1350b3('0x269a')][0x0]:null,_0x15fa77['crudPermissions']=_0x52a9d2['parseCrudPermissions'](_0x15fa77[_0x1350b3('0x17aa')]?_0x15fa77[_0x1350b3('0x17aa')][_0x1350b3('0x243c')]:null);const _0x1117b8=0x3c,_0x18f742=_0x1117b8*0x400*0x400;_0x15fa77[_0x1350b3('0xd67')]={'target':_0x1350b3('0x105f'),'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x18f742,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x15fa77[_0x1350b3('0xca8')]=_0x175e05||{'count':0x0,'rows':[]},_0x15fa77[_0x1350b3('0xd39')]={'hidden':![],'hover':![],'isOpen':![]},_0x15fa77[_0x1350b3('0x916')]=_0x1350b3('0x18c5'),_0x15fa77[_0x1350b3('0x22ef')]=[],_0x15fa77['lists']=_0x10ba8b||{'rows':[],'count':0x0},_0x15fa77[_0x1350b3('0xfd1')]=_0x5f02ed||{'rows':[],'count':0x0},_0x15fa77['tags']=_0x28688a||{'rows':[],'count':0x0},_0x15fa77[_0x1350b3('0x27ca')]=_0x5617dd,_0x15fa77[_0x1350b3('0x173')]=_0x1dc0c6,_0x15fa77[_0x1350b3('0x1726')]=[],_0x15fa77['selectedList']=null,_0x15fa77[_0x1350b3('0x289b')]=null,_0x15fa77[_0x1350b3('0x2218')]=_0x2cfb05()['merge']({'includeAll':!![],'sort':_0x1350b3('0x14dc'),'limit':0xa,'offset':0x0,'page':0x1},_0x5c0f4b),_0x15fa77[_0x1350b3('0x1f8e')]=_0x38f3dc,_0x15fa77['deleteconfirm']=_0x250722,_0x15fa77[_0x1350b3('0x103b')]=_0x2aa416,_0x15fa77[_0x1350b3('0x2738')]=_0x348bd4,_0x15fa77[_0x1350b3('0xc06')]=_0x4cdede,_0x15fa77[_0x1350b3('0x23f3')]=_0xb23a2,_0x15fa77[_0x1350b3('0x22de')]=_0x1f2356,_0x15fa77[_0x1350b3('0x11bd')]=_0x41c3fd,_0x15fa77[_0x1350b3('0x1c34')]=_0x34fe66,_0x15fa77[_0x1350b3('0x22b6')]=_0x574f24,_0x15fa77[_0x1350b3('0x76a')]=_0x595b3b,_0x15fa77[_0x1350b3('0x1321')]=_0x340ea9,_0x15fa77['selectAllContacts']=_0x1f3297,_0x15fa77[_0x1350b3('0x1096')]=_0x54fdc4,_0x15fa77['createList']=_0x2cc204,_0x15fa77[_0x1350b3('0x743')]=_0x341de7,_0x15fa77[_0x1350b3('0x552')]=_0x335795,_0x15fa77[_0x1350b3('0x1167')]=_0x3ec55c,_0x15fa77[_0x1350b3('0xd20')]=_0x201192;_0x2aa098[_0x1350b3('0x23f')]['ListId']&&(_0x15fa77[_0x1350b3('0x8d5')]=_0x2aa098[_0x1350b3('0x23f')][_0x1350b3('0x23c')]);_0x2aa098[_0x1350b3('0x23f')][_0x1350b3('0x537')]&&(_0x15fa77[_0x1350b3('0x289b')]=_0x2aa098[_0x1350b3('0x23f')][_0x1350b3('0x537')]);_0x5644a4[_0x1350b3('0xe83')](_0x1350b3('0x1f5a'),function(_0x55f6ad){const _0x1cc5bb=_0x1350b3;_0x55f6ad?_0x382ea6(function(){const _0x1f3fe3=a0_0x3f2c;_0x5644a4['tooltipVisible']=_0x15fa77[_0x1f3fe3('0xd39')][_0x1f3fe3('0x1f58')];},0x258):_0x5644a4[_0x1cc5bb('0xd00')]=_0x15fa77[_0x1cc5bb('0xd39')][_0x1cc5bb('0x1f58')];});function _0x4cdede(){const _0x98c8d2=_0x1350b3;if(!_0x52a9d2[_0x98c8d2('0x1ac6')](_0x98c8d2('0xa7c'))){const _0x475397=_0x2cfb05()(_0x15fa77['contacts'][_0x98c8d2('0x269a')])[_0x98c8d2('0x2563')](function(_0x180cc3){const _0x21b1e2=_0x98c8d2;return{'id':_0x180cc3[_0x21b1e2('0x537')]};})[_0x98c8d2('0x1841')]('id')['filter'](function(_0x3d2001){return _0x3d2001['id']&&_0x3d2001['id']>0x0;})['pullAllBy'](_0x15fa77[_0x98c8d2('0xfd1')][_0x98c8d2('0x269a')],'id')[_0x98c8d2('0x18e0')]();if(!_0x2cfb05()[_0x98c8d2('0x1081')](_0x475397)){const _0x5778d7=[];_0x475397[_0x98c8d2('0x2782')](function(_0x12455d){const _0x1e44ea=_0x98c8d2;_0x5778d7[_0x1e44ea('0x1514')](_0xfee850[_0x1e44ea('0xc39')][_0x1e44ea('0xd83')]({'id':_0x12455d['id'],'fields':_0x1e44ea('0x1776')})[_0x1e44ea('0xa44')]);}),_0x25e9ed[_0x98c8d2('0x2760')](_0x5778d7)[_0x98c8d2('0x1166')](function(_0x56d780){const _0x2d5c8d=_0x98c8d2;_0x56d780[_0x2d5c8d('0x2782')](function(_0x500e1d){const _0x136131=_0x2d5c8d,_0x1089a4=_0x500e1d[_0x136131('0x2876')]();_0x1089a4[_0x136131('0x2378')]=![],_0x15fa77[_0x136131('0xfd1')][_0x136131('0x269a')][_0x136131('0x1514')](_0x1089a4);const _0x177085={};_0x177085[_0x1089a4['id']]=_0x1089a4['name'],_0x15fa77['companiesMap']=_0x2cfb05()[_0x136131('0x11f2')](_0x15fa77[_0x136131('0x173')],_0x177085);});})[_0x98c8d2('0x1a80')](function(_0x508a46){const _0x2d84cd=_0x98c8d2;_0x26de54[_0x2d84cd('0xfc9')]({'title':_0x508a46['status']?_0x2d84cd('0x1e21')+_0x508a46[_0x2d84cd('0x52d')]+_0x2d84cd('0x11e1')+_0x508a46[_0x2d84cd('0xe1b')]:_0x2d84cd('0x8a'),'msg':_0x508a46['data']?JSON[_0x2d84cd('0xbac')](_0x508a46['data'][_0x2d84cd('0x1e70')]):_0x508a46[_0x2d84cd('0x1586')]()});});}}}function _0x2cc204(_0x4997e5){const _0x5285d3=_0x1350b3,_0x29ff30=_0x51a77b[_0x5285d3('0x2081')]()[_0x5285d3('0xcdc')](_0x5285d3('0x2001'))['placeholder'](_0x5285d3('0x2612'))[_0x5285d3('0x8e8')](_0x5285d3('0x2612'))[_0x5285d3('0x203b')](_0x4997e5)['ok']('Ok')[_0x5285d3('0x3f')](_0x5285d3('0x497'));return _0x51a77b[_0x5285d3('0x1f80')](_0x29ff30)[_0x5285d3('0x1166')](function(_0x20620c){const _0x40567b=_0x5285d3;if(_0x20620c)return _0xfee850[_0x40567b('0xdd9')][_0x40567b('0x9cc')]({'name':_0x20620c});else _0x26de54[_0x40567b('0xfc9')]({'title':_0x40567b('0x1a71'),'msg':_0x40567b('0x238')});})[_0x5285d3('0x1166')](function(_0x3f7880){const _0x57f9f5=_0x5285d3;_0x3f7880&&(_0x15fa77[_0x57f9f5('0x8de')][_0x57f9f5('0x269a')][_0x57f9f5('0x1514')](_0x3f7880),_0x26de54[_0x57f9f5('0x103b')]({'title':_0x57f9f5('0x868'),'msg':_0x3f7880[_0x57f9f5('0x4f0')]?_0x3f7880[_0x57f9f5('0x4f0')]+_0x57f9f5('0x1eda'):''}));});}function _0x3ec55c(){return _0x52a9d2['hasPermission'](0x12f)||_0x52a9d2['hasRole']('admin');}function _0x341de7(_0x106722){const _0x921428=_0x1350b3,_0x2b9a27=_0x51a77b[_0x921428('0x2081')]()[_0x921428('0xcdc')](_0x921428('0x1030'))[_0x921428('0xc5c')]('Company\x20name')[_0x921428('0x8e8')](_0x921428('0x6f8'))[_0x921428('0x203b')](_0x106722)['ok']('Ok')[_0x921428('0x3f')](_0x921428('0x497'));return _0x51a77b[_0x921428('0x1f80')](_0x2b9a27)['then'](function(_0x509234){const _0x45567d=_0x921428;if(_0x509234)return _0xfee850[_0x45567d('0xc39')][_0x45567d('0x9cc')]({'name':_0x509234});else _0x26de54['error']({'title':_0x45567d('0x94'),'msg':_0x45567d('0xc8d')});})[_0x921428('0x1166')](function(_0x3b47ec){const _0x2b6b2d=_0x921428;_0x3b47ec&&(_0x15fa77[_0x2b6b2d('0xfd1')][_0x2b6b2d('0x269a')][_0x2b6b2d('0x1514')](_0x3b47ec),_0x26de54[_0x2b6b2d('0x103b')]({'title':_0x2b6b2d('0x1c3e'),'msg':_0x3b47ec[_0x2b6b2d('0x4f0')]?_0x3b47ec[_0x2b6b2d('0x4f0')]+'\x20has\x20been\x20created!':''}));});}function _0x54fdc4(_0x575bb2){const _0x5b1421=_0x1350b3,_0x28a3f7=_0x51a77b[_0x5b1421('0x2081')]()[_0x5b1421('0xcdc')]('What\x20would\x20you\x20name\x20your\x20tag?')[_0x5b1421('0xc5c')](_0x5b1421('0x89a'))[_0x5b1421('0x8e8')](_0x5b1421('0x89a'))[_0x5b1421('0x203b')](_0x575bb2)['ok']('Ok')['cancel'](_0x5b1421('0x497'));return _0x51a77b[_0x5b1421('0x1f80')](_0x28a3f7)[_0x5b1421('0x1166')](function(_0x40449d){const _0x3525a0=_0x5b1421;if(_0x40449d)return _0xfee850[_0x3525a0('0x1446')][_0x3525a0('0x9cc')]({'name':_0x40449d});else _0x26de54[_0x3525a0('0xfc9')]({'title':_0x3525a0('0x25a5'),'msg':'Invalid\x20tag\x20name.'});})['then'](function(_0x38e614){const _0x57d191=_0x5b1421;_0x38e614&&(_0x15fa77[_0x57d191('0xb38')][_0x57d191('0x269a')][_0x57d191('0x1514')](_0x38e614),_0x26de54[_0x57d191('0x103b')]({'title':_0x57d191('0x1415'),'msg':_0x38e614[_0x57d191('0x1446')]?_0x38e614[_0x57d191('0x4f0')]+'\x20has\x20been\x20created!':''}));});}function _0x335795(_0xffa52a,_0x444c01){const _0x444351=_0x1350b3,_0x2efff5=JSON['parse'](_0x444c01);_0x51a77b[_0x444351('0x1f80')]({'controller':_0x444351('0x15cd'),'controllerAs':'vm','templateUrl':_0xd769fd,'parent':angular[_0x444351('0x1194')](_0x1e72f1[_0x444351('0x8d2')]),'clickOutsideToClose':![],'locals':{'lists':_0x10ba8b,'companies':_0x5f02ed,'file':_0x2efff5[_0x444351('0x6bd')],'fields':_0x2efff5[_0x444351('0xfe2')],'license':_0x15fa77[_0x444351('0x5c9')]}})['then'](function(){const _0x20190b=_0x444351;_0x15fa77[_0x20190b('0x2738')]();})[_0x444351('0x1a80')](function(){const _0x377f3a=_0x444351;console[_0x377f3a('0xfc9')]();});}function _0x38f3dc(_0x255304){const _0x43a21f=_0x1350b3;_0x2aa098['go'](_0x43a21f('0x1e16'),{'id':_0x255304['id'],'crudPermissions':_0x15fa77[_0x43a21f('0x243c')]});}function _0x250722(_0x23ae3c,_0x5cf335){const _0x5cd094=_0x1350b3,_0x303a25=_0x51a77b[_0x5cd094('0x1d26')]()[_0x5cd094('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20contact?')[_0x5cd094('0xf3c')](_0x5cd094('0x12b5')+(_0x23ae3c[_0x5cd094('0x18cb')]||_0x23ae3c[_0x5cd094('0x66f')]||_0x23ae3c[_0x5cd094('0x2026')]||_0x5cd094('0x21a4'))+_0x5cd094('0xace')+_0x5cd094('0x3f3'))[_0x5cd094('0x8e8')](_0x5cd094('0x2889'))[_0x5cd094('0x203b')](_0x5cf335)['ok']('OK')[_0x5cd094('0x3f')](_0x5cd094('0x2d3'));_0x51a77b['show'](_0x303a25)[_0x5cd094('0x1166')](function(){_0x34fe66(_0x23ae3c);});}function _0x201192(_0x235725){const _0x5178ec=_0x1350b3,_0x4c0a12=[_0x5178ec('0x2702')];if(!_0x2cfb05()[_0x5178ec('0x1257')](_0x4c0a12,_0x235725[_0x5178ec('0x26a5')]()))return _0x26de54['error']({'title':_0x5178ec('0x27fb')+_0x235725['getExtension'](),'msg':_0x5178ec('0x1020')+_0x4c0a12[_0x5178ec('0x45a')]()}),![];if(_0x235725[_0x5178ec('0x2340')]>_0x18f742)return _0x26de54['error']({'title':'File\x20too\x20big','msg':'The\x20max\x20allowed\x20size\x20is\x20'+_0x1117b8+'MB'}),![];return!![];}let _0x142ae7=!![],_0x567408=0x1;_0x5644a4[_0x1350b3('0xe83')](_0x1350b3('0x12d8'),function(_0x16ef22,_0x591d8c){const _0x58933d=_0x1350b3;_0x142ae7?_0x382ea6(function(){_0x142ae7=![];}):(!_0x591d8c&&(_0x567408=_0x15fa77[_0x58933d('0x2218')][_0x58933d('0x1a43')]),_0x16ef22!==_0x591d8c&&(_0x15fa77[_0x58933d('0x2218')][_0x58933d('0x1a43')]=0x1),!_0x16ef22&&(_0x15fa77[_0x58933d('0x2218')]['page']=_0x567408),_0x15fa77[_0x58933d('0x2738')]());},!![]),_0x5644a4[_0x1350b3('0xe83')](_0x1350b3('0x20cd'),function(_0x4c1f8c,_0x5e7af1){const _0x50d392=_0x1350b3;_0x4c1f8c!==_0x5e7af1&&(_0x15fa77['query'][_0x50d392('0x23c')]=_0x15fa77[_0x50d392('0x8d5')]||undefined,_0x15fa77[_0x50d392('0x2738')]());}),_0x5644a4[_0x1350b3('0xe83')](_0x1350b3('0x230c'),function(_0x342239,_0x5d5e4b){const _0x52481d=_0x1350b3;_0x342239!==_0x5d5e4b&&(_0x15fa77[_0x52481d('0x2218')][_0x52481d('0x537')]=_0x15fa77[_0x52481d('0x289b')]||undefined,_0x15fa77[_0x52481d('0x2738')]());}),_0x5644a4[_0x1350b3('0xe83')](_0x1350b3('0x74d'),function(_0x603c0d,_0x485e39){const _0x420a43=_0x1350b3;(_0x603c0d['length']||_0x485e39['length'])&&_0x15fa77[_0x420a43('0x2738')]();});function _0x2aa416(_0x15004e){_0x15fa77['contacts']=_0x15004e||{'count':0x0,'rows':[]};}function _0x348bd4(){const _0x4902ed=_0x1350b3;_0x15fa77[_0x4902ed('0x2218')][_0x4902ed('0x1098')]=(_0x15fa77[_0x4902ed('0x2218')][_0x4902ed('0x1a43')]-0x1)*_0x15fa77[_0x4902ed('0x2218')]['limit'],_0x52a9d2[_0x4902ed('0x1ac6')](_0x4902ed('0xa7c'))?_0x15fa77[_0x4902ed('0x1f48')]=_0xfee850[_0x4902ed('0x149e')][_0x4902ed('0xd83')](_0x15fa77[_0x4902ed('0x2218')],_0x2aa416)[_0x4902ed('0xa44')]:(_0x15fa77[_0x4902ed('0x2218')]['id']=_0x15fa77[_0x4902ed('0x7f')]['id'],_0x15fa77['query'][_0x4902ed('0x23c')]=!_0x15fa77[_0x4902ed('0x2218')][_0x4902ed('0x23c')]?_0x2cfb05()[_0x4902ed('0x2563')](_0x15fa77[_0x4902ed('0x8de')][_0x4902ed('0x269a')],'id'):_0x15fa77['query'][_0x4902ed('0x23c')],_0x15fa77[_0x4902ed('0x2218')][_0x4902ed('0x537')]=!_0x15fa77[_0x4902ed('0x2218')]['CompanyId']?_0x2cfb05()(_0x15fa77[_0x4902ed('0xfd1')][_0x4902ed('0x269a')])[_0x4902ed('0x1c33')]({'canSelect':undefined})[_0x4902ed('0x2563')]('id')[_0x4902ed('0x18e0')]():_0x15fa77[_0x4902ed('0x2218')]['CompanyId'],_0x15fa77[_0x4902ed('0x2218')][_0x4902ed('0xe60')]=_0x4902ed('0x2326'),_0x15fa77[_0x4902ed('0x1f48')]=_0xfee850[_0x4902ed('0x7f')][_0x4902ed('0x263a')](_0x15fa77[_0x4902ed('0x2218')],_0x2aa416)[_0x4902ed('0xa44')]);}function _0x41c3fd(_0x41724c,_0x63937f){const _0x481d59=_0x1350b3;_0x63937f&&_0x63937f[_0x481d59('0x17a0')]&&(_0x63937f[_0x481d59('0x17a0')]=new Date(_0x63937f[_0x481d59('0x17a0')])),_0x51a77b[_0x481d59('0x1f80')]({'controller':'CreateOrEditContactDialogController','controllerAs':'vm','templateUrl':_0x1a4aea,'parent':angular['element'](_0x1e72f1[_0x481d59('0x8d2')]),'targetEvent':_0x41724c,'clickOutsideToClose':!![],'locals':{'ListId':_0x15fa77[_0x481d59('0x2218')]['ListId']||_0x2aa098['params'][_0x481d59('0x23c')],'CompanyId':_0x15fa77[_0x481d59('0x2218')][_0x481d59('0x537')]||_0x2aa098[_0x481d59('0x23f')][_0x481d59('0x537')],'contact':_0x63937f,'contacts':_0x15fa77[_0x481d59('0xca8')][_0x481d59('0x269a')],'companies':_0x15fa77['companies'],'lists':_0x15fa77['lists'],'setting':null,'crudPermissions':_0x15fa77['crudPermissions']}});}function _0x1f2356(_0x113f39,_0x1428dd){const _0x3b0679=_0x1350b3;_0x51a77b[_0x3b0679('0x1f80')]({'controller':_0x3b0679('0x15ad'),'controllerAs':'vm','templateUrl':_0x5b62a4,'parent':angular[_0x3b0679('0x1194')](_0x1e72f1[_0x3b0679('0x8d2')]),'targetEvent':_0x113f39,'clickOutsideToClose':!![],'resolve':{'contact':[_0x3b0679('0x1fbc'),function(_0x567ebd){return _0x567ebd['resolve']('cmContact@get',{'id':_0x1428dd['id']});}],'lists':['apiResolver',_0x3b0679('0x21ef'),function(_0x57facd,_0x24f38a){const _0x4c32fc=_0x3b0679;return _0x24f38a[_0x4c32fc('0x1ac6')](_0x4c32fc('0xa7c'))?_0x57facd[_0x4c32fc('0x18af')](_0x4c32fc('0x4ee'),{'fields':'id,name','nolimit':!![]}):_0x57facd['resolve'](_0x4c32fc('0x17c4'),{'id':_0x24f38a[_0x4c32fc('0x26cd')]()[_0x4c32fc('0xb86')],'section':'Lists','fields':_0x4c32fc('0x1776'),'nolimit':!![]});}]},'locals':{'contacts':_0x15fa77[_0x3b0679('0xca8')][_0x3b0679('0x269a')]}});}function _0xb23a2(_0x37cf35,_0x1a37e4){const _0x58d3be=_0x1350b3;_0x51a77b[_0x58d3be('0x1f80')]({'controller':_0x58d3be('0xcd1'),'controllerAs':'vm','templateUrl':_0x18c924,'parent':angular[_0x58d3be('0x1194')](_0x1e72f1[_0x58d3be('0x8d2')]),'targetEvent':_0x37cf35,'clickOutsideToClose':!![],'resolve':{'contact':[_0x58d3be('0x1fbc'),function(_0x423ffe){const _0x53d57b=_0x58d3be;return _0x423ffe[_0x53d57b('0x18af')](_0x53d57b('0x111c'),{'id':_0x1a37e4['id']});}],'lists':['apiResolver',_0x58d3be('0x21ef'),function(_0x3a4847,_0x1faf34){const _0x2ad650=_0x58d3be;return _0x1faf34[_0x2ad650('0x1ac6')](_0x2ad650('0xa7c'))?_0x3a4847['resolve']('cmList@get',{'fields':_0x2ad650('0x1776'),'nolimit':!![]}):_0x3a4847[_0x2ad650('0x18af')]('userProfile@getResources',{'id':_0x1faf34[_0x2ad650('0x26cd')]()[_0x2ad650('0xb86')],'section':_0x2ad650('0x1cae'),'fields':_0x2ad650('0x1776'),'nolimit':!![]});}]},'locals':{'contacts':_0x15fa77[_0x58d3be('0xca8')][_0x58d3be('0x269a')]}});}function _0x34fe66(_0x1edb70){const _0x1c808e=_0x1350b3;_0xfee850[_0x1c808e('0x149e')]['delete']({'id':_0x1edb70['id']})[_0x1c808e('0xa44')][_0x1c808e('0x1166')](function(){const _0x50738c=_0x1c808e;_0x2cfb05()[_0x50738c('0x127f')](_0x15fa77[_0x50738c('0xca8')]['rows'],{'id':_0x1edb70['id']}),_0x15fa77[_0x50738c('0xca8')][_0x50738c('0x240f')]-=0x1,!_0x15fa77[_0x50738c('0xca8')][_0x50738c('0x269a')]['length']&&_0x15fa77[_0x50738c('0x2738')](),_0x26de54['success']({'title':_0x50738c('0x548'),'msg':_0x1edb70[_0x50738c('0x4f0')]?_0x1edb70[_0x50738c('0x4f0')]+_0x50738c('0x7cd'):''});})[_0x1c808e('0x1a80')](function(_0x285c25){const _0x34af68=_0x1c808e;if(_0x285c25[_0x34af68('0x25f4')]&&_0x285c25[_0x34af68('0x25f4')][_0x34af68('0x61a')]&&_0x285c25[_0x34af68('0x25f4')][_0x34af68('0x61a')][_0x34af68('0x264b')]){_0x15fa77[_0x34af68('0x61a')]=_0x285c25['data'][_0x34af68('0x61a')]||[{'message':_0x285c25[_0x34af68('0x1586')](),'type':_0x34af68('0x2718')}];for(let _0x959c72=0x0;_0x959c72<_0x285c25['data'][_0x34af68('0x61a')][_0x34af68('0x264b')];_0x959c72++){_0x26de54[_0x34af68('0xfc9')]({'title':_0x285c25[_0x34af68('0x25f4')][_0x34af68('0x61a')][_0x959c72][_0x34af68('0x1345')],'msg':_0x285c25['data'][_0x34af68('0x61a')][_0x959c72][_0x34af68('0x1e70')]});}}else _0x26de54[_0x34af68('0xfc9')]({'title':_0x285c25[_0x34af68('0x52d')]?_0x34af68('0x1e21')+_0x285c25[_0x34af68('0x52d')]+_0x34af68('0x11e1')+_0x285c25[_0x34af68('0xe1b')]:'api.contact.delete','msg':_0x285c25[_0x34af68('0x25f4')]?JSON[_0x34af68('0xbac')](_0x285c25['data'][_0x34af68('0x1e70')]):_0x285c25[_0x34af68('0x1e70')]||_0x285c25[_0x34af68('0x1586')]()});});}function _0x574f24(){const _0x190785=_0x1350b3,_0x52dcfc=angular[_0x190785('0x225f')](_0x15fa77[_0x190785('0x22ef')]);return _0x15fa77[_0x190785('0x22ef')]=[],_0x52dcfc;}function _0x595b3b(_0x1fd3de){const _0x4c60d8=_0x1350b3,_0x300c77=_0x51a77b['confirm']()[_0x4c60d8('0xcdc')](_0x4c60d8('0x258a'))[_0x4c60d8('0xf3c')](_0x4c60d8('0x12b5')+_0x15fa77['selectedContacts'][_0x4c60d8('0x264b')]+_0x4c60d8('0x196d')+'\x20will\x20be\x20deleted.')[_0x4c60d8('0x8e8')](_0x4c60d8('0xfdc'))[_0x4c60d8('0x203b')](_0x1fd3de)['ok']('OK')[_0x4c60d8('0x3f')](_0x4c60d8('0x2d3'));_0x51a77b[_0x4c60d8('0x1f80')](_0x300c77)[_0x4c60d8('0x1166')](function(){const _0x301706=_0x4c60d8;_0x15fa77[_0x301706('0x22ef')][_0x301706('0x2782')](function(_0x320bfd){_0x34fe66(_0x320bfd);}),_0x15fa77[_0x301706('0x22ef')]=[];});}function _0x340ea9(){const _0x39d24e=_0x1350b3;_0x15fa77[_0x39d24e('0x22ef')]=[];}function _0x1f3297(){const _0x484cfe=_0x1350b3;_0x15fa77[_0x484cfe('0x22ef')]=_0x15fa77[_0x484cfe('0xca8')][_0x484cfe('0x269a')];}}const _0x4293ed=_0x1e0b9c;_0xf470fc[_0x36e6f4('0x1294')]=['$mdDialog',_0x36e6f4('0x1d2e'),_0x36e6f4('0xca8'),_0x36e6f4('0x8de'),'companies','contact','ListId',_0x36e6f4('0x537'),_0x36e6f4('0x19e3'),_0x36e6f4('0x243c')];function _0xf470fc(_0x185a67,_0x523661,_0x80b7cb,_0x4ebdef,_0x27832e,_0x4cc187,_0x4da683,_0x442be9,_0x43ee0a,_0x5516ae){const _0x1cdb37=_0x36e6f4,_0x875881=this;_0x875881['errors']=[],_0x875881[_0x1cdb37('0xcdc')]=_0x1cdb37('0x2498'),_0x875881['crudPermissions']=_0x5516ae,_0x875881['contact']=angular[_0x1cdb37('0x225f')](_0x4cc187),_0x875881[_0x1cdb37('0xca8')]=_0x80b7cb||{'rows':[],'count':0x0},_0x875881['lists']=_0x4ebdef||{'rows':[],'count':0x0},_0x875881[_0x1cdb37('0xfd1')]=_0x27832e||{'rows':[],'count':0x0},_0x875881[_0x1cdb37('0x23d7')]={'rows':[],'count':0x0},_0x875881[_0x1cdb37('0x1018')]=![];!_0x875881[_0x1cdb37('0x26db')]?(_0x875881[_0x1cdb37('0x26db')]={'ListId':_0x4da683?parseInt(_0x4da683,0xa):undefined,'CompanyId':_0x442be9?parseInt(_0x442be9,0xa):undefined},_0x875881[_0x1cdb37('0xcdc')]=_0x1cdb37('0x1966'),_0x875881[_0x1cdb37('0x1018')]=!![]):(delete _0x875881[_0x1cdb37('0x26db')]['List'],_0x875881[_0x1cdb37('0x23c')]=_0x875881[_0x1cdb37('0x26db')][_0x1cdb37('0x23c')]||undefined);_0x875881[_0x1cdb37('0xf58')]=_0x4edad7,_0x875881[_0x1cdb37('0x1aae')]=_0x1e0b1c,_0x875881[_0x1cdb37('0x1c34')]=_0x28eba8,_0x875881[_0x1cdb37('0x24a0')]=_0x43c8d4,_0x875881['getCustomFields']=_0x2ea074,_0x875881['getDateFromString']=_0x28b8c2;function _0x4edad7(){const _0x2ef24b=_0x1cdb37;_0x875881[_0x2ef24b('0x61a')]=[],_0x43ee0a[_0x2ef24b('0x149e')][_0x2ef24b('0x9cc')](_0x875881[_0x2ef24b('0x26db')])['$promise'][_0x2ef24b('0x1166')](function(_0x45d82a){const _0x10f24e=_0x2ef24b;_0x875881[_0x10f24e('0xca8')][_0x10f24e('0x2450')](_0x45d82a),_0x523661['success']({'title':'Contact\x20properly\x20created','msg':_0x875881[_0x10f24e('0x26db')][_0x10f24e('0x4f0')]?_0x875881['contact']['name']+_0x10f24e('0x1eda'):''}),_0x43c8d4();})[_0x2ef24b('0x1a80')](function(_0x140e6c){const _0xa71f16=_0x2ef24b;if(_0x140e6c[_0xa71f16('0x25f4')]&&_0x140e6c['data'][_0xa71f16('0x61a')]&&_0x140e6c[_0xa71f16('0x25f4')]['errors'][_0xa71f16('0x264b')]){_0x875881['errors']=_0x140e6c[_0xa71f16('0x25f4')]['errors']||[{'message':_0x140e6c['toString'](),'type':_0xa71f16('0xe5d')}];for(let _0x185cbb=0x0;_0x185cbb<_0x140e6c[_0xa71f16('0x25f4')]['errors'][_0xa71f16('0x264b')];_0x185cbb++){_0x523661[_0xa71f16('0xfc9')]({'title':_0x140e6c['data'][_0xa71f16('0x61a')][_0x185cbb][_0xa71f16('0x1345')],'msg':_0x140e6c['data'][_0xa71f16('0x61a')][_0x185cbb][_0xa71f16('0x1e70')]});}}else _0x523661[_0xa71f16('0xfc9')]({'title':_0x140e6c[_0xa71f16('0x52d')]?_0xa71f16('0x1e21')+_0x140e6c[_0xa71f16('0x52d')]+'\x20-\x20'+_0x140e6c[_0xa71f16('0xe1b')]:'api.contacts.save','msg':_0x140e6c['data']?JSON[_0xa71f16('0xbac')](_0x140e6c['data'][_0xa71f16('0x1e70')]):_0x140e6c['toString']()});});}function _0x1e0b1c(){const _0x1b0b39=_0x1cdb37;_0x875881[_0x1b0b39('0x61a')]=[],_0x43ee0a[_0x1b0b39('0x149e')][_0x1b0b39('0x1449')]({'id':_0x875881['contact']['id']},_0x875881['contact'])[_0x1b0b39('0xa44')]['then'](function(_0x1a99b0){const _0x45a60b=_0x1b0b39,_0x552004=_0x2cfb05()[_0x45a60b('0xc38')](_0x875881[_0x45a60b('0xca8')],{'id':_0x1a99b0['id']});_0x552004&&_0x2cfb05()[_0x45a60b('0xcc3')](_0x552004,_0x1a99b0),_0x523661[_0x45a60b('0x103b')]({'title':_0x45a60b('0xf5d'),'msg':_0x875881[_0x45a60b('0x26db')][_0x45a60b('0x4f0')]?_0x875881[_0x45a60b('0x26db')]['name']+_0x45a60b('0x7d'):''}),_0x43c8d4();})[_0x1b0b39('0x1a80')](function(_0x48a673){const _0x4706e3=_0x1b0b39;if(_0x48a673['data']&&_0x48a673[_0x4706e3('0x25f4')][_0x4706e3('0x61a')]&&_0x48a673[_0x4706e3('0x25f4')][_0x4706e3('0x61a')][_0x4706e3('0x264b')]){_0x875881[_0x4706e3('0x61a')]=_0x48a673[_0x4706e3('0x25f4')][_0x4706e3('0x61a')]||[{'message':_0x48a673[_0x4706e3('0x1586')](),'type':_0x4706e3('0x163')}];for(let _0x1d730c=0x0;_0x1d730c<_0x48a673[_0x4706e3('0x25f4')]['errors'][_0x4706e3('0x264b')];_0x1d730c++){_0x523661[_0x4706e3('0xfc9')]({'title':_0x48a673[_0x4706e3('0x25f4')][_0x4706e3('0x61a')][_0x1d730c][_0x4706e3('0x1345')],'msg':_0x48a673['data'][_0x4706e3('0x61a')][_0x1d730c]['message']});}}else _0x523661[_0x4706e3('0xfc9')]({'title':_0x48a673[_0x4706e3('0x52d')]?'API:'+_0x48a673[_0x4706e3('0x52d')]+_0x4706e3('0x11e1')+_0x48a673[_0x4706e3('0xe1b')]:_0x4706e3('0x163'),'msg':_0x48a673[_0x4706e3('0x25f4')]?JSON[_0x4706e3('0xbac')](_0x48a673[_0x4706e3('0x25f4')]['message']):_0x48a673[_0x4706e3('0x1586')]()});});}function _0x2ea074(_0x101a06){const _0x317c8f=_0x1cdb37;if(_0x101a06)return _0x43ee0a['cmList'][_0x317c8f('0x1bb')]({'id':_0x101a06})['$promise']['then'](function(_0x4fc175){const _0x8fefd5=_0x317c8f;if(_0x4fc175){_0x875881[_0x8fefd5('0x23d7')]=_0x4fc175;const _0xce0b99=_0x2cfb05()[_0x8fefd5('0x2563')](_0x875881[_0x8fefd5('0x23d7')][_0x8fefd5('0x269a')],function(_0x4a180d){const _0x3de1f0=_0x8fefd5;return _0x3de1f0('0x711')+_0x4a180d['id'];});_0x43ee0a['cmContact'][_0x8fefd5('0xd83')]({'id':_0x875881[_0x8fefd5('0x26db')]['id'],'attributes':_0xce0b99,'raw':!![]})[_0x8fefd5('0xa44')]['then'](function(_0x33b97e){const _0x2e7bd1=_0x8fefd5;_0x875881['contact']=_0x2cfb05()[_0x2e7bd1('0xcc3')](_0x875881[_0x2e7bd1('0x26db')],_0x33b97e);});}})[_0x317c8f('0x1a80')](function(_0x58874f){const _0x41f448=_0x317c8f;console[_0x41f448('0xfc9')](_0x58874f);});else _0x875881[_0x317c8f('0x23d7')]={'rows':[],'count':0x0};}function _0x28eba8(_0x2215a1){const _0x4ac644=_0x1cdb37;_0x875881[_0x4ac644('0x61a')]=[];const _0x37bead=_0x185a67[_0x4ac644('0x1d26')]()[_0x4ac644('0xcdc')](_0x4ac644('0x7fb'))[_0x4ac644('0xacc')](_0x4ac644('0x1521'))[_0x4ac644('0x8e8')](_0x4ac644('0x1e7'))['ok'](_0x4ac644('0x18'))[_0x4ac644('0x3f')](_0x4ac644('0x497'))[_0x4ac644('0x203b')](_0x2215a1);_0x185a67['show'](_0x37bead)['then'](function(){const _0x5521e7=_0x4ac644;_0x43ee0a[_0x5521e7('0x149e')][_0x5521e7('0x906')]({'id':_0x875881[_0x5521e7('0x26db')]['id']})['$promise'][_0x5521e7('0x1166')](function(){const _0x21d435=_0x5521e7;_0x2cfb05()[_0x21d435('0x127f')](_0x875881[_0x21d435('0xca8')],{'id':_0x875881[_0x21d435('0x26db')]['id']}),_0x523661[_0x21d435('0x103b')]({'title':'Contact\x20properly\x20deleted!','msg':_0x875881['contact'][_0x21d435('0x4f0')]?_0x875881[_0x21d435('0x26db')]['name']+_0x21d435('0x7cd'):''}),_0x43c8d4();})[_0x5521e7('0x1a80')](function(_0x5ca8a9){const _0x12ee7d=_0x5521e7;console[_0x12ee7d('0xfc9')](_0x5ca8a9),_0x875881['errors']=_0x5ca8a9[_0x12ee7d('0x25f4')]['errors']||[{'message':_0x5ca8a9[_0x12ee7d('0x1586')](),'type':_0x12ee7d('0x2718')}];});},function(){});}function _0x28b8c2(_0xca0639){return _0xca0639===null?undefined:new Date(_0xca0639);}function _0x43c8d4(){const _0x451b35=_0x1cdb37;_0x185a67[_0x451b35('0x1197')]();}}const _0x3f37f8=_0xf470fc;_0xc4f209[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x26db'),_0x36e6f4('0xca8'),_0x36e6f4('0x8de'),_0x36e6f4('0x19e3')];function _0xc4f209(_0x574388,_0x5e842e,_0xcfce04,_0x1c6503,_0x5be17d,_0x4d8ca1){const _0x122c3e=_0x36e6f4,_0x41bbce=this;_0x41bbce[_0x122c3e('0x61a')]=[],_0x41bbce['title']=_0x122c3e('0x1178'),_0x41bbce[_0x122c3e('0x26db')]=angular['copy'](_0xcfce04),_0x41bbce[_0x122c3e('0x8de')]=_0x5be17d||{'rows':[],'count':0x0},_0x41bbce['addNewContact']=_0x26ecd4,_0x41bbce['closeDialog']=_0x5e94cf;function _0x26ecd4(){const _0x230448=_0x122c3e;_0x41bbce['errors']=[],delete _0x41bbce[_0x230448('0x26db')]['id'],_0x41bbce['contact'][_0x230448('0xb38')]&&!_0x41bbce[_0x230448('0x26db')][_0x230448('0xb38')]['length']&&delete _0x41bbce[_0x230448('0x26db')][_0x230448('0xb38')],_0x4d8ca1[_0x230448('0x149e')]['save'](_0x41bbce[_0x230448('0x26db')])[_0x230448('0xa44')]['then'](function(_0x4d8a61){const _0x113bc1=_0x230448;_0x1c6503[_0x113bc1('0x2450')](_0x4d8a61),_0x5e842e[_0x113bc1('0x103b')]({'title':_0x113bc1('0x254d'),'msg':_0x41bbce['contact'][_0x113bc1('0x4f0')]?_0x41bbce['contact'][_0x113bc1('0x4f0')]+_0x113bc1('0x1eda'):''}),_0x5e94cf();})['catch'](function(_0x5c8f28){const _0x59c0ca=_0x230448;console['error'](_0x5c8f28),_0x41bbce[_0x59c0ca('0x61a')]=_0x5c8f28[_0x59c0ca('0x25f4')]['errors']||[{'message':_0x5c8f28[_0x59c0ca('0x1586')](),'type':_0x59c0ca('0x257f')}];});}function _0x5e94cf(){const _0x3a88b0=_0x122c3e;_0x574388[_0x3a88b0('0x1197')]();}}const _0x25d149=_0xc4f209;_0x4879ce[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'toasty',_0x36e6f4('0x28c4'),'hopper',_0x36e6f4('0x19e3'),_0x36e6f4('0x243c')];function _0x4879ce(_0x220659,_0x3a2bd3,_0x18da88,_0x3680e2,_0x46c5fd,_0x2453df,_0x32542b,_0x5b27a5,_0x2192b6){const _0x3570ad=_0x36e6f4,_0x1b004b=this;_0x1b004b[_0x3570ad('0x61a')]=[],_0x1b004b[_0x3570ad('0xcdc')]=_0x3570ad('0x1a0d'),_0x1b004b[_0x3570ad('0x1d98')]=angular[_0x3570ad('0x225f')](_0x32542b),_0x1b004b[_0x3570ad('0x28c4')]=_0x2453df,_0x1b004b[_0x3570ad('0x1e01')]=![],_0x1b004b['crudPermissions']=_0x2192b6;!_0x1b004b['hopper']&&(_0x1b004b[_0x3570ad('0x1d98')]={},_0x1b004b['title']=_0x3570ad('0xd9e'),_0x1b004b['newHopper']=!![]);_0x1b004b['saveHopper']=_0x1743f9,_0x1b004b['getDateFromString']=_0x18aa84,_0x1b004b['closeDialog']=_0x2921a6;function _0x1743f9(){const _0x2c1989=_0x3570ad;_0x1b004b['errors']=[],_0x5b27a5['cmHopper'][_0x2c1989('0x1449')]({'id':_0x1b004b[_0x2c1989('0x1d98')]['id']},_0x1b004b[_0x2c1989('0x1d98')])[_0x2c1989('0xa44')][_0x2c1989('0x1166')](function(_0x24bc41){const _0x5597de=_0x2c1989,_0x43bce9=_0x2cfb05()[_0x5597de('0xc38')](_0x1b004b[_0x5597de('0x28c4')],{'id':_0x24bc41['id']});_0x43bce9&&_0x2cfb05()[_0x5597de('0xcc3')](_0x43bce9,_0x24bc41),_0x46c5fd[_0x5597de('0x103b')]({'title':_0x5597de('0x108f'),'msg':_0x1b004b[_0x5597de('0x1d98')][_0x5597de('0x4f0')]?_0x1b004b['hopper'][_0x5597de('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x2921a6(_0x24bc41);})[_0x2c1989('0x1a80')](function(_0x52c58f){const _0x2e20ea=_0x2c1989;console['error'](_0x52c58f),_0x1b004b[_0x2e20ea('0x61a')]=_0x52c58f['data'][_0x2e20ea('0x61a')]||[{'message':_0x52c58f[_0x2e20ea('0x1586')](),'type':_0x2e20ea('0xd28')}];});}function _0x18aa84(_0x2a356a){return _0x2a356a===null?undefined:new Date(_0x2a356a);}function _0x2921a6(_0x2d94ad){const _0x17666b=_0x3570ad;_0x3680e2[_0x17666b('0x1197')](_0x2d94ad);}}const _0x43171b=_0x4879ce,_0x24ef4f=_0x2734b2['p']+_0x36e6f4('0x1924');_0x4fefc6[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$timeout','$state',_0x36e6f4('0x1c90'),_0x36e6f4('0x265d'),_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x26db'),_0x36e6f4('0x28c4'),_0x36e6f4('0x17d9'),'histories',_0x36e6f4('0xca8'),'companies',_0x36e6f4('0x8de'),_0x36e6f4('0x23d7'),_0x36e6f4('0xb38'),_0x36e6f4('0x1010'),_0x36e6f4('0x5c9'),_0x36e6f4('0x21ef'),'userProfileSection'];function _0x4fefc6(_0x4e3ec8,_0x58efaa,_0x429c26,_0x3a4eea,_0x4c36f4,_0x59f162,_0x5cdec1,_0x93ec4b,_0xa7e9ba,_0x4ebbd4,_0x3578fe,_0x388a1b,_0x4312aa,_0x298737,_0x3c96a0,_0x173354,_0x4ce450,_0x297f02,_0x52a46e,_0x696e46,_0x59c7ec){const _0x1b8d10=_0x36e6f4,_0x2cd397=this;_0x2cd397['currentUser']=_0x696e46[_0x1b8d10('0x26cd')](),_0x2cd397[_0x1b8d10('0x5c9')]=_0x52a46e,_0x2cd397[_0x1b8d10('0x227e')]=[],_0x2cd397[_0x1b8d10('0x26db')]=_0xa7e9ba||{},_0x2cd397['hoppers']=_0x4ebbd4||{'rows':[],'count':0x0},_0x2cd397[_0x1b8d10('0x17d9')]=_0x3578fe||{'rows':[],'count':0x0},_0x2cd397['histories']=_0x388a1b||{'rows':[],'count':0x0},_0x2cd397['companies']=_0x298737||{'rows':[],'count':0x0},_0x2cd397[_0x1b8d10('0x8de')]=_0x3c96a0||{'rows':[],'count':0x0},_0x2cd397[_0x1b8d10('0x23d7')]=_0x173354||{'rows':[],'count':0x0},_0x2cd397['tags']=_0x4ce450||{'rows':[],'count':0x0},_0x2cd397[_0x1b8d10('0x1010')]=_0x297f02||{'rows':[],'count':0x0},_0x2cd397['timelineOptions']={'scrollEl':_0x1b8d10('0x2166')},_0x2cd397[_0x1b8d10('0x2387')]=new Date(_0x24273b()()[_0x1b8d10('0x1659')](_0x1b8d10('0x2e7'))['subtract'](0x1,_0x1b8d10('0x1aa6'))['utcOffset'](0x0,!![])[_0x1b8d10('0x128a')]()),_0x2cd397['lastDayMonth']=new Date(_0x24273b()()[_0x1b8d10('0x2589')](_0x1b8d10('0x2e7'))[_0x1b8d10('0x6ab')](0x1,_0x1b8d10('0x16a'))[_0x1b8d10('0x13f2')](0x0,!![])[_0x1b8d10('0x128a')]()),_0x2cd397['userProfileSection']=_0x59c7ec&&_0x59c7ec[_0x1b8d10('0x240f')]==0x1?_0x59c7ec['rows'][0x0]:null,_0x2cd397[_0x1b8d10('0x243c')]=_0x696e46[_0x1b8d10('0xd87')](_0x2cd397[_0x1b8d10('0x17aa')]?_0x2cd397[_0x1b8d10('0x17aa')][_0x1b8d10('0x243c')]:null),_0x2cd397['arraypriority']=_0x2cfb05()[_0x1b8d10('0x155c')]([{'option':_0x1b8d10('0xb06'),'value':_0x1b8d10('0x5d')},{'option':_0x1b8d10('0xf95'),'value':_0x1b8d10('0x2687')},{'option':_0x1b8d10('0x3e9'),'value':_0x1b8d10('0x246e')},{'option':'Low','value':_0x1b8d10('0x54e')},{'option':_0x1b8d10('0x4'),'value':_0x1b8d10('0x125f')}],function(_0x205e02){const _0x3d78f2=_0x1b8d10;return _0x2cfb05()[_0x3d78f2('0xf3')](_0x205e02['value'],new RegExp('\x27','g'),'');}),_0x2cd397[_0x1b8d10('0x20b4')]={'fields':_0x1b8d10('0x1f5e'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x2cd397[_0x1b8d10('0x25ca')]={'fields':_0x1b8d10('0xb'),'sort':_0x1b8d10('0x83'),'limit':0xa,'page':0x1},_0x2cd397['queryHistory']={'fields':_0x1b8d10('0x1cf4'),'sort':'-id','limit':0xa,'page':0x1},_0x2cd397[_0x1b8d10('0x2120')]={'fields':_0x1b8d10('0xb1c'),'sort':_0x1b8d10('0x1083'),'limit':0xa,'page':0x1},_0x2cd397[_0x1b8d10('0x2669')]=_0x429c26[_0x1b8d10('0x23f')][_0x1b8d10('0xbe3')]||0x0,_0x2cd397[_0x1b8d10('0xae0')]=_0x298609,_0x2cd397[_0x1b8d10('0x21ea')]=_0x27c251,_0x2cd397['duplicateContact']=_0x36427d,_0x2cd397[_0x1b8d10('0x1aae')]=_0x363d4b,_0x2cd397['editCompany']=_0x20e91a,_0x2cd397[_0x1b8d10('0x2754')]=_0x54ffaa,_0x2cd397['onSelectListSuccess']=_0xa22555,_0x2cd397['getDateFromString']=_0x2bb181,_0x2cd397[_0x1b8d10('0xfee')]=_0x48fcf6,_0x2cd397[_0x1b8d10('0x2e6')]=_0x565f49,_0x2cd397[_0x1b8d10('0xe86')]=_0x83c474,_0x2cd397[_0x1b8d10('0x1bf8')]=_0x1f4f2a,_0x2cd397['deleteconfirm']=_0x1ee9aa,_0x2cd397['editHopper']=_0x1bbc30,_0x2cd397['createOrEditIvrCampaignHopper']=_0x442b27,_0x2cd397['getColorByItem']=_0x3e6e29;let _0x40fe5f=!![],_0x28f994=0x1;_0x4e3ec8[_0x1b8d10('0xe83')]('vm.queryHopper.filter',function(_0x57f354,_0x1b34ae){const _0x20ac28=_0x1b8d10;_0x40fe5f?_0x58efaa(function(){_0x40fe5f=![];}):(!_0x1b34ae&&(_0x28f994=_0x2cd397[_0x20ac28('0x20b4')][_0x20ac28('0x1a43')]),_0x57f354!==_0x1b34ae&&(_0x2cd397[_0x20ac28('0x20b4')][_0x20ac28('0x1a43')]=0x1),!_0x57f354&&(_0x2cd397['queryHopper']['page']=_0x28f994),_0x2cd397['getHoppers']());}),_0x4e3ec8[_0x1b8d10('0xe83')]('vm.queryFinal.filter',function(_0x9c07ee,_0x427a03){const _0x389e6f=_0x1b8d10;_0x40fe5f?_0x58efaa(function(){_0x40fe5f=![];}):(!_0x427a03&&(_0x28f994=_0x2cd397['queryFinal'][_0x389e6f('0x1a43')]),_0x9c07ee!==_0x427a03&&(_0x2cd397[_0x389e6f('0x25ca')][_0x389e6f('0x1a43')]=0x1),!_0x9c07ee&&(_0x2cd397[_0x389e6f('0x25ca')][_0x389e6f('0x1a43')]=_0x28f994),_0x2cd397[_0x389e6f('0x2e6')]());}),_0x4e3ec8['$watch']('vm.queryHistory.filter',function(_0xabf7fe,_0x89433b){const _0x1b5a15=_0x1b8d10;_0x40fe5f?_0x58efaa(function(){_0x40fe5f=![];}):(!_0x89433b&&(_0x28f994=_0x2cd397[_0x1b5a15('0x687')][_0x1b5a15('0x1a43')]),_0xabf7fe!==_0x89433b&&(_0x2cd397[_0x1b5a15('0x687')]['page']=0x1),!_0xabf7fe&&(_0x2cd397['queryHistory'][_0x1b5a15('0x1a43')]=_0x28f994),_0x2cd397[_0x1b5a15('0xe86')]());});function _0x3da76b(_0x3bc15b){const _0x8e8583=_0x1b8d10;switch(_0x3bc15b){case _0x8e8583('0xde2'):return _0x8e8583('0x1d17');case _0x8e8583('0x1bfa'):return _0x8e8583('0x28e8');case'sms':return _0x8e8583('0x1adc');case _0x8e8583('0x26c'):return _0x8e8583('0xb1e');case'fax':return _0x8e8583('0x1917');case _0x8e8583('0x116e'):return _0x8e8583('0xe6d');default:return _0x8e8583('0x432');}}function _0x3e6e29(_0x214aba){const _0x2d873f=_0x1b8d10;let _0x3f0575='';if(_0x214aba[_0x2d873f('0x18fe')])_0x3f0575=_0x2d873f('0x1fc7');else{if(_0x214aba['OpenchannelAccountId'])_0x3f0575=_0x2d873f('0x26c');else{if(_0x214aba['SmsAccountId'])_0x3f0575=_0x2d873f('0x146c');else{if(_0x214aba[_0x2d873f('0x56')])_0x3f0575=_0x2d873f('0x1bfa');else{if(_0x214aba[_0x2d873f('0x1e02')])_0x3f0575=_0x2d873f('0xde2');else _0x214aba[_0x2d873f('0x1f2c')]&&(_0x3f0575='voice');}}}}return _0x3da76b(_0x3f0575);}function _0x4e9000(_0x257fbe){return function(_0x30e4de){_0x2cd397[_0x257fbe]=_0x30e4de||{'count':0x0,'rows':[]};};}function _0x298609(){const _0xe6ae45=_0x1b8d10;return!_0x696e46[_0xe6ae45('0x1ac6')](_0xe6ae45('0xa7c'))&&(_0x2218b9(),_0x345847()),_0x93ec4b['user'][_0xe6ae45('0xd83')]({'fields':_0xe6ae45('0x1217'),'nolimit':!![]})['$promise'][_0xe6ae45('0x1166')](function(_0x18705d){const _0x131bcb=_0xe6ae45;_0x2cd397[_0x131bcb('0x21f6')]=_0x18705d||{'count':0x0,'rows':[]},_0x2cd397[_0x131bcb('0x7b5')]=_0x2cfb05()[_0x131bcb('0x1f4d')](_0x2cfb05()[_0x131bcb('0x155c')](_0x2cd397[_0x131bcb('0x21f6')][_0x131bcb('0x269a')],'id'),_0x131bcb('0x6e1')),_0x2cd397[_0x131bcb('0x21c2')]=_0x2cfb05()[_0x131bcb('0x2563')](_0x2cd397[_0x131bcb('0x26db')]['Tags'],'id');})[_0xe6ae45('0x1166')](_0xb8c017(_0xa7e9ba));}function _0x2218b9(){const _0x3236ab=_0x1b8d10,_0x483e7a=_0x2cfb05()[_0x3236ab('0x1798')](_0x2cd397['companies'][_0x3236ab('0x269a')],{'id':_0x2cd397[_0x3236ab('0x26db')][_0x3236ab('0x537')]});if(!_0x483e7a)return _0x93ec4b[_0x3236ab('0xc39')][_0x3236ab('0xd83')]({'id':_0x2cd397['contact'][_0x3236ab('0x537')],'fields':'id,name'})[_0x3236ab('0xa44')]['then'](function(_0x5af536){const _0x4dc9cd=_0x3236ab,_0x7f8564=_0x5af536[_0x4dc9cd('0x2876')]();_0x7f8564['canSelect']=![],_0x2cd397[_0x4dc9cd('0xfd1')][_0x4dc9cd('0x269a')][_0x4dc9cd('0x1514')](_0x7f8564);})['catch'](function(_0x5ec952){const _0x54fe13=_0x3236ab;_0x5cdec1[_0x54fe13('0xfc9')]({'title':_0x5ec952['status']?_0x54fe13('0x1e21')+_0x5ec952[_0x54fe13('0x52d')]+_0x54fe13('0x11e1')+_0x5ec952[_0x54fe13('0xe1b')]:_0x54fe13('0x8a'),'msg':_0x5ec952[_0x54fe13('0x25f4')]?JSON[_0x54fe13('0xbac')](_0x5ec952[_0x54fe13('0x25f4')]['message']):_0x5ec952[_0x54fe13('0x1586')]()});});}function _0x345847(){const _0x2ebca5=_0x1b8d10,_0x35a987=_0x2cfb05()[_0x2ebca5('0x2563')](_0x2cd397[_0x2ebca5('0x26db')][_0x2ebca5('0x21c2')],function(_0x5ec258){return{'id':_0x5ec258['id'],'name':_0x5ec258['name']};});if(!_0x2cfb05()[_0x2ebca5('0x1081')](_0x35a987))for(let _0xe93794=0x0;_0xe93794<_0x35a987[_0x2ebca5('0x264b')];_0xe93794++){!_0x2cfb05()[_0x2ebca5('0x1798')](_0x2cd397[_0x2ebca5('0xb38')][_0x2ebca5('0x269a')],{'id':_0x35a987['id']})&&(_0x35a987[_0xe93794][_0x2ebca5('0x2378')]=![],_0x2cd397[_0x2ebca5('0xb38')]['rows'][_0x2ebca5('0x1514')](_0x35a987[_0xe93794]));}}function _0x137e05(_0xf69740){const _0x386a6f=_0x1b8d10;if(!_0xf69740['disposition'])return'('+_0x59f162[_0x386a6f('0x25cc')](_0x386a6f('0x991'))+')';const _0x23ce70=_0x2cfb05()[_0x386a6f('0xc4')]([_0xf69740[_0x386a6f('0x12e8')],_0xf69740['secondDisposition'],_0xf69740[_0x386a6f('0x228e')]]);return'('+_0x23ce70['join'](_0x386a6f('0x11e1'))+')';}function _0x38c45f(_0x374172){const _0x6bf54c=_0x1b8d10;_0x374172&&_0x374172[_0x6bf54c('0x240f')]&&_0x374172['rows']['length']&&(_0x2cd397[_0x6bf54c('0x227e')]=_0x2cfb05()[_0x6bf54c('0x1c6a')](_0x2cd397[_0x6bf54c('0x227e')],_0x374172[_0x6bf54c('0x269a')]),_0x2cd397[_0x6bf54c('0x227e')][_0x6bf54c('0x2782')](function(_0xdff316){_0xdff316['dispositionsValues']=_0x137e05(_0xdff316);}));}function _0xb8c017(_0x37cfbd){const _0xc3153a=_0x1b8d10,_0x924eb7=['mail',_0xc3153a('0xde2'),_0xc3153a('0x146c'),'openchannel','fax'];if(_0x37cfbd&&_0x37cfbd['id']){for(let _0x335648=0x0;_0x335648<_0x924eb7['length'];_0x335648++){_0x93ec4b[_0x924eb7[_0x335648]+_0xc3153a('0x7ee')]['get']({'ContactId':_0x37cfbd['id'],'includeAll':!![]})['$promise'][_0xc3153a('0x1166')](_0x38c45f);}_0x93ec4b[_0xc3153a('0x26e0')][_0xc3153a('0xd83')]({'ContactId':_0x37cfbd['id'],'includeAll':!![]})['$promise'][_0xc3153a('0x1166')](_0x38c45f)[_0xc3153a('0x1a80')](function(_0x4a0b0f){console['error'](_0x4a0b0f);});}}function _0x1bbc30(_0x2d4ff1,_0x16015a){const _0x3c5de7=_0x1b8d10;_0x4c36f4['show']({'controller':_0x3c5de7('0x1c8c'),'controllerAs':'vm','templateUrl':_0x8db371,'parent':angular[_0x3c5de7('0x1194')](_0x3a4eea['body']),'targetEvent':_0x2d4ff1,'clickOutsideToClose':!![],'locals':{'hopper':_0x16015a,'hoppers':_0x2cd397['hoppers'][_0x3c5de7('0x269a')],'license':null,'setting':null,'crudPermissions':_0x2cd397[_0x3c5de7('0x243c')]}});}function _0x442b27(_0x40591d,_0x1c546f){const _0x5e769c=_0x1b8d10;_0x4c36f4[_0x5e769c('0x1f80')]({'controller':_0x5e769c('0x155d'),'controllerAs':'vm','templateUrl':_0x24ef4f,'parent':angular['element'](_0x3a4eea['body']),'targetEvent':_0x40591d,'clickOutsideToClose':!![],'locals':{'hopper':_0x1c546f,'hoppers':_0x2cd397['hoppers'][_0x5e769c('0x269a')],'license':null,'setting':null,'crudPermissions':_0x2cd397[_0x5e769c('0x243c')]}});}function _0x1ee9aa(_0x1ff2b9,_0x7f114e){const _0x41b5ff=_0x1b8d10,_0x6a9ec3=_0x4c36f4[_0x41b5ff('0x1d26')]()[_0x41b5ff('0xcdc')](_0x41b5ff('0x7ce'))['htmlContent'](''+(_0x1ff2b9['phone']||_0x41b5ff('0x1d98'))+_0x41b5ff('0xace')+'\x20will\x20be\x20deleted.')[_0x41b5ff('0x8e8')](_0x41b5ff('0x19'))[_0x41b5ff('0x203b')](_0x7f114e)['ok']('OK')[_0x41b5ff('0x3f')](_0x41b5ff('0x2d3'));_0x4c36f4[_0x41b5ff('0x1f80')](_0x6a9ec3)[_0x41b5ff('0x1166')](function(){_0x51745c(_0x1ff2b9);},function(){const _0x41e996=_0x41b5ff;console[_0x41e996('0x455')]('CANCEL');});}function _0x51745c(_0xc8e15){const _0x145f05=_0x1b8d10;return _0x93ec4b[_0x145f05('0x256a')][_0x145f05('0x906')]({'id':_0xc8e15['id']})[_0x145f05('0xa44')][_0x145f05('0x1166')](function(){const _0xf1801a=_0x145f05;_0x2cfb05()[_0xf1801a('0x127f')](_0x2cd397[_0xf1801a('0x28c4')][_0xf1801a('0x269a')],{'id':_0xc8e15['id']}),_0x2cd397['hoppers'][_0xf1801a('0x240f')]--,!_0x2cd397['hoppers'][_0xf1801a('0x269a')][_0xf1801a('0x264b')]&&_0x2cd397[_0xf1801a('0xfee')](),_0x5cdec1[_0xf1801a('0x103b')]({'title':'Hopper\x20deleted!','msg':_0xc8e15[_0xf1801a('0x2026')]?_0xc8e15[_0xf1801a('0x2026')]+_0xf1801a('0x7cd'):''});})['catch'](function(_0x13e64c){const _0x2aeac1=_0x145f05;_0x5cdec1[_0x2aeac1('0xfc9')]({'title':_0x13e64c[_0x2aeac1('0x52d')]?_0x2aeac1('0x1e21')+_0x13e64c[_0x2aeac1('0x52d')]+'\x20-\x20'+_0x13e64c[_0x2aeac1('0xe1b')]:'SYSTEM:DELETEhopper','msg':_0x13e64c[_0x2aeac1('0x25f4')]?JSON['stringify'](_0x13e64c[_0x2aeac1('0x25f4')]):_0x13e64c[_0x2aeac1('0x1586')]()});});}function _0x48fcf6(){const _0x417b72=_0x1b8d10;_0x2cd397[_0x417b72('0x20b4')][_0x417b72('0x1098')]=(_0x2cd397[_0x417b72('0x20b4')][_0x417b72('0x1a43')]-0x1)*_0x2cd397['queryHopper'][_0x417b72('0x163f')],_0x2cd397[_0x417b72('0x20b4')]['id']=_0x2cd397['contact']['id'],_0x2cd397[_0x417b72('0x1f48')]=_0x93ec4b['cmContact']['getHoppers'](_0x2cd397['queryHopper'],_0x4e9000('hoppers'))[_0x417b72('0xa44')];}function _0x565f49(){const _0x21d118=_0x1b8d10;_0x2cd397[_0x21d118('0x25ca')]['offset']=(_0x2cd397[_0x21d118('0x25ca')][_0x21d118('0x1a43')]-0x1)*_0x2cd397['queryFinal'][_0x21d118('0x163f')],_0x2cd397[_0x21d118('0x25ca')]['id']=_0x2cd397[_0x21d118('0x26db')]['id'],_0x2cd397['promise']=_0x93ec4b['cmContact']['getHopperFinals'](_0x2cd397[_0x21d118('0x25ca')],_0x4e9000(_0x21d118('0x17d9')))[_0x21d118('0xa44')];}function _0x83c474(){const _0x59b1e3=_0x1b8d10;_0x2cd397[_0x59b1e3('0x687')][_0x59b1e3('0x1098')]=(_0x2cd397[_0x59b1e3('0x687')][_0x59b1e3('0x1a43')]-0x1)*_0x2cd397[_0x59b1e3('0x687')][_0x59b1e3('0x163f')],_0x2cd397[_0x59b1e3('0x687')]['id']=_0x2cd397['contact']['id'],_0x2cd397['promise']=_0x93ec4b[_0x59b1e3('0x149e')]['getHopperHistories'](_0x2cd397[_0x59b1e3('0x687')],_0x4e9000(_0x59b1e3('0x1f7c')))[_0x59b1e3('0xa44')];}function _0x1f4f2a(){const _0x59250b=_0x1b8d10;_0x2cd397[_0x59250b('0x2120')][_0x59250b('0x1098')]=(_0x2cd397[_0x59250b('0x2120')][_0x59250b('0x1a43')]-0x1)*_0x2cd397[_0x59250b('0x2120')][_0x59250b('0x163f')],_0x2cd397[_0x59250b('0x2120')]['id']=_0x2cd397[_0x59250b('0x26db')]['id'],_0x2cd397[_0x59250b('0x1f48')]=_0x93ec4b['cmContact'][_0x59250b('0x1bf8')](_0x2cd397[_0x59250b('0x2120')],_0x4e9000(_0x59250b('0x1010')))[_0x59250b('0xa44')];}function _0x54ffaa(_0x4b465f){const _0x438f96=_0x1b8d10;if(_0x2cd397[_0x438f96('0x26db')]['ListId']){const _0x3b3e88=_0x4c36f4['confirm']()[_0x438f96('0xcdc')](_0x438f96('0xc4a')+_0x2cd397[_0x438f96('0x26db')][_0x438f96('0x23c')])[_0x438f96('0x2077')](_0x438f96('0x26a2')+_0x2cd397['contact'][_0x438f96('0x18cb')]||0x0||0x0)[_0x438f96('0x203b')](_0x4b465f)['ok']('Ok')['cancel'](_0x438f96('0x497'));return _0x4c36f4[_0x438f96('0x1f80')](_0x3b3e88)[_0x438f96('0x1166')](_0x2cd397[_0x438f96('0x3fa')])[_0x438f96('0x1a80')](function(){const _0x2b09d5=_0x438f96;_0x2cd397[_0x2b09d5('0x26db')]['ListId']=null;});}}function _0xa22555(){const _0x1cb824=_0x1b8d10;return _0x93ec4b['cmList'][_0x1cb824('0x1bb')]({'id':_0x2cd397[_0x1cb824('0x26db')][_0x1cb824('0x23c')]})[_0x1cb824('0xa44')][_0x1cb824('0x1166')](function(_0x4a7f10){const _0x11f82c=_0x1cb824;_0x2cd397[_0x11f82c('0x23d7')]=_0x4a7f10||{'rows':[],'count':0x0};})[_0x1cb824('0x1a80')](function(_0x117aed){const _0x4edf8a=_0x1cb824;console[_0x4edf8a('0xfc9')](_0x117aed);});}function _0x2ceafb(){const _0x234e81=_0x1b8d10;return _0x93ec4b[_0x234e81('0x17aa')][_0x234e81('0xd83')]({'userProfileId':_0x2cd397[_0x234e81('0x98')]['userProfileId'],'sectionId':0x12e})[_0x234e81('0xa44')]['then'](function(_0x4e76f9){const _0x4ff84d=_0x234e81,_0x5ebcb9=_0x4e76f9[_0x4ff84d('0x269a')]?_0x4e76f9[_0x4ff84d('0x269a')][0x0]:null;return _0x696e46['parseCrudPermissions'](_0x5ebcb9?_0x5ebcb9[_0x4ff84d('0x243c')]:null);})['catch'](function(_0x18343f){const _0xf2cae=_0x234e81;_0x5cdec1[_0xf2cae('0xfc9')]({'title':_0x18343f[_0xf2cae('0x52d')]?_0xf2cae('0x1e21')+_0x18343f['status']+_0xf2cae('0x11e1')+_0x18343f[_0xf2cae('0xe1b')]:'API:GET_COMPANY_SECTION','msg':_0x18343f[_0xf2cae('0x25f4')]?JSON[_0xf2cae('0xbac')](_0x18343f[_0xf2cae('0x25f4')]):_0x18343f['toString']()});});}function _0x20e91a(_0x28090a,_0xe587f5){const _0xbc31bf=_0x1b8d10,_0x26dddf=_0x2cfb05()[_0xbc31bf('0xc38')](_0x2cd397[_0xbc31bf('0xfd1')][_0xbc31bf('0x269a')],{'id':_0xe587f5});_0x4c36f4[_0xbc31bf('0x1f80')]({'controller':_0xbc31bf('0x1d6c'),'controllerAs':'vm','templateUrl':_0x1a4aea,'parent':angular['element'](_0x3a4eea[_0xbc31bf('0x8d2')]),'targetEvent':_0x28090a,'clickOutsideToClose':!![],'locals':{'companies':[],'license':null,'setting':null,'crudPermissions':_0x26dddf[_0xbc31bf('0x2378')]===![]?{'readOnly':!![],'canEdit':![],'canDelete':![]}:_0x2ceafb()},'resolve':{'company':['apiResolver',function(_0x43d3f2){const _0x188659=_0xbc31bf;return _0x43d3f2[_0x188659('0x18af')]('cmCompany@get',{'id':_0xe587f5});}]}});}function _0x36427d(_0x53239c){const _0x593e3b=_0x1b8d10;_0x4c36f4[_0x593e3b('0x1f80')]({'controller':_0x593e3b('0x15ad'),'controllerAs':'vm','templateUrl':_0x5b62a4,'parent':angular[_0x593e3b('0x1194')](_0x3a4eea[_0x593e3b('0x8d2')]),'targetEvent':_0x53239c,'clickOutsideToClose':!![],'resolve':{'lists':[_0x593e3b('0x1fbc'),'Auth',function(_0x33e5e4,_0x46982b){const _0x4cbcbd=_0x593e3b;return _0x46982b[_0x4cbcbd('0x1ac6')](_0x4cbcbd('0xa7c'))?_0x33e5e4[_0x4cbcbd('0x18af')](_0x4cbcbd('0x4ee'),{'fields':_0x4cbcbd('0x1776')}):_0x33e5e4[_0x4cbcbd('0x18af')](_0x4cbcbd('0x17c4'),{'id':_0x2cd397[_0x4cbcbd('0x98')][_0x4cbcbd('0xb86')],'section':_0x4cbcbd('0x1cae'),'fields':_0x4cbcbd('0x1776')});}]},'locals':{'contacts':_0x4312aa['rows'],'contact':_0xa7e9ba}});}function _0x363d4b(){const _0x33c0d2=_0x1b8d10;_0x93ec4b[_0x33c0d2('0x149e')]['update']({'id':_0x2cd397[_0x33c0d2('0x26db')]['id']},_0x2cd397[_0x33c0d2('0x26db')])[_0x33c0d2('0xa44')][_0x33c0d2('0x1166')](function(){const _0x40b3e4=_0x33c0d2;_0x5cdec1['success']({'title':_0x40b3e4('0x13d6'),'msg':_0x2cd397['contact'][_0x40b3e4('0x4f0')]?_0x2cd397[_0x40b3e4('0x26db')][_0x40b3e4('0x4f0')]+_0x40b3e4('0xa17'):''});})['then'](function(){const _0x22c424=_0x33c0d2;return _0x93ec4b[_0x22c424('0x149e')]['setTags']({'id':_0x2cd397['contact']['id'],'ids':_0x2cd397['Tags']})[_0x22c424('0xa44')];})[_0x33c0d2('0x1a80')](function(_0x3f334a){const _0x4da8ae=_0x33c0d2;_0x5cdec1['error']({'title':_0x3f334a[_0x4da8ae('0x52d')]?_0x4da8ae('0x1e21')+_0x3f334a['status']+_0x4da8ae('0x11e1')+_0x3f334a['statusText']:_0x4da8ae('0x31f'),'msg':_0x3f334a[_0x4da8ae('0x25f4')]?JSON[_0x4da8ae('0xbac')](_0x3f334a['data']):_0x3f334a[_0x4da8ae('0x1586')]()});});}function _0x2bb181(_0x4905b4){return _0x4905b4===null?undefined:new Date(_0x4905b4);}function _0x27c251(){const _0x1754f8=_0x1b8d10;_0x429c26['go'](_0x1754f8('0x1275'),{},{'reload':!![],'notify':!![]});}}const _0xaf8a5e=_0x4fefc6;_0x1456c5[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x265d'),_0x36e6f4('0x10eb'),'$q',_0x36e6f4('0x8da'),'lists',_0x36e6f4('0xfd1'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x36f'),_0x36e6f4('0x6bd'),_0x36e6f4('0xfe2'),_0x36e6f4('0x5c9')];function _0x1456c5(_0x408aae,_0x40757a,_0x1a9f46,_0x1199fd,_0x271073,_0xd13c24,_0x4e8be2,_0x2b6a91,_0xdcf162,_0x2700db,_0x859869,_0x3044f1,_0x30434c,_0x3df645){const _0x1d4952=_0x36e6f4,_0x53ee14=this;_0x53ee14[_0x1d4952('0x1977')]=![],_0x53ee14[_0x1d4952('0xf7d')]=!![],_0x53ee14['license']=_0x3df645,_0x53ee14[_0x1d4952('0x1a7c')]=0x0,_0x53ee14['result']={'finish':![],'rows':0x0,'affectedRows':0x0,'failedRows':0x0,'duplicatedRows':0x0,'errors':[]},_0x53ee14[_0x1d4952('0x147')]=[{'key':'firstName','required':!![]},{'key':_0x1d4952('0xeb0'),'required':![]},{'key':_0x1d4952('0x2026'),'required':!![]},{'key':_0x1d4952('0x2459'),'required':![]},{'key':'email','required':![]},{'key':_0x1d4952('0x17a0'),'required':![]},{'key':_0x1d4952('0x1c0a'),'required':![]},{'key':'city','required':![]},{'key':_0x1d4952('0x211e'),'required':![]},{'key':_0x1d4952('0x1b78'),'required':![]},{'key':_0x1d4952('0x1fc7'),'required':![]}],_0x53ee14[_0x1d4952('0x1ab2')]=[{'key':_0x1d4952('0x122a'),'required':![]},{'key':_0x1d4952('0x1c5e'),'required':![]},{'key':'priority','required':![]}],_0x53ee14['binding']={},_0x53ee14[_0x1d4952('0x23e8')]=[],_0x53ee14[_0x1d4952('0x8de')]=_0xd13c24||{'rows':[],'count':0x0},_0x53ee14[_0x1d4952('0xfd1')]=_0x4e8be2||{'rows':[],'count':0x0},_0x53ee14['customFields']={'rows':[],'count':0x0},_0x53ee14[_0x1d4952('0xfe2')]=_0x30434c||[],_0x53ee14['closeDialog']=_0x1f1e14,_0x53ee14[_0x1d4952('0x127d')]=_0x16913a,_0x53ee14[_0x1d4952('0x1e05')]=_0x3da4cb,_0x53ee14[_0x1d4952('0x1463')]=_0x42c046,_0x53ee14[_0x1d4952('0x1d2a')]=_0x481fbb,_0x53ee14[_0x1d4952('0x936')]=_0x493829;const _0x32f66f=_0x24273b()()['unix']();_0x2700db['on'](_0x1d4952('0x1a8')+_0x32f66f,_0x7b5d85);function _0x16913a(){const _0x414dab=_0x1d4952;return _0xdcf162['cmList'][_0x414dab('0x1bb')]({'id':_0x53ee14['ListId']})[_0x414dab('0xa44')][_0x414dab('0x1166')](function(_0x2ca0c6){const _0x5a1b4d=_0x414dab;_0x53ee14[_0x5a1b4d('0x23d7')]=_0x2ca0c6;})[_0x414dab('0x1a80')](function(_0x495b72){const _0x56cead=_0x414dab;console[_0x56cead('0xfc9')](_0x495b72);});}function _0x3da4cb(){const _0x1a6b23=_0x1d4952;_0x53ee14[_0x1a6b23('0x1977')]=_0x24273b()(),_0xdcf162[_0x1a6b23('0x149e')][_0x1a6b23('0x271f')]({'id':_0x3044f1['filename'],'binding':_0x53ee14[_0x1a6b23('0x2664')],'ListId':_0x53ee14['ListId'],'CompanyId':_0x53ee14[_0x1a6b23('0x537')],'duplicates':_0x53ee14[_0x1a6b23('0x38a')],'socket_timestamp':_0x32f66f})['$promise'][_0x1a6b23('0x1166')](function(_0x440643){const _0x2fb7c6=_0x1a6b23;_0x53ee14[_0x2fb7c6('0xf7d')]=![],_0x440643&&_0x440643[_0x2fb7c6('0x1a7c')]&&(_0x53ee14[_0x2fb7c6('0x1a7c')]=_0x440643[_0x2fb7c6('0x1a7c')]);})['catch'](function(){const _0x585a35=_0x1a6b23;_0x53ee14[_0x585a35('0x1977')]=![],_0x2b6a91[_0x585a35('0xfc9')]({'title':_0x585a35('0xe70'),'msg':_0x585a35('0x475')});});}function _0x7b5d85(_0x22943a){_0x271073(function(){const _0x16912a=a0_0x3f2c;_0x53ee14[_0x16912a('0x15b5')][_0x16912a('0x269a')]=_0x22943a[_0x16912a('0x269a')];if(_0x22943a[_0x16912a('0x61a')])for(let _0xba3a04=0x0;_0xba3a04<_0x22943a[_0x16912a('0x61a')]['length'];_0xba3a04++){_0x53ee14[_0x16912a('0x15b5')]['errors'][_0x16912a('0x1514')](_0x22943a['errors'][_0xba3a04]);}if(_0x22943a[_0x16912a('0x1b3c')]){_0x53ee14[_0x16912a('0x15b5')]['finish']=!![],_0x53ee14['result'][_0x16912a('0x23c7')]=_0x22943a[_0x16912a('0x23c7')],_0x53ee14[_0x16912a('0x15b5')][_0x16912a('0x17dc')]=_0x53ee14[_0x16912a('0x15b5')][_0x16912a('0x61a')][_0x16912a('0x264b')];const _0x397319=_0x53ee14['result'][_0x16912a('0x269a')]-_0x53ee14[_0x16912a('0x15b5')][_0x16912a('0x23c7')]-_0x53ee14[_0x16912a('0x15b5')][_0x16912a('0x61a')][_0x16912a('0x264b')];_0x397319&&_0x397319>0x0&&(_0x53ee14['duplicates'][_0x16912a('0x264b')]?_0x53ee14[_0x16912a('0x15b5')][_0x16912a('0x1e56')]=_0x397319:_0x53ee14[_0x16912a('0x15b5')][_0x16912a('0x17dc')]+=_0x397319),_0x53ee14[_0x16912a('0x15b5')]['elapsed']=_0x24273b()()[_0x16912a('0x884')](_0x53ee14[_0x16912a('0x1977')],_0x16912a('0x1aa6'));}});}function _0x42c046(){const _0xc60742=_0x1d4952,_0x5ad45d=_0x30434c;return _0x5ad45d[_0xc60742('0x1514')]('contact_import_error'),_0x5ad45d;}function _0x481fbb(){const _0x2454ad=_0x1d4952,_0x317d59=[];for(let _0x584926=0x0;_0x584926<_0x53ee14[_0x2454ad('0x15b5')][_0x2454ad('0x61a')][_0x2454ad('0x264b')];_0x584926+=0x1){const _0x4267ee=_0x53ee14[_0x2454ad('0x15b5')]['errors'][_0x584926][_0x2454ad('0x205d')];_0x4267ee[_0x2454ad('0x2474')]=_0x53ee14[_0x2454ad('0x15b5')][_0x2454ad('0x61a')][_0x584926][_0x2454ad('0x1e70')],_0x317d59[_0x2454ad('0x1514')](_0x4267ee);}return _0x317d59;}function _0x493829(){const _0x3181a5=_0x1d4952;_0x53ee14['stopping']=!![];if(_0x53ee14[_0x3181a5('0x1a7c')])return _0xdcf162[_0x3181a5('0x1c2b')][_0x3181a5('0x1633')]({'pid':_0x53ee14['pid']})['$promise'][_0x3181a5('0x1166')](function(){const _0xb27c45=_0x3181a5;_0x2b6a91[_0xb27c45('0x103b')]({'title':_0xb27c45('0x26b9'),'msg':_0xb27c45('0x1fca')});})[_0x3181a5('0x1a80')](function(){const _0x5b68c4=_0x3181a5;_0x2b6a91['error']({'title':_0x5b68c4('0x1581'),'msg':_0x5b68c4('0x23bb')});});}_0x859869[_0x1d4952('0x3d2')]('$destroy',function(){const _0x14561f=_0x1d4952;_0x2700db['removeAllListeners'](_0x14561f('0x1a8')+_0x32f66f);});function _0x1f1e14(){const _0x164669=_0x1d4952;_0x2700db[_0x164669('0x1800')](_0x164669('0x1a8')+_0x32f66f),_0x40757a[_0x164669('0x1197')]();}}const _0x2cac98=_0x1456c5;_0x2a85b8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x36f'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x26db'),'contacts',_0x36e6f4('0x8de'),_0x36e6f4('0x19e3')];function _0x2a85b8(_0x56a663,_0x13283e,_0x5be011,_0x27adb3,_0x55bfd9,_0x910d57,_0xdb3c72){const _0x570909=_0x36e6f4,_0x40accc=this;_0x40accc['errors']=[],_0x40accc[_0x570909('0xcdc')]=_0x570909('0x619'),_0x40accc['contact']=angular['copy'](_0x27adb3),_0x40accc[_0x570909('0x8de')]=_0x910d57||[],_0x40accc['change']=function(){const _0x5e74bd=_0x570909;_0x40accc[_0x5e74bd('0x2b9')]?_0xdb3c72[_0x5e74bd('0x149e')][_0x5e74bd('0xd83')]({'fields':'id,firstName,lastName,phone,email','filter':_0x40accc[_0x5e74bd('0x2b9')],'ListId':_0x27adb3[_0x5e74bd('0x23c')]})[_0x5e74bd('0xa44')][_0x5e74bd('0x1166')](function(_0x4dfb4b){const _0x4dfa45=_0x5e74bd;_0x40accc[_0x4dfa45('0xca8')]=_0x4dfb4b[_0x4dfa45('0x269a')];})['catch'](function(_0x34c9a7){const _0x33e1e4=_0x5e74bd;console[_0x33e1e4('0xfc9')](_0x34c9a7);}):_0x40accc[_0x5e74bd('0xca8')]=[];},_0x40accc[_0x570909('0x1252')]=_0x4c119c,_0x40accc[_0x570909('0x24a0')]=_0x30f95e;function _0x4c119c(_0x413a66,_0x2dc232,_0x4d23f7){const _0x227dd0=_0x570909,_0x4a599b=_0x56a663[_0x227dd0('0x1d26')]({'skipHide':!![]})['title']('Would\x20you\x20like\x20to\x20merge\x20your\x20contacs?')[_0x227dd0('0x2077')](_0x227dd0('0x2527')+_0x4d23f7['id']+_0x227dd0('0x7da')+_0x2dc232['id']+'.')[_0x227dd0('0x203b')](_0x413a66)['ok']('Ok')['cancel'](_0x227dd0('0x497'));_0x56a663['show'](_0x4a599b)[_0x227dd0('0x1166')](function(){const _0x52c4de=_0x227dd0;return _0xdb3c72[_0x52c4de('0x149e')][_0x52c4de('0xcc3')]({'to':_0x4d23f7['id'],'from':_0x2dc232['id']})['$promise'];})[_0x227dd0('0x1166')](function(_0x2ac7fc){const _0x3d5db3=_0x227dd0;_0x56a663['hide']({'new':_0x2ac7fc,'to':_0x4d23f7,'from':_0x2dc232}),_0x2cfb05()[_0x3d5db3('0x127f')](_0x55bfd9,{'id':_0x4d23f7['id']}),_0x2cfb05()['remove'](_0x55bfd9,{'id':_0x2dc232['id']}),_0x55bfd9[_0x3d5db3('0x2450')](_0x2ac7fc);})[_0x227dd0('0x1166')](function(){const _0x84fbf2=_0x227dd0;_0x5be011[_0x84fbf2('0x103b')]({'title':_0x84fbf2('0x1329')});})['catch'](function(_0xb7f57c){const _0x435efc=_0x227dd0;_0xb7f57c&&_0xb7f57c[_0x435efc('0x52d')]&&_0x5be011[_0x435efc('0xfc9')]({'title':_0xb7f57c[_0x435efc('0x52d')]?_0x435efc('0x1e21')+_0xb7f57c[_0x435efc('0x52d')]+_0x435efc('0x11e1')+_0xb7f57c[_0x435efc('0xe1b')]:_0x435efc('0x13c5'),'msg':_0xb7f57c[_0x435efc('0x25f4')]?JSON[_0x435efc('0xbac')](_0xb7f57c[_0x435efc('0x25f4')]):_0xb7f57c['toString']()});});}function _0x30f95e(){const _0x2fcccb=_0x570909;_0x56a663[_0x2fcccb('0x1197')]();}}const _0x1a0d5e=_0x2a85b8,_0x5477d8=_0x2734b2['p']+_0x36e6f4('0x12f2'),_0x413913=_0x2734b2['p']+'src/js/modules/main/apps/contactmanager/views/contacts/edit/view.html/view.html';_0x3a0eef[_0x36e6f4('0x1294')]=['$stateProvider'];function _0x3a0eef(_0x300ca3){const _0x4612f7=_0x36e6f4;_0x300ca3[_0x4612f7('0x63f')](_0x4612f7('0x1275'),{'url':'/contacts?ListId&CompanyId','views':{'content@app':{'templateUrl':_0x5477d8,'controller':_0x4612f7('0x1d20')}},'resolve':{'contacts':[_0x4612f7('0x1fbc'),_0x4612f7('0x21ef'),_0x4612f7('0xf75'),function(_0x2f8f25,_0x342c02,_0x13db3d){const _0x2b341a=_0x4612f7;return _0x342c02['hasRole'](_0x2b341a('0xa7c'))?_0x2f8f25[_0x2b341a('0x18af')](_0x2b341a('0x111c'),_0x2cfb05()[_0x2b341a('0xcc3')]({'includeAll':!![],'sort':_0x2b341a('0x14dc'),'limit':0xa,'offset':0x0},_0x13db3d)):_0x2f8f25[_0x2b341a('0x18af')](_0x2b341a('0x17c4'),_0x2cfb05()[_0x2b341a('0xcc3')]({'id':_0x342c02['getCurrentUser']()[_0x2b341a('0xb86')],'section':_0x2b341a('0x2326'),'includeAll':!![],'sort':'-updatedAt','limit':0xa,'offset':0x0},_0x13db3d));}],'lists':[_0x4612f7('0x1fbc'),_0x4612f7('0x21ef'),function(_0x258a0c,_0x35c0b1){const _0x402306=_0x4612f7;return _0x35c0b1[_0x402306('0x1ac6')]('admin')?_0x258a0c[_0x402306('0x18af')](_0x402306('0x4ee'),{'fields':_0x402306('0x1776'),'sort':_0x402306('0x4f0'),'nolimit':!![]}):_0x258a0c[_0x402306('0x18af')](_0x402306('0x17c4'),{'id':_0x35c0b1['getCurrentUser']()[_0x402306('0xb86')],'section':_0x402306('0x1cae'),'fields':_0x402306('0x1776'),'sort':_0x402306('0x14dc'),'nolimit':!![]});}],'listsMap':[_0x4612f7('0x8de'),function(_0xc7dc53){const _0x220a01=_0x4612f7,_0x27c25b={};for(let _0xacf27=0x0;_0xacf27<_0xc7dc53[_0x220a01('0x269a')][_0x220a01('0x264b')];_0xacf27++){_0x27c25b[_0xc7dc53['rows'][_0xacf27]['id']]=_0xc7dc53[_0x220a01('0x269a')][_0xacf27][_0x220a01('0x4f0')];}return _0x27c25b;}],'companies':[_0x4612f7('0x1fbc'),_0x4612f7('0x21ef'),function(_0x1e7469,_0x36cf21){const _0x2ee340=_0x4612f7;return _0x36cf21[_0x2ee340('0x1ac6')]('admin')?_0x1e7469[_0x2ee340('0x18af')](_0x2ee340('0x117a'),{'fields':_0x2ee340('0x1776'),'sort':'name','nolimit':!![]}):_0x1e7469[_0x2ee340('0x18af')]('userProfile@getResources',{'id':_0x36cf21[_0x2ee340('0x26cd')]()['userProfileId'],'section':_0x2ee340('0x117'),'fields':_0x2ee340('0x1776'),'sort':'name','nolimit':!![]});}],'companiesMap':[_0x4612f7('0xfd1'),function(_0x464a47){const _0x1b85a8=_0x4612f7,_0x4fb39d={};for(let _0x223392=0x0;_0x223392<_0x464a47[_0x1b85a8('0x269a')][_0x1b85a8('0x264b')];_0x223392++){_0x4fb39d[_0x464a47['rows'][_0x223392]['id']]=_0x464a47[_0x1b85a8('0x269a')][_0x223392][_0x1b85a8('0x4f0')];}return _0x4fb39d;}],'tags':['apiResolver',_0x4612f7('0x21ef'),function(_0x7de582,_0x4caba4){const _0x26101f=_0x4612f7;return _0x4caba4[_0x26101f('0x1ac6')](_0x26101f('0xa7c'))?_0x7de582[_0x26101f('0x18af')](_0x26101f('0x1dfc'),{'fields':_0x26101f('0x1776'),'sort':'name','nolimit':!![]}):_0x7de582['resolve'](_0x26101f('0x17c4'),{'id':_0x4caba4[_0x26101f('0x26cd')]()['userProfileId'],'section':'Tags','fields':'id,name','sort':_0x26101f('0x4f0'),'nolimit':!![]});}],'userProfile':[_0x4612f7('0x1fbc'),'Auth',function(_0x4ee87f,_0x5c660c){const _0x2ce52d=_0x4612f7;return _0x4ee87f[_0x2ce52d('0x18af')](_0x2ce52d('0x697'),{'fields':_0x2ce52d('0x686'),'id':_0x5c660c[_0x2ce52d('0x26cd')]()[_0x2ce52d('0xb86')]});}],'userProfileSection':[_0x4612f7('0x1fbc'),'Auth',function(_0x2c51ec,_0x2ecc5b){const _0x201399=_0x4612f7;return _0x2c51ec[_0x201399('0x18af')](_0x201399('0xaf'),{'fields':_0x201399('0xe26'),'userProfileId':_0x2ecc5b['getCurrentUser']()[_0x201399('0xb86')],'sectionId':0x12f});}]},'authenticate':!![],'permissionId':0x12f,'bodyClass':'contactmanager'})['state'](_0x4612f7('0x1e16'),{'url':_0x4612f7('0x2233'),'params':{'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x413913,'controller':_0x4612f7('0xdb2')}},'resolve':{'contact':['apiResolver','$stateParams',function(_0x4f1ea9,_0x1e244e){const _0x5d63da=_0x4612f7;return _0x4f1ea9[_0x5d63da('0x18af')]('cmContact@get',{'id':_0x1e244e['id']})[_0x5d63da('0x1166')](function(_0x17b799){const _0x5e5810=_0x5d63da;return _0x17b799['dateOfBirth']&&(_0x17b799[_0x5e5810('0x17a0')]=new Date(_0x17b799[_0x5e5810('0x17a0')])),_0x17b799;})['catch'](function(_0x381243){const _0x4b903c=_0x5d63da;console[_0x4b903c('0xfc9')](_0x381243);});}],'hoppers':['apiResolver','$stateParams',function(_0x178fc0,_0x393ffe){const _0x2a386f=_0x4612f7;return _0x178fc0[_0x2a386f('0x18af')](_0x2a386f('0x22da'),{'id':_0x393ffe['id'],'fields':_0x2a386f('0x1f5e'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'finals':[_0x4612f7('0x1fbc'),_0x4612f7('0xf75'),function(_0x415a8a,_0x15c95c){const _0x40ceea=_0x4612f7;return _0x415a8a[_0x40ceea('0x18af')](_0x40ceea('0x1c51'),{'id':_0x15c95c['id'],'fields':_0x40ceea('0xb'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'histories':[_0x4612f7('0x1fbc'),_0x4612f7('0xf75'),function(_0x5eef99,_0x4951a0){const _0x485c28=_0x4612f7;return _0x5eef99[_0x485c28('0x18af')](_0x485c28('0x26ed'),{'id':_0x4951a0['id'],'fields':'id,uniqueid,calleridnum,statedesc,scheduledat,starttime,endtime','sort':_0x485c28('0x14dc'),'limit':0xa,'offset':0x0});}],'jscriptySessions':[_0x4612f7('0x1fbc'),_0x4612f7('0xf75'),function(_0x18194c,_0x4a35a0){const _0x2e6756=_0x4612f7;return _0x18194c[_0x2e6756('0x18af')](_0x2e6756('0x13c'),{'id':_0x4a35a0['id'],'fields':_0x2e6756('0xb1c'),'sort':_0x2e6756('0x1083'),'limit':0xa,'offset':0x0});}],'companies':[_0x4612f7('0x1fbc'),'Auth',function(_0x3c1eff,_0x5d3079){const _0x5be94b=_0x4612f7;return _0x5d3079[_0x5be94b('0x1ac6')](_0x5be94b('0xa7c'))?_0x3c1eff['resolve'](_0x5be94b('0x117a')):_0x3c1eff[_0x5be94b('0x18af')](_0x5be94b('0x17c4'),{'id':_0x5d3079[_0x5be94b('0x26cd')]()[_0x5be94b('0xb86')],'section':_0x5be94b('0x117')});}],'lists':['apiResolver',_0x4612f7('0x21ef'),function(_0x2f5c20,_0x398d09){const _0x2306e4=_0x4612f7;return _0x398d09['hasRole'](_0x2306e4('0xa7c'))?_0x2f5c20['resolve'](_0x2306e4('0x4ee'),{'fields':'id,name','sort':'-updatedAt','nolimit':!![]}):_0x2f5c20[_0x2306e4('0x18af')](_0x2306e4('0x17c4'),{'id':_0x398d09[_0x2306e4('0x26cd')]()[_0x2306e4('0xb86')],'section':'Lists','fields':_0x2306e4('0x1776'),'sort':_0x2306e4('0x14dc'),'nolimit':!![]});}],'customFields':[_0x4612f7('0x1fbc'),_0x4612f7('0x26db'),function(_0x5158cf,_0x27aecd){const _0x400f1f=_0x4612f7;return _0x27aecd['ListId']?_0x5158cf[_0x400f1f('0x18af')](_0x400f1f('0x26c0'),{'id':_0x27aecd[_0x400f1f('0x23c')]}):null;}],'tags':[_0x4612f7('0x1fbc'),'Auth',function(_0x312d8a,_0x48e26e){const _0x4c25e1=_0x4612f7;return _0x48e26e[_0x4c25e1('0x1ac6')](_0x4c25e1('0xa7c'))?_0x312d8a[_0x4c25e1('0x18af')]('tag@get'):_0x312d8a['resolve'](_0x4c25e1('0x17c4'),{'id':_0x48e26e[_0x4c25e1('0x26cd')]()[_0x4c25e1('0xb86')],'section':_0x4c25e1('0x21c2')});}],'userProfileSection':[_0x4612f7('0x1fbc'),_0x4612f7('0x21ef'),function(_0x59aaac,_0x2210d2){const _0x43f05b=_0x4612f7;return _0x59aaac[_0x43f05b('0x18af')](_0x43f05b('0xaf'),{'fields':_0x43f05b('0xe26'),'userProfileId':_0x2210d2[_0x43f05b('0x26cd')]()[_0x43f05b('0xb86')],'sectionId':0x12f});}]},'authenticate':!![],'permissionId':0x12f,'bodyClass':'contactmanager'});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x1275'),[])[_0x36e6f4('0xe11')](_0x3a0eef)[_0x36e6f4('0x75e')](_0x36e6f4('0xbe7'),_0x4293ed)[_0x36e6f4('0x75e')](_0x36e6f4('0x313'),_0x3f37f8)[_0x36e6f4('0x75e')](_0x36e6f4('0x15ad'),_0x25d149)['controller'](_0x36e6f4('0x130a'),_0x43171b)[_0x36e6f4('0x75e')](_0x36e6f4('0x21c9'),_0xaf8a5e)[_0x36e6f4('0x75e')](_0x36e6f4('0x15cd'),_0x2cac98)[_0x36e6f4('0x75e')](_0x36e6f4('0xcd1'),_0x1a0d5e);const _0x37e232=_0x2734b2['p']+_0x36e6f4('0x1483');_0x47cf9a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0xfd1'),'userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting'];function _0x47cf9a(_0x1023fe,_0x28aeeb,_0x5587a1,_0x4b2ebc,_0x5ef11c,_0x69f6de,_0x2a5103,_0x54c4f6,_0x98ebe6,_0x406bf8,_0x538670,_0x3e0bff,_0xc306a1,_0xb9b1c9,_0x2d725b,_0x3f9b27,_0x64f42){const _0xa5f7a6=_0x36e6f4,_0x52d75f=this;_0x52d75f[_0xa5f7a6('0x5c9')]=_0x3f9b27,_0x52d75f[_0xa5f7a6('0xf8a')]=_0x64f42,_0x52d75f[_0xa5f7a6('0x98')]=_0x2d725b[_0xa5f7a6('0x26cd')](),_0x52d75f[_0xa5f7a6('0xfd1')]=_0x98ebe6||{'count':0x0,'rows':[]},_0x52d75f[_0xa5f7a6('0x7f')]=_0x406bf8,_0x52d75f[_0xa5f7a6('0x17aa')]=_0x538670&&_0x538670[_0xa5f7a6('0x240f')]==0x1?_0x538670[_0xa5f7a6('0x269a')][0x0]:null,_0x52d75f[_0xa5f7a6('0x243c')]=_0x2d725b['parseCrudPermissions'](_0x52d75f['userProfileSection']?_0x52d75f[_0xa5f7a6('0x17aa')][_0xa5f7a6('0x243c')]:null),_0x52d75f[_0xa5f7a6('0x916')]=_0xa5f7a6('0xfd1'),_0x52d75f[_0xa5f7a6('0xef5')]='',_0x52d75f[_0xa5f7a6('0x104c')]=null,_0x52d75f[_0xa5f7a6('0x20b1')]=[],_0x52d75f[_0xa5f7a6('0x2218')]={'fields':_0xa5f7a6('0x7d9'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x52d75f[_0xa5f7a6('0x1ff6')]=_0x57da89,_0x52d75f[_0xa5f7a6('0x282b')]=_0x402964,_0x52d75f[_0xa5f7a6('0x8d8')]=_0x5cf244,_0x52d75f[_0xa5f7a6('0x103b')]=_0x129ef0,_0x52d75f[_0xa5f7a6('0x1dc5')]=_0x383f25,_0x52d75f[_0xa5f7a6('0x1bfd')]=_0x234c50,_0x52d75f['deleteCompany']=_0xe0924d,_0x52d75f[_0xa5f7a6('0x1de8')]=_0xb730b3,_0x52d75f[_0xa5f7a6('0x17f1')]=_0x364e9a,_0x52d75f[_0xa5f7a6('0x35a')]=_0x432bdc,_0x52d75f[_0xa5f7a6('0x169c')]=_0x27abae;function _0x57da89(_0x44768e){const _0xc7cafb=_0xa5f7a6;_0x5587a1['go'](_0xc7cafb('0x23dd'),{'id':_0x44768e['id'],'company':_0x44768e,'crudPermissions':_0x52d75f[_0xc7cafb('0x243c')]});}function _0x402964(_0x17c2ce){const _0xc37783=_0xa5f7a6;if(_0x2d725b[_0xc37783('0x1ac6')]('admin'))_0x5587a1['go']('app.contactmanager.contacts',{'CompanyId':_0x17c2ce['id']});else return _0x3e0bff[_0xc37783('0x17aa')][_0xc37783('0xd83')]({'userProfileId':_0x2d725b[_0xc37783('0x26cd')]()[_0xc37783('0xb86')],'sectionId':0x12f})[_0xc37783('0xa44')][_0xc37783('0x1166')](function(_0x387021){const _0x205ce3=_0xc37783,_0x59d8f0=_0x387021&&_0x387021[_0x205ce3('0x269a')]?_0x387021[_0x205ce3('0x269a')][0x0]:null;_0x59d8f0&&_0x59d8f0[_0x205ce3('0xc27')]?_0x5587a1['go'](_0x205ce3('0x1275'),{'CompanyId':_0x17c2ce['id']}):_0xb9b1c9[_0x205ce3('0x1fa1')]({'title':_0x54c4f6[_0x205ce3('0x25cc')](_0x205ce3('0x627')),'msg':_0x54c4f6['instant'](_0x205ce3('0x2642'))});})[_0xc37783('0x1a80')](function(_0x593ae7){const _0x10b8ea=_0xc37783;_0xb9b1c9[_0x10b8ea('0xfc9')]({'title':_0x593ae7[_0x10b8ea('0x52d')]?_0x10b8ea('0x1e21')+_0x593ae7[_0x10b8ea('0x52d')]+'\x20-\x20'+_0x593ae7['statusText']:_0x10b8ea('0x153e'),'msg':_0x593ae7[_0x10b8ea('0x52d')]?JSON[_0x10b8ea('0xbac')](_0x593ae7[_0x10b8ea('0x25f4')]):_0x593ae7['toString']()});});}function _0x5cf244(_0x27642b,_0x6c9c4d){const _0x491d3e=_0xa5f7a6,_0x2da8c8=_0x5ef11c[_0x491d3e('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x491d3e('0xb35')](_0x491d3e('0x11d8'))+'?')['htmlContent'](''+(_0x27642b[_0x491d3e('0x4f0')]||_0x491d3e('0x11d8'))+''+'\x20will\x20be\x20deleted.')[_0x491d3e('0x8e8')](_0x491d3e('0x1ada'))[_0x491d3e('0x203b')](_0x6c9c4d)['ok']('OK')[_0x491d3e('0x3f')]('CANCEL');_0x5ef11c[_0x491d3e('0x1f80')](_0x2da8c8)[_0x491d3e('0x1166')](function(){_0xe0924d(_0x27642b);},function(){const _0x1f1eef=_0x491d3e;console[_0x1f1eef('0x455')](_0x1f1eef('0x2d3'));});}let _0x5584d9=!![],_0x1735e1=0x1;_0x1023fe[_0xa5f7a6('0xe83')]('vm.query.filter',function(_0x46d2fa,_0x1b9cc7){const _0x5d9abf=_0xa5f7a6;_0x5584d9?_0x2a5103(function(){_0x5584d9=![];}):(!_0x1b9cc7&&(_0x1735e1=_0x52d75f[_0x5d9abf('0x2218')]['page']),_0x46d2fa!==_0x1b9cc7&&(_0x52d75f[_0x5d9abf('0x2218')][_0x5d9abf('0x1a43')]=0x1),!_0x46d2fa&&(_0x52d75f[_0x5d9abf('0x2218')][_0x5d9abf('0x1a43')]=_0x1735e1),_0x52d75f['getCompanies']());});function _0x129ef0(_0x5ed2fd){const _0x516026=_0xa5f7a6;_0x52d75f[_0x516026('0xfd1')]=_0x5ed2fd||{'count':0x0,'rows':[]};}function _0x383f25(){const _0x398490=_0xa5f7a6;_0x52d75f[_0x398490('0x2218')][_0x398490('0x1098')]=(_0x52d75f[_0x398490('0x2218')]['page']-0x1)*_0x52d75f[_0x398490('0x2218')][_0x398490('0x163f')],_0x2d725b[_0x398490('0x1ac6')](_0x398490('0xa7c'))?_0x52d75f[_0x398490('0x1f48')]=_0x3e0bff[_0x398490('0xc39')]['get'](_0x52d75f[_0x398490('0x2218')],_0x129ef0)[_0x398490('0xa44')]:(_0x52d75f[_0x398490('0x2218')]['id']=_0x52d75f[_0x398490('0x7f')]['id'],_0x52d75f[_0x398490('0x2218')][_0x398490('0xe60')]=_0x398490('0x117'),_0x52d75f['promise']=_0x3e0bff[_0x398490('0x7f')][_0x398490('0x263a')](_0x52d75f[_0x398490('0x2218')],_0x129ef0)[_0x398490('0xa44')]);}function _0x234c50(_0x4dd906,_0x38bb5d){const _0x32f503=_0xa5f7a6;_0x5ef11c[_0x32f503('0x1f80')]({'controller':_0x32f503('0x1d6c'),'controllerAs':'vm','templateUrl':_0x37e232,'parent':angular['element'](_0x69f6de[_0x32f503('0x8d2')]),'targetEvent':_0x4dd906,'clickOutsideToClose':!![],'locals':{'company':_0x38bb5d,'companies':_0x52d75f[_0x32f503('0xfd1')][_0x32f503('0x269a')],'license':_0x52d75f['license'],'setting':_0x52d75f[_0x32f503('0xf8a')],'crudPermissions':_0x52d75f[_0x32f503('0x243c')]}});}function _0xe0924d(_0x1a2118){const _0x2ef20c=_0xa5f7a6;_0x3e0bff[_0x2ef20c('0xc39')][_0x2ef20c('0x906')]({'id':_0x1a2118['id']})[_0x2ef20c('0xa44')][_0x2ef20c('0x1166')](function(){const _0x384a55=_0x2ef20c;_0x2cfb05()['remove'](_0x52d75f[_0x384a55('0xfd1')][_0x384a55('0x269a')],{'id':_0x1a2118['id']}),_0x52d75f[_0x384a55('0xfd1')][_0x384a55('0x240f')]-=0x1,!_0x52d75f['companies'][_0x384a55('0x269a')]['length']&&_0x52d75f['getCompanies'](),_0xb9b1c9[_0x384a55('0x103b')]({'title':_0x2cfb05()[_0x384a55('0xb35')](_0x384a55('0xb82'))+_0x384a55('0x2b6'),'msg':_0x1a2118[_0x384a55('0x4f0')]?_0x1a2118[_0x384a55('0x4f0')]+_0x384a55('0x7cd'):''});})[_0x2ef20c('0x1a80')](function(_0x351444){const _0x575250=_0x2ef20c;if(_0x351444[_0x575250('0x25f4')]&&_0x351444[_0x575250('0x25f4')][_0x575250('0x61a')]&&_0x351444[_0x575250('0x25f4')]['errors'][_0x575250('0x264b')]){_0x52d75f[_0x575250('0x61a')]=_0x351444[_0x575250('0x25f4')][_0x575250('0x61a')]||[{'message':_0x351444[_0x575250('0x1586')](),'type':_0x575250('0x119d')}];for(let _0x461398=0x0;_0x461398<_0x351444[_0x575250('0x25f4')]['errors'][_0x575250('0x264b')];_0x461398++){_0xb9b1c9[_0x575250('0xfc9')]({'title':_0x351444['data']['errors'][_0x461398][_0x575250('0x1345')],'msg':_0x351444['data'][_0x575250('0x61a')][_0x461398][_0x575250('0x1e70')]});}}else _0xb9b1c9[_0x575250('0xfc9')]({'title':_0x351444[_0x575250('0x52d')]?'API:'+_0x351444['status']+'\x20-\x20'+_0x351444[_0x575250('0xe1b')]:'SYSTEM:DELETEcmCompany','msg':_0x351444[_0x575250('0x25f4')]?JSON[_0x575250('0xbac')](_0x351444[_0x575250('0x25f4')]['message']):_0x351444[_0x575250('0x1e70')]||_0x351444[_0x575250('0x1586')]()});});}function _0xb730b3(){const _0x3af661=_0xa5f7a6,_0x638fc8=angular['copy'](_0x52d75f['selectedCompanies']);return _0x52d75f[_0x3af661('0x20b1')]=[],_0x638fc8;}function _0x364e9a(_0x29fe74){const _0xbeadee=_0xa5f7a6,_0x37aff3=_0x5ef11c['confirm']()[_0xbeadee('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20companies?')[_0xbeadee('0xf3c')](_0xbeadee('0x12b5')+_0x52d75f['selectedCompanies'][_0xbeadee('0x264b')]+_0xbeadee('0x196d')+'\x20will\x20be\x20deleted.')['ariaLabel']('delete\x20Companys')[_0xbeadee('0x203b')](_0x29fe74)['ok']('OK')[_0xbeadee('0x3f')](_0xbeadee('0x2d3'));_0x5ef11c['show'](_0x37aff3)[_0xbeadee('0x1166')](function(){const _0x114abe=_0xbeadee;_0x52d75f[_0x114abe('0x20b1')]['forEach'](function(_0x47db01){_0xe0924d(_0x47db01);}),_0x52d75f['selectedCompanies']=[];});}function _0x432bdc(){const _0x78766c=_0xa5f7a6;_0x52d75f[_0x78766c('0x20b1')]=[];}function _0x27abae(){const _0x2df12c=_0xa5f7a6;_0x52d75f['selectedCompanies']=_0x52d75f[_0x2df12c('0xfd1')][_0x2df12c('0x269a')];}}const _0x5bda5f=_0x47cf9a;_0x223ca3[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),'companies','company',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x223ca3(_0xf46b22,_0x1c1e77,_0xccef05,_0x183a09,_0x3d529c,_0x596c2a,_0x3b151d,_0x14905c,_0x54dbb7,_0x3a5cd8,_0x29adb7,_0x49dcbe,_0x35de7c,_0x21a05a){const _0x11c806=_0x36e6f4,_0x2a1e23=this;_0x2a1e23[_0x11c806('0x98')]=_0x29adb7[_0x11c806('0x26cd')](),_0x2a1e23[_0x11c806('0x61a')]=[],_0x2a1e23[_0x11c806('0xf8a')]=_0x35de7c,_0x2a1e23[_0x11c806('0x5c9')]=_0x49dcbe,_0x2a1e23[_0x11c806('0x243c')]=_0x21a05a,_0x2a1e23[_0x11c806('0x128b')]={},_0x2a1e23[_0x11c806('0x2900')]=_0x2a1e23[_0x11c806('0xf8a')]&&_0x2a1e23[_0x11c806('0xf8a')][_0x11c806('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2a1e23[_0x11c806('0xcdc')]=_0x11c806('0xfc3'),_0x2a1e23[_0x11c806('0x11d8')]=angular[_0x11c806('0x225f')](_0x54dbb7),_0x2a1e23[_0x11c806('0xfd1')]=_0x14905c,_0x2a1e23[_0x11c806('0x106d')]=![];!_0x2a1e23['company']&&(_0x2a1e23[_0x11c806('0x11d8')]={},_0x2a1e23[_0x11c806('0xcdc')]=_0x11c806('0x261e'),_0x2a1e23[_0x11c806('0x106d')]=!![]);_0x2a1e23[_0x11c806('0x1df7')]=_0x5051cf,_0x2a1e23[_0x11c806('0x1d3b')]=_0x2faa8d,_0x2a1e23[_0x11c806('0x49c')]=_0xecf40f,_0x2a1e23['getDateFromString']=_0x2fe14d,_0x2a1e23[_0x11c806('0x24a0')]=_0x49ad05;function _0x5051cf(){const _0x383cb7=_0x11c806;_0x2a1e23[_0x383cb7('0x61a')]=[],_0x3a5cd8[_0x383cb7('0xc39')][_0x383cb7('0x9cc')](_0x2a1e23[_0x383cb7('0x11d8')])[_0x383cb7('0xa44')][_0x383cb7('0x1166')](function(_0x113329){const _0x3f2581=_0x383cb7;_0x2a1e23[_0x3f2581('0xfd1')]['unshift'](_0x113329[_0x3f2581('0x2876')]()),_0x3b151d[_0x3f2581('0x103b')]({'title':_0x3f2581('0x23b4'),'msg':_0x2a1e23[_0x3f2581('0x11d8')][_0x3f2581('0x4f0')]?_0x2a1e23['company']['name']+_0x3f2581('0x1eda'):''}),_0x49ad05(_0x113329);})[_0x383cb7('0x1a80')](function(_0x50567b){const _0x5b33ad=_0x383cb7;if(_0x50567b[_0x5b33ad('0x25f4')]&&_0x50567b[_0x5b33ad('0x25f4')]['errors']&&_0x50567b[_0x5b33ad('0x25f4')][_0x5b33ad('0x61a')][_0x5b33ad('0x264b')]){_0x2a1e23[_0x5b33ad('0x61a')]=_0x50567b[_0x5b33ad('0x25f4')][_0x5b33ad('0x61a')]||[{'message':_0x50567b['toString'](),'type':_0x5b33ad('0x1a3c')}];for(let _0x5c15d4=0x0;_0x5c15d4<_0x50567b[_0x5b33ad('0x25f4')]['errors'][_0x5b33ad('0x264b')];_0x5c15d4+=0x1){_0x3b151d[_0x5b33ad('0xfc9')]({'title':_0x50567b['data']['errors'][_0x5c15d4][_0x5b33ad('0x1345')],'msg':_0x50567b[_0x5b33ad('0x25f4')][_0x5b33ad('0x61a')][_0x5c15d4][_0x5b33ad('0x1e70')]});}}else _0x3b151d[_0x5b33ad('0xfc9')]({'title':_0x50567b[_0x5b33ad('0x52d')]?_0x5b33ad('0x1e21')+_0x50567b[_0x5b33ad('0x52d')]+_0x5b33ad('0x11e1')+_0x50567b[_0x5b33ad('0xe1b')]:_0x5b33ad('0x1a3c'),'msg':_0x50567b['data']?JSON[_0x5b33ad('0xbac')](_0x50567b[_0x5b33ad('0x25f4')][_0x5b33ad('0x1e70')]):_0x50567b['toString']()});});}function _0x2faa8d(){const _0x545cb7=_0x11c806;_0x2a1e23[_0x545cb7('0x61a')]=[],_0x3a5cd8['cmCompany'][_0x545cb7('0x1449')]({'id':_0x2a1e23[_0x545cb7('0x11d8')]['id']},_0x2a1e23[_0x545cb7('0x11d8')])[_0x545cb7('0xa44')][_0x545cb7('0x1166')](function(_0x417527){const _0x54e843=_0x545cb7,_0x2aa625=_0x2cfb05()[_0x54e843('0xc38')](_0x2a1e23[_0x54e843('0xfd1')],{'id':_0x417527['id']});_0x2aa625&&_0x2cfb05()[_0x54e843('0xcc3')](_0x2aa625,_0x2cfb05()['pick'](_0x417527[_0x54e843('0x2876')](),_0x2cfb05()[_0x54e843('0x14a4')](_0x2aa625))),_0x3b151d[_0x54e843('0x103b')]({'title':_0x54e843('0x1069'),'msg':_0x2a1e23[_0x54e843('0x11d8')][_0x54e843('0x4f0')]?_0x2a1e23[_0x54e843('0x11d8')][_0x54e843('0x4f0')]+_0x54e843('0x7d'):''}),_0x49ad05(_0x417527);})[_0x545cb7('0x1a80')](function(_0x1d8a0c){const _0x28d44a=_0x545cb7;if(_0x1d8a0c['data']&&_0x1d8a0c[_0x28d44a('0x25f4')][_0x28d44a('0x61a')]&&_0x1d8a0c[_0x28d44a('0x25f4')]['errors'][_0x28d44a('0x264b')]){_0x2a1e23[_0x28d44a('0x61a')]=_0x1d8a0c[_0x28d44a('0x25f4')][_0x28d44a('0x61a')]||[{'message':_0x1d8a0c['toString'](),'type':_0x28d44a('0x2295')}];for(let _0x3be2ec=0x0;_0x3be2ec<_0x1d8a0c['data'][_0x28d44a('0x61a')][_0x28d44a('0x264b')];_0x3be2ec++){_0x3b151d[_0x28d44a('0xfc9')]({'title':_0x1d8a0c[_0x28d44a('0x25f4')][_0x28d44a('0x61a')][_0x3be2ec][_0x28d44a('0x1345')],'msg':_0x1d8a0c[_0x28d44a('0x25f4')][_0x28d44a('0x61a')][_0x3be2ec][_0x28d44a('0x1e70')]});}}else _0x3b151d['error']({'title':_0x1d8a0c[_0x28d44a('0x52d')]?_0x28d44a('0x1e21')+_0x1d8a0c['status']+'\x20-\x20'+_0x1d8a0c[_0x28d44a('0xe1b')]:_0x28d44a('0x2295'),'msg':_0x1d8a0c['data']?JSON[_0x28d44a('0xbac')](_0x1d8a0c[_0x28d44a('0x25f4')][_0x28d44a('0x1e70')]):_0x1d8a0c['toString']()});});}function _0xecf40f(_0x514e0e){const _0x5e79ca=_0x11c806;_0x2a1e23[_0x5e79ca('0x61a')]=[];const _0x41e701=_0x183a09['confirm']()[_0x5e79ca('0xcdc')](_0x5e79ca('0x7fb'))[_0x5e79ca('0xacc')](_0x5e79ca('0x11c4'))[_0x5e79ca('0x8e8')](_0x5e79ca('0x675'))['ok'](_0x5e79ca('0x18'))['cancel']('Cancel')['targetEvent'](_0x514e0e);_0x183a09['show'](_0x41e701)['then'](function(){const _0x2cf787=_0x5e79ca;_0x3a5cd8[_0x2cf787('0xc39')][_0x2cf787('0x906')]({'id':_0x2a1e23[_0x2cf787('0x11d8')]['id']})[_0x2cf787('0xa44')][_0x2cf787('0x1166')](function(){const _0x4906f8=_0x2cf787;_0x2cfb05()[_0x4906f8('0x127f')](_0x2a1e23[_0x4906f8('0xfd1')],{'id':_0x2a1e23[_0x4906f8('0x11d8')]['id']}),_0x3b151d[_0x4906f8('0x103b')]({'title':_0x4906f8('0x1b18'),'msg':(_0x2a1e23[_0x4906f8('0x11d8')]['name']||_0x4906f8('0x11d8'))+_0x4906f8('0x7cd')}),_0x49ad05(_0x2a1e23['company']);})[_0x2cf787('0x1a80')](function(_0x484e1f){const _0x1d5522=_0x2cf787;if(_0x484e1f[_0x1d5522('0x25f4')]&&_0x484e1f[_0x1d5522('0x25f4')]['errors']&&_0x484e1f[_0x1d5522('0x25f4')]['errors'][_0x1d5522('0x264b')]){_0x2a1e23[_0x1d5522('0x61a')]=_0x484e1f[_0x1d5522('0x25f4')]['errors']||[{'message':_0x484e1f[_0x1d5522('0x1586')](),'type':_0x1d5522('0x1e1b')}];for(let _0x37bd9a=0x0;_0x37bd9a<_0x484e1f[_0x1d5522('0x25f4')][_0x1d5522('0x61a')]['length'];_0x37bd9a++){_0x3b151d[_0x1d5522('0xfc9')]({'title':_0x484e1f[_0x1d5522('0x25f4')][_0x1d5522('0x61a')][_0x37bd9a]['type'],'msg':_0x484e1f[_0x1d5522('0x25f4')][_0x1d5522('0x61a')][_0x37bd9a][_0x1d5522('0x1e70')]});}}else _0x3b151d[_0x1d5522('0xfc9')]({'title':_0x484e1f['status']?_0x1d5522('0x1e21')+_0x484e1f[_0x1d5522('0x52d')]+_0x1d5522('0x11e1')+_0x484e1f[_0x1d5522('0xe1b')]:'api.cmCompany.delete','msg':_0x484e1f['data']?JSON[_0x1d5522('0xbac')](_0x484e1f[_0x1d5522('0x25f4')][_0x1d5522('0x1e70')]):_0x484e1f[_0x1d5522('0x1e70')]||_0x484e1f['toString']()});});},function(){});}function _0x2fe14d(_0x1cd072){return _0x1cd072===null?undefined:new Date(_0x1cd072);}function _0x49ad05(_0x5b9028){const _0x3bc7e1=_0x11c806;_0x183a09[_0x3bc7e1('0x1197')](_0x5b9028);}}const _0x3e8b39=_0x223ca3;_0x559b31[_0x36e6f4('0x1294')]=['$state','$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$translate',_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'company','userProfileSection'];function _0x559b31(_0x2002f3,_0xbd6ce5,_0x29fea3,_0x35989e,_0x1e570b,_0x4ad693,_0x19e090,_0x115d63,_0x41f48b,_0x3ac7c4,_0x512690,_0x20853b){const _0x475e14=_0x36e6f4,_0x437955=this;_0x437955[_0x475e14('0x98')]=_0x3ac7c4[_0x475e14('0x26cd')](),_0x437955[_0x475e14('0x5c9')]=_0x4ad693,_0x437955['setting']=_0x19e090,_0x437955[_0x475e14('0x2900')]=_0x437955['setting'][_0x475e14('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x437955[_0x475e14('0x246b')]=_0xbd6ce5[_0x475e14('0x6f1')]()+_0x475e14('0xc51')+_0xbd6ce5['host'](),_0x437955['company']=_0x512690||_0x2002f3[_0x475e14('0x23f')][_0x475e14('0x11d8')]||{},_0x437955[_0x475e14('0x17aa')]=_0x20853b&&_0x20853b[_0x475e14('0x240f')]==0x1?_0x20853b[_0x475e14('0x269a')][0x0]:null,_0x437955[_0x475e14('0x243c')]=_0x3ac7c4['parseCrudPermissions'](_0x437955[_0x475e14('0x17aa')]?_0x437955[_0x475e14('0x17aa')][_0x475e14('0x243c')]:null),_0x437955[_0x475e14('0x128b')]={},_0x437955[_0x475e14('0x2669')]=_0x2002f3['params'][_0x475e14('0xbe3')]||0x0,_0x437955['gotogoto']=_0x5092b2,_0x437955[_0x475e14('0x31d')]=_0x41f48b[_0x475e14('0x1fa1')],_0x437955[_0x475e14('0x1d6e')]=_0x312698,_0x437955[_0x475e14('0x1d3b')]=_0x6d132d;function _0x5092b2(_0xbfb4c2){const _0x323880=_0x475e14;if(_0x3ac7c4[_0x323880('0x1ac6')](_0x323880('0xa7c')))_0x2002f3['go']('app.contactmanager.contacts',{'CompanyId':_0xbfb4c2['id']});else return _0x115d63['userProfileSection'][_0x323880('0xd83')]({'userProfileId':_0x3ac7c4[_0x323880('0x26cd')]()[_0x323880('0xb86')],'sectionId':0x12f})[_0x323880('0xa44')]['then'](function(_0x183d37){const _0x8d3828=_0x323880,_0x2c5fa5=_0x183d37&&_0x183d37[_0x8d3828('0x269a')]?_0x183d37[_0x8d3828('0x269a')][0x0]:null;_0x2c5fa5&&_0x2c5fa5[_0x8d3828('0xc27')]?_0x2002f3['go']('app.contactmanager.contacts',{'CompanyId':_0xbfb4c2['id']}):_0x41f48b[_0x8d3828('0x1fa1')]({'title':_0x1e570b['instant'](_0x8d3828('0x627')),'msg':_0x1e570b[_0x8d3828('0x25cc')](_0x8d3828('0x2642'))});})[_0x323880('0x1a80')](function(_0x5007bd){const _0x4dd195=_0x323880;_0x41f48b['error']({'title':_0x5007bd[_0x4dd195('0x52d')]?_0x4dd195('0x1e21')+_0x5007bd[_0x4dd195('0x52d')]+'\x20-\x20'+_0x5007bd[_0x4dd195('0xe1b')]:'USERPROFILE:GET_SECTION','msg':_0x5007bd['status']?JSON[_0x4dd195('0xbac')](_0x5007bd['data']):_0x5007bd[_0x4dd195('0x1586')]()});});}function _0x312698(){const _0x5ec48f=_0x475e14;_0x2002f3['go'](_0x5ec48f('0x1af0'),{},{'reload':_0x5ec48f('0x1af0')});}function _0x6d132d(){const _0xc771be=_0x475e14;_0x115d63[_0xc771be('0xc39')]['update']({'id':_0x437955['company']['id']},_0x437955[_0xc771be('0x11d8')])[_0xc771be('0xa44')][_0xc771be('0x1166')](function(){const _0x4e6e3f=_0xc771be;_0x41f48b[_0x4e6e3f('0x103b')]({'title':_0x4e6e3f('0x143a'),'msg':_0x437955[_0x4e6e3f('0x11d8')][_0x4e6e3f('0x4f0')]?_0x437955[_0x4e6e3f('0x11d8')]['name']+'\x20has\x20been\x20updated!':''});})['catch'](function(_0x544eaa){const _0x11d725=_0xc771be;_0x41f48b[_0x11d725('0xfc9')]({'title':_0x544eaa[_0x11d725('0x52d')]?_0x11d725('0x1e21')+_0x544eaa[_0x11d725('0x52d')]+_0x11d725('0x11e1')+_0x544eaa['statusText']:_0x11d725('0x23fc'),'msg':_0x544eaa[_0x11d725('0x25f4')]?JSON[_0x11d725('0xbac')](_0x544eaa[_0x11d725('0x25f4')]):_0x544eaa['toString']()});});}}const _0x408ea3=_0x559b31;_0x366f50['$inject']=['$scope',_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'globalCustomFields',_0x36e6f4('0xf3d'),'api','Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x366f50(_0x4d550a,_0x1ecabe,_0x34bc54,_0x280a58,_0x41122b,_0x4dfa0a,_0x2874d6,_0x2982e7,_0x3f666c,_0x1fd622,_0x1fdc0e,_0x2d41f7,_0x12e291,_0x391969){const _0x13d77c=_0x36e6f4,_0x40e75a=this;_0x40e75a[_0x13d77c('0x98')]=_0x1fdc0e[_0x13d77c('0x26cd')](),_0x40e75a[_0x13d77c('0x61a')]=[],_0x40e75a[_0x13d77c('0xf8a')]=_0x12e291,_0x40e75a[_0x13d77c('0x5c9')]=_0x2d41f7,_0x40e75a[_0x13d77c('0x243c')]=_0x391969,_0x40e75a[_0x13d77c('0x128b')]={},_0x40e75a[_0x13d77c('0x2900')]=_0x40e75a[_0x13d77c('0xf8a')]&&_0x40e75a[_0x13d77c('0xf8a')][_0x13d77c('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x40e75a['title']=_0x13d77c('0x1234'),_0x40e75a[_0x13d77c('0x1e89')]={'animation':0x320,'sort':!![],'onSort':function(){const _0x2a82e3=_0x13d77c;_0x4d550a[_0x2a82e3('0x28ad')][_0x2a82e3('0x514')]=![];}},_0x40e75a[_0x13d77c('0xf3d')]=_0x3f666c,_0x40e75a['globalCustomFields']=_0x2982e7,_0x40e75a[_0x13d77c('0x1122')]=![];!_0x40e75a[_0x13d77c('0xf3d')]&&(_0x40e75a[_0x13d77c('0xf3d')]={'type':_0x13d77c('0x1640'),'actionType':_0x13d77c('0x21da')},_0x40e75a[_0x13d77c('0xcdc')]=_0x13d77c('0x233e'),_0x40e75a[_0x13d77c('0x1122')]=!![]);_0x4d550a[_0x13d77c('0xe83')](_0x13d77c('0x8dc'),function(_0x5956a5,_0x51cb93){const _0x31cf52=_0x13d77c;if(_0x5956a5!==_0x51cb93)switch(_0x5956a5){case _0x31cf52('0x1640'):_0x40e75a[_0x31cf52('0xf3d')]['values']='';break;case _0x31cf52('0x88a'):_0x40e75a[_0x31cf52('0xf3d')][_0x31cf52('0x1ac1')]=[];break;default:}}),_0x40e75a[_0x13d77c('0xc4b')]=_0x21c3cd,_0x40e75a[_0x13d77c('0x21d8')]=_0xc90b93,_0x40e75a[_0x13d77c('0x1faf')]=_0x5c2c13,_0x40e75a[_0x13d77c('0x1a9c')]=_0x1c1bc5,_0x40e75a[_0x13d77c('0x28ab')]=_0x4dee4f,_0x40e75a[_0x13d77c('0x214f')]=_0x5eed91,_0x40e75a[_0x13d77c('0x2196')]=_0x4738fa,_0x40e75a[_0x13d77c('0x24a0')]=_0x1c4935;function _0x4dee4f(_0x4fa543){const _0x4e26c7=_0x13d77c;_0x4fa543['push']({'value':_0x4e26c7('0x201f')}),_0x4d550a[_0x4e26c7('0x28ad')]['$pristine']=![];}function _0x5eed91(_0x303577,_0x25a701){const _0x9227c=_0x13d77c;_0x303577[_0x9227c('0x57b')](_0x25a701,0x1),_0x4d550a[_0x9227c('0x28ad')][_0x9227c('0x514')]=![];}function _0x4738fa(_0x5078f9){const _0x214045=_0x13d77c,_0x2e520f=_0x5078f9[_0x214045('0x264b')];for(let _0x575dc8=0x0;_0x575dc8<_0x2e520f;_0x575dc8++){_0x5078f9[_0x214045('0x57b')](0x0,0x1);}_0x4d550a[_0x214045('0x28ad')][_0x214045('0x514')]=![];}function _0x21c3cd(){const _0x20fbe5=_0x13d77c;_0x40e75a[_0x20fbe5('0x61a')]=[],_0x1fd622[_0x20fbe5('0x300')][_0x20fbe5('0x9cc')](_0x40e75a['globalCustomField'])[_0x20fbe5('0xa44')][_0x20fbe5('0x1166')](function(_0x135aac){const _0x5287c6=_0x20fbe5;_0x40e75a['globalCustomFields'][_0x5287c6('0x2450')](_0x135aac[_0x5287c6('0x2876')]()),_0x2874d6['success']({'title':_0x5287c6('0x25c7'),'msg':_0x40e75a[_0x5287c6('0xf3d')][_0x5287c6('0x4f0')]?_0x40e75a[_0x5287c6('0xf3d')][_0x5287c6('0x4f0')]+_0x5287c6('0x1eda'):''}),_0x1c4935(_0x135aac);})[_0x20fbe5('0x1a80')](function(_0x33795d){const _0x4c8296=_0x20fbe5;if(_0x33795d['data']&&_0x33795d[_0x4c8296('0x25f4')]['errors']&&_0x33795d[_0x4c8296('0x25f4')][_0x4c8296('0x61a')][_0x4c8296('0x264b')]){_0x40e75a[_0x4c8296('0x61a')]=_0x33795d[_0x4c8296('0x25f4')][_0x4c8296('0x61a')]||[{'message':_0x33795d[_0x4c8296('0x1586')](),'type':_0x4c8296('0xa4b')}];for(let _0x3c4166=0x0;_0x3c4166<_0x33795d[_0x4c8296('0x25f4')][_0x4c8296('0x61a')][_0x4c8296('0x264b')];_0x3c4166+=0x1){_0x2874d6['error']({'title':_0x33795d['data'][_0x4c8296('0x61a')][_0x3c4166][_0x4c8296('0x1345')],'msg':_0x33795d[_0x4c8296('0x25f4')][_0x4c8296('0x61a')][_0x3c4166]['message']});}}else _0x2874d6[_0x4c8296('0xfc9')]({'title':_0x33795d[_0x4c8296('0x52d')]?_0x4c8296('0x1e21')+_0x33795d[_0x4c8296('0x52d')]+_0x4c8296('0x11e1')+_0x33795d['statusText']:_0x4c8296('0xa4b'),'msg':_0x33795d[_0x4c8296('0x25f4')]?JSON[_0x4c8296('0xbac')](_0x33795d['data'][_0x4c8296('0x1e70')]):_0x33795d[_0x4c8296('0x1586')]()});});}function _0xc90b93(){const _0x3188e5=_0x13d77c;_0x40e75a[_0x3188e5('0x61a')]=[],_0x1fd622[_0x3188e5('0x300')][_0x3188e5('0x1449')]({'id':_0x40e75a[_0x3188e5('0xf3d')]['id']},_0x40e75a[_0x3188e5('0xf3d')])[_0x3188e5('0xa44')][_0x3188e5('0x1166')](function(_0x455e54){const _0x5375f4=_0x3188e5,_0xb65725=_0x2cfb05()['find'](_0x40e75a[_0x5375f4('0xc00')],{'id':_0x455e54['id']});_0xb65725&&_0x2cfb05()[_0x5375f4('0xcc3')](_0xb65725,_0x2cfb05()[_0x5375f4('0x1a08')](_0x455e54['toJSON'](),_0x2cfb05()['keys'](_0xb65725))),_0x2874d6['success']({'title':_0x5375f4('0xae3'),'msg':_0x40e75a[_0x5375f4('0xf3d')][_0x5375f4('0x4f0')]?_0x40e75a[_0x5375f4('0xf3d')][_0x5375f4('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x1c4935(_0x455e54);})[_0x3188e5('0x1a80')](function(_0x5eb61a){const _0x165fb1=_0x3188e5;if(_0x5eb61a[_0x165fb1('0x25f4')]&&_0x5eb61a['data'][_0x165fb1('0x61a')]&&_0x5eb61a['data']['errors'][_0x165fb1('0x264b')]){_0x40e75a[_0x165fb1('0x61a')]=_0x5eb61a[_0x165fb1('0x25f4')]['errors']||[{'message':_0x5eb61a[_0x165fb1('0x1586')](),'type':_0x165fb1('0x179b')}];for(let _0x3320bc=0x0;_0x3320bc<_0x5eb61a['data'][_0x165fb1('0x61a')][_0x165fb1('0x264b')];_0x3320bc++){_0x2874d6['error']({'title':_0x5eb61a[_0x165fb1('0x25f4')][_0x165fb1('0x61a')][_0x3320bc][_0x165fb1('0x1345')],'msg':_0x5eb61a[_0x165fb1('0x25f4')][_0x165fb1('0x61a')][_0x3320bc][_0x165fb1('0x1e70')]});}}else _0x2874d6[_0x165fb1('0xfc9')]({'title':_0x5eb61a[_0x165fb1('0x52d')]?_0x165fb1('0x1e21')+_0x5eb61a[_0x165fb1('0x52d')]+_0x165fb1('0x11e1')+_0x5eb61a['statusText']:_0x165fb1('0x179b'),'msg':_0x5eb61a[_0x165fb1('0x25f4')]?JSON['stringify'](_0x5eb61a['data'][_0x165fb1('0x1e70')]):_0x5eb61a[_0x165fb1('0x1586')]()});});}function _0x5c2c13(_0x305410){const _0x1e067d=_0x13d77c;_0x40e75a[_0x1e067d('0x61a')]=[];const _0x577aa5=_0x280a58['confirm']()[_0x1e067d('0xcdc')](_0x1e067d('0x7fb'))['content']('The\x20globalCustomField\x20will\x20be\x20deleted.')['ariaLabel'](_0x1e067d('0x2023'))['ok'](_0x1e067d('0x18'))[_0x1e067d('0x3f')](_0x1e067d('0x497'))[_0x1e067d('0x203b')](_0x305410);_0x280a58[_0x1e067d('0x1f80')](_0x577aa5)[_0x1e067d('0x1166')](function(){const _0x4486b0=_0x1e067d;_0x1fd622['cmCustomField'][_0x4486b0('0x906')]({'id':_0x40e75a[_0x4486b0('0xf3d')]['id']})[_0x4486b0('0xa44')]['then'](function(){const _0x160637=_0x4486b0;_0x2cfb05()[_0x160637('0x127f')](_0x40e75a['globalCustomFields'],{'id':_0x40e75a[_0x160637('0xf3d')]['id']}),_0x2874d6[_0x160637('0x103b')]({'title':_0x160637('0xfd7'),'msg':(_0x40e75a[_0x160637('0xf3d')][_0x160637('0x4f0')]||_0x160637('0xf3d'))+'\x20has\x20been\x20deleted!'}),_0x1c4935(_0x40e75a[_0x160637('0xf3d')]);})[_0x4486b0('0x1a80')](function(_0x313b57){const _0x3e595e=_0x4486b0;if(_0x313b57[_0x3e595e('0x25f4')]&&_0x313b57[_0x3e595e('0x25f4')][_0x3e595e('0x61a')]&&_0x313b57[_0x3e595e('0x25f4')][_0x3e595e('0x61a')]['length']){_0x40e75a[_0x3e595e('0x61a')]=_0x313b57[_0x3e595e('0x25f4')][_0x3e595e('0x61a')]||[{'message':_0x313b57[_0x3e595e('0x1586')](),'type':_0x3e595e('0x115f')}];for(let _0xd65fcc=0x0;_0xd65fcc<_0x313b57[_0x3e595e('0x25f4')]['errors'][_0x3e595e('0x264b')];_0xd65fcc++){_0x2874d6[_0x3e595e('0xfc9')]({'title':_0x313b57['data']['errors'][_0xd65fcc][_0x3e595e('0x1345')],'msg':_0x313b57[_0x3e595e('0x25f4')][_0x3e595e('0x61a')][_0xd65fcc]['message']});}}else _0x2874d6[_0x3e595e('0xfc9')]({'title':_0x313b57['status']?'API:'+_0x313b57['status']+'\x20-\x20'+_0x313b57[_0x3e595e('0xe1b')]:_0x3e595e('0x115f'),'msg':_0x313b57[_0x3e595e('0x25f4')]?JSON[_0x3e595e('0xbac')](_0x313b57['data']['message']):_0x313b57[_0x3e595e('0x1e70')]||_0x313b57['toString']()});});},function(){});}function _0x1c1bc5(_0xb1059c){return _0xb1059c===null?undefined:new Date(_0xb1059c);}function _0x1c4935(_0x18a334){const _0x55370a=_0x13d77c;_0x280a58[_0x55370a('0x1197')](_0x18a334);}}const _0x250cb1=_0x366f50,_0x170887=_0x2734b2['p']+'src/js/modules/main/apps/contactmanager/views/globalCustomFields/create/dialog.html/dialog.html';_0x53e3e2[_0x36e6f4('0x1294')]=['$scope','$window','$state',_0x36e6f4('0xc46'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0xc00'),_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x53e3e2(_0x523648,_0x36a787,_0x1fa008,_0x1428b2,_0x15b909,_0x40efeb,_0x9e36bb,_0xf5741d,_0x279570,_0xff0ddd,_0x443373,_0x3c0e10,_0x735831,_0x456dcc,_0x2164d4,_0x13ab32,_0x2a56e6){const _0x1b183e=_0x36e6f4,_0x532606=this;_0x532606[_0x1b183e('0x5c9')]=_0x13ab32,_0x532606[_0x1b183e('0xf8a')]=_0x2a56e6,_0x532606[_0x1b183e('0x98')]=_0x2164d4['getCurrentUser'](),_0x532606[_0x1b183e('0xc00')]=_0x279570||{'count':0x0,'rows':[]},_0x532606[_0x1b183e('0x7f')]=_0xff0ddd,_0x532606[_0x1b183e('0x17aa')]=_0x443373&&_0x443373[_0x1b183e('0x240f')]==0x1?_0x443373['rows'][0x0]:null,_0x532606[_0x1b183e('0x243c')]=_0x2164d4[_0x1b183e('0xd87')](_0x532606[_0x1b183e('0x17aa')]?_0x532606['userProfileSection'][_0x1b183e('0x243c')]:null),_0x532606[_0x1b183e('0x916')]=_0x1b183e('0xc00'),_0x532606[_0x1b183e('0xef5')]='',_0x532606['listOrderAsc']=null,_0x532606[_0x1b183e('0xb95')]=[],_0x532606[_0x1b183e('0x2218')]={'fields':_0x1b183e('0x263f'),'sort':_0x1b183e('0x14dc'),'ListId':_0x1b183e('0x15d7'),'limit':0xa,'page':0x1},_0x532606['arraytype']=_0x2cfb05()[_0x1b183e('0x155c')]([{'option':_0x1b183e('0xef7'),'value':_0x1b183e('0x64a')},{'option':_0x1b183e('0x260d'),'value':_0x1b183e('0xb07')},{'option':_0x1b183e('0x223'),'value':_0x1b183e('0x16ef')},{'option':'Switch','value':_0x1b183e('0x1dad')},{'option':'Datetime','value':'\x27datetime\x27'}],function(_0x902c35){const _0x1b961e=_0x1b183e;return _0x2cfb05()[_0x1b961e('0xf3')](_0x902c35['value'],new RegExp('\x27','g'),'');}),_0x532606[_0x1b183e('0x1c2f')]=_0x2cfb05()['keyBy']([{'option':_0x1b183e('0x334'),'value':_0x1b183e('0x1a83')}],function(_0xb043ff){const _0x38587e=_0x1b183e;return _0x2cfb05()[_0x38587e('0xf3')](_0xb043ff[_0x38587e('0x18e0')],new RegExp('\x27','g'),'');}),_0x532606[_0x1b183e('0x1f8e')]=_0x127116,_0x532606['deleteconfirm']=_0x2a6eb5,_0x532606[_0x1b183e('0x103b')]=_0x476b7c,_0x532606[_0x1b183e('0xe7c')]=_0x3912ad,_0x532606['createOrEditGlobalCustomField']=_0x44fa39,_0x532606[_0x1b183e('0x1faf')]=_0x37caff,_0x532606[_0x1b183e('0x11ab')]=_0x2259b0,_0x532606[_0x1b183e('0x22bb')]=_0x3144d3,_0x532606[_0x1b183e('0x143f')]=_0x19b26b,_0x532606[_0x1b183e('0x2400')]=_0x1ebef1;function _0x127116(_0x285e1e,_0x10f3ed){const _0x24cb54=_0x1b183e;_0x15b909[_0x24cb54('0x1f80')]({'controller':_0x24cb54('0x1833'),'controllerAs':'vm','templateUrl':_0x170887,'parent':angular[_0x24cb54('0x1194')](_0x40efeb[_0x24cb54('0x8d2')]),'targetEvent':_0x10f3ed,'clickOutsideToClose':!![],'locals':{'globalCustomField':_0x285e1e,'globalCustomFields':_0x532606[_0x24cb54('0xc00')][_0x24cb54('0x269a')],'license':_0x532606[_0x24cb54('0x5c9')],'setting':null,'crudPermissions':_0x532606[_0x24cb54('0x243c')]}});}function _0x2a6eb5(_0xc77c45,_0x317d32){const _0x12532b=_0x1b183e,_0x1bc3a0=_0x15b909[_0x12532b('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()['startCase'](_0x12532b('0xf3d'))+'?')['htmlContent'](''+(_0xc77c45[_0x12532b('0x4f0')]||_0x12532b('0xf3d'))+_0x12532b('0xace')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x12532b('0x1334'))[_0x12532b('0x203b')](_0x317d32)['ok']('OK')[_0x12532b('0x3f')]('CANCEL');_0x15b909[_0x12532b('0x1f80')](_0x1bc3a0)[_0x12532b('0x1166')](function(){_0x37caff(_0xc77c45);},function(){const _0x2f4363=_0x12532b;console['log'](_0x2f4363('0x2d3'));});}let _0x316151=!![],_0x2aab5a=0x1;_0x523648['$watch'](_0x1b183e('0x12d8'),function(_0x45a256,_0x31f2eb){const _0x34daa5=_0x1b183e;_0x316151?_0x9e36bb(function(){_0x316151=![];}):(!_0x31f2eb&&(_0x2aab5a=_0x532606[_0x34daa5('0x2218')][_0x34daa5('0x1a43')]),_0x45a256!==_0x31f2eb&&(_0x532606[_0x34daa5('0x2218')]['page']=0x1),!_0x45a256&&(_0x532606[_0x34daa5('0x2218')][_0x34daa5('0x1a43')]=_0x2aab5a),_0x532606[_0x34daa5('0xe7c')]());});function _0x476b7c(_0x2276a4){const _0x30f4fc=_0x1b183e;_0x532606[_0x30f4fc('0xc00')]=_0x2276a4||{'count':0x0,'rows':[]};}function _0x3912ad(){const _0x251306=_0x1b183e;_0x532606[_0x251306('0x2218')]['offset']=(_0x532606['query'][_0x251306('0x1a43')]-0x1)*_0x532606[_0x251306('0x2218')][_0x251306('0x163f')],_0x2164d4[_0x251306('0x1ac6')](_0x251306('0xa7c'))?_0x532606[_0x251306('0x1f48')]=_0x3c0e10[_0x251306('0x300')]['get'](_0x532606[_0x251306('0x2218')],_0x476b7c)[_0x251306('0xa44')]:(_0x532606[_0x251306('0x2218')]['id']=_0x532606[_0x251306('0x7f')]['id'],_0x532606['query'][_0x251306('0xe60')]=_0x251306('0x17f9'),_0x532606[_0x251306('0x1f48')]=_0x3c0e10['userProfile'][_0x251306('0x263a')](_0x532606['query'],_0x476b7c)[_0x251306('0xa44')]);}function _0x44fa39(_0x4ff5da,_0x4be24b){const _0x230f35=_0x1b183e;_0x15b909['show']({'controller':'CreateOrEditGlobalCustomFieldDialogController','controllerAs':'vm','templateUrl':_0x170887,'parent':angular[_0x230f35('0x1194')](_0x40efeb['body']),'targetEvent':_0x4ff5da,'clickOutsideToClose':!![],'locals':{'globalCustomField':_0x4be24b,'globalCustomFields':_0x532606['globalCustomFields']['rows'],'license':_0x532606['license'],'setting':_0x532606[_0x230f35('0xf8a')],'crudPermissions':_0x532606[_0x230f35('0x243c')]}});}function _0x37caff(_0x36a143){const _0x19a2ce=_0x1b183e;_0x3c0e10[_0x19a2ce('0x300')]['delete']({'id':_0x36a143['id']})['$promise'][_0x19a2ce('0x1166')](function(){const _0x51ccb2=_0x19a2ce;_0x2cfb05()['remove'](_0x532606[_0x51ccb2('0xc00')]['rows'],{'id':_0x36a143['id']}),_0x532606[_0x51ccb2('0xc00')][_0x51ccb2('0x240f')]-=0x1,!_0x532606[_0x51ccb2('0xc00')]['rows'][_0x51ccb2('0x264b')]&&_0x532606[_0x51ccb2('0xe7c')](),_0x456dcc[_0x51ccb2('0x103b')]({'title':_0x2cfb05()[_0x51ccb2('0xb35')]('GlobalCustomField')+_0x51ccb2('0x2b6'),'msg':_0x36a143[_0x51ccb2('0x4f0')]?_0x36a143[_0x51ccb2('0x4f0')]+_0x51ccb2('0x7cd'):''});})[_0x19a2ce('0x1a80')](function(_0x22e5dc){const _0x417321=_0x19a2ce;if(_0x22e5dc[_0x417321('0x25f4')]&&_0x22e5dc[_0x417321('0x25f4')][_0x417321('0x61a')]&&_0x22e5dc[_0x417321('0x25f4')]['errors']['length']){_0x532606[_0x417321('0x61a')]=_0x22e5dc[_0x417321('0x25f4')][_0x417321('0x61a')]||[{'message':_0x22e5dc['toString'](),'type':'SYSTEM:DELETEcmCustomField'}];for(let _0xb2ba21=0x0;_0xb2ba21<_0x22e5dc['data'][_0x417321('0x61a')]['length'];_0xb2ba21++){_0x456dcc[_0x417321('0xfc9')]({'title':_0x22e5dc[_0x417321('0x25f4')][_0x417321('0x61a')][_0xb2ba21][_0x417321('0x1345')],'msg':_0x22e5dc[_0x417321('0x25f4')]['errors'][_0xb2ba21]['message']});}}else _0x456dcc[_0x417321('0xfc9')]({'title':_0x22e5dc['status']?'API:'+_0x22e5dc['status']+'\x20-\x20'+_0x22e5dc[_0x417321('0xe1b')]:_0x417321('0xd27'),'msg':_0x22e5dc[_0x417321('0x25f4')]?JSON[_0x417321('0xbac')](_0x22e5dc[_0x417321('0x25f4')][_0x417321('0x1e70')]):_0x22e5dc[_0x417321('0x1e70')]||_0x22e5dc[_0x417321('0x1586')]()});});}function _0x2259b0(){const _0x364a05=angular['copy'](_0x532606['selectedGlobalCustomFields']);return _0x532606['selectedGlobalCustomFields']=[],_0x364a05;}function _0x3144d3(_0xdea464){const _0x570fea=_0x1b183e,_0x5e0773=_0x15b909[_0x570fea('0x1d26')]()[_0x570fea('0xcdc')](_0x570fea('0x625'))[_0x570fea('0xf3c')](''+_0x532606[_0x570fea('0xb95')][_0x570fea('0x264b')]+_0x570fea('0x196d')+_0x570fea('0x3f3'))[_0x570fea('0x8e8')](_0x570fea('0x1bb9'))[_0x570fea('0x203b')](_0xdea464)['ok']('OK')[_0x570fea('0x3f')](_0x570fea('0x2d3'));_0x15b909[_0x570fea('0x1f80')](_0x5e0773)[_0x570fea('0x1166')](function(){const _0x2fb22c=_0x570fea;_0x532606[_0x2fb22c('0xb95')][_0x2fb22c('0x2782')](function(_0x55de57){_0x37caff(_0x55de57);}),_0x532606['selectedGlobalCustomFields']=[];});}function _0x19b26b(){const _0x2e78f8=_0x1b183e;_0x532606[_0x2e78f8('0xb95')]=[];}function _0x1ebef1(){const _0x3fe44c=_0x1b183e;_0x532606[_0x3fe44c('0xb95')]=_0x532606[_0x3fe44c('0xc00')][_0x3fe44c('0x269a')];}}const _0xa67cc0=_0x53e3e2;_0x315640[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x8de'),_0x36e6f4('0x1480'),'api','Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'crudPermissions'];function _0x315640(_0x784a7b,_0x562cba,_0x2cc2e0,_0x578638,_0x55fb4d,_0x13c291,_0x20aa54,_0x4b1b49,_0x4fc222,_0x3ea59a,_0x46fd41,_0x4ea372,_0x233e73,_0x289546){const _0x31f064=_0x36e6f4,_0x484f9d=this;_0x484f9d[_0x31f064('0x98')]=_0x46fd41[_0x31f064('0x26cd')](),_0x484f9d[_0x31f064('0x61a')]=[],_0x484f9d[_0x31f064('0xf8a')]=_0x233e73,_0x484f9d[_0x31f064('0x5c9')]=_0x4ea372,_0x484f9d[_0x31f064('0x243c')]=_0x289546,_0x484f9d['hasModulePermissions']={},_0x484f9d['passwordPattern']=_0x484f9d[_0x31f064('0xf8a')]&&_0x484f9d[_0x31f064('0xf8a')][_0x31f064('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x484f9d[_0x31f064('0xcdc')]=_0x31f064('0x1394'),_0x484f9d[_0x31f064('0x1480')]=angular['copy'](_0x4fc222),_0x484f9d['lists']=_0x4b1b49,_0x484f9d[_0x31f064('0x157e')]=![];!_0x484f9d['list']&&(_0x484f9d[_0x31f064('0x1480')]={},_0x484f9d['title']='CONTACTMANAGER.NEW_LIST',_0x484f9d[_0x31f064('0x157e')]=!![]);_0x484f9d[_0x31f064('0x2199')]=_0x4012b5,_0x484f9d[_0x31f064('0x2859')]=_0x25a796,_0x484f9d[_0x31f064('0x165b')]=_0x2f2640,_0x484f9d['getDateFromString']=_0x2bf243,_0x484f9d['closeDialog']=_0xb7ef4;function _0x4012b5(){const _0x42ab50=_0x31f064;_0x484f9d['errors']=[],_0x3ea59a[_0x42ab50('0xdd9')]['save'](_0x484f9d[_0x42ab50('0x1480')])[_0x42ab50('0xa44')][_0x42ab50('0x1166')](function(_0x42a4a8){const _0x6fc3a5=_0x42ab50;_0x484f9d['lists'][_0x6fc3a5('0x2450')](_0x42a4a8[_0x6fc3a5('0x2876')]()),_0x20aa54['success']({'title':'List\x20properly\x20created','msg':_0x484f9d[_0x6fc3a5('0x1480')][_0x6fc3a5('0x4f0')]?_0x484f9d[_0x6fc3a5('0x1480')][_0x6fc3a5('0x4f0')]+_0x6fc3a5('0x1eda'):''}),_0xb7ef4(_0x42a4a8);})[_0x42ab50('0x1a80')](function(_0x1fc1e9){const _0x25c1c4=_0x42ab50;if(_0x1fc1e9[_0x25c1c4('0x25f4')]&&_0x1fc1e9[_0x25c1c4('0x25f4')][_0x25c1c4('0x61a')]&&_0x1fc1e9[_0x25c1c4('0x25f4')][_0x25c1c4('0x61a')][_0x25c1c4('0x264b')]){_0x484f9d[_0x25c1c4('0x61a')]=_0x1fc1e9[_0x25c1c4('0x25f4')][_0x25c1c4('0x61a')]||[{'message':_0x1fc1e9['toString'](),'type':_0x25c1c4('0x671')}];for(let _0x16ecdd=0x0;_0x16ecdd<_0x1fc1e9['data'][_0x25c1c4('0x61a')][_0x25c1c4('0x264b')];_0x16ecdd+=0x1){_0x20aa54['error']({'title':_0x1fc1e9[_0x25c1c4('0x25f4')][_0x25c1c4('0x61a')][_0x16ecdd][_0x25c1c4('0x1345')],'msg':_0x1fc1e9[_0x25c1c4('0x25f4')]['errors'][_0x16ecdd][_0x25c1c4('0x1e70')]});}}else _0x20aa54[_0x25c1c4('0xfc9')]({'title':_0x1fc1e9['status']?'API:'+_0x1fc1e9[_0x25c1c4('0x52d')]+_0x25c1c4('0x11e1')+_0x1fc1e9['statusText']:_0x25c1c4('0x671'),'msg':_0x1fc1e9['data']?JSON['stringify'](_0x1fc1e9[_0x25c1c4('0x25f4')][_0x25c1c4('0x1e70')]):_0x1fc1e9[_0x25c1c4('0x1586')]()});});}function _0x25a796(){const _0x4f2ca2=_0x31f064;_0x484f9d[_0x4f2ca2('0x61a')]=[],_0x3ea59a[_0x4f2ca2('0xdd9')][_0x4f2ca2('0x1449')]({'id':_0x484f9d[_0x4f2ca2('0x1480')]['id']},_0x484f9d[_0x4f2ca2('0x1480')])[_0x4f2ca2('0xa44')][_0x4f2ca2('0x1166')](function(_0xd24c5a){const _0x3c8a7c=_0x4f2ca2,_0x2cf57e=_0x2cfb05()['find'](_0x484f9d['lists'],{'id':_0xd24c5a['id']});_0x2cf57e&&_0x2cfb05()[_0x3c8a7c('0xcc3')](_0x2cf57e,_0x2cfb05()[_0x3c8a7c('0x1a08')](_0xd24c5a[_0x3c8a7c('0x2876')](),_0x2cfb05()[_0x3c8a7c('0x14a4')](_0x2cf57e))),_0x20aa54['success']({'title':_0x3c8a7c('0x2140'),'msg':_0x484f9d[_0x3c8a7c('0x1480')][_0x3c8a7c('0x4f0')]?_0x484f9d[_0x3c8a7c('0x1480')][_0x3c8a7c('0x4f0')]+_0x3c8a7c('0x7d'):''}),_0xb7ef4(_0xd24c5a);})['catch'](function(_0x58b671){const _0x18114d=_0x4f2ca2;if(_0x58b671[_0x18114d('0x25f4')]&&_0x58b671['data']['errors']&&_0x58b671[_0x18114d('0x25f4')][_0x18114d('0x61a')][_0x18114d('0x264b')]){_0x484f9d[_0x18114d('0x61a')]=_0x58b671['data'][_0x18114d('0x61a')]||[{'message':_0x58b671[_0x18114d('0x1586')](),'type':_0x18114d('0x1237')}];for(let _0x16f256=0x0;_0x16f256<_0x58b671[_0x18114d('0x25f4')][_0x18114d('0x61a')]['length'];_0x16f256++){_0x20aa54[_0x18114d('0xfc9')]({'title':_0x58b671['data'][_0x18114d('0x61a')][_0x16f256][_0x18114d('0x1345')],'msg':_0x58b671['data'][_0x18114d('0x61a')][_0x16f256][_0x18114d('0x1e70')]});}}else _0x20aa54['error']({'title':_0x58b671['status']?_0x18114d('0x1e21')+_0x58b671[_0x18114d('0x52d')]+'\x20-\x20'+_0x58b671[_0x18114d('0xe1b')]:_0x18114d('0x1237'),'msg':_0x58b671[_0x18114d('0x25f4')]?JSON[_0x18114d('0xbac')](_0x58b671[_0x18114d('0x25f4')][_0x18114d('0x1e70')]):_0x58b671[_0x18114d('0x1586')]()});});}function _0x2f2640(_0x5c827f){const _0x40da18=_0x31f064;_0x484f9d[_0x40da18('0x61a')]=[];const _0x36969c=_0x578638[_0x40da18('0x1d26')]()[_0x40da18('0xcdc')](_0x40da18('0x7fb'))[_0x40da18('0xacc')]('The\x20list\x20will\x20be\x20deleted.')[_0x40da18('0x8e8')](_0x40da18('0x2834'))['ok'](_0x40da18('0x18'))[_0x40da18('0x3f')]('Cancel')[_0x40da18('0x203b')](_0x5c827f);_0x578638[_0x40da18('0x1f80')](_0x36969c)[_0x40da18('0x1166')](function(){const _0x188d3b=_0x40da18;_0x3ea59a[_0x188d3b('0xdd9')][_0x188d3b('0x906')]({'id':_0x484f9d['list']['id']})['$promise'][_0x188d3b('0x1166')](function(){const _0xf87f00=_0x188d3b;_0x2cfb05()[_0xf87f00('0x127f')](_0x484f9d[_0xf87f00('0x8de')],{'id':_0x484f9d[_0xf87f00('0x1480')]['id']}),_0x20aa54[_0xf87f00('0x103b')]({'title':_0xf87f00('0x28f4'),'msg':(_0x484f9d[_0xf87f00('0x1480')][_0xf87f00('0x4f0')]||_0xf87f00('0x1480'))+'\x20has\x20been\x20deleted!'}),_0xb7ef4(_0x484f9d[_0xf87f00('0x1480')]);})[_0x188d3b('0x1a80')](function(_0x157db9){const _0x151316=_0x188d3b;if(_0x157db9['data']&&_0x157db9[_0x151316('0x25f4')]['errors']&&_0x157db9['data'][_0x151316('0x61a')][_0x151316('0x264b')]){_0x484f9d[_0x151316('0x61a')]=_0x157db9[_0x151316('0x25f4')]['errors']||[{'message':_0x157db9[_0x151316('0x1586')](),'type':_0x151316('0x60c')}];for(let _0x345130=0x0;_0x345130<_0x157db9[_0x151316('0x25f4')][_0x151316('0x61a')][_0x151316('0x264b')];_0x345130++){_0x20aa54[_0x151316('0xfc9')]({'title':_0x157db9[_0x151316('0x25f4')]['errors'][_0x345130]['type'],'msg':_0x157db9[_0x151316('0x25f4')][_0x151316('0x61a')][_0x345130]['message']});}}else _0x20aa54[_0x151316('0xfc9')]({'title':_0x157db9[_0x151316('0x52d')]?'API:'+_0x157db9[_0x151316('0x52d')]+_0x151316('0x11e1')+_0x157db9[_0x151316('0xe1b')]:'api.cmList.delete','msg':_0x157db9[_0x151316('0x25f4')]?JSON['stringify'](_0x157db9[_0x151316('0x25f4')][_0x151316('0x1e70')]):_0x157db9['message']||_0x157db9[_0x151316('0x1586')]()});});},function(){});}function _0x2bf243(_0x5dea2b){return _0x5dea2b===null?undefined:new Date(_0x5dea2b);}function _0xb7ef4(_0x320990){const _0x175e4d=_0x31f064;_0x578638[_0x175e4d('0x1197')](_0x320990);}}const _0x10d064=_0x315640;_0x47922b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1480'),_0x36e6f4('0x8de'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x47922b(_0x3abe0d,_0x2d4076,_0x4752c3,_0x1ec952,_0x37eccd,_0x3ac3b4,_0x2ce064,_0x4380c1,_0x3b968d,_0x1bf660){const _0x5724b6=_0x36e6f4,_0x58ca91=this;_0x58ca91['currentUser']=_0x3b968d[_0x5724b6('0x26cd')](),_0x58ca91['list']=_0x37eccd,_0x58ca91[_0x5724b6('0x243c')]=_0x1bf660,_0x58ca91['realtime']=_0x2ce064,_0x58ca91[_0x5724b6('0xbd7')]=[],_0x58ca91[_0x5724b6('0x10ab')]=[],_0x58ca91[_0x5724b6('0x18e1')]=[],_0x58ca91[_0x5724b6('0x2111')]=[],_0x58ca91[_0x5724b6('0x2781')]=[],_0x58ca91['pendingChanges']=![],_0x58ca91[_0x5724b6('0xae0')]=_0x5b0908,_0x58ca91['saveAgents']=_0x25c202,_0x58ca91[_0x5724b6('0x24a0')]=_0x22a75f,_0x58ca91[_0x5724b6('0xc68')]={'readOnly':!_0x58ca91[_0x5724b6('0x243c')][_0x5724b6('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':'fullname','line2':[_0x5724b6('0x4f0'),_0x5724b6('0x1eef')],'line3':'','labelAll':_0x4380c1['instant'](_0x5724b6('0x1779')),'labelSelected':_0x4380c1[_0x5724b6('0x25cc')](_0x5724b6('0xd08')),'transferCallback':function(){const _0x2ffc7e=_0x5724b6,_0x4079a4=_0x2cfb05()[_0x2ffc7e('0x2802')](_0x58ca91[_0x2ffc7e('0x2781')],_0x58ca91['selectedItems'],'id');_0x58ca91[_0x2ffc7e('0x14d7')]=_0x2cfb05()['isEmpty'](_0x4079a4)?![]:!![];}};function _0x5b0908(){const _0x1041b7=_0x5724b6;return _0x3b968d['hasRole'](_0x1041b7('0xa7c'))?_0x209af1()[_0x1041b7('0x1a80')](function(_0x472525){const _0x28eddc=_0x1041b7;_0x4752c3['error']({'title':_0x472525['status']?'API:'+_0x472525['status']+_0x28eddc('0x11e1')+_0x472525[_0x28eddc('0xe1b')]:'SYSTEM:GET_AGENTS','msg':_0x472525['status']?JSON[_0x28eddc('0xbac')](_0x472525['data']):_0x472525['toString']()});}):_0x8058ca()['then'](function(_0x46fc08){const _0x8f697b=_0x1041b7;return _0x58ca91[_0x8f697b('0xe60')]=_0x46fc08,_0x209af1();})[_0x1041b7('0x1a80')](function(_0x56ec5c){const _0x4583f4=_0x1041b7;_0x4752c3['error']({'title':_0x56ec5c['status']?_0x4583f4('0x1e21')+_0x56ec5c[_0x4583f4('0x52d')]+'\x20-\x20'+_0x56ec5c['statusText']:'SYSTEM:GET_AGENTS','msg':_0x56ec5c[_0x4583f4('0x52d')]?JSON['stringify'](_0x56ec5c[_0x4583f4('0x25f4')]):_0x56ec5c[_0x4583f4('0x1586')]()});});}function _0x8058ca(){return _0x2d4076(function(_0x2b5b29,_0x4ab588){const _0x4d6e34=a0_0x3f2c;_0x1ec952['userProfileSection']['get']({'userProfileId':_0x58ca91[_0x4d6e34('0x98')][_0x4d6e34('0xb86')],'name':'Agents'})[_0x4d6e34('0xa44')][_0x4d6e34('0x1166')](function(_0x4581ec){const _0x18b471=_0x4d6e34,_0x2e76fc=_0x4581ec&&_0x4581ec[_0x18b471('0x269a')]?_0x4581ec[_0x18b471('0x269a')][0x0]:null;_0x2b5b29(_0x2e76fc);})[_0x4d6e34('0x1a80')](function(_0x2d046b){_0x4ab588(_0x2d046b);});});}function _0x209af1(){return _0x2d4076(function(_0x2a4e15,_0x2db155){const _0x3561d3=a0_0x3f2c;return _0x519ed4()[_0x3561d3('0x1166')](function(_0x1fdf0e){const _0x47d6c3=_0x3561d3;return _0x58ca91[_0x47d6c3('0xbd7')]=_0x1fdf0e[_0x47d6c3('0x269a')]?_0x1fdf0e[_0x47d6c3('0x269a')]:[],_0x3b968d[_0x47d6c3('0x1ac6')](_0x47d6c3('0xa7c'))?_0x1fdf0e:_0x58ca91['section']?_0x58ca91[_0x47d6c3('0xe60')][_0x47d6c3('0x1a2b')]?_0x1fdf0e:_0x18544a():null;})[_0x3561d3('0x1166')](function(_0x29a9ac){const _0x2f3bd9=_0x3561d3,_0xef347f=_0x29a9ac&&_0x29a9ac[_0x2f3bd9('0x269a')]?_0x29a9ac[_0x2f3bd9('0x269a')]:[];return _0x58ca91['allowedItems']=_0x2cfb05()[_0x2f3bd9('0x2563')](_0xef347f,function(_0x433ba9){const _0x158f7c=_0x2f3bd9;return _0x2cfb05()[_0x158f7c('0xc38')](_0x58ca91['items'],{'id':_0x3b968d[_0x158f7c('0x1ac6')]('admin')||_0x58ca91[_0x158f7c('0xe60')][_0x158f7c('0x1a2b')]?_0x433ba9['id']:_0x433ba9[_0x158f7c('0x24e8')]});}),_0x58ca91[_0x2f3bd9('0x2111')]=angular[_0x2f3bd9('0x225f')](_0x58ca91[_0x2f3bd9('0x10ab')]),_0x58ca91['items'][_0x2f3bd9('0x2782')](function(_0x4f95ba){const _0x88c096=_0x2f3bd9,_0x43af01=_0x2cfb05()[_0x88c096('0xc38')](_0x58ca91[_0x88c096('0x10ab')],{'id':_0x4f95ba['id']});_0x3b968d[_0x88c096('0x1ac6')](_0x88c096('0xa7c'))?_0x4f95ba['isValid']=!![]:_0x4f95ba[_0x88c096('0x26ef')]=typeof _0x43af01!=='undefined'?!![]:![];}),_0x16c94a();})[_0x3561d3('0x1166')](function(_0x2cd1c3){const _0x8f8d02=_0x3561d3,_0x46d35b=_0x2cd1c3&&_0x2cd1c3[_0x8f8d02('0x269a')]?_0x2cd1c3['rows']:[];_0x58ca91[_0x8f8d02('0x18e1')]=_0x2cfb05()[_0x8f8d02('0x2563')](_0x46d35b,function(_0x349547){const _0xdab450=_0x8f8d02,_0x453391=_0x2cfb05()[_0xdab450('0xc38')](_0x58ca91['items'],{'id':_0x349547['id']});return _0x453391['penalty']=_0x349547[_0xdab450('0x1ca')]?_0xdab450('0x11e8')+_0x349547[_0xdab450('0x1ca')][_0xdab450('0x23af')]:'',_0x453391[_0xdab450('0x1eef')]=typeof _0x349547[_0xdab450('0x1eef')]!==_0xdab450('0x1048')?'<'+_0x349547[_0xdab450('0x1eef')]+'>':'',_0x453391;}),_0x58ca91[_0x8f8d02('0x2781')]=angular[_0x8f8d02('0x225f')](_0x58ca91[_0x8f8d02('0x18e1')]),_0x58ca91[_0x8f8d02('0xc68')][_0x8f8d02('0x18e1')]=_0x58ca91[_0x8f8d02('0x18e1')],_0x58ca91[_0x8f8d02('0xc68')][_0x8f8d02('0xbd7')]=_0x2cfb05()['differenceBy'](_0x58ca91[_0x8f8d02('0x10ab')],_0x58ca91[_0x8f8d02('0xc68')][_0x8f8d02('0x18e1')],'id'),_0x2a4e15();})[_0x3561d3('0x1a80')](function(_0xc6d94b){_0x2db155(_0xc6d94b);});});}function _0x18544a(){return _0x2d4076(function(_0xd27071,_0x5f0869){const _0x16d2b2=a0_0x3f2c;return _0x1ec952[_0x16d2b2('0x4b5')][_0x16d2b2('0xd83')]({'sectionId':_0x58ca91[_0x16d2b2('0xe60')]['id'],'nolimit':!![]})['$promise'][_0x16d2b2('0x1166')](function(_0x4f9537){_0xd27071(_0x4f9537);})[_0x16d2b2('0x1a80')](function(_0x280a52){_0x5f0869(_0x280a52);});});}function _0x16c94a(){return _0x2d4076(function(_0x302293,_0x469c7b){const _0x280d8b=a0_0x3f2c;return _0x1ec952['cmList']['getAgents']({'id':_0x58ca91[_0x280d8b('0x1480')]['id'],'fields':_0x280d8b('0x1459'),'nolimit':!![],'role':_0x280d8b('0x1eff')})[_0x280d8b('0xa44')]['then'](function(_0x560570){_0x302293(_0x560570);})['catch'](function(_0x251340){_0x469c7b(_0x251340);});});}function _0x519ed4(){return _0x2d4076(function(_0x995d66,_0x3d85a9){const _0x17bea1=a0_0x3f2c;return _0x1ec952['user'][_0x17bea1('0xd83')]({'fields':'id,name,internal,fullname','nolimit':!![],'role':_0x17bea1('0x1eff')})[_0x17bea1('0xa44')][_0x17bea1('0x1166')](function(_0x96f817){_0x995d66(_0x96f817);})[_0x17bea1('0x1a80')](function(_0x1587a4){_0x3d85a9(_0x1587a4);});});}function _0x4f77f7(_0x51fc62){return _0x2d4076(function(_0x224ef8,_0x4fce0a){const _0x3eadaa=a0_0x3f2c;_0x2cfb05()['isEmpty'](_0x51fc62)?_0x224ef8():_0x1ec952[_0x3eadaa('0xdd9')]['addAgents']({'id':_0x58ca91['list']['id'],'ids':_0x2cfb05()[_0x3eadaa('0x2563')](_0x51fc62,'id')})['$promise'][_0x3eadaa('0x1166')](function(){_0x224ef8();})[_0x3eadaa('0x1a80')](function(_0x58f00d){_0x4fce0a(_0x58f00d);});});}function _0x12df47(_0x419921){return _0x2d4076(function(_0x39d8f7,_0x231cf4){const _0x10c143=a0_0x3f2c;_0x2cfb05()[_0x10c143('0x1081')](_0x419921)?_0x39d8f7():_0x1ec952[_0x10c143('0xdd9')][_0x10c143('0x269d')]({'id':_0x58ca91[_0x10c143('0x1480')]['id'],'ids':_0x2cfb05()[_0x10c143('0x2563')](_0x419921,'id')})[_0x10c143('0xa44')]['then'](function(){_0x39d8f7();})[_0x10c143('0x1a80')](function(_0xeb07e){_0x231cf4(_0xeb07e);});});}function _0x25c202(){const _0x870725=_0x5724b6,_0x18adf7=_0x2cfb05()['differenceBy'](_0x58ca91[_0x870725('0x2781')],_0x58ca91[_0x870725('0x18e1')],'id'),_0x4b7f2b=_0x2cfb05()['differenceBy'](_0x58ca91['selectedItems'],_0x58ca91[_0x870725('0x2781')],'id');return _0x12df47(_0x18adf7)[_0x870725('0x1166')](function(){return _0x4f77f7(_0x4b7f2b);})[_0x870725('0x1166')](function(){const _0x9591fc=_0x870725;_0x58ca91[_0x9591fc('0x14d7')]=![],_0x58ca91['startingAllowedItems']=angular['copy'](_0x58ca91[_0x9591fc('0x10ab')]),_0x58ca91[_0x9591fc('0x2781')]=angular[_0x9591fc('0x225f')](_0x58ca91[_0x9591fc('0x18e1')]),_0x4752c3[_0x9591fc('0x103b')]({'title':'SUCCESS','msg':_0x9591fc('0x1673')});})['catch'](function(_0x265d96){const _0x955435=_0x870725;_0x4752c3['error']({'title':_0x265d96[_0x955435('0x52d')]?'API:'+_0x265d96[_0x955435('0x52d')]+'\x20-\x20'+_0x265d96['statusText']:_0x955435('0x1b29'),'msg':_0x265d96[_0x955435('0x52d')]?JSON[_0x955435('0xbac')](_0x265d96[_0x955435('0x25f4')]):_0x265d96[_0x955435('0x1586')]()});});}function _0x22a75f(){const _0x3ba8a3=_0x5724b6;_0x3abe0d[_0x3ba8a3('0x1197')]();}}const _0x19a96f=_0x47922b,_0x40e5a1=_0x2734b2['p']+_0x36e6f4('0x101a');_0x2d2d7b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x2d2d7b(_0x5d33ab,_0x113207,_0x1d3f33,_0x2e5396,_0x145bf2,_0x3a690e,_0x1eec20,_0x4b0613,_0xb8e2e5,_0xb1e4e3,_0x5ca050){const _0x43f80e=_0x36e6f4,_0x1810a2=this;_0x1810a2[_0x43f80e('0x98')]=_0x5ca050['getCurrentUser'](),_0x1810a2['list']={},_0x1810a2[_0x43f80e('0x1eb8')]={'count':0x0,'rows':[]},_0x1810a2[_0x43f80e('0x2446')]=[],_0x1810a2[_0x43f80e('0x243c')],_0x1810a2['query']={'fields':_0x43f80e('0x263f'),'limit':0xa,'page':0x1},_0x1810a2['arraytype']=_0x2cfb05()[_0x43f80e('0x155c')]([{'option':_0x43f80e('0xef7'),'value':'\x27text\x27'},{'option':_0x43f80e('0x260d'),'value':_0x43f80e('0xb07')},{'option':_0x43f80e('0x223'),'value':_0x43f80e('0x16ef')},{'option':_0x43f80e('0x1f83'),'value':'\x27switch\x27'},{'option':_0x43f80e('0x38'),'value':_0x43f80e('0x2034')}],function(_0x582e21){const _0x3e8b57=_0x43f80e;return _0x2cfb05()[_0x3e8b57('0xf3')](_0x582e21[_0x3e8b57('0x18e0')],new RegExp('\x27','g'),'');}),_0x1810a2[_0x43f80e('0x1c2f')]=_0x2cfb05()[_0x43f80e('0x155c')]([{'option':_0x43f80e('0x334'),'value':_0x43f80e('0x1a83')}],function(_0x2d538d){const _0x468aa7=_0x43f80e;return _0x2cfb05()[_0x468aa7('0xf3')](_0x2d538d[_0x468aa7('0x18e0')],new RegExp('\x27','g'),'');}),_0x1810a2[_0x43f80e('0x24d5')]=_0x46287d,_0x1810a2[_0x43f80e('0x8a2')]=_0xb7f568,_0x1810a2[_0x43f80e('0x103b')]=_0x1c4f86,_0x1810a2[_0x43f80e('0x628')]=_0x3fe873,_0x1810a2[_0x43f80e('0x84b')]=_0xf3a1e,_0x1810a2[_0x43f80e('0x151f')]=_0x790488,_0x1810a2[_0x43f80e('0x12fd')]=_0x4ebf42,_0x1810a2[_0x43f80e('0x1749')]=_0x393ed4;function _0x46287d(_0x125659,_0x29f09b){const _0x5cfa64=_0x43f80e;_0x1810a2[_0x5cfa64('0x1480')]=_0x125659,_0x1810a2[_0x5cfa64('0x243c')]=typeof _0x29f09b!==_0x5cfa64('0x1048')?_0x29f09b:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1810a2[_0x5cfa64('0x2218')][_0x5cfa64('0x23c')]=_0x1810a2['list']['id'],_0x1810a2['query']['id']=_0x1810a2[_0x5cfa64('0x1480')]['id'],_0x3fe873();}function _0xb7f568(_0x5c6a01,_0x5242a2){const _0x5e5a03=_0x43f80e,_0x2a87b2=_0x1eec20[_0x5e5a03('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20customField?')[_0x5e5a03('0xf3c')](_0x5e5a03('0x12b5')+(_0x5c6a01['name']||_0x5c6a01['id']&&_0x2cfb05()[_0x5e5a03('0x114b')](_0x5e5a03('0x394'))+_0x5c6a01['id']||_0x5e5a03('0x117e'))+_0x5e5a03('0xace')+_0x5e5a03('0x3f3'))[_0x5e5a03('0x8e8')](_0x5e5a03('0x182'))['targetEvent'](_0x5242a2)['ok']('OK')[_0x5e5a03('0x3f')]('CANCEL');_0x1eec20[_0x5e5a03('0x1f80')](_0x2a87b2)[_0x5e5a03('0x1166')](function(){_0x4ebf42(_0x5c6a01);},function(){const _0x2a185a=_0x5e5a03;console['log'](_0x2a185a('0x2d3'));});}function _0x1c4f86(_0x2aa726){const _0x5887e1=_0x43f80e;_0x1810a2[_0x5887e1('0x1eb8')]=_0x2aa726||{'count':0x0,'rows':[]};}function _0x3fe873(){const _0x4cb1de=_0x43f80e;_0x1810a2[_0x4cb1de('0x2218')][_0x4cb1de('0x1098')]=(_0x1810a2[_0x4cb1de('0x2218')][_0x4cb1de('0x1a43')]-0x1)*_0x1810a2[_0x4cb1de('0x2218')][_0x4cb1de('0x163f')],_0x1810a2[_0x4cb1de('0x1f48')]=_0xb1e4e3[_0x4cb1de('0xdd9')]['getCustomFields'](_0x1810a2[_0x4cb1de('0x2218')],_0x1c4f86)[_0x4cb1de('0xa44')];}function _0xf3a1e(_0x58971c,_0x2d0b87){const _0x2578fb=_0x43f80e;_0x1eec20['show']({'controller':_0x2578fb('0x18e'),'controllerAs':'vm','templateUrl':_0x40e5a1,'parent':angular[_0x2578fb('0x1194')](_0x4b0613[_0x2578fb('0x8d2')]),'targetEvent':_0x58971c,'clickOutsideToClose':!![],'locals':{'list':_0x1810a2[_0x2578fb('0x1480')],'customField':_0x2d0b87,'customFields':_0x1810a2['listCustomFields'][_0x2578fb('0x269a')],'license':null,'setting':null,'crudPermissions':_0x1810a2['crudPermissions']}});}function _0x4ebf42(_0x5ea876){const _0x220fd2=_0x43f80e;_0xb1e4e3['cmCustomField'][_0x220fd2('0x906')]({'id':_0x5ea876['id']})['$promise'][_0x220fd2('0x1166')](function(){const _0x11901a=_0x220fd2;_0x2cfb05()[_0x11901a('0x127f')](_0x1810a2[_0x11901a('0x1eb8')]['rows'],{'id':_0x5ea876['id']}),_0x1810a2[_0x11901a('0x1eb8')][_0x11901a('0x240f')]-=0x1,!_0x1810a2[_0x11901a('0x1eb8')][_0x11901a('0x269a')][_0x11901a('0x264b')]&&_0x3fe873(),_0xb8e2e5[_0x11901a('0x103b')]({'title':'CustomField\x20deleted!','msg':_0x5ea876['name']?_0x5ea876['name']+'\x20has\x20been\x20deleted!':''});})[_0x220fd2('0x1a80')](function(_0x3acc90){const _0x2dd0d9=_0x220fd2;if(_0x3acc90[_0x2dd0d9('0x25f4')]&&_0x3acc90[_0x2dd0d9('0x25f4')][_0x2dd0d9('0x61a')]&&_0x3acc90[_0x2dd0d9('0x25f4')][_0x2dd0d9('0x61a')][_0x2dd0d9('0x264b')]){_0x1810a2['errors']=_0x3acc90['data'][_0x2dd0d9('0x61a')]||[{'message':_0x3acc90[_0x2dd0d9('0x1586')](),'type':_0x2dd0d9('0x23c9')}];for(let _0x28ab01=0x0;_0x28ab01<_0x3acc90['data'][_0x2dd0d9('0x61a')][_0x2dd0d9('0x264b')];_0x28ab01++){_0xb8e2e5['error']({'title':_0x3acc90[_0x2dd0d9('0x25f4')][_0x2dd0d9('0x61a')][_0x28ab01][_0x2dd0d9('0x1345')],'msg':_0x3acc90[_0x2dd0d9('0x25f4')][_0x2dd0d9('0x61a')][_0x28ab01][_0x2dd0d9('0x1e70')]});}}else _0xb8e2e5[_0x2dd0d9('0xfc9')]({'title':_0x3acc90['status']?_0x2dd0d9('0x1e21')+_0x3acc90[_0x2dd0d9('0x52d')]+_0x2dd0d9('0x11e1')+_0x3acc90[_0x2dd0d9('0xe1b')]:_0x2dd0d9('0x23c9'),'msg':_0x3acc90['data']?JSON[_0x2dd0d9('0xbac')](_0x3acc90[_0x2dd0d9('0x25f4')]['message']):_0x3acc90[_0x2dd0d9('0x1e70')]||_0x3acc90['toString']()});});}function _0x790488(){const _0x3680f2=_0x43f80e,_0x7be8b4=angular['copy'](_0x1810a2[_0x3680f2('0x2446')]);return _0x1810a2['selectedListCustomFields']=[],_0x7be8b4;}function _0x393ed4(_0x52d045){const _0x13f184=_0x43f80e,_0x41aa2d=_0x1eec20['confirm']()[_0x13f184('0xcdc')](_0x13f184('0x220a'))[_0x13f184('0xf3c')](_0x13f184('0x12b5')+_0x1810a2[_0x13f184('0x2446')]['length']+_0x13f184('0x196d')+_0x13f184('0x3f3'))[_0x13f184('0x8e8')](_0x13f184('0x2711'))[_0x13f184('0x203b')](_0x52d045)['ok']('OK')[_0x13f184('0x3f')](_0x13f184('0x2d3'));_0x1eec20[_0x13f184('0x1f80')](_0x41aa2d)[_0x13f184('0x1166')](function(){const _0x21c19d=_0x13f184;_0x1810a2[_0x21c19d('0x2446')][_0x21c19d('0x2782')](function(_0x36b500){_0x4ebf42(_0x36b500);}),_0x1810a2[_0x21c19d('0x2446')]=[];});}let _0x4ea5fe=!![],_0x339b06=0x1;_0x113207[_0x43f80e('0xe83')]('vm_dc.query.filter',function(_0x382234,_0x50c110){const _0x4d3637=_0x43f80e;_0x4ea5fe?_0x3a690e(function(){_0x4ea5fe=![];}):(!_0x50c110&&(_0x339b06=_0x1810a2[_0x4d3637('0x2218')][_0x4d3637('0x1a43')]),_0x382234!==_0x50c110&&(_0x1810a2['query'][_0x4d3637('0x1a43')]=0x1),!_0x382234&&(_0x1810a2[_0x4d3637('0x2218')][_0x4d3637('0x1a43')]=_0x339b06),_0x3fe873());});}const _0xb3d2b2=_0x2d2d7b;_0x23d6a5['$inject']=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate','toasty',_0x36e6f4('0x23d7'),_0x36e6f4('0x117e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x23d6a5(_0xffbd59,_0x174d48,_0x3518b2,_0x3793cf,_0x4afbe4,_0x313c3e,_0x804003,_0x2db222,_0x31d378,_0x12d77a,_0x2dc970,_0x45180a,_0x3862d4,_0x415ab5){const _0x5c1638=_0x36e6f4,_0x25c1d4=this;_0x25c1d4[_0x5c1638('0x98')]=_0x2dc970['getCurrentUser'](),_0x25c1d4['errors']=[],_0x25c1d4[_0x5c1638('0xf8a')]=_0x3862d4,_0x25c1d4[_0x5c1638('0x5c9')]=_0x45180a,_0x25c1d4[_0x5c1638('0x243c')]=_0x415ab5,_0x25c1d4['hasModulePermissions']={},_0x25c1d4[_0x5c1638('0x2900')]=_0x25c1d4[_0x5c1638('0xf8a')]&&_0x25c1d4['setting'][_0x5c1638('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x25c1d4['title']=_0x5c1638('0x2054'),_0x25c1d4['sortable']={'animation':0x320,'sort':!![],'onSort':function(){const _0x44bd46=_0x5c1638;_0xffbd59['customFieldForm'][_0x44bd46('0x514')]=![];}},_0x25c1d4[_0x5c1638('0x117e')]=_0x31d378,_0x25c1d4[_0x5c1638('0x23d7')]=_0x2db222,_0x25c1d4[_0x5c1638('0x251c')]=![];!_0x25c1d4[_0x5c1638('0x117e')]&&(_0x25c1d4[_0x5c1638('0x117e')]={'type':'text','actionType':'voice'},_0x25c1d4[_0x5c1638('0xcdc')]=_0x5c1638('0x198a'),_0x25c1d4['newCustomField']=!![]);_0x174d48[_0x5c1638('0x23f')]['id']&&(_0x25c1d4[_0x5c1638('0x117e')][_0x5c1638('0x23c')]=_0x174d48['params']['id']);_0xffbd59[_0x5c1638('0xe83')]('vm.customField.type',function(_0x12bb5b,_0x4093dc){const _0x1e17d9=_0x5c1638;if(_0x12bb5b!==_0x4093dc)switch(_0x12bb5b){case _0x1e17d9('0x1640'):_0x25c1d4['customField']['values']='';break;case'select':_0x25c1d4['customField'][_0x1e17d9('0x1ac1')]=[];break;default:}}),_0x25c1d4[_0x5c1638('0x255f')]=_0x3d1ca0,_0x25c1d4['saveCustomField']=_0x2c5ab9,_0x25c1d4['deleteCustomField']=_0x11dd57,_0x25c1d4[_0x5c1638('0x1a9c')]=_0x17d320,_0x25c1d4[_0x5c1638('0x28ab')]=_0x5b72a6,_0x25c1d4[_0x5c1638('0x214f')]=_0x56b5e7,_0x25c1d4[_0x5c1638('0x2196')]=_0xfeb5f2,_0x25c1d4[_0x5c1638('0x24a0')]=_0x177430;function _0x5b72a6(_0x2a2403){const _0x49d7e7=_0x5c1638;_0x2a2403[_0x49d7e7('0x1514')]({'value':_0x49d7e7('0x201f')}),_0xffbd59[_0x49d7e7('0xcda')][_0x49d7e7('0x514')]=![];}function _0x56b5e7(_0x32d87e,_0x497472){const _0x28ea8e=_0x5c1638;_0x32d87e[_0x28ea8e('0x57b')](_0x497472,0x1),_0xffbd59[_0x28ea8e('0xcda')][_0x28ea8e('0x514')]=![];}function _0xfeb5f2(_0x8b2371){const _0x47d453=_0x5c1638,_0x35a6c0=_0x8b2371['length'];for(let _0x45ccb6=0x0;_0x45ccb6<_0x35a6c0;_0x45ccb6++){_0x8b2371[_0x47d453('0x57b')](0x0,0x1);}_0xffbd59[_0x47d453('0xcda')][_0x47d453('0x514')]=![];}function _0x3d1ca0(){const _0x36d7a7=_0x5c1638;_0x25c1d4[_0x36d7a7('0x61a')]=[],_0x12d77a[_0x36d7a7('0xdd9')][_0x36d7a7('0x1026')]({'id':_0x174d48[_0x36d7a7('0x23f')]['id']},_0x25c1d4[_0x36d7a7('0x117e')])[_0x36d7a7('0xa44')][_0x36d7a7('0x1166')](function(_0x4d1b1a){const _0x435e50=_0x36d7a7;_0x25c1d4[_0x435e50('0x23d7')][_0x435e50('0x2450')](_0x4d1b1a[_0x435e50('0x2876')]()),_0x804003['success']({'title':'CustomField\x20properly\x20created','msg':_0x25c1d4[_0x435e50('0x117e')][_0x435e50('0x4f0')]?_0x25c1d4[_0x435e50('0x117e')]['name']+_0x435e50('0x1eda'):''}),_0x177430(_0x4d1b1a);})[_0x36d7a7('0x1a80')](function(_0x55118f){const _0x326679=_0x36d7a7;if(_0x55118f[_0x326679('0x25f4')]&&_0x55118f[_0x326679('0x25f4')][_0x326679('0x61a')]&&_0x55118f[_0x326679('0x25f4')][_0x326679('0x61a')][_0x326679('0x264b')]){_0x25c1d4[_0x326679('0x61a')]=_0x55118f[_0x326679('0x25f4')][_0x326679('0x61a')]||[{'message':_0x55118f[_0x326679('0x1586')](),'type':_0x326679('0xa4b')}];for(let _0x2739e2=0x0;_0x2739e2<_0x55118f[_0x326679('0x25f4')][_0x326679('0x61a')][_0x326679('0x264b')];_0x2739e2+=0x1){_0x804003[_0x326679('0xfc9')]({'title':_0x55118f[_0x326679('0x25f4')]['errors'][_0x2739e2]['type'],'msg':_0x55118f[_0x326679('0x25f4')][_0x326679('0x61a')][_0x2739e2][_0x326679('0x1e70')]});}}else _0x804003['error']({'title':_0x55118f[_0x326679('0x52d')]?_0x326679('0x1e21')+_0x55118f[_0x326679('0x52d')]+_0x326679('0x11e1')+_0x55118f[_0x326679('0xe1b')]:_0x326679('0xa4b'),'msg':_0x55118f[_0x326679('0x25f4')]?JSON[_0x326679('0xbac')](_0x55118f[_0x326679('0x25f4')][_0x326679('0x1e70')]):_0x55118f[_0x326679('0x1586')]()});});}function _0x2c5ab9(){const _0x3cb627=_0x5c1638;_0x25c1d4[_0x3cb627('0x61a')]=[],_0x12d77a['cmCustomField'][_0x3cb627('0x1449')]({'id':_0x25c1d4['customField']['id']},_0x25c1d4[_0x3cb627('0x117e')])[_0x3cb627('0xa44')][_0x3cb627('0x1166')](function(_0x287a81){const _0x38dfc4=_0x3cb627,_0x2904d3=_0x2cfb05()[_0x38dfc4('0xc38')](_0x25c1d4['customFields'],{'id':_0x287a81['id']});_0x2904d3&&_0x2cfb05()[_0x38dfc4('0xcc3')](_0x2904d3,_0x2cfb05()[_0x38dfc4('0x1a08')](_0x287a81[_0x38dfc4('0x2876')](),_0x2cfb05()[_0x38dfc4('0x14a4')](_0x2904d3))),_0x804003['success']({'title':'CustomField\x20properly\x20saved!','msg':_0x25c1d4[_0x38dfc4('0x117e')]['name']?_0x25c1d4[_0x38dfc4('0x117e')][_0x38dfc4('0x4f0')]+_0x38dfc4('0x7d'):''}),_0x177430(_0x287a81);})[_0x3cb627('0x1a80')](function(_0x3e2d3f){const _0x4b41c3=_0x3cb627;if(_0x3e2d3f[_0x4b41c3('0x25f4')]&&_0x3e2d3f[_0x4b41c3('0x25f4')][_0x4b41c3('0x61a')]&&_0x3e2d3f[_0x4b41c3('0x25f4')][_0x4b41c3('0x61a')][_0x4b41c3('0x264b')]){_0x25c1d4['errors']=_0x3e2d3f['data'][_0x4b41c3('0x61a')]||[{'message':_0x3e2d3f[_0x4b41c3('0x1586')](),'type':_0x4b41c3('0x179b')}];for(let _0x220542=0x0;_0x220542<_0x3e2d3f[_0x4b41c3('0x25f4')]['errors']['length'];_0x220542++){_0x804003[_0x4b41c3('0xfc9')]({'title':_0x3e2d3f[_0x4b41c3('0x25f4')][_0x4b41c3('0x61a')][_0x220542][_0x4b41c3('0x1345')],'msg':_0x3e2d3f['data'][_0x4b41c3('0x61a')][_0x220542][_0x4b41c3('0x1e70')]});}}else _0x804003['error']({'title':_0x3e2d3f[_0x4b41c3('0x52d')]?_0x4b41c3('0x1e21')+_0x3e2d3f['status']+_0x4b41c3('0x11e1')+_0x3e2d3f[_0x4b41c3('0xe1b')]:_0x4b41c3('0x179b'),'msg':_0x3e2d3f[_0x4b41c3('0x25f4')]?JSON[_0x4b41c3('0xbac')](_0x3e2d3f['data']['message']):_0x3e2d3f[_0x4b41c3('0x1586')]()});});}function _0x11dd57(_0x2a6b85){const _0x4a6d9=_0x5c1638;_0x25c1d4[_0x4a6d9('0x61a')]=[];const _0x1c2ca6=_0x3793cf[_0x4a6d9('0x1d26')]()[_0x4a6d9('0xcdc')](_0x4a6d9('0x7fb'))[_0x4a6d9('0xacc')](_0x4a6d9('0x551'))[_0x4a6d9('0x8e8')]('Delete\x20CustomField')['ok'](_0x4a6d9('0x18'))['cancel'](_0x4a6d9('0x497'))[_0x4a6d9('0x203b')](_0x2a6b85);_0x3793cf['show'](_0x1c2ca6)[_0x4a6d9('0x1166')](function(){const _0x2d94f5=_0x4a6d9;_0x12d77a[_0x2d94f5('0x300')][_0x2d94f5('0x906')]({'id':_0x25c1d4[_0x2d94f5('0x117e')]['id']})['$promise']['then'](function(){const _0x31d980=_0x2d94f5;_0x2cfb05()[_0x31d980('0x127f')](_0x25c1d4[_0x31d980('0x23d7')],{'id':_0x25c1d4[_0x31d980('0x117e')]['id']}),_0x804003[_0x31d980('0x103b')]({'title':_0x31d980('0x19f2'),'msg':(_0x25c1d4[_0x31d980('0x117e')][_0x31d980('0x4f0')]||_0x31d980('0x117e'))+_0x31d980('0x7cd')}),_0x177430(_0x25c1d4[_0x31d980('0x117e')]);})['catch'](function(_0x5c6098){const _0x11bb3a=_0x2d94f5;if(_0x5c6098[_0x11bb3a('0x25f4')]&&_0x5c6098[_0x11bb3a('0x25f4')][_0x11bb3a('0x61a')]&&_0x5c6098['data'][_0x11bb3a('0x61a')][_0x11bb3a('0x264b')]){_0x25c1d4[_0x11bb3a('0x61a')]=_0x5c6098[_0x11bb3a('0x25f4')][_0x11bb3a('0x61a')]||[{'message':_0x5c6098[_0x11bb3a('0x1586')](),'type':_0x11bb3a('0x115f')}];for(let _0x49a96f=0x0;_0x49a96f<_0x5c6098[_0x11bb3a('0x25f4')][_0x11bb3a('0x61a')][_0x11bb3a('0x264b')];_0x49a96f++){_0x804003[_0x11bb3a('0xfc9')]({'title':_0x5c6098['data'][_0x11bb3a('0x61a')][_0x49a96f]['type'],'msg':_0x5c6098['data'][_0x11bb3a('0x61a')][_0x49a96f][_0x11bb3a('0x1e70')]});}}else _0x804003['error']({'title':_0x5c6098[_0x11bb3a('0x52d')]?_0x11bb3a('0x1e21')+_0x5c6098['status']+_0x11bb3a('0x11e1')+_0x5c6098['statusText']:'api.cmCustomField.delete','msg':_0x5c6098[_0x11bb3a('0x25f4')]?JSON[_0x11bb3a('0xbac')](_0x5c6098['data'][_0x11bb3a('0x1e70')]):_0x5c6098[_0x11bb3a('0x1e70')]||_0x5c6098[_0x11bb3a('0x1586')]()});});},function(){});}function _0x17d320(_0x4a2503){return _0x4a2503===null?undefined:new Date(_0x4a2503);}function _0x177430(_0x43b87f){const _0x4d0b2d=_0x5c1638;_0x3793cf[_0x4d0b2d('0x1197')](_0x43b87f);}}const _0xc64799=_0x23d6a5,_0x117c30=_0x2734b2['p']+_0x36e6f4('0xafa');_0x3fb0a1[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$document',_0x36e6f4('0x586'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'list','userProfileSection'];function _0x3fb0a1(_0x460b8d,_0x1dc350,_0x46eccd,_0x5e819f,_0x336eaf,_0x388ae0,_0xd8815b,_0x1b68ff,_0xa4985a,_0x3368ca,_0x264921,_0x51a5a7){const _0x4051eb=_0x36e6f4,_0x1c7745=this;_0x1c7745[_0x4051eb('0x98')]=_0x3368ca[_0x4051eb('0x26cd')](),_0x1c7745[_0x4051eb('0x5c9')]=_0x388ae0,_0x1c7745[_0x4051eb('0xf8a')]=_0xd8815b,_0x1c7745[_0x4051eb('0x2900')]=_0x1c7745[_0x4051eb('0xf8a')][_0x4051eb('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1c7745[_0x4051eb('0x246b')]=_0x1dc350[_0x4051eb('0x6f1')]()+_0x4051eb('0xc51')+_0x1dc350[_0x4051eb('0x1690')](),_0x1c7745['list']=_0x264921||_0x460b8d[_0x4051eb('0x23f')][_0x4051eb('0x1480')]||{},_0x1c7745[_0x4051eb('0x17aa')]=_0x51a5a7&&_0x51a5a7['count']==0x1?_0x51a5a7['rows'][0x0]:null,_0x1c7745['crudPermissions']=_0x3368ca[_0x4051eb('0xd87')](_0x1c7745[_0x4051eb('0x17aa')]?_0x1c7745[_0x4051eb('0x17aa')]['crudPermissions']:null),_0x1c7745[_0x4051eb('0x128b')]={},_0x1c7745[_0x4051eb('0x2669')]=_0x460b8d[_0x4051eb('0x23f')]['tab']||0x0,_0x1c7745[_0x4051eb('0x22c1')]=_0x35f0bb,_0x1c7745[_0x4051eb('0x1728')]=_0x901e3a,_0x1c7745[_0x4051eb('0x31d')]=_0xa4985a[_0x4051eb('0x1fa1')],_0x1c7745[_0x4051eb('0x2507')]=_0xc7ee42,_0x1c7745[_0x4051eb('0x2859')]=_0x23e696;function _0x35f0bb(_0x156a71){const _0x11269a=_0x4051eb;if(_0x3368ca[_0x11269a('0x1ac6')](_0x11269a('0xa7c')))_0x460b8d['go']('app.contactmanager.contacts',{'ListId':_0x156a71['id']});else return _0x1b68ff[_0x11269a('0x17aa')]['get']({'userProfileId':_0x3368ca[_0x11269a('0x26cd')]()[_0x11269a('0xb86')],'sectionId':0x12f})[_0x11269a('0xa44')][_0x11269a('0x1166')](function(_0x1fad2d){const _0x547b77=_0x11269a,_0xc38a28=_0x1fad2d&&_0x1fad2d[_0x547b77('0x269a')]?_0x1fad2d[_0x547b77('0x269a')][0x0]:null;_0xc38a28&&_0xc38a28['enabled']?_0x460b8d['go'](_0x547b77('0x1275'),{'ListId':_0x156a71['id']}):_0xa4985a['info']({'title':_0x336eaf[_0x547b77('0x25cc')](_0x547b77('0x627')),'msg':_0x336eaf['instant'](_0x547b77('0x2642'))});})[_0x11269a('0x1a80')](function(_0x3c1c2b){const _0x139690=_0x11269a;_0xa4985a[_0x139690('0xfc9')]({'title':_0x3c1c2b[_0x139690('0x52d')]?'API:'+_0x3c1c2b[_0x139690('0x52d')]+_0x139690('0x11e1')+_0x3c1c2b['statusText']:_0x139690('0x153e'),'msg':_0x3c1c2b[_0x139690('0x52d')]?JSON[_0x139690('0xbac')](_0x3c1c2b[_0x139690('0x25f4')]):_0x3c1c2b[_0x139690('0x1586')]()});});}function _0x901e3a(_0x57a178,_0x2330b0){const _0xa7418=_0x4051eb;_0x46eccd[_0xa7418('0x1f80')]({'controller':'ListagentaddController','controllerAs':'vm','templateUrl':_0x117c30,'parent':angular['element'](_0x5e819f[_0xa7418('0x8d2')]),'targetEvent':_0x2330b0,'clickOutsideToClose':!![],'locals':{'list':_0x57a178,'lists':_0x1c7745[_0xa7418('0x8de')]?_0x1c7745['lists']['rows']:[],'crudPermissions':_0x1c7745[_0xa7418('0x243c')],'realtime':![]}});}function _0xc7ee42(){const _0x1cad0f=_0x4051eb;_0x460b8d['go'](_0x1cad0f('0x24c4'),{},{'reload':_0x1cad0f('0x24c4')});}function _0x23e696(){const _0xbf0431=_0x4051eb;_0x1b68ff[_0xbf0431('0xdd9')][_0xbf0431('0x1449')]({'id':_0x1c7745[_0xbf0431('0x1480')]['id']},_0x1c7745['list'])[_0xbf0431('0xa44')][_0xbf0431('0x1166')](function(){const _0x1594c2=_0xbf0431;_0xa4985a['success']({'title':_0x1594c2('0x1e48'),'msg':_0x1c7745[_0x1594c2('0x1480')][_0x1594c2('0x4f0')]?_0x1c7745[_0x1594c2('0x1480')]['name']+_0x1594c2('0xa17'):''});})[_0xbf0431('0x1a80')](function(_0x292e9b){const _0x2e21bc=_0xbf0431;_0xa4985a[_0x2e21bc('0xfc9')]({'title':_0x292e9b[_0x2e21bc('0x52d')]?'API:'+_0x292e9b[_0x2e21bc('0x52d')]+'\x20-\x20'+_0x292e9b['statusText']:_0x2e21bc('0x23c9'),'msg':_0x292e9b[_0x2e21bc('0x25f4')]?JSON[_0x2e21bc('0xbac')](_0x292e9b[_0x2e21bc('0x25f4')]):_0x292e9b[_0x2e21bc('0x1586')]()});});}}const _0x1f352d=_0x3fb0a1,_0x14e8d3=_0x2734b2['p']+_0x36e6f4('0xaa0');_0x50e837[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x50e837(_0x10a717,_0x5ab3b2,_0xdec247,_0x2dc833,_0x4e3992,_0x173014,_0x3fba44,_0x38a18a,_0x34f42d,_0x5b1305,_0x445d1e){const _0x32c97d=_0x36e6f4,_0x499ec6=this;_0x499ec6[_0x32c97d('0x98')]=_0x445d1e['getCurrentUser'](),_0x499ec6['dispositions']={'count':0x0,'rows':[]},_0x499ec6[_0x32c97d('0x1082')]=[],_0x499ec6[_0x32c97d('0x243c')],_0x499ec6[_0x32c97d('0x178f')]={'first':_0x32c97d('0xc31'),'second':_0x32c97d('0x580'),'third':_0x32c97d('0x1144')},_0x499ec6[_0x32c97d('0x2218')]={'fields':'id,level,name,description,ParentId,createdAt,updatedAt','sort':_0x32c97d('0x14dc'),'limit':0xa,'page':0x1},_0x499ec6[_0x32c97d('0x24d5')]=_0x4bba43,_0x499ec6[_0x32c97d('0x8a2')]=_0x15f683,_0x499ec6[_0x32c97d('0x103b')]=_0x1182a9,_0x499ec6[_0x32c97d('0x3e')]=_0x50fb49,_0x499ec6[_0x32c97d('0x782')]=_0x5479e3,_0x499ec6[_0x32c97d('0x27c6')]=_0x3f4e21,_0x499ec6[_0x32c97d('0x4e2')]=_0x2c7148,_0x499ec6[_0x32c97d('0x14b5')]=_0x25c217,_0x499ec6[_0x32c97d('0x205e')]=_0x121eac,_0x499ec6[_0x32c97d('0xd7c')]=_0x1717f8;function _0x4bba43(_0x32b4ff,_0x48ce54){const _0x4d2b05=_0x32c97d;_0x499ec6[_0x4d2b05('0x1480')]=_0x32b4ff||{},_0x499ec6[_0x4d2b05('0x243c')]=typeof _0x48ce54!==_0x4d2b05('0x1048')?_0x48ce54:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x499ec6[_0x4d2b05('0x2218')]['ListId']=_0x499ec6[_0x4d2b05('0x1480')]['id'],_0x499ec6[_0x4d2b05('0x2218')]['id']=_0x499ec6[_0x4d2b05('0x1480')]['id'],_0x50fb49();}function _0x5479e3(_0x1f31df,_0x4e05f4){const _0x5211ac=_0x32c97d;_0x4e3992[_0x5211ac('0x1f80')]({'controller':'CreateOrEditDispositionDialogController','controllerAs':'vm','templateUrl':_0x14e8d3,'parent':angular[_0x5211ac('0x1194')](_0x173014[_0x5211ac('0x8d2')]),'targetEvent':_0x1f31df,'clickOutsideToClose':!![],'locals':{'disposition':_0x4e05f4,'dispositions':_0x499ec6[_0x5211ac('0x4ea')][_0x5211ac('0x269a')],'model':{'id':_0x499ec6['list']['id'],'field':_0x5211ac('0x23c')},'license':null,'setting':null,'crudPermissions':_0x499ec6['crudPermissions']}})[_0x5211ac('0x1166')](function(_0x26f152){if(_0x26f152)_0x50fb49();});}function _0x15f683(_0x44be91,_0x21a2c8){const _0x4ed072=_0x32c97d,_0x410cc1=_0x2cfb05()[_0x4ed072('0x1798')](_0x499ec6[_0x4ed072('0x4ea')][_0x4ed072('0x269a')],['ParentId',_0x44be91['id']]),_0x17cc53=_0x4e3992[_0x4ed072('0x1d26')]()[_0x4ed072('0xcdc')](_0x38a18a[_0x4ed072('0x25cc')](_0x4ed072('0x1ac5')))[_0x4ed072('0xacc')](_0x38a18a[_0x4ed072('0x25cc')](_0x4ed072('0x92f')+(_0x410cc1?_0x4ed072('0xc7a'):_0x4ed072('0x251e')),{'name':_0x44be91[_0x4ed072('0x4f0')]}))['ariaLabel'](_0x4ed072('0x1af2'))['targetEvent'](_0x21a2c8)['ok']('OK')[_0x4ed072('0x3f')](_0x38a18a[_0x4ed072('0x25cc')](_0x4ed072('0x12a3')));_0x4e3992[_0x4ed072('0x1f80')](_0x17cc53)[_0x4ed072('0x1166')](function(){_0x3f4e21(_0x44be91);});}function _0x1182a9(_0x164ec7){const _0x1704aa=_0x32c97d;_0x499ec6[_0x1704aa('0x4ea')]=_0x164ec7||{'count':0x0,'rows':[]};}function _0x50fb49(){const _0x59e44f=_0x32c97d;_0x499ec6['query']['offset']=(_0x499ec6[_0x59e44f('0x2218')][_0x59e44f('0x1a43')]-0x1)*_0x499ec6['query'][_0x59e44f('0x163f')],_0x499ec6[_0x59e44f('0x1f48')]=_0x34f42d[_0x59e44f('0xdd9')]['getDispositions'](_0x499ec6['query'],_0x1182a9)['$promise'];}function _0x3f4e21(_0xc814d8){const _0x2699e7=_0x32c97d;_0x34f42d[_0x2699e7('0x12e8')]['delete']({'id':_0xc814d8['id']})['$promise'][_0x2699e7('0x1166')](function(){const _0x1dd86a=_0x2699e7;_0x50fb49(),_0x5b1305[_0x1dd86a('0x103b')]({'title':_0x38a18a[_0x1dd86a('0x25cc')](_0x1dd86a('0x1ca6'))});})[_0x2699e7('0x1a80')](function(_0x24a652){const _0x56578f=_0x2699e7;if(_0x24a652[_0x56578f('0x25f4')]&&_0x24a652['data'][_0x56578f('0x61a')]&&_0x24a652[_0x56578f('0x25f4')][_0x56578f('0x61a')][_0x56578f('0x264b')]){_0x499ec6['errors']=_0x24a652[_0x56578f('0x25f4')][_0x56578f('0x61a')]||[{'message':_0x24a652[_0x56578f('0x1586')](),'type':_0x56578f('0x1b2c')}];for(let _0x5e6474=0x0;_0x5e6474<_0x24a652[_0x56578f('0x25f4')][_0x56578f('0x61a')][_0x56578f('0x264b')];_0x5e6474++){_0x5b1305[_0x56578f('0xfc9')]({'title':_0x24a652[_0x56578f('0x25f4')][_0x56578f('0x61a')][_0x5e6474][_0x56578f('0x1345')],'msg':_0x24a652['data'][_0x56578f('0x61a')][_0x5e6474][_0x56578f('0x1e70')]});}}else _0x5b1305[_0x56578f('0xfc9')]({'title':_0x24a652['status']?_0x56578f('0x1e21')+_0x24a652[_0x56578f('0x52d')]+_0x56578f('0x11e1')+_0x24a652['statusText']:_0x56578f('0x1b2c'),'msg':_0x24a652['data']?JSON[_0x56578f('0xbac')](_0x24a652[_0x56578f('0x25f4')][_0x56578f('0x1e70')]):_0x24a652[_0x56578f('0x1e70')]||_0x24a652[_0x56578f('0x1586')]()});});}function _0x2c7148(){const _0x2f5136=_0x32c97d,_0x2313b8=angular['copy'](_0x499ec6[_0x2f5136('0x1082')]);return _0x499ec6[_0x2f5136('0x1082')]=[],_0x2313b8;}function _0x25c217(_0x279e1d){const _0x3cb58e=_0x32c97d,_0xbcd3b4=_0x4e3992[_0x3cb58e('0x1d26')]()[_0x3cb58e('0xcdc')](_0x38a18a[_0x3cb58e('0x25cc')](_0x3cb58e('0x24fd')))['content'](_0x38a18a[_0x3cb58e('0x25cc')](_0x3cb58e('0x223e'),{'total':_0x499ec6[_0x3cb58e('0x1082')][_0x3cb58e('0x264b')]}))[_0x3cb58e('0x8e8')](_0x3cb58e('0x19b'))[_0x3cb58e('0x203b')](_0x279e1d)['ok']('OK')[_0x3cb58e('0x3f')](_0x38a18a[_0x3cb58e('0x25cc')]('TOOLS.CANCEL'));_0x4e3992['show'](_0xbcd3b4)[_0x3cb58e('0x1166')](function(){const _0x41be74=_0x3cb58e;_0x499ec6['selectedDispositions'][_0x41be74('0x2782')](function(_0x3adf61){_0x3f4e21(_0x3adf61);}),_0x499ec6[_0x41be74('0x1082')]=[];});}function _0x121eac(){const _0x1cbf00=_0x32c97d;_0x499ec6[_0x1cbf00('0x1082')]=[];}function _0x1717f8(){const _0x42d949=_0x32c97d;_0x499ec6[_0x42d949('0x1082')]=_0x499ec6['dispositions']['rows'];}let _0x5c6816=!![],_0x459950=0x1;_0x10a717[_0x32c97d('0xe83')](_0x32c97d('0x28b4'),function(_0x12c9b1,_0x5ba664){const _0x544264=_0x32c97d;_0x5c6816?_0x3fba44(function(){_0x5c6816=![];}):(!_0x5ba664&&(_0x459950=_0x499ec6[_0x544264('0x2218')][_0x544264('0x1a43')]),_0x12c9b1!==_0x5ba664&&(_0x499ec6[_0x544264('0x2218')][_0x544264('0x1a43')]=0x1),!_0x12c9b1&&(_0x499ec6[_0x544264('0x2218')][_0x544264('0x1a43')]=_0x459950),_0x50fb49());});}const _0x33069=_0x50e837,_0xa88d5=_0x2734b2['p']+_0x36e6f4('0x1482');_0x1da3b9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$mdSidenav',_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x8de'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),'api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x1da3b9(_0x511ffc,_0x3c9c13,_0x58b64b,_0x5b23ea,_0x14ae7c,_0x123a0b,_0x26a42a,_0x5ae4bc,_0x53783a,_0x48b0a6,_0x34a8ba,_0x2c011d,_0x274657,_0x299454,_0x34d4e3,_0x17752f,_0x589518){const _0x3ff963=_0x36e6f4,_0x275950=this;_0x275950[_0x3ff963('0x5c9')]=_0x17752f,_0x275950['setting']=_0x589518,_0x275950[_0x3ff963('0x98')]=_0x34d4e3[_0x3ff963('0x26cd')](),_0x275950[_0x3ff963('0x8de')]=_0x53783a||{'count':0x0,'rows':[]},_0x275950['userProfile']=_0x48b0a6,_0x275950[_0x3ff963('0x17aa')]=_0x34a8ba&&_0x34a8ba[_0x3ff963('0x240f')]==0x1?_0x34a8ba['rows'][0x0]:null,_0x275950['crudPermissions']=_0x34d4e3[_0x3ff963('0xd87')](_0x275950['userProfileSection']?_0x275950[_0x3ff963('0x17aa')][_0x3ff963('0x243c')]:null),_0x275950['table']='lists',_0x275950[_0x3ff963('0xef5')]='',_0x275950[_0x3ff963('0x104c')]=null,_0x275950[_0x3ff963('0xe93')]=[],_0x275950[_0x3ff963('0x2218')]={'fields':'createdAt,updatedAt,id,name,description,dialPrefix','sort':_0x3ff963('0x14dc'),'limit':0xa,'page':0x1},_0x275950[_0x3ff963('0x1ff6')]=_0x4c7139,_0x275950['gotocontactsgoto']=_0x3db217,_0x275950[_0x3ff963('0x18ee')]=_0x55b349,_0x275950['agentadddialog']=_0x4be9a0,_0x275950[_0x3ff963('0x8d8')]=_0x10575e,_0x275950[_0x3ff963('0x103b')]=_0x123a29,_0x275950[_0x3ff963('0x5a1')]=_0x2c9612,_0x275950['createOrEditList']=_0xf6a4be,_0x275950['deleteList']=_0x58c872,_0x275950[_0x3ff963('0x2723')]=_0x4558f3,_0x275950[_0x3ff963('0x27d8')]=_0x9c4a5b,_0x275950[_0x3ff963('0xb74')]=_0x119991,_0x275950[_0x3ff963('0x2310')]=_0x3aeba2;function _0x4c7139(_0x4c435e){const _0x10e683=_0x3ff963;_0x58b64b['go'](_0x10e683('0x18a1'),{'id':_0x4c435e['id'],'list':_0x4c435e,'crudPermissions':_0x275950[_0x10e683('0x243c')]});}function _0x3db217(_0x36248b){const _0x44c765=_0x3ff963;if(_0x34d4e3['hasRole'](_0x44c765('0xa7c')))_0x58b64b['go'](_0x44c765('0x1275'),{'ListId':_0x36248b['id']});else return _0x2c011d['userProfileSection']['get']({'userProfileId':_0x34d4e3[_0x44c765('0x26cd')]()[_0x44c765('0xb86')],'sectionId':0x12f})[_0x44c765('0xa44')][_0x44c765('0x1166')](function(_0x36f144){const _0x4c1414=_0x44c765,_0xf7383=_0x36f144&&_0x36f144[_0x4c1414('0x269a')]?_0x36f144[_0x4c1414('0x269a')][0x0]:null;_0xf7383&&_0xf7383[_0x4c1414('0xc27')]?_0x58b64b['go'](_0x4c1414('0x1275'),{'ListId':_0x36248b['id']}):_0x299454[_0x4c1414('0x1fa1')]({'title':_0x5ae4bc[_0x4c1414('0x25cc')](_0x4c1414('0x627')),'msg':_0x5ae4bc['instant'](_0x4c1414('0x2642'))});})[_0x44c765('0x1a80')](function(_0x1cb912){const _0x5d5d1c=_0x44c765;_0x299454[_0x5d5d1c('0xfc9')]({'title':_0x1cb912[_0x5d5d1c('0x52d')]?_0x5d5d1c('0x1e21')+_0x1cb912[_0x5d5d1c('0x52d')]+_0x5d5d1c('0x11e1')+_0x1cb912[_0x5d5d1c('0xe1b')]:_0x5d5d1c('0x153e'),'msg':_0x1cb912[_0x5d5d1c('0x52d')]?JSON['stringify'](_0x1cb912[_0x5d5d1c('0x25f4')]):_0x1cb912[_0x5d5d1c('0x1586')]()});});}function _0x55b349(_0x2dcf4a){const _0x23ff2c=_0x3ff963;return _0x2c011d[_0x23ff2c('0xdd9')][_0x23ff2c('0x1e84')]({'id':_0x2dcf4a['id'],'nolimit':!![]})[_0x23ff2c('0xa44')][_0x23ff2c('0x1166')](function(_0x54fa36){const _0x395ec2=_0x23ff2c;if(typeof _0x54fa36[_0x395ec2('0x264b')]!==_0x395ec2('0x1048')){const _0x1482b9=[_0x54fa36['buffer']],_0x350db1=new Blob(_0x1482b9,{'type':_0x54fa36['type']}),_0x393dce=window[_0x395ec2('0x136d')][_0x395ec2('0xdd')]('a');_0x393dce[_0x395ec2('0xffd')](_0x395ec2('0x14f9'),URL['createObjectURL'](_0x350db1)),_0x393dce[_0x395ec2('0xffd')](_0x395ec2('0x2ad'),'exportContacts_'+_0x2dcf4a['id']+_0x395ec2('0x1e1')),_0x393dce[_0x395ec2('0x3b4')]();}else _0x299454[_0x395ec2('0x1fa1')]({'title':_0x395ec2('0x27d5'),'msg':_0x395ec2('0x1e30')});})[_0x23ff2c('0x1a80')](function(_0x3f584e){const _0x5a0828=_0x23ff2c;_0x299454['error']({'title':_0x3f584e[_0x5a0828('0x52d')]?'API:'+_0x3f584e[_0x5a0828('0x52d')]+_0x5a0828('0x11e1')+_0x3f584e[_0x5a0828('0xe1b')]:_0x5a0828('0x23c9'),'msg':_0x3f584e[_0x5a0828('0x25f4')]?JSON[_0x5a0828('0xbac')](_0x3f584e[_0x5a0828('0x25f4')]):_0x3f584e[_0x5a0828('0x1586')]()});});}function _0x4be9a0(_0x48061f,_0x554710){const _0x271750=_0x3ff963;_0x14ae7c[_0x271750('0x1f80')]({'controller':'ListagentaddController','controllerAs':'vm','templateUrl':_0x117c30,'parent':angular[_0x271750('0x1194')](_0x123a0b[_0x271750('0x8d2')]),'targetEvent':_0x554710,'clickOutsideToClose':!![],'locals':{'list':_0x48061f,'lists':_0x275950[_0x271750('0x8de')]?_0x275950[_0x271750('0x8de')]['rows']:[],'crudPermissions':_0x275950[_0x271750('0x243c')],'realtime':![]}});}function _0x10575e(_0xb01800,_0x401734){const _0x23cbad=_0x3ff963,_0x423f9c=_0x14ae7c[_0x23cbad('0x1d26')]()[_0x23cbad('0xcdc')](_0x23cbad('0x288d')+_0x2cfb05()[_0x23cbad('0xb35')](_0x23cbad('0x1480'))+'?')['htmlContent'](''+(_0xb01800['name']||_0x23cbad('0x1480'))+_0x23cbad('0xace')+_0x23cbad('0x3f3'))[_0x23cbad('0x8e8')](_0x23cbad('0x359'))[_0x23cbad('0x203b')](_0x401734)['ok']('OK')['cancel'](_0x23cbad('0x2d3'));_0x14ae7c[_0x23cbad('0x1f80')](_0x423f9c)[_0x23cbad('0x1166')](function(){_0x58c872(_0xb01800);},function(){console['log']('CANCEL');});}let _0x41db59=!![],_0x49957a=0x1;_0x511ffc[_0x3ff963('0xe83')](_0x3ff963('0x12d8'),function(_0xd84adc,_0xeb732e){const _0x555e3c=_0x3ff963;_0x41db59?_0x26a42a(function(){_0x41db59=![];}):(!_0xeb732e&&(_0x49957a=_0x275950[_0x555e3c('0x2218')]['page']),_0xd84adc!==_0xeb732e&&(_0x275950[_0x555e3c('0x2218')][_0x555e3c('0x1a43')]=0x1),!_0xd84adc&&(_0x275950[_0x555e3c('0x2218')]['page']=_0x49957a),_0x275950[_0x555e3c('0x5a1')]());});function _0x123a29(_0x2f2cf8){const _0x180ca7=_0x3ff963;_0x275950[_0x180ca7('0x8de')]=_0x2f2cf8||{'count':0x0,'rows':[]};}function _0x2c9612(){const _0x99b065=_0x3ff963;_0x275950['query']['offset']=(_0x275950['query']['page']-0x1)*_0x275950[_0x99b065('0x2218')][_0x99b065('0x163f')],_0x34d4e3[_0x99b065('0x1ac6')]('admin')?_0x275950[_0x99b065('0x1f48')]=_0x2c011d['cmList'][_0x99b065('0xd83')](_0x275950[_0x99b065('0x2218')],_0x123a29)['$promise']:(_0x275950[_0x99b065('0x2218')]['id']=_0x275950[_0x99b065('0x7f')]['id'],_0x275950[_0x99b065('0x2218')][_0x99b065('0xe60')]='Lists',_0x275950[_0x99b065('0x1f48')]=_0x2c011d[_0x99b065('0x7f')][_0x99b065('0x263a')](_0x275950[_0x99b065('0x2218')],_0x123a29)['$promise']);}function _0xf6a4be(_0x21eeef,_0x42d2d0){const _0x2a388c=_0x3ff963;_0x14ae7c[_0x2a388c('0x1f80')]({'controller':'CreateOrEditListDialogController','controllerAs':'vm','templateUrl':_0xa88d5,'parent':angular[_0x2a388c('0x1194')](_0x123a0b[_0x2a388c('0x8d2')]),'targetEvent':_0x21eeef,'clickOutsideToClose':!![],'locals':{'list':_0x42d2d0,'lists':_0x275950[_0x2a388c('0x8de')][_0x2a388c('0x269a')],'license':_0x275950['license'],'setting':_0x275950[_0x2a388c('0xf8a')],'crudPermissions':_0x275950[_0x2a388c('0x243c')]}});}function _0x58c872(_0x4a6dfe){const _0x16d1d5=_0x3ff963;_0x2c011d[_0x16d1d5('0xdd9')]['delete']({'id':_0x4a6dfe['id']})['$promise']['then'](function(){const _0x3a014a=_0x16d1d5;_0x2cfb05()[_0x3a014a('0x127f')](_0x275950[_0x3a014a('0x8de')][_0x3a014a('0x269a')],{'id':_0x4a6dfe['id']}),_0x275950[_0x3a014a('0x8de')]['count']-=0x1,!_0x275950['lists'][_0x3a014a('0x269a')]['length']&&_0x275950['getLists'](),_0x299454[_0x3a014a('0x103b')]({'title':_0x2cfb05()['startCase']('List')+_0x3a014a('0x2b6'),'msg':_0x4a6dfe[_0x3a014a('0x4f0')]?_0x4a6dfe[_0x3a014a('0x4f0')]+_0x3a014a('0x7cd'):''});})[_0x16d1d5('0x1a80')](function(_0x134059){const _0x43495b=_0x16d1d5;if(_0x134059[_0x43495b('0x25f4')]&&_0x134059[_0x43495b('0x25f4')][_0x43495b('0x61a')]&&_0x134059[_0x43495b('0x25f4')][_0x43495b('0x61a')][_0x43495b('0x264b')]){_0x275950[_0x43495b('0x61a')]=_0x134059[_0x43495b('0x25f4')][_0x43495b('0x61a')]||[{'message':_0x134059[_0x43495b('0x1586')](),'type':_0x43495b('0x1abd')}];for(let _0x3e1620=0x0;_0x3e1620<_0x134059[_0x43495b('0x25f4')][_0x43495b('0x61a')][_0x43495b('0x264b')];_0x3e1620++){_0x299454[_0x43495b('0xfc9')]({'title':_0x134059['data'][_0x43495b('0x61a')][_0x3e1620][_0x43495b('0x1345')],'msg':_0x134059[_0x43495b('0x25f4')][_0x43495b('0x61a')][_0x3e1620][_0x43495b('0x1e70')]});}}else _0x299454['error']({'title':_0x134059['status']?_0x43495b('0x1e21')+_0x134059[_0x43495b('0x52d')]+_0x43495b('0x11e1')+_0x134059[_0x43495b('0xe1b')]:'SYSTEM:DELETEcmList','msg':_0x134059[_0x43495b('0x25f4')]?JSON[_0x43495b('0xbac')](_0x134059[_0x43495b('0x25f4')][_0x43495b('0x1e70')]):_0x134059[_0x43495b('0x1e70')]||_0x134059[_0x43495b('0x1586')]()});});}function _0x4558f3(){const _0x57aaa7=_0x3ff963,_0x3fa9d7=angular['copy'](_0x275950[_0x57aaa7('0xe93')]);return _0x275950[_0x57aaa7('0xe93')]=[],_0x3fa9d7;}function _0x9c4a5b(_0x5bdc26){const _0x5281ca=_0x3ff963,_0x8b02aa=_0x14ae7c['confirm']()[_0x5281ca('0xcdc')](_0x5281ca('0x289f'))['htmlContent'](''+_0x275950[_0x5281ca('0xe93')][_0x5281ca('0x264b')]+'\x20selected'+_0x5281ca('0x3f3'))[_0x5281ca('0x8e8')](_0x5281ca('0x2f7'))[_0x5281ca('0x203b')](_0x5bdc26)['ok']('OK')[_0x5281ca('0x3f')]('CANCEL');_0x14ae7c[_0x5281ca('0x1f80')](_0x8b02aa)[_0x5281ca('0x1166')](function(){const _0x5bcfd7=_0x5281ca;_0x275950[_0x5bcfd7('0xe93')][_0x5bcfd7('0x2782')](function(_0x323a01){_0x58c872(_0x323a01);}),_0x275950['selectedLists']=[];});}function _0x119991(){const _0x252fd5=_0x3ff963;_0x275950[_0x252fd5('0xe93')]=[];}function _0x3aeba2(){const _0x5c67b1=_0x3ff963;_0x275950['selectedLists']=_0x275950[_0x5c67b1('0x8de')][_0x5c67b1('0x269a')];}}const _0x2bf1da=_0x1da3b9,_0xe86124=_0x2734b2['p']+_0x36e6f4('0x1fe7'),_0x163a53=_0x2734b2['p']+_0x36e6f4('0x1fed'),_0x246641=_0x2734b2['p']+_0x36e6f4('0x132d'),_0x4d884f=_0x2734b2['p']+_0x36e6f4('0x3d9'),_0xb1033c=_0x2734b2['p']+'src/js/modules/main/apps/contactmanager/views/globalCustomFields/globalCustomFields.html/globalCustomFields.html';_0x478bad[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x478bad(_0x12f4b6,_0x4d45ab){const _0x16b828=_0x36e6f4;_0x12f4b6[_0x16b828('0x63f')](_0x16b828('0x1b7b'),{'abstract':!![],'url':_0x16b828('0xbe')})[_0x16b828('0x63f')](_0x16b828('0x24c4'),{'url':_0x16b828('0x219d'),'views':{'content@app':{'templateUrl':_0xe86124,'controller':_0x16b828('0x1918')}},'resolve':{'lists':[_0x16b828('0x1fbc'),_0x16b828('0x21ef'),function(_0xca3552,_0x10666e){const _0xf57d4f=_0x16b828;return _0x10666e['hasRole'](_0xf57d4f('0xa7c'))?_0xca3552[_0xf57d4f('0x18af')](_0xf57d4f('0x4ee'),{'fields':'createdAt,updatedAt,id,name,description,dialPrefix','sort':_0xf57d4f('0x14dc'),'limit':0xa,'offset':0x0}):_0xca3552[_0xf57d4f('0x18af')]('userProfile@getResources',{'id':_0x10666e['getCurrentUser']()[_0xf57d4f('0xb86')],'section':_0xf57d4f('0x1cae'),'fields':_0xf57d4f('0x609'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':[_0x16b828('0x1fbc'),'Auth',function(_0x14a983,_0x511c3f){const _0x5a8e87=_0x16b828;return _0x511c3f[_0x5a8e87('0x1ac6')](_0x5a8e87('0xa7c'))?null:_0x14a983['resolve']('userProfile@get',{'fields':_0x5a8e87('0x686'),'id':_0x511c3f[_0x5a8e87('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x16b828('0x1fbc'),_0x16b828('0x21ef'),function(_0x5b03b8,_0x746cc){const _0x4db9a8=_0x16b828;return _0x746cc[_0x4db9a8('0x1ac6')](_0x4db9a8('0xa7c'))?null:_0x5b03b8[_0x4db9a8('0x18af')]('userProfileSection@get',{'fields':_0x4db9a8('0xe26'),'userProfileId':_0x746cc['getCurrentUser']()[_0x4db9a8('0xb86')],'sectionId':0x12d});}]},'authenticate':!![],'permissionId':0x12d,'bodyClass':_0x16b828('0x1412')})['state'](_0x16b828('0x18a1'),{'url':_0x16b828('0x2233'),'params':{'list':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x163a53,'controller':_0x16b828('0x10e2')}},'resolve':{'list':[_0x16b828('0x1fbc'),_0x16b828('0xf75'),function(_0x25d9fa,_0x2f7ad8){const _0x55ce0d=_0x16b828;return _0x25d9fa[_0x55ce0d('0x18af')](_0x55ce0d('0x4ee'),{'fields':_0x55ce0d('0x609'),'id':_0x2f7ad8['id']});}],'userProfileSection':['apiResolver','Auth',function(_0xff3068,_0x3482e1){const _0x22bfe9=_0x16b828;return _0xff3068[_0x22bfe9('0x18af')](_0x22bfe9('0xaf'),{'fields':_0x22bfe9('0xe26'),'userProfileId':_0x3482e1[_0x22bfe9('0x26cd')]()[_0x22bfe9('0xb86')],'sectionId':0x12d});}]},'authenticate':!![],'permissionId':0x12d,'bodyClass':'contactmanager'})[_0x16b828('0x63f')](_0x16b828('0x1af0'),{'url':_0x16b828('0x8db'),'views':{'content@app':{'templateUrl':_0x246641,'controller':_0x16b828('0x1cf8')}},'resolve':{'companies':[_0x16b828('0x1fbc'),_0x16b828('0x21ef'),function(_0x2f04f2,_0x489294){const _0x521c22=_0x16b828;return _0x489294[_0x521c22('0x1ac6')](_0x521c22('0xa7c'))?_0x2f04f2['resolve'](_0x521c22('0x117a'),{'fields':_0x521c22('0x7d9'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x2f04f2[_0x521c22('0x18af')](_0x521c22('0x17c4'),{'id':_0x489294[_0x521c22('0x26cd')]()[_0x521c22('0xb86')],'section':_0x521c22('0x117'),'fields':_0x521c22('0x7d9'),'sort':_0x521c22('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x16b828('0x1fbc'),_0x16b828('0x21ef'),function(_0x250bdb,_0x33984d){const _0xc51a3d=_0x16b828;return _0x33984d[_0xc51a3d('0x1ac6')](_0xc51a3d('0xa7c'))?null:_0x250bdb[_0xc51a3d('0x18af')](_0xc51a3d('0x697'),{'fields':_0xc51a3d('0x686'),'id':_0x33984d[_0xc51a3d('0x26cd')]()['userProfileId']});}],'userProfileSection':['apiResolver',_0x16b828('0x21ef'),function(_0x1cd4b9,_0x8ad400){const _0x252d85=_0x16b828;return _0x8ad400[_0x252d85('0x1ac6')](_0x252d85('0xa7c'))?null:_0x1cd4b9[_0x252d85('0x18af')](_0x252d85('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x8ad400[_0x252d85('0x26cd')]()['userProfileId'],'sectionId':0x12e});}]},'authenticate':!![],'permissionId':0x12e,'bodyClass':_0x16b828('0x1412')})[_0x16b828('0x63f')](_0x16b828('0x23dd'),{'url':_0x16b828('0x2233'),'params':{'company':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x4d884f,'controller':'CompanyController\x20as\x20vm'}},'resolve':{'company':[_0x16b828('0x1fbc'),_0x16b828('0xf75'),function(_0x5dbbd9,_0x2b38ef){const _0x953b8e=_0x16b828;return _0x5dbbd9['resolve'](_0x953b8e('0x117a'),{'fields':_0x953b8e('0x7d9'),'id':_0x2b38ef['id']});}],'userProfileSection':[_0x16b828('0x1fbc'),'Auth',function(_0x5cbc69,_0x4a40c5){const _0x59fec1=_0x16b828;return _0x5cbc69[_0x59fec1('0x18af')]('userProfileSection@get',{'fields':_0x59fec1('0xe26'),'userProfileId':_0x4a40c5['getCurrentUser']()[_0x59fec1('0xb86')],'sectionId':0x12e});}]},'authenticate':!![],'permissionId':0x12e,'bodyClass':_0x16b828('0x1412')})['state'](_0x16b828('0xab5'),{'url':_0x16b828('0x8e3'),'views':{'content@app':{'templateUrl':_0xb1033c,'controller':_0x16b828('0x27b7')}},'resolve':{'globalCustomFields':['apiResolver',function(_0x48a7b5){const _0x3415d4=_0x16b828;return _0x48a7b5['resolve'](_0x3415d4('0x1204'),{'fields':_0x3415d4('0x263f'),'sort':_0x3415d4('0x14dc'),'ListId':'null','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x16b828('0x21ef'),function(_0x551db7,_0x1aba9d){const _0x70ee0=_0x16b828;return _0x1aba9d[_0x70ee0('0x1ac6')]('admin')?null:_0x551db7['resolve']('userProfile@get',{'fields':_0x70ee0('0x686'),'id':_0x1aba9d[_0x70ee0('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x16b828('0x1fbc'),_0x16b828('0x21ef'),function(_0x309805,_0x3ec205){const _0x5b239b=_0x16b828;return _0x3ec205[_0x5b239b('0x1ac6')]('admin')?null:_0x309805[_0x5b239b('0x18af')](_0x5b239b('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x3ec205[_0x5b239b('0x26cd')]()[_0x5b239b('0xb86')],'sectionId':0x130});}]},'authenticate':!![],'permissionId':0x130,'bodyClass':_0x16b828('0x1412')}),_0x4d45ab[_0x16b828('0x95e')]('app/main/apps/contactmanager');}angular[_0x36e6f4('0x896')](_0x36e6f4('0x1b7b'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),'ng-sortable',_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),'ngclipboard',_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),'app.contactmanager.contacts'])[_0x36e6f4('0xe11')](_0x478bad)[_0x36e6f4('0x75e')](_0x36e6f4('0x254c'),_0x5bda5f)[_0x36e6f4('0x75e')](_0x36e6f4('0x1d6c'),_0x3e8b39)[_0x36e6f4('0x75e')](_0x36e6f4('0x1d1d'),_0x408ea3)[_0x36e6f4('0x75e')](_0x36e6f4('0x1833'),_0x250cb1)['controller'](_0x36e6f4('0x6b1'),_0xa67cc0)[_0x36e6f4('0x75e')](_0x36e6f4('0x19e'),_0x10d064)[_0x36e6f4('0x75e')](_0x36e6f4('0x2533'),_0x19a96f)[_0x36e6f4('0x75e')](_0x36e6f4('0xfe'),_0xb3d2b2)[_0x36e6f4('0x75e')](_0x36e6f4('0x18e'),_0xc64799)[_0x36e6f4('0x75e')](_0x36e6f4('0x1d7'),_0x1f352d)['controller'](_0x36e6f4('0x716'),_0x33069)[_0x36e6f4('0x75e')](_0x36e6f4('0x1d70'),_0x2bf1da),_0x2e366d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x1566'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),'Auth',_0x36e6f4('0x2661'),'toasty',_0x36e6f4('0x1f7e'),_0x36e6f4('0x4ea')];function _0x2e366d(_0x4eafa6,_0x3a29d4,_0x1d5b4b,_0x301b52,_0x56edcc,_0x1e7501,_0x4f4100,_0x343c77,_0xafb114,_0x1e217a,_0x4ec7a9,_0x494d25,_0x562f84,_0x50d043){const _0x9bf3ec=_0x36e6f4,_0x23195a=this;_0x23195a[_0x9bf3ec('0x98')]=_0x1e217a[_0x9bf3ec('0x26cd')](),_0x23195a['agents']=_0x562f84?_0x562f84:[],_0x23195a['dispositions']=_0x50d043,_0x23195a['abandonedCalls']={'count':0x0,'rows':[]},_0x23195a[_0x9bf3ec('0xc6e')]=![],_0x23195a[_0x9bf3ec('0x1a73')]=!![],_0x23195a[_0x9bf3ec('0x7f')]=_0x343c77,_0x23195a[_0x9bf3ec('0x17aa')]=_0xafb114&&_0xafb114[_0x9bf3ec('0x240f')]==0x1?_0xafb114['rows'][0x0]:null,_0x23195a[_0x9bf3ec('0x243c')]=_0x1e217a['parseCrudPermissions'](_0x23195a[_0x9bf3ec('0x17aa')]?_0x23195a[_0x9bf3ec('0x17aa')][_0x9bf3ec('0x243c')]:null),_0x23195a['query']={'fields':_0x9bf3ec('0x1cd1'),'type':_0x9bf3ec('0x14d8'),'queuecallerexitreason':_0x9bf3ec('0x197b')+','+'ABANDONED','sort':'-updatedAt','limit':0xa,'page':0x1},_0x23195a[_0x9bf3ec('0x17df')]=_0x37e151,_0x23195a[_0x9bf3ec('0x1def')]=_0x4cdefd,_0x23195a[_0x9bf3ec('0x2327')]=_0x55bb97,_0x23195a[_0x9bf3ec('0xbb5')]=_0x1a5f0a,_0x23195a['onSaveVoiceQueueReport']=_0x9892b2,_0x23195a[_0x9bf3ec('0x10f')]=_0x3ab690,_0x4ec7a9['onWithoutApply'](_0x9bf3ec('0x2615'),_0x23195a[_0x9bf3ec('0x944')]),_0x4ec7a9['on'](_0x9bf3ec('0x4b0'),_0x23195a[_0x9bf3ec('0x10f')]),_0x1af86f();function _0x1af86f(){const _0x3582d2=_0x9bf3ec;let _0x106354=_0x56edcc[_0x3582d2('0x275')][_0x3582d2('0x15f7')](_0x3582d2('0xbae')+_0x23195a['currentUser']['id']);if(_0x106354)_0x106354=JSON[_0x3582d2('0x1295')](_0x106354),_0x106354&&_0x106354[_0x3582d2('0x2218')]&&(_0x23195a[_0x3582d2('0x2218')]=_0x2cfb05()['merge'](_0x106354[_0x3582d2('0x2218')],_0x2cfb05()[_0x3582d2('0x1414')](_0x23195a[_0x3582d2('0x2218')],[_0x3582d2('0x1aba'),_0x3582d2('0x163f'),_0x3582d2('0x1a43')])),_0x23195a['query']=_0x2cfb05()[_0x3582d2('0x1414')](_0x23195a[_0x3582d2('0x2218')],_0x3582d2('0x1c33')));else{const _0x4e5130={'$gte':_0x24273b()()[_0x3582d2('0x1659')](_0x3582d2('0x2e7'))['utcOffset'](0x0,!![])['format'](),'$lte':_0x24273b()()[_0x3582d2('0x2589')](_0x3582d2('0x2e7'))[_0x3582d2('0x13f2')](0x0,!![])['format']()};_0x23195a['query']['createdAt']=_0x4e5130;}_0x1e217a[_0x3582d2('0x1ac6')](_0x3582d2('0xa7c'))?_0x4f4100[_0x3582d2('0x557')][_0x3582d2('0x152a')]({'id':_0x1e217a[_0x3582d2('0x26cd')]()['id'],'fields':'id,name','channel':_0x3582d2('0x21da'),'type':_0x3582d2('0x14d8'),'nolimit':!![]})[_0x3582d2('0xa44')][_0x3582d2('0x1166')](function(_0x1e5687){const _0x51038d=_0x3582d2;_0x23195a[_0x51038d('0x7a7')]=_0x1e5687||{'count':0x0,'rows':[]},_0x23195a[_0x51038d('0x2392')]=_0x2cfb05()['mapValues'](_0x2cfb05()['keyBy'](_0x23195a[_0x51038d('0x7a7')][_0x51038d('0x269a')],'name'),_0x51038d('0x4f0'));})['catch'](function(_0x33ab52){console['error'](_0x33ab52);})[_0x3582d2('0x1951')](function(){const _0x299d2a=_0x3582d2;_0x23195a[_0x299d2a('0x6cb')]=_0x2c72f6(),_0x23195a[_0x299d2a('0x17df')]();}):_0x4f4100[_0x3582d2('0x7f')][_0x3582d2('0x263a')]({'id':_0x23195a[_0x3582d2('0x98')][_0x3582d2('0xb86')],'section':'VoiceQueues','channel':_0x3582d2('0x21da'),'type':_0x3582d2('0x14d8'),'sort':'-updatedAt','nolimit':!![]})['$promise'][_0x3582d2('0x1166')](function(_0x5ec739){const _0x5732f3=_0x3582d2;_0x23195a[_0x5732f3('0x7a7')]=_0x5ec739||{'count':0x0,'rows':[]},_0x23195a['queuesMap']=_0x2cfb05()['mapValues'](_0x2cfb05()[_0x5732f3('0x155c')](_0x23195a['queues'][_0x5732f3('0x269a')],'name'),_0x5732f3('0x4f0'));})[_0x3582d2('0x1a80')](function(_0x46ba4b){console['error'](_0x46ba4b);})['finally'](function(){const _0x5e73b5=_0x3582d2;_0x23195a[_0x5e73b5('0x6cb')]=_0x2c72f6(),_0x23195a['getAbandonedCalls']();});}function _0x2c72f6(){const _0x55e2a0=_0x9bf3ec;return[{'name':_0x55e2a0('0x2567'),'key':_0x55e2a0('0x262'),'type':_0x55e2a0('0x1643'),'label':_0x55e2a0('0x16d9')},{'name':_0x55e2a0('0x89b'),'key':_0x55e2a0('0x6b0'),'type':_0x55e2a0('0x88a'),'label':_0x55e2a0('0x1db1'),'options':_0x23195a[_0x55e2a0('0x1f7e')]['rows'],'customOptions':[{'value':_0x55e2a0('0x1c08'),'translate':_0x55e2a0('0x216b')},{'value':undefined,'translate':_0x55e2a0('0x2150')}]},{'name':_0x55e2a0('0xaaf'),'key':_0x55e2a0('0x1d3e'),'type':_0x55e2a0('0x2162'),'label':_0x55e2a0('0x1428'),'options':_0x23195a[_0x55e2a0('0x7a7')]['rows']}];}function _0x37e151(){const _0x1e3dfa=_0x9bf3ec;_0x23195a[_0x1e3dfa('0x1a73')]=![],_0x23195a['queues'][_0x1e3dfa('0x240f')]>0x0?(_0x23195a['query'][_0x1e3dfa('0x1d3e')]=_0x23195a[_0x1e3dfa('0x7a7')][_0x1e3dfa('0x240f')]===0x1?_0x23195a['queues'][_0x1e3dfa('0x269a')][0x0]['name']:_0x23195a['query'][_0x1e3dfa('0x1d3e')],_0x23195a['query'][_0x1e3dfa('0x1098')]=(_0x23195a[_0x1e3dfa('0x2218')][_0x1e3dfa('0x1a43')]-0x1)*_0x23195a[_0x1e3dfa('0x2218')][_0x1e3dfa('0x163f')],_0x56edcc[_0x1e3dfa('0x275')]['setItem']('motion2.realtime.abandoned.voice.abandonedCalls:'+_0x23195a[_0x1e3dfa('0x98')]['id'],JSON[_0x1e3dfa('0xbac')]({'query':_0x2cfb05()[_0x1e3dfa('0x1414')](_0x23195a['query'],_0x1e3dfa('0x1d3e'))})),_0x23195a[_0x1e3dfa('0x1f48')]=_0x4f4100['voiceQueueReport'][_0x1e3dfa('0x1cdb')](_0x23195a[_0x1e3dfa('0x2218')],_0x3f576d)[_0x1e3dfa('0xa44')]):_0x3f576d(null);}function _0x3f576d(_0x1f2bd7){const _0x207715=_0x9bf3ec;_0x23195a['abandonedCalls']=_0x1f2bd7||{'count':0x0,'rows':[]},_0x23195a[_0x207715('0x1a73')]=!![];}function _0x4cdefd(){const _0x238357=_0x9bf3ec;_0x23195a[_0x238357('0xc6e')]=![],_0x23195a[_0x238357('0x17df')]();}function _0x9892b2(_0x14cf93){const _0x1dd3b9=_0x9bf3ec,_0x542efa=_0x1dd3b9('0x14d8');_0x14cf93&&_0x23195a[_0x1dd3b9('0x2392')]&&_0x23195a['query'][_0x1dd3b9('0x1345')]===_0x542efa&&_0x23195a[_0x1dd3b9('0x2392')][_0x14cf93[_0x1dd3b9('0x1d3e')]]&&(_0x23195a[_0x1dd3b9('0xc6e')]=!![]);}function _0x3ab690(_0x4e66a8){const _0x127579=_0x9bf3ec;if(_0x4e66a8){const _0x3495ce=_0x2cfb05()[_0x127579('0xede')](_0x23195a[_0x127579('0x224c')][_0x127579('0x269a')],['id',_0x4e66a8['id']]);_0x3495ce>=0x0&&_0x2cfb05()[_0x127579('0xcc3')](_0x23195a[_0x127579('0x224c')][_0x127579('0x269a')][_0x3495ce],_0x4e66a8);}}function _0x55bb97(_0x5104c1,_0x5d88fb){const _0x3aac9c=_0x9bf3ec;_0x5104c1&&_0x4f4100[_0x3aac9c('0x1ede')][_0x3aac9c('0x1449')]({'id':_0x5104c1['id'],'lastAssignedTo':_0x5d88fb?_0x5d88fb[_0x3aac9c('0x4f0')]:null,'assigned':_0x5d88fb?!![]:![]})['$promise'][_0x3aac9c('0x1a80')](function(_0x4fab01){const _0x2f8b68=_0x3aac9c;console[_0x2f8b68('0x455')](_0x4fab01);});}function _0x1a5f0a(_0x4a757a){const _0x58e414=_0x9bf3ec;_0x1d5b4b[_0x58e414('0x1f80')]({'controller':_0x58e414('0x2c1'),'controllerAs':'vm','templateUrl':_0x58e414('0x23b0'),'parent':angular['element'](_0x301b52[_0x58e414('0x8d2')]),'targetEvent':_0x4a757a,'resolve':{'globalDispositions':[_0x58e414('0x1fbc'),function(_0x37b7d0){const _0x58a56b=_0x58e414;return _0x37b7d0[_0x58a56b('0x18af')]('disposition@get',{'MailAccountId':'null','FaxAccountId':_0x58a56b('0x15d7'),'SmsAccountId':_0x58a56b('0x15d7'),'WhatsappAccountId':_0x58a56b('0x15d7'),'OpenchannelAccountId':_0x58a56b('0x15d7'),'ChatWebsiteId':_0x58a56b('0x15d7'),'ListId':_0x58a56b('0x15d7')});}]},'locals':{'dispositions':_0x23195a[_0x58e414('0x4ea')],'call':_0x4a757a}})[_0x58e414('0x1166')](function(_0x335381){const _0x4f0a4b=_0x58e414;if(_0x335381){const _0x35e53e={'id':_0x4a757a['id'],'disposition':_0x335381[_0x4f0a4b('0xdc6')]||null,'secondDisposition':_0x335381[_0x4f0a4b('0xefe')]||null,'thirdDisposition':_0x335381[_0x4f0a4b('0x1d91')]||null};_0x4f4100['voiceQueueReport'][_0x4f0a4b('0x1449')](_0x35e53e)[_0x4f0a4b('0xa44')][_0x4f0a4b('0x1a80')](function(_0x27b1f6){const _0x359942=_0x4f0a4b;console[_0x359942('0x455')](_0x27b1f6);});}});}let _0x545083=!![],_0x3cb6a1=0x1;_0x4eafa6[_0x9bf3ec('0xe83')]('vm.query.filter',function(_0x15e2c2,_0x223e74){const _0x4212eb=_0x9bf3ec;_0x545083?_0x3a29d4(function(){_0x545083=![];}):(!_0x223e74&&(_0x3cb6a1=_0x23195a[_0x4212eb('0x2218')][_0x4212eb('0x1a43')]),_0x15e2c2!==_0x223e74&&(_0x23195a[_0x4212eb('0x2218')]['page']=0x1),!_0x15e2c2&&(_0x23195a[_0x4212eb('0x2218')]['page']=_0x3cb6a1),_0x23195a[_0x4212eb('0x17df')]());}),_0x4eafa6[_0x9bf3ec('0x3d2')](_0x9bf3ec('0x1c3f'),function(){const _0x2f0c77=_0x9bf3ec;_0x4ec7a9[_0x2f0c77('0x1800')](_0x2f0c77('0x2615')),_0x4ec7a9['removeAllListeners'](_0x2f0c77('0x4b0'));});}const _0x16230b=_0x2e366d;_0x817aa7['$inject']=[_0x36e6f4('0x36f'),'$q',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$filter',_0x36e6f4('0xe29'),'agents','rpcAgents',_0x36e6f4('0x19e3'),'socket','toasty',_0x36e6f4('0x1a02'),'userProfile','userProfileSection','Auth','license',_0x36e6f4('0x10eb')];function _0x817aa7(_0x45b41c,_0x1bfe86,_0x403925,_0x81a537,_0x18eddf,_0x350771,_0x190d4e,_0x3d654b,_0x5a7a86,_0x327201,_0x4dfb9e,_0x4792d0,_0xf211d7,_0x2f10e8,_0x48f717,_0x27d15e,_0x1c050f,_0x3235aa){const _0x499432=_0x36e6f4,_0x479c42=this,_0x47ba5d=[_0x499432('0x1a82'),'online','lastLoginAt',_0x499432('0x3dc'),'pauseType','lastPauseAt',_0x499432('0x1eef'),'address',_0x499432('0x1c5c'),_0x499432('0x287f'),_0x499432('0xb4'),_0x499432('0x178d'),_0x499432('0x11ee'),_0x499432('0x5aa'),_0x499432('0x2540'),'chatCapacity','openchannelCapacity','mailCapacity',_0x499432('0x2627'),_0x499432('0x361'),_0x499432('0x1462'),_0x499432('0x1107'),_0x499432('0x8cf'),_0x499432('0x82d'),_0x499432('0x1da1'),_0x499432('0x2681'),_0x499432('0x1ee6'),_0x499432('0x840'),_0x499432('0x1f33'),_0x499432('0x25d8'),'smsStatus',_0x499432('0x1a5d'),'faxStatus',_0x499432('0x17e1'),'chatStatusTime',_0x499432('0x43e'),_0x499432('0x1955'),_0x499432('0x2357'),_0x499432('0x11a8'),_0x499432('0x4f3'),_0x499432('0x18c9'),_0x499432('0x1d3e'),_0x499432('0x1ad2'),'screenrecording',_0x499432('0x2167'),_0x499432('0x1c5b')],_0x42b327=['chatPause','openchannelPause','mailPause',_0x499432('0x178d'),_0x499432('0x11ee'),_0x499432('0x5aa'),_0x499432('0x2540'),_0x499432('0xb41')];_0x479c42['currentUser']=_0x27d15e['getCurrentUser'](),_0x479c42[_0x499432('0xcdd')]=[_0x499432('0x1628'),_0x499432('0x133e'),_0x499432('0x2344'),'onhold',_0x499432('0x521')],_0x479c42[_0x499432('0xe29')]=_0x190d4e||{'count':0x0,'rows':[]},_0x479c42[_0x499432('0x5c9')]=_0x1c050f,_0x479c42['userProfile']=_0x2f10e8,_0x479c42[_0x499432('0x17aa')]=_0x48f717&&_0x48f717['count']==0x1?_0x48f717[_0x499432('0x269a')][0x0]:null,_0x479c42[_0x499432('0x243c')]=_0x27d15e['parseCrudPermissions'](_0x479c42['userProfileSection']?_0x479c42[_0x499432('0x17aa')]['crudPermissions']:null),_0x479c42[_0x499432('0x1f7e')]=_0x3d654b?_0x2cfb05()['keyBy'](_0x3d654b['rows']?_0x3d654b['rows']:[],'id'):{},_0x479c42['rpcAgents']=_0x5a7a86?_0x2cfb05()[_0x499432('0x155c')](_0x5a7a86[_0x499432('0x269a')]?_0x5a7a86['rows']:[],'id'):{},_0x479c42[_0x499432('0x5e5')]={},_0x479c42[_0x499432('0x173f')]=![],_0x479c42[_0x499432('0xa99')]=[],_0x479c42[_0x499432('0x4c4')]={};for(const _0x2afc41 in _0x479c42[_0x499432('0x1f7e')]){typeof _0x479c42[_0x499432('0x1f7e')][_0x2afc41]!==_0x499432('0x1048')&&(_0x479c42[_0x499432('0x1f7e')][_0x2afc41][_0x499432('0x24d5')]=!![]);}_0x479c42[_0x499432('0x2218')]={'limit':0xa,'page':0x1,'order':_0x499432('0x6e1'),'globalStatusFilter':'','pauseTypeFilter':''},_0x479c42[_0x499432('0x885')]=_0x1c56d1,_0x479c42['queueAdd']=_0x3e8bf3,_0x479c42[_0x499432('0x1e77')]=_0x317977,_0x479c42[_0x499432('0xecc')]=_0x3aa143,_0x479c42[_0x499432('0x6df')]=_0x529e6a,_0x479c42['getAgentStatus']=_0x44089f,_0x479c42[_0x499432('0x28b5')]=_0x56a267,_0x479c42['isPause']=_0x35dfae,_0x479c42[_0x499432('0x5ad')]=_0x18b0e5,_0x479c42[_0x499432('0xb02')]=_0xa67ca0,_0x479c42['onSave']=_0x537060,_0x479c42['onUpdate']=_0x262522,_0x479c42[_0x499432('0xae0')]=_0x33ba01,_0x479c42[_0x499432('0x223a')]=_0x49cf1c,_0x479c42['onComplete']=_0x133d7f,_0x479c42['screenRecording']=_0x50027e,_0x4dfb9e['on'](_0x499432('0x26b2'),_0x479c42['onSave']),_0x4dfb9e['on'](_0x499432('0x19d5'),_0x479c42[_0x499432('0x2232')]),_0x4dfb9e['on'](_0x499432('0x10fc'),_0x479c42['onConnect']),_0x4dfb9e['on']('user:agentcomplete',_0x479c42[_0x499432('0x1923')]),_0x33ba01();let _0x4cd112=_0x3235aa(function(){const _0x2cc8ad=_0x499432;_0x479c42[_0x2cc8ad('0x173f')]&&(_0x479c42[_0x2cc8ad('0x173f')]=![],_0x33ba01());},0x3e7);function _0x33ba01(){const _0x31975f=_0x499432;_0x479c42['load']=![];const _0x339944=_0x1bfe86[_0x31975f('0x24d8')]();_0x479c42[_0x31975f('0x1f48')]=_0x339944['promise'],_0x479c42[_0x31975f('0x220b')]=[],_0x479c42[_0x31975f('0xa99')]=[],_0x2cfb05()[_0x31975f('0x941')](_0x479c42['agents'],function(_0x58675c,_0x54f82f){const _0x49943d=_0x31975f;_0x479c42[_0x49943d('0x24b7')][_0x54f82f]&&_0x2cfb05()['merge'](_0x58675c,_0x2cfb05()[_0x49943d('0x1a08')](_0x2cfb05()[_0x49943d('0x1414')](_0x479c42[_0x49943d('0x24b7')][_0x54f82f],_0x42b327),_0x47ba5d)),_0x56a267(_0x58675c),_0x58675c['online']?(_0x479c42['filteredAgents'][_0x49943d('0x1514')](_0x58675c),_0x479c42['agentInternal'][_0x58675c[_0x49943d('0x1eef')]]=_0x54f82f):_0x58675c['globalStatusTime']=_0x2cfb05()[_0x49943d('0xa53')](_0x24273b()()[_0x49943d('0x128a')]('x'));});_0x479c42[_0x31975f('0x2218')][_0x31975f('0xf4')]&&_0x2cfb05()[_0x31975f('0x127f')](_0x479c42[_0x31975f('0x220b')],function(_0x4daec2){const _0x2ea557=_0x31975f;return _0x4daec2[_0x2ea557('0xe34')]!==_0x479c42['query']['globalStatusFilter'];});_0x479c42['query'][_0x31975f('0x2121')]&&_0x2cfb05()[_0x31975f('0x127f')](_0x479c42[_0x31975f('0x220b')],function(_0x3ac8d7){const _0x2b5425=_0x31975f;return _0x3ac8d7[_0x2b5425('0x246c')]!==_0x479c42[_0x2b5425('0x2218')][_0x2b5425('0x2121')];});_0x479c42['query'][_0x31975f('0x1c33')]&&_0x2cfb05()[_0x31975f('0x127f')](_0x479c42[_0x31975f('0x220b')],function(_0x2c0341){const _0x4ac732=_0x31975f;return _0x2c0341[_0x4ac732('0x6e1')][_0x4ac732('0x2574')]()[_0x4ac732('0x2379')](_0x479c42[_0x4ac732('0x2218')]['filter'][_0x4ac732('0x2574')]())<0x0;});_0x479c42[_0x31975f('0x220b')]=_0x3374b5(_0x479c42['filteredAgents']);const _0x15dfee=(_0x479c42[_0x31975f('0x2218')][_0x31975f('0x1a43')]-0x1)*_0x479c42[_0x31975f('0x2218')][_0x31975f('0x163f')];_0x479c42[_0x31975f('0x5e5')]=_0x2cfb05()[_0x31975f('0x3e5')](_0x479c42[_0x31975f('0x220b')],_0x15dfee)['slice'](0x0,_0x479c42['query'][_0x31975f('0x163f')]);for(let _0x36cfa9=0x0;_0x36cfa9<_0x479c42[_0x31975f('0x5e5')][_0x31975f('0x264b')];_0x36cfa9+=0x1){_0x479c42[_0x31975f('0xa99')][_0x31975f('0x1514')](_0x479c42['paginatedAgents'][_0x36cfa9]['id']);}_0x339944[_0x31975f('0x18af')](),_0x479c42[_0x31975f('0x173f')]=!![];}function _0x537060(_0x608101){const _0x4257fa=_0x499432;_0x479c42[_0x4257fa('0x1f7e')][_0x608101['id']]&&(_0x2cfb05()[_0x4257fa('0xcc3')](_0x479c42[_0x4257fa('0x1f7e')][_0x608101['id']],_0x2cfb05()[_0x4257fa('0x1a08')](_0x2cfb05()['omit'](_0x608101,_0x42b327),_0x47ba5d)),_0x2cfb05()[_0x4257fa('0xcc3')](_0x479c42[_0x4257fa('0x24b7')][_0x608101['id']],_0x2cfb05()[_0x4257fa('0x1a08')](_0x2cfb05()[_0x4257fa('0x1414')](_0x608101,_0x42b327),_0x47ba5d)),_0x56a267(_0x479c42[_0x4257fa('0x1f7e')][_0x608101['id']]));}function _0x262522(_0x28d499){const _0x45a8e1=_0x499432;_0x479c42['agents'][_0x28d499['id']]&&(_0x2cfb05()[_0x45a8e1('0xcc3')](_0x479c42['agents'][_0x28d499['id']],_0x2cfb05()['pick'](_0x28d499,_0x47ba5d)),_0x2cfb05()[_0x45a8e1('0xcc3')](_0x479c42[_0x45a8e1('0x24b7')][_0x28d499['id']],_0x2cfb05()[_0x45a8e1('0x1a08')](_0x28d499,_0x47ba5d)),_0x28d499[_0x45a8e1('0x3dc')]&&(_0x479c42[_0x45a8e1('0x1f7e')][_0x28d499['id']]['globalStatusTime']=_0x28d499['lastPauseAt'],_0x479c42[_0x45a8e1('0x24b7')][_0x28d499['id']][_0x45a8e1('0x25b3')]=_0x28d499['lastPauseAt']),_0x56a267(_0x479c42[_0x45a8e1('0x1f7e')][_0x28d499['id']]));}function _0x49cf1c(_0x1d13e0){const _0x3f2904=_0x499432;_0x479c42[_0x3f2904('0x1f7e')][_0x479c42[_0x3f2904('0x4c4')][_0x1d13e0['destaccountcode']]]&&(_0x2cfb05()['merge'](_0x479c42[_0x3f2904('0x1f7e')][_0x479c42[_0x3f2904('0x4c4')][_0x1d13e0[_0x3f2904('0x25fc')]]],_0x2cfb05()['pick'](_0x1d13e0,[_0x3f2904('0x1d3e'),_0x3f2904('0x1ad2')])),_0x2cfb05()[_0x3f2904('0xcc3')](_0x479c42['rpcAgents'][_0x479c42[_0x3f2904('0x4c4')][_0x1d13e0[_0x3f2904('0x25fc')]]],_0x2cfb05()[_0x3f2904('0x1a08')](_0x1d13e0,[_0x3f2904('0x1d3e'),_0x3f2904('0x1ad2')])));}function _0x133d7f(_0x5500b3){const _0x28dc27=_0x499432;_0x479c42['agents'][_0x479c42[_0x28dc27('0x4c4')][_0x5500b3[_0x28dc27('0x25fc')]]]&&(_0x479c42['agents'][_0x479c42['agentInternal'][_0x5500b3[_0x28dc27('0x25fc')]]]=_0x2cfb05()[_0x28dc27('0x1414')](_0x479c42[_0x28dc27('0x1f7e')][_0x479c42[_0x28dc27('0x4c4')][_0x5500b3['destaccountcode']]],[_0x28dc27('0x1d3e'),_0x28dc27('0x1ad2')]),_0x479c42[_0x28dc27('0x24b7')][_0x479c42[_0x28dc27('0x4c4')][_0x5500b3[_0x28dc27('0x25fc')]]]=_0x2cfb05()[_0x28dc27('0x1414')](_0x479c42[_0x28dc27('0x24b7')][_0x479c42[_0x28dc27('0x4c4')][_0x5500b3[_0x28dc27('0x25fc')]]],[_0x28dc27('0x1d3e'),_0x28dc27('0x1ad2')]));}function _0x1c56d1(_0x58c0af){const _0x447b92=_0x499432;return _0x327201[_0x447b92('0x557')][_0x447b92('0x885')]({'id':_0x58c0af['id'],'device':'realtime','agent_id':_0x58c0af['id'],'agent_name':_0x58c0af[_0x447b92('0x4f0')]})[_0x447b92('0xa44')][_0x447b92('0x1166')](function(){const _0xeb6c80=_0x447b92;_0x4792d0[_0xeb6c80('0x103b')]({'title':_0xeb6c80('0x16a7'),'msg':_0x58c0af[_0xeb6c80('0x6e1')]+_0xeb6c80('0x22ec')}),_0x479c42[_0xeb6c80('0x1f7e')][_0x58c0af['id']]&&(_0x479c42[_0xeb6c80('0x1f7e')][_0x58c0af['id']][_0xeb6c80('0xb41')]=![]),_0x479c42[_0xeb6c80('0x24b7')][_0x58c0af['id']]&&(_0x479c42['rpcAgents'][_0x58c0af['id']][_0xeb6c80('0xb41')]=![]),_0x33ba01();})[_0x447b92('0x1a80')](function(_0x4577ed){const _0x226186=_0x447b92;_0x4792d0[_0x226186('0xfc9')]({'title':_0x4577ed[_0x226186('0x52d')]?'API:'+_0x4577ed[_0x226186('0x52d')]+_0x226186('0x11e1')+_0x4577ed[_0x226186('0xe1b')]:'api.staff.save','msg':_0x4577ed[_0x226186('0x25f4')]?JSON['stringify'](_0x4577ed[_0x226186('0x25f4')][_0x226186('0x1e70')]):_0x4577ed['toString']()});});}function _0x317977(_0x4dc5f8,_0x5e816e){const _0x186bad=_0x499432;return _0x327201[_0x186bad('0x557')]['pause']({'id':_0x4dc5f8['id'],'type':_0x5e816e})['$promise'][_0x186bad('0x1166')](function(_0x506b2c){const _0x56972d=_0x186bad;_0x479c42['agents'][_0x4dc5f8['id']]&&_0x2cfb05()[_0x56972d('0xcc3')](_0x479c42[_0x56972d('0x1f7e')][_0x4dc5f8['id']],_0x2cfb05()[_0x56972d('0x1a08')](_0x506b2c,_0x47ba5d)),_0x479c42[_0x56972d('0x24b7')][_0x4dc5f8['id']]&&_0x2cfb05()[_0x56972d('0xcc3')](_0x479c42['rpcAgents'][_0x4dc5f8['id']],_0x2cfb05()[_0x56972d('0x1a08')](_0x506b2c,_0x47ba5d)),_0x56a267(_0x479c42[_0x56972d('0x1f7e')][_0x4dc5f8['id']]);})[_0x186bad('0x1a80')](function(_0x185761){const _0x4c7b86=_0x186bad;_0x4792d0[_0x4c7b86('0xfc9')]({'title':_0x185761[_0x4c7b86('0x52d')]?_0x4c7b86('0x1e21')+_0x185761[_0x4c7b86('0x52d')]+_0x4c7b86('0x11e1')+_0x185761['statusText']:_0x4c7b86('0x1e3c'),'msg':_0x185761[_0x4c7b86('0x25f4')]?JSON['stringify'](_0x185761[_0x4c7b86('0x25f4')][_0x4c7b86('0x1e70')]):_0x185761[_0x4c7b86('0x1586')]()});});}function _0x3aa143(_0x4e53ac){const _0x5802fa=_0x499432;return _0x327201[_0x5802fa('0x557')]['unpause']({'id':_0x4e53ac['id']})['$promise'][_0x5802fa('0x1166')](function(_0x232140){const _0x2a06cb=_0x5802fa;_0x479c42[_0x2a06cb('0x1f7e')][_0x4e53ac['id']]&&_0x2cfb05()[_0x2a06cb('0xcc3')](_0x479c42['agents'][_0x4e53ac['id']],_0x2cfb05()['pick'](_0x232140,_0x47ba5d)),_0x479c42[_0x2a06cb('0x24b7')][_0x4e53ac['id']]&&_0x2cfb05()[_0x2a06cb('0xcc3')](_0x479c42[_0x2a06cb('0x24b7')][_0x4e53ac['id']],_0x2cfb05()[_0x2a06cb('0x1a08')](_0x232140,_0x47ba5d)),_0x56a267(_0x479c42[_0x2a06cb('0x1f7e')][_0x4e53ac['id']]);})[_0x5802fa('0x1a80')](function(_0x2c1efa){const _0x45cf1e=_0x5802fa;_0x4792d0[_0x45cf1e('0xfc9')]({'title':_0x2c1efa['status']?_0x45cf1e('0x1e21')+_0x2c1efa[_0x45cf1e('0x52d')]+'\x20-\x20'+_0x2c1efa[_0x45cf1e('0xe1b')]:'api.staff.save','msg':_0x2c1efa['data']?JSON[_0x45cf1e('0xbac')](_0x2c1efa['data']['message']):_0x2c1efa[_0x45cf1e('0x1586')]()});});}function _0x529e6a(_0x28f7b6){const _0x882be6=_0x499432;_0x81a537['show'](_0x81a537[_0x882be6('0x31d')]()[_0x882be6('0x2339')](!![])[_0x882be6('0xcdc')]('Legend')['htmlContent'](_0x882be6('0x1174'))['ok']('Ok')['targetEvent'](_0x28f7b6));}function _0x3e8bf3(_0x49ed80,_0x168877){const _0xa3b2c3=_0x499432;_0x81a537[_0xa3b2c3('0x1f80')]({'controller':_0xa3b2c3('0xf19'),'controllerAs':'vm','templateUrl':_0x49c5be,'parent':angular[_0xa3b2c3('0x1194')](_0x18eddf[_0xa3b2c3('0x8d2')]),'targetEvent':_0x168877,'clickOutsideToClose':!![],'locals':{'agent':_0x49ed80,'agents':[],'channel':_0xa3b2c3('0x21da'),'direction':'inbound','crudPermissions':_0x479c42[_0xa3b2c3('0x243c')]}});}function _0x35dfae(_0x569b36){const _0x3a16ee=_0x499432;return _0x569b36===_0x3a16ee('0x1e77')||_0x569b36===_0x3a16ee('0x6e8');}function _0x18b0e5(_0x56e259){return _0x56e259==='pause';}function _0xa67ca0(_0x159810){return _0x159810==='*pause';}function _0x452453(_0x1720ce){const _0x5c5ff0=_0x499432;return _0x1720ce===_0x5c5ff0('0xdb0')||_0x1720ce===_0x5c5ff0('0x22d5')||_0x1720ce==='unavailable'||_0x1720ce===_0x5c5ff0('0x1628')||_0x2cfb05()['isNil'](_0x1720ce);}function _0x44089f(_0x2847ef,_0x1796db){const _0x9b7906=_0x499432;if(_0x1796db===_0x9b7906('0x21da')){if(_0x2847ef[_0x1796db+_0x9b7906('0x28f6')]!==_0x9b7906('0xdb0'))return _0x2847ef[_0x1796db+_0x9b7906('0x28f6')];if(_0x2847ef[_0x1796db+_0x9b7906('0x108')])return _0x2847ef[_0x1796db+_0x9b7906('0x28f6')]=_0x9b7906('0x1e77'),'pause';return _0x9b7906('0xdb0');}else{if(_0x2847ef[_0x1796db+_0x9b7906('0x108')])return _0x2847ef[_0x1796db+_0x9b7906('0x28f6')]=_0x9b7906('0x1e77'),_0x9b7906('0x1e77');return _0x2847ef[_0x1796db+_0x9b7906('0x28f6')];}}function _0x56a267(_0x303478){const _0x25d214=_0x499432;let _0x72ce35=_0x25d214('0x22d5');if(_0x2cfb05()[_0x25d214('0x2285')]([_0x44089f(_0x303478,_0x25d214('0x21da')),_0x44089f(_0x303478,_0x25d214('0xde2')),_0x44089f(_0x303478,_0x25d214('0x1bfa')),_0x44089f(_0x303478,_0x25d214('0x26c')),_0x44089f(_0x303478,_0x25d214('0x146c')),_0x44089f(_0x303478,'whatsapp'),_0x44089f(_0x303478,'fax')],_0x35dfae))_0x72ce35=_0x25d214('0x1e77');else{if(_0x2cfb05()[_0x25d214('0x1798')]([_0x44089f(_0x303478,_0x25d214('0x21da')),_0x44089f(_0x303478,_0x25d214('0xde2')),_0x44089f(_0x303478,_0x25d214('0x1bfa')),_0x44089f(_0x303478,_0x25d214('0x26c')),_0x44089f(_0x303478,_0x25d214('0x146c')),_0x44089f(_0x303478,_0x25d214('0x116e')),_0x44089f(_0x303478,_0x25d214('0x1fc7'))],_0x35dfae))_0x72ce35=_0x25d214('0x6e8');else _0x2cfb05()['every']([_0x44089f(_0x303478,_0x25d214('0x21da')),_0x44089f(_0x303478,_0x25d214('0xde2')),_0x44089f(_0x303478,_0x25d214('0x1bfa')),_0x44089f(_0x303478,_0x25d214('0x26c')),_0x44089f(_0x303478,_0x25d214('0x146c')),_0x44089f(_0x303478,_0x25d214('0x116e')),_0x44089f(_0x303478,_0x25d214('0x1fc7'))],_0x452453)?_0x72ce35=_0x25d214('0xdb0'):_0x72ce35=_0x25d214('0x2344');}_0x303478[_0x25d214('0xe34')]!==_0x72ce35&&(_0x303478[_0x25d214('0xe34')]=_0x72ce35,_0x303478['init']?(_0x303478[_0x25d214('0x24d5')]=![],_0x303478['globalStatusTime']=_0x35dfae(_0x72ce35)?_0x2cfb05()[_0x25d214('0xa53')](_0x24273b()(_0x303478[_0x25d214('0x3dc')])[_0x25d214('0x128a')]('x')):_0x2cfb05()['max']([_0x303478['voiceStatusTime'],_0x303478[_0x25d214('0x1507')],_0x303478['mailStatusTime'],_0x303478[_0x25d214('0x2357')],_0x303478['whatsappStatusTime'],_0x303478[_0x25d214('0x43e')],_0x303478['faxStatusTime']])):_0x303478[_0x25d214('0x25b3')]=_0x2cfb05()[_0x25d214('0xa53')](_0x24273b()()[_0x25d214('0x128a')]('x')));}function _0x3374b5(_0x138679){const _0x9cbec0=_0x499432,_0x537de4=_0x2cfb05()[_0x9cbec0('0x1783')](_0x479c42[_0x9cbec0('0x2218')][_0x9cbec0('0xa99')],'-')?_0x9cbec0('0x1dc3'):_0x9cbec0('0x17d');return _0x2cfb05()[_0x9cbec0('0xe63')](_0x138679,[_0x479c42[_0x9cbec0('0x2218')]['order'][_0x9cbec0('0xf3')]('-','')],[_0x537de4]);}function _0x4af9e9(){_0x4cd112&&(_0x3235aa['cancel'](_0x4cd112),_0x4cd112=null);}function _0x50027e(_0x3ffc20,_0xd950f8){const _0x42b1a2=_0x499432;return _0x327201[_0x42b1a2('0x557')][_0x42b1a2('0x1449')]({'id':_0x3ffc20['id']},{'screenrecording':_0xd950f8})[_0x42b1a2('0xa44')][_0x42b1a2('0x1a80')](function(_0x4c6893){const _0x26330a=_0x42b1a2;_0x4792d0[_0x26330a('0xfc9')]({'title':_0x4c6893[_0x26330a('0x52d')]?_0x26330a('0x1e21')+_0x4c6893['status']+'\x20-\x20'+_0x4c6893[_0x26330a('0xe1b')]:_0x26330a('0x1103'),'msg':_0x4c6893[_0x26330a('0x25f4')]?JSON[_0x26330a('0xbac')](_0x4c6893['data'][_0x26330a('0x1e70')]):_0x4c6893[_0x26330a('0x1586')]()});});}_0x45b41c[_0x499432('0x3d2')](_0x499432('0x1c3f'),function(){const _0x13f0a0=_0x499432;_0x4dfb9e['removeAllListeners'](_0x13f0a0('0x26b2')),_0x4dfb9e[_0x13f0a0('0x1800')](_0x13f0a0('0x19d5')),_0x4dfb9e[_0x13f0a0('0x1800')](_0x13f0a0('0x10fc')),_0x4dfb9e[_0x13f0a0('0x1800')]('user:agentcomplete'),_0x4af9e9();});}const _0x45eae1=_0x817aa7;_0xb5e262[_0x36e6f4('0x1294')]=['$scope','$timeout',_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0xda'),_0x36e6f4('0x1a02')];function _0xb5e262(_0x470e2c,_0x48fde6,_0x764dbc,_0x356d21,_0xe0aafa,_0x18b30f){const _0x343079=_0x36e6f4,_0x3c2a89=this;_0x3c2a89['calls']=_0xe0aafa||{'rows':[],'count':0x0},_0x3c2a89[_0x343079('0x2218')]={'limit':0xa,'page':0x1},_0x3c2a89[_0x343079('0xd93')]=_0x18b30f[_0x343079('0x81e')],_0x356d21['on'](_0x343079('0x2816'),_0x3c2a89['onSave']),_0x356d21['on'](_0x343079('0x125c'),_0x3c2a89[_0x343079('0x20e2')]);function _0x9751b9(_0x385ac2){const _0x5a2bf6=_0x343079,_0x2ca311=_0x2cfb05()[_0x5a2bf6('0xc38')](_0x3c2a89[_0x5a2bf6('0x807')][_0x5a2bf6('0x269a')],{'channel':_0x385ac2['channel']});_0x385ac2['channelstatedesc']=_0x385ac2[_0x5a2bf6('0x1ca4')]?'up':_0x5a2bf6('0x198f');if(_0x2ca311)_0x2cfb05()[_0x5a2bf6('0xcc3')](_0x2ca311,_0x385ac2);else _0x385ac2['channel']&&_0x3c2a89[_0x5a2bf6('0x807')][_0x5a2bf6('0x269a')]['push'](_0x385ac2);}function _0x21a77f(_0x40a047){const _0x1d36e1=_0x343079,_0x37bb5a=_0x2cfb05()[_0x1d36e1('0xede')](_0x3c2a89[_0x1d36e1('0x807')][_0x1d36e1('0x269a')],{'channel':_0x40a047[_0x1d36e1('0x1298')]});_0x37bb5a>=0x0&&(_0x3c2a89['calls'][_0x1d36e1('0x269a')][_0x37bb5a]['status']=_0x1d36e1('0x133d')),_0x48fde6(function(){const _0x5c16f2=_0x1d36e1;_0x3c2a89['calls']['rows'][_0x5c16f2('0x57b')](_0x37bb5a,0x1);},0x1388);}_0x470e2c[_0x343079('0x3d2')]('$destroy',function(){const _0x1d69be=_0x343079;_0x356d21[_0x1d69be('0x1800')](_0x1d69be('0x2816')),_0x356d21[_0x1d69be('0x1800')]('voice_outbound_channel:remove');}),_0x3c2a89['onSave']=_0x9751b9,_0x3c2a89[_0x343079('0x20e2')]=_0x21a77f;}const _0x14ec7d=_0xb5e262;_0xee0fd6[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1f7e'),_0x36e6f4('0x7a7'),_0x36e6f4('0x2177'),'api','socket',_0x36e6f4('0x1a02'),_0x36e6f4('0x1d2e'),'userProfile','userProfileSection','Auth'];function _0xee0fd6(_0x20d280,_0x383d33,_0x18e63b,_0x1b526f,_0x4201db,_0x22c5fd,_0x3dcafb,_0x414aa1,_0x2a7678,_0x2d8e71,_0x3b0a33,_0x59ec83,_0x375734){const _0x103ffb=_0x36e6f4,_0x1ee8da=this;_0x1ee8da[_0x103ffb('0x98')]=_0x375734[_0x103ffb('0x26cd')](),_0x1ee8da[_0x103ffb('0x1f7e')]=_0x1b526f||{'count':0x0,'rows':[]},_0x1ee8da[_0x103ffb('0x7a7')]=_0x4201db?_0x2cfb05()[_0x103ffb('0x155c')](_0x4201db[_0x103ffb('0x269a')]?_0x4201db[_0x103ffb('0x269a')]:[],'name'):{},_0x1ee8da[_0x103ffb('0x1f93')]=_0x22c5fd?_0x2cfb05()[_0x103ffb('0x155c')](_0x22c5fd['rows']?_0x2cfb05()[_0x103ffb('0x1c33')](_0x22c5fd[_0x103ffb('0x269a')],{'type':_0x103ffb('0x14d8')}):[],_0x103ffb('0x1c21')):{},_0x1ee8da[_0x103ffb('0x2177')]={},_0x1ee8da[_0x103ffb('0x7f')]=_0x3b0a33,_0x1ee8da[_0x103ffb('0x17aa')]=_0x59ec83&&_0x59ec83['count']==0x1?_0x59ec83[_0x103ffb('0x269a')][0x0]:null,_0x1ee8da[_0x103ffb('0x243c')]=_0x375734[_0x103ffb('0xd87')](_0x1ee8da[_0x103ffb('0x17aa')]?_0x1ee8da[_0x103ffb('0x17aa')][_0x103ffb('0x243c')]:null),_0x1ee8da['queryChannels']={'limit':0xa,'page':0x1},_0x1ee8da[_0x103ffb('0x1c4d')]=_0x53069b,_0x1ee8da[_0x103ffb('0x1089')]=_0xddb383,_0x1ee8da[_0x103ffb('0x1303')]=_0x37456a,_0x1ee8da[_0x103ffb('0x20e2')]=_0x53efca,_0x1ee8da[_0x103ffb('0x133d')]=_0x3fc36a,_0x1ee8da[_0x103ffb('0x23a5')]=_0x2ae8ac,_0x1ee8da['redirectToNumber']=_0x15589c,_0x414aa1['on'](_0x103ffb('0x196a'),_0x1ee8da[_0x103ffb('0x1303')]),_0x414aa1['on'](_0x103ffb('0x14fe'),_0x1ee8da['onRemove']);function _0x53069b(_0x4685ce){const _0x5e7494=_0x103ffb;return _0x2cfb05()[_0x5e7494('0x2340')](_0x4685ce);}function _0xddb383(){const _0x2dcff5=_0x103ffb;_0x2cfb05()[_0x2dcff5('0x941')](_0x1ee8da[_0x2dcff5('0x1f93')],function(_0x3708c2,_0x444db1){const _0x2ce584=_0x2dcff5;_0x2cfb05()['find'](_0x1ee8da[_0x2ce584('0x7a7')],{'name':_0x3708c2[_0x2ce584('0x4f0')]})&&(_0x1ee8da['rpcVoiceQueuesChannels'][_0x444db1]=_0x3708c2);});}function _0x37456a(_0x252bba){const _0x529645=_0x103ffb;_0x252bba[_0x529645('0x1345')]===_0x529645('0x14d8')&&(_0x2cfb05()['find'](_0x1ee8da['queues'],{'name':_0x252bba[_0x529645('0x4f0')]})&&(_0x1ee8da['rpcVoiceQueuesChannels'][_0x252bba[_0x529645('0x1c21')]]=_0x252bba));}function _0x53efca(_0x3fc302){const _0x5bdf34=_0x103ffb;_0x1ee8da['rpcVoiceQueuesChannels'][_0x3fc302[_0x5bdf34('0x1c21')]]&&delete _0x1ee8da[_0x5bdf34('0x2177')][_0x3fc302[_0x5bdf34('0x1c21')]];}function _0x3fc36a(_0x26e648){const _0x417fe5=_0x103ffb;return _0x3dcafb[_0x417fe5('0x13fa')][_0x417fe5('0x1abc')]({'uniqueid':_0x26e648})[_0x417fe5('0xa44')][_0x417fe5('0x1166')](function(_0x22a5e9){const _0xdeee00=_0x417fe5;_0x2d8e71[_0xdeee00('0x103b')]({'title':'Channel\x20'+_0x26e648+_0xdeee00('0x176b'),'msg':_0x22a5e9[_0xdeee00('0x1e70')]||''});})[_0x417fe5('0x1a80')](function(_0x38de13){const _0x55bc75=_0x417fe5;_0x2d8e71[_0x55bc75('0xfc9')]({'title':_0x38de13['status']+_0x55bc75('0x11e1')+_0x38de13[_0x55bc75('0xe1b')],'msg':JSON[_0x55bc75('0xbac')](_0x38de13[_0x55bc75('0x25f4')])||_0x38de13[_0x55bc75('0x1e70')]['join']('\x20')});});}function _0x2ae8ac(_0x4502fe,_0x327635,_0x5669fc){const _0x492dc9=_0x103ffb;return _0x3dcafb['rpc'][_0x492dc9('0xb2c')]({'uniqueid':_0x4502fe,'exten':_0x327635,'context':_0x5669fc})['$promise'][_0x492dc9('0x1166')](function(_0x2c83de){const _0x4ee189=_0x492dc9;_0x2d8e71[_0x4ee189('0x103b')]({'title':_0x4ee189('0x177a')+_0x4502fe+'\x20properly\x20redirect!','msg':_0x2c83de['message']||''});})[_0x492dc9('0x1a80')](function(_0x47f003){const _0x47d079=_0x492dc9;_0x2d8e71[_0x47d079('0xfc9')]({'title':_0x47f003['status']+'\x20-\x20'+_0x47f003[_0x47d079('0xe1b')],'msg':JSON[_0x47d079('0xbac')](_0x47f003[_0x47d079('0x25f4')])||_0x47f003[_0x47d079('0x1e70')][_0x47d079('0x45a')]('\x20')});});}function _0x15589c(_0x36f413,_0x33a543){const _0x28e81c=_0x103ffb,_0xbcec3=_0x18e63b[_0x28e81c('0x2081')]()[_0x28e81c('0xcdc')](_0x28e81c('0x629'))[_0x28e81c('0xc5c')](_0x28e81c('0x223'))[_0x28e81c('0x203b')](_0x36f413)['ok']('Ok')['cancel'](_0x28e81c('0x497'));return _0x18e63b[_0x28e81c('0x1f80')](_0xbcec3)['then'](function(_0x836bfb){const _0x399105=_0x28e81c;return _0x3dcafb[_0x399105('0x13fa')][_0x399105('0xb2c')]({'uniqueid':_0x33a543,'exten':_0x836bfb})['$promise'];})[_0x28e81c('0x1166')](function(_0x40cc49){const _0x596b07=_0x28e81c;_0x2d8e71['success']({'title':_0x596b07('0x177a')+_0x33a543+'\x20properly\x20redirect!','msg':_0x40cc49[_0x596b07('0x1e70')]||''});})['catch'](function(_0x573a20){const _0x4dea29=_0x28e81c;_0x2d8e71[_0x4dea29('0xfc9')]({'title':_0x573a20['status']+_0x4dea29('0x11e1')+_0x573a20[_0x4dea29('0xe1b')],'msg':JSON[_0x4dea29('0xbac')](_0x573a20[_0x4dea29('0x25f4')])||_0x573a20[_0x4dea29('0x1e70')][_0x4dea29('0x45a')]('\x20')});});}_0x20d280[_0x103ffb('0x3d2')]('$destroy',function(){const _0x1e7b86=_0x103ffb;_0x414aa1[_0x1e7b86('0x1800')](_0x1e7b86('0x196a')),_0x414aa1[_0x1e7b86('0x1800')](_0x1e7b86('0x14fe'));});}const _0x32243a=_0xee0fd6;_0x4a8b39[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x10eb'),_0x36e6f4('0x7a7'),_0x36e6f4('0x744'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),'userProfile','userProfileSection',_0x36e6f4('0x21ef')];function _0x4a8b39(_0x28ca50,_0x3160b0,_0x5410d2,_0x278419,_0x53348f,_0x139f62,_0x2aa855,_0x3875ae,_0x217e4f,_0x2c8b24){const _0x1341ca=_0x36e6f4,_0x7f13d1=this,_0x2de358=['total',_0x1341ca('0x13d'),_0x1341ca('0x15a7'),'abandoned',_0x1341ca('0x4c9'),_0x1341ca('0xa08'),_0x1341ca('0xb76')];_0x7f13d1[_0x1341ca('0x240f')]=_0x278419['count'],_0x7f13d1[_0x1341ca('0x7a7')]=_0x278419?_0x2cfb05()[_0x1341ca('0x155c')](_0x278419[_0x1341ca('0x269a')]?_0x278419[_0x1341ca('0x269a')]:[],'id'):{},_0x7f13d1[_0x1341ca('0x744')]=_0x53348f?_0x2cfb05()['keyBy'](_0x53348f[_0x1341ca('0x269a')]?_0x53348f['rows']:[],'id'):{},_0x7f13d1['userProfile']=_0x3875ae,_0x7f13d1[_0x1341ca('0x17aa')]=_0x217e4f&&_0x217e4f[_0x1341ca('0x240f')]==0x1?_0x217e4f[_0x1341ca('0x269a')][0x0]:null,_0x7f13d1[_0x1341ca('0x243c')]=_0x2c8b24[_0x1341ca('0xd87')](_0x7f13d1[_0x1341ca('0x17aa')]?_0x7f13d1[_0x1341ca('0x17aa')][_0x1341ca('0x243c')]:null);_0x2c8b24[_0x1341ca('0x1ac6')](_0x1341ca('0xa7c'))?_0x7f13d1[_0x1341ca('0x2218')]={'type':_0x1341ca('0x14d8'),'fields':_0x1341ca('0x1776'),'sort':_0x1341ca('0x14dc'),'limit':0xa,'page':0x1}:_0x7f13d1[_0x1341ca('0x2218')]={'id':_0x2c8b24[_0x1341ca('0x26cd')]()['id'],'channel':'voice','type':'inbound','fields':_0x1341ca('0x1776'),'sort':_0x1341ca('0x14dc'),'limit':0xa,'page':0x1};_0x7f13d1['success']=_0xa505b9,_0x7f13d1[_0x1341ca('0x152a')]=_0x123385,_0x7f13d1[_0x1341ca('0x1303')]=_0x1c199e,_0x7f13d1[_0x1341ca('0x1089')]=_0x174075,_0x2aa855[_0x1341ca('0xe82')](_0x1341ca('0xa60'),_0x7f13d1[_0x1341ca('0x1303')]),_0x7f13d1['interval']=_0x5410d2(function(){},0x3e7);function _0x174075(){const _0x22a06f=_0x1341ca;_0x2cfb05()[_0x22a06f('0x941')](_0x7f13d1[_0x22a06f('0x7a7')],function(_0x29eaf1,_0x1b0a5a){const _0x51c21=_0x22a06f;_0x7f13d1['rpcQueues'][_0x1b0a5a]&&_0x2cfb05()[_0x51c21('0xcc3')](_0x29eaf1,_0x2cfb05()[_0x51c21('0x1a08')](_0x7f13d1[_0x51c21('0x744')][_0x1b0a5a],_0x2de358));});}function _0x1c199e(_0xdba31e){const _0x17ebf2=_0x1341ca;_0x7f13d1[_0x17ebf2('0x7a7')][_0xdba31e['id']]&&_0x2cfb05()[_0x17ebf2('0xcc3')](_0x7f13d1[_0x17ebf2('0x7a7')][_0xdba31e['id']],_0x2cfb05()[_0x17ebf2('0x1a08')](_0xdba31e,_0x2de358));}let _0xc3e8c3=!![],_0x91c877=0x1;_0x28ca50[_0x1341ca('0xe83')](_0x1341ca('0x12d8'),function(_0x52c6cb,_0x2c2927){const _0x465edb=_0x1341ca;_0xc3e8c3?_0x3160b0(function(){_0xc3e8c3=![];}):(!_0x2c2927&&(_0x91c877=_0x7f13d1[_0x465edb('0x2218')]['page']),_0x52c6cb!==_0x2c2927&&(_0x7f13d1[_0x465edb('0x2218')]['page']=0x1),!_0x52c6cb&&(_0x7f13d1['query']['page']=_0x91c877),_0x7f13d1[_0x465edb('0x152a')]());});function _0xa505b9(_0x44c8ce){const _0x4602ea=_0x1341ca;_0x7f13d1[_0x4602ea('0x240f')]=_0x44c8ce[_0x4602ea('0x240f')],_0x7f13d1[_0x4602ea('0x7a7')]=_0x44c8ce?_0x2cfb05()['keyBy'](_0x44c8ce['rows']?_0x44c8ce[_0x4602ea('0x269a')]:[],'id'):{},_0x174075();}function _0x123385(){const _0x34468e=_0x1341ca;_0x7f13d1[_0x34468e('0x2218')]['offset']=(_0x7f13d1['query'][_0x34468e('0x1a43')]-0x1)*_0x7f13d1[_0x34468e('0x2218')][_0x34468e('0x163f')],_0x2c8b24['hasRole']('admin')?_0x7f13d1[_0x34468e('0x1f48')]=_0x139f62['voiceQueue']['get'](_0x7f13d1['query'],_0xa505b9)[_0x34468e('0xa44')]:(_0x7f13d1[_0x34468e('0x2218')]['id']=_0x7f13d1[_0x34468e('0x7f')]['id'],_0x7f13d1[_0x34468e('0x2218')][_0x34468e('0xe60')]=_0x34468e('0x1ba2'),_0x7f13d1[_0x34468e('0x1f48')]=_0x139f62[_0x34468e('0x7f')][_0x34468e('0x263a')](_0x7f13d1['query'],_0xa505b9)[_0x34468e('0xa44')]);}_0x28ca50['$on'](_0x1341ca('0x1c3f'),function(){const _0x1a0250=_0x1341ca;_0x2aa855[_0x1a0250('0x1800')]('voice_queue:save'),_0x7f13d1['interval']&&_0x5410d2[_0x1a0250('0x3f')](_0x7f13d1[_0x1a0250('0x277c')]);});}const _0x833de4=_0x4a8b39,_0x7dc18b=_0x2734b2['p']+_0x36e6f4('0x1b77'),_0x4924de=_0x2734b2['p']+_0x36e6f4('0x21fb');_0x5e8893[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1c90'),_0x36e6f4('0x10eb'),_0x36e6f4('0x7a7'),'rpcQueues',_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),'toasty','userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x5e8893(_0x31d10b,_0x3ae6d1,_0xcb453,_0x224858,_0x426797,_0x3e2bc5,_0x2a177e,_0x3b7a10,_0x2f4d5f,_0x5ea5fc,_0x3b9351,_0x45cf0f,_0x1c766a,_0x2538f8){const _0x425326=_0x36e6f4,_0x2517cc=this,_0x32ef51=['loggedIn',_0x425326('0x44b'),_0x425326('0x288a'),'talking',_0x425326('0x67d'),_0x425326('0x20ab'),_0x425326('0x1e70'),'dialActive',_0x425326('0x20ae'),_0x425326('0x14c4'),_0x425326('0x18b')];_0x2517cc['currentUser']=_0x2538f8[_0x425326('0x26cd')](),_0x2517cc[_0x425326('0x240f')]=_0x2a177e[_0x425326('0x240f')]?_0x2a177e['count']:0x0,_0x2517cc[_0x425326('0x7a7')]=_0x2a177e?_0x2cfb05()[_0x425326('0x155c')](_0x2a177e[_0x425326('0x269a')]?_0x2a177e[_0x425326('0x269a')]:[],'id'):{},_0x2517cc[_0x425326('0x744')]=_0x3b7a10?_0x2cfb05()[_0x425326('0x155c')](_0x3b7a10[_0x425326('0x269a')]?_0x3b7a10[_0x425326('0x269a')]:[],'id'):{},_0x2517cc[_0x425326('0x7f')]=_0x45cf0f,_0x2517cc['userProfileSection']=_0x1c766a&&_0x1c766a[_0x425326('0x240f')]==0x1?_0x1c766a[_0x425326('0x269a')][0x0]:null,_0x2517cc[_0x425326('0x243c')]=_0x2538f8[_0x425326('0xd87')](_0x2517cc['userProfileSection']?_0x2517cc[_0x425326('0x17aa')][_0x425326('0x243c')]:null);_0x2538f8['hasRole'](_0x425326('0xa7c'))?_0x2517cc[_0x425326('0x2218')]={'type':_0x425326('0x14d8'),'sort':_0x425326('0x14dc'),'limit':0xa,'page':0x1}:_0x2517cc[_0x425326('0x2218')]={'id':_0x2517cc[_0x425326('0x98')]['id'],'channel':'voice','type':'inbound','sort':'-updatedAt','limit':0xa,'page':0x1};_0x2517cc['success']=_0x53fcf1,_0x2517cc[_0x425326('0x152a')]=_0x2d5c74,_0x2517cc[_0x425326('0x12e5')]=_0xedc9a,_0x2517cc[_0x425326('0x33f')]=_0x5dfa57,_0x2517cc['updateQueue']=_0x2b1f00,_0x2517cc[_0x425326('0x1303')]=_0x1c2502,_0x2517cc[_0x425326('0x212c')]=_0x2a948f,_0x2517cc['onLogin']=_0xe71eee,_0x2517cc['onLogout']=_0x1fba78,_0x2517cc[_0x425326('0x1089')]=_0x382294,_0x2517cc[_0x425326('0xa99')]=[],_0x2cfb05()['forIn'](_0x2517cc['queues'],function(_0x2ddd0e){const _0x39f20a=_0x425326;_0x2517cc[_0x39f20a('0xa99')]['push'](_0x2ddd0e['id']);}),_0x5ea5fc['onWithoutApply']('voice_queue:save',_0x2517cc['onSave']),_0x2517cc['interval']=_0x3e2bc5(function(){},0x3e7),_0x5ea5fc['on'](_0x425326('0x19d5'),_0x2517cc[_0x425326('0x212c')]),_0x5ea5fc['on'](_0x425326('0x25f0'),_0x2517cc[_0x425326('0x1696')]),_0x5ea5fc['on']('userVoiceQueue:save',_0x2517cc[_0x425326('0xb9a')]);function _0x382294(){const _0x5f486d=_0x425326,_0x530578=[];return _0x2cfb05()['forIn'](_0x2517cc[_0x5f486d('0x7a7')],function(_0x740110,_0x1076b5){const _0x2cdf82=_0x5f486d;_0x740110['paused']=0x0,_0x740110[_0x2cdf82('0x2689')]=0x0,_0x2517cc[_0x2cdf82('0x7a7')][_0x1076b5]['agents']={},_0x530578[_0x2cdf82('0x1514')](_0x2f4d5f['voiceQueue'][_0x2cdf82('0x27d1')]({'id':_0x1076b5})[_0x2cdf82('0xa44')]),_0x2517cc['rpcQueues'][_0x1076b5]&&_0x2cfb05()[_0x2cdf82('0xcc3')](_0x740110,_0x2cfb05()[_0x2cdf82('0x1a08')](_0x2517cc['rpcQueues'][_0x1076b5],_0x32ef51));}),_0x224858['all'](_0x530578)['then'](function(_0xc14a16){const _0x1404f8=_0x5f486d;for(let _0x5887e3=0x0;_0x5887e3<_0xc14a16[_0x1404f8('0x264b')];_0x5887e3+=0x1){for(let _0x40c710=0x0;_0x40c710<_0xc14a16[_0x5887e3][_0x1404f8('0x269a')][_0x1404f8('0x264b')];_0x40c710++){_0xc14a16[_0x5887e3]['rows'][_0x40c710][_0x1404f8('0x18b')]&&_0x2517cc[_0x1404f8('0x7a7')][_0xc14a16[_0x5887e3][_0x1404f8('0x269a')][_0x40c710][_0x1404f8('0xc69')]][_0x1404f8('0x18b')]++,_0x2517cc[_0x1404f8('0x7a7')][_0xc14a16[_0x5887e3]['rows'][_0x40c710][_0x1404f8('0xc69')]][_0x1404f8('0x2689')]++,_0x2517cc[_0x1404f8('0x7a7')][_0xc14a16[_0x5887e3]['rows'][_0x40c710][_0x1404f8('0xc69')]]['agents'][_0xc14a16[_0x5887e3]['rows'][_0x40c710]['UserId']]=_0xc14a16[_0x5887e3][_0x1404f8('0x269a')][_0x40c710][_0x1404f8('0xc69')];}}})[_0x5f486d('0x1a80')](function(_0x468b85){const _0x212861=_0x5f486d;console[_0x212861('0xfc9')](_0x468b85);});}function _0x1c2502(_0x4e5442){const _0x2f85ea=_0x425326;_0x2517cc[_0x2f85ea('0x7a7')][_0x4e5442['id']]&&_0x2cfb05()[_0x2f85ea('0xcc3')](_0x2517cc[_0x2f85ea('0x7a7')][_0x4e5442['id']],_0x2cfb05()[_0x2f85ea('0x1a08')](_0x4e5442,_0x32ef51));}function _0x2a948f(_0xba0b18){const _0x21e74f=_0x425326;console[_0x21e74f('0x455')](_0x21e74f('0x212c'),_0xba0b18);if(_0xba0b18[_0x21e74f('0x2540')])_0x2cfb05()[_0x21e74f('0x941')](_0x2517cc[_0x21e74f('0x7a7')],function(_0x1bc922){const _0x4b1236=_0x21e74f;_0x1bc922[_0x4b1236('0x1f7e')][_0xba0b18['id']]&&(_0x1bc922[_0x4b1236('0x18b')]+=0x1,console[_0x4b1236('0x455')](_0x4b1236('0x1e77')));});else!_0xba0b18[_0x21e74f('0x2540')]&&_0x2cfb05()['forIn'](_0x2517cc[_0x21e74f('0x7a7')],function(_0x4cb4e0){const _0x41e1df=_0x21e74f;_0x4cb4e0[_0x41e1df('0x1f7e')][_0xba0b18['id']]&&(_0x4cb4e0[_0x41e1df('0x18b')]>0x0&&(_0x4cb4e0['paused']-=0x1,console[_0x41e1df('0x455')](_0x41e1df('0x20eb'))));});}function _0xe71eee(_0x1a75b3){const _0x155f50=_0x425326;console[_0x155f50('0x455')](_0x155f50('0x26c1'),_0x1a75b3),_0x2517cc['queues'][_0x1a75b3[_0x155f50('0xc69')]]&&(_0x2517cc[_0x155f50('0x7a7')][_0x1a75b3[_0x155f50('0xc69')]][_0x155f50('0x2689')]+=0x1,_0x2517cc['queues'][_0x1a75b3['VoiceQueueId']][_0x155f50('0x1f7e')][_0x1a75b3[_0x155f50('0x122a')]]=_0x1a75b3['VoiceQueueId']);}function _0x1fba78(_0xe8b854){const _0x27af27=_0x425326;console[_0x27af27('0x455')](_0x27af27('0x1696'),_0xe8b854),_0x2517cc[_0x27af27('0x7a7')][_0xe8b854[_0x27af27('0xc69')]]&&_0x2517cc[_0x27af27('0x7a7')][_0xe8b854[_0x27af27('0xc69')]][_0x27af27('0x2689')]>0x0&&(_0x2517cc[_0x27af27('0x7a7')][_0xe8b854['VoiceQueueId']]['loggedInDb']-=0x1,delete _0x2517cc[_0x27af27('0x7a7')][_0xe8b854[_0x27af27('0xc69')]]['agents'][_0xe8b854[_0x27af27('0x122a')]]);}let _0x527c79=!![],_0x4e78a3=0x1;_0x31d10b[_0x425326('0xe83')](_0x425326('0x12d8'),function(_0x485bb5,_0x2022d0){const _0x4c5bc7=_0x425326;_0x527c79?_0x3ae6d1(function(){_0x527c79=![];}):(!_0x2022d0&&(_0x4e78a3=_0x2517cc[_0x4c5bc7('0x2218')][_0x4c5bc7('0x1a43')]),_0x485bb5!==_0x2022d0&&(_0x2517cc['query']['page']=0x1),!_0x485bb5&&(_0x2517cc[_0x4c5bc7('0x2218')]['page']=_0x4e78a3),_0x2517cc[_0x4c5bc7('0x152a')]());});function _0x53fcf1(_0x4fe2db){const _0x576fcf=_0x425326;_0x2517cc[_0x576fcf('0x240f')]=_0x4fe2db[_0x576fcf('0x240f')],_0x2517cc[_0x576fcf('0x7a7')]=_0x4fe2db?_0x2cfb05()[_0x576fcf('0x155c')](_0x4fe2db[_0x576fcf('0x269a')]?_0x4fe2db['rows']:[],'id'):{};if(_0x4fe2db['rows']){_0x2517cc['order']=[];for(let _0x4110d9=0x0;_0x4110d9<_0x4fe2db[_0x576fcf('0x269a')]['length'];_0x4110d9++){_0x2517cc[_0x576fcf('0xa99')][_0x576fcf('0x1514')](_0x4fe2db['rows'][_0x4110d9]['id']);}}_0x382294();}function _0x2d5c74(){const _0xfd8df1=_0x425326;_0x2517cc['query']['offset']=(_0x2517cc['query']['page']-0x1)*_0x2517cc[_0xfd8df1('0x2218')][_0xfd8df1('0x163f')],_0x2538f8[_0xfd8df1('0x1ac6')]('admin')?_0x2517cc[_0xfd8df1('0x1f48')]=_0x2f4d5f['voiceQueue']['get'](_0x2517cc['query'],_0x53fcf1)[_0xfd8df1('0xa44')]:(_0x2517cc[_0xfd8df1('0x2218')]['id']=_0x2517cc[_0xfd8df1('0x7f')]['id'],_0x2517cc[_0xfd8df1('0x2218')][_0xfd8df1('0xe60')]='VoiceQueues',_0x2517cc[_0xfd8df1('0x1f48')]=_0x2f4d5f[_0xfd8df1('0x7f')][_0xfd8df1('0x263a')](_0x2517cc[_0xfd8df1('0x2218')],_0x53fcf1)['$promise']);}function _0xedc9a(_0x410c39,_0x2453aa){const _0x5d950d=_0x425326;_0xcb453[_0x5d950d('0x1f80')]({'controller':'CreateOrEditVoiceQueueDialogController','controllerAs':'vm','templateUrl':_0x7dc18b,'parent':angular[_0x5d950d('0x1194')](_0x426797[_0x5d950d('0x8d2')]),'targetEvent':_0x410c39,'clickOutsideToClose':!![],'locals':{'voiceQueue':_0x2453aa,'voiceQueues':_0x2cfb05()[_0x5d950d('0x1ac1')](_0x2517cc[_0x5d950d('0x7a7')]),'license':null,'setting':null,'crudPermissions':_0x2517cc[_0x5d950d('0x243c')]}});}function _0x5dfa57(_0x536ee0,_0x2b42e9){const _0x9d0522=_0x425326;_0xcb453[_0x9d0522('0x1f80')]({'controller':_0x9d0522('0x2829'),'controllerAs':'vm','templateUrl':_0x4924de,'parent':angular[_0x9d0522('0x1194')](_0x426797[_0x9d0522('0x8d2')]),'targetEvent':_0x536ee0,'clickOutsideToClose':!![],'locals':{'voiceQueue':_0x2b42e9,'voiceQueues':_0x2517cc['queues']?_0x2517cc['queues']['rows']:[],'realtime':!![],'crudPermissions':_0x2517cc[_0x9d0522('0x243c')]}});}function _0x2b1f00(_0x575c21){const _0x9b6e77=_0x425326;return _0x2f4d5f['voiceQueue'][_0x9b6e77('0x1449')](_0x575c21)[_0x9b6e77('0xa44')]['then'](function(){const _0x17eb32=_0x9b6e77;_0x3b9351[_0x17eb32('0x103b')]({'title':'Queue\x20properly\x20updated!','msg':_0x575c21[_0x17eb32('0x4f0')]?_0x575c21[_0x17eb32('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x9b6e77('0x1a80')](function(_0x407951){const _0x3e0d19=_0x9b6e77;_0x3b9351[_0x3e0d19('0xfc9')]({'title':_0x3e0d19('0xa98'),'msg':_0x407951[_0x3e0d19('0x1e70')]});});}_0x31d10b['$on'](_0x425326('0x1c3f'),function(){const _0x2838ed=_0x425326;_0x5ea5fc['removeAllListeners'](_0x2838ed('0xa60')),_0x2517cc['interval']&&_0x3e2bc5[_0x2838ed('0x3f')](_0x2517cc[_0x2838ed('0x277c')]),_0x5ea5fc[_0x2838ed('0x1800')](_0x2838ed('0x19d5')),_0x5ea5fc[_0x2838ed('0x1800')](_0x2838ed('0x25f0')),_0x5ea5fc[_0x2838ed('0x1800')]('userVoiceQueue:save');});}const _0x46c1af=_0x5e8893;function _0x11b64b(){const _0x134c9c=_0x36e6f4;return{'status':{'registered':_0x134c9c('0x23ca'),'unregistered':_0x134c9c('0x278f'),'lagged':_0x134c9c('0x278f'),'reachable':_0x134c9c('0x23ca'),'unreachable':_0x134c9c('0x278f'),'unknown':_0x134c9c('0x2125')},'state':{'unknown':_0x134c9c('0x1d48'),'not_inuse':_0x134c9c('0xa1e'),'inuse':_0x134c9c('0xa2f'),'busy':_0x134c9c('0x18d2'),'invalid':_0x134c9c('0x1d48'),'unavailable':_0x134c9c('0x1d48'),'ringing':'blue-300-fg\x20icon-phone-incoming','ringinuse':'blue-300-fg\x20icon-phone-incoming','onhold':'blue-300-fg\x20icon-phone-paused'},'channelStatus':{'ring':_0x134c9c('0x132c'),'up':_0x134c9c('0x20b2'),'hangup':_0x134c9c('0x9e3')},'channelStatusOut':{'ring':_0x134c9c('0xac'),'up':_0x134c9c('0x20b2'),'hangup':_0x134c9c('0x9e3')}};}const _0xa75680=_0x11b64b;_0x55dcef['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x2661')];function _0x55dcef(_0x2b0b1f,_0x44848b,_0x27af7b){const _0x17a5ee=_0x36e6f4,_0x5cdc71=this;_0x27af7b[_0x17a5ee('0x670')](),_0x27af7b[_0x17a5ee('0x7bb')](),_0x5cdc71[_0x17a5ee('0x2669')]=0x0;switch(_0x44848b['current']['name']){case _0x17a5ee('0x578'):_0x5cdc71[_0x17a5ee('0x2669')]=0x0;break;case _0x17a5ee('0x214d'):_0x5cdc71[_0x17a5ee('0x2669')]=0x1;break;case _0x17a5ee('0x13ae'):_0x5cdc71[_0x17a5ee('0x2669')]=0x2;break;case'app.voice.realtime.queues':_0x5cdc71[_0x17a5ee('0x2669')]=0x3;break;case _0x17a5ee('0x1bc4'):_0x5cdc71[_0x17a5ee('0x2669')]=0x4;break;case _0x17a5ee('0xf59'):_0x5cdc71[_0x17a5ee('0x2669')]=0x5;break;case _0x17a5ee('0x517'):_0x5cdc71[_0x17a5ee('0x2669')]=0x6;break;case _0x17a5ee('0x1154'):_0x5cdc71[_0x17a5ee('0x2669')]=0x7;break;default:_0x5cdc71['selectedTab']=0x0,_0x44848b['go'](_0x17a5ee('0x578'));}_0x2b0b1f[_0x17a5ee('0xe83')](_0x17a5ee('0x27a7'),function(_0x1211e6,_0x3531b4){const _0x251bf7=_0x17a5ee;if(_0x1211e6!==_0x3531b4)switch(_0x1211e6){case 0x0:_0x44848b['go'](_0x251bf7('0x578'));break;case 0x1:_0x44848b['go'](_0x251bf7('0x214d'));break;case 0x2:_0x44848b['go'](_0x251bf7('0x13ae'));break;case 0x3:_0x44848b['go'](_0x251bf7('0xde0'));break;case 0x4:_0x44848b['go'](_0x251bf7('0x1bc4'));break;case 0x5:_0x44848b['go']('app.voice.realtime.abandonedcalls');break;case 0x6:_0x44848b['go'](_0x251bf7('0x517'));break;case 0x7:_0x44848b['go'](_0x251bf7('0x1154'));break;default:_0x44848b['go'](_0x251bf7('0x578'));}});}const _0x360f7=_0x55dcef;_0x2c2b36[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),'$mdDialog',_0x36e6f4('0x20f9'),_0x36e6f4('0xb9b'),'api',_0x36e6f4('0x2661'),_0x36e6f4('0x1a02'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x2c2b36(_0x21fb69,_0x48f485,_0xbc0da2,_0x2063e3,_0x2a45fb,_0x46846e,_0x466802,_0x41ee18,_0x3f97b7,_0x4ac2f6,_0x27c399){const _0x26adc5=_0x36e6f4,_0x1c11e4=this,_0x5262d4=['fullname',_0x26adc5('0x1eef'),_0x26adc5('0x63f'),'status'];_0x1c11e4[_0x26adc5('0x240f')]=_0x2063e3[_0x26adc5('0x240f')],_0x1c11e4[_0x26adc5('0x27db')]=[_0x26adc5('0x6e1'),_0x26adc5('0x1eef'),_0x26adc5('0x63f'),_0x26adc5('0x52d'),_0x26adc5('0x16a6')],_0x1c11e4[_0x26adc5('0x20f9')]=_0x2063e3?_0x2cfb05()[_0x26adc5('0x155c')](_0x2063e3[_0x26adc5('0x269a')]?_0x2063e3[_0x26adc5('0x269a')]:[],'id'):{},_0x1c11e4[_0x26adc5('0xb9b')]=_0x2a45fb?_0x2cfb05()[_0x26adc5('0x155c')](_0x2a45fb[_0x26adc5('0x269a')]?_0x2a45fb['rows']:[],'id'):{},_0x1c11e4[_0x26adc5('0x7f')]=_0x3f97b7,_0x1c11e4[_0x26adc5('0x17aa')]=_0x4ac2f6&&_0x4ac2f6['count']==0x1?_0x4ac2f6[_0x26adc5('0x269a')][0x0]:null,_0x1c11e4['crudPermissions']=_0x27c399[_0x26adc5('0xd87')](_0x1c11e4[_0x26adc5('0x17aa')]?_0x1c11e4[_0x26adc5('0x17aa')][_0x26adc5('0x243c')]:null),_0x1c11e4['query']={'fields':_0x26adc5('0xc23'),'role':_0x26adc5('0x887'),'sort':_0x26adc5('0x14dc'),'limit':0xa,'page':0x1},_0x1c11e4['statusClass']=_0x41ee18[_0x26adc5('0x52d')],_0x1c11e4['stateClass']=_0x41ee18[_0x26adc5('0x63f')],_0x1c11e4[_0x26adc5('0x103b')]=_0x27cc0e,_0x1c11e4['$onInit']=_0x409347,_0x1c11e4['showInfo']=_0x9ca94,_0x1c11e4['getTelephones']=_0x4957f5,_0x1c11e4[_0x26adc5('0x1303')]=_0x1a5bc4,_0x466802['on'](_0x26adc5('0x206a'),_0x1c11e4['onSave']);function _0x409347(){const _0x15d602=_0x26adc5;_0x2cfb05()[_0x15d602('0x941')](_0x1c11e4[_0x15d602('0x20f9')],function(_0x3533eb,_0x57ea4a){const _0x51641d=_0x15d602;_0x1c11e4[_0x51641d('0xb9b')][_0x57ea4a]&&_0x2cfb05()[_0x51641d('0xcc3')](_0x3533eb,_0x2cfb05()[_0x51641d('0x1a08')](_0x1c11e4[_0x51641d('0xb9b')][_0x57ea4a],_0x5262d4));});}function _0x9ca94(_0x59ec8f){const _0x54c228=_0x26adc5;_0xbc0da2[_0x54c228('0x1f80')](_0xbc0da2['alert']()[_0x54c228('0x2339')](!![])[_0x54c228('0xcdc')](_0x54c228('0x58a'))[_0x54c228('0xf3c')]('
TODO\x20legend\x20status\x20+\x20state
')['ok']('Ok')[_0x54c228('0x203b')](_0x59ec8f));}function _0x1a5bc4(_0x14b3a2){const _0x1b1f3b=_0x26adc5;_0x1c11e4[_0x1b1f3b('0x20f9')][_0x14b3a2['id']]&&_0x2cfb05()[_0x1b1f3b('0xcc3')](_0x1c11e4['telephones'][_0x14b3a2['id']],_0x2cfb05()[_0x1b1f3b('0x1a08')](_0x14b3a2,_0x5262d4));}let _0x378bde=!![],_0x30b32b=0x1;_0x21fb69[_0x26adc5('0xe83')](_0x26adc5('0x12d8'),function(_0x465f54,_0x108752){const _0x499236=_0x26adc5;_0x378bde?_0x48f485(function(){_0x378bde=![];}):(!_0x108752&&(_0x30b32b=_0x1c11e4[_0x499236('0x2218')][_0x499236('0x1a43')]),_0x465f54!==_0x108752&&(_0x1c11e4[_0x499236('0x2218')][_0x499236('0x1a43')]=0x1),!_0x465f54&&(_0x1c11e4[_0x499236('0x2218')]['page']=_0x30b32b),_0x1c11e4['getTelephones']());});function _0x27cc0e(_0x425597){const _0x45f138=_0x26adc5;_0x1c11e4[_0x45f138('0x20f9')]=_0x425597?_0x2cfb05()['keyBy'](_0x425597[_0x45f138('0x269a')]?_0x425597[_0x45f138('0x269a')]:[],'id'):{},_0x409347();}function _0x4957f5(){const _0x297aca=_0x26adc5;_0x1c11e4[_0x297aca('0x2218')]['offset']=(_0x1c11e4[_0x297aca('0x2218')]['page']-0x1)*_0x1c11e4['query']['limit'],_0x27c399[_0x297aca('0x1ac6')]('admin')?_0x1c11e4[_0x297aca('0x1f48')]=_0x46846e[_0x297aca('0x557')][_0x297aca('0xd83')](_0x1c11e4[_0x297aca('0x2218')],_0x27cc0e)[_0x297aca('0xa44')]:(_0x1c11e4['query']['id']=_0x1c11e4[_0x297aca('0x7f')]['id'],_0x1c11e4[_0x297aca('0x2218')][_0x297aca('0xe60')]='Telephones',_0x1c11e4[_0x297aca('0x1f48')]=_0x46846e[_0x297aca('0x7f')][_0x297aca('0x263a')](_0x1c11e4[_0x297aca('0x2218')],_0x27cc0e)[_0x297aca('0xa44')]);}_0x21fb69['$on'](_0x26adc5('0x1c3f'),function(){const _0x56f02e=_0x26adc5;_0x466802['removeAllListeners'](_0x56f02e('0x206a'));});}const _0x234932=_0x2c2b36;_0x44eb27[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),'$mdDialog','trunks','rpcTrunks',_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x1a02'),_0x36e6f4('0x7b9'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x44eb27(_0x29c186,_0x4af243,_0x6a9ca4,_0x4a1eaa,_0x461e7d,_0x28a9af,_0x4ff3cd,_0x1241e6,_0x3bc30a,_0x2efb8e,_0x59aff7,_0x179d22){const _0x5d0802=_0x36e6f4,_0x2368a0=this,_0x580aa5=[_0x5d0802('0x52d'),_0x5d0802('0x1b1a'),_0x5d0802('0x942'),_0x5d0802('0x1690'),_0x5d0802('0x93d'),_0x5d0802('0x1eef'),'state','status'];_0x2368a0[_0x5d0802('0x98')]=_0x179d22[_0x5d0802('0x26cd')](),_0x2368a0['count']=_0x4a1eaa[_0x5d0802('0x240f')],_0x2368a0[_0x5d0802('0xf24')]=_0x4a1eaa?_0x4a1eaa[_0x5d0802('0x269a')]:[],_0x2368a0[_0x5d0802('0x24e3')]=_0x461e7d?_0x461e7d['rows']?_0x461e7d[_0x5d0802('0x269a')]:[]:[],_0x2368a0[_0x5d0802('0x2218')]={'fields':_0x5d0802('0x1776'),'active':!![],'sort':'-updatedAt','limit':0xa,'page':0x1},_0x2368a0[_0x5d0802('0x15a8')]=_0x1241e6[_0x5d0802('0x52d')],_0x2368a0[_0x5d0802('0x1b31')]=_0x1241e6[_0x5d0802('0x63f')],_0x2368a0[_0x5d0802('0x7f')]=_0x2efb8e,_0x2368a0['userProfileSection']=_0x59aff7&&_0x59aff7[_0x5d0802('0x240f')]==0x1?_0x59aff7[_0x5d0802('0x269a')][0x0]:null,_0x2368a0[_0x5d0802('0x243c')]=_0x179d22['parseCrudPermissions'](_0x2368a0[_0x5d0802('0x17aa')]?_0x2368a0[_0x5d0802('0x17aa')][_0x5d0802('0x243c')]:null),_0x2368a0['success']=_0x17dfcb,_0x2368a0[_0x5d0802('0x1089')]=_0x32cee8,_0x2368a0[_0x5d0802('0x6df')]=_0x4a0f7b,_0x2368a0[_0x5d0802('0x58')]=_0x1cc64e,_0x2368a0['goToTrunk']=_0x218f95,_0x2368a0['onSave']=_0x1e0bee,_0x4ff3cd['on'](_0x5d0802('0x2240'),_0x2368a0[_0x5d0802('0x1303')]);function _0x32cee8(){const _0x282cf5=_0x5d0802;let _0x4d371c;for(let _0xf1f411=0x0;_0xf1f411<_0x2368a0[_0x282cf5('0xf24')][_0x282cf5('0x264b')];_0xf1f411+=0x1){_0x4d371c=_0x2cfb05()[_0x282cf5('0xede')](_0x2368a0[_0x282cf5('0x24e3')],['id',_0x2368a0[_0x282cf5('0xf24')][_0xf1f411]['id']]),_0x4d371c>=0x0&&_0x2cfb05()['merge'](_0x2368a0[_0x282cf5('0xf24')][_0xf1f411],_0x2cfb05()[_0x282cf5('0x1a08')](_0x2368a0[_0x282cf5('0x24e3')][_0x4d371c],_0x580aa5));}}function _0x4a0f7b(_0x247853){const _0x83e5db=_0x5d0802;_0x6a9ca4['show'](_0x6a9ca4[_0x83e5db('0x31d')]()[_0x83e5db('0x2339')](!![])[_0x83e5db('0xcdc')](_0x83e5db('0x58a'))[_0x83e5db('0xf3c')](_0x83e5db('0x1174'))['ok']('Ok')[_0x83e5db('0x203b')](_0x247853));}function _0x21afc5(_0x3c7fdb,_0x5bc4e6,_0x54fe09){const _0x331909=_0x5d0802;_0x5bc4e6>=0x0&&_0x2cfb05()[_0x331909('0xcc3')](_0x3c7fdb[_0x5bc4e6],_0x2cfb05()[_0x331909('0x1a08')](_0x54fe09,_0x580aa5));}function _0x1e0bee(_0x30f7ca){const _0x4196bb=_0x5d0802,_0x32da7f=_0x2cfb05()[_0x4196bb('0xede')](_0x2368a0[_0x4196bb('0xf24')],['id',_0x30f7ca['id']]),_0x2c3f39=_0x2cfb05()['findIndex'](_0x2368a0[_0x4196bb('0x24e3')],['id',_0x30f7ca['id']]);_0x21afc5(_0x2368a0[_0x4196bb('0xf24')],_0x32da7f,_0x30f7ca),_0x21afc5(_0x2368a0[_0x4196bb('0x24e3')],_0x2c3f39,_0x30f7ca);}let _0x4f684f=!![],_0x30c3b4=0x1;_0x29c186[_0x5d0802('0xe83')](_0x5d0802('0x12d8'),function(_0x173943,_0x2abca8){const _0x40bc8b=_0x5d0802;_0x4f684f?_0x4af243(function(){_0x4f684f=![];}):(!_0x2abca8&&(_0x30c3b4=_0x2368a0['query'][_0x40bc8b('0x1a43')]),_0x173943!==_0x2abca8&&(_0x2368a0[_0x40bc8b('0x2218')][_0x40bc8b('0x1a43')]=0x1),!_0x173943&&(_0x2368a0[_0x40bc8b('0x2218')]['page']=_0x30c3b4),_0x2368a0[_0x40bc8b('0x58')]());});function _0x17dfcb(_0x191dd5){const _0x13a987=_0x5d0802;_0x2368a0['count']=_0x191dd5[_0x13a987('0x240f')],_0x2368a0[_0x13a987('0xf24')]=_0x191dd5?_0x191dd5[_0x13a987('0x269a')]?_0x191dd5[_0x13a987('0x269a')]:[]:[],_0x32cee8();}function _0x1cc64e(){const _0xc6285d=_0x5d0802;_0x2368a0[_0xc6285d('0x2218')][_0xc6285d('0x1098')]=(_0x2368a0[_0xc6285d('0x2218')]['page']-0x1)*_0x2368a0[_0xc6285d('0x2218')][_0xc6285d('0x163f')],_0x179d22[_0xc6285d('0x1ac6')](_0xc6285d('0xa7c'))?_0x2368a0['promise']=_0x28a9af[_0xc6285d('0x3b2')][_0xc6285d('0xd83')](_0x2368a0[_0xc6285d('0x2218')],_0x17dfcb)[_0xc6285d('0xa44')]:(_0x2368a0[_0xc6285d('0x2218')]['id']=_0x2368a0[_0xc6285d('0x7f')]['id'],_0x2368a0[_0xc6285d('0x2218')][_0xc6285d('0xe60')]=_0xc6285d('0x2685'),_0x2368a0[_0xc6285d('0x1f48')]=_0x28a9af[_0xc6285d('0x7f')][_0xc6285d('0x263a')](_0x2368a0['query'],_0x17dfcb)[_0xc6285d('0xa44')]);}_0x29c186['$on'](_0x5d0802('0x1c3f'),function(){_0x4ff3cd['removeAllListeners']('trunk:save');});function _0x218f95(_0x53413b,_0x80e1da){const _0x359f13=_0x5d0802;_0x3bc30a['go'](_0x359f13('0x1f20'),{'id':_0x80e1da['id']});}}const _0x947caf=_0x44eb27,_0x8d9661=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/realtime/realtime.html/realtime.html',_0x47c638=_0x2734b2['p']+_0x36e6f4('0x20e3'),_0x30da8b=_0x2734b2['p']+_0x36e6f4('0x27a9'),_0x3bd580=_0x2734b2['p']+_0x36e6f4('0x28d2'),_0x216d6b=_0x2734b2['p']+_0x36e6f4('0x5c4'),_0x5f48f0=_0x2734b2['p']+_0x36e6f4('0x1a0e'),_0x19fa0e=_0x2734b2['p']+_0x36e6f4('0x544'),_0x4690c6=_0x2734b2['p']+_0x36e6f4('0xa6b'),_0x175f8a=_0x2734b2['p']+_0x36e6f4('0x1c37');_0x36439f[_0x36e6f4('0x1294')]=['$stateProvider'];function _0x36439f(_0x9307b5){const _0x2d8e89=_0x36e6f4;_0x9307b5['state']('app.voice.realtime',{'url':_0x2d8e89('0x1c2e'),'views':{'content@app':{'templateUrl':_0x8d9661,'controller':_0x2d8e89('0x1b14')}},'resolve':{'userProfile':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0xe09d98,_0x35c992){const _0x32d139=_0x2d8e89;return _0x35c992[_0x32d139('0x1ac6')](_0x32d139('0xa7c'))?null:_0xe09d98[_0x32d139('0x18af')](_0x32d139('0x697'),{'fields':'id,name,crudPermissions','id':_0x35c992[_0x32d139('0x26cd')]()[_0x32d139('0xb86')]});}],'userProfileSection':[_0x2d8e89('0x1fbc'),'Auth',function(_0x50c395,_0x596a71){const _0x3a18b0=_0x2d8e89;return _0x596a71[_0x3a18b0('0x1ac6')](_0x3a18b0('0xa7c'))?null:_0x50c395[_0x3a18b0('0x18af')]('userProfileSection@get',{'fields':_0x3a18b0('0xe26'),'userProfileId':_0x596a71[_0x3a18b0('0x26cd')]()[_0x3a18b0('0xb86')],'sectionId':0x19b});}]},'authenticate':!![],'permissionId':0x19b})[_0x2d8e89('0x63f')](_0x2d8e89('0x578'),{'url':_0x2d8e89('0x730'),'controller':'AgentsVoiceRealtimeController\x20as\x20vm','templateUrl':_0x47c638,'resolve':{'pauses':[_0x2d8e89('0x1fbc'),function(_0x2f6b95){const _0x4cfb62=_0x2d8e89;return _0x2f6b95[_0x4cfb62('0x18af')](_0x4cfb62('0x737'),{'nolimit':!![]});}],'agents':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x17ce16,_0x56a808){const _0x22105a=_0x2d8e89;return _0x56a808[_0x22105a('0x1ac6')](_0x22105a('0xa7c'))?_0x17ce16['resolve']('user@get',{'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0x22105a('0x1eff'),'sort':_0x22105a('0x6e1'),'nolimit':!![]}):_0x17ce16[_0x22105a('0x18af')](_0x22105a('0x17c4'),{'id':_0x56a808[_0x22105a('0x26cd')]()['userProfileId'],'section':_0x22105a('0x2391'),'fields':_0x22105a('0x1746'),'role':'agent','sort':_0x22105a('0x6e1'),'nolimit':!![]});}],'userProfile':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x37c702,_0x5d3b10){const _0x33ee4b=_0x2d8e89;return _0x5d3b10[_0x33ee4b('0x1ac6')](_0x33ee4b('0xa7c'))?null:_0x37c702[_0x33ee4b('0x18af')](_0x33ee4b('0x697'),{'fields':_0x33ee4b('0x686'),'id':_0x5d3b10[_0x33ee4b('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0xe27351,_0x5d6570){const _0x237bf3=_0x2d8e89;return _0x5d6570[_0x237bf3('0x1ac6')](_0x237bf3('0xa7c'))?null:_0xe27351[_0x237bf3('0x18af')](_0x237bf3('0xaf'),{'fields':_0x237bf3('0xe26'),'userProfileId':_0x5d6570['getCurrentUser']()[_0x237bf3('0xb86')],'sectionId':0xca});}],'rpcAgents':['apiResolver',function(_0x7f9d46){const _0x128c9e=_0x2d8e89;return _0x7f9d46[_0x128c9e('0x18af')]('rpc@getAgents');}]},'authenticate':!![],'permissionId':0x19b})[_0x2d8e89('0x63f')](_0x2d8e89('0x214d'),{'url':'/telephones','controller':_0x2d8e89('0x1bb2'),'templateUrl':_0x30da8b,'resolve':{'telephones':['apiResolver',_0x2d8e89('0x21ef'),function(_0x29d3d2,_0x3e6dc3){const _0x5de459=_0x2d8e89;return _0x3e6dc3[_0x5de459('0x1ac6')](_0x5de459('0xa7c'))?_0x29d3d2[_0x5de459('0x18af')](_0x5de459('0x1c80'),{'fields':_0x5de459('0x1b06'),'role':_0x5de459('0x887'),'sort':_0x5de459('0x14dc'),'limit':0xa,'offset':0x0}):_0x29d3d2[_0x5de459('0x18af')]('userProfile@getResources',{'id':_0x3e6dc3[_0x5de459('0x26cd')]()['userProfileId'],'section':'Telephones','fields':_0x5de459('0x1b06'),'role':_0x5de459('0x887'),'sort':_0x5de459('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x2d8e89('0x21ef'),function(_0x4959da,_0x1f8443){const _0x13a6b3=_0x2d8e89;return _0x1f8443[_0x13a6b3('0x1ac6')]('admin')?null:_0x4959da[_0x13a6b3('0x18af')](_0x13a6b3('0x697'),{'fields':_0x13a6b3('0x686'),'id':_0x1f8443[_0x13a6b3('0x26cd')]()[_0x13a6b3('0xb86')]});}],'userProfileSection':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x3d9713,_0x384c4a){const _0x56868e=_0x2d8e89;return _0x384c4a['hasRole'](_0x56868e('0xa7c'))?null:_0x3d9713[_0x56868e('0x18af')](_0x56868e('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x384c4a[_0x56868e('0x26cd')]()[_0x56868e('0xb86')],'sectionId':0xcb});}],'rpcTelephones':[_0x2d8e89('0x1fbc'),function(_0x4253ee){const _0x2e98c7=_0x2d8e89;return _0x4253ee[_0x2e98c7('0x18af')]('rpc@getTelephones');}]},'authenticate':!![],'permissionId':0x19b})['state'](_0x2d8e89('0x13ae'),{'url':'/trunks','controller':'TrunksVoiceRealtimeController\x20as\x20vm','templateUrl':_0x3bd580,'resolve':{'trunks':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x59bc46,_0x571123){const _0x4cc145=_0x2d8e89;return _0x571123[_0x4cc145('0x1ac6')](_0x4cc145('0xa7c'))?_0x59bc46[_0x4cc145('0x18af')](_0x4cc145('0xfb8'),{'fields':_0x4cc145('0x1776'),'active':!![],'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x59bc46[_0x4cc145('0x18af')]('userProfile@getResources',{'id':_0x571123['getCurrentUser']()[_0x4cc145('0xb86')],'section':_0x4cc145('0x2685'),'fields':'id,name','active':!![],'sort':_0x4cc145('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x2d8e89('0x21ef'),function(_0x44bdc2,_0x789236){const _0x5382ef=_0x2d8e89;return _0x789236['hasRole'](_0x5382ef('0xa7c'))?null:_0x44bdc2[_0x5382ef('0x18af')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x789236[_0x5382ef('0x26cd')]()[_0x5382ef('0xb86')]});}],'userProfileSection':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x4841b7,_0x73235e){const _0xd46771=_0x2d8e89;return _0x73235e[_0xd46771('0x1ac6')](_0xd46771('0xa7c'))?null:_0x4841b7[_0xd46771('0x18af')](_0xd46771('0xaf'),{'fields':_0xd46771('0xe26'),'userProfileId':_0x73235e[_0xd46771('0x26cd')]()['userProfileId'],'sectionId':0x3f3});}],'rpcTrunks':['apiResolver',function(_0x4caf31){const _0x3320a4=_0x2d8e89;return _0x4caf31[_0x3320a4('0x18af')]('rpc@getTrunks');}]},'authenticate':!![],'permissionId':0x19b})[_0x2d8e89('0x63f')](_0x2d8e89('0xde0'),{'url':_0x2d8e89('0x1bd2'),'controller':_0x2d8e89('0xdc0'),'templateUrl':_0x216d6b,'resolve':{'queues':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x45187c,_0x200a85){const _0x1f10a9=_0x2d8e89;return _0x200a85[_0x1f10a9('0x1ac6')]('admin')?_0x45187c[_0x1f10a9('0x18af')](_0x1f10a9('0x2700'),{'type':_0x1f10a9('0x14d8'),'sort':_0x1f10a9('0x14dc'),'limit':0xa,'offset':0x0}):_0x45187c[_0x1f10a9('0x18af')](_0x1f10a9('0x17c4'),{'id':_0x200a85[_0x1f10a9('0x26cd')]()[_0x1f10a9('0xb86')],'section':_0x1f10a9('0x1ba2'),'channel':_0x1f10a9('0x21da'),'type':_0x1f10a9('0x14d8'),'sort':_0x1f10a9('0x14dc'),'limit':0xa,'page':0x1});}],'userProfile':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x3b0f07,_0x1cbe59){const _0x5e6816=_0x2d8e89;return _0x1cbe59[_0x5e6816('0x1ac6')](_0x5e6816('0xa7c'))?null:_0x3b0f07[_0x5e6816('0x18af')](_0x5e6816('0x697'),{'fields':_0x5e6816('0x686'),'id':_0x1cbe59['getCurrentUser']()[_0x5e6816('0xb86')]});}],'userProfileSection':[_0x2d8e89('0x1fbc'),'Auth',function(_0x390975,_0x16c766){const _0x3f6b11=_0x2d8e89;return _0x16c766[_0x3f6b11('0x1ac6')]('admin')?null:_0x390975[_0x3f6b11('0x18af')](_0x3f6b11('0xaf'),{'fields':_0x3f6b11('0xe26'),'userProfileId':_0x16c766[_0x3f6b11('0x26cd')]()[_0x3f6b11('0xb86')],'sectionId':0x191});}],'rpcQueues':[_0x2d8e89('0x1fbc'),function(_0x1bec4c){const _0x4cb4b2=_0x2d8e89;return _0x1bec4c['resolve'](_0x4cb4b2('0x85d'));}]},'authenticate':!![],'permissionId':0x19b})[_0x2d8e89('0x63f')](_0x2d8e89('0x1bc4'),{'url':_0x2d8e89('0xb8e'),'controller':_0x2d8e89('0x1cc7'),'templateUrl':_0x5f48f0,'resolve':{'agents':['apiResolver',_0x2d8e89('0x21ef'),function(_0x10e7d1,_0x981438){const _0x10a77d=_0x2d8e89;return _0x981438[_0x10a77d('0x1ac6')](_0x10a77d('0xa7c'))?_0x10e7d1[_0x10a77d('0x18af')](_0x10a77d('0x1c80'),{'fields':_0x10a77d('0x1111'),'role':_0x10a77d('0x1eff'),'nolimit':!![]}):_0x10e7d1[_0x10a77d('0x18af')](_0x10a77d('0x17c4'),{'id':_0x981438[_0x10a77d('0x26cd')]()[_0x10a77d('0xb86')],'section':_0x10a77d('0x2391'),'fields':'id,name,role,context','role':_0x10a77d('0x1eff'),'nolimit':!![]});}],'queues':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x3ab1e3,_0x21a1c0){const _0x203319=_0x2d8e89;return _0x21a1c0[_0x203319('0x1ac6')](_0x203319('0xa7c'))?_0x3ab1e3[_0x203319('0x18af')]('voiceQueue@get',{'type':_0x203319('0x14d8'),'sort':'-updatedAt','nolimit':!![]}):_0x3ab1e3[_0x203319('0x18af')](_0x203319('0x17c4'),{'id':_0x21a1c0['getCurrentUser']()[_0x203319('0xb86')],'section':'VoiceQueues','channel':_0x203319('0x21da'),'type':'inbound','sort':_0x203319('0x14dc'),'nolimit':!![]});}],'userProfile':['apiResolver',_0x2d8e89('0x21ef'),function(_0x36a5eb,_0x19dfc1){const _0x3fee28=_0x2d8e89;return _0x19dfc1[_0x3fee28('0x1ac6')](_0x3fee28('0xa7c'))?null:_0x36a5eb['resolve'](_0x3fee28('0x697'),{'fields':_0x3fee28('0x686'),'id':_0x19dfc1[_0x3fee28('0x26cd')]()[_0x3fee28('0xb86')]});}],'userProfileSection':['apiResolver','Auth',function(_0x2ff0f3,_0x2e285a){const _0x5a41ef=_0x2d8e89;return _0x2e285a['hasRole'](_0x5a41ef('0xa7c'))?null:_0x2ff0f3[_0x5a41ef('0x18af')](_0x5a41ef('0xaf'),{'fields':_0x5a41ef('0xe26'),'userProfileId':_0x2e285a[_0x5a41ef('0x26cd')]()[_0x5a41ef('0xb86')],'sectionId':0x191});}],'rpcVoiceQueuesChannels':[_0x2d8e89('0x1fbc'),function(_0x33e0ae){const _0x1382b1=_0x2d8e89;return _0x33e0ae[_0x1382b1('0x18af')](_0x1382b1('0x25a'));}]},'authenticate':!![],'permissionId':0x19b})[_0x2d8e89('0x63f')](_0x2d8e89('0xf59'),{'url':'/abandonedcalls','controller':_0x2d8e89('0xb08'),'templateUrl':_0x19fa0e,'resolve':{'agents':[_0x2d8e89('0x1fbc'),'Auth',function(_0x56271e,_0x2d66e9){const _0x53aa2b=_0x2d8e89;return _0x2d66e9[_0x53aa2b('0x1ac6')](_0x53aa2b('0xa7c'))?_0x56271e[_0x53aa2b('0x18af')](_0x53aa2b('0x1c80'),{'fields':_0x53aa2b('0x1111'),'role':'agent','nolimit':!![]}):_0x56271e[_0x53aa2b('0x18af')](_0x53aa2b('0x17c4'),{'id':_0x2d66e9['getCurrentUser']()[_0x53aa2b('0xb86')],'section':_0x53aa2b('0x2391'),'fields':_0x53aa2b('0x1111'),'role':_0x53aa2b('0x1eff'),'nolimit':!![]});}],'queues':['apiResolver','Auth',function(_0x1d6669,_0xfef69d){const _0x1f1f27=_0x2d8e89;return _0xfef69d[_0x1f1f27('0x1ac6')]('admin')?_0x1d6669[_0x1f1f27('0x18af')](_0x1f1f27('0x2700'),{'type':'inbound','sort':_0x1f1f27('0x14dc'),'nolimit':!![]}):_0x1d6669[_0x1f1f27('0x18af')](_0x1f1f27('0x17c4'),{'id':_0xfef69d['getCurrentUser']()[_0x1f1f27('0xb86')],'section':'VoiceQueues','channel':'voice','type':_0x1f1f27('0x14d8'),'sort':'-updatedAt','nolimit':!![]});}],'dispositions':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x285048,_0x52b738){const _0x318d85=_0x2d8e89;return _0x52b738[_0x318d85('0x1ac6')](_0x318d85('0xa7c'))?_0x285048[_0x318d85('0x18af')](_0x318d85('0x1e98'),{'fields':_0x318d85('0x1f07'),'sort':'-updatedAt','MailAccountId':_0x318d85('0x15d7'),'FaxAccountId':_0x318d85('0x15d7'),'SmsAccountId':_0x318d85('0x15d7'),'WhatsappAccountId':'null','OpenchannelAccountId':_0x318d85('0x15d7'),'ChatWebsiteId':_0x318d85('0x15d7'),'ListId':_0x318d85('0x15d7'),'nolimit':!![]}):_0x285048[_0x318d85('0x18af')](_0x318d85('0x17c4'),{'id':_0x52b738[_0x318d85('0x26cd')]()['userProfileId'],'section':_0x318d85('0x10fb'),'fields':_0x318d85('0x1979'),'sort':_0x318d85('0x14dc'),'MailAccountId':_0x318d85('0x15d7'),'FaxAccountId':_0x318d85('0x15d7'),'SmsAccountId':_0x318d85('0x15d7'),'WhatsappAccountId':'null','OpenchannelAccountId':_0x318d85('0x15d7'),'ChatWebsiteId':_0x318d85('0x15d7'),'ListId':_0x318d85('0x15d7'),'nolimit':!![]});}],'userProfile':[_0x2d8e89('0x1fbc'),'Auth',function(_0x320e01,_0x5c706a){const _0x3dd574=_0x2d8e89;return _0x5c706a[_0x3dd574('0x1ac6')](_0x3dd574('0xa7c'))?null:_0x320e01[_0x3dd574('0x18af')](_0x3dd574('0x697'),{'fields':_0x3dd574('0x686'),'id':_0x5c706a[_0x3dd574('0x26cd')]()[_0x3dd574('0xb86')]});}],'userProfileSection':[_0x2d8e89('0x1fbc'),_0x2d8e89('0x21ef'),function(_0x4b495d,_0x384413){const _0x285b2d=_0x2d8e89;return _0x384413[_0x285b2d('0x1ac6')]('admin')?null:_0x4b495d[_0x285b2d('0x18af')](_0x285b2d('0xaf'),{'fields':_0x285b2d('0xe26'),'userProfileId':_0x384413[_0x285b2d('0x26cd')]()[_0x285b2d('0xb86')],'sectionId':0x191});}]},'authenticate':!![],'permissionId':0x19b})[_0x2d8e89('0x63f')](_0x2d8e89('0x517'),{'url':_0x2d8e89('0x268d'),'controller':_0x2d8e89('0x5c3'),'templateUrl':_0x4690c6,'resolve':{'queues':[_0x2d8e89('0x1fbc'),'Auth',function(_0x46a4ee,_0x49a969){const _0x5ca772=_0x2d8e89;return _0x49a969[_0x5ca772('0x1ac6')](_0x5ca772('0xa7c'))?_0x46a4ee['resolve']('voiceQueue@get',{'type':_0x5ca772('0x14d8'),'fields':'id,name','sort':_0x5ca772('0x14dc'),'limit':0xa,'offset':0x0}):_0x46a4ee['resolve'](_0x5ca772('0x17c4'),{'id':_0x49a969[_0x5ca772('0x26cd')]()[_0x5ca772('0xb86')],'section':_0x5ca772('0x1ba2'),'channel':_0x5ca772('0x21da'),'type':_0x5ca772('0x14d8'),'sort':_0x5ca772('0x14dc'),'nolimit':!![]});}],'userProfile':['apiResolver',_0x2d8e89('0x21ef'),function(_0xd31bbd,_0x104f09){const _0x5e981e=_0x2d8e89;return _0x104f09[_0x5e981e('0x1ac6')](_0x5e981e('0xa7c'))?null:_0xd31bbd['resolve']('userProfile@get',{'fields':_0x5e981e('0x686'),'id':_0x104f09['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x2d8e89('0x1fbc'),'Auth',function(_0x1d951c,_0x57b3d8){const _0x3d6aed=_0x2d8e89;return _0x57b3d8['hasRole'](_0x3d6aed('0xa7c'))?null:_0x1d951c[_0x3d6aed('0x18af')]('userProfileSection@get',{'fields':_0x3d6aed('0xe26'),'userProfileId':_0x57b3d8[_0x3d6aed('0x26cd')]()[_0x3d6aed('0xb86')],'sectionId':0x191});}],'rpcQueues':['apiResolver',function(_0x40dacd){const _0x2287fd=_0x2d8e89;return _0x40dacd[_0x2287fd('0x18af')]('rpc@getVoiceQueues');}]},'authenticate':!![],'permissionId':0x19b})[_0x2d8e89('0x63f')](_0x2d8e89('0x1154'),{'url':_0x2d8e89('0x16e3'),'controller':_0x2d8e89('0x1132'),'templateUrl':_0x175f8a,'resolve':{'rpcCalls':[_0x2d8e89('0x1fbc'),function(_0x53d87f){const _0x26e82b=_0x2d8e89;return _0x53d87f[_0x26e82b('0x18af')](_0x26e82b('0x12a2'));}]},'authenticate':!![],'permissionId':0x19b});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x468'),[])[_0x36e6f4('0xe11')](_0x36439f)[_0x36e6f4('0x75e')]('AbandonedCallsVoiceRealtimeController',_0x16230b)[_0x36e6f4('0x75e')](_0x36e6f4('0x1b2b'),_0x45eae1)[_0x36e6f4('0x75e')](_0x36e6f4('0xf1f'),_0x14ec7d)['controller'](_0x36e6f4('0xcc9'),_0x32243a)['controller']('QueueParamsVoiceRealtimeController',_0x833de4)[_0x36e6f4('0x75e')]('QueuesVoiceRealtimeController',_0x46c1af)[_0x36e6f4('0x87c')](_0x36e6f4('0x1a02'),_0xa75680)[_0x36e6f4('0x75e')](_0x36e6f4('0x1c14'),_0x360f7)[_0x36e6f4('0x75e')](_0x36e6f4('0xfec'),_0x234932)[_0x36e6f4('0x75e')]('TrunksVoiceRealtimeController',_0x947caf);const _0x47892e=_0x2734b2['p']+_0x36e6f4('0x499');_0x4c5f73[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$mdSidenav','$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),'$translate',_0x36e6f4('0x26f2'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x4c5f73(_0x2f73da,_0x2ddd20,_0x14c423,_0x55a727,_0x5a92c5,_0x2bc715,_0x7eb270,_0x15c947,_0x4ba16d,_0x873e45,_0x2eda80,_0x1d43fa,_0x3b547a,_0x4fe2c7,_0xa23016,_0x217e2f,_0x286315){const _0x2efa33=_0x36e6f4,_0x1ec724=this;_0x1ec724[_0x2efa33('0x5c9')]=_0x217e2f,_0x1ec724[_0x2efa33('0xf8a')]=_0x286315,_0x1ec724[_0x2efa33('0x98')]=_0xa23016[_0x2efa33('0x26cd')](),_0x1ec724[_0x2efa33('0x26f2')]=_0x4ba16d||{'count':0x0,'rows':[]},_0x1ec724[_0x2efa33('0x7f')]=_0x873e45,_0x1ec724[_0x2efa33('0x17aa')]=_0x2eda80&&_0x2eda80[_0x2efa33('0x240f')]==0x1?_0x2eda80[_0x2efa33('0x269a')][0x0]:null,_0x1ec724[_0x2efa33('0x243c')]=_0xa23016[_0x2efa33('0xd87')](_0x1ec724[_0x2efa33('0x17aa')]?_0x1ec724[_0x2efa33('0x17aa')][_0x2efa33('0x243c')]:null),_0x1ec724[_0x2efa33('0x916')]=_0x2efa33('0x26f2'),_0x1ec724[_0x2efa33('0xef5')]='',_0x1ec724[_0x2efa33('0x104c')]=null,_0x1ec724['selectedChanSpies']=[],_0x1ec724['query']={'fields':_0x2efa33('0x96b'),'sort':_0x2efa33('0x14dc'),'limit':0xa,'page':0x1},_0x1ec724['arrayoptions']=_0x2cfb05()[_0x2efa33('0x155c')]([{'option':_0x2efa33('0x232'),'value':_0x2efa33('0xf0b')},{'option':_0x2efa33('0x1099'),'value':_0x2efa33('0x2483')},{'option':_0x2efa33('0x1961'),'value':_0x2efa33('0xdf9')},{'option':'o:\x20Only\x20listen\x20to\x20audio\x20coming\x20from\x20this\x20channel.','value':_0x2efa33('0x13f6')},{'option':'q:\x20Don\x27t\x20play\x20a\x20beep\x20when\x20beginning\x20to\x20spy\x20on\x20a\x20channel,\x20or\x20speak\x20the\x20selected\x20channel\x20name.','value':_0x2efa33('0x6d7')},{'option':'s:\x20Skip\x20the\x20playback\x20of\x20the\x20channel\x20type\x20(i.e.\x20SIP,\x20IAX,\x20etc)\x20when\x20speaking\x20the\x20selected\x20channel\x20name.','value':_0x2efa33('0x1629')},{'option':_0x2efa33('0x12f8'),'value':_0x2efa33('0xf47')},{'option':_0x2efa33('0x10b'),'value':'\x27w\x27'},{'option':_0x2efa33('0x238a'),'value':_0x2efa33('0x83d')}],function(_0x3db28e){return _0x2cfb05()['replace'](_0x3db28e['value'],new RegExp('\x27','g'),'');}),_0x1ec724[_0x2efa33('0x1bfb')]=_0x2cfb05()[_0x2efa33('0x155c')]([{'option':_0x2efa33('0xdef'),'value':_0x2efa33('0x91c')},{'option':'gsm','value':'\x27gsm\x27'},{'option':_0x2efa33('0xd43'),'value':_0x2efa33('0x21b7')}],function(_0x21a43a){const _0x2c461b=_0x2efa33;return _0x2cfb05()[_0x2c461b('0xf3')](_0x21a43a['value'],new RegExp('\x27','g'),'');}),_0x1ec724[_0x2efa33('0x1f8e')]=_0x1819b9,_0x1ec724[_0x2efa33('0x8d8')]=_0xe5e60a,_0x1ec724[_0x2efa33('0x103b')]=_0x35b10d,_0x1ec724[_0x2efa33('0x25fb')]=_0x579b62,_0x1ec724[_0x2efa33('0x2719')]=_0x50c7cf,_0x1ec724[_0x2efa33('0xd70')]=_0x2d55da,_0x1ec724['exportSelectedChanSpies']=_0x10e549,_0x1ec724[_0x2efa33('0x2317')]=_0x8cb53a,_0x1ec724[_0x2efa33('0x1de4')]=_0x2b6a50,_0x1ec724[_0x2efa33('0x14ab')]=_0x37ae6e;function _0x1819b9(_0x8e8fe2,_0x143acb){const _0x193012=_0x2efa33;_0x5a92c5[_0x193012('0x1f80')]({'controller':_0x193012('0x1130'),'controllerAs':'vm','templateUrl':_0x47892e,'parent':angular[_0x193012('0x1194')](_0x2bc715[_0x193012('0x8d2')]),'targetEvent':_0x143acb,'clickOutsideToClose':!![],'locals':{'chanSpy':_0x8e8fe2,'chanSpies':_0x1ec724['chanSpies'][_0x193012('0x269a')],'license':_0x1ec724[_0x193012('0x5c9')],'setting':null,'crudPermissions':_0x1ec724[_0x193012('0x243c')]}});}function _0xe5e60a(_0x52c979,_0x11076b){const _0x48fc59=_0x2efa33,_0x4d32dc=_0x5a92c5[_0x48fc59('0x1d26')]()[_0x48fc59('0xcdc')](_0x48fc59('0x288d')+_0x2cfb05()['startCase'](_0x48fc59('0x1ec6'))+'?')[_0x48fc59('0xf3c')](_0x48fc59('0x12b5')+(_0x52c979[_0x48fc59('0x4f0')]||_0x48fc59('0x1ec6'))+'
'+_0x48fc59('0x3f3'))[_0x48fc59('0x8e8')](_0x48fc59('0x8af'))['targetEvent'](_0x11076b)['ok']('OK')[_0x48fc59('0x3f')](_0x48fc59('0x2d3'));_0x5a92c5['show'](_0x4d32dc)[_0x48fc59('0x1166')](function(){_0x2d55da(_0x52c979);},function(){const _0x496030=_0x48fc59;console[_0x496030('0x455')](_0x496030('0x2d3'));});}let _0x28f51d=!![],_0x8aed92=0x1;_0x2f73da['$watch'](_0x2efa33('0x12d8'),function(_0x3b0790,_0x3460e0){const _0x1f30a4=_0x2efa33;_0x28f51d?_0x7eb270(function(){_0x28f51d=![];}):(!_0x3460e0&&(_0x8aed92=_0x1ec724['query'][_0x1f30a4('0x1a43')]),_0x3b0790!==_0x3460e0&&(_0x1ec724[_0x1f30a4('0x2218')][_0x1f30a4('0x1a43')]=0x1),!_0x3b0790&&(_0x1ec724[_0x1f30a4('0x2218')][_0x1f30a4('0x1a43')]=_0x8aed92),_0x1ec724[_0x1f30a4('0x25fb')]());});function _0x35b10d(_0x535a98){const _0x1cfd9d=_0x2efa33;_0x1ec724[_0x1cfd9d('0x26f2')]=_0x535a98||{'count':0x0,'rows':[]};}function _0x579b62(){const _0x90549c=_0x2efa33;_0x1ec724['query']['offset']=(_0x1ec724['query'][_0x90549c('0x1a43')]-0x1)*_0x1ec724[_0x90549c('0x2218')][_0x90549c('0x163f')],_0xa23016[_0x90549c('0x1ac6')](_0x90549c('0xa7c'))?_0x1ec724[_0x90549c('0x1f48')]=_0x1d43fa[_0x90549c('0x35c')][_0x90549c('0xd83')](_0x1ec724[_0x90549c('0x2218')],_0x35b10d)[_0x90549c('0xa44')]:(_0x1ec724['query']['id']=_0x1ec724['userProfile']['id'],_0x1ec724['query']['section']=_0x90549c('0x61c'),_0x1ec724[_0x90549c('0x1f48')]=_0x1d43fa[_0x90549c('0x7f')][_0x90549c('0x263a')](_0x1ec724[_0x90549c('0x2218')],_0x35b10d)[_0x90549c('0xa44')]);}function _0x50c7cf(_0x56af56,_0x18139e){const _0x43cf88=_0x2efa33;_0x5a92c5[_0x43cf88('0x1f80')]({'controller':_0x43cf88('0x1130'),'controllerAs':'vm','templateUrl':_0x47892e,'parent':angular[_0x43cf88('0x1194')](_0x2bc715['body']),'targetEvent':_0x56af56,'clickOutsideToClose':!![],'locals':{'chanSpy':_0x18139e,'chanSpies':_0x1ec724[_0x43cf88('0x26f2')][_0x43cf88('0x269a')],'license':_0x1ec724['license'],'setting':_0x1ec724[_0x43cf88('0xf8a')],'crudPermissions':_0x1ec724['crudPermissions']}});}function _0x2d55da(_0x1b8ac5){const _0xf55aab=_0x2efa33;_0x1d43fa['voiceChanSpy'][_0xf55aab('0x906')]({'id':_0x1b8ac5['id']})[_0xf55aab('0xa44')]['then'](function(){const _0x6e14cc=_0xf55aab;_0x2cfb05()[_0x6e14cc('0x127f')](_0x1ec724[_0x6e14cc('0x26f2')][_0x6e14cc('0x269a')],{'id':_0x1b8ac5['id']}),_0x1ec724[_0x6e14cc('0x26f2')][_0x6e14cc('0x240f')]-=0x1,!_0x1ec724['chanSpies'][_0x6e14cc('0x269a')][_0x6e14cc('0x264b')]&&_0x1ec724['getChanSpies'](),_0x4fe2c7['success']({'title':_0x2cfb05()[_0x6e14cc('0xb35')](_0x6e14cc('0x1ec6'))+_0x6e14cc('0x2b6'),'msg':_0x1b8ac5['name']?_0x1b8ac5[_0x6e14cc('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0xf55aab('0x1a80')](function(_0x2d403e){const _0x50dc96=_0xf55aab;if(_0x2d403e[_0x50dc96('0x25f4')]&&_0x2d403e[_0x50dc96('0x25f4')]['errors']&&_0x2d403e[_0x50dc96('0x25f4')][_0x50dc96('0x61a')]['length']){_0x1ec724['errors']=_0x2d403e[_0x50dc96('0x25f4')][_0x50dc96('0x61a')]||[{'message':_0x2d403e['toString'](),'type':_0x50dc96('0x2182')}];for(let _0x12aced=0x0;_0x12aced<_0x2d403e[_0x50dc96('0x25f4')][_0x50dc96('0x61a')][_0x50dc96('0x264b')];_0x12aced++){_0x4fe2c7[_0x50dc96('0xfc9')]({'title':_0x2d403e['data'][_0x50dc96('0x61a')][_0x12aced]['type'],'msg':_0x2d403e['data'][_0x50dc96('0x61a')][_0x12aced][_0x50dc96('0x1e70')]});}}else _0x4fe2c7[_0x50dc96('0xfc9')]({'title':_0x2d403e[_0x50dc96('0x52d')]?_0x50dc96('0x1e21')+_0x2d403e[_0x50dc96('0x52d')]+_0x50dc96('0x11e1')+_0x2d403e[_0x50dc96('0xe1b')]:_0x50dc96('0x2182'),'msg':_0x2d403e['data']?JSON[_0x50dc96('0xbac')](_0x2d403e[_0x50dc96('0x25f4')][_0x50dc96('0x1e70')]):_0x2d403e['message']||_0x2d403e['toString']()});});}function _0x10e549(){const _0x4f3009=_0x2efa33,_0x2e09e9=angular[_0x4f3009('0x225f')](_0x1ec724[_0x4f3009('0x267f')]);return _0x1ec724[_0x4f3009('0x267f')]=[],_0x2e09e9;}function _0x8cb53a(_0x4fe9fe){const _0x245117=_0x2efa33,_0x15e7f0=_0x5a92c5[_0x245117('0x1d26')]()[_0x245117('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20chanSpies?')[_0x245117('0xf3c')](_0x245117('0x12b5')+_0x1ec724[_0x245117('0x267f')][_0x245117('0x264b')]+_0x245117('0x196d')+_0x245117('0x3f3'))[_0x245117('0x8e8')](_0x245117('0x270c'))[_0x245117('0x203b')](_0x4fe9fe)['ok']('OK')[_0x245117('0x3f')](_0x245117('0x2d3'));_0x5a92c5[_0x245117('0x1f80')](_0x15e7f0)['then'](function(){const _0x4d46e9=_0x245117;_0x1ec724[_0x4d46e9('0x267f')]['forEach'](function(_0x35589e){_0x2d55da(_0x35589e);}),_0x1ec724['selectedChanSpies']=[];});}function _0x2b6a50(){const _0x513a15=_0x2efa33;_0x1ec724[_0x513a15('0x267f')]=[];}function _0x37ae6e(){const _0x2e179f=_0x2efa33;_0x1ec724[_0x2e179f('0x267f')]=_0x1ec724[_0x2e179f('0x26f2')][_0x2e179f('0x269a')];}}const _0x14abd7=_0x4c5f73;_0xd09b11[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x26f2'),'chanSpy',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'crudPermissions'];function _0xd09b11(_0x13dd44,_0x298ee2,_0x94d73e,_0x1e9f57,_0x29662a,_0x6e4648,_0x224b41,_0x3b4794,_0x33847,_0x221242,_0x2f3b45,_0x5ea7e8,_0x29db99,_0x42b73f){const _0x150873=_0x36e6f4,_0x471752=this;_0x471752['currentUser']=_0x2f3b45[_0x150873('0x26cd')](),_0x471752['errors']=[],_0x471752[_0x150873('0xf8a')]=_0x29db99,_0x471752[_0x150873('0x5c9')]=_0x5ea7e8,_0x471752[_0x150873('0x243c')]=_0x42b73f,_0x471752[_0x150873('0x128b')]={},_0x471752[_0x150873('0x2900')]=_0x471752[_0x150873('0xf8a')]&&_0x471752[_0x150873('0xf8a')][_0x150873('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x471752[_0x150873('0xcdc')]=_0x150873('0x27c0'),_0x471752['chanSpy']=angular[_0x150873('0x225f')](_0x33847),_0x471752[_0x150873('0x26f2')]=_0x3b4794,_0x471752[_0x150873('0x1d6b')]=![];!_0x471752[_0x150873('0x1ec6')]&&(_0x471752['chanSpy']={'recordingFormat':_0x150873('0xdef')},_0x471752[_0x150873('0xcdc')]='VOICE.NEW_CHANSPY',_0x471752[_0x150873('0x1d6b')]=!![]);_0x471752[_0x150873('0x12d')]=_0x3dd668,_0x471752[_0x150873('0x1f92')]=_0x47e46f,_0x471752['deletechanSpy']=_0x5e0f01,_0x471752[_0x150873('0x1a9c')]=_0x41848a,_0x471752[_0x150873('0x24a0')]=_0x59adae;function _0x3dd668(){const _0x241e6b=_0x150873;_0x471752[_0x241e6b('0x61a')]=[],_0x221242[_0x241e6b('0x35c')][_0x241e6b('0x9cc')](_0x471752[_0x241e6b('0x1ec6')])[_0x241e6b('0xa44')][_0x241e6b('0x1166')](function(_0xa4b53){const _0x1b8afd=_0x241e6b;_0x471752['chanSpies']['unshift'](_0xa4b53[_0x1b8afd('0x2876')]()),_0x224b41[_0x1b8afd('0x103b')]({'title':_0x1b8afd('0x1840'),'msg':_0x471752['chanSpy'][_0x1b8afd('0x4f0')]?_0x471752[_0x1b8afd('0x1ec6')][_0x1b8afd('0x4f0')]+_0x1b8afd('0x1eda'):''}),_0x59adae(_0xa4b53);})[_0x241e6b('0x1a80')](function(_0x220df8){const _0x28a9f7=_0x241e6b;if(_0x220df8[_0x28a9f7('0x25f4')]&&_0x220df8[_0x28a9f7('0x25f4')][_0x28a9f7('0x61a')]&&_0x220df8['data'][_0x28a9f7('0x61a')]['length']){_0x471752[_0x28a9f7('0x61a')]=_0x220df8[_0x28a9f7('0x25f4')][_0x28a9f7('0x61a')]||[{'message':_0x220df8[_0x28a9f7('0x1586')](),'type':_0x28a9f7('0x14f4')}];for(let _0x224a6e=0x0;_0x224a6e<_0x220df8[_0x28a9f7('0x25f4')][_0x28a9f7('0x61a')][_0x28a9f7('0x264b')];_0x224a6e+=0x1){_0x224b41['error']({'title':_0x220df8[_0x28a9f7('0x25f4')]['errors'][_0x224a6e]['type'],'msg':_0x220df8[_0x28a9f7('0x25f4')][_0x28a9f7('0x61a')][_0x224a6e][_0x28a9f7('0x1e70')]});}}else _0x224b41[_0x28a9f7('0xfc9')]({'title':_0x220df8[_0x28a9f7('0x52d')]?_0x28a9f7('0x1e21')+_0x220df8[_0x28a9f7('0x52d')]+_0x28a9f7('0x11e1')+_0x220df8['statusText']:_0x28a9f7('0x14f4'),'msg':_0x220df8[_0x28a9f7('0x25f4')]?JSON['stringify'](_0x220df8[_0x28a9f7('0x25f4')][_0x28a9f7('0x1e70')]):_0x220df8[_0x28a9f7('0x1586')]()});});}function _0x47e46f(){const _0x15f0a4=_0x150873;_0x471752[_0x15f0a4('0x61a')]=[],_0x221242['voiceChanSpy'][_0x15f0a4('0x1449')]({'id':_0x471752[_0x15f0a4('0x1ec6')]['id']},_0x471752[_0x15f0a4('0x1ec6')])['$promise']['then'](function(_0x2c80db){const _0x40a497=_0x15f0a4,_0x4e565b=_0x2cfb05()[_0x40a497('0xc38')](_0x471752[_0x40a497('0x26f2')],{'id':_0x2c80db['id']});_0x4e565b&&_0x2cfb05()[_0x40a497('0xcc3')](_0x4e565b,_0x2cfb05()['pick'](_0x2c80db['toJSON'](),_0x2cfb05()[_0x40a497('0x14a4')](_0x4e565b))),_0x224b41[_0x40a497('0x103b')]({'title':_0x40a497('0x34a'),'msg':_0x471752[_0x40a497('0x1ec6')][_0x40a497('0x4f0')]?_0x471752[_0x40a497('0x1ec6')][_0x40a497('0x4f0')]+_0x40a497('0x7d'):''}),_0x59adae(_0x2c80db);})[_0x15f0a4('0x1a80')](function(_0x39f6f7){const _0x24aa9d=_0x15f0a4;if(_0x39f6f7[_0x24aa9d('0x25f4')]&&_0x39f6f7[_0x24aa9d('0x25f4')]['errors']&&_0x39f6f7[_0x24aa9d('0x25f4')][_0x24aa9d('0x61a')]['length']){_0x471752['errors']=_0x39f6f7[_0x24aa9d('0x25f4')][_0x24aa9d('0x61a')]||[{'message':_0x39f6f7['toString'](),'type':_0x24aa9d('0x13d3')}];for(let _0x40ce98=0x0;_0x40ce98<_0x39f6f7[_0x24aa9d('0x25f4')]['errors'][_0x24aa9d('0x264b')];_0x40ce98++){_0x224b41['error']({'title':_0x39f6f7[_0x24aa9d('0x25f4')][_0x24aa9d('0x61a')][_0x40ce98][_0x24aa9d('0x1345')],'msg':_0x39f6f7[_0x24aa9d('0x25f4')][_0x24aa9d('0x61a')][_0x40ce98][_0x24aa9d('0x1e70')]});}}else _0x224b41[_0x24aa9d('0xfc9')]({'title':_0x39f6f7[_0x24aa9d('0x52d')]?'API:'+_0x39f6f7[_0x24aa9d('0x52d')]+_0x24aa9d('0x11e1')+_0x39f6f7[_0x24aa9d('0xe1b')]:'api.voiceChanSpy.update','msg':_0x39f6f7[_0x24aa9d('0x25f4')]?JSON[_0x24aa9d('0xbac')](_0x39f6f7[_0x24aa9d('0x25f4')][_0x24aa9d('0x1e70')]):_0x39f6f7['toString']()});});}function _0x5e0f01(_0x3b7e71){const _0x1fd854=_0x150873;_0x471752['errors']=[];const _0x334642=_0x1e9f57['confirm']()[_0x1fd854('0xcdc')]('Are\x20you\x20sure?')['content'](_0x1fd854('0x1970'))[_0x1fd854('0x8e8')](_0x1fd854('0x14cd'))['ok'](_0x1fd854('0x18'))[_0x1fd854('0x3f')](_0x1fd854('0x497'))[_0x1fd854('0x203b')](_0x3b7e71);_0x1e9f57['show'](_0x334642)[_0x1fd854('0x1166')](function(){const _0x25eb57=_0x1fd854;_0x221242[_0x25eb57('0x35c')][_0x25eb57('0x906')]({'id':_0x471752['chanSpy']['id']})['$promise'][_0x25eb57('0x1166')](function(){const _0x5e07b9=_0x25eb57;_0x2cfb05()['remove'](_0x471752[_0x5e07b9('0x26f2')],{'id':_0x471752[_0x5e07b9('0x1ec6')]['id']}),_0x224b41[_0x5e07b9('0x103b')]({'title':_0x5e07b9('0xeb3'),'msg':(_0x471752[_0x5e07b9('0x1ec6')]['name']||_0x5e07b9('0x1ec6'))+_0x5e07b9('0x7cd')}),_0x59adae(_0x471752[_0x5e07b9('0x1ec6')]);})[_0x25eb57('0x1a80')](function(_0x10c1cc){const _0x3c706c=_0x25eb57;if(_0x10c1cc[_0x3c706c('0x25f4')]&&_0x10c1cc[_0x3c706c('0x25f4')]['errors']&&_0x10c1cc[_0x3c706c('0x25f4')][_0x3c706c('0x61a')][_0x3c706c('0x264b')]){_0x471752[_0x3c706c('0x61a')]=_0x10c1cc[_0x3c706c('0x25f4')][_0x3c706c('0x61a')]||[{'message':_0x10c1cc[_0x3c706c('0x1586')](),'type':_0x3c706c('0xf1c')}];for(let _0x265aaa=0x0;_0x265aaa<_0x10c1cc[_0x3c706c('0x25f4')][_0x3c706c('0x61a')]['length'];_0x265aaa++){_0x224b41[_0x3c706c('0xfc9')]({'title':_0x10c1cc[_0x3c706c('0x25f4')]['errors'][_0x265aaa][_0x3c706c('0x1345')],'msg':_0x10c1cc[_0x3c706c('0x25f4')][_0x3c706c('0x61a')][_0x265aaa]['message']});}}else _0x224b41['error']({'title':_0x10c1cc['status']?'API:'+_0x10c1cc['status']+'\x20-\x20'+_0x10c1cc[_0x3c706c('0xe1b')]:_0x3c706c('0xf1c'),'msg':_0x10c1cc[_0x3c706c('0x25f4')]?JSON[_0x3c706c('0xbac')](_0x10c1cc[_0x3c706c('0x25f4')][_0x3c706c('0x1e70')]):_0x10c1cc[_0x3c706c('0x1e70')]||_0x10c1cc[_0x3c706c('0x1586')]()});});},function(){});}function _0x41848a(_0x3af25c){return _0x3af25c===null?undefined:new Date(_0x3af25c);}function _0x59adae(_0x36e841){const _0xc231d3=_0x150873;_0x1e9f57[_0xc231d3('0x1197')](_0x36e841);}}const _0x365d64=_0xd09b11,_0x1a9b31=_0x2734b2['p']+_0x36e6f4('0x7bf');_0x28f2e5['$inject']=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x160a'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x28f2e5(_0x4d1e10,_0x3250c1,_0xdc3b7b,_0x223375,_0x3b210a,_0x5f45bd,_0x3a4133,_0x8b47cc,_0x4ecfb2,_0x4e0bdf,_0x36f04f,_0x57852b,_0x452876,_0x3fc297,_0x361d9c,_0x5661ee,_0xd02756){const _0x474412=_0x36e6f4,_0x1d449d=this;_0x1d449d['license']=_0x5661ee,_0x1d449d[_0x474412('0xf8a')]=_0xd02756,_0x1d449d[_0x474412('0x98')]=_0x361d9c['getCurrentUser'](),_0x1d449d[_0x474412('0x160a')]=_0x4ecfb2||{'count':0x0,'rows':[]},_0x1d449d[_0x474412('0x7f')]=_0x4e0bdf,_0x1d449d['userProfileSection']=_0x36f04f&&_0x36f04f[_0x474412('0x240f')]==0x1?_0x36f04f['rows'][0x0]:null,_0x1d449d[_0x474412('0x243c')]=_0x361d9c[_0x474412('0xd87')](_0x1d449d[_0x474412('0x17aa')]?_0x1d449d[_0x474412('0x17aa')][_0x474412('0x243c')]:null),_0x1d449d[_0x474412('0x916')]=_0x474412('0x160a'),_0x1d449d[_0x474412('0xef5')]='',_0x1d449d[_0x474412('0x104c')]=null,_0x1d449d[_0x474412('0x534')]=[],_0x1d449d['query']={'fields':_0x474412('0x208e'),'sort':'-updatedAt','defaultEntry':_0x474412('0x1607'),'limit':0xa,'page':0x1},_0x1d449d[_0x474412('0x1f8e')]=_0x2b32c4,_0x1d449d[_0x474412('0x8d8')]=_0x8cfe09,_0x1d449d[_0x474412('0x103b')]=_0x3878ef,_0x1d449d[_0x474412('0xf6')]=_0x5561e7,_0x1d449d[_0x474412('0xdc3')]=_0x1104e9,_0x1d449d['deleteContext']=_0x5f521c,_0x1d449d['exportSelectedContexts']=_0x9910ae,_0x1d449d[_0x474412('0x5fd')]=_0x11b54e,_0x1d449d[_0x474412('0x195b')]=_0x98e6d2,_0x1d449d[_0x474412('0xbf3')]=_0x537559;function _0x2b32c4(_0x2452ad,_0x3c540f){const _0x16b23d=_0x474412;_0x3b210a['show']({'controller':_0x16b23d('0x134f'),'controllerAs':'vm','templateUrl':_0x1a9b31,'parent':angular['element'](_0x5f45bd['body']),'targetEvent':_0x3c540f,'clickOutsideToClose':!![],'locals':{'context':_0x2452ad,'contexts':_0x1d449d[_0x16b23d('0x160a')][_0x16b23d('0x269a')],'license':_0x1d449d['license'],'setting':null,'crudPermissions':_0x1d449d['crudPermissions']}});}function _0x8cfe09(_0x483a04,_0x2cc16f){const _0x301364=_0x474412,_0xf04a8e=_0x3b210a[_0x301364('0x1d26')]()['title'](_0x301364('0x288d')+_0x2cfb05()[_0x301364('0xb35')](_0x301364('0xe1c'))+'?')['htmlContent'](_0x301364('0x12b5')+(_0x483a04[_0x301364('0x4f0')]||_0x301364('0xe1c'))+_0x301364('0xace')+'\x20will\x20be\x20deleted.')[_0x301364('0x8e8')](_0x301364('0x1226'))['targetEvent'](_0x2cc16f)['ok']('OK')[_0x301364('0x3f')](_0x301364('0x2d3'));_0x3b210a[_0x301364('0x1f80')](_0xf04a8e)[_0x301364('0x1166')](function(){_0x5f521c(_0x483a04);},function(){const _0xd0b89d=_0x301364;console[_0xd0b89d('0x455')](_0xd0b89d('0x2d3'));});}let _0x40905f=!![],_0x4c462e=0x1;_0x4d1e10['$watch'](_0x474412('0x12d8'),function(_0x269f0c,_0x5654d3){const _0x5819a5=_0x474412;_0x40905f?_0x3a4133(function(){_0x40905f=![];}):(!_0x5654d3&&(_0x4c462e=_0x1d449d[_0x5819a5('0x2218')][_0x5819a5('0x1a43')]),_0x269f0c!==_0x5654d3&&(_0x1d449d[_0x5819a5('0x2218')]['page']=0x1),!_0x269f0c&&(_0x1d449d[_0x5819a5('0x2218')]['page']=_0x4c462e),_0x1d449d[_0x5819a5('0xf6')]());});function _0x3878ef(_0xfedcda){const _0x27f8a9=_0x474412;_0x1d449d[_0x27f8a9('0x160a')]=_0xfedcda||{'count':0x0,'rows':[]};}function _0x5561e7(){const _0xc721b7=_0x474412;_0x1d449d[_0xc721b7('0x2218')][_0xc721b7('0x1098')]=(_0x1d449d[_0xc721b7('0x2218')]['page']-0x1)*_0x1d449d[_0xc721b7('0x2218')][_0xc721b7('0x163f')],_0x361d9c[_0xc721b7('0x1ac6')]('admin')?_0x1d449d['promise']=_0x57852b[_0xc721b7('0x23b1')][_0xc721b7('0xd83')](_0x1d449d[_0xc721b7('0x2218')],_0x3878ef)['$promise']:(_0x1d449d[_0xc721b7('0x2218')]['id']=_0x1d449d['userProfile']['id'],_0x1d449d[_0xc721b7('0x2218')][_0xc721b7('0xe60')]=_0xc721b7('0x136e'),_0x1d449d[_0xc721b7('0x1f48')]=_0x57852b[_0xc721b7('0x7f')][_0xc721b7('0x263a')](_0x1d449d['query'],_0x3878ef)['$promise']);}function _0x1104e9(_0x49d530,_0x28b76d){const _0x45c1f9=_0x474412;_0x3b210a[_0x45c1f9('0x1f80')]({'controller':_0x45c1f9('0x134f'),'controllerAs':'vm','templateUrl':_0x1a9b31,'parent':angular[_0x45c1f9('0x1194')](_0x5f45bd['body']),'targetEvent':_0x49d530,'clickOutsideToClose':!![],'locals':{'context':_0x28b76d,'contexts':_0x1d449d[_0x45c1f9('0x160a')][_0x45c1f9('0x269a')],'license':_0x1d449d[_0x45c1f9('0x5c9')],'setting':_0x1d449d[_0x45c1f9('0xf8a')],'crudPermissions':_0x1d449d[_0x45c1f9('0x243c')]}});}function _0x5f521c(_0x293a59){const _0x4d8b6c=_0x474412;_0x57852b[_0x4d8b6c('0x23b1')]['delete']({'id':_0x293a59['id']})[_0x4d8b6c('0xa44')]['then'](function(){const _0x25b5d7=_0x4d8b6c;_0x2cfb05()[_0x25b5d7('0x127f')](_0x1d449d[_0x25b5d7('0x160a')][_0x25b5d7('0x269a')],{'id':_0x293a59['id']}),_0x1d449d[_0x25b5d7('0x160a')][_0x25b5d7('0x240f')]-=0x1,!_0x1d449d[_0x25b5d7('0x160a')]['rows'][_0x25b5d7('0x264b')]&&_0x1d449d['getContexts'](),_0x3fc297[_0x25b5d7('0x103b')]({'title':_0x2cfb05()['startCase']('Context')+_0x25b5d7('0x2b6'),'msg':_0x293a59[_0x25b5d7('0x4f0')]?_0x293a59[_0x25b5d7('0x4f0')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x509d7f){const _0x3f5410=_0x4d8b6c;if(_0x509d7f[_0x3f5410('0x25f4')]&&_0x509d7f[_0x3f5410('0x25f4')][_0x3f5410('0x61a')]&&_0x509d7f['data']['errors'][_0x3f5410('0x264b')]){_0x1d449d[_0x3f5410('0x61a')]=_0x509d7f['data'][_0x3f5410('0x61a')]||[{'message':_0x509d7f['toString'](),'type':'SYSTEM:DELETEvoiceContext'}];for(let _0x2a30cf=0x0;_0x2a30cf<_0x509d7f[_0x3f5410('0x25f4')]['errors'][_0x3f5410('0x264b')];_0x2a30cf++){_0x3fc297[_0x3f5410('0xfc9')]({'title':_0x509d7f['data'][_0x3f5410('0x61a')][_0x2a30cf]['type'],'msg':_0x509d7f['data']['errors'][_0x2a30cf][_0x3f5410('0x1e70')]});}}else _0x3fc297[_0x3f5410('0xfc9')]({'title':_0x509d7f[_0x3f5410('0x52d')]?'API:'+_0x509d7f['status']+_0x3f5410('0x11e1')+_0x509d7f[_0x3f5410('0xe1b')]:_0x3f5410('0x1558'),'msg':_0x509d7f['data']?JSON[_0x3f5410('0xbac')](_0x509d7f['data'][_0x3f5410('0x1e70')]):_0x509d7f[_0x3f5410('0x1e70')]||_0x509d7f[_0x3f5410('0x1586')]()});});}function _0x9910ae(){const _0x5eb13a=_0x474412,_0x181dfb=angular[_0x5eb13a('0x225f')](_0x1d449d['selectedContexts']);return _0x1d449d[_0x5eb13a('0x534')]=[],_0x181dfb;}function _0x11b54e(_0x4357ef){const _0x54b4de=_0x474412,_0x534334=_0x3b210a['confirm']()[_0x54b4de('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20contexts?')['htmlContent'](_0x54b4de('0x12b5')+_0x1d449d[_0x54b4de('0x534')][_0x54b4de('0x264b')]+_0x54b4de('0x196d')+_0x54b4de('0x3f3'))[_0x54b4de('0x8e8')](_0x54b4de('0x222a'))[_0x54b4de('0x203b')](_0x4357ef)['ok']('OK')[_0x54b4de('0x3f')]('CANCEL');_0x3b210a[_0x54b4de('0x1f80')](_0x534334)['then'](function(){const _0x1c559b=_0x54b4de;_0x1d449d[_0x1c559b('0x534')][_0x1c559b('0x2782')](function(_0x23320c){_0x5f521c(_0x23320c);}),_0x1d449d[_0x1c559b('0x534')]=[];});}function _0x98e6d2(){const _0x52aa34=_0x474412;_0x1d449d[_0x52aa34('0x534')]=[];}function _0x537559(){const _0x35f475=_0x474412;_0x1d449d[_0x35f475('0x534')]=_0x1d449d[_0x35f475('0x160a')]['rows'];}}const _0x6810f2=_0x28f2e5;_0x365c47['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate','toasty',_0x36e6f4('0x160a'),'context','api','Auth',_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x365c47(_0x3d4eaf,_0xfc0e2,_0x61491c,_0x31cb96,_0x461e3a,_0x351a21,_0x4cdc89,_0x42212b,_0x5a2765,_0x5398e5,_0x1ba723,_0x2d9630,_0x2193fb,_0x3fbc89){const _0x1dadc2=_0x36e6f4,_0x304daa=this;_0x304daa[_0x1dadc2('0x98')]=_0x1ba723[_0x1dadc2('0x26cd')](),_0x304daa[_0x1dadc2('0x61a')]=[],_0x304daa[_0x1dadc2('0xf8a')]=_0x2193fb,_0x304daa[_0x1dadc2('0x5c9')]=_0x2d9630,_0x304daa[_0x1dadc2('0x243c')]=_0x3fbc89,_0x304daa[_0x1dadc2('0x128b')]={},_0x304daa['passwordPattern']=_0x304daa[_0x1dadc2('0xf8a')]&&_0x304daa[_0x1dadc2('0xf8a')][_0x1dadc2('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x304daa['title']=_0x1dadc2('0x576'),_0x304daa[_0x1dadc2('0xe1c')]=angular[_0x1dadc2('0x225f')](_0x5a2765),_0x304daa[_0x1dadc2('0x160a')]=_0x42212b,_0x304daa['newContext']=![];!_0x304daa['context']&&(_0x304daa[_0x1dadc2('0xe1c')]={},_0x304daa[_0x1dadc2('0xcdc')]='VOICE.NEW_CONTEXT',_0x304daa['newContext']=!![]);_0x304daa['addNewContext']=_0x257dc6,_0x304daa['saveContext']=_0x2aadeb,_0x304daa['deleteContext']=_0x12f65a,_0x304daa['getDateFromString']=_0x18f419,_0x304daa['closeDialog']=_0x9a9679;function _0x257dc6(){const _0x3472b0=_0x1dadc2;_0x304daa[_0x3472b0('0x61a')]=[],_0x5398e5[_0x3472b0('0x23b1')][_0x3472b0('0x9cc')](_0x304daa['context'])['$promise']['then'](function(_0x339ff6){const _0x384f7d=_0x3472b0;_0x304daa[_0x384f7d('0x160a')][_0x384f7d('0x2450')](_0x339ff6[_0x384f7d('0x2876')]()),_0x4cdc89['success']({'title':_0x384f7d('0x17e7'),'msg':_0x304daa[_0x384f7d('0xe1c')][_0x384f7d('0x4f0')]?_0x304daa[_0x384f7d('0xe1c')]['name']+_0x384f7d('0x1eda'):''}),_0x9a9679(_0x339ff6);})[_0x3472b0('0x1a80')](function(_0x52f19f){const _0x3ed7a4=_0x3472b0;if(_0x52f19f['data']&&_0x52f19f[_0x3ed7a4('0x25f4')][_0x3ed7a4('0x61a')]&&_0x52f19f[_0x3ed7a4('0x25f4')][_0x3ed7a4('0x61a')][_0x3ed7a4('0x264b')]){_0x304daa['errors']=_0x52f19f['data'][_0x3ed7a4('0x61a')]||[{'message':_0x52f19f[_0x3ed7a4('0x1586')](),'type':_0x3ed7a4('0x2354')}];for(let _0x58259d=0x0;_0x58259d<_0x52f19f[_0x3ed7a4('0x25f4')][_0x3ed7a4('0x61a')][_0x3ed7a4('0x264b')];_0x58259d+=0x1){_0x4cdc89[_0x3ed7a4('0xfc9')]({'title':_0x52f19f[_0x3ed7a4('0x25f4')]['errors'][_0x58259d]['type'],'msg':_0x52f19f[_0x3ed7a4('0x25f4')][_0x3ed7a4('0x61a')][_0x58259d]['message']});}}else _0x4cdc89[_0x3ed7a4('0xfc9')]({'title':_0x52f19f[_0x3ed7a4('0x52d')]?_0x3ed7a4('0x1e21')+_0x52f19f[_0x3ed7a4('0x52d')]+_0x3ed7a4('0x11e1')+_0x52f19f[_0x3ed7a4('0xe1b')]:_0x3ed7a4('0x2354'),'msg':_0x52f19f['data']?JSON['stringify'](_0x52f19f[_0x3ed7a4('0x25f4')][_0x3ed7a4('0x1e70')]):_0x52f19f[_0x3ed7a4('0x1586')]()});});}function _0x2aadeb(){const _0x1bda16=_0x1dadc2;_0x304daa[_0x1bda16('0x61a')]=[],_0x5398e5['voiceContext'][_0x1bda16('0x1449')]({'id':_0x304daa[_0x1bda16('0xe1c')]['id']},_0x304daa[_0x1bda16('0xe1c')])[_0x1bda16('0xa44')][_0x1bda16('0x1166')](function(_0x85c922){const _0x4945fa=_0x1bda16,_0x160c01=_0x2cfb05()[_0x4945fa('0xc38')](_0x304daa[_0x4945fa('0x160a')],{'id':_0x85c922['id']});_0x160c01&&_0x2cfb05()[_0x4945fa('0xcc3')](_0x160c01,_0x2cfb05()[_0x4945fa('0x1a08')](_0x85c922['toJSON'](),_0x2cfb05()[_0x4945fa('0x14a4')](_0x160c01))),_0x4cdc89[_0x4945fa('0x103b')]({'title':'Context\x20properly\x20saved!','msg':_0x304daa[_0x4945fa('0xe1c')][_0x4945fa('0x4f0')]?_0x304daa['context']['name']+'\x20has\x20been\x20saved!':''}),_0x9a9679(_0x85c922);})['catch'](function(_0x2b9d5e){const _0x40a426=_0x1bda16;if(_0x2b9d5e[_0x40a426('0x25f4')]&&_0x2b9d5e[_0x40a426('0x25f4')][_0x40a426('0x61a')]&&_0x2b9d5e[_0x40a426('0x25f4')][_0x40a426('0x61a')]['length']){_0x304daa['errors']=_0x2b9d5e[_0x40a426('0x25f4')][_0x40a426('0x61a')]||[{'message':_0x2b9d5e['toString'](),'type':_0x40a426('0x2109')}];for(let _0xceea3c=0x0;_0xceea3c<_0x2b9d5e['data'][_0x40a426('0x61a')][_0x40a426('0x264b')];_0xceea3c++){_0x4cdc89[_0x40a426('0xfc9')]({'title':_0x2b9d5e[_0x40a426('0x25f4')][_0x40a426('0x61a')][_0xceea3c][_0x40a426('0x1345')],'msg':_0x2b9d5e[_0x40a426('0x25f4')]['errors'][_0xceea3c][_0x40a426('0x1e70')]});}}else _0x4cdc89[_0x40a426('0xfc9')]({'title':_0x2b9d5e['status']?'API:'+_0x2b9d5e[_0x40a426('0x52d')]+_0x40a426('0x11e1')+_0x2b9d5e[_0x40a426('0xe1b')]:'api.voiceContext.update','msg':_0x2b9d5e[_0x40a426('0x25f4')]?JSON[_0x40a426('0xbac')](_0x2b9d5e['data']['message']):_0x2b9d5e[_0x40a426('0x1586')]()});});}function _0x12f65a(_0x257b28){const _0x100b5e=_0x1dadc2;_0x304daa['errors']=[];const _0x10da62=_0x31cb96['confirm']()[_0x100b5e('0xcdc')](_0x100b5e('0x7fb'))[_0x100b5e('0xacc')](_0x100b5e('0x2ef'))['ariaLabel']('Delete\x20Context')['ok']('Delete')[_0x100b5e('0x3f')](_0x100b5e('0x497'))[_0x100b5e('0x203b')](_0x257b28);_0x31cb96[_0x100b5e('0x1f80')](_0x10da62)[_0x100b5e('0x1166')](function(){const _0x509af0=_0x100b5e;_0x5398e5[_0x509af0('0x23b1')][_0x509af0('0x906')]({'id':_0x304daa['context']['id']})[_0x509af0('0xa44')][_0x509af0('0x1166')](function(){const _0x318cee=_0x509af0;_0x2cfb05()[_0x318cee('0x127f')](_0x304daa['contexts'],{'id':_0x304daa[_0x318cee('0xe1c')]['id']}),_0x4cdc89[_0x318cee('0x103b')]({'title':_0x318cee('0xd33'),'msg':(_0x304daa[_0x318cee('0xe1c')][_0x318cee('0x4f0')]||_0x318cee('0xe1c'))+_0x318cee('0x7cd')}),_0x9a9679(_0x304daa[_0x318cee('0xe1c')]);})[_0x509af0('0x1a80')](function(_0x59a72e){const _0x5de6f9=_0x509af0;if(_0x59a72e[_0x5de6f9('0x25f4')]&&_0x59a72e[_0x5de6f9('0x25f4')][_0x5de6f9('0x61a')]&&_0x59a72e[_0x5de6f9('0x25f4')][_0x5de6f9('0x61a')][_0x5de6f9('0x264b')]){_0x304daa[_0x5de6f9('0x61a')]=_0x59a72e[_0x5de6f9('0x25f4')][_0x5de6f9('0x61a')]||[{'message':_0x59a72e['toString'](),'type':'api.voiceContext.delete'}];for(let _0x25aa82=0x0;_0x25aa82<_0x59a72e[_0x5de6f9('0x25f4')]['errors'][_0x5de6f9('0x264b')];_0x25aa82++){_0x4cdc89['error']({'title':_0x59a72e[_0x5de6f9('0x25f4')][_0x5de6f9('0x61a')][_0x25aa82]['type'],'msg':_0x59a72e[_0x5de6f9('0x25f4')]['errors'][_0x25aa82][_0x5de6f9('0x1e70')]});}}else _0x4cdc89[_0x5de6f9('0xfc9')]({'title':_0x59a72e[_0x5de6f9('0x52d')]?_0x5de6f9('0x1e21')+_0x59a72e['status']+'\x20-\x20'+_0x59a72e['statusText']:_0x5de6f9('0x91e'),'msg':_0x59a72e[_0x5de6f9('0x25f4')]?JSON[_0x5de6f9('0xbac')](_0x59a72e[_0x5de6f9('0x25f4')]['message']):_0x59a72e['message']||_0x59a72e[_0x5de6f9('0x1586')]()});});},function(){});}function _0x18f419(_0x32b812){return _0x32b812===null?undefined:new Date(_0x32b812);}function _0x9a9679(_0x343319){const _0x143fbf=_0x1dadc2;_0x31cb96[_0x143fbf('0x1197')](_0x343319);}}const _0x18357b=_0x365c47;_0xa6103f[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xc30'),_0x36e6f4('0x428'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0xa6103f(_0x4bc9df,_0x494559,_0x184343,_0x25a257,_0x3c7c47,_0x247f5f,_0x555eef,_0x2343e5,_0xe6af3,_0x4f61a2,_0x5c983,_0x3c1c4a,_0x42b867,_0x4c62b6){const _0x24c029=_0x36e6f4,_0x59838d=this;_0x59838d[_0x24c029('0x98')]=_0x5c983[_0x24c029('0x26cd')](),_0x59838d[_0x24c029('0x61a')]=[],_0x59838d[_0x24c029('0xf8a')]=_0x42b867,_0x59838d['license']=_0x3c1c4a,_0x59838d[_0x24c029('0x243c')]=_0x4c62b6,_0x59838d[_0x24c029('0x128b')]={},_0x59838d[_0x24c029('0x2900')]=_0x59838d[_0x24c029('0xf8a')]&&_0x59838d[_0x24c029('0xf8a')][_0x24c029('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x59838d[_0x24c029('0xcdc')]=_0x24c029('0x2363'),_0x59838d['inboundroute']=angular[_0x24c029('0x225f')](_0xe6af3),_0x59838d['inboundroutes']=_0x2343e5,_0x59838d[_0x24c029('0x1d34')]=![];!_0x59838d[_0x24c029('0x428')]&&(_0x59838d['inboundroute']={'appdata':_0x24c029('0x1e85'),'type':_0x24c029('0x14d8'),'context':_0x24c029('0x94b')},_0x59838d[_0x24c029('0xcdc')]=_0x24c029('0x274f'),_0x59838d[_0x24c029('0x1d34')]=!![]);_0x59838d[_0x24c029('0x15fd')]=_0x1283c4,_0x59838d[_0x24c029('0xacd')]=_0x4bf90c,_0x59838d[_0x24c029('0x1235')]=_0x5175c2,_0x59838d['getDateFromString']=_0x1666b1,_0x59838d[_0x24c029('0x24a0')]=_0x35477f,_0x5c983[_0x24c029('0x1ac6')]('admin')?_0x4f61a2[_0x24c029('0x23b1')][_0x24c029('0xd83')]({'fields':'id,name','sort':_0x24c029('0x4f0'),'nolimit':'true'})['$promise'][_0x24c029('0x1166')](function(_0x4b8267){const _0x4ae5d9=_0x24c029;_0x59838d[_0x4ae5d9('0x160a')]=_0x4b8267['rows']||[];})[_0x24c029('0x1a80')](function(_0x253a34){const _0x18037e=_0x24c029;_0x555eef[_0x18037e('0xfc9')]({'title':_0x253a34['status']?_0x18037e('0x1e21')+_0x253a34[_0x18037e('0x52d')]+_0x18037e('0x11e1')+_0x253a34[_0x18037e('0xe1b')]:_0x18037e('0x140d'),'msg':_0x253a34[_0x18037e('0x25f4')]?JSON[_0x18037e('0xbac')](_0x253a34[_0x18037e('0x25f4')]):_0x253a34[_0x18037e('0x1586')]()});}):_0x4f61a2['voiceContext'][_0x24c029('0xd83')]({'fields':'id,name','sort':_0x24c029('0x4f0'),'nolimit':'true'})['$promise'][_0x24c029('0x1166')](function(_0x114982){const _0x4f8fb2=_0x24c029;_0x59838d[_0x4f8fb2('0x160a')]=_0x114982[_0x4f8fb2('0x269a')]||[];})[_0x24c029('0x1166')](function(){const _0xfd795d=_0x24c029;return _0x4f61a2['userProfileSection']['get']({'userProfileId':_0x59838d[_0xfd795d('0x98')][_0xfd795d('0xb86')],'sectionId':0x195})[_0xfd795d('0xa44')];})[_0x24c029('0x1166')](function(_0x1413e5){const _0x492faf=_0x24c029,_0x574c41=_0x1413e5&&_0x1413e5[_0x492faf('0x269a')]?_0x1413e5[_0x492faf('0x269a')][0x0]:null;if(!_0x574c41)return _0x4f61a2[_0x492faf('0x23b1')][_0x492faf('0xd83')]({'fields':_0x492faf('0x1776'),'sort':_0x492faf('0x4f0'),'nolimit':'true','defaultEntry':0x1})[_0x492faf('0xa44')][_0x492faf('0x1166')](function(_0x1bddd6){const _0x3eb9d5=_0x492faf;_0x59838d[_0x3eb9d5('0x160a')]=_0x1bddd6['rows']||[];});else{if(!_0x574c41[_0x492faf('0x1a2b')])return _0x4f61a2[_0x492faf('0x4b5')][_0x492faf('0xd83')]({'sectionId':_0x574c41['id']})['$promise'][_0x492faf('0x1166')](function(_0x42f3e4){const _0x453ae8=_0x492faf,_0x5250a3=_0x2cfb05()[_0x453ae8('0x2563')](_0x42f3e4[_0x453ae8('0x269a')],function(_0x52cce8){const _0x1e69a5=_0x453ae8;return _0x2cfb05()[_0x1e69a5('0xc38')](_0x59838d[_0x1e69a5('0x160a')],{'id':_0x52cce8[_0x1e69a5('0x24e8')]});});let _0x50918b=null;_0x59838d[_0x453ae8('0x428')]&&(_0x50918b=_0x2cfb05()[_0x453ae8('0xc38')](_0x59838d[_0x453ae8('0x160a')],{'name':_0x59838d[_0x453ae8('0x428')]['context']}));if(_0x50918b&&!_0x2cfb05()[_0x453ae8('0x1798')](_0x5250a3,['id',_0x50918b['id']])){const _0x482aff=_0x2cfb05()[_0x453ae8('0xc38')](_0x59838d['contexts'],{'id':_0x50918b['id']});_0x482aff[_0x453ae8('0x2378')]=![],_0x5250a3['push'](_0x482aff);}_0x59838d[_0x453ae8('0x160a')]=_0x5250a3;});}})[_0x24c029('0x1a80')](function(_0x5f18df){const _0x18d8de=_0x24c029;_0x555eef[_0x18d8de('0xfc9')]({'title':_0x5f18df[_0x18d8de('0x52d')]?_0x18d8de('0x1e21')+_0x5f18df['status']+_0x18d8de('0x11e1')+_0x5f18df[_0x18d8de('0xe1b')]:_0x18d8de('0x482'),'msg':_0x5f18df[_0x18d8de('0x25f4')]?JSON[_0x18d8de('0xbac')](_0x5f18df[_0x18d8de('0x25f4')]):_0x5f18df[_0x18d8de('0x1586')]()});});function _0x1283c4(){const _0x561320=_0x24c029;_0x59838d[_0x561320('0x61a')]=[],_0x4f61a2[_0x561320('0x1deb')]['save'](_0x59838d[_0x561320('0x428')])[_0x561320('0xa44')]['then'](function(_0x3852a6){const _0x52f2a6=_0x561320;_0x59838d[_0x52f2a6('0xc30')][_0x52f2a6('0x2450')](_0x3852a6[_0x52f2a6('0x2876')]()),_0x555eef['success']({'title':'InboundRoute\x20properly\x20created','msg':_0x59838d[_0x52f2a6('0x428')][_0x52f2a6('0x4f0')]?_0x59838d[_0x52f2a6('0x428')][_0x52f2a6('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x35477f(_0x3852a6);})[_0x561320('0x1a80')](function(_0x2c8914){const _0xe21354=_0x561320;if(_0x2c8914[_0xe21354('0x25f4')]&&_0x2c8914['data'][_0xe21354('0x61a')]&&_0x2c8914['data'][_0xe21354('0x61a')][_0xe21354('0x264b')]){_0x59838d['errors']=_0x2c8914[_0xe21354('0x25f4')]['errors']||[{'message':_0x2c8914[_0xe21354('0x1586')](),'type':_0xe21354('0x1b99')}];for(let _0x1a243a=0x0;_0x1a243a<_0x2c8914[_0xe21354('0x25f4')][_0xe21354('0x61a')][_0xe21354('0x264b')];_0x1a243a+=0x1){_0x555eef[_0xe21354('0xfc9')]({'title':_0x2c8914['data'][_0xe21354('0x61a')][_0x1a243a][_0xe21354('0x1345')],'msg':_0x2c8914['data'][_0xe21354('0x61a')][_0x1a243a][_0xe21354('0x1e70')]});}}else _0x555eef['error']({'title':_0x2c8914['status']?_0xe21354('0x1e21')+_0x2c8914['status']+_0xe21354('0x11e1')+_0x2c8914[_0xe21354('0xe1b')]:_0xe21354('0x1b99'),'msg':_0x2c8914['data']?JSON[_0xe21354('0xbac')](_0x2c8914[_0xe21354('0x25f4')][_0xe21354('0x1e70')]):_0x2c8914[_0xe21354('0x1586')]()});});}function _0x4bf90c(){const _0x46af19=_0x24c029;_0x59838d[_0x46af19('0x61a')]=[],_0x4f61a2[_0x46af19('0x1deb')][_0x46af19('0x1449')]({'id':_0x59838d['inboundroute']['id']},_0x59838d['inboundroute'])['$promise'][_0x46af19('0x1166')](function(_0x4818fe){const _0x13cfb3=_0x46af19,_0x282912=_0x2cfb05()[_0x13cfb3('0xc38')](_0x59838d['inboundroutes'],{'id':_0x4818fe['id']});_0x282912&&_0x2cfb05()[_0x13cfb3('0xcc3')](_0x282912,_0x2cfb05()['pick'](_0x4818fe[_0x13cfb3('0x2876')](),_0x2cfb05()['keys'](_0x282912))),_0x555eef[_0x13cfb3('0x103b')]({'title':_0x13cfb3('0x1dfa'),'msg':_0x59838d[_0x13cfb3('0x428')][_0x13cfb3('0x4f0')]?_0x59838d[_0x13cfb3('0x428')][_0x13cfb3('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x35477f(_0x4818fe);})[_0x46af19('0x1a80')](function(_0xdff853){const _0x806544=_0x46af19;if(_0xdff853[_0x806544('0x25f4')]&&_0xdff853[_0x806544('0x25f4')]['errors']&&_0xdff853['data'][_0x806544('0x61a')][_0x806544('0x264b')]){_0x59838d[_0x806544('0x61a')]=_0xdff853['data']['errors']||[{'message':_0xdff853[_0x806544('0x1586')](),'type':'api.voiceExtension.update'}];for(let _0x2f6f21=0x0;_0x2f6f21<_0xdff853[_0x806544('0x25f4')][_0x806544('0x61a')][_0x806544('0x264b')];_0x2f6f21++){_0x555eef[_0x806544('0xfc9')]({'title':_0xdff853[_0x806544('0x25f4')]['errors'][_0x2f6f21]['type'],'msg':_0xdff853[_0x806544('0x25f4')][_0x806544('0x61a')][_0x2f6f21]['message']});}}else _0x555eef['error']({'title':_0xdff853[_0x806544('0x52d')]?_0x806544('0x1e21')+_0xdff853[_0x806544('0x52d')]+_0x806544('0x11e1')+_0xdff853[_0x806544('0xe1b')]:_0x806544('0x1caf'),'msg':_0xdff853['data']?JSON[_0x806544('0xbac')](_0xdff853[_0x806544('0x25f4')]['message']):_0xdff853['toString']()});});}function _0x5175c2(_0x2ddca0){const _0x4708eb=_0x24c029;_0x59838d[_0x4708eb('0x61a')]=[];const _0x1158d9=_0x25a257['confirm']()[_0x4708eb('0xcdc')]('Are\x20you\x20sure?')['content']('The\x20inboundroute\x20will\x20be\x20deleted.')[_0x4708eb('0x8e8')](_0x4708eb('0xaf3'))['ok']('Delete')['cancel'](_0x4708eb('0x497'))[_0x4708eb('0x203b')](_0x2ddca0);_0x25a257[_0x4708eb('0x1f80')](_0x1158d9)['then'](function(){const _0x3941ea=_0x4708eb;_0x4f61a2[_0x3941ea('0x1deb')]['delete']({'id':_0x59838d[_0x3941ea('0x428')]['id']})[_0x3941ea('0xa44')][_0x3941ea('0x1166')](function(){const _0x40c3ab=_0x3941ea;_0x2cfb05()[_0x40c3ab('0x127f')](_0x59838d[_0x40c3ab('0xc30')],{'id':_0x59838d['inboundroute']['id']}),_0x555eef[_0x40c3ab('0x103b')]({'title':'InboundRoute\x20properly\x20deleted!','msg':(_0x59838d[_0x40c3ab('0x428')][_0x40c3ab('0x4f0')]||_0x40c3ab('0x428'))+_0x40c3ab('0x7cd')}),_0x35477f(_0x59838d[_0x40c3ab('0x428')]);})[_0x3941ea('0x1a80')](function(_0x3e814e){const _0x1bf814=_0x3941ea;if(_0x3e814e[_0x1bf814('0x25f4')]&&_0x3e814e[_0x1bf814('0x25f4')][_0x1bf814('0x61a')]&&_0x3e814e[_0x1bf814('0x25f4')]['errors'][_0x1bf814('0x264b')]){_0x59838d[_0x1bf814('0x61a')]=_0x3e814e[_0x1bf814('0x25f4')][_0x1bf814('0x61a')]||[{'message':_0x3e814e[_0x1bf814('0x1586')](),'type':'api.voiceExtension.delete'}];for(let _0x4dbe4a=0x0;_0x4dbe4a<_0x3e814e[_0x1bf814('0x25f4')][_0x1bf814('0x61a')]['length'];_0x4dbe4a++){_0x555eef[_0x1bf814('0xfc9')]({'title':_0x3e814e[_0x1bf814('0x25f4')][_0x1bf814('0x61a')][_0x4dbe4a][_0x1bf814('0x1345')],'msg':_0x3e814e[_0x1bf814('0x25f4')][_0x1bf814('0x61a')][_0x4dbe4a][_0x1bf814('0x1e70')]});}}else _0x555eef[_0x1bf814('0xfc9')]({'title':_0x3e814e[_0x1bf814('0x52d')]?_0x1bf814('0x1e21')+_0x3e814e[_0x1bf814('0x52d')]+_0x1bf814('0x11e1')+_0x3e814e[_0x1bf814('0xe1b')]:'api.voiceExtension.delete','msg':_0x3e814e[_0x1bf814('0x25f4')]?JSON['stringify'](_0x3e814e[_0x1bf814('0x25f4')]['message']):_0x3e814e['message']||_0x3e814e[_0x1bf814('0x1586')]()});});},function(){});}function _0x1666b1(_0x28e94c){return _0x28e94c===null?undefined:new Date(_0x28e94c);}function _0x35477f(_0x5d742b){const _0x2dbf8b=_0x24c029;_0x25a257[_0x2dbf8b('0x1197')](_0x5d742b);}}const _0x216ace=_0xa6103f,_0x18d613=_0x2734b2['p']+_0x36e6f4('0x1f5'),_0x34396d=_0x2734b2['p']+_0x36e6f4('0x2251'),_0x582171=_0x2734b2['p']+_0x36e6f4('0x318'),_0x453d16=_0x2734b2['p']+_0x36e6f4('0x1fd9'),_0x41769f=_0x2734b2['p']+_0x36e6f4('0x2671'),_0x250e43=_0x2734b2['p']+_0x36e6f4('0x5f'),_0x166f77=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/internaldial/dialog.html/dialog.html',_0x4a642b=_0x2734b2['p']+_0x36e6f4('0x13d0'),_0x4f464e=_0x2734b2['p']+_0x36e6f4('0x283c'),_0x2e93fd=_0x2734b2['p']+_0x36e6f4('0x44f'),_0x5c46f2=_0x2734b2['p']+_0x36e6f4('0x1b2a'),_0x472112=_0x2734b2['p']+_0x36e6f4('0x2901'),_0x38ca21=_0x2734b2['p']+_0x36e6f4('0x26a6');_0x3f8eae[_0x36e6f4('0x1294')]=[_0x36e6f4('0x19e3'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];const _0x32595b={'agi':_0x18d613,'custom':_0x34396d,'dial':_0x582171,'externaldial':_0x453d16,'goto':_0x41769f,'hangup':_0x250e43,'internaldial':_0x166f77,'interval':_0x4a642b,'playback':_0x4f464e,'queue':_0x2e93fd,'ringgroup':_0x5c46f2,'set':_0x472112,'voicemail':_0x38ca21};function _0x3f8eae(_0x417bd3,_0xb314b6,_0x26b216,_0x57fdbb,_0x365b7a){const _0x55637e=_0x36e6f4,_0x25dffc=this;_0x25dffc[_0x55637e('0x98')]=_0x365b7a[_0x55637e('0x26cd')](),_0x25dffc[_0x55637e('0x428')]={},_0x25dffc[_0x55637e('0x1269')]={'count':0x0,'rows':[]},_0x25dffc['selectedInboundRouteApps']=[],_0x25dffc[_0x55637e('0x243c')],_0x25dffc['query']={'sort':_0x55637e('0xfde')},_0x25dffc['apps']=_0x2cfb05()[_0x55637e('0x21bf')](_0x2cfb05()[_0x55637e('0x1eba')]([{'app':'Interval','appType':_0x55637e('0x277c'),'types':[_0x55637e('0x597'),_0x55637e('0x2853'),'list'],'fields':[],'isApp':![]},{'app':_0x55637e('0x28ba'),'appType':_0x55637e('0x1d3e'),'context':_0x55637e('0x94b'),'type':'Inbound','appdata':_0x55637e('0xd0e'),'icon':'icon-apps','options':'xX','interval':'*,*,*,*','answer':!![],'isApp':!![],'extraApi':[{'name':_0x55637e('0x137'),'field':{'name':_0x55637e('0x960'),'key':_0x55637e('0x28d5'),'prefix':_0x55637e('0x158c')},'route':'sound','filters':{'fields':_0x55637e('0x296'),'sort':_0x55637e('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3ef}},{'name':_0x55637e('0x7a7'),'field':{'name':_0x55637e('0x1d3e'),'key':'name'},'route':_0x55637e('0x1943'),'filters':{'type':_0x55637e('0x14d8'),'fields':_0x55637e('0x1c09'),'sort':'name','nolimit':!![]},'permissions':{'section':0x191}}],'fields':[{'title':_0x55637e('0x28ba'),'name':'queue','type':_0x55637e('0x2550'),'values':'queues','value':_0x55637e('0x24ad'),'option':_0x55637e('0x24ad'),'required':!![],'param':0x0},{'title':'Options','name':_0x55637e('0xd39'),'type':'text','param':0x1},{'title':'Url','name':_0x55637e('0x308'),'type':_0x55637e('0x1640'),'param':0x2},{'title':_0x55637e('0x25cb'),'name':_0x55637e('0x960'),'type':'apiselect','values':_0x55637e('0x137'),'value':'\x27/var/opt/motion2/server/files/sounds/converted/{{sound.save_name}}\x27','option':_0x55637e('0x2316'),'defaultValues':[{'value':'\x27\x27','option':'None'}],'param':0x3},{'title':_0x55637e('0x1861'),'name':_0x55637e('0x651'),'type':_0x55637e('0xc45'),'min':0x0,'param':0x4},{'title':_0x55637e('0x271d'),'name':_0x55637e('0x1034'),'type':'text','param':0x5},{'title':_0x55637e('0x20d8'),'name':_0x55637e('0x1c8'),'type':_0x55637e('0x1640'),'param':0x6},{'title':'GoSub','name':_0x55637e('0x281c'),'type':_0x55637e('0x1640'),'param':0x7},{'title':_0x55637e('0x2643'),'name':'rule','type':'text','param':0x8},{'title':_0x55637e('0x833'),'name':_0x55637e('0x2086'),'type':_0x55637e('0xc45'),'min':0x0,'param':0x9},{'title':'Answer','name':_0x55637e('0x1de9'),'type':_0x55637e('0x6f4'),'general':!![]}]},{'app':_0x55637e('0x134'),'appType':_0x55637e('0x19a0'),'context':_0x55637e('0x94b'),'type':_0x55637e('0xa09'),'icon':_0x55637e('0x283f'),'interval':_0x55637e('0x16f'),'answer':!![],'isApp':!![],'extraApi':[{'name':'sounds','field':{'name':_0x55637e('0x960'),'key':_0x55637e('0x28d5'),'prefix':_0x55637e('0x158c')},'route':_0x55637e('0x960'),'filters':{'fields':_0x55637e('0x296'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3ef}}],'fields':[{'title':_0x55637e('0x78e'),'name':_0x55637e('0x823'),'type':_0x55637e('0x2550'),'values':'sounds','value':_0x55637e('0x2049'),'option':_0x55637e('0x1dd9'),'required':!![],'param':0x0},{'title':_0x55637e('0x20f3'),'name':_0x55637e('0xd39'),'type':_0x55637e('0x1640'),'param':0x1},{'title':_0x55637e('0x33c'),'name':_0x55637e('0x1de9'),'type':_0x55637e('0x6f4'),'general':!![]}]},{'app':_0x55637e('0x1d90'),'appType':_0x55637e('0xc77'),'context':_0x55637e('0x94b'),'type':_0x55637e('0xa09'),'icon':'icon-apps','interval':_0x55637e('0x16f'),'options':'xX','isApp':!![],'fields':[{'title':_0x55637e('0x1a37'),'name':_0x55637e('0x134d'),'type':_0x55637e('0x1640'),'required':!![],'param':0x0},{'title':_0x55637e('0x1861'),'name':_0x55637e('0x651'),'type':'number','min':0x0,'param':0x1},{'title':_0x55637e('0x20f3'),'name':_0x55637e('0xd39'),'type':_0x55637e('0x1640'),'param':0x2},{'title':_0x55637e('0x11a2'),'name':'url','type':_0x55637e('0x1640'),'param':0x3}]},{'app':_0x55637e('0x1d90'),'appType':_0x55637e('0x11d9'),'context':_0x55637e('0x94b'),'type':_0x55637e('0xa09'),'icon':_0x55637e('0x283f'),'interval':_0x55637e('0x16f'),'options':'xX','isApp':!![],'extraApi':[{'name':_0x55637e('0x21f6'),'field':{'name':_0x55637e('0x557'),'key':_0x55637e('0x4f0'),'prefix':'SIP/'},'route':'user','filters':{'fields':'id,name,role','sort':_0x55637e('0x4f0'),'nolimit':!![]},'permissions':{'sections':[{'id':0xca,'role':_0x55637e('0x1eff')},{'id':0xcb,'role':_0x55637e('0x887')}]}}],'fields':[{'title':_0x55637e('0x1a6f'),'name':_0x55637e('0x557'),'type':_0x55637e('0x2550'),'values':_0x55637e('0x21f6'),'value':_0x55637e('0x1665'),'option':_0x55637e('0x1501'),'required':!![],'param':0x0},{'title':_0x55637e('0x1861'),'name':_0x55637e('0x651'),'type':_0x55637e('0xc45'),'min':0x0,'param':0x1},{'title':_0x55637e('0x20f3'),'name':'options','type':_0x55637e('0x1640'),'param':0x2},{'title':_0x55637e('0x11a2'),'name':_0x55637e('0xcac'),'type':_0x55637e('0x1640'),'param':0x3}]},{'app':'Dial','appType':_0x55637e('0x18cd'),'context':_0x55637e('0x94b'),'type':_0x55637e('0x14d8'),'icon':_0x55637e('0x283f'),'interval':_0x55637e('0x16f'),'options':'xX','isApp':!![],'extraApi':[{'name':'trunks','field':{'name':'trunk','key':_0x55637e('0x4f0')},'route':_0x55637e('0x3b2'),'filters':{'fields':_0x55637e('0x1776'),'sort':_0x55637e('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f3}}],'fields':[{'title':_0x55637e('0x14c4'),'name':_0x55637e('0x3b2'),'type':'apiselect','values':_0x55637e('0xf24'),'value':_0x55637e('0x912'),'option':_0x55637e('0x912'),'required':!![],'param':0x0},{'title':_0x55637e('0x2114'),'name':'phone','required':!![],'type':_0x55637e('0x1640')},{'title':_0x55637e('0x1861'),'name':'timeout','type':_0x55637e('0xc45'),'min':0x0,'param':0x1},{'title':_0x55637e('0x20f3'),'name':_0x55637e('0xd39'),'type':_0x55637e('0x1640'),'param':0x2},{'title':_0x55637e('0x11a2'),'name':_0x55637e('0xcac'),'type':_0x55637e('0x1640'),'param':0x3}]},{'app':_0x55637e('0x1d90'),'appType':_0x55637e('0x17e0'),'context':_0x55637e('0x94b'),'type':'inbound','icon':'icon-apps','interval':_0x55637e('0x16f'),'options':'xX','isApp':!![],'extraApi':[{'name':'users','field':{'name':_0x55637e('0x1855'),'key':_0x55637e('0x4f0'),'prefix':'SIP/'},'route':_0x55637e('0x557'),'filters':{'fields':_0x55637e('0x1906'),'sort':_0x55637e('0x4f0'),'nolimit':!![]},'permissions':{'sections':[{'id':0xca,'role':_0x55637e('0x1eff')},{'id':0xcb,'role':'telephone'}]}}],'fields':[{'title':_0x55637e('0x1a6f'),'name':'multipleUsers','type':_0x55637e('0x2550'),'multiple':!![],'values':_0x55637e('0x21f6'),'value':_0x55637e('0x1fa6'),'option':_0x55637e('0x498'),'required':!![],'param':0x0},{'title':'Timeout','name':_0x55637e('0x651'),'type':'number','min':0x0,'param':0x1},{'title':_0x55637e('0x20f3'),'name':_0x55637e('0xd39'),'type':_0x55637e('0x1640'),'param':0x2},{'title':'Url','name':_0x55637e('0xcac'),'type':_0x55637e('0x1640'),'param':0x3}]},{'app':_0x55637e('0x1465'),'alias':_0x55637e('0x678'),'appType':_0x55637e('0x1034'),'context':_0x55637e('0x94b'),'type':'inbound','icon':'icon-apps','interval':_0x55637e('0x16f'),'isApp':!![],'extraApi':[{'name':_0x55637e('0x149f'),'field':{'name':_0x55637e('0x2588'),'key':_0x55637e('0x4f0'),'prefix':'agi://127.0.0.1/square,'},'route':_0x55637e('0x7e4'),'filters':{'fields':'id,name','sort':_0x55637e('0x4f0'),'nolimit':!![]},'permissions':{'section':0x44f}}],'fields':[{'title':_0x55637e('0x1593'),'name':_0x55637e('0x2588'),'type':'apiselect','values':'projects','value':_0x55637e('0xdb3'),'option':_0x55637e('0x100d'),'required':!![],'param':0x0}]},{'app':_0x55637e('0x1a03'),'appType':'goTo','context':_0x55637e('0x94b'),'type':_0x55637e('0xa09'),'icon':_0x55637e('0x283f'),'interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':_0x55637e('0x160a'),'field':{'name':_0x55637e('0xe1c'),'key':'name'},'route':'voiceContext','filters':{'fields':'id,name','sort':_0x55637e('0x4f0'),'nolimit':!![]},'permissions':{'section':0x195}}],'fields':[{'title':_0x55637e('0x637'),'name':'context','type':'apiselect','values':_0x55637e('0x160a'),'value':_0x55637e('0x10f8'),'option':_0x55637e('0x10f8'),'required':!![],'param':0x0},{'title':_0x55637e('0x76'),'name':'extension','type':'text','required':!![],'param':0x1},{'title':'Priority','name':_0x55637e('0xfde'),'type':_0x55637e('0x1640'),'required':!![],'param':0x2}]},{'app':_0x55637e('0x133d'),'appType':_0x55637e('0x133d'),'context':_0x55637e('0x94b'),'type':_0x55637e('0xa09'),'icon':_0x55637e('0x283f'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':'Hangup_Cause','name':_0x55637e('0x823'),'type':'select','param':0x0,'values':[{'option':_0x55637e('0x1080'),'value':_0x55637e('0x54e')},{'option':_0x55637e('0xeb7'),'value':_0x55637e('0x995')},{'option':'HANGUPCAUSE_17','value':_0x55637e('0x1c48')},{'option':_0x55637e('0x132b'),'value':_0x55637e('0x2697')},{'option':_0x55637e('0x23f6'),'value':_0x55637e('0x17e4')},{'option':_0x55637e('0xf6c'),'value':'\x2722\x27'},{'option':_0x55637e('0x19f7'),'value':'\x2727\x27'},{'option':'HANGUPCAUSE_38','value':_0x55637e('0x25cd')},{'option':'HANGUPCAUSE_41','value':_0x55637e('0x7cf')}],'translate':!![],'required':!![],'general':!![]}]},{'app':_0x55637e('0x1816'),'appType':_0x55637e('0xceb'),'context':_0x55637e('0x94b'),'type':_0x55637e('0xa09'),'separator':'=','icon':'icon-apps','interval':_0x55637e('0x16f'),'extraApi':[{'name':_0x55637e('0x57a'),'field':{'name':_0x55637e('0x4f0'),'key':_0x55637e('0x4f0')},'route':_0x55637e('0x734'),'filters':{'fields':'id,name','sort':_0x55637e('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'isApp':!![],'fields':[{'title':'Variable','name':_0x55637e('0x4f0'),'type':_0x55637e('0x2550'),'values':_0x55637e('0x57a'),'value':_0x55637e('0x1815'),'option':_0x55637e('0x1815'),'required':!![],'param':0x0},{'title':'Value','name':_0x55637e('0x18e0'),'type':_0x55637e('0x1640'),'required':!![],'param':0x1}]},{'app':null,'appType':'custom','icon':_0x55637e('0x283f'),'type':_0x55637e('0xa09'),'interval':_0x55637e('0x16f'),'isApp':!![],'fields':[{'title':_0x55637e('0x7bc'),'name':_0x55637e('0x746'),'type':_0x55637e('0x1640'),'required':!![],'param':0x0},{'title':_0x55637e('0x81c'),'name':_0x55637e('0x823'),'type':'text','param':0x1}]},{'app':_0x55637e('0x28d8'),'appType':_0x55637e('0x1ee9'),'context':_0x55637e('0x94b'),'icon':_0x55637e('0x283f'),'type':_0x55637e('0xa09'),'interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':_0x55637e('0x138'),'field':{'name':_0x55637e('0x8d4'),'key':'mailbox','suffix':'@from-voicemail'},'route':_0x55637e('0x8d4'),'filters':{'fields':'id,mailbox','sort':_0x55637e('0x1cfc'),'nolimit':!![]},'permissions':{'section':0x196}}],'fields':[{'title':_0x55637e('0x265'),'name':'voiceMail','type':'apiselect','values':'voiceMails','value':_0x55637e('0x614'),'option':_0x55637e('0x113d'),'required':!![],'param':0x0},{'title':_0x55637e('0x20f3'),'name':_0x55637e('0xd39'),'type':'text','param':0x1}]}],[_0x55637e('0x746')]),{'isApp':![]}),_0x25dffc[_0x55637e('0x1480')]={'group':{'name':_0x55637e('0x1b27'),'pull':_0x55637e('0xddc')},'animation':0x64,'sort':![]},_0x25dffc[_0x55637e('0x227f')]={'group':{'name':_0x55637e('0x103e'),'put':_0x55637e('0x1b27')},'animation':0x64,'onAdd':function(_0x3e5c63){const _0x2a9f36=_0x55637e;_0x1d29bc(_0x3e5c63,_0x3e5c63[_0x2a9f36('0x1313')]);},'onSort':function(){_0x58fdbb();}},_0x25dffc[_0x55637e('0x24d5')]=_0x17140c,_0x25dffc[_0x55637e('0x8a2')]=_0x1f5670,_0x25dffc[_0x55637e('0x287c')]=_0x49482c,_0x25dffc[_0x55637e('0x2101')]=_0x1d29bc,_0x25dffc['editInterval']=_0x5dcbf8,_0x25dffc['deleteInboundRouteApp']=_0x4c10e1,_0x25dffc[_0x55637e('0x278e')]=_0x2b2881,_0x25dffc[_0x55637e('0x20a6')]=_0x58fdbb,_0x25dffc['getIntervals']=_0x453757;function _0x17140c(_0x4d03a6,_0x45da2e){const _0x5195a1=_0x55637e;_0x25dffc[_0x5195a1('0x428')]=_0x4d03a6,_0x25dffc[_0x5195a1('0x243c')]=typeof _0x45da2e!=='undefined'?_0x45da2e:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x25dffc[_0x5195a1('0x227f')][_0x5195a1('0xbd0')]=!_0x25dffc['crudPermissions']['canEdit']?!![]:![],_0x25dffc[_0x5195a1('0x2218')][_0x5195a1('0xa51')]=_0x4d03a6['id'],_0x25dffc['query'][_0x5195a1('0x1a55')]=!![],_0x25dffc[_0x5195a1('0x2218')]['nolimit']=!![],_0x25dffc[_0x5195a1('0x287c')](),_0x25dffc[_0x5195a1('0x242')]();}function _0x1f5670(_0x429bfa,_0x23bf7e,_0x5c778e){const _0x160f35=_0x55637e,_0x2efe60=_0xb314b6[_0x160f35('0x1d26')]()['title'](_0x160f35('0xd0f'))[_0x160f35('0xf3c')](_0x160f35('0x12b5')+_0x429bfa[_0x160f35('0x746')]+_0x160f35('0xace')+_0x160f35('0x3f3'))[_0x160f35('0x8e8')](_0x160f35('0x238d'))[_0x160f35('0x203b')](_0x5c778e)['ok']('OK')[_0x160f35('0x3f')](_0x160f35('0x2d3'));_0xb314b6[_0x160f35('0x1f80')](_0x2efe60)[_0x160f35('0x1166')](function(){const _0x587d18=_0x160f35;_0x25dffc[_0x587d18('0x1269')][_0x587d18('0x269a')][_0x587d18('0x57b')](_0x23bf7e,0x1),_0x58fdbb();},function(){const _0x2cffbd=_0x160f35;console['log'](_0x2cffbd('0x2d3'));});}function _0x1d29bc(_0x28b2fc,_0x567bd4){const _0x37defd=_0x55637e;if(_0x25dffc[_0x37defd('0x1269')][_0x37defd('0x269a')]['length']){const _0x1a2a42=_0x25dffc[_0x37defd('0x1269')]['rows'][_0x567bd4]?_0x25dffc['inboundrouteApps']['rows'][_0x567bd4]:_0x25dffc[_0x37defd('0x1269')][_0x37defd('0x269a')][0x0],_0x444fc0=(_0x1a2a42[_0x37defd('0x83f')]||_0x1a2a42[_0x37defd('0x746')])[_0x37defd('0x2574')]();_0xb314b6['show']({'controller':_0x37defd('0x566')+_0x444fc0+'DialogController','controllerAs':'vm','templateUrl':_0x32595b[_0x444fc0],'parent':angular[_0x37defd('0x1194')](_0x26b216['body']),'targetEvent':_0x28b2fc,'clickOutsideToClose':!![],'locals':{'inboundrouteApp':_0x1a2a42,'inboundroute':_0x25dffc[_0x37defd('0x428')],'crudPermissions':_0x25dffc['crudPermissions']}})[_0x37defd('0x1166')](function(_0x581cd2){const _0x13f232=_0x37defd;_0x581cd2&&(_0x581cd2['id']?_0x25dffc['inboundrouteApps'][_0x13f232('0x269a')][_0x567bd4]=_0x581cd2:_0x25dffc[_0x13f232('0x1269')]['rows'][_0x13f232('0x57b')](_0x567bd4,0x0,_0x581cd2),_0x58fdbb());})[_0x37defd('0x1a80')](function(_0x3212ce){const _0x4f7099=_0x37defd;_0x3212ce&&_0x57fdbb[_0x4f7099('0xfc9')]({'title':_0x3212ce['status']?_0x4f7099('0x1e21')+_0x3212ce['status']+_0x4f7099('0x11e1')+_0x3212ce['statusText']:_0x4f7099('0x2e5'),'msg':_0x3212ce[_0x4f7099('0x25f4')]?JSON['stringify'](_0x3212ce['data']):_0x3212ce[_0x4f7099('0x1586')]()});});}}function _0x5dcbf8(_0x3f905d,_0x137dce){const _0x30f1a7=_0x55637e;if(_0x25dffc[_0x30f1a7('0x1269')][_0x30f1a7('0x269a')]['length']){const _0x40f2e0=_0x25dffc['inboundrouteApps'][_0x30f1a7('0x269a')][_0x137dce]?_0x25dffc[_0x30f1a7('0x1269')][_0x30f1a7('0x269a')][_0x137dce]:_0x25dffc[_0x30f1a7('0x1269')][_0x30f1a7('0x269a')][0x0];_0xb314b6[_0x30f1a7('0x1f80')]({'controller':'EditInboundAppintervalDialogController','controllerAs':'vm','templateUrl':_0x4a642b,'parent':angular['element'](_0x26b216[_0x30f1a7('0x8d2')]),'targetEvent':_0x3f905d,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x40f2e0[_0x30f1a7('0x277c')],'IntervalId':_0x40f2e0[_0x30f1a7('0x186f')],'application':!![]},'intervals':[],'crudPermissions':_0x25dffc[_0x30f1a7('0x243c')]}})[_0x30f1a7('0x1166')](function(_0x5bfb3c){const _0x3f1449=_0x30f1a7;_0x5bfb3c&&(_0x40f2e0[_0x3f1449('0x277c')]=_0x5bfb3c['interval']||_0x3f1449('0x16f'),_0x40f2e0['IntervalId']=_0x5bfb3c[_0x3f1449('0x186f')]||null,_0x58fdbb());});}}function _0x58fdbb(){const _0xdac181=_0x55637e,_0x169c88=[_0xdac181('0x1d3e'),'playback'];let _0x21cb00=0x2,_0x480ecd=[];_0x480ecd[_0xdac181('0x1514')]({'type':_0xdac181('0x14d8'),'app':_0xdac181('0x1816'),'appdata':'CDR(type)=inbound','context':_0x25dffc[_0xdac181('0x428')][_0xdac181('0xe1c')],'exten':_0x25dffc['inboundroute'][_0xdac181('0x23ae')],'priority':_0x21cb00++,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']}),_0x480ecd[_0xdac181('0x1514')]({'type':_0xdac181('0x14d8'),'app':'Set','appdata':_0xdac181('0x1d93'),'context':_0x25dffc[_0xdac181('0x428')][_0xdac181('0xe1c')],'exten':_0x25dffc['inboundroute'][_0xdac181('0x23ae')],'priority':_0x21cb00++,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']}),_0x480ecd['push']({'type':_0xdac181('0x14d8'),'app':_0xdac181('0x1816'),'appdata':_0xdac181('0x2201'),'context':_0x25dffc[_0xdac181('0x428')]['context'],'exten':_0x25dffc[_0xdac181('0x428')][_0xdac181('0x23ae')],'priority':_0x21cb00++,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']}),_0x480ecd['push']({'type':_0xdac181('0x14d8'),'app':_0xdac181('0x1816'),'appdata':_0xdac181('0x28a5'),'context':_0x25dffc[_0xdac181('0x428')][_0xdac181('0xe1c')],'exten':_0x25dffc[_0xdac181('0x428')][_0xdac181('0x23ae')],'priority':_0x21cb00++,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']});for(let _0x3846c1=0x0,_0xb49f10=0x0;_0x3846c1<_0x25dffc['inboundrouteApps'][_0xdac181('0x269a')][_0xdac181('0x264b')];_0x3846c1++,_0xb49f10=0x0){const _0x1442a3=_0x25dffc[_0xdac181('0x1269')][_0xdac181('0x269a')][_0x3846c1],_0x18e175=[],_0x15a111=[];_0x1442a3[_0xdac181('0x164e')]=_0x1442a3[_0xdac181('0x277c')]!==_0xdac181('0x16f')?[_0x1442a3[_0xdac181('0x277c')]]:_0x1442a3[_0xdac181('0x186f')]?_0x2cfb05()['map'](_0x2cfb05()[_0xdac181('0x1c33')](_0x25dffc[_0xdac181('0x164e')][_0xdac181('0x269a')],{'IntervalId':_0x1442a3[_0xdac181('0x186f')]}),_0xdac181('0x277c')):[],_0x1442a3[_0xdac181('0xe1c')]=_0x25dffc[_0xdac181('0x428')][_0xdac181('0xe1c')],_0x1442a3[_0xdac181('0x23ae')]=_0x25dffc[_0xdac181('0x428')]['exten'];_0x1442a3['type']&&(_0x1442a3[_0xdac181('0x1345')]=_0x1442a3[_0xdac181('0x1345')][_0xdac181('0x2574')]());typeof _0x1442a3['answer']!==_0xdac181('0x1048')&&(_0x169c88[_0xdac181('0x1257')](_0x1442a3[_0xdac181('0x746')][_0xdac181('0x2574')]())&&_0x1442a3[_0xdac181('0x83f')]!==_0xdac181('0x2853')&&(_0x1442a3[_0xdac181('0x1de9')]?(_0x18e175['push']({'type':_0x1442a3[_0xdac181('0x1345')]['toLowerCase'](),'app':_0xdac181('0x20cc'),'appdata':_0xdac181('0x252d'),'context':_0x25dffc['inboundroute'][_0xdac181('0xe1c')],'exten':_0x25dffc[_0xdac181('0x428')]['exten'],'priority':_0x1442a3[_0xdac181('0x164e')]['length']+_0x21cb00+_0xb49f10++,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']}),_0x18e175['push']({'type':_0x1442a3[_0xdac181('0x1345')][_0xdac181('0x2574')](),'app':_0xdac181('0x1816'),'appdata':_0xdac181('0x115'),'context':_0x25dffc['inboundroute'][_0xdac181('0xe1c')],'exten':_0x25dffc[_0xdac181('0x428')][_0xdac181('0x23ae')],'priority':_0x1442a3[_0xdac181('0x164e')][_0xdac181('0x264b')]+_0x21cb00+_0xb49f10++,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']})):(_0x18e175[_0xdac181('0x1514')]({'type':_0x1442a3['type'][_0xdac181('0x2574')](),'app':_0xdac181('0x20cc'),'appdata':'$[${XCALLY-MOTION-PROGRESS}=0]?Progress','context':_0x25dffc[_0xdac181('0x428')][_0xdac181('0xe1c')],'exten':_0x25dffc[_0xdac181('0x428')]['exten'],'priority':_0x1442a3[_0xdac181('0x164e')][_0xdac181('0x264b')]+_0x21cb00+_0xb49f10++,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']}),_0x18e175['push']({'type':_0x1442a3[_0xdac181('0x1345')]['toLowerCase'](),'app':_0xdac181('0x1816'),'appdata':_0xdac181('0xe9e'),'context':_0x25dffc[_0xdac181('0x428')][_0xdac181('0xe1c')],'exten':_0x25dffc[_0xdac181('0x428')][_0xdac181('0x23ae')],'priority':_0x1442a3[_0xdac181('0x164e')][_0xdac181('0x264b')]+_0x21cb00+_0xb49f10++,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']}))));for(let _0x2d4fd1=0x0;_0x2d4fd1<_0x1442a3[_0xdac181('0x164e')][_0xdac181('0x264b')];_0x2d4fd1++){const _0x10820a=_0x21cb00+_0x1442a3[_0xdac181('0x164e')][_0xdac181('0x264b')],_0x3a53d6=_0x2d4fd1===_0x1442a3[_0xdac181('0x164e')][_0xdac181('0x264b')]-0x1?_0x21cb00+_0x18e175[_0xdac181('0x264b')]+_0x15a111[_0xdac181('0x264b')]+0x2:_0x21cb00+_0x2d4fd1+0x1;_0x18e175['splice'](_0x2d4fd1,0x0,{'type':'inbound','app':_0xdac181('0x15df'),'appdata':_0x1442a3[_0xdac181('0x164e')][_0x2d4fd1]+'?'+_0x25dffc['inboundroute'][_0xdac181('0xe1c')]+_0xdac181('0x883')+_0x10820a+':'+_0x25dffc[_0xdac181('0x428')][_0xdac181('0xe1c')]+_0xdac181('0x883')+_0x3a53d6,'exten':_0x25dffc[_0xdac181('0x428')][_0xdac181('0x23ae')],'context':_0x25dffc[_0xdac181('0x428')]['context'],'priority':_0x21cb00+_0x2d4fd1,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']});}_0x1442a3[_0xdac181('0xfde')]=_0x18e175[_0xdac181('0x264b')]?_0x2cfb05()[_0xdac181('0x1ef5')](_0x18e175)[_0xdac181('0xfde')]+0x1:_0x21cb00,_0x21cb00=(_0x15a111[_0xdac181('0x264b')]?_0x2cfb05()['last'](_0x15a111)[_0xdac181('0xfde')]:_0x1442a3['priority'])+0x1,_0x480ecd=_0x2cfb05()[_0xdac181('0x1c6a')](_0x480ecd,_0x18e175,[_0x1442a3],_0x15a111);}_0x480ecd[_0xdac181('0x1514')]({'type':_0xdac181('0x14d8'),'app':'Hangup','exten':_0x25dffc[_0xdac181('0x428')][_0xdac181('0x23ae')],'context':_0x25dffc[_0xdac181('0x428')][_0xdac181('0xe1c')],'priority':_0x21cb00,'VoiceExtensionId':_0x25dffc[_0xdac181('0x428')]['id']}),_0x417bd3[_0xdac181('0x1deb')][_0xdac181('0x153b')]({'id':_0x25dffc['inboundroute']['id']},_0x2cfb05()[_0xdac181('0x1eba')](_0x480ecd,_0xdac181('0xfde')))[_0xdac181('0xa44')]['then'](function(_0x38f3e7){const _0x1afbd2=_0xdac181;_0x25dffc[_0x1afbd2('0x1269')][_0x1afbd2('0x269a')]=_0x38f3e7[_0x1afbd2('0x269a')];})[_0xdac181('0x1a80')](function(_0x358976){console['error'](_0x358976);});}function _0x70df0d(_0x81614f){_0x25dffc['inboundrouteApps']=_0x81614f||{'count':0x0,'rows':[]};}function _0x453757(){const _0x28484d=_0x55637e;return _0x417bd3['interval'][_0x28484d('0xd83')]({'fields':_0x28484d('0x1d39')})[_0x28484d('0xa44')][_0x28484d('0x1166')](function(_0x1a0103){_0x25dffc['intervals']=_0x1a0103;})[_0x28484d('0x1a80')](function(_0x3c43ff){console['error'](_0x3c43ff);});}function _0x49482c(){const _0x355e83=_0x55637e;_0x25dffc[_0x355e83('0x1f48')]=_0x417bd3['voiceExtension'][_0x355e83('0xd83')](_0x25dffc[_0x355e83('0x2218')],_0x70df0d)[_0x355e83('0xa44')];}function _0x4c10e1(_0x4f1ee3){const _0x10fe3d=_0x55637e;_0x2cfb05()[_0x10fe3d('0x127f')](_0x25dffc[_0x10fe3d('0x1269')]['rows'],{'id':_0x4f1ee3['id']}),_0x58fdbb(),_0x57fdbb[_0x10fe3d('0x103b')]({'title':'App\x20deleted!','msg':_0x4f1ee3[_0x10fe3d('0x746')]?_0x4f1ee3['app']+'\x20has\x20been\x20deleted!':''});}function _0x2b2881(_0x958ef8){const _0x543055=_0x55637e,_0x1ee0a1=_0xb314b6[_0x543055('0x1d26')]()[_0x543055('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20applications?')[_0x543055('0xf3c')](_0x543055('0x12b5')+_0x25dffc[_0x543055('0xb99')]['length']+_0x543055('0x196d')+'\x20will\x20be\x20deleted.')[_0x543055('0x8e8')]('delete\x20applications')[_0x543055('0x203b')](_0x958ef8)['ok']('OK')[_0x543055('0x3f')]('CANCEL');_0xb314b6[_0x543055('0x1f80')](_0x1ee0a1)[_0x543055('0x1166')](function(){const _0x3b0834=_0x543055;_0x25dffc['selectedInboundRouteApps'][_0x3b0834('0x2782')](function(_0x150d72){const _0x3a67cb=_0x3b0834;_0x2cfb05()[_0x3a67cb('0x127f')](_0x25dffc[_0x3a67cb('0x1269')][_0x3a67cb('0x269a')],{'id':_0x150d72['id']});}),_0x25dffc[_0x3b0834('0xb99')]=[],_0x58fdbb();});}}const _0x5ec5dd=_0x3f8eae;_0x385a3e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21fe'),_0x36e6f4('0x428'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x385a3e(_0x1d510a,_0x26112c,_0x2eed41,_0x5791b7,_0x3b6a86,_0x545421,_0x3dbdf9,_0x379824){const _0x5e85e9=_0x36e6f4,_0x37dbae=this;_0x37dbae[_0x5e85e9('0x98')]=_0x3dbdf9[_0x5e85e9('0x26cd')](),_0x37dbae[_0x5e85e9('0x61a')]=[],_0x37dbae[_0x5e85e9('0xcdc')]=_0x5e85e9('0xd79')+(_0x5791b7[_0x5e85e9('0x83f')]||_0x5791b7[_0x5e85e9('0x746')])[_0x5e85e9('0x1387')](),_0x37dbae[_0x5e85e9('0x1034')]=angular[_0x5e85e9('0x225f')](_0x5791b7),_0x37dbae[_0x5e85e9('0x243c')]=_0x379824,_0x37dbae['hasModulePermissions']={};if(_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x823')])switch(_0x37dbae['agi'][_0x5e85e9('0x83f')]?_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x83f')][_0x5e85e9('0x2574')]():_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x746')][_0x5e85e9('0x2574')]()){case _0x5e85e9('0x2853'):break;case'dialogflow':{const _0x468d63=_0x37dbae['agi'][_0x5e85e9('0x823')][_0x5e85e9('0x25c8')](',');_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x7ca')]=_0x468d63[0x0],_0x37dbae['agi'][_0x5e85e9('0xedb')]=_0x468d63[0x1],_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x1634')]=_0x468d63['slice'](0x2,_0x468d63[_0x5e85e9('0x264b')])['join'](',');}break;case _0x5e85e9('0x1636'):{const _0x22212c=_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x823')][_0x5e85e9('0x25c8')](',');_0x37dbae['agi'][_0x5e85e9('0x1b0a')]=_0x22212c[0x0],_0x37dbae[_0x5e85e9('0x1034')]['clientEmail']=_0x22212c[0x1],_0x37dbae['agi'][_0x5e85e9('0x170e')]=_0x22212c[0x2],_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0xedb')]=_0x22212c[0x3],_0x37dbae['agi']['welcomemessage']=_0x22212c['slice'](0x4,_0x22212c[_0x5e85e9('0x264b')])[_0x5e85e9('0x45a')](',');}break;case _0x5e85e9('0x86c'):{const _0x3f9d7d=_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x823')][_0x5e85e9('0x25c8')](',');_0x37dbae['agi'][_0x5e85e9('0xee6')]=_0x3f9d7d[0x0],_0x37dbae['agi']['secretaccesskey']=_0x3f9d7d[0x1],_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x25a2')]=_0x3f9d7d[0x2],_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x1ac4')]=_0x3f9d7d[0x3],_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x1634')]=_0x3f9d7d[_0x5e85e9('0x233')](0x4,_0x3f9d7d[_0x5e85e9('0x264b')])['join'](',');}break;case _0x5e85e9('0x1af7'):{const _0x2a9712=_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x823')][_0x5e85e9('0x25c8')](',');_0x37dbae['agi']['times']=isNaN(_0x2a9712[0x0])?_0x2a9712[0x0]:parseInt(_0x2a9712[0x0],0xa),_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x1640')]=_0x2a9712[_0x5e85e9('0x233')](0x1,_0x2a9712[_0x5e85e9('0x264b')])[_0x5e85e9('0x45a')](',');}break;case _0x5e85e9('0x1e70'):_0x37dbae[_0x5e85e9('0x1034')]['text']=_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x823')];break;case _0x5e85e9('0xceb'):_0x37dbae[_0x5e85e9('0x1034')]['name']=_0x37dbae['agi']['appdata'][_0x5e85e9('0x25c8')]('=')[0x0],_0x37dbae[_0x5e85e9('0x1034')]['value']=_0x37dbae['agi'][_0x5e85e9('0x823')][_0x5e85e9('0x25c8')]('=')[0x1];break;case _0x5e85e9('0x1034'):_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x2588')]=_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x823')];break;default:{const _0x1ab566=_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x823')]['split'](',');_0x37dbae['agi'][_0x5e85e9('0x2588')]=_0x2cfb05()[_0x5e85e9('0x1081')](_0x1ab566[0x0])?_0x1ab566[0x0]:isNaN(_0x1ab566[0x0])?_0x1ab566[0x0]:parseInt(_0x1ab566[0x0],0xa);}break;}else{}_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x1345')]&&_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x1345')][_0x5e85e9('0x2574')]()===_0x5e85e9('0x587')&&_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x83f')][_0x5e85e9('0x2574')]()==='outbounddial'&&(_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x265a')]=_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x2026')]?_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x2026')][_0x5e85e9('0x25c8')]('$')[0x0]:undefined,_0x37dbae['agi'][_0x5e85e9('0x1f02')]=_0x37dbae[_0x5e85e9('0x1034')]['callerID']?_0x5e85e9('0xa4c')+_0x37dbae[_0x5e85e9('0x1034')][_0x5e85e9('0x992')]:undefined);_0x37dbae[_0x5e85e9('0x1e81')]=_0x5d4b44,_0x37dbae[_0x5e85e9('0x24a0')]=_0xf14ba0,_0x3dbdf9[_0x5e85e9('0x1ac6')](_0x5e85e9('0xa7c'))?_0x545421['squareProject'][_0x5e85e9('0xd83')]({'fields':_0x5e85e9('0x1776'),'sort':'name','nolimit':_0x5e85e9('0xf3b')})['$promise'][_0x5e85e9('0x1166')](function(_0x2bacf7){const _0x5eb460=_0x5e85e9;_0x37dbae['projects']=_0x2bacf7[_0x5eb460('0x269a')]||[];})['catch'](function(_0x58d8c0){const _0x3f3410=_0x5e85e9;_0x2eed41[_0x3f3410('0xfc9')]({'title':_0x58d8c0['status']?_0x3f3410('0x1e21')+_0x58d8c0[_0x3f3410('0x52d')]+_0x3f3410('0x11e1')+_0x58d8c0[_0x3f3410('0xe1b')]:_0x3f3410('0x178b'),'msg':_0x58d8c0[_0x3f3410('0x25f4')]?JSON[_0x3f3410('0xbac')](_0x58d8c0[_0x3f3410('0x25f4')]):_0x58d8c0['toString']()});}):_0x545421['squareProject'][_0x5e85e9('0xd83')]({'fields':'id,name','sort':_0x5e85e9('0x4f0'),'nolimit':_0x5e85e9('0xf3b')})[_0x5e85e9('0xa44')][_0x5e85e9('0x1166')](function(_0x323069){const _0x470d16=_0x5e85e9;_0x37dbae[_0x470d16('0x149f')]=_0x323069[_0x470d16('0x269a')]||[];})[_0x5e85e9('0x1166')](function(){const _0x5588f8=_0x5e85e9;return _0x545421[_0x5588f8('0x17aa')][_0x5588f8('0xd83')]({'userProfileId':_0x37dbae[_0x5588f8('0x98')][_0x5588f8('0xb86')],'sectionId':0x44f})[_0x5588f8('0xa44')];})[_0x5e85e9('0x1166')](function(_0x274447){const _0x4f22bd=_0x5e85e9,_0x24796e=_0x274447&&_0x274447[_0x4f22bd('0x269a')]?_0x274447[_0x4f22bd('0x269a')][0x0]:null;if(!_0x24796e){const _0x32f3ec=[];let _0x534e1b=null;_0x37dbae['agi']&&(_0x534e1b=_0x2cfb05()[_0x4f22bd('0xc38')](_0x37dbae[_0x4f22bd('0x149f')],{'name':_0x37dbae[_0x4f22bd('0x1034')][_0x4f22bd('0x2588')]}));for(let _0x30b161=0x0;_0x30b161<_0x37dbae['projects'][_0x4f22bd('0x264b')];_0x30b161++){_0x534e1b&&_0x37dbae[_0x4f22bd('0x149f')][_0x30b161]['id']===_0x534e1b['id']&&(_0x37dbae[_0x4f22bd('0x149f')][_0x30b161][_0x4f22bd('0x2378')]=![],_0x32f3ec[_0x4f22bd('0x1514')](_0x37dbae[_0x4f22bd('0x149f')][_0x30b161]));}_0x37dbae[_0x4f22bd('0x149f')]=_0x32f3ec;}else{if(!_0x24796e[_0x4f22bd('0x1a2b')])return _0x545421['userProfileResource'][_0x4f22bd('0xd83')]({'sectionId':_0x24796e['id']})[_0x4f22bd('0xa44')][_0x4f22bd('0x1166')](function(_0x39700c){const _0x33f925=_0x4f22bd,_0x453fe0=_0x2cfb05()['map'](_0x39700c[_0x33f925('0x269a')],function(_0x47b474){const _0x1531e8=_0x33f925;return _0x2cfb05()[_0x1531e8('0xc38')](_0x37dbae[_0x1531e8('0x149f')],{'id':_0x47b474[_0x1531e8('0x24e8')]});});let _0x59cc36=null;_0x37dbae[_0x33f925('0x1034')]&&(_0x59cc36=_0x2cfb05()['find'](_0x37dbae[_0x33f925('0x149f')],{'name':_0x37dbae[_0x33f925('0x1034')][_0x33f925('0x2588')]}));if(_0x59cc36&&!_0x2cfb05()[_0x33f925('0x1798')](_0x453fe0,['id',_0x59cc36['id']])){const _0x286914=_0x2cfb05()[_0x33f925('0xc38')](_0x37dbae[_0x33f925('0x149f')],{'id':_0x59cc36['id']});_0x286914[_0x33f925('0x2378')]=![],_0x453fe0[_0x33f925('0x1514')](_0x286914);}_0x37dbae['projects']=_0x453fe0;});}})[_0x5e85e9('0x1a80')](function(_0x47859e){const _0x26ada3=_0x5e85e9;_0x2eed41[_0x26ada3('0xfc9')]({'title':_0x47859e[_0x26ada3('0x52d')]?_0x26ada3('0x1e21')+_0x47859e[_0x26ada3('0x52d')]+'\x20-\x20'+_0x47859e[_0x26ada3('0xe1b')]:_0x26ada3('0x10f2'),'msg':_0x47859e[_0x26ada3('0x25f4')]?JSON[_0x26ada3('0xbac')](_0x47859e[_0x26ada3('0x25f4')]):_0x47859e[_0x26ada3('0x1586')]()});});function _0x5d4b44(){const _0x35a282=_0x5e85e9;_0x37dbae[_0x35a282('0x61a')]=[];const _0x4d3cd6=[];_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x1345')]&&_0x37dbae['agi'][_0x35a282('0x1345')]['toLowerCase']()===_0x35a282('0x587')&&_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x83f')]===_0x35a282('0x867')&&(_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x2026')]=_0x3b6a86[_0x35a282('0x2848')]?(_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x265a')]||'')+_0x35a282('0x881')+_0x3b6a86[_0x35a282('0x2848')]+'}':(_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x265a')]||'')+'${EXTEN}',_0x3b6a86['recordingFormat']!=='none'?_0x37dbae['agi'][_0x35a282('0xd39')][_0x35a282('0x2379')](_0x35a282('0x1059'))<0x0&&(_0x37dbae[_0x35a282('0x1034')][_0x35a282('0xd39')]+=_0x35a282('0x1059')):_0x37dbae['agi'][_0x35a282('0xd39')]=_0x37dbae[_0x35a282('0x1034')][_0x35a282('0xd39')][_0x35a282('0xf3')](_0x35a282('0x1059'),''));if(_0x37dbae[_0x35a282('0x1034')]['appType']&&_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x83f')]===_0x35a282('0x2853')){}else switch((_0x37dbae[_0x35a282('0x1034')]['app']||_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x83f')])['toLowerCase']()){case _0x35a282('0xceb'):_0x37dbae[_0x35a282('0x1034')]['appdata']=_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x4f0')]+'='+_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x18e0')];break;case _0x35a282('0x2853'):break;default:_0x4d3cd6[0x0]=_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x2588')],_0x37dbae[_0x35a282('0x1034')][_0x35a282('0x823')]=_0x4d3cd6[_0x35a282('0x45a')](',');}_0xf14ba0(_0x37dbae['agi']);}function _0xf14ba0(_0x13100b){const _0x364c6f=_0x5e85e9;_0x1d510a[_0x364c6f('0x1197')](_0x13100b);}}const _0x1543a9=_0x385a3e;_0x2fe559['$inject']=[_0x36e6f4('0x265d'),'$q','toasty','inboundrouteApp',_0x36e6f4('0x428'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x2fe559(_0x38c064,_0x2713c4,_0x15eeac,_0x25d7c2,_0x5700f7,_0x49b16d,_0x3f2afa,_0x7aff1c){const _0x4e36d1=_0x36e6f4,_0x186594=this;_0x186594[_0x4e36d1('0x98')]=_0x3f2afa[_0x4e36d1('0x26cd')](),_0x186594[_0x4e36d1('0x61a')]=[],_0x186594[_0x4e36d1('0xcdc')]=_0x4e36d1('0xd79')+(_0x25d7c2['appType']||_0x25d7c2['app'])['toUpperCase'](),_0x186594[_0x4e36d1('0x2853')]=angular['copy'](_0x25d7c2),_0x186594[_0x4e36d1('0x243c')]=_0x7aff1c,_0x186594[_0x4e36d1('0x128b')]={};if(_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x823')])switch(_0x186594['custom'][_0x4e36d1('0x83f')]?_0x186594['custom'][_0x4e36d1('0x83f')][_0x4e36d1('0x2574')]():_0x186594['custom'][_0x4e36d1('0x746')]['toLowerCase']()){case _0x4e36d1('0x2853'):break;case _0x4e36d1('0xded'):{const _0x499f32=_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x823')]['split'](',');_0x186594['custom'][_0x4e36d1('0x7ca')]=_0x499f32[0x0],_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0xedb')]=_0x499f32[0x1],_0x186594[_0x4e36d1('0x2853')]['welcomemessage']=_0x499f32['slice'](0x2,_0x499f32['length'])['join'](',');}break;case _0x4e36d1('0x1636'):{const _0xd2e406=_0x186594['custom'][_0x4e36d1('0x823')]['split'](',');_0x186594['custom']['projectId']=_0xd2e406[0x0],_0x186594[_0x4e36d1('0x2853')]['clientEmail']=_0xd2e406[0x1],_0x186594['custom'][_0x4e36d1('0x170e')]=_0xd2e406[0x2],_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0xedb')]=_0xd2e406[0x3],_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x1634')]=_0xd2e406[_0x4e36d1('0x233')](0x4,_0xd2e406[_0x4e36d1('0x264b')])[_0x4e36d1('0x45a')](',');}break;case'amazonlex':{const _0x2f7080=_0x186594['custom']['appdata'][_0x4e36d1('0x25c8')](',');_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0xee6')]=_0x2f7080[0x0],_0x186594['custom']['secretaccesskey']=_0x2f7080[0x1],_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x25a2')]=_0x2f7080[0x2],_0x186594[_0x4e36d1('0x2853')]['botname']=_0x2f7080[0x3],_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x1634')]=_0x2f7080[_0x4e36d1('0x233')](0x4,_0x2f7080['length'])[_0x4e36d1('0x45a')](',');}break;case'autoreply':{const _0x2eb490=_0x186594[_0x4e36d1('0x2853')]['appdata']['split'](',');_0x186594[_0x4e36d1('0x2853')]['times']=isNaN(_0x2eb490[0x0])?_0x2eb490[0x0]:parseInt(_0x2eb490[0x0],0xa),_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x1640')]=_0x2eb490['slice'](0x1,_0x2eb490['length'])[_0x4e36d1('0x45a')](',');}break;case _0x4e36d1('0x1e70'):_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x1640')]=_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x823')];break;case _0x4e36d1('0xceb'):_0x186594['custom']['name']=_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x823')][_0x4e36d1('0x25c8')]('=')[0x0],_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x18e0')]=_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x823')]['split']('=')[0x1];break;case'agi':_0x186594[_0x4e36d1('0x2853')]['project']=_0x186594[_0x4e36d1('0x2853')]['appdata'];break;default:{const _0x8cd4be=_0x186594['custom'][_0x4e36d1('0x823')][_0x4e36d1('0x25c8')](',');_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x746')]=_0x2cfb05()[_0x4e36d1('0x1081')](_0x8cd4be[0x0])?_0x8cd4be[0x0]:isNaN(_0x8cd4be[0x0])?_0x8cd4be[0x0]:parseInt(_0x8cd4be[0x0],0xa),_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x823')]=_0x2cfb05()[_0x4e36d1('0x1081')](_0x8cd4be[0x1])?_0x8cd4be[0x1]:isNaN(_0x8cd4be[0x1])?_0x8cd4be[0x1]:parseInt(_0x8cd4be[0x1],0xa);}break;}else{}_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x1345')]&&_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x1345')][_0x4e36d1('0x2574')]()===_0x4e36d1('0x587')&&_0x186594['custom']['appType']['toLowerCase']()===_0x4e36d1('0x2884')&&(_0x186594['custom']['prefix']=_0x186594[_0x4e36d1('0x2853')]['phone']?_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x2026')][_0x4e36d1('0x25c8')]('$')[0x0]:undefined,_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x1f02')]=_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x992')]?_0x4e36d1('0xa4c')+_0x186594[_0x4e36d1('0x2853')][_0x4e36d1('0x992')]:undefined);_0x186594['saveInboundRouteApp']=_0x40472a,_0x186594[_0x4e36d1('0x24a0')]=_0x3f048e;function _0x40472a(){const _0x4a243b=_0x4e36d1;_0x186594[_0x4a243b('0x61a')]=[];const _0xd7146=[];_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x1345')]&&_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x1345')]['toLowerCase']()===_0x4a243b('0x587')&&_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x83f')]===_0x4a243b('0x867')&&(_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x2026')]=_0x5700f7[_0x4a243b('0x2848')]?(_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x265a')]||'')+'${EXTEN:'+_0x5700f7[_0x4a243b('0x2848')]+'}':(_0x186594[_0x4a243b('0x2853')]['prefix']||'')+'${EXTEN}',_0x5700f7[_0x4a243b('0x28cb')]!==_0x4a243b('0x192')?_0x186594[_0x4a243b('0x2853')][_0x4a243b('0xd39')]['indexOf'](_0x4a243b('0x1059'))<0x0&&(_0x186594[_0x4a243b('0x2853')][_0x4a243b('0xd39')]+=_0x4a243b('0x1059')):_0x186594['custom']['options']=_0x186594[_0x4a243b('0x2853')][_0x4a243b('0xd39')][_0x4a243b('0xf3')](_0x4a243b('0x1059'),''));if(_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x83f')]&&_0x186594['custom'][_0x4a243b('0x83f')]===_0x4a243b('0x2853')){}else switch((_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x746')]||_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x83f')])[_0x4a243b('0x2574')]()){case'set':_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x823')]=_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x4f0')]+'='+_0x186594['custom']['value'];break;case _0x4a243b('0x2853'):break;default:_0xd7146[0x0]=_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x746')],_0xd7146[0x1]=_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x823')],_0x186594[_0x4a243b('0x2853')][_0x4a243b('0x823')]=_0xd7146[_0x4a243b('0x45a')](',');}_0x3f048e(_0x186594[_0x4a243b('0x2853')]);}function _0x3f048e(_0x56b55c){const _0xc3ee96=_0x4e36d1;_0x38c064[_0xc3ee96('0x1197')](_0x56b55c);}}const _0x2b9daa=_0x2fe559;_0x1b1959['$inject']=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21fe'),_0x36e6f4('0x428'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x1b1959(_0x3dc91f,_0x21616b,_0x2fb170,_0x21b2ba,_0x271cb5,_0x46c7b5,_0x3d5e7c,_0x47daab){const _0x454c4d=_0x36e6f4,_0x169306=this;_0x169306[_0x454c4d('0x98')]=_0x3d5e7c[_0x454c4d('0x26cd')](),_0x169306[_0x454c4d('0x61a')]=[],_0x169306[_0x454c4d('0xcdc')]='VOICE.EDIT_'+(_0x21b2ba['appType']||_0x21b2ba[_0x454c4d('0x746')])[_0x454c4d('0x1387')](),_0x169306[_0x454c4d('0xc77')]=angular[_0x454c4d('0x225f')](_0x21b2ba),_0x169306['crudPermissions']=_0x47daab,_0x169306[_0x454c4d('0x128b')]={};if(_0x169306['dial']['appdata'])switch(_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x83f')]?_0x169306[_0x454c4d('0xc77')]['appType']['toLowerCase']():_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x746')]['toLowerCase']()){case _0x454c4d('0x2853'):break;case'dialogflow':{const _0x5bfc45=_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x823')][_0x454c4d('0x25c8')](',');_0x169306[_0x454c4d('0xc77')]['key']=_0x5bfc45[0x0],_0x169306['dial']['language']=_0x5bfc45[0x1],_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x1634')]=_0x5bfc45[_0x454c4d('0x233')](0x2,_0x5bfc45['length'])[_0x454c4d('0x45a')](',');}break;case'dialogflowv2':{const _0x1ef2f5=_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x823')]['split'](',');_0x169306['dial']['projectId']=_0x1ef2f5[0x0],_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x27f3')]=_0x1ef2f5[0x1],_0x169306[_0x454c4d('0xc77')]['privateKey']=_0x1ef2f5[0x2],_0x169306[_0x454c4d('0xc77')][_0x454c4d('0xedb')]=_0x1ef2f5[0x3],_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x1634')]=_0x1ef2f5[_0x454c4d('0x233')](0x4,_0x1ef2f5[_0x454c4d('0x264b')])[_0x454c4d('0x45a')](',');}break;case _0x454c4d('0x86c'):{const _0x2a68d6=_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x823')]['split'](',');_0x169306[_0x454c4d('0xc77')][_0x454c4d('0xee6')]=_0x2a68d6[0x0],_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x125')]=_0x2a68d6[0x1],_0x169306[_0x454c4d('0xc77')]['lexregion']=_0x2a68d6[0x2],_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x1ac4')]=_0x2a68d6[0x3],_0x169306[_0x454c4d('0xc77')]['welcomemessage']=_0x2a68d6['slice'](0x4,_0x2a68d6[_0x454c4d('0x264b')])['join'](',');}break;case _0x454c4d('0x1af7'):{const _0x20fb59=_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x823')][_0x454c4d('0x25c8')](',');_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x265e')]=isNaN(_0x20fb59[0x0])?_0x20fb59[0x0]:parseInt(_0x20fb59[0x0],0xa),_0x169306[_0x454c4d('0xc77')]['text']=_0x20fb59[_0x454c4d('0x233')](0x1,_0x20fb59[_0x454c4d('0x264b')])[_0x454c4d('0x45a')](',');}break;case _0x454c4d('0x1e70'):_0x169306[_0x454c4d('0xc77')]['text']=_0x169306[_0x454c4d('0xc77')]['appdata'];break;case _0x454c4d('0xceb'):_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x4f0')]=_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x823')]['split']('=')[0x0],_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x18e0')]=_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x823')][_0x454c4d('0x25c8')]('=')[0x1];break;case _0x454c4d('0x1034'):_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x2588')]=_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x823')];break;default:{const _0x28486a=_0x169306['dial']['appdata'][_0x454c4d('0x25c8')](',');_0x169306['dial'][_0x454c4d('0x134d')]=_0x2cfb05()['isEmpty'](_0x28486a[0x0])?_0x28486a[0x0]:isNaN(_0x28486a[0x0])?_0x28486a[0x0]:parseInt(_0x28486a[0x0],0xa),_0x169306['dial']['timeout']=_0x2cfb05()['isEmpty'](_0x28486a[0x1])?_0x28486a[0x1]:isNaN(_0x28486a[0x1])?_0x28486a[0x1]:parseInt(_0x28486a[0x1],0xa),_0x169306[_0x454c4d('0xc77')][_0x454c4d('0xd39')]=_0x2cfb05()[_0x454c4d('0x1081')](_0x28486a[0x2])?_0x28486a[0x2]:isNaN(_0x28486a[0x2])?_0x28486a[0x2]:parseInt(_0x28486a[0x2],0xa),_0x169306[_0x454c4d('0xc77')]['url']=_0x2cfb05()['isEmpty'](_0x28486a[0x3])?_0x28486a[0x3]:isNaN(_0x28486a[0x3])?_0x28486a[0x3]:parseInt(_0x28486a[0x3],0xa);}break;}else{}_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x1345')]&&_0x169306['dial'][_0x454c4d('0x1345')]['toLowerCase']()===_0x454c4d('0x587')&&_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x83f')]['toLowerCase']()===_0x454c4d('0x2884')&&(_0x169306['dial'][_0x454c4d('0x265a')]=_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x2026')]?_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x2026')][_0x454c4d('0x25c8')]('$')[0x0]:undefined,_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x1f02')]=_0x169306[_0x454c4d('0xc77')]['callerID']?_0x454c4d('0xa4c')+_0x169306[_0x454c4d('0xc77')][_0x454c4d('0x992')]:undefined);_0x169306[_0x454c4d('0x1e81')]=_0x6202bb,_0x169306[_0x454c4d('0x24a0')]=_0x3e61e3;function _0x6202bb(){const _0xcfaf38=_0x454c4d;_0x169306[_0xcfaf38('0x61a')]=[];const _0xa72af8=[];_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x1345')]&&_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x1345')][_0xcfaf38('0x2574')]()===_0xcfaf38('0x587')&&_0x169306[_0xcfaf38('0xc77')]['appType']===_0xcfaf38('0x867')&&(_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x2026')]=_0x271cb5[_0xcfaf38('0x2848')]?(_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x265a')]||'')+'${EXTEN:'+_0x271cb5[_0xcfaf38('0x2848')]+'}':(_0x169306['dial'][_0xcfaf38('0x265a')]||'')+_0xcfaf38('0x1d1'),_0x271cb5['recordingFormat']!==_0xcfaf38('0x192')?_0x169306[_0xcfaf38('0xc77')]['options']['indexOf'](_0xcfaf38('0x1059'))<0x0&&(_0x169306['dial']['options']+=_0xcfaf38('0x1059')):_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0xd39')]=_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0xd39')][_0xcfaf38('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x83f')]&&_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x83f')]===_0xcfaf38('0x2853')){}else switch((_0x169306['dial'][_0xcfaf38('0x746')]||_0x169306[_0xcfaf38('0xc77')]['appType'])['toLowerCase']()){case _0xcfaf38('0xceb'):_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x823')]=_0x169306['dial'][_0xcfaf38('0x4f0')]+'='+_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x18e0')];break;case _0xcfaf38('0x2853'):break;default:_0xa72af8[0x0]=_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x134d')],_0xa72af8[0x1]=_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x651')],_0xa72af8[0x2]=_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0xd39')],_0xa72af8[0x3]=_0x169306[_0xcfaf38('0xc77')]['url'],_0x169306[_0xcfaf38('0xc77')][_0xcfaf38('0x823')]=_0xa72af8[_0xcfaf38('0x45a')](',');}_0x3e61e3(_0x169306[_0xcfaf38('0xc77')]);}function _0x3e61e3(_0x453e0b){_0x3dc91f['hide'](_0x453e0b);}}const _0x80c61f=_0x1b1959;_0x3a4b1a[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21fe'),_0x36e6f4('0x428'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x3a4b1a(_0x496be8,_0x1a08a7,_0x194eba,_0x5a87f0,_0x40d685,_0x2f7aa3,_0x155172,_0x39c287){const _0x5d8f4f=_0x36e6f4,_0x4aeef9=this;_0x4aeef9[_0x5d8f4f('0x98')]=_0x155172[_0x5d8f4f('0x26cd')](),_0x4aeef9[_0x5d8f4f('0x61a')]=[],_0x4aeef9[_0x5d8f4f('0xcdc')]=_0x5d8f4f('0xd79')+(_0x5a87f0['appType']||_0x5a87f0[_0x5d8f4f('0x746')])[_0x5d8f4f('0x1387')](),_0x4aeef9[_0x5d8f4f('0x26ee')]=angular[_0x5d8f4f('0x225f')](_0x5a87f0),_0x4aeef9[_0x5d8f4f('0x243c')]=_0x39c287,_0x4aeef9[_0x5d8f4f('0x128b')]={};if(_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x823')])switch(_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x83f')]?_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x83f')][_0x5d8f4f('0x2574')]():_0x4aeef9[_0x5d8f4f('0x26ee')]['app'][_0x5d8f4f('0x2574')]()){case _0x5d8f4f('0x2853'):break;case _0x5d8f4f('0xded'):{const _0x2ab53d=_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x823')]['split'](',');_0x4aeef9['externaldial'][_0x5d8f4f('0x7ca')]=_0x2ab53d[0x0],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0xedb')]=_0x2ab53d[0x1],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x1634')]=_0x2ab53d[_0x5d8f4f('0x233')](0x2,_0x2ab53d[_0x5d8f4f('0x264b')])[_0x5d8f4f('0x45a')](',');}break;case'dialogflowv2':{const _0x2789f5=_0x4aeef9['externaldial'][_0x5d8f4f('0x823')][_0x5d8f4f('0x25c8')](',');_0x4aeef9['externaldial'][_0x5d8f4f('0x1b0a')]=_0x2789f5[0x0],_0x4aeef9['externaldial'][_0x5d8f4f('0x27f3')]=_0x2789f5[0x1],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x170e')]=_0x2789f5[0x2],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0xedb')]=_0x2789f5[0x3],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x1634')]=_0x2789f5[_0x5d8f4f('0x233')](0x4,_0x2789f5[_0x5d8f4f('0x264b')])[_0x5d8f4f('0x45a')](',');}break;case _0x5d8f4f('0x86c'):{const _0x1213a5=_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x823')][_0x5d8f4f('0x25c8')](',');_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0xee6')]=_0x1213a5[0x0],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x125')]=_0x1213a5[0x1],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x25a2')]=_0x1213a5[0x2],_0x4aeef9['externaldial'][_0x5d8f4f('0x1ac4')]=_0x1213a5[0x3],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x1634')]=_0x1213a5[_0x5d8f4f('0x233')](0x4,_0x1213a5[_0x5d8f4f('0x264b')])[_0x5d8f4f('0x45a')](',');}break;case'autoreply':{const _0x284076=_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x823')]['split'](',');_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x265e')]=isNaN(_0x284076[0x0])?_0x284076[0x0]:parseInt(_0x284076[0x0],0xa),_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x1640')]=_0x284076[_0x5d8f4f('0x233')](0x1,_0x284076['length'])[_0x5d8f4f('0x45a')](',');}break;case'message':_0x4aeef9[_0x5d8f4f('0x26ee')]['text']=_0x4aeef9[_0x5d8f4f('0x26ee')]['appdata'];break;case _0x5d8f4f('0xceb'):_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x4f0')]=_0x4aeef9['externaldial'][_0x5d8f4f('0x823')][_0x5d8f4f('0x25c8')]('=')[0x0],_0x4aeef9['externaldial']['value']=_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x823')]['split']('=')[0x1];break;case _0x5d8f4f('0x1034'):_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x2588')]=_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x823')];break;default:{const _0x119656=_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x823')][_0x5d8f4f('0x25c8')](',');_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x3b2')]=_0x119656[0x0][_0x5d8f4f('0x25c8')]('/')[0x1],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x2026')]=_0x119656[0x0][_0x5d8f4f('0x25c8')]('/')[0x2],_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x651')]=_0x2cfb05()['isEmpty'](_0x119656[0x1])?_0x119656[0x1]:isNaN(_0x119656[0x1])?_0x119656[0x1]:parseInt(_0x119656[0x1],0xa),_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0xd39')]=_0x2cfb05()[_0x5d8f4f('0x1081')](_0x119656[0x2])?_0x119656[0x2]:isNaN(_0x119656[0x2])?_0x119656[0x2]:parseInt(_0x119656[0x2],0xa),_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0xcac')]=_0x2cfb05()[_0x5d8f4f('0x1081')](_0x119656[0x3])?_0x119656[0x3]:isNaN(_0x119656[0x3])?_0x119656[0x3]:parseInt(_0x119656[0x3],0xa);}break;}else{}_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x1345')]&&_0x4aeef9[_0x5d8f4f('0x26ee')]['type']['toLowerCase']()==='outbound'&&_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x83f')][_0x5d8f4f('0x2574')]()==='outbounddial'&&(_0x4aeef9[_0x5d8f4f('0x26ee')]['prefix']=_0x4aeef9['externaldial'][_0x5d8f4f('0x2026')]?_0x4aeef9['externaldial']['phone'][_0x5d8f4f('0x25c8')]('$')[0x0]:undefined,_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x1f02')]=_0x4aeef9[_0x5d8f4f('0x26ee')][_0x5d8f4f('0x992')]?_0x5d8f4f('0xa4c')+_0x4aeef9['externaldial'][_0x5d8f4f('0x992')]:undefined);_0x4aeef9[_0x5d8f4f('0x1e81')]=_0x383f49,_0x4aeef9[_0x5d8f4f('0x24a0')]=_0x55be61,_0x155172[_0x5d8f4f('0x1ac6')](_0x5d8f4f('0xa7c'))?_0x2f7aa3[_0x5d8f4f('0x3b2')][_0x5d8f4f('0xd83')]({'fields':_0x5d8f4f('0x1776'),'sort':_0x5d8f4f('0x4f0'),'nolimit':_0x5d8f4f('0xf3b')})['$promise']['then'](function(_0x132097){const _0x366aaf=_0x5d8f4f;_0x4aeef9['trunks']=_0x132097[_0x366aaf('0x269a')]||[];})[_0x5d8f4f('0x1a80')](function(_0x219ccd){const _0x23c538=_0x5d8f4f;_0x194eba[_0x23c538('0xfc9')]({'title':_0x219ccd[_0x23c538('0x52d')]?_0x23c538('0x1e21')+_0x219ccd[_0x23c538('0x52d')]+_0x23c538('0x11e1')+_0x219ccd[_0x23c538('0xe1b')]:'SYSTEM:GET_TRUNKS','msg':_0x219ccd[_0x23c538('0x25f4')]?JSON[_0x23c538('0xbac')](_0x219ccd['data']):_0x219ccd[_0x23c538('0x1586')]()});}):_0x2f7aa3[_0x5d8f4f('0x3b2')][_0x5d8f4f('0xd83')]({'fields':_0x5d8f4f('0x1776'),'sort':'name','nolimit':'true'})['$promise']['then'](function(_0x4a6de2){const _0xada184=_0x5d8f4f;_0x4aeef9['trunks']=_0x4a6de2[_0xada184('0x269a')]||[];})[_0x5d8f4f('0x1166')](function(){const _0x5b261d=_0x5d8f4f;return _0x2f7aa3['userProfileSection'][_0x5b261d('0xd83')]({'userProfileId':_0x4aeef9[_0x5b261d('0x98')][_0x5b261d('0xb86')],'sectionId':0x3f3})[_0x5b261d('0xa44')];})['then'](function(_0x2ff815){const _0x865aef=_0x5d8f4f,_0x147b68=_0x2ff815&&_0x2ff815[_0x865aef('0x269a')]?_0x2ff815[_0x865aef('0x269a')][0x0]:null;if(!_0x147b68){const _0x11d4e=[];let _0x2235a9=null;_0x4aeef9[_0x865aef('0x26ee')]&&(_0x2235a9=_0x2cfb05()[_0x865aef('0xc38')](_0x4aeef9[_0x865aef('0xf24')],{'name':_0x4aeef9['externaldial'][_0x865aef('0x3b2')]}));for(let _0x554ff5=0x0;_0x554ff5<_0x4aeef9[_0x865aef('0xf24')][_0x865aef('0x264b')];_0x554ff5++){_0x2235a9&&_0x4aeef9['trunks'][_0x554ff5]['id']===_0x2235a9['id']&&(_0x4aeef9['trunks'][_0x554ff5][_0x865aef('0x2378')]=![],_0x11d4e[_0x865aef('0x1514')](_0x4aeef9[_0x865aef('0xf24')][_0x554ff5]));}_0x4aeef9[_0x865aef('0xf24')]=_0x11d4e;}else{if(!_0x147b68[_0x865aef('0x1a2b')])return _0x2f7aa3[_0x865aef('0x4b5')][_0x865aef('0xd83')]({'sectionId':_0x147b68['id']})[_0x865aef('0xa44')][_0x865aef('0x1166')](function(_0x459fa3){const _0x5d9329=_0x865aef,_0x11cdd7=_0x2cfb05()[_0x5d9329('0x2563')](_0x459fa3[_0x5d9329('0x269a')],function(_0x5c267e){const _0x523be5=_0x5d9329;return _0x2cfb05()['find'](_0x4aeef9['trunks'],{'id':_0x5c267e[_0x523be5('0x24e8')]});});let _0x5b2229=null;_0x4aeef9[_0x5d9329('0x26ee')]&&(_0x5b2229=_0x2cfb05()['find'](_0x4aeef9['trunks'],{'name':_0x4aeef9['externaldial'][_0x5d9329('0x3b2')]}));if(_0x5b2229&&!_0x2cfb05()[_0x5d9329('0x1798')](_0x11cdd7,['id',_0x5b2229['id']])){const _0x1204c9=_0x2cfb05()[_0x5d9329('0xc38')](_0x4aeef9[_0x5d9329('0xf24')],{'id':_0x5b2229['id']});_0x1204c9[_0x5d9329('0x2378')]=![],_0x11cdd7[_0x5d9329('0x1514')](_0x1204c9);}_0x4aeef9[_0x5d9329('0xf24')]=_0x11cdd7;});}})[_0x5d8f4f('0x1a80')](function(_0x14c8be){const _0x2a1d98=_0x5d8f4f;_0x194eba[_0x2a1d98('0xfc9')]({'title':_0x14c8be[_0x2a1d98('0x52d')]?_0x2a1d98('0x1e21')+_0x14c8be[_0x2a1d98('0x52d')]+_0x2a1d98('0x11e1')+_0x14c8be[_0x2a1d98('0xe1b')]:_0x2a1d98('0x1d44'),'msg':_0x14c8be[_0x2a1d98('0x25f4')]?JSON[_0x2a1d98('0xbac')](_0x14c8be[_0x2a1d98('0x25f4')]):_0x14c8be[_0x2a1d98('0x1586')]()});});function _0x383f49(){const _0x18980d=_0x5d8f4f;_0x4aeef9['errors']=[];const _0x510fcb=[];_0x4aeef9[_0x18980d('0x26ee')]['type']&&_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0x1345')][_0x18980d('0x2574')]()===_0x18980d('0x587')&&_0x4aeef9[_0x18980d('0x26ee')]['appType']==='outboundDial'&&(_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0x2026')]=_0x40d685[_0x18980d('0x2848')]?(_0x4aeef9['externaldial'][_0x18980d('0x265a')]||'')+_0x18980d('0x881')+_0x40d685[_0x18980d('0x2848')]+'}':(_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0x265a')]||'')+'${EXTEN}',_0x40d685[_0x18980d('0x28cb')]!==_0x18980d('0x192')?_0x4aeef9['externaldial']['options'][_0x18980d('0x2379')](_0x18980d('0x1059'))<0x0&&(_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0xd39')]+='U(xcally-mixmonitor-context)'):_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0xd39')]=_0x4aeef9[_0x18980d('0x26ee')]['options'][_0x18980d('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x4aeef9['externaldial'][_0x18980d('0x83f')]&&_0x4aeef9['externaldial'][_0x18980d('0x83f')]===_0x18980d('0x2853')){}else switch((_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0x746')]||_0x4aeef9['externaldial'][_0x18980d('0x83f')])[_0x18980d('0x2574')]()){case _0x18980d('0xceb'):_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0x823')]=_0x4aeef9['externaldial'][_0x18980d('0x4f0')]+'='+_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0x18e0')];break;case'custom':break;default:_0x510fcb[0x0]=['SIP',_0x4aeef9[_0x18980d('0x26ee')]['trunk'],_0x4aeef9['externaldial'][_0x18980d('0x2026')]][_0x18980d('0x45a')]('/'),_0x510fcb[0x1]=_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0x651')],_0x510fcb[0x2]=_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0xd39')],_0x510fcb[0x3]=_0x4aeef9[_0x18980d('0x26ee')][_0x18980d('0xcac')],_0x4aeef9['externaldial'][_0x18980d('0x823')]=_0x510fcb['join'](',');}_0x55be61(_0x4aeef9[_0x18980d('0x26ee')]);}function _0x55be61(_0x2db97d){const _0x5dc835=_0x5d8f4f;_0x496be8[_0x5dc835('0x1197')](_0x2db97d);}}const _0x2cbc39=_0x3a4b1a;_0x155b34[_0x36e6f4('0x1294')]=['$mdDialog','$q','toasty',_0x36e6f4('0x21fe'),_0x36e6f4('0x428'),'api','Auth',_0x36e6f4('0x243c')];function _0x155b34(_0x26f990,_0x5a110e,_0x558ce7,_0x3ed3fc,_0x66129e,_0x2c5aaa,_0x139662,_0x302bf8){const _0x46ecca=_0x36e6f4,_0x353fc0=this;_0x353fc0[_0x46ecca('0x98')]=_0x139662['getCurrentUser'](),_0x353fc0['errors']=[],_0x353fc0['title']='VOICE.EDIT_'+(_0x3ed3fc[_0x46ecca('0x83f')]||_0x3ed3fc[_0x46ecca('0x746')])[_0x46ecca('0x1387')](),_0x353fc0['goto']=angular[_0x46ecca('0x225f')](_0x3ed3fc),_0x353fc0[_0x46ecca('0x243c')]=_0x302bf8,_0x353fc0[_0x46ecca('0x128b')]={};if(_0x353fc0[_0x46ecca('0x1a03')]['appdata'])switch(_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x83f')]?_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x83f')][_0x46ecca('0x2574')]():_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x746')]['toLowerCase']()){case _0x46ecca('0x2853'):break;case _0x46ecca('0xded'):{const _0x406d39=_0x353fc0['goto'][_0x46ecca('0x823')][_0x46ecca('0x25c8')](',');_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x7ca')]=_0x406d39[0x0],_0x353fc0['goto'][_0x46ecca('0xedb')]=_0x406d39[0x1],_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x1634')]=_0x406d39['slice'](0x2,_0x406d39[_0x46ecca('0x264b')])[_0x46ecca('0x45a')](',');}break;case _0x46ecca('0x1636'):{const _0x123269=_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x823')]['split'](',');_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x1b0a')]=_0x123269[0x0],_0x353fc0[_0x46ecca('0x1a03')]['clientEmail']=_0x123269[0x1],_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x170e')]=_0x123269[0x2],_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0xedb')]=_0x123269[0x3],_0x353fc0['goto']['welcomemessage']=_0x123269[_0x46ecca('0x233')](0x4,_0x123269[_0x46ecca('0x264b')])[_0x46ecca('0x45a')](',');}break;case _0x46ecca('0x86c'):{const _0x304e2d=_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x823')][_0x46ecca('0x25c8')](',');_0x353fc0[_0x46ecca('0x1a03')]['accesskeyid']=_0x304e2d[0x0],_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x125')]=_0x304e2d[0x1],_0x353fc0['goto']['lexregion']=_0x304e2d[0x2],_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x1ac4')]=_0x304e2d[0x3],_0x353fc0[_0x46ecca('0x1a03')]['welcomemessage']=_0x304e2d[_0x46ecca('0x233')](0x4,_0x304e2d['length'])[_0x46ecca('0x45a')](',');}break;case _0x46ecca('0x1af7'):{const _0x2c18a7=_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x823')][_0x46ecca('0x25c8')](',');_0x353fc0[_0x46ecca('0x1a03')]['times']=isNaN(_0x2c18a7[0x0])?_0x2c18a7[0x0]:parseInt(_0x2c18a7[0x0],0xa),_0x353fc0[_0x46ecca('0x1a03')]['text']=_0x2c18a7[_0x46ecca('0x233')](0x1,_0x2c18a7[_0x46ecca('0x264b')])['join'](',');}break;case _0x46ecca('0x1e70'):_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x1640')]=_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x823')];break;case _0x46ecca('0xceb'):_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x4f0')]=_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x823')]['split']('=')[0x0],_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x18e0')]=_0x353fc0['goto'][_0x46ecca('0x823')][_0x46ecca('0x25c8')]('=')[0x1];break;case _0x46ecca('0x1034'):_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x2588')]=_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x823')];break;default:{const _0x4914e3=_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x823')][_0x46ecca('0x25c8')](',');_0x353fc0[_0x46ecca('0x1a03')]['context']=_0x2cfb05()['isEmpty'](_0x4914e3[0x0])?_0x4914e3[0x0]:isNaN(_0x4914e3[0x0])?_0x4914e3[0x0]:parseInt(_0x4914e3[0x0],0xa),_0x353fc0['goto']['extension']=_0x2cfb05()['isEmpty'](_0x4914e3[0x1])?_0x4914e3[0x1]:isNaN(_0x4914e3[0x1])?_0x4914e3[0x1]:parseInt(_0x4914e3[0x1],0xa),_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0xfde')]=_0x2cfb05()[_0x46ecca('0x1081')](_0x4914e3[0x2])?_0x4914e3[0x2]:isNaN(_0x4914e3[0x2])?_0x4914e3[0x2]:parseInt(_0x4914e3[0x2],0xa);}break;}else{}_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x1345')]&&_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x1345')]['toLowerCase']()===_0x46ecca('0x587')&&_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x83f')]['toLowerCase']()===_0x46ecca('0x2884')&&(_0x353fc0['goto'][_0x46ecca('0x265a')]=_0x353fc0[_0x46ecca('0x1a03')]['phone']?_0x353fc0['goto'][_0x46ecca('0x2026')][_0x46ecca('0x25c8')]('$')[0x0]:undefined,_0x353fc0['goto'][_0x46ecca('0x1f02')]=_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x992')]?_0x46ecca('0xa4c')+_0x353fc0[_0x46ecca('0x1a03')][_0x46ecca('0x992')]:undefined);_0x353fc0['saveInboundRouteApp']=_0x2a69a3,_0x353fc0[_0x46ecca('0x24a0')]=_0x30462e,_0x139662['hasRole'](_0x46ecca('0xa7c'))?_0x2c5aaa[_0x46ecca('0x23b1')][_0x46ecca('0xd83')]({'fields':_0x46ecca('0x1776'),'sort':_0x46ecca('0x4f0'),'nolimit':'true'})[_0x46ecca('0xa44')][_0x46ecca('0x1166')](function(_0x3999b9){const _0x49a623=_0x46ecca;_0x353fc0[_0x49a623('0x160a')]=_0x3999b9['rows']||[];})[_0x46ecca('0x1a80')](function(_0x2fca18){const _0x459151=_0x46ecca;_0x558ce7[_0x459151('0xfc9')]({'title':_0x2fca18[_0x459151('0x52d')]?_0x459151('0x1e21')+_0x2fca18[_0x459151('0x52d')]+_0x459151('0x11e1')+_0x2fca18[_0x459151('0xe1b')]:_0x459151('0x140d'),'msg':_0x2fca18[_0x459151('0x25f4')]?JSON[_0x459151('0xbac')](_0x2fca18[_0x459151('0x25f4')]):_0x2fca18[_0x459151('0x1586')]()});}):_0x2c5aaa[_0x46ecca('0x23b1')][_0x46ecca('0xd83')]({'fields':_0x46ecca('0x1776'),'sort':'name','nolimit':_0x46ecca('0xf3b')})[_0x46ecca('0xa44')][_0x46ecca('0x1166')](function(_0x1ca1eb){const _0x143367=_0x46ecca;_0x353fc0['contexts']=_0x1ca1eb[_0x143367('0x269a')]||[];})[_0x46ecca('0x1166')](function(){const _0x35721a=_0x46ecca;return _0x2c5aaa[_0x35721a('0x17aa')]['get']({'userProfileId':_0x353fc0[_0x35721a('0x98')]['userProfileId'],'sectionId':0x195})[_0x35721a('0xa44')];})[_0x46ecca('0x1166')](function(_0x2fa08f){const _0x148437=_0x46ecca,_0x57cf2e=_0x2fa08f&&_0x2fa08f[_0x148437('0x269a')]?_0x2fa08f[_0x148437('0x269a')][0x0]:null;if(!_0x57cf2e)return _0x2c5aaa['voiceContext'][_0x148437('0xd83')]({'fields':_0x148437('0x1776'),'sort':_0x148437('0x4f0'),'nolimit':_0x148437('0xf3b'),'defaultEntry':0x1})[_0x148437('0xa44')][_0x148437('0x1166')](function(_0x4834c5){const _0x4e58ba=_0x148437;_0x353fc0['contexts']=_0x4834c5[_0x4e58ba('0x269a')]||[];});else{if(!_0x57cf2e['autoAssociation'])return _0x2c5aaa['userProfileResource'][_0x148437('0xd83')]({'sectionId':_0x57cf2e['id']})[_0x148437('0xa44')]['then'](function(_0x2d31c7){const _0xaf8153=_0x148437,_0x374339=_0x2cfb05()[_0xaf8153('0x2563')](_0x2d31c7[_0xaf8153('0x269a')],function(_0x14769b){const _0x1a67f9=_0xaf8153;return _0x2cfb05()['find'](_0x353fc0[_0x1a67f9('0x160a')],{'id':_0x14769b[_0x1a67f9('0x24e8')]});});let _0x40761b=null;_0x353fc0[_0xaf8153('0x1a03')]&&(_0x40761b=_0x2cfb05()['find'](_0x353fc0['contexts'],{'name':_0x353fc0[_0xaf8153('0x1a03')][_0xaf8153('0xe1c')]}));if(_0x40761b&&!_0x2cfb05()[_0xaf8153('0x1798')](_0x374339,['id',_0x40761b['id']])){const _0x2fbff1=_0x2cfb05()[_0xaf8153('0xc38')](_0x353fc0[_0xaf8153('0x160a')],{'id':_0x40761b['id']});_0x2fbff1[_0xaf8153('0x2378')]=![],_0x374339[_0xaf8153('0x1514')](_0x2fbff1);}_0x353fc0[_0xaf8153('0x160a')]=_0x374339;});}})[_0x46ecca('0x1a80')](function(_0x3a90f4){const _0x58794a=_0x46ecca;_0x558ce7['error']({'title':_0x3a90f4[_0x58794a('0x52d')]?_0x58794a('0x1e21')+_0x3a90f4['status']+_0x58794a('0x11e1')+_0x3a90f4[_0x58794a('0xe1b')]:_0x58794a('0x482'),'msg':_0x3a90f4[_0x58794a('0x25f4')]?JSON['stringify'](_0x3a90f4[_0x58794a('0x25f4')]):_0x3a90f4['toString']()});});function _0x2a69a3(){const _0x9dc9b0=_0x46ecca;_0x353fc0[_0x9dc9b0('0x61a')]=[];const _0x376497=[];_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0x1345')]&&_0x353fc0['goto'][_0x9dc9b0('0x1345')][_0x9dc9b0('0x2574')]()===_0x9dc9b0('0x587')&&_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0x83f')]===_0x9dc9b0('0x867')&&(_0x353fc0['goto'][_0x9dc9b0('0x2026')]=_0x66129e[_0x9dc9b0('0x2848')]?(_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0x265a')]||'')+_0x9dc9b0('0x881')+_0x66129e[_0x9dc9b0('0x2848')]+'}':(_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0x265a')]||'')+_0x9dc9b0('0x1d1'),_0x66129e[_0x9dc9b0('0x28cb')]!==_0x9dc9b0('0x192')?_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0xd39')][_0x9dc9b0('0x2379')](_0x9dc9b0('0x1059'))<0x0&&(_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0xd39')]+=_0x9dc9b0('0x1059')):_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0xd39')]=_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0xd39')]['replace'](_0x9dc9b0('0x1059'),''));if(_0x353fc0[_0x9dc9b0('0x1a03')]['appType']&&_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0x83f')]==='custom'){}else switch((_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0x746')]||_0x353fc0[_0x9dc9b0('0x1a03')]['appType'])[_0x9dc9b0('0x2574')]()){case _0x9dc9b0('0xceb'):_0x353fc0['goto'][_0x9dc9b0('0x823')]=_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0x4f0')]+'='+_0x353fc0[_0x9dc9b0('0x1a03')]['value'];break;case _0x9dc9b0('0x2853'):break;default:_0x376497[0x0]=_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0xe1c')],_0x376497[0x1]=_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0x1ed1')],_0x376497[0x2]=_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0xfde')],_0x353fc0[_0x9dc9b0('0x1a03')][_0x9dc9b0('0x823')]=_0x376497[_0x9dc9b0('0x45a')](',');}_0x30462e(_0x353fc0['goto']);}function _0x30462e(_0x3e7084){const _0x517ca0=_0x46ecca;_0x26f990[_0x517ca0('0x1197')](_0x3e7084);}}const _0x2a13a2=_0x155b34;_0xa39559[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21fe'),_0x36e6f4('0x428'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0xa39559(_0x48a421,_0x4aa9cd,_0x5c3041,_0xf3eb00,_0x6b361f,_0x3a06aa,_0x566565,_0x565ce2){const _0x22bc60=_0x36e6f4,_0x41251a=this;_0x41251a[_0x22bc60('0x98')]=_0x566565['getCurrentUser'](),_0x41251a[_0x22bc60('0x61a')]=[],_0x41251a[_0x22bc60('0xcdc')]=_0x22bc60('0xd79')+(_0xf3eb00[_0x22bc60('0x83f')]||_0xf3eb00[_0x22bc60('0x746')])[_0x22bc60('0x1387')](),_0x41251a[_0x22bc60('0x133d')]=angular['copy'](_0xf3eb00),_0x41251a[_0x22bc60('0x243c')]=_0x565ce2,_0x41251a['hasModulePermissions']={};if(_0x41251a[_0x22bc60('0x133d')]['appdata'])switch(_0x41251a['hangup']['appType']?_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x83f')][_0x22bc60('0x2574')]():_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x746')]['toLowerCase']()){case _0x22bc60('0x2853'):break;case _0x22bc60('0xded'):{const _0x2a5bd8=_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x823')][_0x22bc60('0x25c8')](',');_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x7ca')]=_0x2a5bd8[0x0],_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0xedb')]=_0x2a5bd8[0x1],_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x1634')]=_0x2a5bd8[_0x22bc60('0x233')](0x2,_0x2a5bd8[_0x22bc60('0x264b')])[_0x22bc60('0x45a')](',');}break;case _0x22bc60('0x1636'):{const _0x674b3a=_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x823')][_0x22bc60('0x25c8')](',');_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x1b0a')]=_0x674b3a[0x0],_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x27f3')]=_0x674b3a[0x1],_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x170e')]=_0x674b3a[0x2],_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0xedb')]=_0x674b3a[0x3],_0x41251a['hangup']['welcomemessage']=_0x674b3a[_0x22bc60('0x233')](0x4,_0x674b3a['length'])['join'](',');}break;case _0x22bc60('0x86c'):{const _0xd97eb7=_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x823')][_0x22bc60('0x25c8')](',');_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0xee6')]=_0xd97eb7[0x0],_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x125')]=_0xd97eb7[0x1],_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x25a2')]=_0xd97eb7[0x2],_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x1ac4')]=_0xd97eb7[0x3],_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x1634')]=_0xd97eb7[_0x22bc60('0x233')](0x4,_0xd97eb7[_0x22bc60('0x264b')])[_0x22bc60('0x45a')](',');}break;case _0x22bc60('0x1af7'):{const _0x42f821=_0x41251a['hangup'][_0x22bc60('0x823')][_0x22bc60('0x25c8')](',');_0x41251a[_0x22bc60('0x133d')]['times']=isNaN(_0x42f821[0x0])?_0x42f821[0x0]:parseInt(_0x42f821[0x0],0xa),_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x1640')]=_0x42f821[_0x22bc60('0x233')](0x1,_0x42f821['length'])[_0x22bc60('0x45a')](',');}break;case _0x22bc60('0x1e70'):_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x1640')]=_0x41251a['hangup'][_0x22bc60('0x823')];break;case _0x22bc60('0xceb'):_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x4f0')]=_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x823')][_0x22bc60('0x25c8')]('=')[0x0],_0x41251a[_0x22bc60('0x133d')]['value']=_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x823')][_0x22bc60('0x25c8')]('=')[0x1];break;case _0x22bc60('0x1034'):_0x41251a['hangup'][_0x22bc60('0x2588')]=_0x41251a[_0x22bc60('0x133d')]['appdata'];break;default:{const _0x471811=_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x823')][_0x22bc60('0x25c8')](',');_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x823')]=_0x2cfb05()[_0x22bc60('0x1081')](_0x471811[0x0])?_0x471811[0x0]:isNaN(_0x471811[0x0])?_0x471811[0x0]:parseInt(_0x471811[0x0],0xa);}break;}else{}_0x41251a['hangup'][_0x22bc60('0x1345')]&&_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x1345')][_0x22bc60('0x2574')]()===_0x22bc60('0x587')&&_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x83f')][_0x22bc60('0x2574')]()===_0x22bc60('0x2884')&&(_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x265a')]=_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x2026')]?_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x2026')][_0x22bc60('0x25c8')]('$')[0x0]:undefined,_0x41251a[_0x22bc60('0x133d')][_0x22bc60('0x1f02')]=_0x41251a['hangup'][_0x22bc60('0x992')]?'CALLERID(all)='+_0x41251a['hangup'][_0x22bc60('0x992')]:undefined);_0x41251a[_0x22bc60('0x1e81')]=_0x411d09,_0x41251a[_0x22bc60('0x24a0')]=_0x2038f3;function _0x411d09(){const _0x3b7e0e=_0x22bc60;_0x41251a[_0x3b7e0e('0x61a')]=[];const _0x29d752=[];_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x1345')]&&_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x1345')]['toLowerCase']()===_0x3b7e0e('0x587')&&_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x83f')]===_0x3b7e0e('0x867')&&(_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x2026')]=_0x6b361f[_0x3b7e0e('0x2848')]?(_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x265a')]||'')+'${EXTEN:'+_0x6b361f[_0x3b7e0e('0x2848')]+'}':(_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x265a')]||'')+_0x3b7e0e('0x1d1'),_0x6b361f[_0x3b7e0e('0x28cb')]!==_0x3b7e0e('0x192')?_0x41251a['hangup'][_0x3b7e0e('0xd39')]['indexOf']('U(xcally-mixmonitor-context)')<0x0&&(_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0xd39')]+='U(xcally-mixmonitor-context)'):_0x41251a[_0x3b7e0e('0x133d')]['options']=_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0xd39')]['replace'](_0x3b7e0e('0x1059'),''));if(_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x83f')]&&_0x41251a[_0x3b7e0e('0x133d')]['appType']===_0x3b7e0e('0x2853')){}else switch((_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x746')]||_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x83f')])[_0x3b7e0e('0x2574')]()){case _0x3b7e0e('0xceb'):_0x41251a['hangup']['appdata']=_0x41251a[_0x3b7e0e('0x133d')]['name']+'='+_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x18e0')];break;case _0x3b7e0e('0x2853'):break;default:_0x29d752[0x0]=_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x823')],_0x41251a[_0x3b7e0e('0x133d')][_0x3b7e0e('0x823')]=_0x29d752[_0x3b7e0e('0x45a')](',');}_0x2038f3(_0x41251a[_0x3b7e0e('0x133d')]);}function _0x2038f3(_0x113126){const _0x3f5d2e=_0x22bc60;_0x48a421[_0x3f5d2e('0x1197')](_0x113126);}}const _0x4a379c=_0xa39559;_0x5a39b5[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty','inboundrouteApp',_0x36e6f4('0x428'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x5a39b5(_0x24907a,_0x164ea2,_0x3fd9e9,_0x49b2d5,_0x246c08,_0x3d9d16,_0x151ddc,_0x52186b){const _0x1c7d95=_0x36e6f4,_0x2a44fa=this;_0x2a44fa['currentUser']=_0x151ddc['getCurrentUser'](),_0x2a44fa[_0x1c7d95('0x61a')]=[],_0x2a44fa[_0x1c7d95('0xcdc')]=_0x1c7d95('0xd79')+(_0x49b2d5['appType']||_0x49b2d5[_0x1c7d95('0x746')])[_0x1c7d95('0x1387')](),_0x2a44fa['internaldial']=angular['copy'](_0x49b2d5),_0x2a44fa[_0x1c7d95('0x243c')]=_0x52186b,_0x2a44fa[_0x1c7d95('0x128b')]={};if(_0x2a44fa[_0x1c7d95('0x143c')]['appdata'])switch(_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x83f')]?_0x2a44fa[_0x1c7d95('0x143c')]['appType'][_0x1c7d95('0x2574')]():_0x2a44fa[_0x1c7d95('0x143c')]['app']['toLowerCase']()){case _0x1c7d95('0x2853'):break;case'dialogflow':{const _0x46a6e9=_0x2a44fa[_0x1c7d95('0x143c')]['appdata'][_0x1c7d95('0x25c8')](',');_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x7ca')]=_0x46a6e9[0x0],_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0xedb')]=_0x46a6e9[0x1],_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x1634')]=_0x46a6e9[_0x1c7d95('0x233')](0x2,_0x46a6e9['length'])[_0x1c7d95('0x45a')](',');}break;case'dialogflowv2':{const _0x49327e=_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x823')][_0x1c7d95('0x25c8')](',');_0x2a44fa['internaldial'][_0x1c7d95('0x1b0a')]=_0x49327e[0x0],_0x2a44fa[_0x1c7d95('0x143c')]['clientEmail']=_0x49327e[0x1],_0x2a44fa[_0x1c7d95('0x143c')]['privateKey']=_0x49327e[0x2],_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0xedb')]=_0x49327e[0x3],_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x1634')]=_0x49327e[_0x1c7d95('0x233')](0x4,_0x49327e[_0x1c7d95('0x264b')])[_0x1c7d95('0x45a')](',');}break;case _0x1c7d95('0x86c'):{const _0x142fed=_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x823')][_0x1c7d95('0x25c8')](',');_0x2a44fa[_0x1c7d95('0x143c')]['accesskeyid']=_0x142fed[0x0],_0x2a44fa['internaldial'][_0x1c7d95('0x125')]=_0x142fed[0x1],_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x25a2')]=_0x142fed[0x2],_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x1ac4')]=_0x142fed[0x3],_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x1634')]=_0x142fed[_0x1c7d95('0x233')](0x4,_0x142fed[_0x1c7d95('0x264b')])[_0x1c7d95('0x45a')](',');}break;case'autoreply':{const _0x5a2da4=_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x823')][_0x1c7d95('0x25c8')](',');_0x2a44fa['internaldial'][_0x1c7d95('0x265e')]=isNaN(_0x5a2da4[0x0])?_0x5a2da4[0x0]:parseInt(_0x5a2da4[0x0],0xa),_0x2a44fa['internaldial'][_0x1c7d95('0x1640')]=_0x5a2da4['slice'](0x1,_0x5a2da4['length'])['join'](',');}break;case'message':_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x1640')]=_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x823')];break;case _0x1c7d95('0xceb'):_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x4f0')]=_0x2a44fa[_0x1c7d95('0x143c')]['appdata']['split']('=')[0x0],_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x18e0')]=_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x823')]['split']('=')[0x1];break;case _0x1c7d95('0x1034'):_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x2588')]=_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x823')];break;default:{const _0x4d4bff=_0x2a44fa[_0x1c7d95('0x143c')]['appdata']['split'](',');_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x557')]=_0x2cfb05()[_0x1c7d95('0x1081')](_0x4d4bff[0x0])?_0x4d4bff[0x0]:isNaN(_0x4d4bff[0x0])?_0x4d4bff[0x0]:parseInt(_0x4d4bff[0x0],0xa),_0x2a44fa['internaldial']['timeout']=_0x2cfb05()[_0x1c7d95('0x1081')](_0x4d4bff[0x1])?_0x4d4bff[0x1]:isNaN(_0x4d4bff[0x1])?_0x4d4bff[0x1]:parseInt(_0x4d4bff[0x1],0xa),_0x2a44fa['internaldial']['options']=_0x2cfb05()[_0x1c7d95('0x1081')](_0x4d4bff[0x2])?_0x4d4bff[0x2]:isNaN(_0x4d4bff[0x2])?_0x4d4bff[0x2]:parseInt(_0x4d4bff[0x2],0xa),_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0xcac')]=_0x2cfb05()[_0x1c7d95('0x1081')](_0x4d4bff[0x3])?_0x4d4bff[0x3]:isNaN(_0x4d4bff[0x3])?_0x4d4bff[0x3]:parseInt(_0x4d4bff[0x3],0xa);}break;}else{}_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x1345')]&&_0x2a44fa[_0x1c7d95('0x143c')]['type'][_0x1c7d95('0x2574')]()===_0x1c7d95('0x587')&&_0x2a44fa[_0x1c7d95('0x143c')]['appType']['toLowerCase']()===_0x1c7d95('0x2884')&&(_0x2a44fa['internaldial']['prefix']=_0x2a44fa['internaldial'][_0x1c7d95('0x2026')]?_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x2026')]['split']('$')[0x0]:undefined,_0x2a44fa[_0x1c7d95('0x143c')]['callerId']=_0x2a44fa[_0x1c7d95('0x143c')][_0x1c7d95('0x992')]?_0x1c7d95('0xa4c')+_0x2a44fa['internaldial']['callerID']:undefined);_0x2a44fa[_0x1c7d95('0x1e81')]=_0x350b1b,_0x2a44fa[_0x1c7d95('0x24a0')]=_0x2f6fe4;const _0x44a503=[{'id':0xca,'role':_0x1c7d95('0x1eff')},{'id':0xcb,'role':_0x1c7d95('0x887')}];let _0x5f2bb1=null;_0x151ddc['hasRole'](_0x1c7d95('0xa7c'))?_0x3d9d16[_0x1c7d95('0x557')][_0x1c7d95('0xd83')]({'fields':_0x1c7d95('0x1906'),'sort':_0x1c7d95('0x4f0'),'nolimit':'true'})[_0x1c7d95('0xa44')][_0x1c7d95('0x1166')](function(_0x69d525){const _0x184354=_0x1c7d95;_0x2a44fa[_0x184354('0x21f6')]=_0x69d525['rows']||[];})[_0x1c7d95('0x1a80')](function(_0x37c61e){const _0x547a2c=_0x1c7d95;_0x3fd9e9['error']({'title':_0x37c61e[_0x547a2c('0x52d')]?_0x547a2c('0x1e21')+_0x37c61e['status']+_0x547a2c('0x11e1')+_0x37c61e[_0x547a2c('0xe1b')]:_0x547a2c('0x13e3'),'msg':_0x37c61e[_0x547a2c('0x25f4')]?JSON[_0x547a2c('0xbac')](_0x37c61e['data']):_0x37c61e[_0x547a2c('0x1586')]()});}):_0x3d9d16['user'][_0x1c7d95('0xd83')]({'fields':_0x1c7d95('0x1906'),'sort':_0x1c7d95('0x4f0'),'nolimit':'true'})['$promise'][_0x1c7d95('0x1166')](function(_0x165b1f){const _0x5a8e1b=_0x1c7d95;_0x5f2bb1=_0x165b1f[_0x5a8e1b('0x269a')]||[];})[_0x1c7d95('0x1166')](function(){const _0xb3da2=_0x1c7d95,_0x560081=[];for(let _0x27b13c=0x0;_0x27b13c<_0x44a503['length'];_0x27b13c++){_0x560081[_0xb3da2('0x1514')](_0x3d9d16[_0xb3da2('0x17aa')]['get']({'userProfileId':_0x2a44fa[_0xb3da2('0x98')][_0xb3da2('0xb86')],'sectionId':_0x44a503[_0x27b13c]['id']})[_0xb3da2('0xa44')]);}return _0x164ea2[_0xb3da2('0x2760')](_0x560081);})[_0x1c7d95('0x1166')](function(_0x212eea){const _0x3393b5=_0x1c7d95,_0x242258=_0x2cfb05()[_0x3393b5('0x2563')](_0x212eea,function(_0x5f4d8c){const _0x5a19df=_0x3393b5;return _0x5f4d8c&&_0x5f4d8c[_0x5a19df('0x269a')]?_0x5f4d8c['rows'][0x0]:null;}),_0x1d2291=[];for(let _0x2ac8c9=0x0;_0x2ac8c9<_0x44a503[_0x3393b5('0x264b')];_0x2ac8c9++){const _0x1c8f54=_0x2cfb05()[_0x3393b5('0xc38')](_0x242258,[_0x3393b5('0x120e'),_0x44a503[_0x2ac8c9]['id']]);if(_0x1c8f54){if(!_0x1c8f54[_0x3393b5('0x1a2b')])_0x1d2291[_0x3393b5('0x1514')](_0x3d9d16['userProfileResource'][_0x3393b5('0xd83')]({'sectionId':_0x1c8f54['id']})[_0x3393b5('0xa44')]);else{const _0x395ec4=[];_0x5f2bb1[_0x3393b5('0x2782')](function(_0x380e70){const _0x3e493b=_0x3393b5;_0x380e70['role']===_0x44a503[_0x2ac8c9][_0x3e493b('0x1e75')]&&_0x395ec4[_0x3e493b('0x1514')](_0x380e70);}),_0x1d2291[_0x3393b5('0x1514')]({'rows':_0x395ec4,'count':_0x395ec4[_0x3393b5('0x264b')]});}}}return _0x164ea2[_0x3393b5('0x2760')](_0x1d2291);})[_0x1c7d95('0x1166')](function(_0x270f6c){const _0x219a59=_0x1c7d95,_0x4093fc=[];let _0x38a5ba=null;_0x2a44fa['internaldial']&&(_0x38a5ba=_0x2cfb05()[_0x219a59('0xc38')](_0x5f2bb1,{'name':_0x2a44fa['internaldial'][_0x219a59('0x557')]}));for(let _0xeadffa=0x0;_0xeadffa<_0x270f6c[_0x219a59('0x264b')];_0xeadffa++){const _0x3a45ab=_0x270f6c[_0xeadffa][_0x219a59('0x269a')]||[];_0x3a45ab[_0x219a59('0x2782')](function(_0x196010){_0x4093fc['push'](_0x196010);});}_0x38a5ba&&!_0x2cfb05()[_0x219a59('0x1798')](_0x4093fc,[_0x219a59('0x24e8'),_0x38a5ba['id']])&&_0x5f2bb1[_0x219a59('0x2782')](function(_0x798d6b){const _0x4a55ef=_0x219a59;_0x798d6b['id']===_0x38a5ba['id']&&(_0x798d6b[_0x4a55ef('0x2378')]=![],_0x4093fc[_0x4a55ef('0x1514')](_0x798d6b));}),_0x2a44fa[_0x219a59('0x21f6')]=_0x4093fc;})['catch'](function(_0x1dfb2c){const _0xebf2e9=_0x1c7d95;_0x3fd9e9[_0xebf2e9('0xfc9')]({'title':_0x1dfb2c[_0xebf2e9('0x52d')]?_0xebf2e9('0x1e21')+_0x1dfb2c[_0xebf2e9('0x52d')]+_0xebf2e9('0x11e1')+_0x1dfb2c['statusText']:_0xebf2e9('0x1256'),'msg':_0x1dfb2c[_0xebf2e9('0x25f4')]?JSON[_0xebf2e9('0xbac')](_0x1dfb2c[_0xebf2e9('0x25f4')]):_0x1dfb2c['toString']()});});function _0x350b1b(){const _0x4ab533=_0x1c7d95;_0x2a44fa[_0x4ab533('0x61a')]=[];const _0x2844f1=[];_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x1345')]&&_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x1345')]['toLowerCase']()===_0x4ab533('0x587')&&_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x83f')]===_0x4ab533('0x867')&&(_0x2a44fa[_0x4ab533('0x143c')]['phone']=_0x246c08[_0x4ab533('0x2848')]?(_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x265a')]||'')+_0x4ab533('0x881')+_0x246c08[_0x4ab533('0x2848')]+'}':(_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x265a')]||'')+'${EXTEN}',_0x246c08['recordingFormat']!==_0x4ab533('0x192')?_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0xd39')][_0x4ab533('0x2379')](_0x4ab533('0x1059'))<0x0&&(_0x2a44fa['internaldial'][_0x4ab533('0xd39')]+=_0x4ab533('0x1059')):_0x2a44fa[_0x4ab533('0x143c')]['options']=_0x2a44fa[_0x4ab533('0x143c')]['options']['replace'](_0x4ab533('0x1059'),''));if(_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x83f')]&&_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x83f')]===_0x4ab533('0x2853')){}else switch((_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x746')]||_0x2a44fa['internaldial'][_0x4ab533('0x83f')])['toLowerCase']()){case _0x4ab533('0xceb'):_0x2a44fa['internaldial'][_0x4ab533('0x823')]=_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x4f0')]+'='+_0x2a44fa[_0x4ab533('0x143c')]['value'];break;case _0x4ab533('0x2853'):break;default:_0x2844f1[0x0]=_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x557')],_0x2844f1[0x1]=_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0x651')],_0x2844f1[0x2]=_0x2a44fa[_0x4ab533('0x143c')][_0x4ab533('0xd39')],_0x2844f1[0x3]=_0x2a44fa['internaldial']['url'],_0x2a44fa['internaldial'][_0x4ab533('0x823')]=_0x2844f1['join'](',');}_0x2f6fe4(_0x2a44fa[_0x4ab533('0x143c')]);}function _0x2f6fe4(_0x48353e){_0x24907a['hide'](_0x48353e);}}const _0x8587be=_0x5a39b5;_0x5c1718[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x265d'),_0x36e6f4('0x25d0'),'IndexFactory',_0x36e6f4('0x277c'),_0x36e6f4('0x164e'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x5c1718(_0xe19a92,_0xaeb9f3,_0xc8c7ac,_0x3a4a44,_0x557975,_0x74982c,_0x4ebc1a,_0x580730,_0x4520fb,_0x2ee947){const _0x3287e7=_0x36e6f4,_0x395213=this;_0x395213['currentUser']=_0x4520fb[_0x3287e7('0x26cd')](),_0x395213[_0x3287e7('0x61a')]=[],_0x395213[_0x3287e7('0xcdc')]=_0x3287e7('0x2879'),_0x395213[_0x3287e7('0x277c')]=angular['copy'](_0x557975),_0x395213[_0x3287e7('0x164e')]=_0x74982c,_0x395213[_0x3287e7('0x99d')]=![],_0x395213[_0x3287e7('0x6aa')]=['always','custom',_0x3287e7('0x1480')],_0x395213[_0x3287e7('0x243c')]=_0x2ee947,_0x395213[_0x3287e7('0x5ef')]=_0x3a4a44[_0x3287e7('0x28de')](),_0x395213[_0x3287e7('0x10b4')]=_0x3a4a44[_0x3287e7('0x51d')](),_0x395213[_0x3287e7('0x2259')]=_0x3a4a44['getMonthName'](),_0x395213[_0x3287e7('0x1fc0')]=_0x3a4a44[_0x3287e7('0x2489')]();if(!_0x395213['interval'])_0x395213['interval']={'interval':'*,*,*,*'},_0x395213[_0x3287e7('0x1345')]='always',_0x395213[_0x3287e7('0xcdc')]='TOOLS.NEW_INTERVAL',_0x395213['newInterval']=!![];else{if(_0x395213[_0x3287e7('0x277c')][_0x3287e7('0x277c')]!==_0x3287e7('0x16f')){_0x395213['type']=_0x3287e7('0x2853');const _0x1cd359=_0x395213[_0x3287e7('0x277c')][_0x3287e7('0x277c')][_0x3287e7('0x25c8')](','),_0xbe5514=_0x1cd359[0x0],_0x58e843=_0x1cd359[0x1],_0x4f16f3=_0x1cd359[0x2],_0x3a7d4b=_0x1cd359[0x3];if(_0xbe5514!=='*'){const _0x90a9d5=_0xbe5514['split']('-')[0x0],_0x51e94e=_0xbe5514[_0x3287e7('0x25c8')]('-')[0x1];let _0x347574;_0x347574=new Date(),_0x347574['setHours'](Number(_0x90a9d5['split'](':')[0x0])),_0x347574['setMinutes'](Number(_0x90a9d5[_0x3287e7('0x25c8')](':')[0x1])),_0x395213[_0x3287e7('0x64d')]=_0x347574,_0x347574=new Date(),_0x347574[_0x3287e7('0xe24')](Number(_0x51e94e[_0x3287e7('0x25c8')](':')[0x0])),_0x347574['setMinutes'](Number(_0x51e94e[_0x3287e7('0x25c8')](':')[0x1])),_0x395213[_0x3287e7('0x2076')]=_0x347574;}_0x58e843!=='*'&&(_0x395213[_0x3287e7('0x1eca')]=_0x58e843['split']('-')[0x0],_0x395213[_0x3287e7('0x1b81')]=_0x58e843[_0x3287e7('0x25c8')]('-')[0x1]),_0x4f16f3!=='*'&&(_0x395213[_0x3287e7('0x103d')]=_0x4f16f3[_0x3287e7('0x25c8')]('-')[0x0],_0x395213[_0x3287e7('0x1dbb')]=_0x4f16f3[_0x3287e7('0x25c8')]('-')[0x1]),_0x3a7d4b!=='*'&&(_0x395213[_0x3287e7('0xdec')]=_0x3a7d4b[_0x3287e7('0x25c8')]('-')[0x0],_0x395213[_0x3287e7('0x1125')]=_0x3a7d4b[_0x3287e7('0x25c8')]('-')[0x1]);}else _0x395213['type']='always';}_0xe19a92[_0x3287e7('0x23f')]['id']&&!_0x395213['interval'][_0x3287e7('0x50d')]&&(_0x395213[_0x3287e7('0x277c')][_0x3287e7('0x186f')]=_0xe19a92[_0x3287e7('0x23f')]['id']);_0x395213[_0x3287e7('0x277c')][_0x3287e7('0x186f')]&&_0x395213[_0x3287e7('0x277c')][_0x3287e7('0x50d')]&&(_0x395213[_0x3287e7('0x1345')]=_0x3287e7('0x1480'));_0x395213['addNewInterval']=_0x466da9,_0x395213['saveInterval']=_0x457a1b,_0x395213['closeDialog']=_0x1500fb;_0x395213['interval'][_0x3287e7('0x50d')]&&(_0x4520fb['hasRole'](_0x3287e7('0xa7c'))?_0x580730[_0x3287e7('0x277c')][_0x3287e7('0xd83')]({'fields':_0x3287e7('0xd0a'),'IntervalId':'null','nolimit':!![]})[_0x3287e7('0xa44')][_0x3287e7('0x1166')](function(_0x35c161){const _0xc63a09=_0x3287e7;_0x395213[_0xc63a09('0x164e')]=_0x35c161[_0xc63a09('0x269a')]||[];})[_0x3287e7('0x1a80')](function(_0x2e4848){const _0x223813=_0x3287e7;_0x4ebc1a[_0x223813('0xfc9')]({'title':_0x2e4848[_0x223813('0x52d')]?'API:'+_0x2e4848[_0x223813('0x52d')]+_0x223813('0x11e1')+_0x2e4848[_0x223813('0xe1b')]:_0x223813('0xbb4'),'msg':_0x2e4848[_0x223813('0x25f4')]?JSON[_0x223813('0xbac')](_0x2e4848[_0x223813('0x25f4')]):_0x2e4848[_0x223813('0x1586')]()});}):_0x580730[_0x3287e7('0x277c')][_0x3287e7('0xd83')]({'fields':'id,name,interval,IntervalId','IntervalId':'null','nolimit':!![]})[_0x3287e7('0xa44')][_0x3287e7('0x1166')](function(_0x44d7f6){const _0x1dc36b=_0x3287e7;_0x395213[_0x1dc36b('0x164e')]=_0x44d7f6[_0x1dc36b('0x269a')]||[];})['then'](function(){const _0x3a28dc=_0x3287e7;return _0x580730[_0x3a28dc('0x17aa')][_0x3a28dc('0xd83')]({'userProfileId':_0x395213[_0x3a28dc('0x98')][_0x3a28dc('0xb86')],'sectionId':0x3ec})[_0x3a28dc('0xa44')];})[_0x3287e7('0x1166')](function(_0x11cdab){const _0x3fc446=_0x3287e7,_0xb2dae2=_0x11cdab&&_0x11cdab[_0x3fc446('0x269a')]?_0x11cdab[_0x3fc446('0x269a')][0x0]:null;if(!_0xb2dae2)_0x395213[_0x3fc446('0x164e')]=[];else{if(!_0xb2dae2[_0x3fc446('0x1a2b')])return _0x580730[_0x3fc446('0x4b5')][_0x3fc446('0xd83')]({'sectionId':_0xb2dae2['id']})[_0x3fc446('0xa44')][_0x3fc446('0x1166')](function(_0x4958cf){const _0x377b7b=_0x3fc446,_0x202420=_0x4958cf&&_0x4958cf[_0x377b7b('0x269a')]?_0x4958cf[_0x377b7b('0x269a')]:[],_0x4f81f2=[];let _0x4b2037=null;_0x395213['interval']&&(_0x4b2037=_0x2cfb05()[_0x377b7b('0xc38')](_0x395213[_0x377b7b('0x164e')],{'name':_0x395213[_0x377b7b('0x277c')][_0x377b7b('0x186f')]})),_0x4b2037&&!_0x2cfb05()[_0x377b7b('0x1798')](_0x202420,[_0x377b7b('0x24e8'),_0x4b2037['id']])&&_0x395213[_0x377b7b('0x164e')][_0x377b7b('0x2782')](function(_0x21fa3f){const _0x54f9f2=_0x377b7b;_0x21fa3f['id']===_0x4b2037['id']&&(_0x21fa3f[_0x54f9f2('0x2378')]=![],_0x4f81f2[_0x54f9f2('0x1514')](_0x21fa3f));}),_0x395213[_0x377b7b('0x164e')]=_0x4f81f2;});}})[_0x3287e7('0x1a80')](function(_0x330c90){const _0x1896a5=_0x3287e7;_0x4ebc1a['error']({'title':_0x330c90[_0x1896a5('0x52d')]?_0x1896a5('0x1e21')+_0x330c90[_0x1896a5('0x52d')]+_0x1896a5('0x11e1')+_0x330c90[_0x1896a5('0xe1b')]:_0x1896a5('0xbb4'),'msg':_0x330c90['data']?JSON['stringify'](_0x330c90[_0x1896a5('0x25f4')]):_0x330c90['toString']()});}));function _0x557c52(){const _0x4b1064=_0x3287e7;switch(_0x395213[_0x4b1064('0x1345')]){case _0x4b1064('0x597'):case _0x4b1064('0x1480'):return'*,*,*,*';case'custom':{const _0x266115=[];if(_0x395213[_0x4b1064('0x64d')]!=='*'&&_0x395213['timeRangeFrom']&&_0x395213[_0x4b1064('0x2076')]){const _0x3cfb6b=(_0x395213[_0x4b1064('0x64d')][_0x4b1064('0x11fe')]()<0xa?'0':'')+_0x395213[_0x4b1064('0x64d')]['getHours']()+':'+((_0x395213[_0x4b1064('0x64d')][_0x4b1064('0x234')]()<0xa?'0':'')+_0x395213[_0x4b1064('0x64d')][_0x4b1064('0x234')]()),_0x4929cd=(_0x395213[_0x4b1064('0x2076')][_0x4b1064('0x11fe')]()<0xa?'0':'')+_0x395213['timeRangeTo'][_0x4b1064('0x11fe')]()+':'+((_0x395213[_0x4b1064('0x2076')][_0x4b1064('0x234')]()<0xa?'0':'')+_0x395213[_0x4b1064('0x2076')]['getMinutes']());_0x266115[_0x4b1064('0x1514')](_0x3cfb6b+'-'+_0x4929cd);}else _0x266115[_0x4b1064('0x1514')]('*');return _0x395213['dayOfWeekFrom']?_0x395213[_0x4b1064('0x1b81')]?_0x266115[_0x4b1064('0x1514')](_0x395213[_0x4b1064('0x1eca')]+'-'+_0x395213[_0x4b1064('0x1b81')]):_0x266115[_0x4b1064('0x1514')](_0x395213['dayOfWeekFrom']):_0x266115[_0x4b1064('0x1514')]('*'),_0x395213['monthDayFrom']?_0x395213['monthDayTo']?_0x266115[_0x4b1064('0x1514')](_0x395213[_0x4b1064('0x103d')]+'-'+_0x395213['monthDayTo']):_0x266115[_0x4b1064('0x1514')](_0x395213[_0x4b1064('0x103d')]):_0x266115[_0x4b1064('0x1514')]('*'),_0x395213[_0x4b1064('0xdec')]?_0x395213[_0x4b1064('0x1125')]?_0x266115[_0x4b1064('0x1514')](_0x395213['monthFrom']+'-'+_0x395213['monthTo']):_0x266115[_0x4b1064('0x1514')](_0x395213[_0x4b1064('0xdec')]):_0x266115[_0x4b1064('0x1514')]('*'),_0x266115['join']();}}}function _0x466da9(){const _0x3e6290=_0x3287e7;_0x395213[_0x3e6290('0x61a')]=[],_0x395213[_0x3e6290('0x277c')][_0x3e6290('0x277c')]=_0x557c52(),_0x580730['interval'][_0x3e6290('0x9cc')](_0x395213[_0x3e6290('0x277c')])['$promise'][_0x3e6290('0x1166')](function(_0x5de965){const _0x565303=_0x3e6290;_0x395213[_0x565303('0x164e')][_0x565303('0x1514')](_0x5de965),_0x4ebc1a[_0x565303('0x103b')]({'title':'Interval\x20properly\x20created','msg':_0x395213[_0x565303('0x277c')]['name']?_0x395213[_0x565303('0x277c')]['name']+_0x565303('0x1eda'):''}),_0x1500fb();})[_0x3e6290('0x1a80')](function(_0x335ebc){const _0x5837ce=_0x3e6290;console[_0x5837ce('0xfc9')](_0x335ebc),_0x395213[_0x5837ce('0x61a')]=_0x335ebc[_0x5837ce('0x25f4')]['errors']||[{'message':_0x335ebc[_0x5837ce('0x1586')](),'type':_0x5837ce('0x1192')}];});}function _0x457a1b(){const _0x3e2af2=_0x3287e7;_0x395213[_0x3e2af2('0x61a')]=[],_0x395213[_0x3e2af2('0x277c')][_0x3e2af2('0x277c')]=_0x557c52(),_0x395213[_0x3e2af2('0x277c')][_0x3e2af2('0x50d')]?(_0x395213[_0x3e2af2('0x1345')]!==_0x3e2af2('0x1480')&&(_0x395213[_0x3e2af2('0x277c')][_0x3e2af2('0x186f')]=null),_0x1500fb(_0x395213['interval'])):_0x580730[_0x3e2af2('0x277c')]['update']({'id':_0x395213[_0x3e2af2('0x277c')]['id']},_0x395213[_0x3e2af2('0x277c')])['$promise'][_0x3e2af2('0x1166')](function(_0x40c90f){const _0x39aba2=_0x3e2af2,_0x4f1267=_0x2cfb05()[_0x39aba2('0xc38')](_0x395213[_0x39aba2('0x164e')],{'id':_0x40c90f['id']});_0x4f1267&&_0x2cfb05()[_0x39aba2('0xcc3')](_0x4f1267,_0x40c90f),_0x4ebc1a[_0x39aba2('0x103b')]({'title':'Interval\x20properly\x20saved!','msg':_0x39aba2('0x1666')}),_0x1500fb();})[_0x3e2af2('0x1a80')](function(_0x279a83){const _0x1ff157=_0x3e2af2;console[_0x1ff157('0xfc9')](_0x279a83),_0x395213[_0x1ff157('0x61a')]=_0x279a83['data']['errors']||[{'message':_0x279a83[_0x1ff157('0x1586')](),'type':_0x1ff157('0x2725')}];});}function _0x1500fb(_0x15077e){const _0x2e05d7=_0x3287e7;_0xaeb9f3[_0x2e05d7('0x1197')](_0x15077e);}}const _0x3ac19c=_0x5c1718;_0x4ee444[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21fe'),'inboundroute',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x4ee444(_0x48a576,_0x5d2768,_0x3c574f,_0x4dc41e,_0x18a596,_0x41c527,_0x932416,_0x186167){const _0x72e9c4=_0x36e6f4,_0x108a9e=this;_0x108a9e[_0x72e9c4('0x98')]=_0x932416['getCurrentUser'](),_0x108a9e[_0x72e9c4('0x61a')]=[],_0x108a9e[_0x72e9c4('0xcdc')]='VOICE.EDIT_'+(_0x4dc41e[_0x72e9c4('0x83f')]||_0x4dc41e[_0x72e9c4('0x746')])['toUpperCase'](),_0x108a9e['playback']=angular[_0x72e9c4('0x225f')](_0x4dc41e),_0x108a9e[_0x72e9c4('0x243c')]=_0x186167,_0x108a9e[_0x72e9c4('0x128b')]={};if(_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x823')])switch(_0x108a9e['playback'][_0x72e9c4('0x83f')]?_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x83f')][_0x72e9c4('0x2574')]():_0x108a9e['playback']['app']['toLowerCase']()){case _0x72e9c4('0x2853'):break;case _0x72e9c4('0xded'):{const _0x35958c=_0x108a9e['playback']['appdata']['split'](',');_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x7ca')]=_0x35958c[0x0],_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0xedb')]=_0x35958c[0x1],_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x1634')]=_0x35958c[_0x72e9c4('0x233')](0x2,_0x35958c[_0x72e9c4('0x264b')])[_0x72e9c4('0x45a')](',');}break;case'dialogflowv2':{const _0xd5921d=_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x823')][_0x72e9c4('0x25c8')](',');_0x108a9e['playback'][_0x72e9c4('0x1b0a')]=_0xd5921d[0x0],_0x108a9e[_0x72e9c4('0x19a0')]['clientEmail']=_0xd5921d[0x1],_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x170e')]=_0xd5921d[0x2],_0x108a9e[_0x72e9c4('0x19a0')]['language']=_0xd5921d[0x3],_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x1634')]=_0xd5921d[_0x72e9c4('0x233')](0x4,_0xd5921d[_0x72e9c4('0x264b')])[_0x72e9c4('0x45a')](',');}break;case _0x72e9c4('0x86c'):{const _0x30488e=_0x108a9e[_0x72e9c4('0x19a0')]['appdata'][_0x72e9c4('0x25c8')](',');_0x108a9e['playback']['accesskeyid']=_0x30488e[0x0],_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x125')]=_0x30488e[0x1],_0x108a9e['playback'][_0x72e9c4('0x25a2')]=_0x30488e[0x2],_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x1ac4')]=_0x30488e[0x3],_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x1634')]=_0x30488e[_0x72e9c4('0x233')](0x4,_0x30488e[_0x72e9c4('0x264b')])['join'](',');}break;case'autoreply':{const _0x2034de=_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x823')][_0x72e9c4('0x25c8')](',');_0x108a9e[_0x72e9c4('0x19a0')]['times']=isNaN(_0x2034de[0x0])?_0x2034de[0x0]:parseInt(_0x2034de[0x0],0xa),_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x1640')]=_0x2034de[_0x72e9c4('0x233')](0x1,_0x2034de[_0x72e9c4('0x264b')])['join'](',');}break;case _0x72e9c4('0x1e70'):_0x108a9e[_0x72e9c4('0x19a0')]['text']=_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x823')];break;case _0x72e9c4('0xceb'):_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x4f0')]=_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x823')][_0x72e9c4('0x25c8')]('=')[0x0],_0x108a9e[_0x72e9c4('0x19a0')]['value']=_0x108a9e['playback'][_0x72e9c4('0x823')]['split']('=')[0x1];break;case _0x72e9c4('0x1034'):_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x2588')]=_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x823')];break;default:{const _0x46bab7=_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x823')][_0x72e9c4('0x25c8')](',');_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x823')]=_0x2cfb05()[_0x72e9c4('0x1081')](_0x46bab7[0x0])?_0x46bab7[0x0]:isNaN(_0x46bab7[0x0])?_0x46bab7[0x0]:parseInt(_0x46bab7[0x0],0xa),_0x108a9e[_0x72e9c4('0x19a0')]['options']=_0x2cfb05()['isEmpty'](_0x46bab7[0x1])?_0x46bab7[0x1]:isNaN(_0x46bab7[0x1])?_0x46bab7[0x1]:parseInt(_0x46bab7[0x1],0xa);}break;}else{}_0x108a9e[_0x72e9c4('0x19a0')]['type']&&_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x1345')][_0x72e9c4('0x2574')]()==='outbound'&&_0x108a9e[_0x72e9c4('0x19a0')]['appType'][_0x72e9c4('0x2574')]()===_0x72e9c4('0x2884')&&(_0x108a9e['playback'][_0x72e9c4('0x265a')]=_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x2026')]?_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x2026')][_0x72e9c4('0x25c8')]('$')[0x0]:undefined,_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x1f02')]=_0x108a9e['playback'][_0x72e9c4('0x992')]?_0x72e9c4('0xa4c')+_0x108a9e[_0x72e9c4('0x19a0')][_0x72e9c4('0x992')]:undefined);_0x108a9e['saveInboundRouteApp']=_0x4cb72a,_0x108a9e[_0x72e9c4('0x24a0')]=_0x4c8046,_0x932416[_0x72e9c4('0x1ac6')]('admin')?_0x41c527[_0x72e9c4('0x960')][_0x72e9c4('0xd83')]({'fields':'id,name,save_name','sort':_0x72e9c4('0x4f0'),'nolimit':_0x72e9c4('0xf3b')})[_0x72e9c4('0xa44')][_0x72e9c4('0x1166')](function(_0x1e6154){const _0x51b0c3=_0x72e9c4;_0x108a9e['sounds']=_0x1e6154[_0x51b0c3('0x269a')]||[];})['catch'](function(_0x180ca4){const _0x4e1ed1=_0x72e9c4;_0x3c574f[_0x4e1ed1('0xfc9')]({'title':_0x180ca4[_0x4e1ed1('0x52d')]?_0x4e1ed1('0x1e21')+_0x180ca4[_0x4e1ed1('0x52d')]+_0x4e1ed1('0x11e1')+_0x180ca4[_0x4e1ed1('0xe1b')]:_0x4e1ed1('0x140a'),'msg':_0x180ca4[_0x4e1ed1('0x25f4')]?JSON['stringify'](_0x180ca4[_0x4e1ed1('0x25f4')]):_0x180ca4[_0x4e1ed1('0x1586')]()});}):_0x41c527[_0x72e9c4('0x960')][_0x72e9c4('0xd83')]({'fields':'id,name,save_name','sort':_0x72e9c4('0x4f0'),'nolimit':_0x72e9c4('0xf3b')})[_0x72e9c4('0xa44')][_0x72e9c4('0x1166')](function(_0x36462f){const _0x2ceeb9=_0x72e9c4;_0x108a9e[_0x2ceeb9('0x137')]=_0x36462f['rows']||[];})[_0x72e9c4('0x1166')](function(){const _0x3e5fbb=_0x72e9c4;return _0x41c527[_0x3e5fbb('0x17aa')][_0x3e5fbb('0xd83')]({'userProfileId':_0x108a9e[_0x3e5fbb('0x98')][_0x3e5fbb('0xb86')],'sectionId':0x3ef})[_0x3e5fbb('0xa44')];})[_0x72e9c4('0x1166')](function(_0x2b2cc1){const _0x3509d3=_0x72e9c4,_0x2e71b0=_0x2b2cc1&&_0x2b2cc1['rows']?_0x2b2cc1['rows'][0x0]:null;if(!_0x2e71b0){const _0xabc73d=[];let _0x52f9c7=null;_0x108a9e[_0x3509d3('0x19a0')]&&(_0x52f9c7=_0x2cfb05()[_0x3509d3('0xc38')](_0x108a9e[_0x3509d3('0x137')],{'save_name':_0x108a9e[_0x3509d3('0x19a0')][_0x3509d3('0x960')]}));for(let _0x1ca561=0x0;_0x1ca561<_0x108a9e[_0x3509d3('0x137')][_0x3509d3('0x264b')];_0x1ca561++){_0x52f9c7&&_0x108a9e['sounds'][_0x1ca561]['id']===_0x52f9c7['id']&&(_0x108a9e['sounds'][_0x1ca561][_0x3509d3('0x2378')]=![],_0xabc73d[_0x3509d3('0x1514')](_0x108a9e[_0x3509d3('0x137')][_0x1ca561]));}_0x108a9e[_0x3509d3('0x137')]=_0xabc73d;}else{if(!_0x2e71b0['autoAssociation'])return _0x41c527[_0x3509d3('0x4b5')][_0x3509d3('0xd83')]({'sectionId':_0x2e71b0['id']})['$promise'][_0x3509d3('0x1166')](function(_0x39198e){const _0x2baf24=_0x3509d3,_0x2dd075=_0x2cfb05()['map'](_0x39198e[_0x2baf24('0x269a')],function(_0x2bb317){const _0x35d124=_0x2baf24;return _0x2cfb05()[_0x35d124('0xc38')](_0x108a9e['sounds'],{'id':_0x2bb317[_0x35d124('0x24e8')]});});let _0x31ee8c=null;_0x108a9e[_0x2baf24('0x19a0')]&&(_0x31ee8c=_0x2cfb05()[_0x2baf24('0xc38')](_0x108a9e[_0x2baf24('0x137')],{'save_name':_0x108a9e['playback'][_0x2baf24('0x960')]}));if(_0x31ee8c&&!_0x2cfb05()[_0x2baf24('0x1798')](_0x2dd075,['id',_0x31ee8c['id']])){const _0x424110=_0x2cfb05()[_0x2baf24('0xc38')](_0x108a9e[_0x2baf24('0x137')],{'id':_0x31ee8c['id']});_0x424110[_0x2baf24('0x2378')]=![],_0x2dd075[_0x2baf24('0x1514')](_0x424110);}_0x108a9e[_0x2baf24('0x137')]=_0x2dd075;});}})[_0x72e9c4('0x1a80')](function(_0x57e819){const _0x5108b4=_0x72e9c4;_0x3c574f[_0x5108b4('0xfc9')]({'title':_0x57e819[_0x5108b4('0x52d')]?_0x5108b4('0x1e21')+_0x57e819[_0x5108b4('0x52d')]+_0x5108b4('0x11e1')+_0x57e819['statusText']:_0x5108b4('0x1d89'),'msg':_0x57e819[_0x5108b4('0x25f4')]?JSON[_0x5108b4('0xbac')](_0x57e819['data']):_0x57e819['toString']()});});function _0x4cb72a(){const _0x1799b5=_0x72e9c4;_0x108a9e['errors']=[];const _0x3866e3=[];_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x1345')]&&_0x108a9e['playback']['type'][_0x1799b5('0x2574')]()===_0x1799b5('0x587')&&_0x108a9e['playback'][_0x1799b5('0x83f')]===_0x1799b5('0x867')&&(_0x108a9e['playback'][_0x1799b5('0x2026')]=_0x18a596[_0x1799b5('0x2848')]?(_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x265a')]||'')+_0x1799b5('0x881')+_0x18a596[_0x1799b5('0x2848')]+'}':(_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x265a')]||'')+_0x1799b5('0x1d1'),_0x18a596[_0x1799b5('0x28cb')]!=='none'?_0x108a9e[_0x1799b5('0x19a0')]['options'][_0x1799b5('0x2379')](_0x1799b5('0x1059'))<0x0&&(_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0xd39')]+='U(xcally-mixmonitor-context)'):_0x108a9e['playback'][_0x1799b5('0xd39')]=_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0xd39')]['replace'](_0x1799b5('0x1059'),''));if(_0x108a9e['playback'][_0x1799b5('0x83f')]&&_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x83f')]==='custom'){}else switch((_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x746')]||_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x83f')])[_0x1799b5('0x2574')]()){case'set':_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x823')]=_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x4f0')]+'='+_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x18e0')];break;case _0x1799b5('0x2853'):break;default:_0x3866e3[0x0]=_0x108a9e[_0x1799b5('0x19a0')][_0x1799b5('0x823')],_0x3866e3[0x1]=_0x108a9e[_0x1799b5('0x19a0')]['options'],_0x108a9e[_0x1799b5('0x19a0')]['appdata']=_0x3866e3[_0x1799b5('0x45a')](',');}_0x4c8046(_0x108a9e[_0x1799b5('0x19a0')]);}function _0x4c8046(_0x3f0a31){_0x48a576['hide'](_0x3f0a31);}}const _0x31a660=_0x4ee444;_0x1b3ca8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'inboundrouteApp',_0x36e6f4('0x428'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x1b3ca8(_0x2e241c,_0x2d95ca,_0x2333ff,_0x4f2202,_0x461c0e,_0x514b18,_0x1df10c,_0x41c5aa){const _0x13a39d=_0x36e6f4,_0x1d0d92=this;_0x1d0d92['currentUser']=_0x1df10c[_0x13a39d('0x26cd')](),_0x1d0d92[_0x13a39d('0x61a')]=[],_0x1d0d92['title']='VOICE.EDIT_'+(_0x4f2202[_0x13a39d('0x83f')]||_0x4f2202[_0x13a39d('0x746')])[_0x13a39d('0x1387')](),_0x1d0d92[_0x13a39d('0x1d3e')]=angular[_0x13a39d('0x225f')](_0x4f2202),_0x1d0d92[_0x13a39d('0x243c')]=_0x41c5aa,_0x1d0d92[_0x13a39d('0x128b')]={};if(_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x823')])switch(_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x83f')]?_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x83f')][_0x13a39d('0x2574')]():_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x746')][_0x13a39d('0x2574')]()){case _0x13a39d('0x2853'):break;case'dialogflow':{const _0x1665ec=_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x823')]['split'](',');_0x1d0d92[_0x13a39d('0x1d3e')]['key']=_0x1665ec[0x0],_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0xedb')]=_0x1665ec[0x1],_0x1d0d92['queue']['welcomemessage']=_0x1665ec[_0x13a39d('0x233')](0x2,_0x1665ec['length'])['join'](',');}break;case _0x13a39d('0x1636'):{const _0x2b9c55=_0x1d0d92['queue'][_0x13a39d('0x823')][_0x13a39d('0x25c8')](',');_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x1b0a')]=_0x2b9c55[0x0],_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x27f3')]=_0x2b9c55[0x1],_0x1d0d92[_0x13a39d('0x1d3e')]['privateKey']=_0x2b9c55[0x2],_0x1d0d92['queue'][_0x13a39d('0xedb')]=_0x2b9c55[0x3],_0x1d0d92['queue']['welcomemessage']=_0x2b9c55['slice'](0x4,_0x2b9c55[_0x13a39d('0x264b')])[_0x13a39d('0x45a')](',');}break;case _0x13a39d('0x86c'):{const _0x58132c=_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x823')][_0x13a39d('0x25c8')](',');_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0xee6')]=_0x58132c[0x0],_0x1d0d92['queue']['secretaccesskey']=_0x58132c[0x1],_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x25a2')]=_0x58132c[0x2],_0x1d0d92['queue'][_0x13a39d('0x1ac4')]=_0x58132c[0x3],_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x1634')]=_0x58132c[_0x13a39d('0x233')](0x4,_0x58132c['length'])[_0x13a39d('0x45a')](',');}break;case'autoreply':{const _0x36c1ea=_0x1d0d92['queue']['appdata'][_0x13a39d('0x25c8')](',');_0x1d0d92['queue'][_0x13a39d('0x265e')]=isNaN(_0x36c1ea[0x0])?_0x36c1ea[0x0]:parseInt(_0x36c1ea[0x0],0xa),_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x1640')]=_0x36c1ea[_0x13a39d('0x233')](0x1,_0x36c1ea[_0x13a39d('0x264b')])['join'](',');}break;case _0x13a39d('0x1e70'):_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x1640')]=_0x1d0d92['queue']['appdata'];break;case _0x13a39d('0xceb'):_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x4f0')]=_0x1d0d92['queue'][_0x13a39d('0x823')][_0x13a39d('0x25c8')]('=')[0x0],_0x1d0d92['queue'][_0x13a39d('0x18e0')]=_0x1d0d92['queue'][_0x13a39d('0x823')][_0x13a39d('0x25c8')]('=')[0x1];break;case _0x13a39d('0x1034'):_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x2588')]=_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x823')];break;default:{const _0x31ca00=_0x1d0d92[_0x13a39d('0x1d3e')]['appdata'][_0x13a39d('0x25c8')](',');_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x1d3e')]=_0x2cfb05()['isEmpty'](_0x31ca00[0x0])?_0x31ca00[0x0]:isNaN(_0x31ca00[0x0])?_0x31ca00[0x0]:parseInt(_0x31ca00[0x0],0xa),_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0xd39')]=_0x2cfb05()[_0x13a39d('0x1081')](_0x31ca00[0x1])?_0x31ca00[0x1]:isNaN(_0x31ca00[0x1])?_0x31ca00[0x1]:parseInt(_0x31ca00[0x1],0xa),_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x308')]=_0x2cfb05()[_0x13a39d('0x1081')](_0x31ca00[0x2])?_0x31ca00[0x2]:isNaN(_0x31ca00[0x2])?_0x31ca00[0x2]:parseInt(_0x31ca00[0x2],0xa),_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x960')]=_0x2cfb05()[_0x13a39d('0x1081')](_0x31ca00[0x3])?_0x31ca00[0x3]:isNaN(_0x31ca00[0x3])?_0x31ca00[0x3]:parseInt(_0x31ca00[0x3],0xa),_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x651')]=_0x2cfb05()[_0x13a39d('0x1081')](_0x31ca00[0x4])?_0x31ca00[0x4]:isNaN(_0x31ca00[0x4])?_0x31ca00[0x4]:parseInt(_0x31ca00[0x4],0xa),_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x1034')]=_0x2cfb05()[_0x13a39d('0x1081')](_0x31ca00[0x5])?_0x31ca00[0x5]:isNaN(_0x31ca00[0x5])?_0x31ca00[0x5]:parseInt(_0x31ca00[0x5],0xa),_0x1d0d92['queue'][_0x13a39d('0x1c8')]=_0x2cfb05()[_0x13a39d('0x1081')](_0x31ca00[0x6])?_0x31ca00[0x6]:isNaN(_0x31ca00[0x6])?_0x31ca00[0x6]:parseInt(_0x31ca00[0x6],0xa),_0x1d0d92['queue'][_0x13a39d('0x281c')]=_0x2cfb05()[_0x13a39d('0x1081')](_0x31ca00[0x7])?_0x31ca00[0x7]:isNaN(_0x31ca00[0x7])?_0x31ca00[0x7]:parseInt(_0x31ca00[0x7],0xa),_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x326')]=_0x2cfb05()[_0x13a39d('0x1081')](_0x31ca00[0x8])?_0x31ca00[0x8]:isNaN(_0x31ca00[0x8])?_0x31ca00[0x8]:parseInt(_0x31ca00[0x8],0xa),_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x2086')]=_0x2cfb05()[_0x13a39d('0x1081')](_0x31ca00[0x9])?_0x31ca00[0x9]:isNaN(_0x31ca00[0x9])?_0x31ca00[0x9]:parseInt(_0x31ca00[0x9],0xa);}break;}else{}_0x1d0d92['queue'][_0x13a39d('0x1345')]&&_0x1d0d92['queue'][_0x13a39d('0x1345')][_0x13a39d('0x2574')]()===_0x13a39d('0x587')&&_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x83f')][_0x13a39d('0x2574')]()===_0x13a39d('0x2884')&&(_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x265a')]=_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x2026')]?_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x2026')][_0x13a39d('0x25c8')]('$')[0x0]:undefined,_0x1d0d92[_0x13a39d('0x1d3e')][_0x13a39d('0x1f02')]=_0x1d0d92['queue'][_0x13a39d('0x992')]?_0x13a39d('0xa4c')+_0x1d0d92['queue']['callerID']:undefined);_0x1d0d92[_0x13a39d('0x1e81')]=_0x2a192c,_0x1d0d92['closeDialog']=_0x121bf8,_0x1df10c['hasRole']('admin')?_0x514b18['sound'][_0x13a39d('0xd83')]({'fields':_0x13a39d('0x296'),'sort':'name','nolimit':_0x13a39d('0xf3b')})['$promise'][_0x13a39d('0x1166')](function(_0x190343){const _0x19e46f=_0x13a39d;_0x1d0d92[_0x19e46f('0x137')]=_0x190343['rows']||[];})['catch'](function(_0x205bd5){const _0x37e187=_0x13a39d;_0x2333ff[_0x37e187('0xfc9')]({'title':_0x205bd5[_0x37e187('0x52d')]?_0x37e187('0x1e21')+_0x205bd5['status']+_0x37e187('0x11e1')+_0x205bd5[_0x37e187('0xe1b')]:_0x37e187('0x140a'),'msg':_0x205bd5[_0x37e187('0x25f4')]?JSON[_0x37e187('0xbac')](_0x205bd5[_0x37e187('0x25f4')]):_0x205bd5['toString']()});}):_0x514b18[_0x13a39d('0x960')][_0x13a39d('0xd83')]({'fields':'id,name,save_name','sort':'name','nolimit':_0x13a39d('0xf3b')})[_0x13a39d('0xa44')][_0x13a39d('0x1166')](function(_0x294971){const _0x2dce74=_0x13a39d;_0x1d0d92[_0x2dce74('0x137')]=_0x294971['rows']||[];})[_0x13a39d('0x1166')](function(){const _0x24bb5e=_0x13a39d;return _0x514b18[_0x24bb5e('0x17aa')][_0x24bb5e('0xd83')]({'userProfileId':_0x1d0d92[_0x24bb5e('0x98')][_0x24bb5e('0xb86')],'sectionId':0x3ef})[_0x24bb5e('0xa44')];})['then'](function(_0x3c458e){const _0x4f191c=_0x13a39d,_0xa442ce=_0x3c458e&&_0x3c458e[_0x4f191c('0x269a')]?_0x3c458e[_0x4f191c('0x269a')][0x0]:null;if(!_0xa442ce){const _0x490a85=[];let _0x5d6483=null;_0x1d0d92[_0x4f191c('0x1d3e')]&&(_0x5d6483=_0x2cfb05()[_0x4f191c('0xc38')](_0x1d0d92[_0x4f191c('0x137')],{'save_name':_0x1d0d92[_0x4f191c('0x1d3e')][_0x4f191c('0x960')]}));for(let _0x35a9ce=0x0;_0x35a9ce<_0x1d0d92[_0x4f191c('0x137')]['length'];_0x35a9ce++){_0x5d6483&&_0x1d0d92[_0x4f191c('0x137')][_0x35a9ce]['id']===_0x5d6483['id']&&(_0x1d0d92['sounds'][_0x35a9ce]['canSelect']=![],_0x490a85[_0x4f191c('0x1514')](_0x1d0d92[_0x4f191c('0x137')][_0x35a9ce]));}_0x1d0d92['sounds']=_0x490a85;}else{if(!_0xa442ce[_0x4f191c('0x1a2b')])return _0x514b18[_0x4f191c('0x4b5')][_0x4f191c('0xd83')]({'sectionId':_0xa442ce['id']})[_0x4f191c('0xa44')][_0x4f191c('0x1166')](function(_0x5b8593){const _0x152758=_0x4f191c,_0x4dab85=_0x2cfb05()[_0x152758('0x2563')](_0x5b8593[_0x152758('0x269a')],function(_0x16140d){const _0x4bc24e=_0x152758;return _0x2cfb05()[_0x4bc24e('0xc38')](_0x1d0d92[_0x4bc24e('0x137')],{'id':_0x16140d[_0x4bc24e('0x24e8')]});});let _0x53ba12=null;_0x1d0d92['queue']&&(_0x53ba12=_0x2cfb05()[_0x152758('0xc38')](_0x1d0d92[_0x152758('0x137')],{'save_name':_0x1d0d92['queue'][_0x152758('0x960')]}));if(_0x53ba12&&!_0x2cfb05()['some'](_0x4dab85,['id',_0x53ba12['id']])){const _0x2c253e=_0x2cfb05()[_0x152758('0xc38')](_0x1d0d92[_0x152758('0x137')],{'id':_0x53ba12['id']});_0x2c253e[_0x152758('0x2378')]=![],_0x4dab85[_0x152758('0x1514')](_0x2c253e);}_0x1d0d92[_0x152758('0x137')]=_0x4dab85;});}})['catch'](function(_0x4b4fca){const _0x3e8d35=_0x13a39d;_0x2333ff['error']({'title':_0x4b4fca[_0x3e8d35('0x52d')]?_0x3e8d35('0x1e21')+_0x4b4fca[_0x3e8d35('0x52d')]+_0x3e8d35('0x11e1')+_0x4b4fca[_0x3e8d35('0xe1b')]:'SYSTEM:GETsounds','msg':_0x4b4fca['data']?JSON[_0x3e8d35('0xbac')](_0x4b4fca[_0x3e8d35('0x25f4')]):_0x4b4fca[_0x3e8d35('0x1586')]()});}),_0x1df10c[_0x13a39d('0x1ac6')](_0x13a39d('0xa7c'))?_0x514b18[_0x13a39d('0x1943')]['get']({'type':_0x13a39d('0x14d8'),'fields':'id,name,type','sort':_0x13a39d('0x4f0'),'nolimit':_0x13a39d('0xf3b')})[_0x13a39d('0xa44')][_0x13a39d('0x1166')](function(_0x3901d3){const _0x50aa9f=_0x13a39d;_0x1d0d92[_0x50aa9f('0x7a7')]=_0x3901d3['rows']||[];})[_0x13a39d('0x1a80')](function(_0x1ef6a2){const _0x101925=_0x13a39d;_0x2333ff[_0x101925('0xfc9')]({'title':_0x1ef6a2[_0x101925('0x52d')]?_0x101925('0x1e21')+_0x1ef6a2[_0x101925('0x52d')]+'\x20-\x20'+_0x1ef6a2[_0x101925('0xe1b')]:_0x101925('0x2029'),'msg':_0x1ef6a2[_0x101925('0x25f4')]?JSON[_0x101925('0xbac')](_0x1ef6a2['data']):_0x1ef6a2[_0x101925('0x1586')]()});}):_0x514b18[_0x13a39d('0x1943')][_0x13a39d('0xd83')]({'type':_0x13a39d('0x14d8'),'fields':_0x13a39d('0x1c09'),'sort':_0x13a39d('0x4f0'),'nolimit':_0x13a39d('0xf3b')})[_0x13a39d('0xa44')][_0x13a39d('0x1166')](function(_0x365daf){const _0x3d9fdb=_0x13a39d;_0x1d0d92[_0x3d9fdb('0x7a7')]=_0x365daf['rows']||[];})[_0x13a39d('0x1166')](function(){const _0x2f1b8b=_0x13a39d;return _0x514b18[_0x2f1b8b('0x17aa')]['get']({'userProfileId':_0x1d0d92['currentUser'][_0x2f1b8b('0xb86')],'sectionId':0x191})[_0x2f1b8b('0xa44')];})[_0x13a39d('0x1166')](function(_0xf42ce6){const _0x23a553=_0x13a39d,_0x58e36c=_0xf42ce6&&_0xf42ce6[_0x23a553('0x269a')]?_0xf42ce6[_0x23a553('0x269a')][0x0]:null;if(!_0x58e36c){const _0x2b6795=[];let _0xe393c5=null;_0x1d0d92[_0x23a553('0x1d3e')]&&(_0xe393c5=_0x2cfb05()[_0x23a553('0xc38')](_0x1d0d92[_0x23a553('0x7a7')],{'name':_0x1d0d92[_0x23a553('0x1d3e')][_0x23a553('0x1d3e')]}));for(let _0xb58e4f=0x0;_0xb58e4f<_0x1d0d92[_0x23a553('0x7a7')][_0x23a553('0x264b')];_0xb58e4f++){_0xe393c5&&_0x1d0d92[_0x23a553('0x7a7')][_0xb58e4f]['id']===_0xe393c5['id']&&(_0x1d0d92[_0x23a553('0x7a7')][_0xb58e4f][_0x23a553('0x2378')]=![],_0x2b6795[_0x23a553('0x1514')](_0x1d0d92[_0x23a553('0x7a7')][_0xb58e4f]));}_0x1d0d92[_0x23a553('0x7a7')]=_0x2b6795;}else{if(!_0x58e36c[_0x23a553('0x1a2b')])return _0x514b18['userProfileResource'][_0x23a553('0xd83')]({'sectionId':_0x58e36c['id']})[_0x23a553('0xa44')]['then'](function(_0x377f29){const _0x16fd0a=_0x23a553,_0x4bdca6=_0x2cfb05()[_0x16fd0a('0x2563')](_0x377f29[_0x16fd0a('0x269a')],function(_0x1da207){const _0x5c05d8=_0x16fd0a;return _0x2cfb05()[_0x5c05d8('0xc38')](_0x1d0d92[_0x5c05d8('0x7a7')],{'id':_0x1da207[_0x5c05d8('0x24e8')]});});let _0x34b727=null;_0x1d0d92[_0x16fd0a('0x1d3e')]&&(_0x34b727=_0x2cfb05()[_0x16fd0a('0xc38')](_0x1d0d92[_0x16fd0a('0x7a7')],{'name':_0x1d0d92[_0x16fd0a('0x1d3e')][_0x16fd0a('0x1d3e')]}));if(_0x34b727&&!_0x2cfb05()[_0x16fd0a('0x1798')](_0x4bdca6,['id',_0x34b727['id']])){const _0x1558ba=_0x2cfb05()[_0x16fd0a('0xc38')](_0x1d0d92[_0x16fd0a('0x7a7')],{'id':_0x34b727['id']});_0x1558ba[_0x16fd0a('0x2378')]=![],_0x4bdca6[_0x16fd0a('0x1514')](_0x1558ba);}_0x1d0d92['queues']=_0x4bdca6;});}})[_0x13a39d('0x1a80')](function(_0x41b6de){const _0x5367dd=_0x13a39d;_0x2333ff['error']({'title':_0x41b6de[_0x5367dd('0x52d')]?_0x5367dd('0x1e21')+_0x41b6de[_0x5367dd('0x52d')]+_0x5367dd('0x11e1')+_0x41b6de[_0x5367dd('0xe1b')]:_0x5367dd('0x1dd7'),'msg':_0x41b6de[_0x5367dd('0x25f4')]?JSON[_0x5367dd('0xbac')](_0x41b6de[_0x5367dd('0x25f4')]):_0x41b6de[_0x5367dd('0x1586')]()});});function _0x2a192c(){const _0xf12872=_0x13a39d;_0x1d0d92[_0xf12872('0x61a')]=[];const _0x53d2c4=[];_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x1345')]&&_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x1345')][_0xf12872('0x2574')]()===_0xf12872('0x587')&&_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x83f')]===_0xf12872('0x867')&&(_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x2026')]=_0x461c0e[_0xf12872('0x2848')]?(_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x265a')]||'')+_0xf12872('0x881')+_0x461c0e[_0xf12872('0x2848')]+'}':(_0x1d0d92[_0xf12872('0x1d3e')]['prefix']||'')+_0xf12872('0x1d1'),_0x461c0e[_0xf12872('0x28cb')]!=='none'?_0x1d0d92[_0xf12872('0x1d3e')]['options'][_0xf12872('0x2379')](_0xf12872('0x1059'))<0x0&&(_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0xd39')]+=_0xf12872('0x1059')):_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0xd39')]=_0x1d0d92['queue'][_0xf12872('0xd39')][_0xf12872('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x83f')]&&_0x1d0d92[_0xf12872('0x1d3e')]['appType']===_0xf12872('0x2853')){}else switch((_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x746')]||_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x83f')])[_0xf12872('0x2574')]()){case'set':_0x1d0d92[_0xf12872('0x1d3e')]['appdata']=_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x4f0')]+'='+_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x18e0')];break;case _0xf12872('0x2853'):break;default:_0x53d2c4[0x0]=_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x1d3e')],_0x53d2c4[0x1]=_0x1d0d92[_0xf12872('0x1d3e')]['options'],_0x53d2c4[0x2]=_0x1d0d92[_0xf12872('0x1d3e')]['URL'],_0x53d2c4[0x3]=_0x1d0d92['queue'][_0xf12872('0x960')],_0x53d2c4[0x4]=_0x1d0d92['queue'][_0xf12872('0x651')],_0x53d2c4[0x5]=_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x1034')],_0x53d2c4[0x6]=_0x1d0d92[_0xf12872('0x1d3e')][_0xf12872('0x1c8')],_0x53d2c4[0x7]=_0x1d0d92['queue'][_0xf12872('0x281c')],_0x53d2c4[0x8]=_0x1d0d92[_0xf12872('0x1d3e')]['rule'],_0x53d2c4[0x9]=_0x1d0d92['queue'][_0xf12872('0x2086')],_0x1d0d92[_0xf12872('0x1d3e')]['appdata']=_0x53d2c4[_0xf12872('0x45a')](',');}_0x121bf8(_0x1d0d92[_0xf12872('0x1d3e')]);}function _0x121bf8(_0x101c0a){const _0x379364=_0x13a39d;_0x2e241c[_0x379364('0x1197')](_0x101c0a);}}const _0x15ab86=_0x1b3ca8;_0x551814[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21fe'),'inboundroute',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x551814(_0x2f4538,_0x21c154,_0xb9a4a2,_0x5a9680,_0x4ab5ab,_0x34fd33,_0x5c1c7c,_0x2a42b0){const _0x395d8e=_0x36e6f4,_0x26815f=this;_0x26815f[_0x395d8e('0x98')]=_0x5c1c7c[_0x395d8e('0x26cd')](),_0x26815f[_0x395d8e('0x61a')]=[],_0x26815f[_0x395d8e('0xcdc')]='VOICE.EDIT_'+(_0x5a9680[_0x395d8e('0x83f')]||_0x5a9680[_0x395d8e('0x746')])['toUpperCase'](),_0x26815f['ringgroup']=angular[_0x395d8e('0x225f')](_0x5a9680),_0x26815f[_0x395d8e('0x243c')]=_0x2a42b0,_0x26815f[_0x395d8e('0x128b')]={};if(_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x823')])switch(_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x83f')]?_0x26815f['ringgroup'][_0x395d8e('0x83f')][_0x395d8e('0x2574')]():_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x746')][_0x395d8e('0x2574')]()){case _0x395d8e('0x2853'):break;case _0x395d8e('0xded'):{const _0x5e98bd=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x823')][_0x395d8e('0x25c8')](',');_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x7ca')]=_0x5e98bd[0x0],_0x26815f[_0x395d8e('0xed1')]['language']=_0x5e98bd[0x1],_0x26815f['ringgroup']['welcomemessage']=_0x5e98bd[_0x395d8e('0x233')](0x2,_0x5e98bd[_0x395d8e('0x264b')])[_0x395d8e('0x45a')](',');}break;case _0x395d8e('0x1636'):{const _0x395c11=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x823')][_0x395d8e('0x25c8')](',');_0x26815f['ringgroup'][_0x395d8e('0x1b0a')]=_0x395c11[0x0],_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x27f3')]=_0x395c11[0x1],_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x170e')]=_0x395c11[0x2],_0x26815f[_0x395d8e('0xed1')]['language']=_0x395c11[0x3],_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x1634')]=_0x395c11[_0x395d8e('0x233')](0x4,_0x395c11['length'])[_0x395d8e('0x45a')](',');}break;case _0x395d8e('0x86c'):{const _0x3d081d=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x823')][_0x395d8e('0x25c8')](',');_0x26815f[_0x395d8e('0xed1')]['accesskeyid']=_0x3d081d[0x0],_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x125')]=_0x3d081d[0x1],_0x26815f['ringgroup'][_0x395d8e('0x25a2')]=_0x3d081d[0x2],_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x1ac4')]=_0x3d081d[0x3],_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x1634')]=_0x3d081d[_0x395d8e('0x233')](0x4,_0x3d081d[_0x395d8e('0x264b')])['join'](',');}break;case _0x395d8e('0x1af7'):{const _0x111f44=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x823')][_0x395d8e('0x25c8')](',');_0x26815f['ringgroup'][_0x395d8e('0x265e')]=isNaN(_0x111f44[0x0])?_0x111f44[0x0]:parseInt(_0x111f44[0x0],0xa),_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x1640')]=_0x111f44[_0x395d8e('0x233')](0x1,_0x111f44['length'])[_0x395d8e('0x45a')](',');}break;case'message':_0x26815f['ringgroup'][_0x395d8e('0x1640')]=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x823')];break;case _0x395d8e('0xceb'):_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x4f0')]=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x823')]['split']('=')[0x0],_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x18e0')]=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x823')]['split']('=')[0x1];break;case _0x395d8e('0x1034'):_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x2588')]=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x823')];break;default:{const _0x27c869=_0x26815f[_0x395d8e('0xed1')]['appdata']['split'](',');_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x1855')]=_0x27c869[0x0][_0x395d8e('0x25c8')]('&'),_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x651')]=_0x2cfb05()['isEmpty'](_0x27c869[0x1])?_0x27c869[0x1]:isNaN(_0x27c869[0x1])?_0x27c869[0x1]:parseInt(_0x27c869[0x1],0xa),_0x26815f[_0x395d8e('0xed1')]['options']=_0x2cfb05()['isEmpty'](_0x27c869[0x2])?_0x27c869[0x2]:isNaN(_0x27c869[0x2])?_0x27c869[0x2]:parseInt(_0x27c869[0x2],0xa),_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0xcac')]=_0x2cfb05()['isEmpty'](_0x27c869[0x3])?_0x27c869[0x3]:isNaN(_0x27c869[0x3])?_0x27c869[0x3]:parseInt(_0x27c869[0x3],0xa);}break;}else{}_0x26815f[_0x395d8e('0xed1')]['type']&&_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x1345')]['toLowerCase']()===_0x395d8e('0x587')&&_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x83f')]['toLowerCase']()===_0x395d8e('0x2884')&&(_0x26815f['ringgroup'][_0x395d8e('0x265a')]=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x2026')]?_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x2026')][_0x395d8e('0x25c8')]('$')[0x0]:undefined,_0x26815f['ringgroup'][_0x395d8e('0x1f02')]=_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x992')]?_0x395d8e('0xa4c')+_0x26815f[_0x395d8e('0xed1')][_0x395d8e('0x992')]:undefined);_0x26815f['saveInboundRouteApp']=_0x5bc023,_0x26815f[_0x395d8e('0x24a0')]=_0x116dad;const _0x233f96=[{'id':0xca,'role':_0x395d8e('0x1eff')},{'id':0xcb,'role':_0x395d8e('0x887')}];let _0x3a6283=null;_0x5c1c7c[_0x395d8e('0x1ac6')](_0x395d8e('0xa7c'))?_0x34fd33[_0x395d8e('0x557')][_0x395d8e('0xd83')]({'fields':'id,name,role','sort':_0x395d8e('0x4f0'),'nolimit':'true'})[_0x395d8e('0xa44')][_0x395d8e('0x1166')](function(_0x100287){const _0x3f4fe8=_0x395d8e;_0x26815f[_0x3f4fe8('0x21f6')]=_0x100287[_0x3f4fe8('0x269a')]||[];})[_0x395d8e('0x1a80')](function(_0x1a3f5c){const _0x1cf55e=_0x395d8e;_0xb9a4a2[_0x1cf55e('0xfc9')]({'title':_0x1a3f5c[_0x1cf55e('0x52d')]?_0x1cf55e('0x1e21')+_0x1a3f5c['status']+_0x1cf55e('0x11e1')+_0x1a3f5c[_0x1cf55e('0xe1b')]:_0x1cf55e('0x13e3'),'msg':_0x1a3f5c[_0x1cf55e('0x25f4')]?JSON['stringify'](_0x1a3f5c[_0x1cf55e('0x25f4')]):_0x1a3f5c[_0x1cf55e('0x1586')]()});}):_0x34fd33[_0x395d8e('0x557')][_0x395d8e('0xd83')]({'fields':_0x395d8e('0x1906'),'sort':_0x395d8e('0x4f0'),'nolimit':'true'})['$promise']['then'](function(_0x486374){const _0x5af371=_0x395d8e;_0x3a6283=_0x486374[_0x5af371('0x269a')]||[];})[_0x395d8e('0x1166')](function(){const _0x34ff27=_0x395d8e,_0x1d5bf0=[];for(let _0x57182e=0x0;_0x57182e<_0x233f96[_0x34ff27('0x264b')];_0x57182e++){_0x1d5bf0[_0x34ff27('0x1514')](_0x34fd33[_0x34ff27('0x17aa')][_0x34ff27('0xd83')]({'userProfileId':_0x26815f['currentUser'][_0x34ff27('0xb86')],'sectionId':_0x233f96[_0x57182e]['id']})[_0x34ff27('0xa44')]);}return _0x21c154[_0x34ff27('0x2760')](_0x1d5bf0);})['then'](function(_0x1dbd0b){const _0x29dd84=_0x395d8e,_0x1d9c64=_0x2cfb05()[_0x29dd84('0x2563')](_0x1dbd0b,function(_0x4e1410){const _0x5bb08d=_0x29dd84;return _0x4e1410&&_0x4e1410[_0x5bb08d('0x269a')]?_0x4e1410[_0x5bb08d('0x269a')][0x0]:null;}),_0x4c36d4=[];for(let _0x347e8f=0x0;_0x347e8f<_0x233f96[_0x29dd84('0x264b')];_0x347e8f++){const _0x3fad46=_0x2cfb05()[_0x29dd84('0xc38')](_0x1d9c64,[_0x29dd84('0x120e'),_0x233f96[_0x347e8f]['id']]);if(_0x3fad46){if(!_0x3fad46['autoAssociation'])_0x4c36d4[_0x29dd84('0x1514')](_0x34fd33[_0x29dd84('0x4b5')][_0x29dd84('0xd83')]({'sectionId':_0x3fad46['id']})['$promise']);else{const _0x50a548=[];_0x3a6283[_0x29dd84('0x2782')](function(_0x3e6b9a){const _0x119aad=_0x29dd84;_0x3e6b9a[_0x119aad('0x1e75')]===_0x233f96[_0x347e8f]['role']&&_0x50a548[_0x119aad('0x1514')](_0x3e6b9a);}),_0x4c36d4['push']({'rows':_0x50a548,'count':_0x50a548['length']});}}}return _0x21c154['all'](_0x4c36d4);})['then'](function(_0x378f4c){const _0x1b679a=_0x395d8e,_0x213e39=[];let _0x2673cb=null;_0x26815f[_0x1b679a('0xed1')]&&(_0x2673cb=_0x2cfb05()[_0x1b679a('0xc38')](_0x3a6283,{'name':_0x26815f[_0x1b679a('0xed1')][_0x1b679a('0x1855')]}));for(let _0x2f2c10=0x0;_0x2f2c10<_0x378f4c[_0x1b679a('0x264b')];_0x2f2c10++){const _0x380885=_0x378f4c[_0x2f2c10][_0x1b679a('0x269a')]||[];_0x380885[_0x1b679a('0x2782')](function(_0x4916bb){const _0x4a666c=_0x1b679a;_0x213e39[_0x4a666c('0x1514')](_0x4916bb);});}_0x2673cb&&!_0x2cfb05()[_0x1b679a('0x1798')](_0x213e39,[_0x1b679a('0x24e8'),_0x2673cb['id']])&&_0x3a6283[_0x1b679a('0x2782')](function(_0x11062e){const _0x8571ea=_0x1b679a;_0x11062e['id']===_0x2673cb['id']&&(_0x11062e['canSelect']=![],_0x213e39[_0x8571ea('0x1514')](_0x11062e));}),_0x26815f[_0x1b679a('0x21f6')]=_0x213e39;})[_0x395d8e('0x1a80')](function(_0x3e593f){const _0x26ace2=_0x395d8e;_0xb9a4a2[_0x26ace2('0xfc9')]({'title':_0x3e593f['status']?_0x26ace2('0x1e21')+_0x3e593f[_0x26ace2('0x52d')]+'\x20-\x20'+_0x3e593f['statusText']:_0x26ace2('0x1256'),'msg':_0x3e593f['data']?JSON[_0x26ace2('0xbac')](_0x3e593f[_0x26ace2('0x25f4')]):_0x3e593f[_0x26ace2('0x1586')]()});});function _0x5bc023(){const _0x182c0b=_0x395d8e;_0x26815f['errors']=[];const _0x4cff09=[];_0x26815f[_0x182c0b('0xed1')]['type']&&_0x26815f[_0x182c0b('0xed1')]['type'][_0x182c0b('0x2574')]()===_0x182c0b('0x587')&&_0x26815f[_0x182c0b('0xed1')]['appType']==='outboundDial'&&(_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x2026')]=_0x4ab5ab[_0x182c0b('0x2848')]?(_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x265a')]||'')+_0x182c0b('0x881')+_0x4ab5ab['cutdigits']+'}':(_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x265a')]||'')+_0x182c0b('0x1d1'),_0x4ab5ab[_0x182c0b('0x28cb')]!==_0x182c0b('0x192')?_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0xd39')][_0x182c0b('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0xd39')]+=_0x182c0b('0x1059')):_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0xd39')]=_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0xd39')][_0x182c0b('0xf3')](_0x182c0b('0x1059'),''));if(_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x83f')]&&_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x83f')]===_0x182c0b('0x2853')){}else switch((_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x746')]||_0x26815f[_0x182c0b('0xed1')]['appType'])['toLowerCase']()){case _0x182c0b('0xceb'):_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x823')]=_0x26815f[_0x182c0b('0xed1')]['name']+'='+_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x18e0')];break;case'custom':break;default:_0x4cff09[0x0]=_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x1855')][_0x182c0b('0x45a')]('&'),_0x4cff09[0x1]=_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0x651')],_0x4cff09[0x2]=_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0xd39')],_0x4cff09[0x3]=_0x26815f[_0x182c0b('0xed1')][_0x182c0b('0xcac')],_0x26815f['ringgroup']['appdata']=_0x4cff09[_0x182c0b('0x45a')](',');}_0x116dad(_0x26815f[_0x182c0b('0xed1')]);}function _0x116dad(_0x7f8764){_0x2f4538['hide'](_0x7f8764);}}const _0x157c0a=_0x551814;_0x266fde[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21fe'),_0x36e6f4('0x428'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x266fde(_0x3cc9bf,_0x182f14,_0x516f12,_0x3b61d5,_0x4d1c6b,_0x1fbb3d,_0x3e8cac,_0x269a91){const _0x526130=_0x36e6f4,_0x3d7d90=this;_0x3d7d90[_0x526130('0x98')]=_0x3e8cac[_0x526130('0x26cd')](),_0x3d7d90[_0x526130('0x61a')]=[],_0x3d7d90['title']='VOICE.EDIT_'+(_0x3b61d5[_0x526130('0x83f')]||_0x3b61d5[_0x526130('0x746')])[_0x526130('0x1387')](),_0x3d7d90['set']=angular[_0x526130('0x225f')](_0x3b61d5),_0x3d7d90[_0x526130('0x243c')]=_0x269a91,_0x3d7d90[_0x526130('0x128b')]={};if(_0x3d7d90['set']['appdata'])switch(_0x3d7d90[_0x526130('0xceb')][_0x526130('0x83f')]?_0x3d7d90[_0x526130('0xceb')][_0x526130('0x83f')][_0x526130('0x2574')]():_0x3d7d90[_0x526130('0xceb')][_0x526130('0x746')][_0x526130('0x2574')]()){case'custom':break;case _0x526130('0xded'):{const _0x33ddb2=_0x3d7d90[_0x526130('0xceb')]['appdata'][_0x526130('0x25c8')](',');_0x3d7d90[_0x526130('0xceb')]['key']=_0x33ddb2[0x0],_0x3d7d90['set'][_0x526130('0xedb')]=_0x33ddb2[0x1],_0x3d7d90[_0x526130('0xceb')][_0x526130('0x1634')]=_0x33ddb2[_0x526130('0x233')](0x2,_0x33ddb2[_0x526130('0x264b')])[_0x526130('0x45a')](',');}break;case _0x526130('0x1636'):{const _0xc8b967=_0x3d7d90[_0x526130('0xceb')]['appdata'][_0x526130('0x25c8')](',');_0x3d7d90['set']['projectId']=_0xc8b967[0x0],_0x3d7d90[_0x526130('0xceb')]['clientEmail']=_0xc8b967[0x1],_0x3d7d90['set'][_0x526130('0x170e')]=_0xc8b967[0x2],_0x3d7d90['set'][_0x526130('0xedb')]=_0xc8b967[0x3],_0x3d7d90[_0x526130('0xceb')][_0x526130('0x1634')]=_0xc8b967[_0x526130('0x233')](0x4,_0xc8b967[_0x526130('0x264b')])[_0x526130('0x45a')](',');}break;case _0x526130('0x86c'):{const _0x487037=_0x3d7d90[_0x526130('0xceb')][_0x526130('0x823')][_0x526130('0x25c8')](',');_0x3d7d90[_0x526130('0xceb')]['accesskeyid']=_0x487037[0x0],_0x3d7d90[_0x526130('0xceb')][_0x526130('0x125')]=_0x487037[0x1],_0x3d7d90[_0x526130('0xceb')]['lexregion']=_0x487037[0x2],_0x3d7d90[_0x526130('0xceb')][_0x526130('0x1ac4')]=_0x487037[0x3],_0x3d7d90['set'][_0x526130('0x1634')]=_0x487037['slice'](0x4,_0x487037['length'])[_0x526130('0x45a')](',');}break;case _0x526130('0x1af7'):{const _0x5b2132=_0x3d7d90['set'][_0x526130('0x823')]['split'](',');_0x3d7d90[_0x526130('0xceb')][_0x526130('0x265e')]=isNaN(_0x5b2132[0x0])?_0x5b2132[0x0]:parseInt(_0x5b2132[0x0],0xa),_0x3d7d90[_0x526130('0xceb')][_0x526130('0x1640')]=_0x5b2132[_0x526130('0x233')](0x1,_0x5b2132[_0x526130('0x264b')])[_0x526130('0x45a')](',');}break;case _0x526130('0x1e70'):_0x3d7d90[_0x526130('0xceb')][_0x526130('0x1640')]=_0x3d7d90['set'][_0x526130('0x823')];break;case _0x526130('0xceb'):_0x3d7d90[_0x526130('0xceb')][_0x526130('0x4f0')]=_0x3d7d90[_0x526130('0xceb')][_0x526130('0x823')][_0x526130('0x25c8')]('=')[0x0],_0x3d7d90['set'][_0x526130('0x18e0')]=_0x3d7d90[_0x526130('0xceb')]['appdata'][_0x526130('0x25c8')]('=')[0x1];break;case'agi':_0x3d7d90[_0x526130('0xceb')][_0x526130('0x2588')]=_0x3d7d90[_0x526130('0xceb')][_0x526130('0x823')];break;default:{const _0x29de1a=_0x3d7d90['set'][_0x526130('0x823')][_0x526130('0x25c8')]('=');_0x3d7d90[_0x526130('0xceb')][_0x526130('0x4f0')]=_0x2cfb05()['isEmpty'](_0x29de1a[0x0])?_0x29de1a[0x0]:isNaN(_0x29de1a[0x0])?_0x29de1a[0x0]:parseInt(_0x29de1a[0x0],0xa),_0x3d7d90[_0x526130('0xceb')][_0x526130('0x18e0')]=_0x2cfb05()[_0x526130('0x1081')](_0x29de1a[0x1])?_0x29de1a[0x1]:isNaN(_0x29de1a[0x1])?_0x29de1a[0x1]:parseInt(_0x29de1a[0x1],0xa);}break;}else{}_0x3d7d90[_0x526130('0xceb')][_0x526130('0x1345')]&&_0x3d7d90[_0x526130('0xceb')][_0x526130('0x1345')][_0x526130('0x2574')]()===_0x526130('0x587')&&_0x3d7d90[_0x526130('0xceb')]['appType'][_0x526130('0x2574')]()===_0x526130('0x2884')&&(_0x3d7d90[_0x526130('0xceb')][_0x526130('0x265a')]=_0x3d7d90[_0x526130('0xceb')]['phone']?_0x3d7d90[_0x526130('0xceb')][_0x526130('0x2026')][_0x526130('0x25c8')]('$')[0x0]:undefined,_0x3d7d90[_0x526130('0xceb')][_0x526130('0x1f02')]=_0x3d7d90['set'][_0x526130('0x992')]?_0x526130('0xa4c')+_0x3d7d90[_0x526130('0xceb')][_0x526130('0x992')]:undefined);_0x3d7d90['saveInboundRouteApp']=_0x5a714e,_0x3d7d90[_0x526130('0x24a0')]=_0x4e7868,_0x3e8cac[_0x526130('0x1ac6')](_0x526130('0xa7c'))?_0x1fbb3d[_0x526130('0x734')][_0x526130('0xd83')]({'fields':_0x526130('0x1776'),'sort':_0x526130('0x4f0'),'nolimit':'true'})[_0x526130('0xa44')][_0x526130('0x1166')](function(_0x252911){const _0x7c39c2=_0x526130;_0x3d7d90[_0x7c39c2('0x57a')]=_0x252911['rows']||[];})['catch'](function(_0xffce78){const _0x39e8a8=_0x526130;_0x516f12[_0x39e8a8('0xfc9')]({'title':_0xffce78[_0x39e8a8('0x52d')]?_0x39e8a8('0x1e21')+_0xffce78[_0x39e8a8('0x52d')]+_0x39e8a8('0x11e1')+_0xffce78[_0x39e8a8('0xe1b')]:_0x39e8a8('0xcf8'),'msg':_0xffce78[_0x39e8a8('0x25f4')]?JSON[_0x39e8a8('0xbac')](_0xffce78[_0x39e8a8('0x25f4')]):_0xffce78[_0x39e8a8('0x1586')]()});}):_0x1fbb3d['variable']['get']({'fields':'id,name','sort':_0x526130('0x4f0'),'nolimit':_0x526130('0xf3b')})[_0x526130('0xa44')]['then'](function(_0x423ec0){const _0x44cef1=_0x526130;_0x3d7d90[_0x44cef1('0x57a')]=_0x423ec0[_0x44cef1('0x269a')]||[];})['then'](function(){const _0x5f3bfd=_0x526130;return _0x1fbb3d[_0x5f3bfd('0x17aa')][_0x5f3bfd('0xd83')]({'userProfileId':_0x3d7d90[_0x5f3bfd('0x98')][_0x5f3bfd('0xb86')],'sectionId':0x3f4})[_0x5f3bfd('0xa44')];})[_0x526130('0x1166')](function(_0x5af98b){const _0x1103dd=_0x526130,_0x197c43=_0x5af98b&&_0x5af98b[_0x1103dd('0x269a')]?_0x5af98b['rows'][0x0]:null;if(!_0x197c43){const _0x5b9853=[];let _0x1cfcec=null;_0x3d7d90['set']&&(_0x1cfcec=_0x2cfb05()[_0x1103dd('0xc38')](_0x3d7d90[_0x1103dd('0x57a')],{'name':_0x3d7d90[_0x1103dd('0xceb')]['name']}));for(let _0x13b658=0x0;_0x13b658<_0x3d7d90[_0x1103dd('0x57a')]['length'];_0x13b658++){_0x1cfcec&&_0x3d7d90[_0x1103dd('0x57a')][_0x13b658]['id']===_0x1cfcec['id']&&(_0x3d7d90[_0x1103dd('0x57a')][_0x13b658]['canSelect']=![],_0x5b9853['push'](_0x3d7d90[_0x1103dd('0x57a')][_0x13b658]));}_0x3d7d90[_0x1103dd('0x57a')]=_0x5b9853;}else{if(!_0x197c43[_0x1103dd('0x1a2b')])return _0x1fbb3d[_0x1103dd('0x4b5')]['get']({'sectionId':_0x197c43['id']})[_0x1103dd('0xa44')][_0x1103dd('0x1166')](function(_0x37efa2){const _0x1937a9=_0x1103dd,_0x398abb=_0x2cfb05()[_0x1937a9('0x2563')](_0x37efa2[_0x1937a9('0x269a')],function(_0x581e5d){const _0x29d634=_0x1937a9;return _0x2cfb05()[_0x29d634('0xc38')](_0x3d7d90[_0x29d634('0x57a')],{'id':_0x581e5d['resourceId']});});let _0x1fbc9e=null;_0x3d7d90['set']&&(_0x1fbc9e=_0x2cfb05()[_0x1937a9('0xc38')](_0x3d7d90[_0x1937a9('0x57a')],{'name':_0x3d7d90['set'][_0x1937a9('0x4f0')]}));if(_0x1fbc9e&&!_0x2cfb05()[_0x1937a9('0x1798')](_0x398abb,['id',_0x1fbc9e['id']])){const _0x4addaa=_0x2cfb05()[_0x1937a9('0xc38')](_0x3d7d90[_0x1937a9('0x57a')],{'id':_0x1fbc9e['id']});_0x4addaa[_0x1937a9('0x2378')]=![],_0x398abb[_0x1937a9('0x1514')](_0x4addaa);}_0x3d7d90[_0x1937a9('0x57a')]=_0x398abb;});}})['catch'](function(_0x47f44a){const _0x10b838=_0x526130;_0x516f12[_0x10b838('0xfc9')]({'title':_0x47f44a[_0x10b838('0x52d')]?_0x10b838('0x1e21')+_0x47f44a[_0x10b838('0x52d')]+'\x20-\x20'+_0x47f44a['statusText']:'SYSTEM:GETvariables','msg':_0x47f44a[_0x10b838('0x25f4')]?JSON['stringify'](_0x47f44a[_0x10b838('0x25f4')]):_0x47f44a[_0x10b838('0x1586')]()});});function _0x5a714e(){const _0xe067f6=_0x526130;_0x3d7d90[_0xe067f6('0x61a')]=[];const _0x346c7b=[];_0x3d7d90['set']['type']&&_0x3d7d90[_0xe067f6('0xceb')]['type'][_0xe067f6('0x2574')]()==='outbound'&&_0x3d7d90['set'][_0xe067f6('0x83f')]===_0xe067f6('0x867')&&(_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x2026')]=_0x4d1c6b[_0xe067f6('0x2848')]?(_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x265a')]||'')+_0xe067f6('0x881')+_0x4d1c6b['cutdigits']+'}':(_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x265a')]||'')+_0xe067f6('0x1d1'),_0x4d1c6b[_0xe067f6('0x28cb')]!==_0xe067f6('0x192')?_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0xd39')][_0xe067f6('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x3d7d90['set'][_0xe067f6('0xd39')]+='U(xcally-mixmonitor-context)'):_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0xd39')]=_0x3d7d90[_0xe067f6('0xceb')]['options'][_0xe067f6('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x3d7d90['set']['appType']&&_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x83f')]===_0xe067f6('0x2853')){}else switch((_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x746')]||_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x83f')])[_0xe067f6('0x2574')]()){case'set':_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x823')]=_0x3d7d90[_0xe067f6('0xceb')]['name']+'='+_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x18e0')];break;case _0xe067f6('0x2853'):break;default:_0x346c7b[0x0]=_0x3d7d90['set'][_0xe067f6('0x4f0')],_0x346c7b[0x1]=_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x18e0')],_0x3d7d90[_0xe067f6('0xceb')][_0xe067f6('0x823')]=_0x346c7b['join']('=');}_0x4e7868(_0x3d7d90['set']);}function _0x4e7868(_0x1ee5d9){const _0xdd1367=_0x526130;_0x3cc9bf[_0xdd1367('0x1197')](_0x1ee5d9);}}const _0x690de4=_0x266fde;_0x30e51f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'inboundrouteApp',_0x36e6f4('0x428'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x30e51f(_0x5ef34c,_0x203ec4,_0x2ad89c,_0x4f17c7,_0x4f1225,_0x408b57,_0x53c42d,_0x2e43b6){const _0x470a6a=_0x36e6f4,_0x4afdea=this;_0x4afdea[_0x470a6a('0x98')]=_0x53c42d['getCurrentUser'](),_0x4afdea['errors']=[],_0x4afdea[_0x470a6a('0xcdc')]=_0x470a6a('0xd79')+(_0x4f17c7['appType']||_0x4f17c7[_0x470a6a('0x746')])[_0x470a6a('0x1387')](),_0x4afdea[_0x470a6a('0x1ee9')]=angular['copy'](_0x4f17c7),_0x4afdea[_0x470a6a('0x243c')]=_0x2e43b6,_0x4afdea[_0x470a6a('0x128b')]={};if(_0x4afdea[_0x470a6a('0x1ee9')]['appdata'])switch(_0x4afdea[_0x470a6a('0x1ee9')]['appType']?_0x4afdea[_0x470a6a('0x1ee9')]['appType'][_0x470a6a('0x2574')]():_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x746')][_0x470a6a('0x2574')]()){case'custom':break;case _0x470a6a('0xded'):{const _0xf26c56=_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x823')][_0x470a6a('0x25c8')](',');_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x7ca')]=_0xf26c56[0x0],_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0xedb')]=_0xf26c56[0x1],_0x4afdea['voicemail'][_0x470a6a('0x1634')]=_0xf26c56[_0x470a6a('0x233')](0x2,_0xf26c56[_0x470a6a('0x264b')])[_0x470a6a('0x45a')](',');}break;case _0x470a6a('0x1636'):{const _0x4a0330=_0x4afdea['voicemail'][_0x470a6a('0x823')][_0x470a6a('0x25c8')](',');_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x1b0a')]=_0x4a0330[0x0],_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x27f3')]=_0x4a0330[0x1],_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x170e')]=_0x4a0330[0x2],_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0xedb')]=_0x4a0330[0x3],_0x4afdea['voicemail'][_0x470a6a('0x1634')]=_0x4a0330[_0x470a6a('0x233')](0x4,_0x4a0330['length'])[_0x470a6a('0x45a')](',');}break;case _0x470a6a('0x86c'):{const _0x411f74=_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x823')]['split'](',');_0x4afdea['voicemail'][_0x470a6a('0xee6')]=_0x411f74[0x0],_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x125')]=_0x411f74[0x1],_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x25a2')]=_0x411f74[0x2],_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x1ac4')]=_0x411f74[0x3],_0x4afdea['voicemail'][_0x470a6a('0x1634')]=_0x411f74[_0x470a6a('0x233')](0x4,_0x411f74[_0x470a6a('0x264b')])[_0x470a6a('0x45a')](',');}break;case _0x470a6a('0x1af7'):{const _0x3496c3=_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x823')]['split'](',');_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x265e')]=isNaN(_0x3496c3[0x0])?_0x3496c3[0x0]:parseInt(_0x3496c3[0x0],0xa),_0x4afdea['voicemail'][_0x470a6a('0x1640')]=_0x3496c3['slice'](0x1,_0x3496c3[_0x470a6a('0x264b')])[_0x470a6a('0x45a')](',');}break;case _0x470a6a('0x1e70'):_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x1640')]=_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x823')];break;case _0x470a6a('0xceb'):_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x4f0')]=_0x4afdea[_0x470a6a('0x1ee9')]['appdata'][_0x470a6a('0x25c8')]('=')[0x0],_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x18e0')]=_0x4afdea['voicemail'][_0x470a6a('0x823')][_0x470a6a('0x25c8')]('=')[0x1];break;case _0x470a6a('0x1034'):_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x2588')]=_0x4afdea['voicemail']['appdata'];break;default:{const _0x4f7653=_0x4afdea[_0x470a6a('0x1ee9')]['appdata'][_0x470a6a('0x25c8')](',');_0x4afdea[_0x470a6a('0x1ee9')]['voiceMail']=_0x2cfb05()[_0x470a6a('0x1081')](_0x4f7653[0x0])?_0x4f7653[0x0]:isNaN(_0x4f7653[0x0])?_0x4f7653[0x0]:parseInt(_0x4f7653[0x0],0xa),_0x4afdea['voicemail'][_0x470a6a('0xd39')]=_0x2cfb05()[_0x470a6a('0x1081')](_0x4f7653[0x1])?_0x4f7653[0x1]:isNaN(_0x4f7653[0x1])?_0x4f7653[0x1]:parseInt(_0x4f7653[0x1],0xa);}break;}else{}_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x1345')]&&_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x1345')][_0x470a6a('0x2574')]()===_0x470a6a('0x587')&&_0x4afdea['voicemail'][_0x470a6a('0x83f')]['toLowerCase']()===_0x470a6a('0x2884')&&(_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x265a')]=_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x2026')]?_0x4afdea[_0x470a6a('0x1ee9')]['phone'][_0x470a6a('0x25c8')]('$')[0x0]:undefined,_0x4afdea['voicemail'][_0x470a6a('0x1f02')]=_0x4afdea[_0x470a6a('0x1ee9')]['callerID']?_0x470a6a('0xa4c')+_0x4afdea[_0x470a6a('0x1ee9')][_0x470a6a('0x992')]:undefined);_0x4afdea[_0x470a6a('0x1e81')]=_0x439e4e,_0x4afdea[_0x470a6a('0x24a0')]=_0x368a54,_0x53c42d[_0x470a6a('0x1ac6')](_0x470a6a('0xa7c'))?_0x408b57[_0x470a6a('0x8d4')]['get']({'fields':_0x470a6a('0x189e'),'sort':'mailbox','nolimit':'true'})[_0x470a6a('0xa44')][_0x470a6a('0x1166')](function(_0x742c93){const _0x32e617=_0x470a6a;_0x4afdea[_0x32e617('0x138')]=_0x742c93[_0x32e617('0x269a')]||[];})['catch'](function(_0x171777){const _0x132189=_0x470a6a;_0x2ad89c[_0x132189('0xfc9')]({'title':_0x171777[_0x132189('0x52d')]?_0x132189('0x1e21')+_0x171777[_0x132189('0x52d')]+_0x132189('0x11e1')+_0x171777[_0x132189('0xe1b')]:'SYSTEM:GET_VOICEMAILS','msg':_0x171777['data']?JSON['stringify'](_0x171777[_0x132189('0x25f4')]):_0x171777[_0x132189('0x1586')]()});}):_0x408b57['voiceMail'][_0x470a6a('0xd83')]({'fields':_0x470a6a('0x189e'),'sort':_0x470a6a('0x1cfc'),'nolimit':_0x470a6a('0xf3b')})['$promise'][_0x470a6a('0x1166')](function(_0x2b521a){const _0x15c321=_0x470a6a;_0x4afdea[_0x15c321('0x138')]=_0x2b521a[_0x15c321('0x269a')]||[];})['then'](function(){const _0x3b2010=_0x470a6a;return _0x408b57[_0x3b2010('0x17aa')][_0x3b2010('0xd83')]({'userProfileId':_0x4afdea[_0x3b2010('0x98')][_0x3b2010('0xb86')],'sectionId':0x196})[_0x3b2010('0xa44')];})['then'](function(_0x2329c5){const _0x47da0b=_0x470a6a,_0x47990a=_0x2329c5&&_0x2329c5['rows']?_0x2329c5[_0x47da0b('0x269a')][0x0]:null;if(!_0x47990a){const _0x30eb17=[];let _0x13a9de=null;_0x4afdea[_0x47da0b('0x1ee9')]&&(_0x13a9de=_0x2cfb05()[_0x47da0b('0xc38')](_0x4afdea[_0x47da0b('0x138')],{'mailbox':_0x4afdea[_0x47da0b('0x1ee9')][_0x47da0b('0x8d4')]}));for(let _0x473367=0x0;_0x473367<_0x4afdea[_0x47da0b('0x138')][_0x47da0b('0x264b')];_0x473367++){_0x13a9de&&_0x4afdea[_0x47da0b('0x138')][_0x473367]['id']===_0x13a9de['id']&&(_0x4afdea[_0x47da0b('0x138')][_0x473367]['canSelect']=![],_0x30eb17[_0x47da0b('0x1514')](_0x4afdea['voiceMails'][_0x473367]));}_0x4afdea[_0x47da0b('0x138')]=_0x30eb17;}else{if(!_0x47990a[_0x47da0b('0x1a2b')])return _0x408b57[_0x47da0b('0x4b5')][_0x47da0b('0xd83')]({'sectionId':_0x47990a['id']})[_0x47da0b('0xa44')][_0x47da0b('0x1166')](function(_0x1cb32c){const _0x344c0d=_0x47da0b,_0x322c17=_0x2cfb05()[_0x344c0d('0x2563')](_0x1cb32c['rows'],function(_0x59b183){return _0x2cfb05()['find'](_0x4afdea['voiceMails'],{'id':_0x59b183['resourceId']});});let _0x52cfd7=null;_0x4afdea[_0x344c0d('0x1ee9')]&&(_0x52cfd7=_0x2cfb05()['find'](_0x4afdea['voiceMails'],{'mailbox':_0x4afdea[_0x344c0d('0x1ee9')][_0x344c0d('0x8d4')]}));if(_0x52cfd7&&!_0x2cfb05()[_0x344c0d('0x1798')](_0x322c17,['id',_0x52cfd7['id']])){const _0x4756c1=_0x2cfb05()[_0x344c0d('0xc38')](_0x4afdea['voiceMails'],{'id':_0x52cfd7['id']});_0x4756c1['canSelect']=![],_0x322c17[_0x344c0d('0x1514')](_0x4756c1);}_0x4afdea[_0x344c0d('0x138')]=_0x322c17;});}})['catch'](function(_0xe924b9){const _0x26fc3d=_0x470a6a;_0x2ad89c[_0x26fc3d('0xfc9')]({'title':_0xe924b9['status']?_0x26fc3d('0x1e21')+_0xe924b9['status']+_0x26fc3d('0x11e1')+_0xe924b9[_0x26fc3d('0xe1b')]:_0x26fc3d('0xc7'),'msg':_0xe924b9[_0x26fc3d('0x25f4')]?JSON[_0x26fc3d('0xbac')](_0xe924b9[_0x26fc3d('0x25f4')]):_0xe924b9[_0x26fc3d('0x1586')]()});});function _0x439e4e(){const _0x123070=_0x470a6a;_0x4afdea['errors']=[];const _0x481234=[];_0x4afdea[_0x123070('0x1ee9')]['type']&&_0x4afdea[_0x123070('0x1ee9')]['type'][_0x123070('0x2574')]()===_0x123070('0x587')&&_0x4afdea[_0x123070('0x1ee9')][_0x123070('0x83f')]===_0x123070('0x867')&&(_0x4afdea['voicemail'][_0x123070('0x2026')]=_0x4f1225[_0x123070('0x2848')]?(_0x4afdea['voicemail'][_0x123070('0x265a')]||'')+_0x123070('0x881')+_0x4f1225[_0x123070('0x2848')]+'}':(_0x4afdea[_0x123070('0x1ee9')][_0x123070('0x265a')]||'')+_0x123070('0x1d1'),_0x4f1225[_0x123070('0x28cb')]!=='none'?_0x4afdea[_0x123070('0x1ee9')][_0x123070('0xd39')][_0x123070('0x2379')](_0x123070('0x1059'))<0x0&&(_0x4afdea[_0x123070('0x1ee9')][_0x123070('0xd39')]+=_0x123070('0x1059')):_0x4afdea[_0x123070('0x1ee9')][_0x123070('0xd39')]=_0x4afdea[_0x123070('0x1ee9')][_0x123070('0xd39')]['replace'](_0x123070('0x1059'),''));if(_0x4afdea['voicemail'][_0x123070('0x83f')]&&_0x4afdea[_0x123070('0x1ee9')][_0x123070('0x83f')]===_0x123070('0x2853')){}else switch((_0x4afdea[_0x123070('0x1ee9')][_0x123070('0x746')]||_0x4afdea[_0x123070('0x1ee9')][_0x123070('0x83f')])[_0x123070('0x2574')]()){case _0x123070('0xceb'):_0x4afdea[_0x123070('0x1ee9')][_0x123070('0x823')]=_0x4afdea[_0x123070('0x1ee9')][_0x123070('0x4f0')]+'='+_0x4afdea['voicemail'][_0x123070('0x18e0')];break;case _0x123070('0x2853'):break;default:_0x481234[0x0]=_0x4afdea[_0x123070('0x1ee9')]['voiceMail'],_0x481234[0x1]=_0x4afdea[_0x123070('0x1ee9')][_0x123070('0xd39')],_0x4afdea[_0x123070('0x1ee9')]['appdata']=_0x481234[_0x123070('0x45a')](',');}_0x368a54(_0x4afdea[_0x123070('0x1ee9')]);}function _0x368a54(_0x44527a){const _0x3f9fb0=_0x470a6a;_0x5ef34c[_0x3f9fb0('0x1197')](_0x44527a);}}const _0x3b9d7d=_0x30e51f;_0xe5da6['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),'license','setting',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),'Auth','inboundroute',_0x36e6f4('0x17aa')];function _0xe5da6(_0x3a542d,_0x263ecf,_0x1642bf,_0x464a5,_0x514d3b,_0x354c2a,_0x4c1a11,_0x15e784,_0x5f56e5,_0x1d7dd6,_0x513ef3,_0x42d367){const _0x5da935=_0x36e6f4,_0x575d8d=this;_0x575d8d['currentUser']=_0x1d7dd6['getCurrentUser'](),_0x575d8d['license']=_0x354c2a,_0x575d8d[_0x5da935('0xf8a')]=_0x4c1a11,_0x575d8d['passwordPattern']=_0x575d8d['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x575d8d[_0x5da935('0x246b')]=_0x263ecf[_0x5da935('0x6f1')]()+_0x5da935('0xc51')+_0x263ecf['host'](),_0x575d8d[_0x5da935('0x428')]=_0x513ef3||_0x3a542d['params'][_0x5da935('0x428')]||{},_0x575d8d['userProfileSection']=_0x42d367&&_0x42d367[_0x5da935('0x240f')]==0x1?_0x42d367[_0x5da935('0x269a')][0x0]:null,_0x575d8d[_0x5da935('0x243c')]=_0x1d7dd6[_0x5da935('0xd87')](_0x575d8d['userProfileSection']?_0x575d8d['userProfileSection'][_0x5da935('0x243c')]:null),_0x575d8d[_0x5da935('0x128b')]={},_0x575d8d['selectedTab']=_0x3a542d['params']['tab']||0x0,_0x575d8d['alert']=_0x5f56e5['info'],_0x575d8d[_0x5da935('0x174d')]=_0x1c5fc8,_0x575d8d[_0x5da935('0xacd')]=_0x12c800,_0x1d7dd6[_0x5da935('0x1ac6')](_0x5da935('0xa7c'))?_0x15e784[_0x5da935('0x23b1')][_0x5da935('0xd83')]({'fields':_0x5da935('0x1776'),'sort':_0x5da935('0x4f0'),'nolimit':_0x5da935('0xf3b')})[_0x5da935('0xa44')][_0x5da935('0x1166')](function(_0x19f662){const _0x19a5a3=_0x5da935;_0x575d8d[_0x19a5a3('0x160a')]=_0x19f662[_0x19a5a3('0x269a')]||[];})[_0x5da935('0x1a80')](function(_0x59069b){const _0x218b6b=_0x5da935;_0x5f56e5[_0x218b6b('0xfc9')]({'title':_0x59069b[_0x218b6b('0x52d')]?_0x218b6b('0x1e21')+_0x59069b[_0x218b6b('0x52d')]+_0x218b6b('0x11e1')+_0x59069b[_0x218b6b('0xe1b')]:_0x218b6b('0x140d'),'msg':_0x59069b['data']?JSON[_0x218b6b('0xbac')](_0x59069b[_0x218b6b('0x25f4')]):_0x59069b[_0x218b6b('0x1586')]()});}):_0x15e784['voiceContext'][_0x5da935('0xd83')]({'fields':_0x5da935('0x1776'),'sort':_0x5da935('0x4f0'),'nolimit':_0x5da935('0xf3b')})[_0x5da935('0xa44')][_0x5da935('0x1166')](function(_0x37a837){const _0x4ac47e=_0x5da935;_0x575d8d[_0x4ac47e('0x160a')]=_0x37a837[_0x4ac47e('0x269a')]||[];})[_0x5da935('0x1166')](function(){const _0x43fccf=_0x5da935;return _0x15e784[_0x43fccf('0x17aa')]['get']({'userProfileId':_0x575d8d['currentUser'][_0x43fccf('0xb86')],'sectionId':0x195})[_0x43fccf('0xa44')];})['then'](function(_0x14f6f0){const _0x140db3=_0x5da935,_0x1d27b0=_0x14f6f0&&_0x14f6f0['rows']?_0x14f6f0[_0x140db3('0x269a')][0x0]:null;if(!_0x1d27b0)return _0x15e784[_0x140db3('0x23b1')]['get']({'fields':_0x140db3('0x1776'),'sort':'name','nolimit':_0x140db3('0xf3b'),'defaultEntry':0x1})['$promise'][_0x140db3('0x1166')](function(_0x4d7698){const _0x198f12=_0x140db3;_0x575d8d[_0x198f12('0x160a')]=_0x4d7698[_0x198f12('0x269a')]||[];});else{if(!_0x1d27b0['autoAssociation'])return _0x15e784[_0x140db3('0x4b5')]['get']({'sectionId':_0x1d27b0['id']})[_0x140db3('0xa44')][_0x140db3('0x1166')](function(_0x30c1a9){const _0x180854=_0x140db3,_0xf4c88c=_0x2cfb05()['map'](_0x30c1a9['rows'],function(_0x3f142a){const _0x393dab=a0_0x3f2c;return _0x2cfb05()[_0x393dab('0xc38')](_0x575d8d[_0x393dab('0x160a')],{'id':_0x3f142a['resourceId']});});let _0x2bde74=null;_0x575d8d['inboundroute']&&(_0x2bde74=_0x2cfb05()[_0x180854('0xc38')](_0x575d8d[_0x180854('0x160a')],{'name':_0x575d8d[_0x180854('0x428')][_0x180854('0xe1c')]}));if(_0x2bde74&&!_0x2cfb05()['some'](_0xf4c88c,['id',_0x2bde74['id']])){const _0x374c6c=_0x2cfb05()[_0x180854('0xc38')](_0x575d8d[_0x180854('0x160a')],{'id':_0x2bde74['id']});_0x374c6c[_0x180854('0x2378')]=![],_0xf4c88c[_0x180854('0x1514')](_0x374c6c);}_0x575d8d[_0x180854('0x160a')]=_0xf4c88c;});}})[_0x5da935('0x1a80')](function(_0x4bb5bd){const _0x4ff1a6=_0x5da935;_0x5f56e5[_0x4ff1a6('0xfc9')]({'title':_0x4bb5bd[_0x4ff1a6('0x52d')]?_0x4ff1a6('0x1e21')+_0x4bb5bd[_0x4ff1a6('0x52d')]+'\x20-\x20'+_0x4bb5bd['statusText']:_0x4ff1a6('0x482'),'msg':_0x4bb5bd[_0x4ff1a6('0x25f4')]?JSON[_0x4ff1a6('0xbac')](_0x4bb5bd['data']):_0x4bb5bd['toString']()});});function _0x1c5fc8(){const _0x4a65e4=_0x5da935;_0x3a542d['go'](_0x4a65e4('0x2107'),{},{'reload':_0x4a65e4('0x2107')});}function _0x12c800(){const _0xa31fcd=_0x5da935;_0x15e784[_0xa31fcd('0x1deb')][_0xa31fcd('0x1449')]({'id':_0x575d8d[_0xa31fcd('0x428')]['id']},_0x575d8d[_0xa31fcd('0x428')])['$promise']['then'](function(){const _0xf36bad=_0xa31fcd;_0x5f56e5['success']({'title':_0xf36bad('0x2d6'),'msg':_0x575d8d['inboundroute'][_0xf36bad('0x4f0')]?_0x575d8d[_0xf36bad('0x428')]['name']+_0xf36bad('0xa17'):''});})[_0xa31fcd('0x1a80')](function(_0xfc9425){const _0x1f2c6e=_0xa31fcd;_0x5f56e5[_0x1f2c6e('0xfc9')]({'title':_0xfc9425[_0x1f2c6e('0x52d')]?_0x1f2c6e('0x1e21')+_0xfc9425['status']+_0x1f2c6e('0x11e1')+_0xfc9425[_0x1f2c6e('0xe1b')]:_0x1f2c6e('0x1af9'),'msg':_0xfc9425[_0x1f2c6e('0x25f4')]?JSON[_0x1f2c6e('0xbac')](_0xfc9425[_0x1f2c6e('0x25f4')]):_0xfc9425[_0x1f2c6e('0x1586')]()});});}}const _0x1d28cc=_0xe5da6,_0x2a60a0=_0x2734b2['p']+_0x36e6f4('0xb67');_0xbfdefe[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0xc30'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0xbfdefe(_0x2df9b0,_0x245754,_0x188bd8,_0x2b5c94,_0x683008,_0x430bf2,_0x274a50,_0x2a6613,_0x3cb4e6,_0x2258a6,_0x46895e,_0x303010,_0x2b2699,_0x3175ce,_0xa004d0,_0x2dde51,_0x571715){const _0x1ba616=_0x36e6f4,_0x40a2f6=this;_0x40a2f6[_0x1ba616('0x5c9')]=_0x2dde51,_0x40a2f6[_0x1ba616('0xf8a')]=_0x571715,_0x40a2f6[_0x1ba616('0x98')]=_0xa004d0[_0x1ba616('0x26cd')](),_0x40a2f6[_0x1ba616('0xc30')]=_0x3cb4e6||{'count':0x0,'rows':[]},_0x40a2f6[_0x1ba616('0x7f')]=_0x2258a6,_0x40a2f6['userProfileSection']=_0x46895e&&_0x46895e[_0x1ba616('0x240f')]==0x1?_0x46895e[_0x1ba616('0x269a')][0x0]:null,_0x40a2f6[_0x1ba616('0x243c')]=_0xa004d0['parseCrudPermissions'](_0x40a2f6['userProfileSection']?_0x40a2f6[_0x1ba616('0x17aa')][_0x1ba616('0x243c')]:null),_0x40a2f6[_0x1ba616('0x916')]=_0x1ba616('0xc30'),_0x40a2f6['listOrder']='',_0x40a2f6[_0x1ba616('0x104c')]=null,_0x40a2f6[_0x1ba616('0x1ed9')]=[],_0x40a2f6['query']={'fields':'createdAt,updatedAt,id,appdata,type,exten,context,description','type':_0x1ba616('0x14d8'),'sort':'-updatedAt','VoiceExtensionId':_0x1ba616('0x15d7'),'limit':0xa,'page':0x1},_0x40a2f6[_0x1ba616('0x1ff6')]=_0x188181,_0x40a2f6[_0x1ba616('0x8d8')]=_0x1918ed,_0x40a2f6['success']=_0xcd6569,_0x40a2f6[_0x1ba616('0x584')]=_0x5ca05b,_0x40a2f6['createOrEditInboundRoute']=_0x51a5ef,_0x40a2f6[_0x1ba616('0x1235')]=_0x1cc672,_0x40a2f6[_0x1ba616('0x7a1')]=_0x3a1639,_0x40a2f6[_0x1ba616('0x36a')]=_0x97eb52,_0x40a2f6['deselectInboundRoutes']=_0x33adcc,_0x40a2f6[_0x1ba616('0x1367')]=_0x583572,_0xa004d0[_0x1ba616('0x1ac6')](_0x1ba616('0xa7c'))?_0x303010[_0x1ba616('0x23b1')][_0x1ba616('0xd83')]({'fields':'id,name','sort':_0x1ba616('0x4f0'),'nolimit':'true'})['$promise'][_0x1ba616('0x1166')](function(_0x16fab3){const _0x39500a=_0x1ba616;_0x40a2f6['contexts']=_0x16fab3[_0x39500a('0x269a')]||[];})['catch'](function(_0x289a9b){const _0x4938c2=_0x1ba616;_0x3175ce['error']({'title':_0x289a9b[_0x4938c2('0x52d')]?'API:'+_0x289a9b['status']+_0x4938c2('0x11e1')+_0x289a9b[_0x4938c2('0xe1b')]:_0x4938c2('0x140d'),'msg':_0x289a9b[_0x4938c2('0x25f4')]?JSON[_0x4938c2('0xbac')](_0x289a9b[_0x4938c2('0x25f4')]):_0x289a9b['toString']()});}):_0x303010[_0x1ba616('0x23b1')][_0x1ba616('0xd83')]({'fields':_0x1ba616('0x1776'),'sort':_0x1ba616('0x4f0'),'nolimit':'true'})[_0x1ba616('0xa44')]['then'](function(_0x348fe8){const _0x3132f2=_0x1ba616;_0x40a2f6[_0x3132f2('0x160a')]=_0x348fe8['rows']||[];})[_0x1ba616('0x1166')](function(){const _0x3237cb=_0x1ba616;return _0x303010[_0x3237cb('0x17aa')][_0x3237cb('0xd83')]({'userProfileId':_0x40a2f6[_0x3237cb('0x98')][_0x3237cb('0xb86')],'sectionId':0x195})[_0x3237cb('0xa44')];})['then'](function(_0x3c9e7a){const _0x14e830=_0x1ba616,_0x230310=_0x3c9e7a&&_0x3c9e7a[_0x14e830('0x269a')]?_0x3c9e7a[_0x14e830('0x269a')][0x0]:null;if(!_0x230310)return _0x303010[_0x14e830('0x23b1')]['get']({'fields':_0x14e830('0x1776'),'sort':'name','nolimit':'true','defaultEntry':0x1})[_0x14e830('0xa44')]['then'](function(_0x659153){const _0x5146cc=_0x14e830;_0x40a2f6[_0x5146cc('0x160a')]=_0x659153['rows']||[];});else{if(!_0x230310['autoAssociation'])return _0x303010[_0x14e830('0x4b5')][_0x14e830('0xd83')]({'sectionId':_0x230310['id']})[_0x14e830('0xa44')][_0x14e830('0x1166')](function(_0xfe0b29){const _0x126780=_0x14e830,_0x356ffc=_0x2cfb05()[_0x126780('0x2563')](_0xfe0b29[_0x126780('0x269a')],function(_0x19a849){const _0x543925=_0x126780;return _0x2cfb05()[_0x543925('0xc38')](_0x40a2f6[_0x543925('0x160a')],{'id':_0x19a849[_0x543925('0x24e8')]});});let _0x287257=null;_0x40a2f6[_0x126780('0x428')]&&(_0x287257=_0x2cfb05()[_0x126780('0xc38')](_0x40a2f6[_0x126780('0x160a')],{'name':_0x40a2f6[_0x126780('0x428')][_0x126780('0xe1c')]}));if(_0x287257&&!_0x2cfb05()[_0x126780('0x1798')](_0x356ffc,['id',_0x287257['id']])){const _0x494b24=_0x2cfb05()[_0x126780('0xc38')](_0x40a2f6[_0x126780('0x160a')],{'id':_0x287257['id']});_0x494b24['canSelect']=![],_0x356ffc[_0x126780('0x1514')](_0x494b24);}_0x40a2f6[_0x126780('0x160a')]=_0x356ffc;});}})[_0x1ba616('0x1a80')](function(_0x24fdd3){const _0x59e686=_0x1ba616;_0x3175ce[_0x59e686('0xfc9')]({'title':_0x24fdd3[_0x59e686('0x52d')]?_0x59e686('0x1e21')+_0x24fdd3[_0x59e686('0x52d')]+'\x20-\x20'+_0x24fdd3['statusText']:_0x59e686('0x482'),'msg':_0x24fdd3['data']?JSON[_0x59e686('0xbac')](_0x24fdd3[_0x59e686('0x25f4')]):_0x24fdd3[_0x59e686('0x1586')]()});});function _0x188181(_0x435e3d){const _0x490925=_0x1ba616;_0x188bd8['go'](_0x490925('0x2609'),{'id':_0x435e3d['id'],'inboundroute':_0x435e3d,'crudPermissions':_0x40a2f6['crudPermissions']});}function _0x1918ed(_0x2f52d8,_0x42933a){const _0x5846a4=_0x1ba616,_0x15f6c8=_0x683008[_0x5846a4('0x1d26')]()[_0x5846a4('0xcdc')](_0x5846a4('0x288d')+_0x2cfb05()[_0x5846a4('0xb35')]('inboundroute')+'?')[_0x5846a4('0xf3c')](_0x5846a4('0x12b5')+(_0x2f52d8[_0x5846a4('0x4f0')]||_0x5846a4('0x428'))+_0x5846a4('0xace')+'\x20will\x20be\x20deleted.')[_0x5846a4('0x8e8')](_0x5846a4('0x1133'))[_0x5846a4('0x203b')](_0x42933a)['ok']('OK')[_0x5846a4('0x3f')](_0x5846a4('0x2d3'));_0x683008['show'](_0x15f6c8)[_0x5846a4('0x1166')](function(){_0x1cc672(_0x2f52d8);},function(){const _0x2dce8d=_0x5846a4;console[_0x2dce8d('0x455')](_0x2dce8d('0x2d3'));});}let _0x3677bd=!![],_0x17fb6c=0x1;_0x2df9b0['$watch'](_0x1ba616('0x12d8'),function(_0x4dbbdd,_0x26ef55){const _0x3a7b83=_0x1ba616;_0x3677bd?_0x274a50(function(){_0x3677bd=![];}):(!_0x26ef55&&(_0x17fb6c=_0x40a2f6[_0x3a7b83('0x2218')]['page']),_0x4dbbdd!==_0x26ef55&&(_0x40a2f6[_0x3a7b83('0x2218')]['page']=0x1),!_0x4dbbdd&&(_0x40a2f6[_0x3a7b83('0x2218')][_0x3a7b83('0x1a43')]=_0x17fb6c),_0x40a2f6['getInboundRoutes']());});function _0xcd6569(_0x3ea55f){const _0x5a974a=_0x1ba616;_0x40a2f6[_0x5a974a('0xc30')]=_0x3ea55f||{'count':0x0,'rows':[]};}function _0x5ca05b(){const _0x311d03=_0x1ba616;_0x40a2f6['query'][_0x311d03('0x1098')]=(_0x40a2f6[_0x311d03('0x2218')][_0x311d03('0x1a43')]-0x1)*_0x40a2f6[_0x311d03('0x2218')][_0x311d03('0x163f')],_0xa004d0[_0x311d03('0x1ac6')]('admin')?_0x40a2f6['promise']=_0x303010['voiceExtension']['get'](_0x40a2f6[_0x311d03('0x2218')],_0xcd6569)[_0x311d03('0xa44')]:(_0x40a2f6[_0x311d03('0x2218')]['id']=_0x40a2f6[_0x311d03('0x7f')]['id'],_0x40a2f6[_0x311d03('0x2218')][_0x311d03('0xe60')]=_0x311d03('0x679'),_0x40a2f6[_0x311d03('0x1f48')]=_0x303010['userProfile'][_0x311d03('0x263a')](_0x40a2f6[_0x311d03('0x2218')],_0xcd6569)[_0x311d03('0xa44')]);}function _0x51a5ef(_0x47445f,_0x3f57d4){const _0x34f7db=_0x1ba616;_0x683008[_0x34f7db('0x1f80')]({'controller':_0x34f7db('0xed8'),'controllerAs':'vm','templateUrl':_0x2a60a0,'parent':angular[_0x34f7db('0x1194')](_0x430bf2[_0x34f7db('0x8d2')]),'targetEvent':_0x47445f,'clickOutsideToClose':!![],'locals':{'inboundroute':_0x3f57d4,'inboundroutes':_0x40a2f6[_0x34f7db('0xc30')]['rows'],'license':_0x40a2f6[_0x34f7db('0x5c9')],'setting':_0x40a2f6[_0x34f7db('0xf8a')],'crudPermissions':_0x40a2f6['crudPermissions']}});}function _0x1cc672(_0x33276c){const _0x364b93=_0x1ba616;_0x303010[_0x364b93('0x1deb')][_0x364b93('0x906')]({'id':_0x33276c['id']})['$promise']['then'](function(){const _0x40f9d5=_0x364b93;_0x2cfb05()[_0x40f9d5('0x127f')](_0x40a2f6[_0x40f9d5('0xc30')][_0x40f9d5('0x269a')],{'id':_0x33276c['id']}),_0x40a2f6[_0x40f9d5('0xc30')][_0x40f9d5('0x240f')]-=0x1,!_0x40a2f6[_0x40f9d5('0xc30')]['rows'][_0x40f9d5('0x264b')]&&_0x40a2f6[_0x40f9d5('0x584')](),_0x3175ce[_0x40f9d5('0x103b')]({'title':_0x2cfb05()[_0x40f9d5('0xb35')](_0x40f9d5('0x1db2'))+'\x20deleted!','msg':_0x33276c[_0x40f9d5('0x4f0')]?_0x33276c[_0x40f9d5('0x4f0')]+_0x40f9d5('0x7cd'):''});})[_0x364b93('0x1a80')](function(_0x11788c){const _0x1a4a12=_0x364b93;if(_0x11788c[_0x1a4a12('0x25f4')]&&_0x11788c['data'][_0x1a4a12('0x61a')]&&_0x11788c['data'][_0x1a4a12('0x61a')][_0x1a4a12('0x264b')]){_0x40a2f6[_0x1a4a12('0x61a')]=_0x11788c[_0x1a4a12('0x25f4')][_0x1a4a12('0x61a')]||[{'message':_0x11788c[_0x1a4a12('0x1586')](),'type':'SYSTEM:DELETEvoiceExtension'}];for(let _0x1b5540=0x0;_0x1b5540<_0x11788c['data'][_0x1a4a12('0x61a')][_0x1a4a12('0x264b')];_0x1b5540++){_0x3175ce['error']({'title':_0x11788c[_0x1a4a12('0x25f4')]['errors'][_0x1b5540][_0x1a4a12('0x1345')],'msg':_0x11788c[_0x1a4a12('0x25f4')][_0x1a4a12('0x61a')][_0x1b5540][_0x1a4a12('0x1e70')]});}}else _0x3175ce[_0x1a4a12('0xfc9')]({'title':_0x11788c[_0x1a4a12('0x52d')]?_0x1a4a12('0x1e21')+_0x11788c[_0x1a4a12('0x52d')]+_0x1a4a12('0x11e1')+_0x11788c[_0x1a4a12('0xe1b')]:'SYSTEM:DELETEvoiceExtension','msg':_0x11788c[_0x1a4a12('0x25f4')]?JSON['stringify'](_0x11788c[_0x1a4a12('0x25f4')][_0x1a4a12('0x1e70')]):_0x11788c['message']||_0x11788c[_0x1a4a12('0x1586')]()});});}function _0x3a1639(){const _0x13c01a=_0x1ba616,_0x17fd41=angular[_0x13c01a('0x225f')](_0x40a2f6[_0x13c01a('0x1ed9')]);return _0x40a2f6[_0x13c01a('0x1ed9')]=[],_0x17fd41;}function _0x97eb52(_0x457706){const _0x1d846c=_0x1ba616,_0x162d6c=_0x683008[_0x1d846c('0x1d26')]()[_0x1d846c('0xcdc')](_0x1d846c('0x23b'))[_0x1d846c('0xf3c')](_0x1d846c('0x12b5')+_0x40a2f6[_0x1d846c('0x1ed9')][_0x1d846c('0x264b')]+_0x1d846c('0x196d')+_0x1d846c('0x3f3'))['ariaLabel'](_0x1d846c('0x1664'))[_0x1d846c('0x203b')](_0x457706)['ok']('OK')[_0x1d846c('0x3f')](_0x1d846c('0x2d3'));_0x683008[_0x1d846c('0x1f80')](_0x162d6c)['then'](function(){const _0xb2fbeb=_0x1d846c;_0x40a2f6['selectedInboundRoutes']['forEach'](function(_0x5bed0d){_0x1cc672(_0x5bed0d);}),_0x40a2f6[_0xb2fbeb('0x1ed9')]=[];});}function _0x33adcc(){const _0x5d8b2a=_0x1ba616;_0x40a2f6[_0x5d8b2a('0x1ed9')]=[];}function _0x583572(){const _0x2ab949=_0x1ba616;_0x40a2f6[_0x2ab949('0x1ed9')]=_0x40a2f6[_0x2ab949('0xc30')][_0x2ab949('0x269a')];}}const _0x3bbf0e=_0xbfdefe;_0x1c0c62[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0x2456'),_0x36e6f4('0x12b4'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting','crudPermissions'];function _0x1c0c62(_0x2f4d0b,_0x5a7116,_0x2d7f77,_0x9caa34,_0x1ba4f3,_0x252791,_0x310f60,_0x456e07,_0x47eb76,_0x4ec91d,_0x30c2bc,_0x223414,_0x1903b2,_0x592d50){const _0x381335=_0x36e6f4,_0x25b74a=this;_0x25b74a[_0x381335('0x98')]=_0x30c2bc['getCurrentUser'](),_0x25b74a[_0x381335('0x61a')]=[],_0x25b74a[_0x381335('0xf8a')]=_0x1903b2,_0x25b74a[_0x381335('0x5c9')]=_0x223414,_0x25b74a['crudPermissions']=_0x592d50,_0x25b74a[_0x381335('0x128b')]={},_0x25b74a[_0x381335('0x2900')]=_0x25b74a[_0x381335('0xf8a')]&&_0x25b74a['setting'][_0x381335('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x25b74a['title']=_0x381335('0xd19'),_0x25b74a[_0x381335('0x12b4')]=angular[_0x381335('0x225f')](_0x47eb76),_0x25b74a[_0x381335('0x2456')]=_0x456e07,_0x25b74a[_0x381335('0x1d8f')]=![];!_0x25b74a[_0x381335('0x12b4')]&&(_0x25b74a[_0x381335('0x12b4')]={'appdata':_0x381335('0x1198'),'type':_0x381335('0x1eef'),'context':_0x381335('0xb31')},_0x25b74a[_0x381335('0xcdc')]=_0x381335('0xd5d'),_0x25b74a[_0x381335('0x1d8f')]=!![]);_0x25b74a[_0x381335('0x2487')]=_0x54d87e,_0x25b74a[_0x381335('0x269c')]=_0x4e6c24,_0x25b74a[_0x381335('0x1402')]=_0x2c3bd2,_0x25b74a[_0x381335('0x1a9c')]=_0x5349a3,_0x25b74a[_0x381335('0x24a0')]=_0x3512ca,_0x30c2bc[_0x381335('0x1ac6')](_0x381335('0xa7c'))?_0x4ec91d['voiceContext'][_0x381335('0xd83')]({'fields':_0x381335('0x1776'),'sort':_0x381335('0x4f0'),'nolimit':_0x381335('0xf3b')})[_0x381335('0xa44')]['then'](function(_0x8bf399){const _0x4c40c7=_0x381335;_0x25b74a['contexts']=_0x8bf399[_0x4c40c7('0x269a')]||[];})[_0x381335('0x1a80')](function(_0x42e5b6){const _0x5e3eb8=_0x381335;_0x310f60['error']({'title':_0x42e5b6['status']?_0x5e3eb8('0x1e21')+_0x42e5b6[_0x5e3eb8('0x52d')]+'\x20-\x20'+_0x42e5b6[_0x5e3eb8('0xe1b')]:_0x5e3eb8('0x140d'),'msg':_0x42e5b6['data']?JSON['stringify'](_0x42e5b6[_0x5e3eb8('0x25f4')]):_0x42e5b6[_0x5e3eb8('0x1586')]()});}):_0x4ec91d['voiceContext'][_0x381335('0xd83')]({'fields':_0x381335('0x1776'),'sort':'name','nolimit':_0x381335('0xf3b')})['$promise'][_0x381335('0x1166')](function(_0x57c0ae){const _0x1e7209=_0x381335;_0x25b74a[_0x1e7209('0x160a')]=_0x57c0ae[_0x1e7209('0x269a')]||[];})[_0x381335('0x1166')](function(){const _0x3615b2=_0x381335;return _0x4ec91d['userProfileSection']['get']({'userProfileId':_0x25b74a[_0x3615b2('0x98')]['userProfileId'],'sectionId':0x195})[_0x3615b2('0xa44')];})['then'](function(_0x33053a){const _0x3099ac=_0x381335,_0x353b4d=_0x33053a&&_0x33053a[_0x3099ac('0x269a')]?_0x33053a['rows'][0x0]:null;if(!_0x353b4d)return _0x4ec91d[_0x3099ac('0x23b1')][_0x3099ac('0xd83')]({'fields':_0x3099ac('0x1776'),'sort':_0x3099ac('0x4f0'),'nolimit':_0x3099ac('0xf3b'),'defaultEntry':0x1})[_0x3099ac('0xa44')][_0x3099ac('0x1166')](function(_0x2f8cb2){const _0x3d3f20=_0x3099ac;_0x25b74a[_0x3d3f20('0x160a')]=_0x2f8cb2[_0x3d3f20('0x269a')]||[];});else{if(!_0x353b4d[_0x3099ac('0x1a2b')])return _0x4ec91d[_0x3099ac('0x4b5')]['get']({'sectionId':_0x353b4d['id']})[_0x3099ac('0xa44')][_0x3099ac('0x1166')](function(_0x59d2d9){const _0x3432df=_0x3099ac,_0x53f8d8=_0x2cfb05()['map'](_0x59d2d9[_0x3432df('0x269a')],function(_0x4b2378){const _0x507809=_0x3432df;return _0x2cfb05()[_0x507809('0xc38')](_0x25b74a[_0x507809('0x160a')],{'id':_0x4b2378[_0x507809('0x24e8')]});});let _0x96417b=null;_0x25b74a[_0x3432df('0x12b4')]&&(_0x96417b=_0x2cfb05()[_0x3432df('0xc38')](_0x25b74a[_0x3432df('0x160a')],{'name':_0x25b74a[_0x3432df('0x12b4')][_0x3432df('0xe1c')]}));if(_0x96417b&&!_0x2cfb05()[_0x3432df('0x1798')](_0x53f8d8,['id',_0x96417b['id']])){const _0x95687c=_0x2cfb05()[_0x3432df('0xc38')](_0x25b74a[_0x3432df('0x160a')],{'id':_0x96417b['id']});_0x95687c[_0x3432df('0x2378')]=![],_0x53f8d8[_0x3432df('0x1514')](_0x95687c);}_0x25b74a['contexts']=_0x53f8d8;});}})[_0x381335('0x1a80')](function(_0x3ed997){const _0x5e22d8=_0x381335;_0x310f60['error']({'title':_0x3ed997[_0x5e22d8('0x52d')]?_0x5e22d8('0x1e21')+_0x3ed997[_0x5e22d8('0x52d')]+_0x5e22d8('0x11e1')+_0x3ed997[_0x5e22d8('0xe1b')]:_0x5e22d8('0x482'),'msg':_0x3ed997[_0x5e22d8('0x25f4')]?JSON[_0x5e22d8('0xbac')](_0x3ed997[_0x5e22d8('0x25f4')]):_0x3ed997[_0x5e22d8('0x1586')]()});});function _0x54d87e(){const _0xa0c3dd=_0x381335;_0x25b74a[_0xa0c3dd('0x61a')]=[],_0x4ec91d[_0xa0c3dd('0x1deb')][_0xa0c3dd('0x9cc')](_0x25b74a[_0xa0c3dd('0x12b4')])[_0xa0c3dd('0xa44')][_0xa0c3dd('0x1166')](function(_0x586333){const _0x461b1c=_0xa0c3dd;_0x25b74a['internalroutes'][_0x461b1c('0x2450')](_0x586333[_0x461b1c('0x2876')]()),_0x310f60[_0x461b1c('0x103b')]({'title':_0x461b1c('0x6c3'),'msg':_0x25b74a[_0x461b1c('0x12b4')][_0x461b1c('0x4f0')]?_0x25b74a['internalroute'][_0x461b1c('0x4f0')]+_0x461b1c('0x1eda'):''}),_0x3512ca(_0x586333);})['catch'](function(_0xf340e0){const _0x299321=_0xa0c3dd;if(_0xf340e0[_0x299321('0x25f4')]&&_0xf340e0[_0x299321('0x25f4')][_0x299321('0x61a')]&&_0xf340e0[_0x299321('0x25f4')][_0x299321('0x61a')][_0x299321('0x264b')]){_0x25b74a[_0x299321('0x61a')]=_0xf340e0['data'][_0x299321('0x61a')]||[{'message':_0xf340e0[_0x299321('0x1586')](),'type':_0x299321('0x1b99')}];for(let _0x3bea08=0x0;_0x3bea08<_0xf340e0[_0x299321('0x25f4')]['errors'][_0x299321('0x264b')];_0x3bea08+=0x1){_0x310f60[_0x299321('0xfc9')]({'title':_0xf340e0[_0x299321('0x25f4')][_0x299321('0x61a')][_0x3bea08][_0x299321('0x1345')],'msg':_0xf340e0[_0x299321('0x25f4')][_0x299321('0x61a')][_0x3bea08][_0x299321('0x1e70')]});}}else _0x310f60[_0x299321('0xfc9')]({'title':_0xf340e0[_0x299321('0x52d')]?_0x299321('0x1e21')+_0xf340e0[_0x299321('0x52d')]+_0x299321('0x11e1')+_0xf340e0[_0x299321('0xe1b')]:_0x299321('0x1b99'),'msg':_0xf340e0[_0x299321('0x25f4')]?JSON[_0x299321('0xbac')](_0xf340e0[_0x299321('0x25f4')][_0x299321('0x1e70')]):_0xf340e0[_0x299321('0x1586')]()});});}function _0x4e6c24(){const _0x219db9=_0x381335;_0x25b74a[_0x219db9('0x61a')]=[],_0x4ec91d[_0x219db9('0x1deb')][_0x219db9('0x1449')]({'id':_0x25b74a[_0x219db9('0x12b4')]['id']},_0x25b74a[_0x219db9('0x12b4')])[_0x219db9('0xa44')]['then'](function(_0x15ad83){const _0x142e94=_0x219db9,_0x50f719=_0x2cfb05()[_0x142e94('0xc38')](_0x25b74a[_0x142e94('0x2456')],{'id':_0x15ad83['id']});_0x50f719&&_0x2cfb05()[_0x142e94('0xcc3')](_0x50f719,_0x2cfb05()[_0x142e94('0x1a08')](_0x15ad83[_0x142e94('0x2876')](),_0x2cfb05()[_0x142e94('0x14a4')](_0x50f719))),_0x310f60[_0x142e94('0x103b')]({'title':_0x142e94('0x16df'),'msg':_0x25b74a[_0x142e94('0x12b4')][_0x142e94('0x4f0')]?_0x25b74a[_0x142e94('0x12b4')][_0x142e94('0x4f0')]+_0x142e94('0x7d'):''}),_0x3512ca(_0x15ad83);})[_0x219db9('0x1a80')](function(_0x1339ce){const _0x282396=_0x219db9;if(_0x1339ce[_0x282396('0x25f4')]&&_0x1339ce[_0x282396('0x25f4')][_0x282396('0x61a')]&&_0x1339ce['data'][_0x282396('0x61a')][_0x282396('0x264b')]){_0x25b74a[_0x282396('0x61a')]=_0x1339ce[_0x282396('0x25f4')]['errors']||[{'message':_0x1339ce[_0x282396('0x1586')](),'type':_0x282396('0x1caf')}];for(let _0x50cde5=0x0;_0x50cde5<_0x1339ce[_0x282396('0x25f4')][_0x282396('0x61a')]['length'];_0x50cde5++){_0x310f60['error']({'title':_0x1339ce[_0x282396('0x25f4')][_0x282396('0x61a')][_0x50cde5][_0x282396('0x1345')],'msg':_0x1339ce[_0x282396('0x25f4')][_0x282396('0x61a')][_0x50cde5][_0x282396('0x1e70')]});}}else _0x310f60[_0x282396('0xfc9')]({'title':_0x1339ce[_0x282396('0x52d')]?_0x282396('0x1e21')+_0x1339ce[_0x282396('0x52d')]+_0x282396('0x11e1')+_0x1339ce[_0x282396('0xe1b')]:_0x282396('0x1caf'),'msg':_0x1339ce[_0x282396('0x25f4')]?JSON[_0x282396('0xbac')](_0x1339ce[_0x282396('0x25f4')][_0x282396('0x1e70')]):_0x1339ce[_0x282396('0x1586')]()});});}function _0x2c3bd2(_0x51ebb2){const _0x17301d=_0x381335;_0x25b74a[_0x17301d('0x61a')]=[];const _0x4c4d6b=_0x9caa34[_0x17301d('0x1d26')]()[_0x17301d('0xcdc')](_0x17301d('0x7fb'))[_0x17301d('0xacc')](_0x17301d('0x1d16'))[_0x17301d('0x8e8')](_0x17301d('0x2313'))['ok'](_0x17301d('0x18'))[_0x17301d('0x3f')](_0x17301d('0x497'))[_0x17301d('0x203b')](_0x51ebb2);_0x9caa34[_0x17301d('0x1f80')](_0x4c4d6b)['then'](function(){const _0x3a3dcb=_0x17301d;_0x4ec91d[_0x3a3dcb('0x1deb')][_0x3a3dcb('0x906')]({'id':_0x25b74a[_0x3a3dcb('0x12b4')]['id']})[_0x3a3dcb('0xa44')]['then'](function(){const _0x443142=_0x3a3dcb;_0x2cfb05()['remove'](_0x25b74a[_0x443142('0x2456')],{'id':_0x25b74a[_0x443142('0x12b4')]['id']}),_0x310f60[_0x443142('0x103b')]({'title':_0x443142('0x27c2'),'msg':(_0x25b74a[_0x443142('0x12b4')][_0x443142('0x4f0')]||_0x443142('0x12b4'))+_0x443142('0x7cd')}),_0x3512ca(_0x25b74a[_0x443142('0x12b4')]);})[_0x3a3dcb('0x1a80')](function(_0x5ad4fe){const _0xa5dc0d=_0x3a3dcb;if(_0x5ad4fe[_0xa5dc0d('0x25f4')]&&_0x5ad4fe[_0xa5dc0d('0x25f4')][_0xa5dc0d('0x61a')]&&_0x5ad4fe[_0xa5dc0d('0x25f4')]['errors']['length']){_0x25b74a[_0xa5dc0d('0x61a')]=_0x5ad4fe['data'][_0xa5dc0d('0x61a')]||[{'message':_0x5ad4fe[_0xa5dc0d('0x1586')](),'type':_0xa5dc0d('0x187b')}];for(let _0x2a705d=0x0;_0x2a705d<_0x5ad4fe['data']['errors'][_0xa5dc0d('0x264b')];_0x2a705d++){_0x310f60[_0xa5dc0d('0xfc9')]({'title':_0x5ad4fe[_0xa5dc0d('0x25f4')][_0xa5dc0d('0x61a')][_0x2a705d][_0xa5dc0d('0x1345')],'msg':_0x5ad4fe[_0xa5dc0d('0x25f4')]['errors'][_0x2a705d]['message']});}}else _0x310f60[_0xa5dc0d('0xfc9')]({'title':_0x5ad4fe[_0xa5dc0d('0x52d')]?_0xa5dc0d('0x1e21')+_0x5ad4fe['status']+_0xa5dc0d('0x11e1')+_0x5ad4fe[_0xa5dc0d('0xe1b')]:_0xa5dc0d('0x187b'),'msg':_0x5ad4fe[_0xa5dc0d('0x25f4')]?JSON[_0xa5dc0d('0xbac')](_0x5ad4fe[_0xa5dc0d('0x25f4')][_0xa5dc0d('0x1e70')]):_0x5ad4fe[_0xa5dc0d('0x1e70')]||_0x5ad4fe[_0xa5dc0d('0x1586')]()});});},function(){});}function _0x5349a3(_0xf6a8c9){return _0xf6a8c9===null?undefined:new Date(_0xf6a8c9);}function _0x3512ca(_0x307ab6){const _0x1756bb=_0x381335;_0x9caa34[_0x1756bb('0x1197')](_0x307ab6);}}const _0x5f0d7e=_0x1c0c62,_0x17661d=_0x2734b2['p']+_0x36e6f4('0xe85'),_0x263d48=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/internalroutes/edit/apps/custom/dialog.html/dialog.html',_0x4ed5a2=_0x2734b2['p']+_0x36e6f4('0x1dc8'),_0x18c35c=_0x2734b2['p']+_0x36e6f4('0x1580'),_0xa4f661=_0x2734b2['p']+_0x36e6f4('0x5ae'),_0x4b9ffc=_0x2734b2['p']+_0x36e6f4('0x12e'),_0xd00006=_0x2734b2['p']+_0x36e6f4('0x48b'),_0x1dabc9=_0x2734b2['p']+_0x36e6f4('0x1811'),_0x5aaf4f=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/internalroutes/edit/apps/playback/dialog.html/dialog.html',_0x524da0=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/internalroutes/edit/apps/queue/dialog.html/dialog.html',_0x4c1fd9=_0x2734b2['p']+_0x36e6f4('0x33b'),_0x51a9bb=_0x2734b2['p']+_0x36e6f4('0x151'),_0xdf17f5=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/internalroutes/edit/apps/voicemail/dialog.html/dialog.html';_0x60e8da['$inject']=[_0x36e6f4('0x19e3'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x1d2e'),'Auth'];const _0x507ecf={'agi':_0x17661d,'custom':_0x263d48,'dial':_0x4ed5a2,'externaldial':_0x18c35c,'goto':_0xa4f661,'hangup':_0x4b9ffc,'internaldial':_0xd00006,'interval':_0x1dabc9,'playback':_0x5aaf4f,'queue':_0x524da0,'ringgroup':_0x4c1fd9,'set':_0x51a9bb,'voicemail':_0xdf17f5};function _0x60e8da(_0x2c208f,_0x3b220d,_0x3e78eb,_0x3899ac,_0x3b3ee6){const _0x3909eb=_0x36e6f4,_0x4c9d3f=this;_0x4c9d3f[_0x3909eb('0x98')]=_0x3b3ee6[_0x3909eb('0x26cd')](),_0x4c9d3f['internalroute']={},_0x4c9d3f['internalrouteApps']={'count':0x0,'rows':[]},_0x4c9d3f[_0x3909eb('0x2dd')]=[],_0x4c9d3f[_0x3909eb('0x243c')],_0x4c9d3f[_0x3909eb('0x2218')]={'sort':_0x3909eb('0xfde')},_0x4c9d3f['apps']=_0x2cfb05()[_0x3909eb('0x21bf')](_0x2cfb05()[_0x3909eb('0x1eba')]([{'app':'Interval','appType':'interval','type':_0x3909eb('0xb48'),'types':[_0x3909eb('0x597'),_0x3909eb('0x2853'),_0x3909eb('0x1480')],'fields':[],'isApp':![]},{'app':_0x3909eb('0x28ba'),'appType':_0x3909eb('0x1d3e'),'context':_0x3909eb('0xb31'),'type':_0x3909eb('0xb48'),'options':'xX','appdata':_0x3909eb('0xd0e'),'icon':_0x3909eb('0x283f'),'interval':_0x3909eb('0x16f'),'answer':!![],'isApp':!![],'extraApi':[{'name':_0x3909eb('0x137'),'field':{'name':_0x3909eb('0x960'),'key':_0x3909eb('0x28d5'),'prefix':_0x3909eb('0x158c')},'route':_0x3909eb('0x960'),'filters':{'fields':'id,name,save_name','sort':_0x3909eb('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3ef}},{'name':_0x3909eb('0x7a7'),'field':{'name':_0x3909eb('0x1d3e'),'key':'name'},'route':_0x3909eb('0x1943'),'filters':{'type':'inbound','fields':_0x3909eb('0x1c09'),'sort':_0x3909eb('0x4f0'),'nolimit':!![]},'permissions':{'section':0x191}}],'fields':[{'title':'Queue','name':_0x3909eb('0x1d3e'),'type':_0x3909eb('0x2550'),'values':'queues','value':_0x3909eb('0x24ad'),'option':_0x3909eb('0x24ad'),'required':!![],'param':0x0},{'title':_0x3909eb('0x20f3'),'name':_0x3909eb('0xd39'),'type':_0x3909eb('0x1640'),'param':0x1},{'title':'Url','name':_0x3909eb('0x308'),'type':_0x3909eb('0x1640'),'param':0x2},{'title':'Announce_Overrides','name':_0x3909eb('0x960'),'type':_0x3909eb('0x2550'),'values':_0x3909eb('0x137'),'value':_0x3909eb('0x223d'),'option':_0x3909eb('0x2316'),'defaultValues':[{'value':'\x27\x27','option':_0x3909eb('0x1280')}],'param':0x3},{'title':_0x3909eb('0x1861'),'name':_0x3909eb('0x651'),'type':'number','min':0x0,'param':0x4},{'title':_0x3909eb('0x271d'),'name':_0x3909eb('0x1034'),'type':_0x3909eb('0x1640'),'param':0x5},{'title':_0x3909eb('0x20d8'),'name':_0x3909eb('0x1c8'),'type':_0x3909eb('0x1640'),'param':0x6},{'title':_0x3909eb('0x193d'),'name':_0x3909eb('0x281c'),'type':_0x3909eb('0x1640'),'param':0x7},{'title':_0x3909eb('0x2643'),'name':'rule','type':_0x3909eb('0x1640'),'param':0x8},{'title':_0x3909eb('0x833'),'name':'position','type':_0x3909eb('0xc45'),'min':0x0,'param':0x9},{'title':_0x3909eb('0x33c'),'name':_0x3909eb('0x1de9'),'type':_0x3909eb('0x6f4'),'general':!![]}]},{'app':_0x3909eb('0x134'),'appType':'playback','context':_0x3909eb('0xb31'),'type':_0x3909eb('0xb48'),'icon':'icon-apps','interval':_0x3909eb('0x16f'),'answer':!![],'isApp':!![],'extraApi':[{'name':_0x3909eb('0x137'),'field':{'name':'appdata','key':'save_name','prefix':_0x3909eb('0x158c')},'route':_0x3909eb('0x960'),'filters':{'fields':_0x3909eb('0x296'),'sort':_0x3909eb('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3ef}}],'fields':[{'title':_0x3909eb('0x78e'),'name':'appdata','type':_0x3909eb('0x2550'),'values':_0x3909eb('0x137'),'value':_0x3909eb('0x2049'),'option':_0x3909eb('0x1dd9'),'required':!![],'param':0x0},{'title':'Options','name':_0x3909eb('0xd39'),'type':'text','param':0x1},{'title':_0x3909eb('0x33c'),'name':_0x3909eb('0x1de9'),'type':_0x3909eb('0x6f4'),'general':!![]}]},{'app':'Dial','appType':_0x3909eb('0xc77'),'context':'from-sip','type':'Internal','icon':_0x3909eb('0x283f'),'options':'xX','interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x3909eb('0x1a37'),'name':_0x3909eb('0x134d'),'type':'text','required':!![],'param':0x0},{'title':'Timeout','name':_0x3909eb('0x651'),'type':'number','min':0x0,'param':0x1},{'title':_0x3909eb('0x20f3'),'name':_0x3909eb('0xd39'),'type':_0x3909eb('0x1640'),'param':0x2},{'title':'Url','name':_0x3909eb('0xcac'),'type':'text','param':0x3}]},{'app':_0x3909eb('0x1d90'),'appType':_0x3909eb('0x11d9'),'context':_0x3909eb('0xb31'),'type':_0x3909eb('0xb48'),'icon':_0x3909eb('0x283f'),'options':'xX','interval':_0x3909eb('0x16f'),'isApp':!![],'extraApi':[{'name':_0x3909eb('0x21f6'),'field':{'name':'user','key':_0x3909eb('0x4f0'),'prefix':_0x3909eb('0x1b89')},'route':_0x3909eb('0x557'),'filters':{'fields':'id,name,role','sort':_0x3909eb('0x4f0'),'nolimit':!![]},'permissions':{'sections':[{'id':0xca,'role':'agent'},{'id':0xcb,'role':_0x3909eb('0x887')}]}}],'fields':[{'title':'User','name':_0x3909eb('0x557'),'type':_0x3909eb('0x2550'),'values':_0x3909eb('0x21f6'),'value':_0x3909eb('0x1665'),'option':'user.name','required':!![],'param':0x0},{'title':_0x3909eb('0x1861'),'name':_0x3909eb('0x651'),'type':'number','min':0x0,'param':0x1},{'title':_0x3909eb('0x20f3'),'name':_0x3909eb('0xd39'),'type':'text','param':0x2},{'title':_0x3909eb('0x11a2'),'name':_0x3909eb('0xcac'),'type':_0x3909eb('0x1640'),'param':0x3}]},{'app':_0x3909eb('0x1d90'),'appType':'externalDial','context':_0x3909eb('0xb31'),'type':_0x3909eb('0xb48'),'icon':_0x3909eb('0x283f'),'interval':'*,*,*,*','options':'xX','isApp':!![],'extraApi':[{'name':_0x3909eb('0xf24'),'field':{'name':'trunk','key':_0x3909eb('0x4f0')},'route':_0x3909eb('0x3b2'),'filters':{'fields':_0x3909eb('0x1776'),'sort':_0x3909eb('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f3}}],'fields':[{'title':_0x3909eb('0x14c4'),'name':'trunk','type':_0x3909eb('0x2550'),'values':'trunks','value':'trunk.name','option':_0x3909eb('0x912'),'required':!![],'param':0x0},{'title':'Phone','name':_0x3909eb('0x2026'),'type':_0x3909eb('0x1640')},{'title':_0x3909eb('0x1861'),'name':_0x3909eb('0x651'),'type':'number','min':0x0,'param':0x1},{'title':_0x3909eb('0x20f3'),'name':'options','type':_0x3909eb('0x1640'),'param':0x2},{'title':'Url','name':_0x3909eb('0xcac'),'type':_0x3909eb('0x1640'),'param':0x3}]},{'app':_0x3909eb('0x1d90'),'appType':'ringGroup','context':_0x3909eb('0xb31'),'type':_0x3909eb('0xb48'),'icon':'icon-apps','interval':_0x3909eb('0x16f'),'options':'xX','isApp':!![],'extraApi':[{'name':_0x3909eb('0x21f6'),'field':{'name':_0x3909eb('0x1855'),'key':_0x3909eb('0x4f0'),'prefix':_0x3909eb('0x1b89')},'route':_0x3909eb('0x557'),'filters':{'fields':'id,name,role','sort':_0x3909eb('0x4f0'),'nolimit':!![]},'permissions':{'sections':[{'id':0xca,'role':_0x3909eb('0x1eff')},{'id':0xcb,'role':_0x3909eb('0x887')}]}}],'fields':[{'title':_0x3909eb('0x1a6f'),'name':_0x3909eb('0x1855'),'type':_0x3909eb('0x2550'),'multiple':!![],'values':_0x3909eb('0x21f6'),'value':_0x3909eb('0x1fa6'),'option':'multipleUsers.name','required':!![],'param':0x0},{'title':_0x3909eb('0x1861'),'name':_0x3909eb('0x651'),'type':_0x3909eb('0xc45'),'min':0x0,'param':0x1},{'title':_0x3909eb('0x20f3'),'name':'options','type':_0x3909eb('0x1640'),'param':0x2},{'title':_0x3909eb('0x11a2'),'name':_0x3909eb('0xcac'),'type':_0x3909eb('0x1640'),'param':0x3}]},{'app':_0x3909eb('0x1465'),'alias':_0x3909eb('0x678'),'appType':_0x3909eb('0x1034'),'context':'from-sip','type':_0x3909eb('0xb48'),'icon':_0x3909eb('0x283f'),'interval':_0x3909eb('0x16f'),'isApp':!![],'extraApi':[{'name':_0x3909eb('0x149f'),'field':{'name':_0x3909eb('0x2588'),'key':_0x3909eb('0x4f0'),'prefix':_0x3909eb('0x139e')},'route':_0x3909eb('0x7e4'),'filters':{'fields':_0x3909eb('0x1776'),'sort':_0x3909eb('0x4f0'),'nolimit':!![]},'permissions':{'section':0x44f}}],'fields':[{'title':'Project','name':_0x3909eb('0x2588'),'type':'apiselect','values':_0x3909eb('0x149f'),'value':'\x27agi://127.0.0.1/square,{{project.name}}\x27','option':_0x3909eb('0x100d'),'required':!![],'param':0x0}]},{'app':_0x3909eb('0x1a03'),'appType':_0x3909eb('0x19b4'),'context':_0x3909eb('0xb31'),'type':_0x3909eb('0xb48'),'icon':_0x3909eb('0x283f'),'interval':_0x3909eb('0x16f'),'isApp':!![],'extraApi':[{'name':_0x3909eb('0x160a'),'field':{'name':_0x3909eb('0xe1c'),'key':_0x3909eb('0x4f0')},'route':'voiceContext','filters':{'fields':'id,name','sort':'name','nolimit':!![]},'permissions':{'section':0x195}}],'fields':[{'title':_0x3909eb('0x637'),'name':_0x3909eb('0xe1c'),'type':_0x3909eb('0x2550'),'values':_0x3909eb('0x160a'),'value':_0x3909eb('0x10f8'),'option':_0x3909eb('0x10f8'),'required':!![],'param':0x0},{'title':_0x3909eb('0x76'),'name':_0x3909eb('0x1ed1'),'type':_0x3909eb('0x1640'),'required':!![],'param':0x1},{'title':'Priority','name':'priority','type':_0x3909eb('0x1640'),'required':!![],'param':0x2}]},{'app':'hangup','appType':_0x3909eb('0x133d'),'context':_0x3909eb('0xb31'),'type':_0x3909eb('0xb48'),'icon':_0x3909eb('0x283f'),'interval':_0x3909eb('0x16f'),'isApp':!![],'fields':[{'title':_0x3909eb('0x21d3'),'name':_0x3909eb('0x823'),'type':_0x3909eb('0x88a'),'param':0x0,'values':[{'option':_0x3909eb('0x1080'),'value':'\x271\x27'},{'option':_0x3909eb('0xeb7'),'value':_0x3909eb('0x995')},{'option':_0x3909eb('0x1e63'),'value':_0x3909eb('0x1c48')},{'option':'HANGUPCAUSE_18','value':_0x3909eb('0x2697')},{'option':_0x3909eb('0x23f6'),'value':_0x3909eb('0x17e4')},{'option':'HANGUPCAUSE_22','value':_0x3909eb('0x1818')},{'option':_0x3909eb('0x19f7'),'value':_0x3909eb('0x1a4c')},{'option':_0x3909eb('0x1660'),'value':_0x3909eb('0x25cd')},{'option':_0x3909eb('0xd49'),'value':_0x3909eb('0x7cf')}],'translate':!![],'required':!![],'general':!![]}]},{'app':_0x3909eb('0x1816'),'appType':'set','context':'from-sip','type':_0x3909eb('0xb48'),'separator':'=','icon':'icon-apps','interval':_0x3909eb('0x16f'),'extraApi':[{'name':_0x3909eb('0x57a'),'field':{'name':_0x3909eb('0x4f0'),'key':_0x3909eb('0x4f0')},'route':_0x3909eb('0x734'),'filters':{'fields':_0x3909eb('0x1776'),'sort':_0x3909eb('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'isApp':!![],'fields':[{'title':_0x3909eb('0x2d5'),'name':'name','type':'apiselect','values':_0x3909eb('0x57a'),'value':_0x3909eb('0x1815'),'option':_0x3909eb('0x1815'),'required':!![],'param':0x0},{'title':_0x3909eb('0x1efa'),'name':'value','type':_0x3909eb('0x1640'),'required':!![],'param':0x1}]},{'app':null,'appType':_0x3909eb('0x2853'),'icon':'icon-apps','type':_0x3909eb('0xb48'),'interval':_0x3909eb('0x16f'),'isApp':!![],'fields':[{'title':_0x3909eb('0x7bc'),'name':'app','type':_0x3909eb('0x1640'),'required':!![],'param':0x0},{'title':_0x3909eb('0x81c'),'name':_0x3909eb('0x823'),'type':_0x3909eb('0x1640'),'param':0x1}]},{'app':'Voicemail','appType':_0x3909eb('0x1ee9'),'context':_0x3909eb('0xb31'),'icon':_0x3909eb('0x283f'),'type':_0x3909eb('0xb48'),'interval':_0x3909eb('0x16f'),'isApp':!![],'extraApi':[{'name':_0x3909eb('0x138'),'field':{'name':_0x3909eb('0x8d4'),'key':'mailbox','suffix':'@from-voicemail'},'route':_0x3909eb('0x8d4'),'filters':{'fields':'id,mailbox','sort':'mailbox','nolimit':!![]},'permissions':{'section':0x196}}],'fields':[{'title':_0x3909eb('0x265'),'name':_0x3909eb('0x8d4'),'type':_0x3909eb('0x2550'),'values':_0x3909eb('0x138'),'value':_0x3909eb('0x614'),'option':_0x3909eb('0x113d'),'required':!![],'param':0x0},{'title':_0x3909eb('0x20f3'),'name':_0x3909eb('0xd39'),'type':_0x3909eb('0x1640'),'param':0x1}]}],['app']),{'isApp':![]}),_0x4c9d3f[_0x3909eb('0x1480')]={'group':{'name':'opt1','pull':_0x3909eb('0xddc')},'animation':0x64,'sort':![]},_0x4c9d3f[_0x3909eb('0x227f')]={'group':{'name':_0x3909eb('0x103e'),'put':_0x3909eb('0x1b27')},'animation':0x64,'onAdd':function(_0x316a41){const _0x24a089=_0x3909eb;_0x1c6eb5(_0x316a41,_0x316a41[_0x24a089('0x1313')]);},'onSort':function(){_0x2e224c();}},_0x4c9d3f[_0x3909eb('0x24d5')]=_0x1dbe72,_0x4c9d3f['deleteConfirm']=_0x1d30ed,_0x4c9d3f[_0x3909eb('0x1b61')]=_0x3934c6,_0x4c9d3f[_0x3909eb('0xd35')]=_0x1c6eb5,_0x4c9d3f['editInterval']=_0x3d4a39,_0x4c9d3f['deleteInternalRouteApp']=_0x3382aa,_0x4c9d3f[_0x3909eb('0xc22')]=_0x487a63,_0x4c9d3f[_0x3909eb('0x20a6')]=_0x2e224c,_0x4c9d3f['getIntervals']=_0x513771;function _0x1dbe72(_0x52b96f,_0x41ad3b){const _0x7cc3af=_0x3909eb;_0x4c9d3f[_0x7cc3af('0x12b4')]=_0x52b96f,_0x4c9d3f[_0x7cc3af('0x243c')]=typeof _0x41ad3b!=='undefined'?_0x41ad3b:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4c9d3f[_0x7cc3af('0x227f')][_0x7cc3af('0xbd0')]=!_0x4c9d3f[_0x7cc3af('0x243c')][_0x7cc3af('0x1684')]?!![]:![],_0x4c9d3f[_0x7cc3af('0x2218')]['VoiceExtensionId']=_0x52b96f['id'],_0x4c9d3f['query']['isApp']=!![],_0x4c9d3f['query'][_0x7cc3af('0x49d')]=!![],_0x4c9d3f[_0x7cc3af('0x1b61')](),_0x4c9d3f[_0x7cc3af('0x242')]();}function _0x1d30ed(_0x186284,_0x426ec4,_0x2ae7dd){const _0x2d5781=_0x3909eb,_0x1c9a26=_0x3b220d[_0x2d5781('0x1d26')]()[_0x2d5781('0xcdc')](_0x2d5781('0xd0f'))[_0x2d5781('0xf3c')](_0x2d5781('0x12b5')+_0x186284[_0x2d5781('0x746')]+_0x2d5781('0xace')+_0x2d5781('0x3f3'))['ariaLabel'](_0x2d5781('0x238d'))[_0x2d5781('0x203b')](_0x2ae7dd)['ok']('OK')[_0x2d5781('0x3f')](_0x2d5781('0x2d3'));_0x3b220d[_0x2d5781('0x1f80')](_0x1c9a26)[_0x2d5781('0x1166')](function(){const _0x38e277=_0x2d5781;_0x4c9d3f[_0x38e277('0x2255')][_0x38e277('0x269a')]['splice'](_0x426ec4,0x1),_0x2e224c();},function(){console['log']('CANCEL');});}function _0x1c6eb5(_0x5bce60,_0x49f515){const _0x4cbfea=_0x3909eb;if(_0x4c9d3f[_0x4cbfea('0x2255')]['rows'][_0x4cbfea('0x264b')]){const _0x156d13=_0x4c9d3f[_0x4cbfea('0x2255')][_0x4cbfea('0x269a')][_0x49f515]?_0x4c9d3f[_0x4cbfea('0x2255')][_0x4cbfea('0x269a')][_0x49f515]:_0x4c9d3f[_0x4cbfea('0x2255')]['rows'][0x0],_0x99e97c=(_0x156d13['appType']||_0x156d13[_0x4cbfea('0x746')])[_0x4cbfea('0x2574')]();_0x3b220d[_0x4cbfea('0x1f80')]({'controller':_0x4cbfea('0xa69')+_0x99e97c+_0x4cbfea('0x8a4'),'controllerAs':'vm','templateUrl':_0x507ecf[_0x99e97c],'parent':angular[_0x4cbfea('0x1194')](_0x3e78eb[_0x4cbfea('0x8d2')]),'targetEvent':_0x5bce60,'clickOutsideToClose':!![],'locals':{'internalrouteApp':_0x156d13,'internalroute':_0x4c9d3f[_0x4cbfea('0x12b4')],'crudPermissions':_0x4c9d3f[_0x4cbfea('0x243c')]}})[_0x4cbfea('0x1166')](function(_0x31eca6){const _0x5f2abf=_0x4cbfea;_0x31eca6&&(_0x31eca6['id']?_0x4c9d3f['internalrouteApps'][_0x5f2abf('0x269a')][_0x49f515]=_0x31eca6:_0x4c9d3f[_0x5f2abf('0x2255')]['rows'][_0x5f2abf('0x57b')](_0x49f515,0x0,_0x31eca6),_0x2e224c());})['catch'](function(_0x40dcb9){const _0x3f4d2d=_0x4cbfea;_0x40dcb9&&_0x3899ac['error']({'title':_0x40dcb9[_0x3f4d2d('0x52d')]?_0x3f4d2d('0x1e21')+_0x40dcb9['status']+'\x20-\x20'+_0x40dcb9['statusText']:_0x3f4d2d('0x2e5'),'msg':_0x40dcb9['data']?JSON[_0x3f4d2d('0xbac')](_0x40dcb9['data']):_0x40dcb9['toString']()});});}}function _0x3d4a39(_0x47eb39,_0x20a834){const _0x398529=_0x3909eb;if(_0x4c9d3f[_0x398529('0x2255')][_0x398529('0x269a')][_0x398529('0x264b')]){const _0x2bf185=_0x4c9d3f[_0x398529('0x2255')][_0x398529('0x269a')][_0x20a834]?_0x4c9d3f[_0x398529('0x2255')][_0x398529('0x269a')][_0x20a834]:_0x4c9d3f[_0x398529('0x2255')][_0x398529('0x269a')][0x0];_0x3b220d[_0x398529('0x1f80')]({'controller':_0x398529('0x2298'),'controllerAs':'vm','templateUrl':_0x1dabc9,'parent':angular[_0x398529('0x1194')](_0x3e78eb[_0x398529('0x8d2')]),'targetEvent':_0x47eb39,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x2bf185[_0x398529('0x277c')],'IntervalId':_0x2bf185['IntervalId'],'application':!![]},'intervals':[],'crudPermissions':_0x4c9d3f[_0x398529('0x243c')]}})['then'](function(_0x31c33d){const _0x29154b=_0x398529;_0x31c33d&&(_0x2bf185[_0x29154b('0x277c')]=_0x31c33d[_0x29154b('0x277c')]||'*,*,*,*',_0x2bf185[_0x29154b('0x186f')]=_0x31c33d['IntervalId']||null,_0x2e224c());});}}function _0x2e224c(){const _0x47daed=_0x3909eb,_0x672b36=['queue',_0x47daed('0x19a0')];let _0x472b2d=0x2,_0x193165=[];_0x193165[_0x47daed('0x1514')]({'type':_0x47daed('0x1eef'),'app':_0x47daed('0x1816'),'appdata':_0x47daed('0x17fa'),'context':_0x4c9d3f[_0x47daed('0x12b4')]['context'],'exten':_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0x23ae')],'priority':_0x472b2d++,'VoiceExtensionId':_0x4c9d3f[_0x47daed('0x12b4')]['id']}),_0x193165['push']({'type':_0x47daed('0x1eef'),'app':_0x47daed('0x1816'),'appdata':_0x47daed('0x1d93'),'context':_0x4c9d3f[_0x47daed('0x12b4')]['context'],'exten':_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0x23ae')],'priority':_0x472b2d++,'VoiceExtensionId':_0x4c9d3f['internalroute']['id']}),_0x193165[_0x47daed('0x1514')]({'type':'internal','app':'Set','appdata':_0x47daed('0x2201'),'context':_0x4c9d3f['internalroute'][_0x47daed('0xe1c')],'exten':_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0x23ae')],'priority':_0x472b2d++,'VoiceExtensionId':_0x4c9d3f[_0x47daed('0x12b4')]['id']}),_0x193165[_0x47daed('0x1514')]({'type':_0x47daed('0x1eef'),'app':'Set','appdata':_0x47daed('0x28a5'),'context':_0x4c9d3f['internalroute'][_0x47daed('0xe1c')],'exten':_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0x23ae')],'priority':_0x472b2d++,'VoiceExtensionId':_0x4c9d3f['internalroute']['id']});for(let _0xfa3655=0x0,_0x53fdb0=0x0;_0xfa3655<_0x4c9d3f[_0x47daed('0x2255')][_0x47daed('0x269a')][_0x47daed('0x264b')];_0xfa3655++,_0x53fdb0=0x0){const _0xb3a9ba=_0x4c9d3f[_0x47daed('0x2255')][_0x47daed('0x269a')][_0xfa3655],_0x50240e=[],_0x2580ce=[];_0xb3a9ba[_0x47daed('0x164e')]=_0xb3a9ba['interval']!==_0x47daed('0x16f')?[_0xb3a9ba['interval']]:_0xb3a9ba[_0x47daed('0x186f')]?_0x2cfb05()['map'](_0x2cfb05()['filter'](_0x4c9d3f[_0x47daed('0x164e')]['rows'],{'IntervalId':_0xb3a9ba[_0x47daed('0x186f')]}),'interval'):[],_0xb3a9ba[_0x47daed('0xe1c')]=_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0xe1c')],_0xb3a9ba['exten']=_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0x23ae')];_0xb3a9ba['type']&&(_0xb3a9ba[_0x47daed('0x1345')]=_0xb3a9ba['type'][_0x47daed('0x2574')]());typeof _0xb3a9ba[_0x47daed('0x1de9')]!==_0x47daed('0x1048')&&(_0x672b36[_0x47daed('0x1257')](_0xb3a9ba[_0x47daed('0x746')][_0x47daed('0x2574')]())&&_0xb3a9ba[_0x47daed('0x83f')]!==_0x47daed('0x2853')&&(_0xb3a9ba[_0x47daed('0x1de9')]?(_0x50240e['push']({'type':_0xb3a9ba[_0x47daed('0x1345')][_0x47daed('0x2574')](),'app':'ExecIf','appdata':'$[${XCALLY-MOTION-ANSWER}=0]?Answer','context':_0x4c9d3f['internalroute'][_0x47daed('0xe1c')],'exten':_0x4c9d3f[_0x47daed('0x12b4')]['exten'],'priority':_0xb3a9ba[_0x47daed('0x164e')][_0x47daed('0x264b')]+_0x472b2d+_0x53fdb0++,'VoiceExtensionId':_0x4c9d3f['internalroute']['id']}),_0x50240e[_0x47daed('0x1514')]({'type':_0xb3a9ba[_0x47daed('0x1345')]['toLowerCase'](),'app':'Set','appdata':_0x47daed('0x115'),'context':_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0xe1c')],'exten':_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0x23ae')],'priority':_0xb3a9ba[_0x47daed('0x164e')]['length']+_0x472b2d+_0x53fdb0++,'VoiceExtensionId':_0x4c9d3f[_0x47daed('0x12b4')]['id']})):(_0x50240e[_0x47daed('0x1514')]({'type':_0xb3a9ba['type'][_0x47daed('0x2574')](),'app':'ExecIf','appdata':_0x47daed('0x7d5'),'context':_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0xe1c')],'exten':_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0x23ae')],'priority':_0xb3a9ba[_0x47daed('0x164e')]['length']+_0x472b2d+_0x53fdb0++,'VoiceExtensionId':_0x4c9d3f[_0x47daed('0x12b4')]['id']}),_0x50240e[_0x47daed('0x1514')]({'type':_0xb3a9ba[_0x47daed('0x1345')][_0x47daed('0x2574')](),'app':_0x47daed('0x1816'),'appdata':'XCALLY-MOTION-PROGRESS=1','context':_0x4c9d3f['internalroute'][_0x47daed('0xe1c')],'exten':_0x4c9d3f[_0x47daed('0x12b4')]['exten'],'priority':_0xb3a9ba['intervals'][_0x47daed('0x264b')]+_0x472b2d+_0x53fdb0++,'VoiceExtensionId':_0x4c9d3f[_0x47daed('0x12b4')]['id']}))));for(let _0x1ab844=0x0;_0x1ab844<_0xb3a9ba[_0x47daed('0x164e')][_0x47daed('0x264b')];_0x1ab844++){const _0x2b117f=_0x472b2d+_0xb3a9ba[_0x47daed('0x164e')][_0x47daed('0x264b')],_0x5e4708=_0x1ab844===_0xb3a9ba['intervals'][_0x47daed('0x264b')]-0x1?_0x472b2d+_0x50240e[_0x47daed('0x264b')]+_0x2580ce[_0x47daed('0x264b')]+0x2:_0x472b2d+_0x1ab844+0x1;_0x50240e[_0x47daed('0x57b')](_0x1ab844,0x0,{'type':_0x47daed('0x1eef'),'app':'GotoIfTime','appdata':_0xb3a9ba[_0x47daed('0x164e')][_0x1ab844]+'?'+_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0xe1c')]+',${EXTEN},'+_0x2b117f+':'+_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0xe1c')]+_0x47daed('0x883')+_0x5e4708,'exten':_0x4c9d3f['internalroute'][_0x47daed('0x23ae')],'context':_0x4c9d3f[_0x47daed('0x12b4')][_0x47daed('0xe1c')],'priority':_0x472b2d+_0x1ab844,'VoiceExtensionId':_0x4c9d3f[_0x47daed('0x12b4')]['id']});}_0xb3a9ba[_0x47daed('0xfde')]=_0x50240e['length']?_0x2cfb05()[_0x47daed('0x1ef5')](_0x50240e)[_0x47daed('0xfde')]+0x1:_0x472b2d,_0x472b2d=(_0x2580ce[_0x47daed('0x264b')]?_0x2cfb05()[_0x47daed('0x1ef5')](_0x2580ce)[_0x47daed('0xfde')]:_0xb3a9ba[_0x47daed('0xfde')])+0x1,_0x193165=_0x2cfb05()[_0x47daed('0x1c6a')](_0x193165,_0x50240e,[_0xb3a9ba],_0x2580ce);}_0x193165[_0x47daed('0x1514')]({'type':_0x47daed('0x1eef'),'app':'Hangup','exten':_0x4c9d3f[_0x47daed('0x12b4')]['exten'],'context':_0x4c9d3f[_0x47daed('0x12b4')]['context'],'priority':_0x472b2d,'VoiceExtensionId':_0x4c9d3f[_0x47daed('0x12b4')]['id']}),_0x2c208f['voiceExtension']['addApplications']({'id':_0x4c9d3f[_0x47daed('0x12b4')]['id']},_0x2cfb05()['sortBy'](_0x193165,_0x47daed('0xfde')))[_0x47daed('0xa44')][_0x47daed('0x1166')](function(_0x5cef07){const _0x5c524a=_0x47daed;_0x4c9d3f[_0x5c524a('0x2255')][_0x5c524a('0x269a')]=_0x5cef07[_0x5c524a('0x269a')];})[_0x47daed('0x1a80')](function(_0x39fb76){const _0x2e289f=_0x47daed;console[_0x2e289f('0xfc9')](_0x39fb76);});}function _0x452c10(_0x57fbaf){const _0x44f89a=_0x3909eb;_0x4c9d3f[_0x44f89a('0x2255')]=_0x57fbaf||{'count':0x0,'rows':[]};}function _0x513771(){const _0x561cd4=_0x3909eb;return _0x2c208f[_0x561cd4('0x277c')][_0x561cd4('0xd83')]({'fields':'id,interval,IntervalId'})['$promise']['then'](function(_0x38be4d){_0x4c9d3f['intervals']=_0x38be4d;})[_0x561cd4('0x1a80')](function(_0x2d917e){const _0x43f2ba=_0x561cd4;console[_0x43f2ba('0xfc9')](_0x2d917e);});}function _0x3934c6(){const _0x228081=_0x3909eb;_0x4c9d3f['promise']=_0x2c208f[_0x228081('0x1deb')][_0x228081('0xd83')](_0x4c9d3f['query'],_0x452c10)[_0x228081('0xa44')];}function _0x3382aa(_0x582244){const _0x1e939a=_0x3909eb;_0x2cfb05()[_0x1e939a('0x127f')](_0x4c9d3f['internalrouteApps'][_0x1e939a('0x269a')],{'id':_0x582244['id']}),_0x2e224c(),_0x3899ac[_0x1e939a('0x103b')]({'title':'App\x20deleted!','msg':_0x582244[_0x1e939a('0x746')]?_0x582244['app']+'\x20has\x20been\x20deleted!':''});}function _0x487a63(_0x4b420a){const _0x5bed26=_0x3909eb,_0x297a63=_0x3b220d[_0x5bed26('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20applications?')[_0x5bed26('0xf3c')](''+_0x4c9d3f[_0x5bed26('0x2dd')][_0x5bed26('0x264b')]+'\x20selected'+_0x5bed26('0x3f3'))[_0x5bed26('0x8e8')]('delete\x20applications')[_0x5bed26('0x203b')](_0x4b420a)['ok']('OK')['cancel'](_0x5bed26('0x2d3'));_0x3b220d[_0x5bed26('0x1f80')](_0x297a63)['then'](function(){const _0x5d950f=_0x5bed26;_0x4c9d3f[_0x5d950f('0x2dd')][_0x5d950f('0x2782')](function(_0x5ae08a){const _0x41285e=_0x5d950f;_0x2cfb05()[_0x41285e('0x127f')](_0x4c9d3f[_0x41285e('0x2255')]['rows'],{'id':_0x5ae08a['id']});}),_0x4c9d3f[_0x5d950f('0x2dd')]=[],_0x2e224c();});}}const _0x2d076c=_0x60e8da;_0x29f408[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x96'),'internalroute',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x29f408(_0x4cb384,_0x51a72d,_0xcdf1f,_0xb203a6,_0x3162da,_0x386f50,_0x1cbc64,_0x57aeeb){const _0x30c5d4=_0x36e6f4,_0xc88711=this;_0xc88711[_0x30c5d4('0x98')]=_0x1cbc64[_0x30c5d4('0x26cd')](),_0xc88711[_0x30c5d4('0x61a')]=[],_0xc88711[_0x30c5d4('0xcdc')]=_0x30c5d4('0xd79')+(_0xb203a6[_0x30c5d4('0x83f')]||_0xb203a6[_0x30c5d4('0x746')])[_0x30c5d4('0x1387')](),_0xc88711[_0x30c5d4('0x1034')]=angular[_0x30c5d4('0x225f')](_0xb203a6),_0xc88711[_0x30c5d4('0x243c')]=_0x57aeeb,_0xc88711[_0x30c5d4('0x128b')]={};if(_0xc88711[_0x30c5d4('0x1034')]['appdata'])switch(_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x83f')]?_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x83f')][_0x30c5d4('0x2574')]():_0xc88711['agi'][_0x30c5d4('0x746')][_0x30c5d4('0x2574')]()){case _0x30c5d4('0x2853'):break;case'dialogflow':{const _0x1da217=_0xc88711['agi'][_0x30c5d4('0x823')][_0x30c5d4('0x25c8')](',');_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x7ca')]=_0x1da217[0x0],_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0xedb')]=_0x1da217[0x1],_0xc88711['agi'][_0x30c5d4('0x1634')]=_0x1da217['slice'](0x2,_0x1da217[_0x30c5d4('0x264b')])['join'](',');}break;case _0x30c5d4('0x1636'):{const _0x2a9aad=_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x823')][_0x30c5d4('0x25c8')](',');_0xc88711[_0x30c5d4('0x1034')]['projectId']=_0x2a9aad[0x0],_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x27f3')]=_0x2a9aad[0x1],_0xc88711['agi']['privateKey']=_0x2a9aad[0x2],_0xc88711['agi'][_0x30c5d4('0xedb')]=_0x2a9aad[0x3],_0xc88711['agi'][_0x30c5d4('0x1634')]=_0x2a9aad[_0x30c5d4('0x233')](0x4,_0x2a9aad[_0x30c5d4('0x264b')])[_0x30c5d4('0x45a')](',');}break;case _0x30c5d4('0x86c'):{const _0x10a446=_0xc88711['agi'][_0x30c5d4('0x823')][_0x30c5d4('0x25c8')](',');_0xc88711['agi'][_0x30c5d4('0xee6')]=_0x10a446[0x0],_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x125')]=_0x10a446[0x1],_0xc88711['agi'][_0x30c5d4('0x25a2')]=_0x10a446[0x2],_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x1ac4')]=_0x10a446[0x3],_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x1634')]=_0x10a446[_0x30c5d4('0x233')](0x4,_0x10a446[_0x30c5d4('0x264b')])[_0x30c5d4('0x45a')](',');}break;case _0x30c5d4('0x1af7'):{const _0x426888=_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x823')][_0x30c5d4('0x25c8')](',');_0xc88711['agi'][_0x30c5d4('0x265e')]=isNaN(_0x426888[0x0])?_0x426888[0x0]:parseInt(_0x426888[0x0],0xa),_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x1640')]=_0x426888['slice'](0x1,_0x426888[_0x30c5d4('0x264b')])[_0x30c5d4('0x45a')](',');}break;case _0x30c5d4('0x1e70'):_0xc88711['agi'][_0x30c5d4('0x1640')]=_0xc88711[_0x30c5d4('0x1034')]['appdata'];break;case'set':_0xc88711['agi'][_0x30c5d4('0x4f0')]=_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x823')][_0x30c5d4('0x25c8')]('=')[0x0],_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x18e0')]=_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x823')][_0x30c5d4('0x25c8')]('=')[0x1];break;case'agi':_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x2588')]=_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x823')];break;default:{const _0x33b403=_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x823')][_0x30c5d4('0x25c8')](',');_0xc88711['agi'][_0x30c5d4('0x2588')]=_0x2cfb05()[_0x30c5d4('0x1081')](_0x33b403[0x0])?_0x33b403[0x0]:isNaN(_0x33b403[0x0])?_0x33b403[0x0]:parseInt(_0x33b403[0x0],0xa);}break;}else{}_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x1345')]&&_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x1345')][_0x30c5d4('0x2574')]()===_0x30c5d4('0x587')&&_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x83f')][_0x30c5d4('0x2574')]()===_0x30c5d4('0x2884')&&(_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x265a')]=_0xc88711['agi'][_0x30c5d4('0x2026')]?_0xc88711['agi'][_0x30c5d4('0x2026')][_0x30c5d4('0x25c8')]('$')[0x0]:undefined,_0xc88711['agi'][_0x30c5d4('0x1f02')]=_0xc88711[_0x30c5d4('0x1034')][_0x30c5d4('0x992')]?'CALLERID(all)='+_0xc88711['agi'][_0x30c5d4('0x992')]:undefined);_0xc88711[_0x30c5d4('0x2aa')]=_0x186d75,_0xc88711[_0x30c5d4('0x24a0')]=_0x5db61e,_0x1cbc64[_0x30c5d4('0x1ac6')]('admin')?_0x386f50[_0x30c5d4('0x7e4')][_0x30c5d4('0xd83')]({'fields':'id,name','sort':_0x30c5d4('0x4f0'),'nolimit':_0x30c5d4('0xf3b')})[_0x30c5d4('0xa44')][_0x30c5d4('0x1166')](function(_0x406625){const _0x522563=_0x30c5d4;_0xc88711[_0x522563('0x149f')]=_0x406625[_0x522563('0x269a')]||[];})[_0x30c5d4('0x1a80')](function(_0x506282){const _0x28b733=_0x30c5d4;_0xcdf1f[_0x28b733('0xfc9')]({'title':_0x506282[_0x28b733('0x52d')]?'API:'+_0x506282[_0x28b733('0x52d')]+_0x28b733('0x11e1')+_0x506282[_0x28b733('0xe1b')]:'SYSTEM:GET_PROJECTS','msg':_0x506282[_0x28b733('0x25f4')]?JSON[_0x28b733('0xbac')](_0x506282['data']):_0x506282['toString']()});}):_0x386f50[_0x30c5d4('0x7e4')][_0x30c5d4('0xd83')]({'fields':_0x30c5d4('0x1776'),'sort':_0x30c5d4('0x4f0'),'nolimit':_0x30c5d4('0xf3b')})['$promise']['then'](function(_0x228584){const _0x50a6a7=_0x30c5d4;_0xc88711[_0x50a6a7('0x149f')]=_0x228584[_0x50a6a7('0x269a')]||[];})[_0x30c5d4('0x1166')](function(){const _0x258953=_0x30c5d4;return _0x386f50[_0x258953('0x17aa')][_0x258953('0xd83')]({'userProfileId':_0xc88711[_0x258953('0x98')][_0x258953('0xb86')],'sectionId':0x44f})[_0x258953('0xa44')];})['then'](function(_0x54f250){const _0x56b016=_0x30c5d4,_0x17c39b=_0x54f250&&_0x54f250[_0x56b016('0x269a')]?_0x54f250[_0x56b016('0x269a')][0x0]:null;if(!_0x17c39b){const _0x50c35c=[];let _0x18da05=null;_0xc88711[_0x56b016('0x1034')]&&(_0x18da05=_0x2cfb05()[_0x56b016('0xc38')](_0xc88711[_0x56b016('0x149f')],{'name':_0xc88711[_0x56b016('0x1034')]['project']}));for(let _0x54fb43=0x0;_0x54fb43<_0xc88711[_0x56b016('0x149f')]['length'];_0x54fb43++){_0x18da05&&_0xc88711['projects'][_0x54fb43]['id']===_0x18da05['id']&&(_0xc88711[_0x56b016('0x149f')][_0x54fb43][_0x56b016('0x2378')]=![],_0x50c35c[_0x56b016('0x1514')](_0xc88711['projects'][_0x54fb43]));}_0xc88711['projects']=_0x50c35c;}else{if(!_0x17c39b[_0x56b016('0x1a2b')])return _0x386f50[_0x56b016('0x4b5')][_0x56b016('0xd83')]({'sectionId':_0x17c39b['id']})[_0x56b016('0xa44')][_0x56b016('0x1166')](function(_0xa82ac7){const _0x44a477=_0x56b016,_0x337401=_0x2cfb05()[_0x44a477('0x2563')](_0xa82ac7[_0x44a477('0x269a')],function(_0x4466da){const _0x1b9c49=_0x44a477;return _0x2cfb05()[_0x1b9c49('0xc38')](_0xc88711[_0x1b9c49('0x149f')],{'id':_0x4466da['resourceId']});});let _0x3fe2ef=null;_0xc88711['agi']&&(_0x3fe2ef=_0x2cfb05()[_0x44a477('0xc38')](_0xc88711[_0x44a477('0x149f')],{'name':_0xc88711[_0x44a477('0x1034')][_0x44a477('0x2588')]}));if(_0x3fe2ef&&!_0x2cfb05()[_0x44a477('0x1798')](_0x337401,['id',_0x3fe2ef['id']])){const _0x2611b3=_0x2cfb05()[_0x44a477('0xc38')](_0xc88711[_0x44a477('0x149f')],{'id':_0x3fe2ef['id']});_0x2611b3[_0x44a477('0x2378')]=![],_0x337401[_0x44a477('0x1514')](_0x2611b3);}_0xc88711[_0x44a477('0x149f')]=_0x337401;});}})['catch'](function(_0xe3dbfc){const _0x28e89b=_0x30c5d4;_0xcdf1f[_0x28e89b('0xfc9')]({'title':_0xe3dbfc[_0x28e89b('0x52d')]?_0x28e89b('0x1e21')+_0xe3dbfc[_0x28e89b('0x52d')]+'\x20-\x20'+_0xe3dbfc[_0x28e89b('0xe1b')]:_0x28e89b('0x10f2'),'msg':_0xe3dbfc[_0x28e89b('0x25f4')]?JSON['stringify'](_0xe3dbfc['data']):_0xe3dbfc['toString']()});});function _0x186d75(){const _0x369386=_0x30c5d4;_0xc88711[_0x369386('0x61a')]=[];const _0x10b578=[];_0xc88711[_0x369386('0x1034')][_0x369386('0x1345')]&&_0xc88711[_0x369386('0x1034')]['type'][_0x369386('0x2574')]()==='outbound'&&_0xc88711[_0x369386('0x1034')][_0x369386('0x83f')]===_0x369386('0x867')&&(_0xc88711[_0x369386('0x1034')][_0x369386('0x2026')]=_0x3162da[_0x369386('0x2848')]?(_0xc88711[_0x369386('0x1034')]['prefix']||'')+_0x369386('0x881')+_0x3162da['cutdigits']+'}':(_0xc88711[_0x369386('0x1034')][_0x369386('0x265a')]||'')+_0x369386('0x1d1'),_0x3162da[_0x369386('0x28cb')]!==_0x369386('0x192')?_0xc88711[_0x369386('0x1034')][_0x369386('0xd39')][_0x369386('0x2379')](_0x369386('0x1059'))<0x0&&(_0xc88711[_0x369386('0x1034')][_0x369386('0xd39')]+=_0x369386('0x1059')):_0xc88711[_0x369386('0x1034')][_0x369386('0xd39')]=_0xc88711[_0x369386('0x1034')][_0x369386('0xd39')][_0x369386('0xf3')](_0x369386('0x1059'),''));if(_0xc88711[_0x369386('0x1034')][_0x369386('0x83f')]&&_0xc88711[_0x369386('0x1034')][_0x369386('0x83f')]==='custom'){}else switch((_0xc88711[_0x369386('0x1034')][_0x369386('0x746')]||_0xc88711[_0x369386('0x1034')][_0x369386('0x83f')])[_0x369386('0x2574')]()){case _0x369386('0xceb'):_0xc88711[_0x369386('0x1034')][_0x369386('0x823')]=_0xc88711[_0x369386('0x1034')][_0x369386('0x4f0')]+'='+_0xc88711[_0x369386('0x1034')]['value'];break;case _0x369386('0x2853'):break;default:_0x10b578[0x0]=_0xc88711[_0x369386('0x1034')]['project'],_0xc88711[_0x369386('0x1034')][_0x369386('0x823')]=_0x10b578[_0x369386('0x45a')](',');}_0x5db61e(_0xc88711[_0x369386('0x1034')]);}function _0x5db61e(_0x4cf0fe){const _0x3d0161=_0x30c5d4;_0x4cb384[_0x3d0161('0x1197')](_0x4cf0fe);}}const _0x1ffaf9=_0x29f408;_0x22d0d7[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x96'),_0x36e6f4('0x12b4'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x22d0d7(_0x146ec1,_0x378a34,_0x5c60ab,_0x3e34ee,_0x5484d8,_0x57bdec,_0x4f6606,_0x59550e){const _0x46ebef=_0x36e6f4,_0x3af686=this;_0x3af686[_0x46ebef('0x98')]=_0x4f6606[_0x46ebef('0x26cd')](),_0x3af686[_0x46ebef('0x61a')]=[],_0x3af686[_0x46ebef('0xcdc')]='VOICE.EDIT_'+(_0x3e34ee[_0x46ebef('0x83f')]||_0x3e34ee[_0x46ebef('0x746')])[_0x46ebef('0x1387')](),_0x3af686[_0x46ebef('0x2853')]=angular[_0x46ebef('0x225f')](_0x3e34ee),_0x3af686[_0x46ebef('0x243c')]=_0x59550e,_0x3af686[_0x46ebef('0x128b')]={};if(_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x823')])switch(_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x83f')]?_0x3af686['custom'][_0x46ebef('0x83f')][_0x46ebef('0x2574')]():_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x746')][_0x46ebef('0x2574')]()){case _0x46ebef('0x2853'):break;case'dialogflow':{const _0x62f45e=_0x3af686['custom'][_0x46ebef('0x823')][_0x46ebef('0x25c8')](',');_0x3af686['custom'][_0x46ebef('0x7ca')]=_0x62f45e[0x0],_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0xedb')]=_0x62f45e[0x1],_0x3af686['custom']['welcomemessage']=_0x62f45e[_0x46ebef('0x233')](0x2,_0x62f45e[_0x46ebef('0x264b')])[_0x46ebef('0x45a')](',');}break;case _0x46ebef('0x1636'):{const _0x40d92b=_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x823')]['split'](',');_0x3af686[_0x46ebef('0x2853')]['projectId']=_0x40d92b[0x0],_0x3af686['custom']['clientEmail']=_0x40d92b[0x1],_0x3af686[_0x46ebef('0x2853')]['privateKey']=_0x40d92b[0x2],_0x3af686['custom'][_0x46ebef('0xedb')]=_0x40d92b[0x3],_0x3af686['custom']['welcomemessage']=_0x40d92b['slice'](0x4,_0x40d92b['length'])['join'](',');}break;case _0x46ebef('0x86c'):{const _0x30188a=_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x823')]['split'](',');_0x3af686[_0x46ebef('0x2853')]['accesskeyid']=_0x30188a[0x0],_0x3af686[_0x46ebef('0x2853')]['secretaccesskey']=_0x30188a[0x1],_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x25a2')]=_0x30188a[0x2],_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x1ac4')]=_0x30188a[0x3],_0x3af686['custom'][_0x46ebef('0x1634')]=_0x30188a[_0x46ebef('0x233')](0x4,_0x30188a[_0x46ebef('0x264b')])[_0x46ebef('0x45a')](',');}break;case _0x46ebef('0x1af7'):{const _0x30afd2=_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x823')][_0x46ebef('0x25c8')](',');_0x3af686[_0x46ebef('0x2853')]['times']=isNaN(_0x30afd2[0x0])?_0x30afd2[0x0]:parseInt(_0x30afd2[0x0],0xa),_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x1640')]=_0x30afd2['slice'](0x1,_0x30afd2[_0x46ebef('0x264b')])[_0x46ebef('0x45a')](',');}break;case'message':_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x1640')]=_0x3af686['custom']['appdata'];break;case'set':_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x4f0')]=_0x3af686[_0x46ebef('0x2853')]['appdata'][_0x46ebef('0x25c8')]('=')[0x0],_0x3af686[_0x46ebef('0x2853')]['value']=_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x823')][_0x46ebef('0x25c8')]('=')[0x1];break;case _0x46ebef('0x1034'):_0x3af686[_0x46ebef('0x2853')]['project']=_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x823')];break;default:{const _0x6ad4ff=_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x823')][_0x46ebef('0x25c8')](',');_0x3af686['custom'][_0x46ebef('0x746')]=_0x2cfb05()[_0x46ebef('0x1081')](_0x6ad4ff[0x0])?_0x6ad4ff[0x0]:isNaN(_0x6ad4ff[0x0])?_0x6ad4ff[0x0]:parseInt(_0x6ad4ff[0x0],0xa),_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x823')]=_0x2cfb05()['isEmpty'](_0x6ad4ff[0x1])?_0x6ad4ff[0x1]:isNaN(_0x6ad4ff[0x1])?_0x6ad4ff[0x1]:parseInt(_0x6ad4ff[0x1],0xa);}break;}else{}_0x3af686[_0x46ebef('0x2853')]['type']&&_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x1345')][_0x46ebef('0x2574')]()===_0x46ebef('0x587')&&_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x83f')][_0x46ebef('0x2574')]()===_0x46ebef('0x2884')&&(_0x3af686['custom'][_0x46ebef('0x265a')]=_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x2026')]?_0x3af686['custom'][_0x46ebef('0x2026')][_0x46ebef('0x25c8')]('$')[0x0]:undefined,_0x3af686['custom']['callerId']=_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x992')]?'CALLERID(all)='+_0x3af686[_0x46ebef('0x2853')][_0x46ebef('0x992')]:undefined);_0x3af686[_0x46ebef('0x2aa')]=_0x21537f,_0x3af686[_0x46ebef('0x24a0')]=_0x239604;function _0x21537f(){const _0x58e88c=_0x46ebef;_0x3af686[_0x58e88c('0x61a')]=[];const _0x192ac1=[];_0x3af686['custom'][_0x58e88c('0x1345')]&&_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x1345')]['toLowerCase']()===_0x58e88c('0x587')&&_0x3af686['custom'][_0x58e88c('0x83f')]===_0x58e88c('0x867')&&(_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x2026')]=_0x5484d8['cutdigits']?(_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x265a')]||'')+_0x58e88c('0x881')+_0x5484d8[_0x58e88c('0x2848')]+'}':(_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x265a')]||'')+'${EXTEN}',_0x5484d8[_0x58e88c('0x28cb')]!==_0x58e88c('0x192')?_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0xd39')][_0x58e88c('0x2379')](_0x58e88c('0x1059'))<0x0&&(_0x3af686['custom']['options']+='U(xcally-mixmonitor-context)'):_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0xd39')]=_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0xd39')]['replace'](_0x58e88c('0x1059'),''));if(_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x83f')]&&_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x83f')]===_0x58e88c('0x2853')){}else switch((_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x746')]||_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x83f')])['toLowerCase']()){case'set':_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x823')]=_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x4f0')]+'='+_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x18e0')];break;case _0x58e88c('0x2853'):break;default:_0x192ac1[0x0]=_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x746')],_0x192ac1[0x1]=_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x823')],_0x3af686[_0x58e88c('0x2853')][_0x58e88c('0x823')]=_0x192ac1['join'](',');}_0x239604(_0x3af686[_0x58e88c('0x2853')]);}function _0x239604(_0x231a74){const _0x1fa764=_0x46ebef;_0x146ec1[_0x1fa764('0x1197')](_0x231a74);}}const _0x1b78b1=_0x22d0d7;_0x209b42[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),'internalrouteApp',_0x36e6f4('0x12b4'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x209b42(_0x2d2ce4,_0x419a23,_0x3582d8,_0x3a9da6,_0x2084b7,_0x210417,_0x418394,_0x4451d1){const _0x8c5fa3=_0x36e6f4,_0x32e1e7=this;_0x32e1e7[_0x8c5fa3('0x98')]=_0x418394[_0x8c5fa3('0x26cd')](),_0x32e1e7[_0x8c5fa3('0x61a')]=[],_0x32e1e7['title']=_0x8c5fa3('0xd79')+(_0x3a9da6[_0x8c5fa3('0x83f')]||_0x3a9da6['app'])[_0x8c5fa3('0x1387')](),_0x32e1e7[_0x8c5fa3('0xc77')]=angular['copy'](_0x3a9da6),_0x32e1e7[_0x8c5fa3('0x243c')]=_0x4451d1,_0x32e1e7[_0x8c5fa3('0x128b')]={};if(_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x823')])switch(_0x32e1e7['dial'][_0x8c5fa3('0x83f')]?_0x32e1e7['dial'][_0x8c5fa3('0x83f')][_0x8c5fa3('0x2574')]():_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x746')][_0x8c5fa3('0x2574')]()){case _0x8c5fa3('0x2853'):break;case _0x8c5fa3('0xded'):{const _0x47b79c=_0x32e1e7['dial'][_0x8c5fa3('0x823')]['split'](',');_0x32e1e7['dial'][_0x8c5fa3('0x7ca')]=_0x47b79c[0x0],_0x32e1e7[_0x8c5fa3('0xc77')]['language']=_0x47b79c[0x1],_0x32e1e7['dial']['welcomemessage']=_0x47b79c['slice'](0x2,_0x47b79c[_0x8c5fa3('0x264b')])[_0x8c5fa3('0x45a')](',');}break;case _0x8c5fa3('0x1636'):{const _0x3af5ef=_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x823')][_0x8c5fa3('0x25c8')](',');_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x1b0a')]=_0x3af5ef[0x0],_0x32e1e7['dial'][_0x8c5fa3('0x27f3')]=_0x3af5ef[0x1],_0x32e1e7[_0x8c5fa3('0xc77')]['privateKey']=_0x3af5ef[0x2],_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0xedb')]=_0x3af5ef[0x3],_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x1634')]=_0x3af5ef[_0x8c5fa3('0x233')](0x4,_0x3af5ef['length'])[_0x8c5fa3('0x45a')](',');}break;case _0x8c5fa3('0x86c'):{const _0x3b962b=_0x32e1e7['dial']['appdata'][_0x8c5fa3('0x25c8')](',');_0x32e1e7['dial'][_0x8c5fa3('0xee6')]=_0x3b962b[0x0],_0x32e1e7['dial'][_0x8c5fa3('0x125')]=_0x3b962b[0x1],_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x25a2')]=_0x3b962b[0x2],_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x1ac4')]=_0x3b962b[0x3],_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x1634')]=_0x3b962b['slice'](0x4,_0x3b962b['length'])[_0x8c5fa3('0x45a')](',');}break;case _0x8c5fa3('0x1af7'):{const _0x3111a0=_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x823')][_0x8c5fa3('0x25c8')](',');_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x265e')]=isNaN(_0x3111a0[0x0])?_0x3111a0[0x0]:parseInt(_0x3111a0[0x0],0xa),_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x1640')]=_0x3111a0[_0x8c5fa3('0x233')](0x1,_0x3111a0[_0x8c5fa3('0x264b')])[_0x8c5fa3('0x45a')](',');}break;case _0x8c5fa3('0x1e70'):_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x1640')]=_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x823')];break;case _0x8c5fa3('0xceb'):_0x32e1e7['dial'][_0x8c5fa3('0x4f0')]=_0x32e1e7['dial'][_0x8c5fa3('0x823')][_0x8c5fa3('0x25c8')]('=')[0x0],_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x18e0')]=_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x823')]['split']('=')[0x1];break;case _0x8c5fa3('0x1034'):_0x32e1e7['dial']['project']=_0x32e1e7['dial']['appdata'];break;default:{const _0x4a35e0=_0x32e1e7[_0x8c5fa3('0xc77')]['appdata']['split'](',');_0x32e1e7[_0x8c5fa3('0xc77')]['tech']=_0x2cfb05()[_0x8c5fa3('0x1081')](_0x4a35e0[0x0])?_0x4a35e0[0x0]:isNaN(_0x4a35e0[0x0])?_0x4a35e0[0x0]:parseInt(_0x4a35e0[0x0],0xa),_0x32e1e7['dial'][_0x8c5fa3('0x651')]=_0x2cfb05()['isEmpty'](_0x4a35e0[0x1])?_0x4a35e0[0x1]:isNaN(_0x4a35e0[0x1])?_0x4a35e0[0x1]:parseInt(_0x4a35e0[0x1],0xa),_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0xd39')]=_0x2cfb05()[_0x8c5fa3('0x1081')](_0x4a35e0[0x2])?_0x4a35e0[0x2]:isNaN(_0x4a35e0[0x2])?_0x4a35e0[0x2]:parseInt(_0x4a35e0[0x2],0xa),_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0xcac')]=_0x2cfb05()['isEmpty'](_0x4a35e0[0x3])?_0x4a35e0[0x3]:isNaN(_0x4a35e0[0x3])?_0x4a35e0[0x3]:parseInt(_0x4a35e0[0x3],0xa);}break;}else{}_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x1345')]&&_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x1345')][_0x8c5fa3('0x2574')]()==='outbound'&&_0x32e1e7['dial']['appType'][_0x8c5fa3('0x2574')]()==='outbounddial'&&(_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x265a')]=_0x32e1e7['dial'][_0x8c5fa3('0x2026')]?_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x2026')]['split']('$')[0x0]:undefined,_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x1f02')]=_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x992')]?_0x8c5fa3('0xa4c')+_0x32e1e7[_0x8c5fa3('0xc77')][_0x8c5fa3('0x992')]:undefined);_0x32e1e7[_0x8c5fa3('0x2aa')]=_0x7ed98e,_0x32e1e7[_0x8c5fa3('0x24a0')]=_0x5d713f;function _0x7ed98e(){const _0x50a1eb=_0x8c5fa3;_0x32e1e7[_0x50a1eb('0x61a')]=[];const _0x34cb56=[];_0x32e1e7[_0x50a1eb('0xc77')][_0x50a1eb('0x1345')]&&_0x32e1e7[_0x50a1eb('0xc77')][_0x50a1eb('0x1345')][_0x50a1eb('0x2574')]()==='outbound'&&_0x32e1e7['dial']['appType']===_0x50a1eb('0x867')&&(_0x32e1e7[_0x50a1eb('0xc77')][_0x50a1eb('0x2026')]=_0x2084b7[_0x50a1eb('0x2848')]?(_0x32e1e7['dial'][_0x50a1eb('0x265a')]||'')+_0x50a1eb('0x881')+_0x2084b7[_0x50a1eb('0x2848')]+'}':(_0x32e1e7['dial'][_0x50a1eb('0x265a')]||'')+_0x50a1eb('0x1d1'),_0x2084b7[_0x50a1eb('0x28cb')]!==_0x50a1eb('0x192')?_0x32e1e7[_0x50a1eb('0xc77')][_0x50a1eb('0xd39')]['indexOf'](_0x50a1eb('0x1059'))<0x0&&(_0x32e1e7['dial'][_0x50a1eb('0xd39')]+=_0x50a1eb('0x1059')):_0x32e1e7[_0x50a1eb('0xc77')]['options']=_0x32e1e7[_0x50a1eb('0xc77')]['options'][_0x50a1eb('0xf3')](_0x50a1eb('0x1059'),''));if(_0x32e1e7[_0x50a1eb('0xc77')][_0x50a1eb('0x83f')]&&_0x32e1e7[_0x50a1eb('0xc77')]['appType']===_0x50a1eb('0x2853')){}else switch((_0x32e1e7[_0x50a1eb('0xc77')][_0x50a1eb('0x746')]||_0x32e1e7['dial'][_0x50a1eb('0x83f')])[_0x50a1eb('0x2574')]()){case _0x50a1eb('0xceb'):_0x32e1e7['dial'][_0x50a1eb('0x823')]=_0x32e1e7[_0x50a1eb('0xc77')]['name']+'='+_0x32e1e7[_0x50a1eb('0xc77')]['value'];break;case _0x50a1eb('0x2853'):break;default:_0x34cb56[0x0]=_0x32e1e7[_0x50a1eb('0xc77')][_0x50a1eb('0x134d')],_0x34cb56[0x1]=_0x32e1e7[_0x50a1eb('0xc77')][_0x50a1eb('0x651')],_0x34cb56[0x2]=_0x32e1e7[_0x50a1eb('0xc77')]['options'],_0x34cb56[0x3]=_0x32e1e7['dial'][_0x50a1eb('0xcac')],_0x32e1e7[_0x50a1eb('0xc77')][_0x50a1eb('0x823')]=_0x34cb56['join'](',');}_0x5d713f(_0x32e1e7['dial']);}function _0x5d713f(_0x2b6739){_0x2d2ce4['hide'](_0x2b6739);}}const _0x4f1c42=_0x209b42;_0x23799a['$inject']=['$mdDialog','$q','toasty',_0x36e6f4('0x96'),_0x36e6f4('0x12b4'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x23799a(_0x43ee26,_0x2beaed,_0x42c28b,_0x3b1545,_0xc1a806,_0x3593c4,_0x1fd237,_0x5dda2b){const _0x4004af=_0x36e6f4,_0x5d186a=this;_0x5d186a['currentUser']=_0x1fd237[_0x4004af('0x26cd')](),_0x5d186a[_0x4004af('0x61a')]=[],_0x5d186a[_0x4004af('0xcdc')]=_0x4004af('0xd79')+(_0x3b1545[_0x4004af('0x83f')]||_0x3b1545['app'])['toUpperCase'](),_0x5d186a[_0x4004af('0x26ee')]=angular[_0x4004af('0x225f')](_0x3b1545),_0x5d186a['crudPermissions']=_0x5dda2b,_0x5d186a['hasModulePermissions']={};if(_0x5d186a['externaldial'][_0x4004af('0x823')])switch(_0x5d186a[_0x4004af('0x26ee')]['appType']?_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x83f')][_0x4004af('0x2574')]():_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x746')][_0x4004af('0x2574')]()){case'custom':break;case'dialogflow':{const _0x395b24=_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x823')][_0x4004af('0x25c8')](',');_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x7ca')]=_0x395b24[0x0],_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0xedb')]=_0x395b24[0x1],_0x5d186a['externaldial']['welcomemessage']=_0x395b24[_0x4004af('0x233')](0x2,_0x395b24['length'])[_0x4004af('0x45a')](',');}break;case'dialogflowv2':{const _0xa4133=_0x5d186a['externaldial'][_0x4004af('0x823')][_0x4004af('0x25c8')](',');_0x5d186a['externaldial'][_0x4004af('0x1b0a')]=_0xa4133[0x0],_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x27f3')]=_0xa4133[0x1],_0x5d186a[_0x4004af('0x26ee')]['privateKey']=_0xa4133[0x2],_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0xedb')]=_0xa4133[0x3],_0x5d186a[_0x4004af('0x26ee')]['welcomemessage']=_0xa4133[_0x4004af('0x233')](0x4,_0xa4133[_0x4004af('0x264b')])[_0x4004af('0x45a')](',');}break;case _0x4004af('0x86c'):{const _0x53ea21=_0x5d186a['externaldial'][_0x4004af('0x823')][_0x4004af('0x25c8')](',');_0x5d186a['externaldial'][_0x4004af('0xee6')]=_0x53ea21[0x0],_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x125')]=_0x53ea21[0x1],_0x5d186a['externaldial'][_0x4004af('0x25a2')]=_0x53ea21[0x2],_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x1ac4')]=_0x53ea21[0x3],_0x5d186a['externaldial']['welcomemessage']=_0x53ea21['slice'](0x4,_0x53ea21['length'])[_0x4004af('0x45a')](',');}break;case _0x4004af('0x1af7'):{const _0x136093=_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x823')]['split'](',');_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x265e')]=isNaN(_0x136093[0x0])?_0x136093[0x0]:parseInt(_0x136093[0x0],0xa),_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x1640')]=_0x136093['slice'](0x1,_0x136093[_0x4004af('0x264b')])[_0x4004af('0x45a')](',');}break;case _0x4004af('0x1e70'):_0x5d186a[_0x4004af('0x26ee')]['text']=_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x823')];break;case _0x4004af('0xceb'):_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x4f0')]=_0x5d186a['externaldial'][_0x4004af('0x823')][_0x4004af('0x25c8')]('=')[0x0],_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x18e0')]=_0x5d186a['externaldial'][_0x4004af('0x823')][_0x4004af('0x25c8')]('=')[0x1];break;case _0x4004af('0x1034'):_0x5d186a['externaldial'][_0x4004af('0x2588')]=_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x823')];break;default:{const _0x39e218=_0x5d186a['externaldial'][_0x4004af('0x823')][_0x4004af('0x25c8')](',');_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x3b2')]=_0x39e218[0x0][_0x4004af('0x25c8')]('/')[0x1],_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x2026')]=_0x39e218[0x0][_0x4004af('0x25c8')]('/')[0x2],_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x651')]=_0x2cfb05()[_0x4004af('0x1081')](_0x39e218[0x1])?_0x39e218[0x1]:isNaN(_0x39e218[0x1])?_0x39e218[0x1]:parseInt(_0x39e218[0x1],0xa),_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0xd39')]=_0x2cfb05()[_0x4004af('0x1081')](_0x39e218[0x2])?_0x39e218[0x2]:isNaN(_0x39e218[0x2])?_0x39e218[0x2]:parseInt(_0x39e218[0x2],0xa),_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0xcac')]=_0x2cfb05()['isEmpty'](_0x39e218[0x3])?_0x39e218[0x3]:isNaN(_0x39e218[0x3])?_0x39e218[0x3]:parseInt(_0x39e218[0x3],0xa);}break;}else{}_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x1345')]&&_0x5d186a['externaldial'][_0x4004af('0x1345')][_0x4004af('0x2574')]()===_0x4004af('0x587')&&_0x5d186a['externaldial'][_0x4004af('0x83f')]['toLowerCase']()===_0x4004af('0x2884')&&(_0x5d186a['externaldial'][_0x4004af('0x265a')]=_0x5d186a['externaldial']['phone']?_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x2026')][_0x4004af('0x25c8')]('$')[0x0]:undefined,_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x1f02')]=_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x992')]?_0x4004af('0xa4c')+_0x5d186a[_0x4004af('0x26ee')][_0x4004af('0x992')]:undefined);_0x5d186a[_0x4004af('0x2aa')]=_0x1382b2,_0x5d186a[_0x4004af('0x24a0')]=_0x1b9134,_0x1fd237[_0x4004af('0x1ac6')](_0x4004af('0xa7c'))?_0x3593c4[_0x4004af('0x3b2')][_0x4004af('0xd83')]({'fields':_0x4004af('0x1776'),'sort':_0x4004af('0x4f0'),'nolimit':_0x4004af('0xf3b')})[_0x4004af('0xa44')][_0x4004af('0x1166')](function(_0x45ce60){const _0x51aa4e=_0x4004af;_0x5d186a[_0x51aa4e('0xf24')]=_0x45ce60['rows']||[];})[_0x4004af('0x1a80')](function(_0x28f626){const _0x4ef05c=_0x4004af;_0x42c28b['error']({'title':_0x28f626[_0x4ef05c('0x52d')]?_0x4ef05c('0x1e21')+_0x28f626[_0x4ef05c('0x52d')]+_0x4ef05c('0x11e1')+_0x28f626[_0x4ef05c('0xe1b')]:'SYSTEM:GET_TRUNKS','msg':_0x28f626[_0x4ef05c('0x25f4')]?JSON[_0x4ef05c('0xbac')](_0x28f626[_0x4ef05c('0x25f4')]):_0x28f626['toString']()});}):_0x3593c4[_0x4004af('0x3b2')]['get']({'fields':_0x4004af('0x1776'),'sort':_0x4004af('0x4f0'),'nolimit':_0x4004af('0xf3b')})[_0x4004af('0xa44')][_0x4004af('0x1166')](function(_0x88586c){const _0x5cee7e=_0x4004af;_0x5d186a[_0x5cee7e('0xf24')]=_0x88586c[_0x5cee7e('0x269a')]||[];})[_0x4004af('0x1166')](function(){const _0xbf12fe=_0x4004af;return _0x3593c4[_0xbf12fe('0x17aa')]['get']({'userProfileId':_0x5d186a['currentUser'][_0xbf12fe('0xb86')],'sectionId':0x3f3})[_0xbf12fe('0xa44')];})[_0x4004af('0x1166')](function(_0x2b44ca){const _0x1a33c8=_0x4004af,_0x5b63d9=_0x2b44ca&&_0x2b44ca['rows']?_0x2b44ca[_0x1a33c8('0x269a')][0x0]:null;if(!_0x5b63d9){const _0x340eb6=[];let _0x54ed01=null;_0x5d186a[_0x1a33c8('0x26ee')]&&(_0x54ed01=_0x2cfb05()[_0x1a33c8('0xc38')](_0x5d186a[_0x1a33c8('0xf24')],{'name':_0x5d186a[_0x1a33c8('0x26ee')][_0x1a33c8('0x3b2')]}));for(let _0x7d5713=0x0;_0x7d5713<_0x5d186a[_0x1a33c8('0xf24')][_0x1a33c8('0x264b')];_0x7d5713++){_0x54ed01&&_0x5d186a[_0x1a33c8('0xf24')][_0x7d5713]['id']===_0x54ed01['id']&&(_0x5d186a[_0x1a33c8('0xf24')][_0x7d5713][_0x1a33c8('0x2378')]=![],_0x340eb6[_0x1a33c8('0x1514')](_0x5d186a[_0x1a33c8('0xf24')][_0x7d5713]));}_0x5d186a[_0x1a33c8('0xf24')]=_0x340eb6;}else{if(!_0x5b63d9[_0x1a33c8('0x1a2b')])return _0x3593c4[_0x1a33c8('0x4b5')]['get']({'sectionId':_0x5b63d9['id']})[_0x1a33c8('0xa44')]['then'](function(_0x567480){const _0x2e7cc0=_0x1a33c8,_0x3407b2=_0x2cfb05()[_0x2e7cc0('0x2563')](_0x567480['rows'],function(_0x2dba17){const _0x49557a=_0x2e7cc0;return _0x2cfb05()['find'](_0x5d186a['trunks'],{'id':_0x2dba17[_0x49557a('0x24e8')]});});let _0x1d230f=null;_0x5d186a[_0x2e7cc0('0x26ee')]&&(_0x1d230f=_0x2cfb05()[_0x2e7cc0('0xc38')](_0x5d186a['trunks'],{'name':_0x5d186a[_0x2e7cc0('0x26ee')][_0x2e7cc0('0x3b2')]}));if(_0x1d230f&&!_0x2cfb05()[_0x2e7cc0('0x1798')](_0x3407b2,['id',_0x1d230f['id']])){const _0x15a3ac=_0x2cfb05()[_0x2e7cc0('0xc38')](_0x5d186a[_0x2e7cc0('0xf24')],{'id':_0x1d230f['id']});_0x15a3ac['canSelect']=![],_0x3407b2[_0x2e7cc0('0x1514')](_0x15a3ac);}_0x5d186a[_0x2e7cc0('0xf24')]=_0x3407b2;});}})[_0x4004af('0x1a80')](function(_0x2fd174){const _0x26d08e=_0x4004af;_0x42c28b[_0x26d08e('0xfc9')]({'title':_0x2fd174[_0x26d08e('0x52d')]?_0x26d08e('0x1e21')+_0x2fd174[_0x26d08e('0x52d')]+_0x26d08e('0x11e1')+_0x2fd174[_0x26d08e('0xe1b')]:_0x26d08e('0x1d44'),'msg':_0x2fd174[_0x26d08e('0x25f4')]?JSON[_0x26d08e('0xbac')](_0x2fd174[_0x26d08e('0x25f4')]):_0x2fd174[_0x26d08e('0x1586')]()});});function _0x1382b2(){const _0x370b27=_0x4004af;_0x5d186a[_0x370b27('0x61a')]=[];const _0x47b82e=[];_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x1345')]&&_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x1345')][_0x370b27('0x2574')]()===_0x370b27('0x587')&&_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x83f')]===_0x370b27('0x867')&&(_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x2026')]=_0xc1a806[_0x370b27('0x2848')]?(_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x265a')]||'')+_0x370b27('0x881')+_0xc1a806[_0x370b27('0x2848')]+'}':(_0x5d186a[_0x370b27('0x26ee')]['prefix']||'')+_0x370b27('0x1d1'),_0xc1a806['recordingFormat']!==_0x370b27('0x192')?_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0xd39')][_0x370b27('0x2379')](_0x370b27('0x1059'))<0x0&&(_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0xd39')]+=_0x370b27('0x1059')):_0x5d186a[_0x370b27('0x26ee')]['options']=_0x5d186a['externaldial'][_0x370b27('0xd39')][_0x370b27('0xf3')](_0x370b27('0x1059'),''));if(_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x83f')]&&_0x5d186a[_0x370b27('0x26ee')]['appType']===_0x370b27('0x2853')){}else switch((_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x746')]||_0x5d186a[_0x370b27('0x26ee')]['appType'])['toLowerCase']()){case'set':_0x5d186a['externaldial'][_0x370b27('0x823')]=_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x4f0')]+'='+_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x18e0')];break;case _0x370b27('0x2853'):break;default:_0x47b82e[0x0]=[_0x370b27('0x1683'),_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x3b2')],_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0x2026')]][_0x370b27('0x45a')]('/'),_0x47b82e[0x1]=_0x5d186a['externaldial'][_0x370b27('0x651')],_0x47b82e[0x2]=_0x5d186a['externaldial']['options'],_0x47b82e[0x3]=_0x5d186a[_0x370b27('0x26ee')][_0x370b27('0xcac')],_0x5d186a['externaldial']['appdata']=_0x47b82e['join'](',');}_0x1b9134(_0x5d186a['externaldial']);}function _0x1b9134(_0x484faf){_0x43ee26['hide'](_0x484faf);}}const _0xf87aa9=_0x23799a;_0xe2a8f2[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'internalrouteApp','internalroute',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0xe2a8f2(_0x314dc2,_0x161fad,_0x87c158,_0x2804f4,_0x34e212,_0x2ae4cb,_0x91b591,_0x17472c){const _0x188e52=_0x36e6f4,_0x2dba28=this;_0x2dba28['currentUser']=_0x91b591[_0x188e52('0x26cd')](),_0x2dba28[_0x188e52('0x61a')]=[],_0x2dba28[_0x188e52('0xcdc')]=_0x188e52('0xd79')+(_0x2804f4[_0x188e52('0x83f')]||_0x2804f4[_0x188e52('0x746')])[_0x188e52('0x1387')](),_0x2dba28['goto']=angular[_0x188e52('0x225f')](_0x2804f4),_0x2dba28['crudPermissions']=_0x17472c,_0x2dba28[_0x188e52('0x128b')]={};if(_0x2dba28['goto'][_0x188e52('0x823')])switch(_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x83f')]?_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x83f')][_0x188e52('0x2574')]():_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x746')][_0x188e52('0x2574')]()){case'custom':break;case _0x188e52('0xded'):{const _0x270c80=_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x823')][_0x188e52('0x25c8')](',');_0x2dba28['goto']['key']=_0x270c80[0x0],_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0xedb')]=_0x270c80[0x1],_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x1634')]=_0x270c80['slice'](0x2,_0x270c80[_0x188e52('0x264b')])[_0x188e52('0x45a')](',');}break;case _0x188e52('0x1636'):{const _0x502b51=_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x823')][_0x188e52('0x25c8')](',');_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x1b0a')]=_0x502b51[0x0],_0x2dba28['goto'][_0x188e52('0x27f3')]=_0x502b51[0x1],_0x2dba28['goto'][_0x188e52('0x170e')]=_0x502b51[0x2],_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0xedb')]=_0x502b51[0x3],_0x2dba28['goto']['welcomemessage']=_0x502b51[_0x188e52('0x233')](0x4,_0x502b51[_0x188e52('0x264b')])[_0x188e52('0x45a')](',');}break;case _0x188e52('0x86c'):{const _0x3ab756=_0x2dba28['goto'][_0x188e52('0x823')][_0x188e52('0x25c8')](',');_0x2dba28[_0x188e52('0x1a03')]['accesskeyid']=_0x3ab756[0x0],_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x125')]=_0x3ab756[0x1],_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x25a2')]=_0x3ab756[0x2],_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x1ac4')]=_0x3ab756[0x3],_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x1634')]=_0x3ab756['slice'](0x4,_0x3ab756[_0x188e52('0x264b')])[_0x188e52('0x45a')](',');}break;case _0x188e52('0x1af7'):{const _0x1594ab=_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x823')]['split'](',');_0x2dba28[_0x188e52('0x1a03')]['times']=isNaN(_0x1594ab[0x0])?_0x1594ab[0x0]:parseInt(_0x1594ab[0x0],0xa),_0x2dba28[_0x188e52('0x1a03')]['text']=_0x1594ab[_0x188e52('0x233')](0x1,_0x1594ab[_0x188e52('0x264b')])[_0x188e52('0x45a')](',');}break;case'message':_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x1640')]=_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x823')];break;case'set':_0x2dba28['goto'][_0x188e52('0x4f0')]=_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x823')]['split']('=')[0x0],_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x18e0')]=_0x2dba28['goto'][_0x188e52('0x823')][_0x188e52('0x25c8')]('=')[0x1];break;case _0x188e52('0x1034'):_0x2dba28[_0x188e52('0x1a03')]['project']=_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x823')];break;default:{const _0x4924eb=_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x823')][_0x188e52('0x25c8')](',');_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0xe1c')]=_0x2cfb05()[_0x188e52('0x1081')](_0x4924eb[0x0])?_0x4924eb[0x0]:isNaN(_0x4924eb[0x0])?_0x4924eb[0x0]:parseInt(_0x4924eb[0x0],0xa),_0x2dba28[_0x188e52('0x1a03')]['extension']=_0x2cfb05()[_0x188e52('0x1081')](_0x4924eb[0x1])?_0x4924eb[0x1]:isNaN(_0x4924eb[0x1])?_0x4924eb[0x1]:parseInt(_0x4924eb[0x1],0xa),_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0xfde')]=_0x2cfb05()[_0x188e52('0x1081')](_0x4924eb[0x2])?_0x4924eb[0x2]:isNaN(_0x4924eb[0x2])?_0x4924eb[0x2]:parseInt(_0x4924eb[0x2],0xa);}break;}else{}_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x1345')]&&_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x1345')]['toLowerCase']()==='outbound'&&_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x83f')][_0x188e52('0x2574')]()===_0x188e52('0x2884')&&(_0x2dba28['goto']['prefix']=_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x2026')]?_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x2026')][_0x188e52('0x25c8')]('$')[0x0]:undefined,_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x1f02')]=_0x2dba28[_0x188e52('0x1a03')]['callerID']?'CALLERID(all)='+_0x2dba28[_0x188e52('0x1a03')][_0x188e52('0x992')]:undefined);_0x2dba28[_0x188e52('0x2aa')]=_0x32bfff,_0x2dba28[_0x188e52('0x24a0')]=_0x55476a,_0x91b591[_0x188e52('0x1ac6')]('admin')?_0x2ae4cb[_0x188e52('0x23b1')][_0x188e52('0xd83')]({'fields':'id,name','sort':_0x188e52('0x4f0'),'nolimit':_0x188e52('0xf3b')})[_0x188e52('0xa44')][_0x188e52('0x1166')](function(_0x955186){const _0x395825=_0x188e52;_0x2dba28[_0x395825('0x160a')]=_0x955186[_0x395825('0x269a')]||[];})['catch'](function(_0x3dca17){const _0x945185=_0x188e52;_0x87c158[_0x945185('0xfc9')]({'title':_0x3dca17[_0x945185('0x52d')]?_0x945185('0x1e21')+_0x3dca17[_0x945185('0x52d')]+'\x20-\x20'+_0x3dca17[_0x945185('0xe1b')]:_0x945185('0x140d'),'msg':_0x3dca17['data']?JSON[_0x945185('0xbac')](_0x3dca17[_0x945185('0x25f4')]):_0x3dca17[_0x945185('0x1586')]()});}):_0x2ae4cb[_0x188e52('0x23b1')][_0x188e52('0xd83')]({'fields':_0x188e52('0x1776'),'sort':_0x188e52('0x4f0'),'nolimit':_0x188e52('0xf3b')})[_0x188e52('0xa44')][_0x188e52('0x1166')](function(_0x8c794e){_0x2dba28['contexts']=_0x8c794e['rows']||[];})[_0x188e52('0x1166')](function(){const _0x36d4e4=_0x188e52;return _0x2ae4cb[_0x36d4e4('0x17aa')][_0x36d4e4('0xd83')]({'userProfileId':_0x2dba28[_0x36d4e4('0x98')][_0x36d4e4('0xb86')],'sectionId':0x195})[_0x36d4e4('0xa44')];})[_0x188e52('0x1166')](function(_0x556cbd){const _0x2040a4=_0x188e52,_0x81325f=_0x556cbd&&_0x556cbd[_0x2040a4('0x269a')]?_0x556cbd[_0x2040a4('0x269a')][0x0]:null;if(!_0x81325f)return _0x2ae4cb[_0x2040a4('0x23b1')][_0x2040a4('0xd83')]({'fields':_0x2040a4('0x1776'),'sort':_0x2040a4('0x4f0'),'nolimit':_0x2040a4('0xf3b'),'defaultEntry':0x1})['$promise']['then'](function(_0x1ee899){const _0x3d0cec=_0x2040a4;_0x2dba28[_0x3d0cec('0x160a')]=_0x1ee899[_0x3d0cec('0x269a')]||[];});else{if(!_0x81325f['autoAssociation'])return _0x2ae4cb[_0x2040a4('0x4b5')][_0x2040a4('0xd83')]({'sectionId':_0x81325f['id']})[_0x2040a4('0xa44')]['then'](function(_0x211da4){const _0x3f41f2=_0x2040a4,_0x29e35f=_0x2cfb05()[_0x3f41f2('0x2563')](_0x211da4[_0x3f41f2('0x269a')],function(_0x284eb8){const _0x21596f=_0x3f41f2;return _0x2cfb05()[_0x21596f('0xc38')](_0x2dba28['contexts'],{'id':_0x284eb8[_0x21596f('0x24e8')]});});let _0x450c93=null;_0x2dba28[_0x3f41f2('0x1a03')]&&(_0x450c93=_0x2cfb05()[_0x3f41f2('0xc38')](_0x2dba28[_0x3f41f2('0x160a')],{'name':_0x2dba28[_0x3f41f2('0x1a03')][_0x3f41f2('0xe1c')]}));if(_0x450c93&&!_0x2cfb05()[_0x3f41f2('0x1798')](_0x29e35f,['id',_0x450c93['id']])){const _0x11d17e=_0x2cfb05()[_0x3f41f2('0xc38')](_0x2dba28[_0x3f41f2('0x160a')],{'id':_0x450c93['id']});_0x11d17e[_0x3f41f2('0x2378')]=![],_0x29e35f['push'](_0x11d17e);}_0x2dba28['contexts']=_0x29e35f;});}})['catch'](function(_0x116e4a){const _0x488d38=_0x188e52;_0x87c158['error']({'title':_0x116e4a[_0x488d38('0x52d')]?_0x488d38('0x1e21')+_0x116e4a['status']+_0x488d38('0x11e1')+_0x116e4a[_0x488d38('0xe1b')]:_0x488d38('0x482'),'msg':_0x116e4a[_0x488d38('0x25f4')]?JSON[_0x488d38('0xbac')](_0x116e4a[_0x488d38('0x25f4')]):_0x116e4a[_0x488d38('0x1586')]()});});function _0x32bfff(){const _0x4d75a0=_0x188e52;_0x2dba28[_0x4d75a0('0x61a')]=[];const _0x392f91=[];_0x2dba28[_0x4d75a0('0x1a03')]['type']&&_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0x1345')][_0x4d75a0('0x2574')]()===_0x4d75a0('0x587')&&_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0x83f')]===_0x4d75a0('0x867')&&(_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0x2026')]=_0x34e212['cutdigits']?(_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0x265a')]||'')+_0x4d75a0('0x881')+_0x34e212[_0x4d75a0('0x2848')]+'}':(_0x2dba28[_0x4d75a0('0x1a03')]['prefix']||'')+_0x4d75a0('0x1d1'),_0x34e212['recordingFormat']!==_0x4d75a0('0x192')?_0x2dba28[_0x4d75a0('0x1a03')]['options'][_0x4d75a0('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0xd39')]+=_0x4d75a0('0x1059')):_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0xd39')]=_0x2dba28['goto'][_0x4d75a0('0xd39')][_0x4d75a0('0xf3')](_0x4d75a0('0x1059'),''));if(_0x2dba28[_0x4d75a0('0x1a03')]['appType']&&_0x2dba28['goto'][_0x4d75a0('0x83f')]==='custom'){}else switch((_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0x746')]||_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0x83f')])[_0x4d75a0('0x2574')]()){case'set':_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0x823')]=_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0x4f0')]+'='+_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0x18e0')];break;case'custom':break;default:_0x392f91[0x0]=_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0xe1c')],_0x392f91[0x1]=_0x2dba28['goto']['extension'],_0x392f91[0x2]=_0x2dba28[_0x4d75a0('0x1a03')][_0x4d75a0('0xfde')],_0x2dba28[_0x4d75a0('0x1a03')]['appdata']=_0x392f91[_0x4d75a0('0x45a')](',');}_0x55476a(_0x2dba28[_0x4d75a0('0x1a03')]);}function _0x55476a(_0x53894d){const _0x223a1b=_0x188e52;_0x314dc2[_0x223a1b('0x1197')](_0x53894d);}}const _0x268ed2=_0xe2a8f2;_0x46f8fc[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'internalrouteApp',_0x36e6f4('0x12b4'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x46f8fc(_0x252491,_0x4affc7,_0x401856,_0x2206de,_0xfb5457,_0x5dbd0c,_0x2a8f02,_0x3180df){const _0x1964d9=_0x36e6f4,_0x16e79d=this;_0x16e79d['currentUser']=_0x2a8f02['getCurrentUser'](),_0x16e79d[_0x1964d9('0x61a')]=[],_0x16e79d[_0x1964d9('0xcdc')]=_0x1964d9('0xd79')+(_0x2206de[_0x1964d9('0x83f')]||_0x2206de[_0x1964d9('0x746')])[_0x1964d9('0x1387')](),_0x16e79d['hangup']=angular[_0x1964d9('0x225f')](_0x2206de),_0x16e79d[_0x1964d9('0x243c')]=_0x3180df,_0x16e79d[_0x1964d9('0x128b')]={};if(_0x16e79d[_0x1964d9('0x133d')]['appdata'])switch(_0x16e79d[_0x1964d9('0x133d')]['appType']?_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x83f')][_0x1964d9('0x2574')]():_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x746')]['toLowerCase']()){case'custom':break;case'dialogflow':{const _0xdda2dd=_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x823')]['split'](',');_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x7ca')]=_0xdda2dd[0x0],_0x16e79d['hangup'][_0x1964d9('0xedb')]=_0xdda2dd[0x1],_0x16e79d[_0x1964d9('0x133d')]['welcomemessage']=_0xdda2dd[_0x1964d9('0x233')](0x2,_0xdda2dd[_0x1964d9('0x264b')])['join'](',');}break;case _0x1964d9('0x1636'):{const _0x5d5d13=_0x16e79d[_0x1964d9('0x133d')]['appdata'][_0x1964d9('0x25c8')](',');_0x16e79d[_0x1964d9('0x133d')]['projectId']=_0x5d5d13[0x0],_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x27f3')]=_0x5d5d13[0x1],_0x16e79d[_0x1964d9('0x133d')]['privateKey']=_0x5d5d13[0x2],_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0xedb')]=_0x5d5d13[0x3],_0x16e79d['hangup'][_0x1964d9('0x1634')]=_0x5d5d13[_0x1964d9('0x233')](0x4,_0x5d5d13[_0x1964d9('0x264b')])[_0x1964d9('0x45a')](',');}break;case'amazonlex':{const _0x2d2fe3=_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x823')]['split'](',');_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0xee6')]=_0x2d2fe3[0x0],_0x16e79d['hangup']['secretaccesskey']=_0x2d2fe3[0x1],_0x16e79d['hangup'][_0x1964d9('0x25a2')]=_0x2d2fe3[0x2],_0x16e79d[_0x1964d9('0x133d')]['botname']=_0x2d2fe3[0x3],_0x16e79d[_0x1964d9('0x133d')]['welcomemessage']=_0x2d2fe3[_0x1964d9('0x233')](0x4,_0x2d2fe3[_0x1964d9('0x264b')])[_0x1964d9('0x45a')](',');}break;case'autoreply':{const _0x583f28=_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x823')][_0x1964d9('0x25c8')](',');_0x16e79d['hangup'][_0x1964d9('0x265e')]=isNaN(_0x583f28[0x0])?_0x583f28[0x0]:parseInt(_0x583f28[0x0],0xa),_0x16e79d['hangup'][_0x1964d9('0x1640')]=_0x583f28['slice'](0x1,_0x583f28[_0x1964d9('0x264b')])['join'](',');}break;case _0x1964d9('0x1e70'):_0x16e79d[_0x1964d9('0x133d')]['text']=_0x16e79d[_0x1964d9('0x133d')]['appdata'];break;case _0x1964d9('0xceb'):_0x16e79d['hangup'][_0x1964d9('0x4f0')]=_0x16e79d[_0x1964d9('0x133d')]['appdata'][_0x1964d9('0x25c8')]('=')[0x0],_0x16e79d[_0x1964d9('0x133d')]['value']=_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x823')][_0x1964d9('0x25c8')]('=')[0x1];break;case _0x1964d9('0x1034'):_0x16e79d[_0x1964d9('0x133d')]['project']=_0x16e79d[_0x1964d9('0x133d')]['appdata'];break;default:{const _0x79d6de=_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x823')][_0x1964d9('0x25c8')](',');_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x823')]=_0x2cfb05()['isEmpty'](_0x79d6de[0x0])?_0x79d6de[0x0]:isNaN(_0x79d6de[0x0])?_0x79d6de[0x0]:parseInt(_0x79d6de[0x0],0xa);}break;}else{}_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x1345')]&&_0x16e79d[_0x1964d9('0x133d')]['type']['toLowerCase']()===_0x1964d9('0x587')&&_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x83f')][_0x1964d9('0x2574')]()==='outbounddial'&&(_0x16e79d[_0x1964d9('0x133d')]['prefix']=_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x2026')]?_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x2026')]['split']('$')[0x0]:undefined,_0x16e79d[_0x1964d9('0x133d')]['callerId']=_0x16e79d[_0x1964d9('0x133d')][_0x1964d9('0x992')]?_0x1964d9('0xa4c')+_0x16e79d['hangup'][_0x1964d9('0x992')]:undefined);_0x16e79d[_0x1964d9('0x2aa')]=_0x5a886e,_0x16e79d[_0x1964d9('0x24a0')]=_0x11e3d1;function _0x5a886e(){const _0x53dbd9=_0x1964d9;_0x16e79d[_0x53dbd9('0x61a')]=[];const _0x401099=[];_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x1345')]&&_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x1345')][_0x53dbd9('0x2574')]()===_0x53dbd9('0x587')&&_0x16e79d['hangup'][_0x53dbd9('0x83f')]===_0x53dbd9('0x867')&&(_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x2026')]=_0xfb5457['cutdigits']?(_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x265a')]||'')+_0x53dbd9('0x881')+_0xfb5457[_0x53dbd9('0x2848')]+'}':(_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x265a')]||'')+_0x53dbd9('0x1d1'),_0xfb5457[_0x53dbd9('0x28cb')]!=='none'?_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0xd39')][_0x53dbd9('0x2379')](_0x53dbd9('0x1059'))<0x0&&(_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0xd39')]+=_0x53dbd9('0x1059')):_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0xd39')]=_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0xd39')][_0x53dbd9('0xf3')](_0x53dbd9('0x1059'),''));if(_0x16e79d['hangup'][_0x53dbd9('0x83f')]&&_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x83f')]==='custom'){}else switch((_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x746')]||_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x83f')])['toLowerCase']()){case _0x53dbd9('0xceb'):_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x823')]=_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x4f0')]+'='+_0x16e79d[_0x53dbd9('0x133d')]['value'];break;case'custom':break;default:_0x401099[0x0]=_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x823')],_0x16e79d[_0x53dbd9('0x133d')][_0x53dbd9('0x823')]=_0x401099['join'](',');}_0x11e3d1(_0x16e79d[_0x53dbd9('0x133d')]);}function _0x11e3d1(_0x4419d7){const _0x1d14d3=_0x1964d9;_0x252491[_0x1d14d3('0x1197')](_0x4419d7);}}const _0x41f4e0=_0x46f8fc;_0x3a4e91[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),'internalrouteApp',_0x36e6f4('0x12b4'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x3a4e91(_0x4d9ad1,_0x47708a,_0x590323,_0x3994b1,_0x3a181f,_0x1d0667,_0x301671,_0x367116){const _0x5dad9d=_0x36e6f4,_0x146460=this;_0x146460[_0x5dad9d('0x98')]=_0x301671['getCurrentUser'](),_0x146460[_0x5dad9d('0x61a')]=[],_0x146460[_0x5dad9d('0xcdc')]=_0x5dad9d('0xd79')+(_0x3994b1[_0x5dad9d('0x83f')]||_0x3994b1[_0x5dad9d('0x746')])[_0x5dad9d('0x1387')](),_0x146460[_0x5dad9d('0x143c')]=angular[_0x5dad9d('0x225f')](_0x3994b1),_0x146460[_0x5dad9d('0x243c')]=_0x367116,_0x146460['hasModulePermissions']={};if(_0x146460['internaldial'][_0x5dad9d('0x823')])switch(_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x83f')]?_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x83f')]['toLowerCase']():_0x146460['internaldial'][_0x5dad9d('0x746')][_0x5dad9d('0x2574')]()){case _0x5dad9d('0x2853'):break;case _0x5dad9d('0xded'):{const _0x413379=_0x146460[_0x5dad9d('0x143c')]['appdata'][_0x5dad9d('0x25c8')](',');_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x7ca')]=_0x413379[0x0],_0x146460[_0x5dad9d('0x143c')]['language']=_0x413379[0x1],_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x1634')]=_0x413379[_0x5dad9d('0x233')](0x2,_0x413379[_0x5dad9d('0x264b')])[_0x5dad9d('0x45a')](',');}break;case'dialogflowv2':{const _0x34c71c=_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x823')][_0x5dad9d('0x25c8')](',');_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x1b0a')]=_0x34c71c[0x0],_0x146460['internaldial']['clientEmail']=_0x34c71c[0x1],_0x146460['internaldial'][_0x5dad9d('0x170e')]=_0x34c71c[0x2],_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0xedb')]=_0x34c71c[0x3],_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x1634')]=_0x34c71c[_0x5dad9d('0x233')](0x4,_0x34c71c[_0x5dad9d('0x264b')])[_0x5dad9d('0x45a')](',');}break;case _0x5dad9d('0x86c'):{const _0x59d91a=_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x823')][_0x5dad9d('0x25c8')](',');_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0xee6')]=_0x59d91a[0x0],_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x125')]=_0x59d91a[0x1],_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x25a2')]=_0x59d91a[0x2],_0x146460[_0x5dad9d('0x143c')]['botname']=_0x59d91a[0x3],_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x1634')]=_0x59d91a['slice'](0x4,_0x59d91a['length'])['join'](',');}break;case'autoreply':{const _0x561987=_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x823')][_0x5dad9d('0x25c8')](',');_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x265e')]=isNaN(_0x561987[0x0])?_0x561987[0x0]:parseInt(_0x561987[0x0],0xa),_0x146460[_0x5dad9d('0x143c')]['text']=_0x561987['slice'](0x1,_0x561987[_0x5dad9d('0x264b')])[_0x5dad9d('0x45a')](',');}break;case'message':_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x1640')]=_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x823')];break;case _0x5dad9d('0xceb'):_0x146460['internaldial'][_0x5dad9d('0x4f0')]=_0x146460['internaldial'][_0x5dad9d('0x823')]['split']('=')[0x0],_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x18e0')]=_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x823')][_0x5dad9d('0x25c8')]('=')[0x1];break;case _0x5dad9d('0x1034'):_0x146460['internaldial'][_0x5dad9d('0x2588')]=_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x823')];break;default:{const _0x3bacf1=_0x146460[_0x5dad9d('0x143c')]['appdata'][_0x5dad9d('0x25c8')](',');_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x557')]=_0x2cfb05()[_0x5dad9d('0x1081')](_0x3bacf1[0x0])?_0x3bacf1[0x0]:isNaN(_0x3bacf1[0x0])?_0x3bacf1[0x0]:parseInt(_0x3bacf1[0x0],0xa),_0x146460[_0x5dad9d('0x143c')]['timeout']=_0x2cfb05()[_0x5dad9d('0x1081')](_0x3bacf1[0x1])?_0x3bacf1[0x1]:isNaN(_0x3bacf1[0x1])?_0x3bacf1[0x1]:parseInt(_0x3bacf1[0x1],0xa),_0x146460['internaldial'][_0x5dad9d('0xd39')]=_0x2cfb05()[_0x5dad9d('0x1081')](_0x3bacf1[0x2])?_0x3bacf1[0x2]:isNaN(_0x3bacf1[0x2])?_0x3bacf1[0x2]:parseInt(_0x3bacf1[0x2],0xa),_0x146460[_0x5dad9d('0x143c')]['url']=_0x2cfb05()['isEmpty'](_0x3bacf1[0x3])?_0x3bacf1[0x3]:isNaN(_0x3bacf1[0x3])?_0x3bacf1[0x3]:parseInt(_0x3bacf1[0x3],0xa);}break;}else{}_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x1345')]&&_0x146460[_0x5dad9d('0x143c')]['type'][_0x5dad9d('0x2574')]()===_0x5dad9d('0x587')&&_0x146460[_0x5dad9d('0x143c')]['appType']['toLowerCase']()==='outbounddial'&&(_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x265a')]=_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x2026')]?_0x146460['internaldial'][_0x5dad9d('0x2026')][_0x5dad9d('0x25c8')]('$')[0x0]:undefined,_0x146460[_0x5dad9d('0x143c')]['callerId']=_0x146460[_0x5dad9d('0x143c')][_0x5dad9d('0x992')]?_0x5dad9d('0xa4c')+_0x146460['internaldial'][_0x5dad9d('0x992')]:undefined);_0x146460['saveInternalRouteApp']=_0x13aba1,_0x146460[_0x5dad9d('0x24a0')]=_0x1b4a61;const _0x1c6991=[{'id':0xca,'role':'agent'},{'id':0xcb,'role':_0x5dad9d('0x887')}];let _0x3669a1=null;_0x301671[_0x5dad9d('0x1ac6')](_0x5dad9d('0xa7c'))?_0x1d0667[_0x5dad9d('0x557')][_0x5dad9d('0xd83')]({'fields':_0x5dad9d('0x1906'),'sort':_0x5dad9d('0x4f0'),'nolimit':_0x5dad9d('0xf3b')})[_0x5dad9d('0xa44')][_0x5dad9d('0x1166')](function(_0x40ecbe){const _0x64f057=_0x5dad9d;_0x146460['users']=_0x40ecbe[_0x64f057('0x269a')]||[];})[_0x5dad9d('0x1a80')](function(_0x21fa41){const _0x4a6d2b=_0x5dad9d;_0x590323['error']({'title':_0x21fa41[_0x4a6d2b('0x52d')]?_0x4a6d2b('0x1e21')+_0x21fa41['status']+_0x4a6d2b('0x11e1')+_0x21fa41[_0x4a6d2b('0xe1b')]:_0x4a6d2b('0x13e3'),'msg':_0x21fa41[_0x4a6d2b('0x25f4')]?JSON[_0x4a6d2b('0xbac')](_0x21fa41['data']):_0x21fa41[_0x4a6d2b('0x1586')]()});}):_0x1d0667[_0x5dad9d('0x557')][_0x5dad9d('0xd83')]({'fields':_0x5dad9d('0x1906'),'sort':_0x5dad9d('0x4f0'),'nolimit':'true'})[_0x5dad9d('0xa44')][_0x5dad9d('0x1166')](function(_0x3966dc){const _0x5f28ee=_0x5dad9d;_0x3669a1=_0x3966dc[_0x5f28ee('0x269a')]||[];})[_0x5dad9d('0x1166')](function(){const _0x31de75=_0x5dad9d,_0x3902ee=[];for(let _0x153ddc=0x0;_0x153ddc<_0x1c6991[_0x31de75('0x264b')];_0x153ddc++){_0x3902ee[_0x31de75('0x1514')](_0x1d0667['userProfileSection'][_0x31de75('0xd83')]({'userProfileId':_0x146460['currentUser'][_0x31de75('0xb86')],'sectionId':_0x1c6991[_0x153ddc]['id']})[_0x31de75('0xa44')]);}return _0x47708a[_0x31de75('0x2760')](_0x3902ee);})[_0x5dad9d('0x1166')](function(_0x3463cb){const _0x75387d=_0x5dad9d,_0x1b8ea4=_0x2cfb05()[_0x75387d('0x2563')](_0x3463cb,function(_0x17e686){const _0x483c2d=_0x75387d;return _0x17e686&&_0x17e686['rows']?_0x17e686[_0x483c2d('0x269a')][0x0]:null;}),_0x1b51fe=[];for(let _0x1e152d=0x0;_0x1e152d<_0x1c6991['length'];_0x1e152d++){const _0x3270a0=_0x2cfb05()[_0x75387d('0xc38')](_0x1b8ea4,[_0x75387d('0x120e'),_0x1c6991[_0x1e152d]['id']]);if(_0x3270a0){if(!_0x3270a0[_0x75387d('0x1a2b')])_0x1b51fe['push'](_0x1d0667[_0x75387d('0x4b5')]['get']({'sectionId':_0x3270a0['id']})['$promise']);else{const _0x51995a=[];_0x3669a1[_0x75387d('0x2782')](function(_0x4cffbe){const _0x564678=_0x75387d;_0x4cffbe['role']===_0x1c6991[_0x1e152d][_0x564678('0x1e75')]&&_0x51995a[_0x564678('0x1514')](_0x4cffbe);}),_0x1b51fe['push']({'rows':_0x51995a,'count':_0x51995a['length']});}}}return _0x47708a['all'](_0x1b51fe);})[_0x5dad9d('0x1166')](function(_0x294275){const _0x1ffea5=_0x5dad9d,_0x312595=[];let _0x3174a8=null;_0x146460[_0x1ffea5('0x143c')]&&(_0x3174a8=_0x2cfb05()[_0x1ffea5('0xc38')](_0x3669a1,{'name':_0x146460[_0x1ffea5('0x143c')][_0x1ffea5('0x557')]}));for(let _0x1d04fe=0x0;_0x1d04fe<_0x294275['length'];_0x1d04fe++){const _0x438341=_0x294275[_0x1d04fe][_0x1ffea5('0x269a')]||[];_0x438341['forEach'](function(_0x2edfee){_0x312595['push'](_0x2edfee);});}_0x3174a8&&!_0x2cfb05()[_0x1ffea5('0x1798')](_0x312595,[_0x1ffea5('0x24e8'),_0x3174a8['id']])&&_0x3669a1[_0x1ffea5('0x2782')](function(_0xcb7069){const _0xd59d75=_0x1ffea5;_0xcb7069['id']===_0x3174a8['id']&&(_0xcb7069[_0xd59d75('0x2378')]=![],_0x312595['push'](_0xcb7069));}),_0x146460[_0x1ffea5('0x21f6')]=_0x312595;})[_0x5dad9d('0x1a80')](function(_0x261e9c){const _0x4ca3cf=_0x5dad9d;_0x590323[_0x4ca3cf('0xfc9')]({'title':_0x261e9c[_0x4ca3cf('0x52d')]?_0x4ca3cf('0x1e21')+_0x261e9c[_0x4ca3cf('0x52d')]+_0x4ca3cf('0x11e1')+_0x261e9c[_0x4ca3cf('0xe1b')]:'SYSTEM:GETusers','msg':_0x261e9c[_0x4ca3cf('0x25f4')]?JSON['stringify'](_0x261e9c['data']):_0x261e9c[_0x4ca3cf('0x1586')]()});});function _0x13aba1(){const _0x43bff0=_0x5dad9d;_0x146460[_0x43bff0('0x61a')]=[];const _0x487d9e=[];_0x146460[_0x43bff0('0x143c')][_0x43bff0('0x1345')]&&_0x146460[_0x43bff0('0x143c')][_0x43bff0('0x1345')][_0x43bff0('0x2574')]()===_0x43bff0('0x587')&&_0x146460[_0x43bff0('0x143c')][_0x43bff0('0x83f')]==='outboundDial'&&(_0x146460['internaldial']['phone']=_0x3a181f[_0x43bff0('0x2848')]?(_0x146460['internaldial'][_0x43bff0('0x265a')]||'')+_0x43bff0('0x881')+_0x3a181f[_0x43bff0('0x2848')]+'}':(_0x146460['internaldial'][_0x43bff0('0x265a')]||'')+'${EXTEN}',_0x3a181f[_0x43bff0('0x28cb')]!=='none'?_0x146460[_0x43bff0('0x143c')][_0x43bff0('0xd39')][_0x43bff0('0x2379')](_0x43bff0('0x1059'))<0x0&&(_0x146460[_0x43bff0('0x143c')]['options']+=_0x43bff0('0x1059')):_0x146460[_0x43bff0('0x143c')][_0x43bff0('0xd39')]=_0x146460[_0x43bff0('0x143c')][_0x43bff0('0xd39')][_0x43bff0('0xf3')](_0x43bff0('0x1059'),''));if(_0x146460['internaldial']['appType']&&_0x146460[_0x43bff0('0x143c')][_0x43bff0('0x83f')]===_0x43bff0('0x2853')){}else switch((_0x146460['internaldial'][_0x43bff0('0x746')]||_0x146460[_0x43bff0('0x143c')]['appType'])[_0x43bff0('0x2574')]()){case _0x43bff0('0xceb'):_0x146460[_0x43bff0('0x143c')]['appdata']=_0x146460[_0x43bff0('0x143c')][_0x43bff0('0x4f0')]+'='+_0x146460[_0x43bff0('0x143c')][_0x43bff0('0x18e0')];break;case'custom':break;default:_0x487d9e[0x0]=_0x146460[_0x43bff0('0x143c')][_0x43bff0('0x557')],_0x487d9e[0x1]=_0x146460['internaldial'][_0x43bff0('0x651')],_0x487d9e[0x2]=_0x146460[_0x43bff0('0x143c')]['options'],_0x487d9e[0x3]=_0x146460[_0x43bff0('0x143c')][_0x43bff0('0xcac')],_0x146460[_0x43bff0('0x143c')][_0x43bff0('0x823')]=_0x487d9e[_0x43bff0('0x45a')](',');}_0x1b4a61(_0x146460[_0x43bff0('0x143c')]);}function _0x1b4a61(_0x50635b){_0x4d9ad1['hide'](_0x50635b);}}const _0x4a1a28=_0x3a4e91;_0x3580c7[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x265d'),_0x36e6f4('0x25d0'),_0x36e6f4('0x124d'),_0x36e6f4('0x277c'),_0x36e6f4('0x164e'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x3580c7(_0x1fb0a8,_0x5c6a97,_0x49aa03,_0x3af60e,_0x107a3c,_0x302e1f,_0x5233a0,_0x320473,_0x3a86d4,_0x265036){const _0xb56ef2=_0x36e6f4,_0x12fc61=this;_0x12fc61['currentUser']=_0x3a86d4[_0xb56ef2('0x26cd')](),_0x12fc61[_0xb56ef2('0x61a')]=[],_0x12fc61['title']=_0xb56ef2('0x2879'),_0x12fc61['interval']=angular[_0xb56ef2('0x225f')](_0x107a3c),_0x12fc61['intervals']=_0x302e1f,_0x12fc61[_0xb56ef2('0x99d')]=![],_0x12fc61[_0xb56ef2('0x6aa')]=[_0xb56ef2('0x597'),_0xb56ef2('0x2853'),_0xb56ef2('0x1480')],_0x12fc61[_0xb56ef2('0x243c')]=_0x265036,_0x12fc61['daysOfWeek']=_0x3af60e['getDaysOfWeek'](),_0x12fc61[_0xb56ef2('0x10b4')]=_0x3af60e[_0xb56ef2('0x51d')](),_0x12fc61[_0xb56ef2('0x2259')]=_0x3af60e['getMonthName'](),_0x12fc61[_0xb56ef2('0x1fc0')]=_0x3af60e[_0xb56ef2('0x2489')]();if(!_0x12fc61[_0xb56ef2('0x277c')])_0x12fc61[_0xb56ef2('0x277c')]={'interval':'*,*,*,*'},_0x12fc61[_0xb56ef2('0x1345')]=_0xb56ef2('0x597'),_0x12fc61['title']=_0xb56ef2('0x412'),_0x12fc61['newInterval']=!![];else{if(_0x12fc61[_0xb56ef2('0x277c')][_0xb56ef2('0x277c')]!==_0xb56ef2('0x16f')){_0x12fc61['type']=_0xb56ef2('0x2853');const _0x1b4868=_0x12fc61['interval'][_0xb56ef2('0x277c')]['split'](','),_0x1a8528=_0x1b4868[0x0],_0x280758=_0x1b4868[0x1],_0xddc821=_0x1b4868[0x2],_0x458a6b=_0x1b4868[0x3];if(_0x1a8528!=='*'){const _0x53bee1=_0x1a8528[_0xb56ef2('0x25c8')]('-')[0x0],_0x19abd1=_0x1a8528[_0xb56ef2('0x25c8')]('-')[0x1];let _0x1b5f30;_0x1b5f30=new Date(),_0x1b5f30['setHours'](Number(_0x53bee1['split'](':')[0x0])),_0x1b5f30[_0xb56ef2('0x790')](Number(_0x53bee1[_0xb56ef2('0x25c8')](':')[0x1])),_0x12fc61[_0xb56ef2('0x64d')]=_0x1b5f30,_0x1b5f30=new Date(),_0x1b5f30['setHours'](Number(_0x19abd1[_0xb56ef2('0x25c8')](':')[0x0])),_0x1b5f30[_0xb56ef2('0x790')](Number(_0x19abd1[_0xb56ef2('0x25c8')](':')[0x1])),_0x12fc61[_0xb56ef2('0x2076')]=_0x1b5f30;}_0x280758!=='*'&&(_0x12fc61[_0xb56ef2('0x1eca')]=_0x280758[_0xb56ef2('0x25c8')]('-')[0x0],_0x12fc61[_0xb56ef2('0x1b81')]=_0x280758[_0xb56ef2('0x25c8')]('-')[0x1]),_0xddc821!=='*'&&(_0x12fc61['monthDayFrom']=_0xddc821[_0xb56ef2('0x25c8')]('-')[0x0],_0x12fc61[_0xb56ef2('0x1dbb')]=_0xddc821[_0xb56ef2('0x25c8')]('-')[0x1]),_0x458a6b!=='*'&&(_0x12fc61[_0xb56ef2('0xdec')]=_0x458a6b['split']('-')[0x0],_0x12fc61[_0xb56ef2('0x1125')]=_0x458a6b[_0xb56ef2('0x25c8')]('-')[0x1]);}else _0x12fc61[_0xb56ef2('0x1345')]=_0xb56ef2('0x597');}_0x1fb0a8[_0xb56ef2('0x23f')]['id']&&!_0x12fc61['interval']['application']&&(_0x12fc61[_0xb56ef2('0x277c')][_0xb56ef2('0x186f')]=_0x1fb0a8[_0xb56ef2('0x23f')]['id']);_0x12fc61[_0xb56ef2('0x277c')][_0xb56ef2('0x186f')]&&_0x12fc61['interval'][_0xb56ef2('0x50d')]&&(_0x12fc61[_0xb56ef2('0x1345')]='list');_0x12fc61['addNewInterval']=_0x3b4e66,_0x12fc61[_0xb56ef2('0x24be')]=_0x3cc4fe,_0x12fc61[_0xb56ef2('0x24a0')]=_0xda30b7;_0x12fc61[_0xb56ef2('0x277c')]['application']&&(_0x3a86d4[_0xb56ef2('0x1ac6')]('admin')?_0x320473[_0xb56ef2('0x277c')]['get']({'fields':_0xb56ef2('0xd0a'),'IntervalId':_0xb56ef2('0x15d7'),'nolimit':!![]})[_0xb56ef2('0xa44')][_0xb56ef2('0x1166')](function(_0x411923){const _0x9c82b8=_0xb56ef2;_0x12fc61[_0x9c82b8('0x164e')]=_0x411923[_0x9c82b8('0x269a')]||[];})[_0xb56ef2('0x1a80')](function(_0x5b3fcc){const _0x27a230=_0xb56ef2;_0x5233a0[_0x27a230('0xfc9')]({'title':_0x5b3fcc[_0x27a230('0x52d')]?_0x27a230('0x1e21')+_0x5b3fcc[_0x27a230('0x52d')]+'\x20-\x20'+_0x5b3fcc[_0x27a230('0xe1b')]:_0x27a230('0xbb4'),'msg':_0x5b3fcc[_0x27a230('0x25f4')]?JSON['stringify'](_0x5b3fcc[_0x27a230('0x25f4')]):_0x5b3fcc[_0x27a230('0x1586')]()});}):_0x320473[_0xb56ef2('0x277c')]['get']({'fields':'id,name,interval,IntervalId','IntervalId':_0xb56ef2('0x15d7'),'nolimit':!![]})[_0xb56ef2('0xa44')][_0xb56ef2('0x1166')](function(_0x4f3b47){const _0x21820c=_0xb56ef2;_0x12fc61[_0x21820c('0x164e')]=_0x4f3b47[_0x21820c('0x269a')]||[];})[_0xb56ef2('0x1166')](function(){const _0x1b12f5=_0xb56ef2;return _0x320473[_0x1b12f5('0x17aa')][_0x1b12f5('0xd83')]({'userProfileId':_0x12fc61[_0x1b12f5('0x98')][_0x1b12f5('0xb86')],'sectionId':0x3ec})[_0x1b12f5('0xa44')];})['then'](function(_0x1d7308){const _0x171b25=_0xb56ef2,_0x4f5795=_0x1d7308&&_0x1d7308[_0x171b25('0x269a')]?_0x1d7308[_0x171b25('0x269a')][0x0]:null;if(!_0x4f5795)_0x12fc61[_0x171b25('0x164e')]=[];else{if(!_0x4f5795[_0x171b25('0x1a2b')])return _0x320473[_0x171b25('0x4b5')][_0x171b25('0xd83')]({'sectionId':_0x4f5795['id']})[_0x171b25('0xa44')][_0x171b25('0x1166')](function(_0x2f6d24){const _0x2d4d98=_0x171b25,_0x4c8f23=_0x2f6d24&&_0x2f6d24[_0x2d4d98('0x269a')]?_0x2f6d24[_0x2d4d98('0x269a')]:[],_0x1e5149=[];let _0x244bcd=null;_0x12fc61[_0x2d4d98('0x277c')]&&(_0x244bcd=_0x2cfb05()[_0x2d4d98('0xc38')](_0x12fc61[_0x2d4d98('0x164e')],{'name':_0x12fc61[_0x2d4d98('0x277c')][_0x2d4d98('0x186f')]})),_0x244bcd&&!_0x2cfb05()[_0x2d4d98('0x1798')](_0x4c8f23,['resourceId',_0x244bcd['id']])&&_0x12fc61[_0x2d4d98('0x164e')][_0x2d4d98('0x2782')](function(_0x1d3ead){const _0x4e6337=_0x2d4d98;_0x1d3ead['id']===_0x244bcd['id']&&(_0x1d3ead[_0x4e6337('0x2378')]=![],_0x1e5149[_0x4e6337('0x1514')](_0x1d3ead));}),_0x12fc61['intervals']=_0x1e5149;});}})['catch'](function(_0xb1972a){const _0x3c048b=_0xb56ef2;_0x5233a0[_0x3c048b('0xfc9')]({'title':_0xb1972a['status']?_0x3c048b('0x1e21')+_0xb1972a[_0x3c048b('0x52d')]+'\x20-\x20'+_0xb1972a[_0x3c048b('0xe1b')]:_0x3c048b('0xbb4'),'msg':_0xb1972a[_0x3c048b('0x25f4')]?JSON['stringify'](_0xb1972a['data']):_0xb1972a['toString']()});}));function _0x3944b3(){const _0x3e7742=_0xb56ef2;switch(_0x12fc61[_0x3e7742('0x1345')]){case _0x3e7742('0x597'):case _0x3e7742('0x1480'):return _0x3e7742('0x16f');case _0x3e7742('0x2853'):{const _0x24b2f9=[];if(_0x12fc61['timeRangeFrom']!=='*'&&_0x12fc61[_0x3e7742('0x64d')]&&_0x12fc61['timeRangeTo']){const _0x4a93f3=(_0x12fc61['timeRangeFrom'][_0x3e7742('0x11fe')]()<0xa?'0':'')+_0x12fc61[_0x3e7742('0x64d')][_0x3e7742('0x11fe')]()+':'+((_0x12fc61[_0x3e7742('0x64d')]['getMinutes']()<0xa?'0':'')+_0x12fc61[_0x3e7742('0x64d')][_0x3e7742('0x234')]()),_0x1a83bc=(_0x12fc61[_0x3e7742('0x2076')][_0x3e7742('0x11fe')]()<0xa?'0':'')+_0x12fc61[_0x3e7742('0x2076')][_0x3e7742('0x11fe')]()+':'+((_0x12fc61[_0x3e7742('0x2076')][_0x3e7742('0x234')]()<0xa?'0':'')+_0x12fc61[_0x3e7742('0x2076')]['getMinutes']());_0x24b2f9[_0x3e7742('0x1514')](_0x4a93f3+'-'+_0x1a83bc);}else _0x24b2f9[_0x3e7742('0x1514')]('*');return _0x12fc61['dayOfWeekFrom']?_0x12fc61[_0x3e7742('0x1b81')]?_0x24b2f9['push'](_0x12fc61['dayOfWeekFrom']+'-'+_0x12fc61[_0x3e7742('0x1b81')]):_0x24b2f9['push'](_0x12fc61[_0x3e7742('0x1eca')]):_0x24b2f9[_0x3e7742('0x1514')]('*'),_0x12fc61['monthDayFrom']?_0x12fc61[_0x3e7742('0x1dbb')]?_0x24b2f9[_0x3e7742('0x1514')](_0x12fc61['monthDayFrom']+'-'+_0x12fc61[_0x3e7742('0x1dbb')]):_0x24b2f9[_0x3e7742('0x1514')](_0x12fc61[_0x3e7742('0x103d')]):_0x24b2f9[_0x3e7742('0x1514')]('*'),_0x12fc61[_0x3e7742('0xdec')]?_0x12fc61[_0x3e7742('0x1125')]?_0x24b2f9[_0x3e7742('0x1514')](_0x12fc61[_0x3e7742('0xdec')]+'-'+_0x12fc61[_0x3e7742('0x1125')]):_0x24b2f9[_0x3e7742('0x1514')](_0x12fc61[_0x3e7742('0xdec')]):_0x24b2f9[_0x3e7742('0x1514')]('*'),_0x24b2f9[_0x3e7742('0x45a')]();}}}function _0x3b4e66(){const _0x297472=_0xb56ef2;_0x12fc61[_0x297472('0x61a')]=[],_0x12fc61[_0x297472('0x277c')]['interval']=_0x3944b3(),_0x320473[_0x297472('0x277c')][_0x297472('0x9cc')](_0x12fc61[_0x297472('0x277c')])[_0x297472('0xa44')][_0x297472('0x1166')](function(_0x55da18){const _0x3c7fa5=_0x297472;_0x12fc61[_0x3c7fa5('0x164e')]['push'](_0x55da18),_0x5233a0[_0x3c7fa5('0x103b')]({'title':'Interval\x20properly\x20created','msg':_0x12fc61[_0x3c7fa5('0x277c')][_0x3c7fa5('0x4f0')]?_0x12fc61[_0x3c7fa5('0x277c')][_0x3c7fa5('0x4f0')]+_0x3c7fa5('0x1eda'):''}),_0xda30b7();})[_0x297472('0x1a80')](function(_0x4eeebf){const _0x5967f0=_0x297472;console[_0x5967f0('0xfc9')](_0x4eeebf),_0x12fc61[_0x5967f0('0x61a')]=_0x4eeebf[_0x5967f0('0x25f4')]['errors']||[{'message':_0x4eeebf[_0x5967f0('0x1586')](),'type':_0x5967f0('0x1192')}];});}function _0x3cc4fe(){const _0x2a79e0=_0xb56ef2;_0x12fc61['errors']=[],_0x12fc61[_0x2a79e0('0x277c')][_0x2a79e0('0x277c')]=_0x3944b3(),_0x12fc61['interval']['application']?(_0x12fc61[_0x2a79e0('0x1345')]!==_0x2a79e0('0x1480')&&(_0x12fc61[_0x2a79e0('0x277c')][_0x2a79e0('0x186f')]=null),_0xda30b7(_0x12fc61['interval'])):_0x320473[_0x2a79e0('0x277c')][_0x2a79e0('0x1449')]({'id':_0x12fc61[_0x2a79e0('0x277c')]['id']},_0x12fc61[_0x2a79e0('0x277c')])['$promise'][_0x2a79e0('0x1166')](function(_0x54d2e5){const _0x252e99=_0x2a79e0,_0x3d16cc=_0x2cfb05()[_0x252e99('0xc38')](_0x12fc61[_0x252e99('0x164e')],{'id':_0x54d2e5['id']});_0x3d16cc&&_0x2cfb05()[_0x252e99('0xcc3')](_0x3d16cc,_0x54d2e5),_0x5233a0[_0x252e99('0x103b')]({'title':_0x252e99('0x1243'),'msg':_0x252e99('0x1666')}),_0xda30b7();})[_0x2a79e0('0x1a80')](function(_0x125a2e){const _0x465639=_0x2a79e0;console[_0x465639('0xfc9')](_0x125a2e),_0x12fc61[_0x465639('0x61a')]=_0x125a2e[_0x465639('0x25f4')]['errors']||[{'message':_0x125a2e[_0x465639('0x1586')](),'type':'api.interval.update'}];});}function _0xda30b7(_0x5afcf5){const _0x9359c=_0xb56ef2;_0x5c6a97[_0x9359c('0x1197')](_0x5afcf5);}}const _0x26a9fe=_0x3580c7;_0x55627d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x96'),_0x36e6f4('0x12b4'),_0x36e6f4('0x19e3'),'Auth','crudPermissions'];function _0x55627d(_0xd1a8bf,_0x162544,_0xea35f2,_0x4354fc,_0x48c0d7,_0x5b1fe7,_0x282e67,_0x27ccba){const _0x48694f=_0x36e6f4,_0x5c3a5b=this;_0x5c3a5b['currentUser']=_0x282e67[_0x48694f('0x26cd')](),_0x5c3a5b[_0x48694f('0x61a')]=[],_0x5c3a5b[_0x48694f('0xcdc')]='VOICE.EDIT_'+(_0x4354fc[_0x48694f('0x83f')]||_0x4354fc[_0x48694f('0x746')])[_0x48694f('0x1387')](),_0x5c3a5b[_0x48694f('0x19a0')]=angular['copy'](_0x4354fc),_0x5c3a5b['crudPermissions']=_0x27ccba,_0x5c3a5b['hasModulePermissions']={};if(_0x5c3a5b[_0x48694f('0x19a0')]['appdata'])switch(_0x5c3a5b['playback']['appType']?_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x83f')]['toLowerCase']():_0x5c3a5b[_0x48694f('0x19a0')]['app'][_0x48694f('0x2574')]()){case _0x48694f('0x2853'):break;case'dialogflow':{const _0x2f8aae=_0x5c3a5b['playback']['appdata'][_0x48694f('0x25c8')](',');_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x7ca')]=_0x2f8aae[0x0],_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0xedb')]=_0x2f8aae[0x1],_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x1634')]=_0x2f8aae[_0x48694f('0x233')](0x2,_0x2f8aae[_0x48694f('0x264b')])[_0x48694f('0x45a')](',');}break;case _0x48694f('0x1636'):{const _0x4a849e=_0x5c3a5b[_0x48694f('0x19a0')]['appdata'][_0x48694f('0x25c8')](',');_0x5c3a5b['playback'][_0x48694f('0x1b0a')]=_0x4a849e[0x0],_0x5c3a5b[_0x48694f('0x19a0')]['clientEmail']=_0x4a849e[0x1],_0x5c3a5b[_0x48694f('0x19a0')]['privateKey']=_0x4a849e[0x2],_0x5c3a5b[_0x48694f('0x19a0')]['language']=_0x4a849e[0x3],_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x1634')]=_0x4a849e['slice'](0x4,_0x4a849e['length'])[_0x48694f('0x45a')](',');}break;case _0x48694f('0x86c'):{const _0x304e19=_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x823')]['split'](',');_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0xee6')]=_0x304e19[0x0],_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x125')]=_0x304e19[0x1],_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x25a2')]=_0x304e19[0x2],_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x1ac4')]=_0x304e19[0x3],_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x1634')]=_0x304e19[_0x48694f('0x233')](0x4,_0x304e19[_0x48694f('0x264b')])[_0x48694f('0x45a')](',');}break;case _0x48694f('0x1af7'):{const _0x467b87=_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x823')][_0x48694f('0x25c8')](',');_0x5c3a5b['playback'][_0x48694f('0x265e')]=isNaN(_0x467b87[0x0])?_0x467b87[0x0]:parseInt(_0x467b87[0x0],0xa),_0x5c3a5b[_0x48694f('0x19a0')]['text']=_0x467b87[_0x48694f('0x233')](0x1,_0x467b87[_0x48694f('0x264b')])[_0x48694f('0x45a')](',');}break;case _0x48694f('0x1e70'):_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x1640')]=_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x823')];break;case _0x48694f('0xceb'):_0x5c3a5b['playback'][_0x48694f('0x4f0')]=_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x823')][_0x48694f('0x25c8')]('=')[0x0],_0x5c3a5b['playback']['value']=_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x823')][_0x48694f('0x25c8')]('=')[0x1];break;case'agi':_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x2588')]=_0x5c3a5b[_0x48694f('0x19a0')]['appdata'];break;default:{const _0x2ebca7=_0x5c3a5b['playback']['appdata'][_0x48694f('0x25c8')](',');_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x823')]=_0x2cfb05()[_0x48694f('0x1081')](_0x2ebca7[0x0])?_0x2ebca7[0x0]:isNaN(_0x2ebca7[0x0])?_0x2ebca7[0x0]:parseInt(_0x2ebca7[0x0],0xa),_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0xd39')]=_0x2cfb05()['isEmpty'](_0x2ebca7[0x1])?_0x2ebca7[0x1]:isNaN(_0x2ebca7[0x1])?_0x2ebca7[0x1]:parseInt(_0x2ebca7[0x1],0xa);}break;}else{}_0x5c3a5b['playback'][_0x48694f('0x1345')]&&_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x1345')]['toLowerCase']()==='outbound'&&_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x83f')][_0x48694f('0x2574')]()===_0x48694f('0x2884')&&(_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x265a')]=_0x5c3a5b['playback'][_0x48694f('0x2026')]?_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x2026')][_0x48694f('0x25c8')]('$')[0x0]:undefined,_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x1f02')]=_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x992')]?_0x48694f('0xa4c')+_0x5c3a5b[_0x48694f('0x19a0')][_0x48694f('0x992')]:undefined);_0x5c3a5b['saveInternalRouteApp']=_0x2a4460,_0x5c3a5b[_0x48694f('0x24a0')]=_0x5172f9,_0x282e67[_0x48694f('0x1ac6')]('admin')?_0x5b1fe7[_0x48694f('0x960')]['get']({'fields':'id,name,save_name','sort':_0x48694f('0x4f0'),'nolimit':'true'})[_0x48694f('0xa44')][_0x48694f('0x1166')](function(_0x4893bc){const _0x44ad9c=_0x48694f;_0x5c3a5b['sounds']=_0x4893bc[_0x44ad9c('0x269a')]||[];})['catch'](function(_0x44dedb){const _0x2a5e8f=_0x48694f;_0xea35f2[_0x2a5e8f('0xfc9')]({'title':_0x44dedb[_0x2a5e8f('0x52d')]?_0x2a5e8f('0x1e21')+_0x44dedb['status']+_0x2a5e8f('0x11e1')+_0x44dedb[_0x2a5e8f('0xe1b')]:_0x2a5e8f('0x140a'),'msg':_0x44dedb[_0x2a5e8f('0x25f4')]?JSON[_0x2a5e8f('0xbac')](_0x44dedb[_0x2a5e8f('0x25f4')]):_0x44dedb[_0x2a5e8f('0x1586')]()});}):_0x5b1fe7[_0x48694f('0x960')][_0x48694f('0xd83')]({'fields':_0x48694f('0x296'),'sort':_0x48694f('0x4f0'),'nolimit':_0x48694f('0xf3b')})['$promise'][_0x48694f('0x1166')](function(_0x472afb){const _0x284bb1=_0x48694f;_0x5c3a5b['sounds']=_0x472afb[_0x284bb1('0x269a')]||[];})[_0x48694f('0x1166')](function(){const _0x4b5d2f=_0x48694f;return _0x5b1fe7['userProfileSection']['get']({'userProfileId':_0x5c3a5b[_0x4b5d2f('0x98')][_0x4b5d2f('0xb86')],'sectionId':0x3ef})[_0x4b5d2f('0xa44')];})[_0x48694f('0x1166')](function(_0x50167e){const _0x146654=_0x48694f,_0x3792d1=_0x50167e&&_0x50167e[_0x146654('0x269a')]?_0x50167e[_0x146654('0x269a')][0x0]:null;if(!_0x3792d1){const _0x59e6c1=[];let _0x2475ad=null;_0x5c3a5b[_0x146654('0x19a0')]&&(_0x2475ad=_0x2cfb05()[_0x146654('0xc38')](_0x5c3a5b[_0x146654('0x137')],{'save_name':_0x5c3a5b[_0x146654('0x19a0')][_0x146654('0x823')]}));for(let _0x1e5963=0x0;_0x1e5963<_0x5c3a5b[_0x146654('0x137')]['length'];_0x1e5963++){_0x2475ad&&_0x5c3a5b[_0x146654('0x137')][_0x1e5963]['id']===_0x2475ad['id']&&(_0x5c3a5b[_0x146654('0x137')][_0x1e5963][_0x146654('0x2378')]=![],_0x59e6c1[_0x146654('0x1514')](_0x5c3a5b[_0x146654('0x137')][_0x1e5963]));}_0x5c3a5b[_0x146654('0x137')]=_0x59e6c1;}else{if(!_0x3792d1['autoAssociation'])return _0x5b1fe7[_0x146654('0x4b5')][_0x146654('0xd83')]({'sectionId':_0x3792d1['id']})['$promise'][_0x146654('0x1166')](function(_0x8d2b9b){const _0x3fe41d=_0x146654,_0x15ea6d=_0x2cfb05()[_0x3fe41d('0x2563')](_0x8d2b9b[_0x3fe41d('0x269a')],function(_0x4a56ab){const _0x199407=_0x3fe41d;return _0x2cfb05()['find'](_0x5c3a5b[_0x199407('0x137')],{'id':_0x4a56ab[_0x199407('0x24e8')]});});let _0x4d2dbe=null;_0x5c3a5b[_0x3fe41d('0x19a0')]&&(_0x4d2dbe=_0x2cfb05()[_0x3fe41d('0xc38')](_0x5c3a5b['sounds'],{'save_name':_0x5c3a5b[_0x3fe41d('0x19a0')][_0x3fe41d('0x823')]}));if(_0x4d2dbe&&!_0x2cfb05()[_0x3fe41d('0x1798')](_0x15ea6d,['id',_0x4d2dbe['id']])){const _0x133063=_0x2cfb05()[_0x3fe41d('0xc38')](_0x5c3a5b['sounds'],{'id':_0x4d2dbe['id']});_0x133063[_0x3fe41d('0x2378')]=![],_0x15ea6d[_0x3fe41d('0x1514')](_0x133063);}_0x5c3a5b['sounds']=_0x15ea6d;});}})[_0x48694f('0x1a80')](function(_0x3066b0){const _0x4ae187=_0x48694f;_0xea35f2['error']({'title':_0x3066b0[_0x4ae187('0x52d')]?_0x4ae187('0x1e21')+_0x3066b0['status']+_0x4ae187('0x11e1')+_0x3066b0[_0x4ae187('0xe1b')]:'SYSTEM:GETsounds','msg':_0x3066b0[_0x4ae187('0x25f4')]?JSON[_0x4ae187('0xbac')](_0x3066b0[_0x4ae187('0x25f4')]):_0x3066b0[_0x4ae187('0x1586')]()});});function _0x2a4460(){const _0x413e65=_0x48694f;_0x5c3a5b[_0x413e65('0x61a')]=[];const _0x1e3a0f=[];_0x5c3a5b[_0x413e65('0x19a0')]['type']&&_0x5c3a5b[_0x413e65('0x19a0')]['type'][_0x413e65('0x2574')]()==='outbound'&&_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0x83f')]===_0x413e65('0x867')&&(_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0x2026')]=_0x48c0d7['cutdigits']?(_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0x265a')]||'')+'${EXTEN:'+_0x48c0d7[_0x413e65('0x2848')]+'}':(_0x5c3a5b[_0x413e65('0x19a0')]['prefix']||'')+_0x413e65('0x1d1'),_0x48c0d7[_0x413e65('0x28cb')]!==_0x413e65('0x192')?_0x5c3a5b[_0x413e65('0x19a0')]['options'][_0x413e65('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0xd39')]+=_0x413e65('0x1059')):_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0xd39')]=_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0xd39')][_0x413e65('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x5c3a5b['playback'][_0x413e65('0x83f')]&&_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0x83f')]===_0x413e65('0x2853')){}else switch((_0x5c3a5b['playback'][_0x413e65('0x746')]||_0x5c3a5b['playback'][_0x413e65('0x83f')])[_0x413e65('0x2574')]()){case _0x413e65('0xceb'):_0x5c3a5b[_0x413e65('0x19a0')]['appdata']=_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0x4f0')]+'='+_0x5c3a5b[_0x413e65('0x19a0')]['value'];break;case _0x413e65('0x2853'):break;default:_0x1e3a0f[0x0]=_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0x823')],_0x1e3a0f[0x1]=_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0xd39')],_0x5c3a5b[_0x413e65('0x19a0')][_0x413e65('0x823')]=_0x1e3a0f[_0x413e65('0x45a')](',');}_0x5172f9(_0x5c3a5b[_0x413e65('0x19a0')]);}function _0x5172f9(_0x2dc318){const _0x273c67=_0x48694f;_0xd1a8bf[_0x273c67('0x1197')](_0x2dc318);}}const _0x5900ff=_0x55627d;_0x594bf2['$inject']=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x96'),_0x36e6f4('0x12b4'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x594bf2(_0x13c4b1,_0x1e2f9d,_0x471992,_0x16d783,_0x53c5bd,_0x2869a3,_0x43e70d,_0x5a9026){const _0x3722df=_0x36e6f4,_0x465bcf=this;_0x465bcf[_0x3722df('0x98')]=_0x43e70d[_0x3722df('0x26cd')](),_0x465bcf[_0x3722df('0x61a')]=[],_0x465bcf['title']=_0x3722df('0xd79')+(_0x16d783[_0x3722df('0x83f')]||_0x16d783[_0x3722df('0x746')])[_0x3722df('0x1387')](),_0x465bcf[_0x3722df('0x1d3e')]=angular['copy'](_0x16d783),_0x465bcf[_0x3722df('0x243c')]=_0x5a9026,_0x465bcf[_0x3722df('0x128b')]={};if(_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x823')])switch(_0x465bcf[_0x3722df('0x1d3e')]['appType']?_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x83f')][_0x3722df('0x2574')]():_0x465bcf[_0x3722df('0x1d3e')]['app']['toLowerCase']()){case _0x3722df('0x2853'):break;case _0x3722df('0xded'):{const _0x5d0f68=_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x823')][_0x3722df('0x25c8')](',');_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x7ca')]=_0x5d0f68[0x0],_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0xedb')]=_0x5d0f68[0x1],_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x1634')]=_0x5d0f68[_0x3722df('0x233')](0x2,_0x5d0f68[_0x3722df('0x264b')])[_0x3722df('0x45a')](',');}break;case _0x3722df('0x1636'):{const _0x754804=_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x823')][_0x3722df('0x25c8')](',');_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x1b0a')]=_0x754804[0x0],_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x27f3')]=_0x754804[0x1],_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x170e')]=_0x754804[0x2],_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0xedb')]=_0x754804[0x3],_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x1634')]=_0x754804[_0x3722df('0x233')](0x4,_0x754804['length'])[_0x3722df('0x45a')](',');}break;case _0x3722df('0x86c'):{const _0x1b089a=_0x465bcf['queue'][_0x3722df('0x823')]['split'](',');_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0xee6')]=_0x1b089a[0x0],_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x125')]=_0x1b089a[0x1],_0x465bcf['queue'][_0x3722df('0x25a2')]=_0x1b089a[0x2],_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x1ac4')]=_0x1b089a[0x3],_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x1634')]=_0x1b089a[_0x3722df('0x233')](0x4,_0x1b089a[_0x3722df('0x264b')])[_0x3722df('0x45a')](',');}break;case _0x3722df('0x1af7'):{const _0x371eff=_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x823')][_0x3722df('0x25c8')](',');_0x465bcf['queue'][_0x3722df('0x265e')]=isNaN(_0x371eff[0x0])?_0x371eff[0x0]:parseInt(_0x371eff[0x0],0xa),_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x1640')]=_0x371eff[_0x3722df('0x233')](0x1,_0x371eff[_0x3722df('0x264b')])[_0x3722df('0x45a')](',');}break;case _0x3722df('0x1e70'):_0x465bcf['queue'][_0x3722df('0x1640')]=_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x823')];break;case'set':_0x465bcf['queue'][_0x3722df('0x4f0')]=_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x823')]['split']('=')[0x0],_0x465bcf[_0x3722df('0x1d3e')]['value']=_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x823')][_0x3722df('0x25c8')]('=')[0x1];break;case'agi':_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x2588')]=_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x823')];break;default:{const _0x23aa26=_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x823')][_0x3722df('0x25c8')](',');_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x1d3e')]=_0x2cfb05()[_0x3722df('0x1081')](_0x23aa26[0x0])?_0x23aa26[0x0]:isNaN(_0x23aa26[0x0])?_0x23aa26[0x0]:parseInt(_0x23aa26[0x0],0xa),_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0xd39')]=_0x2cfb05()[_0x3722df('0x1081')](_0x23aa26[0x1])?_0x23aa26[0x1]:isNaN(_0x23aa26[0x1])?_0x23aa26[0x1]:parseInt(_0x23aa26[0x1],0xa),_0x465bcf[_0x3722df('0x1d3e')]['URL']=_0x2cfb05()[_0x3722df('0x1081')](_0x23aa26[0x2])?_0x23aa26[0x2]:isNaN(_0x23aa26[0x2])?_0x23aa26[0x2]:parseInt(_0x23aa26[0x2],0xa),_0x465bcf['queue'][_0x3722df('0x960')]=_0x2cfb05()[_0x3722df('0x1081')](_0x23aa26[0x3])?_0x23aa26[0x3]:isNaN(_0x23aa26[0x3])?_0x23aa26[0x3]:parseInt(_0x23aa26[0x3],0xa),_0x465bcf['queue'][_0x3722df('0x651')]=_0x2cfb05()[_0x3722df('0x1081')](_0x23aa26[0x4])?_0x23aa26[0x4]:isNaN(_0x23aa26[0x4])?_0x23aa26[0x4]:parseInt(_0x23aa26[0x4],0xa),_0x465bcf['queue'][_0x3722df('0x1034')]=_0x2cfb05()['isEmpty'](_0x23aa26[0x5])?_0x23aa26[0x5]:isNaN(_0x23aa26[0x5])?_0x23aa26[0x5]:parseInt(_0x23aa26[0x5],0xa),_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x1c8')]=_0x2cfb05()[_0x3722df('0x1081')](_0x23aa26[0x6])?_0x23aa26[0x6]:isNaN(_0x23aa26[0x6])?_0x23aa26[0x6]:parseInt(_0x23aa26[0x6],0xa),_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x281c')]=_0x2cfb05()[_0x3722df('0x1081')](_0x23aa26[0x7])?_0x23aa26[0x7]:isNaN(_0x23aa26[0x7])?_0x23aa26[0x7]:parseInt(_0x23aa26[0x7],0xa),_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x326')]=_0x2cfb05()[_0x3722df('0x1081')](_0x23aa26[0x8])?_0x23aa26[0x8]:isNaN(_0x23aa26[0x8])?_0x23aa26[0x8]:parseInt(_0x23aa26[0x8],0xa),_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x2086')]=_0x2cfb05()[_0x3722df('0x1081')](_0x23aa26[0x9])?_0x23aa26[0x9]:isNaN(_0x23aa26[0x9])?_0x23aa26[0x9]:parseInt(_0x23aa26[0x9],0xa);}break;}else{}_0x465bcf[_0x3722df('0x1d3e')]['type']&&_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x1345')][_0x3722df('0x2574')]()===_0x3722df('0x587')&&_0x465bcf[_0x3722df('0x1d3e')]['appType'][_0x3722df('0x2574')]()===_0x3722df('0x2884')&&(_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x265a')]=_0x465bcf[_0x3722df('0x1d3e')][_0x3722df('0x2026')]?_0x465bcf[_0x3722df('0x1d3e')]['phone'][_0x3722df('0x25c8')]('$')[0x0]:undefined,_0x465bcf['queue'][_0x3722df('0x1f02')]=_0x465bcf['queue']['callerID']?_0x3722df('0xa4c')+_0x465bcf[_0x3722df('0x1d3e')]['callerID']:undefined);_0x465bcf[_0x3722df('0x2aa')]=_0x1daa5c,_0x465bcf[_0x3722df('0x24a0')]=_0x38a1f1,_0x43e70d['hasRole']('admin')?_0x2869a3[_0x3722df('0x960')]['get']({'fields':_0x3722df('0x296'),'sort':'name','nolimit':_0x3722df('0xf3b')})[_0x3722df('0xa44')][_0x3722df('0x1166')](function(_0xd4ec67){const _0x1b3bb2=_0x3722df;_0x465bcf[_0x1b3bb2('0x137')]=_0xd4ec67[_0x1b3bb2('0x269a')]||[];})[_0x3722df('0x1a80')](function(_0x4719bf){const _0x158344=_0x3722df;_0x471992[_0x158344('0xfc9')]({'title':_0x4719bf[_0x158344('0x52d')]?_0x158344('0x1e21')+_0x4719bf[_0x158344('0x52d')]+'\x20-\x20'+_0x4719bf[_0x158344('0xe1b')]:_0x158344('0x140a'),'msg':_0x4719bf['data']?JSON['stringify'](_0x4719bf[_0x158344('0x25f4')]):_0x4719bf[_0x158344('0x1586')]()});}):_0x2869a3[_0x3722df('0x960')][_0x3722df('0xd83')]({'fields':_0x3722df('0x296'),'sort':_0x3722df('0x4f0'),'nolimit':_0x3722df('0xf3b')})[_0x3722df('0xa44')][_0x3722df('0x1166')](function(_0x879bf5){const _0xfff18b=_0x3722df;_0x465bcf[_0xfff18b('0x137')]=_0x879bf5[_0xfff18b('0x269a')]||[];})[_0x3722df('0x1166')](function(){const _0x19ac55=_0x3722df;return _0x2869a3[_0x19ac55('0x17aa')][_0x19ac55('0xd83')]({'userProfileId':_0x465bcf[_0x19ac55('0x98')][_0x19ac55('0xb86')],'sectionId':0x3ef})[_0x19ac55('0xa44')];})[_0x3722df('0x1166')](function(_0xd2cf60){const _0x5dcee=_0x3722df,_0x2efbbb=_0xd2cf60&&_0xd2cf60[_0x5dcee('0x269a')]?_0xd2cf60[_0x5dcee('0x269a')][0x0]:null;if(!_0x2efbbb){const _0x2a5699=[];let _0xf74c08=null;_0x465bcf[_0x5dcee('0x1d3e')]&&(_0xf74c08=_0x2cfb05()[_0x5dcee('0xc38')](_0x465bcf['sounds'],{'save_name':_0x465bcf[_0x5dcee('0x1d3e')]['sound']}));for(let _0x3aae04=0x0;_0x3aae04<_0x465bcf['sounds'][_0x5dcee('0x264b')];_0x3aae04++){_0xf74c08&&_0x465bcf[_0x5dcee('0x137')][_0x3aae04]['id']===_0xf74c08['id']&&(_0x465bcf['sounds'][_0x3aae04][_0x5dcee('0x2378')]=![],_0x2a5699['push'](_0x465bcf['sounds'][_0x3aae04]));}_0x465bcf[_0x5dcee('0x137')]=_0x2a5699;}else{if(!_0x2efbbb[_0x5dcee('0x1a2b')])return _0x2869a3[_0x5dcee('0x4b5')]['get']({'sectionId':_0x2efbbb['id']})[_0x5dcee('0xa44')]['then'](function(_0xc79335){const _0x34b5e3=_0x5dcee,_0x3abccc=_0x2cfb05()['map'](_0xc79335[_0x34b5e3('0x269a')],function(_0x2dba89){const _0x595c98=_0x34b5e3;return _0x2cfb05()[_0x595c98('0xc38')](_0x465bcf[_0x595c98('0x137')],{'id':_0x2dba89[_0x595c98('0x24e8')]});});let _0x249a87=null;_0x465bcf[_0x34b5e3('0x1d3e')]&&(_0x249a87=_0x2cfb05()[_0x34b5e3('0xc38')](_0x465bcf['sounds'],{'save_name':_0x465bcf['queue'][_0x34b5e3('0x960')]}));if(_0x249a87&&!_0x2cfb05()[_0x34b5e3('0x1798')](_0x3abccc,['id',_0x249a87['id']])){const _0x593b44=_0x2cfb05()['find'](_0x465bcf[_0x34b5e3('0x137')],{'id':_0x249a87['id']});_0x593b44[_0x34b5e3('0x2378')]=![],_0x3abccc[_0x34b5e3('0x1514')](_0x593b44);}_0x465bcf[_0x34b5e3('0x137')]=_0x3abccc;});}})[_0x3722df('0x1a80')](function(_0x27cd12){const _0x3e9677=_0x3722df;_0x471992[_0x3e9677('0xfc9')]({'title':_0x27cd12[_0x3e9677('0x52d')]?_0x3e9677('0x1e21')+_0x27cd12[_0x3e9677('0x52d')]+'\x20-\x20'+_0x27cd12[_0x3e9677('0xe1b')]:_0x3e9677('0x1d89'),'msg':_0x27cd12[_0x3e9677('0x25f4')]?JSON[_0x3e9677('0xbac')](_0x27cd12[_0x3e9677('0x25f4')]):_0x27cd12[_0x3e9677('0x1586')]()});}),_0x43e70d[_0x3722df('0x1ac6')](_0x3722df('0xa7c'))?_0x2869a3[_0x3722df('0x1943')]['get']({'type':_0x3722df('0x14d8'),'fields':'id,name,type','sort':_0x3722df('0x4f0'),'nolimit':_0x3722df('0xf3b')})[_0x3722df('0xa44')][_0x3722df('0x1166')](function(_0x269b87){const _0x1463ad=_0x3722df;_0x465bcf[_0x1463ad('0x7a7')]=_0x269b87[_0x1463ad('0x269a')]||[];})[_0x3722df('0x1a80')](function(_0x54bfe0){const _0x38addd=_0x3722df;_0x471992[_0x38addd('0xfc9')]({'title':_0x54bfe0[_0x38addd('0x52d')]?_0x38addd('0x1e21')+_0x54bfe0['status']+_0x38addd('0x11e1')+_0x54bfe0[_0x38addd('0xe1b')]:_0x38addd('0x2029'),'msg':_0x54bfe0['data']?JSON['stringify'](_0x54bfe0[_0x38addd('0x25f4')]):_0x54bfe0[_0x38addd('0x1586')]()});}):_0x2869a3[_0x3722df('0x1943')][_0x3722df('0xd83')]({'type':_0x3722df('0x14d8'),'fields':_0x3722df('0x1c09'),'sort':_0x3722df('0x4f0'),'nolimit':_0x3722df('0xf3b')})[_0x3722df('0xa44')][_0x3722df('0x1166')](function(_0x608d2b){const _0x1b7c40=_0x3722df;_0x465bcf[_0x1b7c40('0x7a7')]=_0x608d2b[_0x1b7c40('0x269a')]||[];})[_0x3722df('0x1166')](function(){const _0x7ea520=_0x3722df;return _0x2869a3['userProfileSection'][_0x7ea520('0xd83')]({'userProfileId':_0x465bcf[_0x7ea520('0x98')][_0x7ea520('0xb86')],'sectionId':0x191})[_0x7ea520('0xa44')];})[_0x3722df('0x1166')](function(_0x21f5a9){const _0x400310=_0x3722df,_0x24cf2f=_0x21f5a9&&_0x21f5a9[_0x400310('0x269a')]?_0x21f5a9[_0x400310('0x269a')][0x0]:null;if(!_0x24cf2f){const _0x116aa4=[];let _0x33f6a3=null;_0x465bcf[_0x400310('0x1d3e')]&&(_0x33f6a3=_0x2cfb05()[_0x400310('0xc38')](_0x465bcf[_0x400310('0x7a7')],{'name':_0x465bcf[_0x400310('0x1d3e')]['queue']}));for(let _0x5af7e7=0x0;_0x5af7e7<_0x465bcf[_0x400310('0x7a7')]['length'];_0x5af7e7++){_0x33f6a3&&_0x465bcf[_0x400310('0x7a7')][_0x5af7e7]['id']===_0x33f6a3['id']&&(_0x465bcf[_0x400310('0x7a7')][_0x5af7e7][_0x400310('0x2378')]=![],_0x116aa4[_0x400310('0x1514')](_0x465bcf[_0x400310('0x7a7')][_0x5af7e7]));}_0x465bcf[_0x400310('0x7a7')]=_0x116aa4;}else{if(!_0x24cf2f[_0x400310('0x1a2b')])return _0x2869a3[_0x400310('0x4b5')][_0x400310('0xd83')]({'sectionId':_0x24cf2f['id']})[_0x400310('0xa44')][_0x400310('0x1166')](function(_0x31cac1){const _0x38d746=_0x400310,_0x1ddb36=_0x2cfb05()[_0x38d746('0x2563')](_0x31cac1[_0x38d746('0x269a')],function(_0x59af0a){const _0x106877=_0x38d746;return _0x2cfb05()[_0x106877('0xc38')](_0x465bcf[_0x106877('0x7a7')],{'id':_0x59af0a[_0x106877('0x24e8')]});});let _0x2bbab4=null;_0x465bcf[_0x38d746('0x1d3e')]&&(_0x2bbab4=_0x2cfb05()[_0x38d746('0xc38')](_0x465bcf[_0x38d746('0x7a7')],{'name':_0x465bcf[_0x38d746('0x1d3e')][_0x38d746('0x1d3e')]}));if(_0x2bbab4&&!_0x2cfb05()[_0x38d746('0x1798')](_0x1ddb36,['id',_0x2bbab4['id']])){const _0x1fdeee=_0x2cfb05()[_0x38d746('0xc38')](_0x465bcf[_0x38d746('0x7a7')],{'id':_0x2bbab4['id']});_0x1fdeee[_0x38d746('0x2378')]=![],_0x1ddb36['push'](_0x1fdeee);}_0x465bcf[_0x38d746('0x7a7')]=_0x1ddb36;});}})[_0x3722df('0x1a80')](function(_0x3557f7){const _0x591b1c=_0x3722df;_0x471992['error']({'title':_0x3557f7['status']?_0x591b1c('0x1e21')+_0x3557f7[_0x591b1c('0x52d')]+_0x591b1c('0x11e1')+_0x3557f7[_0x591b1c('0xe1b')]:_0x591b1c('0x1dd7'),'msg':_0x3557f7[_0x591b1c('0x25f4')]?JSON[_0x591b1c('0xbac')](_0x3557f7[_0x591b1c('0x25f4')]):_0x3557f7[_0x591b1c('0x1586')]()});});function _0x1daa5c(){const _0x8386a0=_0x3722df;_0x465bcf['errors']=[];const _0x3aa223=[];_0x465bcf[_0x8386a0('0x1d3e')]['type']&&_0x465bcf['queue'][_0x8386a0('0x1345')]['toLowerCase']()===_0x8386a0('0x587')&&_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0x83f')]==='outboundDial'&&(_0x465bcf['queue']['phone']=_0x53c5bd[_0x8386a0('0x2848')]?(_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0x265a')]||'')+_0x8386a0('0x881')+_0x53c5bd[_0x8386a0('0x2848')]+'}':(_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0x265a')]||'')+_0x8386a0('0x1d1'),_0x53c5bd[_0x8386a0('0x28cb')]!=='none'?_0x465bcf['queue'][_0x8386a0('0xd39')][_0x8386a0('0x2379')](_0x8386a0('0x1059'))<0x0&&(_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0xd39')]+=_0x8386a0('0x1059')):_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0xd39')]=_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0xd39')][_0x8386a0('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0x83f')]&&_0x465bcf['queue'][_0x8386a0('0x83f')]===_0x8386a0('0x2853')){}else switch((_0x465bcf[_0x8386a0('0x1d3e')]['app']||_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0x83f')])['toLowerCase']()){case'set':_0x465bcf['queue'][_0x8386a0('0x823')]=_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0x4f0')]+'='+_0x465bcf[_0x8386a0('0x1d3e')]['value'];break;case'custom':break;default:_0x3aa223[0x0]=_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0x1d3e')],_0x3aa223[0x1]=_0x465bcf['queue'][_0x8386a0('0xd39')],_0x3aa223[0x2]=_0x465bcf['queue'][_0x8386a0('0x308')],_0x3aa223[0x3]=_0x465bcf[_0x8386a0('0x1d3e')]['sound'],_0x3aa223[0x4]=_0x465bcf['queue'][_0x8386a0('0x651')],_0x3aa223[0x5]=_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0x1034')],_0x3aa223[0x6]=_0x465bcf['queue'][_0x8386a0('0x1c8')],_0x3aa223[0x7]=_0x465bcf['queue'][_0x8386a0('0x281c')],_0x3aa223[0x8]=_0x465bcf['queue'][_0x8386a0('0x326')],_0x3aa223[0x9]=_0x465bcf[_0x8386a0('0x1d3e')][_0x8386a0('0x2086')],_0x465bcf['queue']['appdata']=_0x3aa223['join'](',');}_0x38a1f1(_0x465bcf['queue']);}function _0x38a1f1(_0x11fc67){const _0x54a098=_0x3722df;_0x13c4b1[_0x54a098('0x1197')](_0x11fc67);}}const _0x257a05=_0x594bf2;_0x32f436['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x96'),_0x36e6f4('0x12b4'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x32f436(_0x3f6bc8,_0x4734f8,_0x293da6,_0x7df69c,_0x201718,_0x5d8aa8,_0x2c6c54,_0x7a276e){const _0x337f0e=_0x36e6f4,_0x51c363=this;_0x51c363[_0x337f0e('0x98')]=_0x2c6c54[_0x337f0e('0x26cd')](),_0x51c363['errors']=[],_0x51c363[_0x337f0e('0xcdc')]=_0x337f0e('0xd79')+(_0x7df69c[_0x337f0e('0x83f')]||_0x7df69c[_0x337f0e('0x746')])[_0x337f0e('0x1387')](),_0x51c363[_0x337f0e('0xed1')]=angular[_0x337f0e('0x225f')](_0x7df69c),_0x51c363[_0x337f0e('0x243c')]=_0x7a276e,_0x51c363['hasModulePermissions']={};if(_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x823')])switch(_0x51c363[_0x337f0e('0xed1')]['appType']?_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x83f')]['toLowerCase']():_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x746')][_0x337f0e('0x2574')]()){case _0x337f0e('0x2853'):break;case _0x337f0e('0xded'):{const _0x1c1278=_0x51c363['ringgroup'][_0x337f0e('0x823')][_0x337f0e('0x25c8')](',');_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x7ca')]=_0x1c1278[0x0],_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0xedb')]=_0x1c1278[0x1],_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x1634')]=_0x1c1278['slice'](0x2,_0x1c1278[_0x337f0e('0x264b')])[_0x337f0e('0x45a')](',');}break;case'dialogflowv2':{const _0x433f74=_0x51c363[_0x337f0e('0xed1')]['appdata'][_0x337f0e('0x25c8')](',');_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x1b0a')]=_0x433f74[0x0],_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x27f3')]=_0x433f74[0x1],_0x51c363[_0x337f0e('0xed1')]['privateKey']=_0x433f74[0x2],_0x51c363['ringgroup'][_0x337f0e('0xedb')]=_0x433f74[0x3],_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x1634')]=_0x433f74['slice'](0x4,_0x433f74['length'])[_0x337f0e('0x45a')](',');}break;case'amazonlex':{const _0x6b188b=_0x51c363['ringgroup'][_0x337f0e('0x823')][_0x337f0e('0x25c8')](',');_0x51c363[_0x337f0e('0xed1')]['accesskeyid']=_0x6b188b[0x0],_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x125')]=_0x6b188b[0x1],_0x51c363['ringgroup'][_0x337f0e('0x25a2')]=_0x6b188b[0x2],_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x1ac4')]=_0x6b188b[0x3],_0x51c363['ringgroup']['welcomemessage']=_0x6b188b[_0x337f0e('0x233')](0x4,_0x6b188b[_0x337f0e('0x264b')])['join'](',');}break;case _0x337f0e('0x1af7'):{const _0x2c249c=_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x823')]['split'](',');_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x265e')]=isNaN(_0x2c249c[0x0])?_0x2c249c[0x0]:parseInt(_0x2c249c[0x0],0xa),_0x51c363[_0x337f0e('0xed1')]['text']=_0x2c249c[_0x337f0e('0x233')](0x1,_0x2c249c[_0x337f0e('0x264b')])[_0x337f0e('0x45a')](',');}break;case _0x337f0e('0x1e70'):_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x1640')]=_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x823')];break;case'set':_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x4f0')]=_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x823')][_0x337f0e('0x25c8')]('=')[0x0],_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x18e0')]=_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x823')][_0x337f0e('0x25c8')]('=')[0x1];break;case'agi':_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x2588')]=_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x823')];break;default:{const _0x4df2e0=_0x51c363['ringgroup'][_0x337f0e('0x823')][_0x337f0e('0x25c8')](',');_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x1855')]=_0x4df2e0[0x0][_0x337f0e('0x25c8')]('&'),_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x651')]=_0x2cfb05()[_0x337f0e('0x1081')](_0x4df2e0[0x1])?_0x4df2e0[0x1]:isNaN(_0x4df2e0[0x1])?_0x4df2e0[0x1]:parseInt(_0x4df2e0[0x1],0xa),_0x51c363['ringgroup'][_0x337f0e('0xd39')]=_0x2cfb05()[_0x337f0e('0x1081')](_0x4df2e0[0x2])?_0x4df2e0[0x2]:isNaN(_0x4df2e0[0x2])?_0x4df2e0[0x2]:parseInt(_0x4df2e0[0x2],0xa),_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0xcac')]=_0x2cfb05()[_0x337f0e('0x1081')](_0x4df2e0[0x3])?_0x4df2e0[0x3]:isNaN(_0x4df2e0[0x3])?_0x4df2e0[0x3]:parseInt(_0x4df2e0[0x3],0xa);}break;}else{}_0x51c363['ringgroup']['type']&&_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x1345')][_0x337f0e('0x2574')]()===_0x337f0e('0x587')&&_0x51c363[_0x337f0e('0xed1')]['appType']['toLowerCase']()===_0x337f0e('0x2884')&&(_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x265a')]=_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x2026')]?_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x2026')][_0x337f0e('0x25c8')]('$')[0x0]:undefined,_0x51c363['ringgroup']['callerId']=_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x992')]?_0x337f0e('0xa4c')+_0x51c363[_0x337f0e('0xed1')][_0x337f0e('0x992')]:undefined);_0x51c363[_0x337f0e('0x2aa')]=_0x17e904,_0x51c363['closeDialog']=_0x482b09;const _0x43d03f=[{'id':0xca,'role':_0x337f0e('0x1eff')},{'id':0xcb,'role':_0x337f0e('0x887')}];let _0x28fb5d=null;_0x2c6c54[_0x337f0e('0x1ac6')](_0x337f0e('0xa7c'))?_0x5d8aa8['user'][_0x337f0e('0xd83')]({'fields':'id,name,role','sort':_0x337f0e('0x4f0'),'nolimit':_0x337f0e('0xf3b')})[_0x337f0e('0xa44')][_0x337f0e('0x1166')](function(_0x234577){const _0x530104=_0x337f0e;_0x51c363[_0x530104('0x21f6')]=_0x234577[_0x530104('0x269a')]||[];})['catch'](function(_0x369f1d){const _0x448737=_0x337f0e;_0x293da6[_0x448737('0xfc9')]({'title':_0x369f1d[_0x448737('0x52d')]?_0x448737('0x1e21')+_0x369f1d[_0x448737('0x52d')]+_0x448737('0x11e1')+_0x369f1d[_0x448737('0xe1b')]:_0x448737('0x13e3'),'msg':_0x369f1d[_0x448737('0x25f4')]?JSON[_0x448737('0xbac')](_0x369f1d['data']):_0x369f1d[_0x448737('0x1586')]()});}):_0x5d8aa8[_0x337f0e('0x557')][_0x337f0e('0xd83')]({'fields':_0x337f0e('0x1906'),'sort':_0x337f0e('0x4f0'),'nolimit':'true'})[_0x337f0e('0xa44')][_0x337f0e('0x1166')](function(_0x5db096){const _0x15d94a=_0x337f0e;_0x28fb5d=_0x5db096[_0x15d94a('0x269a')]||[];})['then'](function(){const _0x56b18a=_0x337f0e,_0x47ae6d=[];for(let _0x881375=0x0;_0x881375<_0x43d03f[_0x56b18a('0x264b')];_0x881375++){_0x47ae6d[_0x56b18a('0x1514')](_0x5d8aa8[_0x56b18a('0x17aa')][_0x56b18a('0xd83')]({'userProfileId':_0x51c363[_0x56b18a('0x98')][_0x56b18a('0xb86')],'sectionId':_0x43d03f[_0x881375]['id']})['$promise']);}return _0x4734f8[_0x56b18a('0x2760')](_0x47ae6d);})[_0x337f0e('0x1166')](function(_0x6cb1f2){const _0x308d7f=_0x337f0e,_0x1497e1=_0x2cfb05()['map'](_0x6cb1f2,function(_0x3904e4){const _0x592d23=a0_0x3f2c;return _0x3904e4&&_0x3904e4['rows']?_0x3904e4[_0x592d23('0x269a')][0x0]:null;}),_0x14a680=[];for(let _0x25d4cd=0x0;_0x25d4cd<_0x43d03f['length'];_0x25d4cd++){const _0x23879=_0x2cfb05()['find'](_0x1497e1,[_0x308d7f('0x120e'),_0x43d03f[_0x25d4cd]['id']]);if(_0x23879){if(!_0x23879[_0x308d7f('0x1a2b')])_0x14a680[_0x308d7f('0x1514')](_0x5d8aa8[_0x308d7f('0x4b5')][_0x308d7f('0xd83')]({'sectionId':_0x23879['id']})[_0x308d7f('0xa44')]);else{const _0x1406d8=[];_0x28fb5d[_0x308d7f('0x2782')](function(_0x330f19){const _0x17b8ab=_0x308d7f;_0x330f19[_0x17b8ab('0x1e75')]===_0x43d03f[_0x25d4cd][_0x17b8ab('0x1e75')]&&_0x1406d8[_0x17b8ab('0x1514')](_0x330f19);}),_0x14a680[_0x308d7f('0x1514')]({'rows':_0x1406d8,'count':_0x1406d8[_0x308d7f('0x264b')]});}}}return _0x4734f8[_0x308d7f('0x2760')](_0x14a680);})[_0x337f0e('0x1166')](function(_0xa18fda){const _0x3a32d8=_0x337f0e,_0x37fceb=[];let _0x128571=null;_0x51c363[_0x3a32d8('0xed1')]&&(_0x128571=_0x2cfb05()['find'](_0x28fb5d,{'name':_0x51c363[_0x3a32d8('0xed1')][_0x3a32d8('0x1855')]}));for(let _0x48073a=0x0;_0x48073a<_0xa18fda[_0x3a32d8('0x264b')];_0x48073a++){const _0x5b5582=_0xa18fda[_0x48073a][_0x3a32d8('0x269a')]||[];_0x5b5582['forEach'](function(_0xc7dbd0){const _0x547234=_0x3a32d8;_0x37fceb[_0x547234('0x1514')](_0xc7dbd0);});}_0x128571&&!_0x2cfb05()[_0x3a32d8('0x1798')](_0x37fceb,[_0x3a32d8('0x24e8'),_0x128571['id']])&&_0x28fb5d[_0x3a32d8('0x2782')](function(_0x99388e){_0x99388e['id']===_0x128571['id']&&(_0x99388e['canSelect']=![],_0x37fceb['push'](_0x99388e));}),_0x51c363[_0x3a32d8('0x21f6')]=_0x37fceb;})[_0x337f0e('0x1a80')](function(_0x1b6356){const _0x187438=_0x337f0e;_0x293da6[_0x187438('0xfc9')]({'title':_0x1b6356['status']?'API:'+_0x1b6356['status']+_0x187438('0x11e1')+_0x1b6356['statusText']:'SYSTEM:GETusers','msg':_0x1b6356[_0x187438('0x25f4')]?JSON[_0x187438('0xbac')](_0x1b6356[_0x187438('0x25f4')]):_0x1b6356[_0x187438('0x1586')]()});});function _0x17e904(){const _0xa61a2a=_0x337f0e;_0x51c363[_0xa61a2a('0x61a')]=[];const _0x598af2=[];_0x51c363[_0xa61a2a('0xed1')][_0xa61a2a('0x1345')]&&_0x51c363[_0xa61a2a('0xed1')]['type'][_0xa61a2a('0x2574')]()===_0xa61a2a('0x587')&&_0x51c363[_0xa61a2a('0xed1')][_0xa61a2a('0x83f')]===_0xa61a2a('0x867')&&(_0x51c363['ringgroup']['phone']=_0x201718[_0xa61a2a('0x2848')]?(_0x51c363[_0xa61a2a('0xed1')][_0xa61a2a('0x265a')]||'')+'${EXTEN:'+_0x201718[_0xa61a2a('0x2848')]+'}':(_0x51c363[_0xa61a2a('0xed1')]['prefix']||'')+_0xa61a2a('0x1d1'),_0x201718[_0xa61a2a('0x28cb')]!==_0xa61a2a('0x192')?_0x51c363[_0xa61a2a('0xed1')][_0xa61a2a('0xd39')]['indexOf'](_0xa61a2a('0x1059'))<0x0&&(_0x51c363[_0xa61a2a('0xed1')][_0xa61a2a('0xd39')]+=_0xa61a2a('0x1059')):_0x51c363['ringgroup'][_0xa61a2a('0xd39')]=_0x51c363[_0xa61a2a('0xed1')][_0xa61a2a('0xd39')][_0xa61a2a('0xf3')](_0xa61a2a('0x1059'),''));if(_0x51c363['ringgroup'][_0xa61a2a('0x83f')]&&_0x51c363[_0xa61a2a('0xed1')]['appType']===_0xa61a2a('0x2853')){}else switch((_0x51c363[_0xa61a2a('0xed1')]['app']||_0x51c363['ringgroup'][_0xa61a2a('0x83f')])['toLowerCase']()){case _0xa61a2a('0xceb'):_0x51c363['ringgroup'][_0xa61a2a('0x823')]=_0x51c363[_0xa61a2a('0xed1')]['name']+'='+_0x51c363[_0xa61a2a('0xed1')]['value'];break;case _0xa61a2a('0x2853'):break;default:_0x598af2[0x0]=_0x51c363[_0xa61a2a('0xed1')][_0xa61a2a('0x1855')][_0xa61a2a('0x45a')]('&'),_0x598af2[0x1]=_0x51c363[_0xa61a2a('0xed1')][_0xa61a2a('0x651')],_0x598af2[0x2]=_0x51c363[_0xa61a2a('0xed1')][_0xa61a2a('0xd39')],_0x598af2[0x3]=_0x51c363[_0xa61a2a('0xed1')]['url'],_0x51c363['ringgroup'][_0xa61a2a('0x823')]=_0x598af2[_0xa61a2a('0x45a')](',');}_0x482b09(_0x51c363[_0xa61a2a('0xed1')]);}function _0x482b09(_0x6c6164){const _0xba281a=_0x337f0e;_0x3f6bc8[_0xba281a('0x1197')](_0x6c6164);}}const _0x13deb9=_0x32f436;_0x4c323a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'internalrouteApp',_0x36e6f4('0x12b4'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x4c323a(_0x9407b5,_0x2e8eb7,_0x1449a2,_0x30a1b2,_0x22df76,_0x5cdbb0,_0x5be38f,_0x26ed64){const _0xba6e1e=_0x36e6f4,_0x409a0c=this;_0x409a0c[_0xba6e1e('0x98')]=_0x5be38f['getCurrentUser'](),_0x409a0c[_0xba6e1e('0x61a')]=[],_0x409a0c[_0xba6e1e('0xcdc')]=_0xba6e1e('0xd79')+(_0x30a1b2['appType']||_0x30a1b2['app'])['toUpperCase'](),_0x409a0c[_0xba6e1e('0xceb')]=angular[_0xba6e1e('0x225f')](_0x30a1b2),_0x409a0c[_0xba6e1e('0x243c')]=_0x26ed64,_0x409a0c['hasModulePermissions']={};if(_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x823')])switch(_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x83f')]?_0x409a0c['set']['appType'][_0xba6e1e('0x2574')]():_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x746')][_0xba6e1e('0x2574')]()){case _0xba6e1e('0x2853'):break;case _0xba6e1e('0xded'):{const _0x251eb4=_0x409a0c['set'][_0xba6e1e('0x823')]['split'](',');_0x409a0c[_0xba6e1e('0xceb')]['key']=_0x251eb4[0x0],_0x409a0c[_0xba6e1e('0xceb')]['language']=_0x251eb4[0x1],_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x1634')]=_0x251eb4[_0xba6e1e('0x233')](0x2,_0x251eb4[_0xba6e1e('0x264b')])[_0xba6e1e('0x45a')](',');}break;case _0xba6e1e('0x1636'):{const _0x3f53de=_0x409a0c['set'][_0xba6e1e('0x823')][_0xba6e1e('0x25c8')](',');_0x409a0c['set']['projectId']=_0x3f53de[0x0],_0x409a0c[_0xba6e1e('0xceb')]['clientEmail']=_0x3f53de[0x1],_0x409a0c[_0xba6e1e('0xceb')]['privateKey']=_0x3f53de[0x2],_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0xedb')]=_0x3f53de[0x3],_0x409a0c['set'][_0xba6e1e('0x1634')]=_0x3f53de['slice'](0x4,_0x3f53de[_0xba6e1e('0x264b')])['join'](',');}break;case _0xba6e1e('0x86c'):{const _0x45594a=_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x823')][_0xba6e1e('0x25c8')](',');_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0xee6')]=_0x45594a[0x0],_0x409a0c[_0xba6e1e('0xceb')]['secretaccesskey']=_0x45594a[0x1],_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x25a2')]=_0x45594a[0x2],_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x1ac4')]=_0x45594a[0x3],_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x1634')]=_0x45594a[_0xba6e1e('0x233')](0x4,_0x45594a[_0xba6e1e('0x264b')])[_0xba6e1e('0x45a')](',');}break;case _0xba6e1e('0x1af7'):{const _0x32ba95=_0x409a0c['set'][_0xba6e1e('0x823')][_0xba6e1e('0x25c8')](',');_0x409a0c[_0xba6e1e('0xceb')]['times']=isNaN(_0x32ba95[0x0])?_0x32ba95[0x0]:parseInt(_0x32ba95[0x0],0xa),_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x1640')]=_0x32ba95[_0xba6e1e('0x233')](0x1,_0x32ba95[_0xba6e1e('0x264b')])['join'](',');}break;case'message':_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x1640')]=_0x409a0c['set'][_0xba6e1e('0x823')];break;case _0xba6e1e('0xceb'):_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x4f0')]=_0x409a0c[_0xba6e1e('0xceb')]['appdata'][_0xba6e1e('0x25c8')]('=')[0x0],_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x18e0')]=_0x409a0c[_0xba6e1e('0xceb')]['appdata']['split']('=')[0x1];break;case _0xba6e1e('0x1034'):_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x2588')]=_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x823')];break;default:{const _0x54fb11=_0x409a0c['set'][_0xba6e1e('0x823')][_0xba6e1e('0x25c8')]('=');_0x409a0c['set']['name']=_0x2cfb05()[_0xba6e1e('0x1081')](_0x54fb11[0x0])?_0x54fb11[0x0]:isNaN(_0x54fb11[0x0])?_0x54fb11[0x0]:parseInt(_0x54fb11[0x0],0xa),_0x409a0c[_0xba6e1e('0xceb')]['value']=_0x2cfb05()[_0xba6e1e('0x1081')](_0x54fb11[0x1])?_0x54fb11[0x1]:isNaN(_0x54fb11[0x1])?_0x54fb11[0x1]:parseInt(_0x54fb11[0x1],0xa);}break;}else{}_0x409a0c[_0xba6e1e('0xceb')]['type']&&_0x409a0c[_0xba6e1e('0xceb')]['type'][_0xba6e1e('0x2574')]()===_0xba6e1e('0x587')&&_0x409a0c['set'][_0xba6e1e('0x83f')][_0xba6e1e('0x2574')]()==='outbounddial'&&(_0x409a0c[_0xba6e1e('0xceb')]['prefix']=_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x2026')]?_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x2026')]['split']('$')[0x0]:undefined,_0x409a0c['set'][_0xba6e1e('0x1f02')]=_0x409a0c[_0xba6e1e('0xceb')]['callerID']?_0xba6e1e('0xa4c')+_0x409a0c[_0xba6e1e('0xceb')][_0xba6e1e('0x992')]:undefined);_0x409a0c[_0xba6e1e('0x2aa')]=_0x19bccc,_0x409a0c[_0xba6e1e('0x24a0')]=_0x170b7c,_0x5be38f['hasRole'](_0xba6e1e('0xa7c'))?_0x5cdbb0[_0xba6e1e('0x734')][_0xba6e1e('0xd83')]({'fields':_0xba6e1e('0x1776'),'sort':_0xba6e1e('0x4f0'),'nolimit':_0xba6e1e('0xf3b')})[_0xba6e1e('0xa44')]['then'](function(_0x4ad9b0){const _0x8329ab=_0xba6e1e;_0x409a0c[_0x8329ab('0x57a')]=_0x4ad9b0[_0x8329ab('0x269a')]||[];})['catch'](function(_0x332d72){const _0x4774ae=_0xba6e1e;_0x1449a2['error']({'title':_0x332d72[_0x4774ae('0x52d')]?_0x4774ae('0x1e21')+_0x332d72[_0x4774ae('0x52d')]+'\x20-\x20'+_0x332d72['statusText']:_0x4774ae('0xcf8'),'msg':_0x332d72[_0x4774ae('0x25f4')]?JSON[_0x4774ae('0xbac')](_0x332d72[_0x4774ae('0x25f4')]):_0x332d72[_0x4774ae('0x1586')]()});}):_0x5cdbb0[_0xba6e1e('0x734')][_0xba6e1e('0xd83')]({'fields':_0xba6e1e('0x1776'),'sort':_0xba6e1e('0x4f0'),'nolimit':_0xba6e1e('0xf3b')})[_0xba6e1e('0xa44')]['then'](function(_0x3b3122){const _0x176609=_0xba6e1e;_0x409a0c[_0x176609('0x57a')]=_0x3b3122[_0x176609('0x269a')]||[];})[_0xba6e1e('0x1166')](function(){const _0x2ac1fa=_0xba6e1e;return _0x5cdbb0[_0x2ac1fa('0x17aa')][_0x2ac1fa('0xd83')]({'userProfileId':_0x409a0c['currentUser'][_0x2ac1fa('0xb86')],'sectionId':0x3f4})[_0x2ac1fa('0xa44')];})['then'](function(_0x7990f7){const _0x48cd95=_0xba6e1e,_0x3c24f6=_0x7990f7&&_0x7990f7['rows']?_0x7990f7[_0x48cd95('0x269a')][0x0]:null;if(!_0x3c24f6){const _0x26f523=[];let _0x2d9252=null;_0x409a0c[_0x48cd95('0xceb')]&&(_0x2d9252=_0x2cfb05()['find'](_0x409a0c['variables'],{'name':_0x409a0c[_0x48cd95('0xceb')]['name']}));for(let _0xe019e9=0x0;_0xe019e9<_0x409a0c['variables'][_0x48cd95('0x264b')];_0xe019e9++){_0x2d9252&&_0x409a0c[_0x48cd95('0x57a')][_0xe019e9]['id']===_0x2d9252['id']&&(_0x409a0c[_0x48cd95('0x57a')][_0xe019e9]['canSelect']=![],_0x26f523[_0x48cd95('0x1514')](_0x409a0c[_0x48cd95('0x57a')][_0xe019e9]));}_0x409a0c['variables']=_0x26f523;}else{if(!_0x3c24f6[_0x48cd95('0x1a2b')])return _0x5cdbb0[_0x48cd95('0x4b5')][_0x48cd95('0xd83')]({'sectionId':_0x3c24f6['id']})[_0x48cd95('0xa44')]['then'](function(_0x5534c7){const _0x37cf04=_0x48cd95,_0x1d6fd4=_0x2cfb05()[_0x37cf04('0x2563')](_0x5534c7[_0x37cf04('0x269a')],function(_0x4fe910){const _0x19df6a=_0x37cf04;return _0x2cfb05()[_0x19df6a('0xc38')](_0x409a0c[_0x19df6a('0x57a')],{'id':_0x4fe910['resourceId']});});let _0x18d3fc=null;_0x409a0c[_0x37cf04('0xceb')]&&(_0x18d3fc=_0x2cfb05()[_0x37cf04('0xc38')](_0x409a0c[_0x37cf04('0x57a')],{'name':_0x409a0c['set'][_0x37cf04('0x4f0')]}));if(_0x18d3fc&&!_0x2cfb05()[_0x37cf04('0x1798')](_0x1d6fd4,['id',_0x18d3fc['id']])){const _0x2c64d4=_0x2cfb05()['find'](_0x409a0c[_0x37cf04('0x57a')],{'id':_0x18d3fc['id']});_0x2c64d4[_0x37cf04('0x2378')]=![],_0x1d6fd4[_0x37cf04('0x1514')](_0x2c64d4);}_0x409a0c[_0x37cf04('0x57a')]=_0x1d6fd4;});}})[_0xba6e1e('0x1a80')](function(_0x4ea77a){const _0x9ee0e4=_0xba6e1e;_0x1449a2[_0x9ee0e4('0xfc9')]({'title':_0x4ea77a[_0x9ee0e4('0x52d')]?_0x9ee0e4('0x1e21')+_0x4ea77a[_0x9ee0e4('0x52d')]+_0x9ee0e4('0x11e1')+_0x4ea77a[_0x9ee0e4('0xe1b')]:_0x9ee0e4('0x2644'),'msg':_0x4ea77a['data']?JSON[_0x9ee0e4('0xbac')](_0x4ea77a[_0x9ee0e4('0x25f4')]):_0x4ea77a[_0x9ee0e4('0x1586')]()});});function _0x19bccc(){const _0x54e32d=_0xba6e1e;_0x409a0c[_0x54e32d('0x61a')]=[];const _0x51cacd=[];_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0x1345')]&&_0x409a0c['set'][_0x54e32d('0x1345')]['toLowerCase']()===_0x54e32d('0x587')&&_0x409a0c[_0x54e32d('0xceb')]['appType']===_0x54e32d('0x867')&&(_0x409a0c[_0x54e32d('0xceb')]['phone']=_0x22df76['cutdigits']?(_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0x265a')]||'')+'${EXTEN:'+_0x22df76['cutdigits']+'}':(_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0x265a')]||'')+_0x54e32d('0x1d1'),_0x22df76[_0x54e32d('0x28cb')]!==_0x54e32d('0x192')?_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0xd39')][_0x54e32d('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0xd39')]+=_0x54e32d('0x1059')):_0x409a0c['set'][_0x54e32d('0xd39')]=_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0xd39')]['replace'](_0x54e32d('0x1059'),''));if(_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0x83f')]&&_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0x83f')]===_0x54e32d('0x2853')){}else switch((_0x409a0c['set']['app']||_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0x83f')])[_0x54e32d('0x2574')]()){case _0x54e32d('0xceb'):_0x409a0c[_0x54e32d('0xceb')]['appdata']=_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0x4f0')]+'='+_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0x18e0')];break;case _0x54e32d('0x2853'):break;default:_0x51cacd[0x0]=_0x409a0c[_0x54e32d('0xceb')][_0x54e32d('0x4f0')],_0x51cacd[0x1]=_0x409a0c['set'][_0x54e32d('0x18e0')],_0x409a0c['set'][_0x54e32d('0x823')]=_0x51cacd[_0x54e32d('0x45a')]('=');}_0x170b7c(_0x409a0c[_0x54e32d('0xceb')]);}function _0x170b7c(_0x5bc65f){const _0x22bb46=_0xba6e1e;_0x9407b5[_0x22bb46('0x1197')](_0x5bc65f);}}const _0x4af344=_0x4c323a;_0xed7a47[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x96'),'internalroute','api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0xed7a47(_0x34d800,_0x26fdad,_0xf573d,_0x49b5d2,_0x464f70,_0x543d99,_0x5d0665,_0x12350f){const _0x3235e2=_0x36e6f4,_0x46281d=this;_0x46281d['currentUser']=_0x5d0665[_0x3235e2('0x26cd')](),_0x46281d[_0x3235e2('0x61a')]=[],_0x46281d[_0x3235e2('0xcdc')]=_0x3235e2('0xd79')+(_0x49b5d2[_0x3235e2('0x83f')]||_0x49b5d2['app'])[_0x3235e2('0x1387')](),_0x46281d['voicemail']=angular[_0x3235e2('0x225f')](_0x49b5d2),_0x46281d[_0x3235e2('0x243c')]=_0x12350f,_0x46281d[_0x3235e2('0x128b')]={};if(_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x823')])switch(_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x83f')]?_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x83f')][_0x3235e2('0x2574')]():_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x746')][_0x3235e2('0x2574')]()){case _0x3235e2('0x2853'):break;case _0x3235e2('0xded'):{const _0x32a56b=_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x823')][_0x3235e2('0x25c8')](',');_0x46281d['voicemail'][_0x3235e2('0x7ca')]=_0x32a56b[0x0],_0x46281d[_0x3235e2('0x1ee9')]['language']=_0x32a56b[0x1],_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x1634')]=_0x32a56b[_0x3235e2('0x233')](0x2,_0x32a56b[_0x3235e2('0x264b')])[_0x3235e2('0x45a')](',');}break;case'dialogflowv2':{const _0x5ebfd9=_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x823')][_0x3235e2('0x25c8')](',');_0x46281d[_0x3235e2('0x1ee9')]['projectId']=_0x5ebfd9[0x0],_0x46281d['voicemail'][_0x3235e2('0x27f3')]=_0x5ebfd9[0x1],_0x46281d[_0x3235e2('0x1ee9')]['privateKey']=_0x5ebfd9[0x2],_0x46281d['voicemail'][_0x3235e2('0xedb')]=_0x5ebfd9[0x3],_0x46281d['voicemail'][_0x3235e2('0x1634')]=_0x5ebfd9[_0x3235e2('0x233')](0x4,_0x5ebfd9['length'])[_0x3235e2('0x45a')](',');}break;case'amazonlex':{const _0xe4803d=_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x823')][_0x3235e2('0x25c8')](',');_0x46281d['voicemail'][_0x3235e2('0xee6')]=_0xe4803d[0x0],_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x125')]=_0xe4803d[0x1],_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x25a2')]=_0xe4803d[0x2],_0x46281d[_0x3235e2('0x1ee9')]['botname']=_0xe4803d[0x3],_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x1634')]=_0xe4803d[_0x3235e2('0x233')](0x4,_0xe4803d[_0x3235e2('0x264b')])[_0x3235e2('0x45a')](',');}break;case'autoreply':{const _0x13f522=_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x823')][_0x3235e2('0x25c8')](',');_0x46281d['voicemail'][_0x3235e2('0x265e')]=isNaN(_0x13f522[0x0])?_0x13f522[0x0]:parseInt(_0x13f522[0x0],0xa),_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x1640')]=_0x13f522[_0x3235e2('0x233')](0x1,_0x13f522['length'])['join'](',');}break;case'message':_0x46281d[_0x3235e2('0x1ee9')]['text']=_0x46281d['voicemail']['appdata'];break;case _0x3235e2('0xceb'):_0x46281d['voicemail'][_0x3235e2('0x4f0')]=_0x46281d[_0x3235e2('0x1ee9')]['appdata'][_0x3235e2('0x25c8')]('=')[0x0],_0x46281d['voicemail'][_0x3235e2('0x18e0')]=_0x46281d[_0x3235e2('0x1ee9')]['appdata'][_0x3235e2('0x25c8')]('=')[0x1];break;case _0x3235e2('0x1034'):_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x2588')]=_0x46281d[_0x3235e2('0x1ee9')]['appdata'];break;default:{const _0xe8dbb7=_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x823')][_0x3235e2('0x25c8')](',');_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x8d4')]=_0x2cfb05()[_0x3235e2('0x1081')](_0xe8dbb7[0x0])?_0xe8dbb7[0x0]:isNaN(_0xe8dbb7[0x0])?_0xe8dbb7[0x0]:parseInt(_0xe8dbb7[0x0],0xa),_0x46281d[_0x3235e2('0x1ee9')]['options']=_0x2cfb05()[_0x3235e2('0x1081')](_0xe8dbb7[0x1])?_0xe8dbb7[0x1]:isNaN(_0xe8dbb7[0x1])?_0xe8dbb7[0x1]:parseInt(_0xe8dbb7[0x1],0xa);}break;}else{}_0x46281d['voicemail'][_0x3235e2('0x1345')]&&_0x46281d[_0x3235e2('0x1ee9')]['type'][_0x3235e2('0x2574')]()==='outbound'&&_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x83f')][_0x3235e2('0x2574')]()===_0x3235e2('0x2884')&&(_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x265a')]=_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x2026')]?_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x2026')][_0x3235e2('0x25c8')]('$')[0x0]:undefined,_0x46281d[_0x3235e2('0x1ee9')][_0x3235e2('0x1f02')]=_0x46281d[_0x3235e2('0x1ee9')]['callerID']?_0x3235e2('0xa4c')+_0x46281d['voicemail'][_0x3235e2('0x992')]:undefined);_0x46281d[_0x3235e2('0x2aa')]=_0x806aba,_0x46281d['closeDialog']=_0x44f87a,_0x5d0665['hasRole'](_0x3235e2('0xa7c'))?_0x543d99[_0x3235e2('0x8d4')]['get']({'fields':_0x3235e2('0x189e'),'sort':_0x3235e2('0x1cfc'),'nolimit':_0x3235e2('0xf3b')})[_0x3235e2('0xa44')][_0x3235e2('0x1166')](function(_0xac7ac5){const _0x25ac7e=_0x3235e2;_0x46281d['voiceMails']=_0xac7ac5[_0x25ac7e('0x269a')]||[];})[_0x3235e2('0x1a80')](function(_0x2112c3){const _0x3f5e92=_0x3235e2;_0xf573d[_0x3f5e92('0xfc9')]({'title':_0x2112c3[_0x3f5e92('0x52d')]?_0x3f5e92('0x1e21')+_0x2112c3[_0x3f5e92('0x52d')]+_0x3f5e92('0x11e1')+_0x2112c3['statusText']:_0x3f5e92('0x5ec'),'msg':_0x2112c3[_0x3f5e92('0x25f4')]?JSON[_0x3f5e92('0xbac')](_0x2112c3[_0x3f5e92('0x25f4')]):_0x2112c3['toString']()});}):_0x543d99[_0x3235e2('0x8d4')][_0x3235e2('0xd83')]({'fields':_0x3235e2('0x189e'),'sort':_0x3235e2('0x1cfc'),'nolimit':_0x3235e2('0xf3b')})[_0x3235e2('0xa44')]['then'](function(_0x41c7f1){const _0x350dc3=_0x3235e2;_0x46281d[_0x350dc3('0x138')]=_0x41c7f1[_0x350dc3('0x269a')]||[];})['then'](function(){const _0x32f26b=_0x3235e2;return _0x543d99[_0x32f26b('0x17aa')][_0x32f26b('0xd83')]({'userProfileId':_0x46281d[_0x32f26b('0x98')]['userProfileId'],'sectionId':0x196})[_0x32f26b('0xa44')];})[_0x3235e2('0x1166')](function(_0x4676ff){const _0x251ef1=_0x3235e2,_0x560fac=_0x4676ff&&_0x4676ff[_0x251ef1('0x269a')]?_0x4676ff['rows'][0x0]:null;if(!_0x560fac){const _0x2dbf93=[];let _0x5e6b3c=null;_0x46281d['voicemail']&&(_0x5e6b3c=_0x2cfb05()[_0x251ef1('0xc38')](_0x46281d['voiceMails'],{'mailbox':_0x46281d[_0x251ef1('0x1ee9')]['voiceMail']}));for(let _0x3cf93c=0x0;_0x3cf93c<_0x46281d[_0x251ef1('0x138')][_0x251ef1('0x264b')];_0x3cf93c++){_0x5e6b3c&&_0x46281d[_0x251ef1('0x138')][_0x3cf93c]['id']===_0x5e6b3c['id']&&(_0x46281d['voiceMails'][_0x3cf93c][_0x251ef1('0x2378')]=![],_0x2dbf93[_0x251ef1('0x1514')](_0x46281d['voiceMails'][_0x3cf93c]));}_0x46281d[_0x251ef1('0x138')]=_0x2dbf93;}else{if(!_0x560fac[_0x251ef1('0x1a2b')])return _0x543d99[_0x251ef1('0x4b5')]['get']({'sectionId':_0x560fac['id']})[_0x251ef1('0xa44')][_0x251ef1('0x1166')](function(_0x329f74){const _0x26b61e=_0x251ef1,_0x1c7c49=_0x2cfb05()[_0x26b61e('0x2563')](_0x329f74['rows'],function(_0xba86e7){const _0x113e4a=_0x26b61e;return _0x2cfb05()['find'](_0x46281d[_0x113e4a('0x138')],{'id':_0xba86e7[_0x113e4a('0x24e8')]});});let _0x23a7d9=null;_0x46281d['voicemail']&&(_0x23a7d9=_0x2cfb05()[_0x26b61e('0xc38')](_0x46281d[_0x26b61e('0x138')],{'mailbox':_0x46281d[_0x26b61e('0x1ee9')][_0x26b61e('0x8d4')]}));if(_0x23a7d9&&!_0x2cfb05()['some'](_0x1c7c49,['id',_0x23a7d9['id']])){const _0x341364=_0x2cfb05()['find'](_0x46281d[_0x26b61e('0x138')],{'id':_0x23a7d9['id']});_0x341364[_0x26b61e('0x2378')]=![],_0x1c7c49[_0x26b61e('0x1514')](_0x341364);}_0x46281d[_0x26b61e('0x138')]=_0x1c7c49;});}})[_0x3235e2('0x1a80')](function(_0x320ab6){const _0x4dd6ce=_0x3235e2;_0xf573d[_0x4dd6ce('0xfc9')]({'title':_0x320ab6['status']?_0x4dd6ce('0x1e21')+_0x320ab6['status']+_0x4dd6ce('0x11e1')+_0x320ab6[_0x4dd6ce('0xe1b')]:_0x4dd6ce('0xc7'),'msg':_0x320ab6['data']?JSON[_0x4dd6ce('0xbac')](_0x320ab6[_0x4dd6ce('0x25f4')]):_0x320ab6[_0x4dd6ce('0x1586')]()});});function _0x806aba(){const _0x279b7d=_0x3235e2;_0x46281d['errors']=[];const _0x104b33=[];_0x46281d[_0x279b7d('0x1ee9')][_0x279b7d('0x1345')]&&_0x46281d[_0x279b7d('0x1ee9')][_0x279b7d('0x1345')][_0x279b7d('0x2574')]()===_0x279b7d('0x587')&&_0x46281d['voicemail']['appType']===_0x279b7d('0x867')&&(_0x46281d[_0x279b7d('0x1ee9')]['phone']=_0x464f70[_0x279b7d('0x2848')]?(_0x46281d[_0x279b7d('0x1ee9')]['prefix']||'')+'${EXTEN:'+_0x464f70[_0x279b7d('0x2848')]+'}':(_0x46281d['voicemail']['prefix']||'')+'${EXTEN}',_0x464f70[_0x279b7d('0x28cb')]!=='none'?_0x46281d[_0x279b7d('0x1ee9')][_0x279b7d('0xd39')][_0x279b7d('0x2379')](_0x279b7d('0x1059'))<0x0&&(_0x46281d['voicemail'][_0x279b7d('0xd39')]+='U(xcally-mixmonitor-context)'):_0x46281d[_0x279b7d('0x1ee9')][_0x279b7d('0xd39')]=_0x46281d['voicemail'][_0x279b7d('0xd39')][_0x279b7d('0xf3')](_0x279b7d('0x1059'),''));if(_0x46281d['voicemail'][_0x279b7d('0x83f')]&&_0x46281d['voicemail'][_0x279b7d('0x83f')]===_0x279b7d('0x2853')){}else switch((_0x46281d[_0x279b7d('0x1ee9')][_0x279b7d('0x746')]||_0x46281d[_0x279b7d('0x1ee9')][_0x279b7d('0x83f')])[_0x279b7d('0x2574')]()){case _0x279b7d('0xceb'):_0x46281d['voicemail']['appdata']=_0x46281d['voicemail'][_0x279b7d('0x4f0')]+'='+_0x46281d['voicemail'][_0x279b7d('0x18e0')];break;case'custom':break;default:_0x104b33[0x0]=_0x46281d[_0x279b7d('0x1ee9')]['voiceMail'],_0x104b33[0x1]=_0x46281d[_0x279b7d('0x1ee9')][_0x279b7d('0xd39')],_0x46281d['voicemail']['appdata']=_0x104b33[_0x279b7d('0x45a')](',');}_0x44f87a(_0x46281d[_0x279b7d('0x1ee9')]);}function _0x44f87a(_0x58f1d7){const _0x14ab64=_0x3235e2;_0x34d800[_0x14ab64('0x1197')](_0x58f1d7);}}const _0x36cd5a=_0xed7a47;_0x54786a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x12b4'),_0x36e6f4('0x17aa')];function _0x54786a(_0x1ffcb0,_0x564f86,_0x114dca,_0xc53bc1,_0x4b75ac,_0xedd93e,_0x2e54e4,_0x2498fb,_0x2cc38d,_0x122fca,_0x32bb3a,_0x4e8a87){const _0x1a5aa9=_0x36e6f4,_0x906253=this;_0x906253[_0x1a5aa9('0x98')]=_0x122fca['getCurrentUser'](),_0x906253['license']=_0xedd93e,_0x906253[_0x1a5aa9('0xf8a')]=_0x2e54e4,_0x906253[_0x1a5aa9('0x2900')]=_0x906253[_0x1a5aa9('0xf8a')][_0x1a5aa9('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x906253[_0x1a5aa9('0x246b')]=_0x564f86['protocol']()+_0x1a5aa9('0xc51')+_0x564f86[_0x1a5aa9('0x1690')](),_0x906253[_0x1a5aa9('0x12b4')]=_0x32bb3a||_0x1ffcb0[_0x1a5aa9('0x23f')]['internalroute']||{},_0x906253[_0x1a5aa9('0x17aa')]=_0x4e8a87&&_0x4e8a87[_0x1a5aa9('0x240f')]==0x1?_0x4e8a87['rows'][0x0]:null,_0x906253['crudPermissions']=_0x122fca[_0x1a5aa9('0xd87')](_0x906253[_0x1a5aa9('0x17aa')]?_0x906253[_0x1a5aa9('0x17aa')][_0x1a5aa9('0x243c')]:null),_0x906253['hasModulePermissions']={},_0x906253['selectedTab']=_0x1ffcb0[_0x1a5aa9('0x23f')][_0x1a5aa9('0xbe3')]||0x0,_0x906253['alert']=_0x2cc38d['info'],_0x906253[_0x1a5aa9('0x7c2')]=_0x538878,_0x906253[_0x1a5aa9('0x269c')]=_0x517744,_0x122fca['hasRole'](_0x1a5aa9('0xa7c'))?_0x2498fb[_0x1a5aa9('0x23b1')][_0x1a5aa9('0xd83')]({'fields':_0x1a5aa9('0x1776'),'sort':_0x1a5aa9('0x4f0'),'nolimit':'true'})['$promise'][_0x1a5aa9('0x1166')](function(_0x56aab2){_0x906253['contexts']=_0x56aab2['rows']||[];})['catch'](function(_0x4b5aa0){const _0x5aa313=_0x1a5aa9;_0x2cc38d[_0x5aa313('0xfc9')]({'title':_0x4b5aa0[_0x5aa313('0x52d')]?'API:'+_0x4b5aa0[_0x5aa313('0x52d')]+_0x5aa313('0x11e1')+_0x4b5aa0[_0x5aa313('0xe1b')]:'SYSTEM:GET_CONTEXTS','msg':_0x4b5aa0[_0x5aa313('0x25f4')]?JSON['stringify'](_0x4b5aa0[_0x5aa313('0x25f4')]):_0x4b5aa0[_0x5aa313('0x1586')]()});}):_0x2498fb[_0x1a5aa9('0x23b1')][_0x1a5aa9('0xd83')]({'fields':_0x1a5aa9('0x1776'),'sort':'name','nolimit':_0x1a5aa9('0xf3b')})['$promise']['then'](function(_0x1dbd91){const _0x2c82d2=_0x1a5aa9;_0x906253[_0x2c82d2('0x160a')]=_0x1dbd91['rows']||[];})[_0x1a5aa9('0x1166')](function(){const _0x41ee7d=_0x1a5aa9;return _0x2498fb['userProfileSection']['get']({'userProfileId':_0x906253[_0x41ee7d('0x98')][_0x41ee7d('0xb86')],'sectionId':0x195})[_0x41ee7d('0xa44')];})['then'](function(_0xeca467){const _0x9ae485=_0x1a5aa9,_0x36f46d=_0xeca467&&_0xeca467[_0x9ae485('0x269a')]?_0xeca467[_0x9ae485('0x269a')][0x0]:null;if(!_0x36f46d)return _0x2498fb[_0x9ae485('0x23b1')]['get']({'fields':_0x9ae485('0x1776'),'sort':_0x9ae485('0x4f0'),'nolimit':_0x9ae485('0xf3b'),'defaultEntry':0x1})[_0x9ae485('0xa44')]['then'](function(_0x19e7b5){const _0x25714e=_0x9ae485;_0x906253[_0x25714e('0x160a')]=_0x19e7b5[_0x25714e('0x269a')]||[];});else{if(!_0x36f46d[_0x9ae485('0x1a2b')])return _0x2498fb[_0x9ae485('0x4b5')][_0x9ae485('0xd83')]({'sectionId':_0x36f46d['id']})[_0x9ae485('0xa44')][_0x9ae485('0x1166')](function(_0x21352d){const _0x548ca5=_0x9ae485,_0x593121=_0x2cfb05()[_0x548ca5('0x2563')](_0x21352d[_0x548ca5('0x269a')],function(_0x3e5aa1){const _0x3f5a6b=_0x548ca5;return _0x2cfb05()['find'](_0x906253['contexts'],{'id':_0x3e5aa1[_0x3f5a6b('0x24e8')]});});let _0x1eacfc=null;_0x906253['internalroute']&&(_0x1eacfc=_0x2cfb05()[_0x548ca5('0xc38')](_0x906253[_0x548ca5('0x160a')],{'name':_0x906253['internalroute'][_0x548ca5('0xe1c')]}));if(_0x1eacfc&&!_0x2cfb05()[_0x548ca5('0x1798')](_0x593121,['id',_0x1eacfc['id']])){const _0x2f1e72=_0x2cfb05()[_0x548ca5('0xc38')](_0x906253[_0x548ca5('0x160a')],{'id':_0x1eacfc['id']});_0x2f1e72['canSelect']=![],_0x593121[_0x548ca5('0x1514')](_0x2f1e72);}_0x906253['contexts']=_0x593121;});}})[_0x1a5aa9('0x1a80')](function(_0x99379b){const _0x5d56cc=_0x1a5aa9;_0x2cc38d[_0x5d56cc('0xfc9')]({'title':_0x99379b[_0x5d56cc('0x52d')]?_0x5d56cc('0x1e21')+_0x99379b[_0x5d56cc('0x52d')]+'\x20-\x20'+_0x99379b[_0x5d56cc('0xe1b')]:_0x5d56cc('0x482'),'msg':_0x99379b[_0x5d56cc('0x25f4')]?JSON[_0x5d56cc('0xbac')](_0x99379b['data']):_0x99379b[_0x5d56cc('0x1586')]()});});function _0x538878(){const _0x2d37a0=_0x1a5aa9;_0x1ffcb0['go']('app.voice.internalroutes',{},{'reload':_0x2d37a0('0x2b0')});}function _0x517744(){const _0x276f3f=_0x1a5aa9;_0x2498fb[_0x276f3f('0x1deb')]['update']({'id':_0x906253[_0x276f3f('0x12b4')]['id']},_0x906253[_0x276f3f('0x12b4')])[_0x276f3f('0xa44')][_0x276f3f('0x1166')](function(){const _0xc89dd3=_0x276f3f;_0x2cc38d['success']({'title':'InternalRoute\x20updated!','msg':_0x906253[_0xc89dd3('0x12b4')][_0xc89dd3('0x4f0')]?_0x906253['internalroute'][_0xc89dd3('0x4f0')]+_0xc89dd3('0xa17'):''});})['catch'](function(_0x5a3ee0){const _0x367c33=_0x276f3f;_0x2cc38d['error']({'title':_0x5a3ee0[_0x367c33('0x52d')]?_0x367c33('0x1e21')+_0x5a3ee0[_0x367c33('0x52d')]+_0x367c33('0x11e1')+_0x5a3ee0[_0x367c33('0xe1b')]:_0x367c33('0x1af9'),'msg':_0x5a3ee0['data']?JSON[_0x367c33('0xbac')](_0x5a3ee0[_0x367c33('0x25f4')]):_0x5a3ee0[_0x367c33('0x1586')]()});});}}const _0x1e3e23=_0x54786a,_0x3b5da0=_0x2734b2['p']+_0x36e6f4('0x310');_0x7ab5d8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$mdSidenav','$mdDialog','$document','$timeout','$translate',_0x36e6f4('0x2456'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x7ab5d8(_0x14fc92,_0x1608bc,_0x12f988,_0x299b58,_0x445167,_0x2ea8ba,_0x3a933d,_0x3662de,_0x4a64a7,_0x10fb49,_0x19f5de,_0x47b2fd,_0x1bd563,_0x445394,_0x5720a8,_0x215175,_0x4d2953){const _0x528547=_0x36e6f4,_0x2cbb23=this;_0x2cbb23['license']=_0x215175,_0x2cbb23[_0x528547('0xf8a')]=_0x4d2953,_0x2cbb23[_0x528547('0x98')]=_0x5720a8[_0x528547('0x26cd')](),_0x2cbb23[_0x528547('0x2456')]=_0x4a64a7||{'count':0x0,'rows':[]},_0x2cbb23[_0x528547('0x7f')]=_0x10fb49,_0x2cbb23[_0x528547('0x17aa')]=_0x19f5de&&_0x19f5de['count']==0x1?_0x19f5de[_0x528547('0x269a')][0x0]:null,_0x2cbb23[_0x528547('0x243c')]=_0x5720a8['parseCrudPermissions'](_0x2cbb23[_0x528547('0x17aa')]?_0x2cbb23[_0x528547('0x17aa')][_0x528547('0x243c')]:null),_0x2cbb23['table']=_0x528547('0x2456'),_0x2cbb23[_0x528547('0xef5')]='',_0x2cbb23[_0x528547('0x104c')]=null,_0x2cbb23[_0x528547('0x26c4')]=[],_0x2cbb23['query']={'fields':_0x528547('0x22cd'),'type':'internal','sort':'-updatedAt','VoiceExtensionId':'null','limit':0xa,'page':0x1},_0x2cbb23[_0x528547('0x1ff6')]=_0x38927e,_0x2cbb23[_0x528547('0x8d8')]=_0x3758ef,_0x2cbb23[_0x528547('0x103b')]=_0x2c60d7,_0x2cbb23[_0x528547('0x60e')]=_0x3171fa,_0x2cbb23['createOrEditInternalRoute']=_0x376ea0,_0x2cbb23[_0x528547('0x1402')]=_0x1fb4a3,_0x2cbb23[_0x528547('0x14f')]=_0x474439,_0x2cbb23[_0x528547('0x11f8')]=_0x38da1f,_0x2cbb23[_0x528547('0x1965')]=_0x3465d5,_0x2cbb23['selectAllInternalRoutes']=_0x498fdb,_0x5720a8['hasRole'](_0x528547('0xa7c'))?_0x47b2fd[_0x528547('0x23b1')]['get']({'fields':'id,name','sort':_0x528547('0x4f0'),'nolimit':'true'})['$promise'][_0x528547('0x1166')](function(_0x1954bd){const _0x3ce5ce=_0x528547;_0x2cbb23[_0x3ce5ce('0x160a')]=_0x1954bd['rows']||[];})[_0x528547('0x1a80')](function(_0x4dffe4){const _0x31e6e7=_0x528547;_0x445394[_0x31e6e7('0xfc9')]({'title':_0x4dffe4[_0x31e6e7('0x52d')]?_0x31e6e7('0x1e21')+_0x4dffe4['status']+'\x20-\x20'+_0x4dffe4[_0x31e6e7('0xe1b')]:'SYSTEM:GET_CONTEXTS','msg':_0x4dffe4[_0x31e6e7('0x25f4')]?JSON['stringify'](_0x4dffe4[_0x31e6e7('0x25f4')]):_0x4dffe4['toString']()});}):_0x47b2fd[_0x528547('0x23b1')][_0x528547('0xd83')]({'fields':_0x528547('0x1776'),'sort':_0x528547('0x4f0'),'nolimit':_0x528547('0xf3b')})['$promise'][_0x528547('0x1166')](function(_0x2f5420){const _0x583482=_0x528547;_0x2cbb23[_0x583482('0x160a')]=_0x2f5420[_0x583482('0x269a')]||[];})['then'](function(){const _0x9e4da7=_0x528547;return _0x47b2fd['userProfileSection'][_0x9e4da7('0xd83')]({'userProfileId':_0x2cbb23[_0x9e4da7('0x98')][_0x9e4da7('0xb86')],'sectionId':0x195})[_0x9e4da7('0xa44')];})['then'](function(_0x260cbe){const _0x3634e4=_0x528547,_0x3ff8f8=_0x260cbe&&_0x260cbe[_0x3634e4('0x269a')]?_0x260cbe[_0x3634e4('0x269a')][0x0]:null;if(!_0x3ff8f8)return _0x47b2fd[_0x3634e4('0x23b1')]['get']({'fields':_0x3634e4('0x1776'),'sort':_0x3634e4('0x4f0'),'nolimit':_0x3634e4('0xf3b'),'defaultEntry':0x1})[_0x3634e4('0xa44')][_0x3634e4('0x1166')](function(_0x447af8){const _0x593966=_0x3634e4;_0x2cbb23[_0x593966('0x160a')]=_0x447af8[_0x593966('0x269a')]||[];});else{if(!_0x3ff8f8[_0x3634e4('0x1a2b')])return _0x47b2fd[_0x3634e4('0x4b5')][_0x3634e4('0xd83')]({'sectionId':_0x3ff8f8['id']})[_0x3634e4('0xa44')][_0x3634e4('0x1166')](function(_0x11ce1b){const _0x49113f=_0x3634e4,_0x3a95a5=_0x2cfb05()[_0x49113f('0x2563')](_0x11ce1b[_0x49113f('0x269a')],function(_0x48d85d){const _0x1c1dd3=_0x49113f;return _0x2cfb05()['find'](_0x2cbb23[_0x1c1dd3('0x160a')],{'id':_0x48d85d[_0x1c1dd3('0x24e8')]});});let _0x5c41b8=null;_0x2cbb23[_0x49113f('0x12b4')]&&(_0x5c41b8=_0x2cfb05()[_0x49113f('0xc38')](_0x2cbb23[_0x49113f('0x160a')],{'name':_0x2cbb23['internalroute']['context']}));if(_0x5c41b8&&!_0x2cfb05()[_0x49113f('0x1798')](_0x3a95a5,['id',_0x5c41b8['id']])){const _0x5e8956=_0x2cfb05()[_0x49113f('0xc38')](_0x2cbb23[_0x49113f('0x160a')],{'id':_0x5c41b8['id']});_0x5e8956['canSelect']=![],_0x3a95a5[_0x49113f('0x1514')](_0x5e8956);}_0x2cbb23[_0x49113f('0x160a')]=_0x3a95a5;});}})[_0x528547('0x1a80')](function(_0x5f0146){const _0x20254b=_0x528547;_0x445394[_0x20254b('0xfc9')]({'title':_0x5f0146['status']?_0x20254b('0x1e21')+_0x5f0146[_0x20254b('0x52d')]+_0x20254b('0x11e1')+_0x5f0146[_0x20254b('0xe1b')]:_0x20254b('0x482'),'msg':_0x5f0146[_0x20254b('0x25f4')]?JSON['stringify'](_0x5f0146[_0x20254b('0x25f4')]):_0x5f0146['toString']()});});function _0x38927e(_0x34a64f){const _0x45bc41=_0x528547;_0x12f988['go'](_0x45bc41('0x11d5'),{'id':_0x34a64f['id'],'internalroute':_0x34a64f,'crudPermissions':_0x2cbb23['crudPermissions']});}function _0x3758ef(_0x4295fe,_0x82d834){const _0x345641=_0x528547,_0x1d1ef7=_0x445167[_0x345641('0x1d26')]()[_0x345641('0xcdc')](_0x345641('0x288d')+_0x2cfb05()[_0x345641('0xb35')](_0x345641('0x12b4'))+'?')[_0x345641('0xf3c')](_0x345641('0x12b5')+(_0x4295fe[_0x345641('0x4f0')]||_0x345641('0x12b4'))+_0x345641('0xace')+_0x345641('0x3f3'))['ariaLabel'](_0x345641('0x17ae'))['targetEvent'](_0x82d834)['ok']('OK')[_0x345641('0x3f')](_0x345641('0x2d3'));_0x445167[_0x345641('0x1f80')](_0x1d1ef7)[_0x345641('0x1166')](function(){_0x1fb4a3(_0x4295fe);},function(){const _0x2d3852=_0x345641;console[_0x2d3852('0x455')](_0x2d3852('0x2d3'));});}let _0x2aa1e2=!![],_0x57fda3=0x1;_0x14fc92['$watch'](_0x528547('0x12d8'),function(_0x51f268,_0xb1db9f){const _0x5a1c4a=_0x528547;_0x2aa1e2?_0x3a933d(function(){_0x2aa1e2=![];}):(!_0xb1db9f&&(_0x57fda3=_0x2cbb23['query'][_0x5a1c4a('0x1a43')]),_0x51f268!==_0xb1db9f&&(_0x2cbb23['query'][_0x5a1c4a('0x1a43')]=0x1),!_0x51f268&&(_0x2cbb23[_0x5a1c4a('0x2218')]['page']=_0x57fda3),_0x2cbb23[_0x5a1c4a('0x60e')]());});function _0x2c60d7(_0x8cdfa4){const _0x5be01f=_0x528547;_0x2cbb23[_0x5be01f('0x2456')]=_0x8cdfa4||{'count':0x0,'rows':[]};}function _0x3171fa(){const _0x124074=_0x528547;_0x2cbb23[_0x124074('0x2218')]['offset']=(_0x2cbb23[_0x124074('0x2218')][_0x124074('0x1a43')]-0x1)*_0x2cbb23[_0x124074('0x2218')][_0x124074('0x163f')],_0x5720a8['hasRole'](_0x124074('0xa7c'))?_0x2cbb23[_0x124074('0x1f48')]=_0x47b2fd['voiceExtension']['get'](_0x2cbb23[_0x124074('0x2218')],_0x2c60d7)[_0x124074('0xa44')]:(_0x2cbb23[_0x124074('0x2218')]['id']=_0x2cbb23[_0x124074('0x7f')]['id'],_0x2cbb23['query']['section']=_0x124074('0x21ce'),_0x2cbb23[_0x124074('0x1f48')]=_0x47b2fd[_0x124074('0x7f')][_0x124074('0x263a')](_0x2cbb23[_0x124074('0x2218')],_0x2c60d7)[_0x124074('0xa44')]);}function _0x376ea0(_0x2c4bdd,_0x59ce9f){const _0x1623f5=_0x528547;_0x445167[_0x1623f5('0x1f80')]({'controller':_0x1623f5('0xe87'),'controllerAs':'vm','templateUrl':_0x3b5da0,'parent':angular[_0x1623f5('0x1194')](_0x2ea8ba['body']),'targetEvent':_0x2c4bdd,'clickOutsideToClose':!![],'locals':{'internalroute':_0x59ce9f,'internalroutes':_0x2cbb23[_0x1623f5('0x2456')][_0x1623f5('0x269a')],'license':_0x2cbb23['license'],'setting':_0x2cbb23[_0x1623f5('0xf8a')],'crudPermissions':_0x2cbb23['crudPermissions']}});}function _0x1fb4a3(_0x5a42cb){const _0x3dcc75=_0x528547;_0x47b2fd[_0x3dcc75('0x1deb')][_0x3dcc75('0x906')]({'id':_0x5a42cb['id']})[_0x3dcc75('0xa44')][_0x3dcc75('0x1166')](function(){const _0x557b2a=_0x3dcc75;_0x2cfb05()['remove'](_0x2cbb23['internalroutes']['rows'],{'id':_0x5a42cb['id']}),_0x2cbb23[_0x557b2a('0x2456')]['count']-=0x1,!_0x2cbb23['internalroutes'][_0x557b2a('0x269a')]['length']&&_0x2cbb23['getInternalRoutes'](),_0x445394['success']({'title':_0x2cfb05()[_0x557b2a('0xb35')](_0x557b2a('0x1881'))+_0x557b2a('0x2b6'),'msg':_0x5a42cb[_0x557b2a('0x4f0')]?_0x5a42cb[_0x557b2a('0x4f0')]+_0x557b2a('0x7cd'):''});})[_0x3dcc75('0x1a80')](function(_0x116343){const _0x2f9712=_0x3dcc75;if(_0x116343['data']&&_0x116343[_0x2f9712('0x25f4')]['errors']&&_0x116343['data']['errors'][_0x2f9712('0x264b')]){_0x2cbb23['errors']=_0x116343[_0x2f9712('0x25f4')][_0x2f9712('0x61a')]||[{'message':_0x116343[_0x2f9712('0x1586')](),'type':'SYSTEM:DELETEvoiceExtension'}];for(let _0x553855=0x0;_0x553855<_0x116343['data'][_0x2f9712('0x61a')]['length'];_0x553855++){_0x445394[_0x2f9712('0xfc9')]({'title':_0x116343['data'][_0x2f9712('0x61a')][_0x553855][_0x2f9712('0x1345')],'msg':_0x116343[_0x2f9712('0x25f4')]['errors'][_0x553855][_0x2f9712('0x1e70')]});}}else _0x445394['error']({'title':_0x116343[_0x2f9712('0x52d')]?'API:'+_0x116343[_0x2f9712('0x52d')]+_0x2f9712('0x11e1')+_0x116343[_0x2f9712('0xe1b')]:_0x2f9712('0xa97'),'msg':_0x116343[_0x2f9712('0x25f4')]?JSON[_0x2f9712('0xbac')](_0x116343[_0x2f9712('0x25f4')][_0x2f9712('0x1e70')]):_0x116343[_0x2f9712('0x1e70')]||_0x116343[_0x2f9712('0x1586')]()});});}function _0x474439(){const _0x744fad=_0x528547,_0x519891=angular[_0x744fad('0x225f')](_0x2cbb23[_0x744fad('0x26c4')]);return _0x2cbb23[_0x744fad('0x26c4')]=[],_0x519891;}function _0x38da1f(_0x2987f5){const _0x859878=_0x528547,_0x350ba6=_0x445167[_0x859878('0x1d26')]()['title'](_0x859878('0x13b9'))[_0x859878('0xf3c')](_0x859878('0x12b5')+_0x2cbb23[_0x859878('0x26c4')][_0x859878('0x264b')]+'\x20selected
'+'\x20will\x20be\x20deleted.')[_0x859878('0x8e8')](_0x859878('0x1260'))[_0x859878('0x203b')](_0x2987f5)['ok']('OK')[_0x859878('0x3f')](_0x859878('0x2d3'));_0x445167['show'](_0x350ba6)[_0x859878('0x1166')](function(){const _0x2a132c=_0x859878;_0x2cbb23[_0x2a132c('0x26c4')][_0x2a132c('0x2782')](function(_0x4b6623){_0x1fb4a3(_0x4b6623);}),_0x2cbb23[_0x2a132c('0x26c4')]=[];});}function _0x3465d5(){const _0x2a03d4=_0x528547;_0x2cbb23[_0x2a03d4('0x26c4')]=[];}function _0x498fdb(){const _0x1330c0=_0x528547;_0x2cbb23[_0x1330c0('0x26c4')]=_0x2cbb23[_0x1330c0('0x2456')][_0x1330c0('0x269a')];}}const _0x40b932=_0x7ab5d8;_0x5b35db['$inject']=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'musiconholds','musiconhold',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x5b35db(_0x1f8813,_0x12a60c,_0x458da0,_0x4fbc9c,_0x266b3b,_0x330e9e,_0x374281,_0x596668,_0x1a4dbf,_0x2687ff,_0x4b72f0,_0x11b2a6,_0x440dce,_0x75a58b){const _0xf50065=_0x36e6f4,_0x2fba73=this;_0x2fba73[_0xf50065('0x98')]=_0x4b72f0[_0xf50065('0x26cd')](),_0x2fba73[_0xf50065('0x61a')]=[],_0x2fba73[_0xf50065('0xf8a')]=_0x440dce,_0x2fba73['license']=_0x11b2a6,_0x2fba73['crudPermissions']=_0x75a58b,_0x2fba73[_0xf50065('0x128b')]={},_0x2fba73['passwordPattern']=_0x2fba73['setting']&&_0x2fba73[_0xf50065('0xf8a')][_0xf50065('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2fba73['title']=_0xf50065('0x20cf'),_0x2fba73[_0xf50065('0x98e')]=angular['copy'](_0x1a4dbf),_0x2fba73[_0xf50065('0x10ad')]=_0x596668,_0x2fba73[_0xf50065('0x18f0')]=![];!_0x2fba73[_0xf50065('0x98e')]&&(_0x2fba73[_0xf50065('0x98e')]={'mode':_0xf50065('0x911')},_0x2fba73[_0xf50065('0xcdc')]=_0xf50065('0x1df'),_0x2fba73[_0xf50065('0x18f0')]=!![]);_0x2fba73['addNewMusicOnHold']=_0x48f107,_0x2fba73['saveMusicOnHold']=_0x738813,_0x2fba73[_0xf50065('0x265c')]=_0xbeb585,_0x2fba73[_0xf50065('0x1a9c')]=_0x46b6b9,_0x2fba73[_0xf50065('0x24a0')]=_0x3b28c9;function _0x48f107(){const _0x28e62e=_0xf50065;_0x2fba73[_0x28e62e('0x61a')]=[],_0x2687ff[_0x28e62e('0x8d3')][_0x28e62e('0x9cc')](_0x2fba73[_0x28e62e('0x98e')])[_0x28e62e('0xa44')][_0x28e62e('0x1166')](function(_0xa91703){const _0x9e8ae9=_0x28e62e;_0x2fba73[_0x9e8ae9('0x10ad')][_0x9e8ae9('0x2450')](_0xa91703[_0x9e8ae9('0x2876')]()),_0x374281[_0x9e8ae9('0x103b')]({'title':_0x9e8ae9('0x4b9'),'msg':_0x2fba73[_0x9e8ae9('0x98e')][_0x9e8ae9('0x4f0')]?_0x2fba73[_0x9e8ae9('0x98e')][_0x9e8ae9('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x3b28c9(_0xa91703);})[_0x28e62e('0x1a80')](function(_0x35e173){const _0x23369f=_0x28e62e;if(_0x35e173[_0x23369f('0x25f4')]&&_0x35e173[_0x23369f('0x25f4')][_0x23369f('0x61a')]&&_0x35e173[_0x23369f('0x25f4')][_0x23369f('0x61a')]['length']){_0x2fba73[_0x23369f('0x61a')]=_0x35e173[_0x23369f('0x25f4')][_0x23369f('0x61a')]||[{'message':_0x35e173[_0x23369f('0x1586')](),'type':_0x23369f('0x3ea')}];for(let _0xb76ee0=0x0;_0xb76ee0<_0x35e173[_0x23369f('0x25f4')][_0x23369f('0x61a')][_0x23369f('0x264b')];_0xb76ee0+=0x1){_0x374281[_0x23369f('0xfc9')]({'title':_0x35e173[_0x23369f('0x25f4')]['errors'][_0xb76ee0][_0x23369f('0x1345')],'msg':_0x35e173[_0x23369f('0x25f4')]['errors'][_0xb76ee0][_0x23369f('0x1e70')]});}}else _0x374281[_0x23369f('0xfc9')]({'title':_0x35e173[_0x23369f('0x52d')]?'API:'+_0x35e173[_0x23369f('0x52d')]+_0x23369f('0x11e1')+_0x35e173[_0x23369f('0xe1b')]:_0x23369f('0x3ea'),'msg':_0x35e173['data']?JSON['stringify'](_0x35e173[_0x23369f('0x25f4')][_0x23369f('0x1e70')]):_0x35e173[_0x23369f('0x1586')]()});});}function _0x738813(){const _0x7bdd0d=_0xf50065;_0x2fba73[_0x7bdd0d('0x61a')]=[],_0x2687ff[_0x7bdd0d('0x8d3')][_0x7bdd0d('0x1449')]({'id':_0x2fba73[_0x7bdd0d('0x98e')]['id']},_0x2fba73['musiconhold'])[_0x7bdd0d('0xa44')]['then'](function(_0x37a2f5){const _0x1dd4b3=_0x7bdd0d,_0x3fe485=_0x2cfb05()[_0x1dd4b3('0xc38')](_0x2fba73[_0x1dd4b3('0x10ad')],{'id':_0x37a2f5['id']});_0x3fe485&&_0x2cfb05()['merge'](_0x3fe485,_0x2cfb05()[_0x1dd4b3('0x1a08')](_0x37a2f5[_0x1dd4b3('0x2876')](),_0x2cfb05()[_0x1dd4b3('0x14a4')](_0x3fe485))),_0x374281[_0x1dd4b3('0x103b')]({'title':_0x1dd4b3('0x2624'),'msg':_0x2fba73[_0x1dd4b3('0x98e')][_0x1dd4b3('0x4f0')]?_0x2fba73[_0x1dd4b3('0x98e')][_0x1dd4b3('0x4f0')]+_0x1dd4b3('0x7d'):''}),_0x3b28c9(_0x37a2f5);})['catch'](function(_0x4be3ff){const _0x21ce09=_0x7bdd0d;if(_0x4be3ff['data']&&_0x4be3ff[_0x21ce09('0x25f4')][_0x21ce09('0x61a')]&&_0x4be3ff[_0x21ce09('0x25f4')][_0x21ce09('0x61a')][_0x21ce09('0x264b')]){_0x2fba73[_0x21ce09('0x61a')]=_0x4be3ff[_0x21ce09('0x25f4')][_0x21ce09('0x61a')]||[{'message':_0x4be3ff['toString'](),'type':_0x21ce09('0x14d3')}];for(let _0x11603f=0x0;_0x11603f<_0x4be3ff['data']['errors'][_0x21ce09('0x264b')];_0x11603f++){_0x374281[_0x21ce09('0xfc9')]({'title':_0x4be3ff[_0x21ce09('0x25f4')]['errors'][_0x11603f][_0x21ce09('0x1345')],'msg':_0x4be3ff[_0x21ce09('0x25f4')]['errors'][_0x11603f][_0x21ce09('0x1e70')]});}}else _0x374281[_0x21ce09('0xfc9')]({'title':_0x4be3ff[_0x21ce09('0x52d')]?'API:'+_0x4be3ff['status']+'\x20-\x20'+_0x4be3ff[_0x21ce09('0xe1b')]:_0x21ce09('0x14d3'),'msg':_0x4be3ff[_0x21ce09('0x25f4')]?JSON[_0x21ce09('0xbac')](_0x4be3ff[_0x21ce09('0x25f4')][_0x21ce09('0x1e70')]):_0x4be3ff['toString']()});});}function _0xbeb585(_0x284e17){const _0x15574c=_0xf50065;_0x2fba73[_0x15574c('0x61a')]=[];const _0x47fe58=_0x4fbc9c[_0x15574c('0x1d26')]()['title'](_0x15574c('0x7fb'))['content']('The\x20musiconhold\x20will\x20be\x20deleted.')['ariaLabel'](_0x15574c('0x18a3'))['ok'](_0x15574c('0x18'))[_0x15574c('0x3f')]('Cancel')[_0x15574c('0x203b')](_0x284e17);_0x4fbc9c['show'](_0x47fe58)['then'](function(){const _0x46baef=_0x15574c;_0x2687ff[_0x46baef('0x8d3')][_0x46baef('0x906')]({'id':_0x2fba73[_0x46baef('0x98e')]['id']})[_0x46baef('0xa44')][_0x46baef('0x1166')](function(){const _0x131e7e=_0x46baef;_0x2cfb05()['remove'](_0x2fba73[_0x131e7e('0x10ad')],{'id':_0x2fba73[_0x131e7e('0x98e')]['id']}),_0x374281[_0x131e7e('0x103b')]({'title':'MusicOnHold\x20properly\x20deleted!','msg':(_0x2fba73[_0x131e7e('0x98e')][_0x131e7e('0x4f0')]||'musiconhold')+_0x131e7e('0x7cd')}),_0x3b28c9(_0x2fba73[_0x131e7e('0x98e')]);})['catch'](function(_0x2f70cc){const _0x11bc90=_0x46baef;if(_0x2f70cc[_0x11bc90('0x25f4')]&&_0x2f70cc[_0x11bc90('0x25f4')][_0x11bc90('0x61a')]&&_0x2f70cc[_0x11bc90('0x25f4')][_0x11bc90('0x61a')][_0x11bc90('0x264b')]){_0x2fba73['errors']=_0x2f70cc[_0x11bc90('0x25f4')][_0x11bc90('0x61a')]||[{'message':_0x2f70cc['toString'](),'type':'api.voiceMusicOnHold.delete'}];for(let _0x1e8593=0x0;_0x1e8593<_0x2f70cc[_0x11bc90('0x25f4')][_0x11bc90('0x61a')][_0x11bc90('0x264b')];_0x1e8593++){_0x374281[_0x11bc90('0xfc9')]({'title':_0x2f70cc[_0x11bc90('0x25f4')][_0x11bc90('0x61a')][_0x1e8593]['type'],'msg':_0x2f70cc['data'][_0x11bc90('0x61a')][_0x1e8593]['message']});}}else _0x374281['error']({'title':_0x2f70cc[_0x11bc90('0x52d')]?_0x11bc90('0x1e21')+_0x2f70cc[_0x11bc90('0x52d')]+_0x11bc90('0x11e1')+_0x2f70cc['statusText']:_0x11bc90('0x219c'),'msg':_0x2f70cc[_0x11bc90('0x25f4')]?JSON[_0x11bc90('0xbac')](_0x2f70cc['data'][_0x11bc90('0x1e70')]):_0x2f70cc['message']||_0x2f70cc['toString']()});});},function(){});}function _0x46b6b9(_0x181ac4){return _0x181ac4===null?undefined:new Date(_0x181ac4);}function _0x3b28c9(_0x31a1d1){const _0x445199=_0xf50065;_0x4fbc9c[_0x445199('0x1197')](_0x31a1d1);}}const _0x550e5f=_0x5b35db,_0x3dc7ef=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/musiconholds/edit/mohSounds/dialog.html/dialog.html';_0x3fcde7[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),'$scope',_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'toasty','api','Auth'];function _0x3fcde7(_0x4caccd,_0x185525,_0x11438b,_0x4bfc10,_0x84976c,_0x497158,_0x135d7f,_0x93a119,_0x117fd4,_0x5133ec,_0xd25a4){const _0x142136=_0x36e6f4,_0x53ef65=this;_0x53ef65[_0x142136('0x98')]=_0xd25a4[_0x142136('0x26cd')](),_0x53ef65[_0x142136('0x98e')]={},_0x53ef65[_0x142136('0x7a2')]={'count':0x0,'rows':[]},_0x53ef65[_0x142136('0x197e')]=[],_0x53ef65[_0x142136('0x243c')],_0x53ef65[_0x142136('0x2218')]={'fields':_0x142136('0x97d'),'limit':0xa,'page':0x1},_0x53ef65[_0x142136('0x24d5')]=_0x3c64ba,_0x53ef65[_0x142136('0x8a2')]=_0x252acf,_0x53ef65[_0x142136('0x561')]=_0xae67a8,_0x53ef65[_0x142136('0x103b')]=_0x1ffacb,_0x53ef65['getMusicOnHoldMohSounds']=_0xe8711,_0x53ef65[_0x142136('0x1253')]=_0x13f5c0,_0x53ef65[_0x142136('0x2203')]=_0x3b0623,_0x53ef65[_0x142136('0x22b0')]=_0x133310,_0x53ef65[_0x142136('0x1f40')]=_0x4996ba,_0xd25a4['hasRole'](_0x142136('0xa7c'))?_0x5133ec[_0x142136('0x960')][_0x142136('0xd83')]({'fields':_0x142136('0x1776'),'sort':_0x142136('0x4f0')})[_0x142136('0xa44')][_0x142136('0x1166')](function(_0x3518ed){const _0x283fc8=_0x142136;_0x53ef65[_0x283fc8('0x137')]=_0x3518ed['rows']||[];})[_0x142136('0x1a80')](function(_0x27df23){const _0x3dde41=_0x142136;_0x117fd4[_0x3dde41('0xfc9')]({'title':_0x27df23[_0x3dde41('0x52d')]?_0x3dde41('0x1e21')+_0x27df23[_0x3dde41('0x52d')]+'\x20-\x20'+_0x27df23[_0x3dde41('0xe1b')]:_0x3dde41('0x140a'),'msg':_0x27df23[_0x3dde41('0x25f4')]?JSON['stringify'](_0x27df23[_0x3dde41('0x25f4')]):_0x27df23[_0x3dde41('0x1586')]()});}):_0x5133ec[_0x142136('0x960')]['get']({'fields':_0x142136('0x1776'),'sort':_0x142136('0x4f0')})['$promise'][_0x142136('0x1166')](function(_0x59e6a5){const _0x69a36c=_0x142136;_0x53ef65[_0x69a36c('0x137')]=_0x59e6a5[_0x69a36c('0x269a')]||[];})[_0x142136('0x1166')](function(){const _0x4199da=_0x142136;return _0x5133ec[_0x4199da('0x17aa')][_0x4199da('0xd83')]({'userProfileId':_0x53ef65[_0x4199da('0x98')]['userProfileId'],'sectionId':0x3ef})[_0x4199da('0xa44')];})['then'](function(_0x36cde3){const _0x542359=_0x142136,_0x3c9e54=_0x36cde3&&_0x36cde3['rows']?_0x36cde3['rows'][0x0]:null;if(!_0x3c9e54){const _0x412d02=[];let _0x5a6ed7=null;_0x53ef65[_0x542359('0x98e')]&&(_0x5a6ed7=_0x2cfb05()['find'](_0x53ef65[_0x542359('0x137')],{'id':Number(_0x53ef65[_0x542359('0x98e')]['id'])}));for(let _0x4e55fa=0x0;_0x4e55fa<_0x53ef65[_0x542359('0x137')][_0x542359('0x264b')];_0x4e55fa++){_0x5a6ed7&&_0x53ef65[_0x542359('0x137')][_0x4e55fa]['id']===_0x5a6ed7['id']&&(_0x53ef65['sounds'][_0x4e55fa]['canSelect']=![],_0x412d02[_0x542359('0x1514')](_0x53ef65[_0x542359('0x137')][_0x4e55fa]));}_0x53ef65[_0x542359('0x137')]=_0x412d02;}else{if(!_0x3c9e54[_0x542359('0x1a2b')])return _0x5133ec['userProfileResource'][_0x542359('0xd83')]({'sectionId':_0x3c9e54['id']})['$promise']['then'](function(_0x497a52){const _0x247e27=_0x542359,_0x1c21e5=_0x2cfb05()['map'](_0x497a52[_0x247e27('0x269a')],function(_0x18d8fa){const _0x53299b=_0x247e27;return _0x2cfb05()[_0x53299b('0xc38')](_0x53ef65[_0x53299b('0x137')],{'id':_0x18d8fa[_0x53299b('0x24e8')]});});let _0x4faf4d=null;_0x53ef65[_0x247e27('0x98e')]&&(_0x4faf4d=_0x2cfb05()['find'](_0x53ef65[_0x247e27('0x137')],{'id':Number(_0x53ef65[_0x247e27('0x98e')]['id'])}));if(_0x4faf4d&&!_0x2cfb05()[_0x247e27('0x1798')](_0x1c21e5,['id',_0x4faf4d['id']])){const _0xe2f613=_0x2cfb05()[_0x247e27('0xc38')](_0x53ef65['sounds'],{'id':_0x4faf4d['id']});_0xe2f613['canSelect']=![],_0x1c21e5[_0x247e27('0x1514')](_0xe2f613);}_0x53ef65[_0x247e27('0x137')]=_0x1c21e5;});}})['catch'](function(_0x1b668e){const _0x50fc98=_0x142136;_0x117fd4[_0x50fc98('0xfc9')]({'title':_0x1b668e[_0x50fc98('0x52d')]?'API:'+_0x1b668e['status']+_0x50fc98('0x11e1')+_0x1b668e[_0x50fc98('0xe1b')]:'SYSTEM:GETsounds','msg':_0x1b668e[_0x50fc98('0x25f4')]?JSON[_0x50fc98('0xbac')](_0x1b668e[_0x50fc98('0x25f4')]):_0x1b668e[_0x50fc98('0x1586')]()});});function _0x3c64ba(_0x4109b4,_0x236729){const _0x32042f=_0x142136;_0x53ef65[_0x32042f('0x98e')]=_0x4109b4,_0x53ef65[_0x32042f('0x243c')]=typeof _0x236729!==_0x32042f('0x1048')?_0x236729:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x53ef65['query'][_0x32042f('0x193b')]=_0x53ef65[_0x32042f('0x98e')]['id'],_0x53ef65[_0x32042f('0x2218')]['id']=_0x53ef65[_0x32042f('0x98e')]['id'],_0xe8711();}function _0xae67a8(_0x3c50d0,_0x2c2ebf,_0x2a2192){const _0xa7556d=_0x142136;return _0x5133ec['sound'][_0xa7556d('0x2ad')]({'id':_0x3c50d0['id'],'exists':!![],'attachments':_0x2a2192})['$promise'][_0xa7556d('0x1166')](function(_0x30f8e9){const _0x217fc9=_0xa7556d,_0x17f848=[_0x30f8e9[_0x217fc9('0x20ed')]];let _0x2c7825='mohSound'+_0x3c50d0['id'];const _0x233e15=new Blob(_0x17f848,{'type':_0x30f8e9['type']});_0x2c7825=_0x3c50d0[_0x217fc9('0x237')]?_0x3c50d0['save_name']+'.'+_0x3c50d0[_0x217fc9('0x237')]:_0x3c50d0[_0x217fc9('0x28d5')];const _0x3ad20b=window[_0x217fc9('0x136d')][_0x217fc9('0xdd')]('a');_0x3ad20b[_0x217fc9('0xffd')](_0x217fc9('0x14f9'),URL[_0x217fc9('0x215a')](_0x233e15)),_0x3ad20b[_0x217fc9('0xffd')](_0x217fc9('0x2ad'),_0x2c7825),document[_0x217fc9('0x8d2')][_0x217fc9('0x21a')](_0x3ad20b),_0x3ad20b[_0x217fc9('0x3b4')]();})[_0xa7556d('0x1a80')](function(_0x2e2e68){const _0x4878af=_0xa7556d;if(_0x2e2e68['data']&&_0x2e2e68[_0x4878af('0x25f4')][_0x4878af('0x61a')]&&_0x2e2e68[_0x4878af('0x25f4')][_0x4878af('0x61a')][_0x4878af('0x264b')])for(let _0x3820e3=0x0;_0x3820e3<_0x2e2e68[_0x4878af('0x25f4')][_0x4878af('0x61a')][_0x4878af('0x264b')];_0x3820e3+=0x1){_0x117fd4[_0x4878af('0xfc9')]({'title':_0x2e2e68[_0x4878af('0x25f4')][_0x4878af('0x61a')][_0x3820e3]['type'],'msg':_0x2e2e68[_0x4878af('0x25f4')]['errors'][_0x3820e3][_0x4878af('0x1e70')]});}else _0x117fd4[_0x4878af('0xfc9')]({'title':_0x2e2e68['status']?'API:'+_0x2e2e68[_0x4878af('0x52d')]+_0x4878af('0x11e1')+_0x2e2e68[_0x4878af('0xe1b')]:_0x4878af('0x3ea'),'msg':_0x2e2e68[_0x4878af('0x25f4')]?JSON[_0x4878af('0xbac')](_0x2e2e68[_0x4878af('0x25f4')][_0x4878af('0x1e70')]):_0x2e2e68['toString']()});});}function _0x252acf(_0x5ada58,_0x171b1e){const _0x12f761=_0x142136,_0x4f4504=_0x135d7f[_0x12f761('0x1d26')]()['title'](_0x12f761('0x797'))['htmlContent'](_0x12f761('0x12b5')+(_0x5ada58[_0x12f761('0x4f0')]||_0x5ada58['id']&&_0x2cfb05()['upperFirst'](_0x12f761('0x1a1e'))+_0x5ada58['id']||_0x12f761('0x2b8'))+_0x12f761('0xace')+'\x20will\x20be\x20deleted.')[_0x12f761('0x8e8')](_0x12f761('0x573'))[_0x12f761('0x203b')](_0x171b1e)['ok']('OK')[_0x12f761('0x3f')](_0x12f761('0x2d3'));_0x135d7f[_0x12f761('0x1f80')](_0x4f4504)[_0x12f761('0x1166')](function(){_0x133310(_0x5ada58);},function(){const _0x3b77d4=_0x12f761;console[_0x3b77d4('0x455')](_0x3b77d4('0x2d3'));});}function _0x1ffacb(_0x12c1bb){const _0x53c46d=_0x142136;_0x53ef65[_0x53c46d('0x7a2')]=_0x12c1bb||{'count':0x0,'rows':[]};}function _0xe8711(){const _0x1af10c=_0x142136;_0x53ef65['query'][_0x1af10c('0x1098')]=(_0x53ef65[_0x1af10c('0x2218')][_0x1af10c('0x1a43')]-0x1)*_0x53ef65['query'][_0x1af10c('0x163f')],_0x53ef65['promise']=_0x5133ec[_0x1af10c('0x8d3')][_0x1af10c('0x30a')](_0x53ef65['query'],_0x1ffacb)[_0x1af10c('0xa44')];}function _0x13f5c0(_0x4fa17e,_0x348d6f){const _0x3035ea=_0x142136;_0x135d7f[_0x3035ea('0x1f80')]({'controller':_0x3035ea('0xb30'),'controllerAs':'vm','templateUrl':_0x3dc7ef,'parent':angular[_0x3035ea('0x1194')](_0x93a119[_0x3035ea('0x8d2')]),'targetEvent':_0x4fa17e,'clickOutsideToClose':!![],'locals':{'musiconhold':_0x53ef65[_0x3035ea('0x98e')],'mohSound':_0x348d6f,'mohSounds':_0x53ef65[_0x3035ea('0x7a2')][_0x3035ea('0x269a')],'license':null,'setting':null,'crudPermissions':_0x53ef65[_0x3035ea('0x243c')]}});}function _0x133310(_0x4cc79d){const _0x3e5407=_0x142136;_0x5133ec['voiceMusicOnHold'][_0x3e5407('0x1d94')]({'id':_0x11438b[_0x3e5407('0x23f')]['id'],'id2':_0x4cc79d['id']})['$promise'][_0x3e5407('0x1166')](function(){const _0x1bb19b=_0x3e5407;_0x2cfb05()['remove'](_0x53ef65[_0x1bb19b('0x7a2')]['rows'],{'id':_0x4cc79d['id']}),_0x53ef65[_0x1bb19b('0x7a2')][_0x1bb19b('0x240f')]-=0x1,!_0x53ef65[_0x1bb19b('0x7a2')][_0x1bb19b('0x269a')][_0x1bb19b('0x264b')]&&_0xe8711(),_0x117fd4[_0x1bb19b('0x103b')]({'title':_0x1bb19b('0x20fa'),'msg':_0x4cc79d[_0x1bb19b('0x4f0')]?_0x4cc79d[_0x1bb19b('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0x3e5407('0x1a80')](function(_0xb210ca){const _0x56836a=_0x3e5407;if(_0xb210ca[_0x56836a('0x25f4')]&&_0xb210ca[_0x56836a('0x25f4')][_0x56836a('0x61a')]&&_0xb210ca[_0x56836a('0x25f4')][_0x56836a('0x61a')][_0x56836a('0x264b')]){_0x53ef65[_0x56836a('0x61a')]=_0xb210ca['data'][_0x56836a('0x61a')]||[{'message':_0xb210ca[_0x56836a('0x1586')](),'type':_0x56836a('0x407')}];for(let _0x39044b=0x0;_0x39044b<_0xb210ca[_0x56836a('0x25f4')][_0x56836a('0x61a')][_0x56836a('0x264b')];_0x39044b++){_0x117fd4[_0x56836a('0xfc9')]({'title':_0xb210ca[_0x56836a('0x25f4')]['errors'][_0x39044b][_0x56836a('0x1345')],'msg':_0xb210ca['data'][_0x56836a('0x61a')][_0x39044b]['message']});}}else _0x117fd4[_0x56836a('0xfc9')]({'title':_0xb210ca[_0x56836a('0x52d')]?_0x56836a('0x1e21')+_0xb210ca[_0x56836a('0x52d')]+_0x56836a('0x11e1')+_0xb210ca[_0x56836a('0xe1b')]:_0x56836a('0x407'),'msg':_0xb210ca[_0x56836a('0x25f4')]?JSON[_0x56836a('0xbac')](_0xb210ca[_0x56836a('0x25f4')][_0x56836a('0x1e70')]):_0xb210ca[_0x56836a('0x1e70')]||_0xb210ca[_0x56836a('0x1586')]()});});}function _0x3b0623(){const _0x1c8de5=_0x142136,_0x5c6b66=angular['copy'](_0x53ef65['selectedMusicOnHoldMohSounds']);return _0x53ef65[_0x1c8de5('0x197e')]=[],_0x5c6b66;}function _0x4996ba(_0x24b955){const _0x4b82f3=_0x142136,_0x98314b=_0x135d7f[_0x4b82f3('0x1d26')]()[_0x4b82f3('0xcdc')](_0x4b82f3('0xd3d'))['htmlContent'](_0x4b82f3('0x12b5')+_0x53ef65[_0x4b82f3('0x197e')]['length']+_0x4b82f3('0x196d')+_0x4b82f3('0x3f3'))['ariaLabel'](_0x4b82f3('0x5fa'))[_0x4b82f3('0x203b')](_0x24b955)['ok']('OK')[_0x4b82f3('0x3f')](_0x4b82f3('0x2d3'));_0x135d7f['show'](_0x98314b)[_0x4b82f3('0x1166')](function(){const _0x32b4f8=_0x4b82f3;_0x53ef65['selectedMusicOnHoldMohSounds'][_0x32b4f8('0x2782')](function(_0x5dd02c){_0x133310(_0x5dd02c);}),_0x53ef65['selectedMusicOnHoldMohSounds']=[];});}let _0x43d271=!![],_0x250500=0x1;_0x185525[_0x142136('0xe83')](_0x142136('0x28b4'),function(_0x30977f,_0x27b95e){const _0x2e6bc9=_0x142136;_0x43d271?_0x497158(function(){_0x43d271=![];}):(!_0x27b95e&&(_0x250500=_0x53ef65['query'][_0x2e6bc9('0x1a43')]),_0x30977f!==_0x27b95e&&(_0x53ef65[_0x2e6bc9('0x2218')][_0x2e6bc9('0x1a43')]=0x1),!_0x30977f&&(_0x53ef65['query']['page']=_0x250500),_0xe8711());});}const _0x26de84=_0x3fcde7;_0x48f38e['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x339'),_0x36e6f4('0x2b8'),_0x36e6f4('0x19e3'),'Auth','license',_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x48f38e(_0x488e66,_0x16abf9,_0x5bc33c,_0x3a60aa,_0x4f6c14,_0x50b3d8,_0x3a5324,_0x3b58df,_0x2e5f3b,_0x3fcc32,_0x3a8679,_0x561075,_0x1e0fba,_0xf2c327){const _0x3d9f77=_0x36e6f4,_0x305f61=this;_0x305f61[_0x3d9f77('0x98')]=_0x3a8679['getCurrentUser'](),_0x305f61[_0x3d9f77('0x61a')]=[],_0x305f61[_0x3d9f77('0xf8a')]=_0x1e0fba,_0x305f61[_0x3d9f77('0x5c9')]=_0x561075,_0x305f61['crudPermissions']=_0xf2c327,_0x305f61['hasModulePermissions']={},_0x305f61['passwordPattern']=_0x305f61[_0x3d9f77('0xf8a')]&&_0x305f61[_0x3d9f77('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x305f61[_0x3d9f77('0xcdc')]=_0x3d9f77('0x7c7'),_0x305f61[_0x3d9f77('0x2b8')]=angular[_0x3d9f77('0x225f')](_0x2e5f3b),_0x305f61[_0x3d9f77('0x339')]=_0x3b58df,_0x305f61[_0x3d9f77('0x1fc1')]=![];!_0x305f61[_0x3d9f77('0x2b8')]&&(_0x305f61[_0x3d9f77('0x2b8')]={},_0x305f61[_0x3d9f77('0xcdc')]=_0x3d9f77('0xa24'),_0x305f61[_0x3d9f77('0x1fc1')]=!![]);_0x16abf9['params']['id']&&(_0x305f61[_0x3d9f77('0x2b8')][_0x3d9f77('0x193b')]=_0x16abf9[_0x3d9f77('0x23f')]['id']);_0x305f61['addNewMohSound']=_0x123619,_0x305f61[_0x3d9f77('0x1286')]=_0xdcf68c,_0x305f61['deleteMohSound']=_0x54e4e7,_0x305f61[_0x3d9f77('0x1a9c')]=_0x11523f,_0x305f61[_0x3d9f77('0x24a0')]=_0x14cb20,_0x3a8679[_0x3d9f77('0x1ac6')](_0x3d9f77('0xa7c'))?_0x3fcc32['sound'][_0x3d9f77('0xd83')]({'fields':_0x3d9f77('0x1776'),'sort':_0x3d9f77('0x4f0')})[_0x3d9f77('0xa44')][_0x3d9f77('0x1166')](function(_0x10666d){const _0x50242e=_0x3d9f77;_0x305f61[_0x50242e('0x137')]=_0x10666d['rows']||[];})[_0x3d9f77('0x1a80')](function(_0x31f3f0){const _0x1bcdd1=_0x3d9f77;_0x3a5324['error']({'title':_0x31f3f0[_0x1bcdd1('0x52d')]?_0x1bcdd1('0x1e21')+_0x31f3f0[_0x1bcdd1('0x52d')]+_0x1bcdd1('0x11e1')+_0x31f3f0[_0x1bcdd1('0xe1b')]:_0x1bcdd1('0x140a'),'msg':_0x31f3f0[_0x1bcdd1('0x25f4')]?JSON[_0x1bcdd1('0xbac')](_0x31f3f0[_0x1bcdd1('0x25f4')]):_0x31f3f0[_0x1bcdd1('0x1586')]()});}):_0x3fcc32['sound']['get']({'fields':_0x3d9f77('0x1776'),'sort':_0x3d9f77('0x4f0')})[_0x3d9f77('0xa44')]['then'](function(_0x311378){const _0x4fa565=_0x3d9f77;_0x305f61['sounds']=_0x311378[_0x4fa565('0x269a')]||[];})[_0x3d9f77('0x1166')](function(){const _0x2de410=_0x3d9f77;return _0x3fcc32['userProfileSection'][_0x2de410('0xd83')]({'userProfileId':_0x305f61[_0x2de410('0x98')][_0x2de410('0xb86')],'sectionId':0x3ef})[_0x2de410('0xa44')];})[_0x3d9f77('0x1166')](function(_0x25849f){const _0x38ca28=_0x3d9f77,_0xd7a00c=_0x25849f&&_0x25849f[_0x38ca28('0x269a')]?_0x25849f[_0x38ca28('0x269a')][0x0]:null;if(!_0xd7a00c){const _0x543487=[];let _0x4e1214=null;_0x305f61[_0x38ca28('0x2b8')]&&(_0x4e1214=_0x2cfb05()[_0x38ca28('0xc38')](_0x305f61[_0x38ca28('0x137')],{'id':Number(_0x305f61[_0x38ca28('0x2b8')]['id'])}));for(let _0x29860c=0x0;_0x29860c<_0x305f61[_0x38ca28('0x137')][_0x38ca28('0x264b')];_0x29860c++){_0x4e1214&&_0x305f61[_0x38ca28('0x137')][_0x29860c]['id']===_0x4e1214['id']&&(_0x305f61[_0x38ca28('0x137')][_0x29860c][_0x38ca28('0x2378')]=![],_0x543487[_0x38ca28('0x1514')](_0x305f61[_0x38ca28('0x137')][_0x29860c]));}_0x305f61[_0x38ca28('0x137')]=_0x543487;}else{if(!_0xd7a00c[_0x38ca28('0x1a2b')])return _0x3fcc32[_0x38ca28('0x4b5')][_0x38ca28('0xd83')]({'sectionId':_0xd7a00c['id']})[_0x38ca28('0xa44')][_0x38ca28('0x1166')](function(_0x2335a9){const _0x447746=_0x38ca28,_0x22a0da=_0x2cfb05()[_0x447746('0x2563')](_0x2335a9[_0x447746('0x269a')],function(_0x5dc148){const _0x3288f2=_0x447746;return _0x2cfb05()[_0x3288f2('0xc38')](_0x305f61[_0x3288f2('0x137')],{'id':_0x5dc148['resourceId']});});let _0x133e81=null;_0x305f61['mohSound']&&(_0x133e81=_0x2cfb05()[_0x447746('0xc38')](_0x305f61[_0x447746('0x137')],{'id':Number(_0x305f61['mohSound']['id'])}));if(_0x133e81&&!_0x2cfb05()['some'](_0x22a0da,['id',_0x133e81['id']])){const _0x2eba82=_0x2cfb05()[_0x447746('0xc38')](_0x305f61['sounds'],{'id':_0x133e81['id']});_0x2eba82[_0x447746('0x2378')]=![],_0x22a0da['push'](_0x2eba82);}_0x305f61[_0x447746('0x137')]=_0x22a0da;});}})[_0x3d9f77('0x1a80')](function(_0x5deced){const _0x5f4b53=_0x3d9f77;_0x3a5324[_0x5f4b53('0xfc9')]({'title':_0x5deced['status']?_0x5f4b53('0x1e21')+_0x5deced[_0x5f4b53('0x52d')]+'\x20-\x20'+_0x5deced[_0x5f4b53('0xe1b')]:_0x5f4b53('0x1d89'),'msg':_0x5deced[_0x5f4b53('0x25f4')]?JSON['stringify'](_0x5deced[_0x5f4b53('0x25f4')]):_0x5deced['toString']()});});function _0x123619(){const _0x42ef0c=_0x3d9f77;_0x305f61[_0x42ef0c('0x61a')]=[],_0x3fcc32[_0x42ef0c('0x8d3')][_0x42ef0c('0xd92')]({'id':_0x16abf9[_0x42ef0c('0x23f')]['id']},_0x305f61[_0x42ef0c('0x2b8')])[_0x42ef0c('0xa44')]['then'](function(_0x214d14){const _0x46b808=_0x42ef0c;_0x305f61[_0x46b808('0x339')]['unshift'](_0x214d14[_0x46b808('0x2876')]()),_0x3a5324[_0x46b808('0x103b')]({'title':_0x46b808('0x23aa'),'msg':_0x305f61['mohSound']['name']?_0x305f61[_0x46b808('0x2b8')][_0x46b808('0x4f0')]+_0x46b808('0x1eda'):''}),_0x14cb20(_0x214d14);})[_0x42ef0c('0x1a80')](function(_0x47fba5){const _0x816465=_0x42ef0c;if(_0x47fba5[_0x816465('0x25f4')]&&_0x47fba5[_0x816465('0x25f4')][_0x816465('0x61a')]&&_0x47fba5[_0x816465('0x25f4')][_0x816465('0x61a')]['length']){_0x305f61[_0x816465('0x61a')]=_0x47fba5[_0x816465('0x25f4')][_0x816465('0x61a')]||[{'message':_0x47fba5[_0x816465('0x1586')](),'type':_0x816465('0x3ea')}];for(let _0x28565f=0x0;_0x28565f<_0x47fba5['data']['errors'][_0x816465('0x264b')];_0x28565f+=0x1){_0x3a5324[_0x816465('0xfc9')]({'title':_0x47fba5[_0x816465('0x25f4')][_0x816465('0x61a')][_0x28565f][_0x816465('0x1345')],'msg':_0x47fba5[_0x816465('0x25f4')][_0x816465('0x61a')][_0x28565f][_0x816465('0x1e70')]});}}else _0x3a5324[_0x816465('0xfc9')]({'title':_0x47fba5[_0x816465('0x52d')]?'API:'+_0x47fba5['status']+_0x816465('0x11e1')+_0x47fba5['statusText']:_0x816465('0x3ea'),'msg':_0x47fba5[_0x816465('0x25f4')]?JSON[_0x816465('0xbac')](_0x47fba5['data'][_0x816465('0x1e70')]):_0x47fba5['toString']()});});}function _0xdcf68c(){const _0x47db2c=_0x3d9f77;_0x305f61['errors']=[],_0x3fcc32[_0x47db2c('0x8d3')][_0x47db2c('0x1449')]({'id':_0x305f61['mohSound']['id']},_0x305f61[_0x47db2c('0x2b8')])[_0x47db2c('0xa44')][_0x47db2c('0x1166')](function(_0x4b060c){const _0x546bc7=_0x47db2c,_0xc56e27=_0x2cfb05()[_0x546bc7('0xc38')](_0x305f61[_0x546bc7('0x339')],{'id':_0x4b060c['id']});_0xc56e27&&_0x2cfb05()[_0x546bc7('0xcc3')](_0xc56e27,_0x2cfb05()[_0x546bc7('0x1a08')](_0x4b060c[_0x546bc7('0x2876')](),_0x2cfb05()[_0x546bc7('0x14a4')](_0xc56e27))),_0x3a5324[_0x546bc7('0x103b')]({'title':'MohSound\x20properly\x20saved!','msg':_0x305f61[_0x546bc7('0x2b8')]['name']?_0x305f61[_0x546bc7('0x2b8')]['name']+_0x546bc7('0x7d'):''}),_0x14cb20(_0x4b060c);})[_0x47db2c('0x1a80')](function(_0x136f87){const _0x57990e=_0x47db2c;if(_0x136f87[_0x57990e('0x25f4')]&&_0x136f87[_0x57990e('0x25f4')]['errors']&&_0x136f87[_0x57990e('0x25f4')][_0x57990e('0x61a')][_0x57990e('0x264b')]){_0x305f61[_0x57990e('0x61a')]=_0x136f87[_0x57990e('0x25f4')][_0x57990e('0x61a')]||[{'message':_0x136f87[_0x57990e('0x1586')](),'type':_0x57990e('0x14d3')}];for(let _0x5a31e5=0x0;_0x5a31e5<_0x136f87['data'][_0x57990e('0x61a')][_0x57990e('0x264b')];_0x5a31e5++){_0x3a5324[_0x57990e('0xfc9')]({'title':_0x136f87[_0x57990e('0x25f4')]['errors'][_0x5a31e5][_0x57990e('0x1345')],'msg':_0x136f87[_0x57990e('0x25f4')][_0x57990e('0x61a')][_0x5a31e5][_0x57990e('0x1e70')]});}}else _0x3a5324[_0x57990e('0xfc9')]({'title':_0x136f87[_0x57990e('0x52d')]?_0x57990e('0x1e21')+_0x136f87[_0x57990e('0x52d')]+_0x57990e('0x11e1')+_0x136f87[_0x57990e('0xe1b')]:_0x57990e('0x14d3'),'msg':_0x136f87['data']?JSON[_0x57990e('0xbac')](_0x136f87[_0x57990e('0x25f4')]['message']):_0x136f87[_0x57990e('0x1586')]()});});}function _0x54e4e7(_0x2fe1e3){const _0xe25aa4=_0x3d9f77;_0x305f61[_0xe25aa4('0x61a')]=[];const _0x2e1c90=_0x3a60aa['confirm']()['title'](_0xe25aa4('0x7fb'))[_0xe25aa4('0xacc')]('The\x20mohSound\x20will\x20be\x20deleted.')[_0xe25aa4('0x8e8')]('Delete\x20MohSound')['ok'](_0xe25aa4('0x18'))[_0xe25aa4('0x3f')](_0xe25aa4('0x497'))[_0xe25aa4('0x203b')](_0x2fe1e3);_0x3a60aa[_0xe25aa4('0x1f80')](_0x2e1c90)[_0xe25aa4('0x1166')](function(){const _0x21eac1=_0xe25aa4;_0x3fcc32[_0x21eac1('0x8d3')][_0x21eac1('0x906')]({'id':_0x305f61[_0x21eac1('0x2b8')]['id']})[_0x21eac1('0xa44')][_0x21eac1('0x1166')](function(){const _0x6d88eb=_0x21eac1;_0x2cfb05()[_0x6d88eb('0x127f')](_0x305f61[_0x6d88eb('0x339')],{'id':_0x305f61[_0x6d88eb('0x2b8')]['id']}),_0x3a5324['success']({'title':_0x6d88eb('0x1de5'),'msg':(_0x305f61['mohSound'][_0x6d88eb('0x4f0')]||_0x6d88eb('0x2b8'))+'\x20has\x20been\x20deleted!'}),_0x14cb20(_0x305f61[_0x6d88eb('0x2b8')]);})[_0x21eac1('0x1a80')](function(_0x40ad70){const _0x3023b3=_0x21eac1;if(_0x40ad70[_0x3023b3('0x25f4')]&&_0x40ad70[_0x3023b3('0x25f4')]['errors']&&_0x40ad70[_0x3023b3('0x25f4')][_0x3023b3('0x61a')][_0x3023b3('0x264b')]){_0x305f61[_0x3023b3('0x61a')]=_0x40ad70[_0x3023b3('0x25f4')][_0x3023b3('0x61a')]||[{'message':_0x40ad70[_0x3023b3('0x1586')](),'type':'api.voiceMusicOnHold.delete'}];for(let _0x1d84e5=0x0;_0x1d84e5<_0x40ad70[_0x3023b3('0x25f4')]['errors'][_0x3023b3('0x264b')];_0x1d84e5++){_0x3a5324[_0x3023b3('0xfc9')]({'title':_0x40ad70[_0x3023b3('0x25f4')][_0x3023b3('0x61a')][_0x1d84e5][_0x3023b3('0x1345')],'msg':_0x40ad70[_0x3023b3('0x25f4')]['errors'][_0x1d84e5][_0x3023b3('0x1e70')]});}}else _0x3a5324[_0x3023b3('0xfc9')]({'title':_0x40ad70[_0x3023b3('0x52d')]?_0x3023b3('0x1e21')+_0x40ad70[_0x3023b3('0x52d')]+_0x3023b3('0x11e1')+_0x40ad70['statusText']:'api.voiceMusicOnHold.delete','msg':_0x40ad70[_0x3023b3('0x25f4')]?JSON[_0x3023b3('0xbac')](_0x40ad70[_0x3023b3('0x25f4')]['message']):_0x40ad70['message']||_0x40ad70[_0x3023b3('0x1586')]()});});},function(){});}function _0x11523f(_0x988cb){return _0x988cb===null?undefined:new Date(_0x988cb);}function _0x14cb20(_0x475a87){_0x3a60aa['hide'](_0x475a87);}}const _0x50cb0d=_0x48f38e;_0x59a8d8['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x98e'),'userProfileSection'];function _0x59a8d8(_0x4994e9,_0x18da99,_0x423bc7,_0x31e946,_0x3b574a,_0x16bd60,_0x215e66,_0x57519d,_0xb28c29,_0x345880,_0x11d6f3,_0x103771){const _0x5c1603=_0x36e6f4,_0x3a98cd=this;_0x3a98cd[_0x5c1603('0x98')]=_0x345880[_0x5c1603('0x26cd')](),_0x3a98cd[_0x5c1603('0x5c9')]=_0x16bd60,_0x3a98cd[_0x5c1603('0xf8a')]=_0x215e66,_0x3a98cd[_0x5c1603('0x2900')]=_0x3a98cd[_0x5c1603('0xf8a')][_0x5c1603('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3a98cd[_0x5c1603('0x246b')]=_0x18da99[_0x5c1603('0x6f1')]()+'://'+_0x18da99[_0x5c1603('0x1690')](),_0x3a98cd['musiconhold']=_0x11d6f3||_0x4994e9['params'][_0x5c1603('0x98e')]||{},_0x3a98cd[_0x5c1603('0x17aa')]=_0x103771&&_0x103771[_0x5c1603('0x240f')]==0x1?_0x103771[_0x5c1603('0x269a')][0x0]:null,_0x3a98cd['crudPermissions']=_0x345880[_0x5c1603('0xd87')](_0x3a98cd['userProfileSection']?_0x3a98cd[_0x5c1603('0x17aa')][_0x5c1603('0x243c')]:null),_0x3a98cd[_0x5c1603('0x128b')]={},_0x3a98cd[_0x5c1603('0x2669')]=_0x4994e9[_0x5c1603('0x23f')][_0x5c1603('0xbe3')]||0x0,_0x3a98cd[_0x5c1603('0x31d')]=_0xb28c29[_0x5c1603('0x1fa1')],_0x3a98cd[_0x5c1603('0x276a')]=_0x37129b,_0x3a98cd[_0x5c1603('0x1047')]=_0x15f1ea;function _0x37129b(){const _0x3f2d4b=_0x5c1603;_0x4994e9['go'](_0x3f2d4b('0x1b42'),{},{'reload':_0x3f2d4b('0x1b42')});}function _0x15f1ea(){const _0x1b178b=_0x5c1603;_0x57519d['voiceMusicOnHold'][_0x1b178b('0x1449')]({'id':_0x3a98cd[_0x1b178b('0x98e')]['id']},_0x3a98cd[_0x1b178b('0x98e')])[_0x1b178b('0xa44')]['then'](function(){const _0xc4890c=_0x1b178b;_0xb28c29['success']({'title':_0xc4890c('0xb96'),'msg':_0x3a98cd[_0xc4890c('0x98e')]['name']?_0x3a98cd[_0xc4890c('0x98e')][_0xc4890c('0x4f0')]+_0xc4890c('0xa17'):''});})[_0x1b178b('0x1a80')](function(_0x47f0d2){const _0x33fd25=_0x1b178b;_0xb28c29['error']({'title':_0x47f0d2[_0x33fd25('0x52d')]?_0x33fd25('0x1e21')+_0x47f0d2[_0x33fd25('0x52d')]+_0x33fd25('0x11e1')+_0x47f0d2[_0x33fd25('0xe1b')]:_0x33fd25('0x407'),'msg':_0x47f0d2[_0x33fd25('0x25f4')]?JSON[_0x33fd25('0xbac')](_0x47f0d2['data']):_0x47f0d2[_0x33fd25('0x1586')]()});});}}const _0xed8a75=_0x59a8d8,_0x54e22b=_0x2734b2['p']+_0x36e6f4('0xae7');_0x491edf[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x10ad'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils','toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting'];function _0x491edf(_0x16e301,_0x4109fe,_0x15cf21,_0x47a5ec,_0x19d8be,_0x3a42de,_0x49e0ff,_0x2b3eff,_0x19bbea,_0x35eddd,_0xd82183,_0x792811,_0x521e1d,_0x44e871,_0x1cf456,_0x485a5a,_0x26ed5e){const _0x48672b=_0x36e6f4,_0x5d6cbb=this;_0x5d6cbb[_0x48672b('0x5c9')]=_0x485a5a,_0x5d6cbb[_0x48672b('0xf8a')]=_0x26ed5e,_0x5d6cbb[_0x48672b('0x98')]=_0x1cf456[_0x48672b('0x26cd')](),_0x5d6cbb[_0x48672b('0x10ad')]=_0x19bbea||{'count':0x0,'rows':[]},_0x5d6cbb[_0x48672b('0x7f')]=_0x35eddd,_0x5d6cbb[_0x48672b('0x17aa')]=_0xd82183&&_0xd82183[_0x48672b('0x240f')]==0x1?_0xd82183[_0x48672b('0x269a')][0x0]:null,_0x5d6cbb[_0x48672b('0x243c')]=_0x1cf456[_0x48672b('0xd87')](_0x5d6cbb[_0x48672b('0x17aa')]?_0x5d6cbb[_0x48672b('0x17aa')][_0x48672b('0x243c')]:null),_0x5d6cbb[_0x48672b('0x916')]=_0x48672b('0x10ad'),_0x5d6cbb[_0x48672b('0xef5')]='',_0x5d6cbb['listOrderAsc']=null,_0x5d6cbb[_0x48672b('0x79b')]=[],_0x5d6cbb[_0x48672b('0x2218')]={'fields':_0x48672b('0x18db'),'defaultEntry':_0x48672b('0x1607'),'limit':0xa,'page':0x1},_0x5d6cbb[_0x48672b('0x39f')]=_0x2cfb05()[_0x48672b('0x155c')]([{'option':_0x48672b('0x465'),'value':'\x27files\x27'},{'option':_0x48672b('0x117f'),'value':_0x48672b('0x16cc')}],function(_0x1bd726){const _0x41c346=_0x48672b;return _0x2cfb05()[_0x41c346('0xf3')](_0x1bd726[_0x41c346('0x18e0')],new RegExp('\x27','g'),'');}),_0x5d6cbb['arraysort']=_0x2cfb05()[_0x48672b('0x155c')]([{'option':_0x48672b('0x13cd'),'value':_0x48672b('0x7ad')},{'option':'Alphabetical','value':'\x27alpha\x27'}],function(_0x54d92a){const _0x575c0b=_0x48672b;return _0x2cfb05()[_0x575c0b('0xf3')](_0x54d92a[_0x575c0b('0x18e0')],new RegExp('\x27','g'),'');}),_0x5d6cbb['editstate']=_0x5403a4,_0x5d6cbb[_0x48672b('0x8d8')]=_0x16c01b,_0x5d6cbb['success']=_0x28c555,_0x5d6cbb['getMusicOnHolds']=_0x1171b7,_0x5d6cbb['createOrEditMusicOnHold']=_0x649b6b,_0x5d6cbb[_0x48672b('0x265c')]=_0x295a28,_0x5d6cbb[_0x48672b('0xa3b')]=_0xcdfbaa,_0x5d6cbb[_0x48672b('0x8a0')]=_0x31a630,_0x5d6cbb[_0x48672b('0x9cf')]=_0x12e44b,_0x5d6cbb['selectAllMusicOnHolds']=_0x5c12d9;function _0x5403a4(_0x453886){const _0x10922e=_0x48672b;_0x15cf21['go']('app.voice.musiconholds.edit',{'id':_0x453886['id'],'musiconhold':_0x453886,'crudPermissions':_0x5d6cbb[_0x10922e('0x243c')]});}function _0x16c01b(_0x9d1b02,_0x290ceb){const _0xa90a03=_0x48672b,_0x2b68a4=_0x19d8be[_0xa90a03('0x1d26')]()[_0xa90a03('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0xa90a03('0xb35')](_0xa90a03('0x98e'))+'?')[_0xa90a03('0xf3c')](''+(_0x9d1b02[_0xa90a03('0x4f0')]||_0xa90a03('0x98e'))+_0xa90a03('0xace')+_0xa90a03('0x3f3'))[_0xa90a03('0x8e8')]('delete\x20musiconhold')['targetEvent'](_0x290ceb)['ok']('OK')[_0xa90a03('0x3f')](_0xa90a03('0x2d3'));_0x19d8be[_0xa90a03('0x1f80')](_0x2b68a4)[_0xa90a03('0x1166')](function(){_0x295a28(_0x9d1b02);},function(){const _0x247033=_0xa90a03;console[_0x247033('0x455')](_0x247033('0x2d3'));});}let _0x43b030=!![],_0x3c304e=0x1;_0x16e301[_0x48672b('0xe83')](_0x48672b('0x12d8'),function(_0x240b2e,_0x33d77e){const _0x30087b=_0x48672b;_0x43b030?_0x49e0ff(function(){_0x43b030=![];}):(!_0x33d77e&&(_0x3c304e=_0x5d6cbb[_0x30087b('0x2218')][_0x30087b('0x1a43')]),_0x240b2e!==_0x33d77e&&(_0x5d6cbb[_0x30087b('0x2218')][_0x30087b('0x1a43')]=0x1),!_0x240b2e&&(_0x5d6cbb[_0x30087b('0x2218')][_0x30087b('0x1a43')]=_0x3c304e),_0x5d6cbb[_0x30087b('0x22b8')]());});function _0x28c555(_0x16d7f0){const _0x31f3d5=_0x48672b;_0x5d6cbb[_0x31f3d5('0x10ad')]=_0x16d7f0||{'count':0x0,'rows':[]};}function _0x1171b7(){const _0x4e338c=_0x48672b;_0x5d6cbb[_0x4e338c('0x2218')]['offset']=(_0x5d6cbb[_0x4e338c('0x2218')]['page']-0x1)*_0x5d6cbb[_0x4e338c('0x2218')][_0x4e338c('0x163f')],_0x1cf456[_0x4e338c('0x1ac6')](_0x4e338c('0xa7c'))?_0x5d6cbb['promise']=_0x792811[_0x4e338c('0x8d3')]['get'](_0x5d6cbb[_0x4e338c('0x2218')],_0x28c555)[_0x4e338c('0xa44')]:(_0x5d6cbb[_0x4e338c('0x2218')]['id']=_0x5d6cbb['userProfile']['id'],_0x5d6cbb[_0x4e338c('0x2218')]['section']=_0x4e338c('0x1a14'),_0x5d6cbb[_0x4e338c('0x1f48')]=_0x792811[_0x4e338c('0x7f')][_0x4e338c('0x263a')](_0x5d6cbb[_0x4e338c('0x2218')],_0x28c555)[_0x4e338c('0xa44')]);}function _0x649b6b(_0x1a52f3,_0x2d9aef){const _0x122bdd=_0x48672b;_0x19d8be[_0x122bdd('0x1f80')]({'controller':_0x122bdd('0x1c13'),'controllerAs':'vm','templateUrl':_0x54e22b,'parent':angular['element'](_0x3a42de['body']),'targetEvent':_0x1a52f3,'clickOutsideToClose':!![],'locals':{'musiconhold':_0x2d9aef,'musiconholds':_0x5d6cbb[_0x122bdd('0x10ad')][_0x122bdd('0x269a')],'license':_0x5d6cbb[_0x122bdd('0x5c9')],'setting':_0x5d6cbb['setting'],'crudPermissions':_0x5d6cbb[_0x122bdd('0x243c')]}});}function _0x295a28(_0xff0a22){const _0x20d94f=_0x48672b;_0x792811['voiceMusicOnHold']['delete']({'id':_0xff0a22['id']})['$promise'][_0x20d94f('0x1166')](function(){const _0x1f921e=_0x20d94f;_0x2cfb05()[_0x1f921e('0x127f')](_0x5d6cbb['musiconholds'][_0x1f921e('0x269a')],{'id':_0xff0a22['id']}),_0x5d6cbb[_0x1f921e('0x10ad')][_0x1f921e('0x240f')]-=0x1,!_0x5d6cbb['musiconholds'][_0x1f921e('0x269a')][_0x1f921e('0x264b')]&&_0x5d6cbb['getMusicOnHolds'](),_0x44e871[_0x1f921e('0x103b')]({'title':_0x2cfb05()[_0x1f921e('0xb35')]('MusicOnHold')+_0x1f921e('0x2b6'),'msg':_0xff0a22['name']?_0xff0a22['name']+'\x20has\x20been\x20deleted!':''});})[_0x20d94f('0x1a80')](function(_0x5c768){const _0x4d510a=_0x20d94f;if(_0x5c768[_0x4d510a('0x25f4')]&&_0x5c768[_0x4d510a('0x25f4')][_0x4d510a('0x61a')]&&_0x5c768[_0x4d510a('0x25f4')][_0x4d510a('0x61a')][_0x4d510a('0x264b')]){_0x5d6cbb['errors']=_0x5c768['data'][_0x4d510a('0x61a')]||[{'message':_0x5c768['toString'](),'type':_0x4d510a('0x1e79')}];for(let _0x942eac=0x0;_0x942eac<_0x5c768[_0x4d510a('0x25f4')]['errors'][_0x4d510a('0x264b')];_0x942eac++){_0x44e871[_0x4d510a('0xfc9')]({'title':_0x5c768[_0x4d510a('0x25f4')][_0x4d510a('0x61a')][_0x942eac][_0x4d510a('0x1345')],'msg':_0x5c768['data'][_0x4d510a('0x61a')][_0x942eac][_0x4d510a('0x1e70')]});}}else _0x44e871[_0x4d510a('0xfc9')]({'title':_0x5c768[_0x4d510a('0x52d')]?_0x4d510a('0x1e21')+_0x5c768[_0x4d510a('0x52d')]+_0x4d510a('0x11e1')+_0x5c768['statusText']:_0x4d510a('0x1e79'),'msg':_0x5c768[_0x4d510a('0x25f4')]?JSON['stringify'](_0x5c768[_0x4d510a('0x25f4')][_0x4d510a('0x1e70')]):_0x5c768[_0x4d510a('0x1e70')]||_0x5c768[_0x4d510a('0x1586')]()});});}function _0xcdfbaa(){const _0xf70044=_0x48672b,_0x1d12e5=angular[_0xf70044('0x225f')](_0x5d6cbb[_0xf70044('0x79b')]);return _0x5d6cbb[_0xf70044('0x79b')]=[],_0x1d12e5;}function _0x31a630(_0x2e1d04){const _0x5b8d4a=_0x48672b,_0xfd67b1=_0x19d8be[_0x5b8d4a('0x1d26')]()['title'](_0x5b8d4a('0xa7a'))[_0x5b8d4a('0xf3c')](_0x5b8d4a('0x12b5')+_0x5d6cbb['selectedMusicOnHolds'][_0x5b8d4a('0x264b')]+_0x5b8d4a('0x196d')+_0x5b8d4a('0x3f3'))['ariaLabel'](_0x5b8d4a('0x16cf'))[_0x5b8d4a('0x203b')](_0x2e1d04)['ok']('OK')['cancel'](_0x5b8d4a('0x2d3'));_0x19d8be['show'](_0xfd67b1)[_0x5b8d4a('0x1166')](function(){const _0x571d45=_0x5b8d4a;_0x5d6cbb[_0x571d45('0x79b')][_0x571d45('0x2782')](function(_0x265d3a){_0x295a28(_0x265d3a);}),_0x5d6cbb[_0x571d45('0x79b')]=[];});}function _0x12e44b(){_0x5d6cbb['selectedMusicOnHolds']=[];}function _0x5c12d9(){const _0x27d8c0=_0x48672b;_0x5d6cbb[_0x27d8c0('0x79b')]=_0x5d6cbb[_0x27d8c0('0x10ad')]['rows'];}}const _0x34541f=_0x491edf;_0x445f4f[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xee4'),_0x36e6f4('0x1aec'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x445f4f(_0x3e61ef,_0x2fdd53,_0x6f6626,_0x2f65f5,_0x356fa3,_0x56e261,_0x3dfaa0,_0x45448d,_0x169066,_0x57f774,_0x3c6781,_0x4bb95d,_0x544feb,_0x33e6bc){const _0x364174=_0x36e6f4,_0x1b3f9d=this;_0x1b3f9d[_0x364174('0x98')]=_0x3c6781[_0x364174('0x26cd')](),_0x1b3f9d[_0x364174('0x61a')]=[],_0x1b3f9d['setting']=_0x544feb,_0x1b3f9d['license']=_0x4bb95d,_0x1b3f9d[_0x364174('0x243c')]=_0x33e6bc,_0x1b3f9d['hasModulePermissions']={},_0x1b3f9d['passwordPattern']=_0x1b3f9d[_0x364174('0xf8a')]&&_0x1b3f9d[_0x364174('0xf8a')][_0x364174('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1b3f9d[_0x364174('0xcdc')]=_0x364174('0x2090'),_0x1b3f9d[_0x364174('0x1aec')]=angular[_0x364174('0x225f')](_0x169066),_0x1b3f9d[_0x364174('0xee4')]=_0x45448d,_0x1b3f9d['newOutboundRoute']=![],_0x1b3f9d[_0x364174('0x22eb')]={'count':0x0,'rows':[]},_0x1b3f9d[_0x364174('0x24d2')]=_0x2cfb05()['reject'](_0x2cfb05()[_0x364174('0x1eba')]([{'app':_0x364174('0x1545'),'appType':_0x364174('0x277c'),'type':_0x364174('0xd94'),'types':[_0x364174('0x597'),_0x364174('0x2853'),'list'],'fields':[],'isApp':![]},{'app':'Dial','appType':_0x364174('0x867'),'context':'from-sip','type':'Outbound','icon':_0x364174('0x283f'),'interval':'*,*,*,*','options':'xX','isApp':!![],'extraApi':[{'name':'trunks','route':_0x364174('0x3b2'),'filters':{'fields':_0x364174('0x4f0'),'sort':_0x364174('0x4f0')}},{'name':'tags','route':_0x364174('0x1446'),'filters':{'fields':'name','sort':_0x364174('0x4f0'),'nolimit':!![]}}],'fields':[{'title':_0x364174('0x14c4'),'name':_0x364174('0x3b2'),'type':'apiselect','values':_0x364174('0xf24'),'value':_0x364174('0x912'),'option':'trunk.name','required':!![],'param':0x0},{'title':_0x364174('0x1e58'),'name':_0x364174('0x992'),'type':_0x364174('0x1640'),'ngPattern':_0x364174('0x1bd4'),'help':!![]},{'title':'Prefix','name':_0x364174('0x265a'),'type':'text'},{'title':_0x364174('0x21c2'),'name':_0x364174('0x1446'),'type':_0x364174('0x2550'),'values':_0x364174('0xb38'),'value':_0x364174('0xc2c'),'option':_0x364174('0xc2c'),'defaultValues':[{'value':'\x27--\x27','option':_0x364174('0x1280')}]},{'title':'Timeout','name':_0x364174('0x651'),'type':_0x364174('0xc45'),'min':0x0,'param':0x1},{'title':_0x364174('0x20f3'),'name':'options','type':_0x364174('0x1640'),'param':0x2},{'title':_0x364174('0x11a2'),'name':_0x364174('0xcac'),'type':'text','param':0x3}]},{'app':null,'type':_0x364174('0xd94'),'appType':'custom','icon':_0x364174('0x283f'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x364174('0x7bc'),'name':'app','type':_0x364174('0x1640'),'required':!![],'param':0x0},{'title':_0x364174('0x81c'),'name':_0x364174('0x823'),'type':'text','param':0x1}]}],['app']),{'isApp':![]});!_0x1b3f9d[_0x364174('0x1aec')]&&(_0x1b3f9d[_0x364174('0x1aec')]={'appdata':'Outbound\x20Call','type':_0x364174('0x587'),'context':_0x364174('0xb31'),'recordingFormat':_0x364174('0x192')},_0x1b3f9d['title']='VOICE.NEW_OUTBOUNDROUTE',_0x1b3f9d[_0x364174('0xc88')]=!![]);_0x1b3f9d[_0x364174('0x1a13')]=_0x5f4c84,_0x1b3f9d[_0x364174('0x2675')]=_0x28dcd0,_0x1b3f9d[_0x364174('0x1d47')]=_0x46e1cf,_0x1b3f9d[_0x364174('0x1a9c')]=_0x265499,_0x1b3f9d[_0x364174('0x20a6')]=_0x2bc18,_0x1b3f9d[_0x364174('0x24a0')]=_0x5a9315,_0x3c6781[_0x364174('0x1ac6')](_0x364174('0xa7c'))?_0x57f774[_0x364174('0x23b1')][_0x364174('0xd83')]({'fields':_0x364174('0x1776'),'sort':'name','nolimit':_0x364174('0xf3b')})['$promise']['then'](function(_0x581b02){const _0x426c23=_0x364174;_0x1b3f9d['contexts']=_0x581b02[_0x426c23('0x269a')]||[];})[_0x364174('0x1a80')](function(_0x46b623){const _0x400c98=_0x364174;_0x3dfaa0['error']({'title':_0x46b623['status']?_0x400c98('0x1e21')+_0x46b623[_0x400c98('0x52d')]+_0x400c98('0x11e1')+_0x46b623[_0x400c98('0xe1b')]:_0x400c98('0x140d'),'msg':_0x46b623[_0x400c98('0x25f4')]?JSON[_0x400c98('0xbac')](_0x46b623['data']):_0x46b623['toString']()});}):_0x57f774[_0x364174('0x23b1')][_0x364174('0xd83')]({'fields':_0x364174('0x1776'),'sort':'name','nolimit':_0x364174('0xf3b')})[_0x364174('0xa44')][_0x364174('0x1166')](function(_0x19e3d4){const _0x5f1b24=_0x364174;_0x1b3f9d['contexts']=_0x19e3d4[_0x5f1b24('0x269a')]||[];})[_0x364174('0x1166')](function(){const _0x148d9b=_0x364174;return _0x57f774[_0x148d9b('0x17aa')]['get']({'userProfileId':_0x1b3f9d['currentUser'][_0x148d9b('0xb86')],'sectionId':0x195})[_0x148d9b('0xa44')];})[_0x364174('0x1166')](function(_0x5c3b7c){const _0xdf9ae7=_0x364174,_0x28bac5=_0x5c3b7c&&_0x5c3b7c[_0xdf9ae7('0x269a')]?_0x5c3b7c[_0xdf9ae7('0x269a')][0x0]:null;if(!_0x28bac5)return _0x57f774[_0xdf9ae7('0x23b1')]['get']({'fields':_0xdf9ae7('0x1776'),'sort':_0xdf9ae7('0x4f0'),'nolimit':_0xdf9ae7('0xf3b'),'defaultEntry':0x1})[_0xdf9ae7('0xa44')]['then'](function(_0x26f5ad){const _0x5e0238=_0xdf9ae7;_0x1b3f9d[_0x5e0238('0x160a')]=_0x26f5ad[_0x5e0238('0x269a')]||[];});else{if(!_0x28bac5[_0xdf9ae7('0x1a2b')])return _0x57f774[_0xdf9ae7('0x4b5')]['get']({'sectionId':_0x28bac5['id']})[_0xdf9ae7('0xa44')][_0xdf9ae7('0x1166')](function(_0x4251e9){const _0x39c8f1=_0xdf9ae7,_0x27e7fb=_0x2cfb05()[_0x39c8f1('0x2563')](_0x4251e9['rows'],function(_0x1f60a5){const _0x76da46=_0x39c8f1;return _0x2cfb05()[_0x76da46('0xc38')](_0x1b3f9d[_0x76da46('0x160a')],{'id':_0x1f60a5[_0x76da46('0x24e8')]});});let _0x160dc7=null;_0x1b3f9d[_0x39c8f1('0x1aec')]&&(_0x160dc7=_0x2cfb05()['find'](_0x1b3f9d['contexts'],{'name':_0x1b3f9d[_0x39c8f1('0x1aec')][_0x39c8f1('0xe1c')]}));if(_0x160dc7&&!_0x2cfb05()['some'](_0x27e7fb,['id',_0x160dc7['id']])){const _0x57e6dc=_0x2cfb05()[_0x39c8f1('0xc38')](_0x1b3f9d['contexts'],{'id':_0x160dc7['id']});_0x57e6dc['canSelect']=![],_0x27e7fb[_0x39c8f1('0x1514')](_0x57e6dc);}_0x1b3f9d[_0x39c8f1('0x160a')]=_0x27e7fb;});}})[_0x364174('0x1a80')](function(_0x2b789f){const _0x12aff7=_0x364174;_0x3dfaa0[_0x12aff7('0xfc9')]({'title':_0x2b789f[_0x12aff7('0x52d')]?_0x12aff7('0x1e21')+_0x2b789f['status']+_0x12aff7('0x11e1')+_0x2b789f[_0x12aff7('0xe1b')]:_0x12aff7('0x482'),'msg':_0x2b789f[_0x12aff7('0x25f4')]?JSON[_0x12aff7('0xbac')](_0x2b789f[_0x12aff7('0x25f4')]):_0x2b789f['toString']()});});function _0x5f4c84(){const _0xee421e=_0x364174;_0x1b3f9d[_0xee421e('0x61a')]=[],_0x57f774[_0xee421e('0x1deb')][_0xee421e('0x9cc')](_0x1b3f9d[_0xee421e('0x1aec')])[_0xee421e('0xa44')][_0xee421e('0x1166')](function(_0x33b1bb){const _0x595ffa=_0xee421e;_0x1b3f9d[_0x595ffa('0xee4')][_0x595ffa('0x2450')](_0x33b1bb[_0x595ffa('0x2876')]()),_0x3dfaa0[_0x595ffa('0x103b')]({'title':_0x595ffa('0x2680'),'msg':_0x1b3f9d[_0x595ffa('0x1aec')]['name']?_0x1b3f9d[_0x595ffa('0x1aec')][_0x595ffa('0x4f0')]+_0x595ffa('0x1eda'):''}),_0x5a9315(_0x33b1bb);})[_0xee421e('0x1a80')](function(_0x3ed835){const _0x240596=_0xee421e;if(_0x3ed835['data']&&_0x3ed835[_0x240596('0x25f4')][_0x240596('0x61a')]&&_0x3ed835[_0x240596('0x25f4')][_0x240596('0x61a')][_0x240596('0x264b')]){_0x1b3f9d[_0x240596('0x61a')]=_0x3ed835[_0x240596('0x25f4')]['errors']||[{'message':_0x3ed835[_0x240596('0x1586')](),'type':_0x240596('0x1b99')}];for(let _0x44fcc4=0x0;_0x44fcc4<_0x3ed835['data'][_0x240596('0x61a')]['length'];_0x44fcc4+=0x1){_0x3dfaa0[_0x240596('0xfc9')]({'title':_0x3ed835[_0x240596('0x25f4')][_0x240596('0x61a')][_0x44fcc4][_0x240596('0x1345')],'msg':_0x3ed835[_0x240596('0x25f4')][_0x240596('0x61a')][_0x44fcc4][_0x240596('0x1e70')]});}}else _0x3dfaa0[_0x240596('0xfc9')]({'title':_0x3ed835[_0x240596('0x52d')]?'API:'+_0x3ed835[_0x240596('0x52d')]+_0x240596('0x11e1')+_0x3ed835[_0x240596('0xe1b')]:_0x240596('0x1b99'),'msg':_0x3ed835[_0x240596('0x25f4')]?JSON[_0x240596('0xbac')](_0x3ed835[_0x240596('0x25f4')][_0x240596('0x1e70')]):_0x3ed835[_0x240596('0x1586')]()});});}function _0x28dcd0(){const _0x14f246=_0x364174;_0x1b3f9d[_0x14f246('0x61a')]=[],_0x57f774[_0x14f246('0x1deb')][_0x14f246('0x1449')]({'id':_0x1b3f9d[_0x14f246('0x1aec')]['id']},_0x1b3f9d['outboundroute'])[_0x14f246('0xa44')][_0x14f246('0x1166')](function(_0x90962b){const _0x7b407b=_0x14f246,_0x499c2a=_0x2cfb05()['find'](_0x1b3f9d[_0x7b407b('0xee4')],{'id':_0x90962b['id']});_0x499c2a&&(_0x2cfb05()[_0x7b407b('0xcc3')](_0x499c2a,_0x2cfb05()[_0x7b407b('0x1a08')](_0x90962b[_0x7b407b('0x2876')](),_0x2cfb05()[_0x7b407b('0x14a4')](_0x499c2a))),_0x57f774[_0x7b407b('0x1deb')][_0x7b407b('0xd83')]({'sort':'priority','VoiceExtensionId':_0x499c2a['id'],'isApp':!![],'nolimit':!![]})[_0x7b407b('0xa44')][_0x7b407b('0x1166')](function(_0x247c15){_0x1b3f9d['outboundrouteApps']=_0x247c15,_0x2bc18();})),_0x3dfaa0[_0x7b407b('0x103b')]({'title':_0x7b407b('0x28c6'),'msg':_0x1b3f9d[_0x7b407b('0x1aec')][_0x7b407b('0x4f0')]?_0x1b3f9d[_0x7b407b('0x1aec')][_0x7b407b('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x5a9315(_0x90962b);})[_0x14f246('0x1a80')](function(_0x4c6337){const _0x95abf3=_0x14f246;if(_0x4c6337['data']&&_0x4c6337['data'][_0x95abf3('0x61a')]&&_0x4c6337['data'][_0x95abf3('0x61a')][_0x95abf3('0x264b')]){_0x1b3f9d[_0x95abf3('0x61a')]=_0x4c6337[_0x95abf3('0x25f4')][_0x95abf3('0x61a')]||[{'message':_0x4c6337[_0x95abf3('0x1586')](),'type':_0x95abf3('0x1caf')}];for(let _0x2adf4b=0x0;_0x2adf4b<_0x4c6337[_0x95abf3('0x25f4')][_0x95abf3('0x61a')][_0x95abf3('0x264b')];_0x2adf4b++){_0x3dfaa0[_0x95abf3('0xfc9')]({'title':_0x4c6337[_0x95abf3('0x25f4')][_0x95abf3('0x61a')][_0x2adf4b][_0x95abf3('0x1345')],'msg':_0x4c6337[_0x95abf3('0x25f4')]['errors'][_0x2adf4b]['message']});}}else _0x3dfaa0[_0x95abf3('0xfc9')]({'title':_0x4c6337[_0x95abf3('0x52d')]?_0x95abf3('0x1e21')+_0x4c6337[_0x95abf3('0x52d')]+'\x20-\x20'+_0x4c6337[_0x95abf3('0xe1b')]:_0x95abf3('0x1caf'),'msg':_0x4c6337[_0x95abf3('0x25f4')]?JSON[_0x95abf3('0xbac')](_0x4c6337[_0x95abf3('0x25f4')][_0x95abf3('0x1e70')]):_0x4c6337[_0x95abf3('0x1586')]()});});}function _0x46e1cf(_0x29c02c){const _0x5608f2=_0x364174;_0x57f774[_0x5608f2('0x1d96')][_0x5608f2('0xd83')]({'VoiceExtensionId':_0x169066['id']})['$promise'][_0x5608f2('0x1166')](function(_0x59f531){const _0x356eda=_0x5608f2;if(_0x59f531&&_0x59f531[_0x356eda('0x269a')]&&_0x59f531[_0x356eda('0x269a')][_0x356eda('0x264b')]>0x0)return _0x3dfaa0[_0x356eda('0xfc9')]({'title':_0x356eda('0x2856'),'msg':'You\x20can\x27t\x20remove\x20an\x20outbound\x20route\x20associated\x20to\x20an\x20out\x20prefix'});else{_0x1b3f9d[_0x356eda('0x61a')]=[];const _0x49c38a=_0x2f65f5[_0x356eda('0x1d26')]()['title']('Are\x20you\x20sure?')['content'](_0x356eda('0x59b'))[_0x356eda('0x8e8')](_0x356eda('0x1a42'))['ok'](_0x356eda('0x18'))[_0x356eda('0x3f')](_0x356eda('0x497'))[_0x356eda('0x203b')](_0x29c02c);_0x2f65f5['show'](_0x49c38a)['then'](function(){const _0x272bb9=_0x356eda;_0x57f774[_0x272bb9('0x1deb')][_0x272bb9('0x906')]({'id':_0x1b3f9d['outboundroute']['id']})[_0x272bb9('0xa44')][_0x272bb9('0x1166')](function(){const _0x37128d=_0x272bb9;_0x2cfb05()[_0x37128d('0x127f')](_0x1b3f9d[_0x37128d('0xee4')],{'id':_0x1b3f9d[_0x37128d('0x1aec')]['id']}),_0x3dfaa0['success']({'title':_0x37128d('0x8b0'),'msg':(_0x1b3f9d[_0x37128d('0x1aec')][_0x37128d('0x4f0')]||'outboundroute')+_0x37128d('0x7cd')}),_0x5a9315(_0x1b3f9d[_0x37128d('0x1aec')]);})['catch'](function(_0x421c92){const _0x2e7bde=_0x272bb9;if(_0x421c92[_0x2e7bde('0x25f4')]&&_0x421c92[_0x2e7bde('0x25f4')][_0x2e7bde('0x61a')]&&_0x421c92[_0x2e7bde('0x25f4')]['errors'][_0x2e7bde('0x264b')]){_0x1b3f9d[_0x2e7bde('0x61a')]=_0x421c92[_0x2e7bde('0x25f4')]['errors']||[{'message':_0x421c92[_0x2e7bde('0x1586')](),'type':_0x2e7bde('0x187b')}];for(let _0x27c800=0x0;_0x27c800<_0x421c92[_0x2e7bde('0x25f4')]['errors']['length'];_0x27c800++){_0x3dfaa0[_0x2e7bde('0xfc9')]({'title':_0x421c92[_0x2e7bde('0x25f4')]['errors'][_0x27c800][_0x2e7bde('0x1345')],'msg':_0x421c92[_0x2e7bde('0x25f4')][_0x2e7bde('0x61a')][_0x27c800][_0x2e7bde('0x1e70')]});}}else _0x3dfaa0[_0x2e7bde('0xfc9')]({'title':_0x421c92['status']?_0x2e7bde('0x1e21')+_0x421c92[_0x2e7bde('0x52d')]+_0x2e7bde('0x11e1')+_0x421c92[_0x2e7bde('0xe1b')]:_0x2e7bde('0x187b'),'msg':_0x421c92[_0x2e7bde('0x25f4')]?JSON['stringify'](_0x421c92[_0x2e7bde('0x25f4')]['message']):_0x421c92[_0x2e7bde('0x1e70')]||_0x421c92[_0x2e7bde('0x1586')]()});});},function(){});}});}function _0x2bc18(){const _0xec7a8c=_0x364174;let _0x3c30bc=0x2,_0x50c04a=[];_0x50c04a[_0xec7a8c('0x1514')]({'type':_0xec7a8c('0x587'),'app':_0xec7a8c('0x1816'),'appdata':'CDR(type)=outbound','context':_0x1b3f9d['outboundroute'][_0xec7a8c('0xe1c')],'exten':_0x1b3f9d['outboundroute'][_0xec7a8c('0x23ae')],'priority':_0x3c30bc++,'VoiceExtensionId':_0x1b3f9d['outboundroute']['id']}),_0x50c04a[_0xec7a8c('0x1514')]({'type':'outbound','app':_0xec7a8c('0x1816'),'appdata':'CDR(destination)='+(_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0x2848')]?_0xec7a8c('0x881')+_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0x2848')]+'}':'${EXTEN}'),'context':_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0xe1c')],'exten':_0x1b3f9d[_0xec7a8c('0x1aec')]['exten'],'priority':_0x3c30bc++,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']}),_0x50c04a[_0xec7a8c('0x1514')]({'type':_0xec7a8c('0x587'),'app':_0xec7a8c('0x1816'),'appdata':_0xec7a8c('0x1d93'),'context':_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0xe1c')],'exten':_0x1b3f9d['outboundroute']['exten'],'priority':_0x3c30bc++,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']}),_0x50c04a[_0xec7a8c('0x1514')]({'type':_0xec7a8c('0x587'),'app':_0xec7a8c('0x1816'),'appdata':_0xec7a8c('0x2201'),'context':_0x1b3f9d[_0xec7a8c('0x1aec')]['context'],'exten':_0x1b3f9d['outboundroute']['exten'],'priority':_0x3c30bc++,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']}),_0x50c04a[_0xec7a8c('0x1514')]({'type':_0xec7a8c('0x587'),'app':'Set','appdata':_0xec7a8c('0x28a5'),'context':_0x1b3f9d[_0xec7a8c('0x1aec')]['context'],'exten':_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0x23ae')],'priority':_0x3c30bc++,'VoiceExtensionId':_0x1b3f9d['outboundroute']['id']}),_0x50c04a['push']({'type':_0xec7a8c('0x587'),'app':_0xec7a8c('0x1816'),'appdata':_0xec7a8c('0x24cc')+_0x1b3f9d['outboundroute']['id'],'context':_0x1b3f9d['outboundroute'][_0xec7a8c('0xe1c')],'exten':_0x1b3f9d[_0xec7a8c('0x1aec')]['exten'],'priority':_0x3c30bc++,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']});typeof _0x1b3f9d['outboundroute']['recordingFormat']!==_0xec7a8c('0x1048')&&_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0x28cb')]!==_0xec7a8c('0x192')&&(_0x50c04a[_0xec7a8c('0x1514')]({'type':_0xec7a8c('0x587'),'app':'Set','appdata':_0xec7a8c('0x25a0'),'context':_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0xe1c')],'exten':_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0x23ae')],'priority':_0x3c30bc++,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']}),_0x50c04a[_0xec7a8c('0x1514')]({'type':'outbound','app':'Set','appdata':_0xec7a8c('0xa6')+_0x1b3f9d['outboundroute'][_0xec7a8c('0x28cb')]||0x0,'context':_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0xe1c')],'exten':_0x1b3f9d[_0xec7a8c('0x1aec')]['exten'],'priority':_0x3c30bc++,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']}));for(let _0x254975=0x0,_0xf68da7=0x0;_0x254975<_0x1b3f9d[_0xec7a8c('0x22eb')][_0xec7a8c('0x269a')][_0xec7a8c('0x264b')];_0x254975++,_0xf68da7=0x0){const _0xd6e7af=_0x1b3f9d['outboundrouteApps']['rows'][_0x254975],_0x3dd5d6=[],_0x964253=[];_0xd6e7af[_0xec7a8c('0x164e')]=_0xd6e7af[_0xec7a8c('0x277c')]!==_0xec7a8c('0x16f')?[_0xd6e7af[_0xec7a8c('0x277c')]]:_0xd6e7af[_0xec7a8c('0x186f')]?_0x2cfb05()[_0xec7a8c('0x2563')](_0x2cfb05()[_0xec7a8c('0x1c33')](_0x1b3f9d['intervals'][_0xec7a8c('0x269a')],{'IntervalId':_0xd6e7af[_0xec7a8c('0x186f')]}),_0xec7a8c('0x277c')):[],_0xd6e7af['context']=_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0xe1c')],_0xd6e7af['exten']=_0x1b3f9d['outboundroute'][_0xec7a8c('0x23ae')];_0xd6e7af['type']&&(_0xd6e7af[_0xec7a8c('0x1345')]=_0xd6e7af['type'][_0xec7a8c('0x2574')]());typeof _0xd6e7af[_0xec7a8c('0x1446')]!==_0xec7a8c('0x1048')&&(_0xd6e7af['tag']&&_0xd6e7af[_0xec7a8c('0x1446')]!=='--'&&_0x3dd5d6[_0xec7a8c('0x1514')]({'type':_0xd6e7af[_0xec7a8c('0x1345')][_0xec7a8c('0x2574')](),'app':'Set','appdata':_0xec7a8c('0x1d66')+_0xd6e7af[_0xec7a8c('0x1446')],'context':_0x1b3f9d['outboundroute'][_0xec7a8c('0xe1c')],'exten':_0x1b3f9d['outboundroute'][_0xec7a8c('0x23ae')],'priority':_0xd6e7af[_0xec7a8c('0x164e')]['length']+_0x3c30bc+_0xf68da7++,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']}));_0xd6e7af[_0xec7a8c('0x992')]?_0x3dd5d6[_0xec7a8c('0x1514')]({'type':_0xd6e7af['type'][_0xec7a8c('0x2574')](),'app':_0xec7a8c('0x20cc'),'appdata':_0xec7a8c('0x1093')+_0xd6e7af[_0xec7a8c('0x992')]+')','context':_0x1b3f9d['outboundroute'][_0xec7a8c('0xe1c')],'exten':_0x1b3f9d[_0xec7a8c('0x1aec')]['exten'],'priority':_0xd6e7af['intervals'][_0xec7a8c('0x264b')]+_0x3c30bc+_0xf68da7++,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']}):_0x3dd5d6['push']({'type':_0xd6e7af['type']['toLowerCase'](),'app':_0xec7a8c('0x20cc'),'appdata':_0xec7a8c('0xc9a'),'context':_0x1b3f9d['outboundroute'][_0xec7a8c('0xe1c')],'exten':_0x1b3f9d[_0xec7a8c('0x1aec')]['exten'],'priority':_0xd6e7af[_0xec7a8c('0x164e')][_0xec7a8c('0x264b')]+_0x3c30bc+_0xf68da7++,'VoiceExtensionId':_0x1b3f9d['outboundroute']['id']});for(let _0x1328ec=0x0;_0x1328ec<_0xd6e7af[_0xec7a8c('0x164e')][_0xec7a8c('0x264b')];_0x1328ec++){const _0x220004=_0x3c30bc+_0xd6e7af[_0xec7a8c('0x164e')][_0xec7a8c('0x264b')],_0x32cb7e=_0x1328ec===_0xd6e7af['intervals'][_0xec7a8c('0x264b')]-0x1?_0x3c30bc+_0x3dd5d6['length']+_0x964253[_0xec7a8c('0x264b')]+0x2:_0x3c30bc+_0x1328ec+0x1;_0x3dd5d6[_0xec7a8c('0x57b')](_0x1328ec,0x0,{'type':_0xec7a8c('0x587'),'app':_0xec7a8c('0x15df'),'appdata':_0xd6e7af[_0xec7a8c('0x164e')][_0x1328ec]+'?'+_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0xe1c')]+',${EXTEN},'+_0x220004+':'+_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0xe1c')]+_0xec7a8c('0x883')+_0x32cb7e,'exten':_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0x23ae')],'context':_0x1b3f9d['outboundroute'][_0xec7a8c('0xe1c')],'priority':_0x3c30bc+_0x1328ec,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']});}if(_0xd6e7af[_0xec7a8c('0x83f')]===_0xec7a8c('0x867')){const _0x239b62=_0x2cfb05()['find'](_0x1b3f9d['apps'],{'appType':_0xec7a8c('0x867')});if(_0x239b62&&_0x239b62[_0xec7a8c('0xfe2')]){const _0x351698={},_0x4fa967=_0xd6e7af[_0xec7a8c('0x823')][_0xec7a8c('0x25c8')](','),_0x34a10b=[];for(let _0x2660f9=0x0,_0x2895d5=_0x239b62[_0xec7a8c('0xfe2')][_0xec7a8c('0x264b')];_0x2660f9<_0x2895d5;_0x2660f9++){if(typeof _0x239b62[_0xec7a8c('0xfe2')][_0x2660f9]['param']!==_0xec7a8c('0x1048'))switch(_0x239b62['fields'][_0x2660f9][_0xec7a8c('0x4f0')]){case _0xec7a8c('0x3b2'):_0x351698[_0xec7a8c('0x3b2')]=_0x4fa967[_0x239b62['fields'][_0x2660f9][_0xec7a8c('0x1277')]]['split']('/')[0x1],_0x351698[_0xec7a8c('0x2026')]=_0x4fa967[_0x239b62['fields'][_0x2660f9]['param']]['split']('/')[0x2],_0x351698[_0xec7a8c('0x265a')]=_0x351698['phone']?_0x351698[_0xec7a8c('0x2026')][_0xec7a8c('0x25c8')]('$')[0x0]:undefined,_0x351698['phone']=_0x1b3f9d[_0xec7a8c('0x1aec')]['cutdigits']?(_0x351698[_0xec7a8c('0x265a')]||'')+_0xec7a8c('0x881')+_0x1b3f9d['outboundroute'][_0xec7a8c('0x2848')]+'}':(_0x351698[_0xec7a8c('0x265a')]||'')+_0xec7a8c('0x1d1'),_0x34a10b[_0x239b62[_0xec7a8c('0xfe2')][_0x2660f9][_0xec7a8c('0x1277')]]=[_0xec7a8c('0x1683'),_0x351698['trunk'],_0x351698[_0xec7a8c('0x2026')]][_0xec7a8c('0x45a')]('/');break;case'options':_0x351698[_0xec7a8c('0xd39')]=_0x4fa967[_0x239b62['fields'][_0x2660f9][_0xec7a8c('0x1277')]];_0x1b3f9d['outboundroute'][_0xec7a8c('0x28cb')]!==_0xec7a8c('0x192')?_0x351698[_0xec7a8c('0xd39')][_0xec7a8c('0x2379')](_0xec7a8c('0x1059'))<0x0&&(_0x351698[_0xec7a8c('0xd39')]+=_0xec7a8c('0x1059')):_0x351698[_0xec7a8c('0xd39')]=_0x351698[_0xec7a8c('0xd39')]['replace'](_0xec7a8c('0x1059'),'');_0x34a10b[_0x239b62[_0xec7a8c('0xfe2')][_0x2660f9][_0xec7a8c('0x1277')]]=_0x351698[_0xec7a8c('0xd39')];break;default:_0x34a10b[_0x239b62[_0xec7a8c('0xfe2')][_0x2660f9][_0xec7a8c('0x1277')]]=_0x4fa967[_0x239b62['fields'][_0x2660f9]['param']];}}_0xd6e7af[_0xec7a8c('0x823')]=_0x34a10b[_0xec7a8c('0x45a')](',');}}_0xd6e7af[_0xec7a8c('0xfde')]=_0x3dd5d6['length']?_0x2cfb05()[_0xec7a8c('0x1ef5')](_0x3dd5d6)[_0xec7a8c('0xfde')]+0x1:_0x3c30bc,_0x3c30bc=(_0x964253['length']?_0x2cfb05()[_0xec7a8c('0x1ef5')](_0x964253)[_0xec7a8c('0xfde')]:_0xd6e7af[_0xec7a8c('0xfde')])+0x1,_0x50c04a=_0x2cfb05()['concat'](_0x50c04a,_0x3dd5d6,[_0xd6e7af],_0x964253);}_0x50c04a[_0xec7a8c('0x1514')]({'type':'outbound','app':'Hangup','exten':_0x1b3f9d[_0xec7a8c('0x1aec')][_0xec7a8c('0x23ae')],'context':_0x1b3f9d['outboundroute'][_0xec7a8c('0xe1c')],'priority':_0x3c30bc,'VoiceExtensionId':_0x1b3f9d[_0xec7a8c('0x1aec')]['id']}),_0x57f774[_0xec7a8c('0x1deb')][_0xec7a8c('0x153b')]({'id':_0x1b3f9d['outboundroute']['id']},_0x2cfb05()['sortBy'](_0x50c04a,_0xec7a8c('0xfde')))[_0xec7a8c('0xa44')]['then'](function(_0xe5cd35){const _0xecc6d6=_0xec7a8c;_0x1b3f9d[_0xecc6d6('0x22eb')][_0xecc6d6('0x269a')]=_0xe5cd35[_0xecc6d6('0x269a')];})[_0xec7a8c('0x1a80')](function(_0x182fa2){const _0x2c1507=_0xec7a8c;console[_0x2c1507('0xfc9')](_0x182fa2);});}function _0x265499(_0x4fe380){return _0x4fe380===null?undefined:new Date(_0x4fe380);}function _0x5a9315(_0xa1c106){const _0x971b1=_0x364174;_0x2f65f5[_0x971b1('0x1197')](_0xa1c106);}}const _0x4bcfa1=_0x445f4f,_0x54f7ce=_0x2734b2['p']+_0x36e6f4('0x871'),_0x36adb1=_0x2734b2['p']+_0x36e6f4('0x212e'),_0x22a235=_0x2734b2['p']+_0x36e6f4('0x937');_0x57c4e3[_0x36e6f4('0x1294')]=[_0x36e6f4('0x19e3'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x1d2e'),_0x36e6f4('0x2661'),_0x36e6f4('0x36f'),_0x36e6f4('0x21ef')];const _0x463627={'custom':_0x54f7ce,'interval':_0x36adb1,'outbounddial':_0x22a235};function _0x57c4e3(_0x481604,_0x2a73e4,_0x5d3fa7,_0x1980d2,_0x338332,_0x4c297f,_0x4ecff6){const _0x2f6a00=_0x36e6f4,_0x2b009e=this;_0x2b009e[_0x2f6a00('0x98')]=_0x4ecff6[_0x2f6a00('0x26cd')](),_0x2b009e[_0x2f6a00('0x1aec')]={},_0x2b009e[_0x2f6a00('0x22eb')]={'count':0x0,'rows':[]},_0x2b009e['selectedOutboundRouteApps']=[],_0x2b009e[_0x2f6a00('0x243c')],_0x2b009e['query']={'sort':'priority'},_0x2b009e[_0x2f6a00('0x24d2')]=_0x2cfb05()['reject'](_0x2cfb05()[_0x2f6a00('0x1eba')]([{'app':_0x2f6a00('0x1545'),'appType':'interval','type':_0x2f6a00('0xd94'),'types':[_0x2f6a00('0x597'),_0x2f6a00('0x2853'),_0x2f6a00('0x1480')],'fields':[],'isApp':![]},{'app':'Dial','appType':'outboundDial','context':_0x2f6a00('0xb31'),'type':_0x2f6a00('0xd94'),'icon':_0x2f6a00('0x283f'),'interval':'*,*,*,*','options':'xX','isApp':!![],'extraApi':[{'name':'trunks','field':{'name':_0x2f6a00('0x3b2'),'key':_0x2f6a00('0x4f0')},'route':_0x2f6a00('0x3b2'),'filters':{'fields':_0x2f6a00('0x1776'),'sort':_0x2f6a00('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f3}},{'name':'tags','field':{'name':_0x2f6a00('0x1446'),'key':_0x2f6a00('0x4f0')},'route':_0x2f6a00('0x1446'),'filters':{'fields':'id,name','sort':_0x2f6a00('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x2f6a00('0x14c4'),'name':'trunk','type':_0x2f6a00('0x2550'),'values':'trunks','value':_0x2f6a00('0x912'),'option':_0x2f6a00('0x912'),'required':!![],'param':0x0},{'title':_0x2f6a00('0x1e58'),'name':_0x2f6a00('0x992'),'type':_0x2f6a00('0x1640'),'help':!![]},{'title':_0x2f6a00('0x10a5'),'name':_0x2f6a00('0x265a'),'type':'text'},{'title':_0x2f6a00('0x21c2'),'name':_0x2f6a00('0x1446'),'type':_0x2f6a00('0x2550'),'values':_0x2f6a00('0xb38'),'value':_0x2f6a00('0xc2c'),'option':'tag.name','defaultValues':[{'value':_0x2f6a00('0x19f3'),'option':'None'}]},{'title':_0x2f6a00('0x1861'),'name':_0x2f6a00('0x651'),'type':_0x2f6a00('0xc45'),'min':0x0,'param':0x1},{'title':_0x2f6a00('0x20f3'),'name':_0x2f6a00('0xd39'),'type':_0x2f6a00('0x1640'),'param':0x2},{'title':_0x2f6a00('0x11a2'),'name':_0x2f6a00('0xcac'),'type':_0x2f6a00('0x1640'),'param':0x3}]},{'app':null,'type':'Outbound','appType':_0x2f6a00('0x2853'),'icon':_0x2f6a00('0x283f'),'interval':_0x2f6a00('0x16f'),'isApp':!![],'fields':[{'title':_0x2f6a00('0x7bc'),'name':'app','type':'text','required':!![],'param':0x0},{'title':_0x2f6a00('0x81c'),'name':_0x2f6a00('0x823'),'type':_0x2f6a00('0x1640'),'param':0x1}]}],[_0x2f6a00('0x746')]),{'isApp':![]}),_0x2b009e[_0x2f6a00('0x1480')]={'group':{'name':'opt1','pull':'clone'},'animation':0x64,'sort':![]},_0x2b009e[_0x2f6a00('0x227f')]={'group':{'name':_0x2f6a00('0x103e'),'put':_0x2f6a00('0x1b27')},'animation':0x64,'onAdd':function(_0x525a6e){const _0x11ef1c=_0x2f6a00;_0x525a45(_0x525a6e,_0x525a6e[_0x11ef1c('0x1313')]);},'onSort':function(){_0x39fef6();}},_0x2b009e['init']=_0x18ae71,_0x2b009e['deleteConfirm']=_0x254083,_0x2b009e[_0x2f6a00('0x817')]=_0x3404fa,_0x2b009e[_0x2f6a00('0x2302')]=_0x525a45,_0x2b009e['editInterval']=_0x3eee31,_0x2b009e['deleteOutboundRouteApp']=_0x570712,_0x2b009e['deleteSelectedOutboundRouteApps']=_0x195a0e,_0x2b009e[_0x2f6a00('0x20a6')]=_0x39fef6,_0x2b009e['getIntervals']=_0x4d1c50,_0x2b009e['onVoiceExtensionUpdate']=_0x2d91d0;function _0x18ae71(_0x541a57,_0x7f8da1){const _0x3005a7=_0x2f6a00;_0x2b009e[_0x3005a7('0x1aec')]=_0x541a57,_0x2b009e[_0x3005a7('0x243c')]=typeof _0x7f8da1!==_0x3005a7('0x1048')?_0x7f8da1:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x2b009e[_0x3005a7('0x227f')][_0x3005a7('0xbd0')]=!_0x2b009e[_0x3005a7('0x243c')][_0x3005a7('0x1684')]?!![]:![],_0x338332['on'](_0x3005a7('0x1b08'),_0x2b009e[_0x3005a7('0xf7e')]),_0x2b009e[_0x3005a7('0x2218')][_0x3005a7('0xa51')]=_0x541a57['id'],_0x2b009e[_0x3005a7('0x2218')]['isApp']=!![],_0x2b009e[_0x3005a7('0x2218')][_0x3005a7('0x49d')]=!![],_0x2b009e[_0x3005a7('0x817')](),_0x2b009e[_0x3005a7('0x242')]();}function _0x2d91d0(_0x216ed6){const _0x5861d1=_0x2f6a00;_0x216ed6[_0x5861d1('0xa51')]===_0x2b009e[_0x5861d1('0x1aec')]['id']&&_0x39fef6(!![]);}function _0x254083(_0x1c1d26,_0x4421d1,_0x59784f){const _0x38c2f9=_0x2f6a00,_0x136e59=_0x2a73e4[_0x38c2f9('0x1d26')]()[_0x38c2f9('0xcdc')](_0x38c2f9('0xd0f'))['htmlContent'](_0x38c2f9('0x12b5')+_0x1c1d26[_0x38c2f9('0x746')]+_0x38c2f9('0xace')+_0x38c2f9('0x3f3'))[_0x38c2f9('0x8e8')](_0x38c2f9('0x238d'))['targetEvent'](_0x59784f)['ok']('OK')[_0x38c2f9('0x3f')]('CANCEL');_0x2a73e4[_0x38c2f9('0x1f80')](_0x136e59)['then'](function(){const _0x5132a3=_0x38c2f9;_0x2b009e[_0x5132a3('0x22eb')][_0x5132a3('0x269a')]['splice'](_0x4421d1,0x1),_0x39fef6();},function(){const _0x5ae4bf=_0x38c2f9;console[_0x5ae4bf('0x455')](_0x5ae4bf('0x2d3'));});}function _0x525a45(_0x132911,_0x3f08c8){const _0x49a4dd=_0x2f6a00;if(_0x2b009e[_0x49a4dd('0x22eb')][_0x49a4dd('0x269a')][_0x49a4dd('0x264b')]){const _0x4ca10c=_0x2b009e['outboundrouteApps'][_0x49a4dd('0x269a')][_0x3f08c8]?_0x2b009e[_0x49a4dd('0x22eb')][_0x49a4dd('0x269a')][_0x3f08c8]:_0x2b009e['outboundrouteApps'][_0x49a4dd('0x269a')][0x0],_0x28f373=(_0x4ca10c['appType']||_0x4ca10c['app'])['toLowerCase']();_0x2a73e4[_0x49a4dd('0x1f80')]({'controller':_0x49a4dd('0x98d')+_0x28f373+'DialogController','controllerAs':'vm','templateUrl':_0x463627[_0x28f373],'parent':angular[_0x49a4dd('0x1194')](_0x5d3fa7['body']),'targetEvent':_0x132911,'clickOutsideToClose':!![],'locals':{'outboundrouteApp':_0x4ca10c,'outboundroute':_0x2b009e[_0x49a4dd('0x1aec')],'crudPermissions':_0x2b009e[_0x49a4dd('0x243c')]}})[_0x49a4dd('0x1166')](function(_0x10eef9){const _0x381e21=_0x49a4dd;_0x10eef9&&(_0x10eef9['id']?_0x2b009e[_0x381e21('0x22eb')][_0x381e21('0x269a')][_0x3f08c8]=_0x10eef9:_0x2b009e['outboundrouteApps'][_0x381e21('0x269a')][_0x381e21('0x57b')](_0x3f08c8,0x0,_0x10eef9),_0x39fef6());})[_0x49a4dd('0x1a80')](function(_0x411e3b){const _0x17475d=_0x49a4dd;_0x411e3b&&_0x1980d2['error']({'title':_0x411e3b[_0x17475d('0x52d')]?_0x17475d('0x1e21')+_0x411e3b[_0x17475d('0x52d')]+_0x17475d('0x11e1')+_0x411e3b[_0x17475d('0xe1b')]:'SYSTEM:EDITMODALSHOW','msg':_0x411e3b[_0x17475d('0x25f4')]?JSON['stringify'](_0x411e3b[_0x17475d('0x25f4')]):_0x411e3b[_0x17475d('0x1586')]()});});}}function _0x3eee31(_0x100db8,_0x241fec){const _0x8d89fe=_0x2f6a00;if(_0x2b009e[_0x8d89fe('0x22eb')][_0x8d89fe('0x269a')][_0x8d89fe('0x264b')]){const _0xd79018=_0x2b009e['outboundrouteApps'][_0x8d89fe('0x269a')][_0x241fec]?_0x2b009e[_0x8d89fe('0x22eb')][_0x8d89fe('0x269a')][_0x241fec]:_0x2b009e[_0x8d89fe('0x22eb')][_0x8d89fe('0x269a')][0x0];_0x2a73e4['show']({'controller':_0x8d89fe('0x1f38'),'controllerAs':'vm','templateUrl':_0x36adb1,'parent':angular[_0x8d89fe('0x1194')](_0x5d3fa7[_0x8d89fe('0x8d2')]),'targetEvent':_0x100db8,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0xd79018[_0x8d89fe('0x277c')],'IntervalId':_0xd79018[_0x8d89fe('0x186f')],'application':!![]},'intervals':[],'crudPermissions':_0x2b009e[_0x8d89fe('0x243c')]}})[_0x8d89fe('0x1166')](function(_0x1b999d){const _0x19b6ae=_0x8d89fe;_0x1b999d&&(_0xd79018['interval']=_0x1b999d[_0x19b6ae('0x277c')]||_0x19b6ae('0x16f'),_0xd79018[_0x19b6ae('0x186f')]=_0x1b999d['IntervalId']||null,_0x39fef6());});}}function _0x39fef6(_0x626e16){const _0x51506c=_0x2f6a00;let _0x22819f=0x2,_0x5bdc2c=[];_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':_0x51506c('0x1816'),'appdata':'CDR(type)=outbound','context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'exten':_0x2b009e['outboundroute']['exten'],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}),_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':_0x51506c('0x1816'),'appdata':_0x51506c('0x1230')+(_0x2b009e[_0x51506c('0x1aec')]['cutdigits']?_0x51506c('0x881')+_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x2848')]+'}':_0x51506c('0x1d1')),'context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}),_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':_0x51506c('0x1816'),'appdata':_0x51506c('0x267a')+_0x2b009e['outboundroute']['id'],'context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']});const _0x40861a=_0x22819f++;_0x5bdc2c[_0x51506c('0x1514')]({'type':'outbound','app':'ExecIf','appdata':_0x51506c('0xa65')+(_0x40861a+0x2)+'):Goto('+(_0x40861a+0x1)+')','context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'priority':_0x40861a,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}),_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':_0x51506c('0x1816'),'appdata':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x2848')]?'CDR(prefix)=${EXTEN:0:'+_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x2848')]+'}':_0x51506c('0x1e7c'),'context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}),_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':'Set','appdata':_0x51506c('0x1d93'),'context':_0x2b009e[_0x51506c('0x1aec')]['context'],'exten':_0x2b009e['outboundroute'][_0x51506c('0x23ae')],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}),_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':'Set','appdata':_0x51506c('0x2201'),'context':_0x2b009e[_0x51506c('0x1aec')]['context'],'exten':_0x2b009e['outboundroute'][_0x51506c('0x23ae')],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}),_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':_0x51506c('0x1816'),'appdata':_0x51506c('0x28a5'),'context':_0x2b009e['outboundroute'][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}),_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':_0x51506c('0x1816'),'appdata':_0x51506c('0x24cc')+_0x2b009e[_0x51506c('0x1aec')]['id'],'context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')]['exten'],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']});typeof _0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x28cb')]===_0x51506c('0x1048')&&_0x2b009e[_0x51506c('0x1aec')]['recordingFormat']!=='none'&&(_0x5bdc2c[_0x51506c('0x1514')]({'type':'outbound','app':'Set','appdata':_0x51506c('0x25a0'),'context':_0x2b009e['outboundroute'][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}),_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':'Set','appdata':_0x51506c('0xa6')+_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x28cb')]||0x0,'context':_0x2b009e['outboundroute']['context'],'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'priority':_0x22819f++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}));for(let _0x5edc6b=0x0,_0x3f6dd7=0x0;_0x5edc6b<_0x2b009e['outboundrouteApps']['rows'][_0x51506c('0x264b')];_0x5edc6b++,_0x3f6dd7=0x0){const _0x57e9f2=_0x2b009e['outboundrouteApps'][_0x51506c('0x269a')][_0x5edc6b],_0x4c8c27=[],_0x1859b1=[];_0x57e9f2[_0x51506c('0x164e')]=_0x57e9f2[_0x51506c('0x277c')]!==_0x51506c('0x16f')?[_0x57e9f2[_0x51506c('0x277c')]]:_0x57e9f2[_0x51506c('0x186f')]?_0x2cfb05()[_0x51506c('0x2563')](_0x2cfb05()[_0x51506c('0x1c33')](_0x2b009e[_0x51506c('0x164e')][_0x51506c('0x269a')],{'IntervalId':_0x57e9f2[_0x51506c('0x186f')]}),_0x51506c('0x277c')):[],_0x57e9f2[_0x51506c('0xe1c')]=_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],_0x57e9f2[_0x51506c('0x23ae')]=_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')];_0x57e9f2[_0x51506c('0x1345')]&&(_0x57e9f2[_0x51506c('0x1345')]=_0x57e9f2[_0x51506c('0x1345')][_0x51506c('0x2574')]());typeof _0x57e9f2[_0x51506c('0x1446')]!==_0x51506c('0x1048')&&(_0x57e9f2['tag']&&_0x57e9f2[_0x51506c('0x1446')]!=='--'&&_0x4c8c27[_0x51506c('0x1514')]({'type':_0x57e9f2[_0x51506c('0x1345')][_0x51506c('0x2574')](),'app':_0x51506c('0x1816'),'appdata':'CDR(tag)='+_0x57e9f2[_0x51506c('0x1446')],'context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'priority':_0x57e9f2[_0x51506c('0x164e')][_0x51506c('0x264b')]+_0x22819f+_0x3f6dd7++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}));_0x57e9f2[_0x51506c('0x992')]?_0x4c8c27[_0x51506c('0x1514')]({'type':_0x57e9f2[_0x51506c('0x1345')]['toLowerCase'](),'app':_0x51506c('0x20cc'),'appdata':'$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):Set(CALLERID(all)='+_0x57e9f2[_0x51506c('0x992')]+')','context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')]['exten'],'priority':_0x57e9f2[_0x51506c('0x164e')][_0x51506c('0x264b')]+_0x22819f+_0x3f6dd7++,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}):_0x4c8c27['push']({'type':_0x57e9f2['type']['toLowerCase'](),'app':_0x51506c('0x20cc'),'appdata':_0x51506c('0xc9a'),'context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'priority':_0x57e9f2['intervals'][_0x51506c('0x264b')]+_0x22819f+_0x3f6dd7++,'VoiceExtensionId':_0x2b009e['outboundroute']['id']});for(let _0x5c2c44=0x0;_0x5c2c44<_0x57e9f2[_0x51506c('0x164e')][_0x51506c('0x264b')];_0x5c2c44++){const _0x1ea243=_0x22819f+_0x57e9f2[_0x51506c('0x164e')][_0x51506c('0x264b')],_0x2fd9b1=_0x5c2c44===_0x57e9f2['intervals'][_0x51506c('0x264b')]-0x1?_0x22819f+_0x4c8c27[_0x51506c('0x264b')]+_0x1859b1[_0x51506c('0x264b')]+0x2:_0x22819f+_0x5c2c44+0x1;_0x4c8c27['splice'](_0x5c2c44,0x0,{'type':'outbound','app':_0x51506c('0x15df'),'appdata':_0x57e9f2['intervals'][_0x5c2c44]+'?'+_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')]+',${EXTEN},'+_0x1ea243+':'+_0x2b009e['outboundroute'][_0x51506c('0xe1c')]+_0x51506c('0x883')+_0x2fd9b1,'exten':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x23ae')],'context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'priority':_0x22819f+_0x5c2c44,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']});}if(_0x626e16&&_0x57e9f2[_0x51506c('0x83f')]==='outboundDial'){const _0x46deb3=_0x2cfb05()[_0x51506c('0xc38')](_0x2b009e['apps'],{'appType':'outboundDial'});if(_0x46deb3&&_0x46deb3[_0x51506c('0xfe2')]){const _0x2ae341={},_0x12d084=_0x57e9f2[_0x51506c('0x823')][_0x51506c('0x25c8')](','),_0x48b97c=[];for(let _0x9a8a63=0x0,_0x142853=_0x46deb3[_0x51506c('0xfe2')][_0x51506c('0x264b')];_0x9a8a63<_0x142853;_0x9a8a63++){if(typeof _0x46deb3[_0x51506c('0xfe2')][_0x9a8a63][_0x51506c('0x1277')]!==_0x51506c('0x1048'))switch(_0x46deb3[_0x51506c('0xfe2')][_0x9a8a63][_0x51506c('0x4f0')]){case _0x51506c('0x3b2'):_0x2ae341[_0x51506c('0x3b2')]=_0x12d084[_0x46deb3[_0x51506c('0xfe2')][_0x9a8a63]['param']][_0x51506c('0x25c8')]('/')[0x1],_0x2ae341[_0x51506c('0x2026')]=_0x12d084[_0x46deb3[_0x51506c('0xfe2')][_0x9a8a63][_0x51506c('0x1277')]][_0x51506c('0x25c8')]('/')[0x2],_0x2ae341['prefix']=_0x2ae341[_0x51506c('0x2026')]?_0x2ae341[_0x51506c('0x2026')]['split']('$')[0x0]:undefined,_0x2ae341[_0x51506c('0x2026')]=_0x2b009e[_0x51506c('0x1aec')]['cutdigits']?(_0x2ae341[_0x51506c('0x265a')]||'')+_0x51506c('0x881')+_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0x2848')]+'}':(_0x2ae341[_0x51506c('0x265a')]||'')+'${EXTEN}',_0x48b97c[_0x46deb3[_0x51506c('0xfe2')][_0x9a8a63][_0x51506c('0x1277')]]=['SIP',_0x2ae341[_0x51506c('0x3b2')],_0x2ae341[_0x51506c('0x2026')]]['join']('/');break;case'options':_0x2ae341['options']=_0x12d084[_0x46deb3[_0x51506c('0xfe2')][_0x9a8a63][_0x51506c('0x1277')]];_0x2b009e[_0x51506c('0x1aec')]['recordingFormat']!==_0x51506c('0x192')?_0x2ae341[_0x51506c('0xd39')][_0x51506c('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x2ae341['options']+=_0x51506c('0x1059')):_0x2ae341[_0x51506c('0xd39')]=_0x2ae341[_0x51506c('0xd39')][_0x51506c('0xf3')]('U(xcally-mixmonitor-context)','');_0x48b97c[_0x46deb3[_0x51506c('0xfe2')][_0x9a8a63][_0x51506c('0x1277')]]=_0x2ae341[_0x51506c('0xd39')];break;default:_0x48b97c[_0x46deb3[_0x51506c('0xfe2')][_0x9a8a63][_0x51506c('0x1277')]]=_0x12d084[_0x46deb3['fields'][_0x9a8a63][_0x51506c('0x1277')]];}}_0x57e9f2[_0x51506c('0x823')]=_0x48b97c['join'](',');}}_0x57e9f2[_0x51506c('0xfde')]=_0x4c8c27['length']?_0x2cfb05()['last'](_0x4c8c27)['priority']+0x1:_0x22819f,_0x22819f=(_0x1859b1[_0x51506c('0x264b')]?_0x2cfb05()['last'](_0x1859b1)[_0x51506c('0xfde')]:_0x57e9f2[_0x51506c('0xfde')])+0x1,_0x5bdc2c=_0x2cfb05()[_0x51506c('0x1c6a')](_0x5bdc2c,_0x4c8c27,[_0x57e9f2],_0x1859b1);}_0x5bdc2c[_0x51506c('0x1514')]({'type':_0x51506c('0x587'),'app':'Hangup','exten':_0x2b009e['outboundroute'][_0x51506c('0x23ae')],'context':_0x2b009e[_0x51506c('0x1aec')][_0x51506c('0xe1c')],'priority':_0x22819f,'VoiceExtensionId':_0x2b009e[_0x51506c('0x1aec')]['id']}),_0x481604[_0x51506c('0x1deb')][_0x51506c('0x153b')]({'id':_0x2b009e['outboundroute']['id']},_0x2cfb05()[_0x51506c('0x1eba')](_0x5bdc2c,_0x51506c('0xfde')))[_0x51506c('0xa44')][_0x51506c('0x1166')](function(_0x28685f){const _0x2c66b5=_0x51506c;_0x2b009e[_0x2c66b5('0x22eb')][_0x2c66b5('0x269a')]=_0x28685f['rows'];})['catch'](function(_0x4ebd06){const _0x2f859d=_0x51506c;console[_0x2f859d('0xfc9')](_0x4ebd06);});}function _0x716a2d(_0x304dea){const _0x40c59d=_0x2f6a00;_0x2b009e[_0x40c59d('0x22eb')]=_0x304dea||{'count':0x0,'rows':[]};}function _0x4d1c50(){const _0x6049e7=_0x2f6a00;return _0x481604[_0x6049e7('0x277c')][_0x6049e7('0xd83')]({'fields':_0x6049e7('0x1d39')})[_0x6049e7('0xa44')][_0x6049e7('0x1166')](function(_0x3efa9c){const _0x483800=_0x6049e7;_0x2b009e[_0x483800('0x164e')]=_0x3efa9c;})[_0x6049e7('0x1a80')](function(_0xb18eb6){const _0x580a71=_0x6049e7;console[_0x580a71('0xfc9')](_0xb18eb6);});}function _0x3404fa(){const _0xbe7dfb=_0x2f6a00;_0x2b009e[_0xbe7dfb('0x1f48')]=_0x481604['voiceExtension'][_0xbe7dfb('0xd83')](_0x2b009e[_0xbe7dfb('0x2218')],_0x716a2d)[_0xbe7dfb('0xa44')];}function _0x570712(_0xe5e2f2){const _0x2042a7=_0x2f6a00;_0x2cfb05()[_0x2042a7('0x127f')](_0x2b009e['outboundrouteApps'][_0x2042a7('0x269a')],{'id':_0xe5e2f2['id']}),_0x39fef6(),_0x1980d2[_0x2042a7('0x103b')]({'title':_0x2042a7('0x11c0'),'msg':_0xe5e2f2[_0x2042a7('0x746')]?_0xe5e2f2[_0x2042a7('0x746')]+_0x2042a7('0x7cd'):''});}function _0x195a0e(_0x5cb34d){const _0x2a51e2=_0x2f6a00,_0x59ecef=_0x2a73e4['confirm']()[_0x2a51e2('0xcdc')](_0x2a51e2('0x2338'))[_0x2a51e2('0xf3c')](_0x2a51e2('0x12b5')+_0x2b009e[_0x2a51e2('0xfeb')]['length']+'\x20selected'+_0x2a51e2('0x3f3'))[_0x2a51e2('0x8e8')](_0x2a51e2('0x106e'))[_0x2a51e2('0x203b')](_0x5cb34d)['ok']('OK')[_0x2a51e2('0x3f')](_0x2a51e2('0x2d3'));_0x2a73e4[_0x2a51e2('0x1f80')](_0x59ecef)[_0x2a51e2('0x1166')](function(){const _0x2f0135=_0x2a51e2;_0x2b009e[_0x2f0135('0xfeb')][_0x2f0135('0x2782')](function(_0x42d663){const _0x400399=_0x2f0135;_0x2cfb05()['remove'](_0x2b009e[_0x400399('0x22eb')][_0x400399('0x269a')],{'id':_0x42d663['id']});}),_0x2b009e['selectedOutboundRouteApps']=[],_0x39fef6();});}_0x4c297f[_0x2f6a00('0x3d2')](_0x2f6a00('0x1c3f'),function(){const _0x4faa82=_0x2f6a00;_0x338332[_0x4faa82('0x1800')]('voiceExtension:update');});}const _0x3fd899=_0x57c4e3;_0x2bb2e8['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'outboundrouteApp',_0x36e6f4('0x1aec'),_0x36e6f4('0x19e3'),'Auth','crudPermissions'];function _0x2bb2e8(_0x16cb07,_0x4c5343,_0x482d6e,_0x1ea163,_0x45e7fc,_0x160d9b,_0x4e98bb,_0x4f2136){const _0x4e09f6=_0x36e6f4,_0x57079a=this;_0x57079a[_0x4e09f6('0x98')]=_0x4e98bb[_0x4e09f6('0x26cd')](),_0x57079a[_0x4e09f6('0x61a')]=[],_0x57079a['title']=_0x4e09f6('0xd79')+(_0x1ea163[_0x4e09f6('0x83f')]||_0x1ea163['app'])['toUpperCase'](),_0x57079a[_0x4e09f6('0x2853')]=angular[_0x4e09f6('0x225f')](_0x1ea163),_0x57079a[_0x4e09f6('0x243c')]=_0x4f2136,_0x57079a['hasModulePermissions']={};if(_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x823')])switch(_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x83f')]?_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x83f')][_0x4e09f6('0x2574')]():_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x746')][_0x4e09f6('0x2574')]()){case'custom':break;case _0x4e09f6('0xded'):{const _0x421b1c=_0x57079a[_0x4e09f6('0x2853')]['appdata']['split'](',');_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x7ca')]=_0x421b1c[0x0],_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0xedb')]=_0x421b1c[0x1],_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1634')]=_0x421b1c[_0x4e09f6('0x233')](0x2,_0x421b1c[_0x4e09f6('0x264b')])[_0x4e09f6('0x45a')](',');}break;case _0x4e09f6('0x1636'):{const _0x8f91b2=_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x823')][_0x4e09f6('0x25c8')](',');_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1b0a')]=_0x8f91b2[0x0],_0x57079a['custom'][_0x4e09f6('0x27f3')]=_0x8f91b2[0x1],_0x57079a[_0x4e09f6('0x2853')]['privateKey']=_0x8f91b2[0x2],_0x57079a[_0x4e09f6('0x2853')]['language']=_0x8f91b2[0x3],_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1634')]=_0x8f91b2['slice'](0x4,_0x8f91b2[_0x4e09f6('0x264b')])[_0x4e09f6('0x45a')](',');}break;case _0x4e09f6('0x86c'):{const _0x3741b2=_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x823')][_0x4e09f6('0x25c8')](',');_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0xee6')]=_0x3741b2[0x0],_0x57079a['custom'][_0x4e09f6('0x125')]=_0x3741b2[0x1],_0x57079a[_0x4e09f6('0x2853')]['lexregion']=_0x3741b2[0x2],_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1ac4')]=_0x3741b2[0x3],_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1634')]=_0x3741b2[_0x4e09f6('0x233')](0x4,_0x3741b2[_0x4e09f6('0x264b')])['join'](',');}break;case'autoreply':{const _0x3a234a=_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x823')][_0x4e09f6('0x25c8')](',');_0x57079a[_0x4e09f6('0x2853')]['times']=isNaN(_0x3a234a[0x0])?_0x3a234a[0x0]:parseInt(_0x3a234a[0x0],0xa),_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1640')]=_0x3a234a['slice'](0x1,_0x3a234a[_0x4e09f6('0x264b')])[_0x4e09f6('0x45a')](',');}break;case _0x4e09f6('0x1e70'):_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1640')]=_0x57079a['custom'][_0x4e09f6('0x823')];break;case _0x4e09f6('0xceb'):_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x4f0')]=_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x823')][_0x4e09f6('0x25c8')]('=')[0x0],_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x18e0')]=_0x57079a['custom'][_0x4e09f6('0x823')][_0x4e09f6('0x25c8')]('=')[0x1];break;case _0x4e09f6('0x1034'):_0x57079a[_0x4e09f6('0x2853')]['project']=_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x823')];break;default:{const _0x1de39e=_0x57079a['custom'][_0x4e09f6('0x823')][_0x4e09f6('0x25c8')](',');_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x746')]=_0x2cfb05()[_0x4e09f6('0x1081')](_0x1de39e[0x0])?_0x1de39e[0x0]:isNaN(_0x1de39e[0x0])?_0x1de39e[0x0]:parseInt(_0x1de39e[0x0],0xa),_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x823')]=_0x2cfb05()['isEmpty'](_0x1de39e[0x1])?_0x1de39e[0x1]:isNaN(_0x1de39e[0x1])?_0x1de39e[0x1]:parseInt(_0x1de39e[0x1],0xa);}break;}else{}_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1345')]&&_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1345')][_0x4e09f6('0x2574')]()===_0x4e09f6('0x587')&&_0x57079a['custom'][_0x4e09f6('0x83f')]['toLowerCase']()===_0x4e09f6('0x2884')&&(_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x265a')]=_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x2026')]?_0x57079a[_0x4e09f6('0x2853')]['phone'][_0x4e09f6('0x25c8')]('$')[0x0]:undefined,_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x1f02')]=_0x57079a['custom'][_0x4e09f6('0x992')]?_0x4e09f6('0xa4c')+_0x57079a[_0x4e09f6('0x2853')][_0x4e09f6('0x992')]:undefined);_0x57079a[_0x4e09f6('0x16ae')]=_0x128f7f,_0x57079a[_0x4e09f6('0x24a0')]=_0x5a9d18;function _0x128f7f(){const _0x1f7aff=_0x4e09f6;_0x57079a[_0x1f7aff('0x61a')]=[];const _0x4c7a0c=[];_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x1345')]&&_0x57079a['custom']['type'][_0x1f7aff('0x2574')]()==='outbound'&&_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x83f')]==='outboundDial'&&(_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x2026')]=_0x45e7fc[_0x1f7aff('0x2848')]?(_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x265a')]||'')+_0x1f7aff('0x881')+_0x45e7fc[_0x1f7aff('0x2848')]+'}':(_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x265a')]||'')+_0x1f7aff('0x1d1'),_0x45e7fc[_0x1f7aff('0x28cb')]!==_0x1f7aff('0x192')?_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0xd39')][_0x1f7aff('0x2379')](_0x1f7aff('0x1059'))<0x0&&(_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0xd39')]+=_0x1f7aff('0x1059')):_0x57079a[_0x1f7aff('0x2853')]['options']=_0x57079a['custom'][_0x1f7aff('0xd39')]['replace'](_0x1f7aff('0x1059'),''));if(_0x57079a['custom'][_0x1f7aff('0x83f')]&&_0x57079a['custom'][_0x1f7aff('0x83f')]===_0x1f7aff('0x2853')){}else switch((_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x746')]||_0x57079a['custom'][_0x1f7aff('0x83f')])[_0x1f7aff('0x2574')]()){case'set':_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x823')]=_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x4f0')]+'='+_0x57079a[_0x1f7aff('0x2853')]['value'];break;case'custom':break;default:_0x4c7a0c[0x0]=_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x746')],_0x4c7a0c[0x1]=_0x57079a['custom'][_0x1f7aff('0x823')],_0x57079a[_0x1f7aff('0x2853')][_0x1f7aff('0x823')]=_0x4c7a0c[_0x1f7aff('0x45a')](',');}_0x5a9d18(_0x57079a['custom']);}function _0x5a9d18(_0x1bf0c5){_0x16cb07['hide'](_0x1bf0c5);}}const _0x3504e3=_0x2bb2e8;_0x295a65['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x265d'),_0x36e6f4('0x25d0'),_0x36e6f4('0x124d'),'interval',_0x36e6f4('0x164e'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x295a65(_0x4e2c26,_0x4c616b,_0x421192,_0x25f741,_0x51902e,_0x91504e,_0x910c71,_0x4f475b,_0x5e87ff,_0x433fe5){const _0xdeb35d=_0x36e6f4,_0x380607=this;_0x380607[_0xdeb35d('0x98')]=_0x5e87ff[_0xdeb35d('0x26cd')](),_0x380607[_0xdeb35d('0x61a')]=[],_0x380607[_0xdeb35d('0xcdc')]=_0xdeb35d('0x2879'),_0x380607[_0xdeb35d('0x277c')]=angular[_0xdeb35d('0x225f')](_0x51902e),_0x380607[_0xdeb35d('0x164e')]=_0x91504e,_0x380607[_0xdeb35d('0x99d')]=![],_0x380607[_0xdeb35d('0x6aa')]=[_0xdeb35d('0x597'),_0xdeb35d('0x2853'),_0xdeb35d('0x1480')],_0x380607[_0xdeb35d('0x243c')]=_0x433fe5,_0x380607[_0xdeb35d('0x5ef')]=_0x25f741['getDaysOfWeek'](),_0x380607[_0xdeb35d('0x10b4')]=_0x25f741['getMonthNumber'](),_0x380607[_0xdeb35d('0x2259')]=_0x25f741[_0xdeb35d('0x1c39')](),_0x380607[_0xdeb35d('0x1fc0')]=_0x25f741[_0xdeb35d('0x2489')]();if(!_0x380607[_0xdeb35d('0x277c')])_0x380607[_0xdeb35d('0x277c')]={'interval':_0xdeb35d('0x16f')},_0x380607['type']=_0xdeb35d('0x597'),_0x380607[_0xdeb35d('0xcdc')]='TOOLS.NEW_INTERVAL',_0x380607[_0xdeb35d('0x99d')]=!![];else{if(_0x380607[_0xdeb35d('0x277c')][_0xdeb35d('0x277c')]!==_0xdeb35d('0x16f')){_0x380607['type']='custom';const _0x506313=_0x380607[_0xdeb35d('0x277c')][_0xdeb35d('0x277c')][_0xdeb35d('0x25c8')](','),_0x4611e6=_0x506313[0x0],_0x1373c9=_0x506313[0x1],_0x30139f=_0x506313[0x2],_0x3326e6=_0x506313[0x3];if(_0x4611e6!=='*'){const _0x29019b=_0x4611e6[_0xdeb35d('0x25c8')]('-')[0x0],_0x44616e=_0x4611e6[_0xdeb35d('0x25c8')]('-')[0x1];let _0x3d2474;_0x3d2474=new Date(),_0x3d2474['setHours'](Number(_0x29019b['split'](':')[0x0])),_0x3d2474[_0xdeb35d('0x790')](Number(_0x29019b[_0xdeb35d('0x25c8')](':')[0x1])),_0x380607[_0xdeb35d('0x64d')]=_0x3d2474,_0x3d2474=new Date(),_0x3d2474['setHours'](Number(_0x44616e['split'](':')[0x0])),_0x3d2474['setMinutes'](Number(_0x44616e['split'](':')[0x1])),_0x380607[_0xdeb35d('0x2076')]=_0x3d2474;}_0x1373c9!=='*'&&(_0x380607[_0xdeb35d('0x1eca')]=_0x1373c9[_0xdeb35d('0x25c8')]('-')[0x0],_0x380607[_0xdeb35d('0x1b81')]=_0x1373c9[_0xdeb35d('0x25c8')]('-')[0x1]),_0x30139f!=='*'&&(_0x380607[_0xdeb35d('0x103d')]=_0x30139f[_0xdeb35d('0x25c8')]('-')[0x0],_0x380607[_0xdeb35d('0x1dbb')]=_0x30139f['split']('-')[0x1]),_0x3326e6!=='*'&&(_0x380607['monthFrom']=_0x3326e6[_0xdeb35d('0x25c8')]('-')[0x0],_0x380607[_0xdeb35d('0x1125')]=_0x3326e6[_0xdeb35d('0x25c8')]('-')[0x1]);}else _0x380607[_0xdeb35d('0x1345')]=_0xdeb35d('0x597');}_0x4e2c26[_0xdeb35d('0x23f')]['id']&&!_0x380607[_0xdeb35d('0x277c')][_0xdeb35d('0x50d')]&&(_0x380607['interval'][_0xdeb35d('0x186f')]=_0x4e2c26[_0xdeb35d('0x23f')]['id']);_0x380607['interval'][_0xdeb35d('0x186f')]&&_0x380607[_0xdeb35d('0x277c')][_0xdeb35d('0x50d')]&&(_0x380607['type']='list');_0x380607[_0xdeb35d('0x1ebf')]=_0x419d85,_0x380607['saveInterval']=_0xb29a6b,_0x380607['closeDialog']=_0x2d21f5;_0x380607['interval'][_0xdeb35d('0x50d')]&&(_0x5e87ff[_0xdeb35d('0x1ac6')](_0xdeb35d('0xa7c'))?_0x4f475b[_0xdeb35d('0x277c')][_0xdeb35d('0xd83')]({'fields':_0xdeb35d('0xd0a'),'IntervalId':'null','nolimit':!![]})[_0xdeb35d('0xa44')]['then'](function(_0x43947b){const _0x2ad7b3=_0xdeb35d;_0x380607[_0x2ad7b3('0x164e')]=_0x43947b['rows']||[];})[_0xdeb35d('0x1a80')](function(_0x221ed3){const _0x3323f4=_0xdeb35d;_0x910c71[_0x3323f4('0xfc9')]({'title':_0x221ed3[_0x3323f4('0x52d')]?'API:'+_0x221ed3[_0x3323f4('0x52d')]+'\x20-\x20'+_0x221ed3[_0x3323f4('0xe1b')]:_0x3323f4('0xbb4'),'msg':_0x221ed3[_0x3323f4('0x25f4')]?JSON['stringify'](_0x221ed3[_0x3323f4('0x25f4')]):_0x221ed3[_0x3323f4('0x1586')]()});}):_0x4f475b['interval'][_0xdeb35d('0xd83')]({'fields':_0xdeb35d('0xd0a'),'IntervalId':'null','nolimit':!![]})[_0xdeb35d('0xa44')][_0xdeb35d('0x1166')](function(_0xb3c477){_0x380607['intervals']=_0xb3c477['rows']||[];})[_0xdeb35d('0x1166')](function(){const _0x4c8a2e=_0xdeb35d;return _0x4f475b['userProfileSection'][_0x4c8a2e('0xd83')]({'userProfileId':_0x380607['currentUser'][_0x4c8a2e('0xb86')],'sectionId':0x3ec})['$promise'];})[_0xdeb35d('0x1166')](function(_0x2b26c6){const _0x5a44b3=_0xdeb35d,_0x3f29cf=_0x2b26c6&&_0x2b26c6['rows']?_0x2b26c6[_0x5a44b3('0x269a')][0x0]:null;if(!_0x3f29cf)_0x380607[_0x5a44b3('0x164e')]=[];else{if(!_0x3f29cf['autoAssociation'])return _0x4f475b[_0x5a44b3('0x4b5')][_0x5a44b3('0xd83')]({'sectionId':_0x3f29cf['id']})[_0x5a44b3('0xa44')][_0x5a44b3('0x1166')](function(_0x590f8d){const _0x3a86c9=_0x5a44b3,_0x3f4485=_0x590f8d&&_0x590f8d['rows']?_0x590f8d[_0x3a86c9('0x269a')]:[],_0x1879d4=[];let _0x22e75b=null;_0x380607[_0x3a86c9('0x277c')]&&(_0x22e75b=_0x2cfb05()[_0x3a86c9('0xc38')](_0x380607[_0x3a86c9('0x164e')],{'name':_0x380607['interval'][_0x3a86c9('0x186f')]})),_0x22e75b&&!_0x2cfb05()[_0x3a86c9('0x1798')](_0x3f4485,[_0x3a86c9('0x24e8'),_0x22e75b['id']])&&_0x380607[_0x3a86c9('0x164e')][_0x3a86c9('0x2782')](function(_0x538c63){const _0x2eb015=_0x3a86c9;_0x538c63['id']===_0x22e75b['id']&&(_0x538c63[_0x2eb015('0x2378')]=![],_0x1879d4[_0x2eb015('0x1514')](_0x538c63));}),_0x380607[_0x3a86c9('0x164e')]=_0x1879d4;});}})[_0xdeb35d('0x1a80')](function(_0x5bddfe){const _0x3018c9=_0xdeb35d;_0x910c71[_0x3018c9('0xfc9')]({'title':_0x5bddfe[_0x3018c9('0x52d')]?_0x3018c9('0x1e21')+_0x5bddfe[_0x3018c9('0x52d')]+_0x3018c9('0x11e1')+_0x5bddfe[_0x3018c9('0xe1b')]:_0x3018c9('0xbb4'),'msg':_0x5bddfe['data']?JSON[_0x3018c9('0xbac')](_0x5bddfe['data']):_0x5bddfe[_0x3018c9('0x1586')]()});}));function _0x225c62(){const _0x2214db=_0xdeb35d;switch(_0x380607[_0x2214db('0x1345')]){case _0x2214db('0x597'):case _0x2214db('0x1480'):return _0x2214db('0x16f');case _0x2214db('0x2853'):{const _0x12f9f6=[];if(_0x380607[_0x2214db('0x64d')]!=='*'&&_0x380607[_0x2214db('0x64d')]&&_0x380607['timeRangeTo']){const _0x51de2f=(_0x380607[_0x2214db('0x64d')]['getHours']()<0xa?'0':'')+_0x380607[_0x2214db('0x64d')][_0x2214db('0x11fe')]()+':'+((_0x380607['timeRangeFrom'][_0x2214db('0x234')]()<0xa?'0':'')+_0x380607['timeRangeFrom']['getMinutes']()),_0x51da59=(_0x380607[_0x2214db('0x2076')]['getHours']()<0xa?'0':'')+_0x380607['timeRangeTo'][_0x2214db('0x11fe')]()+':'+((_0x380607['timeRangeTo']['getMinutes']()<0xa?'0':'')+_0x380607['timeRangeTo'][_0x2214db('0x234')]());_0x12f9f6[_0x2214db('0x1514')](_0x51de2f+'-'+_0x51da59);}else _0x12f9f6['push']('*');return _0x380607[_0x2214db('0x1eca')]?_0x380607['dayOfWeekTo']?_0x12f9f6['push'](_0x380607['dayOfWeekFrom']+'-'+_0x380607[_0x2214db('0x1b81')]):_0x12f9f6[_0x2214db('0x1514')](_0x380607[_0x2214db('0x1eca')]):_0x12f9f6[_0x2214db('0x1514')]('*'),_0x380607[_0x2214db('0x103d')]?_0x380607[_0x2214db('0x1dbb')]?_0x12f9f6[_0x2214db('0x1514')](_0x380607['monthDayFrom']+'-'+_0x380607[_0x2214db('0x1dbb')]):_0x12f9f6[_0x2214db('0x1514')](_0x380607['monthDayFrom']):_0x12f9f6['push']('*'),_0x380607[_0x2214db('0xdec')]?_0x380607[_0x2214db('0x1125')]?_0x12f9f6[_0x2214db('0x1514')](_0x380607[_0x2214db('0xdec')]+'-'+_0x380607[_0x2214db('0x1125')]):_0x12f9f6[_0x2214db('0x1514')](_0x380607[_0x2214db('0xdec')]):_0x12f9f6[_0x2214db('0x1514')]('*'),_0x12f9f6[_0x2214db('0x45a')]();}}}function _0x419d85(){const _0x5ec588=_0xdeb35d;_0x380607[_0x5ec588('0x61a')]=[],_0x380607['interval']['interval']=_0x225c62(),_0x4f475b[_0x5ec588('0x277c')][_0x5ec588('0x9cc')](_0x380607[_0x5ec588('0x277c')])[_0x5ec588('0xa44')][_0x5ec588('0x1166')](function(_0x58fe4f){const _0x1df467=_0x5ec588;_0x380607[_0x1df467('0x164e')]['push'](_0x58fe4f),_0x910c71['success']({'title':_0x1df467('0xf10'),'msg':_0x380607[_0x1df467('0x277c')][_0x1df467('0x4f0')]?_0x380607[_0x1df467('0x277c')][_0x1df467('0x4f0')]+_0x1df467('0x1eda'):''}),_0x2d21f5();})[_0x5ec588('0x1a80')](function(_0x5ae832){const _0x242465=_0x5ec588;console['error'](_0x5ae832),_0x380607[_0x242465('0x61a')]=_0x5ae832[_0x242465('0x25f4')][_0x242465('0x61a')]||[{'message':_0x5ae832[_0x242465('0x1586')](),'type':_0x242465('0x1192')}];});}function _0xb29a6b(){const _0x4feb74=_0xdeb35d;_0x380607[_0x4feb74('0x61a')]=[],_0x380607[_0x4feb74('0x277c')][_0x4feb74('0x277c')]=_0x225c62(),_0x380607[_0x4feb74('0x277c')][_0x4feb74('0x50d')]?(_0x380607[_0x4feb74('0x1345')]!=='list'&&(_0x380607[_0x4feb74('0x277c')][_0x4feb74('0x186f')]=null),_0x2d21f5(_0x380607['interval'])):_0x4f475b[_0x4feb74('0x277c')][_0x4feb74('0x1449')]({'id':_0x380607[_0x4feb74('0x277c')]['id']},_0x380607[_0x4feb74('0x277c')])[_0x4feb74('0xa44')]['then'](function(_0x3338d3){const _0x4b76d8=_0x4feb74,_0x222857=_0x2cfb05()[_0x4b76d8('0xc38')](_0x380607[_0x4b76d8('0x164e')],{'id':_0x3338d3['id']});_0x222857&&_0x2cfb05()[_0x4b76d8('0xcc3')](_0x222857,_0x3338d3),_0x910c71[_0x4b76d8('0x103b')]({'title':_0x4b76d8('0x1243'),'msg':_0x4b76d8('0x1666')}),_0x2d21f5();})['catch'](function(_0x3e48f0){const _0x2877ad=_0x4feb74;console[_0x2877ad('0xfc9')](_0x3e48f0),_0x380607[_0x2877ad('0x61a')]=_0x3e48f0[_0x2877ad('0x25f4')]['errors']||[{'message':_0x3e48f0[_0x2877ad('0x1586')](),'type':_0x2877ad('0x2725')}];});}function _0x2d21f5(_0x2dbbc9){const _0x3c4581=_0xdeb35d;_0x4c616b[_0x3c4581('0x1197')](_0x2dbbc9);}}const _0x513f4d=_0x295a65;_0xff5f5a[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1f12'),_0x36e6f4('0x1aec'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0xff5f5a(_0x2fd72c,_0x29dc7e,_0xbe108f,_0x373518,_0x5e5dce,_0x16b3d5,_0x1bb467,_0x17de02){const _0x204c5b=_0x36e6f4,_0x48ea04=this;_0x48ea04[_0x204c5b('0x98')]=_0x1bb467[_0x204c5b('0x26cd')](),_0x48ea04['errors']=[],_0x48ea04[_0x204c5b('0xcdc')]='VOICE.EDIT_'+(_0x373518[_0x204c5b('0x83f')]||_0x373518[_0x204c5b('0x746')])['toUpperCase'](),_0x48ea04[_0x204c5b('0x2884')]=angular[_0x204c5b('0x225f')](_0x373518),_0x48ea04[_0x204c5b('0x243c')]=_0x17de02,_0x48ea04[_0x204c5b('0x128b')]={};if(_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x823')])switch(_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x83f')]?_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x83f')][_0x204c5b('0x2574')]():_0x48ea04[_0x204c5b('0x2884')]['app']['toLowerCase']()){case _0x204c5b('0x2853'):break;case _0x204c5b('0xded'):{const _0x7f6bda=_0x48ea04[_0x204c5b('0x2884')]['appdata'][_0x204c5b('0x25c8')](',');_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x7ca')]=_0x7f6bda[0x0],_0x48ea04[_0x204c5b('0x2884')]['language']=_0x7f6bda[0x1],_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x1634')]=_0x7f6bda['slice'](0x2,_0x7f6bda[_0x204c5b('0x264b')])[_0x204c5b('0x45a')](',');}break;case _0x204c5b('0x1636'):{const _0x2651d0=_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x823')][_0x204c5b('0x25c8')](',');_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x1b0a')]=_0x2651d0[0x0],_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x27f3')]=_0x2651d0[0x1],_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x170e')]=_0x2651d0[0x2],_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0xedb')]=_0x2651d0[0x3],_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x1634')]=_0x2651d0[_0x204c5b('0x233')](0x4,_0x2651d0[_0x204c5b('0x264b')])[_0x204c5b('0x45a')](',');}break;case _0x204c5b('0x86c'):{const _0x20b0f1=_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x823')][_0x204c5b('0x25c8')](',');_0x48ea04['outbounddial'][_0x204c5b('0xee6')]=_0x20b0f1[0x0],_0x48ea04['outbounddial'][_0x204c5b('0x125')]=_0x20b0f1[0x1],_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x25a2')]=_0x20b0f1[0x2],_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x1ac4')]=_0x20b0f1[0x3],_0x48ea04['outbounddial'][_0x204c5b('0x1634')]=_0x20b0f1[_0x204c5b('0x233')](0x4,_0x20b0f1[_0x204c5b('0x264b')])[_0x204c5b('0x45a')](',');}break;case _0x204c5b('0x1af7'):{const _0x48a2de=_0x48ea04['outbounddial'][_0x204c5b('0x823')][_0x204c5b('0x25c8')](',');_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x265e')]=isNaN(_0x48a2de[0x0])?_0x48a2de[0x0]:parseInt(_0x48a2de[0x0],0xa),_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x1640')]=_0x48a2de[_0x204c5b('0x233')](0x1,_0x48a2de[_0x204c5b('0x264b')])[_0x204c5b('0x45a')](',');}break;case _0x204c5b('0x1e70'):_0x48ea04[_0x204c5b('0x2884')]['text']=_0x48ea04['outbounddial'][_0x204c5b('0x823')];break;case'set':_0x48ea04['outbounddial'][_0x204c5b('0x4f0')]=_0x48ea04[_0x204c5b('0x2884')]['appdata'][_0x204c5b('0x25c8')]('=')[0x0],_0x48ea04['outbounddial']['value']=_0x48ea04[_0x204c5b('0x2884')]['appdata'][_0x204c5b('0x25c8')]('=')[0x1];break;case _0x204c5b('0x1034'):_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x2588')]=_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x823')];break;default:{const _0x377e75=_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x823')][_0x204c5b('0x25c8')](',');_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x3b2')]=_0x377e75[0x0]['split']('/')[0x1],_0x48ea04['outbounddial']['phone']=_0x377e75[0x0][_0x204c5b('0x25c8')]('/')[0x2],_0x48ea04['outbounddial'][_0x204c5b('0x651')]=_0x2cfb05()[_0x204c5b('0x1081')](_0x377e75[0x1])?_0x377e75[0x1]:isNaN(_0x377e75[0x1])?_0x377e75[0x1]:parseInt(_0x377e75[0x1],0xa),_0x48ea04['outbounddial'][_0x204c5b('0xd39')]=_0x2cfb05()[_0x204c5b('0x1081')](_0x377e75[0x2])?_0x377e75[0x2]:isNaN(_0x377e75[0x2])?_0x377e75[0x2]:parseInt(_0x377e75[0x2],0xa),_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0xcac')]=_0x2cfb05()[_0x204c5b('0x1081')](_0x377e75[0x3])?_0x377e75[0x3]:isNaN(_0x377e75[0x3])?_0x377e75[0x3]:parseInt(_0x377e75[0x3],0xa);}break;}else{}_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x1345')]&&_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x1345')][_0x204c5b('0x2574')]()===_0x204c5b('0x587')&&_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x83f')][_0x204c5b('0x2574')]()===_0x204c5b('0x2884')&&(_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x265a')]=_0x48ea04['outbounddial'][_0x204c5b('0x2026')]?_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x2026')][_0x204c5b('0x25c8')]('$')[0x0]:undefined,_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x1f02')]=_0x48ea04[_0x204c5b('0x2884')][_0x204c5b('0x992')]?_0x204c5b('0xa4c')+_0x48ea04[_0x204c5b('0x2884')]['callerID']:undefined);_0x48ea04[_0x204c5b('0x16ae')]=_0x121b53,_0x48ea04['closeDialog']=_0xb31f27,_0x1bb467[_0x204c5b('0x1ac6')](_0x204c5b('0xa7c'))?_0x16b3d5[_0x204c5b('0x3b2')][_0x204c5b('0xd83')]({'fields':_0x204c5b('0x1776'),'sort':_0x204c5b('0x4f0'),'nolimit':_0x204c5b('0xf3b')})[_0x204c5b('0xa44')][_0x204c5b('0x1166')](function(_0x387681){const _0x4ee484=_0x204c5b;_0x48ea04[_0x4ee484('0xf24')]=_0x387681['rows']||[];})['catch'](function(_0x421aff){const _0x208996=_0x204c5b;_0xbe108f[_0x208996('0xfc9')]({'title':_0x421aff['status']?'API:'+_0x421aff['status']+_0x208996('0x11e1')+_0x421aff[_0x208996('0xe1b')]:_0x208996('0x12a6'),'msg':_0x421aff[_0x208996('0x25f4')]?JSON[_0x208996('0xbac')](_0x421aff[_0x208996('0x25f4')]):_0x421aff[_0x208996('0x1586')]()});}):_0x16b3d5[_0x204c5b('0x3b2')][_0x204c5b('0xd83')]({'fields':_0x204c5b('0x1776'),'sort':_0x204c5b('0x4f0'),'nolimit':'true'})['$promise'][_0x204c5b('0x1166')](function(_0x2490be){_0x48ea04['trunks']=_0x2490be['rows']||[];})[_0x204c5b('0x1166')](function(){const _0xda0909=_0x204c5b;return _0x16b3d5['userProfileSection']['get']({'userProfileId':_0x48ea04[_0xda0909('0x98')][_0xda0909('0xb86')],'sectionId':0x3f3})['$promise'];})[_0x204c5b('0x1166')](function(_0x418238){const _0x505f55=_0x204c5b,_0x325e19=_0x418238&&_0x418238['rows']?_0x418238[_0x505f55('0x269a')][0x0]:null;if(!_0x325e19){const _0x3fc4dc=[];let _0x535412=null;_0x48ea04['outbounddial']&&(_0x535412=_0x2cfb05()['find'](_0x48ea04['trunks'],{'name':_0x48ea04['outbounddial']['trunk']}));for(let _0x207c3c=0x0;_0x207c3c<_0x48ea04['trunks'][_0x505f55('0x264b')];_0x207c3c++){_0x535412&&_0x48ea04[_0x505f55('0xf24')][_0x207c3c]['id']===_0x535412['id']&&(_0x48ea04[_0x505f55('0xf24')][_0x207c3c][_0x505f55('0x2378')]=![],_0x3fc4dc[_0x505f55('0x1514')](_0x48ea04[_0x505f55('0xf24')][_0x207c3c]));}_0x48ea04[_0x505f55('0xf24')]=_0x3fc4dc;}else{if(!_0x325e19[_0x505f55('0x1a2b')])return _0x16b3d5[_0x505f55('0x4b5')][_0x505f55('0xd83')]({'sectionId':_0x325e19['id']})[_0x505f55('0xa44')][_0x505f55('0x1166')](function(_0x1f7b2f){const _0x52a799=_0x505f55,_0x1fd9cd=_0x2cfb05()[_0x52a799('0x2563')](_0x1f7b2f[_0x52a799('0x269a')],function(_0xb743d5){const _0x29bf27=_0x52a799;return _0x2cfb05()[_0x29bf27('0xc38')](_0x48ea04[_0x29bf27('0xf24')],{'id':_0xb743d5['resourceId']});});let _0xe079db=null;_0x48ea04['outbounddial']&&(_0xe079db=_0x2cfb05()['find'](_0x48ea04[_0x52a799('0xf24')],{'name':_0x48ea04[_0x52a799('0x2884')][_0x52a799('0x3b2')]}));if(_0xe079db&&!_0x2cfb05()[_0x52a799('0x1798')](_0x1fd9cd,['id',_0xe079db['id']])){const _0x41fb50=_0x2cfb05()[_0x52a799('0xc38')](_0x48ea04[_0x52a799('0xf24')],{'id':_0xe079db['id']});_0x41fb50[_0x52a799('0x2378')]=![],_0x1fd9cd['push'](_0x41fb50);}_0x48ea04['trunks']=_0x1fd9cd;});}})['catch'](function(_0x3d9b0a){const _0x189740=_0x204c5b;_0xbe108f[_0x189740('0xfc9')]({'title':_0x3d9b0a[_0x189740('0x52d')]?_0x189740('0x1e21')+_0x3d9b0a[_0x189740('0x52d')]+_0x189740('0x11e1')+_0x3d9b0a['statusText']:_0x189740('0x1d44'),'msg':_0x3d9b0a[_0x189740('0x25f4')]?JSON[_0x189740('0xbac')](_0x3d9b0a[_0x189740('0x25f4')]):_0x3d9b0a[_0x189740('0x1586')]()});}),_0x1bb467[_0x204c5b('0x1ac6')](_0x204c5b('0xa7c'))?_0x16b3d5['tag']['get']({'fields':_0x204c5b('0x1776'),'sort':_0x204c5b('0x4f0'),'nolimit':'true'})['$promise']['then'](function(_0x3cc3f6){const _0x1892e2=_0x204c5b;_0x48ea04[_0x1892e2('0xb38')]=_0x3cc3f6[_0x1892e2('0x269a')]||[];})[_0x204c5b('0x1a80')](function(_0x5d9e7f){const _0x18ca07=_0x204c5b;_0xbe108f[_0x18ca07('0xfc9')]({'title':_0x5d9e7f[_0x18ca07('0x52d')]?'API:'+_0x5d9e7f[_0x18ca07('0x52d')]+_0x18ca07('0x11e1')+_0x5d9e7f[_0x18ca07('0xe1b')]:'SYSTEM:GET_TAGS','msg':_0x5d9e7f[_0x18ca07('0x25f4')]?JSON[_0x18ca07('0xbac')](_0x5d9e7f[_0x18ca07('0x25f4')]):_0x5d9e7f['toString']()});}):_0x16b3d5[_0x204c5b('0x1446')]['get']({'fields':_0x204c5b('0x1776'),'sort':'name','nolimit':_0x204c5b('0xf3b')})[_0x204c5b('0xa44')][_0x204c5b('0x1166')](function(_0xbc8cbc){_0x48ea04['tags']=_0xbc8cbc['rows']||[];})[_0x204c5b('0x1166')](function(){const _0x20bfed=_0x204c5b;return _0x16b3d5[_0x20bfed('0x17aa')][_0x20bfed('0xd83')]({'userProfileId':_0x48ea04[_0x20bfed('0x98')][_0x20bfed('0xb86')],'sectionId':0x3f0})[_0x20bfed('0xa44')];})[_0x204c5b('0x1166')](function(_0xb5f155){const _0x324b86=_0x204c5b,_0xb64c00=_0xb5f155&&_0xb5f155[_0x324b86('0x269a')]?_0xb5f155['rows'][0x0]:null;if(!_0xb64c00){const _0x499151=[];let _0x35b476=null;_0x48ea04[_0x324b86('0x2884')]&&(_0x35b476=_0x2cfb05()[_0x324b86('0xc38')](_0x48ea04['tags'],{'name':_0x48ea04[_0x324b86('0x2884')][_0x324b86('0x1446')]}));for(let _0x4c9472=0x0;_0x4c9472<_0x48ea04[_0x324b86('0xb38')][_0x324b86('0x264b')];_0x4c9472++){_0x35b476&&_0x48ea04['tags'][_0x4c9472]['id']===_0x35b476['id']&&(_0x48ea04[_0x324b86('0xb38')][_0x4c9472][_0x324b86('0x2378')]=![],_0x499151[_0x324b86('0x1514')](_0x48ea04['tags'][_0x4c9472]));}_0x48ea04[_0x324b86('0xb38')]=_0x499151;}else{if(!_0xb64c00[_0x324b86('0x1a2b')])return _0x16b3d5[_0x324b86('0x4b5')][_0x324b86('0xd83')]({'sectionId':_0xb64c00['id']})[_0x324b86('0xa44')]['then'](function(_0x306421){const _0x5d1e74=_0x324b86,_0x53ad1c=_0x2cfb05()[_0x5d1e74('0x2563')](_0x306421['rows'],function(_0x478a04){const _0x4c7a52=_0x5d1e74;return _0x2cfb05()[_0x4c7a52('0xc38')](_0x48ea04[_0x4c7a52('0xb38')],{'id':_0x478a04[_0x4c7a52('0x24e8')]});});let _0x2ce16f=null;_0x48ea04[_0x5d1e74('0x2884')]&&(_0x2ce16f=_0x2cfb05()[_0x5d1e74('0xc38')](_0x48ea04[_0x5d1e74('0xb38')],{'name':_0x48ea04[_0x5d1e74('0x2884')][_0x5d1e74('0x1446')]}));if(_0x2ce16f&&!_0x2cfb05()[_0x5d1e74('0x1798')](_0x53ad1c,['id',_0x2ce16f['id']])){const _0x1a5f14=_0x2cfb05()[_0x5d1e74('0xc38')](_0x48ea04[_0x5d1e74('0xb38')],{'id':_0x2ce16f['id']});_0x1a5f14[_0x5d1e74('0x2378')]=![],_0x53ad1c[_0x5d1e74('0x1514')](_0x1a5f14);}_0x48ea04['tags']=_0x53ad1c;});}})['catch'](function(_0x80f19){const _0x5a37ad=_0x204c5b;_0xbe108f[_0x5a37ad('0xfc9')]({'title':_0x80f19[_0x5a37ad('0x52d')]?_0x5a37ad('0x1e21')+_0x80f19[_0x5a37ad('0x52d')]+_0x5a37ad('0x11e1')+_0x80f19[_0x5a37ad('0xe1b')]:'SYSTEM:GETtags','msg':_0x80f19[_0x5a37ad('0x25f4')]?JSON[_0x5a37ad('0xbac')](_0x80f19[_0x5a37ad('0x25f4')]):_0x80f19[_0x5a37ad('0x1586')]()});});function _0x121b53(){const _0x207d33=_0x204c5b;_0x48ea04['errors']=[];const _0x5a37be=[];_0x48ea04['outbounddial']['type']&&_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x1345')][_0x207d33('0x2574')]()===_0x207d33('0x587')&&_0x48ea04[_0x207d33('0x2884')]['appType']===_0x207d33('0x867')&&(_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x2026')]=_0x5e5dce['cutdigits']?(_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x265a')]||'')+'${EXTEN:'+_0x5e5dce[_0x207d33('0x2848')]+'}':(_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x265a')]||'')+'${EXTEN}',_0x5e5dce['recordingFormat']!==_0x207d33('0x192')?_0x48ea04[_0x207d33('0x2884')][_0x207d33('0xd39')]['indexOf'](_0x207d33('0x1059'))<0x0&&(_0x48ea04[_0x207d33('0x2884')][_0x207d33('0xd39')]+=_0x207d33('0x1059')):_0x48ea04[_0x207d33('0x2884')][_0x207d33('0xd39')]=_0x48ea04[_0x207d33('0x2884')][_0x207d33('0xd39')][_0x207d33('0xf3')](_0x207d33('0x1059'),''));if(_0x48ea04['outbounddial'][_0x207d33('0x83f')]&&_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x83f')]==='custom'){}else switch((_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x746')]||_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x83f')])['toLowerCase']()){case _0x207d33('0xceb'):_0x48ea04['outbounddial'][_0x207d33('0x823')]=_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x4f0')]+'='+_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x18e0')];break;case _0x207d33('0x2853'):break;default:_0x5a37be[0x0]=[_0x207d33('0x1683'),_0x48ea04['outbounddial'][_0x207d33('0x3b2')],_0x48ea04['outbounddial']['phone']]['join']('/'),_0x5a37be[0x1]=_0x48ea04[_0x207d33('0x2884')]['timeout'],_0x5a37be[0x2]=_0x48ea04[_0x207d33('0x2884')][_0x207d33('0xd39')],_0x5a37be[0x3]=_0x48ea04[_0x207d33('0x2884')][_0x207d33('0xcac')],_0x48ea04[_0x207d33('0x2884')][_0x207d33('0x823')]=_0x5a37be['join'](',');}_0xb31f27(_0x48ea04[_0x207d33('0x2884')]);}function _0xb31f27(_0x110b4d){const _0x4c712e=_0x204c5b;_0x2fd72c[_0x4c712e('0x1197')](_0x110b4d);}}const _0xcb7b35=_0xff5f5a;_0x272f6e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x1aec'),'userProfileSection'];function _0x272f6e(_0xf01f4c,_0xd848e9,_0x596f37,_0xc5c0bc,_0x4452e4,_0x2329f9,_0xc64fe0,_0x3a4290,_0x3ba8d0,_0x32ac24,_0x1d75c7,_0x5280c3){const _0xca0803=_0x36e6f4,_0x5b7fa0=this;_0x5b7fa0['currentUser']=_0x32ac24[_0xca0803('0x26cd')](),_0x5b7fa0['license']=_0x2329f9,_0x5b7fa0[_0xca0803('0xf8a')]=_0xc64fe0,_0x5b7fa0['passwordPattern']=_0x5b7fa0['setting'][_0xca0803('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5b7fa0[_0xca0803('0x246b')]=_0xd848e9[_0xca0803('0x6f1')]()+_0xca0803('0xc51')+_0xd848e9[_0xca0803('0x1690')](),_0x5b7fa0[_0xca0803('0x1aec')]=_0x1d75c7||_0xf01f4c[_0xca0803('0x23f')]['outboundroute']||{},_0x5b7fa0['userProfileSection']=_0x5280c3&&_0x5280c3[_0xca0803('0x240f')]==0x1?_0x5280c3[_0xca0803('0x269a')][0x0]:null,_0x5b7fa0[_0xca0803('0x243c')]=_0x32ac24[_0xca0803('0xd87')](_0x5b7fa0[_0xca0803('0x17aa')]?_0x5b7fa0[_0xca0803('0x17aa')][_0xca0803('0x243c')]:null),_0x5b7fa0[_0xca0803('0x128b')]={},_0x5b7fa0[_0xca0803('0x2669')]=_0xf01f4c[_0xca0803('0x23f')][_0xca0803('0xbe3')]||0x0,_0x5b7fa0[_0xca0803('0x31d')]=_0x3ba8d0[_0xca0803('0x1fa1')],_0x5b7fa0[_0xca0803('0x1bac')]=_0x408fdb,_0x5b7fa0[_0xca0803('0x2675')]=_0x2e6d58,_0x32ac24['hasRole']('admin')?_0x3a4290[_0xca0803('0x23b1')][_0xca0803('0xd83')]({'fields':'id,name','sort':_0xca0803('0x4f0'),'nolimit':_0xca0803('0xf3b')})['$promise'][_0xca0803('0x1166')](function(_0x29761a){const _0x4ed652=_0xca0803;_0x5b7fa0[_0x4ed652('0x160a')]=_0x29761a[_0x4ed652('0x269a')]||[];})[_0xca0803('0x1a80')](function(_0x48bbc3){const _0x5d7ba0=_0xca0803;_0x3ba8d0[_0x5d7ba0('0xfc9')]({'title':_0x48bbc3[_0x5d7ba0('0x52d')]?_0x5d7ba0('0x1e21')+_0x48bbc3[_0x5d7ba0('0x52d')]+'\x20-\x20'+_0x48bbc3['statusText']:_0x5d7ba0('0x140d'),'msg':_0x48bbc3[_0x5d7ba0('0x25f4')]?JSON[_0x5d7ba0('0xbac')](_0x48bbc3['data']):_0x48bbc3['toString']()});}):_0x3a4290[_0xca0803('0x23b1')][_0xca0803('0xd83')]({'fields':_0xca0803('0x1776'),'sort':_0xca0803('0x4f0'),'nolimit':_0xca0803('0xf3b')})[_0xca0803('0xa44')][_0xca0803('0x1166')](function(_0x291f67){const _0x1138e4=_0xca0803;_0x5b7fa0[_0x1138e4('0x160a')]=_0x291f67[_0x1138e4('0x269a')]||[];})[_0xca0803('0x1166')](function(){const _0x15bfbb=_0xca0803;return _0x3a4290['userProfileSection'][_0x15bfbb('0xd83')]({'userProfileId':_0x5b7fa0[_0x15bfbb('0x98')]['userProfileId'],'sectionId':0x195})[_0x15bfbb('0xa44')];})[_0xca0803('0x1166')](function(_0x417dcd){const _0x2d3ea9=_0xca0803,_0x46d708=_0x417dcd&&_0x417dcd[_0x2d3ea9('0x269a')]?_0x417dcd[_0x2d3ea9('0x269a')][0x0]:null;if(!_0x46d708)return _0x3a4290[_0x2d3ea9('0x23b1')][_0x2d3ea9('0xd83')]({'fields':_0x2d3ea9('0x1776'),'sort':_0x2d3ea9('0x4f0'),'nolimit':_0x2d3ea9('0xf3b'),'defaultEntry':0x1})['$promise'][_0x2d3ea9('0x1166')](function(_0x18a136){const _0xf8949e=_0x2d3ea9;_0x5b7fa0[_0xf8949e('0x160a')]=_0x18a136[_0xf8949e('0x269a')]||[];});else{if(!_0x46d708['autoAssociation'])return _0x3a4290[_0x2d3ea9('0x4b5')][_0x2d3ea9('0xd83')]({'sectionId':_0x46d708['id']})['$promise']['then'](function(_0x20df2c){const _0x31b5ad=_0x2d3ea9,_0x5cea0c=_0x2cfb05()[_0x31b5ad('0x2563')](_0x20df2c['rows'],function(_0x13b4c9){const _0x89c48a=_0x31b5ad;return _0x2cfb05()[_0x89c48a('0xc38')](_0x5b7fa0[_0x89c48a('0x160a')],{'id':_0x13b4c9['resourceId']});});let _0x990580=null;_0x5b7fa0['outboundroute']&&(_0x990580=_0x2cfb05()[_0x31b5ad('0xc38')](_0x5b7fa0[_0x31b5ad('0x160a')],{'name':_0x5b7fa0['outboundroute'][_0x31b5ad('0xe1c')]}));if(_0x990580&&!_0x2cfb05()['some'](_0x5cea0c,['id',_0x990580['id']])){const _0x1733de=_0x2cfb05()[_0x31b5ad('0xc38')](_0x5b7fa0['contexts'],{'id':_0x990580['id']});_0x1733de[_0x31b5ad('0x2378')]=![],_0x5cea0c[_0x31b5ad('0x1514')](_0x1733de);}_0x5b7fa0[_0x31b5ad('0x160a')]=_0x5cea0c;});}})['catch'](function(_0x59a3d6){const _0xffb908=_0xca0803;_0x3ba8d0[_0xffb908('0xfc9')]({'title':_0x59a3d6[_0xffb908('0x52d')]?'API:'+_0x59a3d6[_0xffb908('0x52d')]+'\x20-\x20'+_0x59a3d6[_0xffb908('0xe1b')]:_0xffb908('0x482'),'msg':_0x59a3d6[_0xffb908('0x25f4')]?JSON[_0xffb908('0xbac')](_0x59a3d6['data']):_0x59a3d6[_0xffb908('0x1586')]()});});function _0x408fdb(){const _0x60eb19=_0xca0803;_0xf01f4c['go'](_0x60eb19('0x24d6'),{},{'reload':'app.voice.outboundroutes'});}function _0x2e6d58(){const _0x3c10cf=_0xca0803;_0x3a4290[_0x3c10cf('0x1deb')][_0x3c10cf('0x1449')]({'id':_0x5b7fa0['outboundroute']['id']},_0x5b7fa0[_0x3c10cf('0x1aec')])[_0x3c10cf('0xa44')][_0x3c10cf('0x1166')](function(){const _0x33e9bf=_0x3c10cf;_0x3ba8d0['success']({'title':_0x33e9bf('0x90f'),'msg':_0x5b7fa0['outboundroute'][_0x33e9bf('0x4f0')]?_0x5b7fa0['outboundroute'][_0x33e9bf('0x4f0')]+_0x33e9bf('0xa17'):''});})[_0x3c10cf('0x1a80')](function(_0x50a92a){const _0x297d17=_0x3c10cf;_0x3ba8d0[_0x297d17('0xfc9')]({'title':_0x50a92a['status']?_0x297d17('0x1e21')+_0x50a92a[_0x297d17('0x52d')]+'\x20-\x20'+_0x50a92a[_0x297d17('0xe1b')]:_0x297d17('0x1af9'),'msg':_0x50a92a[_0x297d17('0x25f4')]?JSON[_0x297d17('0xbac')](_0x50a92a[_0x297d17('0x25f4')]):_0x50a92a['toString']()});});}}const _0x5e9041=_0x272f6e,_0x552afc=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/outboundroutes/create/dialog.html/dialog.html';_0x35e415[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0xee4'),_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting'];function _0x35e415(_0x44f212,_0x5a4b17,_0x5ee529,_0x5b4076,_0x244548,_0x486673,_0xf8aa11,_0x213fcb,_0x4ee7cb,_0x6ef424,_0x69a9d8,_0x19b625,_0x22ed31,_0x4e3544,_0x4d7673,_0x260273,_0x1edb24){const _0x3fa06f=_0x36e6f4,_0x18d56d=this;_0x18d56d[_0x3fa06f('0x5c9')]=_0x260273,_0x18d56d['setting']=_0x1edb24,_0x18d56d[_0x3fa06f('0x98')]=_0x4d7673['getCurrentUser'](),_0x18d56d[_0x3fa06f('0xee4')]=_0x4ee7cb||{'count':0x0,'rows':[]},_0x18d56d[_0x3fa06f('0x7f')]=_0x6ef424,_0x18d56d[_0x3fa06f('0x17aa')]=_0x69a9d8&&_0x69a9d8[_0x3fa06f('0x240f')]==0x1?_0x69a9d8[_0x3fa06f('0x269a')][0x0]:null,_0x18d56d[_0x3fa06f('0x243c')]=_0x4d7673['parseCrudPermissions'](_0x18d56d[_0x3fa06f('0x17aa')]?_0x18d56d[_0x3fa06f('0x17aa')]['crudPermissions']:null),_0x18d56d[_0x3fa06f('0x916')]=_0x3fa06f('0xee4'),_0x18d56d['listOrder']='',_0x18d56d[_0x3fa06f('0x104c')]=null,_0x18d56d['selectedOutboundRoutes']=[],_0x18d56d['query']={'fields':_0x3fa06f('0x22fd'),'type':'outbound','sort':_0x3fa06f('0x14dc'),'VoiceExtensionId':_0x3fa06f('0x15d7'),'limit':0xa,'page':0x1},_0x18d56d[_0x3fa06f('0x1bfb')]=_0x2cfb05()[_0x3fa06f('0x155c')]([{'option':'none','value':'\x27none\x27'},{'option':_0x3fa06f('0xdef'),'value':_0x3fa06f('0x91c')},{'option':_0x3fa06f('0xd43'),'value':_0x3fa06f('0x21b7')},{'option':'gsm','value':_0x3fa06f('0xd74')}],function(_0x202755){const _0x366245=_0x3fa06f;return _0x2cfb05()[_0x366245('0xf3')](_0x202755[_0x366245('0x18e0')],new RegExp('\x27','g'),'');}),_0x18d56d[_0x3fa06f('0x1ff6')]=_0x134255,_0x18d56d[_0x3fa06f('0x8d8')]=_0x207a13,_0x18d56d[_0x3fa06f('0x103b')]=_0x358aa7,_0x18d56d[_0x3fa06f('0x78d')]=_0x2c7b25,_0x18d56d[_0x3fa06f('0x2629')]=_0x1303f4,_0x18d56d[_0x3fa06f('0x1d47')]=_0x19cf85,_0x18d56d[_0x3fa06f('0x270e')]=_0x35336a,_0x18d56d[_0x3fa06f('0x1b36')]=_0x52b275,_0x18d56d[_0x3fa06f('0xe65')]=_0x28258c,_0x18d56d['selectAllOutboundRoutes']=_0x2db541,_0x4d7673[_0x3fa06f('0x1ac6')](_0x3fa06f('0xa7c'))?_0x19b625['voiceContext'][_0x3fa06f('0xd83')]({'fields':'id,name','sort':'name','nolimit':'true'})['$promise']['then'](function(_0x3d6352){_0x18d56d['contexts']=_0x3d6352['rows']||[];})[_0x3fa06f('0x1a80')](function(_0x6df0dd){const _0x1c0b1f=_0x3fa06f;_0x4e3544[_0x1c0b1f('0xfc9')]({'title':_0x6df0dd['status']?_0x1c0b1f('0x1e21')+_0x6df0dd[_0x1c0b1f('0x52d')]+'\x20-\x20'+_0x6df0dd['statusText']:'SYSTEM:GET_CONTEXTS','msg':_0x6df0dd['data']?JSON['stringify'](_0x6df0dd[_0x1c0b1f('0x25f4')]):_0x6df0dd[_0x1c0b1f('0x1586')]()});}):_0x19b625[_0x3fa06f('0x23b1')][_0x3fa06f('0xd83')]({'fields':'id,name','sort':_0x3fa06f('0x4f0'),'nolimit':_0x3fa06f('0xf3b')})[_0x3fa06f('0xa44')][_0x3fa06f('0x1166')](function(_0x1c5074){const _0x331ee0=_0x3fa06f;_0x18d56d[_0x331ee0('0x160a')]=_0x1c5074[_0x331ee0('0x269a')]||[];})[_0x3fa06f('0x1166')](function(){const _0x4ad6bf=_0x3fa06f;return _0x19b625[_0x4ad6bf('0x17aa')][_0x4ad6bf('0xd83')]({'userProfileId':_0x18d56d[_0x4ad6bf('0x98')][_0x4ad6bf('0xb86')],'sectionId':0x195})[_0x4ad6bf('0xa44')];})[_0x3fa06f('0x1166')](function(_0x1eda5d){const _0x5da215=_0x3fa06f,_0x381201=_0x1eda5d&&_0x1eda5d['rows']?_0x1eda5d['rows'][0x0]:null;if(!_0x381201)return _0x19b625[_0x5da215('0x23b1')]['get']({'fields':'id,name','sort':_0x5da215('0x4f0'),'nolimit':_0x5da215('0xf3b'),'defaultEntry':0x1})[_0x5da215('0xa44')][_0x5da215('0x1166')](function(_0x576e87){const _0x4e4ebe=_0x5da215;_0x18d56d[_0x4e4ebe('0x160a')]=_0x576e87[_0x4e4ebe('0x269a')]||[];});else{if(!_0x381201[_0x5da215('0x1a2b')])return _0x19b625[_0x5da215('0x4b5')]['get']({'sectionId':_0x381201['id']})['$promise'][_0x5da215('0x1166')](function(_0x109ccc){const _0x214bef=_0x5da215,_0xc3950c=_0x2cfb05()[_0x214bef('0x2563')](_0x109ccc[_0x214bef('0x269a')],function(_0x45ce67){const _0x335754=_0x214bef;return _0x2cfb05()[_0x335754('0xc38')](_0x18d56d['contexts'],{'id':_0x45ce67[_0x335754('0x24e8')]});});let _0x578b3e=null;_0x18d56d[_0x214bef('0x1aec')]&&(_0x578b3e=_0x2cfb05()[_0x214bef('0xc38')](_0x18d56d[_0x214bef('0x160a')],{'name':_0x18d56d[_0x214bef('0x1aec')][_0x214bef('0xe1c')]}));if(_0x578b3e&&!_0x2cfb05()['some'](_0xc3950c,['id',_0x578b3e['id']])){const _0x48d801=_0x2cfb05()['find'](_0x18d56d[_0x214bef('0x160a')],{'id':_0x578b3e['id']});_0x48d801[_0x214bef('0x2378')]=![],_0xc3950c['push'](_0x48d801);}_0x18d56d['contexts']=_0xc3950c;});}})[_0x3fa06f('0x1a80')](function(_0x1ef229){const _0x1cbf63=_0x3fa06f;_0x4e3544[_0x1cbf63('0xfc9')]({'title':_0x1ef229[_0x1cbf63('0x52d')]?_0x1cbf63('0x1e21')+_0x1ef229[_0x1cbf63('0x52d')]+_0x1cbf63('0x11e1')+_0x1ef229[_0x1cbf63('0xe1b')]:'SYSTEM:GETcontexts','msg':_0x1ef229[_0x1cbf63('0x25f4')]?JSON[_0x1cbf63('0xbac')](_0x1ef229[_0x1cbf63('0x25f4')]):_0x1ef229[_0x1cbf63('0x1586')]()});});function _0x134255(_0x522832){const _0x35b7fd=_0x3fa06f;_0x5ee529['go'](_0x35b7fd('0xad'),{'id':_0x522832['id'],'outboundroute':_0x522832,'crudPermissions':_0x18d56d[_0x35b7fd('0x243c')]});}function _0x207a13(_0x13eb20,_0x5222a5){const _0x2b24a9=_0x3fa06f,_0x307388=_0x244548[_0x2b24a9('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()['startCase'](_0x2b24a9('0x1aec'))+'?')[_0x2b24a9('0xf3c')](_0x2b24a9('0x12b5')+(_0x13eb20[_0x2b24a9('0x4f0')]||_0x2b24a9('0x1aec'))+_0x2b24a9('0xace')+_0x2b24a9('0x3f3'))['ariaLabel'](_0x2b24a9('0xec1'))[_0x2b24a9('0x203b')](_0x5222a5)['ok']('OK')[_0x2b24a9('0x3f')](_0x2b24a9('0x2d3'));_0x244548[_0x2b24a9('0x1f80')](_0x307388)['then'](function(){_0x19cf85(_0x13eb20);},function(){const _0x333e05=_0x2b24a9;console[_0x333e05('0x455')](_0x333e05('0x2d3'));});}let _0x57fc65=!![],_0x290b06=0x1;_0x44f212[_0x3fa06f('0xe83')]('vm.query.filter',function(_0xf814ad,_0x5756e6){const _0x33d6e4=_0x3fa06f;_0x57fc65?_0xf8aa11(function(){_0x57fc65=![];}):(!_0x5756e6&&(_0x290b06=_0x18d56d[_0x33d6e4('0x2218')][_0x33d6e4('0x1a43')]),_0xf814ad!==_0x5756e6&&(_0x18d56d['query'][_0x33d6e4('0x1a43')]=0x1),!_0xf814ad&&(_0x18d56d['query'][_0x33d6e4('0x1a43')]=_0x290b06),_0x18d56d[_0x33d6e4('0x78d')]());});function _0x358aa7(_0xc552ea){_0x18d56d['outboundroutes']=_0xc552ea||{'count':0x0,'rows':[]};}function _0x2c7b25(){const _0x46a366=_0x3fa06f;_0x18d56d['query']['offset']=(_0x18d56d['query']['page']-0x1)*_0x18d56d[_0x46a366('0x2218')]['limit'],_0x4d7673['hasRole'](_0x46a366('0xa7c'))?_0x18d56d[_0x46a366('0x1f48')]=_0x19b625[_0x46a366('0x1deb')]['get'](_0x18d56d[_0x46a366('0x2218')],_0x358aa7)[_0x46a366('0xa44')]:(_0x18d56d[_0x46a366('0x2218')]['id']=_0x18d56d[_0x46a366('0x7f')]['id'],_0x18d56d['query'][_0x46a366('0xe60')]='OutboundRoutes',_0x18d56d['promise']=_0x19b625[_0x46a366('0x7f')][_0x46a366('0x263a')](_0x18d56d['query'],_0x358aa7)[_0x46a366('0xa44')]);}function _0x1303f4(_0x51d78f,_0x389201){const _0x50cc67=_0x3fa06f;_0x244548[_0x50cc67('0x1f80')]({'controller':'CreateOrEditOutboundRouteDialogController','controllerAs':'vm','templateUrl':_0x552afc,'parent':angular['element'](_0x486673[_0x50cc67('0x8d2')]),'targetEvent':_0x51d78f,'clickOutsideToClose':!![],'locals':{'outboundroute':_0x389201,'outboundroutes':_0x18d56d[_0x50cc67('0xee4')][_0x50cc67('0x269a')],'license':_0x18d56d[_0x50cc67('0x5c9')],'setting':_0x18d56d['setting'],'crudPermissions':_0x18d56d['crudPermissions']}});}function _0x19cf85(_0x51bc56){const _0x5c1aed=_0x3fa06f;_0x19b625[_0x5c1aed('0x1d96')]['get']({'VoiceExtensionId':_0x51bc56['id']})[_0x5c1aed('0xa44')][_0x5c1aed('0x1166')](function(_0x4f76f4){const _0x112f72=_0x5c1aed;if(_0x4f76f4&&_0x4f76f4[_0x112f72('0x269a')]&&_0x4f76f4[_0x112f72('0x269a')][_0x112f72('0x264b')]>0x0)return _0x4e3544['error']({'title':_0x112f72('0x2856'),'msg':_0x112f72('0x175d')});else _0x19b625[_0x112f72('0x1deb')]['delete']({'id':_0x51bc56['id']})[_0x112f72('0xa44')][_0x112f72('0x1166')](function(){const _0x512ca2=_0x112f72;_0x2cfb05()[_0x512ca2('0x127f')](_0x18d56d[_0x512ca2('0xee4')][_0x512ca2('0x269a')],{'id':_0x51bc56['id']}),_0x18d56d[_0x512ca2('0xee4')][_0x512ca2('0x240f')]-=0x1,!_0x18d56d['outboundroutes'][_0x512ca2('0x269a')][_0x512ca2('0x264b')]&&_0x18d56d['getOutboundRoutes'](),_0x4e3544[_0x512ca2('0x103b')]({'title':_0x2cfb05()[_0x512ca2('0xb35')](_0x512ca2('0x1aaf'))+_0x512ca2('0x2b6'),'msg':_0x51bc56['name']?_0x51bc56[_0x512ca2('0x4f0')]+_0x512ca2('0x7cd'):''});})[_0x112f72('0x1a80')](function(_0x504040){const _0x2ada1d=_0x112f72;if(_0x504040[_0x2ada1d('0x25f4')]&&_0x504040[_0x2ada1d('0x25f4')][_0x2ada1d('0x61a')]&&_0x504040[_0x2ada1d('0x25f4')]['errors'][_0x2ada1d('0x264b')]){_0x18d56d['errors']=_0x504040['data']['errors']||[{'message':_0x504040['toString'](),'type':'SYSTEM:DELETEvoiceExtension'}];for(let _0x4c765c=0x0;_0x4c765c<_0x504040[_0x2ada1d('0x25f4')]['errors'][_0x2ada1d('0x264b')];_0x4c765c++){_0x4e3544[_0x2ada1d('0xfc9')]({'title':_0x504040['data']['errors'][_0x4c765c][_0x2ada1d('0x1345')],'msg':_0x504040[_0x2ada1d('0x25f4')][_0x2ada1d('0x61a')][_0x4c765c][_0x2ada1d('0x1e70')]});}}else _0x4e3544['error']({'title':_0x504040[_0x2ada1d('0x52d')]?_0x2ada1d('0x1e21')+_0x504040[_0x2ada1d('0x52d')]+_0x2ada1d('0x11e1')+_0x504040[_0x2ada1d('0xe1b')]:_0x2ada1d('0xa97'),'msg':_0x504040[_0x2ada1d('0x25f4')]?JSON[_0x2ada1d('0xbac')](_0x504040['data']['message']):_0x504040[_0x2ada1d('0x1e70')]||_0x504040[_0x2ada1d('0x1586')]()});});});}function _0x35336a(){const _0x3c97fa=_0x3fa06f,_0x1158ac=angular[_0x3c97fa('0x225f')](_0x18d56d[_0x3c97fa('0x1e3d')]);return _0x18d56d['selectedOutboundRoutes']=[],_0x1158ac;}function _0x52b275(_0x418db3){const _0xa22ee4=_0x3fa06f,_0x1228f5=_0x244548[_0xa22ee4('0x1d26')]()[_0xa22ee4('0xcdc')](_0xa22ee4('0x2897'))[_0xa22ee4('0xf3c')](_0xa22ee4('0x12b5')+_0x18d56d[_0xa22ee4('0x1e3d')]['length']+'\x20selected
'+_0xa22ee4('0x3f3'))[_0xa22ee4('0x8e8')](_0xa22ee4('0x1561'))[_0xa22ee4('0x203b')](_0x418db3)['ok']('OK')[_0xa22ee4('0x3f')]('CANCEL');_0x244548[_0xa22ee4('0x1f80')](_0x1228f5)[_0xa22ee4('0x1166')](function(){const _0x4a0ef3=_0xa22ee4;_0x18d56d['selectedOutboundRoutes']['forEach'](function(_0x267866){_0x19cf85(_0x267866);}),_0x18d56d[_0x4a0ef3('0x1e3d')]=[];});}function _0x28258c(){_0x18d56d['selectedOutboundRoutes']=[];}function _0x2db541(){const _0x5fd35f=_0x3fa06f;_0x18d56d[_0x5fd35f('0x1e3d')]=_0x18d56d['outboundroutes']['rows'];}}const _0x18a420=_0x35e415;_0x507fb0['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1149'),_0x36e6f4('0x1ee9'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x507fb0(_0x18edde,_0x117204,_0x3310ed,_0x496529,_0x262fd3,_0x4d57c9,_0x244b2d,_0x3f791d,_0x176a8d,_0x95f7c9,_0x528d27,_0x4d353d,_0x1f3f2c,_0x3fa032){const _0x31c900=_0x36e6f4,_0x3e59b3=this;_0x3e59b3[_0x31c900('0x98')]=_0x528d27[_0x31c900('0x26cd')](),_0x3e59b3[_0x31c900('0x61a')]=[],_0x3e59b3[_0x31c900('0xf8a')]=_0x1f3f2c,_0x3e59b3[_0x31c900('0x5c9')]=_0x4d353d,_0x3e59b3[_0x31c900('0x243c')]=_0x3fa032,_0x3e59b3[_0x31c900('0x128b')]={},_0x3e59b3[_0x31c900('0x2900')]=_0x3e59b3['setting']&&_0x3e59b3[_0x31c900('0xf8a')][_0x31c900('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3e59b3['title']=_0x31c900('0x13dc'),_0x3e59b3[_0x31c900('0x1ee9')]=angular[_0x31c900('0x225f')](_0x176a8d),_0x3e59b3['voicemails']=_0x3f791d,_0x3e59b3['newVoicemail']=![];!_0x3e59b3[_0x31c900('0x1ee9')]&&(_0x3e59b3['voicemail']={'attach':'no'},_0x3e59b3[_0x31c900('0xcdc')]=_0x31c900('0x1fe5'),_0x3e59b3[_0x31c900('0xf35')]=!![]);_0x3e59b3['addNewVoicemail']=_0x1820aa,_0x3e59b3['saveVoicemail']=_0x2c6759,_0x3e59b3[_0x31c900('0x129d')]=_0x2854e5,_0x3e59b3[_0x31c900('0x1a9c')]=_0x4891af,_0x3e59b3[_0x31c900('0x24a0')]=_0x441afe;function _0x1820aa(){const _0x17fe3d=_0x31c900;_0x3e59b3[_0x17fe3d('0x61a')]=[],_0x95f7c9[_0x17fe3d('0x8d4')][_0x17fe3d('0x9cc')](_0x3e59b3[_0x17fe3d('0x1ee9')])[_0x17fe3d('0xa44')][_0x17fe3d('0x1166')](function(_0xc3138d){const _0x3edaab=_0x17fe3d;_0x3e59b3['voicemails'][_0x3edaab('0x2450')](_0xc3138d[_0x3edaab('0x2876')]()),_0x244b2d[_0x3edaab('0x103b')]({'title':_0x3edaab('0x156c'),'msg':_0x3e59b3[_0x3edaab('0x1ee9')][_0x3edaab('0x4f0')]?_0x3e59b3[_0x3edaab('0x1ee9')]['name']+'\x20has\x20been\x20created!':''}),_0x441afe(_0xc3138d);})['catch'](function(_0x11e117){const _0x4d82a2=_0x17fe3d;if(_0x11e117[_0x4d82a2('0x25f4')]&&_0x11e117['data'][_0x4d82a2('0x61a')]&&_0x11e117['data']['errors']['length']){_0x3e59b3[_0x4d82a2('0x61a')]=_0x11e117[_0x4d82a2('0x25f4')][_0x4d82a2('0x61a')]||[{'message':_0x11e117[_0x4d82a2('0x1586')](),'type':'api.voiceMail.save'}];for(let _0x2b0fb7=0x0;_0x2b0fb7<_0x11e117['data'][_0x4d82a2('0x61a')]['length'];_0x2b0fb7+=0x1){_0x244b2d[_0x4d82a2('0xfc9')]({'title':_0x11e117[_0x4d82a2('0x25f4')][_0x4d82a2('0x61a')][_0x2b0fb7][_0x4d82a2('0x1345')],'msg':_0x11e117[_0x4d82a2('0x25f4')][_0x4d82a2('0x61a')][_0x2b0fb7][_0x4d82a2('0x1e70')]});}}else _0x244b2d[_0x4d82a2('0xfc9')]({'title':_0x11e117[_0x4d82a2('0x52d')]?'API:'+_0x11e117[_0x4d82a2('0x52d')]+_0x4d82a2('0x11e1')+_0x11e117[_0x4d82a2('0xe1b')]:_0x4d82a2('0x2785'),'msg':_0x11e117['data']?JSON[_0x4d82a2('0xbac')](_0x11e117[_0x4d82a2('0x25f4')]['message']):_0x11e117['toString']()});});}function _0x2c6759(){const _0x5e1046=_0x31c900;_0x3e59b3[_0x5e1046('0x61a')]=[],_0x95f7c9[_0x5e1046('0x8d4')]['update']({'id':_0x3e59b3[_0x5e1046('0x1ee9')]['id']},_0x3e59b3[_0x5e1046('0x1ee9')])[_0x5e1046('0xa44')][_0x5e1046('0x1166')](function(_0x1a8595){const _0x218e74=_0x5e1046,_0x5a8f6b=_0x2cfb05()[_0x218e74('0xc38')](_0x3e59b3[_0x218e74('0x1149')],{'id':_0x1a8595['id']});_0x5a8f6b&&_0x2cfb05()[_0x218e74('0xcc3')](_0x5a8f6b,_0x2cfb05()['pick'](_0x1a8595[_0x218e74('0x2876')](),_0x2cfb05()['keys'](_0x5a8f6b))),_0x244b2d[_0x218e74('0x103b')]({'title':_0x218e74('0x21bb'),'msg':_0x3e59b3[_0x218e74('0x1ee9')][_0x218e74('0x4f0')]?_0x3e59b3[_0x218e74('0x1ee9')]['name']+_0x218e74('0x7d'):''}),_0x441afe(_0x1a8595);})[_0x5e1046('0x1a80')](function(_0x9179f4){const _0x89ed23=_0x5e1046;if(_0x9179f4[_0x89ed23('0x25f4')]&&_0x9179f4[_0x89ed23('0x25f4')]['errors']&&_0x9179f4['data']['errors']['length']){_0x3e59b3[_0x89ed23('0x61a')]=_0x9179f4[_0x89ed23('0x25f4')][_0x89ed23('0x61a')]||[{'message':_0x9179f4['toString'](),'type':'api.voiceMail.update'}];for(let _0x2ea2f0=0x0;_0x2ea2f0<_0x9179f4[_0x89ed23('0x25f4')][_0x89ed23('0x61a')][_0x89ed23('0x264b')];_0x2ea2f0++){_0x244b2d['error']({'title':_0x9179f4[_0x89ed23('0x25f4')][_0x89ed23('0x61a')][_0x2ea2f0][_0x89ed23('0x1345')],'msg':_0x9179f4['data'][_0x89ed23('0x61a')][_0x2ea2f0][_0x89ed23('0x1e70')]});}}else _0x244b2d['error']({'title':_0x9179f4[_0x89ed23('0x52d')]?'API:'+_0x9179f4[_0x89ed23('0x52d')]+_0x89ed23('0x11e1')+_0x9179f4[_0x89ed23('0xe1b')]:_0x89ed23('0x32a'),'msg':_0x9179f4[_0x89ed23('0x25f4')]?JSON[_0x89ed23('0xbac')](_0x9179f4[_0x89ed23('0x25f4')][_0x89ed23('0x1e70')]):_0x9179f4['toString']()});});}function _0x2854e5(_0x10401b){const _0x49ba40=_0x31c900;_0x3e59b3[_0x49ba40('0x61a')]=[];const _0x2e3981=_0x496529[_0x49ba40('0x1d26')]()[_0x49ba40('0xcdc')](_0x49ba40('0x7fb'))[_0x49ba40('0xacc')](_0x49ba40('0x2187'))[_0x49ba40('0x8e8')](_0x49ba40('0x1713'))['ok'](_0x49ba40('0x18'))[_0x49ba40('0x3f')](_0x49ba40('0x497'))['targetEvent'](_0x10401b);_0x496529[_0x49ba40('0x1f80')](_0x2e3981)['then'](function(){const _0x3266dc=_0x49ba40;_0x95f7c9[_0x3266dc('0x8d4')][_0x3266dc('0x906')]({'id':_0x3e59b3[_0x3266dc('0x1ee9')]['id']})[_0x3266dc('0xa44')][_0x3266dc('0x1166')](function(){const _0x385644=_0x3266dc;_0x2cfb05()[_0x385644('0x127f')](_0x3e59b3['voicemails'],{'id':_0x3e59b3[_0x385644('0x1ee9')]['id']}),_0x244b2d[_0x385644('0x103b')]({'title':'Voicemail\x20properly\x20deleted!','msg':(_0x3e59b3[_0x385644('0x1ee9')][_0x385644('0x4f0')]||_0x385644('0x1ee9'))+_0x385644('0x7cd')}),_0x441afe(_0x3e59b3[_0x385644('0x1ee9')]);})[_0x3266dc('0x1a80')](function(_0x4c67f8){const _0x4476a0=_0x3266dc;if(_0x4c67f8[_0x4476a0('0x25f4')]&&_0x4c67f8['data']['errors']&&_0x4c67f8[_0x4476a0('0x25f4')]['errors'][_0x4476a0('0x264b')]){_0x3e59b3[_0x4476a0('0x61a')]=_0x4c67f8[_0x4476a0('0x25f4')][_0x4476a0('0x61a')]||[{'message':_0x4c67f8[_0x4476a0('0x1586')](),'type':'api.voiceMail.delete'}];for(let _0x58802b=0x0;_0x58802b<_0x4c67f8[_0x4476a0('0x25f4')][_0x4476a0('0x61a')][_0x4476a0('0x264b')];_0x58802b++){_0x244b2d[_0x4476a0('0xfc9')]({'title':_0x4c67f8[_0x4476a0('0x25f4')][_0x4476a0('0x61a')][_0x58802b][_0x4476a0('0x1345')],'msg':_0x4c67f8['data'][_0x4476a0('0x61a')][_0x58802b][_0x4476a0('0x1e70')]});}}else _0x244b2d[_0x4476a0('0xfc9')]({'title':_0x4c67f8[_0x4476a0('0x52d')]?'API:'+_0x4c67f8['status']+_0x4476a0('0x11e1')+_0x4c67f8[_0x4476a0('0xe1b')]:_0x4476a0('0x2395'),'msg':_0x4c67f8[_0x4476a0('0x25f4')]?JSON['stringify'](_0x4c67f8[_0x4476a0('0x25f4')][_0x4476a0('0x1e70')]):_0x4c67f8[_0x4476a0('0x1e70')]||_0x4c67f8['toString']()});});},function(){});}function _0x4891af(_0x3c2c9b){return _0x3c2c9b===null?undefined:new Date(_0x3c2c9b);}function _0x441afe(_0x41e242){_0x496529['hide'](_0x41e242);}}const _0x44f1e7=_0x507fb0;_0x2e7542['$inject']=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'Auth'];function _0x2e7542(_0x2110ef,_0x33d0f8,_0x139765,_0x5a5f6d,_0x3ea3c5,_0x23e8ac,_0x7c6727,_0x4c79bb,_0x55bcb1,_0x2f3e8c,_0x429654){const _0x656c2=_0x36e6f4,_0x32fdb3=this;_0x32fdb3['currentUser']=_0x429654[_0x656c2('0x26cd')](),_0x32fdb3[_0x656c2('0x1ee9')]={},_0x32fdb3['voicemailMessages']={'count':0x0,'rows':[]},_0x32fdb3[_0x656c2('0x252f')]=[],_0x32fdb3[_0x656c2('0x243c')],_0x32fdb3['query']={'fields':_0x656c2('0x4f'),'sort':_0x656c2('0x27a8'),'limit':0xa,'page':0x1},_0x32fdb3[_0x656c2('0x24d5')]=_0x1720c7,_0x32fdb3[_0x656c2('0x8a2')]=_0x333929,_0x32fdb3[_0x656c2('0x80b')]=_0x36b642,_0x32fdb3['success']=_0x24db4f,_0x32fdb3[_0x656c2('0x19b8')]=_0x45875f,_0x32fdb3['exportSelectedVoicemailMessages']=_0x10d161,_0x32fdb3['deleteVoicemailMessage']=_0x5c9a2d,_0x32fdb3[_0x656c2('0x732')]=_0x27a5b3;function _0x1720c7(_0x1ccfb2,_0xb83a21){const _0x4be012=_0x656c2;_0x32fdb3[_0x4be012('0x1ee9')]=_0x1ccfb2,_0x32fdb3['crudPermissions']=typeof _0xb83a21!==_0x4be012('0x1048')?_0xb83a21:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x32fdb3[_0x4be012('0x2218')]['id']=_0x32fdb3[_0x4be012('0x1ee9')]['id'],_0x45875f();}function _0x36b642(_0x52b9f7,_0x305ff9,_0x406324){const _0x4baa7e=_0x656c2;return _0x2f3e8c['voiceMailMessage'][_0x4baa7e('0x2ad')]({'id':_0x52b9f7['id'],'exists':!![],'attachments':_0x406324})[_0x4baa7e('0xa44')][_0x4baa7e('0x1166')](function(_0x33ae42){const _0x2a8233=_0x4baa7e,_0x1cd5ea=[_0x33ae42[_0x2a8233('0x20ed')]];let _0x1ea515='message'+_0x52b9f7['id'];const _0x14ce96=new Blob(_0x1cd5ea,{'type':_0x33ae42[_0x2a8233('0x1345')]});_0x1ea515=_0x52b9f7[_0x2a8233('0x132f')]+_0x2a8233('0xf37');const _0x23fa04=window[_0x2a8233('0x136d')][_0x2a8233('0xdd')]('a');_0x23fa04[_0x2a8233('0xffd')](_0x2a8233('0x14f9'),URL['createObjectURL'](_0x14ce96)),_0x23fa04[_0x2a8233('0xffd')]('download',_0x1ea515),document[_0x2a8233('0x8d2')]['appendChild'](_0x23fa04),_0x23fa04[_0x2a8233('0x3b4')]();})['catch'](function(_0x5809d9){const _0x1cd421=_0x4baa7e;if(_0x5809d9[_0x1cd421('0x25f4')]&&_0x5809d9[_0x1cd421('0x25f4')][_0x1cd421('0x61a')]&&_0x5809d9[_0x1cd421('0x25f4')][_0x1cd421('0x61a')][_0x1cd421('0x264b')])for(let _0x28515f=0x0;_0x28515f<_0x5809d9[_0x1cd421('0x25f4')][_0x1cd421('0x61a')][_0x1cd421('0x264b')];_0x28515f+=0x1){_0x55bcb1[_0x1cd421('0xfc9')]({'title':_0x5809d9[_0x1cd421('0x25f4')][_0x1cd421('0x61a')][_0x28515f][_0x1cd421('0x1345')],'msg':_0x5809d9[_0x1cd421('0x25f4')][_0x1cd421('0x61a')][_0x28515f]['message']});}else _0x55bcb1['error']({'title':_0x5809d9['status']?_0x1cd421('0x1e21')+_0x5809d9[_0x1cd421('0x52d')]+_0x1cd421('0x11e1')+_0x5809d9[_0x1cd421('0xe1b')]:_0x1cd421('0x2785'),'msg':_0x5809d9['data']?JSON['stringify'](_0x5809d9[_0x1cd421('0x25f4')][_0x1cd421('0x1e70')]):_0x5809d9[_0x1cd421('0x1586')]()});});}function _0x333929(_0x4518b0,_0x40d5a6){const _0x37f700=_0x656c2,_0x141a2a=_0x7c6727[_0x37f700('0x1d26')]()[_0x37f700('0xcdc')](_0x37f700('0x618'))[_0x37f700('0xf3c')](_0x37f700('0x12b5')+(_0x4518b0[_0x37f700('0x4f0')]||_0x4518b0['id']&&_0x2cfb05()[_0x37f700('0x114b')](_0x37f700('0x4f2'))+_0x4518b0['id']||'message')+_0x37f700('0xace')+'\x20will\x20be\x20deleted.')[_0x37f700('0x8e8')](_0x37f700('0x2619'))[_0x37f700('0x203b')](_0x40d5a6)['ok']('OK')[_0x37f700('0x3f')](_0x37f700('0x2d3'));_0x7c6727[_0x37f700('0x1f80')](_0x141a2a)[_0x37f700('0x1166')](function(){_0x5c9a2d(_0x4518b0);},function(){const _0x31b099=_0x37f700;console['log'](_0x31b099('0x2d3'));});}function _0x24db4f(_0x30ede2){const _0x1b4351=_0x656c2;_0x32fdb3[_0x1b4351('0xbd8')]=_0x30ede2||{'count':0x0,'rows':[]};}function _0x45875f(){const _0x1380d5=_0x656c2;_0x32fdb3[_0x1380d5('0x2218')][_0x1380d5('0x1098')]=(_0x32fdb3[_0x1380d5('0x2218')][_0x1380d5('0x1a43')]-0x1)*_0x32fdb3['query'][_0x1380d5('0x163f')],_0x32fdb3[_0x1380d5('0x1f48')]=_0x2f3e8c[_0x1380d5('0x8d4')][_0x1380d5('0x16f2')](_0x32fdb3[_0x1380d5('0x2218')],_0x24db4f)[_0x1380d5('0xa44')];}function _0x5c9a2d(_0x562337){const _0x5cc791=_0x656c2;_0x2f3e8c[_0x5cc791('0xd1b')]['delete']({'id':_0x562337['id']})['$promise'][_0x5cc791('0x1166')](function(){const _0x2eb2e7=_0x5cc791;_0x2cfb05()[_0x2eb2e7('0x127f')](_0x32fdb3['voicemailMessages'][_0x2eb2e7('0x269a')],{'id':_0x562337['id']}),_0x32fdb3[_0x2eb2e7('0xbd8')]['count']-=0x1,!_0x32fdb3[_0x2eb2e7('0xbd8')]['rows'][_0x2eb2e7('0x264b')]&&_0x45875f(),_0x55bcb1[_0x2eb2e7('0x103b')]({'title':_0x2eb2e7('0x15e'),'msg':_0x562337[_0x2eb2e7('0x4f0')]?_0x562337[_0x2eb2e7('0x4f0')]+_0x2eb2e7('0x7cd'):''});})[_0x5cc791('0x1a80')](function(_0x189691){const _0x35e7f6=_0x5cc791;if(_0x189691[_0x35e7f6('0x25f4')]&&_0x189691['data']['errors']&&_0x189691[_0x35e7f6('0x25f4')][_0x35e7f6('0x61a')][_0x35e7f6('0x264b')]){_0x32fdb3[_0x35e7f6('0x61a')]=_0x189691['data'][_0x35e7f6('0x61a')]||[{'message':_0x189691['toString'](),'type':_0x35e7f6('0xd16')}];for(let _0x53a406=0x0;_0x53a406<_0x189691[_0x35e7f6('0x25f4')][_0x35e7f6('0x61a')][_0x35e7f6('0x264b')];_0x53a406++){_0x55bcb1[_0x35e7f6('0xfc9')]({'title':_0x189691[_0x35e7f6('0x25f4')]['errors'][_0x53a406]['type'],'msg':_0x189691[_0x35e7f6('0x25f4')][_0x35e7f6('0x61a')][_0x53a406][_0x35e7f6('0x1e70')]});}}else _0x55bcb1[_0x35e7f6('0xfc9')]({'title':_0x189691['status']?_0x35e7f6('0x1e21')+_0x189691[_0x35e7f6('0x52d')]+_0x35e7f6('0x11e1')+_0x189691[_0x35e7f6('0xe1b')]:_0x35e7f6('0xd16'),'msg':_0x189691[_0x35e7f6('0x25f4')]?JSON[_0x35e7f6('0xbac')](_0x189691[_0x35e7f6('0x25f4')][_0x35e7f6('0x1e70')]):_0x189691['message']||_0x189691['toString']()});});}function _0x10d161(){const _0x341f74=_0x656c2,_0x48de16=angular[_0x341f74('0x225f')](_0x32fdb3['selectedVoicemailMessages']);return _0x32fdb3[_0x341f74('0x252f')]=[],_0x48de16;}function _0x27a5b3(_0xf187e5){const _0x1e03c5=_0x656c2,_0x2c525a=_0x7c6727['confirm']()['title'](_0x1e03c5('0x1810'))[_0x1e03c5('0xf3c')](_0x1e03c5('0x12b5')+_0x32fdb3['selectedVoicemailMessages'][_0x1e03c5('0x264b')]+_0x1e03c5('0x196d')+_0x1e03c5('0x3f3'))['ariaLabel'](_0x1e03c5('0x2297'))[_0x1e03c5('0x203b')](_0xf187e5)['ok']('OK')[_0x1e03c5('0x3f')](_0x1e03c5('0x2d3'));_0x7c6727[_0x1e03c5('0x1f80')](_0x2c525a)['then'](function(){const _0x12e4e6=_0x1e03c5;_0x32fdb3[_0x12e4e6('0x252f')][_0x12e4e6('0x2782')](function(_0x1f6362){_0x5c9a2d(_0x1f6362);}),_0x32fdb3[_0x12e4e6('0x252f')]=[];});}let _0x164c18=!![],_0x34d6fa=0x1;_0x33d0f8[_0x656c2('0xe83')](_0x656c2('0x28b4'),function(_0xf11e3d,_0x2b8b80){const _0x5aff31=_0x656c2;_0x164c18?_0x23e8ac(function(){_0x164c18=![];}):(!_0x2b8b80&&(_0x34d6fa=_0x32fdb3['query']['page']),_0xf11e3d!==_0x2b8b80&&(_0x32fdb3['query'][_0x5aff31('0x1a43')]=0x1),!_0xf11e3d&&(_0x32fdb3[_0x5aff31('0x2218')][_0x5aff31('0x1a43')]=_0x34d6fa),_0x45875f());});}const _0x41aa53=_0x2e7542;_0x3b9c75[_0x36e6f4('0x1294')]=['$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x1ee9'),_0x36e6f4('0x17aa')];function _0x3b9c75(_0x1b0d9d,_0x3272f7,_0x50e24d,_0x540b1e,_0x3ae1c1,_0x47352b,_0x3b12f7,_0x377dc2,_0x1b4285,_0x1ef688,_0x112aa4,_0x4b5581){const _0xe19180=_0x36e6f4,_0x15062a=this;_0x15062a[_0xe19180('0x98')]=_0x1ef688[_0xe19180('0x26cd')](),_0x15062a[_0xe19180('0x5c9')]=_0x47352b,_0x15062a[_0xe19180('0xf8a')]=_0x3b12f7,_0x15062a[_0xe19180('0x2900')]=_0x15062a['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x15062a[_0xe19180('0x246b')]=_0x3272f7[_0xe19180('0x6f1')]()+_0xe19180('0xc51')+_0x3272f7['host'](),_0x15062a['voicemail']=_0x112aa4||_0x1b0d9d['params']['voicemail']||{},_0x15062a[_0xe19180('0x17aa')]=_0x4b5581&&_0x4b5581[_0xe19180('0x240f')]==0x1?_0x4b5581[_0xe19180('0x269a')][0x0]:null,_0x15062a[_0xe19180('0x243c')]=_0x1ef688[_0xe19180('0xd87')](_0x15062a['userProfileSection']?_0x15062a[_0xe19180('0x17aa')][_0xe19180('0x243c')]:null),_0x15062a['hasModulePermissions']={},_0x15062a['selectedTab']=_0x1b0d9d[_0xe19180('0x23f')][_0xe19180('0xbe3')]||0x0,_0x15062a[_0xe19180('0x31d')]=_0x1b4285[_0xe19180('0x1fa1')],_0x15062a[_0xe19180('0x21e6')]=_0x288713,_0x15062a['saveVoicemail']=_0x25a013,_0x1ef688[_0xe19180('0x1ac6')](_0xe19180('0xa7c'))?_0x377dc2['voiceContext'][_0xe19180('0xd83')]({'fields':_0xe19180('0x1776'),'sort':_0xe19180('0x4f0')})[_0xe19180('0xa44')]['then'](function(_0x4a9a42){const _0x14b1e6=_0xe19180;_0x15062a[_0x14b1e6('0x160a')]=_0x4a9a42[_0x14b1e6('0x269a')]||[];})[_0xe19180('0x1a80')](function(_0x3d6bb8){const _0x1a7ef8=_0xe19180;_0x1b4285['error']({'title':_0x3d6bb8[_0x1a7ef8('0x52d')]?_0x1a7ef8('0x1e21')+_0x3d6bb8[_0x1a7ef8('0x52d')]+_0x1a7ef8('0x11e1')+_0x3d6bb8[_0x1a7ef8('0xe1b')]:'SYSTEM:GET_CONTEXTS','msg':_0x3d6bb8[_0x1a7ef8('0x25f4')]?JSON[_0x1a7ef8('0xbac')](_0x3d6bb8[_0x1a7ef8('0x25f4')]):_0x3d6bb8[_0x1a7ef8('0x1586')]()});}):_0x377dc2[_0xe19180('0x23b1')][_0xe19180('0xd83')]({'fields':_0xe19180('0x1776'),'sort':_0xe19180('0x4f0')})[_0xe19180('0xa44')]['then'](function(_0x216957){const _0x243ee3=_0xe19180;_0x15062a['contexts']=_0x216957[_0x243ee3('0x269a')]||[];})[_0xe19180('0x1166')](function(){const _0x47f8e4=_0xe19180;return _0x377dc2[_0x47f8e4('0x17aa')][_0x47f8e4('0xd83')]({'userProfileId':_0x15062a[_0x47f8e4('0x98')]['userProfileId'],'sectionId':0x195})[_0x47f8e4('0xa44')];})['then'](function(_0x51621c){const _0x49ffa2=_0xe19180,_0x4affa4=_0x51621c&&_0x51621c[_0x49ffa2('0x269a')]?_0x51621c[_0x49ffa2('0x269a')][0x0]:null;if(!_0x4affa4)return _0x377dc2[_0x49ffa2('0x23b1')]['get']({'fields':_0x49ffa2('0x1776'),'sort':_0x49ffa2('0x4f0'),'defaultEntry':0x1})[_0x49ffa2('0xa44')][_0x49ffa2('0x1166')](function(_0x1580b6){const _0x323d80=_0x49ffa2;_0x15062a[_0x323d80('0x160a')]=_0x1580b6[_0x323d80('0x269a')]||[];});else{if(!_0x4affa4['autoAssociation'])return _0x377dc2[_0x49ffa2('0x4b5')][_0x49ffa2('0xd83')]({'sectionId':_0x4affa4['id']})[_0x49ffa2('0xa44')]['then'](function(_0x197036){const _0x17c093=_0x49ffa2,_0x14e074=_0x2cfb05()['map'](_0x197036[_0x17c093('0x269a')],function(_0x2612ce){const _0x35c664=_0x17c093;return _0x2cfb05()[_0x35c664('0xc38')](_0x15062a[_0x35c664('0x160a')],{'id':_0x2612ce[_0x35c664('0x24e8')]});});let _0x44b5af=null;_0x15062a[_0x17c093('0x1ee9')]&&(_0x44b5af=_0x2cfb05()['find'](_0x15062a[_0x17c093('0x160a')],{'name':_0x15062a[_0x17c093('0x1ee9')][_0x17c093('0xe1c')]}));if(_0x44b5af&&!_0x2cfb05()[_0x17c093('0x1798')](_0x14e074,['id',_0x44b5af['id']])){const _0x362197=_0x2cfb05()[_0x17c093('0xc38')](_0x15062a[_0x17c093('0x160a')],{'id':_0x44b5af['id']});_0x362197['canSelect']=![],_0x14e074[_0x17c093('0x1514')](_0x362197);}_0x15062a[_0x17c093('0x160a')]=_0x14e074;});}})[_0xe19180('0x1a80')](function(_0x5d296f){const _0x2d37f4=_0xe19180;_0x1b4285[_0x2d37f4('0xfc9')]({'title':_0x5d296f[_0x2d37f4('0x52d')]?_0x2d37f4('0x1e21')+_0x5d296f[_0x2d37f4('0x52d')]+'\x20-\x20'+_0x5d296f['statusText']:'SYSTEM:GETcontexts','msg':_0x5d296f[_0x2d37f4('0x25f4')]?JSON[_0x2d37f4('0xbac')](_0x5d296f[_0x2d37f4('0x25f4')]):_0x5d296f[_0x2d37f4('0x1586')]()});});function _0x288713(){const _0x17b228=_0xe19180;_0x1b0d9d['go']('app.voice.voicemails',{},{'reload':_0x17b228('0x27be')});}function _0x25a013(){const _0x55e934=_0xe19180;_0x377dc2[_0x55e934('0x8d4')][_0x55e934('0x1449')]({'id':_0x15062a['voicemail']['id']},_0x15062a[_0x55e934('0x1ee9')])[_0x55e934('0xa44')][_0x55e934('0x1166')](function(){const _0x5c2ae0=_0x55e934;_0x1b4285['success']({'title':_0x5c2ae0('0x25b7'),'msg':_0x15062a['voicemail'][_0x5c2ae0('0x4f0')]?_0x15062a[_0x5c2ae0('0x1ee9')][_0x5c2ae0('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x55e934('0x1a80')](function(_0x190d72){const _0x313801=_0x55e934;_0x1b4285[_0x313801('0xfc9')]({'title':_0x190d72[_0x313801('0x52d')]?'API:'+_0x190d72['status']+_0x313801('0x11e1')+_0x190d72[_0x313801('0xe1b')]:_0x313801('0xd16'),'msg':_0x190d72[_0x313801('0x25f4')]?JSON[_0x313801('0xbac')](_0x190d72[_0x313801('0x25f4')]):_0x190d72[_0x313801('0x1586')]()});});}}const _0x81db1d=_0x3b9c75,_0x4c58f2=_0x2734b2['p']+_0x36e6f4('0x2761');_0x41a0f5['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state','$mdSidenav',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),'$translate',_0x36e6f4('0x1149'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),'api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a')];function _0x41a0f5(_0x268d51,_0x5daa35,_0x3b0540,_0x399a15,_0x13d27f,_0x5c5d10,_0x3fd724,_0x16ee65,_0x2d954d,_0xe46969,_0x3ea5a6,_0x3a2d38,_0x3dd4b9,_0x519f1c,_0x317700,_0x3f7512,_0x1f1565){const _0x292428=_0x36e6f4,_0x579d19=this;_0x579d19[_0x292428('0x5c9')]=_0x3f7512,_0x579d19[_0x292428('0xf8a')]=_0x1f1565,_0x579d19[_0x292428('0x98')]=_0x317700[_0x292428('0x26cd')](),_0x579d19['voicemails']=_0x2d954d||{'count':0x0,'rows':[]},_0x579d19[_0x292428('0x7f')]=_0xe46969,_0x579d19[_0x292428('0x17aa')]=_0x3ea5a6&&_0x3ea5a6[_0x292428('0x240f')]==0x1?_0x3ea5a6[_0x292428('0x269a')][0x0]:null,_0x579d19[_0x292428('0x243c')]=_0x317700['parseCrudPermissions'](_0x579d19[_0x292428('0x17aa')]?_0x579d19[_0x292428('0x17aa')][_0x292428('0x243c')]:null),_0x579d19[_0x292428('0x916')]=_0x292428('0x1149'),_0x579d19[_0x292428('0xef5')]='',_0x579d19['listOrderAsc']=null,_0x579d19[_0x292428('0x16a9')]=[],_0x579d19['query']={'fields':'createdAt,updatedAt,id,customer_id,fullname,email,password,mailbox,context,tz,attach,envelope,delete,emailbody,emailsubject,maxsecs,maxmsg','sort':'-updatedAt','limit':0xa,'page':0x1},_0x579d19['arrayattach']=_0x2cfb05()[_0x292428('0x155c')]([{'option':_0x292428('0x193c'),'value':_0x292428('0x20b3')},{'option':'No','value':'\x27no\x27'}],function(_0x49c079){const _0x227a8c=_0x292428;return _0x2cfb05()['replace'](_0x49c079[_0x227a8c('0x18e0')],new RegExp('\x27','g'),'');}),_0x579d19[_0x292428('0xf2b')]=_0x2cfb05()[_0x292428('0x155c')]([{'option':'Yes','value':_0x292428('0x20b3')},{'option':'No','value':_0x292428('0x119b')}],function(_0x343910){const _0x429ddf=_0x292428;return _0x2cfb05()[_0x429ddf('0xf3')](_0x343910[_0x429ddf('0x18e0')],new RegExp('\x27','g'),'');}),_0x579d19[_0x292428('0xa2')]=_0x2cfb05()[_0x292428('0x155c')]([{'option':_0x292428('0x193c'),'value':'\x27yes\x27'},{'option':'No','value':'\x27no\x27'}],function(_0x5de162){const _0x3873e7=_0x292428;return _0x2cfb05()['replace'](_0x5de162[_0x3873e7('0x18e0')],new RegExp('\x27','g'),'');}),_0x579d19[_0x292428('0x1ff6')]=_0x382adb,_0x579d19[_0x292428('0x8d8')]=_0x323f77,_0x579d19['success']=_0xab63a5,_0x579d19[_0x292428('0x4d5')]=_0x2367cb,_0x579d19[_0x292428('0x14af')]=_0x330aa1,_0x579d19[_0x292428('0x129d')]=_0x5ae300,_0x579d19[_0x292428('0x3a0')]=_0x6dc70d,_0x579d19[_0x292428('0x12a1')]=_0xc2e4b7,_0x579d19[_0x292428('0x26fd')]=_0x1f33d7,_0x579d19[_0x292428('0x1171')]=_0x4f5467;function _0x382adb(_0x1440cb){const _0x5b672d=_0x292428;_0x3b0540['go'](_0x5b672d('0x1730'),{'id':_0x1440cb['id'],'voicemail':_0x1440cb,'crudPermissions':_0x579d19[_0x5b672d('0x243c')]});}function _0x323f77(_0x4dde9d,_0x3d89d0){const _0x2764f7=_0x292428,_0x4498d2=_0x13d27f['confirm']()[_0x2764f7('0xcdc')](_0x2764f7('0x288d')+_0x2cfb05()[_0x2764f7('0xb35')](_0x2764f7('0x1ee9'))+'?')['htmlContent'](_0x2764f7('0x12b5')+(_0x4dde9d[_0x2764f7('0x4f0')]||_0x2764f7('0x1ee9'))+_0x2764f7('0xace')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x2764f7('0x60'))[_0x2764f7('0x203b')](_0x3d89d0)['ok']('OK')[_0x2764f7('0x3f')](_0x2764f7('0x2d3'));_0x13d27f[_0x2764f7('0x1f80')](_0x4498d2)[_0x2764f7('0x1166')](function(){_0x5ae300(_0x4dde9d);},function(){const _0x3e4aad=_0x2764f7;console['log'](_0x3e4aad('0x2d3'));});}let _0x256b3c=!![],_0x1a6d71=0x1;_0x268d51[_0x292428('0xe83')](_0x292428('0x12d8'),function(_0x589868,_0x31bc84){const _0x12d251=_0x292428;_0x256b3c?_0x3fd724(function(){_0x256b3c=![];}):(!_0x31bc84&&(_0x1a6d71=_0x579d19[_0x12d251('0x2218')][_0x12d251('0x1a43')]),_0x589868!==_0x31bc84&&(_0x579d19['query'][_0x12d251('0x1a43')]=0x1),!_0x589868&&(_0x579d19[_0x12d251('0x2218')]['page']=_0x1a6d71),_0x579d19[_0x12d251('0x4d5')]());});function _0xab63a5(_0x186687){const _0x5d7ea6=_0x292428;_0x579d19[_0x5d7ea6('0x1149')]=_0x186687||{'count':0x0,'rows':[]};}function _0x2367cb(){const _0x29432a=_0x292428;_0x579d19[_0x29432a('0x2218')][_0x29432a('0x1098')]=(_0x579d19[_0x29432a('0x2218')][_0x29432a('0x1a43')]-0x1)*_0x579d19[_0x29432a('0x2218')]['limit'],_0x317700['hasRole'](_0x29432a('0xa7c'))?_0x579d19[_0x29432a('0x1f48')]=_0x3a2d38[_0x29432a('0x8d4')][_0x29432a('0xd83')](_0x579d19[_0x29432a('0x2218')],_0xab63a5)[_0x29432a('0xa44')]:(_0x579d19['query']['id']=_0x579d19[_0x29432a('0x7f')]['id'],_0x579d19['query'][_0x29432a('0xe60')]='Voicemails',_0x579d19['promise']=_0x3a2d38[_0x29432a('0x7f')][_0x29432a('0x263a')](_0x579d19[_0x29432a('0x2218')],_0xab63a5)[_0x29432a('0xa44')]);}function _0x330aa1(_0x23d770,_0xa8f4){const _0x4f8adc=_0x292428;_0x13d27f[_0x4f8adc('0x1f80')]({'controller':_0x4f8adc('0x3b1'),'controllerAs':'vm','templateUrl':_0x4c58f2,'parent':angular[_0x4f8adc('0x1194')](_0x5c5d10['body']),'targetEvent':_0x23d770,'clickOutsideToClose':!![],'locals':{'voicemail':_0xa8f4,'voicemails':_0x579d19[_0x4f8adc('0x1149')][_0x4f8adc('0x269a')],'license':_0x579d19['license'],'setting':_0x579d19[_0x4f8adc('0xf8a')],'crudPermissions':_0x579d19[_0x4f8adc('0x243c')]}});}function _0x5ae300(_0x27d0ee){const _0x22d359=_0x292428;_0x3a2d38[_0x22d359('0x8d4')][_0x22d359('0x906')]({'id':_0x27d0ee['id']})['$promise'][_0x22d359('0x1166')](function(){const _0x4ef25d=_0x22d359;_0x2cfb05()['remove'](_0x579d19[_0x4ef25d('0x1149')][_0x4ef25d('0x269a')],{'id':_0x27d0ee['id']}),_0x579d19[_0x4ef25d('0x1149')][_0x4ef25d('0x240f')]-=0x1,!_0x579d19[_0x4ef25d('0x1149')][_0x4ef25d('0x269a')][_0x4ef25d('0x264b')]&&_0x579d19['getVoicemails'](),_0x519f1c[_0x4ef25d('0x103b')]({'title':_0x2cfb05()[_0x4ef25d('0xb35')]('Voicemail')+_0x4ef25d('0x2b6'),'msg':_0x27d0ee[_0x4ef25d('0x4f0')]?_0x27d0ee[_0x4ef25d('0x4f0')]+_0x4ef25d('0x7cd'):''});})[_0x22d359('0x1a80')](function(_0x3d47ec){const _0x47433a=_0x22d359;if(_0x3d47ec[_0x47433a('0x25f4')]&&_0x3d47ec[_0x47433a('0x25f4')][_0x47433a('0x61a')]&&_0x3d47ec[_0x47433a('0x25f4')][_0x47433a('0x61a')][_0x47433a('0x264b')]){_0x579d19[_0x47433a('0x61a')]=_0x3d47ec['data'][_0x47433a('0x61a')]||[{'message':_0x3d47ec['toString'](),'type':_0x47433a('0x187c')}];for(let _0xad0e18=0x0;_0xad0e18<_0x3d47ec[_0x47433a('0x25f4')][_0x47433a('0x61a')]['length'];_0xad0e18++){_0x519f1c[_0x47433a('0xfc9')]({'title':_0x3d47ec['data'][_0x47433a('0x61a')][_0xad0e18]['type'],'msg':_0x3d47ec['data'][_0x47433a('0x61a')][_0xad0e18][_0x47433a('0x1e70')]});}}else _0x519f1c[_0x47433a('0xfc9')]({'title':_0x3d47ec['status']?_0x47433a('0x1e21')+_0x3d47ec['status']+'\x20-\x20'+_0x3d47ec[_0x47433a('0xe1b')]:_0x47433a('0x187c'),'msg':_0x3d47ec[_0x47433a('0x25f4')]?JSON[_0x47433a('0xbac')](_0x3d47ec[_0x47433a('0x25f4')][_0x47433a('0x1e70')]):_0x3d47ec[_0x47433a('0x1e70')]||_0x3d47ec[_0x47433a('0x1586')]()});});}function _0x6dc70d(){const _0x3ef1c8=_0x292428,_0x53e22d=angular[_0x3ef1c8('0x225f')](_0x579d19[_0x3ef1c8('0x16a9')]);return _0x579d19[_0x3ef1c8('0x16a9')]=[],_0x53e22d;}function _0xc2e4b7(_0x3eead0){const _0x458c12=_0x292428,_0x26cbd9=_0x13d27f[_0x458c12('0x1d26')]()[_0x458c12('0xcdc')](_0x458c12('0x1292'))['htmlContent'](_0x458c12('0x12b5')+_0x579d19[_0x458c12('0x16a9')][_0x458c12('0x264b')]+_0x458c12('0x196d')+_0x458c12('0x3f3'))['ariaLabel'](_0x458c12('0x752'))[_0x458c12('0x203b')](_0x3eead0)['ok']('OK')[_0x458c12('0x3f')](_0x458c12('0x2d3'));_0x13d27f[_0x458c12('0x1f80')](_0x26cbd9)[_0x458c12('0x1166')](function(){const _0x58d2b6=_0x458c12;_0x579d19['selectedVoicemails']['forEach'](function(_0x136366){_0x5ae300(_0x136366);}),_0x579d19[_0x58d2b6('0x16a9')]=[];});}function _0x1f33d7(){const _0x255477=_0x292428;_0x579d19[_0x255477('0x16a9')]=[];}function _0x4f5467(){const _0x35290f=_0x292428;_0x579d19[_0x35290f('0x16a9')]=_0x579d19[_0x35290f('0x1149')][_0x35290f('0x269a')];}}const _0x578073=_0x41a0f5;_0x5e5dd0[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x25d3'),_0x36e6f4('0x1d96'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'crudPermissions'];function _0x5e5dd0(_0x42a7e3,_0x58cc7c,_0x2a50aa,_0x5bc9b3,_0x4e50eb,_0x2a02d0,_0x212398,_0x55ff3c,_0x273fed,_0x3ff0ab,_0x3e5e69,_0x507062,_0x4d54dd,_0x458c8c){const _0x2de946=_0x36e6f4,_0x5ba0a5=this;_0x5ba0a5['currentUser']=_0x3e5e69[_0x2de946('0x26cd')](),_0x5ba0a5[_0x2de946('0x61a')]=[],_0x5ba0a5['setting']=_0x4d54dd,_0x5ba0a5[_0x2de946('0x5c9')]=_0x507062,_0x5ba0a5[_0x2de946('0x243c')]=_0x458c8c,_0x5ba0a5[_0x2de946('0x128b')]={},_0x5ba0a5[_0x2de946('0x2900')]=_0x5ba0a5['setting']&&_0x5ba0a5[_0x2de946('0xf8a')][_0x2de946('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5ba0a5[_0x2de946('0xcdc')]=_0x2de946('0x11e9'),_0x5ba0a5['voicePrefix']=angular[_0x2de946('0x225f')](_0x273fed),_0x5ba0a5['voicePrefixes']=_0x55ff3c,_0x5ba0a5[_0x2de946('0xb20')]=![];!_0x5ba0a5[_0x2de946('0x1d96')]&&(_0x5ba0a5[_0x2de946('0x1d96')]={},_0x5ba0a5['title']=_0x2de946('0x19c1'),_0x5ba0a5[_0x2de946('0xb20')]=!![]);_0x5ba0a5[_0x2de946('0x137c')]=_0x5b69e5,_0x5ba0a5[_0x2de946('0x26f0')]=_0xc9c76c,_0x5ba0a5[_0x2de946('0x2f3')]=_0x4af926,_0x5ba0a5['getDateFromString']=_0xbaa626,_0x5ba0a5['closeDialog']=_0x36a538,_0x3e5e69['hasRole']('admin')?_0x3ff0ab[_0x2de946('0x1deb')][_0x2de946('0xd83')]({'fields':_0x2de946('0x27bd'),'type':_0x2de946('0x587'),'VoiceExtensionId':_0x2de946('0x15d7'),'nolimit':'true'})[_0x2de946('0xa44')][_0x2de946('0x1166')](function(_0x24b4c2){const _0x52d64c=_0x2de946;_0x5ba0a5[_0x52d64c('0x2404')]=_0x24b4c2[_0x52d64c('0x269a')]||[];})['catch'](function(_0x4dcd86){const _0x2c7d3b=_0x2de946;_0x212398['error']({'title':_0x4dcd86[_0x2c7d3b('0x52d')]?'API:'+_0x4dcd86[_0x2c7d3b('0x52d')]+_0x2c7d3b('0x11e1')+_0x4dcd86[_0x2c7d3b('0xe1b')]:_0x2c7d3b('0x261f'),'msg':_0x4dcd86[_0x2c7d3b('0x25f4')]?JSON[_0x2c7d3b('0xbac')](_0x4dcd86[_0x2c7d3b('0x25f4')]):_0x4dcd86[_0x2c7d3b('0x1586')]()});}):_0x3ff0ab[_0x2de946('0x1deb')][_0x2de946('0xd83')]({'fields':_0x2de946('0x27bd'),'type':_0x2de946('0x587'),'VoiceExtensionId':'null','nolimit':_0x2de946('0xf3b')})[_0x2de946('0xa44')][_0x2de946('0x1166')](function(_0x2fcf94){const _0x22bb94=_0x2de946;_0x5ba0a5[_0x22bb94('0x2404')]=_0x2fcf94[_0x22bb94('0x269a')]||[];})[_0x2de946('0x1166')](function(){const _0xa41033=_0x2de946;return _0x3ff0ab[_0xa41033('0x17aa')][_0xa41033('0xd83')]({'userProfileId':_0x5ba0a5[_0xa41033('0x98')][_0xa41033('0xb86')],'sectionId':0x193})[_0xa41033('0xa44')];})[_0x2de946('0x1166')](function(_0x83021e){const _0x49de26=_0x2de946,_0xf722b4=_0x83021e&&_0x83021e[_0x49de26('0x269a')]?_0x83021e[_0x49de26('0x269a')][0x0]:null;if(!_0xf722b4){const _0x73595a=[];let _0x5d296d=null;_0x5ba0a5[_0x49de26('0x1d96')]&&(_0x5d296d=_0x2cfb05()[_0x49de26('0xc38')](_0x5ba0a5[_0x49de26('0x2404')],{'id':Number(_0x5ba0a5[_0x49de26('0x1d96')][_0x49de26('0xa51')])}));for(let _0x3dcb7f=0x0;_0x3dcb7f<_0x5ba0a5[_0x49de26('0x2404')][_0x49de26('0x264b')];_0x3dcb7f++){_0x5d296d&&_0x5ba0a5[_0x49de26('0x2404')][_0x3dcb7f]['id']===_0x5d296d['id']&&(_0x5ba0a5[_0x49de26('0x2404')][_0x3dcb7f][_0x49de26('0x2378')]=![],_0x73595a[_0x49de26('0x1514')](_0x5ba0a5[_0x49de26('0x2404')][_0x3dcb7f]));}_0x5ba0a5[_0x49de26('0x2404')]=_0x73595a;}else{if(!_0xf722b4[_0x49de26('0x1a2b')])return _0x3ff0ab[_0x49de26('0x4b5')][_0x49de26('0xd83')]({'sectionId':_0xf722b4['id']})[_0x49de26('0xa44')][_0x49de26('0x1166')](function(_0x16912d){const _0x2b926d=_0x49de26,_0x366a7b=_0x2cfb05()[_0x2b926d('0x2563')](_0x16912d[_0x2b926d('0x269a')],function(_0x35e947){const _0x43efe3=_0x2b926d;return _0x2cfb05()[_0x43efe3('0xc38')](_0x5ba0a5['outboundRoutes'],{'id':_0x35e947[_0x43efe3('0x24e8')]});});let _0x3fe791=null;_0x5ba0a5['voicePrefix']&&(_0x3fe791=_0x2cfb05()[_0x2b926d('0xc38')](_0x5ba0a5['outboundRoutes'],{'id':Number(_0x5ba0a5['voicePrefix'][_0x2b926d('0xa51')])}));if(_0x3fe791&&!_0x2cfb05()[_0x2b926d('0x1798')](_0x366a7b,['id',_0x3fe791['id']])){const _0x4bf232=_0x2cfb05()[_0x2b926d('0xc38')](_0x5ba0a5['outboundRoutes'],{'id':_0x3fe791['id']});_0x4bf232[_0x2b926d('0x2378')]=![],_0x366a7b['push'](_0x4bf232);}_0x5ba0a5[_0x2b926d('0x2404')]=_0x366a7b;});}})['catch'](function(_0x17a8ca){const _0x333599=_0x2de946;_0x212398['error']({'title':_0x17a8ca[_0x333599('0x52d')]?_0x333599('0x1e21')+_0x17a8ca[_0x333599('0x52d')]+'\x20-\x20'+_0x17a8ca[_0x333599('0xe1b')]:_0x333599('0x2764'),'msg':_0x17a8ca[_0x333599('0x25f4')]?JSON[_0x333599('0xbac')](_0x17a8ca[_0x333599('0x25f4')]):_0x17a8ca[_0x333599('0x1586')]()});});function _0x5b69e5(){const _0x180893=_0x2de946;_0x5ba0a5[_0x180893('0x61a')]=[],_0x3ff0ab[_0x180893('0x1d96')][_0x180893('0x9cc')](_0x5ba0a5[_0x180893('0x1d96')])['$promise'][_0x180893('0x1166')](function(_0x54a6c4){const _0x3d1bad=_0x180893;_0x5ba0a5[_0x3d1bad('0x25d3')][_0x3d1bad('0x2450')](_0x54a6c4[_0x3d1bad('0x2876')]()),_0x212398[_0x3d1bad('0x103b')]({'title':'voicePrefix\x20properly\x20created','msg':_0x5ba0a5[_0x3d1bad('0x1d96')]['name']?_0x5ba0a5[_0x3d1bad('0x1d96')][_0x3d1bad('0x4f0')]+_0x3d1bad('0x1eda'):''}),_0x36a538(_0x54a6c4);})[_0x180893('0x1a80')](function(_0x48955a){const _0x14f0c8=_0x180893;if(_0x48955a[_0x14f0c8('0x25f4')]&&_0x48955a[_0x14f0c8('0x25f4')][_0x14f0c8('0x61a')]&&_0x48955a['data'][_0x14f0c8('0x61a')]['length']){_0x5ba0a5['errors']=_0x48955a[_0x14f0c8('0x25f4')][_0x14f0c8('0x61a')]||[{'message':_0x48955a['toString'](),'type':_0x14f0c8('0x26c6')}];for(let _0xc6e5e0=0x0;_0xc6e5e0<_0x48955a['data'][_0x14f0c8('0x61a')][_0x14f0c8('0x264b')];_0xc6e5e0+=0x1){_0x212398['error']({'title':_0x48955a[_0x14f0c8('0x25f4')]['errors'][_0xc6e5e0][_0x14f0c8('0x1345')],'msg':_0x48955a[_0x14f0c8('0x25f4')][_0x14f0c8('0x61a')][_0xc6e5e0][_0x14f0c8('0x1e70')]});}}else _0x212398[_0x14f0c8('0xfc9')]({'title':_0x48955a[_0x14f0c8('0x52d')]?'API:'+_0x48955a[_0x14f0c8('0x52d')]+_0x14f0c8('0x11e1')+_0x48955a[_0x14f0c8('0xe1b')]:_0x14f0c8('0x26c6'),'msg':_0x48955a[_0x14f0c8('0x25f4')]?JSON[_0x14f0c8('0xbac')](_0x48955a[_0x14f0c8('0x25f4')]['message']):_0x48955a[_0x14f0c8('0x1586')]()});});}function _0xc9c76c(){const _0x4cdf74=_0x2de946;_0x5ba0a5['errors']=[],_0x3ff0ab[_0x4cdf74('0x1d96')][_0x4cdf74('0x1449')]({'id':_0x5ba0a5[_0x4cdf74('0x1d96')]['id']},_0x5ba0a5['voicePrefix'])[_0x4cdf74('0xa44')][_0x4cdf74('0x1166')](function(_0x5171de){const _0x164780=_0x4cdf74,_0xb1bef=_0x2cfb05()[_0x164780('0xc38')](_0x5ba0a5[_0x164780('0x25d3')],{'id':_0x5171de['id']});_0xb1bef&&_0x2cfb05()['merge'](_0xb1bef,_0x2cfb05()[_0x164780('0x1a08')](_0x5171de[_0x164780('0x2876')](),_0x2cfb05()['keys'](_0xb1bef))),_0x212398[_0x164780('0x103b')]({'title':_0x164780('0x1c77'),'msg':_0x5ba0a5[_0x164780('0x1d96')][_0x164780('0x4f0')]?_0x5ba0a5['voicePrefix'][_0x164780('0x4f0')]+_0x164780('0x7d'):''}),_0x36a538(_0x5171de);})['catch'](function(_0x1b8d48){const _0x461d59=_0x4cdf74;if(_0x1b8d48[_0x461d59('0x25f4')]&&_0x1b8d48[_0x461d59('0x25f4')][_0x461d59('0x61a')]&&_0x1b8d48[_0x461d59('0x25f4')]['errors']['length']){_0x5ba0a5[_0x461d59('0x61a')]=_0x1b8d48['data'][_0x461d59('0x61a')]||[{'message':_0x1b8d48[_0x461d59('0x1586')](),'type':_0x461d59('0x1477')}];for(let _0x25ce49=0x0;_0x25ce49<_0x1b8d48[_0x461d59('0x25f4')]['errors'][_0x461d59('0x264b')];_0x25ce49++){_0x212398[_0x461d59('0xfc9')]({'title':_0x1b8d48[_0x461d59('0x25f4')][_0x461d59('0x61a')][_0x25ce49][_0x461d59('0x1345')],'msg':_0x1b8d48[_0x461d59('0x25f4')][_0x461d59('0x61a')][_0x25ce49]['message']});}}else _0x212398[_0x461d59('0xfc9')]({'title':_0x1b8d48[_0x461d59('0x52d')]?_0x461d59('0x1e21')+_0x1b8d48[_0x461d59('0x52d')]+'\x20-\x20'+_0x1b8d48[_0x461d59('0xe1b')]:'api.voicePrefix.update','msg':_0x1b8d48[_0x461d59('0x25f4')]?JSON[_0x461d59('0xbac')](_0x1b8d48[_0x461d59('0x25f4')][_0x461d59('0x1e70')]):_0x1b8d48[_0x461d59('0x1586')]()});});}function _0x4af926(_0x46f90e){const _0x2100b5=_0x2de946;_0x5ba0a5['errors']=[];const _0x599a66=_0x5bc9b3[_0x2100b5('0x1d26')]()[_0x2100b5('0xcdc')](_0x2100b5('0x7fb'))[_0x2100b5('0xacc')](_0x2100b5('0x1ba1'))[_0x2100b5('0x8e8')](_0x2100b5('0x286'))['ok'](_0x2100b5('0x18'))[_0x2100b5('0x3f')]('Cancel')['targetEvent'](_0x46f90e);_0x5bc9b3[_0x2100b5('0x1f80')](_0x599a66)['then'](function(){const _0x30ded5=_0x2100b5;_0x3ff0ab[_0x30ded5('0x1d96')][_0x30ded5('0x906')]({'id':_0x5ba0a5['voicePrefix']['id']})[_0x30ded5('0xa44')]['then'](function(){const _0x298c25=_0x30ded5;_0x2cfb05()[_0x298c25('0x127f')](_0x5ba0a5[_0x298c25('0x25d3')],{'id':_0x5ba0a5[_0x298c25('0x1d96')]['id']}),_0x212398[_0x298c25('0x103b')]({'title':'voicePrefix\x20properly\x20deleted!','msg':(_0x5ba0a5[_0x298c25('0x1d96')]['name']||_0x298c25('0x1d96'))+_0x298c25('0x7cd')}),_0x36a538(_0x5ba0a5[_0x298c25('0x1d96')]);})[_0x30ded5('0x1a80')](function(_0x3901a4){const _0x10b4a4=_0x30ded5;if(_0x3901a4[_0x10b4a4('0x25f4')]&&_0x3901a4[_0x10b4a4('0x25f4')][_0x10b4a4('0x61a')]&&_0x3901a4[_0x10b4a4('0x25f4')][_0x10b4a4('0x61a')]['length']){_0x5ba0a5[_0x10b4a4('0x61a')]=_0x3901a4['data'][_0x10b4a4('0x61a')]||[{'message':_0x3901a4[_0x10b4a4('0x1586')](),'type':_0x10b4a4('0xc73')}];for(let _0x442cba=0x0;_0x442cba<_0x3901a4[_0x10b4a4('0x25f4')][_0x10b4a4('0x61a')][_0x10b4a4('0x264b')];_0x442cba++){_0x212398[_0x10b4a4('0xfc9')]({'title':_0x3901a4[_0x10b4a4('0x25f4')][_0x10b4a4('0x61a')][_0x442cba][_0x10b4a4('0x1345')],'msg':_0x3901a4['data'][_0x10b4a4('0x61a')][_0x442cba][_0x10b4a4('0x1e70')]});}}else _0x212398[_0x10b4a4('0xfc9')]({'title':_0x3901a4['status']?'API:'+_0x3901a4[_0x10b4a4('0x52d')]+_0x10b4a4('0x11e1')+_0x3901a4['statusText']:_0x10b4a4('0xc73'),'msg':_0x3901a4[_0x10b4a4('0x25f4')]?JSON[_0x10b4a4('0xbac')](_0x3901a4[_0x10b4a4('0x25f4')][_0x10b4a4('0x1e70')]):_0x3901a4[_0x10b4a4('0x1e70')]||_0x3901a4[_0x10b4a4('0x1586')]()});});},function(){});}function _0xbaa626(_0xce8f57){return _0xce8f57===null?undefined:new Date(_0xce8f57);}function _0x36a538(_0x675566){const _0x30603b=_0x2de946;_0x5bc9b3[_0x30603b('0x1197')](_0x675566);}}const _0x5dd88c=_0x5e5dd0;_0x1c8741[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d96'),_0x36e6f4('0x25d3'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),'Auth',_0x36e6f4('0x243c')];function _0x1c8741(_0x451fe5,_0x398c92,_0x30238a,_0xb50ea8,_0xb3540a,_0x32c9f7,_0x2c6787,_0xba6f68,_0x190e57,_0x5a089c){const _0x4004d5=_0x36e6f4,_0x55c4b9=this;_0x55c4b9[_0x4004d5('0x98')]=_0x190e57[_0x4004d5('0x26cd')](),_0x55c4b9['voicePrefix']=_0xb3540a,_0x55c4b9['crudPermissions']=_0x5a089c,_0x55c4b9[_0x4004d5('0xf01')]=_0x2c6787,_0x55c4b9[_0x4004d5('0xbd7')]=[],_0x55c4b9[_0x4004d5('0x10ab')]=[],_0x55c4b9[_0x4004d5('0x18e1')]=[],_0x55c4b9[_0x4004d5('0x2111')]=[],_0x55c4b9[_0x4004d5('0x2781')]=[],_0x55c4b9[_0x4004d5('0x14d7')]=![],_0x55c4b9[_0x4004d5('0xae0')]=_0x4bb9e5,_0x55c4b9[_0x4004d5('0x1d92')]=_0x1cdabf,_0x55c4b9[_0x4004d5('0x24a0')]=_0x5d625a,_0x55c4b9['dualMultiselectOptions']={'readOnly':!_0x55c4b9['crudPermissions']['canEdit'],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x4004d5('0x4f0'),'line1':_0x4004d5('0x6e1'),'line2':['name','internal'],'line3':'','labelAll':_0xba6f68[_0x4004d5('0x25cc')]('VOICE.ALL_AGENTS'),'labelSelected':_0xba6f68['instant'](_0x4004d5('0x167')),'transferCallback':function(){const _0x3343f5=_0x4004d5,_0x49079b=_0x2cfb05()['xorBy'](_0x55c4b9[_0x3343f5('0x2781')],_0x55c4b9[_0x3343f5('0x18e1')],'id');_0x55c4b9['pendingChanges']=_0x2cfb05()[_0x3343f5('0x1081')](_0x49079b)?![]:!![];}};function _0x4bb9e5(){const _0x16c793=_0x4004d5;return _0x190e57[_0x16c793('0x1ac6')](_0x16c793('0xa7c'))?_0x5de3eb()[_0x16c793('0x1a80')](function(_0x1e4182){const _0x139904=_0x16c793;_0x30238a['error']({'title':_0x1e4182[_0x139904('0x52d')]?_0x139904('0x1e21')+_0x1e4182[_0x139904('0x52d')]+_0x139904('0x11e1')+_0x1e4182[_0x139904('0xe1b')]:_0x139904('0xd4c'),'msg':_0x1e4182[_0x139904('0x52d')]?JSON['stringify'](_0x1e4182[_0x139904('0x25f4')]):_0x1e4182[_0x139904('0x1586')]()});}):_0x4d3401()[_0x16c793('0x1166')](function(_0x22abc2){const _0x3460d5=_0x16c793;return _0x55c4b9[_0x3460d5('0xe60')]=_0x22abc2,_0x5de3eb();})[_0x16c793('0x1a80')](function(_0x11528d){const _0x34907b=_0x16c793;_0x30238a['error']({'title':_0x11528d[_0x34907b('0x52d')]?_0x34907b('0x1e21')+_0x11528d[_0x34907b('0x52d')]+_0x34907b('0x11e1')+_0x11528d[_0x34907b('0xe1b')]:_0x34907b('0xd4c'),'msg':_0x11528d['status']?JSON[_0x34907b('0xbac')](_0x11528d[_0x34907b('0x25f4')]):_0x11528d[_0x34907b('0x1586')]()});});}function _0x4d3401(){return _0x398c92(function(_0x1403e1,_0x108b22){const _0x34bc20=a0_0x3f2c;_0xb50ea8[_0x34bc20('0x17aa')][_0x34bc20('0xd83')]({'userProfileId':_0x55c4b9[_0x34bc20('0x98')]['userProfileId'],'name':_0x34bc20('0x2391')})[_0x34bc20('0xa44')][_0x34bc20('0x1166')](function(_0x59ba2a){const _0x2fa078=_0x34bc20,_0x5699fe=_0x59ba2a&&_0x59ba2a['rows']?_0x59ba2a[_0x2fa078('0x269a')][0x0]:null;_0x1403e1(_0x5699fe);})['catch'](function(_0x14d3e9){_0x108b22(_0x14d3e9);});});}function _0x5de3eb(){return _0x398c92(function(_0x130ba4,_0xd0ae7b){const _0x2c4cc7=a0_0x3f2c;return _0xcd85bb()[_0x2c4cc7('0x1166')](function(_0xfe3de1){const _0x31c485=_0x2c4cc7;return _0x55c4b9[_0x31c485('0xbd7')]=_0xfe3de1[_0x31c485('0x269a')]?_0xfe3de1['rows']:[],_0x190e57['hasRole'](_0x31c485('0xa7c'))?_0xfe3de1:_0x55c4b9[_0x31c485('0xe60')]?_0x55c4b9[_0x31c485('0xe60')][_0x31c485('0x1a2b')]?_0xfe3de1:_0x1f2b9e():null;})['then'](function(_0x5e83e6){const _0x5395ea=_0x2c4cc7,_0x4ab9e5=_0x5e83e6&&_0x5e83e6[_0x5395ea('0x269a')]?_0x5e83e6[_0x5395ea('0x269a')]:[];return _0x55c4b9[_0x5395ea('0x10ab')]=_0x2cfb05()[_0x5395ea('0x2563')](_0x4ab9e5,function(_0x3df531){const _0x2f52f2=_0x5395ea;return _0x2cfb05()[_0x2f52f2('0xc38')](_0x55c4b9[_0x2f52f2('0xbd7')],{'id':_0x190e57[_0x2f52f2('0x1ac6')](_0x2f52f2('0xa7c'))||_0x55c4b9[_0x2f52f2('0xe60')]['autoAssociation']?_0x3df531['id']:_0x3df531['resourceId']});}),_0x55c4b9[_0x5395ea('0x2111')]=angular['copy'](_0x55c4b9[_0x5395ea('0x10ab')]),_0x55c4b9['items'][_0x5395ea('0x2782')](function(_0x2b1451){const _0x2583b8=_0x5395ea,_0x1ca9e2=_0x2cfb05()[_0x2583b8('0xc38')](_0x55c4b9[_0x2583b8('0x10ab')],{'id':_0x2b1451['id']});_0x190e57['hasRole'](_0x2583b8('0xa7c'))?_0x2b1451[_0x2583b8('0x26ef')]=!![]:_0x2b1451[_0x2583b8('0x26ef')]=typeof _0x1ca9e2!=='undefined'?!![]:![];}),_0x1be960();})[_0x2c4cc7('0x1166')](function(_0x487b42){const _0x147ad2=_0x2c4cc7,_0x378fb7=_0x487b42&&_0x487b42[_0x147ad2('0x269a')]?_0x487b42[_0x147ad2('0x269a')]:[];_0x55c4b9[_0x147ad2('0x18e1')]=_0x2cfb05()[_0x147ad2('0x2563')](_0x378fb7,function(_0x4a22d5){const _0xa35d48=_0x147ad2,_0x28c52c=_0x2cfb05()[_0xa35d48('0xc38')](_0x55c4b9[_0xa35d48('0xbd7')],{'id':_0x4a22d5['id']});return _0x28c52c[_0xa35d48('0x23af')]=_0x4a22d5[_0xa35d48('0x1555')]?_0xa35d48('0x11e8')+_0x4a22d5['UservoicePrefix']['penalty']:'',_0x28c52c[_0xa35d48('0x1eef')]=typeof _0x4a22d5[_0xa35d48('0x1eef')]!==_0xa35d48('0x1048')?'<'+_0x4a22d5[_0xa35d48('0x1eef')]+'>':'',_0x28c52c;}),_0x55c4b9[_0x147ad2('0x2781')]=angular[_0x147ad2('0x225f')](_0x55c4b9['selectedItems']),_0x55c4b9[_0x147ad2('0xc68')]['selectedItems']=_0x55c4b9[_0x147ad2('0x18e1')],_0x55c4b9[_0x147ad2('0xc68')][_0x147ad2('0xbd7')]=_0x2cfb05()[_0x147ad2('0x24ac')](_0x55c4b9[_0x147ad2('0x10ab')],_0x55c4b9[_0x147ad2('0xc68')][_0x147ad2('0x18e1')],'id'),_0x130ba4();})['catch'](function(_0x143c24){_0xd0ae7b(_0x143c24);});});}function _0x1f2b9e(){return _0x398c92(function(_0xb65d85,_0x3ad550){const _0x455a8b=a0_0x3f2c;return _0xb50ea8[_0x455a8b('0x4b5')][_0x455a8b('0xd83')]({'sectionId':_0x55c4b9[_0x455a8b('0xe60')]['id'],'nolimit':!![]})['$promise']['then'](function(_0x1c0601){_0xb65d85(_0x1c0601);})['catch'](function(_0x1babb3){_0x3ad550(_0x1babb3);});});}function _0x1be960(){return _0x398c92(function(_0x21c38f,_0x367614){const _0x1ea89f=a0_0x3f2c;return _0xb50ea8['voicePrefix']['getAgents']({'id':_0x55c4b9[_0x1ea89f('0x1d96')]['id'],'fields':'id,name,internal,fullname','nolimit':!![],'role':_0x1ea89f('0x1eff')})[_0x1ea89f('0xa44')]['then'](function(_0x1846be){_0x21c38f(_0x1846be);})[_0x1ea89f('0x1a80')](function(_0x49d690){_0x367614(_0x49d690);});});}function _0xcd85bb(){return _0x398c92(function(_0x2e00cd,_0x3ded63){const _0x47f876=a0_0x3f2c;return _0xb50ea8[_0x47f876('0x557')][_0x47f876('0xd83')]({'fields':_0x47f876('0x1459'),'nolimit':!![],'role':_0x47f876('0x1eff')})[_0x47f876('0xa44')][_0x47f876('0x1166')](function(_0x161bc5){_0x2e00cd(_0x161bc5);})[_0x47f876('0x1a80')](function(_0x4b4023){_0x3ded63(_0x4b4023);});});}function _0x43a825(_0x2d0200){return _0x398c92(function(_0xce6584,_0x4f7a8a){const _0x2ee44d=a0_0x3f2c;_0x2cfb05()[_0x2ee44d('0x1081')](_0x2d0200)?_0xce6584():_0xb50ea8[_0x2ee44d('0x1d96')][_0x2ee44d('0x275c')]({'id':_0x55c4b9[_0x2ee44d('0x1d96')]['id'],'ids':_0x2cfb05()[_0x2ee44d('0x2563')](_0x2d0200,'id')})[_0x2ee44d('0xa44')]['then'](function(){_0xce6584();})[_0x2ee44d('0x1a80')](function(_0x2c08eb){_0x4f7a8a(_0x2c08eb);});});}function _0x9fc2f2(_0x1f7856){return _0x398c92(function(_0xaf311c,_0x1afdfb){const _0x39cad3=a0_0x3f2c;_0x2cfb05()[_0x39cad3('0x1081')](_0x1f7856)?_0xaf311c():_0xb50ea8['voicePrefix'][_0x39cad3('0x269d')]({'id':_0x55c4b9[_0x39cad3('0x1d96')]['id'],'ids':_0x2cfb05()['map'](_0x1f7856,'id')})[_0x39cad3('0xa44')][_0x39cad3('0x1166')](function(){_0xaf311c();})[_0x39cad3('0x1a80')](function(_0x35ac48){_0x1afdfb(_0x35ac48);});});}function _0x1cdabf(){const _0x96f87c=_0x4004d5,_0x39f4c3=_0x2cfb05()[_0x96f87c('0x24ac')](_0x55c4b9[_0x96f87c('0x2781')],_0x55c4b9[_0x96f87c('0x18e1')],'id'),_0x15ec94=_0x2cfb05()[_0x96f87c('0x24ac')](_0x55c4b9['selectedItems'],_0x55c4b9['startingSelectedItems'],'id');return _0x9fc2f2(_0x39f4c3)[_0x96f87c('0x1166')](function(){return _0x43a825(_0x15ec94);})[_0x96f87c('0x1166')](function(){const _0x34dab3=_0x96f87c;_0x55c4b9[_0x34dab3('0x14d7')]=![],_0x55c4b9[_0x34dab3('0x2111')]=angular[_0x34dab3('0x225f')](_0x55c4b9[_0x34dab3('0x10ab')]),_0x55c4b9[_0x34dab3('0x2781')]=angular[_0x34dab3('0x225f')](_0x55c4b9[_0x34dab3('0x18e1')]),_0x30238a[_0x34dab3('0x103b')]({'title':_0x34dab3('0x983'),'msg':_0x34dab3('0x1673')});})['catch'](function(_0x467636){const _0x4bc400=_0x96f87c;_0x30238a[_0x4bc400('0xfc9')]({'title':_0x467636['status']?_0x4bc400('0x1e21')+_0x467636['status']+_0x4bc400('0x11e1')+_0x467636[_0x4bc400('0xe1b')]:_0x4bc400('0x1b29'),'msg':_0x467636[_0x4bc400('0x52d')]?JSON[_0x4bc400('0xbac')](_0x467636['data']):_0x467636[_0x4bc400('0x1586')]()});});}function _0x5d625a(){_0x451fe5['hide']();}}const _0x59115b=_0x1c8741,_0x2618a6=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/voicePrefixes/create/dialog.html/dialog.html',_0x25b1c0=_0x2734b2['p']+_0x36e6f4('0x1b2e');_0x1954ec[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'voicePrefixes','userProfile',_0x36e6f4('0x17aa'),'api','msUtils','toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x1954ec(_0x435407,_0x19bff2,_0x27ae88,_0x5582d8,_0x321246,_0x5ec854,_0x115209,_0x5e9fd6,_0x3f1eec,_0x2cc0eb,_0x233363,_0x4cdd98,_0x1bdf08,_0xd696c3,_0xf0931e,_0x5c88ef,_0xd3f17c){const _0x3153bf=_0x36e6f4,_0x340158=this;_0x340158[_0x3153bf('0x5c9')]=_0x5c88ef,_0x340158[_0x3153bf('0xf8a')]=_0xd3f17c,_0x340158[_0x3153bf('0x98')]=_0xf0931e[_0x3153bf('0x26cd')](),_0x340158[_0x3153bf('0x25d3')]=_0x3f1eec||{'count':0x0,'rows':[]},_0x340158[_0x3153bf('0x7f')]=_0x2cc0eb,_0x340158['userProfileSection']=_0x233363&&_0x233363[_0x3153bf('0x240f')]==0x1?_0x233363['rows'][0x0]:null,_0x340158[_0x3153bf('0x243c')]=_0xf0931e[_0x3153bf('0xd87')](_0x340158[_0x3153bf('0x17aa')]?_0x340158['userProfileSection']['crudPermissions']:null),_0x340158[_0x3153bf('0x916')]=_0x3153bf('0x25d3'),_0x340158[_0x3153bf('0xef5')]='',_0x340158[_0x3153bf('0x104c')]=null,_0x340158[_0x3153bf('0x26c7')]=[],_0x340158[_0x3153bf('0x2218')]={'fields':_0x3153bf('0x14fc'),'limit':0xa,'page':0x1},_0x340158[_0x3153bf('0x1f8e')]=_0x4e607f,_0x340158[_0x3153bf('0x1728')]=_0xa75685,_0x340158['deleteconfirm']=_0x4f31a8,_0x340158[_0x3153bf('0x103b')]=_0x4fbac3,_0x340158['getVoicePrefixes']=_0x4de56c,_0x340158[_0x3153bf('0x1215')]=_0x2aeda7,_0x340158['deletevoicePrefix']=_0x3c343a,_0x340158['exportSelectedVoicePrefixes']=_0x197388,_0x340158['deleteSelectedVoicePrefixes']=_0x3ee0c2,_0x340158[_0x3153bf('0x624')]=_0x2e047e,_0x340158[_0x3153bf('0x28e0')]=_0x1a5fec,_0xf0931e[_0x3153bf('0x1ac6')](_0x3153bf('0xa7c'))?_0x4cdd98[_0x3153bf('0x1deb')][_0x3153bf('0xd83')]({'fields':_0x3153bf('0x27bd'),'type':_0x3153bf('0x587'),'VoiceExtensionId':_0x3153bf('0x15d7'),'nolimit':'true'})[_0x3153bf('0xa44')][_0x3153bf('0x1166')](function(_0x4b0d2e){const _0x1e796e=_0x3153bf;_0x340158['outboundRoutes']=_0x4b0d2e[_0x1e796e('0x269a')]||[];})[_0x3153bf('0x1a80')](function(_0x26aa8e){const _0x590fd6=_0x3153bf;_0xd696c3[_0x590fd6('0xfc9')]({'title':_0x26aa8e[_0x590fd6('0x52d')]?_0x590fd6('0x1e21')+_0x26aa8e[_0x590fd6('0x52d')]+_0x590fd6('0x11e1')+_0x26aa8e[_0x590fd6('0xe1b')]:_0x590fd6('0x261f'),'msg':_0x26aa8e[_0x590fd6('0x25f4')]?JSON[_0x590fd6('0xbac')](_0x26aa8e['data']):_0x26aa8e[_0x590fd6('0x1586')]()});}):_0x4cdd98[_0x3153bf('0x1deb')][_0x3153bf('0xd83')]({'fields':_0x3153bf('0x27bd'),'type':_0x3153bf('0x587'),'VoiceExtensionId':_0x3153bf('0x15d7'),'nolimit':_0x3153bf('0xf3b')})[_0x3153bf('0xa44')][_0x3153bf('0x1166')](function(_0x12f233){const _0x5a2447=_0x3153bf;_0x340158['outboundRoutes']=_0x12f233[_0x5a2447('0x269a')]||[];})[_0x3153bf('0x1166')](function(){const _0x3925b7=_0x3153bf;return _0x4cdd98[_0x3925b7('0x17aa')][_0x3925b7('0xd83')]({'userProfileId':_0x340158[_0x3925b7('0x98')][_0x3925b7('0xb86')],'sectionId':0x193})['$promise'];})['then'](function(_0xccbc00){const _0x3b3134=_0x3153bf,_0x10afdc=_0xccbc00&&_0xccbc00[_0x3b3134('0x269a')]?_0xccbc00[_0x3b3134('0x269a')][0x0]:null;if(!_0x10afdc){const _0xdbfd1d=[];let _0x49f026=null;_0x340158['voicePrefix']&&(_0x49f026=_0x2cfb05()[_0x3b3134('0xc38')](_0x340158[_0x3b3134('0x2404')],{'id':Number(_0x340158[_0x3b3134('0x1d96')][_0x3b3134('0xa51')])}));for(let _0x2be3b8=0x0;_0x2be3b8<_0x340158[_0x3b3134('0x2404')][_0x3b3134('0x264b')];_0x2be3b8++){_0x49f026&&_0x340158['outboundRoutes'][_0x2be3b8]['id']===_0x49f026['id']&&(_0x340158[_0x3b3134('0x2404')][_0x2be3b8][_0x3b3134('0x2378')]=![],_0xdbfd1d['push'](_0x340158['outboundRoutes'][_0x2be3b8]));}_0x340158[_0x3b3134('0x2404')]=_0xdbfd1d;}else{if(!_0x10afdc[_0x3b3134('0x1a2b')])return _0x4cdd98[_0x3b3134('0x4b5')]['get']({'sectionId':_0x10afdc['id']})[_0x3b3134('0xa44')][_0x3b3134('0x1166')](function(_0x47462d){const _0xa0efdb=_0x3b3134,_0x430fb5=_0x2cfb05()[_0xa0efdb('0x2563')](_0x47462d[_0xa0efdb('0x269a')],function(_0x3a9d22){const _0x53ca1a=_0xa0efdb;return _0x2cfb05()[_0x53ca1a('0xc38')](_0x340158[_0x53ca1a('0x2404')],{'id':_0x3a9d22[_0x53ca1a('0x24e8')]});});let _0x149769=null;_0x340158['voicePrefix']&&(_0x149769=_0x2cfb05()[_0xa0efdb('0xc38')](_0x340158[_0xa0efdb('0x2404')],{'id':Number(_0x340158[_0xa0efdb('0x1d96')][_0xa0efdb('0xa51')])}));if(_0x149769&&!_0x2cfb05()[_0xa0efdb('0x1798')](_0x430fb5,['id',_0x149769['id']])){const _0x1e4e58=_0x2cfb05()[_0xa0efdb('0xc38')](_0x340158[_0xa0efdb('0x2404')],{'id':_0x149769['id']});_0x1e4e58['canSelect']=![],_0x430fb5[_0xa0efdb('0x1514')](_0x1e4e58);}_0x340158[_0xa0efdb('0x2404')]=_0x430fb5;});}})[_0x3153bf('0x1a80')](function(_0x56ddc0){const _0x3c7b4a=_0x3153bf;_0xd696c3[_0x3c7b4a('0xfc9')]({'title':_0x56ddc0[_0x3c7b4a('0x52d')]?_0x3c7b4a('0x1e21')+_0x56ddc0[_0x3c7b4a('0x52d')]+_0x3c7b4a('0x11e1')+_0x56ddc0[_0x3c7b4a('0xe1b')]:_0x3c7b4a('0x2764'),'msg':_0x56ddc0[_0x3c7b4a('0x25f4')]?JSON['stringify'](_0x56ddc0[_0x3c7b4a('0x25f4')]):_0x56ddc0[_0x3c7b4a('0x1586')]()});});function _0x4e607f(_0x32aefb,_0xae1461){const _0x160c57=_0x3153bf;_0x321246['show']({'controller':_0x160c57('0x228'),'controllerAs':'vm','templateUrl':_0x2618a6,'parent':angular[_0x160c57('0x1194')](_0x5ec854[_0x160c57('0x8d2')]),'targetEvent':_0xae1461,'clickOutsideToClose':!![],'locals':{'voicePrefix':_0x32aefb,'voicePrefixes':_0x340158['voicePrefixes'][_0x160c57('0x269a')],'license':_0x340158['license'],'setting':null,'crudPermissions':_0x340158[_0x160c57('0x243c')]}});}function _0xa75685(_0x2bd43f,_0x14538d){const _0x15ae45=_0x3153bf;_0x321246['show']({'controller':'voicePrefixagentaddController','controllerAs':'vm','templateUrl':_0x25b1c0,'parent':angular[_0x15ae45('0x1194')](_0x5ec854[_0x15ae45('0x8d2')]),'targetEvent':_0x14538d,'clickOutsideToClose':!![],'locals':{'voicePrefix':_0x2bd43f,'voicePrefixes':_0x340158[_0x15ae45('0x25d3')]?_0x340158[_0x15ae45('0x25d3')]['rows']:[],'crudPermissions':_0x340158[_0x15ae45('0x243c')],'realtime':![]}});}function _0x4f31a8(_0x356c79,_0x3efd79){const _0x4e6a4b=_0x3153bf,_0x3d4d58=_0x321246[_0x4e6a4b('0x1d26')]()[_0x4e6a4b('0xcdc')](_0x4e6a4b('0x288d')+_0x2cfb05()[_0x4e6a4b('0xb35')](_0x4e6a4b('0x1d96'))+'?')[_0x4e6a4b('0xf3c')](_0x4e6a4b('0x12b5')+(_0x356c79[_0x4e6a4b('0x4f0')]||'voicePrefix')+_0x4e6a4b('0xace')+'\x20will\x20be\x20deleted.')[_0x4e6a4b('0x8e8')](_0x4e6a4b('0xdf5'))['targetEvent'](_0x3efd79)['ok']('OK')[_0x4e6a4b('0x3f')](_0x4e6a4b('0x2d3'));_0x321246[_0x4e6a4b('0x1f80')](_0x3d4d58)['then'](function(){_0x3c343a(_0x356c79);},function(){const _0x4f8c24=_0x4e6a4b;console[_0x4f8c24('0x455')](_0x4f8c24('0x2d3'));});}let _0x129329=!![],_0x5e21ca=0x1;_0x435407[_0x3153bf('0xe83')]('vm.query.filter',function(_0x15dee1,_0x53a30b){const _0xc9c0b4=_0x3153bf;_0x129329?_0x115209(function(){_0x129329=![];}):(!_0x53a30b&&(_0x5e21ca=_0x340158[_0xc9c0b4('0x2218')][_0xc9c0b4('0x1a43')]),_0x15dee1!==_0x53a30b&&(_0x340158['query'][_0xc9c0b4('0x1a43')]=0x1),!_0x15dee1&&(_0x340158[_0xc9c0b4('0x2218')][_0xc9c0b4('0x1a43')]=_0x5e21ca),_0x340158[_0xc9c0b4('0x10b2')]());});function _0x4fbac3(_0x44ba33){const _0x4dc53b=_0x3153bf;_0x340158[_0x4dc53b('0x25d3')]=_0x44ba33||{'count':0x0,'rows':[]};}function _0x4de56c(){const _0x459205=_0x3153bf;_0x340158['query']['offset']=(_0x340158[_0x459205('0x2218')][_0x459205('0x1a43')]-0x1)*_0x340158['query']['limit'],_0xf0931e[_0x459205('0x1ac6')](_0x459205('0xa7c'))?_0x340158[_0x459205('0x1f48')]=_0x4cdd98[_0x459205('0x1d96')][_0x459205('0xd83')](_0x340158[_0x459205('0x2218')],_0x4fbac3)[_0x459205('0xa44')]:(_0x340158['query']['id']=_0x340158[_0x459205('0x7f')]['id'],_0x340158['query'][_0x459205('0xe60')]=_0x459205('0x2385'),_0x340158[_0x459205('0x1f48')]=_0x4cdd98['userProfile']['getResources'](_0x340158['query'],_0x4fbac3)['$promise']);}function _0x2aeda7(_0x3d0519,_0x1d4f9d){const _0x59e48a=_0x3153bf;_0x321246[_0x59e48a('0x1f80')]({'controller':_0x59e48a('0x228'),'controllerAs':'vm','templateUrl':_0x2618a6,'parent':angular[_0x59e48a('0x1194')](_0x5ec854['body']),'targetEvent':_0x3d0519,'clickOutsideToClose':!![],'locals':{'voicePrefix':_0x1d4f9d,'voicePrefixes':_0x340158['voicePrefixes']['rows'],'license':_0x340158['license'],'setting':_0x340158[_0x59e48a('0xf8a')],'crudPermissions':_0x340158[_0x59e48a('0x243c')]}});}function _0x3c343a(_0x16825a){const _0x334427=_0x3153bf;_0x4cdd98['voicePrefix'][_0x334427('0x906')]({'id':_0x16825a['id']})[_0x334427('0xa44')][_0x334427('0x1166')](function(){const _0x108204=_0x334427;_0x2cfb05()['remove'](_0x340158[_0x108204('0x25d3')][_0x108204('0x269a')],{'id':_0x16825a['id']}),_0x340158[_0x108204('0x25d3')][_0x108204('0x240f')]-=0x1,!_0x340158['voicePrefixes'][_0x108204('0x269a')][_0x108204('0x264b')]&&_0x340158['getVoicePrefixes'](),_0xd696c3[_0x108204('0x103b')]({'title':_0x2cfb05()['startCase'](_0x108204('0x1d96'))+_0x108204('0x2b6'),'msg':_0x16825a[_0x108204('0x4f0')]?_0x16825a[_0x108204('0x4f0')]+_0x108204('0x7cd'):''});})[_0x334427('0x1a80')](function(_0xe6f5c1){const _0x400f20=_0x334427;if(_0xe6f5c1[_0x400f20('0x25f4')]&&_0xe6f5c1['data'][_0x400f20('0x61a')]&&_0xe6f5c1['data'][_0x400f20('0x61a')][_0x400f20('0x264b')]){_0x340158[_0x400f20('0x61a')]=_0xe6f5c1[_0x400f20('0x25f4')][_0x400f20('0x61a')]||[{'message':_0xe6f5c1[_0x400f20('0x1586')](),'type':'SYSTEM:DELETEvoicePrefix'}];for(let _0x630abf=0x0;_0x630abf<_0xe6f5c1[_0x400f20('0x25f4')][_0x400f20('0x61a')][_0x400f20('0x264b')];_0x630abf++){_0xd696c3['error']({'title':_0xe6f5c1[_0x400f20('0x25f4')][_0x400f20('0x61a')][_0x630abf][_0x400f20('0x1345')],'msg':_0xe6f5c1['data']['errors'][_0x630abf][_0x400f20('0x1e70')]});}}else _0xd696c3[_0x400f20('0xfc9')]({'title':_0xe6f5c1[_0x400f20('0x52d')]?_0x400f20('0x1e21')+_0xe6f5c1[_0x400f20('0x52d')]+_0x400f20('0x11e1')+_0xe6f5c1[_0x400f20('0xe1b')]:_0x400f20('0x726'),'msg':_0xe6f5c1[_0x400f20('0x25f4')]?JSON[_0x400f20('0xbac')](_0xe6f5c1[_0x400f20('0x25f4')][_0x400f20('0x1e70')]):_0xe6f5c1[_0x400f20('0x1e70')]||_0xe6f5c1['toString']()});});}function _0x197388(){const _0x30bc5e=_0x3153bf,_0x307502=angular['copy'](_0x340158[_0x30bc5e('0x26c7')]);return _0x340158['selectedVoicePrefixes']=[],_0x307502;}function _0x3ee0c2(_0x3affd5){const _0x8edb20=_0x3153bf,_0x2ad189=_0x321246['confirm']()[_0x8edb20('0xcdc')](_0x8edb20('0x17f5'))['htmlContent'](_0x8edb20('0x12b5')+_0x340158[_0x8edb20('0x26c7')][_0x8edb20('0x264b')]+_0x8edb20('0x196d')+'\x20will\x20be\x20deleted.')[_0x8edb20('0x8e8')]('delete\x20voicePrefixs')[_0x8edb20('0x203b')](_0x3affd5)['ok']('OK')[_0x8edb20('0x3f')](_0x8edb20('0x2d3'));_0x321246['show'](_0x2ad189)[_0x8edb20('0x1166')](function(){const _0x3328db=_0x8edb20;_0x340158[_0x3328db('0x26c7')][_0x3328db('0x2782')](function(_0x53895d){_0x3c343a(_0x53895d);}),_0x340158[_0x3328db('0x26c7')]=[];});}function _0x2e047e(){const _0x38d801=_0x3153bf;_0x340158[_0x38d801('0x26c7')]=[];}function _0x1a5fec(){const _0x15adb5=_0x3153bf;_0x340158['selectedVoicePrefixes']=_0x340158[_0x15adb5('0x25d3')]['rows'];}}const _0x2e522a=_0x1954ec;_0x1d7fc1['$inject']=['$scope',_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),'voiceQueues','voiceQueue',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x1d7fc1(_0x30a088,_0xa7460f,_0x6de59e,_0x1ff93e,_0x3c4405,_0x36cd44,_0x5f87d5,_0x4fa8f5,_0x24b71b,_0x58fd67,_0x441502,_0x310f2,_0x56ebd4,_0x167a70){const _0x23d701=_0x36e6f4,_0x1b1a07=this;_0x1b1a07['currentUser']=_0x441502['getCurrentUser'](),_0x1b1a07[_0x23d701('0x61a')]=[],_0x1b1a07[_0x23d701('0xf8a')]=_0x56ebd4,_0x1b1a07['license']=_0x310f2,_0x1b1a07[_0x23d701('0x243c')]=_0x167a70,_0x1b1a07[_0x23d701('0x128b')]={},_0x1b1a07[_0x23d701('0x2900')]=_0x1b1a07[_0x23d701('0xf8a')]&&_0x1b1a07[_0x23d701('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1b1a07[_0x23d701('0xcdc')]='VOICE.EDIT_VOICEQUEUE',_0x1b1a07[_0x23d701('0x1943')]=angular[_0x23d701('0x225f')](_0x24b71b),_0x1b1a07[_0x23d701('0x20fd')]=_0x4fa8f5,_0x1b1a07[_0x23d701('0xca6')]=![];!_0x1b1a07[_0x23d701('0x1943')]&&(_0x1b1a07[_0x23d701('0x1943')]={'type':'inbound','strategy':_0x23d701('0x194b'),'timeout':0xf,'retry':0x2,'random_periodic_announce':'no','announce_holdtime':'no','announce_position':'no','reportholdtime':'no','autopause':'no','ringinuse':'no','timeoutrestart':'no','setinterfacevar':'no','setqueuevar':'no','setqueueentryvar':'no'},_0x1b1a07[_0x23d701('0xcdc')]=_0x23d701('0x12f4'),_0x1b1a07[_0x23d701('0xca6')]=!![]);_0x1b1a07['addNewVoiceQueue']=_0x417bfe,_0x1b1a07[_0x23d701('0x902')]=_0x4ea07a,_0x1b1a07[_0x23d701('0x2a9')]=_0x5f5d0e,_0x1b1a07[_0x23d701('0x1a9c')]=_0x362b74,_0x1b1a07[_0x23d701('0x24a0')]=_0x3dce4a;function _0x417bfe(){const _0x29b65=_0x23d701;_0x1b1a07[_0x29b65('0x61a')]=[],_0x58fd67[_0x29b65('0x1943')][_0x29b65('0x9cc')](_0x1b1a07[_0x29b65('0x1943')])[_0x29b65('0xa44')][_0x29b65('0x1166')](function(_0x35b2aa){const _0x53a573=_0x29b65;_0x1b1a07[_0x53a573('0x20fd')][_0x53a573('0x2450')](_0x35b2aa['toJSON']()),_0x5f87d5[_0x53a573('0x103b')]({'title':_0x53a573('0x1937'),'msg':_0x1b1a07[_0x53a573('0x1943')][_0x53a573('0x4f0')]?_0x1b1a07[_0x53a573('0x1943')][_0x53a573('0x4f0')]+_0x53a573('0x1eda'):''}),_0x3dce4a(_0x35b2aa);})[_0x29b65('0x1a80')](function(_0x49fcf8){const _0x1b0f3a=_0x29b65;if(_0x49fcf8['data']&&_0x49fcf8[_0x1b0f3a('0x25f4')]['errors']&&_0x49fcf8['data'][_0x1b0f3a('0x61a')]['length']){_0x1b1a07[_0x1b0f3a('0x61a')]=_0x49fcf8[_0x1b0f3a('0x25f4')][_0x1b0f3a('0x61a')]||[{'message':_0x49fcf8['toString'](),'type':_0x1b0f3a('0x14ca')}];for(let _0x3f1066=0x0;_0x3f1066<_0x49fcf8[_0x1b0f3a('0x25f4')][_0x1b0f3a('0x61a')][_0x1b0f3a('0x264b')];_0x3f1066+=0x1){_0x5f87d5[_0x1b0f3a('0xfc9')]({'title':_0x49fcf8['data'][_0x1b0f3a('0x61a')][_0x3f1066][_0x1b0f3a('0x1345')],'msg':_0x49fcf8[_0x1b0f3a('0x25f4')][_0x1b0f3a('0x61a')][_0x3f1066][_0x1b0f3a('0x1e70')]});}}else _0x5f87d5[_0x1b0f3a('0xfc9')]({'title':_0x49fcf8[_0x1b0f3a('0x52d')]?'API:'+_0x49fcf8[_0x1b0f3a('0x52d')]+'\x20-\x20'+_0x49fcf8[_0x1b0f3a('0xe1b')]:_0x1b0f3a('0x14ca'),'msg':_0x49fcf8[_0x1b0f3a('0x25f4')]?JSON['stringify'](_0x49fcf8[_0x1b0f3a('0x25f4')]['message']):_0x49fcf8[_0x1b0f3a('0x1586')]()});});}function _0x4ea07a(){const _0x1cb492=_0x23d701;_0x1b1a07[_0x1cb492('0x61a')]=[],_0x58fd67[_0x1cb492('0x1943')]['update']({'id':_0x1b1a07[_0x1cb492('0x1943')]['id']},_0x1b1a07[_0x1cb492('0x1943')])[_0x1cb492('0xa44')][_0x1cb492('0x1166')](function(_0x77d078){const _0xec46ae=_0x1cb492,_0x29683a=_0x2cfb05()[_0xec46ae('0xc38')](_0x1b1a07['voiceQueues'],{'id':_0x77d078['id']});_0x29683a&&_0x2cfb05()['merge'](_0x29683a,_0x2cfb05()[_0xec46ae('0x1a08')](_0x77d078[_0xec46ae('0x2876')](),_0x2cfb05()[_0xec46ae('0x14a4')](_0x29683a))),_0x5f87d5[_0xec46ae('0x103b')]({'title':'VoiceQueue\x20properly\x20saved!','msg':_0x1b1a07[_0xec46ae('0x1943')][_0xec46ae('0x4f0')]?_0x1b1a07[_0xec46ae('0x1943')][_0xec46ae('0x4f0')]+_0xec46ae('0x7d'):''}),_0x3dce4a(_0x77d078);})['catch'](function(_0x558291){const _0x140d58=_0x1cb492;if(_0x558291[_0x140d58('0x25f4')]&&_0x558291[_0x140d58('0x25f4')][_0x140d58('0x61a')]&&_0x558291[_0x140d58('0x25f4')][_0x140d58('0x61a')]['length']){_0x1b1a07[_0x140d58('0x61a')]=_0x558291[_0x140d58('0x25f4')][_0x140d58('0x61a')]||[{'message':_0x558291['toString'](),'type':_0x140d58('0x1aed')}];for(let _0x495505=0x0;_0x495505<_0x558291[_0x140d58('0x25f4')][_0x140d58('0x61a')]['length'];_0x495505++){_0x5f87d5[_0x140d58('0xfc9')]({'title':_0x558291[_0x140d58('0x25f4')]['errors'][_0x495505][_0x140d58('0x1345')],'msg':_0x558291[_0x140d58('0x25f4')][_0x140d58('0x61a')][_0x495505][_0x140d58('0x1e70')]});}}else _0x5f87d5[_0x140d58('0xfc9')]({'title':_0x558291[_0x140d58('0x52d')]?_0x140d58('0x1e21')+_0x558291['status']+_0x140d58('0x11e1')+_0x558291['statusText']:_0x140d58('0x1aed'),'msg':_0x558291[_0x140d58('0x25f4')]?JSON['stringify'](_0x558291['data']['message']):_0x558291[_0x140d58('0x1586')]()});});}function _0x5f5d0e(_0x2651ec){const _0x1a7d03=_0x23d701;_0x1b1a07[_0x1a7d03('0x61a')]=[];const _0x28ed3c=_0x1ff93e[_0x1a7d03('0x1d26')]()['title'](_0x1a7d03('0x7fb'))['content'](_0x1a7d03('0x119f'))[_0x1a7d03('0x8e8')](_0x1a7d03('0x456'))['ok']('Delete')[_0x1a7d03('0x3f')](_0x1a7d03('0x497'))['targetEvent'](_0x2651ec);_0x1ff93e[_0x1a7d03('0x1f80')](_0x28ed3c)[_0x1a7d03('0x1166')](function(){const _0x57c775=_0x1a7d03;_0x58fd67['voiceQueue'][_0x57c775('0x906')]({'id':_0x1b1a07[_0x57c775('0x1943')]['id']})[_0x57c775('0xa44')][_0x57c775('0x1166')](function(){const _0x257cea=_0x57c775;_0x2cfb05()[_0x257cea('0x127f')](_0x1b1a07[_0x257cea('0x20fd')],{'id':_0x1b1a07[_0x257cea('0x1943')]['id']}),_0x5f87d5[_0x257cea('0x103b')]({'title':_0x257cea('0xd76'),'msg':(_0x1b1a07[_0x257cea('0x1943')][_0x257cea('0x4f0')]||_0x257cea('0x1943'))+_0x257cea('0x7cd')}),_0x3dce4a(_0x1b1a07[_0x257cea('0x1943')]);})['catch'](function(_0x40468f){const _0x54f5ce=_0x57c775;if(_0x40468f['data']&&_0x40468f[_0x54f5ce('0x25f4')]['errors']&&_0x40468f['data'][_0x54f5ce('0x61a')][_0x54f5ce('0x264b')]){_0x1b1a07[_0x54f5ce('0x61a')]=_0x40468f['data']['errors']||[{'message':_0x40468f[_0x54f5ce('0x1586')](),'type':_0x54f5ce('0x221d')}];for(let _0x5022ef=0x0;_0x5022ef<_0x40468f[_0x54f5ce('0x25f4')][_0x54f5ce('0x61a')][_0x54f5ce('0x264b')];_0x5022ef++){_0x5f87d5[_0x54f5ce('0xfc9')]({'title':_0x40468f['data']['errors'][_0x5022ef][_0x54f5ce('0x1345')],'msg':_0x40468f[_0x54f5ce('0x25f4')][_0x54f5ce('0x61a')][_0x5022ef]['message']});}}else _0x5f87d5[_0x54f5ce('0xfc9')]({'title':_0x40468f[_0x54f5ce('0x52d')]?_0x54f5ce('0x1e21')+_0x40468f[_0x54f5ce('0x52d')]+'\x20-\x20'+_0x40468f[_0x54f5ce('0xe1b')]:_0x54f5ce('0x221d'),'msg':_0x40468f[_0x54f5ce('0x25f4')]?JSON['stringify'](_0x40468f[_0x54f5ce('0x25f4')][_0x54f5ce('0x1e70')]):_0x40468f[_0x54f5ce('0x1e70')]||_0x40468f[_0x54f5ce('0x1586')]()});});},function(){});}function _0x362b74(_0x7507bf){return _0x7507bf===null?undefined:new Date(_0x7507bf);}function _0x3dce4a(_0x19e927){const _0x439d93=_0x23d701;_0x1ff93e[_0x439d93('0x1197')](_0x19e927);}}const _0x53df2c=_0x1d7fc1;_0x17584e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1943'),_0x36e6f4('0x20fd'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),'Auth','crudPermissions'];function _0x17584e(_0x29d92e,_0xab05ce,_0x101aaa,_0x4cad34,_0x409084,_0x6a4624,_0x493170,_0x2438e8,_0x578c58,_0x3a3975){const _0x4c270e=_0x36e6f4,_0xae3979=this;_0xae3979[_0x4c270e('0x98')]=_0x578c58[_0x4c270e('0x26cd')](),_0xae3979[_0x4c270e('0x1943')]=_0x409084,_0xae3979[_0x4c270e('0x243c')]=_0x3a3975,_0xae3979['penalty']=0x0,_0xae3979['realtime']=_0x493170,_0xae3979[_0x4c270e('0xbd7')]=[],_0xae3979['allowedItems']=[],_0xae3979['selectedItems']=[],_0xae3979[_0x4c270e('0x2111')]=[],_0xae3979[_0x4c270e('0x2781')]=[],_0xae3979[_0x4c270e('0x14d7')]=![],_0xae3979[_0x4c270e('0xae0')]=_0x54cf3a,_0xae3979[_0x4c270e('0x1d92')]=_0x3a8e8a,_0xae3979[_0x4c270e('0x24a0')]=_0x40a312,_0xae3979['dualMultiselectOptions']={'readOnly':!_0xae3979[_0x4c270e('0x243c')][_0x4c270e('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x4c270e('0x6e1'),'line2':[_0x4c270e('0x4f0'),_0x4c270e('0x1eef')],'line3':_0x4c270e('0x23af'),'labelAll':_0x2438e8['instant'](_0x4c270e('0x3ac')),'labelSelected':_0x2438e8[_0x4c270e('0x25cc')]('VOICE.SELECTED_AGENTS'),'transferCallback':function(_0x5cb807,_0x471077){const _0x56facf=_0x4c270e;_0x471077?_0x5cb807[_0x56facf('0x2782')](function(_0xbdb004){const _0x267b26=_0x56facf;_0xbdb004[_0x267b26('0x23af')]=undefined;}):_0x5cb807[_0x56facf('0x2782')](function(_0x1fcaa7){const _0x305d52=_0x56facf;_0x1fcaa7[_0x305d52('0x23af')]=_0x305d52('0x11e8')+_0xae3979[_0x305d52('0x23af')];});const _0x2eb771=_0x2cfb05()['xorWith'](_0xae3979[_0x56facf('0x2781')],_0xae3979[_0x56facf('0x18e1')],function(_0x53e86d,_0x52ac60){const _0x333ac3=_0x56facf;return _0x53e86d['id']===_0x52ac60['id']&&_0x53e86d['penalty']===_0x52ac60[_0x333ac3('0x23af')];});_0xae3979[_0x56facf('0x14d7')]=_0x2cfb05()['isEmpty'](_0x2eb771)?![]:!![];}};function _0x54cf3a(){const _0x432ac6=_0x4c270e;return _0x578c58['hasRole'](_0x432ac6('0xa7c'))?_0x3f7998()[_0x432ac6('0x1a80')](function(_0x3d6b3d){const _0xef6a33=_0x432ac6;_0x101aaa[_0xef6a33('0xfc9')]({'title':_0x3d6b3d[_0xef6a33('0x52d')]?'API:'+_0x3d6b3d[_0xef6a33('0x52d')]+'\x20-\x20'+_0x3d6b3d[_0xef6a33('0xe1b')]:'SYSTEM:GET_AGENTS','msg':_0x3d6b3d[_0xef6a33('0x52d')]?JSON[_0xef6a33('0xbac')](_0x3d6b3d[_0xef6a33('0x25f4')]):_0x3d6b3d[_0xef6a33('0x1586')]()});}):_0x350e5f()[_0x432ac6('0x1166')](function(_0x4c82c0){const _0x2d7944=_0x432ac6;return _0xae3979[_0x2d7944('0xe60')]=_0x4c82c0,_0x3f7998();})[_0x432ac6('0x1a80')](function(_0x1c420f){const _0xff694=_0x432ac6;_0x101aaa[_0xff694('0xfc9')]({'title':_0x1c420f['status']?'API:'+_0x1c420f['status']+_0xff694('0x11e1')+_0x1c420f[_0xff694('0xe1b')]:_0xff694('0xd4c'),'msg':_0x1c420f[_0xff694('0x52d')]?JSON['stringify'](_0x1c420f[_0xff694('0x25f4')]):_0x1c420f[_0xff694('0x1586')]()});});}function _0x350e5f(){return _0xab05ce(function(_0x4d76b9,_0x4d3476){const _0x461aa9=a0_0x3f2c;_0x4cad34[_0x461aa9('0x17aa')][_0x461aa9('0xd83')]({'userProfileId':_0xae3979[_0x461aa9('0x98')][_0x461aa9('0xb86')],'name':'Agents'})[_0x461aa9('0xa44')]['then'](function(_0x3530cc){const _0x327db7=_0x461aa9,_0x3cc648=_0x3530cc&&_0x3530cc['rows']?_0x3530cc[_0x327db7('0x269a')][0x0]:null;_0x4d76b9(_0x3cc648);})['catch'](function(_0x155d09){_0x4d3476(_0x155d09);});});}function _0x3f7998(){return _0xab05ce(function(_0xd01c19,_0x2e0c2f){const _0x90a186=a0_0x3f2c;return _0x24ee85()[_0x90a186('0x1166')](function(_0x52fcff){const _0x24bfd8=_0x90a186;return _0xae3979[_0x24bfd8('0xbd7')]=_0x52fcff[_0x24bfd8('0x269a')]?_0x52fcff['rows']:[],_0x578c58[_0x24bfd8('0x1ac6')](_0x24bfd8('0xa7c'))?_0x52fcff:_0xae3979[_0x24bfd8('0xe60')]?_0xae3979[_0x24bfd8('0xe60')][_0x24bfd8('0x1a2b')]?_0x52fcff:_0x3fb5b9():null;})[_0x90a186('0x1166')](function(_0x532320){const _0x96358=_0x90a186,_0x16e412=_0x532320&&_0x532320[_0x96358('0x269a')]?_0x532320[_0x96358('0x269a')]:[];return _0xae3979[_0x96358('0x10ab')]=_0x2cfb05()[_0x96358('0x2563')](_0x16e412,function(_0x16f3d7){const _0x41fead=_0x96358;return _0x2cfb05()['find'](_0xae3979[_0x41fead('0xbd7')],{'id':_0x578c58[_0x41fead('0x1ac6')](_0x41fead('0xa7c'))||_0xae3979[_0x41fead('0xe60')][_0x41fead('0x1a2b')]?_0x16f3d7['id']:_0x16f3d7[_0x41fead('0x24e8')]});}),_0xae3979[_0x96358('0x2111')]=angular[_0x96358('0x225f')](_0xae3979[_0x96358('0x10ab')]),_0xae3979[_0x96358('0xbd7')]['forEach'](function(_0x307e4c){const _0x4d0562=_0x96358,_0x39fcfe=_0x2cfb05()[_0x4d0562('0xc38')](_0xae3979[_0x4d0562('0x10ab')],{'id':_0x307e4c['id']});_0x578c58['hasRole'](_0x4d0562('0xa7c'))?_0x307e4c[_0x4d0562('0x26ef')]=!![]:_0x307e4c[_0x4d0562('0x26ef')]=typeof _0x39fcfe!==_0x4d0562('0x1048')?!![]:![];}),_0x28d00e();})[_0x90a186('0x1166')](function(_0x3f5d0c){const _0xc3f72f=_0x90a186,_0x1287e0=_0x3f5d0c&&_0x3f5d0c['rows']?_0x3f5d0c[_0xc3f72f('0x269a')]:[];_0xae3979[_0xc3f72f('0x18e1')]=_0x2cfb05()[_0xc3f72f('0x2563')](_0x1287e0,function(_0x13ab3d){const _0x38bb14=_0xc3f72f,_0x2f77f5=_0x2cfb05()[_0x38bb14('0xc38')](_0xae3979['items'],{'id':_0x13ab3d['id']});return _0x2f77f5[_0x38bb14('0x23af')]=_0x13ab3d[_0x38bb14('0x1dcc')]?'penalty\x20'+_0x13ab3d[_0x38bb14('0x1dcc')][_0x38bb14('0x23af')]:'',_0x2f77f5[_0x38bb14('0x1eef')]=typeof _0x13ab3d[_0x38bb14('0x1eef')]!==_0x38bb14('0x1048')?'<'+_0x13ab3d[_0x38bb14('0x1eef')]+'>':'',_0x2f77f5;}),_0xae3979[_0xc3f72f('0x2781')]=angular[_0xc3f72f('0x225f')](_0xae3979[_0xc3f72f('0x18e1')]),_0xae3979[_0xc3f72f('0xc68')][_0xc3f72f('0x18e1')]=_0xae3979[_0xc3f72f('0x18e1')],_0xae3979['dualMultiselectOptions'][_0xc3f72f('0xbd7')]=_0x2cfb05()[_0xc3f72f('0x24ac')](_0xae3979['allowedItems'],_0xae3979[_0xc3f72f('0xc68')][_0xc3f72f('0x18e1')],'id'),_0xd01c19();})[_0x90a186('0x1a80')](function(_0x2d79f5){_0x2e0c2f(_0x2d79f5);});});}function _0x3fb5b9(){return _0xab05ce(function(_0x2bd0da,_0x5272ba){const _0x5d7b0d=a0_0x3f2c;return _0x4cad34[_0x5d7b0d('0x4b5')][_0x5d7b0d('0xd83')]({'sectionId':_0xae3979['section']['id'],'nolimit':!![]})[_0x5d7b0d('0xa44')][_0x5d7b0d('0x1166')](function(_0xd1714f){_0x2bd0da(_0xd1714f);})[_0x5d7b0d('0x1a80')](function(_0x3affad){_0x5272ba(_0x3affad);});});}function _0x28d00e(){return _0xab05ce(function(_0x4ee18c,_0x263ffe){const _0x16b9a9=a0_0x3f2c;return _0x4cad34[_0x16b9a9('0x1943')][_0x16b9a9('0x261c')]({'id':_0xae3979[_0x16b9a9('0x1943')]['id'],'fields':_0x16b9a9('0x1459'),'nolimit':!![],'role':_0x16b9a9('0x1eff')})[_0x16b9a9('0xa44')]['then'](function(_0x1a4aba){_0x4ee18c(_0x1a4aba);})[_0x16b9a9('0x1a80')](function(_0x5b4617){_0x263ffe(_0x5b4617);});});}function _0x24ee85(){return _0xab05ce(function(_0x45bce5,_0x3c10c4){const _0x10aa54=a0_0x3f2c;return _0x4cad34[_0x10aa54('0x557')]['get']({'fields':_0x10aa54('0x1459'),'nolimit':!![],'role':'agent'})['$promise'][_0x10aa54('0x1166')](function(_0x433f80){_0x45bce5(_0x433f80);})['catch'](function(_0x1fd2d2){_0x3c10c4(_0x1fd2d2);});});}function _0x385b63(_0x4a2075){return _0xab05ce(function(_0xebbbb0,_0x54dce8){const _0x59c5c9=a0_0x3f2c;if(_0x2cfb05()[_0x59c5c9('0x1081')](_0x4a2075))_0xebbbb0();else{const _0x2eaa08=[],_0x36867a=_0x2cfb05()[_0x59c5c9('0x1535')](_0x4a2075,_0x59c5c9('0x23af'));for(let _0x517805=0x0;_0x517805'+(_0x38aa3d[_0x598071('0x4f0')]||_0x598071('0x1943'))+_0x598071('0xace')+_0x598071('0x3f3'))[_0x598071('0x8e8')](_0x598071('0x2769'))['targetEvent'](_0x13c783)['ok']('OK')['cancel'](_0x598071('0x2d3'));_0x54ac83['show'](_0x160057)['then'](function(){_0x1a7153(_0x38aa3d);},function(){const _0x344f3d=_0x598071;console[_0x344f3d('0x455')]('CANCEL');});}function _0x58a542(){const _0x1cfa00=_0x527845;if(_0x584491[_0x1cfa00('0x1ac6')]('admin'))_0x4161be['go'](_0x1cfa00('0xde0'),{});else return _0x3d3373[_0x1cfa00('0x17aa')][_0x1cfa00('0xd83')]({'userProfileId':_0x584491['getCurrentUser']()[_0x1cfa00('0xb86')],'sectionId':0x19b})[_0x1cfa00('0xa44')][_0x1cfa00('0x1166')](function(_0xd07e7f){const _0x26d339=_0x1cfa00,_0xfadeb0=_0xd07e7f&&_0xd07e7f[_0x26d339('0x269a')]?_0xd07e7f[_0x26d339('0x269a')][0x0]:null;_0xfadeb0&&_0xfadeb0[_0x26d339('0xc27')]?_0x4161be['go'](_0x26d339('0xde0'),{}):_0x3f4222[_0x26d339('0x1fa1')]({'title':_0x447e23[_0x26d339('0x25cc')](_0x26d339('0x627')),'msg':_0x447e23['instant'](_0x26d339('0x2642'))});})[_0x1cfa00('0x1a80')](function(_0x215eb4){const _0x218cc5=_0x1cfa00;_0x3f4222[_0x218cc5('0xfc9')]({'title':_0x215eb4[_0x218cc5('0x52d')]?'API:'+_0x215eb4[_0x218cc5('0x52d')]+_0x218cc5('0x11e1')+_0x215eb4[_0x218cc5('0xe1b')]:_0x218cc5('0x153e'),'msg':_0x215eb4[_0x218cc5('0x52d')]?JSON['stringify'](_0x215eb4[_0x218cc5('0x25f4')]):_0x215eb4['toString']()});});}let _0x5088fd=!![],_0x2344ee=0x1;_0x4e6709[_0x527845('0xe83')](_0x527845('0x12d8'),function(_0x54fa35,_0x4e8fc4){const _0x6bbb2d=_0x527845;_0x5088fd?_0x79f1b2(function(){_0x5088fd=![];}):(!_0x4e8fc4&&(_0x2344ee=_0x4eb7ef['query'][_0x6bbb2d('0x1a43')]),_0x54fa35!==_0x4e8fc4&&(_0x4eb7ef[_0x6bbb2d('0x2218')]['page']=0x1),!_0x54fa35&&(_0x4eb7ef[_0x6bbb2d('0x2218')][_0x6bbb2d('0x1a43')]=_0x2344ee),_0x4eb7ef[_0x6bbb2d('0x680')]());});function _0xed5188(_0xe590a1){const _0x3dbe0e=_0x527845;_0x4eb7ef[_0x3dbe0e('0x20fd')]=_0xe590a1||{'count':0x0,'rows':[]};}function _0x50dcdb(){const _0xd8dfbb=_0x527845;_0x4eb7ef[_0xd8dfbb('0x2218')][_0xd8dfbb('0x1098')]=(_0x4eb7ef[_0xd8dfbb('0x2218')]['page']-0x1)*_0x4eb7ef[_0xd8dfbb('0x2218')][_0xd8dfbb('0x163f')],_0x584491[_0xd8dfbb('0x1ac6')](_0xd8dfbb('0xa7c'))?_0x4eb7ef[_0xd8dfbb('0x1f48')]=_0x3d3373['voiceQueue'][_0xd8dfbb('0xd83')](_0x4eb7ef[_0xd8dfbb('0x2218')],_0xed5188)[_0xd8dfbb('0xa44')]:(_0x4eb7ef[_0xd8dfbb('0x2218')]['id']=_0x4eb7ef[_0xd8dfbb('0x7f')]['id'],_0x4eb7ef[_0xd8dfbb('0x2218')][_0xd8dfbb('0xe60')]='VoiceQueues',_0x4eb7ef[_0xd8dfbb('0x1f48')]=_0x3d3373[_0xd8dfbb('0x7f')][_0xd8dfbb('0x263a')](_0x4eb7ef['query'],_0xed5188)[_0xd8dfbb('0xa44')]);}function _0x47641e(_0x5a2e84,_0x2064c4){const _0x159481=_0x527845;_0x54ac83['show']({'controller':_0x159481('0x253d'),'controllerAs':'vm','templateUrl':_0x7dc18b,'parent':angular[_0x159481('0x1194')](_0xce83b6['body']),'targetEvent':_0x5a2e84,'clickOutsideToClose':!![],'locals':{'voiceQueue':_0x2064c4,'voiceQueues':_0x4eb7ef[_0x159481('0x20fd')][_0x159481('0x269a')],'license':_0x4eb7ef[_0x159481('0x5c9')],'setting':_0x4eb7ef[_0x159481('0xf8a')],'crudPermissions':_0x4eb7ef[_0x159481('0x243c')]}});}function _0x1a7153(_0x5513e4){const _0x168c5c=_0x527845;_0x3d3373[_0x168c5c('0x1943')][_0x168c5c('0x906')]({'id':_0x5513e4['id']})[_0x168c5c('0xa44')]['then'](function(){const _0x2535cc=_0x168c5c;_0x2cfb05()[_0x2535cc('0x127f')](_0x4eb7ef[_0x2535cc('0x20fd')]['rows'],{'id':_0x5513e4['id']}),_0x4eb7ef['voiceQueues'][_0x2535cc('0x240f')]-=0x1,!_0x4eb7ef[_0x2535cc('0x20fd')][_0x2535cc('0x269a')][_0x2535cc('0x264b')]&&_0x4eb7ef[_0x2535cc('0x680')](),_0x3f4222['success']({'title':_0x2cfb05()[_0x2535cc('0xb35')](_0x2535cc('0x120b'))+_0x2535cc('0x2b6'),'msg':_0x5513e4[_0x2535cc('0x4f0')]?_0x5513e4[_0x2535cc('0x4f0')]+_0x2535cc('0x7cd'):''});})['catch'](function(_0x7cc592){const _0x1b3c4f=_0x168c5c;if(_0x7cc592[_0x1b3c4f('0x25f4')]&&_0x7cc592['data'][_0x1b3c4f('0x61a')]&&_0x7cc592[_0x1b3c4f('0x25f4')]['errors'][_0x1b3c4f('0x264b')]){_0x4eb7ef[_0x1b3c4f('0x61a')]=_0x7cc592[_0x1b3c4f('0x25f4')][_0x1b3c4f('0x61a')]||[{'message':_0x7cc592[_0x1b3c4f('0x1586')](),'type':_0x1b3c4f('0x466')}];for(let _0x5ab697=0x0;_0x5ab697<_0x7cc592['data'][_0x1b3c4f('0x61a')][_0x1b3c4f('0x264b')];_0x5ab697++){_0x3f4222[_0x1b3c4f('0xfc9')]({'title':_0x7cc592['data'][_0x1b3c4f('0x61a')][_0x5ab697][_0x1b3c4f('0x1345')],'msg':_0x7cc592[_0x1b3c4f('0x25f4')][_0x1b3c4f('0x61a')][_0x5ab697]['message']});}}else _0x3f4222['error']({'title':_0x7cc592[_0x1b3c4f('0x52d')]?_0x1b3c4f('0x1e21')+_0x7cc592['status']+_0x1b3c4f('0x11e1')+_0x7cc592[_0x1b3c4f('0xe1b')]:_0x1b3c4f('0x466'),'msg':_0x7cc592[_0x1b3c4f('0x25f4')]?JSON[_0x1b3c4f('0xbac')](_0x7cc592[_0x1b3c4f('0x25f4')][_0x1b3c4f('0x1e70')]):_0x7cc592[_0x1b3c4f('0x1e70')]||_0x7cc592['toString']()});});}function _0x1fe54e(){const _0x37448e=_0x527845,_0x82ae72=angular[_0x37448e('0x225f')](_0x4eb7ef[_0x37448e('0xc2a')]);return _0x4eb7ef['selectedVoiceQueues']=[],_0x82ae72;}function _0x179816(_0x475de9){const _0x5186bb=_0x527845,_0x44f238=_0x54ac83['confirm']()[_0x5186bb('0xcdc')](_0x5186bb('0x2037'))['htmlContent'](_0x5186bb('0x12b5')+_0x4eb7ef['selectedVoiceQueues'][_0x5186bb('0x264b')]+_0x5186bb('0x196d')+_0x5186bb('0x3f3'))['ariaLabel'](_0x5186bb('0xd1d'))[_0x5186bb('0x203b')](_0x475de9)['ok']('OK')['cancel']('CANCEL');_0x54ac83[_0x5186bb('0x1f80')](_0x44f238)[_0x5186bb('0x1166')](function(){const _0x565191=_0x5186bb;_0x4eb7ef['selectedVoiceQueues'][_0x565191('0x2782')](function(_0x4e1de6){_0x1a7153(_0x4e1de6);}),_0x4eb7ef[_0x565191('0xc2a')]=[];});}function _0x5ac130(){const _0x2499b6=_0x527845;_0x4eb7ef[_0x2499b6('0xc2a')]=[];}function _0x207b17(){const _0x33e250=_0x527845;_0x4eb7ef[_0x33e250('0xc2a')]=_0x4eb7ef[_0x33e250('0x20fd')][_0x33e250('0x269a')];}}const _0xe704e=_0x3ef061;_0x2cb460['$inject']=['$scope','$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x25d9'),_0x36e6f4('0x1825'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x2cb460(_0x4c8dd5,_0x362d10,_0x543168,_0x1d2d46,_0x1199bd,_0x3c15c6,_0x2f5f9e,_0x404506,_0x409e3a,_0x5f3497,_0x220335,_0x5c4ba7,_0x97651,_0x57a43d){const _0x6b114b=_0x36e6f4,_0x13397c=this;_0x13397c[_0x6b114b('0x98')]=_0x220335[_0x6b114b('0x26cd')](),_0x13397c[_0x6b114b('0x61a')]=[],_0x13397c[_0x6b114b('0xf8a')]=_0x97651,_0x13397c[_0x6b114b('0x5c9')]=_0x5c4ba7,_0x13397c[_0x6b114b('0x243c')]=_0x57a43d,_0x13397c[_0x6b114b('0x128b')]={},_0x13397c[_0x6b114b('0x2900')]=_0x13397c[_0x6b114b('0xf8a')]&&_0x13397c['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x13397c['title']='VOICE.EDIT_VOICERECORDING',_0x13397c['voiceRecording']=angular[_0x6b114b('0x225f')](_0x409e3a),_0x13397c[_0x6b114b('0x25d9')]=_0x404506,_0x13397c[_0x6b114b('0x15a1')]=![];!_0x13397c[_0x6b114b('0x1825')]&&(_0x13397c[_0x6b114b('0x1825')]={},_0x13397c[_0x6b114b('0xcdc')]=_0x6b114b('0x21e7'),_0x13397c[_0x6b114b('0x15a1')]=!![]);_0x13397c[_0x6b114b('0x2505')]=_0x1de599,_0x13397c['saveVoiceRecording']=_0x42ee7e,_0x13397c['deleteVoiceRecording']=_0x52b3c0,_0x13397c[_0x6b114b('0x1a9c')]=_0x43ca44,_0x13397c['closeDialog']=_0x52d3f2;function _0x1de599(){const _0x24c6fb=_0x6b114b;_0x13397c[_0x24c6fb('0x61a')]=[],_0x5f3497[_0x24c6fb('0x1825')][_0x24c6fb('0x9cc')](_0x13397c[_0x24c6fb('0x1825')])[_0x24c6fb('0xa44')]['then'](function(_0x3ff02d){const _0x187909=_0x24c6fb;_0x13397c[_0x187909('0x25d9')][_0x187909('0x2450')](_0x3ff02d[_0x187909('0x2876')]()),_0x2f5f9e['success']({'title':_0x187909('0x167a'),'msg':_0x13397c[_0x187909('0x1825')]['name']?_0x13397c['voiceRecording'][_0x187909('0x4f0')]+_0x187909('0x1eda'):''}),_0x52d3f2(_0x3ff02d);})['catch'](function(_0x280285){const _0x2b4c68=_0x24c6fb;if(_0x280285['data']&&_0x280285[_0x2b4c68('0x25f4')][_0x2b4c68('0x61a')]&&_0x280285[_0x2b4c68('0x25f4')][_0x2b4c68('0x61a')][_0x2b4c68('0x264b')]){_0x13397c['errors']=_0x280285['data']['errors']||[{'message':_0x280285['toString'](),'type':_0x2b4c68('0x2480')}];for(let _0x4912b6=0x0;_0x4912b6<_0x280285[_0x2b4c68('0x25f4')][_0x2b4c68('0x61a')]['length'];_0x4912b6+=0x1){_0x2f5f9e[_0x2b4c68('0xfc9')]({'title':_0x280285[_0x2b4c68('0x25f4')]['errors'][_0x4912b6][_0x2b4c68('0x1345')],'msg':_0x280285[_0x2b4c68('0x25f4')][_0x2b4c68('0x61a')][_0x4912b6][_0x2b4c68('0x1e70')]});}}else _0x2f5f9e[_0x2b4c68('0xfc9')]({'title':_0x280285[_0x2b4c68('0x52d')]?'API:'+_0x280285[_0x2b4c68('0x52d')]+_0x2b4c68('0x11e1')+_0x280285[_0x2b4c68('0xe1b')]:'api.voiceRecording.save','msg':_0x280285[_0x2b4c68('0x25f4')]?JSON[_0x2b4c68('0xbac')](_0x280285[_0x2b4c68('0x25f4')][_0x2b4c68('0x1e70')]):_0x280285[_0x2b4c68('0x1586')]()});});}function _0x42ee7e(){const _0x1605fe=_0x6b114b;_0x13397c[_0x1605fe('0x61a')]=[],_0x5f3497['voiceRecording'][_0x1605fe('0x1449')]({'id':_0x13397c[_0x1605fe('0x1825')]['id']},_0x13397c['voiceRecording'])['$promise'][_0x1605fe('0x1166')](function(_0x573359){const _0x401a63=_0x1605fe,_0x56fb2b=_0x2cfb05()[_0x401a63('0xc38')](_0x13397c[_0x401a63('0x25d9')],{'id':_0x573359['id']});_0x56fb2b&&_0x2cfb05()[_0x401a63('0xcc3')](_0x56fb2b,_0x2cfb05()[_0x401a63('0x1a08')](_0x573359['toJSON'](),_0x2cfb05()[_0x401a63('0x14a4')](_0x56fb2b))),_0x2f5f9e[_0x401a63('0x103b')]({'title':_0x401a63('0x14f2'),'msg':_0x13397c[_0x401a63('0x1825')][_0x401a63('0x4f0')]?_0x13397c[_0x401a63('0x1825')]['name']+_0x401a63('0x7d'):''}),_0x52d3f2(_0x573359);})[_0x1605fe('0x1a80')](function(_0x2b4832){const _0x1860d6=_0x1605fe;if(_0x2b4832[_0x1860d6('0x25f4')]&&_0x2b4832['data'][_0x1860d6('0x61a')]&&_0x2b4832[_0x1860d6('0x25f4')][_0x1860d6('0x61a')][_0x1860d6('0x264b')]){_0x13397c[_0x1860d6('0x61a')]=_0x2b4832['data'][_0x1860d6('0x61a')]||[{'message':_0x2b4832['toString'](),'type':_0x1860d6('0x900')}];for(let _0x44fd2f=0x0;_0x44fd2f<_0x2b4832['data'][_0x1860d6('0x61a')]['length'];_0x44fd2f++){_0x2f5f9e[_0x1860d6('0xfc9')]({'title':_0x2b4832[_0x1860d6('0x25f4')][_0x1860d6('0x61a')][_0x44fd2f]['type'],'msg':_0x2b4832['data']['errors'][_0x44fd2f][_0x1860d6('0x1e70')]});}}else _0x2f5f9e['error']({'title':_0x2b4832[_0x1860d6('0x52d')]?'API:'+_0x2b4832[_0x1860d6('0x52d')]+'\x20-\x20'+_0x2b4832[_0x1860d6('0xe1b')]:_0x1860d6('0x900'),'msg':_0x2b4832[_0x1860d6('0x25f4')]?JSON[_0x1860d6('0xbac')](_0x2b4832['data'][_0x1860d6('0x1e70')]):_0x2b4832[_0x1860d6('0x1586')]()});});}function _0x52b3c0(_0x503efd){const _0x40a488=_0x6b114b;_0x13397c[_0x40a488('0x61a')]=[];const _0x5e3e24=_0x1d2d46['confirm']()['title']('Are\x20you\x20sure?')[_0x40a488('0xacc')]('The\x20voiceRecording\x20will\x20be\x20deleted.')[_0x40a488('0x8e8')]('Delete\x20VoiceRecording')['ok'](_0x40a488('0x18'))[_0x40a488('0x3f')](_0x40a488('0x497'))[_0x40a488('0x203b')](_0x503efd);_0x1d2d46[_0x40a488('0x1f80')](_0x5e3e24)['then'](function(){const _0x266098=_0x40a488;_0x5f3497['voiceRecording'][_0x266098('0x906')]({'id':_0x13397c[_0x266098('0x1825')]['id']})[_0x266098('0xa44')][_0x266098('0x1166')](function(){const _0x12fce5=_0x266098;_0x2cfb05()[_0x12fce5('0x127f')](_0x13397c[_0x12fce5('0x25d9')],{'id':_0x13397c[_0x12fce5('0x1825')]['id']}),_0x2f5f9e[_0x12fce5('0x103b')]({'title':'VoiceRecording\x20properly\x20deleted!','msg':(_0x13397c['voiceRecording'][_0x12fce5('0x4f0')]||_0x12fce5('0x1825'))+_0x12fce5('0x7cd')}),_0x52d3f2(_0x13397c['voiceRecording']);})[_0x266098('0x1a80')](function(_0x522556){const _0x560f26=_0x266098;if(_0x522556[_0x560f26('0x25f4')]&&_0x522556[_0x560f26('0x25f4')][_0x560f26('0x61a')]&&_0x522556['data'][_0x560f26('0x61a')][_0x560f26('0x264b')]){_0x13397c[_0x560f26('0x61a')]=_0x522556[_0x560f26('0x25f4')]['errors']||[{'message':_0x522556[_0x560f26('0x1586')](),'type':_0x560f26('0x1abe')}];for(let _0x99699d=0x0;_0x99699d<_0x522556['data']['errors'][_0x560f26('0x264b')];_0x99699d++){_0x2f5f9e[_0x560f26('0xfc9')]({'title':_0x522556[_0x560f26('0x25f4')][_0x560f26('0x61a')][_0x99699d][_0x560f26('0x1345')],'msg':_0x522556[_0x560f26('0x25f4')][_0x560f26('0x61a')][_0x99699d][_0x560f26('0x1e70')]});}}else _0x2f5f9e[_0x560f26('0xfc9')]({'title':_0x522556[_0x560f26('0x52d')]?_0x560f26('0x1e21')+_0x522556['status']+_0x560f26('0x11e1')+_0x522556['statusText']:'api.voiceRecording.delete','msg':_0x522556[_0x560f26('0x25f4')]?JSON[_0x560f26('0xbac')](_0x522556['data'][_0x560f26('0x1e70')]):_0x522556[_0x560f26('0x1e70')]||_0x522556[_0x560f26('0x1586')]()});});},function(){});}function _0x43ca44(_0x5c179c){return _0x5c179c===null?undefined:new Date(_0x5c179c);}function _0x52d3f2(_0x45e782){_0x1d2d46['hide'](_0x45e782);}}const _0x3c4b8b=_0x2cb460;function _0x342c52(){const _0x536453=_0x36e6f4,_0x223be8=this;_0x223be8[_0x536453('0x1825')]={},_0x223be8[_0x536453('0x24d5')]=_0x28db53;function _0x28db53(_0xf90bf7){const _0x440b9a=_0x536453;_0x223be8[_0x440b9a('0x1825')]=_0xf90bf7;}}const _0x342a14=_0x342c52;_0xd2bc6f[_0x36e6f4('0x1294')]=['$state',_0x36e6f4('0x25e0'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),'license','setting','api',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x1825'),_0x36e6f4('0x17aa')];function _0xd2bc6f(_0xbbc554,_0x4d4133,_0x13fbfc,_0x6f2a26,_0x344ab2,_0x52d531,_0x13f407,_0x585ac1,_0x42270c,_0x29091d,_0x1aaa32,_0x1a4d45){const _0x274f21=_0x36e6f4,_0x23453d=this;_0x23453d[_0x274f21('0x98')]=_0x29091d[_0x274f21('0x26cd')](),_0x23453d['license']=_0x52d531,_0x23453d[_0x274f21('0xf8a')]=_0x13f407,_0x23453d['passwordPattern']=_0x23453d['setting'][_0x274f21('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x23453d[_0x274f21('0x246b')]=_0x4d4133[_0x274f21('0x6f1')]()+_0x274f21('0xc51')+_0x4d4133[_0x274f21('0x1690')](),_0x23453d['voiceRecording']=_0x1aaa32||_0xbbc554[_0x274f21('0x23f')][_0x274f21('0x1825')]||{},_0x23453d[_0x274f21('0x17aa')]=_0x1a4d45&&_0x1a4d45[_0x274f21('0x240f')]==0x1?_0x1a4d45[_0x274f21('0x269a')][0x0]:null,_0x23453d[_0x274f21('0x243c')]=_0x29091d['parseCrudPermissions'](_0x23453d['userProfileSection']?_0x23453d['userProfileSection']['crudPermissions']:null),_0x23453d[_0x274f21('0x128b')]={},_0x23453d[_0x274f21('0x2669')]=_0xbbc554[_0x274f21('0x23f')][_0x274f21('0xbe3')]||0x0,_0x23453d['alert']=_0x42270c[_0x274f21('0x1fa1')],_0x23453d[_0x274f21('0x17ee')]=_0x1a70de,_0x23453d[_0x274f21('0x2396')]=_0x10cb9d;function _0x1a70de(){const _0xbc2d1e=_0x274f21;_0xbbc554['go'](_0xbc2d1e('0x20a1'),{},{'reload':_0xbc2d1e('0x20a1')});}function _0x10cb9d(){const _0x367834=_0x274f21;_0x585ac1[_0x367834('0x1825')][_0x367834('0x1449')]({'id':_0x23453d[_0x367834('0x1825')]['id']},_0x23453d[_0x367834('0x1825')])['$promise']['then'](function(){const _0x3044ae=_0x367834;_0x42270c[_0x3044ae('0x103b')]({'title':_0x3044ae('0xfc'),'msg':_0x23453d[_0x3044ae('0x1825')][_0x3044ae('0x4f0')]?_0x23453d[_0x3044ae('0x1825')][_0x3044ae('0x4f0')]+_0x3044ae('0xa17'):''});})['catch'](function(_0x12f0a6){const _0x548c15=_0x367834;_0x42270c[_0x548c15('0xfc9')]({'title':_0x12f0a6[_0x548c15('0x52d')]?_0x548c15('0x1e21')+_0x12f0a6['status']+_0x548c15('0x11e1')+_0x12f0a6[_0x548c15('0xe1b')]:'SYSTEM:GETvoiceRecording','msg':_0x12f0a6[_0x548c15('0x25f4')]?JSON[_0x548c15('0xbac')](_0x12f0a6['data']):_0x12f0a6[_0x548c15('0x1586')]()});});}}const _0x3836ce=_0xd2bc6f,_0xb398ae=_0x2734b2['p']+_0x36e6f4('0x8c6');_0x25536e['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x25d9'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),'toasty',_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a')];function _0x25536e(_0x399c0e,_0x577b92,_0x4010c7,_0x5a5a57,_0x31396c,_0x12ac96,_0x4fc424,_0xb08019,_0xfdb576,_0x3ab758,_0x3abb8c,_0x409a86,_0x415574,_0x965e0e,_0x25a8b2,_0xc1b501,_0x313794){const _0x441fa2=_0x36e6f4,_0x2b9972=this;_0x2b9972[_0x441fa2('0x5c9')]=_0xc1b501,_0x2b9972['setting']=_0x313794,_0x2b9972[_0x441fa2('0x98')]=_0x25a8b2['getCurrentUser'](),_0x2b9972[_0x441fa2('0x25d9')]=_0xfdb576||{'count':0x0,'rows':[]},_0x2b9972[_0x441fa2('0x7f')]=_0x3ab758,_0x2b9972['userProfileSection']=_0x3abb8c&&_0x3abb8c[_0x441fa2('0x240f')]==0x1?_0x3abb8c[_0x441fa2('0x269a')][0x0]:null,_0x2b9972['crudPermissions']=_0x25a8b2[_0x441fa2('0xd87')](_0x2b9972[_0x441fa2('0x17aa')]?_0x2b9972[_0x441fa2('0x17aa')][_0x441fa2('0x243c')]:null),_0x2b9972[_0x441fa2('0x916')]=_0x441fa2('0x25d9'),_0x2b9972[_0x441fa2('0xef5')]='',_0x2b9972['listOrderAsc']=null,_0x2b9972[_0x441fa2('0x16ab')]=[],_0x2b9972[_0x441fa2('0x2218')]={'fields':_0x441fa2('0xeea'),'sort':_0x441fa2('0x14dc'),'createdAt':'@msUtils.firstLastDayMonth()','limit':0xa,'page':0x1},_0x2b9972[_0x441fa2('0x2218')]['createdAt']=_0x415574[_0x441fa2('0x1024')](),_0x2b9972['quickFilters']=_0x2f7b0b();function _0x2f7b0b(){const _0x3572a0=_0x441fa2;return[{'name':_0x3572a0('0x2567'),'key':_0x3572a0('0x262'),'type':_0x3572a0('0x1643'),'label':_0x3572a0('0x9a9')}];}_0x2b9972['editstate']=_0x15e4cb,_0x2b9972[_0x441fa2('0x10ed')]=_0x590997,_0x2b9972[_0x441fa2('0x1a84')]=_0x27e1e3,_0x2b9972[_0x441fa2('0xc65')]=_0x131f21,_0x2b9972['downloadtranscribefile2']=_0x3eed37,_0x2b9972[_0x441fa2('0x424')]=_0x16cd19,_0x2b9972[_0x441fa2('0x8d8')]=_0xdbc5a3,_0x2b9972[_0x441fa2('0x103b')]=_0x4afdc8,_0x2b9972[_0x441fa2('0x1773')]=_0x2d293e,_0x2b9972[_0x441fa2('0x59a')]=_0x30e509,_0x2b9972[_0x441fa2('0x2716')]=_0x3f8c2c,_0x2b9972[_0x441fa2('0x1e50')]=_0xa5c5b6,_0x2b9972['deleteSelectedVoiceRecordings']=_0x21a37,_0x2b9972[_0x441fa2('0x210a')]=_0xd6de35,_0x2b9972[_0x441fa2('0x1525')]=_0x1ae40f;function _0x15e4cb(_0x222ef7){const _0x2663e3=_0x441fa2;_0x4010c7['go'](_0x2663e3('0x1539'),{'id':_0x222ef7['id'],'voiceRecording':_0x222ef7,'crudPermissions':_0x2b9972[_0x2663e3('0x243c')]});}_0x2b9972[_0x441fa2('0x2bf')]=_0x15a6fd;function _0x590997(_0x2cdf6e){const _0x4581fa=_0x441fa2;return _0x409a86[_0x4581fa('0x1825')][_0x4581fa('0x21fc')]({'id':_0x2cdf6e['id'],'runSentiment':![]})[_0x4581fa('0xa44')]['then'](function(_0x1cb997){const _0x3418a8=_0x4581fa;_0x965e0e[_0x3418a8('0x103b')]({'title':_0xb08019['instant'](_0x3418a8('0x2137')),'msg':_0xb08019['instant']('VOICE.RUNTRANSCRIBE_VOICERECORDING')+_0x3418a8('0x2238')}),_0x2cdf6e[_0x3418a8('0x4ca')]=_0x1cb997[_0x3418a8('0x4ca')];})[_0x4581fa('0x1a80')](function(_0x19c5ab){const _0x36cb6b=_0x4581fa;_0x965e0e[_0x36cb6b('0xfc9')]({'title':_0xb08019[_0x36cb6b('0x25cc')](_0x36cb6b('0x2137')),'msg':_0x19c5ab[_0x36cb6b('0x25f4')]?_0x19c5ab[_0x36cb6b('0x25f4')][_0x36cb6b('0x1e70')]?_0x19c5ab[_0x36cb6b('0x25f4')][_0x36cb6b('0x1e70')]:JSON[_0x36cb6b('0xbac')](_0x19c5ab[_0x36cb6b('0x25f4')]):_0x19c5ab[_0x36cb6b('0x1586')]()});});}function _0x15a6fd(){const _0xf012d6=_0x441fa2;_0x2b9972[_0xf012d6('0x16ab')]['forEach'](function(_0x4e862c){_0x590997(_0x4e862c);}),_0x2b9972[_0xf012d6('0x16ab')]=[];}_0x2b9972[_0x441fa2('0x2693')]=_0x42ffd5;function _0x27e1e3(_0x2b0a64){const _0x17189c=_0x441fa2;return _0x409a86[_0x17189c('0x1825')][_0x17189c('0x21fc')]({'id':_0x2b0a64['id'],'runSentiment':!![]})[_0x17189c('0xa44')][_0x17189c('0x1166')](function(_0x3b53ca){const _0x3e5280=_0x17189c;_0x965e0e[_0x3e5280('0x103b')]({'title':_0xb08019[_0x3e5280('0x25cc')]('VOICE.RUNTRANSCRIBESENTIMENT_VOICERECORDING'),'msg':_0xb08019['instant'](_0x3e5280('0x5d8'))+_0x3e5280('0x2238')}),_0x2b0a64['transcribeStatus']=_0x3b53ca[_0x3e5280('0x4ca')];})[_0x17189c('0x1a80')](function(_0x595d8c){const _0x459e58=_0x17189c;_0x965e0e[_0x459e58('0xfc9')]({'title':_0xb08019['instant'](_0x459e58('0x5d8')),'msg':_0x595d8c[_0x459e58('0x25f4')]?_0x595d8c[_0x459e58('0x25f4')][_0x459e58('0x1e70')]?_0x595d8c['data'][_0x459e58('0x1e70')]:JSON[_0x459e58('0xbac')](_0x595d8c[_0x459e58('0x25f4')]):_0x595d8c[_0x459e58('0x1586')]()});});}function _0x42ffd5(){const _0x5b24a2=_0x441fa2;_0x2b9972[_0x5b24a2('0x16ab')][_0x5b24a2('0x2782')](function(_0x5d7aef){_0x27e1e3(_0x5d7aef);}),_0x2b9972['selectedVoiceRecordings']=[];}_0x2b9972[_0x441fa2('0x1dfd')]=_0x4aeb32;function _0x131f21(_0x5b0426){const _0x4dea56=_0x441fa2;return _0x409a86[_0x4dea56('0x1825')][_0x4dea56('0x21fc')]({'id':_0x5b0426['id'],'runSentiment':!![]})['$promise'][_0x4dea56('0x1166')](function(){const _0x4045c2=_0x4dea56;_0x965e0e['success']({'title':_0xb08019[_0x4045c2('0x25cc')](_0x4045c2('0x11c')),'msg':_0xb08019[_0x4045c2('0x25cc')]('VOICE.RUNSENTIMENT_VOICERECORDING')+_0x4045c2('0x2238')});})[_0x4dea56('0x1a80')](function(_0x12eeec){const _0x177194=_0x4dea56;_0x965e0e[_0x177194('0xfc9')]({'title':_0xb08019['instant'](_0x177194('0x11c')),'msg':_0x12eeec[_0x177194('0x25f4')]?_0x12eeec[_0x177194('0x25f4')][_0x177194('0x1e70')]?_0x12eeec['data'][_0x177194('0x1e70')]:JSON[_0x177194('0xbac')](_0x12eeec[_0x177194('0x25f4')]):_0x12eeec[_0x177194('0x1586')]()});});}function _0x4aeb32(){const _0x29d935=_0x441fa2;_0x2b9972[_0x29d935('0x16ab')][_0x29d935('0x2782')](function(_0x2a54c9){_0x131f21(_0x2a54c9);}),_0x2b9972[_0x29d935('0x16ab')]=[];}function _0x3eed37(_0x5afed3){const _0x38ec1b=_0x441fa2;let _0x17136e=![];const _0x4a5a0a=!_0x2cfb05()[_0x38ec1b('0x2863')](_0x5afed3[_0x38ec1b('0x128a')])?_0x5afed3['format']:_0x5afed3['value'][_0x38ec1b('0x192f')](_0x5afed3[_0x38ec1b('0x18e0')][_0x38ec1b('0x19da')]('.'));return _0x17136e=_0x4a5a0a===_0x38ec1b('0x2532')?!![]:![],_0x409a86['voiceRecording'][_0x38ec1b('0x1200')]({'id':_0x5afed3['id']})[_0x38ec1b('0xa44')][_0x38ec1b('0x1166')](function(_0x38ade6){const _0x563336=_0x38ec1b,_0x55d037=[_0x38ade6[_0x563336('0x20ed')]];let _0x3654ac='download';const _0x439a19=new Blob(_0x55d037,{'type':_0x38ade6[_0x563336('0x1345')]});_0x3654ac=_0x5afed3[_0x563336('0x1c21')]+_0x563336('0x256f');const _0x434bbc=window[_0x563336('0x136d')][_0x563336('0xdd')]('a');_0x434bbc['setAttribute']('href',URL[_0x563336('0x215a')](_0x439a19)),_0x434bbc[_0x563336('0xffd')](_0x563336('0x2ad'),_0x3654ac),document[_0x563336('0x8d2')][_0x563336('0x21a')](_0x434bbc),_0x434bbc[_0x563336('0x3b4')]();})[_0x38ec1b('0x1a80')](function(_0x496a29){const _0x192d22=_0x38ec1b;if(_0x496a29[_0x192d22('0x25f4')]&&_0x496a29[_0x192d22('0x25f4')][_0x192d22('0x61a')]&&_0x496a29['data']['errors'][_0x192d22('0x264b')])for(let _0x5e9c64=0x0;_0x5e9c64<_0x496a29[_0x192d22('0x25f4')][_0x192d22('0x61a')][_0x192d22('0x264b')];_0x5e9c64++){_0x965e0e[_0x192d22('0xfc9')]({'title':_0x496a29[_0x192d22('0x25f4')]['errors'][_0x5e9c64][_0x192d22('0x1345')],'msg':_0x496a29[_0x192d22('0x25f4')][_0x192d22('0x61a')][_0x5e9c64][_0x192d22('0x1e70')]});}else{if(String(_0x496a29[_0x192d22('0x52d')])===_0x192d22('0x24e7')&&_0x17136e===![])_0x965e0e[_0x192d22('0x1fa1')]({'title':_0xb08019[_0x192d22('0x25cc')](_0x192d22('0x151e')),'msg':_0xb08019['instant'](_0x192d22('0x162'))});else String(_0x496a29['status'])===_0x192d22('0x24e7')?_0x965e0e['info']({'title':_0xb08019[_0x192d22('0x25cc')](_0x192d22('0x151e')),'msg':_0xb08019[_0x192d22('0x25cc')]('VOICE.FILE_NOT_FOUND')}):_0x965e0e[_0x192d22('0xfc9')]({'title':_0x496a29['status']?_0x192d22('0x1e21')+_0x496a29['status']+_0x192d22('0x11e1')+_0x496a29[_0x192d22('0xe1b')]:'api.voiceRecording.save','msg':_0x496a29['data']?JSON['stringify'](_0x496a29[_0x192d22('0x25f4')]['message']):_0x496a29[_0x192d22('0x1586')]()});}});}function _0x416905(_0x29bb2b){const _0x44bf51=_0x441fa2;let _0x1eeb89=_0x29bb2b['lastIndexOf']('/')>-0x1?_0x29bb2b[_0x44bf51('0x192f')](_0x29bb2b['lastIndexOf']('/')+0x1):_0x29bb2b[_0x44bf51('0x19da')]('\x5c')>-0x1?_0x29bb2b['substring'](_0x29bb2b[_0x44bf51('0x19da')]('\x5c')+0x1):_0x29bb2b;return _0x1eeb89=_0x1eeb89[_0x44bf51('0x192f')](0x0,_0x1eeb89[_0x44bf51('0x19da')]('.')),_0x1eeb89;}function _0x16cd19(_0xc40cba){const _0x2b0273=_0x441fa2;let _0x4d8690=![];const _0x3af07a=!_0x2cfb05()[_0x2b0273('0x2863')](_0xc40cba[_0x2b0273('0x128a')])?_0xc40cba[_0x2b0273('0x128a')]:_0xc40cba[_0x2b0273('0x18e0')][_0x2b0273('0x192f')](_0xc40cba[_0x2b0273('0x18e0')][_0x2b0273('0x19da')]('.'));return _0x4d8690=_0x3af07a==='.mp4'?!![]:![],_0x409a86[_0x2b0273('0x1825')][_0x2b0273('0x2ad')]({'id':_0xc40cba['id']})[_0x2b0273('0xa44')][_0x2b0273('0x1166')](function(_0x3700a5){const _0x123ea6=_0x2b0273,_0x412dc=[_0x3700a5[_0x123ea6('0x20ed')]];let _0x187c04=_0x123ea6('0x2ad');const _0x2e5842=new Blob(_0x412dc,{'type':_0x3700a5[_0x123ea6('0x1345')]});_0x187c04=_0x416905(_0xc40cba[_0x123ea6('0x18e0')])+_0xc40cba[_0x123ea6('0x128a')];const _0x4b54da=window['document'][_0x123ea6('0xdd')]('a');_0x4b54da[_0x123ea6('0xffd')](_0x123ea6('0x14f9'),URL[_0x123ea6('0x215a')](_0x2e5842)),_0x4b54da[_0x123ea6('0xffd')](_0x123ea6('0x2ad'),_0x187c04),document[_0x123ea6('0x8d2')][_0x123ea6('0x21a')](_0x4b54da),_0x4b54da[_0x123ea6('0x3b4')]();})[_0x2b0273('0x1a80')](function(_0x5cce29){const _0x2a4b72=_0x2b0273;if(_0x5cce29['data']&&_0x5cce29[_0x2a4b72('0x25f4')][_0x2a4b72('0x61a')]&&_0x5cce29[_0x2a4b72('0x25f4')][_0x2a4b72('0x61a')][_0x2a4b72('0x264b')])for(let _0x3975d6=0x0;_0x3975d6<_0x5cce29[_0x2a4b72('0x25f4')][_0x2a4b72('0x61a')][_0x2a4b72('0x264b')];_0x3975d6++){_0x965e0e['error']({'title':_0x5cce29[_0x2a4b72('0x25f4')][_0x2a4b72('0x61a')][_0x3975d6]['type'],'msg':_0x5cce29[_0x2a4b72('0x25f4')][_0x2a4b72('0x61a')][_0x3975d6][_0x2a4b72('0x1e70')]});}else{if(String(_0x5cce29['status'])===_0x2a4b72('0x24e7')&&_0x4d8690===![])_0x965e0e[_0x2a4b72('0x1fa1')]({'title':_0xb08019[_0x2a4b72('0x25cc')](_0x2a4b72('0x151e')),'msg':_0xb08019['instant'](_0x2a4b72('0x162'))});else String(_0x5cce29['status'])==='404'?_0x965e0e['info']({'title':_0xb08019[_0x2a4b72('0x25cc')](_0x2a4b72('0x151e')),'msg':_0xb08019[_0x2a4b72('0x25cc')](_0x2a4b72('0x1703'))}):_0x965e0e[_0x2a4b72('0xfc9')]({'title':_0x5cce29[_0x2a4b72('0x52d')]?_0x2a4b72('0x1e21')+_0x5cce29[_0x2a4b72('0x52d')]+_0x2a4b72('0x11e1')+_0x5cce29['statusText']:_0x2a4b72('0x2480'),'msg':_0x5cce29[_0x2a4b72('0x25f4')]?JSON['stringify'](_0x5cce29[_0x2a4b72('0x25f4')]['message']):_0x5cce29[_0x2a4b72('0x1586')]()});}});}function _0xdbc5a3(_0x51f5ff,_0x4c8c95){const _0xfc0a47=_0x441fa2,_0x247380=_0x31396c['confirm']()[_0xfc0a47('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0xfc0a47('0xb35')](_0xfc0a47('0x1825'))+'?')[_0xfc0a47('0xf3c')](_0xfc0a47('0x12b5')+(_0x51f5ff['name']||_0xfc0a47('0x1825'))+_0xfc0a47('0xace')+_0xfc0a47('0x3f3'))[_0xfc0a47('0x8e8')](_0xfc0a47('0x996'))[_0xfc0a47('0x203b')](_0x4c8c95)['ok']('OK')[_0xfc0a47('0x3f')](_0xfc0a47('0x2d3'));_0x31396c[_0xfc0a47('0x1f80')](_0x247380)['then'](function(){_0x3f8c2c(_0x51f5ff);},function(){const _0xbb4064=_0xfc0a47;console[_0xbb4064('0x455')]('CANCEL');});}let _0x366488=!![],_0x4cfa61=0x1;_0x399c0e[_0x441fa2('0xe83')](_0x441fa2('0x12d8'),function(_0x3a74d3,_0x51204c){const _0xe8de05=_0x441fa2;_0x366488?_0x4fc424(function(){_0x366488=![];}):(!_0x51204c&&(_0x4cfa61=_0x2b9972[_0xe8de05('0x2218')]['page']),_0x3a74d3!==_0x51204c&&(_0x2b9972['query'][_0xe8de05('0x1a43')]=0x1),!_0x3a74d3&&(_0x2b9972[_0xe8de05('0x2218')][_0xe8de05('0x1a43')]=_0x4cfa61),_0x2b9972[_0xe8de05('0x1773')]());});function _0x4afdc8(_0x12de4a){const _0x58c8c9=_0x441fa2;_0x2b9972[_0x58c8c9('0x25d9')]=_0x12de4a||{'count':0x0,'rows':[]};}function _0x2d293e(){const _0x23b636=_0x441fa2;_0x2b9972['query'][_0x23b636('0x1098')]=(_0x2b9972[_0x23b636('0x2218')][_0x23b636('0x1a43')]-0x1)*_0x2b9972[_0x23b636('0x2218')][_0x23b636('0x163f')],_0x25a8b2[_0x23b636('0x1ac6')](_0x23b636('0xa7c'))?_0x2b9972[_0x23b636('0x1f48')]=_0x409a86[_0x23b636('0x1825')][_0x23b636('0xd83')](_0x2b9972[_0x23b636('0x2218')],_0x4afdc8)[_0x23b636('0xa44')]:(_0x2b9972[_0x23b636('0x2218')]['id']=_0x2b9972[_0x23b636('0x7f')]['id'],_0x2b9972[_0x23b636('0x2218')][_0x23b636('0xe60')]=_0x23b636('0x262e'),_0x2b9972[_0x23b636('0x1f48')]=_0x409a86[_0x23b636('0x7f')][_0x23b636('0x263a')](_0x2b9972[_0x23b636('0x2218')],_0x4afdc8)['$promise']);}function _0x30e509(_0x58bbc3,_0x4dca34){const _0x1c5edf=_0x441fa2;_0x31396c[_0x1c5edf('0x1f80')]({'controller':_0x1c5edf('0x194d'),'controllerAs':'vm','templateUrl':_0xb398ae,'parent':angular['element'](_0x12ac96['body']),'targetEvent':_0x58bbc3,'clickOutsideToClose':!![],'locals':{'voiceRecording':_0x4dca34,'voiceRecordings':_0x2b9972[_0x1c5edf('0x25d9')][_0x1c5edf('0x269a')],'license':_0x2b9972[_0x1c5edf('0x5c9')],'setting':_0x2b9972[_0x1c5edf('0xf8a')],'crudPermissions':_0x2b9972[_0x1c5edf('0x243c')]}});}function _0x3f8c2c(_0x2a3307){const _0x280d69=_0x441fa2;_0x409a86['voiceRecording'][_0x280d69('0x906')]({'id':_0x2a3307['id']})[_0x280d69('0xa44')]['then'](function(){const _0x198caf=_0x280d69;_0x2cfb05()[_0x198caf('0x127f')](_0x2b9972[_0x198caf('0x25d9')]['rows'],{'id':_0x2a3307['id']}),_0x2b9972['voiceRecordings']['count']-=0x1,!_0x2b9972[_0x198caf('0x25d9')]['rows'][_0x198caf('0x264b')]&&_0x2b9972[_0x198caf('0x1773')](),_0x965e0e[_0x198caf('0x103b')]({'title':_0x2cfb05()[_0x198caf('0xb35')](_0x198caf('0x2495'))+'\x20deleted!','msg':_0x2a3307['name']?_0x2a3307[_0x198caf('0x4f0')]+_0x198caf('0x7cd'):''});})[_0x280d69('0x1a80')](function(_0x178a62){const _0x5746d3=_0x280d69;if(_0x178a62['data']&&_0x178a62[_0x5746d3('0x25f4')][_0x5746d3('0x61a')]&&_0x178a62[_0x5746d3('0x25f4')][_0x5746d3('0x61a')]['length']){_0x2b9972['errors']=_0x178a62['data'][_0x5746d3('0x61a')]||[{'message':_0x178a62[_0x5746d3('0x1586')](),'type':'SYSTEM:DELETEvoiceRecording'}];for(let _0x4af3bd=0x0;_0x4af3bd<_0x178a62[_0x5746d3('0x25f4')]['errors'][_0x5746d3('0x264b')];_0x4af3bd++){_0x965e0e[_0x5746d3('0xfc9')]({'title':_0x178a62[_0x5746d3('0x25f4')][_0x5746d3('0x61a')][_0x4af3bd][_0x5746d3('0x1345')],'msg':_0x178a62['data'][_0x5746d3('0x61a')][_0x4af3bd][_0x5746d3('0x1e70')]});}}else _0x965e0e['error']({'title':_0x178a62[_0x5746d3('0x52d')]?_0x5746d3('0x1e21')+_0x178a62[_0x5746d3('0x52d')]+_0x5746d3('0x11e1')+_0x178a62['statusText']:'SYSTEM:DELETEvoiceRecording','msg':_0x178a62[_0x5746d3('0x25f4')]?JSON[_0x5746d3('0xbac')](_0x178a62['data'][_0x5746d3('0x1e70')]):_0x178a62[_0x5746d3('0x1e70')]||_0x178a62[_0x5746d3('0x1586')]()});});}function _0xa5c5b6(){const _0x541926=_0x441fa2,_0x45b088=angular[_0x541926('0x225f')](_0x2b9972[_0x541926('0x16ab')]);return _0x2b9972['selectedVoiceRecordings']=[],_0x45b088;}function _0x21a37(_0x25f73c){const _0x5082e3=_0x441fa2,_0x16010c=_0x31396c['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20voiceRecordings?')['htmlContent'](_0x5082e3('0x12b5')+_0x2b9972[_0x5082e3('0x16ab')][_0x5082e3('0x264b')]+_0x5082e3('0x196d')+_0x5082e3('0x3f3'))['ariaLabel'](_0x5082e3('0x2a7'))[_0x5082e3('0x203b')](_0x25f73c)['ok']('OK')['cancel'](_0x5082e3('0x2d3'));_0x31396c[_0x5082e3('0x1f80')](_0x16010c)[_0x5082e3('0x1166')](function(){const _0x5b3d53=_0x5082e3;_0x2b9972['selectedVoiceRecordings'][_0x5b3d53('0x2782')](function(_0x3f4585){_0x3f8c2c(_0x3f4585);}),_0x2b9972[_0x5b3d53('0x16ab')]=[];});}function _0xd6de35(){_0x2b9972['selectedVoiceRecordings']=[];}function _0x1ae40f(){const _0xf48580=_0x441fa2;_0x2b9972[_0xf48580('0x16ab')]=_0x2b9972['voiceRecordings'][_0xf48580('0x269a')];}}const _0x44db08=_0x25536e,_0x111121=_0x2734b2['p']+_0x36e6f4('0x15ca'),_0x3f6fa7=_0x2734b2['p']+_0x36e6f4('0x215f'),_0x262d2a=_0x2734b2['p']+_0x36e6f4('0x337'),_0x13a804=_0x2734b2['p']+_0x36e6f4('0x21e4'),_0x2f47e8=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/outboundroutes/outboundroutes.html/outboundroutes.html',_0x2e5965=_0x2734b2['p']+_0x36e6f4('0xc7d'),_0x46fd17=_0x2734b2['p']+_0x36e6f4('0x362'),_0x24f939=_0x2734b2['p']+_0x36e6f4('0x589'),_0x8643b9=_0x2734b2['p']+_0x36e6f4('0x189c'),_0xf09b56=_0x2734b2['p']+_0x36e6f4('0x728'),_0xcbb0fc=_0x2734b2['p']+_0x36e6f4('0x24cd'),_0x2df545=_0x2734b2['p']+_0x36e6f4('0x1ad9'),_0x2e49ce=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/musiconholds/edit/view.html/view.html',_0x11d856=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/voiceRecordings/voiceRecordings.html/voiceRecordings.html',_0x2b8aa9=_0x2734b2['p']+_0x36e6f4('0xe99'),_0x4ded58=_0x2734b2['p']+_0x36e6f4('0xd1a'),_0x319936=_0x2734b2['p']+'src/js/modules/main/apps/voice/views/voicePrefixes/voicePrefixes.html/voicePrefixes.html';_0x1353f4['$inject']=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x1353f4(_0x261b5d,_0xa27fa6){const _0x30a4c8=_0x36e6f4;_0x261b5d[_0x30a4c8('0x63f')]('app.voice',{'abstract':!![],'url':_0x30a4c8('0x11be')})[_0x30a4c8('0x63f')](_0x30a4c8('0x2409'),{'url':_0x30a4c8('0x1cfd'),'views':{'content@app':{'templateUrl':_0x111121,'controller':_0x30a4c8('0x20c7')}},'resolve':{'voiceQueues':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x185fda,_0x546d45){const _0x1756b9=_0x30a4c8;return _0x546d45['hasRole'](_0x1756b9('0xa7c'))?_0x185fda[_0x1756b9('0x18af')](_0x1756b9('0x2700'),{'fields':_0x1756b9('0x1be0'),'type':'inbound','sort':_0x1756b9('0x14dc'),'channel':_0x1756b9('0x21da'),'limit':0xa,'offset':0x0}):_0x185fda[_0x1756b9('0x18af')](_0x1756b9('0x17c4'),{'id':_0x546d45['getCurrentUser']()['userProfileId'],'section':_0x1756b9('0x1ba2'),'fields':_0x1756b9('0x1be0'),'type':'inbound','sort':_0x1756b9('0x14dc'),'channel':_0x1756b9('0x21da'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x30a4c8('0x21ef'),function(_0x80a902,_0x34df33){const _0x51afa2=_0x30a4c8;return _0x34df33[_0x51afa2('0x1ac6')](_0x51afa2('0xa7c'))?null:_0x80a902[_0x51afa2('0x18af')](_0x51afa2('0x697'),{'fields':'id,name,crudPermissions','id':_0x34df33['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x314d8b,_0x271006){const _0x4bdff3=_0x30a4c8;return _0x271006[_0x4bdff3('0x1ac6')](_0x4bdff3('0xa7c'))?null:_0x314d8b[_0x4bdff3('0x18af')](_0x4bdff3('0xaf'),{'fields':_0x4bdff3('0xe26'),'userProfileId':_0x271006[_0x4bdff3('0x26cd')]()['userProfileId'],'sectionId':0x191});}]},'authenticate':!![],'permissionId':0x191,'bodyClass':'voice'})[_0x30a4c8('0x63f')](_0x30a4c8('0x1dd0'),{'url':'/:id?tab','params':{'voiceQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x3f6fa7,'controller':_0x30a4c8('0x1e4e')}},'resolve':{'voiceQueue':[_0x30a4c8('0x1fbc'),_0x30a4c8('0xf75'),function(_0xb24881,_0x1ce653){const _0x3ef57f=_0x30a4c8;return _0xb24881[_0x3ef57f('0x18af')](_0x3ef57f('0x2700'),{'fields':_0x3ef57f('0x1be0'),'id':_0x1ce653['id']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),'Auth',function(_0x28e2cb,_0x26ee60){const _0x1ba0df=_0x30a4c8;return _0x28e2cb[_0x1ba0df('0x18af')](_0x1ba0df('0xaf'),{'fields':_0x1ba0df('0xe26'),'userProfileId':_0x26ee60['getCurrentUser']()[_0x1ba0df('0xb86')],'sectionId':0x191});}]},'authenticate':!![],'permissionId':0x191,'bodyClass':_0x30a4c8('0x21da')})['state'](_0x30a4c8('0x2107'),{'url':_0x30a4c8('0x1695'),'views':{'content@app':{'templateUrl':_0x262d2a,'controller':_0x30a4c8('0x5d3')}},'resolve':{'inboundroutes':[_0x30a4c8('0x1fbc'),'Auth',function(_0x125117,_0x45a1b8){const _0x5135f2=_0x30a4c8;return _0x45a1b8[_0x5135f2('0x1ac6')](_0x5135f2('0xa7c'))?_0x125117[_0x5135f2('0x18af')](_0x5135f2('0x229'),{'fields':_0x5135f2('0x22cd'),'type':_0x5135f2('0x14d8'),'sort':_0x5135f2('0x14dc'),'VoiceExtensionId':_0x5135f2('0x15d7'),'limit':0xa,'offset':0x0}):_0x125117[_0x5135f2('0x18af')]('userProfile@getResources',{'id':_0x45a1b8[_0x5135f2('0x26cd')]()[_0x5135f2('0xb86')],'section':'InboundRoutes','fields':_0x5135f2('0x22cd'),'type':'inbound','sort':_0x5135f2('0x14dc'),'VoiceExtensionId':_0x5135f2('0x15d7'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x5bb767,_0x434780){const _0x16e4e0=_0x30a4c8;return _0x434780[_0x16e4e0('0x1ac6')]('admin')?null:_0x5bb767[_0x16e4e0('0x18af')](_0x16e4e0('0x697'),{'fields':_0x16e4e0('0x686'),'id':_0x434780[_0x16e4e0('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x1e23cd,_0x1f46b2){const _0x207658=_0x30a4c8;return _0x1f46b2[_0x207658('0x1ac6')](_0x207658('0xa7c'))?null:_0x1e23cd['resolve'](_0x207658('0xaf'),{'fields':_0x207658('0xe26'),'userProfileId':_0x1f46b2[_0x207658('0x26cd')]()['userProfileId'],'sectionId':0x192});}]},'authenticate':!![],'permissionId':0x192,'bodyClass':'voice'})[_0x30a4c8('0x63f')](_0x30a4c8('0x2609'),{'url':_0x30a4c8('0x2233'),'params':{'inboundroute':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x13a804,'controller':'InboundRouteController\x20as\x20vm'}},'resolve':{'inboundroute':[_0x30a4c8('0x1fbc'),'$stateParams',function(_0xf8569,_0x36f01a){const _0x3ba573=_0x30a4c8;return _0xf8569[_0x3ba573('0x18af')](_0x3ba573('0x229'),{'fields':_0x3ba573('0x22cd'),'id':_0x36f01a['id']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),'Auth',function(_0x496540,_0x1d4b20){const _0x4ee58e=_0x30a4c8;return _0x496540[_0x4ee58e('0x18af')](_0x4ee58e('0xaf'),{'fields':_0x4ee58e('0xe26'),'userProfileId':_0x1d4b20[_0x4ee58e('0x26cd')]()[_0x4ee58e('0xb86')],'sectionId':0x192});}]},'authenticate':!![],'permissionId':0x192,'bodyClass':_0x30a4c8('0x21da')})[_0x30a4c8('0x63f')]('app.voice.outboundroutes',{'url':_0x30a4c8('0x476'),'views':{'content@app':{'templateUrl':_0x2f47e8,'controller':_0x30a4c8('0x1c5a')}},'resolve':{'outboundroutes':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x5198d6,_0x53faff){const _0x2edb8a=_0x30a4c8;return _0x53faff[_0x2edb8a('0x1ac6')]('admin')?_0x5198d6[_0x2edb8a('0x18af')](_0x2edb8a('0x229'),{'fields':_0x2edb8a('0x22fd'),'type':_0x2edb8a('0x587'),'sort':_0x2edb8a('0x14dc'),'VoiceExtensionId':_0x2edb8a('0x15d7'),'limit':0xa,'offset':0x0}):_0x5198d6['resolve'](_0x2edb8a('0x17c4'),{'id':_0x53faff[_0x2edb8a('0x26cd')]()[_0x2edb8a('0xb86')],'section':_0x2edb8a('0x21f5'),'fields':_0x2edb8a('0x22fd'),'type':_0x2edb8a('0x587'),'sort':'-updatedAt','VoiceExtensionId':'null','limit':0xa,'offset':0x0});}],'userProfile':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x5c47e8,_0x469752){const _0x3b985d=_0x30a4c8;return _0x469752['hasRole']('admin')?null:_0x5c47e8['resolve']('userProfile@get',{'fields':_0x3b985d('0x686'),'id':_0x469752[_0x3b985d('0x26cd')]()[_0x3b985d('0xb86')]});}],'userProfileSection':['apiResolver',_0x30a4c8('0x21ef'),function(_0x2b7d32,_0x3fdde8){const _0x2f56d0=_0x30a4c8;return _0x3fdde8[_0x2f56d0('0x1ac6')]('admin')?null:_0x2b7d32[_0x2f56d0('0x18af')](_0x2f56d0('0xaf'),{'fields':_0x2f56d0('0xe26'),'userProfileId':_0x3fdde8['getCurrentUser']()[_0x2f56d0('0xb86')],'sectionId':0x193});}]},'authenticate':!![],'permissionId':0x193,'bodyClass':'voice'})['state']('app.voice.outboundroutes.edit',{'url':'/:id?tab','params':{'outboundroute':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x2e5965,'controller':_0x30a4c8('0x24a9')}},'resolve':{'outboundroute':[_0x30a4c8('0x1fbc'),'$stateParams',function(_0x4c61f8,_0x1b7794){const _0x275ff5=_0x30a4c8;return _0x4c61f8[_0x275ff5('0x18af')](_0x275ff5('0x229'),{'fields':'createdAt,updatedAt,id,appdata,type,exten,context,recordingFormat,cutdigits,description','id':_0x1b7794['id']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),'Auth',function(_0x3e911c,_0xf58985){const _0x4b3963=_0x30a4c8;return _0x3e911c[_0x4b3963('0x18af')](_0x4b3963('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0xf58985[_0x4b3963('0x26cd')]()[_0x4b3963('0xb86')],'sectionId':0x193});}]},'authenticate':!![],'permissionId':0x193,'bodyClass':_0x30a4c8('0x21da')})['state']('app.voice.internalroutes',{'url':_0x30a4c8('0x147d'),'views':{'content@app':{'templateUrl':_0x46fd17,'controller':_0x30a4c8('0x1ad5')}},'resolve':{'internalroutes':['apiResolver',_0x30a4c8('0x21ef'),function(_0x58b8f8,_0x10fa3f){const _0x363b16=_0x30a4c8;return _0x10fa3f[_0x363b16('0x1ac6')]('admin')?_0x58b8f8[_0x363b16('0x18af')](_0x363b16('0x229'),{'fields':'createdAt,updatedAt,id,appdata,type,exten,context,description','type':_0x363b16('0x1eef'),'sort':_0x363b16('0x14dc'),'VoiceExtensionId':_0x363b16('0x15d7'),'limit':0xa,'offset':0x0}):_0x58b8f8[_0x363b16('0x18af')](_0x363b16('0x17c4'),{'id':_0x10fa3f[_0x363b16('0x26cd')]()[_0x363b16('0xb86')],'section':'InternalRoutes','fields':_0x363b16('0x22cd'),'type':'internal','sort':_0x363b16('0x14dc'),'VoiceExtensionId':'null','limit':0xa,'offset':0x0});}],'userProfile':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x104bfc,_0x2eaf4e){const _0x4c4456=_0x30a4c8;return _0x2eaf4e[_0x4c4456('0x1ac6')](_0x4c4456('0xa7c'))?null:_0x104bfc[_0x4c4456('0x18af')](_0x4c4456('0x697'),{'fields':_0x4c4456('0x686'),'id':_0x2eaf4e[_0x4c4456('0x26cd')]()[_0x4c4456('0xb86')]});}],'userProfileSection':['apiResolver',_0x30a4c8('0x21ef'),function(_0x111ba8,_0x3dafe0){const _0x5874e9=_0x30a4c8;return _0x3dafe0[_0x5874e9('0x1ac6')]('admin')?null:_0x111ba8[_0x5874e9('0x18af')](_0x5874e9('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x3dafe0[_0x5874e9('0x26cd')]()['userProfileId'],'sectionId':0x194});}]},'authenticate':!![],'permissionId':0x194,'bodyClass':'voice'})[_0x30a4c8('0x63f')](_0x30a4c8('0x11d5'),{'url':_0x30a4c8('0x2233'),'params':{'internalroute':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x24f939,'controller':_0x30a4c8('0xf33')}},'resolve':{'internalroute':[_0x30a4c8('0x1fbc'),'$stateParams',function(_0x335d80,_0x5f0c70){const _0x10c502=_0x30a4c8;return _0x335d80[_0x10c502('0x18af')](_0x10c502('0x229'),{'fields':_0x10c502('0x22cd'),'id':_0x5f0c70['id']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x1d2cae,_0x29a3b0){const _0x3a74b5=_0x30a4c8;return _0x1d2cae['resolve'](_0x3a74b5('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x29a3b0[_0x3a74b5('0x26cd')]()['userProfileId'],'sectionId':0x194});}]},'authenticate':!![],'permissionId':0x194,'bodyClass':_0x30a4c8('0x21da')})['state'](_0x30a4c8('0x839'),{'url':_0x30a4c8('0x18b0'),'views':{'content@app':{'templateUrl':_0x8643b9,'controller':_0x30a4c8('0x18f9')}},'resolve':{'contexts':[_0x30a4c8('0x1fbc'),'Auth',function(_0x3ab1f3,_0x49a4ca){const _0x1f63e6=_0x30a4c8;return _0x49a4ca['hasRole'](_0x1f63e6('0xa7c'))?_0x3ab1f3[_0x1f63e6('0x18af')](_0x1f63e6('0xa59'),{'fields':_0x1f63e6('0x208e'),'sort':_0x1f63e6('0x14dc'),'defaultEntry':_0x1f63e6('0x1607'),'limit':0xa,'offset':0x0}):_0x3ab1f3[_0x1f63e6('0x18af')](_0x1f63e6('0x17c4'),{'id':_0x49a4ca['getCurrentUser']()[_0x1f63e6('0xb86')],'section':_0x1f63e6('0x136e'),'fields':_0x1f63e6('0x208e'),'sort':_0x1f63e6('0x14dc'),'defaultEntry':'false','limit':0xa,'offset':0x0});}],'userProfile':[_0x30a4c8('0x1fbc'),'Auth',function(_0x4e71ee,_0x3efafc){const _0x1c33bc=_0x30a4c8;return _0x3efafc[_0x1c33bc('0x1ac6')](_0x1c33bc('0xa7c'))?null:_0x4e71ee[_0x1c33bc('0x18af')](_0x1c33bc('0x697'),{'fields':_0x1c33bc('0x686'),'id':_0x3efafc[_0x1c33bc('0x26cd')]()[_0x1c33bc('0xb86')]});}],'userProfileSection':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x2a7a03,_0x2b3e6a){const _0xb5b3de=_0x30a4c8;return _0x2b3e6a[_0xb5b3de('0x1ac6')](_0xb5b3de('0xa7c'))?null:_0x2a7a03[_0xb5b3de('0x18af')](_0xb5b3de('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x2b3e6a[_0xb5b3de('0x26cd')]()[_0xb5b3de('0xb86')],'sectionId':0x195});}]},'authenticate':!![],'permissionId':0x195,'bodyClass':'voice'})[_0x30a4c8('0x63f')](_0x30a4c8('0x27be'),{'url':_0x30a4c8('0x759'),'views':{'content@app':{'templateUrl':_0xf09b56,'controller':'VoicemailsController\x20as\x20vm'}},'resolve':{'voicemails':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x290aaf,_0x5d84b9){const _0x36c5cf=_0x30a4c8;return _0x5d84b9[_0x36c5cf('0x1ac6')](_0x36c5cf('0xa7c'))?_0x290aaf[_0x36c5cf('0x18af')](_0x36c5cf('0x238f'),{'fields':_0x36c5cf('0xaf0'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x290aaf[_0x36c5cf('0x18af')](_0x36c5cf('0x17c4'),{'id':_0x5d84b9[_0x36c5cf('0x26cd')]()['userProfileId'],'section':_0x36c5cf('0x1116'),'fields':'createdAt,updatedAt,id,customer_id,fullname,email,password,mailbox,context,tz,attach,envelope,delete,emailbody,emailsubject,maxsecs,maxmsg','sort':_0x36c5cf('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x30a4c8('0x21ef'),function(_0x31f5bd,_0x3fb4a8){const _0x50b87b=_0x30a4c8;return _0x3fb4a8[_0x50b87b('0x1ac6')]('admin')?null:_0x31f5bd[_0x50b87b('0x18af')](_0x50b87b('0x697'),{'fields':_0x50b87b('0x686'),'id':_0x3fb4a8[_0x50b87b('0x26cd')]()[_0x50b87b('0xb86')]});}],'userProfileSection':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x133953,_0x224a8e){const _0x1ee981=_0x30a4c8;return _0x224a8e[_0x1ee981('0x1ac6')](_0x1ee981('0xa7c'))?null:_0x133953[_0x1ee981('0x18af')](_0x1ee981('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x224a8e[_0x1ee981('0x26cd')]()[_0x1ee981('0xb86')],'sectionId':0x196});}]},'authenticate':!![],'permissionId':0x196,'bodyClass':_0x30a4c8('0x21da')})[_0x30a4c8('0x63f')](_0x30a4c8('0x1730'),{'url':_0x30a4c8('0x2233'),'params':{'voicemail':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0xcbb0fc,'controller':_0x30a4c8('0xd55')}},'resolve':{'voicemail':['apiResolver',_0x30a4c8('0xf75'),function(_0x5c5fce,_0x47aaef){const _0x5ceb49=_0x30a4c8;return _0x5c5fce[_0x5ceb49('0x18af')](_0x5ceb49('0x238f'),{'fields':_0x5ceb49('0xaf0'),'id':_0x47aaef['id']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x592723,_0x3a8e65){const _0x1e3c63=_0x30a4c8;return _0x592723[_0x1e3c63('0x18af')](_0x1e3c63('0xaf'),{'fields':_0x1e3c63('0xe26'),'userProfileId':_0x3a8e65[_0x1e3c63('0x26cd')]()['userProfileId'],'sectionId':0x196});}]},'authenticate':!![],'permissionId':0x196,'bodyClass':'voice'})['state'](_0x30a4c8('0x1b42'),{'url':'/musiconholds','views':{'content@app':{'templateUrl':_0x2df545,'controller':_0x30a4c8('0x21ae')}},'resolve':{'musiconholds':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x5e5cde,_0x4ebfd3){const _0x10fc41=_0x30a4c8;return _0x4ebfd3['hasRole'](_0x10fc41('0xa7c'))?_0x5e5cde[_0x10fc41('0x18af')](_0x10fc41('0x75a'),{'fields':_0x10fc41('0x18db'),'defaultEntry':'false','limit':0xa,'offset':0x0}):_0x5e5cde['resolve']('userProfile@getResources',{'id':_0x4ebfd3['getCurrentUser']()['userProfileId'],'section':_0x10fc41('0x1a14'),'fields':_0x10fc41('0x18db'),'defaultEntry':_0x10fc41('0x1607'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver','Auth',function(_0x2230f4,_0x2d7f85){const _0x115d29=_0x30a4c8;return _0x2d7f85[_0x115d29('0x1ac6')](_0x115d29('0xa7c'))?null:_0x2230f4['resolve'](_0x115d29('0x697'),{'fields':_0x115d29('0x686'),'id':_0x2d7f85[_0x115d29('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),'Auth',function(_0x27d887,_0x349db8){const _0x283366=_0x30a4c8;return _0x349db8['hasRole'](_0x283366('0xa7c'))?null:_0x27d887[_0x283366('0x18af')](_0x283366('0xaf'),{'fields':_0x283366('0xe26'),'userProfileId':_0x349db8[_0x283366('0x26cd')]()['userProfileId'],'sectionId':0x197});}]},'authenticate':!![],'permissionId':0x197,'bodyClass':_0x30a4c8('0x21da')})[_0x30a4c8('0x63f')](_0x30a4c8('0x69a'),{'url':_0x30a4c8('0x2233'),'params':{'musiconhold':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x2e49ce,'controller':'MusicOnHoldController\x20as\x20vm'}},'resolve':{'musiconhold':[_0x30a4c8('0x1fbc'),_0x30a4c8('0xf75'),function(_0x4870b5,_0x394276){const _0x3a29ca=_0x30a4c8;return _0x4870b5['resolve'](_0x3a29ca('0x75a'),{'fields':'createdAt,updatedAt,id,name,mode,directory,application,format,sort','id':_0x394276['id']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),'Auth',function(_0x57ff06,_0x49b002){const _0x274483=_0x30a4c8;return _0x57ff06[_0x274483('0x18af')](_0x274483('0xaf'),{'fields':_0x274483('0xe26'),'userProfileId':_0x49b002[_0x274483('0x26cd')]()[_0x274483('0xb86')],'sectionId':0x197});}]},'authenticate':!![],'permissionId':0x197,'bodyClass':'voice'})[_0x30a4c8('0x63f')](_0x30a4c8('0x20a1'),{'url':'/voiceRecordings','views':{'content@app':{'templateUrl':_0x11d856,'controller':'VoiceRecordingsController\x20as\x20vm'}},'resolve':{'voiceRecordings':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),'msUtils',function(_0x437493,_0x6fb091,_0x5668e6){const _0x596a0e=_0x30a4c8;return _0x6fb091[_0x596a0e('0x1ac6')](_0x596a0e('0xa7c'))?_0x437493[_0x596a0e('0x18af')](_0x596a0e('0xf9'),{'fields':_0x596a0e('0xeea'),'sort':'-updatedAt','createdAt':_0x5668e6[_0x596a0e('0x1024')](),'limit':0xa,'offset':0x0}):_0x437493[_0x596a0e('0x18af')](_0x596a0e('0x17c4'),{'id':_0x6fb091[_0x596a0e('0x26cd')]()['userProfileId'],'section':_0x596a0e('0x262e'),'fields':_0x596a0e('0xeea'),'sort':_0x596a0e('0x14dc'),'createdAt':_0x5668e6[_0x596a0e('0x1024')](),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x30a4c8('0x21ef'),function(_0x2624e5,_0x25056a){const _0x5b49e5=_0x30a4c8;return _0x25056a[_0x5b49e5('0x1ac6')](_0x5b49e5('0xa7c'))?null:_0x2624e5[_0x5b49e5('0x18af')](_0x5b49e5('0x697'),{'fields':_0x5b49e5('0x686'),'id':_0x25056a[_0x5b49e5('0x26cd')]()[_0x5b49e5('0xb86')]});}],'userProfileSection':['apiResolver',_0x30a4c8('0x21ef'),function(_0x4d3ca8,_0x5a1ea4){const _0x4431d2=_0x30a4c8;return _0x5a1ea4[_0x4431d2('0x1ac6')](_0x4431d2('0xa7c'))?null:_0x4d3ca8[_0x4431d2('0x18af')](_0x4431d2('0xaf'),{'fields':_0x4431d2('0xe26'),'userProfileId':_0x5a1ea4[_0x4431d2('0x26cd')]()[_0x4431d2('0xb86')],'sectionId':0x198});}]},'authenticate':!![],'permissionId':0x198,'bodyClass':_0x30a4c8('0x21da')})['state']('app.voice.voiceRecordings.edit',{'url':_0x30a4c8('0x2233'),'params':{'voiceRecording':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x2b8aa9,'controller':'VoiceRecordingController\x20as\x20vm'}},'resolve':{'voiceRecording':[_0x30a4c8('0x1fbc'),_0x30a4c8('0xf75'),function(_0x32388a,_0x56b853){const _0x4f098f=_0x30a4c8;return _0x32388a[_0x4f098f('0x18af')]('voiceRecording@get',{'fields':_0x4f098f('0xeea'),'id':_0x56b853['id']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x906f90,_0x4c8e1f){const _0x2f0b07=_0x30a4c8;return _0x906f90[_0x2f0b07('0x18af')](_0x2f0b07('0xaf'),{'fields':_0x2f0b07('0xe26'),'userProfileId':_0x4c8e1f['getCurrentUser']()['userProfileId'],'sectionId':0x198});}]},'authenticate':!![],'permissionId':0x198,'bodyClass':_0x30a4c8('0x21da')})['state'](_0x30a4c8('0x1ec3'),{'url':_0x30a4c8('0xc9e'),'views':{'content@app':{'templateUrl':_0x4ded58,'controller':'ChanSpiesController\x20as\x20vm'}},'resolve':{'chanSpies':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x50a629,_0x418085){const _0x33696b=_0x30a4c8;return _0x418085[_0x33696b('0x1ac6')](_0x33696b('0xa7c'))?_0x50a629[_0x33696b('0x18af')](_0x33696b('0xec0'),{'fields':'createdAt,updatedAt,id,name,prefix,options,auth,password,record,recordingFormat,description','sort':_0x33696b('0x14dc'),'limit':0xa,'offset':0x0}):_0x50a629[_0x33696b('0x18af')](_0x33696b('0x17c4'),{'id':_0x418085[_0x33696b('0x26cd')]()[_0x33696b('0xb86')],'section':_0x33696b('0x61c'),'fields':_0x33696b('0x96b'),'sort':_0x33696b('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x3bba7b,_0x2ed035){const _0x14c13b=_0x30a4c8;return _0x2ed035['hasRole'](_0x14c13b('0xa7c'))?null:_0x3bba7b[_0x14c13b('0x18af')](_0x14c13b('0x697'),{'fields':_0x14c13b('0x686'),'id':_0x2ed035[_0x14c13b('0x26cd')]()[_0x14c13b('0xb86')]});}],'userProfileSection':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x3d90c7,_0x473e1b){const _0x3380ff=_0x30a4c8;return _0x473e1b[_0x3380ff('0x1ac6')](_0x3380ff('0xa7c'))?null:_0x3d90c7[_0x3380ff('0x18af')]('userProfileSection@get',{'fields':_0x3380ff('0xe26'),'userProfileId':_0x473e1b[_0x3380ff('0x26cd')]()[_0x3380ff('0xb86')],'sectionId':0x199});}]},'authenticate':!![],'permissionId':0x199,'bodyClass':_0x30a4c8('0x21da')})[_0x30a4c8('0x63f')](_0x30a4c8('0x2666'),{'url':'/voicePrefixes','views':{'content@app':{'templateUrl':_0x319936,'controller':_0x30a4c8('0x598')}},'resolve':{'voicePrefixes':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x44c1a4,_0x1efe3a){const _0x5d7f9=_0x30a4c8;return _0x1efe3a['hasRole'](_0x5d7f9('0xa7c'))?_0x44c1a4[_0x5d7f9('0x18af')]('voicePrefix@get',{'fields':_0x5d7f9('0x14fc'),'limit':0xa,'offset':0x0}):_0x44c1a4[_0x5d7f9('0x18af')](_0x5d7f9('0x17c4'),{'id':_0x1efe3a[_0x5d7f9('0x26cd')]()[_0x5d7f9('0xb86')],'section':'VoicePrefixes','fields':_0x5d7f9('0x14fc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x30a4c8('0x1fbc'),'Auth',function(_0x818a51,_0x596a77){const _0x36c903=_0x30a4c8;return _0x596a77[_0x36c903('0x1ac6')](_0x36c903('0xa7c'))?null:_0x818a51[_0x36c903('0x18af')](_0x36c903('0x697'),{'fields':_0x36c903('0x686'),'id':_0x596a77[_0x36c903('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x30a4c8('0x1fbc'),_0x30a4c8('0x21ef'),function(_0x2271e1,_0x1a92af){const _0x25be3a=_0x30a4c8;return _0x1a92af['hasRole']('admin')?null:_0x2271e1['resolve'](_0x25be3a('0xaf'),{'fields':_0x25be3a('0xe26'),'userProfileId':_0x1a92af[_0x25be3a('0x26cd')]()['userProfileId'],'sectionId':0x19a});}]},'authenticate':!![],'permissionId':0x19a,'bodyClass':_0x30a4c8('0x21da')}),_0xa27fa6[_0x30a4c8('0x95e')]('app/main/apps/voice');}angular[_0x36e6f4('0x896')](_0x36e6f4('0x62'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),'mdColorPicker','ckeditor',_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),'mdPickers','mwFormBuilder',_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),'angularMaterialFormBuilder',_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),'app.voice.realtime'])[_0x36e6f4('0xe11')](_0x1353f4)['controller'](_0x36e6f4('0x176c'),_0x14abd7)['controller'](_0x36e6f4('0x1130'),_0x365d64)[_0x36e6f4('0x75e')](_0x36e6f4('0x25c3'),_0x6810f2)[_0x36e6f4('0x75e')](_0x36e6f4('0x134f'),_0x18357b)[_0x36e6f4('0x75e')](_0x36e6f4('0xed8'),_0x216ace)['controller'](_0x36e6f4('0x1390'),_0x5ec5dd)[_0x36e6f4('0x75e')]('EditInboundAppagiDialogController',_0x1543a9)[_0x36e6f4('0x75e')]('EditInboundAppcustomDialogController',_0x2b9daa)[_0x36e6f4('0x75e')]('EditInboundAppdialDialogController',_0x80c61f)[_0x36e6f4('0x75e')](_0x36e6f4('0x778'),_0x2cbc39)['controller']('EditInboundAppgotoDialogController',_0x2a13a2)[_0x36e6f4('0x75e')]('EditInboundApphangupDialogController',_0x4a379c)['controller']('EditInboundAppinternaldialDialogController',_0x8587be)['controller'](_0x36e6f4('0x1b7'),_0x3ac19c)[_0x36e6f4('0x75e')](_0x36e6f4('0x1373'),_0x31a660)['controller'](_0x36e6f4('0x496'),_0x15ab86)['controller'](_0x36e6f4('0x2170'),_0x157c0a)[_0x36e6f4('0x75e')](_0x36e6f4('0x6a5'),_0x690de4)[_0x36e6f4('0x75e')](_0x36e6f4('0x23c6'),_0x3b9d7d)[_0x36e6f4('0x75e')](_0x36e6f4('0x11cb'),_0x1d28cc)[_0x36e6f4('0x75e')](_0x36e6f4('0x84a'),_0x3bbf0e)[_0x36e6f4('0x75e')]('CreateOrEditInternalRouteDialogController',_0x5f0d7e)[_0x36e6f4('0x75e')](_0x36e6f4('0x16e'),_0x2d076c)[_0x36e6f4('0x75e')](_0x36e6f4('0x2600'),_0x1ffaf9)[_0x36e6f4('0x75e')](_0x36e6f4('0xe5f'),_0x1b78b1)[_0x36e6f4('0x75e')](_0x36e6f4('0x177f'),_0x4f1c42)[_0x36e6f4('0x75e')](_0x36e6f4('0x1b8e'),_0xf87aa9)['controller'](_0x36e6f4('0x94a'),_0x268ed2)[_0x36e6f4('0x75e')](_0x36e6f4('0x216a'),_0x41f4e0)[_0x36e6f4('0x75e')](_0x36e6f4('0x147e'),_0x4a1a28)[_0x36e6f4('0x75e')](_0x36e6f4('0x2298'),_0x26a9fe)['controller'](_0x36e6f4('0x17c3'),_0x5900ff)['controller'](_0x36e6f4('0x4b7'),_0x257a05)[_0x36e6f4('0x75e')](_0x36e6f4('0x13fd'),_0x13deb9)[_0x36e6f4('0x75e')]('EditInternalAppsetDialogController',_0x4af344)['controller'](_0x36e6f4('0x1abb'),_0x36cd5a)[_0x36e6f4('0x75e')](_0x36e6f4('0x27a4'),_0x1e3e23)[_0x36e6f4('0x75e')](_0x36e6f4('0x767'),_0x40b932)[_0x36e6f4('0x75e')](_0x36e6f4('0x1c13'),_0x550e5f)[_0x36e6f4('0x75e')](_0x36e6f4('0xf21'),_0x26de84)['controller'](_0x36e6f4('0xb30'),_0x50cb0d)['controller']('MusicOnHoldController',_0xed8a75)[_0x36e6f4('0x75e')](_0x36e6f4('0xe13'),_0x34541f),angular[_0x36e6f4('0x896')](_0x36e6f4('0x62'))['controller'](_0x36e6f4('0x1086'),_0x4bcfa1)[_0x36e6f4('0x75e')](_0x36e6f4('0x26a9'),_0x3fd899)[_0x36e6f4('0x75e')]('EditoutboundAppcustomDialogController',_0x3504e3)[_0x36e6f4('0x75e')](_0x36e6f4('0x1f38'),_0x513f4d)[_0x36e6f4('0x75e')](_0x36e6f4('0xa9f'),_0xcb7b35)[_0x36e6f4('0x75e')]('OutboundRouteController',_0x5e9041)[_0x36e6f4('0x75e')]('OutboundRoutesController',_0x18a420)[_0x36e6f4('0x75e')](_0x36e6f4('0x3b1'),_0x44f1e7)[_0x36e6f4('0x75e')](_0x36e6f4('0x8b5'),_0x41aa53)[_0x36e6f4('0x75e')](_0x36e6f4('0x1460'),_0x81db1d)[_0x36e6f4('0x75e')]('VoicemailsController',_0x578073)[_0x36e6f4('0x75e')](_0x36e6f4('0x228'),_0x5dd88c)[_0x36e6f4('0x75e')](_0x36e6f4('0x4f8'),_0x59115b)['controller'](_0x36e6f4('0x15c0'),_0x2e522a)['controller'](_0x36e6f4('0x253d'),_0x53df2c)[_0x36e6f4('0x75e')](_0x36e6f4('0x2829'),_0xa4cb71)[_0x36e6f4('0x75e')](_0x36e6f4('0x25e8'),_0x4ffe0c)[_0x36e6f4('0x75e')](_0x36e6f4('0x1d88'),_0x1b2588)[_0x36e6f4('0x75e')](_0x36e6f4('0x1344'),_0xe704e)['controller'](_0x36e6f4('0x194d'),_0x3c4b8b)[_0x36e6f4('0x75e')](_0x36e6f4('0x1f85'),_0x342a14)[_0x36e6f4('0x75e')](_0x36e6f4('0x1a15'),_0x3836ce)[_0x36e6f4('0x75e')](_0x36e6f4('0x213a'),_0x44db08);const _0x5710d1=_0x2734b2['p']+'src/js/modules/main/apps/chat/views/chatQueues/chatQueues.html/chatQueues.html',_0x39e166=_0x2734b2['p']+_0x36e6f4('0x1b69'),_0x52e96b=_0x2734b2['p']+_0x36e6f4('0xfbb'),_0x1d738a=_0x2734b2['p']+_0x36e6f4('0x1158'),_0xaa4bec=_0x2734b2['p']+'src/js/modules/main/apps/chat/views/realtime/realtime.html/realtime.html',_0x20f042=_0x2734b2['p']+_0x36e6f4('0x1e93'),_0x5bfc38=_0x2734b2['p']+_0x36e6f4('0x152e');_0x493bf5[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$q',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x18bc'),_0x36e6f4('0xe29'),_0x36e6f4('0x1f7e'),_0x36e6f4('0x24b7'),_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1a02'),_0x36e6f4('0x7f'),'userProfileSection','Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0x10eb')];function _0x493bf5(_0xdc5d8,_0x502982,_0x4ef900,_0xba38d7,_0x51d415,_0x58f488,_0x34d6cb,_0x263875,_0x1e7d29,_0x23c25e,_0x8dad01,_0x228052,_0x1caa35,_0x100feb,_0x476d55,_0x3552df,_0x4a8861,_0x7400e7){const _0x833497=_0x36e6f4,_0x37f94d=this,_0x2f5ce0=['userpic',_0x833497('0xb41'),_0x833497('0x2318'),_0x833497('0x3dc'),'pauseType',_0x833497('0x3dc'),_0x833497('0x1eef'),_0x833497('0x16a6'),_0x833497('0x1c5c'),_0x833497('0x287f'),'mailPause','smsPause',_0x833497('0x11ee'),_0x833497('0x5aa'),_0x833497('0x2540'),_0x833497('0x6a8'),_0x833497('0x1b39'),_0x833497('0x18ae'),_0x833497('0x2627'),'whatsappCapacity',_0x833497('0x1462'),'chatCurrentCapacity',_0x833497('0x8cf'),_0x833497('0x82d'),_0x833497('0x1da1'),_0x833497('0x2681'),_0x833497('0x1ee6'),_0x833497('0x840'),_0x833497('0x1f33'),'mailStatus',_0x833497('0x1c1a'),'whatsappStatus','faxStatus',_0x833497('0x17e1'),_0x833497('0x1507'),_0x833497('0x43e'),'mailStatusTime',_0x833497('0x2357'),'whatsappStatusTime',_0x833497('0x4f3'),'voiceStatusTime','queue',_0x833497('0x1ad2'),_0x833497('0x158'),'phoneBarEnableScreenRecordingByAgent',_0x833497('0x1c5b')],_0x8ff5ad=[_0x833497('0x1c5c'),_0x833497('0x287f'),_0x833497('0xb4'),_0x833497('0x178d'),'whatsappPause',_0x833497('0x5aa'),_0x833497('0x2540'),'online'];_0x37f94d[_0x833497('0x98')]=_0x3552df[_0x833497('0x26cd')](),_0x37f94d[_0x833497('0xcdd')]=[_0x833497('0x1628'),_0x833497('0x133e'),_0x833497('0x2344'),_0x833497('0x158e'),_0x833497('0x521')],_0x37f94d[_0x833497('0xe29')]=_0x34d6cb||{'count':0x0,'rows':[]},_0x37f94d[_0x833497('0x5c9')]=_0x4a8861,_0x37f94d[_0x833497('0x7f')]=_0x100feb,_0x37f94d[_0x833497('0x17aa')]=_0x476d55&&_0x476d55['count']==0x1?_0x476d55['rows'][0x0]:null,_0x37f94d[_0x833497('0x243c')]=_0x3552df[_0x833497('0xd87')](_0x37f94d[_0x833497('0x17aa')]?_0x37f94d[_0x833497('0x17aa')][_0x833497('0x243c')]:null),_0x37f94d[_0x833497('0x1f7e')]=_0x263875?_0x2cfb05()[_0x833497('0x155c')](_0x263875[_0x833497('0x269a')]?_0x263875[_0x833497('0x269a')]:[],'id'):{},_0x37f94d[_0x833497('0x24b7')]=_0x1e7d29?_0x2cfb05()['keyBy'](_0x1e7d29['rows']?_0x1e7d29[_0x833497('0x269a')]:[],'id'):{},_0x37f94d['paginatedAgents']={},_0x37f94d[_0x833497('0x173f')]=![],_0x37f94d[_0x833497('0xa99')]=[],_0x37f94d[_0x833497('0x4c4')]={};for(const _0x241860 in _0x37f94d[_0x833497('0x1f7e')]){typeof _0x37f94d[_0x833497('0x1f7e')][_0x241860]!=='undefined'&&(_0x37f94d[_0x833497('0x1f7e')][_0x241860][_0x833497('0x24d5')]=!![]);}_0x37f94d['query']={'limit':0xa,'page':0x1,'order':_0x833497('0x6e1'),'globalStatusFilter':'','pauseTypeFilter':''},_0x37f94d[_0x833497('0x885')]=_0xe3773a,_0x37f94d[_0x833497('0xaf7')]=_0x4f18c2,_0x37f94d['pause']=_0x1f4d51,_0x37f94d['unPause']=_0x2e3987,_0x37f94d[_0x833497('0x6df')]=_0x1f5ca5,_0x37f94d[_0x833497('0x72f')]=_0x1c9890,_0x37f94d[_0x833497('0x28b5')]=_0xc630f2,_0x37f94d[_0x833497('0x882')]=_0xaa080a,_0x37f94d[_0x833497('0x5ad')]=_0x1aa733,_0x37f94d[_0x833497('0xb02')]=_0x4846f0,_0x37f94d[_0x833497('0x1303')]=_0x440c86,_0x37f94d[_0x833497('0x2232')]=_0x58967e,_0x37f94d[_0x833497('0xae0')]=_0x15e378,_0x37f94d[_0x833497('0x223a')]=_0x20c91c,_0x37f94d[_0x833497('0x1923')]=_0x472684,_0x37f94d[_0x833497('0x2845')]=_0xad29c5,_0x8dad01['on']('user:save',_0x37f94d[_0x833497('0x1303')]),_0x8dad01['on'](_0x833497('0x19d5'),_0x37f94d[_0x833497('0x2232')]),_0x8dad01['on'](_0x833497('0x10fc'),_0x37f94d[_0x833497('0x223a')]),_0x8dad01['on'](_0x833497('0x1c99'),_0x37f94d[_0x833497('0x1923')]),_0x15e378();let _0x497221=_0x7400e7(function(){const _0x3d6717=_0x833497;_0x37f94d[_0x3d6717('0x173f')]&&(_0x37f94d['load']=![],_0x15e378());},0x3e7);function _0x15e378(){const _0xc60b59=_0x833497;_0x37f94d[_0xc60b59('0x173f')]=![];const _0x8b514b=_0x502982['defer']();_0x37f94d[_0xc60b59('0x1f48')]=_0x8b514b['promise'],_0x37f94d[_0xc60b59('0x220b')]=[],_0x37f94d[_0xc60b59('0xa99')]=[],_0x2cfb05()['forIn'](_0x37f94d[_0xc60b59('0x1f7e')],function(_0x211021,_0x46532c){const _0x4752ae=_0xc60b59;_0x37f94d['rpcAgents'][_0x46532c]&&_0x2cfb05()[_0x4752ae('0xcc3')](_0x211021,_0x2cfb05()[_0x4752ae('0x1a08')](_0x2cfb05()[_0x4752ae('0x1414')](_0x37f94d['rpcAgents'][_0x46532c],_0x8ff5ad),_0x2f5ce0)),_0xc630f2(_0x211021),_0x211021['online']?(_0x37f94d[_0x4752ae('0x220b')][_0x4752ae('0x1514')](_0x211021),_0x37f94d[_0x4752ae('0x4c4')][_0x211021[_0x4752ae('0x1eef')]]=_0x46532c):_0x211021['globalStatusTime']=_0x2cfb05()[_0x4752ae('0xa53')](_0x24273b()()[_0x4752ae('0x128a')]('x'));});_0x37f94d[_0xc60b59('0x2218')][_0xc60b59('0xf4')]&&_0x2cfb05()[_0xc60b59('0x127f')](_0x37f94d[_0xc60b59('0x220b')],function(_0x3546f2){const _0x35de16=_0xc60b59;return _0x3546f2[_0x35de16('0xe34')]!==_0x37f94d[_0x35de16('0x2218')][_0x35de16('0xf4')];});_0x37f94d[_0xc60b59('0x2218')][_0xc60b59('0x2121')]&&_0x2cfb05()[_0xc60b59('0x127f')](_0x37f94d[_0xc60b59('0x220b')],function(_0x304a05){const _0x358cc1=_0xc60b59;return _0x304a05[_0x358cc1('0x246c')]!==_0x37f94d['query'][_0x358cc1('0x2121')];});_0x37f94d[_0xc60b59('0x2218')]['filter']&&_0x2cfb05()[_0xc60b59('0x127f')](_0x37f94d[_0xc60b59('0x220b')],function(_0x15d226){const _0x42af79=_0xc60b59;return _0x15d226[_0x42af79('0x6e1')]['toLowerCase']()[_0x42af79('0x2379')](_0x37f94d[_0x42af79('0x2218')][_0x42af79('0x1c33')]['toLowerCase']())<0x0;});_0x37f94d['filteredAgents']=_0x56e5e8(_0x37f94d['filteredAgents']);const _0x54cfc7=(_0x37f94d['query'][_0xc60b59('0x1a43')]-0x1)*_0x37f94d[_0xc60b59('0x2218')]['limit'];_0x37f94d['paginatedAgents']=_0x2cfb05()[_0xc60b59('0x3e5')](_0x37f94d['filteredAgents'],_0x54cfc7)[_0xc60b59('0x233')](0x0,_0x37f94d[_0xc60b59('0x2218')][_0xc60b59('0x163f')]);for(let _0x20f1a7=0x0;_0x20f1a7<_0x37f94d[_0xc60b59('0x5e5')][_0xc60b59('0x264b')];_0x20f1a7+=0x1){_0x37f94d[_0xc60b59('0xa99')]['push'](_0x37f94d['paginatedAgents'][_0x20f1a7]['id']);}_0x8b514b[_0xc60b59('0x18af')](),_0x37f94d[_0xc60b59('0x173f')]=!![];}function _0x440c86(_0x85028){const _0x1fa005=_0x833497;_0x37f94d[_0x1fa005('0x1f7e')][_0x85028['id']]&&(_0x2cfb05()[_0x1fa005('0xcc3')](_0x37f94d['agents'][_0x85028['id']],_0x2cfb05()[_0x1fa005('0x1a08')](_0x2cfb05()[_0x1fa005('0x1414')](_0x85028,_0x8ff5ad),_0x2f5ce0)),_0x2cfb05()[_0x1fa005('0xcc3')](_0x37f94d['rpcAgents'][_0x85028['id']],_0x2cfb05()[_0x1fa005('0x1a08')](_0x2cfb05()[_0x1fa005('0x1414')](_0x85028,_0x8ff5ad),_0x2f5ce0)),_0xc630f2(_0x37f94d['agents'][_0x85028['id']]));}function _0x58967e(_0x1e13dd){const _0x47440a=_0x833497;_0x37f94d['agents'][_0x1e13dd['id']]&&(_0x2cfb05()[_0x47440a('0xcc3')](_0x37f94d[_0x47440a('0x1f7e')][_0x1e13dd['id']],_0x2cfb05()['pick'](_0x1e13dd,_0x2f5ce0)),_0x2cfb05()[_0x47440a('0xcc3')](_0x37f94d['rpcAgents'][_0x1e13dd['id']],_0x2cfb05()[_0x47440a('0x1a08')](_0x1e13dd,_0x2f5ce0)),_0x1e13dd[_0x47440a('0x3dc')]&&(_0x37f94d[_0x47440a('0x1f7e')][_0x1e13dd['id']][_0x47440a('0x25b3')]=_0x1e13dd['lastPauseAt'],_0x37f94d[_0x47440a('0x24b7')][_0x1e13dd['id']][_0x47440a('0x25b3')]=_0x1e13dd['lastPauseAt']),_0xc630f2(_0x37f94d[_0x47440a('0x1f7e')][_0x1e13dd['id']]));}function _0x20c91c(_0x225f87){const _0x22f9f5=_0x833497;_0x37f94d[_0x22f9f5('0x1f7e')][_0x37f94d['agentInternal'][_0x225f87['destaccountcode']]]&&(_0x2cfb05()['merge'](_0x37f94d['agents'][_0x37f94d[_0x22f9f5('0x4c4')][_0x225f87[_0x22f9f5('0x25fc')]]],_0x2cfb05()[_0x22f9f5('0x1a08')](_0x225f87,[_0x22f9f5('0x1d3e'),_0x22f9f5('0x1ad2')])),_0x2cfb05()[_0x22f9f5('0xcc3')](_0x37f94d['rpcAgents'][_0x37f94d[_0x22f9f5('0x4c4')][_0x225f87[_0x22f9f5('0x25fc')]]],_0x2cfb05()[_0x22f9f5('0x1a08')](_0x225f87,[_0x22f9f5('0x1d3e'),_0x22f9f5('0x1ad2')])));}function _0x472684(_0x14572f){const _0x3bf7c5=_0x833497;_0x37f94d[_0x3bf7c5('0x1f7e')][_0x37f94d[_0x3bf7c5('0x4c4')][_0x14572f[_0x3bf7c5('0x25fc')]]]&&(_0x37f94d['agents'][_0x37f94d[_0x3bf7c5('0x4c4')][_0x14572f[_0x3bf7c5('0x25fc')]]]=_0x2cfb05()[_0x3bf7c5('0x1414')](_0x37f94d['agents'][_0x37f94d['agentInternal'][_0x14572f[_0x3bf7c5('0x25fc')]]],[_0x3bf7c5('0x1d3e'),_0x3bf7c5('0x1ad2')]),_0x37f94d[_0x3bf7c5('0x24b7')][_0x37f94d['agentInternal'][_0x14572f[_0x3bf7c5('0x25fc')]]]=_0x2cfb05()['omit'](_0x37f94d[_0x3bf7c5('0x24b7')][_0x37f94d[_0x3bf7c5('0x4c4')][_0x14572f[_0x3bf7c5('0x25fc')]]],[_0x3bf7c5('0x1d3e'),_0x3bf7c5('0x1ad2')]));}function _0xe3773a(_0x565391){const _0x1b16d0=_0x833497;return _0x23c25e[_0x1b16d0('0x557')][_0x1b16d0('0x885')]({'id':_0x565391['id'],'device':_0x1b16d0('0xf01'),'agent_id':_0x565391['id'],'agent_name':_0x565391[_0x1b16d0('0x4f0')]})[_0x1b16d0('0xa44')]['then'](function(){const _0x3f7af1=_0x1b16d0;_0x228052[_0x3f7af1('0x103b')]({'title':'Agent\x20logout','msg':_0x565391[_0x3f7af1('0x6e1')]+_0x3f7af1('0x22ec')}),_0x37f94d['agents'][_0x565391['id']]&&(_0x37f94d[_0x3f7af1('0x1f7e')][_0x565391['id']]['online']=![]),_0x37f94d['rpcAgents'][_0x565391['id']]&&(_0x37f94d[_0x3f7af1('0x24b7')][_0x565391['id']][_0x3f7af1('0xb41')]=![]),_0x15e378();})[_0x1b16d0('0x1a80')](function(_0xdd44a5){const _0x2e95ce=_0x1b16d0;_0x228052[_0x2e95ce('0xfc9')]({'title':_0xdd44a5[_0x2e95ce('0x52d')]?'API:'+_0xdd44a5[_0x2e95ce('0x52d')]+_0x2e95ce('0x11e1')+_0xdd44a5['statusText']:_0x2e95ce('0x1e3c'),'msg':_0xdd44a5[_0x2e95ce('0x25f4')]?JSON['stringify'](_0xdd44a5[_0x2e95ce('0x25f4')]['message']):_0xdd44a5[_0x2e95ce('0x1586')]()});});}function _0x1f4d51(_0x21da84,_0x2112c1){const _0x40a195=_0x833497;return _0x23c25e['user']['pause']({'id':_0x21da84['id'],'type':_0x2112c1})[_0x40a195('0xa44')][_0x40a195('0x1166')](function(_0x11f2c5){const _0x35afe8=_0x40a195;_0x37f94d[_0x35afe8('0x1f7e')][_0x21da84['id']]&&_0x2cfb05()[_0x35afe8('0xcc3')](_0x37f94d['agents'][_0x21da84['id']],_0x2cfb05()[_0x35afe8('0x1a08')](_0x11f2c5,_0x2f5ce0)),_0x37f94d[_0x35afe8('0x24b7')][_0x21da84['id']]&&_0x2cfb05()[_0x35afe8('0xcc3')](_0x37f94d[_0x35afe8('0x24b7')][_0x21da84['id']],_0x2cfb05()[_0x35afe8('0x1a08')](_0x11f2c5,_0x2f5ce0)),_0xc630f2(_0x37f94d['agents'][_0x21da84['id']]);})[_0x40a195('0x1a80')](function(_0x576dee){const _0x368adb=_0x40a195;_0x228052['error']({'title':_0x576dee[_0x368adb('0x52d')]?_0x368adb('0x1e21')+_0x576dee[_0x368adb('0x52d')]+_0x368adb('0x11e1')+_0x576dee['statusText']:_0x368adb('0x1e3c'),'msg':_0x576dee[_0x368adb('0x25f4')]?JSON[_0x368adb('0xbac')](_0x576dee['data'][_0x368adb('0x1e70')]):_0x576dee['toString']()});});}function _0x2e3987(_0x15d11f){const _0x352733=_0x833497;return _0x23c25e[_0x352733('0x557')][_0x352733('0x20eb')]({'id':_0x15d11f['id']})[_0x352733('0xa44')][_0x352733('0x1166')](function(_0x42e1c8){const _0x226e4a=_0x352733;_0x37f94d[_0x226e4a('0x1f7e')][_0x15d11f['id']]&&_0x2cfb05()[_0x226e4a('0xcc3')](_0x37f94d[_0x226e4a('0x1f7e')][_0x15d11f['id']],_0x2cfb05()[_0x226e4a('0x1a08')](_0x42e1c8,_0x2f5ce0)),_0x37f94d['rpcAgents'][_0x15d11f['id']]&&_0x2cfb05()[_0x226e4a('0xcc3')](_0x37f94d[_0x226e4a('0x24b7')][_0x15d11f['id']],_0x2cfb05()[_0x226e4a('0x1a08')](_0x42e1c8,_0x2f5ce0)),_0xc630f2(_0x37f94d[_0x226e4a('0x1f7e')][_0x15d11f['id']]);})['catch'](function(_0x53613f){const _0x1d4b70=_0x352733;_0x228052['error']({'title':_0x53613f['status']?'API:'+_0x53613f['status']+_0x1d4b70('0x11e1')+_0x53613f[_0x1d4b70('0xe1b')]:_0x1d4b70('0x1e3c'),'msg':_0x53613f['data']?JSON[_0x1d4b70('0xbac')](_0x53613f['data']['message']):_0x53613f[_0x1d4b70('0x1586')]()});});}function _0x1f5ca5(_0x3007ad){const _0x4a7988=_0x833497;_0xba38d7[_0x4a7988('0x1f80')](_0xba38d7[_0x4a7988('0x31d')]()['clickOutsideToClose'](!![])[_0x4a7988('0xcdc')](_0x4a7988('0x58a'))['htmlContent'](_0x4a7988('0x1174'))['ok']('Ok')[_0x4a7988('0x203b')](_0x3007ad));}function _0x4f18c2(_0x55070c,_0x371328){const _0x340a49=_0x833497;_0xba38d7[_0x340a49('0x1f80')]({'controller':_0x340a49('0xf19'),'controllerAs':'vm','templateUrl':_0x49c5be,'parent':angular[_0x340a49('0x1194')](_0x51d415[_0x340a49('0x8d2')]),'targetEvent':_0x371328,'clickOutsideToClose':!![],'locals':{'agent':_0x55070c,'agents':[],'channel':_0x340a49('0xde2'),'direction':_0x340a49('0x14d8'),'crudPermissions':_0x37f94d[_0x340a49('0x243c')]}});}function _0xaa080a(_0x3c62e1){const _0x2bfec2=_0x833497;return _0x3c62e1===_0x2bfec2('0x1e77')||_0x3c62e1==='*pause';}function _0x1aa733(_0xc5f8){return _0xc5f8==='pause';}function _0x4846f0(_0x50522e){const _0x664ee6=_0x833497;return _0x50522e===_0x664ee6('0x6e8');}function _0x1891d3(_0x23a272){const _0x1485c0=_0x833497;return _0x23a272===_0x1485c0('0xdb0')||_0x23a272===_0x1485c0('0x22d5')||_0x23a272===_0x1485c0('0x14dd')||_0x23a272===_0x1485c0('0x1628')||_0x2cfb05()[_0x1485c0('0x2863')](_0x23a272);}function _0x1c9890(_0x5ee68b,_0x530b1a){const _0x627d42=_0x833497;if(_0x530b1a==='voice'){if(_0x5ee68b[_0x530b1a+_0x627d42('0x28f6')]!==_0x627d42('0xdb0'))return _0x5ee68b[_0x530b1a+_0x627d42('0x28f6')];if(_0x5ee68b[_0x530b1a+_0x627d42('0x108')])return _0x5ee68b[_0x530b1a+_0x627d42('0x28f6')]=_0x627d42('0x1e77'),_0x627d42('0x1e77');return _0x627d42('0xdb0');}else{if(_0x5ee68b[_0x530b1a+'Pause'])return _0x5ee68b[_0x530b1a+'Status']='pause',_0x627d42('0x1e77');return _0x5ee68b[_0x530b1a+_0x627d42('0x28f6')];}}function _0xc630f2(_0x2ea47b){const _0x726912=_0x833497;let _0x1b2804=_0x726912('0x22d5');if(_0x2cfb05()[_0x726912('0x2285')]([_0x1c9890(_0x2ea47b,'voice'),_0x1c9890(_0x2ea47b,_0x726912('0xde2')),_0x1c9890(_0x2ea47b,_0x726912('0x1bfa')),_0x1c9890(_0x2ea47b,'openchannel'),_0x1c9890(_0x2ea47b,_0x726912('0x146c')),_0x1c9890(_0x2ea47b,_0x726912('0x116e')),_0x1c9890(_0x2ea47b,_0x726912('0x1fc7'))],_0xaa080a))_0x1b2804=_0x726912('0x1e77');else{if(_0x2cfb05()[_0x726912('0x1798')]([_0x1c9890(_0x2ea47b,_0x726912('0x21da')),_0x1c9890(_0x2ea47b,'chat'),_0x1c9890(_0x2ea47b,'mail'),_0x1c9890(_0x2ea47b,_0x726912('0x26c')),_0x1c9890(_0x2ea47b,_0x726912('0x146c')),_0x1c9890(_0x2ea47b,_0x726912('0x116e')),_0x1c9890(_0x2ea47b,_0x726912('0x1fc7'))],_0xaa080a))_0x1b2804=_0x726912('0x6e8');else _0x2cfb05()['every']([_0x1c9890(_0x2ea47b,_0x726912('0x21da')),_0x1c9890(_0x2ea47b,_0x726912('0xde2')),_0x1c9890(_0x2ea47b,'mail'),_0x1c9890(_0x2ea47b,_0x726912('0x26c')),_0x1c9890(_0x2ea47b,'sms'),_0x1c9890(_0x2ea47b,'whatsapp'),_0x1c9890(_0x2ea47b,_0x726912('0x1fc7'))],_0x1891d3)?_0x1b2804='idle':_0x1b2804='busy';}_0x2ea47b[_0x726912('0xe34')]!==_0x1b2804&&(_0x2ea47b[_0x726912('0xe34')]=_0x1b2804,_0x2ea47b[_0x726912('0x24d5')]?(_0x2ea47b[_0x726912('0x24d5')]=![],_0x2ea47b[_0x726912('0x25b3')]=_0xaa080a(_0x1b2804)?_0x2cfb05()['toNumber'](_0x24273b()(_0x2ea47b['lastPauseAt'])[_0x726912('0x128a')]('x')):_0x2cfb05()[_0x726912('0x28bc')]([_0x2ea47b[_0x726912('0x18c9')],_0x2ea47b['chatStatusTime'],_0x2ea47b[_0x726912('0x1955')],_0x2ea47b['smsStatusTime'],_0x2ea47b[_0x726912('0x11a8')],_0x2ea47b[_0x726912('0x43e')],_0x2ea47b[_0x726912('0x4f3')]])):_0x2ea47b[_0x726912('0x25b3')]=_0x2cfb05()[_0x726912('0xa53')](_0x24273b()()['format']('x')));}function _0x56e5e8(_0x5272a8){const _0x1c73d7=_0x833497,_0x3912e8=_0x2cfb05()[_0x1c73d7('0x1783')](_0x37f94d['query']['order'],'-')?'desc':_0x1c73d7('0x17d');return _0x2cfb05()[_0x1c73d7('0xe63')](_0x5272a8,[_0x37f94d[_0x1c73d7('0x2218')][_0x1c73d7('0xa99')]['replace']('-','')],[_0x3912e8]);}function _0x445e24(){const _0x3c8da0=_0x833497;_0x497221&&(_0x7400e7[_0x3c8da0('0x3f')](_0x497221),_0x497221=null);}function _0xad29c5(_0x15c0dd,_0x1440fd){const _0x1d855f=_0x833497;return _0x23c25e[_0x1d855f('0x557')][_0x1d855f('0x1449')]({'id':_0x15c0dd['id']},{'screenrecording':_0x1440fd})[_0x1d855f('0xa44')][_0x1d855f('0x1a80')](function(_0x3bd803){const _0x31d28c=_0x1d855f;_0x228052[_0x31d28c('0xfc9')]({'title':_0x3bd803[_0x31d28c('0x52d')]?'API:'+_0x3bd803[_0x31d28c('0x52d')]+_0x31d28c('0x11e1')+_0x3bd803[_0x31d28c('0xe1b')]:'api.user.update','msg':_0x3bd803[_0x31d28c('0x25f4')]?JSON[_0x31d28c('0xbac')](_0x3bd803['data'][_0x31d28c('0x1e70')]):_0x3bd803[_0x31d28c('0x1586')]()});});}_0xdc5d8['$on'](_0x833497('0x1c3f'),function(){const _0x38bc3b=_0x833497;_0x8dad01[_0x38bc3b('0x1800')](_0x38bc3b('0x26b2')),_0x8dad01[_0x38bc3b('0x1800')](_0x38bc3b('0x19d5')),_0x8dad01[_0x38bc3b('0x1800')](_0x38bc3b('0x10fc')),_0x8dad01[_0x38bc3b('0x1800')]('user:agentcomplete'),_0x445e24();});}const _0x29ace6=_0x493bf5,_0x4667b8=_0x2734b2['p']+_0x36e6f4('0x1b3b'),_0x1711ce=_0x2734b2['p']+'src/js/modules/main/apps/chat/views/chatQueues/edit/agentadd/agentadd.html/agentadd.html';_0x34a326[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$timeout','$mdDialog','$q',_0x36e6f4('0x1c90'),'$interval',_0x36e6f4('0x7a7'),_0x36e6f4('0x744'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),'toasty',_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x21ef')];function _0x34a326(_0x3a2170,_0x44928e,_0x3c55ef,_0x590eaa,_0x176449,_0x17c357,_0x1f2d6b,_0x5f174a,_0x26cf09,_0x5e3179,_0x38468f,_0x213fb4,_0x4f6393,_0x38d77e){const _0x2e2b9d=_0x36e6f4,_0x240a4f=this,_0x325b75=[_0x2e2b9d('0x1570'),_0x2e2b9d('0x44b'),'waiting',_0x2e2b9d('0x46a'),_0x2e2b9d('0x67d'),'originated','message',_0x2e2b9d('0x6c9'),'dialMethod',_0x2e2b9d('0x14c4'),_0x2e2b9d('0x18b')];_0x240a4f['currentUser']=_0x38d77e[_0x2e2b9d('0x26cd')](),_0x240a4f[_0x2e2b9d('0x240f')]=_0x1f2d6b[_0x2e2b9d('0x240f')]?_0x1f2d6b[_0x2e2b9d('0x240f')]:0x0,_0x240a4f[_0x2e2b9d('0x7a7')]=_0x1f2d6b?_0x2cfb05()[_0x2e2b9d('0x155c')](_0x1f2d6b['rows']?_0x1f2d6b[_0x2e2b9d('0x269a')]:[],'id'):{},_0x240a4f[_0x2e2b9d('0x744')]=_0x5f174a?_0x2cfb05()[_0x2e2b9d('0x155c')](_0x5f174a[_0x2e2b9d('0x269a')]?_0x5f174a[_0x2e2b9d('0x269a')]:[],'id'):{},_0x240a4f[_0x2e2b9d('0x7f')]=_0x213fb4,_0x240a4f['userProfileSection']=_0x4f6393&&_0x4f6393['count']==0x1?_0x4f6393[_0x2e2b9d('0x269a')][0x0]:null,_0x240a4f[_0x2e2b9d('0x243c')]=_0x38d77e[_0x2e2b9d('0xd87')](_0x240a4f[_0x2e2b9d('0x17aa')]?_0x240a4f[_0x2e2b9d('0x17aa')]['crudPermissions']:null);_0x38d77e[_0x2e2b9d('0x1ac6')]('admin')?_0x240a4f[_0x2e2b9d('0x2218')]={'type':_0x2e2b9d('0x14d8'),'sort':_0x2e2b9d('0x14dc'),'limit':0xa,'page':0x1}:_0x240a4f[_0x2e2b9d('0x2218')]={'id':_0x240a4f[_0x2e2b9d('0x98')]['id'],'channel':_0x2e2b9d('0xde2'),'type':_0x2e2b9d('0x14d8'),'sort':_0x2e2b9d('0x14dc'),'limit':0xa,'page':0x1};_0x240a4f[_0x2e2b9d('0x103b')]=_0x3a1b73,_0x240a4f[_0x2e2b9d('0x152a')]=_0x29bd60,_0x240a4f[_0x2e2b9d('0x93f')]=_0x3258b4,_0x240a4f[_0x2e2b9d('0x33f')]=_0x2b739e,_0x240a4f[_0x2e2b9d('0xeba')]=_0x5e2ac8,_0x240a4f[_0x2e2b9d('0x1303')]=_0xf348ad,_0x240a4f[_0x2e2b9d('0xfb')]=_0xde9a0e,_0x240a4f[_0x2e2b9d('0xfe9')]=_0x58e8a1,_0x240a4f['onPause']=_0x548c6f,_0x240a4f[_0x2e2b9d('0xb9a')]=_0x40f56d,_0x240a4f[_0x2e2b9d('0x1696')]=_0x19eeff,_0x240a4f[_0x2e2b9d('0x1089')]=_0x5413ec,_0x240a4f[_0x2e2b9d('0xa99')]=[],_0x2cfb05()[_0x2e2b9d('0x941')](_0x240a4f[_0x2e2b9d('0x7a7')],function(_0xc86ac7){const _0x415079=_0x2e2b9d;_0x240a4f[_0x415079('0xa99')][_0x415079('0x1514')](_0xc86ac7['id']);}),_0x5e3179['on'](_0x2e2b9d('0x612'),_0x240a4f[_0x2e2b9d('0x1303')]),_0x5e3179['on'](_0x2e2b9d('0x268e'),_0x240a4f['onSaveMember']),_0x5e3179['on']('userChatQueue:remove',_0x240a4f[_0x2e2b9d('0xfe9')]),_0x5e3179['on'](_0x2e2b9d('0x19d5'),_0x240a4f[_0x2e2b9d('0x212c')]),_0x5e3179['on']('userVoiceQueue:remove',_0x240a4f[_0x2e2b9d('0x1696')]),_0x5e3179['on'](_0x2e2b9d('0x663'),_0x240a4f[_0x2e2b9d('0xb9a')]);function _0x5413ec(){const _0x3994b6=_0x2e2b9d,_0xbd495a=[];return _0x2cfb05()['forIn'](_0x240a4f['queues'],function(_0x43fa6c,_0x25ad9f){const _0x5b5a67=a0_0x3f2c;_0x43fa6c[_0x5b5a67('0x18b')]=0x0,_0x43fa6c['loggedInDb']=0x0,_0x240a4f['queues'][_0x25ad9f][_0x5b5a67('0x1f7e')]={},_0xbd495a[_0x5b5a67('0x1514')](_0x26cf09[_0x5b5a67('0x1e45')][_0x5b5a67('0x27d1')]({'id':_0x25ad9f})[_0x5b5a67('0xa44')]),_0x240a4f[_0x5b5a67('0x744')][_0x25ad9f]&&_0x2cfb05()[_0x5b5a67('0xcc3')](_0x43fa6c,_0x2cfb05()[_0x5b5a67('0x1a08')](_0x240a4f[_0x5b5a67('0x744')][_0x25ad9f],_0x325b75));}),_0x590eaa[_0x3994b6('0x2760')](_0xbd495a)['then'](function(_0x24ecbe){const _0x4e02a0=_0x3994b6;for(let _0x3f5cad=0x0;_0x3f5cad<_0x24ecbe[_0x4e02a0('0x264b')];_0x3f5cad+=0x1){for(let _0x5a9eba=0x0;_0x5a9eba<_0x24ecbe[_0x3f5cad][_0x4e02a0('0x269a')][_0x4e02a0('0x264b')];_0x5a9eba++){_0x24ecbe[_0x3f5cad]['rows'][_0x5a9eba][_0x4e02a0('0x18b')]&&_0x240a4f[_0x4e02a0('0x7a7')][_0x24ecbe[_0x3f5cad]['rows'][_0x5a9eba][_0x4e02a0('0x23f7')]][_0x4e02a0('0x18b')]++,_0x240a4f['queues'][_0x24ecbe[_0x3f5cad][_0x4e02a0('0x269a')][_0x5a9eba][_0x4e02a0('0x23f7')]][_0x4e02a0('0x2689')]++,_0x240a4f[_0x4e02a0('0x7a7')][_0x24ecbe[_0x3f5cad]['rows'][_0x5a9eba][_0x4e02a0('0x23f7')]]['agents'][_0x24ecbe[_0x3f5cad][_0x4e02a0('0x269a')][_0x5a9eba]['UserId']]=_0x24ecbe[_0x3f5cad]['rows'][_0x5a9eba]['ChatQueueId'];}}})['catch'](function(_0x22b925){const _0x36e9c3=_0x3994b6;console[_0x36e9c3('0xfc9')](_0x22b925);});}function _0xf348ad(_0xa9437f){const _0x1234f3=_0x2e2b9d;_0x240a4f['queues'][_0xa9437f['id']]&&_0x2cfb05()[_0x1234f3('0xcc3')](_0x240a4f['queues'][_0xa9437f['id']],_0x2cfb05()[_0x1234f3('0x1a08')](_0xa9437f,_0x325b75));}function _0xde9a0e(_0x15cc35){const _0x1c9f6c=_0x2e2b9d;_0x240a4f[_0x1c9f6c('0x7a7')][_0x15cc35[_0x1c9f6c('0x23f7')]]&&_0x240a4f['queues'][_0x15cc35[_0x1c9f6c('0x23f7')]][_0x1c9f6c('0x2689')]++;}function _0x58e8a1(_0x3ce3ed){const _0x2fd52c=_0x2e2b9d;_0x240a4f['queues'][_0x3ce3ed['ChatQueueId']]&&_0x240a4f[_0x2fd52c('0x7a7')][_0x3ce3ed[_0x2fd52c('0x23f7')]][_0x2fd52c('0x2689')]--;}function _0x548c6f(_0x268bc1){const _0x3468a5=_0x2e2b9d;console[_0x3468a5('0x455')](_0x3468a5('0x212c'),_0x268bc1);if(_0x268bc1[_0x3468a5('0x2540')])_0x2cfb05()['forIn'](_0x240a4f[_0x3468a5('0x7a7')],function(_0x4c0110){const _0x255a37=_0x3468a5;_0x4c0110[_0x255a37('0x1f7e')][_0x268bc1['id']]&&(_0x4c0110['paused']+=0x1,console[_0x255a37('0x455')](_0x255a37('0x1e77')));});else!_0x268bc1[_0x3468a5('0x2540')]&&_0x2cfb05()[_0x3468a5('0x941')](_0x240a4f['queues'],function(_0x4723ce){const _0x587afe=_0x3468a5;_0x4723ce[_0x587afe('0x1f7e')][_0x268bc1['id']]&&(_0x4723ce['paused']>0x0&&(_0x4723ce['paused']-=0x1,console[_0x587afe('0x455')](_0x587afe('0x20eb'))));});}function _0x40f56d(_0x2d3da7){const _0x3f48c1=_0x2e2b9d;console['log'](_0x3f48c1('0x26c1'),_0x2d3da7),_0x240a4f[_0x3f48c1('0x7a7')][_0x2d3da7[_0x3f48c1('0x23f7')]]&&(_0x240a4f[_0x3f48c1('0x7a7')][_0x2d3da7['ChatQueueId']][_0x3f48c1('0x2689')]+=0x1,_0x240a4f['queues'][_0x2d3da7['ChatQueueId']][_0x3f48c1('0x1f7e')][_0x2d3da7['UserId']]=_0x2d3da7[_0x3f48c1('0x23f7')]);}function _0x19eeff(_0x596ef6){const _0x58f315=_0x2e2b9d;console[_0x58f315('0x455')](_0x58f315('0x1696'),_0x596ef6),_0x240a4f['queues'][_0x596ef6['ChatQueueId']]&&_0x240a4f[_0x58f315('0x7a7')][_0x596ef6[_0x58f315('0x23f7')]][_0x58f315('0x2689')]>0x0&&(_0x240a4f[_0x58f315('0x7a7')][_0x596ef6[_0x58f315('0x23f7')]]['loggedInDb']-=0x1,delete _0x240a4f[_0x58f315('0x7a7')][_0x596ef6[_0x58f315('0x23f7')]][_0x58f315('0x1f7e')][_0x596ef6[_0x58f315('0x122a')]]);}let _0x2a1f77=!![],_0x2d68d6=0x1;_0x3a2170[_0x2e2b9d('0xe83')](_0x2e2b9d('0x12d8'),function(_0x5aa9b0,_0x47f0d0){const _0x430012=_0x2e2b9d;_0x2a1f77?_0x44928e(function(){_0x2a1f77=![];}):(!_0x47f0d0&&(_0x2d68d6=_0x240a4f[_0x430012('0x2218')][_0x430012('0x1a43')]),_0x5aa9b0!==_0x47f0d0&&(_0x240a4f['query'][_0x430012('0x1a43')]=0x1),!_0x5aa9b0&&(_0x240a4f[_0x430012('0x2218')][_0x430012('0x1a43')]=_0x2d68d6),_0x240a4f[_0x430012('0x152a')]());});function _0x3a1b73(_0x7cff92){const _0x3dab23=_0x2e2b9d;_0x240a4f['count']=_0x7cff92[_0x3dab23('0x240f')],_0x240a4f[_0x3dab23('0x7a7')]=_0x7cff92?_0x2cfb05()[_0x3dab23('0x155c')](_0x7cff92[_0x3dab23('0x269a')]?_0x7cff92[_0x3dab23('0x269a')]:[],'id'):{};if(_0x7cff92[_0x3dab23('0x269a')]){_0x240a4f['order']=[];for(let _0x1d868d=0x0;_0x1d868d<_0x7cff92[_0x3dab23('0x269a')]['length'];_0x1d868d++){_0x240a4f[_0x3dab23('0xa99')]['push'](_0x7cff92['rows'][_0x1d868d]['id']);}}_0x5413ec();}function _0x29bd60(){const _0x594450=_0x2e2b9d;_0x240a4f[_0x594450('0x2218')]['offset']=(_0x240a4f[_0x594450('0x2218')][_0x594450('0x1a43')]-0x1)*_0x240a4f['query']['limit'],_0x38d77e[_0x594450('0x1ac6')](_0x594450('0xa7c'))?_0x240a4f[_0x594450('0x1f48')]=_0x26cf09[_0x594450('0x1e45')][_0x594450('0xd83')](_0x240a4f['query'],_0x3a1b73)['$promise']:(_0x240a4f[_0x594450('0x2218')]['id']=_0x240a4f['userProfile']['id'],_0x240a4f['query'][_0x594450('0xe60')]=_0x594450('0x1858'),_0x240a4f['promise']=_0x26cf09[_0x594450('0x7f')]['getResources'](_0x240a4f[_0x594450('0x2218')],_0x3a1b73)[_0x594450('0xa44')]);}function _0x3258b4(_0x80976f,_0x1e1c25){const _0x286d5e=_0x2e2b9d;_0x3c55ef[_0x286d5e('0x1f80')]({'controller':_0x286d5e('0x415'),'controllerAs':'vm','templateUrl':_0x4667b8,'parent':angular[_0x286d5e('0x1194')](_0x176449[_0x286d5e('0x8d2')]),'targetEvent':_0x80976f,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x1e1c25,'chatQueues':_0x2cfb05()['values'](_0x240a4f['queues']),'license':null,'setting':null,'crudPermissions':_0x240a4f[_0x286d5e('0x243c')]}});}function _0x2b739e(_0x517dab,_0x4bf20b){const _0x14b582=_0x2e2b9d;_0x3c55ef[_0x14b582('0x1f80')]({'controller':_0x14b582('0x1e46'),'controllerAs':'vm','templateUrl':_0x1711ce,'parent':angular['element'](_0x176449[_0x14b582('0x8d2')]),'targetEvent':_0x517dab,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x4bf20b,'chatQueues':_0x240a4f[_0x14b582('0x7a7')]?_0x240a4f[_0x14b582('0x7a7')][_0x14b582('0x269a')]:[],'realtime':![],'crudPermissions':_0x240a4f['crudPermissions']}});}function _0x5e2ac8(_0x2eed63){const _0x36148c=_0x2e2b9d;return _0x26cf09[_0x36148c('0x1e45')][_0x36148c('0x1449')](_0x2eed63)[_0x36148c('0xa44')]['then'](function(){const _0x39aa7c=_0x36148c;_0x38468f['success']({'title':_0x39aa7c('0x75b'),'msg':_0x2eed63[_0x39aa7c('0x4f0')]?_0x2eed63['name']+_0x39aa7c('0xa17'):''});})[_0x36148c('0x1a80')](function(_0x33bea6){const _0x4fa11a=_0x36148c;_0x38468f[_0x4fa11a('0xfc9')]({'title':_0x4fa11a('0xa98'),'msg':_0x33bea6[_0x4fa11a('0x1e70')]});});}_0x3a2170[_0x2e2b9d('0x3d2')](_0x2e2b9d('0x1c3f'),function(){const _0x3cecf9=_0x2e2b9d;_0x5e3179[_0x3cecf9('0x1800')](_0x3cecf9('0x612')),_0x5e3179[_0x3cecf9('0x1800')]('userChatQueue:remove'),_0x5e3179[_0x3cecf9('0x1800')]('userChatQueue:save'),_0x5e3179[_0x3cecf9('0x1800')](_0x3cecf9('0x19d5')),_0x5e3179['removeAllListeners'](_0x3cecf9('0x25f0')),_0x5e3179[_0x3cecf9('0x1800')](_0x3cecf9('0x663'));});}const _0x40107a=_0x34a326;function _0x22fba8(){const _0x56203f=_0x36e6f4;return{'status':{'registered':'green-300-fg\x20icon-checkbox-marked-circle','unregistered':_0x56203f('0x278f'),'lagged':_0x56203f('0x278f'),'reachable':_0x56203f('0x23ca'),'unreachable':_0x56203f('0x278f'),'unknown':'grey-fg\x20icon-minus-circle'},'state':{'unknown':'grey-fg\x20icon-phone-hangup','not_inuse':_0x56203f('0xa1e'),'inuse':'red-300-fg\x20icon-phone-in-talk','busy':'red-300-fg\x20icon-phone-locked','invalid':_0x56203f('0x1d48'),'unavailable':_0x56203f('0x1d48'),'ringing':_0x56203f('0x132c'),'ringinuse':_0x56203f('0x132c'),'onhold':'blue-300-fg\x20icon-phone-paused'},'channelStatus':{'ring':_0x56203f('0x132c'),'up':'green-300-fg\x20icon-phone-in-talk','hangup':'red-300-fg\x20icon-phone-hangup'},'channelStatusOut':{'ring':_0x56203f('0xac'),'up':_0x56203f('0x20b2'),'hangup':_0x56203f('0x9e3')}};}const _0x2acfb2=_0x22fba8;_0x11524e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'socket'];function _0x11524e(_0x99951a,_0xad48fd,_0x54b38e){const _0x24f6c1=_0x36e6f4,_0x316134=this;_0x54b38e[_0x24f6c1('0x670')](),_0x54b38e[_0x24f6c1('0x7bb')](),_0x316134[_0x24f6c1('0x2669')]=0x0;switch(_0xad48fd['current'][_0x24f6c1('0x4f0')]){case _0x24f6c1('0x1d0'):_0x316134[_0x24f6c1('0x2669')]=0x0;break;case _0x24f6c1('0x41'):_0x316134[_0x24f6c1('0x2669')]=0x1;break;default:_0x316134[_0x24f6c1('0x2669')]=0x0,_0xad48fd['go'](_0x24f6c1('0x1d0'));}_0x99951a[_0x24f6c1('0xe83')](_0x24f6c1('0x27a7'),function(_0x538d3a,_0x575c77){const _0x2e694e=_0x24f6c1;if(_0x538d3a!==_0x575c77)switch(_0x538d3a){case 0x0:_0xad48fd['go'](_0x2e694e('0x1d0'));break;case 0x1:_0xad48fd['go']('app.chat.realtime.queues');break;default:_0xad48fd['go'](_0x2e694e('0x1d0'));}});}const _0x36cb79=_0x11524e;_0x520e21[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x520e21(_0x5ac66d){const _0x53ae97=_0x36e6f4;_0x5ac66d[_0x53ae97('0x63f')]('app.chat.realtime',{'url':_0x53ae97('0x1c2e'),'views':{'content@app':{'templateUrl':_0xaa4bec,'controller':_0x53ae97('0x2454')}},'resolve':{'userProfile':[_0x53ae97('0x1fbc'),'Auth',function(_0x3f61e,_0x256fb1){const _0x16e0bd=_0x53ae97;return _0x256fb1['hasRole'](_0x16e0bd('0xa7c'))?null:_0x3f61e['resolve'](_0x16e0bd('0x697'),{'fields':'id,name,crudPermissions','id':_0x256fb1[_0x16e0bd('0x26cd')]()[_0x16e0bd('0xb86')]});}],'userProfileSection':[_0x53ae97('0x1fbc'),_0x53ae97('0x21ef'),function(_0x5df906,_0x4971b9){const _0x56ded1=_0x53ae97;return _0x4971b9[_0x56ded1('0x1ac6')](_0x56ded1('0xa7c'))?null:_0x5df906[_0x56ded1('0x18af')](_0x56ded1('0xaf'),{'fields':_0x56ded1('0xe26'),'userProfileId':_0x4971b9[_0x56ded1('0x26cd')]()['userProfileId'],'sectionId':0x1fe});}]},'authenticate':!![],'permissionId':0x1fe})[_0x53ae97('0x63f')](_0x53ae97('0x1d0'),{'url':'/agents','controller':_0x53ae97('0x2557'),'templateUrl':_0x20f042,'resolve':{'pauses':['apiResolver',function(_0x543f4c){const _0x48518c=_0x53ae97;return _0x543f4c[_0x48518c('0x18af')](_0x48518c('0x737'),{'nolimit':!![]});}],'agents':[_0x53ae97('0x1fbc'),_0x53ae97('0x21ef'),function(_0x35bfbd,_0x5bc451){const _0x850ff=_0x53ae97;return _0x5bc451[_0x850ff('0x1ac6')](_0x850ff('0xa7c'))?_0x35bfbd['resolve'](_0x850ff('0x1c80'),{'fields':_0x850ff('0x1746'),'role':_0x850ff('0x1eff'),'sort':_0x850ff('0x6e1'),'nolimit':!![]}):_0x35bfbd[_0x850ff('0x18af')]('userProfile@getResources',{'id':_0x5bc451['getCurrentUser']()[_0x850ff('0xb86')],'section':_0x850ff('0x2391'),'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0x850ff('0x1eff'),'sort':_0x850ff('0x6e1'),'nolimit':!![]});}],'userProfile':[_0x53ae97('0x1fbc'),_0x53ae97('0x21ef'),function(_0x19b9f8,_0x4a280e){const _0x216017=_0x53ae97;return _0x4a280e[_0x216017('0x1ac6')](_0x216017('0xa7c'))?null:_0x19b9f8[_0x216017('0x18af')]('userProfile@get',{'fields':_0x216017('0x686'),'id':_0x4a280e[_0x216017('0x26cd')]()['userProfileId']});}],'userProfileSection':['apiResolver',_0x53ae97('0x21ef'),function(_0x98404e,_0x21c1e8){const _0x4bb509=_0x53ae97;return _0x21c1e8['hasRole'](_0x4bb509('0xa7c'))?null:_0x98404e[_0x4bb509('0x18af')]('userProfileSection@get',{'fields':_0x4bb509('0xe26'),'userProfileId':_0x21c1e8[_0x4bb509('0x26cd')]()[_0x4bb509('0xb86')],'sectionId':0xca});}],'rpcAgents':['apiResolver',function(_0x35434d){const _0x24d50f=_0x53ae97;return _0x35434d[_0x24d50f('0x18af')](_0x24d50f('0xfab'));}]},'authenticate':!![],'permissionId':0x1fe})[_0x53ae97('0x63f')](_0x53ae97('0x41'),{'url':'/queues','controller':_0x53ae97('0x21ab'),'templateUrl':_0x5bfc38,'resolve':{'queues':[_0x53ae97('0x1fbc'),_0x53ae97('0x21ef'),function(_0x1b3a2c,_0x3a75a4){const _0x1e2315=_0x53ae97;return _0x3a75a4[_0x1e2315('0x1ac6')](_0x1e2315('0xa7c'))?_0x1b3a2c[_0x1e2315('0x18af')](_0x1e2315('0x2479'),{'type':_0x1e2315('0x14d8'),'sort':_0x1e2315('0x14dc'),'limit':0xa,'offset':0x0}):_0x1b3a2c['resolve'](_0x1e2315('0x17c4'),{'id':_0x3a75a4[_0x1e2315('0x26cd')]()[_0x1e2315('0xb86')],'section':_0x1e2315('0x1858'),'channel':_0x1e2315('0xde2'),'type':_0x1e2315('0x14d8'),'sort':'-updatedAt','limit':0xa,'page':0x1});}],'userProfile':[_0x53ae97('0x1fbc'),'Auth',function(_0x290df5,_0x2f1283){const _0x391669=_0x53ae97;return _0x2f1283[_0x391669('0x1ac6')](_0x391669('0xa7c'))?null:_0x290df5['resolve'](_0x391669('0x697'),{'fields':'id,name,crudPermissions','id':_0x2f1283['getCurrentUser']()[_0x391669('0xb86')]});}],'userProfileSection':[_0x53ae97('0x1fbc'),'Auth',function(_0x20f126,_0x2f0810){const _0x294e5c=_0x53ae97;return _0x2f0810[_0x294e5c('0x1ac6')](_0x294e5c('0xa7c'))?null:_0x20f126[_0x294e5c('0x18af')]('userProfileSection@get',{'fields':_0x294e5c('0xe26'),'userProfileId':_0x2f0810['getCurrentUser']()[_0x294e5c('0xb86')],'sectionId':0x1f5});}],'rpcQueues':['apiResolver',function(_0x757d66){const _0x44e052=_0x53ae97;return _0x757d66['resolve'](_0x44e052('0x846'));}]},'authenticate':!![],'permissionId':0x1fe});}angular['module'](_0x36e6f4('0x286f'),[])[_0x36e6f4('0xe11')](_0x520e21)['controller'](_0x36e6f4('0x280d'),_0x29ace6)[_0x36e6f4('0x75e')](_0x36e6f4('0x1836'),_0x40107a)[_0x36e6f4('0x87c')](_0x36e6f4('0x1a02'),_0x2acfb2)[_0x36e6f4('0x75e')](_0x36e6f4('0x26bf'),_0x36cb79);const _0x14046a=_0x2734b2['p']+'src/js/modules/main/apps/chat/views/chatQueues/edit/teamadd/teamadd.html/teamadd.html';_0x572211[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$mdSidenav',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x3a1'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x572211(_0xfaa7d7,_0x2d6c05,_0x1fc0fa,_0x1b52ea,_0x38876e,_0x358c6a,_0x5f1f63,_0x27f427,_0xc1c155,_0xa33b35,_0x5ae2a1,_0xb50f73,_0x30ccfe,_0x480071,_0xd50177,_0x1d9482,_0x3b24fb){const _0x157eb6=_0x36e6f4,_0x559cbb=this;_0x559cbb[_0x157eb6('0x5c9')]=_0x1d9482,_0x559cbb[_0x157eb6('0xf8a')]=_0x3b24fb,_0x559cbb[_0x157eb6('0x98')]=_0xd50177[_0x157eb6('0x26cd')](),_0x559cbb[_0x157eb6('0x3a1')]=_0xc1c155||{'count':0x0,'rows':[]},_0x559cbb[_0x157eb6('0x7f')]=_0xa33b35,_0x559cbb[_0x157eb6('0x17aa')]=_0x5ae2a1&&_0x5ae2a1['count']==0x1?_0x5ae2a1[_0x157eb6('0x269a')][0x0]:null,_0x559cbb[_0x157eb6('0x243c')]=_0xd50177[_0x157eb6('0xd87')](_0x559cbb['userProfileSection']?_0x559cbb[_0x157eb6('0x17aa')]['crudPermissions']:null),_0x559cbb[_0x157eb6('0x916')]=_0x157eb6('0x3a1'),_0x559cbb[_0x157eb6('0xef5')]='',_0x559cbb[_0x157eb6('0x104c')]=null,_0x559cbb['selectedChatQueues']=[],_0x559cbb[_0x157eb6('0x2218')]={'fields':_0x157eb6('0xf26'),'sort':_0x157eb6('0x14dc'),'channel':_0x157eb6('0xde2'),'limit':0xa,'page':0x1},_0x559cbb['arraystrategy']=_0x2cfb05()[_0x157eb6('0x155c')]([{'option':_0x157eb6('0xb16'),'value':_0x157eb6('0x1792')},{'option':_0x157eb6('0x75'),'value':_0x157eb6('0x11ad')}],function(_0x3109fe){const _0x425578=_0x157eb6;return _0x2cfb05()[_0x425578('0xf3')](_0x3109fe[_0x425578('0x18e0')],new RegExp('\x27','g'),'');}),_0x559cbb[_0x157eb6('0x1ff6')]=_0x5a9c70,_0x559cbb[_0x157eb6('0x292')]=_0x279b01,_0x559cbb['agentadddialog']=_0x29a092,_0x559cbb[_0x157eb6('0x8d8')]=_0x3bbbbc,_0x559cbb[_0x157eb6('0x182d')]=_0x410c11,_0x559cbb[_0x157eb6('0x103b')]=_0xcc9449,_0x559cbb['getChatQueues']=_0x397c8e,_0x559cbb[_0x157eb6('0x93f')]=_0x4611c3,_0x559cbb['deleteChatQueue']=_0x2a7852,_0x559cbb['exportSelectedChatQueues']=_0x1155a3,_0x559cbb[_0x157eb6('0x1169')]=_0x463fbd,_0x559cbb['deselectChatQueues']=_0x2d365d,_0x559cbb[_0x157eb6('0x7d1')]=_0x49c943;function _0x5a9c70(_0x34f271){const _0x1f6e42=_0x157eb6;_0x1fc0fa['go'](_0x1f6e42('0x285a'),{'id':_0x34f271['id'],'chatQueue':_0x34f271,'crudPermissions':_0x559cbb[_0x1f6e42('0x243c')]});}function _0x279b01(_0x28bf0e,_0x11412e){const _0xb29da7=_0x157eb6;_0x38876e['show']({'controller':'ChatQueueteamaddController','controllerAs':'vm','templateUrl':_0x14046a,'parent':angular['element'](_0x358c6a[_0xb29da7('0x8d2')]),'targetEvent':_0x11412e,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x28bf0e,'chatQueues':_0x559cbb[_0xb29da7('0x3a1')]?_0x559cbb[_0xb29da7('0x3a1')][_0xb29da7('0x269a')]:[],'crudPermissions':_0x559cbb[_0xb29da7('0x243c')]}});}function _0x29a092(_0x8fa775,_0x153d03){const _0x177787=_0x157eb6;_0x38876e[_0x177787('0x1f80')]({'controller':_0x177787('0x1e46'),'controllerAs':'vm','templateUrl':_0x1711ce,'parent':angular[_0x177787('0x1194')](_0x358c6a[_0x177787('0x8d2')]),'targetEvent':_0x153d03,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x8fa775,'chatQueues':_0x559cbb[_0x177787('0x3a1')]?_0x559cbb[_0x177787('0x3a1')][_0x177787('0x269a')]:[],'crudPermissions':_0x559cbb[_0x177787('0x243c')],'realtime':![]}});}function _0x3bbbbc(_0x2b145a,_0x1cc02c){const _0x5eef14=_0x157eb6,_0x4c20db=_0x38876e[_0x5eef14('0x1d26')]()[_0x5eef14('0xcdc')](_0x5eef14('0x288d')+_0x2cfb05()[_0x5eef14('0xb35')]('chatQueue')+'?')[_0x5eef14('0xf3c')](_0x5eef14('0x12b5')+(_0x2b145a[_0x5eef14('0x4f0')]||_0x5eef14('0x1e45'))+_0x5eef14('0xace')+_0x5eef14('0x3f3'))[_0x5eef14('0x8e8')]('delete\x20chatQueue')[_0x5eef14('0x203b')](_0x1cc02c)['ok']('OK')['cancel'](_0x5eef14('0x2d3'));_0x38876e['show'](_0x4c20db)[_0x5eef14('0x1166')](function(){_0x2a7852(_0x2b145a);},function(){const _0x4ea9da=_0x5eef14;console[_0x4ea9da('0x455')](_0x4ea9da('0x2d3'));});}function _0x410c11(){const _0x4140a0=_0x157eb6;if(_0xd50177[_0x4140a0('0x1ac6')](_0x4140a0('0xa7c')))_0x1fc0fa['go'](_0x4140a0('0x41'),{});else return _0xb50f73[_0x4140a0('0x17aa')]['get']({'userProfileId':_0xd50177[_0x4140a0('0x26cd')]()[_0x4140a0('0xb86')],'sectionId':0x1fe})[_0x4140a0('0xa44')][_0x4140a0('0x1166')](function(_0x481d30){const _0x1d6b15=_0x4140a0,_0x3566ab=_0x481d30&&_0x481d30[_0x1d6b15('0x269a')]?_0x481d30[_0x1d6b15('0x269a')][0x0]:null;_0x3566ab&&_0x3566ab['enabled']?_0x1fc0fa['go'](_0x1d6b15('0x41'),{}):_0x480071['info']({'title':_0x27f427['instant']('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x27f427['instant'](_0x1d6b15('0x2642'))});})[_0x4140a0('0x1a80')](function(_0x42edb0){const _0x2acd8b=_0x4140a0;_0x480071[_0x2acd8b('0xfc9')]({'title':_0x42edb0[_0x2acd8b('0x52d')]?'API:'+_0x42edb0[_0x2acd8b('0x52d')]+_0x2acd8b('0x11e1')+_0x42edb0['statusText']:_0x2acd8b('0x153e'),'msg':_0x42edb0[_0x2acd8b('0x52d')]?JSON[_0x2acd8b('0xbac')](_0x42edb0['data']):_0x42edb0[_0x2acd8b('0x1586')]()});});}let _0xbb3ab0=!![],_0x4e3459=0x1;_0xfaa7d7[_0x157eb6('0xe83')]('vm.query.filter',function(_0x682962,_0x94292){const _0x2bbd71=_0x157eb6;_0xbb3ab0?_0x5f1f63(function(){_0xbb3ab0=![];}):(!_0x94292&&(_0x4e3459=_0x559cbb['query'][_0x2bbd71('0x1a43')]),_0x682962!==_0x94292&&(_0x559cbb[_0x2bbd71('0x2218')][_0x2bbd71('0x1a43')]=0x1),!_0x682962&&(_0x559cbb[_0x2bbd71('0x2218')][_0x2bbd71('0x1a43')]=_0x4e3459),_0x559cbb['getChatQueues']());});function _0xcc9449(_0x19e42f){const _0x2f7f4f=_0x157eb6;_0x559cbb[_0x2f7f4f('0x3a1')]=_0x19e42f||{'count':0x0,'rows':[]};}function _0x397c8e(){const _0x5ce702=_0x157eb6;_0x559cbb[_0x5ce702('0x2218')][_0x5ce702('0x1098')]=(_0x559cbb[_0x5ce702('0x2218')]['page']-0x1)*_0x559cbb[_0x5ce702('0x2218')][_0x5ce702('0x163f')],_0xd50177[_0x5ce702('0x1ac6')](_0x5ce702('0xa7c'))?_0x559cbb[_0x5ce702('0x1f48')]=_0xb50f73[_0x5ce702('0x1e45')]['get'](_0x559cbb['query'],_0xcc9449)[_0x5ce702('0xa44')]:(_0x559cbb[_0x5ce702('0x2218')]['id']=_0x559cbb['userProfile']['id'],_0x559cbb['query'][_0x5ce702('0xe60')]='ChatQueues',_0x559cbb[_0x5ce702('0x1f48')]=_0xb50f73[_0x5ce702('0x7f')][_0x5ce702('0x263a')](_0x559cbb['query'],_0xcc9449)['$promise']);}function _0x4611c3(_0x1b1076,_0xc30a53){const _0x2475db=_0x157eb6;_0x38876e['show']({'controller':'CreateOrEditChatQueueDialogController','controllerAs':'vm','templateUrl':_0x4667b8,'parent':angular['element'](_0x358c6a[_0x2475db('0x8d2')]),'targetEvent':_0x1b1076,'clickOutsideToClose':!![],'locals':{'chatQueue':_0xc30a53,'chatQueues':_0x559cbb[_0x2475db('0x3a1')][_0x2475db('0x269a')],'license':_0x559cbb[_0x2475db('0x5c9')],'setting':_0x559cbb[_0x2475db('0xf8a')],'crudPermissions':_0x559cbb[_0x2475db('0x243c')]}});}function _0x2a7852(_0x5c1887){const _0x87f016=_0x157eb6;_0xb50f73['chatQueue']['delete']({'id':_0x5c1887['id']})[_0x87f016('0xa44')][_0x87f016('0x1166')](function(){const _0x367fc7=_0x87f016;_0x2cfb05()[_0x367fc7('0x127f')](_0x559cbb[_0x367fc7('0x3a1')]['rows'],{'id':_0x5c1887['id']}),_0x559cbb['chatQueues'][_0x367fc7('0x240f')]-=0x1,!_0x559cbb['chatQueues'][_0x367fc7('0x269a')]['length']&&_0x559cbb['getChatQueues'](),_0x480071[_0x367fc7('0x103b')]({'title':_0x2cfb05()['startCase'](_0x367fc7('0x1b96'))+_0x367fc7('0x2b6'),'msg':_0x5c1887[_0x367fc7('0x4f0')]?_0x5c1887[_0x367fc7('0x4f0')]+_0x367fc7('0x7cd'):''});})[_0x87f016('0x1a80')](function(_0x46c83b){const _0x420bb2=_0x87f016;if(_0x46c83b[_0x420bb2('0x25f4')]&&_0x46c83b['data'][_0x420bb2('0x61a')]&&_0x46c83b['data']['errors'][_0x420bb2('0x264b')]){_0x559cbb['errors']=_0x46c83b[_0x420bb2('0x25f4')][_0x420bb2('0x61a')]||[{'message':_0x46c83b[_0x420bb2('0x1586')](),'type':_0x420bb2('0x2432')}];for(let _0x42786b=0x0;_0x42786b<_0x46c83b[_0x420bb2('0x25f4')]['errors']['length'];_0x42786b++){_0x480071[_0x420bb2('0xfc9')]({'title':_0x46c83b[_0x420bb2('0x25f4')]['errors'][_0x42786b][_0x420bb2('0x1345')],'msg':_0x46c83b[_0x420bb2('0x25f4')][_0x420bb2('0x61a')][_0x42786b][_0x420bb2('0x1e70')]});}}else _0x480071['error']({'title':_0x46c83b[_0x420bb2('0x52d')]?'API:'+_0x46c83b[_0x420bb2('0x52d')]+_0x420bb2('0x11e1')+_0x46c83b[_0x420bb2('0xe1b')]:_0x420bb2('0x2432'),'msg':_0x46c83b[_0x420bb2('0x25f4')]?JSON['stringify'](_0x46c83b[_0x420bb2('0x25f4')][_0x420bb2('0x1e70')]):_0x46c83b['message']||_0x46c83b[_0x420bb2('0x1586')]()});});}function _0x1155a3(){const _0x50a5e7=_0x157eb6,_0x56921f=angular[_0x50a5e7('0x225f')](_0x559cbb[_0x50a5e7('0xf92')]);return _0x559cbb[_0x50a5e7('0xf92')]=[],_0x56921f;}function _0x463fbd(_0x200f28){const _0x21baf1=_0x157eb6,_0x1cf68a=_0x38876e[_0x21baf1('0x1d26')]()[_0x21baf1('0xcdc')](_0x21baf1('0xdcd'))[_0x21baf1('0xf3c')](_0x21baf1('0x12b5')+_0x559cbb['selectedChatQueues'][_0x21baf1('0x264b')]+_0x21baf1('0x196d')+_0x21baf1('0x3f3'))[_0x21baf1('0x8e8')](_0x21baf1('0x194c'))['targetEvent'](_0x200f28)['ok']('OK')[_0x21baf1('0x3f')]('CANCEL');_0x38876e[_0x21baf1('0x1f80')](_0x1cf68a)['then'](function(){const _0x302368=_0x21baf1;_0x559cbb[_0x302368('0xf92')]['forEach'](function(_0x1eafa1){_0x2a7852(_0x1eafa1);}),_0x559cbb[_0x302368('0xf92')]=[];});}function _0x2d365d(){const _0x202e0c=_0x157eb6;_0x559cbb[_0x202e0c('0xf92')]=[];}function _0x49c943(){const _0x1dda3f=_0x157eb6;_0x559cbb[_0x1dda3f('0xf92')]=_0x559cbb['chatQueues'][_0x1dda3f('0x269a')];}}const _0x3c59f7=_0x572211;_0x361450['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location','$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'chatQueues',_0x36e6f4('0x1e45'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'crudPermissions'];function _0x361450(_0x3176ef,_0x24a453,_0x23209d,_0x414ddf,_0x420e55,_0x46fc7c,_0xa96018,_0x196c20,_0x5ba648,_0x24e6bd,_0x3816bd,_0x1c05b1,_0x4f4565,_0x444883){const _0x428d78=_0x36e6f4,_0x4d308b=this;_0x4d308b['currentUser']=_0x3816bd[_0x428d78('0x26cd')](),_0x4d308b[_0x428d78('0x61a')]=[],_0x4d308b[_0x428d78('0xf8a')]=_0x4f4565,_0x4d308b['license']=_0x1c05b1,_0x4d308b[_0x428d78('0x243c')]=_0x444883,_0x4d308b[_0x428d78('0x128b')]={},_0x4d308b[_0x428d78('0x2900')]=_0x4d308b[_0x428d78('0xf8a')]&&_0x4d308b[_0x428d78('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4d308b[_0x428d78('0xcdc')]=_0x428d78('0xe5b'),_0x4d308b[_0x428d78('0x1e45')]=angular[_0x428d78('0x225f')](_0x5ba648),_0x4d308b[_0x428d78('0x3a1')]=_0x196c20,_0x4d308b[_0x428d78('0x2a2')]=![];!_0x4d308b[_0x428d78('0x1e45')]&&(_0x4d308b[_0x428d78('0x1e45')]={'strategy':_0x428d78('0x278c'),'timeout':0xa},_0x4d308b['title']=_0x428d78('0x1846'),_0x4d308b['newChatQueue']=!![]);_0x4d308b['addNewChatQueue']=_0x31c507,_0x4d308b[_0x428d78('0x1a64')]=_0x263edd,_0x4d308b[_0x428d78('0x1aef')]=_0x4cffdb,_0x4d308b['getDateFromString']=_0x589de0,_0x4d308b['closeDialog']=_0x250d67;function _0x31c507(){const _0xd20cd=_0x428d78;_0x4d308b[_0xd20cd('0x61a')]=[],_0x24e6bd[_0xd20cd('0x1e45')][_0xd20cd('0x9cc')](_0x4d308b[_0xd20cd('0x1e45')])[_0xd20cd('0xa44')][_0xd20cd('0x1166')](function(_0x44048d){const _0x3277f6=_0xd20cd;_0x4d308b[_0x3277f6('0x3a1')][_0x3277f6('0x2450')](_0x44048d[_0x3277f6('0x2876')]()),_0xa96018['success']({'title':_0x3277f6('0x1f47'),'msg':_0x4d308b[_0x3277f6('0x1e45')][_0x3277f6('0x4f0')]?_0x4d308b[_0x3277f6('0x1e45')][_0x3277f6('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x250d67(_0x44048d);})[_0xd20cd('0x1a80')](function(_0x1ce26e){const _0x16dd6c=_0xd20cd;if(_0x1ce26e[_0x16dd6c('0x25f4')]&&_0x1ce26e['data']['errors']&&_0x1ce26e[_0x16dd6c('0x25f4')][_0x16dd6c('0x61a')][_0x16dd6c('0x264b')]){_0x4d308b[_0x16dd6c('0x61a')]=_0x1ce26e['data'][_0x16dd6c('0x61a')]||[{'message':_0x1ce26e[_0x16dd6c('0x1586')](),'type':_0x16dd6c('0x154f')}];for(let _0x2c1afb=0x0;_0x2c1afb<_0x1ce26e[_0x16dd6c('0x25f4')][_0x16dd6c('0x61a')][_0x16dd6c('0x264b')];_0x2c1afb+=0x1){_0xa96018[_0x16dd6c('0xfc9')]({'title':_0x1ce26e[_0x16dd6c('0x25f4')][_0x16dd6c('0x61a')][_0x2c1afb][_0x16dd6c('0x1345')],'msg':_0x1ce26e[_0x16dd6c('0x25f4')][_0x16dd6c('0x61a')][_0x2c1afb][_0x16dd6c('0x1e70')]});}}else _0xa96018[_0x16dd6c('0xfc9')]({'title':_0x1ce26e[_0x16dd6c('0x52d')]?_0x16dd6c('0x1e21')+_0x1ce26e[_0x16dd6c('0x52d')]+_0x16dd6c('0x11e1')+_0x1ce26e[_0x16dd6c('0xe1b')]:_0x16dd6c('0x154f'),'msg':_0x1ce26e[_0x16dd6c('0x25f4')]?JSON[_0x16dd6c('0xbac')](_0x1ce26e[_0x16dd6c('0x25f4')][_0x16dd6c('0x1e70')]):_0x1ce26e['toString']()});});}function _0x263edd(){const _0x3b93b5=_0x428d78;_0x4d308b[_0x3b93b5('0x61a')]=[],_0x24e6bd[_0x3b93b5('0x1e45')][_0x3b93b5('0x1449')]({'id':_0x4d308b[_0x3b93b5('0x1e45')]['id']},_0x4d308b[_0x3b93b5('0x1e45')])[_0x3b93b5('0xa44')][_0x3b93b5('0x1166')](function(_0x4278e7){const _0x38b1c4=_0x3b93b5,_0x45a955=_0x2cfb05()[_0x38b1c4('0xc38')](_0x4d308b['chatQueues'],{'id':_0x4278e7['id']});_0x45a955&&_0x2cfb05()[_0x38b1c4('0xcc3')](_0x45a955,_0x2cfb05()[_0x38b1c4('0x1a08')](_0x4278e7[_0x38b1c4('0x2876')](),_0x2cfb05()[_0x38b1c4('0x14a4')](_0x45a955))),_0xa96018[_0x38b1c4('0x103b')]({'title':_0x38b1c4('0xf78'),'msg':_0x4d308b[_0x38b1c4('0x1e45')][_0x38b1c4('0x4f0')]?_0x4d308b[_0x38b1c4('0x1e45')][_0x38b1c4('0x4f0')]+_0x38b1c4('0x7d'):''}),_0x250d67(_0x4278e7);})[_0x3b93b5('0x1a80')](function(_0x41e8e4){const _0x3bb8e1=_0x3b93b5;if(_0x41e8e4[_0x3bb8e1('0x25f4')]&&_0x41e8e4['data'][_0x3bb8e1('0x61a')]&&_0x41e8e4[_0x3bb8e1('0x25f4')]['errors'][_0x3bb8e1('0x264b')]){_0x4d308b[_0x3bb8e1('0x61a')]=_0x41e8e4['data']['errors']||[{'message':_0x41e8e4[_0x3bb8e1('0x1586')](),'type':_0x3bb8e1('0x1b9f')}];for(let _0x12d713=0x0;_0x12d713<_0x41e8e4[_0x3bb8e1('0x25f4')][_0x3bb8e1('0x61a')][_0x3bb8e1('0x264b')];_0x12d713++){_0xa96018['error']({'title':_0x41e8e4[_0x3bb8e1('0x25f4')][_0x3bb8e1('0x61a')][_0x12d713][_0x3bb8e1('0x1345')],'msg':_0x41e8e4[_0x3bb8e1('0x25f4')]['errors'][_0x12d713][_0x3bb8e1('0x1e70')]});}}else _0xa96018['error']({'title':_0x41e8e4[_0x3bb8e1('0x52d')]?_0x3bb8e1('0x1e21')+_0x41e8e4['status']+_0x3bb8e1('0x11e1')+_0x41e8e4[_0x3bb8e1('0xe1b')]:_0x3bb8e1('0x1b9f'),'msg':_0x41e8e4[_0x3bb8e1('0x25f4')]?JSON[_0x3bb8e1('0xbac')](_0x41e8e4[_0x3bb8e1('0x25f4')][_0x3bb8e1('0x1e70')]):_0x41e8e4['toString']()});});}function _0x4cffdb(_0x21b84e){const _0xef96ad=_0x428d78;_0x4d308b[_0xef96ad('0x61a')]=[];const _0x584f45=_0x414ddf['confirm']()['title'](_0xef96ad('0x7fb'))[_0xef96ad('0xacc')](_0xef96ad('0x1045'))['ariaLabel']('Delete\x20ChatQueue')['ok'](_0xef96ad('0x18'))[_0xef96ad('0x3f')]('Cancel')[_0xef96ad('0x203b')](_0x21b84e);_0x414ddf['show'](_0x584f45)['then'](function(){const _0x1ac491=_0xef96ad;_0x24e6bd[_0x1ac491('0x1e45')][_0x1ac491('0x906')]({'id':_0x4d308b[_0x1ac491('0x1e45')]['id']})['$promise'][_0x1ac491('0x1166')](function(){const _0x1133fe=_0x1ac491;_0x2cfb05()['remove'](_0x4d308b['chatQueues'],{'id':_0x4d308b['chatQueue']['id']}),_0xa96018['success']({'title':_0x1133fe('0x23b3'),'msg':(_0x4d308b[_0x1133fe('0x1e45')][_0x1133fe('0x4f0')]||_0x1133fe('0x1e45'))+_0x1133fe('0x7cd')}),_0x250d67(_0x4d308b[_0x1133fe('0x1e45')]);})['catch'](function(_0x5c6c12){const _0x300ec5=_0x1ac491;if(_0x5c6c12[_0x300ec5('0x25f4')]&&_0x5c6c12['data'][_0x300ec5('0x61a')]&&_0x5c6c12[_0x300ec5('0x25f4')]['errors'][_0x300ec5('0x264b')]){_0x4d308b['errors']=_0x5c6c12[_0x300ec5('0x25f4')][_0x300ec5('0x61a')]||[{'message':_0x5c6c12[_0x300ec5('0x1586')](),'type':_0x300ec5('0x154c')}];for(let _0x490caf=0x0;_0x490caf<_0x5c6c12['data'][_0x300ec5('0x61a')][_0x300ec5('0x264b')];_0x490caf++){_0xa96018[_0x300ec5('0xfc9')]({'title':_0x5c6c12['data']['errors'][_0x490caf]['type'],'msg':_0x5c6c12[_0x300ec5('0x25f4')][_0x300ec5('0x61a')][_0x490caf]['message']});}}else _0xa96018[_0x300ec5('0xfc9')]({'title':_0x5c6c12[_0x300ec5('0x52d')]?_0x300ec5('0x1e21')+_0x5c6c12[_0x300ec5('0x52d')]+_0x300ec5('0x11e1')+_0x5c6c12[_0x300ec5('0xe1b')]:_0x300ec5('0x154c'),'msg':_0x5c6c12[_0x300ec5('0x25f4')]?JSON[_0x300ec5('0xbac')](_0x5c6c12[_0x300ec5('0x25f4')][_0x300ec5('0x1e70')]):_0x5c6c12[_0x300ec5('0x1e70')]||_0x5c6c12[_0x300ec5('0x1586')]()});});},function(){});}function _0x589de0(_0x1e1c02){return _0x1e1c02===null?undefined:new Date(_0x1e1c02);}function _0x250d67(_0x2feca1){_0x414ddf['hide'](_0x2feca1);}}const _0x5efdea=_0x361450;_0x5f1409[_0x36e6f4('0x1294')]=['$mdDialog','$q','toasty','api',_0x36e6f4('0x1e45'),_0x36e6f4('0x3a1'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x5f1409(_0xe08b32,_0x11d16a,_0x4e0c0a,_0x170740,_0x1efd2e,_0x1ca818,_0x5cde83,_0x2e185b,_0x2d0df7,_0x51e5ad){const _0x273405=_0x36e6f4,_0x11b096=this;_0x11b096[_0x273405('0x98')]=_0x2d0df7['getCurrentUser'](),_0x11b096[_0x273405('0x1e45')]=_0x1efd2e,_0x11b096[_0x273405('0x243c')]=_0x51e5ad,_0x11b096[_0x273405('0xf01')]=_0x5cde83,_0x11b096[_0x273405('0xbd7')]=[],_0x11b096['allowedItems']=[],_0x11b096['selectedItems']=[],_0x11b096['startingAllowedItems']=[],_0x11b096['startingSelectedItems']=[],_0x11b096[_0x273405('0x14d7')]=![],_0x11b096['onInit']=_0x387bd6,_0x11b096['saveAgents']=_0x4b1426,_0x11b096[_0x273405('0x24a0')]=_0x339ae8,_0x11b096['dualMultiselectOptions']={'readOnly':!_0x11b096[_0x273405('0x243c')][_0x273405('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x273405('0x4f0'),'line1':_0x273405('0x6e1'),'line2':[_0x273405('0x4f0'),'internal'],'line3':'','labelAll':_0x2e185b[_0x273405('0x25cc')](_0x273405('0x958')),'labelSelected':_0x2e185b[_0x273405('0x25cc')](_0x273405('0x14db')),'transferCallback':function(){const _0x198857=_0x273405,_0x635820=_0x2cfb05()[_0x198857('0x2802')](_0x11b096['startingSelectedItems'],_0x11b096['selectedItems'],'id');_0x11b096['pendingChanges']=_0x2cfb05()[_0x198857('0x1081')](_0x635820)?![]:!![];}};function _0x387bd6(){const _0x401401=_0x273405;return _0x2d0df7[_0x401401('0x1ac6')](_0x401401('0xa7c'))?_0x13cb87()['catch'](function(_0x1b92b6){const _0x38697d=_0x401401;_0x4e0c0a[_0x38697d('0xfc9')]({'title':_0x1b92b6['status']?_0x38697d('0x1e21')+_0x1b92b6['status']+_0x38697d('0x11e1')+_0x1b92b6[_0x38697d('0xe1b')]:_0x38697d('0xd4c'),'msg':_0x1b92b6[_0x38697d('0x52d')]?JSON[_0x38697d('0xbac')](_0x1b92b6[_0x38697d('0x25f4')]):_0x1b92b6[_0x38697d('0x1586')]()});}):_0x1a2878()[_0x401401('0x1166')](function(_0x2800f1){const _0x30f697=_0x401401;return _0x11b096[_0x30f697('0xe60')]=_0x2800f1,_0x13cb87();})[_0x401401('0x1a80')](function(_0x2fef5c){const _0x3d1675=_0x401401;_0x4e0c0a[_0x3d1675('0xfc9')]({'title':_0x2fef5c['status']?_0x3d1675('0x1e21')+_0x2fef5c['status']+_0x3d1675('0x11e1')+_0x2fef5c[_0x3d1675('0xe1b')]:'SYSTEM:GET_AGENTS','msg':_0x2fef5c[_0x3d1675('0x52d')]?JSON['stringify'](_0x2fef5c[_0x3d1675('0x25f4')]):_0x2fef5c[_0x3d1675('0x1586')]()});});}function _0x1a2878(){return _0x11d16a(function(_0x14be07,_0x4418d6){const _0x38a826=a0_0x3f2c;_0x170740[_0x38a826('0x17aa')]['get']({'userProfileId':_0x11b096[_0x38a826('0x98')][_0x38a826('0xb86')],'name':_0x38a826('0x2391')})[_0x38a826('0xa44')]['then'](function(_0x41e96a){const _0x31352d=_0x38a826,_0x45d5d7=_0x41e96a&&_0x41e96a[_0x31352d('0x269a')]?_0x41e96a['rows'][0x0]:null;_0x14be07(_0x45d5d7);})[_0x38a826('0x1a80')](function(_0x494d5e){_0x4418d6(_0x494d5e);});});}function _0x13cb87(){return _0x11d16a(function(_0x57d895,_0x402b7c){const _0x37ef58=a0_0x3f2c;return _0x132490()[_0x37ef58('0x1166')](function(_0x355339){const _0x2f4615=_0x37ef58;return _0x11b096[_0x2f4615('0xbd7')]=_0x355339[_0x2f4615('0x269a')]?_0x355339[_0x2f4615('0x269a')]:[],_0x2d0df7[_0x2f4615('0x1ac6')](_0x2f4615('0xa7c'))?_0x355339:_0x11b096[_0x2f4615('0xe60')]?_0x11b096[_0x2f4615('0xe60')][_0x2f4615('0x1a2b')]?_0x355339:_0x575b83():null;})[_0x37ef58('0x1166')](function(_0x1d892a){const _0x2a981e=_0x37ef58,_0x17206a=_0x1d892a&&_0x1d892a[_0x2a981e('0x269a')]?_0x1d892a[_0x2a981e('0x269a')]:[];return _0x11b096[_0x2a981e('0x10ab')]=_0x2cfb05()[_0x2a981e('0x2563')](_0x17206a,function(_0x1ce564){const _0x1d5911=_0x2a981e;return _0x2cfb05()[_0x1d5911('0xc38')](_0x11b096[_0x1d5911('0xbd7')],{'id':_0x2d0df7[_0x1d5911('0x1ac6')](_0x1d5911('0xa7c'))||_0x11b096[_0x1d5911('0xe60')]['autoAssociation']?_0x1ce564['id']:_0x1ce564[_0x1d5911('0x24e8')]});}),_0x11b096[_0x2a981e('0x2111')]=angular[_0x2a981e('0x225f')](_0x11b096[_0x2a981e('0x10ab')]),_0x11b096[_0x2a981e('0xbd7')]['forEach'](function(_0x55530e){const _0x2db2d0=_0x2a981e,_0x6a098=_0x2cfb05()[_0x2db2d0('0xc38')](_0x11b096[_0x2db2d0('0x10ab')],{'id':_0x55530e['id']});_0x2d0df7[_0x2db2d0('0x1ac6')](_0x2db2d0('0xa7c'))?_0x55530e[_0x2db2d0('0x26ef')]=!![]:_0x55530e[_0x2db2d0('0x26ef')]=typeof _0x6a098!==_0x2db2d0('0x1048')?!![]:![];}),_0x495685();})[_0x37ef58('0x1166')](function(_0x47a9f1){const _0x2aafa5=_0x37ef58,_0x65dffb=_0x47a9f1&&_0x47a9f1[_0x2aafa5('0x269a')]?_0x47a9f1[_0x2aafa5('0x269a')]:[];_0x11b096[_0x2aafa5('0x18e1')]=_0x2cfb05()['map'](_0x65dffb,function(_0x2f0935){const _0xe44f8b=_0x2aafa5,_0x4c3118=_0x2cfb05()[_0xe44f8b('0xc38')](_0x11b096['items'],{'id':_0x2f0935['id']});return _0x4c3118[_0xe44f8b('0x23af')]=_0x2f0935[_0xe44f8b('0x1325')]?'penalty\x20'+_0x2f0935[_0xe44f8b('0x1325')][_0xe44f8b('0x23af')]:'',_0x4c3118[_0xe44f8b('0x1eef')]=typeof _0x2f0935[_0xe44f8b('0x1eef')]!==_0xe44f8b('0x1048')?'<'+_0x2f0935[_0xe44f8b('0x1eef')]+'>':'',_0x4c3118;}),_0x11b096[_0x2aafa5('0x2781')]=angular[_0x2aafa5('0x225f')](_0x11b096[_0x2aafa5('0x18e1')]),_0x11b096[_0x2aafa5('0xc68')][_0x2aafa5('0x18e1')]=_0x11b096[_0x2aafa5('0x18e1')],_0x11b096[_0x2aafa5('0xc68')]['items']=_0x2cfb05()[_0x2aafa5('0x24ac')](_0x11b096[_0x2aafa5('0x10ab')],_0x11b096[_0x2aafa5('0xc68')]['selectedItems'],'id'),_0x57d895();})[_0x37ef58('0x1a80')](function(_0x17631c){_0x402b7c(_0x17631c);});});}function _0x575b83(){return _0x11d16a(function(_0x70c395,_0xb62376){const _0x60e93d=a0_0x3f2c;return _0x170740[_0x60e93d('0x4b5')]['get']({'sectionId':_0x11b096['section']['id'],'nolimit':!![]})[_0x60e93d('0xa44')][_0x60e93d('0x1166')](function(_0x1a884b){_0x70c395(_0x1a884b);})[_0x60e93d('0x1a80')](function(_0x1d32e6){_0xb62376(_0x1d32e6);});});}function _0x495685(){return _0x11d16a(function(_0x3db1a9,_0x17ced1){const _0x27b0e3=a0_0x3f2c;return _0x170740[_0x27b0e3('0x1e45')][_0x27b0e3('0x261c')]({'id':_0x11b096[_0x27b0e3('0x1e45')]['id'],'fields':_0x27b0e3('0x1459'),'nolimit':!![],'role':_0x27b0e3('0x1eff')})[_0x27b0e3('0xa44')][_0x27b0e3('0x1166')](function(_0x6484bf){_0x3db1a9(_0x6484bf);})[_0x27b0e3('0x1a80')](function(_0x4dd1a6){_0x17ced1(_0x4dd1a6);});});}function _0x132490(){return _0x11d16a(function(_0x42b290,_0x2e6286){const _0x4e9c88=a0_0x3f2c;return _0x170740[_0x4e9c88('0x557')]['get']({'fields':_0x4e9c88('0x1459'),'nolimit':!![],'role':'agent'})['$promise'][_0x4e9c88('0x1166')](function(_0x4f089f){_0x42b290(_0x4f089f);})[_0x4e9c88('0x1a80')](function(_0x1e9270){_0x2e6286(_0x1e9270);});});}function _0xebca66(_0x517a87){return _0x11d16a(function(_0x195bdb,_0x503ec0){const _0x3ebc11=a0_0x3f2c;_0x2cfb05()['isEmpty'](_0x517a87)?_0x195bdb():_0x170740[_0x3ebc11('0x1e45')][_0x3ebc11('0x275c')]({'id':_0x11b096['chatQueue']['id'],'ids':_0x2cfb05()[_0x3ebc11('0x2563')](_0x517a87,'id')})[_0x3ebc11('0xa44')][_0x3ebc11('0x1166')](function(){_0x195bdb();})[_0x3ebc11('0x1a80')](function(_0x46df2b){_0x503ec0(_0x46df2b);});});}function _0x289cf1(_0x528daf){return _0x11d16a(function(_0x13e6cd,_0x56dd95){const _0x3e8046=a0_0x3f2c;_0x2cfb05()[_0x3e8046('0x1081')](_0x528daf)?_0x13e6cd():_0x170740[_0x3e8046('0x1e45')][_0x3e8046('0x269d')]({'id':_0x11b096[_0x3e8046('0x1e45')]['id'],'ids':_0x2cfb05()[_0x3e8046('0x2563')](_0x528daf,'id')})['$promise'][_0x3e8046('0x1166')](function(){_0x13e6cd();})[_0x3e8046('0x1a80')](function(_0x9ced07){_0x56dd95(_0x9ced07);});});}function _0x4b1426(){const _0x4bd6c9=_0x273405,_0x159f9f=_0x2cfb05()[_0x4bd6c9('0x24ac')](_0x11b096[_0x4bd6c9('0x2781')],_0x11b096[_0x4bd6c9('0x18e1')],'id'),_0x41ae30=_0x2cfb05()['differenceBy'](_0x11b096[_0x4bd6c9('0x18e1')],_0x11b096['startingSelectedItems'],'id');return _0x289cf1(_0x159f9f)[_0x4bd6c9('0x1166')](function(){return _0xebca66(_0x41ae30);})[_0x4bd6c9('0x1166')](function(){const _0x43e1e3=_0x4bd6c9;_0x11b096[_0x43e1e3('0x14d7')]=![],_0x11b096[_0x43e1e3('0x2111')]=angular['copy'](_0x11b096[_0x43e1e3('0x10ab')]),_0x11b096['startingSelectedItems']=angular['copy'](_0x11b096['selectedItems']),_0x4e0c0a[_0x43e1e3('0x103b')]({'title':_0x43e1e3('0x983'),'msg':_0x43e1e3('0x1673')});})[_0x4bd6c9('0x1a80')](function(_0x1ed9db){const _0x2e021f=_0x4bd6c9;_0x4e0c0a[_0x2e021f('0xfc9')]({'title':_0x1ed9db[_0x2e021f('0x52d')]?_0x2e021f('0x1e21')+_0x1ed9db['status']+_0x2e021f('0x11e1')+_0x1ed9db[_0x2e021f('0xe1b')]:_0x2e021f('0x1b29'),'msg':_0x1ed9db[_0x2e021f('0x52d')]?JSON['stringify'](_0x1ed9db[_0x2e021f('0x25f4')]):_0x1ed9db[_0x2e021f('0x1586')]()});});}function _0x339ae8(){_0xe08b32['hide']();}}const _0x410c05=_0x5f1409;_0x895498['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x1e45'),_0x36e6f4('0x586'),'Auth','crudPermissions'];function _0x895498(_0x42cc8f,_0x5f0848,_0x302107,_0x263354,_0x3e9563,_0x99b1d9,_0x152f37,_0x4fdd74){const _0x4db845=_0x36e6f4,_0x4c3c50=this;_0x4c3c50[_0x4db845('0x98')]=_0x152f37[_0x4db845('0x26cd')](),_0x4c3c50[_0x4db845('0x1e45')]=_0x3e9563,_0x4c3c50[_0x4db845('0x243c')]=_0x4fdd74,_0x4c3c50[_0x4db845('0xbd7')]=[],_0x4c3c50[_0x4db845('0x10ab')]=[],_0x4c3c50[_0x4db845('0x18e1')]=[],_0x4c3c50[_0x4db845('0x2111')]=[],_0x4c3c50[_0x4db845('0x2781')]=[],_0x4c3c50[_0x4db845('0x14d7')]=![],_0x4c3c50[_0x4db845('0xc68')]={'readOnly':!_0x4c3c50['crudPermissions'][_0x4db845('0x1684')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x4db845('0x4f0'),'line1':'name','line2':'','line3':'','labelAll':_0x99b1d9[_0x4db845('0x25cc')](_0x4db845('0xaf4')),'labelSelected':_0x99b1d9[_0x4db845('0x25cc')](_0x4db845('0x1d4b')),'transferCallback':function(){const _0x2334c4=_0x4db845,_0x7d81f8=_0x2cfb05()[_0x2334c4('0x2802')](_0x4c3c50['startingSelectedItems'],_0x4c3c50[_0x2334c4('0x18e1')],'id');_0x4c3c50[_0x2334c4('0x14d7')]=_0x2cfb05()[_0x2334c4('0x1081')](_0x7d81f8)?![]:!![];}},_0x4c3c50['onInit']=_0xc3f4be,_0x4c3c50[_0x4db845('0x1add')]=_0x20fc71,_0x4c3c50[_0x4db845('0x24a0')]=_0x56b20b;function _0xc3f4be(){const _0x4c3c55=_0x4db845;return _0x152f37[_0x4c3c55('0x1ac6')](_0x4c3c55('0xa7c'))?_0x26eb4e()[_0x4c3c55('0x1a80')](function(_0x5dfedd){const _0x1a1df5=_0x4c3c55;_0x302107[_0x1a1df5('0xfc9')]({'title':_0x5dfedd[_0x1a1df5('0x52d')]?_0x1a1df5('0x1e21')+_0x5dfedd[_0x1a1df5('0x52d')]+_0x1a1df5('0x11e1')+_0x5dfedd['statusText']:_0x1a1df5('0x1031'),'msg':_0x5dfedd[_0x1a1df5('0x52d')]?JSON[_0x1a1df5('0xbac')](_0x5dfedd['data']):_0x5dfedd['toString']()});}):_0x439d9b()['then'](function(_0x20c13f){return _0x4c3c50['section']=_0x20c13f,_0x26eb4e();})[_0x4c3c55('0x1a80')](function(_0xf05890){const _0x58a5f8=_0x4c3c55;_0x302107[_0x58a5f8('0xfc9')]({'title':_0xf05890[_0x58a5f8('0x52d')]?_0x58a5f8('0x1e21')+_0xf05890[_0x58a5f8('0x52d')]+_0x58a5f8('0x11e1')+_0xf05890[_0x58a5f8('0xe1b')]:'SYSTEM:GET_TEAMS','msg':_0xf05890[_0x58a5f8('0x52d')]?JSON[_0x58a5f8('0xbac')](_0xf05890[_0x58a5f8('0x25f4')]):_0xf05890[_0x58a5f8('0x1586')]()});});}function _0x439d9b(){return _0x5f0848(function(_0xccf96a,_0x313bdb){const _0x1487dc=a0_0x3f2c;_0x263354[_0x1487dc('0x17aa')][_0x1487dc('0xd83')]({'userProfileId':_0x4c3c50[_0x1487dc('0x98')]['userProfileId'],'name':_0x1487dc('0x289e')})[_0x1487dc('0xa44')][_0x1487dc('0x1166')](function(_0x44dc14){const _0x157688=_0x1487dc,_0x2ccf68=_0x44dc14&&_0x44dc14[_0x157688('0x269a')]?_0x44dc14['rows'][0x0]:null;_0xccf96a(_0x2ccf68);})[_0x1487dc('0x1a80')](function(_0x5dbfce){_0x313bdb(_0x5dbfce);});});}function _0x26eb4e(){return _0x5f0848(function(_0x63dcd6,_0x17a11a){const _0x5cfb17=a0_0x3f2c;return _0x54e458()[_0x5cfb17('0x1166')](function(_0x453674){const _0x15e837=_0x5cfb17;return _0x4c3c50[_0x15e837('0xbd7')]=_0x453674[_0x15e837('0x269a')]?_0x453674['rows']:[],_0x152f37[_0x15e837('0x1ac6')](_0x15e837('0xa7c'))?_0x453674:_0x4c3c50[_0x15e837('0xe60')]?_0x4c3c50[_0x15e837('0xe60')]['autoAssociation']?_0x453674:_0x412f0f():null;})['then'](function(_0x81fa4b){const _0x137d5f=_0x5cfb17,_0x13bf47=_0x81fa4b&&_0x81fa4b[_0x137d5f('0x269a')]?_0x81fa4b[_0x137d5f('0x269a')]:[];return _0x4c3c50[_0x137d5f('0x10ab')]=_0x2cfb05()[_0x137d5f('0x2563')](_0x13bf47,function(_0x9be58c){const _0x1f09c2=_0x137d5f;return _0x2cfb05()[_0x1f09c2('0xc38')](_0x4c3c50[_0x1f09c2('0xbd7')],{'id':_0x152f37[_0x1f09c2('0x1ac6')](_0x1f09c2('0xa7c'))||_0x4c3c50['section'][_0x1f09c2('0x1a2b')]?_0x9be58c['id']:_0x9be58c[_0x1f09c2('0x24e8')]});}),_0x4c3c50[_0x137d5f('0xbd7')][_0x137d5f('0x2782')](function(_0x48dfa8){const _0x366996=_0x137d5f,_0x319445=_0x2cfb05()[_0x366996('0xc38')](_0x4c3c50[_0x366996('0x10ab')],{'id':_0x48dfa8['id']});_0x152f37['hasRole']('admin')?_0x48dfa8[_0x366996('0x26ef')]=!![]:_0x48dfa8[_0x366996('0x26ef')]=typeof _0x319445!==_0x366996('0x1048')?!![]:![];}),_0x455c0c();})[_0x5cfb17('0x1166')](function(_0x4997a4){const _0x33d612=_0x5cfb17,_0x33c6b5=_0x4997a4&&_0x4997a4[_0x33d612('0x269a')]?_0x4997a4['rows']:[];_0x4c3c50[_0x33d612('0x18e1')]=_0x2cfb05()[_0x33d612('0x2563')](_0x33c6b5,function(_0x117ba5){return _0x2cfb05()['find'](_0x4c3c50['items'],{'id':_0x117ba5['id']});}),_0x4c3c50['startingSelectedItems']=angular[_0x33d612('0x225f')](_0x4c3c50[_0x33d612('0x18e1')]),_0x4c3c50[_0x33d612('0xc68')][_0x33d612('0x18e1')]=_0x4c3c50[_0x33d612('0x18e1')],_0x4c3c50[_0x33d612('0xc68')][_0x33d612('0xbd7')]=_0x2cfb05()['differenceBy'](_0x4c3c50[_0x33d612('0x10ab')],_0x4c3c50[_0x33d612('0xc68')][_0x33d612('0x18e1')],'id'),_0x63dcd6();})[_0x5cfb17('0x1a80')](function(_0x327db1){_0x17a11a(_0x327db1);});});}function _0x412f0f(){return _0x5f0848(function(_0xa948ce,_0x282c94){return _0x263354['userProfileResource']['get']({'sectionId':_0x4c3c50['section']['id'],'nolimit':!![]})['$promise']['then'](function(_0x26edb3){_0xa948ce(_0x26edb3);})['catch'](function(_0x100e3d){_0x282c94(_0x100e3d);});});}function _0x455c0c(){return _0x5f0848(function(_0x12def1,_0x5545e6){const _0x451f2c=a0_0x3f2c;return _0x263354[_0x451f2c('0x1e45')]['getTeams']({'id':_0x4c3c50['chatQueue']['id'],'fields':_0x451f2c('0x1776'),'nolimit':!![]})[_0x451f2c('0xa44')][_0x451f2c('0x1166')](function(_0x2c543a){_0x12def1(_0x2c543a);})[_0x451f2c('0x1a80')](function(_0x4bf78f){_0x5545e6(_0x4bf78f);});});}function _0x54e458(){return _0x5f0848(function(_0x3f0e5c,_0x3b2d89){const _0x539f2e=a0_0x3f2c;return _0x263354[_0x539f2e('0x1e37')][_0x539f2e('0xd83')]({'fields':'id,name','nolimit':!![]})[_0x539f2e('0xa44')]['then'](function(_0x38a0fa){_0x3f0e5c(_0x38a0fa);})[_0x539f2e('0x1a80')](function(_0x250385){_0x3b2d89(_0x250385);});});}function _0x382afa(_0xcc351f){return _0x5f0848(function(_0x1703fb,_0x33a8b3){const _0xc467c8=a0_0x3f2c;_0x2cfb05()[_0xc467c8('0x1081')](_0xcc351f)?_0x1703fb():_0x263354[_0xc467c8('0x1e45')][_0xc467c8('0x16e0')]({'id':_0x4c3c50[_0xc467c8('0x1e45')]['id'],'ids':_0x2cfb05()[_0xc467c8('0x2563')](_0xcc351f,'id')})[_0xc467c8('0xa44')][_0xc467c8('0x1166')](function(){_0x1703fb();})[_0xc467c8('0x1a80')](function(_0x4ba883){_0x33a8b3(_0x4ba883);});});}function _0x2ca3ca(_0x13d269){return _0x5f0848(function(_0x864bb,_0x510fe1){const _0x4bccea=a0_0x3f2c;_0x2cfb05()[_0x4bccea('0x1081')](_0x13d269)?_0x864bb():_0x263354[_0x4bccea('0x1e45')][_0x4bccea('0x8f')]({'id':_0x4c3c50[_0x4bccea('0x1e45')]['id'],'ids':_0x2cfb05()[_0x4bccea('0x2563')](_0x13d269,'id')})[_0x4bccea('0xa44')][_0x4bccea('0x1166')](function(){_0x864bb();})['catch'](function(_0x4f04da){_0x510fe1(_0x4f04da);});});}function _0x20fc71(){const _0x5d69d1=_0x4db845,_0x5a9fce=_0x2cfb05()[_0x5d69d1('0x24ac')](_0x4c3c50[_0x5d69d1('0x2781')],_0x4c3c50[_0x5d69d1('0x18e1')],'id'),_0x44b031=_0x2cfb05()[_0x5d69d1('0x24ac')](_0x4c3c50[_0x5d69d1('0x18e1')],_0x4c3c50['startingSelectedItems'],'id');return _0x2ca3ca(_0x5a9fce)[_0x5d69d1('0x1166')](function(){return _0x382afa(_0x44b031);})['then'](function(){const _0x4465d4=_0x5d69d1;_0x4c3c50[_0x4465d4('0x14d7')]=![],_0x4c3c50[_0x4465d4('0x2111')]=angular[_0x4465d4('0x225f')](_0x4c3c50[_0x4465d4('0x10ab')]),_0x4c3c50['startingSelectedItems']=angular[_0x4465d4('0x225f')](_0x4c3c50['selectedItems']),_0x302107[_0x4465d4('0x103b')]({'title':_0x4465d4('0x983'),'msg':_0x4465d4('0x1f6b')});})[_0x5d69d1('0x1a80')](function(_0x41bba6){const _0x2f7579=_0x5d69d1;_0x302107[_0x2f7579('0xfc9')]({'title':_0x41bba6[_0x2f7579('0x52d')]?'API:'+_0x41bba6[_0x2f7579('0x52d')]+_0x2f7579('0x11e1')+_0x41bba6[_0x2f7579('0xe1b')]:_0x2f7579('0x1b29'),'msg':_0x41bba6['status']?JSON['stringify'](_0x41bba6[_0x2f7579('0x25f4')]):_0x41bba6[_0x2f7579('0x1586')]()});});}function _0x56b20b(){_0x42cc8f['hide']();}}const _0x4d31c9=_0x895498;_0x1c8b15[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$document',_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x1e45'),'userProfileSection'];function _0x1c8b15(_0x3bda79,_0x54e7c2,_0x394ffc,_0x56ccc6,_0x278c98,_0x5d8e24,_0x1afa02,_0x2dc5b5,_0x58c832,_0x49dfbd,_0x272528,_0x468a26){const _0x530ad4=_0x36e6f4,_0x2f6041=this;_0x2f6041[_0x530ad4('0x98')]=_0x49dfbd[_0x530ad4('0x26cd')](),_0x2f6041['license']=_0x5d8e24,_0x2f6041[_0x530ad4('0xf8a')]=_0x1afa02,_0x2f6041[_0x530ad4('0x2900')]=_0x2f6041[_0x530ad4('0xf8a')][_0x530ad4('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2f6041[_0x530ad4('0x246b')]=_0x54e7c2[_0x530ad4('0x6f1')]()+_0x530ad4('0xc51')+_0x54e7c2[_0x530ad4('0x1690')](),_0x2f6041['chatQueue']=_0x272528||_0x3bda79[_0x530ad4('0x23f')][_0x530ad4('0x1e45')]||{},_0x2f6041[_0x530ad4('0x17aa')]=_0x468a26&&_0x468a26[_0x530ad4('0x240f')]==0x1?_0x468a26[_0x530ad4('0x269a')][0x0]:null,_0x2f6041[_0x530ad4('0x243c')]=_0x49dfbd[_0x530ad4('0xd87')](_0x2f6041['userProfileSection']?_0x2f6041['userProfileSection'][_0x530ad4('0x243c')]:null),_0x2f6041[_0x530ad4('0x128b')]={},_0x2f6041[_0x530ad4('0x2669')]=_0x3bda79[_0x530ad4('0x23f')][_0x530ad4('0xbe3')]||0x0,_0x2f6041[_0x530ad4('0x292')]=_0x1b891a,_0x2f6041[_0x530ad4('0x1728')]=_0x5da3e1,_0x2f6041[_0x530ad4('0x31d')]=_0x58c832[_0x530ad4('0x1fa1')],_0x2f6041[_0x530ad4('0x1b4b')]=_0x10b268,_0x2f6041['saveChatQueue']=_0x25fbae;function _0x1b891a(_0xa849ce,_0x107cea){const _0x43f842=_0x530ad4;_0x394ffc[_0x43f842('0x1f80')]({'controller':'ChatQueueteamaddController','controllerAs':'vm','templateUrl':_0x14046a,'parent':angular[_0x43f842('0x1194')](_0x56ccc6['body']),'targetEvent':_0x107cea,'clickOutsideToClose':!![],'locals':{'chatQueue':_0xa849ce,'chatQueues':_0x2f6041['chatQueues']?_0x2f6041[_0x43f842('0x3a1')][_0x43f842('0x269a')]:[],'crudPermissions':_0x2f6041[_0x43f842('0x243c')]}});}function _0x5da3e1(_0x60414a,_0x599e80){const _0x4bdf38=_0x530ad4;_0x394ffc[_0x4bdf38('0x1f80')]({'controller':_0x4bdf38('0x1e46'),'controllerAs':'vm','templateUrl':_0x1711ce,'parent':angular[_0x4bdf38('0x1194')](_0x56ccc6[_0x4bdf38('0x8d2')]),'targetEvent':_0x599e80,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x60414a,'chatQueues':_0x2f6041[_0x4bdf38('0x3a1')]?_0x2f6041[_0x4bdf38('0x3a1')]['rows']:[],'crudPermissions':_0x2f6041[_0x4bdf38('0x243c')],'realtime':![]}});}function _0x10b268(){_0x3bda79['go']('app.chat.chatQueues',{},{'reload':'app.chat.chatQueues'});}function _0x25fbae(){const _0x328bd5=_0x530ad4;_0x2dc5b5[_0x328bd5('0x1e45')][_0x328bd5('0x1449')]({'id':_0x2f6041[_0x328bd5('0x1e45')]['id']},_0x2f6041[_0x328bd5('0x1e45')])[_0x328bd5('0xa44')][_0x328bd5('0x1166')](function(){const _0x5b90a7=_0x328bd5;_0x58c832[_0x5b90a7('0x103b')]({'title':_0x5b90a7('0x146a'),'msg':_0x2f6041[_0x5b90a7('0x1e45')][_0x5b90a7('0x4f0')]?_0x2f6041['chatQueue'][_0x5b90a7('0x4f0')]+_0x5b90a7('0xa17'):''});})[_0x328bd5('0x1a80')](function(_0x1e4f49){const _0x4f90ea=_0x328bd5;_0x58c832[_0x4f90ea('0xfc9')]({'title':_0x1e4f49[_0x4f90ea('0x52d')]?_0x4f90ea('0x1e21')+_0x1e4f49[_0x4f90ea('0x52d')]+_0x4f90ea('0x11e1')+_0x1e4f49[_0x4f90ea('0xe1b')]:'SYSTEM:GETchatQueue','msg':_0x1e4f49['data']?JSON['stringify'](_0x1e4f49[_0x4f90ea('0x25f4')]):_0x1e4f49['toString']()});});}}const _0x31ec80=_0x1c8b15,_0x550701=_0x2734b2['p']+_0x36e6f4('0x8ec'),_0x3fd5f8=_0x2734b2['p']+_0x36e6f4('0x3f9');_0x19d8ce[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$mdSidenav',_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x2136'),_0x36e6f4('0x7f'),'userProfileSection','api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x19d8ce(_0x2a3648,_0x430350,_0x22880e,_0xf07aa9,_0x15b6b2,_0x6dc5aa,_0x20f454,_0x76ed3e,_0x4f65f7,_0x3d5da4,_0x50313c,_0x3032a5,_0x57efcb,_0x42852d,_0x38e55f,_0x314497,_0x1e4b21){const _0x2cb6f1=_0x36e6f4,_0x1e4dce=this;_0x1e4dce[_0x2cb6f1('0x5c9')]=_0x314497,_0x1e4dce[_0x2cb6f1('0xf8a')]=_0x1e4b21,_0x1e4dce['currentUser']=_0x38e55f[_0x2cb6f1('0x26cd')](),_0x1e4dce['chatWebsites']=_0x4f65f7||{'count':0x0,'rows':[]},_0x1e4dce[_0x2cb6f1('0x7f')]=_0x3d5da4,_0x1e4dce[_0x2cb6f1('0x17aa')]=_0x50313c&&_0x50313c[_0x2cb6f1('0x240f')]==0x1?_0x50313c[_0x2cb6f1('0x269a')][0x0]:null,_0x1e4dce[_0x2cb6f1('0x243c')]=_0x38e55f[_0x2cb6f1('0xd87')](_0x1e4dce[_0x2cb6f1('0x17aa')]?_0x1e4dce[_0x2cb6f1('0x17aa')][_0x2cb6f1('0x243c')]:null),_0x1e4dce[_0x2cb6f1('0x916')]='chatWebsites',_0x1e4dce[_0x2cb6f1('0xef5')]='',_0x1e4dce['listOrderAsc']=null,_0x1e4dce['selectedChatWebsites']=[],_0x1e4dce[_0x2cb6f1('0x2218')]={'fields':_0x2cb6f1('0x244b'),'sort':_0x2cb6f1('0x14dc'),'limit':0xa,'page':0x1},_0x1e4dce[_0x2cb6f1('0x1859')]=_0x2cfb05()[_0x2cb6f1('0x155c')]([{'option':'WebsiteAlias','value':_0x2cb6f1('0x5e4')},{'option':_0x2cb6f1('0x6e3'),'value':_0x2cb6f1('0x1c47')},{'option':_0x2cb6f1('0x218e'),'value':'\x27agent_fullname\x27'}],function(_0x549789){return _0x2cfb05()['replace'](_0x549789['value'],new RegExp('\x27','g'),'');}),_0x1e4dce[_0x2cb6f1('0x124e')]=_0x2cfb05()[_0x2cb6f1('0x155c')]([{'option':'Rounded','value':_0x2cb6f1('0x1ab8')},{'option':_0x2cb6f1('0x1123'),'value':'\x27squared\x27'}],function(_0x5e7c2c){const _0x5f1253=_0x2cb6f1;return _0x2cfb05()[_0x5f1253('0xf3')](_0x5e7c2c['value'],new RegExp('\x27','g'),'');}),_0x1e4dce[_0x2cb6f1('0x1064')]=_0x2cfb05()[_0x2cb6f1('0x155c')]([{'option':_0x2cb6f1('0xcd5'),'value':_0x2cb6f1('0x4ad')},{'option':_0x2cb6f1('0x8e4'),'value':'\x27right\x27'},{'option':_0x2cb6f1('0xb0'),'value':_0x2cb6f1('0xe03')}],function(_0x283ad9){const _0x33919d=_0x2cb6f1;return _0x2cfb05()['replace'](_0x283ad9[_0x33919d('0x18e0')],new RegExp('\x27','g'),'');}),_0x1e4dce[_0x2cb6f1('0x1efd')]=_0x2cfb05()['keyBy']([{'option':_0x2cb6f1('0x25f7'),'value':_0x2cb6f1('0x2050')},{'option':'centered','value':_0x2cb6f1('0x4f4')}],function(_0x9a87c1){const _0x1fd980=_0x2cb6f1;return _0x2cfb05()[_0x1fd980('0xf3')](_0x9a87c1[_0x1fd980('0x18e0')],new RegExp('\x27','g'),'');}),_0x1e4dce[_0x2cb6f1('0x1597')]=_0x2cfb05()[_0x2cb6f1('0x155c')]([{'option':'Star','value':_0x2cb6f1('0x2762')},{'option':_0x2cb6f1('0x7f2'),'value':_0x2cb6f1('0x1d5f')}],function(_0x3b0b70){const _0x12b14c=_0x2cb6f1;return _0x2cfb05()['replace'](_0x3b0b70[_0x12b14c('0x18e0')],new RegExp('\x27','g'),'');}),_0x1e4dce['editstate']=_0x463558,_0x1e4dce['interactionsgoto']=_0x4bbeaf,_0x1e4dce[_0x2cb6f1('0x11e5')]=_0x13f646,_0x1e4dce['agentadddialog']=_0x58855d,_0x1e4dce[_0x2cb6f1('0x8d8')]=_0x58cd0b,_0x1e4dce['success']=_0x8fdf19,_0x1e4dce[_0x2cb6f1('0x36d')]=_0x4132e4,_0x1e4dce[_0x2cb6f1('0x181c')]=_0x4a4336,_0x1e4dce[_0x2cb6f1('0x285d')]=_0x178926,_0x1e4dce[_0x2cb6f1('0xdf4')]=_0x455905,_0x1e4dce['deleteSelectedChatWebsites']=_0x187a8d,_0x1e4dce[_0x2cb6f1('0xba1')]=_0x293fa1,_0x1e4dce[_0x2cb6f1('0x2af')]=_0x442cc0,_0x38e55f[_0x2cb6f1('0x1ac6')](_0x2cb6f1('0xa7c'))?_0x3032a5['cmList']['get']({'fields':_0x2cb6f1('0x1776'),'sort':_0x2cb6f1('0x4f0')})[_0x2cb6f1('0xa44')]['then'](function(_0x372973){_0x1e4dce['lists']=_0x372973['rows']||[];})[_0x2cb6f1('0x1a80')](function(_0x5a14f9){const _0x5a3a30=_0x2cb6f1;_0x42852d[_0x5a3a30('0xfc9')]({'title':_0x5a14f9[_0x5a3a30('0x52d')]?_0x5a3a30('0x1e21')+_0x5a14f9['status']+_0x5a3a30('0x11e1')+_0x5a14f9[_0x5a3a30('0xe1b')]:_0x5a3a30('0x520'),'msg':_0x5a14f9[_0x5a3a30('0x25f4')]?JSON['stringify'](_0x5a14f9[_0x5a3a30('0x25f4')]):_0x5a14f9[_0x5a3a30('0x1586')]()});}):_0x3032a5[_0x2cb6f1('0xdd9')][_0x2cb6f1('0xd83')]({'fields':_0x2cb6f1('0x1776'),'sort':_0x2cb6f1('0x4f0')})[_0x2cb6f1('0xa44')][_0x2cb6f1('0x1166')](function(_0x5627f2){const _0x51ea4f=_0x2cb6f1;_0x1e4dce[_0x51ea4f('0x8de')]=_0x5627f2[_0x51ea4f('0x269a')]||[];})[_0x2cb6f1('0x1166')](function(){const _0x1b1e2=_0x2cb6f1;return _0x3032a5[_0x1b1e2('0x17aa')][_0x1b1e2('0xd83')]({'userProfileId':_0x1e4dce['currentUser'][_0x1b1e2('0xb86')],'sectionId':0x12d})[_0x1b1e2('0xa44')];})[_0x2cb6f1('0x1166')](function(_0x431995){const _0x4e0ee9=_0x2cb6f1,_0x469932=_0x431995&&_0x431995[_0x4e0ee9('0x269a')]?_0x431995[_0x4e0ee9('0x269a')][0x0]:null;if(!_0x469932){const _0x27ea6e=[];let _0x20e586=null;_0x1e4dce[_0x4e0ee9('0x1864')]&&(_0x20e586=_0x2cfb05()[_0x4e0ee9('0xc38')](_0x1e4dce[_0x4e0ee9('0x8de')],{'id':Number(_0x1e4dce['chatWebsite'][_0x4e0ee9('0x23c')])}));for(let _0x3024b9=0x0;_0x3024b9<_0x1e4dce[_0x4e0ee9('0x8de')][_0x4e0ee9('0x264b')];_0x3024b9++){_0x20e586&&_0x1e4dce[_0x4e0ee9('0x8de')][_0x3024b9]['id']===_0x20e586['id']&&(_0x1e4dce[_0x4e0ee9('0x8de')][_0x3024b9][_0x4e0ee9('0x2378')]=![],_0x27ea6e[_0x4e0ee9('0x1514')](_0x1e4dce[_0x4e0ee9('0x8de')][_0x3024b9]));}_0x1e4dce[_0x4e0ee9('0x8de')]=_0x27ea6e;}else{if(!_0x469932[_0x4e0ee9('0x1a2b')])return _0x3032a5['userProfileResource'][_0x4e0ee9('0xd83')]({'sectionId':_0x469932['id']})[_0x4e0ee9('0xa44')]['then'](function(_0x522b66){const _0x46df76=_0x4e0ee9,_0x43ff35=_0x2cfb05()[_0x46df76('0x2563')](_0x522b66['rows'],function(_0x4afa65){const _0x4e5905=_0x46df76;return _0x2cfb05()[_0x4e5905('0xc38')](_0x1e4dce[_0x4e5905('0x8de')],{'id':_0x4afa65[_0x4e5905('0x24e8')]});});let _0x47f751=null;_0x1e4dce[_0x46df76('0x1864')]&&(_0x47f751=_0x2cfb05()['find'](_0x1e4dce[_0x46df76('0x8de')],{'id':Number(_0x1e4dce[_0x46df76('0x1864')][_0x46df76('0x23c')])}));if(_0x47f751&&!_0x2cfb05()[_0x46df76('0x1798')](_0x43ff35,['id',_0x47f751['id']])){const _0x144db8=_0x2cfb05()[_0x46df76('0xc38')](_0x1e4dce[_0x46df76('0x8de')],{'id':_0x47f751['id']});_0x144db8[_0x46df76('0x2378')]=![],_0x43ff35['push'](_0x144db8);}_0x1e4dce['lists']=_0x43ff35;});}})[_0x2cb6f1('0x1a80')](function(_0x1498b9){const _0x2af8bd=_0x2cb6f1;_0x42852d[_0x2af8bd('0xfc9')]({'title':_0x1498b9[_0x2af8bd('0x52d')]?_0x2af8bd('0x1e21')+_0x1498b9[_0x2af8bd('0x52d')]+'\x20-\x20'+_0x1498b9[_0x2af8bd('0xe1b')]:_0x2af8bd('0x1248'),'msg':_0x1498b9[_0x2af8bd('0x25f4')]?JSON[_0x2af8bd('0xbac')](_0x1498b9['data']):_0x1498b9[_0x2af8bd('0x1586')]()});}),_0x38e55f[_0x2cb6f1('0x1ac6')](_0x2cb6f1('0xa7c'))?_0x3032a5[_0x2cb6f1('0x277c')][_0x2cb6f1('0xd83')]({'fields':'id,name','sort':_0x2cb6f1('0x4f0'),'IntervalId':_0x2cb6f1('0x15d7')})[_0x2cb6f1('0xa44')][_0x2cb6f1('0x1166')](function(_0x35387e){const _0x2ec1f1=_0x2cb6f1;_0x1e4dce[_0x2ec1f1('0x277c')]=_0x35387e[_0x2ec1f1('0x269a')]||[];})[_0x2cb6f1('0x1a80')](function(_0x323488){const _0x2aaf39=_0x2cb6f1;_0x42852d[_0x2aaf39('0xfc9')]({'title':_0x323488[_0x2aaf39('0x52d')]?_0x2aaf39('0x1e21')+_0x323488[_0x2aaf39('0x52d')]+_0x2aaf39('0x11e1')+_0x323488[_0x2aaf39('0xe1b')]:_0x2aaf39('0x2451'),'msg':_0x323488['data']?JSON['stringify'](_0x323488[_0x2aaf39('0x25f4')]):_0x323488[_0x2aaf39('0x1586')]()});}):_0x3032a5[_0x2cb6f1('0x277c')]['get']({'fields':'id,name','sort':'name','IntervalId':_0x2cb6f1('0x15d7')})['$promise']['then'](function(_0x5a99b5){const _0x207251=_0x2cb6f1;_0x1e4dce[_0x207251('0x277c')]=_0x5a99b5[_0x207251('0x269a')]||[];})[_0x2cb6f1('0x1166')](function(){const _0x54972d=_0x2cb6f1;return _0x3032a5[_0x54972d('0x17aa')][_0x54972d('0xd83')]({'userProfileId':_0x1e4dce[_0x54972d('0x98')][_0x54972d('0xb86')],'sectionId':0x3ec})['$promise'];})['then'](function(_0x8f2704){const _0x1211a7=_0x2cb6f1,_0x514c00=_0x8f2704&&_0x8f2704['rows']?_0x8f2704[_0x1211a7('0x269a')][0x0]:null;if(!_0x514c00){const _0x2d4d1f=[];let _0x3c0d91=null;_0x1e4dce[_0x1211a7('0x1864')]&&(_0x3c0d91=_0x2cfb05()['find'](_0x1e4dce['interval'],{'id':Number(_0x1e4dce[_0x1211a7('0x1864')][_0x1211a7('0x186f')])}));for(let _0x12e8dc=0x0;_0x12e8dc<_0x1e4dce[_0x1211a7('0x277c')][_0x1211a7('0x264b')];_0x12e8dc++){_0x3c0d91&&_0x1e4dce['interval'][_0x12e8dc]['id']===_0x3c0d91['id']&&(_0x1e4dce[_0x1211a7('0x277c')][_0x12e8dc][_0x1211a7('0x2378')]=![],_0x2d4d1f[_0x1211a7('0x1514')](_0x1e4dce[_0x1211a7('0x277c')][_0x12e8dc]));}_0x1e4dce[_0x1211a7('0x277c')]=_0x2d4d1f;}else{if(!_0x514c00['autoAssociation'])return _0x3032a5[_0x1211a7('0x4b5')]['get']({'sectionId':_0x514c00['id']})[_0x1211a7('0xa44')][_0x1211a7('0x1166')](function(_0x4fa6f1){const _0x49a7b9=_0x1211a7,_0x4d687b=_0x2cfb05()[_0x49a7b9('0x2563')](_0x4fa6f1['rows'],function(_0x411e7d){const _0x34666d=_0x49a7b9;return _0x2cfb05()[_0x34666d('0xc38')](_0x1e4dce[_0x34666d('0x277c')],{'id':_0x411e7d[_0x34666d('0x24e8')]});});let _0x177002=null;_0x1e4dce[_0x49a7b9('0x1864')]&&(_0x177002=_0x2cfb05()['find'](_0x1e4dce[_0x49a7b9('0x277c')],{'id':Number(_0x1e4dce[_0x49a7b9('0x1864')][_0x49a7b9('0x186f')])}));if(_0x177002&&!_0x2cfb05()[_0x49a7b9('0x1798')](_0x4d687b,['id',_0x177002['id']])){const _0x18838e=_0x2cfb05()['find'](_0x1e4dce['interval'],{'id':_0x177002['id']});_0x18838e['canSelect']=![],_0x4d687b[_0x49a7b9('0x1514')](_0x18838e);}_0x1e4dce[_0x49a7b9('0x277c')]=_0x4d687b;});}})[_0x2cb6f1('0x1a80')](function(_0x26751b){const _0x5d46bd=_0x2cb6f1;_0x42852d['error']({'title':_0x26751b['status']?_0x5d46bd('0x1e21')+_0x26751b[_0x5d46bd('0x52d')]+_0x5d46bd('0x11e1')+_0x26751b[_0x5d46bd('0xe1b')]:_0x5d46bd('0xe48'),'msg':_0x26751b[_0x5d46bd('0x25f4')]?JSON['stringify'](_0x26751b['data']):_0x26751b[_0x5d46bd('0x1586')]()});});function _0x463558(_0x46e735){const _0x223bd1=_0x2cb6f1;_0x22880e['go'](_0x223bd1('0x90b'),{'id':_0x46e735['id'],'chatWebsite':_0x46e735,'crudPermissions':_0x1e4dce[_0x223bd1('0x243c')]});}function _0x4bbeaf(_0x14c017){const _0x954da5=_0x2cb6f1;_0x22880e['go'](_0x954da5('0x90b'),{'id':_0x14c017['id'],'tab':0xa});}function _0x13f646(_0x58cadf){_0x22880e['go']('app.chat.chatWebsites.edit',{'id':_0x58cadf['id'],'tab':0xb});}function _0x58855d(_0x835c7c,_0x4476aa){const _0x173824=_0x2cb6f1;_0x15b6b2['show']({'controller':_0x173824('0x222e'),'controllerAs':'vm','templateUrl':_0x550701,'parent':angular[_0x173824('0x1194')](_0x6dc5aa[_0x173824('0x8d2')]),'targetEvent':_0x4476aa,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x835c7c,'chatWebsites':_0x1e4dce[_0x173824('0x2136')]?_0x1e4dce[_0x173824('0x2136')][_0x173824('0x269a')]:[],'crudPermissions':_0x1e4dce[_0x173824('0x243c')],'realtime':![]}});}function _0x58cd0b(_0x145951,_0xd32e73){const _0x8a43e0=_0x2cb6f1,_0x2dcdb6=_0x15b6b2['confirm']()[_0x8a43e0('0xcdc')](_0x8a43e0('0x288d')+_0x2cfb05()[_0x8a43e0('0xb35')](_0x8a43e0('0x1864'))+'?')[_0x8a43e0('0xf3c')](_0x8a43e0('0x12b5')+(_0x145951['name']||_0x8a43e0('0x1864'))+_0x8a43e0('0xace')+_0x8a43e0('0x3f3'))[_0x8a43e0('0x8e8')](_0x8a43e0('0x18c2'))[_0x8a43e0('0x203b')](_0xd32e73)['ok']('OK')['cancel'](_0x8a43e0('0x2d3'));_0x15b6b2[_0x8a43e0('0x1f80')](_0x2dcdb6)[_0x8a43e0('0x1166')](function(){_0x178926(_0x145951);},function(){const _0x2a4b08=_0x8a43e0;console[_0x2a4b08('0x455')](_0x2a4b08('0x2d3'));});}let _0x545c6b=!![],_0x44fdc8=0x1;_0x2a3648['$watch']('vm.query.filter',function(_0x20c755,_0x22ae80){const _0x2f4372=_0x2cb6f1;_0x545c6b?_0x20f454(function(){_0x545c6b=![];}):(!_0x22ae80&&(_0x44fdc8=_0x1e4dce[_0x2f4372('0x2218')][_0x2f4372('0x1a43')]),_0x20c755!==_0x22ae80&&(_0x1e4dce[_0x2f4372('0x2218')][_0x2f4372('0x1a43')]=0x1),!_0x20c755&&(_0x1e4dce['query'][_0x2f4372('0x1a43')]=_0x44fdc8),_0x1e4dce[_0x2f4372('0x36d')]());});function _0x8fdf19(_0x163c5e){const _0x3bb46d=_0x2cb6f1;_0x1e4dce[_0x3bb46d('0x2136')]=_0x163c5e||{'count':0x0,'rows':[]};}function _0x4132e4(){const _0x561b4a=_0x2cb6f1;_0x1e4dce[_0x561b4a('0x2218')][_0x561b4a('0x1098')]=(_0x1e4dce[_0x561b4a('0x2218')][_0x561b4a('0x1a43')]-0x1)*_0x1e4dce['query']['limit'],_0x38e55f['hasRole']('admin')?_0x1e4dce[_0x561b4a('0x1f48')]=_0x3032a5[_0x561b4a('0x1864')]['get'](_0x1e4dce[_0x561b4a('0x2218')],_0x8fdf19)['$promise']:(_0x1e4dce[_0x561b4a('0x2218')]['id']=_0x1e4dce[_0x561b4a('0x7f')]['id'],_0x1e4dce['query'][_0x561b4a('0xe60')]=_0x561b4a('0xbe9'),_0x1e4dce[_0x561b4a('0x1f48')]=_0x3032a5[_0x561b4a('0x7f')][_0x561b4a('0x263a')](_0x1e4dce[_0x561b4a('0x2218')],_0x8fdf19)[_0x561b4a('0xa44')]);}function _0x4a4336(_0x4bb66e,_0x2917b0){const _0x1b032c=_0x2cb6f1;_0x15b6b2['show']({'controller':'CreateOrEditChatWebsiteDialogController','controllerAs':'vm','templateUrl':_0x3fd5f8,'parent':angular[_0x1b032c('0x1194')](_0x6dc5aa['body']),'targetEvent':_0x4bb66e,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x2917b0,'chatWebsites':_0x1e4dce[_0x1b032c('0x2136')][_0x1b032c('0x269a')],'license':_0x1e4dce[_0x1b032c('0x5c9')],'setting':_0x1e4dce[_0x1b032c('0xf8a')],'crudPermissions':_0x1e4dce['crudPermissions']}});}function _0x178926(_0x598718){const _0x385a0a=_0x2cb6f1;_0x3032a5['chatWebsite'][_0x385a0a('0x906')]({'id':_0x598718['id']})[_0x385a0a('0xa44')][_0x385a0a('0x1166')](function(){const _0x58c806=_0x385a0a;_0x2cfb05()[_0x58c806('0x127f')](_0x1e4dce[_0x58c806('0x2136')][_0x58c806('0x269a')],{'id':_0x598718['id']}),_0x1e4dce[_0x58c806('0x2136')][_0x58c806('0x240f')]-=0x1,!_0x1e4dce[_0x58c806('0x2136')]['rows'][_0x58c806('0x264b')]&&_0x1e4dce[_0x58c806('0x36d')](),_0x42852d[_0x58c806('0x103b')]({'title':_0x2cfb05()[_0x58c806('0xb35')](_0x58c806('0x117d'))+_0x58c806('0x2b6'),'msg':_0x598718[_0x58c806('0x4f0')]?_0x598718['name']+'\x20has\x20been\x20deleted!':''});})[_0x385a0a('0x1a80')](function(_0x2aeb46){const _0x4aa82a=_0x385a0a;if(_0x2aeb46[_0x4aa82a('0x25f4')]&&_0x2aeb46[_0x4aa82a('0x25f4')]['errors']&&_0x2aeb46[_0x4aa82a('0x25f4')]['errors']['length']){_0x1e4dce['errors']=_0x2aeb46[_0x4aa82a('0x25f4')][_0x4aa82a('0x61a')]||[{'message':_0x2aeb46['toString'](),'type':_0x4aa82a('0x2fe')}];for(let _0x175e78=0x0;_0x175e78<_0x2aeb46[_0x4aa82a('0x25f4')][_0x4aa82a('0x61a')][_0x4aa82a('0x264b')];_0x175e78++){_0x42852d['error']({'title':_0x2aeb46[_0x4aa82a('0x25f4')][_0x4aa82a('0x61a')][_0x175e78][_0x4aa82a('0x1345')],'msg':_0x2aeb46[_0x4aa82a('0x25f4')][_0x4aa82a('0x61a')][_0x175e78]['message']});}}else _0x42852d[_0x4aa82a('0xfc9')]({'title':_0x2aeb46[_0x4aa82a('0x52d')]?_0x4aa82a('0x1e21')+_0x2aeb46['status']+_0x4aa82a('0x11e1')+_0x2aeb46[_0x4aa82a('0xe1b')]:_0x4aa82a('0x2fe'),'msg':_0x2aeb46[_0x4aa82a('0x25f4')]?JSON[_0x4aa82a('0xbac')](_0x2aeb46[_0x4aa82a('0x25f4')]['message']):_0x2aeb46[_0x4aa82a('0x1e70')]||_0x2aeb46[_0x4aa82a('0x1586')]()});});}function _0x455905(){const _0x17f40a=_0x2cb6f1,_0x5e870b=angular['copy'](_0x1e4dce[_0x17f40a('0x13a2')]);return _0x1e4dce[_0x17f40a('0x13a2')]=[],_0x5e870b;}function _0x187a8d(_0x45de3e){const _0x2743cc=_0x2cb6f1,_0x1a1fac=_0x15b6b2[_0x2743cc('0x1d26')]()[_0x2743cc('0xcdc')](_0x2743cc('0x5b1'))[_0x2743cc('0xf3c')](''+_0x1e4dce[_0x2743cc('0x13a2')][_0x2743cc('0x264b')]+_0x2743cc('0x196d')+_0x2743cc('0x3f3'))['ariaLabel'](_0x2743cc('0x24f1'))[_0x2743cc('0x203b')](_0x45de3e)['ok']('OK')[_0x2743cc('0x3f')](_0x2743cc('0x2d3'));_0x15b6b2[_0x2743cc('0x1f80')](_0x1a1fac)[_0x2743cc('0x1166')](function(){const _0x2c2a97=_0x2743cc;_0x1e4dce[_0x2c2a97('0x13a2')]['forEach'](function(_0x4e6579){_0x178926(_0x4e6579);}),_0x1e4dce[_0x2c2a97('0x13a2')]=[];});}function _0x293fa1(){_0x1e4dce['selectedChatWebsites']=[];}function _0x442cc0(){const _0x36f74e=_0x2cb6f1;_0x1e4dce[_0x36f74e('0x13a2')]=_0x1e4dce[_0x36f74e('0x2136')][_0x36f74e('0x269a')];}}const _0x10a540=_0x19d8ce;_0x4eed05[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),'chatWebsites',_0x36e6f4('0x1864'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x4eed05(_0x590648,_0x53f7b7,_0x8f1499,_0x41f65b,_0x4e0096,_0x5163ea,_0x43660a,_0x54bd53,_0x1f7ec7,_0x2f2866,_0x1d9916,_0x101fbd,_0x13e3dc,_0x83ba98){const _0x2e1b35=_0x36e6f4,_0x17a6d5=this;_0x17a6d5[_0x2e1b35('0x98')]=_0x1d9916[_0x2e1b35('0x26cd')](),_0x17a6d5[_0x2e1b35('0x61a')]=[],_0x17a6d5[_0x2e1b35('0xf8a')]=_0x13e3dc,_0x17a6d5[_0x2e1b35('0x5c9')]=_0x101fbd,_0x17a6d5[_0x2e1b35('0x243c')]=_0x83ba98,_0x17a6d5[_0x2e1b35('0x128b')]={},_0x17a6d5[_0x2e1b35('0x2900')]=_0x17a6d5[_0x2e1b35('0xf8a')]&&_0x17a6d5[_0x2e1b35('0xf8a')][_0x2e1b35('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x17a6d5['title']='CHAT.EDIT_CHATWEBSITE',_0x17a6d5['chatWebsite']=angular[_0x2e1b35('0x225f')](_0x1f7ec7),_0x17a6d5[_0x2e1b35('0x2136')]=_0x54bd53,_0x17a6d5[_0x2e1b35('0xb6b')]=![];!_0x17a6d5[_0x2e1b35('0x1864')]&&(_0x17a6d5['chatWebsite']={'remote':_0x8f1499['protocol']()+_0x2e1b35('0xc51')+_0x8f1499[_0x2e1b35('0x1690')]()+(_0x8f1499[_0x2e1b35('0x93d')]()?':'+_0x8f1499['port']():''),'header_shape':_0x2e1b35('0x2469'),'alignment':'bottom_right','verticalAlignment':0x1e,'messagesAlignment':'alternate','IntervalId':_0x2e1b35('0x15d7'),'timezone':'null','waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0x17a6d5[_0x2e1b35('0xcdc')]=_0x2e1b35('0x124'),_0x17a6d5['newChatWebsite']=!![]);_0x53f7b7[_0x2e1b35('0x23f')]['id']&&(_0x17a6d5[_0x2e1b35('0x1864')]['ChatWebsiteId']=_0x53f7b7['params']['id']);_0x17a6d5['addNewChatWebsite']=_0x2e6e9e,_0x17a6d5[_0x2e1b35('0xef6')]=_0x7fa911,_0x17a6d5[_0x2e1b35('0x285d')]=_0x56307d,_0x17a6d5[_0x2e1b35('0x1a9c')]=_0xf7cd04,_0x17a6d5[_0x2e1b35('0x24a0')]=_0x23e2a2,_0x1d9916[_0x2e1b35('0x1ac6')](_0x2e1b35('0xa7c'))?_0x2f2866[_0x2e1b35('0xdd9')][_0x2e1b35('0xd83')]({'fields':_0x2e1b35('0x1776'),'sort':_0x2e1b35('0x4f0')})[_0x2e1b35('0xa44')]['then'](function(_0x3c5ee2){_0x17a6d5['lists']=_0x3c5ee2['rows']||[];})['catch'](function(_0x41f794){const _0x22268d=_0x2e1b35;_0x43660a[_0x22268d('0xfc9')]({'title':_0x41f794[_0x22268d('0x52d')]?_0x22268d('0x1e21')+_0x41f794[_0x22268d('0x52d')]+'\x20-\x20'+_0x41f794[_0x22268d('0xe1b')]:_0x22268d('0x520'),'msg':_0x41f794[_0x22268d('0x25f4')]?JSON['stringify'](_0x41f794[_0x22268d('0x25f4')]):_0x41f794[_0x22268d('0x1586')]()});}):_0x2f2866['cmList'][_0x2e1b35('0xd83')]({'fields':_0x2e1b35('0x1776'),'sort':_0x2e1b35('0x4f0')})[_0x2e1b35('0xa44')][_0x2e1b35('0x1166')](function(_0x52598b){const _0x4669f2=_0x2e1b35;_0x17a6d5[_0x4669f2('0x8de')]=_0x52598b[_0x4669f2('0x269a')]||[];})[_0x2e1b35('0x1166')](function(){const _0x2bbc37=_0x2e1b35;return _0x2f2866['userProfileSection']['get']({'userProfileId':_0x17a6d5[_0x2bbc37('0x98')][_0x2bbc37('0xb86')],'sectionId':0x12d})[_0x2bbc37('0xa44')];})['then'](function(_0x343fb2){const _0x483b7b=_0x2e1b35,_0x3f0962=_0x343fb2&&_0x343fb2['rows']?_0x343fb2[_0x483b7b('0x269a')][0x0]:null;if(!_0x3f0962){const _0xfcf379=[];let _0x5660be=null;_0x17a6d5[_0x483b7b('0x1864')]&&(_0x5660be=_0x2cfb05()[_0x483b7b('0xc38')](_0x17a6d5['lists'],{'id':Number(_0x17a6d5['chatWebsite'][_0x483b7b('0x23c')])}));for(let _0xa9b203=0x0;_0xa9b203<_0x17a6d5[_0x483b7b('0x8de')][_0x483b7b('0x264b')];_0xa9b203++){_0x5660be&&_0x17a6d5['lists'][_0xa9b203]['id']===_0x5660be['id']&&(_0x17a6d5[_0x483b7b('0x8de')][_0xa9b203][_0x483b7b('0x2378')]=![],_0xfcf379[_0x483b7b('0x1514')](_0x17a6d5['lists'][_0xa9b203]));}_0x17a6d5['lists']=_0xfcf379;}else{if(!_0x3f0962[_0x483b7b('0x1a2b')])return _0x2f2866[_0x483b7b('0x4b5')][_0x483b7b('0xd83')]({'sectionId':_0x3f0962['id']})[_0x483b7b('0xa44')][_0x483b7b('0x1166')](function(_0x36c202){const _0x2ed0cd=_0x483b7b,_0x30f425=_0x2cfb05()['map'](_0x36c202[_0x2ed0cd('0x269a')],function(_0x50ba63){const _0x23c264=_0x2ed0cd;return _0x2cfb05()[_0x23c264('0xc38')](_0x17a6d5['lists'],{'id':_0x50ba63[_0x23c264('0x24e8')]});});let _0x23a17d=null;_0x17a6d5[_0x2ed0cd('0x1864')]&&(_0x23a17d=_0x2cfb05()[_0x2ed0cd('0xc38')](_0x17a6d5['lists'],{'id':Number(_0x17a6d5[_0x2ed0cd('0x1864')][_0x2ed0cd('0x23c')])}));if(_0x23a17d&&!_0x2cfb05()['some'](_0x30f425,['id',_0x23a17d['id']])){const _0x52169f=_0x2cfb05()[_0x2ed0cd('0xc38')](_0x17a6d5[_0x2ed0cd('0x8de')],{'id':_0x23a17d['id']});_0x52169f[_0x2ed0cd('0x2378')]=![],_0x30f425[_0x2ed0cd('0x1514')](_0x52169f);}_0x17a6d5[_0x2ed0cd('0x8de')]=_0x30f425;});}})['catch'](function(_0x41f95e){const _0x5d129b=_0x2e1b35;_0x43660a['error']({'title':_0x41f95e['status']?_0x5d129b('0x1e21')+_0x41f95e[_0x5d129b('0x52d')]+_0x5d129b('0x11e1')+_0x41f95e['statusText']:'SYSTEM:GETlists','msg':_0x41f95e[_0x5d129b('0x25f4')]?JSON[_0x5d129b('0xbac')](_0x41f95e['data']):_0x41f95e['toString']()});}),_0x1d9916[_0x2e1b35('0x1ac6')](_0x2e1b35('0xa7c'))?_0x2f2866[_0x2e1b35('0x277c')][_0x2e1b35('0xd83')]({'fields':'id,name','sort':_0x2e1b35('0x4f0'),'IntervalId':'null'})['$promise'][_0x2e1b35('0x1166')](function(_0x3d349e){const _0x3e352a=_0x2e1b35;_0x17a6d5[_0x3e352a('0x277c')]=_0x3d349e['rows']||[];})[_0x2e1b35('0x1a80')](function(_0x4abba0){const _0x27cad2=_0x2e1b35;_0x43660a[_0x27cad2('0xfc9')]({'title':_0x4abba0[_0x27cad2('0x52d')]?_0x27cad2('0x1e21')+_0x4abba0[_0x27cad2('0x52d')]+_0x27cad2('0x11e1')+_0x4abba0[_0x27cad2('0xe1b')]:_0x27cad2('0x2451'),'msg':_0x4abba0[_0x27cad2('0x25f4')]?JSON[_0x27cad2('0xbac')](_0x4abba0[_0x27cad2('0x25f4')]):_0x4abba0[_0x27cad2('0x1586')]()});}):_0x2f2866[_0x2e1b35('0x277c')][_0x2e1b35('0xd83')]({'fields':_0x2e1b35('0x1776'),'sort':'name','IntervalId':_0x2e1b35('0x15d7')})['$promise'][_0x2e1b35('0x1166')](function(_0xad3d53){const _0x1ecea1=_0x2e1b35;_0x17a6d5[_0x1ecea1('0x277c')]=_0xad3d53[_0x1ecea1('0x269a')]||[];})['then'](function(){const _0x398fbf=_0x2e1b35;return _0x2f2866[_0x398fbf('0x17aa')][_0x398fbf('0xd83')]({'userProfileId':_0x17a6d5[_0x398fbf('0x98')][_0x398fbf('0xb86')],'sectionId':0x3ec})[_0x398fbf('0xa44')];})[_0x2e1b35('0x1166')](function(_0x56c1b1){const _0xcb6c0a=_0x2e1b35,_0x52fb97=_0x56c1b1&&_0x56c1b1[_0xcb6c0a('0x269a')]?_0x56c1b1['rows'][0x0]:null;if(!_0x52fb97){const _0x2a245f=[];let _0x21c86b=null;_0x17a6d5['chatWebsite']&&(_0x21c86b=_0x2cfb05()[_0xcb6c0a('0xc38')](_0x17a6d5[_0xcb6c0a('0x277c')],{'id':Number(_0x17a6d5[_0xcb6c0a('0x1864')]['IntervalId'])}));for(let _0xad6885=0x0;_0xad6885<_0x17a6d5['interval'][_0xcb6c0a('0x264b')];_0xad6885++){_0x21c86b&&_0x17a6d5[_0xcb6c0a('0x277c')][_0xad6885]['id']===_0x21c86b['id']&&(_0x17a6d5['interval'][_0xad6885]['canSelect']=![],_0x2a245f[_0xcb6c0a('0x1514')](_0x17a6d5[_0xcb6c0a('0x277c')][_0xad6885]));}_0x17a6d5[_0xcb6c0a('0x277c')]=_0x2a245f;}else{if(!_0x52fb97[_0xcb6c0a('0x1a2b')])return _0x2f2866[_0xcb6c0a('0x4b5')]['get']({'sectionId':_0x52fb97['id']})[_0xcb6c0a('0xa44')][_0xcb6c0a('0x1166')](function(_0x14824b){const _0x328b44=_0xcb6c0a,_0x3e241e=_0x2cfb05()[_0x328b44('0x2563')](_0x14824b[_0x328b44('0x269a')],function(_0x228286){const _0x5912b6=_0x328b44;return _0x2cfb05()['find'](_0x17a6d5[_0x5912b6('0x277c')],{'id':_0x228286[_0x5912b6('0x24e8')]});});let _0x4ab08f=null;_0x17a6d5['chatWebsite']&&(_0x4ab08f=_0x2cfb05()[_0x328b44('0xc38')](_0x17a6d5[_0x328b44('0x277c')],{'id':Number(_0x17a6d5['chatWebsite'][_0x328b44('0x186f')])}));if(_0x4ab08f&&!_0x2cfb05()[_0x328b44('0x1798')](_0x3e241e,['id',_0x4ab08f['id']])){const _0xf0bc04=_0x2cfb05()['find'](_0x17a6d5[_0x328b44('0x277c')],{'id':_0x4ab08f['id']});_0xf0bc04[_0x328b44('0x2378')]=![],_0x3e241e[_0x328b44('0x1514')](_0xf0bc04);}_0x17a6d5['interval']=_0x3e241e;});}})['catch'](function(_0x2e9062){const _0x2719fb=_0x2e1b35;_0x43660a[_0x2719fb('0xfc9')]({'title':_0x2e9062['status']?'API:'+_0x2e9062[_0x2719fb('0x52d')]+'\x20-\x20'+_0x2e9062[_0x2719fb('0xe1b')]:_0x2719fb('0xe48'),'msg':_0x2e9062[_0x2719fb('0x25f4')]?JSON[_0x2719fb('0xbac')](_0x2e9062['data']):_0x2e9062[_0x2719fb('0x1586')]()});});function _0x2e6e9e(){const _0x367a73=_0x2e1b35;_0x17a6d5[_0x367a73('0x61a')]=[],_0x2f2866[_0x367a73('0x1864')][_0x367a73('0x9cc')](_0x17a6d5[_0x367a73('0x1864')])[_0x367a73('0xa44')]['then'](function(_0x4c49fe){const _0x203670=_0x367a73;_0x17a6d5[_0x203670('0x2136')][_0x203670('0x2450')](_0x4c49fe['toJSON']()),_0x43660a[_0x203670('0x103b')]({'title':_0x203670('0x2417'),'msg':_0x17a6d5[_0x203670('0x1864')][_0x203670('0x4f0')]?_0x17a6d5['chatWebsite'][_0x203670('0x4f0')]+_0x203670('0x1eda'):''}),_0x23e2a2(_0x4c49fe);})['catch'](function(_0x1b39c2){const _0x12ed52=_0x367a73;if(_0x1b39c2[_0x12ed52('0x25f4')]&&_0x1b39c2[_0x12ed52('0x25f4')][_0x12ed52('0x61a')]&&_0x1b39c2['data'][_0x12ed52('0x61a')][_0x12ed52('0x264b')]){_0x17a6d5[_0x12ed52('0x61a')]=_0x1b39c2[_0x12ed52('0x25f4')][_0x12ed52('0x61a')]||[{'message':_0x1b39c2['toString'](),'type':_0x12ed52('0x183b')}];for(let _0x27d783=0x0;_0x27d783<_0x1b39c2[_0x12ed52('0x25f4')][_0x12ed52('0x61a')][_0x12ed52('0x264b')];_0x27d783+=0x1){_0x43660a[_0x12ed52('0xfc9')]({'title':_0x1b39c2[_0x12ed52('0x25f4')][_0x12ed52('0x61a')][_0x27d783][_0x12ed52('0x1345')],'msg':_0x1b39c2[_0x12ed52('0x25f4')]['errors'][_0x27d783][_0x12ed52('0x1e70')]});}}else _0x43660a['error']({'title':_0x1b39c2[_0x12ed52('0x52d')]?_0x12ed52('0x1e21')+_0x1b39c2[_0x12ed52('0x52d')]+'\x20-\x20'+_0x1b39c2[_0x12ed52('0xe1b')]:_0x12ed52('0x183b'),'msg':_0x1b39c2[_0x12ed52('0x25f4')]?JSON[_0x12ed52('0xbac')](_0x1b39c2['data'][_0x12ed52('0x1e70')]):_0x1b39c2[_0x12ed52('0x1586')]()});});}function _0x7fa911(){const _0x53189e=_0x2e1b35;_0x17a6d5[_0x53189e('0x61a')]=[],_0x2f2866[_0x53189e('0x1864')][_0x53189e('0x1449')]({'id':_0x17a6d5[_0x53189e('0x1864')]['id']},_0x17a6d5[_0x53189e('0x1864')])[_0x53189e('0xa44')][_0x53189e('0x1166')](function(_0x296df5){const _0xab6bb4=_0x53189e,_0x25ef70=_0x2cfb05()[_0xab6bb4('0xc38')](_0x17a6d5[_0xab6bb4('0x2136')],{'id':_0x296df5['id']});_0x25ef70&&_0x2cfb05()[_0xab6bb4('0xcc3')](_0x25ef70,_0x2cfb05()['pick'](_0x296df5[_0xab6bb4('0x2876')](),_0x2cfb05()[_0xab6bb4('0x14a4')](_0x25ef70))),_0x43660a['success']({'title':_0xab6bb4('0x2543'),'msg':_0x17a6d5['chatWebsite'][_0xab6bb4('0x4f0')]?_0x17a6d5[_0xab6bb4('0x1864')][_0xab6bb4('0x4f0')]+_0xab6bb4('0x7d'):''}),_0x23e2a2(_0x296df5);})[_0x53189e('0x1a80')](function(_0x50762d){const _0x14c436=_0x53189e;if(_0x50762d[_0x14c436('0x25f4')]&&_0x50762d[_0x14c436('0x25f4')][_0x14c436('0x61a')]&&_0x50762d[_0x14c436('0x25f4')][_0x14c436('0x61a')][_0x14c436('0x264b')]){_0x17a6d5[_0x14c436('0x61a')]=_0x50762d[_0x14c436('0x25f4')]['errors']||[{'message':_0x50762d[_0x14c436('0x1586')](),'type':_0x14c436('0xb8c')}];for(let _0xcd6774=0x0;_0xcd6774<_0x50762d[_0x14c436('0x25f4')][_0x14c436('0x61a')][_0x14c436('0x264b')];_0xcd6774++){_0x43660a[_0x14c436('0xfc9')]({'title':_0x50762d[_0x14c436('0x25f4')][_0x14c436('0x61a')][_0xcd6774][_0x14c436('0x1345')],'msg':_0x50762d[_0x14c436('0x25f4')][_0x14c436('0x61a')][_0xcd6774][_0x14c436('0x1e70')]});}}else _0x43660a[_0x14c436('0xfc9')]({'title':_0x50762d[_0x14c436('0x52d')]?'API:'+_0x50762d[_0x14c436('0x52d')]+_0x14c436('0x11e1')+_0x50762d[_0x14c436('0xe1b')]:'api.chatWebsite.update','msg':_0x50762d[_0x14c436('0x25f4')]?JSON[_0x14c436('0xbac')](_0x50762d['data'][_0x14c436('0x1e70')]):_0x50762d[_0x14c436('0x1586')]()});});}function _0x56307d(_0x50fcfa){const _0x3c8556=_0x2e1b35;_0x17a6d5[_0x3c8556('0x61a')]=[];const _0x5981ac=_0x41f65b[_0x3c8556('0x1d26')]()[_0x3c8556('0xcdc')](_0x3c8556('0x7fb'))[_0x3c8556('0xacc')]('The\x20chatWebsite\x20will\x20be\x20deleted.')[_0x3c8556('0x8e8')](_0x3c8556('0x44e'))['ok']('Delete')['cancel']('Cancel')[_0x3c8556('0x203b')](_0x50fcfa);_0x41f65b['show'](_0x5981ac)[_0x3c8556('0x1166')](function(){const _0x15acd5=_0x3c8556;_0x2f2866[_0x15acd5('0x1864')][_0x15acd5('0x906')]({'id':_0x17a6d5[_0x15acd5('0x1864')]['id']})[_0x15acd5('0xa44')][_0x15acd5('0x1166')](function(){const _0x3c873c=_0x15acd5;_0x2cfb05()[_0x3c873c('0x127f')](_0x17a6d5[_0x3c873c('0x2136')],{'id':_0x17a6d5[_0x3c873c('0x1864')]['id']}),_0x43660a['success']({'title':'ChatWebsite\x20properly\x20deleted!','msg':(_0x17a6d5[_0x3c873c('0x1864')][_0x3c873c('0x4f0')]||_0x3c873c('0x1864'))+_0x3c873c('0x7cd')}),_0x23e2a2(_0x17a6d5['chatWebsite']);})['catch'](function(_0x162ef9){const _0x49feec=_0x15acd5;if(_0x162ef9[_0x49feec('0x25f4')]&&_0x162ef9[_0x49feec('0x25f4')][_0x49feec('0x61a')]&&_0x162ef9[_0x49feec('0x25f4')]['errors'][_0x49feec('0x264b')]){_0x17a6d5['errors']=_0x162ef9[_0x49feec('0x25f4')][_0x49feec('0x61a')]||[{'message':_0x162ef9['toString'](),'type':_0x49feec('0x2234')}];for(let _0x3752dd=0x0;_0x3752dd<_0x162ef9['data'][_0x49feec('0x61a')][_0x49feec('0x264b')];_0x3752dd++){_0x43660a[_0x49feec('0xfc9')]({'title':_0x162ef9[_0x49feec('0x25f4')][_0x49feec('0x61a')][_0x3752dd]['type'],'msg':_0x162ef9[_0x49feec('0x25f4')][_0x49feec('0x61a')][_0x3752dd][_0x49feec('0x1e70')]});}}else _0x43660a[_0x49feec('0xfc9')]({'title':_0x162ef9[_0x49feec('0x52d')]?_0x49feec('0x1e21')+_0x162ef9[_0x49feec('0x52d')]+'\x20-\x20'+_0x162ef9[_0x49feec('0xe1b')]:_0x49feec('0x2234'),'msg':_0x162ef9[_0x49feec('0x25f4')]?JSON[_0x49feec('0xbac')](_0x162ef9['data']['message']):_0x162ef9['message']||_0x162ef9[_0x49feec('0x1586')]()});});},function(){});}function _0xf7cd04(_0x4c9e74){return _0x4c9e74===null?undefined:new Date(_0x4c9e74);}function _0x23e2a2(_0x55f49f){const _0x1d9049=_0x2e1b35;_0x41f65b[_0x1d9049('0x1197')](_0x55f49f);}}const _0x1e5902=_0x4eed05,_0x11d197=_0x2734b2['p']+_0x36e6f4('0x3f1'),_0x510812=_0x2734b2['p']+_0x36e6f4('0x12a0'),_0x5c0288=_0x2734b2['p']+_0x36e6f4('0x127b'),_0x3c6d8e=_0x2734b2['p']+_0x36e6f4('0xdff'),_0x27efb6=_0x2734b2['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/dialogflow/dialog.html/dialog.html',_0x5bdc59=_0x2734b2['p']+_0x36e6f4('0x330'),_0x2ceac0=_0x2734b2['p']+_0x36e6f4('0x2530'),_0x1f23e0=_0x2734b2['p']+_0x36e6f4('0x2475'),_0x50f69e=_0x2734b2['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/noop/dialog.html/dialog.html',_0x5617ad=_0x2734b2['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/queue/dialog.html/dialog.html',_0x2a1d7c=_0x2734b2['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/system/dialog.html/dialog.html',_0x48636c=_0x2734b2['p']+_0x36e6f4('0x1fa4');_0x5eab63['$inject']=[_0x36e6f4('0x19e3'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];const _0x526f48={'agent':_0x11d197,'amazonlex':_0x510812,'autoreply':_0x5c0288,'close':_0x3c6d8e,'dialogflow':_0x27efb6,'gotoif':_0x5bdc59,'gotop':_0x2ceac0,'interval':_0x1f23e0,'noop':_0x50f69e,'queue':_0x5617ad,'system':_0x2a1d7c,'tag':_0x48636c};function _0x5eab63(_0x1249ee,_0x3b0081,_0x28e880,_0x413f78,_0x1997cf){const _0x5173b9=_0x36e6f4,_0x3c96bc=this;_0x3c96bc[_0x5173b9('0x98')]=_0x1997cf[_0x5173b9('0x26cd')](),_0x3c96bc['chatWebsite']={},_0x3c96bc[_0x5173b9('0x2862')]={'count':0x0,'rows':[]},_0x3c96bc['selectedChatWebsiteApps']=[],_0x3c96bc[_0x5173b9('0x243c')],_0x3c96bc['query']={'sort':_0x5173b9('0xfde')},_0x3c96bc[_0x5173b9('0x24d2')]=_0x2cfb05()[_0x5173b9('0x21bf')](_0x2cfb05()['sortBy']([{'app':_0x5173b9('0x1545'),'appType':_0x5173b9('0x277c'),'types':[_0x5173b9('0x597'),'custom',_0x5173b9('0x1480')],'fields':[],'isApp':![]},{'app':_0x5173b9('0x2652'),'appType':_0x5173b9('0x2652'),'type':_0x5173b9('0x2652'),'icon':_0x5173b9('0x283f'),'interval':'*,*,*,*','required':!![],'isApp':!![],'fields':[{'title':_0x5173b9('0x1efa'),'name':_0x5173b9('0x18e0'),'type':_0x5173b9('0x1640'),'param':0x0}]},{'app':'system','appType':'system','type':_0x5173b9('0x1c2b'),'icon':_0x5173b9('0x283f'),'interval':'*,*,*,*','required':!![],'isApp':!![],'extraApi':[{'name':_0x5173b9('0x57a'),'field':{'name':_0x5173b9('0x734'),'key':'name'},'route':'variable','filters':{'fields':_0x5173b9('0x1776'),'sort':_0x5173b9('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':_0x5173b9('0xd5'),'name':_0x5173b9('0x187'),'type':_0x5173b9('0x1640'),'required':!![],'param':0x0},{'title':_0x5173b9('0x2d5'),'name':_0x5173b9('0x734'),'type':_0x5173b9('0x2550'),'values':_0x5173b9('0x57a'),'value':_0x5173b9('0x15f0'),'option':_0x5173b9('0x15f0'),'defaultValues':[{'value':'\x27\x27','option':_0x5173b9('0x1280')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':'gotop','appType':_0x5173b9('0x6e6'),'type':'goto','icon':_0x5173b9('0x283f'),'interval':_0x5173b9('0x16f'),'isApp':!![],'fields':[{'title':_0x5173b9('0x9c2'),'name':'priority','type':_0x5173b9('0xc45'),'required':!![],'min':0x0,'param':0x0}]},{'app':_0x5173b9('0x30f'),'appType':_0x5173b9('0x30f'),'type':_0x5173b9('0x30f'),'icon':'icon-apps','interval':_0x5173b9('0x16f'),'isApp':!![],'fields':[{'title':'Condition','name':'condition','type':'text','required':!![],'param':0x0},{'title':'truepriority','name':_0x5173b9('0x13a6'),'type':_0x5173b9('0xc45'),'min':0x1,'required':!![],'param':0x1},{'title':_0x5173b9('0x1d7a'),'name':_0x5173b9('0x1d7a'),'type':_0x5173b9('0xc45'),'min':0x1,'required':!![],'param':0x2}]},{'app':_0x5173b9('0x1d3e'),'appType':'queue','foreignKey':_0x5173b9('0x23f7'),'type':_0x5173b9('0x1d3e'),'icon':_0x5173b9('0x283f'),'interval':_0x5173b9('0x16f'),'isApp':!![],'extraApi':[{'name':_0x5173b9('0x7a7'),'field':{'name':_0x5173b9('0x1d3e'),'key':_0x5173b9('0x4f0')},'route':'chatQueue','filters':{'fields':_0x5173b9('0x1c09'),'sort':_0x5173b9('0x4f0'),'nolimit':!![]},'permissions':{'section':0x1f5}}],'fields':[{'title':_0x5173b9('0x28ba'),'name':_0x5173b9('0x1d3e'),'type':_0x5173b9('0x2550'),'values':_0x5173b9('0x7a7'),'value':'queue.name','option':_0x5173b9('0x24ad'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':_0x5173b9('0x1861'),'name':_0x5173b9('0x651'),'type':_0x5173b9('0xc45'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x12c,'param':0x1}]},{'app':_0x5173b9('0x1eff'),'appType':'agent','type':_0x5173b9('0x1eff'),'foreignKey':_0x5173b9('0x122a'),'icon':'icon-apps','interval':_0x5173b9('0x16f'),'isApp':!![],'extraApi':[{'name':'agents','field':{'name':_0x5173b9('0x1eff'),'key':_0x5173b9('0x4f0')},'route':_0x5173b9('0x557'),'filters':{'fields':'id,name','role':_0x5173b9('0x1eff'),'sort':_0x5173b9('0x4f0'),'nolimit':!![]},'permissions':{'section':0xca}}],'fields':[{'title':_0x5173b9('0x89b'),'name':_0x5173b9('0x1eff'),'type':_0x5173b9('0x2550'),'values':_0x5173b9('0x1f7e'),'value':_0x5173b9('0x1530'),'option':_0x5173b9('0x1530'),'required':!![],'param':0x0},{'title':'Timeout','name':_0x5173b9('0x651'),'type':_0x5173b9('0xc45'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':_0x5173b9('0x1a7b'),'appType':'close','type':'close','icon':'icon-apps','interval':_0x5173b9('0x16f'),'isApp':!![],'fields':[{'title':_0x5173b9('0x9b9'),'name':_0x5173b9('0x12e8'),'type':_0x5173b9('0x1640'),'required':!![],'param':0x0}]},{'app':_0x5173b9('0x1af7'),'appType':_0x5173b9('0x1af7'),'type':_0x5173b9('0x1af7'),'icon':_0x5173b9('0x283f'),'interval':_0x5173b9('0x16f'),'isApp':!![],'fields':[{'title':_0x5173b9('0x265e'),'name':_0x5173b9('0x265e'),'type':_0x5173b9('0x88a'),'defaultValue':'1','values':[{'option':_0x5173b9('0xbe0'),'value':'1'},{'option':_0x5173b9('0x70f'),'value':'0'}],'required':!![],'param':0x0},{'title':_0x5173b9('0xef7'),'name':_0x5173b9('0x1640'),'type':_0x5173b9('0x489'),'required':!![],'param':0x1}]},{'app':_0x5173b9('0x1446'),'appType':_0x5173b9('0x1446'),'type':'tag','foreignKey':'TagId','icon':_0x5173b9('0x283f'),'interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':_0x5173b9('0xb38'),'field':{'name':'tag','key':_0x5173b9('0x4f0')},'route':'tag','filters':{'fields':'id,name','sort':_0x5173b9('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x5173b9('0x1b35'),'name':_0x5173b9('0x1446'),'type':_0x5173b9('0x2550'),'values':_0x5173b9('0xb38'),'value':_0x5173b9('0xc2c'),'option':_0x5173b9('0xc2c'),'required':!![],'param':0x0}]},{'app':_0x5173b9('0xded'),'appType':_0x5173b9('0xded'),'type':_0x5173b9('0xded'),'icon':_0x5173b9('0x283f'),'interval':_0x5173b9('0x16f'),'isApp':!![],'fields':[{'title':_0x5173b9('0x2eb'),'name':'key','type':_0x5173b9('0x1640'),'required':!![],'param':0x0},{'title':_0x5173b9('0xedb'),'name':'language','type':_0x5173b9('0x88a'),'defaultValue':'\x27en\x27','values':[{'option':_0x5173b9('0x7a4'),'value':_0x5173b9('0xacf')},{'option':_0x5173b9('0x1852'),'value':_0x5173b9('0x17bf')},{'option':'German','value':_0x5173b9('0x15bd')},{'option':'Italian','value':'\x27it\x27'},{'option':_0x5173b9('0x2246'),'value':_0x5173b9('0x14d0')},{'option':'French','value':_0x5173b9('0x5f0')},{'option':_0x5173b9('0xebe'),'value':_0x5173b9('0x2872')},{'option':_0x5173b9('0x2688'),'value':_0x5173b9('0x1764')},{'option':'Korean\x20(South\x20Korea)','value':_0x5173b9('0x82e')},{'option':_0x5173b9('0x1025'),'value':_0x5173b9('0x4f5')},{'option':_0x5173b9('0x522'),'value':_0x5173b9('0x119b')},{'option':'Portuguese\x20(European)','value':_0x5173b9('0x145d')},{'option':_0x5173b9('0x2528'),'value':_0x5173b9('0x1136')},{'option':_0x5173b9('0xf22'),'value':'\x27ru\x27'},{'option':'Swedish','value':_0x5173b9('0x297')},{'option':_0x5173b9('0x24f9'),'value':'\x27th\x27'},{'option':_0x5173b9('0xd6b'),'value':_0x5173b9('0x38e')},{'option':'Chinese\x20(Simplified)','value':'\x27zh-CN\x27'},{'option':'Chinese\x20(Hong\x20Kong)','value':_0x5173b9('0x21c7')},{'option':_0x5173b9('0x145a'),'value':_0x5173b9('0x2348')}],'required':!![],'param':0x1},{'title':'welcomemessage','name':'welcomemessage','type':_0x5173b9('0x489'),'maxlength':0xff,'param':0x2,'help':!![]}]},{'app':'dialogflowV2','appType':'dialogflowv2','type':'dialogflowv2','icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x5173b9('0x23'),'name':_0x5173b9('0x1b0a'),'type':_0x5173b9('0x1640'),'required':!![],'param':0x0},{'title':_0x5173b9('0x23e3'),'name':_0x5173b9('0x27f3'),'type':_0x5173b9('0x1640'),'required':!![],'param':0x1},{'title':'PrivateKey','name':_0x5173b9('0x170e'),'type':_0x5173b9('0x489'),'required':!![],'param':0x2},{'title':'language','name':_0x5173b9('0xedb'),'type':'select','defaultValue':_0x5173b9('0x17bf'),'values':[{'value':_0x5173b9('0x21c7'),'option':_0x5173b9('0x2837')},{'value':_0x5173b9('0x244a'),'option':_0x5173b9('0xefc')},{'value':_0x5173b9('0x2348'),'option':_0x5173b9('0x145a')},{'value':_0x5173b9('0xacf'),'option':_0x5173b9('0x7a4')},{'value':_0x5173b9('0x4f5'),'option':_0x5173b9('0x1025')},{'value':_0x5173b9('0x17bf'),'option':_0x5173b9('0x1852')},{'value':_0x5173b9('0x457'),'option':_0x5173b9('0x27a0')},{'value':_0x5173b9('0x2270'),'option':_0x5173b9('0x28b8')},{'value':'\x27en-GB\x27','option':_0x5173b9('0x1cdd')},{'value':_0x5173b9('0xbc6'),'option':_0x5173b9('0x655')},{'value':_0x5173b9('0x25ba'),'option':_0x5173b9('0x1f4')},{'value':'\x27fr\x27','option':_0x5173b9('0x2746')},{'value':_0x5173b9('0x391'),'option':_0x5173b9('0x19bd')},{'value':_0x5173b9('0x1cb9'),'option':_0x5173b9('0x18e4')},{'value':_0x5173b9('0x15bd'),'option':_0x5173b9('0x20f')},{'value':_0x5173b9('0x9bd'),'option':_0x5173b9('0x473')},{'value':_0x5173b9('0x2872'),'option':_0x5173b9('0xebe')},{'value':'\x27it\x27','option':'Italian'},{'value':'\x27ja\x27','option':_0x5173b9('0x2688')},{'value':_0x5173b9('0x82e'),'option':_0x5173b9('0x511')},{'value':_0x5173b9('0x119b'),'option':'Norwegian'},{'value':_0x5173b9('0x27c'),'option':_0x5173b9('0x19b3')},{'value':_0x5173b9('0x271c'),'option':'Portuguese\x20(Brazil)'},{'value':_0x5173b9('0x24bd'),'option':_0x5173b9('0x1336')},{'value':_0x5173b9('0x543'),'option':_0x5173b9('0xf22')},{'value':_0x5173b9('0x14d0'),'option':'Spanish'},{'value':'\x27es-419\x27','option':_0x5173b9('0x9e5')},{'value':_0x5173b9('0x1cfa'),'option':_0x5173b9('0x1f75')},{'value':_0x5173b9('0x1ae8'),'option':_0x5173b9('0x277e')},{'value':_0x5173b9('0x1d2b'),'option':_0x5173b9('0x24f9')},{'value':_0x5173b9('0x1d58'),'option':_0x5173b9('0x71a')},{'value':_0x5173b9('0x38e'),'option':'Ukrainian'}],'required':!![],'param':0x3},{'title':_0x5173b9('0x1634'),'name':'welcomemessage','type':'textarea','maxlength':0xff,'param':0x4,'help':!![]}]},{'app':'amazonlex','appType':'amazonlex','type':'amazonlex','icon':_0x5173b9('0x283f'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x5173b9('0xee6'),'name':'accesskeyid','type':_0x5173b9('0x1640'),'required':!![],'param':0x0},{'title':_0x5173b9('0x125'),'name':_0x5173b9('0x125'),'type':_0x5173b9('0x1640'),'required':!![],'param':0x1},{'title':_0x5173b9('0x25a2'),'name':'lexregion','type':_0x5173b9('0x88a'),'defaultValue':'\x27us-east-1\x27','values':[{'option':_0x5173b9('0xc64'),'value':_0x5173b9('0x2891')},{'option':_0x5173b9('0x1fbb'),'value':_0x5173b9('0x27b2')},{'option':'EU\x20(Ireland)','value':_0x5173b9('0x658')},{'option':_0x5173b9('0xac9'),'value':_0x5173b9('0xaed')}],'required':!![],'param':0x2},{'title':'botname','name':'botname','type':_0x5173b9('0x1640'),'required':!![],'param':0x3},{'title':_0x5173b9('0x1634'),'name':_0x5173b9('0x1634'),'type':_0x5173b9('0x489'),'maxlength':0xff,'param':0x4,'help':!![]}]}],['app']),{'isApp':![]}),_0x3c96bc['list']={'group':{'name':_0x5173b9('0x1b27'),'pull':_0x5173b9('0xddc')},'animation':0x64,'sort':![]},_0x3c96bc[_0x5173b9('0x227f')]={'group':{'name':'opt2','put':_0x5173b9('0x1b27')},'animation':0x64,'onAdd':function(_0x419c71){const _0x4fe266=_0x5173b9;_0xefebec(_0x419c71,_0x419c71[_0x4fe266('0x1313')]);},'onSort':function(){_0x36c331();}},_0x3c96bc[_0x5173b9('0x24d5')]=_0x144c2c,_0x3c96bc[_0x5173b9('0x8a2')]=_0x5a8192,_0x3c96bc['getChatWebsiteApps']=_0x1a3748,_0x3c96bc['editChatWebsiteApp']=_0xefebec,_0x3c96bc[_0x5173b9('0x1a93')]=_0x1b8e9f,_0x3c96bc[_0x5173b9('0x2335')]=_0x36f372,_0x3c96bc[_0x5173b9('0x5bd')]=_0x4b6d30,_0x3c96bc[_0x5173b9('0x20a6')]=_0x36c331,_0x3c96bc[_0x5173b9('0x242')]=_0x30a9f3;function _0x144c2c(_0x4b2292,_0x59882c){const _0x56fe3a=_0x5173b9;_0x3c96bc[_0x56fe3a('0x1864')]=_0x4b2292,_0x3c96bc[_0x56fe3a('0x243c')]=typeof _0x59882c!==_0x56fe3a('0x1048')?_0x59882c:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3c96bc['applications'][_0x56fe3a('0xbd0')]=!_0x3c96bc[_0x56fe3a('0x243c')][_0x56fe3a('0x1684')]?!![]:![],_0x3c96bc[_0x56fe3a('0x2218')]['id']=_0x4b2292['id'],_0x3c96bc[_0x56fe3a('0x2218')][_0x56fe3a('0x1a55')]=!![],_0x3c96bc[_0x56fe3a('0x2218')][_0x56fe3a('0x49d')]=!![],_0x3c96bc[_0x56fe3a('0x1aee')](),_0x3c96bc[_0x56fe3a('0x242')]();}function _0x5a8192(_0x10f842,_0x5a2769,_0x5ae254){const _0x11c3c1=_0x5173b9,_0x27e8b9=_0x3b0081[_0x11c3c1('0x1d26')]()[_0x11c3c1('0xcdc')](_0x11c3c1('0xd0f'))[_0x11c3c1('0xf3c')](_0x11c3c1('0x12b5')+_0x10f842[_0x11c3c1('0x746')]+_0x11c3c1('0xace')+_0x11c3c1('0x3f3'))[_0x11c3c1('0x8e8')](_0x11c3c1('0x238d'))[_0x11c3c1('0x203b')](_0x5ae254)['ok']('OK')[_0x11c3c1('0x3f')]('CANCEL');_0x3b0081[_0x11c3c1('0x1f80')](_0x27e8b9)[_0x11c3c1('0x1166')](function(){const _0x13fb7=_0x11c3c1;_0x3c96bc[_0x13fb7('0x2862')][_0x13fb7('0x269a')]['splice'](_0x5a2769,0x1),_0x36c331();},function(){const _0x1c593e=_0x11c3c1;console[_0x1c593e('0x455')]('CANCEL');});}function _0xefebec(_0x55ad5d,_0x5674f1){const _0x3c7e0b=_0x5173b9;if(_0x3c96bc[_0x3c7e0b('0x2862')][_0x3c7e0b('0x269a')]['length']){const _0x337d77=_0x3c96bc['chatWebsiteApps'][_0x3c7e0b('0x269a')][_0x5674f1]?_0x3c96bc[_0x3c7e0b('0x2862')]['rows'][_0x5674f1]:_0x3c96bc[_0x3c7e0b('0x2862')][_0x3c7e0b('0x269a')][0x0],_0x442775=(_0x337d77[_0x3c7e0b('0x83f')]||_0x337d77[_0x3c7e0b('0x746')])[_0x3c7e0b('0x2574')]();_0x3b0081['show']({'controller':_0x3c7e0b('0x729')+_0x442775+_0x3c7e0b('0x8a4'),'controllerAs':'vm','templateUrl':_0x526f48[_0x442775],'parent':angular[_0x3c7e0b('0x1194')](_0x28e880[_0x3c7e0b('0x8d2')]),'targetEvent':_0x55ad5d,'clickOutsideToClose':!![],'locals':{'chatWebsiteApp':_0x337d77,'chatWebsite':_0x3c96bc[_0x3c7e0b('0x1864')],'crudPermissions':_0x3c96bc[_0x3c7e0b('0x243c')]}})[_0x3c7e0b('0x1166')](function(_0x5de1bc){const _0x5923ee=_0x3c7e0b;_0x5de1bc&&(_0x5de1bc['id']?_0x3c96bc[_0x5923ee('0x2862')][_0x5923ee('0x269a')][_0x5674f1]=_0x5de1bc:_0x3c96bc[_0x5923ee('0x2862')][_0x5923ee('0x269a')][_0x5923ee('0x57b')](_0x5674f1,0x0,_0x5de1bc),_0x36c331());})[_0x3c7e0b('0x1a80')](function(_0x22be91){const _0x13b3f8=_0x3c7e0b;_0x22be91&&_0x413f78[_0x13b3f8('0xfc9')]({'title':_0x22be91[_0x13b3f8('0x52d')]?_0x13b3f8('0x1e21')+_0x22be91['status']+_0x13b3f8('0x11e1')+_0x22be91[_0x13b3f8('0xe1b')]:_0x13b3f8('0x2e5'),'msg':_0x22be91[_0x13b3f8('0x25f4')]?JSON['stringify'](_0x22be91[_0x13b3f8('0x25f4')]):_0x22be91['toString']()});});}}function _0x1b8e9f(_0x2f92b8,_0xe8b694){const _0x4ec23f=_0x5173b9;if(_0x3c96bc[_0x4ec23f('0x2862')][_0x4ec23f('0x269a')][_0x4ec23f('0x264b')]){const _0x27d9e4=_0x3c96bc[_0x4ec23f('0x2862')]['rows'][_0xe8b694]?_0x3c96bc[_0x4ec23f('0x2862')][_0x4ec23f('0x269a')][_0xe8b694]:_0x3c96bc[_0x4ec23f('0x2862')]['rows'][0x0];_0x3b0081[_0x4ec23f('0x1f80')]({'controller':'EditChatWebsiteAppintervalDialogController','controllerAs':'vm','templateUrl':_0x1f23e0,'parent':angular[_0x4ec23f('0x1194')](_0x28e880[_0x4ec23f('0x8d2')]),'targetEvent':_0x2f92b8,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x27d9e4[_0x4ec23f('0x277c')],'IntervalId':_0x27d9e4[_0x4ec23f('0x186f')],'application':!![]},'intervals':[],'crudPermissions':_0x3c96bc['crudPermissions']}})[_0x4ec23f('0x1166')](function(_0x41dfc7){const _0x36ddb8=_0x4ec23f;_0x41dfc7&&(_0x27d9e4[_0x36ddb8('0x277c')]=_0x41dfc7[_0x36ddb8('0x277c')]||'*,*,*,*',_0x27d9e4['IntervalId']=_0x41dfc7['IntervalId']||null,_0x36c331());});}}function _0x36c331(){const _0x56a71f=_0x5173b9;let _0x226461=0x1,_0x475366=[];for(let _0x9d216d=0x0;_0x9d216d<_0x3c96bc[_0x56a71f('0x2862')][_0x56a71f('0x269a')][_0x56a71f('0x264b')];_0x9d216d++){const _0x4e7a7a=_0x3c96bc[_0x56a71f('0x2862')][_0x56a71f('0x269a')][_0x9d216d],_0x17e7b7=[],_0x3e79b7=[];_0x4e7a7a[_0x56a71f('0x164e')]=_0x4e7a7a['interval']!==_0x56a71f('0x16f')?[_0x4e7a7a[_0x56a71f('0x277c')]]:_0x4e7a7a[_0x56a71f('0x186f')]?_0x2cfb05()[_0x56a71f('0x2563')](_0x2cfb05()[_0x56a71f('0x1c33')](_0x3c96bc[_0x56a71f('0x164e')][_0x56a71f('0x269a')],{'IntervalId':_0x4e7a7a[_0x56a71f('0x186f')]}),_0x56a71f('0x277c')):[],_0x4e7a7a['context']=_0x3c96bc[_0x56a71f('0x1864')]['context'],_0x4e7a7a[_0x56a71f('0x23ae')]=_0x3c96bc[_0x56a71f('0x1864')]['exten'],_0x4e7a7a[_0x56a71f('0x1345')]&&(_0x4e7a7a[_0x56a71f('0x1345')]=_0x4e7a7a[_0x56a71f('0x1345')]['toLowerCase']()),_0x4e7a7a['priority']=_0x17e7b7[_0x56a71f('0x264b')]?_0x2cfb05()[_0x56a71f('0x1ef5')](_0x17e7b7)[_0x56a71f('0xfde')]+0x1:_0x226461,_0x226461=(_0x3e79b7[_0x56a71f('0x264b')]?_0x2cfb05()[_0x56a71f('0x1ef5')](_0x3e79b7)[_0x56a71f('0xfde')]:_0x4e7a7a[_0x56a71f('0xfde')])+0x1,_0x475366=_0x2cfb05()[_0x56a71f('0x1c6a')](_0x475366,_0x17e7b7,[_0x4e7a7a],_0x3e79b7);}_0x1249ee['chatWebsite'][_0x56a71f('0x153b')]({'id':_0x3c96bc[_0x56a71f('0x1864')]['id']},_0x2cfb05()[_0x56a71f('0x1eba')](_0x475366,'priority'))[_0x56a71f('0xa44')][_0x56a71f('0x1166')](function(_0x53765f){const _0x41e77a=_0x56a71f;_0x3c96bc[_0x41e77a('0x2862')][_0x41e77a('0x269a')]=_0x53765f['rows'];})[_0x56a71f('0x1a80')](function(_0x2b3df1){const _0x4cbb9f=_0x56a71f;console[_0x4cbb9f('0xfc9')](_0x2b3df1);});}function _0x503260(_0x2cf87f){const _0x17263c=_0x5173b9;_0x3c96bc[_0x17263c('0x2862')]=_0x2cf87f||{'count':0x0,'rows':[]};}function _0x30a9f3(){const _0x339b1e=_0x5173b9;return _0x1249ee[_0x339b1e('0x277c')]['get']({'fields':_0x339b1e('0x1d39')})['$promise'][_0x339b1e('0x1166')](function(_0x3be027){const _0x64a595=_0x339b1e;_0x3c96bc[_0x64a595('0x164e')]=_0x3be027;})[_0x339b1e('0x1a80')](function(_0x276b65){const _0x2841e8=_0x339b1e;console[_0x2841e8('0xfc9')](_0x276b65);});}function _0x1a3748(){const _0xba7111=_0x5173b9;_0x3c96bc[_0xba7111('0x1f48')]=_0x1249ee[_0xba7111('0x1864')]['getApplications'](_0x3c96bc['query'],_0x503260)[_0xba7111('0xa44')];}function _0x36f372(_0xe80c16){const _0x299174=_0x5173b9;_0x2cfb05()[_0x299174('0x127f')](_0x3c96bc[_0x299174('0x2862')][_0x299174('0x269a')],{'id':_0xe80c16['id']}),_0x36c331(),_0x413f78[_0x299174('0x103b')]({'title':_0x299174('0x11c0'),'msg':_0xe80c16[_0x299174('0x746')]?_0xe80c16[_0x299174('0x746')]+'\x20has\x20been\x20deleted!':''});}function _0x4b6d30(_0x1d117d){const _0x85318=_0x5173b9,_0x4e4269=_0x3b0081['confirm']()['title'](_0x85318('0x2338'))[_0x85318('0xf3c')](_0x85318('0x12b5')+_0x3c96bc[_0x85318('0x25bd')][_0x85318('0x264b')]+_0x85318('0x196d')+_0x85318('0x3f3'))[_0x85318('0x8e8')]('delete\x20applications')[_0x85318('0x203b')](_0x1d117d)['ok']('OK')[_0x85318('0x3f')](_0x85318('0x2d3'));_0x3b0081[_0x85318('0x1f80')](_0x4e4269)[_0x85318('0x1166')](function(){const _0xec7278=_0x85318;_0x3c96bc[_0xec7278('0x25bd')][_0xec7278('0x2782')](function(_0x35e9f8){const _0x28a92c=_0xec7278;_0x2cfb05()[_0x28a92c('0x127f')](_0x3c96bc[_0x28a92c('0x2862')][_0x28a92c('0x269a')],{'id':_0x35e9f8['id']});}),_0x3c96bc[_0xec7278('0x25bd')]=[],_0x36c331();});}}const _0x2f1d0e=_0x5eab63;_0x2d26f5[_0x36e6f4('0x1294')]=['$mdDialog','$q','toasty',_0x36e6f4('0x19e3'),'chatWebsite',_0x36e6f4('0x2136'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x2d26f5(_0x5b42f7,_0xf7151,_0x1551ea,_0x617107,_0x5255c4,_0x497c20,_0x266c09,_0x1ef32a,_0x110ee3,_0x2d76b3){const _0x29847e=_0x36e6f4,_0x4d74da=this;_0x4d74da[_0x29847e('0x98')]=_0x110ee3[_0x29847e('0x26cd')](),_0x4d74da['chatWebsite']=_0x5255c4,_0x4d74da[_0x29847e('0x243c')]=_0x2d76b3,_0x4d74da['realtime']=_0x266c09,_0x4d74da[_0x29847e('0xbd7')]=[],_0x4d74da[_0x29847e('0x10ab')]=[],_0x4d74da['selectedItems']=[],_0x4d74da[_0x29847e('0x2111')]=[],_0x4d74da['startingSelectedItems']=[],_0x4d74da['pendingChanges']=![],_0x4d74da[_0x29847e('0xae0')]=_0x51185d,_0x4d74da[_0x29847e('0x1d92')]=_0x576c15,_0x4d74da[_0x29847e('0x24a0')]=_0x20d529,_0x4d74da[_0x29847e('0xc68')]={'readOnly':!_0x4d74da[_0x29847e('0x243c')]['canEdit'],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x29847e('0x4f0'),'line1':'fullname','line2':[_0x29847e('0x4f0'),_0x29847e('0x1eef')],'line3':'','labelAll':_0x1ef32a[_0x29847e('0x25cc')](_0x29847e('0x958')),'labelSelected':_0x1ef32a[_0x29847e('0x25cc')](_0x29847e('0x14db')),'transferCallback':function(){const _0x34d0b2=_0x29847e,_0x24e7af=_0x2cfb05()[_0x34d0b2('0x2802')](_0x4d74da['startingSelectedItems'],_0x4d74da['selectedItems'],'id');_0x4d74da['pendingChanges']=_0x2cfb05()[_0x34d0b2('0x1081')](_0x24e7af)?![]:!![];}};function _0x51185d(){const _0x3e893f=_0x29847e;return _0x110ee3['hasRole'](_0x3e893f('0xa7c'))?_0x5b919d()[_0x3e893f('0x1a80')](function(_0x34c124){const _0x5dc3db=_0x3e893f;_0x1551ea[_0x5dc3db('0xfc9')]({'title':_0x34c124[_0x5dc3db('0x52d')]?_0x5dc3db('0x1e21')+_0x34c124['status']+_0x5dc3db('0x11e1')+_0x34c124[_0x5dc3db('0xe1b')]:_0x5dc3db('0xd4c'),'msg':_0x34c124[_0x5dc3db('0x52d')]?JSON[_0x5dc3db('0xbac')](_0x34c124[_0x5dc3db('0x25f4')]):_0x34c124[_0x5dc3db('0x1586')]()});}):_0x3384c3()[_0x3e893f('0x1166')](function(_0xe7c561){return _0x4d74da['section']=_0xe7c561,_0x5b919d();})[_0x3e893f('0x1a80')](function(_0x252383){const _0x37ecf3=_0x3e893f;_0x1551ea[_0x37ecf3('0xfc9')]({'title':_0x252383[_0x37ecf3('0x52d')]?_0x37ecf3('0x1e21')+_0x252383['status']+'\x20-\x20'+_0x252383[_0x37ecf3('0xe1b')]:_0x37ecf3('0xd4c'),'msg':_0x252383[_0x37ecf3('0x52d')]?JSON[_0x37ecf3('0xbac')](_0x252383[_0x37ecf3('0x25f4')]):_0x252383[_0x37ecf3('0x1586')]()});});}function _0x3384c3(){return _0xf7151(function(_0x60f41f,_0x1dc32e){const _0x1f76ab=a0_0x3f2c;_0x617107[_0x1f76ab('0x17aa')][_0x1f76ab('0xd83')]({'userProfileId':_0x4d74da[_0x1f76ab('0x98')]['userProfileId'],'name':_0x1f76ab('0x2391')})['$promise'][_0x1f76ab('0x1166')](function(_0x20aab8){const _0x3986ca=_0x1f76ab,_0x2ad3f4=_0x20aab8&&_0x20aab8['rows']?_0x20aab8[_0x3986ca('0x269a')][0x0]:null;_0x60f41f(_0x2ad3f4);})['catch'](function(_0x50a8dd){_0x1dc32e(_0x50a8dd);});});}function _0x5b919d(){return _0xf7151(function(_0xd00d9e,_0x275598){const _0x421a1e=a0_0x3f2c;return _0x37be9d()[_0x421a1e('0x1166')](function(_0x77b56f){const _0x237911=_0x421a1e;return _0x4d74da['items']=_0x77b56f[_0x237911('0x269a')]?_0x77b56f[_0x237911('0x269a')]:[],_0x110ee3[_0x237911('0x1ac6')]('admin')?_0x77b56f:_0x4d74da[_0x237911('0xe60')]?_0x4d74da[_0x237911('0xe60')][_0x237911('0x1a2b')]?_0x77b56f:_0x551164():null;})[_0x421a1e('0x1166')](function(_0x1bcdc6){const _0x2c736c=_0x421a1e,_0x588957=_0x1bcdc6&&_0x1bcdc6['rows']?_0x1bcdc6[_0x2c736c('0x269a')]:[];return _0x4d74da[_0x2c736c('0x10ab')]=_0x2cfb05()[_0x2c736c('0x2563')](_0x588957,function(_0x333822){const _0x56c588=_0x2c736c;return _0x2cfb05()[_0x56c588('0xc38')](_0x4d74da[_0x56c588('0xbd7')],{'id':_0x110ee3['hasRole']('admin')||_0x4d74da[_0x56c588('0xe60')][_0x56c588('0x1a2b')]?_0x333822['id']:_0x333822[_0x56c588('0x24e8')]});}),_0x4d74da[_0x2c736c('0x2111')]=angular[_0x2c736c('0x225f')](_0x4d74da[_0x2c736c('0x10ab')]),_0x4d74da[_0x2c736c('0xbd7')][_0x2c736c('0x2782')](function(_0x3f11e7){const _0x3b21a9=_0x2c736c,_0x26a14a=_0x2cfb05()[_0x3b21a9('0xc38')](_0x4d74da[_0x3b21a9('0x10ab')],{'id':_0x3f11e7['id']});_0x110ee3[_0x3b21a9('0x1ac6')]('admin')?_0x3f11e7['isValid']=!![]:_0x3f11e7['isValid']=typeof _0x26a14a!==_0x3b21a9('0x1048')?!![]:![];}),_0x102df4();})[_0x421a1e('0x1166')](function(_0x3fac99){const _0x537dbc=_0x421a1e,_0x4ba3c5=_0x3fac99&&_0x3fac99[_0x537dbc('0x269a')]?_0x3fac99['rows']:[];_0x4d74da[_0x537dbc('0x18e1')]=_0x2cfb05()[_0x537dbc('0x2563')](_0x4ba3c5,function(_0x4c54c7){const _0x12595b=_0x537dbc,_0x4ef12e=_0x2cfb05()[_0x12595b('0xc38')](_0x4d74da[_0x12595b('0xbd7')],{'id':_0x4c54c7['id']});return _0x4ef12e['penalty']=_0x4c54c7[_0x12595b('0x956')]?_0x12595b('0x11e8')+_0x4c54c7[_0x12595b('0x956')]['penalty']:'',_0x4ef12e[_0x12595b('0x1eef')]=typeof _0x4c54c7[_0x12595b('0x1eef')]!==_0x12595b('0x1048')?'<'+_0x4c54c7['internal']+'>':'',_0x4ef12e;}),_0x4d74da[_0x537dbc('0x2781')]=angular[_0x537dbc('0x225f')](_0x4d74da[_0x537dbc('0x18e1')]),_0x4d74da[_0x537dbc('0xc68')][_0x537dbc('0x18e1')]=_0x4d74da[_0x537dbc('0x18e1')],_0x4d74da[_0x537dbc('0xc68')][_0x537dbc('0xbd7')]=_0x2cfb05()['differenceBy'](_0x4d74da[_0x537dbc('0x10ab')],_0x4d74da['dualMultiselectOptions'][_0x537dbc('0x18e1')],'id'),_0xd00d9e();})[_0x421a1e('0x1a80')](function(_0x483acd){_0x275598(_0x483acd);});});}function _0x551164(){return _0xf7151(function(_0x221682,_0x16709c){const _0x1d500a=a0_0x3f2c;return _0x617107[_0x1d500a('0x4b5')][_0x1d500a('0xd83')]({'sectionId':_0x4d74da[_0x1d500a('0xe60')]['id'],'nolimit':!![]})[_0x1d500a('0xa44')][_0x1d500a('0x1166')](function(_0xa33c0f){_0x221682(_0xa33c0f);})[_0x1d500a('0x1a80')](function(_0x4a69b5){_0x16709c(_0x4a69b5);});});}function _0x102df4(){return _0xf7151(function(_0x5f49c0,_0xef6ad7){const _0x15c693=a0_0x3f2c;return _0x617107[_0x15c693('0x1864')]['getAgents']({'id':_0x4d74da[_0x15c693('0x1864')]['id'],'fields':'id,name,internal,fullname','nolimit':!![],'role':_0x15c693('0x1eff')})[_0x15c693('0xa44')][_0x15c693('0x1166')](function(_0x35487d){_0x5f49c0(_0x35487d);})[_0x15c693('0x1a80')](function(_0x262b84){_0xef6ad7(_0x262b84);});});}function _0x37be9d(){return _0xf7151(function(_0x5cdcd0,_0x1847d7){const _0x1ee1c9=a0_0x3f2c;return _0x617107[_0x1ee1c9('0x557')][_0x1ee1c9('0xd83')]({'fields':_0x1ee1c9('0x1459'),'nolimit':!![],'role':_0x1ee1c9('0x1eff')})[_0x1ee1c9('0xa44')][_0x1ee1c9('0x1166')](function(_0x5cfb24){_0x5cdcd0(_0x5cfb24);})['catch'](function(_0xe31e41){_0x1847d7(_0xe31e41);});});}function _0x471682(_0x465c2e){return _0xf7151(function(_0x186925,_0x137d3c){const _0x5ab5f0=a0_0x3f2c;_0x2cfb05()[_0x5ab5f0('0x1081')](_0x465c2e)?_0x186925():_0x617107[_0x5ab5f0('0x1864')][_0x5ab5f0('0x275c')]({'id':_0x4d74da['chatWebsite']['id'],'ids':_0x2cfb05()['map'](_0x465c2e,'id')})['$promise'][_0x5ab5f0('0x1166')](function(){_0x186925();})[_0x5ab5f0('0x1a80')](function(_0x196465){_0x137d3c(_0x196465);});});}function _0x27916b(_0xae27c1){return _0xf7151(function(_0x5a1678,_0x326737){const _0x1bb22f=a0_0x3f2c;_0x2cfb05()[_0x1bb22f('0x1081')](_0xae27c1)?_0x5a1678():_0x617107[_0x1bb22f('0x1864')][_0x1bb22f('0x269d')]({'id':_0x4d74da[_0x1bb22f('0x1864')]['id'],'ids':_0x2cfb05()[_0x1bb22f('0x2563')](_0xae27c1,'id')})[_0x1bb22f('0xa44')][_0x1bb22f('0x1166')](function(){_0x5a1678();})[_0x1bb22f('0x1a80')](function(_0x457827){_0x326737(_0x457827);});});}function _0x576c15(){const _0x1755a1=_0x29847e,_0x1578c0=_0x2cfb05()['differenceBy'](_0x4d74da[_0x1755a1('0x2781')],_0x4d74da['selectedItems'],'id'),_0xc4d185=_0x2cfb05()[_0x1755a1('0x24ac')](_0x4d74da[_0x1755a1('0x18e1')],_0x4d74da['startingSelectedItems'],'id');return _0x27916b(_0x1578c0)['then'](function(){return _0x471682(_0xc4d185);})['then'](function(){const _0xaaff5e=_0x1755a1;_0x4d74da[_0xaaff5e('0x14d7')]=![],_0x4d74da['startingAllowedItems']=angular[_0xaaff5e('0x225f')](_0x4d74da['allowedItems']),_0x4d74da[_0xaaff5e('0x2781')]=angular[_0xaaff5e('0x225f')](_0x4d74da[_0xaaff5e('0x18e1')]),_0x1551ea[_0xaaff5e('0x103b')]({'title':'SUCCESS','msg':_0xaaff5e('0x1673')});})[_0x1755a1('0x1a80')](function(_0x386132){const _0x2a17e0=_0x1755a1;_0x1551ea[_0x2a17e0('0xfc9')]({'title':_0x386132[_0x2a17e0('0x52d')]?_0x2a17e0('0x1e21')+_0x386132['status']+_0x2a17e0('0x11e1')+_0x386132['statusText']:'SYSTEM:LISTS_ASSOCIATION','msg':_0x386132[_0x2a17e0('0x52d')]?JSON[_0x2a17e0('0xbac')](_0x386132['data']):_0x386132[_0x2a17e0('0x1586')]()});});}function _0x20d529(){_0x5b42f7['hide']();}}const _0x39468b=_0x2d26f5;_0xe919e3['$inject']=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x1d2e')];function _0xe919e3(_0xfb4327,_0x468e2c){const _0x3146a2=_0x36e6f4,_0x5115f4=this,_0x38ae35=0x8,_0x14fbf1=_0x38ae35*0x400*0x400;_0x5115f4[_0x3146a2('0x1864')]={},_0x5115f4[_0x3146a2('0x243c')],_0x5115f4['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x14fbf1,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x5115f4[_0x3146a2('0xe57')]={'flow':{}},_0x5115f4[_0x3146a2('0x1a5c')]=![],_0x5115f4[_0x3146a2('0xd20')]=_0x409e4b,_0x5115f4[_0x3146a2('0x1d40')]=_0x15c022,_0x5115f4[_0x3146a2('0x1dea')]=_0x385258,_0x5115f4[_0x3146a2('0x24d5')]=_0x2bada2;function _0x2bada2(_0x4c758a,_0x847fd8){const _0x5c42b5=_0x3146a2;_0x5115f4[_0x5c42b5('0x1864')]=angular[_0x5c42b5('0x225f')](_0x4c758a),_0x5115f4[_0x5c42b5('0x243c')]=typeof _0x847fd8!==_0x5c42b5('0x1048')?_0x847fd8:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x5115f4[_0x5c42b5('0xd67')][_0x5c42b5('0x21cc')]=_0x5c42b5('0x262d')[_0x5c42b5('0xf3')](':id',_0x5115f4[_0x5c42b5('0x1864')]['id']),_0x5115f4[_0x5c42b5('0x1864')][_0x5c42b5('0x1b17')]=[];}function _0x409e4b(_0x5a5c24){const _0x325eb0=_0x3146a2,_0x13b0e5=[_0x325eb0('0xccc'),_0x325eb0('0x1cd0')];if(!_0x2cfb05()['includes'](_0x13b0e5,_0x5a5c24[_0x325eb0('0x26a5')]()))return _0x468e2c[_0x325eb0('0xfc9')]({'title':_0x325eb0('0x27fb')+_0x5a5c24[_0x325eb0('0x26a5')](),'msg':_0x325eb0('0x1020')+_0x13b0e5['join']()}),![];if(_0x5a5c24[_0x325eb0('0x2340')]>_0x14fbf1)return _0x468e2c['error']({'title':_0x325eb0('0x11e6'),'msg':_0x325eb0('0x12c0')+_0x38ae35+'MB'}),![];const _0x16329c={'id':_0x5a5c24[_0x325eb0('0x20f4')],'file':_0x5a5c24,'type':_0x325eb0('0x32f')};return _0x5115f4['chatWebsite'][_0x325eb0('0x1b17')][_0x325eb0('0x2450')](_0x16329c),!![];}function _0x15c022(){const _0x5a4766=_0x3146a2;_0x5115f4['ngFlow'][_0x5a4766('0x13d1')][_0x5a4766('0x1ca3')]['headers']={'X-Requested-With':_0x5a4766('0x1bc1'),'Authorization':_0x5a4766('0x24d4')+_0xfb4327[_0x5a4766('0xd83')](_0x5a4766('0x10b6'))},_0x5115f4[_0x5a4766('0xe57')][_0x5a4766('0x13d1')][_0x5a4766('0x1d40')]();}function _0x385258(_0x5a3e93){const _0x418f0e=_0x3146a2;angular['forEach'](_0x5115f4[_0x418f0e('0x1864')][_0x418f0e('0x1b17')],function(_0x52fd33){const _0x2bab0f=_0x418f0e;if(_0x52fd33['id']===_0x5a3e93[_0x2bab0f('0x20f4')]){const _0x49eaea=new FileReader();_0x49eaea[_0x2bab0f('0x2030')](_0x52fd33[_0x2bab0f('0x6bd')][_0x2bab0f('0x6bd')]),_0x49eaea['onload']=function(_0x3fbb44){_0x52fd33['url']=_0x3fbb44['target']['result'];},_0x52fd33[_0x2bab0f('0x1345')]=_0x2bab0f('0x19f5');}});}}const _0x10bc22=_0xe919e3;_0x34b6a2['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'chatWebsiteApp','chatWebsite','api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x34b6a2(_0xbbcd76,_0x4d4029,_0x5ee5a9,_0x4cabe9,_0x3f9613,_0x1b73e4,_0x4c288b,_0x31a963){const _0x482767=_0x36e6f4,_0x3e07d3=this;_0x3e07d3[_0x482767('0x98')]=_0x4c288b[_0x482767('0x26cd')](),_0x3e07d3[_0x482767('0x61a')]=[],_0x3e07d3[_0x482767('0xcdc')]=_0x482767('0x1c9b')+(_0x4cabe9[_0x482767('0x83f')]||_0x4cabe9[_0x482767('0x746')])['toUpperCase'](),_0x3e07d3[_0x482767('0x1eff')]=angular['copy'](_0x4cabe9),_0x3e07d3[_0x482767('0x243c')]=_0x31a963,_0x3e07d3['hasModulePermissions']={};if(_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x823')])switch(_0x3e07d3[_0x482767('0x1eff')]['appType']?_0x3e07d3[_0x482767('0x1eff')]['appType'][_0x482767('0x2574')]():_0x3e07d3[_0x482767('0x1eff')]['app'][_0x482767('0x2574')]()){case _0x482767('0x2853'):break;case _0x482767('0xded'):{const _0x369b8b=_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x823')]['split'](',');_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x7ca')]=_0x369b8b[0x0],_0x3e07d3[_0x482767('0x1eff')][_0x482767('0xedb')]=_0x369b8b[0x1],_0x3e07d3['agent'][_0x482767('0x1634')]=_0x369b8b[_0x482767('0x233')](0x2,_0x369b8b[_0x482767('0x264b')])[_0x482767('0x45a')](',');}break;case _0x482767('0x1636'):{const _0x18357a=_0x3e07d3[_0x482767('0x1eff')]['appdata']['split'](',');_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x1b0a')]=_0x18357a[0x0],_0x3e07d3['agent'][_0x482767('0x27f3')]=_0x18357a[0x1],_0x3e07d3['agent']['privateKey']=_0x18357a[0x2],_0x3e07d3[_0x482767('0x1eff')][_0x482767('0xedb')]=_0x18357a[0x3],_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x1634')]=_0x18357a[_0x482767('0x233')](0x4,_0x18357a['length'])[_0x482767('0x45a')](',');}break;case _0x482767('0x86c'):{const _0x1bda8a=_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x823')][_0x482767('0x25c8')](',');_0x3e07d3[_0x482767('0x1eff')][_0x482767('0xee6')]=_0x1bda8a[0x0],_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x125')]=_0x1bda8a[0x1],_0x3e07d3['agent'][_0x482767('0x25a2')]=_0x1bda8a[0x2],_0x3e07d3['agent'][_0x482767('0x1ac4')]=_0x1bda8a[0x3],_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x1634')]=_0x1bda8a['slice'](0x4,_0x1bda8a[_0x482767('0x264b')])[_0x482767('0x45a')](',');}break;case _0x482767('0x1af7'):{const _0xebb12e=_0x3e07d3['agent']['appdata'][_0x482767('0x25c8')](',');_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x265e')]=isNaN(_0xebb12e[0x0])?_0xebb12e[0x0]:parseInt(_0xebb12e[0x0],0xa),_0x3e07d3[_0x482767('0x1eff')]['text']=_0xebb12e[_0x482767('0x233')](0x1,_0xebb12e[_0x482767('0x264b')])['join'](',');}break;case _0x482767('0x1e70'):_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x1640')]=_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x823')];break;case _0x482767('0xceb'):_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x4f0')]=_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x823')][_0x482767('0x25c8')]('=')[0x0],_0x3e07d3[_0x482767('0x1eff')]['value']=_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x823')][_0x482767('0x25c8')]('=')[0x1];break;case _0x482767('0x1034'):_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x2588')]=_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x823')];break;default:{const _0x2deebb=_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x823')]['split'](',');_0x3e07d3['agent'][_0x482767('0x1eff')]=_0x2cfb05()['isEmpty'](_0x2deebb[0x0])?_0x2deebb[0x0]:isNaN(_0x2deebb[0x0])?_0x2deebb[0x0]:parseInt(_0x2deebb[0x0],0xa),_0x3e07d3['agent'][_0x482767('0x651')]=_0x2cfb05()['isEmpty'](_0x2deebb[0x1])?_0x2deebb[0x1]:isNaN(_0x2deebb[0x1])?_0x2deebb[0x1]:parseInt(_0x2deebb[0x1],0xa);}break;}else _0x3e07d3['agent']['timeout']=0x1e;_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x1345')]&&_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x1345')][_0x482767('0x2574')]()===_0x482767('0x587')&&_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x83f')][_0x482767('0x2574')]()===_0x482767('0x2884')&&(_0x3e07d3['agent'][_0x482767('0x265a')]=_0x3e07d3['agent']['phone']?_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x2026')]['split']('$')[0x0]:undefined,_0x3e07d3['agent']['callerId']=_0x3e07d3['agent'][_0x482767('0x992')]?'CALLERID(all)='+_0x3e07d3[_0x482767('0x1eff')][_0x482767('0x992')]:undefined);_0x3e07d3[_0x482767('0x22f7')]=_0x4ecce5,_0x3e07d3[_0x482767('0x24a0')]=_0x584ce1,_0x4c288b[_0x482767('0x1ac6')](_0x482767('0xa7c'))?_0x1b73e4['user']['get']({'fields':_0x482767('0x1776'),'role':_0x482767('0x1eff'),'sort':_0x482767('0x4f0'),'nolimit':'true'})[_0x482767('0xa44')][_0x482767('0x1166')](function(_0x3be254){const _0x2be860=_0x482767;_0x3e07d3[_0x2be860('0x1f7e')]=_0x3be254[_0x2be860('0x269a')]||[];})[_0x482767('0x1a80')](function(_0x573fc4){const _0x31b912=_0x482767;_0x5ee5a9[_0x31b912('0xfc9')]({'title':_0x573fc4[_0x31b912('0x52d')]?_0x31b912('0x1e21')+_0x573fc4[_0x31b912('0x52d')]+_0x31b912('0x11e1')+_0x573fc4[_0x31b912('0xe1b')]:_0x31b912('0xd4c'),'msg':_0x573fc4['data']?JSON['stringify'](_0x573fc4['data']):_0x573fc4['toString']()});}):_0x1b73e4[_0x482767('0x557')][_0x482767('0xd83')]({'fields':_0x482767('0x1776'),'role':_0x482767('0x1eff'),'sort':_0x482767('0x4f0'),'nolimit':'true'})[_0x482767('0xa44')][_0x482767('0x1166')](function(_0x30e03b){const _0x49612a=_0x482767;_0x3e07d3[_0x49612a('0x1f7e')]=_0x30e03b[_0x49612a('0x269a')]||[];})[_0x482767('0x1166')](function(){const _0x412b6d=_0x482767;return _0x1b73e4[_0x412b6d('0x17aa')][_0x412b6d('0xd83')]({'userProfileId':_0x3e07d3[_0x412b6d('0x98')][_0x412b6d('0xb86')],'sectionId':0xca})['$promise'];})[_0x482767('0x1166')](function(_0x1c3b4e){const _0x1c51dd=_0x482767,_0x41e2c4=_0x1c3b4e&&_0x1c3b4e[_0x1c51dd('0x269a')]?_0x1c3b4e['rows'][0x0]:null;if(!_0x41e2c4){const _0x225198=[];let _0x4b4ef7=null;_0x3e07d3[_0x1c51dd('0x1eff')]&&(_0x4b4ef7=_0x2cfb05()['find'](_0x3e07d3[_0x1c51dd('0x1f7e')],{'name':_0x3e07d3[_0x1c51dd('0x1eff')][_0x1c51dd('0x1eff')]}));for(let _0x72e33a=0x0;_0x72e33a<_0x3e07d3[_0x1c51dd('0x1f7e')][_0x1c51dd('0x264b')];_0x72e33a++){_0x4b4ef7&&_0x3e07d3[_0x1c51dd('0x1f7e')][_0x72e33a]['id']===_0x4b4ef7['id']&&(_0x3e07d3['agents'][_0x72e33a][_0x1c51dd('0x2378')]=![],_0x225198[_0x1c51dd('0x1514')](_0x3e07d3[_0x1c51dd('0x1f7e')][_0x72e33a]));}_0x3e07d3[_0x1c51dd('0x1f7e')]=_0x225198;}else{if(!_0x41e2c4[_0x1c51dd('0x1a2b')])return _0x1b73e4[_0x1c51dd('0x4b5')][_0x1c51dd('0xd83')]({'sectionId':_0x41e2c4['id']})[_0x1c51dd('0xa44')][_0x1c51dd('0x1166')](function(_0x4a5c57){const _0x430ae4=_0x1c51dd,_0x464613=_0x2cfb05()['map'](_0x4a5c57['rows'],function(_0x3a819f){const _0x1d9eed=a0_0x3f2c;return _0x2cfb05()[_0x1d9eed('0xc38')](_0x3e07d3[_0x1d9eed('0x1f7e')],{'id':_0x3a819f[_0x1d9eed('0x24e8')]});});let _0x38b918=null;_0x3e07d3[_0x430ae4('0x1eff')]&&(_0x38b918=_0x2cfb05()['find'](_0x3e07d3[_0x430ae4('0x1f7e')],{'name':_0x3e07d3[_0x430ae4('0x1eff')][_0x430ae4('0x1eff')]}));if(_0x38b918&&!_0x2cfb05()['some'](_0x464613,['id',_0x38b918['id']])){const _0x2dce58=_0x2cfb05()['find'](_0x3e07d3[_0x430ae4('0x1f7e')],{'id':_0x38b918['id']});_0x2dce58[_0x430ae4('0x2378')]=![],_0x464613['push'](_0x2dce58);}_0x3e07d3[_0x430ae4('0x1f7e')]=_0x464613;});}})[_0x482767('0x1a80')](function(_0x4c4302){const _0x461b12=_0x482767;_0x5ee5a9[_0x461b12('0xfc9')]({'title':_0x4c4302[_0x461b12('0x52d')]?_0x461b12('0x1e21')+_0x4c4302['status']+_0x461b12('0x11e1')+_0x4c4302[_0x461b12('0xe1b')]:_0x461b12('0xdc5'),'msg':_0x4c4302['data']?JSON[_0x461b12('0xbac')](_0x4c4302[_0x461b12('0x25f4')]):_0x4c4302[_0x461b12('0x1586')]()});});function _0x4ecce5(){const _0x2df0a0=_0x482767;_0x3e07d3[_0x2df0a0('0x61a')]=[];const _0x405cc1=[];_0x3e07d3[_0x2df0a0('0x1eff')]['type']&&_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x1345')][_0x2df0a0('0x2574')]()==='outbound'&&_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x83f')]===_0x2df0a0('0x867')&&(_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x2026')]=_0x3f9613[_0x2df0a0('0x2848')]?(_0x3e07d3[_0x2df0a0('0x1eff')]['prefix']||'')+_0x2df0a0('0x881')+_0x3f9613[_0x2df0a0('0x2848')]+'}':(_0x3e07d3[_0x2df0a0('0x1eff')]['prefix']||'')+'${EXTEN}',_0x3f9613[_0x2df0a0('0x28cb')]!==_0x2df0a0('0x192')?_0x3e07d3[_0x2df0a0('0x1eff')]['options'][_0x2df0a0('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x3e07d3[_0x2df0a0('0x1eff')]['options']+=_0x2df0a0('0x1059')):_0x3e07d3[_0x2df0a0('0x1eff')]['options']=_0x3e07d3['agent'][_0x2df0a0('0xd39')]['replace'](_0x2df0a0('0x1059'),''));const _0x3e97c6=_0x2cfb05()[_0x2df0a0('0xc38')](_0x3e07d3[_0x2df0a0('0x1f7e')],{'name':_0x3e07d3[_0x2df0a0('0x1eff')]['agent']});_0x3e97c6&&(_0x3e07d3['agent'][_0x2df0a0('0x122a')]=_0x3e97c6['id']);if(_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x83f')]&&_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x83f')]===_0x2df0a0('0x2853')){}else switch((_0x3e07d3[_0x2df0a0('0x1eff')]['app']||_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x83f')])[_0x2df0a0('0x2574')]()){case _0x2df0a0('0xceb'):_0x3e07d3[_0x2df0a0('0x1eff')]['appdata']=_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x4f0')]+'='+_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x18e0')];break;case _0x2df0a0('0x2853'):break;default:_0x405cc1[0x0]=_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x1eff')],_0x405cc1[0x1]=_0x3e07d3[_0x2df0a0('0x1eff')][_0x2df0a0('0x651')],_0x3e07d3['agent'][_0x2df0a0('0x823')]=_0x405cc1[_0x2df0a0('0x45a')](',');}_0x584ce1(_0x3e07d3[_0x2df0a0('0x1eff')]);}function _0x584ce1(_0x3fe7b9){const _0x517f44=_0x482767;_0xbbcd76[_0x517f44('0x1197')](_0x3fe7b9);}}const _0xd50390=_0x34b6a2;_0x21492b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1332'),_0x36e6f4('0x1864'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x21492b(_0x375645,_0x85b64,_0x7a02c,_0x11f303,_0x217d12,_0x2c08b0,_0x1bf6db,_0x4d4ba2){const _0xcd2c0d=_0x36e6f4,_0x48d325=this;_0x48d325[_0xcd2c0d('0x98')]=_0x1bf6db[_0xcd2c0d('0x26cd')](),_0x48d325[_0xcd2c0d('0x61a')]=[],_0x48d325['title']='CHAT.EDIT_'+(_0x11f303[_0xcd2c0d('0x83f')]||_0x11f303[_0xcd2c0d('0x746')])[_0xcd2c0d('0x1387')](),_0x48d325[_0xcd2c0d('0x86c')]=angular['copy'](_0x11f303),_0x48d325[_0xcd2c0d('0x243c')]=_0x4d4ba2,_0x48d325[_0xcd2c0d('0x128b')]={};if(_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x823')])switch(_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x83f')]?_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x83f')][_0xcd2c0d('0x2574')]():_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x746')][_0xcd2c0d('0x2574')]()){case _0xcd2c0d('0x2853'):break;case _0xcd2c0d('0xded'):{const _0x1b02a4=_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x823')][_0xcd2c0d('0x25c8')](',');_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x7ca')]=_0x1b02a4[0x0],_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0xedb')]=_0x1b02a4[0x1],_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x1634')]=_0x1b02a4[_0xcd2c0d('0x233')](0x2,_0x1b02a4['length'])[_0xcd2c0d('0x45a')](',');}break;case'dialogflowv2':{const _0x1a42fb=_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x823')][_0xcd2c0d('0x25c8')](',');_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x1b0a')]=_0x1a42fb[0x0],_0x48d325['amazonlex'][_0xcd2c0d('0x27f3')]=_0x1a42fb[0x1],_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x170e')]=_0x1a42fb[0x2],_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0xedb')]=_0x1a42fb[0x3],_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x1634')]=_0x1a42fb[_0xcd2c0d('0x233')](0x4,_0x1a42fb[_0xcd2c0d('0x264b')])[_0xcd2c0d('0x45a')](',');}break;case _0xcd2c0d('0x86c'):{const _0x58a0bc=_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x823')][_0xcd2c0d('0x25c8')](',');_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0xee6')]=_0x58a0bc[0x0],_0x48d325['amazonlex']['secretaccesskey']=_0x58a0bc[0x1],_0x48d325['amazonlex']['lexregion']=_0x58a0bc[0x2],_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x1ac4')]=_0x58a0bc[0x3],_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x1634')]=_0x58a0bc[_0xcd2c0d('0x233')](0x4,_0x58a0bc[_0xcd2c0d('0x264b')])[_0xcd2c0d('0x45a')](',');}break;case _0xcd2c0d('0x1af7'):{const _0x9c9580=_0x48d325['amazonlex'][_0xcd2c0d('0x823')][_0xcd2c0d('0x25c8')](',');_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x265e')]=isNaN(_0x9c9580[0x0])?_0x9c9580[0x0]:parseInt(_0x9c9580[0x0],0xa),_0x48d325[_0xcd2c0d('0x86c')]['text']=_0x9c9580[_0xcd2c0d('0x233')](0x1,_0x9c9580[_0xcd2c0d('0x264b')])['join'](',');}break;case _0xcd2c0d('0x1e70'):_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x1640')]=_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x823')];break;case _0xcd2c0d('0xceb'):_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x4f0')]=_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x823')][_0xcd2c0d('0x25c8')]('=')[0x0],_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x18e0')]=_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x823')]['split']('=')[0x1];break;case _0xcd2c0d('0x1034'):_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x2588')]=_0x48d325['amazonlex'][_0xcd2c0d('0x823')];break;default:{const _0x2965fc=_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x823')][_0xcd2c0d('0x25c8')](',');_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0xee6')]=_0x2cfb05()[_0xcd2c0d('0x1081')](_0x2965fc[0x0])?_0x2965fc[0x0]:isNaN(_0x2965fc[0x0])?_0x2965fc[0x0]:parseInt(_0x2965fc[0x0],0xa),_0x48d325['amazonlex'][_0xcd2c0d('0x125')]=_0x2cfb05()[_0xcd2c0d('0x1081')](_0x2965fc[0x1])?_0x2965fc[0x1]:isNaN(_0x2965fc[0x1])?_0x2965fc[0x1]:parseInt(_0x2965fc[0x1],0xa),_0x48d325['amazonlex']['lexregion']=_0x2cfb05()['isEmpty'](_0x2965fc[0x2])?_0x2965fc[0x2]:isNaN(_0x2965fc[0x2])?_0x2965fc[0x2]:parseInt(_0x2965fc[0x2],0xa),_0x48d325['amazonlex'][_0xcd2c0d('0x1ac4')]=_0x2cfb05()['isEmpty'](_0x2965fc[0x3])?_0x2965fc[0x3]:isNaN(_0x2965fc[0x3])?_0x2965fc[0x3]:parseInt(_0x2965fc[0x3],0xa),_0x48d325['amazonlex']['welcomemessage']=_0x2cfb05()[_0xcd2c0d('0x1081')](_0x2965fc[0x4])?_0x2965fc[0x4]:isNaN(_0x2965fc[0x4])?_0x2965fc[0x4]:parseInt(_0x2965fc[0x4],0xa);}break;}else _0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x25a2')]=_0xcd2c0d('0x1039');_0x48d325['amazonlex'][_0xcd2c0d('0x1345')]&&_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x1345')][_0xcd2c0d('0x2574')]()==='outbound'&&_0x48d325[_0xcd2c0d('0x86c')]['appType'][_0xcd2c0d('0x2574')]()===_0xcd2c0d('0x2884')&&(_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x265a')]=_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x2026')]?_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x2026')][_0xcd2c0d('0x25c8')]('$')[0x0]:undefined,_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x1f02')]=_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x992')]?_0xcd2c0d('0xa4c')+_0x48d325[_0xcd2c0d('0x86c')][_0xcd2c0d('0x992')]:undefined);_0x48d325[_0xcd2c0d('0x22f7')]=_0x346fbf,_0x48d325[_0xcd2c0d('0x24a0')]=_0x58de3f;function _0x346fbf(){const _0x4ae827=_0xcd2c0d;_0x48d325[_0x4ae827('0x61a')]=[];const _0x575232=[];_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x1345')]&&_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x1345')][_0x4ae827('0x2574')]()===_0x4ae827('0x587')&&_0x48d325['amazonlex'][_0x4ae827('0x83f')]===_0x4ae827('0x867')&&(_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x2026')]=_0x217d12[_0x4ae827('0x2848')]?(_0x48d325['amazonlex'][_0x4ae827('0x265a')]||'')+_0x4ae827('0x881')+_0x217d12[_0x4ae827('0x2848')]+'}':(_0x48d325['amazonlex'][_0x4ae827('0x265a')]||'')+'${EXTEN}',_0x217d12[_0x4ae827('0x28cb')]!==_0x4ae827('0x192')?_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0xd39')]['indexOf'](_0x4ae827('0x1059'))<0x0&&(_0x48d325['amazonlex'][_0x4ae827('0xd39')]+='U(xcally-mixmonitor-context)'):_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0xd39')]=_0x48d325[_0x4ae827('0x86c')]['options'][_0x4ae827('0xf3')](_0x4ae827('0x1059'),''));if(_0x48d325['amazonlex'][_0x4ae827('0x83f')]&&_0x48d325[_0x4ae827('0x86c')]['appType']==='custom'){}else switch((_0x48d325['amazonlex']['app']||_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x83f')])['toLowerCase']()){case'set':_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x823')]=_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x4f0')]+'='+_0x48d325[_0x4ae827('0x86c')]['value'];break;case _0x4ae827('0x2853'):break;default:_0x575232[0x0]=_0x48d325['amazonlex'][_0x4ae827('0xee6')],_0x575232[0x1]=_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x125')],_0x575232[0x2]=_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x25a2')],_0x575232[0x3]=_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x1ac4')],_0x575232[0x4]=_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x1634')],_0x48d325[_0x4ae827('0x86c')][_0x4ae827('0x823')]=_0x575232['join'](',');}_0x58de3f(_0x48d325[_0x4ae827('0x86c')]);}function _0x58de3f(_0x2b8a46){const _0x195891=_0xcd2c0d;_0x375645[_0x195891('0x1197')](_0x2b8a46);}}const _0x167dae=_0x21492b;_0x4c9e63[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty','chatWebsiteApp',_0x36e6f4('0x1864'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x4c9e63(_0x2f9c5f,_0x4fddab,_0x242da8,_0x1574ea,_0x333c3e,_0x8c9440,_0x2fd571,_0x3e21ac){const _0x3dc50c=_0x36e6f4,_0x51839f=this;_0x51839f['currentUser']=_0x2fd571[_0x3dc50c('0x26cd')](),_0x51839f[_0x3dc50c('0x61a')]=[],_0x51839f[_0x3dc50c('0xcdc')]=_0x3dc50c('0x1c9b')+(_0x1574ea[_0x3dc50c('0x83f')]||_0x1574ea['app'])[_0x3dc50c('0x1387')](),_0x51839f[_0x3dc50c('0x1af7')]=angular[_0x3dc50c('0x225f')](_0x1574ea),_0x51839f['crudPermissions']=_0x3e21ac,_0x51839f['hasModulePermissions']={};if(_0x51839f['autoreply'][_0x3dc50c('0x823')])switch(_0x51839f[_0x3dc50c('0x1af7')]['appType']?_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x83f')][_0x3dc50c('0x2574')]():_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x746')][_0x3dc50c('0x2574')]()){case _0x3dc50c('0x2853'):break;case _0x3dc50c('0xded'):{const _0x3bc085=_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x823')]['split'](',');_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x7ca')]=_0x3bc085[0x0],_0x51839f['autoreply'][_0x3dc50c('0xedb')]=_0x3bc085[0x1],_0x51839f[_0x3dc50c('0x1af7')]['welcomemessage']=_0x3bc085['slice'](0x2,_0x3bc085['length'])['join'](',');}break;case _0x3dc50c('0x1636'):{const _0x29667d=_0x51839f['autoreply'][_0x3dc50c('0x823')][_0x3dc50c('0x25c8')](',');_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x1b0a')]=_0x29667d[0x0],_0x51839f['autoreply'][_0x3dc50c('0x27f3')]=_0x29667d[0x1],_0x51839f['autoreply'][_0x3dc50c('0x170e')]=_0x29667d[0x2],_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0xedb')]=_0x29667d[0x3],_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x1634')]=_0x29667d['slice'](0x4,_0x29667d[_0x3dc50c('0x264b')])[_0x3dc50c('0x45a')](',');}break;case _0x3dc50c('0x86c'):{const _0xb126a4=_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x823')][_0x3dc50c('0x25c8')](',');_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0xee6')]=_0xb126a4[0x0],_0x51839f['autoreply'][_0x3dc50c('0x125')]=_0xb126a4[0x1],_0x51839f['autoreply'][_0x3dc50c('0x25a2')]=_0xb126a4[0x2],_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x1ac4')]=_0xb126a4[0x3],_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x1634')]=_0xb126a4[_0x3dc50c('0x233')](0x4,_0xb126a4['length'])[_0x3dc50c('0x45a')](',');}break;case _0x3dc50c('0x1af7'):{const _0xeef2a1=_0x51839f[_0x3dc50c('0x1af7')]['appdata'][_0x3dc50c('0x25c8')](',');_0x51839f[_0x3dc50c('0x1af7')]['times']=isNaN(_0xeef2a1[0x0])?_0xeef2a1[0x0]:parseInt(_0xeef2a1[0x0],0xa),_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x1640')]=_0xeef2a1[_0x3dc50c('0x233')](0x1,_0xeef2a1[_0x3dc50c('0x264b')])[_0x3dc50c('0x45a')](',');}break;case'message':_0x51839f[_0x3dc50c('0x1af7')]['text']=_0x51839f['autoreply']['appdata'];break;case _0x3dc50c('0xceb'):_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x4f0')]=_0x51839f[_0x3dc50c('0x1af7')]['appdata']['split']('=')[0x0],_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x18e0')]=_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x823')][_0x3dc50c('0x25c8')]('=')[0x1];break;case'agi':_0x51839f['autoreply'][_0x3dc50c('0x2588')]=_0x51839f['autoreply']['appdata'];break;default:{const _0x290a48=_0x51839f['autoreply'][_0x3dc50c('0x823')]['split'](',');_0x51839f[_0x3dc50c('0x1af7')]['times']=_0x2cfb05()[_0x3dc50c('0x1081')](_0x290a48[0x0])?_0x290a48[0x0]:isNaN(_0x290a48[0x0])?_0x290a48[0x0]:parseInt(_0x290a48[0x0],0xa),_0x51839f['autoreply'][_0x3dc50c('0x1640')]=_0x2cfb05()['isEmpty'](_0x290a48[0x1])?_0x290a48[0x1]:isNaN(_0x290a48[0x1])?_0x290a48[0x1]:parseInt(_0x290a48[0x1],0xa);}break;}else _0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x265e')]=0x1;_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x1345')]&&_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x1345')][_0x3dc50c('0x2574')]()===_0x3dc50c('0x587')&&_0x51839f[_0x3dc50c('0x1af7')]['appType'][_0x3dc50c('0x2574')]()===_0x3dc50c('0x2884')&&(_0x51839f[_0x3dc50c('0x1af7')]['prefix']=_0x51839f[_0x3dc50c('0x1af7')]['phone']?_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x2026')][_0x3dc50c('0x25c8')]('$')[0x0]:undefined,_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x1f02')]=_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x992')]?'CALLERID(all)='+_0x51839f[_0x3dc50c('0x1af7')][_0x3dc50c('0x992')]:undefined);_0x51839f[_0x3dc50c('0x22f7')]=_0x284c45,_0x51839f['closeDialog']=_0x59e7a4;function _0x284c45(){const _0x3fa11a=_0x3dc50c;_0x51839f[_0x3fa11a('0x61a')]=[];const _0x2800f3=[];_0x51839f[_0x3fa11a('0x1af7')]['type']&&_0x51839f[_0x3fa11a('0x1af7')]['type'][_0x3fa11a('0x2574')]()===_0x3fa11a('0x587')&&_0x51839f[_0x3fa11a('0x1af7')][_0x3fa11a('0x83f')]===_0x3fa11a('0x867')&&(_0x51839f[_0x3fa11a('0x1af7')][_0x3fa11a('0x2026')]=_0x333c3e[_0x3fa11a('0x2848')]?(_0x51839f['autoreply'][_0x3fa11a('0x265a')]||'')+'${EXTEN:'+_0x333c3e['cutdigits']+'}':(_0x51839f['autoreply'][_0x3fa11a('0x265a')]||'')+_0x3fa11a('0x1d1'),_0x333c3e[_0x3fa11a('0x28cb')]!==_0x3fa11a('0x192')?_0x51839f['autoreply'][_0x3fa11a('0xd39')][_0x3fa11a('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x51839f['autoreply'][_0x3fa11a('0xd39')]+=_0x3fa11a('0x1059')):_0x51839f['autoreply'][_0x3fa11a('0xd39')]=_0x51839f['autoreply'][_0x3fa11a('0xd39')]['replace'](_0x3fa11a('0x1059'),''));if(_0x51839f[_0x3fa11a('0x1af7')]['appType']&&_0x51839f[_0x3fa11a('0x1af7')][_0x3fa11a('0x83f')]===_0x3fa11a('0x2853')){}else switch((_0x51839f[_0x3fa11a('0x1af7')][_0x3fa11a('0x746')]||_0x51839f[_0x3fa11a('0x1af7')][_0x3fa11a('0x83f')])['toLowerCase']()){case _0x3fa11a('0xceb'):_0x51839f[_0x3fa11a('0x1af7')][_0x3fa11a('0x823')]=_0x51839f[_0x3fa11a('0x1af7')][_0x3fa11a('0x4f0')]+'='+_0x51839f[_0x3fa11a('0x1af7')][_0x3fa11a('0x18e0')];break;case'custom':break;default:_0x2800f3[0x0]=_0x51839f[_0x3fa11a('0x1af7')][_0x3fa11a('0x265e')],_0x2800f3[0x1]=_0x51839f['autoreply']['text'],_0x51839f['autoreply'][_0x3fa11a('0x823')]=_0x2800f3[_0x3fa11a('0x45a')](',');}_0x59e7a4(_0x51839f[_0x3fa11a('0x1af7')]);}function _0x59e7a4(_0x99c9c0){const _0x1bb733=_0x3dc50c;_0x2f9c5f[_0x1bb733('0x1197')](_0x99c9c0);}}const _0x54863d=_0x4c9e63;_0x1ad1e['$inject']=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1332'),'chatWebsite',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x1ad1e(_0x4ba635,_0x11e805,_0xab6b14,_0x5e4398,_0x3379cf,_0x44fcf4,_0x419cc9,_0x549a8c){const _0xea09f2=_0x36e6f4,_0x22e30d=this;_0x22e30d[_0xea09f2('0x98')]=_0x419cc9[_0xea09f2('0x26cd')](),_0x22e30d[_0xea09f2('0x61a')]=[],_0x22e30d['title']=_0xea09f2('0x1c9b')+(_0x5e4398['appType']||_0x5e4398['app'])['toUpperCase'](),_0x22e30d[_0xea09f2('0x1a7b')]=angular[_0xea09f2('0x225f')](_0x5e4398),_0x22e30d['crudPermissions']=_0x549a8c,_0x22e30d[_0xea09f2('0x128b')]={};if(_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x823')])switch(_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x83f')]?_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x83f')]['toLowerCase']():_0x22e30d['close'][_0xea09f2('0x746')][_0xea09f2('0x2574')]()){case _0xea09f2('0x2853'):break;case'dialogflow':{const _0x6ed950=_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x823')]['split'](',');_0x22e30d['close'][_0xea09f2('0x7ca')]=_0x6ed950[0x0],_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0xedb')]=_0x6ed950[0x1],_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x1634')]=_0x6ed950[_0xea09f2('0x233')](0x2,_0x6ed950['length'])['join'](',');}break;case _0xea09f2('0x1636'):{const _0x546280=_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x823')][_0xea09f2('0x25c8')](',');_0x22e30d['close']['projectId']=_0x546280[0x0],_0x22e30d['close']['clientEmail']=_0x546280[0x1],_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x170e')]=_0x546280[0x2],_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0xedb')]=_0x546280[0x3],_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x1634')]=_0x546280[_0xea09f2('0x233')](0x4,_0x546280[_0xea09f2('0x264b')])[_0xea09f2('0x45a')](',');}break;case _0xea09f2('0x86c'):{const _0x1d2f66=_0x22e30d[_0xea09f2('0x1a7b')]['appdata'][_0xea09f2('0x25c8')](',');_0x22e30d['close'][_0xea09f2('0xee6')]=_0x1d2f66[0x0],_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x125')]=_0x1d2f66[0x1],_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x25a2')]=_0x1d2f66[0x2],_0x22e30d['close'][_0xea09f2('0x1ac4')]=_0x1d2f66[0x3],_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x1634')]=_0x1d2f66[_0xea09f2('0x233')](0x4,_0x1d2f66[_0xea09f2('0x264b')])[_0xea09f2('0x45a')](',');}break;case _0xea09f2('0x1af7'):{const _0x45df81=_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x823')][_0xea09f2('0x25c8')](',');_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x265e')]=isNaN(_0x45df81[0x0])?_0x45df81[0x0]:parseInt(_0x45df81[0x0],0xa),_0x22e30d['close'][_0xea09f2('0x1640')]=_0x45df81[_0xea09f2('0x233')](0x1,_0x45df81[_0xea09f2('0x264b')])[_0xea09f2('0x45a')](',');}break;case _0xea09f2('0x1e70'):_0x22e30d[_0xea09f2('0x1a7b')]['text']=_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x823')];break;case _0xea09f2('0xceb'):_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x4f0')]=_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x823')][_0xea09f2('0x25c8')]('=')[0x0],_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x18e0')]=_0x22e30d[_0xea09f2('0x1a7b')]['appdata'][_0xea09f2('0x25c8')]('=')[0x1];break;case'agi':_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x2588')]=_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x823')];break;default:{const _0xee96aa=_0x22e30d['close'][_0xea09f2('0x823')][_0xea09f2('0x25c8')](',');_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x12e8')]=_0x2cfb05()[_0xea09f2('0x1081')](_0xee96aa[0x0])?_0xee96aa[0x0]:isNaN(_0xee96aa[0x0])?_0xee96aa[0x0]:parseInt(_0xee96aa[0x0],0xa);}break;}else{}_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x1345')]&&_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x1345')][_0xea09f2('0x2574')]()==='outbound'&&_0x22e30d['close'][_0xea09f2('0x83f')][_0xea09f2('0x2574')]()==='outbounddial'&&(_0x22e30d['close'][_0xea09f2('0x265a')]=_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x2026')]?_0x22e30d[_0xea09f2('0x1a7b')][_0xea09f2('0x2026')][_0xea09f2('0x25c8')]('$')[0x0]:undefined,_0x22e30d[_0xea09f2('0x1a7b')]['callerId']=_0x22e30d['close'][_0xea09f2('0x992')]?_0xea09f2('0xa4c')+_0x22e30d['close'][_0xea09f2('0x992')]:undefined);_0x22e30d[_0xea09f2('0x22f7')]=_0x2aced4,_0x22e30d['closeDialog']=_0x27dda8;function _0x2aced4(){const _0x1d9b87=_0xea09f2;_0x22e30d[_0x1d9b87('0x61a')]=[];const _0x4ab17e=[];_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x1345')]&&_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x1345')][_0x1d9b87('0x2574')]()===_0x1d9b87('0x587')&&_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x83f')]===_0x1d9b87('0x867')&&(_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x2026')]=_0x3379cf[_0x1d9b87('0x2848')]?(_0x22e30d[_0x1d9b87('0x1a7b')]['prefix']||'')+_0x1d9b87('0x881')+_0x3379cf['cutdigits']+'}':(_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x265a')]||'')+_0x1d9b87('0x1d1'),_0x3379cf[_0x1d9b87('0x28cb')]!==_0x1d9b87('0x192')?_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0xd39')]['indexOf'](_0x1d9b87('0x1059'))<0x0&&(_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0xd39')]+=_0x1d9b87('0x1059')):_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0xd39')]=_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0xd39')]['replace'](_0x1d9b87('0x1059'),''));if(_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x83f')]&&_0x22e30d['close'][_0x1d9b87('0x83f')]===_0x1d9b87('0x2853')){}else switch((_0x22e30d['close'][_0x1d9b87('0x746')]||_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x83f')])['toLowerCase']()){case'set':_0x22e30d['close'][_0x1d9b87('0x823')]=_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x4f0')]+'='+_0x22e30d[_0x1d9b87('0x1a7b')]['value'];break;case'custom':break;default:_0x4ab17e[0x0]=_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x12e8')],_0x22e30d[_0x1d9b87('0x1a7b')][_0x1d9b87('0x823')]=_0x4ab17e[_0x1d9b87('0x45a')](',');}_0x27dda8(_0x22e30d['close']);}function _0x27dda8(_0x46a26d){_0x4ba635['hide'](_0x46a26d);}}const _0x123bb3=_0x1ad1e;_0x21e090[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1332'),_0x36e6f4('0x1864'),'api',_0x36e6f4('0x21ef'),'crudPermissions'];function _0x21e090(_0x12baca,_0x110ea3,_0x3eee70,_0x8b5d6a,_0x2e794d,_0x2a23a3,_0x5aac1f,_0x5d840d){const _0x167c73=_0x36e6f4,_0x1e478f=this;_0x1e478f[_0x167c73('0x98')]=_0x5aac1f[_0x167c73('0x26cd')](),_0x1e478f[_0x167c73('0x61a')]=[],_0x1e478f[_0x167c73('0xcdc')]=_0x167c73('0x1c9b')+(_0x8b5d6a[_0x167c73('0x83f')]||_0x8b5d6a['app'])['toUpperCase'](),_0x1e478f[_0x167c73('0xded')]=angular[_0x167c73('0x225f')](_0x8b5d6a),_0x1e478f['crudPermissions']=_0x5d840d,_0x1e478f[_0x167c73('0x128b')]={};if(_0x1e478f[_0x167c73('0xded')][_0x167c73('0x823')])switch(_0x1e478f[_0x167c73('0xded')][_0x167c73('0x83f')]?_0x1e478f[_0x167c73('0xded')][_0x167c73('0x83f')][_0x167c73('0x2574')]():_0x1e478f[_0x167c73('0xded')][_0x167c73('0x746')][_0x167c73('0x2574')]()){case _0x167c73('0x2853'):break;case _0x167c73('0xded'):{const _0x521bb9=_0x1e478f[_0x167c73('0xded')][_0x167c73('0x823')][_0x167c73('0x25c8')](',');_0x1e478f[_0x167c73('0xded')][_0x167c73('0x7ca')]=_0x521bb9[0x0],_0x1e478f[_0x167c73('0xded')][_0x167c73('0xedb')]=_0x521bb9[0x1],_0x1e478f[_0x167c73('0xded')][_0x167c73('0x1634')]=_0x521bb9[_0x167c73('0x233')](0x2,_0x521bb9[_0x167c73('0x264b')])[_0x167c73('0x45a')](',');}break;case _0x167c73('0x1636'):{const _0x48c1c4=_0x1e478f[_0x167c73('0xded')][_0x167c73('0x823')][_0x167c73('0x25c8')](',');_0x1e478f['dialogflow'][_0x167c73('0x1b0a')]=_0x48c1c4[0x0],_0x1e478f['dialogflow'][_0x167c73('0x27f3')]=_0x48c1c4[0x1],_0x1e478f['dialogflow'][_0x167c73('0x170e')]=_0x48c1c4[0x2],_0x1e478f[_0x167c73('0xded')][_0x167c73('0xedb')]=_0x48c1c4[0x3],_0x1e478f[_0x167c73('0xded')][_0x167c73('0x1634')]=_0x48c1c4[_0x167c73('0x233')](0x4,_0x48c1c4[_0x167c73('0x264b')])[_0x167c73('0x45a')](',');}break;case _0x167c73('0x86c'):{const _0x5ee18d=_0x1e478f['dialogflow'][_0x167c73('0x823')]['split'](',');_0x1e478f['dialogflow'][_0x167c73('0xee6')]=_0x5ee18d[0x0],_0x1e478f[_0x167c73('0xded')]['secretaccesskey']=_0x5ee18d[0x1],_0x1e478f[_0x167c73('0xded')][_0x167c73('0x25a2')]=_0x5ee18d[0x2],_0x1e478f[_0x167c73('0xded')][_0x167c73('0x1ac4')]=_0x5ee18d[0x3],_0x1e478f[_0x167c73('0xded')][_0x167c73('0x1634')]=_0x5ee18d[_0x167c73('0x233')](0x4,_0x5ee18d[_0x167c73('0x264b')])['join'](',');}break;case'autoreply':{const _0x179222=_0x1e478f[_0x167c73('0xded')][_0x167c73('0x823')][_0x167c73('0x25c8')](',');_0x1e478f['dialogflow'][_0x167c73('0x265e')]=isNaN(_0x179222[0x0])?_0x179222[0x0]:parseInt(_0x179222[0x0],0xa),_0x1e478f[_0x167c73('0xded')][_0x167c73('0x1640')]=_0x179222[_0x167c73('0x233')](0x1,_0x179222[_0x167c73('0x264b')])[_0x167c73('0x45a')](',');}break;case _0x167c73('0x1e70'):_0x1e478f[_0x167c73('0xded')][_0x167c73('0x1640')]=_0x1e478f[_0x167c73('0xded')][_0x167c73('0x823')];break;case _0x167c73('0xceb'):_0x1e478f['dialogflow'][_0x167c73('0x4f0')]=_0x1e478f[_0x167c73('0xded')][_0x167c73('0x823')][_0x167c73('0x25c8')]('=')[0x0],_0x1e478f['dialogflow'][_0x167c73('0x18e0')]=_0x1e478f[_0x167c73('0xded')]['appdata']['split']('=')[0x1];break;case _0x167c73('0x1034'):_0x1e478f[_0x167c73('0xded')][_0x167c73('0x2588')]=_0x1e478f[_0x167c73('0xded')]['appdata'];break;default:{const _0x177352=_0x1e478f[_0x167c73('0xded')][_0x167c73('0x823')]['split'](',');_0x1e478f[_0x167c73('0xded')][_0x167c73('0x7ca')]=_0x2cfb05()['isEmpty'](_0x177352[0x0])?_0x177352[0x0]:isNaN(_0x177352[0x0])?_0x177352[0x0]:parseInt(_0x177352[0x0],0xa),_0x1e478f[_0x167c73('0xded')][_0x167c73('0xedb')]=_0x2cfb05()[_0x167c73('0x1081')](_0x177352[0x1])?_0x177352[0x1]:isNaN(_0x177352[0x1])?_0x177352[0x1]:parseInt(_0x177352[0x1],0xa),_0x1e478f[_0x167c73('0xded')][_0x167c73('0x1634')]=_0x2cfb05()['isEmpty'](_0x177352[0x2])?_0x177352[0x2]:isNaN(_0x177352[0x2])?_0x177352[0x2]:parseInt(_0x177352[0x2],0xa);}break;}else _0x1e478f[_0x167c73('0xded')][_0x167c73('0xedb')]='en';_0x1e478f['dialogflow'][_0x167c73('0x1345')]&&_0x1e478f[_0x167c73('0xded')]['type']['toLowerCase']()===_0x167c73('0x587')&&_0x1e478f[_0x167c73('0xded')]['appType'][_0x167c73('0x2574')]()===_0x167c73('0x2884')&&(_0x1e478f[_0x167c73('0xded')][_0x167c73('0x265a')]=_0x1e478f['dialogflow'][_0x167c73('0x2026')]?_0x1e478f['dialogflow']['phone'][_0x167c73('0x25c8')]('$')[0x0]:undefined,_0x1e478f[_0x167c73('0xded')]['callerId']=_0x1e478f[_0x167c73('0xded')][_0x167c73('0x992')]?'CALLERID(all)='+_0x1e478f['dialogflow'][_0x167c73('0x992')]:undefined);_0x1e478f['saveChatWebsiteApp']=_0x171b30,_0x1e478f[_0x167c73('0x24a0')]=_0x3892a2;function _0x171b30(){const _0x24bcff=_0x167c73;_0x1e478f['errors']=[];const _0x3385a8=[];_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0x1345')]&&_0x1e478f[_0x24bcff('0xded')]['type']['toLowerCase']()===_0x24bcff('0x587')&&_0x1e478f['dialogflow'][_0x24bcff('0x83f')]===_0x24bcff('0x867')&&(_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0x2026')]=_0x2e794d['cutdigits']?(_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0x265a')]||'')+_0x24bcff('0x881')+_0x2e794d[_0x24bcff('0x2848')]+'}':(_0x1e478f['dialogflow'][_0x24bcff('0x265a')]||'')+_0x24bcff('0x1d1'),_0x2e794d[_0x24bcff('0x28cb')]!==_0x24bcff('0x192')?_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0xd39')][_0x24bcff('0x2379')](_0x24bcff('0x1059'))<0x0&&(_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0xd39')]+=_0x24bcff('0x1059')):_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0xd39')]=_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0xd39')]['replace']('U(xcally-mixmonitor-context)',''));if(_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0x83f')]&&_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0x83f')]===_0x24bcff('0x2853')){}else switch((_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0x746')]||_0x1e478f[_0x24bcff('0xded')]['appType'])[_0x24bcff('0x2574')]()){case _0x24bcff('0xceb'):_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0x823')]=_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0x4f0')]+'='+_0x1e478f[_0x24bcff('0xded')]['value'];break;case _0x24bcff('0x2853'):break;default:_0x3385a8[0x0]=_0x1e478f['dialogflow'][_0x24bcff('0x7ca')],_0x3385a8[0x1]=_0x1e478f[_0x24bcff('0xded')][_0x24bcff('0xedb')],_0x3385a8[0x2]=_0x1e478f['dialogflow']['welcomemessage'],_0x1e478f['dialogflow'][_0x24bcff('0x823')]=_0x3385a8[_0x24bcff('0x45a')](',');}_0x3892a2(_0x1e478f[_0x24bcff('0xded')]);}function _0x3892a2(_0xf1934e){_0x12baca['hide'](_0xf1934e);}}const _0x27f068=_0x21e090;_0x36a9a6['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1332'),'chatWebsite',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x36a9a6(_0x3b6041,_0x191c1b,_0xe80b4b,_0x10fa09,_0x4a661c,_0x1419a0,_0x2aeb99,_0x51276d){const _0x2ee896=_0x36e6f4,_0x1a829b=this;_0x1a829b['currentUser']=_0x2aeb99[_0x2ee896('0x26cd')](),_0x1a829b[_0x2ee896('0x61a')]=[],_0x1a829b[_0x2ee896('0xcdc')]='CHAT.EDIT_'+(_0x10fa09['appType']||_0x10fa09[_0x2ee896('0x746')])[_0x2ee896('0x1387')](),_0x1a829b[_0x2ee896('0x30f')]=angular[_0x2ee896('0x225f')](_0x10fa09),_0x1a829b[_0x2ee896('0x243c')]=_0x51276d,_0x1a829b[_0x2ee896('0x128b')]={};if(_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x823')])switch(_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x83f')]?_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x83f')][_0x2ee896('0x2574')]():_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x746')][_0x2ee896('0x2574')]()){case _0x2ee896('0x2853'):break;case _0x2ee896('0xded'):{const _0x58affd=_0x1a829b['gotoif'][_0x2ee896('0x823')][_0x2ee896('0x25c8')](',');_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x7ca')]=_0x58affd[0x0],_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0xedb')]=_0x58affd[0x1],_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x1634')]=_0x58affd[_0x2ee896('0x233')](0x2,_0x58affd['length'])[_0x2ee896('0x45a')](',');}break;case _0x2ee896('0x1636'):{const _0x296575=_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x823')][_0x2ee896('0x25c8')](',');_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x1b0a')]=_0x296575[0x0],_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x27f3')]=_0x296575[0x1],_0x1a829b[_0x2ee896('0x30f')]['privateKey']=_0x296575[0x2],_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0xedb')]=_0x296575[0x3],_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x1634')]=_0x296575[_0x2ee896('0x233')](0x4,_0x296575['length'])[_0x2ee896('0x45a')](',');}break;case _0x2ee896('0x86c'):{const _0x4dfce2=_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x823')][_0x2ee896('0x25c8')](',');_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0xee6')]=_0x4dfce2[0x0],_0x1a829b['gotoif'][_0x2ee896('0x125')]=_0x4dfce2[0x1],_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x25a2')]=_0x4dfce2[0x2],_0x1a829b[_0x2ee896('0x30f')]['botname']=_0x4dfce2[0x3],_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x1634')]=_0x4dfce2[_0x2ee896('0x233')](0x4,_0x4dfce2[_0x2ee896('0x264b')])[_0x2ee896('0x45a')](',');}break;case _0x2ee896('0x1af7'):{const _0x18b403=_0x1a829b['gotoif'][_0x2ee896('0x823')][_0x2ee896('0x25c8')](',');_0x1a829b[_0x2ee896('0x30f')]['times']=isNaN(_0x18b403[0x0])?_0x18b403[0x0]:parseInt(_0x18b403[0x0],0xa),_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x1640')]=_0x18b403['slice'](0x1,_0x18b403[_0x2ee896('0x264b')])[_0x2ee896('0x45a')](',');}break;case'message':_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x1640')]=_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x823')];break;case'set':_0x1a829b[_0x2ee896('0x30f')]['name']=_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x823')][_0x2ee896('0x25c8')]('=')[0x0],_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x18e0')]=_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x823')][_0x2ee896('0x25c8')]('=')[0x1];break;case'agi':_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x2588')]=_0x1a829b[_0x2ee896('0x30f')]['appdata'];break;default:{const _0x34af00=_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x823')][_0x2ee896('0x25c8')](',');_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x8ff')]=_0x2cfb05()[_0x2ee896('0x1081')](_0x34af00[0x0])?_0x34af00[0x0]:isNaN(_0x34af00[0x0])?_0x34af00[0x0]:parseInt(_0x34af00[0x0],0xa),_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x13a6')]=_0x2cfb05()['isEmpty'](_0x34af00[0x1])?_0x34af00[0x1]:isNaN(_0x34af00[0x1])?_0x34af00[0x1]:parseInt(_0x34af00[0x1],0xa),_0x1a829b['gotoif'][_0x2ee896('0x1d7a')]=_0x2cfb05()[_0x2ee896('0x1081')](_0x34af00[0x2])?_0x34af00[0x2]:isNaN(_0x34af00[0x2])?_0x34af00[0x2]:parseInt(_0x34af00[0x2],0xa);}break;}else{}_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x1345')]&&_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x1345')]['toLowerCase']()===_0x2ee896('0x587')&&_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x83f')][_0x2ee896('0x2574')]()==='outbounddial'&&(_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x265a')]=_0x1a829b['gotoif'][_0x2ee896('0x2026')]?_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x2026')]['split']('$')[0x0]:undefined,_0x1a829b['gotoif'][_0x2ee896('0x1f02')]=_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x992')]?_0x2ee896('0xa4c')+_0x1a829b[_0x2ee896('0x30f')][_0x2ee896('0x992')]:undefined);_0x1a829b[_0x2ee896('0x22f7')]=_0x4a442a,_0x1a829b[_0x2ee896('0x24a0')]=_0x184b60;function _0x4a442a(){const _0x3cf92a=_0x2ee896;_0x1a829b[_0x3cf92a('0x61a')]=[];const _0x2ea29a=[];_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x1345')]&&_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x1345')][_0x3cf92a('0x2574')]()===_0x3cf92a('0x587')&&_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x83f')]===_0x3cf92a('0x867')&&(_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x2026')]=_0x4a661c['cutdigits']?(_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x265a')]||'')+_0x3cf92a('0x881')+_0x4a661c[_0x3cf92a('0x2848')]+'}':(_0x1a829b['gotoif'][_0x3cf92a('0x265a')]||'')+'${EXTEN}',_0x4a661c['recordingFormat']!=='none'?_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0xd39')][_0x3cf92a('0x2379')](_0x3cf92a('0x1059'))<0x0&&(_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0xd39')]+='U(xcally-mixmonitor-context)'):_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0xd39')]=_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0xd39')][_0x3cf92a('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x83f')]&&_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x83f')]===_0x3cf92a('0x2853')){}else switch((_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x746')]||_0x1a829b[_0x3cf92a('0x30f')]['appType'])[_0x3cf92a('0x2574')]()){case _0x3cf92a('0xceb'):_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x823')]=_0x1a829b['gotoif'][_0x3cf92a('0x4f0')]+'='+_0x1a829b[_0x3cf92a('0x30f')]['value'];break;case _0x3cf92a('0x2853'):break;default:_0x2ea29a[0x0]=_0x1a829b['gotoif'][_0x3cf92a('0x8ff')],_0x2ea29a[0x1]=_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x13a6')],_0x2ea29a[0x2]=_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x1d7a')],_0x1a829b[_0x3cf92a('0x30f')][_0x3cf92a('0x823')]=_0x2ea29a[_0x3cf92a('0x45a')](',');}_0x184b60(_0x1a829b['gotoif']);}function _0x184b60(_0x51c44d){const _0xc8c346=_0x2ee896;_0x3b6041[_0xc8c346('0x1197')](_0x51c44d);}}const _0x1db176=_0x36a9a6;_0x47deea[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'chatWebsiteApp',_0x36e6f4('0x1864'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x47deea(_0x2ff88f,_0x74bf4b,_0x7d4d6a,_0x45f8d5,_0x497f43,_0x2913ec,_0x17fa53,_0xd851d0){const _0x58cfd9=_0x36e6f4,_0x550566=this;_0x550566['currentUser']=_0x17fa53['getCurrentUser'](),_0x550566['errors']=[],_0x550566[_0x58cfd9('0xcdc')]=_0x58cfd9('0x1c9b')+(_0x45f8d5[_0x58cfd9('0x83f')]||_0x45f8d5[_0x58cfd9('0x746')])['toUpperCase'](),_0x550566[_0x58cfd9('0x6e6')]=angular[_0x58cfd9('0x225f')](_0x45f8d5),_0x550566[_0x58cfd9('0x243c')]=_0xd851d0,_0x550566[_0x58cfd9('0x128b')]={};if(_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x823')])switch(_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x83f')]?_0x550566[_0x58cfd9('0x6e6')]['appType'][_0x58cfd9('0x2574')]():_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x746')][_0x58cfd9('0x2574')]()){case _0x58cfd9('0x2853'):break;case _0x58cfd9('0xded'):{const _0x5ca226=_0x550566[_0x58cfd9('0x6e6')]['appdata'][_0x58cfd9('0x25c8')](',');_0x550566['gotop'][_0x58cfd9('0x7ca')]=_0x5ca226[0x0],_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0xedb')]=_0x5ca226[0x1],_0x550566['gotop'][_0x58cfd9('0x1634')]=_0x5ca226[_0x58cfd9('0x233')](0x2,_0x5ca226['length'])[_0x58cfd9('0x45a')](',');}break;case _0x58cfd9('0x1636'):{const _0x4e3449=_0x550566[_0x58cfd9('0x6e6')]['appdata'][_0x58cfd9('0x25c8')](',');_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x1b0a')]=_0x4e3449[0x0],_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x27f3')]=_0x4e3449[0x1],_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x170e')]=_0x4e3449[0x2],_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0xedb')]=_0x4e3449[0x3],_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x1634')]=_0x4e3449[_0x58cfd9('0x233')](0x4,_0x4e3449['length'])[_0x58cfd9('0x45a')](',');}break;case _0x58cfd9('0x86c'):{const _0x3daf09=_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x823')][_0x58cfd9('0x25c8')](',');_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0xee6')]=_0x3daf09[0x0],_0x550566['gotop'][_0x58cfd9('0x125')]=_0x3daf09[0x1],_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x25a2')]=_0x3daf09[0x2],_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x1ac4')]=_0x3daf09[0x3],_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x1634')]=_0x3daf09['slice'](0x4,_0x3daf09[_0x58cfd9('0x264b')])[_0x58cfd9('0x45a')](',');}break;case'autoreply':{const _0x2c5848=_0x550566[_0x58cfd9('0x6e6')]['appdata'][_0x58cfd9('0x25c8')](',');_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x265e')]=isNaN(_0x2c5848[0x0])?_0x2c5848[0x0]:parseInt(_0x2c5848[0x0],0xa),_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x1640')]=_0x2c5848['slice'](0x1,_0x2c5848[_0x58cfd9('0x264b')])[_0x58cfd9('0x45a')](',');}break;case'message':_0x550566[_0x58cfd9('0x6e6')]['text']=_0x550566['gotop'][_0x58cfd9('0x823')];break;case'set':_0x550566[_0x58cfd9('0x6e6')]['name']=_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x823')]['split']('=')[0x0],_0x550566['gotop'][_0x58cfd9('0x18e0')]=_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x823')][_0x58cfd9('0x25c8')]('=')[0x1];break;case _0x58cfd9('0x1034'):_0x550566['gotop'][_0x58cfd9('0x2588')]=_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x823')];break;default:{const _0x5322f8=_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x823')]['split'](',');_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0xfde')]=_0x2cfb05()[_0x58cfd9('0x1081')](_0x5322f8[0x0])?_0x5322f8[0x0]:isNaN(_0x5322f8[0x0])?_0x5322f8[0x0]:parseInt(_0x5322f8[0x0],0xa);}break;}else{}_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x1345')]&&_0x550566['gotop'][_0x58cfd9('0x1345')][_0x58cfd9('0x2574')]()==='outbound'&&_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x83f')][_0x58cfd9('0x2574')]()===_0x58cfd9('0x2884')&&(_0x550566['gotop'][_0x58cfd9('0x265a')]=_0x550566[_0x58cfd9('0x6e6')]['phone']?_0x550566[_0x58cfd9('0x6e6')][_0x58cfd9('0x2026')][_0x58cfd9('0x25c8')]('$')[0x0]:undefined,_0x550566['gotop'][_0x58cfd9('0x1f02')]=_0x550566[_0x58cfd9('0x6e6')]['callerID']?_0x58cfd9('0xa4c')+_0x550566['gotop']['callerID']:undefined);_0x550566[_0x58cfd9('0x22f7')]=_0x21aca9,_0x550566[_0x58cfd9('0x24a0')]=_0x89a4b4;function _0x21aca9(){const _0x53ec44=_0x58cfd9;_0x550566[_0x53ec44('0x61a')]=[];const _0x42ef49=[];_0x550566['gotop'][_0x53ec44('0x1345')]&&_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x1345')][_0x53ec44('0x2574')]()===_0x53ec44('0x587')&&_0x550566[_0x53ec44('0x6e6')]['appType']===_0x53ec44('0x867')&&(_0x550566['gotop']['phone']=_0x497f43[_0x53ec44('0x2848')]?(_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x265a')]||'')+_0x53ec44('0x881')+_0x497f43[_0x53ec44('0x2848')]+'}':(_0x550566[_0x53ec44('0x6e6')]['prefix']||'')+_0x53ec44('0x1d1'),_0x497f43['recordingFormat']!==_0x53ec44('0x192')?_0x550566['gotop'][_0x53ec44('0xd39')][_0x53ec44('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x550566[_0x53ec44('0x6e6')]['options']+=_0x53ec44('0x1059')):_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0xd39')]=_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0xd39')][_0x53ec44('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x83f')]&&_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x83f')]===_0x53ec44('0x2853')){}else switch((_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x746')]||_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x83f')])['toLowerCase']()){case _0x53ec44('0xceb'):_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x823')]=_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x4f0')]+'='+_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x18e0')];break;case _0x53ec44('0x2853'):break;default:_0x42ef49[0x0]=_0x550566['gotop']['priority'],_0x550566[_0x53ec44('0x6e6')][_0x53ec44('0x823')]=_0x42ef49[_0x53ec44('0x45a')](',');}_0x89a4b4(_0x550566[_0x53ec44('0x6e6')]);}function _0x89a4b4(_0xaf28c4){_0x2ff88f['hide'](_0xaf28c4);}}const _0x322038=_0x47deea;_0x2238a9['$inject']=['$state',_0x36e6f4('0x265d'),_0x36e6f4('0x25d0'),'IndexFactory','interval','intervals',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x2238a9(_0x435f0a,_0x76d9c8,_0x1c6e19,_0x722fcc,_0x4159f5,_0xd38bf2,_0x33c721,_0x5dec95,_0x4d6251,_0x4efba7){const _0x7bad76=_0x36e6f4,_0x52501c=this;_0x52501c[_0x7bad76('0x98')]=_0x4d6251[_0x7bad76('0x26cd')](),_0x52501c[_0x7bad76('0x61a')]=[],_0x52501c['title']=_0x7bad76('0x2879'),_0x52501c['interval']=angular[_0x7bad76('0x225f')](_0x4159f5),_0x52501c[_0x7bad76('0x164e')]=_0xd38bf2,_0x52501c['newInterval']=![],_0x52501c[_0x7bad76('0x6aa')]=[_0x7bad76('0x597'),_0x7bad76('0x2853'),_0x7bad76('0x1480')],_0x52501c['crudPermissions']=_0x4efba7,_0x52501c[_0x7bad76('0x5ef')]=_0x722fcc['getDaysOfWeek'](),_0x52501c[_0x7bad76('0x10b4')]=_0x722fcc[_0x7bad76('0x51d')](),_0x52501c[_0x7bad76('0x2259')]=_0x722fcc[_0x7bad76('0x1c39')](),_0x52501c[_0x7bad76('0x1fc0')]=_0x722fcc[_0x7bad76('0x2489')]();if(!_0x52501c[_0x7bad76('0x277c')])_0x52501c[_0x7bad76('0x277c')]={'interval':_0x7bad76('0x16f')},_0x52501c['type']=_0x7bad76('0x597'),_0x52501c[_0x7bad76('0xcdc')]=_0x7bad76('0x412'),_0x52501c[_0x7bad76('0x99d')]=!![];else{if(_0x52501c['interval'][_0x7bad76('0x277c')]!==_0x7bad76('0x16f')){_0x52501c['type']=_0x7bad76('0x2853');const _0x1798a1=_0x52501c['interval']['interval'][_0x7bad76('0x25c8')](','),_0x2ee923=_0x1798a1[0x0],_0x2f1987=_0x1798a1[0x1],_0x54ab8d=_0x1798a1[0x2],_0x4aea61=_0x1798a1[0x3];if(_0x2ee923!=='*'){const _0x23ec8b=_0x2ee923['split']('-')[0x0],_0x32f33e=_0x2ee923['split']('-')[0x1];let _0x323bac;_0x323bac=new Date(),_0x323bac[_0x7bad76('0xe24')](Number(_0x23ec8b[_0x7bad76('0x25c8')](':')[0x0])),_0x323bac['setMinutes'](Number(_0x23ec8b['split'](':')[0x1])),_0x52501c[_0x7bad76('0x64d')]=_0x323bac,_0x323bac=new Date(),_0x323bac[_0x7bad76('0xe24')](Number(_0x32f33e['split'](':')[0x0])),_0x323bac['setMinutes'](Number(_0x32f33e[_0x7bad76('0x25c8')](':')[0x1])),_0x52501c[_0x7bad76('0x2076')]=_0x323bac;}_0x2f1987!=='*'&&(_0x52501c[_0x7bad76('0x1eca')]=_0x2f1987['split']('-')[0x0],_0x52501c['dayOfWeekTo']=_0x2f1987['split']('-')[0x1]),_0x54ab8d!=='*'&&(_0x52501c[_0x7bad76('0x103d')]=_0x54ab8d[_0x7bad76('0x25c8')]('-')[0x0],_0x52501c[_0x7bad76('0x1dbb')]=_0x54ab8d[_0x7bad76('0x25c8')]('-')[0x1]),_0x4aea61!=='*'&&(_0x52501c[_0x7bad76('0xdec')]=_0x4aea61[_0x7bad76('0x25c8')]('-')[0x0],_0x52501c[_0x7bad76('0x1125')]=_0x4aea61[_0x7bad76('0x25c8')]('-')[0x1]);}else _0x52501c['type']='always';}_0x435f0a[_0x7bad76('0x23f')]['id']&&!_0x52501c[_0x7bad76('0x277c')][_0x7bad76('0x50d')]&&(_0x52501c[_0x7bad76('0x277c')]['IntervalId']=_0x435f0a[_0x7bad76('0x23f')]['id']);_0x52501c[_0x7bad76('0x277c')][_0x7bad76('0x186f')]&&_0x52501c[_0x7bad76('0x277c')][_0x7bad76('0x50d')]&&(_0x52501c[_0x7bad76('0x1345')]=_0x7bad76('0x1480'));_0x52501c[_0x7bad76('0x1ebf')]=_0x96bc6b,_0x52501c[_0x7bad76('0x24be')]=_0x5d9edb,_0x52501c['closeDialog']=_0x2519d3;_0x52501c[_0x7bad76('0x277c')][_0x7bad76('0x50d')]&&(_0x4d6251[_0x7bad76('0x1ac6')](_0x7bad76('0xa7c'))?_0x5dec95['interval'][_0x7bad76('0xd83')]({'fields':_0x7bad76('0xd0a'),'IntervalId':_0x7bad76('0x15d7'),'nolimit':!![]})[_0x7bad76('0xa44')][_0x7bad76('0x1166')](function(_0x3ea10a){const _0x117274=_0x7bad76;_0x52501c[_0x117274('0x164e')]=_0x3ea10a['rows']||[];})[_0x7bad76('0x1a80')](function(_0x44c30e){const _0x40df8d=_0x7bad76;_0x33c721[_0x40df8d('0xfc9')]({'title':_0x44c30e[_0x40df8d('0x52d')]?_0x40df8d('0x1e21')+_0x44c30e[_0x40df8d('0x52d')]+'\x20-\x20'+_0x44c30e[_0x40df8d('0xe1b')]:_0x40df8d('0xbb4'),'msg':_0x44c30e[_0x40df8d('0x25f4')]?JSON[_0x40df8d('0xbac')](_0x44c30e[_0x40df8d('0x25f4')]):_0x44c30e['toString']()});}):_0x5dec95[_0x7bad76('0x277c')]['get']({'fields':_0x7bad76('0xd0a'),'IntervalId':'null','nolimit':!![]})[_0x7bad76('0xa44')][_0x7bad76('0x1166')](function(_0xdf4ca5){const _0xd5478b=_0x7bad76;_0x52501c[_0xd5478b('0x164e')]=_0xdf4ca5[_0xd5478b('0x269a')]||[];})['then'](function(){const _0x14fa7e=_0x7bad76;return _0x5dec95[_0x14fa7e('0x17aa')]['get']({'userProfileId':_0x52501c[_0x14fa7e('0x98')][_0x14fa7e('0xb86')],'sectionId':0x3ec})['$promise'];})['then'](function(_0x84bb4e){const _0x1365d6=_0x7bad76,_0x25f2b6=_0x84bb4e&&_0x84bb4e['rows']?_0x84bb4e[_0x1365d6('0x269a')][0x0]:null;if(!_0x25f2b6)_0x52501c[_0x1365d6('0x164e')]=[];else{if(!_0x25f2b6[_0x1365d6('0x1a2b')])return _0x5dec95[_0x1365d6('0x4b5')][_0x1365d6('0xd83')]({'sectionId':_0x25f2b6['id']})[_0x1365d6('0xa44')][_0x1365d6('0x1166')](function(_0x3344ce){const _0x4cecaa=_0x1365d6,_0x1dffef=_0x3344ce&&_0x3344ce['rows']?_0x3344ce[_0x4cecaa('0x269a')]:[],_0x3fa45d=[];let _0x1617c0=null;_0x52501c[_0x4cecaa('0x277c')]&&(_0x1617c0=_0x2cfb05()['find'](_0x52501c[_0x4cecaa('0x164e')],{'name':_0x52501c[_0x4cecaa('0x277c')][_0x4cecaa('0x186f')]})),_0x1617c0&&!_0x2cfb05()[_0x4cecaa('0x1798')](_0x1dffef,[_0x4cecaa('0x24e8'),_0x1617c0['id']])&&_0x52501c[_0x4cecaa('0x164e')][_0x4cecaa('0x2782')](function(_0x3171ba){const _0x1c8d4a=_0x4cecaa;_0x3171ba['id']===_0x1617c0['id']&&(_0x3171ba[_0x1c8d4a('0x2378')]=![],_0x3fa45d[_0x1c8d4a('0x1514')](_0x3171ba));}),_0x52501c[_0x4cecaa('0x164e')]=_0x3fa45d;});}})[_0x7bad76('0x1a80')](function(_0x49ff2c){const _0x39b8a0=_0x7bad76;_0x33c721[_0x39b8a0('0xfc9')]({'title':_0x49ff2c['status']?_0x39b8a0('0x1e21')+_0x49ff2c[_0x39b8a0('0x52d')]+'\x20-\x20'+_0x49ff2c[_0x39b8a0('0xe1b')]:_0x39b8a0('0xbb4'),'msg':_0x49ff2c[_0x39b8a0('0x25f4')]?JSON['stringify'](_0x49ff2c[_0x39b8a0('0x25f4')]):_0x49ff2c[_0x39b8a0('0x1586')]()});}));function _0x522a13(){const _0x5ba7aa=_0x7bad76;switch(_0x52501c[_0x5ba7aa('0x1345')]){case _0x5ba7aa('0x597'):case _0x5ba7aa('0x1480'):return _0x5ba7aa('0x16f');case'custom':{const _0x30b5c2=[];if(_0x52501c[_0x5ba7aa('0x64d')]!=='*'&&_0x52501c[_0x5ba7aa('0x64d')]&&_0x52501c[_0x5ba7aa('0x2076')]){const _0x1fe510=(_0x52501c[_0x5ba7aa('0x64d')][_0x5ba7aa('0x11fe')]()<0xa?'0':'')+_0x52501c[_0x5ba7aa('0x64d')][_0x5ba7aa('0x11fe')]()+':'+((_0x52501c[_0x5ba7aa('0x64d')][_0x5ba7aa('0x234')]()<0xa?'0':'')+_0x52501c['timeRangeFrom']['getMinutes']()),_0x3d0d1a=(_0x52501c[_0x5ba7aa('0x2076')][_0x5ba7aa('0x11fe')]()<0xa?'0':'')+_0x52501c[_0x5ba7aa('0x2076')][_0x5ba7aa('0x11fe')]()+':'+((_0x52501c['timeRangeTo'][_0x5ba7aa('0x234')]()<0xa?'0':'')+_0x52501c[_0x5ba7aa('0x2076')]['getMinutes']());_0x30b5c2['push'](_0x1fe510+'-'+_0x3d0d1a);}else _0x30b5c2['push']('*');return _0x52501c[_0x5ba7aa('0x1eca')]?_0x52501c[_0x5ba7aa('0x1b81')]?_0x30b5c2[_0x5ba7aa('0x1514')](_0x52501c[_0x5ba7aa('0x1eca')]+'-'+_0x52501c[_0x5ba7aa('0x1b81')]):_0x30b5c2[_0x5ba7aa('0x1514')](_0x52501c['dayOfWeekFrom']):_0x30b5c2[_0x5ba7aa('0x1514')]('*'),_0x52501c['monthDayFrom']?_0x52501c['monthDayTo']?_0x30b5c2[_0x5ba7aa('0x1514')](_0x52501c['monthDayFrom']+'-'+_0x52501c['monthDayTo']):_0x30b5c2[_0x5ba7aa('0x1514')](_0x52501c[_0x5ba7aa('0x103d')]):_0x30b5c2['push']('*'),_0x52501c[_0x5ba7aa('0xdec')]?_0x52501c[_0x5ba7aa('0x1125')]?_0x30b5c2[_0x5ba7aa('0x1514')](_0x52501c['monthFrom']+'-'+_0x52501c['monthTo']):_0x30b5c2[_0x5ba7aa('0x1514')](_0x52501c[_0x5ba7aa('0xdec')]):_0x30b5c2[_0x5ba7aa('0x1514')]('*'),_0x30b5c2['join']();}}}function _0x96bc6b(){const _0x872959=_0x7bad76;_0x52501c[_0x872959('0x61a')]=[],_0x52501c[_0x872959('0x277c')]['interval']=_0x522a13(),_0x5dec95[_0x872959('0x277c')][_0x872959('0x9cc')](_0x52501c[_0x872959('0x277c')])[_0x872959('0xa44')][_0x872959('0x1166')](function(_0x5a6ac8){const _0x579871=_0x872959;_0x52501c[_0x579871('0x164e')][_0x579871('0x1514')](_0x5a6ac8),_0x33c721['success']({'title':_0x579871('0xf10'),'msg':_0x52501c[_0x579871('0x277c')][_0x579871('0x4f0')]?_0x52501c['interval'][_0x579871('0x4f0')]+_0x579871('0x1eda'):''}),_0x2519d3();})[_0x872959('0x1a80')](function(_0x328426){const _0x5c0b51=_0x872959;console['error'](_0x328426),_0x52501c['errors']=_0x328426[_0x5c0b51('0x25f4')][_0x5c0b51('0x61a')]||[{'message':_0x328426['toString'](),'type':_0x5c0b51('0x1192')}];});}function _0x5d9edb(){const _0x475ff9=_0x7bad76;_0x52501c[_0x475ff9('0x61a')]=[],_0x52501c['interval']['interval']=_0x522a13(),_0x52501c[_0x475ff9('0x277c')]['application']?(_0x52501c[_0x475ff9('0x1345')]!==_0x475ff9('0x1480')&&(_0x52501c['interval'][_0x475ff9('0x186f')]=null),_0x2519d3(_0x52501c['interval'])):_0x5dec95['interval'][_0x475ff9('0x1449')]({'id':_0x52501c[_0x475ff9('0x277c')]['id']},_0x52501c['interval'])[_0x475ff9('0xa44')][_0x475ff9('0x1166')](function(_0xa23bb6){const _0x9de925=_0x475ff9,_0x413eeb=_0x2cfb05()[_0x9de925('0xc38')](_0x52501c[_0x9de925('0x164e')],{'id':_0xa23bb6['id']});_0x413eeb&&_0x2cfb05()['merge'](_0x413eeb,_0xa23bb6),_0x33c721[_0x9de925('0x103b')]({'title':_0x9de925('0x1243'),'msg':_0x9de925('0x1666')}),_0x2519d3();})[_0x475ff9('0x1a80')](function(_0x18d9e4){const _0x2bae2f=_0x475ff9;console[_0x2bae2f('0xfc9')](_0x18d9e4),_0x52501c[_0x2bae2f('0x61a')]=_0x18d9e4['data'][_0x2bae2f('0x61a')]||[{'message':_0x18d9e4[_0x2bae2f('0x1586')](),'type':_0x2bae2f('0x2725')}];});}function _0x2519d3(_0x3edb5f){const _0xd86c1d=_0x7bad76;_0x76d9c8[_0xd86c1d('0x1197')](_0x3edb5f);}}const _0xb78adf=_0x2238a9;_0x97e8b7[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1332'),_0x36e6f4('0x1864'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x97e8b7(_0x48a93d,_0x517226,_0xd50e15,_0x3303eb,_0x45edf9,_0x27682e,_0x105d08,_0x24044c){const _0x22706c=_0x36e6f4,_0x422d23=this;_0x422d23[_0x22706c('0x98')]=_0x105d08[_0x22706c('0x26cd')](),_0x422d23['errors']=[],_0x422d23[_0x22706c('0xcdc')]='CHAT.EDIT_'+(_0x3303eb[_0x22706c('0x83f')]||_0x3303eb[_0x22706c('0x746')])['toUpperCase'](),_0x422d23['noop']=angular[_0x22706c('0x225f')](_0x3303eb),_0x422d23[_0x22706c('0x243c')]=_0x24044c,_0x422d23['hasModulePermissions']={};if(_0x422d23[_0x22706c('0x2652')][_0x22706c('0x823')])switch(_0x422d23[_0x22706c('0x2652')]['appType']?_0x422d23['noop'][_0x22706c('0x83f')][_0x22706c('0x2574')]():_0x422d23['noop']['app'][_0x22706c('0x2574')]()){case'custom':break;case _0x22706c('0xded'):{const _0x29954e=_0x422d23[_0x22706c('0x2652')][_0x22706c('0x823')]['split'](',');_0x422d23['noop']['key']=_0x29954e[0x0],_0x422d23[_0x22706c('0x2652')][_0x22706c('0xedb')]=_0x29954e[0x1],_0x422d23[_0x22706c('0x2652')][_0x22706c('0x1634')]=_0x29954e[_0x22706c('0x233')](0x2,_0x29954e[_0x22706c('0x264b')])[_0x22706c('0x45a')](',');}break;case _0x22706c('0x1636'):{const _0x49387a=_0x422d23[_0x22706c('0x2652')][_0x22706c('0x823')]['split'](',');_0x422d23['noop'][_0x22706c('0x1b0a')]=_0x49387a[0x0],_0x422d23[_0x22706c('0x2652')]['clientEmail']=_0x49387a[0x1],_0x422d23[_0x22706c('0x2652')]['privateKey']=_0x49387a[0x2],_0x422d23[_0x22706c('0x2652')][_0x22706c('0xedb')]=_0x49387a[0x3],_0x422d23[_0x22706c('0x2652')]['welcomemessage']=_0x49387a[_0x22706c('0x233')](0x4,_0x49387a['length'])[_0x22706c('0x45a')](',');}break;case _0x22706c('0x86c'):{const _0xea4790=_0x422d23[_0x22706c('0x2652')]['appdata'][_0x22706c('0x25c8')](',');_0x422d23[_0x22706c('0x2652')][_0x22706c('0xee6')]=_0xea4790[0x0],_0x422d23[_0x22706c('0x2652')]['secretaccesskey']=_0xea4790[0x1],_0x422d23['noop'][_0x22706c('0x25a2')]=_0xea4790[0x2],_0x422d23[_0x22706c('0x2652')][_0x22706c('0x1ac4')]=_0xea4790[0x3],_0x422d23[_0x22706c('0x2652')]['welcomemessage']=_0xea4790[_0x22706c('0x233')](0x4,_0xea4790[_0x22706c('0x264b')])[_0x22706c('0x45a')](',');}break;case _0x22706c('0x1af7'):{const _0x1c22f6=_0x422d23[_0x22706c('0x2652')][_0x22706c('0x823')][_0x22706c('0x25c8')](',');_0x422d23[_0x22706c('0x2652')]['times']=isNaN(_0x1c22f6[0x0])?_0x1c22f6[0x0]:parseInt(_0x1c22f6[0x0],0xa),_0x422d23[_0x22706c('0x2652')][_0x22706c('0x1640')]=_0x1c22f6[_0x22706c('0x233')](0x1,_0x1c22f6[_0x22706c('0x264b')])[_0x22706c('0x45a')](',');}break;case _0x22706c('0x1e70'):_0x422d23[_0x22706c('0x2652')][_0x22706c('0x1640')]=_0x422d23[_0x22706c('0x2652')]['appdata'];break;case _0x22706c('0xceb'):_0x422d23[_0x22706c('0x2652')][_0x22706c('0x4f0')]=_0x422d23[_0x22706c('0x2652')]['appdata']['split']('=')[0x0],_0x422d23[_0x22706c('0x2652')][_0x22706c('0x18e0')]=_0x422d23[_0x22706c('0x2652')][_0x22706c('0x823')][_0x22706c('0x25c8')]('=')[0x1];break;case _0x22706c('0x1034'):_0x422d23[_0x22706c('0x2652')]['project']=_0x422d23[_0x22706c('0x2652')]['appdata'];break;default:{const _0x3e8e0f=_0x422d23[_0x22706c('0x2652')][_0x22706c('0x823')][_0x22706c('0x25c8')](',');_0x422d23[_0x22706c('0x2652')]['value']=_0x2cfb05()[_0x22706c('0x1081')](_0x3e8e0f[0x0])?_0x3e8e0f[0x0]:isNaN(_0x3e8e0f[0x0])?_0x3e8e0f[0x0]:parseInt(_0x3e8e0f[0x0],0xa);}break;}else{}_0x422d23['noop'][_0x22706c('0x1345')]&&_0x422d23['noop'][_0x22706c('0x1345')][_0x22706c('0x2574')]()===_0x22706c('0x587')&&_0x422d23[_0x22706c('0x2652')][_0x22706c('0x83f')][_0x22706c('0x2574')]()===_0x22706c('0x2884')&&(_0x422d23[_0x22706c('0x2652')][_0x22706c('0x265a')]=_0x422d23[_0x22706c('0x2652')][_0x22706c('0x2026')]?_0x422d23[_0x22706c('0x2652')][_0x22706c('0x2026')][_0x22706c('0x25c8')]('$')[0x0]:undefined,_0x422d23[_0x22706c('0x2652')][_0x22706c('0x1f02')]=_0x422d23[_0x22706c('0x2652')][_0x22706c('0x992')]?_0x22706c('0xa4c')+_0x422d23[_0x22706c('0x2652')][_0x22706c('0x992')]:undefined);_0x422d23[_0x22706c('0x22f7')]=_0x306acd,_0x422d23[_0x22706c('0x24a0')]=_0x549e4e;function _0x306acd(){const _0x1337a0=_0x22706c;_0x422d23[_0x1337a0('0x61a')]=[];const _0x290578=[];_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0x1345')]&&_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0x1345')]['toLowerCase']()===_0x1337a0('0x587')&&_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0x83f')]===_0x1337a0('0x867')&&(_0x422d23['noop'][_0x1337a0('0x2026')]=_0x45edf9[_0x1337a0('0x2848')]?(_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0x265a')]||'')+_0x1337a0('0x881')+_0x45edf9['cutdigits']+'}':(_0x422d23[_0x1337a0('0x2652')]['prefix']||'')+_0x1337a0('0x1d1'),_0x45edf9[_0x1337a0('0x28cb')]!=='none'?_0x422d23['noop'][_0x1337a0('0xd39')][_0x1337a0('0x2379')](_0x1337a0('0x1059'))<0x0&&(_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0xd39')]+=_0x1337a0('0x1059')):_0x422d23['noop'][_0x1337a0('0xd39')]=_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0xd39')][_0x1337a0('0xf3')](_0x1337a0('0x1059'),''));if(_0x422d23[_0x1337a0('0x2652')]['appType']&&_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0x83f')]===_0x1337a0('0x2853')){}else switch((_0x422d23[_0x1337a0('0x2652')]['app']||_0x422d23['noop'][_0x1337a0('0x83f')])[_0x1337a0('0x2574')]()){case _0x1337a0('0xceb'):_0x422d23[_0x1337a0('0x2652')]['appdata']=_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0x4f0')]+'='+_0x422d23['noop'][_0x1337a0('0x18e0')];break;case _0x1337a0('0x2853'):break;default:_0x290578[0x0]=_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0x18e0')],_0x422d23[_0x1337a0('0x2652')][_0x1337a0('0x823')]=_0x290578[_0x1337a0('0x45a')](',');}_0x549e4e(_0x422d23['noop']);}function _0x549e4e(_0x5b641e){const _0x3b4aa0=_0x22706c;_0x48a93d[_0x3b4aa0('0x1197')](_0x5b641e);}}const _0x1b3b8e=_0x97e8b7;_0x381023['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1332'),'chatWebsite','api',_0x36e6f4('0x21ef'),'crudPermissions'];function _0x381023(_0x46d0b9,_0xa31ae,_0x17f5f3,_0x4d31c1,_0x3154a8,_0x2365e3,_0x6912f4,_0x55d515){const _0x5e0876=_0x36e6f4,_0x5e610c=this;_0x5e610c[_0x5e0876('0x98')]=_0x6912f4[_0x5e0876('0x26cd')](),_0x5e610c[_0x5e0876('0x61a')]=[],_0x5e610c[_0x5e0876('0xcdc')]='CHAT.EDIT_'+(_0x4d31c1[_0x5e0876('0x83f')]||_0x4d31c1['app'])[_0x5e0876('0x1387')](),_0x5e610c['queue']=angular[_0x5e0876('0x225f')](_0x4d31c1),_0x5e610c[_0x5e0876('0x243c')]=_0x55d515,_0x5e610c[_0x5e0876('0x128b')]={};if(_0x5e610c[_0x5e0876('0x1d3e')]['appdata'])switch(_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x83f')]?_0x5e610c['queue'][_0x5e0876('0x83f')]['toLowerCase']():_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x746')][_0x5e0876('0x2574')]()){case _0x5e0876('0x2853'):break;case _0x5e0876('0xded'):{const _0x52ce1d=_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x823')][_0x5e0876('0x25c8')](',');_0x5e610c['queue'][_0x5e0876('0x7ca')]=_0x52ce1d[0x0],_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0xedb')]=_0x52ce1d[0x1],_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x1634')]=_0x52ce1d[_0x5e0876('0x233')](0x2,_0x52ce1d[_0x5e0876('0x264b')])[_0x5e0876('0x45a')](',');}break;case _0x5e0876('0x1636'):{const _0x39a0fc=_0x5e610c['queue'][_0x5e0876('0x823')]['split'](',');_0x5e610c['queue'][_0x5e0876('0x1b0a')]=_0x39a0fc[0x0],_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x27f3')]=_0x39a0fc[0x1],_0x5e610c['queue'][_0x5e0876('0x170e')]=_0x39a0fc[0x2],_0x5e610c[_0x5e0876('0x1d3e')]['language']=_0x39a0fc[0x3],_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x1634')]=_0x39a0fc[_0x5e0876('0x233')](0x4,_0x39a0fc[_0x5e0876('0x264b')])['join'](',');}break;case _0x5e0876('0x86c'):{const _0x5060b2=_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x823')][_0x5e0876('0x25c8')](',');_0x5e610c[_0x5e0876('0x1d3e')]['accesskeyid']=_0x5060b2[0x0],_0x5e610c['queue']['secretaccesskey']=_0x5060b2[0x1],_0x5e610c['queue'][_0x5e0876('0x25a2')]=_0x5060b2[0x2],_0x5e610c[_0x5e0876('0x1d3e')]['botname']=_0x5060b2[0x3],_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x1634')]=_0x5060b2[_0x5e0876('0x233')](0x4,_0x5060b2[_0x5e0876('0x264b')])[_0x5e0876('0x45a')](',');}break;case'autoreply':{const _0x3ca954=_0x5e610c[_0x5e0876('0x1d3e')]['appdata'][_0x5e0876('0x25c8')](',');_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x265e')]=isNaN(_0x3ca954[0x0])?_0x3ca954[0x0]:parseInt(_0x3ca954[0x0],0xa),_0x5e610c['queue'][_0x5e0876('0x1640')]=_0x3ca954[_0x5e0876('0x233')](0x1,_0x3ca954[_0x5e0876('0x264b')])[_0x5e0876('0x45a')](',');}break;case'message':_0x5e610c['queue'][_0x5e0876('0x1640')]=_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x823')];break;case _0x5e0876('0xceb'):_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x4f0')]=_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x823')][_0x5e0876('0x25c8')]('=')[0x0],_0x5e610c['queue'][_0x5e0876('0x18e0')]=_0x5e610c['queue'][_0x5e0876('0x823')][_0x5e0876('0x25c8')]('=')[0x1];break;case _0x5e0876('0x1034'):_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x2588')]=_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x823')];break;default:{const _0x470b5a=_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x823')]['split'](',');_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x1d3e')]=_0x2cfb05()[_0x5e0876('0x1081')](_0x470b5a[0x0])?_0x470b5a[0x0]:isNaN(_0x470b5a[0x0])?_0x470b5a[0x0]:parseInt(_0x470b5a[0x0],0xa),_0x5e610c['queue'][_0x5e0876('0x651')]=_0x2cfb05()[_0x5e0876('0x1081')](_0x470b5a[0x1])?_0x470b5a[0x1]:isNaN(_0x470b5a[0x1])?_0x470b5a[0x1]:parseInt(_0x470b5a[0x1],0xa);}break;}else _0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x1d3e')]=0x12c,_0x5e610c['queue'][_0x5e0876('0x651')]=0x12c;_0x5e610c['queue'][_0x5e0876('0x1345')]&&_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x1345')][_0x5e0876('0x2574')]()===_0x5e0876('0x587')&&_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x83f')][_0x5e0876('0x2574')]()===_0x5e0876('0x2884')&&(_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x265a')]=_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x2026')]?_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x2026')][_0x5e0876('0x25c8')]('$')[0x0]:undefined,_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x1f02')]=_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x992')]?_0x5e0876('0xa4c')+_0x5e610c[_0x5e0876('0x1d3e')][_0x5e0876('0x992')]:undefined);_0x5e610c['saveChatWebsiteApp']=_0x300873,_0x5e610c[_0x5e0876('0x24a0')]=_0x23d673,_0x6912f4['hasRole'](_0x5e0876('0xa7c'))?_0x2365e3['chatQueue'][_0x5e0876('0xd83')]({'fields':'id,name,type','sort':_0x5e0876('0x4f0'),'nolimit':'true'})['$promise'][_0x5e0876('0x1166')](function(_0x2e1e6a){const _0x213385=_0x5e0876;_0x5e610c[_0x213385('0x7a7')]=_0x2e1e6a['rows']||[];})[_0x5e0876('0x1a80')](function(_0x5a9b2d){const _0x5ad603=_0x5e0876;_0x17f5f3[_0x5ad603('0xfc9')]({'title':_0x5a9b2d['status']?_0x5ad603('0x1e21')+_0x5a9b2d[_0x5ad603('0x52d')]+'\x20-\x20'+_0x5a9b2d[_0x5ad603('0xe1b')]:_0x5ad603('0x2029'),'msg':_0x5a9b2d[_0x5ad603('0x25f4')]?JSON[_0x5ad603('0xbac')](_0x5a9b2d[_0x5ad603('0x25f4')]):_0x5a9b2d[_0x5ad603('0x1586')]()});}):_0x2365e3[_0x5e0876('0x1e45')]['get']({'fields':_0x5e0876('0x1c09'),'sort':_0x5e0876('0x4f0'),'nolimit':_0x5e0876('0xf3b')})['$promise'][_0x5e0876('0x1166')](function(_0x292a12){const _0x4e275e=_0x5e0876;_0x5e610c[_0x4e275e('0x7a7')]=_0x292a12['rows']||[];})[_0x5e0876('0x1166')](function(){const _0x5f5cb8=_0x5e0876;return _0x2365e3[_0x5f5cb8('0x17aa')][_0x5f5cb8('0xd83')]({'userProfileId':_0x5e610c['currentUser'][_0x5f5cb8('0xb86')],'sectionId':0x1f5})['$promise'];})[_0x5e0876('0x1166')](function(_0x26019b){const _0x544455=_0x5e0876,_0x50218e=_0x26019b&&_0x26019b[_0x544455('0x269a')]?_0x26019b['rows'][0x0]:null;if(!_0x50218e){const _0x78bd68=[];let _0x71be6b=null;_0x5e610c[_0x544455('0x1d3e')]&&(_0x71be6b=_0x2cfb05()[_0x544455('0xc38')](_0x5e610c[_0x544455('0x7a7')],{'name':_0x5e610c['queue'][_0x544455('0x1d3e')]}));for(let _0x107be3=0x0;_0x107be3<_0x5e610c['queues'][_0x544455('0x264b')];_0x107be3++){_0x71be6b&&_0x5e610c['queues'][_0x107be3]['id']===_0x71be6b['id']&&(_0x5e610c['queues'][_0x107be3]['canSelect']=![],_0x78bd68['push'](_0x5e610c[_0x544455('0x7a7')][_0x107be3]));}_0x5e610c[_0x544455('0x7a7')]=_0x78bd68;}else{if(!_0x50218e['autoAssociation'])return _0x2365e3['userProfileResource']['get']({'sectionId':_0x50218e['id']})[_0x544455('0xa44')][_0x544455('0x1166')](function(_0x300dc5){const _0xdbd44c=_0x544455,_0xbc11db=_0x2cfb05()['map'](_0x300dc5[_0xdbd44c('0x269a')],function(_0x49f746){const _0x2c181b=_0xdbd44c;return _0x2cfb05()[_0x2c181b('0xc38')](_0x5e610c['queues'],{'id':_0x49f746[_0x2c181b('0x24e8')]});});let _0x404e68=null;_0x5e610c[_0xdbd44c('0x1d3e')]&&(_0x404e68=_0x2cfb05()[_0xdbd44c('0xc38')](_0x5e610c[_0xdbd44c('0x7a7')],{'name':_0x5e610c['queue'][_0xdbd44c('0x1d3e')]}));if(_0x404e68&&!_0x2cfb05()[_0xdbd44c('0x1798')](_0xbc11db,['id',_0x404e68['id']])){const _0x30661b=_0x2cfb05()[_0xdbd44c('0xc38')](_0x5e610c['queues'],{'id':_0x404e68['id']});_0x30661b['canSelect']=![],_0xbc11db[_0xdbd44c('0x1514')](_0x30661b);}_0x5e610c[_0xdbd44c('0x7a7')]=_0xbc11db;});}})[_0x5e0876('0x1a80')](function(_0x485b1a){const _0x2e3d1d=_0x5e0876;_0x17f5f3[_0x2e3d1d('0xfc9')]({'title':_0x485b1a[_0x2e3d1d('0x52d')]?_0x2e3d1d('0x1e21')+_0x485b1a[_0x2e3d1d('0x52d')]+'\x20-\x20'+_0x485b1a[_0x2e3d1d('0xe1b')]:_0x2e3d1d('0x1dd7'),'msg':_0x485b1a[_0x2e3d1d('0x25f4')]?JSON[_0x2e3d1d('0xbac')](_0x485b1a[_0x2e3d1d('0x25f4')]):_0x485b1a['toString']()});});function _0x300873(){const _0x11737f=_0x5e0876;_0x5e610c[_0x11737f('0x61a')]=[];const _0x4b9884=[];_0x5e610c[_0x11737f('0x1d3e')][_0x11737f('0x1345')]&&_0x5e610c['queue']['type'][_0x11737f('0x2574')]()===_0x11737f('0x587')&&_0x5e610c[_0x11737f('0x1d3e')]['appType']===_0x11737f('0x867')&&(_0x5e610c['queue'][_0x11737f('0x2026')]=_0x3154a8[_0x11737f('0x2848')]?(_0x5e610c[_0x11737f('0x1d3e')][_0x11737f('0x265a')]||'')+'${EXTEN:'+_0x3154a8[_0x11737f('0x2848')]+'}':(_0x5e610c[_0x11737f('0x1d3e')]['prefix']||'')+_0x11737f('0x1d1'),_0x3154a8[_0x11737f('0x28cb')]!==_0x11737f('0x192')?_0x5e610c['queue'][_0x11737f('0xd39')][_0x11737f('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x5e610c[_0x11737f('0x1d3e')][_0x11737f('0xd39')]+=_0x11737f('0x1059')):_0x5e610c[_0x11737f('0x1d3e')]['options']=_0x5e610c[_0x11737f('0x1d3e')][_0x11737f('0xd39')][_0x11737f('0xf3')](_0x11737f('0x1059'),''));const _0x1f33ae=_0x2cfb05()[_0x11737f('0xc38')](_0x5e610c[_0x11737f('0x7a7')],{'name':_0x5e610c[_0x11737f('0x1d3e')][_0x11737f('0x1d3e')]});_0x1f33ae&&(_0x5e610c[_0x11737f('0x1d3e')][_0x2cfb05()[_0x11737f('0x92c')](_0x11737f('0xde2'))+_0x11737f('0x1366')]=_0x1f33ae['id']);if(_0x5e610c[_0x11737f('0x1d3e')]['appType']&&_0x5e610c[_0x11737f('0x1d3e')][_0x11737f('0x83f')]===_0x11737f('0x2853')){}else switch((_0x5e610c[_0x11737f('0x1d3e')][_0x11737f('0x746')]||_0x5e610c['queue'][_0x11737f('0x83f')])[_0x11737f('0x2574')]()){case _0x11737f('0xceb'):_0x5e610c[_0x11737f('0x1d3e')]['appdata']=_0x5e610c[_0x11737f('0x1d3e')][_0x11737f('0x4f0')]+'='+_0x5e610c[_0x11737f('0x1d3e')]['value'];break;case'custom':break;default:_0x4b9884[0x0]=_0x5e610c[_0x11737f('0x1d3e')][_0x11737f('0x1d3e')],_0x4b9884[0x1]=_0x5e610c[_0x11737f('0x1d3e')]['timeout'],_0x5e610c['queue'][_0x11737f('0x823')]=_0x4b9884[_0x11737f('0x45a')](',');}_0x23d673(_0x5e610c['queue']);}function _0x23d673(_0x640731){const _0x202d58=_0x5e0876;_0x46d0b9[_0x202d58('0x1197')](_0x640731);}}const _0x5f5ce4=_0x381023;_0x420196['$inject']=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x1332'),_0x36e6f4('0x1864'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x420196(_0x58518a,_0x1903ed,_0x33f4e7,_0x22aac8,_0x52af8c,_0x2ec448,_0x3eae27,_0x27c4bc){const _0x5889a8=_0x36e6f4,_0x21b004=this;_0x21b004[_0x5889a8('0x98')]=_0x3eae27[_0x5889a8('0x26cd')](),_0x21b004['errors']=[],_0x21b004['title']=_0x5889a8('0x1c9b')+(_0x22aac8[_0x5889a8('0x83f')]||_0x22aac8[_0x5889a8('0x746')])['toUpperCase'](),_0x21b004[_0x5889a8('0x1c2b')]=angular[_0x5889a8('0x225f')](_0x22aac8),_0x21b004[_0x5889a8('0x243c')]=_0x27c4bc,_0x21b004[_0x5889a8('0x128b')]={};if(_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x823')])switch(_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x83f')]?_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x83f')][_0x5889a8('0x2574')]():_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x746')][_0x5889a8('0x2574')]()){case _0x5889a8('0x2853'):break;case _0x5889a8('0xded'):{const _0x2ddd54=_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x823')][_0x5889a8('0x25c8')](',');_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x7ca')]=_0x2ddd54[0x0],_0x21b004[_0x5889a8('0x1c2b')]['language']=_0x2ddd54[0x1],_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x1634')]=_0x2ddd54['slice'](0x2,_0x2ddd54['length'])['join'](',');}break;case _0x5889a8('0x1636'):{const _0x47794c=_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x823')][_0x5889a8('0x25c8')](',');_0x21b004[_0x5889a8('0x1c2b')]['projectId']=_0x47794c[0x0],_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x27f3')]=_0x47794c[0x1],_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x170e')]=_0x47794c[0x2],_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0xedb')]=_0x47794c[0x3],_0x21b004['system']['welcomemessage']=_0x47794c[_0x5889a8('0x233')](0x4,_0x47794c[_0x5889a8('0x264b')])[_0x5889a8('0x45a')](',');}break;case _0x5889a8('0x86c'):{const _0x53642f=_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x823')][_0x5889a8('0x25c8')](',');_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0xee6')]=_0x53642f[0x0],_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x125')]=_0x53642f[0x1],_0x21b004['system']['lexregion']=_0x53642f[0x2],_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x1ac4')]=_0x53642f[0x3],_0x21b004['system'][_0x5889a8('0x1634')]=_0x53642f[_0x5889a8('0x233')](0x4,_0x53642f[_0x5889a8('0x264b')])[_0x5889a8('0x45a')](',');}break;case'autoreply':{const _0x4589dd=_0x21b004['system'][_0x5889a8('0x823')][_0x5889a8('0x25c8')](',');_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x265e')]=isNaN(_0x4589dd[0x0])?_0x4589dd[0x0]:parseInt(_0x4589dd[0x0],0xa),_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x1640')]=_0x4589dd['slice'](0x1,_0x4589dd[_0x5889a8('0x264b')])[_0x5889a8('0x45a')](',');}break;case'message':_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x1640')]=_0x21b004['system'][_0x5889a8('0x823')];break;case _0x5889a8('0xceb'):_0x21b004[_0x5889a8('0x1c2b')]['name']=_0x21b004[_0x5889a8('0x1c2b')]['appdata'][_0x5889a8('0x25c8')]('=')[0x0],_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x18e0')]=_0x21b004[_0x5889a8('0x1c2b')]['appdata']['split']('=')[0x1];break;case'agi':_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x2588')]=_0x21b004[_0x5889a8('0x1c2b')]['appdata'];break;default:{const _0x14cdc6=_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x823')][_0x5889a8('0x25c8')](',');_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x187')]=_0x2cfb05()[_0x5889a8('0x1081')](_0x14cdc6[0x0])?_0x14cdc6[0x0]:isNaN(_0x14cdc6[0x0])?_0x14cdc6[0x0]:parseInt(_0x14cdc6[0x0],0xa),_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x734')]=_0x2cfb05()['isEmpty'](_0x14cdc6[0x1])?_0x14cdc6[0x1]:isNaN(_0x14cdc6[0x1])?_0x14cdc6[0x1]:parseInt(_0x14cdc6[0x1],0xa);}break;}else _0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x734')]='';_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x1345')]&&_0x21b004['system'][_0x5889a8('0x1345')]['toLowerCase']()==='outbound'&&_0x21b004[_0x5889a8('0x1c2b')]['appType']['toLowerCase']()===_0x5889a8('0x2884')&&(_0x21b004['system']['prefix']=_0x21b004[_0x5889a8('0x1c2b')]['phone']?_0x21b004['system'][_0x5889a8('0x2026')][_0x5889a8('0x25c8')]('$')[0x0]:undefined,_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x1f02')]=_0x21b004['system']['callerID']?_0x5889a8('0xa4c')+_0x21b004[_0x5889a8('0x1c2b')][_0x5889a8('0x992')]:undefined);_0x21b004['saveChatWebsiteApp']=_0x5ed641,_0x21b004[_0x5889a8('0x24a0')]=_0x18c44a,_0x3eae27['hasRole'](_0x5889a8('0xa7c'))?_0x2ec448['variable'][_0x5889a8('0xd83')]({'fields':_0x5889a8('0x1776'),'sort':'name','nolimit':_0x5889a8('0xf3b')})[_0x5889a8('0xa44')][_0x5889a8('0x1166')](function(_0x44d19c){const _0x2ab8cd=_0x5889a8;_0x21b004[_0x2ab8cd('0x57a')]=_0x44d19c[_0x2ab8cd('0x269a')]||[];})[_0x5889a8('0x1a80')](function(_0x275e2a){const _0x411474=_0x5889a8;_0x33f4e7['error']({'title':_0x275e2a[_0x411474('0x52d')]?_0x411474('0x1e21')+_0x275e2a[_0x411474('0x52d')]+_0x411474('0x11e1')+_0x275e2a[_0x411474('0xe1b')]:_0x411474('0xcf8'),'msg':_0x275e2a[_0x411474('0x25f4')]?JSON['stringify'](_0x275e2a[_0x411474('0x25f4')]):_0x275e2a['toString']()});}):_0x2ec448[_0x5889a8('0x734')][_0x5889a8('0xd83')]({'fields':_0x5889a8('0x1776'),'sort':'name','nolimit':'true'})[_0x5889a8('0xa44')][_0x5889a8('0x1166')](function(_0x4962f8){const _0x4ab3ab=_0x5889a8;_0x21b004[_0x4ab3ab('0x57a')]=_0x4962f8[_0x4ab3ab('0x269a')]||[];})[_0x5889a8('0x1166')](function(){const _0x330a95=_0x5889a8;return _0x2ec448[_0x330a95('0x17aa')][_0x330a95('0xd83')]({'userProfileId':_0x21b004[_0x330a95('0x98')][_0x330a95('0xb86')],'sectionId':0x3f4})[_0x330a95('0xa44')];})[_0x5889a8('0x1166')](function(_0x57a924){const _0x2a5be9=_0x5889a8,_0xe30935=_0x57a924&&_0x57a924['rows']?_0x57a924[_0x2a5be9('0x269a')][0x0]:null;if(!_0xe30935){const _0x3a3f0a=[];let _0x56537e=null;_0x21b004[_0x2a5be9('0x1c2b')]&&(_0x56537e=_0x2cfb05()[_0x2a5be9('0xc38')](_0x21b004[_0x2a5be9('0x57a')],{'name':_0x21b004[_0x2a5be9('0x1c2b')]['variable']}));for(let _0x4980ac=0x0;_0x4980ac<_0x21b004[_0x2a5be9('0x57a')]['length'];_0x4980ac++){_0x56537e&&_0x21b004[_0x2a5be9('0x57a')][_0x4980ac]['id']===_0x56537e['id']&&(_0x21b004[_0x2a5be9('0x57a')][_0x4980ac][_0x2a5be9('0x2378')]=![],_0x3a3f0a['push'](_0x21b004[_0x2a5be9('0x57a')][_0x4980ac]));}_0x21b004[_0x2a5be9('0x57a')]=_0x3a3f0a;}else{if(!_0xe30935[_0x2a5be9('0x1a2b')])return _0x2ec448[_0x2a5be9('0x4b5')][_0x2a5be9('0xd83')]({'sectionId':_0xe30935['id']})['$promise']['then'](function(_0x2d5f0e){const _0x5ca198=_0x2a5be9,_0x362de8=_0x2cfb05()['map'](_0x2d5f0e[_0x5ca198('0x269a')],function(_0x453bde){const _0xb7eb48=_0x5ca198;return _0x2cfb05()[_0xb7eb48('0xc38')](_0x21b004[_0xb7eb48('0x57a')],{'id':_0x453bde[_0xb7eb48('0x24e8')]});});let _0x4e9c5b=null;_0x21b004['system']&&(_0x4e9c5b=_0x2cfb05()['find'](_0x21b004[_0x5ca198('0x57a')],{'name':_0x21b004[_0x5ca198('0x1c2b')][_0x5ca198('0x734')]}));if(_0x4e9c5b&&!_0x2cfb05()[_0x5ca198('0x1798')](_0x362de8,['id',_0x4e9c5b['id']])){const _0xf4998f=_0x2cfb05()['find'](_0x21b004[_0x5ca198('0x57a')],{'id':_0x4e9c5b['id']});_0xf4998f['canSelect']=![],_0x362de8[_0x5ca198('0x1514')](_0xf4998f);}_0x21b004[_0x5ca198('0x57a')]=_0x362de8;});}})[_0x5889a8('0x1a80')](function(_0x278f3f){const _0x12a2ea=_0x5889a8;_0x33f4e7['error']({'title':_0x278f3f['status']?_0x12a2ea('0x1e21')+_0x278f3f[_0x12a2ea('0x52d')]+'\x20-\x20'+_0x278f3f[_0x12a2ea('0xe1b')]:'SYSTEM:GETvariables','msg':_0x278f3f[_0x12a2ea('0x25f4')]?JSON[_0x12a2ea('0xbac')](_0x278f3f['data']):_0x278f3f[_0x12a2ea('0x1586')]()});});function _0x5ed641(){const _0x1d4c6a=_0x5889a8;_0x21b004['errors']=[];const _0x57d374=[];_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x1345')]&&_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x1345')][_0x1d4c6a('0x2574')]()===_0x1d4c6a('0x587')&&_0x21b004[_0x1d4c6a('0x1c2b')]['appType']==='outboundDial'&&(_0x21b004['system'][_0x1d4c6a('0x2026')]=_0x52af8c[_0x1d4c6a('0x2848')]?(_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x265a')]||'')+'${EXTEN:'+_0x52af8c[_0x1d4c6a('0x2848')]+'}':(_0x21b004['system'][_0x1d4c6a('0x265a')]||'')+_0x1d4c6a('0x1d1'),_0x52af8c['recordingFormat']!==_0x1d4c6a('0x192')?_0x21b004[_0x1d4c6a('0x1c2b')]['options'][_0x1d4c6a('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0xd39')]+=_0x1d4c6a('0x1059')):_0x21b004['system'][_0x1d4c6a('0xd39')]=_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0xd39')]['replace'](_0x1d4c6a('0x1059'),''));if(_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x83f')]&&_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x83f')]==='custom'){}else switch((_0x21b004['system'][_0x1d4c6a('0x746')]||_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x83f')])[_0x1d4c6a('0x2574')]()){case'set':_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x823')]=_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x4f0')]+'='+_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x18e0')];break;case _0x1d4c6a('0x2853'):break;default:_0x57d374[0x0]=_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x187')],_0x57d374[0x1]=_0x21b004[_0x1d4c6a('0x1c2b')][_0x1d4c6a('0x734')],_0x21b004['system'][_0x1d4c6a('0x823')]=_0x57d374[_0x1d4c6a('0x45a')](',');}_0x18c44a(_0x21b004[_0x1d4c6a('0x1c2b')]);}function _0x18c44a(_0x10b47a){_0x58518a['hide'](_0x10b47a);}}const _0x46c2e1=_0x420196;_0x14dced[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty','chatWebsiteApp',_0x36e6f4('0x1864'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x14dced(_0x80ef10,_0x108e26,_0x269f7c,_0x104566,_0x6ae72a,_0x3b7ccc,_0x2cebcd,_0x75d36d){const _0xb8c0c9=_0x36e6f4,_0x4f0f77=this;_0x4f0f77[_0xb8c0c9('0x98')]=_0x2cebcd[_0xb8c0c9('0x26cd')](),_0x4f0f77[_0xb8c0c9('0x61a')]=[],_0x4f0f77[_0xb8c0c9('0xcdc')]=_0xb8c0c9('0x1c9b')+(_0x104566[_0xb8c0c9('0x83f')]||_0x104566[_0xb8c0c9('0x746')])['toUpperCase'](),_0x4f0f77['tag']=angular[_0xb8c0c9('0x225f')](_0x104566),_0x4f0f77['crudPermissions']=_0x75d36d,_0x4f0f77[_0xb8c0c9('0x128b')]={};if(_0x4f0f77[_0xb8c0c9('0x1446')]['appdata'])switch(_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x83f')]?_0x4f0f77[_0xb8c0c9('0x1446')]['appType'][_0xb8c0c9('0x2574')]():_0x4f0f77['tag'][_0xb8c0c9('0x746')][_0xb8c0c9('0x2574')]()){case _0xb8c0c9('0x2853'):break;case'dialogflow':{const _0x4fcd15=_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x823')][_0xb8c0c9('0x25c8')](',');_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x7ca')]=_0x4fcd15[0x0],_0x4f0f77[_0xb8c0c9('0x1446')]['language']=_0x4fcd15[0x1],_0x4f0f77['tag'][_0xb8c0c9('0x1634')]=_0x4fcd15[_0xb8c0c9('0x233')](0x2,_0x4fcd15[_0xb8c0c9('0x264b')])['join'](',');}break;case _0xb8c0c9('0x1636'):{const _0x569cbd=_0x4f0f77['tag']['appdata'][_0xb8c0c9('0x25c8')](',');_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x1b0a')]=_0x569cbd[0x0],_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x27f3')]=_0x569cbd[0x1],_0x4f0f77['tag'][_0xb8c0c9('0x170e')]=_0x569cbd[0x2],_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0xedb')]=_0x569cbd[0x3],_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x1634')]=_0x569cbd[_0xb8c0c9('0x233')](0x4,_0x569cbd[_0xb8c0c9('0x264b')])[_0xb8c0c9('0x45a')](',');}break;case _0xb8c0c9('0x86c'):{const _0x3c0e26=_0x4f0f77['tag'][_0xb8c0c9('0x823')][_0xb8c0c9('0x25c8')](',');_0x4f0f77[_0xb8c0c9('0x1446')]['accesskeyid']=_0x3c0e26[0x0],_0x4f0f77['tag']['secretaccesskey']=_0x3c0e26[0x1],_0x4f0f77['tag'][_0xb8c0c9('0x25a2')]=_0x3c0e26[0x2],_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x1ac4')]=_0x3c0e26[0x3],_0x4f0f77['tag'][_0xb8c0c9('0x1634')]=_0x3c0e26[_0xb8c0c9('0x233')](0x4,_0x3c0e26['length'])[_0xb8c0c9('0x45a')](',');}break;case _0xb8c0c9('0x1af7'):{const _0xbf7e57=_0x4f0f77[_0xb8c0c9('0x1446')]['appdata']['split'](',');_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x265e')]=isNaN(_0xbf7e57[0x0])?_0xbf7e57[0x0]:parseInt(_0xbf7e57[0x0],0xa),_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x1640')]=_0xbf7e57[_0xb8c0c9('0x233')](0x1,_0xbf7e57[_0xb8c0c9('0x264b')])['join'](',');}break;case _0xb8c0c9('0x1e70'):_0x4f0f77[_0xb8c0c9('0x1446')]['text']=_0x4f0f77[_0xb8c0c9('0x1446')]['appdata'];break;case _0xb8c0c9('0xceb'):_0x4f0f77['tag']['name']=_0x4f0f77['tag'][_0xb8c0c9('0x823')][_0xb8c0c9('0x25c8')]('=')[0x0],_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x18e0')]=_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x823')]['split']('=')[0x1];break;case'agi':_0x4f0f77['tag'][_0xb8c0c9('0x2588')]=_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x823')];break;default:{const _0x44528d=_0x4f0f77['tag'][_0xb8c0c9('0x823')]['split'](',');_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x1446')]=_0x2cfb05()['isEmpty'](_0x44528d[0x0])?_0x44528d[0x0]:isNaN(_0x44528d[0x0])?_0x44528d[0x0]:parseInt(_0x44528d[0x0],0xa);}break;}else{}_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x1345')]&&_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x1345')]['toLowerCase']()==='outbound'&&_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x83f')][_0xb8c0c9('0x2574')]()===_0xb8c0c9('0x2884')&&(_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x265a')]=_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x2026')]?_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x2026')]['split']('$')[0x0]:undefined,_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x1f02')]=_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x992')]?_0xb8c0c9('0xa4c')+_0x4f0f77[_0xb8c0c9('0x1446')][_0xb8c0c9('0x992')]:undefined);_0x4f0f77[_0xb8c0c9('0x22f7')]=_0x584947,_0x4f0f77[_0xb8c0c9('0x24a0')]=_0x33a57f,_0x2cebcd[_0xb8c0c9('0x1ac6')]('admin')?_0x3b7ccc[_0xb8c0c9('0x1446')][_0xb8c0c9('0xd83')]({'fields':_0xb8c0c9('0x1776'),'sort':'name','nolimit':'true'})['$promise']['then'](function(_0x4eda10){const _0x171aaa=_0xb8c0c9;_0x4f0f77[_0x171aaa('0xb38')]=_0x4eda10[_0x171aaa('0x269a')]||[];})[_0xb8c0c9('0x1a80')](function(_0x3071f5){const _0x17d65e=_0xb8c0c9;_0x269f7c[_0x17d65e('0xfc9')]({'title':_0x3071f5[_0x17d65e('0x52d')]?_0x17d65e('0x1e21')+_0x3071f5[_0x17d65e('0x52d')]+_0x17d65e('0x11e1')+_0x3071f5[_0x17d65e('0xe1b')]:_0x17d65e('0x402'),'msg':_0x3071f5[_0x17d65e('0x25f4')]?JSON[_0x17d65e('0xbac')](_0x3071f5[_0x17d65e('0x25f4')]):_0x3071f5[_0x17d65e('0x1586')]()});}):_0x3b7ccc[_0xb8c0c9('0x1446')][_0xb8c0c9('0xd83')]({'fields':_0xb8c0c9('0x1776'),'sort':_0xb8c0c9('0x4f0'),'nolimit':_0xb8c0c9('0xf3b')})[_0xb8c0c9('0xa44')][_0xb8c0c9('0x1166')](function(_0x6cee08){const _0x4d35fd=_0xb8c0c9;_0x4f0f77[_0x4d35fd('0xb38')]=_0x6cee08[_0x4d35fd('0x269a')]||[];})[_0xb8c0c9('0x1166')](function(){const _0x4db71f=_0xb8c0c9;return _0x3b7ccc[_0x4db71f('0x17aa')][_0x4db71f('0xd83')]({'userProfileId':_0x4f0f77['currentUser'][_0x4db71f('0xb86')],'sectionId':0x3f0})[_0x4db71f('0xa44')];})[_0xb8c0c9('0x1166')](function(_0x18ff61){const _0x161fc0=_0xb8c0c9,_0x157fa=_0x18ff61&&_0x18ff61[_0x161fc0('0x269a')]?_0x18ff61[_0x161fc0('0x269a')][0x0]:null;if(!_0x157fa){const _0x385591=[];let _0x552469=null;_0x4f0f77[_0x161fc0('0x1446')]&&(_0x552469=_0x2cfb05()[_0x161fc0('0xc38')](_0x4f0f77[_0x161fc0('0xb38')],{'name':_0x4f0f77[_0x161fc0('0x1446')][_0x161fc0('0x1446')]}));for(let _0x160336=0x0;_0x160336<_0x4f0f77[_0x161fc0('0xb38')]['length'];_0x160336++){_0x552469&&_0x4f0f77[_0x161fc0('0xb38')][_0x160336]['id']===_0x552469['id']&&(_0x4f0f77['tags'][_0x160336][_0x161fc0('0x2378')]=![],_0x385591['push'](_0x4f0f77[_0x161fc0('0xb38')][_0x160336]));}_0x4f0f77[_0x161fc0('0xb38')]=_0x385591;}else{if(!_0x157fa[_0x161fc0('0x1a2b')])return _0x3b7ccc[_0x161fc0('0x4b5')]['get']({'sectionId':_0x157fa['id']})[_0x161fc0('0xa44')][_0x161fc0('0x1166')](function(_0x5e1deb){const _0x3fb531=_0x161fc0,_0x1ae78a=_0x2cfb05()['map'](_0x5e1deb['rows'],function(_0x2ecf80){const _0x1ef422=a0_0x3f2c;return _0x2cfb05()[_0x1ef422('0xc38')](_0x4f0f77[_0x1ef422('0xb38')],{'id':_0x2ecf80[_0x1ef422('0x24e8')]});});let _0x8abb98=null;_0x4f0f77['tag']&&(_0x8abb98=_0x2cfb05()[_0x3fb531('0xc38')](_0x4f0f77[_0x3fb531('0xb38')],{'name':_0x4f0f77[_0x3fb531('0x1446')][_0x3fb531('0x1446')]}));if(_0x8abb98&&!_0x2cfb05()[_0x3fb531('0x1798')](_0x1ae78a,['id',_0x8abb98['id']])){const _0x1427f5=_0x2cfb05()['find'](_0x4f0f77['tags'],{'id':_0x8abb98['id']});_0x1427f5['canSelect']=![],_0x1ae78a[_0x3fb531('0x1514')](_0x1427f5);}_0x4f0f77[_0x3fb531('0xb38')]=_0x1ae78a;});}})['catch'](function(_0x3e3a36){const _0x54c1c7=_0xb8c0c9;_0x269f7c['error']({'title':_0x3e3a36['status']?_0x54c1c7('0x1e21')+_0x3e3a36[_0x54c1c7('0x52d')]+_0x54c1c7('0x11e1')+_0x3e3a36[_0x54c1c7('0xe1b')]:'SYSTEM:GETtags','msg':_0x3e3a36[_0x54c1c7('0x25f4')]?JSON[_0x54c1c7('0xbac')](_0x3e3a36[_0x54c1c7('0x25f4')]):_0x3e3a36[_0x54c1c7('0x1586')]()});});function _0x584947(){const _0x56b38c=_0xb8c0c9;_0x4f0f77['errors']=[];const _0x3769ed=[];_0x4f0f77[_0x56b38c('0x1446')]['type']&&_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x1345')][_0x56b38c('0x2574')]()===_0x56b38c('0x587')&&_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x83f')]===_0x56b38c('0x867')&&(_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x2026')]=_0x6ae72a['cutdigits']?(_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x265a')]||'')+_0x56b38c('0x881')+_0x6ae72a['cutdigits']+'}':(_0x4f0f77['tag'][_0x56b38c('0x265a')]||'')+'${EXTEN}',_0x6ae72a[_0x56b38c('0x28cb')]!==_0x56b38c('0x192')?_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0xd39')][_0x56b38c('0x2379')](_0x56b38c('0x1059'))<0x0&&(_0x4f0f77['tag'][_0x56b38c('0xd39')]+='U(xcally-mixmonitor-context)'):_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0xd39')]=_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0xd39')][_0x56b38c('0xf3')](_0x56b38c('0x1059'),''));const _0x2fa65f=_0x2cfb05()[_0x56b38c('0xc38')](_0x4f0f77[_0x56b38c('0xb38')],{'name':_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x1446')]});_0x2fa65f&&(_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x8f5')]=_0x2fa65f['id']);if(_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x83f')]&&_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x83f')]===_0x56b38c('0x2853')){}else switch((_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x746')]||_0x4f0f77[_0x56b38c('0x1446')]['appType'])[_0x56b38c('0x2574')]()){case _0x56b38c('0xceb'):_0x4f0f77['tag'][_0x56b38c('0x823')]=_0x4f0f77[_0x56b38c('0x1446')]['name']+'='+_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x18e0')];break;case _0x56b38c('0x2853'):break;default:_0x3769ed[0x0]=_0x4f0f77[_0x56b38c('0x1446')]['tag'],_0x4f0f77[_0x56b38c('0x1446')][_0x56b38c('0x823')]=_0x3769ed[_0x56b38c('0x45a')](',');}_0x33a57f(_0x4f0f77[_0x56b38c('0x1446')]);}function _0x33a57f(_0x190e9c){const _0x122b0a=_0xb8c0c9;_0x80ef10[_0x122b0a('0x1197')](_0x190e9c);}}const _0x1edfc6=_0x14dced,_0x409247=_0x2734b2['p']+_0x36e6f4('0x142c');_0x3d9ec6[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x3d9ec6(_0x1ad2d4,_0x524af6,_0x4aa442,_0x470674,_0x479625,_0x161b43,_0x16aff2,_0x2b0ed5,_0xfc2e58,_0x37b211,_0x52faf1){const _0x3e6bd1=_0x36e6f4,_0x4a0e66=this;_0x4a0e66[_0x3e6bd1('0x98')]=_0x52faf1[_0x3e6bd1('0x26cd')](),_0x4a0e66[_0x3e6bd1('0x1864')]={},_0x4a0e66[_0x3e6bd1('0x255')]={'count':0x0,'rows':[]},_0x4a0e66[_0x3e6bd1('0x1b84')]=[],_0x4a0e66[_0x3e6bd1('0x243c')],_0x4a0e66[_0x3e6bd1('0x2218')]={'fields':_0x3e6bd1('0x1b4'),'limit':0xa,'page':0x1},_0x4a0e66[_0x3e6bd1('0x24d5')]=_0x1a03d0,_0x4a0e66['deleteConfirm']=_0x30877a,_0x4a0e66['success']=_0x174638,_0x4a0e66[_0x3e6bd1('0x1f6a')]=_0x5b5580,_0x4a0e66[_0x3e6bd1('0x16f9')]=_0x4b3725,_0x4a0e66[_0x3e6bd1('0x1443')]=_0x4ddd73,_0x4a0e66[_0x3e6bd1('0x10be')]=_0x18dcba,_0x4a0e66['deleteSelectedChatWebsiteChatCannedAnswers']=_0x3bc57d;function _0x1a03d0(_0x547a9b,_0x39de26){const _0x35048c=_0x3e6bd1;_0x4a0e66[_0x35048c('0x1864')]=_0x547a9b,_0x4a0e66[_0x35048c('0x243c')]=typeof _0x39de26!==_0x35048c('0x1048')?_0x39de26:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4a0e66[_0x35048c('0x2218')]['ChatWebsiteId']=_0x4a0e66[_0x35048c('0x1864')]['id'],_0x4a0e66[_0x35048c('0x2218')]['id']=_0x4a0e66[_0x35048c('0x1864')]['id'],_0x5b5580();}function _0x30877a(_0x461843,_0x5bf3fb){const _0x1b4a89=_0x3e6bd1,_0x4d482d=_0x16aff2[_0x1b4a89('0x1d26')]()['title'](_0x1b4a89('0x212d'))['htmlContent'](_0x1b4a89('0x12b5')+(_0x461843[_0x1b4a89('0x4f0')]||_0x461843['id']&&_0x2cfb05()[_0x1b4a89('0x114b')](_0x1b4a89('0x1e41'))+_0x461843['id']||_0x1b4a89('0x2133'))+_0x1b4a89('0xace')+_0x1b4a89('0x3f3'))['ariaLabel'](_0x1b4a89('0x23ad'))['targetEvent'](_0x5bf3fb)['ok']('OK')['cancel']('CANCEL');_0x16aff2['show'](_0x4d482d)['then'](function(){_0x18dcba(_0x461843);},function(){const _0x516b43=_0x1b4a89;console[_0x516b43('0x455')](_0x516b43('0x2d3'));});}function _0x174638(_0x2e8371){const _0x4e82cc=_0x3e6bd1;_0x4a0e66[_0x4e82cc('0x255')]=_0x2e8371||{'count':0x0,'rows':[]};}function _0x5b5580(){const _0x5051cc=_0x3e6bd1;_0x4a0e66[_0x5051cc('0x2218')][_0x5051cc('0x1098')]=(_0x4a0e66[_0x5051cc('0x2218')][_0x5051cc('0x1a43')]-0x1)*_0x4a0e66[_0x5051cc('0x2218')]['limit'],_0x4a0e66['promise']=_0x37b211[_0x5051cc('0x1864')][_0x5051cc('0xab8')](_0x4a0e66['query'],_0x174638)[_0x5051cc('0xa44')];}function _0x4b3725(_0xdb69d3,_0x4fd5cc){const _0x3fc2fa=_0x3e6bd1;_0x16aff2['show']({'controller':_0x3fc2fa('0x191a'),'controllerAs':'vm','templateUrl':_0x409247,'parent':angular[_0x3fc2fa('0x1194')](_0x2b0ed5[_0x3fc2fa('0x8d2')]),'targetEvent':_0xdb69d3,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x4a0e66[_0x3fc2fa('0x1864')],'chatCannedAnswer':_0x4fd5cc,'chatCannedAnswers':_0x4a0e66[_0x3fc2fa('0x255')]['rows'],'license':null,'setting':null,'crudPermissions':_0x4a0e66[_0x3fc2fa('0x243c')]}});}function _0x18dcba(_0x4ecd26){const _0x5ee836=_0x3e6bd1;_0x37b211[_0x5ee836('0x1b1f')][_0x5ee836('0x906')]({'id':_0x4ecd26['id']})['$promise']['then'](function(){const _0x3fdadb=_0x5ee836;_0x2cfb05()[_0x3fdadb('0x127f')](_0x4a0e66[_0x3fdadb('0x255')]['rows'],{'id':_0x4ecd26['id']}),_0x4a0e66['chatWebsiteChatCannedAnswers'][_0x3fdadb('0x240f')]-=0x1,!_0x4a0e66[_0x3fdadb('0x255')][_0x3fdadb('0x269a')]['length']&&_0x5b5580(),_0xfc2e58[_0x3fdadb('0x103b')]({'title':_0x3fdadb('0x277d'),'msg':_0x4ecd26[_0x3fdadb('0x4f0')]?_0x4ecd26[_0x3fdadb('0x4f0')]+_0x3fdadb('0x7cd'):''});})[_0x5ee836('0x1a80')](function(_0x1a94f9){const _0x1cc92e=_0x5ee836;if(_0x1a94f9[_0x1cc92e('0x25f4')]&&_0x1a94f9[_0x1cc92e('0x25f4')][_0x1cc92e('0x61a')]&&_0x1a94f9[_0x1cc92e('0x25f4')][_0x1cc92e('0x61a')]['length']){_0x4a0e66[_0x1cc92e('0x61a')]=_0x1a94f9[_0x1cc92e('0x25f4')]['errors']||[{'message':_0x1a94f9[_0x1cc92e('0x1586')](),'type':_0x1cc92e('0x8b8')}];for(let _0x2b1281=0x0;_0x2b1281<_0x1a94f9['data'][_0x1cc92e('0x61a')][_0x1cc92e('0x264b')];_0x2b1281++){_0xfc2e58[_0x1cc92e('0xfc9')]({'title':_0x1a94f9[_0x1cc92e('0x25f4')][_0x1cc92e('0x61a')][_0x2b1281][_0x1cc92e('0x1345')],'msg':_0x1a94f9[_0x1cc92e('0x25f4')][_0x1cc92e('0x61a')][_0x2b1281]['message']});}}else _0xfc2e58['error']({'title':_0x1a94f9[_0x1cc92e('0x52d')]?_0x1cc92e('0x1e21')+_0x1a94f9[_0x1cc92e('0x52d')]+_0x1cc92e('0x11e1')+_0x1a94f9[_0x1cc92e('0xe1b')]:_0x1cc92e('0x8b8'),'msg':_0x1a94f9[_0x1cc92e('0x25f4')]?JSON[_0x1cc92e('0xbac')](_0x1a94f9[_0x1cc92e('0x25f4')][_0x1cc92e('0x1e70')]):_0x1a94f9[_0x1cc92e('0x1e70')]||_0x1a94f9[_0x1cc92e('0x1586')]()});});}function _0x4ddd73(){const _0xfc31e4=_0x3e6bd1,_0x1e3641=angular[_0xfc31e4('0x225f')](_0x4a0e66['selectedChatWebsiteChatCannedAnswers']);return _0x4a0e66[_0xfc31e4('0x1b84')]=[],_0x1e3641;}function _0x3bc57d(_0x308992){const _0x266078=_0x3e6bd1,_0x4f5e00=_0x16aff2[_0x266078('0x1d26')]()['title'](_0x266078('0x1302'))[_0x266078('0xf3c')](_0x266078('0x12b5')+_0x4a0e66[_0x266078('0x1b84')][_0x266078('0x264b')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x266078('0x8e8')](_0x266078('0xe6e'))[_0x266078('0x203b')](_0x308992)['ok']('OK')['cancel'](_0x266078('0x2d3'));_0x16aff2[_0x266078('0x1f80')](_0x4f5e00)[_0x266078('0x1166')](function(){const _0x116e69=_0x266078;_0x4a0e66[_0x116e69('0x1b84')]['forEach'](function(_0x528819){_0x18dcba(_0x528819);}),_0x4a0e66[_0x116e69('0x1b84')]=[];});}let _0x2dade9=!![],_0x124607=0x1;_0x524af6[_0x3e6bd1('0xe83')](_0x3e6bd1('0x28b4'),function(_0x4610e0,_0x335c2d){const _0x3fe693=_0x3e6bd1;_0x2dade9?_0x161b43(function(){_0x2dade9=![];}):(!_0x335c2d&&(_0x124607=_0x4a0e66[_0x3fe693('0x2218')][_0x3fe693('0x1a43')]),_0x4610e0!==_0x335c2d&&(_0x4a0e66['query'][_0x3fe693('0x1a43')]=0x1),!_0x4610e0&&(_0x4a0e66[_0x3fe693('0x2218')]['page']=_0x124607),_0x5b5580());});}const _0x399cbb=_0x3d9ec6;_0x393769['$inject']=['$scope','$state','$location',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x4eb'),_0x36e6f4('0x2133'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x393769(_0x2e2f9f,_0x15e840,_0x1d13c7,_0x1c916f,_0x576dba,_0x2330d5,_0x40db0c,_0x1a716f,_0x251b23,_0x2a2473,_0x235321,_0x28e0a3,_0x5edd3d,_0x591c65){const _0x13690b=_0x36e6f4,_0x58b776=this;_0x58b776[_0x13690b('0x98')]=_0x235321[_0x13690b('0x26cd')](),_0x58b776['errors']=[],_0x58b776[_0x13690b('0xf8a')]=_0x5edd3d,_0x58b776[_0x13690b('0x5c9')]=_0x28e0a3,_0x58b776[_0x13690b('0x243c')]=_0x591c65,_0x58b776['hasModulePermissions']={},_0x58b776[_0x13690b('0x2900')]=_0x58b776[_0x13690b('0xf8a')]&&_0x58b776[_0x13690b('0xf8a')][_0x13690b('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x58b776[_0x13690b('0xcdc')]='CHAT.EDIT_CHATCANNEDANSWER',_0x58b776['chatCannedAnswer']=angular[_0x13690b('0x225f')](_0x251b23),_0x58b776[_0x13690b('0x4eb')]=_0x1a716f,_0x58b776[_0x13690b('0x222')]=![];!_0x58b776[_0x13690b('0x2133')]&&(_0x58b776[_0x13690b('0x2133')]={},_0x58b776['title']=_0x13690b('0x1183'),_0x58b776[_0x13690b('0x222')]=!![]);_0x15e840['params']['id']&&(_0x58b776['chatCannedAnswer'][_0x13690b('0x1e02')]=_0x15e840[_0x13690b('0x23f')]['id']);_0x58b776['addNewChatCannedAnswer']=_0x191149,_0x58b776[_0x13690b('0x2481')]=_0x51592e,_0x58b776['deleteChatCannedAnswer']=_0x57c0b8,_0x58b776[_0x13690b('0x1a9c')]=_0x175fe9,_0x58b776['closeDialog']=_0x2eb6a5;function _0x191149(){const _0x946f1=_0x13690b;_0x58b776[_0x946f1('0x61a')]=[],_0x2a2473['cannedAnswer'][_0x946f1('0x9cc')](_0x58b776[_0x946f1('0x2133')])['$promise'][_0x946f1('0x1166')](function(_0x3845f3){const _0xfb99dc=_0x946f1;_0x58b776[_0xfb99dc('0x4eb')][_0xfb99dc('0x2450')](_0x3845f3['toJSON']()),_0x40db0c[_0xfb99dc('0x103b')]({'title':_0xfb99dc('0xc20'),'msg':_0x58b776[_0xfb99dc('0x2133')][_0xfb99dc('0x4f0')]?_0x58b776[_0xfb99dc('0x2133')][_0xfb99dc('0x4f0')]+_0xfb99dc('0x1eda'):''}),_0x2eb6a5(_0x3845f3);})[_0x946f1('0x1a80')](function(_0x573b77){const _0xbef00b=_0x946f1;if(_0x573b77['data']&&_0x573b77[_0xbef00b('0x25f4')]['errors']&&_0x573b77[_0xbef00b('0x25f4')]['errors'][_0xbef00b('0x264b')]){_0x58b776[_0xbef00b('0x61a')]=_0x573b77[_0xbef00b('0x25f4')][_0xbef00b('0x61a')]||[{'message':_0x573b77['toString'](),'type':'api.cannedAnswer.save'}];for(let _0x154d2d=0x0;_0x154d2d<_0x573b77[_0xbef00b('0x25f4')][_0xbef00b('0x61a')][_0xbef00b('0x264b')];_0x154d2d+=0x1){_0x40db0c[_0xbef00b('0xfc9')]({'title':_0x573b77[_0xbef00b('0x25f4')][_0xbef00b('0x61a')][_0x154d2d][_0xbef00b('0x1345')],'msg':_0x573b77['data']['errors'][_0x154d2d]['message']});}}else _0x40db0c['error']({'title':_0x573b77[_0xbef00b('0x52d')]?'API:'+_0x573b77[_0xbef00b('0x52d')]+_0xbef00b('0x11e1')+_0x573b77[_0xbef00b('0xe1b')]:'api.cannedAnswer.save','msg':_0x573b77[_0xbef00b('0x25f4')]?JSON[_0xbef00b('0xbac')](_0x573b77[_0xbef00b('0x25f4')][_0xbef00b('0x1e70')]):_0x573b77[_0xbef00b('0x1586')]()});});}function _0x51592e(){const _0xa6d5a1=_0x13690b;_0x58b776[_0xa6d5a1('0x61a')]=[],_0x2a2473[_0xa6d5a1('0x1b1f')]['update']({'id':_0x58b776[_0xa6d5a1('0x2133')]['id']},_0x58b776[_0xa6d5a1('0x2133')])['$promise']['then'](function(_0x2a326a){const _0x5ae553=_0xa6d5a1,_0x467da3=_0x2cfb05()[_0x5ae553('0xc38')](_0x58b776[_0x5ae553('0x4eb')],{'id':_0x2a326a['id']});_0x467da3&&_0x2cfb05()[_0x5ae553('0xcc3')](_0x467da3,_0x2cfb05()['pick'](_0x2a326a[_0x5ae553('0x2876')](),_0x2cfb05()[_0x5ae553('0x14a4')](_0x467da3))),_0x40db0c[_0x5ae553('0x103b')]({'title':'ChatCannedAnswer\x20properly\x20saved!','msg':_0x58b776[_0x5ae553('0x2133')][_0x5ae553('0x4f0')]?_0x58b776['chatCannedAnswer'][_0x5ae553('0x4f0')]+_0x5ae553('0x7d'):''}),_0x2eb6a5(_0x2a326a);})[_0xa6d5a1('0x1a80')](function(_0x1480a4){const _0x1b55f9=_0xa6d5a1;if(_0x1480a4[_0x1b55f9('0x25f4')]&&_0x1480a4['data'][_0x1b55f9('0x61a')]&&_0x1480a4[_0x1b55f9('0x25f4')][_0x1b55f9('0x61a')][_0x1b55f9('0x264b')]){_0x58b776['errors']=_0x1480a4[_0x1b55f9('0x25f4')][_0x1b55f9('0x61a')]||[{'message':_0x1480a4['toString'](),'type':_0x1b55f9('0x122e')}];for(let _0x3f3b0a=0x0;_0x3f3b0a<_0x1480a4[_0x1b55f9('0x25f4')][_0x1b55f9('0x61a')][_0x1b55f9('0x264b')];_0x3f3b0a++){_0x40db0c[_0x1b55f9('0xfc9')]({'title':_0x1480a4[_0x1b55f9('0x25f4')][_0x1b55f9('0x61a')][_0x3f3b0a][_0x1b55f9('0x1345')],'msg':_0x1480a4['data'][_0x1b55f9('0x61a')][_0x3f3b0a][_0x1b55f9('0x1e70')]});}}else _0x40db0c['error']({'title':_0x1480a4[_0x1b55f9('0x52d')]?_0x1b55f9('0x1e21')+_0x1480a4[_0x1b55f9('0x52d')]+_0x1b55f9('0x11e1')+_0x1480a4[_0x1b55f9('0xe1b')]:'api.cannedAnswer.update','msg':_0x1480a4[_0x1b55f9('0x25f4')]?JSON[_0x1b55f9('0xbac')](_0x1480a4[_0x1b55f9('0x25f4')]['message']):_0x1480a4['toString']()});});}function _0x57c0b8(_0x100509){const _0x2bc7e3=_0x13690b;_0x58b776['errors']=[];const _0x1beb61=_0x1c916f['confirm']()[_0x2bc7e3('0xcdc')](_0x2bc7e3('0x7fb'))[_0x2bc7e3('0xacc')](_0x2bc7e3('0x1642'))[_0x2bc7e3('0x8e8')](_0x2bc7e3('0xd14'))['ok'](_0x2bc7e3('0x18'))['cancel'](_0x2bc7e3('0x497'))[_0x2bc7e3('0x203b')](_0x100509);_0x1c916f[_0x2bc7e3('0x1f80')](_0x1beb61)[_0x2bc7e3('0x1166')](function(){const _0x6cd60d=_0x2bc7e3;_0x2a2473['cannedAnswer'][_0x6cd60d('0x906')]({'id':_0x58b776[_0x6cd60d('0x2133')]['id']})['$promise'][_0x6cd60d('0x1166')](function(){const _0x2126a1=_0x6cd60d;_0x2cfb05()['remove'](_0x58b776[_0x2126a1('0x4eb')],{'id':_0x58b776[_0x2126a1('0x2133')]['id']}),_0x40db0c[_0x2126a1('0x103b')]({'title':_0x2126a1('0x27ce'),'msg':(_0x58b776[_0x2126a1('0x2133')][_0x2126a1('0x4f0')]||_0x2126a1('0x2133'))+_0x2126a1('0x7cd')}),_0x2eb6a5(_0x58b776[_0x2126a1('0x2133')]);})['catch'](function(_0x57dd5f){const _0x4e0de1=_0x6cd60d;if(_0x57dd5f[_0x4e0de1('0x25f4')]&&_0x57dd5f[_0x4e0de1('0x25f4')][_0x4e0de1('0x61a')]&&_0x57dd5f['data'][_0x4e0de1('0x61a')][_0x4e0de1('0x264b')]){_0x58b776['errors']=_0x57dd5f[_0x4e0de1('0x25f4')]['errors']||[{'message':_0x57dd5f[_0x4e0de1('0x1586')](),'type':_0x4e0de1('0x1da9')}];for(let _0x3be088=0x0;_0x3be088<_0x57dd5f[_0x4e0de1('0x25f4')][_0x4e0de1('0x61a')]['length'];_0x3be088++){_0x40db0c['error']({'title':_0x57dd5f[_0x4e0de1('0x25f4')]['errors'][_0x3be088][_0x4e0de1('0x1345')],'msg':_0x57dd5f[_0x4e0de1('0x25f4')][_0x4e0de1('0x61a')][_0x3be088][_0x4e0de1('0x1e70')]});}}else _0x40db0c[_0x4e0de1('0xfc9')]({'title':_0x57dd5f[_0x4e0de1('0x52d')]?_0x4e0de1('0x1e21')+_0x57dd5f[_0x4e0de1('0x52d')]+_0x4e0de1('0x11e1')+_0x57dd5f[_0x4e0de1('0xe1b')]:_0x4e0de1('0x1da9'),'msg':_0x57dd5f[_0x4e0de1('0x25f4')]?JSON['stringify'](_0x57dd5f[_0x4e0de1('0x25f4')][_0x4e0de1('0x1e70')]):_0x57dd5f['message']||_0x57dd5f[_0x4e0de1('0x1586')]()});});},function(){});}function _0x175fe9(_0x22e2b5){return _0x22e2b5===null?undefined:new Date(_0x22e2b5);}function _0x2eb6a5(_0x34bc9c){const _0x508ecd=_0x13690b;_0x1c916f[_0x508ecd('0x1197')](_0x34bc9c);}}const _0x5a081e=_0x393769;_0x274957[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),'toasty',_0x36e6f4('0x21ef')];function _0x274957(_0x891d96,_0x392ded,_0x1d5695,_0x5ae319,_0x12554b,_0x334a9b,_0x55dab3,_0x3f1376,_0xd0d164,_0x570513,_0x298f19){const _0x40e9bc=_0x36e6f4,_0x3075cb=this;_0x3075cb[_0x40e9bc('0x98')]=_0x298f19['getCurrentUser'](),_0x3075cb[_0x40e9bc('0x4ea')]={'count':0x0,'rows':[]},_0x3075cb[_0x40e9bc('0x1082')]=[],_0x3075cb['crudPermissions'],_0x3075cb['levels']={'first':_0x40e9bc('0xc31'),'second':_0x40e9bc('0x580'),'third':_0x40e9bc('0x1144')},_0x3075cb[_0x40e9bc('0x2218')]={'fields':_0x40e9bc('0xf1a'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x3075cb[_0x40e9bc('0x24d5')]=_0x5c75a7,_0x3075cb['deleteConfirm']=_0x3213ed,_0x3075cb[_0x40e9bc('0x103b')]=_0x4de0ae,_0x3075cb[_0x40e9bc('0x3e')]=_0x2c70a6,_0x3075cb[_0x40e9bc('0x782')]=_0x49067f,_0x3075cb[_0x40e9bc('0x27c6')]=_0x336274,_0x3075cb[_0x40e9bc('0x4e2')]=_0x24815b,_0x3075cb[_0x40e9bc('0x14b5')]=_0x341bc9,_0x3075cb[_0x40e9bc('0x205e')]=_0x5e8fa6,_0x3075cb['selectAllDispositions']=_0x120b2d;function _0x5c75a7(_0x535c6c,_0x6da4a5){const _0x13ea7d=_0x40e9bc;_0x3075cb[_0x13ea7d('0x1864')]=_0x535c6c||{},_0x3075cb[_0x13ea7d('0x243c')]=typeof _0x6da4a5!==_0x13ea7d('0x1048')?_0x6da4a5:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3075cb[_0x13ea7d('0x2218')][_0x13ea7d('0x1e02')]=_0x3075cb[_0x13ea7d('0x1864')]['id'],_0x3075cb[_0x13ea7d('0x2218')]['id']=_0x3075cb['chatWebsite']['id'],_0x2c70a6();}function _0x49067f(_0x5a9ad3,_0xc1e55c){const _0x1f2542=_0x40e9bc;_0x12554b[_0x1f2542('0x1f80')]({'controller':_0x1f2542('0x17a3'),'controllerAs':'vm','templateUrl':_0x14e8d3,'parent':angular['element'](_0x334a9b[_0x1f2542('0x8d2')]),'targetEvent':_0x5a9ad3,'clickOutsideToClose':!![],'locals':{'disposition':_0xc1e55c,'dispositions':_0x3075cb['dispositions']['rows'],'model':{'id':_0x3075cb[_0x1f2542('0x1864')]['id'],'field':'ChatWebsiteId'},'license':null,'setting':null,'crudPermissions':_0x3075cb[_0x1f2542('0x243c')]}})[_0x1f2542('0x1166')](function(_0x111c06){if(_0x111c06)_0x2c70a6();});}function _0x3213ed(_0x5039b8,_0x4c0164){const _0x530661=_0x40e9bc,_0x31598e=_0x2cfb05()[_0x530661('0x1798')](_0x3075cb[_0x530661('0x4ea')]['rows'],[_0x530661('0x11fa'),_0x5039b8['id']]),_0x49e041=_0x12554b[_0x530661('0x1d26')]()['title'](_0x3f1376['instant']('TOOLS.NOTIFICATIONS.DISPOSITION_DELETE_TITLE'))['content'](_0x3f1376[_0x530661('0x25cc')](_0x530661('0x92f')+(_0x31598e?'DISPOSITION_DELETE_MESSAGE_CHILDREN':'DISPOSITION_DELETE_MESSAGE'),{'name':_0x5039b8[_0x530661('0x4f0')]}))['ariaLabel'](_0x530661('0x1af2'))[_0x530661('0x203b')](_0x4c0164)['ok']('OK')[_0x530661('0x3f')](_0x3f1376[_0x530661('0x25cc')](_0x530661('0x12a3')));_0x12554b[_0x530661('0x1f80')](_0x49e041)[_0x530661('0x1166')](function(){_0x336274(_0x5039b8);});}function _0x4de0ae(_0xf64589){_0x3075cb['dispositions']=_0xf64589||{'count':0x0,'rows':[]};}function _0x2c70a6(){const _0x5cb1b2=_0x40e9bc;_0x3075cb[_0x5cb1b2('0x2218')][_0x5cb1b2('0x1098')]=(_0x3075cb[_0x5cb1b2('0x2218')][_0x5cb1b2('0x1a43')]-0x1)*_0x3075cb[_0x5cb1b2('0x2218')][_0x5cb1b2('0x163f')],_0x3075cb[_0x5cb1b2('0x1f48')]=_0xd0d164[_0x5cb1b2('0x1864')][_0x5cb1b2('0x3e')](_0x3075cb[_0x5cb1b2('0x2218')],_0x4de0ae)[_0x5cb1b2('0xa44')];}function _0x336274(_0x17a7a7){const _0x5f00fa=_0x40e9bc;_0xd0d164['disposition'][_0x5f00fa('0x906')]({'id':_0x17a7a7['id']})[_0x5f00fa('0xa44')][_0x5f00fa('0x1166')](function(){const _0x531795=_0x5f00fa;_0x2c70a6(),_0x570513[_0x531795('0x103b')]({'title':_0x3f1376['instant'](_0x531795('0x1ca6'))});})[_0x5f00fa('0x1a80')](function(_0x1d835c){const _0x1a90d2=_0x5f00fa;if(_0x1d835c[_0x1a90d2('0x25f4')]&&_0x1d835c[_0x1a90d2('0x25f4')]['errors']&&_0x1d835c[_0x1a90d2('0x25f4')][_0x1a90d2('0x61a')][_0x1a90d2('0x264b')]){_0x3075cb[_0x1a90d2('0x61a')]=_0x1d835c[_0x1a90d2('0x25f4')][_0x1a90d2('0x61a')]||[{'message':_0x1d835c[_0x1a90d2('0x1586')](),'type':_0x1a90d2('0x1b2c')}];for(let _0x3e542f=0x0;_0x3e542f<_0x1d835c[_0x1a90d2('0x25f4')][_0x1a90d2('0x61a')][_0x1a90d2('0x264b')];_0x3e542f++){_0x570513[_0x1a90d2('0xfc9')]({'title':_0x1d835c[_0x1a90d2('0x25f4')][_0x1a90d2('0x61a')][_0x3e542f][_0x1a90d2('0x1345')],'msg':_0x1d835c['data'][_0x1a90d2('0x61a')][_0x3e542f][_0x1a90d2('0x1e70')]});}}else _0x570513['error']({'title':_0x1d835c['status']?_0x1a90d2('0x1e21')+_0x1d835c[_0x1a90d2('0x52d')]+_0x1a90d2('0x11e1')+_0x1d835c['statusText']:_0x1a90d2('0x1b2c'),'msg':_0x1d835c[_0x1a90d2('0x25f4')]?JSON['stringify'](_0x1d835c[_0x1a90d2('0x25f4')][_0x1a90d2('0x1e70')]):_0x1d835c[_0x1a90d2('0x1e70')]||_0x1d835c['toString']()});});}function _0x24815b(){const _0x367ec2=angular['copy'](_0x3075cb['selectedDispositions']);return _0x3075cb['selectedDispositions']=[],_0x367ec2;}function _0x341bc9(_0xf06f0f){const _0x20547b=_0x40e9bc,_0x383094=_0x12554b[_0x20547b('0x1d26')]()[_0x20547b('0xcdc')](_0x3f1376[_0x20547b('0x25cc')]('TOOLS.NOTIFICATIONS.DISPOSITIONS_DELETE_TITLE'))[_0x20547b('0xacc')](_0x3f1376[_0x20547b('0x25cc')](_0x20547b('0x223e'),{'total':_0x3075cb[_0x20547b('0x1082')][_0x20547b('0x264b')]}))[_0x20547b('0x8e8')](_0x20547b('0x19b'))[_0x20547b('0x203b')](_0xf06f0f)['ok']('OK')['cancel'](_0x3f1376[_0x20547b('0x25cc')](_0x20547b('0x12a3')));_0x12554b[_0x20547b('0x1f80')](_0x383094)['then'](function(){const _0x27798b=_0x20547b;_0x3075cb[_0x27798b('0x1082')][_0x27798b('0x2782')](function(_0xdd0191){_0x336274(_0xdd0191);}),_0x3075cb['selectedDispositions']=[];});}function _0x5e8fa6(){const _0x1be2e9=_0x40e9bc;_0x3075cb[_0x1be2e9('0x1082')]=[];}function _0x120b2d(){_0x3075cb['selectedDispositions']=_0x3075cb['dispositions']['rows'];}let _0x3f27bf=!![],_0x2d3bd6=0x1;_0x891d96[_0x40e9bc('0xe83')](_0x40e9bc('0x28b4'),function(_0x23dd59,_0x411949){const _0x23bef2=_0x40e9bc;_0x3f27bf?_0x55dab3(function(){_0x3f27bf=![];}):(!_0x411949&&(_0x2d3bd6=_0x3075cb['query'][_0x23bef2('0x1a43')]),_0x23dd59!==_0x411949&&(_0x3075cb[_0x23bef2('0x2218')][_0x23bef2('0x1a43')]=0x1),!_0x23dd59&&(_0x3075cb[_0x23bef2('0x2218')][_0x23bef2('0x1a43')]=_0x2d3bd6),_0x2c70a6());});}const _0x50aee5=_0x274957;_0x5cbfef['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x19e3')];function _0x5cbfef(_0x46d58c,_0x4a14e2,_0x567dba){const _0x19569b=_0x36e6f4,_0x556467=this;_0x556467[_0x19569b('0x1864')]={},_0x556467[_0x19569b('0x13b5')]={},_0x556467[_0x19569b('0xb61')]=[{'type':_0x19569b('0x8ce'),'name':_0x19569b('0x100c'),'icon':'icon-label'},{'type':_0x19569b('0x764'),'name':'Select','icon':'icon-playlist-plus'},{'type':'input','name':_0x19569b('0x328'),'icon':_0x19569b('0x23d1')},{'type':'textarea','name':_0x19569b('0x1d71'),'icon':'icon-format-text'},{'type':'multipleChoices','name':'Radio\x20Buttons','icon':_0x19569b('0x4af')},{'type':_0x19569b('0xbba'),'name':_0x19569b('0xcbf'),'icon':_0x19569b('0x10ce')},{'type':'agreement','name':_0x19569b('0x848'),'icon':'icon-checkbox-marked-outline'}],_0x556467[_0x19569b('0x24d5')]=_0x45389e,_0x556467['up']=_0x3bdb6e,_0x556467[_0x19569b('0x2224')]=_0x2b42d6,_0x556467[_0x19569b('0x126a')]=_0x16ae23,_0x556467[_0x19569b('0x127f')]=_0x3b6111;function _0x45389e(_0x50c17d){const _0x5081cf=_0x19569b;_0x556467[_0x5081cf('0xfe2')]=[],_0x556467['customFields']=[],_0x556467['uselessFields']=['id',_0x5081cf('0x262'),_0x5081cf('0x6f9'),_0x5081cf('0x23c'),_0x5081cf('0x537'),'$promise',_0x5081cf('0xfcd')],_0x556467['chatWebsite']=_0x50c17d,_0x2cfb05()['isEmpty'](_0x556467['chatWebsite']['offlineForm'])&&(_0x556467[_0x5081cf('0x1864')][_0x5081cf('0x13b5')]={'items':[],'fromKey':null}),_0x567dba[_0x5081cf('0xdd9')][_0x5081cf('0x1bb')]({'id':_0x556467[_0x5081cf('0x1864')]['ListId']})[_0x5081cf('0xa44')]['then'](function(_0x3506a1){const _0x5d024f=_0x5081cf;for(let _0x483e64=0x0;_0x483e64<_0x3506a1[_0x5d024f('0x269a')][_0x5d024f('0x264b')];_0x483e64++){_0x556467[_0x5d024f('0x23d7')][_0x5d024f('0x1514')]({'key':'cf_'+_0x3506a1['rows'][_0x483e64]['id'],'value':_0x3506a1[_0x5d024f('0x269a')][_0x483e64]['alias']});}return _0x567dba[_0x5d024f('0x149e')][_0x5d024f('0x23d0')]()[_0x5d024f('0xa44')];})[_0x5081cf('0x1166')](function(_0x529f2f){const _0x1f9e55=_0x5081cf,_0x2211cc=_0x2cfb05()[_0x1f9e55('0x14a4')](_0x529f2f);for(let _0x265bf3=0x0;_0x265bf3<_0x2211cc[_0x1f9e55('0x264b')];_0x265bf3++){!_0x2cfb05()[_0x1f9e55('0x1257')](_0x556467[_0x1f9e55('0x23f2')],_0x2211cc[_0x265bf3])&&!_0x2cfb05()[_0x1f9e55('0x1783')](_0x2211cc[_0x265bf3],_0x1f9e55('0x711'))&&_0x556467['fields']['unshift']({'key':_0x2211cc[_0x265bf3],'value':_0x2211cc[_0x265bf3]});}return _0x567dba[_0x1f9e55('0x734')][_0x1f9e55('0xd83')]()[_0x1f9e55('0xa44')];})[_0x5081cf('0x1166')](function(_0x40c2a3){const _0x5262bd=_0x5081cf;_0x556467[_0x5262bd('0x57a')]=_0x40c2a3['rows'];})[_0x5081cf('0x1a80')](function(_0x5a226d){const _0x517429=_0x5081cf;console[_0x517429('0xfc9')](_0x5a226d);});}function _0x3bdb6e(_0x490d2a,_0x23ba71){const _0x5570d1=_0x19569b;if(_0x23ba71!==0x0){const _0x1e62b4=_0x556467[_0x5570d1('0x1864')][_0x5570d1('0x13b5')]['items'][_0x23ba71-0x1];_0x556467[_0x5570d1('0x1864')][_0x5570d1('0x13b5')]['items'][_0x23ba71]=_0x1e62b4,_0x556467[_0x5570d1('0x1864')][_0x5570d1('0x13b5')][_0x5570d1('0xbd7')][_0x23ba71-0x1]=angular['copy'](_0x490d2a);if(_0x556467[_0x5570d1('0x1864')][_0x5570d1('0x13b5')][_0x5570d1('0x1d63')]===_0x23ba71)_0x556467[_0x5570d1('0x1864')]['offlineForm'][_0x5570d1('0x1d63')]--;else _0x556467[_0x5570d1('0x1864')][_0x5570d1('0x13b5')][_0x5570d1('0x1d63')]===_0x23ba71-0x1&&_0x556467['chatWebsite'][_0x5570d1('0x13b5')][_0x5570d1('0x1d63')]++;}}function _0x2b42d6(_0x5e6f22,_0x38554d){const _0x4e0b7b=_0x19569b;if(_0x38554d!==_0x556467[_0x4e0b7b('0x1864')]['offlineForm'][_0x4e0b7b('0xbd7')][_0x4e0b7b('0x264b')]-0x1){const _0x4cc130=_0x556467[_0x4e0b7b('0x1864')][_0x4e0b7b('0x13b5')][_0x4e0b7b('0xbd7')][_0x38554d+0x1];_0x556467[_0x4e0b7b('0x1864')][_0x4e0b7b('0x13b5')][_0x4e0b7b('0xbd7')][_0x38554d]=_0x4cc130,_0x556467[_0x4e0b7b('0x1864')]['offlineForm']['items'][_0x38554d+0x1]=angular['copy'](_0x5e6f22);if(_0x556467['chatWebsite'][_0x4e0b7b('0x13b5')]['fromKey']===_0x38554d)_0x556467[_0x4e0b7b('0x1864')][_0x4e0b7b('0x13b5')]['fromKey']++;else _0x556467[_0x4e0b7b('0x1864')]['offlineForm']['fromKey']===_0x38554d+0x1&&_0x556467[_0x4e0b7b('0x1864')]['offlineForm'][_0x4e0b7b('0x1d63')]--;}}function _0x16ae23(_0x3476f5){const _0x1702dc=_0x19569b;_0x556467[_0x1702dc('0x1864')][_0x1702dc('0x13b5')]['items'][_0x1702dc('0x1514')]({'type':_0x3476f5,'cmField':null,'variable':null});}function _0x3b6111(_0x1b1e21){const _0x51ab6c=_0x19569b,_0x9c3b73=_0x46d58c['confirm']()[_0x51ab6c('0xcdc')]('The\x20component\x20will\x20be\x20deleted.')[_0x51ab6c('0x2077')](_0x51ab6c('0x7fb'))['ariaLabel'](_0x51ab6c('0x1c95'))['ok']('Ok')[_0x51ab6c('0x3f')](_0x51ab6c('0x497'));_0x46d58c[_0x51ab6c('0x1f80')](_0x9c3b73)[_0x51ab6c('0x1166')](function(){const _0x3a24e6=_0x51ab6c;_0x556467['chatWebsite'][_0x3a24e6('0x13b5')][_0x3a24e6('0xbd7')][_0x3a24e6('0x57b')](_0x1b1e21,0x1);});}}const _0x2e9506=_0x5cbfef;_0x4eb939[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x19e3')];function _0x4eb939(_0x2b871a,_0x64cc27,_0x3f565d){const _0x5a6755=_0x36e6f4,_0x5ca2c1=this;_0x5ca2c1[_0x5a6755('0x1864')]={},_0x5ca2c1[_0x5a6755('0x8c5')]={},_0x5ca2c1[_0x5a6755('0xb61')]=[{'type':_0x5a6755('0x8ce'),'name':'Label','icon':'icon-label'},{'type':_0x5a6755('0x764'),'name':'Select','icon':'icon-playlist-plus'},{'type':_0x5a6755('0xd7a'),'name':_0x5a6755('0x328'),'icon':_0x5a6755('0x23d1')},{'type':_0x5a6755('0x489'),'name':_0x5a6755('0x1d71'),'icon':'icon-format-text'},{'type':_0x5a6755('0xf57'),'name':_0x5a6755('0x2656'),'icon':_0x5a6755('0x4af')},{'type':_0x5a6755('0xbba'),'name':_0x5a6755('0xcbf'),'icon':_0x5a6755('0x10ce')},{'type':'agreement','name':_0x5a6755('0x848'),'icon':_0x5a6755('0x26ab')}],_0x5ca2c1[_0x5a6755('0x24d5')]=_0x38e2a8,_0x5ca2c1['up']=_0x531212,_0x5ca2c1[_0x5a6755('0x2224')]=_0x4ee867,_0x5ca2c1[_0x5a6755('0x126a')]=_0x30a883,_0x5ca2c1[_0x5a6755('0x127f')]=_0x1e4a58;function _0x38e2a8(_0x4ffc87){const _0x40f5b=_0x5a6755;_0x5ca2c1['fields']=[],_0x5ca2c1[_0x40f5b('0x23d7')]=[],_0x5ca2c1[_0x40f5b('0x23f2')]=['id',_0x40f5b('0x262'),_0x40f5b('0x6f9'),_0x40f5b('0x23c'),_0x40f5b('0x537'),_0x40f5b('0xa44'),'$resolved'],_0x5ca2c1[_0x40f5b('0x1864')]=_0x4ffc87,_0x2cfb05()[_0x40f5b('0x1081')](_0x5ca2c1[_0x40f5b('0x1864')]['onlineForm'])&&(_0x5ca2c1[_0x40f5b('0x1864')][_0x40f5b('0x8c5')]={'items':[],'fromKey':null}),_0x3f565d[_0x40f5b('0xdd9')][_0x40f5b('0x1bb')]({'id':_0x5ca2c1[_0x40f5b('0x1864')][_0x40f5b('0x23c')]})[_0x40f5b('0xa44')]['then'](function(_0x149dbb){const _0x58c176=_0x40f5b;for(let _0x30ea1e=0x0;_0x30ea1e<_0x149dbb[_0x58c176('0x269a')][_0x58c176('0x264b')];_0x30ea1e++){_0x5ca2c1[_0x58c176('0x23d7')][_0x58c176('0x1514')]({'key':_0x58c176('0x711')+_0x149dbb[_0x58c176('0x269a')][_0x30ea1e]['id'],'value':_0x149dbb[_0x58c176('0x269a')][_0x30ea1e][_0x58c176('0x4e')]});}return _0x3f565d['cmContact'][_0x58c176('0x23d0')]()[_0x58c176('0xa44')];})['then'](function(_0x6dc948){const _0x258087=_0x40f5b,_0x65db72=_0x2cfb05()[_0x258087('0x14a4')](_0x6dc948);for(let _0x4a0d40=0x0;_0x4a0d40<_0x65db72[_0x258087('0x264b')];_0x4a0d40++){!_0x2cfb05()[_0x258087('0x1257')](_0x5ca2c1[_0x258087('0x23f2')],_0x65db72[_0x4a0d40])&&!_0x2cfb05()['startsWith'](_0x65db72[_0x4a0d40],_0x258087('0x711'))&&_0x5ca2c1[_0x258087('0xfe2')]['unshift']({'key':_0x65db72[_0x4a0d40],'value':_0x65db72[_0x4a0d40]});}return _0x3f565d['variable'][_0x258087('0xd83')]()[_0x258087('0xa44')];})[_0x40f5b('0x1166')](function(_0x238868){const _0x28f2f1=_0x40f5b;_0x5ca2c1[_0x28f2f1('0x57a')]=_0x238868['rows'];})[_0x40f5b('0x1a80')](function(_0x2467bc){const _0x57a009=_0x40f5b;console[_0x57a009('0xfc9')](_0x2467bc);});}function _0x531212(_0x30b6ea,_0x2591d3){const _0x3f06a4=_0x5a6755;if(_0x2591d3!==0x0){const _0x3421c4=_0x5ca2c1['chatWebsite']['onlineForm'][_0x3f06a4('0xbd7')][_0x2591d3-0x1];_0x5ca2c1[_0x3f06a4('0x1864')][_0x3f06a4('0x8c5')][_0x3f06a4('0xbd7')][_0x2591d3]=_0x3421c4,_0x5ca2c1[_0x3f06a4('0x1864')][_0x3f06a4('0x8c5')][_0x3f06a4('0xbd7')][_0x2591d3-0x1]=angular[_0x3f06a4('0x225f')](_0x30b6ea);if(_0x5ca2c1[_0x3f06a4('0x1864')][_0x3f06a4('0x8c5')][_0x3f06a4('0x1d63')]===_0x2591d3)_0x5ca2c1[_0x3f06a4('0x1864')][_0x3f06a4('0x8c5')][_0x3f06a4('0x1d63')]--;else _0x5ca2c1[_0x3f06a4('0x1864')][_0x3f06a4('0x8c5')][_0x3f06a4('0x1d63')]===_0x2591d3-0x1&&_0x5ca2c1[_0x3f06a4('0x1864')][_0x3f06a4('0x8c5')][_0x3f06a4('0x1d63')]++;}}function _0x4ee867(_0x59f6c5,_0x4ad514){const _0x6bff55=_0x5a6755;if(_0x4ad514!==_0x5ca2c1[_0x6bff55('0x1864')][_0x6bff55('0x8c5')][_0x6bff55('0xbd7')]['length']-0x1){const _0x45f9fa=_0x5ca2c1[_0x6bff55('0x1864')][_0x6bff55('0x8c5')][_0x6bff55('0xbd7')][_0x4ad514+0x1];_0x5ca2c1[_0x6bff55('0x1864')]['onlineForm'][_0x6bff55('0xbd7')][_0x4ad514]=_0x45f9fa,_0x5ca2c1[_0x6bff55('0x1864')][_0x6bff55('0x8c5')]['items'][_0x4ad514+0x1]=angular[_0x6bff55('0x225f')](_0x59f6c5);if(_0x5ca2c1[_0x6bff55('0x1864')][_0x6bff55('0x8c5')][_0x6bff55('0x1d63')]===_0x4ad514)_0x5ca2c1['chatWebsite']['onlineForm'][_0x6bff55('0x1d63')]++;else _0x5ca2c1[_0x6bff55('0x1864')][_0x6bff55('0x8c5')][_0x6bff55('0x1d63')]===_0x4ad514+0x1&&_0x5ca2c1['chatWebsite'][_0x6bff55('0x8c5')][_0x6bff55('0x1d63')]--;}}function _0x30a883(_0x58601a){const _0x392cc2=_0x5a6755;_0x5ca2c1[_0x392cc2('0x1864')][_0x392cc2('0x8c5')]['items'][_0x392cc2('0x1514')]({'type':_0x58601a,'cmField':null,'variable':null});}function _0x1e4a58(_0x2370d7){const _0x397581=_0x5a6755,_0x2af9db=_0x2b871a['confirm']()[_0x397581('0xcdc')](_0x397581('0xeab'))[_0x397581('0x2077')](_0x397581('0x7fb'))['ariaLabel'](_0x397581('0x1c95'))['ok']('Ok')['cancel'](_0x397581('0x497'));_0x2b871a[_0x397581('0x1f80')](_0x2af9db)[_0x397581('0x1166')](function(){const _0x4e363b=_0x397581;_0x5ca2c1['chatWebsite']['onlineForm'][_0x4e363b('0x1d63')]===_0x2370d7&&(_0x5ca2c1[_0x4e363b('0x1864')][_0x4e363b('0x8c5')]['fromKey']=null),_0x5ca2c1[_0x4e363b('0x1864')][_0x4e363b('0x8c5')][_0x4e363b('0xbd7')][_0x4e363b('0x57b')](_0x2370d7,0x1),!_0x5ca2c1[_0x4e363b('0x1864')][_0x4e363b('0x8c5')][_0x4e363b('0xbd7')][_0x4e363b('0x264b')]&&(_0x5ca2c1[_0x4e363b('0x1864')][_0x4e363b('0x8c5')][_0x4e363b('0x1d63')]=null);});}}const _0x2b05a9=_0x4eb939;_0x27e39f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x1d2e')];function _0x27e39f(_0x2c3d09,_0x5c5ebe){const _0x3bd25a=_0x36e6f4,_0x1d5d69=this,_0x5666ea=0x8,_0x458af1=_0x5666ea*0x400*0x400;_0x1d5d69['chatWebsite']={},_0x1d5d69[_0x3bd25a('0x243c')],_0x1d5d69[_0x3bd25a('0xd67')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x458af1,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x1d5d69[_0x3bd25a('0xe57')]={'flow':{}},_0x1d5d69['dropping']=![],_0x1d5d69[_0x3bd25a('0xd20')]=_0x452a34,_0x1d5d69[_0x3bd25a('0x1d40')]=_0x73144a,_0x1d5d69['fileSuccess']=_0x1a5ebb,_0x1d5d69[_0x3bd25a('0x24d5')]=_0x4d1330;function _0x4d1330(_0x45a27f,_0x45e083){const _0x219709=_0x3bd25a;_0x1d5d69[_0x219709('0x1864')]=angular[_0x219709('0x225f')](_0x45a27f),_0x1d5d69[_0x219709('0x243c')]=typeof _0x45e083!==_0x219709('0x1048')?_0x45e083:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1d5d69[_0x219709('0xd67')][_0x219709('0x21cc')]='/api/chat/websites/:id/customer_avatar'[_0x219709('0xf3')](_0x219709('0x1585'),_0x1d5d69[_0x219709('0x1864')]['id']),_0x1d5d69['chatWebsite']['images']=[];}function _0x452a34(_0x29bc0a){const _0x27d43e=_0x3bd25a,_0x310608=[_0x27d43e('0xccc'),_0x27d43e('0x1cd0')];if(!_0x2cfb05()[_0x27d43e('0x1257')](_0x310608,_0x29bc0a['getExtension']()))return _0x5c5ebe[_0x27d43e('0xfc9')]({'title':_0x27d43e('0x27fb')+_0x29bc0a[_0x27d43e('0x26a5')](),'msg':_0x27d43e('0x1020')+_0x310608[_0x27d43e('0x45a')]()}),![];if(_0x29bc0a[_0x27d43e('0x2340')]>_0x458af1)return _0x5c5ebe['error']({'title':'File\x20too\x20big','msg':_0x27d43e('0x12c0')+_0x5666ea+'MB'}),![];const _0xadf55e={'id':_0x29bc0a[_0x27d43e('0x20f4')],'file':_0x29bc0a,'type':_0x27d43e('0x32f')};return _0x1d5d69[_0x27d43e('0x1864')][_0x27d43e('0x1b17')][_0x27d43e('0x2450')](_0xadf55e),!![];}function _0x73144a(){const _0x49f103=_0x3bd25a;_0x1d5d69[_0x49f103('0xe57')]['flow'][_0x49f103('0x1ca3')]['headers']={'X-Requested-With':'XMLHttpRequest','Authorization':_0x49f103('0x24d4')+_0x2c3d09[_0x49f103('0xd83')](_0x49f103('0x10b6'))},_0x1d5d69[_0x49f103('0xe57')][_0x49f103('0x13d1')][_0x49f103('0x1d40')]();}function _0x1a5ebb(_0x18b0cc){const _0x376f17=_0x3bd25a;angular[_0x376f17('0x2782')](_0x1d5d69['chatWebsite'][_0x376f17('0x1b17')],function(_0x283d0a){const _0x2d78ce=_0x376f17;if(_0x283d0a['id']===_0x18b0cc['uniqueIdentifier']){const _0x237e53=new FileReader();_0x237e53[_0x2d78ce('0x2030')](_0x283d0a[_0x2d78ce('0x6bd')][_0x2d78ce('0x6bd')]),_0x237e53['onload']=function(_0x4e84af){const _0x3291bb=_0x2d78ce;_0x283d0a[_0x3291bb('0xcac')]=_0x4e84af[_0x3291bb('0x21cc')][_0x3291bb('0x15b5')];},_0x283d0a[_0x2d78ce('0x1345')]='image';}});}}const _0x46c66a=_0x27e39f,_0xbfcb18=_0x2734b2['p']+'src/js/modules/main/apps/dashboards/views/general/agent/interaction/agent.general.interaction.dialog.html/agent.general.interaction.dialog.html';_0xbd4339[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),'$state','$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0xbd4339(_0x71ae24,_0x104915,_0x3f7348,_0x4bcd1d,_0xa58523,_0x1390c6,_0x4e96b0,_0x3c315e,_0x2150d2,_0x4632a2,_0x304e5a){const _0x23f6f9=_0x36e6f4,_0x623822=this;_0x623822[_0x23f6f9('0x98')]=_0x304e5a[_0x23f6f9('0x26cd')](),_0x623822[_0x23f6f9('0x1864')]={},_0x623822['chatWebsiteInteractions']={'count':0x0,'rows':[]},_0x623822[_0x23f6f9('0x28b1')]=[],_0x623822[_0x23f6f9('0x243c')],_0x623822['query']={'read':'null','closed':'null','sort':_0x23f6f9('0x2537'),'includeAll':_0x23f6f9('0xf3b'),'limit':0xa,'page':0x1},_0x623822[_0x23f6f9('0x24d5')]=_0x271e7e,_0x623822[_0x23f6f9('0x8a2')]=_0x41c587,_0x623822[_0x23f6f9('0x187f')]=_0x2442b5,_0x623822[_0x23f6f9('0x103b')]=_0x102887,_0x623822[_0x23f6f9('0x272b')]=_0x2a8577,_0x623822[_0x23f6f9('0x1bd9')]=_0x14e247,_0x623822[_0x23f6f9('0x138b')]=_0x30767e,_0x623822[_0x23f6f9('0xe8a')]=_0x53b81d,_0x623822['deleteChatWebsiteInteraction']=_0x4d7e9f,_0x623822[_0x23f6f9('0x13df')]=_0x59db96;function _0x271e7e(_0x54b1df,_0x474595){const _0x55ddc5=_0x23f6f9;_0x623822[_0x55ddc5('0x1864')]=_0x54b1df,_0x623822[_0x55ddc5('0x243c')]=typeof _0x474595!=='undefined'?_0x474595:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x623822[_0x55ddc5('0x2218')][_0x55ddc5('0x1e02')]=_0x623822[_0x55ddc5('0x1864')]['id'],_0x623822[_0x55ddc5('0x1291')]={'fields':_0x505f04()},_0x333aaf();}function _0x333aaf(){const _0x481748=_0x23f6f9;return _0x4632a2['tag'][_0x481748('0xd83')]()['$promise']['then'](function(_0x48bca7){const _0x526947=_0x481748;_0x623822[_0x526947('0xb38')]=_0x48bca7||{'count':0x0,'rows':[]};})[_0x481748('0x1166')](function(){const _0x34cfd4=_0x481748;_0x623822[_0x34cfd4('0x6cb')]=_0x2c97cc();});}function _0x2c97cc(){const _0x35fe42=_0x23f6f9;return[{'name':_0x35fe42('0x2567'),'key':_0x35fe42('0x262'),'type':'date','label':'DASHBOARDS.SELECT_DATE'},{'name':_0x35fe42('0x116c'),'key':_0x35fe42('0x123'),'type':_0x35fe42('0x88a'),'label':_0x35fe42('0x379'),'customOptions':[{'value':0x0,'translate':_0x35fe42('0x2c8')},{'value':0x1,'translate':_0x35fe42('0x1057')},{'value':null,'translate':_0x35fe42('0x2150')}]},{'name':_0x35fe42('0x28f6'),'key':_0x35fe42('0xa5b'),'type':_0x35fe42('0x88a'),'label':_0x35fe42('0xe32'),'customOptions':[{'value':0x0,'translate':_0x35fe42('0xdeb')},{'value':0x1,'translate':'DASHBOARDS.CLOSED'},{'value':null,'translate':_0x35fe42('0x2150')}]},{'name':_0x35fe42('0x89b'),'key':_0x35fe42('0x122a'),'type':'select','label':_0x35fe42('0x1db1'),'customOptions':[{'value':_0x35fe42('0x15d7'),'translate':_0x35fe42('0x216b')},{'value':undefined,'translate':_0x35fe42('0x2150')}]},{'name':_0x35fe42('0x1b35'),'key':'tag','type':'multiselect','label':'DASHBOARDS.SELECT_TAG','options':_0x623822['tags'][_0x35fe42('0x269a')],'placeholder':_0x35fe42('0x2223')}];}function _0x505f04(){const _0x2cac30=_0x23f6f9;return[{'name':'Id','column':'id','type':_0x2cac30('0xc45')},{'name':'Contact','column':_0x2cac30('0x21a4'),'type':'autocomplete','options':{'searchFields':['firstName',_0x2cac30('0xeb0'),_0x2cac30('0x66f')],'route':{'model':'cmContact','action':_0x2cac30('0xd83'),'params':{'fields':'id,firstName,lastName,email','Contact':_0x2cac30('0x145b'),'nolimit':!![]}},'extraOperators':[_0x2cac30('0x2836')],'excludedOperators':[_0x2cac30('0x2646')]}},{'name':'Subject','column':_0x2cac30('0x210d'),'type':'text','options':{'excludedOperators':[_0x2cac30('0x110'),_0x2cac30('0x2646')]}},{'name':'Body','column':_0x2cac30('0x26d2'),'type':_0x2cac30('0x1640'),'options':{'excludedOperators':[_0x2cac30('0x110'),_0x2cac30('0x2646')]}},{'name':'Status','column':_0x2cac30('0xa5b'),'type':_0x2cac30('0x88a'),'values':[{'id':0x0,'translate':_0x2cac30('0xdeb')},{'id':0x1,'translate':_0x2cac30('0x58f')}],'options':{'excludedOperators':[_0x2cac30('0x2646')]}},{'name':_0x2cac30('0x89b'),'column':_0x2cac30('0x1a6f'),'type':_0x2cac30('0x1a01'),'options':{'table':'i','route':{'model':'user','action':'get','params':{'role':_0x2cac30('0x1eff'),'fields':_0x2cac30('0xce1'),'nolimit':!![]}},'searchFields':[_0x2cac30('0x6e1'),_0x2cac30('0x4f0')],'extraOperators':[_0x2cac30('0x2836')],'excludedOperators':[_0x2cac30('0x2646')]}},{'name':_0x2cac30('0x21c2'),'column':_0x2cac30('0x1b35'),'type':_0x2cac30('0x2162'),'options':{'route':{'model':'tag','action':_0x2cac30('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':[_0x2cac30('0x18d')]}},{'name':_0x2cac30('0x2567'),'column':_0x2cac30('0x262'),'type':_0x2cac30('0x1643'),'options':{'excludedOperators':['$ne']}},{'name':'Read','column':_0x2cac30('0x723'),'type':_0x2cac30('0x88a'),'values':[{'id':0x1,'translate':_0x2cac30('0x1057')},{'id':0x0,'translate':_0x2cac30('0x2c8')}],'options':{'excludedOperators':[_0x2cac30('0x2646')]}}];}function _0x30767e(){const _0x4e8fa6=_0x23f6f9;_0x4e96b0[_0x4e8fa6('0x1f80')]({'controller':_0x4e8fa6('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0x4e8fa6('0x1194')](_0x3c315e['body']),'clickOutsideToClose':![],'locals':{'fields':_0x623822[_0x4e8fa6('0x1291')]['fields'],'color':undefined,'storagePath':_0x4e8fa6('0x26ad')},'fullscreen':!![]})[_0x4e8fa6('0x1166')](function(_0x5a3016){const _0x704bf5=_0x4e8fa6;_0x623822[_0x704bf5('0x2218')][_0x704bf5('0xe07')]=_0x5a3016===![]?undefined:_0x5a3016;if(_0x623822[_0x704bf5('0x2218')][_0x704bf5('0xe07')])_0x2a8577();else _0x5a3016===![]&&_0x2a8577();})[_0x4e8fa6('0x1a80')](function(_0x138b17){const _0x59d4d9=_0x4e8fa6;_0x2150d2[_0x59d4d9('0xfc9')]({'title':_0x59d4d9('0x2272'),'msg':_0x138b17[_0x59d4d9('0x25f4')]?JSON[_0x59d4d9('0xbac')](_0x138b17['data']['message']):_0x138b17[_0x59d4d9('0x1586')]()});});}function _0x2442b5(_0x1c6c16,_0x434092,_0x10c820){const _0x7a18c2=_0x23f6f9;return _0x4632a2[_0x7a18c2('0x1162')][_0x7a18c2('0x2ad')]({'id':_0x1c6c16['id'],'exists':!![],'attachments':_0x10c820})[_0x7a18c2('0xa44')][_0x7a18c2('0x1166')](function(_0x1b0b8a){const _0x3dac9a=_0x7a18c2,_0x1fa89b=[_0x1b0b8a[_0x3dac9a('0x20ed')]];let _0x5e9a54='interaction'+_0x1c6c16['id'];const _0x5e360a=new Blob(_0x1fa89b,{'type':_0x1b0b8a[_0x3dac9a('0x1345')]});_0x5e9a54='chat-interaction'+_0x1c6c16['id']+_0x3dac9a('0x806');const _0x554cf9=window['document']['createElement']('a');_0x554cf9[_0x3dac9a('0xffd')]('href',URL[_0x3dac9a('0x215a')](_0x5e360a)),_0x554cf9[_0x3dac9a('0xffd')](_0x3dac9a('0x2ad'),_0x5e9a54),document[_0x3dac9a('0x8d2')][_0x3dac9a('0x21a')](_0x554cf9),_0x554cf9[_0x3dac9a('0x3b4')]();})[_0x7a18c2('0x1a80')](function(_0x4de9f6){const _0x59cb1a=_0x7a18c2;if(_0x4de9f6[_0x59cb1a('0x25f4')]&&_0x4de9f6[_0x59cb1a('0x25f4')][_0x59cb1a('0x61a')]&&_0x4de9f6[_0x59cb1a('0x25f4')][_0x59cb1a('0x61a')]['length'])for(let _0x1ed068=0x0;_0x1ed068<_0x4de9f6[_0x59cb1a('0x25f4')][_0x59cb1a('0x61a')][_0x59cb1a('0x264b')];_0x1ed068+=0x1){_0x2150d2['error']({'title':_0x4de9f6[_0x59cb1a('0x25f4')][_0x59cb1a('0x61a')][_0x1ed068][_0x59cb1a('0x1345')],'msg':_0x4de9f6['data'][_0x59cb1a('0x61a')][_0x1ed068][_0x59cb1a('0x1e70')]});}else _0x2150d2[_0x59cb1a('0xfc9')]({'title':_0x4de9f6[_0x59cb1a('0x52d')]?_0x59cb1a('0x1e21')+_0x4de9f6[_0x59cb1a('0x52d')]+'\x20-\x20'+_0x4de9f6[_0x59cb1a('0xe1b')]:_0x59cb1a('0x183b'),'msg':_0x4de9f6[_0x59cb1a('0x25f4')]?JSON[_0x59cb1a('0xbac')](_0x4de9f6['data'][_0x59cb1a('0x1e70')]):_0x4de9f6[_0x59cb1a('0x1586')]()});});}function _0x41c587(_0x20544d,_0x229ffc){const _0xc24768=_0x23f6f9,_0x691f3d=_0x4e96b0['confirm']()[_0xc24768('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20interaction?')[_0xc24768('0xf3c')](_0xc24768('0x12b5')+(_0x20544d[_0xc24768('0x4f0')]||_0x20544d['id']&&_0x2cfb05()['upperFirst'](_0xc24768('0x2625'))+_0x20544d['id']||_0xc24768('0x25e6'))+''+'\x20will\x20be\x20deleted.')[_0xc24768('0x8e8')]('delete\x20interaction')[_0xc24768('0x203b')](_0x229ffc)['ok']('OK')['cancel'](_0xc24768('0x2d3'));_0x4e96b0[_0xc24768('0x1f80')](_0x691f3d)[_0xc24768('0x1166')](function(){_0x4d7e9f(_0x20544d);},function(){const _0x20e016=_0xc24768;console['log'](_0x20e016('0x2d3'));});}function _0x102887(_0x20f134){const _0x15bb25=_0x23f6f9;_0x623822['chatWebsiteInteractions']=_0x20f134||{'count':0x0,'rows':[]};for(let _0x481349=0x0;_0x481349<_0x623822[_0x15bb25('0x92a')][_0x15bb25('0x269a')][_0x15bb25('0x264b')];_0x481349+=0x1){const _0x2f6112=_0x623822[_0x15bb25('0x92a')][_0x15bb25('0x269a')][_0x481349];_0x208081(_0x2f6112),_0x2f6112[_0x15bb25('0x121b')][_0x15bb25('0x4f0')]=_0x4305db(_0x2f6112);}}function _0x2a8577(){const _0x4d76ba=_0x23f6f9;_0x623822[_0x4d76ba('0x2218')]['offset']=(_0x623822[_0x4d76ba('0x2218')][_0x4d76ba('0x1a43')]-0x1)*_0x623822[_0x4d76ba('0x2218')][_0x4d76ba('0x163f')],_0x623822[_0x4d76ba('0x1f48')]=_0x4632a2['chatInteraction'][_0x4d76ba('0xd83')](_0x623822[_0x4d76ba('0x2218')],_0x102887)[_0x4d76ba('0xa44')];}function _0x14e247(_0x523ad8,_0x28ca59){const _0x173c2d=_0x23f6f9;_0x4e96b0[_0x173c2d('0x1f80')]({'controller':_0x173c2d('0x19ad'),'controllerAs':'vm','templateUrl':_0xbfcb18,'parent':angular[_0x173c2d('0x1194')](_0x3c315e[_0x173c2d('0x8d2')]),'targetEvent':_0x523ad8,'clickOutsideToClose':!![],'onShowing':function(_0xb96ad9){const _0x478292=_0x173c2d;_0xb96ad9['vm'][_0x478292('0x24d5')]({'id':0x1,'channel':'chat','interaction':_0x28ca59,'spy':!![]},_0x104915[_0x478292('0x23ac')]['vm'][_0x478292('0xf8a')]);}});}function _0x4d7e9f(_0x4bb0d5){const _0x3aed43=_0x23f6f9;_0x4632a2[_0x3aed43('0x1162')][_0x3aed43('0x906')]({'id':_0x4bb0d5['id']})[_0x3aed43('0xa44')][_0x3aed43('0x1166')](function(){const _0x21c8e4=_0x3aed43;_0x2cfb05()[_0x21c8e4('0x127f')](_0x623822['chatWebsiteInteractions']['rows'],{'id':_0x4bb0d5['id']}),_0x623822['chatWebsiteInteractions']['count']-=0x1,!_0x623822[_0x21c8e4('0x92a')][_0x21c8e4('0x269a')][_0x21c8e4('0x264b')]&&_0x2a8577(),_0x2150d2[_0x21c8e4('0x103b')]({'title':_0x21c8e4('0x2003'),'msg':_0x4bb0d5[_0x21c8e4('0x4f0')]?_0x4bb0d5[_0x21c8e4('0x4f0')]+_0x21c8e4('0x7cd'):''});})['catch'](function(_0x1db775){const _0x3eb0b1=_0x3aed43;if(_0x1db775['data']&&_0x1db775[_0x3eb0b1('0x25f4')][_0x3eb0b1('0x61a')]&&_0x1db775[_0x3eb0b1('0x25f4')][_0x3eb0b1('0x61a')]['length']){_0x623822[_0x3eb0b1('0x61a')]=_0x1db775['data'][_0x3eb0b1('0x61a')]||[{'message':_0x1db775['toString'](),'type':_0x3eb0b1('0x8b8')}];for(let _0x233477=0x0;_0x233477<_0x1db775['data'][_0x3eb0b1('0x61a')][_0x3eb0b1('0x264b')];_0x233477++){_0x2150d2[_0x3eb0b1('0xfc9')]({'title':_0x1db775[_0x3eb0b1('0x25f4')]['errors'][_0x233477][_0x3eb0b1('0x1345')],'msg':_0x1db775[_0x3eb0b1('0x25f4')]['errors'][_0x233477][_0x3eb0b1('0x1e70')]});}}else _0x2150d2[_0x3eb0b1('0xfc9')]({'title':_0x1db775[_0x3eb0b1('0x52d')]?'API:'+_0x1db775[_0x3eb0b1('0x52d')]+_0x3eb0b1('0x11e1')+_0x1db775[_0x3eb0b1('0xe1b')]:'SYSTEM:GETchatWebsite','msg':_0x1db775[_0x3eb0b1('0x25f4')]?JSON[_0x3eb0b1('0xbac')](_0x1db775[_0x3eb0b1('0x25f4')][_0x3eb0b1('0x1e70')]):_0x1db775[_0x3eb0b1('0x1e70')]||_0x1db775['toString']()});});}function _0x53b81d(){const _0x1e9ac7=_0x23f6f9,_0x353fd2=angular[_0x1e9ac7('0x225f')](_0x623822[_0x1e9ac7('0x28b1')]);return _0x623822['selectedChatWebsiteInteractions']=[],_0x353fd2;}function _0x59db96(_0x5b26d3){const _0x3918f4=_0x23f6f9,_0xacee4=_0x4e96b0[_0x3918f4('0x1d26')]()[_0x3918f4('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20interactions?')[_0x3918f4('0xf3c')](_0x3918f4('0x12b5')+_0x623822[_0x3918f4('0x28b1')][_0x3918f4('0x264b')]+_0x3918f4('0x196d')+_0x3918f4('0x3f3'))['ariaLabel'](_0x3918f4('0x1623'))[_0x3918f4('0x203b')](_0x5b26d3)['ok']('OK')[_0x3918f4('0x3f')]('CANCEL');_0x4e96b0[_0x3918f4('0x1f80')](_0xacee4)[_0x3918f4('0x1166')](function(){const _0x410a2f=_0x3918f4;_0x623822['selectedChatWebsiteInteractions'][_0x410a2f('0x2782')](function(_0x33fe10){_0x4d7e9f(_0x33fe10);}),_0x623822['selectedChatWebsiteInteractions']=[];});}function _0x208081(_0x65f521){const _0x238efd=_0x23f6f9;_0x65f521['Contact']?_0x65f521[_0x238efd('0x15cf')]=(_0x65f521[_0x238efd('0x21a4')][_0x238efd('0x18cb')]||'')+'\x20'+(_0x65f521['Contact'][_0x238efd('0xeb0')]||''):_0x65f521[_0x238efd('0x15cf')]=_0xa58523[_0x238efd('0x25cc')](_0x238efd('0x148c'));}function _0x4305db(_0x3aae0f){const _0x3ee99e=_0x23f6f9;if(_0x3aae0f['UserId'])return _0x3aae0f[_0x3ee99e('0x122a')]===_0x623822['currentUser']['id']?_0xa58523[_0x3ee99e('0x25cc')](_0x3ee99e('0x15ae')):_0x3aae0f[_0x3ee99e('0x121b')][_0x3ee99e('0x6e1')]+'\x20<'+_0x3aae0f[_0x3ee99e('0x121b')][_0x3ee99e('0x1eef')]+'>';return _0xa58523[_0x3ee99e('0x25cc')](_0x3ee99e('0x216b'));}let _0x860c9b=!![],_0x6991fd=0x1;_0x104915[_0x23f6f9('0xe83')]('vm_dc.query.filter',function(_0x398e17,_0x4586a6){const _0x2fac3b=_0x23f6f9;_0x860c9b?_0x1390c6(function(){_0x860c9b=![];}):(!_0x4586a6&&(_0x6991fd=_0x623822[_0x2fac3b('0x2218')][_0x2fac3b('0x1a43')]),_0x398e17!==_0x4586a6&&(_0x623822[_0x2fac3b('0x2218')][_0x2fac3b('0x1a43')]=0x1),!_0x398e17&&(_0x623822[_0x2fac3b('0x2218')][_0x2fac3b('0x1a43')]=_0x6991fd),_0x2a8577());});}const _0xffa32b=_0xbd4339;_0x28f8af['$inject']=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x1d2e')];function _0x28f8af(_0xbba951,_0x2983f3){const _0x5ed77f=_0x36e6f4,_0x5da27e=this,_0x18a8d0=0x8,_0x24f188=_0x18a8d0*0x400*0x400;_0x5da27e[_0x5ed77f('0x1864')]={},_0x5da27e['crudPermissions'],_0x5da27e['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x24f188,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x5da27e[_0x5ed77f('0xe57')]={'flow':{}},_0x5da27e[_0x5ed77f('0x1a5c')]=![],_0x5da27e[_0x5ed77f('0xd20')]=_0x385ad3,_0x5da27e[_0x5ed77f('0x1d40')]=_0x53e1db,_0x5da27e[_0x5ed77f('0x1dea')]=_0x520954,_0x5da27e[_0x5ed77f('0x24d5')]=_0x203701;function _0x203701(_0x11b56d,_0x456ab1){const _0x4e211b=_0x5ed77f;_0x5da27e[_0x4e211b('0x1864')]=angular['copy'](_0x11b56d),_0x5da27e[_0x4e211b('0x243c')]=typeof _0x456ab1!==_0x4e211b('0x1048')?_0x456ab1:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x5da27e[_0x4e211b('0xd67')][_0x4e211b('0x21cc')]=_0x4e211b('0x708')[_0x4e211b('0xf3')](_0x4e211b('0x1585'),_0x5da27e[_0x4e211b('0x1864')]['id']),_0x5da27e[_0x4e211b('0x1864')][_0x4e211b('0x1b17')]=[];}function _0x385ad3(_0x523c74){const _0x2c9bff=_0x5ed77f,_0x31ee01=[_0x2c9bff('0xccc'),_0x2c9bff('0x1cd0')];if(!_0x2cfb05()[_0x2c9bff('0x1257')](_0x31ee01,_0x523c74[_0x2c9bff('0x26a5')]()))return _0x2983f3[_0x2c9bff('0xfc9')]({'title':_0x2c9bff('0x27fb')+_0x523c74['getExtension'](),'msg':_0x2c9bff('0x1020')+_0x31ee01[_0x2c9bff('0x45a')]()}),![];if(_0x523c74[_0x2c9bff('0x2340')]>_0x24f188)return _0x2983f3[_0x2c9bff('0xfc9')]({'title':_0x2c9bff('0x11e6'),'msg':_0x2c9bff('0x12c0')+_0x18a8d0+'MB'}),![];const _0x5c712d={'id':_0x523c74['uniqueIdentifier'],'file':_0x523c74,'type':_0x2c9bff('0x32f')};return _0x5da27e[_0x2c9bff('0x1864')][_0x2c9bff('0x1b17')][_0x2c9bff('0x2450')](_0x5c712d),!![];}function _0x53e1db(){const _0x34dd11=_0x5ed77f;_0x5da27e['ngFlow'][_0x34dd11('0x13d1')][_0x34dd11('0x1ca3')][_0x34dd11('0x5fb')]={'X-Requested-With':_0x34dd11('0x1bc1'),'Authorization':_0x34dd11('0x24d4')+_0xbba951[_0x34dd11('0xd83')]('motion.token')},_0x5da27e['ngFlow'][_0x34dd11('0x13d1')][_0x34dd11('0x1d40')]();}function _0x520954(_0x1a8889){const _0x29a66f=_0x5ed77f;angular[_0x29a66f('0x2782')](_0x5da27e[_0x29a66f('0x1864')]['images'],function(_0x5c09c4){const _0x4d225e=_0x29a66f;if(_0x5c09c4['id']===_0x1a8889[_0x4d225e('0x20f4')]){const _0x1ebd1e=new FileReader();_0x1ebd1e[_0x4d225e('0x2030')](_0x5c09c4[_0x4d225e('0x6bd')]['file']),_0x1ebd1e[_0x4d225e('0x15d4')]=function(_0x1e7a56){const _0xb5db7b=_0x4d225e;_0x5c09c4[_0xb5db7b('0xcac')]=_0x1e7a56['target'][_0xb5db7b('0x15b5')];},_0x5c09c4['type']=_0x4d225e('0x19f5');}});}}const _0xa3c2ec=_0x28f8af,_0x280bfe=_0x2734b2['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/offlineMessages/dialog.html/dialog.html';_0x23285c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$document','toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x23285c(_0x4ed74f,_0x2db59f,_0x4e48c4,_0x22de7c,_0x478fc4,_0x4eb0ca,_0x40965a,_0x1dd13b,_0x267db7,_0x1833ad,_0x23ead4){const _0x2908af=_0x36e6f4,_0x51c956=this;_0x51c956[_0x2908af('0x98')]=_0x23ead4[_0x2908af('0x26cd')](),_0x51c956[_0x2908af('0x1864')]={},_0x51c956['chatWebsiteOfflineMessages']={'count':0x0,'rows':[]},_0x51c956[_0x2908af('0x165d')]=[],_0x51c956[_0x2908af('0x243c')],_0x51c956['query']={'fields':_0x2908af('0x20d9'),'sort':_0x2908af('0x2537'),'limit':0xa,'page':0x1},_0x51c956[_0x2908af('0x24d5')]=_0x6bfb1d,_0x51c956['deleteConfirm']=_0x5b6e02,_0x51c956['success']=_0x9901f5,_0x51c956[_0x2908af('0x1905')]=_0x4cc2d4,_0x51c956[_0x2908af('0x181e')]=_0x48ffb8,_0x51c956['showOfflineMessageChatWebsiteOfflineMessage']=_0x214f51,_0x51c956[_0x2908af('0x16e4')]=_0x5abbd8,_0x51c956[_0x2908af('0x226a')]=_0x1f6909,_0x51c956[_0x2908af('0x129f')]=_0x1dbabc;function _0x6bfb1d(_0x554dd8,_0x251888){const _0x1c7800=_0x2908af;_0x51c956[_0x1c7800('0x1864')]=_0x554dd8,_0x51c956[_0x1c7800('0x243c')]=typeof _0x251888!=='undefined'?_0x251888:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x51c956[_0x1c7800('0x2218')]['id']=_0x51c956[_0x1c7800('0x1864')]['id'],_0x4cc2d4();}function _0x5b6e02(_0x22264f,_0x3d87cd){const _0x3846d6=_0x2908af,_0x41ffbc=_0x40965a['confirm']()[_0x3846d6('0xcdc')](_0x3846d6('0xb58'))[_0x3846d6('0xf3c')](''+(_0x22264f[_0x3846d6('0x4f0')]||_0x22264f['id']&&_0x2cfb05()[_0x3846d6('0x114b')]('offlineMessage\x20#')+_0x22264f['id']||'offlineMessage')+_0x3846d6('0xace')+_0x3846d6('0x3f3'))['ariaLabel']('delete\x20offlineMessage')[_0x3846d6('0x203b')](_0x3d87cd)['ok']('OK')[_0x3846d6('0x3f')](_0x3846d6('0x2d3'));_0x40965a[_0x3846d6('0x1f80')](_0x41ffbc)[_0x3846d6('0x1166')](function(){_0x1f6909(_0x22264f);},function(){console['log']('CANCEL');});}function _0x9901f5(_0x4b68a4){const _0x5101a6=_0x2908af;_0x51c956[_0x5101a6('0x11c9')]=_0x4b68a4||{'count':0x0,'rows':[]};}function _0x4cc2d4(){const _0x3b8abd=_0x2908af;_0x51c956['query'][_0x3b8abd('0x1098')]=(_0x51c956[_0x3b8abd('0x2218')][_0x3b8abd('0x1a43')]-0x1)*_0x51c956['query'][_0x3b8abd('0x163f')],_0x51c956[_0x3b8abd('0x1f48')]=_0x1833ad[_0x3b8abd('0x1864')][_0x3b8abd('0x5b6')](_0x51c956['query'],_0x9901f5)[_0x3b8abd('0xa44')];}function _0x48ffb8(_0x25d3bd,_0x11dadc){const _0x4abdaf=_0x2908af;_0x40965a['show']({'controller':_0x4abdaf('0xfa3'),'controllerAs':'vm','templateUrl':_0x280bfe,'parent':angular[_0x4abdaf('0x1194')](_0x1dd13b[_0x4abdaf('0x8d2')]),'targetEvent':_0x25d3bd,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x51c956[_0x4abdaf('0x1864')],'offlineMessage':_0x11dadc,'offlineMessages':_0x51c956['chatWebsiteOfflineMessages'][_0x4abdaf('0x269a')],'license':null,'setting':null,'crudPermissions':_0x51c956[_0x4abdaf('0x243c')]}});}function _0x214f51(_0x2d1e56,_0x476ed8){const _0x2452b8=_0x2908af;_0x40965a['show']({'controller':'ShowOfflineMessageOfflineMessageDialogController','controllerAs':'vm','templateUrl':_0x280bfe,'parent':angular[_0x2452b8('0x1194')](_0x1dd13b[_0x2452b8('0x8d2')]),'targetEvent':_0x2d1e56,'clickOutsideToClose':!![],'resolve':{'message':[_0x2452b8('0x1fbc'),function(_0x29b639){const _0x59b409=_0x2452b8;return _0x29b639[_0x59b409('0x18af')](_0x59b409('0x1c61'),{'fields':'id,body','id':_0x476ed8['id']});}]}});}function _0x1f6909(_0x27098c){const _0x11d928=_0x2908af;_0x1833ad['chatOfflineMessage'][_0x11d928('0x906')]({'id':_0x27098c['id']})[_0x11d928('0xa44')]['then'](function(){const _0x4a694c=_0x11d928;_0x2cfb05()['remove'](_0x51c956['chatWebsiteOfflineMessages'][_0x4a694c('0x269a')],{'id':_0x27098c['id']}),_0x51c956[_0x4a694c('0x11c9')][_0x4a694c('0x240f')]-=0x1,!_0x51c956['chatWebsiteOfflineMessages']['rows'][_0x4a694c('0x264b')]&&_0x4cc2d4(),_0x267db7['success']({'title':_0x4a694c('0x3c1'),'msg':_0x27098c[_0x4a694c('0x4f0')]?_0x27098c[_0x4a694c('0x4f0')]+_0x4a694c('0x7cd'):''});})['catch'](function(_0x56cdb4){const _0x5e962c=_0x11d928;if(_0x56cdb4['data']&&_0x56cdb4[_0x5e962c('0x25f4')][_0x5e962c('0x61a')]&&_0x56cdb4[_0x5e962c('0x25f4')][_0x5e962c('0x61a')][_0x5e962c('0x264b')]){_0x51c956[_0x5e962c('0x61a')]=_0x56cdb4[_0x5e962c('0x25f4')][_0x5e962c('0x61a')]||[{'message':_0x56cdb4[_0x5e962c('0x1586')](),'type':_0x5e962c('0x8b8')}];for(let _0x3e08f5=0x0;_0x3e08f5<_0x56cdb4[_0x5e962c('0x25f4')]['errors']['length'];_0x3e08f5++){_0x267db7[_0x5e962c('0xfc9')]({'title':_0x56cdb4['data'][_0x5e962c('0x61a')][_0x3e08f5]['type'],'msg':_0x56cdb4[_0x5e962c('0x25f4')][_0x5e962c('0x61a')][_0x3e08f5][_0x5e962c('0x1e70')]});}}else _0x267db7[_0x5e962c('0xfc9')]({'title':_0x56cdb4[_0x5e962c('0x52d')]?_0x5e962c('0x1e21')+_0x56cdb4[_0x5e962c('0x52d')]+_0x5e962c('0x11e1')+_0x56cdb4[_0x5e962c('0xe1b')]:'SYSTEM:GETchatWebsite','msg':_0x56cdb4[_0x5e962c('0x25f4')]?JSON[_0x5e962c('0xbac')](_0x56cdb4[_0x5e962c('0x25f4')][_0x5e962c('0x1e70')]):_0x56cdb4[_0x5e962c('0x1e70')]||_0x56cdb4['toString']()});});}function _0x5abbd8(){const _0x445806=_0x2908af,_0x1d0354=angular['copy'](_0x51c956[_0x445806('0x165d')]);return _0x51c956['selectedChatWebsiteOfflineMessages']=[],_0x1d0354;}function _0x1dbabc(_0x2b8c14){const _0x13c35f=_0x2908af,_0x4263b8=_0x40965a[_0x13c35f('0x1d26')]()[_0x13c35f('0xcdc')](_0x13c35f('0x23f9'))[_0x13c35f('0xf3c')](_0x13c35f('0x12b5')+_0x51c956['selectedChatWebsiteOfflineMessages'][_0x13c35f('0x264b')]+_0x13c35f('0x196d')+_0x13c35f('0x3f3'))[_0x13c35f('0x8e8')](_0x13c35f('0x309'))[_0x13c35f('0x203b')](_0x2b8c14)['ok']('OK')[_0x13c35f('0x3f')](_0x13c35f('0x2d3'));_0x40965a[_0x13c35f('0x1f80')](_0x4263b8)[_0x13c35f('0x1166')](function(){const _0x3b4179=_0x13c35f;_0x51c956[_0x3b4179('0x165d')]['forEach'](function(_0x2b2327){_0x1f6909(_0x2b2327);}),_0x51c956['selectedChatWebsiteOfflineMessages']=[];});}let _0x190c1d=!![],_0x17f810=0x1;_0x2db59f[_0x2908af('0xe83')](_0x2908af('0x28b4'),function(_0xe15a9,_0x3ebe55){const _0x42dfe=_0x2908af;_0x190c1d?_0x4eb0ca(function(){_0x190c1d=![];}):(!_0x3ebe55&&(_0x17f810=_0x51c956[_0x42dfe('0x2218')][_0x42dfe('0x1a43')]),_0xe15a9!==_0x3ebe55&&(_0x51c956[_0x42dfe('0x2218')][_0x42dfe('0x1a43')]=0x1),!_0xe15a9&&(_0x51c956['query'][_0x42dfe('0x1a43')]=_0x17f810),_0x4cc2d4());});}const _0x4157d0=_0x23285c;_0x1f1a71[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1e70')];function _0x1f1a71(_0x54bbc7,_0x3d823a){const _0x555088=_0x36e6f4,_0x1d1d64=this;_0x1d1d64[_0x555088('0xcdc')]=_0x555088('0x1d56'),_0x1d1d64[_0x555088('0x1e70')]=_0x3d823a,_0x1d1d64[_0x555088('0x24a0')]=_0x3cc9e7;function _0x3cc9e7(_0xbbc9b8){const _0x116e32=_0x555088;_0x54bbc7[_0x116e32('0x1197')](_0xbbc9b8);}}const _0x59dab4=_0x1f1a71,_0x3d1a0f=_0x2734b2['p']+_0x36e6f4('0x408');_0x35ffbf['$inject']=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'Auth'];function _0x35ffbf(_0x90fd3f,_0x3adcdb,_0x45a563,_0x1c7ec0,_0x452539,_0x452185,_0x1f2198,_0x57ff5b,_0xfe87d1,_0x1454d2,_0x26a7ea){const _0x28fb77=_0x36e6f4,_0x58e47c=this;_0x58e47c['currentUser']=_0x26a7ea[_0x28fb77('0x26cd')](),_0x58e47c[_0x28fb77('0x1864')]={},_0x58e47c[_0x28fb77('0x506')]={'count':0x0,'rows':[]},_0x58e47c[_0x28fb77('0x1fb9')]=[],_0x58e47c[_0x28fb77('0x243c')],_0x58e47c[_0x28fb77('0x2218')]={'fields':_0x28fb77('0x1693'),'limit':0xa,'page':0x1},_0x58e47c[_0x28fb77('0x2736')]=_0x2cfb05()[_0x28fb77('0x155c')]([{'option':_0x28fb77('0x1f97'),'value':'\x27mouseOver\x27'},{'option':_0x28fb77('0x1861'),'value':'\x27timeout\x27'}],function(_0x1962ce){const _0x443e77=_0x28fb77;return _0x2cfb05()[_0x443e77('0xf3')](_0x1962ce[_0x443e77('0x18e0')],new RegExp('\x27','g'),'');}),_0x58e47c[_0x28fb77('0x24d5')]=_0x374682,_0x58e47c[_0x28fb77('0x8a2')]=_0x188b35,_0x58e47c[_0x28fb77('0x103b')]=_0x371749,_0x58e47c[_0x28fb77('0x1b6e')]=_0x36da2b,_0x58e47c['createOrEditChatWebsiteChatProactiveAction']=_0x127f03,_0x58e47c[_0x28fb77('0x160c')]=_0x339b43,_0x58e47c[_0x28fb77('0x1403')]=_0x296036,_0x58e47c[_0x28fb77('0x2607')]=_0xd816dd;function _0x374682(_0x5478bf,_0x16d042){const _0x4691b0=_0x28fb77;_0x58e47c['chatWebsite']=_0x5478bf,_0x58e47c['crudPermissions']=typeof _0x16d042!==_0x4691b0('0x1048')?_0x16d042:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x58e47c[_0x4691b0('0x2218')][_0x4691b0('0x1e02')]=_0x58e47c[_0x4691b0('0x1864')]['id'],_0x58e47c[_0x4691b0('0x2218')]['id']=_0x58e47c[_0x4691b0('0x1864')]['id'],_0x36da2b();}function _0x188b35(_0x247cf9,_0x5edbfd){const _0x1190a4=_0x28fb77,_0x58dd69=_0x1f2198[_0x1190a4('0x1d26')]()[_0x1190a4('0xcdc')](_0x1190a4('0x1e5c'))[_0x1190a4('0xf3c')](''+(_0x247cf9[_0x1190a4('0x4f0')]||_0x247cf9['id']&&_0x2cfb05()[_0x1190a4('0x114b')]('chatProactiveAction\x20#')+_0x247cf9['id']||'chatProactiveAction')+_0x1190a4('0xace')+'\x20will\x20be\x20deleted.')['ariaLabel']('delete\x20chatProactiveAction')[_0x1190a4('0x203b')](_0x5edbfd)['ok']('OK')[_0x1190a4('0x3f')]('CANCEL');_0x1f2198[_0x1190a4('0x1f80')](_0x58dd69)[_0x1190a4('0x1166')](function(){_0x296036(_0x247cf9);},function(){const _0x4eb68c=_0x1190a4;console[_0x4eb68c('0x455')](_0x4eb68c('0x2d3'));});}function _0x371749(_0x5cfa67){const _0x123de4=_0x28fb77;_0x58e47c[_0x123de4('0x506')]=_0x5cfa67||{'count':0x0,'rows':[]};}function _0x36da2b(){const _0x59f61a=_0x28fb77;_0x58e47c[_0x59f61a('0x2218')]['offset']=(_0x58e47c[_0x59f61a('0x2218')][_0x59f61a('0x1a43')]-0x1)*_0x58e47c[_0x59f61a('0x2218')][_0x59f61a('0x163f')],_0x58e47c[_0x59f61a('0x1f48')]=_0x1454d2['chatWebsite'][_0x59f61a('0x204c')](_0x58e47c['query'],_0x371749)[_0x59f61a('0xa44')];}function _0x127f03(_0x16fdbb,_0x35849d){const _0x4a3cf0=_0x28fb77;_0x1f2198[_0x4a3cf0('0x1f80')]({'controller':'CreateOrEditChatProactiveActionDialogController','controllerAs':'vm','templateUrl':_0x3d1a0f,'parent':angular[_0x4a3cf0('0x1194')](_0x57ff5b['body']),'targetEvent':_0x16fdbb,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x58e47c['chatWebsite'],'chatProactiveAction':_0x35849d,'proactive':_0x58e47c[_0x4a3cf0('0x506')][_0x4a3cf0('0x269a')],'license':null,'setting':null,'crudPermissions':_0x58e47c[_0x4a3cf0('0x243c')]}});}function _0x296036(_0x53c5f6){const _0x4f7bb5=_0x28fb77;_0x1454d2[_0x4f7bb5('0x1f2f')][_0x4f7bb5('0x906')]({'id':_0x53c5f6['id']})[_0x4f7bb5('0xa44')][_0x4f7bb5('0x1166')](function(){const _0x353d05=_0x4f7bb5;_0x2cfb05()[_0x353d05('0x127f')](_0x58e47c[_0x353d05('0x506')][_0x353d05('0x269a')],{'id':_0x53c5f6['id']}),_0x58e47c[_0x353d05('0x506')][_0x353d05('0x240f')]-=0x1,!_0x58e47c['chatWebsiteProactiveActions'][_0x353d05('0x269a')]['length']&&_0x36da2b(),_0xfe87d1[_0x353d05('0x103b')]({'title':_0x353d05('0x258e'),'msg':_0x53c5f6[_0x353d05('0x4f0')]?_0x53c5f6[_0x353d05('0x4f0')]+_0x353d05('0x7cd'):''});})[_0x4f7bb5('0x1a80')](function(_0x3988de){const _0x45de91=_0x4f7bb5;if(_0x3988de[_0x45de91('0x25f4')]&&_0x3988de[_0x45de91('0x25f4')]['errors']&&_0x3988de[_0x45de91('0x25f4')][_0x45de91('0x61a')][_0x45de91('0x264b')]){_0x58e47c[_0x45de91('0x61a')]=_0x3988de[_0x45de91('0x25f4')][_0x45de91('0x61a')]||[{'message':_0x3988de[_0x45de91('0x1586')](),'type':_0x45de91('0x8b8')}];for(let _0x1659b2=0x0;_0x1659b2<_0x3988de[_0x45de91('0x25f4')][_0x45de91('0x61a')]['length'];_0x1659b2++){_0xfe87d1[_0x45de91('0xfc9')]({'title':_0x3988de[_0x45de91('0x25f4')][_0x45de91('0x61a')][_0x1659b2][_0x45de91('0x1345')],'msg':_0x3988de[_0x45de91('0x25f4')][_0x45de91('0x61a')][_0x1659b2][_0x45de91('0x1e70')]});}}else _0xfe87d1['error']({'title':_0x3988de[_0x45de91('0x52d')]?_0x45de91('0x1e21')+_0x3988de[_0x45de91('0x52d')]+'\x20-\x20'+_0x3988de[_0x45de91('0xe1b')]:_0x45de91('0x8b8'),'msg':_0x3988de[_0x45de91('0x25f4')]?JSON['stringify'](_0x3988de[_0x45de91('0x25f4')][_0x45de91('0x1e70')]):_0x3988de[_0x45de91('0x1e70')]||_0x3988de[_0x45de91('0x1586')]()});});}function _0x339b43(){const _0x226bdf=_0x28fb77,_0x138afd=angular[_0x226bdf('0x225f')](_0x58e47c['selectedChatWebsiteProactiveActions']);return _0x58e47c[_0x226bdf('0x1fb9')]=[],_0x138afd;}function _0xd816dd(_0x493e6b){const _0x2bcd40=_0x28fb77,_0x4f3ad8=_0x1f2198['confirm']()['title'](_0x2bcd40('0xfe8'))[_0x2bcd40('0xf3c')](''+_0x58e47c[_0x2bcd40('0x1fb9')][_0x2bcd40('0x264b')]+_0x2bcd40('0x196d')+_0x2bcd40('0x3f3'))[_0x2bcd40('0x8e8')]('delete\x20proactive')[_0x2bcd40('0x203b')](_0x493e6b)['ok']('OK')[_0x2bcd40('0x3f')](_0x2bcd40('0x2d3'));_0x1f2198['show'](_0x4f3ad8)[_0x2bcd40('0x1166')](function(){const _0x3b59d4=_0x2bcd40;_0x58e47c[_0x3b59d4('0x1fb9')][_0x3b59d4('0x2782')](function(_0x1d40ed){_0x296036(_0x1d40ed);}),_0x58e47c['selectedChatWebsiteProactiveActions']=[];});}let _0x12d923=!![],_0x308268=0x1;_0x3adcdb[_0x28fb77('0xe83')](_0x28fb77('0x28b4'),function(_0x2d1c45,_0x2486b5){const _0x3841f1=_0x28fb77;_0x12d923?_0x452185(function(){_0x12d923=![];}):(!_0x2486b5&&(_0x308268=_0x58e47c[_0x3841f1('0x2218')][_0x3841f1('0x1a43')]),_0x2d1c45!==_0x2486b5&&(_0x58e47c['query']['page']=0x1),!_0x2d1c45&&(_0x58e47c[_0x3841f1('0x2218')]['page']=_0x308268),_0x36da2b());});}const _0x23cb97=_0x35ffbf;_0x3eb43b[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xc03'),_0x36e6f4('0x1f2f'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x3eb43b(_0x136d83,_0x42ebdf,_0xc01c62,_0x4dc2ac,_0x10c645,_0x58aa84,_0x2ae5eb,_0x290661,_0x488714,_0x2a7585,_0x4be18c,_0x38c072,_0x2685bd,_0x3963ca){const _0x536f8f=_0x36e6f4,_0xce63db=this;_0xce63db['currentUser']=_0x4be18c[_0x536f8f('0x26cd')](),_0xce63db[_0x536f8f('0x61a')]=[],_0xce63db['setting']=_0x2685bd,_0xce63db[_0x536f8f('0x5c9')]=_0x38c072,_0xce63db[_0x536f8f('0x243c')]=_0x3963ca,_0xce63db[_0x536f8f('0x128b')]={},_0xce63db['passwordPattern']=_0xce63db[_0x536f8f('0xf8a')]&&_0xce63db[_0x536f8f('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xce63db[_0x536f8f('0xcdc')]=_0x536f8f('0x4ab'),_0xce63db[_0x536f8f('0x1f2f')]=angular[_0x536f8f('0x225f')](_0x488714),_0xce63db[_0x536f8f('0xc03')]=_0x290661,_0xce63db['newChatProactiveAction']=![];!_0xce63db['chatProactiveAction']&&(_0xce63db[_0x536f8f('0x1f2f')]={'type':'mouseOver'},_0xce63db['title']=_0x536f8f('0x1953'),_0xce63db['newChatProactiveAction']=!![]);_0x42ebdf[_0x536f8f('0x23f')]['id']&&(_0xce63db[_0x536f8f('0x1f2f')][_0x536f8f('0x1e02')]=_0x42ebdf['params']['id']);_0xce63db[_0x536f8f('0x14f6')]=_0x4b9dec,_0xce63db[_0x536f8f('0x52a')]=_0x3a2332,_0xce63db[_0x536f8f('0xa20')]=_0x4f658b,_0xce63db[_0x536f8f('0x1a9c')]=_0x3f39f2,_0xce63db[_0x536f8f('0x24a0')]=_0x1081d7;function _0x4b9dec(){const _0x5cd99a=_0x536f8f;_0xce63db[_0x5cd99a('0x61a')]=[],_0x2a7585['chatProactiveAction'][_0x5cd99a('0x9cc')](_0xce63db[_0x5cd99a('0x1f2f')])['$promise'][_0x5cd99a('0x1166')](function(_0x5c2699){const _0x3f54b9=_0x5cd99a;_0xce63db['proactive'][_0x3f54b9('0x2450')](_0x5c2699[_0x3f54b9('0x2876')]()),_0x2ae5eb[_0x3f54b9('0x103b')]({'title':'ChatProactiveAction\x20properly\x20created','msg':_0xce63db[_0x3f54b9('0x1f2f')]['name']?_0xce63db['chatProactiveAction'][_0x3f54b9('0x4f0')]+_0x3f54b9('0x1eda'):''}),_0x1081d7(_0x5c2699);})[_0x5cd99a('0x1a80')](function(_0x110b9a){const _0x33f1fd=_0x5cd99a;if(_0x110b9a[_0x33f1fd('0x25f4')]&&_0x110b9a[_0x33f1fd('0x25f4')][_0x33f1fd('0x61a')]&&_0x110b9a[_0x33f1fd('0x25f4')][_0x33f1fd('0x61a')][_0x33f1fd('0x264b')]){_0xce63db[_0x33f1fd('0x61a')]=_0x110b9a[_0x33f1fd('0x25f4')]['errors']||[{'message':_0x110b9a[_0x33f1fd('0x1586')](),'type':_0x33f1fd('0x2091')}];for(let _0x1a51cf=0x0;_0x1a51cf<_0x110b9a['data'][_0x33f1fd('0x61a')][_0x33f1fd('0x264b')];_0x1a51cf+=0x1){_0x2ae5eb[_0x33f1fd('0xfc9')]({'title':_0x110b9a[_0x33f1fd('0x25f4')][_0x33f1fd('0x61a')][_0x1a51cf]['type'],'msg':_0x110b9a[_0x33f1fd('0x25f4')]['errors'][_0x1a51cf][_0x33f1fd('0x1e70')]});}}else _0x2ae5eb[_0x33f1fd('0xfc9')]({'title':_0x110b9a[_0x33f1fd('0x52d')]?_0x33f1fd('0x1e21')+_0x110b9a[_0x33f1fd('0x52d')]+_0x33f1fd('0x11e1')+_0x110b9a[_0x33f1fd('0xe1b')]:_0x33f1fd('0x2091'),'msg':_0x110b9a['data']?JSON[_0x33f1fd('0xbac')](_0x110b9a['data'][_0x33f1fd('0x1e70')]):_0x110b9a[_0x33f1fd('0x1586')]()});});}function _0x3a2332(){const _0x3c94ce=_0x536f8f;_0xce63db[_0x3c94ce('0x61a')]=[],_0x2a7585[_0x3c94ce('0x1f2f')]['update']({'id':_0xce63db[_0x3c94ce('0x1f2f')]['id']},_0xce63db[_0x3c94ce('0x1f2f')])[_0x3c94ce('0xa44')][_0x3c94ce('0x1166')](function(_0x6d0a54){const _0x21df5d=_0x3c94ce,_0x229ac2=_0x2cfb05()['find'](_0xce63db['proactive'],{'id':_0x6d0a54['id']});_0x229ac2&&_0x2cfb05()[_0x21df5d('0xcc3')](_0x229ac2,_0x2cfb05()[_0x21df5d('0x1a08')](_0x6d0a54['toJSON'](),_0x2cfb05()['keys'](_0x229ac2))),_0x2ae5eb[_0x21df5d('0x103b')]({'title':_0x21df5d('0x138a'),'msg':_0xce63db[_0x21df5d('0x1f2f')][_0x21df5d('0x4f0')]?_0xce63db[_0x21df5d('0x1f2f')][_0x21df5d('0x4f0')]+_0x21df5d('0x7d'):''}),_0x1081d7(_0x6d0a54);})[_0x3c94ce('0x1a80')](function(_0x83659f){const _0x1e65c9=_0x3c94ce;if(_0x83659f['data']&&_0x83659f[_0x1e65c9('0x25f4')][_0x1e65c9('0x61a')]&&_0x83659f[_0x1e65c9('0x25f4')][_0x1e65c9('0x61a')]['length']){_0xce63db[_0x1e65c9('0x61a')]=_0x83659f[_0x1e65c9('0x25f4')]['errors']||[{'message':_0x83659f[_0x1e65c9('0x1586')](),'type':'api.chatProactiveAction.update'}];for(let _0x3dfc26=0x0;_0x3dfc26<_0x83659f[_0x1e65c9('0x25f4')][_0x1e65c9('0x61a')][_0x1e65c9('0x264b')];_0x3dfc26++){_0x2ae5eb[_0x1e65c9('0xfc9')]({'title':_0x83659f['data'][_0x1e65c9('0x61a')][_0x3dfc26][_0x1e65c9('0x1345')],'msg':_0x83659f[_0x1e65c9('0x25f4')][_0x1e65c9('0x61a')][_0x3dfc26][_0x1e65c9('0x1e70')]});}}else _0x2ae5eb[_0x1e65c9('0xfc9')]({'title':_0x83659f[_0x1e65c9('0x52d')]?_0x1e65c9('0x1e21')+_0x83659f[_0x1e65c9('0x52d')]+_0x1e65c9('0x11e1')+_0x83659f[_0x1e65c9('0xe1b')]:_0x1e65c9('0x1b6b'),'msg':_0x83659f[_0x1e65c9('0x25f4')]?JSON[_0x1e65c9('0xbac')](_0x83659f[_0x1e65c9('0x25f4')][_0x1e65c9('0x1e70')]):_0x83659f[_0x1e65c9('0x1586')]()});});}function _0x4f658b(_0x25bf6e){const _0x30be96=_0x536f8f;_0xce63db['errors']=[];const _0x436ec7=_0x4dc2ac[_0x30be96('0x1d26')]()[_0x30be96('0xcdc')]('Are\x20you\x20sure?')[_0x30be96('0xacc')]('The\x20chatProactiveAction\x20will\x20be\x20deleted.')[_0x30be96('0x8e8')](_0x30be96('0x9a2'))['ok'](_0x30be96('0x18'))['cancel'](_0x30be96('0x497'))[_0x30be96('0x203b')](_0x25bf6e);_0x4dc2ac[_0x30be96('0x1f80')](_0x436ec7)['then'](function(){const _0x152b64=_0x30be96;_0x2a7585['chatProactiveAction'][_0x152b64('0x906')]({'id':_0xce63db[_0x152b64('0x1f2f')]['id']})['$promise'][_0x152b64('0x1166')](function(){const _0x40360f=_0x152b64;_0x2cfb05()[_0x40360f('0x127f')](_0xce63db[_0x40360f('0xc03')],{'id':_0xce63db['chatProactiveAction']['id']}),_0x2ae5eb[_0x40360f('0x103b')]({'title':'ChatProactiveAction\x20properly\x20deleted!','msg':(_0xce63db[_0x40360f('0x1f2f')][_0x40360f('0x4f0')]||_0x40360f('0x1f2f'))+_0x40360f('0x7cd')}),_0x1081d7(_0xce63db['chatProactiveAction']);})['catch'](function(_0x20ee44){const _0x14e6ef=_0x152b64;if(_0x20ee44['data']&&_0x20ee44[_0x14e6ef('0x25f4')][_0x14e6ef('0x61a')]&&_0x20ee44[_0x14e6ef('0x25f4')][_0x14e6ef('0x61a')][_0x14e6ef('0x264b')]){_0xce63db['errors']=_0x20ee44[_0x14e6ef('0x25f4')]['errors']||[{'message':_0x20ee44[_0x14e6ef('0x1586')](),'type':_0x14e6ef('0xc42')}];for(let _0x596c19=0x0;_0x596c19<_0x20ee44[_0x14e6ef('0x25f4')]['errors'][_0x14e6ef('0x264b')];_0x596c19++){_0x2ae5eb[_0x14e6ef('0xfc9')]({'title':_0x20ee44['data']['errors'][_0x596c19][_0x14e6ef('0x1345')],'msg':_0x20ee44[_0x14e6ef('0x25f4')][_0x14e6ef('0x61a')][_0x596c19][_0x14e6ef('0x1e70')]});}}else _0x2ae5eb['error']({'title':_0x20ee44['status']?_0x14e6ef('0x1e21')+_0x20ee44[_0x14e6ef('0x52d')]+_0x14e6ef('0x11e1')+_0x20ee44[_0x14e6ef('0xe1b')]:_0x14e6ef('0xc42'),'msg':_0x20ee44[_0x14e6ef('0x25f4')]?JSON[_0x14e6ef('0xbac')](_0x20ee44[_0x14e6ef('0x25f4')][_0x14e6ef('0x1e70')]):_0x20ee44[_0x14e6ef('0x1e70')]||_0x20ee44[_0x14e6ef('0x1586')]()});});},function(){});}function _0x3f39f2(_0x103d2c){return _0x103d2c===null?undefined:new Date(_0x103d2c);}function _0x1081d7(_0x5eeddb){const _0x342e15=_0x536f8f;_0x4dc2ac[_0x342e15('0x1197')](_0x5eeddb);}}const _0x4692b0=_0x3eb43b;_0x1621e6['$inject']=[_0x36e6f4('0x36f')];function _0x1621e6(_0x19c42a){const _0x13c0b8=_0x36e6f4,_0x45aa0a=this;_0x45aa0a[_0x13c0b8('0x1864')]={},_0x45aa0a[_0x13c0b8('0x24d5')]=_0x4fc520,_0x45aa0a[_0x13c0b8('0x1fa1')]={};function _0x4fc520(_0x1af51f){const _0x15f19d=_0x13c0b8;_0x45aa0a[_0x15f19d('0x1864')]=_0x1af51f,_0x45aa0a[_0x15f19d('0x180a')]=_0x15f19d('0xb72'),_0x45aa0a['script']=_0x15f19d('0xf2e')+_0x45aa0a['chatWebsite'][_0x15f19d('0x6ed')]+'/api/chat/websites/'+_0x45aa0a['chatWebsite']['id']+'/snippet?token='+_0x45aa0a[_0x15f19d('0x1864')][_0x15f19d('0x1f67')]+_0x15f19d('0x15d6'),_0x45aa0a[_0x15f19d('0x234d')]=_0x15f19d('0xb72');}_0x19c42a[_0x13c0b8('0xe83')](_0x13c0b8('0x1735'),function(){const _0x135b02=_0x13c0b8;_0x45aa0a['script']=_0x135b02('0xf2e')+_0x45aa0a[_0x135b02('0x1864')][_0x135b02('0x6ed')]+'/api/chat/websites/'+_0x45aa0a[_0x135b02('0x1864')]['id']+_0x135b02('0x16cb')+_0x45aa0a['chatWebsite'][_0x135b02('0x1f67')]+_0x135b02('0x15d6');});}const _0x1beb71=_0x1621e6;_0xd94a31[_0x36e6f4('0x1294')]=['$cookies',_0x36e6f4('0x1d2e')];function _0xd94a31(_0xc259e8,_0x1988ac){const _0xa6fd27=_0x36e6f4,_0x4e2b93=this,_0x1a5b45=0x8,_0x5546fa=_0x1a5b45*0x400*0x400;_0x4e2b93[_0xa6fd27('0x1864')]={},_0x4e2b93[_0xa6fd27('0x243c')],_0x4e2b93['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x5546fa,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x4e2b93[_0xa6fd27('0xe57')]={'flow':{}},_0x4e2b93[_0xa6fd27('0x1a5c')]=![],_0x4e2b93[_0xa6fd27('0xd20')]=_0x43b06b,_0x4e2b93[_0xa6fd27('0x1d40')]=_0x58f02e,_0x4e2b93[_0xa6fd27('0x1dea')]=_0x1df823,_0x4e2b93['init']=_0x5a39a0;function _0x5a39a0(_0x2374cb,_0x20b8fe){const _0x4b83dd=_0xa6fd27;_0x4e2b93[_0x4b83dd('0x1864')]=angular['copy'](_0x2374cb),_0x4e2b93['crudPermissions']=typeof _0x20b8fe!=='undefined'?_0x20b8fe:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4e2b93[_0x4b83dd('0xd67')][_0x4b83dd('0x21cc')]=_0x4b83dd('0x2595')[_0x4b83dd('0xf3')](':id',_0x4e2b93[_0x4b83dd('0x1864')]['id']),_0x4e2b93['chatWebsite'][_0x4b83dd('0x1b17')]=[];}function _0x43b06b(_0x2ddcbc){const _0x11f6e5=_0xa6fd27,_0x177116=[_0x11f6e5('0xccc'),_0x11f6e5('0x1cd0')];if(!_0x2cfb05()[_0x11f6e5('0x1257')](_0x177116,_0x2ddcbc[_0x11f6e5('0x26a5')]()))return _0x1988ac[_0x11f6e5('0xfc9')]({'title':_0x11f6e5('0x27fb')+_0x2ddcbc[_0x11f6e5('0x26a5')](),'msg':_0x11f6e5('0x1020')+_0x177116[_0x11f6e5('0x45a')]()}),![];if(_0x2ddcbc[_0x11f6e5('0x2340')]>_0x5546fa)return _0x1988ac[_0x11f6e5('0xfc9')]({'title':'File\x20too\x20big','msg':'The\x20max\x20allowed\x20size\x20is\x20'+_0x1a5b45+'MB'}),![];const _0x3e2ad3={'id':_0x2ddcbc[_0x11f6e5('0x20f4')],'file':_0x2ddcbc,'type':_0x11f6e5('0x32f')};return _0x4e2b93[_0x11f6e5('0x1864')][_0x11f6e5('0x1b17')][_0x11f6e5('0x2450')](_0x3e2ad3),!![];}function _0x58f02e(){const _0x176123=_0xa6fd27;_0x4e2b93[_0x176123('0xe57')][_0x176123('0x13d1')][_0x176123('0x1ca3')][_0x176123('0x5fb')]={'X-Requested-With':_0x176123('0x1bc1'),'Authorization':_0x176123('0x24d4')+_0xc259e8[_0x176123('0xd83')]('motion.token')},_0x4e2b93[_0x176123('0xe57')]['flow'][_0x176123('0x1d40')]();}function _0x1df823(_0x13b515){const _0x313d7e=_0xa6fd27;angular['forEach'](_0x4e2b93[_0x313d7e('0x1864')][_0x313d7e('0x1b17')],function(_0x2dec1e){const _0x309e8d=_0x313d7e;if(_0x2dec1e['id']===_0x13b515['uniqueIdentifier']){const _0x584973=new FileReader();_0x584973[_0x309e8d('0x2030')](_0x2dec1e[_0x309e8d('0x6bd')][_0x309e8d('0x6bd')]),_0x584973[_0x309e8d('0x15d4')]=function(_0x58baa7){const _0x3bcc7f=_0x309e8d;_0x2dec1e['url']=_0x58baa7[_0x3bcc7f('0x21cc')][_0x3bcc7f('0x15b5')];},_0x2dec1e['type']='image';}});}}const _0x56e9ca=_0xd94a31;_0x379423[_0x36e6f4('0x1294')]=['$state','$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'api','toasty',_0x36e6f4('0x21ef'),'chatWebsite','userProfileSection'];function _0x379423(_0x5195e7,_0x4df35d,_0x3dfd3b,_0x538925,_0x55d6bd,_0x3971aa,_0x513d29,_0x10bd4d,_0x9ec69d,_0x4db9c0,_0x4546c1,_0x2093e5){const _0x3c0044=_0x36e6f4,_0x59f729=this;_0x59f729[_0x3c0044('0x98')]=_0x4db9c0['getCurrentUser'](),_0x59f729['license']=_0x3971aa,_0x59f729[_0x3c0044('0xf8a')]=_0x513d29,_0x59f729[_0x3c0044('0x2900')]=_0x59f729[_0x3c0044('0xf8a')][_0x3c0044('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x59f729['location']=_0x4df35d[_0x3c0044('0x6f1')]()+_0x3c0044('0xc51')+_0x4df35d['host'](),_0x59f729['chatWebsite']=_0x4546c1||_0x5195e7[_0x3c0044('0x23f')][_0x3c0044('0x1864')]||{},_0x59f729[_0x3c0044('0x17aa')]=_0x2093e5&&_0x2093e5['count']==0x1?_0x2093e5[_0x3c0044('0x269a')][0x0]:null,_0x59f729[_0x3c0044('0x243c')]=_0x4db9c0[_0x3c0044('0xd87')](_0x59f729[_0x3c0044('0x17aa')]?_0x59f729[_0x3c0044('0x17aa')][_0x3c0044('0x243c')]:null),_0x59f729[_0x3c0044('0x128b')]={},_0x59f729[_0x3c0044('0x2669')]=_0x5195e7[_0x3c0044('0x23f')][_0x3c0044('0xbe3')]||0x0,_0x59f729[_0x3c0044('0x1728')]=_0x2ea1a4,_0x59f729[_0x3c0044('0x31d')]=_0x9ec69d[_0x3c0044('0x1fa1')],_0x59f729[_0x3c0044('0x22f5')]=_0x2018e7,_0x59f729['saveChatWebsite']=_0x1deacf,_0x4db9c0[_0x3c0044('0x1ac6')](_0x3c0044('0xa7c'))?_0x10bd4d[_0x3c0044('0xdd9')]['get']({'fields':'id,name','sort':'name'})[_0x3c0044('0xa44')][_0x3c0044('0x1166')](function(_0x172eb1){const _0x3e03fc=_0x3c0044;_0x59f729[_0x3e03fc('0x8de')]=_0x172eb1['rows']||[];})[_0x3c0044('0x1a80')](function(_0x694a9b){const _0x3d4a60=_0x3c0044;_0x9ec69d[_0x3d4a60('0xfc9')]({'title':_0x694a9b[_0x3d4a60('0x52d')]?_0x3d4a60('0x1e21')+_0x694a9b['status']+_0x3d4a60('0x11e1')+_0x694a9b[_0x3d4a60('0xe1b')]:_0x3d4a60('0x520'),'msg':_0x694a9b[_0x3d4a60('0x25f4')]?JSON[_0x3d4a60('0xbac')](_0x694a9b[_0x3d4a60('0x25f4')]):_0x694a9b[_0x3d4a60('0x1586')]()});}):_0x10bd4d[_0x3c0044('0xdd9')][_0x3c0044('0xd83')]({'fields':_0x3c0044('0x1776'),'sort':_0x3c0044('0x4f0')})[_0x3c0044('0xa44')][_0x3c0044('0x1166')](function(_0x4b7e44){const _0x514429=_0x3c0044;_0x59f729[_0x514429('0x8de')]=_0x4b7e44[_0x514429('0x269a')]||[];})[_0x3c0044('0x1166')](function(){const _0x2c9a8d=_0x3c0044;return _0x10bd4d['userProfileSection'][_0x2c9a8d('0xd83')]({'userProfileId':_0x59f729['currentUser'][_0x2c9a8d('0xb86')],'sectionId':0x12d})[_0x2c9a8d('0xa44')];})[_0x3c0044('0x1166')](function(_0x5cc28c){const _0xd370d0=_0x3c0044,_0x3a8ca2=_0x5cc28c&&_0x5cc28c[_0xd370d0('0x269a')]?_0x5cc28c['rows'][0x0]:null;if(!_0x3a8ca2){const _0x8de458=[];let _0x4fb6f9=null;_0x59f729[_0xd370d0('0x1864')]&&(_0x4fb6f9=_0x2cfb05()[_0xd370d0('0xc38')](_0x59f729[_0xd370d0('0x8de')],{'id':Number(_0x59f729[_0xd370d0('0x1864')][_0xd370d0('0x23c')])}));for(let _0x4e4463=0x0;_0x4e4463<_0x59f729[_0xd370d0('0x8de')][_0xd370d0('0x264b')];_0x4e4463++){_0x4fb6f9&&_0x59f729[_0xd370d0('0x8de')][_0x4e4463]['id']===_0x4fb6f9['id']&&(_0x59f729[_0xd370d0('0x8de')][_0x4e4463]['canSelect']=![],_0x8de458['push'](_0x59f729['lists'][_0x4e4463]));}_0x59f729[_0xd370d0('0x8de')]=_0x8de458;}else{if(!_0x3a8ca2['autoAssociation'])return _0x10bd4d[_0xd370d0('0x4b5')][_0xd370d0('0xd83')]({'sectionId':_0x3a8ca2['id']})['$promise']['then'](function(_0x57f01f){const _0x48175e=_0xd370d0,_0x1ce24d=_0x2cfb05()['map'](_0x57f01f[_0x48175e('0x269a')],function(_0xddeaca){const _0x56989f=_0x48175e;return _0x2cfb05()[_0x56989f('0xc38')](_0x59f729[_0x56989f('0x8de')],{'id':_0xddeaca[_0x56989f('0x24e8')]});});let _0x2bfaba=null;_0x59f729['chatWebsite']&&(_0x2bfaba=_0x2cfb05()['find'](_0x59f729[_0x48175e('0x8de')],{'id':Number(_0x59f729['chatWebsite'][_0x48175e('0x23c')])}));if(_0x2bfaba&&!_0x2cfb05()[_0x48175e('0x1798')](_0x1ce24d,['id',_0x2bfaba['id']])){const _0x910f13=_0x2cfb05()[_0x48175e('0xc38')](_0x59f729['lists'],{'id':_0x2bfaba['id']});_0x910f13[_0x48175e('0x2378')]=![],_0x1ce24d[_0x48175e('0x1514')](_0x910f13);}_0x59f729['lists']=_0x1ce24d;});}})['catch'](function(_0x19024e){const _0x113fdb=_0x3c0044;_0x9ec69d['error']({'title':_0x19024e[_0x113fdb('0x52d')]?_0x113fdb('0x1e21')+_0x19024e[_0x113fdb('0x52d')]+_0x113fdb('0x11e1')+_0x19024e[_0x113fdb('0xe1b')]:_0x113fdb('0x1248'),'msg':_0x19024e[_0x113fdb('0x25f4')]?JSON[_0x113fdb('0xbac')](_0x19024e[_0x113fdb('0x25f4')]):_0x19024e['toString']()});}),_0x4db9c0[_0x3c0044('0x1ac6')](_0x3c0044('0xa7c'))?_0x10bd4d['interval'][_0x3c0044('0xd83')]({'fields':_0x3c0044('0x1776'),'sort':_0x3c0044('0x4f0'),'IntervalId':_0x3c0044('0x15d7')})[_0x3c0044('0xa44')]['then'](function(_0x404f47){const _0x58f8a1=_0x3c0044;_0x59f729[_0x58f8a1('0x277c')]=_0x404f47['rows']||[];})[_0x3c0044('0x1a80')](function(_0x3c2dbf){const _0xbf23ca=_0x3c0044;_0x9ec69d['error']({'title':_0x3c2dbf[_0xbf23ca('0x52d')]?_0xbf23ca('0x1e21')+_0x3c2dbf[_0xbf23ca('0x52d')]+'\x20-\x20'+_0x3c2dbf[_0xbf23ca('0xe1b')]:'SYSTEM:GET_INTERVAL','msg':_0x3c2dbf[_0xbf23ca('0x25f4')]?JSON[_0xbf23ca('0xbac')](_0x3c2dbf['data']):_0x3c2dbf[_0xbf23ca('0x1586')]()});}):_0x10bd4d[_0x3c0044('0x277c')]['get']({'fields':'id,name','sort':_0x3c0044('0x4f0'),'IntervalId':_0x3c0044('0x15d7')})[_0x3c0044('0xa44')][_0x3c0044('0x1166')](function(_0x109e51){const _0x7dfd7=_0x3c0044;_0x59f729[_0x7dfd7('0x277c')]=_0x109e51[_0x7dfd7('0x269a')]||[];})[_0x3c0044('0x1166')](function(){const _0xcf3f1a=_0x3c0044;return _0x10bd4d[_0xcf3f1a('0x17aa')]['get']({'userProfileId':_0x59f729[_0xcf3f1a('0x98')][_0xcf3f1a('0xb86')],'sectionId':0x3ec})[_0xcf3f1a('0xa44')];})['then'](function(_0x46161f){const _0x2d845b=_0x3c0044,_0x101b14=_0x46161f&&_0x46161f[_0x2d845b('0x269a')]?_0x46161f[_0x2d845b('0x269a')][0x0]:null;if(!_0x101b14){const _0x1ca62b=[];let _0x6b0cc7=null;_0x59f729[_0x2d845b('0x1864')]&&(_0x6b0cc7=_0x2cfb05()[_0x2d845b('0xc38')](_0x59f729[_0x2d845b('0x277c')],{'id':Number(_0x59f729['chatWebsite']['IntervalId'])}));for(let _0x5c6c21=0x0;_0x5c6c21<_0x59f729[_0x2d845b('0x277c')][_0x2d845b('0x264b')];_0x5c6c21++){_0x6b0cc7&&_0x59f729[_0x2d845b('0x277c')][_0x5c6c21]['id']===_0x6b0cc7['id']&&(_0x59f729[_0x2d845b('0x277c')][_0x5c6c21][_0x2d845b('0x2378')]=![],_0x1ca62b[_0x2d845b('0x1514')](_0x59f729['interval'][_0x5c6c21]));}_0x59f729[_0x2d845b('0x277c')]=_0x1ca62b;}else{if(!_0x101b14[_0x2d845b('0x1a2b')])return _0x10bd4d[_0x2d845b('0x4b5')][_0x2d845b('0xd83')]({'sectionId':_0x101b14['id']})['$promise'][_0x2d845b('0x1166')](function(_0x278c91){const _0x17e241=_0x2d845b,_0x12c2b0=_0x2cfb05()[_0x17e241('0x2563')](_0x278c91[_0x17e241('0x269a')],function(_0x2a2917){return _0x2cfb05()['find'](_0x59f729['interval'],{'id':_0x2a2917['resourceId']});});let _0x440ea2=null;_0x59f729[_0x17e241('0x1864')]&&(_0x440ea2=_0x2cfb05()['find'](_0x59f729[_0x17e241('0x277c')],{'id':Number(_0x59f729['chatWebsite'][_0x17e241('0x186f')])}));if(_0x440ea2&&!_0x2cfb05()[_0x17e241('0x1798')](_0x12c2b0,['id',_0x440ea2['id']])){const _0x35be40=_0x2cfb05()[_0x17e241('0xc38')](_0x59f729[_0x17e241('0x277c')],{'id':_0x440ea2['id']});_0x35be40[_0x17e241('0x2378')]=![],_0x12c2b0[_0x17e241('0x1514')](_0x35be40);}_0x59f729['interval']=_0x12c2b0;});}})[_0x3c0044('0x1a80')](function(_0x4f2122){const _0x25cf9b=_0x3c0044;_0x9ec69d[_0x25cf9b('0xfc9')]({'title':_0x4f2122[_0x25cf9b('0x52d')]?'API:'+_0x4f2122[_0x25cf9b('0x52d')]+_0x25cf9b('0x11e1')+_0x4f2122[_0x25cf9b('0xe1b')]:_0x25cf9b('0xe48'),'msg':_0x4f2122['data']?JSON['stringify'](_0x4f2122[_0x25cf9b('0x25f4')]):_0x4f2122['toString']()});}),_0x4db9c0[_0x3c0044('0x1ac6')](_0x3c0044('0xa7c'))?_0x10bd4d[_0x3c0044('0x1e77')][_0x3c0044('0xd83')]({'fields':'name,id','sort':'name','nolimit':_0x3c0044('0xf3b')})[_0x3c0044('0xa44')][_0x3c0044('0x1166')](function(_0x29b3ad){const _0x49b137=_0x3c0044;_0x59f729[_0x49b137('0xe29')]=_0x29b3ad[_0x49b137('0x269a')]||[];})[_0x3c0044('0x1a80')](function(_0x15c007){const _0x5bcbfc=_0x3c0044;_0x9ec69d['error']({'title':_0x15c007[_0x5bcbfc('0x52d')]?_0x5bcbfc('0x1e21')+_0x15c007[_0x5bcbfc('0x52d')]+_0x5bcbfc('0x11e1')+_0x15c007[_0x5bcbfc('0xe1b')]:_0x5bcbfc('0x18ed'),'msg':_0x15c007[_0x5bcbfc('0x25f4')]?JSON[_0x5bcbfc('0xbac')](_0x15c007['data']):_0x15c007['toString']()});}):_0x10bd4d[_0x3c0044('0x1e77')][_0x3c0044('0xd83')]({'fields':'name,id','sort':_0x3c0044('0x4f0'),'nolimit':'true'})[_0x3c0044('0xa44')][_0x3c0044('0x1166')](function(_0x4d06e8){const _0x58d207=_0x3c0044;_0x59f729[_0x58d207('0xe29')]=_0x4d06e8[_0x58d207('0x269a')]||[];})[_0x3c0044('0x1166')](function(){const _0x39772d=_0x3c0044;return _0x10bd4d[_0x39772d('0x17aa')]['get']({'userProfileId':_0x59f729['currentUser'][_0x39772d('0xb86')],'sectionId':0x3ed})[_0x39772d('0xa44')];})[_0x3c0044('0x1166')](function(_0x133039){const _0x1fa0ee=_0x3c0044,_0x433905=_0x133039&&_0x133039[_0x1fa0ee('0x269a')]?_0x133039['rows'][0x0]:null;if(!_0x433905)_0x59f729[_0x1fa0ee('0xe29')]=[];else{if(!_0x433905[_0x1fa0ee('0x1a2b')])return _0x10bd4d[_0x1fa0ee('0x4b5')][_0x1fa0ee('0xd83')]({'sectionId':_0x433905['id']})[_0x1fa0ee('0xa44')][_0x1fa0ee('0x1166')](function(_0x5bdf28){const _0x4c1b31=_0x1fa0ee,_0x3b69e5=_0x2cfb05()[_0x4c1b31('0x2563')](_0x5bdf28[_0x4c1b31('0x269a')],function(_0x3df456){const _0x24e526=_0x4c1b31;return _0x2cfb05()[_0x24e526('0xc38')](_0x59f729[_0x24e526('0xe29')],{'id':_0x3df456[_0x24e526('0x24e8')]});});_0x59f729['pauses'][_0x4c1b31('0x2782')](function(_0x2a0c00){const _0x6cb13f=_0x4c1b31;!_0x2cfb05()[_0x6cb13f('0x1798')](_0x3b69e5,['id',_0x2a0c00['id']])&&(_0x2a0c00[_0x6cb13f('0x2378')]=![]),_0x3b69e5[_0x6cb13f('0x1514')](_0x2a0c00);}),_0x59f729['pauses']=_0x3b69e5;});}})['catch'](function(_0x2eb395){const _0x14a35c=_0x3c0044;_0x9ec69d['error']({'title':_0x2eb395[_0x14a35c('0x52d')]?_0x14a35c('0x1e21')+_0x2eb395[_0x14a35c('0x52d')]+_0x14a35c('0x11e1')+_0x2eb395[_0x14a35c('0xe1b')]:_0x14a35c('0x1488'),'msg':_0x2eb395[_0x14a35c('0x25f4')]?JSON[_0x14a35c('0xbac')](_0x2eb395[_0x14a35c('0x25f4')]):_0x2eb395[_0x14a35c('0x1586')]()});});function _0x2ea1a4(_0x4e1044,_0x23ae61){const _0x50cb0e=_0x3c0044;_0x3dfd3b[_0x50cb0e('0x1f80')]({'controller':'ChatWebsiteagentaddController','controllerAs':'vm','templateUrl':_0x550701,'parent':angular[_0x50cb0e('0x1194')](_0x538925['body']),'targetEvent':_0x23ae61,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x4e1044,'chatWebsites':_0x59f729[_0x50cb0e('0x2136')]?_0x59f729[_0x50cb0e('0x2136')]['rows']:[],'crudPermissions':_0x59f729['crudPermissions'],'realtime':![]}});}function _0x2018e7(){const _0xb91e44=_0x3c0044;_0x5195e7['go'](_0xb91e44('0xcd'),{},{'reload':'app.chat.chatWebsites'});}function _0x1deacf(){const _0x5f4772=_0x3c0044;_0x10bd4d[_0x5f4772('0x1864')][_0x5f4772('0x1449')]({'id':_0x59f729[_0x5f4772('0x1864')]['id']},_0x59f729['chatWebsite'])[_0x5f4772('0xa44')][_0x5f4772('0x1166')](function(){const _0x56d8ee=_0x5f4772;_0x9ec69d['success']({'title':_0x56d8ee('0x1565'),'msg':_0x59f729[_0x56d8ee('0x1864')][_0x56d8ee('0x4f0')]?_0x59f729[_0x56d8ee('0x1864')]['name']+_0x56d8ee('0xa17'):''});})[_0x5f4772('0x1a80')](function(_0x46d92d){const _0x2b81fa=_0x5f4772;_0x9ec69d['error']({'title':_0x46d92d[_0x2b81fa('0x52d')]?_0x2b81fa('0x1e21')+_0x46d92d[_0x2b81fa('0x52d')]+_0x2b81fa('0x11e1')+_0x46d92d['statusText']:'SYSTEM:GETchatWebsite','msg':_0x46d92d[_0x2b81fa('0x25f4')]?JSON['stringify'](_0x46d92d[_0x2b81fa('0x25f4')]):_0x46d92d['toString']()});});}}const _0x4c5ee6=_0x379423;_0x354def['$inject']=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x354def(_0xa17573,_0x5ce518){const _0x143e37=_0x36e6f4;_0xa17573[_0x143e37('0x63f')](_0x143e37('0xb66'),{'abstract':!![],'url':_0x143e37('0x828')})[_0x143e37('0x63f')]('app.chat.chatQueues',{'url':_0x143e37('0x7ac'),'views':{'content@app':{'templateUrl':_0x5710d1,'controller':_0x143e37('0x27f5')}},'resolve':{'chatQueues':[_0x143e37('0x1fbc'),_0x143e37('0x21ef'),function(_0x4430f7,_0x27be11){const _0x359a57=_0x143e37;return _0x27be11[_0x359a57('0x1ac6')]('admin')?_0x4430f7[_0x359a57('0x18af')]('chatQueue@get',{'fields':_0x359a57('0xf26'),'sort':'-updatedAt','channel':_0x359a57('0xde2'),'limit':0xa,'offset':0x0}):_0x4430f7[_0x359a57('0x18af')](_0x359a57('0x17c4'),{'id':_0x27be11[_0x359a57('0x26cd')]()[_0x359a57('0xb86')],'section':_0x359a57('0x1858'),'fields':_0x359a57('0xf26'),'sort':_0x359a57('0x14dc'),'channel':_0x359a57('0xde2'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x143e37('0x21ef'),function(_0x442b52,_0x40d0fa){const _0x49b908=_0x143e37;return _0x40d0fa[_0x49b908('0x1ac6')](_0x49b908('0xa7c'))?null:_0x442b52[_0x49b908('0x18af')](_0x49b908('0x697'),{'fields':_0x49b908('0x686'),'id':_0x40d0fa[_0x49b908('0x26cd')]()[_0x49b908('0xb86')]});}],'userProfileSection':[_0x143e37('0x1fbc'),_0x143e37('0x21ef'),function(_0x272d59,_0x901405){const _0x1453f2=_0x143e37;return _0x901405[_0x1453f2('0x1ac6')](_0x1453f2('0xa7c'))?null:_0x272d59['resolve'](_0x1453f2('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x901405[_0x1453f2('0x26cd')]()[_0x1453f2('0xb86')],'sectionId':0x1f5});}]},'authenticate':!![],'permissionId':0x1f5,'bodyClass':_0x143e37('0xde2')})['state']('app.chat.chatQueues.edit',{'url':'/:id?tab','params':{'chatQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x39e166,'controller':_0x143e37('0x1caa')}},'resolve':{'chatQueue':[_0x143e37('0x1fbc'),_0x143e37('0xf75'),function(_0x5dd543,_0x483013){const _0x99d512=_0x143e37;return _0x5dd543[_0x99d512('0x18af')](_0x99d512('0x2479'),{'fields':_0x99d512('0xf26'),'id':_0x483013['id']});}],'userProfileSection':['apiResolver',_0x143e37('0x21ef'),function(_0x1dda2d,_0x429696){const _0x5e5649=_0x143e37;return _0x1dda2d[_0x5e5649('0x18af')](_0x5e5649('0xaf'),{'fields':_0x5e5649('0xe26'),'userProfileId':_0x429696[_0x5e5649('0x26cd')]()[_0x5e5649('0xb86')],'sectionId':0x1f5});}]},'authenticate':!![],'permissionId':0x1f5,'bodyClass':'chat'})[_0x143e37('0x63f')](_0x143e37('0xcd'),{'url':'/chatWebsites','views':{'content@app':{'templateUrl':_0x52e96b,'controller':_0x143e37('0x89c')}},'resolve':{'chatWebsites':[_0x143e37('0x1fbc'),'Auth',function(_0x1b899,_0x5870d1){const _0x12029f=_0x143e37;return _0x5870d1['hasRole'](_0x12029f('0xa7c'))?_0x1b899[_0x12029f('0x18af')](_0x12029f('0x1794'),{'fields':_0x12029f('0x244b'),'sort':_0x12029f('0x14dc'),'limit':0xa,'offset':0x0}):_0x1b899[_0x12029f('0x18af')](_0x12029f('0x17c4'),{'id':_0x5870d1[_0x12029f('0x26cd')]()[_0x12029f('0xb86')],'section':'ChatWebsites','fields':_0x12029f('0x244b'),'sort':_0x12029f('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x143e37('0x1fbc'),_0x143e37('0x21ef'),function(_0x244b1b,_0x318a46){const _0x8ea4ff=_0x143e37;return _0x318a46[_0x8ea4ff('0x1ac6')](_0x8ea4ff('0xa7c'))?null:_0x244b1b['resolve'](_0x8ea4ff('0x697'),{'fields':_0x8ea4ff('0x686'),'id':_0x318a46['getCurrentUser']()[_0x8ea4ff('0xb86')]});}],'userProfileSection':[_0x143e37('0x1fbc'),_0x143e37('0x21ef'),function(_0x2f3049,_0x277aab){const _0x8048b6=_0x143e37;return _0x277aab[_0x8048b6('0x1ac6')](_0x8048b6('0xa7c'))?null:_0x2f3049[_0x8048b6('0x18af')]('userProfileSection@get',{'fields':_0x8048b6('0xe26'),'userProfileId':_0x277aab[_0x8048b6('0x26cd')]()['userProfileId'],'sectionId':0x1f6});}]},'authenticate':!![],'permissionId':0x1f6,'bodyClass':'chat'})[_0x143e37('0x63f')]('app.chat.chatWebsites.edit',{'url':_0x143e37('0x2233'),'params':{'chatWebsite':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x1d738a,'controller':_0x143e37('0x1f56')}},'resolve':{'chatWebsite':[_0x143e37('0x1fbc'),'$stateParams',function(_0x263a3d,_0x4d8fd6){const _0x4ca6e7=_0x143e37;return _0x263a3d[_0x4ca6e7('0x18af')](_0x4ca6e7('0x1794'),{'fields':_0x4ca6e7('0x244b'),'id':_0x4d8fd6['id']});}],'userProfileSection':[_0x143e37('0x1fbc'),_0x143e37('0x21ef'),function(_0x30ec40,_0x5f1068){const _0x169675=_0x143e37;return _0x30ec40['resolve']('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5f1068[_0x169675('0x26cd')]()[_0x169675('0xb86')],'sectionId':0x1f6});}]},'authenticate':!![],'permissionId':0x1f6,'bodyClass':_0x143e37('0xde2')}),_0x5ce518['addPart'](_0x143e37('0x169f'));}angular[_0x36e6f4('0x896')](_0x36e6f4('0xb66'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),'ckeditor',_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),'mwFormBuilder',_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),'material.components.expansionPanels',_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),_0x36e6f4('0x286f')])[_0x36e6f4('0xe11')](_0x354def)[_0x36e6f4('0x75e')](_0x36e6f4('0x22b1'),_0x3c59f7)[_0x36e6f4('0x75e')]('CreateOrEditChatQueueDialogController',_0x5efdea)[_0x36e6f4('0x75e')]('ChatQueueagentaddController',_0x410c05)[_0x36e6f4('0x75e')](_0x36e6f4('0x1c83'),_0x4d31c9)['controller'](_0x36e6f4('0x87d'),_0x31ec80)['controller'](_0x36e6f4('0x1bb4'),_0x10a540)[_0x36e6f4('0x75e')](_0x36e6f4('0x220c'),_0x1e5902)[_0x36e6f4('0x75e')](_0x36e6f4('0x171b'),_0x2f1d0e)['controller'](_0x36e6f4('0x222e'),_0x39468b)['controller'](_0x36e6f4('0x20'),_0x10bc22)[_0x36e6f4('0x75e')](_0x36e6f4('0xeb5'),_0xd50390)[_0x36e6f4('0x75e')](_0x36e6f4('0xe7a'),_0x167dae)['controller']('EditChatWebsiteAppamazonlexDialogController',_0x167dae)[_0x36e6f4('0x75e')](_0x36e6f4('0x121d'),_0x54863d)['controller']('EditChatWebsiteAppcloseDialogController',_0x123bb3)[_0x36e6f4('0x75e')](_0x36e6f4('0xdb9'),_0x27f068)['controller'](_0x36e6f4('0x224a'),_0x1db176)[_0x36e6f4('0x75e')](_0x36e6f4('0xe49'),_0x322038)[_0x36e6f4('0x75e')]('EditChatWebsiteAppintervalDialogController',_0xb78adf)[_0x36e6f4('0x75e')](_0x36e6f4('0x35'),_0x1b3b8e)[_0x36e6f4('0x75e')](_0x36e6f4('0x1723'),_0x5f5ce4)[_0x36e6f4('0x75e')](_0x36e6f4('0x125e'),_0x46c2e1)[_0x36e6f4('0x75e')](_0x36e6f4('0x780'),_0x1edfc6)[_0x36e6f4('0x75e')](_0x36e6f4('0x14fd'),_0x399cbb)[_0x36e6f4('0x75e')](_0x36e6f4('0x191a'),_0x5a081e)['controller']('ChatWebsiteChatDispositionsController',_0x50aee5)[_0x36e6f4('0x75e')](_0x36e6f4('0x1863'),_0x2e9506)[_0x36e6f4('0x75e')](_0x36e6f4('0x1901'),_0x2b05a9)[_0x36e6f4('0x75e')](_0x36e6f4('0x2087'),_0x46c66a)[_0x36e6f4('0x75e')](_0x36e6f4('0x1a3b'),_0xffa32b)['controller'](_0x36e6f4('0x198d'),_0xa3c2ec)[_0x36e6f4('0x75e')](_0x36e6f4('0x1ecc'),_0x4157d0)[_0x36e6f4('0x75e')]('ShowOfflineMessageOfflineMessageDialogController',_0x59dab4)[_0x36e6f4('0x75e')](_0x36e6f4('0x25f8'),_0x23cb97)['controller'](_0x36e6f4('0x1087'),_0x4692b0)[_0x36e6f4('0x75e')]('ChatWebsiteScriptController',_0x1beb71)['controller'](_0x36e6f4('0x2805'),_0x56e9ca)[_0x36e6f4('0x75e')]('ChatWebsiteController',_0x4c5ee6);const _0x53f1c5=_0x2734b2['p']+_0x36e6f4('0x1c25'),_0xa4f315=_0x2734b2['p']+_0x36e6f4('0x89'),_0x227cc5=_0x2734b2['p']+_0x36e6f4('0x820'),_0x54f859=_0x2734b2['p']+_0x36e6f4('0x2578');_0x50efab['$inject']=[_0x36e6f4('0x36f'),'$q',_0x36e6f4('0x8da'),'$mdDialog',_0x36e6f4('0x1c90'),'$filter',_0x36e6f4('0xe29'),_0x36e6f4('0x1f7e'),_0x36e6f4('0x24b7'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x1a02'),'userProfile','userProfileSection',_0x36e6f4('0x21ef'),'license',_0x36e6f4('0x10eb')];function _0x50efab(_0x28f096,_0x541c3e,_0x4fe19c,_0x5519e0,_0xf30ca3,_0x21460e,_0x7aadda,_0x3109cf,_0x2b370b,_0x238f0e,_0x5b2e3e,_0x3abbb0,_0x152e6a,_0x1ed7c1,_0x5d5e1e,_0x5a9f94,_0x25f15f,_0x183864){const _0x3e98ce=_0x36e6f4,_0x50d91b=this,_0x531fbf=['userpic',_0x3e98ce('0xb41'),'lastLoginAt',_0x3e98ce('0x3dc'),_0x3e98ce('0x246c'),_0x3e98ce('0x3dc'),_0x3e98ce('0x1eef'),_0x3e98ce('0x16a6'),_0x3e98ce('0x1c5c'),'openchannelPause',_0x3e98ce('0xb4'),_0x3e98ce('0x178d'),_0x3e98ce('0x11ee'),_0x3e98ce('0x5aa'),_0x3e98ce('0x2540'),'chatCapacity','openchannelCapacity','mailCapacity',_0x3e98ce('0x2627'),_0x3e98ce('0x361'),_0x3e98ce('0x1462'),'chatCurrentCapacity','openchannelCurrentCapacity',_0x3e98ce('0x82d'),_0x3e98ce('0x1da1'),_0x3e98ce('0x2681'),_0x3e98ce('0x1ee6'),'chatStatus',_0x3e98ce('0x1f33'),_0x3e98ce('0x25d8'),_0x3e98ce('0x1c1a'),_0x3e98ce('0x1a5d'),_0x3e98ce('0x276d'),_0x3e98ce('0x17e1'),'chatStatusTime',_0x3e98ce('0x43e'),_0x3e98ce('0x1955'),_0x3e98ce('0x2357'),_0x3e98ce('0x11a8'),_0x3e98ce('0x4f3'),_0x3e98ce('0x18c9'),_0x3e98ce('0x1d3e'),_0x3e98ce('0x1ad2'),'screenrecording',_0x3e98ce('0x2167'),_0x3e98ce('0x1c5b')],_0x97981b=[_0x3e98ce('0x1c5c'),_0x3e98ce('0x287f'),_0x3e98ce('0xb4'),_0x3e98ce('0x178d'),_0x3e98ce('0x11ee'),_0x3e98ce('0x5aa'),_0x3e98ce('0x2540'),_0x3e98ce('0xb41')];_0x50d91b[_0x3e98ce('0x98')]=_0x5a9f94[_0x3e98ce('0x26cd')](),_0x50d91b[_0x3e98ce('0xcdd')]=[_0x3e98ce('0x1628'),_0x3e98ce('0x133e'),_0x3e98ce('0x2344'),_0x3e98ce('0x158e'),'not_inuse'],_0x50d91b[_0x3e98ce('0xe29')]=_0x7aadda||{'count':0x0,'rows':[]},_0x50d91b[_0x3e98ce('0x5c9')]=_0x25f15f,_0x50d91b[_0x3e98ce('0x7f')]=_0x1ed7c1,_0x50d91b['userProfileSection']=_0x5d5e1e&&_0x5d5e1e['count']==0x1?_0x5d5e1e[_0x3e98ce('0x269a')][0x0]:null,_0x50d91b[_0x3e98ce('0x243c')]=_0x5a9f94[_0x3e98ce('0xd87')](_0x50d91b['userProfileSection']?_0x50d91b[_0x3e98ce('0x17aa')][_0x3e98ce('0x243c')]:null),_0x50d91b[_0x3e98ce('0x1f7e')]=_0x3109cf?_0x2cfb05()['keyBy'](_0x3109cf[_0x3e98ce('0x269a')]?_0x3109cf['rows']:[],'id'):{},_0x50d91b['rpcAgents']=_0x2b370b?_0x2cfb05()[_0x3e98ce('0x155c')](_0x2b370b[_0x3e98ce('0x269a')]?_0x2b370b[_0x3e98ce('0x269a')]:[],'id'):{},_0x50d91b[_0x3e98ce('0x5e5')]={},_0x50d91b['load']=![],_0x50d91b[_0x3e98ce('0xa99')]=[],_0x50d91b[_0x3e98ce('0x4c4')]={};for(const _0x46aecb in _0x50d91b[_0x3e98ce('0x1f7e')]){typeof _0x50d91b[_0x3e98ce('0x1f7e')][_0x46aecb]!=='undefined'&&(_0x50d91b['agents'][_0x46aecb][_0x3e98ce('0x24d5')]=!![]);}_0x50d91b['query']={'limit':0xa,'page':0x1,'order':_0x3e98ce('0x6e1'),'globalStatusFilter':'','pauseTypeFilter':''},_0x50d91b['logout']=_0x3e7126,_0x50d91b[_0x3e98ce('0xaf7')]=_0x31fbd1,_0x50d91b[_0x3e98ce('0x1e77')]=_0x1ececc,_0x50d91b[_0x3e98ce('0xecc')]=_0x3f3eae,_0x50d91b[_0x3e98ce('0x6df')]=_0x318904,_0x50d91b[_0x3e98ce('0x72f')]=_0x3f3a80,_0x50d91b[_0x3e98ce('0x28b5')]=_0x2f60e7,_0x50d91b[_0x3e98ce('0x882')]=_0x327409,_0x50d91b[_0x3e98ce('0x5ad')]=_0x1c4c8c,_0x50d91b[_0x3e98ce('0xb02')]=_0x15d9c8,_0x50d91b[_0x3e98ce('0x1303')]=_0x1ad1d1,_0x50d91b[_0x3e98ce('0x2232')]=_0xe0c334,_0x50d91b[_0x3e98ce('0xae0')]=_0x3b6398,_0x50d91b[_0x3e98ce('0x223a')]=_0x229c5e,_0x50d91b['onComplete']=_0x53a5c2,_0x50d91b['screenRecording']=_0x5001a1,_0x5b2e3e['on'](_0x3e98ce('0x26b2'),_0x50d91b[_0x3e98ce('0x1303')]),_0x5b2e3e['on']('user:update',_0x50d91b[_0x3e98ce('0x2232')]),_0x5b2e3e['on'](_0x3e98ce('0x10fc'),_0x50d91b[_0x3e98ce('0x223a')]),_0x5b2e3e['on'](_0x3e98ce('0x1c99'),_0x50d91b[_0x3e98ce('0x1923')]),_0x3b6398();let _0x3607a0=_0x183864(function(){const _0x3ffde5=_0x3e98ce;_0x50d91b[_0x3ffde5('0x173f')]&&(_0x50d91b[_0x3ffde5('0x173f')]=![],_0x3b6398());},0x3e7);function _0x3b6398(){const _0x25bb39=_0x3e98ce;_0x50d91b[_0x25bb39('0x173f')]=![];const _0x175777=_0x541c3e[_0x25bb39('0x24d8')]();_0x50d91b[_0x25bb39('0x1f48')]=_0x175777[_0x25bb39('0x1f48')],_0x50d91b['filteredAgents']=[],_0x50d91b[_0x25bb39('0xa99')]=[],_0x2cfb05()[_0x25bb39('0x941')](_0x50d91b[_0x25bb39('0x1f7e')],function(_0x4d01fd,_0x42cc54){const _0x52da4d=_0x25bb39;_0x50d91b[_0x52da4d('0x24b7')][_0x42cc54]&&_0x2cfb05()[_0x52da4d('0xcc3')](_0x4d01fd,_0x2cfb05()[_0x52da4d('0x1a08')](_0x2cfb05()[_0x52da4d('0x1414')](_0x50d91b[_0x52da4d('0x24b7')][_0x42cc54],_0x97981b),_0x531fbf)),_0x2f60e7(_0x4d01fd),_0x4d01fd[_0x52da4d('0xb41')]?(_0x50d91b[_0x52da4d('0x220b')][_0x52da4d('0x1514')](_0x4d01fd),_0x50d91b[_0x52da4d('0x4c4')][_0x4d01fd[_0x52da4d('0x1eef')]]=_0x42cc54):_0x4d01fd[_0x52da4d('0x25b3')]=_0x2cfb05()[_0x52da4d('0xa53')](_0x24273b()()[_0x52da4d('0x128a')]('x'));});_0x50d91b[_0x25bb39('0x2218')][_0x25bb39('0xf4')]&&_0x2cfb05()[_0x25bb39('0x127f')](_0x50d91b[_0x25bb39('0x220b')],function(_0x4d8126){const _0x4c45a0=_0x25bb39;return _0x4d8126[_0x4c45a0('0xe34')]!==_0x50d91b['query'][_0x4c45a0('0xf4')];});_0x50d91b['query'][_0x25bb39('0x2121')]&&_0x2cfb05()['remove'](_0x50d91b[_0x25bb39('0x220b')],function(_0x1c636a){const _0x4b409f=_0x25bb39;return _0x1c636a[_0x4b409f('0x246c')]!==_0x50d91b[_0x4b409f('0x2218')]['pauseTypeFilter'];});_0x50d91b[_0x25bb39('0x2218')][_0x25bb39('0x1c33')]&&_0x2cfb05()[_0x25bb39('0x127f')](_0x50d91b['filteredAgents'],function(_0x268a25){const _0x2c9b85=_0x25bb39;return _0x268a25[_0x2c9b85('0x6e1')]['toLowerCase']()[_0x2c9b85('0x2379')](_0x50d91b['query'][_0x2c9b85('0x1c33')][_0x2c9b85('0x2574')]())<0x0;});_0x50d91b['filteredAgents']=_0x475394(_0x50d91b['filteredAgents']);const _0x45db69=(_0x50d91b[_0x25bb39('0x2218')][_0x25bb39('0x1a43')]-0x1)*_0x50d91b['query'][_0x25bb39('0x163f')];_0x50d91b[_0x25bb39('0x5e5')]=_0x2cfb05()[_0x25bb39('0x3e5')](_0x50d91b['filteredAgents'],_0x45db69)[_0x25bb39('0x233')](0x0,_0x50d91b['query']['limit']);for(let _0x58acd0=0x0;_0x58acd0<_0x50d91b['paginatedAgents'][_0x25bb39('0x264b')];_0x58acd0+=0x1){_0x50d91b[_0x25bb39('0xa99')][_0x25bb39('0x1514')](_0x50d91b[_0x25bb39('0x5e5')][_0x58acd0]['id']);}_0x175777[_0x25bb39('0x18af')](),_0x50d91b['load']=!![];}function _0x1ad1d1(_0x232f3a){const _0x4e857a=_0x3e98ce;_0x50d91b[_0x4e857a('0x1f7e')][_0x232f3a['id']]&&(_0x2cfb05()[_0x4e857a('0xcc3')](_0x50d91b[_0x4e857a('0x1f7e')][_0x232f3a['id']],_0x2cfb05()['pick'](_0x2cfb05()[_0x4e857a('0x1414')](_0x232f3a,_0x97981b),_0x531fbf)),_0x2cfb05()[_0x4e857a('0xcc3')](_0x50d91b[_0x4e857a('0x24b7')][_0x232f3a['id']],_0x2cfb05()[_0x4e857a('0x1a08')](_0x2cfb05()['omit'](_0x232f3a,_0x97981b),_0x531fbf)),_0x2f60e7(_0x50d91b[_0x4e857a('0x1f7e')][_0x232f3a['id']]));}function _0xe0c334(_0x44b4bd){const _0x4b875d=_0x3e98ce;_0x50d91b[_0x4b875d('0x1f7e')][_0x44b4bd['id']]&&(_0x2cfb05()[_0x4b875d('0xcc3')](_0x50d91b[_0x4b875d('0x1f7e')][_0x44b4bd['id']],_0x2cfb05()[_0x4b875d('0x1a08')](_0x44b4bd,_0x531fbf)),_0x2cfb05()[_0x4b875d('0xcc3')](_0x50d91b[_0x4b875d('0x24b7')][_0x44b4bd['id']],_0x2cfb05()[_0x4b875d('0x1a08')](_0x44b4bd,_0x531fbf)),_0x44b4bd[_0x4b875d('0x3dc')]&&(_0x50d91b[_0x4b875d('0x1f7e')][_0x44b4bd['id']][_0x4b875d('0x25b3')]=_0x44b4bd[_0x4b875d('0x3dc')],_0x50d91b[_0x4b875d('0x24b7')][_0x44b4bd['id']][_0x4b875d('0x25b3')]=_0x44b4bd[_0x4b875d('0x3dc')]),_0x2f60e7(_0x50d91b['agents'][_0x44b4bd['id']]));}function _0x229c5e(_0x50ae3b){const _0x1b2e46=_0x3e98ce;_0x50d91b['agents'][_0x50d91b[_0x1b2e46('0x4c4')][_0x50ae3b['destaccountcode']]]&&(_0x2cfb05()[_0x1b2e46('0xcc3')](_0x50d91b[_0x1b2e46('0x1f7e')][_0x50d91b[_0x1b2e46('0x4c4')][_0x50ae3b[_0x1b2e46('0x25fc')]]],_0x2cfb05()['pick'](_0x50ae3b,[_0x1b2e46('0x1d3e'),'destconnectedlinenum'])),_0x2cfb05()[_0x1b2e46('0xcc3')](_0x50d91b[_0x1b2e46('0x24b7')][_0x50d91b['agentInternal'][_0x50ae3b[_0x1b2e46('0x25fc')]]],_0x2cfb05()[_0x1b2e46('0x1a08')](_0x50ae3b,[_0x1b2e46('0x1d3e'),_0x1b2e46('0x1ad2')])));}function _0x53a5c2(_0x4e491c){const _0x2e8ccf=_0x3e98ce;_0x50d91b[_0x2e8ccf('0x1f7e')][_0x50d91b[_0x2e8ccf('0x4c4')][_0x4e491c[_0x2e8ccf('0x25fc')]]]&&(_0x50d91b[_0x2e8ccf('0x1f7e')][_0x50d91b[_0x2e8ccf('0x4c4')][_0x4e491c['destaccountcode']]]=_0x2cfb05()[_0x2e8ccf('0x1414')](_0x50d91b[_0x2e8ccf('0x1f7e')][_0x50d91b[_0x2e8ccf('0x4c4')][_0x4e491c['destaccountcode']]],[_0x2e8ccf('0x1d3e'),_0x2e8ccf('0x1ad2')]),_0x50d91b[_0x2e8ccf('0x24b7')][_0x50d91b[_0x2e8ccf('0x4c4')][_0x4e491c[_0x2e8ccf('0x25fc')]]]=_0x2cfb05()[_0x2e8ccf('0x1414')](_0x50d91b[_0x2e8ccf('0x24b7')][_0x50d91b[_0x2e8ccf('0x4c4')][_0x4e491c['destaccountcode']]],['queue','destconnectedlinenum']));}function _0x3e7126(_0x5678e0){const _0x5f1dca=_0x3e98ce;return _0x238f0e[_0x5f1dca('0x557')]['logout']({'id':_0x5678e0['id'],'device':_0x5f1dca('0xf01'),'agent_id':_0x5678e0['id'],'agent_name':_0x5678e0['name']})[_0x5f1dca('0xa44')][_0x5f1dca('0x1166')](function(){const _0x32ba74=_0x5f1dca;_0x3abbb0['success']({'title':_0x32ba74('0x16a7'),'msg':_0x5678e0[_0x32ba74('0x6e1')]+'\x20\x20properly\x20logout'}),_0x50d91b[_0x32ba74('0x1f7e')][_0x5678e0['id']]&&(_0x50d91b[_0x32ba74('0x1f7e')][_0x5678e0['id']][_0x32ba74('0xb41')]=![]),_0x50d91b[_0x32ba74('0x24b7')][_0x5678e0['id']]&&(_0x50d91b[_0x32ba74('0x24b7')][_0x5678e0['id']]['online']=![]),_0x3b6398();})[_0x5f1dca('0x1a80')](function(_0x199f1d){const _0x223360=_0x5f1dca;_0x3abbb0['error']({'title':_0x199f1d[_0x223360('0x52d')]?_0x223360('0x1e21')+_0x199f1d[_0x223360('0x52d')]+'\x20-\x20'+_0x199f1d[_0x223360('0xe1b')]:_0x223360('0x1e3c'),'msg':_0x199f1d[_0x223360('0x25f4')]?JSON[_0x223360('0xbac')](_0x199f1d[_0x223360('0x25f4')][_0x223360('0x1e70')]):_0x199f1d['toString']()});});}function _0x1ececc(_0xc4fa82,_0x3c60a4){const _0x23161c=_0x3e98ce;return _0x238f0e[_0x23161c('0x557')][_0x23161c('0x1e77')]({'id':_0xc4fa82['id'],'type':_0x3c60a4})[_0x23161c('0xa44')]['then'](function(_0x2c8bc7){const _0x23399d=_0x23161c;_0x50d91b[_0x23399d('0x1f7e')][_0xc4fa82['id']]&&_0x2cfb05()[_0x23399d('0xcc3')](_0x50d91b[_0x23399d('0x1f7e')][_0xc4fa82['id']],_0x2cfb05()[_0x23399d('0x1a08')](_0x2c8bc7,_0x531fbf)),_0x50d91b[_0x23399d('0x24b7')][_0xc4fa82['id']]&&_0x2cfb05()['merge'](_0x50d91b[_0x23399d('0x24b7')][_0xc4fa82['id']],_0x2cfb05()['pick'](_0x2c8bc7,_0x531fbf)),_0x2f60e7(_0x50d91b[_0x23399d('0x1f7e')][_0xc4fa82['id']]);})['catch'](function(_0x4d5413){const _0x3e83c9=_0x23161c;_0x3abbb0[_0x3e83c9('0xfc9')]({'title':_0x4d5413[_0x3e83c9('0x52d')]?_0x3e83c9('0x1e21')+_0x4d5413[_0x3e83c9('0x52d')]+'\x20-\x20'+_0x4d5413[_0x3e83c9('0xe1b')]:'api.staff.save','msg':_0x4d5413[_0x3e83c9('0x25f4')]?JSON['stringify'](_0x4d5413[_0x3e83c9('0x25f4')][_0x3e83c9('0x1e70')]):_0x4d5413['toString']()});});}function _0x3f3eae(_0x2e1bd6){const _0x53387d=_0x3e98ce;return _0x238f0e[_0x53387d('0x557')][_0x53387d('0x20eb')]({'id':_0x2e1bd6['id']})[_0x53387d('0xa44')][_0x53387d('0x1166')](function(_0x20073e){const _0x4ad1ed=_0x53387d;_0x50d91b[_0x4ad1ed('0x1f7e')][_0x2e1bd6['id']]&&_0x2cfb05()[_0x4ad1ed('0xcc3')](_0x50d91b['agents'][_0x2e1bd6['id']],_0x2cfb05()[_0x4ad1ed('0x1a08')](_0x20073e,_0x531fbf)),_0x50d91b[_0x4ad1ed('0x24b7')][_0x2e1bd6['id']]&&_0x2cfb05()[_0x4ad1ed('0xcc3')](_0x50d91b[_0x4ad1ed('0x24b7')][_0x2e1bd6['id']],_0x2cfb05()['pick'](_0x20073e,_0x531fbf)),_0x2f60e7(_0x50d91b[_0x4ad1ed('0x1f7e')][_0x2e1bd6['id']]);})['catch'](function(_0x5234e8){const _0x37edac=_0x53387d;_0x3abbb0[_0x37edac('0xfc9')]({'title':_0x5234e8['status']?'API:'+_0x5234e8['status']+_0x37edac('0x11e1')+_0x5234e8['statusText']:_0x37edac('0x1e3c'),'msg':_0x5234e8[_0x37edac('0x25f4')]?JSON['stringify'](_0x5234e8[_0x37edac('0x25f4')]['message']):_0x5234e8[_0x37edac('0x1586')]()});});}function _0x318904(_0x2a5119){const _0x8d7bdd=_0x3e98ce;_0x5519e0[_0x8d7bdd('0x1f80')](_0x5519e0[_0x8d7bdd('0x31d')]()[_0x8d7bdd('0x2339')](!![])[_0x8d7bdd('0xcdc')](_0x8d7bdd('0x58a'))[_0x8d7bdd('0xf3c')](_0x8d7bdd('0x1174'))['ok']('Ok')[_0x8d7bdd('0x203b')](_0x2a5119));}function _0x31fbd1(_0x2e1503,_0x16b3d9){const _0xe0d4c4=_0x3e98ce;_0x5519e0['show']({'controller':_0xe0d4c4('0xf19'),'controllerAs':'vm','templateUrl':_0x49c5be,'parent':angular['element'](_0xf30ca3[_0xe0d4c4('0x8d2')]),'targetEvent':_0x16b3d9,'clickOutsideToClose':!![],'locals':{'agent':_0x2e1503,'agents':[],'channel':_0xe0d4c4('0x1bfa'),'direction':_0xe0d4c4('0x14d8'),'crudPermissions':_0x50d91b[_0xe0d4c4('0x243c')]}});}function _0x327409(_0x31a948){return _0x31a948==='pause'||_0x31a948==='*pause';}function _0x1c4c8c(_0x268dfe){const _0x4294e6=_0x3e98ce;return _0x268dfe===_0x4294e6('0x1e77');}function _0x15d9c8(_0x1e8597){return _0x1e8597==='*pause';}function _0x3b33b0(_0x6ce4f4){const _0x2a64ce=_0x3e98ce;return _0x6ce4f4==='idle'||_0x6ce4f4===_0x2a64ce('0x22d5')||_0x6ce4f4==='unavailable'||_0x6ce4f4===_0x2a64ce('0x1628')||_0x2cfb05()[_0x2a64ce('0x2863')](_0x6ce4f4);}function _0x3f3a80(_0x4b13ea,_0x175809){const _0x11838d=_0x3e98ce;if(_0x175809===_0x11838d('0x21da')){if(_0x4b13ea[_0x175809+_0x11838d('0x28f6')]!==_0x11838d('0xdb0'))return _0x4b13ea[_0x175809+_0x11838d('0x28f6')];if(_0x4b13ea[_0x175809+'Pause'])return _0x4b13ea[_0x175809+_0x11838d('0x28f6')]=_0x11838d('0x1e77'),_0x11838d('0x1e77');return'idle';}else{if(_0x4b13ea[_0x175809+_0x11838d('0x108')])return _0x4b13ea[_0x175809+_0x11838d('0x28f6')]=_0x11838d('0x1e77'),_0x11838d('0x1e77');return _0x4b13ea[_0x175809+_0x11838d('0x28f6')];}}function _0x2f60e7(_0x2427a8){const _0x36c609=_0x3e98ce;let _0x43cf89=_0x36c609('0x22d5');if(_0x2cfb05()['every']([_0x3f3a80(_0x2427a8,'voice'),_0x3f3a80(_0x2427a8,_0x36c609('0xde2')),_0x3f3a80(_0x2427a8,_0x36c609('0x1bfa')),_0x3f3a80(_0x2427a8,_0x36c609('0x26c')),_0x3f3a80(_0x2427a8,'sms'),_0x3f3a80(_0x2427a8,'whatsapp'),_0x3f3a80(_0x2427a8,'fax')],_0x327409))_0x43cf89=_0x36c609('0x1e77');else{if(_0x2cfb05()[_0x36c609('0x1798')]([_0x3f3a80(_0x2427a8,_0x36c609('0x21da')),_0x3f3a80(_0x2427a8,'chat'),_0x3f3a80(_0x2427a8,_0x36c609('0x1bfa')),_0x3f3a80(_0x2427a8,_0x36c609('0x26c')),_0x3f3a80(_0x2427a8,_0x36c609('0x146c')),_0x3f3a80(_0x2427a8,'whatsapp'),_0x3f3a80(_0x2427a8,_0x36c609('0x1fc7'))],_0x327409))_0x43cf89='*pause';else _0x2cfb05()['every']([_0x3f3a80(_0x2427a8,_0x36c609('0x21da')),_0x3f3a80(_0x2427a8,_0x36c609('0xde2')),_0x3f3a80(_0x2427a8,_0x36c609('0x1bfa')),_0x3f3a80(_0x2427a8,_0x36c609('0x26c')),_0x3f3a80(_0x2427a8,_0x36c609('0x146c')),_0x3f3a80(_0x2427a8,_0x36c609('0x116e')),_0x3f3a80(_0x2427a8,_0x36c609('0x1fc7'))],_0x3b33b0)?_0x43cf89=_0x36c609('0xdb0'):_0x43cf89='busy';}_0x2427a8[_0x36c609('0xe34')]!==_0x43cf89&&(_0x2427a8[_0x36c609('0xe34')]=_0x43cf89,_0x2427a8['init']?(_0x2427a8[_0x36c609('0x24d5')]=![],_0x2427a8[_0x36c609('0x25b3')]=_0x327409(_0x43cf89)?_0x2cfb05()[_0x36c609('0xa53')](_0x24273b()(_0x2427a8[_0x36c609('0x3dc')])[_0x36c609('0x128a')]('x')):_0x2cfb05()[_0x36c609('0x28bc')]([_0x2427a8[_0x36c609('0x18c9')],_0x2427a8[_0x36c609('0x1507')],_0x2427a8['mailStatusTime'],_0x2427a8[_0x36c609('0x2357')],_0x2427a8[_0x36c609('0x11a8')],_0x2427a8[_0x36c609('0x43e')],_0x2427a8['faxStatusTime']])):_0x2427a8[_0x36c609('0x25b3')]=_0x2cfb05()[_0x36c609('0xa53')](_0x24273b()()[_0x36c609('0x128a')]('x')));}function _0x475394(_0x14b7f9){const _0x89a33=_0x3e98ce,_0x4d7d01=_0x2cfb05()['startsWith'](_0x50d91b['query'][_0x89a33('0xa99')],'-')?'desc':_0x89a33('0x17d');return _0x2cfb05()['orderBy'](_0x14b7f9,[_0x50d91b[_0x89a33('0x2218')][_0x89a33('0xa99')][_0x89a33('0xf3')]('-','')],[_0x4d7d01]);}function _0x1a837c(){_0x3607a0&&(_0x183864['cancel'](_0x3607a0),_0x3607a0=null);}function _0x5001a1(_0x5b4aad,_0x38e464){const _0x14112c=_0x3e98ce;return _0x238f0e[_0x14112c('0x557')]['update']({'id':_0x5b4aad['id']},{'screenrecording':_0x38e464})[_0x14112c('0xa44')][_0x14112c('0x1a80')](function(_0x3f0db5){const _0x2b79b5=_0x14112c;_0x3abbb0[_0x2b79b5('0xfc9')]({'title':_0x3f0db5[_0x2b79b5('0x52d')]?_0x2b79b5('0x1e21')+_0x3f0db5['status']+_0x2b79b5('0x11e1')+_0x3f0db5['statusText']:'api.user.update','msg':_0x3f0db5[_0x2b79b5('0x25f4')]?JSON['stringify'](_0x3f0db5[_0x2b79b5('0x25f4')][_0x2b79b5('0x1e70')]):_0x3f0db5[_0x2b79b5('0x1586')]()});});}_0x28f096[_0x3e98ce('0x3d2')](_0x3e98ce('0x1c3f'),function(){const _0x1e6f92=_0x3e98ce;_0x5b2e3e[_0x1e6f92('0x1800')](_0x1e6f92('0x26b2')),_0x5b2e3e['removeAllListeners']('user:update'),_0x5b2e3e[_0x1e6f92('0x1800')](_0x1e6f92('0x10fc')),_0x5b2e3e[_0x1e6f92('0x1800')](_0x1e6f92('0x1c99')),_0x1a837c();});}const _0x69a3b=_0x50efab,_0x195a4f=_0x2734b2['p']+_0x36e6f4('0x1e96'),_0x58bfc2=_0x2734b2['p']+_0x36e6f4('0x6fb');_0x25008b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$q','$document',_0x36e6f4('0x10eb'),_0x36e6f4('0x7a7'),_0x36e6f4('0x744'),'api',_0x36e6f4('0x2661'),'toasty',_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x21ef')];function _0x25008b(_0x360e80,_0x36ce3e,_0x27b8de,_0xdc5919,_0x5aff88,_0xbf34e,_0x96af9a,_0x549e34,_0x391d60,_0xdd50e1,_0x4b0765,_0x4bb16f,_0x10dec3,_0x1f1ef4){const _0x1c7801=_0x36e6f4,_0x29d497=this,_0x124fc2=[_0x1c7801('0x1570'),_0x1c7801('0x44b'),'waiting','talking',_0x1c7801('0x67d'),'originated',_0x1c7801('0x1e70'),'dialActive',_0x1c7801('0x20ae'),_0x1c7801('0x14c4'),_0x1c7801('0x18b')];_0x29d497[_0x1c7801('0x98')]=_0x1f1ef4[_0x1c7801('0x26cd')](),_0x29d497[_0x1c7801('0x240f')]=_0x96af9a[_0x1c7801('0x240f')]?_0x96af9a[_0x1c7801('0x240f')]:0x0,_0x29d497[_0x1c7801('0x7a7')]=_0x96af9a?_0x2cfb05()[_0x1c7801('0x155c')](_0x96af9a[_0x1c7801('0x269a')]?_0x96af9a[_0x1c7801('0x269a')]:[],'id'):{},_0x29d497[_0x1c7801('0x744')]=_0x549e34?_0x2cfb05()[_0x1c7801('0x155c')](_0x549e34['rows']?_0x549e34[_0x1c7801('0x269a')]:[],'id'):{},_0x29d497[_0x1c7801('0x7f')]=_0x4bb16f,_0x29d497[_0x1c7801('0x17aa')]=_0x10dec3&&_0x10dec3[_0x1c7801('0x240f')]==0x1?_0x10dec3[_0x1c7801('0x269a')][0x0]:null,_0x29d497[_0x1c7801('0x243c')]=_0x1f1ef4[_0x1c7801('0xd87')](_0x29d497[_0x1c7801('0x17aa')]?_0x29d497[_0x1c7801('0x17aa')][_0x1c7801('0x243c')]:null);_0x1f1ef4[_0x1c7801('0x1ac6')](_0x1c7801('0xa7c'))?_0x29d497[_0x1c7801('0x2218')]={'type':'inbound','sort':_0x1c7801('0x14dc'),'limit':0xa,'page':0x1}:_0x29d497[_0x1c7801('0x2218')]={'id':_0x29d497[_0x1c7801('0x98')]['id'],'channel':_0x1c7801('0x1bfa'),'type':_0x1c7801('0x14d8'),'sort':'-updatedAt','limit':0xa,'page':0x1};_0x29d497[_0x1c7801('0x103b')]=_0x12ead3,_0x29d497['getQueues']=_0x323689,_0x29d497[_0x1c7801('0x2840')]=_0x2eb20f,_0x29d497[_0x1c7801('0x33f')]=_0x5b4bfa,_0x29d497['updateQueue']=_0x23be4b,_0x29d497['onSave']=_0x467896,_0x29d497[_0x1c7801('0xfb')]=_0x554d2f,_0x29d497['onRemoveMember']=_0x10a3ce,_0x29d497[_0x1c7801('0x212c')]=_0x158001,_0x29d497[_0x1c7801('0xb9a')]=_0x1fbd49,_0x29d497[_0x1c7801('0x1696')]=_0x35c4f8,_0x29d497[_0x1c7801('0x1089')]=_0x124951,_0x29d497[_0x1c7801('0xa99')]=[],_0x2cfb05()[_0x1c7801('0x941')](_0x29d497['queues'],function(_0x45e342){const _0x210cc3=_0x1c7801;_0x29d497['order'][_0x210cc3('0x1514')](_0x45e342['id']);}),_0xdd50e1['on']('mail_queue:save',_0x29d497[_0x1c7801('0x1303')]),_0xdd50e1['on'](_0x1c7801('0x11b2'),_0x29d497['onSaveMember']),_0xdd50e1['on']('userMailQueue:remove',_0x29d497[_0x1c7801('0xfe9')]),_0xdd50e1['on'](_0x1c7801('0x19d5'),_0x29d497['onPause']),_0xdd50e1['on'](_0x1c7801('0x25f0'),_0x29d497[_0x1c7801('0x1696')]),_0xdd50e1['on'](_0x1c7801('0x663'),_0x29d497[_0x1c7801('0xb9a')]);function _0x124951(){const _0x459aea=_0x1c7801,_0x33c984=[];return _0x2cfb05()['forIn'](_0x29d497[_0x459aea('0x7a7')],function(_0x3ae3e9,_0x426a3e){const _0x5d7cd6=_0x459aea;_0x3ae3e9[_0x5d7cd6('0x18b')]=0x0,_0x3ae3e9[_0x5d7cd6('0x2689')]=0x0,_0x29d497[_0x5d7cd6('0x7a7')][_0x426a3e][_0x5d7cd6('0x1f7e')]={},_0x33c984[_0x5d7cd6('0x1514')](_0x391d60[_0x5d7cd6('0x24c9')][_0x5d7cd6('0x27d1')]({'id':_0x426a3e})[_0x5d7cd6('0xa44')]),_0x29d497[_0x5d7cd6('0x744')][_0x426a3e]&&_0x2cfb05()[_0x5d7cd6('0xcc3')](_0x3ae3e9,_0x2cfb05()[_0x5d7cd6('0x1a08')](_0x29d497['rpcQueues'][_0x426a3e],_0x124fc2));}),_0xdc5919[_0x459aea('0x2760')](_0x33c984)[_0x459aea('0x1166')](function(_0x4ce0b3){const _0x22e462=_0x459aea;for(let _0x2732fa=0x0;_0x2732fa<_0x4ce0b3[_0x22e462('0x264b')];_0x2732fa+=0x1){for(let _0x4c40e6=0x0;_0x4c40e6<_0x4ce0b3[_0x2732fa][_0x22e462('0x269a')]['length'];_0x4c40e6++){_0x4ce0b3[_0x2732fa][_0x22e462('0x269a')][_0x4c40e6][_0x22e462('0x18b')]&&_0x29d497['queues'][_0x4ce0b3[_0x2732fa][_0x22e462('0x269a')][_0x4c40e6]['MailQueueId']][_0x22e462('0x18b')]++,_0x29d497[_0x22e462('0x7a7')][_0x4ce0b3[_0x2732fa][_0x22e462('0x269a')][_0x4c40e6]['MailQueueId']][_0x22e462('0x2689')]++,_0x29d497['queues'][_0x4ce0b3[_0x2732fa][_0x22e462('0x269a')][_0x4c40e6][_0x22e462('0x1a29')]][_0x22e462('0x1f7e')][_0x4ce0b3[_0x2732fa][_0x22e462('0x269a')][_0x4c40e6][_0x22e462('0x122a')]]=_0x4ce0b3[_0x2732fa][_0x22e462('0x269a')][_0x4c40e6][_0x22e462('0x1a29')];}}})['catch'](function(_0x481a3f){const _0x4e24ac=_0x459aea;console[_0x4e24ac('0xfc9')](_0x481a3f);});}function _0x467896(_0x5a76c3){const _0x1d852b=_0x1c7801;_0x29d497[_0x1d852b('0x7a7')][_0x5a76c3['id']]&&_0x2cfb05()['merge'](_0x29d497[_0x1d852b('0x7a7')][_0x5a76c3['id']],_0x2cfb05()['pick'](_0x5a76c3,_0x124fc2));}function _0x554d2f(_0x45b673){const _0xaca9b3=_0x1c7801;_0x29d497[_0xaca9b3('0x7a7')][_0x45b673['MailQueueId']]&&_0x29d497[_0xaca9b3('0x7a7')][_0x45b673[_0xaca9b3('0x1a29')]][_0xaca9b3('0x2689')]++;}function _0x10a3ce(_0x76314a){const _0x365647=_0x1c7801;_0x29d497[_0x365647('0x7a7')][_0x76314a['MailQueueId']]&&_0x29d497[_0x365647('0x7a7')][_0x76314a[_0x365647('0x1a29')]][_0x365647('0x2689')]--;}function _0x158001(_0x4769c9){const _0x2329a8=_0x1c7801;console[_0x2329a8('0x455')]('onPause',_0x4769c9);if(_0x4769c9[_0x2329a8('0x2540')])_0x2cfb05()[_0x2329a8('0x941')](_0x29d497[_0x2329a8('0x7a7')],function(_0xdf35a9){const _0x259bb0=_0x2329a8;_0xdf35a9[_0x259bb0('0x1f7e')][_0x4769c9['id']]&&(_0xdf35a9[_0x259bb0('0x18b')]+=0x1,console[_0x259bb0('0x455')](_0x259bb0('0x1e77')));});else!_0x4769c9[_0x2329a8('0x2540')]&&_0x2cfb05()['forIn'](_0x29d497[_0x2329a8('0x7a7')],function(_0x52d0b8){const _0x56671a=_0x2329a8;_0x52d0b8[_0x56671a('0x1f7e')][_0x4769c9['id']]&&(_0x52d0b8[_0x56671a('0x18b')]>0x0&&(_0x52d0b8[_0x56671a('0x18b')]-=0x1,console[_0x56671a('0x455')](_0x56671a('0x20eb'))));});}function _0x1fbd49(_0x2ec532){const _0x44af5e=_0x1c7801;console[_0x44af5e('0x455')]('onLogged',_0x2ec532),_0x29d497[_0x44af5e('0x7a7')][_0x2ec532[_0x44af5e('0x1a29')]]&&(_0x29d497[_0x44af5e('0x7a7')][_0x2ec532[_0x44af5e('0x1a29')]][_0x44af5e('0x2689')]+=0x1,_0x29d497['queues'][_0x2ec532[_0x44af5e('0x1a29')]]['agents'][_0x2ec532['UserId']]=_0x2ec532['MailQueueId']);}function _0x35c4f8(_0x11609b){const _0x19cefc=_0x1c7801;console[_0x19cefc('0x455')](_0x19cefc('0x1696'),_0x11609b),_0x29d497['queues'][_0x11609b['MailQueueId']]&&_0x29d497[_0x19cefc('0x7a7')][_0x11609b['MailQueueId']][_0x19cefc('0x2689')]>0x0&&(_0x29d497[_0x19cefc('0x7a7')][_0x11609b[_0x19cefc('0x1a29')]][_0x19cefc('0x2689')]-=0x1,delete _0x29d497['queues'][_0x11609b[_0x19cefc('0x1a29')]][_0x19cefc('0x1f7e')][_0x11609b[_0x19cefc('0x122a')]]);}let _0xfb21a7=!![],_0x442697=0x1;_0x360e80['$watch']('vm.query.filter',function(_0xd1d431,_0x43e9cb){const _0x54a6a1=_0x1c7801;_0xfb21a7?_0x36ce3e(function(){_0xfb21a7=![];}):(!_0x43e9cb&&(_0x442697=_0x29d497[_0x54a6a1('0x2218')][_0x54a6a1('0x1a43')]),_0xd1d431!==_0x43e9cb&&(_0x29d497['query'][_0x54a6a1('0x1a43')]=0x1),!_0xd1d431&&(_0x29d497[_0x54a6a1('0x2218')][_0x54a6a1('0x1a43')]=_0x442697),_0x29d497['getQueues']());});function _0x12ead3(_0x1018b5){const _0x2d4c72=_0x1c7801;_0x29d497[_0x2d4c72('0x240f')]=_0x1018b5[_0x2d4c72('0x240f')],_0x29d497[_0x2d4c72('0x7a7')]=_0x1018b5?_0x2cfb05()['keyBy'](_0x1018b5[_0x2d4c72('0x269a')]?_0x1018b5[_0x2d4c72('0x269a')]:[],'id'):{};if(_0x1018b5[_0x2d4c72('0x269a')]){_0x29d497[_0x2d4c72('0xa99')]=[];for(let _0x173a7e=0x0;_0x173a7e<_0x1018b5[_0x2d4c72('0x269a')][_0x2d4c72('0x264b')];_0x173a7e++){_0x29d497[_0x2d4c72('0xa99')]['push'](_0x1018b5['rows'][_0x173a7e]['id']);}}_0x124951();}function _0x323689(){const _0x4ae9bc=_0x1c7801;_0x29d497['query'][_0x4ae9bc('0x1098')]=(_0x29d497[_0x4ae9bc('0x2218')][_0x4ae9bc('0x1a43')]-0x1)*_0x29d497[_0x4ae9bc('0x2218')][_0x4ae9bc('0x163f')],_0x1f1ef4[_0x4ae9bc('0x1ac6')](_0x4ae9bc('0xa7c'))?_0x29d497[_0x4ae9bc('0x1f48')]=_0x391d60[_0x4ae9bc('0x24c9')][_0x4ae9bc('0xd83')](_0x29d497[_0x4ae9bc('0x2218')],_0x12ead3)['$promise']:(_0x29d497[_0x4ae9bc('0x2218')]['id']=_0x29d497['userProfile']['id'],_0x29d497[_0x4ae9bc('0x2218')][_0x4ae9bc('0xe60')]=_0x4ae9bc('0x5f8'),_0x29d497[_0x4ae9bc('0x1f48')]=_0x391d60[_0x4ae9bc('0x7f')]['getResources'](_0x29d497[_0x4ae9bc('0x2218')],_0x12ead3)['$promise']);}function _0x2eb20f(_0x474da0,_0x49d007){const _0x2add8c=_0x1c7801;_0x27b8de[_0x2add8c('0x1f80')]({'controller':_0x2add8c('0xc1c'),'controllerAs':'vm','templateUrl':_0x195a4f,'parent':angular['element'](_0x5aff88[_0x2add8c('0x8d2')]),'targetEvent':_0x474da0,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x49d007,'mailQueues':_0x2cfb05()[_0x2add8c('0x1ac1')](_0x29d497[_0x2add8c('0x7a7')]),'license':null,'setting':null,'crudPermissions':_0x29d497[_0x2add8c('0x243c')]}});}function _0x5b4bfa(_0x24156b,_0x3bb50f){const _0x3b0c63=_0x1c7801;_0x27b8de[_0x3b0c63('0x1f80')]({'controller':_0x3b0c63('0x4f6'),'controllerAs':'vm','templateUrl':_0x58bfc2,'parent':angular['element'](_0x5aff88[_0x3b0c63('0x8d2')]),'targetEvent':_0x24156b,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x3bb50f,'mailQueues':_0x29d497[_0x3b0c63('0x7a7')]?_0x29d497[_0x3b0c63('0x7a7')][_0x3b0c63('0x269a')]:[],'realtime':![],'crudPermissions':_0x29d497[_0x3b0c63('0x243c')]}});}function _0x23be4b(_0x4eb10a){const _0xadc0c4=_0x1c7801;return _0x391d60[_0xadc0c4('0x24c9')][_0xadc0c4('0x1449')](_0x4eb10a)[_0xadc0c4('0xa44')][_0xadc0c4('0x1166')](function(){const _0xbc901a=_0xadc0c4;_0x4b0765[_0xbc901a('0x103b')]({'title':_0xbc901a('0x75b'),'msg':_0x4eb10a[_0xbc901a('0x4f0')]?_0x4eb10a[_0xbc901a('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0xadc0c4('0x1a80')](function(_0x18614d){const _0x159beb=_0xadc0c4;_0x4b0765[_0x159beb('0xfc9')]({'title':_0x159beb('0xa98'),'msg':_0x18614d[_0x159beb('0x1e70')]});});}_0x360e80['$on'](_0x1c7801('0x1c3f'),function(){const _0x581fc4=_0x1c7801;_0xdd50e1[_0x581fc4('0x1800')](_0x581fc4('0x2056')),_0xdd50e1[_0x581fc4('0x1800')](_0x581fc4('0x5a')),_0xdd50e1[_0x581fc4('0x1800')]('userMailQueue:save'),_0xdd50e1[_0x581fc4('0x1800')](_0x581fc4('0x19d5')),_0xdd50e1[_0x581fc4('0x1800')](_0x581fc4('0x25f0')),_0xdd50e1[_0x581fc4('0x1800')](_0x581fc4('0x663'));});}const _0x59ea03=_0x25008b;function _0x57e31a(){const _0x135fa0=_0x36e6f4;return{'status':{'registered':'green-300-fg\x20icon-checkbox-marked-circle','unregistered':_0x135fa0('0x278f'),'lagged':'red-300-fg\x20icon-close-circle','reachable':_0x135fa0('0x23ca'),'unreachable':'red-300-fg\x20icon-close-circle','unknown':_0x135fa0('0x2125')},'state':{'unknown':_0x135fa0('0x1d48'),'not_inuse':'green-300-fg\x20icon-phone-hangup','inuse':_0x135fa0('0xa2f'),'busy':_0x135fa0('0x18d2'),'invalid':_0x135fa0('0x1d48'),'unavailable':_0x135fa0('0x1d48'),'ringing':_0x135fa0('0x132c'),'ringinuse':_0x135fa0('0x132c'),'onhold':_0x135fa0('0x23d9')},'channelStatus':{'ring':_0x135fa0('0x132c'),'up':'green-300-fg\x20icon-phone-in-talk','hangup':'red-300-fg\x20icon-phone-hangup'},'channelStatusOut':{'ring':'blue-300-fg\x20icon-phone-outgoing','up':_0x135fa0('0x20b2'),'hangup':_0x135fa0('0x9e3')}};}const _0x38677c=_0x57e31a;_0x1e083d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x2661')];function _0x1e083d(_0x5cbcf4,_0x24fe18,_0x497db0){const _0x499bc7=_0x36e6f4,_0x31a4d2=this;_0x497db0['disconnect'](),_0x497db0[_0x499bc7('0x7bb')](),_0x31a4d2[_0x499bc7('0x2669')]=0x0;switch(_0x24fe18['current'][_0x499bc7('0x4f0')]){case _0x499bc7('0xd13'):_0x31a4d2[_0x499bc7('0x2669')]=0x0;break;case _0x499bc7('0x1ccd'):_0x31a4d2[_0x499bc7('0x2669')]=0x1;break;case _0x499bc7('0xbfa'):_0x31a4d2[_0x499bc7('0x2669')]=0x2;break;default:_0x31a4d2[_0x499bc7('0x2669')]=0x0,_0x24fe18['go']('app.mail.realtime.agents');}_0x5cbcf4[_0x499bc7('0xe83')]('vm.selectedTab',function(_0x4586a9,_0x1b236a){if(_0x4586a9!==_0x1b236a)switch(_0x4586a9){case 0x0:_0x24fe18['go']('app.mail.realtime.agents');break;case 0x1:_0x24fe18['go']('app.mail.realtime.queues');break;case 0x2:_0x24fe18['go']('app.mail.realtime.accounts');break;default:_0x24fe18['go']('app.mail.realtime.agents');}});}const _0x5469c5=_0x1e083d;_0x3b3e5e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x3b3e5e(_0x13c9ce){const _0x1ae64d=_0x36e6f4;_0x13c9ce[_0x1ae64d('0x63f')](_0x1ae64d('0x26ba'),{'url':_0x1ae64d('0x1c2e'),'views':{'content@app':{'templateUrl':_0x53f1c5,'controller':_0x1ae64d('0x24c2')}},'resolve':{'userProfile':[_0x1ae64d('0x1fbc'),_0x1ae64d('0x21ef'),function(_0x2aba17,_0x320788){const _0x274f48=_0x1ae64d;return _0x320788[_0x274f48('0x1ac6')](_0x274f48('0xa7c'))?null:_0x2aba17['resolve']('userProfile@get',{'fields':_0x274f48('0x686'),'id':_0x320788[_0x274f48('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x1ae64d('0x1fbc'),_0x1ae64d('0x21ef'),function(_0x57c85c,_0x35c66c){const _0x406992=_0x1ae64d;return _0x35c66c[_0x406992('0x1ac6')](_0x406992('0xa7c'))?null:_0x57c85c[_0x406992('0x18af')](_0x406992('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x35c66c[_0x406992('0x26cd')]()[_0x406992('0xb86')],'sectionId':0x262});}]},'authenticate':!![],'permissionId':0x262})[_0x1ae64d('0x63f')](_0x1ae64d('0xd13'),{'url':_0x1ae64d('0x730'),'controller':_0x1ae64d('0x403'),'templateUrl':_0xa4f315,'resolve':{'pauses':['apiResolver',function(_0x348ffe){return _0x348ffe['resolve']('pause@get',{'nolimit':!![]});}],'agents':['apiResolver',_0x1ae64d('0x21ef'),function(_0x54b4ba,_0x15555d){const _0x1471d9=_0x1ae64d;return _0x15555d['hasRole'](_0x1471d9('0xa7c'))?_0x54b4ba[_0x1471d9('0x18af')](_0x1471d9('0x1c80'),{'fields':_0x1471d9('0x1746'),'role':_0x1471d9('0x1eff'),'sort':_0x1471d9('0x6e1'),'nolimit':!![]}):_0x54b4ba[_0x1471d9('0x18af')](_0x1471d9('0x17c4'),{'id':_0x15555d['getCurrentUser']()[_0x1471d9('0xb86')],'section':_0x1471d9('0x2391'),'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':'agent','sort':_0x1471d9('0x6e1'),'nolimit':!![]});}],'userProfile':[_0x1ae64d('0x1fbc'),_0x1ae64d('0x21ef'),function(_0x57ae2f,_0x3db245){const _0x42f899=_0x1ae64d;return _0x3db245[_0x42f899('0x1ac6')](_0x42f899('0xa7c'))?null:_0x57ae2f[_0x42f899('0x18af')]('userProfile@get',{'fields':_0x42f899('0x686'),'id':_0x3db245[_0x42f899('0x26cd')]()[_0x42f899('0xb86')]});}],'userProfileSection':[_0x1ae64d('0x1fbc'),_0x1ae64d('0x21ef'),function(_0x135bfb,_0x32dbf0){const _0x1fcaf3=_0x1ae64d;return _0x32dbf0['hasRole']('admin')?null:_0x135bfb[_0x1fcaf3('0x18af')](_0x1fcaf3('0xaf'),{'fields':_0x1fcaf3('0xe26'),'userProfileId':_0x32dbf0[_0x1fcaf3('0x26cd')]()[_0x1fcaf3('0xb86')],'sectionId':0xca});}],'rpcAgents':[_0x1ae64d('0x1fbc'),function(_0x7a1d3e){const _0x4f2257=_0x1ae64d;return _0x7a1d3e[_0x4f2257('0x18af')]('rpc@getAgents');}]},'authenticate':!![],'permissionId':0x262})[_0x1ae64d('0x63f')](_0x1ae64d('0x1ccd'),{'url':_0x1ae64d('0x1bd2'),'controller':_0x1ae64d('0x5c8'),'templateUrl':_0x227cc5,'resolve':{'queues':['apiResolver',_0x1ae64d('0x21ef'),function(_0x3e2f15,_0xe19ff9){const _0x489fd5=_0x1ae64d;return _0xe19ff9[_0x489fd5('0x1ac6')]('admin')?_0x3e2f15[_0x489fd5('0x18af')](_0x489fd5('0x13fe'),{'type':'inbound','sort':_0x489fd5('0x14dc'),'limit':0xa,'offset':0x0}):_0x3e2f15[_0x489fd5('0x18af')](_0x489fd5('0x17c4'),{'id':_0xe19ff9[_0x489fd5('0x26cd')]()['userProfileId'],'section':_0x489fd5('0x5f8'),'channel':_0x489fd5('0x1bfa'),'type':_0x489fd5('0x14d8'),'sort':_0x489fd5('0x14dc'),'limit':0xa,'page':0x1});}],'userProfile':[_0x1ae64d('0x1fbc'),_0x1ae64d('0x21ef'),function(_0x3a1957,_0x1f70b5){const _0x50a718=_0x1ae64d;return _0x1f70b5[_0x50a718('0x1ac6')](_0x50a718('0xa7c'))?null:_0x3a1957[_0x50a718('0x18af')](_0x50a718('0x697'),{'fields':'id,name,crudPermissions','id':_0x1f70b5[_0x50a718('0x26cd')]()[_0x50a718('0xb86')]});}],'userProfileSection':[_0x1ae64d('0x1fbc'),_0x1ae64d('0x21ef'),function(_0x426ecf,_0x3be0ca){const _0x4b0adf=_0x1ae64d;return _0x3be0ca[_0x4b0adf('0x1ac6')](_0x4b0adf('0xa7c'))?null:_0x426ecf[_0x4b0adf('0x18af')]('userProfileSection@get',{'fields':_0x4b0adf('0xe26'),'userProfileId':_0x3be0ca[_0x4b0adf('0x26cd')]()['userProfileId'],'sectionId':0x259});}],'rpcQueues':['apiResolver',function(_0x4fabe4){const _0x16934f=_0x1ae64d;return _0x4fabe4[_0x16934f('0x18af')](_0x16934f('0x1ebe'));}]},'authenticate':!![],'permissionId':0x262})[_0x1ae64d('0x63f')](_0x1ae64d('0xbfa'),{'url':_0x1ae64d('0x4c5'),'controller':'MailAccountsRealtimeController\x20as\x20vm','templateUrl':_0x54f859,'resolve':{'mailAccounts':['apiResolver','Auth',function(_0xcf4a26,_0x10f677){const _0x4399de=_0x1ae64d;return _0x10f677[_0x4399de('0x1ac6')](_0x4399de('0xa7c'))?_0xcf4a26[_0x4399de('0x18af')]('mailAccount@get',{'sort':_0x4399de('0x14dc'),'limit':0xa,'offset':0x0}):_0xcf4a26[_0x4399de('0x18af')]('userProfile@getResources',{'id':_0x10f677[_0x4399de('0x26cd')]()[_0x4399de('0xb86')],'section':'MailAccounts','sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':[_0x1ae64d('0x1fbc'),_0x1ae64d('0x21ef'),function(_0x377a4c,_0x78212e){const _0x3d092d=_0x1ae64d;return _0x78212e[_0x3d092d('0x1ac6')](_0x3d092d('0xa7c'))?null:_0x377a4c['resolve'](_0x3d092d('0x697'),{'fields':'id,name,crudPermissions','id':_0x78212e[_0x3d092d('0x26cd')]()[_0x3d092d('0xb86')]});}],'userProfileSection':[_0x1ae64d('0x1fbc'),_0x1ae64d('0x21ef'),function(_0x1c72e6,_0x5e78df){const _0x1c1460=_0x1ae64d;return _0x5e78df[_0x1c1460('0x1ac6')]('admin')?null:_0x1c72e6[_0x1c1460('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5e78df['getCurrentUser']()[_0x1c1460('0xb86')],'sectionId':0x25a});}],'rpcMailAccounts':[_0x1ae64d('0x1fbc'),function(_0x126545){const _0x1698bf=_0x1ae64d;return _0x126545['resolve'](_0x1698bf('0x621'));}]},'authenticate':!![],'permissionId':0x262});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x26ba'),[])[_0x36e6f4('0xe11')](_0x3b3e5e)[_0x36e6f4('0x75e')]('AgentsMailRealtimeController',_0x69a3b)[_0x36e6f4('0x75e')](_0x36e6f4('0x14d9'),_0x59ea03)['factory'](_0x36e6f4('0x1a02'),_0x38677c)['controller']('MailRealtimeController',_0x5469c5);const _0x4054c8=_0x2734b2['p']+'src/js/modules/main/apps/mail/views/mailQueues/mailQueues.html/mailQueues.html',_0x4ffa96=_0x2734b2['p']+'src/js/modules/main/apps/mail/views/mailQueues/edit/view.html/view.html',_0xb5260d=_0x2734b2['p']+_0x36e6f4('0x25f1'),_0x217418=_0x2734b2['p']+_0x36e6f4('0xe2a'),_0xcb7532=_0x2734b2['p']+_0x36e6f4('0xc5b');_0x41aa97[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty','mailAccounts',_0x36e6f4('0x21b9'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x41aa97(_0x267f8e,_0x70c37e,_0x5860d9,_0x40e698,_0x1cd76e,_0x4b1cdb,_0x58907e,_0x208897,_0x5b7860,_0x266762,_0xd2769b,_0x4e8e2,_0x3c6563,_0x5902c5){const _0x32da6f=_0x36e6f4,_0x6e122e=this;_0x6e122e[_0x32da6f('0x98')]=_0xd2769b[_0x32da6f('0x26cd')](),_0x6e122e[_0x32da6f('0x61a')]=[],_0x6e122e[_0x32da6f('0xf8a')]=_0x3c6563,_0x6e122e[_0x32da6f('0x5c9')]=_0x4e8e2,_0x6e122e[_0x32da6f('0x243c')]=_0x5902c5,_0x6e122e[_0x32da6f('0x128b')]={},_0x6e122e[_0x32da6f('0x2900')]=_0x6e122e['setting']&&_0x6e122e['setting'][_0x32da6f('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x6e122e[_0x32da6f('0xcdc')]=_0x32da6f('0x1dc1'),_0x6e122e[_0x32da6f('0x21b9')]=angular[_0x32da6f('0x225f')](_0x5b7860),_0x6e122e['mailAccounts']=_0x208897,_0x6e122e[_0x32da6f('0x15a6')]=![];!_0x6e122e[_0x32da6f('0x21b9')]&&(_0x6e122e['mailAccount']={'active':!![],'cservice':_0x32da6f('0x15d7'),'cauthentication':!![],'fontSize':0xd,'waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0x6e122e[_0x32da6f('0xcdc')]=_0x32da6f('0x1ddd'),_0x6e122e[_0x32da6f('0x15a6')]=!![]);_0x70c37e[_0x32da6f('0x23f')]['id']&&(_0x6e122e[_0x32da6f('0x21b9')][_0x32da6f('0x56')]=_0x70c37e['params']['id']);_0x6e122e[_0x32da6f('0x1760')]=_0x212496,_0x6e122e[_0x32da6f('0x1f99')]=_0x81c788,_0x6e122e[_0x32da6f('0xaf5')]=_0x10aa82,_0x6e122e[_0x32da6f('0x1a9c')]=_0x8795ae,_0x6e122e[_0x32da6f('0x24a0')]=_0xe5fdaf,_0xd2769b[_0x32da6f('0x1ac6')]('admin')?_0x266762[_0x32da6f('0xdd9')][_0x32da6f('0xd83')]({'fields':_0x32da6f('0x1776'),'sort':_0x32da6f('0x4f0')})[_0x32da6f('0xa44')][_0x32da6f('0x1166')](function(_0x1fa126){const _0x9c56b7=_0x32da6f;_0x6e122e[_0x9c56b7('0x8de')]=_0x1fa126[_0x9c56b7('0x269a')]||[];})[_0x32da6f('0x1a80')](function(_0x3b61e1){const _0x3faeaa=_0x32da6f;_0x58907e[_0x3faeaa('0xfc9')]({'title':_0x3b61e1[_0x3faeaa('0x52d')]?_0x3faeaa('0x1e21')+_0x3b61e1[_0x3faeaa('0x52d')]+_0x3faeaa('0x11e1')+_0x3b61e1['statusText']:_0x3faeaa('0x520'),'msg':_0x3b61e1[_0x3faeaa('0x25f4')]?JSON[_0x3faeaa('0xbac')](_0x3b61e1[_0x3faeaa('0x25f4')]):_0x3b61e1[_0x3faeaa('0x1586')]()});}):_0x266762[_0x32da6f('0xdd9')]['get']({'fields':_0x32da6f('0x1776'),'sort':_0x32da6f('0x4f0')})[_0x32da6f('0xa44')][_0x32da6f('0x1166')](function(_0x2b0cb7){_0x6e122e['lists']=_0x2b0cb7['rows']||[];})[_0x32da6f('0x1166')](function(){const _0x18d39b=_0x32da6f;return _0x266762['userProfileSection'][_0x18d39b('0xd83')]({'userProfileId':_0x6e122e[_0x18d39b('0x98')][_0x18d39b('0xb86')],'sectionId':0x12d})[_0x18d39b('0xa44')];})['then'](function(_0x5d52e2){const _0x1b7639=_0x32da6f,_0x3f5f72=_0x5d52e2&&_0x5d52e2['rows']?_0x5d52e2[_0x1b7639('0x269a')][0x0]:null;if(!_0x3f5f72){const _0x3a0c6d=[];let _0x55b62a=null;_0x6e122e[_0x1b7639('0x21b9')]&&(_0x55b62a=_0x2cfb05()[_0x1b7639('0xc38')](_0x6e122e[_0x1b7639('0x8de')],{'id':Number(_0x6e122e[_0x1b7639('0x21b9')][_0x1b7639('0x23c')])}));for(let _0x4e5662=0x0;_0x4e5662<_0x6e122e[_0x1b7639('0x8de')][_0x1b7639('0x264b')];_0x4e5662++){_0x55b62a&&_0x6e122e[_0x1b7639('0x8de')][_0x4e5662]['id']===_0x55b62a['id']&&(_0x6e122e[_0x1b7639('0x8de')][_0x4e5662][_0x1b7639('0x2378')]=![],_0x3a0c6d[_0x1b7639('0x1514')](_0x6e122e[_0x1b7639('0x8de')][_0x4e5662]));}_0x6e122e[_0x1b7639('0x8de')]=_0x3a0c6d;}else{if(!_0x3f5f72[_0x1b7639('0x1a2b')])return _0x266762[_0x1b7639('0x4b5')][_0x1b7639('0xd83')]({'sectionId':_0x3f5f72['id']})[_0x1b7639('0xa44')]['then'](function(_0x187832){const _0x3ef985=_0x1b7639,_0x3d0554=_0x2cfb05()['map'](_0x187832[_0x3ef985('0x269a')],function(_0x579be4){const _0x291735=_0x3ef985;return _0x2cfb05()['find'](_0x6e122e[_0x291735('0x8de')],{'id':_0x579be4[_0x291735('0x24e8')]});});let _0x5eac2e=null;_0x6e122e['mailAccount']&&(_0x5eac2e=_0x2cfb05()[_0x3ef985('0xc38')](_0x6e122e[_0x3ef985('0x8de')],{'id':Number(_0x6e122e[_0x3ef985('0x21b9')][_0x3ef985('0x23c')])}));if(_0x5eac2e&&!_0x2cfb05()[_0x3ef985('0x1798')](_0x3d0554,['id',_0x5eac2e['id']])){const _0x3a018e=_0x2cfb05()['find'](_0x6e122e[_0x3ef985('0x8de')],{'id':_0x5eac2e['id']});_0x3a018e['canSelect']=![],_0x3d0554[_0x3ef985('0x1514')](_0x3a018e);}_0x6e122e[_0x3ef985('0x8de')]=_0x3d0554;});}})['catch'](function(_0x59836c){const _0x419128=_0x32da6f;_0x58907e[_0x419128('0xfc9')]({'title':_0x59836c[_0x419128('0x52d')]?'API:'+_0x59836c[_0x419128('0x52d')]+_0x419128('0x11e1')+_0x59836c[_0x419128('0xe1b')]:'SYSTEM:GETlists','msg':_0x59836c[_0x419128('0x25f4')]?JSON[_0x419128('0xbac')](_0x59836c[_0x419128('0x25f4')]):_0x59836c[_0x419128('0x1586')]()});});function _0x212496(){const _0x4c4c8f=_0x32da6f;_0x6e122e['errors']=[],_0x266762[_0x4c4c8f('0x21b9')][_0x4c4c8f('0x9cc')](_0x6e122e['mailAccount'])[_0x4c4c8f('0xa44')]['then'](function(_0x13df6f){const _0x2a1ed5=_0x4c4c8f;_0x6e122e[_0x2a1ed5('0xf85')][_0x2a1ed5('0x2450')](_0x13df6f[_0x2a1ed5('0x2876')]()),_0x58907e[_0x2a1ed5('0x103b')]({'title':_0x2a1ed5('0x2222'),'msg':_0x6e122e[_0x2a1ed5('0x21b9')][_0x2a1ed5('0x4f0')]?_0x6e122e[_0x2a1ed5('0x21b9')][_0x2a1ed5('0x4f0')]+_0x2a1ed5('0x1eda'):''}),_0xe5fdaf(_0x13df6f);})[_0x4c4c8f('0x1a80')](function(_0xbb7c41){const _0x1bf01c=_0x4c4c8f;if(_0xbb7c41['data']&&_0xbb7c41[_0x1bf01c('0x25f4')]['errors']&&_0xbb7c41['data'][_0x1bf01c('0x61a')][_0x1bf01c('0x264b')]){_0x6e122e[_0x1bf01c('0x61a')]=_0xbb7c41[_0x1bf01c('0x25f4')]['errors']||[{'message':_0xbb7c41['toString'](),'type':_0x1bf01c('0x211b')}];for(let _0x548778=0x0;_0x548778<_0xbb7c41[_0x1bf01c('0x25f4')][_0x1bf01c('0x61a')][_0x1bf01c('0x264b')];_0x548778+=0x1){_0x58907e[_0x1bf01c('0xfc9')]({'title':_0xbb7c41[_0x1bf01c('0x25f4')][_0x1bf01c('0x61a')][_0x548778][_0x1bf01c('0x1345')],'msg':_0xbb7c41[_0x1bf01c('0x25f4')][_0x1bf01c('0x61a')][_0x548778][_0x1bf01c('0x1e70')]});}}else _0x58907e[_0x1bf01c('0xfc9')]({'title':_0xbb7c41[_0x1bf01c('0x52d')]?_0x1bf01c('0x1e21')+_0xbb7c41[_0x1bf01c('0x52d')]+'\x20-\x20'+_0xbb7c41[_0x1bf01c('0xe1b')]:_0x1bf01c('0x211b'),'msg':_0xbb7c41['data']?JSON[_0x1bf01c('0xbac')](_0xbb7c41[_0x1bf01c('0x25f4')][_0x1bf01c('0x1e70')]):_0xbb7c41[_0x1bf01c('0x1586')]()});});}function _0x81c788(){const _0x45b968=_0x32da6f;_0x6e122e['errors']=[],_0x266762[_0x45b968('0x21b9')][_0x45b968('0x1449')]({'id':_0x6e122e[_0x45b968('0x21b9')]['id']},_0x6e122e['mailAccount'])[_0x45b968('0xa44')]['then'](function(_0x19a21c){const _0x42b9f2=_0x45b968,_0x1ccd34=_0x2cfb05()['find'](_0x6e122e['mailAccounts'],{'id':_0x19a21c['id']});_0x1ccd34&&_0x2cfb05()[_0x42b9f2('0xcc3')](_0x1ccd34,_0x2cfb05()[_0x42b9f2('0x1a08')](_0x19a21c[_0x42b9f2('0x2876')](),_0x2cfb05()[_0x42b9f2('0x14a4')](_0x1ccd34))),_0x58907e[_0x42b9f2('0x103b')]({'title':_0x42b9f2('0x15f8'),'msg':_0x6e122e['mailAccount'][_0x42b9f2('0x4f0')]?_0x6e122e[_0x42b9f2('0x21b9')][_0x42b9f2('0x4f0')]+_0x42b9f2('0x7d'):''}),_0xe5fdaf(_0x19a21c);})[_0x45b968('0x1a80')](function(_0x36f8f7){const _0x1edebe=_0x45b968;if(_0x36f8f7[_0x1edebe('0x25f4')]&&_0x36f8f7[_0x1edebe('0x25f4')][_0x1edebe('0x61a')]&&_0x36f8f7[_0x1edebe('0x25f4')][_0x1edebe('0x61a')][_0x1edebe('0x264b')]){_0x6e122e[_0x1edebe('0x61a')]=_0x36f8f7[_0x1edebe('0x25f4')][_0x1edebe('0x61a')]||[{'message':_0x36f8f7['toString'](),'type':_0x1edebe('0x2750')}];for(let _0x31bee3=0x0;_0x31bee3<_0x36f8f7[_0x1edebe('0x25f4')][_0x1edebe('0x61a')][_0x1edebe('0x264b')];_0x31bee3++){_0x58907e[_0x1edebe('0xfc9')]({'title':_0x36f8f7[_0x1edebe('0x25f4')]['errors'][_0x31bee3][_0x1edebe('0x1345')],'msg':_0x36f8f7[_0x1edebe('0x25f4')][_0x1edebe('0x61a')][_0x31bee3][_0x1edebe('0x1e70')]});}}else _0x58907e[_0x1edebe('0xfc9')]({'title':_0x36f8f7['status']?_0x1edebe('0x1e21')+_0x36f8f7['status']+'\x20-\x20'+_0x36f8f7[_0x1edebe('0xe1b')]:'api.mailAccount.update','msg':_0x36f8f7['data']?JSON['stringify'](_0x36f8f7[_0x1edebe('0x25f4')][_0x1edebe('0x1e70')]):_0x36f8f7[_0x1edebe('0x1586')]()});});}function _0x10aa82(_0x585d08){const _0x3a7349=_0x32da6f;if(_0x6e122e[_0x3a7349('0x21b9')][_0x3a7349('0x1725')])return _0x58907e[_0x3a7349('0xfc9')]({'title':'Mail\x20Account\x20not\x20deleted!','msg':_0x3a7349('0xb3b')});_0x6e122e['errors']=[];const _0x37ac61=_0x40e698['confirm']()[_0x3a7349('0xcdc')](_0x3a7349('0x7fb'))[_0x3a7349('0xacc')](_0x3a7349('0x27b4'))[_0x3a7349('0x8e8')]('Delete\x20MailAccount')['ok']('Delete')[_0x3a7349('0x3f')](_0x3a7349('0x497'))[_0x3a7349('0x203b')](_0x585d08);_0x40e698[_0x3a7349('0x1f80')](_0x37ac61)[_0x3a7349('0x1166')](function(){const _0x11464b=_0x3a7349;_0x266762['mailAccount']['delete']({'id':_0x6e122e[_0x11464b('0x21b9')]['id']})['$promise'][_0x11464b('0x1166')](function(){const _0x139da4=_0x11464b;_0x2cfb05()[_0x139da4('0x127f')](_0x6e122e[_0x139da4('0xf85')],{'id':_0x6e122e['mailAccount']['id']}),_0x58907e[_0x139da4('0x103b')]({'title':_0x139da4('0x10df'),'msg':(_0x6e122e['mailAccount'][_0x139da4('0x4f0')]||_0x139da4('0x21b9'))+'\x20has\x20been\x20deleted!'}),_0xe5fdaf(_0x6e122e[_0x139da4('0x21b9')]);})['catch'](function(_0x4a8536){const _0x54f185=_0x11464b;if(_0x4a8536[_0x54f185('0x25f4')]&&_0x4a8536[_0x54f185('0x25f4')]['errors']&&_0x4a8536['data']['errors'][_0x54f185('0x264b')]){_0x6e122e['errors']=_0x4a8536[_0x54f185('0x25f4')]['errors']||[{'message':_0x4a8536[_0x54f185('0x1586')](),'type':_0x54f185('0x492')}];for(let _0x567399=0x0;_0x567399<_0x4a8536[_0x54f185('0x25f4')][_0x54f185('0x61a')]['length'];_0x567399++){_0x58907e['error']({'title':_0x4a8536['data'][_0x54f185('0x61a')][_0x567399]['type'],'msg':_0x4a8536[_0x54f185('0x25f4')]['errors'][_0x567399]['message']});}}else _0x58907e[_0x54f185('0xfc9')]({'title':_0x4a8536[_0x54f185('0x52d')]?_0x54f185('0x1e21')+_0x4a8536[_0x54f185('0x52d')]+_0x54f185('0x11e1')+_0x4a8536[_0x54f185('0xe1b')]:_0x54f185('0x492'),'msg':_0x4a8536[_0x54f185('0x25f4')]?JSON[_0x54f185('0xbac')](_0x4a8536[_0x54f185('0x25f4')][_0x54f185('0x1e70')]):_0x4a8536[_0x54f185('0x1e70')]||_0x4a8536[_0x54f185('0x1586')]()});});},function(){});}function _0x8795ae(_0x2646ad){return _0x2646ad===null?undefined:new Date(_0x2646ad);}function _0xe5fdaf(_0x2283f0){const _0x57df0e=_0x32da6f;_0x40e698[_0x57df0e('0x1197')](_0x2283f0);}}const _0x311577=_0x41aa97,_0x595713=_0x2734b2['p']+_0x36e6f4('0x10f7'),_0x27921b=_0x2734b2['p']+_0x36e6f4('0x20bd'),_0xc92d7f=_0x2734b2['p']+_0x36e6f4('0xadf'),_0x8e3bbf=_0x2734b2['p']+_0x36e6f4('0xfaa'),_0x1c1177=_0x2734b2['p']+_0x36e6f4('0xdd7'),_0x1896ee=_0x2734b2['p']+_0x36e6f4('0x254'),_0x19183c=_0x2734b2['p']+_0x36e6f4('0x59d'),_0x3c0c42=_0x2734b2['p']+_0x36e6f4('0x3c3'),_0x22a6f1=_0x2734b2['p']+_0x36e6f4('0x15f3'),_0x4af10a=_0x2734b2['p']+_0x36e6f4('0x1272');_0x22a85a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x19e3'),'$mdDialog','$document',_0x36e6f4('0x1d2e'),'Auth'];const _0x5a35c1={'agent':_0x595713,'autoreply':_0x27921b,'close':_0xc92d7f,'gotoif':_0x8e3bbf,'gotop':_0x1c1177,'interval':_0x1896ee,'noop':_0x19183c,'queue':_0x3c0c42,'system':_0x22a6f1,'tag':_0x4af10a};function _0x22a85a(_0x5954ce,_0x3dbee8,_0x2192b8,_0x184056,_0x26e237){const _0x295192=_0x36e6f4,_0x51785a=this;_0x51785a[_0x295192('0x98')]=_0x26e237[_0x295192('0x26cd')](),_0x51785a[_0x295192('0x21b9')]={},_0x51785a[_0x295192('0x24a2')]={'count':0x0,'rows':[]},_0x51785a[_0x295192('0x1cea')]=[],_0x51785a[_0x295192('0x243c')],_0x51785a['query']={'sort':_0x295192('0xfde')},_0x51785a[_0x295192('0x24d2')]=_0x2cfb05()['reject'](_0x2cfb05()[_0x295192('0x1eba')]([{'app':_0x295192('0x1545'),'appType':_0x295192('0x277c'),'types':[_0x295192('0x597'),_0x295192('0x2853'),_0x295192('0x1480')],'fields':[],'isApp':![]},{'app':_0x295192('0x2652'),'appType':_0x295192('0x2652'),'type':_0x295192('0x2652'),'icon':_0x295192('0x283f'),'interval':_0x295192('0x16f'),'required':!![],'isApp':!![],'fields':[{'title':_0x295192('0x1efa'),'name':_0x295192('0x18e0'),'type':_0x295192('0x1640'),'param':0x0}]},{'app':_0x295192('0x1c2b'),'appType':'system','type':_0x295192('0x1c2b'),'icon':_0x295192('0x283f'),'interval':'*,*,*,*','required':!![],'isApp':!![],'extraApi':[{'name':_0x295192('0x57a'),'field':{'name':_0x295192('0x734'),'key':'name'},'route':'variable','filters':{'fields':_0x295192('0x1776'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':_0x295192('0xd5'),'name':_0x295192('0x187'),'type':_0x295192('0x1640'),'required':!![],'param':0x0},{'title':_0x295192('0x2d5'),'name':_0x295192('0x734'),'type':_0x295192('0x2550'),'values':'variables','value':_0x295192('0x15f0'),'option':'variable.name','defaultValues':[{'value':'\x27\x27','option':_0x295192('0x1280')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':'gotop','appType':_0x295192('0x6e6'),'type':'goto','icon':'icon-apps','interval':_0x295192('0x16f'),'isApp':!![],'fields':[{'title':_0x295192('0x9c2'),'name':_0x295192('0xfde'),'type':_0x295192('0xc45'),'required':!![],'min':0x0,'param':0x0}]},{'app':_0x295192('0x30f'),'appType':_0x295192('0x30f'),'type':'gotoif','icon':_0x295192('0x283f'),'interval':_0x295192('0x16f'),'isApp':!![],'fields':[{'title':_0x295192('0x1cdc'),'name':_0x295192('0x8ff'),'type':'text','required':!![],'param':0x0},{'title':_0x295192('0x13a6'),'name':_0x295192('0x13a6'),'type':_0x295192('0xc45'),'min':0x1,'required':!![],'param':0x1},{'title':'falsepriority','name':_0x295192('0x1d7a'),'type':'number','min':0x1,'required':!![],'param':0x2}]},{'app':_0x295192('0x1d3e'),'appType':_0x295192('0x1d3e'),'foreignKey':'MailQueueId','type':_0x295192('0x1d3e'),'icon':_0x295192('0x283f'),'interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':_0x295192('0x7a7'),'field':{'name':'queue','key':'name'},'route':'mailQueue','filters':{'fields':'id,name,type','sort':_0x295192('0x4f0'),'nolimit':!![]},'permissions':{'section':0x259}}],'fields':[{'title':_0x295192('0x28ba'),'name':'queue','type':_0x295192('0x2550'),'values':_0x295192('0x7a7'),'value':_0x295192('0x24ad'),'option':'queue.name','defaultValue':0x12c,'required':!![],'param':0x0},{'title':_0x295192('0x1861'),'name':_0x295192('0x651'),'type':_0x295192('0xc45'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x12c,'param':0x1}]},{'app':_0x295192('0x1eff'),'appType':_0x295192('0x1eff'),'type':'agent','foreignKey':_0x295192('0x122a'),'icon':_0x295192('0x283f'),'interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':_0x295192('0x1f7e'),'field':{'name':'agent','key':_0x295192('0x4f0')},'route':'user','filters':{'fields':_0x295192('0x1776'),'sort':_0x295192('0x4f0'),'nolimit':!![],'role':_0x295192('0x1eff')},'permissions':{'section':0xca}}],'fields':[{'title':'Agent','name':_0x295192('0x1eff'),'type':_0x295192('0x2550'),'values':'agents','value':'agent.name','option':_0x295192('0x1530'),'required':!![],'param':0x0},{'title':_0x295192('0x1861'),'name':'timeout','type':'number','max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':'autoreply','appType':_0x295192('0x1af7'),'type':_0x295192('0x1af7'),'icon':_0x295192('0x283f'),'interval':_0x295192('0x16f'),'isApp':!![],'fields':[{'title':_0x295192('0x265e'),'name':_0x295192('0x265e'),'type':_0x295192('0x88a'),'defaultValue':'1','values':[{'option':_0x295192('0xbe0'),'value':'1'},{'option':'Always','value':'0'}],'required':!![],'param':0x0},{'title':_0x295192('0xef7'),'name':_0x295192('0x1640'),'type':_0x295192('0x1fe3'),'required':!![],'param':0x1}]},{'app':_0x295192('0x1a7b'),'appType':_0x295192('0x1a7b'),'type':'close','icon':'icon-apps','interval':_0x295192('0x16f'),'isApp':!![],'fields':[{'title':'Disposition','name':'disposition','type':_0x295192('0x1640'),'required':!![],'param':0x0}]},{'app':_0x295192('0x1446'),'appType':_0x295192('0x1446'),'type':_0x295192('0x1446'),'foreignKey':_0x295192('0x8f5'),'icon':_0x295192('0x283f'),'interval':_0x295192('0x16f'),'isApp':!![],'extraApi':[{'name':'tags','field':{'name':_0x295192('0x1446'),'key':_0x295192('0x4f0')},'route':_0x295192('0x1446'),'filters':{'fields':_0x295192('0x1776'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x295192('0x1b35'),'name':'tag','type':_0x295192('0x2550'),'values':'tags','value':'tag.name','option':_0x295192('0xc2c'),'required':!![],'param':0x0}]}],['app']),{'isApp':![]}),_0x51785a['list']={'group':{'name':'opt1','pull':'clone'},'animation':0x64,'sort':![]},_0x51785a[_0x295192('0x227f')]={'group':{'name':_0x295192('0x103e'),'put':_0x295192('0x1b27')},'animation':0x64,'onAdd':function(_0x384ba4){_0x3efc30(_0x384ba4,_0x384ba4['newIndex']);},'onSort':function(){_0x2d07fc();}},_0x51785a[_0x295192('0x24d5')]=_0x4fb789,_0x51785a[_0x295192('0x8a2')]=_0x46ec97,_0x51785a[_0x295192('0x1b02')]=_0x3dd70c,_0x51785a[_0x295192('0x72d')]=_0x3efc30,_0x51785a['editInterval']=_0x51e456,_0x51785a[_0x295192('0x24ae')]=_0x4e734c,_0x51785a[_0x295192('0x144d')]=_0xb1f3de,_0x51785a[_0x295192('0x20a6')]=_0x2d07fc,_0x51785a[_0x295192('0x242')]=_0x20039d;function _0x4fb789(_0x39e670,_0x2d5623){const _0x1778ff=_0x295192;_0x51785a[_0x1778ff('0x21b9')]=_0x39e670,_0x51785a[_0x1778ff('0x243c')]=typeof _0x2d5623!==_0x1778ff('0x1048')?_0x2d5623:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x51785a[_0x1778ff('0x227f')][_0x1778ff('0xbd0')]=!_0x51785a[_0x1778ff('0x243c')]['canEdit']?!![]:![],_0x51785a[_0x1778ff('0x2218')]['id']=_0x39e670['id'],_0x51785a['query'][_0x1778ff('0x1a55')]=!![],_0x51785a[_0x1778ff('0x2218')][_0x1778ff('0x49d')]=!![],_0x51785a[_0x1778ff('0x1b02')](),_0x51785a[_0x1778ff('0x242')]();}function _0x46ec97(_0x12e4c5,_0x39a8da,_0x3d73c2){const _0x1f64bd=_0x295192,_0x18f141=_0x3dbee8['confirm']()[_0x1f64bd('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20application?')[_0x1f64bd('0xf3c')](''+_0x12e4c5[_0x1f64bd('0x746')]+_0x1f64bd('0xace')+_0x1f64bd('0x3f3'))['ariaLabel'](_0x1f64bd('0x238d'))['targetEvent'](_0x3d73c2)['ok']('OK')[_0x1f64bd('0x3f')]('CANCEL');_0x3dbee8[_0x1f64bd('0x1f80')](_0x18f141)[_0x1f64bd('0x1166')](function(){const _0x1ee87b=_0x1f64bd;_0x51785a['mailAccountApps'][_0x1ee87b('0x269a')][_0x1ee87b('0x57b')](_0x39a8da,0x1),_0x2d07fc();},function(){const _0x341d9d=_0x1f64bd;console[_0x341d9d('0x455')](_0x341d9d('0x2d3'));});}function _0x3efc30(_0x3c0190,_0x5203e6){const _0x87b54e=_0x295192;if(_0x51785a['mailAccountApps'][_0x87b54e('0x269a')][_0x87b54e('0x264b')]){const _0x2f45b1=_0x51785a[_0x87b54e('0x24a2')][_0x87b54e('0x269a')][_0x5203e6]?_0x51785a[_0x87b54e('0x24a2')][_0x87b54e('0x269a')][_0x5203e6]:_0x51785a['mailAccountApps']['rows'][0x0],_0x2eb3d6=(_0x2f45b1[_0x87b54e('0x83f')]||_0x2f45b1[_0x87b54e('0x746')])[_0x87b54e('0x2574')]();_0x3dbee8[_0x87b54e('0x1f80')]({'controller':_0x87b54e('0x112a')+_0x2eb3d6+_0x87b54e('0x8a4'),'controllerAs':'vm','templateUrl':_0x5a35c1[_0x2eb3d6],'parent':angular[_0x87b54e('0x1194')](_0x2192b8['body']),'targetEvent':_0x3c0190,'clickOutsideToClose':!![],'locals':{'mailAccountApp':_0x2f45b1,'mailAccount':_0x51785a[_0x87b54e('0x21b9')],'crudPermissions':_0x51785a['crudPermissions']}})[_0x87b54e('0x1166')](function(_0x4e4c7b){const _0x5549dd=_0x87b54e;_0x4e4c7b&&(_0x4e4c7b['id']?_0x51785a[_0x5549dd('0x24a2')][_0x5549dd('0x269a')][_0x5203e6]=_0x4e4c7b:_0x51785a[_0x5549dd('0x24a2')][_0x5549dd('0x269a')][_0x5549dd('0x57b')](_0x5203e6,0x0,_0x4e4c7b),_0x2d07fc());})[_0x87b54e('0x1a80')](function(_0x4ec6ab){const _0x5461e8=_0x87b54e;_0x4ec6ab&&_0x184056[_0x5461e8('0xfc9')]({'title':_0x4ec6ab[_0x5461e8('0x52d')]?_0x5461e8('0x1e21')+_0x4ec6ab[_0x5461e8('0x52d')]+'\x20-\x20'+_0x4ec6ab[_0x5461e8('0xe1b')]:_0x5461e8('0x2e5'),'msg':_0x4ec6ab[_0x5461e8('0x25f4')]?JSON[_0x5461e8('0xbac')](_0x4ec6ab[_0x5461e8('0x25f4')]):_0x4ec6ab[_0x5461e8('0x1586')]()});});}}function _0x51e456(_0x5e80cb,_0xaf1be8){const _0x3ba189=_0x295192;if(_0x51785a[_0x3ba189('0x24a2')][_0x3ba189('0x269a')][_0x3ba189('0x264b')]){const _0x346c59=_0x51785a[_0x3ba189('0x24a2')][_0x3ba189('0x269a')][_0xaf1be8]?_0x51785a[_0x3ba189('0x24a2')]['rows'][_0xaf1be8]:_0x51785a['mailAccountApps'][_0x3ba189('0x269a')][0x0];_0x3dbee8[_0x3ba189('0x1f80')]({'controller':'EditMailAccountAppintervalDialogController','controllerAs':'vm','templateUrl':_0x1896ee,'parent':angular[_0x3ba189('0x1194')](_0x2192b8['body']),'targetEvent':_0x5e80cb,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x346c59['interval'],'IntervalId':_0x346c59['IntervalId'],'application':!![]},'intervals':[],'crudPermissions':_0x51785a['crudPermissions']}})[_0x3ba189('0x1166')](function(_0x1f2ad7){const _0x21d1f9=_0x3ba189;_0x1f2ad7&&(_0x346c59[_0x21d1f9('0x277c')]=_0x1f2ad7[_0x21d1f9('0x277c')]||_0x21d1f9('0x16f'),_0x346c59[_0x21d1f9('0x186f')]=_0x1f2ad7[_0x21d1f9('0x186f')]||null,_0x2d07fc());});}}function _0x2d07fc(){const _0x521a5a=_0x295192;let _0x302241=0x1,_0x45a642=[];for(let _0x5be9da=0x0;_0x5be9da<_0x51785a[_0x521a5a('0x24a2')][_0x521a5a('0x269a')][_0x521a5a('0x264b')];_0x5be9da++){const _0x2d76e7=_0x51785a['mailAccountApps'][_0x521a5a('0x269a')][_0x5be9da],_0x580fbc=[],_0x1e0264=[];_0x2d76e7[_0x521a5a('0x164e')]=_0x2d76e7[_0x521a5a('0x277c')]!==_0x521a5a('0x16f')?[_0x2d76e7[_0x521a5a('0x277c')]]:_0x2d76e7['IntervalId']?_0x2cfb05()[_0x521a5a('0x2563')](_0x2cfb05()[_0x521a5a('0x1c33')](_0x51785a[_0x521a5a('0x164e')][_0x521a5a('0x269a')],{'IntervalId':_0x2d76e7[_0x521a5a('0x186f')]}),_0x521a5a('0x277c')):[],_0x2d76e7['context']=_0x51785a[_0x521a5a('0x21b9')][_0x521a5a('0xe1c')],_0x2d76e7[_0x521a5a('0x23ae')]=_0x51785a['mailAccount'][_0x521a5a('0x23ae')],_0x2d76e7[_0x521a5a('0x1345')]&&(_0x2d76e7[_0x521a5a('0x1345')]=_0x2d76e7[_0x521a5a('0x1345')][_0x521a5a('0x2574')]()),_0x2d76e7[_0x521a5a('0xfde')]=_0x580fbc[_0x521a5a('0x264b')]?_0x2cfb05()[_0x521a5a('0x1ef5')](_0x580fbc)[_0x521a5a('0xfde')]+0x1:_0x302241,_0x302241=(_0x1e0264[_0x521a5a('0x264b')]?_0x2cfb05()['last'](_0x1e0264)[_0x521a5a('0xfde')]:_0x2d76e7[_0x521a5a('0xfde')])+0x1,_0x45a642=_0x2cfb05()[_0x521a5a('0x1c6a')](_0x45a642,_0x580fbc,[_0x2d76e7],_0x1e0264);}_0x5954ce['mailAccount'][_0x521a5a('0x153b')]({'id':_0x51785a[_0x521a5a('0x21b9')]['id']},_0x2cfb05()[_0x521a5a('0x1eba')](_0x45a642,_0x521a5a('0xfde')))[_0x521a5a('0xa44')][_0x521a5a('0x1166')](function(_0x51db04){const _0x5c1b6b=_0x521a5a;_0x51785a[_0x5c1b6b('0x24a2')]['rows']=_0x51db04[_0x5c1b6b('0x269a')];})[_0x521a5a('0x1a80')](function(_0x748a59){const _0x506dc0=_0x521a5a;console[_0x506dc0('0xfc9')](_0x748a59);});}function _0x7a9bba(_0xf9f429){const _0x4e45dd=_0x295192;_0x51785a[_0x4e45dd('0x24a2')]=_0xf9f429||{'count':0x0,'rows':[]};}function _0x20039d(){const _0x1f5938=_0x295192;return _0x5954ce[_0x1f5938('0x277c')][_0x1f5938('0xd83')]({'fields':_0x1f5938('0x1d39')})[_0x1f5938('0xa44')][_0x1f5938('0x1166')](function(_0x2e8cd){const _0x463c24=_0x1f5938;_0x51785a[_0x463c24('0x164e')]=_0x2e8cd;})[_0x1f5938('0x1a80')](function(_0x31be46){const _0x4651ef=_0x1f5938;console[_0x4651ef('0xfc9')](_0x31be46);});}function _0x3dd70c(){const _0x596e8b=_0x295192;_0x51785a[_0x596e8b('0x1f48')]=_0x5954ce[_0x596e8b('0x21b9')][_0x596e8b('0x10e0')](_0x51785a[_0x596e8b('0x2218')],_0x7a9bba)['$promise'];}function _0x4e734c(_0x415127){const _0x1dde3f=_0x295192;_0x2cfb05()[_0x1dde3f('0x127f')](_0x51785a[_0x1dde3f('0x24a2')][_0x1dde3f('0x269a')],{'id':_0x415127['id']}),_0x2d07fc(),_0x184056[_0x1dde3f('0x103b')]({'title':_0x1dde3f('0x11c0'),'msg':_0x415127['app']?_0x415127[_0x1dde3f('0x746')]+_0x1dde3f('0x7cd'):''});}function _0xb1f3de(_0x5d5fac){const _0x44e687=_0x295192,_0x518a8c=_0x3dbee8[_0x44e687('0x1d26')]()['title'](_0x44e687('0x2338'))[_0x44e687('0xf3c')](_0x44e687('0x12b5')+_0x51785a['selectedMailAccountApps'][_0x44e687('0x264b')]+'\x20selected'+_0x44e687('0x3f3'))[_0x44e687('0x8e8')](_0x44e687('0x106e'))[_0x44e687('0x203b')](_0x5d5fac)['ok']('OK')[_0x44e687('0x3f')](_0x44e687('0x2d3'));_0x3dbee8['show'](_0x518a8c)[_0x44e687('0x1166')](function(){const _0x19fe0=_0x44e687;_0x51785a[_0x19fe0('0x1cea')][_0x19fe0('0x2782')](function(_0x4fb45b){const _0x1ab959=_0x19fe0;_0x2cfb05()[_0x1ab959('0x127f')](_0x51785a[_0x1ab959('0x24a2')][_0x1ab959('0x269a')],{'id':_0x4fb45b['id']});}),_0x51785a[_0x19fe0('0x1cea')]=[],_0x2d07fc();});}}const _0x4863a3=_0x22a85a;_0x32370e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty','api',_0x36e6f4('0x21b9'),_0x36e6f4('0xf85'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x32370e(_0x3d9e4a,_0x418362,_0x35031a,_0x375e52,_0x28873a,_0x2dea1f,_0x496b14,_0x28f206,_0x40397a,_0x1f2ba3){const _0x2acece=_0x36e6f4,_0x365b87=this;_0x365b87[_0x2acece('0x98')]=_0x40397a['getCurrentUser'](),_0x365b87[_0x2acece('0x21b9')]=_0x28873a,_0x365b87[_0x2acece('0x243c')]=_0x1f2ba3,_0x365b87[_0x2acece('0xf01')]=_0x496b14,_0x365b87['items']=[],_0x365b87[_0x2acece('0x10ab')]=[],_0x365b87[_0x2acece('0x18e1')]=[],_0x365b87[_0x2acece('0x2111')]=[],_0x365b87[_0x2acece('0x2781')]=[],_0x365b87[_0x2acece('0x14d7')]=![],_0x365b87['onInit']=_0x3b4cbd,_0x365b87[_0x2acece('0x1d92')]=_0x18b695,_0x365b87[_0x2acece('0x24a0')]=_0x54ff29,_0x365b87['dualMultiselectOptions']={'readOnly':!_0x365b87[_0x2acece('0x243c')][_0x2acece('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x2acece('0x6e1'),'line2':['name',_0x2acece('0x1eef')],'line3':'','labelAll':_0x28f206[_0x2acece('0x25cc')](_0x2acece('0x1708')),'labelSelected':_0x28f206[_0x2acece('0x25cc')](_0x2acece('0x230')),'transferCallback':function(){const _0x4176b9=_0x2acece,_0x1790a3=_0x2cfb05()[_0x4176b9('0x2802')](_0x365b87[_0x4176b9('0x2781')],_0x365b87[_0x4176b9('0x18e1')],'id');_0x365b87['pendingChanges']=_0x2cfb05()[_0x4176b9('0x1081')](_0x1790a3)?![]:!![];}};function _0x3b4cbd(){const _0x177a76=_0x2acece;return _0x40397a[_0x177a76('0x1ac6')](_0x177a76('0xa7c'))?_0x5ef751()['catch'](function(_0x1926dc){const _0x46002e=_0x177a76;_0x35031a['error']({'title':_0x1926dc[_0x46002e('0x52d')]?_0x46002e('0x1e21')+_0x1926dc[_0x46002e('0x52d')]+_0x46002e('0x11e1')+_0x1926dc[_0x46002e('0xe1b')]:_0x46002e('0xd4c'),'msg':_0x1926dc['status']?JSON[_0x46002e('0xbac')](_0x1926dc[_0x46002e('0x25f4')]):_0x1926dc[_0x46002e('0x1586')]()});}):_0x1e63f3()[_0x177a76('0x1166')](function(_0x5e0abf){return _0x365b87['section']=_0x5e0abf,_0x5ef751();})['catch'](function(_0x294860){const _0x909b05=_0x177a76;_0x35031a[_0x909b05('0xfc9')]({'title':_0x294860[_0x909b05('0x52d')]?_0x909b05('0x1e21')+_0x294860['status']+_0x909b05('0x11e1')+_0x294860[_0x909b05('0xe1b')]:_0x909b05('0xd4c'),'msg':_0x294860[_0x909b05('0x52d')]?JSON['stringify'](_0x294860[_0x909b05('0x25f4')]):_0x294860[_0x909b05('0x1586')]()});});}function _0x1e63f3(){return _0x418362(function(_0x18524f,_0x3a3e91){const _0x715a1d=a0_0x3f2c;_0x375e52['userProfileSection'][_0x715a1d('0xd83')]({'userProfileId':_0x365b87[_0x715a1d('0x98')]['userProfileId'],'name':_0x715a1d('0x2391')})[_0x715a1d('0xa44')]['then'](function(_0x176fb8){const _0x4d5c63=_0x715a1d,_0x31c3b7=_0x176fb8&&_0x176fb8[_0x4d5c63('0x269a')]?_0x176fb8[_0x4d5c63('0x269a')][0x0]:null;_0x18524f(_0x31c3b7);})[_0x715a1d('0x1a80')](function(_0x57d6cc){_0x3a3e91(_0x57d6cc);});});}function _0x5ef751(){return _0x418362(function(_0x1a4b94,_0x18204a){const _0x3e739e=a0_0x3f2c;return _0xd8e28c()[_0x3e739e('0x1166')](function(_0x14225d){const _0x26fe28=_0x3e739e;return _0x365b87[_0x26fe28('0xbd7')]=_0x14225d[_0x26fe28('0x269a')]?_0x14225d[_0x26fe28('0x269a')]:[],_0x40397a[_0x26fe28('0x1ac6')]('admin')?_0x14225d:_0x365b87[_0x26fe28('0xe60')]?_0x365b87['section']['autoAssociation']?_0x14225d:_0x58f863():null;})[_0x3e739e('0x1166')](function(_0x2d0c22){const _0x3521b8=_0x3e739e,_0xbb77e=_0x2d0c22&&_0x2d0c22[_0x3521b8('0x269a')]?_0x2d0c22['rows']:[];return _0x365b87['allowedItems']=_0x2cfb05()[_0x3521b8('0x2563')](_0xbb77e,function(_0x2befde){const _0x50114a=_0x3521b8;return _0x2cfb05()[_0x50114a('0xc38')](_0x365b87['items'],{'id':_0x40397a[_0x50114a('0x1ac6')]('admin')||_0x365b87[_0x50114a('0xe60')]['autoAssociation']?_0x2befde['id']:_0x2befde[_0x50114a('0x24e8')]});}),_0x365b87['startingAllowedItems']=angular[_0x3521b8('0x225f')](_0x365b87[_0x3521b8('0x10ab')]),_0x365b87[_0x3521b8('0xbd7')][_0x3521b8('0x2782')](function(_0x252757){const _0x96a4c8=_0x3521b8,_0x2a4fa7=_0x2cfb05()[_0x96a4c8('0xc38')](_0x365b87[_0x96a4c8('0x10ab')],{'id':_0x252757['id']});_0x40397a[_0x96a4c8('0x1ac6')]('admin')?_0x252757['isValid']=!![]:_0x252757[_0x96a4c8('0x26ef')]=typeof _0x2a4fa7!==_0x96a4c8('0x1048')?!![]:![];}),_0x3c73a7();})['then'](function(_0x328d75){const _0x3dd116=_0x3e739e,_0x25146f=_0x328d75&&_0x328d75[_0x3dd116('0x269a')]?_0x328d75[_0x3dd116('0x269a')]:[];_0x365b87['selectedItems']=_0x2cfb05()[_0x3dd116('0x2563')](_0x25146f,function(_0x502ba3){const _0x31f498=_0x3dd116,_0x1e02f7=_0x2cfb05()[_0x31f498('0xc38')](_0x365b87[_0x31f498('0xbd7')],{'id':_0x502ba3['id']});return _0x1e02f7[_0x31f498('0x23af')]=_0x502ba3[_0x31f498('0x2651')]?_0x31f498('0x11e8')+_0x502ba3['UserMailAccount'][_0x31f498('0x23af')]:'',_0x1e02f7[_0x31f498('0x1eef')]=typeof _0x502ba3[_0x31f498('0x1eef')]!=='undefined'?'<'+_0x502ba3['internal']+'>':'',_0x1e02f7;}),_0x365b87[_0x3dd116('0x2781')]=angular[_0x3dd116('0x225f')](_0x365b87[_0x3dd116('0x18e1')]),_0x365b87[_0x3dd116('0xc68')][_0x3dd116('0x18e1')]=_0x365b87[_0x3dd116('0x18e1')],_0x365b87[_0x3dd116('0xc68')][_0x3dd116('0xbd7')]=_0x2cfb05()['differenceBy'](_0x365b87[_0x3dd116('0x10ab')],_0x365b87[_0x3dd116('0xc68')][_0x3dd116('0x18e1')],'id'),_0x1a4b94();})[_0x3e739e('0x1a80')](function(_0x138edf){_0x18204a(_0x138edf);});});}function _0x58f863(){return _0x418362(function(_0x535949,_0x447a77){const _0x5ea7dc=a0_0x3f2c;return _0x375e52[_0x5ea7dc('0x4b5')][_0x5ea7dc('0xd83')]({'sectionId':_0x365b87['section']['id'],'nolimit':!![]})[_0x5ea7dc('0xa44')][_0x5ea7dc('0x1166')](function(_0x2162f9){_0x535949(_0x2162f9);})[_0x5ea7dc('0x1a80')](function(_0x3c65a4){_0x447a77(_0x3c65a4);});});}function _0x3c73a7(){return _0x418362(function(_0x3fe9d4,_0x3f4982){const _0x5033c8=a0_0x3f2c;return _0x375e52[_0x5033c8('0x21b9')][_0x5033c8('0x261c')]({'id':_0x365b87[_0x5033c8('0x21b9')]['id'],'fields':_0x5033c8('0x1459'),'nolimit':!![],'role':_0x5033c8('0x1eff')})[_0x5033c8('0xa44')]['then'](function(_0x5821e5){_0x3fe9d4(_0x5821e5);})[_0x5033c8('0x1a80')](function(_0x5d2875){_0x3f4982(_0x5d2875);});});}function _0xd8e28c(){return _0x418362(function(_0x286b9c,_0x243dd9){const _0x53d695=a0_0x3f2c;return _0x375e52[_0x53d695('0x557')][_0x53d695('0xd83')]({'fields':_0x53d695('0x1459'),'nolimit':!![],'role':'agent'})['$promise'][_0x53d695('0x1166')](function(_0x1d3d28){_0x286b9c(_0x1d3d28);})[_0x53d695('0x1a80')](function(_0x360180){_0x243dd9(_0x360180);});});}function _0x29cf06(_0x22cb1b){return _0x418362(function(_0x16719a,_0x5deca6){const _0x3a7e84=a0_0x3f2c;_0x2cfb05()[_0x3a7e84('0x1081')](_0x22cb1b)?_0x16719a():_0x375e52['mailAccount'][_0x3a7e84('0x275c')]({'id':_0x365b87[_0x3a7e84('0x21b9')]['id'],'ids':_0x2cfb05()[_0x3a7e84('0x2563')](_0x22cb1b,'id')})[_0x3a7e84('0xa44')][_0x3a7e84('0x1166')](function(){_0x16719a();})['catch'](function(_0x22e1a0){_0x5deca6(_0x22e1a0);});});}function _0x3a559f(_0x101025){return _0x418362(function(_0x3d6a6d,_0x5e6657){const _0x245007=a0_0x3f2c;_0x2cfb05()[_0x245007('0x1081')](_0x101025)?_0x3d6a6d():_0x375e52[_0x245007('0x21b9')]['removeAgents']({'id':_0x365b87[_0x245007('0x21b9')]['id'],'ids':_0x2cfb05()[_0x245007('0x2563')](_0x101025,'id')})[_0x245007('0xa44')]['then'](function(){_0x3d6a6d();})[_0x245007('0x1a80')](function(_0x12949c){_0x5e6657(_0x12949c);});});}function _0x18b695(){const _0x380bee=_0x2acece,_0x4aebb4=_0x2cfb05()[_0x380bee('0x24ac')](_0x365b87['startingSelectedItems'],_0x365b87[_0x380bee('0x18e1')],'id'),_0x363ae8=_0x2cfb05()[_0x380bee('0x24ac')](_0x365b87[_0x380bee('0x18e1')],_0x365b87[_0x380bee('0x2781')],'id');return _0x3a559f(_0x4aebb4)[_0x380bee('0x1166')](function(){return _0x29cf06(_0x363ae8);})[_0x380bee('0x1166')](function(){const _0x1766bc=_0x380bee;_0x365b87[_0x1766bc('0x14d7')]=![],_0x365b87[_0x1766bc('0x2111')]=angular[_0x1766bc('0x225f')](_0x365b87['allowedItems']),_0x365b87[_0x1766bc('0x2781')]=angular[_0x1766bc('0x225f')](_0x365b87['selectedItems']),_0x35031a[_0x1766bc('0x103b')]({'title':_0x1766bc('0x983'),'msg':_0x1766bc('0x1673')});})[_0x380bee('0x1a80')](function(_0x4012df){const _0x28c1f6=_0x380bee;_0x35031a[_0x28c1f6('0xfc9')]({'title':_0x4012df['status']?_0x28c1f6('0x1e21')+_0x4012df[_0x28c1f6('0x52d')]+_0x28c1f6('0x11e1')+_0x4012df['statusText']:'SYSTEM:LISTS_ASSOCIATION','msg':_0x4012df['status']?JSON[_0x28c1f6('0xbac')](_0x4012df['data']):_0x4012df[_0x28c1f6('0x1586')]()});});}function _0x54ff29(){const _0x9aec0a=_0x2acece;_0x3d9e4a[_0x9aec0a('0x1197')]();}}const _0x5aa946=_0x32370e;_0x2e419a[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1990'),'mailAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x2e419a(_0xad296e,_0x288732,_0x2bddc9,_0x292577,_0x51dbf8,_0xd166d2,_0x441144,_0x18ee79){const _0x115e9b=_0x36e6f4,_0x1f3239=this;_0x1f3239[_0x115e9b('0x98')]=_0x441144[_0x115e9b('0x26cd')](),_0x1f3239[_0x115e9b('0x61a')]=[],_0x1f3239[_0x115e9b('0xcdc')]=_0x115e9b('0x2132')+(_0x292577[_0x115e9b('0x83f')]||_0x292577[_0x115e9b('0x746')])[_0x115e9b('0x1387')](),_0x1f3239['agent']=angular['copy'](_0x292577),_0x1f3239['crudPermissions']=_0x18ee79,_0x1f3239[_0x115e9b('0x128b')]={};if(_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x823')])switch(_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x83f')]?_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x83f')][_0x115e9b('0x2574')]():_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x746')][_0x115e9b('0x2574')]()){case _0x115e9b('0x2853'):break;case _0x115e9b('0xded'):{const _0x113395=_0x1f3239['agent'][_0x115e9b('0x823')]['split'](',');_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x7ca')]=_0x113395[0x0],_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0xedb')]=_0x113395[0x1],_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x1634')]=_0x113395['slice'](0x2,_0x113395['length'])[_0x115e9b('0x45a')](',');}break;case _0x115e9b('0x1636'):{const _0x560c5f=_0x1f3239['agent'][_0x115e9b('0x823')]['split'](',');_0x1f3239[_0x115e9b('0x1eff')]['projectId']=_0x560c5f[0x0],_0x1f3239['agent']['clientEmail']=_0x560c5f[0x1],_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x170e')]=_0x560c5f[0x2],_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0xedb')]=_0x560c5f[0x3],_0x1f3239[_0x115e9b('0x1eff')]['welcomemessage']=_0x560c5f[_0x115e9b('0x233')](0x4,_0x560c5f[_0x115e9b('0x264b')])['join'](',');}break;case'amazonlex':{const _0x30b0c6=_0x1f3239[_0x115e9b('0x1eff')]['appdata'][_0x115e9b('0x25c8')](',');_0x1f3239['agent'][_0x115e9b('0xee6')]=_0x30b0c6[0x0],_0x1f3239[_0x115e9b('0x1eff')]['secretaccesskey']=_0x30b0c6[0x1],_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x25a2')]=_0x30b0c6[0x2],_0x1f3239['agent'][_0x115e9b('0x1ac4')]=_0x30b0c6[0x3],_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x1634')]=_0x30b0c6[_0x115e9b('0x233')](0x4,_0x30b0c6[_0x115e9b('0x264b')])[_0x115e9b('0x45a')](',');}break;case'autoreply':{const _0x390c60=_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x823')][_0x115e9b('0x25c8')](',');_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x265e')]=isNaN(_0x390c60[0x0])?_0x390c60[0x0]:parseInt(_0x390c60[0x0],0xa),_0x1f3239[_0x115e9b('0x1eff')]['text']=_0x390c60[_0x115e9b('0x233')](0x1,_0x390c60[_0x115e9b('0x264b')])[_0x115e9b('0x45a')](',');}break;case _0x115e9b('0x1e70'):_0x1f3239[_0x115e9b('0x1eff')]['text']=_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x823')];break;case'set':_0x1f3239['agent'][_0x115e9b('0x4f0')]=_0x1f3239['agent']['appdata']['split']('=')[0x0],_0x1f3239[_0x115e9b('0x1eff')]['value']=_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x823')]['split']('=')[0x1];break;case'agi':_0x1f3239[_0x115e9b('0x1eff')]['project']=_0x1f3239['agent']['appdata'];break;default:{const _0xffe9c1=_0x1f3239[_0x115e9b('0x1eff')]['appdata'][_0x115e9b('0x25c8')](',');_0x1f3239['agent'][_0x115e9b('0x1eff')]=_0x2cfb05()[_0x115e9b('0x1081')](_0xffe9c1[0x0])?_0xffe9c1[0x0]:isNaN(_0xffe9c1[0x0])?_0xffe9c1[0x0]:parseInt(_0xffe9c1[0x0],0xa),_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x651')]=_0x2cfb05()[_0x115e9b('0x1081')](_0xffe9c1[0x1])?_0xffe9c1[0x1]:isNaN(_0xffe9c1[0x1])?_0xffe9c1[0x1]:parseInt(_0xffe9c1[0x1],0xa);}break;}else _0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x651')]=0x1e;_0x1f3239['agent'][_0x115e9b('0x1345')]&&_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x1345')][_0x115e9b('0x2574')]()==='outbound'&&_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x83f')]['toLowerCase']()===_0x115e9b('0x2884')&&(_0x1f3239['agent'][_0x115e9b('0x265a')]=_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x2026')]?_0x1f3239['agent']['phone'][_0x115e9b('0x25c8')]('$')[0x0]:undefined,_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x1f02')]=_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x992')]?'CALLERID(all)='+_0x1f3239[_0x115e9b('0x1eff')][_0x115e9b('0x992')]:undefined);_0x1f3239[_0x115e9b('0x2871')]=_0x3883e9,_0x1f3239[_0x115e9b('0x24a0')]=_0xae28c6,_0x441144['hasRole'](_0x115e9b('0xa7c'))?_0xd166d2[_0x115e9b('0x557')][_0x115e9b('0xd83')]({'fields':_0x115e9b('0x1776'),'sort':'name','nolimit':'true','role':'agent'})[_0x115e9b('0xa44')][_0x115e9b('0x1166')](function(_0x2c0ecc){const _0x1b9736=_0x115e9b;_0x1f3239[_0x1b9736('0x1f7e')]=_0x2c0ecc['rows']||[];})['catch'](function(_0x3c038c){const _0x36d2c5=_0x115e9b;_0x2bddc9[_0x36d2c5('0xfc9')]({'title':_0x3c038c[_0x36d2c5('0x52d')]?_0x36d2c5('0x1e21')+_0x3c038c[_0x36d2c5('0x52d')]+_0x36d2c5('0x11e1')+_0x3c038c[_0x36d2c5('0xe1b')]:_0x36d2c5('0xd4c'),'msg':_0x3c038c[_0x36d2c5('0x25f4')]?JSON[_0x36d2c5('0xbac')](_0x3c038c['data']):_0x3c038c['toString']()});}):_0xd166d2[_0x115e9b('0x557')]['get']({'fields':'id,name','sort':'name','nolimit':_0x115e9b('0xf3b'),'role':'agent'})[_0x115e9b('0xa44')][_0x115e9b('0x1166')](function(_0x5cadfc){const _0x41e268=_0x115e9b;_0x1f3239[_0x41e268('0x1f7e')]=_0x5cadfc[_0x41e268('0x269a')]||[];})[_0x115e9b('0x1166')](function(){const _0x556b77=_0x115e9b;return _0xd166d2[_0x556b77('0x17aa')][_0x556b77('0xd83')]({'userProfileId':_0x1f3239[_0x556b77('0x98')][_0x556b77('0xb86')],'sectionId':0xca})[_0x556b77('0xa44')];})[_0x115e9b('0x1166')](function(_0x16f8a2){const _0xf31d47=_0x115e9b,_0x32d305=_0x16f8a2&&_0x16f8a2['rows']?_0x16f8a2[_0xf31d47('0x269a')][0x0]:null;if(!_0x32d305){const _0xab6daf=[];let _0x52aaae=null;_0x1f3239[_0xf31d47('0x1eff')]&&(_0x52aaae=_0x2cfb05()[_0xf31d47('0xc38')](_0x1f3239[_0xf31d47('0x1f7e')],{'name':_0x1f3239[_0xf31d47('0x1eff')][_0xf31d47('0x1eff')]}));for(let _0x524a2f=0x0;_0x524a2f<_0x1f3239[_0xf31d47('0x1f7e')][_0xf31d47('0x264b')];_0x524a2f++){_0x52aaae&&_0x1f3239[_0xf31d47('0x1f7e')][_0x524a2f]['id']===_0x52aaae['id']&&(_0x1f3239[_0xf31d47('0x1f7e')][_0x524a2f][_0xf31d47('0x2378')]=![],_0xab6daf[_0xf31d47('0x1514')](_0x1f3239[_0xf31d47('0x1f7e')][_0x524a2f]));}_0x1f3239['agents']=_0xab6daf;}else{if(!_0x32d305[_0xf31d47('0x1a2b')])return _0xd166d2[_0xf31d47('0x4b5')][_0xf31d47('0xd83')]({'sectionId':_0x32d305['id']})[_0xf31d47('0xa44')][_0xf31d47('0x1166')](function(_0x81bb63){const _0x1072be=_0xf31d47,_0x5ad401=_0x2cfb05()[_0x1072be('0x2563')](_0x81bb63['rows'],function(_0x2a3e3a){const _0xee4239=_0x1072be;return _0x2cfb05()['find'](_0x1f3239[_0xee4239('0x1f7e')],{'id':_0x2a3e3a['resourceId']});});let _0x194137=null;_0x1f3239[_0x1072be('0x1eff')]&&(_0x194137=_0x2cfb05()[_0x1072be('0xc38')](_0x1f3239[_0x1072be('0x1f7e')],{'name':_0x1f3239[_0x1072be('0x1eff')]['agent']}));if(_0x194137&&!_0x2cfb05()[_0x1072be('0x1798')](_0x5ad401,['id',_0x194137['id']])){const _0x4a9915=_0x2cfb05()['find'](_0x1f3239[_0x1072be('0x1f7e')],{'id':_0x194137['id']});_0x4a9915[_0x1072be('0x2378')]=![],_0x5ad401[_0x1072be('0x1514')](_0x4a9915);}_0x1f3239[_0x1072be('0x1f7e')]=_0x5ad401;});}})[_0x115e9b('0x1a80')](function(_0x1db96c){const _0x509835=_0x115e9b;_0x2bddc9[_0x509835('0xfc9')]({'title':_0x1db96c['status']?_0x509835('0x1e21')+_0x1db96c[_0x509835('0x52d')]+'\x20-\x20'+_0x1db96c[_0x509835('0xe1b')]:_0x509835('0xdc5'),'msg':_0x1db96c[_0x509835('0x25f4')]?JSON[_0x509835('0xbac')](_0x1db96c['data']):_0x1db96c[_0x509835('0x1586')]()});});function _0x3883e9(){const _0x362822=_0x115e9b;_0x1f3239['errors']=[];const _0x3cddba=[];_0x1f3239[_0x362822('0x1eff')][_0x362822('0x1345')]&&_0x1f3239[_0x362822('0x1eff')][_0x362822('0x1345')]['toLowerCase']()===_0x362822('0x587')&&_0x1f3239[_0x362822('0x1eff')][_0x362822('0x83f')]==='outboundDial'&&(_0x1f3239['agent'][_0x362822('0x2026')]=_0x51dbf8[_0x362822('0x2848')]?(_0x1f3239[_0x362822('0x1eff')][_0x362822('0x265a')]||'')+_0x362822('0x881')+_0x51dbf8['cutdigits']+'}':(_0x1f3239[_0x362822('0x1eff')][_0x362822('0x265a')]||'')+_0x362822('0x1d1'),_0x51dbf8['recordingFormat']!==_0x362822('0x192')?_0x1f3239['agent'][_0x362822('0xd39')][_0x362822('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x1f3239[_0x362822('0x1eff')][_0x362822('0xd39')]+=_0x362822('0x1059')):_0x1f3239['agent'][_0x362822('0xd39')]=_0x1f3239[_0x362822('0x1eff')][_0x362822('0xd39')][_0x362822('0xf3')](_0x362822('0x1059'),''));const _0xb8f9b4=_0x2cfb05()[_0x362822('0xc38')](_0x1f3239['agents'],{'name':_0x1f3239['agent'][_0x362822('0x1eff')]});_0xb8f9b4&&(_0x1f3239[_0x362822('0x1eff')][_0x362822('0x122a')]=_0xb8f9b4['id']);if(_0x1f3239['agent']['appType']&&_0x1f3239[_0x362822('0x1eff')][_0x362822('0x83f')]==='custom'){}else switch((_0x1f3239[_0x362822('0x1eff')][_0x362822('0x746')]||_0x1f3239[_0x362822('0x1eff')][_0x362822('0x83f')])[_0x362822('0x2574')]()){case _0x362822('0xceb'):_0x1f3239['agent'][_0x362822('0x823')]=_0x1f3239[_0x362822('0x1eff')][_0x362822('0x4f0')]+'='+_0x1f3239[_0x362822('0x1eff')][_0x362822('0x18e0')];break;case _0x362822('0x2853'):break;default:_0x3cddba[0x0]=_0x1f3239[_0x362822('0x1eff')][_0x362822('0x1eff')],_0x3cddba[0x1]=_0x1f3239[_0x362822('0x1eff')]['timeout'],_0x1f3239[_0x362822('0x1eff')][_0x362822('0x823')]=_0x3cddba[_0x362822('0x45a')](',');}_0xae28c6(_0x1f3239[_0x362822('0x1eff')]);}function _0xae28c6(_0x56394b){const _0x1dbc38=_0x115e9b;_0xad296e[_0x1dbc38('0x1197')](_0x56394b);}}const _0x23fea9=_0x2e419a;_0x535499[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1990'),_0x36e6f4('0x21b9'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x535499(_0x268c94,_0x520e58,_0x31d809,_0x3492ba,_0x27cab1,_0x144399,_0x1d70b9,_0x2547bd){const _0x2f9cca=_0x36e6f4,_0x44cdba=this;_0x44cdba[_0x2f9cca('0x98')]=_0x1d70b9[_0x2f9cca('0x26cd')](),_0x44cdba[_0x2f9cca('0x61a')]=[],_0x44cdba[_0x2f9cca('0xcdc')]=_0x2f9cca('0x2132')+(_0x3492ba['appType']||_0x3492ba[_0x2f9cca('0x746')])[_0x2f9cca('0x1387')](),_0x44cdba[_0x2f9cca('0x1af7')]=angular[_0x2f9cca('0x225f')](_0x3492ba),_0x44cdba[_0x2f9cca('0x243c')]=_0x2547bd,_0x44cdba[_0x2f9cca('0x128b')]={};if(_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x823')])switch(_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x83f')]?_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x83f')][_0x2f9cca('0x2574')]():_0x44cdba['autoreply']['app']['toLowerCase']()){case _0x2f9cca('0x2853'):break;case'dialogflow':{const _0x3dc450=_0x44cdba['autoreply']['appdata'][_0x2f9cca('0x25c8')](',');_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x7ca')]=_0x3dc450[0x0],_0x44cdba[_0x2f9cca('0x1af7')]['language']=_0x3dc450[0x1],_0x44cdba['autoreply'][_0x2f9cca('0x1634')]=_0x3dc450['slice'](0x2,_0x3dc450[_0x2f9cca('0x264b')])['join'](',');}break;case _0x2f9cca('0x1636'):{const _0x1f793f=_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x823')][_0x2f9cca('0x25c8')](',');_0x44cdba[_0x2f9cca('0x1af7')]['projectId']=_0x1f793f[0x0],_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x27f3')]=_0x1f793f[0x1],_0x44cdba[_0x2f9cca('0x1af7')]['privateKey']=_0x1f793f[0x2],_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0xedb')]=_0x1f793f[0x3],_0x44cdba[_0x2f9cca('0x1af7')]['welcomemessage']=_0x1f793f[_0x2f9cca('0x233')](0x4,_0x1f793f[_0x2f9cca('0x264b')])[_0x2f9cca('0x45a')](',');}break;case _0x2f9cca('0x86c'):{const _0x12c6a3=_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x823')][_0x2f9cca('0x25c8')](',');_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0xee6')]=_0x12c6a3[0x0],_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x125')]=_0x12c6a3[0x1],_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x25a2')]=_0x12c6a3[0x2],_0x44cdba[_0x2f9cca('0x1af7')]['botname']=_0x12c6a3[0x3],_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x1634')]=_0x12c6a3[_0x2f9cca('0x233')](0x4,_0x12c6a3[_0x2f9cca('0x264b')])[_0x2f9cca('0x45a')](',');}break;case _0x2f9cca('0x1af7'):{const _0x230b3d=_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x823')][_0x2f9cca('0x25c8')](',');_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x265e')]=isNaN(_0x230b3d[0x0])?_0x230b3d[0x0]:parseInt(_0x230b3d[0x0],0xa),_0x44cdba['autoreply']['text']=_0x230b3d[_0x2f9cca('0x233')](0x1,_0x230b3d[_0x2f9cca('0x264b')])[_0x2f9cca('0x45a')](',');}break;case _0x2f9cca('0x1e70'):_0x44cdba[_0x2f9cca('0x1af7')]['text']=_0x44cdba['autoreply'][_0x2f9cca('0x823')];break;case _0x2f9cca('0xceb'):_0x44cdba['autoreply'][_0x2f9cca('0x4f0')]=_0x44cdba[_0x2f9cca('0x1af7')]['appdata'][_0x2f9cca('0x25c8')]('=')[0x0],_0x44cdba['autoreply']['value']=_0x44cdba['autoreply'][_0x2f9cca('0x823')][_0x2f9cca('0x25c8')]('=')[0x1];break;case _0x2f9cca('0x1034'):_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x2588')]=_0x44cdba['autoreply']['appdata'];break;default:{const _0x36f063=_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x823')]['split'](',');_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x265e')]=_0x2cfb05()[_0x2f9cca('0x1081')](_0x36f063[0x0])?_0x36f063[0x0]:isNaN(_0x36f063[0x0])?_0x36f063[0x0]:parseInt(_0x36f063[0x0],0xa),_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x1640')]=_0x2cfb05()['isEmpty'](_0x36f063[0x1])?_0x36f063[0x1]:isNaN(_0x36f063[0x1])?_0x36f063[0x1]:parseInt(_0x36f063[0x1],0xa);}break;}else _0x44cdba[_0x2f9cca('0x1af7')]['times']=0x1;_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x1345')]&&_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x1345')]['toLowerCase']()==='outbound'&&_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x83f')]['toLowerCase']()===_0x2f9cca('0x2884')&&(_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x265a')]=_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x2026')]?_0x44cdba['autoreply'][_0x2f9cca('0x2026')][_0x2f9cca('0x25c8')]('$')[0x0]:undefined,_0x44cdba['autoreply']['callerId']=_0x44cdba[_0x2f9cca('0x1af7')]['callerID']?_0x2f9cca('0xa4c')+_0x44cdba[_0x2f9cca('0x1af7')][_0x2f9cca('0x992')]:undefined);_0x44cdba[_0x2f9cca('0x2871')]=_0x2dad73,_0x44cdba[_0x2f9cca('0x24a0')]=_0x8e2812;function _0x2dad73(){const _0x2279bc=_0x2f9cca;_0x44cdba[_0x2279bc('0x61a')]=[];const _0x530e71=[];_0x44cdba[_0x2279bc('0x1af7')][_0x2279bc('0x1345')]&&_0x44cdba[_0x2279bc('0x1af7')][_0x2279bc('0x1345')][_0x2279bc('0x2574')]()==='outbound'&&_0x44cdba['autoreply'][_0x2279bc('0x83f')]===_0x2279bc('0x867')&&(_0x44cdba[_0x2279bc('0x1af7')][_0x2279bc('0x2026')]=_0x27cab1[_0x2279bc('0x2848')]?(_0x44cdba['autoreply'][_0x2279bc('0x265a')]||'')+_0x2279bc('0x881')+_0x27cab1[_0x2279bc('0x2848')]+'}':(_0x44cdba[_0x2279bc('0x1af7')]['prefix']||'')+_0x2279bc('0x1d1'),_0x27cab1[_0x2279bc('0x28cb')]!=='none'?_0x44cdba[_0x2279bc('0x1af7')]['options'][_0x2279bc('0x2379')](_0x2279bc('0x1059'))<0x0&&(_0x44cdba[_0x2279bc('0x1af7')]['options']+=_0x2279bc('0x1059')):_0x44cdba['autoreply'][_0x2279bc('0xd39')]=_0x44cdba[_0x2279bc('0x1af7')][_0x2279bc('0xd39')][_0x2279bc('0xf3')](_0x2279bc('0x1059'),''));if(_0x44cdba[_0x2279bc('0x1af7')][_0x2279bc('0x83f')]&&_0x44cdba[_0x2279bc('0x1af7')][_0x2279bc('0x83f')]===_0x2279bc('0x2853')){}else switch((_0x44cdba[_0x2279bc('0x1af7')][_0x2279bc('0x746')]||_0x44cdba[_0x2279bc('0x1af7')]['appType'])['toLowerCase']()){case _0x2279bc('0xceb'):_0x44cdba[_0x2279bc('0x1af7')]['appdata']=_0x44cdba[_0x2279bc('0x1af7')][_0x2279bc('0x4f0')]+'='+_0x44cdba['autoreply'][_0x2279bc('0x18e0')];break;case _0x2279bc('0x2853'):break;default:_0x530e71[0x0]=_0x44cdba['autoreply'][_0x2279bc('0x265e')],_0x530e71[0x1]=_0x44cdba[_0x2279bc('0x1af7')][_0x2279bc('0x1640')],_0x44cdba[_0x2279bc('0x1af7')]['appdata']=_0x530e71[_0x2279bc('0x45a')](',');}_0x8e2812(_0x44cdba[_0x2279bc('0x1af7')]);}function _0x8e2812(_0x463d33){const _0x28ad41=_0x2f9cca;_0x268c94[_0x28ad41('0x1197')](_0x463d33);}}const _0x41d5b3=_0x535499;_0x42978b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x1990'),_0x36e6f4('0x21b9'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x42978b(_0x1ea703,_0x52dfc7,_0x25975e,_0x274ac0,_0x8c1ea2,_0x26fa96,_0x4e187b,_0x27ad3e){const _0xa9549f=_0x36e6f4,_0x2051a4=this;_0x2051a4[_0xa9549f('0x98')]=_0x4e187b['getCurrentUser'](),_0x2051a4[_0xa9549f('0x61a')]=[],_0x2051a4[_0xa9549f('0xcdc')]=_0xa9549f('0x2132')+(_0x274ac0[_0xa9549f('0x83f')]||_0x274ac0[_0xa9549f('0x746')])[_0xa9549f('0x1387')](),_0x2051a4[_0xa9549f('0x1a7b')]=angular[_0xa9549f('0x225f')](_0x274ac0),_0x2051a4['crudPermissions']=_0x27ad3e,_0x2051a4[_0xa9549f('0x128b')]={};if(_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x823')])switch(_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x83f')]?_0x2051a4[_0xa9549f('0x1a7b')]['appType'][_0xa9549f('0x2574')]():_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x746')][_0xa9549f('0x2574')]()){case'custom':break;case _0xa9549f('0xded'):{const _0x4317ac=_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x823')][_0xa9549f('0x25c8')](',');_0x2051a4['close']['key']=_0x4317ac[0x0],_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0xedb')]=_0x4317ac[0x1],_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x1634')]=_0x4317ac[_0xa9549f('0x233')](0x2,_0x4317ac[_0xa9549f('0x264b')])['join'](',');}break;case _0xa9549f('0x1636'):{const _0x12c703=_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x823')][_0xa9549f('0x25c8')](',');_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x1b0a')]=_0x12c703[0x0],_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x27f3')]=_0x12c703[0x1],_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x170e')]=_0x12c703[0x2],_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0xedb')]=_0x12c703[0x3],_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x1634')]=_0x12c703['slice'](0x4,_0x12c703[_0xa9549f('0x264b')])[_0xa9549f('0x45a')](',');}break;case _0xa9549f('0x86c'):{const _0x327956=_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x823')]['split'](',');_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0xee6')]=_0x327956[0x0],_0x2051a4['close']['secretaccesskey']=_0x327956[0x1],_0x2051a4['close'][_0xa9549f('0x25a2')]=_0x327956[0x2],_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x1ac4')]=_0x327956[0x3],_0x2051a4[_0xa9549f('0x1a7b')]['welcomemessage']=_0x327956[_0xa9549f('0x233')](0x4,_0x327956['length'])[_0xa9549f('0x45a')](',');}break;case _0xa9549f('0x1af7'):{const _0x368328=_0x2051a4[_0xa9549f('0x1a7b')]['appdata'][_0xa9549f('0x25c8')](',');_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x265e')]=isNaN(_0x368328[0x0])?_0x368328[0x0]:parseInt(_0x368328[0x0],0xa),_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x1640')]=_0x368328[_0xa9549f('0x233')](0x1,_0x368328[_0xa9549f('0x264b')])[_0xa9549f('0x45a')](',');}break;case _0xa9549f('0x1e70'):_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x1640')]=_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x823')];break;case'set':_0x2051a4['close']['name']=_0x2051a4[_0xa9549f('0x1a7b')]['appdata'][_0xa9549f('0x25c8')]('=')[0x0],_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x18e0')]=_0x2051a4[_0xa9549f('0x1a7b')]['appdata'][_0xa9549f('0x25c8')]('=')[0x1];break;case _0xa9549f('0x1034'):_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x2588')]=_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x823')];break;default:{const _0xd3e3d8=_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x823')][_0xa9549f('0x25c8')](',');_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x12e8')]=_0x2cfb05()[_0xa9549f('0x1081')](_0xd3e3d8[0x0])?_0xd3e3d8[0x0]:isNaN(_0xd3e3d8[0x0])?_0xd3e3d8[0x0]:parseInt(_0xd3e3d8[0x0],0xa);}break;}else{}_0x2051a4['close']['type']&&_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x1345')][_0xa9549f('0x2574')]()===_0xa9549f('0x587')&&_0x2051a4['close']['appType'][_0xa9549f('0x2574')]()==='outbounddial'&&(_0x2051a4['close']['prefix']=_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x2026')]?_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x2026')][_0xa9549f('0x25c8')]('$')[0x0]:undefined,_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x1f02')]=_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x992')]?_0xa9549f('0xa4c')+_0x2051a4[_0xa9549f('0x1a7b')][_0xa9549f('0x992')]:undefined);_0x2051a4[_0xa9549f('0x2871')]=_0x30e769,_0x2051a4[_0xa9549f('0x24a0')]=_0x566cb5;function _0x30e769(){const _0x3816ae=_0xa9549f;_0x2051a4[_0x3816ae('0x61a')]=[];const _0x270005=[];_0x2051a4['close'][_0x3816ae('0x1345')]&&_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0x1345')][_0x3816ae('0x2574')]()===_0x3816ae('0x587')&&_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0x83f')]===_0x3816ae('0x867')&&(_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0x2026')]=_0x8c1ea2[_0x3816ae('0x2848')]?(_0x2051a4[_0x3816ae('0x1a7b')]['prefix']||'')+'${EXTEN:'+_0x8c1ea2[_0x3816ae('0x2848')]+'}':(_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0x265a')]||'')+_0x3816ae('0x1d1'),_0x8c1ea2['recordingFormat']!==_0x3816ae('0x192')?_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0xd39')]['indexOf']('U(xcally-mixmonitor-context)')<0x0&&(_0x2051a4['close']['options']+=_0x3816ae('0x1059')):_0x2051a4['close'][_0x3816ae('0xd39')]=_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0xd39')][_0x3816ae('0xf3')](_0x3816ae('0x1059'),''));if(_0x2051a4['close']['appType']&&_0x2051a4['close']['appType']==='custom'){}else switch((_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0x746')]||_0x2051a4[_0x3816ae('0x1a7b')]['appType'])['toLowerCase']()){case _0x3816ae('0xceb'):_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0x823')]=_0x2051a4[_0x3816ae('0x1a7b')]['name']+'='+_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0x18e0')];break;case _0x3816ae('0x2853'):break;default:_0x270005[0x0]=_0x2051a4[_0x3816ae('0x1a7b')][_0x3816ae('0x12e8')],_0x2051a4[_0x3816ae('0x1a7b')]['appdata']=_0x270005[_0x3816ae('0x45a')](',');}_0x566cb5(_0x2051a4['close']);}function _0x566cb5(_0x500746){_0x1ea703['hide'](_0x500746);}}const _0x38e0c5=_0x42978b;_0x57433f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1990'),_0x36e6f4('0x21b9'),_0x36e6f4('0x19e3'),'Auth','crudPermissions'];function _0x57433f(_0x3e4133,_0xcfec9c,_0x402547,_0x518eb2,_0x24d531,_0x42a7bf,_0x57c706,_0x576cb9){const _0x50cc70=_0x36e6f4,_0x463a66=this;_0x463a66[_0x50cc70('0x98')]=_0x57c706[_0x50cc70('0x26cd')](),_0x463a66['errors']=[],_0x463a66['title']='MAIL.EDIT_'+(_0x518eb2[_0x50cc70('0x83f')]||_0x518eb2[_0x50cc70('0x746')])[_0x50cc70('0x1387')](),_0x463a66[_0x50cc70('0x30f')]=angular[_0x50cc70('0x225f')](_0x518eb2),_0x463a66[_0x50cc70('0x243c')]=_0x576cb9,_0x463a66[_0x50cc70('0x128b')]={};if(_0x463a66[_0x50cc70('0x30f')]['appdata'])switch(_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x83f')]?_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x83f')][_0x50cc70('0x2574')]():_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x746')][_0x50cc70('0x2574')]()){case _0x50cc70('0x2853'):break;case _0x50cc70('0xded'):{const _0xc9185c=_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x823')][_0x50cc70('0x25c8')](',');_0x463a66['gotoif']['key']=_0xc9185c[0x0],_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0xedb')]=_0xc9185c[0x1],_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x1634')]=_0xc9185c['slice'](0x2,_0xc9185c['length'])[_0x50cc70('0x45a')](',');}break;case _0x50cc70('0x1636'):{const _0x5cfbb3=_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x823')][_0x50cc70('0x25c8')](',');_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x1b0a')]=_0x5cfbb3[0x0],_0x463a66[_0x50cc70('0x30f')]['clientEmail']=_0x5cfbb3[0x1],_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x170e')]=_0x5cfbb3[0x2],_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0xedb')]=_0x5cfbb3[0x3],_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x1634')]=_0x5cfbb3[_0x50cc70('0x233')](0x4,_0x5cfbb3[_0x50cc70('0x264b')])[_0x50cc70('0x45a')](',');}break;case _0x50cc70('0x86c'):{const _0x34d843=_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x823')]['split'](',');_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0xee6')]=_0x34d843[0x0],_0x463a66[_0x50cc70('0x30f')]['secretaccesskey']=_0x34d843[0x1],_0x463a66['gotoif'][_0x50cc70('0x25a2')]=_0x34d843[0x2],_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x1ac4')]=_0x34d843[0x3],_0x463a66[_0x50cc70('0x30f')]['welcomemessage']=_0x34d843[_0x50cc70('0x233')](0x4,_0x34d843[_0x50cc70('0x264b')])[_0x50cc70('0x45a')](',');}break;case _0x50cc70('0x1af7'):{const _0x2fd263=_0x463a66['gotoif'][_0x50cc70('0x823')][_0x50cc70('0x25c8')](',');_0x463a66[_0x50cc70('0x30f')]['times']=isNaN(_0x2fd263[0x0])?_0x2fd263[0x0]:parseInt(_0x2fd263[0x0],0xa),_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x1640')]=_0x2fd263[_0x50cc70('0x233')](0x1,_0x2fd263[_0x50cc70('0x264b')])[_0x50cc70('0x45a')](',');}break;case _0x50cc70('0x1e70'):_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x1640')]=_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x823')];break;case _0x50cc70('0xceb'):_0x463a66[_0x50cc70('0x30f')]['name']=_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x823')][_0x50cc70('0x25c8')]('=')[0x0],_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x18e0')]=_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x823')][_0x50cc70('0x25c8')]('=')[0x1];break;case _0x50cc70('0x1034'):_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x2588')]=_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x823')];break;default:{const _0x1812bc=_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x823')][_0x50cc70('0x25c8')](',');_0x463a66[_0x50cc70('0x30f')]['condition']=_0x2cfb05()[_0x50cc70('0x1081')](_0x1812bc[0x0])?_0x1812bc[0x0]:isNaN(_0x1812bc[0x0])?_0x1812bc[0x0]:parseInt(_0x1812bc[0x0],0xa),_0x463a66['gotoif']['truepriority']=_0x2cfb05()['isEmpty'](_0x1812bc[0x1])?_0x1812bc[0x1]:isNaN(_0x1812bc[0x1])?_0x1812bc[0x1]:parseInt(_0x1812bc[0x1],0xa),_0x463a66['gotoif'][_0x50cc70('0x1d7a')]=_0x2cfb05()[_0x50cc70('0x1081')](_0x1812bc[0x2])?_0x1812bc[0x2]:isNaN(_0x1812bc[0x2])?_0x1812bc[0x2]:parseInt(_0x1812bc[0x2],0xa);}break;}else{}_0x463a66[_0x50cc70('0x30f')]['type']&&_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x1345')][_0x50cc70('0x2574')]()===_0x50cc70('0x587')&&_0x463a66['gotoif'][_0x50cc70('0x83f')][_0x50cc70('0x2574')]()===_0x50cc70('0x2884')&&(_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x265a')]=_0x463a66['gotoif'][_0x50cc70('0x2026')]?_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x2026')][_0x50cc70('0x25c8')]('$')[0x0]:undefined,_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x1f02')]=_0x463a66['gotoif'][_0x50cc70('0x992')]?'CALLERID(all)='+_0x463a66[_0x50cc70('0x30f')][_0x50cc70('0x992')]:undefined);_0x463a66[_0x50cc70('0x2871')]=_0x26767a,_0x463a66[_0x50cc70('0x24a0')]=_0x5d4873;function _0x26767a(){const _0x59bec1=_0x50cc70;_0x463a66[_0x59bec1('0x61a')]=[];const _0x17b500=[];_0x463a66[_0x59bec1('0x30f')][_0x59bec1('0x1345')]&&_0x463a66[_0x59bec1('0x30f')]['type'][_0x59bec1('0x2574')]()===_0x59bec1('0x587')&&_0x463a66[_0x59bec1('0x30f')]['appType']==='outboundDial'&&(_0x463a66[_0x59bec1('0x30f')][_0x59bec1('0x2026')]=_0x24d531[_0x59bec1('0x2848')]?(_0x463a66[_0x59bec1('0x30f')][_0x59bec1('0x265a')]||'')+'${EXTEN:'+_0x24d531['cutdigits']+'}':(_0x463a66[_0x59bec1('0x30f')][_0x59bec1('0x265a')]||'')+'${EXTEN}',_0x24d531[_0x59bec1('0x28cb')]!=='none'?_0x463a66[_0x59bec1('0x30f')][_0x59bec1('0xd39')]['indexOf'](_0x59bec1('0x1059'))<0x0&&(_0x463a66['gotoif'][_0x59bec1('0xd39')]+=_0x59bec1('0x1059')):_0x463a66[_0x59bec1('0x30f')]['options']=_0x463a66[_0x59bec1('0x30f')][_0x59bec1('0xd39')][_0x59bec1('0xf3')](_0x59bec1('0x1059'),''));if(_0x463a66[_0x59bec1('0x30f')][_0x59bec1('0x83f')]&&_0x463a66[_0x59bec1('0x30f')]['appType']===_0x59bec1('0x2853')){}else switch((_0x463a66['gotoif'][_0x59bec1('0x746')]||_0x463a66['gotoif'][_0x59bec1('0x83f')])['toLowerCase']()){case _0x59bec1('0xceb'):_0x463a66[_0x59bec1('0x30f')][_0x59bec1('0x823')]=_0x463a66['gotoif'][_0x59bec1('0x4f0')]+'='+_0x463a66['gotoif']['value'];break;case _0x59bec1('0x2853'):break;default:_0x17b500[0x0]=_0x463a66['gotoif'][_0x59bec1('0x8ff')],_0x17b500[0x1]=_0x463a66['gotoif']['truepriority'],_0x17b500[0x2]=_0x463a66[_0x59bec1('0x30f')][_0x59bec1('0x1d7a')],_0x463a66[_0x59bec1('0x30f')]['appdata']=_0x17b500[_0x59bec1('0x45a')](',');}_0x5d4873(_0x463a66[_0x59bec1('0x30f')]);}function _0x5d4873(_0x36e6d4){const _0x104945=_0x50cc70;_0x3e4133[_0x104945('0x1197')](_0x36e6d4);}}const _0x32d432=_0x57433f;_0x4fa44f[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),'mailAccountApp',_0x36e6f4('0x21b9'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x4fa44f(_0xc0b9b4,_0xed37de,_0x53b3ac,_0x152694,_0x35eb84,_0x18d6fc,_0x360aea,_0x412b5b){const _0x19e400=_0x36e6f4,_0x3f93ef=this;_0x3f93ef[_0x19e400('0x98')]=_0x360aea[_0x19e400('0x26cd')](),_0x3f93ef[_0x19e400('0x61a')]=[],_0x3f93ef[_0x19e400('0xcdc')]='MAIL.EDIT_'+(_0x152694['appType']||_0x152694[_0x19e400('0x746')])[_0x19e400('0x1387')](),_0x3f93ef['gotop']=angular[_0x19e400('0x225f')](_0x152694),_0x3f93ef[_0x19e400('0x243c')]=_0x412b5b,_0x3f93ef[_0x19e400('0x128b')]={};if(_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x823')])switch(_0x3f93ef['gotop'][_0x19e400('0x83f')]?_0x3f93ef['gotop'][_0x19e400('0x83f')][_0x19e400('0x2574')]():_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x746')][_0x19e400('0x2574')]()){case _0x19e400('0x2853'):break;case _0x19e400('0xded'):{const _0x51a8dc=_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x823')][_0x19e400('0x25c8')](',');_0x3f93ef[_0x19e400('0x6e6')]['key']=_0x51a8dc[0x0],_0x3f93ef['gotop'][_0x19e400('0xedb')]=_0x51a8dc[0x1],_0x3f93ef['gotop'][_0x19e400('0x1634')]=_0x51a8dc[_0x19e400('0x233')](0x2,_0x51a8dc[_0x19e400('0x264b')])[_0x19e400('0x45a')](',');}break;case _0x19e400('0x1636'):{const _0x23db6d=_0x3f93ef['gotop'][_0x19e400('0x823')][_0x19e400('0x25c8')](',');_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x1b0a')]=_0x23db6d[0x0],_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x27f3')]=_0x23db6d[0x1],_0x3f93ef['gotop']['privateKey']=_0x23db6d[0x2],_0x3f93ef[_0x19e400('0x6e6')]['language']=_0x23db6d[0x3],_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x1634')]=_0x23db6d['slice'](0x4,_0x23db6d[_0x19e400('0x264b')])[_0x19e400('0x45a')](',');}break;case _0x19e400('0x86c'):{const _0x342a41=_0x3f93ef[_0x19e400('0x6e6')]['appdata']['split'](',');_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0xee6')]=_0x342a41[0x0],_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x125')]=_0x342a41[0x1],_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x25a2')]=_0x342a41[0x2],_0x3f93ef[_0x19e400('0x6e6')]['botname']=_0x342a41[0x3],_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x1634')]=_0x342a41['slice'](0x4,_0x342a41['length'])[_0x19e400('0x45a')](',');}break;case'autoreply':{const _0x551b08=_0x3f93ef['gotop'][_0x19e400('0x823')][_0x19e400('0x25c8')](',');_0x3f93ef['gotop']['times']=isNaN(_0x551b08[0x0])?_0x551b08[0x0]:parseInt(_0x551b08[0x0],0xa),_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x1640')]=_0x551b08['slice'](0x1,_0x551b08[_0x19e400('0x264b')])[_0x19e400('0x45a')](',');}break;case _0x19e400('0x1e70'):_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x1640')]=_0x3f93ef['gotop'][_0x19e400('0x823')];break;case _0x19e400('0xceb'):_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x4f0')]=_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x823')][_0x19e400('0x25c8')]('=')[0x0],_0x3f93ef['gotop'][_0x19e400('0x18e0')]=_0x3f93ef['gotop'][_0x19e400('0x823')][_0x19e400('0x25c8')]('=')[0x1];break;case'agi':_0x3f93ef['gotop'][_0x19e400('0x2588')]=_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x823')];break;default:{const _0x1f8430=_0x3f93ef['gotop'][_0x19e400('0x823')][_0x19e400('0x25c8')](',');_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0xfde')]=_0x2cfb05()[_0x19e400('0x1081')](_0x1f8430[0x0])?_0x1f8430[0x0]:isNaN(_0x1f8430[0x0])?_0x1f8430[0x0]:parseInt(_0x1f8430[0x0],0xa);}break;}else{}_0x3f93ef['gotop']['type']&&_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x1345')][_0x19e400('0x2574')]()===_0x19e400('0x587')&&_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x83f')][_0x19e400('0x2574')]()===_0x19e400('0x2884')&&(_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x265a')]=_0x3f93ef['gotop'][_0x19e400('0x2026')]?_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x2026')]['split']('$')[0x0]:undefined,_0x3f93ef[_0x19e400('0x6e6')]['callerId']=_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x992')]?_0x19e400('0xa4c')+_0x3f93ef[_0x19e400('0x6e6')][_0x19e400('0x992')]:undefined);_0x3f93ef[_0x19e400('0x2871')]=_0x54efa0,_0x3f93ef[_0x19e400('0x24a0')]=_0x133f85;function _0x54efa0(){const _0x384633=_0x19e400;_0x3f93ef['errors']=[];const _0x1e0275=[];_0x3f93ef[_0x384633('0x6e6')][_0x384633('0x1345')]&&_0x3f93ef[_0x384633('0x6e6')][_0x384633('0x1345')][_0x384633('0x2574')]()==='outbound'&&_0x3f93ef[_0x384633('0x6e6')][_0x384633('0x83f')]===_0x384633('0x867')&&(_0x3f93ef[_0x384633('0x6e6')]['phone']=_0x35eb84[_0x384633('0x2848')]?(_0x3f93ef[_0x384633('0x6e6')][_0x384633('0x265a')]||'')+'${EXTEN:'+_0x35eb84[_0x384633('0x2848')]+'}':(_0x3f93ef[_0x384633('0x6e6')][_0x384633('0x265a')]||'')+_0x384633('0x1d1'),_0x35eb84['recordingFormat']!==_0x384633('0x192')?_0x3f93ef[_0x384633('0x6e6')][_0x384633('0xd39')][_0x384633('0x2379')](_0x384633('0x1059'))<0x0&&(_0x3f93ef[_0x384633('0x6e6')][_0x384633('0xd39')]+=_0x384633('0x1059')):_0x3f93ef[_0x384633('0x6e6')][_0x384633('0xd39')]=_0x3f93ef[_0x384633('0x6e6')][_0x384633('0xd39')][_0x384633('0xf3')](_0x384633('0x1059'),''));if(_0x3f93ef['gotop'][_0x384633('0x83f')]&&_0x3f93ef[_0x384633('0x6e6')][_0x384633('0x83f')]===_0x384633('0x2853')){}else switch((_0x3f93ef[_0x384633('0x6e6')]['app']||_0x3f93ef['gotop']['appType'])[_0x384633('0x2574')]()){case _0x384633('0xceb'):_0x3f93ef[_0x384633('0x6e6')]['appdata']=_0x3f93ef[_0x384633('0x6e6')][_0x384633('0x4f0')]+'='+_0x3f93ef['gotop']['value'];break;case _0x384633('0x2853'):break;default:_0x1e0275[0x0]=_0x3f93ef['gotop'][_0x384633('0xfde')],_0x3f93ef['gotop']['appdata']=_0x1e0275[_0x384633('0x45a')](',');}_0x133f85(_0x3f93ef[_0x384633('0x6e6')]);}function _0x133f85(_0x47abd0){const _0x28f6c0=_0x19e400;_0xc0b9b4[_0x28f6c0('0x1197')](_0x47abd0);}}const _0xf53356=_0x4fa44f;_0x29cdfc[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x265d'),_0x36e6f4('0x25d0'),_0x36e6f4('0x124d'),'interval',_0x36e6f4('0x164e'),_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x29cdfc(_0x1c13c5,_0x4d2905,_0x382bc9,_0x3c6851,_0xb0890a,_0x375240,_0x128f93,_0x14d7ce,_0x5c6ba9,_0x46037c){const _0x211742=_0x36e6f4,_0x363692=this;_0x363692[_0x211742('0x98')]=_0x5c6ba9['getCurrentUser'](),_0x363692[_0x211742('0x61a')]=[],_0x363692[_0x211742('0xcdc')]=_0x211742('0x2879'),_0x363692[_0x211742('0x277c')]=angular[_0x211742('0x225f')](_0xb0890a),_0x363692[_0x211742('0x164e')]=_0x375240,_0x363692[_0x211742('0x99d')]=![],_0x363692[_0x211742('0x6aa')]=['always',_0x211742('0x2853'),_0x211742('0x1480')],_0x363692[_0x211742('0x243c')]=_0x46037c,_0x363692[_0x211742('0x5ef')]=_0x3c6851[_0x211742('0x28de')](),_0x363692[_0x211742('0x10b4')]=_0x3c6851[_0x211742('0x51d')](),_0x363692[_0x211742('0x2259')]=_0x3c6851[_0x211742('0x1c39')](),_0x363692['daysOfMonth']=_0x3c6851[_0x211742('0x2489')]();if(!_0x363692[_0x211742('0x277c')])_0x363692[_0x211742('0x277c')]={'interval':_0x211742('0x16f')},_0x363692[_0x211742('0x1345')]=_0x211742('0x597'),_0x363692[_0x211742('0xcdc')]='TOOLS.NEW_INTERVAL',_0x363692[_0x211742('0x99d')]=!![];else{if(_0x363692['interval'][_0x211742('0x277c')]!==_0x211742('0x16f')){_0x363692['type']=_0x211742('0x2853');const _0x349a6c=_0x363692[_0x211742('0x277c')][_0x211742('0x277c')][_0x211742('0x25c8')](','),_0x3067de=_0x349a6c[0x0],_0x3cbdff=_0x349a6c[0x1],_0x2c3af7=_0x349a6c[0x2],_0x165cf0=_0x349a6c[0x3];if(_0x3067de!=='*'){const _0x3d3918=_0x3067de[_0x211742('0x25c8')]('-')[0x0],_0x315d89=_0x3067de[_0x211742('0x25c8')]('-')[0x1];let _0x1afdc2;_0x1afdc2=new Date(),_0x1afdc2['setHours'](Number(_0x3d3918[_0x211742('0x25c8')](':')[0x0])),_0x1afdc2[_0x211742('0x790')](Number(_0x3d3918[_0x211742('0x25c8')](':')[0x1])),_0x363692[_0x211742('0x64d')]=_0x1afdc2,_0x1afdc2=new Date(),_0x1afdc2[_0x211742('0xe24')](Number(_0x315d89[_0x211742('0x25c8')](':')[0x0])),_0x1afdc2[_0x211742('0x790')](Number(_0x315d89[_0x211742('0x25c8')](':')[0x1])),_0x363692[_0x211742('0x2076')]=_0x1afdc2;}_0x3cbdff!=='*'&&(_0x363692[_0x211742('0x1eca')]=_0x3cbdff[_0x211742('0x25c8')]('-')[0x0],_0x363692[_0x211742('0x1b81')]=_0x3cbdff[_0x211742('0x25c8')]('-')[0x1]),_0x2c3af7!=='*'&&(_0x363692[_0x211742('0x103d')]=_0x2c3af7['split']('-')[0x0],_0x363692[_0x211742('0x1dbb')]=_0x2c3af7[_0x211742('0x25c8')]('-')[0x1]),_0x165cf0!=='*'&&(_0x363692[_0x211742('0xdec')]=_0x165cf0[_0x211742('0x25c8')]('-')[0x0],_0x363692[_0x211742('0x1125')]=_0x165cf0[_0x211742('0x25c8')]('-')[0x1]);}else _0x363692[_0x211742('0x1345')]=_0x211742('0x597');}_0x1c13c5['params']['id']&&!_0x363692[_0x211742('0x277c')][_0x211742('0x50d')]&&(_0x363692[_0x211742('0x277c')][_0x211742('0x186f')]=_0x1c13c5[_0x211742('0x23f')]['id']);_0x363692[_0x211742('0x277c')]['IntervalId']&&_0x363692['interval'][_0x211742('0x50d')]&&(_0x363692[_0x211742('0x1345')]=_0x211742('0x1480'));_0x363692['addNewInterval']=_0x228829,_0x363692['saveInterval']=_0x1bf830,_0x363692[_0x211742('0x24a0')]=_0x55f248;_0x363692[_0x211742('0x277c')]['application']&&(_0x5c6ba9['hasRole'](_0x211742('0xa7c'))?_0x14d7ce[_0x211742('0x277c')][_0x211742('0xd83')]({'fields':_0x211742('0xd0a'),'IntervalId':'null','nolimit':!![]})[_0x211742('0xa44')]['then'](function(_0x3622ea){const _0x1cae29=_0x211742;_0x363692['intervals']=_0x3622ea[_0x1cae29('0x269a')]||[];})[_0x211742('0x1a80')](function(_0x83c43e){const _0x4c4631=_0x211742;_0x128f93[_0x4c4631('0xfc9')]({'title':_0x83c43e[_0x4c4631('0x52d')]?_0x4c4631('0x1e21')+_0x83c43e[_0x4c4631('0x52d')]+_0x4c4631('0x11e1')+_0x83c43e[_0x4c4631('0xe1b')]:_0x4c4631('0xbb4'),'msg':_0x83c43e[_0x4c4631('0x25f4')]?JSON[_0x4c4631('0xbac')](_0x83c43e['data']):_0x83c43e[_0x4c4631('0x1586')]()});}):_0x14d7ce[_0x211742('0x277c')]['get']({'fields':_0x211742('0xd0a'),'IntervalId':_0x211742('0x15d7'),'nolimit':!![]})['$promise'][_0x211742('0x1166')](function(_0x17589c){_0x363692['intervals']=_0x17589c['rows']||[];})[_0x211742('0x1166')](function(){const _0x3e1042=_0x211742;return _0x14d7ce[_0x3e1042('0x17aa')][_0x3e1042('0xd83')]({'userProfileId':_0x363692['currentUser'][_0x3e1042('0xb86')],'sectionId':0x3ec})[_0x3e1042('0xa44')];})[_0x211742('0x1166')](function(_0x14a249){const _0x4c70ad=_0x211742,_0x5b92f6=_0x14a249&&_0x14a249[_0x4c70ad('0x269a')]?_0x14a249[_0x4c70ad('0x269a')][0x0]:null;if(!_0x5b92f6)_0x363692[_0x4c70ad('0x164e')]=[];else{if(!_0x5b92f6[_0x4c70ad('0x1a2b')])return _0x14d7ce[_0x4c70ad('0x4b5')][_0x4c70ad('0xd83')]({'sectionId':_0x5b92f6['id']})['$promise'][_0x4c70ad('0x1166')](function(_0x1ba349){const _0x54b552=_0x4c70ad,_0x5229c9=_0x1ba349&&_0x1ba349[_0x54b552('0x269a')]?_0x1ba349['rows']:[],_0x1afd25=[];let _0x5385a7=null;_0x363692[_0x54b552('0x277c')]&&(_0x5385a7=_0x2cfb05()[_0x54b552('0xc38')](_0x363692[_0x54b552('0x164e')],{'name':_0x363692[_0x54b552('0x277c')][_0x54b552('0x186f')]})),_0x5385a7&&!_0x2cfb05()[_0x54b552('0x1798')](_0x5229c9,[_0x54b552('0x24e8'),_0x5385a7['id']])&&_0x363692[_0x54b552('0x164e')][_0x54b552('0x2782')](function(_0x39df36){const _0x731962=_0x54b552;_0x39df36['id']===_0x5385a7['id']&&(_0x39df36[_0x731962('0x2378')]=![],_0x1afd25['push'](_0x39df36));}),_0x363692['intervals']=_0x1afd25;});}})[_0x211742('0x1a80')](function(_0x148acb){const _0x40424b=_0x211742;_0x128f93[_0x40424b('0xfc9')]({'title':_0x148acb[_0x40424b('0x52d')]?'API:'+_0x148acb[_0x40424b('0x52d')]+'\x20-\x20'+_0x148acb['statusText']:'SYSTEM:GET_INTERVALS','msg':_0x148acb[_0x40424b('0x25f4')]?JSON[_0x40424b('0xbac')](_0x148acb['data']):_0x148acb[_0x40424b('0x1586')]()});}));function _0x5f28a8(){const _0x58c191=_0x211742;switch(_0x363692[_0x58c191('0x1345')]){case _0x58c191('0x597'):case _0x58c191('0x1480'):return _0x58c191('0x16f');case _0x58c191('0x2853'):{const _0x12a5d0=[];if(_0x363692[_0x58c191('0x64d')]!=='*'&&_0x363692[_0x58c191('0x64d')]&&_0x363692[_0x58c191('0x2076')]){const _0x575722=(_0x363692[_0x58c191('0x64d')][_0x58c191('0x11fe')]()<0xa?'0':'')+_0x363692[_0x58c191('0x64d')]['getHours']()+':'+((_0x363692[_0x58c191('0x64d')][_0x58c191('0x234')]()<0xa?'0':'')+_0x363692[_0x58c191('0x64d')][_0x58c191('0x234')]()),_0x55f919=(_0x363692[_0x58c191('0x2076')][_0x58c191('0x11fe')]()<0xa?'0':'')+_0x363692['timeRangeTo'][_0x58c191('0x11fe')]()+':'+((_0x363692[_0x58c191('0x2076')][_0x58c191('0x234')]()<0xa?'0':'')+_0x363692[_0x58c191('0x2076')][_0x58c191('0x234')]());_0x12a5d0['push'](_0x575722+'-'+_0x55f919);}else _0x12a5d0['push']('*');return _0x363692[_0x58c191('0x1eca')]?_0x363692[_0x58c191('0x1b81')]?_0x12a5d0[_0x58c191('0x1514')](_0x363692[_0x58c191('0x1eca')]+'-'+_0x363692[_0x58c191('0x1b81')]):_0x12a5d0[_0x58c191('0x1514')](_0x363692[_0x58c191('0x1eca')]):_0x12a5d0[_0x58c191('0x1514')]('*'),_0x363692['monthDayFrom']?_0x363692[_0x58c191('0x1dbb')]?_0x12a5d0[_0x58c191('0x1514')](_0x363692[_0x58c191('0x103d')]+'-'+_0x363692['monthDayTo']):_0x12a5d0['push'](_0x363692[_0x58c191('0x103d')]):_0x12a5d0['push']('*'),_0x363692[_0x58c191('0xdec')]?_0x363692['monthTo']?_0x12a5d0[_0x58c191('0x1514')](_0x363692[_0x58c191('0xdec')]+'-'+_0x363692['monthTo']):_0x12a5d0['push'](_0x363692[_0x58c191('0xdec')]):_0x12a5d0[_0x58c191('0x1514')]('*'),_0x12a5d0[_0x58c191('0x45a')]();}}}function _0x228829(){const _0x207f66=_0x211742;_0x363692[_0x207f66('0x61a')]=[],_0x363692[_0x207f66('0x277c')][_0x207f66('0x277c')]=_0x5f28a8(),_0x14d7ce[_0x207f66('0x277c')]['save'](_0x363692[_0x207f66('0x277c')])[_0x207f66('0xa44')]['then'](function(_0x1cb7e4){const _0x2fe62a=_0x207f66;_0x363692[_0x2fe62a('0x164e')]['push'](_0x1cb7e4),_0x128f93[_0x2fe62a('0x103b')]({'title':_0x2fe62a('0xf10'),'msg':_0x363692[_0x2fe62a('0x277c')][_0x2fe62a('0x4f0')]?_0x363692[_0x2fe62a('0x277c')][_0x2fe62a('0x4f0')]+_0x2fe62a('0x1eda'):''}),_0x55f248();})[_0x207f66('0x1a80')](function(_0x6d1d10){const _0x51b76f=_0x207f66;console['error'](_0x6d1d10),_0x363692['errors']=_0x6d1d10[_0x51b76f('0x25f4')]['errors']||[{'message':_0x6d1d10[_0x51b76f('0x1586')](),'type':'api.interval.save'}];});}function _0x1bf830(){const _0x339257=_0x211742;_0x363692['errors']=[],_0x363692[_0x339257('0x277c')][_0x339257('0x277c')]=_0x5f28a8(),_0x363692[_0x339257('0x277c')][_0x339257('0x50d')]?(_0x363692[_0x339257('0x1345')]!==_0x339257('0x1480')&&(_0x363692['interval'][_0x339257('0x186f')]=null),_0x55f248(_0x363692[_0x339257('0x277c')])):_0x14d7ce[_0x339257('0x277c')][_0x339257('0x1449')]({'id':_0x363692[_0x339257('0x277c')]['id']},_0x363692[_0x339257('0x277c')])[_0x339257('0xa44')]['then'](function(_0x1f79fa){const _0x2468d3=_0x339257,_0x35e48a=_0x2cfb05()['find'](_0x363692['intervals'],{'id':_0x1f79fa['id']});_0x35e48a&&_0x2cfb05()[_0x2468d3('0xcc3')](_0x35e48a,_0x1f79fa),_0x128f93[_0x2468d3('0x103b')]({'title':'Interval\x20properly\x20saved!','msg':_0x2468d3('0x1666')}),_0x55f248();})[_0x339257('0x1a80')](function(_0xdf2b63){const _0x210863=_0x339257;console[_0x210863('0xfc9')](_0xdf2b63),_0x363692[_0x210863('0x61a')]=_0xdf2b63[_0x210863('0x25f4')][_0x210863('0x61a')]||[{'message':_0xdf2b63[_0x210863('0x1586')](),'type':'api.interval.update'}];});}function _0x55f248(_0x190a11){const _0x5c6899=_0x211742;_0x4d2905[_0x5c6899('0x1197')](_0x190a11);}}const _0x19be60=_0x29cdfc;_0x5c261a['$inject']=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1990'),'mailAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x5c261a(_0x37ee57,_0x2c4631,_0x358d5c,_0x165e2f,_0x8982d7,_0x4fabac,_0x25978a,_0x26347c){const _0x47933f=_0x36e6f4,_0x31c549=this;_0x31c549[_0x47933f('0x98')]=_0x25978a[_0x47933f('0x26cd')](),_0x31c549[_0x47933f('0x61a')]=[],_0x31c549[_0x47933f('0xcdc')]=_0x47933f('0x2132')+(_0x165e2f[_0x47933f('0x83f')]||_0x165e2f[_0x47933f('0x746')])[_0x47933f('0x1387')](),_0x31c549['noop']=angular[_0x47933f('0x225f')](_0x165e2f),_0x31c549[_0x47933f('0x243c')]=_0x26347c,_0x31c549[_0x47933f('0x128b')]={};if(_0x31c549[_0x47933f('0x2652')]['appdata'])switch(_0x31c549['noop'][_0x47933f('0x83f')]?_0x31c549['noop'][_0x47933f('0x83f')][_0x47933f('0x2574')]():_0x31c549['noop']['app'][_0x47933f('0x2574')]()){case'custom':break;case _0x47933f('0xded'):{const _0x10defe=_0x31c549[_0x47933f('0x2652')]['appdata'][_0x47933f('0x25c8')](',');_0x31c549[_0x47933f('0x2652')]['key']=_0x10defe[0x0],_0x31c549[_0x47933f('0x2652')][_0x47933f('0xedb')]=_0x10defe[0x1],_0x31c549[_0x47933f('0x2652')][_0x47933f('0x1634')]=_0x10defe[_0x47933f('0x233')](0x2,_0x10defe[_0x47933f('0x264b')])[_0x47933f('0x45a')](',');}break;case _0x47933f('0x1636'):{const _0x1c407b=_0x31c549[_0x47933f('0x2652')][_0x47933f('0x823')][_0x47933f('0x25c8')](',');_0x31c549[_0x47933f('0x2652')][_0x47933f('0x1b0a')]=_0x1c407b[0x0],_0x31c549[_0x47933f('0x2652')]['clientEmail']=_0x1c407b[0x1],_0x31c549[_0x47933f('0x2652')]['privateKey']=_0x1c407b[0x2],_0x31c549[_0x47933f('0x2652')][_0x47933f('0xedb')]=_0x1c407b[0x3],_0x31c549[_0x47933f('0x2652')][_0x47933f('0x1634')]=_0x1c407b[_0x47933f('0x233')](0x4,_0x1c407b[_0x47933f('0x264b')])[_0x47933f('0x45a')](',');}break;case _0x47933f('0x86c'):{const _0x31507c=_0x31c549['noop'][_0x47933f('0x823')][_0x47933f('0x25c8')](',');_0x31c549['noop'][_0x47933f('0xee6')]=_0x31507c[0x0],_0x31c549['noop'][_0x47933f('0x125')]=_0x31507c[0x1],_0x31c549[_0x47933f('0x2652')][_0x47933f('0x25a2')]=_0x31507c[0x2],_0x31c549['noop'][_0x47933f('0x1ac4')]=_0x31507c[0x3],_0x31c549['noop'][_0x47933f('0x1634')]=_0x31507c[_0x47933f('0x233')](0x4,_0x31507c[_0x47933f('0x264b')])['join'](',');}break;case'autoreply':{const _0x3ce830=_0x31c549['noop']['appdata'][_0x47933f('0x25c8')](',');_0x31c549['noop'][_0x47933f('0x265e')]=isNaN(_0x3ce830[0x0])?_0x3ce830[0x0]:parseInt(_0x3ce830[0x0],0xa),_0x31c549['noop'][_0x47933f('0x1640')]=_0x3ce830[_0x47933f('0x233')](0x1,_0x3ce830[_0x47933f('0x264b')])[_0x47933f('0x45a')](',');}break;case _0x47933f('0x1e70'):_0x31c549[_0x47933f('0x2652')]['text']=_0x31c549[_0x47933f('0x2652')][_0x47933f('0x823')];break;case _0x47933f('0xceb'):_0x31c549['noop'][_0x47933f('0x4f0')]=_0x31c549[_0x47933f('0x2652')]['appdata'][_0x47933f('0x25c8')]('=')[0x0],_0x31c549[_0x47933f('0x2652')][_0x47933f('0x18e0')]=_0x31c549['noop']['appdata'][_0x47933f('0x25c8')]('=')[0x1];break;case _0x47933f('0x1034'):_0x31c549[_0x47933f('0x2652')][_0x47933f('0x2588')]=_0x31c549['noop'][_0x47933f('0x823')];break;default:{const _0x4f177d=_0x31c549[_0x47933f('0x2652')]['appdata'][_0x47933f('0x25c8')](',');_0x31c549[_0x47933f('0x2652')]['value']=_0x2cfb05()['isEmpty'](_0x4f177d[0x0])?_0x4f177d[0x0]:isNaN(_0x4f177d[0x0])?_0x4f177d[0x0]:parseInt(_0x4f177d[0x0],0xa);}break;}else{}_0x31c549[_0x47933f('0x2652')][_0x47933f('0x1345')]&&_0x31c549['noop']['type'][_0x47933f('0x2574')]()===_0x47933f('0x587')&&_0x31c549[_0x47933f('0x2652')][_0x47933f('0x83f')][_0x47933f('0x2574')]()===_0x47933f('0x2884')&&(_0x31c549[_0x47933f('0x2652')]['prefix']=_0x31c549[_0x47933f('0x2652')][_0x47933f('0x2026')]?_0x31c549[_0x47933f('0x2652')][_0x47933f('0x2026')][_0x47933f('0x25c8')]('$')[0x0]:undefined,_0x31c549[_0x47933f('0x2652')][_0x47933f('0x1f02')]=_0x31c549[_0x47933f('0x2652')][_0x47933f('0x992')]?_0x47933f('0xa4c')+_0x31c549[_0x47933f('0x2652')][_0x47933f('0x992')]:undefined);_0x31c549[_0x47933f('0x2871')]=_0x41881d,_0x31c549[_0x47933f('0x24a0')]=_0x3b72ea;function _0x41881d(){const _0x3aaee9=_0x47933f;_0x31c549[_0x3aaee9('0x61a')]=[];const _0x2930a4=[];_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x1345')]&&_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x1345')][_0x3aaee9('0x2574')]()===_0x3aaee9('0x587')&&_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x83f')]===_0x3aaee9('0x867')&&(_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x2026')]=_0x8982d7[_0x3aaee9('0x2848')]?(_0x31c549[_0x3aaee9('0x2652')]['prefix']||'')+'${EXTEN:'+_0x8982d7[_0x3aaee9('0x2848')]+'}':(_0x31c549['noop'][_0x3aaee9('0x265a')]||'')+'${EXTEN}',_0x8982d7[_0x3aaee9('0x28cb')]!=='none'?_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0xd39')][_0x3aaee9('0x2379')](_0x3aaee9('0x1059'))<0x0&&(_0x31c549['noop'][_0x3aaee9('0xd39')]+='U(xcally-mixmonitor-context)'):_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0xd39')]=_0x31c549[_0x3aaee9('0x2652')]['options'][_0x3aaee9('0xf3')](_0x3aaee9('0x1059'),''));if(_0x31c549['noop'][_0x3aaee9('0x83f')]&&_0x31c549['noop']['appType']===_0x3aaee9('0x2853')){}else switch((_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x746')]||_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x83f')])[_0x3aaee9('0x2574')]()){case _0x3aaee9('0xceb'):_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x823')]=_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x4f0')]+'='+_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x18e0')];break;case _0x3aaee9('0x2853'):break;default:_0x2930a4[0x0]=_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x18e0')],_0x31c549[_0x3aaee9('0x2652')][_0x3aaee9('0x823')]=_0x2930a4['join'](',');}_0x3b72ea(_0x31c549[_0x3aaee9('0x2652')]);}function _0x3b72ea(_0x167ca4){_0x37ee57['hide'](_0x167ca4);}}const _0x460a5c=_0x5c261a;_0x128b45['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1990'),_0x36e6f4('0x21b9'),_0x36e6f4('0x19e3'),'Auth','crudPermissions'];function _0x128b45(_0x2c519e,_0x5bf4d2,_0x191dc0,_0x3647fc,_0x38da37,_0x477d7b,_0x57de54,_0x89d58f){const _0x2fde0c=_0x36e6f4,_0x3597bd=this;_0x3597bd[_0x2fde0c('0x98')]=_0x57de54[_0x2fde0c('0x26cd')](),_0x3597bd['errors']=[],_0x3597bd[_0x2fde0c('0xcdc')]=_0x2fde0c('0x2132')+(_0x3647fc[_0x2fde0c('0x83f')]||_0x3647fc[_0x2fde0c('0x746')])['toUpperCase'](),_0x3597bd[_0x2fde0c('0x1d3e')]=angular[_0x2fde0c('0x225f')](_0x3647fc),_0x3597bd[_0x2fde0c('0x243c')]=_0x89d58f,_0x3597bd['hasModulePermissions']={};if(_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x823')])switch(_0x3597bd['queue'][_0x2fde0c('0x83f')]?_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x83f')]['toLowerCase']():_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x746')]['toLowerCase']()){case _0x2fde0c('0x2853'):break;case _0x2fde0c('0xded'):{const _0x4d1e69=_0x3597bd['queue']['appdata'][_0x2fde0c('0x25c8')](',');_0x3597bd['queue'][_0x2fde0c('0x7ca')]=_0x4d1e69[0x0],_0x3597bd[_0x2fde0c('0x1d3e')]['language']=_0x4d1e69[0x1],_0x3597bd[_0x2fde0c('0x1d3e')]['welcomemessage']=_0x4d1e69[_0x2fde0c('0x233')](0x2,_0x4d1e69['length'])[_0x2fde0c('0x45a')](',');}break;case'dialogflowv2':{const _0xcf88e0=_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x823')][_0x2fde0c('0x25c8')](',');_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x1b0a')]=_0xcf88e0[0x0],_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x27f3')]=_0xcf88e0[0x1],_0x3597bd['queue'][_0x2fde0c('0x170e')]=_0xcf88e0[0x2],_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0xedb')]=_0xcf88e0[0x3],_0x3597bd['queue'][_0x2fde0c('0x1634')]=_0xcf88e0['slice'](0x4,_0xcf88e0[_0x2fde0c('0x264b')])[_0x2fde0c('0x45a')](',');}break;case _0x2fde0c('0x86c'):{const _0x4ccae8=_0x3597bd[_0x2fde0c('0x1d3e')]['appdata'][_0x2fde0c('0x25c8')](',');_0x3597bd['queue'][_0x2fde0c('0xee6')]=_0x4ccae8[0x0],_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x125')]=_0x4ccae8[0x1],_0x3597bd[_0x2fde0c('0x1d3e')]['lexregion']=_0x4ccae8[0x2],_0x3597bd[_0x2fde0c('0x1d3e')]['botname']=_0x4ccae8[0x3],_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x1634')]=_0x4ccae8[_0x2fde0c('0x233')](0x4,_0x4ccae8[_0x2fde0c('0x264b')])['join'](',');}break;case _0x2fde0c('0x1af7'):{const _0x2dbc2e=_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x823')]['split'](',');_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x265e')]=isNaN(_0x2dbc2e[0x0])?_0x2dbc2e[0x0]:parseInt(_0x2dbc2e[0x0],0xa),_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x1640')]=_0x2dbc2e[_0x2fde0c('0x233')](0x1,_0x2dbc2e[_0x2fde0c('0x264b')])[_0x2fde0c('0x45a')](',');}break;case _0x2fde0c('0x1e70'):_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x1640')]=_0x3597bd['queue'][_0x2fde0c('0x823')];break;case'set':_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x4f0')]=_0x3597bd[_0x2fde0c('0x1d3e')]['appdata'][_0x2fde0c('0x25c8')]('=')[0x0],_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x18e0')]=_0x3597bd['queue']['appdata'][_0x2fde0c('0x25c8')]('=')[0x1];break;case'agi':_0x3597bd['queue'][_0x2fde0c('0x2588')]=_0x3597bd['queue'][_0x2fde0c('0x823')];break;default:{const _0x4c6adc=_0x3597bd['queue'][_0x2fde0c('0x823')][_0x2fde0c('0x25c8')](',');_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x1d3e')]=_0x2cfb05()[_0x2fde0c('0x1081')](_0x4c6adc[0x0])?_0x4c6adc[0x0]:isNaN(_0x4c6adc[0x0])?_0x4c6adc[0x0]:parseInt(_0x4c6adc[0x0],0xa),_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x651')]=_0x2cfb05()['isEmpty'](_0x4c6adc[0x1])?_0x4c6adc[0x1]:isNaN(_0x4c6adc[0x1])?_0x4c6adc[0x1]:parseInt(_0x4c6adc[0x1],0xa);}break;}else _0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x1d3e')]=0x12c,_0x3597bd[_0x2fde0c('0x1d3e')]['timeout']=0x12c;_0x3597bd['queue'][_0x2fde0c('0x1345')]&&_0x3597bd[_0x2fde0c('0x1d3e')]['type'][_0x2fde0c('0x2574')]()===_0x2fde0c('0x587')&&_0x3597bd[_0x2fde0c('0x1d3e')]['appType']['toLowerCase']()===_0x2fde0c('0x2884')&&(_0x3597bd['queue']['prefix']=_0x3597bd['queue'][_0x2fde0c('0x2026')]?_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x2026')][_0x2fde0c('0x25c8')]('$')[0x0]:undefined,_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x1f02')]=_0x3597bd[_0x2fde0c('0x1d3e')]['callerID']?_0x2fde0c('0xa4c')+_0x3597bd[_0x2fde0c('0x1d3e')][_0x2fde0c('0x992')]:undefined);_0x3597bd[_0x2fde0c('0x2871')]=_0x2f5702,_0x3597bd['closeDialog']=_0x37358e,_0x57de54['hasRole']('admin')?_0x477d7b[_0x2fde0c('0x24c9')]['get']({'fields':'id,name,type','sort':'name','nolimit':_0x2fde0c('0xf3b')})[_0x2fde0c('0xa44')][_0x2fde0c('0x1166')](function(_0x493183){const _0x5bdc0e=_0x2fde0c;_0x3597bd[_0x5bdc0e('0x7a7')]=_0x493183[_0x5bdc0e('0x269a')]||[];})[_0x2fde0c('0x1a80')](function(_0x1e3aae){const _0x1440fc=_0x2fde0c;_0x191dc0[_0x1440fc('0xfc9')]({'title':_0x1e3aae['status']?'API:'+_0x1e3aae['status']+_0x1440fc('0x11e1')+_0x1e3aae['statusText']:'SYSTEM:GET_QUEUES','msg':_0x1e3aae[_0x1440fc('0x25f4')]?JSON[_0x1440fc('0xbac')](_0x1e3aae['data']):_0x1e3aae[_0x1440fc('0x1586')]()});}):_0x477d7b[_0x2fde0c('0x24c9')][_0x2fde0c('0xd83')]({'fields':_0x2fde0c('0x1c09'),'sort':_0x2fde0c('0x4f0'),'nolimit':_0x2fde0c('0xf3b')})['$promise'][_0x2fde0c('0x1166')](function(_0x290614){const _0x35f0c7=_0x2fde0c;_0x3597bd[_0x35f0c7('0x7a7')]=_0x290614[_0x35f0c7('0x269a')]||[];})['then'](function(){const _0x2ee81a=_0x2fde0c;return _0x477d7b['userProfileSection']['get']({'userProfileId':_0x3597bd[_0x2ee81a('0x98')]['userProfileId'],'sectionId':0x259})['$promise'];})['then'](function(_0x389f09){const _0x33b2cb=_0x2fde0c,_0x222acd=_0x389f09&&_0x389f09[_0x33b2cb('0x269a')]?_0x389f09[_0x33b2cb('0x269a')][0x0]:null;if(!_0x222acd){const _0x5a4cd2=[];let _0x4830a3=null;_0x3597bd[_0x33b2cb('0x1d3e')]&&(_0x4830a3=_0x2cfb05()[_0x33b2cb('0xc38')](_0x3597bd[_0x33b2cb('0x7a7')],{'name':_0x3597bd['queue'][_0x33b2cb('0x1d3e')]}));for(let _0x4d5781=0x0;_0x4d5781<_0x3597bd['queues'][_0x33b2cb('0x264b')];_0x4d5781++){_0x4830a3&&_0x3597bd[_0x33b2cb('0x7a7')][_0x4d5781]['id']===_0x4830a3['id']&&(_0x3597bd[_0x33b2cb('0x7a7')][_0x4d5781][_0x33b2cb('0x2378')]=![],_0x5a4cd2[_0x33b2cb('0x1514')](_0x3597bd['queues'][_0x4d5781]));}_0x3597bd[_0x33b2cb('0x7a7')]=_0x5a4cd2;}else{if(!_0x222acd[_0x33b2cb('0x1a2b')])return _0x477d7b[_0x33b2cb('0x4b5')]['get']({'sectionId':_0x222acd['id']})[_0x33b2cb('0xa44')]['then'](function(_0xcfc968){const _0x4bf3a1=_0x33b2cb,_0x3a043b=_0x2cfb05()[_0x4bf3a1('0x2563')](_0xcfc968[_0x4bf3a1('0x269a')],function(_0x4116f4){const _0xd8dacf=_0x4bf3a1;return _0x2cfb05()[_0xd8dacf('0xc38')](_0x3597bd[_0xd8dacf('0x7a7')],{'id':_0x4116f4[_0xd8dacf('0x24e8')]});});let _0x3f9151=null;_0x3597bd[_0x4bf3a1('0x1d3e')]&&(_0x3f9151=_0x2cfb05()[_0x4bf3a1('0xc38')](_0x3597bd[_0x4bf3a1('0x7a7')],{'name':_0x3597bd[_0x4bf3a1('0x1d3e')][_0x4bf3a1('0x1d3e')]}));if(_0x3f9151&&!_0x2cfb05()[_0x4bf3a1('0x1798')](_0x3a043b,['id',_0x3f9151['id']])){const _0x17f6b8=_0x2cfb05()[_0x4bf3a1('0xc38')](_0x3597bd[_0x4bf3a1('0x7a7')],{'id':_0x3f9151['id']});_0x17f6b8['canSelect']=![],_0x3a043b[_0x4bf3a1('0x1514')](_0x17f6b8);}_0x3597bd[_0x4bf3a1('0x7a7')]=_0x3a043b;});}})['catch'](function(_0x35ba13){const _0xc563c7=_0x2fde0c;_0x191dc0[_0xc563c7('0xfc9')]({'title':_0x35ba13[_0xc563c7('0x52d')]?_0xc563c7('0x1e21')+_0x35ba13[_0xc563c7('0x52d')]+_0xc563c7('0x11e1')+_0x35ba13[_0xc563c7('0xe1b')]:'SYSTEM:GETqueues','msg':_0x35ba13[_0xc563c7('0x25f4')]?JSON[_0xc563c7('0xbac')](_0x35ba13[_0xc563c7('0x25f4')]):_0x35ba13[_0xc563c7('0x1586')]()});});function _0x2f5702(){const _0x3b9314=_0x2fde0c;_0x3597bd['errors']=[];const _0x25dc78=[];_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0x1345')]&&_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0x1345')][_0x3b9314('0x2574')]()===_0x3b9314('0x587')&&_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0x83f')]===_0x3b9314('0x867')&&(_0x3597bd['queue'][_0x3b9314('0x2026')]=_0x38da37[_0x3b9314('0x2848')]?(_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0x265a')]||'')+_0x3b9314('0x881')+_0x38da37[_0x3b9314('0x2848')]+'}':(_0x3597bd['queue'][_0x3b9314('0x265a')]||'')+'${EXTEN}',_0x38da37[_0x3b9314('0x28cb')]!==_0x3b9314('0x192')?_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0xd39')]['indexOf'](_0x3b9314('0x1059'))<0x0&&(_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0xd39')]+='U(xcally-mixmonitor-context)'):_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0xd39')]=_0x3597bd['queue'][_0x3b9314('0xd39')]['replace']('U(xcally-mixmonitor-context)',''));const _0x3c8d3a=_0x2cfb05()[_0x3b9314('0xc38')](_0x3597bd[_0x3b9314('0x7a7')],{'name':_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0x1d3e')]});_0x3c8d3a&&(_0x3597bd[_0x3b9314('0x1d3e')][_0x2cfb05()[_0x3b9314('0x92c')](_0x3b9314('0x1bfa'))+_0x3b9314('0x1366')]=_0x3c8d3a['id']);if(_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0x83f')]&&_0x3597bd[_0x3b9314('0x1d3e')]['appType']===_0x3b9314('0x2853')){}else switch((_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0x746')]||_0x3597bd[_0x3b9314('0x1d3e')][_0x3b9314('0x83f')])[_0x3b9314('0x2574')]()){case _0x3b9314('0xceb'):_0x3597bd['queue'][_0x3b9314('0x823')]=_0x3597bd['queue'][_0x3b9314('0x4f0')]+'='+_0x3597bd['queue'][_0x3b9314('0x18e0')];break;case _0x3b9314('0x2853'):break;default:_0x25dc78[0x0]=_0x3597bd[_0x3b9314('0x1d3e')]['queue'],_0x25dc78[0x1]=_0x3597bd['queue']['timeout'],_0x3597bd['queue'][_0x3b9314('0x823')]=_0x25dc78[_0x3b9314('0x45a')](',');}_0x37358e(_0x3597bd['queue']);}function _0x37358e(_0x46df61){_0x2c519e['hide'](_0x46df61);}}const _0x25c598=_0x128b45;_0xacc949[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1990'),_0x36e6f4('0x21b9'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0xacc949(_0x44b80a,_0x295ee4,_0x5b0927,_0x10a6ff,_0x27af4f,_0x533f91,_0xd68363,_0x278d2c){const _0x226af6=_0x36e6f4,_0x19918f=this;_0x19918f[_0x226af6('0x98')]=_0xd68363[_0x226af6('0x26cd')](),_0x19918f[_0x226af6('0x61a')]=[],_0x19918f[_0x226af6('0xcdc')]=_0x226af6('0x2132')+(_0x10a6ff[_0x226af6('0x83f')]||_0x10a6ff[_0x226af6('0x746')])[_0x226af6('0x1387')](),_0x19918f[_0x226af6('0x1c2b')]=angular['copy'](_0x10a6ff),_0x19918f[_0x226af6('0x243c')]=_0x278d2c,_0x19918f[_0x226af6('0x128b')]={};if(_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x823')])switch(_0x19918f[_0x226af6('0x1c2b')]['appType']?_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x83f')][_0x226af6('0x2574')]():_0x19918f[_0x226af6('0x1c2b')]['app'][_0x226af6('0x2574')]()){case _0x226af6('0x2853'):break;case _0x226af6('0xded'):{const _0x34907a=_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x823')][_0x226af6('0x25c8')](',');_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x7ca')]=_0x34907a[0x0],_0x19918f[_0x226af6('0x1c2b')]['language']=_0x34907a[0x1],_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x1634')]=_0x34907a[_0x226af6('0x233')](0x2,_0x34907a[_0x226af6('0x264b')])[_0x226af6('0x45a')](',');}break;case'dialogflowv2':{const _0x164e02=_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x823')]['split'](',');_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x1b0a')]=_0x164e02[0x0],_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x27f3')]=_0x164e02[0x1],_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x170e')]=_0x164e02[0x2],_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0xedb')]=_0x164e02[0x3],_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x1634')]=_0x164e02['slice'](0x4,_0x164e02[_0x226af6('0x264b')])['join'](',');}break;case _0x226af6('0x86c'):{const _0x3439b6=_0x19918f['system'][_0x226af6('0x823')]['split'](',');_0x19918f['system'][_0x226af6('0xee6')]=_0x3439b6[0x0],_0x19918f[_0x226af6('0x1c2b')]['secretaccesskey']=_0x3439b6[0x1],_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x25a2')]=_0x3439b6[0x2],_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x1ac4')]=_0x3439b6[0x3],_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x1634')]=_0x3439b6[_0x226af6('0x233')](0x4,_0x3439b6[_0x226af6('0x264b')])['join'](',');}break;case _0x226af6('0x1af7'):{const _0x4145d2=_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x823')][_0x226af6('0x25c8')](',');_0x19918f['system'][_0x226af6('0x265e')]=isNaN(_0x4145d2[0x0])?_0x4145d2[0x0]:parseInt(_0x4145d2[0x0],0xa),_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x1640')]=_0x4145d2['slice'](0x1,_0x4145d2['length'])['join'](',');}break;case _0x226af6('0x1e70'):_0x19918f['system']['text']=_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x823')];break;case _0x226af6('0xceb'):_0x19918f['system'][_0x226af6('0x4f0')]=_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x823')][_0x226af6('0x25c8')]('=')[0x0],_0x19918f[_0x226af6('0x1c2b')]['value']=_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x823')][_0x226af6('0x25c8')]('=')[0x1];break;case _0x226af6('0x1034'):_0x19918f['system'][_0x226af6('0x2588')]=_0x19918f['system'][_0x226af6('0x823')];break;default:{const _0x32647=_0x19918f['system'][_0x226af6('0x823')][_0x226af6('0x25c8')](',');_0x19918f['system'][_0x226af6('0x187')]=_0x2cfb05()[_0x226af6('0x1081')](_0x32647[0x0])?_0x32647[0x0]:isNaN(_0x32647[0x0])?_0x32647[0x0]:parseInt(_0x32647[0x0],0xa),_0x19918f['system'][_0x226af6('0x734')]=_0x2cfb05()[_0x226af6('0x1081')](_0x32647[0x1])?_0x32647[0x1]:isNaN(_0x32647[0x1])?_0x32647[0x1]:parseInt(_0x32647[0x1],0xa);}break;}else _0x19918f[_0x226af6('0x1c2b')]['variable']='';_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x1345')]&&_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x1345')][_0x226af6('0x2574')]()===_0x226af6('0x587')&&_0x19918f[_0x226af6('0x1c2b')]['appType'][_0x226af6('0x2574')]()===_0x226af6('0x2884')&&(_0x19918f[_0x226af6('0x1c2b')]['prefix']=_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x2026')]?_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x2026')]['split']('$')[0x0]:undefined,_0x19918f['system'][_0x226af6('0x1f02')]=_0x19918f['system']['callerID']?_0x226af6('0xa4c')+_0x19918f[_0x226af6('0x1c2b')][_0x226af6('0x992')]:undefined);_0x19918f[_0x226af6('0x2871')]=_0x3bcb47,_0x19918f[_0x226af6('0x24a0')]=_0x510dd2,_0xd68363[_0x226af6('0x1ac6')]('admin')?_0x533f91['variable'][_0x226af6('0xd83')]({'fields':_0x226af6('0x1776'),'sort':_0x226af6('0x4f0'),'nolimit':'true'})['$promise'][_0x226af6('0x1166')](function(_0x53a360){const _0x59546b=_0x226af6;_0x19918f[_0x59546b('0x57a')]=_0x53a360[_0x59546b('0x269a')]||[];})[_0x226af6('0x1a80')](function(_0x2e5a37){const _0x3f6a2c=_0x226af6;_0x5b0927[_0x3f6a2c('0xfc9')]({'title':_0x2e5a37[_0x3f6a2c('0x52d')]?'API:'+_0x2e5a37['status']+_0x3f6a2c('0x11e1')+_0x2e5a37[_0x3f6a2c('0xe1b')]:'SYSTEM:GET_VARIABLES','msg':_0x2e5a37[_0x3f6a2c('0x25f4')]?JSON['stringify'](_0x2e5a37['data']):_0x2e5a37[_0x3f6a2c('0x1586')]()});}):_0x533f91[_0x226af6('0x734')][_0x226af6('0xd83')]({'fields':_0x226af6('0x1776'),'sort':_0x226af6('0x4f0'),'nolimit':_0x226af6('0xf3b')})[_0x226af6('0xa44')][_0x226af6('0x1166')](function(_0x563a8f){const _0x2807ea=_0x226af6;_0x19918f[_0x2807ea('0x57a')]=_0x563a8f[_0x2807ea('0x269a')]||[];})[_0x226af6('0x1166')](function(){const _0x2222ee=_0x226af6;return _0x533f91[_0x2222ee('0x17aa')]['get']({'userProfileId':_0x19918f['currentUser']['userProfileId'],'sectionId':0x3f4})['$promise'];})[_0x226af6('0x1166')](function(_0x222577){const _0x369ac3=_0x226af6,_0x3750f0=_0x222577&&_0x222577[_0x369ac3('0x269a')]?_0x222577[_0x369ac3('0x269a')][0x0]:null;if(!_0x3750f0){const _0x2c57cf=[];let _0x5b5be0=null;_0x19918f['system']&&(_0x5b5be0=_0x2cfb05()[_0x369ac3('0xc38')](_0x19918f[_0x369ac3('0x57a')],{'name':_0x19918f[_0x369ac3('0x1c2b')][_0x369ac3('0x734')]}));for(let _0x283b9f=0x0;_0x283b9f<_0x19918f['variables']['length'];_0x283b9f++){_0x5b5be0&&_0x19918f[_0x369ac3('0x57a')][_0x283b9f]['id']===_0x5b5be0['id']&&(_0x19918f[_0x369ac3('0x57a')][_0x283b9f]['canSelect']=![],_0x2c57cf['push'](_0x19918f[_0x369ac3('0x57a')][_0x283b9f]));}_0x19918f[_0x369ac3('0x57a')]=_0x2c57cf;}else{if(!_0x3750f0[_0x369ac3('0x1a2b')])return _0x533f91['userProfileResource'][_0x369ac3('0xd83')]({'sectionId':_0x3750f0['id']})['$promise'][_0x369ac3('0x1166')](function(_0x571514){const _0x1cec01=_0x369ac3,_0x2f4277=_0x2cfb05()[_0x1cec01('0x2563')](_0x571514[_0x1cec01('0x269a')],function(_0x39693e){const _0x5b3dff=_0x1cec01;return _0x2cfb05()[_0x5b3dff('0xc38')](_0x19918f[_0x5b3dff('0x57a')],{'id':_0x39693e[_0x5b3dff('0x24e8')]});});let _0x235818=null;_0x19918f['system']&&(_0x235818=_0x2cfb05()[_0x1cec01('0xc38')](_0x19918f[_0x1cec01('0x57a')],{'name':_0x19918f['system'][_0x1cec01('0x734')]}));if(_0x235818&&!_0x2cfb05()[_0x1cec01('0x1798')](_0x2f4277,['id',_0x235818['id']])){const _0x40cbde=_0x2cfb05()[_0x1cec01('0xc38')](_0x19918f[_0x1cec01('0x57a')],{'id':_0x235818['id']});_0x40cbde[_0x1cec01('0x2378')]=![],_0x2f4277['push'](_0x40cbde);}_0x19918f[_0x1cec01('0x57a')]=_0x2f4277;});}})[_0x226af6('0x1a80')](function(_0x26ef5a){const _0x55611a=_0x226af6;_0x5b0927['error']({'title':_0x26ef5a[_0x55611a('0x52d')]?_0x55611a('0x1e21')+_0x26ef5a[_0x55611a('0x52d')]+'\x20-\x20'+_0x26ef5a[_0x55611a('0xe1b')]:_0x55611a('0x2644'),'msg':_0x26ef5a['data']?JSON[_0x55611a('0xbac')](_0x26ef5a['data']):_0x26ef5a['toString']()});});function _0x3bcb47(){const _0x31571d=_0x226af6;_0x19918f[_0x31571d('0x61a')]=[];const _0x106de7=[];_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x1345')]&&_0x19918f['system'][_0x31571d('0x1345')][_0x31571d('0x2574')]()==='outbound'&&_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x83f')]===_0x31571d('0x867')&&(_0x19918f[_0x31571d('0x1c2b')]['phone']=_0x27af4f['cutdigits']?(_0x19918f['system'][_0x31571d('0x265a')]||'')+_0x31571d('0x881')+_0x27af4f[_0x31571d('0x2848')]+'}':(_0x19918f['system'][_0x31571d('0x265a')]||'')+_0x31571d('0x1d1'),_0x27af4f[_0x31571d('0x28cb')]!==_0x31571d('0x192')?_0x19918f['system'][_0x31571d('0xd39')]['indexOf'](_0x31571d('0x1059'))<0x0&&(_0x19918f[_0x31571d('0x1c2b')]['options']+=_0x31571d('0x1059')):_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0xd39')]=_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0xd39')]['replace'](_0x31571d('0x1059'),''));if(_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x83f')]&&_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x83f')]==='custom'){}else switch((_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x746')]||_0x19918f['system'][_0x31571d('0x83f')])['toLowerCase']()){case'set':_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x823')]=_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x4f0')]+'='+_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x18e0')];break;case _0x31571d('0x2853'):break;default:_0x106de7[0x0]=_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x187')],_0x106de7[0x1]=_0x19918f[_0x31571d('0x1c2b')][_0x31571d('0x734')],_0x19918f['system'][_0x31571d('0x823')]=_0x106de7[_0x31571d('0x45a')](',');}_0x510dd2(_0x19918f['system']);}function _0x510dd2(_0x5bbc11){const _0x40782a=_0x226af6;_0x44b80a[_0x40782a('0x1197')](_0x5bbc11);}}const _0x38d79f=_0xacc949;_0x58d6b9['$inject']=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x1990'),'mailAccount',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x58d6b9(_0x34cda8,_0xf28aa9,_0x2c950d,_0x27395b,_0x4e8d3b,_0x579b58,_0x40554c,_0x2144ba){const _0x3a636b=_0x36e6f4,_0x4e317c=this;_0x4e317c['currentUser']=_0x40554c[_0x3a636b('0x26cd')](),_0x4e317c['errors']=[],_0x4e317c[_0x3a636b('0xcdc')]='MAIL.EDIT_'+(_0x27395b[_0x3a636b('0x83f')]||_0x27395b['app'])[_0x3a636b('0x1387')](),_0x4e317c[_0x3a636b('0x1446')]=angular[_0x3a636b('0x225f')](_0x27395b),_0x4e317c[_0x3a636b('0x243c')]=_0x2144ba,_0x4e317c[_0x3a636b('0x128b')]={};if(_0x4e317c['tag'][_0x3a636b('0x823')])switch(_0x4e317c['tag']['appType']?_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x83f')]['toLowerCase']():_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x746')][_0x3a636b('0x2574')]()){case _0x3a636b('0x2853'):break;case _0x3a636b('0xded'):{const _0x400d1f=_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x823')]['split'](',');_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x7ca')]=_0x400d1f[0x0],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0xedb')]=_0x400d1f[0x1],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x1634')]=_0x400d1f['slice'](0x2,_0x400d1f[_0x3a636b('0x264b')])['join'](',');}break;case _0x3a636b('0x1636'):{const _0x47d622=_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x823')]['split'](',');_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x1b0a')]=_0x47d622[0x0],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x27f3')]=_0x47d622[0x1],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x170e')]=_0x47d622[0x2],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0xedb')]=_0x47d622[0x3],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x1634')]=_0x47d622[_0x3a636b('0x233')](0x4,_0x47d622[_0x3a636b('0x264b')])[_0x3a636b('0x45a')](',');}break;case'amazonlex':{const _0x5626d5=_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x823')][_0x3a636b('0x25c8')](',');_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0xee6')]=_0x5626d5[0x0],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x125')]=_0x5626d5[0x1],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x25a2')]=_0x5626d5[0x2],_0x4e317c['tag'][_0x3a636b('0x1ac4')]=_0x5626d5[0x3],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x1634')]=_0x5626d5['slice'](0x4,_0x5626d5[_0x3a636b('0x264b')])[_0x3a636b('0x45a')](',');}break;case _0x3a636b('0x1af7'):{const _0x2fae71=_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x823')]['split'](',');_0x4e317c['tag'][_0x3a636b('0x265e')]=isNaN(_0x2fae71[0x0])?_0x2fae71[0x0]:parseInt(_0x2fae71[0x0],0xa),_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x1640')]=_0x2fae71['slice'](0x1,_0x2fae71[_0x3a636b('0x264b')])[_0x3a636b('0x45a')](',');}break;case _0x3a636b('0x1e70'):_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x1640')]=_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x823')];break;case _0x3a636b('0xceb'):_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x4f0')]=_0x4e317c['tag'][_0x3a636b('0x823')][_0x3a636b('0x25c8')]('=')[0x0],_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x18e0')]=_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x823')][_0x3a636b('0x25c8')]('=')[0x1];break;case _0x3a636b('0x1034'):_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x2588')]=_0x4e317c['tag'][_0x3a636b('0x823')];break;default:{const _0x52d26f=_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x823')][_0x3a636b('0x25c8')](',');_0x4e317c[_0x3a636b('0x1446')]['tag']=_0x2cfb05()[_0x3a636b('0x1081')](_0x52d26f[0x0])?_0x52d26f[0x0]:isNaN(_0x52d26f[0x0])?_0x52d26f[0x0]:parseInt(_0x52d26f[0x0],0xa);}break;}else{}_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x1345')]&&_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x1345')][_0x3a636b('0x2574')]()===_0x3a636b('0x587')&&_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x83f')]['toLowerCase']()==='outbounddial'&&(_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x265a')]=_0x4e317c[_0x3a636b('0x1446')]['phone']?_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x2026')][_0x3a636b('0x25c8')]('$')[0x0]:undefined,_0x4e317c[_0x3a636b('0x1446')][_0x3a636b('0x1f02')]=_0x4e317c['tag'][_0x3a636b('0x992')]?_0x3a636b('0xa4c')+_0x4e317c['tag'][_0x3a636b('0x992')]:undefined);_0x4e317c['saveMailAccountApp']=_0x40a33f,_0x4e317c['closeDialog']=_0x4b7aec,_0x40554c[_0x3a636b('0x1ac6')]('admin')?_0x579b58[_0x3a636b('0x1446')][_0x3a636b('0xd83')]({'fields':_0x3a636b('0x1776'),'sort':_0x3a636b('0x4f0'),'nolimit':'true'})[_0x3a636b('0xa44')][_0x3a636b('0x1166')](function(_0x2e909b){const _0x4922ff=_0x3a636b;_0x4e317c[_0x4922ff('0xb38')]=_0x2e909b[_0x4922ff('0x269a')]||[];})['catch'](function(_0x5ba164){const _0x136778=_0x3a636b;_0x2c950d[_0x136778('0xfc9')]({'title':_0x5ba164['status']?'API:'+_0x5ba164[_0x136778('0x52d')]+_0x136778('0x11e1')+_0x5ba164[_0x136778('0xe1b')]:_0x136778('0x402'),'msg':_0x5ba164[_0x136778('0x25f4')]?JSON['stringify'](_0x5ba164[_0x136778('0x25f4')]):_0x5ba164[_0x136778('0x1586')]()});}):_0x579b58['tag'][_0x3a636b('0xd83')]({'fields':'id,name','sort':'name','nolimit':_0x3a636b('0xf3b')})[_0x3a636b('0xa44')][_0x3a636b('0x1166')](function(_0x48383d){const _0x39fcd2=_0x3a636b;_0x4e317c['tags']=_0x48383d[_0x39fcd2('0x269a')]||[];})[_0x3a636b('0x1166')](function(){const _0x5dde88=_0x3a636b;return _0x579b58['userProfileSection'][_0x5dde88('0xd83')]({'userProfileId':_0x4e317c[_0x5dde88('0x98')][_0x5dde88('0xb86')],'sectionId':0x3f0})[_0x5dde88('0xa44')];})[_0x3a636b('0x1166')](function(_0x451b01){const _0x724ea3=_0x3a636b,_0x20ab02=_0x451b01&&_0x451b01[_0x724ea3('0x269a')]?_0x451b01[_0x724ea3('0x269a')][0x0]:null;if(!_0x20ab02){const _0x3e8e3d=[];let _0x267532=null;_0x4e317c[_0x724ea3('0x1446')]&&(_0x267532=_0x2cfb05()[_0x724ea3('0xc38')](_0x4e317c['tags'],{'name':_0x4e317c['tag'][_0x724ea3('0x1446')]}));for(let _0x20832c=0x0;_0x20832c<_0x4e317c[_0x724ea3('0xb38')][_0x724ea3('0x264b')];_0x20832c++){_0x267532&&_0x4e317c[_0x724ea3('0xb38')][_0x20832c]['id']===_0x267532['id']&&(_0x4e317c[_0x724ea3('0xb38')][_0x20832c][_0x724ea3('0x2378')]=![],_0x3e8e3d[_0x724ea3('0x1514')](_0x4e317c[_0x724ea3('0xb38')][_0x20832c]));}_0x4e317c[_0x724ea3('0xb38')]=_0x3e8e3d;}else{if(!_0x20ab02[_0x724ea3('0x1a2b')])return _0x579b58[_0x724ea3('0x4b5')][_0x724ea3('0xd83')]({'sectionId':_0x20ab02['id']})[_0x724ea3('0xa44')][_0x724ea3('0x1166')](function(_0x5a3f44){const _0x5218d4=_0x724ea3,_0x3c4538=_0x2cfb05()[_0x5218d4('0x2563')](_0x5a3f44[_0x5218d4('0x269a')],function(_0x38c790){const _0x1297e6=_0x5218d4;return _0x2cfb05()[_0x1297e6('0xc38')](_0x4e317c[_0x1297e6('0xb38')],{'id':_0x38c790[_0x1297e6('0x24e8')]});});let _0x28268c=null;_0x4e317c[_0x5218d4('0x1446')]&&(_0x28268c=_0x2cfb05()[_0x5218d4('0xc38')](_0x4e317c[_0x5218d4('0xb38')],{'name':_0x4e317c['tag'][_0x5218d4('0x1446')]}));if(_0x28268c&&!_0x2cfb05()['some'](_0x3c4538,['id',_0x28268c['id']])){const _0x41021a=_0x2cfb05()[_0x5218d4('0xc38')](_0x4e317c[_0x5218d4('0xb38')],{'id':_0x28268c['id']});_0x41021a[_0x5218d4('0x2378')]=![],_0x3c4538[_0x5218d4('0x1514')](_0x41021a);}_0x4e317c[_0x5218d4('0xb38')]=_0x3c4538;});}})['catch'](function(_0x2ec7be){const _0x2f4fb1=_0x3a636b;_0x2c950d['error']({'title':_0x2ec7be[_0x2f4fb1('0x52d')]?'API:'+_0x2ec7be['status']+_0x2f4fb1('0x11e1')+_0x2ec7be[_0x2f4fb1('0xe1b')]:_0x2f4fb1('0x9e'),'msg':_0x2ec7be[_0x2f4fb1('0x25f4')]?JSON[_0x2f4fb1('0xbac')](_0x2ec7be[_0x2f4fb1('0x25f4')]):_0x2ec7be[_0x2f4fb1('0x1586')]()});});function _0x40a33f(){const _0x457ce7=_0x3a636b;_0x4e317c[_0x457ce7('0x61a')]=[];const _0x4b555f=[];_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0x1345')]&&_0x4e317c['tag'][_0x457ce7('0x1345')][_0x457ce7('0x2574')]()===_0x457ce7('0x587')&&_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0x83f')]===_0x457ce7('0x867')&&(_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0x2026')]=_0x4e8d3b[_0x457ce7('0x2848')]?(_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0x265a')]||'')+'${EXTEN:'+_0x4e8d3b[_0x457ce7('0x2848')]+'}':(_0x4e317c[_0x457ce7('0x1446')]['prefix']||'')+_0x457ce7('0x1d1'),_0x4e8d3b['recordingFormat']!==_0x457ce7('0x192')?_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0xd39')][_0x457ce7('0x2379')](_0x457ce7('0x1059'))<0x0&&(_0x4e317c[_0x457ce7('0x1446')]['options']+='U(xcally-mixmonitor-context)'):_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0xd39')]=_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0xd39')]['replace'](_0x457ce7('0x1059'),''));const _0x58ac3a=_0x2cfb05()['find'](_0x4e317c[_0x457ce7('0xb38')],{'name':_0x4e317c['tag'][_0x457ce7('0x1446')]});_0x58ac3a&&(_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0x8f5')]=_0x58ac3a['id']);if(_0x4e317c['tag'][_0x457ce7('0x83f')]&&_0x4e317c['tag'][_0x457ce7('0x83f')]===_0x457ce7('0x2853')){}else switch((_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0x746')]||_0x4e317c[_0x457ce7('0x1446')]['appType'])[_0x457ce7('0x2574')]()){case _0x457ce7('0xceb'):_0x4e317c['tag'][_0x457ce7('0x823')]=_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0x4f0')]+'='+_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0x18e0')];break;case _0x457ce7('0x2853'):break;default:_0x4b555f[0x0]=_0x4e317c[_0x457ce7('0x1446')]['tag'],_0x4e317c[_0x457ce7('0x1446')][_0x457ce7('0x823')]=_0x4b555f[_0x457ce7('0x45a')](',');}_0x4b7aec(_0x4e317c[_0x457ce7('0x1446')]);}function _0x4b7aec(_0x187998){const _0x39e194=_0x3a636b;_0x34cda8[_0x39e194('0x1197')](_0x187998);}}const _0x20ea16=_0x58d6b9;_0x48381e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),'$state','$q','$translate',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x21ef')];function _0x48381e(_0x32e992,_0x463137,_0x267437,_0x28ab7a,_0xceb235,_0x568dd8,_0xc0395c,_0x19552f,_0x2f2e6e,_0x46e75e,_0x154073){const _0x321ec4=_0x36e6f4,_0x5b2a2e=this;_0x5b2a2e[_0x321ec4('0x98')]=_0x154073[_0x321ec4('0x26cd')](),_0x5b2a2e[_0x321ec4('0x21b9')]={},_0x5b2a2e[_0x321ec4('0x2159')]={'count':0x0,'rows':[]},_0x5b2a2e[_0x321ec4('0xea4')]=[],_0x5b2a2e[_0x321ec4('0x243c')],_0x5b2a2e[_0x321ec4('0x2218')]={'read':_0x321ec4('0x15d7'),'closed':_0x321ec4('0x15d7'),'sort':_0x321ec4('0x2537'),'includeAll':'true','limit':0xa,'page':0x1},_0x5b2a2e[_0x321ec4('0x24d5')]=_0x24b9cf,_0x5b2a2e[_0x321ec4('0x8a2')]=_0x450661,_0x5b2a2e[_0x321ec4('0x102')]=_0x6fc917,_0x5b2a2e[_0x321ec4('0x103b')]=_0x558152,_0x5b2a2e[_0x321ec4('0x392')]=_0x1bcb8f,_0x5b2a2e['spymailInteraction']=_0x422312,_0x5b2a2e[_0x321ec4('0x138b')]=_0x5208ef,_0x5b2a2e[_0x321ec4('0x1e09')]=_0x3678b9,_0x5b2a2e[_0x321ec4('0xca1')]=_0xf525ee,_0x5b2a2e[_0x321ec4('0x2015')]=_0x37321d;function _0x24b9cf(_0x6f90b3,_0x121b2e){const _0x372017=_0x321ec4;_0x5b2a2e[_0x372017('0x21b9')]=_0x6f90b3,_0x5b2a2e[_0x372017('0x243c')]=typeof _0x121b2e!=='undefined'?_0x121b2e:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x5b2a2e[_0x372017('0x2218')]['MailAccountId']=_0x5b2a2e[_0x372017('0x21b9')]['id'],_0x5b2a2e['advancedSearch']={'fields':_0x2bb4ac()},_0x4e218f();}function _0x4e218f(){const _0x44d9f4=_0x321ec4;return _0x46e75e[_0x44d9f4('0x1446')][_0x44d9f4('0xd83')]()[_0x44d9f4('0xa44')][_0x44d9f4('0x1166')](function(_0x1216cb){const _0x4aea05=_0x44d9f4;_0x5b2a2e[_0x4aea05('0xb38')]=_0x1216cb||{'count':0x0,'rows':[]};})[_0x44d9f4('0x1166')](function(){const _0x5a91f4=_0x44d9f4;return _0x46e75e['mailSubstatus'][_0x5a91f4('0xd83')]({'nolimit':!![]})[_0x5a91f4('0xa44')]['then'](function(_0x309784){const _0x18ee7c=_0x5a91f4;_0x5b2a2e[_0x18ee7c('0x1ed2')]=_0x309784||{'count':0x0,'rows':[]};});})[_0x44d9f4('0x1166')](function(){const _0x3aad3b=_0x44d9f4;_0x5b2a2e[_0x3aad3b('0x6cb')]=_0x1b4bda();});}function _0x1b4bda(){const _0x5cab63=_0x321ec4;return[{'name':'Start\x20Date','key':'createdAt','type':_0x5cab63('0x1643'),'label':_0x5cab63('0x16d9')},{'name':_0x5cab63('0x116c'),'key':'read','type':_0x5cab63('0x88a'),'label':'DASHBOARDS.SELECT_READ_UNREAD','customOptions':[{'value':0x0,'translate':_0x5cab63('0x2c8')},{'value':0x1,'translate':_0x5cab63('0x1057')},{'value':null,'translate':_0x5cab63('0x2150')}]},{'name':_0x5cab63('0x28f6'),'key':_0x5cab63('0xa5b'),'type':_0x5cab63('0x88a'),'label':_0x5cab63('0xe32'),'customOptions':[{'value':0x0,'translate':_0x5cab63('0xdeb')},{'value':0x1,'translate':_0x5cab63('0x58f')},{'value':null,'translate':_0x5cab63('0x2150')}]},{'name':_0x5cab63('0x1b50'),'key':_0x5cab63('0xcfc'),'type':'select','label':_0x5cab63('0x221b'),'options':_0x5b2a2e[_0x5cab63('0x1ed2')]['rows'],'customOptions':[{'value':_0x5cab63('0x15d7'),'translate':'DASHBOARDS.NONE'},{'value':undefined,'translate':_0x5cab63('0x2150')}],'ngValue':'name','ngIf':_0x5cab63('0x168f')},{'name':_0x5cab63('0x89b'),'key':'UserId','type':'select','label':_0x5cab63('0x1db1'),'customOptions':[{'value':_0x5cab63('0x15d7'),'translate':_0x5cab63('0x216b')},{'value':undefined,'translate':_0x5cab63('0x2150')}]},{'name':_0x5cab63('0x1b35'),'key':'tag','type':_0x5cab63('0x2162'),'label':_0x5cab63('0x1669'),'options':_0x5b2a2e[_0x5cab63('0xb38')][_0x5cab63('0x269a')],'placeholder':'DASHBOARDS.TAGS'}];}function _0x2bb4ac(){const _0x3eed55=_0x321ec4;return[{'name':'Id','column':'id','type':_0x3eed55('0xc45')},{'name':_0x3eed55('0x21a4'),'column':_0x3eed55('0x21a4'),'type':'autocomplete','options':{'searchFields':[_0x3eed55('0x18cb'),'lastName',_0x3eed55('0x66f')],'route':{'model':_0x3eed55('0x149e'),'action':_0x3eed55('0xd83'),'params':{'fields':_0x3eed55('0x18eb'),'Contact':'@autocomplete','nolimit':!![]}},'extraOperators':[_0x3eed55('0x2836')],'excludedOperators':['$ne']}},{'name':_0x3eed55('0x36e'),'column':'subject','type':_0x3eed55('0x1640'),'options':{'excludedOperators':[_0x3eed55('0x110'),_0x3eed55('0x2646')]}},{'name':_0x3eed55('0xe1'),'column':'plainBody','type':_0x3eed55('0x1640'),'options':{'excludedOperators':[_0x3eed55('0x110'),_0x3eed55('0x2646')]}},{'name':_0x3eed55('0x28f6'),'column':_0x3eed55('0xa5b'),'type':_0x3eed55('0x88a'),'values':[{'id':0x0,'translate':_0x3eed55('0xdeb')},{'id':0x1,'translate':'DASHBOARDS.CLOSED'}],'options':{'excludedOperators':[_0x3eed55('0x2646')]}},{'name':_0x3eed55('0x1b50'),'column':_0x3eed55('0xcfc'),'type':'multiselect','options':{'field':_0x3eed55('0x4f0'),'route':{'model':_0x3eed55('0x1c44'),'action':'get','params':{'nolimit':!![]}},'excludedOperators':[_0x3eed55('0x18d')]}},{'name':_0x3eed55('0x89b'),'column':'User','type':'autocomplete','options':{'table':'i','route':{'model':_0x3eed55('0x557'),'action':_0x3eed55('0xd83'),'params':{'role':_0x3eed55('0x1eff'),'fields':_0x3eed55('0xce1'),'nolimit':!![]}},'searchFields':[_0x3eed55('0x6e1'),_0x3eed55('0x4f0')],'extraOperators':[_0x3eed55('0x2836')],'excludedOperators':[_0x3eed55('0x2646')]}},{'name':_0x3eed55('0x21c2'),'column':_0x3eed55('0x1b35'),'type':_0x3eed55('0x2162'),'options':{'route':{'model':_0x3eed55('0x1446'),'action':_0x3eed55('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':[_0x3eed55('0x18d')]}},{'name':_0x3eed55('0x2567'),'column':_0x3eed55('0x262'),'type':'date','options':{'excludedOperators':['$ne']}},{'name':_0x3eed55('0xf43'),'column':_0x3eed55('0x723'),'type':_0x3eed55('0x88a'),'values':[{'id':0x1,'translate':_0x3eed55('0x1057')},{'id':0x0,'translate':'DASHBOARDS.UNREAD'}],'options':{'excludedOperators':['$ne']}}];}function _0x5208ef(){const _0x518607=_0x321ec4;_0xc0395c[_0x518607('0x1f80')]({'controller':_0x518607('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0x518607('0x1194')](_0x19552f['body']),'clickOutsideToClose':![],'locals':{'fields':_0x5b2a2e['advancedSearch'][_0x518607('0xfe2')],'color':undefined,'storagePath':_0x518607('0x1ae3')},'fullscreen':!![]})[_0x518607('0x1166')](function(_0x20a88f){const _0x551bfc=_0x518607;_0x5b2a2e[_0x551bfc('0x2218')][_0x551bfc('0xe07')]=_0x20a88f===![]?undefined:_0x20a88f;if(_0x5b2a2e[_0x551bfc('0x2218')][_0x551bfc('0xe07')])_0x5b2a2e['query'][_0x551bfc('0xe07')]+=_0x551bfc('0xdb')+_0x5b2a2e[_0x551bfc('0x21b9')]['id']+']',_0x1bcb8f();else _0x20a88f===![]&&_0x1bcb8f();})[_0x518607('0x1a80')](function(_0x2fd36b){const _0x1d4ab3=_0x518607;_0x2f2e6e['error']({'title':_0x1d4ab3('0x2272'),'msg':_0x2fd36b[_0x1d4ab3('0x25f4')]?JSON['stringify'](_0x2fd36b[_0x1d4ab3('0x25f4')][_0x1d4ab3('0x1e70')]):_0x2fd36b['toString']()});});}function _0x6fc917(_0x2aa0bd,_0xc0f800,_0x24e4f8){const _0x3bf01f=_0x321ec4;return _0x46e75e[_0x3bf01f('0x382')][_0x3bf01f('0x2ad')]({'id':_0x2aa0bd['id'],'exists':!![],'attachments':_0x24e4f8})['$promise'][_0x3bf01f('0x1166')](function(_0x2e437b){const _0x27823f=_0x3bf01f,_0x53a717=[_0x2e437b[_0x27823f('0x20ed')]];let _0x45437f=_0x27823f('0x25e6')+_0x2aa0bd['id'];const _0x566d19=new Blob(_0x53a717,{'type':_0x2e437b[_0x27823f('0x1345')]});_0x45437f=_0x27823f('0xe36')+_0x2aa0bd['id']+'.zip';const _0x2e40b3=window[_0x27823f('0x136d')][_0x27823f('0xdd')]('a');_0x2e40b3[_0x27823f('0xffd')](_0x27823f('0x14f9'),URL[_0x27823f('0x215a')](_0x566d19)),_0x2e40b3[_0x27823f('0xffd')](_0x27823f('0x2ad'),_0x45437f),document[_0x27823f('0x8d2')]['appendChild'](_0x2e40b3),_0x2e40b3[_0x27823f('0x3b4')]();})[_0x3bf01f('0x1a80')](function(_0x271cc8){const _0x520325=_0x3bf01f;if(_0x271cc8[_0x520325('0x25f4')]&&_0x271cc8[_0x520325('0x25f4')][_0x520325('0x61a')]&&_0x271cc8['data'][_0x520325('0x61a')]['length'])for(let _0x480c29=0x0;_0x480c29<_0x271cc8['data'][_0x520325('0x61a')][_0x520325('0x264b')];_0x480c29+=0x1){_0x2f2e6e['error']({'title':_0x271cc8[_0x520325('0x25f4')][_0x520325('0x61a')][_0x480c29][_0x520325('0x1345')],'msg':_0x271cc8[_0x520325('0x25f4')][_0x520325('0x61a')][_0x480c29][_0x520325('0x1e70')]});}else _0x2f2e6e['error']({'title':_0x271cc8[_0x520325('0x52d')]?_0x520325('0x1e21')+_0x271cc8[_0x520325('0x52d')]+_0x520325('0x11e1')+_0x271cc8[_0x520325('0xe1b')]:_0x520325('0x211b'),'msg':_0x271cc8['data']?JSON[_0x520325('0xbac')](_0x271cc8[_0x520325('0x25f4')][_0x520325('0x1e70')]):_0x271cc8[_0x520325('0x1586')]()});});}function _0x450661(_0x295922,_0x2bee83){const _0x511c55=_0x321ec4,_0xd88eb=_0xc0395c[_0x511c55('0x1d26')]()[_0x511c55('0xcdc')](_0x511c55('0xced'))[_0x511c55('0xf3c')](_0x511c55('0x12b5')+(_0x295922[_0x511c55('0x4f0')]||_0x295922['id']&&_0x2cfb05()[_0x511c55('0x114b')](_0x511c55('0x2625'))+_0x295922['id']||_0x511c55('0x25e6'))+_0x511c55('0xace')+_0x511c55('0x3f3'))[_0x511c55('0x8e8')]('delete\x20interaction')[_0x511c55('0x203b')](_0x2bee83)['ok']('OK')[_0x511c55('0x3f')](_0x511c55('0x2d3'));_0xc0395c['show'](_0xd88eb)[_0x511c55('0x1166')](function(){_0xf525ee(_0x295922);},function(){const _0x383eab=_0x511c55;console[_0x383eab('0x455')](_0x383eab('0x2d3'));});}function _0x558152(_0x5ed750){const _0x2d13f9=_0x321ec4;_0x5b2a2e[_0x2d13f9('0x2159')]=_0x5ed750||{'count':0x0,'rows':[]};for(let _0x80a402=0x0;_0x80a402<_0x5b2a2e[_0x2d13f9('0x2159')][_0x2d13f9('0x269a')][_0x2d13f9('0x264b')];_0x80a402+=0x1){const _0xa017f=_0x5b2a2e[_0x2d13f9('0x2159')][_0x2d13f9('0x269a')][_0x80a402];_0x2b6958(_0xa017f),_0xa017f['Owner'][_0x2d13f9('0x4f0')]=_0xfd863a(_0xa017f);}}function _0x1bcb8f(){const _0xd18990=_0x321ec4;_0x5b2a2e[_0xd18990('0x2218')][_0xd18990('0x1098')]=(_0x5b2a2e[_0xd18990('0x2218')][_0xd18990('0x1a43')]-0x1)*_0x5b2a2e[_0xd18990('0x2218')][_0xd18990('0x163f')],_0x5b2a2e['promise']=_0x46e75e['mailInteraction'][_0xd18990('0xd83')](_0x5b2a2e['query'],_0x558152)[_0xd18990('0xa44')];}function _0x422312(_0x3517e1,_0x36ac93){const _0x10d04b=_0x321ec4;_0xc0395c[_0x10d04b('0x1f80')]({'controller':_0x10d04b('0x19ad'),'controllerAs':'vm','templateUrl':_0xbfcb18,'parent':angular['element'](_0x19552f[_0x10d04b('0x8d2')]),'targetEvent':_0x3517e1,'clickOutsideToClose':!![],'onShowing':function(_0x17ee13){const _0x2224be=_0x10d04b;_0x17ee13['vm'][_0x2224be('0x24d5')]({'id':0x1,'channel':'mail','interaction':_0x36ac93,'spy':!![]},_0x463137[_0x2224be('0x23ac')]['vm'][_0x2224be('0xf8a')]);}});}function _0xf525ee(_0x4c8e4c){const _0x1d3907=_0x321ec4;_0x46e75e[_0x1d3907('0x382')][_0x1d3907('0x906')]({'id':_0x4c8e4c['id']})['$promise']['then'](function(){const _0x1efc38=_0x1d3907;_0x2cfb05()[_0x1efc38('0x127f')](_0x5b2a2e[_0x1efc38('0x2159')]['rows'],{'id':_0x4c8e4c['id']}),_0x5b2a2e[_0x1efc38('0x2159')]['count']-=0x1,!_0x5b2a2e[_0x1efc38('0x2159')][_0x1efc38('0x269a')][_0x1efc38('0x264b')]&&_0x1bcb8f(),_0x2f2e6e['success']({'title':_0x1efc38('0x2003'),'msg':_0x4c8e4c['name']?_0x4c8e4c[_0x1efc38('0x4f0')]+_0x1efc38('0x7cd'):''});})[_0x1d3907('0x1a80')](function(_0x5225ff){const _0x58e44e=_0x1d3907;if(_0x5225ff['data']&&_0x5225ff[_0x58e44e('0x25f4')]['errors']&&_0x5225ff[_0x58e44e('0x25f4')][_0x58e44e('0x61a')][_0x58e44e('0x264b')]){_0x5b2a2e[_0x58e44e('0x61a')]=_0x5225ff[_0x58e44e('0x25f4')][_0x58e44e('0x61a')]||[{'message':_0x5225ff['toString'](),'type':_0x58e44e('0xabc')}];for(let _0x3eca73=0x0;_0x3eca73<_0x5225ff[_0x58e44e('0x25f4')][_0x58e44e('0x61a')][_0x58e44e('0x264b')];_0x3eca73++){_0x2f2e6e[_0x58e44e('0xfc9')]({'title':_0x5225ff['data'][_0x58e44e('0x61a')][_0x3eca73]['type'],'msg':_0x5225ff[_0x58e44e('0x25f4')][_0x58e44e('0x61a')][_0x3eca73][_0x58e44e('0x1e70')]});}}else _0x2f2e6e[_0x58e44e('0xfc9')]({'title':_0x5225ff[_0x58e44e('0x52d')]?_0x58e44e('0x1e21')+_0x5225ff['status']+'\x20-\x20'+_0x5225ff[_0x58e44e('0xe1b')]:'SYSTEM:GETmailAccount','msg':_0x5225ff[_0x58e44e('0x25f4')]?JSON['stringify'](_0x5225ff['data'][_0x58e44e('0x1e70')]):_0x5225ff[_0x58e44e('0x1e70')]||_0x5225ff[_0x58e44e('0x1586')]()});});}function _0x3678b9(){const _0x1683aa=_0x321ec4,_0x2a0cfd=angular[_0x1683aa('0x225f')](_0x5b2a2e['selectedMailAccountInteractions']);return _0x5b2a2e[_0x1683aa('0xea4')]=[],_0x2a0cfd;}function _0x37321d(_0x21d797){const _0x5c9fdc=_0x321ec4,_0x3b8e4d=_0xc0395c[_0x5c9fdc('0x1d26')]()[_0x5c9fdc('0xcdc')](_0x5c9fdc('0x5dd'))[_0x5c9fdc('0xf3c')](_0x5c9fdc('0x12b5')+_0x5b2a2e[_0x5c9fdc('0xea4')]['length']+'\x20selected'+_0x5c9fdc('0x3f3'))[_0x5c9fdc('0x8e8')](_0x5c9fdc('0x1623'))[_0x5c9fdc('0x203b')](_0x21d797)['ok']('OK')[_0x5c9fdc('0x3f')](_0x5c9fdc('0x2d3'));_0xc0395c['show'](_0x3b8e4d)['then'](function(){const _0x362e26=_0x5c9fdc;_0x5b2a2e[_0x362e26('0xea4')][_0x362e26('0x2782')](function(_0x578f98){_0xf525ee(_0x578f98);}),_0x5b2a2e[_0x362e26('0xea4')]=[];});}function _0x2b6958(_0x1ed2b4){const _0x37896a=_0x321ec4;if(!_0x2cfb05()['isEmpty'](_0x1ed2b4['to'])&&!_0x2cfb05()[_0x37896a('0x1257')](_0x1ed2b4['to'],_0x5b2a2e['mailAccount'][_0x37896a('0x66f')]))_0x1ed2b4[_0x37896a('0x15cf')]=_0x1ed2b4['to'][_0x37896a('0x25c8')]('\x20<')[0x0],_0x1ed2b4[_0x37896a('0x1ce2')]=_0x1ed2b4['to'][_0x37896a('0x25c8')]('<')['pop']()['split']('>')[0x0];else _0x1ed2b4['Contact']?(_0x1ed2b4['contactName']=(_0x1ed2b4['Contact']['firstName']||'')+'\x20'+(_0x1ed2b4[_0x37896a('0x21a4')][_0x37896a('0xeb0')]||''),_0x1ed2b4[_0x37896a('0x1ce2')]=_0x1ed2b4['Contact']['email']||''):_0x1ed2b4[_0x37896a('0x15cf')]=_0xceb235[_0x37896a('0x25cc')](_0x37896a('0x1a0b'));}function _0xfd863a(_0x451018){const _0x38076a=_0x321ec4;if(_0x451018[_0x38076a('0x122a')])return _0x451018[_0x38076a('0x122a')]===_0x5b2a2e['currentUser']['id']?_0xceb235[_0x38076a('0x25cc')](_0x38076a('0x15ae')):_0x451018[_0x38076a('0x121b')][_0x38076a('0x6e1')]+'\x20<'+_0x451018[_0x38076a('0x121b')]['internal']+'>';return _0xceb235[_0x38076a('0x25cc')]('DASHBOARDS.NOT_ASSIGNED');}let _0x419924=!![],_0x4cd333=0x1;_0x463137[_0x321ec4('0xe83')]('vm_dc.query.filter',function(_0x552292,_0x46623c){const _0x1b5874=_0x321ec4;_0x419924?_0x568dd8(function(){_0x419924=![];}):(!_0x46623c&&(_0x4cd333=_0x5b2a2e['query'][_0x1b5874('0x1a43')]),_0x552292!==_0x46623c&&(_0x5b2a2e[_0x1b5874('0x2218')]['page']=0x1),!_0x552292&&(_0x5b2a2e['query']['page']=_0x4cd333),_0x1bcb8f());});}const _0x2d614d=_0x48381e,_0x39498c=_0x2734b2['p']+_0x36e6f4('0x12d9');_0xb9662a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),'$state','$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),'api','Auth'];function _0xb9662a(_0x2a8897,_0x36bb77,_0x413151,_0x147738,_0x58809d,_0x3d9cd6,_0x37723a,_0x1048ab,_0x3c8f9c,_0x46a508,_0x20c6fb){const _0x2c53a8=_0x36e6f4,_0x31bb94=this;_0x31bb94['currentUser']=_0x20c6fb['getCurrentUser'](),_0x31bb94['mailAccount']={},_0x31bb94[_0x2c53a8('0x14ce')]={'count':0x0,'rows':[]},_0x31bb94[_0x2c53a8('0x1eb4')]=[],_0x31bb94['crudPermissions'],_0x31bb94['query']={'fields':_0x2c53a8('0x1b4'),'limit':0xa,'page':0x1},_0x31bb94[_0x2c53a8('0x24d5')]=_0x39ab6f,_0x31bb94[_0x2c53a8('0x8a2')]=_0x278916,_0x31bb94[_0x2c53a8('0x103b')]=_0x54285c,_0x31bb94[_0x2c53a8('0x9f9')]=_0x2c1733,_0x31bb94['createOrEditMailAccountMailCannedAnswer']=_0xd4efcf,_0x31bb94[_0x2c53a8('0xf41')]=_0x40717b,_0x31bb94['deleteMailAccountMailCannedAnswer']=_0x58852a,_0x31bb94[_0x2c53a8('0x144f')]=_0xbd434f;function _0x39ab6f(_0x5cc4aa,_0x497037){const _0x9c67e7=_0x2c53a8;_0x31bb94['mailAccount']=_0x5cc4aa,_0x31bb94[_0x9c67e7('0x243c')]=typeof _0x497037!==_0x9c67e7('0x1048')?_0x497037:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x31bb94[_0x9c67e7('0x2218')][_0x9c67e7('0x56')]=_0x31bb94[_0x9c67e7('0x21b9')]['id'],_0x31bb94[_0x9c67e7('0x2218')]['id']=_0x31bb94[_0x9c67e7('0x21b9')]['id'],_0x2c1733();}function _0x278916(_0x157b10,_0x58707f){const _0xf34d77=_0x2c53a8,_0xe8aa63=_0x37723a[_0xf34d77('0x1d26')]()[_0xf34d77('0xcdc')](_0xf34d77('0x195c'))[_0xf34d77('0xf3c')](''+(_0x157b10[_0xf34d77('0x4f0')]||_0x157b10['id']&&_0x2cfb05()['upperFirst']('mailCannedAnswer\x20#')+_0x157b10['id']||_0xf34d77('0x672'))+_0xf34d77('0xace')+_0xf34d77('0x3f3'))['ariaLabel'](_0xf34d77('0xb11'))[_0xf34d77('0x203b')](_0x58707f)['ok']('OK')[_0xf34d77('0x3f')](_0xf34d77('0x2d3'));_0x37723a[_0xf34d77('0x1f80')](_0xe8aa63)[_0xf34d77('0x1166')](function(){_0x58852a(_0x157b10);},function(){const _0x2f9801=_0xf34d77;console[_0x2f9801('0x455')](_0x2f9801('0x2d3'));});}function _0x54285c(_0x42aace){_0x31bb94['mailAccountMailCannedAnswers']=_0x42aace||{'count':0x0,'rows':[]};}function _0x2c1733(){const _0x4ae4e8=_0x2c53a8;_0x31bb94[_0x4ae4e8('0x2218')][_0x4ae4e8('0x1098')]=(_0x31bb94['query'][_0x4ae4e8('0x1a43')]-0x1)*_0x31bb94['query'][_0x4ae4e8('0x163f')],_0x31bb94[_0x4ae4e8('0x1f48')]=_0x46a508[_0x4ae4e8('0x21b9')][_0x4ae4e8('0xab8')](_0x31bb94[_0x4ae4e8('0x2218')],_0x54285c)[_0x4ae4e8('0xa44')];}function _0xd4efcf(_0x4abfb9,_0x5ec6f3){const _0x8caaa5=_0x2c53a8;_0x37723a[_0x8caaa5('0x1f80')]({'controller':_0x8caaa5('0x12ad'),'controllerAs':'vm','templateUrl':_0x39498c,'parent':angular[_0x8caaa5('0x1194')](_0x1048ab[_0x8caaa5('0x8d2')]),'targetEvent':_0x4abfb9,'clickOutsideToClose':!![],'locals':{'mailAccount':_0x31bb94[_0x8caaa5('0x21b9')],'mailCannedAnswer':_0x5ec6f3,'mailCannedAnswers':_0x31bb94[_0x8caaa5('0x14ce')][_0x8caaa5('0x269a')],'license':null,'setting':null,'crudPermissions':_0x31bb94[_0x8caaa5('0x243c')]}});}function _0x58852a(_0x3c02c4){const _0x8fd5b0=_0x2c53a8;_0x46a508[_0x8fd5b0('0x1b1f')][_0x8fd5b0('0x906')]({'id':_0x3c02c4['id']})[_0x8fd5b0('0xa44')][_0x8fd5b0('0x1166')](function(){const _0x200a2b=_0x8fd5b0;_0x2cfb05()[_0x200a2b('0x127f')](_0x31bb94[_0x200a2b('0x14ce')][_0x200a2b('0x269a')],{'id':_0x3c02c4['id']}),_0x31bb94[_0x200a2b('0x14ce')][_0x200a2b('0x240f')]-=0x1,!_0x31bb94[_0x200a2b('0x14ce')]['rows']['length']&&_0x2c1733(),_0x3c8f9c[_0x200a2b('0x103b')]({'title':_0x200a2b('0x2892'),'msg':_0x3c02c4['name']?_0x3c02c4[_0x200a2b('0x4f0')]+_0x200a2b('0x7cd'):''});})[_0x8fd5b0('0x1a80')](function(_0x58db2a){const _0x32b9c2=_0x8fd5b0;if(_0x58db2a[_0x32b9c2('0x25f4')]&&_0x58db2a['data'][_0x32b9c2('0x61a')]&&_0x58db2a[_0x32b9c2('0x25f4')][_0x32b9c2('0x61a')][_0x32b9c2('0x264b')]){_0x31bb94[_0x32b9c2('0x61a')]=_0x58db2a['data'][_0x32b9c2('0x61a')]||[{'message':_0x58db2a[_0x32b9c2('0x1586')](),'type':_0x32b9c2('0xabc')}];for(let _0x558417=0x0;_0x558417<_0x58db2a[_0x32b9c2('0x25f4')]['errors'][_0x32b9c2('0x264b')];_0x558417++){_0x3c8f9c[_0x32b9c2('0xfc9')]({'title':_0x58db2a[_0x32b9c2('0x25f4')][_0x32b9c2('0x61a')][_0x558417][_0x32b9c2('0x1345')],'msg':_0x58db2a[_0x32b9c2('0x25f4')][_0x32b9c2('0x61a')][_0x558417][_0x32b9c2('0x1e70')]});}}else _0x3c8f9c[_0x32b9c2('0xfc9')]({'title':_0x58db2a[_0x32b9c2('0x52d')]?'API:'+_0x58db2a[_0x32b9c2('0x52d')]+_0x32b9c2('0x11e1')+_0x58db2a['statusText']:_0x32b9c2('0xabc'),'msg':_0x58db2a['data']?JSON[_0x32b9c2('0xbac')](_0x58db2a[_0x32b9c2('0x25f4')][_0x32b9c2('0x1e70')]):_0x58db2a[_0x32b9c2('0x1e70')]||_0x58db2a[_0x32b9c2('0x1586')]()});});}function _0x40717b(){const _0x46bb66=_0x2c53a8,_0x429a42=angular[_0x46bb66('0x225f')](_0x31bb94['selectedMailAccountMailCannedAnswers']);return _0x31bb94['selectedMailAccountMailCannedAnswers']=[],_0x429a42;}function _0xbd434f(_0x4d5b2a){const _0xae723a=_0x2c53a8,_0x4ed476=_0x37723a['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20mailCannedAnswers?')[_0xae723a('0xf3c')](_0xae723a('0x12b5')+_0x31bb94['selectedMailAccountMailCannedAnswers'][_0xae723a('0x264b')]+'\x20selected'+_0xae723a('0x3f3'))[_0xae723a('0x8e8')]('delete\x20mailCannedAnswers')['targetEvent'](_0x4d5b2a)['ok']('OK')[_0xae723a('0x3f')](_0xae723a('0x2d3'));_0x37723a[_0xae723a('0x1f80')](_0x4ed476)['then'](function(){const _0x2e0e10=_0xae723a;_0x31bb94[_0x2e0e10('0x1eb4')][_0x2e0e10('0x2782')](function(_0x5b5820){_0x58852a(_0x5b5820);}),_0x31bb94[_0x2e0e10('0x1eb4')]=[];});}let _0x47ddcf=!![],_0x14be24=0x1;_0x36bb77[_0x2c53a8('0xe83')](_0x2c53a8('0x28b4'),function(_0x22a072,_0x56506c){const _0xd767bb=_0x2c53a8;_0x47ddcf?_0x3d9cd6(function(){_0x47ddcf=![];}):(!_0x56506c&&(_0x14be24=_0x31bb94[_0xd767bb('0x2218')][_0xd767bb('0x1a43')]),_0x22a072!==_0x56506c&&(_0x31bb94[_0xd767bb('0x2218')][_0xd767bb('0x1a43')]=0x1),!_0x22a072&&(_0x31bb94['query'][_0xd767bb('0x1a43')]=_0x14be24),_0x2c1733());});}const _0x1a41f2=_0xb9662a;_0x98be6e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'mailCannedAnswers',_0x36e6f4('0x672'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x98be6e(_0x47635c,_0x33d9c6,_0x4791ed,_0x571cf7,_0x255656,_0x19adfc,_0x388c87,_0x190687,_0x5a1d9d,_0x5b3278,_0x3dd423,_0x11982e,_0x4e1e24,_0x321e74){const _0x5060f4=_0x36e6f4,_0x2c6aeb=this;_0x2c6aeb[_0x5060f4('0x98')]=_0x3dd423[_0x5060f4('0x26cd')](),_0x2c6aeb[_0x5060f4('0x61a')]=[],_0x2c6aeb['setting']=_0x4e1e24,_0x2c6aeb[_0x5060f4('0x5c9')]=_0x11982e,_0x2c6aeb[_0x5060f4('0x243c')]=_0x321e74,_0x2c6aeb[_0x5060f4('0x128b')]={},_0x2c6aeb[_0x5060f4('0x2900')]=_0x2c6aeb[_0x5060f4('0xf8a')]&&_0x2c6aeb['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2c6aeb['title']=_0x5060f4('0x15bb'),_0x2c6aeb['mailCannedAnswer']=angular[_0x5060f4('0x225f')](_0x5a1d9d),_0x2c6aeb['mailCannedAnswers']=_0x190687,_0x2c6aeb[_0x5060f4('0x863')]=![];!_0x2c6aeb[_0x5060f4('0x672')]&&(_0x2c6aeb[_0x5060f4('0x672')]={},_0x2c6aeb['title']=_0x5060f4('0x244'),_0x2c6aeb[_0x5060f4('0x863')]=!![]);_0x33d9c6[_0x5060f4('0x23f')]['id']&&(_0x2c6aeb[_0x5060f4('0x672')][_0x5060f4('0x56')]=_0x33d9c6[_0x5060f4('0x23f')]['id']);_0x2c6aeb['addNewMailCannedAnswer']=_0xd3b694,_0x2c6aeb['saveMailCannedAnswer']=_0xcd763,_0x2c6aeb[_0x5060f4('0x1dd6')]=_0x5d14e7,_0x2c6aeb[_0x5060f4('0x1a9c')]=_0x350392,_0x2c6aeb[_0x5060f4('0x24a0')]=_0xa8c06;function _0xd3b694(){const _0x58f930=_0x5060f4;_0x2c6aeb[_0x58f930('0x61a')]=[],_0x5b3278[_0x58f930('0x1b1f')][_0x58f930('0x9cc')](_0x2c6aeb['mailCannedAnswer'])[_0x58f930('0xa44')][_0x58f930('0x1166')](function(_0x57df33){const _0x139342=_0x58f930;_0x2c6aeb['mailCannedAnswers'][_0x139342('0x2450')](_0x57df33['toJSON']()),_0x388c87[_0x139342('0x103b')]({'title':_0x139342('0x1542'),'msg':_0x2c6aeb['mailCannedAnswer'][_0x139342('0x4f0')]?_0x2c6aeb[_0x139342('0x672')]['name']+_0x139342('0x1eda'):''}),_0xa8c06(_0x57df33);})[_0x58f930('0x1a80')](function(_0x394131){const _0x56ec63=_0x58f930;if(_0x394131[_0x56ec63('0x25f4')]&&_0x394131[_0x56ec63('0x25f4')][_0x56ec63('0x61a')]&&_0x394131[_0x56ec63('0x25f4')][_0x56ec63('0x61a')]['length']){_0x2c6aeb[_0x56ec63('0x61a')]=_0x394131[_0x56ec63('0x25f4')][_0x56ec63('0x61a')]||[{'message':_0x394131['toString'](),'type':'api.cannedAnswer.save'}];for(let _0x5851e0=0x0;_0x5851e0<_0x394131['data'][_0x56ec63('0x61a')]['length'];_0x5851e0+=0x1){_0x388c87[_0x56ec63('0xfc9')]({'title':_0x394131['data'][_0x56ec63('0x61a')][_0x5851e0][_0x56ec63('0x1345')],'msg':_0x394131[_0x56ec63('0x25f4')]['errors'][_0x5851e0]['message']});}}else _0x388c87[_0x56ec63('0xfc9')]({'title':_0x394131[_0x56ec63('0x52d')]?_0x56ec63('0x1e21')+_0x394131[_0x56ec63('0x52d')]+_0x56ec63('0x11e1')+_0x394131[_0x56ec63('0xe1b')]:'api.cannedAnswer.save','msg':_0x394131[_0x56ec63('0x25f4')]?JSON['stringify'](_0x394131[_0x56ec63('0x25f4')][_0x56ec63('0x1e70')]):_0x394131[_0x56ec63('0x1586')]()});});}function _0xcd763(){const _0x1c0097=_0x5060f4;_0x2c6aeb[_0x1c0097('0x61a')]=[],_0x5b3278[_0x1c0097('0x1b1f')][_0x1c0097('0x1449')]({'id':_0x2c6aeb[_0x1c0097('0x672')]['id']},_0x2c6aeb[_0x1c0097('0x672')])[_0x1c0097('0xa44')]['then'](function(_0x435021){const _0x3b231d=_0x1c0097,_0x452eb1=_0x2cfb05()[_0x3b231d('0xc38')](_0x2c6aeb['mailCannedAnswers'],{'id':_0x435021['id']});_0x452eb1&&_0x2cfb05()[_0x3b231d('0xcc3')](_0x452eb1,_0x2cfb05()[_0x3b231d('0x1a08')](_0x435021[_0x3b231d('0x2876')](),_0x2cfb05()[_0x3b231d('0x14a4')](_0x452eb1))),_0x388c87['success']({'title':_0x3b231d('0x2205'),'msg':_0x2c6aeb[_0x3b231d('0x672')][_0x3b231d('0x4f0')]?_0x2c6aeb['mailCannedAnswer'][_0x3b231d('0x4f0')]+_0x3b231d('0x7d'):''}),_0xa8c06(_0x435021);})[_0x1c0097('0x1a80')](function(_0x47a40d){const _0x39548f=_0x1c0097;if(_0x47a40d[_0x39548f('0x25f4')]&&_0x47a40d['data'][_0x39548f('0x61a')]&&_0x47a40d['data'][_0x39548f('0x61a')][_0x39548f('0x264b')]){_0x2c6aeb[_0x39548f('0x61a')]=_0x47a40d[_0x39548f('0x25f4')][_0x39548f('0x61a')]||[{'message':_0x47a40d[_0x39548f('0x1586')](),'type':_0x39548f('0x122e')}];for(let _0x3c303a=0x0;_0x3c303a<_0x47a40d['data'][_0x39548f('0x61a')]['length'];_0x3c303a++){_0x388c87['error']({'title':_0x47a40d[_0x39548f('0x25f4')][_0x39548f('0x61a')][_0x3c303a][_0x39548f('0x1345')],'msg':_0x47a40d[_0x39548f('0x25f4')][_0x39548f('0x61a')][_0x3c303a]['message']});}}else _0x388c87[_0x39548f('0xfc9')]({'title':_0x47a40d[_0x39548f('0x52d')]?'API:'+_0x47a40d[_0x39548f('0x52d')]+_0x39548f('0x11e1')+_0x47a40d[_0x39548f('0xe1b')]:'api.cannedAnswer.update','msg':_0x47a40d[_0x39548f('0x25f4')]?JSON['stringify'](_0x47a40d[_0x39548f('0x25f4')][_0x39548f('0x1e70')]):_0x47a40d[_0x39548f('0x1586')]()});});}function _0x5d14e7(_0x9eb3b1){const _0x13697a=_0x5060f4;_0x2c6aeb[_0x13697a('0x61a')]=[];const _0x406530=_0x571cf7[_0x13697a('0x1d26')]()['title']('Are\x20you\x20sure?')[_0x13697a('0xacc')]('The\x20mailCannedAnswer\x20will\x20be\x20deleted.')[_0x13697a('0x8e8')]('Delete\x20MailCannedAnswer')['ok'](_0x13697a('0x18'))[_0x13697a('0x3f')]('Cancel')[_0x13697a('0x203b')](_0x9eb3b1);_0x571cf7[_0x13697a('0x1f80')](_0x406530)[_0x13697a('0x1166')](function(){const _0x368a5d=_0x13697a;_0x5b3278[_0x368a5d('0x1b1f')]['delete']({'id':_0x2c6aeb[_0x368a5d('0x672')]['id']})[_0x368a5d('0xa44')][_0x368a5d('0x1166')](function(){const _0x41b441=_0x368a5d;_0x2cfb05()[_0x41b441('0x127f')](_0x2c6aeb[_0x41b441('0xc0f')],{'id':_0x2c6aeb[_0x41b441('0x672')]['id']}),_0x388c87[_0x41b441('0x103b')]({'title':_0x41b441('0x9ab'),'msg':(_0x2c6aeb['mailCannedAnswer'][_0x41b441('0x4f0')]||_0x41b441('0x672'))+'\x20has\x20been\x20deleted!'}),_0xa8c06(_0x2c6aeb[_0x41b441('0x672')]);})[_0x368a5d('0x1a80')](function(_0x4a1c50){const _0x563573=_0x368a5d;if(_0x4a1c50[_0x563573('0x25f4')]&&_0x4a1c50['data'][_0x563573('0x61a')]&&_0x4a1c50[_0x563573('0x25f4')][_0x563573('0x61a')]['length']){_0x2c6aeb[_0x563573('0x61a')]=_0x4a1c50[_0x563573('0x25f4')][_0x563573('0x61a')]||[{'message':_0x4a1c50[_0x563573('0x1586')](),'type':_0x563573('0x1da9')}];for(let _0x40956d=0x0;_0x40956d<_0x4a1c50[_0x563573('0x25f4')][_0x563573('0x61a')][_0x563573('0x264b')];_0x40956d++){_0x388c87[_0x563573('0xfc9')]({'title':_0x4a1c50[_0x563573('0x25f4')]['errors'][_0x40956d][_0x563573('0x1345')],'msg':_0x4a1c50[_0x563573('0x25f4')][_0x563573('0x61a')][_0x40956d][_0x563573('0x1e70')]});}}else _0x388c87['error']({'title':_0x4a1c50['status']?'API:'+_0x4a1c50[_0x563573('0x52d')]+_0x563573('0x11e1')+_0x4a1c50[_0x563573('0xe1b')]:_0x563573('0x1da9'),'msg':_0x4a1c50['data']?JSON[_0x563573('0xbac')](_0x4a1c50['data'][_0x563573('0x1e70')]):_0x4a1c50[_0x563573('0x1e70')]||_0x4a1c50[_0x563573('0x1586')]()});});},function(){});}function _0x350392(_0x24a070){return _0x24a070===null?undefined:new Date(_0x24a070);}function _0xa8c06(_0x10d153){const _0x50b2c6=_0x5060f4;_0x571cf7[_0x50b2c6('0x1197')](_0x10d153);}}const _0x126cee=_0x98be6e;_0x1c835c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x1c835c(_0x5a0f24,_0x3fb8cd,_0x5e9b1f,_0x1e8a23,_0x3bc3c6,_0x5f423a,_0x2e3da3,_0x5d0c36,_0x2c11cb,_0x2aeaaa,_0x2fae41){const _0x506e88=_0x36e6f4,_0x277e83=this;_0x277e83[_0x506e88('0x98')]=_0x2fae41['getCurrentUser'](),_0x277e83[_0x506e88('0x4ea')]={'count':0x0,'rows':[]},_0x277e83[_0x506e88('0x1082')]=[],_0x277e83['crudPermissions'],_0x277e83[_0x506e88('0x178f')]={'first':_0x506e88('0xc31'),'second':_0x506e88('0x580'),'third':'3rd'},_0x277e83[_0x506e88('0x2218')]={'fields':_0x506e88('0xf1a'),'sort':_0x506e88('0x14dc'),'limit':0xa,'page':0x1},_0x277e83[_0x506e88('0x24d5')]=_0x42e4b1,_0x277e83['deleteConfirm']=_0x5301ed,_0x277e83[_0x506e88('0x103b')]=_0x4ad0c2,_0x277e83[_0x506e88('0x3e')]=_0x3fddf9,_0x277e83[_0x506e88('0x782')]=_0x5ac4e1,_0x277e83['deleteDisposition']=_0x16cbdd,_0x277e83[_0x506e88('0x4e2')]=_0x22e5b5,_0x277e83[_0x506e88('0x14b5')]=_0x32bfdd,_0x277e83[_0x506e88('0x205e')]=_0x1efb5f,_0x277e83[_0x506e88('0xd7c')]=_0x1d8e25;function _0x42e4b1(_0xd7823,_0x54fff2){const _0x5ee504=_0x506e88;_0x277e83[_0x5ee504('0x21b9')]=_0xd7823||{},_0x277e83[_0x5ee504('0x243c')]=typeof _0x54fff2!==_0x5ee504('0x1048')?_0x54fff2:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x277e83['query'][_0x5ee504('0x56')]=_0x277e83[_0x5ee504('0x21b9')]['id'],_0x277e83[_0x5ee504('0x2218')]['id']=_0x277e83[_0x5ee504('0x21b9')]['id'],_0x3fddf9();}function _0x5ac4e1(_0x367b59,_0x2dcd70){const _0x312009=_0x506e88;_0x3bc3c6[_0x312009('0x1f80')]({'controller':'CreateOrEditDispositionDialogController','controllerAs':'vm','templateUrl':_0x14e8d3,'parent':angular[_0x312009('0x1194')](_0x5f423a['body']),'targetEvent':_0x367b59,'clickOutsideToClose':!![],'locals':{'disposition':_0x2dcd70,'dispositions':_0x277e83['dispositions'][_0x312009('0x269a')],'model':{'id':_0x277e83[_0x312009('0x21b9')]['id'],'field':_0x312009('0x56')},'license':null,'setting':null,'crudPermissions':_0x277e83['crudPermissions']}})['then'](function(_0x32ba5c){if(_0x32ba5c)_0x3fddf9();});}function _0x5301ed(_0x2fdeaa,_0x35f2bc){const _0x380845=_0x506e88,_0x475d1a=_0x2cfb05()['some'](_0x277e83[_0x380845('0x4ea')][_0x380845('0x269a')],[_0x380845('0x11fa'),_0x2fdeaa['id']]),_0x12d305=_0x3bc3c6[_0x380845('0x1d26')]()[_0x380845('0xcdc')](_0x5d0c36['instant'](_0x380845('0x1ac5')))[_0x380845('0xacc')](_0x5d0c36[_0x380845('0x25cc')](_0x380845('0x92f')+(_0x475d1a?_0x380845('0xc7a'):_0x380845('0x251e')),{'name':_0x2fdeaa[_0x380845('0x4f0')]}))[_0x380845('0x8e8')](_0x380845('0x1af2'))[_0x380845('0x203b')](_0x35f2bc)['ok']('OK')[_0x380845('0x3f')](_0x5d0c36[_0x380845('0x25cc')](_0x380845('0x12a3')));_0x3bc3c6[_0x380845('0x1f80')](_0x12d305)[_0x380845('0x1166')](function(){_0x16cbdd(_0x2fdeaa);});}function _0x4ad0c2(_0x5527fe){const _0x3d5abb=_0x506e88;_0x277e83[_0x3d5abb('0x4ea')]=_0x5527fe||{'count':0x0,'rows':[]};}function _0x3fddf9(){const _0x1247f8=_0x506e88;_0x277e83[_0x1247f8('0x2218')][_0x1247f8('0x1098')]=(_0x277e83[_0x1247f8('0x2218')][_0x1247f8('0x1a43')]-0x1)*_0x277e83['query']['limit'],_0x277e83['promise']=_0x2c11cb[_0x1247f8('0x21b9')][_0x1247f8('0x3e')](_0x277e83[_0x1247f8('0x2218')],_0x4ad0c2)[_0x1247f8('0xa44')];}function _0x16cbdd(_0x1d4ea3){const _0x138462=_0x506e88;_0x2c11cb[_0x138462('0x12e8')][_0x138462('0x906')]({'id':_0x1d4ea3['id']})[_0x138462('0xa44')][_0x138462('0x1166')](function(){const _0x3c46bd=_0x138462;_0x3fddf9(),_0x2aeaaa[_0x3c46bd('0x103b')]({'title':_0x5d0c36['instant'](_0x3c46bd('0x1ca6'))});})[_0x138462('0x1a80')](function(_0x2789a4){const _0x3c701c=_0x138462;if(_0x2789a4[_0x3c701c('0x25f4')]&&_0x2789a4[_0x3c701c('0x25f4')][_0x3c701c('0x61a')]&&_0x2789a4[_0x3c701c('0x25f4')][_0x3c701c('0x61a')][_0x3c701c('0x264b')]){_0x277e83[_0x3c701c('0x61a')]=_0x2789a4[_0x3c701c('0x25f4')][_0x3c701c('0x61a')]||[{'message':_0x2789a4[_0x3c701c('0x1586')](),'type':_0x3c701c('0x1b2c')}];for(let _0x594d6b=0x0;_0x594d6b<_0x2789a4[_0x3c701c('0x25f4')]['errors'][_0x3c701c('0x264b')];_0x594d6b++){_0x2aeaaa[_0x3c701c('0xfc9')]({'title':_0x2789a4[_0x3c701c('0x25f4')][_0x3c701c('0x61a')][_0x594d6b][_0x3c701c('0x1345')],'msg':_0x2789a4[_0x3c701c('0x25f4')][_0x3c701c('0x61a')][_0x594d6b]['message']});}}else _0x2aeaaa[_0x3c701c('0xfc9')]({'title':_0x2789a4[_0x3c701c('0x52d')]?_0x3c701c('0x1e21')+_0x2789a4[_0x3c701c('0x52d')]+_0x3c701c('0x11e1')+_0x2789a4[_0x3c701c('0xe1b')]:_0x3c701c('0x1b2c'),'msg':_0x2789a4[_0x3c701c('0x25f4')]?JSON['stringify'](_0x2789a4[_0x3c701c('0x25f4')][_0x3c701c('0x1e70')]):_0x2789a4[_0x3c701c('0x1e70')]||_0x2789a4[_0x3c701c('0x1586')]()});});}function _0x22e5b5(){const _0x41d4d4=_0x506e88,_0x2a9d1b=angular[_0x41d4d4('0x225f')](_0x277e83['selectedDispositions']);return _0x277e83[_0x41d4d4('0x1082')]=[],_0x2a9d1b;}function _0x32bfdd(_0x5acd79){const _0xa4bc87=_0x506e88,_0x1c220a=_0x3bc3c6[_0xa4bc87('0x1d26')]()[_0xa4bc87('0xcdc')](_0x5d0c36[_0xa4bc87('0x25cc')](_0xa4bc87('0x24fd')))['content'](_0x5d0c36['instant']('TOOLS.NOTIFICATIONS.DISPOSITIONS_DELETE_MESSAGE',{'total':_0x277e83[_0xa4bc87('0x1082')][_0xa4bc87('0x264b')]}))[_0xa4bc87('0x8e8')](_0xa4bc87('0x19b'))[_0xa4bc87('0x203b')](_0x5acd79)['ok']('OK')['cancel'](_0x5d0c36[_0xa4bc87('0x25cc')](_0xa4bc87('0x12a3')));_0x3bc3c6[_0xa4bc87('0x1f80')](_0x1c220a)['then'](function(){const _0x719a50=_0xa4bc87;_0x277e83[_0x719a50('0x1082')][_0x719a50('0x2782')](function(_0x91bdd1){_0x16cbdd(_0x91bdd1);}),_0x277e83[_0x719a50('0x1082')]=[];});}function _0x1efb5f(){const _0x1701e0=_0x506e88;_0x277e83[_0x1701e0('0x1082')]=[];}function _0x1d8e25(){const _0x3707ca=_0x506e88;_0x277e83[_0x3707ca('0x1082')]=_0x277e83[_0x3707ca('0x4ea')]['rows'];}let _0x4bbf89=!![],_0x336e30=0x1;_0x5a0f24[_0x506e88('0xe83')](_0x506e88('0x28b4'),function(_0x38c79f,_0x5ecd73){const _0x5b02eb=_0x506e88;_0x4bbf89?_0x2e3da3(function(){_0x4bbf89=![];}):(!_0x5ecd73&&(_0x336e30=_0x277e83['query'][_0x5b02eb('0x1a43')]),_0x38c79f!==_0x5ecd73&&(_0x277e83[_0x5b02eb('0x2218')][_0x5b02eb('0x1a43')]=0x1),!_0x38c79f&&(_0x277e83['query'][_0x5b02eb('0x1a43')]=_0x336e30),_0x3fddf9());});}const _0x5c007f=_0x1c835c,_0x23d4f6=_0x2734b2['p']+'src/js/modules/main/apps/mail/views/mailAccounts/edit/agentadd/agentadd.html/agentadd.html';_0x220900[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x21b9'),_0x36e6f4('0x17aa')];function _0x220900(_0x42502b,_0xc0051e,_0x4ee1b5,_0x526c49,_0x24dda5,_0xa31520,_0x5ab2c8,_0x49710b,_0x3ce796,_0x148ea9,_0x3ea344,_0x2c44bf){const _0x5e651a=_0x36e6f4,_0x3482f0=this;_0x3482f0['currentUser']=_0x148ea9[_0x5e651a('0x26cd')](),_0x3482f0['license']=_0xa31520,_0x3482f0[_0x5e651a('0xf8a')]=_0x5ab2c8,_0x3482f0[_0x5e651a('0x2900')]=_0x3482f0[_0x5e651a('0xf8a')][_0x5e651a('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3482f0[_0x5e651a('0x246b')]=_0xc0051e['protocol']()+_0x5e651a('0xc51')+_0xc0051e[_0x5e651a('0x1690')](),_0x3482f0[_0x5e651a('0x21b9')]=_0x3ea344||_0x42502b[_0x5e651a('0x23f')][_0x5e651a('0x21b9')]||{},_0x3482f0['userProfileSection']=_0x2c44bf&&_0x2c44bf[_0x5e651a('0x240f')]==0x1?_0x2c44bf[_0x5e651a('0x269a')][0x0]:null,_0x3482f0[_0x5e651a('0x243c')]=_0x148ea9['parseCrudPermissions'](_0x3482f0['userProfileSection']?_0x3482f0[_0x5e651a('0x17aa')]['crudPermissions']:null),_0x3482f0[_0x5e651a('0x128b')]={},_0x3482f0[_0x5e651a('0x2669')]=_0x42502b[_0x5e651a('0x23f')][_0x5e651a('0xbe3')]||0x0,_0x3482f0[_0x5e651a('0x22c1')]=_0x119fd3,_0x3482f0[_0x5e651a('0x1728')]=_0x269a03,_0x3482f0[_0x5e651a('0x31d')]=_0x3ce796[_0x5e651a('0x1fa1')],_0x3482f0['gotoMailAccounts']=_0x1de22d,_0x3482f0['saveMailAccount']=_0xdcc8d8,_0x148ea9['hasRole'](_0x5e651a('0xa7c'))?_0x49710b[_0x5e651a('0xdd9')][_0x5e651a('0xd83')]({'fields':_0x5e651a('0x1776'),'sort':_0x5e651a('0x4f0')})[_0x5e651a('0xa44')][_0x5e651a('0x1166')](function(_0x1b6384){const _0x51a844=_0x5e651a;_0x3482f0[_0x51a844('0x8de')]=_0x1b6384[_0x51a844('0x269a')]||[];})['catch'](function(_0x56bac3){const _0x492804=_0x5e651a;_0x3ce796[_0x492804('0xfc9')]({'title':_0x56bac3[_0x492804('0x52d')]?_0x492804('0x1e21')+_0x56bac3[_0x492804('0x52d')]+_0x492804('0x11e1')+_0x56bac3[_0x492804('0xe1b')]:_0x492804('0x520'),'msg':_0x56bac3[_0x492804('0x25f4')]?JSON['stringify'](_0x56bac3[_0x492804('0x25f4')]):_0x56bac3[_0x492804('0x1586')]()});}):_0x49710b[_0x5e651a('0xdd9')]['get']({'fields':_0x5e651a('0x1776'),'sort':_0x5e651a('0x4f0')})[_0x5e651a('0xa44')][_0x5e651a('0x1166')](function(_0x3bc23d){const _0x3f20a4=_0x5e651a;_0x3482f0[_0x3f20a4('0x8de')]=_0x3bc23d[_0x3f20a4('0x269a')]||[];})[_0x5e651a('0x1166')](function(){const _0x397f15=_0x5e651a;return _0x49710b[_0x397f15('0x17aa')][_0x397f15('0xd83')]({'userProfileId':_0x3482f0['currentUser'][_0x397f15('0xb86')],'sectionId':0x12d})[_0x397f15('0xa44')];})[_0x5e651a('0x1166')](function(_0x2fc064){const _0x1311f0=_0x5e651a,_0x23c56c=_0x2fc064&&_0x2fc064[_0x1311f0('0x269a')]?_0x2fc064['rows'][0x0]:null;if(!_0x23c56c){const _0x5a5e9f=[];let _0x113cc1=null;_0x3482f0['mailAccount']&&(_0x113cc1=_0x2cfb05()[_0x1311f0('0xc38')](_0x3482f0['lists'],{'id':Number(_0x3482f0[_0x1311f0('0x21b9')]['ListId'])}));for(let _0x413a27=0x0;_0x413a27<_0x3482f0[_0x1311f0('0x8de')]['length'];_0x413a27++){_0x113cc1&&_0x3482f0[_0x1311f0('0x8de')][_0x413a27]['id']===_0x113cc1['id']&&(_0x3482f0[_0x1311f0('0x8de')][_0x413a27]['canSelect']=![],_0x5a5e9f[_0x1311f0('0x1514')](_0x3482f0['lists'][_0x413a27]));}_0x3482f0['lists']=_0x5a5e9f;}else{if(!_0x23c56c[_0x1311f0('0x1a2b')])return _0x49710b[_0x1311f0('0x4b5')][_0x1311f0('0xd83')]({'sectionId':_0x23c56c['id']})['$promise'][_0x1311f0('0x1166')](function(_0x47da9f){const _0x95e496=_0x1311f0,_0x32fe51=_0x2cfb05()[_0x95e496('0x2563')](_0x47da9f[_0x95e496('0x269a')],function(_0x58eb36){const _0x29dc5b=_0x95e496;return _0x2cfb05()[_0x29dc5b('0xc38')](_0x3482f0['lists'],{'id':_0x58eb36[_0x29dc5b('0x24e8')]});});let _0x283ffc=null;_0x3482f0['mailAccount']&&(_0x283ffc=_0x2cfb05()[_0x95e496('0xc38')](_0x3482f0['lists'],{'id':Number(_0x3482f0[_0x95e496('0x21b9')][_0x95e496('0x23c')])}));if(_0x283ffc&&!_0x2cfb05()['some'](_0x32fe51,['id',_0x283ffc['id']])){const _0x4b7907=_0x2cfb05()[_0x95e496('0xc38')](_0x3482f0[_0x95e496('0x8de')],{'id':_0x283ffc['id']});_0x4b7907[_0x95e496('0x2378')]=![],_0x32fe51[_0x95e496('0x1514')](_0x4b7907);}_0x3482f0['lists']=_0x32fe51;});}})[_0x5e651a('0x1a80')](function(_0x40711a){const _0x24359d=_0x5e651a;_0x3ce796[_0x24359d('0xfc9')]({'title':_0x40711a[_0x24359d('0x52d')]?_0x24359d('0x1e21')+_0x40711a[_0x24359d('0x52d')]+'\x20-\x20'+_0x40711a[_0x24359d('0xe1b')]:_0x24359d('0x1248'),'msg':_0x40711a[_0x24359d('0x25f4')]?JSON[_0x24359d('0xbac')](_0x40711a[_0x24359d('0x25f4')]):_0x40711a[_0x24359d('0x1586')]()});}),_0x148ea9[_0x5e651a('0x1ac6')]('admin')?_0x49710b[_0x5e651a('0x1e77')][_0x5e651a('0xd83')]({'fields':'name,id','sort':_0x5e651a('0x4f0'),'nolimit':_0x5e651a('0xf3b')})[_0x5e651a('0xa44')][_0x5e651a('0x1166')](function(_0x427c29){const _0x538c68=_0x5e651a;_0x3482f0[_0x538c68('0xe29')]=_0x427c29[_0x538c68('0x269a')]||[];})['catch'](function(_0x1b2dd5){const _0x3d98bd=_0x5e651a;_0x3ce796[_0x3d98bd('0xfc9')]({'title':_0x1b2dd5[_0x3d98bd('0x52d')]?_0x3d98bd('0x1e21')+_0x1b2dd5[_0x3d98bd('0x52d')]+_0x3d98bd('0x11e1')+_0x1b2dd5[_0x3d98bd('0xe1b')]:_0x3d98bd('0x18ed'),'msg':_0x1b2dd5[_0x3d98bd('0x25f4')]?JSON[_0x3d98bd('0xbac')](_0x1b2dd5[_0x3d98bd('0x25f4')]):_0x1b2dd5[_0x3d98bd('0x1586')]()});}):_0x49710b[_0x5e651a('0x1e77')]['get']({'fields':_0x5e651a('0xcb8'),'sort':_0x5e651a('0x4f0'),'nolimit':_0x5e651a('0xf3b')})[_0x5e651a('0xa44')][_0x5e651a('0x1166')](function(_0x1778a7){const _0x24a5cd=_0x5e651a;_0x3482f0[_0x24a5cd('0xe29')]=_0x1778a7[_0x24a5cd('0x269a')]||[];})[_0x5e651a('0x1166')](function(){const _0x35d071=_0x5e651a;return _0x49710b['userProfileSection']['get']({'userProfileId':_0x3482f0[_0x35d071('0x98')]['userProfileId'],'sectionId':0x3ed})[_0x35d071('0xa44')];})[_0x5e651a('0x1166')](function(_0x5ba89d){const _0x3a83d7=_0x5e651a,_0x2da39c=_0x5ba89d&&_0x5ba89d[_0x3a83d7('0x269a')]?_0x5ba89d['rows'][0x0]:null;if(!_0x2da39c)_0x3482f0['pauses']=[];else{if(!_0x2da39c[_0x3a83d7('0x1a2b')])return _0x49710b[_0x3a83d7('0x4b5')][_0x3a83d7('0xd83')]({'sectionId':_0x2da39c['id']})[_0x3a83d7('0xa44')]['then'](function(_0x52ae34){const _0x3b4c7c=_0x3a83d7,_0x4e1634=_0x2cfb05()[_0x3b4c7c('0x2563')](_0x52ae34[_0x3b4c7c('0x269a')],function(_0x16929c){const _0xc61e85=_0x3b4c7c;return _0x2cfb05()['find'](_0x3482f0[_0xc61e85('0xe29')],{'id':_0x16929c[_0xc61e85('0x24e8')]});});_0x3482f0[_0x3b4c7c('0xe29')][_0x3b4c7c('0x2782')](function(_0x383390){const _0x301d1d=_0x3b4c7c;!_0x2cfb05()[_0x301d1d('0x1798')](_0x4e1634,['id',_0x383390['id']])&&(_0x383390[_0x301d1d('0x2378')]=![]),_0x4e1634[_0x301d1d('0x1514')](_0x383390);}),_0x3482f0[_0x3b4c7c('0xe29')]=_0x4e1634;});}})[_0x5e651a('0x1a80')](function(_0x1ec3fa){const _0x169706=_0x5e651a;_0x3ce796['error']({'title':_0x1ec3fa[_0x169706('0x52d')]?_0x169706('0x1e21')+_0x1ec3fa[_0x169706('0x52d')]+_0x169706('0x11e1')+_0x1ec3fa[_0x169706('0xe1b')]:_0x169706('0x1488'),'msg':_0x1ec3fa[_0x169706('0x25f4')]?JSON[_0x169706('0xbac')](_0x1ec3fa['data']):_0x1ec3fa[_0x169706('0x1586')]()});});function _0x119fd3(){const _0x52d341=_0x5e651a;if(_0x148ea9[_0x52d341('0x1ac6')](_0x52d341('0xa7c')))_0x42502b['go'](_0x52d341('0xbfa'),{});else return _0x49710b['userProfileSection'][_0x52d341('0xd83')]({'userProfileId':_0x148ea9[_0x52d341('0x26cd')]()[_0x52d341('0xb86')],'sectionId':0x262})['$promise']['then'](function(_0x8bc633){const _0x542423=_0x52d341,_0x5b49ef=_0x8bc633&&_0x8bc633[_0x542423('0x269a')]?_0x8bc633[_0x542423('0x269a')][0x0]:null;_0x5b49ef&&_0x5b49ef[_0x542423('0xc27')]?_0x42502b['go'](_0x542423('0xbfa'),{}):_0x3ce796[_0x542423('0x1fa1')]({'title':_0x24dda5[_0x542423('0x25cc')](_0x542423('0x627')),'msg':_0x24dda5['instant']('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_MESSAGE')});})[_0x52d341('0x1a80')](function(_0x4006d9){const _0x48ed84=_0x52d341;_0x3ce796[_0x48ed84('0xfc9')]({'title':_0x4006d9[_0x48ed84('0x52d')]?_0x48ed84('0x1e21')+_0x4006d9['status']+_0x48ed84('0x11e1')+_0x4006d9[_0x48ed84('0xe1b')]:_0x48ed84('0x153e'),'msg':_0x4006d9[_0x48ed84('0x52d')]?JSON[_0x48ed84('0xbac')](_0x4006d9[_0x48ed84('0x25f4')]):_0x4006d9[_0x48ed84('0x1586')]()});});}function _0x269a03(_0x4f6492,_0x56dd6c){const _0x4716ab=_0x5e651a;_0x4ee1b5['show']({'controller':_0x4716ab('0x2729'),'controllerAs':'vm','templateUrl':_0x23d4f6,'parent':angular['element'](_0x526c49['body']),'targetEvent':_0x56dd6c,'clickOutsideToClose':!![],'locals':{'mailAccount':_0x4f6492,'mailAccounts':_0x3482f0[_0x4716ab('0xf85')]?_0x3482f0[_0x4716ab('0xf85')]['rows']:[],'crudPermissions':_0x3482f0['crudPermissions'],'realtime':![]}});}function _0x1de22d(){const _0x752c6d=_0x5e651a;_0x42502b['go'](_0x752c6d('0xc81'),{},{'reload':_0x752c6d('0xc81')});}function _0xdcc8d8(){const _0x4c0c51=_0x5e651a;_0x49710b[_0x4c0c51('0x21b9')][_0x4c0c51('0x1449')]({'id':_0x3482f0[_0x4c0c51('0x21b9')]['id']},_0x3482f0[_0x4c0c51('0x21b9')])[_0x4c0c51('0xa44')][_0x4c0c51('0x1166')](function(){const _0x2e145b=_0x4c0c51;_0x3ce796['success']({'title':_0x2e145b('0x1411'),'msg':_0x3482f0['mailAccount']['name']?_0x3482f0[_0x2e145b('0x21b9')][_0x2e145b('0x4f0')]+_0x2e145b('0xa17'):''});})[_0x4c0c51('0x1a80')](function(_0x1cc71a){const _0x457c6e=_0x4c0c51;_0x3ce796[_0x457c6e('0xfc9')]({'title':_0x1cc71a['status']?'API:'+_0x1cc71a[_0x457c6e('0x52d')]+_0x457c6e('0x11e1')+_0x1cc71a[_0x457c6e('0xe1b')]:_0x457c6e('0xabc'),'msg':_0x1cc71a[_0x457c6e('0x25f4')]?JSON[_0x457c6e('0xbac')](_0x1cc71a[_0x457c6e('0x25f4')]):_0x1cc71a[_0x457c6e('0x1586')]()});});}}const _0x1b534e=_0x220900,_0x503ce7=_0x2734b2['p']+'src/js/modules/main/apps/mail/views/mailAccounts/create/dialog.html/dialog.html';_0x357b3b['$inject']=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$mdSidenav',_0x36e6f4('0x265d'),'$document','$timeout','$translate',_0x36e6f4('0xf85'),_0x36e6f4('0x7f'),'userProfileSection','api','msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x357b3b(_0x12fedc,_0x9d684a,_0x146311,_0x11c6ec,_0x52a41b,_0x5d8f85,_0x116b5f,_0x283ea7,_0x56b039,_0x3f81a7,_0x4f069d,_0x8abacf,_0x2704ca,_0x33773e,_0x581e65,_0x266ad0,_0x4d9ab7){const _0x1c03f2=_0x36e6f4,_0x1c7757=this;_0x1c7757[_0x1c03f2('0x5c9')]=_0x266ad0,_0x1c7757[_0x1c03f2('0xf8a')]=_0x4d9ab7,_0x1c7757[_0x1c03f2('0x98')]=_0x581e65['getCurrentUser'](),_0x1c7757['mailAccounts']=_0x56b039||{'count':0x0,'rows':[]},_0x1c7757['userProfile']=_0x3f81a7,_0x1c7757[_0x1c03f2('0x17aa')]=_0x4f069d&&_0x4f069d[_0x1c03f2('0x240f')]==0x1?_0x4f069d[_0x1c03f2('0x269a')][0x0]:null,_0x1c7757[_0x1c03f2('0x243c')]=_0x581e65[_0x1c03f2('0xd87')](_0x1c7757[_0x1c03f2('0x17aa')]?_0x1c7757[_0x1c03f2('0x17aa')][_0x1c03f2('0x243c')]:null),_0x1c7757['table']='mailAccounts',_0x1c7757[_0x1c03f2('0xef5')]='',_0x1c7757[_0x1c03f2('0x104c')]=null,_0x1c7757[_0x1c03f2('0x998')]=[],_0x1c7757['query']={'fields':_0x1c03f2('0xb5d'),'sort':_0x1c03f2('0x14dc'),'limit':0xa,'page':0x1},_0x1c7757[_0x1c03f2('0x1113')]=_0x2cfb05()[_0x1c03f2('0x155c')]([{'option':_0x1c03f2('0x117f'),'value':_0x1c03f2('0x15d7')},{'option':'Gmail','value':'\x27gmail\x27'},{'option':'Hotmail','value':_0x1c03f2('0x14a6')},{'option':'Yahoo','value':_0x1c03f2('0x1262')},{'option':_0x1c03f2('0x549'),'value':_0x1c03f2('0x200a')}],function(_0x4b02b0){const _0x1a517a=_0x1c03f2;return _0x2cfb05()['replace'](_0x4b02b0[_0x1a517a('0x18e0')],new RegExp('\x27','g'),'');}),_0x1c7757[_0x1c03f2('0x3d')]=_0x2cfb05()[_0x1c03f2('0x155c')]([{'option':_0x1c03f2('0x117f'),'value':_0x1c03f2('0x15d7')},{'option':_0x1c03f2('0xdc1'),'value':'\x27gmail\x27'},{'option':'Hotmail','value':_0x1c03f2('0x14a6')},{'option':'Yahoo','value':_0x1c03f2('0x1262')},{'option':'Outlook365','value':'\x27outlook365\x27'}],function(_0x4c3f4c){const _0x1cb384=_0x1c03f2;return _0x2cfb05()[_0x1cb384('0xf3')](_0x4c3f4c[_0x1cb384('0x18e0')],new RegExp('\x27','g'),'');}),_0x1c7757[_0x1c03f2('0x1ec7')]=_0x2cfb05()[_0x1c03f2('0x155c')]([{'option':'Custom','value':_0x1c03f2('0x15d7')},{'option':_0x1c03f2('0xdc1'),'value':'\x27gmail\x27'},{'option':_0x1c03f2('0x165c'),'value':'\x27hotmail\x27'},{'option':_0x1c03f2('0x1bae'),'value':_0x1c03f2('0x1262')},{'option':'Outlook365','value':_0x1c03f2('0x200a')}],function(_0x434c34){const _0x394b76=_0x1c03f2;return _0x2cfb05()[_0x394b76('0xf3')](_0x434c34[_0x394b76('0x18e0')],new RegExp('\x27','g'),'');}),_0x1c7757[_0x1c03f2('0x1ff6')]=_0x43b393,_0x1c7757[_0x1c03f2('0x23fe')]=_0x3eff1d,_0x1c7757[_0x1c03f2('0x5e9')]=_0x5628cd,_0x1c7757[_0x1c03f2('0x182d')]=_0x509104,_0x1c7757[_0x1c03f2('0x1728')]=_0xc35693,_0x1c7757['deleteconfirm']=_0x82e78e,_0x1c7757['success']=_0x487736,_0x1c7757['getMailAccounts']=_0x36dfe7,_0x1c7757[_0x1c03f2('0x64b')]=_0x40c7ce,_0x1c7757['deleteMailAccount']=_0x569af6,_0x1c7757[_0x1c03f2('0x2552')]=_0x4f88ec,_0x1c7757['deleteSelectedMailAccounts']=_0x4f0f5b,_0x1c7757[_0x1c03f2('0x2660')]=_0x5f36f5,_0x1c7757[_0x1c03f2('0x1f81')]=_0x2add64,_0x581e65['hasRole'](_0x1c03f2('0xa7c'))?_0x8abacf['cmList'][_0x1c03f2('0xd83')]({'fields':_0x1c03f2('0x1776'),'sort':'name'})[_0x1c03f2('0xa44')][_0x1c03f2('0x1166')](function(_0x4e6052){const _0x2c2ee7=_0x1c03f2;_0x1c7757[_0x2c2ee7('0x8de')]=_0x4e6052[_0x2c2ee7('0x269a')]||[];})['catch'](function(_0x138b44){const _0x260703=_0x1c03f2;_0x33773e[_0x260703('0xfc9')]({'title':_0x138b44[_0x260703('0x52d')]?_0x260703('0x1e21')+_0x138b44[_0x260703('0x52d')]+_0x260703('0x11e1')+_0x138b44[_0x260703('0xe1b')]:'SYSTEM:GET_LISTS','msg':_0x138b44[_0x260703('0x25f4')]?JSON[_0x260703('0xbac')](_0x138b44['data']):_0x138b44[_0x260703('0x1586')]()});}):_0x8abacf[_0x1c03f2('0xdd9')][_0x1c03f2('0xd83')]({'fields':'id,name','sort':_0x1c03f2('0x4f0')})[_0x1c03f2('0xa44')][_0x1c03f2('0x1166')](function(_0x430c82){_0x1c7757['lists']=_0x430c82['rows']||[];})[_0x1c03f2('0x1166')](function(){const _0x103de2=_0x1c03f2;return _0x8abacf[_0x103de2('0x17aa')][_0x103de2('0xd83')]({'userProfileId':_0x1c7757[_0x103de2('0x98')][_0x103de2('0xb86')],'sectionId':0x12d})[_0x103de2('0xa44')];})[_0x1c03f2('0x1166')](function(_0x2e75d5){const _0x165e9a=_0x1c03f2,_0x1c0c9f=_0x2e75d5&&_0x2e75d5[_0x165e9a('0x269a')]?_0x2e75d5[_0x165e9a('0x269a')][0x0]:null;if(!_0x1c0c9f){const _0x31d4f3=[];let _0x3b6693=null;_0x1c7757[_0x165e9a('0x21b9')]&&(_0x3b6693=_0x2cfb05()['find'](_0x1c7757[_0x165e9a('0x8de')],{'id':Number(_0x1c7757['mailAccount'][_0x165e9a('0x23c')])}));for(let _0x42b692=0x0;_0x42b692<_0x1c7757[_0x165e9a('0x8de')][_0x165e9a('0x264b')];_0x42b692++){_0x3b6693&&_0x1c7757[_0x165e9a('0x8de')][_0x42b692]['id']===_0x3b6693['id']&&(_0x1c7757[_0x165e9a('0x8de')][_0x42b692][_0x165e9a('0x2378')]=![],_0x31d4f3[_0x165e9a('0x1514')](_0x1c7757[_0x165e9a('0x8de')][_0x42b692]));}_0x1c7757[_0x165e9a('0x8de')]=_0x31d4f3;}else{if(!_0x1c0c9f['autoAssociation'])return _0x8abacf[_0x165e9a('0x4b5')][_0x165e9a('0xd83')]({'sectionId':_0x1c0c9f['id']})[_0x165e9a('0xa44')][_0x165e9a('0x1166')](function(_0x592e28){const _0x4a66f6=_0x165e9a,_0x2d1232=_0x2cfb05()[_0x4a66f6('0x2563')](_0x592e28[_0x4a66f6('0x269a')],function(_0x3b37b6){const _0x4bed38=_0x4a66f6;return _0x2cfb05()[_0x4bed38('0xc38')](_0x1c7757[_0x4bed38('0x8de')],{'id':_0x3b37b6['resourceId']});});let _0x3932bd=null;_0x1c7757[_0x4a66f6('0x21b9')]&&(_0x3932bd=_0x2cfb05()[_0x4a66f6('0xc38')](_0x1c7757['lists'],{'id':Number(_0x1c7757[_0x4a66f6('0x21b9')]['ListId'])}));if(_0x3932bd&&!_0x2cfb05()[_0x4a66f6('0x1798')](_0x2d1232,['id',_0x3932bd['id']])){const _0x3cff34=_0x2cfb05()[_0x4a66f6('0xc38')](_0x1c7757['lists'],{'id':_0x3932bd['id']});_0x3cff34[_0x4a66f6('0x2378')]=![],_0x2d1232['push'](_0x3cff34);}_0x1c7757[_0x4a66f6('0x8de')]=_0x2d1232;});}})[_0x1c03f2('0x1a80')](function(_0x1846ea){const _0x268b57=_0x1c03f2;_0x33773e[_0x268b57('0xfc9')]({'title':_0x1846ea[_0x268b57('0x52d')]?_0x268b57('0x1e21')+_0x1846ea['status']+_0x268b57('0x11e1')+_0x1846ea[_0x268b57('0xe1b')]:_0x268b57('0x1248'),'msg':_0x1846ea[_0x268b57('0x25f4')]?JSON['stringify'](_0x1846ea[_0x268b57('0x25f4')]):_0x1846ea[_0x268b57('0x1586')]()});});function _0x43b393(_0x3ee33d){const _0x3b3779=_0x1c03f2;_0x146311['go']('app.mail.mailAccounts.edit',{'id':_0x3ee33d['id'],'mailAccount':_0x3ee33d,'crudPermissions':_0x1c7757[_0x3b3779('0x243c')]});}function _0x3eff1d(_0x2c2307){const _0x535034=_0x1c03f2;if(_0x2c2307&&_0x2c2307['id'])return _0x8abacf['mailAccount'][_0x535034('0x1126')]({'id':_0x2c2307['id']})['$promise'][_0x535034('0x1166')](function(){const _0x5a73d7=_0x535034;_0x33773e[_0x5a73d7('0x103b')]({'title':'Smtp\x20properly\x20verified','msg':_0x5a73d7('0x1fef')});})['catch'](function(_0x19f2d6){const _0x3671a6=_0x535034;_0x33773e[_0x3671a6('0xfc9')]({'title':_0x3671a6('0x1424'),'msg':_0x19f2d6[_0x3671a6('0x25f4')]?JSON['stringify'](_0x19f2d6[_0x3671a6('0x25f4')]):_0x19f2d6[_0x3671a6('0x1586')]()});});else _0x33773e['error']({'title':_0x535034('0x1424'),'msg':_0x535034('0x144b')});}function _0x5628cd(_0x40ccae){const _0x1cd42f=_0x1c03f2;_0x146311['go'](_0x1cd42f('0x9bf'),{'id':_0x40ccae['id'],'tab':0x7});}function _0x509104(){const _0x4294af=_0x1c03f2;if(_0x581e65['hasRole']('admin'))_0x146311['go'](_0x4294af('0xbfa'),{});else return _0x8abacf[_0x4294af('0x17aa')][_0x4294af('0xd83')]({'userProfileId':_0x581e65[_0x4294af('0x26cd')]()[_0x4294af('0xb86')],'sectionId':0x262})[_0x4294af('0xa44')][_0x4294af('0x1166')](function(_0x3cf3d9){const _0x2de7c9=_0x4294af,_0x103d62=_0x3cf3d9&&_0x3cf3d9[_0x2de7c9('0x269a')]?_0x3cf3d9[_0x2de7c9('0x269a')][0x0]:null;_0x103d62&&_0x103d62['enabled']?_0x146311['go'](_0x2de7c9('0xbfa'),{}):_0x33773e[_0x2de7c9('0x1fa1')]({'title':_0x283ea7[_0x2de7c9('0x25cc')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x283ea7['instant'](_0x2de7c9('0x2642'))});})[_0x4294af('0x1a80')](function(_0x52ce47){const _0x47ed75=_0x4294af;_0x33773e[_0x47ed75('0xfc9')]({'title':_0x52ce47[_0x47ed75('0x52d')]?'API:'+_0x52ce47['status']+_0x47ed75('0x11e1')+_0x52ce47[_0x47ed75('0xe1b')]:_0x47ed75('0x153e'),'msg':_0x52ce47[_0x47ed75('0x52d')]?JSON['stringify'](_0x52ce47[_0x47ed75('0x25f4')]):_0x52ce47[_0x47ed75('0x1586')]()});});}function _0xc35693(_0x30cb7b,_0x4ebeb9){const _0x9cd91e=_0x1c03f2;_0x52a41b[_0x9cd91e('0x1f80')]({'controller':_0x9cd91e('0x2729'),'controllerAs':'vm','templateUrl':_0x23d4f6,'parent':angular['element'](_0x5d8f85['body']),'targetEvent':_0x4ebeb9,'clickOutsideToClose':!![],'locals':{'mailAccount':_0x30cb7b,'mailAccounts':_0x1c7757['mailAccounts']?_0x1c7757['mailAccounts'][_0x9cd91e('0x269a')]:[],'crudPermissions':_0x1c7757[_0x9cd91e('0x243c')],'realtime':![]}});}function _0x82e78e(_0x13acfe,_0x7abd81){const _0x33f4f9=_0x1c03f2,_0x1f3ffd=_0x52a41b[_0x33f4f9('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x33f4f9('0xb35')](_0x33f4f9('0x21b9'))+'?')['htmlContent'](_0x33f4f9('0x12b5')+(_0x13acfe[_0x33f4f9('0x4f0')]||'mailAccount')+_0x33f4f9('0xace')+_0x33f4f9('0x3f3'))[_0x33f4f9('0x8e8')](_0x33f4f9('0x1bf7'))['targetEvent'](_0x7abd81)['ok']('OK')['cancel'](_0x33f4f9('0x2d3'));_0x52a41b[_0x33f4f9('0x1f80')](_0x1f3ffd)['then'](function(){_0x569af6(_0x13acfe);},function(){const _0x38ebb2=_0x33f4f9;console['log'](_0x38ebb2('0x2d3'));});}let _0x208371=!![],_0xf80f4d=0x1;_0x12fedc['$watch']('vm.query.filter',function(_0x5d936e,_0x2fda91){const _0x1a34bc=_0x1c03f2;_0x208371?_0x116b5f(function(){_0x208371=![];}):(!_0x2fda91&&(_0xf80f4d=_0x1c7757['query']['page']),_0x5d936e!==_0x2fda91&&(_0x1c7757[_0x1a34bc('0x2218')]['page']=0x1),!_0x5d936e&&(_0x1c7757[_0x1a34bc('0x2218')][_0x1a34bc('0x1a43')]=_0xf80f4d),_0x1c7757[_0x1a34bc('0xf73')]());});function _0x487736(_0x598a48){const _0x4476a7=_0x1c03f2;_0x1c7757[_0x4476a7('0xf85')]=_0x598a48||{'count':0x0,'rows':[]};}function _0x36dfe7(){const _0x17d83b=_0x1c03f2;_0x1c7757['query']['offset']=(_0x1c7757[_0x17d83b('0x2218')][_0x17d83b('0x1a43')]-0x1)*_0x1c7757[_0x17d83b('0x2218')][_0x17d83b('0x163f')],_0x581e65[_0x17d83b('0x1ac6')](_0x17d83b('0xa7c'))?_0x1c7757[_0x17d83b('0x1f48')]=_0x8abacf['mailAccount']['get'](_0x1c7757[_0x17d83b('0x2218')],_0x487736)['$promise']:(_0x1c7757['query']['id']=_0x1c7757[_0x17d83b('0x7f')]['id'],_0x1c7757['query'][_0x17d83b('0xe60')]=_0x17d83b('0x17bd'),_0x1c7757[_0x17d83b('0x1f48')]=_0x8abacf[_0x17d83b('0x7f')][_0x17d83b('0x263a')](_0x1c7757[_0x17d83b('0x2218')],_0x487736)['$promise']);}function _0x40c7ce(_0x4d8b7d,_0xc97122){const _0x463b1c=_0x1c03f2;_0x52a41b['show']({'controller':_0x463b1c('0x894'),'controllerAs':'vm','templateUrl':_0x503ce7,'parent':angular[_0x463b1c('0x1194')](_0x5d8f85[_0x463b1c('0x8d2')]),'targetEvent':_0x4d8b7d,'clickOutsideToClose':!![],'locals':{'mailAccount':_0xc97122,'mailAccounts':_0x1c7757['mailAccounts'][_0x463b1c('0x269a')],'license':_0x1c7757[_0x463b1c('0x5c9')],'setting':_0x1c7757[_0x463b1c('0xf8a')],'crudPermissions':_0x1c7757[_0x463b1c('0x243c')]}});}function _0x569af6(_0x356513){const _0x15fadb=_0x1c03f2;if(_0x356513[_0x15fadb('0x1725')])return _0x33773e[_0x15fadb('0xfc9')]({'title':_0x15fadb('0x1933'),'msg':_0x15fadb('0xb3b')});_0x8abacf[_0x15fadb('0x21b9')]['delete']({'id':_0x356513['id']})[_0x15fadb('0xa44')][_0x15fadb('0x1166')](function(){const _0x5d8399=_0x15fadb;_0x2cfb05()[_0x5d8399('0x127f')](_0x1c7757[_0x5d8399('0xf85')][_0x5d8399('0x269a')],{'id':_0x356513['id']}),_0x1c7757[_0x5d8399('0xf85')][_0x5d8399('0x240f')]-=0x1,!_0x1c7757[_0x5d8399('0xf85')][_0x5d8399('0x269a')][_0x5d8399('0x264b')]&&_0x1c7757[_0x5d8399('0xf73')](),_0x33773e[_0x5d8399('0x103b')]({'title':_0x2cfb05()[_0x5d8399('0xb35')](_0x5d8399('0x24ce'))+_0x5d8399('0x2b6'),'msg':_0x356513[_0x5d8399('0x4f0')]?_0x356513[_0x5d8399('0x4f0')]+_0x5d8399('0x7cd'):''});})[_0x15fadb('0x1a80')](function(_0x4bad08){const _0x4ca54c=_0x15fadb;if(_0x4bad08[_0x4ca54c('0x25f4')]&&_0x4bad08[_0x4ca54c('0x25f4')][_0x4ca54c('0x61a')]&&_0x4bad08[_0x4ca54c('0x25f4')]['errors'][_0x4ca54c('0x264b')]){_0x1c7757[_0x4ca54c('0x61a')]=_0x4bad08['data']['errors']||[{'message':_0x4bad08[_0x4ca54c('0x1586')](),'type':_0x4ca54c('0x17be')}];for(let _0x25482d=0x0;_0x25482d<_0x4bad08['data'][_0x4ca54c('0x61a')]['length'];_0x25482d++){_0x33773e['error']({'title':_0x4bad08[_0x4ca54c('0x25f4')][_0x4ca54c('0x61a')][_0x25482d][_0x4ca54c('0x1345')],'msg':_0x4bad08[_0x4ca54c('0x25f4')]['errors'][_0x25482d][_0x4ca54c('0x1e70')]});}}else _0x33773e[_0x4ca54c('0xfc9')]({'title':_0x4bad08[_0x4ca54c('0x52d')]?_0x4ca54c('0x1e21')+_0x4bad08[_0x4ca54c('0x52d')]+_0x4ca54c('0x11e1')+_0x4bad08[_0x4ca54c('0xe1b')]:_0x4ca54c('0x17be'),'msg':_0x4bad08[_0x4ca54c('0x25f4')]?JSON[_0x4ca54c('0xbac')](_0x4bad08[_0x4ca54c('0x25f4')][_0x4ca54c('0x1e70')]):_0x4bad08[_0x4ca54c('0x1e70')]||_0x4bad08[_0x4ca54c('0x1586')]()});});}function _0x4f88ec(){const _0x5a5248=_0x1c03f2,_0x39f7ae=angular[_0x5a5248('0x225f')](_0x1c7757['selectedMailAccounts']);return _0x1c7757[_0x5a5248('0x998')]=[],_0x39f7ae;}function _0x4f0f5b(_0xadda16){const _0x1d0b61=_0x1c03f2,_0x39c77e=_0x52a41b[_0x1d0b61('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20mailAccounts?')['htmlContent'](_0x1d0b61('0x12b5')+_0x1c7757[_0x1d0b61('0x998')][_0x1d0b61('0x264b')]+'\x20selected'+_0x1d0b61('0x3f3'))[_0x1d0b61('0x8e8')](_0x1d0b61('0x11dc'))['targetEvent'](_0xadda16)['ok']('OK')[_0x1d0b61('0x3f')]('CANCEL');_0x52a41b[_0x1d0b61('0x1f80')](_0x39c77e)['then'](function(){const _0x417e0f=_0x1d0b61;_0x1c7757[_0x417e0f('0x998')][_0x417e0f('0x2782')](function(_0x1bc186){_0x569af6(_0x1bc186);}),_0x1c7757[_0x417e0f('0x998')]=[];});}function _0x5f36f5(){const _0x3650c9=_0x1c03f2;_0x1c7757[_0x3650c9('0x998')]=[];}function _0x2add64(){const _0x4cbf3f=_0x1c03f2;_0x1c7757['selectedMailAccounts']=_0x1c7757['mailAccounts'][_0x4cbf3f('0x269a')];}}const _0x12826b=_0x357b3b;_0x23731b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0x273'),_0x36e6f4('0x24c9'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x23731b(_0x272321,_0x374653,_0x5694b5,_0x56b9a6,_0x3f1013,_0x3956ef,_0x5c497c,_0x49dbaa,_0x18e094,_0x556a22,_0x20002c,_0x58cd73,_0x2ea19c,_0x5677ed){const _0x39f05a=_0x36e6f4,_0x1cfe1a=this;_0x1cfe1a['currentUser']=_0x20002c[_0x39f05a('0x26cd')](),_0x1cfe1a[_0x39f05a('0x61a')]=[],_0x1cfe1a['setting']=_0x2ea19c,_0x1cfe1a['license']=_0x58cd73,_0x1cfe1a[_0x39f05a('0x243c')]=_0x5677ed,_0x1cfe1a['hasModulePermissions']={},_0x1cfe1a['passwordPattern']=_0x1cfe1a[_0x39f05a('0xf8a')]&&_0x1cfe1a[_0x39f05a('0xf8a')][_0x39f05a('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1cfe1a[_0x39f05a('0xcdc')]='MAIL.EDIT_MAILQUEUE',_0x1cfe1a[_0x39f05a('0x24c9')]=angular[_0x39f05a('0x225f')](_0x18e094),_0x1cfe1a[_0x39f05a('0x273')]=_0x49dbaa,_0x1cfe1a[_0x39f05a('0x21b4')]=![];!_0x1cfe1a[_0x39f05a('0x24c9')]&&(_0x1cfe1a[_0x39f05a('0x24c9')]={'strategy':_0x39f05a('0x278c'),'timeout':0xa},_0x1cfe1a[_0x39f05a('0xcdc')]=_0x39f05a('0x21c3'),_0x1cfe1a[_0x39f05a('0x21b4')]=!![]);_0x1cfe1a['addNewMailQueue']=_0x314798,_0x1cfe1a['saveMailQueue']=_0x1a62e5,_0x1cfe1a[_0x39f05a('0x1e40')]=_0x623d51,_0x1cfe1a['getDateFromString']=_0x5c4f56,_0x1cfe1a['closeDialog']=_0x1406f6;function _0x314798(){const _0x11072e=_0x39f05a;_0x1cfe1a[_0x11072e('0x61a')]=[],_0x556a22[_0x11072e('0x24c9')][_0x11072e('0x9cc')](_0x1cfe1a['mailQueue'])[_0x11072e('0xa44')][_0x11072e('0x1166')](function(_0x4ed843){const _0x5ccfce=_0x11072e;_0x1cfe1a[_0x5ccfce('0x273')][_0x5ccfce('0x2450')](_0x4ed843['toJSON']()),_0x5c497c[_0x5ccfce('0x103b')]({'title':_0x5ccfce('0x719'),'msg':_0x1cfe1a[_0x5ccfce('0x24c9')]['name']?_0x1cfe1a['mailQueue'][_0x5ccfce('0x4f0')]+_0x5ccfce('0x1eda'):''}),_0x1406f6(_0x4ed843);})[_0x11072e('0x1a80')](function(_0x3af72f){const _0x15275d=_0x11072e;if(_0x3af72f[_0x15275d('0x25f4')]&&_0x3af72f['data'][_0x15275d('0x61a')]&&_0x3af72f[_0x15275d('0x25f4')][_0x15275d('0x61a')][_0x15275d('0x264b')]){_0x1cfe1a[_0x15275d('0x61a')]=_0x3af72f[_0x15275d('0x25f4')][_0x15275d('0x61a')]||[{'message':_0x3af72f[_0x15275d('0x1586')](),'type':_0x15275d('0x2064')}];for(let _0x5ed5c7=0x0;_0x5ed5c7<_0x3af72f[_0x15275d('0x25f4')][_0x15275d('0x61a')][_0x15275d('0x264b')];_0x5ed5c7+=0x1){_0x5c497c[_0x15275d('0xfc9')]({'title':_0x3af72f['data'][_0x15275d('0x61a')][_0x5ed5c7]['type'],'msg':_0x3af72f[_0x15275d('0x25f4')][_0x15275d('0x61a')][_0x5ed5c7]['message']});}}else _0x5c497c['error']({'title':_0x3af72f[_0x15275d('0x52d')]?'API:'+_0x3af72f[_0x15275d('0x52d')]+_0x15275d('0x11e1')+_0x3af72f[_0x15275d('0xe1b')]:'api.mailQueue.save','msg':_0x3af72f[_0x15275d('0x25f4')]?JSON[_0x15275d('0xbac')](_0x3af72f[_0x15275d('0x25f4')][_0x15275d('0x1e70')]):_0x3af72f[_0x15275d('0x1586')]()});});}function _0x1a62e5(){const _0x5305e1=_0x39f05a;_0x1cfe1a[_0x5305e1('0x61a')]=[],_0x556a22[_0x5305e1('0x24c9')]['update']({'id':_0x1cfe1a[_0x5305e1('0x24c9')]['id']},_0x1cfe1a['mailQueue'])[_0x5305e1('0xa44')][_0x5305e1('0x1166')](function(_0x133ff4){const _0x4129c8=_0x5305e1,_0x43fe52=_0x2cfb05()[_0x4129c8('0xc38')](_0x1cfe1a[_0x4129c8('0x273')],{'id':_0x133ff4['id']});_0x43fe52&&_0x2cfb05()[_0x4129c8('0xcc3')](_0x43fe52,_0x2cfb05()[_0x4129c8('0x1a08')](_0x133ff4[_0x4129c8('0x2876')](),_0x2cfb05()[_0x4129c8('0x14a4')](_0x43fe52))),_0x5c497c[_0x4129c8('0x103b')]({'title':_0x4129c8('0xcde'),'msg':_0x1cfe1a[_0x4129c8('0x24c9')][_0x4129c8('0x4f0')]?_0x1cfe1a[_0x4129c8('0x24c9')]['name']+'\x20has\x20been\x20saved!':''}),_0x1406f6(_0x133ff4);})[_0x5305e1('0x1a80')](function(_0x1dc0d7){const _0x40c921=_0x5305e1;if(_0x1dc0d7[_0x40c921('0x25f4')]&&_0x1dc0d7[_0x40c921('0x25f4')][_0x40c921('0x61a')]&&_0x1dc0d7[_0x40c921('0x25f4')][_0x40c921('0x61a')]['length']){_0x1cfe1a['errors']=_0x1dc0d7[_0x40c921('0x25f4')]['errors']||[{'message':_0x1dc0d7[_0x40c921('0x1586')](),'type':_0x40c921('0x1da0')}];for(let _0x3e976f=0x0;_0x3e976f<_0x1dc0d7['data'][_0x40c921('0x61a')][_0x40c921('0x264b')];_0x3e976f++){_0x5c497c['error']({'title':_0x1dc0d7[_0x40c921('0x25f4')][_0x40c921('0x61a')][_0x3e976f][_0x40c921('0x1345')],'msg':_0x1dc0d7[_0x40c921('0x25f4')][_0x40c921('0x61a')][_0x3e976f][_0x40c921('0x1e70')]});}}else _0x5c497c['error']({'title':_0x1dc0d7[_0x40c921('0x52d')]?_0x40c921('0x1e21')+_0x1dc0d7[_0x40c921('0x52d')]+_0x40c921('0x11e1')+_0x1dc0d7[_0x40c921('0xe1b')]:_0x40c921('0x1da0'),'msg':_0x1dc0d7[_0x40c921('0x25f4')]?JSON['stringify'](_0x1dc0d7[_0x40c921('0x25f4')]['message']):_0x1dc0d7[_0x40c921('0x1586')]()});});}function _0x623d51(_0x5dbea9){const _0x34682c=_0x39f05a;_0x1cfe1a[_0x34682c('0x61a')]=[];const _0x5eeff8=_0x56b9a6[_0x34682c('0x1d26')]()[_0x34682c('0xcdc')](_0x34682c('0x7fb'))[_0x34682c('0xacc')](_0x34682c('0x17d8'))[_0x34682c('0x8e8')]('Delete\x20MailQueue')['ok'](_0x34682c('0x18'))[_0x34682c('0x3f')]('Cancel')['targetEvent'](_0x5dbea9);_0x56b9a6[_0x34682c('0x1f80')](_0x5eeff8)['then'](function(){const _0x5b5555=_0x34682c;_0x556a22[_0x5b5555('0x24c9')]['delete']({'id':_0x1cfe1a['mailQueue']['id']})[_0x5b5555('0xa44')]['then'](function(){const _0x52439b=_0x5b5555;_0x2cfb05()[_0x52439b('0x127f')](_0x1cfe1a[_0x52439b('0x273')],{'id':_0x1cfe1a[_0x52439b('0x24c9')]['id']}),_0x5c497c[_0x52439b('0x103b')]({'title':_0x52439b('0x53d'),'msg':(_0x1cfe1a['mailQueue']['name']||_0x52439b('0x24c9'))+_0x52439b('0x7cd')}),_0x1406f6(_0x1cfe1a['mailQueue']);})[_0x5b5555('0x1a80')](function(_0x2dd885){const _0x2ecfdb=_0x5b5555;if(_0x2dd885[_0x2ecfdb('0x25f4')]&&_0x2dd885[_0x2ecfdb('0x25f4')][_0x2ecfdb('0x61a')]&&_0x2dd885[_0x2ecfdb('0x25f4')][_0x2ecfdb('0x61a')]['length']){_0x1cfe1a['errors']=_0x2dd885[_0x2ecfdb('0x25f4')][_0x2ecfdb('0x61a')]||[{'message':_0x2dd885['toString'](),'type':'api.mailQueue.delete'}];for(let _0x1df0c7=0x0;_0x1df0c7<_0x2dd885[_0x2ecfdb('0x25f4')][_0x2ecfdb('0x61a')][_0x2ecfdb('0x264b')];_0x1df0c7++){_0x5c497c['error']({'title':_0x2dd885[_0x2ecfdb('0x25f4')][_0x2ecfdb('0x61a')][_0x1df0c7][_0x2ecfdb('0x1345')],'msg':_0x2dd885[_0x2ecfdb('0x25f4')][_0x2ecfdb('0x61a')][_0x1df0c7][_0x2ecfdb('0x1e70')]});}}else _0x5c497c[_0x2ecfdb('0xfc9')]({'title':_0x2dd885['status']?_0x2ecfdb('0x1e21')+_0x2dd885['status']+_0x2ecfdb('0x11e1')+_0x2dd885['statusText']:_0x2ecfdb('0x17d5'),'msg':_0x2dd885[_0x2ecfdb('0x25f4')]?JSON[_0x2ecfdb('0xbac')](_0x2dd885[_0x2ecfdb('0x25f4')][_0x2ecfdb('0x1e70')]):_0x2dd885[_0x2ecfdb('0x1e70')]||_0x2dd885[_0x2ecfdb('0x1586')]()});});},function(){});}function _0x5c4f56(_0x1bdc56){return _0x1bdc56===null?undefined:new Date(_0x1bdc56);}function _0x1406f6(_0xfd98ae){const _0x2d750c=_0x39f05a;_0x56b9a6[_0x2d750c('0x1197')](_0xfd98ae);}}const _0x51d507=_0x23731b;_0x2ffc72['$inject']=['$mdDialog','$q',_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x24c9'),_0x36e6f4('0x273'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),'Auth','crudPermissions'];function _0x2ffc72(_0x415f32,_0x105c05,_0x157e7d,_0x5158ab,_0x3badaa,_0x19a6d9,_0x3cbb5e,_0x30e611,_0x7012b1,_0x38b662){const _0x35870b=_0x36e6f4,_0x28fe71=this;_0x28fe71['currentUser']=_0x7012b1['getCurrentUser'](),_0x28fe71[_0x35870b('0x24c9')]=_0x3badaa,_0x28fe71[_0x35870b('0x243c')]=_0x38b662,_0x28fe71[_0x35870b('0xf01')]=_0x3cbb5e,_0x28fe71[_0x35870b('0xbd7')]=[],_0x28fe71[_0x35870b('0x10ab')]=[],_0x28fe71['selectedItems']=[],_0x28fe71[_0x35870b('0x2111')]=[],_0x28fe71[_0x35870b('0x2781')]=[],_0x28fe71['pendingChanges']=![],_0x28fe71[_0x35870b('0xae0')]=_0x4d11c8,_0x28fe71[_0x35870b('0x1d92')]=_0x583000,_0x28fe71[_0x35870b('0x24a0')]=_0x4c2d55,_0x28fe71[_0x35870b('0xc68')]={'readOnly':!_0x28fe71[_0x35870b('0x243c')][_0x35870b('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x35870b('0x4f0'),'line1':_0x35870b('0x6e1'),'line2':[_0x35870b('0x4f0'),_0x35870b('0x1eef')],'line3':'','labelAll':_0x30e611[_0x35870b('0x25cc')]('MAIL.ALL_AGENTS'),'labelSelected':_0x30e611[_0x35870b('0x25cc')](_0x35870b('0x230')),'transferCallback':function(){const _0x3f14db=_0x35870b,_0x3683d9=_0x2cfb05()[_0x3f14db('0x2802')](_0x28fe71['startingSelectedItems'],_0x28fe71['selectedItems'],'id');_0x28fe71['pendingChanges']=_0x2cfb05()[_0x3f14db('0x1081')](_0x3683d9)?![]:!![];}};function _0x4d11c8(){const _0xf27801=_0x35870b;return _0x7012b1[_0xf27801('0x1ac6')]('admin')?_0x1bd905()[_0xf27801('0x1a80')](function(_0x2aad62){const _0x144438=_0xf27801;_0x157e7d[_0x144438('0xfc9')]({'title':_0x2aad62[_0x144438('0x52d')]?_0x144438('0x1e21')+_0x2aad62[_0x144438('0x52d')]+_0x144438('0x11e1')+_0x2aad62['statusText']:_0x144438('0xd4c'),'msg':_0x2aad62['status']?JSON[_0x144438('0xbac')](_0x2aad62[_0x144438('0x25f4')]):_0x2aad62[_0x144438('0x1586')]()});}):_0x2775d1()['then'](function(_0x4b615c){return _0x28fe71['section']=_0x4b615c,_0x1bd905();})[_0xf27801('0x1a80')](function(_0x32cb74){const _0x4e5367=_0xf27801;_0x157e7d[_0x4e5367('0xfc9')]({'title':_0x32cb74[_0x4e5367('0x52d')]?_0x4e5367('0x1e21')+_0x32cb74['status']+_0x4e5367('0x11e1')+_0x32cb74[_0x4e5367('0xe1b')]:'SYSTEM:GET_AGENTS','msg':_0x32cb74[_0x4e5367('0x52d')]?JSON[_0x4e5367('0xbac')](_0x32cb74[_0x4e5367('0x25f4')]):_0x32cb74[_0x4e5367('0x1586')]()});});}function _0x2775d1(){return _0x105c05(function(_0x5dac92,_0x549498){const _0x38b49f=a0_0x3f2c;_0x5158ab['userProfileSection'][_0x38b49f('0xd83')]({'userProfileId':_0x28fe71[_0x38b49f('0x98')][_0x38b49f('0xb86')],'name':_0x38b49f('0x2391')})[_0x38b49f('0xa44')][_0x38b49f('0x1166')](function(_0x17d282){const _0x26c7d0=_0x38b49f,_0x4705a9=_0x17d282&&_0x17d282[_0x26c7d0('0x269a')]?_0x17d282[_0x26c7d0('0x269a')][0x0]:null;_0x5dac92(_0x4705a9);})[_0x38b49f('0x1a80')](function(_0x46ec7a){_0x549498(_0x46ec7a);});});}function _0x1bd905(){return _0x105c05(function(_0x517086,_0x52b16b){const _0xb76cc3=a0_0x3f2c;return _0x21a845()['then'](function(_0x1b9587){const _0x45fa11=a0_0x3f2c;return _0x28fe71[_0x45fa11('0xbd7')]=_0x1b9587[_0x45fa11('0x269a')]?_0x1b9587[_0x45fa11('0x269a')]:[],_0x7012b1[_0x45fa11('0x1ac6')]('admin')?_0x1b9587:_0x28fe71['section']?_0x28fe71['section'][_0x45fa11('0x1a2b')]?_0x1b9587:_0x13e533():null;})[_0xb76cc3('0x1166')](function(_0x1e4445){const _0x7b1186=_0xb76cc3,_0x57d165=_0x1e4445&&_0x1e4445[_0x7b1186('0x269a')]?_0x1e4445[_0x7b1186('0x269a')]:[];return _0x28fe71[_0x7b1186('0x10ab')]=_0x2cfb05()[_0x7b1186('0x2563')](_0x57d165,function(_0x2638e8){const _0x5513bb=_0x7b1186;return _0x2cfb05()[_0x5513bb('0xc38')](_0x28fe71[_0x5513bb('0xbd7')],{'id':_0x7012b1[_0x5513bb('0x1ac6')](_0x5513bb('0xa7c'))||_0x28fe71['section']['autoAssociation']?_0x2638e8['id']:_0x2638e8[_0x5513bb('0x24e8')]});}),_0x28fe71['startingAllowedItems']=angular['copy'](_0x28fe71['allowedItems']),_0x28fe71['items'][_0x7b1186('0x2782')](function(_0xa59227){const _0x1a1c6f=_0x7b1186,_0x572397=_0x2cfb05()[_0x1a1c6f('0xc38')](_0x28fe71[_0x1a1c6f('0x10ab')],{'id':_0xa59227['id']});_0x7012b1['hasRole']('admin')?_0xa59227[_0x1a1c6f('0x26ef')]=!![]:_0xa59227[_0x1a1c6f('0x26ef')]=typeof _0x572397!==_0x1a1c6f('0x1048')?!![]:![];}),_0x5c729f();})[_0xb76cc3('0x1166')](function(_0x41a286){const _0x54fbbc=_0xb76cc3,_0x3cf2b9=_0x41a286&&_0x41a286['rows']?_0x41a286['rows']:[];_0x28fe71[_0x54fbbc('0x18e1')]=_0x2cfb05()[_0x54fbbc('0x2563')](_0x3cf2b9,function(_0x3bec4f){const _0x21641b=_0x54fbbc,_0x4e5a2a=_0x2cfb05()[_0x21641b('0xc38')](_0x28fe71[_0x21641b('0xbd7')],{'id':_0x3bec4f['id']});return _0x4e5a2a[_0x21641b('0x23af')]=_0x3bec4f[_0x21641b('0x1987')]?_0x21641b('0x11e8')+_0x3bec4f[_0x21641b('0x1987')][_0x21641b('0x23af')]:'',_0x4e5a2a[_0x21641b('0x1eef')]=typeof _0x3bec4f[_0x21641b('0x1eef')]!==_0x21641b('0x1048')?'<'+_0x3bec4f[_0x21641b('0x1eef')]+'>':'',_0x4e5a2a;}),_0x28fe71[_0x54fbbc('0x2781')]=angular[_0x54fbbc('0x225f')](_0x28fe71['selectedItems']),_0x28fe71[_0x54fbbc('0xc68')]['selectedItems']=_0x28fe71[_0x54fbbc('0x18e1')],_0x28fe71[_0x54fbbc('0xc68')][_0x54fbbc('0xbd7')]=_0x2cfb05()[_0x54fbbc('0x24ac')](_0x28fe71[_0x54fbbc('0x10ab')],_0x28fe71[_0x54fbbc('0xc68')][_0x54fbbc('0x18e1')],'id'),_0x517086();})[_0xb76cc3('0x1a80')](function(_0x10063e){_0x52b16b(_0x10063e);});});}function _0x13e533(){return _0x105c05(function(_0x505b38,_0x5a7fd8){const _0x1b2745=a0_0x3f2c;return _0x5158ab['userProfileResource'][_0x1b2745('0xd83')]({'sectionId':_0x28fe71[_0x1b2745('0xe60')]['id'],'nolimit':!![]})[_0x1b2745('0xa44')]['then'](function(_0x58e466){_0x505b38(_0x58e466);})[_0x1b2745('0x1a80')](function(_0x5ab99b){_0x5a7fd8(_0x5ab99b);});});}function _0x5c729f(){return _0x105c05(function(_0x48867d,_0x10a681){const _0x515299=a0_0x3f2c;return _0x5158ab[_0x515299('0x24c9')][_0x515299('0x261c')]({'id':_0x28fe71[_0x515299('0x24c9')]['id'],'fields':_0x515299('0x1459'),'nolimit':!![],'role':_0x515299('0x1eff')})['$promise'][_0x515299('0x1166')](function(_0x589e52){_0x48867d(_0x589e52);})[_0x515299('0x1a80')](function(_0x19fff7){_0x10a681(_0x19fff7);});});}function _0x21a845(){return _0x105c05(function(_0x509d54,_0x102c10){const _0x53c3a9=a0_0x3f2c;return _0x5158ab[_0x53c3a9('0x557')][_0x53c3a9('0xd83')]({'fields':_0x53c3a9('0x1459'),'nolimit':!![],'role':_0x53c3a9('0x1eff')})[_0x53c3a9('0xa44')][_0x53c3a9('0x1166')](function(_0x26638b){_0x509d54(_0x26638b);})[_0x53c3a9('0x1a80')](function(_0xd5cdd6){_0x102c10(_0xd5cdd6);});});}function _0x3dd955(_0x34f3a5){return _0x105c05(function(_0x8cb643,_0x306209){const _0x1c2c8d=a0_0x3f2c;_0x2cfb05()[_0x1c2c8d('0x1081')](_0x34f3a5)?_0x8cb643():_0x5158ab[_0x1c2c8d('0x24c9')][_0x1c2c8d('0x275c')]({'id':_0x28fe71['mailQueue']['id'],'ids':_0x2cfb05()['map'](_0x34f3a5,'id')})[_0x1c2c8d('0xa44')][_0x1c2c8d('0x1166')](function(){_0x8cb643();})[_0x1c2c8d('0x1a80')](function(_0x33358e){_0x306209(_0x33358e);});});}function _0x5acf17(_0x3c908b){return _0x105c05(function(_0x409ec8,_0x13086a){const _0x51b6ca=a0_0x3f2c;_0x2cfb05()['isEmpty'](_0x3c908b)?_0x409ec8():_0x5158ab[_0x51b6ca('0x24c9')][_0x51b6ca('0x269d')]({'id':_0x28fe71['mailQueue']['id'],'ids':_0x2cfb05()[_0x51b6ca('0x2563')](_0x3c908b,'id')})[_0x51b6ca('0xa44')][_0x51b6ca('0x1166')](function(){_0x409ec8();})[_0x51b6ca('0x1a80')](function(_0x229613){_0x13086a(_0x229613);});});}function _0x583000(){const _0x2789fc=_0x35870b,_0x1cade9=_0x2cfb05()[_0x2789fc('0x24ac')](_0x28fe71[_0x2789fc('0x2781')],_0x28fe71[_0x2789fc('0x18e1')],'id'),_0x12472e=_0x2cfb05()[_0x2789fc('0x24ac')](_0x28fe71['selectedItems'],_0x28fe71[_0x2789fc('0x2781')],'id');return _0x5acf17(_0x1cade9)[_0x2789fc('0x1166')](function(){return _0x3dd955(_0x12472e);})[_0x2789fc('0x1166')](function(){const _0x5178f4=_0x2789fc;_0x28fe71['pendingChanges']=![],_0x28fe71['startingAllowedItems']=angular[_0x5178f4('0x225f')](_0x28fe71[_0x5178f4('0x10ab')]),_0x28fe71[_0x5178f4('0x2781')]=angular[_0x5178f4('0x225f')](_0x28fe71['selectedItems']),_0x157e7d['success']({'title':'SUCCESS','msg':_0x5178f4('0x1673')});})[_0x2789fc('0x1a80')](function(_0x2d729e){const _0x2c177d=_0x2789fc;_0x157e7d[_0x2c177d('0xfc9')]({'title':_0x2d729e[_0x2c177d('0x52d')]?_0x2c177d('0x1e21')+_0x2d729e[_0x2c177d('0x52d')]+'\x20-\x20'+_0x2d729e[_0x2c177d('0xe1b')]:_0x2c177d('0x1b29'),'msg':_0x2d729e[_0x2c177d('0x52d')]?JSON[_0x2c177d('0xbac')](_0x2d729e[_0x2c177d('0x25f4')]):_0x2d729e[_0x2c177d('0x1586')]()});});}function _0x4c2d55(){const _0x4de5d3=_0x35870b;_0x415f32[_0x4de5d3('0x1197')]();}}const _0x232949=_0x2ffc72;_0x2313fc['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x24c9'),'$translate',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x2313fc(_0x558ab3,_0x23f719,_0x23d6e8,_0x55cc4c,_0x2b27ba,_0xbf7561,_0x38ade3,_0x4b95e5){const _0x14d363=_0x36e6f4,_0x539d83=this;_0x539d83[_0x14d363('0x98')]=_0x38ade3[_0x14d363('0x26cd')](),_0x539d83[_0x14d363('0x24c9')]=_0x2b27ba,_0x539d83[_0x14d363('0x243c')]=_0x4b95e5,_0x539d83[_0x14d363('0xbd7')]=[],_0x539d83[_0x14d363('0x10ab')]=[],_0x539d83[_0x14d363('0x18e1')]=[],_0x539d83[_0x14d363('0x2111')]=[],_0x539d83['startingSelectedItems']=[],_0x539d83[_0x14d363('0x14d7')]=![],_0x539d83[_0x14d363('0xc68')]={'readOnly':!_0x539d83[_0x14d363('0x243c')][_0x14d363('0x1684')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x14d363('0x4f0'),'line1':_0x14d363('0x4f0'),'line2':'','line3':'','labelAll':_0xbf7561[_0x14d363('0x25cc')](_0x14d363('0x1fee')),'labelSelected':_0xbf7561['instant'](_0x14d363('0x1b49')),'transferCallback':function(){const _0x3a1cfd=_0x14d363,_0x1555e1=_0x2cfb05()[_0x3a1cfd('0x2802')](_0x539d83[_0x3a1cfd('0x2781')],_0x539d83['selectedItems'],'id');_0x539d83[_0x3a1cfd('0x14d7')]=_0x2cfb05()[_0x3a1cfd('0x1081')](_0x1555e1)?![]:!![];}},_0x539d83['onInit']=_0x27ddcf,_0x539d83['saveTeams']=_0x48d920,_0x539d83['closeDialog']=_0x47d450;function _0x27ddcf(){const _0x38a99d=_0x14d363;return _0x38ade3[_0x38a99d('0x1ac6')](_0x38a99d('0xa7c'))?_0x1e55f4()[_0x38a99d('0x1a80')](function(_0x1dfb0c){const _0x53a75a=_0x38a99d;_0x23d6e8[_0x53a75a('0xfc9')]({'title':_0x1dfb0c[_0x53a75a('0x52d')]?'API:'+_0x1dfb0c[_0x53a75a('0x52d')]+_0x53a75a('0x11e1')+_0x1dfb0c[_0x53a75a('0xe1b')]:_0x53a75a('0x1031'),'msg':_0x1dfb0c[_0x53a75a('0x52d')]?JSON[_0x53a75a('0xbac')](_0x1dfb0c[_0x53a75a('0x25f4')]):_0x1dfb0c[_0x53a75a('0x1586')]()});}):_0x154dfd()[_0x38a99d('0x1166')](function(_0x172102){return _0x539d83['section']=_0x172102,_0x1e55f4();})[_0x38a99d('0x1a80')](function(_0x1d53cd){const _0x4ea670=_0x38a99d;_0x23d6e8[_0x4ea670('0xfc9')]({'title':_0x1d53cd[_0x4ea670('0x52d')]?_0x4ea670('0x1e21')+_0x1d53cd['status']+_0x4ea670('0x11e1')+_0x1d53cd[_0x4ea670('0xe1b')]:_0x4ea670('0x1031'),'msg':_0x1d53cd['status']?JSON[_0x4ea670('0xbac')](_0x1d53cd[_0x4ea670('0x25f4')]):_0x1d53cd[_0x4ea670('0x1586')]()});});}function _0x154dfd(){return _0x23f719(function(_0x351177,_0x1e62a2){const _0xc51600=a0_0x3f2c;_0x55cc4c[_0xc51600('0x17aa')]['get']({'userProfileId':_0x539d83[_0xc51600('0x98')]['userProfileId'],'name':_0xc51600('0x289e')})['$promise']['then'](function(_0x57ed57){const _0x450d55=_0x57ed57&&_0x57ed57['rows']?_0x57ed57['rows'][0x0]:null;_0x351177(_0x450d55);})[_0xc51600('0x1a80')](function(_0x340ac2){_0x1e62a2(_0x340ac2);});});}function _0x1e55f4(){return _0x23f719(function(_0x42698a,_0x580b5f){const _0x4ed755=a0_0x3f2c;return _0x41486b()[_0x4ed755('0x1166')](function(_0x4aa668){const _0x59ce8c=_0x4ed755;return _0x539d83['items']=_0x4aa668[_0x59ce8c('0x269a')]?_0x4aa668[_0x59ce8c('0x269a')]:[],_0x38ade3[_0x59ce8c('0x1ac6')](_0x59ce8c('0xa7c'))?_0x4aa668:_0x539d83[_0x59ce8c('0xe60')]?_0x539d83[_0x59ce8c('0xe60')][_0x59ce8c('0x1a2b')]?_0x4aa668:_0x5236d5():null;})[_0x4ed755('0x1166')](function(_0x2d4853){const _0x4bc29e=_0x4ed755,_0x28b212=_0x2d4853&&_0x2d4853[_0x4bc29e('0x269a')]?_0x2d4853['rows']:[];return _0x539d83['allowedItems']=_0x2cfb05()[_0x4bc29e('0x2563')](_0x28b212,function(_0x469402){const _0xf31cb8=_0x4bc29e;return _0x2cfb05()[_0xf31cb8('0xc38')](_0x539d83[_0xf31cb8('0xbd7')],{'id':_0x38ade3['hasRole'](_0xf31cb8('0xa7c'))||_0x539d83[_0xf31cb8('0xe60')][_0xf31cb8('0x1a2b')]?_0x469402['id']:_0x469402[_0xf31cb8('0x24e8')]});}),_0x539d83['items'][_0x4bc29e('0x2782')](function(_0x1b84fa){const _0x43c9ed=_0x4bc29e,_0x9af0a1=_0x2cfb05()[_0x43c9ed('0xc38')](_0x539d83[_0x43c9ed('0x10ab')],{'id':_0x1b84fa['id']});_0x38ade3[_0x43c9ed('0x1ac6')]('admin')?_0x1b84fa[_0x43c9ed('0x26ef')]=!![]:_0x1b84fa[_0x43c9ed('0x26ef')]=typeof _0x9af0a1!=='undefined'?!![]:![];}),_0x2696bf();})[_0x4ed755('0x1166')](function(_0x25cb5c){const _0x44c346=_0x4ed755,_0x32072d=_0x25cb5c&&_0x25cb5c[_0x44c346('0x269a')]?_0x25cb5c['rows']:[];_0x539d83[_0x44c346('0x18e1')]=_0x2cfb05()[_0x44c346('0x2563')](_0x32072d,function(_0x2875f3){const _0x2c7291=_0x44c346;return _0x2cfb05()[_0x2c7291('0xc38')](_0x539d83[_0x2c7291('0xbd7')],{'id':_0x2875f3['id']});}),_0x539d83[_0x44c346('0x2781')]=angular[_0x44c346('0x225f')](_0x539d83[_0x44c346('0x18e1')]),_0x539d83[_0x44c346('0xc68')][_0x44c346('0x18e1')]=_0x539d83[_0x44c346('0x18e1')],_0x539d83[_0x44c346('0xc68')][_0x44c346('0xbd7')]=_0x2cfb05()['differenceBy'](_0x539d83[_0x44c346('0x10ab')],_0x539d83[_0x44c346('0xc68')][_0x44c346('0x18e1')],'id'),_0x42698a();})[_0x4ed755('0x1a80')](function(_0x3fc03c){_0x580b5f(_0x3fc03c);});});}function _0x5236d5(){return _0x23f719(function(_0x372dd8,_0xfd1bc5){const _0x1ffbae=a0_0x3f2c;return _0x55cc4c[_0x1ffbae('0x4b5')]['get']({'sectionId':_0x539d83['section']['id'],'nolimit':!![]})[_0x1ffbae('0xa44')][_0x1ffbae('0x1166')](function(_0x4e94d5){_0x372dd8(_0x4e94d5);})[_0x1ffbae('0x1a80')](function(_0x443147){_0xfd1bc5(_0x443147);});});}function _0x2696bf(){return _0x23f719(function(_0x25ba9e,_0x3825e1){const _0x464f13=a0_0x3f2c;return _0x55cc4c['mailQueue'][_0x464f13('0x1448')]({'id':_0x539d83[_0x464f13('0x24c9')]['id'],'fields':_0x464f13('0x1776'),'nolimit':!![]})[_0x464f13('0xa44')][_0x464f13('0x1166')](function(_0x375fb6){_0x25ba9e(_0x375fb6);})[_0x464f13('0x1a80')](function(_0x38dbc0){_0x3825e1(_0x38dbc0);});});}function _0x41486b(){return _0x23f719(function(_0x101329,_0x7ca731){const _0x52978d=a0_0x3f2c;return _0x55cc4c[_0x52978d('0x1e37')][_0x52978d('0xd83')]({'fields':_0x52978d('0x1776'),'nolimit':!![]})[_0x52978d('0xa44')][_0x52978d('0x1166')](function(_0x950c13){_0x101329(_0x950c13);})[_0x52978d('0x1a80')](function(_0xbf63c1){_0x7ca731(_0xbf63c1);});});}function _0xff2f34(_0x4e8a89){return _0x23f719(function(_0x4d25e8,_0x13e829){const _0x528da=a0_0x3f2c;_0x2cfb05()[_0x528da('0x1081')](_0x4e8a89)?_0x4d25e8():_0x55cc4c['mailQueue'][_0x528da('0x16e0')]({'id':_0x539d83[_0x528da('0x24c9')]['id'],'ids':_0x2cfb05()[_0x528da('0x2563')](_0x4e8a89,'id')})[_0x528da('0xa44')]['then'](function(){_0x4d25e8();})[_0x528da('0x1a80')](function(_0x4dd714){_0x13e829(_0x4dd714);});});}function _0x2410f3(_0x58d88e){return _0x23f719(function(_0x14a050,_0x3c3321){const _0x2fb320=a0_0x3f2c;_0x2cfb05()[_0x2fb320('0x1081')](_0x58d88e)?_0x14a050():_0x55cc4c[_0x2fb320('0x24c9')][_0x2fb320('0x8f')]({'id':_0x539d83[_0x2fb320('0x24c9')]['id'],'ids':_0x2cfb05()[_0x2fb320('0x2563')](_0x58d88e,'id')})[_0x2fb320('0xa44')][_0x2fb320('0x1166')](function(){_0x14a050();})[_0x2fb320('0x1a80')](function(_0x38fbf3){_0x3c3321(_0x38fbf3);});});}function _0x48d920(){const _0x5be550=_0x14d363,_0x28e1cb=_0x2cfb05()[_0x5be550('0x24ac')](_0x539d83[_0x5be550('0x2781')],_0x539d83[_0x5be550('0x18e1')],'id'),_0x1a1e7c=_0x2cfb05()[_0x5be550('0x24ac')](_0x539d83['selectedItems'],_0x539d83[_0x5be550('0x2781')],'id');return _0x2410f3(_0x28e1cb)[_0x5be550('0x1166')](function(){return _0xff2f34(_0x1a1e7c);})[_0x5be550('0x1166')](function(){const _0x23dba1=_0x5be550;_0x539d83[_0x23dba1('0x14d7')]=![],_0x539d83[_0x23dba1('0x2111')]=angular[_0x23dba1('0x225f')](_0x539d83[_0x23dba1('0x10ab')]),_0x539d83[_0x23dba1('0x2781')]=angular[_0x23dba1('0x225f')](_0x539d83['selectedItems']),_0x23d6e8['success']({'title':_0x23dba1('0x983'),'msg':_0x23dba1('0x1f6b')});})[_0x5be550('0x1a80')](function(_0x520c10){const _0x5edb19=_0x5be550;_0x23d6e8[_0x5edb19('0xfc9')]({'title':_0x520c10[_0x5edb19('0x52d')]?_0x5edb19('0x1e21')+_0x520c10['status']+'\x20-\x20'+_0x520c10[_0x5edb19('0xe1b')]:_0x5edb19('0x1b29'),'msg':_0x520c10[_0x5edb19('0x52d')]?JSON[_0x5edb19('0xbac')](_0x520c10[_0x5edb19('0x25f4')]):_0x520c10['toString']()});});}function _0x47d450(){const _0x5c876f=_0x14d363;_0x558ab3[_0x5c876f('0x1197')]();}}const _0x4e3baa=_0x2313fc,_0x2a07d1=_0x2734b2['p']+_0x36e6f4('0x1e14');_0x1ab3fa['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),'license',_0x36e6f4('0xf8a'),'api',_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x24c9'),_0x36e6f4('0x17aa')];function _0x1ab3fa(_0x347ed4,_0x1036a2,_0x3971c4,_0x57dc29,_0x48110a,_0x216e7b,_0x17de3e,_0x3b2a89,_0x4faad3,_0x436281,_0x3dcb0c,_0x327c78){const _0x438cb8=_0x36e6f4,_0x1d0b39=this;_0x1d0b39[_0x438cb8('0x98')]=_0x436281[_0x438cb8('0x26cd')](),_0x1d0b39[_0x438cb8('0x5c9')]=_0x216e7b,_0x1d0b39[_0x438cb8('0xf8a')]=_0x17de3e,_0x1d0b39[_0x438cb8('0x2900')]=_0x1d0b39[_0x438cb8('0xf8a')][_0x438cb8('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1d0b39[_0x438cb8('0x246b')]=_0x1036a2[_0x438cb8('0x6f1')]()+_0x438cb8('0xc51')+_0x1036a2[_0x438cb8('0x1690')](),_0x1d0b39[_0x438cb8('0x24c9')]=_0x3dcb0c||_0x347ed4[_0x438cb8('0x23f')][_0x438cb8('0x24c9')]||{},_0x1d0b39[_0x438cb8('0x17aa')]=_0x327c78&&_0x327c78[_0x438cb8('0x240f')]==0x1?_0x327c78[_0x438cb8('0x269a')][0x0]:null,_0x1d0b39[_0x438cb8('0x243c')]=_0x436281[_0x438cb8('0xd87')](_0x1d0b39[_0x438cb8('0x17aa')]?_0x1d0b39[_0x438cb8('0x17aa')][_0x438cb8('0x243c')]:null),_0x1d0b39[_0x438cb8('0x128b')]={},_0x1d0b39['selectedTab']=_0x347ed4[_0x438cb8('0x23f')][_0x438cb8('0xbe3')]||0x0,_0x1d0b39[_0x438cb8('0x292')]=_0x3538a9,_0x1d0b39[_0x438cb8('0x1728')]=_0x115937,_0x1d0b39[_0x438cb8('0x31d')]=_0x4faad3['info'],_0x1d0b39['gotoMailQueues']=_0x390d7e,_0x1d0b39[_0x438cb8('0x249f')]=_0x13c54d;function _0x3538a9(_0x42a05d,_0x33fbde){const _0x2868e1=_0x438cb8;_0x3971c4[_0x2868e1('0x1f80')]({'controller':_0x2868e1('0x724'),'controllerAs':'vm','templateUrl':_0x2a07d1,'parent':angular[_0x2868e1('0x1194')](_0x57dc29[_0x2868e1('0x8d2')]),'targetEvent':_0x33fbde,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x42a05d,'mailQueues':_0x1d0b39[_0x2868e1('0x273')]?_0x1d0b39[_0x2868e1('0x273')][_0x2868e1('0x269a')]:[],'crudPermissions':_0x1d0b39[_0x2868e1('0x243c')]}});}function _0x115937(_0x502f51,_0x182c87){const _0x56366d=_0x438cb8;_0x3971c4[_0x56366d('0x1f80')]({'controller':'MailQueueagentaddController','controllerAs':'vm','templateUrl':_0x58bfc2,'parent':angular[_0x56366d('0x1194')](_0x57dc29[_0x56366d('0x8d2')]),'targetEvent':_0x182c87,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x502f51,'mailQueues':_0x1d0b39['mailQueues']?_0x1d0b39[_0x56366d('0x273')]['rows']:[],'crudPermissions':_0x1d0b39[_0x56366d('0x243c')],'realtime':![]}});}function _0x390d7e(){const _0x480861=_0x438cb8;_0x347ed4['go'](_0x480861('0x2025'),{},{'reload':_0x480861('0x2025')});}function _0x13c54d(){const _0x5b54c6=_0x438cb8;_0x3b2a89[_0x5b54c6('0x24c9')][_0x5b54c6('0x1449')]({'id':_0x1d0b39[_0x5b54c6('0x24c9')]['id']},_0x1d0b39[_0x5b54c6('0x24c9')])['$promise']['then'](function(){const _0x4eaaf5=_0x5b54c6;_0x4faad3[_0x4eaaf5('0x103b')]({'title':_0x4eaaf5('0x344'),'msg':_0x1d0b39[_0x4eaaf5('0x24c9')]['name']?_0x1d0b39[_0x4eaaf5('0x24c9')]['name']+'\x20has\x20been\x20updated!':''});})[_0x5b54c6('0x1a80')](function(_0x32c550){const _0x348503=_0x5b54c6;_0x4faad3[_0x348503('0xfc9')]({'title':_0x32c550[_0x348503('0x52d')]?'API:'+_0x32c550[_0x348503('0x52d')]+_0x348503('0x11e1')+_0x32c550[_0x348503('0xe1b')]:'SYSTEM:GETmailQueue','msg':_0x32c550[_0x348503('0x25f4')]?JSON[_0x348503('0xbac')](_0x32c550['data']):_0x32c550[_0x348503('0x1586')]()});});}}const _0x306581=_0x1ab3fa;_0x2fe32d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x273'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a')];function _0x2fe32d(_0x1d34a9,_0x51e80b,_0xc952e8,_0xcaad2f,_0x2e537b,_0xf859b,_0x2834e6,_0x422cd0,_0x49b574,_0x105701,_0x17ce21,_0x4ce002,_0x3bf1d5,_0x4d1261,_0x3640be,_0x15b3aa,_0x8caf60){const _0xe88c45=_0x36e6f4,_0x1e3698=this;_0x1e3698[_0xe88c45('0x5c9')]=_0x15b3aa,_0x1e3698['setting']=_0x8caf60,_0x1e3698['currentUser']=_0x3640be['getCurrentUser'](),_0x1e3698[_0xe88c45('0x273')]=_0x49b574||{'count':0x0,'rows':[]},_0x1e3698[_0xe88c45('0x7f')]=_0x105701,_0x1e3698[_0xe88c45('0x17aa')]=_0x17ce21&&_0x17ce21['count']==0x1?_0x17ce21[_0xe88c45('0x269a')][0x0]:null,_0x1e3698[_0xe88c45('0x243c')]=_0x3640be[_0xe88c45('0xd87')](_0x1e3698[_0xe88c45('0x17aa')]?_0x1e3698[_0xe88c45('0x17aa')][_0xe88c45('0x243c')]:null),_0x1e3698[_0xe88c45('0x916')]=_0xe88c45('0x273'),_0x1e3698[_0xe88c45('0xef5')]='',_0x1e3698[_0xe88c45('0x104c')]=null,_0x1e3698[_0xe88c45('0x178')]=[],_0x1e3698['query']={'fields':_0xe88c45('0xf26'),'sort':'-updatedAt','channel':'mail','limit':0xa,'page':0x1},_0x1e3698[_0xe88c45('0x1440')]=_0x2cfb05()[_0xe88c45('0x155c')]([{'option':'Beepall','value':_0xe88c45('0x1792')},{'option':_0xe88c45('0x75'),'value':_0xe88c45('0x11ad')}],function(_0x3df3a2){const _0x53e82a=_0xe88c45;return _0x2cfb05()[_0x53e82a('0xf3')](_0x3df3a2['value'],new RegExp('\x27','g'),'');}),_0x1e3698['editstate']=_0x596d22,_0x1e3698['teamadddialog']=_0x1d4115,_0x1e3698[_0xe88c45('0x1728')]=_0x389cf7,_0x1e3698['deleteconfirm']=_0x12eb83,_0x1e3698[_0xe88c45('0x182d')]=_0x1300cd,_0x1e3698[_0xe88c45('0x103b')]=_0x5c78e7,_0x1e3698[_0xe88c45('0xf84')]=_0x123be3,_0x1e3698[_0xe88c45('0x2840')]=_0x19cdf1,_0x1e3698[_0xe88c45('0x1e40')]=_0x3770df,_0x1e3698['exportSelectedMailQueues']=_0x13c545,_0x1e3698[_0xe88c45('0x2902')]=_0x2fc2c1,_0x1e3698[_0xe88c45('0x1a2e')]=_0x76be5f,_0x1e3698['selectAllMailQueues']=_0x278333;function _0x596d22(_0x1dd1fc){const _0x2d2faa=_0xe88c45;_0xc952e8['go'](_0x2d2faa('0x23e0'),{'id':_0x1dd1fc['id'],'mailQueue':_0x1dd1fc,'crudPermissions':_0x1e3698[_0x2d2faa('0x243c')]});}function _0x1d4115(_0x405f96,_0x2a165a){const _0x485a41=_0xe88c45;_0x2e537b[_0x485a41('0x1f80')]({'controller':_0x485a41('0x724'),'controllerAs':'vm','templateUrl':_0x2a07d1,'parent':angular[_0x485a41('0x1194')](_0xf859b[_0x485a41('0x8d2')]),'targetEvent':_0x2a165a,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x405f96,'mailQueues':_0x1e3698['mailQueues']?_0x1e3698[_0x485a41('0x273')][_0x485a41('0x269a')]:[],'crudPermissions':_0x1e3698[_0x485a41('0x243c')]}});}function _0x389cf7(_0xaea9f7,_0x498f10){const _0x2e97b5=_0xe88c45;_0x2e537b[_0x2e97b5('0x1f80')]({'controller':_0x2e97b5('0x4f6'),'controllerAs':'vm','templateUrl':_0x58bfc2,'parent':angular[_0x2e97b5('0x1194')](_0xf859b[_0x2e97b5('0x8d2')]),'targetEvent':_0x498f10,'clickOutsideToClose':!![],'locals':{'mailQueue':_0xaea9f7,'mailQueues':_0x1e3698['mailQueues']?_0x1e3698[_0x2e97b5('0x273')][_0x2e97b5('0x269a')]:[],'crudPermissions':_0x1e3698[_0x2e97b5('0x243c')],'realtime':![]}});}function _0x12eb83(_0x3a7743,_0x445f8d){const _0x3229a6=_0xe88c45,_0x13c076=_0x2e537b['confirm']()[_0x3229a6('0xcdc')](_0x3229a6('0x288d')+_0x2cfb05()[_0x3229a6('0xb35')](_0x3229a6('0x24c9'))+'?')[_0x3229a6('0xf3c')](''+(_0x3a7743[_0x3229a6('0x4f0')]||_0x3229a6('0x24c9'))+_0x3229a6('0xace')+'\x20will\x20be\x20deleted.')[_0x3229a6('0x8e8')]('delete\x20mailQueue')[_0x3229a6('0x203b')](_0x445f8d)['ok']('OK')['cancel'](_0x3229a6('0x2d3'));_0x2e537b[_0x3229a6('0x1f80')](_0x13c076)[_0x3229a6('0x1166')](function(){_0x3770df(_0x3a7743);},function(){const _0x388eca=_0x3229a6;console[_0x388eca('0x455')](_0x388eca('0x2d3'));});}function _0x1300cd(){const _0x5c9951=_0xe88c45;if(_0x3640be[_0x5c9951('0x1ac6')]('admin'))_0xc952e8['go']('app.mail.realtime.queues',{});else return _0x4ce002[_0x5c9951('0x17aa')][_0x5c9951('0xd83')]({'userProfileId':_0x3640be[_0x5c9951('0x26cd')]()[_0x5c9951('0xb86')],'sectionId':0x262})[_0x5c9951('0xa44')][_0x5c9951('0x1166')](function(_0x5629ac){const _0x3d12f3=_0x5c9951,_0xcc0c48=_0x5629ac&&_0x5629ac['rows']?_0x5629ac[_0x3d12f3('0x269a')][0x0]:null;_0xcc0c48&&_0xcc0c48[_0x3d12f3('0xc27')]?_0xc952e8['go'](_0x3d12f3('0x1ccd'),{}):_0x4d1261['info']({'title':_0x422cd0[_0x3d12f3('0x25cc')](_0x3d12f3('0x627')),'msg':_0x422cd0[_0x3d12f3('0x25cc')](_0x3d12f3('0x2642'))});})[_0x5c9951('0x1a80')](function(_0x243e79){const _0x44cb82=_0x5c9951;_0x4d1261[_0x44cb82('0xfc9')]({'title':_0x243e79[_0x44cb82('0x52d')]?_0x44cb82('0x1e21')+_0x243e79[_0x44cb82('0x52d')]+_0x44cb82('0x11e1')+_0x243e79[_0x44cb82('0xe1b')]:'USERPROFILE:GET_SECTION','msg':_0x243e79[_0x44cb82('0x52d')]?JSON[_0x44cb82('0xbac')](_0x243e79[_0x44cb82('0x25f4')]):_0x243e79[_0x44cb82('0x1586')]()});});}let _0x5ae72d=!![],_0x517017=0x1;_0x1d34a9[_0xe88c45('0xe83')]('vm.query.filter',function(_0xd6cd17,_0x240353){const _0x2439e8=_0xe88c45;_0x5ae72d?_0x2834e6(function(){_0x5ae72d=![];}):(!_0x240353&&(_0x517017=_0x1e3698['query']['page']),_0xd6cd17!==_0x240353&&(_0x1e3698[_0x2439e8('0x2218')][_0x2439e8('0x1a43')]=0x1),!_0xd6cd17&&(_0x1e3698['query'][_0x2439e8('0x1a43')]=_0x517017),_0x1e3698['getMailQueues']());});function _0x5c78e7(_0x548123){const _0x159966=_0xe88c45;_0x1e3698[_0x159966('0x273')]=_0x548123||{'count':0x0,'rows':[]};}function _0x123be3(){const _0x3549b4=_0xe88c45;_0x1e3698[_0x3549b4('0x2218')][_0x3549b4('0x1098')]=(_0x1e3698[_0x3549b4('0x2218')][_0x3549b4('0x1a43')]-0x1)*_0x1e3698['query'][_0x3549b4('0x163f')],_0x3640be[_0x3549b4('0x1ac6')](_0x3549b4('0xa7c'))?_0x1e3698[_0x3549b4('0x1f48')]=_0x4ce002['mailQueue'][_0x3549b4('0xd83')](_0x1e3698['query'],_0x5c78e7)[_0x3549b4('0xa44')]:(_0x1e3698['query']['id']=_0x1e3698[_0x3549b4('0x7f')]['id'],_0x1e3698[_0x3549b4('0x2218')][_0x3549b4('0xe60')]=_0x3549b4('0x5f8'),_0x1e3698[_0x3549b4('0x1f48')]=_0x4ce002[_0x3549b4('0x7f')][_0x3549b4('0x263a')](_0x1e3698[_0x3549b4('0x2218')],_0x5c78e7)['$promise']);}function _0x19cdf1(_0x25dfb5,_0x5e094a){const _0x25f4be=_0xe88c45;_0x2e537b['show']({'controller':'CreateOrEditMailQueueDialogController','controllerAs':'vm','templateUrl':_0x195a4f,'parent':angular['element'](_0xf859b[_0x25f4be('0x8d2')]),'targetEvent':_0x25dfb5,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x5e094a,'mailQueues':_0x1e3698[_0x25f4be('0x273')][_0x25f4be('0x269a')],'license':_0x1e3698[_0x25f4be('0x5c9')],'setting':_0x1e3698[_0x25f4be('0xf8a')],'crudPermissions':_0x1e3698[_0x25f4be('0x243c')]}});}function _0x3770df(_0x4381c5){const _0x174036=_0xe88c45;_0x4ce002[_0x174036('0x24c9')][_0x174036('0x906')]({'id':_0x4381c5['id']})[_0x174036('0xa44')][_0x174036('0x1166')](function(){const _0x584027=_0x174036;_0x2cfb05()[_0x584027('0x127f')](_0x1e3698[_0x584027('0x273')]['rows'],{'id':_0x4381c5['id']}),_0x1e3698['mailQueues']['count']-=0x1,!_0x1e3698[_0x584027('0x273')][_0x584027('0x269a')][_0x584027('0x264b')]&&_0x1e3698['getMailQueues'](),_0x4d1261[_0x584027('0x103b')]({'title':_0x2cfb05()['startCase']('MailQueue')+_0x584027('0x2b6'),'msg':_0x4381c5[_0x584027('0x4f0')]?_0x4381c5[_0x584027('0x4f0')]+_0x584027('0x7cd'):''});})[_0x174036('0x1a80')](function(_0x4226df){const _0x17c027=_0x174036;if(_0x4226df[_0x17c027('0x25f4')]&&_0x4226df[_0x17c027('0x25f4')][_0x17c027('0x61a')]&&_0x4226df[_0x17c027('0x25f4')][_0x17c027('0x61a')][_0x17c027('0x264b')]){_0x1e3698[_0x17c027('0x61a')]=_0x4226df[_0x17c027('0x25f4')]['errors']||[{'message':_0x4226df['toString'](),'type':_0x17c027('0x16e9')}];for(let _0x36e9ae=0x0;_0x36e9ae<_0x4226df['data'][_0x17c027('0x61a')][_0x17c027('0x264b')];_0x36e9ae++){_0x4d1261['error']({'title':_0x4226df[_0x17c027('0x25f4')][_0x17c027('0x61a')][_0x36e9ae]['type'],'msg':_0x4226df[_0x17c027('0x25f4')][_0x17c027('0x61a')][_0x36e9ae][_0x17c027('0x1e70')]});}}else _0x4d1261[_0x17c027('0xfc9')]({'title':_0x4226df[_0x17c027('0x52d')]?_0x17c027('0x1e21')+_0x4226df['status']+_0x17c027('0x11e1')+_0x4226df[_0x17c027('0xe1b')]:_0x17c027('0x16e9'),'msg':_0x4226df[_0x17c027('0x25f4')]?JSON[_0x17c027('0xbac')](_0x4226df[_0x17c027('0x25f4')][_0x17c027('0x1e70')]):_0x4226df[_0x17c027('0x1e70')]||_0x4226df[_0x17c027('0x1586')]()});});}function _0x13c545(){const _0x4a3bf2=_0xe88c45,_0xb1264c=angular[_0x4a3bf2('0x225f')](_0x1e3698[_0x4a3bf2('0x178')]);return _0x1e3698[_0x4a3bf2('0x178')]=[],_0xb1264c;}function _0x2fc2c1(_0x3de19f){const _0x58d4b4=_0xe88c45,_0x188516=_0x2e537b[_0x58d4b4('0x1d26')]()[_0x58d4b4('0xcdc')](_0x58d4b4('0x1c7b'))[_0x58d4b4('0xf3c')](_0x58d4b4('0x12b5')+_0x1e3698[_0x58d4b4('0x178')]['length']+_0x58d4b4('0x196d')+'\x20will\x20be\x20deleted.')[_0x58d4b4('0x8e8')](_0x58d4b4('0x2229'))[_0x58d4b4('0x203b')](_0x3de19f)['ok']('OK')[_0x58d4b4('0x3f')](_0x58d4b4('0x2d3'));_0x2e537b[_0x58d4b4('0x1f80')](_0x188516)['then'](function(){const _0x5419aa=_0x58d4b4;_0x1e3698[_0x5419aa('0x178')]['forEach'](function(_0x1a4930){_0x3770df(_0x1a4930);}),_0x1e3698[_0x5419aa('0x178')]=[];});}function _0x76be5f(){_0x1e3698['selectedMailQueues']=[];}function _0x278333(){const _0x2d9a21=_0xe88c45;_0x1e3698[_0x2d9a21('0x178')]=_0x1e3698[_0x2d9a21('0x273')]['rows'];}}const _0x1cb37c=_0x2fe32d;_0x287e64[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x16c0'),_0x36e6f4('0x1c44'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x287e64(_0x345928,_0x3a006b,_0x3f1009,_0x8a11de,_0x64e598,_0x3fbd9f,_0x1da0bd,_0x17e7b3,_0x45d0f1,_0x163d7e,_0xc09b1b,_0xfc32a8,_0x474a0c,_0x20e2e2){const _0x485c71=_0x36e6f4,_0x49e3c9=this;_0x49e3c9['currentUser']=_0xc09b1b['getCurrentUser'](),_0x49e3c9[_0x485c71('0x61a')]=[],_0x49e3c9[_0x485c71('0xf8a')]=_0x474a0c,_0x49e3c9[_0x485c71('0x5c9')]=_0xfc32a8,_0x49e3c9[_0x485c71('0x243c')]=_0x20e2e2,_0x49e3c9[_0x485c71('0x128b')]={},_0x49e3c9['passwordPattern']=_0x49e3c9[_0x485c71('0xf8a')]&&_0x49e3c9[_0x485c71('0xf8a')][_0x485c71('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x49e3c9[_0x485c71('0xcdc')]=_0x485c71('0x832'),_0x49e3c9[_0x485c71('0x1c44')]=angular[_0x485c71('0x225f')](_0x45d0f1),_0x49e3c9[_0x485c71('0x16c0')]=_0x17e7b3,_0x49e3c9[_0x485c71('0x844')]=![];!_0x49e3c9['mailSubstatus']&&(_0x49e3c9[_0x485c71('0x1c44')]={},_0x49e3c9['title']=_0x485c71('0x171d'),_0x49e3c9[_0x485c71('0x844')]=!![]);_0x49e3c9[_0x485c71('0x60b')]=_0x4d89e9,_0x49e3c9[_0x485c71('0x7fa')]=_0x6b3cd6,_0x49e3c9[_0x485c71('0x2346')]=_0x107e09,_0x49e3c9['getDateFromString']=_0x133a63,_0x49e3c9['closeDialog']=_0x937229;function _0x4d89e9(){const _0x24d229=_0x485c71;_0x49e3c9[_0x24d229('0x61a')]=[],_0x163d7e[_0x24d229('0x1c44')][_0x24d229('0x9cc')](_0x49e3c9[_0x24d229('0x1c44')])[_0x24d229('0xa44')]['then'](function(_0x2ebd4b){const _0x32368a=_0x24d229;_0x49e3c9[_0x32368a('0x16c0')][_0x32368a('0x2450')](_0x2ebd4b[_0x32368a('0x2876')]()),_0x1da0bd[_0x32368a('0x103b')]({'title':_0x32368a('0x2262'),'msg':_0x49e3c9['mailSubstatus']['name']?_0x49e3c9[_0x32368a('0x1c44')][_0x32368a('0x4f0')]+_0x32368a('0x1eda'):''}),_0x937229(_0x2ebd4b);})[_0x24d229('0x1a80')](function(_0x510eeb){const _0x5574c8=_0x24d229;if(_0x510eeb[_0x5574c8('0x25f4')]&&_0x510eeb['data'][_0x5574c8('0x61a')]&&_0x510eeb[_0x5574c8('0x25f4')][_0x5574c8('0x61a')][_0x5574c8('0x264b')]){_0x49e3c9[_0x5574c8('0x61a')]=_0x510eeb[_0x5574c8('0x25f4')][_0x5574c8('0x61a')]||[{'message':_0x510eeb[_0x5574c8('0x1586')](),'type':_0x5574c8('0x760')}];for(let _0x818b1a=0x0;_0x818b1a<_0x510eeb[_0x5574c8('0x25f4')][_0x5574c8('0x61a')][_0x5574c8('0x264b')];_0x818b1a+=0x1){_0x1da0bd[_0x5574c8('0xfc9')]({'title':_0x510eeb[_0x5574c8('0x25f4')][_0x5574c8('0x61a')][_0x818b1a][_0x5574c8('0x1345')],'msg':_0x510eeb['data'][_0x5574c8('0x61a')][_0x818b1a][_0x5574c8('0x1e70')]});}}else _0x1da0bd['error']({'title':_0x510eeb[_0x5574c8('0x52d')]?_0x5574c8('0x1e21')+_0x510eeb[_0x5574c8('0x52d')]+_0x5574c8('0x11e1')+_0x510eeb[_0x5574c8('0xe1b')]:_0x5574c8('0x760'),'msg':_0x510eeb[_0x5574c8('0x25f4')]?JSON[_0x5574c8('0xbac')](_0x510eeb[_0x5574c8('0x25f4')][_0x5574c8('0x1e70')]):_0x510eeb[_0x5574c8('0x1586')]()});});}function _0x6b3cd6(){const _0x5d82c3=_0x485c71;_0x49e3c9['errors']=[],_0x163d7e[_0x5d82c3('0x1c44')][_0x5d82c3('0x1449')]({'id':_0x49e3c9['mailSubstatus']['id']},_0x49e3c9[_0x5d82c3('0x1c44')])[_0x5d82c3('0xa44')]['then'](function(_0x2ff2c7){const _0x2b69b0=_0x5d82c3,_0x4a0f40=_0x2cfb05()[_0x2b69b0('0xc38')](_0x49e3c9[_0x2b69b0('0x16c0')],{'id':_0x2ff2c7['id']});_0x4a0f40&&_0x2cfb05()['merge'](_0x4a0f40,_0x2cfb05()[_0x2b69b0('0x1a08')](_0x2ff2c7['toJSON'](),_0x2cfb05()['keys'](_0x4a0f40))),_0x1da0bd['success']({'title':_0x2b69b0('0xf8e'),'msg':_0x49e3c9[_0x2b69b0('0x1c44')]['name']?_0x49e3c9[_0x2b69b0('0x1c44')][_0x2b69b0('0x4f0')]+_0x2b69b0('0x7d'):''}),_0x937229(_0x2ff2c7);})[_0x5d82c3('0x1a80')](function(_0x2d9acf){const _0x44efcc=_0x5d82c3;if(_0x2d9acf[_0x44efcc('0x25f4')]&&_0x2d9acf[_0x44efcc('0x25f4')]['errors']&&_0x2d9acf[_0x44efcc('0x25f4')][_0x44efcc('0x61a')][_0x44efcc('0x264b')]){_0x49e3c9['errors']=_0x2d9acf[_0x44efcc('0x25f4')][_0x44efcc('0x61a')]||[{'message':_0x2d9acf[_0x44efcc('0x1586')](),'type':_0x44efcc('0xf5e')}];for(let _0x1799fb=0x0;_0x1799fb<_0x2d9acf[_0x44efcc('0x25f4')][_0x44efcc('0x61a')][_0x44efcc('0x264b')];_0x1799fb++){_0x1da0bd['error']({'title':_0x2d9acf[_0x44efcc('0x25f4')][_0x44efcc('0x61a')][_0x1799fb]['type'],'msg':_0x2d9acf[_0x44efcc('0x25f4')][_0x44efcc('0x61a')][_0x1799fb][_0x44efcc('0x1e70')]});}}else _0x1da0bd[_0x44efcc('0xfc9')]({'title':_0x2d9acf[_0x44efcc('0x52d')]?_0x44efcc('0x1e21')+_0x2d9acf['status']+_0x44efcc('0x11e1')+_0x2d9acf[_0x44efcc('0xe1b')]:_0x44efcc('0xf5e'),'msg':_0x2d9acf[_0x44efcc('0x25f4')]?JSON[_0x44efcc('0xbac')](_0x2d9acf['data'][_0x44efcc('0x1e70')]):_0x2d9acf['toString']()});});}function _0x107e09(_0x5384e7){const _0x2edb8f=_0x485c71;_0x49e3c9['errors']=[];const _0x50518b=_0x8a11de[_0x2edb8f('0x1d26')]()[_0x2edb8f('0xcdc')]('Are\x20you\x20sure?')[_0x2edb8f('0xacc')](_0x2edb8f('0x1596'))['ariaLabel'](_0x2edb8f('0x238e'))['ok'](_0x2edb8f('0x18'))[_0x2edb8f('0x3f')]('Cancel')[_0x2edb8f('0x203b')](_0x5384e7);_0x8a11de[_0x2edb8f('0x1f80')](_0x50518b)[_0x2edb8f('0x1166')](function(){const _0x5db2b2=_0x2edb8f;_0x163d7e['mailSubstatus'][_0x5db2b2('0x906')]({'id':_0x49e3c9[_0x5db2b2('0x1c44')]['id']})[_0x5db2b2('0xa44')]['then'](function(){const _0xea0fc4=_0x5db2b2;_0x2cfb05()['remove'](_0x49e3c9[_0xea0fc4('0x16c0')],{'id':_0x49e3c9[_0xea0fc4('0x1c44')]['id']}),_0x1da0bd[_0xea0fc4('0x103b')]({'title':_0xea0fc4('0x2043'),'msg':(_0x49e3c9[_0xea0fc4('0x1c44')][_0xea0fc4('0x4f0')]||_0xea0fc4('0x1c44'))+_0xea0fc4('0x7cd')}),_0x937229(_0x49e3c9['mailSubstatus']);})[_0x5db2b2('0x1a80')](function(_0xfb1aa){const _0x192d0a=_0x5db2b2;if(_0xfb1aa[_0x192d0a('0x25f4')]&&_0xfb1aa[_0x192d0a('0x25f4')][_0x192d0a('0x61a')]&&_0xfb1aa[_0x192d0a('0x25f4')][_0x192d0a('0x61a')][_0x192d0a('0x264b')]){_0x49e3c9['errors']=_0xfb1aa[_0x192d0a('0x25f4')][_0x192d0a('0x61a')]||[{'message':_0xfb1aa[_0x192d0a('0x1586')](),'type':_0x192d0a('0x21c4')}];for(let _0x706e74=0x0;_0x706e74<_0xfb1aa[_0x192d0a('0x25f4')][_0x192d0a('0x61a')]['length'];_0x706e74++){_0x1da0bd[_0x192d0a('0xfc9')]({'title':_0xfb1aa[_0x192d0a('0x25f4')]['errors'][_0x706e74]['type'],'msg':_0xfb1aa[_0x192d0a('0x25f4')][_0x192d0a('0x61a')][_0x706e74][_0x192d0a('0x1e70')]});}}else _0x1da0bd[_0x192d0a('0xfc9')]({'title':_0xfb1aa[_0x192d0a('0x52d')]?_0x192d0a('0x1e21')+_0xfb1aa['status']+_0x192d0a('0x11e1')+_0xfb1aa[_0x192d0a('0xe1b')]:_0x192d0a('0x21c4'),'msg':_0xfb1aa[_0x192d0a('0x25f4')]?JSON[_0x192d0a('0xbac')](_0xfb1aa[_0x192d0a('0x25f4')][_0x192d0a('0x1e70')]):_0xfb1aa[_0x192d0a('0x1e70')]||_0xfb1aa['toString']()});});},function(){});}function _0x133a63(_0x2f0ae9){return _0x2f0ae9===null?undefined:new Date(_0x2f0ae9);}function _0x937229(_0x407a1b){const _0x379b5e=_0x485c71;_0x8a11de[_0x379b5e('0x1197')](_0x407a1b);}}const _0x2244bb=_0x287e64,_0x9266e1=_0x2734b2['p']+_0x36e6f4('0x17ed');_0xd9e42[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$window',_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),'$mdDialog','$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'mailSubtatuses',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0xd9e42(_0x30aa17,_0x4f577f,_0x472681,_0x3d9270,_0x490807,_0x332639,_0x18cd6c,_0x4f0455,_0x4bc4d0,_0x16da6c,_0x583a07,_0x441695,_0xab33a6,_0x4c8e19,_0x24fc0a,_0x3925b2,_0x10648d){const _0x3348c6=_0x36e6f4,_0x125a6b=this;_0x125a6b[_0x3348c6('0x5c9')]=_0x3925b2,_0x125a6b[_0x3348c6('0xf8a')]=_0x10648d,_0x125a6b[_0x3348c6('0x98')]=_0x24fc0a[_0x3348c6('0x26cd')](),_0x125a6b[_0x3348c6('0x16c0')]=_0x4bc4d0||{'count':0x0,'rows':[]},_0x125a6b[_0x3348c6('0x7f')]=_0x16da6c,_0x125a6b['userProfileSection']=_0x583a07&&_0x583a07[_0x3348c6('0x240f')]==0x1?_0x583a07[_0x3348c6('0x269a')][0x0]:null,_0x125a6b[_0x3348c6('0x243c')]=_0x24fc0a[_0x3348c6('0xd87')](_0x125a6b[_0x3348c6('0x17aa')]?_0x125a6b[_0x3348c6('0x17aa')][_0x3348c6('0x243c')]:null),_0x125a6b[_0x3348c6('0x916')]='mailSubtatuses',_0x125a6b[_0x3348c6('0xef5')]='',_0x125a6b[_0x3348c6('0x104c')]=null,_0x125a6b[_0x3348c6('0x525')]=[],_0x125a6b[_0x3348c6('0x2218')]={'fields':_0x3348c6('0x208e'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x125a6b[_0x3348c6('0x1f8e')]=_0x3d7c93,_0x125a6b[_0x3348c6('0x8d8')]=_0x551f45,_0x125a6b[_0x3348c6('0x103b')]=_0x3f9660,_0x125a6b['getMailSubstatuses']=_0x43e8a2,_0x125a6b[_0x3348c6('0x91')]=_0x2ae703,_0x125a6b[_0x3348c6('0x2346')]=_0x2fdb01,_0x125a6b[_0x3348c6('0xfc7')]=_0x33be2e,_0x125a6b[_0x3348c6('0xfe4')]=_0x341e64,_0x125a6b[_0x3348c6('0x2721')]=_0x1d94e0,_0x125a6b['selectAllMailSubstatuses']=_0x3603b6;function _0x3d7c93(_0x1eb125,_0x339c4f){const _0x2da2ed=_0x3348c6;_0x490807['show']({'controller':_0x2da2ed('0xf31'),'controllerAs':'vm','templateUrl':_0x9266e1,'parent':angular[_0x2da2ed('0x1194')](_0x332639['body']),'targetEvent':_0x339c4f,'clickOutsideToClose':!![],'locals':{'mailSubstatus':_0x1eb125,'mailSubtatuses':_0x125a6b[_0x2da2ed('0x16c0')][_0x2da2ed('0x269a')],'license':_0x125a6b[_0x2da2ed('0x5c9')],'setting':null,'crudPermissions':_0x125a6b['crudPermissions']}});}function _0x551f45(_0x2eee13,_0x24140d){const _0x287978=_0x3348c6,_0x274832=_0x490807['confirm']()[_0x287978('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x287978('0xb35')](_0x287978('0x1c44'))+'?')[_0x287978('0xf3c')](''+(_0x2eee13[_0x287978('0x4f0')]||'mailSubstatus')+_0x287978('0xace')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x287978('0x65b'))[_0x287978('0x203b')](_0x24140d)['ok']('OK')[_0x287978('0x3f')](_0x287978('0x2d3'));_0x490807['show'](_0x274832)[_0x287978('0x1166')](function(){_0x2fdb01(_0x2eee13);},function(){const _0x5eab43=_0x287978;console[_0x5eab43('0x455')](_0x5eab43('0x2d3'));});}let _0x4d25f1=!![],_0x1487d7=0x1;_0x30aa17['$watch'](_0x3348c6('0x12d8'),function(_0x2e979b,_0x587bc1){const _0x30ba10=_0x3348c6;_0x4d25f1?_0x18cd6c(function(){_0x4d25f1=![];}):(!_0x587bc1&&(_0x1487d7=_0x125a6b[_0x30ba10('0x2218')][_0x30ba10('0x1a43')]),_0x2e979b!==_0x587bc1&&(_0x125a6b[_0x30ba10('0x2218')][_0x30ba10('0x1a43')]=0x1),!_0x2e979b&&(_0x125a6b[_0x30ba10('0x2218')][_0x30ba10('0x1a43')]=_0x1487d7),_0x125a6b[_0x30ba10('0x2804')]());});function _0x3f9660(_0x5d53cc){const _0xed9573=_0x3348c6;_0x125a6b[_0xed9573('0x16c0')]=_0x5d53cc||{'count':0x0,'rows':[]};}function _0x43e8a2(){const _0x1b510c=_0x3348c6;_0x125a6b[_0x1b510c('0x2218')][_0x1b510c('0x1098')]=(_0x125a6b[_0x1b510c('0x2218')][_0x1b510c('0x1a43')]-0x1)*_0x125a6b[_0x1b510c('0x2218')][_0x1b510c('0x163f')],_0x24fc0a[_0x1b510c('0x1ac6')]('admin')?_0x125a6b['promise']=_0x441695[_0x1b510c('0x1c44')][_0x1b510c('0xd83')](_0x125a6b['query'],_0x3f9660)[_0x1b510c('0xa44')]:(_0x125a6b['query']['id']=_0x125a6b[_0x1b510c('0x7f')]['id'],_0x125a6b[_0x1b510c('0x2218')][_0x1b510c('0xe60')]=_0x1b510c('0xd68'),_0x125a6b['promise']=_0x441695[_0x1b510c('0x7f')][_0x1b510c('0x263a')](_0x125a6b['query'],_0x3f9660)[_0x1b510c('0xa44')]);}function _0x2ae703(_0x2f3a75,_0x4d22f7){const _0x9c006b=_0x3348c6;_0x490807[_0x9c006b('0x1f80')]({'controller':_0x9c006b('0xf31'),'controllerAs':'vm','templateUrl':_0x9266e1,'parent':angular[_0x9c006b('0x1194')](_0x332639[_0x9c006b('0x8d2')]),'targetEvent':_0x2f3a75,'clickOutsideToClose':!![],'locals':{'mailSubstatus':_0x4d22f7,'mailSubtatuses':_0x125a6b[_0x9c006b('0x16c0')][_0x9c006b('0x269a')],'license':_0x125a6b[_0x9c006b('0x5c9')],'setting':_0x125a6b[_0x9c006b('0xf8a')],'crudPermissions':_0x125a6b[_0x9c006b('0x243c')]}});}function _0x2fdb01(_0x4610df){const _0x48661d=_0x3348c6;_0x441695[_0x48661d('0x1c44')][_0x48661d('0x906')]({'id':_0x4610df['id']})[_0x48661d('0xa44')][_0x48661d('0x1166')](function(){const _0x128ba3=_0x48661d;_0x2cfb05()[_0x128ba3('0x127f')](_0x125a6b[_0x128ba3('0x16c0')][_0x128ba3('0x269a')],{'id':_0x4610df['id']}),_0x125a6b[_0x128ba3('0x16c0')]['count']-=0x1,!_0x125a6b[_0x128ba3('0x16c0')][_0x128ba3('0x269a')]['length']&&_0x125a6b[_0x128ba3('0x2804')](),_0x4c8e19[_0x128ba3('0x103b')]({'title':_0x2cfb05()['startCase']('MailSubstatus')+_0x128ba3('0x2b6'),'msg':_0x4610df[_0x128ba3('0x4f0')]?_0x4610df[_0x128ba3('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0x48661d('0x1a80')](function(_0x5314fd){const _0x4673db=_0x48661d;if(_0x5314fd[_0x4673db('0x25f4')]&&_0x5314fd[_0x4673db('0x25f4')][_0x4673db('0x61a')]&&_0x5314fd[_0x4673db('0x25f4')]['errors']['length']){_0x125a6b[_0x4673db('0x61a')]=_0x5314fd['data'][_0x4673db('0x61a')]||[{'message':_0x5314fd[_0x4673db('0x1586')](),'type':_0x4673db('0x1cb')}];for(let _0x525075=0x0;_0x525075<_0x5314fd['data'][_0x4673db('0x61a')][_0x4673db('0x264b')];_0x525075++){_0x4c8e19['error']({'title':_0x5314fd[_0x4673db('0x25f4')][_0x4673db('0x61a')][_0x525075][_0x4673db('0x1345')],'msg':_0x5314fd['data'][_0x4673db('0x61a')][_0x525075]['message']});}}else _0x4c8e19['error']({'title':_0x5314fd['status']?'API:'+_0x5314fd['status']+_0x4673db('0x11e1')+_0x5314fd[_0x4673db('0xe1b')]:_0x4673db('0x1cb'),'msg':_0x5314fd[_0x4673db('0x25f4')]?JSON[_0x4673db('0xbac')](_0x5314fd['data']['message']):_0x5314fd[_0x4673db('0x1e70')]||_0x5314fd[_0x4673db('0x1586')]()});});}function _0x33be2e(){const _0x506a99=_0x3348c6,_0x7cd4cd=angular[_0x506a99('0x225f')](_0x125a6b['selectedMailSubstatuses']);return _0x125a6b[_0x506a99('0x525')]=[],_0x7cd4cd;}function _0x341e64(_0x40e063){const _0x3c5052=_0x3348c6,_0x3ccfac=_0x490807['confirm']()[_0x3c5052('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20mailSubtatuses?')['htmlContent'](_0x3c5052('0x12b5')+_0x125a6b[_0x3c5052('0x525')][_0x3c5052('0x264b')]+_0x3c5052('0x196d')+_0x3c5052('0x3f3'))[_0x3c5052('0x8e8')](_0x3c5052('0x1180'))[_0x3c5052('0x203b')](_0x40e063)['ok']('OK')[_0x3c5052('0x3f')]('CANCEL');_0x490807['show'](_0x3ccfac)[_0x3c5052('0x1166')](function(){const _0x1a8711=_0x3c5052;_0x125a6b[_0x1a8711('0x525')][_0x1a8711('0x2782')](function(_0x454c50){_0x2fdb01(_0x454c50);}),_0x125a6b[_0x1a8711('0x525')]=[];});}function _0x1d94e0(){_0x125a6b['selectedMailSubstatuses']=[];}function _0x3603b6(){const _0x4d587d=_0x3348c6;_0x125a6b[_0x4d587d('0x525')]=_0x125a6b[_0x4d587d('0x16c0')][_0x4d587d('0x269a')];}}const _0x31c0f5=_0xd9e42;_0x1ac590[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x1ac590(_0x59bd64,_0x14dbf2){const _0x2b8d38=_0x36e6f4;_0x59bd64[_0x2b8d38('0x63f')](_0x2b8d38('0x1e3'),{'abstract':!![],'url':_0x2b8d38('0x213c')})['state']('app.mail.mailQueues',{'url':'/mailQueues','views':{'content@app':{'templateUrl':_0x4054c8,'controller':_0x2b8d38('0x209f')}},'resolve':{'mailQueues':[_0x2b8d38('0x1fbc'),_0x2b8d38('0x21ef'),function(_0x5aa38e,_0x29910a){const _0x5384dc=_0x2b8d38;return _0x29910a[_0x5384dc('0x1ac6')](_0x5384dc('0xa7c'))?_0x5aa38e['resolve']('mailQueue@get',{'fields':_0x5384dc('0xf26'),'sort':'-updatedAt','channel':_0x5384dc('0x1bfa'),'limit':0xa,'offset':0x0}):_0x5aa38e['resolve'](_0x5384dc('0x17c4'),{'id':_0x29910a[_0x5384dc('0x26cd')]()[_0x5384dc('0xb86')],'section':_0x5384dc('0x5f8'),'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','sort':'-updatedAt','channel':'mail','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x2b8d38('0x21ef'),function(_0x569f34,_0x8e220e){const _0x104dfe=_0x2b8d38;return _0x8e220e[_0x104dfe('0x1ac6')](_0x104dfe('0xa7c'))?null:_0x569f34[_0x104dfe('0x18af')](_0x104dfe('0x697'),{'fields':_0x104dfe('0x686'),'id':_0x8e220e['getCurrentUser']()[_0x104dfe('0xb86')]});}],'userProfileSection':[_0x2b8d38('0x1fbc'),_0x2b8d38('0x21ef'),function(_0x54059f,_0x340680){const _0x36fd32=_0x2b8d38;return _0x340680[_0x36fd32('0x1ac6')](_0x36fd32('0xa7c'))?null:_0x54059f['resolve']('userProfileSection@get',{'fields':_0x36fd32('0xe26'),'userProfileId':_0x340680['getCurrentUser']()[_0x36fd32('0xb86')],'sectionId':0x259});}]},'authenticate':!![],'permissionId':0x259,'bodyClass':_0x2b8d38('0x1bfa')})[_0x2b8d38('0x63f')](_0x2b8d38('0x23e0'),{'url':_0x2b8d38('0x2233'),'params':{'mailQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x4ffa96,'controller':_0x2b8d38('0x1ce6')}},'resolve':{'mailQueue':[_0x2b8d38('0x1fbc'),_0x2b8d38('0xf75'),function(_0x482fcc,_0x34746e){const _0x26f355=_0x2b8d38;return _0x482fcc['resolve'](_0x26f355('0x13fe'),{'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','id':_0x34746e['id']});}],'userProfileSection':['apiResolver',_0x2b8d38('0x21ef'),function(_0x26e89d,_0x50c9fc){const _0x347ca0=_0x2b8d38;return _0x26e89d[_0x347ca0('0x18af')](_0x347ca0('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x50c9fc[_0x347ca0('0x26cd')]()['userProfileId'],'sectionId':0x259});}]},'authenticate':!![],'permissionId':0x259,'bodyClass':'mail'})[_0x2b8d38('0x63f')](_0x2b8d38('0xc81'),{'url':_0x2b8d38('0xf0c'),'views':{'content@app':{'templateUrl':_0xb5260d,'controller':_0x2b8d38('0x24b5')}},'resolve':{'mailAccounts':[_0x2b8d38('0x1fbc'),'Auth',function(_0x178783,_0x69d873){const _0x3baaff=_0x2b8d38;return _0x69d873[_0x3baaff('0x1ac6')]('admin')?_0x178783[_0x3baaff('0x18af')](_0x3baaff('0x1d62'),{'fields':_0x3baaff('0xb5d'),'sort':_0x3baaff('0x14dc'),'limit':0xa,'offset':0x0}):_0x178783[_0x3baaff('0x18af')](_0x3baaff('0x17c4'),{'id':_0x69d873[_0x3baaff('0x26cd')]()[_0x3baaff('0xb86')],'section':'MailAccounts','fields':_0x3baaff('0xb5d'),'sort':_0x3baaff('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver','Auth',function(_0x91c552,_0x5ddc28){const _0x39b193=_0x2b8d38;return _0x5ddc28['hasRole'](_0x39b193('0xa7c'))?null:_0x91c552['resolve'](_0x39b193('0x697'),{'fields':_0x39b193('0x686'),'id':_0x5ddc28[_0x39b193('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x2b8d38('0x1fbc'),_0x2b8d38('0x21ef'),function(_0x2b67ef,_0x1fdca9){const _0x5dffdd=_0x2b8d38;return _0x1fdca9[_0x5dffdd('0x1ac6')](_0x5dffdd('0xa7c'))?null:_0x2b67ef[_0x5dffdd('0x18af')](_0x5dffdd('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x1fdca9[_0x5dffdd('0x26cd')]()['userProfileId'],'sectionId':0x25a});}]},'authenticate':!![],'permissionId':0x25a,'bodyClass':'mail'})[_0x2b8d38('0x63f')](_0x2b8d38('0x9bf'),{'url':'/:id?tab','params':{'mailAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x217418,'controller':'MailAccountController\x20as\x20vm'}},'resolve':{'mailAccount':['apiResolver',_0x2b8d38('0xf75'),function(_0x55d732,_0x35ddba){const _0x25ec8e=_0x2b8d38;return _0x55d732[_0x25ec8e('0x18af')](_0x25ec8e('0x1d62'),{'fields':_0x25ec8e('0xb5d'),'id':_0x35ddba['id']});}],'userProfileSection':[_0x2b8d38('0x1fbc'),_0x2b8d38('0x21ef'),function(_0x5a88dc,_0x20b4d6){const _0x114621=_0x2b8d38;return _0x5a88dc[_0x114621('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x20b4d6[_0x114621('0x26cd')]()[_0x114621('0xb86')],'sectionId':0x25a});}]},'authenticate':!![],'permissionId':0x25a,'bodyClass':_0x2b8d38('0x1bfa')})[_0x2b8d38('0x63f')](_0x2b8d38('0x2618'),{'url':_0x2b8d38('0x25e'),'views':{'content@app':{'templateUrl':_0xcb7532,'controller':_0x2b8d38('0x26f1')}},'resolve':{'mailSubtatuses':[_0x2b8d38('0x1fbc'),function(_0x2a0eff){const _0x2f6348=_0x2b8d38;return _0x2a0eff[_0x2f6348('0x18af')](_0x2f6348('0x95'),{'fields':_0x2f6348('0x208e'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x2b8d38('0x21ef'),function(_0x39430e,_0x1369c8){const _0x543a25=_0x2b8d38;return _0x1369c8[_0x543a25('0x1ac6')](_0x543a25('0xa7c'))?null:_0x39430e[_0x543a25('0x18af')](_0x543a25('0x697'),{'fields':'id,name,crudPermissions','id':_0x1369c8[_0x543a25('0x26cd')]()[_0x543a25('0xb86')]});}],'userProfileSection':['apiResolver',_0x2b8d38('0x21ef'),function(_0x5f16b0,_0x25d927){const _0x20e007=_0x2b8d38;return _0x25d927['hasRole']('admin')?null:_0x5f16b0[_0x20e007('0x18af')](_0x20e007('0xaf'),{'fields':_0x20e007('0xe26'),'userProfileId':_0x25d927[_0x20e007('0x26cd')]()['userProfileId'],'sectionId':0x25b});}]},'authenticate':!![],'permissionId':0x25b,'bodyClass':_0x2b8d38('0x1bfa')}),_0x14dbf2[_0x2b8d38('0x95e')](_0x2b8d38('0x572'));}angular[_0x36e6f4('0x896')](_0x36e6f4('0x1e3'),[_0x36e6f4('0x441'),'ngPassword',_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),'mdColorPicker',_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),'ngAria',_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),'angular.filter',_0x36e6f4('0x26ba')])[_0x36e6f4('0xe11')](_0x1ac590)['controller']('CreateOrEditMailAccountDialogController',_0x311577)[_0x36e6f4('0x75e')]('MailAccountActionsController',_0x4863a3)[_0x36e6f4('0x75e')](_0x36e6f4('0x2729'),_0x5aa946)[_0x36e6f4('0x75e')](_0x36e6f4('0x952'),_0x23fea9)[_0x36e6f4('0x75e')]('EditMailAccountAppautoreplyDialogController',_0x41d5b3)['controller']('EditMailAccountAppcloseDialogController',_0x38e0c5)[_0x36e6f4('0x75e')](_0x36e6f4('0x26e6'),_0x32d432)[_0x36e6f4('0x75e')](_0x36e6f4('0xdcf'),_0xf53356)['controller'](_0x36e6f4('0xe56'),_0x19be60)[_0x36e6f4('0x75e')]('EditMailAccountAppnoopDialogController',_0x460a5c)[_0x36e6f4('0x75e')]('EditMailAccountAppqueueDialogController',_0x25c598)[_0x36e6f4('0x75e')](_0x36e6f4('0xb97'),_0x38d79f)[_0x36e6f4('0x75e')](_0x36e6f4('0x27fc'),_0x20ea16)[_0x36e6f4('0x75e')](_0x36e6f4('0x285f'),_0x2d614d)[_0x36e6f4('0x75e')](_0x36e6f4('0x437'),_0x1a41f2)[_0x36e6f4('0x75e')](_0x36e6f4('0x12ad'),_0x126cee)[_0x36e6f4('0x75e')](_0x36e6f4('0x90'),_0x5c007f)[_0x36e6f4('0x75e')](_0x36e6f4('0xd44'),_0x1b534e)[_0x36e6f4('0x75e')](_0x36e6f4('0x10cc'),_0x12826b)[_0x36e6f4('0x75e')](_0x36e6f4('0xc1c'),_0x51d507)[_0x36e6f4('0x75e')](_0x36e6f4('0x4f6'),_0x232949)[_0x36e6f4('0x75e')]('MailQueueteamaddController',_0x4e3baa)[_0x36e6f4('0x75e')](_0x36e6f4('0x245'),_0x306581)[_0x36e6f4('0x75e')](_0x36e6f4('0x1382'),_0x1cb37c)[_0x36e6f4('0x75e')]('CreateOrEditMailSubstatusDialogController',_0x2244bb)[_0x36e6f4('0x75e')](_0x36e6f4('0x2779'),_0x31c0f5);const _0x2a9387=_0x2734b2['p']+_0x36e6f4('0x44d'),_0x1fd43a=_0x2734b2['p']+_0x36e6f4('0x4fb'),_0x22fcb7=_0x2734b2['p']+'src/js/modules/main/apps/sms/views/realtime/queues/view.html/view.html';_0x6ab97c['$inject']=[_0x36e6f4('0x36f'),'$q','$timeout',_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x18bc'),_0x36e6f4('0xe29'),_0x36e6f4('0x1f7e'),_0x36e6f4('0x24b7'),_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1a02'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0x10eb')];function _0x6ab97c(_0x3ced56,_0x3092c8,_0x367598,_0x61861c,_0x261495,_0x2c9147,_0x421fb6,_0x3f1eb7,_0x1f53c7,_0x78df2b,_0x11d55a,_0x4aea4b,_0x359ce2,_0x5437c4,_0x1c44f0,_0x14f843,_0x547f8c,_0x9a2732){const _0x15c10c=_0x36e6f4,_0x11c992=this,_0x4fcad6=[_0x15c10c('0x1a82'),_0x15c10c('0xb41'),_0x15c10c('0x2318'),_0x15c10c('0x3dc'),'pauseType',_0x15c10c('0x3dc'),_0x15c10c('0x1eef'),_0x15c10c('0x16a6'),_0x15c10c('0x1c5c'),_0x15c10c('0x287f'),_0x15c10c('0xb4'),_0x15c10c('0x178d'),_0x15c10c('0x11ee'),_0x15c10c('0x5aa'),_0x15c10c('0x2540'),_0x15c10c('0x6a8'),'openchannelCapacity',_0x15c10c('0x18ae'),_0x15c10c('0x2627'),'whatsappCapacity','faxCapacity','chatCurrentCapacity',_0x15c10c('0x8cf'),_0x15c10c('0x82d'),_0x15c10c('0x1da1'),'whatsappCurrentCapacity','faxCurrentCapacity',_0x15c10c('0x840'),_0x15c10c('0x1f33'),_0x15c10c('0x25d8'),_0x15c10c('0x1c1a'),'whatsappStatus',_0x15c10c('0x276d'),_0x15c10c('0x17e1'),_0x15c10c('0x1507'),'openchannelStatusTime','mailStatusTime',_0x15c10c('0x2357'),_0x15c10c('0x11a8'),'faxStatusTime',_0x15c10c('0x18c9'),_0x15c10c('0x1d3e'),'destconnectedlinenum',_0x15c10c('0x158'),'phoneBarEnableScreenRecordingByAgent',_0x15c10c('0x1c5b')],_0x15f4f9=[_0x15c10c('0x1c5c'),_0x15c10c('0x287f'),_0x15c10c('0xb4'),_0x15c10c('0x178d'),'whatsappPause',_0x15c10c('0x5aa'),_0x15c10c('0x2540'),_0x15c10c('0xb41')];_0x11c992[_0x15c10c('0x98')]=_0x14f843[_0x15c10c('0x26cd')](),_0x11c992[_0x15c10c('0xcdd')]=[_0x15c10c('0x1628'),_0x15c10c('0x133e'),'busy','onhold',_0x15c10c('0x521')],_0x11c992[_0x15c10c('0xe29')]=_0x421fb6||{'count':0x0,'rows':[]},_0x11c992[_0x15c10c('0x5c9')]=_0x547f8c,_0x11c992['userProfile']=_0x5437c4,_0x11c992['userProfileSection']=_0x1c44f0&&_0x1c44f0[_0x15c10c('0x240f')]==0x1?_0x1c44f0['rows'][0x0]:null,_0x11c992[_0x15c10c('0x243c')]=_0x14f843['parseCrudPermissions'](_0x11c992[_0x15c10c('0x17aa')]?_0x11c992[_0x15c10c('0x17aa')][_0x15c10c('0x243c')]:null),_0x11c992[_0x15c10c('0x1f7e')]=_0x3f1eb7?_0x2cfb05()[_0x15c10c('0x155c')](_0x3f1eb7['rows']?_0x3f1eb7[_0x15c10c('0x269a')]:[],'id'):{},_0x11c992[_0x15c10c('0x24b7')]=_0x1f53c7?_0x2cfb05()[_0x15c10c('0x155c')](_0x1f53c7[_0x15c10c('0x269a')]?_0x1f53c7[_0x15c10c('0x269a')]:[],'id'):{},_0x11c992[_0x15c10c('0x5e5')]={},_0x11c992[_0x15c10c('0x173f')]=![],_0x11c992[_0x15c10c('0xa99')]=[],_0x11c992[_0x15c10c('0x4c4')]={};for(const _0x10758f in _0x11c992[_0x15c10c('0x1f7e')]){typeof _0x11c992[_0x15c10c('0x1f7e')][_0x10758f]!==_0x15c10c('0x1048')&&(_0x11c992[_0x15c10c('0x1f7e')][_0x10758f][_0x15c10c('0x24d5')]=!![]);}_0x11c992[_0x15c10c('0x2218')]={'limit':0xa,'page':0x1,'order':_0x15c10c('0x6e1'),'globalStatusFilter':'','pauseTypeFilter':''},_0x11c992[_0x15c10c('0x885')]=_0xaba0fb,_0x11c992[_0x15c10c('0xaf7')]=_0x1931ae,_0x11c992[_0x15c10c('0x1e77')]=_0x5203b1,_0x11c992[_0x15c10c('0xecc')]=_0x593a02,_0x11c992[_0x15c10c('0x6df')]=_0x155692,_0x11c992[_0x15c10c('0x72f')]=_0x121093,_0x11c992[_0x15c10c('0x28b5')]=_0x37f326,_0x11c992[_0x15c10c('0x882')]=_0x108a68,_0x11c992[_0x15c10c('0x5ad')]=_0x433e8,_0x11c992[_0x15c10c('0xb02')]=_0x2a53d2,_0x11c992[_0x15c10c('0x1303')]=_0x438c92,_0x11c992[_0x15c10c('0x2232')]=_0x2f2699,_0x11c992[_0x15c10c('0xae0')]=_0x59d2dd,_0x11c992['onConnect']=_0x1f39e8,_0x11c992[_0x15c10c('0x1923')]=_0x9bfe93,_0x11c992[_0x15c10c('0x2845')]=_0x16a195,_0x11d55a['on'](_0x15c10c('0x26b2'),_0x11c992[_0x15c10c('0x1303')]),_0x11d55a['on']('user:update',_0x11c992['onUpdate']),_0x11d55a['on'](_0x15c10c('0x10fc'),_0x11c992[_0x15c10c('0x223a')]),_0x11d55a['on']('user:agentcomplete',_0x11c992[_0x15c10c('0x1923')]),_0x59d2dd();let _0x1209d2=_0x9a2732(function(){const _0x13e243=_0x15c10c;_0x11c992[_0x13e243('0x173f')]&&(_0x11c992['load']=![],_0x59d2dd());},0x3e7);function _0x59d2dd(){const _0x22cb7f=_0x15c10c;_0x11c992[_0x22cb7f('0x173f')]=![];const _0x5b2129=_0x3092c8[_0x22cb7f('0x24d8')]();_0x11c992['promise']=_0x5b2129[_0x22cb7f('0x1f48')],_0x11c992[_0x22cb7f('0x220b')]=[],_0x11c992[_0x22cb7f('0xa99')]=[],_0x2cfb05()[_0x22cb7f('0x941')](_0x11c992[_0x22cb7f('0x1f7e')],function(_0x46a92c,_0x438b21){const _0x1077af=_0x22cb7f;_0x11c992['rpcAgents'][_0x438b21]&&_0x2cfb05()[_0x1077af('0xcc3')](_0x46a92c,_0x2cfb05()[_0x1077af('0x1a08')](_0x2cfb05()[_0x1077af('0x1414')](_0x11c992[_0x1077af('0x24b7')][_0x438b21],_0x15f4f9),_0x4fcad6)),_0x37f326(_0x46a92c),_0x46a92c[_0x1077af('0xb41')]?(_0x11c992[_0x1077af('0x220b')][_0x1077af('0x1514')](_0x46a92c),_0x11c992[_0x1077af('0x4c4')][_0x46a92c[_0x1077af('0x1eef')]]=_0x438b21):_0x46a92c['globalStatusTime']=_0x2cfb05()[_0x1077af('0xa53')](_0x24273b()()[_0x1077af('0x128a')]('x'));});_0x11c992[_0x22cb7f('0x2218')][_0x22cb7f('0xf4')]&&_0x2cfb05()[_0x22cb7f('0x127f')](_0x11c992[_0x22cb7f('0x220b')],function(_0x58d14c){const _0x882e5e=_0x22cb7f;return _0x58d14c[_0x882e5e('0xe34')]!==_0x11c992[_0x882e5e('0x2218')][_0x882e5e('0xf4')];});_0x11c992[_0x22cb7f('0x2218')][_0x22cb7f('0x2121')]&&_0x2cfb05()[_0x22cb7f('0x127f')](_0x11c992[_0x22cb7f('0x220b')],function(_0x17351d){const _0x3b6be4=_0x22cb7f;return _0x17351d['pauseType']!==_0x11c992[_0x3b6be4('0x2218')][_0x3b6be4('0x2121')];});_0x11c992[_0x22cb7f('0x2218')][_0x22cb7f('0x1c33')]&&_0x2cfb05()[_0x22cb7f('0x127f')](_0x11c992[_0x22cb7f('0x220b')],function(_0x2affd0){const _0x48a0cc=_0x22cb7f;return _0x2affd0[_0x48a0cc('0x6e1')][_0x48a0cc('0x2574')]()[_0x48a0cc('0x2379')](_0x11c992['query']['filter'][_0x48a0cc('0x2574')]())<0x0;});_0x11c992[_0x22cb7f('0x220b')]=_0x3905b3(_0x11c992[_0x22cb7f('0x220b')]);const _0x373e00=(_0x11c992['query'][_0x22cb7f('0x1a43')]-0x1)*_0x11c992[_0x22cb7f('0x2218')][_0x22cb7f('0x163f')];_0x11c992['paginatedAgents']=_0x2cfb05()[_0x22cb7f('0x3e5')](_0x11c992[_0x22cb7f('0x220b')],_0x373e00)[_0x22cb7f('0x233')](0x0,_0x11c992[_0x22cb7f('0x2218')][_0x22cb7f('0x163f')]);for(let _0x51c7a4=0x0;_0x51c7a4<_0x11c992[_0x22cb7f('0x5e5')][_0x22cb7f('0x264b')];_0x51c7a4+=0x1){_0x11c992[_0x22cb7f('0xa99')][_0x22cb7f('0x1514')](_0x11c992[_0x22cb7f('0x5e5')][_0x51c7a4]['id']);}_0x5b2129[_0x22cb7f('0x18af')](),_0x11c992[_0x22cb7f('0x173f')]=!![];}function _0x438c92(_0x53af0b){const _0x1f8fa1=_0x15c10c;_0x11c992['agents'][_0x53af0b['id']]&&(_0x2cfb05()[_0x1f8fa1('0xcc3')](_0x11c992[_0x1f8fa1('0x1f7e')][_0x53af0b['id']],_0x2cfb05()['pick'](_0x2cfb05()[_0x1f8fa1('0x1414')](_0x53af0b,_0x15f4f9),_0x4fcad6)),_0x2cfb05()[_0x1f8fa1('0xcc3')](_0x11c992[_0x1f8fa1('0x24b7')][_0x53af0b['id']],_0x2cfb05()[_0x1f8fa1('0x1a08')](_0x2cfb05()[_0x1f8fa1('0x1414')](_0x53af0b,_0x15f4f9),_0x4fcad6)),_0x37f326(_0x11c992[_0x1f8fa1('0x1f7e')][_0x53af0b['id']]));}function _0x2f2699(_0xafda5f){const _0x522334=_0x15c10c;_0x11c992[_0x522334('0x1f7e')][_0xafda5f['id']]&&(_0x2cfb05()[_0x522334('0xcc3')](_0x11c992[_0x522334('0x1f7e')][_0xafda5f['id']],_0x2cfb05()[_0x522334('0x1a08')](_0xafda5f,_0x4fcad6)),_0x2cfb05()[_0x522334('0xcc3')](_0x11c992[_0x522334('0x24b7')][_0xafda5f['id']],_0x2cfb05()[_0x522334('0x1a08')](_0xafda5f,_0x4fcad6)),_0xafda5f[_0x522334('0x3dc')]&&(_0x11c992[_0x522334('0x1f7e')][_0xafda5f['id']][_0x522334('0x25b3')]=_0xafda5f[_0x522334('0x3dc')],_0x11c992[_0x522334('0x24b7')][_0xafda5f['id']][_0x522334('0x25b3')]=_0xafda5f[_0x522334('0x3dc')]),_0x37f326(_0x11c992[_0x522334('0x1f7e')][_0xafda5f['id']]));}function _0x1f39e8(_0x130936){const _0x3245eb=_0x15c10c;_0x11c992[_0x3245eb('0x1f7e')][_0x11c992['agentInternal'][_0x130936[_0x3245eb('0x25fc')]]]&&(_0x2cfb05()[_0x3245eb('0xcc3')](_0x11c992[_0x3245eb('0x1f7e')][_0x11c992[_0x3245eb('0x4c4')][_0x130936[_0x3245eb('0x25fc')]]],_0x2cfb05()['pick'](_0x130936,[_0x3245eb('0x1d3e'),_0x3245eb('0x1ad2')])),_0x2cfb05()[_0x3245eb('0xcc3')](_0x11c992[_0x3245eb('0x24b7')][_0x11c992[_0x3245eb('0x4c4')][_0x130936[_0x3245eb('0x25fc')]]],_0x2cfb05()[_0x3245eb('0x1a08')](_0x130936,[_0x3245eb('0x1d3e'),_0x3245eb('0x1ad2')])));}function _0x9bfe93(_0x5e7526){const _0x280812=_0x15c10c;_0x11c992[_0x280812('0x1f7e')][_0x11c992[_0x280812('0x4c4')][_0x5e7526[_0x280812('0x25fc')]]]&&(_0x11c992['agents'][_0x11c992[_0x280812('0x4c4')][_0x5e7526[_0x280812('0x25fc')]]]=_0x2cfb05()[_0x280812('0x1414')](_0x11c992[_0x280812('0x1f7e')][_0x11c992[_0x280812('0x4c4')][_0x5e7526[_0x280812('0x25fc')]]],[_0x280812('0x1d3e'),_0x280812('0x1ad2')]),_0x11c992[_0x280812('0x24b7')][_0x11c992['agentInternal'][_0x5e7526[_0x280812('0x25fc')]]]=_0x2cfb05()[_0x280812('0x1414')](_0x11c992['rpcAgents'][_0x11c992['agentInternal'][_0x5e7526['destaccountcode']]],[_0x280812('0x1d3e'),'destconnectedlinenum']));}function _0xaba0fb(_0x4c2f72){const _0x35017d=_0x15c10c;return _0x78df2b['user']['logout']({'id':_0x4c2f72['id'],'device':_0x35017d('0xf01'),'agent_id':_0x4c2f72['id'],'agent_name':_0x4c2f72[_0x35017d('0x4f0')]})[_0x35017d('0xa44')]['then'](function(){const _0x26bdf=_0x35017d;_0x4aea4b[_0x26bdf('0x103b')]({'title':_0x26bdf('0x16a7'),'msg':_0x4c2f72[_0x26bdf('0x6e1')]+'\x20\x20properly\x20logout'}),_0x11c992[_0x26bdf('0x1f7e')][_0x4c2f72['id']]&&(_0x11c992[_0x26bdf('0x1f7e')][_0x4c2f72['id']][_0x26bdf('0xb41')]=![]),_0x11c992[_0x26bdf('0x24b7')][_0x4c2f72['id']]&&(_0x11c992[_0x26bdf('0x24b7')][_0x4c2f72['id']][_0x26bdf('0xb41')]=![]),_0x59d2dd();})[_0x35017d('0x1a80')](function(_0x761b1c){const _0x4ed4e8=_0x35017d;_0x4aea4b[_0x4ed4e8('0xfc9')]({'title':_0x761b1c[_0x4ed4e8('0x52d')]?_0x4ed4e8('0x1e21')+_0x761b1c[_0x4ed4e8('0x52d')]+'\x20-\x20'+_0x761b1c['statusText']:_0x4ed4e8('0x1e3c'),'msg':_0x761b1c[_0x4ed4e8('0x25f4')]?JSON[_0x4ed4e8('0xbac')](_0x761b1c[_0x4ed4e8('0x25f4')]['message']):_0x761b1c['toString']()});});}function _0x5203b1(_0xa7fdac,_0x9f9abc){const _0x1635b1=_0x15c10c;return _0x78df2b[_0x1635b1('0x557')][_0x1635b1('0x1e77')]({'id':_0xa7fdac['id'],'type':_0x9f9abc})[_0x1635b1('0xa44')][_0x1635b1('0x1166')](function(_0x4ab632){const _0x377385=_0x1635b1;_0x11c992[_0x377385('0x1f7e')][_0xa7fdac['id']]&&_0x2cfb05()[_0x377385('0xcc3')](_0x11c992[_0x377385('0x1f7e')][_0xa7fdac['id']],_0x2cfb05()[_0x377385('0x1a08')](_0x4ab632,_0x4fcad6)),_0x11c992['rpcAgents'][_0xa7fdac['id']]&&_0x2cfb05()[_0x377385('0xcc3')](_0x11c992[_0x377385('0x24b7')][_0xa7fdac['id']],_0x2cfb05()[_0x377385('0x1a08')](_0x4ab632,_0x4fcad6)),_0x37f326(_0x11c992[_0x377385('0x1f7e')][_0xa7fdac['id']]);})[_0x1635b1('0x1a80')](function(_0x397ff8){const _0x1cc8b9=_0x1635b1;_0x4aea4b['error']({'title':_0x397ff8[_0x1cc8b9('0x52d')]?_0x1cc8b9('0x1e21')+_0x397ff8[_0x1cc8b9('0x52d')]+'\x20-\x20'+_0x397ff8[_0x1cc8b9('0xe1b')]:_0x1cc8b9('0x1e3c'),'msg':_0x397ff8[_0x1cc8b9('0x25f4')]?JSON[_0x1cc8b9('0xbac')](_0x397ff8['data'][_0x1cc8b9('0x1e70')]):_0x397ff8[_0x1cc8b9('0x1586')]()});});}function _0x593a02(_0x401d51){const _0x507b1e=_0x15c10c;return _0x78df2b[_0x507b1e('0x557')]['unpause']({'id':_0x401d51['id']})[_0x507b1e('0xa44')][_0x507b1e('0x1166')](function(_0x3f8538){const _0x2082c5=_0x507b1e;_0x11c992['agents'][_0x401d51['id']]&&_0x2cfb05()[_0x2082c5('0xcc3')](_0x11c992[_0x2082c5('0x1f7e')][_0x401d51['id']],_0x2cfb05()[_0x2082c5('0x1a08')](_0x3f8538,_0x4fcad6)),_0x11c992[_0x2082c5('0x24b7')][_0x401d51['id']]&&_0x2cfb05()[_0x2082c5('0xcc3')](_0x11c992['rpcAgents'][_0x401d51['id']],_0x2cfb05()['pick'](_0x3f8538,_0x4fcad6)),_0x37f326(_0x11c992[_0x2082c5('0x1f7e')][_0x401d51['id']]);})['catch'](function(_0x287805){const _0x4c240f=_0x507b1e;_0x4aea4b['error']({'title':_0x287805[_0x4c240f('0x52d')]?_0x4c240f('0x1e21')+_0x287805[_0x4c240f('0x52d')]+'\x20-\x20'+_0x287805[_0x4c240f('0xe1b')]:_0x4c240f('0x1e3c'),'msg':_0x287805[_0x4c240f('0x25f4')]?JSON[_0x4c240f('0xbac')](_0x287805[_0x4c240f('0x25f4')][_0x4c240f('0x1e70')]):_0x287805[_0x4c240f('0x1586')]()});});}function _0x155692(_0x377d0f){const _0x44e6c2=_0x15c10c;_0x61861c[_0x44e6c2('0x1f80')](_0x61861c[_0x44e6c2('0x31d')]()['clickOutsideToClose'](!![])[_0x44e6c2('0xcdc')](_0x44e6c2('0x58a'))[_0x44e6c2('0xf3c')](_0x44e6c2('0x1174'))['ok']('Ok')['targetEvent'](_0x377d0f));}function _0x1931ae(_0x4922db,_0x519d53){const _0x57c542=_0x15c10c;_0x61861c[_0x57c542('0x1f80')]({'controller':'AgentqueueaddController','controllerAs':'vm','templateUrl':_0x49c5be,'parent':angular[_0x57c542('0x1194')](_0x261495[_0x57c542('0x8d2')]),'targetEvent':_0x519d53,'clickOutsideToClose':!![],'locals':{'agent':_0x4922db,'agents':[],'channel':_0x57c542('0x146c'),'direction':_0x57c542('0x14d8'),'crudPermissions':_0x11c992[_0x57c542('0x243c')]}});}function _0x108a68(_0x57cbe0){const _0x45fa51=_0x15c10c;return _0x57cbe0===_0x45fa51('0x1e77')||_0x57cbe0==='*pause';}function _0x433e8(_0x588918){const _0x11702c=_0x15c10c;return _0x588918===_0x11702c('0x1e77');}function _0x2a53d2(_0x347a01){const _0x1a966d=_0x15c10c;return _0x347a01===_0x1a966d('0x6e8');}function _0x47bfd8(_0x506df7){const _0x1f2f96=_0x15c10c;return _0x506df7===_0x1f2f96('0xdb0')||_0x506df7==='unknown'||_0x506df7===_0x1f2f96('0x14dd')||_0x506df7==='ringing'||_0x2cfb05()[_0x1f2f96('0x2863')](_0x506df7);}function _0x121093(_0x1ac96d,_0x33ce5a){const _0x4e7d3d=_0x15c10c;if(_0x33ce5a===_0x4e7d3d('0x21da')){if(_0x1ac96d[_0x33ce5a+_0x4e7d3d('0x28f6')]!==_0x4e7d3d('0xdb0'))return _0x1ac96d[_0x33ce5a+_0x4e7d3d('0x28f6')];if(_0x1ac96d[_0x33ce5a+_0x4e7d3d('0x108')])return _0x1ac96d[_0x33ce5a+_0x4e7d3d('0x28f6')]='pause',_0x4e7d3d('0x1e77');return _0x4e7d3d('0xdb0');}else{if(_0x1ac96d[_0x33ce5a+'Pause'])return _0x1ac96d[_0x33ce5a+_0x4e7d3d('0x28f6')]='pause','pause';return _0x1ac96d[_0x33ce5a+_0x4e7d3d('0x28f6')];}}function _0x37f326(_0x3da639){const _0x31f96d=_0x15c10c;let _0x1281bd=_0x31f96d('0x22d5');if(_0x2cfb05()[_0x31f96d('0x2285')]([_0x121093(_0x3da639,_0x31f96d('0x21da')),_0x121093(_0x3da639,_0x31f96d('0xde2')),_0x121093(_0x3da639,_0x31f96d('0x1bfa')),_0x121093(_0x3da639,_0x31f96d('0x26c')),_0x121093(_0x3da639,_0x31f96d('0x146c')),_0x121093(_0x3da639,_0x31f96d('0x116e')),_0x121093(_0x3da639,'fax')],_0x108a68))_0x1281bd='pause';else{if(_0x2cfb05()['some']([_0x121093(_0x3da639,_0x31f96d('0x21da')),_0x121093(_0x3da639,'chat'),_0x121093(_0x3da639,_0x31f96d('0x1bfa')),_0x121093(_0x3da639,'openchannel'),_0x121093(_0x3da639,_0x31f96d('0x146c')),_0x121093(_0x3da639,_0x31f96d('0x116e')),_0x121093(_0x3da639,'fax')],_0x108a68))_0x1281bd=_0x31f96d('0x6e8');else _0x2cfb05()[_0x31f96d('0x2285')]([_0x121093(_0x3da639,_0x31f96d('0x21da')),_0x121093(_0x3da639,_0x31f96d('0xde2')),_0x121093(_0x3da639,'mail'),_0x121093(_0x3da639,_0x31f96d('0x26c')),_0x121093(_0x3da639,_0x31f96d('0x146c')),_0x121093(_0x3da639,'whatsapp'),_0x121093(_0x3da639,_0x31f96d('0x1fc7'))],_0x47bfd8)?_0x1281bd='idle':_0x1281bd=_0x31f96d('0x2344');}_0x3da639['globalStatus']!==_0x1281bd&&(_0x3da639[_0x31f96d('0xe34')]=_0x1281bd,_0x3da639[_0x31f96d('0x24d5')]?(_0x3da639[_0x31f96d('0x24d5')]=![],_0x3da639['globalStatusTime']=_0x108a68(_0x1281bd)?_0x2cfb05()[_0x31f96d('0xa53')](_0x24273b()(_0x3da639[_0x31f96d('0x3dc')])[_0x31f96d('0x128a')]('x')):_0x2cfb05()[_0x31f96d('0x28bc')]([_0x3da639['voiceStatusTime'],_0x3da639[_0x31f96d('0x1507')],_0x3da639[_0x31f96d('0x1955')],_0x3da639[_0x31f96d('0x2357')],_0x3da639[_0x31f96d('0x11a8')],_0x3da639[_0x31f96d('0x43e')],_0x3da639[_0x31f96d('0x4f3')]])):_0x3da639[_0x31f96d('0x25b3')]=_0x2cfb05()[_0x31f96d('0xa53')](_0x24273b()()[_0x31f96d('0x128a')]('x')));}function _0x3905b3(_0x1db9cc){const _0x3d491e=_0x15c10c,_0x555a5f=_0x2cfb05()[_0x3d491e('0x1783')](_0x11c992['query'][_0x3d491e('0xa99')],'-')?_0x3d491e('0x1dc3'):_0x3d491e('0x17d');return _0x2cfb05()['orderBy'](_0x1db9cc,[_0x11c992[_0x3d491e('0x2218')]['order'][_0x3d491e('0xf3')]('-','')],[_0x555a5f]);}function _0xb21757(){const _0x586eaf=_0x15c10c;_0x1209d2&&(_0x9a2732[_0x586eaf('0x3f')](_0x1209d2),_0x1209d2=null);}function _0x16a195(_0x4fc448,_0x487544){const _0x2f94d9=_0x15c10c;return _0x78df2b['user'][_0x2f94d9('0x1449')]({'id':_0x4fc448['id']},{'screenrecording':_0x487544})[_0x2f94d9('0xa44')][_0x2f94d9('0x1a80')](function(_0x70517f){const _0x342979=_0x2f94d9;_0x4aea4b[_0x342979('0xfc9')]({'title':_0x70517f[_0x342979('0x52d')]?_0x342979('0x1e21')+_0x70517f[_0x342979('0x52d')]+_0x342979('0x11e1')+_0x70517f[_0x342979('0xe1b')]:_0x342979('0x1103'),'msg':_0x70517f[_0x342979('0x25f4')]?JSON[_0x342979('0xbac')](_0x70517f[_0x342979('0x25f4')][_0x342979('0x1e70')]):_0x70517f[_0x342979('0x1586')]()});});}_0x3ced56['$on'](_0x15c10c('0x1c3f'),function(){const _0x1effc7=_0x15c10c;_0x11d55a['removeAllListeners'](_0x1effc7('0x26b2')),_0x11d55a[_0x1effc7('0x1800')](_0x1effc7('0x19d5')),_0x11d55a['removeAllListeners'](_0x1effc7('0x10fc')),_0x11d55a[_0x1effc7('0x1800')]('user:agentcomplete'),_0xb21757();});}const _0x4bd1bf=_0x6ab97c,_0x4ee57a=_0x2734b2['p']+'src/js/modules/main/apps/sms/views/smsQueues/create/dialog.html/dialog.html',_0x199d18=_0x2734b2['p']+'src/js/modules/main/apps/sms/views/smsQueues/edit/agentadd/agentadd.html/agentadd.html';_0x590fd4[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$q','$document',_0x36e6f4('0x10eb'),_0x36e6f4('0x7a7'),_0x36e6f4('0x744'),_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x1d2e'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x590fd4(_0x225ae6,_0x40871c,_0x3891d5,_0x398681,_0x53b6dc,_0x18f0c5,_0x3fc6fc,_0x43aecb,_0x25325f,_0x328381,_0xb7fbc7,_0x5693ff,_0x11d39a,_0x10f0d3){const _0x1a2a5c=_0x36e6f4,_0x3ac4d5=this,_0x57b797=['loggedIn','available',_0x1a2a5c('0x288a'),_0x1a2a5c('0x46a'),_0x1a2a5c('0x67d'),_0x1a2a5c('0x20ab'),_0x1a2a5c('0x1e70'),'dialActive',_0x1a2a5c('0x20ae'),'Trunk',_0x1a2a5c('0x18b')];_0x3ac4d5[_0x1a2a5c('0x98')]=_0x10f0d3[_0x1a2a5c('0x26cd')](),_0x3ac4d5[_0x1a2a5c('0x240f')]=_0x3fc6fc[_0x1a2a5c('0x240f')]?_0x3fc6fc[_0x1a2a5c('0x240f')]:0x0,_0x3ac4d5['queues']=_0x3fc6fc?_0x2cfb05()[_0x1a2a5c('0x155c')](_0x3fc6fc[_0x1a2a5c('0x269a')]?_0x3fc6fc[_0x1a2a5c('0x269a')]:[],'id'):{},_0x3ac4d5[_0x1a2a5c('0x744')]=_0x43aecb?_0x2cfb05()[_0x1a2a5c('0x155c')](_0x43aecb['rows']?_0x43aecb[_0x1a2a5c('0x269a')]:[],'id'):{},_0x3ac4d5[_0x1a2a5c('0x7f')]=_0x5693ff,_0x3ac4d5[_0x1a2a5c('0x17aa')]=_0x11d39a&&_0x11d39a[_0x1a2a5c('0x240f')]==0x1?_0x11d39a[_0x1a2a5c('0x269a')][0x0]:null,_0x3ac4d5[_0x1a2a5c('0x243c')]=_0x10f0d3[_0x1a2a5c('0xd87')](_0x3ac4d5[_0x1a2a5c('0x17aa')]?_0x3ac4d5['userProfileSection'][_0x1a2a5c('0x243c')]:null);_0x10f0d3[_0x1a2a5c('0x1ac6')](_0x1a2a5c('0xa7c'))?_0x3ac4d5[_0x1a2a5c('0x2218')]={'type':_0x1a2a5c('0x14d8'),'sort':_0x1a2a5c('0x14dc'),'limit':0xa,'page':0x1}:_0x3ac4d5[_0x1a2a5c('0x2218')]={'id':_0x3ac4d5[_0x1a2a5c('0x98')]['id'],'channel':_0x1a2a5c('0x146c'),'type':'inbound','sort':_0x1a2a5c('0x14dc'),'limit':0xa,'page':0x1};_0x3ac4d5['success']=_0x53968f,_0x3ac4d5[_0x1a2a5c('0x152a')]=_0xbc2f7f,_0x3ac4d5['createOrEditSmsQueue']=_0xc571e,_0x3ac4d5['agentAdd']=_0x15a4f9,_0x3ac4d5[_0x1a2a5c('0xeba')]=_0x5a0eac,_0x3ac4d5[_0x1a2a5c('0x1303')]=_0x1cb6e5,_0x3ac4d5[_0x1a2a5c('0xfb')]=_0x42ce6f,_0x3ac4d5['onRemoveMember']=_0x5026fb,_0x3ac4d5[_0x1a2a5c('0x212c')]=_0x52049d,_0x3ac4d5[_0x1a2a5c('0xb9a')]=_0x36079d,_0x3ac4d5[_0x1a2a5c('0x1696')]=_0x2043d9,_0x3ac4d5['$onInit']=_0x2b6717,_0x3ac4d5[_0x1a2a5c('0xa99')]=[],_0x2cfb05()[_0x1a2a5c('0x941')](_0x3ac4d5['queues'],function(_0x8d1e4f){const _0x2c0c5e=_0x1a2a5c;_0x3ac4d5['order'][_0x2c0c5e('0x1514')](_0x8d1e4f['id']);}),_0x328381['on'](_0x1a2a5c('0x565'),_0x3ac4d5[_0x1a2a5c('0x1303')]),_0x328381['on'](_0x1a2a5c('0x36'),_0x3ac4d5['onSaveMember']),_0x328381['on']('userSmsQueue:remove',_0x3ac4d5[_0x1a2a5c('0xfe9')]),_0x328381['on'](_0x1a2a5c('0x19d5'),_0x3ac4d5[_0x1a2a5c('0x212c')]),_0x328381['on'](_0x1a2a5c('0x25f0'),_0x3ac4d5[_0x1a2a5c('0x1696')]),_0x328381['on'](_0x1a2a5c('0x663'),_0x3ac4d5[_0x1a2a5c('0xb9a')]);function _0x2b6717(){const _0x14dab3=_0x1a2a5c,_0x39888a=[];return _0x2cfb05()[_0x14dab3('0x941')](_0x3ac4d5[_0x14dab3('0x7a7')],function(_0x5031d4,_0x45e855){const _0x5b8cc3=_0x14dab3;_0x5031d4[_0x5b8cc3('0x18b')]=0x0,_0x5031d4[_0x5b8cc3('0x2689')]=0x0,_0x3ac4d5[_0x5b8cc3('0x7a7')][_0x45e855][_0x5b8cc3('0x1f7e')]={},_0x39888a['push'](_0x25325f[_0x5b8cc3('0x73c')][_0x5b8cc3('0x27d1')]({'id':_0x45e855})[_0x5b8cc3('0xa44')]),_0x3ac4d5['rpcQueues'][_0x45e855]&&_0x2cfb05()[_0x5b8cc3('0xcc3')](_0x5031d4,_0x2cfb05()[_0x5b8cc3('0x1a08')](_0x3ac4d5[_0x5b8cc3('0x744')][_0x45e855],_0x57b797));}),_0x398681[_0x14dab3('0x2760')](_0x39888a)['then'](function(_0x42a3ad){const _0x346308=_0x14dab3;for(let _0x2113f4=0x0;_0x2113f4<_0x42a3ad[_0x346308('0x264b')];_0x2113f4+=0x1){for(let _0x286444=0x0;_0x286444<_0x42a3ad[_0x2113f4][_0x346308('0x269a')][_0x346308('0x264b')];_0x286444++){_0x42a3ad[_0x2113f4][_0x346308('0x269a')][_0x286444]['paused']&&_0x3ac4d5[_0x346308('0x7a7')][_0x42a3ad[_0x2113f4][_0x346308('0x269a')][_0x286444][_0x346308('0x1516')]][_0x346308('0x18b')]++,_0x3ac4d5[_0x346308('0x7a7')][_0x42a3ad[_0x2113f4]['rows'][_0x286444][_0x346308('0x1516')]][_0x346308('0x2689')]++,_0x3ac4d5[_0x346308('0x7a7')][_0x42a3ad[_0x2113f4][_0x346308('0x269a')][_0x286444][_0x346308('0x1516')]][_0x346308('0x1f7e')][_0x42a3ad[_0x2113f4][_0x346308('0x269a')][_0x286444][_0x346308('0x122a')]]=_0x42a3ad[_0x2113f4][_0x346308('0x269a')][_0x286444][_0x346308('0x1516')];}}})['catch'](function(_0x5ee8b3){const _0x12e43a=_0x14dab3;console[_0x12e43a('0xfc9')](_0x5ee8b3);});}function _0x1cb6e5(_0x147e37){const _0x20be29=_0x1a2a5c;_0x3ac4d5['queues'][_0x147e37['id']]&&_0x2cfb05()[_0x20be29('0xcc3')](_0x3ac4d5['queues'][_0x147e37['id']],_0x2cfb05()[_0x20be29('0x1a08')](_0x147e37,_0x57b797));}function _0x42ce6f(_0x5f5d6b){const _0x5b27f1=_0x1a2a5c;_0x3ac4d5['queues'][_0x5f5d6b[_0x5b27f1('0x1516')]]&&_0x3ac4d5[_0x5b27f1('0x7a7')][_0x5f5d6b['SmsQueueId']][_0x5b27f1('0x2689')]++;}function _0x5026fb(_0x513266){const _0x1f182=_0x1a2a5c;_0x3ac4d5[_0x1f182('0x7a7')][_0x513266[_0x1f182('0x1516')]]&&_0x3ac4d5['queues'][_0x513266[_0x1f182('0x1516')]]['loggedInDb']--;}function _0x52049d(_0x371393){const _0x506309=_0x1a2a5c;console['log'](_0x506309('0x212c'),_0x371393);if(_0x371393['voicePause'])_0x2cfb05()['forIn'](_0x3ac4d5['queues'],function(_0x4f22c4){const _0x28db18=_0x506309;_0x4f22c4[_0x28db18('0x1f7e')][_0x371393['id']]&&(_0x4f22c4['paused']+=0x1,console[_0x28db18('0x455')](_0x28db18('0x1e77')));});else!_0x371393['voicePause']&&_0x2cfb05()[_0x506309('0x941')](_0x3ac4d5['queues'],function(_0x4bbf0f){const _0x400e9a=_0x506309;_0x4bbf0f[_0x400e9a('0x1f7e')][_0x371393['id']]&&(_0x4bbf0f[_0x400e9a('0x18b')]>0x0&&(_0x4bbf0f[_0x400e9a('0x18b')]-=0x1,console[_0x400e9a('0x455')](_0x400e9a('0x20eb'))));});}function _0x36079d(_0x308e02){const _0x2d2053=_0x1a2a5c;console[_0x2d2053('0x455')]('onLogged',_0x308e02),_0x3ac4d5['queues'][_0x308e02[_0x2d2053('0x1516')]]&&(_0x3ac4d5[_0x2d2053('0x7a7')][_0x308e02['SmsQueueId']][_0x2d2053('0x2689')]+=0x1,_0x3ac4d5[_0x2d2053('0x7a7')][_0x308e02['SmsQueueId']][_0x2d2053('0x1f7e')][_0x308e02['UserId']]=_0x308e02[_0x2d2053('0x1516')]);}function _0x2043d9(_0x34c608){const _0x41fd69=_0x1a2a5c;console[_0x41fd69('0x455')](_0x41fd69('0x1696'),_0x34c608),_0x3ac4d5[_0x41fd69('0x7a7')][_0x34c608[_0x41fd69('0x1516')]]&&_0x3ac4d5['queues'][_0x34c608[_0x41fd69('0x1516')]][_0x41fd69('0x2689')]>0x0&&(_0x3ac4d5['queues'][_0x34c608[_0x41fd69('0x1516')]][_0x41fd69('0x2689')]-=0x1,delete _0x3ac4d5[_0x41fd69('0x7a7')][_0x34c608[_0x41fd69('0x1516')]][_0x41fd69('0x1f7e')][_0x34c608[_0x41fd69('0x122a')]]);}let _0x1eb8d9=!![],_0x503814=0x1;_0x225ae6[_0x1a2a5c('0xe83')]('vm.query.filter',function(_0x323480,_0x357be3){const _0x26916d=_0x1a2a5c;_0x1eb8d9?_0x40871c(function(){_0x1eb8d9=![];}):(!_0x357be3&&(_0x503814=_0x3ac4d5[_0x26916d('0x2218')]['page']),_0x323480!==_0x357be3&&(_0x3ac4d5[_0x26916d('0x2218')]['page']=0x1),!_0x323480&&(_0x3ac4d5['query'][_0x26916d('0x1a43')]=_0x503814),_0x3ac4d5[_0x26916d('0x152a')]());});function _0x53968f(_0x41979f){const _0x5072cc=_0x1a2a5c;_0x3ac4d5[_0x5072cc('0x240f')]=_0x41979f[_0x5072cc('0x240f')],_0x3ac4d5[_0x5072cc('0x7a7')]=_0x41979f?_0x2cfb05()[_0x5072cc('0x155c')](_0x41979f[_0x5072cc('0x269a')]?_0x41979f[_0x5072cc('0x269a')]:[],'id'):{};if(_0x41979f['rows']){_0x3ac4d5['order']=[];for(let _0x2fb17e=0x0;_0x2fb17e<_0x41979f['rows'][_0x5072cc('0x264b')];_0x2fb17e++){_0x3ac4d5[_0x5072cc('0xa99')][_0x5072cc('0x1514')](_0x41979f[_0x5072cc('0x269a')][_0x2fb17e]['id']);}}_0x2b6717();}function _0xbc2f7f(){const _0x44ec85=_0x1a2a5c;_0x3ac4d5[_0x44ec85('0x2218')][_0x44ec85('0x1098')]=(_0x3ac4d5['query'][_0x44ec85('0x1a43')]-0x1)*_0x3ac4d5[_0x44ec85('0x2218')][_0x44ec85('0x163f')],_0x10f0d3[_0x44ec85('0x1ac6')]('admin')?_0x3ac4d5[_0x44ec85('0x1f48')]=_0x25325f[_0x44ec85('0x73c')][_0x44ec85('0xd83')](_0x3ac4d5[_0x44ec85('0x2218')],_0x53968f)[_0x44ec85('0xa44')]:(_0x3ac4d5[_0x44ec85('0x2218')]['id']=_0x3ac4d5[_0x44ec85('0x7f')]['id'],_0x3ac4d5[_0x44ec85('0x2218')]['section']=_0x44ec85('0x24e4'),_0x3ac4d5[_0x44ec85('0x1f48')]=_0x25325f[_0x44ec85('0x7f')][_0x44ec85('0x263a')](_0x3ac4d5[_0x44ec85('0x2218')],_0x53968f)[_0x44ec85('0xa44')]);}function _0xc571e(_0x2b290d,_0x55ba85){const _0x49126e=_0x1a2a5c;_0x3891d5[_0x49126e('0x1f80')]({'controller':_0x49126e('0x1ec4'),'controllerAs':'vm','templateUrl':_0x4ee57a,'parent':angular[_0x49126e('0x1194')](_0x53b6dc[_0x49126e('0x8d2')]),'targetEvent':_0x2b290d,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x55ba85,'smsQueues':_0x2cfb05()[_0x49126e('0x1ac1')](_0x3ac4d5[_0x49126e('0x7a7')]),'license':null,'setting':null,'crudPermissions':_0x3ac4d5['crudPermissions']}});}function _0x15a4f9(_0x3100a8,_0x2e4233){const _0x43680a=_0x1a2a5c;_0x3891d5[_0x43680a('0x1f80')]({'controller':_0x43680a('0xe68'),'controllerAs':'vm','templateUrl':_0x199d18,'parent':angular[_0x43680a('0x1194')](_0x53b6dc['body']),'targetEvent':_0x3100a8,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x2e4233,'smsQueues':_0x3ac4d5[_0x43680a('0x7a7')]?_0x3ac4d5[_0x43680a('0x7a7')][_0x43680a('0x269a')]:[],'realtime':![],'crudPermissions':_0x3ac4d5[_0x43680a('0x243c')]}});}function _0x5a0eac(_0x17ce30){const _0xafe382=_0x1a2a5c;return _0x25325f['smsQueue'][_0xafe382('0x1449')](_0x17ce30)[_0xafe382('0xa44')][_0xafe382('0x1166')](function(){const _0x1f1ab8=_0xafe382;_0xb7fbc7[_0x1f1ab8('0x103b')]({'title':'Queue\x20properly\x20updated!','msg':_0x17ce30['name']?_0x17ce30[_0x1f1ab8('0x4f0')]+_0x1f1ab8('0xa17'):''});})[_0xafe382('0x1a80')](function(_0x22edcf){const _0x1cafd7=_0xafe382;_0xb7fbc7[_0x1cafd7('0xfc9')]({'title':_0x1cafd7('0xa98'),'msg':_0x22edcf['message']});});}_0x225ae6[_0x1a2a5c('0x3d2')]('$destroy',function(){const _0x1a5aaa=_0x1a2a5c;_0x328381['removeAllListeners']('sms_queue:save'),_0x328381[_0x1a5aaa('0x1800')](_0x1a5aaa('0x2070')),_0x328381[_0x1a5aaa('0x1800')](_0x1a5aaa('0x36')),_0x328381['removeAllListeners'](_0x1a5aaa('0x19d5')),_0x328381[_0x1a5aaa('0x1800')](_0x1a5aaa('0x25f0')),_0x328381[_0x1a5aaa('0x1800')](_0x1a5aaa('0x663'));});}const _0xe0f165=_0x590fd4;function _0x1ad6bf(){const _0x746cdf=_0x36e6f4;return{'status':{'registered':_0x746cdf('0x23ca'),'unregistered':_0x746cdf('0x278f'),'lagged':_0x746cdf('0x278f'),'reachable':'green-300-fg\x20icon-checkbox-marked-circle','unreachable':_0x746cdf('0x278f'),'unknown':_0x746cdf('0x2125')},'state':{'unknown':'grey-fg\x20icon-phone-hangup','not_inuse':_0x746cdf('0xa1e'),'inuse':_0x746cdf('0xa2f'),'busy':_0x746cdf('0x18d2'),'invalid':_0x746cdf('0x1d48'),'unavailable':_0x746cdf('0x1d48'),'ringing':_0x746cdf('0x132c'),'ringinuse':_0x746cdf('0x132c'),'onhold':'blue-300-fg\x20icon-phone-paused'},'channelStatus':{'ring':'blue-300-fg\x20icon-phone-incoming','up':_0x746cdf('0x20b2'),'hangup':'red-300-fg\x20icon-phone-hangup'},'channelStatusOut':{'ring':_0x746cdf('0xac'),'up':_0x746cdf('0x20b2'),'hangup':_0x746cdf('0x9e3')}};}const _0x39d0b7=_0x1ad6bf;_0x4627ea[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x2661')];function _0x4627ea(_0x5b2f01,_0x31c96a,_0x199655){const _0x6075f1=_0x36e6f4,_0x5072c4=this;_0x199655[_0x6075f1('0x670')](),_0x199655['connect'](),_0x5072c4[_0x6075f1('0x2669')]=0x0;switch(_0x31c96a[_0x6075f1('0x22b5')][_0x6075f1('0x4f0')]){case _0x6075f1('0x1456'):_0x5072c4[_0x6075f1('0x2669')]=0x0;break;case _0x6075f1('0x2494'):_0x5072c4[_0x6075f1('0x2669')]=0x1;break;default:_0x5072c4[_0x6075f1('0x2669')]=0x0,_0x31c96a['go'](_0x6075f1('0x1456'));}_0x5b2f01[_0x6075f1('0xe83')](_0x6075f1('0x27a7'),function(_0x17802a,_0x54ccd3){const _0x4f9326=_0x6075f1;if(_0x17802a!==_0x54ccd3)switch(_0x17802a){case 0x0:_0x31c96a['go']('app.sms.realtime.agents');break;case 0x1:_0x31c96a['go'](_0x4f9326('0x2494'));break;default:_0x31c96a['go'](_0x4f9326('0x1456'));}});}const _0x58f77a=_0x4627ea;_0x4fa18e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x4fa18e(_0x2485f2){const _0x4332fd=_0x36e6f4;_0x2485f2[_0x4332fd('0x63f')](_0x4332fd('0x1e4b'),{'url':_0x4332fd('0x1c2e'),'views':{'content@app':{'templateUrl':_0x2a9387,'controller':_0x4332fd('0x160e')}},'resolve':{'userProfile':[_0x4332fd('0x1fbc'),_0x4332fd('0x21ef'),function(_0x52ed7c,_0x2bbf36){const _0x1242f0=_0x4332fd;return _0x2bbf36[_0x1242f0('0x1ac6')](_0x1242f0('0xa7c'))?null:_0x52ed7c['resolve'](_0x1242f0('0x697'),{'fields':_0x1242f0('0x686'),'id':_0x2bbf36['getCurrentUser']()[_0x1242f0('0xb86')]});}],'userProfileSection':[_0x4332fd('0x1fbc'),_0x4332fd('0x21ef'),function(_0x116e94,_0x125c78){const _0x31383d=_0x4332fd;return _0x125c78['hasRole'](_0x31383d('0xa7c'))?null:_0x116e94[_0x31383d('0x18af')](_0x31383d('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x125c78['getCurrentUser']()[_0x31383d('0xb86')],'sectionId':0x2c6});}]},'authenticate':!![],'permissionId':0x2c6})[_0x4332fd('0x63f')](_0x4332fd('0x1456'),{'url':_0x4332fd('0x730'),'controller':_0x4332fd('0x25c4'),'templateUrl':_0x1fd43a,'resolve':{'pauses':[_0x4332fd('0x1fbc'),function(_0x2dd9a7){const _0x547323=_0x4332fd;return _0x2dd9a7[_0x547323('0x18af')](_0x547323('0x737'),{'nolimit':!![]});}],'agents':[_0x4332fd('0x1fbc'),_0x4332fd('0x21ef'),function(_0x4b9ebd,_0x7cb49f){const _0x3d3fb4=_0x4332fd;return _0x7cb49f[_0x3d3fb4('0x1ac6')](_0x3d3fb4('0xa7c'))?_0x4b9ebd[_0x3d3fb4('0x18af')](_0x3d3fb4('0x1c80'),{'fields':_0x3d3fb4('0x1746'),'role':_0x3d3fb4('0x1eff'),'sort':_0x3d3fb4('0x6e1'),'nolimit':!![]}):_0x4b9ebd[_0x3d3fb4('0x18af')](_0x3d3fb4('0x17c4'),{'id':_0x7cb49f['getCurrentUser']()['userProfileId'],'section':'Agents','fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0x3d3fb4('0x1eff'),'sort':_0x3d3fb4('0x6e1'),'nolimit':!![]});}],'userProfile':[_0x4332fd('0x1fbc'),_0x4332fd('0x21ef'),function(_0x524f3b,_0x3631c9){const _0x405af1=_0x4332fd;return _0x3631c9[_0x405af1('0x1ac6')](_0x405af1('0xa7c'))?null:_0x524f3b['resolve'](_0x405af1('0x697'),{'fields':_0x405af1('0x686'),'id':_0x3631c9[_0x405af1('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x4332fd('0x1fbc'),_0x4332fd('0x21ef'),function(_0x3e1f54,_0x27c635){const _0x2a6aeb=_0x4332fd;return _0x27c635['hasRole'](_0x2a6aeb('0xa7c'))?null:_0x3e1f54[_0x2a6aeb('0x18af')](_0x2a6aeb('0xaf'),{'fields':_0x2a6aeb('0xe26'),'userProfileId':_0x27c635[_0x2a6aeb('0x26cd')]()['userProfileId'],'sectionId':0xca});}],'rpcAgents':[_0x4332fd('0x1fbc'),function(_0x526751){const _0x59052f=_0x4332fd;return _0x526751[_0x59052f('0x18af')](_0x59052f('0xfab'));}]},'authenticate':!![],'permissionId':0x2c6})['state'](_0x4332fd('0x2494'),{'url':'/queues','controller':_0x4332fd('0x2360'),'templateUrl':_0x22fcb7,'resolve':{'queues':[_0x4332fd('0x1fbc'),_0x4332fd('0x21ef'),function(_0x174f58,_0x245308){const _0x177299=_0x4332fd;return _0x245308[_0x177299('0x1ac6')](_0x177299('0xa7c'))?_0x174f58[_0x177299('0x18af')](_0x177299('0xcaa'),{'type':'inbound','sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x174f58[_0x177299('0x18af')](_0x177299('0x17c4'),{'id':_0x245308[_0x177299('0x26cd')]()[_0x177299('0xb86')],'section':_0x177299('0x24e4'),'channel':_0x177299('0x146c'),'type':_0x177299('0x14d8'),'sort':_0x177299('0x14dc'),'limit':0xa,'page':0x1});}],'userProfile':['apiResolver',_0x4332fd('0x21ef'),function(_0x17c032,_0x590713){const _0x368dc9=_0x4332fd;return _0x590713[_0x368dc9('0x1ac6')](_0x368dc9('0xa7c'))?null:_0x17c032[_0x368dc9('0x18af')](_0x368dc9('0x697'),{'fields':_0x368dc9('0x686'),'id':_0x590713[_0x368dc9('0x26cd')]()[_0x368dc9('0xb86')]});}],'userProfileSection':['apiResolver',_0x4332fd('0x21ef'),function(_0x4bdb38,_0x2a2e3f){const _0x5663fa=_0x4332fd;return _0x2a2e3f[_0x5663fa('0x1ac6')]('admin')?null:_0x4bdb38['resolve'](_0x5663fa('0xaf'),{'fields':_0x5663fa('0xe26'),'userProfileId':_0x2a2e3f[_0x5663fa('0x26cd')]()['userProfileId'],'sectionId':0x2bd});}],'rpcQueues':[_0x4332fd('0x1fbc'),function(_0xa48436){const _0x22a340=_0x4332fd;return _0xa48436[_0x22a340('0x18af')](_0x22a340('0x1aa1'));}]},'authenticate':!![],'permissionId':0x2c6});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x1e4b'),[])['config'](_0x4fa18e)[_0x36e6f4('0x75e')](_0x36e6f4('0xa8a'),_0x4bd1bf)['controller'](_0x36e6f4('0x25c9'),_0xe0f165)[_0x36e6f4('0x87c')](_0x36e6f4('0x1a02'),_0x39d0b7)[_0x36e6f4('0x75e')](_0x36e6f4('0x2443'),_0x58f77a);const _0x39d966=_0x2734b2['p']+_0x36e6f4('0x1e0e'),_0x114e04=_0x2734b2['p']+_0x36e6f4('0x24e2'),_0x17313f=_0x2734b2['p']+_0x36e6f4('0x7c9'),_0x143228=_0x2734b2['p']+_0x36e6f4('0x1a6a');_0x8aa11['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x1d76'),'smsAccount','api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting','crudPermissions'];function _0x8aa11(_0x5b740a,_0x17e855,_0x4a5109,_0x189cf4,_0x58b49f,_0x5db489,_0x58fdc5,_0x2d3212,_0x5dd306,_0x3b55cd,_0x57aa99,_0x111967,_0x1a092f,_0x46b70d){const _0x533de8=_0x36e6f4,_0x256aa2=this;_0x256aa2[_0x533de8('0x98')]=_0x57aa99[_0x533de8('0x26cd')](),_0x256aa2['errors']=[],_0x256aa2[_0x533de8('0xf8a')]=_0x1a092f,_0x256aa2[_0x533de8('0x5c9')]=_0x111967,_0x256aa2[_0x533de8('0x243c')]=_0x46b70d,_0x256aa2['hasModulePermissions']={},_0x256aa2[_0x533de8('0x2900')]=_0x256aa2[_0x533de8('0xf8a')]&&_0x256aa2[_0x533de8('0xf8a')][_0x533de8('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x256aa2['title']=_0x533de8('0x209a'),_0x256aa2[_0x533de8('0x27e5')]=angular['copy'](_0x5dd306),_0x256aa2['smsAccounts']=_0x2d3212,_0x256aa2['newSmsAccount']=![];!_0x256aa2[_0x533de8('0x27e5')]&&(_0x256aa2[_0x533de8('0x27e5')]={'remote':_0x4a5109['protocol']()+_0x533de8('0xc51')+_0x4a5109[_0x533de8('0x1690')]()+(_0x4a5109[_0x533de8('0x93d')]()?':'+_0x4a5109[_0x533de8('0x93d')]():''),'type':'twilio','waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0x256aa2[_0x533de8('0xcdc')]=_0x533de8('0xf64'),_0x256aa2[_0x533de8('0x2885')]=!![]);_0x17e855[_0x533de8('0x23f')]['id']&&(_0x256aa2['smsAccount'][_0x533de8('0xa74')]=_0x17e855['params']['id']);_0x256aa2['addNewSmsAccount']=_0x1e235f,_0x256aa2[_0x533de8('0x25b1')]=_0x4f0aaf,_0x256aa2[_0x533de8('0x2084')]=_0x2b188e,_0x256aa2['getDateFromString']=_0xc8bed1,_0x256aa2[_0x533de8('0x24a0')]=_0x140d82,_0x57aa99[_0x533de8('0x1ac6')]('admin')?_0x3b55cd[_0x533de8('0xdd9')]['get']({'fields':_0x533de8('0x1776'),'sort':_0x533de8('0x4f0')})[_0x533de8('0xa44')][_0x533de8('0x1166')](function(_0x17cc8f){const _0x1db891=_0x533de8;_0x256aa2[_0x1db891('0x8de')]=_0x17cc8f['rows']||[];})[_0x533de8('0x1a80')](function(_0x403787){const _0x521271=_0x533de8;_0x58fdc5['error']({'title':_0x403787['status']?'API:'+_0x403787[_0x521271('0x52d')]+_0x521271('0x11e1')+_0x403787[_0x521271('0xe1b')]:_0x521271('0x520'),'msg':_0x403787['data']?JSON[_0x521271('0xbac')](_0x403787[_0x521271('0x25f4')]):_0x403787[_0x521271('0x1586')]()});}):_0x3b55cd[_0x533de8('0xdd9')][_0x533de8('0xd83')]({'fields':_0x533de8('0x1776'),'sort':_0x533de8('0x4f0')})[_0x533de8('0xa44')][_0x533de8('0x1166')](function(_0x3e1ff0){const _0x37ff4a=_0x533de8;_0x256aa2[_0x37ff4a('0x8de')]=_0x3e1ff0[_0x37ff4a('0x269a')]||[];})['then'](function(){const _0x577b33=_0x533de8;return _0x3b55cd[_0x577b33('0x17aa')][_0x577b33('0xd83')]({'userProfileId':_0x256aa2[_0x577b33('0x98')][_0x577b33('0xb86')],'sectionId':0x12d})[_0x577b33('0xa44')];})[_0x533de8('0x1166')](function(_0x394333){const _0x3e20cc=_0x533de8,_0x1c0e26=_0x394333&&_0x394333[_0x3e20cc('0x269a')]?_0x394333[_0x3e20cc('0x269a')][0x0]:null;if(!_0x1c0e26){const _0x487076=[];let _0x4900f4=null;_0x256aa2[_0x3e20cc('0x27e5')]&&(_0x4900f4=_0x2cfb05()['find'](_0x256aa2[_0x3e20cc('0x8de')],{'id':Number(_0x256aa2[_0x3e20cc('0x27e5')]['ListId'])}));for(let _0x475163=0x0;_0x475163<_0x256aa2[_0x3e20cc('0x8de')][_0x3e20cc('0x264b')];_0x475163++){_0x4900f4&&_0x256aa2[_0x3e20cc('0x8de')][_0x475163]['id']===_0x4900f4['id']&&(_0x256aa2['lists'][_0x475163][_0x3e20cc('0x2378')]=![],_0x487076[_0x3e20cc('0x1514')](_0x256aa2['lists'][_0x475163]));}_0x256aa2[_0x3e20cc('0x8de')]=_0x487076;}else{if(!_0x1c0e26[_0x3e20cc('0x1a2b')])return _0x3b55cd[_0x3e20cc('0x4b5')]['get']({'sectionId':_0x1c0e26['id']})[_0x3e20cc('0xa44')][_0x3e20cc('0x1166')](function(_0x5a5cc0){const _0x3da30a=_0x3e20cc,_0xf547a6=_0x2cfb05()['map'](_0x5a5cc0[_0x3da30a('0x269a')],function(_0x1356ba){const _0x25d2b6=_0x3da30a;return _0x2cfb05()[_0x25d2b6('0xc38')](_0x256aa2[_0x25d2b6('0x8de')],{'id':_0x1356ba[_0x25d2b6('0x24e8')]});});let _0x158542=null;_0x256aa2['smsAccount']&&(_0x158542=_0x2cfb05()['find'](_0x256aa2[_0x3da30a('0x8de')],{'id':Number(_0x256aa2[_0x3da30a('0x27e5')][_0x3da30a('0x23c')])}));if(_0x158542&&!_0x2cfb05()[_0x3da30a('0x1798')](_0xf547a6,['id',_0x158542['id']])){const _0x1bd8e2=_0x2cfb05()['find'](_0x256aa2[_0x3da30a('0x8de')],{'id':_0x158542['id']});_0x1bd8e2[_0x3da30a('0x2378')]=![],_0xf547a6['push'](_0x1bd8e2);}_0x256aa2[_0x3da30a('0x8de')]=_0xf547a6;});}})[_0x533de8('0x1a80')](function(_0x4beeb0){const _0x2f5b4b=_0x533de8;_0x58fdc5['error']({'title':_0x4beeb0['status']?_0x2f5b4b('0x1e21')+_0x4beeb0['status']+_0x2f5b4b('0x11e1')+_0x4beeb0[_0x2f5b4b('0xe1b')]:_0x2f5b4b('0x1248'),'msg':_0x4beeb0[_0x2f5b4b('0x25f4')]?JSON[_0x2f5b4b('0xbac')](_0x4beeb0['data']):_0x4beeb0['toString']()});});function _0x1e235f(){const _0x2ecc6a=_0x533de8;_0x256aa2[_0x2ecc6a('0x61a')]=[],_0x3b55cd[_0x2ecc6a('0x27e5')][_0x2ecc6a('0x9cc')](_0x256aa2[_0x2ecc6a('0x27e5')])[_0x2ecc6a('0xa44')][_0x2ecc6a('0x1166')](function(_0x4ec4cc){const _0x5ec97b=_0x2ecc6a;_0x256aa2['smsAccounts'][_0x5ec97b('0x2450')](_0x4ec4cc['toJSON']()),_0x58fdc5[_0x5ec97b('0x103b')]({'title':_0x5ec97b('0x1765'),'msg':_0x256aa2[_0x5ec97b('0x27e5')][_0x5ec97b('0x4f0')]?_0x256aa2[_0x5ec97b('0x27e5')][_0x5ec97b('0x4f0')]+_0x5ec97b('0x1eda'):''}),_0x140d82(_0x4ec4cc);})[_0x2ecc6a('0x1a80')](function(_0xd17264){const _0x35f576=_0x2ecc6a;if(_0xd17264['data']&&_0xd17264[_0x35f576('0x25f4')][_0x35f576('0x61a')]&&_0xd17264[_0x35f576('0x25f4')]['errors']['length']){_0x256aa2[_0x35f576('0x61a')]=_0xd17264[_0x35f576('0x25f4')]['errors']||[{'message':_0xd17264[_0x35f576('0x1586')](),'type':_0x35f576('0x24d0')}];for(let _0x24c47a=0x0;_0x24c47a<_0xd17264['data'][_0x35f576('0x61a')][_0x35f576('0x264b')];_0x24c47a+=0x1){_0x58fdc5['error']({'title':_0xd17264[_0x35f576('0x25f4')][_0x35f576('0x61a')][_0x24c47a][_0x35f576('0x1345')],'msg':_0xd17264[_0x35f576('0x25f4')][_0x35f576('0x61a')][_0x24c47a][_0x35f576('0x1e70')]});}}else _0x58fdc5['error']({'title':_0xd17264[_0x35f576('0x52d')]?_0x35f576('0x1e21')+_0xd17264[_0x35f576('0x52d')]+_0x35f576('0x11e1')+_0xd17264['statusText']:_0x35f576('0x24d0'),'msg':_0xd17264[_0x35f576('0x25f4')]?JSON['stringify'](_0xd17264[_0x35f576('0x25f4')][_0x35f576('0x1e70')]):_0xd17264[_0x35f576('0x1586')]()});});}function _0x4f0aaf(){const _0x52faee=_0x533de8;_0x256aa2[_0x52faee('0x61a')]=[],_0x3b55cd[_0x52faee('0x27e5')]['update']({'id':_0x256aa2[_0x52faee('0x27e5')]['id']},_0x256aa2[_0x52faee('0x27e5')])['$promise']['then'](function(_0x47202a){const _0x196042=_0x52faee,_0x2a1d2b=_0x2cfb05()[_0x196042('0xc38')](_0x256aa2['smsAccounts'],{'id':_0x47202a['id']});_0x2a1d2b&&_0x2cfb05()[_0x196042('0xcc3')](_0x2a1d2b,_0x2cfb05()['pick'](_0x47202a[_0x196042('0x2876')](),_0x2cfb05()['keys'](_0x2a1d2b))),_0x58fdc5[_0x196042('0x103b')]({'title':_0x196042('0xce5'),'msg':_0x256aa2[_0x196042('0x27e5')][_0x196042('0x4f0')]?_0x256aa2[_0x196042('0x27e5')][_0x196042('0x4f0')]+_0x196042('0x7d'):''}),_0x140d82(_0x47202a);})[_0x52faee('0x1a80')](function(_0x306b6f){const _0x1a8933=_0x52faee;if(_0x306b6f[_0x1a8933('0x25f4')]&&_0x306b6f[_0x1a8933('0x25f4')][_0x1a8933('0x61a')]&&_0x306b6f[_0x1a8933('0x25f4')][_0x1a8933('0x61a')]['length']){_0x256aa2[_0x1a8933('0x61a')]=_0x306b6f[_0x1a8933('0x25f4')][_0x1a8933('0x61a')]||[{'message':_0x306b6f[_0x1a8933('0x1586')](),'type':_0x1a8933('0x1a36')}];for(let _0x891bdf=0x0;_0x891bdf<_0x306b6f[_0x1a8933('0x25f4')]['errors'][_0x1a8933('0x264b')];_0x891bdf++){_0x58fdc5[_0x1a8933('0xfc9')]({'title':_0x306b6f[_0x1a8933('0x25f4')][_0x1a8933('0x61a')][_0x891bdf]['type'],'msg':_0x306b6f[_0x1a8933('0x25f4')][_0x1a8933('0x61a')][_0x891bdf][_0x1a8933('0x1e70')]});}}else _0x58fdc5['error']({'title':_0x306b6f[_0x1a8933('0x52d')]?_0x1a8933('0x1e21')+_0x306b6f[_0x1a8933('0x52d')]+_0x1a8933('0x11e1')+_0x306b6f[_0x1a8933('0xe1b')]:_0x1a8933('0x1a36'),'msg':_0x306b6f[_0x1a8933('0x25f4')]?JSON[_0x1a8933('0xbac')](_0x306b6f[_0x1a8933('0x25f4')][_0x1a8933('0x1e70')]):_0x306b6f[_0x1a8933('0x1586')]()});});}function _0x2b188e(_0x19a779){const _0x44daf8=_0x533de8;_0x256aa2[_0x44daf8('0x61a')]=[];const _0x1ce3b4=_0x189cf4[_0x44daf8('0x1d26')]()[_0x44daf8('0xcdc')](_0x44daf8('0x7fb'))[_0x44daf8('0xacc')](_0x44daf8('0x1f51'))[_0x44daf8('0x8e8')](_0x44daf8('0xa8d'))['ok'](_0x44daf8('0x18'))[_0x44daf8('0x3f')](_0x44daf8('0x497'))[_0x44daf8('0x203b')](_0x19a779);_0x189cf4[_0x44daf8('0x1f80')](_0x1ce3b4)[_0x44daf8('0x1166')](function(){const _0x536524=_0x44daf8;_0x3b55cd[_0x536524('0x27e5')][_0x536524('0x906')]({'id':_0x256aa2['smsAccount']['id']})[_0x536524('0xa44')]['then'](function(){const _0x31cc0e=_0x536524;_0x2cfb05()[_0x31cc0e('0x127f')](_0x256aa2[_0x31cc0e('0x1d76')],{'id':_0x256aa2['smsAccount']['id']}),_0x58fdc5[_0x31cc0e('0x103b')]({'title':'SmsAccount\x20properly\x20deleted!','msg':(_0x256aa2[_0x31cc0e('0x27e5')]['name']||_0x31cc0e('0x27e5'))+_0x31cc0e('0x7cd')}),_0x140d82(_0x256aa2[_0x31cc0e('0x27e5')]);})[_0x536524('0x1a80')](function(_0x171033){const _0x3dd191=_0x536524;if(_0x171033[_0x3dd191('0x25f4')]&&_0x171033[_0x3dd191('0x25f4')][_0x3dd191('0x61a')]&&_0x171033[_0x3dd191('0x25f4')][_0x3dd191('0x61a')]['length']){_0x256aa2[_0x3dd191('0x61a')]=_0x171033[_0x3dd191('0x25f4')][_0x3dd191('0x61a')]||[{'message':_0x171033['toString'](),'type':_0x3dd191('0x579')}];for(let _0x478c8a=0x0;_0x478c8a<_0x171033[_0x3dd191('0x25f4')][_0x3dd191('0x61a')][_0x3dd191('0x264b')];_0x478c8a++){_0x58fdc5['error']({'title':_0x171033[_0x3dd191('0x25f4')][_0x3dd191('0x61a')][_0x478c8a]['type'],'msg':_0x171033['data'][_0x3dd191('0x61a')][_0x478c8a][_0x3dd191('0x1e70')]});}}else _0x58fdc5['error']({'title':_0x171033['status']?_0x3dd191('0x1e21')+_0x171033[_0x3dd191('0x52d')]+_0x3dd191('0x11e1')+_0x171033[_0x3dd191('0xe1b')]:'api.smsAccount.delete','msg':_0x171033['data']?JSON[_0x3dd191('0xbac')](_0x171033[_0x3dd191('0x25f4')][_0x3dd191('0x1e70')]):_0x171033[_0x3dd191('0x1e70')]||_0x171033[_0x3dd191('0x1586')]()});});},function(){});}function _0xc8bed1(_0x40e27a){return _0x40e27a===null?undefined:new Date(_0x40e27a);}function _0x140d82(_0x24b073){_0x189cf4['hide'](_0x24b073);}}const _0x2eabf2=_0x8aa11,_0x5d30e3=_0x2734b2['p']+_0x36e6f4('0x1954'),_0x3909bf=_0x2734b2['p']+_0x36e6f4('0x37c'),_0x5d2bd5=_0x2734b2['p']+_0x36e6f4('0x11d3'),_0x225905=_0x2734b2['p']+_0x36e6f4('0x86e'),_0x463e90=_0x2734b2['p']+_0x36e6f4('0x1931'),_0x50428e=_0x2734b2['p']+'src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/gotoif/dialog.html/dialog.html',_0x24ec52=_0x2734b2['p']+'src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/gotop/dialog.html/dialog.html',_0x395dc1=_0x2734b2['p']+_0x36e6f4('0x19e0'),_0x1b705f=_0x2734b2['p']+_0x36e6f4('0x26df'),_0x55bf0e=_0x2734b2['p']+'src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/queue/dialog.html/dialog.html',_0xe893a6=_0x2734b2['p']+'src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/system/dialog.html/dialog.html',_0x4255e3=_0x2734b2['p']+_0x36e6f4('0x1ce0');_0x307793[_0x36e6f4('0x1294')]=[_0x36e6f4('0x19e3'),_0x36e6f4('0x265d'),'$document','toasty',_0x36e6f4('0x21ef')];const _0x120d5={'agent':_0x5d30e3,'amazonlex':_0x3909bf,'autoreply':_0x5d2bd5,'close':_0x225905,'dialogflow':_0x463e90,'gotoif':_0x50428e,'gotop':_0x24ec52,'interval':_0x395dc1,'noop':_0x1b705f,'queue':_0x55bf0e,'system':_0xe893a6,'tag':_0x4255e3};function _0x307793(_0x1e6da6,_0x548d68,_0x440385,_0x4877e7,_0x1065be){const _0x115158=_0x36e6f4,_0x1ecef6=this;_0x1ecef6['currentUser']=_0x1065be[_0x115158('0x26cd')](),_0x1ecef6[_0x115158('0x27e5')]={},_0x1ecef6[_0x115158('0x1785')]={'count':0x0,'rows':[]},_0x1ecef6[_0x115158('0xd9')]=[],_0x1ecef6['crudPermissions'],_0x1ecef6[_0x115158('0x2218')]={'sort':'priority'},_0x1ecef6[_0x115158('0x24d2')]=_0x2cfb05()['reject'](_0x2cfb05()[_0x115158('0x1eba')]([{'app':_0x115158('0x1545'),'appType':'interval','types':[_0x115158('0x597'),_0x115158('0x2853'),_0x115158('0x1480')],'fields':[],'isApp':![]},{'app':_0x115158('0x2652'),'appType':_0x115158('0x2652'),'type':_0x115158('0x2652'),'icon':_0x115158('0x283f'),'interval':_0x115158('0x16f'),'required':!![],'isApp':!![],'fields':[{'title':'Value','name':_0x115158('0x18e0'),'type':'text','param':0x0}]},{'app':'system','appType':_0x115158('0x1c2b'),'type':_0x115158('0x1c2b'),'icon':_0x115158('0x283f'),'interval':'*,*,*,*','required':!![],'isApp':!![],'extraApi':[{'name':_0x115158('0x57a'),'field':{'name':'variable','key':'name'},'route':_0x115158('0x734'),'filters':{'fields':_0x115158('0x1776'),'sort':_0x115158('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':_0x115158('0xd5'),'name':_0x115158('0x187'),'type':_0x115158('0x1640'),'required':!![],'param':0x0},{'title':_0x115158('0x2d5'),'name':_0x115158('0x734'),'type':'apiselect','values':_0x115158('0x57a'),'value':_0x115158('0x15f0'),'option':_0x115158('0x15f0'),'defaultValues':[{'value':'\x27\x27','option':_0x115158('0x1280')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':_0x115158('0x6e6'),'appType':'gotop','type':_0x115158('0x1a03'),'icon':_0x115158('0x283f'),'interval':_0x115158('0x16f'),'isApp':!![],'fields':[{'title':_0x115158('0x9c2'),'name':_0x115158('0xfde'),'type':_0x115158('0xc45'),'required':!![],'min':0x0,'param':0x0}]},{'app':_0x115158('0x30f'),'appType':_0x115158('0x30f'),'type':_0x115158('0x30f'),'icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x115158('0x1cdc'),'name':_0x115158('0x8ff'),'type':_0x115158('0x1640'),'required':!![],'param':0x0},{'title':_0x115158('0x13a6'),'name':_0x115158('0x13a6'),'type':'number','min':0x1,'required':!![],'param':0x1},{'title':_0x115158('0x1d7a'),'name':'falsepriority','type':_0x115158('0xc45'),'min':0x1,'required':!![],'param':0x2}]},{'app':_0x115158('0x1d3e'),'appType':_0x115158('0x1d3e'),'foreignKey':'SmsQueueId','type':_0x115158('0x1d3e'),'icon':_0x115158('0x283f'),'interval':_0x115158('0x16f'),'isApp':!![],'extraApi':[{'name':_0x115158('0x7a7'),'field':{'name':_0x115158('0x1d3e'),'key':_0x115158('0x4f0')},'route':_0x115158('0x73c'),'filters':{'fields':_0x115158('0x1c09'),'sort':_0x115158('0x4f0'),'nolimit':!![]},'permissions':{'section':0x2bd}}],'fields':[{'title':'Queue','name':'queue','type':_0x115158('0x2550'),'values':_0x115158('0x7a7'),'value':_0x115158('0x24ad'),'option':_0x115158('0x24ad'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':'Timeout','name':_0x115158('0x651'),'type':_0x115158('0xc45'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x12c,'param':0x1}]},{'app':'agent','appType':_0x115158('0x1eff'),'type':_0x115158('0x1eff'),'foreignKey':_0x115158('0x122a'),'icon':_0x115158('0x283f'),'interval':_0x115158('0x16f'),'isApp':!![],'extraApi':[{'name':_0x115158('0x1f7e'),'field':{'name':_0x115158('0x1eff'),'key':_0x115158('0x4f0')},'route':'user','filters':{'fields':_0x115158('0x1776'),'sort':_0x115158('0x4f0'),'nolimit':!![],'role':_0x115158('0x1eff')},'permissions':{'section':0xca}}],'fields':[{'title':_0x115158('0x89b'),'name':'agent','type':_0x115158('0x2550'),'values':_0x115158('0x1f7e'),'value':_0x115158('0x1530'),'option':_0x115158('0x1530'),'required':!![],'param':0x0},{'title':'Timeout','name':_0x115158('0x651'),'type':'number','max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':_0x115158('0x1af7'),'appType':_0x115158('0x1af7'),'type':'autoreply','icon':'icon-apps','interval':_0x115158('0x16f'),'isApp':!![],'fields':[{'title':_0x115158('0x265e'),'name':'times','type':_0x115158('0x88a'),'defaultValue':'1','values':[{'option':_0x115158('0xbe0'),'value':'1'},{'option':_0x115158('0x70f'),'value':'0'}],'required':!![],'param':0x0},{'title':_0x115158('0xef7'),'name':_0x115158('0x1640'),'type':_0x115158('0x489'),'required':!![],'param':0x1}]},{'app':_0x115158('0x1a7b'),'appType':'close','type':_0x115158('0x1a7b'),'icon':_0x115158('0x283f'),'interval':_0x115158('0x16f'),'isApp':!![],'fields':[{'title':_0x115158('0x9b9'),'name':_0x115158('0x12e8'),'type':_0x115158('0x1640'),'required':!![],'param':0x0}]},{'app':_0x115158('0x1446'),'appType':'tag','type':_0x115158('0x1446'),'foreignKey':_0x115158('0x8f5'),'icon':_0x115158('0x283f'),'interval':_0x115158('0x16f'),'isApp':!![],'extraApi':[{'name':_0x115158('0xb38'),'field':{'name':_0x115158('0x1446'),'key':_0x115158('0x4f0')},'route':_0x115158('0x1446'),'filters':{'fields':_0x115158('0x1776'),'sort':_0x115158('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x115158('0x1b35'),'name':_0x115158('0x1446'),'type':_0x115158('0x2550'),'values':_0x115158('0xb38'),'value':'tag.name','option':'tag.name','required':!![],'param':0x0}]},{'app':_0x115158('0xded'),'appType':_0x115158('0xded'),'type':_0x115158('0xded'),'icon':_0x115158('0x283f'),'interval':_0x115158('0x16f'),'isApp':!![],'fields':[{'title':_0x115158('0x2eb'),'name':_0x115158('0x7ca'),'type':'text','required':!![],'param':0x0},{'title':_0x115158('0xedb'),'name':_0x115158('0xedb'),'type':_0x115158('0x88a'),'defaultValue':_0x115158('0x17bf'),'values':[{'option':_0x115158('0x7a4'),'value':_0x115158('0xacf')},{'option':'English','value':'\x27en\x27'},{'option':_0x115158('0x20f'),'value':_0x115158('0x15bd')},{'option':_0x115158('0x1a40'),'value':_0x115158('0x1dd3')},{'option':'Spanish','value':_0x115158('0x14d0')},{'option':_0x115158('0x2746'),'value':_0x115158('0x5f0')},{'option':_0x115158('0xebe'),'value':'\x27id\x27'},{'option':_0x115158('0x2688'),'value':_0x115158('0x1764')},{'option':_0x115158('0x347'),'value':_0x115158('0x82e')},{'option':'Dutch','value':_0x115158('0x4f5')},{'option':_0x115158('0x522'),'value':_0x115158('0x119b')},{'option':_0x115158('0x0'),'value':_0x115158('0x145d')},{'option':_0x115158('0x2528'),'value':_0x115158('0x1136')},{'option':_0x115158('0xf22'),'value':'\x27ru\x27'},{'option':_0x115158('0x277e'),'value':'\x27sv\x27'},{'option':'Thai','value':_0x115158('0x1d2b')},{'option':_0x115158('0xd6b'),'value':_0x115158('0x38e')},{'option':_0x115158('0xefc'),'value':_0x115158('0x244a')},{'option':_0x115158('0x8d9'),'value':_0x115158('0x21c7')},{'option':_0x115158('0x145a'),'value':'\x27zh-TW\x27'}],'required':!![],'param':0x1},{'title':_0x115158('0x1634'),'name':_0x115158('0x1634'),'type':'textarea','maxlength':0xff,'required':![],'param':0x2,'help':!![]}]},{'app':_0x115158('0x12fa'),'appType':_0x115158('0x1636'),'type':_0x115158('0x1636'),'icon':_0x115158('0x283f'),'interval':_0x115158('0x16f'),'isApp':!![],'fields':[{'title':_0x115158('0x23'),'name':'projectId','type':_0x115158('0x1640'),'required':!![],'param':0x0},{'title':'ClientEmail','name':_0x115158('0x27f3'),'type':_0x115158('0x1640'),'required':!![],'param':0x1},{'title':_0x115158('0x17dd'),'name':_0x115158('0x170e'),'type':_0x115158('0x489'),'required':!![],'param':0x2},{'title':'language','name':_0x115158('0xedb'),'type':_0x115158('0x88a'),'defaultValue':_0x115158('0x17bf'),'values':[{'value':'\x27zh-HK\x27','option':_0x115158('0x2837')},{'value':_0x115158('0x244a'),'option':_0x115158('0xefc')},{'value':_0x115158('0x2348'),'option':_0x115158('0x145a')},{'value':_0x115158('0xacf'),'option':_0x115158('0x7a4')},{'value':_0x115158('0x4f5'),'option':_0x115158('0x1025')},{'value':_0x115158('0x17bf'),'option':'English'},{'value':_0x115158('0x457'),'option':_0x115158('0x27a0')},{'value':'\x27en-CA\x27','option':_0x115158('0x28b8')},{'value':_0x115158('0x60d'),'option':_0x115158('0x1cdd')},{'value':'\x27en-IN\x27','option':_0x115158('0x655')},{'value':'\x27en-US\x27','option':_0x115158('0x1f4')},{'value':_0x115158('0x5f0'),'option':_0x115158('0x2746')},{'value':_0x115158('0x391'),'option':'French\x20(Canada)'},{'value':_0x115158('0x1cb9'),'option':_0x115158('0x18e4')},{'value':_0x115158('0x15bd'),'option':_0x115158('0x20f')},{'value':_0x115158('0x9bd'),'option':'Hindi'},{'value':_0x115158('0x2872'),'option':'Indonesian'},{'value':_0x115158('0x1dd3'),'option':_0x115158('0x1a40')},{'value':_0x115158('0x1764'),'option':_0x115158('0x2688')},{'value':_0x115158('0x82e'),'option':_0x115158('0x511')},{'value':'\x27no\x27','option':'Norwegian'},{'value':_0x115158('0x27c'),'option':_0x115158('0x19b3')},{'value':'\x27pt-BR\x27','option':_0x115158('0x702')},{'value':'\x27pt-PT\x27','option':_0x115158('0x1336')},{'value':_0x115158('0x543'),'option':_0x115158('0xf22')},{'value':_0x115158('0x14d0'),'option':'Spanish'},{'value':_0x115158('0x14e3'),'option':_0x115158('0x9e5')},{'value':_0x115158('0x1cfa'),'option':'Spanish\x20(Spain)'},{'value':_0x115158('0x1ae8'),'option':'Swedish'},{'value':_0x115158('0x1d2b'),'option':_0x115158('0x24f9')},{'value':_0x115158('0x1d58'),'option':_0x115158('0x71a')},{'value':_0x115158('0x38e'),'option':_0x115158('0xd6b')}],'required':!![],'param':0x3},{'title':_0x115158('0x1634'),'name':_0x115158('0x1634'),'type':'textarea','maxlength':0xff,'param':0x4,'help':!![]}]},{'app':_0x115158('0x86c'),'appType':_0x115158('0x86c'),'type':'amazonlex','icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x115158('0xee6'),'name':_0x115158('0xee6'),'type':'text','required':!![],'param':0x0},{'title':_0x115158('0x125'),'name':_0x115158('0x125'),'type':_0x115158('0x1640'),'required':!![],'param':0x1},{'title':_0x115158('0x25a2'),'name':_0x115158('0x25a2'),'type':_0x115158('0x88a'),'defaultValue':_0x115158('0x2891'),'values':[{'option':'US\x20East\x20(N.\x20Virginia)','value':'\x27us-east-1\x27'},{'option':'US\x20West\x20(Oregon)','value':_0x115158('0x27b2')},{'option':_0x115158('0x5b3'),'value':'\x27eu-west-1\x27'},{'option':_0x115158('0xac9'),'value':'\x27ap-southeast-2\x27'}],'required':!![],'param':0x2},{'title':_0x115158('0x1ac4'),'name':'botname','type':_0x115158('0x1640'),'required':!![],'param':0x3},{'title':_0x115158('0x1634'),'name':_0x115158('0x1634'),'type':_0x115158('0x489'),'maxlength':0xff,'required':![],'param':0x4,'help':!![]}]}],[_0x115158('0x746')]),{'isApp':![]}),_0x1ecef6[_0x115158('0x1480')]={'group':{'name':'opt1','pull':_0x115158('0xddc')},'animation':0x64,'sort':![]},_0x1ecef6['applications']={'group':{'name':_0x115158('0x103e'),'put':'opt1'},'animation':0x64,'onAdd':function(_0x15aaf5){_0x4af8(_0x15aaf5,_0x15aaf5['newIndex']);},'onSort':function(){_0xbda157();}},_0x1ecef6[_0x115158('0x24d5')]=_0x16803d,_0x1ecef6[_0x115158('0x8a2')]=_0x47d38a,_0x1ecef6['getSmsAccountApps']=_0x3aafbc,_0x1ecef6[_0x115158('0x20ec')]=_0x4af8,_0x1ecef6[_0x115158('0x1a93')]=_0x427e41,_0x1ecef6[_0x115158('0xe6f')]=_0x5971c1,_0x1ecef6[_0x115158('0x283d')]=_0x407221,_0x1ecef6[_0x115158('0x20a6')]=_0xbda157,_0x1ecef6[_0x115158('0x242')]=_0x45ef08;function _0x16803d(_0x18109b,_0x5382e2){const _0x574937=_0x115158;_0x1ecef6[_0x574937('0x27e5')]=_0x18109b,_0x1ecef6['crudPermissions']=typeof _0x5382e2!=='undefined'?_0x5382e2:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1ecef6[_0x574937('0x227f')][_0x574937('0xbd0')]=!_0x1ecef6['crudPermissions']['canEdit']?!![]:![],_0x1ecef6[_0x574937('0x2218')]['id']=_0x18109b['id'],_0x1ecef6[_0x574937('0x2218')][_0x574937('0x1a55')]=!![],_0x1ecef6[_0x574937('0x2218')]['nolimit']=!![],_0x1ecef6[_0x574937('0xad9')](),_0x1ecef6['getIntervals']();}function _0x47d38a(_0x2c6258,_0x368d4f,_0x2aaa5e){const _0x1dc645=_0x115158,_0x15209f=_0x548d68[_0x1dc645('0x1d26')]()[_0x1dc645('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20application?')[_0x1dc645('0xf3c')](''+_0x2c6258['app']+_0x1dc645('0xace')+_0x1dc645('0x3f3'))[_0x1dc645('0x8e8')](_0x1dc645('0x238d'))[_0x1dc645('0x203b')](_0x2aaa5e)['ok']('OK')[_0x1dc645('0x3f')]('CANCEL');_0x548d68['show'](_0x15209f)[_0x1dc645('0x1166')](function(){const _0x40a43d=_0x1dc645;_0x1ecef6[_0x40a43d('0x1785')][_0x40a43d('0x269a')][_0x40a43d('0x57b')](_0x368d4f,0x1),_0xbda157();},function(){console['log']('CANCEL');});}function _0x4af8(_0x14a7f0,_0x2d727d){const _0x5112f9=_0x115158;if(_0x1ecef6['smsAccountApps'][_0x5112f9('0x269a')][_0x5112f9('0x264b')]){const _0x82e202=_0x1ecef6[_0x5112f9('0x1785')][_0x5112f9('0x269a')][_0x2d727d]?_0x1ecef6[_0x5112f9('0x1785')][_0x5112f9('0x269a')][_0x2d727d]:_0x1ecef6['smsAccountApps'][_0x5112f9('0x269a')][0x0],_0x4ff999=(_0x82e202[_0x5112f9('0x83f')]||_0x82e202['app'])[_0x5112f9('0x2574')]();_0x548d68[_0x5112f9('0x1f80')]({'controller':_0x5112f9('0x1964')+_0x4ff999+_0x5112f9('0x8a4'),'controllerAs':'vm','templateUrl':_0x120d5[_0x4ff999],'parent':angular[_0x5112f9('0x1194')](_0x440385[_0x5112f9('0x8d2')]),'targetEvent':_0x14a7f0,'clickOutsideToClose':!![],'locals':{'smsAccountApp':_0x82e202,'smsAccount':_0x1ecef6[_0x5112f9('0x27e5')],'crudPermissions':_0x1ecef6[_0x5112f9('0x243c')]}})['then'](function(_0x43b392){const _0x538874=_0x5112f9;_0x43b392&&(_0x43b392['id']?_0x1ecef6[_0x538874('0x1785')][_0x538874('0x269a')][_0x2d727d]=_0x43b392:_0x1ecef6[_0x538874('0x1785')]['rows'][_0x538874('0x57b')](_0x2d727d,0x0,_0x43b392),_0xbda157());})[_0x5112f9('0x1a80')](function(_0x4c1f79){const _0x118137=_0x5112f9;_0x4c1f79&&_0x4877e7[_0x118137('0xfc9')]({'title':_0x4c1f79[_0x118137('0x52d')]?_0x118137('0x1e21')+_0x4c1f79['status']+_0x118137('0x11e1')+_0x4c1f79['statusText']:_0x118137('0x2e5'),'msg':_0x4c1f79['data']?JSON['stringify'](_0x4c1f79[_0x118137('0x25f4')]):_0x4c1f79[_0x118137('0x1586')]()});});}}function _0x427e41(_0x16a89e,_0x4c23f0){const _0x931d51=_0x115158;if(_0x1ecef6[_0x931d51('0x1785')][_0x931d51('0x269a')][_0x931d51('0x264b')]){const _0x2505f6=_0x1ecef6[_0x931d51('0x1785')]['rows'][_0x4c23f0]?_0x1ecef6[_0x931d51('0x1785')][_0x931d51('0x269a')][_0x4c23f0]:_0x1ecef6[_0x931d51('0x1785')][_0x931d51('0x269a')][0x0];_0x548d68[_0x931d51('0x1f80')]({'controller':_0x931d51('0x774'),'controllerAs':'vm','templateUrl':_0x395dc1,'parent':angular[_0x931d51('0x1194')](_0x440385['body']),'targetEvent':_0x16a89e,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x2505f6[_0x931d51('0x277c')],'IntervalId':_0x2505f6['IntervalId'],'application':!![]},'intervals':[],'crudPermissions':_0x1ecef6[_0x931d51('0x243c')]}})[_0x931d51('0x1166')](function(_0x32ba7e){const _0x1c985b=_0x931d51;_0x32ba7e&&(_0x2505f6[_0x1c985b('0x277c')]=_0x32ba7e[_0x1c985b('0x277c')]||_0x1c985b('0x16f'),_0x2505f6['IntervalId']=_0x32ba7e[_0x1c985b('0x186f')]||null,_0xbda157());});}}function _0xbda157(){const _0x2f5833=_0x115158;let _0x36952f=0x1,_0x12ae24=[];for(let _0x5e989e=0x0;_0x5e989e<_0x1ecef6['smsAccountApps'][_0x2f5833('0x269a')]['length'];_0x5e989e++){const _0x50d62c=_0x1ecef6['smsAccountApps']['rows'][_0x5e989e],_0x3a01d9=[],_0x1af2ae=[];_0x50d62c[_0x2f5833('0x164e')]=_0x50d62c['interval']!=='*,*,*,*'?[_0x50d62c[_0x2f5833('0x277c')]]:_0x50d62c[_0x2f5833('0x186f')]?_0x2cfb05()[_0x2f5833('0x2563')](_0x2cfb05()[_0x2f5833('0x1c33')](_0x1ecef6[_0x2f5833('0x164e')]['rows'],{'IntervalId':_0x50d62c[_0x2f5833('0x186f')]}),_0x2f5833('0x277c')):[],_0x50d62c[_0x2f5833('0xe1c')]=_0x1ecef6[_0x2f5833('0x27e5')][_0x2f5833('0xe1c')],_0x50d62c['exten']=_0x1ecef6[_0x2f5833('0x27e5')][_0x2f5833('0x23ae')],_0x50d62c[_0x2f5833('0x1345')]&&(_0x50d62c['type']=_0x50d62c['type'][_0x2f5833('0x2574')]()),_0x50d62c[_0x2f5833('0xfde')]=_0x3a01d9['length']?_0x2cfb05()[_0x2f5833('0x1ef5')](_0x3a01d9)['priority']+0x1:_0x36952f,_0x36952f=(_0x1af2ae[_0x2f5833('0x264b')]?_0x2cfb05()[_0x2f5833('0x1ef5')](_0x1af2ae)[_0x2f5833('0xfde')]:_0x50d62c[_0x2f5833('0xfde')])+0x1,_0x12ae24=_0x2cfb05()[_0x2f5833('0x1c6a')](_0x12ae24,_0x3a01d9,[_0x50d62c],_0x1af2ae);}_0x1e6da6[_0x2f5833('0x27e5')][_0x2f5833('0x153b')]({'id':_0x1ecef6[_0x2f5833('0x27e5')]['id']},_0x2cfb05()[_0x2f5833('0x1eba')](_0x12ae24,_0x2f5833('0xfde')))[_0x2f5833('0xa44')][_0x2f5833('0x1166')](function(_0x28c304){const _0x31a146=_0x2f5833;_0x1ecef6[_0x31a146('0x1785')]['rows']=_0x28c304[_0x31a146('0x269a')];})[_0x2f5833('0x1a80')](function(_0x220dfe){console['error'](_0x220dfe);});}function _0x1ab2bb(_0x1b3549){const _0xca8369=_0x115158;_0x1ecef6[_0xca8369('0x1785')]=_0x1b3549||{'count':0x0,'rows':[]};}function _0x45ef08(){const _0x459ffd=_0x115158;return _0x1e6da6[_0x459ffd('0x277c')][_0x459ffd('0xd83')]({'fields':_0x459ffd('0x1d39')})[_0x459ffd('0xa44')][_0x459ffd('0x1166')](function(_0x1a6d1a){const _0x31f274=_0x459ffd;_0x1ecef6[_0x31f274('0x164e')]=_0x1a6d1a;})['catch'](function(_0x4ddb97){console['error'](_0x4ddb97);});}function _0x3aafbc(){const _0x3b8a20=_0x115158;_0x1ecef6['promise']=_0x1e6da6[_0x3b8a20('0x27e5')][_0x3b8a20('0x10e0')](_0x1ecef6[_0x3b8a20('0x2218')],_0x1ab2bb)[_0x3b8a20('0xa44')];}function _0x5971c1(_0x4df465){const _0x496aa5=_0x115158;_0x2cfb05()[_0x496aa5('0x127f')](_0x1ecef6['smsAccountApps'][_0x496aa5('0x269a')],{'id':_0x4df465['id']}),_0xbda157(),_0x4877e7[_0x496aa5('0x103b')]({'title':_0x496aa5('0x11c0'),'msg':_0x4df465['app']?_0x4df465[_0x496aa5('0x746')]+_0x496aa5('0x7cd'):''});}function _0x407221(_0x20db05){const _0x39ce34=_0x115158,_0x408feb=_0x548d68[_0x39ce34('0x1d26')]()[_0x39ce34('0xcdc')](_0x39ce34('0x2338'))[_0x39ce34('0xf3c')](_0x39ce34('0x12b5')+_0x1ecef6[_0x39ce34('0xd9')][_0x39ce34('0x264b')]+_0x39ce34('0x196d')+_0x39ce34('0x3f3'))[_0x39ce34('0x8e8')](_0x39ce34('0x106e'))[_0x39ce34('0x203b')](_0x20db05)['ok']('OK')['cancel'](_0x39ce34('0x2d3'));_0x548d68[_0x39ce34('0x1f80')](_0x408feb)[_0x39ce34('0x1166')](function(){const _0x47ee3d=_0x39ce34;_0x1ecef6['selectedSmsAccountApps'][_0x47ee3d('0x2782')](function(_0x57a3f0){const _0x2b9370=_0x47ee3d;_0x2cfb05()[_0x2b9370('0x127f')](_0x1ecef6['smsAccountApps'][_0x2b9370('0x269a')],{'id':_0x57a3f0['id']});}),_0x1ecef6[_0x47ee3d('0xd9')]=[],_0xbda157();});}}const _0x3c9a6e=_0x307793;_0x51ea62['$inject']=['$mdDialog','$q',_0x36e6f4('0x1d2e'),'api','smsAccount','smsAccounts',_0x36e6f4('0xf01'),_0x36e6f4('0x586'),'Auth',_0x36e6f4('0x243c')];function _0x51ea62(_0x2fa44b,_0x4ea1fa,_0x43aec7,_0x1d0856,_0x456f51,_0x319b99,_0x3c1616,_0x35a00d,_0x4972aa,_0x17e514){const _0x2aa812=_0x36e6f4,_0x11732c=this;_0x11732c[_0x2aa812('0x98')]=_0x4972aa[_0x2aa812('0x26cd')](),_0x11732c[_0x2aa812('0x27e5')]=_0x456f51,_0x11732c[_0x2aa812('0x243c')]=_0x17e514,_0x11732c[_0x2aa812('0xf01')]=_0x3c1616,_0x11732c[_0x2aa812('0xbd7')]=[],_0x11732c[_0x2aa812('0x10ab')]=[],_0x11732c[_0x2aa812('0x18e1')]=[],_0x11732c[_0x2aa812('0x2111')]=[],_0x11732c[_0x2aa812('0x2781')]=[],_0x11732c['pendingChanges']=![],_0x11732c[_0x2aa812('0xae0')]=_0x5d4657,_0x11732c[_0x2aa812('0x1d92')]=_0x2b096c,_0x11732c[_0x2aa812('0x24a0')]=_0x360117,_0x11732c['dualMultiselectOptions']={'readOnly':!_0x11732c['crudPermissions'][_0x2aa812('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x2aa812('0x4f0'),'line1':_0x2aa812('0x6e1'),'line2':[_0x2aa812('0x4f0'),'internal'],'line3':'','labelAll':_0x35a00d[_0x2aa812('0x25cc')]('SMS.ALL_AGENTS'),'labelSelected':_0x35a00d[_0x2aa812('0x25cc')](_0x2aa812('0xa72')),'transferCallback':function(){const _0x5cf218=_0x2aa812,_0x2e39b6=_0x2cfb05()[_0x5cf218('0x2802')](_0x11732c['startingSelectedItems'],_0x11732c[_0x5cf218('0x18e1')],'id');_0x11732c['pendingChanges']=_0x2cfb05()[_0x5cf218('0x1081')](_0x2e39b6)?![]:!![];}};function _0x5d4657(){const _0x2cf02a=_0x2aa812;return _0x4972aa['hasRole'](_0x2cf02a('0xa7c'))?_0x46f7f9()[_0x2cf02a('0x1a80')](function(_0x5bd0f8){const _0x3377b0=_0x2cf02a;_0x43aec7[_0x3377b0('0xfc9')]({'title':_0x5bd0f8['status']?_0x3377b0('0x1e21')+_0x5bd0f8[_0x3377b0('0x52d')]+'\x20-\x20'+_0x5bd0f8[_0x3377b0('0xe1b')]:'SYSTEM:GET_AGENTS','msg':_0x5bd0f8['status']?JSON['stringify'](_0x5bd0f8[_0x3377b0('0x25f4')]):_0x5bd0f8[_0x3377b0('0x1586')]()});}):_0x113a56()['then'](function(_0xe7f85d){const _0x158e96=_0x2cf02a;return _0x11732c[_0x158e96('0xe60')]=_0xe7f85d,_0x46f7f9();})[_0x2cf02a('0x1a80')](function(_0x44f847){const _0x532a39=_0x2cf02a;_0x43aec7[_0x532a39('0xfc9')]({'title':_0x44f847[_0x532a39('0x52d')]?_0x532a39('0x1e21')+_0x44f847[_0x532a39('0x52d')]+_0x532a39('0x11e1')+_0x44f847['statusText']:'SYSTEM:GET_AGENTS','msg':_0x44f847[_0x532a39('0x52d')]?JSON['stringify'](_0x44f847['data']):_0x44f847[_0x532a39('0x1586')]()});});}function _0x113a56(){return _0x4ea1fa(function(_0x46674c,_0x58221c){const _0x545387=a0_0x3f2c;_0x1d0856['userProfileSection'][_0x545387('0xd83')]({'userProfileId':_0x11732c['currentUser'][_0x545387('0xb86')],'name':'Agents'})[_0x545387('0xa44')][_0x545387('0x1166')](function(_0x51030d){const _0x185fd6=_0x51030d&&_0x51030d['rows']?_0x51030d['rows'][0x0]:null;_0x46674c(_0x185fd6);})[_0x545387('0x1a80')](function(_0x4df5ff){_0x58221c(_0x4df5ff);});});}function _0x46f7f9(){return _0x4ea1fa(function(_0x2988a1,_0x1102ee){const _0x43a794=a0_0x3f2c;return _0x4b3bf1()['then'](function(_0x2bbb42){const _0x5f27c3=a0_0x3f2c;return _0x11732c['items']=_0x2bbb42[_0x5f27c3('0x269a')]?_0x2bbb42[_0x5f27c3('0x269a')]:[],_0x4972aa[_0x5f27c3('0x1ac6')]('admin')?_0x2bbb42:_0x11732c['section']?_0x11732c[_0x5f27c3('0xe60')][_0x5f27c3('0x1a2b')]?_0x2bbb42:_0x3c0d5d():null;})[_0x43a794('0x1166')](function(_0x1d667f){const _0xa0c33e=_0x43a794,_0x1096e4=_0x1d667f&&_0x1d667f[_0xa0c33e('0x269a')]?_0x1d667f[_0xa0c33e('0x269a')]:[];return _0x11732c[_0xa0c33e('0x10ab')]=_0x2cfb05()[_0xa0c33e('0x2563')](_0x1096e4,function(_0x3c4bcf){const _0x50963b=_0xa0c33e;return _0x2cfb05()['find'](_0x11732c[_0x50963b('0xbd7')],{'id':_0x4972aa[_0x50963b('0x1ac6')](_0x50963b('0xa7c'))||_0x11732c[_0x50963b('0xe60')]['autoAssociation']?_0x3c4bcf['id']:_0x3c4bcf[_0x50963b('0x24e8')]});}),_0x11732c[_0xa0c33e('0x2111')]=angular[_0xa0c33e('0x225f')](_0x11732c['allowedItems']),_0x11732c['items']['forEach'](function(_0x5c562e){const _0x3a6ac7=_0xa0c33e,_0x404464=_0x2cfb05()[_0x3a6ac7('0xc38')](_0x11732c[_0x3a6ac7('0x10ab')],{'id':_0x5c562e['id']});_0x4972aa[_0x3a6ac7('0x1ac6')](_0x3a6ac7('0xa7c'))?_0x5c562e[_0x3a6ac7('0x26ef')]=!![]:_0x5c562e[_0x3a6ac7('0x26ef')]=typeof _0x404464!==_0x3a6ac7('0x1048')?!![]:![];}),_0x216f86();})[_0x43a794('0x1166')](function(_0x4d29bc){const _0x44ac1e=_0x43a794,_0x427979=_0x4d29bc&&_0x4d29bc[_0x44ac1e('0x269a')]?_0x4d29bc[_0x44ac1e('0x269a')]:[];_0x11732c[_0x44ac1e('0x18e1')]=_0x2cfb05()[_0x44ac1e('0x2563')](_0x427979,function(_0x2220e9){const _0x130aab=_0x44ac1e,_0x46ab79=_0x2cfb05()[_0x130aab('0xc38')](_0x11732c[_0x130aab('0xbd7')],{'id':_0x2220e9['id']});return _0x46ab79[_0x130aab('0x23af')]=_0x2220e9[_0x130aab('0x207a')]?'penalty\x20'+_0x2220e9[_0x130aab('0x207a')][_0x130aab('0x23af')]:'',_0x46ab79[_0x130aab('0x1eef')]=typeof _0x2220e9['internal']!==_0x130aab('0x1048')?'<'+_0x2220e9[_0x130aab('0x1eef')]+'>':'',_0x46ab79;}),_0x11732c[_0x44ac1e('0x2781')]=angular[_0x44ac1e('0x225f')](_0x11732c['selectedItems']),_0x11732c[_0x44ac1e('0xc68')][_0x44ac1e('0x18e1')]=_0x11732c[_0x44ac1e('0x18e1')],_0x11732c[_0x44ac1e('0xc68')][_0x44ac1e('0xbd7')]=_0x2cfb05()[_0x44ac1e('0x24ac')](_0x11732c['allowedItems'],_0x11732c[_0x44ac1e('0xc68')][_0x44ac1e('0x18e1')],'id'),_0x2988a1();})['catch'](function(_0x1ff458){_0x1102ee(_0x1ff458);});});}function _0x3c0d5d(){return _0x4ea1fa(function(_0x579b55,_0x8546fd){const _0xfde81d=a0_0x3f2c;return _0x1d0856['userProfileResource'][_0xfde81d('0xd83')]({'sectionId':_0x11732c[_0xfde81d('0xe60')]['id'],'nolimit':!![]})[_0xfde81d('0xa44')][_0xfde81d('0x1166')](function(_0x16c0f5){_0x579b55(_0x16c0f5);})['catch'](function(_0x50f305){_0x8546fd(_0x50f305);});});}function _0x216f86(){return _0x4ea1fa(function(_0x51f752,_0x4ef05e){const _0x279b88=a0_0x3f2c;return _0x1d0856[_0x279b88('0x27e5')][_0x279b88('0x261c')]({'id':_0x11732c[_0x279b88('0x27e5')]['id'],'fields':_0x279b88('0x1459'),'nolimit':!![],'role':'agent'})[_0x279b88('0xa44')][_0x279b88('0x1166')](function(_0x419d71){_0x51f752(_0x419d71);})[_0x279b88('0x1a80')](function(_0x55b037){_0x4ef05e(_0x55b037);});});}function _0x4b3bf1(){return _0x4ea1fa(function(_0x46e535,_0x5176f0){const _0x10670f=a0_0x3f2c;return _0x1d0856[_0x10670f('0x557')]['get']({'fields':_0x10670f('0x1459'),'nolimit':!![],'role':'agent'})[_0x10670f('0xa44')][_0x10670f('0x1166')](function(_0x1ca41c){_0x46e535(_0x1ca41c);})[_0x10670f('0x1a80')](function(_0x520e89){_0x5176f0(_0x520e89);});});}function _0x32e45f(_0x5667fc){return _0x4ea1fa(function(_0x2ee6f3,_0x52b77e){const _0xedd34b=a0_0x3f2c;_0x2cfb05()[_0xedd34b('0x1081')](_0x5667fc)?_0x2ee6f3():_0x1d0856[_0xedd34b('0x27e5')][_0xedd34b('0x275c')]({'id':_0x11732c[_0xedd34b('0x27e5')]['id'],'ids':_0x2cfb05()['map'](_0x5667fc,'id')})[_0xedd34b('0xa44')][_0xedd34b('0x1166')](function(){_0x2ee6f3();})[_0xedd34b('0x1a80')](function(_0x29727a){_0x52b77e(_0x29727a);});});}function _0x4f4426(_0x3e30af){return _0x4ea1fa(function(_0x81f26b,_0x44e033){const _0x9ffe05=a0_0x3f2c;_0x2cfb05()[_0x9ffe05('0x1081')](_0x3e30af)?_0x81f26b():_0x1d0856[_0x9ffe05('0x27e5')][_0x9ffe05('0x269d')]({'id':_0x11732c[_0x9ffe05('0x27e5')]['id'],'ids':_0x2cfb05()[_0x9ffe05('0x2563')](_0x3e30af,'id')})['$promise'][_0x9ffe05('0x1166')](function(){_0x81f26b();})['catch'](function(_0x5c6021){_0x44e033(_0x5c6021);});});}function _0x2b096c(){const _0x2c1d07=_0x2aa812,_0x175059=_0x2cfb05()[_0x2c1d07('0x24ac')](_0x11732c[_0x2c1d07('0x2781')],_0x11732c[_0x2c1d07('0x18e1')],'id'),_0x30b73f=_0x2cfb05()['differenceBy'](_0x11732c['selectedItems'],_0x11732c[_0x2c1d07('0x2781')],'id');return _0x4f4426(_0x175059)[_0x2c1d07('0x1166')](function(){return _0x32e45f(_0x30b73f);})[_0x2c1d07('0x1166')](function(){const _0x2b9f57=_0x2c1d07;_0x11732c[_0x2b9f57('0x14d7')]=![],_0x11732c['startingAllowedItems']=angular[_0x2b9f57('0x225f')](_0x11732c['allowedItems']),_0x11732c[_0x2b9f57('0x2781')]=angular[_0x2b9f57('0x225f')](_0x11732c['selectedItems']),_0x43aec7[_0x2b9f57('0x103b')]({'title':_0x2b9f57('0x983'),'msg':_0x2b9f57('0x1673')});})[_0x2c1d07('0x1a80')](function(_0x439d07){const _0x505f7b=_0x2c1d07;_0x43aec7[_0x505f7b('0xfc9')]({'title':_0x439d07[_0x505f7b('0x52d')]?_0x505f7b('0x1e21')+_0x439d07[_0x505f7b('0x52d')]+_0x505f7b('0x11e1')+_0x439d07['statusText']:_0x505f7b('0x1b29'),'msg':_0x439d07[_0x505f7b('0x52d')]?JSON[_0x505f7b('0xbac')](_0x439d07[_0x505f7b('0x25f4')]):_0x439d07['toString']()});});}function _0x360117(){const _0x22d48c=_0x2aa812;_0x2fa44b[_0x22d48c('0x1197')]();}}const _0x28c7cc=_0x51ea62;_0x2c4b8['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x22e0'),_0x36e6f4('0x27e5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x2c4b8(_0x4502b3,_0x4f2a02,_0x3dd8cf,_0x1ff039,_0x2b5a4e,_0x57ecb0,_0x2b23a3,_0x2ac78b){const _0x58ff90=_0x36e6f4,_0x54079a=this;_0x54079a[_0x58ff90('0x98')]=_0x2b23a3[_0x58ff90('0x26cd')](),_0x54079a['errors']=[],_0x54079a['title']=_0x58ff90('0xeb')+(_0x1ff039['appType']||_0x1ff039['app'])[_0x58ff90('0x1387')](),_0x54079a[_0x58ff90('0x1eff')]=angular[_0x58ff90('0x225f')](_0x1ff039),_0x54079a[_0x58ff90('0x243c')]=_0x2ac78b,_0x54079a[_0x58ff90('0x128b')]={};if(_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x823')])switch(_0x54079a[_0x58ff90('0x1eff')]['appType']?_0x54079a[_0x58ff90('0x1eff')]['appType'][_0x58ff90('0x2574')]():_0x54079a[_0x58ff90('0x1eff')]['app'][_0x58ff90('0x2574')]()){case _0x58ff90('0x2853'):break;case _0x58ff90('0xded'):{const _0x55643d=_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x823')][_0x58ff90('0x25c8')](',');_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x7ca')]=_0x55643d[0x0],_0x54079a['agent'][_0x58ff90('0xedb')]=_0x55643d[0x1],_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x1634')]=_0x55643d[_0x58ff90('0x233')](0x2,_0x55643d[_0x58ff90('0x264b')])[_0x58ff90('0x45a')](',');}break;case _0x58ff90('0x1636'):{const _0x5f5b0e=_0x54079a['agent']['appdata']['split'](',');_0x54079a['agent'][_0x58ff90('0x1b0a')]=_0x5f5b0e[0x0],_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x27f3')]=_0x5f5b0e[0x1],_0x54079a['agent'][_0x58ff90('0x170e')]=_0x5f5b0e[0x2],_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0xedb')]=_0x5f5b0e[0x3],_0x54079a[_0x58ff90('0x1eff')]['welcomemessage']=_0x5f5b0e[_0x58ff90('0x233')](0x4,_0x5f5b0e[_0x58ff90('0x264b')])[_0x58ff90('0x45a')](',');}break;case _0x58ff90('0x86c'):{const _0x457740=_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x823')][_0x58ff90('0x25c8')](',');_0x54079a[_0x58ff90('0x1eff')]['accesskeyid']=_0x457740[0x0],_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x125')]=_0x457740[0x1],_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x25a2')]=_0x457740[0x2],_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x1ac4')]=_0x457740[0x3],_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x1634')]=_0x457740[_0x58ff90('0x233')](0x4,_0x457740[_0x58ff90('0x264b')])[_0x58ff90('0x45a')](',');}break;case _0x58ff90('0x1af7'):{const _0x5d6e84=_0x54079a['agent'][_0x58ff90('0x823')][_0x58ff90('0x25c8')](',');_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x265e')]=isNaN(_0x5d6e84[0x0])?_0x5d6e84[0x0]:parseInt(_0x5d6e84[0x0],0xa),_0x54079a[_0x58ff90('0x1eff')]['text']=_0x5d6e84[_0x58ff90('0x233')](0x1,_0x5d6e84[_0x58ff90('0x264b')])[_0x58ff90('0x45a')](',');}break;case _0x58ff90('0x1e70'):_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x1640')]=_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x823')];break;case'set':_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x4f0')]=_0x54079a[_0x58ff90('0x1eff')]['appdata'][_0x58ff90('0x25c8')]('=')[0x0],_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x18e0')]=_0x54079a[_0x58ff90('0x1eff')]['appdata']['split']('=')[0x1];break;case'agi':_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x2588')]=_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x823')];break;default:{const _0x9005e3=_0x54079a['agent']['appdata'][_0x58ff90('0x25c8')](',');_0x54079a[_0x58ff90('0x1eff')]['agent']=_0x2cfb05()['isEmpty'](_0x9005e3[0x0])?_0x9005e3[0x0]:isNaN(_0x9005e3[0x0])?_0x9005e3[0x0]:parseInt(_0x9005e3[0x0],0xa),_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x651')]=_0x2cfb05()['isEmpty'](_0x9005e3[0x1])?_0x9005e3[0x1]:isNaN(_0x9005e3[0x1])?_0x9005e3[0x1]:parseInt(_0x9005e3[0x1],0xa);}break;}else _0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x651')]=0x1e;_0x54079a['agent'][_0x58ff90('0x1345')]&&_0x54079a['agent'][_0x58ff90('0x1345')][_0x58ff90('0x2574')]()===_0x58ff90('0x587')&&_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x83f')][_0x58ff90('0x2574')]()==='outbounddial'&&(_0x54079a['agent'][_0x58ff90('0x265a')]=_0x54079a[_0x58ff90('0x1eff')][_0x58ff90('0x2026')]?_0x54079a[_0x58ff90('0x1eff')]['phone'][_0x58ff90('0x25c8')]('$')[0x0]:undefined,_0x54079a['agent'][_0x58ff90('0x1f02')]=_0x54079a['agent']['callerID']?_0x58ff90('0xa4c')+_0x54079a[_0x58ff90('0x1eff')]['callerID']:undefined);_0x54079a['saveSmsAccountApp']=_0x1a1d6a,_0x54079a[_0x58ff90('0x24a0')]=_0x4fc51d,_0x2b23a3[_0x58ff90('0x1ac6')](_0x58ff90('0xa7c'))?_0x57ecb0[_0x58ff90('0x557')][_0x58ff90('0xd83')]({'fields':_0x58ff90('0x1776'),'sort':_0x58ff90('0x4f0'),'nolimit':_0x58ff90('0xf3b'),'role':'agent'})[_0x58ff90('0xa44')][_0x58ff90('0x1166')](function(_0x12552d){const _0x4a8910=_0x58ff90;_0x54079a[_0x4a8910('0x1f7e')]=_0x12552d[_0x4a8910('0x269a')]||[];})[_0x58ff90('0x1a80')](function(_0x11ce41){const _0x307af7=_0x58ff90;_0x3dd8cf[_0x307af7('0xfc9')]({'title':_0x11ce41[_0x307af7('0x52d')]?_0x307af7('0x1e21')+_0x11ce41[_0x307af7('0x52d')]+_0x307af7('0x11e1')+_0x11ce41[_0x307af7('0xe1b')]:_0x307af7('0xd4c'),'msg':_0x11ce41['data']?JSON[_0x307af7('0xbac')](_0x11ce41[_0x307af7('0x25f4')]):_0x11ce41[_0x307af7('0x1586')]()});}):_0x57ecb0[_0x58ff90('0x557')][_0x58ff90('0xd83')]({'fields':_0x58ff90('0x1776'),'sort':_0x58ff90('0x4f0'),'nolimit':_0x58ff90('0xf3b'),'role':_0x58ff90('0x1eff')})[_0x58ff90('0xa44')][_0x58ff90('0x1166')](function(_0x550561){const _0x57f6af=_0x58ff90;_0x54079a[_0x57f6af('0x1f7e')]=_0x550561['rows']||[];})[_0x58ff90('0x1166')](function(){const _0x3e33c9=_0x58ff90;return _0x57ecb0['userProfileSection']['get']({'userProfileId':_0x54079a[_0x3e33c9('0x98')][_0x3e33c9('0xb86')],'sectionId':0xca})['$promise'];})[_0x58ff90('0x1166')](function(_0x12c035){const _0x1d05fa=_0x58ff90,_0x45e43a=_0x12c035&&_0x12c035[_0x1d05fa('0x269a')]?_0x12c035['rows'][0x0]:null;if(!_0x45e43a){const _0x4cd874=[];let _0x5860ff=null;_0x54079a[_0x1d05fa('0x1eff')]&&(_0x5860ff=_0x2cfb05()['find'](_0x54079a[_0x1d05fa('0x1f7e')],{'name':_0x54079a[_0x1d05fa('0x1eff')]['agent']}));for(let _0x3e7fa8=0x0;_0x3e7fa8<_0x54079a[_0x1d05fa('0x1f7e')][_0x1d05fa('0x264b')];_0x3e7fa8++){_0x5860ff&&_0x54079a['agents'][_0x3e7fa8]['id']===_0x5860ff['id']&&(_0x54079a['agents'][_0x3e7fa8][_0x1d05fa('0x2378')]=![],_0x4cd874[_0x1d05fa('0x1514')](_0x54079a[_0x1d05fa('0x1f7e')][_0x3e7fa8]));}_0x54079a['agents']=_0x4cd874;}else{if(!_0x45e43a['autoAssociation'])return _0x57ecb0[_0x1d05fa('0x4b5')][_0x1d05fa('0xd83')]({'sectionId':_0x45e43a['id']})[_0x1d05fa('0xa44')][_0x1d05fa('0x1166')](function(_0x3eac56){const _0x2e796c=_0x1d05fa,_0xc249ff=_0x2cfb05()['map'](_0x3eac56[_0x2e796c('0x269a')],function(_0x3aff9b){const _0x2704c6=_0x2e796c;return _0x2cfb05()[_0x2704c6('0xc38')](_0x54079a[_0x2704c6('0x1f7e')],{'id':_0x3aff9b['resourceId']});});let _0x125b0b=null;_0x54079a[_0x2e796c('0x1eff')]&&(_0x125b0b=_0x2cfb05()[_0x2e796c('0xc38')](_0x54079a['agents'],{'name':_0x54079a[_0x2e796c('0x1eff')][_0x2e796c('0x1eff')]}));if(_0x125b0b&&!_0x2cfb05()[_0x2e796c('0x1798')](_0xc249ff,['id',_0x125b0b['id']])){const _0x3884b6=_0x2cfb05()[_0x2e796c('0xc38')](_0x54079a[_0x2e796c('0x1f7e')],{'id':_0x125b0b['id']});_0x3884b6[_0x2e796c('0x2378')]=![],_0xc249ff['push'](_0x3884b6);}_0x54079a['agents']=_0xc249ff;});}})[_0x58ff90('0x1a80')](function(_0x588678){const _0x477afb=_0x58ff90;_0x3dd8cf[_0x477afb('0xfc9')]({'title':_0x588678[_0x477afb('0x52d')]?_0x477afb('0x1e21')+_0x588678[_0x477afb('0x52d')]+_0x477afb('0x11e1')+_0x588678[_0x477afb('0xe1b')]:_0x477afb('0xdc5'),'msg':_0x588678[_0x477afb('0x25f4')]?JSON['stringify'](_0x588678['data']):_0x588678['toString']()});});function _0x1a1d6a(){const _0x5ab6c5=_0x58ff90;_0x54079a['errors']=[];const _0x4185b8=[];_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0x1345')]&&_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0x1345')][_0x5ab6c5('0x2574')]()===_0x5ab6c5('0x587')&&_0x54079a['agent'][_0x5ab6c5('0x83f')]==='outboundDial'&&(_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0x2026')]=_0x2b5a4e[_0x5ab6c5('0x2848')]?(_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0x265a')]||'')+_0x5ab6c5('0x881')+_0x2b5a4e[_0x5ab6c5('0x2848')]+'}':(_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0x265a')]||'')+'${EXTEN}',_0x2b5a4e[_0x5ab6c5('0x28cb')]!==_0x5ab6c5('0x192')?_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0xd39')][_0x5ab6c5('0x2379')](_0x5ab6c5('0x1059'))<0x0&&(_0x54079a['agent'][_0x5ab6c5('0xd39')]+=_0x5ab6c5('0x1059')):_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0xd39')]=_0x54079a['agent']['options']['replace'](_0x5ab6c5('0x1059'),''));const _0x7d6448=_0x2cfb05()[_0x5ab6c5('0xc38')](_0x54079a[_0x5ab6c5('0x1f7e')],{'name':_0x54079a['agent'][_0x5ab6c5('0x1eff')]});_0x7d6448&&(_0x54079a['agent'][_0x5ab6c5('0x122a')]=_0x7d6448['id']);if(_0x54079a['agent']['appType']&&_0x54079a[_0x5ab6c5('0x1eff')]['appType']===_0x5ab6c5('0x2853')){}else switch((_0x54079a[_0x5ab6c5('0x1eff')]['app']||_0x54079a['agent'][_0x5ab6c5('0x83f')])[_0x5ab6c5('0x2574')]()){case _0x5ab6c5('0xceb'):_0x54079a['agent']['appdata']=_0x54079a[_0x5ab6c5('0x1eff')]['name']+'='+_0x54079a[_0x5ab6c5('0x1eff')]['value'];break;case _0x5ab6c5('0x2853'):break;default:_0x4185b8[0x0]=_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0x1eff')],_0x4185b8[0x1]=_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0x651')],_0x54079a[_0x5ab6c5('0x1eff')][_0x5ab6c5('0x823')]=_0x4185b8[_0x5ab6c5('0x45a')](',');}_0x4fc51d(_0x54079a[_0x5ab6c5('0x1eff')]);}function _0x4fc51d(_0x5c85ad){const _0x41e0e1=_0x58ff90;_0x4502b3[_0x41e0e1('0x1197')](_0x5c85ad);}}const _0x56c1b8=_0x2c4b8;_0x1d7e4a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'smsAccountApp','smsAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x1d7e4a(_0x25bf1b,_0x9d7568,_0x5f3083,_0x17bc78,_0x3afc30,_0x510248,_0xe8d4b0,_0x185acb){const _0x5c98b2=_0x36e6f4,_0x22e9de=this;_0x22e9de['currentUser']=_0xe8d4b0[_0x5c98b2('0x26cd')](),_0x22e9de[_0x5c98b2('0x61a')]=[],_0x22e9de[_0x5c98b2('0xcdc')]='SMS.EDIT_'+(_0x17bc78[_0x5c98b2('0x83f')]||_0x17bc78[_0x5c98b2('0x746')])[_0x5c98b2('0x1387')](),_0x22e9de[_0x5c98b2('0x86c')]=angular[_0x5c98b2('0x225f')](_0x17bc78),_0x22e9de[_0x5c98b2('0x243c')]=_0x185acb,_0x22e9de[_0x5c98b2('0x128b')]={};if(_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x823')])switch(_0x22e9de[_0x5c98b2('0x86c')]['appType']?_0x22e9de[_0x5c98b2('0x86c')]['appType'][_0x5c98b2('0x2574')]():_0x22e9de[_0x5c98b2('0x86c')]['app'][_0x5c98b2('0x2574')]()){case _0x5c98b2('0x2853'):break;case _0x5c98b2('0xded'):{const _0x381e2e=_0x22e9de['amazonlex'][_0x5c98b2('0x823')]['split'](',');_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x7ca')]=_0x381e2e[0x0],_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0xedb')]=_0x381e2e[0x1],_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x1634')]=_0x381e2e[_0x5c98b2('0x233')](0x2,_0x381e2e[_0x5c98b2('0x264b')])[_0x5c98b2('0x45a')](',');}break;case'dialogflowv2':{const _0x1f63cf=_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x823')][_0x5c98b2('0x25c8')](',');_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x1b0a')]=_0x1f63cf[0x0],_0x22e9de[_0x5c98b2('0x86c')]['clientEmail']=_0x1f63cf[0x1],_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x170e')]=_0x1f63cf[0x2],_0x22e9de[_0x5c98b2('0x86c')]['language']=_0x1f63cf[0x3],_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x1634')]=_0x1f63cf[_0x5c98b2('0x233')](0x4,_0x1f63cf['length'])[_0x5c98b2('0x45a')](',');}break;case _0x5c98b2('0x86c'):{const _0x265fe4=_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x823')][_0x5c98b2('0x25c8')](',');_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0xee6')]=_0x265fe4[0x0],_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x125')]=_0x265fe4[0x1],_0x22e9de[_0x5c98b2('0x86c')]['lexregion']=_0x265fe4[0x2],_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x1ac4')]=_0x265fe4[0x3],_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x1634')]=_0x265fe4[_0x5c98b2('0x233')](0x4,_0x265fe4[_0x5c98b2('0x264b')])[_0x5c98b2('0x45a')](',');}break;case _0x5c98b2('0x1af7'):{const _0x56b0f9=_0x22e9de['amazonlex']['appdata'][_0x5c98b2('0x25c8')](',');_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x265e')]=isNaN(_0x56b0f9[0x0])?_0x56b0f9[0x0]:parseInt(_0x56b0f9[0x0],0xa),_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x1640')]=_0x56b0f9['slice'](0x1,_0x56b0f9[_0x5c98b2('0x264b')])[_0x5c98b2('0x45a')](',');}break;case'message':_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x1640')]=_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x823')];break;case'set':_0x22e9de[_0x5c98b2('0x86c')]['name']=_0x22e9de['amazonlex'][_0x5c98b2('0x823')][_0x5c98b2('0x25c8')]('=')[0x0],_0x22e9de['amazonlex'][_0x5c98b2('0x18e0')]=_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x823')]['split']('=')[0x1];break;case _0x5c98b2('0x1034'):_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x2588')]=_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x823')];break;default:{const _0x55058c=_0x22e9de['amazonlex'][_0x5c98b2('0x823')][_0x5c98b2('0x25c8')](',');_0x22e9de[_0x5c98b2('0x86c')]['accesskeyid']=_0x2cfb05()[_0x5c98b2('0x1081')](_0x55058c[0x0])?_0x55058c[0x0]:isNaN(_0x55058c[0x0])?_0x55058c[0x0]:parseInt(_0x55058c[0x0],0xa),_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x125')]=_0x2cfb05()[_0x5c98b2('0x1081')](_0x55058c[0x1])?_0x55058c[0x1]:isNaN(_0x55058c[0x1])?_0x55058c[0x1]:parseInt(_0x55058c[0x1],0xa),_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x25a2')]=_0x2cfb05()[_0x5c98b2('0x1081')](_0x55058c[0x2])?_0x55058c[0x2]:isNaN(_0x55058c[0x2])?_0x55058c[0x2]:parseInt(_0x55058c[0x2],0xa),_0x22e9de['amazonlex'][_0x5c98b2('0x1ac4')]=_0x2cfb05()[_0x5c98b2('0x1081')](_0x55058c[0x3])?_0x55058c[0x3]:isNaN(_0x55058c[0x3])?_0x55058c[0x3]:parseInt(_0x55058c[0x3],0xa),_0x22e9de[_0x5c98b2('0x86c')]['welcomemessage']=_0x2cfb05()['isEmpty'](_0x55058c[0x4])?_0x55058c[0x4]:isNaN(_0x55058c[0x4])?_0x55058c[0x4]:parseInt(_0x55058c[0x4],0xa);}break;}else _0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x25a2')]=_0x5c98b2('0x1039');_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x1345')]&&_0x22e9de['amazonlex'][_0x5c98b2('0x1345')][_0x5c98b2('0x2574')]()===_0x5c98b2('0x587')&&_0x22e9de[_0x5c98b2('0x86c')]['appType'][_0x5c98b2('0x2574')]()===_0x5c98b2('0x2884')&&(_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x265a')]=_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x2026')]?_0x22e9de['amazonlex'][_0x5c98b2('0x2026')][_0x5c98b2('0x25c8')]('$')[0x0]:undefined,_0x22e9de['amazonlex']['callerId']=_0x22e9de['amazonlex'][_0x5c98b2('0x992')]?_0x5c98b2('0xa4c')+_0x22e9de[_0x5c98b2('0x86c')][_0x5c98b2('0x992')]:undefined);_0x22e9de[_0x5c98b2('0x151a')]=_0xcd583e,_0x22e9de[_0x5c98b2('0x24a0')]=_0x465615;function _0xcd583e(){const _0xd2750c=_0x5c98b2;_0x22e9de['errors']=[];const _0x6c9127=[];_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x1345')]&&_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x1345')][_0xd2750c('0x2574')]()===_0xd2750c('0x587')&&_0x22e9de['amazonlex'][_0xd2750c('0x83f')]===_0xd2750c('0x867')&&(_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x2026')]=_0x3afc30[_0xd2750c('0x2848')]?(_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x265a')]||'')+'${EXTEN:'+_0x3afc30[_0xd2750c('0x2848')]+'}':(_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x265a')]||'')+_0xd2750c('0x1d1'),_0x3afc30[_0xd2750c('0x28cb')]!=='none'?_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0xd39')][_0xd2750c('0x2379')](_0xd2750c('0x1059'))<0x0&&(_0x22e9de[_0xd2750c('0x86c')]['options']+=_0xd2750c('0x1059')):_0x22e9de['amazonlex'][_0xd2750c('0xd39')]=_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0xd39')][_0xd2750c('0xf3')](_0xd2750c('0x1059'),''));if(_0x22e9de[_0xd2750c('0x86c')]['appType']&&_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x83f')]===_0xd2750c('0x2853')){}else switch((_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x746')]||_0x22e9de['amazonlex']['appType'])[_0xd2750c('0x2574')]()){case _0xd2750c('0xceb'):_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x823')]=_0x22e9de['amazonlex'][_0xd2750c('0x4f0')]+'='+_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x18e0')];break;case _0xd2750c('0x2853'):break;default:_0x6c9127[0x0]=_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0xee6')],_0x6c9127[0x1]=_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x125')],_0x6c9127[0x2]=_0x22e9de['amazonlex'][_0xd2750c('0x25a2')],_0x6c9127[0x3]=_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x1ac4')],_0x6c9127[0x4]=_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x1634')],_0x22e9de[_0xd2750c('0x86c')][_0xd2750c('0x823')]=_0x6c9127[_0xd2750c('0x45a')](',');}_0x465615(_0x22e9de['amazonlex']);}function _0x465615(_0x2f58b2){const _0x590389=_0x5c98b2;_0x25bf1b[_0x590389('0x1197')](_0x2f58b2);}}const _0x142d96=_0x1d7e4a;_0x558815[_0x36e6f4('0x1294')]=['$mdDialog','$q','toasty',_0x36e6f4('0x22e0'),_0x36e6f4('0x27e5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x558815(_0x40155a,_0x55c8b7,_0x4457b4,_0x48faa4,_0x220220,_0x26bb7e,_0x409333,_0x39d515){const _0xf2b880=_0x36e6f4,_0x5b4d0e=this;_0x5b4d0e[_0xf2b880('0x98')]=_0x409333[_0xf2b880('0x26cd')](),_0x5b4d0e[_0xf2b880('0x61a')]=[],_0x5b4d0e['title']=_0xf2b880('0xeb')+(_0x48faa4[_0xf2b880('0x83f')]||_0x48faa4['app'])[_0xf2b880('0x1387')](),_0x5b4d0e[_0xf2b880('0x1af7')]=angular[_0xf2b880('0x225f')](_0x48faa4),_0x5b4d0e[_0xf2b880('0x243c')]=_0x39d515,_0x5b4d0e[_0xf2b880('0x128b')]={};if(_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x823')])switch(_0x5b4d0e[_0xf2b880('0x1af7')]['appType']?_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x83f')]['toLowerCase']():_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x746')]['toLowerCase']()){case _0xf2b880('0x2853'):break;case _0xf2b880('0xded'):{const _0x4d7b64=_0x5b4d0e['autoreply'][_0xf2b880('0x823')][_0xf2b880('0x25c8')](',');_0x5b4d0e['autoreply'][_0xf2b880('0x7ca')]=_0x4d7b64[0x0],_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0xedb')]=_0x4d7b64[0x1],_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x1634')]=_0x4d7b64['slice'](0x2,_0x4d7b64['length'])['join'](',');}break;case _0xf2b880('0x1636'):{const _0x386376=_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x823')][_0xf2b880('0x25c8')](',');_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x1b0a')]=_0x386376[0x0],_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x27f3')]=_0x386376[0x1],_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x170e')]=_0x386376[0x2],_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0xedb')]=_0x386376[0x3],_0x5b4d0e['autoreply'][_0xf2b880('0x1634')]=_0x386376[_0xf2b880('0x233')](0x4,_0x386376[_0xf2b880('0x264b')])[_0xf2b880('0x45a')](',');}break;case _0xf2b880('0x86c'):{const _0x35acd3=_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x823')][_0xf2b880('0x25c8')](',');_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0xee6')]=_0x35acd3[0x0],_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x125')]=_0x35acd3[0x1],_0x5b4d0e['autoreply'][_0xf2b880('0x25a2')]=_0x35acd3[0x2],_0x5b4d0e['autoreply'][_0xf2b880('0x1ac4')]=_0x35acd3[0x3],_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x1634')]=_0x35acd3[_0xf2b880('0x233')](0x4,_0x35acd3[_0xf2b880('0x264b')])[_0xf2b880('0x45a')](',');}break;case _0xf2b880('0x1af7'):{const _0xeaf673=_0x5b4d0e['autoreply'][_0xf2b880('0x823')][_0xf2b880('0x25c8')](',');_0x5b4d0e[_0xf2b880('0x1af7')]['times']=isNaN(_0xeaf673[0x0])?_0xeaf673[0x0]:parseInt(_0xeaf673[0x0],0xa),_0x5b4d0e['autoreply']['text']=_0xeaf673[_0xf2b880('0x233')](0x1,_0xeaf673['length'])['join'](',');}break;case'message':_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x1640')]=_0x5b4d0e['autoreply'][_0xf2b880('0x823')];break;case _0xf2b880('0xceb'):_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x4f0')]=_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x823')][_0xf2b880('0x25c8')]('=')[0x0],_0x5b4d0e['autoreply'][_0xf2b880('0x18e0')]=_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x823')][_0xf2b880('0x25c8')]('=')[0x1];break;case _0xf2b880('0x1034'):_0x5b4d0e['autoreply'][_0xf2b880('0x2588')]=_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x823')];break;default:{const _0x1a4998=_0x5b4d0e[_0xf2b880('0x1af7')]['appdata']['split'](',');_0x5b4d0e[_0xf2b880('0x1af7')]['times']=_0x2cfb05()['isEmpty'](_0x1a4998[0x0])?_0x1a4998[0x0]:isNaN(_0x1a4998[0x0])?_0x1a4998[0x0]:parseInt(_0x1a4998[0x0],0xa),_0x5b4d0e[_0xf2b880('0x1af7')]['text']=_0x2cfb05()[_0xf2b880('0x1081')](_0x1a4998[0x1])?_0x1a4998[0x1]:isNaN(_0x1a4998[0x1])?_0x1a4998[0x1]:parseInt(_0x1a4998[0x1],0xa);}}else _0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x265e')]=0x1;_0x5b4d0e[_0xf2b880('0x1af7')]['type']&&_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x1345')][_0xf2b880('0x2574')]()===_0xf2b880('0x587')&&_0x5b4d0e[_0xf2b880('0x1af7')]['appType']['toLowerCase']()==='outbounddial'&&(_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x265a')]=_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x2026')]?_0x5b4d0e['autoreply'][_0xf2b880('0x2026')][_0xf2b880('0x25c8')]('$')[0x0]:undefined,_0x5b4d0e[_0xf2b880('0x1af7')][_0xf2b880('0x1f02')]=_0x5b4d0e[_0xf2b880('0x1af7')]['callerID']?_0xf2b880('0xa4c')+_0x5b4d0e['autoreply'][_0xf2b880('0x992')]:undefined);_0x5b4d0e[_0xf2b880('0x151a')]=_0x3e0cc7,_0x5b4d0e[_0xf2b880('0x24a0')]=_0x431d6b;function _0x3e0cc7(){const _0x433b3f=_0xf2b880;_0x5b4d0e['errors']=[];const _0x1e816d=[];_0x5b4d0e[_0x433b3f('0x1af7')][_0x433b3f('0x1345')]&&_0x5b4d0e[_0x433b3f('0x1af7')][_0x433b3f('0x1345')][_0x433b3f('0x2574')]()==='outbound'&&_0x5b4d0e[_0x433b3f('0x1af7')][_0x433b3f('0x83f')]===_0x433b3f('0x867')&&(_0x5b4d0e['autoreply'][_0x433b3f('0x2026')]=_0x220220[_0x433b3f('0x2848')]?(_0x5b4d0e[_0x433b3f('0x1af7')][_0x433b3f('0x265a')]||'')+_0x433b3f('0x881')+_0x220220[_0x433b3f('0x2848')]+'}':(_0x5b4d0e['autoreply'][_0x433b3f('0x265a')]||'')+_0x433b3f('0x1d1'),_0x220220['recordingFormat']!=='none'?_0x5b4d0e[_0x433b3f('0x1af7')]['options'][_0x433b3f('0x2379')](_0x433b3f('0x1059'))<0x0&&(_0x5b4d0e['autoreply'][_0x433b3f('0xd39')]+=_0x433b3f('0x1059')):_0x5b4d0e[_0x433b3f('0x1af7')][_0x433b3f('0xd39')]=_0x5b4d0e[_0x433b3f('0x1af7')]['options'][_0x433b3f('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x5b4d0e[_0x433b3f('0x1af7')]['appType']&&_0x5b4d0e[_0x433b3f('0x1af7')][_0x433b3f('0x83f')]===_0x433b3f('0x2853')){}else switch((_0x5b4d0e[_0x433b3f('0x1af7')][_0x433b3f('0x746')]||_0x5b4d0e[_0x433b3f('0x1af7')][_0x433b3f('0x83f')])['toLowerCase']()){case'set':_0x5b4d0e['autoreply']['appdata']=_0x5b4d0e['autoreply'][_0x433b3f('0x4f0')]+'='+_0x5b4d0e['autoreply']['value'];break;case _0x433b3f('0x2853'):break;default:_0x1e816d[0x0]=_0x5b4d0e[_0x433b3f('0x1af7')][_0x433b3f('0x265e')],_0x1e816d[0x1]=_0x5b4d0e[_0x433b3f('0x1af7')]['text'],_0x5b4d0e['autoreply'][_0x433b3f('0x823')]=_0x1e816d['join'](',');}_0x431d6b(_0x5b4d0e[_0x433b3f('0x1af7')]);}function _0x431d6b(_0x4cbf65){const _0x3c43aa=_0xf2b880;_0x40155a[_0x3c43aa('0x1197')](_0x4cbf65);}}const _0x172585=_0x558815;_0x5b587f[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),'smsAccountApp',_0x36e6f4('0x27e5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x5b587f(_0x5ea148,_0xad2275,_0x392e9a,_0xea31a5,_0x351052,_0x4e2216,_0x29bcd,_0x24173b){const _0x215951=_0x36e6f4,_0x155c47=this;_0x155c47[_0x215951('0x98')]=_0x29bcd[_0x215951('0x26cd')](),_0x155c47['errors']=[],_0x155c47[_0x215951('0xcdc')]=_0x215951('0xeb')+(_0xea31a5[_0x215951('0x83f')]||_0xea31a5[_0x215951('0x746')])[_0x215951('0x1387')](),_0x155c47[_0x215951('0x1a7b')]=angular['copy'](_0xea31a5),_0x155c47[_0x215951('0x243c')]=_0x24173b,_0x155c47[_0x215951('0x128b')]={};if(_0x155c47[_0x215951('0x1a7b')][_0x215951('0x823')])switch(_0x155c47[_0x215951('0x1a7b')]['appType']?_0x155c47['close'][_0x215951('0x83f')][_0x215951('0x2574')]():_0x155c47['close'][_0x215951('0x746')][_0x215951('0x2574')]()){case _0x215951('0x2853'):break;case _0x215951('0xded'):{const _0x2bfffc=_0x155c47[_0x215951('0x1a7b')]['appdata'][_0x215951('0x25c8')](',');_0x155c47['close'][_0x215951('0x7ca')]=_0x2bfffc[0x0],_0x155c47[_0x215951('0x1a7b')]['language']=_0x2bfffc[0x1],_0x155c47[_0x215951('0x1a7b')][_0x215951('0x1634')]=_0x2bfffc[_0x215951('0x233')](0x2,_0x2bfffc[_0x215951('0x264b')])['join'](',');}break;case _0x215951('0x1636'):{const _0x4d844d=_0x155c47['close'][_0x215951('0x823')][_0x215951('0x25c8')](',');_0x155c47[_0x215951('0x1a7b')][_0x215951('0x1b0a')]=_0x4d844d[0x0],_0x155c47[_0x215951('0x1a7b')]['clientEmail']=_0x4d844d[0x1],_0x155c47[_0x215951('0x1a7b')][_0x215951('0x170e')]=_0x4d844d[0x2],_0x155c47['close'][_0x215951('0xedb')]=_0x4d844d[0x3],_0x155c47[_0x215951('0x1a7b')][_0x215951('0x1634')]=_0x4d844d['slice'](0x4,_0x4d844d[_0x215951('0x264b')])[_0x215951('0x45a')](',');}break;case _0x215951('0x86c'):{const _0x3e217e=_0x155c47[_0x215951('0x1a7b')][_0x215951('0x823')]['split'](',');_0x155c47[_0x215951('0x1a7b')][_0x215951('0xee6')]=_0x3e217e[0x0],_0x155c47[_0x215951('0x1a7b')][_0x215951('0x125')]=_0x3e217e[0x1],_0x155c47[_0x215951('0x1a7b')][_0x215951('0x25a2')]=_0x3e217e[0x2],_0x155c47[_0x215951('0x1a7b')][_0x215951('0x1ac4')]=_0x3e217e[0x3],_0x155c47['close']['welcomemessage']=_0x3e217e[_0x215951('0x233')](0x4,_0x3e217e[_0x215951('0x264b')])[_0x215951('0x45a')](',');}break;case _0x215951('0x1af7'):{const _0xdbf043=_0x155c47[_0x215951('0x1a7b')]['appdata']['split'](',');_0x155c47[_0x215951('0x1a7b')]['times']=isNaN(_0xdbf043[0x0])?_0xdbf043[0x0]:parseInt(_0xdbf043[0x0],0xa),_0x155c47[_0x215951('0x1a7b')]['text']=_0xdbf043[_0x215951('0x233')](0x1,_0xdbf043['length'])[_0x215951('0x45a')](',');}break;case _0x215951('0x1e70'):_0x155c47[_0x215951('0x1a7b')]['text']=_0x155c47[_0x215951('0x1a7b')][_0x215951('0x823')];break;case'set':_0x155c47[_0x215951('0x1a7b')][_0x215951('0x4f0')]=_0x155c47['close']['appdata'][_0x215951('0x25c8')]('=')[0x0],_0x155c47[_0x215951('0x1a7b')][_0x215951('0x18e0')]=_0x155c47[_0x215951('0x1a7b')][_0x215951('0x823')][_0x215951('0x25c8')]('=')[0x1];break;case'agi':_0x155c47[_0x215951('0x1a7b')][_0x215951('0x2588')]=_0x155c47[_0x215951('0x1a7b')][_0x215951('0x823')];break;default:{const _0x412c4f=_0x155c47[_0x215951('0x1a7b')][_0x215951('0x823')][_0x215951('0x25c8')](',');_0x155c47['close'][_0x215951('0x12e8')]=_0x2cfb05()[_0x215951('0x1081')](_0x412c4f[0x0])?_0x412c4f[0x0]:isNaN(_0x412c4f[0x0])?_0x412c4f[0x0]:parseInt(_0x412c4f[0x0],0xa);}break;}else{}_0x155c47['close']['type']&&_0x155c47['close'][_0x215951('0x1345')][_0x215951('0x2574')]()===_0x215951('0x587')&&_0x155c47[_0x215951('0x1a7b')][_0x215951('0x83f')][_0x215951('0x2574')]()===_0x215951('0x2884')&&(_0x155c47[_0x215951('0x1a7b')][_0x215951('0x265a')]=_0x155c47[_0x215951('0x1a7b')][_0x215951('0x2026')]?_0x155c47[_0x215951('0x1a7b')][_0x215951('0x2026')]['split']('$')[0x0]:undefined,_0x155c47[_0x215951('0x1a7b')][_0x215951('0x1f02')]=_0x155c47[_0x215951('0x1a7b')][_0x215951('0x992')]?_0x215951('0xa4c')+_0x155c47[_0x215951('0x1a7b')][_0x215951('0x992')]:undefined);_0x155c47[_0x215951('0x151a')]=_0x15f33d,_0x155c47['closeDialog']=_0x515155;function _0x15f33d(){const _0x1a3a2e=_0x215951;_0x155c47[_0x1a3a2e('0x61a')]=[];const _0x2fec15=[];_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x1345')]&&_0x155c47['close'][_0x1a3a2e('0x1345')][_0x1a3a2e('0x2574')]()==='outbound'&&_0x155c47[_0x1a3a2e('0x1a7b')]['appType']===_0x1a3a2e('0x867')&&(_0x155c47[_0x1a3a2e('0x1a7b')]['phone']=_0x351052[_0x1a3a2e('0x2848')]?(_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x265a')]||'')+_0x1a3a2e('0x881')+_0x351052[_0x1a3a2e('0x2848')]+'}':(_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x265a')]||'')+'${EXTEN}',_0x351052[_0x1a3a2e('0x28cb')]!==_0x1a3a2e('0x192')?_0x155c47['close'][_0x1a3a2e('0xd39')][_0x1a3a2e('0x2379')](_0x1a3a2e('0x1059'))<0x0&&(_0x155c47[_0x1a3a2e('0x1a7b')]['options']+=_0x1a3a2e('0x1059')):_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0xd39')]=_0x155c47[_0x1a3a2e('0x1a7b')]['options'][_0x1a3a2e('0xf3')](_0x1a3a2e('0x1059'),''));if(_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x83f')]&&_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x83f')]===_0x1a3a2e('0x2853')){}else switch((_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x746')]||_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x83f')])[_0x1a3a2e('0x2574')]()){case _0x1a3a2e('0xceb'):_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x823')]=_0x155c47['close'][_0x1a3a2e('0x4f0')]+'='+_0x155c47['close']['value'];break;case'custom':break;default:_0x2fec15[0x0]=_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x12e8')],_0x155c47[_0x1a3a2e('0x1a7b')][_0x1a3a2e('0x823')]=_0x2fec15[_0x1a3a2e('0x45a')](',');}_0x515155(_0x155c47['close']);}function _0x515155(_0x994254){_0x5ea148['hide'](_0x994254);}}const _0x35b5df=_0x5b587f;_0x145e10[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x22e0'),_0x36e6f4('0x27e5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x145e10(_0x53ea48,_0x56cb69,_0x3bd48e,_0x359d02,_0x175cc5,_0x1ee124,_0x4248a5,_0x4c5a2a){const _0x13b626=_0x36e6f4,_0x200d46=this;_0x200d46[_0x13b626('0x98')]=_0x4248a5[_0x13b626('0x26cd')](),_0x200d46['errors']=[],_0x200d46[_0x13b626('0xcdc')]=_0x13b626('0xeb')+(_0x359d02[_0x13b626('0x83f')]||_0x359d02['app'])[_0x13b626('0x1387')](),_0x200d46[_0x13b626('0xded')]=angular[_0x13b626('0x225f')](_0x359d02),_0x200d46[_0x13b626('0x243c')]=_0x4c5a2a,_0x200d46['hasModulePermissions']={};if(_0x200d46[_0x13b626('0xded')][_0x13b626('0x823')])switch(_0x200d46['dialogflow'][_0x13b626('0x83f')]?_0x200d46[_0x13b626('0xded')][_0x13b626('0x83f')][_0x13b626('0x2574')]():_0x200d46[_0x13b626('0xded')][_0x13b626('0x746')][_0x13b626('0x2574')]()){case _0x13b626('0x2853'):break;case'dialogflow':{const _0x4c37f6=_0x200d46[_0x13b626('0xded')][_0x13b626('0x823')][_0x13b626('0x25c8')](',');_0x200d46[_0x13b626('0xded')][_0x13b626('0x7ca')]=_0x4c37f6[0x0],_0x200d46[_0x13b626('0xded')][_0x13b626('0xedb')]=_0x4c37f6[0x1],_0x200d46[_0x13b626('0xded')][_0x13b626('0x1634')]=_0x4c37f6['slice'](0x2,_0x4c37f6[_0x13b626('0x264b')])['join'](',');}break;case _0x13b626('0x1636'):{const _0x41d134=_0x200d46[_0x13b626('0xded')][_0x13b626('0x823')][_0x13b626('0x25c8')](',');_0x200d46[_0x13b626('0xded')][_0x13b626('0x1b0a')]=_0x41d134[0x0],_0x200d46[_0x13b626('0xded')][_0x13b626('0x27f3')]=_0x41d134[0x1],_0x200d46[_0x13b626('0xded')][_0x13b626('0x170e')]=_0x41d134[0x2],_0x200d46['dialogflow'][_0x13b626('0xedb')]=_0x41d134[0x3],_0x200d46[_0x13b626('0xded')][_0x13b626('0x1634')]=_0x41d134[_0x13b626('0x233')](0x4,_0x41d134['length'])[_0x13b626('0x45a')](',');}break;case _0x13b626('0x86c'):{const _0x3b208a=_0x200d46[_0x13b626('0xded')][_0x13b626('0x823')][_0x13b626('0x25c8')](',');_0x200d46['dialogflow'][_0x13b626('0xee6')]=_0x3b208a[0x0],_0x200d46[_0x13b626('0xded')][_0x13b626('0x125')]=_0x3b208a[0x1],_0x200d46[_0x13b626('0xded')][_0x13b626('0x25a2')]=_0x3b208a[0x2],_0x200d46['dialogflow']['botname']=_0x3b208a[0x3],_0x200d46['dialogflow'][_0x13b626('0x1634')]=_0x3b208a[_0x13b626('0x233')](0x4,_0x3b208a[_0x13b626('0x264b')])[_0x13b626('0x45a')](',');}break;case _0x13b626('0x1af7'):{const _0x3bcd78=_0x200d46[_0x13b626('0xded')][_0x13b626('0x823')][_0x13b626('0x25c8')](',');_0x200d46[_0x13b626('0xded')][_0x13b626('0x265e')]=isNaN(_0x3bcd78[0x0])?_0x3bcd78[0x0]:parseInt(_0x3bcd78[0x0],0xa),_0x200d46[_0x13b626('0xded')]['text']=_0x3bcd78[_0x13b626('0x233')](0x1,_0x3bcd78[_0x13b626('0x264b')])[_0x13b626('0x45a')](',');}break;case'message':_0x200d46[_0x13b626('0xded')][_0x13b626('0x1640')]=_0x200d46[_0x13b626('0xded')]['appdata'];break;case _0x13b626('0xceb'):_0x200d46[_0x13b626('0xded')][_0x13b626('0x4f0')]=_0x200d46[_0x13b626('0xded')][_0x13b626('0x823')][_0x13b626('0x25c8')]('=')[0x0],_0x200d46[_0x13b626('0xded')][_0x13b626('0x18e0')]=_0x200d46[_0x13b626('0xded')][_0x13b626('0x823')][_0x13b626('0x25c8')]('=')[0x1];break;case _0x13b626('0x1034'):_0x200d46['dialogflow'][_0x13b626('0x2588')]=_0x200d46[_0x13b626('0xded')][_0x13b626('0x823')];break;default:{const _0x4f20aa=_0x200d46[_0x13b626('0xded')][_0x13b626('0x823')][_0x13b626('0x25c8')](',');_0x200d46['dialogflow']['key']=_0x2cfb05()[_0x13b626('0x1081')](_0x4f20aa[0x0])?_0x4f20aa[0x0]:isNaN(_0x4f20aa[0x0])?_0x4f20aa[0x0]:parseInt(_0x4f20aa[0x0],0xa),_0x200d46[_0x13b626('0xded')][_0x13b626('0xedb')]=_0x2cfb05()['isEmpty'](_0x4f20aa[0x1])?_0x4f20aa[0x1]:isNaN(_0x4f20aa[0x1])?_0x4f20aa[0x1]:parseInt(_0x4f20aa[0x1],0xa),_0x200d46[_0x13b626('0xded')]['welcomemessage']=_0x2cfb05()[_0x13b626('0x1081')](_0x4f20aa[0x2])?_0x4f20aa[0x2]:isNaN(_0x4f20aa[0x2])?_0x4f20aa[0x2]:parseInt(_0x4f20aa[0x2],0xa);}break;}else _0x200d46[_0x13b626('0xded')]['language']='en';_0x200d46[_0x13b626('0xded')][_0x13b626('0x1345')]&&_0x200d46[_0x13b626('0xded')][_0x13b626('0x1345')][_0x13b626('0x2574')]()===_0x13b626('0x587')&&_0x200d46['dialogflow']['appType'][_0x13b626('0x2574')]()===_0x13b626('0x2884')&&(_0x200d46['dialogflow'][_0x13b626('0x265a')]=_0x200d46[_0x13b626('0xded')][_0x13b626('0x2026')]?_0x200d46[_0x13b626('0xded')]['phone'][_0x13b626('0x25c8')]('$')[0x0]:undefined,_0x200d46[_0x13b626('0xded')][_0x13b626('0x1f02')]=_0x200d46[_0x13b626('0xded')][_0x13b626('0x992')]?_0x13b626('0xa4c')+_0x200d46[_0x13b626('0xded')][_0x13b626('0x992')]:undefined);_0x200d46[_0x13b626('0x151a')]=_0xe4cf09,_0x200d46[_0x13b626('0x24a0')]=_0x1cd5f4;function _0xe4cf09(){const _0x3933b7=_0x13b626;_0x200d46['errors']=[];const _0x372a8c=[];_0x200d46['dialogflow'][_0x3933b7('0x1345')]&&_0x200d46[_0x3933b7('0xded')]['type'][_0x3933b7('0x2574')]()===_0x3933b7('0x587')&&_0x200d46[_0x3933b7('0xded')][_0x3933b7('0x83f')]===_0x3933b7('0x867')&&(_0x200d46[_0x3933b7('0xded')]['phone']=_0x175cc5[_0x3933b7('0x2848')]?(_0x200d46[_0x3933b7('0xded')][_0x3933b7('0x265a')]||'')+'${EXTEN:'+_0x175cc5[_0x3933b7('0x2848')]+'}':(_0x200d46['dialogflow'][_0x3933b7('0x265a')]||'')+_0x3933b7('0x1d1'),_0x175cc5['recordingFormat']!==_0x3933b7('0x192')?_0x200d46[_0x3933b7('0xded')]['options'][_0x3933b7('0x2379')](_0x3933b7('0x1059'))<0x0&&(_0x200d46[_0x3933b7('0xded')][_0x3933b7('0xd39')]+=_0x3933b7('0x1059')):_0x200d46[_0x3933b7('0xded')][_0x3933b7('0xd39')]=_0x200d46[_0x3933b7('0xded')][_0x3933b7('0xd39')]['replace'](_0x3933b7('0x1059'),''));if(_0x200d46[_0x3933b7('0xded')]['appType']&&_0x200d46[_0x3933b7('0xded')][_0x3933b7('0x83f')]===_0x3933b7('0x2853')){}else switch((_0x200d46[_0x3933b7('0xded')]['app']||_0x200d46['dialogflow']['appType'])['toLowerCase']()){case _0x3933b7('0xceb'):_0x200d46[_0x3933b7('0xded')][_0x3933b7('0x823')]=_0x200d46['dialogflow']['name']+'='+_0x200d46['dialogflow'][_0x3933b7('0x18e0')];break;case _0x3933b7('0x2853'):break;default:_0x372a8c[0x0]=_0x200d46[_0x3933b7('0xded')][_0x3933b7('0x7ca')],_0x372a8c[0x1]=_0x200d46[_0x3933b7('0xded')][_0x3933b7('0xedb')],_0x372a8c[0x2]=_0x200d46[_0x3933b7('0xded')][_0x3933b7('0x1634')],_0x200d46[_0x3933b7('0xded')][_0x3933b7('0x823')]=_0x372a8c[_0x3933b7('0x45a')](',');}_0x1cd5f4(_0x200d46[_0x3933b7('0xded')]);}function _0x1cd5f4(_0x463e74){_0x53ea48['hide'](_0x463e74);}}const _0x5e458e=_0x145e10;_0x1841c3[_0x36e6f4('0x1294')]=['$mdDialog','$q','toasty',_0x36e6f4('0x22e0'),_0x36e6f4('0x27e5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x1841c3(_0x1bc2c4,_0x4e1a11,_0x59c9ef,_0x336a90,_0xb42092,_0x1b891d,_0x52081f,_0x25b42b){const _0x56ce42=_0x36e6f4,_0x51dee3=this;_0x51dee3[_0x56ce42('0x98')]=_0x52081f[_0x56ce42('0x26cd')](),_0x51dee3[_0x56ce42('0x61a')]=[],_0x51dee3[_0x56ce42('0xcdc')]=_0x56ce42('0xeb')+(_0x336a90[_0x56ce42('0x83f')]||_0x336a90[_0x56ce42('0x746')])[_0x56ce42('0x1387')](),_0x51dee3[_0x56ce42('0x30f')]=angular['copy'](_0x336a90),_0x51dee3[_0x56ce42('0x243c')]=_0x25b42b,_0x51dee3[_0x56ce42('0x128b')]={};if(_0x51dee3['gotoif'][_0x56ce42('0x823')])switch(_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x83f')]?_0x51dee3['gotoif'][_0x56ce42('0x83f')]['toLowerCase']():_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x746')][_0x56ce42('0x2574')]()){case _0x56ce42('0x2853'):break;case _0x56ce42('0xded'):{const _0x13090e=_0x51dee3[_0x56ce42('0x30f')]['appdata'][_0x56ce42('0x25c8')](',');_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x7ca')]=_0x13090e[0x0],_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0xedb')]=_0x13090e[0x1],_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x1634')]=_0x13090e[_0x56ce42('0x233')](0x2,_0x13090e['length'])[_0x56ce42('0x45a')](',');}break;case _0x56ce42('0x1636'):{const _0x5d70d8=_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x823')][_0x56ce42('0x25c8')](',');_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x1b0a')]=_0x5d70d8[0x0],_0x51dee3['gotoif'][_0x56ce42('0x27f3')]=_0x5d70d8[0x1],_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x170e')]=_0x5d70d8[0x2],_0x51dee3['gotoif'][_0x56ce42('0xedb')]=_0x5d70d8[0x3],_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x1634')]=_0x5d70d8['slice'](0x4,_0x5d70d8[_0x56ce42('0x264b')])[_0x56ce42('0x45a')](',');}break;case'amazonlex':{const _0x2cd31d=_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x823')]['split'](',');_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0xee6')]=_0x2cd31d[0x0],_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x125')]=_0x2cd31d[0x1],_0x51dee3['gotoif']['lexregion']=_0x2cd31d[0x2],_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x1ac4')]=_0x2cd31d[0x3],_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x1634')]=_0x2cd31d[_0x56ce42('0x233')](0x4,_0x2cd31d[_0x56ce42('0x264b')])[_0x56ce42('0x45a')](',');}break;case'autoreply':{const _0x2c81e2=_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x823')][_0x56ce42('0x25c8')](',');_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x265e')]=isNaN(_0x2c81e2[0x0])?_0x2c81e2[0x0]:parseInt(_0x2c81e2[0x0],0xa),_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x1640')]=_0x2c81e2[_0x56ce42('0x233')](0x1,_0x2c81e2[_0x56ce42('0x264b')])['join'](',');}break;case _0x56ce42('0x1e70'):_0x51dee3['gotoif'][_0x56ce42('0x1640')]=_0x51dee3['gotoif'][_0x56ce42('0x823')];break;case _0x56ce42('0xceb'):_0x51dee3[_0x56ce42('0x30f')]['name']=_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x823')]['split']('=')[0x0],_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x18e0')]=_0x51dee3[_0x56ce42('0x30f')]['appdata'][_0x56ce42('0x25c8')]('=')[0x1];break;case _0x56ce42('0x1034'):_0x51dee3[_0x56ce42('0x30f')]['project']=_0x51dee3['gotoif'][_0x56ce42('0x823')];break;default:{const _0x12b9c0=_0x51dee3['gotoif'][_0x56ce42('0x823')][_0x56ce42('0x25c8')](',');_0x51dee3['gotoif'][_0x56ce42('0x8ff')]=_0x2cfb05()[_0x56ce42('0x1081')](_0x12b9c0[0x0])?_0x12b9c0[0x0]:isNaN(_0x12b9c0[0x0])?_0x12b9c0[0x0]:parseInt(_0x12b9c0[0x0],0xa),_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x13a6')]=_0x2cfb05()[_0x56ce42('0x1081')](_0x12b9c0[0x1])?_0x12b9c0[0x1]:isNaN(_0x12b9c0[0x1])?_0x12b9c0[0x1]:parseInt(_0x12b9c0[0x1],0xa),_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x1d7a')]=_0x2cfb05()[_0x56ce42('0x1081')](_0x12b9c0[0x2])?_0x12b9c0[0x2]:isNaN(_0x12b9c0[0x2])?_0x12b9c0[0x2]:parseInt(_0x12b9c0[0x2],0xa);}break;}else{}_0x51dee3['gotoif']['type']&&_0x51dee3[_0x56ce42('0x30f')]['type'][_0x56ce42('0x2574')]()===_0x56ce42('0x587')&&_0x51dee3[_0x56ce42('0x30f')]['appType'][_0x56ce42('0x2574')]()==='outbounddial'&&(_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x265a')]=_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x2026')]?_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x2026')]['split']('$')[0x0]:undefined,_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x1f02')]=_0x51dee3[_0x56ce42('0x30f')][_0x56ce42('0x992')]?_0x56ce42('0xa4c')+_0x51dee3[_0x56ce42('0x30f')]['callerID']:undefined);_0x51dee3[_0x56ce42('0x151a')]=_0x29f589,_0x51dee3[_0x56ce42('0x24a0')]=_0x501828;function _0x29f589(){const _0x20edaa=_0x56ce42;_0x51dee3['errors']=[];const _0xd709e7=[];_0x51dee3[_0x20edaa('0x30f')]['type']&&_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x1345')][_0x20edaa('0x2574')]()===_0x20edaa('0x587')&&_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x83f')]===_0x20edaa('0x867')&&(_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x2026')]=_0xb42092[_0x20edaa('0x2848')]?(_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x265a')]||'')+_0x20edaa('0x881')+_0xb42092['cutdigits']+'}':(_0x51dee3['gotoif'][_0x20edaa('0x265a')]||'')+_0x20edaa('0x1d1'),_0xb42092[_0x20edaa('0x28cb')]!==_0x20edaa('0x192')?_0x51dee3['gotoif']['options'][_0x20edaa('0x2379')](_0x20edaa('0x1059'))<0x0&&(_0x51dee3['gotoif'][_0x20edaa('0xd39')]+='U(xcally-mixmonitor-context)'):_0x51dee3['gotoif']['options']=_0x51dee3[_0x20edaa('0x30f')]['options'][_0x20edaa('0xf3')](_0x20edaa('0x1059'),''));if(_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x83f')]&&_0x51dee3['gotoif'][_0x20edaa('0x83f')]==='custom'){}else switch((_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x746')]||_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x83f')])[_0x20edaa('0x2574')]()){case _0x20edaa('0xceb'):_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x823')]=_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x4f0')]+'='+_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x18e0')];break;case _0x20edaa('0x2853'):break;default:_0xd709e7[0x0]=_0x51dee3['gotoif'][_0x20edaa('0x8ff')],_0xd709e7[0x1]=_0x51dee3[_0x20edaa('0x30f')][_0x20edaa('0x13a6')],_0xd709e7[0x2]=_0x51dee3[_0x20edaa('0x30f')]['falsepriority'],_0x51dee3[_0x20edaa('0x30f')]['appdata']=_0xd709e7['join'](',');}_0x501828(_0x51dee3['gotoif']);}function _0x501828(_0x5ddec5){const _0x270dcc=_0x56ce42;_0x1bc2c4[_0x270dcc('0x1197')](_0x5ddec5);}}const _0xd463c1=_0x1841c3;_0x441ab4[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x22e0'),_0x36e6f4('0x27e5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x441ab4(_0x2be5e6,_0x5cf20e,_0x96f318,_0x6ae1fa,_0x15ffa7,_0x36af2f,_0x1d8ee5,_0x38b0fb){const _0x5ec2ef=_0x36e6f4,_0x52f35b=this;_0x52f35b['currentUser']=_0x1d8ee5[_0x5ec2ef('0x26cd')](),_0x52f35b['errors']=[],_0x52f35b[_0x5ec2ef('0xcdc')]=_0x5ec2ef('0xeb')+(_0x6ae1fa[_0x5ec2ef('0x83f')]||_0x6ae1fa[_0x5ec2ef('0x746')])[_0x5ec2ef('0x1387')](),_0x52f35b[_0x5ec2ef('0x6e6')]=angular['copy'](_0x6ae1fa),_0x52f35b[_0x5ec2ef('0x243c')]=_0x38b0fb,_0x52f35b[_0x5ec2ef('0x128b')]={};if(_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x823')])switch(_0x52f35b[_0x5ec2ef('0x6e6')]['appType']?_0x52f35b['gotop'][_0x5ec2ef('0x83f')]['toLowerCase']():_0x52f35b[_0x5ec2ef('0x6e6')]['app'][_0x5ec2ef('0x2574')]()){case _0x5ec2ef('0x2853'):break;case _0x5ec2ef('0xded'):{const _0x2a1993=_0x52f35b[_0x5ec2ef('0x6e6')]['appdata'][_0x5ec2ef('0x25c8')](',');_0x52f35b['gotop'][_0x5ec2ef('0x7ca')]=_0x2a1993[0x0],_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0xedb')]=_0x2a1993[0x1],_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x1634')]=_0x2a1993[_0x5ec2ef('0x233')](0x2,_0x2a1993[_0x5ec2ef('0x264b')])[_0x5ec2ef('0x45a')](',');}break;case _0x5ec2ef('0x1636'):{const _0x39b861=_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x823')][_0x5ec2ef('0x25c8')](',');_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x1b0a')]=_0x39b861[0x0],_0x52f35b['gotop'][_0x5ec2ef('0x27f3')]=_0x39b861[0x1],_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x170e')]=_0x39b861[0x2],_0x52f35b['gotop']['language']=_0x39b861[0x3],_0x52f35b['gotop'][_0x5ec2ef('0x1634')]=_0x39b861['slice'](0x4,_0x39b861[_0x5ec2ef('0x264b')])[_0x5ec2ef('0x45a')](',');}break;case _0x5ec2ef('0x86c'):{const _0x52e331=_0x52f35b[_0x5ec2ef('0x6e6')]['appdata']['split'](',');_0x52f35b['gotop']['accesskeyid']=_0x52e331[0x0],_0x52f35b[_0x5ec2ef('0x6e6')]['secretaccesskey']=_0x52e331[0x1],_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x25a2')]=_0x52e331[0x2],_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x1ac4')]=_0x52e331[0x3],_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x1634')]=_0x52e331[_0x5ec2ef('0x233')](0x4,_0x52e331[_0x5ec2ef('0x264b')])[_0x5ec2ef('0x45a')](',');}break;case _0x5ec2ef('0x1af7'):{const _0x58fd70=_0x52f35b['gotop'][_0x5ec2ef('0x823')][_0x5ec2ef('0x25c8')](',');_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x265e')]=isNaN(_0x58fd70[0x0])?_0x58fd70[0x0]:parseInt(_0x58fd70[0x0],0xa),_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x1640')]=_0x58fd70[_0x5ec2ef('0x233')](0x1,_0x58fd70[_0x5ec2ef('0x264b')])[_0x5ec2ef('0x45a')](',');}break;case _0x5ec2ef('0x1e70'):_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x1640')]=_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x823')];break;case'set':_0x52f35b[_0x5ec2ef('0x6e6')]['name']=_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x823')][_0x5ec2ef('0x25c8')]('=')[0x0],_0x52f35b[_0x5ec2ef('0x6e6')]['value']=_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x823')][_0x5ec2ef('0x25c8')]('=')[0x1];break;case _0x5ec2ef('0x1034'):_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x2588')]=_0x52f35b[_0x5ec2ef('0x6e6')]['appdata'];break;default:{const _0x19b736=_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x823')][_0x5ec2ef('0x25c8')](',');_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0xfde')]=_0x2cfb05()[_0x5ec2ef('0x1081')](_0x19b736[0x0])?_0x19b736[0x0]:isNaN(_0x19b736[0x0])?_0x19b736[0x0]:parseInt(_0x19b736[0x0],0xa);}break;}else{}_0x52f35b['gotop'][_0x5ec2ef('0x1345')]&&_0x52f35b['gotop']['type'][_0x5ec2ef('0x2574')]()===_0x5ec2ef('0x587')&&_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x83f')][_0x5ec2ef('0x2574')]()===_0x5ec2ef('0x2884')&&(_0x52f35b['gotop'][_0x5ec2ef('0x265a')]=_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x2026')]?_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x2026')]['split']('$')[0x0]:undefined,_0x52f35b[_0x5ec2ef('0x6e6')]['callerId']=_0x52f35b['gotop'][_0x5ec2ef('0x992')]?'CALLERID(all)='+_0x52f35b[_0x5ec2ef('0x6e6')][_0x5ec2ef('0x992')]:undefined);_0x52f35b['saveSmsAccountApp']=_0x31a7dc,_0x52f35b['closeDialog']=_0x3eb044;function _0x31a7dc(){const _0x3e4bbd=_0x5ec2ef;_0x52f35b[_0x3e4bbd('0x61a')]=[];const _0x5e0438=[];_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0x1345')]&&_0x52f35b['gotop']['type']['toLowerCase']()===_0x3e4bbd('0x587')&&_0x52f35b[_0x3e4bbd('0x6e6')]['appType']===_0x3e4bbd('0x867')&&(_0x52f35b[_0x3e4bbd('0x6e6')]['phone']=_0x15ffa7[_0x3e4bbd('0x2848')]?(_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0x265a')]||'')+_0x3e4bbd('0x881')+_0x15ffa7[_0x3e4bbd('0x2848')]+'}':(_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0x265a')]||'')+'${EXTEN}',_0x15ffa7[_0x3e4bbd('0x28cb')]!==_0x3e4bbd('0x192')?_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0xd39')][_0x3e4bbd('0x2379')](_0x3e4bbd('0x1059'))<0x0&&(_0x52f35b[_0x3e4bbd('0x6e6')]['options']+='U(xcally-mixmonitor-context)'):_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0xd39')]=_0x52f35b['gotop']['options'][_0x3e4bbd('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0x83f')]&&_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0x83f')]===_0x3e4bbd('0x2853')){}else switch((_0x52f35b['gotop'][_0x3e4bbd('0x746')]||_0x52f35b['gotop'][_0x3e4bbd('0x83f')])[_0x3e4bbd('0x2574')]()){case _0x3e4bbd('0xceb'):_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0x823')]=_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0x4f0')]+'='+_0x52f35b[_0x3e4bbd('0x6e6')][_0x3e4bbd('0x18e0')];break;case'custom':break;default:_0x5e0438[0x0]=_0x52f35b['gotop']['priority'],_0x52f35b[_0x3e4bbd('0x6e6')]['appdata']=_0x5e0438['join'](',');}_0x3eb044(_0x52f35b[_0x3e4bbd('0x6e6')]);}function _0x3eb044(_0x8a3931){const _0x15a705=_0x5ec2ef;_0x2be5e6[_0x15a705('0x1197')](_0x8a3931);}}const _0x45d662=_0x441ab4;_0x3e7a08['$inject']=['$state',_0x36e6f4('0x265d'),'$mdToast','IndexFactory','interval','intervals',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'Auth','crudPermissions'];function _0x3e7a08(_0x582f15,_0x5c33cc,_0x56afae,_0x4a2b3d,_0x22bad4,_0x3e3bfb,_0x6ef585,_0x17788e,_0x1b46b9,_0x25d7c1){const _0x2cc3c1=_0x36e6f4,_0x5f0603=this;_0x5f0603[_0x2cc3c1('0x98')]=_0x1b46b9[_0x2cc3c1('0x26cd')](),_0x5f0603[_0x2cc3c1('0x61a')]=[],_0x5f0603['title']=_0x2cc3c1('0x2879'),_0x5f0603[_0x2cc3c1('0x277c')]=angular[_0x2cc3c1('0x225f')](_0x22bad4),_0x5f0603['intervals']=_0x3e3bfb,_0x5f0603[_0x2cc3c1('0x99d')]=![],_0x5f0603[_0x2cc3c1('0x6aa')]=[_0x2cc3c1('0x597'),_0x2cc3c1('0x2853'),_0x2cc3c1('0x1480')],_0x5f0603[_0x2cc3c1('0x243c')]=_0x25d7c1,_0x5f0603[_0x2cc3c1('0x5ef')]=_0x4a2b3d[_0x2cc3c1('0x28de')](),_0x5f0603[_0x2cc3c1('0x10b4')]=_0x4a2b3d[_0x2cc3c1('0x51d')](),_0x5f0603[_0x2cc3c1('0x2259')]=_0x4a2b3d[_0x2cc3c1('0x1c39')](),_0x5f0603[_0x2cc3c1('0x1fc0')]=_0x4a2b3d['getDaysOfMonth']();if(!_0x5f0603[_0x2cc3c1('0x277c')])_0x5f0603['interval']={'interval':_0x2cc3c1('0x16f')},_0x5f0603[_0x2cc3c1('0x1345')]=_0x2cc3c1('0x597'),_0x5f0603[_0x2cc3c1('0xcdc')]=_0x2cc3c1('0x412'),_0x5f0603[_0x2cc3c1('0x99d')]=!![];else{if(_0x5f0603[_0x2cc3c1('0x277c')][_0x2cc3c1('0x277c')]!==_0x2cc3c1('0x16f')){_0x5f0603[_0x2cc3c1('0x1345')]=_0x2cc3c1('0x2853');const _0xcdc0e9=_0x5f0603[_0x2cc3c1('0x277c')][_0x2cc3c1('0x277c')]['split'](','),_0x503506=_0xcdc0e9[0x0],_0x50bff9=_0xcdc0e9[0x1],_0x436dd0=_0xcdc0e9[0x2],_0x46b148=_0xcdc0e9[0x3];if(_0x503506!=='*'){const _0x2b83bf=_0x503506[_0x2cc3c1('0x25c8')]('-')[0x0],_0x34677b=_0x503506[_0x2cc3c1('0x25c8')]('-')[0x1];let _0x5e349f;_0x5e349f=new Date(),_0x5e349f[_0x2cc3c1('0xe24')](Number(_0x2b83bf[_0x2cc3c1('0x25c8')](':')[0x0])),_0x5e349f['setMinutes'](Number(_0x2b83bf[_0x2cc3c1('0x25c8')](':')[0x1])),_0x5f0603[_0x2cc3c1('0x64d')]=_0x5e349f,_0x5e349f=new Date(),_0x5e349f[_0x2cc3c1('0xe24')](Number(_0x34677b[_0x2cc3c1('0x25c8')](':')[0x0])),_0x5e349f['setMinutes'](Number(_0x34677b[_0x2cc3c1('0x25c8')](':')[0x1])),_0x5f0603[_0x2cc3c1('0x2076')]=_0x5e349f;}_0x50bff9!=='*'&&(_0x5f0603[_0x2cc3c1('0x1eca')]=_0x50bff9['split']('-')[0x0],_0x5f0603[_0x2cc3c1('0x1b81')]=_0x50bff9['split']('-')[0x1]),_0x436dd0!=='*'&&(_0x5f0603[_0x2cc3c1('0x103d')]=_0x436dd0[_0x2cc3c1('0x25c8')]('-')[0x0],_0x5f0603[_0x2cc3c1('0x1dbb')]=_0x436dd0[_0x2cc3c1('0x25c8')]('-')[0x1]),_0x46b148!=='*'&&(_0x5f0603[_0x2cc3c1('0xdec')]=_0x46b148['split']('-')[0x0],_0x5f0603[_0x2cc3c1('0x1125')]=_0x46b148['split']('-')[0x1]);}else _0x5f0603[_0x2cc3c1('0x1345')]='always';}_0x582f15[_0x2cc3c1('0x23f')]['id']&&!_0x5f0603[_0x2cc3c1('0x277c')][_0x2cc3c1('0x50d')]&&(_0x5f0603['interval']['IntervalId']=_0x582f15[_0x2cc3c1('0x23f')]['id']);_0x5f0603[_0x2cc3c1('0x277c')][_0x2cc3c1('0x186f')]&&_0x5f0603[_0x2cc3c1('0x277c')][_0x2cc3c1('0x50d')]&&(_0x5f0603[_0x2cc3c1('0x1345')]=_0x2cc3c1('0x1480'));_0x5f0603['addNewInterval']=_0x90fce9,_0x5f0603[_0x2cc3c1('0x24be')]=_0x2c2dd5,_0x5f0603['closeDialog']=_0x823376;_0x5f0603['interval'][_0x2cc3c1('0x50d')]&&(_0x1b46b9[_0x2cc3c1('0x1ac6')](_0x2cc3c1('0xa7c'))?_0x17788e[_0x2cc3c1('0x277c')][_0x2cc3c1('0xd83')]({'fields':_0x2cc3c1('0xd0a'),'IntervalId':_0x2cc3c1('0x15d7'),'nolimit':!![]})[_0x2cc3c1('0xa44')]['then'](function(_0x5591be){_0x5f0603['intervals']=_0x5591be['rows']||[];})['catch'](function(_0x5ee367){const _0x16109a=_0x2cc3c1;_0x6ef585[_0x16109a('0xfc9')]({'title':_0x5ee367['status']?_0x16109a('0x1e21')+_0x5ee367[_0x16109a('0x52d')]+_0x16109a('0x11e1')+_0x5ee367[_0x16109a('0xe1b')]:_0x16109a('0xbb4'),'msg':_0x5ee367[_0x16109a('0x25f4')]?JSON['stringify'](_0x5ee367[_0x16109a('0x25f4')]):_0x5ee367[_0x16109a('0x1586')]()});}):_0x17788e[_0x2cc3c1('0x277c')][_0x2cc3c1('0xd83')]({'fields':_0x2cc3c1('0xd0a'),'IntervalId':_0x2cc3c1('0x15d7'),'nolimit':!![]})[_0x2cc3c1('0xa44')][_0x2cc3c1('0x1166')](function(_0x473de2){const _0x46f120=_0x2cc3c1;_0x5f0603[_0x46f120('0x164e')]=_0x473de2[_0x46f120('0x269a')]||[];})[_0x2cc3c1('0x1166')](function(){const _0x1cccef=_0x2cc3c1;return _0x17788e[_0x1cccef('0x17aa')][_0x1cccef('0xd83')]({'userProfileId':_0x5f0603['currentUser'][_0x1cccef('0xb86')],'sectionId':0x3ec})['$promise'];})['then'](function(_0x611e07){const _0x2ec9de=_0x2cc3c1,_0x84d1d3=_0x611e07&&_0x611e07[_0x2ec9de('0x269a')]?_0x611e07[_0x2ec9de('0x269a')][0x0]:null;if(!_0x84d1d3)_0x5f0603['intervals']=[];else{if(!_0x84d1d3['autoAssociation'])return _0x17788e[_0x2ec9de('0x4b5')]['get']({'sectionId':_0x84d1d3['id']})['$promise']['then'](function(_0x4421fa){const _0x4b9342=_0x2ec9de,_0x1cd531=_0x4421fa&&_0x4421fa[_0x4b9342('0x269a')]?_0x4421fa[_0x4b9342('0x269a')]:[],_0x33b968=[];let _0x2882ac=null;_0x5f0603['interval']&&(_0x2882ac=_0x2cfb05()[_0x4b9342('0xc38')](_0x5f0603[_0x4b9342('0x164e')],{'name':_0x5f0603[_0x4b9342('0x277c')][_0x4b9342('0x186f')]})),_0x2882ac&&!_0x2cfb05()['some'](_0x1cd531,[_0x4b9342('0x24e8'),_0x2882ac['id']])&&_0x5f0603[_0x4b9342('0x164e')][_0x4b9342('0x2782')](function(_0x3af486){const _0x4390f7=_0x4b9342;_0x3af486['id']===_0x2882ac['id']&&(_0x3af486['canSelect']=![],_0x33b968[_0x4390f7('0x1514')](_0x3af486));}),_0x5f0603['intervals']=_0x33b968;});}})[_0x2cc3c1('0x1a80')](function(_0x2cb01a){const _0x2b533c=_0x2cc3c1;_0x6ef585[_0x2b533c('0xfc9')]({'title':_0x2cb01a['status']?_0x2b533c('0x1e21')+_0x2cb01a[_0x2b533c('0x52d')]+_0x2b533c('0x11e1')+_0x2cb01a['statusText']:'SYSTEM:GET_INTERVALS','msg':_0x2cb01a[_0x2b533c('0x25f4')]?JSON[_0x2b533c('0xbac')](_0x2cb01a[_0x2b533c('0x25f4')]):_0x2cb01a[_0x2b533c('0x1586')]()});}));function _0x25ba5d(){const _0x383b2b=_0x2cc3c1;switch(_0x5f0603[_0x383b2b('0x1345')]){case'always':case _0x383b2b('0x1480'):return _0x383b2b('0x16f');case _0x383b2b('0x2853'):{const _0x4d9807=[];if(_0x5f0603['timeRangeFrom']!=='*'&&_0x5f0603[_0x383b2b('0x64d')]&&_0x5f0603[_0x383b2b('0x2076')]){const _0x2c55a3=(_0x5f0603[_0x383b2b('0x64d')][_0x383b2b('0x11fe')]()<0xa?'0':'')+_0x5f0603[_0x383b2b('0x64d')][_0x383b2b('0x11fe')]()+':'+((_0x5f0603[_0x383b2b('0x64d')][_0x383b2b('0x234')]()<0xa?'0':'')+_0x5f0603[_0x383b2b('0x64d')]['getMinutes']()),_0x2c1a8f=(_0x5f0603[_0x383b2b('0x2076')][_0x383b2b('0x11fe')]()<0xa?'0':'')+_0x5f0603['timeRangeTo'][_0x383b2b('0x11fe')]()+':'+((_0x5f0603['timeRangeTo'][_0x383b2b('0x234')]()<0xa?'0':'')+_0x5f0603['timeRangeTo']['getMinutes']());_0x4d9807['push'](_0x2c55a3+'-'+_0x2c1a8f);}else _0x4d9807[_0x383b2b('0x1514')]('*');return _0x5f0603[_0x383b2b('0x1eca')]?_0x5f0603[_0x383b2b('0x1b81')]?_0x4d9807[_0x383b2b('0x1514')](_0x5f0603[_0x383b2b('0x1eca')]+'-'+_0x5f0603['dayOfWeekTo']):_0x4d9807[_0x383b2b('0x1514')](_0x5f0603[_0x383b2b('0x1eca')]):_0x4d9807[_0x383b2b('0x1514')]('*'),_0x5f0603[_0x383b2b('0x103d')]?_0x5f0603[_0x383b2b('0x1dbb')]?_0x4d9807[_0x383b2b('0x1514')](_0x5f0603[_0x383b2b('0x103d')]+'-'+_0x5f0603[_0x383b2b('0x1dbb')]):_0x4d9807[_0x383b2b('0x1514')](_0x5f0603[_0x383b2b('0x103d')]):_0x4d9807['push']('*'),_0x5f0603[_0x383b2b('0xdec')]?_0x5f0603['monthTo']?_0x4d9807[_0x383b2b('0x1514')](_0x5f0603[_0x383b2b('0xdec')]+'-'+_0x5f0603[_0x383b2b('0x1125')]):_0x4d9807[_0x383b2b('0x1514')](_0x5f0603[_0x383b2b('0xdec')]):_0x4d9807['push']('*'),_0x4d9807['join']();}}}function _0x90fce9(){const _0x18f413=_0x2cc3c1;_0x5f0603[_0x18f413('0x61a')]=[],_0x5f0603[_0x18f413('0x277c')][_0x18f413('0x277c')]=_0x25ba5d(),_0x17788e['interval'][_0x18f413('0x9cc')](_0x5f0603[_0x18f413('0x277c')])[_0x18f413('0xa44')][_0x18f413('0x1166')](function(_0x397c96){const _0x3e09df=_0x18f413;_0x5f0603[_0x3e09df('0x164e')][_0x3e09df('0x1514')](_0x397c96),_0x6ef585['success']({'title':'Interval\x20properly\x20created','msg':_0x5f0603[_0x3e09df('0x277c')][_0x3e09df('0x4f0')]?_0x5f0603[_0x3e09df('0x277c')][_0x3e09df('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x823376();})[_0x18f413('0x1a80')](function(_0x55c101){const _0x3f6220=_0x18f413;console[_0x3f6220('0xfc9')](_0x55c101),_0x5f0603[_0x3f6220('0x61a')]=_0x55c101['data'][_0x3f6220('0x61a')]||[{'message':_0x55c101[_0x3f6220('0x1586')](),'type':_0x3f6220('0x1192')}];});}function _0x2c2dd5(){const _0xcbcaac=_0x2cc3c1;_0x5f0603[_0xcbcaac('0x61a')]=[],_0x5f0603[_0xcbcaac('0x277c')]['interval']=_0x25ba5d(),_0x5f0603['interval'][_0xcbcaac('0x50d')]?(_0x5f0603[_0xcbcaac('0x1345')]!==_0xcbcaac('0x1480')&&(_0x5f0603[_0xcbcaac('0x277c')]['IntervalId']=null),_0x823376(_0x5f0603[_0xcbcaac('0x277c')])):_0x17788e[_0xcbcaac('0x277c')][_0xcbcaac('0x1449')]({'id':_0x5f0603[_0xcbcaac('0x277c')]['id']},_0x5f0603[_0xcbcaac('0x277c')])[_0xcbcaac('0xa44')][_0xcbcaac('0x1166')](function(_0x1dde52){const _0xbea412=_0xcbcaac,_0x539bf5=_0x2cfb05()[_0xbea412('0xc38')](_0x5f0603['intervals'],{'id':_0x1dde52['id']});_0x539bf5&&_0x2cfb05()['merge'](_0x539bf5,_0x1dde52),_0x6ef585[_0xbea412('0x103b')]({'title':_0xbea412('0x1243'),'msg':_0xbea412('0x1666')}),_0x823376();})[_0xcbcaac('0x1a80')](function(_0xb10ae3){const _0x3f4bb7=_0xcbcaac;console[_0x3f4bb7('0xfc9')](_0xb10ae3),_0x5f0603[_0x3f4bb7('0x61a')]=_0xb10ae3[_0x3f4bb7('0x25f4')][_0x3f4bb7('0x61a')]||[{'message':_0xb10ae3[_0x3f4bb7('0x1586')](),'type':'api.interval.update'}];});}function _0x823376(_0x59dce7){const _0xa09ff0=_0x2cc3c1;_0x5c33cc[_0xa09ff0('0x1197')](_0x59dce7);}}const _0x5a2758=_0x3e7a08;_0x33d634[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x22e0'),_0x36e6f4('0x27e5'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x33d634(_0x197eab,_0x5736f2,_0x14f278,_0x4eb072,_0x258755,_0xa1cb0d,_0x4eb12f,_0x2533bc){const _0x2af16c=_0x36e6f4,_0x3b07c2=this;_0x3b07c2[_0x2af16c('0x98')]=_0x4eb12f[_0x2af16c('0x26cd')](),_0x3b07c2[_0x2af16c('0x61a')]=[],_0x3b07c2[_0x2af16c('0xcdc')]=_0x2af16c('0xeb')+(_0x4eb072[_0x2af16c('0x83f')]||_0x4eb072[_0x2af16c('0x746')])['toUpperCase'](),_0x3b07c2['noop']=angular['copy'](_0x4eb072),_0x3b07c2[_0x2af16c('0x243c')]=_0x2533bc,_0x3b07c2['hasModulePermissions']={};if(_0x3b07c2['noop'][_0x2af16c('0x823')])switch(_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x83f')]?_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x83f')]['toLowerCase']():_0x3b07c2['noop'][_0x2af16c('0x746')][_0x2af16c('0x2574')]()){case'custom':break;case _0x2af16c('0xded'):{const _0x4efcf4=_0x3b07c2['noop'][_0x2af16c('0x823')][_0x2af16c('0x25c8')](',');_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x7ca')]=_0x4efcf4[0x0],_0x3b07c2['noop']['language']=_0x4efcf4[0x1],_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x1634')]=_0x4efcf4[_0x2af16c('0x233')](0x2,_0x4efcf4[_0x2af16c('0x264b')])['join'](',');}break;case _0x2af16c('0x1636'):{const _0x2472df=_0x3b07c2['noop'][_0x2af16c('0x823')][_0x2af16c('0x25c8')](',');_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x1b0a')]=_0x2472df[0x0],_0x3b07c2[_0x2af16c('0x2652')]['clientEmail']=_0x2472df[0x1],_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x170e')]=_0x2472df[0x2],_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0xedb')]=_0x2472df[0x3],_0x3b07c2[_0x2af16c('0x2652')]['welcomemessage']=_0x2472df['slice'](0x4,_0x2472df[_0x2af16c('0x264b')])[_0x2af16c('0x45a')](',');}break;case _0x2af16c('0x86c'):{const _0x280fdd=_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x823')]['split'](',');_0x3b07c2['noop']['accesskeyid']=_0x280fdd[0x0],_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x125')]=_0x280fdd[0x1],_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x25a2')]=_0x280fdd[0x2],_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x1ac4')]=_0x280fdd[0x3],_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x1634')]=_0x280fdd['slice'](0x4,_0x280fdd[_0x2af16c('0x264b')])[_0x2af16c('0x45a')](',');}break;case _0x2af16c('0x1af7'):{const _0x5dc770=_0x3b07c2['noop'][_0x2af16c('0x823')]['split'](',');_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x265e')]=isNaN(_0x5dc770[0x0])?_0x5dc770[0x0]:parseInt(_0x5dc770[0x0],0xa),_0x3b07c2[_0x2af16c('0x2652')]['text']=_0x5dc770[_0x2af16c('0x233')](0x1,_0x5dc770['length'])[_0x2af16c('0x45a')](',');}break;case'message':_0x3b07c2['noop'][_0x2af16c('0x1640')]=_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x823')];break;case'set':_0x3b07c2['noop'][_0x2af16c('0x4f0')]=_0x3b07c2['noop'][_0x2af16c('0x823')][_0x2af16c('0x25c8')]('=')[0x0],_0x3b07c2['noop']['value']=_0x3b07c2[_0x2af16c('0x2652')]['appdata'][_0x2af16c('0x25c8')]('=')[0x1];break;case _0x2af16c('0x1034'):_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x2588')]=_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x823')];break;default:{const _0x5d1999=_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x823')][_0x2af16c('0x25c8')](',');_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x18e0')]=_0x2cfb05()[_0x2af16c('0x1081')](_0x5d1999[0x0])?_0x5d1999[0x0]:isNaN(_0x5d1999[0x0])?_0x5d1999[0x0]:parseInt(_0x5d1999[0x0],0xa);}break;}else{}_0x3b07c2['noop']['type']&&_0x3b07c2['noop'][_0x2af16c('0x1345')]['toLowerCase']()===_0x2af16c('0x587')&&_0x3b07c2['noop'][_0x2af16c('0x83f')]['toLowerCase']()===_0x2af16c('0x2884')&&(_0x3b07c2[_0x2af16c('0x2652')]['prefix']=_0x3b07c2['noop']['phone']?_0x3b07c2['noop'][_0x2af16c('0x2026')][_0x2af16c('0x25c8')]('$')[0x0]:undefined,_0x3b07c2[_0x2af16c('0x2652')][_0x2af16c('0x1f02')]=_0x3b07c2['noop'][_0x2af16c('0x992')]?_0x2af16c('0xa4c')+_0x3b07c2['noop'][_0x2af16c('0x992')]:undefined);_0x3b07c2[_0x2af16c('0x151a')]=_0x464d50,_0x3b07c2[_0x2af16c('0x24a0')]=_0x4e59ea;function _0x464d50(){const _0x3fd028=_0x2af16c;_0x3b07c2['errors']=[];const _0x21177b=[];_0x3b07c2['noop'][_0x3fd028('0x1345')]&&_0x3b07c2['noop'][_0x3fd028('0x1345')][_0x3fd028('0x2574')]()===_0x3fd028('0x587')&&_0x3b07c2['noop'][_0x3fd028('0x83f')]===_0x3fd028('0x867')&&(_0x3b07c2['noop'][_0x3fd028('0x2026')]=_0x258755[_0x3fd028('0x2848')]?(_0x3b07c2[_0x3fd028('0x2652')][_0x3fd028('0x265a')]||'')+'${EXTEN:'+_0x258755[_0x3fd028('0x2848')]+'}':(_0x3b07c2[_0x3fd028('0x2652')][_0x3fd028('0x265a')]||'')+_0x3fd028('0x1d1'),_0x258755[_0x3fd028('0x28cb')]!==_0x3fd028('0x192')?_0x3b07c2[_0x3fd028('0x2652')]['options'][_0x3fd028('0x2379')](_0x3fd028('0x1059'))<0x0&&(_0x3b07c2[_0x3fd028('0x2652')][_0x3fd028('0xd39')]+='U(xcally-mixmonitor-context)'):_0x3b07c2[_0x3fd028('0x2652')][_0x3fd028('0xd39')]=_0x3b07c2[_0x3fd028('0x2652')][_0x3fd028('0xd39')][_0x3fd028('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x3b07c2[_0x3fd028('0x2652')]['appType']&&_0x3b07c2[_0x3fd028('0x2652')][_0x3fd028('0x83f')]===_0x3fd028('0x2853')){}else switch((_0x3b07c2[_0x3fd028('0x2652')][_0x3fd028('0x746')]||_0x3b07c2[_0x3fd028('0x2652')]['appType'])[_0x3fd028('0x2574')]()){case _0x3fd028('0xceb'):_0x3b07c2['noop']['appdata']=_0x3b07c2['noop']['name']+'='+_0x3b07c2[_0x3fd028('0x2652')][_0x3fd028('0x18e0')];break;case _0x3fd028('0x2853'):break;default:_0x21177b[0x0]=_0x3b07c2['noop']['value'],_0x3b07c2['noop']['appdata']=_0x21177b[_0x3fd028('0x45a')](',');}_0x4e59ea(_0x3b07c2[_0x3fd028('0x2652')]);}function _0x4e59ea(_0x27711f){const _0x1b5dfe=_0x2af16c;_0x197eab[_0x1b5dfe('0x1197')](_0x27711f);}}const _0x3ff29d=_0x33d634;_0x58c62b['$inject']=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x22e0'),_0x36e6f4('0x27e5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x58c62b(_0x1c35a8,_0x12807f,_0x55afe2,_0xad8644,_0x5b7641,_0x3d7aea,_0x230373,_0x255053){const _0x5b0b73=_0x36e6f4,_0x175928=this;_0x175928[_0x5b0b73('0x98')]=_0x230373[_0x5b0b73('0x26cd')](),_0x175928[_0x5b0b73('0x61a')]=[],_0x175928['title']=_0x5b0b73('0xeb')+(_0xad8644[_0x5b0b73('0x83f')]||_0xad8644['app'])[_0x5b0b73('0x1387')](),_0x175928[_0x5b0b73('0x1d3e')]=angular['copy'](_0xad8644),_0x175928[_0x5b0b73('0x243c')]=_0x255053,_0x175928[_0x5b0b73('0x128b')]={};if(_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x823')])switch(_0x175928[_0x5b0b73('0x1d3e')]['appType']?_0x175928[_0x5b0b73('0x1d3e')]['appType']['toLowerCase']():_0x175928['queue'][_0x5b0b73('0x746')][_0x5b0b73('0x2574')]()){case _0x5b0b73('0x2853'):break;case _0x5b0b73('0xded'):{const _0x5d05e7=_0x175928['queue']['appdata']['split'](',');_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x7ca')]=_0x5d05e7[0x0],_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0xedb')]=_0x5d05e7[0x1],_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x1634')]=_0x5d05e7['slice'](0x2,_0x5d05e7['length'])['join'](',');}break;case _0x5b0b73('0x1636'):{const _0x4e0425=_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x823')]['split'](',');_0x175928['queue'][_0x5b0b73('0x1b0a')]=_0x4e0425[0x0],_0x175928['queue'][_0x5b0b73('0x27f3')]=_0x4e0425[0x1],_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x170e')]=_0x4e0425[0x2],_0x175928[_0x5b0b73('0x1d3e')]['language']=_0x4e0425[0x3],_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x1634')]=_0x4e0425['slice'](0x4,_0x4e0425['length'])[_0x5b0b73('0x45a')](',');}break;case'amazonlex':{const _0x1a17fd=_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x823')][_0x5b0b73('0x25c8')](',');_0x175928['queue'][_0x5b0b73('0xee6')]=_0x1a17fd[0x0],_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x125')]=_0x1a17fd[0x1],_0x175928[_0x5b0b73('0x1d3e')]['lexregion']=_0x1a17fd[0x2],_0x175928[_0x5b0b73('0x1d3e')]['botname']=_0x1a17fd[0x3],_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x1634')]=_0x1a17fd['slice'](0x4,_0x1a17fd[_0x5b0b73('0x264b')])[_0x5b0b73('0x45a')](',');}break;case'autoreply':{const _0x2ad5ed=_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x823')][_0x5b0b73('0x25c8')](',');_0x175928['queue'][_0x5b0b73('0x265e')]=isNaN(_0x2ad5ed[0x0])?_0x2ad5ed[0x0]:parseInt(_0x2ad5ed[0x0],0xa),_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x1640')]=_0x2ad5ed[_0x5b0b73('0x233')](0x1,_0x2ad5ed[_0x5b0b73('0x264b')])[_0x5b0b73('0x45a')](',');}break;case'message':_0x175928['queue'][_0x5b0b73('0x1640')]=_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x823')];break;case'set':_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x4f0')]=_0x175928['queue']['appdata'][_0x5b0b73('0x25c8')]('=')[0x0],_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x18e0')]=_0x175928['queue'][_0x5b0b73('0x823')][_0x5b0b73('0x25c8')]('=')[0x1];break;case _0x5b0b73('0x1034'):_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x2588')]=_0x175928['queue'][_0x5b0b73('0x823')];break;default:{const _0xd09f92=_0x175928['queue'][_0x5b0b73('0x823')][_0x5b0b73('0x25c8')](',');_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x1d3e')]=_0x2cfb05()[_0x5b0b73('0x1081')](_0xd09f92[0x0])?_0xd09f92[0x0]:isNaN(_0xd09f92[0x0])?_0xd09f92[0x0]:parseInt(_0xd09f92[0x0],0xa),_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x651')]=_0x2cfb05()[_0x5b0b73('0x1081')](_0xd09f92[0x1])?_0xd09f92[0x1]:isNaN(_0xd09f92[0x1])?_0xd09f92[0x1]:parseInt(_0xd09f92[0x1],0xa);}break;}else _0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x1d3e')]=0x12c,_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x651')]=0x12c;_0x175928[_0x5b0b73('0x1d3e')]['type']&&_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x1345')][_0x5b0b73('0x2574')]()===_0x5b0b73('0x587')&&_0x175928['queue'][_0x5b0b73('0x83f')]['toLowerCase']()==='outbounddial'&&(_0x175928[_0x5b0b73('0x1d3e')]['prefix']=_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x2026')]?_0x175928[_0x5b0b73('0x1d3e')][_0x5b0b73('0x2026')][_0x5b0b73('0x25c8')]('$')[0x0]:undefined,_0x175928['queue'][_0x5b0b73('0x1f02')]=_0x175928[_0x5b0b73('0x1d3e')]['callerID']?_0x5b0b73('0xa4c')+_0x175928[_0x5b0b73('0x1d3e')]['callerID']:undefined);_0x175928['saveSmsAccountApp']=_0x58a500,_0x175928[_0x5b0b73('0x24a0')]=_0x13504a,_0x230373[_0x5b0b73('0x1ac6')](_0x5b0b73('0xa7c'))?_0x3d7aea[_0x5b0b73('0x73c')][_0x5b0b73('0xd83')]({'fields':_0x5b0b73('0x1c09'),'sort':_0x5b0b73('0x4f0'),'nolimit':_0x5b0b73('0xf3b')})['$promise'][_0x5b0b73('0x1166')](function(_0x3097cd){const _0x461314=_0x5b0b73;_0x175928[_0x461314('0x7a7')]=_0x3097cd[_0x461314('0x269a')]||[];})['catch'](function(_0x371088){const _0x459d71=_0x5b0b73;_0x55afe2[_0x459d71('0xfc9')]({'title':_0x371088[_0x459d71('0x52d')]?'API:'+_0x371088[_0x459d71('0x52d')]+_0x459d71('0x11e1')+_0x371088[_0x459d71('0xe1b')]:_0x459d71('0x2029'),'msg':_0x371088[_0x459d71('0x25f4')]?JSON[_0x459d71('0xbac')](_0x371088['data']):_0x371088['toString']()});}):_0x3d7aea['smsQueue'][_0x5b0b73('0xd83')]({'fields':_0x5b0b73('0x1c09'),'sort':_0x5b0b73('0x4f0'),'nolimit':_0x5b0b73('0xf3b')})[_0x5b0b73('0xa44')][_0x5b0b73('0x1166')](function(_0x1ef0a6){const _0x2c2ea8=_0x5b0b73;_0x175928[_0x2c2ea8('0x7a7')]=_0x1ef0a6[_0x2c2ea8('0x269a')]||[];})['then'](function(){const _0x4bbc29=_0x5b0b73;return _0x3d7aea[_0x4bbc29('0x17aa')][_0x4bbc29('0xd83')]({'userProfileId':_0x175928['currentUser'][_0x4bbc29('0xb86')],'sectionId':0x2bd})[_0x4bbc29('0xa44')];})['then'](function(_0x1868a3){const _0x564264=_0x5b0b73,_0x363bf0=_0x1868a3&&_0x1868a3[_0x564264('0x269a')]?_0x1868a3['rows'][0x0]:null;if(!_0x363bf0){const _0x377058=[];let _0x24e6fd=null;_0x175928[_0x564264('0x1d3e')]&&(_0x24e6fd=_0x2cfb05()['find'](_0x175928['queues'],{'name':_0x175928[_0x564264('0x1d3e')][_0x564264('0x1d3e')]}));for(let _0x328c99=0x0;_0x328c99<_0x175928['queues']['length'];_0x328c99++){_0x24e6fd&&_0x175928[_0x564264('0x7a7')][_0x328c99]['id']===_0x24e6fd['id']&&(_0x175928[_0x564264('0x7a7')][_0x328c99]['canSelect']=![],_0x377058[_0x564264('0x1514')](_0x175928[_0x564264('0x7a7')][_0x328c99]));}_0x175928[_0x564264('0x7a7')]=_0x377058;}else{if(!_0x363bf0[_0x564264('0x1a2b')])return _0x3d7aea[_0x564264('0x4b5')][_0x564264('0xd83')]({'sectionId':_0x363bf0['id']})['$promise'][_0x564264('0x1166')](function(_0x3ee599){const _0x84fe16=_0x564264,_0x52c7c2=_0x2cfb05()[_0x84fe16('0x2563')](_0x3ee599[_0x84fe16('0x269a')],function(_0x2d32a6){const _0x28639c=_0x84fe16;return _0x2cfb05()['find'](_0x175928[_0x28639c('0x7a7')],{'id':_0x2d32a6[_0x28639c('0x24e8')]});});let _0x2b1aac=null;_0x175928[_0x84fe16('0x1d3e')]&&(_0x2b1aac=_0x2cfb05()[_0x84fe16('0xc38')](_0x175928['queues'],{'name':_0x175928[_0x84fe16('0x1d3e')][_0x84fe16('0x1d3e')]}));if(_0x2b1aac&&!_0x2cfb05()[_0x84fe16('0x1798')](_0x52c7c2,['id',_0x2b1aac['id']])){const _0x3d9626=_0x2cfb05()['find'](_0x175928[_0x84fe16('0x7a7')],{'id':_0x2b1aac['id']});_0x3d9626['canSelect']=![],_0x52c7c2[_0x84fe16('0x1514')](_0x3d9626);}_0x175928[_0x84fe16('0x7a7')]=_0x52c7c2;});}})['catch'](function(_0x415aa7){const _0x309c39=_0x5b0b73;_0x55afe2[_0x309c39('0xfc9')]({'title':_0x415aa7[_0x309c39('0x52d')]?_0x309c39('0x1e21')+_0x415aa7[_0x309c39('0x52d')]+_0x309c39('0x11e1')+_0x415aa7[_0x309c39('0xe1b')]:_0x309c39('0x1dd7'),'msg':_0x415aa7[_0x309c39('0x25f4')]?JSON[_0x309c39('0xbac')](_0x415aa7[_0x309c39('0x25f4')]):_0x415aa7[_0x309c39('0x1586')]()});});function _0x58a500(){const _0x593673=_0x5b0b73;_0x175928['errors']=[];const _0x5b7918=[];_0x175928['queue'][_0x593673('0x1345')]&&_0x175928[_0x593673('0x1d3e')][_0x593673('0x1345')][_0x593673('0x2574')]()===_0x593673('0x587')&&_0x175928[_0x593673('0x1d3e')][_0x593673('0x83f')]===_0x593673('0x867')&&(_0x175928[_0x593673('0x1d3e')][_0x593673('0x2026')]=_0x5b7641[_0x593673('0x2848')]?(_0x175928['queue']['prefix']||'')+_0x593673('0x881')+_0x5b7641[_0x593673('0x2848')]+'}':(_0x175928[_0x593673('0x1d3e')][_0x593673('0x265a')]||'')+_0x593673('0x1d1'),_0x5b7641[_0x593673('0x28cb')]!==_0x593673('0x192')?_0x175928[_0x593673('0x1d3e')][_0x593673('0xd39')][_0x593673('0x2379')](_0x593673('0x1059'))<0x0&&(_0x175928[_0x593673('0x1d3e')]['options']+=_0x593673('0x1059')):_0x175928['queue'][_0x593673('0xd39')]=_0x175928['queue']['options']['replace'](_0x593673('0x1059'),''));const _0x3b91f3=_0x2cfb05()[_0x593673('0xc38')](_0x175928['queues'],{'name':_0x175928[_0x593673('0x1d3e')][_0x593673('0x1d3e')]});_0x3b91f3&&(_0x175928['queue'][_0x2cfb05()[_0x593673('0x92c')](_0x593673('0x146c'))+_0x593673('0x1366')]=_0x3b91f3['id']);if(_0x175928[_0x593673('0x1d3e')][_0x593673('0x83f')]&&_0x175928[_0x593673('0x1d3e')][_0x593673('0x83f')]==='custom'){}else switch((_0x175928[_0x593673('0x1d3e')][_0x593673('0x746')]||_0x175928[_0x593673('0x1d3e')][_0x593673('0x83f')])['toLowerCase']()){case _0x593673('0xceb'):_0x175928[_0x593673('0x1d3e')]['appdata']=_0x175928[_0x593673('0x1d3e')][_0x593673('0x4f0')]+'='+_0x175928[_0x593673('0x1d3e')][_0x593673('0x18e0')];break;case'custom':break;default:_0x5b7918[0x0]=_0x175928[_0x593673('0x1d3e')][_0x593673('0x1d3e')],_0x5b7918[0x1]=_0x175928[_0x593673('0x1d3e')]['timeout'],_0x175928['queue'][_0x593673('0x823')]=_0x5b7918[_0x593673('0x45a')](',');}_0x13504a(_0x175928[_0x593673('0x1d3e')]);}function _0x13504a(_0x567eaf){const _0x418b31=_0x5b0b73;_0x1c35a8[_0x418b31('0x1197')](_0x567eaf);}}const _0x43a932=_0x58c62b;_0x35745c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x22e0'),_0x36e6f4('0x27e5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x35745c(_0x3f22b4,_0x163570,_0x795480,_0x38372c,_0x312b61,_0x5e2222,_0x1ce5fb,_0x31322f){const _0x536d5f=_0x36e6f4,_0x5e331a=this;_0x5e331a[_0x536d5f('0x98')]=_0x1ce5fb[_0x536d5f('0x26cd')](),_0x5e331a[_0x536d5f('0x61a')]=[],_0x5e331a[_0x536d5f('0xcdc')]=_0x536d5f('0xeb')+(_0x38372c[_0x536d5f('0x83f')]||_0x38372c[_0x536d5f('0x746')])[_0x536d5f('0x1387')](),_0x5e331a[_0x536d5f('0x1c2b')]=angular[_0x536d5f('0x225f')](_0x38372c),_0x5e331a[_0x536d5f('0x243c')]=_0x31322f,_0x5e331a[_0x536d5f('0x128b')]={};if(_0x5e331a['system'][_0x536d5f('0x823')])switch(_0x5e331a[_0x536d5f('0x1c2b')]['appType']?_0x5e331a[_0x536d5f('0x1c2b')]['appType'][_0x536d5f('0x2574')]():_0x5e331a[_0x536d5f('0x1c2b')]['app'][_0x536d5f('0x2574')]()){case _0x536d5f('0x2853'):break;case _0x536d5f('0xded'):{const _0x2945c3=_0x5e331a['system'][_0x536d5f('0x823')][_0x536d5f('0x25c8')](',');_0x5e331a[_0x536d5f('0x1c2b')]['key']=_0x2945c3[0x0],_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0xedb')]=_0x2945c3[0x1],_0x5e331a[_0x536d5f('0x1c2b')]['welcomemessage']=_0x2945c3[_0x536d5f('0x233')](0x2,_0x2945c3[_0x536d5f('0x264b')])[_0x536d5f('0x45a')](',');}break;case _0x536d5f('0x1636'):{const _0x1443c6=_0x5e331a[_0x536d5f('0x1c2b')]['appdata'][_0x536d5f('0x25c8')](',');_0x5e331a[_0x536d5f('0x1c2b')]['projectId']=_0x1443c6[0x0],_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x27f3')]=_0x1443c6[0x1],_0x5e331a[_0x536d5f('0x1c2b')]['privateKey']=_0x1443c6[0x2],_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0xedb')]=_0x1443c6[0x3],_0x5e331a['system'][_0x536d5f('0x1634')]=_0x1443c6[_0x536d5f('0x233')](0x4,_0x1443c6[_0x536d5f('0x264b')])[_0x536d5f('0x45a')](',');}break;case _0x536d5f('0x86c'):{const _0x2d9225=_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x823')]['split'](',');_0x5e331a[_0x536d5f('0x1c2b')]['accesskeyid']=_0x2d9225[0x0],_0x5e331a[_0x536d5f('0x1c2b')]['secretaccesskey']=_0x2d9225[0x1],_0x5e331a['system'][_0x536d5f('0x25a2')]=_0x2d9225[0x2],_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x1ac4')]=_0x2d9225[0x3],_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x1634')]=_0x2d9225[_0x536d5f('0x233')](0x4,_0x2d9225['length'])[_0x536d5f('0x45a')](',');}break;case _0x536d5f('0x1af7'):{const _0x1a5a5d=_0x5e331a['system']['appdata']['split'](',');_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x265e')]=isNaN(_0x1a5a5d[0x0])?_0x1a5a5d[0x0]:parseInt(_0x1a5a5d[0x0],0xa),_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x1640')]=_0x1a5a5d[_0x536d5f('0x233')](0x1,_0x1a5a5d['length'])['join'](',');}break;case _0x536d5f('0x1e70'):_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x1640')]=_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x823')];break;case _0x536d5f('0xceb'):_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x4f0')]=_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x823')][_0x536d5f('0x25c8')]('=')[0x0],_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x18e0')]=_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x823')][_0x536d5f('0x25c8')]('=')[0x1];break;case _0x536d5f('0x1034'):_0x5e331a['system']['project']=_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x823')];break;default:{const _0x5056ad=_0x5e331a['system'][_0x536d5f('0x823')][_0x536d5f('0x25c8')](',');_0x5e331a[_0x536d5f('0x1c2b')]['command']=_0x2cfb05()[_0x536d5f('0x1081')](_0x5056ad[0x0])?_0x5056ad[0x0]:isNaN(_0x5056ad[0x0])?_0x5056ad[0x0]:parseInt(_0x5056ad[0x0],0xa),_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x734')]=_0x2cfb05()[_0x536d5f('0x1081')](_0x5056ad[0x1])?_0x5056ad[0x1]:isNaN(_0x5056ad[0x1])?_0x5056ad[0x1]:parseInt(_0x5056ad[0x1],0xa);}break;}else _0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x734')]='';_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x1345')]&&_0x5e331a['system'][_0x536d5f('0x1345')][_0x536d5f('0x2574')]()===_0x536d5f('0x587')&&_0x5e331a['system'][_0x536d5f('0x83f')]['toLowerCase']()===_0x536d5f('0x2884')&&(_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x265a')]=_0x5e331a[_0x536d5f('0x1c2b')]['phone']?_0x5e331a['system'][_0x536d5f('0x2026')][_0x536d5f('0x25c8')]('$')[0x0]:undefined,_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x1f02')]=_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x992')]?_0x536d5f('0xa4c')+_0x5e331a[_0x536d5f('0x1c2b')][_0x536d5f('0x992')]:undefined);_0x5e331a[_0x536d5f('0x151a')]=_0x2230e7,_0x5e331a[_0x536d5f('0x24a0')]=_0xb7379b,_0x1ce5fb['hasRole']('admin')?_0x5e2222[_0x536d5f('0x734')][_0x536d5f('0xd83')]({'fields':_0x536d5f('0x1776'),'sort':_0x536d5f('0x4f0'),'nolimit':'true'})['$promise'][_0x536d5f('0x1166')](function(_0x48ed4c){const _0x24fc96=_0x536d5f;_0x5e331a['variables']=_0x48ed4c[_0x24fc96('0x269a')]||[];})['catch'](function(_0x424fa2){const _0x272ff1=_0x536d5f;_0x795480[_0x272ff1('0xfc9')]({'title':_0x424fa2[_0x272ff1('0x52d')]?'API:'+_0x424fa2[_0x272ff1('0x52d')]+_0x272ff1('0x11e1')+_0x424fa2['statusText']:'SYSTEM:GET_VARIABLES','msg':_0x424fa2['data']?JSON['stringify'](_0x424fa2[_0x272ff1('0x25f4')]):_0x424fa2[_0x272ff1('0x1586')]()});}):_0x5e2222[_0x536d5f('0x734')]['get']({'fields':_0x536d5f('0x1776'),'sort':_0x536d5f('0x4f0'),'nolimit':_0x536d5f('0xf3b')})[_0x536d5f('0xa44')]['then'](function(_0xc252f0){const _0x19a437=_0x536d5f;_0x5e331a[_0x19a437('0x57a')]=_0xc252f0[_0x19a437('0x269a')]||[];})[_0x536d5f('0x1166')](function(){const _0x7709a1=_0x536d5f;return _0x5e2222['userProfileSection']['get']({'userProfileId':_0x5e331a[_0x7709a1('0x98')]['userProfileId'],'sectionId':0x3f4})[_0x7709a1('0xa44')];})[_0x536d5f('0x1166')](function(_0x23efca){const _0x5c0f29=_0x536d5f,_0x21ba11=_0x23efca&&_0x23efca[_0x5c0f29('0x269a')]?_0x23efca['rows'][0x0]:null;if(!_0x21ba11){const _0x9604ab=[];let _0x4c1e31=null;_0x5e331a[_0x5c0f29('0x1c2b')]&&(_0x4c1e31=_0x2cfb05()[_0x5c0f29('0xc38')](_0x5e331a['variables'],{'name':_0x5e331a[_0x5c0f29('0x1c2b')][_0x5c0f29('0x734')]}));for(let _0x425970=0x0;_0x425970<_0x5e331a[_0x5c0f29('0x57a')][_0x5c0f29('0x264b')];_0x425970++){_0x4c1e31&&_0x5e331a[_0x5c0f29('0x57a')][_0x425970]['id']===_0x4c1e31['id']&&(_0x5e331a['variables'][_0x425970][_0x5c0f29('0x2378')]=![],_0x9604ab[_0x5c0f29('0x1514')](_0x5e331a[_0x5c0f29('0x57a')][_0x425970]));}_0x5e331a[_0x5c0f29('0x57a')]=_0x9604ab;}else{if(!_0x21ba11[_0x5c0f29('0x1a2b')])return _0x5e2222[_0x5c0f29('0x4b5')][_0x5c0f29('0xd83')]({'sectionId':_0x21ba11['id']})['$promise'][_0x5c0f29('0x1166')](function(_0x369e01){const _0x5c3852=_0x5c0f29,_0x225b48=_0x2cfb05()[_0x5c3852('0x2563')](_0x369e01[_0x5c3852('0x269a')],function(_0x5ba64f){const _0x2cb68a=_0x5c3852;return _0x2cfb05()[_0x2cb68a('0xc38')](_0x5e331a[_0x2cb68a('0x57a')],{'id':_0x5ba64f[_0x2cb68a('0x24e8')]});});let _0x489912=null;_0x5e331a[_0x5c3852('0x1c2b')]&&(_0x489912=_0x2cfb05()[_0x5c3852('0xc38')](_0x5e331a[_0x5c3852('0x57a')],{'name':_0x5e331a['system'][_0x5c3852('0x734')]}));if(_0x489912&&!_0x2cfb05()['some'](_0x225b48,['id',_0x489912['id']])){const _0x1bd08d=_0x2cfb05()['find'](_0x5e331a[_0x5c3852('0x57a')],{'id':_0x489912['id']});_0x1bd08d[_0x5c3852('0x2378')]=![],_0x225b48[_0x5c3852('0x1514')](_0x1bd08d);}_0x5e331a['variables']=_0x225b48;});}})[_0x536d5f('0x1a80')](function(_0x223ad4){const _0x409efc=_0x536d5f;_0x795480[_0x409efc('0xfc9')]({'title':_0x223ad4['status']?_0x409efc('0x1e21')+_0x223ad4[_0x409efc('0x52d')]+'\x20-\x20'+_0x223ad4[_0x409efc('0xe1b')]:_0x409efc('0x2644'),'msg':_0x223ad4[_0x409efc('0x25f4')]?JSON['stringify'](_0x223ad4[_0x409efc('0x25f4')]):_0x223ad4[_0x409efc('0x1586')]()});});function _0x2230e7(){const _0x361972=_0x536d5f;_0x5e331a[_0x361972('0x61a')]=[];const _0x560dea=[];_0x5e331a[_0x361972('0x1c2b')][_0x361972('0x1345')]&&_0x5e331a[_0x361972('0x1c2b')]['type'][_0x361972('0x2574')]()===_0x361972('0x587')&&_0x5e331a[_0x361972('0x1c2b')][_0x361972('0x83f')]===_0x361972('0x867')&&(_0x5e331a['system'][_0x361972('0x2026')]=_0x312b61[_0x361972('0x2848')]?(_0x5e331a[_0x361972('0x1c2b')][_0x361972('0x265a')]||'')+_0x361972('0x881')+_0x312b61[_0x361972('0x2848')]+'}':(_0x5e331a[_0x361972('0x1c2b')][_0x361972('0x265a')]||'')+_0x361972('0x1d1'),_0x312b61['recordingFormat']!=='none'?_0x5e331a[_0x361972('0x1c2b')]['options'][_0x361972('0x2379')](_0x361972('0x1059'))<0x0&&(_0x5e331a['system']['options']+='U(xcally-mixmonitor-context)'):_0x5e331a[_0x361972('0x1c2b')][_0x361972('0xd39')]=_0x5e331a[_0x361972('0x1c2b')]['options']['replace']('U(xcally-mixmonitor-context)',''));if(_0x5e331a['system'][_0x361972('0x83f')]&&_0x5e331a['system']['appType']===_0x361972('0x2853')){}else switch((_0x5e331a['system']['app']||_0x5e331a[_0x361972('0x1c2b')][_0x361972('0x83f')])[_0x361972('0x2574')]()){case _0x361972('0xceb'):_0x5e331a[_0x361972('0x1c2b')][_0x361972('0x823')]=_0x5e331a[_0x361972('0x1c2b')]['name']+'='+_0x5e331a[_0x361972('0x1c2b')]['value'];break;case _0x361972('0x2853'):break;default:_0x560dea[0x0]=_0x5e331a[_0x361972('0x1c2b')][_0x361972('0x187')],_0x560dea[0x1]=_0x5e331a[_0x361972('0x1c2b')][_0x361972('0x734')],_0x5e331a[_0x361972('0x1c2b')]['appdata']=_0x560dea[_0x361972('0x45a')](',');}_0xb7379b(_0x5e331a[_0x361972('0x1c2b')]);}function _0xb7379b(_0x3e747e){const _0x258685=_0x536d5f;_0x3f22b4[_0x258685('0x1197')](_0x3e747e);}}const _0x130721=_0x35745c;_0xb52a96[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x22e0'),_0x36e6f4('0x27e5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0xb52a96(_0x35545c,_0x165598,_0x46ce6f,_0xd655db,_0x181c7d,_0x5925c5,_0x4707e3,_0x54e98e){const _0x5ee6f9=_0x36e6f4,_0x57458b=this;_0x57458b[_0x5ee6f9('0x98')]=_0x4707e3['getCurrentUser'](),_0x57458b['errors']=[],_0x57458b['title']=_0x5ee6f9('0xeb')+(_0xd655db['appType']||_0xd655db['app'])[_0x5ee6f9('0x1387')](),_0x57458b[_0x5ee6f9('0x1446')]=angular[_0x5ee6f9('0x225f')](_0xd655db),_0x57458b[_0x5ee6f9('0x243c')]=_0x54e98e,_0x57458b[_0x5ee6f9('0x128b')]={};if(_0x57458b[_0x5ee6f9('0x1446')]['appdata'])switch(_0x57458b[_0x5ee6f9('0x1446')]['appType']?_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x83f')][_0x5ee6f9('0x2574')]():_0x57458b[_0x5ee6f9('0x1446')]['app'][_0x5ee6f9('0x2574')]()){case _0x5ee6f9('0x2853'):break;case _0x5ee6f9('0xded'):{const _0x237578=_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x823')]['split'](',');_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x7ca')]=_0x237578[0x0],_0x57458b[_0x5ee6f9('0x1446')]['language']=_0x237578[0x1],_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x1634')]=_0x237578[_0x5ee6f9('0x233')](0x2,_0x237578[_0x5ee6f9('0x264b')])[_0x5ee6f9('0x45a')](',');}break;case _0x5ee6f9('0x1636'):{const _0x488a3b=_0x57458b[_0x5ee6f9('0x1446')]['appdata'][_0x5ee6f9('0x25c8')](',');_0x57458b['tag'][_0x5ee6f9('0x1b0a')]=_0x488a3b[0x0],_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x27f3')]=_0x488a3b[0x1],_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x170e')]=_0x488a3b[0x2],_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0xedb')]=_0x488a3b[0x3],_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x1634')]=_0x488a3b[_0x5ee6f9('0x233')](0x4,_0x488a3b[_0x5ee6f9('0x264b')])[_0x5ee6f9('0x45a')](',');}break;case'amazonlex':{const _0x3e3050=_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x823')][_0x5ee6f9('0x25c8')](',');_0x57458b['tag'][_0x5ee6f9('0xee6')]=_0x3e3050[0x0],_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x125')]=_0x3e3050[0x1],_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x25a2')]=_0x3e3050[0x2],_0x57458b[_0x5ee6f9('0x1446')]['botname']=_0x3e3050[0x3],_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x1634')]=_0x3e3050[_0x5ee6f9('0x233')](0x4,_0x3e3050[_0x5ee6f9('0x264b')])[_0x5ee6f9('0x45a')](',');}break;case'autoreply':{const _0x13d068=_0x57458b['tag']['appdata']['split'](',');_0x57458b[_0x5ee6f9('0x1446')]['times']=isNaN(_0x13d068[0x0])?_0x13d068[0x0]:parseInt(_0x13d068[0x0],0xa),_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x1640')]=_0x13d068[_0x5ee6f9('0x233')](0x1,_0x13d068[_0x5ee6f9('0x264b')])[_0x5ee6f9('0x45a')](',');}break;case'message':_0x57458b['tag'][_0x5ee6f9('0x1640')]=_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x823')];break;case _0x5ee6f9('0xceb'):_0x57458b[_0x5ee6f9('0x1446')]['name']=_0x57458b['tag'][_0x5ee6f9('0x823')]['split']('=')[0x0],_0x57458b[_0x5ee6f9('0x1446')]['value']=_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x823')]['split']('=')[0x1];break;case _0x5ee6f9('0x1034'):_0x57458b['tag']['project']=_0x57458b[_0x5ee6f9('0x1446')]['appdata'];break;default:{const _0x2a5391=_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x823')][_0x5ee6f9('0x25c8')](',');_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x1446')]=_0x2cfb05()[_0x5ee6f9('0x1081')](_0x2a5391[0x0])?_0x2a5391[0x0]:isNaN(_0x2a5391[0x0])?_0x2a5391[0x0]:parseInt(_0x2a5391[0x0],0xa);}break;}else{}_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x1345')]&&_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x1345')][_0x5ee6f9('0x2574')]()===_0x5ee6f9('0x587')&&_0x57458b[_0x5ee6f9('0x1446')]['appType'][_0x5ee6f9('0x2574')]()==='outbounddial'&&(_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x265a')]=_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x2026')]?_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x2026')][_0x5ee6f9('0x25c8')]('$')[0x0]:undefined,_0x57458b[_0x5ee6f9('0x1446')][_0x5ee6f9('0x1f02')]=_0x57458b['tag']['callerID']?'CALLERID(all)='+_0x57458b[_0x5ee6f9('0x1446')]['callerID']:undefined);_0x57458b[_0x5ee6f9('0x151a')]=_0x3f758a,_0x57458b[_0x5ee6f9('0x24a0')]=_0x214ea0,_0x4707e3[_0x5ee6f9('0x1ac6')](_0x5ee6f9('0xa7c'))?_0x5925c5[_0x5ee6f9('0x1446')][_0x5ee6f9('0xd83')]({'fields':_0x5ee6f9('0x1776'),'sort':_0x5ee6f9('0x4f0'),'nolimit':_0x5ee6f9('0xf3b')})[_0x5ee6f9('0xa44')][_0x5ee6f9('0x1166')](function(_0x337bf5){const _0x282ab9=_0x5ee6f9;_0x57458b[_0x282ab9('0xb38')]=_0x337bf5[_0x282ab9('0x269a')]||[];})[_0x5ee6f9('0x1a80')](function(_0x23ebb4){const _0x10540a=_0x5ee6f9;_0x46ce6f[_0x10540a('0xfc9')]({'title':_0x23ebb4[_0x10540a('0x52d')]?_0x10540a('0x1e21')+_0x23ebb4[_0x10540a('0x52d')]+_0x10540a('0x11e1')+_0x23ebb4[_0x10540a('0xe1b')]:'SYSTEM:GET_TAGS','msg':_0x23ebb4[_0x10540a('0x25f4')]?JSON[_0x10540a('0xbac')](_0x23ebb4['data']):_0x23ebb4[_0x10540a('0x1586')]()});}):_0x5925c5[_0x5ee6f9('0x1446')][_0x5ee6f9('0xd83')]({'fields':_0x5ee6f9('0x1776'),'sort':_0x5ee6f9('0x4f0'),'nolimit':'true'})[_0x5ee6f9('0xa44')][_0x5ee6f9('0x1166')](function(_0x100be3){const _0x170761=_0x5ee6f9;_0x57458b[_0x170761('0xb38')]=_0x100be3[_0x170761('0x269a')]||[];})[_0x5ee6f9('0x1166')](function(){const _0x4136f2=_0x5ee6f9;return _0x5925c5['userProfileSection'][_0x4136f2('0xd83')]({'userProfileId':_0x57458b[_0x4136f2('0x98')][_0x4136f2('0xb86')],'sectionId':0x3f0})['$promise'];})['then'](function(_0x50c6a0){const _0x20389f=_0x5ee6f9,_0x39706f=_0x50c6a0&&_0x50c6a0[_0x20389f('0x269a')]?_0x50c6a0[_0x20389f('0x269a')][0x0]:null;if(!_0x39706f){const _0x3231bd=[];let _0x2fa511=null;_0x57458b[_0x20389f('0x1446')]&&(_0x2fa511=_0x2cfb05()['find'](_0x57458b['tags'],{'name':_0x57458b['tag']['tag']}));for(let _0x1d12db=0x0;_0x1d12db<_0x57458b[_0x20389f('0xb38')][_0x20389f('0x264b')];_0x1d12db++){_0x2fa511&&_0x57458b[_0x20389f('0xb38')][_0x1d12db]['id']===_0x2fa511['id']&&(_0x57458b[_0x20389f('0xb38')][_0x1d12db][_0x20389f('0x2378')]=![],_0x3231bd[_0x20389f('0x1514')](_0x57458b[_0x20389f('0xb38')][_0x1d12db]));}_0x57458b[_0x20389f('0xb38')]=_0x3231bd;}else{if(!_0x39706f[_0x20389f('0x1a2b')])return _0x5925c5['userProfileResource'][_0x20389f('0xd83')]({'sectionId':_0x39706f['id']})[_0x20389f('0xa44')][_0x20389f('0x1166')](function(_0x12137f){const _0x55a83a=_0x20389f,_0xdd0f32=_0x2cfb05()[_0x55a83a('0x2563')](_0x12137f[_0x55a83a('0x269a')],function(_0x4cf519){const _0x1885ac=_0x55a83a;return _0x2cfb05()['find'](_0x57458b[_0x1885ac('0xb38')],{'id':_0x4cf519[_0x1885ac('0x24e8')]});});let _0x57f5ee=null;_0x57458b['tag']&&(_0x57f5ee=_0x2cfb05()[_0x55a83a('0xc38')](_0x57458b[_0x55a83a('0xb38')],{'name':_0x57458b[_0x55a83a('0x1446')][_0x55a83a('0x1446')]}));if(_0x57f5ee&&!_0x2cfb05()[_0x55a83a('0x1798')](_0xdd0f32,['id',_0x57f5ee['id']])){const _0x427629=_0x2cfb05()[_0x55a83a('0xc38')](_0x57458b['tags'],{'id':_0x57f5ee['id']});_0x427629[_0x55a83a('0x2378')]=![],_0xdd0f32[_0x55a83a('0x1514')](_0x427629);}_0x57458b[_0x55a83a('0xb38')]=_0xdd0f32;});}})[_0x5ee6f9('0x1a80')](function(_0xe1c06){const _0x1a5a22=_0x5ee6f9;_0x46ce6f[_0x1a5a22('0xfc9')]({'title':_0xe1c06[_0x1a5a22('0x52d')]?'API:'+_0xe1c06['status']+'\x20-\x20'+_0xe1c06['statusText']:'SYSTEM:GETtags','msg':_0xe1c06[_0x1a5a22('0x25f4')]?JSON[_0x1a5a22('0xbac')](_0xe1c06[_0x1a5a22('0x25f4')]):_0xe1c06[_0x1a5a22('0x1586')]()});});function _0x3f758a(){const _0x3cfcfe=_0x5ee6f9;_0x57458b['errors']=[];const _0x549747=[];_0x57458b['tag']['type']&&_0x57458b['tag'][_0x3cfcfe('0x1345')][_0x3cfcfe('0x2574')]()==='outbound'&&_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x83f')]===_0x3cfcfe('0x867')&&(_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x2026')]=_0x181c7d[_0x3cfcfe('0x2848')]?(_0x57458b[_0x3cfcfe('0x1446')]['prefix']||'')+'${EXTEN:'+_0x181c7d[_0x3cfcfe('0x2848')]+'}':(_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x265a')]||'')+_0x3cfcfe('0x1d1'),_0x181c7d[_0x3cfcfe('0x28cb')]!==_0x3cfcfe('0x192')?_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0xd39')][_0x3cfcfe('0x2379')](_0x3cfcfe('0x1059'))<0x0&&(_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0xd39')]+=_0x3cfcfe('0x1059')):_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0xd39')]=_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0xd39')]['replace'](_0x3cfcfe('0x1059'),''));const _0x25f827=_0x2cfb05()[_0x3cfcfe('0xc38')](_0x57458b['tags'],{'name':_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x1446')]});_0x25f827&&(_0x57458b[_0x3cfcfe('0x1446')]['TagId']=_0x25f827['id']);if(_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x83f')]&&_0x57458b[_0x3cfcfe('0x1446')]['appType']===_0x3cfcfe('0x2853')){}else switch((_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x746')]||_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x83f')])[_0x3cfcfe('0x2574')]()){case _0x3cfcfe('0xceb'):_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x823')]=_0x57458b['tag'][_0x3cfcfe('0x4f0')]+'='+_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x18e0')];break;case'custom':break;default:_0x549747[0x0]=_0x57458b[_0x3cfcfe('0x1446')][_0x3cfcfe('0x1446')],_0x57458b['tag']['appdata']=_0x549747['join'](',');}_0x214ea0(_0x57458b['tag']);}function _0x214ea0(_0x3d36ac){_0x35545c['hide'](_0x3d36ac);}}const _0x3e0f76=_0xb52a96;_0x19dcaf[_0x36e6f4('0x1294')]=['$cookies',_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),'$mdDialog','$document',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x19dcaf(_0x2efe1b,_0x135e17,_0x51dbe1,_0x3108fe,_0x5758ea,_0x3b1112,_0x300286,_0x9f0f16,_0x4c9f19,_0x19fd0a,_0x254174){const _0x49462c=_0x36e6f4,_0xad43cf=this;_0xad43cf['currentUser']=_0x254174['getCurrentUser'](),_0xad43cf[_0x49462c('0x27e5')]={},_0xad43cf['smsAccountInteractions']={'count':0x0,'rows':[]},_0xad43cf['selectedSmsAccountInteractions']=[],_0xad43cf['crudPermissions'],_0xad43cf[_0x49462c('0x2218')]={'read':_0x49462c('0x15d7'),'closed':_0x49462c('0x15d7'),'sort':_0x49462c('0x2537'),'includeAll':_0x49462c('0xf3b'),'limit':0xa,'page':0x1},_0xad43cf[_0x49462c('0x24d5')]=_0x1212ae,_0xad43cf['deleteConfirm']=_0x1d7d21,_0xad43cf['smsInteractionDownload']=_0xe20991,_0xad43cf[_0x49462c('0x103b')]=_0x5c8a91,_0xad43cf['getSmsAccountInteractions']=_0x39efeb,_0xad43cf[_0x49462c('0x1df4')]=_0x51737b,_0xad43cf[_0x49462c('0x138b')]=_0x3f0df0,_0xad43cf[_0x49462c('0x131b')]=_0x4d85fe,_0xad43cf[_0x49462c('0x19a1')]=_0x467351,_0xad43cf[_0x49462c('0x722')]=_0x30870b;function _0x1212ae(_0x39a388,_0x489201){const _0x5ea2f4=_0x49462c;_0xad43cf[_0x5ea2f4('0x27e5')]=_0x39a388,_0xad43cf[_0x5ea2f4('0x243c')]=typeof _0x489201!=='undefined'?_0x489201:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0xad43cf['query'][_0x5ea2f4('0xa74')]=_0xad43cf[_0x5ea2f4('0x27e5')]['id'],_0xad43cf[_0x5ea2f4('0x1291')]={'fields':_0x4bc912()},_0x5463c9();}function _0x5463c9(){const _0x22a7e3=_0x49462c;return _0x19fd0a['tag'][_0x22a7e3('0xd83')]()[_0x22a7e3('0xa44')][_0x22a7e3('0x1166')](function(_0x14e552){const _0x1ca2e3=_0x22a7e3;_0xad43cf[_0x1ca2e3('0xb38')]=_0x14e552||{'count':0x0,'rows':[]};})[_0x22a7e3('0x1166')](function(){const _0x1f52cb=_0x22a7e3;_0xad43cf[_0x1f52cb('0x6cb')]=_0x30d574();});}function _0x30d574(){const _0x4dddfe=_0x49462c;return[{'name':_0x4dddfe('0x2567'),'key':_0x4dddfe('0x262'),'type':_0x4dddfe('0x1643'),'label':_0x4dddfe('0x16d9')},{'name':_0x4dddfe('0x116c'),'key':_0x4dddfe('0x123'),'type':_0x4dddfe('0x88a'),'label':_0x4dddfe('0x379'),'customOptions':[{'value':0x0,'translate':_0x4dddfe('0x2c8')},{'value':0x1,'translate':_0x4dddfe('0x1057')},{'value':null,'translate':_0x4dddfe('0x2150')}]},{'name':_0x4dddfe('0x28f6'),'key':_0x4dddfe('0xa5b'),'type':_0x4dddfe('0x88a'),'label':_0x4dddfe('0xe32'),'customOptions':[{'value':0x0,'translate':_0x4dddfe('0xdeb')},{'value':0x1,'translate':_0x4dddfe('0x58f')},{'value':null,'translate':_0x4dddfe('0x2150')}]},{'name':_0x4dddfe('0x89b'),'key':_0x4dddfe('0x122a'),'type':'select','label':_0x4dddfe('0x1db1'),'customOptions':[{'value':_0x4dddfe('0x15d7'),'translate':'DASHBOARDS.NOT_ASSIGNED'},{'value':undefined,'translate':_0x4dddfe('0x2150')}]},{'name':_0x4dddfe('0x1b35'),'key':_0x4dddfe('0x1446'),'type':_0x4dddfe('0x2162'),'label':_0x4dddfe('0x1669'),'options':_0xad43cf[_0x4dddfe('0xb38')][_0x4dddfe('0x269a')],'placeholder':_0x4dddfe('0x2223')}];}function _0x4bc912(){const _0x5891ec=_0x49462c;return[{'name':'Id','column':'id','type':_0x5891ec('0xc45')},{'name':_0x5891ec('0x21a4'),'column':_0x5891ec('0x21a4'),'type':_0x5891ec('0x1a01'),'options':{'searchFields':['firstName',_0x5891ec('0xeb0'),'email'],'route':{'model':'cmContact','action':_0x5891ec('0xd83'),'params':{'fields':_0x5891ec('0x18eb'),'Contact':'@autocomplete','nolimit':!![]}},'extraOperators':[_0x5891ec('0x2836')],'excludedOperators':[_0x5891ec('0x2646')]}},{'name':_0x5891ec('0x36e'),'column':_0x5891ec('0x210d'),'type':_0x5891ec('0x1640'),'options':{'excludedOperators':[_0x5891ec('0x110'),'$ne']}},{'name':'Body','column':'plainBody','type':_0x5891ec('0x1640'),'options':{'excludedOperators':['$eq',_0x5891ec('0x2646')]}},{'name':_0x5891ec('0x28f6'),'column':_0x5891ec('0xa5b'),'type':'select','values':[{'id':0x0,'translate':_0x5891ec('0xdeb')},{'id':0x1,'translate':_0x5891ec('0x58f')}],'options':{'excludedOperators':[_0x5891ec('0x2646')]}},{'name':'Agent','column':_0x5891ec('0x1a6f'),'type':_0x5891ec('0x1a01'),'options':{'table':'i','route':{'model':'user','action':_0x5891ec('0xd83'),'params':{'role':_0x5891ec('0x1eff'),'fields':_0x5891ec('0xce1'),'nolimit':!![]}},'searchFields':[_0x5891ec('0x6e1'),_0x5891ec('0x4f0')],'extraOperators':[_0x5891ec('0x2836')],'excludedOperators':[_0x5891ec('0x2646')]}},{'name':_0x5891ec('0x21c2'),'column':_0x5891ec('0x1b35'),'type':_0x5891ec('0x2162'),'options':{'route':{'model':_0x5891ec('0x1446'),'action':'get','params':{'nolimit':!![]}},'excludedOperators':[_0x5891ec('0x18d')]}},{'name':_0x5891ec('0x2567'),'column':_0x5891ec('0x262'),'type':_0x5891ec('0x1643'),'options':{'excludedOperators':[_0x5891ec('0x2646')]}},{'name':'Read','column':'unreadMessages','type':_0x5891ec('0x88a'),'values':[{'id':0x1,'translate':_0x5891ec('0x1057')},{'id':0x0,'translate':'DASHBOARDS.UNREAD'}],'options':{'excludedOperators':[_0x5891ec('0x2646')]}}];}function _0x3f0df0(){const _0x2e9f63=_0x49462c;_0x300286[_0x2e9f63('0x1f80')]({'controller':_0x2e9f63('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0x2e9f63('0x1194')](_0x9f0f16['body']),'clickOutsideToClose':![],'locals':{'fields':_0xad43cf[_0x2e9f63('0x1291')][_0x2e9f63('0xfe2')],'color':undefined,'storagePath':_0x2e9f63('0xe1d')},'fullscreen':!![]})[_0x2e9f63('0x1166')](function(_0x4eb551){const _0x360f97=_0x2e9f63;_0xad43cf[_0x360f97('0x2218')][_0x360f97('0xe07')]=_0x4eb551===![]?undefined:_0x4eb551;if(_0xad43cf[_0x360f97('0x2218')][_0x360f97('0xe07')])_0x39efeb();else _0x4eb551===![]&&_0x39efeb();})[_0x2e9f63('0x1a80')](function(_0x387e48){const _0x36504e=_0x2e9f63;_0x4c9f19[_0x36504e('0xfc9')]({'title':_0x36504e('0x2272'),'msg':_0x387e48[_0x36504e('0x25f4')]?JSON['stringify'](_0x387e48[_0x36504e('0x25f4')]['message']):_0x387e48[_0x36504e('0x1586')]()});});}function _0xe20991(_0x161154,_0x5798fa,_0x3f5e39){const _0x2873e4=_0x49462c;return _0x19fd0a[_0x2873e4('0x14c3')]['download']({'id':_0x161154['id'],'exists':!![],'attachments':_0x3f5e39})[_0x2873e4('0xa44')][_0x2873e4('0x1166')](function(_0x5e7879){const _0x183452=_0x2873e4,_0x292394=[_0x5e7879[_0x183452('0x20ed')]];let _0x5c61df='interaction'+_0x161154['id'];const _0x1f56e9=new Blob(_0x292394,{'type':_0x5e7879[_0x183452('0x1345')]});_0x5c61df=_0x183452('0x1c3d')+_0x161154['id']+_0x183452('0x806');const _0x44f53a=window['document'][_0x183452('0xdd')]('a');_0x44f53a[_0x183452('0xffd')](_0x183452('0x14f9'),URL[_0x183452('0x215a')](_0x1f56e9)),_0x44f53a[_0x183452('0xffd')](_0x183452('0x2ad'),_0x5c61df),document[_0x183452('0x8d2')][_0x183452('0x21a')](_0x44f53a),_0x44f53a['click']();})[_0x2873e4('0x1a80')](function(_0x3ec695){const _0x4b5181=_0x2873e4;if(_0x3ec695['data']&&_0x3ec695[_0x4b5181('0x25f4')]['errors']&&_0x3ec695[_0x4b5181('0x25f4')][_0x4b5181('0x61a')]['length'])for(let _0x4d81d3=0x0;_0x4d81d3<_0x3ec695[_0x4b5181('0x25f4')][_0x4b5181('0x61a')][_0x4b5181('0x264b')];_0x4d81d3+=0x1){_0x4c9f19[_0x4b5181('0xfc9')]({'title':_0x3ec695[_0x4b5181('0x25f4')][_0x4b5181('0x61a')][_0x4d81d3][_0x4b5181('0x1345')],'msg':_0x3ec695[_0x4b5181('0x25f4')]['errors'][_0x4d81d3][_0x4b5181('0x1e70')]});}else _0x4c9f19[_0x4b5181('0xfc9')]({'title':_0x3ec695['status']?_0x4b5181('0x1e21')+_0x3ec695[_0x4b5181('0x52d')]+'\x20-\x20'+_0x3ec695[_0x4b5181('0xe1b')]:_0x4b5181('0x24d0'),'msg':_0x3ec695['data']?JSON[_0x4b5181('0xbac')](_0x3ec695[_0x4b5181('0x25f4')]['message']):_0x3ec695[_0x4b5181('0x1586')]()});});}function _0x1d7d21(_0x4aeb12,_0x586250){const _0x12db6b=_0x49462c,_0x20c359=_0x300286[_0x12db6b('0x1d26')]()[_0x12db6b('0xcdc')](_0x12db6b('0xced'))[_0x12db6b('0xf3c')](''+(_0x4aeb12['name']||_0x4aeb12['id']&&_0x2cfb05()[_0x12db6b('0x114b')](_0x12db6b('0x2625'))+_0x4aeb12['id']||_0x12db6b('0x25e6'))+_0x12db6b('0xace')+_0x12db6b('0x3f3'))[_0x12db6b('0x8e8')](_0x12db6b('0xa04'))[_0x12db6b('0x203b')](_0x586250)['ok']('OK')[_0x12db6b('0x3f')]('CANCEL');_0x300286[_0x12db6b('0x1f80')](_0x20c359)[_0x12db6b('0x1166')](function(){_0x467351(_0x4aeb12);},function(){const _0x611fc0=_0x12db6b;console[_0x611fc0('0x455')]('CANCEL');});}function _0x5c8a91(_0x3802a0){const _0x2e184e=_0x49462c;_0xad43cf[_0x2e184e('0x243f')]=_0x3802a0||{'count':0x0,'rows':[]};for(let _0x227519=0x0;_0x227519<_0xad43cf[_0x2e184e('0x243f')][_0x2e184e('0x269a')][_0x2e184e('0x264b')];_0x227519+=0x1){const _0x5c9e9a=_0xad43cf[_0x2e184e('0x243f')][_0x2e184e('0x269a')][_0x227519];_0x42ff24(_0x5c9e9a),_0x5c9e9a[_0x2e184e('0x121b')][_0x2e184e('0x4f0')]=_0x374bc7(_0x5c9e9a);}}function _0x39efeb(){const _0x5ba7bf=_0x49462c;_0xad43cf[_0x5ba7bf('0x2218')][_0x5ba7bf('0x1098')]=(_0xad43cf[_0x5ba7bf('0x2218')][_0x5ba7bf('0x1a43')]-0x1)*_0xad43cf[_0x5ba7bf('0x2218')][_0x5ba7bf('0x163f')],_0xad43cf[_0x5ba7bf('0x1f48')]=_0x19fd0a['smsInteraction'][_0x5ba7bf('0xd83')](_0xad43cf['query'],_0x5c8a91)[_0x5ba7bf('0xa44')];}function _0x51737b(_0x1af0b4,_0x2c14e5){const _0x16306f=_0x49462c;_0x300286[_0x16306f('0x1f80')]({'controller':_0x16306f('0x19ad'),'controllerAs':'vm','templateUrl':_0xbfcb18,'parent':angular[_0x16306f('0x1194')](_0x9f0f16[_0x16306f('0x8d2')]),'targetEvent':_0x1af0b4,'clickOutsideToClose':!![],'onShowing':function(_0x32f855){const _0x2a03ce=_0x16306f;_0x32f855['vm'][_0x2a03ce('0x24d5')]({'id':0x1,'channel':'sms','interaction':_0x2c14e5,'spy':!![]},_0x135e17['$parent']['vm'][_0x2a03ce('0xf8a')]);}});}function _0x467351(_0x2ce22d){const _0x3cc21e=_0x49462c;_0x19fd0a[_0x3cc21e('0x14c3')]['delete']({'id':_0x2ce22d['id']})[_0x3cc21e('0xa44')][_0x3cc21e('0x1166')](function(){const _0xaca959=_0x3cc21e;_0x2cfb05()[_0xaca959('0x127f')](_0xad43cf['smsAccountInteractions'][_0xaca959('0x269a')],{'id':_0x2ce22d['id']}),_0xad43cf[_0xaca959('0x243f')]['count']-=0x1,!_0xad43cf[_0xaca959('0x243f')][_0xaca959('0x269a')][_0xaca959('0x264b')]&&_0x39efeb(),_0x4c9f19[_0xaca959('0x103b')]({'title':'Interaction\x20deleted!','msg':_0x2ce22d[_0xaca959('0x4f0')]?_0x2ce22d[_0xaca959('0x4f0')]+_0xaca959('0x7cd'):''});})[_0x3cc21e('0x1a80')](function(_0x3e2319){const _0x10e8a1=_0x3cc21e;if(_0x3e2319[_0x10e8a1('0x25f4')]&&_0x3e2319[_0x10e8a1('0x25f4')][_0x10e8a1('0x61a')]&&_0x3e2319[_0x10e8a1('0x25f4')][_0x10e8a1('0x61a')][_0x10e8a1('0x264b')]){_0xad43cf['errors']=_0x3e2319['data']['errors']||[{'message':_0x3e2319['toString'](),'type':_0x10e8a1('0x276')}];for(let _0x554429=0x0;_0x554429<_0x3e2319[_0x10e8a1('0x25f4')][_0x10e8a1('0x61a')][_0x10e8a1('0x264b')];_0x554429++){_0x4c9f19[_0x10e8a1('0xfc9')]({'title':_0x3e2319[_0x10e8a1('0x25f4')][_0x10e8a1('0x61a')][_0x554429][_0x10e8a1('0x1345')],'msg':_0x3e2319[_0x10e8a1('0x25f4')][_0x10e8a1('0x61a')][_0x554429][_0x10e8a1('0x1e70')]});}}else _0x4c9f19[_0x10e8a1('0xfc9')]({'title':_0x3e2319['status']?'API:'+_0x3e2319[_0x10e8a1('0x52d')]+'\x20-\x20'+_0x3e2319['statusText']:_0x10e8a1('0x276'),'msg':_0x3e2319[_0x10e8a1('0x25f4')]?JSON['stringify'](_0x3e2319[_0x10e8a1('0x25f4')]['message']):_0x3e2319['message']||_0x3e2319['toString']()});});}function _0x4d85fe(){const _0x4eceb5=_0x49462c,_0x1d08b9=angular[_0x4eceb5('0x225f')](_0xad43cf[_0x4eceb5('0x562')]);return _0xad43cf[_0x4eceb5('0x562')]=[],_0x1d08b9;}function _0x30870b(_0x17c9c9){const _0x5067d7=_0x49462c,_0x24afc8=_0x300286[_0x5067d7('0x1d26')]()[_0x5067d7('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20interactions?')[_0x5067d7('0xf3c')](_0x5067d7('0x12b5')+_0xad43cf[_0x5067d7('0x562')][_0x5067d7('0x264b')]+_0x5067d7('0x196d')+_0x5067d7('0x3f3'))[_0x5067d7('0x8e8')]('delete\x20interactions')[_0x5067d7('0x203b')](_0x17c9c9)['ok']('OK')[_0x5067d7('0x3f')](_0x5067d7('0x2d3'));_0x300286[_0x5067d7('0x1f80')](_0x24afc8)[_0x5067d7('0x1166')](function(){const _0x5f47d1=_0x5067d7;_0xad43cf['selectedSmsAccountInteractions'][_0x5f47d1('0x2782')](function(_0x2276a3){_0x467351(_0x2276a3);}),_0xad43cf[_0x5f47d1('0x562')]=[];});}function _0x42ff24(_0x3ec987){const _0x201545=_0x49462c;_0x3ec987[_0x201545('0x21a4')]?(_0x3ec987[_0x201545('0x15cf')]=(_0x3ec987['Contact'][_0x201545('0x18cb')]||'')+'\x20'+(_0x3ec987[_0x201545('0x21a4')][_0x201545('0xeb0')]||''),_0x3ec987['contactInfo']=_0x3ec987[_0x201545('0x21a4')]['mobile']):_0x3ec987[_0x201545('0x15cf')]=_0x5758ea['instant']('DASHBOARDS.UNKNOWN');}function _0x374bc7(_0x17e0ac){const _0x4c9647=_0x49462c;if(_0x17e0ac[_0x4c9647('0x122a')])return _0x17e0ac[_0x4c9647('0x122a')]===_0xad43cf[_0x4c9647('0x98')]['id']?_0x5758ea[_0x4c9647('0x25cc')](_0x4c9647('0x15ae')):_0x17e0ac[_0x4c9647('0x121b')][_0x4c9647('0x6e1')]+'\x20<'+_0x17e0ac[_0x4c9647('0x121b')][_0x4c9647('0x1eef')]+'>';return _0x5758ea[_0x4c9647('0x25cc')]('DASHBOARDS.NOT_ASSIGNED');}let _0x5b4fbe=!![],_0x11248d=0x1;_0x135e17[_0x49462c('0xe83')](_0x49462c('0x28b4'),function(_0x21864f,_0x58b964){const _0x1ae1e6=_0x49462c;_0x5b4fbe?_0x3b1112(function(){_0x5b4fbe=![];}):(!_0x58b964&&(_0x11248d=_0xad43cf[_0x1ae1e6('0x2218')]['page']),_0x21864f!==_0x58b964&&(_0xad43cf['query'][_0x1ae1e6('0x1a43')]=0x1),!_0x21864f&&(_0xad43cf[_0x1ae1e6('0x2218')]['page']=_0x11248d),_0x39efeb());});}const _0x13de71=_0x19dcaf,_0x48a4ce=_0x2734b2['p']+_0x36e6f4('0x166d');_0x1eddc2[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q','$translate',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x1eddc2(_0xb4850,_0x352863,_0x52606a,_0x54fa97,_0x369344,_0x5c98a3,_0xbd12f6,_0x4fff72,_0x32db08,_0x477a72,_0x24eb07){const _0x5e77fe=_0x36e6f4,_0xf5098e=this;_0xf5098e[_0x5e77fe('0x98')]=_0x24eb07[_0x5e77fe('0x26cd')](),_0xf5098e[_0x5e77fe('0x27e5')]={},_0xf5098e[_0x5e77fe('0x1c60')]={'count':0x0,'rows':[]},_0xf5098e[_0x5e77fe('0x2184')]=[],_0xf5098e[_0x5e77fe('0x243c')],_0xf5098e[_0x5e77fe('0x2218')]={'fields':'createdAt,updatedAt,id,key,value,description','limit':0xa,'page':0x1},_0xf5098e[_0x5e77fe('0x24d5')]=_0x17adc6,_0xf5098e['deleteConfirm']=_0x5b046f,_0xf5098e['success']=_0x1db85e,_0xf5098e[_0x5e77fe('0x1eab')]=_0x1eb093,_0xf5098e['createOrEditSmsAccountSmsCannedAnswer']=_0xa15f42,_0xf5098e['exportSelectedSmsAccountSmsCannedAnswers']=_0x35c032,_0xf5098e[_0x5e77fe('0x2274')]=_0x4374cb,_0xf5098e['deleteSelectedSmsAccountSmsCannedAnswers']=_0x5d0f99;function _0x17adc6(_0x30b243,_0x54d71d){const _0x1b3e63=_0x5e77fe;_0xf5098e[_0x1b3e63('0x27e5')]=_0x30b243,_0xf5098e[_0x1b3e63('0x243c')]=typeof _0x54d71d!==_0x1b3e63('0x1048')?_0x54d71d:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0xf5098e[_0x1b3e63('0x2218')]['SmsAccountId']=_0xf5098e[_0x1b3e63('0x27e5')]['id'],_0xf5098e[_0x1b3e63('0x2218')]['id']=_0xf5098e[_0x1b3e63('0x27e5')]['id'],_0x1eb093();}function _0x5b046f(_0x2691ab,_0x1002e1){const _0x200231=_0x5e77fe,_0x1751c9=_0xbd12f6[_0x200231('0x1d26')]()['title'](_0x200231('0x14c1'))['htmlContent'](''+(_0x2691ab[_0x200231('0x4f0')]||_0x2691ab['id']&&_0x2cfb05()[_0x200231('0x114b')](_0x200231('0x1c8e'))+_0x2691ab['id']||_0x200231('0x123f'))+''+_0x200231('0x3f3'))[_0x200231('0x8e8')]('delete\x20smsCannedAnswer')[_0x200231('0x203b')](_0x1002e1)['ok']('OK')['cancel']('CANCEL');_0xbd12f6['show'](_0x1751c9)[_0x200231('0x1166')](function(){_0x4374cb(_0x2691ab);},function(){const _0x813c35=_0x200231;console['log'](_0x813c35('0x2d3'));});}function _0x1db85e(_0xf9261){const _0x38bf92=_0x5e77fe;_0xf5098e[_0x38bf92('0x1c60')]=_0xf9261||{'count':0x0,'rows':[]};}function _0x1eb093(){const _0x176acb=_0x5e77fe;_0xf5098e[_0x176acb('0x2218')][_0x176acb('0x1098')]=(_0xf5098e['query']['page']-0x1)*_0xf5098e['query'][_0x176acb('0x163f')],_0xf5098e[_0x176acb('0x1f48')]=_0x477a72[_0x176acb('0x27e5')]['getAnswers'](_0xf5098e[_0x176acb('0x2218')],_0x1db85e)[_0x176acb('0xa44')];}function _0xa15f42(_0xb432fd,_0x2da755){const _0x5343ee=_0x5e77fe;_0xbd12f6[_0x5343ee('0x1f80')]({'controller':_0x5343ee('0x8d0'),'controllerAs':'vm','templateUrl':_0x48a4ce,'parent':angular[_0x5343ee('0x1194')](_0x4fff72['body']),'targetEvent':_0xb432fd,'clickOutsideToClose':!![],'locals':{'smsAccount':_0xf5098e[_0x5343ee('0x27e5')],'smsCannedAnswer':_0x2da755,'smsCannedAnswers':_0xf5098e[_0x5343ee('0x1c60')][_0x5343ee('0x269a')],'license':null,'setting':null,'crudPermissions':_0xf5098e[_0x5343ee('0x243c')]}});}function _0x4374cb(_0x31814f){const _0x6cdc10=_0x5e77fe;_0x477a72[_0x6cdc10('0x1b1f')][_0x6cdc10('0x906')]({'id':_0x31814f['id']})[_0x6cdc10('0xa44')][_0x6cdc10('0x1166')](function(){const _0x1eb6bc=_0x6cdc10;_0x2cfb05()[_0x1eb6bc('0x127f')](_0xf5098e[_0x1eb6bc('0x1c60')][_0x1eb6bc('0x269a')],{'id':_0x31814f['id']}),_0xf5098e[_0x1eb6bc('0x1c60')][_0x1eb6bc('0x240f')]-=0x1,!_0xf5098e[_0x1eb6bc('0x1c60')][_0x1eb6bc('0x269a')][_0x1eb6bc('0x264b')]&&_0x1eb093(),_0x32db08[_0x1eb6bc('0x103b')]({'title':_0x1eb6bc('0x44'),'msg':_0x31814f[_0x1eb6bc('0x4f0')]?_0x31814f['name']+'\x20has\x20been\x20deleted!':''});})[_0x6cdc10('0x1a80')](function(_0x48b884){const _0x24196e=_0x6cdc10;if(_0x48b884[_0x24196e('0x25f4')]&&_0x48b884[_0x24196e('0x25f4')][_0x24196e('0x61a')]&&_0x48b884[_0x24196e('0x25f4')][_0x24196e('0x61a')][_0x24196e('0x264b')]){_0xf5098e[_0x24196e('0x61a')]=_0x48b884[_0x24196e('0x25f4')][_0x24196e('0x61a')]||[{'message':_0x48b884[_0x24196e('0x1586')](),'type':_0x24196e('0x276')}];for(let _0x27fc39=0x0;_0x27fc39<_0x48b884['data'][_0x24196e('0x61a')][_0x24196e('0x264b')];_0x27fc39++){_0x32db08[_0x24196e('0xfc9')]({'title':_0x48b884[_0x24196e('0x25f4')][_0x24196e('0x61a')][_0x27fc39]['type'],'msg':_0x48b884['data'][_0x24196e('0x61a')][_0x27fc39][_0x24196e('0x1e70')]});}}else _0x32db08['error']({'title':_0x48b884[_0x24196e('0x52d')]?_0x24196e('0x1e21')+_0x48b884[_0x24196e('0x52d')]+_0x24196e('0x11e1')+_0x48b884[_0x24196e('0xe1b')]:_0x24196e('0x276'),'msg':_0x48b884[_0x24196e('0x25f4')]?JSON[_0x24196e('0xbac')](_0x48b884['data'][_0x24196e('0x1e70')]):_0x48b884[_0x24196e('0x1e70')]||_0x48b884[_0x24196e('0x1586')]()});});}function _0x35c032(){const _0x4490c3=_0x5e77fe,_0x3c930d=angular[_0x4490c3('0x225f')](_0xf5098e[_0x4490c3('0x2184')]);return _0xf5098e['selectedSmsAccountSmsCannedAnswers']=[],_0x3c930d;}function _0x5d0f99(_0x4a4e37){const _0x33bff5=_0x5e77fe,_0x1b50b4=_0xbd12f6[_0x33bff5('0x1d26')]()[_0x33bff5('0xcdc')](_0x33bff5('0x2019'))[_0x33bff5('0xf3c')](_0x33bff5('0x12b5')+_0xf5098e['selectedSmsAccountSmsCannedAnswers'][_0x33bff5('0x264b')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x33bff5('0x8e8')](_0x33bff5('0x808'))[_0x33bff5('0x203b')](_0x4a4e37)['ok']('OK')['cancel'](_0x33bff5('0x2d3'));_0xbd12f6[_0x33bff5('0x1f80')](_0x1b50b4)[_0x33bff5('0x1166')](function(){const _0x185928=_0x33bff5;_0xf5098e[_0x185928('0x2184')]['forEach'](function(_0x54c426){_0x4374cb(_0x54c426);}),_0xf5098e['selectedSmsAccountSmsCannedAnswers']=[];});}let _0x1b49a6=!![],_0x18b7c6=0x1;_0x352863[_0x5e77fe('0xe83')](_0x5e77fe('0x28b4'),function(_0x468b90,_0x29eb34){const _0x5c9217=_0x5e77fe;_0x1b49a6?_0x5c98a3(function(){_0x1b49a6=![];}):(!_0x29eb34&&(_0x18b7c6=_0xf5098e[_0x5c9217('0x2218')][_0x5c9217('0x1a43')]),_0x468b90!==_0x29eb34&&(_0xf5098e[_0x5c9217('0x2218')][_0x5c9217('0x1a43')]=0x1),!_0x468b90&&(_0xf5098e[_0x5c9217('0x2218')][_0x5c9217('0x1a43')]=_0x18b7c6),_0x1eb093());});}const _0x2050c0=_0x1eddc2;_0x2c0b3f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),'smsCannedAnswers',_0x36e6f4('0x123f'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x2c0b3f(_0x3137cc,_0x3a916e,_0x1e5053,_0x30df1f,_0x4a436b,_0xe5f4b9,_0x2c73f3,_0x557cb8,_0x16f161,_0x378aeb,_0x4b3a9d,_0x4820a4,_0x483add,_0x12cdf8){const _0x3e0ec3=_0x36e6f4,_0x3c889b=this;_0x3c889b[_0x3e0ec3('0x98')]=_0x4b3a9d[_0x3e0ec3('0x26cd')](),_0x3c889b[_0x3e0ec3('0x61a')]=[],_0x3c889b['setting']=_0x483add,_0x3c889b[_0x3e0ec3('0x5c9')]=_0x4820a4,_0x3c889b['crudPermissions']=_0x12cdf8,_0x3c889b[_0x3e0ec3('0x128b')]={},_0x3c889b[_0x3e0ec3('0x2900')]=_0x3c889b['setting']&&_0x3c889b[_0x3e0ec3('0xf8a')][_0x3e0ec3('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3c889b[_0x3e0ec3('0xcdc')]=_0x3e0ec3('0x203'),_0x3c889b[_0x3e0ec3('0x123f')]=angular[_0x3e0ec3('0x225f')](_0x16f161),_0x3c889b[_0x3e0ec3('0xfc6')]=_0x557cb8,_0x3c889b[_0x3e0ec3('0x13bf')]=![];!_0x3c889b[_0x3e0ec3('0x123f')]&&(_0x3c889b[_0x3e0ec3('0x123f')]={},_0x3c889b[_0x3e0ec3('0xcdc')]=_0x3e0ec3('0x16f5'),_0x3c889b[_0x3e0ec3('0x13bf')]=!![]);_0x3a916e['params']['id']&&(_0x3c889b[_0x3e0ec3('0x123f')][_0x3e0ec3('0xa74')]=_0x3a916e[_0x3e0ec3('0x23f')]['id']);_0x3c889b[_0x3e0ec3('0x1a6c')]=_0x1f2f14,_0x3c889b[_0x3e0ec3('0x1bdd')]=_0x11709f,_0x3c889b[_0x3e0ec3('0x518')]=_0x434276,_0x3c889b[_0x3e0ec3('0x1a9c')]=_0xc02952,_0x3c889b[_0x3e0ec3('0x24a0')]=_0x375b4a;function _0x1f2f14(){const _0x4fd98d=_0x3e0ec3;_0x3c889b['errors']=[],_0x378aeb['cannedAnswer'][_0x4fd98d('0x9cc')](_0x3c889b['smsCannedAnswer'])[_0x4fd98d('0xa44')][_0x4fd98d('0x1166')](function(_0x1b84fc){const _0x4d4c9a=_0x4fd98d;_0x3c889b[_0x4d4c9a('0xfc6')][_0x4d4c9a('0x2450')](_0x1b84fc[_0x4d4c9a('0x2876')]()),_0x2c73f3[_0x4d4c9a('0x103b')]({'title':_0x4d4c9a('0x88f'),'msg':_0x3c889b[_0x4d4c9a('0x123f')]['name']?_0x3c889b['smsCannedAnswer'][_0x4d4c9a('0x4f0')]+_0x4d4c9a('0x1eda'):''}),_0x375b4a(_0x1b84fc);})[_0x4fd98d('0x1a80')](function(_0x549645){const _0x1ab10c=_0x4fd98d;if(_0x549645['data']&&_0x549645[_0x1ab10c('0x25f4')][_0x1ab10c('0x61a')]&&_0x549645[_0x1ab10c('0x25f4')][_0x1ab10c('0x61a')][_0x1ab10c('0x264b')]){_0x3c889b['errors']=_0x549645[_0x1ab10c('0x25f4')][_0x1ab10c('0x61a')]||[{'message':_0x549645['toString'](),'type':_0x1ab10c('0xcca')}];for(let _0x454b3b=0x0;_0x454b3b<_0x549645[_0x1ab10c('0x25f4')][_0x1ab10c('0x61a')][_0x1ab10c('0x264b')];_0x454b3b+=0x1){_0x2c73f3[_0x1ab10c('0xfc9')]({'title':_0x549645['data'][_0x1ab10c('0x61a')][_0x454b3b][_0x1ab10c('0x1345')],'msg':_0x549645['data'][_0x1ab10c('0x61a')][_0x454b3b][_0x1ab10c('0x1e70')]});}}else _0x2c73f3[_0x1ab10c('0xfc9')]({'title':_0x549645[_0x1ab10c('0x52d')]?_0x1ab10c('0x1e21')+_0x549645['status']+_0x1ab10c('0x11e1')+_0x549645[_0x1ab10c('0xe1b')]:_0x1ab10c('0xcca'),'msg':_0x549645[_0x1ab10c('0x25f4')]?JSON[_0x1ab10c('0xbac')](_0x549645['data']['message']):_0x549645['toString']()});});}function _0x11709f(){const _0x4ff982=_0x3e0ec3;_0x3c889b[_0x4ff982('0x61a')]=[],_0x378aeb[_0x4ff982('0x1b1f')][_0x4ff982('0x1449')]({'id':_0x3c889b[_0x4ff982('0x123f')]['id']},_0x3c889b['smsCannedAnswer'])['$promise']['then'](function(_0x267d38){const _0x38da64=_0x4ff982,_0x34d575=_0x2cfb05()[_0x38da64('0xc38')](_0x3c889b[_0x38da64('0xfc6')],{'id':_0x267d38['id']});_0x34d575&&_0x2cfb05()[_0x38da64('0xcc3')](_0x34d575,_0x2cfb05()['pick'](_0x267d38[_0x38da64('0x2876')](),_0x2cfb05()[_0x38da64('0x14a4')](_0x34d575))),_0x2c73f3[_0x38da64('0x103b')]({'title':_0x38da64('0x135e'),'msg':_0x3c889b[_0x38da64('0x123f')][_0x38da64('0x4f0')]?_0x3c889b[_0x38da64('0x123f')][_0x38da64('0x4f0')]+_0x38da64('0x7d'):''}),_0x375b4a(_0x267d38);})[_0x4ff982('0x1a80')](function(_0x51db9b){const _0x7d5d05=_0x4ff982;if(_0x51db9b[_0x7d5d05('0x25f4')]&&_0x51db9b['data']['errors']&&_0x51db9b[_0x7d5d05('0x25f4')][_0x7d5d05('0x61a')][_0x7d5d05('0x264b')]){_0x3c889b[_0x7d5d05('0x61a')]=_0x51db9b[_0x7d5d05('0x25f4')][_0x7d5d05('0x61a')]||[{'message':_0x51db9b[_0x7d5d05('0x1586')](),'type':_0x7d5d05('0x122e')}];for(let _0x18ff8e=0x0;_0x18ff8e<_0x51db9b[_0x7d5d05('0x25f4')][_0x7d5d05('0x61a')][_0x7d5d05('0x264b')];_0x18ff8e++){_0x2c73f3[_0x7d5d05('0xfc9')]({'title':_0x51db9b['data'][_0x7d5d05('0x61a')][_0x18ff8e][_0x7d5d05('0x1345')],'msg':_0x51db9b['data'][_0x7d5d05('0x61a')][_0x18ff8e][_0x7d5d05('0x1e70')]});}}else _0x2c73f3[_0x7d5d05('0xfc9')]({'title':_0x51db9b[_0x7d5d05('0x52d')]?_0x7d5d05('0x1e21')+_0x51db9b['status']+_0x7d5d05('0x11e1')+_0x51db9b[_0x7d5d05('0xe1b')]:_0x7d5d05('0x122e'),'msg':_0x51db9b['data']?JSON['stringify'](_0x51db9b[_0x7d5d05('0x25f4')]['message']):_0x51db9b['toString']()});});}function _0x434276(_0x4d397f){const _0x3722a9=_0x3e0ec3;_0x3c889b[_0x3722a9('0x61a')]=[];const _0x4d19cc=_0x30df1f[_0x3722a9('0x1d26')]()['title'](_0x3722a9('0x7fb'))[_0x3722a9('0xacc')](_0x3722a9('0x6af'))['ariaLabel'](_0x3722a9('0x136b'))['ok'](_0x3722a9('0x18'))['cancel'](_0x3722a9('0x497'))[_0x3722a9('0x203b')](_0x4d397f);_0x30df1f[_0x3722a9('0x1f80')](_0x4d19cc)['then'](function(){const _0x4422f1=_0x3722a9;_0x378aeb[_0x4422f1('0x1b1f')][_0x4422f1('0x906')]({'id':_0x3c889b[_0x4422f1('0x123f')]['id']})['$promise']['then'](function(){const _0x345155=_0x4422f1;_0x2cfb05()[_0x345155('0x127f')](_0x3c889b['smsCannedAnswers'],{'id':_0x3c889b['smsCannedAnswer']['id']}),_0x2c73f3[_0x345155('0x103b')]({'title':'SmsCannedAnswer\x20properly\x20deleted!','msg':(_0x3c889b[_0x345155('0x123f')][_0x345155('0x4f0')]||_0x345155('0x123f'))+_0x345155('0x7cd')}),_0x375b4a(_0x3c889b[_0x345155('0x123f')]);})[_0x4422f1('0x1a80')](function(_0x432371){const _0xc1f0e6=_0x4422f1;if(_0x432371[_0xc1f0e6('0x25f4')]&&_0x432371[_0xc1f0e6('0x25f4')][_0xc1f0e6('0x61a')]&&_0x432371[_0xc1f0e6('0x25f4')][_0xc1f0e6('0x61a')][_0xc1f0e6('0x264b')]){_0x3c889b['errors']=_0x432371['data'][_0xc1f0e6('0x61a')]||[{'message':_0x432371[_0xc1f0e6('0x1586')](),'type':_0xc1f0e6('0x1da9')}];for(let _0x577680=0x0;_0x577680<_0x432371['data']['errors']['length'];_0x577680++){_0x2c73f3['error']({'title':_0x432371['data'][_0xc1f0e6('0x61a')][_0x577680][_0xc1f0e6('0x1345')],'msg':_0x432371['data']['errors'][_0x577680][_0xc1f0e6('0x1e70')]});}}else _0x2c73f3[_0xc1f0e6('0xfc9')]({'title':_0x432371[_0xc1f0e6('0x52d')]?'API:'+_0x432371['status']+'\x20-\x20'+_0x432371[_0xc1f0e6('0xe1b')]:_0xc1f0e6('0x1da9'),'msg':_0x432371[_0xc1f0e6('0x25f4')]?JSON[_0xc1f0e6('0xbac')](_0x432371[_0xc1f0e6('0x25f4')][_0xc1f0e6('0x1e70')]):_0x432371[_0xc1f0e6('0x1e70')]||_0x432371['toString']()});});},function(){});}function _0xc02952(_0x5d370b){return _0x5d370b===null?undefined:new Date(_0x5d370b);}function _0x375b4a(_0x1deca1){const _0x4ae238=_0x3e0ec3;_0x30df1f[_0x4ae238('0x1197')](_0x1deca1);}}const _0x12957e=_0x2c0b3f;_0x4eab1b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'api',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x4eab1b(_0x4dbcce,_0x2b7af8,_0x25ca81,_0x53dfbc,_0x1f78b9,_0x25e82a,_0x1883ea,_0x3e9e3d,_0x3c244d,_0x401654,_0x4ef04e){const _0x2d5a26=_0x36e6f4,_0x342c03=this;_0x342c03[_0x2d5a26('0x98')]=_0x4ef04e['getCurrentUser'](),_0x342c03[_0x2d5a26('0x4ea')]={'count':0x0,'rows':[]},_0x342c03[_0x2d5a26('0x1082')]=[],_0x342c03[_0x2d5a26('0x243c')],_0x342c03[_0x2d5a26('0x178f')]={'first':_0x2d5a26('0xc31'),'second':_0x2d5a26('0x580'),'third':_0x2d5a26('0x1144')},_0x342c03[_0x2d5a26('0x2218')]={'fields':_0x2d5a26('0xf1a'),'sort':_0x2d5a26('0x14dc'),'limit':0xa,'page':0x1},_0x342c03[_0x2d5a26('0x24d5')]=_0x3725e4,_0x342c03[_0x2d5a26('0x8a2')]=_0x43312a,_0x342c03[_0x2d5a26('0x103b')]=_0x4f9cd8,_0x342c03[_0x2d5a26('0x3e')]=_0x424660,_0x342c03['createOrEditDisposition']=_0x1f7b9a,_0x342c03[_0x2d5a26('0x27c6')]=_0x59a668,_0x342c03[_0x2d5a26('0x4e2')]=_0x11df81,_0x342c03[_0x2d5a26('0x14b5')]=_0x49f55e,_0x342c03[_0x2d5a26('0x205e')]=_0x493bd1,_0x342c03[_0x2d5a26('0xd7c')]=_0x3f8077;function _0x3725e4(_0x163aa6,_0x2474ed){const _0x2b3262=_0x2d5a26;_0x342c03[_0x2b3262('0x27e5')]=_0x163aa6||{},_0x342c03[_0x2b3262('0x243c')]=typeof _0x2474ed!==_0x2b3262('0x1048')?_0x2474ed:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x342c03[_0x2b3262('0x2218')][_0x2b3262('0xa74')]=_0x342c03['smsAccount']['id'],_0x342c03[_0x2b3262('0x2218')]['id']=_0x342c03[_0x2b3262('0x27e5')]['id'],_0x424660();}function _0x1f7b9a(_0x377575,_0x21dcf9){const _0x224e17=_0x2d5a26;_0x1f78b9[_0x224e17('0x1f80')]({'controller':_0x224e17('0x17a3'),'controllerAs':'vm','templateUrl':_0x14e8d3,'parent':angular[_0x224e17('0x1194')](_0x25e82a[_0x224e17('0x8d2')]),'targetEvent':_0x377575,'clickOutsideToClose':!![],'locals':{'disposition':_0x21dcf9,'dispositions':_0x342c03[_0x224e17('0x4ea')][_0x224e17('0x269a')],'model':{'id':_0x342c03[_0x224e17('0x27e5')]['id'],'field':_0x224e17('0xa74')},'license':null,'setting':null,'crudPermissions':_0x342c03[_0x224e17('0x243c')]}})[_0x224e17('0x1166')](function(_0x4f5a33){if(_0x4f5a33)_0x424660();});}function _0x43312a(_0x4d50d6,_0x4e2a78){const _0x299fde=_0x2d5a26,_0x287338=_0x2cfb05()[_0x299fde('0x1798')](_0x342c03[_0x299fde('0x4ea')][_0x299fde('0x269a')],[_0x299fde('0x11fa'),_0x4d50d6['id']]),_0x4c7b85=_0x1f78b9[_0x299fde('0x1d26')]()[_0x299fde('0xcdc')](_0x3e9e3d[_0x299fde('0x25cc')]('TOOLS.NOTIFICATIONS.DISPOSITION_DELETE_TITLE'))[_0x299fde('0xacc')](_0x3e9e3d[_0x299fde('0x25cc')](_0x299fde('0x92f')+(_0x287338?_0x299fde('0xc7a'):_0x299fde('0x251e')),{'name':_0x4d50d6[_0x299fde('0x4f0')]}))['ariaLabel']('Delete\x20disposition')['targetEvent'](_0x4e2a78)['ok']('OK')['cancel'](_0x3e9e3d[_0x299fde('0x25cc')](_0x299fde('0x12a3')));_0x1f78b9['show'](_0x4c7b85)[_0x299fde('0x1166')](function(){_0x59a668(_0x4d50d6);});}function _0x4f9cd8(_0x7d50d){_0x342c03['dispositions']=_0x7d50d||{'count':0x0,'rows':[]};}function _0x424660(){const _0x573b44=_0x2d5a26;_0x342c03['query'][_0x573b44('0x1098')]=(_0x342c03[_0x573b44('0x2218')]['page']-0x1)*_0x342c03['query']['limit'],_0x342c03[_0x573b44('0x1f48')]=_0x3c244d['smsAccount'][_0x573b44('0x3e')](_0x342c03['query'],_0x4f9cd8)[_0x573b44('0xa44')];}function _0x59a668(_0x43c26a){const _0x3b5d46=_0x2d5a26;_0x3c244d[_0x3b5d46('0x12e8')][_0x3b5d46('0x906')]({'id':_0x43c26a['id']})[_0x3b5d46('0xa44')][_0x3b5d46('0x1166')](function(){const _0x2878dc=_0x3b5d46;_0x424660(),_0x401654[_0x2878dc('0x103b')]({'title':_0x3e9e3d[_0x2878dc('0x25cc')]('TOOLS.NOTIFICATIONS.DISPOSITION_DELETED_SUCCESS_TITLE')});})['catch'](function(_0x284a2d){const _0x53a7ff=_0x3b5d46;if(_0x284a2d['data']&&_0x284a2d[_0x53a7ff('0x25f4')][_0x53a7ff('0x61a')]&&_0x284a2d[_0x53a7ff('0x25f4')][_0x53a7ff('0x61a')][_0x53a7ff('0x264b')]){_0x342c03[_0x53a7ff('0x61a')]=_0x284a2d[_0x53a7ff('0x25f4')][_0x53a7ff('0x61a')]||[{'message':_0x284a2d[_0x53a7ff('0x1586')](),'type':'SYSTEM:DELETEdisposition'}];for(let _0x3b981f=0x0;_0x3b981f<_0x284a2d[_0x53a7ff('0x25f4')][_0x53a7ff('0x61a')][_0x53a7ff('0x264b')];_0x3b981f++){_0x401654['error']({'title':_0x284a2d[_0x53a7ff('0x25f4')]['errors'][_0x3b981f][_0x53a7ff('0x1345')],'msg':_0x284a2d[_0x53a7ff('0x25f4')]['errors'][_0x3b981f][_0x53a7ff('0x1e70')]});}}else _0x401654[_0x53a7ff('0xfc9')]({'title':_0x284a2d[_0x53a7ff('0x52d')]?_0x53a7ff('0x1e21')+_0x284a2d[_0x53a7ff('0x52d')]+'\x20-\x20'+_0x284a2d[_0x53a7ff('0xe1b')]:_0x53a7ff('0x1b2c'),'msg':_0x284a2d[_0x53a7ff('0x25f4')]?JSON[_0x53a7ff('0xbac')](_0x284a2d['data'][_0x53a7ff('0x1e70')]):_0x284a2d[_0x53a7ff('0x1e70')]||_0x284a2d[_0x53a7ff('0x1586')]()});});}function _0x11df81(){const _0x367136=_0x2d5a26,_0x57034f=angular[_0x367136('0x225f')](_0x342c03[_0x367136('0x1082')]);return _0x342c03[_0x367136('0x1082')]=[],_0x57034f;}function _0x49f55e(_0x429a0c){const _0x26b8f1=_0x2d5a26,_0x5da90f=_0x1f78b9[_0x26b8f1('0x1d26')]()['title'](_0x3e9e3d[_0x26b8f1('0x25cc')](_0x26b8f1('0x24fd')))[_0x26b8f1('0xacc')](_0x3e9e3d[_0x26b8f1('0x25cc')](_0x26b8f1('0x223e'),{'total':_0x342c03['selectedDispositions'][_0x26b8f1('0x264b')]}))[_0x26b8f1('0x8e8')](_0x26b8f1('0x19b'))[_0x26b8f1('0x203b')](_0x429a0c)['ok']('OK')[_0x26b8f1('0x3f')](_0x3e9e3d[_0x26b8f1('0x25cc')]('TOOLS.CANCEL'));_0x1f78b9[_0x26b8f1('0x1f80')](_0x5da90f)[_0x26b8f1('0x1166')](function(){const _0x138d6e=_0x26b8f1;_0x342c03['selectedDispositions'][_0x138d6e('0x2782')](function(_0x70e6ab){_0x59a668(_0x70e6ab);}),_0x342c03[_0x138d6e('0x1082')]=[];});}function _0x493bd1(){const _0x12a243=_0x2d5a26;_0x342c03[_0x12a243('0x1082')]=[];}function _0x3f8077(){const _0x50fce3=_0x2d5a26;_0x342c03[_0x50fce3('0x1082')]=_0x342c03['dispositions']['rows'];}let _0x1c9bde=!![],_0x22d4b2=0x1;_0x4dbcce['$watch'](_0x2d5a26('0x28b4'),function(_0x2a4c31,_0x9555a9){const _0x3f8260=_0x2d5a26;_0x1c9bde?_0x1883ea(function(){_0x1c9bde=![];}):(!_0x9555a9&&(_0x22d4b2=_0x342c03[_0x3f8260('0x2218')][_0x3f8260('0x1a43')]),_0x2a4c31!==_0x9555a9&&(_0x342c03[_0x3f8260('0x2218')][_0x3f8260('0x1a43')]=0x1),!_0x2a4c31&&(_0x342c03[_0x3f8260('0x2218')][_0x3f8260('0x1a43')]=_0x22d4b2),_0x424660());});}const _0xb9c92b=_0x4eab1b,_0xcf8d4f=_0x2734b2['p']+'src/js/modules/main/apps/sms/views/smsAccounts/edit/agentadd/agentadd.html/agentadd.html';_0x581f81[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x586'),'license','setting',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'smsAccount',_0x36e6f4('0x17aa')];function _0x581f81(_0x747b5d,_0x25db51,_0x242bf6,_0x4125b3,_0x5039cb,_0x3db9da,_0x5889f5,_0x4e7825,_0x480037,_0x4224f6,_0x1f8140,_0x2b96e2){const _0x203951=_0x36e6f4,_0x579fab=this;_0x579fab[_0x203951('0x98')]=_0x4224f6[_0x203951('0x26cd')](),_0x579fab[_0x203951('0x5c9')]=_0x3db9da,_0x579fab['setting']=_0x5889f5,_0x579fab[_0x203951('0x2900')]=_0x579fab[_0x203951('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x579fab['location']=_0x25db51[_0x203951('0x6f1')]()+_0x203951('0xc51')+_0x25db51[_0x203951('0x1690')](),_0x579fab[_0x203951('0x27e5')]=_0x1f8140||_0x747b5d['params']['smsAccount']||{},_0x579fab[_0x203951('0x17aa')]=_0x2b96e2&&_0x2b96e2[_0x203951('0x240f')]==0x1?_0x2b96e2[_0x203951('0x269a')][0x0]:null,_0x579fab['crudPermissions']=_0x4224f6[_0x203951('0xd87')](_0x579fab['userProfileSection']?_0x579fab['userProfileSection'][_0x203951('0x243c')]:null),_0x579fab[_0x203951('0x128b')]={},_0x579fab[_0x203951('0x2669')]=_0x747b5d[_0x203951('0x23f')][_0x203951('0xbe3')]||0x0,_0x579fab[_0x203951('0x1728')]=_0x52b24a,_0x579fab[_0x203951('0x31d')]=_0x480037[_0x203951('0x1fa1')],_0x579fab['gotoSmsAccounts']=_0x1e15be,_0x579fab[_0x203951('0x25b1')]=_0x1187a8,_0x4224f6[_0x203951('0x1ac6')](_0x203951('0xa7c'))?_0x4e7825[_0x203951('0xdd9')][_0x203951('0xd83')]({'fields':_0x203951('0x1776'),'sort':_0x203951('0x4f0')})[_0x203951('0xa44')]['then'](function(_0x4f28c3){const _0x192cc2=_0x203951;_0x579fab[_0x192cc2('0x8de')]=_0x4f28c3[_0x192cc2('0x269a')]||[];})['catch'](function(_0x17cf19){const _0x43296a=_0x203951;_0x480037[_0x43296a('0xfc9')]({'title':_0x17cf19['status']?_0x43296a('0x1e21')+_0x17cf19[_0x43296a('0x52d')]+_0x43296a('0x11e1')+_0x17cf19[_0x43296a('0xe1b')]:'SYSTEM:GET_LISTS','msg':_0x17cf19[_0x43296a('0x25f4')]?JSON['stringify'](_0x17cf19[_0x43296a('0x25f4')]):_0x17cf19['toString']()});}):_0x4e7825['cmList']['get']({'fields':_0x203951('0x1776'),'sort':'name'})[_0x203951('0xa44')][_0x203951('0x1166')](function(_0x2a185b){const _0x1bfaf=_0x203951;_0x579fab[_0x1bfaf('0x8de')]=_0x2a185b[_0x1bfaf('0x269a')]||[];})[_0x203951('0x1166')](function(){const _0x198319=_0x203951;return _0x4e7825[_0x198319('0x17aa')][_0x198319('0xd83')]({'userProfileId':_0x579fab[_0x198319('0x98')][_0x198319('0xb86')],'sectionId':0x12d})[_0x198319('0xa44')];})[_0x203951('0x1166')](function(_0x2f75a1){const _0x25f772=_0x203951,_0x8ce62=_0x2f75a1&&_0x2f75a1['rows']?_0x2f75a1['rows'][0x0]:null;if(!_0x8ce62){const _0x408727=[];let _0x16c0ab=null;_0x579fab[_0x25f772('0x27e5')]&&(_0x16c0ab=_0x2cfb05()[_0x25f772('0xc38')](_0x579fab[_0x25f772('0x8de')],{'id':Number(_0x579fab[_0x25f772('0x27e5')][_0x25f772('0x23c')])}));for(let _0x3c4d07=0x0;_0x3c4d07<_0x579fab['lists'][_0x25f772('0x264b')];_0x3c4d07++){_0x16c0ab&&_0x579fab['lists'][_0x3c4d07]['id']===_0x16c0ab['id']&&(_0x579fab[_0x25f772('0x8de')][_0x3c4d07]['canSelect']=![],_0x408727[_0x25f772('0x1514')](_0x579fab['lists'][_0x3c4d07]));}_0x579fab[_0x25f772('0x8de')]=_0x408727;}else{if(!_0x8ce62['autoAssociation'])return _0x4e7825['userProfileResource'][_0x25f772('0xd83')]({'sectionId':_0x8ce62['id']})[_0x25f772('0xa44')][_0x25f772('0x1166')](function(_0x12ce7c){const _0x233164=_0x25f772,_0x3095ec=_0x2cfb05()['map'](_0x12ce7c['rows'],function(_0x358547){const _0x5f015a=a0_0x3f2c;return _0x2cfb05()[_0x5f015a('0xc38')](_0x579fab[_0x5f015a('0x8de')],{'id':_0x358547[_0x5f015a('0x24e8')]});});let _0x3372f9=null;_0x579fab[_0x233164('0x27e5')]&&(_0x3372f9=_0x2cfb05()[_0x233164('0xc38')](_0x579fab[_0x233164('0x8de')],{'id':Number(_0x579fab[_0x233164('0x27e5')][_0x233164('0x23c')])}));if(_0x3372f9&&!_0x2cfb05()[_0x233164('0x1798')](_0x3095ec,['id',_0x3372f9['id']])){const _0x1818a6=_0x2cfb05()['find'](_0x579fab[_0x233164('0x8de')],{'id':_0x3372f9['id']});_0x1818a6['canSelect']=![],_0x3095ec[_0x233164('0x1514')](_0x1818a6);}_0x579fab[_0x233164('0x8de')]=_0x3095ec;});}})['catch'](function(_0x1c754f){const _0x2391e7=_0x203951;_0x480037[_0x2391e7('0xfc9')]({'title':_0x1c754f[_0x2391e7('0x52d')]?_0x2391e7('0x1e21')+_0x1c754f[_0x2391e7('0x52d')]+_0x2391e7('0x11e1')+_0x1c754f[_0x2391e7('0xe1b')]:_0x2391e7('0x1248'),'msg':_0x1c754f[_0x2391e7('0x25f4')]?JSON[_0x2391e7('0xbac')](_0x1c754f[_0x2391e7('0x25f4')]):_0x1c754f[_0x2391e7('0x1586')]()});}),_0x4224f6[_0x203951('0x1ac6')](_0x203951('0xa7c'))?_0x4e7825[_0x203951('0x1e77')][_0x203951('0xd83')]({'fields':_0x203951('0xcb8'),'sort':_0x203951('0x4f0'),'nolimit':'true'})[_0x203951('0xa44')][_0x203951('0x1166')](function(_0x1d8e1e){const _0x3f21f3=_0x203951;_0x579fab[_0x3f21f3('0xe29')]=_0x1d8e1e[_0x3f21f3('0x269a')]||[];})[_0x203951('0x1a80')](function(_0x5eb383){const _0x45ca99=_0x203951;_0x480037['error']({'title':_0x5eb383[_0x45ca99('0x52d')]?_0x45ca99('0x1e21')+_0x5eb383['status']+_0x45ca99('0x11e1')+_0x5eb383['statusText']:_0x45ca99('0x18ed'),'msg':_0x5eb383[_0x45ca99('0x25f4')]?JSON[_0x45ca99('0xbac')](_0x5eb383[_0x45ca99('0x25f4')]):_0x5eb383[_0x45ca99('0x1586')]()});}):_0x4e7825[_0x203951('0x1e77')][_0x203951('0xd83')]({'fields':_0x203951('0xcb8'),'sort':_0x203951('0x4f0'),'nolimit':'true'})[_0x203951('0xa44')]['then'](function(_0x5b62bf){const _0x2a7468=_0x203951;_0x579fab['pauses']=_0x5b62bf[_0x2a7468('0x269a')]||[];})[_0x203951('0x1166')](function(){const _0x2c9c50=_0x203951;return _0x4e7825['userProfileSection'][_0x2c9c50('0xd83')]({'userProfileId':_0x579fab[_0x2c9c50('0x98')][_0x2c9c50('0xb86')],'sectionId':0x3ed})[_0x2c9c50('0xa44')];})[_0x203951('0x1166')](function(_0x416ec1){const _0x42f4f8=_0x203951,_0x1b98a0=_0x416ec1&&_0x416ec1[_0x42f4f8('0x269a')]?_0x416ec1[_0x42f4f8('0x269a')][0x0]:null;if(!_0x1b98a0)_0x579fab[_0x42f4f8('0xe29')]=[];else{if(!_0x1b98a0[_0x42f4f8('0x1a2b')])return _0x4e7825[_0x42f4f8('0x4b5')][_0x42f4f8('0xd83')]({'sectionId':_0x1b98a0['id']})[_0x42f4f8('0xa44')][_0x42f4f8('0x1166')](function(_0x597a25){const _0x15b0fd=_0x42f4f8,_0x1cb068=_0x2cfb05()['map'](_0x597a25[_0x15b0fd('0x269a')],function(_0x1e5774){const _0x46ad2c=_0x15b0fd;return _0x2cfb05()['find'](_0x579fab[_0x46ad2c('0xe29')],{'id':_0x1e5774['resourceId']});});_0x579fab[_0x15b0fd('0xe29')][_0x15b0fd('0x2782')](function(_0x4a4122){const _0x394992=_0x15b0fd;!_0x2cfb05()[_0x394992('0x1798')](_0x1cb068,['id',_0x4a4122['id']])&&(_0x4a4122['canSelect']=![]),_0x1cb068[_0x394992('0x1514')](_0x4a4122);}),_0x579fab[_0x15b0fd('0xe29')]=_0x1cb068;});}})[_0x203951('0x1a80')](function(_0x1c6107){const _0x26667b=_0x203951;_0x480037[_0x26667b('0xfc9')]({'title':_0x1c6107[_0x26667b('0x52d')]?_0x26667b('0x1e21')+_0x1c6107[_0x26667b('0x52d')]+'\x20-\x20'+_0x1c6107['statusText']:'SYSTEM:GETpauses','msg':_0x1c6107[_0x26667b('0x25f4')]?JSON[_0x26667b('0xbac')](_0x1c6107[_0x26667b('0x25f4')]):_0x1c6107[_0x26667b('0x1586')]()});});function _0x52b24a(_0x3c4249,_0x1a301e){const _0x2ff982=_0x203951;_0x242bf6[_0x2ff982('0x1f80')]({'controller':_0x2ff982('0x962'),'controllerAs':'vm','templateUrl':_0xcf8d4f,'parent':angular[_0x2ff982('0x1194')](_0x4125b3[_0x2ff982('0x8d2')]),'targetEvent':_0x1a301e,'clickOutsideToClose':!![],'locals':{'smsAccount':_0x3c4249,'smsAccounts':_0x579fab[_0x2ff982('0x1d76')]?_0x579fab['smsAccounts'][_0x2ff982('0x269a')]:[],'crudPermissions':_0x579fab[_0x2ff982('0x243c')],'realtime':![]}});}function _0x1e15be(){const _0x4d0b5a=_0x203951;_0x747b5d['go'](_0x4d0b5a('0x248d'),{},{'reload':'app.sms.smsAccounts'});}function _0x1187a8(){const _0x42e068=_0x203951;_0x4e7825[_0x42e068('0x27e5')][_0x42e068('0x1449')]({'id':_0x579fab[_0x42e068('0x27e5')]['id']},_0x579fab['smsAccount'])['$promise'][_0x42e068('0x1166')](function(){const _0xe4c239=_0x42e068;_0x480037[_0xe4c239('0x103b')]({'title':_0xe4c239('0x1e97'),'msg':_0x579fab[_0xe4c239('0x27e5')][_0xe4c239('0x4f0')]?_0x579fab['smsAccount'][_0xe4c239('0x4f0')]+_0xe4c239('0xa17'):''});})[_0x42e068('0x1a80')](function(_0x2780cd){const _0x375c59=_0x42e068;_0x480037[_0x375c59('0xfc9')]({'title':_0x2780cd[_0x375c59('0x52d')]?_0x375c59('0x1e21')+_0x2780cd[_0x375c59('0x52d')]+_0x375c59('0x11e1')+_0x2780cd[_0x375c59('0xe1b')]:_0x375c59('0x276'),'msg':_0x2780cd['data']?JSON[_0x375c59('0xbac')](_0x2780cd[_0x375c59('0x25f4')]):_0x2780cd[_0x375c59('0x1586')]()});});}}const _0x5e5e13=_0x581f81,_0x149894=_0x2734b2['p']+_0x36e6f4('0x2321');_0x2dcf75[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x1d76'),_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x2dcf75(_0x137b81,_0x13c97d,_0x555f8a,_0x3b058f,_0x5f918f,_0x5efd5e,_0x2f78f1,_0x4591cd,_0x9e720c,_0x1dde4e,_0x512928,_0x17bb1d,_0x5912ae,_0x253c80,_0x287771,_0x5de8e9,_0x4aeb72){const _0x4c2d12=_0x36e6f4,_0xfd7ae2=this;_0xfd7ae2['license']=_0x5de8e9,_0xfd7ae2[_0x4c2d12('0xf8a')]=_0x4aeb72,_0xfd7ae2[_0x4c2d12('0x98')]=_0x287771[_0x4c2d12('0x26cd')](),_0xfd7ae2[_0x4c2d12('0x1d76')]=_0x9e720c||{'count':0x0,'rows':[]},_0xfd7ae2[_0x4c2d12('0x7f')]=_0x1dde4e,_0xfd7ae2[_0x4c2d12('0x17aa')]=_0x512928&&_0x512928[_0x4c2d12('0x240f')]==0x1?_0x512928['rows'][0x0]:null,_0xfd7ae2['crudPermissions']=_0x287771['parseCrudPermissions'](_0xfd7ae2[_0x4c2d12('0x17aa')]?_0xfd7ae2[_0x4c2d12('0x17aa')][_0x4c2d12('0x243c')]:null),_0xfd7ae2[_0x4c2d12('0x916')]=_0x4c2d12('0x1d76'),_0xfd7ae2[_0x4c2d12('0xef5')]='',_0xfd7ae2[_0x4c2d12('0x104c')]=null,_0xfd7ae2['selectedSmsAccounts']=[],_0xfd7ae2[_0x4c2d12('0x2218')]={'fields':_0x4c2d12('0x1eac'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0xfd7ae2['arraytype']=_0x2cfb05()[_0x4c2d12('0x155c')]([{'option':_0x4c2d12('0x2464'),'value':_0x4c2d12('0x114c')},{'option':_0x4c2d12('0x1b15'),'value':_0x4c2d12('0x1b1c')},{'option':_0x4c2d12('0x7ab'),'value':_0x4c2d12('0x97c')},{'option':'ClickSend','value':'\x27clicksend\x27'},{'option':_0x4c2d12('0xdd3'),'value':'\x27plivo\x27'},{'option':'Infobip','value':_0x4c2d12('0x10dc')},{'option':_0x4c2d12('0x647'),'value':_0x4c2d12('0x10f5')},{'option':_0x4c2d12('0x18b1'),'value':_0x4c2d12('0x507')},{'option':_0x4c2d12('0x546'),'value':_0x4c2d12('0x1ba3')}],function(_0x3bf1cb){const _0x38fb06=_0x4c2d12;return _0x2cfb05()[_0x38fb06('0xf3')](_0x3bf1cb[_0x38fb06('0x18e0')],new RegExp('\x27','g'),'');}),_0xfd7ae2[_0x4c2d12('0x1447')]=_0x2cfb05()[_0x4c2d12('0x155c')]([{'option':_0x4c2d12('0x1265'),'value':_0x4c2d12('0x264d')},{'option':_0x4c2d12('0x201'),'value':_0x4c2d12('0x195')},{'option':_0x4c2d12('0x1f25'),'value':_0x4c2d12('0x2458')}],function(_0x307c8e){const _0x5f109c=_0x4c2d12;return _0x2cfb05()['replace'](_0x307c8e[_0x5f109c('0x18e0')],new RegExp('\x27','g'),'');}),_0xfd7ae2[_0x4c2d12('0x1ff6')]=_0x3f387a,_0xfd7ae2[_0x4c2d12('0x5e9')]=_0x36c491,_0xfd7ae2[_0x4c2d12('0x1728')]=_0x2fd690,_0xfd7ae2[_0x4c2d12('0x8d8')]=_0x48441d,_0xfd7ae2['success']=_0x4410be,_0xfd7ae2[_0x4c2d12('0x1f5d')]=_0x4b134f,_0xfd7ae2[_0x4c2d12('0x1b03')]=_0x5047c8,_0xfd7ae2['deleteSmsAccount']=_0x315071,_0xfd7ae2[_0x4c2d12('0x17e')]=_0x2105fb,_0xfd7ae2[_0x4c2d12('0x2641')]=_0x3de27c,_0xfd7ae2[_0x4c2d12('0x1013')]=_0x318283,_0xfd7ae2[_0x4c2d12('0x1e0c')]=_0x22b0a4,_0x287771['hasRole']('admin')?_0x17bb1d[_0x4c2d12('0xdd9')][_0x4c2d12('0xd83')]({'fields':_0x4c2d12('0x1776'),'sort':'name'})[_0x4c2d12('0xa44')][_0x4c2d12('0x1166')](function(_0x379a4e){const _0x58dac7=_0x4c2d12;_0xfd7ae2[_0x58dac7('0x8de')]=_0x379a4e[_0x58dac7('0x269a')]||[];})[_0x4c2d12('0x1a80')](function(_0x57f378){const _0x12be82=_0x4c2d12;_0x253c80['error']({'title':_0x57f378[_0x12be82('0x52d')]?_0x12be82('0x1e21')+_0x57f378[_0x12be82('0x52d')]+_0x12be82('0x11e1')+_0x57f378[_0x12be82('0xe1b')]:_0x12be82('0x520'),'msg':_0x57f378['data']?JSON['stringify'](_0x57f378[_0x12be82('0x25f4')]):_0x57f378[_0x12be82('0x1586')]()});}):_0x17bb1d[_0x4c2d12('0xdd9')]['get']({'fields':_0x4c2d12('0x1776'),'sort':_0x4c2d12('0x4f0')})[_0x4c2d12('0xa44')][_0x4c2d12('0x1166')](function(_0x466e47){const _0x39f8d3=_0x4c2d12;_0xfd7ae2[_0x39f8d3('0x8de')]=_0x466e47[_0x39f8d3('0x269a')]||[];})[_0x4c2d12('0x1166')](function(){const _0x1923be=_0x4c2d12;return _0x17bb1d[_0x1923be('0x17aa')][_0x1923be('0xd83')]({'userProfileId':_0xfd7ae2[_0x1923be('0x98')][_0x1923be('0xb86')],'sectionId':0x12d})['$promise'];})[_0x4c2d12('0x1166')](function(_0x45f644){const _0x4c8239=_0x4c2d12,_0x320b85=_0x45f644&&_0x45f644[_0x4c8239('0x269a')]?_0x45f644['rows'][0x0]:null;if(!_0x320b85){const _0xc18fd4=[];let _0x50f05c=null;_0xfd7ae2[_0x4c8239('0x27e5')]&&(_0x50f05c=_0x2cfb05()[_0x4c8239('0xc38')](_0xfd7ae2['lists'],{'id':Number(_0xfd7ae2[_0x4c8239('0x27e5')]['ListId'])}));for(let _0x51ee26=0x0;_0x51ee26<_0xfd7ae2[_0x4c8239('0x8de')][_0x4c8239('0x264b')];_0x51ee26++){_0x50f05c&&_0xfd7ae2[_0x4c8239('0x8de')][_0x51ee26]['id']===_0x50f05c['id']&&(_0xfd7ae2['lists'][_0x51ee26][_0x4c8239('0x2378')]=![],_0xc18fd4[_0x4c8239('0x1514')](_0xfd7ae2[_0x4c8239('0x8de')][_0x51ee26]));}_0xfd7ae2[_0x4c8239('0x8de')]=_0xc18fd4;}else{if(!_0x320b85[_0x4c8239('0x1a2b')])return _0x17bb1d[_0x4c8239('0x4b5')][_0x4c8239('0xd83')]({'sectionId':_0x320b85['id']})['$promise'][_0x4c8239('0x1166')](function(_0x20ced6){const _0x1b680c=_0x4c8239,_0x1334ef=_0x2cfb05()[_0x1b680c('0x2563')](_0x20ced6['rows'],function(_0x58e5d3){const _0x1d70eb=_0x1b680c;return _0x2cfb05()[_0x1d70eb('0xc38')](_0xfd7ae2['lists'],{'id':_0x58e5d3[_0x1d70eb('0x24e8')]});});let _0x1ba238=null;_0xfd7ae2[_0x1b680c('0x27e5')]&&(_0x1ba238=_0x2cfb05()['find'](_0xfd7ae2[_0x1b680c('0x8de')],{'id':Number(_0xfd7ae2[_0x1b680c('0x27e5')][_0x1b680c('0x23c')])}));if(_0x1ba238&&!_0x2cfb05()[_0x1b680c('0x1798')](_0x1334ef,['id',_0x1ba238['id']])){const _0x2b1526=_0x2cfb05()['find'](_0xfd7ae2['lists'],{'id':_0x1ba238['id']});_0x2b1526[_0x1b680c('0x2378')]=![],_0x1334ef['push'](_0x2b1526);}_0xfd7ae2[_0x1b680c('0x8de')]=_0x1334ef;});}})[_0x4c2d12('0x1a80')](function(_0xe84ae4){const _0x15d4c2=_0x4c2d12;_0x253c80[_0x15d4c2('0xfc9')]({'title':_0xe84ae4['status']?'API:'+_0xe84ae4[_0x15d4c2('0x52d')]+_0x15d4c2('0x11e1')+_0xe84ae4[_0x15d4c2('0xe1b')]:_0x15d4c2('0x1248'),'msg':_0xe84ae4[_0x15d4c2('0x25f4')]?JSON[_0x15d4c2('0xbac')](_0xe84ae4[_0x15d4c2('0x25f4')]):_0xe84ae4[_0x15d4c2('0x1586')]()});});function _0x3f387a(_0x12771c){const _0x16b709=_0x4c2d12;_0x555f8a['go'](_0x16b709('0xe43'),{'id':_0x12771c['id'],'smsAccount':_0x12771c,'crudPermissions':_0xfd7ae2[_0x16b709('0x243c')]});}function _0x36c491(_0x479b97){const _0x2843ba=_0x4c2d12;_0x555f8a['go'](_0x2843ba('0xe43'),{'id':_0x479b97['id'],'tab':0x5});}function _0x2fd690(_0x4e2ef2,_0x4323ff){const _0x9979f8=_0x4c2d12;_0x5f918f[_0x9979f8('0x1f80')]({'controller':_0x9979f8('0x962'),'controllerAs':'vm','templateUrl':_0xcf8d4f,'parent':angular[_0x9979f8('0x1194')](_0x5efd5e[_0x9979f8('0x8d2')]),'targetEvent':_0x4323ff,'clickOutsideToClose':!![],'locals':{'smsAccount':_0x4e2ef2,'smsAccounts':_0xfd7ae2[_0x9979f8('0x1d76')]?_0xfd7ae2[_0x9979f8('0x1d76')]['rows']:[],'crudPermissions':_0xfd7ae2[_0x9979f8('0x243c')],'realtime':![]}});}function _0x48441d(_0x4d9569,_0x29b8b5){const _0x51aff1=_0x4c2d12,_0x5bf9fb=_0x5f918f[_0x51aff1('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x51aff1('0xb35')](_0x51aff1('0x27e5'))+'?')['htmlContent'](_0x51aff1('0x12b5')+(_0x4d9569[_0x51aff1('0x4f0')]||_0x51aff1('0x27e5'))+_0x51aff1('0xace')+_0x51aff1('0x3f3'))[_0x51aff1('0x8e8')](_0x51aff1('0x2258'))['targetEvent'](_0x29b8b5)['ok']('OK')['cancel']('CANCEL');_0x5f918f[_0x51aff1('0x1f80')](_0x5bf9fb)['then'](function(){_0x315071(_0x4d9569);},function(){const _0x52cda5=_0x51aff1;console[_0x52cda5('0x455')](_0x52cda5('0x2d3'));});}let _0x445be4=!![],_0x478b73=0x1;_0x137b81['$watch']('vm.query.filter',function(_0x40a98e,_0x4d76be){const _0x2bd6c0=_0x4c2d12;_0x445be4?_0x2f78f1(function(){_0x445be4=![];}):(!_0x4d76be&&(_0x478b73=_0xfd7ae2['query']['page']),_0x40a98e!==_0x4d76be&&(_0xfd7ae2[_0x2bd6c0('0x2218')]['page']=0x1),!_0x40a98e&&(_0xfd7ae2[_0x2bd6c0('0x2218')]['page']=_0x478b73),_0xfd7ae2[_0x2bd6c0('0x1f5d')]());});function _0x4410be(_0x325f71){const _0x202226=_0x4c2d12;_0xfd7ae2[_0x202226('0x1d76')]=_0x325f71||{'count':0x0,'rows':[]};}function _0x4b134f(){const _0x2d8fc3=_0x4c2d12;_0xfd7ae2['query'][_0x2d8fc3('0x1098')]=(_0xfd7ae2['query'][_0x2d8fc3('0x1a43')]-0x1)*_0xfd7ae2[_0x2d8fc3('0x2218')][_0x2d8fc3('0x163f')],_0x287771[_0x2d8fc3('0x1ac6')](_0x2d8fc3('0xa7c'))?_0xfd7ae2[_0x2d8fc3('0x1f48')]=_0x17bb1d[_0x2d8fc3('0x27e5')][_0x2d8fc3('0xd83')](_0xfd7ae2[_0x2d8fc3('0x2218')],_0x4410be)[_0x2d8fc3('0xa44')]:(_0xfd7ae2[_0x2d8fc3('0x2218')]['id']=_0xfd7ae2[_0x2d8fc3('0x7f')]['id'],_0xfd7ae2[_0x2d8fc3('0x2218')][_0x2d8fc3('0xe60')]=_0x2d8fc3('0x1442'),_0xfd7ae2[_0x2d8fc3('0x1f48')]=_0x17bb1d['userProfile'][_0x2d8fc3('0x263a')](_0xfd7ae2[_0x2d8fc3('0x2218')],_0x4410be)[_0x2d8fc3('0xa44')]);}function _0x5047c8(_0x1d9c2f,_0x13db07){const _0x24eded=_0x4c2d12;_0x5f918f[_0x24eded('0x1f80')]({'controller':_0x24eded('0x2799'),'controllerAs':'vm','templateUrl':_0x149894,'parent':angular['element'](_0x5efd5e[_0x24eded('0x8d2')]),'targetEvent':_0x1d9c2f,'clickOutsideToClose':!![],'locals':{'smsAccount':_0x13db07,'smsAccounts':_0xfd7ae2['smsAccounts'][_0x24eded('0x269a')],'license':_0xfd7ae2[_0x24eded('0x5c9')],'setting':_0xfd7ae2[_0x24eded('0xf8a')],'crudPermissions':_0xfd7ae2[_0x24eded('0x243c')]}});}function _0x315071(_0x17c018){const _0x50341a=_0x4c2d12;_0x17bb1d[_0x50341a('0x27e5')][_0x50341a('0x906')]({'id':_0x17c018['id']})[_0x50341a('0xa44')]['then'](function(){const _0x272b5a=_0x50341a;_0x2cfb05()[_0x272b5a('0x127f')](_0xfd7ae2[_0x272b5a('0x1d76')][_0x272b5a('0x269a')],{'id':_0x17c018['id']}),_0xfd7ae2[_0x272b5a('0x1d76')][_0x272b5a('0x240f')]-=0x1,!_0xfd7ae2[_0x272b5a('0x1d76')][_0x272b5a('0x269a')][_0x272b5a('0x264b')]&&_0xfd7ae2[_0x272b5a('0x1f5d')](),_0x253c80[_0x272b5a('0x103b')]({'title':_0x2cfb05()[_0x272b5a('0xb35')](_0x272b5a('0x27bc'))+_0x272b5a('0x2b6'),'msg':_0x17c018[_0x272b5a('0x4f0')]?_0x17c018['name']+_0x272b5a('0x7cd'):''});})['catch'](function(_0x529c90){const _0xe9344f=_0x50341a;if(_0x529c90[_0xe9344f('0x25f4')]&&_0x529c90[_0xe9344f('0x25f4')]['errors']&&_0x529c90[_0xe9344f('0x25f4')][_0xe9344f('0x61a')]['length']){_0xfd7ae2[_0xe9344f('0x61a')]=_0x529c90[_0xe9344f('0x25f4')][_0xe9344f('0x61a')]||[{'message':_0x529c90[_0xe9344f('0x1586')](),'type':_0xe9344f('0x748')}];for(let _0x180f6e=0x0;_0x180f6e<_0x529c90[_0xe9344f('0x25f4')]['errors'][_0xe9344f('0x264b')];_0x180f6e++){_0x253c80[_0xe9344f('0xfc9')]({'title':_0x529c90[_0xe9344f('0x25f4')][_0xe9344f('0x61a')][_0x180f6e]['type'],'msg':_0x529c90[_0xe9344f('0x25f4')][_0xe9344f('0x61a')][_0x180f6e][_0xe9344f('0x1e70')]});}}else _0x253c80['error']({'title':_0x529c90[_0xe9344f('0x52d')]?_0xe9344f('0x1e21')+_0x529c90[_0xe9344f('0x52d')]+'\x20-\x20'+_0x529c90[_0xe9344f('0xe1b')]:'SYSTEM:DELETEsmsAccount','msg':_0x529c90[_0xe9344f('0x25f4')]?JSON['stringify'](_0x529c90[_0xe9344f('0x25f4')]['message']):_0x529c90[_0xe9344f('0x1e70')]||_0x529c90[_0xe9344f('0x1586')]()});});}function _0x2105fb(){const _0x280d24=_0x4c2d12,_0x2f6b8f=angular[_0x280d24('0x225f')](_0xfd7ae2['selectedSmsAccounts']);return _0xfd7ae2['selectedSmsAccounts']=[],_0x2f6b8f;}function _0x3de27c(_0x229f3c){const _0x4ec927=_0x4c2d12,_0x49ac2d=_0x5f918f[_0x4ec927('0x1d26')]()[_0x4ec927('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20smsAccounts?')['htmlContent'](_0x4ec927('0x12b5')+_0xfd7ae2[_0x4ec927('0x13c7')]['length']+_0x4ec927('0x196d')+'\x20will\x20be\x20deleted.')[_0x4ec927('0x8e8')](_0x4ec927('0x1e74'))[_0x4ec927('0x203b')](_0x229f3c)['ok']('OK')[_0x4ec927('0x3f')](_0x4ec927('0x2d3'));_0x5f918f[_0x4ec927('0x1f80')](_0x49ac2d)[_0x4ec927('0x1166')](function(){const _0x20c2ef=_0x4ec927;_0xfd7ae2[_0x20c2ef('0x13c7')][_0x20c2ef('0x2782')](function(_0x2a1fab){_0x315071(_0x2a1fab);}),_0xfd7ae2[_0x20c2ef('0x13c7')]=[];});}function _0x318283(){const _0x23bf5e=_0x4c2d12;_0xfd7ae2[_0x23bf5e('0x13c7')]=[];}function _0x22b0a4(){const _0x15b0ad=_0x4c2d12;_0xfd7ae2[_0x15b0ad('0x13c7')]=_0xfd7ae2[_0x15b0ad('0x1d76')]['rows'];}}const _0x4384e7=_0x2dcf75;_0x89c62a[_0x36e6f4('0x1294')]=['$scope','$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x20c0'),_0x36e6f4('0x73c'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x89c62a(_0x2862cd,_0x4b0418,_0x842846,_0x46aa65,_0x1e4462,_0x5b68a6,_0x342d8e,_0x5136b0,_0x4839eb,_0x3ae337,_0x3cfcc8,_0x17b325,_0x559608,_0x25103b){const _0x3e9ace=_0x36e6f4,_0x2c2f09=this;_0x2c2f09[_0x3e9ace('0x98')]=_0x3cfcc8[_0x3e9ace('0x26cd')](),_0x2c2f09[_0x3e9ace('0x61a')]=[],_0x2c2f09[_0x3e9ace('0xf8a')]=_0x559608,_0x2c2f09['license']=_0x17b325,_0x2c2f09[_0x3e9ace('0x243c')]=_0x25103b,_0x2c2f09['hasModulePermissions']={},_0x2c2f09['passwordPattern']=_0x2c2f09[_0x3e9ace('0xf8a')]&&_0x2c2f09[_0x3e9ace('0xf8a')][_0x3e9ace('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2c2f09['title']='SMS.EDIT_SMSQUEUE',_0x2c2f09['smsQueue']=angular[_0x3e9ace('0x225f')](_0x4839eb),_0x2c2f09[_0x3e9ace('0x20c0')]=_0x5136b0,_0x2c2f09[_0x3e9ace('0x231f')]=![];!_0x2c2f09[_0x3e9ace('0x73c')]&&(_0x2c2f09[_0x3e9ace('0x73c')]={'strategy':'beepall','timeout':0xa},_0x2c2f09['title']=_0x3e9ace('0xb6d'),_0x2c2f09[_0x3e9ace('0x231f')]=!![]);_0x2c2f09[_0x3e9ace('0x1470')]=_0x190735,_0x2c2f09['saveSmsQueue']=_0x51c1fa,_0x2c2f09[_0x3e9ace('0x25f')]=_0x1307d6,_0x2c2f09[_0x3e9ace('0x1a9c')]=_0x35f01e,_0x2c2f09['closeDialog']=_0x40f621;function _0x190735(){const _0x5e5067=_0x3e9ace;_0x2c2f09[_0x5e5067('0x61a')]=[],_0x3ae337[_0x5e5067('0x73c')][_0x5e5067('0x9cc')](_0x2c2f09[_0x5e5067('0x73c')])[_0x5e5067('0xa44')][_0x5e5067('0x1166')](function(_0x3c4a14){const _0x2c134b=_0x5e5067;_0x2c2f09[_0x2c134b('0x20c0')]['unshift'](_0x3c4a14[_0x2c134b('0x2876')]()),_0x342d8e[_0x2c134b('0x103b')]({'title':'SmsQueue\x20properly\x20created','msg':_0x2c2f09['smsQueue'][_0x2c134b('0x4f0')]?_0x2c2f09[_0x2c134b('0x73c')][_0x2c134b('0x4f0')]+_0x2c134b('0x1eda'):''}),_0x40f621(_0x3c4a14);})[_0x5e5067('0x1a80')](function(_0x35000e){const _0x432d47=_0x5e5067;if(_0x35000e[_0x432d47('0x25f4')]&&_0x35000e[_0x432d47('0x25f4')][_0x432d47('0x61a')]&&_0x35000e[_0x432d47('0x25f4')][_0x432d47('0x61a')][_0x432d47('0x264b')]){_0x2c2f09['errors']=_0x35000e[_0x432d47('0x25f4')][_0x432d47('0x61a')]||[{'message':_0x35000e[_0x432d47('0x1586')](),'type':_0x432d47('0x1062')}];for(let _0x4f4e80=0x0;_0x4f4e80<_0x35000e[_0x432d47('0x25f4')]['errors'][_0x432d47('0x264b')];_0x4f4e80+=0x1){_0x342d8e[_0x432d47('0xfc9')]({'title':_0x35000e[_0x432d47('0x25f4')][_0x432d47('0x61a')][_0x4f4e80][_0x432d47('0x1345')],'msg':_0x35000e[_0x432d47('0x25f4')][_0x432d47('0x61a')][_0x4f4e80]['message']});}}else _0x342d8e[_0x432d47('0xfc9')]({'title':_0x35000e[_0x432d47('0x52d')]?_0x432d47('0x1e21')+_0x35000e['status']+_0x432d47('0x11e1')+_0x35000e[_0x432d47('0xe1b')]:_0x432d47('0x1062'),'msg':_0x35000e[_0x432d47('0x25f4')]?JSON[_0x432d47('0xbac')](_0x35000e[_0x432d47('0x25f4')][_0x432d47('0x1e70')]):_0x35000e[_0x432d47('0x1586')]()});});}function _0x51c1fa(){const _0x518085=_0x3e9ace;_0x2c2f09[_0x518085('0x61a')]=[],_0x3ae337[_0x518085('0x73c')][_0x518085('0x1449')]({'id':_0x2c2f09['smsQueue']['id']},_0x2c2f09[_0x518085('0x73c')])['$promise']['then'](function(_0x51cd76){const _0x2bea34=_0x518085,_0x573327=_0x2cfb05()[_0x2bea34('0xc38')](_0x2c2f09[_0x2bea34('0x20c0')],{'id':_0x51cd76['id']});_0x573327&&_0x2cfb05()[_0x2bea34('0xcc3')](_0x573327,_0x2cfb05()[_0x2bea34('0x1a08')](_0x51cd76[_0x2bea34('0x2876')](),_0x2cfb05()[_0x2bea34('0x14a4')](_0x573327))),_0x342d8e[_0x2bea34('0x103b')]({'title':_0x2bea34('0x180d'),'msg':_0x2c2f09[_0x2bea34('0x73c')]['name']?_0x2c2f09[_0x2bea34('0x73c')][_0x2bea34('0x4f0')]+_0x2bea34('0x7d'):''}),_0x40f621(_0x51cd76);})[_0x518085('0x1a80')](function(_0x4321a4){const _0x59a05c=_0x518085;if(_0x4321a4[_0x59a05c('0x25f4')]&&_0x4321a4[_0x59a05c('0x25f4')][_0x59a05c('0x61a')]&&_0x4321a4[_0x59a05c('0x25f4')][_0x59a05c('0x61a')]['length']){_0x2c2f09[_0x59a05c('0x61a')]=_0x4321a4[_0x59a05c('0x25f4')][_0x59a05c('0x61a')]||[{'message':_0x4321a4['toString'](),'type':_0x59a05c('0x2028')}];for(let _0x158fa6=0x0;_0x158fa6<_0x4321a4['data'][_0x59a05c('0x61a')]['length'];_0x158fa6++){_0x342d8e['error']({'title':_0x4321a4['data'][_0x59a05c('0x61a')][_0x158fa6][_0x59a05c('0x1345')],'msg':_0x4321a4[_0x59a05c('0x25f4')]['errors'][_0x158fa6][_0x59a05c('0x1e70')]});}}else _0x342d8e[_0x59a05c('0xfc9')]({'title':_0x4321a4[_0x59a05c('0x52d')]?_0x59a05c('0x1e21')+_0x4321a4[_0x59a05c('0x52d')]+_0x59a05c('0x11e1')+_0x4321a4[_0x59a05c('0xe1b')]:_0x59a05c('0x2028'),'msg':_0x4321a4[_0x59a05c('0x25f4')]?JSON[_0x59a05c('0xbac')](_0x4321a4['data'][_0x59a05c('0x1e70')]):_0x4321a4[_0x59a05c('0x1586')]()});});}function _0x1307d6(_0x2f7c1a){const _0x37ce39=_0x3e9ace;_0x2c2f09['errors']=[];const _0xd58208=_0x46aa65['confirm']()[_0x37ce39('0xcdc')](_0x37ce39('0x7fb'))[_0x37ce39('0xacc')]('The\x20smsQueue\x20will\x20be\x20deleted.')['ariaLabel'](_0x37ce39('0x28fc'))['ok'](_0x37ce39('0x18'))['cancel'](_0x37ce39('0x497'))['targetEvent'](_0x2f7c1a);_0x46aa65[_0x37ce39('0x1f80')](_0xd58208)[_0x37ce39('0x1166')](function(){const _0x482de8=_0x37ce39;_0x3ae337[_0x482de8('0x73c')][_0x482de8('0x906')]({'id':_0x2c2f09['smsQueue']['id']})[_0x482de8('0xa44')][_0x482de8('0x1166')](function(){const _0xe8073f=_0x482de8;_0x2cfb05()[_0xe8073f('0x127f')](_0x2c2f09[_0xe8073f('0x20c0')],{'id':_0x2c2f09[_0xe8073f('0x73c')]['id']}),_0x342d8e[_0xe8073f('0x103b')]({'title':'SmsQueue\x20properly\x20deleted!','msg':(_0x2c2f09[_0xe8073f('0x73c')][_0xe8073f('0x4f0')]||_0xe8073f('0x73c'))+_0xe8073f('0x7cd')}),_0x40f621(_0x2c2f09[_0xe8073f('0x73c')]);})[_0x482de8('0x1a80')](function(_0x1afbfc){const _0x4f4436=_0x482de8;if(_0x1afbfc['data']&&_0x1afbfc[_0x4f4436('0x25f4')]['errors']&&_0x1afbfc[_0x4f4436('0x25f4')][_0x4f4436('0x61a')][_0x4f4436('0x264b')]){_0x2c2f09[_0x4f4436('0x61a')]=_0x1afbfc['data'][_0x4f4436('0x61a')]||[{'message':_0x1afbfc[_0x4f4436('0x1586')](),'type':'api.smsQueue.delete'}];for(let _0x5b24e8=0x0;_0x5b24e8<_0x1afbfc[_0x4f4436('0x25f4')][_0x4f4436('0x61a')][_0x4f4436('0x264b')];_0x5b24e8++){_0x342d8e[_0x4f4436('0xfc9')]({'title':_0x1afbfc[_0x4f4436('0x25f4')]['errors'][_0x5b24e8][_0x4f4436('0x1345')],'msg':_0x1afbfc[_0x4f4436('0x25f4')][_0x4f4436('0x61a')][_0x5b24e8][_0x4f4436('0x1e70')]});}}else _0x342d8e[_0x4f4436('0xfc9')]({'title':_0x1afbfc['status']?_0x4f4436('0x1e21')+_0x1afbfc['status']+_0x4f4436('0x11e1')+_0x1afbfc[_0x4f4436('0xe1b')]:_0x4f4436('0x1189'),'msg':_0x1afbfc[_0x4f4436('0x25f4')]?JSON[_0x4f4436('0xbac')](_0x1afbfc[_0x4f4436('0x25f4')][_0x4f4436('0x1e70')]):_0x1afbfc[_0x4f4436('0x1e70')]||_0x1afbfc[_0x4f4436('0x1586')]()});});},function(){});}function _0x35f01e(_0x415633){return _0x415633===null?undefined:new Date(_0x415633);}function _0x40f621(_0x1e57c6){_0x46aa65['hide'](_0x1e57c6);}}const _0x53af57=_0x89c62a;_0x3e724c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x19e3'),'smsQueue',_0x36e6f4('0x20c0'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),'Auth',_0x36e6f4('0x243c')];function _0x3e724c(_0x59b12b,_0x36d259,_0x123f8,_0x17982b,_0x5b0e46,_0x1631f5,_0x1cfe20,_0x3037c7,_0x2bcd1d,_0x4a44f1){const _0x155ee6=_0x36e6f4,_0x3e8427=this;_0x3e8427[_0x155ee6('0x98')]=_0x2bcd1d['getCurrentUser'](),_0x3e8427[_0x155ee6('0x73c')]=_0x5b0e46,_0x3e8427[_0x155ee6('0x243c')]=_0x4a44f1,_0x3e8427['realtime']=_0x1cfe20,_0x3e8427[_0x155ee6('0xbd7')]=[],_0x3e8427[_0x155ee6('0x10ab')]=[],_0x3e8427[_0x155ee6('0x18e1')]=[],_0x3e8427['startingAllowedItems']=[],_0x3e8427[_0x155ee6('0x2781')]=[],_0x3e8427[_0x155ee6('0x14d7')]=![],_0x3e8427['onInit']=_0xb87a45,_0x3e8427[_0x155ee6('0x1d92')]=_0x43362c,_0x3e8427['closeDialog']=_0x197d1f,_0x3e8427[_0x155ee6('0xc68')]={'readOnly':!_0x3e8427[_0x155ee6('0x243c')][_0x155ee6('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x155ee6('0x4f0'),'line1':_0x155ee6('0x6e1'),'line2':['name',_0x155ee6('0x1eef')],'line3':'','labelAll':_0x3037c7[_0x155ee6('0x25cc')](_0x155ee6('0x283a')),'labelSelected':_0x3037c7[_0x155ee6('0x25cc')](_0x155ee6('0xa72')),'transferCallback':function(){const _0x2d90d4=_0x155ee6,_0xcc1766=_0x2cfb05()['xorBy'](_0x3e8427[_0x2d90d4('0x2781')],_0x3e8427[_0x2d90d4('0x18e1')],'id');_0x3e8427[_0x2d90d4('0x14d7')]=_0x2cfb05()[_0x2d90d4('0x1081')](_0xcc1766)?![]:!![];}};function _0xb87a45(){const _0x7b3331=_0x155ee6;return _0x2bcd1d[_0x7b3331('0x1ac6')](_0x7b3331('0xa7c'))?_0x123be0()[_0x7b3331('0x1a80')](function(_0x451586){const _0x4272fe=_0x7b3331;_0x123f8[_0x4272fe('0xfc9')]({'title':_0x451586[_0x4272fe('0x52d')]?'API:'+_0x451586[_0x4272fe('0x52d')]+'\x20-\x20'+_0x451586['statusText']:'SYSTEM:GET_AGENTS','msg':_0x451586['status']?JSON[_0x4272fe('0xbac')](_0x451586['data']):_0x451586[_0x4272fe('0x1586')]()});}):_0x1a874f()[_0x7b3331('0x1166')](function(_0x3eba4d){const _0x39ce1d=_0x7b3331;return _0x3e8427[_0x39ce1d('0xe60')]=_0x3eba4d,_0x123be0();})[_0x7b3331('0x1a80')](function(_0x749e6e){const _0x71c0ec=_0x7b3331;_0x123f8[_0x71c0ec('0xfc9')]({'title':_0x749e6e[_0x71c0ec('0x52d')]?_0x71c0ec('0x1e21')+_0x749e6e[_0x71c0ec('0x52d')]+_0x71c0ec('0x11e1')+_0x749e6e[_0x71c0ec('0xe1b')]:_0x71c0ec('0xd4c'),'msg':_0x749e6e['status']?JSON['stringify'](_0x749e6e[_0x71c0ec('0x25f4')]):_0x749e6e[_0x71c0ec('0x1586')]()});});}function _0x1a874f(){return _0x36d259(function(_0x1ec2c8,_0x2bd78f){const _0x4af877=a0_0x3f2c;_0x17982b[_0x4af877('0x17aa')][_0x4af877('0xd83')]({'userProfileId':_0x3e8427[_0x4af877('0x98')][_0x4af877('0xb86')],'name':_0x4af877('0x2391')})['$promise'][_0x4af877('0x1166')](function(_0x58d181){const _0xd64104=_0x4af877,_0x3d3c1f=_0x58d181&&_0x58d181['rows']?_0x58d181[_0xd64104('0x269a')][0x0]:null;_0x1ec2c8(_0x3d3c1f);})[_0x4af877('0x1a80')](function(_0x115a7d){_0x2bd78f(_0x115a7d);});});}function _0x123be0(){return _0x36d259(function(_0x1fd792,_0x41b78f){const _0xd18bdd=a0_0x3f2c;return _0x11d872()[_0xd18bdd('0x1166')](function(_0x4cb908){const _0x43dffc=_0xd18bdd;return _0x3e8427[_0x43dffc('0xbd7')]=_0x4cb908[_0x43dffc('0x269a')]?_0x4cb908[_0x43dffc('0x269a')]:[],_0x2bcd1d[_0x43dffc('0x1ac6')]('admin')?_0x4cb908:_0x3e8427[_0x43dffc('0xe60')]?_0x3e8427['section'][_0x43dffc('0x1a2b')]?_0x4cb908:_0x21b700():null;})['then'](function(_0x57577d){const _0x3503ad=_0xd18bdd,_0x5826ad=_0x57577d&&_0x57577d[_0x3503ad('0x269a')]?_0x57577d[_0x3503ad('0x269a')]:[];return _0x3e8427[_0x3503ad('0x10ab')]=_0x2cfb05()[_0x3503ad('0x2563')](_0x5826ad,function(_0x191e27){const _0x57a883=_0x3503ad;return _0x2cfb05()['find'](_0x3e8427[_0x57a883('0xbd7')],{'id':_0x2bcd1d['hasRole'](_0x57a883('0xa7c'))||_0x3e8427[_0x57a883('0xe60')][_0x57a883('0x1a2b')]?_0x191e27['id']:_0x191e27[_0x57a883('0x24e8')]});}),_0x3e8427['startingAllowedItems']=angular[_0x3503ad('0x225f')](_0x3e8427['allowedItems']),_0x3e8427[_0x3503ad('0xbd7')][_0x3503ad('0x2782')](function(_0x365bf0){const _0x33a31c=_0x3503ad,_0x4d3f6a=_0x2cfb05()['find'](_0x3e8427[_0x33a31c('0x10ab')],{'id':_0x365bf0['id']});_0x2bcd1d['hasRole'](_0x33a31c('0xa7c'))?_0x365bf0[_0x33a31c('0x26ef')]=!![]:_0x365bf0[_0x33a31c('0x26ef')]=typeof _0x4d3f6a!=='undefined'?!![]:![];}),_0x4d9cd1();})['then'](function(_0x522347){const _0x200229=_0xd18bdd,_0xd57a8a=_0x522347&&_0x522347[_0x200229('0x269a')]?_0x522347[_0x200229('0x269a')]:[];_0x3e8427[_0x200229('0x18e1')]=_0x2cfb05()[_0x200229('0x2563')](_0xd57a8a,function(_0x246dec){const _0x2e3ff0=_0x200229,_0x3a8c20=_0x2cfb05()['find'](_0x3e8427[_0x2e3ff0('0xbd7')],{'id':_0x246dec['id']});return _0x3a8c20[_0x2e3ff0('0x23af')]=_0x246dec[_0x2e3ff0('0x19de')]?_0x2e3ff0('0x11e8')+_0x246dec[_0x2e3ff0('0x19de')][_0x2e3ff0('0x23af')]:'',_0x3a8c20['internal']=typeof _0x246dec[_0x2e3ff0('0x1eef')]!==_0x2e3ff0('0x1048')?'<'+_0x246dec['internal']+'>':'',_0x3a8c20;}),_0x3e8427[_0x200229('0x2781')]=angular['copy'](_0x3e8427['selectedItems']),_0x3e8427[_0x200229('0xc68')][_0x200229('0x18e1')]=_0x3e8427[_0x200229('0x18e1')],_0x3e8427[_0x200229('0xc68')][_0x200229('0xbd7')]=_0x2cfb05()[_0x200229('0x24ac')](_0x3e8427['allowedItems'],_0x3e8427[_0x200229('0xc68')][_0x200229('0x18e1')],'id'),_0x1fd792();})[_0xd18bdd('0x1a80')](function(_0x5ac3d4){_0x41b78f(_0x5ac3d4);});});}function _0x21b700(){return _0x36d259(function(_0x19947d,_0x1dceef){const _0xdbe5e2=a0_0x3f2c;return _0x17982b['userProfileResource'][_0xdbe5e2('0xd83')]({'sectionId':_0x3e8427[_0xdbe5e2('0xe60')]['id'],'nolimit':!![]})[_0xdbe5e2('0xa44')]['then'](function(_0x1743f0){_0x19947d(_0x1743f0);})[_0xdbe5e2('0x1a80')](function(_0x100c5c){_0x1dceef(_0x100c5c);});});}function _0x4d9cd1(){return _0x36d259(function(_0x3c0cdb,_0x3fd14e){const _0x2a3838=a0_0x3f2c;return _0x17982b['smsQueue']['getAgents']({'id':_0x3e8427[_0x2a3838('0x73c')]['id'],'fields':_0x2a3838('0x1459'),'nolimit':!![],'role':'agent'})[_0x2a3838('0xa44')][_0x2a3838('0x1166')](function(_0x5a6195){_0x3c0cdb(_0x5a6195);})[_0x2a3838('0x1a80')](function(_0x54ebcb){_0x3fd14e(_0x54ebcb);});});}function _0x11d872(){return _0x36d259(function(_0x635804,_0x4f3849){const _0x43c1aa=a0_0x3f2c;return _0x17982b[_0x43c1aa('0x557')][_0x43c1aa('0xd83')]({'fields':_0x43c1aa('0x1459'),'nolimit':!![],'role':_0x43c1aa('0x1eff')})[_0x43c1aa('0xa44')]['then'](function(_0x3c6229){_0x635804(_0x3c6229);})[_0x43c1aa('0x1a80')](function(_0x257492){_0x4f3849(_0x257492);});});}function _0x4f0f6f(_0x5510a9){return _0x36d259(function(_0x1eb194,_0x329d25){const _0xbd31d6=a0_0x3f2c;_0x2cfb05()[_0xbd31d6('0x1081')](_0x5510a9)?_0x1eb194():_0x17982b[_0xbd31d6('0x73c')]['addAgents']({'id':_0x3e8427[_0xbd31d6('0x73c')]['id'],'ids':_0x2cfb05()['map'](_0x5510a9,'id')})[_0xbd31d6('0xa44')][_0xbd31d6('0x1166')](function(){_0x1eb194();})['catch'](function(_0x2613a){_0x329d25(_0x2613a);});});}function _0x4ed517(_0x1b4831){return _0x36d259(function(_0x444ac4,_0x153a7a){const _0x32d18b=a0_0x3f2c;_0x2cfb05()['isEmpty'](_0x1b4831)?_0x444ac4():_0x17982b[_0x32d18b('0x73c')]['removeAgents']({'id':_0x3e8427[_0x32d18b('0x73c')]['id'],'ids':_0x2cfb05()[_0x32d18b('0x2563')](_0x1b4831,'id')})[_0x32d18b('0xa44')][_0x32d18b('0x1166')](function(){_0x444ac4();})[_0x32d18b('0x1a80')](function(_0x5acb93){_0x153a7a(_0x5acb93);});});}function _0x43362c(){const _0xc14e51=_0x155ee6,_0x468629=_0x2cfb05()[_0xc14e51('0x24ac')](_0x3e8427[_0xc14e51('0x2781')],_0x3e8427['selectedItems'],'id'),_0x1d64d5=_0x2cfb05()['differenceBy'](_0x3e8427[_0xc14e51('0x18e1')],_0x3e8427[_0xc14e51('0x2781')],'id');return _0x4ed517(_0x468629)[_0xc14e51('0x1166')](function(){return _0x4f0f6f(_0x1d64d5);})['then'](function(){const _0x4b97c0=_0xc14e51;_0x3e8427[_0x4b97c0('0x14d7')]=![],_0x3e8427[_0x4b97c0('0x2111')]=angular[_0x4b97c0('0x225f')](_0x3e8427['allowedItems']),_0x3e8427[_0x4b97c0('0x2781')]=angular[_0x4b97c0('0x225f')](_0x3e8427[_0x4b97c0('0x18e1')]),_0x123f8[_0x4b97c0('0x103b')]({'title':'SUCCESS','msg':'Agents\x20association\x20has\x20been\x20updated!'});})[_0xc14e51('0x1a80')](function(_0x341928){const _0x33344e=_0xc14e51;_0x123f8[_0x33344e('0xfc9')]({'title':_0x341928[_0x33344e('0x52d')]?_0x33344e('0x1e21')+_0x341928['status']+_0x33344e('0x11e1')+_0x341928[_0x33344e('0xe1b')]:_0x33344e('0x1b29'),'msg':_0x341928[_0x33344e('0x52d')]?JSON[_0x33344e('0xbac')](_0x341928[_0x33344e('0x25f4')]):_0x341928[_0x33344e('0x1586')]()});});}function _0x197d1f(){_0x59b12b['hide']();}}const _0x40c77c=_0x3e724c;_0x1a4b3d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0x73c'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x1a4b3d(_0x5b1e91,_0x14b750,_0x1fc382,_0x5dbedb,_0x2a541a,_0x238b04,_0x19f146,_0x520e0a){const _0x4b3b6e=_0x36e6f4,_0x58ea5f=this;_0x58ea5f[_0x4b3b6e('0x98')]=_0x19f146['getCurrentUser'](),_0x58ea5f[_0x4b3b6e('0x73c')]=_0x2a541a,_0x58ea5f['crudPermissions']=_0x520e0a,_0x58ea5f[_0x4b3b6e('0xbd7')]=[],_0x58ea5f[_0x4b3b6e('0x10ab')]=[],_0x58ea5f['selectedItems']=[],_0x58ea5f[_0x4b3b6e('0x2111')]=[],_0x58ea5f[_0x4b3b6e('0x2781')]=[],_0x58ea5f['pendingChanges']=![],_0x58ea5f[_0x4b3b6e('0xc68')]={'readOnly':!_0x58ea5f[_0x4b3b6e('0x243c')]['canEdit'],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x4b3b6e('0x4f0'),'line2':'','line3':'','labelAll':_0x238b04['instant'](_0x4b3b6e('0x67e')),'labelSelected':_0x238b04[_0x4b3b6e('0x25cc')]('SMS.SELECTED_TEAMS'),'transferCallback':function(){const _0x37170f=_0x4b3b6e,_0x496719=_0x2cfb05()[_0x37170f('0x2802')](_0x58ea5f[_0x37170f('0x2781')],_0x58ea5f[_0x37170f('0x18e1')],'id');_0x58ea5f[_0x37170f('0x14d7')]=_0x2cfb05()['isEmpty'](_0x496719)?![]:!![];}},_0x58ea5f[_0x4b3b6e('0xae0')]=_0xfe5cae,_0x58ea5f[_0x4b3b6e('0x1add')]=_0x46347e,_0x58ea5f['closeDialog']=_0x58e6e1;function _0xfe5cae(){const _0x5ae75b=_0x4b3b6e;return _0x19f146[_0x5ae75b('0x1ac6')](_0x5ae75b('0xa7c'))?_0x4fb9ac()[_0x5ae75b('0x1a80')](function(_0x5cc981){const _0x4ba5c3=_0x5ae75b;_0x1fc382[_0x4ba5c3('0xfc9')]({'title':_0x5cc981[_0x4ba5c3('0x52d')]?_0x4ba5c3('0x1e21')+_0x5cc981[_0x4ba5c3('0x52d')]+'\x20-\x20'+_0x5cc981[_0x4ba5c3('0xe1b')]:'SYSTEM:GET_TEAMS','msg':_0x5cc981['status']?JSON[_0x4ba5c3('0xbac')](_0x5cc981['data']):_0x5cc981[_0x4ba5c3('0x1586')]()});}):_0x3fe3e9()[_0x5ae75b('0x1166')](function(_0x37ee75){const _0x21d997=_0x5ae75b;return _0x58ea5f[_0x21d997('0xe60')]=_0x37ee75,_0x4fb9ac();})['catch'](function(_0x15988b){const _0x28b78b=_0x5ae75b;_0x1fc382[_0x28b78b('0xfc9')]({'title':_0x15988b['status']?_0x28b78b('0x1e21')+_0x15988b[_0x28b78b('0x52d')]+_0x28b78b('0x11e1')+_0x15988b[_0x28b78b('0xe1b')]:_0x28b78b('0x1031'),'msg':_0x15988b[_0x28b78b('0x52d')]?JSON[_0x28b78b('0xbac')](_0x15988b['data']):_0x15988b['toString']()});});}function _0x3fe3e9(){return _0x14b750(function(_0x1e81cd,_0x2ef1a3){const _0x2c702d=a0_0x3f2c;_0x5dbedb['userProfileSection']['get']({'userProfileId':_0x58ea5f[_0x2c702d('0x98')][_0x2c702d('0xb86')],'name':'Teams'})[_0x2c702d('0xa44')][_0x2c702d('0x1166')](function(_0x5ed8b7){const _0x461813=_0x2c702d,_0x55a4bd=_0x5ed8b7&&_0x5ed8b7[_0x461813('0x269a')]?_0x5ed8b7['rows'][0x0]:null;_0x1e81cd(_0x55a4bd);})['catch'](function(_0x5ea264){_0x2ef1a3(_0x5ea264);});});}function _0x4fb9ac(){return _0x14b750(function(_0x5605a2,_0x167a50){const _0x368843=a0_0x3f2c;return _0x34e084()['then'](function(_0x36f688){const _0x5abb42=a0_0x3f2c;return _0x58ea5f[_0x5abb42('0xbd7')]=_0x36f688[_0x5abb42('0x269a')]?_0x36f688[_0x5abb42('0x269a')]:[],_0x19f146[_0x5abb42('0x1ac6')](_0x5abb42('0xa7c'))?_0x36f688:_0x58ea5f['section']?_0x58ea5f[_0x5abb42('0xe60')][_0x5abb42('0x1a2b')]?_0x36f688:_0x4c1b23():null;})[_0x368843('0x1166')](function(_0x35add1){const _0x38a990=_0x368843,_0x35b2ea=_0x35add1&&_0x35add1[_0x38a990('0x269a')]?_0x35add1[_0x38a990('0x269a')]:[];return _0x58ea5f[_0x38a990('0x10ab')]=_0x2cfb05()[_0x38a990('0x2563')](_0x35b2ea,function(_0x598eb2){const _0x598ba0=_0x38a990;return _0x2cfb05()[_0x598ba0('0xc38')](_0x58ea5f[_0x598ba0('0xbd7')],{'id':_0x19f146[_0x598ba0('0x1ac6')](_0x598ba0('0xa7c'))||_0x58ea5f[_0x598ba0('0xe60')][_0x598ba0('0x1a2b')]?_0x598eb2['id']:_0x598eb2[_0x598ba0('0x24e8')]});}),_0x58ea5f[_0x38a990('0xbd7')]['forEach'](function(_0xb3117a){const _0x5e18ee=_0x38a990,_0x211c54=_0x2cfb05()[_0x5e18ee('0xc38')](_0x58ea5f[_0x5e18ee('0x10ab')],{'id':_0xb3117a['id']});_0x19f146['hasRole'](_0x5e18ee('0xa7c'))?_0xb3117a['isValid']=!![]:_0xb3117a[_0x5e18ee('0x26ef')]=typeof _0x211c54!==_0x5e18ee('0x1048')?!![]:![];}),_0x351f28();})[_0x368843('0x1166')](function(_0x52299d){const _0x54448e=_0x368843,_0x92f688=_0x52299d&&_0x52299d[_0x54448e('0x269a')]?_0x52299d[_0x54448e('0x269a')]:[];_0x58ea5f[_0x54448e('0x18e1')]=_0x2cfb05()['map'](_0x92f688,function(_0x3a69eb){const _0x434825=_0x54448e;return _0x2cfb05()[_0x434825('0xc38')](_0x58ea5f[_0x434825('0xbd7')],{'id':_0x3a69eb['id']});}),_0x58ea5f[_0x54448e('0x2781')]=angular['copy'](_0x58ea5f[_0x54448e('0x18e1')]),_0x58ea5f['dualMultiselectOptions'][_0x54448e('0x18e1')]=_0x58ea5f[_0x54448e('0x18e1')],_0x58ea5f['dualMultiselectOptions'][_0x54448e('0xbd7')]=_0x2cfb05()['differenceBy'](_0x58ea5f['allowedItems'],_0x58ea5f[_0x54448e('0xc68')][_0x54448e('0x18e1')],'id'),_0x5605a2();})[_0x368843('0x1a80')](function(_0x209e94){_0x167a50(_0x209e94);});});}function _0x4c1b23(){return _0x14b750(function(_0x4a96d6,_0x2fb1df){const _0x5aa284=a0_0x3f2c;return _0x5dbedb[_0x5aa284('0x4b5')][_0x5aa284('0xd83')]({'sectionId':_0x58ea5f['section']['id'],'nolimit':!![]})[_0x5aa284('0xa44')][_0x5aa284('0x1166')](function(_0x3a07b8){_0x4a96d6(_0x3a07b8);})[_0x5aa284('0x1a80')](function(_0x12daed){_0x2fb1df(_0x12daed);});});}function _0x351f28(){return _0x14b750(function(_0x3cf7ba,_0x1c8449){const _0x38cdb1=a0_0x3f2c;return _0x5dbedb['smsQueue'][_0x38cdb1('0x1448')]({'id':_0x58ea5f[_0x38cdb1('0x73c')]['id'],'fields':_0x38cdb1('0x1776'),'nolimit':!![]})[_0x38cdb1('0xa44')][_0x38cdb1('0x1166')](function(_0x188997){_0x3cf7ba(_0x188997);})[_0x38cdb1('0x1a80')](function(_0x5167b4){_0x1c8449(_0x5167b4);});});}function _0x34e084(){return _0x14b750(function(_0x5f074d,_0x476857){const _0x14512b=a0_0x3f2c;return _0x5dbedb['team']['get']({'fields':_0x14512b('0x1776'),'nolimit':!![]})[_0x14512b('0xa44')][_0x14512b('0x1166')](function(_0x2a588d){_0x5f074d(_0x2a588d);})['catch'](function(_0x136818){_0x476857(_0x136818);});});}function _0x11fefb(_0x3f95d1){return _0x14b750(function(_0x1d6e15,_0x6d0fd5){const _0x1e34e9=a0_0x3f2c;_0x2cfb05()[_0x1e34e9('0x1081')](_0x3f95d1)?_0x1d6e15():_0x5dbedb['smsQueue']['addTeams']({'id':_0x58ea5f['smsQueue']['id'],'ids':_0x2cfb05()[_0x1e34e9('0x2563')](_0x3f95d1,'id')})['$promise'][_0x1e34e9('0x1166')](function(){_0x1d6e15();})[_0x1e34e9('0x1a80')](function(_0x5a9f1e){_0x6d0fd5(_0x5a9f1e);});});}function _0xee90e3(_0x116472){return _0x14b750(function(_0x16af65,_0xe6e697){const _0x15767f=a0_0x3f2c;_0x2cfb05()[_0x15767f('0x1081')](_0x116472)?_0x16af65():_0x5dbedb['smsQueue'][_0x15767f('0x8f')]({'id':_0x58ea5f[_0x15767f('0x73c')]['id'],'ids':_0x2cfb05()[_0x15767f('0x2563')](_0x116472,'id')})[_0x15767f('0xa44')][_0x15767f('0x1166')](function(){_0x16af65();})['catch'](function(_0x492c6b){_0xe6e697(_0x492c6b);});});}function _0x46347e(){const _0x37c6cc=_0x4b3b6e,_0x509aa6=_0x2cfb05()[_0x37c6cc('0x24ac')](_0x58ea5f['startingSelectedItems'],_0x58ea5f['selectedItems'],'id'),_0x524745=_0x2cfb05()[_0x37c6cc('0x24ac')](_0x58ea5f[_0x37c6cc('0x18e1')],_0x58ea5f[_0x37c6cc('0x2781')],'id');return _0xee90e3(_0x509aa6)[_0x37c6cc('0x1166')](function(){return _0x11fefb(_0x524745);})[_0x37c6cc('0x1166')](function(){const _0x14bdcc=_0x37c6cc;_0x58ea5f[_0x14bdcc('0x14d7')]=![],_0x58ea5f[_0x14bdcc('0x2111')]=angular[_0x14bdcc('0x225f')](_0x58ea5f[_0x14bdcc('0x10ab')]),_0x58ea5f[_0x14bdcc('0x2781')]=angular[_0x14bdcc('0x225f')](_0x58ea5f['selectedItems']),_0x1fc382[_0x14bdcc('0x103b')]({'title':_0x14bdcc('0x983'),'msg':_0x14bdcc('0x1f6b')});})[_0x37c6cc('0x1a80')](function(_0x3e06e9){const _0x1636a5=_0x37c6cc;_0x1fc382['error']({'title':_0x3e06e9[_0x1636a5('0x52d')]?_0x1636a5('0x1e21')+_0x3e06e9[_0x1636a5('0x52d')]+_0x1636a5('0x11e1')+_0x3e06e9[_0x1636a5('0xe1b')]:_0x1636a5('0x1b29'),'msg':_0x3e06e9[_0x1636a5('0x52d')]?JSON[_0x1636a5('0xbac')](_0x3e06e9[_0x1636a5('0x25f4')]):_0x3e06e9[_0x1636a5('0x1586')]()});});}function _0x58e6e1(){_0x5b1e91['hide']();}}const _0xc23ea1=_0x1a4b3d,_0x25dbb8=_0x2734b2['p']+_0x36e6f4('0x1890');_0x582f69['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x73c'),_0x36e6f4('0x17aa')];function _0x582f69(_0x58d458,_0x31b7ad,_0x15706c,_0x591ecd,_0x885183,_0xf318ce,_0xa33113,_0x50b13f,_0x5d6087,_0x580c17,_0x31aa28,_0x4444ac){const _0x4f8875=_0x36e6f4,_0x8b723=this;_0x8b723['currentUser']=_0x580c17[_0x4f8875('0x26cd')](),_0x8b723['license']=_0xf318ce,_0x8b723[_0x4f8875('0xf8a')]=_0xa33113,_0x8b723[_0x4f8875('0x2900')]=_0x8b723[_0x4f8875('0xf8a')][_0x4f8875('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x8b723[_0x4f8875('0x246b')]=_0x31b7ad[_0x4f8875('0x6f1')]()+_0x4f8875('0xc51')+_0x31b7ad[_0x4f8875('0x1690')](),_0x8b723[_0x4f8875('0x73c')]=_0x31aa28||_0x58d458[_0x4f8875('0x23f')][_0x4f8875('0x73c')]||{},_0x8b723[_0x4f8875('0x17aa')]=_0x4444ac&&_0x4444ac[_0x4f8875('0x240f')]==0x1?_0x4444ac[_0x4f8875('0x269a')][0x0]:null,_0x8b723[_0x4f8875('0x243c')]=_0x580c17[_0x4f8875('0xd87')](_0x8b723[_0x4f8875('0x17aa')]?_0x8b723['userProfileSection'][_0x4f8875('0x243c')]:null),_0x8b723[_0x4f8875('0x128b')]={},_0x8b723[_0x4f8875('0x2669')]=_0x58d458[_0x4f8875('0x23f')][_0x4f8875('0xbe3')]||0x0,_0x8b723[_0x4f8875('0x292')]=_0x2770c5,_0x8b723[_0x4f8875('0x1728')]=_0x2bd8d5,_0x8b723[_0x4f8875('0x31d')]=_0x5d6087[_0x4f8875('0x1fa1')],_0x8b723[_0x4f8875('0x1ba7')]=_0x58bdd1,_0x8b723[_0x4f8875('0x1d1b')]=_0x429ea9;function _0x2770c5(_0x3467d4,_0x104aed){const _0x5c5ed8=_0x4f8875;_0x15706c[_0x5c5ed8('0x1f80')]({'controller':_0x5c5ed8('0x162b'),'controllerAs':'vm','templateUrl':_0x25dbb8,'parent':angular[_0x5c5ed8('0x1194')](_0x591ecd['body']),'targetEvent':_0x104aed,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x3467d4,'smsQueues':_0x8b723[_0x5c5ed8('0x20c0')]?_0x8b723[_0x5c5ed8('0x20c0')][_0x5c5ed8('0x269a')]:[],'crudPermissions':_0x8b723[_0x5c5ed8('0x243c')]}});}function _0x2bd8d5(_0x338ef2,_0x31f3c9){const _0x17753a=_0x4f8875;_0x15706c[_0x17753a('0x1f80')]({'controller':_0x17753a('0xe68'),'controllerAs':'vm','templateUrl':_0x199d18,'parent':angular[_0x17753a('0x1194')](_0x591ecd[_0x17753a('0x8d2')]),'targetEvent':_0x31f3c9,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x338ef2,'smsQueues':_0x8b723[_0x17753a('0x20c0')]?_0x8b723['smsQueues']['rows']:[],'crudPermissions':_0x8b723[_0x17753a('0x243c')],'realtime':![]}});}function _0x58bdd1(){const _0x400dc8=_0x4f8875;_0x58d458['go'](_0x400dc8('0x191f'),{},{'reload':_0x400dc8('0x191f')});}function _0x429ea9(){const _0x4cf27e=_0x4f8875;_0x50b13f['smsQueue'][_0x4cf27e('0x1449')]({'id':_0x8b723[_0x4cf27e('0x73c')]['id']},_0x8b723[_0x4cf27e('0x73c')])[_0x4cf27e('0xa44')][_0x4cf27e('0x1166')](function(){const _0x4e1716=_0x4cf27e;_0x5d6087[_0x4e1716('0x103b')]({'title':_0x4e1716('0x47d'),'msg':_0x8b723[_0x4e1716('0x73c')][_0x4e1716('0x4f0')]?_0x8b723[_0x4e1716('0x73c')][_0x4e1716('0x4f0')]+_0x4e1716('0xa17'):''});})[_0x4cf27e('0x1a80')](function(_0xd63a18){const _0x13739a=_0x4cf27e;_0x5d6087[_0x13739a('0xfc9')]({'title':_0xd63a18[_0x13739a('0x52d')]?'API:'+_0xd63a18[_0x13739a('0x52d')]+_0x13739a('0x11e1')+_0xd63a18[_0x13739a('0xe1b')]:'SYSTEM:GETsmsQueue','msg':_0xd63a18['data']?JSON['stringify'](_0xd63a18['data']):_0xd63a18[_0x13739a('0x1586')]()});});}}const _0x325986=_0x582f69;_0x498c9d[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x20c0'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'license','setting'];function _0x498c9d(_0x240776,_0xa9d7ff,_0x2f1ebb,_0x556502,_0x5c4eb6,_0x3fafaa,_0x33adbf,_0x34ddac,_0x185f25,_0x29bda9,_0x51bb0b,_0x438774,_0x1831dd,_0x189eed,_0x19ab95,_0x3d4b62,_0x1e1eaa){const _0x3295b5=_0x36e6f4,_0x418be2=this;_0x418be2['license']=_0x3d4b62,_0x418be2[_0x3295b5('0xf8a')]=_0x1e1eaa,_0x418be2['currentUser']=_0x19ab95[_0x3295b5('0x26cd')](),_0x418be2[_0x3295b5('0x20c0')]=_0x185f25||{'count':0x0,'rows':[]},_0x418be2[_0x3295b5('0x7f')]=_0x29bda9,_0x418be2[_0x3295b5('0x17aa')]=_0x51bb0b&&_0x51bb0b[_0x3295b5('0x240f')]==0x1?_0x51bb0b[_0x3295b5('0x269a')][0x0]:null,_0x418be2[_0x3295b5('0x243c')]=_0x19ab95[_0x3295b5('0xd87')](_0x418be2[_0x3295b5('0x17aa')]?_0x418be2[_0x3295b5('0x17aa')][_0x3295b5('0x243c')]:null),_0x418be2[_0x3295b5('0x916')]=_0x3295b5('0x20c0'),_0x418be2['listOrder']='',_0x418be2[_0x3295b5('0x104c')]=null,_0x418be2[_0x3295b5('0x285e')]=[],_0x418be2[_0x3295b5('0x2218')]={'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','sort':'-updatedAt','channel':_0x3295b5('0x146c'),'limit':0xa,'page':0x1},_0x418be2[_0x3295b5('0x1440')]=_0x2cfb05()['keyBy']([{'option':_0x3295b5('0xb16'),'value':'\x27beepall\x27'},{'option':_0x3295b5('0x75'),'value':_0x3295b5('0x11ad')}],function(_0x54a0d6){const _0x21f522=_0x3295b5;return _0x2cfb05()[_0x21f522('0xf3')](_0x54a0d6[_0x21f522('0x18e0')],new RegExp('\x27','g'),'');}),_0x418be2[_0x3295b5('0x1ff6')]=_0x3e927d,_0x418be2[_0x3295b5('0x292')]=_0xa41a10,_0x418be2[_0x3295b5('0x1728')]=_0x48597d,_0x418be2['deleteconfirm']=_0x2d08b9,_0x418be2['gotorealtimegoto']=_0x33d53b,_0x418be2[_0x3295b5('0x103b')]=_0x1e98a5,_0x418be2[_0x3295b5('0x1c6f')]=_0x109514,_0x418be2['createOrEditSmsQueue']=_0x561629,_0x418be2[_0x3295b5('0x25f')]=_0x593bc7,_0x418be2['exportSelectedSmsQueues']=_0x32cac5,_0x418be2['deleteSelectedSmsQueues']=_0x204c36,_0x418be2[_0x3295b5('0x1e6')]=_0x37ef34,_0x418be2[_0x3295b5('0x176d')]=_0x477f44;function _0x3e927d(_0x1a89af){const _0xccb4c1=_0x3295b5;_0x2f1ebb['go'](_0xccb4c1('0xa9d'),{'id':_0x1a89af['id'],'smsQueue':_0x1a89af,'crudPermissions':_0x418be2[_0xccb4c1('0x243c')]});}function _0xa41a10(_0x6cf4f1,_0x3034a0){const _0x5daa8d=_0x3295b5;_0x5c4eb6['show']({'controller':'SmsQueueteamaddController','controllerAs':'vm','templateUrl':_0x25dbb8,'parent':angular[_0x5daa8d('0x1194')](_0x3fafaa[_0x5daa8d('0x8d2')]),'targetEvent':_0x3034a0,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x6cf4f1,'smsQueues':_0x418be2[_0x5daa8d('0x20c0')]?_0x418be2[_0x5daa8d('0x20c0')][_0x5daa8d('0x269a')]:[],'crudPermissions':_0x418be2[_0x5daa8d('0x243c')]}});}function _0x48597d(_0x1b5c51,_0x16c2a0){const _0xf993ca=_0x3295b5;_0x5c4eb6[_0xf993ca('0x1f80')]({'controller':_0xf993ca('0xe68'),'controllerAs':'vm','templateUrl':_0x199d18,'parent':angular[_0xf993ca('0x1194')](_0x3fafaa[_0xf993ca('0x8d2')]),'targetEvent':_0x16c2a0,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x1b5c51,'smsQueues':_0x418be2['smsQueues']?_0x418be2['smsQueues'][_0xf993ca('0x269a')]:[],'crudPermissions':_0x418be2[_0xf993ca('0x243c')],'realtime':![]}});}function _0x2d08b9(_0xd08e92,_0x4e9930){const _0x130227=_0x3295b5,_0x2ba5d5=_0x5c4eb6[_0x130227('0x1d26')]()[_0x130227('0xcdc')](_0x130227('0x288d')+_0x2cfb05()[_0x130227('0xb35')](_0x130227('0x73c'))+'?')[_0x130227('0xf3c')](_0x130227('0x12b5')+(_0xd08e92[_0x130227('0x4f0')]||_0x130227('0x73c'))+_0x130227('0xace')+_0x130227('0x3f3'))['ariaLabel'](_0x130227('0x81f'))[_0x130227('0x203b')](_0x4e9930)['ok']('OK')[_0x130227('0x3f')](_0x130227('0x2d3'));_0x5c4eb6['show'](_0x2ba5d5)[_0x130227('0x1166')](function(){_0x593bc7(_0xd08e92);},function(){const _0x433482=_0x130227;console[_0x433482('0x455')](_0x433482('0x2d3'));});}function _0x33d53b(){const _0x3405f8=_0x3295b5;if(_0x19ab95[_0x3405f8('0x1ac6')](_0x3405f8('0xa7c')))_0x2f1ebb['go'](_0x3405f8('0x2494'),{});else return _0x438774[_0x3405f8('0x17aa')][_0x3405f8('0xd83')]({'userProfileId':_0x19ab95[_0x3405f8('0x26cd')]()['userProfileId'],'sectionId':0x2c6})[_0x3405f8('0xa44')][_0x3405f8('0x1166')](function(_0x33e1ff){const _0x47cc12=_0x3405f8,_0x5e0402=_0x33e1ff&&_0x33e1ff[_0x47cc12('0x269a')]?_0x33e1ff[_0x47cc12('0x269a')][0x0]:null;_0x5e0402&&_0x5e0402[_0x47cc12('0xc27')]?_0x2f1ebb['go']('app.sms.realtime.queues',{}):_0x189eed[_0x47cc12('0x1fa1')]({'title':_0x34ddac[_0x47cc12('0x25cc')](_0x47cc12('0x627')),'msg':_0x34ddac[_0x47cc12('0x25cc')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_MESSAGE')});})[_0x3405f8('0x1a80')](function(_0x239615){const _0x4fef3b=_0x3405f8;_0x189eed[_0x4fef3b('0xfc9')]({'title':_0x239615[_0x4fef3b('0x52d')]?_0x4fef3b('0x1e21')+_0x239615[_0x4fef3b('0x52d')]+_0x4fef3b('0x11e1')+_0x239615[_0x4fef3b('0xe1b')]:_0x4fef3b('0x153e'),'msg':_0x239615['status']?JSON[_0x4fef3b('0xbac')](_0x239615[_0x4fef3b('0x25f4')]):_0x239615[_0x4fef3b('0x1586')]()});});}let _0x54ebec=!![],_0x2ae556=0x1;_0x240776[_0x3295b5('0xe83')](_0x3295b5('0x12d8'),function(_0x44689a,_0x174eec){const _0xf930a5=_0x3295b5;_0x54ebec?_0x33adbf(function(){_0x54ebec=![];}):(!_0x174eec&&(_0x2ae556=_0x418be2['query'][_0xf930a5('0x1a43')]),_0x44689a!==_0x174eec&&(_0x418be2['query'][_0xf930a5('0x1a43')]=0x1),!_0x44689a&&(_0x418be2[_0xf930a5('0x2218')][_0xf930a5('0x1a43')]=_0x2ae556),_0x418be2['getSmsQueues']());});function _0x1e98a5(_0x219ac4){const _0x5b6a2e=_0x3295b5;_0x418be2[_0x5b6a2e('0x20c0')]=_0x219ac4||{'count':0x0,'rows':[]};}function _0x109514(){const _0x57c4c3=_0x3295b5;_0x418be2[_0x57c4c3('0x2218')]['offset']=(_0x418be2['query'][_0x57c4c3('0x1a43')]-0x1)*_0x418be2[_0x57c4c3('0x2218')][_0x57c4c3('0x163f')],_0x19ab95[_0x57c4c3('0x1ac6')](_0x57c4c3('0xa7c'))?_0x418be2[_0x57c4c3('0x1f48')]=_0x438774[_0x57c4c3('0x73c')][_0x57c4c3('0xd83')](_0x418be2['query'],_0x1e98a5)[_0x57c4c3('0xa44')]:(_0x418be2[_0x57c4c3('0x2218')]['id']=_0x418be2['userProfile']['id'],_0x418be2['query'][_0x57c4c3('0xe60')]='SmsQueues',_0x418be2[_0x57c4c3('0x1f48')]=_0x438774[_0x57c4c3('0x7f')][_0x57c4c3('0x263a')](_0x418be2[_0x57c4c3('0x2218')],_0x1e98a5)[_0x57c4c3('0xa44')]);}function _0x561629(_0xf2be5e,_0x5ccc06){const _0x5bb79f=_0x3295b5;_0x5c4eb6[_0x5bb79f('0x1f80')]({'controller':'CreateOrEditSmsQueueDialogController','controllerAs':'vm','templateUrl':_0x4ee57a,'parent':angular[_0x5bb79f('0x1194')](_0x3fafaa[_0x5bb79f('0x8d2')]),'targetEvent':_0xf2be5e,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x5ccc06,'smsQueues':_0x418be2[_0x5bb79f('0x20c0')][_0x5bb79f('0x269a')],'license':_0x418be2[_0x5bb79f('0x5c9')],'setting':_0x418be2[_0x5bb79f('0xf8a')],'crudPermissions':_0x418be2[_0x5bb79f('0x243c')]}});}function _0x593bc7(_0x4de5d1){const _0x42b7e2=_0x3295b5;_0x438774[_0x42b7e2('0x73c')]['delete']({'id':_0x4de5d1['id']})['$promise'][_0x42b7e2('0x1166')](function(){const _0x20a89e=_0x42b7e2;_0x2cfb05()[_0x20a89e('0x127f')](_0x418be2[_0x20a89e('0x20c0')]['rows'],{'id':_0x4de5d1['id']}),_0x418be2[_0x20a89e('0x20c0')][_0x20a89e('0x240f')]-=0x1,!_0x418be2[_0x20a89e('0x20c0')]['rows'][_0x20a89e('0x264b')]&&_0x418be2['getSmsQueues'](),_0x189eed[_0x20a89e('0x103b')]({'title':_0x2cfb05()[_0x20a89e('0xb35')]('SmsQueue')+_0x20a89e('0x2b6'),'msg':_0x4de5d1[_0x20a89e('0x4f0')]?_0x4de5d1[_0x20a89e('0x4f0')]+_0x20a89e('0x7cd'):''});})[_0x42b7e2('0x1a80')](function(_0x4a393b){const _0x3d9cde=_0x42b7e2;if(_0x4a393b[_0x3d9cde('0x25f4')]&&_0x4a393b[_0x3d9cde('0x25f4')][_0x3d9cde('0x61a')]&&_0x4a393b[_0x3d9cde('0x25f4')]['errors'][_0x3d9cde('0x264b')]){_0x418be2[_0x3d9cde('0x61a')]=_0x4a393b['data']['errors']||[{'message':_0x4a393b[_0x3d9cde('0x1586')](),'type':_0x3d9cde('0x1423')}];for(let _0x561a4d=0x0;_0x561a4d<_0x4a393b['data'][_0x3d9cde('0x61a')]['length'];_0x561a4d++){_0x189eed[_0x3d9cde('0xfc9')]({'title':_0x4a393b['data'][_0x3d9cde('0x61a')][_0x561a4d][_0x3d9cde('0x1345')],'msg':_0x4a393b[_0x3d9cde('0x25f4')][_0x3d9cde('0x61a')][_0x561a4d][_0x3d9cde('0x1e70')]});}}else _0x189eed[_0x3d9cde('0xfc9')]({'title':_0x4a393b[_0x3d9cde('0x52d')]?_0x3d9cde('0x1e21')+_0x4a393b['status']+'\x20-\x20'+_0x4a393b[_0x3d9cde('0xe1b')]:_0x3d9cde('0x1423'),'msg':_0x4a393b['data']?JSON[_0x3d9cde('0xbac')](_0x4a393b['data'][_0x3d9cde('0x1e70')]):_0x4a393b[_0x3d9cde('0x1e70')]||_0x4a393b[_0x3d9cde('0x1586')]()});});}function _0x32cac5(){const _0x2590e8=_0x3295b5,_0xe92531=angular[_0x2590e8('0x225f')](_0x418be2[_0x2590e8('0x285e')]);return _0x418be2[_0x2590e8('0x285e')]=[],_0xe92531;}function _0x204c36(_0x5e9329){const _0x217208=_0x3295b5,_0x259a71=_0x5c4eb6['confirm']()[_0x217208('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20smsQueues?')[_0x217208('0xf3c')](_0x217208('0x12b5')+_0x418be2[_0x217208('0x285e')]['length']+_0x217208('0x196d')+_0x217208('0x3f3'))['ariaLabel'](_0x217208('0x11cf'))[_0x217208('0x203b')](_0x5e9329)['ok']('OK')[_0x217208('0x3f')](_0x217208('0x2d3'));_0x5c4eb6[_0x217208('0x1f80')](_0x259a71)[_0x217208('0x1166')](function(){const _0x4a9678=_0x217208;_0x418be2['selectedSmsQueues'][_0x4a9678('0x2782')](function(_0x46f25f){_0x593bc7(_0x46f25f);}),_0x418be2[_0x4a9678('0x285e')]=[];});}function _0x37ef34(){_0x418be2['selectedSmsQueues']=[];}function _0x477f44(){const _0x1bb0fe=_0x3295b5;_0x418be2[_0x1bb0fe('0x285e')]=_0x418be2['smsQueues']['rows'];}}const _0x20abc6=_0x498c9d;_0x2e6dfe[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),'$translatePartialLoaderProvider'];function _0x2e6dfe(_0x3ea477,_0x198b88){const _0x5cd8c8=_0x36e6f4;_0x3ea477[_0x5cd8c8('0x63f')](_0x5cd8c8('0x24f3'),{'abstract':!![],'url':_0x5cd8c8('0x37d')})[_0x5cd8c8('0x63f')](_0x5cd8c8('0x191f'),{'url':'/smsQueues','views':{'content@app':{'templateUrl':_0x39d966,'controller':_0x5cd8c8('0x3e3')}},'resolve':{'smsQueues':[_0x5cd8c8('0x1fbc'),_0x5cd8c8('0x21ef'),function(_0x5df43,_0x36f20f){const _0x794584=_0x5cd8c8;return _0x36f20f[_0x794584('0x1ac6')](_0x794584('0xa7c'))?_0x5df43[_0x794584('0x18af')](_0x794584('0xcaa'),{'fields':_0x794584('0xf26'),'sort':'-updatedAt','channel':_0x794584('0x146c'),'limit':0xa,'offset':0x0}):_0x5df43[_0x794584('0x18af')](_0x794584('0x17c4'),{'id':_0x36f20f[_0x794584('0x26cd')]()[_0x794584('0xb86')],'section':_0x794584('0x24e4'),'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','sort':'-updatedAt','channel':_0x794584('0x146c'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x5cd8c8('0x1fbc'),_0x5cd8c8('0x21ef'),function(_0x12d49d,_0x426324){const _0x5b9424=_0x5cd8c8;return _0x426324[_0x5b9424('0x1ac6')]('admin')?null:_0x12d49d['resolve'](_0x5b9424('0x697'),{'fields':_0x5b9424('0x686'),'id':_0x426324[_0x5b9424('0x26cd')]()['userProfileId']});}],'userProfileSection':['apiResolver',_0x5cd8c8('0x21ef'),function(_0x49e56d,_0x30f257){const _0x148616=_0x5cd8c8;return _0x30f257[_0x148616('0x1ac6')](_0x148616('0xa7c'))?null:_0x49e56d[_0x148616('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x30f257['getCurrentUser']()[_0x148616('0xb86')],'sectionId':0x2bd});}]},'authenticate':!![],'permissionId':0x2bd,'bodyClass':_0x5cd8c8('0x146c')})[_0x5cd8c8('0x63f')](_0x5cd8c8('0xa9d'),{'url':_0x5cd8c8('0x2233'),'params':{'smsQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x114e04,'controller':_0x5cd8c8('0x54a')}},'resolve':{'smsQueue':[_0x5cd8c8('0x1fbc'),_0x5cd8c8('0xf75'),function(_0x53027b,_0x4e1ec2){const _0x4888c1=_0x5cd8c8;return _0x53027b['resolve'](_0x4888c1('0xcaa'),{'fields':_0x4888c1('0xf26'),'id':_0x4e1ec2['id']});}],'userProfileSection':[_0x5cd8c8('0x1fbc'),'Auth',function(_0x3b0c3a,_0x17cb02){const _0x6a5a42=_0x5cd8c8;return _0x3b0c3a['resolve'](_0x6a5a42('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x17cb02['getCurrentUser']()['userProfileId'],'sectionId':0x2bd});}]},'authenticate':!![],'permissionId':0x2bd,'bodyClass':'sms'})[_0x5cd8c8('0x63f')]('app.sms.smsAccounts',{'url':_0x5cd8c8('0x607'),'views':{'content@app':{'templateUrl':_0x17313f,'controller':_0x5cd8c8('0x20d3')}},'resolve':{'smsAccounts':[_0x5cd8c8('0x1fbc'),_0x5cd8c8('0x21ef'),function(_0x156e5f,_0x4c14c4){const _0x3f19ee=_0x5cd8c8;return _0x4c14c4[_0x3f19ee('0x1ac6')](_0x3f19ee('0xa7c'))?_0x156e5f['resolve'](_0x3f19ee('0x1b3'),{'fields':'createdAt,updatedAt,id,name,key,token,remote,ListId,type,phone,accountSid,authId,authToken,smsMethod,username,password,baseUrl,apiKey,senderString,deliveryReport,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,receiveUrl,deliveryReportUrl,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','sort':_0x3f19ee('0x14dc'),'limit':0xa,'offset':0x0}):_0x156e5f[_0x3f19ee('0x18af')]('userProfile@getResources',{'id':_0x4c14c4[_0x3f19ee('0x26cd')]()['userProfileId'],'section':_0x3f19ee('0x1442'),'fields':'createdAt,updatedAt,id,name,key,token,remote,ListId,type,phone,accountSid,authId,authToken,smsMethod,username,password,baseUrl,apiKey,senderString,deliveryReport,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,receiveUrl,deliveryReportUrl,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','sort':_0x3f19ee('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x5cd8c8('0x1fbc'),'Auth',function(_0x7b419a,_0x2cde7a){const _0xa0e4e8=_0x5cd8c8;return _0x2cde7a[_0xa0e4e8('0x1ac6')](_0xa0e4e8('0xa7c'))?null:_0x7b419a[_0xa0e4e8('0x18af')](_0xa0e4e8('0x697'),{'fields':_0xa0e4e8('0x686'),'id':_0x2cde7a[_0xa0e4e8('0x26cd')]()[_0xa0e4e8('0xb86')]});}],'userProfileSection':[_0x5cd8c8('0x1fbc'),_0x5cd8c8('0x21ef'),function(_0x25571a,_0x5ed81e){const _0x4bbf99=_0x5cd8c8;return _0x5ed81e[_0x4bbf99('0x1ac6')](_0x4bbf99('0xa7c'))?null:_0x25571a[_0x4bbf99('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5ed81e[_0x4bbf99('0x26cd')]()['userProfileId'],'sectionId':0x2be});}]},'authenticate':!![],'permissionId':0x2be,'bodyClass':_0x5cd8c8('0x146c')})[_0x5cd8c8('0x63f')](_0x5cd8c8('0xe43'),{'url':_0x5cd8c8('0x2233'),'params':{'smsAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x143228,'controller':'SmsAccountController\x20as\x20vm'}},'resolve':{'smsAccount':[_0x5cd8c8('0x1fbc'),_0x5cd8c8('0xf75'),function(_0x366645,_0xc831dd){const _0x1c8a25=_0x5cd8c8;return _0x366645['resolve'](_0x1c8a25('0x1b3'),{'fields':_0x1c8a25('0x1eac'),'id':_0xc831dd['id']});}],'userProfileSection':['apiResolver',_0x5cd8c8('0x21ef'),function(_0x4b4482,_0x54a46b){const _0x251bb5=_0x5cd8c8;return _0x4b4482[_0x251bb5('0x18af')](_0x251bb5('0xaf'),{'fields':_0x251bb5('0xe26'),'userProfileId':_0x54a46b[_0x251bb5('0x26cd')]()[_0x251bb5('0xb86')],'sectionId':0x2be});}]},'authenticate':!![],'permissionId':0x2be,'bodyClass':_0x5cd8c8('0x146c')}),_0x198b88[_0x5cd8c8('0x95e')](_0x5cd8c8('0x10e3'));}angular[_0x36e6f4('0x896')]('app.sms',[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),'md.data.table',_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),'ckeditor',_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),'ngAnimate','mdPickers','mwFormBuilder',_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),_0x36e6f4('0x1e4b')])[_0x36e6f4('0xe11')](_0x2e6dfe)[_0x36e6f4('0x75e')](_0x36e6f4('0x2799'),_0x2eabf2)[_0x36e6f4('0x75e')](_0x36e6f4('0x259a'),_0x3c9a6e)[_0x36e6f4('0x75e')](_0x36e6f4('0x962'),_0x28c7cc)['controller'](_0x36e6f4('0x18c'),_0x56c1b8)['controller']('EditSmsAccountAppamazonlexDialogController',_0x142d96)[_0x36e6f4('0x75e')](_0x36e6f4('0xd6e'),_0x172585)[_0x36e6f4('0x75e')](_0x36e6f4('0x7f4'),_0x35b5df)[_0x36e6f4('0x75e')](_0x36e6f4('0x1251'),_0x5e458e)[_0x36e6f4('0x75e')](_0x36e6f4('0x792'),_0xd463c1)[_0x36e6f4('0x75e')](_0x36e6f4('0x322'),_0x45d662)[_0x36e6f4('0x75e')]('EditSmsAccountAppintervalDialogController',_0x5a2758)[_0x36e6f4('0x75e')]('EditSmsAccountAppnoopDialogController',_0x3ff29d)['controller']('EditSmsAccountAppqueueDialogController',_0x43a932)[_0x36e6f4('0x75e')](_0x36e6f4('0xb46'),_0x130721)[_0x36e6f4('0x75e')](_0x36e6f4('0x21cd'),_0x3e0f76)['controller'](_0x36e6f4('0xbc9'),_0x13de71)[_0x36e6f4('0x75e')]('SmsAccountSmsCannedAnswersController',_0x2050c0)[_0x36e6f4('0x75e')]('CreateOrEditSmsCannedAnswerDialogController',_0x12957e)['controller'](_0x36e6f4('0x2541'),_0xb9c92b)[_0x36e6f4('0x75e')](_0x36e6f4('0x2124'),_0x5e5e13)[_0x36e6f4('0x75e')](_0x36e6f4('0x114d'),_0x4384e7)[_0x36e6f4('0x75e')](_0x36e6f4('0x1ec4'),_0x53af57)[_0x36e6f4('0x75e')](_0x36e6f4('0xe68'),_0x40c77c)['controller'](_0x36e6f4('0x162b'),_0xc23ea1)[_0x36e6f4('0x75e')](_0x36e6f4('0xf13'),_0x325986)[_0x36e6f4('0x75e')](_0x36e6f4('0x48e'),_0x20abc6);const _0x3c0c38=_0x2734b2['p']+_0x36e6f4('0x474'),_0x39a098=_0x2734b2['p']+_0x36e6f4('0xaca'),_0x1b872e=_0x2734b2['p']+_0x36e6f4('0x2886');_0xf480ff[_0x36e6f4('0x1294')]=['$scope','$q',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x18bc'),'pauses',_0x36e6f4('0x1f7e'),_0x36e6f4('0x24b7'),_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1a02'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0x10eb')];function _0xf480ff(_0xdbcb1,_0x1ea3cc,_0x1e715e,_0x149c3d,_0x45cd73,_0x21edb1,_0x15ebeb,_0x566ab6,_0x3ca03b,_0xf20d09,_0x10c3c1,_0x1a1cbf,_0xdd6ae0,_0x55c296,_0x4a2519,_0x45a399,_0x3d940b,_0x5dd580){const _0x41bef3=_0x36e6f4,_0xc84ef6=this,_0x5c3ec4=[_0x41bef3('0x1a82'),'online',_0x41bef3('0x2318'),_0x41bef3('0x3dc'),_0x41bef3('0x246c'),_0x41bef3('0x3dc'),_0x41bef3('0x1eef'),'address',_0x41bef3('0x1c5c'),_0x41bef3('0x287f'),'mailPause',_0x41bef3('0x178d'),_0x41bef3('0x11ee'),_0x41bef3('0x5aa'),_0x41bef3('0x2540'),_0x41bef3('0x6a8'),_0x41bef3('0x1b39'),'mailCapacity',_0x41bef3('0x2627'),_0x41bef3('0x361'),_0x41bef3('0x1462'),_0x41bef3('0x1107'),_0x41bef3('0x8cf'),_0x41bef3('0x82d'),_0x41bef3('0x1da1'),_0x41bef3('0x2681'),'faxCurrentCapacity','chatStatus',_0x41bef3('0x1f33'),_0x41bef3('0x25d8'),'smsStatus',_0x41bef3('0x1a5d'),_0x41bef3('0x276d'),_0x41bef3('0x17e1'),'chatStatusTime',_0x41bef3('0x43e'),'mailStatusTime','smsStatusTime','whatsappStatusTime','faxStatusTime',_0x41bef3('0x18c9'),_0x41bef3('0x1d3e'),_0x41bef3('0x1ad2'),_0x41bef3('0x158'),_0x41bef3('0x2167'),_0x41bef3('0x1c5b')],_0x2fb2d5=[_0x41bef3('0x1c5c'),_0x41bef3('0x287f'),_0x41bef3('0xb4'),_0x41bef3('0x178d'),_0x41bef3('0x11ee'),_0x41bef3('0x5aa'),_0x41bef3('0x2540'),_0x41bef3('0xb41')];_0xc84ef6['currentUser']=_0x45a399['getCurrentUser'](),_0xc84ef6[_0x41bef3('0xcdd')]=[_0x41bef3('0x1628'),'inuse',_0x41bef3('0x2344'),_0x41bef3('0x158e'),_0x41bef3('0x521')],_0xc84ef6['pauses']=_0x15ebeb||{'count':0x0,'rows':[]},_0xc84ef6[_0x41bef3('0x5c9')]=_0x3d940b,_0xc84ef6[_0x41bef3('0x7f')]=_0x55c296,_0xc84ef6[_0x41bef3('0x17aa')]=_0x4a2519&&_0x4a2519[_0x41bef3('0x240f')]==0x1?_0x4a2519[_0x41bef3('0x269a')][0x0]:null,_0xc84ef6[_0x41bef3('0x243c')]=_0x45a399[_0x41bef3('0xd87')](_0xc84ef6['userProfileSection']?_0xc84ef6[_0x41bef3('0x17aa')]['crudPermissions']:null),_0xc84ef6[_0x41bef3('0x1f7e')]=_0x566ab6?_0x2cfb05()[_0x41bef3('0x155c')](_0x566ab6[_0x41bef3('0x269a')]?_0x566ab6[_0x41bef3('0x269a')]:[],'id'):{},_0xc84ef6[_0x41bef3('0x24b7')]=_0x3ca03b?_0x2cfb05()[_0x41bef3('0x155c')](_0x3ca03b[_0x41bef3('0x269a')]?_0x3ca03b[_0x41bef3('0x269a')]:[],'id'):{},_0xc84ef6[_0x41bef3('0x5e5')]={},_0xc84ef6[_0x41bef3('0x173f')]=![],_0xc84ef6['order']=[],_0xc84ef6[_0x41bef3('0x4c4')]={};for(const _0x40883e in _0xc84ef6[_0x41bef3('0x1f7e')]){typeof _0xc84ef6[_0x41bef3('0x1f7e')][_0x40883e]!==_0x41bef3('0x1048')&&(_0xc84ef6[_0x41bef3('0x1f7e')][_0x40883e]['init']=!![]);}_0xc84ef6['query']={'limit':0xa,'page':0x1,'order':'fullname','globalStatusFilter':'','pauseTypeFilter':''},_0xc84ef6[_0x41bef3('0x885')]=_0x1ac5ec,_0xc84ef6[_0x41bef3('0xaf7')]=_0x521636,_0xc84ef6[_0x41bef3('0x1e77')]=_0x4c589f,_0xc84ef6[_0x41bef3('0xecc')]=_0x29bf14,_0xc84ef6[_0x41bef3('0x6df')]=_0x252c18,_0xc84ef6['getAgentStatus']=_0x316f16,_0xc84ef6[_0x41bef3('0x28b5')]=_0x51819e,_0xc84ef6[_0x41bef3('0x882')]=_0x135127,_0xc84ef6[_0x41bef3('0x5ad')]=_0x784bef,_0xc84ef6['isPartialPause']=_0x404ef6,_0xc84ef6['onSave']=_0x4c20e6,_0xc84ef6['onUpdate']=_0x46f359,_0xc84ef6[_0x41bef3('0xae0')]=_0x125633,_0xc84ef6[_0x41bef3('0x223a')]=_0x592725,_0xc84ef6[_0x41bef3('0x1923')]=_0x186e63,_0xc84ef6['screenRecording']=_0x49e8a7,_0x10c3c1['on'](_0x41bef3('0x26b2'),_0xc84ef6[_0x41bef3('0x1303')]),_0x10c3c1['on'](_0x41bef3('0x19d5'),_0xc84ef6['onUpdate']),_0x10c3c1['on'](_0x41bef3('0x10fc'),_0xc84ef6[_0x41bef3('0x223a')]),_0x10c3c1['on'](_0x41bef3('0x1c99'),_0xc84ef6['onComplete']),_0x125633();let _0x150311=_0x5dd580(function(){const _0x5a20ef=_0x41bef3;_0xc84ef6[_0x5a20ef('0x173f')]&&(_0xc84ef6[_0x5a20ef('0x173f')]=![],_0x125633());},0x3e7);function _0x125633(){const _0x42b8f9=_0x41bef3;_0xc84ef6['load']=![];const _0x5ae376=_0x1ea3cc[_0x42b8f9('0x24d8')]();_0xc84ef6[_0x42b8f9('0x1f48')]=_0x5ae376[_0x42b8f9('0x1f48')],_0xc84ef6[_0x42b8f9('0x220b')]=[],_0xc84ef6[_0x42b8f9('0xa99')]=[],_0x2cfb05()[_0x42b8f9('0x941')](_0xc84ef6[_0x42b8f9('0x1f7e')],function(_0x46f1a5,_0x14bd6b){const _0x5ae263=_0x42b8f9;_0xc84ef6[_0x5ae263('0x24b7')][_0x14bd6b]&&_0x2cfb05()[_0x5ae263('0xcc3')](_0x46f1a5,_0x2cfb05()[_0x5ae263('0x1a08')](_0x2cfb05()[_0x5ae263('0x1414')](_0xc84ef6[_0x5ae263('0x24b7')][_0x14bd6b],_0x2fb2d5),_0x5c3ec4)),_0x51819e(_0x46f1a5),_0x46f1a5[_0x5ae263('0xb41')]?(_0xc84ef6['filteredAgents'][_0x5ae263('0x1514')](_0x46f1a5),_0xc84ef6['agentInternal'][_0x46f1a5[_0x5ae263('0x1eef')]]=_0x14bd6b):_0x46f1a5[_0x5ae263('0x25b3')]=_0x2cfb05()['toNumber'](_0x24273b()()[_0x5ae263('0x128a')]('x'));});_0xc84ef6[_0x42b8f9('0x2218')]['globalStatusFilter']&&_0x2cfb05()[_0x42b8f9('0x127f')](_0xc84ef6[_0x42b8f9('0x220b')],function(_0x310072){const _0x3d1dd5=_0x42b8f9;return _0x310072[_0x3d1dd5('0xe34')]!==_0xc84ef6[_0x3d1dd5('0x2218')][_0x3d1dd5('0xf4')];});_0xc84ef6[_0x42b8f9('0x2218')][_0x42b8f9('0x2121')]&&_0x2cfb05()[_0x42b8f9('0x127f')](_0xc84ef6[_0x42b8f9('0x220b')],function(_0x21aea0){const _0x5b8182=_0x42b8f9;return _0x21aea0[_0x5b8182('0x246c')]!==_0xc84ef6[_0x5b8182('0x2218')]['pauseTypeFilter'];});_0xc84ef6[_0x42b8f9('0x2218')][_0x42b8f9('0x1c33')]&&_0x2cfb05()[_0x42b8f9('0x127f')](_0xc84ef6[_0x42b8f9('0x220b')],function(_0x69ac6b){const _0x545a24=_0x42b8f9;return _0x69ac6b[_0x545a24('0x6e1')]['toLowerCase']()[_0x545a24('0x2379')](_0xc84ef6['query']['filter'][_0x545a24('0x2574')]())<0x0;});_0xc84ef6[_0x42b8f9('0x220b')]=_0x511744(_0xc84ef6['filteredAgents']);const _0x428725=(_0xc84ef6['query'][_0x42b8f9('0x1a43')]-0x1)*_0xc84ef6[_0x42b8f9('0x2218')]['limit'];_0xc84ef6[_0x42b8f9('0x5e5')]=_0x2cfb05()['drop'](_0xc84ef6[_0x42b8f9('0x220b')],_0x428725)[_0x42b8f9('0x233')](0x0,_0xc84ef6['query'][_0x42b8f9('0x163f')]);for(let _0x470a3b=0x0;_0x470a3b<_0xc84ef6[_0x42b8f9('0x5e5')][_0x42b8f9('0x264b')];_0x470a3b+=0x1){_0xc84ef6['order']['push'](_0xc84ef6[_0x42b8f9('0x5e5')][_0x470a3b]['id']);}_0x5ae376[_0x42b8f9('0x18af')](),_0xc84ef6[_0x42b8f9('0x173f')]=!![];}function _0x4c20e6(_0x53bffa){const _0x2b735d=_0x41bef3;_0xc84ef6[_0x2b735d('0x1f7e')][_0x53bffa['id']]&&(_0x2cfb05()[_0x2b735d('0xcc3')](_0xc84ef6[_0x2b735d('0x1f7e')][_0x53bffa['id']],_0x2cfb05()[_0x2b735d('0x1a08')](_0x2cfb05()[_0x2b735d('0x1414')](_0x53bffa,_0x2fb2d5),_0x5c3ec4)),_0x2cfb05()['merge'](_0xc84ef6[_0x2b735d('0x24b7')][_0x53bffa['id']],_0x2cfb05()[_0x2b735d('0x1a08')](_0x2cfb05()['omit'](_0x53bffa,_0x2fb2d5),_0x5c3ec4)),_0x51819e(_0xc84ef6[_0x2b735d('0x1f7e')][_0x53bffa['id']]));}function _0x46f359(_0x13b3c0){const _0xbe2342=_0x41bef3;_0xc84ef6['agents'][_0x13b3c0['id']]&&(_0x2cfb05()[_0xbe2342('0xcc3')](_0xc84ef6[_0xbe2342('0x1f7e')][_0x13b3c0['id']],_0x2cfb05()[_0xbe2342('0x1a08')](_0x13b3c0,_0x5c3ec4)),_0x2cfb05()[_0xbe2342('0xcc3')](_0xc84ef6['rpcAgents'][_0x13b3c0['id']],_0x2cfb05()[_0xbe2342('0x1a08')](_0x13b3c0,_0x5c3ec4)),_0x13b3c0['lastPauseAt']&&(_0xc84ef6['agents'][_0x13b3c0['id']][_0xbe2342('0x25b3')]=_0x13b3c0[_0xbe2342('0x3dc')],_0xc84ef6['rpcAgents'][_0x13b3c0['id']][_0xbe2342('0x25b3')]=_0x13b3c0[_0xbe2342('0x3dc')]),_0x51819e(_0xc84ef6[_0xbe2342('0x1f7e')][_0x13b3c0['id']]));}function _0x592725(_0x4c99ae){const _0x4cbd41=_0x41bef3;_0xc84ef6[_0x4cbd41('0x1f7e')][_0xc84ef6['agentInternal'][_0x4c99ae[_0x4cbd41('0x25fc')]]]&&(_0x2cfb05()[_0x4cbd41('0xcc3')](_0xc84ef6[_0x4cbd41('0x1f7e')][_0xc84ef6[_0x4cbd41('0x4c4')][_0x4c99ae['destaccountcode']]],_0x2cfb05()[_0x4cbd41('0x1a08')](_0x4c99ae,['queue',_0x4cbd41('0x1ad2')])),_0x2cfb05()[_0x4cbd41('0xcc3')](_0xc84ef6['rpcAgents'][_0xc84ef6[_0x4cbd41('0x4c4')][_0x4c99ae['destaccountcode']]],_0x2cfb05()['pick'](_0x4c99ae,['queue',_0x4cbd41('0x1ad2')])));}function _0x186e63(_0x887e04){const _0x56adfe=_0x41bef3;_0xc84ef6[_0x56adfe('0x1f7e')][_0xc84ef6[_0x56adfe('0x4c4')][_0x887e04[_0x56adfe('0x25fc')]]]&&(_0xc84ef6['agents'][_0xc84ef6[_0x56adfe('0x4c4')][_0x887e04[_0x56adfe('0x25fc')]]]=_0x2cfb05()[_0x56adfe('0x1414')](_0xc84ef6[_0x56adfe('0x1f7e')][_0xc84ef6[_0x56adfe('0x4c4')][_0x887e04[_0x56adfe('0x25fc')]]],[_0x56adfe('0x1d3e'),_0x56adfe('0x1ad2')]),_0xc84ef6[_0x56adfe('0x24b7')][_0xc84ef6[_0x56adfe('0x4c4')][_0x887e04[_0x56adfe('0x25fc')]]]=_0x2cfb05()[_0x56adfe('0x1414')](_0xc84ef6[_0x56adfe('0x24b7')][_0xc84ef6[_0x56adfe('0x4c4')][_0x887e04[_0x56adfe('0x25fc')]]],[_0x56adfe('0x1d3e'),_0x56adfe('0x1ad2')]));}function _0x1ac5ec(_0x21bba5){const _0x3d59f6=_0x41bef3;return _0xf20d09[_0x3d59f6('0x557')]['logout']({'id':_0x21bba5['id'],'device':_0x3d59f6('0xf01'),'agent_id':_0x21bba5['id'],'agent_name':_0x21bba5[_0x3d59f6('0x4f0')]})[_0x3d59f6('0xa44')]['then'](function(){const _0x92771=_0x3d59f6;_0x1a1cbf[_0x92771('0x103b')]({'title':_0x92771('0x16a7'),'msg':_0x21bba5[_0x92771('0x6e1')]+_0x92771('0x22ec')}),_0xc84ef6[_0x92771('0x1f7e')][_0x21bba5['id']]&&(_0xc84ef6[_0x92771('0x1f7e')][_0x21bba5['id']][_0x92771('0xb41')]=![]),_0xc84ef6['rpcAgents'][_0x21bba5['id']]&&(_0xc84ef6[_0x92771('0x24b7')][_0x21bba5['id']][_0x92771('0xb41')]=![]),_0x125633();})['catch'](function(_0x23f049){const _0x20f0fa=_0x3d59f6;_0x1a1cbf[_0x20f0fa('0xfc9')]({'title':_0x23f049['status']?_0x20f0fa('0x1e21')+_0x23f049[_0x20f0fa('0x52d')]+'\x20-\x20'+_0x23f049[_0x20f0fa('0xe1b')]:_0x20f0fa('0x1e3c'),'msg':_0x23f049[_0x20f0fa('0x25f4')]?JSON['stringify'](_0x23f049[_0x20f0fa('0x25f4')]['message']):_0x23f049[_0x20f0fa('0x1586')]()});});}function _0x4c589f(_0x14081c,_0x59449e){const _0x6d07eb=_0x41bef3;return _0xf20d09[_0x6d07eb('0x557')][_0x6d07eb('0x1e77')]({'id':_0x14081c['id'],'type':_0x59449e})[_0x6d07eb('0xa44')][_0x6d07eb('0x1166')](function(_0x26e8d0){const _0x340484=_0x6d07eb;_0xc84ef6[_0x340484('0x1f7e')][_0x14081c['id']]&&_0x2cfb05()['merge'](_0xc84ef6[_0x340484('0x1f7e')][_0x14081c['id']],_0x2cfb05()[_0x340484('0x1a08')](_0x26e8d0,_0x5c3ec4)),_0xc84ef6['rpcAgents'][_0x14081c['id']]&&_0x2cfb05()['merge'](_0xc84ef6['rpcAgents'][_0x14081c['id']],_0x2cfb05()[_0x340484('0x1a08')](_0x26e8d0,_0x5c3ec4)),_0x51819e(_0xc84ef6[_0x340484('0x1f7e')][_0x14081c['id']]);})[_0x6d07eb('0x1a80')](function(_0x329e33){const _0xe59657=_0x6d07eb;_0x1a1cbf[_0xe59657('0xfc9')]({'title':_0x329e33[_0xe59657('0x52d')]?_0xe59657('0x1e21')+_0x329e33['status']+_0xe59657('0x11e1')+_0x329e33['statusText']:'api.staff.save','msg':_0x329e33[_0xe59657('0x25f4')]?JSON[_0xe59657('0xbac')](_0x329e33[_0xe59657('0x25f4')]['message']):_0x329e33[_0xe59657('0x1586')]()});});}function _0x29bf14(_0x1a23b3){const _0x3a36bf=_0x41bef3;return _0xf20d09[_0x3a36bf('0x557')][_0x3a36bf('0x20eb')]({'id':_0x1a23b3['id']})['$promise']['then'](function(_0x33a98f){const _0x102127=_0x3a36bf;_0xc84ef6[_0x102127('0x1f7e')][_0x1a23b3['id']]&&_0x2cfb05()[_0x102127('0xcc3')](_0xc84ef6[_0x102127('0x1f7e')][_0x1a23b3['id']],_0x2cfb05()[_0x102127('0x1a08')](_0x33a98f,_0x5c3ec4)),_0xc84ef6[_0x102127('0x24b7')][_0x1a23b3['id']]&&_0x2cfb05()['merge'](_0xc84ef6[_0x102127('0x24b7')][_0x1a23b3['id']],_0x2cfb05()[_0x102127('0x1a08')](_0x33a98f,_0x5c3ec4)),_0x51819e(_0xc84ef6[_0x102127('0x1f7e')][_0x1a23b3['id']]);})[_0x3a36bf('0x1a80')](function(_0x4147f7){const _0x34b49f=_0x3a36bf;_0x1a1cbf[_0x34b49f('0xfc9')]({'title':_0x4147f7[_0x34b49f('0x52d')]?_0x34b49f('0x1e21')+_0x4147f7[_0x34b49f('0x52d')]+_0x34b49f('0x11e1')+_0x4147f7[_0x34b49f('0xe1b')]:_0x34b49f('0x1e3c'),'msg':_0x4147f7['data']?JSON[_0x34b49f('0xbac')](_0x4147f7[_0x34b49f('0x25f4')]['message']):_0x4147f7['toString']()});});}function _0x252c18(_0x35dc18){const _0x51640b=_0x41bef3;_0x149c3d[_0x51640b('0x1f80')](_0x149c3d['alert']()['clickOutsideToClose'](!![])[_0x51640b('0xcdc')](_0x51640b('0x58a'))['htmlContent'](_0x51640b('0x1174'))['ok']('Ok')['targetEvent'](_0x35dc18));}function _0x521636(_0x28a61a,_0x1d509d){const _0x24dd32=_0x41bef3;_0x149c3d[_0x24dd32('0x1f80')]({'controller':_0x24dd32('0xf19'),'controllerAs':'vm','templateUrl':_0x49c5be,'parent':angular[_0x24dd32('0x1194')](_0x45cd73[_0x24dd32('0x8d2')]),'targetEvent':_0x1d509d,'clickOutsideToClose':!![],'locals':{'agent':_0x28a61a,'agents':[],'channel':'openchannel','direction':_0x24dd32('0x14d8'),'crudPermissions':_0xc84ef6[_0x24dd32('0x243c')]}});}function _0x135127(_0x22dded){const _0x22151d=_0x41bef3;return _0x22dded==='pause'||_0x22dded===_0x22151d('0x6e8');}function _0x784bef(_0x527647){return _0x527647==='pause';}function _0x404ef6(_0x3d9fd9){const _0x2dbd7e=_0x41bef3;return _0x3d9fd9===_0x2dbd7e('0x6e8');}function _0x333e96(_0x1e7612){const _0x29eec0=_0x41bef3;return _0x1e7612===_0x29eec0('0xdb0')||_0x1e7612==='unknown'||_0x1e7612===_0x29eec0('0x14dd')||_0x1e7612===_0x29eec0('0x1628')||_0x2cfb05()[_0x29eec0('0x2863')](_0x1e7612);}function _0x316f16(_0x2e11a2,_0x4199d4){const _0x43b0ac=_0x41bef3;if(_0x4199d4===_0x43b0ac('0x21da')){if(_0x2e11a2[_0x4199d4+_0x43b0ac('0x28f6')]!==_0x43b0ac('0xdb0'))return _0x2e11a2[_0x4199d4+'Status'];if(_0x2e11a2[_0x4199d4+_0x43b0ac('0x108')])return _0x2e11a2[_0x4199d4+'Status']=_0x43b0ac('0x1e77'),_0x43b0ac('0x1e77');return _0x43b0ac('0xdb0');}else{if(_0x2e11a2[_0x4199d4+_0x43b0ac('0x108')])return _0x2e11a2[_0x4199d4+'Status']=_0x43b0ac('0x1e77'),_0x43b0ac('0x1e77');return _0x2e11a2[_0x4199d4+'Status'];}}function _0x51819e(_0x4ded59){const _0x36887f=_0x41bef3;let _0x479f56=_0x36887f('0x22d5');if(_0x2cfb05()[_0x36887f('0x2285')]([_0x316f16(_0x4ded59,_0x36887f('0x21da')),_0x316f16(_0x4ded59,_0x36887f('0xde2')),_0x316f16(_0x4ded59,_0x36887f('0x1bfa')),_0x316f16(_0x4ded59,_0x36887f('0x26c')),_0x316f16(_0x4ded59,_0x36887f('0x146c')),_0x316f16(_0x4ded59,'whatsapp'),_0x316f16(_0x4ded59,_0x36887f('0x1fc7'))],_0x135127))_0x479f56=_0x36887f('0x1e77');else{if(_0x2cfb05()[_0x36887f('0x1798')]([_0x316f16(_0x4ded59,_0x36887f('0x21da')),_0x316f16(_0x4ded59,_0x36887f('0xde2')),_0x316f16(_0x4ded59,_0x36887f('0x1bfa')),_0x316f16(_0x4ded59,_0x36887f('0x26c')),_0x316f16(_0x4ded59,_0x36887f('0x146c')),_0x316f16(_0x4ded59,_0x36887f('0x116e')),_0x316f16(_0x4ded59,'fax')],_0x135127))_0x479f56=_0x36887f('0x6e8');else _0x2cfb05()[_0x36887f('0x2285')]([_0x316f16(_0x4ded59,_0x36887f('0x21da')),_0x316f16(_0x4ded59,_0x36887f('0xde2')),_0x316f16(_0x4ded59,_0x36887f('0x1bfa')),_0x316f16(_0x4ded59,_0x36887f('0x26c')),_0x316f16(_0x4ded59,_0x36887f('0x146c')),_0x316f16(_0x4ded59,_0x36887f('0x116e')),_0x316f16(_0x4ded59,_0x36887f('0x1fc7'))],_0x333e96)?_0x479f56=_0x36887f('0xdb0'):_0x479f56='busy';}_0x4ded59[_0x36887f('0xe34')]!==_0x479f56&&(_0x4ded59[_0x36887f('0xe34')]=_0x479f56,_0x4ded59[_0x36887f('0x24d5')]?(_0x4ded59[_0x36887f('0x24d5')]=![],_0x4ded59['globalStatusTime']=_0x135127(_0x479f56)?_0x2cfb05()[_0x36887f('0xa53')](_0x24273b()(_0x4ded59[_0x36887f('0x3dc')])[_0x36887f('0x128a')]('x')):_0x2cfb05()['max']([_0x4ded59[_0x36887f('0x18c9')],_0x4ded59['chatStatusTime'],_0x4ded59[_0x36887f('0x1955')],_0x4ded59[_0x36887f('0x2357')],_0x4ded59['whatsappStatusTime'],_0x4ded59[_0x36887f('0x43e')],_0x4ded59[_0x36887f('0x4f3')]])):_0x4ded59[_0x36887f('0x25b3')]=_0x2cfb05()[_0x36887f('0xa53')](_0x24273b()()[_0x36887f('0x128a')]('x')));}function _0x511744(_0x16f2d6){const _0x2ceeef=_0x41bef3,_0x54e82d=_0x2cfb05()['startsWith'](_0xc84ef6[_0x2ceeef('0x2218')]['order'],'-')?_0x2ceeef('0x1dc3'):_0x2ceeef('0x17d');return _0x2cfb05()[_0x2ceeef('0xe63')](_0x16f2d6,[_0xc84ef6['query'][_0x2ceeef('0xa99')][_0x2ceeef('0xf3')]('-','')],[_0x54e82d]);}function _0x5076a4(){const _0x2fafda=_0x41bef3;_0x150311&&(_0x5dd580[_0x2fafda('0x3f')](_0x150311),_0x150311=null);}function _0x49e8a7(_0x1b8f25,_0x4478a1){const _0x15aee3=_0x41bef3;return _0xf20d09['user']['update']({'id':_0x1b8f25['id']},{'screenrecording':_0x4478a1})[_0x15aee3('0xa44')][_0x15aee3('0x1a80')](function(_0x2f87de){const _0xc69f8=_0x15aee3;_0x1a1cbf[_0xc69f8('0xfc9')]({'title':_0x2f87de[_0xc69f8('0x52d')]?'API:'+_0x2f87de[_0xc69f8('0x52d')]+_0xc69f8('0x11e1')+_0x2f87de['statusText']:_0xc69f8('0x1103'),'msg':_0x2f87de[_0xc69f8('0x25f4')]?JSON[_0xc69f8('0xbac')](_0x2f87de['data']['message']):_0x2f87de[_0xc69f8('0x1586')]()});});}_0xdbcb1[_0x41bef3('0x3d2')]('$destroy',function(){const _0x11a836=_0x41bef3;_0x10c3c1[_0x11a836('0x1800')](_0x11a836('0x26b2')),_0x10c3c1['removeAllListeners']('user:update'),_0x10c3c1[_0x11a836('0x1800')](_0x11a836('0x10fc')),_0x10c3c1[_0x11a836('0x1800')](_0x11a836('0x1c99')),_0x5076a4();});}const _0x12267d=_0xf480ff,_0x40072f=_0x2734b2['p']+_0x36e6f4('0x1002'),_0xd7ba85=_0x2734b2['p']+'src/js/modules/main/apps/openchannel/views/openchannelQueues/edit/agentadd/agentadd.html/agentadd.html';_0x218109['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1c90'),_0x36e6f4('0x10eb'),_0x36e6f4('0x7a7'),_0x36e6f4('0x744'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x218109(_0x5383c2,_0x5c5548,_0x5e68d3,_0xbfe117,_0x16b8f0,_0x3406f0,_0x30e01c,_0x42745f,_0x168940,_0x2646cc,_0x600111,_0x36773e,_0xc58d33,_0x4cb312){const _0x2a6a62=_0x36e6f4,_0x5a4ea8=this,_0x2e3259=[_0x2a6a62('0x1570'),'available',_0x2a6a62('0x288a'),_0x2a6a62('0x46a'),_0x2a6a62('0x67d'),_0x2a6a62('0x20ab'),_0x2a6a62('0x1e70'),_0x2a6a62('0x6c9'),'dialMethod',_0x2a6a62('0x14c4'),'paused'];_0x5a4ea8['currentUser']=_0x4cb312[_0x2a6a62('0x26cd')](),_0x5a4ea8[_0x2a6a62('0x240f')]=_0x30e01c[_0x2a6a62('0x240f')]?_0x30e01c['count']:0x0,_0x5a4ea8[_0x2a6a62('0x7a7')]=_0x30e01c?_0x2cfb05()[_0x2a6a62('0x155c')](_0x30e01c[_0x2a6a62('0x269a')]?_0x30e01c[_0x2a6a62('0x269a')]:[],'id'):{},_0x5a4ea8[_0x2a6a62('0x744')]=_0x42745f?_0x2cfb05()[_0x2a6a62('0x155c')](_0x42745f[_0x2a6a62('0x269a')]?_0x42745f[_0x2a6a62('0x269a')]:[],'id'):{},_0x5a4ea8[_0x2a6a62('0x7f')]=_0x36773e,_0x5a4ea8[_0x2a6a62('0x17aa')]=_0xc58d33&&_0xc58d33[_0x2a6a62('0x240f')]==0x1?_0xc58d33[_0x2a6a62('0x269a')][0x0]:null,_0x5a4ea8[_0x2a6a62('0x243c')]=_0x4cb312[_0x2a6a62('0xd87')](_0x5a4ea8[_0x2a6a62('0x17aa')]?_0x5a4ea8[_0x2a6a62('0x17aa')][_0x2a6a62('0x243c')]:null);_0x4cb312['hasRole'](_0x2a6a62('0xa7c'))?_0x5a4ea8[_0x2a6a62('0x2218')]={'type':_0x2a6a62('0x14d8'),'sort':_0x2a6a62('0x14dc'),'limit':0xa,'page':0x1}:_0x5a4ea8['query']={'id':_0x5a4ea8[_0x2a6a62('0x98')]['id'],'channel':_0x2a6a62('0x26c'),'type':_0x2a6a62('0x14d8'),'sort':_0x2a6a62('0x14dc'),'limit':0xa,'page':0x1};_0x5a4ea8[_0x2a6a62('0x103b')]=_0x511200,_0x5a4ea8[_0x2a6a62('0x152a')]=_0x47d4c4,_0x5a4ea8[_0x2a6a62('0xa5f')]=_0x53ebf7,_0x5a4ea8[_0x2a6a62('0x33f')]=_0x22933d,_0x5a4ea8[_0x2a6a62('0xeba')]=_0x396f7a,_0x5a4ea8[_0x2a6a62('0x1303')]=_0x2e79f3,_0x5a4ea8['onSaveMember']=_0x3d33f2,_0x5a4ea8[_0x2a6a62('0xfe9')]=_0x2dfbd7,_0x5a4ea8['onPause']=_0x5c7d0e,_0x5a4ea8[_0x2a6a62('0xb9a')]=_0x1eded4,_0x5a4ea8[_0x2a6a62('0x1696')]=_0x19746a,_0x5a4ea8[_0x2a6a62('0x1089')]=_0x11cc46,_0x5a4ea8[_0x2a6a62('0xa99')]=[],_0x2cfb05()[_0x2a6a62('0x941')](_0x5a4ea8[_0x2a6a62('0x7a7')],function(_0x4189bd){const _0x1e5bab=_0x2a6a62;_0x5a4ea8[_0x1e5bab('0xa99')][_0x1e5bab('0x1514')](_0x4189bd['id']);}),_0x2646cc['on']('openchannel_queue:save',_0x5a4ea8[_0x2a6a62('0x1303')]),_0x2646cc['on']('userOpenchannelQueue:save',_0x5a4ea8[_0x2a6a62('0xfb')]),_0x2646cc['on'](_0x2a6a62('0x1f45'),_0x5a4ea8[_0x2a6a62('0xfe9')]),_0x2646cc['on'](_0x2a6a62('0x19d5'),_0x5a4ea8[_0x2a6a62('0x212c')]),_0x2646cc['on'](_0x2a6a62('0x25f0'),_0x5a4ea8[_0x2a6a62('0x1696')]),_0x2646cc['on'](_0x2a6a62('0x663'),_0x5a4ea8[_0x2a6a62('0xb9a')]);function _0x11cc46(){const _0x4329a0=_0x2a6a62,_0x117745=[];return _0x2cfb05()[_0x4329a0('0x941')](_0x5a4ea8['queues'],function(_0x439b0a,_0x29f59a){const _0x2d3a67=_0x4329a0;_0x439b0a[_0x2d3a67('0x18b')]=0x0,_0x439b0a[_0x2d3a67('0x2689')]=0x0,_0x5a4ea8[_0x2d3a67('0x7a7')][_0x29f59a][_0x2d3a67('0x1f7e')]={},_0x117745[_0x2d3a67('0x1514')](_0x168940[_0x2d3a67('0x262f')][_0x2d3a67('0x27d1')]({'id':_0x29f59a})[_0x2d3a67('0xa44')]),_0x5a4ea8['rpcQueues'][_0x29f59a]&&_0x2cfb05()[_0x2d3a67('0xcc3')](_0x439b0a,_0x2cfb05()[_0x2d3a67('0x1a08')](_0x5a4ea8[_0x2d3a67('0x744')][_0x29f59a],_0x2e3259));}),_0xbfe117[_0x4329a0('0x2760')](_0x117745)[_0x4329a0('0x1166')](function(_0x2e35b7){const _0x1cbc9d=_0x4329a0;for(let _0x49cd6e=0x0;_0x49cd6e<_0x2e35b7[_0x1cbc9d('0x264b')];_0x49cd6e+=0x1){for(let _0x1cdf7c=0x0;_0x1cdf7c<_0x2e35b7[_0x49cd6e]['rows']['length'];_0x1cdf7c++){_0x2e35b7[_0x49cd6e][_0x1cbc9d('0x269a')][_0x1cdf7c][_0x1cbc9d('0x18b')]&&_0x5a4ea8[_0x1cbc9d('0x7a7')][_0x2e35b7[_0x49cd6e][_0x1cbc9d('0x269a')][_0x1cdf7c][_0x1cbc9d('0x27e0')]][_0x1cbc9d('0x18b')]++,_0x5a4ea8[_0x1cbc9d('0x7a7')][_0x2e35b7[_0x49cd6e][_0x1cbc9d('0x269a')][_0x1cdf7c]['OpenchannelQueueId']][_0x1cbc9d('0x2689')]++,_0x5a4ea8[_0x1cbc9d('0x7a7')][_0x2e35b7[_0x49cd6e][_0x1cbc9d('0x269a')][_0x1cdf7c]['OpenchannelQueueId']][_0x1cbc9d('0x1f7e')][_0x2e35b7[_0x49cd6e][_0x1cbc9d('0x269a')][_0x1cdf7c][_0x1cbc9d('0x122a')]]=_0x2e35b7[_0x49cd6e][_0x1cbc9d('0x269a')][_0x1cdf7c]['OpenchannelQueueId'];}}})[_0x4329a0('0x1a80')](function(_0x15b28f){const _0x5a46e8=_0x4329a0;console[_0x5a46e8('0xfc9')](_0x15b28f);});}function _0x2e79f3(_0x4a14cc){const _0x55617a=_0x2a6a62;_0x5a4ea8[_0x55617a('0x7a7')][_0x4a14cc['id']]&&_0x2cfb05()[_0x55617a('0xcc3')](_0x5a4ea8[_0x55617a('0x7a7')][_0x4a14cc['id']],_0x2cfb05()[_0x55617a('0x1a08')](_0x4a14cc,_0x2e3259));}function _0x3d33f2(_0x1147fa){const _0x93e419=_0x2a6a62;_0x5a4ea8[_0x93e419('0x7a7')][_0x1147fa[_0x93e419('0x27e0')]]&&_0x5a4ea8['queues'][_0x1147fa[_0x93e419('0x27e0')]][_0x93e419('0x2689')]++;}function _0x2dfbd7(_0x2242c5){const _0x3afa90=_0x2a6a62;_0x5a4ea8[_0x3afa90('0x7a7')][_0x2242c5[_0x3afa90('0x27e0')]]&&_0x5a4ea8[_0x3afa90('0x7a7')][_0x2242c5[_0x3afa90('0x27e0')]][_0x3afa90('0x2689')]--;}function _0x5c7d0e(_0x243ef5){const _0x2af931=_0x2a6a62;console[_0x2af931('0x455')](_0x2af931('0x212c'),_0x243ef5);if(_0x243ef5[_0x2af931('0x2540')])_0x2cfb05()['forIn'](_0x5a4ea8['queues'],function(_0x39282e){const _0x524db6=_0x2af931;_0x39282e[_0x524db6('0x1f7e')][_0x243ef5['id']]&&(_0x39282e['paused']+=0x1,console[_0x524db6('0x455')]('pause'));});else!_0x243ef5['voicePause']&&_0x2cfb05()['forIn'](_0x5a4ea8[_0x2af931('0x7a7')],function(_0x1934ed){const _0x50e94f=_0x2af931;_0x1934ed[_0x50e94f('0x1f7e')][_0x243ef5['id']]&&(_0x1934ed[_0x50e94f('0x18b')]>0x0&&(_0x1934ed['paused']-=0x1,console['log']('unpause')));});}function _0x1eded4(_0x54e296){const _0x55237e=_0x2a6a62;console[_0x55237e('0x455')](_0x55237e('0x26c1'),_0x54e296),_0x5a4ea8[_0x55237e('0x7a7')][_0x54e296['OpenchannelQueueId']]&&(_0x5a4ea8[_0x55237e('0x7a7')][_0x54e296['OpenchannelQueueId']][_0x55237e('0x2689')]+=0x1,_0x5a4ea8[_0x55237e('0x7a7')][_0x54e296[_0x55237e('0x27e0')]]['agents'][_0x54e296[_0x55237e('0x122a')]]=_0x54e296[_0x55237e('0x27e0')]);}function _0x19746a(_0xfd2ba7){const _0x532013=_0x2a6a62;console[_0x532013('0x455')](_0x532013('0x1696'),_0xfd2ba7),_0x5a4ea8[_0x532013('0x7a7')][_0xfd2ba7[_0x532013('0x27e0')]]&&_0x5a4ea8[_0x532013('0x7a7')][_0xfd2ba7[_0x532013('0x27e0')]][_0x532013('0x2689')]>0x0&&(_0x5a4ea8[_0x532013('0x7a7')][_0xfd2ba7[_0x532013('0x27e0')]][_0x532013('0x2689')]-=0x1,delete _0x5a4ea8[_0x532013('0x7a7')][_0xfd2ba7[_0x532013('0x27e0')]][_0x532013('0x1f7e')][_0xfd2ba7[_0x532013('0x122a')]]);}let _0xa7bdcb=!![],_0x148dc4=0x1;_0x5383c2[_0x2a6a62('0xe83')](_0x2a6a62('0x12d8'),function(_0x5bda38,_0x2c04b7){const _0x140185=_0x2a6a62;_0xa7bdcb?_0x5c5548(function(){_0xa7bdcb=![];}):(!_0x2c04b7&&(_0x148dc4=_0x5a4ea8[_0x140185('0x2218')][_0x140185('0x1a43')]),_0x5bda38!==_0x2c04b7&&(_0x5a4ea8['query'][_0x140185('0x1a43')]=0x1),!_0x5bda38&&(_0x5a4ea8[_0x140185('0x2218')][_0x140185('0x1a43')]=_0x148dc4),_0x5a4ea8[_0x140185('0x152a')]());});function _0x511200(_0x1d9b9b){const _0xe95320=_0x2a6a62;_0x5a4ea8[_0xe95320('0x240f')]=_0x1d9b9b[_0xe95320('0x240f')],_0x5a4ea8[_0xe95320('0x7a7')]=_0x1d9b9b?_0x2cfb05()['keyBy'](_0x1d9b9b[_0xe95320('0x269a')]?_0x1d9b9b[_0xe95320('0x269a')]:[],'id'):{};if(_0x1d9b9b[_0xe95320('0x269a')]){_0x5a4ea8[_0xe95320('0xa99')]=[];for(let _0x5aed92=0x0;_0x5aed92<_0x1d9b9b[_0xe95320('0x269a')][_0xe95320('0x264b')];_0x5aed92++){_0x5a4ea8[_0xe95320('0xa99')][_0xe95320('0x1514')](_0x1d9b9b[_0xe95320('0x269a')][_0x5aed92]['id']);}}_0x11cc46();}function _0x47d4c4(){const _0x26d30e=_0x2a6a62;_0x5a4ea8['query'][_0x26d30e('0x1098')]=(_0x5a4ea8[_0x26d30e('0x2218')]['page']-0x1)*_0x5a4ea8[_0x26d30e('0x2218')][_0x26d30e('0x163f')],_0x4cb312[_0x26d30e('0x1ac6')](_0x26d30e('0xa7c'))?_0x5a4ea8[_0x26d30e('0x1f48')]=_0x168940[_0x26d30e('0x262f')][_0x26d30e('0xd83')](_0x5a4ea8[_0x26d30e('0x2218')],_0x511200)[_0x26d30e('0xa44')]:(_0x5a4ea8['query']['id']=_0x5a4ea8[_0x26d30e('0x7f')]['id'],_0x5a4ea8['query'][_0x26d30e('0xe60')]=_0x26d30e('0x1eb3'),_0x5a4ea8[_0x26d30e('0x1f48')]=_0x168940[_0x26d30e('0x7f')]['getResources'](_0x5a4ea8[_0x26d30e('0x2218')],_0x511200)['$promise']);}function _0x53ebf7(_0x39d0a8,_0x1cb4e5){const _0x4a1b57=_0x2a6a62;_0x5e68d3['show']({'controller':_0x4a1b57('0x1364'),'controllerAs':'vm','templateUrl':_0x40072f,'parent':angular[_0x4a1b57('0x1194')](_0x16b8f0[_0x4a1b57('0x8d2')]),'targetEvent':_0x39d0a8,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x1cb4e5,'openchannelQueues':_0x2cfb05()[_0x4a1b57('0x1ac1')](_0x5a4ea8['queues']),'license':null,'setting':null,'crudPermissions':_0x5a4ea8[_0x4a1b57('0x243c')]}});}function _0x22933d(_0x159649,_0x396e0e){const _0xf32901=_0x2a6a62;_0x5e68d3[_0xf32901('0x1f80')]({'controller':_0xf32901('0x184a'),'controllerAs':'vm','templateUrl':_0xd7ba85,'parent':angular['element'](_0x16b8f0['body']),'targetEvent':_0x159649,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x396e0e,'openchannelQueues':_0x5a4ea8[_0xf32901('0x7a7')]?_0x5a4ea8['queues'][_0xf32901('0x269a')]:[],'realtime':![],'crudPermissions':_0x5a4ea8[_0xf32901('0x243c')]}});}function _0x396f7a(_0x6e70d3){const _0x18ca78=_0x2a6a62;return _0x168940['openchannelQueue'][_0x18ca78('0x1449')](_0x6e70d3)[_0x18ca78('0xa44')]['then'](function(){const _0x4ee599=_0x18ca78;_0x600111[_0x4ee599('0x103b')]({'title':_0x4ee599('0x75b'),'msg':_0x6e70d3[_0x4ee599('0x4f0')]?_0x6e70d3[_0x4ee599('0x4f0')]+_0x4ee599('0xa17'):''});})[_0x18ca78('0x1a80')](function(_0x15674d){const _0xf37f2e=_0x18ca78;_0x600111[_0xf37f2e('0xfc9')]({'title':_0xf37f2e('0xa98'),'msg':_0x15674d[_0xf37f2e('0x1e70')]});});}_0x5383c2[_0x2a6a62('0x3d2')](_0x2a6a62('0x1c3f'),function(){const _0x19c621=_0x2a6a62;_0x2646cc['removeAllListeners']('openchannel_queue:save'),_0x2646cc[_0x19c621('0x1800')](_0x19c621('0x1f45')),_0x2646cc[_0x19c621('0x1800')](_0x19c621('0x1523')),_0x2646cc['removeAllListeners'](_0x19c621('0x19d5')),_0x2646cc[_0x19c621('0x1800')](_0x19c621('0x25f0')),_0x2646cc['removeAllListeners']('userVoiceQueue:save');});}const _0x16d23e=_0x218109;function _0x497ca1(){const _0x76d699=_0x36e6f4;return{'status':{'registered':_0x76d699('0x23ca'),'unregistered':_0x76d699('0x278f'),'lagged':'red-300-fg\x20icon-close-circle','reachable':_0x76d699('0x23ca'),'unreachable':_0x76d699('0x278f'),'unknown':'grey-fg\x20icon-minus-circle'},'state':{'unknown':_0x76d699('0x1d48'),'not_inuse':'green-300-fg\x20icon-phone-hangup','inuse':_0x76d699('0xa2f'),'busy':'red-300-fg\x20icon-phone-locked','invalid':_0x76d699('0x1d48'),'unavailable':_0x76d699('0x1d48'),'ringing':_0x76d699('0x132c'),'ringinuse':'blue-300-fg\x20icon-phone-incoming','onhold':_0x76d699('0x23d9')},'channelStatus':{'ring':'blue-300-fg\x20icon-phone-incoming','up':'green-300-fg\x20icon-phone-in-talk','hangup':_0x76d699('0x9e3')},'channelStatusOut':{'ring':_0x76d699('0xac'),'up':'green-300-fg\x20icon-phone-in-talk','hangup':_0x76d699('0x9e3')}};}const _0x485410=_0x497ca1;_0x18352a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x2661')];function _0x18352a(_0x30718a,_0x7fb6d4,_0x5723d2){const _0x56f0b9=_0x36e6f4,_0x100105=this;_0x5723d2['disconnect'](),_0x5723d2[_0x56f0b9('0x7bb')](),_0x100105[_0x56f0b9('0x2669')]=0x0;switch(_0x7fb6d4[_0x56f0b9('0x22b5')][_0x56f0b9('0x4f0')]){case _0x56f0b9('0x1d43'):_0x100105['selectedTab']=0x0;break;case'app.openchannel.realtime.queues':_0x100105[_0x56f0b9('0x2669')]=0x1;break;default:_0x100105[_0x56f0b9('0x2669')]=0x0,_0x7fb6d4['go'](_0x56f0b9('0x1d43'));}_0x30718a[_0x56f0b9('0xe83')]('vm.selectedTab',function(_0x2b73a1,_0x1db9f2){const _0x5b96be=_0x56f0b9;if(_0x2b73a1!==_0x1db9f2)switch(_0x2b73a1){case 0x0:_0x7fb6d4['go']('app.openchannel.realtime.agents');break;case 0x1:_0x7fb6d4['go'](_0x5b96be('0x1668'));break;default:_0x7fb6d4['go'](_0x5b96be('0x1d43'));}});}const _0x130a5b=_0x18352a;_0xbb01e4[_0x36e6f4('0x1294')]=['$stateProvider'];function _0xbb01e4(_0x44dbec){const _0x1b24e5=_0x36e6f4;_0x44dbec['state'](_0x1b24e5('0x218c'),{'url':_0x1b24e5('0x1c2e'),'views':{'content@app':{'templateUrl':_0x3c0c38,'controller':'OpenchannelRealtimeController\x20as\x20vm'}},'resolve':{'userProfile':['apiResolver',_0x1b24e5('0x21ef'),function(_0x4416cc,_0x4133fe){const _0x148d5b=_0x1b24e5;return _0x4133fe[_0x148d5b('0x1ac6')](_0x148d5b('0xa7c'))?null:_0x4416cc['resolve'](_0x148d5b('0x697'),{'fields':'id,name,crudPermissions','id':_0x4133fe[_0x148d5b('0x26cd')]()[_0x148d5b('0xb86')]});}],'userProfileSection':[_0x1b24e5('0x1fbc'),'Auth',function(_0x591c62,_0x86172a){const _0xdf8ae7=_0x1b24e5;return _0x86172a[_0xdf8ae7('0x1ac6')]('admin')?null:_0x591c62[_0xdf8ae7('0x18af')](_0xdf8ae7('0xaf'),{'fields':_0xdf8ae7('0xe26'),'userProfileId':_0x86172a[_0xdf8ae7('0x26cd')]()['userProfileId'],'sectionId':0x32a});}]},'authenticate':!![],'permissionId':0x32a})[_0x1b24e5('0x63f')]('app.openchannel.realtime.agents',{'url':_0x1b24e5('0x730'),'controller':_0x1b24e5('0x11b9'),'templateUrl':_0x39a098,'resolve':{'pauses':[_0x1b24e5('0x1fbc'),function(_0x157b3c){return _0x157b3c['resolve']('pause@get',{'nolimit':!![]});}],'agents':[_0x1b24e5('0x1fbc'),_0x1b24e5('0x21ef'),function(_0x302852,_0x59585a){const _0x3439c9=_0x1b24e5;return _0x59585a['hasRole'](_0x3439c9('0xa7c'))?_0x302852[_0x3439c9('0x18af')](_0x3439c9('0x1c80'),{'fields':_0x3439c9('0x1746'),'role':_0x3439c9('0x1eff'),'sort':'fullname','nolimit':!![]}):_0x302852[_0x3439c9('0x18af')](_0x3439c9('0x17c4'),{'id':_0x59585a['getCurrentUser']()[_0x3439c9('0xb86')],'section':_0x3439c9('0x2391'),'fields':_0x3439c9('0x1746'),'role':_0x3439c9('0x1eff'),'sort':_0x3439c9('0x6e1'),'nolimit':!![]});}],'userProfile':[_0x1b24e5('0x1fbc'),'Auth',function(_0x2498f9,_0x1b0854){const _0x36850f=_0x1b24e5;return _0x1b0854[_0x36850f('0x1ac6')](_0x36850f('0xa7c'))?null:_0x2498f9[_0x36850f('0x18af')](_0x36850f('0x697'),{'fields':'id,name,crudPermissions','id':_0x1b0854[_0x36850f('0x26cd')]()[_0x36850f('0xb86')]});}],'userProfileSection':[_0x1b24e5('0x1fbc'),_0x1b24e5('0x21ef'),function(_0x287624,_0x269824){const _0x562948=_0x1b24e5;return _0x269824[_0x562948('0x1ac6')]('admin')?null:_0x287624[_0x562948('0x18af')](_0x562948('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x269824['getCurrentUser']()[_0x562948('0xb86')],'sectionId':0xca});}],'rpcAgents':['apiResolver',function(_0x5e3cc1){const _0x2d49b7=_0x1b24e5;return _0x5e3cc1[_0x2d49b7('0x18af')](_0x2d49b7('0xfab'));}]},'authenticate':!![],'permissionId':0x32a})[_0x1b24e5('0x63f')](_0x1b24e5('0x1668'),{'url':_0x1b24e5('0x1bd2'),'controller':'QueuesOpenchannelRealtimeController\x20as\x20vm','templateUrl':_0x1b872e,'resolve':{'queues':['apiResolver','Auth',function(_0x15e980,_0x45ebb2){const _0x4ac049=_0x1b24e5;return _0x45ebb2[_0x4ac049('0x1ac6')](_0x4ac049('0xa7c'))?_0x15e980[_0x4ac049('0x18af')](_0x4ac049('0x4a3'),{'type':_0x4ac049('0x14d8'),'sort':_0x4ac049('0x14dc'),'limit':0xa,'offset':0x0}):_0x15e980[_0x4ac049('0x18af')]('userProfile@getResources',{'id':_0x45ebb2[_0x4ac049('0x26cd')]()[_0x4ac049('0xb86')],'section':_0x4ac049('0x1eb3'),'channel':'openchannel','type':_0x4ac049('0x14d8'),'sort':_0x4ac049('0x14dc'),'limit':0xa,'page':0x1});}],'userProfile':['apiResolver',_0x1b24e5('0x21ef'),function(_0x2e4c95,_0x1c3859){const _0x31390c=_0x1b24e5;return _0x1c3859[_0x31390c('0x1ac6')](_0x31390c('0xa7c'))?null:_0x2e4c95['resolve'](_0x31390c('0x697'),{'fields':_0x31390c('0x686'),'id':_0x1c3859[_0x31390c('0x26cd')]()[_0x31390c('0xb86')]});}],'userProfileSection':['apiResolver','Auth',function(_0x5cf5d6,_0x705f66){const _0x45d6c3=_0x1b24e5;return _0x705f66[_0x45d6c3('0x1ac6')]('admin')?null:_0x5cf5d6[_0x45d6c3('0x18af')](_0x45d6c3('0xaf'),{'fields':_0x45d6c3('0xe26'),'userProfileId':_0x705f66['getCurrentUser']()[_0x45d6c3('0xb86')],'sectionId':0x321});}],'rpcQueues':[_0x1b24e5('0x1fbc'),function(_0x227508){const _0x591297=_0x1b24e5;return _0x227508[_0x591297('0x18af')](_0x591297('0x1b0'));}]},'authenticate':!![],'permissionId':0x32a});}angular['module'](_0x36e6f4('0x218c'),[])[_0x36e6f4('0xe11')](_0xbb01e4)[_0x36e6f4('0x75e')](_0x36e6f4('0x12a'),_0x12267d)[_0x36e6f4('0x75e')](_0x36e6f4('0x2393'),_0x16d23e)[_0x36e6f4('0x87c')]('helperClasses',_0x485410)[_0x36e6f4('0x75e')](_0x36e6f4('0xedd'),_0x130a5b);const _0x2743dc=_0x2734b2['p']+'src/js/modules/main/apps/openchannel/views/openchannelQueues/openchannelQueues.html/openchannelQueues.html',_0x24ba96=_0x2734b2['p']+_0x36e6f4('0x213'),_0x23bd77=_0x2734b2['p']+_0x36e6f4('0x20d5'),_0x4d28d1=_0x2734b2['p']+_0x36e6f4('0x1823');_0x373915[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q','$translate','toasty',_0x36e6f4('0x28ff'),_0x36e6f4('0x77f'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'crudPermissions'];function _0x373915(_0x21eb98,_0x805700,_0x3145ad,_0x17bcdb,_0x40b5bc,_0x2abb3f,_0x434b1a,_0x4a05ef,_0x38e93f,_0x203af5,_0x3dee8e,_0x96f301,_0x3eb012,_0x5d3ad4){const _0x242448=_0x36e6f4,_0x3b7eb0=this;_0x3b7eb0['currentUser']=_0x3dee8e[_0x242448('0x26cd')](),_0x3b7eb0[_0x242448('0x61a')]=[],_0x3b7eb0[_0x242448('0xf8a')]=_0x3eb012,_0x3b7eb0['license']=_0x96f301,_0x3b7eb0[_0x242448('0x243c')]=_0x5d3ad4,_0x3b7eb0[_0x242448('0x128b')]={},_0x3b7eb0['passwordPattern']=_0x3b7eb0[_0x242448('0xf8a')]&&_0x3b7eb0[_0x242448('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3b7eb0[_0x242448('0xcdc')]=_0x242448('0x480'),_0x3b7eb0['openchannelAccount']=angular[_0x242448('0x225f')](_0x38e93f),_0x3b7eb0[_0x242448('0x28ff')]=_0x4a05ef,_0x3b7eb0[_0x242448('0x241a')]=![];!_0x3b7eb0[_0x242448('0x77f')]&&(_0x3b7eb0[_0x242448('0x77f')]={'waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0x3b7eb0[_0x242448('0xcdc')]='OPENCHANNEL.NEW_OPENCHANNELACCOUNT',_0x3b7eb0[_0x242448('0x241a')]=!![]);_0x805700['params']['id']&&(_0x3b7eb0[_0x242448('0x77f')]['OpenchannelAccountId']=_0x805700[_0x242448('0x23f')]['id']);_0x3b7eb0[_0x242448('0x96e')]=_0x4c4ccc,_0x3b7eb0[_0x242448('0x21b2')]=_0x3a55aa,_0x3b7eb0[_0x242448('0x1a90')]=_0x58a98e,_0x3b7eb0[_0x242448('0x1a9c')]=_0x143c9f,_0x3b7eb0['closeDialog']=_0x23e145,_0x3dee8e[_0x242448('0x1ac6')]('admin')?_0x203af5[_0x242448('0xdd9')][_0x242448('0xd83')]({'fields':_0x242448('0x1776'),'sort':_0x242448('0x4f0')})[_0x242448('0xa44')]['then'](function(_0x967098){_0x3b7eb0['lists']=_0x967098['rows']||[];})[_0x242448('0x1a80')](function(_0x19ac30){const _0x109640=_0x242448;_0x434b1a['error']({'title':_0x19ac30[_0x109640('0x52d')]?_0x109640('0x1e21')+_0x19ac30['status']+_0x109640('0x11e1')+_0x19ac30['statusText']:_0x109640('0x520'),'msg':_0x19ac30[_0x109640('0x25f4')]?JSON['stringify'](_0x19ac30[_0x109640('0x25f4')]):_0x19ac30['toString']()});}):_0x203af5[_0x242448('0xdd9')][_0x242448('0xd83')]({'fields':'id,name','sort':_0x242448('0x4f0')})['$promise']['then'](function(_0x488ab3){const _0x3ea030=_0x242448;_0x3b7eb0[_0x3ea030('0x8de')]=_0x488ab3['rows']||[];})[_0x242448('0x1166')](function(){const _0x82d177=_0x242448;return _0x203af5[_0x82d177('0x17aa')]['get']({'userProfileId':_0x3b7eb0[_0x82d177('0x98')]['userProfileId'],'sectionId':0x12d})[_0x82d177('0xa44')];})[_0x242448('0x1166')](function(_0x218184){const _0x25ae82=_0x242448,_0x4b9fe5=_0x218184&&_0x218184[_0x25ae82('0x269a')]?_0x218184[_0x25ae82('0x269a')][0x0]:null;if(!_0x4b9fe5){const _0x53bdfd=[];let _0x57b1a0=null;_0x3b7eb0[_0x25ae82('0x77f')]&&(_0x57b1a0=_0x2cfb05()[_0x25ae82('0xc38')](_0x3b7eb0[_0x25ae82('0x8de')],{'id':Number(_0x3b7eb0[_0x25ae82('0x77f')]['ListId'])}));for(let _0x110668=0x0;_0x110668<_0x3b7eb0['lists'][_0x25ae82('0x264b')];_0x110668++){_0x57b1a0&&_0x3b7eb0[_0x25ae82('0x8de')][_0x110668]['id']===_0x57b1a0['id']&&(_0x3b7eb0[_0x25ae82('0x8de')][_0x110668]['canSelect']=![],_0x53bdfd[_0x25ae82('0x1514')](_0x3b7eb0[_0x25ae82('0x8de')][_0x110668]));}_0x3b7eb0['lists']=_0x53bdfd;}else{if(!_0x4b9fe5[_0x25ae82('0x1a2b')])return _0x203af5['userProfileResource']['get']({'sectionId':_0x4b9fe5['id']})[_0x25ae82('0xa44')]['then'](function(_0x2cf1ca){const _0x232ad8=_0x25ae82,_0x409e18=_0x2cfb05()[_0x232ad8('0x2563')](_0x2cf1ca[_0x232ad8('0x269a')],function(_0x4c9867){const _0x5bf375=_0x232ad8;return _0x2cfb05()[_0x5bf375('0xc38')](_0x3b7eb0[_0x5bf375('0x8de')],{'id':_0x4c9867[_0x5bf375('0x24e8')]});});let _0x4e4e44=null;_0x3b7eb0[_0x232ad8('0x77f')]&&(_0x4e4e44=_0x2cfb05()['find'](_0x3b7eb0[_0x232ad8('0x8de')],{'id':Number(_0x3b7eb0[_0x232ad8('0x77f')][_0x232ad8('0x23c')])}));if(_0x4e4e44&&!_0x2cfb05()[_0x232ad8('0x1798')](_0x409e18,['id',_0x4e4e44['id']])){const _0x469413=_0x2cfb05()['find'](_0x3b7eb0[_0x232ad8('0x8de')],{'id':_0x4e4e44['id']});_0x469413[_0x232ad8('0x2378')]=![],_0x409e18[_0x232ad8('0x1514')](_0x469413);}_0x3b7eb0['lists']=_0x409e18;});}})[_0x242448('0x1a80')](function(_0x570a4f){const _0x59bb09=_0x242448;_0x434b1a[_0x59bb09('0xfc9')]({'title':_0x570a4f[_0x59bb09('0x52d')]?'API:'+_0x570a4f[_0x59bb09('0x52d')]+'\x20-\x20'+_0x570a4f[_0x59bb09('0xe1b')]:_0x59bb09('0x1248'),'msg':_0x570a4f['data']?JSON[_0x59bb09('0xbac')](_0x570a4f[_0x59bb09('0x25f4')]):_0x570a4f[_0x59bb09('0x1586')]()});});function _0x4c4ccc(){const _0x4d54fd=_0x242448;_0x3b7eb0[_0x4d54fd('0x61a')]=[],_0x203af5[_0x4d54fd('0x77f')]['save'](_0x3b7eb0['openchannelAccount'])[_0x4d54fd('0xa44')][_0x4d54fd('0x1166')](function(_0xa8f972){const _0x590e49=_0x4d54fd;_0x3b7eb0[_0x590e49('0x28ff')][_0x590e49('0x2450')](_0xa8f972[_0x590e49('0x2876')]()),_0x434b1a[_0x590e49('0x103b')]({'title':_0x590e49('0x13b'),'msg':_0x3b7eb0[_0x590e49('0x77f')][_0x590e49('0x4f0')]?_0x3b7eb0['openchannelAccount'][_0x590e49('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x23e145(_0xa8f972);})[_0x4d54fd('0x1a80')](function(_0x4c3383){const _0x280fe1=_0x4d54fd;if(_0x4c3383[_0x280fe1('0x25f4')]&&_0x4c3383['data'][_0x280fe1('0x61a')]&&_0x4c3383[_0x280fe1('0x25f4')][_0x280fe1('0x61a')][_0x280fe1('0x264b')]){_0x3b7eb0[_0x280fe1('0x61a')]=_0x4c3383[_0x280fe1('0x25f4')][_0x280fe1('0x61a')]||[{'message':_0x4c3383[_0x280fe1('0x1586')](),'type':_0x280fe1('0x5e6')}];for(let _0x594f51=0x0;_0x594f51<_0x4c3383[_0x280fe1('0x25f4')][_0x280fe1('0x61a')][_0x280fe1('0x264b')];_0x594f51+=0x1){_0x434b1a[_0x280fe1('0xfc9')]({'title':_0x4c3383[_0x280fe1('0x25f4')]['errors'][_0x594f51][_0x280fe1('0x1345')],'msg':_0x4c3383['data'][_0x280fe1('0x61a')][_0x594f51][_0x280fe1('0x1e70')]});}}else _0x434b1a[_0x280fe1('0xfc9')]({'title':_0x4c3383[_0x280fe1('0x52d')]?_0x280fe1('0x1e21')+_0x4c3383['status']+'\x20-\x20'+_0x4c3383[_0x280fe1('0xe1b')]:'api.openchannelAccount.save','msg':_0x4c3383['data']?JSON[_0x280fe1('0xbac')](_0x4c3383['data'][_0x280fe1('0x1e70')]):_0x4c3383[_0x280fe1('0x1586')]()});});}function _0x3a55aa(){const _0x4ee654=_0x242448;_0x3b7eb0['errors']=[],_0x203af5[_0x4ee654('0x77f')][_0x4ee654('0x1449')]({'id':_0x3b7eb0[_0x4ee654('0x77f')]['id']},_0x3b7eb0[_0x4ee654('0x77f')])[_0x4ee654('0xa44')][_0x4ee654('0x1166')](function(_0x4f06df){const _0x466af8=_0x4ee654,_0x2ad5d9=_0x2cfb05()['find'](_0x3b7eb0[_0x466af8('0x28ff')],{'id':_0x4f06df['id']});_0x2ad5d9&&_0x2cfb05()[_0x466af8('0xcc3')](_0x2ad5d9,_0x2cfb05()[_0x466af8('0x1a08')](_0x4f06df[_0x466af8('0x2876')](),_0x2cfb05()[_0x466af8('0x14a4')](_0x2ad5d9))),_0x434b1a['success']({'title':_0x466af8('0x1cd8'),'msg':_0x3b7eb0['openchannelAccount'][_0x466af8('0x4f0')]?_0x3b7eb0[_0x466af8('0x77f')]['name']+_0x466af8('0x7d'):''}),_0x23e145(_0x4f06df);})[_0x4ee654('0x1a80')](function(_0x49da91){const _0x18f003=_0x4ee654;if(_0x49da91[_0x18f003('0x25f4')]&&_0x49da91[_0x18f003('0x25f4')]['errors']&&_0x49da91[_0x18f003('0x25f4')][_0x18f003('0x61a')][_0x18f003('0x264b')]){_0x3b7eb0[_0x18f003('0x61a')]=_0x49da91[_0x18f003('0x25f4')]['errors']||[{'message':_0x49da91[_0x18f003('0x1586')](),'type':'api.openchannelAccount.update'}];for(let _0x539895=0x0;_0x539895<_0x49da91[_0x18f003('0x25f4')]['errors'][_0x18f003('0x264b')];_0x539895++){_0x434b1a[_0x18f003('0xfc9')]({'title':_0x49da91[_0x18f003('0x25f4')][_0x18f003('0x61a')][_0x539895][_0x18f003('0x1345')],'msg':_0x49da91[_0x18f003('0x25f4')][_0x18f003('0x61a')][_0x539895]['message']});}}else _0x434b1a[_0x18f003('0xfc9')]({'title':_0x49da91[_0x18f003('0x52d')]?_0x18f003('0x1e21')+_0x49da91[_0x18f003('0x52d')]+_0x18f003('0x11e1')+_0x49da91[_0x18f003('0xe1b')]:'api.openchannelAccount.update','msg':_0x49da91['data']?JSON['stringify'](_0x49da91[_0x18f003('0x25f4')]['message']):_0x49da91[_0x18f003('0x1586')]()});});}function _0x58a98e(_0xa578d2){const _0x3988c=_0x242448;_0x3b7eb0[_0x3988c('0x61a')]=[];const _0x1cf742=_0x17bcdb[_0x3988c('0x1d26')]()[_0x3988c('0xcdc')](_0x3988c('0x7fb'))[_0x3988c('0xacc')](_0x3988c('0x15c9'))[_0x3988c('0x8e8')]('Delete\x20OpenchannelAccount')['ok'](_0x3988c('0x18'))[_0x3988c('0x3f')](_0x3988c('0x497'))[_0x3988c('0x203b')](_0xa578d2);_0x17bcdb[_0x3988c('0x1f80')](_0x1cf742)['then'](function(){const _0x1ee0d4=_0x3988c;_0x203af5[_0x1ee0d4('0x77f')][_0x1ee0d4('0x906')]({'id':_0x3b7eb0['openchannelAccount']['id']})[_0x1ee0d4('0xa44')]['then'](function(){const _0x4a5e1b=_0x1ee0d4;_0x2cfb05()[_0x4a5e1b('0x127f')](_0x3b7eb0['openchannelAccounts'],{'id':_0x3b7eb0['openchannelAccount']['id']}),_0x434b1a[_0x4a5e1b('0x103b')]({'title':'OpenchannelAccount\x20properly\x20deleted!','msg':(_0x3b7eb0[_0x4a5e1b('0x77f')][_0x4a5e1b('0x4f0')]||'openchannelAccount')+'\x20has\x20been\x20deleted!'}),_0x23e145(_0x3b7eb0[_0x4a5e1b('0x77f')]);})[_0x1ee0d4('0x1a80')](function(_0x4b4689){const _0xf9826f=_0x1ee0d4;if(_0x4b4689[_0xf9826f('0x25f4')]&&_0x4b4689['data'][_0xf9826f('0x61a')]&&_0x4b4689['data'][_0xf9826f('0x61a')][_0xf9826f('0x264b')]){_0x3b7eb0[_0xf9826f('0x61a')]=_0x4b4689[_0xf9826f('0x25f4')][_0xf9826f('0x61a')]||[{'message':_0x4b4689['toString'](),'type':'api.openchannelAccount.delete'}];for(let _0x3fc110=0x0;_0x3fc110<_0x4b4689[_0xf9826f('0x25f4')][_0xf9826f('0x61a')][_0xf9826f('0x264b')];_0x3fc110++){_0x434b1a['error']({'title':_0x4b4689[_0xf9826f('0x25f4')][_0xf9826f('0x61a')][_0x3fc110][_0xf9826f('0x1345')],'msg':_0x4b4689[_0xf9826f('0x25f4')][_0xf9826f('0x61a')][_0x3fc110][_0xf9826f('0x1e70')]});}}else _0x434b1a[_0xf9826f('0xfc9')]({'title':_0x4b4689[_0xf9826f('0x52d')]?_0xf9826f('0x1e21')+_0x4b4689[_0xf9826f('0x52d')]+_0xf9826f('0x11e1')+_0x4b4689[_0xf9826f('0xe1b')]:_0xf9826f('0x1c38'),'msg':_0x4b4689['data']?JSON[_0xf9826f('0xbac')](_0x4b4689[_0xf9826f('0x25f4')][_0xf9826f('0x1e70')]):_0x4b4689[_0xf9826f('0x1e70')]||_0x4b4689[_0xf9826f('0x1586')]()});});},function(){});}function _0x143c9f(_0x491ce4){return _0x491ce4===null?undefined:new Date(_0x491ce4);}function _0x23e145(_0x104794){const _0x24d02d=_0x242448;_0x17bcdb[_0x24d02d('0x1197')](_0x104794);}}const _0x8d7399=_0x373915,_0x5c2212=_0x2734b2['p']+_0x36e6f4('0xe53'),_0x3f7139=_0x2734b2['p']+_0x36e6f4('0x11c5'),_0x2e3d2c=_0x2734b2['p']+_0x36e6f4('0x72a'),_0x2cf652=_0x2734b2['p']+_0x36e6f4('0x1aab'),_0x519971=_0x2734b2['p']+_0x36e6f4('0x1bf1'),_0x31ca62=_0x2734b2['p']+_0x36e6f4('0xed7'),_0x24de34=_0x2734b2['p']+_0x36e6f4('0x53f'),_0x412e7a=_0x2734b2['p']+_0x36e6f4('0x9c3'),_0x104256=_0x2734b2['p']+_0x36e6f4('0x15b3'),_0x113da7=_0x2734b2['p']+_0x36e6f4('0x15a9');_0x11d721[_0x36e6f4('0x1294')]=[_0x36e6f4('0x19e3'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x1d2e'),'Auth'];const _0x34696a={'agent':_0x5c2212,'autoreply':_0x3f7139,'close':_0x2e3d2c,'gotoif':_0x2cf652,'gotop':_0x519971,'interval':_0x31ca62,'noop':_0x24de34,'queue':_0x412e7a,'system':_0x104256,'tag':_0x113da7};function _0x11d721(_0x24c392,_0x1d29e4,_0x1b61b2,_0x38f589,_0x598424){const _0x4da3d6=_0x36e6f4,_0x3910fb=this;_0x3910fb[_0x4da3d6('0x98')]=_0x598424[_0x4da3d6('0x26cd')](),_0x3910fb[_0x4da3d6('0x77f')]={},_0x3910fb['openchannelAccountApps']={'count':0x0,'rows':[]},_0x3910fb[_0x4da3d6('0x4ef')]=[],_0x3910fb[_0x4da3d6('0x243c')],_0x3910fb[_0x4da3d6('0x2218')]={'sort':_0x4da3d6('0xfde')},_0x3910fb[_0x4da3d6('0x24d2')]=_0x2cfb05()[_0x4da3d6('0x21bf')](_0x2cfb05()[_0x4da3d6('0x1eba')]([{'app':_0x4da3d6('0xded'),'appType':_0x4da3d6('0xded'),'type':_0x4da3d6('0xded'),'icon':'icon-apps','interval':_0x4da3d6('0x16f'),'isApp':!![],'fields':[{'title':_0x4da3d6('0x2eb'),'name':_0x4da3d6('0x7ca'),'type':_0x4da3d6('0x1640'),'required':!![],'param':0x0},{'title':_0x4da3d6('0xedb'),'name':_0x4da3d6('0xedb'),'type':'select','defaultValue':_0x4da3d6('0x17bf'),'values':[{'option':'Danish','value':_0x4da3d6('0xacf')},{'option':_0x4da3d6('0x1852'),'value':_0x4da3d6('0x17bf')},{'option':_0x4da3d6('0x20f'),'value':'\x27de\x27'},{'option':_0x4da3d6('0x1a40'),'value':_0x4da3d6('0x1dd3')},{'option':'Spanish','value':_0x4da3d6('0x14d0')},{'option':_0x4da3d6('0x2746'),'value':_0x4da3d6('0x5f0')},{'option':_0x4da3d6('0xebe'),'value':_0x4da3d6('0x2872')},{'option':_0x4da3d6('0x2688'),'value':'\x27ja\x27'},{'option':'Korean\x20(South\x20Korea)','value':'\x27ko\x27'},{'option':'Dutch','value':_0x4da3d6('0x4f5')},{'option':_0x4da3d6('0x522'),'value':_0x4da3d6('0x119b')},{'option':_0x4da3d6('0x0'),'value':_0x4da3d6('0x145d')},{'option':_0x4da3d6('0x2528'),'value':_0x4da3d6('0x1136')},{'option':'Russian','value':_0x4da3d6('0x543')},{'option':_0x4da3d6('0x277e'),'value':'\x27sv\x27'},{'option':_0x4da3d6('0x24f9'),'value':'\x27th\x27'},{'option':'Ukrainian','value':_0x4da3d6('0x38e')},{'option':_0x4da3d6('0xefc'),'value':_0x4da3d6('0x244a')},{'option':_0x4da3d6('0x8d9'),'value':_0x4da3d6('0x21c7')},{'option':_0x4da3d6('0x145a'),'value':_0x4da3d6('0x2348')}],'required':!![],'param':0x1},{'title':_0x4da3d6('0x1634'),'name':_0x4da3d6('0x1634'),'type':'textarea','maxlength':0xff,'required':![],'param':0x2,'help':!![]}]},{'app':_0x4da3d6('0x12fa'),'appType':_0x4da3d6('0x1636'),'type':'dialogflowv2','icon':_0x4da3d6('0x283f'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x4da3d6('0x23'),'name':_0x4da3d6('0x1b0a'),'type':_0x4da3d6('0x1640'),'required':!![],'param':0x0},{'title':_0x4da3d6('0x23e3'),'name':_0x4da3d6('0x27f3'),'type':_0x4da3d6('0x1640'),'required':!![],'param':0x1},{'title':_0x4da3d6('0x17dd'),'name':_0x4da3d6('0x170e'),'type':_0x4da3d6('0x489'),'required':!![],'param':0x2},{'title':'language','name':_0x4da3d6('0xedb'),'type':_0x4da3d6('0x88a'),'defaultValue':_0x4da3d6('0x17bf'),'values':[{'value':_0x4da3d6('0x21c7'),'option':_0x4da3d6('0x2837')},{'value':_0x4da3d6('0x244a'),'option':'Chinese\x20(Simplified)'},{'value':'\x27zh-TW\x27','option':'Chinese\x20(Traditional)'},{'value':_0x4da3d6('0xacf'),'option':'Danish'},{'value':_0x4da3d6('0x4f5'),'option':_0x4da3d6('0x1025')},{'value':_0x4da3d6('0x17bf'),'option':_0x4da3d6('0x1852')},{'value':_0x4da3d6('0x457'),'option':_0x4da3d6('0x27a0')},{'value':_0x4da3d6('0x2270'),'option':_0x4da3d6('0x28b8')},{'value':_0x4da3d6('0x60d'),'option':_0x4da3d6('0x1cdd')},{'value':'\x27en-IN\x27','option':_0x4da3d6('0x655')},{'value':'\x27en-US\x27','option':_0x4da3d6('0x1f4')},{'value':_0x4da3d6('0x5f0'),'option':_0x4da3d6('0x2746')},{'value':_0x4da3d6('0x391'),'option':_0x4da3d6('0x19bd')},{'value':_0x4da3d6('0x1cb9'),'option':_0x4da3d6('0x18e4')},{'value':_0x4da3d6('0x15bd'),'option':'German'},{'value':_0x4da3d6('0x9bd'),'option':_0x4da3d6('0x473')},{'value':_0x4da3d6('0x2872'),'option':_0x4da3d6('0xebe')},{'value':_0x4da3d6('0x1dd3'),'option':_0x4da3d6('0x1a40')},{'value':'\x27ja\x27','option':_0x4da3d6('0x2688')},{'value':_0x4da3d6('0x82e'),'option':_0x4da3d6('0x511')},{'value':_0x4da3d6('0x119b'),'option':_0x4da3d6('0x522')},{'value':_0x4da3d6('0x27c'),'option':'Polish'},{'value':_0x4da3d6('0x271c'),'option':_0x4da3d6('0x702')},{'value':'\x27pt-PT\x27','option':_0x4da3d6('0x1336')},{'value':'\x27ru\x27','option':_0x4da3d6('0xf22')},{'value':_0x4da3d6('0x14d0'),'option':_0x4da3d6('0x2246')},{'value':_0x4da3d6('0x14e3'),'option':'Spanish\x20(Latin\x20America)'},{'value':'\x27es-ES\x27','option':_0x4da3d6('0x1f75')},{'value':_0x4da3d6('0x1ae8'),'option':_0x4da3d6('0x277e')},{'value':_0x4da3d6('0x1d2b'),'option':_0x4da3d6('0x24f9')},{'value':_0x4da3d6('0x1d58'),'option':_0x4da3d6('0x71a')},{'value':_0x4da3d6('0x38e'),'option':_0x4da3d6('0xd6b')}],'required':!![],'param':0x3},{'title':_0x4da3d6('0x1634'),'name':_0x4da3d6('0x1634'),'type':'textarea','maxlength':0xff,'param':0x4,'help':!![]}]},{'app':'amazonlex','appType':'amazonlex','type':'amazonlex','icon':'icon-apps','interval':_0x4da3d6('0x16f'),'isApp':!![],'fields':[{'title':_0x4da3d6('0xee6'),'name':_0x4da3d6('0xee6'),'type':'text','required':!![],'param':0x0},{'title':_0x4da3d6('0x125'),'name':_0x4da3d6('0x125'),'type':_0x4da3d6('0x1640'),'required':!![],'param':0x1},{'title':_0x4da3d6('0x25a2'),'name':_0x4da3d6('0x25a2'),'type':_0x4da3d6('0x88a'),'defaultValue':_0x4da3d6('0x2891'),'values':[{'option':_0x4da3d6('0xc64'),'value':_0x4da3d6('0x2891')},{'option':_0x4da3d6('0x1fbb'),'value':_0x4da3d6('0x27b2')},{'option':'EU\x20(Ireland)','value':_0x4da3d6('0x658')},{'option':_0x4da3d6('0xac9'),'value':_0x4da3d6('0xaed')}],'required':!![],'param':0x2},{'title':'botname','name':_0x4da3d6('0x1ac4'),'type':_0x4da3d6('0x1640'),'required':!![],'param':0x3},{'title':_0x4da3d6('0x1634'),'name':_0x4da3d6('0x1634'),'type':'textarea','maxlength':0xff,'required':![],'param':0x4,'help':!![]}]},{'app':_0x4da3d6('0x1545'),'appType':_0x4da3d6('0x277c'),'types':[_0x4da3d6('0x597'),_0x4da3d6('0x2853'),_0x4da3d6('0x1480')],'fields':[],'isApp':![]},{'app':_0x4da3d6('0x2652'),'appType':_0x4da3d6('0x2652'),'type':_0x4da3d6('0x2652'),'icon':_0x4da3d6('0x283f'),'interval':_0x4da3d6('0x16f'),'required':!![],'isApp':!![],'fields':[{'title':_0x4da3d6('0x1efa'),'name':_0x4da3d6('0x18e0'),'type':_0x4da3d6('0x1640'),'param':0x0}]},{'app':_0x4da3d6('0x1c2b'),'appType':'system','type':'system','icon':_0x4da3d6('0x283f'),'interval':_0x4da3d6('0x16f'),'required':!![],'isApp':!![],'extraApi':[{'name':_0x4da3d6('0x57a'),'field':{'name':_0x4da3d6('0x734'),'key':_0x4da3d6('0x4f0')},'route':_0x4da3d6('0x734'),'filters':{'fields':_0x4da3d6('0x1776'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':_0x4da3d6('0xd5'),'name':_0x4da3d6('0x187'),'type':_0x4da3d6('0x1640'),'required':!![],'param':0x0},{'title':_0x4da3d6('0x2d5'),'name':_0x4da3d6('0x734'),'type':_0x4da3d6('0x2550'),'values':_0x4da3d6('0x57a'),'value':_0x4da3d6('0x15f0'),'option':_0x4da3d6('0x15f0'),'defaultValues':[{'value':'\x27\x27','option':_0x4da3d6('0x1280')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':_0x4da3d6('0x6e6'),'appType':_0x4da3d6('0x6e6'),'type':'goto','icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x4da3d6('0x9c2'),'name':_0x4da3d6('0xfde'),'type':_0x4da3d6('0xc45'),'required':!![],'min':0x0,'param':0x0}]},{'app':_0x4da3d6('0x30f'),'appType':_0x4da3d6('0x30f'),'type':'gotoif','icon':'icon-apps','interval':_0x4da3d6('0x16f'),'isApp':!![],'fields':[{'title':'Condition','name':'condition','type':_0x4da3d6('0x1640'),'required':!![],'param':0x0},{'title':_0x4da3d6('0x13a6'),'name':_0x4da3d6('0x13a6'),'type':_0x4da3d6('0xc45'),'min':0x1,'required':!![],'param':0x1},{'title':'falsepriority','name':_0x4da3d6('0x1d7a'),'type':_0x4da3d6('0xc45'),'min':0x1,'required':!![],'param':0x2}]},{'app':_0x4da3d6('0x1d3e'),'appType':_0x4da3d6('0x1d3e'),'foreignKey':_0x4da3d6('0x27e0'),'type':'queue','icon':_0x4da3d6('0x283f'),'interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':'queues','field':{'name':_0x4da3d6('0x1d3e'),'key':_0x4da3d6('0x4f0')},'route':_0x4da3d6('0x262f'),'filters':{'fields':_0x4da3d6('0x1c09'),'sort':_0x4da3d6('0x4f0'),'nolimit':!![]},'permissions':{'section':0x321}}],'fields':[{'title':_0x4da3d6('0x28ba'),'name':_0x4da3d6('0x1d3e'),'type':_0x4da3d6('0x2550'),'values':_0x4da3d6('0x7a7'),'value':_0x4da3d6('0x24ad'),'option':_0x4da3d6('0x24ad'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':_0x4da3d6('0x1861'),'name':_0x4da3d6('0x651'),'type':'number','max':0x20c49b,'min':0x0,'defaultValue':0x12c,'required':!![],'param':0x1}]},{'app':'agent','appType':'agent','type':_0x4da3d6('0x1eff'),'foreignKey':_0x4da3d6('0x122a'),'icon':_0x4da3d6('0x283f'),'interval':_0x4da3d6('0x16f'),'isApp':!![],'extraApi':[{'name':_0x4da3d6('0x1f7e'),'field':{'name':'agent','key':_0x4da3d6('0x4f0')},'route':'user','filters':{'fields':'id,name','sort':'name','role':_0x4da3d6('0x1eff'),'nolimit':!![]},'permissions':{'section':0xca}}],'fields':[{'title':_0x4da3d6('0x89b'),'name':_0x4da3d6('0x1eff'),'type':_0x4da3d6('0x2550'),'values':_0x4da3d6('0x1f7e'),'value':_0x4da3d6('0x1530'),'option':_0x4da3d6('0x1530'),'required':!![],'param':0x0},{'title':_0x4da3d6('0x1861'),'name':'timeout','type':'number','max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':'autoreply','appType':_0x4da3d6('0x1af7'),'type':_0x4da3d6('0x1af7'),'icon':'icon-apps','interval':_0x4da3d6('0x16f'),'isApp':!![],'fields':[{'title':_0x4da3d6('0x265e'),'name':_0x4da3d6('0x265e'),'type':'select','defaultValue':'1','values':[{'option':'One\x20Time','value':'1'},{'option':_0x4da3d6('0x70f'),'value':'0'}],'required':!![],'param':0x0},{'title':'Text','name':_0x4da3d6('0x1640'),'type':_0x4da3d6('0x489'),'required':!![],'param':0x1}]},{'app':_0x4da3d6('0x1a7b'),'appType':_0x4da3d6('0x1a7b'),'type':_0x4da3d6('0x1a7b'),'icon':_0x4da3d6('0x283f'),'interval':_0x4da3d6('0x16f'),'isApp':!![],'fields':[{'title':_0x4da3d6('0x9b9'),'name':_0x4da3d6('0x12e8'),'type':_0x4da3d6('0x1640'),'required':!![],'param':0x0}]},{'app':_0x4da3d6('0x1446'),'appType':_0x4da3d6('0x1446'),'type':_0x4da3d6('0x1446'),'foreignKey':_0x4da3d6('0x8f5'),'icon':'icon-apps','interval':_0x4da3d6('0x16f'),'isApp':!![],'extraApi':[{'name':'tags','field':{'name':'tag','key':_0x4da3d6('0x4f0')},'route':'tag','filters':{'fields':_0x4da3d6('0x1776'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':'Tag','name':_0x4da3d6('0x1446'),'type':_0x4da3d6('0x2550'),'values':_0x4da3d6('0xb38'),'value':'tag.name','option':_0x4da3d6('0xc2c'),'required':!![],'param':0x0}]}],[_0x4da3d6('0x746')]),{'isApp':![]}),_0x3910fb[_0x4da3d6('0x1480')]={'group':{'name':_0x4da3d6('0x1b27'),'pull':'clone'},'animation':0x64,'sort':![]},_0x3910fb[_0x4da3d6('0x227f')]={'group':{'name':_0x4da3d6('0x103e'),'put':_0x4da3d6('0x1b27')},'animation':0x64,'onAdd':function(_0x52396c){const _0x2813f4=_0x4da3d6;_0x56f624(_0x52396c,_0x52396c[_0x2813f4('0x1313')]);},'onSort':function(){_0x12a69f();}},_0x3910fb[_0x4da3d6('0x24d5')]=_0xe924dd,_0x3910fb[_0x4da3d6('0x8a2')]=_0x4c9484,_0x3910fb[_0x4da3d6('0x413')]=_0x11d425,_0x3910fb['editOpenchannelAccountApp']=_0x56f624,_0x3910fb['editInterval']=_0x2b908a,_0x3910fb[_0x4da3d6('0x1f13')]=_0xba1200,_0x3910fb[_0x4da3d6('0xee5')]=_0x256c9f,_0x3910fb['rewriteRouting']=_0x12a69f,_0x3910fb[_0x4da3d6('0x242')]=_0x33de0f;function _0xe924dd(_0x1ab6f5,_0x1f1cf3){const _0x20ac21=_0x4da3d6;_0x3910fb[_0x20ac21('0x77f')]=_0x1ab6f5,_0x3910fb[_0x20ac21('0x243c')]=typeof _0x1f1cf3!==_0x20ac21('0x1048')?_0x1f1cf3:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3910fb[_0x20ac21('0x227f')][_0x20ac21('0xbd0')]=!_0x3910fb['crudPermissions']['canEdit']?!![]:![],_0x3910fb[_0x20ac21('0x2218')]['id']=_0x1ab6f5['id'],_0x3910fb[_0x20ac21('0x2218')][_0x20ac21('0x1a55')]=!![],_0x3910fb[_0x20ac21('0x2218')][_0x20ac21('0x49d')]=!![],_0x3910fb[_0x20ac21('0x413')](),_0x3910fb[_0x20ac21('0x242')]();}function _0x4c9484(_0x13b2a4,_0x17912a,_0x36307c){const _0x43e205=_0x4da3d6,_0x3daa56=_0x1d29e4['confirm']()[_0x43e205('0xcdc')](_0x43e205('0xd0f'))[_0x43e205('0xf3c')](_0x43e205('0x12b5')+_0x13b2a4[_0x43e205('0x746')]+''+_0x43e205('0x3f3'))[_0x43e205('0x8e8')]('delete\x20application')['targetEvent'](_0x36307c)['ok']('OK')[_0x43e205('0x3f')](_0x43e205('0x2d3'));_0x1d29e4['show'](_0x3daa56)[_0x43e205('0x1166')](function(){const _0x50bda2=_0x43e205;_0x3910fb[_0x50bda2('0xeda')]['rows']['splice'](_0x17912a,0x1),_0x12a69f();},function(){const _0x388946=_0x43e205;console[_0x388946('0x455')](_0x388946('0x2d3'));});}function _0x56f624(_0x488f5a,_0x113d22){const _0x1637f0=_0x4da3d6;if(_0x3910fb[_0x1637f0('0xeda')][_0x1637f0('0x269a')][_0x1637f0('0x264b')]){const _0x3beba6=_0x3910fb[_0x1637f0('0xeda')][_0x1637f0('0x269a')][_0x113d22]?_0x3910fb[_0x1637f0('0xeda')][_0x1637f0('0x269a')][_0x113d22]:_0x3910fb[_0x1637f0('0xeda')][_0x1637f0('0x269a')][0x0],_0x1399fb=(_0x3beba6[_0x1637f0('0x83f')]||_0x3beba6[_0x1637f0('0x746')])[_0x1637f0('0x2574')]();_0x1d29e4[_0x1637f0('0x1f80')]({'controller':_0x1637f0('0x20b')+_0x1399fb+'DialogController','controllerAs':'vm','templateUrl':_0x34696a[_0x1399fb],'parent':angular[_0x1637f0('0x1194')](_0x1b61b2[_0x1637f0('0x8d2')]),'targetEvent':_0x488f5a,'clickOutsideToClose':!![],'locals':{'openchannelAccountApp':_0x3beba6,'openchannelAccount':_0x3910fb[_0x1637f0('0x77f')],'crudPermissions':_0x3910fb[_0x1637f0('0x243c')]}})[_0x1637f0('0x1166')](function(_0x19e638){const _0x54b77f=_0x1637f0;_0x19e638&&(_0x19e638['id']?_0x3910fb[_0x54b77f('0xeda')][_0x54b77f('0x269a')][_0x113d22]=_0x19e638:_0x3910fb[_0x54b77f('0xeda')][_0x54b77f('0x269a')][_0x54b77f('0x57b')](_0x113d22,0x0,_0x19e638),_0x12a69f());})[_0x1637f0('0x1a80')](function(_0xeaee95){const _0x189f49=_0x1637f0;_0xeaee95&&_0x38f589[_0x189f49('0xfc9')]({'title':_0xeaee95[_0x189f49('0x52d')]?_0x189f49('0x1e21')+_0xeaee95['status']+'\x20-\x20'+_0xeaee95[_0x189f49('0xe1b')]:'SYSTEM:EDITMODALSHOW','msg':_0xeaee95[_0x189f49('0x25f4')]?JSON['stringify'](_0xeaee95[_0x189f49('0x25f4')]):_0xeaee95[_0x189f49('0x1586')]()});});}}function _0x2b908a(_0x17af33,_0x2152ce){const _0x2c74c9=_0x4da3d6;if(_0x3910fb[_0x2c74c9('0xeda')][_0x2c74c9('0x269a')][_0x2c74c9('0x264b')]){const _0xed0de9=_0x3910fb[_0x2c74c9('0xeda')]['rows'][_0x2152ce]?_0x3910fb[_0x2c74c9('0xeda')]['rows'][_0x2152ce]:_0x3910fb[_0x2c74c9('0xeda')][_0x2c74c9('0x269a')][0x0];_0x1d29e4[_0x2c74c9('0x1f80')]({'controller':_0x2c74c9('0x1f73'),'controllerAs':'vm','templateUrl':_0x31ca62,'parent':angular[_0x2c74c9('0x1194')](_0x1b61b2[_0x2c74c9('0x8d2')]),'targetEvent':_0x17af33,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0xed0de9[_0x2c74c9('0x277c')],'IntervalId':_0xed0de9[_0x2c74c9('0x186f')],'application':!![]},'intervals':[],'crudPermissions':_0x3910fb[_0x2c74c9('0x243c')]}})['then'](function(_0x42bb93){const _0x307d5a=_0x2c74c9;_0x42bb93&&(_0xed0de9[_0x307d5a('0x277c')]=_0x42bb93['interval']||_0x307d5a('0x16f'),_0xed0de9[_0x307d5a('0x186f')]=_0x42bb93['IntervalId']||null,_0x12a69f());});}}function _0x12a69f(){const _0x80fbf3=_0x4da3d6;let _0x4195dd=0x1,_0x171ce9=[];for(let _0x32226d=0x0;_0x32226d<_0x3910fb['openchannelAccountApps'][_0x80fbf3('0x269a')][_0x80fbf3('0x264b')];_0x32226d++){const _0x5c8088=_0x3910fb['openchannelAccountApps'][_0x80fbf3('0x269a')][_0x32226d],_0x2e05b6=[],_0x2931e8=[];_0x5c8088[_0x80fbf3('0x164e')]=_0x5c8088[_0x80fbf3('0x277c')]!==_0x80fbf3('0x16f')?[_0x5c8088['interval']]:_0x5c8088[_0x80fbf3('0x186f')]?_0x2cfb05()[_0x80fbf3('0x2563')](_0x2cfb05()[_0x80fbf3('0x1c33')](_0x3910fb[_0x80fbf3('0x164e')][_0x80fbf3('0x269a')],{'IntervalId':_0x5c8088[_0x80fbf3('0x186f')]}),'interval'):[],_0x5c8088['context']=_0x3910fb[_0x80fbf3('0x77f')]['context'],_0x5c8088[_0x80fbf3('0x23ae')]=_0x3910fb[_0x80fbf3('0x77f')][_0x80fbf3('0x23ae')],_0x5c8088[_0x80fbf3('0x1345')]&&(_0x5c8088['type']=_0x5c8088[_0x80fbf3('0x1345')][_0x80fbf3('0x2574')]()),_0x5c8088['priority']=_0x2e05b6[_0x80fbf3('0x264b')]?_0x2cfb05()[_0x80fbf3('0x1ef5')](_0x2e05b6)[_0x80fbf3('0xfde')]+0x1:_0x4195dd,_0x4195dd=(_0x2931e8[_0x80fbf3('0x264b')]?_0x2cfb05()[_0x80fbf3('0x1ef5')](_0x2931e8)[_0x80fbf3('0xfde')]:_0x5c8088[_0x80fbf3('0xfde')])+0x1,_0x171ce9=_0x2cfb05()[_0x80fbf3('0x1c6a')](_0x171ce9,_0x2e05b6,[_0x5c8088],_0x2931e8);}_0x24c392[_0x80fbf3('0x77f')]['addApplications']({'id':_0x3910fb[_0x80fbf3('0x77f')]['id']},_0x2cfb05()[_0x80fbf3('0x1eba')](_0x171ce9,'priority'))[_0x80fbf3('0xa44')][_0x80fbf3('0x1166')](function(_0xbe3b29){const _0x2415ab=_0x80fbf3;_0x3910fb['openchannelAccountApps'][_0x2415ab('0x269a')]=_0xbe3b29['rows'];})[_0x80fbf3('0x1a80')](function(_0x107270){const _0x3305bf=_0x80fbf3;console[_0x3305bf('0xfc9')](_0x107270);});}function _0x132446(_0x3670a1){const _0x47cdaa=_0x4da3d6;_0x3910fb[_0x47cdaa('0xeda')]=_0x3670a1||{'count':0x0,'rows':[]};}function _0x33de0f(){const _0x544102=_0x4da3d6;return _0x24c392[_0x544102('0x277c')][_0x544102('0xd83')]({'fields':_0x544102('0x1d39')})['$promise'][_0x544102('0x1166')](function(_0x142875){const _0xaba5f5=_0x544102;_0x3910fb[_0xaba5f5('0x164e')]=_0x142875;})['catch'](function(_0x563602){const _0x576b75=_0x544102;console[_0x576b75('0xfc9')](_0x563602);});}function _0x11d425(){const _0x4f1a51=_0x4da3d6;_0x3910fb[_0x4f1a51('0x1f48')]=_0x24c392[_0x4f1a51('0x77f')][_0x4f1a51('0x10e0')](_0x3910fb[_0x4f1a51('0x2218')],_0x132446)[_0x4f1a51('0xa44')];}function _0xba1200(_0x16ce0b){const _0x126392=_0x4da3d6;_0x2cfb05()[_0x126392('0x127f')](_0x3910fb['openchannelAccountApps'][_0x126392('0x269a')],{'id':_0x16ce0b['id']}),_0x12a69f(),_0x38f589[_0x126392('0x103b')]({'title':_0x126392('0x11c0'),'msg':_0x16ce0b[_0x126392('0x746')]?_0x16ce0b['app']+_0x126392('0x7cd'):''});}function _0x256c9f(_0x239543){const _0x1bab7b=_0x4da3d6,_0xd98edc=_0x1d29e4[_0x1bab7b('0x1d26')]()['title'](_0x1bab7b('0x2338'))[_0x1bab7b('0xf3c')](_0x1bab7b('0x12b5')+_0x3910fb[_0x1bab7b('0x4ef')][_0x1bab7b('0x264b')]+_0x1bab7b('0x196d')+_0x1bab7b('0x3f3'))[_0x1bab7b('0x8e8')](_0x1bab7b('0x106e'))['targetEvent'](_0x239543)['ok']('OK')[_0x1bab7b('0x3f')](_0x1bab7b('0x2d3'));_0x1d29e4[_0x1bab7b('0x1f80')](_0xd98edc)[_0x1bab7b('0x1166')](function(){const _0x2352c4=_0x1bab7b;_0x3910fb[_0x2352c4('0x4ef')]['forEach'](function(_0x17a8a2){const _0x37a6d1=_0x2352c4;_0x2cfb05()[_0x37a6d1('0x127f')](_0x3910fb[_0x37a6d1('0xeda')][_0x37a6d1('0x269a')],{'id':_0x17a8a2['id']});}),_0x3910fb[_0x2352c4('0x4ef')]=[],_0x12a69f();});}}const _0x11e977=_0x11d721;_0x4ceac4[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x77f'),'openchannelAccounts',_0x36e6f4('0xf01'),'$translate','Auth',_0x36e6f4('0x243c')];function _0x4ceac4(_0x31472a,_0x5e1ef1,_0x248465,_0x24c4a3,_0x7d35b2,_0x547bd2,_0x592a32,_0x26286a,_0xeb97cd,_0x36a42b){const _0x38847b=_0x36e6f4,_0x1bfd51=this;_0x1bfd51['currentUser']=_0xeb97cd[_0x38847b('0x26cd')](),_0x1bfd51[_0x38847b('0x77f')]=_0x7d35b2,_0x1bfd51[_0x38847b('0x243c')]=_0x36a42b,_0x1bfd51['realtime']=_0x592a32,_0x1bfd51[_0x38847b('0xbd7')]=[],_0x1bfd51['allowedItems']=[],_0x1bfd51[_0x38847b('0x18e1')]=[],_0x1bfd51[_0x38847b('0x2111')]=[],_0x1bfd51[_0x38847b('0x2781')]=[],_0x1bfd51['pendingChanges']=![],_0x1bfd51[_0x38847b('0xae0')]=_0xcb440a,_0x1bfd51[_0x38847b('0x1d92')]=_0x55a907,_0x1bfd51[_0x38847b('0x24a0')]=_0x414e78,_0x1bfd51['dualMultiselectOptions']={'readOnly':!_0x1bfd51[_0x38847b('0x243c')]['canEdit'],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x38847b('0x4f0'),'line1':_0x38847b('0x6e1'),'line2':[_0x38847b('0x4f0'),'internal'],'line3':'','labelAll':_0x26286a[_0x38847b('0x25cc')](_0x38847b('0x2783')),'labelSelected':_0x26286a[_0x38847b('0x25cc')](_0x38847b('0xaa2')),'transferCallback':function(){const _0x2d85fb=_0x38847b,_0xf69da2=_0x2cfb05()['xorBy'](_0x1bfd51[_0x2d85fb('0x2781')],_0x1bfd51[_0x2d85fb('0x18e1')],'id');_0x1bfd51[_0x2d85fb('0x14d7')]=_0x2cfb05()[_0x2d85fb('0x1081')](_0xf69da2)?![]:!![];}};function _0xcb440a(){const _0x13f595=_0x38847b;return _0xeb97cd[_0x13f595('0x1ac6')](_0x13f595('0xa7c'))?_0x396475()[_0x13f595('0x1a80')](function(_0x88755e){const _0x3d2d34=_0x13f595;_0x248465[_0x3d2d34('0xfc9')]({'title':_0x88755e['status']?_0x3d2d34('0x1e21')+_0x88755e[_0x3d2d34('0x52d')]+_0x3d2d34('0x11e1')+_0x88755e[_0x3d2d34('0xe1b')]:'SYSTEM:GET_AGENTS','msg':_0x88755e['status']?JSON[_0x3d2d34('0xbac')](_0x88755e[_0x3d2d34('0x25f4')]):_0x88755e[_0x3d2d34('0x1586')]()});}):_0x17b6a5()[_0x13f595('0x1166')](function(_0x5771a1){return _0x1bfd51['section']=_0x5771a1,_0x396475();})[_0x13f595('0x1a80')](function(_0x5424b6){const _0x3113cd=_0x13f595;_0x248465[_0x3113cd('0xfc9')]({'title':_0x5424b6['status']?_0x3113cd('0x1e21')+_0x5424b6[_0x3113cd('0x52d')]+'\x20-\x20'+_0x5424b6[_0x3113cd('0xe1b')]:_0x3113cd('0xd4c'),'msg':_0x5424b6[_0x3113cd('0x52d')]?JSON[_0x3113cd('0xbac')](_0x5424b6[_0x3113cd('0x25f4')]):_0x5424b6[_0x3113cd('0x1586')]()});});}function _0x17b6a5(){return _0x5e1ef1(function(_0x24b721,_0xeddcb){const _0x178bc9=a0_0x3f2c;_0x24c4a3['userProfileSection'][_0x178bc9('0xd83')]({'userProfileId':_0x1bfd51[_0x178bc9('0x98')]['userProfileId'],'name':_0x178bc9('0x2391')})[_0x178bc9('0xa44')]['then'](function(_0x11417d){const _0x49ce61=_0x178bc9,_0x178b15=_0x11417d&&_0x11417d[_0x49ce61('0x269a')]?_0x11417d[_0x49ce61('0x269a')][0x0]:null;_0x24b721(_0x178b15);})[_0x178bc9('0x1a80')](function(_0x1498ef){_0xeddcb(_0x1498ef);});});}function _0x396475(){return _0x5e1ef1(function(_0x1b0add,_0x9b6b65){const _0x4d0c24=a0_0x3f2c;return _0xf7afa7()[_0x4d0c24('0x1166')](function(_0x13dffb){const _0x45266d=_0x4d0c24;return _0x1bfd51[_0x45266d('0xbd7')]=_0x13dffb[_0x45266d('0x269a')]?_0x13dffb['rows']:[],_0xeb97cd[_0x45266d('0x1ac6')]('admin')?_0x13dffb:_0x1bfd51[_0x45266d('0xe60')]?_0x1bfd51[_0x45266d('0xe60')]['autoAssociation']?_0x13dffb:_0x159cfe():null;})[_0x4d0c24('0x1166')](function(_0xa464c2){const _0x552da1=_0x4d0c24,_0x4a707f=_0xa464c2&&_0xa464c2['rows']?_0xa464c2[_0x552da1('0x269a')]:[];return _0x1bfd51[_0x552da1('0x10ab')]=_0x2cfb05()[_0x552da1('0x2563')](_0x4a707f,function(_0x1c48ce){const _0x38dbe7=_0x552da1;return _0x2cfb05()[_0x38dbe7('0xc38')](_0x1bfd51[_0x38dbe7('0xbd7')],{'id':_0xeb97cd[_0x38dbe7('0x1ac6')](_0x38dbe7('0xa7c'))||_0x1bfd51[_0x38dbe7('0xe60')]['autoAssociation']?_0x1c48ce['id']:_0x1c48ce[_0x38dbe7('0x24e8')]});}),_0x1bfd51[_0x552da1('0x2111')]=angular[_0x552da1('0x225f')](_0x1bfd51[_0x552da1('0x10ab')]),_0x1bfd51[_0x552da1('0xbd7')][_0x552da1('0x2782')](function(_0x478518){const _0x3b9d5a=_0x552da1,_0x3cd83c=_0x2cfb05()[_0x3b9d5a('0xc38')](_0x1bfd51[_0x3b9d5a('0x10ab')],{'id':_0x478518['id']});_0xeb97cd[_0x3b9d5a('0x1ac6')](_0x3b9d5a('0xa7c'))?_0x478518[_0x3b9d5a('0x26ef')]=!![]:_0x478518[_0x3b9d5a('0x26ef')]=typeof _0x3cd83c!==_0x3b9d5a('0x1048')?!![]:![];}),_0x26b781();})['then'](function(_0x385489){const _0x4da12b=_0x4d0c24,_0xf778af=_0x385489&&_0x385489[_0x4da12b('0x269a')]?_0x385489[_0x4da12b('0x269a')]:[];_0x1bfd51[_0x4da12b('0x18e1')]=_0x2cfb05()[_0x4da12b('0x2563')](_0xf778af,function(_0x42c15e){const _0x134e78=_0x4da12b,_0x1db983=_0x2cfb05()[_0x134e78('0xc38')](_0x1bfd51['items'],{'id':_0x42c15e['id']});return _0x1db983['penalty']=_0x42c15e[_0x134e78('0x6c7')]?_0x134e78('0x11e8')+_0x42c15e[_0x134e78('0x6c7')]['penalty']:'',_0x1db983[_0x134e78('0x1eef')]=typeof _0x42c15e[_0x134e78('0x1eef')]!==_0x134e78('0x1048')?'<'+_0x42c15e[_0x134e78('0x1eef')]+'>':'',_0x1db983;}),_0x1bfd51[_0x4da12b('0x2781')]=angular[_0x4da12b('0x225f')](_0x1bfd51[_0x4da12b('0x18e1')]),_0x1bfd51['dualMultiselectOptions'][_0x4da12b('0x18e1')]=_0x1bfd51['selectedItems'],_0x1bfd51[_0x4da12b('0xc68')][_0x4da12b('0xbd7')]=_0x2cfb05()[_0x4da12b('0x24ac')](_0x1bfd51['allowedItems'],_0x1bfd51[_0x4da12b('0xc68')][_0x4da12b('0x18e1')],'id'),_0x1b0add();})[_0x4d0c24('0x1a80')](function(_0x1f8aba){_0x9b6b65(_0x1f8aba);});});}function _0x159cfe(){return _0x5e1ef1(function(_0x31ea17,_0x2950e7){const _0x42dc95=a0_0x3f2c;return _0x24c4a3[_0x42dc95('0x4b5')]['get']({'sectionId':_0x1bfd51[_0x42dc95('0xe60')]['id'],'nolimit':!![]})[_0x42dc95('0xa44')]['then'](function(_0x4fe669){_0x31ea17(_0x4fe669);})[_0x42dc95('0x1a80')](function(_0x39f10b){_0x2950e7(_0x39f10b);});});}function _0x26b781(){return _0x5e1ef1(function(_0x28f7dc,_0x5e83ef){const _0x2aab59=a0_0x3f2c;return _0x24c4a3[_0x2aab59('0x77f')][_0x2aab59('0x261c')]({'id':_0x1bfd51[_0x2aab59('0x77f')]['id'],'fields':_0x2aab59('0x1459'),'nolimit':!![],'role':_0x2aab59('0x1eff')})[_0x2aab59('0xa44')][_0x2aab59('0x1166')](function(_0x2363ca){_0x28f7dc(_0x2363ca);})[_0x2aab59('0x1a80')](function(_0x1df802){_0x5e83ef(_0x1df802);});});}function _0xf7afa7(){return _0x5e1ef1(function(_0xc147c,_0x52b076){const _0x45c1de=a0_0x3f2c;return _0x24c4a3[_0x45c1de('0x557')][_0x45c1de('0xd83')]({'fields':_0x45c1de('0x1459'),'nolimit':!![],'role':_0x45c1de('0x1eff')})[_0x45c1de('0xa44')][_0x45c1de('0x1166')](function(_0xad6766){_0xc147c(_0xad6766);})['catch'](function(_0x4a5759){_0x52b076(_0x4a5759);});});}function _0x1199e8(_0x788417){return _0x5e1ef1(function(_0x53ac76,_0x5c7c5d){const _0xdf894f=a0_0x3f2c;_0x2cfb05()[_0xdf894f('0x1081')](_0x788417)?_0x53ac76():_0x24c4a3[_0xdf894f('0x77f')][_0xdf894f('0x275c')]({'id':_0x1bfd51[_0xdf894f('0x77f')]['id'],'ids':_0x2cfb05()[_0xdf894f('0x2563')](_0x788417,'id')})[_0xdf894f('0xa44')][_0xdf894f('0x1166')](function(){_0x53ac76();})[_0xdf894f('0x1a80')](function(_0x44eda6){_0x5c7c5d(_0x44eda6);});});}function _0x4a3924(_0x16d9d9){return _0x5e1ef1(function(_0x44cbf2,_0x232d2c){const _0x5be056=a0_0x3f2c;_0x2cfb05()[_0x5be056('0x1081')](_0x16d9d9)?_0x44cbf2():_0x24c4a3[_0x5be056('0x77f')][_0x5be056('0x269d')]({'id':_0x1bfd51[_0x5be056('0x77f')]['id'],'ids':_0x2cfb05()['map'](_0x16d9d9,'id')})[_0x5be056('0xa44')][_0x5be056('0x1166')](function(){_0x44cbf2();})[_0x5be056('0x1a80')](function(_0x8b9bdd){_0x232d2c(_0x8b9bdd);});});}function _0x55a907(){const _0x513f16=_0x38847b,_0x358ca2=_0x2cfb05()[_0x513f16('0x24ac')](_0x1bfd51[_0x513f16('0x2781')],_0x1bfd51[_0x513f16('0x18e1')],'id'),_0x4e31fd=_0x2cfb05()[_0x513f16('0x24ac')](_0x1bfd51[_0x513f16('0x18e1')],_0x1bfd51[_0x513f16('0x2781')],'id');return _0x4a3924(_0x358ca2)[_0x513f16('0x1166')](function(){return _0x1199e8(_0x4e31fd);})['then'](function(){const _0x586651=_0x513f16;_0x1bfd51['pendingChanges']=![],_0x1bfd51['startingAllowedItems']=angular['copy'](_0x1bfd51[_0x586651('0x10ab')]),_0x1bfd51[_0x586651('0x2781')]=angular[_0x586651('0x225f')](_0x1bfd51[_0x586651('0x18e1')]),_0x248465[_0x586651('0x103b')]({'title':_0x586651('0x983'),'msg':_0x586651('0x1673')});})['catch'](function(_0x39da01){const _0x418244=_0x513f16;_0x248465[_0x418244('0xfc9')]({'title':_0x39da01['status']?_0x418244('0x1e21')+_0x39da01[_0x418244('0x52d')]+_0x418244('0x11e1')+_0x39da01['statusText']:_0x418244('0x1b29'),'msg':_0x39da01[_0x418244('0x52d')]?JSON[_0x418244('0xbac')](_0x39da01[_0x418244('0x25f4')]):_0x39da01[_0x418244('0x1586')]()});});}function _0x414e78(){_0x31472a['hide']();}}const _0x22bfc1=_0x4ceac4;_0x258143[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'openchannelAccountApp',_0x36e6f4('0x77f'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x258143(_0x1eef00,_0xa29771,_0x1cc31e,_0xbcd532,_0xd0bebd,_0x5ab761,_0x24a22a,_0x305e02){const _0x422277=_0x36e6f4,_0x40db69=this;_0x40db69[_0x422277('0x98')]=_0x24a22a[_0x422277('0x26cd')](),_0x40db69[_0x422277('0x61a')]=[],_0x40db69['title']=_0x422277('0xf67')+(_0xbcd532[_0x422277('0x83f')]||_0xbcd532[_0x422277('0x746')])[_0x422277('0x1387')](),_0x40db69[_0x422277('0x1eff')]=angular[_0x422277('0x225f')](_0xbcd532),_0x40db69['crudPermissions']=_0x305e02,_0x40db69[_0x422277('0x128b')]={};if(_0x40db69[_0x422277('0x1eff')]['appdata'])switch(_0x40db69[_0x422277('0x1eff')]['appType']?_0x40db69[_0x422277('0x1eff')][_0x422277('0x83f')][_0x422277('0x2574')]():_0x40db69[_0x422277('0x1eff')][_0x422277('0x746')][_0x422277('0x2574')]()){case _0x422277('0x2853'):break;case _0x422277('0xded'):{const _0x374fca=_0x40db69['agent'][_0x422277('0x823')][_0x422277('0x25c8')](',');_0x40db69[_0x422277('0x1eff')]['key']=_0x374fca[0x0],_0x40db69[_0x422277('0x1eff')][_0x422277('0xedb')]=_0x374fca[0x1],_0x40db69[_0x422277('0x1eff')]['welcomemessage']=_0x374fca[_0x422277('0x233')](0x2,_0x374fca[_0x422277('0x264b')])[_0x422277('0x45a')](',');}break;case'dialogflowv2':{const _0x4eb5f5=_0x40db69[_0x422277('0x1eff')][_0x422277('0x823')]['split'](',');_0x40db69[_0x422277('0x1eff')]['projectId']=_0x4eb5f5[0x0],_0x40db69[_0x422277('0x1eff')][_0x422277('0x27f3')]=_0x4eb5f5[0x1],_0x40db69[_0x422277('0x1eff')]['privateKey']=_0x4eb5f5[0x2],_0x40db69[_0x422277('0x1eff')]['language']=_0x4eb5f5[0x3],_0x40db69['agent'][_0x422277('0x1634')]=_0x4eb5f5[_0x422277('0x233')](0x4,_0x4eb5f5['length'])[_0x422277('0x45a')](',');}break;case'amazonlex':{const _0x34a6ea=_0x40db69['agent'][_0x422277('0x823')][_0x422277('0x25c8')](',');_0x40db69[_0x422277('0x1eff')][_0x422277('0xee6')]=_0x34a6ea[0x0],_0x40db69[_0x422277('0x1eff')][_0x422277('0x125')]=_0x34a6ea[0x1],_0x40db69[_0x422277('0x1eff')][_0x422277('0x25a2')]=_0x34a6ea[0x2],_0x40db69['agent'][_0x422277('0x1ac4')]=_0x34a6ea[0x3],_0x40db69[_0x422277('0x1eff')]['welcomemessage']=_0x34a6ea[_0x422277('0x233')](0x4,_0x34a6ea[_0x422277('0x264b')])[_0x422277('0x45a')](',');}break;case'autoreply':{const _0x409f30=_0x40db69[_0x422277('0x1eff')][_0x422277('0x823')]['split'](',');_0x40db69[_0x422277('0x1eff')][_0x422277('0x265e')]=isNaN(_0x409f30[0x0])?_0x409f30[0x0]:parseInt(_0x409f30[0x0],0xa),_0x40db69[_0x422277('0x1eff')][_0x422277('0x1640')]=_0x409f30[_0x422277('0x233')](0x1,_0x409f30[_0x422277('0x264b')])['join'](',');}break;case _0x422277('0x1e70'):_0x40db69['agent'][_0x422277('0x1640')]=_0x40db69[_0x422277('0x1eff')]['appdata'];break;case _0x422277('0xceb'):_0x40db69['agent'][_0x422277('0x4f0')]=_0x40db69['agent'][_0x422277('0x823')][_0x422277('0x25c8')]('=')[0x0],_0x40db69[_0x422277('0x1eff')]['value']=_0x40db69[_0x422277('0x1eff')][_0x422277('0x823')][_0x422277('0x25c8')]('=')[0x1];break;case'agi':_0x40db69[_0x422277('0x1eff')][_0x422277('0x2588')]=_0x40db69[_0x422277('0x1eff')]['appdata'];break;default:{const _0x1b0b32=_0x40db69['agent'][_0x422277('0x823')]['split'](',');_0x40db69[_0x422277('0x1eff')]['agent']=_0x2cfb05()[_0x422277('0x1081')](_0x1b0b32[0x0])?_0x1b0b32[0x0]:isNaN(_0x1b0b32[0x0])?_0x1b0b32[0x0]:parseInt(_0x1b0b32[0x0],0xa),_0x40db69[_0x422277('0x1eff')]['timeout']=_0x2cfb05()[_0x422277('0x1081')](_0x1b0b32[0x1])?_0x1b0b32[0x1]:isNaN(_0x1b0b32[0x1])?_0x1b0b32[0x1]:parseInt(_0x1b0b32[0x1],0xa);}break;}else _0x40db69[_0x422277('0x1eff')][_0x422277('0x651')]=0x1e;_0x40db69['agent'][_0x422277('0x1345')]&&_0x40db69[_0x422277('0x1eff')]['type']['toLowerCase']()===_0x422277('0x587')&&_0x40db69[_0x422277('0x1eff')][_0x422277('0x83f')][_0x422277('0x2574')]()===_0x422277('0x2884')&&(_0x40db69[_0x422277('0x1eff')][_0x422277('0x265a')]=_0x40db69['agent'][_0x422277('0x2026')]?_0x40db69['agent'][_0x422277('0x2026')][_0x422277('0x25c8')]('$')[0x0]:undefined,_0x40db69[_0x422277('0x1eff')][_0x422277('0x1f02')]=_0x40db69[_0x422277('0x1eff')][_0x422277('0x992')]?'CALLERID(all)='+_0x40db69[_0x422277('0x1eff')][_0x422277('0x992')]:undefined);_0x40db69['saveOpenchannelAccountApp']=_0x1a5cc0,_0x40db69[_0x422277('0x24a0')]=_0x4c546d,_0x24a22a['hasRole'](_0x422277('0xa7c'))?_0x5ab761[_0x422277('0x557')][_0x422277('0xd83')]({'fields':'id,name','sort':_0x422277('0x4f0'),'role':_0x422277('0x1eff'),'nolimit':_0x422277('0xf3b')})[_0x422277('0xa44')][_0x422277('0x1166')](function(_0x445b1a){const _0x1e7ea2=_0x422277;_0x40db69[_0x1e7ea2('0x1f7e')]=_0x445b1a[_0x1e7ea2('0x269a')]||[];})['catch'](function(_0x201c23){const _0x434a59=_0x422277;_0x1cc31e[_0x434a59('0xfc9')]({'title':_0x201c23[_0x434a59('0x52d')]?_0x434a59('0x1e21')+_0x201c23[_0x434a59('0x52d')]+_0x434a59('0x11e1')+_0x201c23[_0x434a59('0xe1b')]:_0x434a59('0xd4c'),'msg':_0x201c23[_0x434a59('0x25f4')]?JSON['stringify'](_0x201c23[_0x434a59('0x25f4')]):_0x201c23[_0x434a59('0x1586')]()});}):_0x5ab761[_0x422277('0x557')][_0x422277('0xd83')]({'fields':_0x422277('0x1776'),'sort':_0x422277('0x4f0'),'role':_0x422277('0x1eff'),'nolimit':_0x422277('0xf3b')})[_0x422277('0xa44')][_0x422277('0x1166')](function(_0x182ad9){const _0x3752d9=_0x422277;_0x40db69[_0x3752d9('0x1f7e')]=_0x182ad9['rows']||[];})[_0x422277('0x1166')](function(){const _0xe6d83a=_0x422277;return _0x5ab761['userProfileSection'][_0xe6d83a('0xd83')]({'userProfileId':_0x40db69[_0xe6d83a('0x98')]['userProfileId'],'sectionId':0xca})[_0xe6d83a('0xa44')];})[_0x422277('0x1166')](function(_0x4f4015){const _0x508005=_0x422277,_0x508481=_0x4f4015&&_0x4f4015[_0x508005('0x269a')]?_0x4f4015[_0x508005('0x269a')][0x0]:null;if(!_0x508481){const _0x19f562=[];let _0x38ba40=null;_0x40db69[_0x508005('0x1eff')]&&(_0x38ba40=_0x2cfb05()[_0x508005('0xc38')](_0x40db69['agents'],{'name':_0x40db69['agent'][_0x508005('0x1eff')]}));for(let _0x485e13=0x0;_0x485e13<_0x40db69[_0x508005('0x1f7e')][_0x508005('0x264b')];_0x485e13++){_0x38ba40&&_0x40db69[_0x508005('0x1f7e')][_0x485e13]['id']===_0x38ba40['id']&&(_0x40db69[_0x508005('0x1f7e')][_0x485e13]['canSelect']=![],_0x19f562['push'](_0x40db69[_0x508005('0x1f7e')][_0x485e13]));}_0x40db69[_0x508005('0x1f7e')]=_0x19f562;}else{if(!_0x508481[_0x508005('0x1a2b')])return _0x5ab761['userProfileResource'][_0x508005('0xd83')]({'sectionId':_0x508481['id']})['$promise'][_0x508005('0x1166')](function(_0x692d8f){const _0x3e0a59=_0x508005,_0x28de50=_0x2cfb05()[_0x3e0a59('0x2563')](_0x692d8f[_0x3e0a59('0x269a')],function(_0x2ee82f){const _0x5e8e95=_0x3e0a59;return _0x2cfb05()['find'](_0x40db69[_0x5e8e95('0x1f7e')],{'id':_0x2ee82f[_0x5e8e95('0x24e8')]});});let _0x3f901d=null;_0x40db69[_0x3e0a59('0x1eff')]&&(_0x3f901d=_0x2cfb05()[_0x3e0a59('0xc38')](_0x40db69[_0x3e0a59('0x1f7e')],{'name':_0x40db69[_0x3e0a59('0x1eff')][_0x3e0a59('0x1eff')]}));if(_0x3f901d&&!_0x2cfb05()['some'](_0x28de50,['id',_0x3f901d['id']])){const _0x527ae3=_0x2cfb05()[_0x3e0a59('0xc38')](_0x40db69[_0x3e0a59('0x1f7e')],{'id':_0x3f901d['id']});_0x527ae3[_0x3e0a59('0x2378')]=![],_0x28de50[_0x3e0a59('0x1514')](_0x527ae3);}_0x40db69[_0x3e0a59('0x1f7e')]=_0x28de50;});}})[_0x422277('0x1a80')](function(_0x4574b4){const _0x384bfc=_0x422277;_0x1cc31e[_0x384bfc('0xfc9')]({'title':_0x4574b4['status']?_0x384bfc('0x1e21')+_0x4574b4['status']+_0x384bfc('0x11e1')+_0x4574b4['statusText']:_0x384bfc('0xdc5'),'msg':_0x4574b4['data']?JSON[_0x384bfc('0xbac')](_0x4574b4[_0x384bfc('0x25f4')]):_0x4574b4[_0x384bfc('0x1586')]()});});function _0x1a5cc0(){const _0x30dbd5=_0x422277;_0x40db69['errors']=[];const _0x985a61=[];_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0x1345')]&&_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0x1345')][_0x30dbd5('0x2574')]()===_0x30dbd5('0x587')&&_0x40db69['agent'][_0x30dbd5('0x83f')]==='outboundDial'&&(_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0x2026')]=_0xd0bebd[_0x30dbd5('0x2848')]?(_0x40db69['agent']['prefix']||'')+_0x30dbd5('0x881')+_0xd0bebd[_0x30dbd5('0x2848')]+'}':(_0x40db69['agent'][_0x30dbd5('0x265a')]||'')+_0x30dbd5('0x1d1'),_0xd0bebd[_0x30dbd5('0x28cb')]!==_0x30dbd5('0x192')?_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0xd39')][_0x30dbd5('0x2379')](_0x30dbd5('0x1059'))<0x0&&(_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0xd39')]+=_0x30dbd5('0x1059')):_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0xd39')]=_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0xd39')][_0x30dbd5('0xf3')](_0x30dbd5('0x1059'),''));const _0x188c6d=_0x2cfb05()[_0x30dbd5('0xc38')](_0x40db69[_0x30dbd5('0x1f7e')],{'name':_0x40db69['agent']['agent']});_0x188c6d&&(_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0x122a')]=_0x188c6d['id']);if(_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0x83f')]&&_0x40db69[_0x30dbd5('0x1eff')]['appType']==='custom'){}else switch((_0x40db69[_0x30dbd5('0x1eff')]['app']||_0x40db69[_0x30dbd5('0x1eff')]['appType'])[_0x30dbd5('0x2574')]()){case _0x30dbd5('0xceb'):_0x40db69['agent']['appdata']=_0x40db69['agent'][_0x30dbd5('0x4f0')]+'='+_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0x18e0')];break;case _0x30dbd5('0x2853'):break;default:_0x985a61[0x0]=_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0x1eff')],_0x985a61[0x1]=_0x40db69[_0x30dbd5('0x1eff')][_0x30dbd5('0x651')],_0x40db69['agent'][_0x30dbd5('0x823')]=_0x985a61[_0x30dbd5('0x45a')](',');}_0x4c546d(_0x40db69['agent']);}function _0x4c546d(_0x20e3d4){const _0x5d9a21=_0x422277;_0x1eef00[_0x5d9a21('0x1197')](_0x20e3d4);}}const _0x34e150=_0x258143;_0x33bc0e['$inject']=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x248f'),_0x36e6f4('0x77f'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x33bc0e(_0x26d663,_0x272337,_0x4af545,_0xd6a5a0,_0x21f405,_0x3a7dae,_0x3ed0e1,_0x3e7197){const _0x1d3cd4=_0x36e6f4,_0x2a9ebc=this;_0x2a9ebc[_0x1d3cd4('0x98')]=_0x3ed0e1['getCurrentUser'](),_0x2a9ebc['errors']=[],_0x2a9ebc['title']=_0x1d3cd4('0xf67')+(_0xd6a5a0[_0x1d3cd4('0x83f')]||_0xd6a5a0[_0x1d3cd4('0x746')])[_0x1d3cd4('0x1387')](),_0x2a9ebc[_0x1d3cd4('0x86c')]=angular['copy'](_0xd6a5a0),_0x2a9ebc[_0x1d3cd4('0x243c')]=_0x3e7197,_0x2a9ebc['hasModulePermissions']={};if(_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x823')])switch(_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x83f')]?_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x83f')]['toLowerCase']():_0x2a9ebc['amazonlex'][_0x1d3cd4('0x746')]['toLowerCase']()){case'custom':break;case _0x1d3cd4('0xded'):{const _0x5ab028=_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x823')][_0x1d3cd4('0x25c8')](',');_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x7ca')]=_0x5ab028[0x0],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0xedb')]=_0x5ab028[0x1],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x1634')]=_0x5ab028[_0x1d3cd4('0x233')](0x2,_0x5ab028[_0x1d3cd4('0x264b')])['join'](',');}break;case'dialogflowv2':{const _0x281f60=_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x823')]['split'](',');_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x1b0a')]=_0x281f60[0x0],_0x2a9ebc['amazonlex'][_0x1d3cd4('0x27f3')]=_0x281f60[0x1],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x170e')]=_0x281f60[0x2],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0xedb')]=_0x281f60[0x3],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x1634')]=_0x281f60[_0x1d3cd4('0x233')](0x4,_0x281f60['length'])['join'](',');}break;case _0x1d3cd4('0x86c'):{const _0x3b0e96=_0x2a9ebc['amazonlex']['appdata'][_0x1d3cd4('0x25c8')](',');_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0xee6')]=_0x3b0e96[0x0],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x125')]=_0x3b0e96[0x1],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x25a2')]=_0x3b0e96[0x2],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x1ac4')]=_0x3b0e96[0x3],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x1634')]=_0x3b0e96[_0x1d3cd4('0x233')](0x4,_0x3b0e96[_0x1d3cd4('0x264b')])[_0x1d3cd4('0x45a')](',');}break;case'autoreply':{const _0x5384a0=_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x823')][_0x1d3cd4('0x25c8')](',');_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x265e')]=isNaN(_0x5384a0[0x0])?_0x5384a0[0x0]:parseInt(_0x5384a0[0x0],0xa),_0x2a9ebc['amazonlex'][_0x1d3cd4('0x1640')]=_0x5384a0[_0x1d3cd4('0x233')](0x1,_0x5384a0[_0x1d3cd4('0x264b')])['join'](',');}break;case'message':_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x1640')]=_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x823')];break;case _0x1d3cd4('0xceb'):_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x4f0')]=_0x2a9ebc['amazonlex'][_0x1d3cd4('0x823')][_0x1d3cd4('0x25c8')]('=')[0x0],_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x18e0')]=_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x823')][_0x1d3cd4('0x25c8')]('=')[0x1];break;case'agi':_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x2588')]=_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x823')];break;default:{const _0x39e0b1=_0x2a9ebc['amazonlex'][_0x1d3cd4('0x823')]['split'](',');_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0xee6')]=_0x2cfb05()[_0x1d3cd4('0x1081')](_0x39e0b1[0x0])?_0x39e0b1[0x0]:isNaN(_0x39e0b1[0x0])?_0x39e0b1[0x0]:parseInt(_0x39e0b1[0x0],0xa),_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x125')]=_0x2cfb05()[_0x1d3cd4('0x1081')](_0x39e0b1[0x1])?_0x39e0b1[0x1]:isNaN(_0x39e0b1[0x1])?_0x39e0b1[0x1]:parseInt(_0x39e0b1[0x1],0xa),_0x2a9ebc['amazonlex'][_0x1d3cd4('0x25a2')]=_0x2cfb05()[_0x1d3cd4('0x1081')](_0x39e0b1[0x2])?_0x39e0b1[0x2]:isNaN(_0x39e0b1[0x2])?_0x39e0b1[0x2]:parseInt(_0x39e0b1[0x2],0xa),_0x2a9ebc[_0x1d3cd4('0x86c')]['botname']=_0x2cfb05()[_0x1d3cd4('0x1081')](_0x39e0b1[0x3])?_0x39e0b1[0x3]:isNaN(_0x39e0b1[0x3])?_0x39e0b1[0x3]:parseInt(_0x39e0b1[0x3],0xa),_0x2a9ebc['amazonlex'][_0x1d3cd4('0x1634')]=_0x2cfb05()[_0x1d3cd4('0x1081')](_0x39e0b1[0x4])?_0x39e0b1[0x4]:isNaN(_0x39e0b1[0x4])?_0x39e0b1[0x4]:parseInt(_0x39e0b1[0x4],0xa);}break;}else _0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x25a2')]=_0x1d3cd4('0x1039');_0x2a9ebc[_0x1d3cd4('0x86c')]['type']&&_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x1345')]['toLowerCase']()===_0x1d3cd4('0x587')&&_0x2a9ebc['amazonlex'][_0x1d3cd4('0x83f')][_0x1d3cd4('0x2574')]()===_0x1d3cd4('0x2884')&&(_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x265a')]=_0x2a9ebc[_0x1d3cd4('0x86c')]['phone']?_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x2026')][_0x1d3cd4('0x25c8')]('$')[0x0]:undefined,_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x1f02')]=_0x2a9ebc[_0x1d3cd4('0x86c')][_0x1d3cd4('0x992')]?'CALLERID(all)='+_0x2a9ebc[_0x1d3cd4('0x86c')]['callerID']:undefined);_0x2a9ebc[_0x1d3cd4('0x3e2')]=_0x34e435,_0x2a9ebc[_0x1d3cd4('0x24a0')]=_0x4ac4fe;function _0x34e435(){const _0x2b0e2b=_0x1d3cd4;_0x2a9ebc[_0x2b0e2b('0x61a')]=[];const _0x534e68=[];_0x2a9ebc[_0x2b0e2b('0x86c')]['type']&&_0x2a9ebc[_0x2b0e2b('0x86c')]['type']['toLowerCase']()==='outbound'&&_0x2a9ebc['amazonlex'][_0x2b0e2b('0x83f')]==='outboundDial'&&(_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x2026')]=_0x21f405[_0x2b0e2b('0x2848')]?(_0x2a9ebc[_0x2b0e2b('0x86c')]['prefix']||'')+_0x2b0e2b('0x881')+_0x21f405[_0x2b0e2b('0x2848')]+'}':(_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x265a')]||'')+'${EXTEN}',_0x21f405['recordingFormat']!==_0x2b0e2b('0x192')?_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0xd39')]['indexOf'](_0x2b0e2b('0x1059'))<0x0&&(_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0xd39')]+='U(xcally-mixmonitor-context)'):_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0xd39')]=_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0xd39')][_0x2b0e2b('0xf3')](_0x2b0e2b('0x1059'),''));if(_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x83f')]&&_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x83f')]===_0x2b0e2b('0x2853')){}else switch((_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x746')]||_0x2a9ebc['amazonlex']['appType'])[_0x2b0e2b('0x2574')]()){case'set':_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x823')]=_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x4f0')]+'='+_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x18e0')];break;case _0x2b0e2b('0x2853'):break;default:_0x534e68[0x0]=_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0xee6')],_0x534e68[0x1]=_0x2a9ebc['amazonlex'][_0x2b0e2b('0x125')],_0x534e68[0x2]=_0x2a9ebc['amazonlex']['lexregion'],_0x534e68[0x3]=_0x2a9ebc[_0x2b0e2b('0x86c')]['botname'],_0x534e68[0x4]=_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x1634')],_0x2a9ebc[_0x2b0e2b('0x86c')][_0x2b0e2b('0x823')]=_0x534e68[_0x2b0e2b('0x45a')](',');}_0x4ac4fe(_0x2a9ebc[_0x2b0e2b('0x86c')]);}function _0x4ac4fe(_0x524cec){const _0xb081f6=_0x1d3cd4;_0x26d663[_0xb081f6('0x1197')](_0x524cec);}}const _0x5403e3=_0x33bc0e;_0xa2313d['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x248f'),'openchannelAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0xa2313d(_0x5ed27d,_0x3d6bca,_0xf4420c,_0xb61a05,_0x10cdf1,_0x3c1c6d,_0x3b2163,_0x4a84e5){const _0x1800c4=_0x36e6f4,_0x2c2d79=this;_0x2c2d79[_0x1800c4('0x98')]=_0x3b2163[_0x1800c4('0x26cd')](),_0x2c2d79[_0x1800c4('0x61a')]=[],_0x2c2d79[_0x1800c4('0xcdc')]=_0x1800c4('0xf67')+(_0xb61a05[_0x1800c4('0x83f')]||_0xb61a05[_0x1800c4('0x746')])[_0x1800c4('0x1387')](),_0x2c2d79[_0x1800c4('0x1af7')]=angular[_0x1800c4('0x225f')](_0xb61a05),_0x2c2d79['crudPermissions']=_0x4a84e5,_0x2c2d79[_0x1800c4('0x128b')]={};if(_0x2c2d79['autoreply'][_0x1800c4('0x823')])switch(_0x2c2d79['autoreply'][_0x1800c4('0x83f')]?_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x83f')][_0x1800c4('0x2574')]():_0x2c2d79['autoreply']['app'][_0x1800c4('0x2574')]()){case _0x1800c4('0x2853'):break;case'dialogflow':{const _0x272d5c=_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x823')][_0x1800c4('0x25c8')](',');_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x7ca')]=_0x272d5c[0x0],_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0xedb')]=_0x272d5c[0x1],_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x1634')]=_0x272d5c['slice'](0x2,_0x272d5c[_0x1800c4('0x264b')])[_0x1800c4('0x45a')](',');}break;case _0x1800c4('0x1636'):{const _0x460018=_0x2c2d79[_0x1800c4('0x1af7')]['appdata'][_0x1800c4('0x25c8')](',');_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x1b0a')]=_0x460018[0x0],_0x2c2d79['autoreply']['clientEmail']=_0x460018[0x1],_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x170e')]=_0x460018[0x2],_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0xedb')]=_0x460018[0x3],_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x1634')]=_0x460018[_0x1800c4('0x233')](0x4,_0x460018[_0x1800c4('0x264b')])[_0x1800c4('0x45a')](',');}break;case _0x1800c4('0x86c'):{const _0x2b6efe=_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x823')][_0x1800c4('0x25c8')](',');_0x2c2d79['autoreply'][_0x1800c4('0xee6')]=_0x2b6efe[0x0],_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x125')]=_0x2b6efe[0x1],_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x25a2')]=_0x2b6efe[0x2],_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x1ac4')]=_0x2b6efe[0x3],_0x2c2d79['autoreply']['welcomemessage']=_0x2b6efe[_0x1800c4('0x233')](0x4,_0x2b6efe[_0x1800c4('0x264b')])['join'](',');}break;case _0x1800c4('0x1af7'):{const _0x281bc7=_0x2c2d79['autoreply'][_0x1800c4('0x823')][_0x1800c4('0x25c8')](',');_0x2c2d79[_0x1800c4('0x1af7')]['times']=isNaN(_0x281bc7[0x0])?_0x281bc7[0x0]:parseInt(_0x281bc7[0x0],0xa),_0x2c2d79[_0x1800c4('0x1af7')]['text']=_0x281bc7['slice'](0x1,_0x281bc7[_0x1800c4('0x264b')])[_0x1800c4('0x45a')](',');}break;case _0x1800c4('0x1e70'):_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x1640')]=_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x823')];break;case _0x1800c4('0xceb'):_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x4f0')]=_0x2c2d79['autoreply'][_0x1800c4('0x823')][_0x1800c4('0x25c8')]('=')[0x0],_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x18e0')]=_0x2c2d79['autoreply'][_0x1800c4('0x823')]['split']('=')[0x1];break;case'agi':_0x2c2d79[_0x1800c4('0x1af7')]['project']=_0x2c2d79[_0x1800c4('0x1af7')]['appdata'];break;default:{const _0x332c0b=_0x2c2d79[_0x1800c4('0x1af7')]['appdata'][_0x1800c4('0x25c8')](',');_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x265e')]=_0x2cfb05()[_0x1800c4('0x1081')](_0x332c0b[0x0])?_0x332c0b[0x0]:isNaN(_0x332c0b[0x0])?_0x332c0b[0x0]:parseInt(_0x332c0b[0x0],0xa),_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x1640')]=_0x2cfb05()[_0x1800c4('0x1081')](_0x332c0b[0x1])?_0x332c0b[0x1]:isNaN(_0x332c0b[0x1])?_0x332c0b[0x1]:parseInt(_0x332c0b[0x1],0xa);}break;}else _0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x265e')]=0x1;_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x1345')]&&_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x1345')]['toLowerCase']()===_0x1800c4('0x587')&&_0x2c2d79['autoreply'][_0x1800c4('0x83f')][_0x1800c4('0x2574')]()===_0x1800c4('0x2884')&&(_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x265a')]=_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x2026')]?_0x2c2d79[_0x1800c4('0x1af7')]['phone'][_0x1800c4('0x25c8')]('$')[0x0]:undefined,_0x2c2d79['autoreply'][_0x1800c4('0x1f02')]=_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x992')]?_0x1800c4('0xa4c')+_0x2c2d79[_0x1800c4('0x1af7')][_0x1800c4('0x992')]:undefined);_0x2c2d79[_0x1800c4('0x3e2')]=_0x4c5337,_0x2c2d79[_0x1800c4('0x24a0')]=_0x14c51a;function _0x4c5337(){const _0x75c857=_0x1800c4;_0x2c2d79[_0x75c857('0x61a')]=[];const _0x1e8dd5=[];_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x1345')]&&_0x2c2d79[_0x75c857('0x1af7')]['type']['toLowerCase']()===_0x75c857('0x587')&&_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x83f')]===_0x75c857('0x867')&&(_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x2026')]=_0x10cdf1['cutdigits']?(_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x265a')]||'')+'${EXTEN:'+_0x10cdf1[_0x75c857('0x2848')]+'}':(_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x265a')]||'')+'${EXTEN}',_0x10cdf1['recordingFormat']!==_0x75c857('0x192')?_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0xd39')][_0x75c857('0x2379')](_0x75c857('0x1059'))<0x0&&(_0x2c2d79[_0x75c857('0x1af7')]['options']+=_0x75c857('0x1059')):_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0xd39')]=_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0xd39')][_0x75c857('0xf3')](_0x75c857('0x1059'),''));if(_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x83f')]&&_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x83f')]===_0x75c857('0x2853')){}else switch((_0x2c2d79[_0x75c857('0x1af7')]['app']||_0x2c2d79[_0x75c857('0x1af7')]['appType'])[_0x75c857('0x2574')]()){case _0x75c857('0xceb'):_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x823')]=_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x4f0')]+'='+_0x2c2d79['autoreply'][_0x75c857('0x18e0')];break;case _0x75c857('0x2853'):break;default:_0x1e8dd5[0x0]=_0x2c2d79[_0x75c857('0x1af7')]['times'],_0x1e8dd5[0x1]=_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x1640')],_0x2c2d79[_0x75c857('0x1af7')][_0x75c857('0x823')]=_0x1e8dd5[_0x75c857('0x45a')](',');}_0x14c51a(_0x2c2d79['autoreply']);}function _0x14c51a(_0x47eca6){_0x5ed27d['hide'](_0x47eca6);}}const _0x2f2e6c=_0xa2313d;_0x1f91a6['$inject']=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x248f'),'openchannelAccount','api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x1f91a6(_0x53eb5b,_0x5e7960,_0x22c4d0,_0x4b9a0b,_0x5d9c8c,_0x52dcc2,_0x41aec9,_0x6f7275){const _0x46e619=_0x36e6f4,_0x5cde18=this;_0x5cde18[_0x46e619('0x98')]=_0x41aec9[_0x46e619('0x26cd')](),_0x5cde18[_0x46e619('0x61a')]=[],_0x5cde18[_0x46e619('0xcdc')]='OPENCHANNEL.EDIT_'+(_0x4b9a0b[_0x46e619('0x83f')]||_0x4b9a0b[_0x46e619('0x746')])[_0x46e619('0x1387')](),_0x5cde18[_0x46e619('0x1a7b')]=angular[_0x46e619('0x225f')](_0x4b9a0b),_0x5cde18[_0x46e619('0x243c')]=_0x6f7275,_0x5cde18[_0x46e619('0x128b')]={};if(_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x823')])switch(_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x83f')]?_0x5cde18['close']['appType'][_0x46e619('0x2574')]():_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x746')][_0x46e619('0x2574')]()){case _0x46e619('0x2853'):break;case _0x46e619('0xded'):{const _0x152dae=_0x5cde18['close'][_0x46e619('0x823')][_0x46e619('0x25c8')](',');_0x5cde18['close'][_0x46e619('0x7ca')]=_0x152dae[0x0],_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0xedb')]=_0x152dae[0x1],_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x1634')]=_0x152dae[_0x46e619('0x233')](0x2,_0x152dae[_0x46e619('0x264b')])[_0x46e619('0x45a')](',');}break;case _0x46e619('0x1636'):{const _0x2b386b=_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x823')]['split'](',');_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x1b0a')]=_0x2b386b[0x0],_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x27f3')]=_0x2b386b[0x1],_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x170e')]=_0x2b386b[0x2],_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0xedb')]=_0x2b386b[0x3],_0x5cde18['close'][_0x46e619('0x1634')]=_0x2b386b[_0x46e619('0x233')](0x4,_0x2b386b[_0x46e619('0x264b')])['join'](',');}break;case _0x46e619('0x86c'):{const _0x7b8bd6=_0x5cde18['close'][_0x46e619('0x823')][_0x46e619('0x25c8')](',');_0x5cde18['close']['accesskeyid']=_0x7b8bd6[0x0],_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x125')]=_0x7b8bd6[0x1],_0x5cde18['close'][_0x46e619('0x25a2')]=_0x7b8bd6[0x2],_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x1ac4')]=_0x7b8bd6[0x3],_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x1634')]=_0x7b8bd6[_0x46e619('0x233')](0x4,_0x7b8bd6[_0x46e619('0x264b')])[_0x46e619('0x45a')](',');}break;case _0x46e619('0x1af7'):{const _0x7417d1=_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x823')][_0x46e619('0x25c8')](',');_0x5cde18[_0x46e619('0x1a7b')]['times']=isNaN(_0x7417d1[0x0])?_0x7417d1[0x0]:parseInt(_0x7417d1[0x0],0xa),_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x1640')]=_0x7417d1[_0x46e619('0x233')](0x1,_0x7417d1['length'])[_0x46e619('0x45a')](',');}break;case _0x46e619('0x1e70'):_0x5cde18[_0x46e619('0x1a7b')]['text']=_0x5cde18[_0x46e619('0x1a7b')]['appdata'];break;case'set':_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x4f0')]=_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x823')][_0x46e619('0x25c8')]('=')[0x0],_0x5cde18['close'][_0x46e619('0x18e0')]=_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x823')][_0x46e619('0x25c8')]('=')[0x1];break;case'agi':_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x2588')]=_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x823')];break;default:{const _0x3b3aa0=_0x5cde18['close'][_0x46e619('0x823')][_0x46e619('0x25c8')](',');_0x5cde18['close']['disposition']=_0x2cfb05()['isEmpty'](_0x3b3aa0[0x0])?_0x3b3aa0[0x0]:isNaN(_0x3b3aa0[0x0])?_0x3b3aa0[0x0]:parseInt(_0x3b3aa0[0x0],0xa);}break;}else{}_0x5cde18['close']['type']&&_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x1345')][_0x46e619('0x2574')]()===_0x46e619('0x587')&&_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x83f')][_0x46e619('0x2574')]()===_0x46e619('0x2884')&&(_0x5cde18['close'][_0x46e619('0x265a')]=_0x5cde18['close'][_0x46e619('0x2026')]?_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x2026')][_0x46e619('0x25c8')]('$')[0x0]:undefined,_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x1f02')]=_0x5cde18[_0x46e619('0x1a7b')][_0x46e619('0x992')]?_0x46e619('0xa4c')+_0x5cde18[_0x46e619('0x1a7b')]['callerID']:undefined);_0x5cde18[_0x46e619('0x3e2')]=_0x7ad9d2,_0x5cde18['closeDialog']=_0xfa45e8;function _0x7ad9d2(){const _0x2b7010=_0x46e619;_0x5cde18[_0x2b7010('0x61a')]=[];const _0x790e7d=[];_0x5cde18['close'][_0x2b7010('0x1345')]&&_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0x1345')]['toLowerCase']()===_0x2b7010('0x587')&&_0x5cde18[_0x2b7010('0x1a7b')]['appType']===_0x2b7010('0x867')&&(_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0x2026')]=_0x5d9c8c[_0x2b7010('0x2848')]?(_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0x265a')]||'')+_0x2b7010('0x881')+_0x5d9c8c[_0x2b7010('0x2848')]+'}':(_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0x265a')]||'')+_0x2b7010('0x1d1'),_0x5d9c8c['recordingFormat']!=='none'?_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0xd39')][_0x2b7010('0x2379')](_0x2b7010('0x1059'))<0x0&&(_0x5cde18['close'][_0x2b7010('0xd39')]+=_0x2b7010('0x1059')):_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0xd39')]=_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0xd39')][_0x2b7010('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0x83f')]&&_0x5cde18['close'][_0x2b7010('0x83f')]===_0x2b7010('0x2853')){}else switch((_0x5cde18[_0x2b7010('0x1a7b')]['app']||_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0x83f')])[_0x2b7010('0x2574')]()){case _0x2b7010('0xceb'):_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0x823')]=_0x5cde18['close'][_0x2b7010('0x4f0')]+'='+_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0x18e0')];break;case'custom':break;default:_0x790e7d[0x0]=_0x5cde18['close'][_0x2b7010('0x12e8')],_0x5cde18[_0x2b7010('0x1a7b')][_0x2b7010('0x823')]=_0x790e7d['join'](',');}_0xfa45e8(_0x5cde18[_0x2b7010('0x1a7b')]);}function _0xfa45e8(_0x19a93c){const _0x5ce79d=_0x46e619;_0x53eb5b[_0x5ce79d('0x1197')](_0x19a93c);}}const _0x354044=_0x1f91a6;_0x50b0a0[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'openchannelAccountApp',_0x36e6f4('0x77f'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x50b0a0(_0xe0297e,_0x2f6b5a,_0x28dcaa,_0x1402f6,_0x576873,_0x3bad60,_0xf5e2f0,_0x368352){const _0x3e283c=_0x36e6f4,_0x44b894=this;_0x44b894[_0x3e283c('0x98')]=_0xf5e2f0[_0x3e283c('0x26cd')](),_0x44b894[_0x3e283c('0x61a')]=[],_0x44b894['title']='OPENCHANNEL.EDIT_'+(_0x1402f6[_0x3e283c('0x83f')]||_0x1402f6[_0x3e283c('0x746')])['toUpperCase'](),_0x44b894[_0x3e283c('0xded')]=angular[_0x3e283c('0x225f')](_0x1402f6),_0x44b894[_0x3e283c('0x243c')]=_0x368352,_0x44b894['hasModulePermissions']={};if(_0x44b894['dialogflow'][_0x3e283c('0x823')])switch(_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x83f')]?_0x44b894[_0x3e283c('0xded')]['appType'][_0x3e283c('0x2574')]():_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x746')][_0x3e283c('0x2574')]()){case _0x3e283c('0x2853'):break;case'dialogflow':{const _0x56e6f1=_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x823')]['split'](',');_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x7ca')]=_0x56e6f1[0x0],_0x44b894[_0x3e283c('0xded')][_0x3e283c('0xedb')]=_0x56e6f1[0x1],_0x44b894['dialogflow'][_0x3e283c('0x1634')]=_0x56e6f1['slice'](0x2,_0x56e6f1[_0x3e283c('0x264b')])['join'](',');}break;case _0x3e283c('0x1636'):{const _0x50f3d9=_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x823')][_0x3e283c('0x25c8')](',');_0x44b894[_0x3e283c('0xded')]['projectId']=_0x50f3d9[0x0],_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x27f3')]=_0x50f3d9[0x1],_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x170e')]=_0x50f3d9[0x2],_0x44b894[_0x3e283c('0xded')][_0x3e283c('0xedb')]=_0x50f3d9[0x3],_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x1634')]=_0x50f3d9[_0x3e283c('0x233')](0x4,_0x50f3d9[_0x3e283c('0x264b')])[_0x3e283c('0x45a')](',');}break;case _0x3e283c('0x86c'):{const _0x733974=_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x823')][_0x3e283c('0x25c8')](',');_0x44b894['dialogflow']['accesskeyid']=_0x733974[0x0],_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x125')]=_0x733974[0x1],_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x25a2')]=_0x733974[0x2],_0x44b894['dialogflow'][_0x3e283c('0x1ac4')]=_0x733974[0x3],_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x1634')]=_0x733974['slice'](0x4,_0x733974[_0x3e283c('0x264b')])[_0x3e283c('0x45a')](',');}break;case'autoreply':{const _0xf8049e=_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x823')][_0x3e283c('0x25c8')](',');_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x265e')]=isNaN(_0xf8049e[0x0])?_0xf8049e[0x0]:parseInt(_0xf8049e[0x0],0xa),_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x1640')]=_0xf8049e['slice'](0x1,_0xf8049e[_0x3e283c('0x264b')])['join'](',');}break;case _0x3e283c('0x1e70'):_0x44b894['dialogflow'][_0x3e283c('0x1640')]=_0x44b894['dialogflow'][_0x3e283c('0x823')];break;case _0x3e283c('0xceb'):_0x44b894['dialogflow']['name']=_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x823')][_0x3e283c('0x25c8')]('=')[0x0],_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x18e0')]=_0x44b894['dialogflow']['appdata'][_0x3e283c('0x25c8')]('=')[0x1];break;case _0x3e283c('0x1034'):_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x2588')]=_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x823')];break;default:{const _0x31f9a0=_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x823')][_0x3e283c('0x25c8')](',');_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x7ca')]=_0x2cfb05()['isEmpty'](_0x31f9a0[0x0])?_0x31f9a0[0x0]:isNaN(_0x31f9a0[0x0])?_0x31f9a0[0x0]:parseInt(_0x31f9a0[0x0],0xa),_0x44b894[_0x3e283c('0xded')]['language']=_0x2cfb05()[_0x3e283c('0x1081')](_0x31f9a0[0x1])?_0x31f9a0[0x1]:isNaN(_0x31f9a0[0x1])?_0x31f9a0[0x1]:parseInt(_0x31f9a0[0x1],0xa),_0x44b894[_0x3e283c('0xded')]['welcomemessage']=_0x2cfb05()[_0x3e283c('0x1081')](_0x31f9a0[0x2])?_0x31f9a0[0x2]:isNaN(_0x31f9a0[0x2])?_0x31f9a0[0x2]:parseInt(_0x31f9a0[0x2],0xa);}break;}else _0x44b894['dialogflow'][_0x3e283c('0xedb')]='en';_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x1345')]&&_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x1345')][_0x3e283c('0x2574')]()===_0x3e283c('0x587')&&_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x83f')][_0x3e283c('0x2574')]()===_0x3e283c('0x2884')&&(_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x265a')]=_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x2026')]?_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x2026')][_0x3e283c('0x25c8')]('$')[0x0]:undefined,_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x1f02')]=_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x992')]?_0x3e283c('0xa4c')+_0x44b894[_0x3e283c('0xded')][_0x3e283c('0x992')]:undefined);_0x44b894['saveOpenchannelAccountApp']=_0x47a361,_0x44b894[_0x3e283c('0x24a0')]=_0x2446a5;function _0x47a361(){const _0x4dacb0=_0x3e283c;_0x44b894['errors']=[];const _0x32c7bc=[];_0x44b894[_0x4dacb0('0xded')]['type']&&_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0x1345')][_0x4dacb0('0x2574')]()===_0x4dacb0('0x587')&&_0x44b894['dialogflow'][_0x4dacb0('0x83f')]===_0x4dacb0('0x867')&&(_0x44b894[_0x4dacb0('0xded')]['phone']=_0x576873[_0x4dacb0('0x2848')]?(_0x44b894[_0x4dacb0('0xded')]['prefix']||'')+_0x4dacb0('0x881')+_0x576873['cutdigits']+'}':(_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0x265a')]||'')+_0x4dacb0('0x1d1'),_0x576873[_0x4dacb0('0x28cb')]!=='none'?_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0xd39')][_0x4dacb0('0x2379')](_0x4dacb0('0x1059'))<0x0&&(_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0xd39')]+=_0x4dacb0('0x1059')):_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0xd39')]=_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0xd39')]['replace'](_0x4dacb0('0x1059'),''));if(_0x44b894[_0x4dacb0('0xded')]['appType']&&_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0x83f')]===_0x4dacb0('0x2853')){}else switch((_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0x746')]||_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0x83f')])[_0x4dacb0('0x2574')]()){case _0x4dacb0('0xceb'):_0x44b894[_0x4dacb0('0xded')]['appdata']=_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0x4f0')]+'='+_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0x18e0')];break;case'custom':break;default:_0x32c7bc[0x0]=_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0x7ca')],_0x32c7bc[0x1]=_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0xedb')],_0x32c7bc[0x2]=_0x44b894['dialogflow']['welcomemessage'],_0x44b894[_0x4dacb0('0xded')][_0x4dacb0('0x823')]=_0x32c7bc[_0x4dacb0('0x45a')](',');}_0x2446a5(_0x44b894[_0x4dacb0('0xded')]);}function _0x2446a5(_0x28af8c){const _0x17ebab=_0x3e283c;_0xe0297e[_0x17ebab('0x1197')](_0x28af8c);}}const _0x1f3074=_0x50b0a0;_0x478d4f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'openchannelAccountApp','openchannelAccount',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x478d4f(_0x4350c1,_0x808c0,_0x525350,_0x40d638,_0x343ab2,_0x4bbd5b,_0x4dffc1,_0x288356){const _0x55e222=_0x36e6f4,_0x43fa36=this;_0x43fa36['currentUser']=_0x4dffc1[_0x55e222('0x26cd')](),_0x43fa36[_0x55e222('0x61a')]=[],_0x43fa36['title']=_0x55e222('0xf67')+(_0x40d638[_0x55e222('0x83f')]||_0x40d638[_0x55e222('0x746')])[_0x55e222('0x1387')](),_0x43fa36['gotoif']=angular[_0x55e222('0x225f')](_0x40d638),_0x43fa36['crudPermissions']=_0x288356,_0x43fa36[_0x55e222('0x128b')]={};if(_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x823')])switch(_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x83f')]?_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x83f')][_0x55e222('0x2574')]():_0x43fa36['gotoif'][_0x55e222('0x746')][_0x55e222('0x2574')]()){case _0x55e222('0x2853'):break;case _0x55e222('0xded'):{const _0xe147a=_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x823')][_0x55e222('0x25c8')](',');_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x7ca')]=_0xe147a[0x0],_0x43fa36['gotoif'][_0x55e222('0xedb')]=_0xe147a[0x1],_0x43fa36[_0x55e222('0x30f')]['welcomemessage']=_0xe147a[_0x55e222('0x233')](0x2,_0xe147a[_0x55e222('0x264b')])[_0x55e222('0x45a')](',');}break;case _0x55e222('0x1636'):{const _0x3965cf=_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x823')]['split'](',');_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x1b0a')]=_0x3965cf[0x0],_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x27f3')]=_0x3965cf[0x1],_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x170e')]=_0x3965cf[0x2],_0x43fa36[_0x55e222('0x30f')][_0x55e222('0xedb')]=_0x3965cf[0x3],_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x1634')]=_0x3965cf['slice'](0x4,_0x3965cf[_0x55e222('0x264b')])['join'](',');}break;case _0x55e222('0x86c'):{const _0x1e1980=_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x823')][_0x55e222('0x25c8')](',');_0x43fa36['gotoif'][_0x55e222('0xee6')]=_0x1e1980[0x0],_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x125')]=_0x1e1980[0x1],_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x25a2')]=_0x1e1980[0x2],_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x1ac4')]=_0x1e1980[0x3],_0x43fa36['gotoif'][_0x55e222('0x1634')]=_0x1e1980['slice'](0x4,_0x1e1980['length'])['join'](',');}break;case'autoreply':{const _0x3b6168=_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x823')]['split'](',');_0x43fa36['gotoif']['times']=isNaN(_0x3b6168[0x0])?_0x3b6168[0x0]:parseInt(_0x3b6168[0x0],0xa),_0x43fa36[_0x55e222('0x30f')]['text']=_0x3b6168[_0x55e222('0x233')](0x1,_0x3b6168[_0x55e222('0x264b')])[_0x55e222('0x45a')](',');}break;case'message':_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x1640')]=_0x43fa36['gotoif'][_0x55e222('0x823')];break;case _0x55e222('0xceb'):_0x43fa36['gotoif']['name']=_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x823')]['split']('=')[0x0],_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x18e0')]=_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x823')][_0x55e222('0x25c8')]('=')[0x1];break;case _0x55e222('0x1034'):_0x43fa36[_0x55e222('0x30f')]['project']=_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x823')];break;default:{const _0x223141=_0x43fa36['gotoif'][_0x55e222('0x823')][_0x55e222('0x25c8')](',');_0x43fa36[_0x55e222('0x30f')]['condition']=_0x2cfb05()[_0x55e222('0x1081')](_0x223141[0x0])?_0x223141[0x0]:isNaN(_0x223141[0x0])?_0x223141[0x0]:parseInt(_0x223141[0x0],0xa),_0x43fa36[_0x55e222('0x30f')]['truepriority']=_0x2cfb05()['isEmpty'](_0x223141[0x1])?_0x223141[0x1]:isNaN(_0x223141[0x1])?_0x223141[0x1]:parseInt(_0x223141[0x1],0xa),_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x1d7a')]=_0x2cfb05()['isEmpty'](_0x223141[0x2])?_0x223141[0x2]:isNaN(_0x223141[0x2])?_0x223141[0x2]:parseInt(_0x223141[0x2],0xa);}break;}else{}_0x43fa36['gotoif'][_0x55e222('0x1345')]&&_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x1345')]['toLowerCase']()===_0x55e222('0x587')&&_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x83f')][_0x55e222('0x2574')]()===_0x55e222('0x2884')&&(_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x265a')]=_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x2026')]?_0x43fa36['gotoif'][_0x55e222('0x2026')][_0x55e222('0x25c8')]('$')[0x0]:undefined,_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x1f02')]=_0x43fa36['gotoif'][_0x55e222('0x992')]?_0x55e222('0xa4c')+_0x43fa36[_0x55e222('0x30f')][_0x55e222('0x992')]:undefined);_0x43fa36[_0x55e222('0x3e2')]=_0x20617b,_0x43fa36[_0x55e222('0x24a0')]=_0x573589;function _0x20617b(){const _0x1e965c=_0x55e222;_0x43fa36[_0x1e965c('0x61a')]=[];const _0x14af0e=[];_0x43fa36['gotoif'][_0x1e965c('0x1345')]&&_0x43fa36[_0x1e965c('0x30f')]['type'][_0x1e965c('0x2574')]()===_0x1e965c('0x587')&&_0x43fa36[_0x1e965c('0x30f')]['appType']===_0x1e965c('0x867')&&(_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0x2026')]=_0x343ab2[_0x1e965c('0x2848')]?(_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0x265a')]||'')+_0x1e965c('0x881')+_0x343ab2[_0x1e965c('0x2848')]+'}':(_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0x265a')]||'')+_0x1e965c('0x1d1'),_0x343ab2[_0x1e965c('0x28cb')]!==_0x1e965c('0x192')?_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0xd39')][_0x1e965c('0x2379')](_0x1e965c('0x1059'))<0x0&&(_0x43fa36['gotoif'][_0x1e965c('0xd39')]+=_0x1e965c('0x1059')):_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0xd39')]=_0x43fa36['gotoif']['options'][_0x1e965c('0xf3')](_0x1e965c('0x1059'),''));if(_0x43fa36[_0x1e965c('0x30f')]['appType']&&_0x43fa36['gotoif']['appType']==='custom'){}else switch((_0x43fa36['gotoif'][_0x1e965c('0x746')]||_0x43fa36['gotoif'][_0x1e965c('0x83f')])['toLowerCase']()){case _0x1e965c('0xceb'):_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0x823')]=_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0x4f0')]+'='+_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0x18e0')];break;case _0x1e965c('0x2853'):break;default:_0x14af0e[0x0]=_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0x8ff')],_0x14af0e[0x1]=_0x43fa36['gotoif'][_0x1e965c('0x13a6')],_0x14af0e[0x2]=_0x43fa36[_0x1e965c('0x30f')][_0x1e965c('0x1d7a')],_0x43fa36['gotoif'][_0x1e965c('0x823')]=_0x14af0e['join'](',');}_0x573589(_0x43fa36[_0x1e965c('0x30f')]);}function _0x573589(_0x1be4b7){_0x4350c1['hide'](_0x1be4b7);}}const _0x436ffb=_0x478d4f;_0x49ba89[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x248f'),'openchannelAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x49ba89(_0x221f2c,_0x25c7a4,_0x2823df,_0x297aa3,_0x2e7f97,_0x39dfab,_0x5e4142,_0x27d56e){const _0x58db81=_0x36e6f4,_0x5965b5=this;_0x5965b5['currentUser']=_0x5e4142[_0x58db81('0x26cd')](),_0x5965b5[_0x58db81('0x61a')]=[],_0x5965b5[_0x58db81('0xcdc')]='OPENCHANNEL.EDIT_'+(_0x297aa3['appType']||_0x297aa3['app'])[_0x58db81('0x1387')](),_0x5965b5['gotop']=angular[_0x58db81('0x225f')](_0x297aa3),_0x5965b5[_0x58db81('0x243c')]=_0x27d56e,_0x5965b5[_0x58db81('0x128b')]={};if(_0x5965b5['gotop'][_0x58db81('0x823')])switch(_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x83f')]?_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x83f')]['toLowerCase']():_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x746')]['toLowerCase']()){case _0x58db81('0x2853'):break;case _0x58db81('0xded'):{const _0x538e80=_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x823')][_0x58db81('0x25c8')](',');_0x5965b5['gotop']['key']=_0x538e80[0x0],_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0xedb')]=_0x538e80[0x1],_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x1634')]=_0x538e80[_0x58db81('0x233')](0x2,_0x538e80[_0x58db81('0x264b')])['join'](',');}break;case'dialogflowv2':{const _0x245fe8=_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x823')][_0x58db81('0x25c8')](',');_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x1b0a')]=_0x245fe8[0x0],_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x27f3')]=_0x245fe8[0x1],_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x170e')]=_0x245fe8[0x2],_0x5965b5['gotop']['language']=_0x245fe8[0x3],_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x1634')]=_0x245fe8['slice'](0x4,_0x245fe8[_0x58db81('0x264b')])[_0x58db81('0x45a')](',');}break;case _0x58db81('0x86c'):{const _0x311557=_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x823')][_0x58db81('0x25c8')](',');_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0xee6')]=_0x311557[0x0],_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x125')]=_0x311557[0x1],_0x5965b5['gotop'][_0x58db81('0x25a2')]=_0x311557[0x2],_0x5965b5[_0x58db81('0x6e6')]['botname']=_0x311557[0x3],_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x1634')]=_0x311557[_0x58db81('0x233')](0x4,_0x311557[_0x58db81('0x264b')])[_0x58db81('0x45a')](',');}break;case _0x58db81('0x1af7'):{const _0x442c85=_0x5965b5[_0x58db81('0x6e6')]['appdata'][_0x58db81('0x25c8')](',');_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x265e')]=isNaN(_0x442c85[0x0])?_0x442c85[0x0]:parseInt(_0x442c85[0x0],0xa),_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x1640')]=_0x442c85['slice'](0x1,_0x442c85[_0x58db81('0x264b')])[_0x58db81('0x45a')](',');}break;case _0x58db81('0x1e70'):_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x1640')]=_0x5965b5[_0x58db81('0x6e6')]['appdata'];break;case _0x58db81('0xceb'):_0x5965b5[_0x58db81('0x6e6')]['name']=_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x823')]['split']('=')[0x0],_0x5965b5[_0x58db81('0x6e6')]['value']=_0x5965b5['gotop']['appdata'][_0x58db81('0x25c8')]('=')[0x1];break;case'agi':_0x5965b5[_0x58db81('0x6e6')]['project']=_0x5965b5['gotop'][_0x58db81('0x823')];break;default:{const _0x1b450d=_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x823')][_0x58db81('0x25c8')](',');_0x5965b5[_0x58db81('0x6e6')]['priority']=_0x2cfb05()[_0x58db81('0x1081')](_0x1b450d[0x0])?_0x1b450d[0x0]:isNaN(_0x1b450d[0x0])?_0x1b450d[0x0]:parseInt(_0x1b450d[0x0],0xa);}break;}else{}_0x5965b5['gotop'][_0x58db81('0x1345')]&&_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x1345')]['toLowerCase']()==='outbound'&&_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x83f')][_0x58db81('0x2574')]()==='outbounddial'&&(_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x265a')]=_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x2026')]?_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x2026')][_0x58db81('0x25c8')]('$')[0x0]:undefined,_0x5965b5[_0x58db81('0x6e6')][_0x58db81('0x1f02')]=_0x5965b5['gotop']['callerID']?'CALLERID(all)='+_0x5965b5['gotop'][_0x58db81('0x992')]:undefined);_0x5965b5[_0x58db81('0x3e2')]=_0x9545d0,_0x5965b5['closeDialog']=_0x160566;function _0x9545d0(){const _0x45d660=_0x58db81;_0x5965b5[_0x45d660('0x61a')]=[];const _0x706c3f=[];_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0x1345')]&&_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0x1345')][_0x45d660('0x2574')]()===_0x45d660('0x587')&&_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0x83f')]===_0x45d660('0x867')&&(_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0x2026')]=_0x2e7f97[_0x45d660('0x2848')]?(_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0x265a')]||'')+_0x45d660('0x881')+_0x2e7f97[_0x45d660('0x2848')]+'}':(_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0x265a')]||'')+_0x45d660('0x1d1'),_0x2e7f97[_0x45d660('0x28cb')]!==_0x45d660('0x192')?_0x5965b5['gotop'][_0x45d660('0xd39')][_0x45d660('0x2379')](_0x45d660('0x1059'))<0x0&&(_0x5965b5[_0x45d660('0x6e6')]['options']+=_0x45d660('0x1059')):_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0xd39')]=_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0xd39')][_0x45d660('0xf3')](_0x45d660('0x1059'),''));if(_0x5965b5['gotop']['appType']&&_0x5965b5['gotop'][_0x45d660('0x83f')]==='custom'){}else switch((_0x5965b5[_0x45d660('0x6e6')]['app']||_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0x83f')])[_0x45d660('0x2574')]()){case _0x45d660('0xceb'):_0x5965b5[_0x45d660('0x6e6')]['appdata']=_0x5965b5[_0x45d660('0x6e6')]['name']+'='+_0x5965b5[_0x45d660('0x6e6')][_0x45d660('0x18e0')];break;case'custom':break;default:_0x706c3f[0x0]=_0x5965b5['gotop'][_0x45d660('0xfde')],_0x5965b5['gotop'][_0x45d660('0x823')]=_0x706c3f['join'](',');}_0x160566(_0x5965b5[_0x45d660('0x6e6')]);}function _0x160566(_0x25632e){_0x221f2c['hide'](_0x25632e);}}const _0x29d581=_0x49ba89;_0x1c261b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x265d'),_0x36e6f4('0x25d0'),_0x36e6f4('0x124d'),_0x36e6f4('0x277c'),_0x36e6f4('0x164e'),'toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x1c261b(_0x355d98,_0x3e3f1d,_0x3b8d93,_0x3f6903,_0x3a300e,_0x5ab9cb,_0x541085,_0x125fae,_0x427f2f,_0x1f1361){const _0x55dcbf=_0x36e6f4,_0x2088a7=this;_0x2088a7[_0x55dcbf('0x98')]=_0x427f2f['getCurrentUser'](),_0x2088a7['errors']=[],_0x2088a7[_0x55dcbf('0xcdc')]='TOOLS.EDIT_INTERVAL',_0x2088a7[_0x55dcbf('0x277c')]=angular[_0x55dcbf('0x225f')](_0x3a300e),_0x2088a7[_0x55dcbf('0x164e')]=_0x5ab9cb,_0x2088a7[_0x55dcbf('0x99d')]=![],_0x2088a7[_0x55dcbf('0x6aa')]=['always',_0x55dcbf('0x2853'),_0x55dcbf('0x1480')],_0x2088a7[_0x55dcbf('0x243c')]=_0x1f1361,_0x2088a7['daysOfWeek']=_0x3f6903[_0x55dcbf('0x28de')](),_0x2088a7['monthNumber']=_0x3f6903['getMonthNumber'](),_0x2088a7[_0x55dcbf('0x2259')]=_0x3f6903[_0x55dcbf('0x1c39')](),_0x2088a7[_0x55dcbf('0x1fc0')]=_0x3f6903[_0x55dcbf('0x2489')]();if(!_0x2088a7[_0x55dcbf('0x277c')])_0x2088a7['interval']={'interval':_0x55dcbf('0x16f')},_0x2088a7[_0x55dcbf('0x1345')]='always',_0x2088a7[_0x55dcbf('0xcdc')]=_0x55dcbf('0x412'),_0x2088a7[_0x55dcbf('0x99d')]=!![];else{if(_0x2088a7['interval']['interval']!==_0x55dcbf('0x16f')){_0x2088a7[_0x55dcbf('0x1345')]='custom';const _0x5c54aa=_0x2088a7['interval'][_0x55dcbf('0x277c')][_0x55dcbf('0x25c8')](','),_0x5c1025=_0x5c54aa[0x0],_0x5edebf=_0x5c54aa[0x1],_0x4bc3c8=_0x5c54aa[0x2],_0x207a3a=_0x5c54aa[0x3];if(_0x5c1025!=='*'){const _0xd81748=_0x5c1025['split']('-')[0x0],_0x2c87d8=_0x5c1025[_0x55dcbf('0x25c8')]('-')[0x1];let _0x474126;_0x474126=new Date(),_0x474126[_0x55dcbf('0xe24')](Number(_0xd81748[_0x55dcbf('0x25c8')](':')[0x0])),_0x474126[_0x55dcbf('0x790')](Number(_0xd81748[_0x55dcbf('0x25c8')](':')[0x1])),_0x2088a7[_0x55dcbf('0x64d')]=_0x474126,_0x474126=new Date(),_0x474126[_0x55dcbf('0xe24')](Number(_0x2c87d8[_0x55dcbf('0x25c8')](':')[0x0])),_0x474126[_0x55dcbf('0x790')](Number(_0x2c87d8['split'](':')[0x1])),_0x2088a7[_0x55dcbf('0x2076')]=_0x474126;}_0x5edebf!=='*'&&(_0x2088a7['dayOfWeekFrom']=_0x5edebf['split']('-')[0x0],_0x2088a7[_0x55dcbf('0x1b81')]=_0x5edebf[_0x55dcbf('0x25c8')]('-')[0x1]),_0x4bc3c8!=='*'&&(_0x2088a7[_0x55dcbf('0x103d')]=_0x4bc3c8[_0x55dcbf('0x25c8')]('-')[0x0],_0x2088a7[_0x55dcbf('0x1dbb')]=_0x4bc3c8['split']('-')[0x1]),_0x207a3a!=='*'&&(_0x2088a7['monthFrom']=_0x207a3a[_0x55dcbf('0x25c8')]('-')[0x0],_0x2088a7[_0x55dcbf('0x1125')]=_0x207a3a[_0x55dcbf('0x25c8')]('-')[0x1]);}else _0x2088a7['type']='always';}_0x355d98['params']['id']&&!_0x2088a7[_0x55dcbf('0x277c')][_0x55dcbf('0x50d')]&&(_0x2088a7[_0x55dcbf('0x277c')][_0x55dcbf('0x186f')]=_0x355d98[_0x55dcbf('0x23f')]['id']);_0x2088a7[_0x55dcbf('0x277c')][_0x55dcbf('0x186f')]&&_0x2088a7[_0x55dcbf('0x277c')][_0x55dcbf('0x50d')]&&(_0x2088a7[_0x55dcbf('0x1345')]='list');_0x2088a7['addNewInterval']=_0x5d4647,_0x2088a7[_0x55dcbf('0x24be')]=_0x43cfe5,_0x2088a7[_0x55dcbf('0x24a0')]=_0x1a50be;_0x2088a7[_0x55dcbf('0x277c')][_0x55dcbf('0x50d')]&&(_0x427f2f[_0x55dcbf('0x1ac6')]('admin')?_0x125fae[_0x55dcbf('0x277c')][_0x55dcbf('0xd83')]({'fields':_0x55dcbf('0xd0a'),'IntervalId':_0x55dcbf('0x15d7'),'nolimit':!![]})['$promise'][_0x55dcbf('0x1166')](function(_0xc91171){_0x2088a7['intervals']=_0xc91171['rows']||[];})[_0x55dcbf('0x1a80')](function(_0x4b2c1b){const _0x2797a1=_0x55dcbf;_0x541085[_0x2797a1('0xfc9')]({'title':_0x4b2c1b[_0x2797a1('0x52d')]?_0x2797a1('0x1e21')+_0x4b2c1b['status']+'\x20-\x20'+_0x4b2c1b[_0x2797a1('0xe1b')]:'SYSTEM:GET_INTERVALS','msg':_0x4b2c1b[_0x2797a1('0x25f4')]?JSON['stringify'](_0x4b2c1b[_0x2797a1('0x25f4')]):_0x4b2c1b['toString']()});}):_0x125fae[_0x55dcbf('0x277c')][_0x55dcbf('0xd83')]({'fields':_0x55dcbf('0xd0a'),'IntervalId':'null','nolimit':!![]})['$promise']['then'](function(_0x9bada5){const _0x248597=_0x55dcbf;_0x2088a7[_0x248597('0x164e')]=_0x9bada5[_0x248597('0x269a')]||[];})[_0x55dcbf('0x1166')](function(){const _0x53ac0f=_0x55dcbf;return _0x125fae['userProfileSection']['get']({'userProfileId':_0x2088a7[_0x53ac0f('0x98')][_0x53ac0f('0xb86')],'sectionId':0x3ec})[_0x53ac0f('0xa44')];})['then'](function(_0x5b2b59){const _0x1291ef=_0x55dcbf,_0x3960b3=_0x5b2b59&&_0x5b2b59[_0x1291ef('0x269a')]?_0x5b2b59[_0x1291ef('0x269a')][0x0]:null;if(!_0x3960b3)_0x2088a7['intervals']=[];else{if(!_0x3960b3[_0x1291ef('0x1a2b')])return _0x125fae[_0x1291ef('0x4b5')][_0x1291ef('0xd83')]({'sectionId':_0x3960b3['id']})['$promise'][_0x1291ef('0x1166')](function(_0x351124){const _0x46bb1b=_0x1291ef,_0x428626=_0x351124&&_0x351124[_0x46bb1b('0x269a')]?_0x351124[_0x46bb1b('0x269a')]:[],_0x131360=[];let _0x492f7d=null;_0x2088a7[_0x46bb1b('0x277c')]&&(_0x492f7d=_0x2cfb05()[_0x46bb1b('0xc38')](_0x2088a7[_0x46bb1b('0x164e')],{'name':_0x2088a7['interval']['IntervalId']})),_0x492f7d&&!_0x2cfb05()[_0x46bb1b('0x1798')](_0x428626,[_0x46bb1b('0x24e8'),_0x492f7d['id']])&&_0x2088a7[_0x46bb1b('0x164e')][_0x46bb1b('0x2782')](function(_0x80976){const _0x4de47b=_0x46bb1b;_0x80976['id']===_0x492f7d['id']&&(_0x80976[_0x4de47b('0x2378')]=![],_0x131360[_0x4de47b('0x1514')](_0x80976));}),_0x2088a7[_0x46bb1b('0x164e')]=_0x131360;});}})[_0x55dcbf('0x1a80')](function(_0x10ba26){const _0x1d4e3b=_0x55dcbf;_0x541085[_0x1d4e3b('0xfc9')]({'title':_0x10ba26[_0x1d4e3b('0x52d')]?'API:'+_0x10ba26[_0x1d4e3b('0x52d')]+_0x1d4e3b('0x11e1')+_0x10ba26['statusText']:'SYSTEM:GET_INTERVALS','msg':_0x10ba26['data']?JSON[_0x1d4e3b('0xbac')](_0x10ba26['data']):_0x10ba26[_0x1d4e3b('0x1586')]()});}));function _0x303ede(){const _0x968ff2=_0x55dcbf;switch(_0x2088a7[_0x968ff2('0x1345')]){case'always':case _0x968ff2('0x1480'):return'*,*,*,*';case'custom':{const _0x3b8307=[];if(_0x2088a7[_0x968ff2('0x64d')]!=='*'&&_0x2088a7[_0x968ff2('0x64d')]&&_0x2088a7[_0x968ff2('0x2076')]){const _0x5d9150=(_0x2088a7[_0x968ff2('0x64d')][_0x968ff2('0x11fe')]()<0xa?'0':'')+_0x2088a7[_0x968ff2('0x64d')][_0x968ff2('0x11fe')]()+':'+((_0x2088a7[_0x968ff2('0x64d')][_0x968ff2('0x234')]()<0xa?'0':'')+_0x2088a7[_0x968ff2('0x64d')][_0x968ff2('0x234')]()),_0x27a166=(_0x2088a7[_0x968ff2('0x2076')][_0x968ff2('0x11fe')]()<0xa?'0':'')+_0x2088a7[_0x968ff2('0x2076')][_0x968ff2('0x11fe')]()+':'+((_0x2088a7[_0x968ff2('0x2076')]['getMinutes']()<0xa?'0':'')+_0x2088a7[_0x968ff2('0x2076')][_0x968ff2('0x234')]());_0x3b8307[_0x968ff2('0x1514')](_0x5d9150+'-'+_0x27a166);}else _0x3b8307[_0x968ff2('0x1514')]('*');return _0x2088a7[_0x968ff2('0x1eca')]?_0x2088a7[_0x968ff2('0x1b81')]?_0x3b8307[_0x968ff2('0x1514')](_0x2088a7['dayOfWeekFrom']+'-'+_0x2088a7[_0x968ff2('0x1b81')]):_0x3b8307[_0x968ff2('0x1514')](_0x2088a7[_0x968ff2('0x1eca')]):_0x3b8307[_0x968ff2('0x1514')]('*'),_0x2088a7['monthDayFrom']?_0x2088a7[_0x968ff2('0x1dbb')]?_0x3b8307[_0x968ff2('0x1514')](_0x2088a7[_0x968ff2('0x103d')]+'-'+_0x2088a7[_0x968ff2('0x1dbb')]):_0x3b8307[_0x968ff2('0x1514')](_0x2088a7[_0x968ff2('0x103d')]):_0x3b8307[_0x968ff2('0x1514')]('*'),_0x2088a7[_0x968ff2('0xdec')]?_0x2088a7[_0x968ff2('0x1125')]?_0x3b8307[_0x968ff2('0x1514')](_0x2088a7[_0x968ff2('0xdec')]+'-'+_0x2088a7[_0x968ff2('0x1125')]):_0x3b8307['push'](_0x2088a7[_0x968ff2('0xdec')]):_0x3b8307[_0x968ff2('0x1514')]('*'),_0x3b8307[_0x968ff2('0x45a')]();}}}function _0x5d4647(){const _0x5ea53e=_0x55dcbf;_0x2088a7[_0x5ea53e('0x61a')]=[],_0x2088a7[_0x5ea53e('0x277c')]['interval']=_0x303ede(),_0x125fae['interval']['save'](_0x2088a7[_0x5ea53e('0x277c')])['$promise']['then'](function(_0x27037e){const _0x24e5e6=_0x5ea53e;_0x2088a7[_0x24e5e6('0x164e')][_0x24e5e6('0x1514')](_0x27037e),_0x541085[_0x24e5e6('0x103b')]({'title':_0x24e5e6('0xf10'),'msg':_0x2088a7[_0x24e5e6('0x277c')][_0x24e5e6('0x4f0')]?_0x2088a7[_0x24e5e6('0x277c')]['name']+_0x24e5e6('0x1eda'):''}),_0x1a50be();})['catch'](function(_0x359f16){const _0x7094d2=_0x5ea53e;console[_0x7094d2('0xfc9')](_0x359f16),_0x2088a7[_0x7094d2('0x61a')]=_0x359f16['data'][_0x7094d2('0x61a')]||[{'message':_0x359f16[_0x7094d2('0x1586')](),'type':'api.interval.save'}];});}function _0x43cfe5(){const _0xdc2d8d=_0x55dcbf;_0x2088a7[_0xdc2d8d('0x61a')]=[],_0x2088a7[_0xdc2d8d('0x277c')][_0xdc2d8d('0x277c')]=_0x303ede(),_0x2088a7[_0xdc2d8d('0x277c')][_0xdc2d8d('0x50d')]?(_0x2088a7[_0xdc2d8d('0x1345')]!==_0xdc2d8d('0x1480')&&(_0x2088a7['interval'][_0xdc2d8d('0x186f')]=null),_0x1a50be(_0x2088a7[_0xdc2d8d('0x277c')])):_0x125fae['interval'][_0xdc2d8d('0x1449')]({'id':_0x2088a7['interval']['id']},_0x2088a7['interval'])[_0xdc2d8d('0xa44')][_0xdc2d8d('0x1166')](function(_0x123579){const _0x44b52c=_0xdc2d8d,_0x2a360d=_0x2cfb05()['find'](_0x2088a7['intervals'],{'id':_0x123579['id']});_0x2a360d&&_0x2cfb05()[_0x44b52c('0xcc3')](_0x2a360d,_0x123579),_0x541085[_0x44b52c('0x103b')]({'title':'Interval\x20properly\x20saved!','msg':_0x44b52c('0x1666')}),_0x1a50be();})[_0xdc2d8d('0x1a80')](function(_0x4eb3a0){const _0x222aa3=_0xdc2d8d;console['error'](_0x4eb3a0),_0x2088a7['errors']=_0x4eb3a0['data'][_0x222aa3('0x61a')]||[{'message':_0x4eb3a0['toString'](),'type':_0x222aa3('0x2725')}];});}function _0x1a50be(_0x23951e){const _0x2e9771=_0x55dcbf;_0x3e3f1d[_0x2e9771('0x1197')](_0x23951e);}}const _0x55a911=_0x1c261b;_0x2539c4[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x248f'),'openchannelAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x2539c4(_0x1dac4d,_0x307778,_0x3d295d,_0x3f3acb,_0xb68bb6,_0x341a3e,_0x27b5a2,_0x4a1461){const _0x1fdbf3=_0x36e6f4,_0x10cd09=this;_0x10cd09[_0x1fdbf3('0x98')]=_0x27b5a2[_0x1fdbf3('0x26cd')](),_0x10cd09['errors']=[],_0x10cd09[_0x1fdbf3('0xcdc')]='OPENCHANNEL.EDIT_'+(_0x3f3acb[_0x1fdbf3('0x83f')]||_0x3f3acb[_0x1fdbf3('0x746')])['toUpperCase'](),_0x10cd09[_0x1fdbf3('0x2652')]=angular[_0x1fdbf3('0x225f')](_0x3f3acb),_0x10cd09[_0x1fdbf3('0x243c')]=_0x4a1461,_0x10cd09[_0x1fdbf3('0x128b')]={};if(_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x823')])switch(_0x10cd09['noop'][_0x1fdbf3('0x83f')]?_0x10cd09['noop'][_0x1fdbf3('0x83f')][_0x1fdbf3('0x2574')]():_0x10cd09['noop'][_0x1fdbf3('0x746')][_0x1fdbf3('0x2574')]()){case _0x1fdbf3('0x2853'):break;case'dialogflow':{const _0x2f520f=_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x823')][_0x1fdbf3('0x25c8')](',');_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x7ca')]=_0x2f520f[0x0],_0x10cd09[_0x1fdbf3('0x2652')]['language']=_0x2f520f[0x1],_0x10cd09[_0x1fdbf3('0x2652')]['welcomemessage']=_0x2f520f[_0x1fdbf3('0x233')](0x2,_0x2f520f[_0x1fdbf3('0x264b')])[_0x1fdbf3('0x45a')](',');}break;case _0x1fdbf3('0x1636'):{const _0x38ea6d=_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x823')]['split'](',');_0x10cd09['noop']['projectId']=_0x38ea6d[0x0],_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x27f3')]=_0x38ea6d[0x1],_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x170e')]=_0x38ea6d[0x2],_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0xedb')]=_0x38ea6d[0x3],_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x1634')]=_0x38ea6d[_0x1fdbf3('0x233')](0x4,_0x38ea6d[_0x1fdbf3('0x264b')])[_0x1fdbf3('0x45a')](',');}break;case _0x1fdbf3('0x86c'):{const _0x39a49e=_0x10cd09['noop'][_0x1fdbf3('0x823')][_0x1fdbf3('0x25c8')](',');_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0xee6')]=_0x39a49e[0x0],_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x125')]=_0x39a49e[0x1],_0x10cd09['noop'][_0x1fdbf3('0x25a2')]=_0x39a49e[0x2],_0x10cd09['noop']['botname']=_0x39a49e[0x3],_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x1634')]=_0x39a49e[_0x1fdbf3('0x233')](0x4,_0x39a49e[_0x1fdbf3('0x264b')])['join'](',');}break;case'autoreply':{const _0x52b20a=_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x823')][_0x1fdbf3('0x25c8')](',');_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x265e')]=isNaN(_0x52b20a[0x0])?_0x52b20a[0x0]:parseInt(_0x52b20a[0x0],0xa),_0x10cd09['noop'][_0x1fdbf3('0x1640')]=_0x52b20a[_0x1fdbf3('0x233')](0x1,_0x52b20a[_0x1fdbf3('0x264b')])[_0x1fdbf3('0x45a')](',');}break;case'message':_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x1640')]=_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x823')];break;case _0x1fdbf3('0xceb'):_0x10cd09[_0x1fdbf3('0x2652')]['name']=_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x823')][_0x1fdbf3('0x25c8')]('=')[0x0],_0x10cd09['noop'][_0x1fdbf3('0x18e0')]=_0x10cd09[_0x1fdbf3('0x2652')]['appdata'][_0x1fdbf3('0x25c8')]('=')[0x1];break;case _0x1fdbf3('0x1034'):_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x2588')]=_0x10cd09['noop'][_0x1fdbf3('0x823')];break;default:{const _0x3cf9ff=_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x823')][_0x1fdbf3('0x25c8')](',');_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x18e0')]=_0x2cfb05()[_0x1fdbf3('0x1081')](_0x3cf9ff[0x0])?_0x3cf9ff[0x0]:isNaN(_0x3cf9ff[0x0])?_0x3cf9ff[0x0]:parseInt(_0x3cf9ff[0x0],0xa);}break;}else{}_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x1345')]&&_0x10cd09['noop'][_0x1fdbf3('0x1345')][_0x1fdbf3('0x2574')]()===_0x1fdbf3('0x587')&&_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x83f')][_0x1fdbf3('0x2574')]()===_0x1fdbf3('0x2884')&&(_0x10cd09[_0x1fdbf3('0x2652')]['prefix']=_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x2026')]?_0x10cd09[_0x1fdbf3('0x2652')]['phone'][_0x1fdbf3('0x25c8')]('$')[0x0]:undefined,_0x10cd09['noop'][_0x1fdbf3('0x1f02')]=_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x992')]?'CALLERID(all)='+_0x10cd09[_0x1fdbf3('0x2652')][_0x1fdbf3('0x992')]:undefined);_0x10cd09[_0x1fdbf3('0x3e2')]=_0xa60e13,_0x10cd09['closeDialog']=_0x4d7426;function _0xa60e13(){const _0x9e88e=_0x1fdbf3;_0x10cd09[_0x9e88e('0x61a')]=[];const _0x2efd67=[];_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x1345')]&&_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x1345')][_0x9e88e('0x2574')]()===_0x9e88e('0x587')&&_0x10cd09['noop'][_0x9e88e('0x83f')]==='outboundDial'&&(_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x2026')]=_0xb68bb6[_0x9e88e('0x2848')]?(_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x265a')]||'')+_0x9e88e('0x881')+_0xb68bb6[_0x9e88e('0x2848')]+'}':(_0x10cd09['noop'][_0x9e88e('0x265a')]||'')+_0x9e88e('0x1d1'),_0xb68bb6[_0x9e88e('0x28cb')]!==_0x9e88e('0x192')?_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0xd39')][_0x9e88e('0x2379')](_0x9e88e('0x1059'))<0x0&&(_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0xd39')]+=_0x9e88e('0x1059')):_0x10cd09['noop'][_0x9e88e('0xd39')]=_0x10cd09['noop'][_0x9e88e('0xd39')][_0x9e88e('0xf3')](_0x9e88e('0x1059'),''));if(_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x83f')]&&_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x83f')]===_0x9e88e('0x2853')){}else switch((_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x746')]||_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x83f')])[_0x9e88e('0x2574')]()){case'set':_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x823')]=_0x10cd09[_0x9e88e('0x2652')]['name']+'='+_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x18e0')];break;case _0x9e88e('0x2853'):break;default:_0x2efd67[0x0]=_0x10cd09[_0x9e88e('0x2652')]['value'],_0x10cd09[_0x9e88e('0x2652')][_0x9e88e('0x823')]=_0x2efd67[_0x9e88e('0x45a')](',');}_0x4d7426(_0x10cd09['noop']);}function _0x4d7426(_0x4c229d){const _0x4060da=_0x1fdbf3;_0x1dac4d[_0x4060da('0x1197')](_0x4c229d);}}const _0x53ede9=_0x2539c4;_0x52abba[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x248f'),'openchannelAccount','api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x52abba(_0x41cd27,_0x53c89c,_0x2bb457,_0x5c167c,_0xc1e48,_0x37465d,_0x36b03b,_0x3e6df3){const _0x5be535=_0x36e6f4,_0x2585f7=this;_0x2585f7[_0x5be535('0x98')]=_0x36b03b[_0x5be535('0x26cd')](),_0x2585f7[_0x5be535('0x61a')]=[],_0x2585f7[_0x5be535('0xcdc')]=_0x5be535('0xf67')+(_0x5c167c[_0x5be535('0x83f')]||_0x5c167c[_0x5be535('0x746')])[_0x5be535('0x1387')](),_0x2585f7[_0x5be535('0x1d3e')]=angular[_0x5be535('0x225f')](_0x5c167c),_0x2585f7['crudPermissions']=_0x3e6df3,_0x2585f7[_0x5be535('0x128b')]={};if(_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x823')])switch(_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x83f')]?_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x83f')][_0x5be535('0x2574')]():_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x746')][_0x5be535('0x2574')]()){case _0x5be535('0x2853'):break;case'dialogflow':{const _0x197214=_0x2585f7['queue'][_0x5be535('0x823')][_0x5be535('0x25c8')](',');_0x2585f7['queue'][_0x5be535('0x7ca')]=_0x197214[0x0],_0x2585f7['queue'][_0x5be535('0xedb')]=_0x197214[0x1],_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x1634')]=_0x197214[_0x5be535('0x233')](0x2,_0x197214[_0x5be535('0x264b')])[_0x5be535('0x45a')](',');}break;case _0x5be535('0x1636'):{const _0x48140c=_0x2585f7['queue'][_0x5be535('0x823')][_0x5be535('0x25c8')](',');_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x1b0a')]=_0x48140c[0x0],_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x27f3')]=_0x48140c[0x1],_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x170e')]=_0x48140c[0x2],_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0xedb')]=_0x48140c[0x3],_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x1634')]=_0x48140c['slice'](0x4,_0x48140c[_0x5be535('0x264b')])[_0x5be535('0x45a')](',');}break;case _0x5be535('0x86c'):{const _0x3a8c28=_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x823')][_0x5be535('0x25c8')](',');_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0xee6')]=_0x3a8c28[0x0],_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x125')]=_0x3a8c28[0x1],_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x25a2')]=_0x3a8c28[0x2],_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x1ac4')]=_0x3a8c28[0x3],_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x1634')]=_0x3a8c28[_0x5be535('0x233')](0x4,_0x3a8c28[_0x5be535('0x264b')])[_0x5be535('0x45a')](',');}break;case _0x5be535('0x1af7'):{const _0x2699e2=_0x2585f7['queue'][_0x5be535('0x823')][_0x5be535('0x25c8')](',');_0x2585f7[_0x5be535('0x1d3e')]['times']=isNaN(_0x2699e2[0x0])?_0x2699e2[0x0]:parseInt(_0x2699e2[0x0],0xa),_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x1640')]=_0x2699e2[_0x5be535('0x233')](0x1,_0x2699e2['length'])[_0x5be535('0x45a')](',');}break;case _0x5be535('0x1e70'):_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x1640')]=_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x823')];break;case _0x5be535('0xceb'):_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x4f0')]=_0x2585f7[_0x5be535('0x1d3e')]['appdata']['split']('=')[0x0],_0x2585f7[_0x5be535('0x1d3e')]['value']=_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x823')][_0x5be535('0x25c8')]('=')[0x1];break;case _0x5be535('0x1034'):_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x2588')]=_0x2585f7[_0x5be535('0x1d3e')]['appdata'];break;default:{const _0x5a57f9=_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x823')][_0x5be535('0x25c8')](',');_0x2585f7['queue'][_0x5be535('0x1d3e')]=_0x2cfb05()[_0x5be535('0x1081')](_0x5a57f9[0x0])?_0x5a57f9[0x0]:isNaN(_0x5a57f9[0x0])?_0x5a57f9[0x0]:parseInt(_0x5a57f9[0x0],0xa),_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x651')]=_0x2cfb05()[_0x5be535('0x1081')](_0x5a57f9[0x1])?_0x5a57f9[0x1]:isNaN(_0x5a57f9[0x1])?_0x5a57f9[0x1]:parseInt(_0x5a57f9[0x1],0xa);}break;}else _0x2585f7[_0x5be535('0x1d3e')]['queue']=0x12c,_0x2585f7['queue']['timeout']=0x12c;_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x1345')]&&_0x2585f7['queue'][_0x5be535('0x1345')][_0x5be535('0x2574')]()===_0x5be535('0x587')&&_0x2585f7['queue'][_0x5be535('0x83f')]['toLowerCase']()===_0x5be535('0x2884')&&(_0x2585f7['queue'][_0x5be535('0x265a')]=_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x2026')]?_0x2585f7['queue'][_0x5be535('0x2026')][_0x5be535('0x25c8')]('$')[0x0]:undefined,_0x2585f7['queue']['callerId']=_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x992')]?_0x5be535('0xa4c')+_0x2585f7[_0x5be535('0x1d3e')][_0x5be535('0x992')]:undefined);_0x2585f7[_0x5be535('0x3e2')]=_0x183ace,_0x2585f7[_0x5be535('0x24a0')]=_0xaf1c64,_0x36b03b['hasRole'](_0x5be535('0xa7c'))?_0x37465d[_0x5be535('0x262f')][_0x5be535('0xd83')]({'fields':_0x5be535('0x1c09'),'sort':'name','nolimit':_0x5be535('0xf3b')})[_0x5be535('0xa44')]['then'](function(_0x1e02bd){const _0xc1ed54=_0x5be535;_0x2585f7[_0xc1ed54('0x7a7')]=_0x1e02bd['rows']||[];})[_0x5be535('0x1a80')](function(_0x5c1e40){const _0x12ba99=_0x5be535;_0x2bb457[_0x12ba99('0xfc9')]({'title':_0x5c1e40[_0x12ba99('0x52d')]?_0x12ba99('0x1e21')+_0x5c1e40['status']+_0x12ba99('0x11e1')+_0x5c1e40[_0x12ba99('0xe1b')]:'SYSTEM:GET_QUEUES','msg':_0x5c1e40['data']?JSON[_0x12ba99('0xbac')](_0x5c1e40[_0x12ba99('0x25f4')]):_0x5c1e40['toString']()});}):_0x37465d[_0x5be535('0x262f')]['get']({'fields':_0x5be535('0x1c09'),'sort':_0x5be535('0x4f0'),'nolimit':_0x5be535('0xf3b')})[_0x5be535('0xa44')][_0x5be535('0x1166')](function(_0x1e0927){const _0x1cb66d=_0x5be535;_0x2585f7['queues']=_0x1e0927[_0x1cb66d('0x269a')]||[];})[_0x5be535('0x1166')](function(){const _0x40e2d5=_0x5be535;return _0x37465d['userProfileSection'][_0x40e2d5('0xd83')]({'userProfileId':_0x2585f7[_0x40e2d5('0x98')][_0x40e2d5('0xb86')],'sectionId':0x321})[_0x40e2d5('0xa44')];})['then'](function(_0x3e3a3f){const _0x3ae5bb=_0x5be535,_0x4df215=_0x3e3a3f&&_0x3e3a3f[_0x3ae5bb('0x269a')]?_0x3e3a3f[_0x3ae5bb('0x269a')][0x0]:null;if(!_0x4df215){const _0x27ba08=[];let _0x141428=null;_0x2585f7[_0x3ae5bb('0x1d3e')]&&(_0x141428=_0x2cfb05()[_0x3ae5bb('0xc38')](_0x2585f7[_0x3ae5bb('0x7a7')],{'name':_0x2585f7[_0x3ae5bb('0x1d3e')][_0x3ae5bb('0x1d3e')]}));for(let _0x30cca7=0x0;_0x30cca7<_0x2585f7[_0x3ae5bb('0x7a7')][_0x3ae5bb('0x264b')];_0x30cca7++){_0x141428&&_0x2585f7[_0x3ae5bb('0x7a7')][_0x30cca7]['id']===_0x141428['id']&&(_0x2585f7[_0x3ae5bb('0x7a7')][_0x30cca7][_0x3ae5bb('0x2378')]=![],_0x27ba08[_0x3ae5bb('0x1514')](_0x2585f7[_0x3ae5bb('0x7a7')][_0x30cca7]));}_0x2585f7[_0x3ae5bb('0x7a7')]=_0x27ba08;}else{if(!_0x4df215[_0x3ae5bb('0x1a2b')])return _0x37465d[_0x3ae5bb('0x4b5')][_0x3ae5bb('0xd83')]({'sectionId':_0x4df215['id']})[_0x3ae5bb('0xa44')][_0x3ae5bb('0x1166')](function(_0x1dbb73){const _0x223404=_0x3ae5bb,_0x25a5ac=_0x2cfb05()[_0x223404('0x2563')](_0x1dbb73[_0x223404('0x269a')],function(_0x119c89){const _0x1d8e7e=_0x223404;return _0x2cfb05()[_0x1d8e7e('0xc38')](_0x2585f7[_0x1d8e7e('0x7a7')],{'id':_0x119c89[_0x1d8e7e('0x24e8')]});});let _0x257615=null;_0x2585f7['queue']&&(_0x257615=_0x2cfb05()[_0x223404('0xc38')](_0x2585f7[_0x223404('0x7a7')],{'name':_0x2585f7[_0x223404('0x1d3e')][_0x223404('0x1d3e')]}));if(_0x257615&&!_0x2cfb05()[_0x223404('0x1798')](_0x25a5ac,['id',_0x257615['id']])){const _0x42764d=_0x2cfb05()['find'](_0x2585f7['queues'],{'id':_0x257615['id']});_0x42764d[_0x223404('0x2378')]=![],_0x25a5ac[_0x223404('0x1514')](_0x42764d);}_0x2585f7[_0x223404('0x7a7')]=_0x25a5ac;});}})[_0x5be535('0x1a80')](function(_0x15e63e){const _0x2bf7b5=_0x5be535;_0x2bb457[_0x2bf7b5('0xfc9')]({'title':_0x15e63e[_0x2bf7b5('0x52d')]?_0x2bf7b5('0x1e21')+_0x15e63e[_0x2bf7b5('0x52d')]+'\x20-\x20'+_0x15e63e[_0x2bf7b5('0xe1b')]:_0x2bf7b5('0x1dd7'),'msg':_0x15e63e[_0x2bf7b5('0x25f4')]?JSON[_0x2bf7b5('0xbac')](_0x15e63e[_0x2bf7b5('0x25f4')]):_0x15e63e[_0x2bf7b5('0x1586')]()});});function _0x183ace(){const _0x26b803=_0x5be535;_0x2585f7[_0x26b803('0x61a')]=[];const _0x3c3cd7=[];_0x2585f7[_0x26b803('0x1d3e')]['type']&&_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0x1345')]['toLowerCase']()===_0x26b803('0x587')&&_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0x83f')]==='outboundDial'&&(_0x2585f7['queue'][_0x26b803('0x2026')]=_0xc1e48[_0x26b803('0x2848')]?(_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0x265a')]||'')+_0x26b803('0x881')+_0xc1e48[_0x26b803('0x2848')]+'}':(_0x2585f7[_0x26b803('0x1d3e')]['prefix']||'')+_0x26b803('0x1d1'),_0xc1e48[_0x26b803('0x28cb')]!==_0x26b803('0x192')?_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0xd39')][_0x26b803('0x2379')](_0x26b803('0x1059'))<0x0&&(_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0xd39')]+=_0x26b803('0x1059')):_0x2585f7['queue'][_0x26b803('0xd39')]=_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0xd39')][_0x26b803('0xf3')](_0x26b803('0x1059'),''));const _0x28772a=_0x2cfb05()[_0x26b803('0xc38')](_0x2585f7['queues'],{'name':_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0x1d3e')]});_0x28772a&&(_0x2585f7[_0x26b803('0x1d3e')][_0x2cfb05()[_0x26b803('0x92c')]('openChannel')+_0x26b803('0x1366')]=_0x28772a['id']);if(_0x2585f7['queue'][_0x26b803('0x83f')]&&_0x2585f7[_0x26b803('0x1d3e')]['appType']==='custom'){}else switch((_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0x746')]||_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0x83f')])[_0x26b803('0x2574')]()){case'set':_0x2585f7['queue'][_0x26b803('0x823')]=_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0x4f0')]+'='+_0x2585f7['queue']['value'];break;case'custom':break;default:_0x3c3cd7[0x0]=_0x2585f7[_0x26b803('0x1d3e')]['queue'],_0x3c3cd7[0x1]=_0x2585f7[_0x26b803('0x1d3e')][_0x26b803('0x651')],_0x2585f7['queue'][_0x26b803('0x823')]=_0x3c3cd7['join'](',');}_0xaf1c64(_0x2585f7['queue']);}function _0xaf1c64(_0x48fce1){_0x41cd27['hide'](_0x48fce1);}}const _0xabf535=_0x52abba;_0x1cc6d8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x248f'),_0x36e6f4('0x77f'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x1cc6d8(_0x1b9309,_0x481493,_0x5d5db8,_0xace9,_0x2bcb1f,_0xf75df2,_0x124760,_0x35e1f3){const _0x1b3981=_0x36e6f4,_0x43b723=this;_0x43b723[_0x1b3981('0x98')]=_0x124760[_0x1b3981('0x26cd')](),_0x43b723[_0x1b3981('0x61a')]=[],_0x43b723[_0x1b3981('0xcdc')]=_0x1b3981('0xf67')+(_0xace9[_0x1b3981('0x83f')]||_0xace9[_0x1b3981('0x746')])[_0x1b3981('0x1387')](),_0x43b723['system']=angular[_0x1b3981('0x225f')](_0xace9),_0x43b723[_0x1b3981('0x243c')]=_0x35e1f3,_0x43b723['hasModulePermissions']={};if(_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x823')])switch(_0x43b723['system'][_0x1b3981('0x83f')]?_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x83f')][_0x1b3981('0x2574')]():_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x746')][_0x1b3981('0x2574')]()){case _0x1b3981('0x2853'):break;case _0x1b3981('0xded'):{const _0xbe269c=_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x823')][_0x1b3981('0x25c8')](',');_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x7ca')]=_0xbe269c[0x0],_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0xedb')]=_0xbe269c[0x1],_0x43b723['system']['welcomemessage']=_0xbe269c[_0x1b3981('0x233')](0x2,_0xbe269c[_0x1b3981('0x264b')])[_0x1b3981('0x45a')](',');}break;case _0x1b3981('0x1636'):{const _0x10a5d0=_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x823')][_0x1b3981('0x25c8')](',');_0x43b723['system'][_0x1b3981('0x1b0a')]=_0x10a5d0[0x0],_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x27f3')]=_0x10a5d0[0x1],_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x170e')]=_0x10a5d0[0x2],_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0xedb')]=_0x10a5d0[0x3],_0x43b723['system'][_0x1b3981('0x1634')]=_0x10a5d0[_0x1b3981('0x233')](0x4,_0x10a5d0['length'])['join'](',');}break;case _0x1b3981('0x86c'):{const _0x4f99a5=_0x43b723['system']['appdata']['split'](',');_0x43b723['system'][_0x1b3981('0xee6')]=_0x4f99a5[0x0],_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x125')]=_0x4f99a5[0x1],_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x25a2')]=_0x4f99a5[0x2],_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x1ac4')]=_0x4f99a5[0x3],_0x43b723[_0x1b3981('0x1c2b')]['welcomemessage']=_0x4f99a5[_0x1b3981('0x233')](0x4,_0x4f99a5['length'])[_0x1b3981('0x45a')](',');}break;case _0x1b3981('0x1af7'):{const _0x241b05=_0x43b723['system'][_0x1b3981('0x823')][_0x1b3981('0x25c8')](',');_0x43b723['system'][_0x1b3981('0x265e')]=isNaN(_0x241b05[0x0])?_0x241b05[0x0]:parseInt(_0x241b05[0x0],0xa),_0x43b723[_0x1b3981('0x1c2b')]['text']=_0x241b05[_0x1b3981('0x233')](0x1,_0x241b05[_0x1b3981('0x264b')])[_0x1b3981('0x45a')](',');}break;case _0x1b3981('0x1e70'):_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x1640')]=_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x823')];break;case _0x1b3981('0xceb'):_0x43b723['system']['name']=_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x823')]['split']('=')[0x0],_0x43b723[_0x1b3981('0x1c2b')]['value']=_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x823')][_0x1b3981('0x25c8')]('=')[0x1];break;case'agi':_0x43b723[_0x1b3981('0x1c2b')]['project']=_0x43b723[_0x1b3981('0x1c2b')]['appdata'];break;default:{const _0x34411d=_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x823')]['split'](',');_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x187')]=_0x2cfb05()[_0x1b3981('0x1081')](_0x34411d[0x0])?_0x34411d[0x0]:isNaN(_0x34411d[0x0])?_0x34411d[0x0]:parseInt(_0x34411d[0x0],0xa),_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x734')]=_0x2cfb05()['isEmpty'](_0x34411d[0x1])?_0x34411d[0x1]:isNaN(_0x34411d[0x1])?_0x34411d[0x1]:parseInt(_0x34411d[0x1],0xa);}break;}else _0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x734')]='';_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x1345')]&&_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x1345')][_0x1b3981('0x2574')]()==='outbound'&&_0x43b723['system']['appType'][_0x1b3981('0x2574')]()===_0x1b3981('0x2884')&&(_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x265a')]=_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x2026')]?_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x2026')]['split']('$')[0x0]:undefined,_0x43b723[_0x1b3981('0x1c2b')]['callerId']=_0x43b723[_0x1b3981('0x1c2b')][_0x1b3981('0x992')]?_0x1b3981('0xa4c')+_0x43b723[_0x1b3981('0x1c2b')]['callerID']:undefined);_0x43b723[_0x1b3981('0x3e2')]=_0x3b9151,_0x43b723[_0x1b3981('0x24a0')]=_0xbefbe7,_0x124760[_0x1b3981('0x1ac6')](_0x1b3981('0xa7c'))?_0xf75df2[_0x1b3981('0x734')]['get']({'fields':_0x1b3981('0x1776'),'sort':_0x1b3981('0x4f0'),'nolimit':'true'})['$promise'][_0x1b3981('0x1166')](function(_0x557108){const _0xf82966=_0x1b3981;_0x43b723[_0xf82966('0x57a')]=_0x557108[_0xf82966('0x269a')]||[];})[_0x1b3981('0x1a80')](function(_0x5e64e4){const _0xffeb4=_0x1b3981;_0x5d5db8[_0xffeb4('0xfc9')]({'title':_0x5e64e4[_0xffeb4('0x52d')]?_0xffeb4('0x1e21')+_0x5e64e4[_0xffeb4('0x52d')]+'\x20-\x20'+_0x5e64e4[_0xffeb4('0xe1b')]:'SYSTEM:GET_VARIABLES','msg':_0x5e64e4[_0xffeb4('0x25f4')]?JSON['stringify'](_0x5e64e4['data']):_0x5e64e4[_0xffeb4('0x1586')]()});}):_0xf75df2['variable']['get']({'fields':_0x1b3981('0x1776'),'sort':_0x1b3981('0x4f0'),'nolimit':'true'})['$promise'][_0x1b3981('0x1166')](function(_0xc258c){const _0x2bc2c1=_0x1b3981;_0x43b723[_0x2bc2c1('0x57a')]=_0xc258c[_0x2bc2c1('0x269a')]||[];})['then'](function(){const _0x4e3bc8=_0x1b3981;return _0xf75df2[_0x4e3bc8('0x17aa')][_0x4e3bc8('0xd83')]({'userProfileId':_0x43b723[_0x4e3bc8('0x98')][_0x4e3bc8('0xb86')],'sectionId':0x3f4})['$promise'];})['then'](function(_0x3d8a1a){const _0x2dad2d=_0x1b3981,_0x5f0728=_0x3d8a1a&&_0x3d8a1a['rows']?_0x3d8a1a[_0x2dad2d('0x269a')][0x0]:null;if(!_0x5f0728){const _0x12e0a0=[];let _0x4085d2=null;_0x43b723[_0x2dad2d('0x1c2b')]&&(_0x4085d2=_0x2cfb05()[_0x2dad2d('0xc38')](_0x43b723[_0x2dad2d('0x57a')],{'name':_0x43b723[_0x2dad2d('0x1c2b')]['variable']}));for(let _0x45ccf9=0x0;_0x45ccf9<_0x43b723[_0x2dad2d('0x57a')][_0x2dad2d('0x264b')];_0x45ccf9++){_0x4085d2&&_0x43b723[_0x2dad2d('0x57a')][_0x45ccf9]['id']===_0x4085d2['id']&&(_0x43b723['variables'][_0x45ccf9][_0x2dad2d('0x2378')]=![],_0x12e0a0[_0x2dad2d('0x1514')](_0x43b723[_0x2dad2d('0x57a')][_0x45ccf9]));}_0x43b723[_0x2dad2d('0x57a')]=_0x12e0a0;}else{if(!_0x5f0728[_0x2dad2d('0x1a2b')])return _0xf75df2[_0x2dad2d('0x4b5')][_0x2dad2d('0xd83')]({'sectionId':_0x5f0728['id']})[_0x2dad2d('0xa44')][_0x2dad2d('0x1166')](function(_0x2b4aa7){const _0x1cdc4d=_0x2dad2d,_0x1dd15c=_0x2cfb05()[_0x1cdc4d('0x2563')](_0x2b4aa7['rows'],function(_0xb4ca47){const _0x3f395a=_0x1cdc4d;return _0x2cfb05()[_0x3f395a('0xc38')](_0x43b723[_0x3f395a('0x57a')],{'id':_0xb4ca47[_0x3f395a('0x24e8')]});});let _0x5baf95=null;_0x43b723[_0x1cdc4d('0x1c2b')]&&(_0x5baf95=_0x2cfb05()['find'](_0x43b723[_0x1cdc4d('0x57a')],{'name':_0x43b723[_0x1cdc4d('0x1c2b')][_0x1cdc4d('0x734')]}));if(_0x5baf95&&!_0x2cfb05()[_0x1cdc4d('0x1798')](_0x1dd15c,['id',_0x5baf95['id']])){const _0x2db389=_0x2cfb05()[_0x1cdc4d('0xc38')](_0x43b723[_0x1cdc4d('0x57a')],{'id':_0x5baf95['id']});_0x2db389[_0x1cdc4d('0x2378')]=![],_0x1dd15c[_0x1cdc4d('0x1514')](_0x2db389);}_0x43b723[_0x1cdc4d('0x57a')]=_0x1dd15c;});}})[_0x1b3981('0x1a80')](function(_0x4b9dc7){const _0x148b71=_0x1b3981;_0x5d5db8[_0x148b71('0xfc9')]({'title':_0x4b9dc7[_0x148b71('0x52d')]?_0x148b71('0x1e21')+_0x4b9dc7[_0x148b71('0x52d')]+_0x148b71('0x11e1')+_0x4b9dc7[_0x148b71('0xe1b')]:'SYSTEM:GETvariables','msg':_0x4b9dc7[_0x148b71('0x25f4')]?JSON[_0x148b71('0xbac')](_0x4b9dc7[_0x148b71('0x25f4')]):_0x4b9dc7[_0x148b71('0x1586')]()});});function _0x3b9151(){const _0x5e2253=_0x1b3981;_0x43b723[_0x5e2253('0x61a')]=[];const _0x123ee4=[];_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x1345')]&&_0x43b723[_0x5e2253('0x1c2b')]['type'][_0x5e2253('0x2574')]()==='outbound'&&_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x83f')]===_0x5e2253('0x867')&&(_0x43b723[_0x5e2253('0x1c2b')]['phone']=_0x2bcb1f[_0x5e2253('0x2848')]?(_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x265a')]||'')+_0x5e2253('0x881')+_0x2bcb1f[_0x5e2253('0x2848')]+'}':(_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x265a')]||'')+_0x5e2253('0x1d1'),_0x2bcb1f[_0x5e2253('0x28cb')]!==_0x5e2253('0x192')?_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0xd39')]['indexOf']('U(xcally-mixmonitor-context)')<0x0&&(_0x43b723[_0x5e2253('0x1c2b')]['options']+=_0x5e2253('0x1059')):_0x43b723['system'][_0x5e2253('0xd39')]=_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0xd39')][_0x5e2253('0xf3')](_0x5e2253('0x1059'),''));if(_0x43b723[_0x5e2253('0x1c2b')]['appType']&&_0x43b723['system']['appType']===_0x5e2253('0x2853')){}else switch((_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x746')]||_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x83f')])['toLowerCase']()){case _0x5e2253('0xceb'):_0x43b723[_0x5e2253('0x1c2b')]['appdata']=_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x4f0')]+'='+_0x43b723['system'][_0x5e2253('0x18e0')];break;case _0x5e2253('0x2853'):break;default:_0x123ee4[0x0]=_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x187')],_0x123ee4[0x1]=_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x734')],_0x43b723[_0x5e2253('0x1c2b')][_0x5e2253('0x823')]=_0x123ee4[_0x5e2253('0x45a')](',');}_0xbefbe7(_0x43b723[_0x5e2253('0x1c2b')]);}function _0xbefbe7(_0x1baff4){const _0x62f83e=_0x1b3981;_0x1b9309[_0x62f83e('0x1197')](_0x1baff4);}}const _0x29a45f=_0x1cc6d8;_0x1fcd78[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x248f'),_0x36e6f4('0x77f'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x1fcd78(_0xb25dbe,_0x2fa4f4,_0x3e5e92,_0x217a9a,_0xd144a5,_0x28f009,_0x50477b,_0x34276f){const _0x5291ca=_0x36e6f4,_0x19504a=this;_0x19504a['currentUser']=_0x50477b[_0x5291ca('0x26cd')](),_0x19504a[_0x5291ca('0x61a')]=[],_0x19504a[_0x5291ca('0xcdc')]=_0x5291ca('0xf67')+(_0x217a9a['appType']||_0x217a9a[_0x5291ca('0x746')])['toUpperCase'](),_0x19504a[_0x5291ca('0x1446')]=angular[_0x5291ca('0x225f')](_0x217a9a),_0x19504a[_0x5291ca('0x243c')]=_0x34276f,_0x19504a['hasModulePermissions']={};if(_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x823')])switch(_0x19504a[_0x5291ca('0x1446')]['appType']?_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x83f')][_0x5291ca('0x2574')]():_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x746')]['toLowerCase']()){case _0x5291ca('0x2853'):break;case _0x5291ca('0xded'):{const _0x15fd65=_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x823')][_0x5291ca('0x25c8')](',');_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x7ca')]=_0x15fd65[0x0],_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0xedb')]=_0x15fd65[0x1],_0x19504a['tag'][_0x5291ca('0x1634')]=_0x15fd65[_0x5291ca('0x233')](0x2,_0x15fd65[_0x5291ca('0x264b')])[_0x5291ca('0x45a')](',');}break;case _0x5291ca('0x1636'):{const _0x275743=_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x823')]['split'](',');_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x1b0a')]=_0x275743[0x0],_0x19504a['tag'][_0x5291ca('0x27f3')]=_0x275743[0x1],_0x19504a[_0x5291ca('0x1446')]['privateKey']=_0x275743[0x2],_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0xedb')]=_0x275743[0x3],_0x19504a['tag'][_0x5291ca('0x1634')]=_0x275743[_0x5291ca('0x233')](0x4,_0x275743['length'])['join'](',');}break;case _0x5291ca('0x86c'):{const _0x1ba71b=_0x19504a['tag'][_0x5291ca('0x823')]['split'](',');_0x19504a['tag']['accesskeyid']=_0x1ba71b[0x0],_0x19504a['tag'][_0x5291ca('0x125')]=_0x1ba71b[0x1],_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x25a2')]=_0x1ba71b[0x2],_0x19504a['tag'][_0x5291ca('0x1ac4')]=_0x1ba71b[0x3],_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x1634')]=_0x1ba71b[_0x5291ca('0x233')](0x4,_0x1ba71b['length'])['join'](',');}break;case'autoreply':{const _0x10a2d6=_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x823')][_0x5291ca('0x25c8')](',');_0x19504a[_0x5291ca('0x1446')]['times']=isNaN(_0x10a2d6[0x0])?_0x10a2d6[0x0]:parseInt(_0x10a2d6[0x0],0xa),_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x1640')]=_0x10a2d6[_0x5291ca('0x233')](0x1,_0x10a2d6[_0x5291ca('0x264b')])[_0x5291ca('0x45a')](',');}break;case _0x5291ca('0x1e70'):_0x19504a[_0x5291ca('0x1446')]['text']=_0x19504a[_0x5291ca('0x1446')]['appdata'];break;case _0x5291ca('0xceb'):_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x4f0')]=_0x19504a['tag'][_0x5291ca('0x823')]['split']('=')[0x0],_0x19504a['tag'][_0x5291ca('0x18e0')]=_0x19504a[_0x5291ca('0x1446')]['appdata']['split']('=')[0x1];break;case'agi':_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x2588')]=_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x823')];break;default:{const _0x360dd3=_0x19504a[_0x5291ca('0x1446')]['appdata'][_0x5291ca('0x25c8')](',');_0x19504a[_0x5291ca('0x1446')]['tag']=_0x2cfb05()[_0x5291ca('0x1081')](_0x360dd3[0x0])?_0x360dd3[0x0]:isNaN(_0x360dd3[0x0])?_0x360dd3[0x0]:parseInt(_0x360dd3[0x0],0xa);}break;}else{}_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x1345')]&&_0x19504a[_0x5291ca('0x1446')]['type'][_0x5291ca('0x2574')]()===_0x5291ca('0x587')&&_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x83f')][_0x5291ca('0x2574')]()==='outbounddial'&&(_0x19504a['tag'][_0x5291ca('0x265a')]=_0x19504a[_0x5291ca('0x1446')]['phone']?_0x19504a[_0x5291ca('0x1446')]['phone']['split']('$')[0x0]:undefined,_0x19504a[_0x5291ca('0x1446')][_0x5291ca('0x1f02')]=_0x19504a['tag']['callerID']?_0x5291ca('0xa4c')+_0x19504a[_0x5291ca('0x1446')]['callerID']:undefined);_0x19504a[_0x5291ca('0x3e2')]=_0x4e1794,_0x19504a[_0x5291ca('0x24a0')]=_0x426fc7,_0x50477b[_0x5291ca('0x1ac6')](_0x5291ca('0xa7c'))?_0x28f009[_0x5291ca('0x1446')]['get']({'fields':'id,name','sort':_0x5291ca('0x4f0'),'nolimit':_0x5291ca('0xf3b')})[_0x5291ca('0xa44')][_0x5291ca('0x1166')](function(_0x1e16fa){const _0x5ce704=_0x5291ca;_0x19504a[_0x5ce704('0xb38')]=_0x1e16fa[_0x5ce704('0x269a')]||[];})[_0x5291ca('0x1a80')](function(_0x415419){const _0x390317=_0x5291ca;_0x3e5e92['error']({'title':_0x415419['status']?'API:'+_0x415419[_0x390317('0x52d')]+_0x390317('0x11e1')+_0x415419[_0x390317('0xe1b')]:'SYSTEM:GET_TAGS','msg':_0x415419[_0x390317('0x25f4')]?JSON['stringify'](_0x415419[_0x390317('0x25f4')]):_0x415419[_0x390317('0x1586')]()});}):_0x28f009[_0x5291ca('0x1446')]['get']({'fields':_0x5291ca('0x1776'),'sort':_0x5291ca('0x4f0'),'nolimit':'true'})[_0x5291ca('0xa44')][_0x5291ca('0x1166')](function(_0x5d2a54){const _0x47036d=_0x5291ca;_0x19504a[_0x47036d('0xb38')]=_0x5d2a54['rows']||[];})['then'](function(){const _0x3e1974=_0x5291ca;return _0x28f009[_0x3e1974('0x17aa')][_0x3e1974('0xd83')]({'userProfileId':_0x19504a['currentUser'][_0x3e1974('0xb86')],'sectionId':0x3f0})[_0x3e1974('0xa44')];})['then'](function(_0x1b123c){const _0x414d5f=_0x5291ca,_0x409700=_0x1b123c&&_0x1b123c['rows']?_0x1b123c['rows'][0x0]:null;if(!_0x409700){const _0x3f55a3=[];let _0x28daa0=null;_0x19504a[_0x414d5f('0x1446')]&&(_0x28daa0=_0x2cfb05()['find'](_0x19504a[_0x414d5f('0xb38')],{'name':_0x19504a['tag']['tag']}));for(let _0x32a28c=0x0;_0x32a28c<_0x19504a[_0x414d5f('0xb38')][_0x414d5f('0x264b')];_0x32a28c++){_0x28daa0&&_0x19504a['tags'][_0x32a28c]['id']===_0x28daa0['id']&&(_0x19504a[_0x414d5f('0xb38')][_0x32a28c][_0x414d5f('0x2378')]=![],_0x3f55a3[_0x414d5f('0x1514')](_0x19504a[_0x414d5f('0xb38')][_0x32a28c]));}_0x19504a[_0x414d5f('0xb38')]=_0x3f55a3;}else{if(!_0x409700[_0x414d5f('0x1a2b')])return _0x28f009['userProfileResource'][_0x414d5f('0xd83')]({'sectionId':_0x409700['id']})[_0x414d5f('0xa44')][_0x414d5f('0x1166')](function(_0x39dbbc){const _0x3db505=_0x414d5f,_0x14ad97=_0x2cfb05()[_0x3db505('0x2563')](_0x39dbbc['rows'],function(_0x395329){const _0x1bc847=_0x3db505;return _0x2cfb05()['find'](_0x19504a['tags'],{'id':_0x395329[_0x1bc847('0x24e8')]});});let _0x4726d4=null;_0x19504a['tag']&&(_0x4726d4=_0x2cfb05()[_0x3db505('0xc38')](_0x19504a[_0x3db505('0xb38')],{'name':_0x19504a[_0x3db505('0x1446')][_0x3db505('0x1446')]}));if(_0x4726d4&&!_0x2cfb05()[_0x3db505('0x1798')](_0x14ad97,['id',_0x4726d4['id']])){const _0x2402ad=_0x2cfb05()[_0x3db505('0xc38')](_0x19504a[_0x3db505('0xb38')],{'id':_0x4726d4['id']});_0x2402ad[_0x3db505('0x2378')]=![],_0x14ad97['push'](_0x2402ad);}_0x19504a[_0x3db505('0xb38')]=_0x14ad97;});}})[_0x5291ca('0x1a80')](function(_0x215847){const _0x417d61=_0x5291ca;_0x3e5e92[_0x417d61('0xfc9')]({'title':_0x215847[_0x417d61('0x52d')]?_0x417d61('0x1e21')+_0x215847[_0x417d61('0x52d')]+'\x20-\x20'+_0x215847[_0x417d61('0xe1b')]:'SYSTEM:GETtags','msg':_0x215847[_0x417d61('0x25f4')]?JSON[_0x417d61('0xbac')](_0x215847[_0x417d61('0x25f4')]):_0x215847[_0x417d61('0x1586')]()});});function _0x4e1794(){const _0x1fe9e2=_0x5291ca;_0x19504a[_0x1fe9e2('0x61a')]=[];const _0x7ee281=[];_0x19504a[_0x1fe9e2('0x1446')][_0x1fe9e2('0x1345')]&&_0x19504a[_0x1fe9e2('0x1446')]['type'][_0x1fe9e2('0x2574')]()==='outbound'&&_0x19504a['tag'][_0x1fe9e2('0x83f')]===_0x1fe9e2('0x867')&&(_0x19504a[_0x1fe9e2('0x1446')][_0x1fe9e2('0x2026')]=_0xd144a5[_0x1fe9e2('0x2848')]?(_0x19504a[_0x1fe9e2('0x1446')][_0x1fe9e2('0x265a')]||'')+_0x1fe9e2('0x881')+_0xd144a5[_0x1fe9e2('0x2848')]+'}':(_0x19504a[_0x1fe9e2('0x1446')]['prefix']||'')+_0x1fe9e2('0x1d1'),_0xd144a5[_0x1fe9e2('0x28cb')]!=='none'?_0x19504a[_0x1fe9e2('0x1446')][_0x1fe9e2('0xd39')][_0x1fe9e2('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x19504a['tag'][_0x1fe9e2('0xd39')]+=_0x1fe9e2('0x1059')):_0x19504a[_0x1fe9e2('0x1446')][_0x1fe9e2('0xd39')]=_0x19504a['tag'][_0x1fe9e2('0xd39')]['replace'](_0x1fe9e2('0x1059'),''));const _0x54e6ec=_0x2cfb05()[_0x1fe9e2('0xc38')](_0x19504a[_0x1fe9e2('0xb38')],{'name':_0x19504a[_0x1fe9e2('0x1446')]['tag']});_0x54e6ec&&(_0x19504a[_0x1fe9e2('0x1446')][_0x1fe9e2('0x8f5')]=_0x54e6ec['id']);if(_0x19504a['tag']['appType']&&_0x19504a[_0x1fe9e2('0x1446')]['appType']===_0x1fe9e2('0x2853')){}else switch((_0x19504a[_0x1fe9e2('0x1446')]['app']||_0x19504a[_0x1fe9e2('0x1446')][_0x1fe9e2('0x83f')])[_0x1fe9e2('0x2574')]()){case _0x1fe9e2('0xceb'):_0x19504a['tag'][_0x1fe9e2('0x823')]=_0x19504a[_0x1fe9e2('0x1446')][_0x1fe9e2('0x4f0')]+'='+_0x19504a[_0x1fe9e2('0x1446')][_0x1fe9e2('0x18e0')];break;case _0x1fe9e2('0x2853'):break;default:_0x7ee281[0x0]=_0x19504a[_0x1fe9e2('0x1446')]['tag'],_0x19504a[_0x1fe9e2('0x1446')]['appdata']=_0x7ee281[_0x1fe9e2('0x45a')](',');}_0x426fc7(_0x19504a[_0x1fe9e2('0x1446')]);}function _0x426fc7(_0xac22e3){_0xb25dbe['hide'](_0xac22e3);}}const _0x37491c=_0x1fcd78;_0x4cf64f[_0x36e6f4('0x1294')]=['$cookies',_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),'$timeout',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x4cf64f(_0x2a4365,_0x495e0c,_0x2cefa1,_0x442590,_0x35c339,_0xeae5c0,_0x35d306,_0x289ac3,_0x107740,_0x147701,_0x442d67){const _0x365591=_0x36e6f4,_0x3c86c0=this;_0x3c86c0['currentUser']=_0x442d67[_0x365591('0x26cd')](),_0x3c86c0[_0x365591('0x77f')]={},_0x3c86c0[_0x365591('0xa6d')]={'count':0x0,'rows':[]},_0x3c86c0[_0x365591('0x1467')]=[],_0x3c86c0[_0x365591('0x243c')],_0x3c86c0[_0x365591('0x2218')]={'read':'null','closed':_0x365591('0x15d7'),'sort':_0x365591('0x2537'),'includeAll':_0x365591('0xf3b'),'limit':0xa,'page':0x1},_0x3c86c0[_0x365591('0x24d5')]=_0x4800fa,_0x3c86c0['deleteConfirm']=_0xa5c35d,_0x3c86c0[_0x365591('0x14df')]=_0x4a7dbe,_0x3c86c0['success']=_0x1cba4a,_0x3c86c0[_0x365591('0x1910')]=_0xa7d939,_0x3c86c0[_0x365591('0x26c3')]=_0xbbc6f2,_0x3c86c0[_0x365591('0x138b')]=_0x59ea66,_0x3c86c0['exportSelectedOpenchannelAccountInteractions']=_0x1b8f2c,_0x3c86c0[_0x365591('0x21dc')]=_0x5ec738,_0x3c86c0['deleteSelectedOpenchannelAccountInteractions']=_0x46ce55;function _0x4800fa(_0x50688f,_0x51aab9){const _0x47d8b5=_0x365591;_0x3c86c0['openchannelAccount']=_0x50688f,_0x3c86c0[_0x47d8b5('0x243c')]=typeof _0x51aab9!=='undefined'?_0x51aab9:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3c86c0[_0x47d8b5('0x2218')][_0x47d8b5('0xb8')]=_0x3c86c0[_0x47d8b5('0x77f')]['id'],_0x3c86c0['advancedSearch']={'fields':_0x1b8c8d()},_0x1f6249();}function _0x1f6249(){const _0x3224c5=_0x365591;return _0x147701[_0x3224c5('0x1446')][_0x3224c5('0xd83')]()['$promise'][_0x3224c5('0x1166')](function(_0x3d8524){const _0x155bca=_0x3224c5;_0x3c86c0[_0x155bca('0xb38')]=_0x3d8524||{'count':0x0,'rows':[]};})[_0x3224c5('0x1166')](function(){_0x3c86c0['quickFilters']=_0x5ba71c();});}function _0x5ba71c(){const _0x5734d8=_0x365591;return[{'name':_0x5734d8('0x2567'),'key':_0x5734d8('0x262'),'type':'date','label':_0x5734d8('0x16d9')},{'name':_0x5734d8('0x116c'),'key':_0x5734d8('0x123'),'type':_0x5734d8('0x88a'),'label':'DASHBOARDS.SELECT_READ_UNREAD','customOptions':[{'value':0x0,'translate':_0x5734d8('0x2c8')},{'value':0x1,'translate':'DASHBOARDS.READ'},{'value':null,'translate':'DASHBOARDS.ALL'}]},{'name':_0x5734d8('0x28f6'),'key':_0x5734d8('0xa5b'),'type':'select','label':_0x5734d8('0xe32'),'customOptions':[{'value':0x0,'translate':'DASHBOARDS.OPENED'},{'value':0x1,'translate':_0x5734d8('0x58f')},{'value':null,'translate':'DASHBOARDS.ALL'}]},{'name':_0x5734d8('0x89b'),'key':_0x5734d8('0x122a'),'type':'select','label':_0x5734d8('0x1db1'),'customOptions':[{'value':_0x5734d8('0x15d7'),'translate':_0x5734d8('0x216b')},{'value':undefined,'translate':'DASHBOARDS.ALL'}]},{'name':_0x5734d8('0x1b35'),'key':_0x5734d8('0x1446'),'type':_0x5734d8('0x2162'),'label':_0x5734d8('0x1669'),'options':_0x3c86c0['tags'][_0x5734d8('0x269a')],'placeholder':_0x5734d8('0x2223')}];}function _0x1b8c8d(){const _0x4f277a=_0x365591;return[{'name':'Id','column':'id','type':_0x4f277a('0xc45')},{'name':'Contact','column':_0x4f277a('0x21a4'),'type':_0x4f277a('0x1a01'),'options':{'searchFields':['firstName',_0x4f277a('0xeb0'),_0x4f277a('0x66f')],'route':{'model':_0x4f277a('0x149e'),'action':_0x4f277a('0xd83'),'params':{'fields':_0x4f277a('0x18eb'),'Contact':_0x4f277a('0x145b'),'nolimit':!![]}},'extraOperators':[_0x4f277a('0x2836')],'excludedOperators':[_0x4f277a('0x2646')]}},{'name':_0x4f277a('0x36e'),'column':_0x4f277a('0x210d'),'type':_0x4f277a('0x1640'),'options':{'excludedOperators':[_0x4f277a('0x110'),_0x4f277a('0x2646')]}},{'name':_0x4f277a('0xe1'),'column':'plainBody','type':_0x4f277a('0x1640'),'options':{'excludedOperators':['$eq',_0x4f277a('0x2646')]}},{'name':_0x4f277a('0x28f6'),'column':_0x4f277a('0xa5b'),'type':'select','values':[{'id':0x0,'translate':'DASHBOARDS.OPENED'},{'id':0x1,'translate':_0x4f277a('0x58f')}],'options':{'excludedOperators':[_0x4f277a('0x2646')]}},{'name':'Agent','column':'User','type':'autocomplete','options':{'table':'i','route':{'model':_0x4f277a('0x557'),'action':_0x4f277a('0xd83'),'params':{'role':_0x4f277a('0x1eff'),'fields':_0x4f277a('0xce1'),'nolimit':!![]}},'searchFields':[_0x4f277a('0x6e1'),_0x4f277a('0x4f0')],'extraOperators':[_0x4f277a('0x2836')],'excludedOperators':[_0x4f277a('0x2646')]}},{'name':_0x4f277a('0x21c2'),'column':_0x4f277a('0x1b35'),'type':_0x4f277a('0x2162'),'options':{'route':{'model':_0x4f277a('0x1446'),'action':_0x4f277a('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':['$notIn']}},{'name':_0x4f277a('0x2567'),'column':_0x4f277a('0x262'),'type':_0x4f277a('0x1643'),'options':{'excludedOperators':[_0x4f277a('0x2646')]}},{'name':_0x4f277a('0xf43'),'column':_0x4f277a('0x723'),'type':_0x4f277a('0x88a'),'values':[{'id':0x1,'translate':'DASHBOARDS.READ'},{'id':0x0,'translate':_0x4f277a('0x2c8')}],'options':{'excludedOperators':[_0x4f277a('0x2646')]}}];}function _0x59ea66(){const _0x2a3adb=_0x365591;_0x35d306['show']({'controller':_0x2a3adb('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular[_0x2a3adb('0x1194')](_0x289ac3[_0x2a3adb('0x8d2')]),'clickOutsideToClose':![],'locals':{'fields':_0x3c86c0[_0x2a3adb('0x1291')]['fields'],'color':undefined,'storagePath':_0x2a3adb('0x1d0f')},'fullscreen':!![]})[_0x2a3adb('0x1166')](function(_0x2d9f55){const _0x183c1c=_0x2a3adb;_0x3c86c0[_0x183c1c('0x2218')][_0x183c1c('0xe07')]=_0x2d9f55===![]?undefined:_0x2d9f55;if(_0x3c86c0[_0x183c1c('0x2218')]['search'])_0xa7d939();else _0x2d9f55===![]&&_0xa7d939();})[_0x2a3adb('0x1a80')](function(_0xcc1c83){const _0x585305=_0x2a3adb;_0x107740['error']({'title':_0x585305('0x2272'),'msg':_0xcc1c83[_0x585305('0x25f4')]?JSON[_0x585305('0xbac')](_0xcc1c83[_0x585305('0x25f4')][_0x585305('0x1e70')]):_0xcc1c83['toString']()});});}function _0x4a7dbe(_0x325952,_0x4a44ee,_0x35ff8f){const _0x2b6511=_0x365591;return _0x147701[_0x2b6511('0x1b9e')]['download']({'id':_0x325952['id'],'exists':!![],'attachments':_0x35ff8f})[_0x2b6511('0xa44')][_0x2b6511('0x1166')](function(_0x4c458b){const _0x5417cc=_0x2b6511,_0x52367a=[_0x4c458b['buffer']];let _0x381818=_0x5417cc('0x25e6')+_0x325952['id'];const _0x2ac779=new Blob(_0x52367a,{'type':_0x4c458b['type']});_0x381818=_0x5417cc('0x253b')+_0x325952['id']+_0x5417cc('0x806');const _0x5a7cfb=window[_0x5417cc('0x136d')]['createElement']('a');_0x5a7cfb['setAttribute'](_0x5417cc('0x14f9'),URL['createObjectURL'](_0x2ac779)),_0x5a7cfb['setAttribute'](_0x5417cc('0x2ad'),_0x381818),document['body'][_0x5417cc('0x21a')](_0x5a7cfb),_0x5a7cfb[_0x5417cc('0x3b4')]();})[_0x2b6511('0x1a80')](function(_0x500a06){const _0x3f7485=_0x2b6511;if(_0x500a06[_0x3f7485('0x25f4')]&&_0x500a06[_0x3f7485('0x25f4')][_0x3f7485('0x61a')]&&_0x500a06['data'][_0x3f7485('0x61a')]['length'])for(let _0xf6a915=0x0;_0xf6a915<_0x500a06[_0x3f7485('0x25f4')][_0x3f7485('0x61a')][_0x3f7485('0x264b')];_0xf6a915+=0x1){_0x107740[_0x3f7485('0xfc9')]({'title':_0x500a06['data'][_0x3f7485('0x61a')][_0xf6a915][_0x3f7485('0x1345')],'msg':_0x500a06[_0x3f7485('0x25f4')][_0x3f7485('0x61a')][_0xf6a915]['message']});}else _0x107740[_0x3f7485('0xfc9')]({'title':_0x500a06['status']?_0x3f7485('0x1e21')+_0x500a06['status']+_0x3f7485('0x11e1')+_0x500a06[_0x3f7485('0xe1b')]:_0x3f7485('0x5e6'),'msg':_0x500a06[_0x3f7485('0x25f4')]?JSON[_0x3f7485('0xbac')](_0x500a06[_0x3f7485('0x25f4')][_0x3f7485('0x1e70')]):_0x500a06[_0x3f7485('0x1586')]()});});}function _0xa5c35d(_0x558b13,_0x281529){const _0x179320=_0x365591,_0x4550f4=_0x35d306[_0x179320('0x1d26')]()[_0x179320('0xcdc')](_0x179320('0xced'))[_0x179320('0xf3c')](_0x179320('0x12b5')+(_0x558b13['name']||_0x558b13['id']&&_0x2cfb05()[_0x179320('0x114b')](_0x179320('0x2625'))+_0x558b13['id']||'interaction')+_0x179320('0xace')+_0x179320('0x3f3'))[_0x179320('0x8e8')](_0x179320('0xa04'))['targetEvent'](_0x281529)['ok']('OK')[_0x179320('0x3f')](_0x179320('0x2d3'));_0x35d306[_0x179320('0x1f80')](_0x4550f4)[_0x179320('0x1166')](function(){_0x5ec738(_0x558b13);},function(){const _0xb572a4=_0x179320;console[_0xb572a4('0x455')](_0xb572a4('0x2d3'));});}function _0x1cba4a(_0x7bfcdd){const _0x5491a0=_0x365591;_0x3c86c0['openchannelAccountInteractions']=_0x7bfcdd||{'count':0x0,'rows':[]};for(let _0x23a511=0x0;_0x23a511<_0x3c86c0['openchannelAccountInteractions'][_0x5491a0('0x269a')][_0x5491a0('0x264b')];_0x23a511+=0x1){const _0x2e754b=_0x3c86c0['openchannelAccountInteractions']['rows'][_0x23a511];_0x516f45(_0x2e754b),_0x2e754b[_0x5491a0('0x121b')]['name']=_0x3e0842(_0x2e754b);}}function _0xa7d939(){const _0x2fc53b=_0x365591;_0x3c86c0[_0x2fc53b('0x2218')][_0x2fc53b('0x1098')]=(_0x3c86c0[_0x2fc53b('0x2218')][_0x2fc53b('0x1a43')]-0x1)*_0x3c86c0[_0x2fc53b('0x2218')][_0x2fc53b('0x163f')],_0x3c86c0[_0x2fc53b('0x1f48')]=_0x147701['openchannelInteraction'][_0x2fc53b('0xd83')](_0x3c86c0[_0x2fc53b('0x2218')],_0x1cba4a)[_0x2fc53b('0xa44')];}function _0xbbc6f2(_0x30b084,_0x207ae7){const _0x49ae5f=_0x365591;_0x35d306[_0x49ae5f('0x1f80')]({'controller':_0x49ae5f('0x19ad'),'controllerAs':'vm','templateUrl':_0xbfcb18,'parent':angular[_0x49ae5f('0x1194')](_0x289ac3[_0x49ae5f('0x8d2')]),'targetEvent':_0x30b084,'clickOutsideToClose':!![],'onShowing':function(_0x327280){const _0x1e693e=_0x49ae5f;_0x327280['vm'][_0x1e693e('0x24d5')]({'id':0x1,'channel':_0x1e693e('0x26c'),'interaction':_0x207ae7,'spy':!![]},_0x495e0c[_0x1e693e('0x23ac')]['vm'][_0x1e693e('0xf8a')]);}});}function _0x5ec738(_0x2ecbf6){const _0x2e2e4d=_0x365591;_0x147701[_0x2e2e4d('0x1b9e')][_0x2e2e4d('0x906')]({'id':_0x2ecbf6['id']})[_0x2e2e4d('0xa44')][_0x2e2e4d('0x1166')](function(){const _0x166f8e=_0x2e2e4d;_0x2cfb05()[_0x166f8e('0x127f')](_0x3c86c0[_0x166f8e('0xa6d')][_0x166f8e('0x269a')],{'id':_0x2ecbf6['id']}),_0x3c86c0[_0x166f8e('0xa6d')][_0x166f8e('0x240f')]-=0x1,!_0x3c86c0[_0x166f8e('0xa6d')][_0x166f8e('0x269a')][_0x166f8e('0x264b')]&&_0xa7d939(),_0x107740[_0x166f8e('0x103b')]({'title':'Interaction\x20deleted!','msg':_0x2ecbf6[_0x166f8e('0x4f0')]?_0x2ecbf6[_0x166f8e('0x4f0')]+_0x166f8e('0x7cd'):''});})['catch'](function(_0x2ce498){const _0x3361e5=_0x2e2e4d;if(_0x2ce498[_0x3361e5('0x25f4')]&&_0x2ce498[_0x3361e5('0x25f4')][_0x3361e5('0x61a')]&&_0x2ce498['data'][_0x3361e5('0x61a')][_0x3361e5('0x264b')]){_0x3c86c0[_0x3361e5('0x61a')]=_0x2ce498[_0x3361e5('0x25f4')][_0x3361e5('0x61a')]||[{'message':_0x2ce498[_0x3361e5('0x1586')](),'type':_0x3361e5('0x20e9')}];for(let _0x32abfb=0x0;_0x32abfb<_0x2ce498['data'][_0x3361e5('0x61a')][_0x3361e5('0x264b')];_0x32abfb++){_0x107740[_0x3361e5('0xfc9')]({'title':_0x2ce498[_0x3361e5('0x25f4')][_0x3361e5('0x61a')][_0x32abfb]['type'],'msg':_0x2ce498['data'][_0x3361e5('0x61a')][_0x32abfb]['message']});}}else _0x107740[_0x3361e5('0xfc9')]({'title':_0x2ce498['status']?_0x3361e5('0x1e21')+_0x2ce498[_0x3361e5('0x52d')]+_0x3361e5('0x11e1')+_0x2ce498[_0x3361e5('0xe1b')]:_0x3361e5('0x20e9'),'msg':_0x2ce498[_0x3361e5('0x25f4')]?JSON['stringify'](_0x2ce498['data'][_0x3361e5('0x1e70')]):_0x2ce498[_0x3361e5('0x1e70')]||_0x2ce498['toString']()});});}function _0x1b8f2c(){const _0x2633f8=_0x365591,_0x27664c=angular['copy'](_0x3c86c0[_0x2633f8('0x1467')]);return _0x3c86c0[_0x2633f8('0x1467')]=[],_0x27664c;}function _0x46ce55(_0x387d36){const _0x4b7934=_0x365591,_0x20aa8f=_0x35d306[_0x4b7934('0x1d26')]()[_0x4b7934('0xcdc')](_0x4b7934('0x5dd'))[_0x4b7934('0xf3c')](_0x4b7934('0x12b5')+_0x3c86c0[_0x4b7934('0x1467')][_0x4b7934('0x264b')]+_0x4b7934('0x196d')+_0x4b7934('0x3f3'))[_0x4b7934('0x8e8')](_0x4b7934('0x1623'))[_0x4b7934('0x203b')](_0x387d36)['ok']('OK')[_0x4b7934('0x3f')](_0x4b7934('0x2d3'));_0x35d306[_0x4b7934('0x1f80')](_0x20aa8f)[_0x4b7934('0x1166')](function(){const _0x1f80f8=_0x4b7934;_0x3c86c0[_0x1f80f8('0x1467')][_0x1f80f8('0x2782')](function(_0x8bd09c){_0x5ec738(_0x8bd09c);}),_0x3c86c0[_0x1f80f8('0x1467')]=[];});}function _0x516f45(_0x49f9bf){const _0x1a9e63=_0x365591;if(_0x49f9bf['from'])_0x49f9bf[_0x1a9e63('0x15cf')]=_0x49f9bf[_0x1a9e63('0x661')];else _0x49f9bf['Contact']?_0x49f9bf[_0x1a9e63('0x15cf')]=(_0x49f9bf[_0x1a9e63('0x21a4')][_0x1a9e63('0x18cb')]||'')+'\x20'+(_0x49f9bf[_0x1a9e63('0x21a4')][_0x1a9e63('0xeb0')]||''):_0x49f9bf[_0x1a9e63('0x15cf')]=_0x35c339[_0x1a9e63('0x25cc')](_0x1a9e63('0x205a'));}function _0x3e0842(_0x557e36){const _0x14992b=_0x365591;if(_0x557e36[_0x14992b('0x122a')])return _0x557e36[_0x14992b('0x122a')]===_0x3c86c0[_0x14992b('0x98')]['id']?_0x35c339[_0x14992b('0x25cc')](_0x14992b('0x15ae')):_0x557e36[_0x14992b('0x121b')]['fullname']+'\x20<'+_0x557e36['Owner']['internal']+'>';return _0x35c339[_0x14992b('0x25cc')](_0x14992b('0x216b'));}let _0xb4e69c=!![],_0x1a452e=0x1;_0x495e0c[_0x365591('0xe83')](_0x365591('0x28b4'),function(_0x19f041,_0x329387){const _0x3c1650=_0x365591;_0xb4e69c?_0xeae5c0(function(){_0xb4e69c=![];}):(!_0x329387&&(_0x1a452e=_0x3c86c0[_0x3c1650('0x2218')]['page']),_0x19f041!==_0x329387&&(_0x3c86c0[_0x3c1650('0x2218')][_0x3c1650('0x1a43')]=0x1),!_0x19f041&&(_0x3c86c0[_0x3c1650('0x2218')]['page']=_0x1a452e),_0xa7d939());});}const _0x4d9526=_0x4cf64f,_0x44cf8d=_0x2734b2['p']+_0x36e6f4('0x1224');_0x17bc1c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q','$translate',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'Auth'];function _0x17bc1c(_0x62593b,_0x47f86e,_0x258f4c,_0x1469ee,_0x4012af,_0x3c210e,_0x1bd8e3,_0x3573e5,_0xfb087c,_0x16c7b3,_0x5dcc05){const _0x3d4da5=_0x36e6f4,_0x523cc1=this;_0x523cc1[_0x3d4da5('0x98')]=_0x5dcc05[_0x3d4da5('0x26cd')](),_0x523cc1[_0x3d4da5('0x77f')]={},_0x523cc1[_0x3d4da5('0x1216')]={'count':0x0,'rows':[]},_0x523cc1[_0x3d4da5('0xdc4')]=[],_0x523cc1[_0x3d4da5('0x243c')],_0x523cc1['query']={'fields':'createdAt,updatedAt,id,key,value,description','limit':0xa,'page':0x1},_0x523cc1[_0x3d4da5('0x24d5')]=_0x14d6f4,_0x523cc1['deleteConfirm']=_0x5112ec,_0x523cc1[_0x3d4da5('0x103b')]=_0x239673,_0x523cc1[_0x3d4da5('0x1d36')]=_0x13a897,_0x523cc1[_0x3d4da5('0x749')]=_0x337bf2,_0x523cc1[_0x3d4da5('0x28f')]=_0x2ecae0,_0x523cc1[_0x3d4da5('0x4d8')]=_0x5a9958,_0x523cc1[_0x3d4da5('0x1b09')]=_0x34ac0a;function _0x14d6f4(_0xa3c9ee,_0x24196b){const _0x120cb4=_0x3d4da5;_0x523cc1[_0x120cb4('0x77f')]=_0xa3c9ee,_0x523cc1[_0x120cb4('0x243c')]=typeof _0x24196b!=='undefined'?_0x24196b:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x523cc1[_0x120cb4('0x2218')]['OpenchannelAccountId']=_0x523cc1['openchannelAccount']['id'],_0x523cc1[_0x120cb4('0x2218')]['id']=_0x523cc1[_0x120cb4('0x77f')]['id'],_0x13a897();}function _0x5112ec(_0x5e850f,_0x49950a){const _0x47d29d=_0x3d4da5,_0x275a5f=_0x1bd8e3[_0x47d29d('0x1d26')]()[_0x47d29d('0xcdc')](_0x47d29d('0x182e'))[_0x47d29d('0xf3c')](_0x47d29d('0x12b5')+(_0x5e850f[_0x47d29d('0x4f0')]||_0x5e850f['id']&&_0x2cfb05()['upperFirst'](_0x47d29d('0x2228'))+_0x5e850f['id']||_0x47d29d('0xda2'))+_0x47d29d('0xace')+_0x47d29d('0x3f3'))[_0x47d29d('0x8e8')](_0x47d29d('0x16bd'))[_0x47d29d('0x203b')](_0x49950a)['ok']('OK')['cancel'](_0x47d29d('0x2d3'));_0x1bd8e3[_0x47d29d('0x1f80')](_0x275a5f)[_0x47d29d('0x1166')](function(){_0x5a9958(_0x5e850f);},function(){const _0x5b2dbc=_0x47d29d;console[_0x5b2dbc('0x455')](_0x5b2dbc('0x2d3'));});}function _0x239673(_0x527ff6){const _0x4a9c87=_0x3d4da5;_0x523cc1[_0x4a9c87('0x1216')]=_0x527ff6||{'count':0x0,'rows':[]};}function _0x13a897(){const _0xea6fce=_0x3d4da5;_0x523cc1[_0xea6fce('0x2218')][_0xea6fce('0x1098')]=(_0x523cc1['query']['page']-0x1)*_0x523cc1[_0xea6fce('0x2218')]['limit'],_0x523cc1['promise']=_0x16c7b3[_0xea6fce('0x77f')][_0xea6fce('0xab8')](_0x523cc1[_0xea6fce('0x2218')],_0x239673)[_0xea6fce('0xa44')];}function _0x337bf2(_0x24d5c7,_0x596790){const _0x467981=_0x3d4da5;_0x1bd8e3[_0x467981('0x1f80')]({'controller':_0x467981('0x1824'),'controllerAs':'vm','templateUrl':_0x44cf8d,'parent':angular[_0x467981('0x1194')](_0x3573e5[_0x467981('0x8d2')]),'targetEvent':_0x24d5c7,'clickOutsideToClose':!![],'locals':{'openchannelAccount':_0x523cc1['openchannelAccount'],'openchannelCannedAnswer':_0x596790,'openchannelCannedAnswers':_0x523cc1[_0x467981('0x1216')][_0x467981('0x269a')],'license':null,'setting':null,'crudPermissions':_0x523cc1['crudPermissions']}});}function _0x5a9958(_0x9cb0ee){const _0x21a1dd=_0x3d4da5;_0x16c7b3[_0x21a1dd('0x1b1f')][_0x21a1dd('0x906')]({'id':_0x9cb0ee['id']})[_0x21a1dd('0xa44')][_0x21a1dd('0x1166')](function(){const _0x3e3f81=_0x21a1dd;_0x2cfb05()['remove'](_0x523cc1['openchannelAccountOpenchannelCannedAnswers']['rows'],{'id':_0x9cb0ee['id']}),_0x523cc1['openchannelAccountOpenchannelCannedAnswers'][_0x3e3f81('0x240f')]-=0x1,!_0x523cc1[_0x3e3f81('0x1216')][_0x3e3f81('0x269a')][_0x3e3f81('0x264b')]&&_0x13a897(),_0xfb087c[_0x3e3f81('0x103b')]({'title':'OpenchannelCannedAnswer\x20deleted!','msg':_0x9cb0ee[_0x3e3f81('0x4f0')]?_0x9cb0ee['name']+'\x20has\x20been\x20deleted!':''});})[_0x21a1dd('0x1a80')](function(_0x253e60){const _0x506062=_0x21a1dd;if(_0x253e60['data']&&_0x253e60['data']['errors']&&_0x253e60[_0x506062('0x25f4')][_0x506062('0x61a')][_0x506062('0x264b')]){_0x523cc1[_0x506062('0x61a')]=_0x253e60[_0x506062('0x25f4')][_0x506062('0x61a')]||[{'message':_0x253e60['toString'](),'type':_0x506062('0x20e9')}];for(let _0x1d5d32=0x0;_0x1d5d32<_0x253e60[_0x506062('0x25f4')][_0x506062('0x61a')][_0x506062('0x264b')];_0x1d5d32++){_0xfb087c[_0x506062('0xfc9')]({'title':_0x253e60['data'][_0x506062('0x61a')][_0x1d5d32][_0x506062('0x1345')],'msg':_0x253e60[_0x506062('0x25f4')][_0x506062('0x61a')][_0x1d5d32][_0x506062('0x1e70')]});}}else _0xfb087c[_0x506062('0xfc9')]({'title':_0x253e60[_0x506062('0x52d')]?_0x506062('0x1e21')+_0x253e60[_0x506062('0x52d')]+_0x506062('0x11e1')+_0x253e60[_0x506062('0xe1b')]:_0x506062('0x20e9'),'msg':_0x253e60[_0x506062('0x25f4')]?JSON[_0x506062('0xbac')](_0x253e60[_0x506062('0x25f4')][_0x506062('0x1e70')]):_0x253e60['message']||_0x253e60[_0x506062('0x1586')]()});});}function _0x2ecae0(){const _0x30f6aa=_0x3d4da5,_0x6181e8=angular[_0x30f6aa('0x225f')](_0x523cc1['selectedOpenchannelAccountOpenchannelCannedAnswers']);return _0x523cc1[_0x30f6aa('0xdc4')]=[],_0x6181e8;}function _0x34ac0a(_0x3fa3d8){const _0x35d534=_0x3d4da5,_0x5b1834=_0x1bd8e3[_0x35d534('0x1d26')]()[_0x35d534('0xcdc')](_0x35d534('0x179a'))[_0x35d534('0xf3c')](_0x35d534('0x12b5')+_0x523cc1[_0x35d534('0xdc4')][_0x35d534('0x264b')]+_0x35d534('0x196d')+_0x35d534('0x3f3'))[_0x35d534('0x8e8')](_0x35d534('0x134b'))[_0x35d534('0x203b')](_0x3fa3d8)['ok']('OK')['cancel']('CANCEL');_0x1bd8e3['show'](_0x5b1834)[_0x35d534('0x1166')](function(){const _0x22f920=_0x35d534;_0x523cc1['selectedOpenchannelAccountOpenchannelCannedAnswers'][_0x22f920('0x2782')](function(_0x24aaf1){_0x5a9958(_0x24aaf1);}),_0x523cc1[_0x22f920('0xdc4')]=[];});}let _0x58c322=!![],_0x5c1aa5=0x1;_0x47f86e['$watch']('vm_dc.query.filter',function(_0x4fa7cf,_0x535ce7){const _0xb264d9=_0x3d4da5;_0x58c322?_0x3c210e(function(){_0x58c322=![];}):(!_0x535ce7&&(_0x5c1aa5=_0x523cc1['query'][_0xb264d9('0x1a43')]),_0x4fa7cf!==_0x535ce7&&(_0x523cc1[_0xb264d9('0x2218')][_0xb264d9('0x1a43')]=0x1),!_0x4fa7cf&&(_0x523cc1[_0xb264d9('0x2218')][_0xb264d9('0x1a43')]=_0x5c1aa5),_0x13a897());});}const _0x1a6214=_0x17bc1c;_0x29c8d9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x11b5'),_0x36e6f4('0xda2'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x29c8d9(_0x4f5299,_0x5999d6,_0x456717,_0x3d48ca,_0x2e1070,_0x35e43a,_0x400590,_0x2322af,_0x468751,_0x1e38b9,_0xfd3c47,_0x47d06f,_0x874cce,_0x20cf76){const _0x493da8=_0x36e6f4,_0x637b68=this;_0x637b68[_0x493da8('0x98')]=_0xfd3c47[_0x493da8('0x26cd')](),_0x637b68[_0x493da8('0x61a')]=[],_0x637b68['setting']=_0x874cce,_0x637b68[_0x493da8('0x5c9')]=_0x47d06f,_0x637b68[_0x493da8('0x243c')]=_0x20cf76,_0x637b68['hasModulePermissions']={},_0x637b68[_0x493da8('0x2900')]=_0x637b68[_0x493da8('0xf8a')]&&_0x637b68['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x637b68[_0x493da8('0xcdc')]=_0x493da8('0x131a'),_0x637b68['openchannelCannedAnswer']=angular['copy'](_0x468751),_0x637b68['openchannelCannedAnswers']=_0x2322af,_0x637b68[_0x493da8('0x1c1f')]=![];!_0x637b68[_0x493da8('0xda2')]&&(_0x637b68[_0x493da8('0xda2')]={},_0x637b68['title']=_0x493da8('0x2650'),_0x637b68[_0x493da8('0x1c1f')]=!![]);_0x5999d6[_0x493da8('0x23f')]['id']&&(_0x637b68[_0x493da8('0xda2')][_0x493da8('0xb8')]=_0x5999d6[_0x493da8('0x23f')]['id']);_0x637b68[_0x493da8('0x1f2d')]=_0x20ec3d,_0x637b68['saveOpenchannelCannedAnswer']=_0x42e1c1,_0x637b68[_0x493da8('0x16a5')]=_0x5014b8,_0x637b68['getDateFromString']=_0x55c04e,_0x637b68[_0x493da8('0x24a0')]=_0x241255;function _0x20ec3d(){const _0x732011=_0x493da8;_0x637b68[_0x732011('0x61a')]=[],_0x1e38b9[_0x732011('0x1b1f')][_0x732011('0x9cc')](_0x637b68[_0x732011('0xda2')])[_0x732011('0xa44')]['then'](function(_0x4bba9c){const _0x4aa669=_0x732011;_0x637b68[_0x4aa669('0x11b5')][_0x4aa669('0x2450')](_0x4bba9c[_0x4aa669('0x2876')]()),_0x400590['success']({'title':'OpenchannelCannedAnswer\x20properly\x20created','msg':_0x637b68[_0x4aa669('0xda2')][_0x4aa669('0x4f0')]?_0x637b68[_0x4aa669('0xda2')]['name']+_0x4aa669('0x1eda'):''}),_0x241255(_0x4bba9c);})[_0x732011('0x1a80')](function(_0x35000a){const _0x4fb20d=_0x732011;if(_0x35000a[_0x4fb20d('0x25f4')]&&_0x35000a[_0x4fb20d('0x25f4')][_0x4fb20d('0x61a')]&&_0x35000a[_0x4fb20d('0x25f4')]['errors'][_0x4fb20d('0x264b')]){_0x637b68[_0x4fb20d('0x61a')]=_0x35000a[_0x4fb20d('0x25f4')]['errors']||[{'message':_0x35000a['toString'](),'type':'api.cannedAnswer.save'}];for(let _0x2b1c46=0x0;_0x2b1c46<_0x35000a[_0x4fb20d('0x25f4')][_0x4fb20d('0x61a')][_0x4fb20d('0x264b')];_0x2b1c46+=0x1){_0x400590['error']({'title':_0x35000a['data'][_0x4fb20d('0x61a')][_0x2b1c46]['type'],'msg':_0x35000a[_0x4fb20d('0x25f4')][_0x4fb20d('0x61a')][_0x2b1c46][_0x4fb20d('0x1e70')]});}}else _0x400590[_0x4fb20d('0xfc9')]({'title':_0x35000a[_0x4fb20d('0x52d')]?_0x4fb20d('0x1e21')+_0x35000a[_0x4fb20d('0x52d')]+_0x4fb20d('0x11e1')+_0x35000a[_0x4fb20d('0xe1b')]:_0x4fb20d('0xcca'),'msg':_0x35000a[_0x4fb20d('0x25f4')]?JSON[_0x4fb20d('0xbac')](_0x35000a[_0x4fb20d('0x25f4')][_0x4fb20d('0x1e70')]):_0x35000a[_0x4fb20d('0x1586')]()});});}function _0x42e1c1(){const _0xba593c=_0x493da8;_0x637b68[_0xba593c('0x61a')]=[],_0x1e38b9['cannedAnswer'][_0xba593c('0x1449')]({'id':_0x637b68[_0xba593c('0xda2')]['id']},_0x637b68['openchannelCannedAnswer'])[_0xba593c('0xa44')][_0xba593c('0x1166')](function(_0x11c024){const _0x3e5a5b=_0xba593c,_0x4992a8=_0x2cfb05()[_0x3e5a5b('0xc38')](_0x637b68[_0x3e5a5b('0x11b5')],{'id':_0x11c024['id']});_0x4992a8&&_0x2cfb05()[_0x3e5a5b('0xcc3')](_0x4992a8,_0x2cfb05()['pick'](_0x11c024[_0x3e5a5b('0x2876')](),_0x2cfb05()[_0x3e5a5b('0x14a4')](_0x4992a8))),_0x400590[_0x3e5a5b('0x103b')]({'title':'OpenchannelCannedAnswer\x20properly\x20saved!','msg':_0x637b68[_0x3e5a5b('0xda2')][_0x3e5a5b('0x4f0')]?_0x637b68[_0x3e5a5b('0xda2')][_0x3e5a5b('0x4f0')]+_0x3e5a5b('0x7d'):''}),_0x241255(_0x11c024);})[_0xba593c('0x1a80')](function(_0x2f25c8){const _0x5c0542=_0xba593c;if(_0x2f25c8[_0x5c0542('0x25f4')]&&_0x2f25c8[_0x5c0542('0x25f4')][_0x5c0542('0x61a')]&&_0x2f25c8[_0x5c0542('0x25f4')][_0x5c0542('0x61a')][_0x5c0542('0x264b')]){_0x637b68[_0x5c0542('0x61a')]=_0x2f25c8[_0x5c0542('0x25f4')]['errors']||[{'message':_0x2f25c8['toString'](),'type':'api.cannedAnswer.update'}];for(let _0x4998dd=0x0;_0x4998dd<_0x2f25c8[_0x5c0542('0x25f4')][_0x5c0542('0x61a')][_0x5c0542('0x264b')];_0x4998dd++){_0x400590['error']({'title':_0x2f25c8['data']['errors'][_0x4998dd][_0x5c0542('0x1345')],'msg':_0x2f25c8['data'][_0x5c0542('0x61a')][_0x4998dd][_0x5c0542('0x1e70')]});}}else _0x400590[_0x5c0542('0xfc9')]({'title':_0x2f25c8[_0x5c0542('0x52d')]?'API:'+_0x2f25c8[_0x5c0542('0x52d')]+_0x5c0542('0x11e1')+_0x2f25c8[_0x5c0542('0xe1b')]:_0x5c0542('0x122e'),'msg':_0x2f25c8[_0x5c0542('0x25f4')]?JSON[_0x5c0542('0xbac')](_0x2f25c8[_0x5c0542('0x25f4')]['message']):_0x2f25c8[_0x5c0542('0x1586')]()});});}function _0x5014b8(_0x2ac0a9){const _0x5a46a0=_0x493da8;_0x637b68[_0x5a46a0('0x61a')]=[];const _0x30a3d1=_0x3d48ca[_0x5a46a0('0x1d26')]()[_0x5a46a0('0xcdc')](_0x5a46a0('0x7fb'))['content']('The\x20openchannelCannedAnswer\x20will\x20be\x20deleted.')[_0x5a46a0('0x8e8')](_0x5a46a0('0x2470'))['ok'](_0x5a46a0('0x18'))[_0x5a46a0('0x3f')](_0x5a46a0('0x497'))[_0x5a46a0('0x203b')](_0x2ac0a9);_0x3d48ca[_0x5a46a0('0x1f80')](_0x30a3d1)['then'](function(){const _0x197769=_0x5a46a0;_0x1e38b9['cannedAnswer'][_0x197769('0x906')]({'id':_0x637b68[_0x197769('0xda2')]['id']})['$promise'][_0x197769('0x1166')](function(){const _0x471e14=_0x197769;_0x2cfb05()[_0x471e14('0x127f')](_0x637b68['openchannelCannedAnswers'],{'id':_0x637b68[_0x471e14('0xda2')]['id']}),_0x400590[_0x471e14('0x103b')]({'title':_0x471e14('0x1638'),'msg':(_0x637b68['openchannelCannedAnswer'][_0x471e14('0x4f0')]||_0x471e14('0xda2'))+'\x20has\x20been\x20deleted!'}),_0x241255(_0x637b68[_0x471e14('0xda2')]);})[_0x197769('0x1a80')](function(_0x5f927d){const _0x17f1af=_0x197769;if(_0x5f927d[_0x17f1af('0x25f4')]&&_0x5f927d[_0x17f1af('0x25f4')][_0x17f1af('0x61a')]&&_0x5f927d['data']['errors'][_0x17f1af('0x264b')]){_0x637b68[_0x17f1af('0x61a')]=_0x5f927d[_0x17f1af('0x25f4')][_0x17f1af('0x61a')]||[{'message':_0x5f927d['toString'](),'type':'api.cannedAnswer.delete'}];for(let _0x92618e=0x0;_0x92618e<_0x5f927d[_0x17f1af('0x25f4')]['errors']['length'];_0x92618e++){_0x400590['error']({'title':_0x5f927d[_0x17f1af('0x25f4')][_0x17f1af('0x61a')][_0x92618e][_0x17f1af('0x1345')],'msg':_0x5f927d[_0x17f1af('0x25f4')][_0x17f1af('0x61a')][_0x92618e]['message']});}}else _0x400590[_0x17f1af('0xfc9')]({'title':_0x5f927d[_0x17f1af('0x52d')]?'API:'+_0x5f927d[_0x17f1af('0x52d')]+_0x17f1af('0x11e1')+_0x5f927d[_0x17f1af('0xe1b')]:_0x17f1af('0x1da9'),'msg':_0x5f927d[_0x17f1af('0x25f4')]?JSON[_0x17f1af('0xbac')](_0x5f927d['data'][_0x17f1af('0x1e70')]):_0x5f927d[_0x17f1af('0x1e70')]||_0x5f927d[_0x17f1af('0x1586')]()});});},function(){});}function _0x55c04e(_0x3a3c19){return _0x3a3c19===null?undefined:new Date(_0x3a3c19);}function _0x241255(_0xf067c7){const _0x2ba29b=_0x493da8;_0x3d48ca[_0x2ba29b('0x1197')](_0xf067c7);}}const _0x243177=_0x29c8d9;_0x20ade8['$inject']=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),'$mdDialog','$document','$timeout','$translate',_0x36e6f4('0x19e3'),'toasty','Auth'];function _0x20ade8(_0x58459c,_0x570838,_0x4395eb,_0x55a5ea,_0x1030f7,_0x50ae79,_0x468a6f,_0x363b24,_0x48ea90,_0x4d9105,_0x354366){const _0x24ad08=_0x36e6f4,_0x551b2c=this;_0x551b2c['currentUser']=_0x354366['getCurrentUser'](),_0x551b2c[_0x24ad08('0x4ea')]={'count':0x0,'rows':[]},_0x551b2c[_0x24ad08('0x1082')]=[],_0x551b2c[_0x24ad08('0x243c')],_0x551b2c['levels']={'first':_0x24ad08('0xc31'),'second':_0x24ad08('0x580'),'third':_0x24ad08('0x1144')},_0x551b2c[_0x24ad08('0x2218')]={'fields':'id,level,name,description,ParentId,createdAt,updatedAt','sort':_0x24ad08('0x14dc'),'limit':0xa,'page':0x1},_0x551b2c[_0x24ad08('0x24d5')]=_0xb1434e,_0x551b2c['deleteConfirm']=_0x1cebd9,_0x551b2c['success']=_0x220ea1,_0x551b2c[_0x24ad08('0x3e')]=_0x1b91a6,_0x551b2c[_0x24ad08('0x782')]=_0x329913,_0x551b2c[_0x24ad08('0x27c6')]=_0x33051f,_0x551b2c[_0x24ad08('0x4e2')]=_0xc1db09,_0x551b2c[_0x24ad08('0x14b5')]=_0x157efa,_0x551b2c[_0x24ad08('0x205e')]=_0x219307,_0x551b2c[_0x24ad08('0xd7c')]=_0x26ffbc;function _0xb1434e(_0x315a1a,_0x264483){const _0x160ebc=_0x24ad08;_0x551b2c[_0x160ebc('0x77f')]=_0x315a1a||{},_0x551b2c[_0x160ebc('0x243c')]=typeof _0x264483!==_0x160ebc('0x1048')?_0x264483:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x551b2c['query'][_0x160ebc('0xb8')]=_0x551b2c[_0x160ebc('0x77f')]['id'],_0x551b2c[_0x160ebc('0x2218')]['id']=_0x551b2c[_0x160ebc('0x77f')]['id'],_0x1b91a6();}function _0x329913(_0x58657a,_0x5c62f3){const _0x3eb1f3=_0x24ad08;_0x1030f7['show']({'controller':_0x3eb1f3('0x17a3'),'controllerAs':'vm','templateUrl':_0x14e8d3,'parent':angular[_0x3eb1f3('0x1194')](_0x50ae79[_0x3eb1f3('0x8d2')]),'targetEvent':_0x58657a,'clickOutsideToClose':!![],'locals':{'disposition':_0x5c62f3,'dispositions':_0x551b2c[_0x3eb1f3('0x4ea')]['rows'],'model':{'id':_0x551b2c[_0x3eb1f3('0x77f')]['id'],'field':'OpenchannelAccountId'},'license':null,'setting':null,'crudPermissions':_0x551b2c[_0x3eb1f3('0x243c')]}})['then'](function(_0x2332e0){if(_0x2332e0)_0x1b91a6();});}function _0x1cebd9(_0x10ac36,_0x1b68b1){const _0x1b8220=_0x24ad08,_0x2b625d=_0x2cfb05()['some'](_0x551b2c['dispositions'][_0x1b8220('0x269a')],['ParentId',_0x10ac36['id']]),_0x3d5133=_0x1030f7[_0x1b8220('0x1d26')]()['title'](_0x363b24[_0x1b8220('0x25cc')](_0x1b8220('0x1ac5')))[_0x1b8220('0xacc')](_0x363b24['instant'](_0x1b8220('0x92f')+(_0x2b625d?_0x1b8220('0xc7a'):_0x1b8220('0x251e')),{'name':_0x10ac36['name']}))['ariaLabel'](_0x1b8220('0x1af2'))[_0x1b8220('0x203b')](_0x1b68b1)['ok']('OK')['cancel'](_0x363b24[_0x1b8220('0x25cc')](_0x1b8220('0x12a3')));_0x1030f7['show'](_0x3d5133)[_0x1b8220('0x1166')](function(){_0x33051f(_0x10ac36);});}function _0x220ea1(_0x24828e){_0x551b2c['dispositions']=_0x24828e||{'count':0x0,'rows':[]};}function _0x1b91a6(){const _0x245ac0=_0x24ad08;_0x551b2c[_0x245ac0('0x2218')][_0x245ac0('0x1098')]=(_0x551b2c[_0x245ac0('0x2218')][_0x245ac0('0x1a43')]-0x1)*_0x551b2c[_0x245ac0('0x2218')][_0x245ac0('0x163f')],_0x551b2c[_0x245ac0('0x1f48')]=_0x48ea90[_0x245ac0('0x77f')][_0x245ac0('0x3e')](_0x551b2c[_0x245ac0('0x2218')],_0x220ea1)[_0x245ac0('0xa44')];}function _0x33051f(_0x50e5da){const _0x586e24=_0x24ad08;_0x48ea90[_0x586e24('0x12e8')][_0x586e24('0x906')]({'id':_0x50e5da['id']})[_0x586e24('0xa44')]['then'](function(){const _0x516cb3=_0x586e24;_0x1b91a6(),_0x4d9105[_0x516cb3('0x103b')]({'title':_0x363b24[_0x516cb3('0x25cc')](_0x516cb3('0x1ca6'))});})[_0x586e24('0x1a80')](function(_0x34bdc3){const _0xaee54=_0x586e24;if(_0x34bdc3[_0xaee54('0x25f4')]&&_0x34bdc3[_0xaee54('0x25f4')]['errors']&&_0x34bdc3[_0xaee54('0x25f4')]['errors'][_0xaee54('0x264b')]){_0x551b2c[_0xaee54('0x61a')]=_0x34bdc3[_0xaee54('0x25f4')]['errors']||[{'message':_0x34bdc3[_0xaee54('0x1586')](),'type':_0xaee54('0x1b2c')}];for(let _0x58e8e2=0x0;_0x58e8e2<_0x34bdc3[_0xaee54('0x25f4')][_0xaee54('0x61a')]['length'];_0x58e8e2++){_0x4d9105[_0xaee54('0xfc9')]({'title':_0x34bdc3['data'][_0xaee54('0x61a')][_0x58e8e2][_0xaee54('0x1345')],'msg':_0x34bdc3[_0xaee54('0x25f4')][_0xaee54('0x61a')][_0x58e8e2][_0xaee54('0x1e70')]});}}else _0x4d9105[_0xaee54('0xfc9')]({'title':_0x34bdc3['status']?_0xaee54('0x1e21')+_0x34bdc3['status']+_0xaee54('0x11e1')+_0x34bdc3[_0xaee54('0xe1b')]:_0xaee54('0x1b2c'),'msg':_0x34bdc3[_0xaee54('0x25f4')]?JSON[_0xaee54('0xbac')](_0x34bdc3['data']['message']):_0x34bdc3[_0xaee54('0x1e70')]||_0x34bdc3[_0xaee54('0x1586')]()});});}function _0xc1db09(){const _0x1e46fe=_0x24ad08,_0x4c2da7=angular[_0x1e46fe('0x225f')](_0x551b2c[_0x1e46fe('0x1082')]);return _0x551b2c[_0x1e46fe('0x1082')]=[],_0x4c2da7;}function _0x157efa(_0x37c2f8){const _0x177e03=_0x24ad08,_0x22857c=_0x1030f7[_0x177e03('0x1d26')]()[_0x177e03('0xcdc')](_0x363b24[_0x177e03('0x25cc')](_0x177e03('0x24fd')))['content'](_0x363b24[_0x177e03('0x25cc')](_0x177e03('0x223e'),{'total':_0x551b2c[_0x177e03('0x1082')][_0x177e03('0x264b')]}))[_0x177e03('0x8e8')]('Delete\x20dispositions')['targetEvent'](_0x37c2f8)['ok']('OK')[_0x177e03('0x3f')](_0x363b24[_0x177e03('0x25cc')](_0x177e03('0x12a3')));_0x1030f7[_0x177e03('0x1f80')](_0x22857c)['then'](function(){const _0x477a96=_0x177e03;_0x551b2c[_0x477a96('0x1082')][_0x477a96('0x2782')](function(_0x342001){_0x33051f(_0x342001);}),_0x551b2c[_0x477a96('0x1082')]=[];});}function _0x219307(){const _0xbb3d93=_0x24ad08;_0x551b2c[_0xbb3d93('0x1082')]=[];}function _0x26ffbc(){const _0xded7a8=_0x24ad08;_0x551b2c['selectedDispositions']=_0x551b2c[_0xded7a8('0x4ea')][_0xded7a8('0x269a')];}let _0x349a8b=!![],_0x2a4edd=0x1;_0x58459c[_0x24ad08('0xe83')](_0x24ad08('0x28b4'),function(_0x4eab5c,_0x190c2d){const _0x5b4edd=_0x24ad08;_0x349a8b?_0x468a6f(function(){_0x349a8b=![];}):(!_0x190c2d&&(_0x2a4edd=_0x551b2c[_0x5b4edd('0x2218')][_0x5b4edd('0x1a43')]),_0x4eab5c!==_0x190c2d&&(_0x551b2c[_0x5b4edd('0x2218')][_0x5b4edd('0x1a43')]=0x1),!_0x4eab5c&&(_0x551b2c[_0x5b4edd('0x2218')]['page']=_0x2a4edd),_0x1b91a6());});}const _0x1f0572=_0x20ade8,_0x54eeb8=_0x2734b2['p']+_0x36e6f4('0xd46');_0x278f64['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'api','toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x77f'),_0x36e6f4('0x17aa')];function _0x278f64(_0x17ae97,_0xce2aa9,_0x35b4a8,_0x2d10c2,_0x8380a,_0x47f87c,_0x4c19fb,_0x3b1f40,_0x184a65,_0x3ab2db,_0x55996d,_0x316111){const _0x582c48=_0x36e6f4,_0x12b956=this;_0x12b956[_0x582c48('0x98')]=_0x3ab2db[_0x582c48('0x26cd')](),_0x12b956['license']=_0x47f87c,_0x12b956[_0x582c48('0xf8a')]=_0x4c19fb,_0x12b956[_0x582c48('0x2900')]=_0x12b956[_0x582c48('0xf8a')][_0x582c48('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x12b956[_0x582c48('0x246b')]=_0xce2aa9[_0x582c48('0x6f1')]()+_0x582c48('0xc51')+_0xce2aa9[_0x582c48('0x1690')](),_0x12b956[_0x582c48('0x77f')]=_0x55996d||_0x17ae97['params'][_0x582c48('0x77f')]||{},_0x12b956[_0x582c48('0x17aa')]=_0x316111&&_0x316111['count']==0x1?_0x316111['rows'][0x0]:null,_0x12b956[_0x582c48('0x243c')]=_0x3ab2db[_0x582c48('0xd87')](_0x12b956[_0x582c48('0x17aa')]?_0x12b956[_0x582c48('0x17aa')]['crudPermissions']:null),_0x12b956[_0x582c48('0x128b')]={},_0x12b956[_0x582c48('0x2669')]=_0x17ae97['params'][_0x582c48('0xbe3')]||0x0,_0x12b956[_0x582c48('0x1728')]=_0x18638e,_0x12b956[_0x582c48('0x31d')]=_0x184a65[_0x582c48('0x1fa1')],_0x12b956[_0x582c48('0x9c6')]=_0xfeee31,_0x12b956['saveOpenchannelAccount']=_0xc77c8c,_0x3ab2db['hasRole']('admin')?_0x3b1f40['cmList'][_0x582c48('0xd83')]({'fields':_0x582c48('0x1776'),'sort':_0x582c48('0x4f0')})['$promise'][_0x582c48('0x1166')](function(_0x14d386){const _0x237f0d=_0x582c48;_0x12b956[_0x237f0d('0x8de')]=_0x14d386[_0x237f0d('0x269a')]||[];})[_0x582c48('0x1a80')](function(_0xd69053){const _0x16f541=_0x582c48;_0x184a65[_0x16f541('0xfc9')]({'title':_0xd69053[_0x16f541('0x52d')]?_0x16f541('0x1e21')+_0xd69053[_0x16f541('0x52d')]+'\x20-\x20'+_0xd69053[_0x16f541('0xe1b')]:'SYSTEM:GET_LISTS','msg':_0xd69053['data']?JSON[_0x16f541('0xbac')](_0xd69053[_0x16f541('0x25f4')]):_0xd69053['toString']()});}):_0x3b1f40[_0x582c48('0xdd9')][_0x582c48('0xd83')]({'fields':_0x582c48('0x1776'),'sort':'name'})[_0x582c48('0xa44')][_0x582c48('0x1166')](function(_0x22d83c){const _0x206165=_0x582c48;_0x12b956[_0x206165('0x8de')]=_0x22d83c[_0x206165('0x269a')]||[];})[_0x582c48('0x1166')](function(){const _0xadf831=_0x582c48;return _0x3b1f40[_0xadf831('0x17aa')]['get']({'userProfileId':_0x12b956[_0xadf831('0x98')][_0xadf831('0xb86')],'sectionId':0x12d})['$promise'];})[_0x582c48('0x1166')](function(_0x2c51ef){const _0x2e6cde=_0x582c48,_0x437600=_0x2c51ef&&_0x2c51ef[_0x2e6cde('0x269a')]?_0x2c51ef[_0x2e6cde('0x269a')][0x0]:null;if(!_0x437600){const _0x54e8c3=[];let _0x427d10=null;_0x12b956['openchannelAccount']&&(_0x427d10=_0x2cfb05()[_0x2e6cde('0xc38')](_0x12b956[_0x2e6cde('0x8de')],{'id':Number(_0x12b956[_0x2e6cde('0x77f')][_0x2e6cde('0x23c')])}));for(let _0xe86907=0x0;_0xe86907<_0x12b956[_0x2e6cde('0x8de')][_0x2e6cde('0x264b')];_0xe86907++){_0x427d10&&_0x12b956['lists'][_0xe86907]['id']===_0x427d10['id']&&(_0x12b956[_0x2e6cde('0x8de')][_0xe86907]['canSelect']=![],_0x54e8c3[_0x2e6cde('0x1514')](_0x12b956[_0x2e6cde('0x8de')][_0xe86907]));}_0x12b956[_0x2e6cde('0x8de')]=_0x54e8c3;}else{if(!_0x437600[_0x2e6cde('0x1a2b')])return _0x3b1f40[_0x2e6cde('0x4b5')][_0x2e6cde('0xd83')]({'sectionId':_0x437600['id']})['$promise'][_0x2e6cde('0x1166')](function(_0x6ba8bd){const _0x1d969d=_0x2e6cde,_0x59c07e=_0x2cfb05()[_0x1d969d('0x2563')](_0x6ba8bd[_0x1d969d('0x269a')],function(_0x33b437){const _0x31db17=_0x1d969d;return _0x2cfb05()[_0x31db17('0xc38')](_0x12b956['lists'],{'id':_0x33b437['resourceId']});});let _0x385f48=null;_0x12b956[_0x1d969d('0x77f')]&&(_0x385f48=_0x2cfb05()[_0x1d969d('0xc38')](_0x12b956['lists'],{'id':Number(_0x12b956[_0x1d969d('0x77f')][_0x1d969d('0x23c')])}));if(_0x385f48&&!_0x2cfb05()['some'](_0x59c07e,['id',_0x385f48['id']])){const _0x175aee=_0x2cfb05()[_0x1d969d('0xc38')](_0x12b956['lists'],{'id':_0x385f48['id']});_0x175aee[_0x1d969d('0x2378')]=![],_0x59c07e[_0x1d969d('0x1514')](_0x175aee);}_0x12b956['lists']=_0x59c07e;});}})[_0x582c48('0x1a80')](function(_0x17ba07){const _0x330186=_0x582c48;_0x184a65['error']({'title':_0x17ba07['status']?_0x330186('0x1e21')+_0x17ba07[_0x330186('0x52d')]+_0x330186('0x11e1')+_0x17ba07[_0x330186('0xe1b')]:_0x330186('0x1248'),'msg':_0x17ba07[_0x330186('0x25f4')]?JSON[_0x330186('0xbac')](_0x17ba07[_0x330186('0x25f4')]):_0x17ba07['toString']()});}),_0x3b1f40['cmContact'][_0x582c48('0x23d0')]({'id':_0x12b956[_0x582c48('0x77f')][_0x582c48('0x23c')]})[_0x582c48('0xa44')][_0x582c48('0x1166')](function(_0x2db751){const _0x312f59=_0x582c48;_0x12b956['fields']=[],_0x2db751=_0x2cfb05()['values'](_0x2db751[_0x312f59('0x2876')]());const _0x2da2e8=['id',_0x312f59('0x262'),_0x312f59('0x6f9'),'deletedAt',_0x312f59('0x1c5e'),'ListId',_0x312f59('0x537')];for(let _0x31d751=0x0;_0x31d751<_0x2db751[_0x312f59('0x264b')];_0x31d751++){!_0x2cfb05()[_0x312f59('0x1257')](_0x2da2e8,_0x2db751[_0x31d751]['columnName'])&&_0x12b956[_0x312f59('0xfe2')][_0x312f59('0x1514')](_0x2db751[_0x31d751]);}})[_0x582c48('0x1a80')](function(_0x1f6eda){const _0x9bb8a9=_0x582c48;_0x184a65[_0x9bb8a9('0xfc9')]({'title':_0x1f6eda['status']?_0x9bb8a9('0x1e21')+_0x1f6eda[_0x9bb8a9('0x52d')]+_0x9bb8a9('0x11e1')+_0x1f6eda[_0x9bb8a9('0xe1b')]:'SYSTEM:GET_FIELDS','msg':_0x1f6eda[_0x9bb8a9('0x25f4')]?JSON[_0x9bb8a9('0xbac')](_0x1f6eda[_0x9bb8a9('0x25f4')]):_0x1f6eda['toString']()});}),_0x3ab2db[_0x582c48('0x1ac6')](_0x582c48('0xa7c'))?_0x3b1f40['pause']['get']({'fields':_0x582c48('0xcb8'),'sort':_0x582c48('0x4f0'),'nolimit':_0x582c48('0xf3b')})[_0x582c48('0xa44')][_0x582c48('0x1166')](function(_0x261033){const _0x3af612=_0x582c48;_0x12b956[_0x3af612('0xe29')]=_0x261033[_0x3af612('0x269a')]||[];})[_0x582c48('0x1a80')](function(_0x557a93){const _0x4d341f=_0x582c48;_0x184a65[_0x4d341f('0xfc9')]({'title':_0x557a93[_0x4d341f('0x52d')]?_0x4d341f('0x1e21')+_0x557a93[_0x4d341f('0x52d')]+_0x4d341f('0x11e1')+_0x557a93[_0x4d341f('0xe1b')]:'SYSTEM:GET_PAUSES','msg':_0x557a93[_0x4d341f('0x25f4')]?JSON[_0x4d341f('0xbac')](_0x557a93['data']):_0x557a93[_0x4d341f('0x1586')]()});}):_0x3b1f40[_0x582c48('0x1e77')][_0x582c48('0xd83')]({'fields':_0x582c48('0xcb8'),'sort':_0x582c48('0x4f0'),'nolimit':'true'})[_0x582c48('0xa44')][_0x582c48('0x1166')](function(_0x38428){const _0x598f62=_0x582c48;_0x12b956[_0x598f62('0xe29')]=_0x38428[_0x598f62('0x269a')]||[];})[_0x582c48('0x1166')](function(){const _0x545f32=_0x582c48;return _0x3b1f40[_0x545f32('0x17aa')][_0x545f32('0xd83')]({'userProfileId':_0x12b956[_0x545f32('0x98')][_0x545f32('0xb86')],'sectionId':0x3ed})['$promise'];})['then'](function(_0x57058e){const _0x20d807=_0x582c48,_0x3885a2=_0x57058e&&_0x57058e['rows']?_0x57058e[_0x20d807('0x269a')][0x0]:null;if(!_0x3885a2)_0x12b956[_0x20d807('0xe29')]=[];else{if(!_0x3885a2[_0x20d807('0x1a2b')])return _0x3b1f40[_0x20d807('0x4b5')][_0x20d807('0xd83')]({'sectionId':_0x3885a2['id']})[_0x20d807('0xa44')][_0x20d807('0x1166')](function(_0x1b1d4e){const _0x2b9ee2=_0x20d807,_0x1aa3f2=_0x2cfb05()[_0x2b9ee2('0x2563')](_0x1b1d4e[_0x2b9ee2('0x269a')],function(_0x273450){const _0x42df77=_0x2b9ee2;return _0x2cfb05()[_0x42df77('0xc38')](_0x12b956[_0x42df77('0xe29')],{'id':_0x273450[_0x42df77('0x24e8')]});});_0x12b956[_0x2b9ee2('0xe29')]['forEach'](function(_0x4633e0){const _0x3487f9=_0x2b9ee2;!_0x2cfb05()[_0x3487f9('0x1798')](_0x1aa3f2,['id',_0x4633e0['id']])&&(_0x4633e0['canSelect']=![]),_0x1aa3f2[_0x3487f9('0x1514')](_0x4633e0);}),_0x12b956[_0x2b9ee2('0xe29')]=_0x1aa3f2;});}})['catch'](function(_0x5c45cf){const _0x391c44=_0x582c48;_0x184a65[_0x391c44('0xfc9')]({'title':_0x5c45cf[_0x391c44('0x52d')]?'API:'+_0x5c45cf['status']+'\x20-\x20'+_0x5c45cf['statusText']:'SYSTEM:GETpauses','msg':_0x5c45cf['data']?JSON[_0x391c44('0xbac')](_0x5c45cf[_0x391c44('0x25f4')]):_0x5c45cf[_0x391c44('0x1586')]()});});function _0x18638e(_0x127c1e,_0x55a7b8){const _0x27b472=_0x582c48;_0x35b4a8[_0x27b472('0x1f80')]({'controller':_0x27b472('0x1950'),'controllerAs':'vm','templateUrl':_0x54eeb8,'parent':angular[_0x27b472('0x1194')](_0x2d10c2[_0x27b472('0x8d2')]),'targetEvent':_0x55a7b8,'clickOutsideToClose':!![],'locals':{'openchannelAccount':_0x127c1e,'openchannelAccounts':_0x12b956[_0x27b472('0x28ff')]?_0x12b956['openchannelAccounts'][_0x27b472('0x269a')]:[],'crudPermissions':_0x12b956[_0x27b472('0x243c')],'realtime':![]}});}function _0xfeee31(){const _0x3c4ace=_0x582c48;_0x17ae97['go']('app.openchannel.openchannelAccounts',{},{'reload':_0x3c4ace('0x17f2')});}function _0xc77c8c(){const _0x18ff3d=_0x582c48;_0x3b1f40[_0x18ff3d('0x77f')]['update']({'id':_0x12b956[_0x18ff3d('0x77f')]['id']},_0x12b956['openchannelAccount'])[_0x18ff3d('0xa44')]['then'](function(){const _0x37cfac=_0x18ff3d;_0x184a65[_0x37cfac('0x103b')]({'title':'OpenchannelAccount\x20updated!','msg':_0x12b956[_0x37cfac('0x77f')][_0x37cfac('0x4f0')]?_0x12b956[_0x37cfac('0x77f')][_0x37cfac('0x4f0')]+'\x20has\x20been\x20updated!':''});})['catch'](function(_0x18cae7){const _0x37cfc9=_0x18ff3d;_0x184a65[_0x37cfc9('0xfc9')]({'title':_0x18cae7[_0x37cfc9('0x52d')]?_0x37cfc9('0x1e21')+_0x18cae7[_0x37cfc9('0x52d')]+_0x37cfc9('0x11e1')+_0x18cae7['statusText']:'SYSTEM:GETopenchannelAccount','msg':_0x18cae7[_0x37cfc9('0x25f4')]?JSON['stringify'](_0x18cae7[_0x37cfc9('0x25f4')]):_0x18cae7[_0x37cfc9('0x1586')]()});});}}const _0x40a44e=_0x278f64,_0x233e9c=_0x2734b2['p']+_0x36e6f4('0x14f7');_0x4bf5c5[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x28ff'),'userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x4bf5c5(_0x150b35,_0x596801,_0x3cf9d7,_0x3faefc,_0x165afc,_0x276e88,_0x50176c,_0x165c00,_0x4f31e3,_0x6491f7,_0x4a4296,_0x1343c6,_0x4ee4f5,_0x2b8d59,_0x145863,_0x4fb1b4,_0x202b48){const _0x400d70=_0x36e6f4,_0x3b40c8=this;_0x3b40c8[_0x400d70('0x5c9')]=_0x4fb1b4,_0x3b40c8[_0x400d70('0xf8a')]=_0x202b48,_0x3b40c8[_0x400d70('0x98')]=_0x145863[_0x400d70('0x26cd')](),_0x3b40c8[_0x400d70('0x28ff')]=_0x4f31e3||{'count':0x0,'rows':[]},_0x3b40c8[_0x400d70('0x7f')]=_0x6491f7,_0x3b40c8['userProfileSection']=_0x4a4296&&_0x4a4296[_0x400d70('0x240f')]==0x1?_0x4a4296['rows'][0x0]:null,_0x3b40c8[_0x400d70('0x243c')]=_0x145863[_0x400d70('0xd87')](_0x3b40c8['userProfileSection']?_0x3b40c8['userProfileSection']['crudPermissions']:null),_0x3b40c8[_0x400d70('0x916')]=_0x400d70('0x28ff'),_0x3b40c8[_0x400d70('0xef5')]='',_0x3b40c8['listOrderAsc']=null,_0x3b40c8[_0x400d70('0xe81')]=[],_0x3b40c8[_0x400d70('0x2218')]={'fields':_0x400d70('0x98f'),'sort':_0x400d70('0x14dc'),'limit':0xa,'page':0x1},_0x3b40c8[_0x400d70('0x1ff6')]=_0x742fe6,_0x3b40c8[_0x400d70('0x5e9')]=_0x3d4fc3,_0x3b40c8['agentadddialog']=_0x3f7635,_0x3b40c8['deleteconfirm']=_0x581e89,_0x3b40c8['success']=_0x76384e,_0x3b40c8[_0x400d70('0xc48')]=_0x340e7a,_0x3b40c8[_0x400d70('0x58c')]=_0x47d7b9,_0x3b40c8[_0x400d70('0x1a90')]=_0x231d63,_0x3b40c8[_0x400d70('0xee1')]=_0x496991,_0x3b40c8[_0x400d70('0xafb')]=_0x1afc6b,_0x3b40c8[_0x400d70('0x921')]=_0x5d8083,_0x3b40c8[_0x400d70('0x386')]=_0x45826b,_0x145863[_0x400d70('0x1ac6')]('admin')?_0x1343c6[_0x400d70('0xdd9')]['get']({'fields':'id,name','sort':_0x400d70('0x4f0')})[_0x400d70('0xa44')][_0x400d70('0x1166')](function(_0xa92fcc){_0x3b40c8['lists']=_0xa92fcc['rows']||[];})[_0x400d70('0x1a80')](function(_0x19460a){const _0x3fc667=_0x400d70;_0x2b8d59[_0x3fc667('0xfc9')]({'title':_0x19460a[_0x3fc667('0x52d')]?_0x3fc667('0x1e21')+_0x19460a['status']+_0x3fc667('0x11e1')+_0x19460a[_0x3fc667('0xe1b')]:_0x3fc667('0x520'),'msg':_0x19460a['data']?JSON[_0x3fc667('0xbac')](_0x19460a[_0x3fc667('0x25f4')]):_0x19460a[_0x3fc667('0x1586')]()});}):_0x1343c6[_0x400d70('0xdd9')]['get']({'fields':_0x400d70('0x1776'),'sort':_0x400d70('0x4f0')})['$promise'][_0x400d70('0x1166')](function(_0x30a909){const _0x3a65fe=_0x400d70;_0x3b40c8[_0x3a65fe('0x8de')]=_0x30a909[_0x3a65fe('0x269a')]||[];})[_0x400d70('0x1166')](function(){const _0x20c797=_0x400d70;return _0x1343c6[_0x20c797('0x17aa')]['get']({'userProfileId':_0x3b40c8[_0x20c797('0x98')][_0x20c797('0xb86')],'sectionId':0x12d})['$promise'];})[_0x400d70('0x1166')](function(_0x4d9fdd){const _0x1359e9=_0x400d70,_0x3f11a6=_0x4d9fdd&&_0x4d9fdd[_0x1359e9('0x269a')]?_0x4d9fdd[_0x1359e9('0x269a')][0x0]:null;if(!_0x3f11a6){const _0x406455=[];let _0x5f0b88=null;_0x3b40c8[_0x1359e9('0x77f')]&&(_0x5f0b88=_0x2cfb05()[_0x1359e9('0xc38')](_0x3b40c8[_0x1359e9('0x8de')],{'id':Number(_0x3b40c8[_0x1359e9('0x77f')]['ListId'])}));for(let _0x44212b=0x0;_0x44212b<_0x3b40c8[_0x1359e9('0x8de')][_0x1359e9('0x264b')];_0x44212b++){_0x5f0b88&&_0x3b40c8['lists'][_0x44212b]['id']===_0x5f0b88['id']&&(_0x3b40c8[_0x1359e9('0x8de')][_0x44212b][_0x1359e9('0x2378')]=![],_0x406455[_0x1359e9('0x1514')](_0x3b40c8[_0x1359e9('0x8de')][_0x44212b]));}_0x3b40c8[_0x1359e9('0x8de')]=_0x406455;}else{if(!_0x3f11a6[_0x1359e9('0x1a2b')])return _0x1343c6['userProfileResource']['get']({'sectionId':_0x3f11a6['id']})[_0x1359e9('0xa44')]['then'](function(_0x8b2286){const _0x5641a5=_0x1359e9,_0x5a5c2b=_0x2cfb05()[_0x5641a5('0x2563')](_0x8b2286[_0x5641a5('0x269a')],function(_0x408152){const _0x5c4d6b=_0x5641a5;return _0x2cfb05()[_0x5c4d6b('0xc38')](_0x3b40c8[_0x5c4d6b('0x8de')],{'id':_0x408152[_0x5c4d6b('0x24e8')]});});let _0x130010=null;_0x3b40c8['openchannelAccount']&&(_0x130010=_0x2cfb05()[_0x5641a5('0xc38')](_0x3b40c8[_0x5641a5('0x8de')],{'id':Number(_0x3b40c8[_0x5641a5('0x77f')][_0x5641a5('0x23c')])}));if(_0x130010&&!_0x2cfb05()[_0x5641a5('0x1798')](_0x5a5c2b,['id',_0x130010['id']])){const _0x2d9d38=_0x2cfb05()[_0x5641a5('0xc38')](_0x3b40c8[_0x5641a5('0x8de')],{'id':_0x130010['id']});_0x2d9d38[_0x5641a5('0x2378')]=![],_0x5a5c2b[_0x5641a5('0x1514')](_0x2d9d38);}_0x3b40c8[_0x5641a5('0x8de')]=_0x5a5c2b;});}})[_0x400d70('0x1a80')](function(_0x288ee0){const _0x585de5=_0x400d70;_0x2b8d59[_0x585de5('0xfc9')]({'title':_0x288ee0[_0x585de5('0x52d')]?_0x585de5('0x1e21')+_0x288ee0[_0x585de5('0x52d')]+'\x20-\x20'+_0x288ee0['statusText']:'SYSTEM:GETlists','msg':_0x288ee0['data']?JSON['stringify'](_0x288ee0[_0x585de5('0x25f4')]):_0x288ee0['toString']()});});function _0x742fe6(_0x19c748){const _0x31c892=_0x400d70;_0x3cf9d7['go']('app.openchannel.openchannelAccounts.edit',{'id':_0x19c748['id'],'openchannelAccount':_0x19c748,'crudPermissions':_0x3b40c8[_0x31c892('0x243c')]});}function _0x3d4fc3(_0x44eaa6){const _0x527d24=_0x400d70;_0x3cf9d7['go'](_0x527d24('0xa75'),{'id':_0x44eaa6['id'],'tab':0x5});}function _0x3f7635(_0x31333c,_0x3e313c){const _0x2a6926=_0x400d70;_0x165afc[_0x2a6926('0x1f80')]({'controller':_0x2a6926('0x1950'),'controllerAs':'vm','templateUrl':_0x54eeb8,'parent':angular[_0x2a6926('0x1194')](_0x276e88['body']),'targetEvent':_0x3e313c,'clickOutsideToClose':!![],'locals':{'openchannelAccount':_0x31333c,'openchannelAccounts':_0x3b40c8[_0x2a6926('0x28ff')]?_0x3b40c8[_0x2a6926('0x28ff')]['rows']:[],'crudPermissions':_0x3b40c8[_0x2a6926('0x243c')],'realtime':![]}});}function _0x581e89(_0x1b3e56,_0x488438){const _0x25bc20=_0x400d70,_0x48a2f=_0x165afc[_0x25bc20('0x1d26')]()[_0x25bc20('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x25bc20('0xb35')](_0x25bc20('0x77f'))+'?')[_0x25bc20('0xf3c')](_0x25bc20('0x12b5')+(_0x1b3e56['name']||_0x25bc20('0x77f'))+''+_0x25bc20('0x3f3'))[_0x25bc20('0x8e8')]('delete\x20openchannelAccount')['targetEvent'](_0x488438)['ok']('OK')[_0x25bc20('0x3f')]('CANCEL');_0x165afc[_0x25bc20('0x1f80')](_0x48a2f)[_0x25bc20('0x1166')](function(){_0x231d63(_0x1b3e56);},function(){const _0x1ab2c3=_0x25bc20;console[_0x1ab2c3('0x455')]('CANCEL');});}let _0x3403c0=!![],_0x332164=0x1;_0x150b35[_0x400d70('0xe83')]('vm.query.filter',function(_0x48c614,_0xf28e6a){const _0x309cd1=_0x400d70;_0x3403c0?_0x50176c(function(){_0x3403c0=![];}):(!_0xf28e6a&&(_0x332164=_0x3b40c8[_0x309cd1('0x2218')][_0x309cd1('0x1a43')]),_0x48c614!==_0xf28e6a&&(_0x3b40c8[_0x309cd1('0x2218')]['page']=0x1),!_0x48c614&&(_0x3b40c8[_0x309cd1('0x2218')][_0x309cd1('0x1a43')]=_0x332164),_0x3b40c8[_0x309cd1('0xc48')]());});function _0x76384e(_0xc3d4f2){const _0x3f7c23=_0x400d70;_0x3b40c8[_0x3f7c23('0x28ff')]=_0xc3d4f2||{'count':0x0,'rows':[]};}function _0x340e7a(){const _0x4545af=_0x400d70;_0x3b40c8['query'][_0x4545af('0x1098')]=(_0x3b40c8[_0x4545af('0x2218')][_0x4545af('0x1a43')]-0x1)*_0x3b40c8[_0x4545af('0x2218')][_0x4545af('0x163f')],_0x145863[_0x4545af('0x1ac6')](_0x4545af('0xa7c'))?_0x3b40c8[_0x4545af('0x1f48')]=_0x1343c6[_0x4545af('0x77f')][_0x4545af('0xd83')](_0x3b40c8['query'],_0x76384e)['$promise']:(_0x3b40c8[_0x4545af('0x2218')]['id']=_0x3b40c8[_0x4545af('0x7f')]['id'],_0x3b40c8['query']['section']=_0x4545af('0x1575'),_0x3b40c8[_0x4545af('0x1f48')]=_0x1343c6[_0x4545af('0x7f')][_0x4545af('0x263a')](_0x3b40c8[_0x4545af('0x2218')],_0x76384e)[_0x4545af('0xa44')]);}function _0x47d7b9(_0x55fe84,_0x1ae65c){const _0x1a27b0=_0x400d70;_0x165afc[_0x1a27b0('0x1f80')]({'controller':_0x1a27b0('0x1ba'),'controllerAs':'vm','templateUrl':_0x233e9c,'parent':angular[_0x1a27b0('0x1194')](_0x276e88[_0x1a27b0('0x8d2')]),'targetEvent':_0x55fe84,'clickOutsideToClose':!![],'locals':{'openchannelAccount':_0x1ae65c,'openchannelAccounts':_0x3b40c8['openchannelAccounts'][_0x1a27b0('0x269a')],'license':_0x3b40c8['license'],'setting':_0x3b40c8[_0x1a27b0('0xf8a')],'crudPermissions':_0x3b40c8[_0x1a27b0('0x243c')]}});}function _0x231d63(_0x267b5c){const _0x4c0600=_0x400d70;_0x1343c6[_0x4c0600('0x77f')][_0x4c0600('0x906')]({'id':_0x267b5c['id']})[_0x4c0600('0xa44')]['then'](function(){const _0x102101=_0x4c0600;_0x2cfb05()[_0x102101('0x127f')](_0x3b40c8[_0x102101('0x28ff')][_0x102101('0x269a')],{'id':_0x267b5c['id']}),_0x3b40c8[_0x102101('0x28ff')]['count']-=0x1,!_0x3b40c8[_0x102101('0x28ff')][_0x102101('0x269a')]['length']&&_0x3b40c8[_0x102101('0xc48')](),_0x2b8d59[_0x102101('0x103b')]({'title':_0x2cfb05()['startCase'](_0x102101('0x2370'))+_0x102101('0x2b6'),'msg':_0x267b5c[_0x102101('0x4f0')]?_0x267b5c['name']+'\x20has\x20been\x20deleted!':''});})[_0x4c0600('0x1a80')](function(_0x27b9c0){const _0x20a27b=_0x4c0600;if(_0x27b9c0[_0x20a27b('0x25f4')]&&_0x27b9c0[_0x20a27b('0x25f4')][_0x20a27b('0x61a')]&&_0x27b9c0[_0x20a27b('0x25f4')][_0x20a27b('0x61a')][_0x20a27b('0x264b')]){_0x3b40c8[_0x20a27b('0x61a')]=_0x27b9c0['data']['errors']||[{'message':_0x27b9c0[_0x20a27b('0x1586')](),'type':'SYSTEM:DELETEopenchannelAccount'}];for(let _0x3a350c=0x0;_0x3a350c<_0x27b9c0[_0x20a27b('0x25f4')][_0x20a27b('0x61a')][_0x20a27b('0x264b')];_0x3a350c++){_0x2b8d59[_0x20a27b('0xfc9')]({'title':_0x27b9c0[_0x20a27b('0x25f4')][_0x20a27b('0x61a')][_0x3a350c][_0x20a27b('0x1345')],'msg':_0x27b9c0[_0x20a27b('0x25f4')]['errors'][_0x3a350c][_0x20a27b('0x1e70')]});}}else _0x2b8d59[_0x20a27b('0xfc9')]({'title':_0x27b9c0[_0x20a27b('0x52d')]?'API:'+_0x27b9c0['status']+_0x20a27b('0x11e1')+_0x27b9c0[_0x20a27b('0xe1b')]:_0x20a27b('0x622'),'msg':_0x27b9c0[_0x20a27b('0x25f4')]?JSON[_0x20a27b('0xbac')](_0x27b9c0[_0x20a27b('0x25f4')][_0x20a27b('0x1e70')]):_0x27b9c0['message']||_0x27b9c0[_0x20a27b('0x1586')]()});});}function _0x496991(){const _0xdbe0c8=_0x400d70,_0x378c0b=angular[_0xdbe0c8('0x225f')](_0x3b40c8[_0xdbe0c8('0xe81')]);return _0x3b40c8[_0xdbe0c8('0xe81')]=[],_0x378c0b;}function _0x1afc6b(_0x5d39a8){const _0x44d8e6=_0x400d70,_0x1f5185=_0x165afc['confirm']()[_0x44d8e6('0xcdc')](_0x44d8e6('0x11ef'))[_0x44d8e6('0xf3c')](_0x44d8e6('0x12b5')+_0x3b40c8['selectedOpenchannelAccounts'][_0x44d8e6('0x264b')]+_0x44d8e6('0x196d')+'\x20will\x20be\x20deleted.')[_0x44d8e6('0x8e8')](_0x44d8e6('0xc9b'))[_0x44d8e6('0x203b')](_0x5d39a8)['ok']('OK')[_0x44d8e6('0x3f')](_0x44d8e6('0x2d3'));_0x165afc[_0x44d8e6('0x1f80')](_0x1f5185)[_0x44d8e6('0x1166')](function(){const _0xfa35de=_0x44d8e6;_0x3b40c8['selectedOpenchannelAccounts'][_0xfa35de('0x2782')](function(_0x4ad33d){_0x231d63(_0x4ad33d);}),_0x3b40c8[_0xfa35de('0xe81')]=[];});}function _0x5d8083(){_0x3b40c8['selectedOpenchannelAccounts']=[];}function _0x45826b(){const _0x238ba2=_0x400d70;_0x3b40c8[_0x238ba2('0xe81')]=_0x3b40c8[_0x238ba2('0x28ff')][_0x238ba2('0x269a')];}}const _0xb83790=_0x4bf5c5;_0x2baae8['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),'openchannelQueues','openchannelQueue',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x2baae8(_0x44b319,_0x561182,_0x4ef11a,_0x4952b4,_0x2392de,_0x23334c,_0x590fae,_0x125b5b,_0x9cb718,_0x5c7c3e,_0x48d75c,_0x432640,_0x39834b,_0x1e8c51){const _0x154722=_0x36e6f4,_0x3b922c=this;_0x3b922c['currentUser']=_0x48d75c[_0x154722('0x26cd')](),_0x3b922c[_0x154722('0x61a')]=[],_0x3b922c[_0x154722('0xf8a')]=_0x39834b,_0x3b922c[_0x154722('0x5c9')]=_0x432640,_0x3b922c[_0x154722('0x243c')]=_0x1e8c51,_0x3b922c[_0x154722('0x128b')]={},_0x3b922c[_0x154722('0x2900')]=_0x3b922c[_0x154722('0xf8a')]&&_0x3b922c[_0x154722('0xf8a')][_0x154722('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3b922c[_0x154722('0xcdc')]=_0x154722('0xfaf'),_0x3b922c[_0x154722('0x262f')]=angular[_0x154722('0x225f')](_0x9cb718),_0x3b922c[_0x154722('0xaf6')]=_0x125b5b,_0x3b922c[_0x154722('0xb94')]=![];!_0x3b922c[_0x154722('0x262f')]&&(_0x3b922c['openchannelQueue']={'strategy':_0x154722('0x278c'),'timeout':0xa},_0x3b922c[_0x154722('0xcdc')]=_0x154722('0xf87'),_0x3b922c[_0x154722('0xb94')]=!![]);_0x3b922c[_0x154722('0x1c8d')]=_0x4da49f,_0x3b922c['saveOpenchannelQueue']=_0x3de23f,_0x3b922c['deleteOpenchannelQueue']=_0x217fa8,_0x3b922c[_0x154722('0x1a9c')]=_0x361e76,_0x3b922c[_0x154722('0x24a0')]=_0x2af39c;function _0x4da49f(){const _0x15051e=_0x154722;_0x3b922c[_0x15051e('0x61a')]=[],_0x5c7c3e['openchannelQueue'][_0x15051e('0x9cc')](_0x3b922c[_0x15051e('0x262f')])[_0x15051e('0xa44')]['then'](function(_0x30f9c7){const _0x4308f1=_0x15051e;_0x3b922c[_0x4308f1('0xaf6')][_0x4308f1('0x2450')](_0x30f9c7[_0x4308f1('0x2876')]()),_0x590fae['success']({'title':_0x4308f1('0x1e19'),'msg':_0x3b922c[_0x4308f1('0x262f')]['name']?_0x3b922c['openchannelQueue'][_0x4308f1('0x4f0')]+_0x4308f1('0x1eda'):''}),_0x2af39c(_0x30f9c7);})[_0x15051e('0x1a80')](function(_0x3bb7f7){const _0x34c33a=_0x15051e;if(_0x3bb7f7['data']&&_0x3bb7f7[_0x34c33a('0x25f4')]['errors']&&_0x3bb7f7[_0x34c33a('0x25f4')][_0x34c33a('0x61a')]['length']){_0x3b922c[_0x34c33a('0x61a')]=_0x3bb7f7['data'][_0x34c33a('0x61a')]||[{'message':_0x3bb7f7[_0x34c33a('0x1586')](),'type':_0x34c33a('0x122')}];for(let _0x550059=0x0;_0x550059<_0x3bb7f7[_0x34c33a('0x25f4')][_0x34c33a('0x61a')]['length'];_0x550059+=0x1){_0x590fae[_0x34c33a('0xfc9')]({'title':_0x3bb7f7[_0x34c33a('0x25f4')][_0x34c33a('0x61a')][_0x550059][_0x34c33a('0x1345')],'msg':_0x3bb7f7[_0x34c33a('0x25f4')][_0x34c33a('0x61a')][_0x550059][_0x34c33a('0x1e70')]});}}else _0x590fae['error']({'title':_0x3bb7f7[_0x34c33a('0x52d')]?_0x34c33a('0x1e21')+_0x3bb7f7[_0x34c33a('0x52d')]+_0x34c33a('0x11e1')+_0x3bb7f7[_0x34c33a('0xe1b')]:_0x34c33a('0x122'),'msg':_0x3bb7f7[_0x34c33a('0x25f4')]?JSON[_0x34c33a('0xbac')](_0x3bb7f7[_0x34c33a('0x25f4')][_0x34c33a('0x1e70')]):_0x3bb7f7['toString']()});});}function _0x3de23f(){const _0x4630e6=_0x154722;_0x3b922c[_0x4630e6('0x61a')]=[],_0x5c7c3e[_0x4630e6('0x262f')][_0x4630e6('0x1449')]({'id':_0x3b922c[_0x4630e6('0x262f')]['id']},_0x3b922c[_0x4630e6('0x262f')])['$promise'][_0x4630e6('0x1166')](function(_0x1d9fb0){const _0x409c66=_0x4630e6,_0x27b863=_0x2cfb05()[_0x409c66('0xc38')](_0x3b922c['openchannelQueues'],{'id':_0x1d9fb0['id']});_0x27b863&&_0x2cfb05()['merge'](_0x27b863,_0x2cfb05()[_0x409c66('0x1a08')](_0x1d9fb0['toJSON'](),_0x2cfb05()['keys'](_0x27b863))),_0x590fae[_0x409c66('0x103b')]({'title':_0x409c66('0xb4c'),'msg':_0x3b922c['openchannelQueue'][_0x409c66('0x4f0')]?_0x3b922c['openchannelQueue'][_0x409c66('0x4f0')]+_0x409c66('0x7d'):''}),_0x2af39c(_0x1d9fb0);})[_0x4630e6('0x1a80')](function(_0x3ab7dd){const _0x419f2a=_0x4630e6;if(_0x3ab7dd[_0x419f2a('0x25f4')]&&_0x3ab7dd[_0x419f2a('0x25f4')][_0x419f2a('0x61a')]&&_0x3ab7dd['data'][_0x419f2a('0x61a')][_0x419f2a('0x264b')]){_0x3b922c[_0x419f2a('0x61a')]=_0x3ab7dd[_0x419f2a('0x25f4')][_0x419f2a('0x61a')]||[{'message':_0x3ab7dd['toString'](),'type':_0x419f2a('0x24d')}];for(let _0x2bdbea=0x0;_0x2bdbea<_0x3ab7dd[_0x419f2a('0x25f4')][_0x419f2a('0x61a')][_0x419f2a('0x264b')];_0x2bdbea++){_0x590fae[_0x419f2a('0xfc9')]({'title':_0x3ab7dd['data'][_0x419f2a('0x61a')][_0x2bdbea][_0x419f2a('0x1345')],'msg':_0x3ab7dd[_0x419f2a('0x25f4')][_0x419f2a('0x61a')][_0x2bdbea][_0x419f2a('0x1e70')]});}}else _0x590fae[_0x419f2a('0xfc9')]({'title':_0x3ab7dd['status']?'API:'+_0x3ab7dd[_0x419f2a('0x52d')]+_0x419f2a('0x11e1')+_0x3ab7dd['statusText']:_0x419f2a('0x24d'),'msg':_0x3ab7dd['data']?JSON[_0x419f2a('0xbac')](_0x3ab7dd[_0x419f2a('0x25f4')][_0x419f2a('0x1e70')]):_0x3ab7dd[_0x419f2a('0x1586')]()});});}function _0x217fa8(_0x3f2357){const _0x93df50=_0x154722;_0x3b922c[_0x93df50('0x61a')]=[];const _0x19875c=_0x4952b4[_0x93df50('0x1d26')]()['title'](_0x93df50('0x7fb'))['content'](_0x93df50('0xaec'))['ariaLabel'](_0x93df50('0x1900'))['ok'](_0x93df50('0x18'))['cancel'](_0x93df50('0x497'))[_0x93df50('0x203b')](_0x3f2357);_0x4952b4['show'](_0x19875c)['then'](function(){const _0x5bea69=_0x93df50;_0x5c7c3e['openchannelQueue'][_0x5bea69('0x906')]({'id':_0x3b922c[_0x5bea69('0x262f')]['id']})['$promise'][_0x5bea69('0x1166')](function(){const _0x58a2ea=_0x5bea69;_0x2cfb05()['remove'](_0x3b922c[_0x58a2ea('0xaf6')],{'id':_0x3b922c[_0x58a2ea('0x262f')]['id']}),_0x590fae['success']({'title':_0x58a2ea('0x2181'),'msg':(_0x3b922c[_0x58a2ea('0x262f')][_0x58a2ea('0x4f0')]||_0x58a2ea('0x262f'))+_0x58a2ea('0x7cd')}),_0x2af39c(_0x3b922c[_0x58a2ea('0x262f')]);})[_0x5bea69('0x1a80')](function(_0xf49d98){const _0x40ac33=_0x5bea69;if(_0xf49d98['data']&&_0xf49d98[_0x40ac33('0x25f4')][_0x40ac33('0x61a')]&&_0xf49d98[_0x40ac33('0x25f4')][_0x40ac33('0x61a')]['length']){_0x3b922c[_0x40ac33('0x61a')]=_0xf49d98[_0x40ac33('0x25f4')][_0x40ac33('0x61a')]||[{'message':_0xf49d98[_0x40ac33('0x1586')](),'type':_0x40ac33('0x299')}];for(let _0x1daa16=0x0;_0x1daa16<_0xf49d98[_0x40ac33('0x25f4')][_0x40ac33('0x61a')]['length'];_0x1daa16++){_0x590fae['error']({'title':_0xf49d98[_0x40ac33('0x25f4')]['errors'][_0x1daa16]['type'],'msg':_0xf49d98['data']['errors'][_0x1daa16][_0x40ac33('0x1e70')]});}}else _0x590fae['error']({'title':_0xf49d98[_0x40ac33('0x52d')]?_0x40ac33('0x1e21')+_0xf49d98[_0x40ac33('0x52d')]+_0x40ac33('0x11e1')+_0xf49d98[_0x40ac33('0xe1b')]:_0x40ac33('0x299'),'msg':_0xf49d98[_0x40ac33('0x25f4')]?JSON[_0x40ac33('0xbac')](_0xf49d98['data'][_0x40ac33('0x1e70')]):_0xf49d98[_0x40ac33('0x1e70')]||_0xf49d98[_0x40ac33('0x1586')]()});});},function(){});}function _0x361e76(_0x262bbb){return _0x262bbb===null?undefined:new Date(_0x262bbb);}function _0x2af39c(_0x34b876){const _0x3d35b2=_0x154722;_0x4952b4[_0x3d35b2('0x1197')](_0x34b876);}}const _0x39c5b4=_0x2baae8;_0xb5a2cd[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x262f'),'openchannelQueues',_0x36e6f4('0xf01'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0xb5a2cd(_0xcfce5,_0x704bc0,_0x11a71d,_0x571137,_0x2e9273,_0x4b114f,_0x26ba1a,_0x4908ef,_0x20a0c5,_0x72f61f){const _0x5caafe=_0x36e6f4,_0x1ed898=this;_0x1ed898['currentUser']=_0x20a0c5['getCurrentUser'](),_0x1ed898[_0x5caafe('0x262f')]=_0x2e9273,_0x1ed898['crudPermissions']=_0x72f61f,_0x1ed898['realtime']=_0x26ba1a,_0x1ed898[_0x5caafe('0xbd7')]=[],_0x1ed898[_0x5caafe('0x10ab')]=[],_0x1ed898[_0x5caafe('0x18e1')]=[],_0x1ed898['startingAllowedItems']=[],_0x1ed898[_0x5caafe('0x2781')]=[],_0x1ed898[_0x5caafe('0x14d7')]=![],_0x1ed898[_0x5caafe('0xae0')]=_0x15ab82,_0x1ed898[_0x5caafe('0x1d92')]=_0x190c7b,_0x1ed898['closeDialog']=_0x2725c3,_0x1ed898['dualMultiselectOptions']={'readOnly':!_0x1ed898['crudPermissions'][_0x5caafe('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x5caafe('0x6e1'),'line2':['name',_0x5caafe('0x1eef')],'line3':'','labelAll':_0x4908ef[_0x5caafe('0x25cc')]('OPENCHANNEL.ALL_AGENTS'),'labelSelected':_0x4908ef[_0x5caafe('0x25cc')](_0x5caafe('0xaa2')),'transferCallback':function(){const _0x2f168f=_0x5caafe,_0x2368d2=_0x2cfb05()['xorBy'](_0x1ed898[_0x2f168f('0x2781')],_0x1ed898[_0x2f168f('0x18e1')],'id');_0x1ed898[_0x2f168f('0x14d7')]=_0x2cfb05()['isEmpty'](_0x2368d2)?![]:!![];}};function _0x15ab82(){const _0x39783f=_0x5caafe;return _0x20a0c5['hasRole'](_0x39783f('0xa7c'))?_0xfcce3f()['catch'](function(_0x5ef5ea){const _0x8c0734=_0x39783f;_0x11a71d['error']({'title':_0x5ef5ea['status']?'API:'+_0x5ef5ea[_0x8c0734('0x52d')]+_0x8c0734('0x11e1')+_0x5ef5ea['statusText']:'SYSTEM:GET_AGENTS','msg':_0x5ef5ea[_0x8c0734('0x52d')]?JSON[_0x8c0734('0xbac')](_0x5ef5ea[_0x8c0734('0x25f4')]):_0x5ef5ea[_0x8c0734('0x1586')]()});}):_0x2dd727()['then'](function(_0x2f654a){const _0x3e0b92=_0x39783f;return _0x1ed898[_0x3e0b92('0xe60')]=_0x2f654a,_0xfcce3f();})[_0x39783f('0x1a80')](function(_0x5d7a4c){const _0x52a48b=_0x39783f;_0x11a71d[_0x52a48b('0xfc9')]({'title':_0x5d7a4c['status']?_0x52a48b('0x1e21')+_0x5d7a4c[_0x52a48b('0x52d')]+_0x52a48b('0x11e1')+_0x5d7a4c[_0x52a48b('0xe1b')]:_0x52a48b('0xd4c'),'msg':_0x5d7a4c[_0x52a48b('0x52d')]?JSON[_0x52a48b('0xbac')](_0x5d7a4c[_0x52a48b('0x25f4')]):_0x5d7a4c[_0x52a48b('0x1586')]()});});}function _0x2dd727(){return _0x704bc0(function(_0x13a3db,_0x3fe186){const _0x4a5f94=a0_0x3f2c;_0x571137[_0x4a5f94('0x17aa')][_0x4a5f94('0xd83')]({'userProfileId':_0x1ed898['currentUser']['userProfileId'],'name':_0x4a5f94('0x2391')})[_0x4a5f94('0xa44')][_0x4a5f94('0x1166')](function(_0x340bd7){const _0x55c561=_0x4a5f94,_0x17f81e=_0x340bd7&&_0x340bd7[_0x55c561('0x269a')]?_0x340bd7['rows'][0x0]:null;_0x13a3db(_0x17f81e);})[_0x4a5f94('0x1a80')](function(_0x5883ed){_0x3fe186(_0x5883ed);});});}function _0xfcce3f(){return _0x704bc0(function(_0x204978,_0xeb14bf){const _0x4895ae=a0_0x3f2c;return _0x39fb24()[_0x4895ae('0x1166')](function(_0x143e59){const _0x372de4=_0x4895ae;return _0x1ed898[_0x372de4('0xbd7')]=_0x143e59[_0x372de4('0x269a')]?_0x143e59[_0x372de4('0x269a')]:[],_0x20a0c5['hasRole'](_0x372de4('0xa7c'))?_0x143e59:_0x1ed898['section']?_0x1ed898[_0x372de4('0xe60')][_0x372de4('0x1a2b')]?_0x143e59:_0x33e007():null;})['then'](function(_0x450519){const _0x4f7de9=_0x4895ae,_0x3d0d6c=_0x450519&&_0x450519[_0x4f7de9('0x269a')]?_0x450519['rows']:[];return _0x1ed898[_0x4f7de9('0x10ab')]=_0x2cfb05()['map'](_0x3d0d6c,function(_0x36d335){const _0x4b8983=_0x4f7de9;return _0x2cfb05()[_0x4b8983('0xc38')](_0x1ed898[_0x4b8983('0xbd7')],{'id':_0x20a0c5['hasRole'](_0x4b8983('0xa7c'))||_0x1ed898[_0x4b8983('0xe60')][_0x4b8983('0x1a2b')]?_0x36d335['id']:_0x36d335[_0x4b8983('0x24e8')]});}),_0x1ed898[_0x4f7de9('0x2111')]=angular[_0x4f7de9('0x225f')](_0x1ed898[_0x4f7de9('0x10ab')]),_0x1ed898['items'][_0x4f7de9('0x2782')](function(_0x12424a){const _0x145255=_0x4f7de9,_0x4976c6=_0x2cfb05()[_0x145255('0xc38')](_0x1ed898[_0x145255('0x10ab')],{'id':_0x12424a['id']});_0x20a0c5['hasRole'](_0x145255('0xa7c'))?_0x12424a[_0x145255('0x26ef')]=!![]:_0x12424a[_0x145255('0x26ef')]=typeof _0x4976c6!==_0x145255('0x1048')?!![]:![];}),_0xfe54c();})['then'](function(_0x4e032f){const _0x33cf0a=_0x4895ae,_0x48d6ae=_0x4e032f&&_0x4e032f['rows']?_0x4e032f[_0x33cf0a('0x269a')]:[];_0x1ed898[_0x33cf0a('0x18e1')]=_0x2cfb05()[_0x33cf0a('0x2563')](_0x48d6ae,function(_0x2197b6){const _0x530164=_0x33cf0a,_0x960dfe=_0x2cfb05()['find'](_0x1ed898['items'],{'id':_0x2197b6['id']});return _0x960dfe[_0x530164('0x23af')]=_0x2197b6[_0x530164('0x143')]?_0x530164('0x11e8')+_0x2197b6[_0x530164('0x143')][_0x530164('0x23af')]:'',_0x960dfe[_0x530164('0x1eef')]=typeof _0x2197b6[_0x530164('0x1eef')]!==_0x530164('0x1048')?'<'+_0x2197b6[_0x530164('0x1eef')]+'>':'',_0x960dfe;}),_0x1ed898[_0x33cf0a('0x2781')]=angular['copy'](_0x1ed898[_0x33cf0a('0x18e1')]),_0x1ed898['dualMultiselectOptions']['selectedItems']=_0x1ed898[_0x33cf0a('0x18e1')],_0x1ed898['dualMultiselectOptions'][_0x33cf0a('0xbd7')]=_0x2cfb05()[_0x33cf0a('0x24ac')](_0x1ed898[_0x33cf0a('0x10ab')],_0x1ed898['dualMultiselectOptions'][_0x33cf0a('0x18e1')],'id'),_0x204978();})[_0x4895ae('0x1a80')](function(_0x116b43){_0xeb14bf(_0x116b43);});});}function _0x33e007(){return _0x704bc0(function(_0x2aa483,_0x244b1d){const _0x3cd46d=a0_0x3f2c;return _0x571137[_0x3cd46d('0x4b5')][_0x3cd46d('0xd83')]({'sectionId':_0x1ed898[_0x3cd46d('0xe60')]['id'],'nolimit':!![]})[_0x3cd46d('0xa44')][_0x3cd46d('0x1166')](function(_0x47db31){_0x2aa483(_0x47db31);})[_0x3cd46d('0x1a80')](function(_0x953fd2){_0x244b1d(_0x953fd2);});});}function _0xfe54c(){return _0x704bc0(function(_0x2eb6ab,_0x1af37a){const _0x1b2c30=a0_0x3f2c;return _0x571137[_0x1b2c30('0x262f')][_0x1b2c30('0x261c')]({'id':_0x1ed898[_0x1b2c30('0x262f')]['id'],'fields':'id,name,internal,fullname','nolimit':!![],'role':_0x1b2c30('0x1eff')})[_0x1b2c30('0xa44')][_0x1b2c30('0x1166')](function(_0x1d485d){_0x2eb6ab(_0x1d485d);})['catch'](function(_0x3d5d21){_0x1af37a(_0x3d5d21);});});}function _0x39fb24(){return _0x704bc0(function(_0x424b89,_0x5309e0){const _0x4a7c5d=a0_0x3f2c;return _0x571137[_0x4a7c5d('0x557')][_0x4a7c5d('0xd83')]({'fields':_0x4a7c5d('0x1459'),'nolimit':!![],'role':_0x4a7c5d('0x1eff')})[_0x4a7c5d('0xa44')][_0x4a7c5d('0x1166')](function(_0x2f85e1){_0x424b89(_0x2f85e1);})[_0x4a7c5d('0x1a80')](function(_0x2a4300){_0x5309e0(_0x2a4300);});});}function _0x20078c(_0x17151e){return _0x704bc0(function(_0x1e486a,_0x2589ad){const _0x55c73a=a0_0x3f2c;_0x2cfb05()[_0x55c73a('0x1081')](_0x17151e)?_0x1e486a():_0x571137[_0x55c73a('0x262f')][_0x55c73a('0x275c')]({'id':_0x1ed898[_0x55c73a('0x262f')]['id'],'ids':_0x2cfb05()['map'](_0x17151e,'id')})[_0x55c73a('0xa44')]['then'](function(){_0x1e486a();})['catch'](function(_0x11541a){_0x2589ad(_0x11541a);});});}function _0x48a359(_0xafe60e){return _0x704bc0(function(_0x3c1069,_0x465a55){const _0x1d9696=a0_0x3f2c;_0x2cfb05()[_0x1d9696('0x1081')](_0xafe60e)?_0x3c1069():_0x571137[_0x1d9696('0x262f')][_0x1d9696('0x269d')]({'id':_0x1ed898[_0x1d9696('0x262f')]['id'],'ids':_0x2cfb05()[_0x1d9696('0x2563')](_0xafe60e,'id')})[_0x1d9696('0xa44')][_0x1d9696('0x1166')](function(){_0x3c1069();})[_0x1d9696('0x1a80')](function(_0x3732e0){_0x465a55(_0x3732e0);});});}function _0x190c7b(){const _0x589c4f=_0x5caafe,_0x2b8016=_0x2cfb05()[_0x589c4f('0x24ac')](_0x1ed898[_0x589c4f('0x2781')],_0x1ed898[_0x589c4f('0x18e1')],'id'),_0x7f6e4d=_0x2cfb05()[_0x589c4f('0x24ac')](_0x1ed898[_0x589c4f('0x18e1')],_0x1ed898[_0x589c4f('0x2781')],'id');return _0x48a359(_0x2b8016)[_0x589c4f('0x1166')](function(){return _0x20078c(_0x7f6e4d);})['then'](function(){const _0x1f4875=_0x589c4f;_0x1ed898['pendingChanges']=![],_0x1ed898['startingAllowedItems']=angular[_0x1f4875('0x225f')](_0x1ed898[_0x1f4875('0x10ab')]),_0x1ed898[_0x1f4875('0x2781')]=angular[_0x1f4875('0x225f')](_0x1ed898[_0x1f4875('0x18e1')]),_0x11a71d[_0x1f4875('0x103b')]({'title':_0x1f4875('0x983'),'msg':'Agents\x20association\x20has\x20been\x20updated!'});})[_0x589c4f('0x1a80')](function(_0x1c2f45){const _0x4540fe=_0x589c4f;_0x11a71d[_0x4540fe('0xfc9')]({'title':_0x1c2f45['status']?_0x4540fe('0x1e21')+_0x1c2f45[_0x4540fe('0x52d')]+_0x4540fe('0x11e1')+_0x1c2f45[_0x4540fe('0xe1b')]:_0x4540fe('0x1b29'),'msg':_0x1c2f45['status']?JSON[_0x4540fe('0xbac')](_0x1c2f45[_0x4540fe('0x25f4')]):_0x1c2f45[_0x4540fe('0x1586')]()});});}function _0x2725c3(){const _0x345e3a=_0x5caafe;_0xcfce5[_0x345e3a('0x1197')]();}}const _0x50aad3=_0xb5a2cd;_0x3ee79b['$inject']=['$mdDialog','$q',_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x262f'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x3ee79b(_0x3d4187,_0x25089d,_0xc8dd87,_0x5e18c3,_0x35badc,_0x4d0205,_0x170c6a,_0x3f22db){const _0x2dab8f=_0x36e6f4,_0x3d1783=this;_0x3d1783[_0x2dab8f('0x98')]=_0x170c6a[_0x2dab8f('0x26cd')](),_0x3d1783[_0x2dab8f('0x262f')]=_0x35badc,_0x3d1783['crudPermissions']=_0x3f22db,_0x3d1783[_0x2dab8f('0xbd7')]=[],_0x3d1783[_0x2dab8f('0x10ab')]=[],_0x3d1783[_0x2dab8f('0x18e1')]=[],_0x3d1783[_0x2dab8f('0x2111')]=[],_0x3d1783[_0x2dab8f('0x2781')]=[],_0x3d1783[_0x2dab8f('0x14d7')]=![],_0x3d1783[_0x2dab8f('0xc68')]={'readOnly':!_0x3d1783[_0x2dab8f('0x243c')][_0x2dab8f('0x1684')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x2dab8f('0x4f0'),'line1':_0x2dab8f('0x4f0'),'line2':'','line3':'','labelAll':_0x4d0205['instant'](_0x2dab8f('0x67c')),'labelSelected':_0x4d0205['instant'](_0x2dab8f('0x360')),'transferCallback':function(){const _0x1e7d3e=_0x2dab8f,_0x9f84c9=_0x2cfb05()[_0x1e7d3e('0x2802')](_0x3d1783[_0x1e7d3e('0x2781')],_0x3d1783[_0x1e7d3e('0x18e1')],'id');_0x3d1783[_0x1e7d3e('0x14d7')]=_0x2cfb05()['isEmpty'](_0x9f84c9)?![]:!![];}},_0x3d1783[_0x2dab8f('0xae0')]=_0x138b67,_0x3d1783['saveTeams']=_0xa3226b,_0x3d1783['closeDialog']=_0x475922;function _0x138b67(){const _0x24bb5d=_0x2dab8f;return _0x170c6a['hasRole'](_0x24bb5d('0xa7c'))?_0x26bcc0()[_0x24bb5d('0x1a80')](function(_0x2c405d){const _0x9de1e5=_0x24bb5d;_0xc8dd87[_0x9de1e5('0xfc9')]({'title':_0x2c405d['status']?'API:'+_0x2c405d[_0x9de1e5('0x52d')]+_0x9de1e5('0x11e1')+_0x2c405d[_0x9de1e5('0xe1b')]:_0x9de1e5('0x1031'),'msg':_0x2c405d[_0x9de1e5('0x52d')]?JSON[_0x9de1e5('0xbac')](_0x2c405d[_0x9de1e5('0x25f4')]):_0x2c405d['toString']()});}):_0x23e9ef()[_0x24bb5d('0x1166')](function(_0x2d586a){const _0x154061=_0x24bb5d;return _0x3d1783[_0x154061('0xe60')]=_0x2d586a,_0x26bcc0();})[_0x24bb5d('0x1a80')](function(_0x5cf21e){const _0x285c90=_0x24bb5d;_0xc8dd87['error']({'title':_0x5cf21e[_0x285c90('0x52d')]?_0x285c90('0x1e21')+_0x5cf21e[_0x285c90('0x52d')]+_0x285c90('0x11e1')+_0x5cf21e[_0x285c90('0xe1b')]:_0x285c90('0x1031'),'msg':_0x5cf21e[_0x285c90('0x52d')]?JSON['stringify'](_0x5cf21e[_0x285c90('0x25f4')]):_0x5cf21e['toString']()});});}function _0x23e9ef(){return _0x25089d(function(_0x4a9122,_0x4b096a){const _0x25b03a=a0_0x3f2c;_0x5e18c3[_0x25b03a('0x17aa')][_0x25b03a('0xd83')]({'userProfileId':_0x3d1783[_0x25b03a('0x98')][_0x25b03a('0xb86')],'name':'Teams'})[_0x25b03a('0xa44')][_0x25b03a('0x1166')](function(_0x2d48f4){const _0x3ed230=_0x25b03a,_0x1552d0=_0x2d48f4&&_0x2d48f4['rows']?_0x2d48f4[_0x3ed230('0x269a')][0x0]:null;_0x4a9122(_0x1552d0);})[_0x25b03a('0x1a80')](function(_0x4b8ec0){_0x4b096a(_0x4b8ec0);});});}function _0x26bcc0(){return _0x25089d(function(_0x5b261b,_0x526f01){const _0x4f3f4d=a0_0x3f2c;return _0x3d1bcb()[_0x4f3f4d('0x1166')](function(_0x454fa6){const _0x514507=_0x4f3f4d;return _0x3d1783[_0x514507('0xbd7')]=_0x454fa6[_0x514507('0x269a')]?_0x454fa6['rows']:[],_0x170c6a[_0x514507('0x1ac6')]('admin')?_0x454fa6:_0x3d1783[_0x514507('0xe60')]?_0x3d1783[_0x514507('0xe60')]['autoAssociation']?_0x454fa6:_0x541941():null;})[_0x4f3f4d('0x1166')](function(_0x3c446d){const _0x49421b=_0x4f3f4d,_0xba904=_0x3c446d&&_0x3c446d[_0x49421b('0x269a')]?_0x3c446d[_0x49421b('0x269a')]:[];return _0x3d1783[_0x49421b('0x10ab')]=_0x2cfb05()['map'](_0xba904,function(_0x1d00f9){const _0x14eef9=_0x49421b;return _0x2cfb05()[_0x14eef9('0xc38')](_0x3d1783['items'],{'id':_0x170c6a['hasRole'](_0x14eef9('0xa7c'))||_0x3d1783[_0x14eef9('0xe60')][_0x14eef9('0x1a2b')]?_0x1d00f9['id']:_0x1d00f9[_0x14eef9('0x24e8')]});}),_0x3d1783[_0x49421b('0xbd7')]['forEach'](function(_0x387c6c){const _0x372746=_0x49421b,_0x1d3108=_0x2cfb05()[_0x372746('0xc38')](_0x3d1783[_0x372746('0x10ab')],{'id':_0x387c6c['id']});_0x170c6a[_0x372746('0x1ac6')](_0x372746('0xa7c'))?_0x387c6c[_0x372746('0x26ef')]=!![]:_0x387c6c[_0x372746('0x26ef')]=typeof _0x1d3108!==_0x372746('0x1048')?!![]:![];}),_0x1f339f();})[_0x4f3f4d('0x1166')](function(_0xf43ff4){const _0x546ced=_0x4f3f4d,_0x5b079f=_0xf43ff4&&_0xf43ff4['rows']?_0xf43ff4[_0x546ced('0x269a')]:[];_0x3d1783[_0x546ced('0x18e1')]=_0x2cfb05()[_0x546ced('0x2563')](_0x5b079f,function(_0x1c80c8){const _0x1b90f6=_0x546ced;return _0x2cfb05()[_0x1b90f6('0xc38')](_0x3d1783['items'],{'id':_0x1c80c8['id']});}),_0x3d1783[_0x546ced('0x2781')]=angular[_0x546ced('0x225f')](_0x3d1783[_0x546ced('0x18e1')]),_0x3d1783[_0x546ced('0xc68')][_0x546ced('0x18e1')]=_0x3d1783[_0x546ced('0x18e1')],_0x3d1783['dualMultiselectOptions'][_0x546ced('0xbd7')]=_0x2cfb05()[_0x546ced('0x24ac')](_0x3d1783[_0x546ced('0x10ab')],_0x3d1783[_0x546ced('0xc68')][_0x546ced('0x18e1')],'id'),_0x5b261b();})[_0x4f3f4d('0x1a80')](function(_0xdb9e2){_0x526f01(_0xdb9e2);});});}function _0x541941(){return _0x25089d(function(_0x37e7e0,_0x6b5b57){const _0x1b6004=a0_0x3f2c;return _0x5e18c3[_0x1b6004('0x4b5')]['get']({'sectionId':_0x3d1783[_0x1b6004('0xe60')]['id'],'nolimit':!![]})[_0x1b6004('0xa44')][_0x1b6004('0x1166')](function(_0x214491){_0x37e7e0(_0x214491);})['catch'](function(_0x17c380){_0x6b5b57(_0x17c380);});});}function _0x1f339f(){return _0x25089d(function(_0xfa1cc,_0x2177be){const _0x1b355e=a0_0x3f2c;return _0x5e18c3[_0x1b355e('0x262f')][_0x1b355e('0x1448')]({'id':_0x3d1783[_0x1b355e('0x262f')]['id'],'fields':_0x1b355e('0x1776'),'nolimit':!![]})['$promise']['then'](function(_0x18d9ff){_0xfa1cc(_0x18d9ff);})['catch'](function(_0x140921){_0x2177be(_0x140921);});});}function _0x3d1bcb(){return _0x25089d(function(_0x373947,_0x115044){const _0x1fce70=a0_0x3f2c;return _0x5e18c3['team'][_0x1fce70('0xd83')]({'fields':_0x1fce70('0x1776'),'nolimit':!![]})[_0x1fce70('0xa44')][_0x1fce70('0x1166')](function(_0x4e8ea7){_0x373947(_0x4e8ea7);})['catch'](function(_0xe743d7){_0x115044(_0xe743d7);});});}function _0x52361b(_0x35023e){return _0x25089d(function(_0x4785ea,_0x105ae1){const _0x4362f8=a0_0x3f2c;_0x2cfb05()[_0x4362f8('0x1081')](_0x35023e)?_0x4785ea():_0x5e18c3['openchannelQueue'][_0x4362f8('0x16e0')]({'id':_0x3d1783[_0x4362f8('0x262f')]['id'],'ids':_0x2cfb05()[_0x4362f8('0x2563')](_0x35023e,'id')})[_0x4362f8('0xa44')][_0x4362f8('0x1166')](function(){_0x4785ea();})['catch'](function(_0x147f7d){_0x105ae1(_0x147f7d);});});}function _0x2c4425(_0xff5713){return _0x25089d(function(_0x190781,_0x15eaa8){const _0x11696d=a0_0x3f2c;_0x2cfb05()[_0x11696d('0x1081')](_0xff5713)?_0x190781():_0x5e18c3['openchannelQueue'][_0x11696d('0x8f')]({'id':_0x3d1783[_0x11696d('0x262f')]['id'],'ids':_0x2cfb05()[_0x11696d('0x2563')](_0xff5713,'id')})[_0x11696d('0xa44')][_0x11696d('0x1166')](function(){_0x190781();})[_0x11696d('0x1a80')](function(_0x52c52c){_0x15eaa8(_0x52c52c);});});}function _0xa3226b(){const _0x5eae5f=_0x2dab8f,_0x5a279e=_0x2cfb05()[_0x5eae5f('0x24ac')](_0x3d1783['startingSelectedItems'],_0x3d1783[_0x5eae5f('0x18e1')],'id'),_0x28a850=_0x2cfb05()[_0x5eae5f('0x24ac')](_0x3d1783[_0x5eae5f('0x18e1')],_0x3d1783['startingSelectedItems'],'id');return _0x2c4425(_0x5a279e)[_0x5eae5f('0x1166')](function(){return _0x52361b(_0x28a850);})[_0x5eae5f('0x1166')](function(){const _0x424287=_0x5eae5f;_0x3d1783[_0x424287('0x14d7')]=![],_0x3d1783[_0x424287('0x2111')]=angular[_0x424287('0x225f')](_0x3d1783[_0x424287('0x10ab')]),_0x3d1783[_0x424287('0x2781')]=angular[_0x424287('0x225f')](_0x3d1783[_0x424287('0x18e1')]),_0xc8dd87[_0x424287('0x103b')]({'title':'SUCCESS','msg':_0x424287('0x1f6b')});})[_0x5eae5f('0x1a80')](function(_0x12ec5c){const _0x286fe4=_0x5eae5f;_0xc8dd87[_0x286fe4('0xfc9')]({'title':_0x12ec5c[_0x286fe4('0x52d')]?'API:'+_0x12ec5c['status']+_0x286fe4('0x11e1')+_0x12ec5c[_0x286fe4('0xe1b')]:_0x286fe4('0x1b29'),'msg':_0x12ec5c[_0x286fe4('0x52d')]?JSON[_0x286fe4('0xbac')](_0x12ec5c[_0x286fe4('0x25f4')]):_0x12ec5c['toString']()});});}function _0x475922(){const _0x5654d8=_0x2dab8f;_0x3d4187[_0x5654d8('0x1197')]();}}const _0x48be12=_0x3ee79b,_0x1ca011=_0x2734b2['p']+_0x36e6f4('0x1156');_0x2af878[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x19e3'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x262f'),'userProfileSection'];function _0x2af878(_0x268983,_0x993f19,_0x4e98cf,_0x236965,_0x19483b,_0x12077f,_0x1dce6d,_0x221448,_0x33a699,_0x5e0562,_0x561064,_0x10963f){const _0x24ec6a=_0x36e6f4,_0x208a5e=this;_0x208a5e['currentUser']=_0x5e0562[_0x24ec6a('0x26cd')](),_0x208a5e[_0x24ec6a('0x5c9')]=_0x12077f,_0x208a5e['setting']=_0x1dce6d,_0x208a5e['passwordPattern']=_0x208a5e['setting'][_0x24ec6a('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x208a5e[_0x24ec6a('0x246b')]=_0x993f19['protocol']()+_0x24ec6a('0xc51')+_0x993f19[_0x24ec6a('0x1690')](),_0x208a5e[_0x24ec6a('0x262f')]=_0x561064||_0x268983[_0x24ec6a('0x23f')][_0x24ec6a('0x262f')]||{},_0x208a5e[_0x24ec6a('0x17aa')]=_0x10963f&&_0x10963f[_0x24ec6a('0x240f')]==0x1?_0x10963f[_0x24ec6a('0x269a')][0x0]:null,_0x208a5e['crudPermissions']=_0x5e0562[_0x24ec6a('0xd87')](_0x208a5e[_0x24ec6a('0x17aa')]?_0x208a5e[_0x24ec6a('0x17aa')][_0x24ec6a('0x243c')]:null),_0x208a5e[_0x24ec6a('0x128b')]={},_0x208a5e[_0x24ec6a('0x2669')]=_0x268983[_0x24ec6a('0x23f')][_0x24ec6a('0xbe3')]||0x0,_0x208a5e['teamadddialog']=_0x2b43ad,_0x208a5e['agentadddialog']=_0x12893f,_0x208a5e[_0x24ec6a('0x31d')]=_0x33a699[_0x24ec6a('0x1fa1')],_0x208a5e['gotoOpenchannelQueues']=_0x4ad659,_0x208a5e[_0x24ec6a('0x22cb')]=_0x31151f;function _0x2b43ad(_0x583d02,_0x41c9d1){const _0x2eb72b=_0x24ec6a;_0x4e98cf['show']({'controller':_0x2eb72b('0xe21'),'controllerAs':'vm','templateUrl':_0x1ca011,'parent':angular[_0x2eb72b('0x1194')](_0x236965[_0x2eb72b('0x8d2')]),'targetEvent':_0x41c9d1,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x583d02,'openchannelQueues':_0x208a5e[_0x2eb72b('0xaf6')]?_0x208a5e[_0x2eb72b('0xaf6')]['rows']:[],'crudPermissions':_0x208a5e[_0x2eb72b('0x243c')]}});}function _0x12893f(_0x47f735,_0x1166e7){const _0x4c1997=_0x24ec6a;_0x4e98cf[_0x4c1997('0x1f80')]({'controller':'OpenchannelQueueagentaddController','controllerAs':'vm','templateUrl':_0xd7ba85,'parent':angular['element'](_0x236965[_0x4c1997('0x8d2')]),'targetEvent':_0x1166e7,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x47f735,'openchannelQueues':_0x208a5e['openchannelQueues']?_0x208a5e[_0x4c1997('0xaf6')][_0x4c1997('0x269a')]:[],'crudPermissions':_0x208a5e[_0x4c1997('0x243c')],'realtime':![]}});}function _0x4ad659(){const _0xedfd96=_0x24ec6a;_0x268983['go']('app.openchannel.openchannelQueues',{},{'reload':_0xedfd96('0x20b5')});}function _0x31151f(){const _0x3d70ef=_0x24ec6a;_0x221448['openchannelQueue'][_0x3d70ef('0x1449')]({'id':_0x208a5e[_0x3d70ef('0x262f')]['id']},_0x208a5e['openchannelQueue'])[_0x3d70ef('0xa44')][_0x3d70ef('0x1166')](function(){const _0x53b0a2=_0x3d70ef;_0x33a699[_0x53b0a2('0x103b')]({'title':'OpenchannelQueue\x20updated!','msg':_0x208a5e[_0x53b0a2('0x262f')][_0x53b0a2('0x4f0')]?_0x208a5e[_0x53b0a2('0x262f')][_0x53b0a2('0x4f0')]+_0x53b0a2('0xa17'):''});})[_0x3d70ef('0x1a80')](function(_0x286c83){const _0x1fa3ba=_0x3d70ef;_0x33a699[_0x1fa3ba('0xfc9')]({'title':_0x286c83[_0x1fa3ba('0x52d')]?_0x1fa3ba('0x1e21')+_0x286c83[_0x1fa3ba('0x52d')]+'\x20-\x20'+_0x286c83[_0x1fa3ba('0xe1b')]:_0x1fa3ba('0x21a8'),'msg':_0x286c83['data']?JSON['stringify'](_0x286c83['data']):_0x286c83[_0x1fa3ba('0x1586')]()});});}}const _0x594c1d=_0x2af878;_0x3ea5f1[_0x36e6f4('0x1294')]=['$scope','$window',_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0xaf6'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x3ea5f1(_0x20b5e6,_0x205b48,_0x588437,_0xb3c84f,_0x440aa3,_0x215a9a,_0x1ce10f,_0x33184f,_0x4a4ae8,_0x2c8958,_0x140676,_0xe48d1b,_0x5c6353,_0x2423ee,_0x1fd983,_0x4a055d,_0x5a014e){const _0x461004=_0x36e6f4,_0x1bbbb3=this;_0x1bbbb3[_0x461004('0x5c9')]=_0x4a055d,_0x1bbbb3['setting']=_0x5a014e,_0x1bbbb3[_0x461004('0x98')]=_0x1fd983[_0x461004('0x26cd')](),_0x1bbbb3[_0x461004('0xaf6')]=_0x4a4ae8||{'count':0x0,'rows':[]},_0x1bbbb3[_0x461004('0x7f')]=_0x2c8958,_0x1bbbb3['userProfileSection']=_0x140676&&_0x140676[_0x461004('0x240f')]==0x1?_0x140676[_0x461004('0x269a')][0x0]:null,_0x1bbbb3[_0x461004('0x243c')]=_0x1fd983[_0x461004('0xd87')](_0x1bbbb3['userProfileSection']?_0x1bbbb3['userProfileSection'][_0x461004('0x243c')]:null),_0x1bbbb3[_0x461004('0x916')]=_0x461004('0xaf6'),_0x1bbbb3[_0x461004('0xef5')]='',_0x1bbbb3[_0x461004('0x104c')]=null,_0x1bbbb3[_0x461004('0x3dd')]=[],_0x1bbbb3[_0x461004('0x2218')]={'fields':_0x461004('0xf26'),'sort':_0x461004('0x14dc'),'channel':'openchannel','limit':0xa,'page':0x1},_0x1bbbb3[_0x461004('0x1440')]=_0x2cfb05()['keyBy']([{'option':'Beepall','value':_0x461004('0x1792')},{'option':_0x461004('0x75'),'value':_0x461004('0x11ad')}],function(_0x1fd522){return _0x2cfb05()['replace'](_0x1fd522['value'],new RegExp('\x27','g'),'');}),_0x1bbbb3['editstate']=_0x4cdc09,_0x1bbbb3[_0x461004('0x292')]=_0x7fcd02,_0x1bbbb3['agentadddialog']=_0x55b0e2,_0x1bbbb3[_0x461004('0x8d8')]=_0x403b1c,_0x1bbbb3[_0x461004('0x182d')]=_0x585b7d,_0x1bbbb3[_0x461004('0x103b')]=_0x5181a9,_0x1bbbb3['getOpenchannelQueues']=_0xc3abff,_0x1bbbb3['createOrEditOpenchannelQueue']=_0x4ea16d,_0x1bbbb3['deleteOpenchannelQueue']=_0x56daa0,_0x1bbbb3[_0x461004('0x1c65')]=_0x3c490c,_0x1bbbb3['deleteSelectedOpenchannelQueues']=_0x2c2bf6,_0x1bbbb3[_0x461004('0x2fd')]=_0x17c28d,_0x1bbbb3['selectAllOpenchannelQueues']=_0x288c2e;function _0x4cdc09(_0x434657){const _0x42a509=_0x461004;_0x588437['go'](_0x42a509('0x1c8f'),{'id':_0x434657['id'],'openchannelQueue':_0x434657,'crudPermissions':_0x1bbbb3[_0x42a509('0x243c')]});}function _0x7fcd02(_0x41cd0a,_0x2c98dc){const _0x508d38=_0x461004;_0x440aa3[_0x508d38('0x1f80')]({'controller':_0x508d38('0xe21'),'controllerAs':'vm','templateUrl':_0x1ca011,'parent':angular['element'](_0x215a9a['body']),'targetEvent':_0x2c98dc,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x41cd0a,'openchannelQueues':_0x1bbbb3[_0x508d38('0xaf6')]?_0x1bbbb3[_0x508d38('0xaf6')][_0x508d38('0x269a')]:[],'crudPermissions':_0x1bbbb3[_0x508d38('0x243c')]}});}function _0x55b0e2(_0x2fb0d7,_0x3cbc21){const _0x1759f2=_0x461004;_0x440aa3[_0x1759f2('0x1f80')]({'controller':'OpenchannelQueueagentaddController','controllerAs':'vm','templateUrl':_0xd7ba85,'parent':angular[_0x1759f2('0x1194')](_0x215a9a['body']),'targetEvent':_0x3cbc21,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x2fb0d7,'openchannelQueues':_0x1bbbb3['openchannelQueues']?_0x1bbbb3[_0x1759f2('0xaf6')]['rows']:[],'crudPermissions':_0x1bbbb3['crudPermissions'],'realtime':![]}});}function _0x403b1c(_0x2b433f,_0x2ec42c){const _0x304fdb=_0x461004,_0x598920=_0x440aa3['confirm']()[_0x304fdb('0xcdc')](_0x304fdb('0x288d')+_0x2cfb05()['startCase'](_0x304fdb('0x262f'))+'?')['htmlContent'](_0x304fdb('0x12b5')+(_0x2b433f[_0x304fdb('0x4f0')]||_0x304fdb('0x262f'))+_0x304fdb('0xace')+'\x20will\x20be\x20deleted.')[_0x304fdb('0x8e8')]('delete\x20openchannelQueue')[_0x304fdb('0x203b')](_0x2ec42c)['ok']('OK')[_0x304fdb('0x3f')](_0x304fdb('0x2d3'));_0x440aa3[_0x304fdb('0x1f80')](_0x598920)[_0x304fdb('0x1166')](function(){_0x56daa0(_0x2b433f);},function(){const _0x135aec=_0x304fdb;console[_0x135aec('0x455')](_0x135aec('0x2d3'));});}function _0x585b7d(){const _0x24aff6=_0x461004;if(_0x1fd983['hasRole'](_0x24aff6('0xa7c')))_0x588437['go'](_0x24aff6('0x1668'),{});else return _0xe48d1b[_0x24aff6('0x17aa')][_0x24aff6('0xd83')]({'userProfileId':_0x1fd983[_0x24aff6('0x26cd')]()[_0x24aff6('0xb86')],'sectionId':0x32a})[_0x24aff6('0xa44')][_0x24aff6('0x1166')](function(_0x4a3a0b){const _0x8a0b68=_0x24aff6,_0x52f5c9=_0x4a3a0b&&_0x4a3a0b[_0x8a0b68('0x269a')]?_0x4a3a0b[_0x8a0b68('0x269a')][0x0]:null;_0x52f5c9&&_0x52f5c9[_0x8a0b68('0xc27')]?_0x588437['go'](_0x8a0b68('0x1668'),{}):_0x2423ee['info']({'title':_0x33184f[_0x8a0b68('0x25cc')](_0x8a0b68('0x627')),'msg':_0x33184f[_0x8a0b68('0x25cc')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_MESSAGE')});})[_0x24aff6('0x1a80')](function(_0x56d8de){const _0x472acb=_0x24aff6;_0x2423ee[_0x472acb('0xfc9')]({'title':_0x56d8de[_0x472acb('0x52d')]?_0x472acb('0x1e21')+_0x56d8de[_0x472acb('0x52d')]+_0x472acb('0x11e1')+_0x56d8de[_0x472acb('0xe1b')]:_0x472acb('0x153e'),'msg':_0x56d8de[_0x472acb('0x52d')]?JSON[_0x472acb('0xbac')](_0x56d8de[_0x472acb('0x25f4')]):_0x56d8de[_0x472acb('0x1586')]()});});}let _0x3bab9e=!![],_0x3d0365=0x1;_0x20b5e6[_0x461004('0xe83')](_0x461004('0x12d8'),function(_0x27eccc,_0x4118fc){const _0x56e55a=_0x461004;_0x3bab9e?_0x1ce10f(function(){_0x3bab9e=![];}):(!_0x4118fc&&(_0x3d0365=_0x1bbbb3[_0x56e55a('0x2218')][_0x56e55a('0x1a43')]),_0x27eccc!==_0x4118fc&&(_0x1bbbb3[_0x56e55a('0x2218')][_0x56e55a('0x1a43')]=0x1),!_0x27eccc&&(_0x1bbbb3[_0x56e55a('0x2218')][_0x56e55a('0x1a43')]=_0x3d0365),_0x1bbbb3[_0x56e55a('0x2bb')]());});function _0x5181a9(_0x3c7cc8){const _0x3a4bb6=_0x461004;_0x1bbbb3[_0x3a4bb6('0xaf6')]=_0x3c7cc8||{'count':0x0,'rows':[]};}function _0xc3abff(){const _0x18d8da=_0x461004;_0x1bbbb3[_0x18d8da('0x2218')][_0x18d8da('0x1098')]=(_0x1bbbb3[_0x18d8da('0x2218')][_0x18d8da('0x1a43')]-0x1)*_0x1bbbb3[_0x18d8da('0x2218')]['limit'],_0x1fd983[_0x18d8da('0x1ac6')](_0x18d8da('0xa7c'))?_0x1bbbb3[_0x18d8da('0x1f48')]=_0xe48d1b[_0x18d8da('0x262f')]['get'](_0x1bbbb3[_0x18d8da('0x2218')],_0x5181a9)['$promise']:(_0x1bbbb3[_0x18d8da('0x2218')]['id']=_0x1bbbb3[_0x18d8da('0x7f')]['id'],_0x1bbbb3['query'][_0x18d8da('0xe60')]=_0x18d8da('0x1eb3'),_0x1bbbb3[_0x18d8da('0x1f48')]=_0xe48d1b[_0x18d8da('0x7f')]['getResources'](_0x1bbbb3[_0x18d8da('0x2218')],_0x5181a9)[_0x18d8da('0xa44')]);}function _0x4ea16d(_0x1c5fb8,_0x3fe937){const _0x1280e6=_0x461004;_0x440aa3[_0x1280e6('0x1f80')]({'controller':_0x1280e6('0x1364'),'controllerAs':'vm','templateUrl':_0x40072f,'parent':angular[_0x1280e6('0x1194')](_0x215a9a['body']),'targetEvent':_0x1c5fb8,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x3fe937,'openchannelQueues':_0x1bbbb3['openchannelQueues'][_0x1280e6('0x269a')],'license':_0x1bbbb3[_0x1280e6('0x5c9')],'setting':_0x1bbbb3[_0x1280e6('0xf8a')],'crudPermissions':_0x1bbbb3['crudPermissions']}});}function _0x56daa0(_0x2989dc){const _0x2a2907=_0x461004;_0xe48d1b[_0x2a2907('0x262f')][_0x2a2907('0x906')]({'id':_0x2989dc['id']})[_0x2a2907('0xa44')][_0x2a2907('0x1166')](function(){const _0x4f00ae=_0x2a2907;_0x2cfb05()[_0x4f00ae('0x127f')](_0x1bbbb3[_0x4f00ae('0xaf6')][_0x4f00ae('0x269a')],{'id':_0x2989dc['id']}),_0x1bbbb3[_0x4f00ae('0xaf6')][_0x4f00ae('0x240f')]-=0x1,!_0x1bbbb3[_0x4f00ae('0xaf6')][_0x4f00ae('0x269a')][_0x4f00ae('0x264b')]&&_0x1bbbb3[_0x4f00ae('0x2bb')](),_0x2423ee[_0x4f00ae('0x103b')]({'title':_0x2cfb05()[_0x4f00ae('0xb35')](_0x4f00ae('0x138c'))+_0x4f00ae('0x2b6'),'msg':_0x2989dc[_0x4f00ae('0x4f0')]?_0x2989dc[_0x4f00ae('0x4f0')]+_0x4f00ae('0x7cd'):''});})[_0x2a2907('0x1a80')](function(_0x261fcd){const _0x1bf3a2=_0x2a2907;if(_0x261fcd['data']&&_0x261fcd[_0x1bf3a2('0x25f4')][_0x1bf3a2('0x61a')]&&_0x261fcd[_0x1bf3a2('0x25f4')][_0x1bf3a2('0x61a')]['length']){_0x1bbbb3[_0x1bf3a2('0x61a')]=_0x261fcd['data']['errors']||[{'message':_0x261fcd['toString'](),'type':'SYSTEM:DELETEopenchannelQueue'}];for(let _0x5f3011=0x0;_0x5f3011<_0x261fcd[_0x1bf3a2('0x25f4')][_0x1bf3a2('0x61a')][_0x1bf3a2('0x264b')];_0x5f3011++){_0x2423ee[_0x1bf3a2('0xfc9')]({'title':_0x261fcd['data'][_0x1bf3a2('0x61a')][_0x5f3011][_0x1bf3a2('0x1345')],'msg':_0x261fcd['data'][_0x1bf3a2('0x61a')][_0x5f3011][_0x1bf3a2('0x1e70')]});}}else _0x2423ee['error']({'title':_0x261fcd[_0x1bf3a2('0x52d')]?_0x1bf3a2('0x1e21')+_0x261fcd['status']+_0x1bf3a2('0x11e1')+_0x261fcd['statusText']:_0x1bf3a2('0x1bc3'),'msg':_0x261fcd['data']?JSON[_0x1bf3a2('0xbac')](_0x261fcd[_0x1bf3a2('0x25f4')]['message']):_0x261fcd[_0x1bf3a2('0x1e70')]||_0x261fcd[_0x1bf3a2('0x1586')]()});});}function _0x3c490c(){const _0x3b80d4=_0x461004,_0x8af4c1=angular[_0x3b80d4('0x225f')](_0x1bbbb3['selectedOpenchannelQueues']);return _0x1bbbb3[_0x3b80d4('0x3dd')]=[],_0x8af4c1;}function _0x2c2bf6(_0x3ec1a1){const _0x17f882=_0x461004,_0x2d2eed=_0x440aa3['confirm']()['title'](_0x17f882('0x25ff'))[_0x17f882('0xf3c')](_0x17f882('0x12b5')+_0x1bbbb3[_0x17f882('0x3dd')]['length']+'\x20selected'+_0x17f882('0x3f3'))[_0x17f882('0x8e8')](_0x17f882('0xbd5'))[_0x17f882('0x203b')](_0x3ec1a1)['ok']('OK')['cancel']('CANCEL');_0x440aa3[_0x17f882('0x1f80')](_0x2d2eed)[_0x17f882('0x1166')](function(){const _0xfe9f2=_0x17f882;_0x1bbbb3[_0xfe9f2('0x3dd')]['forEach'](function(_0x4afffe){_0x56daa0(_0x4afffe);}),_0x1bbbb3[_0xfe9f2('0x3dd')]=[];});}function _0x17c28d(){const _0x3ec823=_0x461004;_0x1bbbb3[_0x3ec823('0x3dd')]=[];}function _0x288c2e(){const _0x53898a=_0x461004;_0x1bbbb3[_0x53898a('0x3dd')]=_0x1bbbb3[_0x53898a('0xaf6')][_0x53898a('0x269a')];}}const _0x527ad8=_0x3ea5f1;_0x5ad369[_0x36e6f4('0x1294')]=['$stateProvider',_0x36e6f4('0x1562')];function _0x5ad369(_0x253d13,_0x538bd1){const _0x5173e6=_0x36e6f4;_0x253d13[_0x5173e6('0x63f')](_0x5173e6('0x1c1'),{'abstract':!![],'url':'/openchannel'})[_0x5173e6('0x63f')](_0x5173e6('0x20b5'),{'url':_0x5173e6('0x24b0'),'views':{'content@app':{'templateUrl':_0x2743dc,'controller':_0x5173e6('0x13c9')}},'resolve':{'openchannelQueues':[_0x5173e6('0x1fbc'),_0x5173e6('0x21ef'),function(_0x18112f,_0x1a8de5){const _0x4a5363=_0x5173e6;return _0x1a8de5[_0x4a5363('0x1ac6')](_0x4a5363('0xa7c'))?_0x18112f[_0x4a5363('0x18af')]('openchannelQueue@get',{'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','sort':'-updatedAt','channel':_0x4a5363('0x26c'),'limit':0xa,'offset':0x0}):_0x18112f[_0x4a5363('0x18af')]('userProfile@getResources',{'id':_0x1a8de5[_0x4a5363('0x26cd')]()[_0x4a5363('0xb86')],'section':_0x4a5363('0x1eb3'),'fields':_0x4a5363('0xf26'),'sort':_0x4a5363('0x14dc'),'channel':_0x4a5363('0x26c'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x5173e6('0x1fbc'),_0x5173e6('0x21ef'),function(_0x45d53c,_0x531ea9){const _0x5176e7=_0x5173e6;return _0x531ea9[_0x5176e7('0x1ac6')]('admin')?null:_0x45d53c[_0x5176e7('0x18af')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x531ea9['getCurrentUser']()[_0x5176e7('0xb86')]});}],'userProfileSection':[_0x5173e6('0x1fbc'),_0x5173e6('0x21ef'),function(_0x175c25,_0xf9eb40){const _0x215740=_0x5173e6;return _0xf9eb40[_0x215740('0x1ac6')](_0x215740('0xa7c'))?null:_0x175c25[_0x215740('0x18af')](_0x215740('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0xf9eb40[_0x215740('0x26cd')]()[_0x215740('0xb86')],'sectionId':0x321});}]},'authenticate':!![],'permissionId':0x321,'bodyClass':_0x5173e6('0x26c')})[_0x5173e6('0x63f')](_0x5173e6('0x1c8f'),{'url':_0x5173e6('0x2233'),'params':{'openchannelQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x24ba96,'controller':_0x5173e6('0x2178')}},'resolve':{'openchannelQueue':[_0x5173e6('0x1fbc'),_0x5173e6('0xf75'),function(_0x255337,_0x27f597){const _0xcf2c28=_0x5173e6;return _0x255337[_0xcf2c28('0x18af')](_0xcf2c28('0x4a3'),{'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','id':_0x27f597['id']});}],'userProfileSection':['apiResolver','Auth',function(_0xe3e1ef,_0x52f8ff){const _0x22de08=_0x5173e6;return _0xe3e1ef[_0x22de08('0x18af')](_0x22de08('0xaf'),{'fields':_0x22de08('0xe26'),'userProfileId':_0x52f8ff['getCurrentUser']()[_0x22de08('0xb86')],'sectionId':0x321});}]},'authenticate':!![],'permissionId':0x321,'bodyClass':_0x5173e6('0x26c')})[_0x5173e6('0x63f')]('app.openchannel.openchannelAccounts',{'url':'/openchannelAccounts','views':{'content@app':{'templateUrl':_0x23bd77,'controller':_0x5173e6('0x1c85')}},'resolve':{'openchannelAccounts':[_0x5173e6('0x1fbc'),_0x5173e6('0x21ef'),function(_0x3e0f65,_0x412a29){const _0x206996=_0x5173e6;return _0x412a29[_0x206996('0x1ac6')]('admin')?_0x3e0f65[_0x206996('0x18af')](_0x206996('0x1ccb'),{'fields':_0x206996('0x98f'),'sort':_0x206996('0x14dc'),'limit':0xa,'offset':0x0}):_0x3e0f65[_0x206996('0x18af')](_0x206996('0x17c4'),{'id':_0x412a29[_0x206996('0x26cd')]()[_0x206996('0xb86')],'section':_0x206996('0x1575'),'fields':'createdAt,updatedAt,id,name,key,token,replyUri,ListId,waitForTheAssignedAgent,mapKey,mandatoryDisposition,mandatoryDispositionPauseId,description,receiveUri,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','sort':_0x206996('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x5173e6('0x1fbc'),'Auth',function(_0x1c6383,_0x4c259e){const _0x2c87e4=_0x5173e6;return _0x4c259e['hasRole'](_0x2c87e4('0xa7c'))?null:_0x1c6383[_0x2c87e4('0x18af')](_0x2c87e4('0x697'),{'fields':_0x2c87e4('0x686'),'id':_0x4c259e[_0x2c87e4('0x26cd')]()[_0x2c87e4('0xb86')]});}],'userProfileSection':[_0x5173e6('0x1fbc'),_0x5173e6('0x21ef'),function(_0x26c4f,_0x5c4d0b){const _0x25a710=_0x5173e6;return _0x5c4d0b[_0x25a710('0x1ac6')](_0x25a710('0xa7c'))?null:_0x26c4f['resolve']('userProfileSection@get',{'fields':_0x25a710('0xe26'),'userProfileId':_0x5c4d0b[_0x25a710('0x26cd')]()[_0x25a710('0xb86')],'sectionId':0x322});}]},'authenticate':!![],'permissionId':0x322,'bodyClass':_0x5173e6('0x26c')})[_0x5173e6('0x63f')](_0x5173e6('0xa75'),{'url':_0x5173e6('0x2233'),'params':{'openchannelAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x4d28d1,'controller':_0x5173e6('0xcb5')}},'resolve':{'openchannelAccount':[_0x5173e6('0x1fbc'),_0x5173e6('0xf75'),function(_0x375034,_0x28c9f1){const _0x37b1fb=_0x5173e6;return _0x375034['resolve']('openchannelAccount@get',{'fields':_0x37b1fb('0x98f'),'id':_0x28c9f1['id']});}],'userProfileSection':[_0x5173e6('0x1fbc'),'Auth',function(_0x102664,_0x554282){const _0x47f2b5=_0x5173e6;return _0x102664[_0x47f2b5('0x18af')](_0x47f2b5('0xaf'),{'fields':_0x47f2b5('0xe26'),'userProfileId':_0x554282[_0x47f2b5('0x26cd')]()['userProfileId'],'sectionId':0x322});}]},'authenticate':!![],'permissionId':0x322,'bodyClass':_0x5173e6('0x26c')}),_0x538bd1[_0x5173e6('0x95e')](_0x5173e6('0x695'));}angular['module'](_0x36e6f4('0x1c1'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),'flow','mdColorPicker',_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),'mwFormUtils',_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),'app.openchannel.realtime'])[_0x36e6f4('0xe11')](_0x5ad369)[_0x36e6f4('0x75e')]('CreateOrEditOpenchannelAccountDialogController',_0x8d7399)[_0x36e6f4('0x75e')](_0x36e6f4('0x95d'),_0x11e977)[_0x36e6f4('0x75e')]('OpenchannelAccountagentaddController',_0x22bfc1)[_0x36e6f4('0x75e')](_0x36e6f4('0xe2e'),_0x34e150)['controller'](_0x36e6f4('0x1807'),_0x5403e3)[_0x36e6f4('0x75e')]('EditOpenchannelAccountAppautoreplyDialogController',_0x2f2e6c)['controller'](_0x36e6f4('0x116d'),_0x354044)[_0x36e6f4('0x75e')](_0x36e6f4('0x75d'),_0x1f3074)[_0x36e6f4('0x75e')](_0x36e6f4('0x20d'),_0x436ffb)[_0x36e6f4('0x75e')]('EditOpenchannelAccountAppgotopDialogController',_0x29d581)[_0x36e6f4('0x75e')]('EditOpenchannelAccountAppintervalDialogController',_0x55a911)['controller']('EditOpenchannelAccountAppnoopDialogController',_0x53ede9)[_0x36e6f4('0x75e')](_0x36e6f4('0x22f1'),_0xabf535)[_0x36e6f4('0x75e')](_0x36e6f4('0x1ffd'),_0x29a45f)[_0x36e6f4('0x75e')](_0x36e6f4('0x1b95'),_0x37491c)[_0x36e6f4('0x75e')](_0x36e6f4('0x1db0'),_0x4d9526)[_0x36e6f4('0x75e')](_0x36e6f4('0x1a2'),_0x1a6214)[_0x36e6f4('0x75e')]('CreateOrEditOpenchannelCannedAnswerDialogController',_0x243177)[_0x36e6f4('0x75e')](_0x36e6f4('0x13f5'),_0x1f0572)[_0x36e6f4('0x75e')](_0x36e6f4('0x28af'),_0x40a44e)[_0x36e6f4('0x75e')]('OpenchannelAccountsController',_0xb83790)[_0x36e6f4('0x75e')](_0x36e6f4('0x1364'),_0x39c5b4)[_0x36e6f4('0x75e')](_0x36e6f4('0x184a'),_0x50aad3)[_0x36e6f4('0x75e')](_0x36e6f4('0xe21'),_0x48be12)[_0x36e6f4('0x75e')](_0x36e6f4('0x1ba8'),_0x594c1d)[_0x36e6f4('0x75e')](_0x36e6f4('0x192b'),_0x527ad8);const _0x51ea19=_0x2734b2['p']+_0x36e6f4('0x1e8'),_0x42c061=_0x2734b2['p']+_0x36e6f4('0x1f8a'),_0x317850=_0x2734b2['p']+_0x36e6f4('0x710'),_0x300918=_0x2734b2['p']+_0x36e6f4('0x513'),_0x44e6f1=_0x2734b2['p']+_0x36e6f4('0x1115'),_0x3e81a2=_0x2734b2['p']+_0x36e6f4('0x269f'),_0x4d3a13=_0x2734b2['p']+_0x36e6f4('0x1ad3'),_0x3054c2=_0x2734b2['p']+_0x36e6f4('0xc57'),_0x216b0c=_0x2734b2['p']+_0x36e6f4('0x12a4');_0x4bae34[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$timeout',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$state','api',_0x36e6f4('0x2661'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xd6c'),_0x36e6f4('0xe72'),'userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x4bae34(_0x229243,_0x21fa7f,_0x1d294d,_0x3dc733,_0x1da23b,_0x111e89,_0x36cfdf,_0x29edf3,_0xf8ce6e,_0x1fd928,_0x13d746,_0x24173e,_0x63b619){const _0x33bca8=_0x36e6f4,_0x5536cd=this;_0x5536cd['currentUser']=_0x63b619[_0x33bca8('0x26cd')](),_0x5536cd[_0x33bca8('0x240f')]=_0xf8ce6e&&_0xf8ce6e[_0x33bca8('0x240f')]?_0xf8ce6e[_0x33bca8('0x240f')]:0x0,_0x5536cd[_0x33bca8('0xd6c')]=_0xf8ce6e?_0x2cfb05()['keyBy'](_0xf8ce6e[_0x33bca8('0x269a')]?_0xf8ce6e[_0x33bca8('0x269a')]:[],'id'):{},_0x5536cd[_0x33bca8('0xe72')]=_0x1fd928?_0x2cfb05()[_0x33bca8('0x155c')](_0x1fd928[_0x33bca8('0x269a')]?_0x1fd928[_0x33bca8('0x269a')]:[],'id'):{},_0x5536cd[_0x33bca8('0x7f')]=_0x13d746,_0x5536cd['userProfileSection']=_0x24173e&&_0x24173e['count']==0x1?_0x24173e[_0x33bca8('0x269a')][0x0]:null,_0x5536cd[_0x33bca8('0x243c')]=_0x63b619['parseCrudPermissions'](_0x5536cd[_0x33bca8('0x17aa')]?_0x5536cd[_0x33bca8('0x17aa')][_0x33bca8('0x243c')]:null),_0x5536cd['query']={'sort':_0x33bca8('0x2237'),'limit':0xa,'page':0x1},_0x5536cd['success']=_0x54c857,_0x5536cd[_0x33bca8('0x1089')]=_0x2cf6e9,_0x5536cd[_0x33bca8('0x1f63')]=_0x514e8b,_0x5536cd[_0x33bca8('0x1303')]=_0x20e958,_0x5536cd[_0x33bca8('0x1307')]=_0x55581e,_0x5536cd[_0x33bca8('0x1f3d')]=_0x24096c,_0x5536cd['order']=[],_0x2cfb05()[_0x33bca8('0x941')](_0x5536cd[_0x33bca8('0xd6c')],function(_0x2ff5d0){const _0x826c64=_0x33bca8;_0x5536cd[_0x826c64('0xa99')][_0x826c64('0x1514')](_0x2ff5d0['id']);}),_0x36cfdf['on'](_0x33bca8('0x258'),_0x5536cd[_0x33bca8('0x1303')]),_0x36cfdf['on'](_0x33bca8('0x1cb1'),_0x5536cd[_0x33bca8('0x1303')]),_0x36cfdf['on'](_0x33bca8('0x1c76'),_0x5536cd[_0x33bca8('0x1307')]);function _0x2cf6e9(){const _0x3768e8=_0x33bca8;_0x2cfb05()[_0x3768e8('0x941')](_0x5536cd[_0x3768e8('0xd6c')],function(_0x35db97,_0x5c7a5d){const _0xb84fc6=_0x3768e8;_0x5536cd['rpcFaxAccounts'][_0x5c7a5d]&&_0x2cfb05()[_0xb84fc6('0xcc3')](_0x35db97,_0x5536cd['rpcFaxAccounts'][_0x5c7a5d]);}),_0x2cfb05()[_0x3768e8('0x941')](_0x5536cd['faxAccounts'],function(_0x139c4b,_0x58a8d0){const _0x3515d6=_0x3768e8,_0x5bd52b={'id':_0x58a8d0,'sort':'-id','direction':'in','limit':0x1,'offset':0x0,'$gte':_0x3515d6('0xd17')+_0x24273b()()[_0x3515d6('0x1659')](_0x3515d6('0x16a'))[_0x3515d6('0x128a')](_0x3515d6('0x1084'))};_0x111e89['faxAccount'][_0x3515d6('0x16f2')](_0x5bd52b)[_0x3515d6('0xa44')]['then'](function(_0x5ee4f9){const _0x5bf89c=_0x3515d6;return _0x5ee4f9&&(_0x139c4b['in']=_0x5ee4f9[_0x5bf89c('0x240f')]||0x0,_0x139c4b['lastIn']=_0x5ee4f9['rows']&&_0x5ee4f9[_0x5bf89c('0x269a')]['length']?_0x5ee4f9[_0x5bf89c('0x269a')][0x0][_0x5bf89c('0x262')]:undefined),_0x5bd52b[_0x5bf89c('0x2788')]=_0x5bf89c('0x15ff'),_0x111e89[_0x5bf89c('0x2085')][_0x5bf89c('0x16f2')](_0x5bd52b)[_0x5bf89c('0xa44')];})[_0x3515d6('0x1166')](function(_0x1f8b29){const _0x12a4a9=_0x3515d6;_0x1f8b29&&(_0x139c4b[_0x12a4a9('0x15ff')]=_0x1f8b29[_0x12a4a9('0x240f')]||0x0,_0x139c4b[_0x12a4a9('0x13fc')]=_0x1f8b29[_0x12a4a9('0x269a')]&&_0x1f8b29[_0x12a4a9('0x269a')][_0x12a4a9('0x264b')]?_0x1f8b29[_0x12a4a9('0x269a')][0x0][_0x12a4a9('0x262')]:undefined);})[_0x3515d6('0x1a80')](function(_0x42c1c6){const _0x5b36db=_0x3515d6;console[_0x5b36db('0x455')](_0x42c1c6);});});}function _0x20e958(_0x3b2b72){const _0x5c2cbc=_0x33bca8;_0x5536cd[_0x5c2cbc('0xd6c')][_0x3b2b72['id']]&&_0x2cfb05()['merge'](_0x5536cd[_0x5c2cbc('0xd6c')][_0x3b2b72['id']],_0x3b2b72);}function _0x55581e(_0x45906f){const _0x335338=_0x33bca8;_0x5536cd[_0x335338('0xd6c')][_0x45906f[_0x335338('0x18fe')]]&&(_0x45906f[_0x335338('0x2788')]=='in'?(_0x5536cd[_0x335338('0xd6c')][_0x45906f['FaxAccountId']]['in']+=0x1,_0x5536cd[_0x335338('0xd6c')][_0x45906f['FaxAccountId']][_0x335338('0x9dc')]=_0x45906f['createdAt']):(_0x5536cd['faxAccounts'][_0x45906f[_0x335338('0x18fe')]][_0x335338('0x15ff')]+=0x1,_0x5536cd[_0x335338('0xd6c')][_0x45906f[_0x335338('0x18fe')]][_0x335338('0x13fc')]=_0x45906f['createdAt']));}function _0x24096c(_0x51851e,_0x197bfc){const _0x5bcaf0=_0x33bca8;_0x1da23b['go'](_0x5bcaf0('0x140b'),{'id':_0x197bfc['id'],'faxAccount':_0x197bfc});}let _0x2030b3=!![],_0x598e7f=0x1;_0x229243[_0x33bca8('0xe83')](_0x33bca8('0x12d8'),function(_0x2f1fe3,_0x483e68){const _0x4af54f=_0x33bca8;_0x2030b3?_0x21fa7f(function(){_0x2030b3=![];}):(!_0x483e68&&(_0x598e7f=_0x5536cd[_0x4af54f('0x2218')][_0x4af54f('0x1a43')]),_0x2f1fe3!==_0x483e68&&(_0x5536cd[_0x4af54f('0x2218')][_0x4af54f('0x1a43')]=0x1),!_0x2f1fe3&&(_0x5536cd[_0x4af54f('0x2218')][_0x4af54f('0x1a43')]=_0x598e7f),_0x5536cd['getFaxAccounts']());});function _0x54c857(_0x3ec470){const _0x397584=_0x33bca8;_0x5536cd[_0x397584('0xd6c')]=_0x3ec470?_0x2cfb05()[_0x397584('0x155c')](_0x3ec470['rows']?_0x3ec470[_0x397584('0x269a')]:[],'id'):{};if(_0x3ec470[_0x397584('0x269a')]){_0x5536cd[_0x397584('0xa99')]=[];for(let _0x43766c=0x0;_0x43766c<_0x3ec470[_0x397584('0x269a')][_0x397584('0x264b')];_0x43766c++){_0x5536cd['order'][_0x397584('0x1514')](_0x3ec470[_0x397584('0x269a')][_0x43766c]['id']);}}_0x2cf6e9();}function _0x514e8b(){const _0x395c65=_0x33bca8;_0x5536cd[_0x395c65('0x2218')][_0x395c65('0x1098')]=(_0x5536cd[_0x395c65('0x2218')][_0x395c65('0x1a43')]-0x1)*_0x5536cd['query']['limit'],_0x63b619[_0x395c65('0x1ac6')](_0x395c65('0xa7c'))?_0x5536cd[_0x395c65('0x1f48')]=_0x111e89[_0x395c65('0x2085')]['get'](_0x5536cd[_0x395c65('0x2218')],_0x54c857)[_0x395c65('0xa44')]:(_0x5536cd['query']['id']=_0x5536cd[_0x395c65('0x7f')]['id'],_0x5536cd['query'][_0x395c65('0xe60')]='FaxAccounts',_0x5536cd[_0x395c65('0x1f48')]=_0x111e89[_0x395c65('0x7f')][_0x395c65('0x263a')](_0x5536cd['query'],_0x54c857)['$promise']);}_0x229243[_0x33bca8('0x3d2')]('$destroy',function(){const _0x439a84=_0x33bca8;_0x36cfdf['removeAllListeners'](_0x439a84('0x258')),_0x36cfdf['removeAllListeners'](_0x439a84('0x1cb1')),_0x36cfdf[_0x439a84('0x1800')](_0x439a84('0x1c76'));});}const _0x589d71=_0x4bae34;_0x582eb8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$q',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x18bc'),_0x36e6f4('0xe29'),_0x36e6f4('0x1f7e'),_0x36e6f4('0x24b7'),_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1a02'),'userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0x10eb')];function _0x582eb8(_0x4ffd87,_0x2e6401,_0x1281a3,_0x191187,_0x16490c,_0x775e96,_0x4a6951,_0x33e141,_0x328266,_0x1e9337,_0x3a8cb1,_0x2eb3ad,_0x1f0a60,_0x47d419,_0x564707,_0x5a9be8,_0x26afad,_0x5c58a2){const _0x173688=_0x36e6f4,_0x130b6d=this,_0x3cf7ec=['userpic',_0x173688('0xb41'),_0x173688('0x2318'),'lastPauseAt','pauseType','lastPauseAt','internal',_0x173688('0x16a6'),_0x173688('0x1c5c'),_0x173688('0x287f'),_0x173688('0xb4'),_0x173688('0x178d'),_0x173688('0x11ee'),'faxPause','voicePause',_0x173688('0x6a8'),'openchannelCapacity','mailCapacity','smsCapacity',_0x173688('0x361'),_0x173688('0x1462'),_0x173688('0x1107'),'openchannelCurrentCapacity',_0x173688('0x82d'),_0x173688('0x1da1'),'whatsappCurrentCapacity','faxCurrentCapacity','chatStatus',_0x173688('0x1f33'),_0x173688('0x25d8'),_0x173688('0x1c1a'),_0x173688('0x1a5d'),_0x173688('0x276d'),_0x173688('0x17e1'),'chatStatusTime','openchannelStatusTime',_0x173688('0x1955'),_0x173688('0x2357'),_0x173688('0x11a8'),_0x173688('0x4f3'),'voiceStatusTime',_0x173688('0x1d3e'),_0x173688('0x1ad2'),'screenrecording',_0x173688('0x2167'),_0x173688('0x1c5b')],_0x23f951=[_0x173688('0x1c5c'),_0x173688('0x287f'),_0x173688('0xb4'),_0x173688('0x178d'),_0x173688('0x11ee'),_0x173688('0x5aa'),_0x173688('0x2540'),_0x173688('0xb41')];_0x130b6d[_0x173688('0x98')]=_0x5a9be8[_0x173688('0x26cd')](),_0x130b6d['availableStates']=[_0x173688('0x1628'),_0x173688('0x133e'),'busy','onhold',_0x173688('0x521')],_0x130b6d[_0x173688('0xe29')]=_0x4a6951||{'count':0x0,'rows':[]},_0x130b6d[_0x173688('0x5c9')]=_0x26afad,_0x130b6d[_0x173688('0x7f')]=_0x47d419,_0x130b6d['userProfileSection']=_0x564707&&_0x564707[_0x173688('0x240f')]==0x1?_0x564707[_0x173688('0x269a')][0x0]:null,_0x130b6d[_0x173688('0x243c')]=_0x5a9be8[_0x173688('0xd87')](_0x130b6d[_0x173688('0x17aa')]?_0x130b6d[_0x173688('0x17aa')][_0x173688('0x243c')]:null),_0x130b6d['agents']=_0x33e141?_0x2cfb05()[_0x173688('0x155c')](_0x33e141[_0x173688('0x269a')]?_0x33e141['rows']:[],'id'):{},_0x130b6d['rpcAgents']=_0x328266?_0x2cfb05()[_0x173688('0x155c')](_0x328266[_0x173688('0x269a')]?_0x328266['rows']:[],'id'):{},_0x130b6d['paginatedAgents']={},_0x130b6d[_0x173688('0x173f')]=![],_0x130b6d[_0x173688('0xa99')]=[],_0x130b6d[_0x173688('0x4c4')]={};for(const _0x492770 in _0x130b6d['agents']){typeof _0x130b6d[_0x173688('0x1f7e')][_0x492770]!==_0x173688('0x1048')&&(_0x130b6d['agents'][_0x492770][_0x173688('0x24d5')]=!![]);}_0x130b6d['query']={'limit':0xa,'page':0x1,'order':'fullname','globalStatusFilter':'','pauseTypeFilter':''},_0x130b6d[_0x173688('0x885')]=_0x4bf3e2,_0x130b6d['queueAdd']=_0x2facf5,_0x130b6d[_0x173688('0x1e77')]=_0x2657cb,_0x130b6d[_0x173688('0xecc')]=_0x4fd4fc,_0x130b6d[_0x173688('0x6df')]=_0x543db6,_0x130b6d[_0x173688('0x72f')]=_0x58b21e,_0x130b6d['getAgentGlobalStatus']=_0x4c1d58,_0x130b6d[_0x173688('0x882')]=_0x3c7ac9,_0x130b6d['checkPause']=_0x2be910,_0x130b6d[_0x173688('0xb02')]=_0x15fc7a,_0x130b6d['onSave']=_0x1d305c,_0x130b6d[_0x173688('0x2232')]=_0x2fc260,_0x130b6d[_0x173688('0xae0')]=_0x12d70f,_0x130b6d['onConnect']=_0x4617ca,_0x130b6d[_0x173688('0x1923')]=_0x405f03,_0x130b6d[_0x173688('0x2845')]=_0x8341ea,_0x3a8cb1['on'](_0x173688('0x26b2'),_0x130b6d[_0x173688('0x1303')]),_0x3a8cb1['on'](_0x173688('0x19d5'),_0x130b6d[_0x173688('0x2232')]),_0x3a8cb1['on']('user:agentconnect',_0x130b6d[_0x173688('0x223a')]),_0x3a8cb1['on']('user:agentcomplete',_0x130b6d[_0x173688('0x1923')]),_0x12d70f();let _0x21a197=_0x5c58a2(function(){const _0x4d5f12=_0x173688;_0x130b6d[_0x4d5f12('0x173f')]&&(_0x130b6d[_0x4d5f12('0x173f')]=![],_0x12d70f());},0x3e7);function _0x12d70f(){const _0x4c5baf=_0x173688;_0x130b6d[_0x4c5baf('0x173f')]=![];const _0x26eb28=_0x2e6401[_0x4c5baf('0x24d8')]();_0x130b6d[_0x4c5baf('0x1f48')]=_0x26eb28[_0x4c5baf('0x1f48')],_0x130b6d[_0x4c5baf('0x220b')]=[],_0x130b6d[_0x4c5baf('0xa99')]=[],_0x2cfb05()[_0x4c5baf('0x941')](_0x130b6d[_0x4c5baf('0x1f7e')],function(_0x3d254f,_0x5a66f7){const _0x187635=_0x4c5baf;_0x130b6d['rpcAgents'][_0x5a66f7]&&_0x2cfb05()[_0x187635('0xcc3')](_0x3d254f,_0x2cfb05()['pick'](_0x2cfb05()[_0x187635('0x1414')](_0x130b6d[_0x187635('0x24b7')][_0x5a66f7],_0x23f951),_0x3cf7ec)),_0x4c1d58(_0x3d254f),_0x3d254f[_0x187635('0xb41')]?(_0x130b6d[_0x187635('0x220b')][_0x187635('0x1514')](_0x3d254f),_0x130b6d[_0x187635('0x4c4')][_0x3d254f['internal']]=_0x5a66f7):_0x3d254f[_0x187635('0x25b3')]=_0x2cfb05()[_0x187635('0xa53')](_0x24273b()()[_0x187635('0x128a')]('x'));});_0x130b6d[_0x4c5baf('0x2218')][_0x4c5baf('0xf4')]&&_0x2cfb05()[_0x4c5baf('0x127f')](_0x130b6d['filteredAgents'],function(_0x123498){const _0x35f04d=_0x4c5baf;return _0x123498['globalStatus']!==_0x130b6d['query'][_0x35f04d('0xf4')];});_0x130b6d[_0x4c5baf('0x2218')][_0x4c5baf('0x2121')]&&_0x2cfb05()[_0x4c5baf('0x127f')](_0x130b6d['filteredAgents'],function(_0x9afae8){const _0x23b29f=_0x4c5baf;return _0x9afae8[_0x23b29f('0x246c')]!==_0x130b6d[_0x23b29f('0x2218')]['pauseTypeFilter'];});_0x130b6d[_0x4c5baf('0x2218')][_0x4c5baf('0x1c33')]&&_0x2cfb05()['remove'](_0x130b6d[_0x4c5baf('0x220b')],function(_0x62a8be){const _0x526631=_0x4c5baf;return _0x62a8be['fullname'][_0x526631('0x2574')]()[_0x526631('0x2379')](_0x130b6d['query']['filter'][_0x526631('0x2574')]())<0x0;});_0x130b6d[_0x4c5baf('0x220b')]=_0x2b8ce1(_0x130b6d[_0x4c5baf('0x220b')]);const _0x13f32d=(_0x130b6d[_0x4c5baf('0x2218')][_0x4c5baf('0x1a43')]-0x1)*_0x130b6d[_0x4c5baf('0x2218')]['limit'];_0x130b6d['paginatedAgents']=_0x2cfb05()[_0x4c5baf('0x3e5')](_0x130b6d[_0x4c5baf('0x220b')],_0x13f32d)['slice'](0x0,_0x130b6d[_0x4c5baf('0x2218')][_0x4c5baf('0x163f')]);for(let _0x59e663=0x0;_0x59e663<_0x130b6d['paginatedAgents'][_0x4c5baf('0x264b')];_0x59e663+=0x1){_0x130b6d[_0x4c5baf('0xa99')]['push'](_0x130b6d[_0x4c5baf('0x5e5')][_0x59e663]['id']);}_0x26eb28[_0x4c5baf('0x18af')](),_0x130b6d[_0x4c5baf('0x173f')]=!![];}function _0x1d305c(_0x5e9d99){const _0x3401c0=_0x173688;_0x130b6d['agents'][_0x5e9d99['id']]&&(_0x2cfb05()[_0x3401c0('0xcc3')](_0x130b6d[_0x3401c0('0x1f7e')][_0x5e9d99['id']],_0x2cfb05()[_0x3401c0('0x1a08')](_0x2cfb05()[_0x3401c0('0x1414')](_0x5e9d99,_0x23f951),_0x3cf7ec)),_0x2cfb05()[_0x3401c0('0xcc3')](_0x130b6d['rpcAgents'][_0x5e9d99['id']],_0x2cfb05()[_0x3401c0('0x1a08')](_0x2cfb05()[_0x3401c0('0x1414')](_0x5e9d99,_0x23f951),_0x3cf7ec)),_0x4c1d58(_0x130b6d[_0x3401c0('0x1f7e')][_0x5e9d99['id']]));}function _0x2fc260(_0x26fed4){const _0x295efe=_0x173688;_0x130b6d[_0x295efe('0x1f7e')][_0x26fed4['id']]&&(_0x2cfb05()[_0x295efe('0xcc3')](_0x130b6d['agents'][_0x26fed4['id']],_0x2cfb05()['pick'](_0x26fed4,_0x3cf7ec)),_0x2cfb05()[_0x295efe('0xcc3')](_0x130b6d[_0x295efe('0x24b7')][_0x26fed4['id']],_0x2cfb05()['pick'](_0x26fed4,_0x3cf7ec)),_0x26fed4[_0x295efe('0x3dc')]&&(_0x130b6d['agents'][_0x26fed4['id']][_0x295efe('0x25b3')]=_0x26fed4[_0x295efe('0x3dc')],_0x130b6d[_0x295efe('0x24b7')][_0x26fed4['id']][_0x295efe('0x25b3')]=_0x26fed4[_0x295efe('0x3dc')]),_0x4c1d58(_0x130b6d[_0x295efe('0x1f7e')][_0x26fed4['id']]));}function _0x4617ca(_0x1fe0e0){const _0x27fc74=_0x173688;_0x130b6d[_0x27fc74('0x1f7e')][_0x130b6d['agentInternal'][_0x1fe0e0[_0x27fc74('0x25fc')]]]&&(_0x2cfb05()[_0x27fc74('0xcc3')](_0x130b6d['agents'][_0x130b6d[_0x27fc74('0x4c4')][_0x1fe0e0['destaccountcode']]],_0x2cfb05()[_0x27fc74('0x1a08')](_0x1fe0e0,[_0x27fc74('0x1d3e'),'destconnectedlinenum'])),_0x2cfb05()['merge'](_0x130b6d[_0x27fc74('0x24b7')][_0x130b6d[_0x27fc74('0x4c4')][_0x1fe0e0[_0x27fc74('0x25fc')]]],_0x2cfb05()[_0x27fc74('0x1a08')](_0x1fe0e0,[_0x27fc74('0x1d3e'),_0x27fc74('0x1ad2')])));}function _0x405f03(_0x36555d){const _0x286f37=_0x173688;_0x130b6d['agents'][_0x130b6d['agentInternal'][_0x36555d[_0x286f37('0x25fc')]]]&&(_0x130b6d[_0x286f37('0x1f7e')][_0x130b6d[_0x286f37('0x4c4')][_0x36555d[_0x286f37('0x25fc')]]]=_0x2cfb05()[_0x286f37('0x1414')](_0x130b6d[_0x286f37('0x1f7e')][_0x130b6d[_0x286f37('0x4c4')][_0x36555d[_0x286f37('0x25fc')]]],[_0x286f37('0x1d3e'),_0x286f37('0x1ad2')]),_0x130b6d[_0x286f37('0x24b7')][_0x130b6d['agentInternal'][_0x36555d[_0x286f37('0x25fc')]]]=_0x2cfb05()[_0x286f37('0x1414')](_0x130b6d[_0x286f37('0x24b7')][_0x130b6d['agentInternal'][_0x36555d[_0x286f37('0x25fc')]]],[_0x286f37('0x1d3e'),'destconnectedlinenum']));}function _0x4bf3e2(_0x282a50){const _0x405913=_0x173688;return _0x1e9337['user'][_0x405913('0x885')]({'id':_0x282a50['id'],'device':'realtime','agent_id':_0x282a50['id'],'agent_name':_0x282a50[_0x405913('0x4f0')]})[_0x405913('0xa44')][_0x405913('0x1166')](function(){const _0x29efe=_0x405913;_0x2eb3ad[_0x29efe('0x103b')]({'title':_0x29efe('0x16a7'),'msg':_0x282a50['fullname']+_0x29efe('0x22ec')}),_0x130b6d[_0x29efe('0x1f7e')][_0x282a50['id']]&&(_0x130b6d[_0x29efe('0x1f7e')][_0x282a50['id']][_0x29efe('0xb41')]=![]),_0x130b6d[_0x29efe('0x24b7')][_0x282a50['id']]&&(_0x130b6d[_0x29efe('0x24b7')][_0x282a50['id']][_0x29efe('0xb41')]=![]),_0x12d70f();})['catch'](function(_0x3b9db3){const _0x1a9535=_0x405913;_0x2eb3ad[_0x1a9535('0xfc9')]({'title':_0x3b9db3[_0x1a9535('0x52d')]?_0x1a9535('0x1e21')+_0x3b9db3['status']+_0x1a9535('0x11e1')+_0x3b9db3[_0x1a9535('0xe1b')]:'api.staff.save','msg':_0x3b9db3[_0x1a9535('0x25f4')]?JSON[_0x1a9535('0xbac')](_0x3b9db3[_0x1a9535('0x25f4')][_0x1a9535('0x1e70')]):_0x3b9db3[_0x1a9535('0x1586')]()});});}function _0x2657cb(_0x53d9af,_0x550b7b){const _0x2140de=_0x173688;return _0x1e9337[_0x2140de('0x557')]['pause']({'id':_0x53d9af['id'],'type':_0x550b7b})[_0x2140de('0xa44')][_0x2140de('0x1166')](function(_0x8d7a08){const _0x4e0785=_0x2140de;_0x130b6d[_0x4e0785('0x1f7e')][_0x53d9af['id']]&&_0x2cfb05()[_0x4e0785('0xcc3')](_0x130b6d['agents'][_0x53d9af['id']],_0x2cfb05()[_0x4e0785('0x1a08')](_0x8d7a08,_0x3cf7ec)),_0x130b6d['rpcAgents'][_0x53d9af['id']]&&_0x2cfb05()[_0x4e0785('0xcc3')](_0x130b6d['rpcAgents'][_0x53d9af['id']],_0x2cfb05()[_0x4e0785('0x1a08')](_0x8d7a08,_0x3cf7ec)),_0x4c1d58(_0x130b6d[_0x4e0785('0x1f7e')][_0x53d9af['id']]);})[_0x2140de('0x1a80')](function(_0xad172f){const _0x324bdc=_0x2140de;_0x2eb3ad[_0x324bdc('0xfc9')]({'title':_0xad172f[_0x324bdc('0x52d')]?_0x324bdc('0x1e21')+_0xad172f['status']+_0x324bdc('0x11e1')+_0xad172f[_0x324bdc('0xe1b')]:'api.staff.save','msg':_0xad172f[_0x324bdc('0x25f4')]?JSON[_0x324bdc('0xbac')](_0xad172f[_0x324bdc('0x25f4')]['message']):_0xad172f[_0x324bdc('0x1586')]()});});}function _0x4fd4fc(_0x29a53e){const _0x2419ff=_0x173688;return _0x1e9337[_0x2419ff('0x557')][_0x2419ff('0x20eb')]({'id':_0x29a53e['id']})[_0x2419ff('0xa44')][_0x2419ff('0x1166')](function(_0x3b7dcd){const _0x58edfe=_0x2419ff;_0x130b6d[_0x58edfe('0x1f7e')][_0x29a53e['id']]&&_0x2cfb05()[_0x58edfe('0xcc3')](_0x130b6d[_0x58edfe('0x1f7e')][_0x29a53e['id']],_0x2cfb05()[_0x58edfe('0x1a08')](_0x3b7dcd,_0x3cf7ec)),_0x130b6d[_0x58edfe('0x24b7')][_0x29a53e['id']]&&_0x2cfb05()['merge'](_0x130b6d[_0x58edfe('0x24b7')][_0x29a53e['id']],_0x2cfb05()[_0x58edfe('0x1a08')](_0x3b7dcd,_0x3cf7ec)),_0x4c1d58(_0x130b6d[_0x58edfe('0x1f7e')][_0x29a53e['id']]);})['catch'](function(_0x3d3e85){const _0x4ec333=_0x2419ff;_0x2eb3ad[_0x4ec333('0xfc9')]({'title':_0x3d3e85[_0x4ec333('0x52d')]?'API:'+_0x3d3e85['status']+'\x20-\x20'+_0x3d3e85['statusText']:_0x4ec333('0x1e3c'),'msg':_0x3d3e85['data']?JSON[_0x4ec333('0xbac')](_0x3d3e85['data'][_0x4ec333('0x1e70')]):_0x3d3e85[_0x4ec333('0x1586')]()});});}function _0x543db6(_0x327f0b){const _0x2ab086=_0x173688;_0x191187[_0x2ab086('0x1f80')](_0x191187['alert']()[_0x2ab086('0x2339')](!![])['title'](_0x2ab086('0x58a'))[_0x2ab086('0xf3c')](_0x2ab086('0x1174'))['ok']('Ok')[_0x2ab086('0x203b')](_0x327f0b));}function _0x2facf5(_0x5cb009,_0x49d858){const _0x3c9bfa=_0x173688;_0x191187[_0x3c9bfa('0x1f80')]({'controller':'AgentqueueaddController','controllerAs':'vm','templateUrl':_0x49c5be,'parent':angular[_0x3c9bfa('0x1194')](_0x16490c[_0x3c9bfa('0x8d2')]),'targetEvent':_0x49d858,'clickOutsideToClose':!![],'locals':{'agent':_0x5cb009,'agents':[],'channel':_0x3c9bfa('0x1fc7'),'direction':_0x3c9bfa('0x14d8'),'crudPermissions':_0x130b6d[_0x3c9bfa('0x243c')]}});}function _0x3c7ac9(_0x1e9a8f){const _0x3c0144=_0x173688;return _0x1e9a8f===_0x3c0144('0x1e77')||_0x1e9a8f==='*pause';}function _0x2be910(_0x49a0d0){return _0x49a0d0==='pause';}function _0x15fc7a(_0x2dc92b){const _0x52dd10=_0x173688;return _0x2dc92b===_0x52dd10('0x6e8');}function _0x133570(_0x4ebe68){const _0x51e2de=_0x173688;return _0x4ebe68==='idle'||_0x4ebe68==='unknown'||_0x4ebe68===_0x51e2de('0x14dd')||_0x4ebe68===_0x51e2de('0x1628')||_0x2cfb05()['isNil'](_0x4ebe68);}function _0x58b21e(_0x5b0b8a,_0x3fcf3f){const _0x35c41f=_0x173688;if(_0x3fcf3f===_0x35c41f('0x21da')){if(_0x5b0b8a[_0x3fcf3f+_0x35c41f('0x28f6')]!=='idle')return _0x5b0b8a[_0x3fcf3f+_0x35c41f('0x28f6')];if(_0x5b0b8a[_0x3fcf3f+_0x35c41f('0x108')])return _0x5b0b8a[_0x3fcf3f+_0x35c41f('0x28f6')]=_0x35c41f('0x1e77'),_0x35c41f('0x1e77');return _0x35c41f('0xdb0');}else{if(_0x5b0b8a[_0x3fcf3f+'Pause'])return _0x5b0b8a[_0x3fcf3f+_0x35c41f('0x28f6')]=_0x35c41f('0x1e77'),_0x35c41f('0x1e77');return _0x5b0b8a[_0x3fcf3f+_0x35c41f('0x28f6')];}}function _0x4c1d58(_0x453069){const _0x43eadf=_0x173688;let _0xfcea2c=_0x43eadf('0x22d5');if(_0x2cfb05()[_0x43eadf('0x2285')]([_0x58b21e(_0x453069,_0x43eadf('0x21da')),_0x58b21e(_0x453069,_0x43eadf('0xde2')),_0x58b21e(_0x453069,_0x43eadf('0x1bfa')),_0x58b21e(_0x453069,_0x43eadf('0x26c')),_0x58b21e(_0x453069,_0x43eadf('0x146c')),_0x58b21e(_0x453069,_0x43eadf('0x116e')),_0x58b21e(_0x453069,_0x43eadf('0x1fc7'))],_0x3c7ac9))_0xfcea2c=_0x43eadf('0x1e77');else{if(_0x2cfb05()[_0x43eadf('0x1798')]([_0x58b21e(_0x453069,_0x43eadf('0x21da')),_0x58b21e(_0x453069,'chat'),_0x58b21e(_0x453069,'mail'),_0x58b21e(_0x453069,_0x43eadf('0x26c')),_0x58b21e(_0x453069,_0x43eadf('0x146c')),_0x58b21e(_0x453069,_0x43eadf('0x116e')),_0x58b21e(_0x453069,_0x43eadf('0x1fc7'))],_0x3c7ac9))_0xfcea2c=_0x43eadf('0x6e8');else _0x2cfb05()[_0x43eadf('0x2285')]([_0x58b21e(_0x453069,_0x43eadf('0x21da')),_0x58b21e(_0x453069,_0x43eadf('0xde2')),_0x58b21e(_0x453069,_0x43eadf('0x1bfa')),_0x58b21e(_0x453069,_0x43eadf('0x26c')),_0x58b21e(_0x453069,_0x43eadf('0x146c')),_0x58b21e(_0x453069,_0x43eadf('0x116e')),_0x58b21e(_0x453069,'fax')],_0x133570)?_0xfcea2c=_0x43eadf('0xdb0'):_0xfcea2c=_0x43eadf('0x2344');}_0x453069[_0x43eadf('0xe34')]!==_0xfcea2c&&(_0x453069[_0x43eadf('0xe34')]=_0xfcea2c,_0x453069[_0x43eadf('0x24d5')]?(_0x453069['init']=![],_0x453069[_0x43eadf('0x25b3')]=_0x3c7ac9(_0xfcea2c)?_0x2cfb05()[_0x43eadf('0xa53')](_0x24273b()(_0x453069[_0x43eadf('0x3dc')])[_0x43eadf('0x128a')]('x')):_0x2cfb05()['max']([_0x453069['voiceStatusTime'],_0x453069[_0x43eadf('0x1507')],_0x453069[_0x43eadf('0x1955')],_0x453069[_0x43eadf('0x2357')],_0x453069[_0x43eadf('0x11a8')],_0x453069[_0x43eadf('0x43e')],_0x453069[_0x43eadf('0x4f3')]])):_0x453069[_0x43eadf('0x25b3')]=_0x2cfb05()['toNumber'](_0x24273b()()[_0x43eadf('0x128a')]('x')));}function _0x2b8ce1(_0x10f03c){const _0xc3ab1e=_0x173688,_0x540b7e=_0x2cfb05()['startsWith'](_0x130b6d[_0xc3ab1e('0x2218')][_0xc3ab1e('0xa99')],'-')?_0xc3ab1e('0x1dc3'):_0xc3ab1e('0x17d');return _0x2cfb05()['orderBy'](_0x10f03c,[_0x130b6d[_0xc3ab1e('0x2218')][_0xc3ab1e('0xa99')][_0xc3ab1e('0xf3')]('-','')],[_0x540b7e]);}function _0x307a16(){const _0x5bd019=_0x173688;_0x21a197&&(_0x5c58a2[_0x5bd019('0x3f')](_0x21a197),_0x21a197=null);}function _0x8341ea(_0x13133a,_0x2d3cd8){const _0x173325=_0x173688;return _0x1e9337['user'][_0x173325('0x1449')]({'id':_0x13133a['id']},{'screenrecording':_0x2d3cd8})[_0x173325('0xa44')][_0x173325('0x1a80')](function(_0x4e3990){const _0x5ce46c=_0x173325;_0x2eb3ad[_0x5ce46c('0xfc9')]({'title':_0x4e3990[_0x5ce46c('0x52d')]?_0x5ce46c('0x1e21')+_0x4e3990[_0x5ce46c('0x52d')]+'\x20-\x20'+_0x4e3990[_0x5ce46c('0xe1b')]:_0x5ce46c('0x1103'),'msg':_0x4e3990['data']?JSON['stringify'](_0x4e3990[_0x5ce46c('0x25f4')][_0x5ce46c('0x1e70')]):_0x4e3990[_0x5ce46c('0x1586')]()});});}_0x4ffd87[_0x173688('0x3d2')](_0x173688('0x1c3f'),function(){const _0x4e09ec=_0x173688;_0x3a8cb1[_0x4e09ec('0x1800')](_0x4e09ec('0x26b2')),_0x3a8cb1[_0x4e09ec('0x1800')]('user:update'),_0x3a8cb1[_0x4e09ec('0x1800')]('user:agentconnect'),_0x3a8cb1[_0x4e09ec('0x1800')](_0x4e09ec('0x1c99')),_0x307a16();});}const _0x577a4f=_0x582eb8,_0x50858c=_0x2734b2['p']+'src/js/modules/main/apps/fax/views/faxQueues/edit/agentadd/agentadd.html/agentadd.html',_0x28b772=_0x2734b2['p']+'src/js/modules/main/apps/fax/views/faxQueues/create/dialog.html/dialog.html';_0x386b2f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$timeout','$mdDialog','$q',_0x36e6f4('0x1c90'),'$interval','queues','rpcQueues',_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x1d2e'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x386b2f(_0x5e6efa,_0x17b2e4,_0x5c482b,_0xde6dbf,_0x29ea16,_0x4a6b3c,_0x7faf94,_0x4e5939,_0x38adca,_0x100468,_0xe65811,_0x2631f5,_0x35bdaf,_0x1f9ee4){const _0x30d528=_0x36e6f4,_0x49dbcc=this,_0x1c9e4f=[_0x30d528('0x1570'),_0x30d528('0x44b'),_0x30d528('0x288a'),_0x30d528('0x46a'),_0x30d528('0x67d'),_0x30d528('0x20ab'),_0x30d528('0x1e70'),'dialActive',_0x30d528('0x20ae'),'Trunk','paused'];_0x49dbcc['currentUser']=_0x1f9ee4[_0x30d528('0x26cd')](),_0x49dbcc['count']=_0x7faf94['count']?_0x7faf94[_0x30d528('0x240f')]:0x0,_0x49dbcc['queues']=_0x7faf94?_0x2cfb05()[_0x30d528('0x155c')](_0x7faf94[_0x30d528('0x269a')]?_0x7faf94['rows']:[],'id'):{},_0x49dbcc['rpcQueues']=_0x4e5939?_0x2cfb05()[_0x30d528('0x155c')](_0x4e5939[_0x30d528('0x269a')]?_0x4e5939['rows']:[],'id'):{},_0x49dbcc[_0x30d528('0x7f')]=_0x2631f5,_0x49dbcc[_0x30d528('0x17aa')]=_0x35bdaf&&_0x35bdaf[_0x30d528('0x240f')]==0x1?_0x35bdaf[_0x30d528('0x269a')][0x0]:null,_0x49dbcc['crudPermissions']=_0x1f9ee4[_0x30d528('0xd87')](_0x49dbcc['userProfileSection']?_0x49dbcc[_0x30d528('0x17aa')][_0x30d528('0x243c')]:null);_0x1f9ee4[_0x30d528('0x1ac6')](_0x30d528('0xa7c'))?_0x49dbcc['query']={'type':_0x30d528('0x14d8'),'sort':_0x30d528('0x14dc'),'limit':0xa,'page':0x1}:_0x49dbcc[_0x30d528('0x2218')]={'id':_0x49dbcc[_0x30d528('0x98')]['id'],'channel':_0x30d528('0x1fc7'),'type':_0x30d528('0x14d8'),'sort':_0x30d528('0x14dc'),'limit':0xa,'page':0x1};_0x49dbcc['success']=_0x1cf324,_0x49dbcc['getQueues']=_0x33b573,_0x49dbcc['createOrEditFaxQueue']=_0x5a75d2,_0x49dbcc[_0x30d528('0x33f')]=_0x161912,_0x49dbcc[_0x30d528('0xeba')]=_0x2c99d7,_0x49dbcc[_0x30d528('0x1303')]=_0x373eef,_0x49dbcc[_0x30d528('0xfb')]=_0x534c10,_0x49dbcc[_0x30d528('0xfe9')]=_0xe5ef5a,_0x49dbcc[_0x30d528('0x212c')]=_0x4b5f73,_0x49dbcc[_0x30d528('0xb9a')]=_0x220dbf,_0x49dbcc[_0x30d528('0x1696')]=_0x108c56,_0x49dbcc['$onInit']=_0x4d9dd6,_0x49dbcc[_0x30d528('0xa99')]=[],_0x2cfb05()['forIn'](_0x49dbcc[_0x30d528('0x7a7')],function(_0x1905cb){const _0x4792da=_0x30d528;_0x49dbcc[_0x4792da('0xa99')][_0x4792da('0x1514')](_0x1905cb['id']);}),_0x100468['on']('fax_queue:save',_0x49dbcc[_0x30d528('0x1303')]),_0x100468['on']('userFaxQueue:save',_0x49dbcc[_0x30d528('0xfb')]),_0x100468['on'](_0x30d528('0x268b'),_0x49dbcc['onRemoveMember']),_0x100468['on']('user:update',_0x49dbcc[_0x30d528('0x212c')]),_0x100468['on'](_0x30d528('0x25f0'),_0x49dbcc[_0x30d528('0x1696')]),_0x100468['on']('userVoiceQueue:save',_0x49dbcc[_0x30d528('0xb9a')]);function _0x4d9dd6(){const _0x5b34a6=_0x30d528,_0x1d92bf=[];return _0x2cfb05()[_0x5b34a6('0x941')](_0x49dbcc['queues'],function(_0x373e9b,_0x65eaff){const _0x39028f=_0x5b34a6;_0x373e9b[_0x39028f('0x18b')]=0x0,_0x373e9b[_0x39028f('0x2689')]=0x0,_0x49dbcc[_0x39028f('0x7a7')][_0x65eaff][_0x39028f('0x1f7e')]={},_0x1d92bf[_0x39028f('0x1514')](_0x38adca[_0x39028f('0x1a5b')][_0x39028f('0x27d1')]({'id':_0x65eaff})['$promise']),_0x49dbcc[_0x39028f('0x744')][_0x65eaff]&&_0x2cfb05()[_0x39028f('0xcc3')](_0x373e9b,_0x2cfb05()['pick'](_0x49dbcc['rpcQueues'][_0x65eaff],_0x1c9e4f));}),_0xde6dbf['all'](_0x1d92bf)[_0x5b34a6('0x1166')](function(_0x62f963){const _0x209588=_0x5b34a6;for(let _0x2d5d88=0x0;_0x2d5d88<_0x62f963[_0x209588('0x264b')];_0x2d5d88+=0x1){for(let _0x4a2473=0x0;_0x4a2473<_0x62f963[_0x2d5d88][_0x209588('0x269a')]['length'];_0x4a2473++){_0x62f963[_0x2d5d88]['rows'][_0x4a2473][_0x209588('0x18b')]&&_0x49dbcc[_0x209588('0x7a7')][_0x62f963[_0x2d5d88][_0x209588('0x269a')][_0x4a2473]['FaxQueueId']]['paused']++,_0x49dbcc[_0x209588('0x7a7')][_0x62f963[_0x2d5d88][_0x209588('0x269a')][_0x4a2473][_0x209588('0x14e1')]][_0x209588('0x2689')]++,_0x49dbcc[_0x209588('0x7a7')][_0x62f963[_0x2d5d88][_0x209588('0x269a')][_0x4a2473][_0x209588('0x14e1')]]['agents'][_0x62f963[_0x2d5d88][_0x209588('0x269a')][_0x4a2473][_0x209588('0x122a')]]=_0x62f963[_0x2d5d88]['rows'][_0x4a2473][_0x209588('0x14e1')];}}})[_0x5b34a6('0x1a80')](function(_0x4aef1f){const _0x4d348f=_0x5b34a6;console[_0x4d348f('0xfc9')](_0x4aef1f);});}function _0x373eef(_0xc71465){const _0x3119db=_0x30d528;_0x49dbcc[_0x3119db('0x7a7')][_0xc71465['id']]&&_0x2cfb05()[_0x3119db('0xcc3')](_0x49dbcc[_0x3119db('0x7a7')][_0xc71465['id']],_0x2cfb05()[_0x3119db('0x1a08')](_0xc71465,_0x1c9e4f));}function _0x534c10(_0x375621){const _0x30e7ab=_0x30d528;_0x49dbcc[_0x30e7ab('0x7a7')][_0x375621[_0x30e7ab('0x14e1')]]&&_0x49dbcc['queues'][_0x375621[_0x30e7ab('0x14e1')]]['loggedInDb']++;}function _0xe5ef5a(_0x4cdf45){const _0x1696e0=_0x30d528;_0x49dbcc[_0x1696e0('0x7a7')][_0x4cdf45[_0x1696e0('0x14e1')]]&&_0x49dbcc[_0x1696e0('0x7a7')][_0x4cdf45[_0x1696e0('0x14e1')]][_0x1696e0('0x2689')]--;}function _0x4b5f73(_0x4e4d7a){const _0x1e85be=_0x30d528;console[_0x1e85be('0x455')](_0x1e85be('0x212c'),_0x4e4d7a);if(_0x4e4d7a[_0x1e85be('0x2540')])_0x2cfb05()[_0x1e85be('0x941')](_0x49dbcc[_0x1e85be('0x7a7')],function(_0x1e6053){const _0x3abc33=_0x1e85be;_0x1e6053[_0x3abc33('0x1f7e')][_0x4e4d7a['id']]&&(_0x1e6053[_0x3abc33('0x18b')]+=0x1,console[_0x3abc33('0x455')](_0x3abc33('0x1e77')));});else!_0x4e4d7a['voicePause']&&_0x2cfb05()['forIn'](_0x49dbcc[_0x1e85be('0x7a7')],function(_0x2cfc54){const _0x231be1=_0x1e85be;_0x2cfc54[_0x231be1('0x1f7e')][_0x4e4d7a['id']]&&(_0x2cfc54[_0x231be1('0x18b')]>0x0&&(_0x2cfc54['paused']-=0x1,console[_0x231be1('0x455')](_0x231be1('0x20eb'))));});}function _0x220dbf(_0x840bdf){const _0x11d4f8=_0x30d528;console[_0x11d4f8('0x455')](_0x11d4f8('0x26c1'),_0x840bdf),_0x49dbcc[_0x11d4f8('0x7a7')][_0x840bdf[_0x11d4f8('0x14e1')]]&&(_0x49dbcc['queues'][_0x840bdf['FaxQueueId']][_0x11d4f8('0x2689')]+=0x1,_0x49dbcc['queues'][_0x840bdf[_0x11d4f8('0x14e1')]]['agents'][_0x840bdf[_0x11d4f8('0x122a')]]=_0x840bdf[_0x11d4f8('0x14e1')]);}function _0x108c56(_0x68146c){const _0x37c6af=_0x30d528;console[_0x37c6af('0x455')](_0x37c6af('0x1696'),_0x68146c),_0x49dbcc[_0x37c6af('0x7a7')][_0x68146c[_0x37c6af('0x14e1')]]&&_0x49dbcc[_0x37c6af('0x7a7')][_0x68146c[_0x37c6af('0x14e1')]][_0x37c6af('0x2689')]>0x0&&(_0x49dbcc[_0x37c6af('0x7a7')][_0x68146c['FaxQueueId']][_0x37c6af('0x2689')]-=0x1,delete _0x49dbcc[_0x37c6af('0x7a7')][_0x68146c['FaxQueueId']][_0x37c6af('0x1f7e')][_0x68146c[_0x37c6af('0x122a')]]);}let _0x4650d7=!![],_0x27846e=0x1;_0x5e6efa['$watch'](_0x30d528('0x12d8'),function(_0x49e313,_0x27bf26){const _0x66d39e=_0x30d528;_0x4650d7?_0x17b2e4(function(){_0x4650d7=![];}):(!_0x27bf26&&(_0x27846e=_0x49dbcc[_0x66d39e('0x2218')][_0x66d39e('0x1a43')]),_0x49e313!==_0x27bf26&&(_0x49dbcc[_0x66d39e('0x2218')][_0x66d39e('0x1a43')]=0x1),!_0x49e313&&(_0x49dbcc[_0x66d39e('0x2218')]['page']=_0x27846e),_0x49dbcc[_0x66d39e('0x152a')]());});function _0x1cf324(_0x2ded19){const _0x266d4b=_0x30d528;_0x49dbcc[_0x266d4b('0x240f')]=_0x2ded19[_0x266d4b('0x240f')],_0x49dbcc[_0x266d4b('0x7a7')]=_0x2ded19?_0x2cfb05()['keyBy'](_0x2ded19[_0x266d4b('0x269a')]?_0x2ded19[_0x266d4b('0x269a')]:[],'id'):{};if(_0x2ded19[_0x266d4b('0x269a')]){_0x49dbcc[_0x266d4b('0xa99')]=[];for(let _0xecab8d=0x0;_0xecab8d<_0x2ded19[_0x266d4b('0x269a')][_0x266d4b('0x264b')];_0xecab8d++){_0x49dbcc['order'][_0x266d4b('0x1514')](_0x2ded19['rows'][_0xecab8d]['id']);}}_0x4d9dd6();}function _0x33b573(){const _0x2c13bb=_0x30d528;_0x49dbcc['query'][_0x2c13bb('0x1098')]=(_0x49dbcc[_0x2c13bb('0x2218')]['page']-0x1)*_0x49dbcc[_0x2c13bb('0x2218')]['limit'],_0x1f9ee4['hasRole'](_0x2c13bb('0xa7c'))?_0x49dbcc[_0x2c13bb('0x1f48')]=_0x38adca[_0x2c13bb('0x1a5b')][_0x2c13bb('0xd83')](_0x49dbcc['query'],_0x1cf324)['$promise']:(_0x49dbcc[_0x2c13bb('0x2218')]['id']=_0x49dbcc[_0x2c13bb('0x7f')]['id'],_0x49dbcc[_0x2c13bb('0x2218')][_0x2c13bb('0xe60')]=_0x2c13bb('0x1e54'),_0x49dbcc[_0x2c13bb('0x1f48')]=_0x38adca[_0x2c13bb('0x7f')][_0x2c13bb('0x263a')](_0x49dbcc[_0x2c13bb('0x2218')],_0x1cf324)[_0x2c13bb('0xa44')]);}function _0x5a75d2(_0x1022a2,_0x634176){const _0x5e00ac=_0x30d528;_0x5c482b[_0x5e00ac('0x1f80')]({'controller':_0x5e00ac('0xd95'),'controllerAs':'vm','templateUrl':_0x28b772,'parent':angular[_0x5e00ac('0x1194')](_0x29ea16[_0x5e00ac('0x8d2')]),'targetEvent':_0x1022a2,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x634176,'faxQueues':_0x2cfb05()['values'](_0x49dbcc[_0x5e00ac('0x7a7')]),'license':null,'setting':null,'crudPermissions':_0x49dbcc[_0x5e00ac('0x243c')]}});}function _0x161912(_0x39332d,_0x58d427){const _0x415ee2=_0x30d528;_0x5c482b[_0x415ee2('0x1f80')]({'controller':'FaxQueueagentaddController','controllerAs':'vm','templateUrl':_0x50858c,'parent':angular[_0x415ee2('0x1194')](_0x29ea16[_0x415ee2('0x8d2')]),'targetEvent':_0x39332d,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x58d427,'faxQueues':_0x49dbcc[_0x415ee2('0x7a7')]?_0x49dbcc[_0x415ee2('0x7a7')][_0x415ee2('0x269a')]:[],'realtime':![],'crudPermissions':_0x49dbcc[_0x415ee2('0x243c')]}});}function _0x2c99d7(_0x5cd6b7){const _0x21a8ec=_0x30d528;return _0x38adca[_0x21a8ec('0x1a5b')][_0x21a8ec('0x1449')](_0x5cd6b7)[_0x21a8ec('0xa44')][_0x21a8ec('0x1166')](function(){const _0x294a83=_0x21a8ec;_0xe65811[_0x294a83('0x103b')]({'title':'Queue\x20properly\x20updated!','msg':_0x5cd6b7[_0x294a83('0x4f0')]?_0x5cd6b7[_0x294a83('0x4f0')]+_0x294a83('0xa17'):''});})['catch'](function(_0x20121e){const _0x59bcc5=_0x21a8ec;_0xe65811[_0x59bcc5('0xfc9')]({'title':_0x59bcc5('0xa98'),'msg':_0x20121e[_0x59bcc5('0x1e70')]});});}_0x5e6efa[_0x30d528('0x3d2')](_0x30d528('0x1c3f'),function(){const _0x233616=_0x30d528;_0x100468['removeAllListeners'](_0x233616('0x2241')),_0x100468['removeAllListeners']('userFaxQueue:remove'),_0x100468[_0x233616('0x1800')](_0x233616('0x169d')),_0x100468[_0x233616('0x1800')]('user:update'),_0x100468[_0x233616('0x1800')](_0x233616('0x25f0')),_0x100468[_0x233616('0x1800')]('userVoiceQueue:save');});}const _0x49ee0b=_0x386b2f;function _0x1958d9(){const _0x340a4c=_0x36e6f4;return{'status':{'registered':_0x340a4c('0x23ca'),'unregistered':_0x340a4c('0x278f'),'lagged':_0x340a4c('0x278f'),'reachable':_0x340a4c('0x23ca'),'unreachable':_0x340a4c('0x278f'),'unknown':_0x340a4c('0x2125')},'state':{'unknown':_0x340a4c('0x1d48'),'not_inuse':'green-300-fg\x20icon-phone-hangup','inuse':'red-300-fg\x20icon-phone-in-talk','busy':'red-300-fg\x20icon-phone-locked','invalid':_0x340a4c('0x1d48'),'unavailable':'grey-fg\x20icon-phone-hangup','ringing':_0x340a4c('0x132c'),'ringinuse':_0x340a4c('0x132c'),'onhold':'blue-300-fg\x20icon-phone-paused'},'channelStatus':{'ring':_0x340a4c('0x132c'),'up':'green-300-fg\x20icon-phone-in-talk','hangup':_0x340a4c('0x9e3')},'channelStatusOut':{'ring':'blue-300-fg\x20icon-phone-outgoing','up':_0x340a4c('0x20b2'),'hangup':'red-300-fg\x20icon-phone-hangup'}};}const _0x10f388=_0x1958d9;_0x2c9100[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x2661')];function _0x2c9100(_0xb0f07d,_0x3be0e4,_0x531d69){const _0x939bca=_0x36e6f4,_0x2f1475=this;_0x531d69[_0x939bca('0x670')](),_0x531d69[_0x939bca('0x7bb')](),_0x2f1475['selectedTab']=0x0;switch(_0x3be0e4['current'][_0x939bca('0x4f0')]){case'app.fax.realtime.agents':_0x2f1475[_0x939bca('0x2669')]=0x0;break;case _0x939bca('0xda6'):_0x2f1475[_0x939bca('0x2669')]=0x1;break;case'app.fax.realtime.queues':_0x2f1475[_0x939bca('0x2669')]=0x2;break;case _0x939bca('0x2765'):_0x2f1475[_0x939bca('0x2669')]=0x3;break;default:_0x2f1475[_0x939bca('0x2669')]=0x0,_0x3be0e4['go'](_0x939bca('0x113f'));}_0xb0f07d['$watch'](_0x939bca('0x27a7'),function(_0x1338dc,_0x351943){const _0x9bec12=_0x939bca;if(_0x1338dc!==_0x351943)switch(_0x1338dc){case 0x0:_0x3be0e4['go'](_0x9bec12('0x113f'));break;case 0x1:_0x3be0e4['go']('app.fax.realtime.trunks');break;case 0x2:_0x3be0e4['go'](_0x9bec12('0x9e9'));break;case 0x3:_0x3be0e4['go'](_0x9bec12('0x2765'));break;default:_0x3be0e4['go'](_0x9bec12('0x113f'));}});}const _0xa109cb=_0x2c9100;_0x217a5e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0xf24'),'rpcTrunks','api','socket',_0x36e6f4('0x1a02'),_0x36e6f4('0x7b9'),_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x21ef')];function _0x217a5e(_0x5522e8,_0x33fc54,_0x4a691b,_0x5d3916,_0x2c76d9,_0x4cf4e8,_0xc04a1c,_0x422aef,_0x3d9877,_0x4203ec,_0x2454ec,_0x1c9d42){const _0x3e2ad5=_0x36e6f4,_0x84aae5=this,_0x36537f=[_0x3e2ad5('0x52d'),_0x3e2ad5('0x1b1a'),_0x3e2ad5('0x942'),_0x3e2ad5('0x1690'),_0x3e2ad5('0x93d'),_0x3e2ad5('0x1eef'),_0x3e2ad5('0x63f'),'status'];_0x84aae5[_0x3e2ad5('0x98')]=_0x1c9d42['getCurrentUser'](),_0x84aae5[_0x3e2ad5('0x240f')]=_0x5d3916[_0x3e2ad5('0x240f')],_0x84aae5[_0x3e2ad5('0xf24')]=_0x5d3916?_0x5d3916['rows']:[],_0x84aae5[_0x3e2ad5('0x24e3')]=_0x2c76d9?_0x2c76d9[_0x3e2ad5('0x269a')]?_0x2c76d9[_0x3e2ad5('0x269a')]:[]:[],_0x84aae5['query']={'fields':'id,name','active':!![],'sort':_0x3e2ad5('0x14dc'),'limit':0xa,'page':0x1},_0x84aae5[_0x3e2ad5('0x15a8')]=_0x422aef[_0x3e2ad5('0x52d')],_0x84aae5[_0x3e2ad5('0x1b31')]=_0x422aef[_0x3e2ad5('0x63f')],_0x84aae5[_0x3e2ad5('0x7f')]=_0x4203ec,_0x84aae5[_0x3e2ad5('0x17aa')]=_0x2454ec&&_0x2454ec['count']==0x1?_0x2454ec[_0x3e2ad5('0x269a')][0x0]:null,_0x84aae5['crudPermissions']=_0x1c9d42['parseCrudPermissions'](_0x84aae5[_0x3e2ad5('0x17aa')]?_0x84aae5[_0x3e2ad5('0x17aa')]['crudPermissions']:null),_0x84aae5[_0x3e2ad5('0x103b')]=_0x1adefe,_0x84aae5['$onInit']=_0x26b88d,_0x84aae5['showInfo']=_0x189619,_0x84aae5[_0x3e2ad5('0x58')]=_0x4b54ef,_0x84aae5[_0x3e2ad5('0x22a2')]=_0x143ef8,_0x84aae5[_0x3e2ad5('0x1303')]=_0x3483ed,_0xc04a1c['on']('trunk:save',_0x84aae5['onSave']);function _0x26b88d(){const _0x41d240=_0x3e2ad5;let _0x1768ca;for(let _0x44444d=0x0;_0x44444d<_0x84aae5[_0x41d240('0xf24')]['length'];_0x44444d+=0x1){_0x1768ca=_0x2cfb05()[_0x41d240('0xede')](_0x84aae5[_0x41d240('0x24e3')],['id',_0x84aae5[_0x41d240('0xf24')][_0x44444d]['id']]),_0x1768ca>=0x0&&_0x2cfb05()['merge'](_0x84aae5[_0x41d240('0xf24')][_0x44444d],_0x2cfb05()[_0x41d240('0x1a08')](_0x84aae5[_0x41d240('0x24e3')][_0x1768ca],_0x36537f));}}function _0x189619(_0x517fd8){const _0x19a8f8=_0x3e2ad5;_0x4a691b[_0x19a8f8('0x1f80')](_0x4a691b[_0x19a8f8('0x31d')]()[_0x19a8f8('0x2339')](!![])[_0x19a8f8('0xcdc')](_0x19a8f8('0x58a'))[_0x19a8f8('0xf3c')](_0x19a8f8('0x1174'))['ok']('Ok')[_0x19a8f8('0x203b')](_0x517fd8));}function _0x145ee0(_0x321fa5,_0x5ec1b0,_0x226385){const _0x130581=_0x3e2ad5;_0x5ec1b0>=0x0&&_0x2cfb05()[_0x130581('0xcc3')](_0x321fa5[_0x5ec1b0],_0x2cfb05()[_0x130581('0x1a08')](_0x226385,_0x36537f));}function _0x3483ed(_0x1cd310){const _0x3b1061=_0x3e2ad5,_0x3af83f=_0x2cfb05()[_0x3b1061('0xede')](_0x84aae5[_0x3b1061('0xf24')],['id',_0x1cd310['id']]),_0xb36bd4=_0x2cfb05()[_0x3b1061('0xede')](_0x84aae5[_0x3b1061('0x24e3')],['id',_0x1cd310['id']]);_0x145ee0(_0x84aae5['trunks'],_0x3af83f,_0x1cd310),_0x145ee0(_0x84aae5[_0x3b1061('0x24e3')],_0xb36bd4,_0x1cd310);}let _0x47f3d5=!![],_0x1a0d39=0x1;_0x5522e8[_0x3e2ad5('0xe83')]('vm.query.filter',function(_0x3f8647,_0x37d9a8){const _0x19e465=_0x3e2ad5;_0x47f3d5?_0x33fc54(function(){_0x47f3d5=![];}):(!_0x37d9a8&&(_0x1a0d39=_0x84aae5[_0x19e465('0x2218')][_0x19e465('0x1a43')]),_0x3f8647!==_0x37d9a8&&(_0x84aae5['query'][_0x19e465('0x1a43')]=0x1),!_0x3f8647&&(_0x84aae5['query'][_0x19e465('0x1a43')]=_0x1a0d39),_0x84aae5['getTrunks']());});function _0x1adefe(_0x477709){const _0xcb7a54=_0x3e2ad5;_0x84aae5['count']=_0x477709[_0xcb7a54('0x240f')],_0x84aae5[_0xcb7a54('0xf24')]=_0x477709?_0x477709[_0xcb7a54('0x269a')]?_0x477709[_0xcb7a54('0x269a')]:[]:[],_0x26b88d();}function _0x4b54ef(){const _0x4532bc=_0x3e2ad5;_0x84aae5[_0x4532bc('0x2218')][_0x4532bc('0x1098')]=(_0x84aae5[_0x4532bc('0x2218')][_0x4532bc('0x1a43')]-0x1)*_0x84aae5['query'][_0x4532bc('0x163f')],_0x1c9d42['hasRole'](_0x4532bc('0xa7c'))?_0x84aae5[_0x4532bc('0x1f48')]=_0x4cf4e8['trunk'][_0x4532bc('0xd83')](_0x84aae5['query'],_0x1adefe)[_0x4532bc('0xa44')]:(_0x84aae5[_0x4532bc('0x2218')]['id']=_0x84aae5[_0x4532bc('0x7f')]['id'],_0x84aae5[_0x4532bc('0x2218')][_0x4532bc('0xe60')]=_0x4532bc('0x2685'),_0x84aae5['promise']=_0x4cf4e8[_0x4532bc('0x7f')][_0x4532bc('0x263a')](_0x84aae5['query'],_0x1adefe)[_0x4532bc('0xa44')]);}_0x5522e8[_0x3e2ad5('0x3d2')]('$destroy',function(){const _0x2a99cb=_0x3e2ad5;_0xc04a1c[_0x2a99cb('0x1800')](_0x2a99cb('0x2240'));});function _0x143ef8(_0x5744cc,_0x19f5f5){const _0x123626=_0x3e2ad5;_0x3d9877['go'](_0x123626('0x1f20'),{'id':_0x19f5f5['id']});}}const _0x120bb4=_0x217a5e;_0x1c5d85[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x1c5d85(_0x37156d){const _0x254944=_0x36e6f4;_0x37156d[_0x254944('0x63f')](_0x254944('0x1051'),{'url':_0x254944('0x1c2e'),'views':{'content@app':{'templateUrl':_0x44e6f1,'controller':'FaxRealtimeController\x20as\x20vm'}},'resolve':{'userProfile':[_0x254944('0x1fbc'),'Auth',function(_0x479ca6,_0xdf1206){const _0xc7c8d8=_0x254944;return _0xdf1206[_0xc7c8d8('0x1ac6')](_0xc7c8d8('0xa7c'))?null:_0x479ca6[_0xc7c8d8('0x18af')](_0xc7c8d8('0x697'),{'fields':_0xc7c8d8('0x686'),'id':_0xdf1206[_0xc7c8d8('0x26cd')]()[_0xc7c8d8('0xb86')]});}],'userProfileSection':['apiResolver',_0x254944('0x21ef'),function(_0x8fff39,_0x1b5b9c){const _0x503f23=_0x254944;return _0x1b5b9c[_0x503f23('0x1ac6')](_0x503f23('0xa7c'))?null:_0x8fff39[_0x503f23('0x18af')](_0x503f23('0xaf'),{'fields':_0x503f23('0xe26'),'userProfileId':_0x1b5b9c[_0x503f23('0x26cd')]()[_0x503f23('0xb86')],'sectionId':0x38e});}]},'authenticate':!![],'permissionId':0x38e})[_0x254944('0x63f')](_0x254944('0x113f'),{'url':_0x254944('0x730'),'controller':'AgentsFaxRealtimeController\x20as\x20vm','templateUrl':_0x3e81a2,'resolve':{'pauses':[_0x254944('0x1fbc'),function(_0x4f4ec6){const _0x58baa2=_0x254944;return _0x4f4ec6[_0x58baa2('0x18af')](_0x58baa2('0x737'),{'nolimit':!![]});}],'agents':[_0x254944('0x1fbc'),'Auth',function(_0x3fde6a,_0x238e10){const _0x3ef96a=_0x254944;return _0x238e10['hasRole']('admin')?_0x3fde6a['resolve']('user@get',{'fields':_0x3ef96a('0x1746'),'role':'agent','sort':_0x3ef96a('0x6e1'),'nolimit':!![]}):_0x3fde6a[_0x3ef96a('0x18af')](_0x3ef96a('0x17c4'),{'id':_0x238e10['getCurrentUser']()[_0x3ef96a('0xb86')],'section':_0x3ef96a('0x2391'),'fields':_0x3ef96a('0x1746'),'role':'agent','sort':'fullname','nolimit':!![]});}],'userProfile':[_0x254944('0x1fbc'),_0x254944('0x21ef'),function(_0x33067f,_0x2f6483){const _0x3292cc=_0x254944;return _0x2f6483[_0x3292cc('0x1ac6')](_0x3292cc('0xa7c'))?null:_0x33067f['resolve']('userProfile@get',{'fields':_0x3292cc('0x686'),'id':_0x2f6483['getCurrentUser']()[_0x3292cc('0xb86')]});}],'userProfileSection':[_0x254944('0x1fbc'),'Auth',function(_0x37d1c5,_0x578396){const _0x510e35=_0x254944;return _0x578396[_0x510e35('0x1ac6')]('admin')?null:_0x37d1c5[_0x510e35('0x18af')](_0x510e35('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x578396[_0x510e35('0x26cd')]()[_0x510e35('0xb86')],'sectionId':0xca});}],'rpcAgents':['apiResolver',function(_0x5cb613){const _0x26e398=_0x254944;return _0x5cb613[_0x26e398('0x18af')](_0x26e398('0xfab'));}]},'authenticate':!![],'permissionId':0x38e})[_0x254944('0x63f')](_0x254944('0xda6'),{'url':_0x254944('0x1994'),'controller':_0x254944('0xa8'),'templateUrl':_0x4d3a13,'resolve':{'trunks':[_0x254944('0x1fbc'),_0x254944('0x21ef'),function(_0x2ac9ba,_0x5efada){const _0x1894d4=_0x254944;return _0x5efada[_0x1894d4('0x1ac6')](_0x1894d4('0xa7c'))?_0x2ac9ba[_0x1894d4('0x18af')]('trunk@get',{'fields':'id,name','active':!![],'sort':_0x1894d4('0x14dc'),'limit':0xa,'offset':0x0}):_0x2ac9ba[_0x1894d4('0x18af')]('userProfile@getResources',{'id':_0x5efada[_0x1894d4('0x26cd')]()['userProfileId'],'section':_0x1894d4('0x2685'),'fields':'id,name','active':!![],'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':[_0x254944('0x1fbc'),_0x254944('0x21ef'),function(_0x484843,_0x37b6fd){const _0x3b656d=_0x254944;return _0x37b6fd[_0x3b656d('0x1ac6')]('admin')?null:_0x484843[_0x3b656d('0x18af')](_0x3b656d('0x697'),{'fields':'id,name,crudPermissions','id':_0x37b6fd['getCurrentUser']()[_0x3b656d('0xb86')]});}],'userProfileSection':[_0x254944('0x1fbc'),_0x254944('0x21ef'),function(_0x36cb9b,_0x20233f){const _0x58fe12=_0x254944;return _0x20233f[_0x58fe12('0x1ac6')]('admin')?null:_0x36cb9b[_0x58fe12('0x18af')](_0x58fe12('0xaf'),{'fields':_0x58fe12('0xe26'),'userProfileId':_0x20233f[_0x58fe12('0x26cd')]()[_0x58fe12('0xb86')],'sectionId':0x3f3});}],'rpcTrunks':['apiResolver',function(_0x4c255c){const _0x4159e1=_0x254944;return _0x4c255c[_0x4159e1('0x18af')]('rpc@getTrunks');}]},'authenticate':!![],'permissionId':0x38e})['state'](_0x254944('0x9e9'),{'url':_0x254944('0x1bd2'),'controller':_0x254944('0x2428'),'templateUrl':_0x3054c2,'resolve':{'queues':[_0x254944('0x1fbc'),_0x254944('0x21ef'),function(_0x48f551,_0x426e61){const _0x29b286=_0x254944;return _0x426e61[_0x29b286('0x1ac6')]('admin')?_0x48f551[_0x29b286('0x18af')]('faxQueue@get',{'type':_0x29b286('0x14d8'),'sort':_0x29b286('0x14dc'),'limit':0xa,'offset':0x0}):_0x48f551['resolve'](_0x29b286('0x17c4'),{'id':_0x426e61[_0x29b286('0x26cd')]()['userProfileId'],'section':_0x29b286('0x1e54'),'channel':_0x29b286('0x1fc7'),'type':'inbound','sort':_0x29b286('0x14dc'),'limit':0xa,'page':0x1});}],'userProfile':[_0x254944('0x1fbc'),_0x254944('0x21ef'),function(_0x112669,_0x3b0d65){const _0x8f242f=_0x254944;return _0x3b0d65[_0x8f242f('0x1ac6')](_0x8f242f('0xa7c'))?null:_0x112669[_0x8f242f('0x18af')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x3b0d65[_0x8f242f('0x26cd')]()[_0x8f242f('0xb86')]});}],'userProfileSection':[_0x254944('0x1fbc'),_0x254944('0x21ef'),function(_0x47fc4f,_0x175176){const _0x7560df=_0x254944;return _0x175176[_0x7560df('0x1ac6')]('admin')?null:_0x47fc4f[_0x7560df('0x18af')](_0x7560df('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x175176[_0x7560df('0x26cd')]()[_0x7560df('0xb86')],'sectionId':0x385});}],'rpcQueues':[_0x254944('0x1fbc'),function(_0x1322fb){const _0x1eee05=_0x254944;return _0x1322fb[_0x1eee05('0x18af')](_0x1eee05('0x13ed'));}]},'authenticate':!![],'permissionId':0x38e})[_0x254944('0x63f')](_0x254944('0x2765'),{'url':_0x254944('0x4c5'),'controller':_0x254944('0x284d'),'templateUrl':_0x216b0c,'resolve':{'faxAccounts':['apiResolver',_0x254944('0x21ef'),function(_0x155d3a,_0x333b2a){const _0x23b5a1=_0x254944;return _0x333b2a['hasRole'](_0x23b5a1('0xa7c'))?_0x155d3a[_0x23b5a1('0x18af')](_0x23b5a1('0x217d'),{'sort':_0x23b5a1('0x14dc'),'limit':0xa,'offset':0x0}):_0x155d3a[_0x23b5a1('0x18af')](_0x23b5a1('0x17c4'),{'id':_0x333b2a[_0x23b5a1('0x26cd')]()[_0x23b5a1('0xb86')],'section':_0x23b5a1('0x1c3b'),'sort':_0x23b5a1('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x254944('0x1fbc'),_0x254944('0x21ef'),function(_0x307bde,_0x181f95){const _0x5ddeb6=_0x254944;return _0x181f95[_0x5ddeb6('0x1ac6')](_0x5ddeb6('0xa7c'))?null:_0x307bde[_0x5ddeb6('0x18af')]('userProfile@get',{'fields':_0x5ddeb6('0x686'),'id':_0x181f95[_0x5ddeb6('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x254944('0x1fbc'),'Auth',function(_0x1261e4,_0x5568b2){const _0x320ddb=_0x254944;return _0x5568b2[_0x320ddb('0x1ac6')](_0x320ddb('0xa7c'))?null:_0x1261e4[_0x320ddb('0x18af')](_0x320ddb('0xaf'),{'fields':_0x320ddb('0xe26'),'userProfileId':_0x5568b2[_0x320ddb('0x26cd')]()[_0x320ddb('0xb86')],'sectionId':0x386});}],'rpcFaxAccounts':[_0x254944('0x1fbc'),function(_0x136941){const _0x8004ac=_0x254944;return _0x136941['resolve'](_0x8004ac('0x20f6'));}]},'authenticate':!![],'permissionId':0x38e});}angular['module'](_0x36e6f4('0x1051'),[])[_0x36e6f4('0xe11')](_0x1c5d85)[_0x36e6f4('0x75e')](_0x36e6f4('0x139f'),_0x589d71)['controller']('AgentsFaxRealtimeController',_0x577a4f)[_0x36e6f4('0x75e')](_0x36e6f4('0x4cc'),_0x49ee0b)[_0x36e6f4('0x87c')](_0x36e6f4('0x1a02'),_0x10f388)['controller'](_0x36e6f4('0x1063'),_0xa109cb)[_0x36e6f4('0x75e')]('TrunksFaxRealtimeController',_0x120bb4),_0x55044e[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),'faxAccounts',_0x36e6f4('0x2085'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license','setting',_0x36e6f4('0x243c')];function _0x55044e(_0x17219e,_0x37071c,_0x4032c1,_0x31431b,_0x34708d,_0x50163a,_0x8dab49,_0x51ea25,_0x3ec67e,_0x5136cf,_0x3b648a,_0xfd100,_0x5d4e66,_0x32e7de){const _0x4d7cb8=_0x36e6f4,_0x4595aa=this;_0x4595aa[_0x4d7cb8('0x98')]=_0x3b648a['getCurrentUser'](),_0x4595aa[_0x4d7cb8('0x61a')]=[],_0x4595aa[_0x4d7cb8('0xf8a')]=_0x5d4e66,_0x4595aa[_0x4d7cb8('0x5c9')]=_0xfd100,_0x4595aa['crudPermissions']=_0x32e7de,_0x4595aa[_0x4d7cb8('0x128b')]={},_0x4595aa[_0x4d7cb8('0x2900')]=_0x4595aa[_0x4d7cb8('0xf8a')]&&_0x4595aa[_0x4d7cb8('0xf8a')][_0x4d7cb8('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4595aa['title']='FAX.EDIT_FAXACCOUNT',_0x4595aa[_0x4d7cb8('0x2085')]=angular[_0x4d7cb8('0x225f')](_0x3ec67e),_0x4595aa['faxAccounts']=_0x51ea25,_0x4595aa[_0x4d7cb8('0x10a6')]=![];!_0x4595aa[_0x4d7cb8('0x2085')]&&(_0x4595aa[_0x4d7cb8('0x2085')]={'waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0x4595aa[_0x4d7cb8('0xcdc')]=_0x4d7cb8('0x1df1'),_0x4595aa[_0x4d7cb8('0x10a6')]=!![]);_0x37071c[_0x4d7cb8('0x23f')]['id']&&(_0x4595aa[_0x4d7cb8('0x2085')][_0x4d7cb8('0x18fe')]=_0x37071c[_0x4d7cb8('0x23f')]['id']);_0x4595aa['addNewFaxAccount']=_0x3dc793,_0x4595aa[_0x4d7cb8('0x19fa')]=_0x893ba8,_0x4595aa['deleteFaxAccount']=_0x3a28f6,_0x4595aa['getDateFromString']=_0x53cba2,_0x4595aa['closeDialog']=_0x4e7363,_0x3b648a['hasRole']('admin')?_0x5136cf['trunk'][_0x4d7cb8('0xd83')]({'fields':_0x4d7cb8('0x1776'),'sort':_0x4d7cb8('0x4f0')})[_0x4d7cb8('0xa44')][_0x4d7cb8('0x1166')](function(_0x10fa18){const _0x193929=_0x4d7cb8;_0x4595aa[_0x193929('0xf24')]=_0x10fa18[_0x193929('0x269a')]||[];})[_0x4d7cb8('0x1a80')](function(_0x26cd68){const _0x2c5b61=_0x4d7cb8;_0x8dab49[_0x2c5b61('0xfc9')]({'title':_0x26cd68[_0x2c5b61('0x52d')]?_0x2c5b61('0x1e21')+_0x26cd68[_0x2c5b61('0x52d')]+'\x20-\x20'+_0x26cd68[_0x2c5b61('0xe1b')]:_0x2c5b61('0x12a6'),'msg':_0x26cd68[_0x2c5b61('0x25f4')]?JSON[_0x2c5b61('0xbac')](_0x26cd68[_0x2c5b61('0x25f4')]):_0x26cd68[_0x2c5b61('0x1586')]()});}):_0x5136cf['trunk'][_0x4d7cb8('0xd83')]({'fields':_0x4d7cb8('0x1776'),'sort':_0x4d7cb8('0x4f0')})['$promise'][_0x4d7cb8('0x1166')](function(_0x3cb978){const _0x144316=_0x4d7cb8;_0x4595aa[_0x144316('0xf24')]=_0x3cb978['rows']||[];})[_0x4d7cb8('0x1166')](function(){const _0x3b2b26=_0x4d7cb8;return _0x5136cf[_0x3b2b26('0x17aa')][_0x3b2b26('0xd83')]({'userProfileId':_0x4595aa[_0x3b2b26('0x98')][_0x3b2b26('0xb86')],'sectionId':0x3f3})[_0x3b2b26('0xa44')];})['then'](function(_0x230b71){const _0x5070a6=_0x4d7cb8,_0x2f627b=_0x230b71&&_0x230b71[_0x5070a6('0x269a')]?_0x230b71[_0x5070a6('0x269a')][0x0]:null;if(!_0x2f627b){const _0x45170b=[];let _0x1f65e4=null;_0x4595aa[_0x5070a6('0x2085')]&&(_0x1f65e4=_0x2cfb05()[_0x5070a6('0xc38')](_0x4595aa[_0x5070a6('0xf24')],{'id':Number(_0x4595aa[_0x5070a6('0x2085')][_0x5070a6('0x1ce4')])}));for(let _0x3dfb7c=0x0;_0x3dfb7c<_0x4595aa[_0x5070a6('0xf24')][_0x5070a6('0x264b')];_0x3dfb7c++){_0x1f65e4&&_0x4595aa['trunks'][_0x3dfb7c]['id']===_0x1f65e4['id']&&(_0x4595aa['trunks'][_0x3dfb7c]['canSelect']=![],_0x45170b[_0x5070a6('0x1514')](_0x4595aa[_0x5070a6('0xf24')][_0x3dfb7c]));}_0x4595aa[_0x5070a6('0xf24')]=_0x45170b;}else{if(!_0x2f627b[_0x5070a6('0x1a2b')])return _0x5136cf[_0x5070a6('0x4b5')][_0x5070a6('0xd83')]({'sectionId':_0x2f627b['id']})['$promise']['then'](function(_0x530f20){const _0x110f84=_0x5070a6,_0x497ede=_0x2cfb05()[_0x110f84('0x2563')](_0x530f20[_0x110f84('0x269a')],function(_0x7adf2f){return _0x2cfb05()['find'](_0x4595aa['trunks'],{'id':_0x7adf2f['resourceId']});});let _0x5d81b6=null;_0x4595aa[_0x110f84('0x2085')]&&(_0x5d81b6=_0x2cfb05()['find'](_0x4595aa['trunks'],{'id':Number(_0x4595aa[_0x110f84('0x2085')][_0x110f84('0x1ce4')])}));if(_0x5d81b6&&!_0x2cfb05()[_0x110f84('0x1798')](_0x497ede,['id',_0x5d81b6['id']])){const _0xd0e666=_0x2cfb05()[_0x110f84('0xc38')](_0x4595aa[_0x110f84('0xf24')],{'id':_0x5d81b6['id']});_0xd0e666[_0x110f84('0x2378')]=![],_0x497ede[_0x110f84('0x1514')](_0xd0e666);}_0x4595aa[_0x110f84('0xf24')]=_0x497ede;});}})['catch'](function(_0x37068c){const _0x25a945=_0x4d7cb8;_0x8dab49[_0x25a945('0xfc9')]({'title':_0x37068c[_0x25a945('0x52d')]?_0x25a945('0x1e21')+_0x37068c[_0x25a945('0x52d')]+_0x25a945('0x11e1')+_0x37068c[_0x25a945('0xe1b')]:'SYSTEM:GETtrunks','msg':_0x37068c[_0x25a945('0x25f4')]?JSON[_0x25a945('0xbac')](_0x37068c['data']):_0x37068c[_0x25a945('0x1586')]()});}),_0x3b648a['hasRole'](_0x4d7cb8('0xa7c'))?_0x5136cf[_0x4d7cb8('0xdd9')][_0x4d7cb8('0xd83')]({'fields':'id,name','sort':'name'})[_0x4d7cb8('0xa44')][_0x4d7cb8('0x1166')](function(_0x358819){const _0x1e4f2c=_0x4d7cb8;_0x4595aa['lists']=_0x358819[_0x1e4f2c('0x269a')]||[];})[_0x4d7cb8('0x1a80')](function(_0x19f505){const _0x3ea235=_0x4d7cb8;_0x8dab49['error']({'title':_0x19f505['status']?_0x3ea235('0x1e21')+_0x19f505[_0x3ea235('0x52d')]+'\x20-\x20'+_0x19f505[_0x3ea235('0xe1b')]:'SYSTEM:GET_LISTS','msg':_0x19f505['data']?JSON['stringify'](_0x19f505[_0x3ea235('0x25f4')]):_0x19f505[_0x3ea235('0x1586')]()});}):_0x5136cf[_0x4d7cb8('0xdd9')][_0x4d7cb8('0xd83')]({'fields':_0x4d7cb8('0x1776'),'sort':_0x4d7cb8('0x4f0')})[_0x4d7cb8('0xa44')][_0x4d7cb8('0x1166')](function(_0xf8026a){const _0x5d39ad=_0x4d7cb8;_0x4595aa[_0x5d39ad('0x8de')]=_0xf8026a['rows']||[];})[_0x4d7cb8('0x1166')](function(){const _0x5903be=_0x4d7cb8;return _0x5136cf['userProfileSection'][_0x5903be('0xd83')]({'userProfileId':_0x4595aa[_0x5903be('0x98')][_0x5903be('0xb86')],'sectionId':0x12d})[_0x5903be('0xa44')];})[_0x4d7cb8('0x1166')](function(_0x71d92d){const _0x13540c=_0x4d7cb8,_0x5b5221=_0x71d92d&&_0x71d92d[_0x13540c('0x269a')]?_0x71d92d[_0x13540c('0x269a')][0x0]:null;if(!_0x5b5221){const _0x293e9d=[];let _0x3428d8=null;_0x4595aa[_0x13540c('0x2085')]&&(_0x3428d8=_0x2cfb05()['find'](_0x4595aa[_0x13540c('0x8de')],{'id':Number(_0x4595aa[_0x13540c('0x2085')][_0x13540c('0x23c')])}));for(let _0x2f3b50=0x0;_0x2f3b50<_0x4595aa[_0x13540c('0x8de')]['length'];_0x2f3b50++){_0x3428d8&&_0x4595aa['lists'][_0x2f3b50]['id']===_0x3428d8['id']&&(_0x4595aa[_0x13540c('0x8de')][_0x2f3b50][_0x13540c('0x2378')]=![],_0x293e9d['push'](_0x4595aa[_0x13540c('0x8de')][_0x2f3b50]));}_0x4595aa[_0x13540c('0x8de')]=_0x293e9d;}else{if(!_0x5b5221[_0x13540c('0x1a2b')])return _0x5136cf[_0x13540c('0x4b5')][_0x13540c('0xd83')]({'sectionId':_0x5b5221['id']})['$promise']['then'](function(_0x12426f){const _0x2af561=_0x13540c,_0x36d7bf=_0x2cfb05()[_0x2af561('0x2563')](_0x12426f[_0x2af561('0x269a')],function(_0x341fe7){const _0x26e329=_0x2af561;return _0x2cfb05()[_0x26e329('0xc38')](_0x4595aa[_0x26e329('0x8de')],{'id':_0x341fe7[_0x26e329('0x24e8')]});});let _0x1e9c3b=null;_0x4595aa[_0x2af561('0x2085')]&&(_0x1e9c3b=_0x2cfb05()['find'](_0x4595aa[_0x2af561('0x8de')],{'id':Number(_0x4595aa[_0x2af561('0x2085')]['ListId'])}));if(_0x1e9c3b&&!_0x2cfb05()[_0x2af561('0x1798')](_0x36d7bf,['id',_0x1e9c3b['id']])){const _0x9fb25a=_0x2cfb05()[_0x2af561('0xc38')](_0x4595aa['lists'],{'id':_0x1e9c3b['id']});_0x9fb25a[_0x2af561('0x2378')]=![],_0x36d7bf[_0x2af561('0x1514')](_0x9fb25a);}_0x4595aa[_0x2af561('0x8de')]=_0x36d7bf;});}})['catch'](function(_0x1eceda){const _0x38be2a=_0x4d7cb8;_0x8dab49[_0x38be2a('0xfc9')]({'title':_0x1eceda['status']?_0x38be2a('0x1e21')+_0x1eceda[_0x38be2a('0x52d')]+_0x38be2a('0x11e1')+_0x1eceda['statusText']:_0x38be2a('0x1248'),'msg':_0x1eceda['data']?JSON['stringify'](_0x1eceda[_0x38be2a('0x25f4')]):_0x1eceda[_0x38be2a('0x1586')]()});});function _0x3dc793(){const _0x2e5781=_0x4d7cb8;_0x4595aa['errors']=[],_0x5136cf[_0x2e5781('0x2085')]['addAccountApplications'](_0x4595aa[_0x2e5781('0x2085')])['$promise'][_0x2e5781('0x1166')](function(_0x2793b3){const _0x49211b=_0x2e5781;_0x4595aa[_0x49211b('0xd6c')]['unshift'](_0x2793b3[_0x49211b('0x2876')]()),_0x8dab49[_0x49211b('0x103b')]({'title':_0x49211b('0x24db'),'msg':_0x4595aa[_0x49211b('0x2085')]['name']?_0x4595aa['faxAccount'][_0x49211b('0x4f0')]+_0x49211b('0x1eda'):''}),_0x4e7363(_0x2793b3);})['catch'](function(_0x3e3a43){const _0x3edc6c=_0x2e5781;if(_0x3e3a43[_0x3edc6c('0x25f4')]&&_0x3e3a43['data'][_0x3edc6c('0x61a')]&&_0x3e3a43[_0x3edc6c('0x25f4')][_0x3edc6c('0x61a')]['length']){_0x4595aa[_0x3edc6c('0x61a')]=_0x3e3a43[_0x3edc6c('0x25f4')][_0x3edc6c('0x61a')]||[{'message':_0x3e3a43[_0x3edc6c('0x1586')](),'type':_0x3edc6c('0xf4c')}];for(let _0x24054a=0x0;_0x24054a<_0x3e3a43['data'][_0x3edc6c('0x61a')]['length'];_0x24054a+=0x1){_0x8dab49[_0x3edc6c('0xfc9')]({'title':_0x3e3a43['data']['errors'][_0x24054a][_0x3edc6c('0x1345')],'msg':_0x3e3a43[_0x3edc6c('0x25f4')]['errors'][_0x24054a][_0x3edc6c('0x1e70')]});}}else _0x8dab49['error']({'title':_0x3e3a43['status']?_0x3edc6c('0x1e21')+_0x3e3a43['status']+_0x3edc6c('0x11e1')+_0x3e3a43[_0x3edc6c('0xe1b')]:'api.faxAccount.save','msg':_0x3e3a43[_0x3edc6c('0x25f4')]?JSON[_0x3edc6c('0xbac')](_0x3e3a43[_0x3edc6c('0x25f4')][_0x3edc6c('0x1e70')]):_0x3e3a43['toString']()});});}function _0x893ba8(){const _0x3f5d99=_0x4d7cb8;_0x4595aa[_0x3f5d99('0x61a')]=[],_0x5136cf[_0x3f5d99('0x2085')][_0x3f5d99('0xf0d')](_0x4595aa['faxAccount'])[_0x3f5d99('0xa44')][_0x3f5d99('0x1166')](function(_0x1def8c){const _0x1e4c69=_0x3f5d99,_0x21ae6d=_0x2cfb05()[_0x1e4c69('0xc38')](_0x4595aa[_0x1e4c69('0xd6c')],{'id':_0x1def8c['id']});_0x21ae6d&&_0x2cfb05()['merge'](_0x21ae6d,_0x2cfb05()['pick'](_0x1def8c[_0x1e4c69('0x2876')](),_0x2cfb05()[_0x1e4c69('0x14a4')](_0x21ae6d))),_0x8dab49[_0x1e4c69('0x103b')]({'title':_0x1e4c69('0x416'),'msg':_0x4595aa['faxAccount'][_0x1e4c69('0x4f0')]?_0x4595aa['faxAccount']['name']+_0x1e4c69('0x7d'):''}),_0x4e7363(_0x1def8c);})['catch'](function(_0x4b0114){const _0x5de5a0=_0x3f5d99;if(_0x4b0114[_0x5de5a0('0x25f4')]&&_0x4b0114['data']['errors']&&_0x4b0114[_0x5de5a0('0x25f4')][_0x5de5a0('0x61a')]['length']){_0x4595aa[_0x5de5a0('0x61a')]=_0x4b0114[_0x5de5a0('0x25f4')][_0x5de5a0('0x61a')]||[{'message':_0x4b0114[_0x5de5a0('0x1586')](),'type':_0x5de5a0('0x1e9d')}];for(let _0x436de8=0x0;_0x436de8<_0x4b0114[_0x5de5a0('0x25f4')][_0x5de5a0('0x61a')][_0x5de5a0('0x264b')];_0x436de8++){_0x8dab49[_0x5de5a0('0xfc9')]({'title':_0x4b0114['data'][_0x5de5a0('0x61a')][_0x436de8][_0x5de5a0('0x1345')],'msg':_0x4b0114[_0x5de5a0('0x25f4')][_0x5de5a0('0x61a')][_0x436de8][_0x5de5a0('0x1e70')]});}}else _0x8dab49['error']({'title':_0x4b0114['status']?_0x5de5a0('0x1e21')+_0x4b0114[_0x5de5a0('0x52d')]+_0x5de5a0('0x11e1')+_0x4b0114[_0x5de5a0('0xe1b')]:_0x5de5a0('0x1e9d'),'msg':_0x4b0114['data']?JSON[_0x5de5a0('0xbac')](_0x4b0114['data'][_0x5de5a0('0x1e70')]):_0x4b0114['toString']()});});}function _0x3a28f6(_0x48676b){const _0x3130df=_0x4d7cb8;_0x4595aa[_0x3130df('0x61a')]=[];const _0x5917de=_0x31431b[_0x3130df('0x1d26')]()[_0x3130df('0xcdc')]('Are\x20you\x20sure?')[_0x3130df('0xacc')]('The\x20faxAccount\x20will\x20be\x20deleted.')['ariaLabel']('Delete\x20FaxAccount')['ok'](_0x3130df('0x18'))[_0x3130df('0x3f')]('Cancel')['targetEvent'](_0x48676b);_0x31431b[_0x3130df('0x1f80')](_0x5917de)[_0x3130df('0x1166')](function(){const _0x5224fd=_0x3130df;_0x5136cf[_0x5224fd('0x2085')][_0x5224fd('0x906')]({'id':_0x4595aa[_0x5224fd('0x2085')]['id']})[_0x5224fd('0xa44')]['then'](function(){const _0x215977=_0x5224fd;_0x2cfb05()['remove'](_0x4595aa['faxAccounts'],{'id':_0x4595aa[_0x215977('0x2085')]['id']}),_0x8dab49[_0x215977('0x103b')]({'title':_0x215977('0xcbc'),'msg':(_0x4595aa[_0x215977('0x2085')][_0x215977('0x4f0')]||'faxAccount')+_0x215977('0x7cd')}),_0x4e7363(_0x4595aa[_0x215977('0x2085')]);})[_0x5224fd('0x1a80')](function(_0x2a76d7){const _0x4d108b=_0x5224fd;if(_0x2a76d7['data']&&_0x2a76d7[_0x4d108b('0x25f4')][_0x4d108b('0x61a')]&&_0x2a76d7[_0x4d108b('0x25f4')][_0x4d108b('0x61a')]['length']){_0x4595aa[_0x4d108b('0x61a')]=_0x2a76d7[_0x4d108b('0x25f4')][_0x4d108b('0x61a')]||[{'message':_0x2a76d7['toString'](),'type':'api.faxAccount.delete'}];for(let _0x4258be=0x0;_0x4258be<_0x2a76d7[_0x4d108b('0x25f4')]['errors'][_0x4d108b('0x264b')];_0x4258be++){_0x8dab49[_0x4d108b('0xfc9')]({'title':_0x2a76d7[_0x4d108b('0x25f4')][_0x4d108b('0x61a')][_0x4258be][_0x4d108b('0x1345')],'msg':_0x2a76d7[_0x4d108b('0x25f4')][_0x4d108b('0x61a')][_0x4258be][_0x4d108b('0x1e70')]});}}else _0x8dab49['error']({'title':_0x2a76d7['status']?_0x4d108b('0x1e21')+_0x2a76d7[_0x4d108b('0x52d')]+'\x20-\x20'+_0x2a76d7[_0x4d108b('0xe1b')]:'api.faxAccount.delete','msg':_0x2a76d7['data']?JSON[_0x4d108b('0xbac')](_0x2a76d7[_0x4d108b('0x25f4')][_0x4d108b('0x1e70')]):_0x2a76d7[_0x4d108b('0x1e70')]||_0x2a76d7['toString']()});});},function(){});}function _0x53cba2(_0x41d1d2){return _0x41d1d2===null?undefined:new Date(_0x41d1d2);}function _0x4e7363(_0x4dafa2){const _0xce66df=_0x4d7cb8;_0x31431b[_0xce66df('0x1197')](_0x4dafa2);}}const _0x5d48dd=_0x55044e,_0x14db09=_0x2734b2['p']+_0x36e6f4('0x41f'),_0x5d248a=_0x2734b2['p']+_0x36e6f4('0x346'),_0x597cbf=_0x2734b2['p']+_0x36e6f4('0x1385'),_0x3dbf4f=_0x2734b2['p']+_0x36e6f4('0x2337'),_0x3a9adc=_0x2734b2['p']+'src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/interval/dialog.html/dialog.html',_0x210619=_0x2734b2['p']+_0x36e6f4('0x7b6'),_0x4f32cf=_0x2734b2['p']+_0x36e6f4('0x26bb'),_0x5d821e=_0x2734b2['p']+'src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/system/dialog.html/dialog.html',_0x4b30d9=_0x2734b2['p']+_0x36e6f4('0x20e1');_0x24bc81[_0x36e6f4('0x1294')]=[_0x36e6f4('0x19e3'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),'Auth'];const _0x4bd216={'agent':_0x14db09,'close':_0x5d248a,'gotoif':_0x597cbf,'gotop':_0x3dbf4f,'interval':_0x3a9adc,'noop':_0x210619,'queue':_0x4f32cf,'system':_0x5d821e,'tag':_0x4b30d9};function _0x24bc81(_0x5aa3eb,_0x3fe8e0,_0x18025f,_0x3aa352,_0x3d9033){const _0x190019=_0x36e6f4,_0x440d57=this;_0x440d57['currentUser']=_0x3d9033[_0x190019('0x26cd')](),_0x440d57[_0x190019('0x2085')]={},_0x440d57[_0x190019('0x1f1c')]={'count':0x0,'rows':[]},_0x440d57[_0x190019('0x2266')]=[],_0x440d57['crudPermissions'],_0x440d57[_0x190019('0x2218')]={'sort':_0x190019('0xfde')},_0x440d57[_0x190019('0x24d2')]=_0x2cfb05()['reject'](_0x2cfb05()['sortBy']([{'app':_0x190019('0x1545'),'appType':_0x190019('0x277c'),'types':[_0x190019('0x597'),'custom',_0x190019('0x1480')],'fields':[],'isApp':![]},{'app':_0x190019('0x2652'),'appType':_0x190019('0x2652'),'type':_0x190019('0x2652'),'icon':_0x190019('0x283f'),'interval':'*,*,*,*','required':!![],'isApp':!![],'fields':[{'title':_0x190019('0x1efa'),'name':_0x190019('0x18e0'),'type':_0x190019('0x1640'),'param':0x0}]},{'app':_0x190019('0x1c2b'),'appType':_0x190019('0x1c2b'),'type':_0x190019('0x1c2b'),'icon':_0x190019('0x283f'),'interval':_0x190019('0x16f'),'required':!![],'isApp':!![],'extraApi':[{'name':_0x190019('0x57a'),'field':{'name':_0x190019('0x734'),'key':_0x190019('0x4f0')},'route':_0x190019('0x734'),'filters':{'fields':'id,name','sort':_0x190019('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':_0x190019('0xd5'),'name':_0x190019('0x187'),'type':_0x190019('0x1640'),'required':!![],'param':0x0},{'title':_0x190019('0x2d5'),'name':'variable','type':_0x190019('0x2550'),'values':_0x190019('0x57a'),'value':_0x190019('0x15f0'),'option':_0x190019('0x15f0'),'defaultValues':[{'value':'\x27\x27','option':_0x190019('0x1280')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':'gotop','appType':_0x190019('0x6e6'),'type':'goto','icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':'Priority','name':_0x190019('0xfde'),'type':'number','required':!![],'min':0x0,'param':0x0}]},{'app':_0x190019('0x30f'),'appType':_0x190019('0x30f'),'type':_0x190019('0x30f'),'icon':'icon-apps','interval':_0x190019('0x16f'),'isApp':!![],'fields':[{'title':_0x190019('0x1cdc'),'name':_0x190019('0x8ff'),'type':_0x190019('0x1640'),'required':!![],'param':0x0},{'title':'truepriority','name':_0x190019('0x13a6'),'type':_0x190019('0xc45'),'min':0x1,'required':!![],'param':0x1},{'title':_0x190019('0x1d7a'),'name':_0x190019('0x1d7a'),'type':'number','min':0x1,'required':!![],'param':0x2}]},{'app':'queue','appType':_0x190019('0x1d3e'),'foreignKey':_0x190019('0x14e1'),'type':_0x190019('0x1d3e'),'icon':_0x190019('0x283f'),'interval':_0x190019('0x16f'),'isApp':!![],'extraApi':[{'name':'queues','field':{'name':_0x190019('0x1d3e'),'key':_0x190019('0x4f0')},'route':_0x190019('0x1a5b'),'filters':{'fields':_0x190019('0x1c09'),'sort':_0x190019('0x4f0'),'nolimit':!![]},'permissions':{'section':0x385}}],'fields':[{'title':_0x190019('0x28ba'),'name':_0x190019('0x1d3e'),'type':_0x190019('0x2550'),'values':'queues','value':_0x190019('0x24ad'),'option':_0x190019('0x24ad'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':'Timeout','name':'timeout','type':_0x190019('0xc45'),'max':0x20c49b,'min':0x0,'defaultValue':0x12c,'required':!![],'param':0x1}]},{'app':'agent','appType':'agent','type':_0x190019('0x1eff'),'foreignKey':_0x190019('0x122a'),'icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':_0x190019('0x1f7e'),'field':{'name':_0x190019('0x1eff'),'key':_0x190019('0x4f0')},'route':_0x190019('0x557'),'filters':{'fields':'id,name','sort':_0x190019('0x4f0'),'role':'agent','nolimit':!![]},'permissions':{'section':0xca}}],'fields':[{'title':_0x190019('0x89b'),'name':_0x190019('0x1eff'),'type':'apiselect','values':_0x190019('0x1f7e'),'value':_0x190019('0x1530'),'option':_0x190019('0x1530'),'required':!![],'param':0x0},{'title':_0x190019('0x1861'),'name':_0x190019('0x651'),'type':_0x190019('0xc45'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':_0x190019('0x1a7b'),'appType':_0x190019('0x1a7b'),'type':_0x190019('0x1a7b'),'icon':'icon-apps','interval':_0x190019('0x16f'),'isApp':!![],'fields':[{'title':'Disposition','name':_0x190019('0x12e8'),'type':_0x190019('0x1640'),'required':!![],'param':0x0}]},{'app':_0x190019('0x1446'),'appType':_0x190019('0x1446'),'type':_0x190019('0x1446'),'foreignKey':_0x190019('0x8f5'),'icon':_0x190019('0x283f'),'interval':_0x190019('0x16f'),'isApp':!![],'extraApi':[{'name':_0x190019('0xb38'),'field':{'name':_0x190019('0x1446'),'key':_0x190019('0x4f0')},'route':_0x190019('0x1446'),'filters':{'fields':_0x190019('0x1776'),'sort':_0x190019('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':'Tag','name':_0x190019('0x1446'),'type':'apiselect','values':_0x190019('0xb38'),'value':_0x190019('0xc2c'),'option':_0x190019('0xc2c'),'required':!![],'param':0x0}]}],['app']),{'isApp':![]}),_0x440d57[_0x190019('0x1480')]={'group':{'name':_0x190019('0x1b27'),'pull':_0x190019('0xddc')},'animation':0x64,'sort':![]},_0x440d57[_0x190019('0x227f')]={'group':{'name':_0x190019('0x103e'),'put':_0x190019('0x1b27')},'animation':0x64,'onAdd':function(_0x856c98){const _0x4c437a=_0x190019;_0x155cfb(_0x856c98,_0x856c98[_0x4c437a('0x1313')]);},'onSort':function(){_0x4bae8c();}},_0x440d57[_0x190019('0x24d5')]=_0x237987,_0x440d57[_0x190019('0x8a2')]=_0x146085,_0x440d57[_0x190019('0x232c')]=_0x533774,_0x440d57[_0x190019('0x4d9')]=_0x155cfb,_0x440d57[_0x190019('0x1a93')]=_0xef0652,_0x440d57[_0x190019('0xd04')]=_0x441575,_0x440d57['deleteSelectedFaxAccountApps']=_0x1ebce7,_0x440d57[_0x190019('0x20a6')]=_0x4bae8c,_0x440d57[_0x190019('0x242')]=_0x580deb;function _0x237987(_0x55218d,_0x573d0d){const _0x21251f=_0x190019;_0x440d57[_0x21251f('0x2085')]=_0x55218d,_0x440d57[_0x21251f('0x243c')]=typeof _0x573d0d!==_0x21251f('0x1048')?_0x573d0d:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x440d57[_0x21251f('0x227f')]['disabled']=!_0x440d57[_0x21251f('0x243c')][_0x21251f('0x1684')]?!![]:![],_0x440d57['query']['id']=_0x55218d['id'],_0x440d57[_0x21251f('0x2218')][_0x21251f('0x1a55')]=!![],_0x440d57[_0x21251f('0x2218')][_0x21251f('0x49d')]=!![],_0x440d57['getFaxAccountApps'](),_0x440d57[_0x21251f('0x242')]();}function _0x146085(_0x513360,_0x33ac12,_0x28899b){const _0x5a0125=_0x190019,_0x45c392=_0x3fe8e0['confirm']()[_0x5a0125('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20application?')[_0x5a0125('0xf3c')](''+_0x513360[_0x5a0125('0x746')]+_0x5a0125('0xace')+_0x5a0125('0x3f3'))['ariaLabel']('delete\x20application')[_0x5a0125('0x203b')](_0x28899b)['ok']('OK')[_0x5a0125('0x3f')](_0x5a0125('0x2d3'));_0x3fe8e0[_0x5a0125('0x1f80')](_0x45c392)[_0x5a0125('0x1166')](function(){const _0x10d077=_0x5a0125;_0x440d57[_0x10d077('0x1f1c')][_0x10d077('0x269a')]['splice'](_0x33ac12,0x1),_0x4bae8c();},function(){const _0x3cf62c=_0x5a0125;console[_0x3cf62c('0x455')]('CANCEL');});}function _0x155cfb(_0x160e0e,_0x58712d){const _0x56d694=_0x190019;if(_0x440d57[_0x56d694('0x1f1c')]['rows'][_0x56d694('0x264b')]){const _0x3153a6=_0x440d57['faxAccountApps'][_0x56d694('0x269a')][_0x58712d]?_0x440d57[_0x56d694('0x1f1c')]['rows'][_0x58712d]:_0x440d57[_0x56d694('0x1f1c')][_0x56d694('0x269a')][0x0],_0x7487e8=(_0x3153a6[_0x56d694('0x83f')]||_0x3153a6['app'])['toLowerCase']();_0x3fe8e0['show']({'controller':_0x56d694('0x1b59')+_0x7487e8+_0x56d694('0x8a4'),'controllerAs':'vm','templateUrl':_0x4bd216[_0x7487e8],'parent':angular[_0x56d694('0x1194')](_0x18025f['body']),'targetEvent':_0x160e0e,'clickOutsideToClose':!![],'locals':{'faxAccountApp':_0x3153a6,'faxAccount':_0x440d57[_0x56d694('0x2085')],'crudPermissions':_0x440d57[_0x56d694('0x243c')]}})['then'](function(_0x48edae){const _0x84909=_0x56d694;_0x48edae&&(_0x48edae['id']?_0x440d57[_0x84909('0x1f1c')][_0x84909('0x269a')][_0x58712d]=_0x48edae:_0x440d57[_0x84909('0x1f1c')][_0x84909('0x269a')][_0x84909('0x57b')](_0x58712d,0x0,_0x48edae),_0x4bae8c());})[_0x56d694('0x1a80')](function(_0x4c386e){const _0x2f6e68=_0x56d694;_0x4c386e&&_0x3aa352[_0x2f6e68('0xfc9')]({'title':_0x4c386e[_0x2f6e68('0x52d')]?'API:'+_0x4c386e['status']+_0x2f6e68('0x11e1')+_0x4c386e['statusText']:_0x2f6e68('0x2e5'),'msg':_0x4c386e[_0x2f6e68('0x25f4')]?JSON['stringify'](_0x4c386e[_0x2f6e68('0x25f4')]):_0x4c386e[_0x2f6e68('0x1586')]()});});}}function _0xef0652(_0x3db688,_0x379042){const _0x458907=_0x190019;if(_0x440d57['faxAccountApps'][_0x458907('0x269a')][_0x458907('0x264b')]){const _0x9dfd74=_0x440d57[_0x458907('0x1f1c')][_0x458907('0x269a')][_0x379042]?_0x440d57[_0x458907('0x1f1c')]['rows'][_0x379042]:_0x440d57[_0x458907('0x1f1c')][_0x458907('0x269a')][0x0];_0x3fe8e0['show']({'controller':_0x458907('0x8ad'),'controllerAs':'vm','templateUrl':_0x3a9adc,'parent':angular[_0x458907('0x1194')](_0x18025f[_0x458907('0x8d2')]),'targetEvent':_0x3db688,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x9dfd74[_0x458907('0x277c')],'IntervalId':_0x9dfd74[_0x458907('0x186f')],'application':!![]},'intervals':[],'crudPermissions':_0x440d57[_0x458907('0x243c')]}})[_0x458907('0x1166')](function(_0x431790){const _0x2cfd95=_0x458907;_0x431790&&(_0x9dfd74[_0x2cfd95('0x277c')]=_0x431790[_0x2cfd95('0x277c')]||_0x2cfd95('0x16f'),_0x9dfd74[_0x2cfd95('0x186f')]=_0x431790[_0x2cfd95('0x186f')]||null,_0x4bae8c());});}}function _0x4bae8c(){const _0x17b3ef=_0x190019;let _0x200b28=0x1,_0x333798=[];for(let _0x594657=0x0;_0x594657<_0x440d57[_0x17b3ef('0x1f1c')][_0x17b3ef('0x269a')]['length'];_0x594657++){const _0x2653f4=_0x440d57[_0x17b3ef('0x1f1c')][_0x17b3ef('0x269a')][_0x594657],_0x55e91b=[],_0x4480e4=[];_0x2653f4['intervals']=_0x2653f4[_0x17b3ef('0x277c')]!==_0x17b3ef('0x16f')?[_0x2653f4[_0x17b3ef('0x277c')]]:_0x2653f4[_0x17b3ef('0x186f')]?_0x2cfb05()[_0x17b3ef('0x2563')](_0x2cfb05()[_0x17b3ef('0x1c33')](_0x440d57['intervals'][_0x17b3ef('0x269a')],{'IntervalId':_0x2653f4[_0x17b3ef('0x186f')]}),_0x17b3ef('0x277c')):[],_0x2653f4[_0x17b3ef('0xe1c')]=_0x440d57['faxAccount'][_0x17b3ef('0xe1c')],_0x2653f4[_0x17b3ef('0x23ae')]=_0x440d57[_0x17b3ef('0x2085')][_0x17b3ef('0x23ae')],_0x2653f4[_0x17b3ef('0x1345')]&&(_0x2653f4[_0x17b3ef('0x1345')]=_0x2653f4[_0x17b3ef('0x1345')][_0x17b3ef('0x2574')]()),_0x2653f4['priority']=_0x55e91b[_0x17b3ef('0x264b')]?_0x2cfb05()[_0x17b3ef('0x1ef5')](_0x55e91b)[_0x17b3ef('0xfde')]+0x1:_0x200b28,_0x200b28=(_0x4480e4[_0x17b3ef('0x264b')]?_0x2cfb05()[_0x17b3ef('0x1ef5')](_0x4480e4)[_0x17b3ef('0xfde')]:_0x2653f4[_0x17b3ef('0xfde')])+0x1,_0x333798=_0x2cfb05()['concat'](_0x333798,_0x55e91b,[_0x2653f4],_0x4480e4);}_0x5aa3eb[_0x17b3ef('0x2085')][_0x17b3ef('0x153b')]({'id':_0x440d57[_0x17b3ef('0x2085')]['id']},_0x2cfb05()[_0x17b3ef('0x1eba')](_0x333798,'priority'))[_0x17b3ef('0xa44')][_0x17b3ef('0x1166')](function(_0x129776){const _0x3490ad=_0x17b3ef;_0x440d57[_0x3490ad('0x1f1c')][_0x3490ad('0x269a')]=_0x129776[_0x3490ad('0x269a')];})[_0x17b3ef('0x1a80')](function(_0x5a2fc7){const _0x26e5bd=_0x17b3ef;console[_0x26e5bd('0xfc9')](_0x5a2fc7);});}function _0x4e9e13(_0x29be2d){const _0x5bd124=_0x190019;_0x440d57[_0x5bd124('0x1f1c')]=_0x29be2d||{'count':0x0,'rows':[]};}function _0x580deb(){const _0x50785a=_0x190019;return _0x5aa3eb[_0x50785a('0x277c')][_0x50785a('0xd83')]({'fields':_0x50785a('0x1d39')})['$promise']['then'](function(_0x172706){const _0xd08a69=_0x50785a;_0x440d57[_0xd08a69('0x164e')]=_0x172706;})['catch'](function(_0x4734cc){const _0x2661ab=_0x50785a;console[_0x2661ab('0xfc9')](_0x4734cc);});}function _0x533774(){const _0x38a584=_0x190019;_0x440d57[_0x38a584('0x1f48')]=_0x5aa3eb[_0x38a584('0x2085')][_0x38a584('0x10e0')](_0x440d57[_0x38a584('0x2218')],_0x4e9e13)[_0x38a584('0xa44')];}function _0x441575(_0x10857a){const _0x2fbec7=_0x190019;_0x2cfb05()[_0x2fbec7('0x127f')](_0x440d57[_0x2fbec7('0x1f1c')][_0x2fbec7('0x269a')],{'id':_0x10857a['id']}),_0x4bae8c(),_0x3aa352[_0x2fbec7('0x103b')]({'title':_0x2fbec7('0x11c0'),'msg':_0x10857a['app']?_0x10857a['app']+'\x20has\x20been\x20deleted!':''});}function _0x1ebce7(_0x1ee6b9){const _0x5b393e=_0x190019,_0x3a61aa=_0x3fe8e0[_0x5b393e('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20applications?')[_0x5b393e('0xf3c')](_0x5b393e('0x12b5')+_0x440d57['selectedFaxAccountApps']['length']+_0x5b393e('0x196d')+_0x5b393e('0x3f3'))[_0x5b393e('0x8e8')]('delete\x20applications')['targetEvent'](_0x1ee6b9)['ok']('OK')[_0x5b393e('0x3f')](_0x5b393e('0x2d3'));_0x3fe8e0[_0x5b393e('0x1f80')](_0x3a61aa)[_0x5b393e('0x1166')](function(){const _0x576db9=_0x5b393e;_0x440d57[_0x576db9('0x2266')][_0x576db9('0x2782')](function(_0x3b566b){const _0x48b90f=_0x576db9;_0x2cfb05()['remove'](_0x440d57['faxAccountApps'][_0x48b90f('0x269a')],{'id':_0x3b566b['id']});}),_0x440d57[_0x576db9('0x2266')]=[],_0x4bae8c();});}}const _0x5c812e=_0x24bc81;_0x5cdd93[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'faxAccount',_0x36e6f4('0xd6c'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x5cdd93(_0x10159a,_0x527089,_0x140f33,_0x48ef37,_0x5f4a90,_0xa5d0fe,_0x15a3bb,_0x4b339d,_0x3704d5,_0x1e9784){const _0x48915f=_0x36e6f4,_0x2cccbc=this;_0x2cccbc['currentUser']=_0x3704d5[_0x48915f('0x26cd')](),_0x2cccbc['faxAccount']=_0x5f4a90,_0x2cccbc[_0x48915f('0x243c')]=_0x1e9784,_0x2cccbc[_0x48915f('0xf01')]=_0x15a3bb,_0x2cccbc[_0x48915f('0xbd7')]=[],_0x2cccbc['allowedItems']=[],_0x2cccbc[_0x48915f('0x18e1')]=[],_0x2cccbc['startingAllowedItems']=[],_0x2cccbc[_0x48915f('0x2781')]=[],_0x2cccbc[_0x48915f('0x14d7')]=![],_0x2cccbc[_0x48915f('0xae0')]=_0x2834eb,_0x2cccbc['saveAgents']=_0x3eee8f,_0x2cccbc[_0x48915f('0x24a0')]=_0x474a53,_0x2cccbc[_0x48915f('0xc68')]={'readOnly':!_0x2cccbc[_0x48915f('0x243c')][_0x48915f('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x48915f('0x4f0'),'line1':_0x48915f('0x6e1'),'line2':['name',_0x48915f('0x1eef')],'line3':'','labelAll':_0x4b339d['instant'](_0x48915f('0x677')),'labelSelected':_0x4b339d[_0x48915f('0x25cc')](_0x48915f('0x1c03')),'transferCallback':function(){const _0x41f22a=_0x48915f,_0xd4fd99=_0x2cfb05()['xorBy'](_0x2cccbc[_0x41f22a('0x2781')],_0x2cccbc[_0x41f22a('0x18e1')],'id');_0x2cccbc[_0x41f22a('0x14d7')]=_0x2cfb05()['isEmpty'](_0xd4fd99)?![]:!![];}};function _0x2834eb(){const _0x10e5ed=_0x48915f;return _0x3704d5[_0x10e5ed('0x1ac6')]('admin')?_0x3cb085()['catch'](function(_0x404fec){const _0x31d021=_0x10e5ed;_0x140f33[_0x31d021('0xfc9')]({'title':_0x404fec[_0x31d021('0x52d')]?_0x31d021('0x1e21')+_0x404fec[_0x31d021('0x52d')]+_0x31d021('0x11e1')+_0x404fec[_0x31d021('0xe1b')]:'SYSTEM:GET_AGENTS','msg':_0x404fec[_0x31d021('0x52d')]?JSON['stringify'](_0x404fec[_0x31d021('0x25f4')]):_0x404fec[_0x31d021('0x1586')]()});}):_0x436464()[_0x10e5ed('0x1166')](function(_0x419ebb){const _0x255a1d=_0x10e5ed;return _0x2cccbc[_0x255a1d('0xe60')]=_0x419ebb,_0x3cb085();})['catch'](function(_0x5dd09a){const _0x146e61=_0x10e5ed;_0x140f33[_0x146e61('0xfc9')]({'title':_0x5dd09a['status']?_0x146e61('0x1e21')+_0x5dd09a[_0x146e61('0x52d')]+_0x146e61('0x11e1')+_0x5dd09a[_0x146e61('0xe1b')]:_0x146e61('0xd4c'),'msg':_0x5dd09a[_0x146e61('0x52d')]?JSON[_0x146e61('0xbac')](_0x5dd09a[_0x146e61('0x25f4')]):_0x5dd09a[_0x146e61('0x1586')]()});});}function _0x436464(){return _0x527089(function(_0x3b1dab,_0x31d3de){const _0x19f0b3=a0_0x3f2c;_0x48ef37[_0x19f0b3('0x17aa')]['get']({'userProfileId':_0x2cccbc[_0x19f0b3('0x98')][_0x19f0b3('0xb86')],'name':_0x19f0b3('0x2391')})[_0x19f0b3('0xa44')][_0x19f0b3('0x1166')](function(_0x4559dc){const _0x52cd41=_0x19f0b3,_0x37d1b8=_0x4559dc&&_0x4559dc[_0x52cd41('0x269a')]?_0x4559dc[_0x52cd41('0x269a')][0x0]:null;_0x3b1dab(_0x37d1b8);})[_0x19f0b3('0x1a80')](function(_0x27de62){_0x31d3de(_0x27de62);});});}function _0x3cb085(){return _0x527089(function(_0x6ffeeb,_0x5660b0){const _0x4f7e07=a0_0x3f2c;return _0x3fc019()[_0x4f7e07('0x1166')](function(_0x3e2ef1){const _0x468b66=_0x4f7e07;return _0x2cccbc[_0x468b66('0xbd7')]=_0x3e2ef1[_0x468b66('0x269a')]?_0x3e2ef1[_0x468b66('0x269a')]:[],_0x3704d5[_0x468b66('0x1ac6')]('admin')?_0x3e2ef1:_0x2cccbc[_0x468b66('0xe60')]?_0x2cccbc[_0x468b66('0xe60')][_0x468b66('0x1a2b')]?_0x3e2ef1:_0x54ff66():null;})[_0x4f7e07('0x1166')](function(_0x3f41e4){const _0x2f8b02=_0x4f7e07,_0xc1f270=_0x3f41e4&&_0x3f41e4[_0x2f8b02('0x269a')]?_0x3f41e4[_0x2f8b02('0x269a')]:[];return _0x2cccbc['allowedItems']=_0x2cfb05()[_0x2f8b02('0x2563')](_0xc1f270,function(_0x49c5af){const _0x270e91=_0x2f8b02;return _0x2cfb05()[_0x270e91('0xc38')](_0x2cccbc[_0x270e91('0xbd7')],{'id':_0x3704d5[_0x270e91('0x1ac6')]('admin')||_0x2cccbc[_0x270e91('0xe60')][_0x270e91('0x1a2b')]?_0x49c5af['id']:_0x49c5af[_0x270e91('0x24e8')]});}),_0x2cccbc[_0x2f8b02('0x2111')]=angular[_0x2f8b02('0x225f')](_0x2cccbc['allowedItems']),_0x2cccbc[_0x2f8b02('0xbd7')][_0x2f8b02('0x2782')](function(_0x4c04a3){const _0x185f60=_0x2f8b02,_0x59ddf0=_0x2cfb05()['find'](_0x2cccbc['allowedItems'],{'id':_0x4c04a3['id']});_0x3704d5[_0x185f60('0x1ac6')](_0x185f60('0xa7c'))?_0x4c04a3['isValid']=!![]:_0x4c04a3['isValid']=typeof _0x59ddf0!==_0x185f60('0x1048')?!![]:![];}),_0x5cbd58();})[_0x4f7e07('0x1166')](function(_0x4e3050){const _0x137669=_0x4f7e07,_0x8662b7=_0x4e3050&&_0x4e3050[_0x137669('0x269a')]?_0x4e3050[_0x137669('0x269a')]:[];_0x2cccbc[_0x137669('0x18e1')]=_0x2cfb05()[_0x137669('0x2563')](_0x8662b7,function(_0x401c94){const _0xe065b5=_0x137669,_0x574f27=_0x2cfb05()[_0xe065b5('0xc38')](_0x2cccbc[_0xe065b5('0xbd7')],{'id':_0x401c94['id']});return _0x574f27['penalty']=_0x401c94[_0xe065b5('0x23eb')]?_0xe065b5('0x11e8')+_0x401c94[_0xe065b5('0x23eb')][_0xe065b5('0x23af')]:'',_0x574f27['internal']=typeof _0x401c94['internal']!==_0xe065b5('0x1048')?'<'+_0x401c94['internal']+'>':'',_0x574f27;}),_0x2cccbc[_0x137669('0x2781')]=angular[_0x137669('0x225f')](_0x2cccbc[_0x137669('0x18e1')]),_0x2cccbc['dualMultiselectOptions']['selectedItems']=_0x2cccbc['selectedItems'],_0x2cccbc[_0x137669('0xc68')][_0x137669('0xbd7')]=_0x2cfb05()[_0x137669('0x24ac')](_0x2cccbc[_0x137669('0x10ab')],_0x2cccbc['dualMultiselectOptions'][_0x137669('0x18e1')],'id'),_0x6ffeeb();})[_0x4f7e07('0x1a80')](function(_0x10ac70){_0x5660b0(_0x10ac70);});});}function _0x54ff66(){return _0x527089(function(_0x41c096,_0xad41e7){const _0x32edd5=a0_0x3f2c;return _0x48ef37['userProfileResource'][_0x32edd5('0xd83')]({'sectionId':_0x2cccbc[_0x32edd5('0xe60')]['id'],'nolimit':!![]})[_0x32edd5('0xa44')][_0x32edd5('0x1166')](function(_0x2d4445){_0x41c096(_0x2d4445);})[_0x32edd5('0x1a80')](function(_0x176ef4){_0xad41e7(_0x176ef4);});});}function _0x5cbd58(){return _0x527089(function(_0x5fa952,_0x4915fd){const _0x1e7d27=a0_0x3f2c;return _0x48ef37[_0x1e7d27('0x2085')][_0x1e7d27('0x261c')]({'id':_0x2cccbc[_0x1e7d27('0x2085')]['id'],'fields':_0x1e7d27('0x1459'),'nolimit':!![],'role':_0x1e7d27('0x1eff')})[_0x1e7d27('0xa44')][_0x1e7d27('0x1166')](function(_0x6e1584){_0x5fa952(_0x6e1584);})[_0x1e7d27('0x1a80')](function(_0x23ea4d){_0x4915fd(_0x23ea4d);});});}function _0x3fc019(){return _0x527089(function(_0x1c7d80,_0x29952c){const _0x25a57b=a0_0x3f2c;return _0x48ef37[_0x25a57b('0x557')][_0x25a57b('0xd83')]({'fields':_0x25a57b('0x1459'),'nolimit':!![],'role':'agent'})['$promise']['then'](function(_0x246ad7){_0x1c7d80(_0x246ad7);})[_0x25a57b('0x1a80')](function(_0x47130e){_0x29952c(_0x47130e);});});}function _0x32ec5e(_0x487b39){return _0x527089(function(_0x24a2a5,_0x4c1c90){const _0x1a384c=a0_0x3f2c;_0x2cfb05()[_0x1a384c('0x1081')](_0x487b39)?_0x24a2a5():_0x48ef37['faxAccount'][_0x1a384c('0x275c')]({'id':_0x2cccbc[_0x1a384c('0x2085')]['id'],'ids':_0x2cfb05()[_0x1a384c('0x2563')](_0x487b39,'id')})[_0x1a384c('0xa44')]['then'](function(){_0x24a2a5();})[_0x1a384c('0x1a80')](function(_0x2cebbd){_0x4c1c90(_0x2cebbd);});});}function _0x21586c(_0x112faf){return _0x527089(function(_0x14f4b4,_0x71ac1e){const _0x304cfe=a0_0x3f2c;_0x2cfb05()[_0x304cfe('0x1081')](_0x112faf)?_0x14f4b4():_0x48ef37[_0x304cfe('0x2085')][_0x304cfe('0x269d')]({'id':_0x2cccbc['faxAccount']['id'],'ids':_0x2cfb05()[_0x304cfe('0x2563')](_0x112faf,'id')})[_0x304cfe('0xa44')][_0x304cfe('0x1166')](function(){_0x14f4b4();})[_0x304cfe('0x1a80')](function(_0x447ccb){_0x71ac1e(_0x447ccb);});});}function _0x3eee8f(){const _0x1c6d93=_0x48915f,_0x39a58a=_0x2cfb05()['differenceBy'](_0x2cccbc['startingSelectedItems'],_0x2cccbc[_0x1c6d93('0x18e1')],'id'),_0x33aa5b=_0x2cfb05()[_0x1c6d93('0x24ac')](_0x2cccbc[_0x1c6d93('0x18e1')],_0x2cccbc[_0x1c6d93('0x2781')],'id');return _0x21586c(_0x39a58a)['then'](function(){return _0x32ec5e(_0x33aa5b);})[_0x1c6d93('0x1166')](function(){const _0x58b172=_0x1c6d93;_0x2cccbc[_0x58b172('0x14d7')]=![],_0x2cccbc[_0x58b172('0x2111')]=angular['copy'](_0x2cccbc[_0x58b172('0x10ab')]),_0x2cccbc[_0x58b172('0x2781')]=angular['copy'](_0x2cccbc[_0x58b172('0x18e1')]),_0x140f33['success']({'title':_0x58b172('0x983'),'msg':_0x58b172('0x1673')});})[_0x1c6d93('0x1a80')](function(_0x4f0f4b){const _0x8e573=_0x1c6d93;_0x140f33[_0x8e573('0xfc9')]({'title':_0x4f0f4b['status']?'API:'+_0x4f0f4b[_0x8e573('0x52d')]+_0x8e573('0x11e1')+_0x4f0f4b[_0x8e573('0xe1b')]:_0x8e573('0x1b29'),'msg':_0x4f0f4b[_0x8e573('0x52d')]?JSON['stringify'](_0x4f0f4b[_0x8e573('0x25f4')]):_0x4f0f4b['toString']()});});}function _0x474a53(){_0x10159a['hide']();}}const _0x54528b=_0x5cdd93;_0x1d05c2[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0xbc7'),'faxAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x1d05c2(_0x8fe75e,_0x386ae4,_0xf5e06a,_0x334eb8,_0x4a3b7f,_0x57b4fc,_0x300192,_0x595479){const _0x188c64=_0x36e6f4,_0x26c442=this;_0x26c442['currentUser']=_0x300192[_0x188c64('0x26cd')](),_0x26c442['errors']=[],_0x26c442['title']='FAX.EDIT_'+(_0x334eb8[_0x188c64('0x83f')]||_0x334eb8[_0x188c64('0x746')])['toUpperCase'](),_0x26c442[_0x188c64('0x1eff')]=angular[_0x188c64('0x225f')](_0x334eb8),_0x26c442[_0x188c64('0x243c')]=_0x595479,_0x26c442[_0x188c64('0x128b')]={};if(_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x823')])switch(_0x26c442[_0x188c64('0x1eff')]['appType']?_0x26c442[_0x188c64('0x1eff')]['appType'][_0x188c64('0x2574')]():_0x26c442['agent']['app'][_0x188c64('0x2574')]()){case _0x188c64('0x2853'):break;case _0x188c64('0xded'):{const _0x44581f=_0x26c442['agent'][_0x188c64('0x823')][_0x188c64('0x25c8')](',');_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x7ca')]=_0x44581f[0x0],_0x26c442[_0x188c64('0x1eff')][_0x188c64('0xedb')]=_0x44581f[0x1],_0x26c442['agent'][_0x188c64('0x1634')]=_0x44581f[_0x188c64('0x233')](0x2,_0x44581f[_0x188c64('0x264b')])[_0x188c64('0x45a')](',');}break;case _0x188c64('0x1636'):{const _0x2e1865=_0x26c442['agent'][_0x188c64('0x823')][_0x188c64('0x25c8')](',');_0x26c442[_0x188c64('0x1eff')]['projectId']=_0x2e1865[0x0],_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x27f3')]=_0x2e1865[0x1],_0x26c442[_0x188c64('0x1eff')]['privateKey']=_0x2e1865[0x2],_0x26c442[_0x188c64('0x1eff')]['language']=_0x2e1865[0x3],_0x26c442[_0x188c64('0x1eff')]['welcomemessage']=_0x2e1865[_0x188c64('0x233')](0x4,_0x2e1865['length'])[_0x188c64('0x45a')](',');}break;case'amazonlex':{const _0x5d2b9c=_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x823')]['split'](',');_0x26c442[_0x188c64('0x1eff')]['accesskeyid']=_0x5d2b9c[0x0],_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x125')]=_0x5d2b9c[0x1],_0x26c442['agent'][_0x188c64('0x25a2')]=_0x5d2b9c[0x2],_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x1ac4')]=_0x5d2b9c[0x3],_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x1634')]=_0x5d2b9c[_0x188c64('0x233')](0x4,_0x5d2b9c[_0x188c64('0x264b')])[_0x188c64('0x45a')](',');}break;case _0x188c64('0x1af7'):{const _0x2ff198=_0x26c442[_0x188c64('0x1eff')]['appdata']['split'](',');_0x26c442['agent']['times']=isNaN(_0x2ff198[0x0])?_0x2ff198[0x0]:parseInt(_0x2ff198[0x0],0xa),_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x1640')]=_0x2ff198['slice'](0x1,_0x2ff198[_0x188c64('0x264b')])[_0x188c64('0x45a')](',');}break;case _0x188c64('0x1e70'):_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x1640')]=_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x823')];break;case _0x188c64('0xceb'):_0x26c442[_0x188c64('0x1eff')]['name']=_0x26c442['agent'][_0x188c64('0x823')]['split']('=')[0x0],_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x18e0')]=_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x823')][_0x188c64('0x25c8')]('=')[0x1];break;case'agi':_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x2588')]=_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x823')];break;default:{const _0x28f6bd=_0x26c442[_0x188c64('0x1eff')]['appdata'][_0x188c64('0x25c8')](',');_0x26c442[_0x188c64('0x1eff')]['agent']=_0x2cfb05()[_0x188c64('0x1081')](_0x28f6bd[0x0])?_0x28f6bd[0x0]:isNaN(_0x28f6bd[0x0])?_0x28f6bd[0x0]:parseInt(_0x28f6bd[0x0],0xa),_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x651')]=_0x2cfb05()[_0x188c64('0x1081')](_0x28f6bd[0x1])?_0x28f6bd[0x1]:isNaN(_0x28f6bd[0x1])?_0x28f6bd[0x1]:parseInt(_0x28f6bd[0x1],0xa);}break;}else _0x26c442[_0x188c64('0x1eff')][_0x188c64('0x651')]=0x1e;_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x1345')]&&_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x1345')]['toLowerCase']()===_0x188c64('0x587')&&_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x83f')][_0x188c64('0x2574')]()===_0x188c64('0x2884')&&(_0x26c442[_0x188c64('0x1eff')]['prefix']=_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x2026')]?_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x2026')][_0x188c64('0x25c8')]('$')[0x0]:undefined,_0x26c442[_0x188c64('0x1eff')][_0x188c64('0x1f02')]=_0x26c442[_0x188c64('0x1eff')]['callerID']?_0x188c64('0xa4c')+_0x26c442['agent'][_0x188c64('0x992')]:undefined);_0x26c442[_0x188c64('0x1f31')]=_0xcec4f5,_0x26c442[_0x188c64('0x24a0')]=_0x4e042d,_0x300192['hasRole'](_0x188c64('0xa7c'))?_0x57b4fc[_0x188c64('0x557')]['get']({'fields':_0x188c64('0x1776'),'sort':_0x188c64('0x4f0'),'role':'agent','nolimit':'true'})[_0x188c64('0xa44')][_0x188c64('0x1166')](function(_0x4bb776){const _0xed3aa4=_0x188c64;_0x26c442[_0xed3aa4('0x1f7e')]=_0x4bb776[_0xed3aa4('0x269a')]||[];})[_0x188c64('0x1a80')](function(_0x3b163c){const _0x4448f8=_0x188c64;_0xf5e06a[_0x4448f8('0xfc9')]({'title':_0x3b163c['status']?_0x4448f8('0x1e21')+_0x3b163c[_0x4448f8('0x52d')]+_0x4448f8('0x11e1')+_0x3b163c[_0x4448f8('0xe1b')]:_0x4448f8('0xd4c'),'msg':_0x3b163c['data']?JSON[_0x4448f8('0xbac')](_0x3b163c[_0x4448f8('0x25f4')]):_0x3b163c[_0x4448f8('0x1586')]()});}):_0x57b4fc['user'][_0x188c64('0xd83')]({'fields':_0x188c64('0x1776'),'sort':_0x188c64('0x4f0'),'role':'agent','nolimit':'true'})['$promise']['then'](function(_0x2f0c5c){const _0xdf3517=_0x188c64;_0x26c442['agents']=_0x2f0c5c[_0xdf3517('0x269a')]||[];})[_0x188c64('0x1166')](function(){const _0x2cc6c7=_0x188c64;return _0x57b4fc[_0x2cc6c7('0x17aa')][_0x2cc6c7('0xd83')]({'userProfileId':_0x26c442[_0x2cc6c7('0x98')][_0x2cc6c7('0xb86')],'sectionId':0xca})[_0x2cc6c7('0xa44')];})[_0x188c64('0x1166')](function(_0x51c2df){const _0x322c2e=_0x188c64,_0x95389d=_0x51c2df&&_0x51c2df[_0x322c2e('0x269a')]?_0x51c2df[_0x322c2e('0x269a')][0x0]:null;if(!_0x95389d){const _0x1751f1=[];let _0x596171=null;_0x26c442[_0x322c2e('0x1eff')]&&(_0x596171=_0x2cfb05()[_0x322c2e('0xc38')](_0x26c442[_0x322c2e('0x1f7e')],{'name':_0x26c442['agent'][_0x322c2e('0x1eff')]}));for(let _0x1cd64f=0x0;_0x1cd64f<_0x26c442[_0x322c2e('0x1f7e')][_0x322c2e('0x264b')];_0x1cd64f++){_0x596171&&_0x26c442['agents'][_0x1cd64f]['id']===_0x596171['id']&&(_0x26c442['agents'][_0x1cd64f][_0x322c2e('0x2378')]=![],_0x1751f1[_0x322c2e('0x1514')](_0x26c442['agents'][_0x1cd64f]));}_0x26c442['agents']=_0x1751f1;}else{if(!_0x95389d[_0x322c2e('0x1a2b')])return _0x57b4fc[_0x322c2e('0x4b5')][_0x322c2e('0xd83')]({'sectionId':_0x95389d['id']})[_0x322c2e('0xa44')]['then'](function(_0x3d57e2){const _0x34277b=_0x322c2e,_0x1fb517=_0x2cfb05()['map'](_0x3d57e2[_0x34277b('0x269a')],function(_0xbb7ceb){const _0xa2967a=_0x34277b;return _0x2cfb05()['find'](_0x26c442[_0xa2967a('0x1f7e')],{'id':_0xbb7ceb[_0xa2967a('0x24e8')]});});let _0x492cc3=null;_0x26c442['agent']&&(_0x492cc3=_0x2cfb05()[_0x34277b('0xc38')](_0x26c442[_0x34277b('0x1f7e')],{'name':_0x26c442['agent'][_0x34277b('0x1eff')]}));if(_0x492cc3&&!_0x2cfb05()['some'](_0x1fb517,['id',_0x492cc3['id']])){const _0x52550a=_0x2cfb05()[_0x34277b('0xc38')](_0x26c442[_0x34277b('0x1f7e')],{'id':_0x492cc3['id']});_0x52550a[_0x34277b('0x2378')]=![],_0x1fb517[_0x34277b('0x1514')](_0x52550a);}_0x26c442[_0x34277b('0x1f7e')]=_0x1fb517;});}})[_0x188c64('0x1a80')](function(_0x35049b){const _0x8619f0=_0x188c64;_0xf5e06a['error']({'title':_0x35049b['status']?_0x8619f0('0x1e21')+_0x35049b[_0x8619f0('0x52d')]+'\x20-\x20'+_0x35049b[_0x8619f0('0xe1b')]:_0x8619f0('0xdc5'),'msg':_0x35049b[_0x8619f0('0x25f4')]?JSON[_0x8619f0('0xbac')](_0x35049b[_0x8619f0('0x25f4')]):_0x35049b[_0x8619f0('0x1586')]()});});function _0xcec4f5(){const _0x3db305=_0x188c64;_0x26c442['errors']=[];const _0x520b27=[];_0x26c442['agent']['type']&&_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x1345')]['toLowerCase']()===_0x3db305('0x587')&&_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x83f')]===_0x3db305('0x867')&&(_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x2026')]=_0x4a3b7f['cutdigits']?(_0x26c442['agent'][_0x3db305('0x265a')]||'')+_0x3db305('0x881')+_0x4a3b7f[_0x3db305('0x2848')]+'}':(_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x265a')]||'')+'${EXTEN}',_0x4a3b7f[_0x3db305('0x28cb')]!==_0x3db305('0x192')?_0x26c442[_0x3db305('0x1eff')][_0x3db305('0xd39')][_0x3db305('0x2379')](_0x3db305('0x1059'))<0x0&&(_0x26c442[_0x3db305('0x1eff')][_0x3db305('0xd39')]+=_0x3db305('0x1059')):_0x26c442[_0x3db305('0x1eff')]['options']=_0x26c442['agent'][_0x3db305('0xd39')][_0x3db305('0xf3')](_0x3db305('0x1059'),''));const _0x1b0b4d=_0x2cfb05()['find'](_0x26c442['agents'],{'name':_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x1eff')]});_0x1b0b4d&&(_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x122a')]=_0x1b0b4d['id']);if(_0x26c442[_0x3db305('0x1eff')]['appType']&&_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x83f')]===_0x3db305('0x2853')){}else switch((_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x746')]||_0x26c442['agent']['appType'])['toLowerCase']()){case _0x3db305('0xceb'):_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x823')]=_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x4f0')]+'='+_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x18e0')];break;case _0x3db305('0x2853'):break;default:_0x520b27[0x0]=_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x1eff')],_0x520b27[0x1]=_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x651')],_0x26c442[_0x3db305('0x1eff')][_0x3db305('0x823')]=_0x520b27['join'](',');}_0x4e042d(_0x26c442['agent']);}function _0x4e042d(_0x3daeb1){const _0x46000b=_0x188c64;_0x8fe75e[_0x46000b('0x1197')](_0x3daeb1);}}const _0xe7fc68=_0x1d05c2;_0x58a775['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0xbc7'),'faxAccount','api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x58a775(_0x58df32,_0x1d9955,_0x31ab29,_0x349a0e,_0x261b92,_0x5dbe01,_0x4c4107,_0x544d2f){const _0x241e03=_0x36e6f4,_0x16ad99=this;_0x16ad99[_0x241e03('0x98')]=_0x4c4107[_0x241e03('0x26cd')](),_0x16ad99[_0x241e03('0x61a')]=[],_0x16ad99[_0x241e03('0xcdc')]='FAX.EDIT_'+(_0x349a0e[_0x241e03('0x83f')]||_0x349a0e['app'])[_0x241e03('0x1387')](),_0x16ad99[_0x241e03('0x1a7b')]=angular[_0x241e03('0x225f')](_0x349a0e),_0x16ad99[_0x241e03('0x243c')]=_0x544d2f,_0x16ad99[_0x241e03('0x128b')]={};if(_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x823')])switch(_0x16ad99['close'][_0x241e03('0x83f')]?_0x16ad99['close'][_0x241e03('0x83f')][_0x241e03('0x2574')]():_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x746')]['toLowerCase']()){case _0x241e03('0x2853'):break;case'dialogflow':{const _0x5739dd=_0x16ad99[_0x241e03('0x1a7b')]['appdata'][_0x241e03('0x25c8')](',');_0x16ad99['close'][_0x241e03('0x7ca')]=_0x5739dd[0x0],_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0xedb')]=_0x5739dd[0x1],_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x1634')]=_0x5739dd['slice'](0x2,_0x5739dd[_0x241e03('0x264b')])['join'](',');}break;case'dialogflowv2':{const _0x55178d=_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x823')][_0x241e03('0x25c8')](',');_0x16ad99['close'][_0x241e03('0x1b0a')]=_0x55178d[0x0],_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x27f3')]=_0x55178d[0x1],_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x170e')]=_0x55178d[0x2],_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0xedb')]=_0x55178d[0x3],_0x16ad99['close'][_0x241e03('0x1634')]=_0x55178d['slice'](0x4,_0x55178d[_0x241e03('0x264b')])[_0x241e03('0x45a')](',');}break;case _0x241e03('0x86c'):{const _0x153d08=_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x823')][_0x241e03('0x25c8')](',');_0x16ad99['close'][_0x241e03('0xee6')]=_0x153d08[0x0],_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x125')]=_0x153d08[0x1],_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x25a2')]=_0x153d08[0x2],_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x1ac4')]=_0x153d08[0x3],_0x16ad99[_0x241e03('0x1a7b')]['welcomemessage']=_0x153d08[_0x241e03('0x233')](0x4,_0x153d08[_0x241e03('0x264b')])[_0x241e03('0x45a')](',');}break;case _0x241e03('0x1af7'):{const _0x28f163=_0x16ad99[_0x241e03('0x1a7b')]['appdata'][_0x241e03('0x25c8')](',');_0x16ad99['close'][_0x241e03('0x265e')]=isNaN(_0x28f163[0x0])?_0x28f163[0x0]:parseInt(_0x28f163[0x0],0xa),_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x1640')]=_0x28f163[_0x241e03('0x233')](0x1,_0x28f163['length'])[_0x241e03('0x45a')](',');}break;case _0x241e03('0x1e70'):_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x1640')]=_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x823')];break;case'set':_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x4f0')]=_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x823')][_0x241e03('0x25c8')]('=')[0x0],_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x18e0')]=_0x16ad99['close'][_0x241e03('0x823')][_0x241e03('0x25c8')]('=')[0x1];break;case _0x241e03('0x1034'):_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x2588')]=_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x823')];break;default:{const _0x4c7ee4=_0x16ad99['close']['appdata'][_0x241e03('0x25c8')](',');_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x12e8')]=_0x2cfb05()['isEmpty'](_0x4c7ee4[0x0])?_0x4c7ee4[0x0]:isNaN(_0x4c7ee4[0x0])?_0x4c7ee4[0x0]:parseInt(_0x4c7ee4[0x0],0xa);}break;}else{}_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x1345')]&&_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x1345')][_0x241e03('0x2574')]()==='outbound'&&_0x16ad99['close']['appType']['toLowerCase']()===_0x241e03('0x2884')&&(_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x265a')]=_0x16ad99[_0x241e03('0x1a7b')]['phone']?_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x2026')][_0x241e03('0x25c8')]('$')[0x0]:undefined,_0x16ad99[_0x241e03('0x1a7b')][_0x241e03('0x1f02')]=_0x16ad99[_0x241e03('0x1a7b')]['callerID']?_0x241e03('0xa4c')+_0x16ad99['close'][_0x241e03('0x992')]:undefined);_0x16ad99[_0x241e03('0x1f31')]=_0x4115e7,_0x16ad99[_0x241e03('0x24a0')]=_0x16112b;function _0x4115e7(){const _0x2a6b45=_0x241e03;_0x16ad99[_0x2a6b45('0x61a')]=[];const _0x19435b=[];_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0x1345')]&&_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0x1345')]['toLowerCase']()===_0x2a6b45('0x587')&&_0x16ad99['close'][_0x2a6b45('0x83f')]===_0x2a6b45('0x867')&&(_0x16ad99[_0x2a6b45('0x1a7b')]['phone']=_0x261b92[_0x2a6b45('0x2848')]?(_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0x265a')]||'')+'${EXTEN:'+_0x261b92['cutdigits']+'}':(_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0x265a')]||'')+_0x2a6b45('0x1d1'),_0x261b92[_0x2a6b45('0x28cb')]!==_0x2a6b45('0x192')?_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0xd39')][_0x2a6b45('0x2379')](_0x2a6b45('0x1059'))<0x0&&(_0x16ad99['close'][_0x2a6b45('0xd39')]+='U(xcally-mixmonitor-context)'):_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0xd39')]=_0x16ad99['close'][_0x2a6b45('0xd39')][_0x2a6b45('0xf3')](_0x2a6b45('0x1059'),''));if(_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0x83f')]&&_0x16ad99['close'][_0x2a6b45('0x83f')]==='custom'){}else switch((_0x16ad99[_0x2a6b45('0x1a7b')]['app']||_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0x83f')])[_0x2a6b45('0x2574')]()){case _0x2a6b45('0xceb'):_0x16ad99['close']['appdata']=_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0x4f0')]+'='+_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0x18e0')];break;case _0x2a6b45('0x2853'):break;default:_0x19435b[0x0]=_0x16ad99['close'][_0x2a6b45('0x12e8')],_0x16ad99[_0x2a6b45('0x1a7b')][_0x2a6b45('0x823')]=_0x19435b[_0x2a6b45('0x45a')](',');}_0x16112b(_0x16ad99[_0x2a6b45('0x1a7b')]);}function _0x16112b(_0x3adee5){_0x58df32['hide'](_0x3adee5);}}const _0x5d4a8e=_0x58a775;_0x564368[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0xbc7'),_0x36e6f4('0x2085'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x564368(_0x471f58,_0x28942b,_0xfa381f,_0x176af4,_0x28b7fb,_0x120997,_0x5c268a,_0x39fcc4){const _0x347ba8=_0x36e6f4,_0x25835c=this;_0x25835c[_0x347ba8('0x98')]=_0x5c268a[_0x347ba8('0x26cd')](),_0x25835c[_0x347ba8('0x61a')]=[],_0x25835c[_0x347ba8('0xcdc')]='FAX.EDIT_'+(_0x176af4[_0x347ba8('0x83f')]||_0x176af4[_0x347ba8('0x746')])[_0x347ba8('0x1387')](),_0x25835c[_0x347ba8('0x30f')]=angular[_0x347ba8('0x225f')](_0x176af4),_0x25835c['crudPermissions']=_0x39fcc4,_0x25835c[_0x347ba8('0x128b')]={};if(_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x823')])switch(_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x83f')]?_0x25835c['gotoif']['appType'][_0x347ba8('0x2574')]():_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x746')][_0x347ba8('0x2574')]()){case _0x347ba8('0x2853'):break;case _0x347ba8('0xded'):{const _0x31469a=_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x823')][_0x347ba8('0x25c8')](',');_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x7ca')]=_0x31469a[0x0],_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0xedb')]=_0x31469a[0x1],_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x1634')]=_0x31469a[_0x347ba8('0x233')](0x2,_0x31469a[_0x347ba8('0x264b')])[_0x347ba8('0x45a')](',');}break;case _0x347ba8('0x1636'):{const _0x406e4a=_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x823')][_0x347ba8('0x25c8')](',');_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x1b0a')]=_0x406e4a[0x0],_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x27f3')]=_0x406e4a[0x1],_0x25835c['gotoif'][_0x347ba8('0x170e')]=_0x406e4a[0x2],_0x25835c['gotoif'][_0x347ba8('0xedb')]=_0x406e4a[0x3],_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x1634')]=_0x406e4a[_0x347ba8('0x233')](0x4,_0x406e4a['length'])[_0x347ba8('0x45a')](',');}break;case _0x347ba8('0x86c'):{const _0x4a71e5=_0x25835c['gotoif'][_0x347ba8('0x823')][_0x347ba8('0x25c8')](',');_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0xee6')]=_0x4a71e5[0x0],_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x125')]=_0x4a71e5[0x1],_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x25a2')]=_0x4a71e5[0x2],_0x25835c['gotoif'][_0x347ba8('0x1ac4')]=_0x4a71e5[0x3],_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x1634')]=_0x4a71e5['slice'](0x4,_0x4a71e5[_0x347ba8('0x264b')])[_0x347ba8('0x45a')](',');}break;case _0x347ba8('0x1af7'):{const _0x349f9a=_0x25835c[_0x347ba8('0x30f')]['appdata'][_0x347ba8('0x25c8')](',');_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x265e')]=isNaN(_0x349f9a[0x0])?_0x349f9a[0x0]:parseInt(_0x349f9a[0x0],0xa),_0x25835c['gotoif']['text']=_0x349f9a[_0x347ba8('0x233')](0x1,_0x349f9a[_0x347ba8('0x264b')])['join'](',');}break;case'message':_0x25835c['gotoif']['text']=_0x25835c[_0x347ba8('0x30f')]['appdata'];break;case _0x347ba8('0xceb'):_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x4f0')]=_0x25835c['gotoif']['appdata']['split']('=')[0x0],_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x18e0')]=_0x25835c[_0x347ba8('0x30f')]['appdata'][_0x347ba8('0x25c8')]('=')[0x1];break;case _0x347ba8('0x1034'):_0x25835c['gotoif'][_0x347ba8('0x2588')]=_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x823')];break;default:{const _0x5c1732=_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x823')][_0x347ba8('0x25c8')](',');_0x25835c['gotoif']['condition']=_0x2cfb05()[_0x347ba8('0x1081')](_0x5c1732[0x0])?_0x5c1732[0x0]:isNaN(_0x5c1732[0x0])?_0x5c1732[0x0]:parseInt(_0x5c1732[0x0],0xa),_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x13a6')]=_0x2cfb05()['isEmpty'](_0x5c1732[0x1])?_0x5c1732[0x1]:isNaN(_0x5c1732[0x1])?_0x5c1732[0x1]:parseInt(_0x5c1732[0x1],0xa),_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x1d7a')]=_0x2cfb05()[_0x347ba8('0x1081')](_0x5c1732[0x2])?_0x5c1732[0x2]:isNaN(_0x5c1732[0x2])?_0x5c1732[0x2]:parseInt(_0x5c1732[0x2],0xa);}break;}else{}_0x25835c[_0x347ba8('0x30f')]['type']&&_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x1345')][_0x347ba8('0x2574')]()==='outbound'&&_0x25835c[_0x347ba8('0x30f')]['appType'][_0x347ba8('0x2574')]()===_0x347ba8('0x2884')&&(_0x25835c['gotoif'][_0x347ba8('0x265a')]=_0x25835c['gotoif'][_0x347ba8('0x2026')]?_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x2026')][_0x347ba8('0x25c8')]('$')[0x0]:undefined,_0x25835c[_0x347ba8('0x30f')]['callerId']=_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x992')]?_0x347ba8('0xa4c')+_0x25835c[_0x347ba8('0x30f')][_0x347ba8('0x992')]:undefined);_0x25835c[_0x347ba8('0x1f31')]=_0x14e901,_0x25835c[_0x347ba8('0x24a0')]=_0x56a2af;function _0x14e901(){const _0x40dc50=_0x347ba8;_0x25835c[_0x40dc50('0x61a')]=[];const _0x5b073d=[];_0x25835c[_0x40dc50('0x30f')]['type']&&_0x25835c[_0x40dc50('0x30f')]['type'][_0x40dc50('0x2574')]()===_0x40dc50('0x587')&&_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0x83f')]===_0x40dc50('0x867')&&(_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0x2026')]=_0x28b7fb['cutdigits']?(_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0x265a')]||'')+_0x40dc50('0x881')+_0x28b7fb[_0x40dc50('0x2848')]+'}':(_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0x265a')]||'')+_0x40dc50('0x1d1'),_0x28b7fb[_0x40dc50('0x28cb')]!==_0x40dc50('0x192')?_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0xd39')][_0x40dc50('0x2379')](_0x40dc50('0x1059'))<0x0&&(_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0xd39')]+=_0x40dc50('0x1059')):_0x25835c[_0x40dc50('0x30f')]['options']=_0x25835c['gotoif'][_0x40dc50('0xd39')][_0x40dc50('0xf3')](_0x40dc50('0x1059'),''));if(_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0x83f')]&&_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0x83f')]===_0x40dc50('0x2853')){}else switch((_0x25835c['gotoif'][_0x40dc50('0x746')]||_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0x83f')])['toLowerCase']()){case _0x40dc50('0xceb'):_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0x823')]=_0x25835c[_0x40dc50('0x30f')]['name']+'='+_0x25835c['gotoif']['value'];break;case _0x40dc50('0x2853'):break;default:_0x5b073d[0x0]=_0x25835c[_0x40dc50('0x30f')][_0x40dc50('0x8ff')],_0x5b073d[0x1]=_0x25835c['gotoif'][_0x40dc50('0x13a6')],_0x5b073d[0x2]=_0x25835c[_0x40dc50('0x30f')]['falsepriority'],_0x25835c[_0x40dc50('0x30f')]['appdata']=_0x5b073d['join'](',');}_0x56a2af(_0x25835c[_0x40dc50('0x30f')]);}function _0x56a2af(_0x2c02a1){const _0x1f25c4=_0x347ba8;_0x471f58[_0x1f25c4('0x1197')](_0x2c02a1);}}const _0x157564=_0x564368;_0x53b271[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0xbc7'),_0x36e6f4('0x2085'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x53b271(_0xbfb6d3,_0x22dc6c,_0x310512,_0x309e3a,_0x1a7a96,_0x3278ba,_0x18b23e,_0xa2716f){const _0x3edc49=_0x36e6f4,_0x5bad30=this;_0x5bad30[_0x3edc49('0x98')]=_0x18b23e[_0x3edc49('0x26cd')](),_0x5bad30[_0x3edc49('0x61a')]=[],_0x5bad30[_0x3edc49('0xcdc')]=_0x3edc49('0x156b')+(_0x309e3a['appType']||_0x309e3a['app'])['toUpperCase'](),_0x5bad30[_0x3edc49('0x6e6')]=angular[_0x3edc49('0x225f')](_0x309e3a),_0x5bad30[_0x3edc49('0x243c')]=_0xa2716f,_0x5bad30[_0x3edc49('0x128b')]={};if(_0x5bad30['gotop'][_0x3edc49('0x823')])switch(_0x5bad30['gotop']['appType']?_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x83f')][_0x3edc49('0x2574')]():_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x746')]['toLowerCase']()){case'custom':break;case _0x3edc49('0xded'):{const _0x4f3b25=_0x5bad30[_0x3edc49('0x6e6')]['appdata'][_0x3edc49('0x25c8')](',');_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x7ca')]=_0x4f3b25[0x0],_0x5bad30['gotop'][_0x3edc49('0xedb')]=_0x4f3b25[0x1],_0x5bad30[_0x3edc49('0x6e6')]['welcomemessage']=_0x4f3b25['slice'](0x2,_0x4f3b25[_0x3edc49('0x264b')])[_0x3edc49('0x45a')](',');}break;case'dialogflowv2':{const _0x1c3426=_0x5bad30[_0x3edc49('0x6e6')]['appdata'][_0x3edc49('0x25c8')](',');_0x5bad30['gotop'][_0x3edc49('0x1b0a')]=_0x1c3426[0x0],_0x5bad30[_0x3edc49('0x6e6')]['clientEmail']=_0x1c3426[0x1],_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x170e')]=_0x1c3426[0x2],_0x5bad30['gotop'][_0x3edc49('0xedb')]=_0x1c3426[0x3],_0x5bad30['gotop'][_0x3edc49('0x1634')]=_0x1c3426['slice'](0x4,_0x1c3426[_0x3edc49('0x264b')])[_0x3edc49('0x45a')](',');}break;case'amazonlex':{const _0x4d5f93=_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x823')][_0x3edc49('0x25c8')](',');_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0xee6')]=_0x4d5f93[0x0],_0x5bad30[_0x3edc49('0x6e6')]['secretaccesskey']=_0x4d5f93[0x1],_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x25a2')]=_0x4d5f93[0x2],_0x5bad30['gotop']['botname']=_0x4d5f93[0x3],_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x1634')]=_0x4d5f93['slice'](0x4,_0x4d5f93[_0x3edc49('0x264b')])[_0x3edc49('0x45a')](',');}break;case _0x3edc49('0x1af7'):{const _0x1e643e=_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x823')][_0x3edc49('0x25c8')](',');_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x265e')]=isNaN(_0x1e643e[0x0])?_0x1e643e[0x0]:parseInt(_0x1e643e[0x0],0xa),_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x1640')]=_0x1e643e['slice'](0x1,_0x1e643e[_0x3edc49('0x264b')])['join'](',');}break;case _0x3edc49('0x1e70'):_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x1640')]=_0x5bad30[_0x3edc49('0x6e6')]['appdata'];break;case _0x3edc49('0xceb'):_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x4f0')]=_0x5bad30['gotop'][_0x3edc49('0x823')][_0x3edc49('0x25c8')]('=')[0x0],_0x5bad30[_0x3edc49('0x6e6')]['value']=_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x823')][_0x3edc49('0x25c8')]('=')[0x1];break;case _0x3edc49('0x1034'):_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x2588')]=_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x823')];break;default:{const _0x1da7b1=_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x823')][_0x3edc49('0x25c8')](',');_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0xfde')]=_0x2cfb05()[_0x3edc49('0x1081')](_0x1da7b1[0x0])?_0x1da7b1[0x0]:isNaN(_0x1da7b1[0x0])?_0x1da7b1[0x0]:parseInt(_0x1da7b1[0x0],0xa);}break;}else{}_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x1345')]&&_0x5bad30['gotop'][_0x3edc49('0x1345')]['toLowerCase']()==='outbound'&&_0x5bad30['gotop']['appType'][_0x3edc49('0x2574')]()==='outbounddial'&&(_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x265a')]=_0x5bad30['gotop']['phone']?_0x5bad30[_0x3edc49('0x6e6')][_0x3edc49('0x2026')][_0x3edc49('0x25c8')]('$')[0x0]:undefined,_0x5bad30[_0x3edc49('0x6e6')]['callerId']=_0x5bad30[_0x3edc49('0x6e6')]['callerID']?_0x3edc49('0xa4c')+_0x5bad30[_0x3edc49('0x6e6')]['callerID']:undefined);_0x5bad30[_0x3edc49('0x1f31')]=_0x530fb1,_0x5bad30[_0x3edc49('0x24a0')]=_0x494ded;function _0x530fb1(){const _0x123a10=_0x3edc49;_0x5bad30[_0x123a10('0x61a')]=[];const _0x5f407d=[];_0x5bad30[_0x123a10('0x6e6')]['type']&&_0x5bad30['gotop'][_0x123a10('0x1345')]['toLowerCase']()==='outbound'&&_0x5bad30[_0x123a10('0x6e6')]['appType']===_0x123a10('0x867')&&(_0x5bad30[_0x123a10('0x6e6')]['phone']=_0x1a7a96[_0x123a10('0x2848')]?(_0x5bad30[_0x123a10('0x6e6')]['prefix']||'')+_0x123a10('0x881')+_0x1a7a96[_0x123a10('0x2848')]+'}':(_0x5bad30['gotop'][_0x123a10('0x265a')]||'')+_0x123a10('0x1d1'),_0x1a7a96['recordingFormat']!==_0x123a10('0x192')?_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0xd39')][_0x123a10('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0xd39')]+=_0x123a10('0x1059')):_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0xd39')]=_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0xd39')][_0x123a10('0xf3')](_0x123a10('0x1059'),''));if(_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0x83f')]&&_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0x83f')]==='custom'){}else switch((_0x5bad30['gotop'][_0x123a10('0x746')]||_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0x83f')])[_0x123a10('0x2574')]()){case _0x123a10('0xceb'):_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0x823')]=_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0x4f0')]+'='+_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0x18e0')];break;case'custom':break;default:_0x5f407d[0x0]=_0x5bad30[_0x123a10('0x6e6')][_0x123a10('0xfde')],_0x5bad30[_0x123a10('0x6e6')]['appdata']=_0x5f407d[_0x123a10('0x45a')](',');}_0x494ded(_0x5bad30[_0x123a10('0x6e6')]);}function _0x494ded(_0x5a8fd5){_0xbfb6d3['hide'](_0x5a8fd5);}}const _0x334910=_0x53b271;_0x16ac53[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),'$mdDialog',_0x36e6f4('0x25d0'),'IndexFactory',_0x36e6f4('0x277c'),_0x36e6f4('0x164e'),_0x36e6f4('0x1d2e'),'api','Auth',_0x36e6f4('0x243c')];function _0x16ac53(_0x41dfdd,_0x24b374,_0x198777,_0x1787d6,_0x54324c,_0x4283e2,_0x314f5d,_0x6fe8f1,_0x5a029f,_0x4242c8){const _0x406009=_0x36e6f4,_0x90ab99=this;_0x90ab99[_0x406009('0x98')]=_0x5a029f[_0x406009('0x26cd')](),_0x90ab99[_0x406009('0x61a')]=[],_0x90ab99['title']=_0x406009('0x2879'),_0x90ab99[_0x406009('0x277c')]=angular[_0x406009('0x225f')](_0x54324c),_0x90ab99[_0x406009('0x164e')]=_0x4283e2,_0x90ab99[_0x406009('0x99d')]=![],_0x90ab99[_0x406009('0x6aa')]=[_0x406009('0x597'),_0x406009('0x2853'),_0x406009('0x1480')],_0x90ab99['crudPermissions']=_0x4242c8,_0x90ab99[_0x406009('0x5ef')]=_0x1787d6[_0x406009('0x28de')](),_0x90ab99['monthNumber']=_0x1787d6[_0x406009('0x51d')](),_0x90ab99[_0x406009('0x2259')]=_0x1787d6[_0x406009('0x1c39')](),_0x90ab99[_0x406009('0x1fc0')]=_0x1787d6[_0x406009('0x2489')]();if(!_0x90ab99[_0x406009('0x277c')])_0x90ab99[_0x406009('0x277c')]={'interval':_0x406009('0x16f')},_0x90ab99[_0x406009('0x1345')]=_0x406009('0x597'),_0x90ab99[_0x406009('0xcdc')]=_0x406009('0x412'),_0x90ab99[_0x406009('0x99d')]=!![];else{if(_0x90ab99[_0x406009('0x277c')][_0x406009('0x277c')]!==_0x406009('0x16f')){_0x90ab99[_0x406009('0x1345')]='custom';const _0x4af681=_0x90ab99[_0x406009('0x277c')]['interval']['split'](','),_0x87afe3=_0x4af681[0x0],_0x3a00c8=_0x4af681[0x1],_0x59aa0f=_0x4af681[0x2],_0x14587d=_0x4af681[0x3];if(_0x87afe3!=='*'){const _0x2c5ad3=_0x87afe3[_0x406009('0x25c8')]('-')[0x0],_0x1883b6=_0x87afe3[_0x406009('0x25c8')]('-')[0x1];let _0x1e1528;_0x1e1528=new Date(),_0x1e1528[_0x406009('0xe24')](Number(_0x2c5ad3[_0x406009('0x25c8')](':')[0x0])),_0x1e1528[_0x406009('0x790')](Number(_0x2c5ad3['split'](':')[0x1])),_0x90ab99[_0x406009('0x64d')]=_0x1e1528,_0x1e1528=new Date(),_0x1e1528[_0x406009('0xe24')](Number(_0x1883b6['split'](':')[0x0])),_0x1e1528[_0x406009('0x790')](Number(_0x1883b6['split'](':')[0x1])),_0x90ab99[_0x406009('0x2076')]=_0x1e1528;}_0x3a00c8!=='*'&&(_0x90ab99[_0x406009('0x1eca')]=_0x3a00c8[_0x406009('0x25c8')]('-')[0x0],_0x90ab99[_0x406009('0x1b81')]=_0x3a00c8[_0x406009('0x25c8')]('-')[0x1]),_0x59aa0f!=='*'&&(_0x90ab99[_0x406009('0x103d')]=_0x59aa0f[_0x406009('0x25c8')]('-')[0x0],_0x90ab99['monthDayTo']=_0x59aa0f[_0x406009('0x25c8')]('-')[0x1]),_0x14587d!=='*'&&(_0x90ab99[_0x406009('0xdec')]=_0x14587d[_0x406009('0x25c8')]('-')[0x0],_0x90ab99[_0x406009('0x1125')]=_0x14587d[_0x406009('0x25c8')]('-')[0x1]);}else _0x90ab99['type']=_0x406009('0x597');}_0x41dfdd[_0x406009('0x23f')]['id']&&!_0x90ab99[_0x406009('0x277c')]['application']&&(_0x90ab99[_0x406009('0x277c')]['IntervalId']=_0x41dfdd[_0x406009('0x23f')]['id']);_0x90ab99[_0x406009('0x277c')][_0x406009('0x186f')]&&_0x90ab99[_0x406009('0x277c')][_0x406009('0x50d')]&&(_0x90ab99[_0x406009('0x1345')]=_0x406009('0x1480'));_0x90ab99[_0x406009('0x1ebf')]=_0x49e223,_0x90ab99[_0x406009('0x24be')]=_0x3d5c9a,_0x90ab99['closeDialog']=_0x293919;_0x90ab99[_0x406009('0x277c')][_0x406009('0x50d')]&&(_0x5a029f[_0x406009('0x1ac6')](_0x406009('0xa7c'))?_0x6fe8f1['interval'][_0x406009('0xd83')]({'fields':_0x406009('0xd0a'),'IntervalId':_0x406009('0x15d7'),'nolimit':!![]})[_0x406009('0xa44')][_0x406009('0x1166')](function(_0x5868b9){const _0x277cfe=_0x406009;_0x90ab99[_0x277cfe('0x164e')]=_0x5868b9['rows']||[];})['catch'](function(_0x9bb036){const _0x476984=_0x406009;_0x314f5d[_0x476984('0xfc9')]({'title':_0x9bb036[_0x476984('0x52d')]?_0x476984('0x1e21')+_0x9bb036[_0x476984('0x52d')]+_0x476984('0x11e1')+_0x9bb036['statusText']:_0x476984('0xbb4'),'msg':_0x9bb036['data']?JSON[_0x476984('0xbac')](_0x9bb036[_0x476984('0x25f4')]):_0x9bb036[_0x476984('0x1586')]()});}):_0x6fe8f1[_0x406009('0x277c')][_0x406009('0xd83')]({'fields':_0x406009('0xd0a'),'IntervalId':_0x406009('0x15d7'),'nolimit':!![]})[_0x406009('0xa44')][_0x406009('0x1166')](function(_0x498d1b){const _0x1fcba5=_0x406009;_0x90ab99[_0x1fcba5('0x164e')]=_0x498d1b['rows']||[];})['then'](function(){const _0x1389ae=_0x406009;return _0x6fe8f1[_0x1389ae('0x17aa')]['get']({'userProfileId':_0x90ab99['currentUser'][_0x1389ae('0xb86')],'sectionId':0x3ec})['$promise'];})[_0x406009('0x1166')](function(_0xf6f59a){const _0x3995f5=_0x406009,_0x2d81bf=_0xf6f59a&&_0xf6f59a[_0x3995f5('0x269a')]?_0xf6f59a[_0x3995f5('0x269a')][0x0]:null;if(!_0x2d81bf)_0x90ab99['intervals']=[];else{if(!_0x2d81bf[_0x3995f5('0x1a2b')])return _0x6fe8f1[_0x3995f5('0x4b5')][_0x3995f5('0xd83')]({'sectionId':_0x2d81bf['id']})[_0x3995f5('0xa44')][_0x3995f5('0x1166')](function(_0x172c1a){const _0x1d995a=_0x3995f5,_0x1bdc5a=_0x172c1a&&_0x172c1a['rows']?_0x172c1a[_0x1d995a('0x269a')]:[],_0x3b6d9b=[];let _0x3f6a79=null;_0x90ab99[_0x1d995a('0x277c')]&&(_0x3f6a79=_0x2cfb05()['find'](_0x90ab99[_0x1d995a('0x164e')],{'name':_0x90ab99[_0x1d995a('0x277c')]['IntervalId']})),_0x3f6a79&&!_0x2cfb05()[_0x1d995a('0x1798')](_0x1bdc5a,[_0x1d995a('0x24e8'),_0x3f6a79['id']])&&_0x90ab99[_0x1d995a('0x164e')]['forEach'](function(_0x14291b){const _0xfc36fb=_0x1d995a;_0x14291b['id']===_0x3f6a79['id']&&(_0x14291b['canSelect']=![],_0x3b6d9b[_0xfc36fb('0x1514')](_0x14291b));}),_0x90ab99[_0x1d995a('0x164e')]=_0x3b6d9b;});}})['catch'](function(_0x49f09c){const _0x1b586e=_0x406009;_0x314f5d[_0x1b586e('0xfc9')]({'title':_0x49f09c[_0x1b586e('0x52d')]?_0x1b586e('0x1e21')+_0x49f09c[_0x1b586e('0x52d')]+_0x1b586e('0x11e1')+_0x49f09c[_0x1b586e('0xe1b')]:_0x1b586e('0xbb4'),'msg':_0x49f09c['data']?JSON[_0x1b586e('0xbac')](_0x49f09c[_0x1b586e('0x25f4')]):_0x49f09c['toString']()});}));function _0x55c4d3(){const _0x158c77=_0x406009;switch(_0x90ab99[_0x158c77('0x1345')]){case _0x158c77('0x597'):case _0x158c77('0x1480'):return _0x158c77('0x16f');case _0x158c77('0x2853'):{const _0x29e4e6=[];if(_0x90ab99[_0x158c77('0x64d')]!=='*'&&_0x90ab99[_0x158c77('0x64d')]&&_0x90ab99[_0x158c77('0x2076')]){const _0x446725=(_0x90ab99[_0x158c77('0x64d')][_0x158c77('0x11fe')]()<0xa?'0':'')+_0x90ab99[_0x158c77('0x64d')]['getHours']()+':'+((_0x90ab99['timeRangeFrom'][_0x158c77('0x234')]()<0xa?'0':'')+_0x90ab99[_0x158c77('0x64d')][_0x158c77('0x234')]()),_0x36f591=(_0x90ab99[_0x158c77('0x2076')][_0x158c77('0x11fe')]()<0xa?'0':'')+_0x90ab99[_0x158c77('0x2076')][_0x158c77('0x11fe')]()+':'+((_0x90ab99['timeRangeTo'][_0x158c77('0x234')]()<0xa?'0':'')+_0x90ab99['timeRangeTo']['getMinutes']());_0x29e4e6[_0x158c77('0x1514')](_0x446725+'-'+_0x36f591);}else _0x29e4e6[_0x158c77('0x1514')]('*');return _0x90ab99[_0x158c77('0x1eca')]?_0x90ab99[_0x158c77('0x1b81')]?_0x29e4e6[_0x158c77('0x1514')](_0x90ab99['dayOfWeekFrom']+'-'+_0x90ab99[_0x158c77('0x1b81')]):_0x29e4e6[_0x158c77('0x1514')](_0x90ab99[_0x158c77('0x1eca')]):_0x29e4e6[_0x158c77('0x1514')]('*'),_0x90ab99[_0x158c77('0x103d')]?_0x90ab99[_0x158c77('0x1dbb')]?_0x29e4e6['push'](_0x90ab99['monthDayFrom']+'-'+_0x90ab99[_0x158c77('0x1dbb')]):_0x29e4e6[_0x158c77('0x1514')](_0x90ab99['monthDayFrom']):_0x29e4e6[_0x158c77('0x1514')]('*'),_0x90ab99['monthFrom']?_0x90ab99['monthTo']?_0x29e4e6[_0x158c77('0x1514')](_0x90ab99['monthFrom']+'-'+_0x90ab99['monthTo']):_0x29e4e6[_0x158c77('0x1514')](_0x90ab99['monthFrom']):_0x29e4e6[_0x158c77('0x1514')]('*'),_0x29e4e6[_0x158c77('0x45a')]();}}}function _0x49e223(){const _0x16a798=_0x406009;_0x90ab99['errors']=[],_0x90ab99[_0x16a798('0x277c')][_0x16a798('0x277c')]=_0x55c4d3(),_0x6fe8f1[_0x16a798('0x277c')][_0x16a798('0x9cc')](_0x90ab99[_0x16a798('0x277c')])['$promise'][_0x16a798('0x1166')](function(_0x38b26b){const _0x2a97f3=_0x16a798;_0x90ab99[_0x2a97f3('0x164e')][_0x2a97f3('0x1514')](_0x38b26b),_0x314f5d[_0x2a97f3('0x103b')]({'title':_0x2a97f3('0xf10'),'msg':_0x90ab99['interval'][_0x2a97f3('0x4f0')]?_0x90ab99[_0x2a97f3('0x277c')][_0x2a97f3('0x4f0')]+_0x2a97f3('0x1eda'):''}),_0x293919();})[_0x16a798('0x1a80')](function(_0x3c08cb){const _0x55396c=_0x16a798;console[_0x55396c('0xfc9')](_0x3c08cb),_0x90ab99[_0x55396c('0x61a')]=_0x3c08cb['data'][_0x55396c('0x61a')]||[{'message':_0x3c08cb['toString'](),'type':_0x55396c('0x1192')}];});}function _0x3d5c9a(){const _0x1f5982=_0x406009;_0x90ab99[_0x1f5982('0x61a')]=[],_0x90ab99[_0x1f5982('0x277c')][_0x1f5982('0x277c')]=_0x55c4d3(),_0x90ab99[_0x1f5982('0x277c')]['application']?(_0x90ab99[_0x1f5982('0x1345')]!==_0x1f5982('0x1480')&&(_0x90ab99[_0x1f5982('0x277c')][_0x1f5982('0x186f')]=null),_0x293919(_0x90ab99['interval'])):_0x6fe8f1['interval']['update']({'id':_0x90ab99['interval']['id']},_0x90ab99['interval'])['$promise'][_0x1f5982('0x1166')](function(_0x5b2bd9){const _0x543cf0=_0x1f5982,_0x5e67a0=_0x2cfb05()[_0x543cf0('0xc38')](_0x90ab99[_0x543cf0('0x164e')],{'id':_0x5b2bd9['id']});_0x5e67a0&&_0x2cfb05()['merge'](_0x5e67a0,_0x5b2bd9),_0x314f5d[_0x543cf0('0x103b')]({'title':_0x543cf0('0x1243'),'msg':_0x543cf0('0x1666')}),_0x293919();})[_0x1f5982('0x1a80')](function(_0x58ca9d){const _0x13e6ae=_0x1f5982;console[_0x13e6ae('0xfc9')](_0x58ca9d),_0x90ab99['errors']=_0x58ca9d[_0x13e6ae('0x25f4')][_0x13e6ae('0x61a')]||[{'message':_0x58ca9d[_0x13e6ae('0x1586')](),'type':_0x13e6ae('0x2725')}];});}function _0x293919(_0x22bc19){const _0x4df3f2=_0x406009;_0x24b374[_0x4df3f2('0x1197')](_0x22bc19);}}const _0x2945dd=_0x16ac53;_0x255c68['$inject']=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0xbc7'),_0x36e6f4('0x2085'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x255c68(_0x24b784,_0x127339,_0xca0fcc,_0x125e78,_0x542a1b,_0x219f0a,_0x3d14f6,_0x35339e){const _0x3892f9=_0x36e6f4,_0x517af9=this;_0x517af9[_0x3892f9('0x98')]=_0x3d14f6[_0x3892f9('0x26cd')](),_0x517af9[_0x3892f9('0x61a')]=[],_0x517af9['title']='FAX.EDIT_'+(_0x125e78['appType']||_0x125e78[_0x3892f9('0x746')])[_0x3892f9('0x1387')](),_0x517af9['noop']=angular[_0x3892f9('0x225f')](_0x125e78),_0x517af9[_0x3892f9('0x243c')]=_0x35339e,_0x517af9[_0x3892f9('0x128b')]={};if(_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x823')])switch(_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x83f')]?_0x517af9['noop'][_0x3892f9('0x83f')]['toLowerCase']():_0x517af9[_0x3892f9('0x2652')]['app'][_0x3892f9('0x2574')]()){case _0x3892f9('0x2853'):break;case _0x3892f9('0xded'):{const _0x417300=_0x517af9[_0x3892f9('0x2652')]['appdata'][_0x3892f9('0x25c8')](',');_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x7ca')]=_0x417300[0x0],_0x517af9['noop'][_0x3892f9('0xedb')]=_0x417300[0x1],_0x517af9[_0x3892f9('0x2652')]['welcomemessage']=_0x417300[_0x3892f9('0x233')](0x2,_0x417300['length'])[_0x3892f9('0x45a')](',');}break;case'dialogflowv2':{const _0x54a0d5=_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x823')]['split'](',');_0x517af9[_0x3892f9('0x2652')]['projectId']=_0x54a0d5[0x0],_0x517af9[_0x3892f9('0x2652')]['clientEmail']=_0x54a0d5[0x1],_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x170e')]=_0x54a0d5[0x2],_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0xedb')]=_0x54a0d5[0x3],_0x517af9['noop'][_0x3892f9('0x1634')]=_0x54a0d5[_0x3892f9('0x233')](0x4,_0x54a0d5[_0x3892f9('0x264b')])[_0x3892f9('0x45a')](',');}break;case _0x3892f9('0x86c'):{const _0x1386f6=_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x823')][_0x3892f9('0x25c8')](',');_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0xee6')]=_0x1386f6[0x0],_0x517af9['noop'][_0x3892f9('0x125')]=_0x1386f6[0x1],_0x517af9['noop']['lexregion']=_0x1386f6[0x2],_0x517af9['noop'][_0x3892f9('0x1ac4')]=_0x1386f6[0x3],_0x517af9[_0x3892f9('0x2652')]['welcomemessage']=_0x1386f6[_0x3892f9('0x233')](0x4,_0x1386f6['length'])['join'](',');}break;case _0x3892f9('0x1af7'):{const _0x4d0888=_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x823')][_0x3892f9('0x25c8')](',');_0x517af9['noop']['times']=isNaN(_0x4d0888[0x0])?_0x4d0888[0x0]:parseInt(_0x4d0888[0x0],0xa),_0x517af9['noop'][_0x3892f9('0x1640')]=_0x4d0888[_0x3892f9('0x233')](0x1,_0x4d0888[_0x3892f9('0x264b')])[_0x3892f9('0x45a')](',');}break;case _0x3892f9('0x1e70'):_0x517af9['noop'][_0x3892f9('0x1640')]=_0x517af9[_0x3892f9('0x2652')]['appdata'];break;case _0x3892f9('0xceb'):_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x4f0')]=_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x823')]['split']('=')[0x0],_0x517af9['noop'][_0x3892f9('0x18e0')]=_0x517af9['noop'][_0x3892f9('0x823')][_0x3892f9('0x25c8')]('=')[0x1];break;case _0x3892f9('0x1034'):_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x2588')]=_0x517af9[_0x3892f9('0x2652')]['appdata'];break;default:{const _0x3277de=_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x823')][_0x3892f9('0x25c8')](',');_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x18e0')]=_0x2cfb05()[_0x3892f9('0x1081')](_0x3277de[0x0])?_0x3277de[0x0]:isNaN(_0x3277de[0x0])?_0x3277de[0x0]:parseInt(_0x3277de[0x0],0xa);}break;}else{}_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x1345')]&&_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x1345')][_0x3892f9('0x2574')]()===_0x3892f9('0x587')&&_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x83f')][_0x3892f9('0x2574')]()==='outbounddial'&&(_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x265a')]=_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x2026')]?_0x517af9['noop'][_0x3892f9('0x2026')][_0x3892f9('0x25c8')]('$')[0x0]:undefined,_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x1f02')]=_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x992')]?_0x3892f9('0xa4c')+_0x517af9[_0x3892f9('0x2652')][_0x3892f9('0x992')]:undefined);_0x517af9[_0x3892f9('0x1f31')]=_0x1f4c65,_0x517af9[_0x3892f9('0x24a0')]=_0x31366d;function _0x1f4c65(){const _0x128382=_0x3892f9;_0x517af9[_0x128382('0x61a')]=[];const _0x24ae3b=[];_0x517af9[_0x128382('0x2652')][_0x128382('0x1345')]&&_0x517af9[_0x128382('0x2652')][_0x128382('0x1345')][_0x128382('0x2574')]()===_0x128382('0x587')&&_0x517af9[_0x128382('0x2652')][_0x128382('0x83f')]==='outboundDial'&&(_0x517af9[_0x128382('0x2652')]['phone']=_0x542a1b[_0x128382('0x2848')]?(_0x517af9[_0x128382('0x2652')]['prefix']||'')+_0x128382('0x881')+_0x542a1b['cutdigits']+'}':(_0x517af9[_0x128382('0x2652')][_0x128382('0x265a')]||'')+'${EXTEN}',_0x542a1b['recordingFormat']!=='none'?_0x517af9['noop'][_0x128382('0xd39')][_0x128382('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x517af9[_0x128382('0x2652')][_0x128382('0xd39')]+='U(xcally-mixmonitor-context)'):_0x517af9[_0x128382('0x2652')]['options']=_0x517af9[_0x128382('0x2652')]['options'][_0x128382('0xf3')](_0x128382('0x1059'),''));if(_0x517af9['noop'][_0x128382('0x83f')]&&_0x517af9['noop'][_0x128382('0x83f')]==='custom'){}else switch((_0x517af9[_0x128382('0x2652')][_0x128382('0x746')]||_0x517af9[_0x128382('0x2652')]['appType'])[_0x128382('0x2574')]()){case _0x128382('0xceb'):_0x517af9[_0x128382('0x2652')][_0x128382('0x823')]=_0x517af9['noop']['name']+'='+_0x517af9[_0x128382('0x2652')][_0x128382('0x18e0')];break;case _0x128382('0x2853'):break;default:_0x24ae3b[0x0]=_0x517af9[_0x128382('0x2652')][_0x128382('0x18e0')],_0x517af9[_0x128382('0x2652')]['appdata']=_0x24ae3b[_0x128382('0x45a')](',');}_0x31366d(_0x517af9['noop']);}function _0x31366d(_0x3df97e){const _0x2091e9=_0x3892f9;_0x24b784[_0x2091e9('0x1197')](_0x3df97e);}}const _0x4860ee=_0x255c68;_0x4b3c17[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0xbc7'),_0x36e6f4('0x2085'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x4b3c17(_0x16cf32,_0x61fdcd,_0x274408,_0x4dd0b6,_0x380600,_0x1de287,_0x237f4b,_0x19051d){const _0x577492=_0x36e6f4,_0x3241ba=this;_0x3241ba['currentUser']=_0x237f4b[_0x577492('0x26cd')](),_0x3241ba[_0x577492('0x61a')]=[],_0x3241ba[_0x577492('0xcdc')]=_0x577492('0x156b')+(_0x4dd0b6['appType']||_0x4dd0b6['app'])[_0x577492('0x1387')](),_0x3241ba[_0x577492('0x1d3e')]=angular[_0x577492('0x225f')](_0x4dd0b6),_0x3241ba['crudPermissions']=_0x19051d,_0x3241ba['hasModulePermissions']={};if(_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x823')])switch(_0x3241ba['queue'][_0x577492('0x83f')]?_0x3241ba[_0x577492('0x1d3e')]['appType'][_0x577492('0x2574')]():_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x746')][_0x577492('0x2574')]()){case _0x577492('0x2853'):break;case _0x577492('0xded'):{const _0x52e722=_0x3241ba['queue'][_0x577492('0x823')][_0x577492('0x25c8')](',');_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x7ca')]=_0x52e722[0x0],_0x3241ba['queue'][_0x577492('0xedb')]=_0x52e722[0x1],_0x3241ba[_0x577492('0x1d3e')]['welcomemessage']=_0x52e722[_0x577492('0x233')](0x2,_0x52e722[_0x577492('0x264b')])['join'](',');}break;case _0x577492('0x1636'):{const _0x9b2dbe=_0x3241ba[_0x577492('0x1d3e')]['appdata'][_0x577492('0x25c8')](',');_0x3241ba['queue']['projectId']=_0x9b2dbe[0x0],_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x27f3')]=_0x9b2dbe[0x1],_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x170e')]=_0x9b2dbe[0x2],_0x3241ba[_0x577492('0x1d3e')][_0x577492('0xedb')]=_0x9b2dbe[0x3],_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x1634')]=_0x9b2dbe['slice'](0x4,_0x9b2dbe[_0x577492('0x264b')])[_0x577492('0x45a')](',');}break;case'amazonlex':{const _0x488de4=_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x823')][_0x577492('0x25c8')](',');_0x3241ba[_0x577492('0x1d3e')][_0x577492('0xee6')]=_0x488de4[0x0],_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x125')]=_0x488de4[0x1],_0x3241ba[_0x577492('0x1d3e')]['lexregion']=_0x488de4[0x2],_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x1ac4')]=_0x488de4[0x3],_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x1634')]=_0x488de4[_0x577492('0x233')](0x4,_0x488de4[_0x577492('0x264b')])[_0x577492('0x45a')](',');}break;case _0x577492('0x1af7'):{const _0x5e57a8=_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x823')]['split'](',');_0x3241ba['queue'][_0x577492('0x265e')]=isNaN(_0x5e57a8[0x0])?_0x5e57a8[0x0]:parseInt(_0x5e57a8[0x0],0xa),_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x1640')]=_0x5e57a8[_0x577492('0x233')](0x1,_0x5e57a8[_0x577492('0x264b')])['join'](',');}break;case _0x577492('0x1e70'):_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x1640')]=_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x823')];break;case _0x577492('0xceb'):_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x4f0')]=_0x3241ba['queue'][_0x577492('0x823')]['split']('=')[0x0],_0x3241ba['queue'][_0x577492('0x18e0')]=_0x3241ba['queue'][_0x577492('0x823')]['split']('=')[0x1];break;case'agi':_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x2588')]=_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x823')];break;default:{const _0x9b1f6e=_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x823')][_0x577492('0x25c8')](',');_0x3241ba['queue']['queue']=_0x2cfb05()[_0x577492('0x1081')](_0x9b1f6e[0x0])?_0x9b1f6e[0x0]:isNaN(_0x9b1f6e[0x0])?_0x9b1f6e[0x0]:parseInt(_0x9b1f6e[0x0],0xa),_0x3241ba[_0x577492('0x1d3e')]['timeout']=_0x2cfb05()['isEmpty'](_0x9b1f6e[0x1])?_0x9b1f6e[0x1]:isNaN(_0x9b1f6e[0x1])?_0x9b1f6e[0x1]:parseInt(_0x9b1f6e[0x1],0xa);}break;}else _0x3241ba[_0x577492('0x1d3e')]['queue']=0x12c,_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x651')]=0x12c;_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x1345')]&&_0x3241ba['queue'][_0x577492('0x1345')]['toLowerCase']()===_0x577492('0x587')&&_0x3241ba['queue'][_0x577492('0x83f')][_0x577492('0x2574')]()===_0x577492('0x2884')&&(_0x3241ba[_0x577492('0x1d3e')]['prefix']=_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x2026')]?_0x3241ba[_0x577492('0x1d3e')]['phone'][_0x577492('0x25c8')]('$')[0x0]:undefined,_0x3241ba[_0x577492('0x1d3e')][_0x577492('0x1f02')]=_0x3241ba['queue'][_0x577492('0x992')]?_0x577492('0xa4c')+_0x3241ba[_0x577492('0x1d3e')]['callerID']:undefined);_0x3241ba['saveFaxAccountApp']=_0x515532,_0x3241ba['closeDialog']=_0xa5ab60,_0x237f4b[_0x577492('0x1ac6')](_0x577492('0xa7c'))?_0x1de287[_0x577492('0x1a5b')][_0x577492('0xd83')]({'fields':'id,name,type','sort':_0x577492('0x4f0'),'nolimit':_0x577492('0xf3b')})[_0x577492('0xa44')]['then'](function(_0x1bba29){const _0x144414=_0x577492;_0x3241ba[_0x144414('0x7a7')]=_0x1bba29[_0x144414('0x269a')]||[];})[_0x577492('0x1a80')](function(_0x5f3df0){const _0x117b94=_0x577492;_0x274408[_0x117b94('0xfc9')]({'title':_0x5f3df0[_0x117b94('0x52d')]?'API:'+_0x5f3df0[_0x117b94('0x52d')]+_0x117b94('0x11e1')+_0x5f3df0['statusText']:'SYSTEM:GET_QUEUES','msg':_0x5f3df0[_0x117b94('0x25f4')]?JSON[_0x117b94('0xbac')](_0x5f3df0['data']):_0x5f3df0[_0x117b94('0x1586')]()});}):_0x1de287[_0x577492('0x1a5b')]['get']({'fields':_0x577492('0x1c09'),'sort':_0x577492('0x4f0'),'nolimit':_0x577492('0xf3b')})[_0x577492('0xa44')][_0x577492('0x1166')](function(_0x18a02e){const _0xd19507=_0x577492;_0x3241ba['queues']=_0x18a02e[_0xd19507('0x269a')]||[];})['then'](function(){const _0x3be14a=_0x577492;return _0x1de287[_0x3be14a('0x17aa')][_0x3be14a('0xd83')]({'userProfileId':_0x3241ba[_0x3be14a('0x98')][_0x3be14a('0xb86')],'sectionId':0x385})['$promise'];})[_0x577492('0x1166')](function(_0xf3082e){const _0x3ae2c9=_0x577492,_0x3f9498=_0xf3082e&&_0xf3082e['rows']?_0xf3082e[_0x3ae2c9('0x269a')][0x0]:null;if(!_0x3f9498){const _0x45cdfc=[];let _0x170708=null;_0x3241ba['queue']&&(_0x170708=_0x2cfb05()['find'](_0x3241ba[_0x3ae2c9('0x7a7')],{'name':_0x3241ba['queue'][_0x3ae2c9('0x1d3e')]}));for(let _0x2c6ca1=0x0;_0x2c6ca1<_0x3241ba[_0x3ae2c9('0x7a7')][_0x3ae2c9('0x264b')];_0x2c6ca1++){_0x170708&&_0x3241ba['queues'][_0x2c6ca1]['id']===_0x170708['id']&&(_0x3241ba[_0x3ae2c9('0x7a7')][_0x2c6ca1][_0x3ae2c9('0x2378')]=![],_0x45cdfc[_0x3ae2c9('0x1514')](_0x3241ba['queues'][_0x2c6ca1]));}_0x3241ba[_0x3ae2c9('0x7a7')]=_0x45cdfc;}else{if(!_0x3f9498[_0x3ae2c9('0x1a2b')])return _0x1de287[_0x3ae2c9('0x4b5')][_0x3ae2c9('0xd83')]({'sectionId':_0x3f9498['id']})[_0x3ae2c9('0xa44')][_0x3ae2c9('0x1166')](function(_0x17b8b2){const _0x48c2aa=_0x3ae2c9,_0x3ae00a=_0x2cfb05()[_0x48c2aa('0x2563')](_0x17b8b2['rows'],function(_0x2950a7){const _0x4dbc4a=_0x48c2aa;return _0x2cfb05()[_0x4dbc4a('0xc38')](_0x3241ba[_0x4dbc4a('0x7a7')],{'id':_0x2950a7[_0x4dbc4a('0x24e8')]});});let _0x55cec6=null;_0x3241ba[_0x48c2aa('0x1d3e')]&&(_0x55cec6=_0x2cfb05()['find'](_0x3241ba[_0x48c2aa('0x7a7')],{'name':_0x3241ba[_0x48c2aa('0x1d3e')][_0x48c2aa('0x1d3e')]}));if(_0x55cec6&&!_0x2cfb05()[_0x48c2aa('0x1798')](_0x3ae00a,['id',_0x55cec6['id']])){const _0x56029c=_0x2cfb05()[_0x48c2aa('0xc38')](_0x3241ba[_0x48c2aa('0x7a7')],{'id':_0x55cec6['id']});_0x56029c[_0x48c2aa('0x2378')]=![],_0x3ae00a[_0x48c2aa('0x1514')](_0x56029c);}_0x3241ba[_0x48c2aa('0x7a7')]=_0x3ae00a;});}})[_0x577492('0x1a80')](function(_0x39f462){const _0x1a078e=_0x577492;_0x274408[_0x1a078e('0xfc9')]({'title':_0x39f462[_0x1a078e('0x52d')]?'API:'+_0x39f462[_0x1a078e('0x52d')]+'\x20-\x20'+_0x39f462[_0x1a078e('0xe1b')]:_0x1a078e('0x1dd7'),'msg':_0x39f462['data']?JSON[_0x1a078e('0xbac')](_0x39f462[_0x1a078e('0x25f4')]):_0x39f462[_0x1a078e('0x1586')]()});});function _0x515532(){const _0x2efa06=_0x577492;_0x3241ba[_0x2efa06('0x61a')]=[];const _0x463317=[];_0x3241ba[_0x2efa06('0x1d3e')][_0x2efa06('0x1345')]&&_0x3241ba[_0x2efa06('0x1d3e')][_0x2efa06('0x1345')][_0x2efa06('0x2574')]()==='outbound'&&_0x3241ba[_0x2efa06('0x1d3e')][_0x2efa06('0x83f')]===_0x2efa06('0x867')&&(_0x3241ba['queue']['phone']=_0x380600['cutdigits']?(_0x3241ba['queue'][_0x2efa06('0x265a')]||'')+_0x2efa06('0x881')+_0x380600['cutdigits']+'}':(_0x3241ba['queue'][_0x2efa06('0x265a')]||'')+'${EXTEN}',_0x380600['recordingFormat']!==_0x2efa06('0x192')?_0x3241ba[_0x2efa06('0x1d3e')][_0x2efa06('0xd39')][_0x2efa06('0x2379')](_0x2efa06('0x1059'))<0x0&&(_0x3241ba[_0x2efa06('0x1d3e')]['options']+=_0x2efa06('0x1059')):_0x3241ba[_0x2efa06('0x1d3e')][_0x2efa06('0xd39')]=_0x3241ba[_0x2efa06('0x1d3e')]['options'][_0x2efa06('0xf3')](_0x2efa06('0x1059'),''));const _0x17ba08=_0x2cfb05()[_0x2efa06('0xc38')](_0x3241ba[_0x2efa06('0x7a7')],{'name':_0x3241ba['queue'][_0x2efa06('0x1d3e')]});_0x17ba08&&(_0x3241ba['queue'][_0x2cfb05()[_0x2efa06('0x92c')](_0x2efa06('0x1fc7'))+_0x2efa06('0x1366')]=_0x17ba08['id']);if(_0x3241ba['queue']['appType']&&_0x3241ba[_0x2efa06('0x1d3e')][_0x2efa06('0x83f')]===_0x2efa06('0x2853')){}else switch((_0x3241ba[_0x2efa06('0x1d3e')][_0x2efa06('0x746')]||_0x3241ba['queue']['appType'])[_0x2efa06('0x2574')]()){case _0x2efa06('0xceb'):_0x3241ba['queue']['appdata']=_0x3241ba[_0x2efa06('0x1d3e')][_0x2efa06('0x4f0')]+'='+_0x3241ba[_0x2efa06('0x1d3e')]['value'];break;case _0x2efa06('0x2853'):break;default:_0x463317[0x0]=_0x3241ba[_0x2efa06('0x1d3e')]['queue'],_0x463317[0x1]=_0x3241ba['queue'][_0x2efa06('0x651')],_0x3241ba['queue']['appdata']=_0x463317[_0x2efa06('0x45a')](',');}_0xa5ab60(_0x3241ba['queue']);}function _0xa5ab60(_0xb4934e){const _0x1e5c29=_0x577492;_0x16cf32[_0x1e5c29('0x1197')](_0xb4934e);}}const _0x32cdc9=_0x4b3c17;_0x3c514d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0xbc7'),_0x36e6f4('0x2085'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x3c514d(_0x3e2284,_0x10904b,_0x5e56a6,_0x4cdf04,_0x5cb9b1,_0x679a33,_0x4cd545,_0x1f9d16){const _0x507245=_0x36e6f4,_0x1ba2b0=this;_0x1ba2b0[_0x507245('0x98')]=_0x4cd545[_0x507245('0x26cd')](),_0x1ba2b0[_0x507245('0x61a')]=[],_0x1ba2b0[_0x507245('0xcdc')]=_0x507245('0x156b')+(_0x4cdf04[_0x507245('0x83f')]||_0x4cdf04[_0x507245('0x746')])[_0x507245('0x1387')](),_0x1ba2b0[_0x507245('0x1c2b')]=angular[_0x507245('0x225f')](_0x4cdf04),_0x1ba2b0[_0x507245('0x243c')]=_0x1f9d16,_0x1ba2b0[_0x507245('0x128b')]={};if(_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x823')])switch(_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x83f')]?_0x1ba2b0['system'][_0x507245('0x83f')][_0x507245('0x2574')]():_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x746')]['toLowerCase']()){case _0x507245('0x2853'):break;case _0x507245('0xded'):{const _0x5f37f1=_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x823')][_0x507245('0x25c8')](',');_0x1ba2b0['system'][_0x507245('0x7ca')]=_0x5f37f1[0x0],_0x1ba2b0['system'][_0x507245('0xedb')]=_0x5f37f1[0x1],_0x1ba2b0['system'][_0x507245('0x1634')]=_0x5f37f1[_0x507245('0x233')](0x2,_0x5f37f1['length'])[_0x507245('0x45a')](',');}break;case _0x507245('0x1636'):{const _0x11d271=_0x1ba2b0[_0x507245('0x1c2b')]['appdata']['split'](',');_0x1ba2b0['system'][_0x507245('0x1b0a')]=_0x11d271[0x0],_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x27f3')]=_0x11d271[0x1],_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x170e')]=_0x11d271[0x2],_0x1ba2b0[_0x507245('0x1c2b')]['language']=_0x11d271[0x3],_0x1ba2b0['system']['welcomemessage']=_0x11d271[_0x507245('0x233')](0x4,_0x11d271[_0x507245('0x264b')])[_0x507245('0x45a')](',');}break;case _0x507245('0x86c'):{const _0x31a913=_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x823')][_0x507245('0x25c8')](',');_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0xee6')]=_0x31a913[0x0],_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x125')]=_0x31a913[0x1],_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x25a2')]=_0x31a913[0x2],_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x1ac4')]=_0x31a913[0x3],_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x1634')]=_0x31a913[_0x507245('0x233')](0x4,_0x31a913[_0x507245('0x264b')])[_0x507245('0x45a')](',');}break;case _0x507245('0x1af7'):{const _0x5ad72a=_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x823')][_0x507245('0x25c8')](',');_0x1ba2b0[_0x507245('0x1c2b')]['times']=isNaN(_0x5ad72a[0x0])?_0x5ad72a[0x0]:parseInt(_0x5ad72a[0x0],0xa),_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x1640')]=_0x5ad72a[_0x507245('0x233')](0x1,_0x5ad72a[_0x507245('0x264b')])[_0x507245('0x45a')](',');}break;case _0x507245('0x1e70'):_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x1640')]=_0x1ba2b0[_0x507245('0x1c2b')]['appdata'];break;case _0x507245('0xceb'):_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x4f0')]=_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x823')][_0x507245('0x25c8')]('=')[0x0],_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x18e0')]=_0x1ba2b0['system'][_0x507245('0x823')]['split']('=')[0x1];break;case _0x507245('0x1034'):_0x1ba2b0[_0x507245('0x1c2b')]['project']=_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x823')];break;default:{const _0x1ea3a2=_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x823')][_0x507245('0x25c8')](',');_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x187')]=_0x2cfb05()[_0x507245('0x1081')](_0x1ea3a2[0x0])?_0x1ea3a2[0x0]:isNaN(_0x1ea3a2[0x0])?_0x1ea3a2[0x0]:parseInt(_0x1ea3a2[0x0],0xa),_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x734')]=_0x2cfb05()[_0x507245('0x1081')](_0x1ea3a2[0x1])?_0x1ea3a2[0x1]:isNaN(_0x1ea3a2[0x1])?_0x1ea3a2[0x1]:parseInt(_0x1ea3a2[0x1],0xa);}}else _0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x734')]='';_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x1345')]&&_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x1345')][_0x507245('0x2574')]()===_0x507245('0x587')&&_0x1ba2b0['system'][_0x507245('0x83f')][_0x507245('0x2574')]()===_0x507245('0x2884')&&(_0x1ba2b0[_0x507245('0x1c2b')]['prefix']=_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x2026')]?_0x1ba2b0[_0x507245('0x1c2b')][_0x507245('0x2026')][_0x507245('0x25c8')]('$')[0x0]:undefined,_0x1ba2b0[_0x507245('0x1c2b')]['callerId']=_0x1ba2b0[_0x507245('0x1c2b')]['callerID']?_0x507245('0xa4c')+_0x1ba2b0[_0x507245('0x1c2b')]['callerID']:undefined);_0x1ba2b0[_0x507245('0x1f31')]=_0xcb4306,_0x1ba2b0[_0x507245('0x24a0')]=_0xc144da,_0x4cd545[_0x507245('0x1ac6')](_0x507245('0xa7c'))?_0x679a33['variable']['get']({'fields':_0x507245('0x1776'),'sort':'name','nolimit':'true'})[_0x507245('0xa44')][_0x507245('0x1166')](function(_0x34846a){const _0x377504=_0x507245;_0x1ba2b0[_0x377504('0x57a')]=_0x34846a[_0x377504('0x269a')]||[];})['catch'](function(_0x3b10e9){const _0xa065f5=_0x507245;_0x5e56a6[_0xa065f5('0xfc9')]({'title':_0x3b10e9[_0xa065f5('0x52d')]?_0xa065f5('0x1e21')+_0x3b10e9[_0xa065f5('0x52d')]+_0xa065f5('0x11e1')+_0x3b10e9[_0xa065f5('0xe1b')]:_0xa065f5('0xcf8'),'msg':_0x3b10e9[_0xa065f5('0x25f4')]?JSON[_0xa065f5('0xbac')](_0x3b10e9[_0xa065f5('0x25f4')]):_0x3b10e9[_0xa065f5('0x1586')]()});}):_0x679a33[_0x507245('0x734')][_0x507245('0xd83')]({'fields':_0x507245('0x1776'),'sort':_0x507245('0x4f0'),'nolimit':_0x507245('0xf3b')})[_0x507245('0xa44')]['then'](function(_0x23cdba){_0x1ba2b0['variables']=_0x23cdba['rows']||[];})['then'](function(){const _0x535982=_0x507245;return _0x679a33['userProfileSection'][_0x535982('0xd83')]({'userProfileId':_0x1ba2b0['currentUser'][_0x535982('0xb86')],'sectionId':0x3f4})[_0x535982('0xa44')];})[_0x507245('0x1166')](function(_0x4f39ed){const _0x570a69=_0x507245,_0xcbafde=_0x4f39ed&&_0x4f39ed[_0x570a69('0x269a')]?_0x4f39ed[_0x570a69('0x269a')][0x0]:null;if(!_0xcbafde){const _0x160490=[];let _0x3bcd5f=null;_0x1ba2b0[_0x570a69('0x1c2b')]&&(_0x3bcd5f=_0x2cfb05()['find'](_0x1ba2b0[_0x570a69('0x57a')],{'name':_0x1ba2b0[_0x570a69('0x1c2b')][_0x570a69('0x734')]}));for(let _0x3a498f=0x0;_0x3a498f<_0x1ba2b0['variables'][_0x570a69('0x264b')];_0x3a498f++){_0x3bcd5f&&_0x1ba2b0[_0x570a69('0x57a')][_0x3a498f]['id']===_0x3bcd5f['id']&&(_0x1ba2b0[_0x570a69('0x57a')][_0x3a498f][_0x570a69('0x2378')]=![],_0x160490[_0x570a69('0x1514')](_0x1ba2b0['variables'][_0x3a498f]));}_0x1ba2b0[_0x570a69('0x57a')]=_0x160490;}else{if(!_0xcbafde[_0x570a69('0x1a2b')])return _0x679a33[_0x570a69('0x4b5')]['get']({'sectionId':_0xcbafde['id']})['$promise']['then'](function(_0x54affa){const _0x404251=_0x570a69,_0x5cf2a8=_0x2cfb05()['map'](_0x54affa[_0x404251('0x269a')],function(_0x3b7f66){const _0x43ffbd=_0x404251;return _0x2cfb05()[_0x43ffbd('0xc38')](_0x1ba2b0[_0x43ffbd('0x57a')],{'id':_0x3b7f66[_0x43ffbd('0x24e8')]});});let _0x58efc8=null;_0x1ba2b0[_0x404251('0x1c2b')]&&(_0x58efc8=_0x2cfb05()[_0x404251('0xc38')](_0x1ba2b0[_0x404251('0x57a')],{'name':_0x1ba2b0[_0x404251('0x1c2b')]['variable']}));if(_0x58efc8&&!_0x2cfb05()[_0x404251('0x1798')](_0x5cf2a8,['id',_0x58efc8['id']])){const _0x18f0b8=_0x2cfb05()[_0x404251('0xc38')](_0x1ba2b0['variables'],{'id':_0x58efc8['id']});_0x18f0b8[_0x404251('0x2378')]=![],_0x5cf2a8[_0x404251('0x1514')](_0x18f0b8);}_0x1ba2b0[_0x404251('0x57a')]=_0x5cf2a8;});}})[_0x507245('0x1a80')](function(_0x23a692){const _0x3783f6=_0x507245;_0x5e56a6[_0x3783f6('0xfc9')]({'title':_0x23a692[_0x3783f6('0x52d')]?_0x3783f6('0x1e21')+_0x23a692[_0x3783f6('0x52d')]+_0x3783f6('0x11e1')+_0x23a692['statusText']:_0x3783f6('0x2644'),'msg':_0x23a692[_0x3783f6('0x25f4')]?JSON[_0x3783f6('0xbac')](_0x23a692[_0x3783f6('0x25f4')]):_0x23a692[_0x3783f6('0x1586')]()});});function _0xcb4306(){const _0xf9a1ca=_0x507245;_0x1ba2b0['errors']=[];const _0x512b71=[];_0x1ba2b0['system'][_0xf9a1ca('0x1345')]&&_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0x1345')]['toLowerCase']()===_0xf9a1ca('0x587')&&_0x1ba2b0[_0xf9a1ca('0x1c2b')]['appType']==='outboundDial'&&(_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0x2026')]=_0x5cb9b1[_0xf9a1ca('0x2848')]?(_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0x265a')]||'')+_0xf9a1ca('0x881')+_0x5cb9b1[_0xf9a1ca('0x2848')]+'}':(_0x1ba2b0[_0xf9a1ca('0x1c2b')]['prefix']||'')+'${EXTEN}',_0x5cb9b1[_0xf9a1ca('0x28cb')]!==_0xf9a1ca('0x192')?_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0xd39')][_0xf9a1ca('0x2379')](_0xf9a1ca('0x1059'))<0x0&&(_0x1ba2b0[_0xf9a1ca('0x1c2b')]['options']+=_0xf9a1ca('0x1059')):_0x1ba2b0[_0xf9a1ca('0x1c2b')]['options']=_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0xd39')][_0xf9a1ca('0xf3')](_0xf9a1ca('0x1059'),''));if(_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0x83f')]&&_0x1ba2b0[_0xf9a1ca('0x1c2b')]['appType']==='custom'){}else switch((_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0x746')]||_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0x83f')])[_0xf9a1ca('0x2574')]()){case _0xf9a1ca('0xceb'):_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0x823')]=_0x1ba2b0[_0xf9a1ca('0x1c2b')]['name']+'='+_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0x18e0')];break;case'custom':break;default:_0x512b71[0x0]=_0x1ba2b0[_0xf9a1ca('0x1c2b')]['command'],_0x512b71[0x1]=_0x1ba2b0[_0xf9a1ca('0x1c2b')][_0xf9a1ca('0x734')],_0x1ba2b0[_0xf9a1ca('0x1c2b')]['appdata']=_0x512b71['join'](',');}_0xc144da(_0x1ba2b0[_0xf9a1ca('0x1c2b')]);}function _0xc144da(_0x3c5673){const _0x30f559=_0x507245;_0x3e2284[_0x30f559('0x1197')](_0x3c5673);}}const _0x369b1b=_0x3c514d;_0x977fc1[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),'faxAccountApp',_0x36e6f4('0x2085'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x977fc1(_0x2372cb,_0x25149d,_0x47bd2e,_0x207abe,_0x5a417d,_0x536c21,_0x4b195d,_0xa6d9ff){const _0xbcbfb7=_0x36e6f4,_0x3f143c=this;_0x3f143c[_0xbcbfb7('0x98')]=_0x4b195d[_0xbcbfb7('0x26cd')](),_0x3f143c[_0xbcbfb7('0x61a')]=[],_0x3f143c[_0xbcbfb7('0xcdc')]=_0xbcbfb7('0x156b')+(_0x207abe[_0xbcbfb7('0x83f')]||_0x207abe[_0xbcbfb7('0x746')])['toUpperCase'](),_0x3f143c['tag']=angular[_0xbcbfb7('0x225f')](_0x207abe),_0x3f143c[_0xbcbfb7('0x243c')]=_0xa6d9ff,_0x3f143c['hasModulePermissions']={};if(_0x3f143c['tag'][_0xbcbfb7('0x823')])switch(_0x3f143c[_0xbcbfb7('0x1446')]['appType']?_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x83f')][_0xbcbfb7('0x2574')]():_0x3f143c['tag'][_0xbcbfb7('0x746')][_0xbcbfb7('0x2574')]()){case'custom':break;case'dialogflow':{const _0x2cd924=_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x823')][_0xbcbfb7('0x25c8')](',');_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x7ca')]=_0x2cd924[0x0],_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0xedb')]=_0x2cd924[0x1],_0x3f143c['tag'][_0xbcbfb7('0x1634')]=_0x2cd924[_0xbcbfb7('0x233')](0x2,_0x2cd924[_0xbcbfb7('0x264b')])['join'](',');}break;case _0xbcbfb7('0x1636'):{const _0x3f7214=_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x823')][_0xbcbfb7('0x25c8')](',');_0x3f143c[_0xbcbfb7('0x1446')]['projectId']=_0x3f7214[0x0],_0x3f143c[_0xbcbfb7('0x1446')]['clientEmail']=_0x3f7214[0x1],_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x170e')]=_0x3f7214[0x2],_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0xedb')]=_0x3f7214[0x3],_0x3f143c[_0xbcbfb7('0x1446')]['welcomemessage']=_0x3f7214['slice'](0x4,_0x3f7214[_0xbcbfb7('0x264b')])[_0xbcbfb7('0x45a')](',');}break;case _0xbcbfb7('0x86c'):{const _0x49a501=_0x3f143c[_0xbcbfb7('0x1446')]['appdata'][_0xbcbfb7('0x25c8')](',');_0x3f143c[_0xbcbfb7('0x1446')]['accesskeyid']=_0x49a501[0x0],_0x3f143c['tag'][_0xbcbfb7('0x125')]=_0x49a501[0x1],_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x25a2')]=_0x49a501[0x2],_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x1ac4')]=_0x49a501[0x3],_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x1634')]=_0x49a501[_0xbcbfb7('0x233')](0x4,_0x49a501[_0xbcbfb7('0x264b')])[_0xbcbfb7('0x45a')](',');}break;case _0xbcbfb7('0x1af7'):{const _0x3c53ed=_0x3f143c[_0xbcbfb7('0x1446')]['appdata']['split'](',');_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x265e')]=isNaN(_0x3c53ed[0x0])?_0x3c53ed[0x0]:parseInt(_0x3c53ed[0x0],0xa),_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x1640')]=_0x3c53ed[_0xbcbfb7('0x233')](0x1,_0x3c53ed[_0xbcbfb7('0x264b')])[_0xbcbfb7('0x45a')](',');}break;case _0xbcbfb7('0x1e70'):_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x1640')]=_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x823')];break;case _0xbcbfb7('0xceb'):_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x4f0')]=_0x3f143c['tag'][_0xbcbfb7('0x823')][_0xbcbfb7('0x25c8')]('=')[0x0],_0x3f143c['tag'][_0xbcbfb7('0x18e0')]=_0x3f143c['tag'][_0xbcbfb7('0x823')][_0xbcbfb7('0x25c8')]('=')[0x1];break;case _0xbcbfb7('0x1034'):_0x3f143c['tag'][_0xbcbfb7('0x2588')]=_0x3f143c['tag'][_0xbcbfb7('0x823')];break;default:{const _0x33d158=_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x823')][_0xbcbfb7('0x25c8')](',');_0x3f143c['tag'][_0xbcbfb7('0x1446')]=_0x2cfb05()[_0xbcbfb7('0x1081')](_0x33d158[0x0])?_0x33d158[0x0]:isNaN(_0x33d158[0x0])?_0x33d158[0x0]:parseInt(_0x33d158[0x0],0xa);}break;}else{}_0x3f143c['tag']['type']&&_0x3f143c[_0xbcbfb7('0x1446')]['type'][_0xbcbfb7('0x2574')]()==='outbound'&&_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x83f')][_0xbcbfb7('0x2574')]()===_0xbcbfb7('0x2884')&&(_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x265a')]=_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x2026')]?_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x2026')][_0xbcbfb7('0x25c8')]('$')[0x0]:undefined,_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x1f02')]=_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x992')]?_0xbcbfb7('0xa4c')+_0x3f143c[_0xbcbfb7('0x1446')][_0xbcbfb7('0x992')]:undefined);_0x3f143c[_0xbcbfb7('0x1f31')]=_0x5a28ab,_0x3f143c[_0xbcbfb7('0x24a0')]=_0x5ce24f,_0x4b195d[_0xbcbfb7('0x1ac6')]('admin')?_0x536c21[_0xbcbfb7('0x1446')]['get']({'fields':_0xbcbfb7('0x1776'),'sort':'name','nolimit':_0xbcbfb7('0xf3b')})[_0xbcbfb7('0xa44')]['then'](function(_0xd8595c){const _0xa293c2=_0xbcbfb7;_0x3f143c[_0xa293c2('0xb38')]=_0xd8595c[_0xa293c2('0x269a')]||[];})['catch'](function(_0x5e9f04){const _0x33170a=_0xbcbfb7;_0x47bd2e[_0x33170a('0xfc9')]({'title':_0x5e9f04[_0x33170a('0x52d')]?_0x33170a('0x1e21')+_0x5e9f04[_0x33170a('0x52d')]+_0x33170a('0x11e1')+_0x5e9f04[_0x33170a('0xe1b')]:_0x33170a('0x402'),'msg':_0x5e9f04[_0x33170a('0x25f4')]?JSON[_0x33170a('0xbac')](_0x5e9f04['data']):_0x5e9f04[_0x33170a('0x1586')]()});}):_0x536c21['tag'][_0xbcbfb7('0xd83')]({'fields':_0xbcbfb7('0x1776'),'sort':_0xbcbfb7('0x4f0'),'nolimit':_0xbcbfb7('0xf3b')})[_0xbcbfb7('0xa44')]['then'](function(_0x3bca95){const _0x119006=_0xbcbfb7;_0x3f143c[_0x119006('0xb38')]=_0x3bca95[_0x119006('0x269a')]||[];})[_0xbcbfb7('0x1166')](function(){const _0x50cf81=_0xbcbfb7;return _0x536c21[_0x50cf81('0x17aa')][_0x50cf81('0xd83')]({'userProfileId':_0x3f143c[_0x50cf81('0x98')][_0x50cf81('0xb86')],'sectionId':0x3f0})[_0x50cf81('0xa44')];})['then'](function(_0x6165a1){const _0x1c4ddd=_0xbcbfb7,_0x258f33=_0x6165a1&&_0x6165a1[_0x1c4ddd('0x269a')]?_0x6165a1[_0x1c4ddd('0x269a')][0x0]:null;if(!_0x258f33){const _0x375c0c=[];let _0x175d40=null;_0x3f143c['tag']&&(_0x175d40=_0x2cfb05()['find'](_0x3f143c[_0x1c4ddd('0xb38')],{'name':_0x3f143c[_0x1c4ddd('0x1446')][_0x1c4ddd('0x1446')]}));for(let _0x22fe06=0x0;_0x22fe06<_0x3f143c[_0x1c4ddd('0xb38')][_0x1c4ddd('0x264b')];_0x22fe06++){_0x175d40&&_0x3f143c[_0x1c4ddd('0xb38')][_0x22fe06]['id']===_0x175d40['id']&&(_0x3f143c[_0x1c4ddd('0xb38')][_0x22fe06][_0x1c4ddd('0x2378')]=![],_0x375c0c[_0x1c4ddd('0x1514')](_0x3f143c[_0x1c4ddd('0xb38')][_0x22fe06]));}_0x3f143c['tags']=_0x375c0c;}else{if(!_0x258f33[_0x1c4ddd('0x1a2b')])return _0x536c21[_0x1c4ddd('0x4b5')]['get']({'sectionId':_0x258f33['id']})[_0x1c4ddd('0xa44')][_0x1c4ddd('0x1166')](function(_0x1bc918){const _0x55354f=_0x1c4ddd,_0x562eb2=_0x2cfb05()[_0x55354f('0x2563')](_0x1bc918['rows'],function(_0xb1f818){const _0x1cb49b=_0x55354f;return _0x2cfb05()[_0x1cb49b('0xc38')](_0x3f143c['tags'],{'id':_0xb1f818[_0x1cb49b('0x24e8')]});});let _0x32e2ee=null;_0x3f143c[_0x55354f('0x1446')]&&(_0x32e2ee=_0x2cfb05()['find'](_0x3f143c[_0x55354f('0xb38')],{'name':_0x3f143c[_0x55354f('0x1446')][_0x55354f('0x1446')]}));if(_0x32e2ee&&!_0x2cfb05()[_0x55354f('0x1798')](_0x562eb2,['id',_0x32e2ee['id']])){const _0x37ad22=_0x2cfb05()['find'](_0x3f143c['tags'],{'id':_0x32e2ee['id']});_0x37ad22[_0x55354f('0x2378')]=![],_0x562eb2['push'](_0x37ad22);}_0x3f143c['tags']=_0x562eb2;});}})[_0xbcbfb7('0x1a80')](function(_0xae5a39){const _0xc59b25=_0xbcbfb7;_0x47bd2e[_0xc59b25('0xfc9')]({'title':_0xae5a39[_0xc59b25('0x52d')]?_0xc59b25('0x1e21')+_0xae5a39[_0xc59b25('0x52d')]+'\x20-\x20'+_0xae5a39[_0xc59b25('0xe1b')]:_0xc59b25('0x9e'),'msg':_0xae5a39[_0xc59b25('0x25f4')]?JSON[_0xc59b25('0xbac')](_0xae5a39[_0xc59b25('0x25f4')]):_0xae5a39[_0xc59b25('0x1586')]()});});function _0x5a28ab(){const _0x2511a4=_0xbcbfb7;_0x3f143c[_0x2511a4('0x61a')]=[];const _0x27cd8f=[];_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x1345')]&&_0x3f143c[_0x2511a4('0x1446')]['type'][_0x2511a4('0x2574')]()===_0x2511a4('0x587')&&_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x83f')]===_0x2511a4('0x867')&&(_0x3f143c['tag'][_0x2511a4('0x2026')]=_0x5a417d[_0x2511a4('0x2848')]?(_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x265a')]||'')+_0x2511a4('0x881')+_0x5a417d[_0x2511a4('0x2848')]+'}':(_0x3f143c['tag']['prefix']||'')+_0x2511a4('0x1d1'),_0x5a417d['recordingFormat']!==_0x2511a4('0x192')?_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0xd39')][_0x2511a4('0x2379')](_0x2511a4('0x1059'))<0x0&&(_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0xd39')]+=_0x2511a4('0x1059')):_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0xd39')]=_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0xd39')]['replace'](_0x2511a4('0x1059'),''));const _0x50e0ed=_0x2cfb05()['find'](_0x3f143c[_0x2511a4('0xb38')],{'name':_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x1446')]});_0x50e0ed&&(_0x3f143c[_0x2511a4('0x1446')]['TagId']=_0x50e0ed['id']);if(_0x3f143c['tag'][_0x2511a4('0x83f')]&&_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x83f')]===_0x2511a4('0x2853')){}else switch((_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x746')]||_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x83f')])[_0x2511a4('0x2574')]()){case _0x2511a4('0xceb'):_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x823')]=_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x4f0')]+'='+_0x3f143c['tag']['value'];break;case'custom':break;default:_0x27cd8f[0x0]=_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x1446')],_0x3f143c[_0x2511a4('0x1446')][_0x2511a4('0x823')]=_0x27cd8f[_0x2511a4('0x45a')](',');}_0x5ce24f(_0x3f143c[_0x2511a4('0x1446')]);}function _0x5ce24f(_0x477f62){const _0x2a73a8=_0xbcbfb7;_0x2372cb[_0x2a73a8('0x1197')](_0x477f62);}}const _0x3c9529=_0x977fc1;_0x322b0d['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state','$mdSidenav',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),'Auth'];function _0x322b0d(_0xca1435,_0xf1cd26,_0x5e0709,_0x5063d7,_0x171370,_0x33310d,_0x14a103,_0x126847,_0x5c5fec,_0x270664,_0x18e7ef){const _0x1776fe=_0x36e6f4,_0x11eb61=this;_0x11eb61[_0x1776fe('0x98')]=_0x18e7ef[_0x1776fe('0x26cd')](),_0x11eb61[_0x1776fe('0x4ea')]={'count':0x0,'rows':[]},_0x11eb61[_0x1776fe('0x1082')]=[],_0x11eb61[_0x1776fe('0x243c')],_0x11eb61[_0x1776fe('0x178f')]={'first':'1st','second':_0x1776fe('0x580'),'third':'3rd'},_0x11eb61[_0x1776fe('0x2218')]={'fields':'id,level,name,description,ParentId,createdAt,updatedAt','sort':'-updatedAt','limit':0xa,'page':0x1},_0x11eb61[_0x1776fe('0x24d5')]=_0x29c482,_0x11eb61[_0x1776fe('0x8a2')]=_0x56d274,_0x11eb61[_0x1776fe('0x103b')]=_0x2e0c46,_0x11eb61['getDispositions']=_0x325243,_0x11eb61['createOrEditDisposition']=_0x480cd2,_0x11eb61[_0x1776fe('0x27c6')]=_0x128ac9,_0x11eb61[_0x1776fe('0x4e2')]=_0x49393c,_0x11eb61['deleteSelectedDispositions']=_0x7ec00,_0x11eb61['deselectDispositions']=_0x475bcd,_0x11eb61[_0x1776fe('0xd7c')]=_0x262756;function _0x29c482(_0x58a0f0,_0x346c69){const _0x5e54b6=_0x1776fe;_0x11eb61[_0x5e54b6('0x2085')]=_0x58a0f0||{},_0x11eb61['crudPermissions']=typeof _0x346c69!==_0x5e54b6('0x1048')?_0x346c69:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x11eb61[_0x5e54b6('0x2218')][_0x5e54b6('0x18fe')]=_0x11eb61[_0x5e54b6('0x2085')]['id'],_0x11eb61['query']['id']=_0x11eb61[_0x5e54b6('0x2085')]['id'],_0x325243();}function _0x480cd2(_0x403154,_0x152f86){const _0x4cf2f0=_0x1776fe;_0x171370[_0x4cf2f0('0x1f80')]({'controller':_0x4cf2f0('0x17a3'),'controllerAs':'vm','templateUrl':_0x14e8d3,'parent':angular[_0x4cf2f0('0x1194')](_0x33310d[_0x4cf2f0('0x8d2')]),'targetEvent':_0x403154,'clickOutsideToClose':!![],'locals':{'disposition':_0x152f86,'dispositions':_0x11eb61['dispositions'][_0x4cf2f0('0x269a')],'model':{'id':_0x11eb61[_0x4cf2f0('0x2085')]['id'],'field':_0x4cf2f0('0x18fe')},'license':null,'setting':null,'crudPermissions':_0x11eb61[_0x4cf2f0('0x243c')]}})['then'](function(_0x154fea){if(_0x154fea)_0x325243();});}function _0x56d274(_0x2a8c17,_0x4e0d25){const _0x546e0a=_0x1776fe,_0x3fb3a9=_0x2cfb05()['some'](_0x11eb61[_0x546e0a('0x4ea')][_0x546e0a('0x269a')],[_0x546e0a('0x11fa'),_0x2a8c17['id']]),_0x55cac2=_0x171370['confirm']()[_0x546e0a('0xcdc')](_0x126847[_0x546e0a('0x25cc')](_0x546e0a('0x1ac5')))[_0x546e0a('0xacc')](_0x126847[_0x546e0a('0x25cc')](_0x546e0a('0x92f')+(_0x3fb3a9?_0x546e0a('0xc7a'):_0x546e0a('0x251e')),{'name':_0x2a8c17[_0x546e0a('0x4f0')]}))[_0x546e0a('0x8e8')](_0x546e0a('0x1af2'))[_0x546e0a('0x203b')](_0x4e0d25)['ok']('OK')[_0x546e0a('0x3f')](_0x126847['instant'](_0x546e0a('0x12a3')));_0x171370[_0x546e0a('0x1f80')](_0x55cac2)[_0x546e0a('0x1166')](function(){_0x128ac9(_0x2a8c17);});}function _0x2e0c46(_0x2d7a6a){const _0x2c128b=_0x1776fe;_0x11eb61[_0x2c128b('0x4ea')]=_0x2d7a6a||{'count':0x0,'rows':[]};}function _0x325243(){const _0x44d109=_0x1776fe;_0x11eb61[_0x44d109('0x2218')]['offset']=(_0x11eb61[_0x44d109('0x2218')][_0x44d109('0x1a43')]-0x1)*_0x11eb61['query'][_0x44d109('0x163f')],_0x11eb61[_0x44d109('0x1f48')]=_0x5c5fec[_0x44d109('0x2085')][_0x44d109('0x3e')](_0x11eb61[_0x44d109('0x2218')],_0x2e0c46)['$promise'];}function _0x128ac9(_0x5db45a){const _0x58578f=_0x1776fe;_0x5c5fec[_0x58578f('0x12e8')]['delete']({'id':_0x5db45a['id']})[_0x58578f('0xa44')][_0x58578f('0x1166')](function(){const _0x29802c=_0x58578f;_0x325243(),_0x270664[_0x29802c('0x103b')]({'title':_0x126847[_0x29802c('0x25cc')](_0x29802c('0x1ca6'))});})[_0x58578f('0x1a80')](function(_0x296d10){const _0x3220d5=_0x58578f;if(_0x296d10[_0x3220d5('0x25f4')]&&_0x296d10[_0x3220d5('0x25f4')][_0x3220d5('0x61a')]&&_0x296d10[_0x3220d5('0x25f4')][_0x3220d5('0x61a')][_0x3220d5('0x264b')]){_0x11eb61[_0x3220d5('0x61a')]=_0x296d10['data']['errors']||[{'message':_0x296d10[_0x3220d5('0x1586')](),'type':_0x3220d5('0x1b2c')}];for(let _0xca87ed=0x0;_0xca87ed<_0x296d10[_0x3220d5('0x25f4')]['errors'][_0x3220d5('0x264b')];_0xca87ed++){_0x270664[_0x3220d5('0xfc9')]({'title':_0x296d10[_0x3220d5('0x25f4')][_0x3220d5('0x61a')][_0xca87ed][_0x3220d5('0x1345')],'msg':_0x296d10[_0x3220d5('0x25f4')][_0x3220d5('0x61a')][_0xca87ed]['message']});}}else _0x270664[_0x3220d5('0xfc9')]({'title':_0x296d10['status']?'API:'+_0x296d10[_0x3220d5('0x52d')]+_0x3220d5('0x11e1')+_0x296d10[_0x3220d5('0xe1b')]:_0x3220d5('0x1b2c'),'msg':_0x296d10[_0x3220d5('0x25f4')]?JSON[_0x3220d5('0xbac')](_0x296d10['data'][_0x3220d5('0x1e70')]):_0x296d10['message']||_0x296d10[_0x3220d5('0x1586')]()});});}function _0x49393c(){const _0x56c14a=_0x1776fe,_0x3e04d6=angular[_0x56c14a('0x225f')](_0x11eb61['selectedDispositions']);return _0x11eb61['selectedDispositions']=[],_0x3e04d6;}function _0x7ec00(_0xe2dc87){const _0x4d4b8e=_0x1776fe,_0x1a9885=_0x171370[_0x4d4b8e('0x1d26')]()[_0x4d4b8e('0xcdc')](_0x126847['instant'](_0x4d4b8e('0x24fd')))['content'](_0x126847[_0x4d4b8e('0x25cc')]('TOOLS.NOTIFICATIONS.DISPOSITIONS_DELETE_MESSAGE',{'total':_0x11eb61[_0x4d4b8e('0x1082')][_0x4d4b8e('0x264b')]}))[_0x4d4b8e('0x8e8')](_0x4d4b8e('0x19b'))[_0x4d4b8e('0x203b')](_0xe2dc87)['ok']('OK')['cancel'](_0x126847[_0x4d4b8e('0x25cc')]('TOOLS.CANCEL'));_0x171370[_0x4d4b8e('0x1f80')](_0x1a9885)[_0x4d4b8e('0x1166')](function(){const _0x4ebe50=_0x4d4b8e;_0x11eb61[_0x4ebe50('0x1082')]['forEach'](function(_0x2e01ec){_0x128ac9(_0x2e01ec);}),_0x11eb61['selectedDispositions']=[];});}function _0x475bcd(){const _0x4523d1=_0x1776fe;_0x11eb61[_0x4523d1('0x1082')]=[];}function _0x262756(){const _0x408ebb=_0x1776fe;_0x11eb61[_0x408ebb('0x1082')]=_0x11eb61[_0x408ebb('0x4ea')][_0x408ebb('0x269a')];}let _0x4a9e13=!![],_0x4f8a0b=0x1;_0xca1435[_0x1776fe('0xe83')]('vm_dc.query.filter',function(_0x1d0dd2,_0x43b955){const _0xf5d885=_0x1776fe;_0x4a9e13?_0x14a103(function(){_0x4a9e13=![];}):(!_0x43b955&&(_0x4f8a0b=_0x11eb61[_0xf5d885('0x2218')][_0xf5d885('0x1a43')]),_0x1d0dd2!==_0x43b955&&(_0x11eb61[_0xf5d885('0x2218')][_0xf5d885('0x1a43')]=0x1),!_0x1d0dd2&&(_0x11eb61['query'][_0xf5d885('0x1a43')]=_0x4f8a0b),_0x325243());});}const _0x291635=_0x322b0d;_0x335c30[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),'$scope',_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'Auth'];function _0x335c30(_0x5bcf9a,_0x34b417,_0x31b28b,_0x3d1556,_0x199ff8,_0x1e3df4,_0x56ab03,_0x320868,_0x3f8499,_0x50924f,_0x1e956f){const _0x5db500=_0x36e6f4,_0xe61e49=this;_0xe61e49['currentUser']=_0x1e956f[_0x5db500('0x26cd')](),_0xe61e49[_0x5db500('0x2085')]={},_0xe61e49[_0x5db500('0x11a0')]={'count':0x0,'rows':[]},_0xe61e49[_0x5db500('0x2204')]=[],_0xe61e49['crudPermissions'],_0xe61e49['query']={'read':_0x5db500('0x15d7'),'closed':_0x5db500('0x15d7'),'sort':'-createdAt','includeAll':'true','limit':0xa,'page':0x1},_0xe61e49[_0x5db500('0x24d5')]=_0x53430e,_0xe61e49[_0x5db500('0x8a2')]=_0x4b291c,_0xe61e49['faxInteractionDownload']=_0x4ab8d5,_0xe61e49['success']=_0x1b5962,_0xe61e49[_0x5db500('0xc89')]=_0x4c82bf,_0xe61e49[_0x5db500('0x1697')]=_0x48b0a2,_0xe61e49['openAdvancedSearch']=_0x4d833e,_0xe61e49[_0x5db500('0x414')]=_0x284763,_0xe61e49[_0x5db500('0x12c9')]=_0x12254a,_0xe61e49[_0x5db500('0xb37')]=_0x9aa52e;function _0x53430e(_0x152b85,_0x44ed3d){const _0x3872c8=_0x5db500;_0xe61e49[_0x3872c8('0x2085')]=_0x152b85,_0xe61e49[_0x3872c8('0x243c')]=typeof _0x44ed3d!==_0x3872c8('0x1048')?_0x44ed3d:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0xe61e49[_0x3872c8('0x2218')][_0x3872c8('0x18fe')]=_0xe61e49[_0x3872c8('0x2085')]['id'],_0xe61e49[_0x3872c8('0x1291')]={'fields':_0x190556()},_0x981943();}function _0x981943(){const _0x43692a=_0x5db500;return _0x50924f[_0x43692a('0x1446')][_0x43692a('0xd83')]()['$promise'][_0x43692a('0x1166')](function(_0x2c464a){_0xe61e49['tags']=_0x2c464a||{'count':0x0,'rows':[]};})['then'](function(){_0xe61e49['quickFilters']=_0x30f3ed();});}function _0x30f3ed(){const _0x349371=_0x5db500;return[{'name':_0x349371('0x2567'),'key':'createdAt','type':_0x349371('0x1643'),'label':_0x349371('0x16d9')},{'name':_0x349371('0x116c'),'key':_0x349371('0x123'),'type':_0x349371('0x88a'),'label':'DASHBOARDS.SELECT_READ_UNREAD','customOptions':[{'value':0x0,'translate':_0x349371('0x2c8')},{'value':0x1,'translate':'DASHBOARDS.READ'},{'value':null,'translate':_0x349371('0x2150')}]},{'name':_0x349371('0x28f6'),'key':_0x349371('0xa5b'),'type':_0x349371('0x88a'),'label':_0x349371('0xe32'),'customOptions':[{'value':0x0,'translate':_0x349371('0xdeb')},{'value':0x1,'translate':_0x349371('0x58f')},{'value':null,'translate':_0x349371('0x2150')}]},{'name':_0x349371('0x89b'),'key':_0x349371('0x122a'),'type':_0x349371('0x88a'),'label':_0x349371('0x1db1'),'customOptions':[{'value':_0x349371('0x15d7'),'translate':_0x349371('0x216b')},{'value':undefined,'translate':_0x349371('0x2150')}]},{'name':'Tag','key':'tag','type':_0x349371('0x2162'),'label':_0x349371('0x1669'),'options':_0xe61e49[_0x349371('0xb38')]['rows'],'placeholder':_0x349371('0x2223')}];}function _0x190556(){const _0xcebabb=_0x5db500;return[{'name':'Id','column':'id','type':_0xcebabb('0xc45')},{'name':_0xcebabb('0x21a4'),'column':_0xcebabb('0x21a4'),'type':_0xcebabb('0x1a01'),'options':{'searchFields':[_0xcebabb('0x18cb'),'lastName',_0xcebabb('0x66f')],'route':{'model':_0xcebabb('0x149e'),'action':'get','params':{'fields':_0xcebabb('0x18eb'),'Contact':_0xcebabb('0x145b'),'nolimit':!![]}},'extraOperators':[_0xcebabb('0x2836')],'excludedOperators':[_0xcebabb('0x2646')]}},{'name':_0xcebabb('0x36e'),'column':_0xcebabb('0x210d'),'type':_0xcebabb('0x1640'),'options':{'excludedOperators':[_0xcebabb('0x110'),'$ne']}},{'name':_0xcebabb('0xe1'),'column':_0xcebabb('0x26d2'),'type':'text','options':{'excludedOperators':[_0xcebabb('0x110'),_0xcebabb('0x2646')]}},{'name':_0xcebabb('0x28f6'),'column':_0xcebabb('0xa5b'),'type':_0xcebabb('0x88a'),'values':[{'id':0x0,'translate':_0xcebabb('0xdeb')},{'id':0x1,'translate':_0xcebabb('0x58f')}],'options':{'excludedOperators':['$ne']}},{'name':_0xcebabb('0x89b'),'column':_0xcebabb('0x1a6f'),'type':_0xcebabb('0x1a01'),'options':{'table':'i','route':{'model':_0xcebabb('0x557'),'action':_0xcebabb('0xd83'),'params':{'role':_0xcebabb('0x1eff'),'fields':_0xcebabb('0xce1'),'nolimit':!![]}},'searchFields':['fullname',_0xcebabb('0x4f0')],'extraOperators':['$substring'],'excludedOperators':[_0xcebabb('0x2646')]}},{'name':_0xcebabb('0x21c2'),'column':_0xcebabb('0x1b35'),'type':_0xcebabb('0x2162'),'options':{'route':{'model':_0xcebabb('0x1446'),'action':'get','params':{'nolimit':!![]}},'excludedOperators':[_0xcebabb('0x18d')]}},{'name':_0xcebabb('0x2567'),'column':_0xcebabb('0x262'),'type':'date','options':{'excludedOperators':[_0xcebabb('0x2646')]}},{'name':_0xcebabb('0xf43'),'column':'unreadMessages','type':'select','values':[{'id':0x1,'translate':_0xcebabb('0x1057')},{'id':0x0,'translate':_0xcebabb('0x2c8')}],'options':{'excludedOperators':[_0xcebabb('0x2646')]}}];}function _0x4d833e(){const _0x1f6f66=_0x5db500;_0x56ab03['show']({'controller':_0x1f6f66('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular['element'](_0x320868[_0x1f6f66('0x8d2')]),'clickOutsideToClose':![],'locals':{'fields':_0xe61e49[_0x1f6f66('0x1291')][_0x1f6f66('0xfe2')],'color':undefined,'storagePath':_0x1f6f66('0x1b23')},'fullscreen':!![]})[_0x1f6f66('0x1166')](function(_0x2c2453){const _0x4d5668=_0x1f6f66;_0xe61e49[_0x4d5668('0x2218')][_0x4d5668('0xe07')]=_0x2c2453===![]?undefined:_0x2c2453;if(_0xe61e49[_0x4d5668('0x2218')][_0x4d5668('0xe07')])_0x4c82bf();else _0x2c2453===![]&&_0x4c82bf();})[_0x1f6f66('0x1a80')](function(_0x13b374){const _0x2d1ff2=_0x1f6f66;_0x3f8499[_0x2d1ff2('0xfc9')]({'title':_0x2d1ff2('0x2272'),'msg':_0x13b374[_0x2d1ff2('0x25f4')]?JSON[_0x2d1ff2('0xbac')](_0x13b374[_0x2d1ff2('0x25f4')][_0x2d1ff2('0x1e70')]):_0x13b374[_0x2d1ff2('0x1586')]()});});}function _0x4ab8d5(_0x4837f3,_0x52250d,_0xb7c8c6){const _0x206f29=_0x5db500;return _0x50924f[_0x206f29('0x1342')][_0x206f29('0x2ad')]({'id':_0x4837f3['id'],'exists':!![],'attachments':_0xb7c8c6})[_0x206f29('0xa44')][_0x206f29('0x1166')](function(_0x492b3c){const _0x28bf0d=_0x206f29,_0x24283d=[_0x492b3c['buffer']];let _0x21b065=_0x28bf0d('0x25e6')+_0x4837f3['id'];const _0x436e27=new Blob(_0x24283d,{'type':_0x492b3c[_0x28bf0d('0x1345')]});_0x21b065=_0x28bf0d('0x1319')+_0x4837f3['id']+_0x28bf0d('0x806');const _0x5f5d72=window['document'][_0x28bf0d('0xdd')]('a');_0x5f5d72[_0x28bf0d('0xffd')]('href',URL['createObjectURL'](_0x436e27)),_0x5f5d72['setAttribute'](_0x28bf0d('0x2ad'),_0x21b065),document[_0x28bf0d('0x8d2')][_0x28bf0d('0x21a')](_0x5f5d72),_0x5f5d72[_0x28bf0d('0x3b4')]();})['catch'](function(_0x2128ce){const _0x1bba8b=_0x206f29;if(_0x2128ce[_0x1bba8b('0x25f4')]&&_0x2128ce[_0x1bba8b('0x25f4')][_0x1bba8b('0x61a')]&&_0x2128ce[_0x1bba8b('0x25f4')][_0x1bba8b('0x61a')][_0x1bba8b('0x264b')])for(let _0x287353=0x0;_0x287353<_0x2128ce[_0x1bba8b('0x25f4')][_0x1bba8b('0x61a')]['length'];_0x287353+=0x1){_0x3f8499[_0x1bba8b('0xfc9')]({'title':_0x2128ce[_0x1bba8b('0x25f4')]['errors'][_0x287353][_0x1bba8b('0x1345')],'msg':_0x2128ce[_0x1bba8b('0x25f4')][_0x1bba8b('0x61a')][_0x287353][_0x1bba8b('0x1e70')]});}else _0x3f8499['error']({'title':_0x2128ce['status']?'API:'+_0x2128ce[_0x1bba8b('0x52d')]+_0x1bba8b('0x11e1')+_0x2128ce[_0x1bba8b('0xe1b')]:_0x1bba8b('0xf4c'),'msg':_0x2128ce[_0x1bba8b('0x25f4')]?JSON[_0x1bba8b('0xbac')](_0x2128ce[_0x1bba8b('0x25f4')][_0x1bba8b('0x1e70')]):_0x2128ce[_0x1bba8b('0x1586')]()});});}function _0x4b291c(_0xd53778,_0x3f5462){const _0x5747c9=_0x5db500,_0x65ae40=_0x56ab03[_0x5747c9('0x1d26')]()[_0x5747c9('0xcdc')](_0x5747c9('0xced'))[_0x5747c9('0xf3c')](_0x5747c9('0x12b5')+(_0xd53778['name']||_0xd53778['id']&&_0x2cfb05()[_0x5747c9('0x114b')](_0x5747c9('0x2625'))+_0xd53778['id']||'interaction')+_0x5747c9('0xace')+_0x5747c9('0x3f3'))[_0x5747c9('0x8e8')](_0x5747c9('0xa04'))[_0x5747c9('0x203b')](_0x3f5462)['ok']('OK')['cancel']('CANCEL');_0x56ab03[_0x5747c9('0x1f80')](_0x65ae40)[_0x5747c9('0x1166')](function(){_0x12254a(_0xd53778);},function(){const _0x61dc1e=_0x5747c9;console[_0x61dc1e('0x455')]('CANCEL');});}function _0x1b5962(_0x5e824d){const _0x3847e5=_0x5db500;_0xe61e49[_0x3847e5('0x11a0')]=_0x5e824d||{'count':0x0,'rows':[]};for(let _0x5cdf69=0x0;_0x5cdf69<_0xe61e49[_0x3847e5('0x11a0')][_0x3847e5('0x269a')]['length'];_0x5cdf69+=0x1){const _0x188a7d=_0xe61e49['faxAccountInteractions']['rows'][_0x5cdf69];_0x2af433(_0x188a7d),_0x188a7d['Owner']['name']=_0x3cb8f8(_0x188a7d);}}function _0x4c82bf(){const _0x2514c0=_0x5db500;_0xe61e49[_0x2514c0('0x2218')][_0x2514c0('0x1098')]=(_0xe61e49[_0x2514c0('0x2218')]['page']-0x1)*_0xe61e49['query'][_0x2514c0('0x163f')],_0xe61e49[_0x2514c0('0x1f48')]=_0x50924f[_0x2514c0('0x1342')][_0x2514c0('0xd83')](_0xe61e49[_0x2514c0('0x2218')],_0x1b5962)['$promise'];}function _0x48b0a2(_0x469560,_0x5da466){const _0x429a59=_0x5db500;_0x56ab03[_0x429a59('0x1f80')]({'controller':_0x429a59('0x19ad'),'controllerAs':'vm','templateUrl':_0xbfcb18,'parent':angular[_0x429a59('0x1194')](_0x320868[_0x429a59('0x8d2')]),'targetEvent':_0x469560,'clickOutsideToClose':!![],'onShowing':function(_0x2d1f09){const _0x57a025=_0x429a59;_0x2d1f09['vm'][_0x57a025('0x24d5')]({'id':0x1,'channel':_0x57a025('0x1fc7'),'interaction':_0x5da466,'spy':!![]},_0x34b417[_0x57a025('0x23ac')]['vm']['setting']);}});}function _0x12254a(_0x41f165){const _0x3da1e0=_0x5db500;_0x50924f['faxInteraction'][_0x3da1e0('0x906')]({'id':_0x41f165['id']})['$promise']['then'](function(){const _0x3c7a91=_0x3da1e0;_0x2cfb05()[_0x3c7a91('0x127f')](_0xe61e49[_0x3c7a91('0x11a0')][_0x3c7a91('0x269a')],{'id':_0x41f165['id']}),_0xe61e49[_0x3c7a91('0x11a0')][_0x3c7a91('0x240f')]-=0x1,!_0xe61e49[_0x3c7a91('0x11a0')][_0x3c7a91('0x269a')]['length']&&_0x4c82bf(),_0x3f8499[_0x3c7a91('0x103b')]({'title':_0x3c7a91('0x2003'),'msg':_0x41f165['name']?_0x41f165[_0x3c7a91('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0x3da1e0('0x1a80')](function(_0x5809d4){const _0x36e405=_0x3da1e0;if(_0x5809d4[_0x36e405('0x25f4')]&&_0x5809d4[_0x36e405('0x25f4')][_0x36e405('0x61a')]&&_0x5809d4['data']['errors'][_0x36e405('0x264b')]){_0xe61e49[_0x36e405('0x61a')]=_0x5809d4[_0x36e405('0x25f4')][_0x36e405('0x61a')]||[{'message':_0x5809d4['toString'](),'type':_0x36e405('0x8b1')}];for(let _0x158028=0x0;_0x158028<_0x5809d4[_0x36e405('0x25f4')][_0x36e405('0x61a')][_0x36e405('0x264b')];_0x158028++){_0x3f8499[_0x36e405('0xfc9')]({'title':_0x5809d4[_0x36e405('0x25f4')][_0x36e405('0x61a')][_0x158028][_0x36e405('0x1345')],'msg':_0x5809d4['data'][_0x36e405('0x61a')][_0x158028][_0x36e405('0x1e70')]});}}else _0x3f8499[_0x36e405('0xfc9')]({'title':_0x5809d4[_0x36e405('0x52d')]?_0x36e405('0x1e21')+_0x5809d4[_0x36e405('0x52d')]+_0x36e405('0x11e1')+_0x5809d4['statusText']:_0x36e405('0x8b1'),'msg':_0x5809d4[_0x36e405('0x25f4')]?JSON[_0x36e405('0xbac')](_0x5809d4[_0x36e405('0x25f4')][_0x36e405('0x1e70')]):_0x5809d4[_0x36e405('0x1e70')]||_0x5809d4[_0x36e405('0x1586')]()});});}function _0x284763(){const _0x5126f8=_0x5db500,_0x49dc24=angular[_0x5126f8('0x225f')](_0xe61e49['selectedFaxAccountInteractions']);return _0xe61e49[_0x5126f8('0x2204')]=[],_0x49dc24;}function _0x9aa52e(_0x493ca7){const _0x39e351=_0x5db500,_0x4c4b4e=_0x56ab03[_0x39e351('0x1d26')]()[_0x39e351('0xcdc')](_0x39e351('0x5dd'))['htmlContent'](_0x39e351('0x12b5')+_0xe61e49['selectedFaxAccountInteractions'][_0x39e351('0x264b')]+_0x39e351('0x196d')+'\x20will\x20be\x20deleted.')[_0x39e351('0x8e8')](_0x39e351('0x1623'))['targetEvent'](_0x493ca7)['ok']('OK')[_0x39e351('0x3f')](_0x39e351('0x2d3'));_0x56ab03[_0x39e351('0x1f80')](_0x4c4b4e)[_0x39e351('0x1166')](function(){const _0x5441cd=_0x39e351;_0xe61e49['selectedFaxAccountInteractions'][_0x5441cd('0x2782')](function(_0x48aadc){_0x12254a(_0x48aadc);}),_0xe61e49['selectedFaxAccountInteractions']=[];});}function _0x2af433(_0x3066f5){const _0x38a488=_0x5db500;_0x3066f5['Contact']?(_0x3066f5['contactName']=(_0x3066f5[_0x38a488('0x21a4')][_0x38a488('0x18cb')]||'')+'\x20'+(_0x3066f5[_0x38a488('0x21a4')][_0x38a488('0xeb0')]||''),_0x3066f5['contactInfo']=_0x3066f5[_0x38a488('0x21a4')]['fax']):_0x3066f5[_0x38a488('0x15cf')]=_0x199ff8[_0x38a488('0x25cc')](_0x38a488('0x148c'));}function _0x3cb8f8(_0x4e91c8){const _0x332162=_0x5db500;if(_0x4e91c8[_0x332162('0x122a')])return _0x4e91c8[_0x332162('0x122a')]===_0xe61e49['currentUser']['id']?_0x199ff8[_0x332162('0x25cc')](_0x332162('0x15ae')):_0x4e91c8[_0x332162('0x121b')]['fullname']+'\x20<'+_0x4e91c8[_0x332162('0x121b')]['internal']+'>';return _0x199ff8['instant'](_0x332162('0x216b'));}let _0x4e94c8=!![],_0xe2f89a=0x1;_0x34b417[_0x5db500('0xe83')](_0x5db500('0x28b4'),function(_0x278d9c,_0x9aff01){const _0x171499=_0x5db500;_0x4e94c8?_0x1e3df4(function(){_0x4e94c8=![];}):(!_0x9aff01&&(_0xe2f89a=_0xe61e49[_0x171499('0x2218')][_0x171499('0x1a43')]),_0x278d9c!==_0x9aff01&&(_0xe61e49['query'][_0x171499('0x1a43')]=0x1),!_0x278d9c&&(_0xe61e49['query'][_0x171499('0x1a43')]=_0xe2f89a),_0x4c82bf());});}const _0xf3fbf9=_0x335c30,_0x111421=_0x2734b2['p']+_0x36e6f4('0x1046');_0x3b7eae[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x2085'),_0x36e6f4('0x17aa')];function _0x3b7eae(_0x36d5a1,_0x297c21,_0x485eca,_0x559a7a,_0x280015,_0x3a24db,_0x535a1c,_0xc0b726,_0x9abcfb,_0x2a94bb,_0x5e7264,_0x4d6a5b){const _0x12ee32=_0x36e6f4,_0x173c55=this;_0x173c55['currentUser']=_0x2a94bb['getCurrentUser'](),_0x173c55[_0x12ee32('0x5c9')]=_0x3a24db,_0x173c55[_0x12ee32('0xf8a')]=_0x535a1c,_0x173c55[_0x12ee32('0x2900')]=_0x173c55[_0x12ee32('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x173c55[_0x12ee32('0x246b')]=_0x297c21[_0x12ee32('0x6f1')]()+_0x12ee32('0xc51')+_0x297c21[_0x12ee32('0x1690')](),_0x173c55[_0x12ee32('0x2085')]=_0x5e7264||_0x36d5a1[_0x12ee32('0x23f')][_0x12ee32('0x2085')]||{},_0x173c55[_0x12ee32('0x17aa')]=_0x4d6a5b&&_0x4d6a5b['count']==0x1?_0x4d6a5b[_0x12ee32('0x269a')][0x0]:null,_0x173c55[_0x12ee32('0x243c')]=_0x2a94bb[_0x12ee32('0xd87')](_0x173c55['userProfileSection']?_0x173c55['userProfileSection'][_0x12ee32('0x243c')]:null),_0x173c55[_0x12ee32('0x128b')]={},_0x173c55[_0x12ee32('0x2669')]=_0x36d5a1[_0x12ee32('0x23f')][_0x12ee32('0xbe3')]||0x0,_0x173c55[_0x12ee32('0x22c1')]=_0x269097,_0x173c55['agentadddialog']=_0x4f5845,_0x173c55[_0x12ee32('0x31d')]=_0x9abcfb[_0x12ee32('0x1fa1')],_0x173c55[_0x12ee32('0x1fc4')]=_0x2034ac,_0x173c55[_0x12ee32('0x19fa')]=_0x544f83,_0x2a94bb[_0x12ee32('0x1ac6')](_0x12ee32('0xa7c'))?_0xc0b726[_0x12ee32('0x3b2')][_0x12ee32('0xd83')]({'fields':_0x12ee32('0x1776'),'sort':'name'})[_0x12ee32('0xa44')][_0x12ee32('0x1166')](function(_0xe9459b){const _0x28f0ba=_0x12ee32;_0x173c55[_0x28f0ba('0xf24')]=_0xe9459b[_0x28f0ba('0x269a')]||[];})[_0x12ee32('0x1a80')](function(_0x24507f){const _0x54ca39=_0x12ee32;_0x9abcfb[_0x54ca39('0xfc9')]({'title':_0x24507f[_0x54ca39('0x52d')]?'API:'+_0x24507f[_0x54ca39('0x52d')]+_0x54ca39('0x11e1')+_0x24507f['statusText']:'SYSTEM:GET_TRUNKS','msg':_0x24507f[_0x54ca39('0x25f4')]?JSON[_0x54ca39('0xbac')](_0x24507f[_0x54ca39('0x25f4')]):_0x24507f['toString']()});}):_0xc0b726[_0x12ee32('0x3b2')][_0x12ee32('0xd83')]({'fields':_0x12ee32('0x1776'),'sort':'name'})[_0x12ee32('0xa44')]['then'](function(_0x169aaa){const _0x2b9c9a=_0x12ee32;_0x173c55[_0x2b9c9a('0xf24')]=_0x169aaa[_0x2b9c9a('0x269a')]||[];})[_0x12ee32('0x1166')](function(){const _0xcdd3e7=_0x12ee32;return _0xc0b726[_0xcdd3e7('0x17aa')][_0xcdd3e7('0xd83')]({'userProfileId':_0x173c55[_0xcdd3e7('0x98')][_0xcdd3e7('0xb86')],'sectionId':0x3f3})[_0xcdd3e7('0xa44')];})[_0x12ee32('0x1166')](function(_0x1635ee){const _0x1fcc36=_0x12ee32,_0x547a74=_0x1635ee&&_0x1635ee[_0x1fcc36('0x269a')]?_0x1635ee[_0x1fcc36('0x269a')][0x0]:null;if(!_0x547a74){const _0x306d0f=[];let _0x4abd18=null;_0x173c55[_0x1fcc36('0x2085')]&&(_0x4abd18=_0x2cfb05()[_0x1fcc36('0xc38')](_0x173c55[_0x1fcc36('0xf24')],{'id':Number(_0x173c55[_0x1fcc36('0x2085')]['TrunkId'])}));for(let _0x251460=0x0;_0x251460<_0x173c55[_0x1fcc36('0xf24')][_0x1fcc36('0x264b')];_0x251460++){_0x4abd18&&_0x173c55[_0x1fcc36('0xf24')][_0x251460]['id']===_0x4abd18['id']&&(_0x173c55[_0x1fcc36('0xf24')][_0x251460]['canSelect']=![],_0x306d0f[_0x1fcc36('0x1514')](_0x173c55['trunks'][_0x251460]));}_0x173c55[_0x1fcc36('0xf24')]=_0x306d0f;}else{if(!_0x547a74[_0x1fcc36('0x1a2b')])return _0xc0b726[_0x1fcc36('0x4b5')][_0x1fcc36('0xd83')]({'sectionId':_0x547a74['id']})['$promise']['then'](function(_0x307ed3){const _0x486e6b=_0x1fcc36,_0x269224=_0x2cfb05()['map'](_0x307ed3[_0x486e6b('0x269a')],function(_0x4bcc42){const _0x44ea51=_0x486e6b;return _0x2cfb05()[_0x44ea51('0xc38')](_0x173c55[_0x44ea51('0xf24')],{'id':_0x4bcc42[_0x44ea51('0x24e8')]});});let _0x36791d=null;_0x173c55[_0x486e6b('0x2085')]&&(_0x36791d=_0x2cfb05()['find'](_0x173c55['trunks'],{'id':Number(_0x173c55[_0x486e6b('0x2085')][_0x486e6b('0x1ce4')])}));if(_0x36791d&&!_0x2cfb05()['some'](_0x269224,['id',_0x36791d['id']])){const _0x1f86f1=_0x2cfb05()[_0x486e6b('0xc38')](_0x173c55[_0x486e6b('0xf24')],{'id':_0x36791d['id']});_0x1f86f1['canSelect']=![],_0x269224[_0x486e6b('0x1514')](_0x1f86f1);}_0x173c55[_0x486e6b('0xf24')]=_0x269224;});}})[_0x12ee32('0x1a80')](function(_0x4b1cd4){const _0x271935=_0x12ee32;_0x9abcfb[_0x271935('0xfc9')]({'title':_0x4b1cd4[_0x271935('0x52d')]?_0x271935('0x1e21')+_0x4b1cd4[_0x271935('0x52d')]+_0x271935('0x11e1')+_0x4b1cd4[_0x271935('0xe1b')]:_0x271935('0x1d44'),'msg':_0x4b1cd4['data']?JSON[_0x271935('0xbac')](_0x4b1cd4[_0x271935('0x25f4')]):_0x4b1cd4[_0x271935('0x1586')]()});}),_0x2a94bb[_0x12ee32('0x1ac6')](_0x12ee32('0xa7c'))?_0xc0b726[_0x12ee32('0xdd9')][_0x12ee32('0xd83')]({'fields':_0x12ee32('0x1776'),'sort':'name'})[_0x12ee32('0xa44')][_0x12ee32('0x1166')](function(_0xa3421d){_0x173c55['lists']=_0xa3421d['rows']||[];})['catch'](function(_0x15b221){const _0x1040a7=_0x12ee32;_0x9abcfb['error']({'title':_0x15b221[_0x1040a7('0x52d')]?_0x1040a7('0x1e21')+_0x15b221['status']+_0x1040a7('0x11e1')+_0x15b221[_0x1040a7('0xe1b')]:_0x1040a7('0x520'),'msg':_0x15b221['data']?JSON[_0x1040a7('0xbac')](_0x15b221[_0x1040a7('0x25f4')]):_0x15b221['toString']()});}):_0xc0b726[_0x12ee32('0xdd9')][_0x12ee32('0xd83')]({'fields':'id,name','sort':_0x12ee32('0x4f0')})[_0x12ee32('0xa44')][_0x12ee32('0x1166')](function(_0x412b28){const _0x2f0cde=_0x12ee32;_0x173c55[_0x2f0cde('0x8de')]=_0x412b28[_0x2f0cde('0x269a')]||[];})[_0x12ee32('0x1166')](function(){const _0x1c1f9b=_0x12ee32;return _0xc0b726[_0x1c1f9b('0x17aa')][_0x1c1f9b('0xd83')]({'userProfileId':_0x173c55[_0x1c1f9b('0x98')][_0x1c1f9b('0xb86')],'sectionId':0x12d})['$promise'];})[_0x12ee32('0x1166')](function(_0x3736bd){const _0x2255e6=_0x12ee32,_0x20399f=_0x3736bd&&_0x3736bd[_0x2255e6('0x269a')]?_0x3736bd[_0x2255e6('0x269a')][0x0]:null;if(!_0x20399f){const _0x9ea862=[];let _0x50e5ef=null;_0x173c55[_0x2255e6('0x2085')]&&(_0x50e5ef=_0x2cfb05()[_0x2255e6('0xc38')](_0x173c55[_0x2255e6('0x8de')],{'id':Number(_0x173c55[_0x2255e6('0x2085')][_0x2255e6('0x23c')])}));for(let _0x358082=0x0;_0x358082<_0x173c55[_0x2255e6('0x8de')][_0x2255e6('0x264b')];_0x358082++){_0x50e5ef&&_0x173c55[_0x2255e6('0x8de')][_0x358082]['id']===_0x50e5ef['id']&&(_0x173c55[_0x2255e6('0x8de')][_0x358082][_0x2255e6('0x2378')]=![],_0x9ea862[_0x2255e6('0x1514')](_0x173c55[_0x2255e6('0x8de')][_0x358082]));}_0x173c55[_0x2255e6('0x8de')]=_0x9ea862;}else{if(!_0x20399f[_0x2255e6('0x1a2b')])return _0xc0b726[_0x2255e6('0x4b5')][_0x2255e6('0xd83')]({'sectionId':_0x20399f['id']})[_0x2255e6('0xa44')][_0x2255e6('0x1166')](function(_0xccd7d7){const _0x4bd3ec=_0x2255e6,_0x373743=_0x2cfb05()[_0x4bd3ec('0x2563')](_0xccd7d7[_0x4bd3ec('0x269a')],function(_0x37a7e1){const _0x57b5a9=_0x4bd3ec;return _0x2cfb05()[_0x57b5a9('0xc38')](_0x173c55['lists'],{'id':_0x37a7e1[_0x57b5a9('0x24e8')]});});let _0x4c091d=null;_0x173c55[_0x4bd3ec('0x2085')]&&(_0x4c091d=_0x2cfb05()['find'](_0x173c55[_0x4bd3ec('0x8de')],{'id':Number(_0x173c55[_0x4bd3ec('0x2085')][_0x4bd3ec('0x23c')])}));if(_0x4c091d&&!_0x2cfb05()[_0x4bd3ec('0x1798')](_0x373743,['id',_0x4c091d['id']])){const _0x3fc008=_0x2cfb05()['find'](_0x173c55[_0x4bd3ec('0x8de')],{'id':_0x4c091d['id']});_0x3fc008[_0x4bd3ec('0x2378')]=![],_0x373743[_0x4bd3ec('0x1514')](_0x3fc008);}_0x173c55[_0x4bd3ec('0x8de')]=_0x373743;});}})[_0x12ee32('0x1a80')](function(_0x3c3e4a){const _0x3490ca=_0x12ee32;_0x9abcfb[_0x3490ca('0xfc9')]({'title':_0x3c3e4a[_0x3490ca('0x52d')]?_0x3490ca('0x1e21')+_0x3c3e4a[_0x3490ca('0x52d')]+'\x20-\x20'+_0x3c3e4a['statusText']:_0x3490ca('0x1248'),'msg':_0x3c3e4a['data']?JSON[_0x3490ca('0xbac')](_0x3c3e4a[_0x3490ca('0x25f4')]):_0x3c3e4a[_0x3490ca('0x1586')]()});}),_0x2a94bb['hasRole'](_0x12ee32('0xa7c'))?_0xc0b726[_0x12ee32('0x1e77')][_0x12ee32('0xd83')]({'fields':_0x12ee32('0xcb8'),'sort':_0x12ee32('0x4f0'),'nolimit':_0x12ee32('0xf3b')})[_0x12ee32('0xa44')]['then'](function(_0x4b5366){const _0x5c84c2=_0x12ee32;_0x173c55[_0x5c84c2('0xe29')]=_0x4b5366['rows']||[];})[_0x12ee32('0x1a80')](function(_0x173c66){const _0x37dc6b=_0x12ee32;_0x9abcfb[_0x37dc6b('0xfc9')]({'title':_0x173c66['status']?_0x37dc6b('0x1e21')+_0x173c66[_0x37dc6b('0x52d')]+_0x37dc6b('0x11e1')+_0x173c66[_0x37dc6b('0xe1b')]:_0x37dc6b('0x18ed'),'msg':_0x173c66[_0x37dc6b('0x25f4')]?JSON[_0x37dc6b('0xbac')](_0x173c66[_0x37dc6b('0x25f4')]):_0x173c66[_0x37dc6b('0x1586')]()});}):_0xc0b726[_0x12ee32('0x1e77')][_0x12ee32('0xd83')]({'fields':'name,id','sort':_0x12ee32('0x4f0'),'nolimit':_0x12ee32('0xf3b')})[_0x12ee32('0xa44')]['then'](function(_0x434610){const _0x3b5245=_0x12ee32;_0x173c55[_0x3b5245('0xe29')]=_0x434610['rows']||[];})[_0x12ee32('0x1166')](function(){const _0x585ba3=_0x12ee32;return _0xc0b726[_0x585ba3('0x17aa')][_0x585ba3('0xd83')]({'userProfileId':_0x173c55[_0x585ba3('0x98')][_0x585ba3('0xb86')],'sectionId':0x3ed})['$promise'];})['then'](function(_0x2e4131){const _0x5340bd=_0x12ee32,_0x1f2350=_0x2e4131&&_0x2e4131[_0x5340bd('0x269a')]?_0x2e4131['rows'][0x0]:null;if(!_0x1f2350)_0x173c55[_0x5340bd('0xe29')]=[];else{if(!_0x1f2350[_0x5340bd('0x1a2b')])return _0xc0b726[_0x5340bd('0x4b5')][_0x5340bd('0xd83')]({'sectionId':_0x1f2350['id']})['$promise'][_0x5340bd('0x1166')](function(_0x339e91){const _0x417d9e=_0x5340bd,_0x10f7b8=_0x2cfb05()[_0x417d9e('0x2563')](_0x339e91[_0x417d9e('0x269a')],function(_0x3738be){const _0x1a96f3=_0x417d9e;return _0x2cfb05()[_0x1a96f3('0xc38')](_0x173c55[_0x1a96f3('0xe29')],{'id':_0x3738be[_0x1a96f3('0x24e8')]});});_0x173c55[_0x417d9e('0xe29')][_0x417d9e('0x2782')](function(_0x13a57b){const _0x3321d1=_0x417d9e;!_0x2cfb05()[_0x3321d1('0x1798')](_0x10f7b8,['id',_0x13a57b['id']])&&(_0x13a57b['canSelect']=![]),_0x10f7b8['push'](_0x13a57b);}),_0x173c55[_0x417d9e('0xe29')]=_0x10f7b8;});}})[_0x12ee32('0x1a80')](function(_0x1dbc00){const _0x508893=_0x12ee32;_0x9abcfb[_0x508893('0xfc9')]({'title':_0x1dbc00[_0x508893('0x52d')]?'API:'+_0x1dbc00[_0x508893('0x52d')]+_0x508893('0x11e1')+_0x1dbc00[_0x508893('0xe1b')]:_0x508893('0x1488'),'msg':_0x1dbc00['data']?JSON[_0x508893('0xbac')](_0x1dbc00[_0x508893('0x25f4')]):_0x1dbc00[_0x508893('0x1586')]()});});function _0x269097(){const _0x5c0c4d=_0x12ee32;if(_0x2a94bb[_0x5c0c4d('0x1ac6')](_0x5c0c4d('0xa7c')))_0x36d5a1['go']('app.fax.realtime.accounts',{});else return _0xc0b726[_0x5c0c4d('0x17aa')][_0x5c0c4d('0xd83')]({'userProfileId':_0x2a94bb[_0x5c0c4d('0x26cd')]()['userProfileId'],'sectionId':0x38e})['$promise'][_0x5c0c4d('0x1166')](function(_0x5a5a7){const _0x545ac0=_0x5c0c4d,_0x54b134=_0x5a5a7&&_0x5a5a7[_0x545ac0('0x269a')]?_0x5a5a7[_0x545ac0('0x269a')][0x0]:null;_0x54b134&&_0x54b134[_0x545ac0('0xc27')]?_0x36d5a1['go'](_0x545ac0('0x2765'),{}):_0x9abcfb[_0x545ac0('0x1fa1')]({'title':_0x280015[_0x545ac0('0x25cc')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x280015[_0x545ac0('0x25cc')](_0x545ac0('0x2642'))});})[_0x5c0c4d('0x1a80')](function(_0x57ed7c){const _0x504ec0=_0x5c0c4d;_0x9abcfb[_0x504ec0('0xfc9')]({'title':_0x57ed7c['status']?_0x504ec0('0x1e21')+_0x57ed7c['status']+'\x20-\x20'+_0x57ed7c[_0x504ec0('0xe1b')]:_0x504ec0('0x153e'),'msg':_0x57ed7c[_0x504ec0('0x52d')]?JSON[_0x504ec0('0xbac')](_0x57ed7c['data']):_0x57ed7c['toString']()});});}function _0x4f5845(_0x50b72c,_0x541ea0){const _0x5675f6=_0x12ee32;_0x485eca[_0x5675f6('0x1f80')]({'controller':_0x5675f6('0x1be1'),'controllerAs':'vm','templateUrl':_0x111421,'parent':angular[_0x5675f6('0x1194')](_0x559a7a[_0x5675f6('0x8d2')]),'targetEvent':_0x541ea0,'clickOutsideToClose':!![],'locals':{'faxAccount':_0x50b72c,'faxAccounts':_0x173c55[_0x5675f6('0xd6c')]?_0x173c55[_0x5675f6('0xd6c')][_0x5675f6('0x269a')]:[],'crudPermissions':_0x173c55[_0x5675f6('0x243c')],'realtime':![]}});}function _0x2034ac(){const _0x51ca02=_0x12ee32;_0x36d5a1['go']('app.fax.faxAccounts',{},{'reload':_0x51ca02('0x1c56')});}function _0x544f83(){const _0x456883=_0x12ee32;_0xc0b726[_0x456883('0x2085')][_0x456883('0xf0d')](_0x173c55[_0x456883('0x2085')])[_0x456883('0xa44')][_0x456883('0x1166')](function(){const _0x2a352e=_0x456883;_0x9abcfb[_0x2a352e('0x103b')]({'title':_0x2a352e('0x323'),'msg':_0x173c55[_0x2a352e('0x2085')][_0x2a352e('0x4f0')]?_0x173c55[_0x2a352e('0x2085')]['name']+_0x2a352e('0xa17'):''});})[_0x456883('0x1a80')](function(_0x2211b4){const _0x2d46fb=_0x456883;_0x9abcfb[_0x2d46fb('0xfc9')]({'title':_0x2211b4[_0x2d46fb('0x52d')]?_0x2d46fb('0x1e21')+_0x2211b4[_0x2d46fb('0x52d')]+_0x2d46fb('0x11e1')+_0x2211b4[_0x2d46fb('0xe1b')]:_0x2d46fb('0x8b1'),'msg':_0x2211b4['data']?JSON[_0x2d46fb('0xbac')](_0x2211b4[_0x2d46fb('0x25f4')]):_0x2211b4['toString']()});});}}const _0x89f817=_0x3b7eae,_0x4e1d53=_0x2734b2['p']+'src/js/modules/main/apps/fax/views/faxAccounts/create/dialog.html/dialog.html';_0x1abf26['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state','$mdSidenav',_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0xd6c'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),'Auth','license',_0x36e6f4('0xf8a')];function _0x1abf26(_0x43e52e,_0x316555,_0x322e18,_0x3ddfed,_0xffcc77,_0x29ffb8,_0x25ee0b,_0x5b59f9,_0x5c40ac,_0x16bf81,_0x2f492b,_0x4b6f1c,_0x5aef81,_0x4c62f5,_0x5968be,_0x2c51d9,_0x2c6639){const _0x4108d6=_0x36e6f4,_0xac14fa=this;_0xac14fa[_0x4108d6('0x5c9')]=_0x2c51d9,_0xac14fa[_0x4108d6('0xf8a')]=_0x2c6639,_0xac14fa['currentUser']=_0x5968be['getCurrentUser'](),_0xac14fa['faxAccounts']=_0x5c40ac||{'count':0x0,'rows':[]},_0xac14fa['userProfile']=_0x16bf81,_0xac14fa[_0x4108d6('0x17aa')]=_0x2f492b&&_0x2f492b['count']==0x1?_0x2f492b[_0x4108d6('0x269a')][0x0]:null,_0xac14fa['crudPermissions']=_0x5968be[_0x4108d6('0xd87')](_0xac14fa['userProfileSection']?_0xac14fa[_0x4108d6('0x17aa')][_0x4108d6('0x243c')]:null),_0xac14fa[_0x4108d6('0x916')]=_0x4108d6('0xd6c'),_0xac14fa[_0x4108d6('0xef5')]='',_0xac14fa[_0x4108d6('0x104c')]=null,_0xac14fa['selectedFaxAccounts']=[],_0xac14fa[_0x4108d6('0x2218')]={'fields':_0x4108d6('0x241f'),'sort':_0x4108d6('0x14dc'),'limit':0xa,'page':0x1},_0xac14fa[_0x4108d6('0x1aff')]=_0x2cfb05()[_0x4108d6('0x155c')]([{'option':'yes','value':'\x27yes\x27'},{'option':'no','value':_0x4108d6('0x119b')}],function(_0x2b1535){const _0x4f4480=_0x4108d6;return _0x2cfb05()[_0x4f4480('0xf3')](_0x2b1535['value'],new RegExp('\x27','g'),'');}),_0xac14fa['arrayminrate']=_0x2cfb05()[_0x4108d6('0x155c')]([{'option':_0x4108d6('0x2426'),'value':_0x4108d6('0x76f')},{'option':_0x4108d6('0xa79'),'value':'\x274800\x27'},{'option':_0x4108d6('0x16b5'),'value':_0x4108d6('0x219')},{'option':_0x4108d6('0x2554'),'value':_0x4108d6('0xeb8')},{'option':_0x4108d6('0x169e'),'value':_0x4108d6('0x23df')},{'option':_0x4108d6('0xe76'),'value':_0x4108d6('0x13f')}],function(_0x3951e3){const _0x1e0a5f=_0x4108d6;return _0x2cfb05()[_0x1e0a5f('0xf3')](_0x3951e3[_0x1e0a5f('0x18e0')],new RegExp('\x27','g'),'');}),_0xac14fa['arraymaxrate']=_0x2cfb05()[_0x4108d6('0x155c')]([{'option':'2400','value':_0x4108d6('0x76f')},{'option':_0x4108d6('0xa79'),'value':_0x4108d6('0x2556')},{'option':_0x4108d6('0x16b5'),'value':_0x4108d6('0x219')},{'option':_0x4108d6('0x2554'),'value':_0x4108d6('0xeb8')},{'option':_0x4108d6('0x169e'),'value':_0x4108d6('0x23df')},{'option':_0x4108d6('0xe76'),'value':'\x2714400\x27'}],function(_0x1685ef){const _0x17afd7=_0x4108d6;return _0x2cfb05()[_0x17afd7('0xf3')](_0x1685ef['value'],new RegExp('\x27','g'),'');}),_0xac14fa[_0x4108d6('0x1bad')]=_0x2cfb05()[_0x4108d6('0x155c')]([{'option':'SIP','value':_0x4108d6('0x1f66')},{'option':'IAX','value':_0x4108d6('0x26d3')},{'option':_0x4108d6('0x1a48'),'value':_0x4108d6('0x46b')},{'option':'KHOMP','value':_0x4108d6('0x15be')}],function(_0x160ec5){const _0x34330e=_0x4108d6;return _0x2cfb05()[_0x34330e('0xf3')](_0x160ec5[_0x34330e('0x18e0')],new RegExp('\x27','g'),'');}),_0xac14fa[_0x4108d6('0x1ff6')]=_0x55e0e7,_0xac14fa[_0x4108d6('0x5e9')]=_0x2c8d00,_0xac14fa[_0x4108d6('0x182d')]=_0x4a8282,_0xac14fa[_0x4108d6('0x1728')]=_0x3244eb,_0xac14fa[_0x4108d6('0x8d8')]=_0x1ba15a,_0xac14fa[_0x4108d6('0x103b')]=_0x12d702,_0xac14fa[_0x4108d6('0x1f63')]=_0x2f325c,_0xac14fa['createOrEditFaxAccount']=_0x1f3ff5,_0xac14fa[_0x4108d6('0x1ea3')]=_0x451c7e,_0xac14fa[_0x4108d6('0xe8e')]=_0x1be8ea,_0xac14fa[_0x4108d6('0x12aa')]=_0x5530a7,_0xac14fa[_0x4108d6('0x2045')]=_0x4a9a04,_0xac14fa[_0x4108d6('0x264c')]=_0x383222,_0x5968be[_0x4108d6('0x1ac6')](_0x4108d6('0xa7c'))?_0x4b6f1c['trunk']['get']({'fields':_0x4108d6('0x1776'),'sort':_0x4108d6('0x4f0')})[_0x4108d6('0xa44')][_0x4108d6('0x1166')](function(_0x5ecfa7){const _0x3449d2=_0x4108d6;_0xac14fa[_0x3449d2('0xf24')]=_0x5ecfa7['rows']||[];})[_0x4108d6('0x1a80')](function(_0x56506d){const _0x5d8a96=_0x4108d6;_0x4c62f5[_0x5d8a96('0xfc9')]({'title':_0x56506d[_0x5d8a96('0x52d')]?_0x5d8a96('0x1e21')+_0x56506d[_0x5d8a96('0x52d')]+'\x20-\x20'+_0x56506d[_0x5d8a96('0xe1b')]:'SYSTEM:GET_TRUNKS','msg':_0x56506d[_0x5d8a96('0x25f4')]?JSON[_0x5d8a96('0xbac')](_0x56506d['data']):_0x56506d[_0x5d8a96('0x1586')]()});}):_0x4b6f1c[_0x4108d6('0x3b2')][_0x4108d6('0xd83')]({'fields':_0x4108d6('0x1776'),'sort':'name'})[_0x4108d6('0xa44')][_0x4108d6('0x1166')](function(_0x2bedc5){const _0x5eeb7d=_0x4108d6;_0xac14fa['trunks']=_0x2bedc5[_0x5eeb7d('0x269a')]||[];})[_0x4108d6('0x1166')](function(){const _0x3a611e=_0x4108d6;return _0x4b6f1c[_0x3a611e('0x17aa')][_0x3a611e('0xd83')]({'userProfileId':_0xac14fa['currentUser'][_0x3a611e('0xb86')],'sectionId':0x3f3})[_0x3a611e('0xa44')];})[_0x4108d6('0x1166')](function(_0x52bda2){const _0x4011a1=_0x4108d6,_0x58381b=_0x52bda2&&_0x52bda2['rows']?_0x52bda2['rows'][0x0]:null;if(!_0x58381b){const _0xd611df=[],_0x715478=[];_0xac14fa[_0x4011a1('0xd6c')][_0x4011a1('0x269a')][_0x4011a1('0x2782')](function(_0x89ef27){const _0xd8de68=_0x4011a1,_0x4d3160=_0x2cfb05()[_0xd8de68('0xc38')](_0xac14fa[_0xd8de68('0xf24')],{'id':Number(_0x89ef27[_0xd8de68('0x1ce4')])});_0x715478[_0xd8de68('0x1514')](_0x4d3160);});for(let _0x32f109=0x0;_0x32f109<_0xac14fa['trunks'][_0x4011a1('0x264b')];_0x32f109++){const _0x30a798=_0x2cfb05()[_0x4011a1('0x1798')](_0x715478,{'id':_0xac14fa[_0x4011a1('0xf24')][_0x32f109]['id']});_0x30a798&&(_0xac14fa[_0x4011a1('0xf24')][_0x32f109]['canSelect']=![],_0xd611df['push'](_0xac14fa[_0x4011a1('0xf24')][_0x32f109]));}_0xac14fa[_0x4011a1('0xf24')]=_0xd611df;}else{if(!_0x58381b[_0x4011a1('0x1a2b')])return _0x4b6f1c[_0x4011a1('0x4b5')][_0x4011a1('0xd83')]({'sectionId':_0x58381b['id']})[_0x4011a1('0xa44')]['then'](function(_0x523c36){const _0x43a2ab=_0x4011a1,_0x983851=_0x2cfb05()[_0x43a2ab('0x2563')](_0x523c36[_0x43a2ab('0x269a')],function(_0x34d966){const _0x47302c=_0x43a2ab;return _0x2cfb05()[_0x47302c('0xc38')](_0xac14fa[_0x47302c('0xf24')],{'id':_0x34d966[_0x47302c('0x24e8')]});});let _0x189326=null;_0x189326=[],_0xac14fa[_0x43a2ab('0xd6c')][_0x43a2ab('0x269a')][_0x43a2ab('0x2782')](function(_0x5c49dc){const _0x2c8e73=_0x43a2ab,_0x746c65=_0x2cfb05()[_0x2c8e73('0xc38')](_0xac14fa['trunks'],{'id':Number(_0x5c49dc[_0x2c8e73('0x1ce4')])});_0x189326[_0x2c8e73('0x1514')](_0x746c65);}),!_0x2cfb05()['isEmpty'](_0x189326)&&_0x189326[_0x43a2ab('0x2782')](function(_0x15e65c){const _0x31f77a=_0x43a2ab;if(!_0x2cfb05()[_0x31f77a('0x1798')](_0x983851,['id',_0x15e65c['id']])){const _0xdb659c=_0x2cfb05()['find'](_0xac14fa[_0x31f77a('0xf24')],{'id':_0x15e65c['id']});_0xdb659c['canSelect']=![],_0x983851[_0x31f77a('0x1514')](_0xdb659c);}}),_0xac14fa[_0x43a2ab('0xf24')]=_0x983851;});}})['catch'](function(_0x150010){const _0x3634a0=_0x4108d6;_0x4c62f5[_0x3634a0('0xfc9')]({'title':_0x150010[_0x3634a0('0x52d')]?_0x3634a0('0x1e21')+_0x150010[_0x3634a0('0x52d')]+_0x3634a0('0x11e1')+_0x150010[_0x3634a0('0xe1b')]:_0x3634a0('0x1d44'),'msg':_0x150010[_0x3634a0('0x25f4')]?JSON[_0x3634a0('0xbac')](_0x150010[_0x3634a0('0x25f4')]):_0x150010[_0x3634a0('0x1586')]()});}),_0x5968be[_0x4108d6('0x1ac6')](_0x4108d6('0xa7c'))?_0x4b6f1c[_0x4108d6('0xdd9')]['get']({'fields':_0x4108d6('0x1776'),'sort':_0x4108d6('0x4f0')})[_0x4108d6('0xa44')][_0x4108d6('0x1166')](function(_0xf55267){_0xac14fa['lists']=_0xf55267['rows']||[];})['catch'](function(_0x47e005){const _0x4dcc90=_0x4108d6;_0x4c62f5[_0x4dcc90('0xfc9')]({'title':_0x47e005[_0x4dcc90('0x52d')]?_0x4dcc90('0x1e21')+_0x47e005[_0x4dcc90('0x52d')]+'\x20-\x20'+_0x47e005[_0x4dcc90('0xe1b')]:_0x4dcc90('0x520'),'msg':_0x47e005[_0x4dcc90('0x25f4')]?JSON[_0x4dcc90('0xbac')](_0x47e005[_0x4dcc90('0x25f4')]):_0x47e005['toString']()});}):_0x4b6f1c[_0x4108d6('0xdd9')][_0x4108d6('0xd83')]({'fields':_0x4108d6('0x1776'),'sort':'name'})[_0x4108d6('0xa44')][_0x4108d6('0x1166')](function(_0x3d51ca){const _0x126747=_0x4108d6;_0xac14fa['lists']=_0x3d51ca[_0x126747('0x269a')]||[];})['then'](function(){const _0x189875=_0x4108d6;return _0x4b6f1c[_0x189875('0x17aa')][_0x189875('0xd83')]({'userProfileId':_0xac14fa['currentUser'][_0x189875('0xb86')],'sectionId':0x12d})[_0x189875('0xa44')];})[_0x4108d6('0x1166')](function(_0x2c4d76){const _0x19db3d=_0x4108d6,_0x2378b3=_0x2c4d76&&_0x2c4d76[_0x19db3d('0x269a')]?_0x2c4d76[_0x19db3d('0x269a')][0x0]:null;if(!_0x2378b3){const _0x164999=[];let _0x29966a=null;_0xac14fa['faxAccount']&&(_0x29966a=_0x2cfb05()[_0x19db3d('0xc38')](_0xac14fa[_0x19db3d('0x8de')],{'id':Number(_0xac14fa[_0x19db3d('0x2085')]['ListId'])}));for(let _0x3b9222=0x0;_0x3b9222<_0xac14fa[_0x19db3d('0x8de')][_0x19db3d('0x264b')];_0x3b9222++){_0x29966a&&_0xac14fa['lists'][_0x3b9222]['id']===_0x29966a['id']&&(_0xac14fa[_0x19db3d('0x8de')][_0x3b9222]['canSelect']=![],_0x164999[_0x19db3d('0x1514')](_0xac14fa[_0x19db3d('0x8de')][_0x3b9222]));}_0xac14fa['lists']=_0x164999;}else{if(!_0x2378b3[_0x19db3d('0x1a2b')])return _0x4b6f1c[_0x19db3d('0x4b5')]['get']({'sectionId':_0x2378b3['id']})[_0x19db3d('0xa44')][_0x19db3d('0x1166')](function(_0x10f9d1){const _0x198544=_0x19db3d,_0x29f5bb=_0x2cfb05()[_0x198544('0x2563')](_0x10f9d1['rows'],function(_0x4be0a4){const _0x5c9138=_0x198544;return _0x2cfb05()['find'](_0xac14fa[_0x5c9138('0x8de')],{'id':_0x4be0a4[_0x5c9138('0x24e8')]});});let _0x40caec=null;_0xac14fa[_0x198544('0x2085')]&&(_0x40caec=_0x2cfb05()['find'](_0xac14fa['lists'],{'id':Number(_0xac14fa['faxAccount'][_0x198544('0x23c')])}));if(_0x40caec&&!_0x2cfb05()['some'](_0x29f5bb,['id',_0x40caec['id']])){const _0x68d839=_0x2cfb05()[_0x198544('0xc38')](_0xac14fa[_0x198544('0x8de')],{'id':_0x40caec['id']});_0x68d839[_0x198544('0x2378')]=![],_0x29f5bb[_0x198544('0x1514')](_0x68d839);}_0xac14fa[_0x198544('0x8de')]=_0x29f5bb;});}})[_0x4108d6('0x1a80')](function(_0xb48618){const _0x4253c0=_0x4108d6;_0x4c62f5[_0x4253c0('0xfc9')]({'title':_0xb48618[_0x4253c0('0x52d')]?_0x4253c0('0x1e21')+_0xb48618[_0x4253c0('0x52d')]+'\x20-\x20'+_0xb48618[_0x4253c0('0xe1b')]:_0x4253c0('0x1248'),'msg':_0xb48618[_0x4253c0('0x25f4')]?JSON['stringify'](_0xb48618['data']):_0xb48618[_0x4253c0('0x1586')]()});});function _0x55e0e7(_0x2c9ee0){const _0xa22be9=_0x4108d6;_0x322e18['go'](_0xa22be9('0x140b'),{'id':_0x2c9ee0['id'],'faxAccount':_0x2c9ee0,'crudPermissions':_0xac14fa[_0xa22be9('0x243c')]});}function _0x2c8d00(_0x2c8a3c){_0x322e18['go']('app.fax.faxAccounts.edit',{'id':_0x2c8a3c['id'],'tab':0x5});}function _0x4a8282(){const _0xb29d28=_0x4108d6;if(_0x5968be[_0xb29d28('0x1ac6')](_0xb29d28('0xa7c')))_0x322e18['go'](_0xb29d28('0x2765'),{});else return _0x4b6f1c[_0xb29d28('0x17aa')]['get']({'userProfileId':_0x5968be[_0xb29d28('0x26cd')]()['userProfileId'],'sectionId':0x38e})['$promise'][_0xb29d28('0x1166')](function(_0x18450d){const _0x150b49=_0xb29d28,_0x457658=_0x18450d&&_0x18450d['rows']?_0x18450d['rows'][0x0]:null;_0x457658&&_0x457658['enabled']?_0x322e18['go']('app.fax.realtime.accounts',{}):_0x4c62f5[_0x150b49('0x1fa1')]({'title':_0x5b59f9[_0x150b49('0x25cc')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x5b59f9[_0x150b49('0x25cc')](_0x150b49('0x2642'))});})['catch'](function(_0x260982){const _0x2b7318=_0xb29d28;_0x4c62f5[_0x2b7318('0xfc9')]({'title':_0x260982[_0x2b7318('0x52d')]?_0x2b7318('0x1e21')+_0x260982[_0x2b7318('0x52d')]+'\x20-\x20'+_0x260982['statusText']:_0x2b7318('0x153e'),'msg':_0x260982[_0x2b7318('0x52d')]?JSON[_0x2b7318('0xbac')](_0x260982[_0x2b7318('0x25f4')]):_0x260982['toString']()});});}function _0x3244eb(_0x593d33,_0x221b90){const _0x499d95=_0x4108d6;_0xffcc77[_0x499d95('0x1f80')]({'controller':_0x499d95('0x1be1'),'controllerAs':'vm','templateUrl':_0x111421,'parent':angular[_0x499d95('0x1194')](_0x29ffb8['body']),'targetEvent':_0x221b90,'clickOutsideToClose':!![],'locals':{'faxAccount':_0x593d33,'faxAccounts':_0xac14fa[_0x499d95('0xd6c')]?_0xac14fa[_0x499d95('0xd6c')][_0x499d95('0x269a')]:[],'crudPermissions':_0xac14fa[_0x499d95('0x243c')],'realtime':![]}});}function _0x1ba15a(_0x2c942f,_0x32d27f){const _0x14b088=_0x4108d6,_0x159450=_0xffcc77['confirm']()['title'](_0x14b088('0x288d')+_0x2cfb05()['startCase'](_0x14b088('0x2085'))+'?')['htmlContent'](''+(_0x2c942f['name']||'faxAccount')+_0x14b088('0xace')+_0x14b088('0x3f3'))[_0x14b088('0x8e8')](_0x14b088('0x1d60'))[_0x14b088('0x203b')](_0x32d27f)['ok']('OK')[_0x14b088('0x3f')](_0x14b088('0x2d3'));_0xffcc77['show'](_0x159450)[_0x14b088('0x1166')](function(){_0x451c7e(_0x2c942f);},function(){const _0x59865f=_0x14b088;console['log'](_0x59865f('0x2d3'));});}let _0x43c879=!![],_0x5f2d15=0x1;_0x43e52e[_0x4108d6('0xe83')](_0x4108d6('0x12d8'),function(_0x1c8336,_0x1826ea){const _0xeb8e50=_0x4108d6;_0x43c879?_0x25ee0b(function(){_0x43c879=![];}):(!_0x1826ea&&(_0x5f2d15=_0xac14fa['query']['page']),_0x1c8336!==_0x1826ea&&(_0xac14fa['query'][_0xeb8e50('0x1a43')]=0x1),!_0x1c8336&&(_0xac14fa[_0xeb8e50('0x2218')][_0xeb8e50('0x1a43')]=_0x5f2d15),_0xac14fa[_0xeb8e50('0x1f63')]());});function _0x12d702(_0x467dc2){const _0x26e871=_0x4108d6;_0xac14fa[_0x26e871('0xd6c')]=_0x467dc2||{'count':0x0,'rows':[]};}function _0x2f325c(){const _0x35cbb9=_0x4108d6;_0xac14fa[_0x35cbb9('0x2218')][_0x35cbb9('0x1098')]=(_0xac14fa['query']['page']-0x1)*_0xac14fa[_0x35cbb9('0x2218')][_0x35cbb9('0x163f')],_0x5968be[_0x35cbb9('0x1ac6')](_0x35cbb9('0xa7c'))?_0xac14fa[_0x35cbb9('0x1f48')]=_0x4b6f1c[_0x35cbb9('0x2085')][_0x35cbb9('0xd83')](_0xac14fa[_0x35cbb9('0x2218')],_0x12d702)[_0x35cbb9('0xa44')]:(_0xac14fa[_0x35cbb9('0x2218')]['id']=_0xac14fa[_0x35cbb9('0x7f')]['id'],_0xac14fa[_0x35cbb9('0x2218')][_0x35cbb9('0xe60')]=_0x35cbb9('0x1c3b'),_0xac14fa[_0x35cbb9('0x1f48')]=_0x4b6f1c[_0x35cbb9('0x7f')]['getResources'](_0xac14fa[_0x35cbb9('0x2218')],_0x12d702)[_0x35cbb9('0xa44')]);}function _0x1f3ff5(_0x137f3a,_0x3884f1){const _0x31e643=_0x4108d6;_0xffcc77[_0x31e643('0x1f80')]({'controller':_0x31e643('0x830'),'controllerAs':'vm','templateUrl':_0x4e1d53,'parent':angular['element'](_0x29ffb8[_0x31e643('0x8d2')]),'targetEvent':_0x137f3a,'clickOutsideToClose':!![],'locals':{'faxAccount':_0x3884f1,'faxAccounts':_0xac14fa[_0x31e643('0xd6c')][_0x31e643('0x269a')],'license':_0xac14fa[_0x31e643('0x5c9')],'setting':_0xac14fa[_0x31e643('0xf8a')],'crudPermissions':_0xac14fa[_0x31e643('0x243c')]}});}function _0x451c7e(_0x21e57b){const _0x35e9b5=_0x4108d6;_0x4b6f1c['faxAccount'][_0x35e9b5('0x906')]({'id':_0x21e57b['id']})[_0x35e9b5('0xa44')]['then'](function(){const _0x49c2a1=_0x35e9b5;_0x2cfb05()['remove'](_0xac14fa['faxAccounts'][_0x49c2a1('0x269a')],{'id':_0x21e57b['id']}),_0xac14fa[_0x49c2a1('0xd6c')][_0x49c2a1('0x240f')]-=0x1,!_0xac14fa[_0x49c2a1('0xd6c')][_0x49c2a1('0x269a')]['length']&&_0xac14fa[_0x49c2a1('0x1f63')](),_0x4c62f5[_0x49c2a1('0x103b')]({'title':_0x2cfb05()[_0x49c2a1('0xb35')](_0x49c2a1('0x21f'))+_0x49c2a1('0x2b6'),'msg':_0x21e57b[_0x49c2a1('0x4f0')]?_0x21e57b[_0x49c2a1('0x4f0')]+_0x49c2a1('0x7cd'):''});})[_0x35e9b5('0x1a80')](function(_0x3f1aaa){const _0x1a0b2a=_0x35e9b5;if(_0x3f1aaa['data']&&_0x3f1aaa[_0x1a0b2a('0x25f4')][_0x1a0b2a('0x61a')]&&_0x3f1aaa[_0x1a0b2a('0x25f4')]['errors']['length']){_0xac14fa['errors']=_0x3f1aaa[_0x1a0b2a('0x25f4')][_0x1a0b2a('0x61a')]||[{'message':_0x3f1aaa['toString'](),'type':'SYSTEM:DELETEfaxAccount'}];for(let _0x570fe9=0x0;_0x570fe9<_0x3f1aaa[_0x1a0b2a('0x25f4')]['errors'][_0x1a0b2a('0x264b')];_0x570fe9++){_0x4c62f5[_0x1a0b2a('0xfc9')]({'title':_0x3f1aaa[_0x1a0b2a('0x25f4')]['errors'][_0x570fe9][_0x1a0b2a('0x1345')],'msg':_0x3f1aaa[_0x1a0b2a('0x25f4')][_0x1a0b2a('0x61a')][_0x570fe9][_0x1a0b2a('0x1e70')]});}}else _0x4c62f5[_0x1a0b2a('0xfc9')]({'title':_0x3f1aaa[_0x1a0b2a('0x52d')]?'API:'+_0x3f1aaa[_0x1a0b2a('0x52d')]+'\x20-\x20'+_0x3f1aaa[_0x1a0b2a('0xe1b')]:_0x1a0b2a('0xef4'),'msg':_0x3f1aaa[_0x1a0b2a('0x25f4')]?JSON[_0x1a0b2a('0xbac')](_0x3f1aaa[_0x1a0b2a('0x25f4')][_0x1a0b2a('0x1e70')]):_0x3f1aaa[_0x1a0b2a('0x1e70')]||_0x3f1aaa[_0x1a0b2a('0x1586')]()});});}function _0x1be8ea(){const _0x14c457=_0x4108d6,_0x2677e0=angular[_0x14c457('0x225f')](_0xac14fa['selectedFaxAccounts']);return _0xac14fa['selectedFaxAccounts']=[],_0x2677e0;}function _0x5530a7(_0x2250bf){const _0x32fa36=_0x4108d6,_0x587b3f=_0xffcc77[_0x32fa36('0x1d26')]()[_0x32fa36('0xcdc')](_0x32fa36('0x186d'))['htmlContent'](_0x32fa36('0x12b5')+_0xac14fa['selectedFaxAccounts'][_0x32fa36('0x264b')]+_0x32fa36('0x196d')+_0x32fa36('0x3f3'))[_0x32fa36('0x8e8')](_0x32fa36('0x1722'))[_0x32fa36('0x203b')](_0x2250bf)['ok']('OK')[_0x32fa36('0x3f')](_0x32fa36('0x2d3'));_0xffcc77['show'](_0x587b3f)[_0x32fa36('0x1166')](function(){const _0x6f67ba=_0x32fa36;_0xac14fa[_0x6f67ba('0x6d9')][_0x6f67ba('0x2782')](function(_0x1d406b){_0x451c7e(_0x1d406b);}),_0xac14fa['selectedFaxAccounts']=[];});}function _0x4a9a04(){const _0xacde65=_0x4108d6;_0xac14fa[_0xacde65('0x6d9')]=[];}function _0x383222(){const _0x3e6242=_0x4108d6;_0xac14fa[_0x3e6242('0x6d9')]=_0xac14fa[_0x3e6242('0xd6c')][_0x3e6242('0x269a')];}}const _0x121a06=_0x1abf26;_0x1afed8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x2382'),_0x36e6f4('0x1a5b'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x1afed8(_0x3e08c4,_0x67bbec,_0x5b99c4,_0x3bebb4,_0x4a5559,_0x59c968,_0x465b37,_0x2c7118,_0x222513,_0x355d84,_0x362161,_0x311cb5,_0x54f2d0,_0x26564b){const _0x34220d=_0x36e6f4,_0x487aa0=this;_0x487aa0[_0x34220d('0x98')]=_0x362161[_0x34220d('0x26cd')](),_0x487aa0[_0x34220d('0x61a')]=[],_0x487aa0['setting']=_0x54f2d0,_0x487aa0[_0x34220d('0x5c9')]=_0x311cb5,_0x487aa0[_0x34220d('0x243c')]=_0x26564b,_0x487aa0[_0x34220d('0x128b')]={},_0x487aa0[_0x34220d('0x2900')]=_0x487aa0[_0x34220d('0xf8a')]&&_0x487aa0[_0x34220d('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x487aa0['title']='FAX.EDIT_FAXQUEUE',_0x487aa0[_0x34220d('0x1a5b')]=angular['copy'](_0x222513),_0x487aa0[_0x34220d('0x2382')]=_0x2c7118,_0x487aa0[_0x34220d('0x111e')]=![];!_0x487aa0[_0x34220d('0x1a5b')]&&(_0x487aa0[_0x34220d('0x1a5b')]={'strategy':_0x34220d('0x278c'),'timeout':0xa},_0x487aa0['title']='FAX.NEW_FAXQUEUE',_0x487aa0['newFaxQueue']=!![]);_0x487aa0[_0x34220d('0xc7c')]=_0x250b75,_0x487aa0['saveFaxQueue']=_0x12a790,_0x487aa0[_0x34220d('0x274')]=_0x4cdd56,_0x487aa0[_0x34220d('0x1a9c')]=_0x514385,_0x487aa0['closeDialog']=_0xe47735;function _0x250b75(){const _0xf5a546=_0x34220d;_0x487aa0['errors']=[],_0x355d84[_0xf5a546('0x1a5b')][_0xf5a546('0x9cc')](_0x487aa0[_0xf5a546('0x1a5b')])[_0xf5a546('0xa44')][_0xf5a546('0x1166')](function(_0x5adcd8){const _0x485cb3=_0xf5a546;_0x487aa0[_0x485cb3('0x2382')]['unshift'](_0x5adcd8[_0x485cb3('0x2876')]()),_0x465b37['success']({'title':_0x485cb3('0x3db'),'msg':_0x487aa0['faxQueue'][_0x485cb3('0x4f0')]?_0x487aa0[_0x485cb3('0x1a5b')][_0x485cb3('0x4f0')]+'\x20has\x20been\x20created!':''}),_0xe47735(_0x5adcd8);})[_0xf5a546('0x1a80')](function(_0x3e7fb8){const _0x2898b5=_0xf5a546;if(_0x3e7fb8[_0x2898b5('0x25f4')]&&_0x3e7fb8[_0x2898b5('0x25f4')]['errors']&&_0x3e7fb8[_0x2898b5('0x25f4')]['errors'][_0x2898b5('0x264b')]){_0x487aa0[_0x2898b5('0x61a')]=_0x3e7fb8[_0x2898b5('0x25f4')][_0x2898b5('0x61a')]||[{'message':_0x3e7fb8[_0x2898b5('0x1586')](),'type':_0x2898b5('0x831')}];for(let _0x379765=0x0;_0x379765<_0x3e7fb8[_0x2898b5('0x25f4')][_0x2898b5('0x61a')]['length'];_0x379765+=0x1){_0x465b37['error']({'title':_0x3e7fb8[_0x2898b5('0x25f4')][_0x2898b5('0x61a')][_0x379765][_0x2898b5('0x1345')],'msg':_0x3e7fb8['data'][_0x2898b5('0x61a')][_0x379765][_0x2898b5('0x1e70')]});}}else _0x465b37['error']({'title':_0x3e7fb8[_0x2898b5('0x52d')]?_0x2898b5('0x1e21')+_0x3e7fb8['status']+'\x20-\x20'+_0x3e7fb8['statusText']:_0x2898b5('0x831'),'msg':_0x3e7fb8[_0x2898b5('0x25f4')]?JSON['stringify'](_0x3e7fb8['data'][_0x2898b5('0x1e70')]):_0x3e7fb8[_0x2898b5('0x1586')]()});});}function _0x12a790(){const _0x10cf15=_0x34220d;_0x487aa0[_0x10cf15('0x61a')]=[],_0x355d84[_0x10cf15('0x1a5b')]['update']({'id':_0x487aa0[_0x10cf15('0x1a5b')]['id']},_0x487aa0['faxQueue'])[_0x10cf15('0xa44')][_0x10cf15('0x1166')](function(_0x2748e9){const _0x511a21=_0x10cf15,_0x597014=_0x2cfb05()[_0x511a21('0xc38')](_0x487aa0['faxQueues'],{'id':_0x2748e9['id']});_0x597014&&_0x2cfb05()[_0x511a21('0xcc3')](_0x597014,_0x2cfb05()[_0x511a21('0x1a08')](_0x2748e9[_0x511a21('0x2876')](),_0x2cfb05()['keys'](_0x597014))),_0x465b37[_0x511a21('0x103b')]({'title':_0x511a21('0x13'),'msg':_0x487aa0[_0x511a21('0x1a5b')][_0x511a21('0x4f0')]?_0x487aa0[_0x511a21('0x1a5b')][_0x511a21('0x4f0')]+_0x511a21('0x7d'):''}),_0xe47735(_0x2748e9);})[_0x10cf15('0x1a80')](function(_0x35825a){const _0x416cf8=_0x10cf15;if(_0x35825a[_0x416cf8('0x25f4')]&&_0x35825a[_0x416cf8('0x25f4')][_0x416cf8('0x61a')]&&_0x35825a[_0x416cf8('0x25f4')][_0x416cf8('0x61a')][_0x416cf8('0x264b')]){_0x487aa0[_0x416cf8('0x61a')]=_0x35825a[_0x416cf8('0x25f4')]['errors']||[{'message':_0x35825a[_0x416cf8('0x1586')](),'type':_0x416cf8('0x5e7')}];for(let _0x1743a2=0x0;_0x1743a2<_0x35825a[_0x416cf8('0x25f4')]['errors']['length'];_0x1743a2++){_0x465b37[_0x416cf8('0xfc9')]({'title':_0x35825a[_0x416cf8('0x25f4')][_0x416cf8('0x61a')][_0x1743a2]['type'],'msg':_0x35825a['data'][_0x416cf8('0x61a')][_0x1743a2][_0x416cf8('0x1e70')]});}}else _0x465b37['error']({'title':_0x35825a[_0x416cf8('0x52d')]?_0x416cf8('0x1e21')+_0x35825a[_0x416cf8('0x52d')]+_0x416cf8('0x11e1')+_0x35825a['statusText']:_0x416cf8('0x5e7'),'msg':_0x35825a[_0x416cf8('0x25f4')]?JSON[_0x416cf8('0xbac')](_0x35825a['data'][_0x416cf8('0x1e70')]):_0x35825a[_0x416cf8('0x1586')]()});});}function _0x4cdd56(_0x28ac5c){const _0x397156=_0x34220d;_0x487aa0[_0x397156('0x61a')]=[];const _0x50b732=_0x3bebb4[_0x397156('0x1d26')]()['title'](_0x397156('0x7fb'))[_0x397156('0xacc')]('The\x20faxQueue\x20will\x20be\x20deleted.')[_0x397156('0x8e8')](_0x397156('0x27e4'))['ok']('Delete')[_0x397156('0x3f')](_0x397156('0x497'))[_0x397156('0x203b')](_0x28ac5c);_0x3bebb4[_0x397156('0x1f80')](_0x50b732)['then'](function(){const _0x32f570=_0x397156;_0x355d84[_0x32f570('0x1a5b')]['delete']({'id':_0x487aa0['faxQueue']['id']})[_0x32f570('0xa44')][_0x32f570('0x1166')](function(){const _0x41b444=_0x32f570;_0x2cfb05()['remove'](_0x487aa0[_0x41b444('0x2382')],{'id':_0x487aa0['faxQueue']['id']}),_0x465b37[_0x41b444('0x103b')]({'title':_0x41b444('0x1f52'),'msg':(_0x487aa0[_0x41b444('0x1a5b')][_0x41b444('0x4f0')]||'faxQueue')+'\x20has\x20been\x20deleted!'}),_0xe47735(_0x487aa0[_0x41b444('0x1a5b')]);})[_0x32f570('0x1a80')](function(_0xae1dca){const _0x246188=_0x32f570;if(_0xae1dca[_0x246188('0x25f4')]&&_0xae1dca[_0x246188('0x25f4')][_0x246188('0x61a')]&&_0xae1dca[_0x246188('0x25f4')][_0x246188('0x61a')][_0x246188('0x264b')]){_0x487aa0[_0x246188('0x61a')]=_0xae1dca[_0x246188('0x25f4')]['errors']||[{'message':_0xae1dca[_0x246188('0x1586')](),'type':'api.faxQueue.delete'}];for(let _0x1bb870=0x0;_0x1bb870<_0xae1dca[_0x246188('0x25f4')][_0x246188('0x61a')]['length'];_0x1bb870++){_0x465b37['error']({'title':_0xae1dca[_0x246188('0x25f4')]['errors'][_0x1bb870][_0x246188('0x1345')],'msg':_0xae1dca['data'][_0x246188('0x61a')][_0x1bb870][_0x246188('0x1e70')]});}}else _0x465b37['error']({'title':_0xae1dca[_0x246188('0x52d')]?_0x246188('0x1e21')+_0xae1dca[_0x246188('0x52d')]+_0x246188('0x11e1')+_0xae1dca[_0x246188('0xe1b')]:_0x246188('0x1355'),'msg':_0xae1dca[_0x246188('0x25f4')]?JSON[_0x246188('0xbac')](_0xae1dca[_0x246188('0x25f4')]['message']):_0xae1dca['message']||_0xae1dca[_0x246188('0x1586')]()});});},function(){});}function _0x514385(_0x4f59ff){return _0x4f59ff===null?undefined:new Date(_0x4f59ff);}function _0xe47735(_0x3dc8d7){const _0x179798=_0x34220d;_0x3bebb4[_0x179798('0x1197')](_0x3dc8d7);}}const _0x441c6d=_0x1afed8;_0x5955ca[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'api','faxQueue','faxQueues',_0x36e6f4('0xf01'),_0x36e6f4('0x586'),'Auth','crudPermissions'];function _0x5955ca(_0x497864,_0x374e09,_0x55a417,_0xc679a2,_0x2c0086,_0x52b63e,_0x2b5934,_0x4c7377,_0x13d948,_0x591954){const _0x5cdba8=_0x36e6f4,_0x3b9d85=this;_0x3b9d85[_0x5cdba8('0x98')]=_0x13d948['getCurrentUser'](),_0x3b9d85[_0x5cdba8('0x1a5b')]=_0x2c0086,_0x3b9d85[_0x5cdba8('0x243c')]=_0x591954,_0x3b9d85[_0x5cdba8('0xf01')]=_0x2b5934,_0x3b9d85[_0x5cdba8('0xbd7')]=[],_0x3b9d85[_0x5cdba8('0x10ab')]=[],_0x3b9d85['selectedItems']=[],_0x3b9d85[_0x5cdba8('0x2111')]=[],_0x3b9d85[_0x5cdba8('0x2781')]=[],_0x3b9d85[_0x5cdba8('0x14d7')]=![],_0x3b9d85['onInit']=_0x26ca69,_0x3b9d85[_0x5cdba8('0x1d92')]=_0x243b3e,_0x3b9d85['closeDialog']=_0x2df0af,_0x3b9d85[_0x5cdba8('0xc68')]={'readOnly':!_0x3b9d85[_0x5cdba8('0x243c')]['canEdit'],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x5cdba8('0x6e1'),'line2':[_0x5cdba8('0x4f0'),'internal'],'line3':'','labelAll':_0x4c7377[_0x5cdba8('0x25cc')](_0x5cdba8('0x677')),'labelSelected':_0x4c7377['instant'](_0x5cdba8('0x1c03')),'transferCallback':function(){const _0x3f34e9=_0x5cdba8,_0x340ed8=_0x2cfb05()['xorBy'](_0x3b9d85[_0x3f34e9('0x2781')],_0x3b9d85[_0x3f34e9('0x18e1')],'id');_0x3b9d85[_0x3f34e9('0x14d7')]=_0x2cfb05()[_0x3f34e9('0x1081')](_0x340ed8)?![]:!![];}};function _0x26ca69(){const _0x46d56b=_0x5cdba8;return _0x13d948[_0x46d56b('0x1ac6')](_0x46d56b('0xa7c'))?_0x428341()[_0x46d56b('0x1a80')](function(_0x61a6e5){const _0x39ff72=_0x46d56b;_0x55a417[_0x39ff72('0xfc9')]({'title':_0x61a6e5[_0x39ff72('0x52d')]?_0x39ff72('0x1e21')+_0x61a6e5[_0x39ff72('0x52d')]+_0x39ff72('0x11e1')+_0x61a6e5[_0x39ff72('0xe1b')]:_0x39ff72('0xd4c'),'msg':_0x61a6e5[_0x39ff72('0x52d')]?JSON[_0x39ff72('0xbac')](_0x61a6e5['data']):_0x61a6e5[_0x39ff72('0x1586')]()});}):_0x2bda9c()[_0x46d56b('0x1166')](function(_0x124649){const _0x14ba10=_0x46d56b;return _0x3b9d85[_0x14ba10('0xe60')]=_0x124649,_0x428341();})[_0x46d56b('0x1a80')](function(_0xb7ddb){const _0x53bc1e=_0x46d56b;_0x55a417['error']({'title':_0xb7ddb['status']?'API:'+_0xb7ddb[_0x53bc1e('0x52d')]+'\x20-\x20'+_0xb7ddb[_0x53bc1e('0xe1b')]:_0x53bc1e('0xd4c'),'msg':_0xb7ddb[_0x53bc1e('0x52d')]?JSON[_0x53bc1e('0xbac')](_0xb7ddb[_0x53bc1e('0x25f4')]):_0xb7ddb['toString']()});});}function _0x2bda9c(){return _0x374e09(function(_0x294fe0,_0x5b266d){const _0x4dc599=a0_0x3f2c;_0xc679a2[_0x4dc599('0x17aa')]['get']({'userProfileId':_0x3b9d85['currentUser'][_0x4dc599('0xb86')],'name':'Agents'})[_0x4dc599('0xa44')]['then'](function(_0x139149){const _0x2500c1=_0x4dc599,_0x59f3ef=_0x139149&&_0x139149['rows']?_0x139149[_0x2500c1('0x269a')][0x0]:null;_0x294fe0(_0x59f3ef);})[_0x4dc599('0x1a80')](function(_0x3e50af){_0x5b266d(_0x3e50af);});});}function _0x428341(){return _0x374e09(function(_0x474c04,_0x50fae8){const _0x7befb9=a0_0x3f2c;return _0x526455()['then'](function(_0x5c19d9){const _0x3459af=a0_0x3f2c;return _0x3b9d85[_0x3459af('0xbd7')]=_0x5c19d9[_0x3459af('0x269a')]?_0x5c19d9[_0x3459af('0x269a')]:[],_0x13d948[_0x3459af('0x1ac6')](_0x3459af('0xa7c'))?_0x5c19d9:_0x3b9d85['section']?_0x3b9d85[_0x3459af('0xe60')][_0x3459af('0x1a2b')]?_0x5c19d9:_0x1fa7a0():null;})[_0x7befb9('0x1166')](function(_0x5db443){const _0x536824=_0x7befb9,_0x28a181=_0x5db443&&_0x5db443['rows']?_0x5db443[_0x536824('0x269a')]:[];return _0x3b9d85['allowedItems']=_0x2cfb05()[_0x536824('0x2563')](_0x28a181,function(_0x4d504d){const _0x5d6d7f=_0x536824;return _0x2cfb05()[_0x5d6d7f('0xc38')](_0x3b9d85['items'],{'id':_0x13d948[_0x5d6d7f('0x1ac6')](_0x5d6d7f('0xa7c'))||_0x3b9d85[_0x5d6d7f('0xe60')][_0x5d6d7f('0x1a2b')]?_0x4d504d['id']:_0x4d504d[_0x5d6d7f('0x24e8')]});}),_0x3b9d85[_0x536824('0x2111')]=angular[_0x536824('0x225f')](_0x3b9d85['allowedItems']),_0x3b9d85[_0x536824('0xbd7')]['forEach'](function(_0x4e0f82){const _0xc8762b=_0x536824,_0x54369d=_0x2cfb05()['find'](_0x3b9d85['allowedItems'],{'id':_0x4e0f82['id']});_0x13d948[_0xc8762b('0x1ac6')](_0xc8762b('0xa7c'))?_0x4e0f82['isValid']=!![]:_0x4e0f82['isValid']=typeof _0x54369d!==_0xc8762b('0x1048')?!![]:![];}),_0x4a8112();})[_0x7befb9('0x1166')](function(_0x3cd41c){const _0x20e59b=_0x7befb9,_0x49ada5=_0x3cd41c&&_0x3cd41c[_0x20e59b('0x269a')]?_0x3cd41c[_0x20e59b('0x269a')]:[];_0x3b9d85['selectedItems']=_0x2cfb05()['map'](_0x49ada5,function(_0x5bb719){const _0x294d95=_0x20e59b,_0x452078=_0x2cfb05()[_0x294d95('0xc38')](_0x3b9d85[_0x294d95('0xbd7')],{'id':_0x5bb719['id']});return _0x452078[_0x294d95('0x23af')]=_0x5bb719[_0x294d95('0x1193')]?_0x294d95('0x11e8')+_0x5bb719[_0x294d95('0x1193')][_0x294d95('0x23af')]:'',_0x452078[_0x294d95('0x1eef')]=typeof _0x5bb719['internal']!==_0x294d95('0x1048')?'<'+_0x5bb719[_0x294d95('0x1eef')]+'>':'',_0x452078;}),_0x3b9d85[_0x20e59b('0x2781')]=angular[_0x20e59b('0x225f')](_0x3b9d85[_0x20e59b('0x18e1')]),_0x3b9d85[_0x20e59b('0xc68')][_0x20e59b('0x18e1')]=_0x3b9d85[_0x20e59b('0x18e1')],_0x3b9d85[_0x20e59b('0xc68')][_0x20e59b('0xbd7')]=_0x2cfb05()[_0x20e59b('0x24ac')](_0x3b9d85[_0x20e59b('0x10ab')],_0x3b9d85[_0x20e59b('0xc68')]['selectedItems'],'id'),_0x474c04();})[_0x7befb9('0x1a80')](function(_0x1e9438){_0x50fae8(_0x1e9438);});});}function _0x1fa7a0(){return _0x374e09(function(_0x595016,_0x1227a7){const _0x1ebe75=a0_0x3f2c;return _0xc679a2[_0x1ebe75('0x4b5')][_0x1ebe75('0xd83')]({'sectionId':_0x3b9d85[_0x1ebe75('0xe60')]['id'],'nolimit':!![]})['$promise'][_0x1ebe75('0x1166')](function(_0x476087){_0x595016(_0x476087);})[_0x1ebe75('0x1a80')](function(_0x29b3ca){_0x1227a7(_0x29b3ca);});});}function _0x4a8112(){return _0x374e09(function(_0x201b20,_0x413c90){const _0x5ad162=a0_0x3f2c;return _0xc679a2[_0x5ad162('0x1a5b')][_0x5ad162('0x261c')]({'id':_0x3b9d85[_0x5ad162('0x1a5b')]['id'],'fields':_0x5ad162('0x1459'),'nolimit':!![],'role':_0x5ad162('0x1eff')})[_0x5ad162('0xa44')]['then'](function(_0x1e8119){_0x201b20(_0x1e8119);})['catch'](function(_0x3cafbc){_0x413c90(_0x3cafbc);});});}function _0x526455(){return _0x374e09(function(_0x441b90,_0x2087ec){const _0x223e89=a0_0x3f2c;return _0xc679a2[_0x223e89('0x557')][_0x223e89('0xd83')]({'fields':_0x223e89('0x1459'),'nolimit':!![],'role':_0x223e89('0x1eff')})[_0x223e89('0xa44')][_0x223e89('0x1166')](function(_0x204e24){_0x441b90(_0x204e24);})['catch'](function(_0x552e1b){_0x2087ec(_0x552e1b);});});}function _0x3ec6d1(_0x3cd72b){return _0x374e09(function(_0x20ddb1,_0x3cc2fd){const _0x4af1db=a0_0x3f2c;_0x2cfb05()[_0x4af1db('0x1081')](_0x3cd72b)?_0x20ddb1():_0xc679a2[_0x4af1db('0x1a5b')][_0x4af1db('0x275c')]({'id':_0x3b9d85[_0x4af1db('0x1a5b')]['id'],'ids':_0x2cfb05()[_0x4af1db('0x2563')](_0x3cd72b,'id')})[_0x4af1db('0xa44')][_0x4af1db('0x1166')](function(){_0x20ddb1();})[_0x4af1db('0x1a80')](function(_0x5a930b){_0x3cc2fd(_0x5a930b);});});}function _0x368018(_0x49b56a){return _0x374e09(function(_0x57c0bf,_0x11d92e){const _0x1871aa=a0_0x3f2c;_0x2cfb05()[_0x1871aa('0x1081')](_0x49b56a)?_0x57c0bf():_0xc679a2['faxQueue']['removeAgents']({'id':_0x3b9d85['faxQueue']['id'],'ids':_0x2cfb05()[_0x1871aa('0x2563')](_0x49b56a,'id')})['$promise'][_0x1871aa('0x1166')](function(){_0x57c0bf();})[_0x1871aa('0x1a80')](function(_0x3e1873){_0x11d92e(_0x3e1873);});});}function _0x243b3e(){const _0xf30c54=_0x5cdba8,_0x1534a9=_0x2cfb05()['differenceBy'](_0x3b9d85[_0xf30c54('0x2781')],_0x3b9d85[_0xf30c54('0x18e1')],'id'),_0x1f41e8=_0x2cfb05()[_0xf30c54('0x24ac')](_0x3b9d85['selectedItems'],_0x3b9d85['startingSelectedItems'],'id');return _0x368018(_0x1534a9)['then'](function(){return _0x3ec6d1(_0x1f41e8);})['then'](function(){const _0x5f0294=_0xf30c54;_0x3b9d85[_0x5f0294('0x14d7')]=![],_0x3b9d85['startingAllowedItems']=angular['copy'](_0x3b9d85[_0x5f0294('0x10ab')]),_0x3b9d85[_0x5f0294('0x2781')]=angular[_0x5f0294('0x225f')](_0x3b9d85[_0x5f0294('0x18e1')]),_0x55a417[_0x5f0294('0x103b')]({'title':'SUCCESS','msg':_0x5f0294('0x1673')});})[_0xf30c54('0x1a80')](function(_0x13a071){const _0x283ece=_0xf30c54;_0x55a417['error']({'title':_0x13a071[_0x283ece('0x52d')]?'API:'+_0x13a071[_0x283ece('0x52d')]+_0x283ece('0x11e1')+_0x13a071[_0x283ece('0xe1b')]:'SYSTEM:LISTS_ASSOCIATION','msg':_0x13a071[_0x283ece('0x52d')]?JSON[_0x283ece('0xbac')](_0x13a071['data']):_0x13a071['toString']()});});}function _0x2df0af(){const _0x4fbe75=_0x5cdba8;_0x497864[_0x4fbe75('0x1197')]();}}const _0x22fc07=_0x5955ca;_0x2efa29[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1a5b'),'$translate',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x2efa29(_0x59da32,_0x5716f3,_0x266ad8,_0xbfb1b5,_0x39dba0,_0x29becd,_0x5c4405,_0x13a054){const _0x19da1f=_0x36e6f4,_0x1c01a4=this;_0x1c01a4['currentUser']=_0x5c4405[_0x19da1f('0x26cd')](),_0x1c01a4['faxQueue']=_0x39dba0,_0x1c01a4[_0x19da1f('0x243c')]=_0x13a054,_0x1c01a4['items']=[],_0x1c01a4[_0x19da1f('0x10ab')]=[],_0x1c01a4[_0x19da1f('0x18e1')]=[],_0x1c01a4[_0x19da1f('0x2111')]=[],_0x1c01a4[_0x19da1f('0x2781')]=[],_0x1c01a4[_0x19da1f('0x14d7')]=![],_0x1c01a4[_0x19da1f('0xc68')]={'readOnly':!_0x1c01a4[_0x19da1f('0x243c')][_0x19da1f('0x1684')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x19da1f('0x4f0'),'line2':'','line3':'','labelAll':_0x29becd[_0x19da1f('0x25cc')](_0x19da1f('0x4a9')),'labelSelected':_0x29becd['instant'](_0x19da1f('0x27d2')),'transferCallback':function(){const _0x248e17=_0x19da1f,_0x4c85aa=_0x2cfb05()[_0x248e17('0x2802')](_0x1c01a4[_0x248e17('0x2781')],_0x1c01a4[_0x248e17('0x18e1')],'id');_0x1c01a4[_0x248e17('0x14d7')]=_0x2cfb05()[_0x248e17('0x1081')](_0x4c85aa)?![]:!![];}},_0x1c01a4[_0x19da1f('0xae0')]=_0x5941ba,_0x1c01a4['saveTeams']=_0x465497,_0x1c01a4[_0x19da1f('0x24a0')]=_0x207b7b;function _0x5941ba(){const _0xd6210e=_0x19da1f;return _0x5c4405[_0xd6210e('0x1ac6')](_0xd6210e('0xa7c'))?_0x55b404()[_0xd6210e('0x1a80')](function(_0x130cc3){const _0x16bcf3=_0xd6210e;_0x266ad8[_0x16bcf3('0xfc9')]({'title':_0x130cc3['status']?_0x16bcf3('0x1e21')+_0x130cc3[_0x16bcf3('0x52d')]+_0x16bcf3('0x11e1')+_0x130cc3[_0x16bcf3('0xe1b')]:_0x16bcf3('0x1031'),'msg':_0x130cc3[_0x16bcf3('0x52d')]?JSON[_0x16bcf3('0xbac')](_0x130cc3['data']):_0x130cc3[_0x16bcf3('0x1586')]()});}):_0x49f9b8()[_0xd6210e('0x1166')](function(_0x3977ca){return _0x1c01a4['section']=_0x3977ca,_0x55b404();})[_0xd6210e('0x1a80')](function(_0x86cde2){const _0x41403e=_0xd6210e;_0x266ad8[_0x41403e('0xfc9')]({'title':_0x86cde2['status']?_0x41403e('0x1e21')+_0x86cde2[_0x41403e('0x52d')]+'\x20-\x20'+_0x86cde2[_0x41403e('0xe1b')]:'SYSTEM:GET_TEAMS','msg':_0x86cde2['status']?JSON[_0x41403e('0xbac')](_0x86cde2[_0x41403e('0x25f4')]):_0x86cde2['toString']()});});}function _0x49f9b8(){return _0x5716f3(function(_0x4cb6d1,_0x243096){const _0x3df6b0=a0_0x3f2c;_0xbfb1b5[_0x3df6b0('0x17aa')][_0x3df6b0('0xd83')]({'userProfileId':_0x1c01a4[_0x3df6b0('0x98')]['userProfileId'],'name':_0x3df6b0('0x289e')})['$promise'][_0x3df6b0('0x1166')](function(_0x17464b){const _0x16ddfc=_0x3df6b0,_0x4f5ec0=_0x17464b&&_0x17464b[_0x16ddfc('0x269a')]?_0x17464b[_0x16ddfc('0x269a')][0x0]:null;_0x4cb6d1(_0x4f5ec0);})[_0x3df6b0('0x1a80')](function(_0xfc2954){_0x243096(_0xfc2954);});});}function _0x55b404(){return _0x5716f3(function(_0x2d4209,_0x238da4){const _0x44c474=a0_0x3f2c;return _0x8cc397()[_0x44c474('0x1166')](function(_0x411a08){const _0x4b54f0=_0x44c474;return _0x1c01a4[_0x4b54f0('0xbd7')]=_0x411a08['rows']?_0x411a08[_0x4b54f0('0x269a')]:[],_0x5c4405[_0x4b54f0('0x1ac6')]('admin')?_0x411a08:_0x1c01a4[_0x4b54f0('0xe60')]?_0x1c01a4[_0x4b54f0('0xe60')]['autoAssociation']?_0x411a08:_0x595394():null;})[_0x44c474('0x1166')](function(_0x10a2e3){const _0x440e45=_0x44c474,_0x6dff1e=_0x10a2e3&&_0x10a2e3['rows']?_0x10a2e3[_0x440e45('0x269a')]:[];return _0x1c01a4[_0x440e45('0x10ab')]=_0x2cfb05()['map'](_0x6dff1e,function(_0xdfe9ca){const _0x5c0189=_0x440e45;return _0x2cfb05()[_0x5c0189('0xc38')](_0x1c01a4[_0x5c0189('0xbd7')],{'id':_0x5c4405[_0x5c0189('0x1ac6')](_0x5c0189('0xa7c'))||_0x1c01a4['section']['autoAssociation']?_0xdfe9ca['id']:_0xdfe9ca['resourceId']});}),_0x1c01a4[_0x440e45('0xbd7')]['forEach'](function(_0x453f07){const _0x247591=_0x440e45,_0x5ca24b=_0x2cfb05()[_0x247591('0xc38')](_0x1c01a4[_0x247591('0x10ab')],{'id':_0x453f07['id']});_0x5c4405['hasRole']('admin')?_0x453f07['isValid']=!![]:_0x453f07['isValid']=typeof _0x5ca24b!==_0x247591('0x1048')?!![]:![];}),_0x5dd270();})[_0x44c474('0x1166')](function(_0x46f5f4){const _0x5914c8=_0x44c474,_0x30c70e=_0x46f5f4&&_0x46f5f4[_0x5914c8('0x269a')]?_0x46f5f4[_0x5914c8('0x269a')]:[];_0x1c01a4['selectedItems']=_0x2cfb05()['map'](_0x30c70e,function(_0x510274){const _0x3a6866=_0x5914c8;return _0x2cfb05()[_0x3a6866('0xc38')](_0x1c01a4[_0x3a6866('0xbd7')],{'id':_0x510274['id']});}),_0x1c01a4[_0x5914c8('0x2781')]=angular[_0x5914c8('0x225f')](_0x1c01a4['selectedItems']),_0x1c01a4[_0x5914c8('0xc68')][_0x5914c8('0x18e1')]=_0x1c01a4['selectedItems'],_0x1c01a4[_0x5914c8('0xc68')][_0x5914c8('0xbd7')]=_0x2cfb05()[_0x5914c8('0x24ac')](_0x1c01a4[_0x5914c8('0x10ab')],_0x1c01a4[_0x5914c8('0xc68')][_0x5914c8('0x18e1')],'id'),_0x2d4209();})[_0x44c474('0x1a80')](function(_0x2a9b6e){_0x238da4(_0x2a9b6e);});});}function _0x595394(){return _0x5716f3(function(_0x1a08d5,_0x3784b8){const _0x3b35c3=a0_0x3f2c;return _0xbfb1b5[_0x3b35c3('0x4b5')][_0x3b35c3('0xd83')]({'sectionId':_0x1c01a4[_0x3b35c3('0xe60')]['id'],'nolimit':!![]})[_0x3b35c3('0xa44')][_0x3b35c3('0x1166')](function(_0x3cf69d){_0x1a08d5(_0x3cf69d);})[_0x3b35c3('0x1a80')](function(_0x2fc1e2){_0x3784b8(_0x2fc1e2);});});}function _0x5dd270(){return _0x5716f3(function(_0x5b77d0,_0x145418){const _0x4c6815=a0_0x3f2c;return _0xbfb1b5[_0x4c6815('0x1a5b')][_0x4c6815('0x1448')]({'id':_0x1c01a4[_0x4c6815('0x1a5b')]['id'],'fields':_0x4c6815('0x1776'),'nolimit':!![]})[_0x4c6815('0xa44')]['then'](function(_0x1bf553){_0x5b77d0(_0x1bf553);})['catch'](function(_0x1d259a){_0x145418(_0x1d259a);});});}function _0x8cc397(){return _0x5716f3(function(_0x3115b5,_0x24f7d5){const _0x4ad64d=a0_0x3f2c;return _0xbfb1b5[_0x4ad64d('0x1e37')][_0x4ad64d('0xd83')]({'fields':_0x4ad64d('0x1776'),'nolimit':!![]})[_0x4ad64d('0xa44')][_0x4ad64d('0x1166')](function(_0x5b4f80){_0x3115b5(_0x5b4f80);})[_0x4ad64d('0x1a80')](function(_0x332e56){_0x24f7d5(_0x332e56);});});}function _0x29f97c(_0x4c4eef){return _0x5716f3(function(_0x479df4,_0x3e85f2){const _0x342928=a0_0x3f2c;_0x2cfb05()[_0x342928('0x1081')](_0x4c4eef)?_0x479df4():_0xbfb1b5['faxQueue'][_0x342928('0x16e0')]({'id':_0x1c01a4['faxQueue']['id'],'ids':_0x2cfb05()['map'](_0x4c4eef,'id')})[_0x342928('0xa44')][_0x342928('0x1166')](function(){_0x479df4();})[_0x342928('0x1a80')](function(_0x26c00a){_0x3e85f2(_0x26c00a);});});}function _0x1bd2d4(_0x5ca4fd){return _0x5716f3(function(_0x2e474d,_0x405aa1){const _0x79e837=a0_0x3f2c;_0x2cfb05()[_0x79e837('0x1081')](_0x5ca4fd)?_0x2e474d():_0xbfb1b5[_0x79e837('0x1a5b')]['removeTeams']({'id':_0x1c01a4[_0x79e837('0x1a5b')]['id'],'ids':_0x2cfb05()[_0x79e837('0x2563')](_0x5ca4fd,'id')})[_0x79e837('0xa44')]['then'](function(){_0x2e474d();})[_0x79e837('0x1a80')](function(_0x27060b){_0x405aa1(_0x27060b);});});}function _0x465497(){const _0x186dcb=_0x19da1f,_0x4e9eab=_0x2cfb05()[_0x186dcb('0x24ac')](_0x1c01a4[_0x186dcb('0x2781')],_0x1c01a4['selectedItems'],'id'),_0x1e4bcb=_0x2cfb05()[_0x186dcb('0x24ac')](_0x1c01a4[_0x186dcb('0x18e1')],_0x1c01a4['startingSelectedItems'],'id');return _0x1bd2d4(_0x4e9eab)[_0x186dcb('0x1166')](function(){return _0x29f97c(_0x1e4bcb);})[_0x186dcb('0x1166')](function(){const _0x462f80=_0x186dcb;_0x1c01a4[_0x462f80('0x14d7')]=![],_0x1c01a4[_0x462f80('0x2111')]=angular[_0x462f80('0x225f')](_0x1c01a4[_0x462f80('0x10ab')]),_0x1c01a4[_0x462f80('0x2781')]=angular[_0x462f80('0x225f')](_0x1c01a4['selectedItems']),_0x266ad8[_0x462f80('0x103b')]({'title':_0x462f80('0x983'),'msg':_0x462f80('0x1f6b')});})['catch'](function(_0x553d77){const _0x521260=_0x186dcb;_0x266ad8[_0x521260('0xfc9')]({'title':_0x553d77[_0x521260('0x52d')]?_0x521260('0x1e21')+_0x553d77[_0x521260('0x52d')]+_0x521260('0x11e1')+_0x553d77['statusText']:_0x521260('0x1b29'),'msg':_0x553d77[_0x521260('0x52d')]?JSON['stringify'](_0x553d77[_0x521260('0x25f4')]):_0x553d77['toString']()});});}function _0x207b7b(){const _0x9ecb9b=_0x19da1f;_0x59da32[_0x9ecb9b('0x1197')]();}}const _0x4cbbce=_0x2efa29,_0x1c1907=_0x2734b2['p']+_0x36e6f4('0x41e');_0x77d13c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'faxQueue',_0x36e6f4('0x17aa')];function _0x77d13c(_0x393a53,_0x3d73a7,_0x8853da,_0xf6034d,_0x565b43,_0x35ecbe,_0x1847d6,_0x2ed70f,_0x497f4b,_0x753c4,_0x466969,_0x5473c4){const _0x2f5e8a=_0x36e6f4,_0x5fca5d=this;_0x5fca5d[_0x2f5e8a('0x98')]=_0x753c4[_0x2f5e8a('0x26cd')](),_0x5fca5d[_0x2f5e8a('0x5c9')]=_0x35ecbe,_0x5fca5d[_0x2f5e8a('0xf8a')]=_0x1847d6,_0x5fca5d[_0x2f5e8a('0x2900')]=_0x5fca5d[_0x2f5e8a('0xf8a')][_0x2f5e8a('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5fca5d[_0x2f5e8a('0x246b')]=_0x3d73a7[_0x2f5e8a('0x6f1')]()+'://'+_0x3d73a7[_0x2f5e8a('0x1690')](),_0x5fca5d[_0x2f5e8a('0x1a5b')]=_0x466969||_0x393a53[_0x2f5e8a('0x23f')]['faxQueue']||{},_0x5fca5d[_0x2f5e8a('0x17aa')]=_0x5473c4&&_0x5473c4['count']==0x1?_0x5473c4['rows'][0x0]:null,_0x5fca5d[_0x2f5e8a('0x243c')]=_0x753c4[_0x2f5e8a('0xd87')](_0x5fca5d[_0x2f5e8a('0x17aa')]?_0x5fca5d[_0x2f5e8a('0x17aa')][_0x2f5e8a('0x243c')]:null),_0x5fca5d[_0x2f5e8a('0x128b')]={},_0x5fca5d[_0x2f5e8a('0x2669')]=_0x393a53['params']['tab']||0x0,_0x5fca5d[_0x2f5e8a('0x292')]=_0x1dbcbd,_0x5fca5d[_0x2f5e8a('0x1728')]=_0x25d366,_0x5fca5d[_0x2f5e8a('0x31d')]=_0x497f4b['info'],_0x5fca5d[_0x2f5e8a('0x2123')]=_0x526819,_0x5fca5d[_0x2f5e8a('0x2341')]=_0x2903e2;function _0x1dbcbd(_0x326725,_0x36b2e3){const _0x505fd7=_0x2f5e8a;_0x8853da[_0x505fd7('0x1f80')]({'controller':_0x505fd7('0x12d5'),'controllerAs':'vm','templateUrl':_0x1c1907,'parent':angular[_0x505fd7('0x1194')](_0xf6034d['body']),'targetEvent':_0x36b2e3,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x326725,'faxQueues':_0x5fca5d[_0x505fd7('0x2382')]?_0x5fca5d['faxQueues'][_0x505fd7('0x269a')]:[],'crudPermissions':_0x5fca5d['crudPermissions']}});}function _0x25d366(_0x3757ff,_0x45e71f){const _0x89215e=_0x2f5e8a;_0x8853da[_0x89215e('0x1f80')]({'controller':'FaxQueueagentaddController','controllerAs':'vm','templateUrl':_0x50858c,'parent':angular['element'](_0xf6034d[_0x89215e('0x8d2')]),'targetEvent':_0x45e71f,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x3757ff,'faxQueues':_0x5fca5d[_0x89215e('0x2382')]?_0x5fca5d[_0x89215e('0x2382')]['rows']:[],'crudPermissions':_0x5fca5d[_0x89215e('0x243c')],'realtime':![]}});}function _0x526819(){_0x393a53['go']('app.fax.faxQueues',{},{'reload':'app.fax.faxQueues'});}function _0x2903e2(){const _0x334317=_0x2f5e8a;_0x2ed70f[_0x334317('0x1a5b')][_0x334317('0x1449')]({'id':_0x5fca5d['faxQueue']['id']},_0x5fca5d[_0x334317('0x1a5b')])[_0x334317('0xa44')][_0x334317('0x1166')](function(){const _0x3d0e06=_0x334317;_0x497f4b[_0x3d0e06('0x103b')]({'title':'FaxQueue\x20updated!','msg':_0x5fca5d[_0x3d0e06('0x1a5b')][_0x3d0e06('0x4f0')]?_0x5fca5d['faxQueue']['name']+_0x3d0e06('0xa17'):''});})[_0x334317('0x1a80')](function(_0x3ecab6){const _0x1b6760=_0x334317;_0x497f4b['error']({'title':_0x3ecab6[_0x1b6760('0x52d')]?_0x1b6760('0x1e21')+_0x3ecab6[_0x1b6760('0x52d')]+_0x1b6760('0x11e1')+_0x3ecab6[_0x1b6760('0xe1b')]:'SYSTEM:GETfaxQueue','msg':_0x3ecab6['data']?JSON['stringify'](_0x3ecab6[_0x1b6760('0x25f4')]):_0x3ecab6[_0x1b6760('0x1586')]()});});}}const _0x1c3eb9=_0x77d13c;_0x5172ee[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x2382'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x5172ee(_0x329633,_0x12903b,_0x201cfc,_0x3498d3,_0x5d354b,_0x309834,_0x4fdb6a,_0x25fd61,_0x162703,_0x30817a,_0x5849af,_0x54dcbb,_0x49ccbf,_0x2d917b,_0x5d8c1e,_0x20864f,_0x1261fa){const _0x2aacec=_0x36e6f4,_0x5c21fb=this;_0x5c21fb['license']=_0x20864f,_0x5c21fb[_0x2aacec('0xf8a')]=_0x1261fa,_0x5c21fb[_0x2aacec('0x98')]=_0x5d8c1e['getCurrentUser'](),_0x5c21fb['faxQueues']=_0x162703||{'count':0x0,'rows':[]},_0x5c21fb[_0x2aacec('0x7f')]=_0x30817a,_0x5c21fb[_0x2aacec('0x17aa')]=_0x5849af&&_0x5849af[_0x2aacec('0x240f')]==0x1?_0x5849af[_0x2aacec('0x269a')][0x0]:null,_0x5c21fb[_0x2aacec('0x243c')]=_0x5d8c1e[_0x2aacec('0xd87')](_0x5c21fb[_0x2aacec('0x17aa')]?_0x5c21fb[_0x2aacec('0x17aa')][_0x2aacec('0x243c')]:null),_0x5c21fb['table']=_0x2aacec('0x2382'),_0x5c21fb[_0x2aacec('0xef5')]='',_0x5c21fb[_0x2aacec('0x104c')]=null,_0x5c21fb['selectedFaxQueues']=[],_0x5c21fb[_0x2aacec('0x2218')]={'fields':_0x2aacec('0xf26'),'sort':_0x2aacec('0x14dc'),'channel':'fax','limit':0xa,'page':0x1},_0x5c21fb['arraystrategy']=_0x2cfb05()[_0x2aacec('0x155c')]([{'option':'Beepall','value':_0x2aacec('0x1792')},{'option':_0x2aacec('0x75'),'value':_0x2aacec('0x11ad')}],function(_0x154462){const _0x4e893e=_0x2aacec;return _0x2cfb05()[_0x4e893e('0xf3')](_0x154462[_0x4e893e('0x18e0')],new RegExp('\x27','g'),'');}),_0x5c21fb[_0x2aacec('0x1ff6')]=_0xaef003,_0x5c21fb[_0x2aacec('0x292')]=_0x1d5ea9,_0x5c21fb['agentadddialog']=_0xcc6e02,_0x5c21fb['deleteconfirm']=_0x3b689c,_0x5c21fb['gotorealtimegoto']=_0xcc87cf,_0x5c21fb[_0x2aacec('0x103b')]=_0x10876d,_0x5c21fb['getFaxQueues']=_0x548489,_0x5c21fb[_0x2aacec('0xbb')]=_0x54c794,_0x5c21fb[_0x2aacec('0x274')]=_0x2f54d9,_0x5c21fb[_0x2aacec('0x2855')]=_0x10b5ff,_0x5c21fb[_0x2aacec('0x3a7')]=_0xc921d2,_0x5c21fb[_0x2aacec('0x250')]=_0xde3022,_0x5c21fb['selectAllFaxQueues']=_0xe7ea31;function _0xaef003(_0x6cd050){const _0x29cc0b=_0x2aacec;_0x201cfc['go'](_0x29cc0b('0xe9f'),{'id':_0x6cd050['id'],'faxQueue':_0x6cd050,'crudPermissions':_0x5c21fb[_0x29cc0b('0x243c')]});}function _0x1d5ea9(_0x413cf4,_0x333187){const _0x7062ab=_0x2aacec;_0x5d354b['show']({'controller':_0x7062ab('0x12d5'),'controllerAs':'vm','templateUrl':_0x1c1907,'parent':angular[_0x7062ab('0x1194')](_0x309834[_0x7062ab('0x8d2')]),'targetEvent':_0x333187,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x413cf4,'faxQueues':_0x5c21fb[_0x7062ab('0x2382')]?_0x5c21fb[_0x7062ab('0x2382')][_0x7062ab('0x269a')]:[],'crudPermissions':_0x5c21fb[_0x7062ab('0x243c')]}});}function _0xcc6e02(_0x1ada77,_0x2223aa){const _0x3615bd=_0x2aacec;_0x5d354b[_0x3615bd('0x1f80')]({'controller':_0x3615bd('0x1c88'),'controllerAs':'vm','templateUrl':_0x50858c,'parent':angular[_0x3615bd('0x1194')](_0x309834[_0x3615bd('0x8d2')]),'targetEvent':_0x2223aa,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x1ada77,'faxQueues':_0x5c21fb[_0x3615bd('0x2382')]?_0x5c21fb[_0x3615bd('0x2382')]['rows']:[],'crudPermissions':_0x5c21fb['crudPermissions'],'realtime':![]}});}function _0x3b689c(_0x77a36f,_0x34d76e){const _0x4f5742=_0x2aacec,_0x442bf7=_0x5d354b[_0x4f5742('0x1d26')]()[_0x4f5742('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x4f5742('0xb35')](_0x4f5742('0x1a5b'))+'?')[_0x4f5742('0xf3c')](''+(_0x77a36f[_0x4f5742('0x4f0')]||_0x4f5742('0x1a5b'))+_0x4f5742('0xace')+_0x4f5742('0x3f3'))[_0x4f5742('0x8e8')](_0x4f5742('0xec3'))['targetEvent'](_0x34d76e)['ok']('OK')[_0x4f5742('0x3f')](_0x4f5742('0x2d3'));_0x5d354b[_0x4f5742('0x1f80')](_0x442bf7)[_0x4f5742('0x1166')](function(){_0x2f54d9(_0x77a36f);},function(){const _0x5559fa=_0x4f5742;console[_0x5559fa('0x455')](_0x5559fa('0x2d3'));});}function _0xcc87cf(){const _0x3e2152=_0x2aacec;if(_0x5d8c1e[_0x3e2152('0x1ac6')]('admin'))_0x201cfc['go'](_0x3e2152('0x9e9'),{});else return _0x54dcbb[_0x3e2152('0x17aa')][_0x3e2152('0xd83')]({'userProfileId':_0x5d8c1e['getCurrentUser']()['userProfileId'],'sectionId':0x38e})[_0x3e2152('0xa44')]['then'](function(_0x435610){const _0x1ce23d=_0x3e2152,_0x881b9c=_0x435610&&_0x435610[_0x1ce23d('0x269a')]?_0x435610[_0x1ce23d('0x269a')][0x0]:null;_0x881b9c&&_0x881b9c['enabled']?_0x201cfc['go']('app.fax.realtime.queues',{}):_0x2d917b[_0x1ce23d('0x1fa1')]({'title':_0x25fd61[_0x1ce23d('0x25cc')](_0x1ce23d('0x627')),'msg':_0x25fd61[_0x1ce23d('0x25cc')](_0x1ce23d('0x2642'))});})['catch'](function(_0x5b0e36){const _0x2913e2=_0x3e2152;_0x2d917b[_0x2913e2('0xfc9')]({'title':_0x5b0e36[_0x2913e2('0x52d')]?_0x2913e2('0x1e21')+_0x5b0e36[_0x2913e2('0x52d')]+'\x20-\x20'+_0x5b0e36[_0x2913e2('0xe1b')]:_0x2913e2('0x153e'),'msg':_0x5b0e36[_0x2913e2('0x52d')]?JSON[_0x2913e2('0xbac')](_0x5b0e36[_0x2913e2('0x25f4')]):_0x5b0e36['toString']()});});}let _0x4c6583=!![],_0x142cf7=0x1;_0x329633[_0x2aacec('0xe83')](_0x2aacec('0x12d8'),function(_0x41ea05,_0x39deae){const _0x162711=_0x2aacec;_0x4c6583?_0x4fdb6a(function(){_0x4c6583=![];}):(!_0x39deae&&(_0x142cf7=_0x5c21fb[_0x162711('0x2218')][_0x162711('0x1a43')]),_0x41ea05!==_0x39deae&&(_0x5c21fb[_0x162711('0x2218')]['page']=0x1),!_0x41ea05&&(_0x5c21fb[_0x162711('0x2218')][_0x162711('0x1a43')]=_0x142cf7),_0x5c21fb['getFaxQueues']());});function _0x10876d(_0x3237e2){const _0x630297=_0x2aacec;_0x5c21fb[_0x630297('0x2382')]=_0x3237e2||{'count':0x0,'rows':[]};}function _0x548489(){const _0x162572=_0x2aacec;_0x5c21fb[_0x162572('0x2218')]['offset']=(_0x5c21fb['query']['page']-0x1)*_0x5c21fb['query']['limit'],_0x5d8c1e[_0x162572('0x1ac6')](_0x162572('0xa7c'))?_0x5c21fb['promise']=_0x54dcbb[_0x162572('0x1a5b')][_0x162572('0xd83')](_0x5c21fb[_0x162572('0x2218')],_0x10876d)[_0x162572('0xa44')]:(_0x5c21fb['query']['id']=_0x5c21fb[_0x162572('0x7f')]['id'],_0x5c21fb[_0x162572('0x2218')][_0x162572('0xe60')]=_0x162572('0x1e54'),_0x5c21fb[_0x162572('0x1f48')]=_0x54dcbb['userProfile'][_0x162572('0x263a')](_0x5c21fb[_0x162572('0x2218')],_0x10876d)[_0x162572('0xa44')]);}function _0x54c794(_0x1da3e9,_0x5513b7){const _0x5c9e2c=_0x2aacec;_0x5d354b['show']({'controller':_0x5c9e2c('0xd95'),'controllerAs':'vm','templateUrl':_0x28b772,'parent':angular[_0x5c9e2c('0x1194')](_0x309834[_0x5c9e2c('0x8d2')]),'targetEvent':_0x1da3e9,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x5513b7,'faxQueues':_0x5c21fb[_0x5c9e2c('0x2382')]['rows'],'license':_0x5c21fb['license'],'setting':_0x5c21fb[_0x5c9e2c('0xf8a')],'crudPermissions':_0x5c21fb[_0x5c9e2c('0x243c')]}});}function _0x2f54d9(_0x1d0dda){const _0x15fb4e=_0x2aacec;_0x54dcbb[_0x15fb4e('0x1a5b')][_0x15fb4e('0x906')]({'id':_0x1d0dda['id']})[_0x15fb4e('0xa44')][_0x15fb4e('0x1166')](function(){const _0x55b57b=_0x15fb4e;_0x2cfb05()[_0x55b57b('0x127f')](_0x5c21fb[_0x55b57b('0x2382')][_0x55b57b('0x269a')],{'id':_0x1d0dda['id']}),_0x5c21fb[_0x55b57b('0x2382')]['count']-=0x1,!_0x5c21fb[_0x55b57b('0x2382')][_0x55b57b('0x269a')][_0x55b57b('0x264b')]&&_0x5c21fb[_0x55b57b('0x7a')](),_0x2d917b['success']({'title':_0x2cfb05()[_0x55b57b('0xb35')]('FaxQueue')+_0x55b57b('0x2b6'),'msg':_0x1d0dda[_0x55b57b('0x4f0')]?_0x1d0dda[_0x55b57b('0x4f0')]+_0x55b57b('0x7cd'):''});})['catch'](function(_0x27662c){const _0x44249c=_0x15fb4e;if(_0x27662c['data']&&_0x27662c[_0x44249c('0x25f4')][_0x44249c('0x61a')]&&_0x27662c[_0x44249c('0x25f4')][_0x44249c('0x61a')][_0x44249c('0x264b')]){_0x5c21fb['errors']=_0x27662c[_0x44249c('0x25f4')]['errors']||[{'message':_0x27662c[_0x44249c('0x1586')](),'type':_0x44249c('0xc80')}];for(let _0x35ee61=0x0;_0x35ee61<_0x27662c[_0x44249c('0x25f4')][_0x44249c('0x61a')][_0x44249c('0x264b')];_0x35ee61++){_0x2d917b[_0x44249c('0xfc9')]({'title':_0x27662c[_0x44249c('0x25f4')][_0x44249c('0x61a')][_0x35ee61][_0x44249c('0x1345')],'msg':_0x27662c[_0x44249c('0x25f4')][_0x44249c('0x61a')][_0x35ee61]['message']});}}else _0x2d917b[_0x44249c('0xfc9')]({'title':_0x27662c[_0x44249c('0x52d')]?'API:'+_0x27662c[_0x44249c('0x52d')]+_0x44249c('0x11e1')+_0x27662c['statusText']:_0x44249c('0xc80'),'msg':_0x27662c[_0x44249c('0x25f4')]?JSON[_0x44249c('0xbac')](_0x27662c['data'][_0x44249c('0x1e70')]):_0x27662c[_0x44249c('0x1e70')]||_0x27662c[_0x44249c('0x1586')]()});});}function _0x10b5ff(){const _0x13e48f=_0x2aacec,_0x259bdf=angular[_0x13e48f('0x225f')](_0x5c21fb['selectedFaxQueues']);return _0x5c21fb[_0x13e48f('0x491')]=[],_0x259bdf;}function _0xc921d2(_0x52c1ad){const _0x82c2aa=_0x2aacec,_0xfd6ac7=_0x5d354b[_0x82c2aa('0x1d26')]()['title'](_0x82c2aa('0x1c30'))[_0x82c2aa('0xf3c')](_0x82c2aa('0x12b5')+_0x5c21fb[_0x82c2aa('0x491')]['length']+_0x82c2aa('0x196d')+_0x82c2aa('0x3f3'))[_0x82c2aa('0x8e8')](_0x82c2aa('0x6b2'))[_0x82c2aa('0x203b')](_0x52c1ad)['ok']('OK')[_0x82c2aa('0x3f')](_0x82c2aa('0x2d3'));_0x5d354b[_0x82c2aa('0x1f80')](_0xfd6ac7)[_0x82c2aa('0x1166')](function(){const _0x997220=_0x82c2aa;_0x5c21fb[_0x997220('0x491')][_0x997220('0x2782')](function(_0x36095d){_0x2f54d9(_0x36095d);}),_0x5c21fb[_0x997220('0x491')]=[];});}function _0xde3022(){const _0x6af6ae=_0x2aacec;_0x5c21fb[_0x6af6ae('0x491')]=[];}function _0xe7ea31(){const _0x282223=_0x2aacec;_0x5c21fb[_0x282223('0x491')]=_0x5c21fb[_0x282223('0x2382')][_0x282223('0x269a')];}}const _0x241963=_0x5172ee;_0x28b4f3['$inject']=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x28b4f3(_0x5ccf20,_0x5b2c19){const _0x229d2e=_0x36e6f4;_0x5ccf20[_0x229d2e('0x63f')]('app.fax',{'abstract':!![],'url':_0x229d2e('0xfbe')})['state'](_0x229d2e('0x18e5'),{'url':_0x229d2e('0x1d4d'),'views':{'content@app':{'templateUrl':_0x51ea19,'controller':_0x229d2e('0x1a47')}},'resolve':{'faxQueues':[_0x229d2e('0x1fbc'),_0x229d2e('0x21ef'),function(_0x190c2b,_0x5a5ab4){const _0x354997=_0x229d2e;return _0x5a5ab4['hasRole'](_0x354997('0xa7c'))?_0x190c2b[_0x354997('0x18af')]('faxQueue@get',{'fields':_0x354997('0xf26'),'sort':'-updatedAt','channel':_0x354997('0x1fc7'),'limit':0xa,'offset':0x0}):_0x190c2b[_0x354997('0x18af')](_0x354997('0x17c4'),{'id':_0x5a5ab4[_0x354997('0x26cd')]()[_0x354997('0xb86')],'section':_0x354997('0x1e54'),'fields':_0x354997('0xf26'),'sort':'-updatedAt','channel':'fax','limit':0xa,'offset':0x0});}],'userProfile':[_0x229d2e('0x1fbc'),_0x229d2e('0x21ef'),function(_0x149594,_0x1d5551){const _0x2afd95=_0x229d2e;return _0x1d5551[_0x2afd95('0x1ac6')](_0x2afd95('0xa7c'))?null:_0x149594[_0x2afd95('0x18af')](_0x2afd95('0x697'),{'fields':_0x2afd95('0x686'),'id':_0x1d5551[_0x2afd95('0x26cd')]()[_0x2afd95('0xb86')]});}],'userProfileSection':['apiResolver','Auth',function(_0x11ef17,_0x2ce0c8){const _0x1398ab=_0x229d2e;return _0x2ce0c8[_0x1398ab('0x1ac6')](_0x1398ab('0xa7c'))?null:_0x11ef17[_0x1398ab('0x18af')](_0x1398ab('0xaf'),{'fields':_0x1398ab('0xe26'),'userProfileId':_0x2ce0c8[_0x1398ab('0x26cd')]()['userProfileId'],'sectionId':0x385});}]},'authenticate':!![],'permissionId':0x385,'bodyClass':_0x229d2e('0x1fc7')})[_0x229d2e('0x63f')](_0x229d2e('0xe9f'),{'url':_0x229d2e('0x2233'),'params':{'faxQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x42c061,'controller':_0x229d2e('0xf5b')}},'resolve':{'faxQueue':[_0x229d2e('0x1fbc'),_0x229d2e('0xf75'),function(_0x1af71d,_0xaf2c49){const _0x1c636e=_0x229d2e;return _0x1af71d[_0x1c636e('0x18af')](_0x1c636e('0x9ba'),{'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','id':_0xaf2c49['id']});}],'userProfileSection':[_0x229d2e('0x1fbc'),'Auth',function(_0x242b0a,_0x5cf07c){const _0x4877e3=_0x229d2e;return _0x242b0a['resolve'](_0x4877e3('0xaf'),{'fields':_0x4877e3('0xe26'),'userProfileId':_0x5cf07c['getCurrentUser']()[_0x4877e3('0xb86')],'sectionId':0x385});}]},'authenticate':!![],'permissionId':0x385,'bodyClass':'fax'})[_0x229d2e('0x63f')](_0x229d2e('0x1c56'),{'url':_0x229d2e('0x38d'),'views':{'content@app':{'templateUrl':_0x317850,'controller':'FaxAccountsController\x20as\x20vm'}},'resolve':{'faxAccounts':[_0x229d2e('0x1fbc'),_0x229d2e('0x21ef'),function(_0x403509,_0x50258d){const _0x10339b=_0x229d2e;return _0x50258d[_0x10339b('0x1ac6')](_0x10339b('0xa7c'))?_0x403509[_0x10339b('0x18af')](_0x10339b('0x217d'),{'fields':_0x10339b('0x241f'),'sort':_0x10339b('0x14dc'),'limit':0xa,'offset':0x0}):_0x403509[_0x10339b('0x18af')](_0x10339b('0x17c4'),{'id':_0x50258d[_0x10339b('0x26cd')]()['userProfileId'],'section':'FaxAccounts','fields':'createdAt,updatedAt,id,name,key,headerinfo,TrunkId,localstationid,ListId,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,ecm,minrate,maxrate,modem,gateway,faxdetect,t38timeout,tech,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','sort':_0x10339b('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x229d2e('0x1fbc'),_0x229d2e('0x21ef'),function(_0x4aa417,_0x541356){const _0x2ba739=_0x229d2e;return _0x541356[_0x2ba739('0x1ac6')](_0x2ba739('0xa7c'))?null:_0x4aa417[_0x2ba739('0x18af')](_0x2ba739('0x697'),{'fields':_0x2ba739('0x686'),'id':_0x541356[_0x2ba739('0x26cd')]()[_0x2ba739('0xb86')]});}],'userProfileSection':[_0x229d2e('0x1fbc'),_0x229d2e('0x21ef'),function(_0x81661d,_0x28bd83){const _0x3e7518=_0x229d2e;return _0x28bd83[_0x3e7518('0x1ac6')](_0x3e7518('0xa7c'))?null:_0x81661d['resolve'](_0x3e7518('0xaf'),{'fields':_0x3e7518('0xe26'),'userProfileId':_0x28bd83[_0x3e7518('0x26cd')]()['userProfileId'],'sectionId':0x386});}]},'authenticate':!![],'permissionId':0x386,'bodyClass':_0x229d2e('0x1fc7')})['state'](_0x229d2e('0x140b'),{'url':_0x229d2e('0x2233'),'params':{'faxAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x300918,'controller':_0x229d2e('0x1751')}},'resolve':{'faxAccount':[_0x229d2e('0x1fbc'),_0x229d2e('0xf75'),function(_0x2c73a9,_0x454a23){const _0x1d8a9a=_0x229d2e;return _0x2c73a9[_0x1d8a9a('0x18af')]('faxAccount@get',{'fields':_0x1d8a9a('0x241f'),'id':_0x454a23['id']});}],'userProfileSection':[_0x229d2e('0x1fbc'),_0x229d2e('0x21ef'),function(_0x276622,_0x1d2840){const _0x22d005=_0x229d2e;return _0x276622['resolve'](_0x22d005('0xaf'),{'fields':_0x22d005('0xe26'),'userProfileId':_0x1d2840[_0x22d005('0x26cd')]()[_0x22d005('0xb86')],'sectionId':0x386});}]},'authenticate':!![],'permissionId':0x386,'bodyClass':'fax'}),_0x5b2c19[_0x229d2e('0x95e')]('app/main/apps/fax');}angular[_0x36e6f4('0x896')](_0x36e6f4('0x1df6'),['ngCsv','ngPassword',_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),'ckeditor',_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),'mdPickers','mwFormBuilder',_0x36e6f4('0x8f3'),'mwFormUtils',_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),'angular.filter',_0x36e6f4('0x1051')])[_0x36e6f4('0xe11')](_0x28b4f3)[_0x36e6f4('0x75e')](_0x36e6f4('0x830'),_0x5d48dd)[_0x36e6f4('0x75e')](_0x36e6f4('0x2462'),_0x5c812e)['controller']('FaxAccountagentaddController',_0x54528b)['controller'](_0x36e6f4('0x1c79'),_0xe7fc68)['controller'](_0x36e6f4('0x1b12'),_0x5d4a8e)[_0x36e6f4('0x75e')](_0x36e6f4('0x1ec0'),_0x157564)[_0x36e6f4('0x75e')]('EditFaxAccountAppgotopDialogController',_0x334910)[_0x36e6f4('0x75e')](_0x36e6f4('0x8ad'),_0x2945dd)['controller']('EditFaxAccountAppnoopDialogController',_0x4860ee)['controller']('EditFaxAccountAppqueueDialogController',_0x32cdc9)[_0x36e6f4('0x75e')]('EditFaxAccountAppsystemDialogController',_0x369b1b)['controller'](_0x36e6f4('0xb19'),_0x3c9529)[_0x36e6f4('0x75e')]('FaxAccountDispositionsController',_0x291635)[_0x36e6f4('0x75e')](_0x36e6f4('0x2874'),_0xf3fbf9)['controller'](_0x36e6f4('0x240'),_0x89f817)[_0x36e6f4('0x75e')](_0x36e6f4('0x55a'),_0x121a06)[_0x36e6f4('0x75e')](_0x36e6f4('0xd95'),_0x441c6d)['controller']('FaxQueueagentaddController',_0x22fc07)[_0x36e6f4('0x75e')]('FaxQueueteamaddController',_0x4cbbce)[_0x36e6f4('0x75e')](_0x36e6f4('0x5d7'),_0x1c3eb9)[_0x36e6f4('0x75e')](_0x36e6f4('0xf25'),_0x241963);const _0x312c58=_0x2734b2['p']+'src/js/modules/main/apps/tools/views/dispositions/dispositions.html/dispositions.html';_0x20ac8d['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x586'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x4ea'),_0x36e6f4('0x12e8'),_0x36e6f4('0x1404'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c'),_0x36e6f4('0x5c9'),'setting'];function _0x20ac8d(_0x53cc57,_0xc14fc9,_0x329485,_0x171af2,_0x35a363,_0x11e7fe,_0x5793f1,_0x362397,_0x10f2dd,_0x59f648,_0x5baadb,_0x263673){const _0x5eedca=_0x36e6f4,_0x4be80e=this;_0x4be80e[_0x5eedca('0x98')]=_0x10f2dd[_0x5eedca('0x26cd')](),_0x4be80e[_0x5eedca('0x12e8')]=angular['copy'](_0x11e7fe),_0x4be80e[_0x5eedca('0x4ea')]=angular[_0x5eedca('0x225f')](_0x35a363),_0x4be80e[_0x5eedca('0xf8a')]=_0x263673,_0x4be80e[_0x5eedca('0x5c9')]=_0x5baadb,_0x4be80e[_0x5eedca('0x243c')]=_0x59f648,_0x4be80e[_0x5eedca('0x523')]=![],_0x4be80e[_0x5eedca('0x61a')]=[];!_0x4be80e['disposition']?(_0x4be80e[_0x5eedca('0x12e8')]={'level':'first'},_0x4be80e[_0x5eedca('0x523')]=!![]):_0x1f9887();if(_0x5793f1){const _0x12038f=_0x5793f1['field'];_0x4be80e[_0x5eedca('0x12e8')][_0x12038f]=_0x5793f1['id'];}_0x4be80e['onFirstLevelSelection']=_0x1be7d6,_0x4be80e[_0x5eedca('0x1c7f')]=_0x1603b4,_0x4be80e[_0x5eedca('0x9da')]=_0x2e501f,_0x4be80e[_0x5eedca('0x27c6')]=_0x3d22d0,_0x4be80e[_0x5eedca('0xe04')]=_0x21d641,_0x4be80e[_0x5eedca('0x24a0')]=_0x558ff5;function _0x1f9887(){const _0x100e35=_0x5eedca;if(_0x4be80e[_0x100e35('0x12e8')][_0x100e35('0x26d1')]===_0x100e35('0x215c'))return;_0x4be80e[_0x100e35('0x121e')]=_0x2cfb05()[_0x100e35('0xc38')](_0x4be80e[_0x100e35('0x4ea')],['id',_0x4be80e[_0x100e35('0x12e8')][_0x100e35('0x11fa')]]);if(!_0x4be80e['parentDisposition']){_0x560113()[_0x100e35('0x1166')](function(){const _0x138c10=_0x100e35;for(let _0x21f340=0x0;_0x21f340<_0x4be80e['allDispositions'][_0x138c10('0x264b')];_0x21f340++){const _0x132d06=_0x4be80e[_0x138c10('0x258f')][_0x21f340];if(_0x132d06['id']===_0x4be80e[_0x138c10('0x12e8')][_0x138c10('0x11fa')]){_0x5c3c25(_0x132d06),_0x132d06[_0x138c10('0x2378')]=![],_0x4be80e[_0x138c10('0x4ea')]['push'](_0x132d06);break;}}});return;}_0x5c3c25(_0x4be80e[_0x100e35('0x121e')]);}function _0x560113(){return _0x329485(function(_0x581fc5,_0x4cd52c){const _0x238768=a0_0x3f2c;_0x362397[_0x238768('0x12e8')]['get']({'fields':_0x238768('0x1061'),'sort':'id','nolimit':_0x238768('0xf3b')})[_0x238768('0xa44')]['then'](function(_0x111a66){const _0x2c4360=_0x238768;_0x4be80e[_0x2c4360('0x258f')]=_0x111a66[_0x2c4360('0x269a')]||[],_0x581fc5();})['catch'](function(_0x487ee3){_0x4cd52c(_0x487ee3);});});}function _0x5c3c25(_0x1d5bfa){const _0x6c3056=_0x5eedca;_0x1d5bfa[_0x6c3056('0x26d1')]==='first'?_0x4be80e[_0x6c3056('0x1a44')]=_0x1d5bfa:(_0x4be80e['anySecondLevelDisposition']=!![],_0x4be80e[_0x6c3056('0x2092')]=_0x1d5bfa,_0x4be80e[_0x6c3056('0x1a44')]=_0x2cfb05()[_0x6c3056('0xc38')](_0x4be80e[_0x6c3056('0x4ea')],['id',_0x4be80e[_0x6c3056('0x2092')][_0x6c3056('0x11fa')]]),!_0x4be80e['firstLevelDisposition']&&_0x560113()['then'](function(){const _0xb7e581=_0x6c3056;_0x4be80e[_0xb7e581('0x1a44')]=_0x2cfb05()[_0xb7e581('0xc38')](_0x4be80e[_0xb7e581('0x258f')],['id',_0x4be80e[_0xb7e581('0x2092')]['ParentId']]),_0x4be80e[_0xb7e581('0x1a44')]['canSelect']=![],_0x4be80e['dispositions'][_0xb7e581('0x1514')](_0x4be80e[_0xb7e581('0x1a44')]);}));}function _0x21d641(_0x11034f){const _0x41dbb9=_0x5eedca;_0x11034f===_0x41dbb9('0x215c')?(_0x4be80e[_0x41dbb9('0x1a44')]=undefined,_0x4be80e['secondLevelDisposition']=undefined,_0x4be80e[_0x41dbb9('0x2280')]=![]):_0x4be80e[_0x41dbb9('0x2092')]=undefined;}function _0x1be7d6(){const _0x9dd0fe=_0x5eedca;_0x4be80e[_0x9dd0fe('0x2092')]=undefined,_0x4be80e[_0x9dd0fe('0x2280')]=_0x2cfb05()[_0x9dd0fe('0x1798')](_0x4be80e[_0x9dd0fe('0x4ea')],function(_0x28ff65){const _0x342a72=_0x9dd0fe;return _0x28ff65[_0x342a72('0x11fa')]===_0x4be80e[_0x342a72('0x1a44')]['id']&&_0x28ff65['id']!=_0x4be80e['disposition']['id'];});}function _0x1603b4(){const _0x51582a=_0x5eedca;_0x4be80e[_0x51582a('0x61a')]=[];if(_0x4be80e[_0x51582a('0x2092')])_0x4be80e[_0x51582a('0x12e8')][_0x51582a('0x11fa')]=_0x4be80e[_0x51582a('0x2092')]['id'],_0x4be80e['disposition'][_0x51582a('0x26d1')]='third';else _0x4be80e['firstLevelDisposition']&&(_0x4be80e[_0x51582a('0x12e8')][_0x51582a('0x11fa')]=_0x4be80e['firstLevelDisposition']['id'],_0x4be80e[_0x51582a('0x12e8')][_0x51582a('0x26d1')]='second');_0x362397['disposition']['save'](_0x4be80e[_0x51582a('0x12e8')])['$promise'][_0x51582a('0x1166')](function(_0x424544){const _0x4f6df6=_0x51582a;_0x4be80e[_0x4f6df6('0x4ea')]['unshift'](_0x424544[_0x4f6df6('0x2876')]()),_0x171af2[_0x4f6df6('0x103b')]({'title':_0xc14fc9[_0x4f6df6('0x25cc')](_0x4f6df6('0xac2'))}),_0x558ff5(!![]);})[_0x51582a('0x1a80')](function(_0x80091d){const _0x373276=_0x51582a;if(_0x80091d['data']&&_0x80091d[_0x373276('0x25f4')][_0x373276('0x61a')]&&_0x80091d[_0x373276('0x25f4')][_0x373276('0x61a')]['length']){_0x4be80e[_0x373276('0x61a')]=_0x80091d[_0x373276('0x25f4')][_0x373276('0x61a')]||[{'message':_0x80091d[_0x373276('0x1586')](),'type':_0x373276('0x1118')}];for(let _0x1bc8ce=0x0;_0x1bc8ce<_0x80091d[_0x373276('0x25f4')][_0x373276('0x61a')][_0x373276('0x264b')];_0x1bc8ce+=0x1){_0x171af2[_0x373276('0xfc9')]({'title':_0x80091d[_0x373276('0x25f4')][_0x373276('0x61a')][_0x1bc8ce][_0x373276('0x1345')],'msg':_0x80091d['data'][_0x373276('0x61a')][_0x1bc8ce][_0x373276('0x1e70')]});}}else _0x171af2[_0x373276('0xfc9')]({'title':_0x80091d[_0x373276('0x52d')]?_0x373276('0x1e21')+_0x80091d[_0x373276('0x52d')]+_0x373276('0x11e1')+_0x80091d[_0x373276('0xe1b')]:'api.disposition.save','msg':_0x80091d[_0x373276('0x25f4')]?JSON['stringify'](_0x80091d['data'][_0x373276('0x1e70')]):_0x80091d[_0x373276('0x1586')]()});});}function _0x2e501f(){const _0x516113=_0x5eedca;_0x4be80e['errors']=[];if(_0x4be80e[_0x516113('0x2092')])_0x4be80e[_0x516113('0x12e8')][_0x516113('0x11fa')]=_0x4be80e[_0x516113('0x2092')]['id'],_0x4be80e[_0x516113('0x12e8')][_0x516113('0x26d1')]=_0x516113('0x15e9');else _0x4be80e[_0x516113('0x1a44')]&&(_0x4be80e['disposition'][_0x516113('0x11fa')]=_0x4be80e[_0x516113('0x1a44')]['id'],_0x4be80e[_0x516113('0x12e8')]['level']=_0x516113('0x161a'));_0x362397[_0x516113('0x12e8')][_0x516113('0x1449')]({'id':_0x4be80e[_0x516113('0x12e8')]['id']},_0x4be80e[_0x516113('0x12e8')])[_0x516113('0xa44')]['then'](function(_0x4a1dd1){const _0x5ec1b3=_0x516113,_0x817186=_0x2cfb05()['find'](_0x4be80e[_0x5ec1b3('0x4ea')],{'id':_0x4a1dd1['id']});_0x817186&&_0x2cfb05()[_0x5ec1b3('0xcc3')](_0x817186,_0x2cfb05()[_0x5ec1b3('0x1a08')](_0x4a1dd1[_0x5ec1b3('0x2876')](),_0x2cfb05()[_0x5ec1b3('0x14a4')](_0x817186))),_0x171af2[_0x5ec1b3('0x103b')]({'title':_0xc14fc9['instant']('TOOLS.NOTIFICATIONS.DISPOSITION_SAVED_SUCCESS_TITLE')}),_0x558ff5(!![]);})[_0x516113('0x1a80')](function(_0x28074c){const _0x4332ce=_0x516113;if(_0x28074c[_0x4332ce('0x25f4')]&&_0x28074c[_0x4332ce('0x25f4')][_0x4332ce('0x61a')]&&_0x28074c[_0x4332ce('0x25f4')][_0x4332ce('0x61a')][_0x4332ce('0x264b')]){_0x4be80e[_0x4332ce('0x61a')]=_0x28074c['data'][_0x4332ce('0x61a')]||[{'message':_0x28074c['toString'](),'type':_0x4332ce('0x115d')}];for(let _0x28b42c=0x0;_0x28b42c<_0x28074c[_0x4332ce('0x25f4')][_0x4332ce('0x61a')]['length'];_0x28b42c++){_0x171af2[_0x4332ce('0xfc9')]({'title':_0x28074c[_0x4332ce('0x25f4')]['errors'][_0x28b42c][_0x4332ce('0x1345')],'msg':_0x28074c[_0x4332ce('0x25f4')][_0x4332ce('0x61a')][_0x28b42c][_0x4332ce('0x1e70')]});}}else _0x171af2[_0x4332ce('0xfc9')]({'title':_0x28074c[_0x4332ce('0x52d')]?_0x4332ce('0x1e21')+_0x28074c[_0x4332ce('0x52d')]+'\x20-\x20'+_0x28074c[_0x4332ce('0xe1b')]:_0x4332ce('0x115d'),'msg':_0x28074c['data']?JSON[_0x4332ce('0xbac')](_0x28074c['data'][_0x4332ce('0x1e70')]):_0x28074c['toString']()});});}function _0x3d22d0(_0x3500c7){const _0x18ef69=_0x5eedca;_0x4be80e['errors']=[];const _0xb4235=_0x2cfb05()['some'](_0x4be80e[_0x18ef69('0x4ea')],['ParentId',_0x4be80e[_0x18ef69('0x12e8')]['id']]),_0x4121d0=_0x53cc57[_0x18ef69('0x1d26')]({'skipHide':!![]})[_0x18ef69('0xcdc')](_0xc14fc9[_0x18ef69('0x25cc')](_0x18ef69('0x1ac5')))[_0x18ef69('0xacc')](_0xc14fc9['instant'](_0x18ef69('0x92f')+(_0xb4235?_0x18ef69('0xc7a'):_0x18ef69('0x251e')),{'name':_0x4be80e[_0x18ef69('0x12e8')][_0x18ef69('0x4f0')]}))['ariaLabel'](_0x18ef69('0x1af2'))['ok'](_0xc14fc9['instant'](_0x18ef69('0xa68')))[_0x18ef69('0x3f')](_0xc14fc9[_0x18ef69('0x25cc')](_0x18ef69('0x12a3')))[_0x18ef69('0x203b')](_0x3500c7);_0x53cc57[_0x18ef69('0x1f80')](_0x4121d0)[_0x18ef69('0x1166')](function(){const _0x3a5c39=_0x18ef69;_0x362397[_0x3a5c39('0x12e8')][_0x3a5c39('0x906')]({'id':_0x4be80e['disposition']['id']})['$promise'][_0x3a5c39('0x1166')](function(){const _0x54a25f=_0x3a5c39;_0x171af2[_0x54a25f('0x103b')]({'title':_0xc14fc9['instant'](_0x54a25f('0x1ca6'))}),_0x558ff5(!![]);})[_0x3a5c39('0x1a80')](function(_0x5acf34){const _0x6c7389=_0x3a5c39;if(_0x5acf34[_0x6c7389('0x25f4')]&&_0x5acf34[_0x6c7389('0x25f4')][_0x6c7389('0x61a')]&&_0x5acf34[_0x6c7389('0x25f4')][_0x6c7389('0x61a')][_0x6c7389('0x264b')]){_0x4be80e[_0x6c7389('0x61a')]=_0x5acf34[_0x6c7389('0x25f4')]['errors']||[{'message':_0x5acf34[_0x6c7389('0x1586')](),'type':'api.disposition.delete'}];for(let _0x13940d=0x0;_0x13940d<_0x5acf34[_0x6c7389('0x25f4')]['errors'][_0x6c7389('0x264b')];_0x13940d++){_0x171af2['error']({'title':_0x5acf34['data'][_0x6c7389('0x61a')][_0x13940d][_0x6c7389('0x1345')],'msg':_0x5acf34[_0x6c7389('0x25f4')][_0x6c7389('0x61a')][_0x13940d][_0x6c7389('0x1e70')]});}}else _0x171af2[_0x6c7389('0xfc9')]({'title':_0x5acf34['status']?_0x6c7389('0x1e21')+_0x5acf34[_0x6c7389('0x52d')]+'\x20-\x20'+_0x5acf34['statusText']:_0x6c7389('0x1c11'),'msg':_0x5acf34[_0x6c7389('0x25f4')]?JSON['stringify'](_0x5acf34['data'][_0x6c7389('0x1e70')]):_0x5acf34['message']||_0x5acf34[_0x6c7389('0x1586')]()});});});}function _0x558ff5(_0x1fb5a0){const _0x256c49=_0x5eedca;_0x53cc57[_0x256c49('0x1197')](_0x1fb5a0);}}const _0x1eb4c4=_0x20ac8d;_0x417251['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$mdSidenav',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x4ea'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x417251(_0x48629f,_0x2f37a3,_0x599904,_0x14db67,_0x5c596e,_0x4cf163,_0x41300f,_0xa4f8f2,_0x2342ea,_0x564261,_0x4bd379,_0xe40283,_0x545093,_0x5dd48e,_0x111b4d,_0x31732e){const _0x2fbfc0=_0x36e6f4,_0x49083a=this;_0x49083a[_0x2fbfc0('0x5c9')]=_0x111b4d,_0x49083a[_0x2fbfc0('0xf8a')]=_0x31732e,_0x49083a['currentUser']=_0x5dd48e[_0x2fbfc0('0x26cd')](),_0x49083a[_0x2fbfc0('0x4ea')]=_0x2342ea||{'count':0x0,'rows':[]},_0x49083a['userProfile']=_0x564261,_0x49083a[_0x2fbfc0('0x17aa')]=_0x4bd379&&_0x4bd379[_0x2fbfc0('0x240f')]==0x1?_0x4bd379[_0x2fbfc0('0x269a')][0x0]:null,_0x49083a['crudPermissions']=_0x5dd48e[_0x2fbfc0('0xd87')](_0x49083a['userProfileSection']?_0x49083a['userProfileSection']['crudPermissions']:null),_0x49083a[_0x2fbfc0('0x1082')]=[],_0x49083a[_0x2fbfc0('0x178f')]={'first':_0x2fbfc0('0xc31'),'second':_0x2fbfc0('0x580'),'third':_0x2fbfc0('0x1144')},_0x49083a[_0x2fbfc0('0x2218')]={'fields':_0x2fbfc0('0xf1a'),'sort':'-updatedAt','MailAccountId':_0x2fbfc0('0x15d7'),'FaxAccountId':'null','SmsAccountId':_0x2fbfc0('0x15d7'),'OpenchannelAccountId':_0x2fbfc0('0x15d7'),'ChatWebsiteId':_0x2fbfc0('0x15d7'),'WhatsappAccountId':_0x2fbfc0('0x15d7'),'ListId':'null','limit':0xa,'page':0x1},_0x49083a[_0x2fbfc0('0x8d8')]=_0x458cbb,_0x49083a[_0x2fbfc0('0x103b')]=_0x5964ea,_0x49083a[_0x2fbfc0('0x3e')]=_0x5b8d23,_0x49083a[_0x2fbfc0('0x782')]=_0x4dd782,_0x49083a[_0x2fbfc0('0x27c6')]=_0x457fd3,_0x49083a['exportSelectedDispositions']=_0x3349ce,_0x49083a[_0x2fbfc0('0x14b5')]=_0x475957,_0x49083a['deselectDispositions']=_0x1a02b8,_0x49083a['selectAllDispositions']=_0x2c2f9e;function _0x4dd782(_0x4c09b6,_0x2ba9ad){const _0x12451a=_0x2fbfc0;_0x5c596e[_0x12451a('0x1f80')]({'controller':_0x12451a('0x17a3'),'controllerAs':'vm','templateUrl':_0x14e8d3,'parent':angular[_0x12451a('0x1194')](_0x4cf163['body']),'targetEvent':_0x4c09b6,'clickOutsideToClose':!![],'locals':{'disposition':_0x2ba9ad,'dispositions':_0x49083a['dispositions'][_0x12451a('0x269a')],'model':null,'license':_0x49083a[_0x12451a('0x5c9')],'setting':_0x49083a['setting'],'crudPermissions':_0x49083a[_0x12451a('0x243c')]}})['then'](function(_0x27b772){if(_0x27b772===!![])_0x5b8d23();});}function _0x458cbb(_0x28a81e,_0x597b29){const _0x3300fb=_0x2fbfc0,_0x1bf1a8=_0x2cfb05()[_0x3300fb('0x1798')](_0x49083a[_0x3300fb('0x4ea')][_0x3300fb('0x269a')],[_0x3300fb('0x11fa'),_0x28a81e['id']]),_0x56cc5c=_0x5c596e[_0x3300fb('0x1d26')]()[_0x3300fb('0xcdc')](_0xa4f8f2[_0x3300fb('0x25cc')](_0x3300fb('0x1ac5')))[_0x3300fb('0xacc')](_0xa4f8f2[_0x3300fb('0x25cc')](_0x3300fb('0x92f')+(_0x1bf1a8?_0x3300fb('0xc7a'):'DISPOSITION_DELETE_MESSAGE'),{'name':_0x28a81e['name']}))['ariaLabel'](_0x3300fb('0x1af2'))['targetEvent'](_0x597b29)['ok']('OK')[_0x3300fb('0x3f')](_0xa4f8f2[_0x3300fb('0x25cc')](_0x3300fb('0x12a3')));_0x5c596e[_0x3300fb('0x1f80')](_0x56cc5c)[_0x3300fb('0x1166')](function(){_0x457fd3(_0x28a81e);});}function _0x5964ea(_0x43170f){_0x49083a['dispositions']=_0x43170f||{'count':0x0,'rows':[]};}function _0x5b8d23(){const _0x5ba35b=_0x2fbfc0;_0x49083a['query'][_0x5ba35b('0x1098')]=(_0x49083a[_0x5ba35b('0x2218')]['page']-0x1)*_0x49083a['query'][_0x5ba35b('0x163f')],_0x5dd48e[_0x5ba35b('0xe0f')]()?_0x49083a[_0x5ba35b('0x1f48')]=_0xe40283[_0x5ba35b('0x12e8')][_0x5ba35b('0xd83')](_0x49083a[_0x5ba35b('0x2218')],_0x5964ea)[_0x5ba35b('0xa44')]:(_0x49083a[_0x5ba35b('0x2218')]['id']=_0x49083a[_0x5ba35b('0x7f')]['id'],_0x49083a[_0x5ba35b('0x2218')][_0x5ba35b('0xe60')]=_0x5ba35b('0x10fb'),_0x49083a[_0x5ba35b('0x1f48')]=_0xe40283[_0x5ba35b('0x7f')][_0x5ba35b('0x263a')](_0x49083a[_0x5ba35b('0x2218')],_0x5964ea)[_0x5ba35b('0xa44')]);}function _0x457fd3(_0x339ab8){const _0x1d215d=_0x2fbfc0;_0xe40283[_0x1d215d('0x12e8')]['delete']({'id':_0x339ab8['id']})[_0x1d215d('0xa44')][_0x1d215d('0x1166')](function(){const _0x4acf6e=_0x1d215d;_0x5b8d23(),_0x545093[_0x4acf6e('0x103b')]({'title':_0xa4f8f2['instant'](_0x4acf6e('0x1ca6'))});})[_0x1d215d('0x1a80')](function(_0x6419ab){const _0x53f076=_0x1d215d;if(_0x6419ab[_0x53f076('0x25f4')]&&_0x6419ab[_0x53f076('0x25f4')][_0x53f076('0x61a')]&&_0x6419ab['data'][_0x53f076('0x61a')][_0x53f076('0x264b')]){_0x49083a[_0x53f076('0x61a')]=_0x6419ab[_0x53f076('0x25f4')]['errors']||[{'message':_0x6419ab['toString'](),'type':_0x53f076('0x1b2c')}];for(let _0x2d9aa2=0x0;_0x2d9aa2<_0x6419ab['data'][_0x53f076('0x61a')]['length'];_0x2d9aa2++){_0x545093['error']({'title':_0x6419ab[_0x53f076('0x25f4')]['errors'][_0x2d9aa2][_0x53f076('0x1345')],'msg':_0x6419ab[_0x53f076('0x25f4')][_0x53f076('0x61a')][_0x2d9aa2]['message']});}}else _0x545093[_0x53f076('0xfc9')]({'title':_0x6419ab['status']?'API:'+_0x6419ab['status']+_0x53f076('0x11e1')+_0x6419ab['statusText']:'SYSTEM:DELETEdisposition','msg':_0x6419ab['data']?JSON[_0x53f076('0xbac')](_0x6419ab['data'][_0x53f076('0x1e70')]):_0x6419ab[_0x53f076('0x1e70')]||_0x6419ab[_0x53f076('0x1586')]()});});}function _0x3349ce(){const _0x5d7ca5=_0x2fbfc0,_0x2c93a1=angular[_0x5d7ca5('0x225f')](_0x49083a[_0x5d7ca5('0x1082')]);return _0x49083a[_0x5d7ca5('0x1082')]=[],_0x2c93a1;}function _0x475957(_0x37a4aa){const _0x478ef0=_0x2fbfc0,_0x290c55=_0x5c596e[_0x478ef0('0x1d26')]()[_0x478ef0('0xcdc')](_0xa4f8f2[_0x478ef0('0x25cc')](_0x478ef0('0x24fd')))[_0x478ef0('0xacc')](_0xa4f8f2[_0x478ef0('0x25cc')](_0x478ef0('0x223e'),{'total':_0x49083a[_0x478ef0('0x1082')][_0x478ef0('0x264b')]}))['ariaLabel']('Delete\x20dispositions')[_0x478ef0('0x203b')](_0x37a4aa)['ok']('OK')[_0x478ef0('0x3f')](_0xa4f8f2['instant']('TOOLS.CANCEL'));_0x5c596e[_0x478ef0('0x1f80')](_0x290c55)[_0x478ef0('0x1166')](function(){const _0x270b35=_0x478ef0;_0x49083a[_0x270b35('0x1082')][_0x270b35('0x2782')](function(_0x482e24){_0x457fd3(_0x482e24);}),_0x49083a[_0x270b35('0x1082')]=[];});}function _0x1a02b8(){_0x49083a['selectedDispositions']=[];}function _0x2c2f9e(){const _0x446176=_0x2fbfc0;_0x49083a[_0x446176('0x1082')]=_0x49083a[_0x446176('0x4ea')][_0x446176('0x269a')];}let _0x22566e=!![],_0x434b88=0x1;_0x48629f[_0x2fbfc0('0xe83')]('vm.query.filter',function(_0x186689,_0x1890f0){const _0x2ae25b=_0x2fbfc0;_0x22566e?_0x41300f(function(){_0x22566e=![];}):(!_0x1890f0&&(_0x434b88=_0x49083a[_0x2ae25b('0x2218')][_0x2ae25b('0x1a43')]),_0x186689!==_0x1890f0&&(_0x49083a[_0x2ae25b('0x2218')][_0x2ae25b('0x1a43')]=0x1),!_0x186689&&(_0x49083a[_0x2ae25b('0x2218')][_0x2ae25b('0x1a43')]=_0x434b88),_0x5b8d23());});}const _0x40f9d7=_0x417251;_0x43dda9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x43dda9(_0x5b54d1){const _0xb1b4dd=_0x36e6f4;_0x5b54d1['state']('app.tools.dispositions',{'url':'/dispositions','views':{'content@app':{'templateUrl':_0x312c58,'controller':_0xb1b4dd('0x5fc')}},'resolve':{'dispositions':[_0xb1b4dd('0x1fbc'),_0xb1b4dd('0x21ef'),function(_0xcdc37,_0x10f177){const _0x4bacdb=_0xb1b4dd;return _0x10f177[_0x4bacdb('0x1ac6')](_0x4bacdb('0xa7c'))?_0xcdc37[_0x4bacdb('0x18af')](_0x4bacdb('0x1e98'),{'fields':_0x4bacdb('0xf1a'),'sort':'-updatedAt','MailAccountId':'null','FaxAccountId':_0x4bacdb('0x15d7'),'SmsAccountId':'null','OpenchannelAccountId':_0x4bacdb('0x15d7'),'ChatWebsiteId':_0x4bacdb('0x15d7'),'WhatsappAccountId':_0x4bacdb('0x15d7'),'ListId':_0x4bacdb('0x15d7'),'limit':0xa,'offset':0x0}):_0xcdc37['resolve']('userProfile@getResources',{'id':_0x10f177['getCurrentUser']()[_0x4bacdb('0xb86')],'section':_0x4bacdb('0x10fb'),'fields':_0x4bacdb('0xf1a'),'sort':_0x4bacdb('0x14dc'),'MailAccountId':_0x4bacdb('0x15d7'),'FaxAccountId':_0x4bacdb('0x15d7'),'SmsAccountId':'null','OpenchannelAccountId':'null','ChatWebsiteId':'null','WhatsappAccountId':_0x4bacdb('0x15d7'),'ListId':_0x4bacdb('0x15d7'),'limit':0xa,'offset':0x0});}],'userProfile':[_0xb1b4dd('0x1fbc'),_0xb1b4dd('0x21ef'),function(_0x46f93e,_0x29cf41){const _0x10b77a=_0xb1b4dd;return _0x29cf41['hasRole'](_0x10b77a('0xa7c'))?null:_0x46f93e['resolve'](_0x10b77a('0x697'),{'fields':_0x10b77a('0x686'),'id':_0x29cf41[_0x10b77a('0x26cd')]()[_0x10b77a('0xb86')]});}],'userProfileSection':['apiResolver','Auth',function(_0x26a107,_0x2337ca){const _0x3b35b1=_0xb1b4dd;return _0x2337ca[_0x3b35b1('0x1ac6')](_0x3b35b1('0xa7c'))?null:_0x26a107[_0x3b35b1('0x18af')](_0x3b35b1('0xaf'),{'fields':_0x3b35b1('0xe26'),'userProfileId':_0x2337ca[_0x3b35b1('0x26cd')]()[_0x3b35b1('0xb86')],'sectionId':0x3ea});}]},'authenticate':!![],'permissionId':0x3ea,'bodyClass':_0xb1b4dd('0x28e6')});}angular[_0x36e6f4('0x896')]('app.tools.dispositions',[])[_0x36e6f4('0xe11')](_0x43dda9)[_0x36e6f4('0x75e')](_0x36e6f4('0x17a3'),_0x1eb4c4)[_0x36e6f4('0x75e')](_0x36e6f4('0x1396'),_0x40f9d7);const _0x5a911c=_0x2734b2['p']+'src/js/modules/main/apps/tools/views/triggers/triggers.html/triggers.html',_0x1ba183=_0x2734b2['p']+'src/js/modules/main/apps/tools/views/triggers/edit/view.html/view.html';_0x24234b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x1991'),_0x36e6f4('0xe00'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x24234b(_0x5d0a29,_0x5e0990,_0x16acb0,_0x8827bc,_0x41c84a,_0x127ff5,_0x3d1540,_0x61c0ad,_0x401caf,_0x582c9f){const _0x5f2d63=_0x36e6f4,_0x511d6a=this;_0x511d6a[_0x5f2d63('0x98')]=_0x3d1540[_0x5f2d63('0x26cd')](),_0x511d6a[_0x5f2d63('0xe00')]=angular[_0x5f2d63('0x225f')](_0x41c84a),_0x511d6a[_0x5f2d63('0x1991')]=angular[_0x5f2d63('0x225f')](_0x8827bc),_0x511d6a[_0x5f2d63('0xf8a')]=_0x401caf,_0x511d6a[_0x5f2d63('0x5c9')]=_0x61c0ad,_0x511d6a[_0x5f2d63('0x243c')]=_0x582c9f,_0x511d6a[_0x5f2d63('0x20e8')]=![],_0x511d6a['errors']=[];!_0x511d6a[_0x5f2d63('0xe00')]&&(_0x511d6a[_0x5f2d63('0xe00')]={'channel':_0x5f2d63('0x21da')},_0x511d6a[_0x5f2d63('0x20e8')]=!![]);_0x511d6a[_0x5f2d63('0x733')]=_0xcac201,_0x511d6a[_0x5f2d63('0x1c16')]=_0x4682c9,_0x511d6a[_0x5f2d63('0xf80')]=_0x36b82b,_0x511d6a['closeDialog']=_0xb5beb3;function _0xcac201(){const _0x4fce40=_0x5f2d63;_0x511d6a[_0x4fce40('0x61a')]=[],_0x127ff5[_0x4fce40('0xe00')][_0x4fce40('0x9cc')](_0x511d6a['trigger'])[_0x4fce40('0xa44')]['then'](function(_0x57239e){const _0x27de0c=_0x4fce40;_0x511d6a['triggers'][_0x27de0c('0x2450')](_0x57239e['toJSON']()),_0x16acb0[_0x27de0c('0x103b')]({'title':_0x5e0990[_0x27de0c('0x25cc')]('TOOLS.NOTIFICATIONS.TRIGGER_CREATED_SUCCESS_TITLE')}),_0xb5beb3(_0x511d6a[_0x27de0c('0x1991')]);})[_0x4fce40('0x1a80')](function(_0x310453){const _0x37b4a4=_0x4fce40;if(_0x310453[_0x37b4a4('0x25f4')]&&_0x310453[_0x37b4a4('0x25f4')][_0x37b4a4('0x61a')]&&_0x310453[_0x37b4a4('0x25f4')]['errors'][_0x37b4a4('0x264b')]){_0x511d6a[_0x37b4a4('0x61a')]=_0x310453[_0x37b4a4('0x25f4')]['errors']||[{'message':_0x310453[_0x37b4a4('0x1586')](),'type':_0x37b4a4('0x1f15')}];for(let _0x3396ab=0x0;_0x3396ab<_0x310453[_0x37b4a4('0x25f4')][_0x37b4a4('0x61a')][_0x37b4a4('0x264b')];_0x3396ab+=0x1){_0x16acb0[_0x37b4a4('0xfc9')]({'title':_0x310453['data'][_0x37b4a4('0x61a')][_0x3396ab]['type'],'msg':_0x310453[_0x37b4a4('0x25f4')][_0x37b4a4('0x61a')][_0x3396ab][_0x37b4a4('0x1e70')]});}}else _0x16acb0[_0x37b4a4('0xfc9')]({'title':_0x310453[_0x37b4a4('0x52d')]?'API:'+_0x310453[_0x37b4a4('0x52d')]+_0x37b4a4('0x11e1')+_0x310453[_0x37b4a4('0xe1b')]:_0x37b4a4('0x1f15'),'msg':_0x310453['data']?JSON[_0x37b4a4('0xbac')](_0x310453['data']['message']):_0x310453['toString']()});});}function _0x4682c9(){const _0x242a60=_0x5f2d63;_0x511d6a[_0x242a60('0x61a')]=[],_0x127ff5['trigger']['update']({'id':_0x511d6a['trigger']['id']},_0x511d6a['trigger'])[_0x242a60('0xa44')]['then'](function(){const _0x3dbf7b=_0x242a60;_0x511d6a[_0x3dbf7b('0x1991')]=_0x2cfb05()[_0x3dbf7b('0x2563')](_0x511d6a[_0x3dbf7b('0x1991')],function(_0x37b712){const _0x32b03c=_0x3dbf7b;if(_0x37b712['id']===_0x511d6a[_0x32b03c('0xe00')]['id'])return _0x511d6a[_0x32b03c('0xe00')];else return _0x37b712;}),_0x16acb0[_0x3dbf7b('0x103b')]({'title':_0x5e0990[_0x3dbf7b('0x25cc')](_0x3dbf7b('0x1e4c'))}),_0xb5beb3(_0x511d6a[_0x3dbf7b('0x1991')]);})[_0x242a60('0x1a80')](function(_0x81b232){const _0x4abe8d=_0x242a60;if(_0x81b232['data']&&_0x81b232['data'][_0x4abe8d('0x61a')]&&_0x81b232[_0x4abe8d('0x25f4')][_0x4abe8d('0x61a')][_0x4abe8d('0x264b')]){_0x511d6a[_0x4abe8d('0x61a')]=_0x81b232[_0x4abe8d('0x25f4')][_0x4abe8d('0x61a')]||[{'message':_0x81b232[_0x4abe8d('0x1586')](),'type':'api.trigger.update'}];for(let _0x47c6e1=0x0;_0x47c6e1<_0x81b232[_0x4abe8d('0x25f4')][_0x4abe8d('0x61a')][_0x4abe8d('0x264b')];_0x47c6e1++){_0x16acb0[_0x4abe8d('0xfc9')]({'title':_0x81b232[_0x4abe8d('0x25f4')][_0x4abe8d('0x61a')][_0x47c6e1][_0x4abe8d('0x1345')],'msg':_0x81b232['data'][_0x4abe8d('0x61a')][_0x47c6e1][_0x4abe8d('0x1e70')]});}}else _0x16acb0[_0x4abe8d('0xfc9')]({'title':_0x81b232[_0x4abe8d('0x52d')]?_0x4abe8d('0x1e21')+_0x81b232[_0x4abe8d('0x52d')]+_0x4abe8d('0x11e1')+_0x81b232[_0x4abe8d('0xe1b')]:_0x4abe8d('0x1360'),'msg':_0x81b232[_0x4abe8d('0x25f4')]?JSON[_0x4abe8d('0xbac')](_0x81b232[_0x4abe8d('0x25f4')][_0x4abe8d('0x1e70')]):_0x81b232[_0x4abe8d('0x1586')]()});});}function _0x36b82b(_0x101c39){const _0xa39b03=_0x5f2d63;_0x511d6a[_0xa39b03('0x61a')]=[];const _0x273e8a=_0x5d0a29['confirm']({'skipHide':!![]})[_0xa39b03('0xcdc')](_0x5e0990[_0xa39b03('0x25cc')](_0xa39b03('0x5b9')))['content'](_0x5e0990[_0xa39b03('0x25cc')](_0xa39b03('0x2523'),{'name':_0x511d6a[_0xa39b03('0xe00')]['name']}))[_0xa39b03('0x8e8')]('Delete\x20trigger')['ok'](_0x5e0990[_0xa39b03('0x25cc')](_0xa39b03('0xa68')))[_0xa39b03('0x3f')](_0x5e0990[_0xa39b03('0x25cc')](_0xa39b03('0x12a3')))[_0xa39b03('0x203b')](_0x101c39);_0x5d0a29[_0xa39b03('0x1f80')](_0x273e8a)[_0xa39b03('0x1166')](function(){const _0x1a8539=_0xa39b03;_0x127ff5[_0x1a8539('0xe00')][_0x1a8539('0x906')]({'id':_0x511d6a[_0x1a8539('0xe00')]['id']})[_0x1a8539('0xa44')][_0x1a8539('0x1166')](function(){const _0x5bcce1=_0x1a8539;_0x511d6a[_0x5bcce1('0x1991')]=_0x2cfb05()[_0x5bcce1('0x1c33')](_0x511d6a[_0x5bcce1('0x1991')],function(_0x6c23ad){const _0x172995=_0x5bcce1;return _0x6c23ad['id']!==_0x511d6a[_0x172995('0xe00')]['id'];}),_0x16acb0['success']({'title':_0x5e0990[_0x5bcce1('0x25cc')]('TOOLS.NOTIFICATIONS.TRIGGER_DELETED_SUCCESS_TITLE')}),_0xb5beb3(_0x511d6a[_0x5bcce1('0x1991')]);})[_0x1a8539('0x1a80')](function(_0x3ee01a){const _0x172054=_0x1a8539;if(_0x3ee01a[_0x172054('0x25f4')]&&_0x3ee01a[_0x172054('0x25f4')][_0x172054('0x61a')]&&_0x3ee01a[_0x172054('0x25f4')]['errors'][_0x172054('0x264b')]){_0x511d6a[_0x172054('0x61a')]=_0x3ee01a[_0x172054('0x25f4')]['errors']||[{'message':_0x3ee01a[_0x172054('0x1586')](),'type':_0x172054('0x1d05')}];for(let _0x239248=0x0;_0x239248<_0x3ee01a[_0x172054('0x25f4')][_0x172054('0x61a')][_0x172054('0x264b')];_0x239248++){_0x16acb0['error']({'title':_0x3ee01a[_0x172054('0x25f4')][_0x172054('0x61a')][_0x239248]['type'],'msg':_0x3ee01a[_0x172054('0x25f4')][_0x172054('0x61a')][_0x239248][_0x172054('0x1e70')]});}}else _0x16acb0[_0x172054('0xfc9')]({'title':_0x3ee01a[_0x172054('0x52d')]?_0x172054('0x1e21')+_0x3ee01a[_0x172054('0x52d')]+_0x172054('0x11e1')+_0x3ee01a['statusText']:_0x172054('0x1d05'),'msg':_0x3ee01a[_0x172054('0x25f4')]?JSON['stringify'](_0x3ee01a[_0x172054('0x25f4')][_0x172054('0x1e70')]):_0x3ee01a[_0x172054('0x1e70')]||_0x3ee01a[_0x172054('0x1586')]()});});},function(){});}function _0xb5beb3(_0x22f4d1){const _0x16ef36=_0x5f2d63;_0x5d0a29[_0x16ef36('0x1197')](_0x22f4d1);}}const _0x5b32c5=_0x24234b,_0x4dd8bb=_0x2734b2['p']+'src/js/modules/main/apps/tools/views/triggers/edit/actions/create/dialog.html/dialog.html';_0x223fdc[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x223fdc(_0x4141f8,_0x4b92f7,_0x4855fc,_0x31692d,_0x300be1,_0x4b9311,_0x2c7fd2,_0xd9845d){const _0x48c48f=_0x36e6f4,_0x11117b=this;_0x11117b[_0x48c48f('0x98')]=_0xd9845d['getCurrentUser'](),_0x11117b['trigger']={},_0x11117b[_0x48c48f('0xbb2')]={'count':0x0,'rows':[]},_0x11117b[_0x48c48f('0x77a')]=[],_0x11117b[_0x48c48f('0x2218')]={'fields':_0x48c48f('0x3d1'),'limit':0xa,'page':0x1},_0x11117b[_0x48c48f('0x13a8')]={'zendesk':_0x48c48f('0xa0e'),'salesforce':_0x48c48f('0x81d'),'sugarcrm':'SugarCRM','freshdesk':_0x48c48f('0x3f4'),'desk':_0x48c48f('0x1289'),'zoho':_0x48c48f('0xb2d'),'vtiger':_0x48c48f('0x1fae'),'dynamics365':_0x48c48f('0x1432'),'servicenow':_0x48c48f('0x185e'),'freshsales':_0x48c48f('0x22a1')},_0x11117b['motionBarOptions']={0x0:_0x48c48f('0x8ca'),0x1:_0x48c48f('0x1146'),0x2:'Windows\x20App'},_0x11117b[_0x48c48f('0xae0')]=_0x249e3e,_0x11117b['success']=_0x3a5080,_0x11117b[_0x48c48f('0x1e23')]=_0xc550f8,_0x11117b[_0x48c48f('0x1124')]=_0x30fa88,_0x11117b['exportSelectedTriggerActions']=_0x4391b8,_0x11117b[_0x48c48f('0x8a2')]=_0x248f1b,_0x11117b[_0x48c48f('0x18be')]=_0x28886a;function _0x249e3e(_0x4cbedc,_0x43441f){const _0x2e4b58=_0x48c48f;_0x11117b[_0x2e4b58('0xe00')]=_0x4cbedc,_0x11117b[_0x2e4b58('0x243c')]=typeof _0x43441f!==_0x2e4b58('0x1048')?_0x43441f:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x11117b['query']['ActionId']=_0x11117b[_0x2e4b58('0xe00')]['id'],_0x11117b[_0x2e4b58('0x2218')]['id']=_0x11117b[_0x2e4b58('0xe00')]['id'],_0xc550f8();}function _0x1f2325(){const _0x32595d=_0x48c48f;_0xd9845d[_0x32595d('0xe0f')]()?_0x2c7fd2['cmList']['get']({'fields':_0x32595d('0x1776'),'sort':'name','nolimit':_0x32595d('0xf3b')})['$promise'][_0x32595d('0x1166')](function(_0x4cc20b){const _0x34b972=_0x32595d;_0x11117b[_0x34b972('0x8de')]=_0x4cc20b[_0x34b972('0x269a')]||[];})['catch'](function(_0x299328){const _0x536e6f=_0x32595d;_0x4b9311['error']({'title':_0x299328[_0x536e6f('0x52d')]?_0x536e6f('0x1e21')+_0x299328[_0x536e6f('0x52d')]+'\x20-\x20'+_0x299328['statusText']:'SYSTEM:GET_LISTS','msg':_0x299328[_0x536e6f('0x25f4')]?JSON[_0x536e6f('0xbac')](_0x299328[_0x536e6f('0x25f4')]):_0x299328[_0x536e6f('0x1586')]()});}):_0x2c7fd2[_0x32595d('0xdd9')][_0x32595d('0xd83')]({'fields':'id,name','sort':_0x32595d('0x4f0'),'nolimit':_0x32595d('0xf3b')})[_0x32595d('0xa44')][_0x32595d('0x1166')](function(_0x44eb80){const _0x4796ee=_0x32595d;_0x11117b[_0x4796ee('0x8de')]=_0x44eb80['rows']||[];})[_0x32595d('0x1166')](function(){const _0x4e3e2c=_0x32595d;return _0x2c7fd2['userProfileSection']['get']({'userProfileId':_0x11117b[_0x4e3e2c('0x98')][_0x4e3e2c('0xb86')],'sectionId':0x12d})[_0x4e3e2c('0xa44')];})['then'](function(_0x59ff7b){const _0x41c947=_0x32595d,_0x4f16b8=_0x59ff7b&&_0x59ff7b[_0x41c947('0x269a')]?_0x59ff7b['rows'][0x0]:null;if(!_0x4f16b8){const _0x3c9608=[],_0x21883c=[];_0x11117b['triggerActions'][_0x41c947('0x269a')][_0x41c947('0x2782')](function(_0x5c5f1d){const _0x55a7be=_0x41c947;if(_0x5c5f1d[_0x55a7be('0x79f')]===_0x55a7be('0xaa8')){const _0x44d34f=_0x2cfb05()[_0x55a7be('0xc38')](_0x11117b[_0x55a7be('0x8de')],{'id':Number(_0x5c5f1d[_0x55a7be('0x1819')])});_0x21883c[_0x55a7be('0x1514')](_0x44d34f);}});for(let _0x1e42b8=0x0;_0x1e42b8<_0x11117b[_0x41c947('0x8de')]['length'];_0x1e42b8++){const _0x23f7b1=_0x2cfb05()[_0x41c947('0x1798')](_0x21883c,{'id':_0x11117b[_0x41c947('0x8de')][_0x1e42b8]['id']});_0x23f7b1&&(_0x11117b['lists'][_0x1e42b8]['canSelect']=![],_0x3c9608[_0x41c947('0x1514')](_0x11117b['lists'][_0x1e42b8]));}_0x11117b['lists']=_0x3c9608;}else{if(!_0x4f16b8['autoAssociation'])return _0x2c7fd2['userProfileResource'][_0x41c947('0xd83')]({'sectionId':_0x4f16b8['id']})[_0x41c947('0xa44')]['then'](function(_0x8e0c41){const _0x5d1ebe=_0x41c947,_0x442317=_0x2cfb05()[_0x5d1ebe('0x2563')](_0x8e0c41['rows'],function(_0x33d412){const _0x21b906=_0x5d1ebe;return _0x2cfb05()[_0x21b906('0xc38')](_0x11117b[_0x21b906('0x8de')],{'id':_0x33d412[_0x21b906('0x24e8')]});});let _0xe43163=null;_0xe43163=[],_0x11117b[_0x5d1ebe('0xbb2')]['rows']['forEach'](function(_0x4cd898){const _0x1f2617=_0x5d1ebe;if(_0x4cd898[_0x1f2617('0x79f')]===_0x1f2617('0xaa8')){const _0x4751e6=_0x2cfb05()[_0x1f2617('0xc38')](_0x11117b[_0x1f2617('0x8de')],{'id':Number(_0x4cd898[_0x1f2617('0x1819')])});_0xe43163[_0x1f2617('0x1514')](_0x4751e6);}}),!_0x2cfb05()[_0x5d1ebe('0x1081')](_0xe43163)&&_0xe43163['forEach'](function(_0x410a18){const _0xe2475b=_0x5d1ebe;if(!_0x2cfb05()[_0xe2475b('0x1798')](_0x442317,['id',_0x410a18['id']])){const _0x199c56=_0x2cfb05()[_0xe2475b('0xc38')](_0x11117b[_0xe2475b('0x8de')],{'id':_0x410a18['id']});_0x199c56['canSelect']=![],_0x442317[_0xe2475b('0x1514')](_0x199c56);}}),_0x11117b[_0x5d1ebe('0x8de')]=_0x442317;});}})[_0x32595d('0x1a80')](function(_0x49228f){const _0x22c78b=_0x32595d;_0x4b9311[_0x22c78b('0xfc9')]({'title':_0x49228f[_0x22c78b('0x52d')]?'API:'+_0x49228f[_0x22c78b('0x52d')]+_0x22c78b('0x11e1')+_0x49228f[_0x22c78b('0xe1b')]:'SYSTEM:GETlists','msg':_0x49228f[_0x22c78b('0x25f4')]?JSON[_0x22c78b('0xbac')](_0x49228f[_0x22c78b('0x25f4')]):_0x49228f[_0x22c78b('0x1586')]()});});}function _0x139ff4(){const _0x2b264f=_0x48c48f,_0x710914=_0x2cfb05()(_0x11117b['triggerActions'][_0x2b264f('0x269a')])[_0x2b264f('0x2563')](function(_0x5af85d){const _0x170f74=_0x2b264f;return _0x5af85d['action']===_0x170f74('0x2742')?_0x5af85d[_0x170f74('0x1819')]:undefined;})[_0x2b264f('0xc4')]()[_0x2b264f('0x7ae')]()[_0x2b264f('0x18e0')]();_0x710914[_0x2b264f('0x2782')](function(_0x321bdf){const _0x251830=_0x2b264f,_0x5bf4ee=_0x321bdf+_0x251830('0x1288');if(!_0x11117b[_0x5bf4ee]){const _0x3049dd=_0x251830('0x15eb')+_0x2cfb05()['startCase'](_0x321bdf)+_0x251830('0x1758');_0x2c7fd2[_0x3049dd][_0x251830('0xd83')]({'fields':_0x251830('0x1776'),'sort':'id','nolimit':'true'})[_0x251830('0xa44')][_0x251830('0x1166')](function(_0x201b2f){const _0x3004b4=_0x251830;_0x11117b[_0x5bf4ee]=_0x201b2f[_0x3004b4('0x269a')]||[];})[_0x251830('0x1a80')](function(_0x18e0d1){const _0xee821e=_0x251830;_0x4b9311['error']({'title':_0x18e0d1[_0xee821e('0x52d')]?_0xee821e('0x1e21')+_0x18e0d1['status']+'\x20-\x20'+_0x18e0d1[_0xee821e('0xe1b')]:_0xee821e('0xfae')+_0x5bf4ee[_0xee821e('0x1387')]()+_0xee821e('0x204d'),'msg':_0x18e0d1['data']?JSON['stringify'](_0x18e0d1[_0xee821e('0x25f4')]):_0x18e0d1[_0xee821e('0x1586')]()});});}});}function _0x6c9876(){const _0x5a135e=_0x48c48f;_0xd9845d[_0x5a135e('0xe0f')]()?_0x2c7fd2[_0x5a135e('0x129b')][_0x5a135e('0xd83')]({'fields':_0x5a135e('0x1776'),'sort':_0x5a135e('0x4f0'),'nolimit':_0x5a135e('0xf3b')})[_0x5a135e('0xa44')][_0x5a135e('0x1166')](function(_0x4362fb){const _0x511904=_0x5a135e;_0x11117b[_0x511904('0x149f')]=_0x4362fb[_0x511904('0x269a')]||[];})[_0x5a135e('0x1a80')](function(_0x107476){const _0x18611a=_0x5a135e;_0x4b9311[_0x18611a('0xfc9')]({'title':_0x107476[_0x18611a('0x52d')]?'API:'+_0x107476[_0x18611a('0x52d')]+'\x20-\x20'+_0x107476[_0x18611a('0xe1b')]:_0x18611a('0x178b'),'msg':_0x107476[_0x18611a('0x25f4')]?JSON['stringify'](_0x107476[_0x18611a('0x25f4')]):_0x107476[_0x18611a('0x1586')]()});}):_0x2c7fd2[_0x5a135e('0x129b')][_0x5a135e('0xd83')]({'fields':_0x5a135e('0x1776'),'sort':_0x5a135e('0x4f0'),'nolimit':_0x5a135e('0xf3b')})[_0x5a135e('0xa44')]['then'](function(_0x29c7a2){const _0x4db44c=_0x5a135e;_0x11117b['projects']=_0x29c7a2[_0x4db44c('0x269a')]||[];})['then'](function(){const _0x22b867=_0x5a135e;return _0x2c7fd2['userProfileSection'][_0x22b867('0xd83')]({'userProfileId':_0x11117b['currentUser']['userProfileId'],'sectionId':0x6a5})[_0x22b867('0xa44')];})[_0x5a135e('0x1166')](function(_0x4e8086){const _0x3d5f70=_0x5a135e,_0x3361e3=_0x4e8086&&_0x4e8086[_0x3d5f70('0x269a')]?_0x4e8086[_0x3d5f70('0x269a')][0x0]:null;if(!_0x3361e3){const _0x381f69=[],_0x197e0e=[];_0x11117b[_0x3d5f70('0xbb2')][_0x3d5f70('0x269a')]['forEach'](function(_0x49d0cd){const _0x56fd01=_0x3d5f70;if(_0x49d0cd['action']===_0x56fd01('0x179f')){const _0x13870b=_0x2cfb05()[_0x56fd01('0xc38')](_0x11117b[_0x56fd01('0x149f')],{'id':Number(_0x49d0cd['data1'])});_0x197e0e[_0x56fd01('0x1514')](_0x13870b);}});for(let _0x5df586=0x0;_0x5df586<_0x11117b[_0x3d5f70('0x149f')][_0x3d5f70('0x264b')];_0x5df586++){const _0x375095=_0x2cfb05()[_0x3d5f70('0x1798')](_0x197e0e,{'id':_0x11117b[_0x3d5f70('0x149f')][_0x5df586]['id']});_0x375095&&(_0x11117b[_0x3d5f70('0x149f')][_0x5df586][_0x3d5f70('0x2378')]=![],_0x381f69[_0x3d5f70('0x1514')](_0x11117b['projects'][_0x5df586]));}_0x11117b[_0x3d5f70('0x149f')]=_0x381f69;}else{if(!_0x3361e3[_0x3d5f70('0x1a2b')])return _0x2c7fd2[_0x3d5f70('0x4b5')]['get']({'sectionId':_0x3361e3['id']})[_0x3d5f70('0xa44')][_0x3d5f70('0x1166')](function(_0x33c5a3){const _0x50a394=_0x3d5f70,_0x463266=_0x2cfb05()[_0x50a394('0x2563')](_0x33c5a3[_0x50a394('0x269a')],function(_0xde8184){const _0x3d1033=_0x50a394;return _0x2cfb05()[_0x3d1033('0xc38')](_0x11117b['projects'],{'id':_0xde8184[_0x3d1033('0x24e8')]});});let _0x5309c6=null;_0x5309c6=[],_0x11117b[_0x50a394('0xbb2')][_0x50a394('0x269a')][_0x50a394('0x2782')](function(_0x3f886f){const _0x493af6=_0x50a394;if(_0x3f886f[_0x493af6('0x79f')]===_0x493af6('0x179f')){const _0x456ee4=_0x2cfb05()[_0x493af6('0xc38')](_0x11117b[_0x493af6('0x149f')],{'id':Number(_0x3f886f['data1'])});_0x5309c6[_0x493af6('0x1514')](_0x456ee4);}}),!_0x2cfb05()[_0x50a394('0x1081')](_0x5309c6)&&_0x5309c6[_0x50a394('0x2782')](function(_0x28c333){const _0x5e50c7=_0x50a394;if(!_0x2cfb05()[_0x5e50c7('0x1798')](_0x463266,['id',_0x28c333['id']])){const _0x55332e=_0x2cfb05()['find'](_0x11117b[_0x5e50c7('0x149f')],{'id':_0x28c333['id']});_0x55332e[_0x5e50c7('0x2378')]=![],_0x463266[_0x5e50c7('0x1514')](_0x55332e);}}),_0x11117b['projects']=_0x463266;});}})[_0x5a135e('0x1a80')](function(_0xf4eeb7){const _0x8450f=_0x5a135e;_0x4b9311[_0x8450f('0xfc9')]({'title':_0xf4eeb7[_0x8450f('0x52d')]?_0x8450f('0x1e21')+_0xf4eeb7[_0x8450f('0x52d')]+_0x8450f('0x11e1')+_0xf4eeb7[_0x8450f('0xe1b')]:_0x8450f('0x10f2'),'msg':_0xf4eeb7[_0x8450f('0x25f4')]?JSON[_0x8450f('0xbac')](_0xf4eeb7['data']):_0xf4eeb7['toString']()});});}function _0x2feffb(){const _0x47d086=_0x48c48f;_0xd9845d[_0x47d086('0xe0f')]()?_0x2c7fd2[_0x47d086('0x243')][_0x47d086('0xd83')]({'fields':_0x47d086('0x1776'),'sort':'id','nolimit':_0x47d086('0xf3b')})[_0x47d086('0xa44')][_0x47d086('0x1166')](function(_0x5531d1){const _0x23a8cd=_0x47d086;_0x11117b[_0x23a8cd('0x12d0')]=_0x5531d1['rows']||[];})[_0x47d086('0x1a80')](function(_0x1f1e73){const _0x1f82f4=_0x47d086;_0x4b9311[_0x1f82f4('0xfc9')]({'title':_0x1f1e73[_0x1f82f4('0x52d')]?_0x1f82f4('0x1e21')+_0x1f1e73[_0x1f82f4('0x52d')]+_0x1f82f4('0x11e1')+_0x1f1e73[_0x1f82f4('0xe1b')]:_0x1f82f4('0x1370'),'msg':_0x1f1e73[_0x1f82f4('0x25f4')]?JSON[_0x1f82f4('0xbac')](_0x1f1e73[_0x1f82f4('0x25f4')]):_0x1f1e73[_0x1f82f4('0x1586')]()});}):_0x2c7fd2[_0x47d086('0x243')][_0x47d086('0xd83')]({'fields':_0x47d086('0x1776'),'sort':'id','nolimit':_0x47d086('0xf3b')})['$promise']['then'](function(_0x58afb6){const _0x2a189c=_0x47d086;_0x11117b[_0x2a189c('0x12d0')]=_0x58afb6[_0x2a189c('0x269a')]||[];})[_0x47d086('0x1166')](function(){const _0xdca9f1=_0x47d086;return _0x2c7fd2[_0xdca9f1('0x17aa')][_0xdca9f1('0xd83')]({'userProfileId':_0x11117b['currentUser']['userProfileId'],'sectionId':0x3f1})[_0xdca9f1('0xa44')];})[_0x47d086('0x1166')](function(_0x432caf){const _0x1a2e46=_0x47d086,_0x5d5141=_0x432caf&&_0x432caf['rows']?_0x432caf['rows'][0x0]:null;if(!_0x5d5141){const _0xc450fb=[],_0x4df4ff=[];_0x11117b[_0x1a2e46('0xbb2')][_0x1a2e46('0x269a')]['forEach'](function(_0x54b428){const _0x2a47f1=_0x1a2e46;if(_0x2cfb05()['includes']([_0x2a47f1('0x209b'),_0x2a47f1('0x2f0')],_0x54b428[_0x2a47f1('0x79f')])){const _0x352e2f=_0x2cfb05()[_0x2a47f1('0xc38')](_0x11117b[_0x2a47f1('0x12d0')],{'id':Number(_0x54b428[_0x2a47f1('0x17ca')])});_0x4df4ff['push'](_0x352e2f);}});for(let _0x2f4371=0x0;_0x2f4371<_0x11117b['templates'][_0x1a2e46('0x264b')];_0x2f4371++){const _0x3c35ce=_0x2cfb05()['some'](_0x4df4ff,{'id':_0x11117b[_0x1a2e46('0x12d0')][_0x2f4371]['id']});_0x3c35ce&&(_0x11117b[_0x1a2e46('0x12d0')][_0x2f4371]['canSelect']=![],_0xc450fb['push'](_0x11117b[_0x1a2e46('0x12d0')][_0x2f4371]));}_0x11117b[_0x1a2e46('0x12d0')]=_0xc450fb;}else{if(!_0x5d5141[_0x1a2e46('0x1a2b')])return _0x2c7fd2[_0x1a2e46('0x4b5')][_0x1a2e46('0xd83')]({'sectionId':_0x5d5141['id']})[_0x1a2e46('0xa44')][_0x1a2e46('0x1166')](function(_0x365d98){const _0x4bc1e4=_0x1a2e46,_0x21a10a=_0x2cfb05()[_0x4bc1e4('0x2563')](_0x365d98[_0x4bc1e4('0x269a')],function(_0x5e3766){return _0x2cfb05()['find'](_0x11117b['templates'],{'id':_0x5e3766['resourceId']});});let _0x28ecf3=null;_0x28ecf3=[],_0x11117b[_0x4bc1e4('0xbb2')]['rows'][_0x4bc1e4('0x2782')](function(_0x45cc66){const _0x295962=_0x4bc1e4;if(_0x2cfb05()[_0x295962('0x1257')]([_0x295962('0x209b'),'browser'],_0x45cc66[_0x295962('0x79f')])){const _0x350a0e=_0x2cfb05()['find'](_0x11117b[_0x295962('0x12d0')],{'id':Number(_0x45cc66['data2'])});_0x28ecf3['push'](_0x350a0e);}}),!_0x2cfb05()[_0x4bc1e4('0x1081')](_0x28ecf3)&&_0x28ecf3[_0x4bc1e4('0x2782')](function(_0xbc4a45){const _0x36bb51=_0x4bc1e4;if(!_0x2cfb05()[_0x36bb51('0x1798')](_0x21a10a,['id',_0xbc4a45['id']])){const _0xab66f0=_0x2cfb05()[_0x36bb51('0xc38')](_0x11117b[_0x36bb51('0x12d0')],{'id':_0xbc4a45['id']});_0xab66f0[_0x36bb51('0x2378')]=![],_0x21a10a[_0x36bb51('0x1514')](_0xab66f0);}}),_0x11117b[_0x4bc1e4('0x12d0')]=_0x21a10a;});}})['catch'](function(_0x1cebcc){const _0x1bb631=_0x47d086;_0x4b9311['error']({'title':_0x1cebcc[_0x1bb631('0x52d')]?'API:'+_0x1cebcc[_0x1bb631('0x52d')]+_0x1bb631('0x11e1')+_0x1cebcc[_0x1bb631('0xe1b')]:_0x1bb631('0x1370'),'msg':_0x1cebcc[_0x1bb631('0x25f4')]?JSON[_0x1bb631('0xbac')](_0x1cebcc['data']):_0x1cebcc[_0x1bb631('0x1586')]()});});}function _0xe0cadd(){const _0x1876a3=_0x48c48f;if(_0x2cfb05()[_0x1876a3('0x1798')](_0x11117b['triggerActions'][_0x1876a3('0x269a')],[_0x1876a3('0x79f'),_0x1876a3('0xaa8')])){if(!_0x11117b[_0x1876a3('0x8de')])_0x1f2325();}_0x2cfb05()[_0x1876a3('0x1798')](_0x11117b[_0x1876a3('0xbb2')][_0x1876a3('0x269a')],[_0x1876a3('0x79f'),_0x1876a3('0x2742')])&&_0x139ff4();if(_0x2cfb05()[_0x1876a3('0x1798')](_0x11117b[_0x1876a3('0xbb2')][_0x1876a3('0x269a')],function(_0x20afce){const _0x8f63f4=_0x1876a3;return _0x2cfb05()[_0x8f63f4('0x1257')]([_0x8f63f4('0x209b'),_0x8f63f4('0x2f0')],_0x20afce[_0x8f63f4('0x79f')]);})){if(!_0x11117b['templates'])_0x2feffb();}if(_0x2cfb05()[_0x1876a3('0x1798')](_0x11117b[_0x1876a3('0xbb2')]['rows'],[_0x1876a3('0x79f'),_0x1876a3('0x179f')])){if(!_0x11117b[_0x1876a3('0x149f')])_0x6c9876();}}function _0x3a5080(_0x3b9e77){const _0x12a84f=_0x48c48f;_0x11117b[_0x12a84f('0xbb2')]=_0x3b9e77||{'count':0x0,'rows':[]},_0xe0cadd();}function _0xc550f8(){const _0x513e04=_0x48c48f;_0x11117b[_0x513e04('0x2218')][_0x513e04('0x1098')]=(_0x11117b[_0x513e04('0x2218')][_0x513e04('0x1a43')]-0x1)*_0x11117b['query'][_0x513e04('0x163f')],_0x11117b[_0x513e04('0x1f48')]=_0x2c7fd2[_0x513e04('0xe00')][_0x513e04('0xd05')](_0x11117b[_0x513e04('0x2218')],_0x3a5080)[_0x513e04('0xa44')];}function _0x30fa88(_0x2eb9f0,_0x1fdac8){const _0x6c3667=_0x48c48f;_0x31692d[_0x6c3667('0x1f80')]({'controller':_0x6c3667('0x1e29'),'controllerAs':'vm','templateUrl':_0x4dd8bb,'parent':angular[_0x6c3667('0x1194')](_0x300be1[_0x6c3667('0x8d2')]),'targetEvent':_0x2eb9f0,'clickOutsideToClose':!![],'locals':{'trigger':_0x11117b[_0x6c3667('0xe00')],'action':_0x1fdac8,'actions':_0x11117b[_0x6c3667('0xbb2')]['rows'],'license':null,'setting':null,'crudPermissions':_0x11117b[_0x6c3667('0x243c')]}})['then'](function(_0x4e1fbe){const _0x2d491f=_0x6c3667;_0x4e1fbe&&(_0x11117b[_0x2d491f('0xbb2')]={'count':_0x4e1fbe[_0x2d491f('0x264b')],'rows':_0x4e1fbe},_0xe0cadd());});}function _0x248f1b(_0x3f1255,_0x143aa3){const _0x5192f0=_0x48c48f,_0x8afaea=_0x31692d[_0x5192f0('0x1d26')]()['title'](_0x4b92f7[_0x5192f0('0x25cc')](_0x5192f0('0x279f')))[_0x5192f0('0x8e8')](_0x5192f0('0x1182'))[_0x5192f0('0x203b')](_0x143aa3)['ok']('OK')[_0x5192f0('0x3f')](_0x4b92f7[_0x5192f0('0x25cc')](_0x5192f0('0x12a3')));_0x31692d[_0x5192f0('0x1f80')](_0x8afaea)[_0x5192f0('0x1166')](function(){_0x196f64(_0x3f1255,!![]);});}function _0x196f64(_0xb4b20e,_0x229853){const _0x31ebd8=_0x48c48f;_0x2c7fd2['action']['delete']({'id':_0xb4b20e['id']})[_0x31ebd8('0xa44')][_0x31ebd8('0x1166')](function(){const _0x2878db=_0x31ebd8;_0xc550f8(),_0x229853&&_0x4b9311[_0x2878db('0x103b')]({'title':_0x4b92f7[_0x2878db('0x25cc')]('TOOLS.NOTIFICATIONS.ACTION_DELETED_SUCCESS_TITLE')});})[_0x31ebd8('0x1a80')](function(_0x5ee079){const _0x2ad670=_0x31ebd8;if(_0x5ee079[_0x2ad670('0x25f4')]&&_0x5ee079[_0x2ad670('0x25f4')][_0x2ad670('0x61a')]&&_0x5ee079[_0x2ad670('0x25f4')]['errors'][_0x2ad670('0x264b')]){_0x11117b['errors']=_0x5ee079[_0x2ad670('0x25f4')]['errors']||[{'message':_0x5ee079[_0x2ad670('0x1586')](),'type':'SYSTEM:GETtrigger'}];for(let _0x501e15=0x0;_0x501e15<_0x5ee079['data'][_0x2ad670('0x61a')][_0x2ad670('0x264b')];_0x501e15++){_0x4b9311['error']({'title':_0x5ee079[_0x2ad670('0x25f4')][_0x2ad670('0x61a')][_0x501e15][_0x2ad670('0x1345')],'msg':_0x5ee079[_0x2ad670('0x25f4')][_0x2ad670('0x61a')][_0x501e15][_0x2ad670('0x1e70')]});}}else _0x4b9311[_0x2ad670('0xfc9')]({'title':_0x5ee079[_0x2ad670('0x52d')]?_0x2ad670('0x1e21')+_0x5ee079[_0x2ad670('0x52d')]+_0x2ad670('0x11e1')+_0x5ee079[_0x2ad670('0xe1b')]:_0x2ad670('0x22a8'),'msg':_0x5ee079[_0x2ad670('0x25f4')]?JSON['stringify'](_0x5ee079['data'][_0x2ad670('0x1e70')]):_0x5ee079['message']||_0x5ee079[_0x2ad670('0x1586')]()});});}function _0x4391b8(){const _0x385699=_0x48c48f,_0x52fa42=angular[_0x385699('0x225f')](_0x11117b[_0x385699('0x77a')]);return _0x11117b[_0x385699('0x77a')]=[],_0x52fa42;}function _0x28886a(_0x19d842){const _0x3741dc=_0x48c48f,_0x1ebf8b=_0x31692d[_0x3741dc('0x1d26')]()[_0x3741dc('0xcdc')](_0x4b92f7[_0x3741dc('0x25cc')](_0x3741dc('0x13da')))[_0x3741dc('0xacc')](_0x4b92f7[_0x3741dc('0x25cc')]('TOOLS.NOTIFICATIONS.ACTIONS_DELETE_MESSAGE',{'total':_0x11117b['selectedTriggerActions']['length']}))[_0x3741dc('0x8e8')]('Delete\x20actions')[_0x3741dc('0x203b')](_0x19d842)['ok']('OK')[_0x3741dc('0x3f')](_0x4b92f7[_0x3741dc('0x25cc')](_0x3741dc('0x12a3')));_0x31692d[_0x3741dc('0x1f80')](_0x1ebf8b)[_0x3741dc('0x1166')](function(){const _0x1e0613=_0x3741dc;_0x11117b['selectedTriggerActions'][_0x1e0613('0x2782')](function(_0x12e7ab){_0x196f64(_0x12e7ab);}),_0x11117b['selectedTriggerActions']=[],_0x4b9311[_0x1e0613('0x103b')]({'title':_0x4b92f7[_0x1e0613('0x25cc')](_0x1e0613('0x11a6'))});});}let _0x214f35=!![],_0x2c83da=0x1;_0x4141f8[_0x48c48f('0xe83')](_0x48c48f('0x28b4'),function(_0x1eefd3,_0x5bd9f2){const _0x2135e6=_0x48c48f;_0x214f35?_0x4855fc(function(){_0x214f35=![];}):(!_0x5bd9f2&&(_0x2c83da=_0x11117b[_0x2135e6('0x2218')][_0x2135e6('0x1a43')]),_0x1eefd3!==_0x5bd9f2&&(_0x11117b[_0x2135e6('0x2218')]['page']=0x1),!_0x1eefd3&&(_0x11117b['query'][_0x2135e6('0x1a43')]=_0x2c83da),_0xc550f8());});}const _0x91845d=_0x223fdc;_0x917006[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x265d'),_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'actions',_0x36e6f4('0x79f'),'trigger','api',_0x36e6f4('0x21ef'),'license','setting',_0x36e6f4('0x243c')];function _0x917006(_0x265e41,_0x5ecebb,_0x337ccc,_0x125221,_0x4ff99e,_0x2ea5b6,_0x2c09b5,_0x1ceb0b,_0x5207ef,_0x550bd5,_0xa0b819,_0x5cf8b1){const _0x17cf5b=_0x36e6f4,_0x582a9f=this;_0x582a9f[_0x17cf5b('0x98')]=_0x5207ef[_0x17cf5b('0x26cd')](),_0x582a9f[_0x17cf5b('0x79f')]=angular[_0x17cf5b('0x225f')](_0x2ea5b6),_0x582a9f[_0x17cf5b('0x18e7')]=angular[_0x17cf5b('0x225f')](_0x4ff99e),_0x582a9f[_0x17cf5b('0xf8a')]=_0xa0b819,_0x582a9f[_0x17cf5b('0x5c9')]=_0x550bd5,_0x582a9f['crudPermissions']=_0x5cf8b1,_0x582a9f[_0x17cf5b('0x1276')]=![],_0x582a9f['errors']=[],_0x582a9f[_0x17cf5b('0xe00')]=angular[_0x17cf5b('0x225f')](_0x2c09b5);!_0x582a9f['action']&&(_0x582a9f['action']={},_0x582a9f[_0x17cf5b('0x1276')]=!![]);_0x582a9f[_0x17cf5b('0x79f')][_0x17cf5b('0xc11')]=_0x265e41[_0x17cf5b('0x23f')]['id']||undefined,_0x582a9f[_0x17cf5b('0x257')]=[_0x17cf5b('0x2026'),_0x17cf5b('0x2459'),_0x17cf5b('0x1fc7')],_0x582a9f[_0x17cf5b('0x1001')]=_0x25806f,_0x582a9f['saveAction']=_0x388b3f,_0x582a9f['deleteAction']=_0x423bee,_0x582a9f[_0x17cf5b('0xee3')]=_0x2f42f7,_0x582a9f[_0x17cf5b('0x21e0')]=_0x1bfe2d,_0x582a9f[_0x17cf5b('0x21cb')]=_0xfc8715,_0x582a9f['onActionSelection']=_0x3f3952,_0x582a9f[_0x17cf5b('0x172')]=_0x41fa56,_0x582a9f[_0x17cf5b('0xd37')]=_0x363649,_0x582a9f[_0x17cf5b('0x26e1')]=_0x1ed50c,_0x582a9f[_0x17cf5b('0x27e9')]=_0xaaeef,_0x582a9f['onIntegrationAccountSelection']=_0x281d05,_0x582a9f[_0x17cf5b('0x24a0')]=_0x3bb322;function _0x2f42f7(){const _0xd97cf9=_0x17cf5b;_0x5207ef[_0xd97cf9('0x128b')](_0xd97cf9('0x897'))[_0xd97cf9('0x1166')](function(_0x873166){const _0x26ae42=_0xd97cf9;_0x582a9f[_0x26ae42('0x2a0')]=_0x873166;})['catch'](function(_0x143e58){const _0x165b76=_0xd97cf9;_0x125221[_0x165b76('0xfc9')]({'title':_0x143e58[_0x165b76('0x52d')]?_0x165b76('0x1e21')+_0x143e58[_0x165b76('0x52d')]+_0x165b76('0x11e1')+_0x143e58[_0x165b76('0xe1b')]:_0x165b76('0x1a0f'),'msg':_0x143e58[_0x165b76('0x25f4')]?JSON[_0x165b76('0xbac')](_0x143e58['data']):_0x143e58[_0x165b76('0x1586')]()});});if(_0x582a9f[_0xd97cf9('0x79f')][_0xd97cf9('0x79f')])_0x3d14c5();}function _0x1bfe2d(){const _0x38de1e=_0x17cf5b,_0x36fdc3=[0x515,0x516,0x517,0x519,0x51a,0x51b,0x51c,0x51d,0x51e,0x51f];_0x5207ef[_0x38de1e('0x1f94')](_0x36fdc3)[_0x38de1e('0x1166')](function(_0x199334){const _0x2a12c5=_0x38de1e;_0x582a9f[_0x2a12c5('0x25c2')]=_0x2cfb05()[_0x2a12c5('0xcc3')](_0x582a9f['hasSectionPermissions'],_0x199334);})[_0x38de1e('0x1a80')](function(_0x2ad0d1){const _0x5b45c3=_0x38de1e;_0x125221[_0x5b45c3('0xfc9')]({'title':_0x2ad0d1[_0x5b45c3('0x52d')]?_0x5b45c3('0x1e21')+_0x2ad0d1['status']+_0x5b45c3('0x11e1')+_0x2ad0d1[_0x5b45c3('0xe1b')]:_0x5b45c3('0x25ed'),'msg':_0x2ad0d1[_0x5b45c3('0x25f4')]?JSON[_0x5b45c3('0xbac')](_0x2ad0d1[_0x5b45c3('0x25f4')]):_0x2ad0d1[_0x5b45c3('0x1586')]()});});}function _0xfc8715(){const _0x564639=_0x17cf5b;if(!_0x582a9f[_0x564639('0x1276')])_0x111a60();}function _0x3508da(){const _0x3fca8d=_0x17cf5b;_0x5207ef[_0x3fca8d('0xe0f')]()?_0x1ceb0b[_0x3fca8d('0xdd9')][_0x3fca8d('0xd83')]({'fields':'id,name','sort':_0x3fca8d('0x4f0'),'nolimit':_0x3fca8d('0xf3b')})[_0x3fca8d('0xa44')]['then'](function(_0x53eaff){const _0x440cd6=_0x3fca8d;_0x582a9f['lists']=_0x53eaff[_0x440cd6('0x269a')]||[];})[_0x3fca8d('0x1a80')](function(_0x3e2d65){const _0x1abe40=_0x3fca8d;_0x125221['error']({'title':_0x3e2d65[_0x1abe40('0x52d')]?_0x1abe40('0x1e21')+_0x3e2d65[_0x1abe40('0x52d')]+'\x20-\x20'+_0x3e2d65[_0x1abe40('0xe1b')]:_0x1abe40('0x520'),'msg':_0x3e2d65[_0x1abe40('0x25f4')]?JSON[_0x1abe40('0xbac')](_0x3e2d65['data']):_0x3e2d65[_0x1abe40('0x1586')]()});}):_0x1ceb0b[_0x3fca8d('0xdd9')][_0x3fca8d('0xd83')]({'fields':_0x3fca8d('0x1776'),'sort':_0x3fca8d('0x4f0'),'nolimit':_0x3fca8d('0xf3b')})[_0x3fca8d('0xa44')][_0x3fca8d('0x1166')](function(_0xf3ef32){const _0x3c38fa=_0x3fca8d;_0x582a9f[_0x3c38fa('0x8de')]=_0xf3ef32['rows']||[];})[_0x3fca8d('0x1166')](function(){const _0x423fdc=_0x3fca8d;return _0x1ceb0b[_0x423fdc('0x17aa')][_0x423fdc('0xd83')]({'userProfileId':_0x582a9f['currentUser'][_0x423fdc('0xb86')],'sectionId':0x12d})[_0x423fdc('0xa44')];})[_0x3fca8d('0x1166')](function(_0x5e9f9b){const _0xd15471=_0x3fca8d,_0x4dcc0e=_0x5e9f9b&&_0x5e9f9b[_0xd15471('0x269a')]?_0x5e9f9b['rows'][0x0]:null;if(!_0x4dcc0e){const _0x2835c8=[],_0x4c4a5b=[];_0x582a9f['triggerActions']['rows'][_0xd15471('0x2782')](function(_0x4d9f6e){const _0x1b7df4=_0xd15471;if(_0x4d9f6e[_0x1b7df4('0x79f')]===_0x1b7df4('0xaa8')){const _0x2e9a8d=_0x2cfb05()[_0x1b7df4('0xc38')](_0x582a9f[_0x1b7df4('0x8de')],{'id':Number(_0x4d9f6e['data1'])});_0x4c4a5b[_0x1b7df4('0x1514')](_0x2e9a8d);}});for(let _0x40f966=0x0;_0x40f966<_0x582a9f[_0xd15471('0x8de')]['length'];_0x40f966++){const _0x5d0a0c=_0x2cfb05()[_0xd15471('0x1798')](_0x4c4a5b,{'id':_0x582a9f[_0xd15471('0x8de')][_0x40f966]['id']});_0x5d0a0c&&(_0x582a9f[_0xd15471('0x8de')][_0x40f966]['canSelect']=![],_0x2835c8[_0xd15471('0x1514')](_0x582a9f[_0xd15471('0x8de')][_0x40f966]));}_0x582a9f[_0xd15471('0x8de')]=_0x2835c8;}else{if(!_0x4dcc0e['autoAssociation'])return _0x1ceb0b[_0xd15471('0x4b5')][_0xd15471('0xd83')]({'sectionId':_0x4dcc0e['id']})[_0xd15471('0xa44')][_0xd15471('0x1166')](function(_0x58251a){const _0x481ae2=_0xd15471,_0x2713b2=_0x2cfb05()[_0x481ae2('0x2563')](_0x58251a[_0x481ae2('0x269a')],function(_0x596076){const _0x5ea151=_0x481ae2;return _0x2cfb05()[_0x5ea151('0xc38')](_0x582a9f['lists'],{'id':_0x596076['resourceId']});});let _0x5f8749=null;_0x5f8749=[],_0x582a9f[_0x481ae2('0xbb2')]['rows'][_0x481ae2('0x2782')](function(_0x4e862d){const _0x593863=_0x481ae2;if(_0x4e862d[_0x593863('0x79f')]===_0x593863('0xaa8')){const _0x22dcad=_0x2cfb05()[_0x593863('0xc38')](_0x582a9f['lists'],{'id':Number(_0x4e862d[_0x593863('0x1819')])});_0x5f8749[_0x593863('0x1514')](_0x22dcad);}}),!_0x2cfb05()[_0x481ae2('0x1081')](_0x5f8749)&&_0x5f8749[_0x481ae2('0x2782')](function(_0x1c83e4){const _0x313c8d=_0x481ae2;if(!_0x2cfb05()[_0x313c8d('0x1798')](_0x2713b2,['id',_0x1c83e4['id']])){const _0xa43abb=_0x2cfb05()['find'](_0x582a9f[_0x313c8d('0x8de')],{'id':_0x1c83e4['id']});_0xa43abb[_0x313c8d('0x2378')]=![],_0x2713b2['push'](_0xa43abb);}}),_0x582a9f[_0x481ae2('0x8de')]=_0x2713b2;});}})[_0x3fca8d('0x1a80')](function(_0xc39c66){const _0x14bdea=_0x3fca8d;_0x125221[_0x14bdea('0xfc9')]({'title':_0xc39c66[_0x14bdea('0x52d')]?_0x14bdea('0x1e21')+_0xc39c66[_0x14bdea('0x52d')]+_0x14bdea('0x11e1')+_0xc39c66[_0x14bdea('0xe1b')]:_0x14bdea('0x1248'),'msg':_0xc39c66[_0x14bdea('0x25f4')]?JSON[_0x14bdea('0xbac')](_0xc39c66[_0x14bdea('0x25f4')]):_0xc39c66[_0x14bdea('0x1586')]()});});}function _0x51c0c8(){const _0x452d8d=_0x17cf5b;_0x1ceb0b[_0x452d8d('0x149e')]['describe']({})[_0x452d8d('0xa44')][_0x452d8d('0x1166')](function(_0xb8d2ed){const _0x3c61aa=_0x452d8d;_0x582a9f['contactFields']=[],_0x582a9f[_0x3c61aa('0x23d7')]=[];const _0x223ce3=_0x2cfb05()[_0x3c61aa('0x1ac1')](_0xb8d2ed['toJSON']());for(let _0x1775a3=0x0;_0x1775a3<_0x223ce3[_0x3c61aa('0x264b')];_0x1775a3++){if(_0x2cfb05()[_0x3c61aa('0x1257')](_0x582a9f['allowedStandardFields'],_0x223ce3[_0x1775a3][_0x3c61aa('0x24b3')]))_0x582a9f[_0x3c61aa('0x147')][_0x3c61aa('0x1514')](_0x223ce3[_0x1775a3]);else{if(_0x2cfb05()[_0x3c61aa('0x1783')](_0x223ce3[_0x1775a3][_0x3c61aa('0x24b3')],'cf_')){if(_0x223ce3[_0x1775a3][_0x3c61aa('0x2853')][_0x3c61aa('0x1345')]===_0x3c61aa('0x1640'))_0x582a9f[_0x3c61aa('0x23d7')][_0x3c61aa('0x1514')](_0x223ce3[_0x1775a3]);}}}})['catch'](function(_0x175b07){const _0x47cfb0=_0x452d8d;_0x125221[_0x47cfb0('0xfc9')]({'title':_0x175b07[_0x47cfb0('0x52d')]?_0x47cfb0('0x1e21')+_0x175b07[_0x47cfb0('0x52d')]+_0x47cfb0('0x11e1')+_0x175b07['statusText']:_0x47cfb0('0x1479'),'msg':_0x175b07[_0x47cfb0('0x25f4')]?JSON[_0x47cfb0('0xbac')](_0x175b07[_0x47cfb0('0x25f4')]):_0x175b07[_0x47cfb0('0x1586')]()});});}function _0x111a60(){const _0x1a7d4c=_0x17cf5b;_0x1ceb0b[_0x1a7d4c('0xdd9')][_0x1a7d4c('0x1bb')]({'id':_0x582a9f[_0x1a7d4c('0x79f')]['data1'],'ListId':_0x582a9f[_0x1a7d4c('0x79f')]['data1']})[_0x1a7d4c('0xa44')][_0x1a7d4c('0x1166')](function(_0x3e46ab){const _0x5685e6=_0x1a7d4c;_0x582a9f['listFields']=_0x2cfb05()['filter'](_0x3e46ab[_0x5685e6('0x269a')],[_0x5685e6('0x1345'),_0x5685e6('0x1640')]),_0x582a9f['listFields'][_0x5685e6('0x2782')](function(_0x76b218){const _0x4c5bd4=_0x5685e6;_0x76b218['columnName']=_0x4c5bd4('0x711')+_0x76b218['id'];});})[_0x1a7d4c('0x1a80')](function(_0x563e84){const _0x20d8df=_0x1a7d4c;_0x125221[_0x20d8df('0xfc9')]({'title':_0x563e84[_0x20d8df('0x52d')]?_0x20d8df('0x1e21')+_0x563e84['status']+_0x20d8df('0x11e1')+_0x563e84['statusText']:_0x20d8df('0x27e3'),'msg':_0x563e84['data']?JSON['stringify'](_0x563e84[_0x20d8df('0x25f4')]):_0x563e84['toString']()});});}function _0x18a121(){const _0x3de7ec=_0x17cf5b;_0x5207ef[_0x3de7ec('0xe0f')]()?_0x1ceb0b['jscriptyProject'][_0x3de7ec('0xd83')]({'fields':_0x3de7ec('0x1776'),'sort':_0x3de7ec('0x4f0'),'nolimit':'true'})[_0x3de7ec('0xa44')][_0x3de7ec('0x1166')](function(_0x41b874){const _0x3aee92=_0x3de7ec;_0x582a9f[_0x3aee92('0x149f')]=_0x41b874[_0x3aee92('0x269a')]||[];})[_0x3de7ec('0x1a80')](function(_0x1d3043){const _0x1a8244=_0x3de7ec;_0x125221[_0x1a8244('0xfc9')]({'title':_0x1d3043[_0x1a8244('0x52d')]?_0x1a8244('0x1e21')+_0x1d3043['status']+'\x20-\x20'+_0x1d3043[_0x1a8244('0xe1b')]:_0x1a8244('0x178b'),'msg':_0x1d3043['data']?JSON[_0x1a8244('0xbac')](_0x1d3043['data']):_0x1d3043[_0x1a8244('0x1586')]()});}):_0x1ceb0b[_0x3de7ec('0x129b')][_0x3de7ec('0xd83')]({'fields':_0x3de7ec('0x1776'),'sort':_0x3de7ec('0x4f0'),'nolimit':_0x3de7ec('0xf3b')})[_0x3de7ec('0xa44')]['then'](function(_0x5e7a6f){_0x582a9f['projects']=_0x5e7a6f['rows']||[];})[_0x3de7ec('0x1166')](function(){const _0x1d2497=_0x3de7ec;return _0x1ceb0b[_0x1d2497('0x17aa')][_0x1d2497('0xd83')]({'userProfileId':_0x582a9f[_0x1d2497('0x98')][_0x1d2497('0xb86')],'sectionId':0x6a5})['$promise'];})[_0x3de7ec('0x1166')](function(_0x5ae4ca){const _0x1a278a=_0x3de7ec,_0x58eb23=_0x5ae4ca&&_0x5ae4ca['rows']?_0x5ae4ca[_0x1a278a('0x269a')][0x0]:null;if(!_0x58eb23){const _0x20a1e9=[],_0x217ed0=[];_0x582a9f['triggerActions'][_0x1a278a('0x269a')][_0x1a278a('0x2782')](function(_0x4f6196){const _0x32c1f8=_0x1a278a;if(_0x4f6196[_0x32c1f8('0x79f')]===_0x32c1f8('0x179f')){const _0x25ce80=_0x2cfb05()[_0x32c1f8('0xc38')](_0x582a9f['projects'],{'id':Number(_0x4f6196['data1'])});_0x217ed0['push'](_0x25ce80);}});for(let _0x5adf94=0x0;_0x5adf94<_0x582a9f[_0x1a278a('0x149f')][_0x1a278a('0x264b')];_0x5adf94++){const _0x614840=_0x2cfb05()['some'](_0x217ed0,{'id':_0x582a9f['projects'][_0x5adf94]['id']});_0x614840&&(_0x582a9f['projects'][_0x5adf94][_0x1a278a('0x2378')]=![],_0x20a1e9[_0x1a278a('0x1514')](_0x582a9f[_0x1a278a('0x149f')][_0x5adf94]));}_0x582a9f['projects']=_0x20a1e9;}else{if(!_0x58eb23[_0x1a278a('0x1a2b')])return _0x1ceb0b['userProfileResource'][_0x1a278a('0xd83')]({'sectionId':_0x58eb23['id']})[_0x1a278a('0xa44')][_0x1a278a('0x1166')](function(_0x4f9ef1){const _0x3d78f7=_0x1a278a,_0x50f175=_0x2cfb05()['map'](_0x4f9ef1[_0x3d78f7('0x269a')],function(_0x72a0fd){const _0x2307c4=_0x3d78f7;return _0x2cfb05()[_0x2307c4('0xc38')](_0x582a9f[_0x2307c4('0x149f')],{'id':_0x72a0fd[_0x2307c4('0x24e8')]});});let _0x1450cb=null;_0x1450cb=[],_0x582a9f[_0x3d78f7('0xbb2')]['rows']['forEach'](function(_0x574885){const _0x17eea5=_0x3d78f7;if(_0x574885['action']===_0x17eea5('0x179f')){const _0x599fa3=_0x2cfb05()[_0x17eea5('0xc38')](_0x582a9f['projects'],{'id':Number(_0x574885['data1'])});_0x1450cb[_0x17eea5('0x1514')](_0x599fa3);}}),!_0x2cfb05()[_0x3d78f7('0x1081')](_0x1450cb)&&_0x1450cb[_0x3d78f7('0x2782')](function(_0x1cb681){const _0x3ebd83=_0x3d78f7;if(!_0x2cfb05()['some'](_0x50f175,['id',_0x1cb681['id']])){const _0xcce19=_0x2cfb05()['find'](_0x582a9f[_0x3ebd83('0x149f')],{'id':_0x1cb681['id']});_0xcce19['canSelect']=![],_0x50f175[_0x3ebd83('0x1514')](_0xcce19);}}),_0x582a9f[_0x3d78f7('0x149f')]=_0x50f175;});}})[_0x3de7ec('0x1a80')](function(_0x1ca87f){const _0x4811ed=_0x3de7ec;_0x125221[_0x4811ed('0xfc9')]({'title':_0x1ca87f['status']?_0x4811ed('0x1e21')+_0x1ca87f[_0x4811ed('0x52d')]+_0x4811ed('0x11e1')+_0x1ca87f[_0x4811ed('0xe1b')]:_0x4811ed('0x10f2'),'msg':_0x1ca87f[_0x4811ed('0x25f4')]?JSON[_0x4811ed('0xbac')](_0x1ca87f['data']):_0x1ca87f[_0x4811ed('0x1586')]()});});}function _0xfde4cc(){const _0x1fb931=_0x17cf5b;_0x5207ef[_0x1fb931('0xe0f')]()?_0x1ceb0b[_0x1fb931('0x243')][_0x1fb931('0xd83')]({'fields':_0x1fb931('0x1776'),'sort':'id','nolimit':_0x1fb931('0xf3b')})[_0x1fb931('0xa44')][_0x1fb931('0x1166')](function(_0x2a1df4){const _0x49188c=_0x1fb931;_0x582a9f['templates']=_0x2a1df4[_0x49188c('0x269a')]||[];})[_0x1fb931('0x1a80')](function(_0x4b7e2f){const _0x3f9763=_0x1fb931;_0x125221[_0x3f9763('0xfc9')]({'title':_0x4b7e2f[_0x3f9763('0x52d')]?_0x3f9763('0x1e21')+_0x4b7e2f[_0x3f9763('0x52d')]+_0x3f9763('0x11e1')+_0x4b7e2f[_0x3f9763('0xe1b')]:_0x3f9763('0x1370'),'msg':_0x4b7e2f[_0x3f9763('0x25f4')]?JSON['stringify'](_0x4b7e2f[_0x3f9763('0x25f4')]):_0x4b7e2f[_0x3f9763('0x1586')]()});}):_0x1ceb0b['template'][_0x1fb931('0xd83')]({'fields':_0x1fb931('0x1776'),'sort':'id','nolimit':_0x1fb931('0xf3b')})[_0x1fb931('0xa44')][_0x1fb931('0x1166')](function(_0x3dac5e){const _0x2a4e4d=_0x1fb931;_0x582a9f[_0x2a4e4d('0x12d0')]=_0x3dac5e[_0x2a4e4d('0x269a')]||[];})['then'](function(){const _0x332b2f=_0x1fb931;return _0x1ceb0b['userProfileSection'][_0x332b2f('0xd83')]({'userProfileId':_0x582a9f[_0x332b2f('0x98')][_0x332b2f('0xb86')],'sectionId':0x3f1})[_0x332b2f('0xa44')];})[_0x1fb931('0x1166')](function(_0x28de7c){const _0x3a8c0d=_0x1fb931,_0x460b0d=_0x28de7c&&_0x28de7c[_0x3a8c0d('0x269a')]?_0x28de7c[_0x3a8c0d('0x269a')][0x0]:null;if(!_0x460b0d){const _0x364650=[],_0x273b47=[];_0x582a9f['triggerActions']['rows'][_0x3a8c0d('0x2782')](function(_0x1dbf57){const _0x33afd7=_0x3a8c0d;if(_0x2cfb05()[_0x33afd7('0x1257')](['motionbar',_0x33afd7('0x2f0')],_0x1dbf57[_0x33afd7('0x79f')])){const _0x30fe88=_0x2cfb05()['find'](_0x582a9f[_0x33afd7('0x12d0')],{'id':Number(_0x1dbf57['data2'])});_0x273b47['push'](_0x30fe88);}});for(let _0x2bc1b3=0x0;_0x2bc1b3<_0x582a9f[_0x3a8c0d('0x12d0')][_0x3a8c0d('0x264b')];_0x2bc1b3++){const _0x2bb24c=_0x2cfb05()['some'](_0x273b47,{'id':_0x582a9f[_0x3a8c0d('0x12d0')][_0x2bc1b3]['id']});_0x2bb24c&&(_0x582a9f[_0x3a8c0d('0x12d0')][_0x2bc1b3]['canSelect']=![],_0x364650[_0x3a8c0d('0x1514')](_0x582a9f[_0x3a8c0d('0x12d0')][_0x2bc1b3]));}_0x582a9f[_0x3a8c0d('0x12d0')]=_0x364650;}else{if(!_0x460b0d[_0x3a8c0d('0x1a2b')])return _0x1ceb0b[_0x3a8c0d('0x4b5')][_0x3a8c0d('0xd83')]({'sectionId':_0x460b0d['id']})['$promise']['then'](function(_0x4e3586){const _0x478727=_0x3a8c0d,_0x2a34a3=_0x2cfb05()[_0x478727('0x2563')](_0x4e3586[_0x478727('0x269a')],function(_0x3d4cd1){const _0x4f30ae=_0x478727;return _0x2cfb05()[_0x4f30ae('0xc38')](_0x582a9f[_0x4f30ae('0x12d0')],{'id':_0x3d4cd1[_0x4f30ae('0x24e8')]});});let _0x18c8bf=null;_0x18c8bf=[],_0x582a9f['triggerActions'][_0x478727('0x269a')][_0x478727('0x2782')](function(_0xdc230b){const _0x10da0d=_0x478727;if(_0x2cfb05()[_0x10da0d('0x1257')](['motionbar',_0x10da0d('0x2f0')],_0xdc230b[_0x10da0d('0x79f')])){const _0x38825f=_0x2cfb05()[_0x10da0d('0xc38')](_0x582a9f[_0x10da0d('0x12d0')],{'id':Number(_0xdc230b[_0x10da0d('0x17ca')])});_0x18c8bf[_0x10da0d('0x1514')](_0x38825f);}}),!_0x2cfb05()['isEmpty'](_0x18c8bf)&&_0x18c8bf[_0x478727('0x2782')](function(_0x271fdf){const _0x50dc67=_0x478727;if(!_0x2cfb05()['some'](_0x2a34a3,['id',_0x271fdf['id']])){const _0x130611=_0x2cfb05()[_0x50dc67('0xc38')](_0x582a9f[_0x50dc67('0x12d0')],{'id':_0x271fdf['id']});_0x130611[_0x50dc67('0x2378')]=![],_0x2a34a3['push'](_0x130611);}}),_0x582a9f[_0x478727('0x12d0')]=_0x2a34a3;});}})[_0x1fb931('0x1a80')](function(_0x2fd6e5){const _0x131dd1=_0x1fb931;_0x125221[_0x131dd1('0xfc9')]({'title':_0x2fd6e5[_0x131dd1('0x52d')]?_0x131dd1('0x1e21')+_0x2fd6e5[_0x131dd1('0x52d')]+'\x20-\x20'+_0x2fd6e5['statusText']:'SYSTEM:GET_TEMPLATES','msg':_0x2fd6e5[_0x131dd1('0x25f4')]?JSON[_0x131dd1('0xbac')](_0x2fd6e5[_0x131dd1('0x25f4')]):_0x2fd6e5[_0x131dd1('0x1586')]()});});}function _0x458b37(){const _0x3f2d39=_0x17cf5b;switch(_0x582a9f[_0x3f2d39('0x79f')][_0x3f2d39('0x1819')]){case _0x3f2d39('0x174f'):return _0x582a9f['hasSectionPermissions'][0x515];case _0x3f2d39('0x65c'):return _0x582a9f[_0x3f2d39('0x25c2')][0x516];case'sugarcrm':return _0x582a9f['hasSectionPermissions'][0x519];case'freshdesk':return _0x582a9f['hasSectionPermissions'][0x517];case _0x3f2d39('0x1871'):return _0x582a9f[_0x3f2d39('0x25c2')][0x51a];case'zoho':return _0x582a9f['hasSectionPermissions'][0x51b];case _0x3f2d39('0x2055'):return _0x582a9f[_0x3f2d39('0x25c2')][0x51c];case _0x3f2d39('0x773'):return _0x582a9f[_0x3f2d39('0x25c2')][0x51d];case _0x3f2d39('0xc8f'):return _0x582a9f[_0x3f2d39('0x25c2')][0x51e];case _0x3f2d39('0x9bc'):return _0x582a9f['hasSectionPermissions'][0x51f];}}function _0xe12b2f(){const _0xc3c67c=_0x17cf5b;_0x582a9f[_0xc3c67c('0x79f')][_0xc3c67c('0x1819')]=undefined,_0x582a9f[_0xc3c67c('0x79f')][_0xc3c67c('0x17ca')]=undefined,_0x582a9f[_0xc3c67c('0x79f')][_0xc3c67c('0x24fb')]=undefined,_0x582a9f['action'][_0xc3c67c('0x1bef')]=undefined,_0x582a9f[_0xc3c67c('0x79f')][_0xc3c67c('0xaa3')]=_0x582a9f[_0xc3c67c('0x79f')][_0xc3c67c('0x79f')]===_0xc3c67c('0x1cef')?0x5:undefined;}function _0x3d14c5(){const _0x5b4cb0=_0x17cf5b;switch(_0x582a9f[_0x5b4cb0('0x79f')][_0x5b4cb0('0x79f')]){case'contactManager':if(!_0x582a9f['lists'])_0x3508da();if(!_0x582a9f[_0x5b4cb0('0x147')])_0x51c0c8();_0x582a9f[_0x5b4cb0('0x79f')][_0x5b4cb0('0x24fb')]=_0x582a9f[_0x5b4cb0('0x79f')][_0x5b4cb0('0x24fb')]?_0x582a9f[_0x5b4cb0('0x79f')][_0x5b4cb0('0x24fb')][_0x5b4cb0('0x25c8')](','):[_0x5b4cb0('0x2026')];if(_0x582a9f['action']['data2']==='1'&&!_0x582a9f[_0x5b4cb0('0x79f')][_0x5b4cb0('0x1bef')])_0x582a9f[_0x5b4cb0('0x79f')][_0x5b4cb0('0x1bef')]=_0x5b4cb0('0x2026');break;case _0x5b4cb0('0x179f'):if(!_0x582a9f[_0x5b4cb0('0x149f')])_0x18a121();break;case _0x5b4cb0('0x1cef'):if(!_0x582a9f['action'][_0x5b4cb0('0xaa3')])_0x582a9f[_0x5b4cb0('0x79f')]['data5']=0x5;break;}}function _0x3f3952(){_0xe12b2f(),_0x3d14c5();}function _0x41fa56(){const _0x1aed35=_0x17cf5b;_0x582a9f['action'][_0x1aed35('0x17ca')]=undefined,_0x582a9f['action']['data3']=undefined,_0x582a9f['action'][_0x1aed35('0x20a4')]=_0x582a9f[_0x1aed35('0x1276')]?![]:!_0x458b37();const _0x4e4762=_0x1aed35('0x15eb')+_0x2cfb05()[_0x1aed35('0x92c')](_0x582a9f[_0x1aed35('0x79f')][_0x1aed35('0x1819')])+'Account';_0x1ceb0b[_0x4e4762]['get']({'fields':_0x1aed35('0x1776'),'sort':'id','nolimit':_0x1aed35('0xf3b')})['$promise'][_0x1aed35('0x1166')](function(_0x3e3ee0){const _0x2f453a=_0x1aed35;_0x582a9f['accounts']=_0x3e3ee0[_0x2f453a('0x269a')]||[];})[_0x1aed35('0x1a80')](function(_0xc9dfbc){const _0x160729=_0x1aed35;_0x125221[_0x160729('0xfc9')]({'title':_0xc9dfbc[_0x160729('0x52d')]?_0x160729('0x1e21')+_0xc9dfbc[_0x160729('0x52d')]+_0x160729('0x11e1')+_0xc9dfbc[_0x160729('0xe1b')]:_0x160729('0xfae')+_0x582a9f[_0x160729('0x79f')]['data1']['toUpperCase']()+_0x160729('0x204d'),'msg':_0xc9dfbc[_0x160729('0x25f4')]?JSON[_0x160729('0xbac')](_0xc9dfbc[_0x160729('0x25f4')]):_0xc9dfbc[_0x160729('0x1586')]()});});}function _0x363649(){_0x111a60();}function _0x1ed50c(){const _0x437520=_0x17cf5b;if(_0x582a9f['action'][_0x437520('0x1819')]==='0'&&!_0x582a9f[_0x437520('0x12d0')])_0xfde4cc();}function _0xaaeef(){const _0x544d8a=_0x17cf5b;if(_0x582a9f['action']['data2']==='0')_0x582a9f[_0x544d8a('0x79f')][_0x544d8a('0x1bef')]=undefined;if(!_0x582a9f[_0x544d8a('0x79f')]['data4']&&_0x582a9f['action'][_0x544d8a('0x17ca')]==='1')_0x582a9f['action'][_0x544d8a('0x1bef')]=_0x544d8a('0x2026');}function _0x281d05(){const _0x3b3aeb=_0x17cf5b;_0x582a9f['action'][_0x3b3aeb('0x24fb')]=undefined;const _0x270872=_0x3b3aeb('0x15eb')+_0x2cfb05()[_0x3b3aeb('0x92c')](_0x582a9f['action']['data1'])+_0x3b3aeb('0x1a0c');_0x1ceb0b[_0x270872][_0x3b3aeb('0xd83')]({'fields':_0x3b3aeb('0x9d9'),'sort':'id','nolimit':_0x3b3aeb('0xf3b')})[_0x3b3aeb('0xa44')][_0x3b3aeb('0x1166')](function(_0x233270){const _0x3408ac=_0x3b3aeb;_0x582a9f[_0x3408ac('0xd54')]=_0x233270[_0x3408ac('0x269a')]||[];})[_0x3b3aeb('0x1a80')](function(_0x244fe3){const _0x282d27=_0x3b3aeb;_0x125221[_0x282d27('0xfc9')]({'title':_0x244fe3[_0x282d27('0x52d')]?_0x282d27('0x1e21')+_0x244fe3[_0x282d27('0x52d')]+'\x20-\x20'+_0x244fe3['statusText']:_0x282d27('0xfae')+_0x582a9f[_0x282d27('0x79f')][_0x282d27('0x1819')]['toUpperCase']()+'CONFIGURATIONS','msg':_0x244fe3[_0x282d27('0x25f4')]?JSON[_0x282d27('0xbac')](_0x244fe3['data']):_0x244fe3[_0x282d27('0x1586')]()});});}function _0x416606(){const _0x1e7db7=_0x17cf5b,_0x5f3d7a=angular[_0x1e7db7('0x225f')](_0x582a9f[_0x1e7db7('0x79f')]);if(_0x2cfb05()['isArray'](_0x5f3d7a[_0x1e7db7('0x24fb')]))_0x5f3d7a[_0x1e7db7('0x24fb')]=_0x582a9f[_0x1e7db7('0x79f')]['data3'][_0x1e7db7('0x45a')](',');return _0x5f3d7a;}function _0x25806f(){const _0x214f44=_0x17cf5b;_0x582a9f[_0x214f44('0x61a')]=[];const _0x3e84c3=_0x416606();_0x1ceb0b[_0x214f44('0xe00')][_0x214f44('0xce')]({'id':_0x265e41[_0x214f44('0x23f')]['id']},_0x3e84c3)[_0x214f44('0xa44')][_0x214f44('0x1166')](function(_0x1d837f){const _0x9ac738=_0x214f44;_0x582a9f[_0x9ac738('0x18e7')]['unshift'](_0x1d837f['toJSON']()),_0x125221[_0x9ac738('0x103b')]({'title':_0x337ccc[_0x9ac738('0x25cc')](_0x9ac738('0x1cb8'))}),_0x3bb322(_0x582a9f[_0x9ac738('0x18e7')]);})[_0x214f44('0x1a80')](function(_0x3bc0ac){const _0x5c33e1=_0x214f44;if(_0x3bc0ac[_0x5c33e1('0x25f4')]&&_0x3bc0ac[_0x5c33e1('0x25f4')][_0x5c33e1('0x61a')]&&_0x3bc0ac[_0x5c33e1('0x25f4')][_0x5c33e1('0x61a')]['length']){_0x582a9f[_0x5c33e1('0x61a')]=_0x3bc0ac[_0x5c33e1('0x25f4')][_0x5c33e1('0x61a')]||[{'message':_0x3bc0ac[_0x5c33e1('0x1586')](),'type':_0x5c33e1('0x2843')}];for(let _0x5ddf58=0x0;_0x5ddf58<_0x3bc0ac[_0x5c33e1('0x25f4')][_0x5c33e1('0x61a')]['length'];_0x5ddf58+=0x1){_0x125221[_0x5c33e1('0xfc9')]({'title':_0x3bc0ac[_0x5c33e1('0x25f4')]['errors'][_0x5ddf58][_0x5c33e1('0x1345')],'msg':_0x3bc0ac[_0x5c33e1('0x25f4')][_0x5c33e1('0x61a')][_0x5ddf58][_0x5c33e1('0x1e70')]});}}else _0x125221[_0x5c33e1('0xfc9')]({'title':_0x3bc0ac[_0x5c33e1('0x52d')]?_0x5c33e1('0x1e21')+_0x3bc0ac[_0x5c33e1('0x52d')]+_0x5c33e1('0x11e1')+_0x3bc0ac[_0x5c33e1('0xe1b')]:_0x5c33e1('0x2843'),'msg':_0x3bc0ac['data']?JSON[_0x5c33e1('0xbac')](_0x3bc0ac[_0x5c33e1('0x25f4')][_0x5c33e1('0x1e70')]):_0x3bc0ac[_0x5c33e1('0x1586')]()});});}function _0x388b3f(){const _0x481480=_0x17cf5b;_0x582a9f[_0x481480('0x61a')]=[];const _0x25c909=_0x416606();_0x1ceb0b['action']['update']({'id':_0x25c909['id']},_0x25c909)[_0x481480('0xa44')][_0x481480('0x1166')](function(){const _0x50ef4f=_0x481480;_0x582a9f[_0x50ef4f('0x18e7')]=_0x2cfb05()[_0x50ef4f('0x2563')](_0x582a9f[_0x50ef4f('0x18e7')],function(_0xf35808){if(_0xf35808['id']===_0x25c909['id'])return _0x25c909;else return _0xf35808;}),_0x125221[_0x50ef4f('0x103b')]({'title':_0x337ccc[_0x50ef4f('0x25cc')](_0x50ef4f('0x1151'))}),_0x3bb322(_0x582a9f['actions']);})[_0x481480('0x1a80')](function(_0x726d4c){const _0x514950=_0x481480;if(_0x726d4c['data']&&_0x726d4c[_0x514950('0x25f4')][_0x514950('0x61a')]&&_0x726d4c[_0x514950('0x25f4')][_0x514950('0x61a')][_0x514950('0x264b')]){_0x582a9f[_0x514950('0x61a')]=_0x726d4c[_0x514950('0x25f4')][_0x514950('0x61a')]||[{'message':_0x726d4c['toString'](),'type':_0x514950('0x608')}];for(let _0x5d6370=0x0;_0x5d6370<_0x726d4c[_0x514950('0x25f4')][_0x514950('0x61a')][_0x514950('0x264b')];_0x5d6370++){_0x125221[_0x514950('0xfc9')]({'title':_0x726d4c[_0x514950('0x25f4')]['errors'][_0x5d6370][_0x514950('0x1345')],'msg':_0x726d4c[_0x514950('0x25f4')][_0x514950('0x61a')][_0x5d6370][_0x514950('0x1e70')]});}}else _0x125221[_0x514950('0xfc9')]({'title':_0x726d4c[_0x514950('0x52d')]?_0x514950('0x1e21')+_0x726d4c['status']+_0x514950('0x11e1')+_0x726d4c[_0x514950('0xe1b')]:_0x514950('0x608'),'msg':_0x726d4c[_0x514950('0x25f4')]?JSON[_0x514950('0xbac')](_0x726d4c[_0x514950('0x25f4')][_0x514950('0x1e70')]):_0x726d4c[_0x514950('0x1586')]()});});}function _0x423bee(_0x138ab0){const _0x2b5ad1=_0x17cf5b;_0x582a9f[_0x2b5ad1('0x61a')]=[];const _0x23cb59=_0x5ecebb['confirm']({'skipHide':!![]})[_0x2b5ad1('0xcdc')](_0x337ccc['instant'](_0x2b5ad1('0x279f')))['ariaLabel'](_0x2b5ad1('0x1182'))['ok'](_0x337ccc[_0x2b5ad1('0x25cc')](_0x2b5ad1('0xa68')))['cancel'](_0x337ccc['instant'](_0x2b5ad1('0x12a3')))['targetEvent'](_0x138ab0);_0x5ecebb[_0x2b5ad1('0x1f80')](_0x23cb59)[_0x2b5ad1('0x1166')](function(){const _0x283705=_0x2b5ad1;_0x1ceb0b[_0x283705('0x79f')][_0x283705('0x906')]({'id':_0x582a9f[_0x283705('0x79f')]['id']})[_0x283705('0xa44')][_0x283705('0x1166')](function(){const _0x863a1e=_0x283705;_0x582a9f[_0x863a1e('0x18e7')]=_0x2cfb05()[_0x863a1e('0x1c33')](_0x582a9f[_0x863a1e('0x18e7')],function(_0x1a59e7){return _0x1a59e7['id']!==_0x582a9f['action']['id'];}),_0x125221[_0x863a1e('0x103b')]({'title':_0x337ccc[_0x863a1e('0x25cc')](_0x863a1e('0x387'))}),_0x3bb322(_0x582a9f[_0x863a1e('0x18e7')]);})[_0x283705('0x1a80')](function(_0xf9450c){const _0x3cf9b=_0x283705;if(_0xf9450c[_0x3cf9b('0x25f4')]&&_0xf9450c[_0x3cf9b('0x25f4')]['errors']&&_0xf9450c[_0x3cf9b('0x25f4')][_0x3cf9b('0x61a')][_0x3cf9b('0x264b')]){_0x582a9f['errors']=_0xf9450c[_0x3cf9b('0x25f4')][_0x3cf9b('0x61a')]||[{'message':_0xf9450c[_0x3cf9b('0x1586')](),'type':'api.action.delete'}];for(let _0x134bf7=0x0;_0x134bf7<_0xf9450c['data'][_0x3cf9b('0x61a')][_0x3cf9b('0x264b')];_0x134bf7++){_0x125221[_0x3cf9b('0xfc9')]({'title':_0xf9450c[_0x3cf9b('0x25f4')][_0x3cf9b('0x61a')][_0x134bf7]['type'],'msg':_0xf9450c[_0x3cf9b('0x25f4')][_0x3cf9b('0x61a')][_0x134bf7][_0x3cf9b('0x1e70')]});}}else _0x125221['error']({'title':_0xf9450c[_0x3cf9b('0x52d')]?_0x3cf9b('0x1e21')+_0xf9450c[_0x3cf9b('0x52d')]+_0x3cf9b('0x11e1')+_0xf9450c[_0x3cf9b('0xe1b')]:'api.action.delete','msg':_0xf9450c['data']?JSON[_0x3cf9b('0xbac')](_0xf9450c[_0x3cf9b('0x25f4')][_0x3cf9b('0x1e70')]):_0xf9450c[_0x3cf9b('0x1e70')]||_0xf9450c['toString']()});});},function(){});}function _0x3bb322(_0x3e9ba8){const _0x1c108f=_0x17cf5b;_0x5ecebb[_0x1c108f('0x1197')](_0x3e9ba8);}}const _0x24e012=_0x917006,_0x54c655=_0x2734b2['p']+_0x36e6f4('0x2657');_0x57d3c7[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$q','$translate',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'toasty',_0x36e6f4('0x19e3'),'Auth'];function _0x57d3c7(_0x1f6f95,_0x3c5a3d,_0x4530cc,_0x37b659,_0x56730e,_0x1cef0d,_0x411e38,_0x40e087,_0x209c3d){const _0x47eab8=_0x36e6f4,_0x12b0e3=this;_0x12b0e3['currentUser']=_0x209c3d['getCurrentUser'](),_0x12b0e3[_0x47eab8('0xe00')]={},_0x12b0e3['triggerAllConditions']={'count':0x0,'rows':[]},_0x12b0e3[_0x47eab8('0x45f')]=[],_0x12b0e3[_0x47eab8('0x2218')]={'fields':_0x47eab8('0x28dc'),'limit':0xa,'page':0x1},_0x12b0e3['fields']={'queue':'Queue','lastevent':_0x47eab8('0x1d2c'),'routeId':_0x47eab8('0x1aaf'),'agent':_0x47eab8('0x89b'),'account':_0x47eab8('0x1758'),'interaction':_0x47eab8('0x7ee'),'message':_0x47eab8('0x1720')},_0x12b0e3['callStatuses']={'abandoned':_0x47eab8('0x135d'),'timeout':'Timeout','complete':_0x47eab8('0x25af'),'rejected':_0x47eab8('0x242a'),'called':_0x47eab8('0x1a8e'),'connect':'Answer','nosuchnumber':_0x47eab8('0x1dc7'),'busy':'Busy','noanswer':_0x47eab8('0x674'),'congestion':_0x47eab8('0x25ac'),'agentreject':_0x47eab8('0x2877')},_0x12b0e3[_0x47eab8('0x146d')]={'in':_0x47eab8('0x5eb'),'out':_0x47eab8('0x192e'),'accept':_0x47eab8('0x1cf2'),'reject':_0x47eab8('0x1a52')},_0x12b0e3[_0x47eab8('0xae0')]=_0x42117c,_0x12b0e3[_0x47eab8('0x103b')]=_0x23d144,_0x12b0e3['getTriggerAllConditions']=_0x552698,_0x12b0e3[_0x47eab8('0xb3c')]=_0x43334c,_0x12b0e3[_0x47eab8('0x6fe')]=_0xbe4861,_0x12b0e3[_0x47eab8('0x8a2')]=_0x4fb5d2,_0x12b0e3[_0x47eab8('0x1884')]=_0x4c88f0;function _0x42117c(_0x1b9ddc,_0xb63748){const _0xffb54f=_0x47eab8;_0x12b0e3['trigger']=_0x1b9ddc,_0x12b0e3['crudPermissions']=typeof _0xb63748!==_0xffb54f('0x1048')?_0xb63748:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x12b0e3[_0xffb54f('0x2218')][_0xffb54f('0x2501')]=_0x12b0e3[_0xffb54f('0xe00')]['id'],_0x12b0e3[_0xffb54f('0x2218')]['id']=_0x12b0e3[_0xffb54f('0xe00')]['id'],_0x552698();}function _0x5abc1f(){const _0x11540e=_0x47eab8,_0x118737=_0x12b0e3[_0x11540e('0xe00')][_0x11540e('0x1298')],_0x35d4ee=_0x12b0e3[_0x11540e('0xe00')][_0x11540e('0x1298')]+_0x12b0e3['trigger'][_0x11540e('0x1298')]==='chat'?_0x11540e('0x281a'):_0x11540e('0x1288'),_0x17f8cd=_0x12b0e3[_0x11540e('0xe00')][_0x11540e('0x1298')]+(_0x12b0e3[_0x11540e('0xe00')][_0x11540e('0x1298')]===_0x11540e('0xde2')?_0x11540e('0x13b6'):_0x11540e('0x1758'));let _0x21bfc6;switch(_0x12b0e3['trigger']['channel']){case _0x11540e('0xde2'):_0x21bfc6=0x1f6;break;case'fax':_0x21bfc6=0x386;break;case'mail':_0x21bfc6=0x25a;break;case _0x11540e('0x26c'):_0x21bfc6=0x322;break;case'sms':_0x21bfc6=0x2be;break;case _0x11540e('0x116e'):_0x21bfc6=0x836;break;}_0x209c3d[_0x11540e('0xe0f')]()?_0x40e087[_0x17f8cd][_0x11540e('0xd83')]({'fields':_0x11540e('0x1776'),'sort':'id','nolimit':_0x11540e('0xf3b')})[_0x11540e('0xa44')][_0x11540e('0x1166')](function(_0x5dd3ac){const _0x203cf2=_0x11540e;_0x12b0e3[_0x35d4ee]=_0x5dd3ac[_0x203cf2('0x269a')]||[];})['catch'](function(_0x5acc1d){const _0x204dca=_0x11540e;_0x411e38[_0x204dca('0xfc9')]({'title':_0x5acc1d[_0x204dca('0x52d')]?'API:'+_0x5acc1d[_0x204dca('0x52d')]+_0x204dca('0x11e1')+_0x5acc1d['statusText']:_0x204dca('0xfae')+_0x118737[_0x204dca('0x1387')]()+_0x118737==='chat'?_0x204dca('0x14f3'):'ACCOUNTS','msg':_0x5acc1d[_0x204dca('0x25f4')]?JSON[_0x204dca('0xbac')](_0x5acc1d[_0x204dca('0x25f4')]):_0x5acc1d[_0x204dca('0x1586')]()});}):_0x40e087[_0x17f8cd][_0x11540e('0xd83')]({'fields':'id,name','sort':'id','nolimit':_0x11540e('0xf3b')})[_0x11540e('0xa44')][_0x11540e('0x1166')](function(_0x592cad){const _0x814f98=_0x11540e;_0x12b0e3[_0x35d4ee]=_0x592cad[_0x814f98('0x269a')]||[];})[_0x11540e('0x1166')](function(){const _0x522e8d=_0x11540e;return _0x40e087[_0x522e8d('0x17aa')][_0x522e8d('0xd83')]({'userProfileId':_0x12b0e3[_0x522e8d('0x98')][_0x522e8d('0xb86')],'sectionId':_0x21bfc6})['$promise'];})[_0x11540e('0x1166')](function(_0x116dae){const _0x41c05f=_0x11540e,_0x1323ae=_0x116dae&&_0x116dae[_0x41c05f('0x269a')]?_0x116dae[_0x41c05f('0x269a')][0x0]:null;if(!_0x1323ae){const _0x4dc5cc=[],_0x49aee7=[];_0x12b0e3[_0x41c05f('0x25ad')]['rows'][_0x41c05f('0x2782')](function(_0x5056b0){const _0xde36e4=_0x41c05f;if(_0x5056b0[_0xde36e4('0x22f3')]===_0xde36e4('0x1a32')){const _0x57c556=_0x2cfb05()[_0xde36e4('0xc38')](_0x12b0e3[_0x35d4ee],{'id':Number(_0x5056b0[_0xde36e4('0x18e0')])});_0x49aee7[_0xde36e4('0x1514')](_0x57c556);}});for(let _0xee3cc6=0x0;_0xee3cc6<_0x12b0e3[_0x35d4ee][_0x41c05f('0x264b')];_0xee3cc6++){const _0x534e2b=_0x2cfb05()[_0x41c05f('0x1798')](_0x49aee7,{'id':_0x12b0e3[_0x35d4ee][_0xee3cc6]['id']});_0x534e2b&&(_0x12b0e3[_0x35d4ee][_0xee3cc6][_0x41c05f('0x2378')]=![],_0x4dc5cc[_0x41c05f('0x1514')](_0x12b0e3[_0x35d4ee][_0xee3cc6]));}_0x12b0e3[_0x35d4ee]=_0x4dc5cc;}else{if(!_0x1323ae[_0x41c05f('0x1a2b')])return _0x40e087[_0x41c05f('0x4b5')][_0x41c05f('0xd83')]({'sectionId':_0x1323ae['id']})['$promise']['then'](function(_0x2bbd18){const _0x5ac707=_0x41c05f,_0x2dad6e=_0x2cfb05()[_0x5ac707('0x2563')](_0x2bbd18[_0x5ac707('0x269a')],function(_0x42e003){const _0x2a9b28=_0x5ac707;return _0x2cfb05()[_0x2a9b28('0xc38')](_0x12b0e3[_0x35d4ee],{'id':_0x42e003[_0x2a9b28('0x24e8')]});});let _0x133704=null;_0x133704=[],_0x12b0e3[_0x5ac707('0x25ad')][_0x5ac707('0x269a')][_0x5ac707('0x2782')](function(_0x9a352e){const _0x187e6f=_0x5ac707;if(_0x9a352e[_0x187e6f('0x22f3')]===_0x187e6f('0x1a32')){const _0x4ed925=_0x2cfb05()[_0x187e6f('0xc38')](_0x12b0e3[_0x35d4ee],{'id':Number(_0x9a352e[_0x187e6f('0x18e0')])});_0x133704[_0x187e6f('0x1514')](_0x4ed925);}}),!_0x2cfb05()[_0x5ac707('0x1081')](_0x133704)&&_0x133704['forEach'](function(_0x2e3d56){const _0x4a5b68=_0x5ac707;if(!_0x2cfb05()[_0x4a5b68('0x1798')](_0x2dad6e,['id',_0x2e3d56['id']])){const _0x2fb824=_0x2cfb05()[_0x4a5b68('0xc38')](_0x12b0e3[_0x35d4ee],{'id':_0x2e3d56['id']});_0x2fb824[_0x4a5b68('0x2378')]=![],_0x2dad6e[_0x4a5b68('0x1514')](_0x2fb824);}}),_0x12b0e3[_0x35d4ee]=_0x2dad6e;});}})[_0x11540e('0x1a80')](function(_0x483267){const _0x125b82=_0x11540e;_0x411e38[_0x125b82('0xfc9')]({'title':_0x483267[_0x125b82('0x52d')]?_0x125b82('0x1e21')+_0x483267['status']+_0x125b82('0x11e1')+_0x483267[_0x125b82('0xe1b')]:_0x125b82('0xfae')+_0x118737[_0x125b82('0x1387')]()+_0x118737==='chat'?_0x125b82('0x14f3'):_0x125b82('0x204d'),'msg':_0x483267[_0x125b82('0x25f4')]?JSON['stringify'](_0x483267[_0x125b82('0x25f4')]):_0x483267[_0x125b82('0x1586')]()});});}function _0x49fe50(){const _0x81cec6=_0x47eab8,_0x15b13c=[{'id':0x191,'type':_0x81cec6('0x14d8')},{'id':0x5dd,'type':_0x81cec6('0x587')}];let _0x5ce82f=null;_0x209c3d['isAdmin']()?_0x40e087['voiceQueue'][_0x81cec6('0xd83')]({'fields':_0x81cec6('0x1c09'),'sort':'name','nolimit':'true'})[_0x81cec6('0xa44')][_0x81cec6('0x1166')](function(_0x4fabbe){const _0x104cea=_0x81cec6;_0x12b0e3[_0x104cea('0x7a7')]=_0x4fabbe[_0x104cea('0x269a')]||[];})[_0x81cec6('0x1a80')](function(_0x13fd41){const _0x2ab650=_0x81cec6;_0x411e38[_0x2ab650('0xfc9')]({'title':_0x13fd41[_0x2ab650('0x52d')]?'API:'+_0x13fd41[_0x2ab650('0x52d')]+_0x2ab650('0x11e1')+_0x13fd41['statusText']:_0x2ab650('0x250e'),'msg':_0x13fd41[_0x2ab650('0x25f4')]?JSON[_0x2ab650('0xbac')](_0x13fd41[_0x2ab650('0x25f4')]):_0x13fd41[_0x2ab650('0x1586')]()});}):_0x40e087[_0x81cec6('0x1943')][_0x81cec6('0xd83')]({'fields':_0x81cec6('0x1c09'),'sort':'name','nolimit':_0x81cec6('0xf3b')})['$promise'][_0x81cec6('0x1166')](function(_0x3d21dc){const _0x4f312c=_0x81cec6;_0x5ce82f=_0x3d21dc[_0x4f312c('0x269a')]||[];})['then'](function(){const _0x3397e1=_0x81cec6,_0x46305f=[];for(let _0x3abee7=0x0;_0x3abee7<_0x15b13c[_0x3397e1('0x264b')];_0x3abee7++){_0x46305f[_0x3397e1('0x1514')](_0x40e087[_0x3397e1('0x17aa')][_0x3397e1('0xd83')]({'userProfileId':_0x12b0e3[_0x3397e1('0x98')]['userProfileId'],'sectionId':_0x15b13c[_0x3abee7]['id']})[_0x3397e1('0xa44')]);}return _0x3c5a3d[_0x3397e1('0x2760')](_0x46305f);})[_0x81cec6('0x1166')](function(_0x5c7bdc){const _0x19cf54=_0x81cec6,_0xd1c082=_0x2cfb05()[_0x19cf54('0x2563')](_0x5c7bdc,function(_0x1699cc){return _0x1699cc&&_0x1699cc['rows']?_0x1699cc['rows'][0x0]:null;}),_0x40e7ca=[];for(let _0x1970f3=0x0;_0x1970f3<_0x15b13c['length'];_0x1970f3++){const _0x1a6ae4=_0x2cfb05()[_0x19cf54('0xc38')](_0xd1c082,[_0x19cf54('0x120e'),_0x15b13c[_0x1970f3]['id']]);if(_0x1a6ae4){if(!_0x1a6ae4[_0x19cf54('0x1a2b')])_0x40e7ca[_0x19cf54('0x1514')](_0x40e087['userProfileResource'][_0x19cf54('0xd83')]({'sectionId':_0x1a6ae4['id']})[_0x19cf54('0xa44')]);else{const _0x72f1a1=[];_0x5ce82f['forEach'](function(_0x1f110a){const _0x5909cb=_0x19cf54;_0x1f110a[_0x5909cb('0x1345')]===_0x15b13c[_0x1970f3][_0x5909cb('0x1345')]&&_0x72f1a1[_0x5909cb('0x1514')](_0x1f110a);}),_0x40e7ca[_0x19cf54('0x1514')]({'rows':_0x72f1a1,'count':_0x72f1a1[_0x19cf54('0x264b')]});}}}return _0x3c5a3d[_0x19cf54('0x2760')](_0x40e7ca);})[_0x81cec6('0x1166')](function(_0x84ab62){const _0x468498=_0x81cec6,_0x51aed6=[],_0x30422f=[];_0x12b0e3[_0x468498('0x25ad')][_0x468498('0x269a')][_0x468498('0x2782')](function(_0xefe038){const _0x4b5b46=_0x468498;if(_0xefe038['field']==='queue'){const _0x5c70af=_0x2cfb05()['find'](_0x5ce82f,{'name':_0xefe038[_0x4b5b46('0x18e0')]});_0x30422f[_0x4b5b46('0x1514')](_0x5c70af);}});for(let _0x47a181=0x0;_0x47a181<_0x84ab62[_0x468498('0x264b')];_0x47a181++){const _0x144131=_0x84ab62[_0x47a181]['rows']||[];_0x144131[_0x468498('0x2782')](function(_0x5bd7af){_0x51aed6['push'](_0x5bd7af);});}!_0x2cfb05()[_0x468498('0x1081')](_0x30422f)&&_0x30422f[_0x468498('0x2782')](function(_0x7fab9f){const _0x342277=_0x468498;if(!_0x2cfb05()[_0x342277('0x1798')](_0x51aed6,[_0x342277('0x24e8'),_0x7fab9f['id']])){const _0x1d6115=_0x2cfb05()[_0x342277('0xc38')](_0x5ce82f,{'id':_0x7fab9f['id']});_0x1d6115[_0x342277('0x2378')]=![],_0x51aed6['push'](_0x1d6115);}}),_0x12b0e3[_0x468498('0x7a7')]=_0x51aed6;})[_0x81cec6('0x1a80')](function(_0x5476c6){const _0x2dd8f1=_0x81cec6;_0x411e38['error']({'title':_0x5476c6[_0x2dd8f1('0x52d')]?_0x2dd8f1('0x1e21')+_0x5476c6[_0x2dd8f1('0x52d')]+_0x2dd8f1('0x11e1')+_0x5476c6['statusText']:_0x2dd8f1('0x2029'),'msg':_0x5476c6[_0x2dd8f1('0x25f4')]?JSON['stringify'](_0x5476c6[_0x2dd8f1('0x25f4')]):_0x5476c6[_0x2dd8f1('0x1586')]()});});}function _0x53e1fb(){const _0x4f19e1=_0x47eab8;_0x209c3d[_0x4f19e1('0xe0f')]()?_0x40e087[_0x4f19e1('0x1deb')][_0x4f19e1('0xd83')]({'fields':_0x4f19e1('0x27bd'),'type':'outbound','VoiceExtensionId':_0x4f19e1('0x15d7'),'nolimit':'true'})[_0x4f19e1('0xa44')][_0x4f19e1('0x1166')](function(_0x3dde05){const _0x55609c=_0x4f19e1;_0x12b0e3[_0x55609c('0x2404')]=_0x3dde05[_0x55609c('0x269a')]||[];})[_0x4f19e1('0x1a80')](function(_0x4b11f5){const _0x3111bb=_0x4f19e1;_0x411e38[_0x3111bb('0xfc9')]({'title':_0x4b11f5['status']?_0x3111bb('0x1e21')+_0x4b11f5['status']+_0x3111bb('0x11e1')+_0x4b11f5[_0x3111bb('0xe1b')]:_0x3111bb('0x261f'),'msg':_0x4b11f5[_0x3111bb('0x25f4')]?JSON[_0x3111bb('0xbac')](_0x4b11f5[_0x3111bb('0x25f4')]):_0x4b11f5[_0x3111bb('0x1586')]()});}):_0x40e087[_0x4f19e1('0x1deb')]['get']({'fields':'id,exten','type':_0x4f19e1('0x587'),'VoiceExtensionId':_0x4f19e1('0x15d7'),'nolimit':_0x4f19e1('0xf3b')})[_0x4f19e1('0xa44')][_0x4f19e1('0x1166')](function(_0x328f49){const _0xbd079=_0x4f19e1;_0x12b0e3[_0xbd079('0x2404')]=_0x328f49[_0xbd079('0x269a')]||[];})[_0x4f19e1('0x1166')](function(){const _0x44a948=_0x4f19e1;return _0x40e087[_0x44a948('0x17aa')][_0x44a948('0xd83')]({'userProfileId':_0x12b0e3[_0x44a948('0x98')][_0x44a948('0xb86')],'sectionId':0x193})[_0x44a948('0xa44')];})[_0x4f19e1('0x1166')](function(_0x317990){const _0x2b1b7f=_0x4f19e1,_0x143d39=_0x317990&&_0x317990[_0x2b1b7f('0x269a')]?_0x317990[_0x2b1b7f('0x269a')][0x0]:null;if(!_0x143d39){const _0x5d6e97=[],_0xb1391f=[];_0x12b0e3['triggerAllConditions']['rows'][_0x2b1b7f('0x2782')](function(_0x5d20f3){const _0x2eeaea=_0x2b1b7f;if(_0x5d20f3[_0x2eeaea('0x22f3')]===_0x2eeaea('0x2423')){const _0x1441b0=_0x2cfb05()[_0x2eeaea('0xc38')](_0x12b0e3['outboundRoutes'],{'id':Number(_0x5d20f3[_0x2eeaea('0x18e0')])});_0xb1391f[_0x2eeaea('0x1514')](_0x1441b0);}});for(let _0x298aec=0x0;_0x298aec<_0x12b0e3[_0x2b1b7f('0x2404')]['length'];_0x298aec++){const _0x3e4b9c=_0x2cfb05()[_0x2b1b7f('0x1798')](_0xb1391f,{'id':_0x12b0e3['outboundRoutes'][_0x298aec]['id']});_0x3e4b9c&&(_0x12b0e3[_0x2b1b7f('0x2404')][_0x298aec]['canSelect']=![],_0x5d6e97[_0x2b1b7f('0x1514')](_0x12b0e3[_0x2b1b7f('0x2404')][_0x298aec]));}_0x12b0e3[_0x2b1b7f('0x2404')]=_0x5d6e97;}else{if(!_0x143d39['autoAssociation'])return _0x40e087[_0x2b1b7f('0x4b5')]['get']({'sectionId':_0x143d39['id']})[_0x2b1b7f('0xa44')][_0x2b1b7f('0x1166')](function(_0x17e309){const _0xfd09f6=_0x2b1b7f,_0x4a2b88=_0x2cfb05()['map'](_0x17e309['rows'],function(_0x28acd4){return _0x2cfb05()['find'](_0x12b0e3['outboundRoutes'],{'id':_0x28acd4['resourceId']});});let _0x2ecbe8=null;_0x2ecbe8=[],_0x12b0e3['triggerAllConditions'][_0xfd09f6('0x269a')][_0xfd09f6('0x2782')](function(_0x39f837){const _0x4fb590=_0xfd09f6;if(_0x39f837['field']===_0x4fb590('0x2423')){const _0x2e5858=_0x2cfb05()[_0x4fb590('0xc38')](_0x12b0e3[_0x4fb590('0x2404')],{'id':Number(_0x39f837[_0x4fb590('0x18e0')])});_0x2ecbe8['push'](_0x2e5858);}}),!_0x2cfb05()[_0xfd09f6('0x1081')](_0x2ecbe8)&&_0x2ecbe8['forEach'](function(_0x2e69de){const _0xbf3319=_0xfd09f6;if(!_0x2cfb05()[_0xbf3319('0x1798')](_0x4a2b88,['id',_0x2e69de['id']])){const _0x4f7906=_0x2cfb05()[_0xbf3319('0xc38')](_0x12b0e3[_0xbf3319('0x2404')],{'id':_0x2e69de['id']});_0x4f7906[_0xbf3319('0x2378')]=![],_0x4a2b88[_0xbf3319('0x1514')](_0x4f7906);}}),_0x12b0e3[_0xfd09f6('0x2404')]=_0x4a2b88;});}})[_0x4f19e1('0x1a80')](function(_0x514cc8){const _0x52301b=_0x4f19e1;_0x411e38['error']({'title':_0x514cc8['status']?_0x52301b('0x1e21')+_0x514cc8['status']+_0x52301b('0x11e1')+_0x514cc8[_0x52301b('0xe1b')]:_0x52301b('0x261f'),'msg':_0x514cc8[_0x52301b('0x25f4')]?JSON['stringify'](_0x514cc8[_0x52301b('0x25f4')]):_0x514cc8[_0x52301b('0x1586')]()});});}function _0x3a580d(){const _0xbba012=_0x47eab8;_0x209c3d['isAdmin']()?_0x40e087[_0xbba012('0x557')][_0xbba012('0xd83')]({'fields':_0xbba012('0xce1'),'sort':_0xbba012('0x4f0'),'role':_0xbba012('0x1eff'),'nolimit':_0xbba012('0xf3b')})[_0xbba012('0xa44')]['then'](function(_0x41bc15){const _0x588488=_0xbba012;_0x12b0e3[_0x588488('0x1f7e')]=_0x41bc15[_0x588488('0x269a')]||[];})[_0xbba012('0x1a80')](function(_0x56d9f4){const _0x5ad7b1=_0xbba012;_0x411e38[_0x5ad7b1('0xfc9')]({'title':_0x56d9f4[_0x5ad7b1('0x52d')]?_0x5ad7b1('0x1e21')+_0x56d9f4[_0x5ad7b1('0x52d')]+_0x5ad7b1('0x11e1')+_0x56d9f4[_0x5ad7b1('0xe1b')]:_0x5ad7b1('0xd4c'),'msg':_0x56d9f4[_0x5ad7b1('0x25f4')]?JSON[_0x5ad7b1('0xbac')](_0x56d9f4[_0x5ad7b1('0x25f4')]):_0x56d9f4[_0x5ad7b1('0x1586')]()});}):_0x40e087['user'][_0xbba012('0xd83')]({'fields':_0xbba012('0xce1'),'sort':_0xbba012('0x4f0'),'role':'agent','nolimit':_0xbba012('0xf3b')})['$promise'][_0xbba012('0x1166')](function(_0x4f5d25){const _0x1951e0=_0xbba012;_0x12b0e3[_0x1951e0('0x1f7e')]=_0x4f5d25[_0x1951e0('0x269a')]||[];})['then'](function(){const _0x32e15e=_0xbba012;return _0x40e087[_0x32e15e('0x17aa')][_0x32e15e('0xd83')]({'userProfileId':_0x12b0e3[_0x32e15e('0x98')][_0x32e15e('0xb86')],'sectionId':0xca})['$promise'];})['then'](function(_0x17d062){const _0x2f262c=_0xbba012,_0x23e4f8=_0x17d062&&_0x17d062[_0x2f262c('0x269a')]?_0x17d062[_0x2f262c('0x269a')][0x0]:null;if(!_0x23e4f8){const _0x48f5ec=[],_0x455726=[];_0x12b0e3[_0x2f262c('0x25ad')][_0x2f262c('0x269a')][_0x2f262c('0x2782')](function(_0x545a7d){const _0x5e5e31=_0x2f262c;if(_0x545a7d['field']===_0x5e5e31('0x1eff')){const _0x357505=_0x2cfb05()[_0x5e5e31('0xc38')](_0x12b0e3[_0x5e5e31('0x1f7e')],{'name':_0x545a7d['value']});_0x455726[_0x5e5e31('0x1514')](_0x357505);}});for(let _0x40fcc7=0x0;_0x40fcc7<_0x12b0e3[_0x2f262c('0x1f7e')]['length'];_0x40fcc7++){const _0x5d25f2=_0x2cfb05()[_0x2f262c('0x1798')](_0x455726,{'id':_0x12b0e3['agents'][_0x40fcc7]['id']});_0x5d25f2&&(_0x12b0e3[_0x2f262c('0x1f7e')][_0x40fcc7][_0x2f262c('0x2378')]=![],_0x48f5ec[_0x2f262c('0x1514')](_0x12b0e3[_0x2f262c('0x1f7e')][_0x40fcc7]));}_0x12b0e3[_0x2f262c('0x1f7e')]=_0x48f5ec;}else{if(!_0x23e4f8[_0x2f262c('0x1a2b')])return _0x40e087[_0x2f262c('0x4b5')][_0x2f262c('0xd83')]({'sectionId':_0x23e4f8['id']})[_0x2f262c('0xa44')][_0x2f262c('0x1166')](function(_0x289689){const _0x330eb8=_0x2f262c,_0x5eb95c=_0x2cfb05()['map'](_0x289689[_0x330eb8('0x269a')],function(_0xfec692){const _0x5bfcad=_0x330eb8;return _0x2cfb05()[_0x5bfcad('0xc38')](_0x12b0e3[_0x5bfcad('0x1f7e')],{'id':_0xfec692[_0x5bfcad('0x24e8')]});});let _0x4c14ca=null;_0x4c14ca=[],_0x12b0e3[_0x330eb8('0x25ad')]['rows'][_0x330eb8('0x2782')](function(_0x190dd8){const _0x259c36=_0x330eb8;if(_0x190dd8[_0x259c36('0x22f3')]===_0x259c36('0x1eff')){const _0x5b7c66=_0x2cfb05()[_0x259c36('0xc38')](_0x12b0e3['agents'],{'name':_0x190dd8[_0x259c36('0x18e0')]});_0x4c14ca[_0x259c36('0x1514')](_0x5b7c66);}}),!_0x2cfb05()[_0x330eb8('0x1081')](_0x4c14ca)&&_0x4c14ca[_0x330eb8('0x2782')](function(_0x437000){const _0x5c1684=_0x330eb8;if(!_0x2cfb05()[_0x5c1684('0x1798')](_0x5eb95c,['id',_0x437000['id']])){const _0x51d5ce=_0x2cfb05()[_0x5c1684('0xc38')](_0x12b0e3['agents'],{'id':_0x437000['id']});_0x51d5ce['canSelect']=![],_0x5eb95c[_0x5c1684('0x1514')](_0x51d5ce);}}),_0x12b0e3[_0x330eb8('0x1f7e')]=_0x5eb95c;});}})[_0xbba012('0x1a80')](function(_0x2483bc){const _0x58002e=_0xbba012;_0x411e38['error']({'title':_0x2483bc[_0x58002e('0x52d')]?_0x58002e('0x1e21')+_0x2483bc[_0x58002e('0x52d')]+'\x20-\x20'+_0x2483bc[_0x58002e('0xe1b')]:_0x58002e('0xd4c'),'msg':_0x2483bc[_0x58002e('0x25f4')]?JSON[_0x58002e('0xbac')](_0x2483bc[_0x58002e('0x25f4')]):_0x2483bc['toString']()});});}function _0x5460a5(){const _0x35d40c=_0x47eab8;if(_0x12b0e3['trigger'][_0x35d40c('0x1298')]==='voice'){if(_0x2cfb05()[_0x35d40c('0x1798')](_0x12b0e3[_0x35d40c('0x25ad')][_0x35d40c('0x269a')],[_0x35d40c('0x22f3'),_0x35d40c('0x1d3e')])){if(!_0x12b0e3[_0x35d40c('0x7a7')])_0x49fe50();}if(_0x2cfb05()[_0x35d40c('0x1798')](_0x12b0e3[_0x35d40c('0x25ad')][_0x35d40c('0x269a')],['field',_0x35d40c('0x2423')])){if(!_0x12b0e3['outboundRoutes'])_0x53e1fb();}if(_0x2cfb05()[_0x35d40c('0x1798')](_0x12b0e3[_0x35d40c('0x25ad')][_0x35d40c('0x269a')],['field',_0x35d40c('0x1eff')])){if(!_0x12b0e3[_0x35d40c('0x1f7e')])_0x3a580d();}}else _0x5abc1f();}function _0x23d144(_0x4f7903){_0x12b0e3['triggerAllConditions']=_0x4f7903||{'count':0x0,'rows':[]},_0x5460a5();}function _0x552698(){const _0x163c33=_0x47eab8;_0x12b0e3[_0x163c33('0x2218')][_0x163c33('0x1098')]=(_0x12b0e3[_0x163c33('0x2218')][_0x163c33('0x1a43')]-0x1)*_0x12b0e3['query'][_0x163c33('0x163f')],_0x12b0e3[_0x163c33('0x1f48')]=_0x40e087[_0x163c33('0xe00')][_0x163c33('0x1584')](_0x12b0e3[_0x163c33('0x2218')],_0x23d144)[_0x163c33('0xa44')];}function _0x43334c(_0xa19b46,_0xa87c86){const _0x155166=_0x47eab8;_0x56730e['show']({'controller':_0x155166('0x1d0a'),'controllerAs':'vm','templateUrl':_0x54c655,'parent':angular[_0x155166('0x1194')](_0x1cef0d['body']),'targetEvent':_0xa19b46,'clickOutsideToClose':!![],'locals':{'trigger':_0x12b0e3[_0x155166('0xe00')],'allCondition':_0xa87c86,'allConditions':_0x12b0e3[_0x155166('0x25ad')][_0x155166('0x269a')],'license':null,'setting':null,'crudPermissions':_0x12b0e3['crudPermissions']}})[_0x155166('0x1166')](function(_0x2a4af6){const _0x1d07c2=_0x155166;_0x2a4af6&&(_0x12b0e3['triggerAllConditions']={'count':_0x2a4af6[_0x1d07c2('0x264b')],'rows':_0x2a4af6},_0x5460a5());});}function _0x4fb5d2(_0x4401a8,_0x511697){const _0x368859=_0x47eab8,_0x54b55d=_0x56730e[_0x368859('0x1d26')]()['title'](_0x4530cc['instant'](_0x368859('0x1ec9')))[_0x368859('0x8e8')](_0x368859('0x13de'))[_0x368859('0x203b')](_0x511697)['ok']('OK')[_0x368859('0x3f')](_0x4530cc[_0x368859('0x25cc')](_0x368859('0x12a3')));_0x56730e['show'](_0x54b55d)[_0x368859('0x1166')](function(){_0x3a80eb(_0x4401a8,!![]);});}function _0x3a80eb(_0x77cd80,_0x31a1de){const _0x4d5b14=_0x47eab8;_0x40e087[_0x4d5b14('0x8ff')]['delete']({'id':_0x77cd80['id']})[_0x4d5b14('0xa44')]['then'](function(){const _0x4a4dc8=_0x4d5b14;_0x552698(),_0x31a1de&&_0x411e38[_0x4a4dc8('0x103b')]({'title':_0x4530cc[_0x4a4dc8('0x25cc')](_0x4a4dc8('0x287a'))});})['catch'](function(_0x23c2b0){const _0x17b58f=_0x4d5b14;if(_0x23c2b0[_0x17b58f('0x25f4')]&&_0x23c2b0['data']['errors']&&_0x23c2b0[_0x17b58f('0x25f4')][_0x17b58f('0x61a')][_0x17b58f('0x264b')]){_0x12b0e3['errors']=_0x23c2b0['data'][_0x17b58f('0x61a')]||[{'message':_0x23c2b0['toString'](),'type':'SYSTEM:GETtrigger'}];for(let _0x4960e7=0x0;_0x4960e7<_0x23c2b0['data'][_0x17b58f('0x61a')]['length'];_0x4960e7++){_0x411e38[_0x17b58f('0xfc9')]({'title':_0x23c2b0[_0x17b58f('0x25f4')]['errors'][_0x4960e7]['type'],'msg':_0x23c2b0['data']['errors'][_0x4960e7][_0x17b58f('0x1e70')]});}}else _0x411e38[_0x17b58f('0xfc9')]({'title':_0x23c2b0[_0x17b58f('0x52d')]?_0x17b58f('0x1e21')+_0x23c2b0[_0x17b58f('0x52d')]+_0x17b58f('0x11e1')+_0x23c2b0[_0x17b58f('0xe1b')]:_0x17b58f('0x22a8'),'msg':_0x23c2b0['data']?JSON[_0x17b58f('0xbac')](_0x23c2b0[_0x17b58f('0x25f4')]['message']):_0x23c2b0[_0x17b58f('0x1e70')]||_0x23c2b0['toString']()});});}function _0xbe4861(){const _0x368aa4=_0x47eab8,_0x52a38e=angular[_0x368aa4('0x225f')](_0x12b0e3[_0x368aa4('0x45f')]);return _0x12b0e3[_0x368aa4('0x45f')]=[],_0x52a38e;}function _0x4c88f0(_0x4fd27f){const _0x3c33b4=_0x47eab8,_0xc10d31=_0x56730e[_0x3c33b4('0x1d26')]()[_0x3c33b4('0xcdc')](_0x4530cc['instant']('TOOLS.NOTIFICATIONS.CONDITIONS_DELETE_TITLE'))['content'](_0x4530cc[_0x3c33b4('0x25cc')](_0x3c33b4('0x1655'),{'total':_0x12b0e3[_0x3c33b4('0x45f')][_0x3c33b4('0x264b')]}))[_0x3c33b4('0x8e8')]('Delete\x20conditions')[_0x3c33b4('0x203b')](_0x4fd27f)['ok']('OK')[_0x3c33b4('0x3f')](_0x4530cc[_0x3c33b4('0x25cc')](_0x3c33b4('0x12a3')));_0x56730e[_0x3c33b4('0x1f80')](_0xc10d31)[_0x3c33b4('0x1166')](function(){const _0x28c22f=_0x3c33b4;_0x12b0e3['selectedTriggerAllConditions'][_0x28c22f('0x2782')](function(_0x1c5c88){_0x3a80eb(_0x1c5c88);}),_0x12b0e3[_0x28c22f('0x45f')]=[],_0x411e38['success']({'title':_0x4530cc[_0x28c22f('0x25cc')](_0x28c22f('0x1687'))});});}let _0x362a1b=!![],_0x425769=0x1;_0x1f6f95[_0x47eab8('0xe83')](_0x47eab8('0x28b4'),function(_0x14e23a,_0x2505df){const _0x437551=_0x47eab8;_0x362a1b?_0x37b659(function(){_0x362a1b=![];}):(!_0x2505df&&(_0x425769=_0x12b0e3[_0x437551('0x2218')][_0x437551('0x1a43')]),_0x14e23a!==_0x2505df&&(_0x12b0e3[_0x437551('0x2218')][_0x437551('0x1a43')]=0x1),!_0x14e23a&&(_0x12b0e3[_0x437551('0x2218')][_0x437551('0x1a43')]=_0x425769),_0x552698());});}const _0x13229a=_0x57d3c7;_0x2c31c4['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x1802'),_0x36e6f4('0x9e2'),_0x36e6f4('0xe00'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x2c31c4(_0x4b2eb1,_0x58df3d,_0x3838e5,_0x92acb7,_0x3ec904,_0x23919a,_0x4e4e01,_0x4122a2,_0x57c06b,_0xdb6a74,_0x23da6b,_0x140f8a,_0x4e3b14,_0xa3a222,_0x14bfb9){const _0x5e8a86=_0x36e6f4,_0x522aa9=this;_0x522aa9[_0x5e8a86('0x98')]=_0x140f8a[_0x5e8a86('0x26cd')](),_0x522aa9[_0x5e8a86('0x61a')]=[],_0x522aa9[_0x5e8a86('0xf8a')]=_0xa3a222,_0x522aa9[_0x5e8a86('0x5c9')]=_0x4e3b14,_0x522aa9[_0x5e8a86('0x243c')]=_0x14bfb9,_0x522aa9[_0x5e8a86('0x128b')]={},_0x522aa9[_0x5e8a86('0x2900')]=_0x522aa9[_0x5e8a86('0xf8a')]&&_0x522aa9['setting'][_0x5e8a86('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x522aa9[_0x5e8a86('0xcdc')]=_0x5e8a86('0xa8b'),_0x522aa9[_0x5e8a86('0x9e2')]=angular['copy'](_0x57c06b),_0x522aa9[_0x5e8a86('0x1802')]=_0x4122a2,_0x522aa9[_0x5e8a86('0x2353')]=![],_0x522aa9[_0x5e8a86('0xe00')]=angular[_0x5e8a86('0x225f')](_0xdb6a74);!_0x522aa9['allCondition']&&(_0x522aa9[_0x5e8a86('0x9e2')]={'field':'queue','operator':'equals','value':'in'},_0x522aa9['title']=_0x5e8a86('0xa22'),_0x522aa9['newAllCondition']=!![]);_0x58df3d[_0x5e8a86('0x23f')]['id']&&(_0x522aa9[_0x5e8a86('0x9e2')][_0x5e8a86('0x2501')]=_0x58df3d[_0x5e8a86('0x23f')]['id']);_0x522aa9[_0x5e8a86('0x8b9')]=_0x5224d8,_0x522aa9[_0x5e8a86('0x9f5')]=_0x420f9f,_0x522aa9['deleteAllCondition']=_0x59727c,_0x522aa9['getDateFromString']=_0x4b11bc,_0x522aa9[_0x5e8a86('0x24a0')]=_0x1ad4b7,_0x140f8a[_0x5e8a86('0x1ac6')](_0x5e8a86('0xa7c'))?_0x23da6b[_0x5e8a86('0x1864')]['get']({'fields':_0x5e8a86('0x1776'),'sort':'id','nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x465c17){const _0x4d1a99=_0x5e8a86;_0x522aa9[_0x4d1a99('0x20e0')]=_0x465c17[_0x4d1a99('0x269a')]||[];})[_0x5e8a86('0x1a80')](function(_0x3c09d4){const _0x5796fe=_0x5e8a86;_0x4e4e01[_0x5796fe('0xfc9')]({'title':_0x3c09d4[_0x5796fe('0x52d')]?_0x5796fe('0x1e21')+_0x3c09d4[_0x5796fe('0x52d')]+_0x5796fe('0x11e1')+_0x3c09d4[_0x5796fe('0xe1b')]:_0x5796fe('0x2de'),'msg':_0x3c09d4[_0x5796fe('0x25f4')]?JSON['stringify'](_0x3c09d4[_0x5796fe('0x25f4')]):_0x3c09d4[_0x5796fe('0x1586')]()});}):_0x23da6b[_0x5e8a86('0x1864')][_0x5e8a86('0xd83')]({'fields':'id,name','sort':'id','nolimit':_0x5e8a86('0xf3b')})['$promise']['then'](function(_0x35861e){const _0x4cbb59=_0x5e8a86;_0x522aa9['chatAccounts']=_0x35861e[_0x4cbb59('0x269a')]||[];})['then'](function(){const _0x42e2e7=_0x5e8a86;return _0x23da6b[_0x42e2e7('0x17aa')]['get']({'userProfileId':_0x522aa9[_0x42e2e7('0x98')][_0x42e2e7('0xb86')],'sectionId':0x1f6})[_0x42e2e7('0xa44')];})[_0x5e8a86('0x1166')](function(_0x9be353){const _0x92637d=_0x5e8a86,_0xb65ab2=_0x9be353&&_0x9be353[_0x92637d('0x269a')]?_0x9be353[_0x92637d('0x269a')][0x0]:null;if(!_0xb65ab2){const _0x30e503=[];let _0x1d01f1=null;_0x522aa9[_0x92637d('0x9e2')]&&(_0x1d01f1=_0x2cfb05()[_0x92637d('0xc38')](_0x522aa9['chatAccounts'],{'id':Number(_0x522aa9[_0x92637d('0x9e2')][_0x92637d('0x18e0')])}));for(let _0x50136e=0x0;_0x50136e<_0x522aa9[_0x92637d('0x20e0')]['length'];_0x50136e++){_0x1d01f1&&_0x522aa9['chatAccounts'][_0x50136e]['id']===_0x1d01f1['id']&&(_0x522aa9[_0x92637d('0x20e0')][_0x50136e][_0x92637d('0x2378')]=![],_0x30e503['push'](_0x522aa9[_0x92637d('0x20e0')][_0x50136e]));}_0x522aa9[_0x92637d('0x20e0')]=_0x30e503;}else{if(!_0xb65ab2['autoAssociation'])return _0x23da6b[_0x92637d('0x4b5')][_0x92637d('0xd83')]({'sectionId':_0xb65ab2['id']})[_0x92637d('0xa44')][_0x92637d('0x1166')](function(_0x13edbb){const _0xcab90b=_0x92637d,_0x178fb2=_0x2cfb05()[_0xcab90b('0x2563')](_0x13edbb[_0xcab90b('0x269a')],function(_0x3971fd){const _0x38a7f0=_0xcab90b;return _0x2cfb05()[_0x38a7f0('0xc38')](_0x522aa9['chatAccounts'],{'id':_0x3971fd[_0x38a7f0('0x24e8')]});});let _0x2c0afe=null;_0x522aa9[_0xcab90b('0x9e2')]&&(_0x2c0afe=_0x2cfb05()[_0xcab90b('0xc38')](_0x522aa9[_0xcab90b('0x20e0')],{'id':Number(_0x522aa9['allCondition'][_0xcab90b('0x18e0')])}));if(_0x2c0afe&&!_0x2cfb05()['some'](_0x178fb2,['id',_0x2c0afe['id']])){const _0x19ad67=_0x2cfb05()[_0xcab90b('0xc38')](_0x522aa9[_0xcab90b('0x20e0')],{'id':_0x2c0afe['id']});_0x19ad67[_0xcab90b('0x2378')]=![],_0x178fb2['push'](_0x19ad67);}_0x522aa9[_0xcab90b('0x20e0')]=_0x178fb2;});}})[_0x5e8a86('0x1a80')](function(_0x49a13c){const _0x5c1a7f=_0x5e8a86;_0x4e4e01[_0x5c1a7f('0xfc9')]({'title':_0x49a13c[_0x5c1a7f('0x52d')]?_0x5c1a7f('0x1e21')+_0x49a13c[_0x5c1a7f('0x52d')]+_0x5c1a7f('0x11e1')+_0x49a13c['statusText']:_0x5c1a7f('0x1ac'),'msg':_0x49a13c[_0x5c1a7f('0x25f4')]?JSON[_0x5c1a7f('0xbac')](_0x49a13c['data']):_0x49a13c[_0x5c1a7f('0x1586')]()});}),_0x140f8a[_0x5e8a86('0x1ac6')](_0x5e8a86('0xa7c'))?_0x23da6b['mailAccount'][_0x5e8a86('0xd83')]({'fields':'id,name','sort':'id','nolimit':'true'})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0xbb4e9c){const _0x4c63c0=_0x5e8a86;_0x522aa9[_0x4c63c0('0xf85')]=_0xbb4e9c[_0x4c63c0('0x269a')]||[];})['catch'](function(_0xbe5b37){const _0x54bed3=_0x5e8a86;_0x4e4e01[_0x54bed3('0xfc9')]({'title':_0xbe5b37[_0x54bed3('0x52d')]?_0x54bed3('0x1e21')+_0xbe5b37[_0x54bed3('0x52d')]+_0x54bed3('0x11e1')+_0xbe5b37['statusText']:_0x54bed3('0x4bd'),'msg':_0xbe5b37[_0x54bed3('0x25f4')]?JSON[_0x54bed3('0xbac')](_0xbe5b37[_0x54bed3('0x25f4')]):_0xbe5b37['toString']()});}):_0x23da6b[_0x5e8a86('0x21b9')][_0x5e8a86('0xd83')]({'fields':_0x5e8a86('0x1776'),'sort':'id','nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x30821e){const _0x2ea4b9=_0x5e8a86;_0x522aa9[_0x2ea4b9('0xf85')]=_0x30821e['rows']||[];})[_0x5e8a86('0x1166')](function(){const _0x1f5e03=_0x5e8a86;return _0x23da6b[_0x1f5e03('0x17aa')][_0x1f5e03('0xd83')]({'userProfileId':_0x522aa9[_0x1f5e03('0x98')][_0x1f5e03('0xb86')],'sectionId':0x25a})['$promise'];})['then'](function(_0x2a8030){const _0x5ac49f=_0x5e8a86,_0x12a946=_0x2a8030&&_0x2a8030['rows']?_0x2a8030[_0x5ac49f('0x269a')][0x0]:null;if(!_0x12a946){const _0x3afac1=[];let _0x27ffb8=null;_0x522aa9[_0x5ac49f('0x9e2')]&&(_0x27ffb8=_0x2cfb05()['find'](_0x522aa9[_0x5ac49f('0xf85')],{'id':Number(_0x522aa9['allCondition'][_0x5ac49f('0x18e0')])}));for(let _0x137559=0x0;_0x137559<_0x522aa9[_0x5ac49f('0xf85')]['length'];_0x137559++){_0x27ffb8&&_0x522aa9[_0x5ac49f('0xf85')][_0x137559]['id']===_0x27ffb8['id']&&(_0x522aa9[_0x5ac49f('0xf85')][_0x137559][_0x5ac49f('0x2378')]=![],_0x3afac1[_0x5ac49f('0x1514')](_0x522aa9[_0x5ac49f('0xf85')][_0x137559]));}_0x522aa9[_0x5ac49f('0xf85')]=_0x3afac1;}else{if(!_0x12a946[_0x5ac49f('0x1a2b')])return _0x23da6b[_0x5ac49f('0x4b5')][_0x5ac49f('0xd83')]({'sectionId':_0x12a946['id']})['$promise'][_0x5ac49f('0x1166')](function(_0xa94857){const _0x562030=_0x5ac49f,_0x4b47e0=_0x2cfb05()[_0x562030('0x2563')](_0xa94857['rows'],function(_0x54eaea){const _0x783c6=_0x562030;return _0x2cfb05()[_0x783c6('0xc38')](_0x522aa9[_0x783c6('0xf85')],{'id':_0x54eaea['resourceId']});});let _0xc08a5f=null;_0x522aa9['allCondition']&&(_0xc08a5f=_0x2cfb05()[_0x562030('0xc38')](_0x522aa9[_0x562030('0xf85')],{'id':Number(_0x522aa9[_0x562030('0x9e2')]['value'])}));if(_0xc08a5f&&!_0x2cfb05()[_0x562030('0x1798')](_0x4b47e0,['id',_0xc08a5f['id']])){const _0xdf9baf=_0x2cfb05()[_0x562030('0xc38')](_0x522aa9['mailAccounts'],{'id':_0xc08a5f['id']});_0xdf9baf[_0x562030('0x2378')]=![],_0x4b47e0[_0x562030('0x1514')](_0xdf9baf);}_0x522aa9[_0x562030('0xf85')]=_0x4b47e0;});}})['catch'](function(_0x644db6){const _0x4e83cf=_0x5e8a86;_0x4e4e01['error']({'title':_0x644db6[_0x4e83cf('0x52d')]?'API:'+_0x644db6[_0x4e83cf('0x52d')]+_0x4e83cf('0x11e1')+_0x644db6[_0x4e83cf('0xe1b')]:_0x4e83cf('0x5e'),'msg':_0x644db6['data']?JSON[_0x4e83cf('0xbac')](_0x644db6[_0x4e83cf('0x25f4')]):_0x644db6[_0x4e83cf('0x1586')]()});}),_0x140f8a[_0x5e8a86('0x1ac6')](_0x5e8a86('0xa7c'))?_0x23da6b[_0x5e8a86('0x27e5')][_0x5e8a86('0xd83')]({'fields':'id,name','sort':'id','nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x584dcf){const _0x560937=_0x5e8a86;_0x522aa9[_0x560937('0x1d76')]=_0x584dcf[_0x560937('0x269a')]||[];})[_0x5e8a86('0x1a80')](function(_0x4ff007){const _0x5218c4=_0x5e8a86;_0x4e4e01['error']({'title':_0x4ff007[_0x5218c4('0x52d')]?'API:'+_0x4ff007[_0x5218c4('0x52d')]+_0x5218c4('0x11e1')+_0x4ff007[_0x5218c4('0xe1b')]:_0x5218c4('0xc0d'),'msg':_0x4ff007[_0x5218c4('0x25f4')]?JSON[_0x5218c4('0xbac')](_0x4ff007[_0x5218c4('0x25f4')]):_0x4ff007[_0x5218c4('0x1586')]()});}):_0x23da6b[_0x5e8a86('0x27e5')][_0x5e8a86('0xd83')]({'fields':_0x5e8a86('0x1776'),'sort':'id','nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x45f0d1){const _0x5c39cf=_0x5e8a86;_0x522aa9['smsAccounts']=_0x45f0d1[_0x5c39cf('0x269a')]||[];})[_0x5e8a86('0x1166')](function(){const _0x38b6f=_0x5e8a86;return _0x23da6b[_0x38b6f('0x17aa')][_0x38b6f('0xd83')]({'userProfileId':_0x522aa9[_0x38b6f('0x98')][_0x38b6f('0xb86')],'sectionId':0x2be})['$promise'];})[_0x5e8a86('0x1166')](function(_0x2cf688){const _0x3f9741=_0x5e8a86,_0x9c296d=_0x2cf688&&_0x2cf688['rows']?_0x2cf688[_0x3f9741('0x269a')][0x0]:null;if(!_0x9c296d){const _0x1f5287=[];let _0x36ae88=null;_0x522aa9[_0x3f9741('0x9e2')]&&(_0x36ae88=_0x2cfb05()[_0x3f9741('0xc38')](_0x522aa9[_0x3f9741('0x1d76')],{'id':Number(_0x522aa9[_0x3f9741('0x9e2')][_0x3f9741('0x18e0')])}));for(let _0x29ff20=0x0;_0x29ff20<_0x522aa9[_0x3f9741('0x1d76')][_0x3f9741('0x264b')];_0x29ff20++){_0x36ae88&&_0x522aa9[_0x3f9741('0x1d76')][_0x29ff20]['id']===_0x36ae88['id']&&(_0x522aa9[_0x3f9741('0x1d76')][_0x29ff20][_0x3f9741('0x2378')]=![],_0x1f5287[_0x3f9741('0x1514')](_0x522aa9[_0x3f9741('0x1d76')][_0x29ff20]));}_0x522aa9[_0x3f9741('0x1d76')]=_0x1f5287;}else{if(!_0x9c296d[_0x3f9741('0x1a2b')])return _0x23da6b[_0x3f9741('0x4b5')][_0x3f9741('0xd83')]({'sectionId':_0x9c296d['id']})[_0x3f9741('0xa44')][_0x3f9741('0x1166')](function(_0x5457a9){const _0x255083=_0x3f9741,_0xacc434=_0x2cfb05()['map'](_0x5457a9[_0x255083('0x269a')],function(_0x103a01){const _0x1a59cc=_0x255083;return _0x2cfb05()[_0x1a59cc('0xc38')](_0x522aa9['smsAccounts'],{'id':_0x103a01[_0x1a59cc('0x24e8')]});});let _0xbc683=null;_0x522aa9['allCondition']&&(_0xbc683=_0x2cfb05()['find'](_0x522aa9[_0x255083('0x1d76')],{'id':Number(_0x522aa9[_0x255083('0x9e2')][_0x255083('0x18e0')])}));if(_0xbc683&&!_0x2cfb05()['some'](_0xacc434,['id',_0xbc683['id']])){const _0xb0a976=_0x2cfb05()['find'](_0x522aa9[_0x255083('0x1d76')],{'id':_0xbc683['id']});_0xb0a976[_0x255083('0x2378')]=![],_0xacc434['push'](_0xb0a976);}_0x522aa9[_0x255083('0x1d76')]=_0xacc434;});}})[_0x5e8a86('0x1a80')](function(_0x445d6a){const _0x27d12e=_0x5e8a86;_0x4e4e01[_0x27d12e('0xfc9')]({'title':_0x445d6a[_0x27d12e('0x52d')]?_0x27d12e('0x1e21')+_0x445d6a['status']+_0x27d12e('0x11e1')+_0x445d6a[_0x27d12e('0xe1b')]:'SYSTEM:GETsmsAccounts','msg':_0x445d6a[_0x27d12e('0x25f4')]?JSON[_0x27d12e('0xbac')](_0x445d6a[_0x27d12e('0x25f4')]):_0x445d6a[_0x27d12e('0x1586')]()});}),_0x140f8a[_0x5e8a86('0x1ac6')](_0x5e8a86('0xa7c'))?_0x23da6b[_0x5e8a86('0xcc5')][_0x5e8a86('0xd83')]({'fields':_0x5e8a86('0x1776'),'sort':'id','nolimit':'true'})[_0x5e8a86('0xa44')]['then'](function(_0x258255){_0x522aa9['whatsappAccounts']=_0x258255['rows']||[];})[_0x5e8a86('0x1a80')](function(_0x1f00ba){const _0x1b6494=_0x5e8a86;_0x4e4e01['error']({'title':_0x1f00ba[_0x1b6494('0x52d')]?_0x1b6494('0x1e21')+_0x1f00ba[_0x1b6494('0x52d')]+_0x1b6494('0x11e1')+_0x1f00ba['statusText']:_0x1b6494('0x226f'),'msg':_0x1f00ba['data']?JSON[_0x1b6494('0xbac')](_0x1f00ba[_0x1b6494('0x25f4')]):_0x1f00ba['toString']()});}):_0x23da6b[_0x5e8a86('0xcc5')][_0x5e8a86('0xd83')]({'fields':_0x5e8a86('0x1776'),'sort':'id','nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x39a3ae){const _0x5be915=_0x5e8a86;_0x522aa9[_0x5be915('0x1974')]=_0x39a3ae[_0x5be915('0x269a')]||[];})[_0x5e8a86('0x1166')](function(){const _0x529d8d=_0x5e8a86;return _0x23da6b[_0x529d8d('0x17aa')][_0x529d8d('0xd83')]({'userProfileId':_0x522aa9[_0x529d8d('0x98')][_0x529d8d('0xb86')],'sectionId':0x836})[_0x529d8d('0xa44')];})['then'](function(_0x24315e){const _0x4799d6=_0x5e8a86,_0x46556d=_0x24315e&&_0x24315e['rows']?_0x24315e[_0x4799d6('0x269a')][0x0]:null;if(!_0x46556d){const _0x50bbff=[];let _0x51a574=null;_0x522aa9['allCondition']&&(_0x51a574=_0x2cfb05()[_0x4799d6('0xc38')](_0x522aa9['whatsappAccounts'],{'id':Number(_0x522aa9[_0x4799d6('0x9e2')][_0x4799d6('0x18e0')])}));for(let _0xf51f34=0x0;_0xf51f34<_0x522aa9[_0x4799d6('0x1974')]['length'];_0xf51f34++){_0x51a574&&_0x522aa9['whatsappAccounts'][_0xf51f34]['id']===_0x51a574['id']&&(_0x522aa9[_0x4799d6('0x1974')][_0xf51f34]['canSelect']=![],_0x50bbff[_0x4799d6('0x1514')](_0x522aa9[_0x4799d6('0x1974')][_0xf51f34]));}_0x522aa9[_0x4799d6('0x1974')]=_0x50bbff;}else{if(!_0x46556d['autoAssociation'])return _0x23da6b[_0x4799d6('0x4b5')][_0x4799d6('0xd83')]({'sectionId':_0x46556d['id']})[_0x4799d6('0xa44')][_0x4799d6('0x1166')](function(_0x253100){const _0x1bb410=_0x4799d6,_0x106516=_0x2cfb05()[_0x1bb410('0x2563')](_0x253100[_0x1bb410('0x269a')],function(_0xfa6546){const _0xae7011=_0x1bb410;return _0x2cfb05()[_0xae7011('0xc38')](_0x522aa9[_0xae7011('0x1974')],{'id':_0xfa6546[_0xae7011('0x24e8')]});});let _0x51d12b=null;_0x522aa9['allCondition']&&(_0x51d12b=_0x2cfb05()['find'](_0x522aa9[_0x1bb410('0x1974')],{'id':Number(_0x522aa9['allCondition'][_0x1bb410('0x18e0')])}));if(_0x51d12b&&!_0x2cfb05()['some'](_0x106516,['id',_0x51d12b['id']])){const _0x2ff92e=_0x2cfb05()[_0x1bb410('0xc38')](_0x522aa9[_0x1bb410('0x1974')],{'id':_0x51d12b['id']});_0x2ff92e[_0x1bb410('0x2378')]=![],_0x106516[_0x1bb410('0x1514')](_0x2ff92e);}_0x522aa9[_0x1bb410('0x1974')]=_0x106516;});}})[_0x5e8a86('0x1a80')](function(_0x12d517){const _0x3e8235=_0x5e8a86;_0x4e4e01['error']({'title':_0x12d517[_0x3e8235('0x52d')]?_0x3e8235('0x1e21')+_0x12d517['status']+_0x3e8235('0x11e1')+_0x12d517['statusText']:'SYSTEM:GETwhatsappAccounts','msg':_0x12d517[_0x3e8235('0x25f4')]?JSON[_0x3e8235('0xbac')](_0x12d517[_0x3e8235('0x25f4')]):_0x12d517[_0x3e8235('0x1586')]()});}),_0x140f8a['hasRole'](_0x5e8a86('0xa7c'))?_0x23da6b[_0x5e8a86('0x2085')][_0x5e8a86('0xd83')]({'fields':_0x5e8a86('0x1776'),'sort':'id','nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0xcf52bc){const _0x142597=_0x5e8a86;_0x522aa9['faxAccounts']=_0xcf52bc[_0x142597('0x269a')]||[];})[_0x5e8a86('0x1a80')](function(_0x315c44){const _0x49c032=_0x5e8a86;_0x4e4e01[_0x49c032('0xfc9')]({'title':_0x315c44[_0x49c032('0x52d')]?_0x49c032('0x1e21')+_0x315c44['status']+'\x20-\x20'+_0x315c44['statusText']:_0x49c032('0x464'),'msg':_0x315c44['data']?JSON[_0x49c032('0xbac')](_0x315c44['data']):_0x315c44['toString']()});}):_0x23da6b[_0x5e8a86('0x2085')]['get']({'fields':'id,name','sort':'id','nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x704cbf){const _0x2af2d7=_0x5e8a86;_0x522aa9[_0x2af2d7('0xd6c')]=_0x704cbf['rows']||[];})['then'](function(){const _0x5f1b9d=_0x5e8a86;return _0x23da6b[_0x5f1b9d('0x17aa')]['get']({'userProfileId':_0x522aa9[_0x5f1b9d('0x98')][_0x5f1b9d('0xb86')],'sectionId':0x386})['$promise'];})[_0x5e8a86('0x1166')](function(_0x1d7e84){const _0x7fe58b=_0x5e8a86,_0x1df49f=_0x1d7e84&&_0x1d7e84['rows']?_0x1d7e84['rows'][0x0]:null;if(!_0x1df49f){const _0x53c03f=[];let _0x34573b=null;_0x522aa9[_0x7fe58b('0x9e2')]&&(_0x34573b=_0x2cfb05()[_0x7fe58b('0xc38')](_0x522aa9[_0x7fe58b('0xd6c')],{'id':Number(_0x522aa9['allCondition'][_0x7fe58b('0x18e0')])}));for(let _0x13f1e2=0x0;_0x13f1e2<_0x522aa9[_0x7fe58b('0xd6c')]['length'];_0x13f1e2++){_0x34573b&&_0x522aa9[_0x7fe58b('0xd6c')][_0x13f1e2]['id']===_0x34573b['id']&&(_0x522aa9[_0x7fe58b('0xd6c')][_0x13f1e2][_0x7fe58b('0x2378')]=![],_0x53c03f[_0x7fe58b('0x1514')](_0x522aa9[_0x7fe58b('0xd6c')][_0x13f1e2]));}_0x522aa9[_0x7fe58b('0xd6c')]=_0x53c03f;}else{if(!_0x1df49f[_0x7fe58b('0x1a2b')])return _0x23da6b[_0x7fe58b('0x4b5')][_0x7fe58b('0xd83')]({'sectionId':_0x1df49f['id']})[_0x7fe58b('0xa44')][_0x7fe58b('0x1166')](function(_0x1dfbb3){const _0x45335d=_0x7fe58b,_0x4ebd5c=_0x2cfb05()['map'](_0x1dfbb3[_0x45335d('0x269a')],function(_0x1f4497){const _0x2d6a85=_0x45335d;return _0x2cfb05()[_0x2d6a85('0xc38')](_0x522aa9[_0x2d6a85('0xd6c')],{'id':_0x1f4497[_0x2d6a85('0x24e8')]});});let _0x36c053=null;_0x522aa9[_0x45335d('0x9e2')]&&(_0x36c053=_0x2cfb05()['find'](_0x522aa9[_0x45335d('0xd6c')],{'id':Number(_0x522aa9[_0x45335d('0x9e2')][_0x45335d('0x18e0')])}));if(_0x36c053&&!_0x2cfb05()[_0x45335d('0x1798')](_0x4ebd5c,['id',_0x36c053['id']])){const _0x450f9f=_0x2cfb05()[_0x45335d('0xc38')](_0x522aa9[_0x45335d('0xd6c')],{'id':_0x36c053['id']});_0x450f9f[_0x45335d('0x2378')]=![],_0x4ebd5c['push'](_0x450f9f);}_0x522aa9[_0x45335d('0xd6c')]=_0x4ebd5c;});}})[_0x5e8a86('0x1a80')](function(_0x534ff2){const _0x46f9cd=_0x5e8a86;_0x4e4e01['error']({'title':_0x534ff2[_0x46f9cd('0x52d')]?_0x46f9cd('0x1e21')+_0x534ff2[_0x46f9cd('0x52d')]+_0x46f9cd('0x11e1')+_0x534ff2[_0x46f9cd('0xe1b')]:_0x46f9cd('0x1a59'),'msg':_0x534ff2[_0x46f9cd('0x25f4')]?JSON['stringify'](_0x534ff2[_0x46f9cd('0x25f4')]):_0x534ff2[_0x46f9cd('0x1586')]()});}),_0x140f8a[_0x5e8a86('0x1ac6')](_0x5e8a86('0xa7c'))?_0x23da6b[_0x5e8a86('0x77f')][_0x5e8a86('0xd83')]({'fields':_0x5e8a86('0x1776'),'sort':'id','nolimit':'true'})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x109222){_0x522aa9['openchannelAccounts']=_0x109222['rows']||[];})[_0x5e8a86('0x1a80')](function(_0x1297c2){const _0x5041f3=_0x5e8a86;_0x4e4e01[_0x5041f3('0xfc9')]({'title':_0x1297c2['status']?_0x5041f3('0x1e21')+_0x1297c2[_0x5041f3('0x52d')]+'\x20-\x20'+_0x1297c2[_0x5041f3('0xe1b')]:_0x5041f3('0xe1a'),'msg':_0x1297c2[_0x5041f3('0x25f4')]?JSON['stringify'](_0x1297c2['data']):_0x1297c2[_0x5041f3('0x1586')]()});}):_0x23da6b[_0x5e8a86('0x77f')]['get']({'fields':_0x5e8a86('0x1776'),'sort':'id','nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x287ed4){const _0x1ab921=_0x5e8a86;_0x522aa9[_0x1ab921('0x28ff')]=_0x287ed4['rows']||[];})[_0x5e8a86('0x1166')](function(){const _0x1e93af=_0x5e8a86;return _0x23da6b[_0x1e93af('0x17aa')]['get']({'userProfileId':_0x522aa9['currentUser'][_0x1e93af('0xb86')],'sectionId':0x322})['$promise'];})['then'](function(_0x163b58){const _0x3a6116=_0x5e8a86,_0x5f1140=_0x163b58&&_0x163b58[_0x3a6116('0x269a')]?_0x163b58[_0x3a6116('0x269a')][0x0]:null;if(!_0x5f1140){const _0x4b8eea=[];let _0xab385f=null;_0x522aa9['allCondition']&&(_0xab385f=_0x2cfb05()['find'](_0x522aa9[_0x3a6116('0x28ff')],{'id':Number(_0x522aa9['allCondition']['value'])}));for(let _0x1ed237=0x0;_0x1ed237<_0x522aa9[_0x3a6116('0x28ff')][_0x3a6116('0x264b')];_0x1ed237++){_0xab385f&&_0x522aa9[_0x3a6116('0x28ff')][_0x1ed237]['id']===_0xab385f['id']&&(_0x522aa9[_0x3a6116('0x28ff')][_0x1ed237][_0x3a6116('0x2378')]=![],_0x4b8eea[_0x3a6116('0x1514')](_0x522aa9[_0x3a6116('0x28ff')][_0x1ed237]));}_0x522aa9[_0x3a6116('0x28ff')]=_0x4b8eea;}else{if(!_0x5f1140[_0x3a6116('0x1a2b')])return _0x23da6b[_0x3a6116('0x4b5')]['get']({'sectionId':_0x5f1140['id']})['$promise']['then'](function(_0x394fce){const _0x140ce9=_0x3a6116,_0x50bee2=_0x2cfb05()[_0x140ce9('0x2563')](_0x394fce['rows'],function(_0x322cd7){const _0x5f4e07=_0x140ce9;return _0x2cfb05()[_0x5f4e07('0xc38')](_0x522aa9[_0x5f4e07('0x28ff')],{'id':_0x322cd7[_0x5f4e07('0x24e8')]});});let _0x178086=null;_0x522aa9[_0x140ce9('0x9e2')]&&(_0x178086=_0x2cfb05()[_0x140ce9('0xc38')](_0x522aa9[_0x140ce9('0x28ff')],{'id':Number(_0x522aa9['allCondition'][_0x140ce9('0x18e0')])}));if(_0x178086&&!_0x2cfb05()['some'](_0x50bee2,['id',_0x178086['id']])){const _0x2773e4=_0x2cfb05()[_0x140ce9('0xc38')](_0x522aa9[_0x140ce9('0x28ff')],{'id':_0x178086['id']});_0x2773e4['canSelect']=![],_0x50bee2[_0x140ce9('0x1514')](_0x2773e4);}_0x522aa9['openchannelAccounts']=_0x50bee2;});}})[_0x5e8a86('0x1a80')](function(_0x3e5358){const _0x56da4d=_0x5e8a86;_0x4e4e01['error']({'title':_0x3e5358[_0x56da4d('0x52d')]?'API:'+_0x3e5358[_0x56da4d('0x52d')]+_0x56da4d('0x11e1')+_0x3e5358['statusText']:_0x56da4d('0x11bf'),'msg':_0x3e5358[_0x56da4d('0x25f4')]?JSON[_0x56da4d('0xbac')](_0x3e5358[_0x56da4d('0x25f4')]):_0x3e5358[_0x56da4d('0x1586')]()});});const _0x58df6f=[{'id':0x191,'type':_0x5e8a86('0x14d8')},{'id':0x5dd,'type':'outbound'}];let _0x4305c2=null;_0x140f8a[_0x5e8a86('0x1ac6')](_0x5e8a86('0xa7c'))?_0x23da6b[_0x5e8a86('0x1943')][_0x5e8a86('0xd83')]({'fields':_0x5e8a86('0x1c09'),'sort':_0x5e8a86('0x4f0'),'nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x4d2ee3){const _0x47e170=_0x5e8a86;_0x522aa9[_0x47e170('0x7a7')]=_0x4d2ee3[_0x47e170('0x269a')]||[];})[_0x5e8a86('0x1a80')](function(_0x3109b8){const _0x2926df=_0x5e8a86;_0x4e4e01['error']({'title':_0x3109b8['status']?_0x2926df('0x1e21')+_0x3109b8[_0x2926df('0x52d')]+_0x2926df('0x11e1')+_0x3109b8[_0x2926df('0xe1b')]:_0x2926df('0x2029'),'msg':_0x3109b8['data']?JSON[_0x2926df('0xbac')](_0x3109b8[_0x2926df('0x25f4')]):_0x3109b8[_0x2926df('0x1586')]()});}):_0x23da6b['voiceQueue'][_0x5e8a86('0xd83')]({'fields':_0x5e8a86('0x1c09'),'sort':_0x5e8a86('0x4f0'),'nolimit':_0x5e8a86('0xf3b')})['$promise']['then'](function(_0x1b187f){const _0x49baae=_0x5e8a86;_0x4305c2=_0x1b187f[_0x49baae('0x269a')]||[];})['then'](function(){const _0x2211c4=_0x5e8a86,_0xcda8df=[];for(let _0x1d0b92=0x0;_0x1d0b92<_0x58df6f[_0x2211c4('0x264b')];_0x1d0b92++){_0xcda8df[_0x2211c4('0x1514')](_0x23da6b['userProfileSection']['get']({'userProfileId':_0x522aa9['currentUser'][_0x2211c4('0xb86')],'sectionId':_0x58df6f[_0x1d0b92]['id']})[_0x2211c4('0xa44')]);}return _0x3ec904[_0x2211c4('0x2760')](_0xcda8df);})[_0x5e8a86('0x1166')](function(_0x1a8755){const _0x4dcdb1=_0x5e8a86,_0x24ba03=_0x2cfb05()[_0x4dcdb1('0x2563')](_0x1a8755,function(_0x58db66){const _0x23fe5d=_0x4dcdb1;return _0x58db66&&_0x58db66[_0x23fe5d('0x269a')]?_0x58db66['rows'][0x0]:null;}),_0x345f7e=[];for(let _0x5f5a71=0x0;_0x5f5a71<_0x58df6f[_0x4dcdb1('0x264b')];_0x5f5a71++){const _0x486977=_0x2cfb05()[_0x4dcdb1('0xc38')](_0x24ba03,[_0x4dcdb1('0x120e'),_0x58df6f[_0x5f5a71]['id']]);if(_0x486977){if(!_0x486977[_0x4dcdb1('0x1a2b')])_0x345f7e[_0x4dcdb1('0x1514')](_0x23da6b[_0x4dcdb1('0x4b5')]['get']({'sectionId':_0x486977['id']})[_0x4dcdb1('0xa44')]);else{const _0x487473=[];_0x4305c2[_0x4dcdb1('0x2782')](function(_0x322fb8){const _0x20dbfc=_0x4dcdb1;_0x322fb8[_0x20dbfc('0x1345')]===_0x58df6f[_0x5f5a71][_0x20dbfc('0x1345')]&&_0x487473['push'](_0x322fb8);}),_0x345f7e['push']({'rows':_0x487473,'count':_0x487473[_0x4dcdb1('0x264b')]});}}}return _0x3ec904[_0x4dcdb1('0x2760')](_0x345f7e);})['then'](function(_0x4e83df){const _0x449fad=_0x5e8a86,_0x383e07=[];let _0x25d1ca=null;_0x522aa9[_0x449fad('0x9e2')]&&(_0x25d1ca=_0x2cfb05()[_0x449fad('0xc38')](_0x4305c2,{'name':_0x522aa9[_0x449fad('0x9e2')][_0x449fad('0x18e0')]}));for(let _0x2b69d5=0x0;_0x2b69d5<_0x4e83df[_0x449fad('0x264b')];_0x2b69d5++){const _0x164bf4=_0x4e83df[_0x2b69d5][_0x449fad('0x269a')]||[];_0x164bf4[_0x449fad('0x2782')](function(_0x4dda7d){const _0x39c248=_0x449fad;_0x383e07[_0x39c248('0x1514')](_0x4dda7d);});}_0x25d1ca&&!_0x2cfb05()[_0x449fad('0x1798')](_0x383e07,[_0x449fad('0x24e8'),_0x25d1ca['id']])&&_0x4305c2[_0x449fad('0x2782')](function(_0xc30fe){const _0x29eb6a=_0x449fad;_0xc30fe['id']===_0x25d1ca['id']&&(_0xc30fe[_0x29eb6a('0x2378')]=![],_0x383e07[_0x29eb6a('0x1514')](_0xc30fe));}),_0x522aa9[_0x449fad('0x7a7')]=_0x383e07;})['catch'](function(_0x5ce8b1){const _0x586f07=_0x5e8a86;_0x4e4e01[_0x586f07('0xfc9')]({'title':_0x5ce8b1['status']?'API:'+_0x5ce8b1[_0x586f07('0x52d')]+'\x20-\x20'+_0x5ce8b1[_0x586f07('0xe1b')]:_0x586f07('0x1dd7'),'msg':_0x5ce8b1['data']?JSON[_0x586f07('0xbac')](_0x5ce8b1['data']):_0x5ce8b1['toString']()});}),_0x140f8a[_0x5e8a86('0x1ac6')](_0x5e8a86('0xa7c'))?_0x23da6b[_0x5e8a86('0x1deb')][_0x5e8a86('0xd83')]({'fields':_0x5e8a86('0x27bd'),'type':_0x5e8a86('0x587'),'VoiceExtensionId':_0x5e8a86('0x15d7'),'nolimit':'true'})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x360b5a){const _0x2763e0=_0x5e8a86;_0x522aa9['outboundRoutes']=_0x360b5a[_0x2763e0('0x269a')]||[];})[_0x5e8a86('0x1a80')](function(_0x15026e){const _0x3c1aa7=_0x5e8a86;_0x4e4e01[_0x3c1aa7('0xfc9')]({'title':_0x15026e[_0x3c1aa7('0x52d')]?_0x3c1aa7('0x1e21')+_0x15026e[_0x3c1aa7('0x52d')]+_0x3c1aa7('0x11e1')+_0x15026e[_0x3c1aa7('0xe1b')]:_0x3c1aa7('0x261f'),'msg':_0x15026e[_0x3c1aa7('0x25f4')]?JSON[_0x3c1aa7('0xbac')](_0x15026e[_0x3c1aa7('0x25f4')]):_0x15026e[_0x3c1aa7('0x1586')]()});}):_0x23da6b[_0x5e8a86('0x1deb')]['get']({'fields':_0x5e8a86('0x27bd'),'type':_0x5e8a86('0x587'),'VoiceExtensionId':_0x5e8a86('0x15d7'),'nolimit':'true'})['$promise'][_0x5e8a86('0x1166')](function(_0x25e989){_0x522aa9['outboundRoutes']=_0x25e989['rows']||[];})[_0x5e8a86('0x1166')](function(){const _0x412dfb=_0x5e8a86;return _0x23da6b[_0x412dfb('0x17aa')][_0x412dfb('0xd83')]({'userProfileId':_0x522aa9['currentUser'][_0x412dfb('0xb86')],'sectionId':0x193})['$promise'];})[_0x5e8a86('0x1166')](function(_0x1c3999){const _0xd22bdb=_0x5e8a86,_0xa78ab1=_0x1c3999&&_0x1c3999['rows']?_0x1c3999[_0xd22bdb('0x269a')][0x0]:null;if(!_0xa78ab1){const _0x53efa4=[];let _0x21e8b8=null;_0x522aa9[_0xd22bdb('0x9e2')]&&(_0x21e8b8=_0x2cfb05()[_0xd22bdb('0xc38')](_0x522aa9[_0xd22bdb('0x2404')],{'id':Number(_0x522aa9[_0xd22bdb('0x9e2')][_0xd22bdb('0x18e0')])}));for(let _0x248fef=0x0;_0x248fef<_0x522aa9[_0xd22bdb('0x2404')][_0xd22bdb('0x264b')];_0x248fef++){_0x21e8b8&&_0x522aa9[_0xd22bdb('0x2404')][_0x248fef]['id']===_0x21e8b8['id']&&(_0x522aa9[_0xd22bdb('0x2404')][_0x248fef][_0xd22bdb('0x2378')]=![],_0x53efa4[_0xd22bdb('0x1514')](_0x522aa9[_0xd22bdb('0x2404')][_0x248fef]));}_0x522aa9[_0xd22bdb('0x2404')]=_0x53efa4;}else{if(!_0xa78ab1[_0xd22bdb('0x1a2b')])return _0x23da6b[_0xd22bdb('0x4b5')][_0xd22bdb('0xd83')]({'sectionId':_0xa78ab1['id']})[_0xd22bdb('0xa44')]['then'](function(_0xc1d1fa){const _0x4a8a1e=_0xd22bdb,_0x523673=_0x2cfb05()[_0x4a8a1e('0x2563')](_0xc1d1fa['rows'],function(_0x20f3e2){const _0x41270a=_0x4a8a1e;return _0x2cfb05()['find'](_0x522aa9[_0x41270a('0x2404')],{'id':_0x20f3e2[_0x41270a('0x24e8')]});});let _0xd42c49=null;_0x522aa9[_0x4a8a1e('0x9e2')]&&(_0xd42c49=_0x2cfb05()[_0x4a8a1e('0xc38')](_0x522aa9['outboundRoutes'],{'id':Number(_0x522aa9[_0x4a8a1e('0x9e2')][_0x4a8a1e('0x18e0')])}));if(_0xd42c49&&!_0x2cfb05()[_0x4a8a1e('0x1798')](_0x523673,['id',_0xd42c49['id']])){const _0x52ea85=_0x2cfb05()[_0x4a8a1e('0xc38')](_0x522aa9['outboundRoutes'],{'id':_0xd42c49['id']});_0x52ea85[_0x4a8a1e('0x2378')]=![],_0x523673['push'](_0x52ea85);}_0x522aa9[_0x4a8a1e('0x2404')]=_0x523673;});}})[_0x5e8a86('0x1a80')](function(_0x226181){const _0x4cefcc=_0x5e8a86;_0x4e4e01[_0x4cefcc('0xfc9')]({'title':_0x226181['status']?'API:'+_0x226181['status']+_0x4cefcc('0x11e1')+_0x226181[_0x4cefcc('0xe1b')]:_0x4cefcc('0x2764'),'msg':_0x226181['data']?JSON[_0x4cefcc('0xbac')](_0x226181['data']):_0x226181[_0x4cefcc('0x1586')]()});}),_0x140f8a['hasRole'](_0x5e8a86('0xa7c'))?_0x23da6b[_0x5e8a86('0x557')][_0x5e8a86('0xd83')]({'fields':'id,name,fullname','sort':_0x5e8a86('0x4f0'),'role':_0x5e8a86('0x1eff'),'nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x42823a){const _0x368ce3=_0x5e8a86;_0x522aa9[_0x368ce3('0x1f7e')]=_0x42823a[_0x368ce3('0x269a')]||[];})[_0x5e8a86('0x1a80')](function(_0x131e1b){const _0x5a43d6=_0x5e8a86;_0x4e4e01[_0x5a43d6('0xfc9')]({'title':_0x131e1b[_0x5a43d6('0x52d')]?'API:'+_0x131e1b[_0x5a43d6('0x52d')]+_0x5a43d6('0x11e1')+_0x131e1b['statusText']:_0x5a43d6('0xd4c'),'msg':_0x131e1b[_0x5a43d6('0x25f4')]?JSON[_0x5a43d6('0xbac')](_0x131e1b[_0x5a43d6('0x25f4')]):_0x131e1b[_0x5a43d6('0x1586')]()});}):_0x23da6b[_0x5e8a86('0x557')]['get']({'fields':'id,name,fullname','sort':_0x5e8a86('0x4f0'),'role':_0x5e8a86('0x1eff'),'nolimit':_0x5e8a86('0xf3b')})[_0x5e8a86('0xa44')][_0x5e8a86('0x1166')](function(_0x560c19){const _0x549c15=_0x5e8a86;_0x522aa9[_0x549c15('0x1f7e')]=_0x560c19[_0x549c15('0x269a')]||[];})[_0x5e8a86('0x1166')](function(){const _0x141746=_0x5e8a86;return _0x23da6b['userProfileSection'][_0x141746('0xd83')]({'userProfileId':_0x522aa9[_0x141746('0x98')]['userProfileId'],'sectionId':0xca})[_0x141746('0xa44')];})['then'](function(_0x2fd612){const _0x5eba04=_0x5e8a86,_0x939cd5=_0x2fd612&&_0x2fd612[_0x5eba04('0x269a')]?_0x2fd612[_0x5eba04('0x269a')][0x0]:null;if(!_0x939cd5){const _0x229409=[];let _0x3feca0=null;_0x522aa9[_0x5eba04('0x9e2')]&&(_0x3feca0=_0x2cfb05()[_0x5eba04('0xc38')](_0x522aa9[_0x5eba04('0x1f7e')],{'name':_0x522aa9[_0x5eba04('0x9e2')]['value']}));for(let _0x35e046=0x0;_0x35e046<_0x522aa9[_0x5eba04('0x1f7e')]['length'];_0x35e046++){_0x3feca0&&_0x522aa9[_0x5eba04('0x1f7e')][_0x35e046]['id']===_0x3feca0['id']&&(_0x522aa9[_0x5eba04('0x1f7e')][_0x35e046][_0x5eba04('0x2378')]=![],_0x229409[_0x5eba04('0x1514')](_0x522aa9['agents'][_0x35e046]));}_0x522aa9[_0x5eba04('0x1f7e')]=_0x229409;}else{if(!_0x939cd5[_0x5eba04('0x1a2b')])return _0x23da6b[_0x5eba04('0x4b5')][_0x5eba04('0xd83')]({'sectionId':_0x939cd5['id']})[_0x5eba04('0xa44')][_0x5eba04('0x1166')](function(_0x5b5d89){const _0x3318d2=_0x5eba04,_0x277b7e=_0x2cfb05()[_0x3318d2('0x2563')](_0x5b5d89[_0x3318d2('0x269a')],function(_0x137878){const _0x2daf2a=_0x3318d2;return _0x2cfb05()[_0x2daf2a('0xc38')](_0x522aa9[_0x2daf2a('0x1f7e')],{'id':_0x137878[_0x2daf2a('0x24e8')]});});let _0x18d1a6=null;_0x522aa9['allCondition']&&(_0x18d1a6=_0x2cfb05()['find'](_0x522aa9[_0x3318d2('0x1f7e')],{'name':_0x522aa9[_0x3318d2('0x9e2')][_0x3318d2('0x18e0')]}));if(_0x18d1a6&&!_0x2cfb05()[_0x3318d2('0x1798')](_0x277b7e,['id',_0x18d1a6['id']])){const _0x5ec6ff=_0x2cfb05()[_0x3318d2('0xc38')](_0x522aa9[_0x3318d2('0x1f7e')],{'id':_0x18d1a6['id']});_0x5ec6ff['canSelect']=![],_0x277b7e['push'](_0x5ec6ff);}_0x522aa9[_0x3318d2('0x1f7e')]=_0x277b7e;});}})['catch'](function(_0x43dfea){const _0x38c2a5=_0x5e8a86;_0x4e4e01['error']({'title':_0x43dfea[_0x38c2a5('0x52d')]?'API:'+_0x43dfea[_0x38c2a5('0x52d')]+_0x38c2a5('0x11e1')+_0x43dfea[_0x38c2a5('0xe1b')]:_0x38c2a5('0xdc5'),'msg':_0x43dfea[_0x38c2a5('0x25f4')]?JSON[_0x38c2a5('0xbac')](_0x43dfea['data']):_0x43dfea['toString']()});});function _0x5224d8(){const _0x52aecf=_0x5e8a86;_0x522aa9['errors']=[],_0x23da6b[_0x52aecf('0xe00')][_0x52aecf('0x452')]({'id':_0x58df3d[_0x52aecf('0x23f')]['id']},_0x522aa9[_0x52aecf('0x9e2')])[_0x52aecf('0xa44')][_0x52aecf('0x1166')](function(_0x5ad8d0){const _0x44037d=_0x52aecf;_0x522aa9[_0x44037d('0x1802')][_0x44037d('0x2450')](_0x5ad8d0[_0x44037d('0x2876')]()),_0x4e4e01[_0x44037d('0x103b')]({'title':'AllCondition\x20properly\x20created','msg':_0x522aa9[_0x44037d('0x9e2')][_0x44037d('0x4f0')]?_0x522aa9['allCondition'][_0x44037d('0x4f0')]+_0x44037d('0x1eda'):''}),_0x1ad4b7(_0x5ad8d0);})[_0x52aecf('0x1a80')](function(_0x29bc07){const _0x32f964=_0x52aecf;if(_0x29bc07[_0x32f964('0x25f4')]&&_0x29bc07[_0x32f964('0x25f4')][_0x32f964('0x61a')]&&_0x29bc07[_0x32f964('0x25f4')][_0x32f964('0x61a')]['length']){_0x522aa9[_0x32f964('0x61a')]=_0x29bc07[_0x32f964('0x25f4')][_0x32f964('0x61a')]||[{'message':_0x29bc07['toString'](),'type':_0x32f964('0x1a4e')}];for(let _0x17367b=0x0;_0x17367b<_0x29bc07[_0x32f964('0x25f4')]['errors'][_0x32f964('0x264b')];_0x17367b+=0x1){_0x4e4e01[_0x32f964('0xfc9')]({'title':_0x29bc07[_0x32f964('0x25f4')][_0x32f964('0x61a')][_0x17367b]['type'],'msg':_0x29bc07[_0x32f964('0x25f4')][_0x32f964('0x61a')][_0x17367b]['message']});}}else _0x4e4e01['error']({'title':_0x29bc07[_0x32f964('0x52d')]?_0x32f964('0x1e21')+_0x29bc07[_0x32f964('0x52d')]+_0x32f964('0x11e1')+_0x29bc07[_0x32f964('0xe1b')]:'api.condition.save','msg':_0x29bc07[_0x32f964('0x25f4')]?JSON[_0x32f964('0xbac')](_0x29bc07[_0x32f964('0x25f4')]['message']):_0x29bc07[_0x32f964('0x1586')]()});});}function _0x420f9f(){const _0xc8df04=_0x5e8a86;_0x522aa9[_0xc8df04('0x61a')]=[],_0x23da6b[_0xc8df04('0x8ff')][_0xc8df04('0x1449')]({'id':_0x522aa9['allCondition']['id']},_0x522aa9[_0xc8df04('0x9e2')])['$promise'][_0xc8df04('0x1166')](function(_0x3a4e5e){const _0xc8d23=_0xc8df04,_0x27a6bc=_0x2cfb05()[_0xc8d23('0xc38')](_0x522aa9[_0xc8d23('0x1802')],{'id':_0x3a4e5e['id']});_0x27a6bc&&_0x2cfb05()['merge'](_0x27a6bc,_0x2cfb05()[_0xc8d23('0x1a08')](_0x3a4e5e[_0xc8d23('0x2876')](),_0x2cfb05()[_0xc8d23('0x14a4')](_0x27a6bc))),_0x4e4e01[_0xc8d23('0x103b')]({'title':_0xc8d23('0x266e'),'msg':_0x522aa9[_0xc8d23('0x9e2')][_0xc8d23('0x4f0')]?_0x522aa9[_0xc8d23('0x9e2')]['name']+_0xc8d23('0x7d'):''}),_0x1ad4b7(_0x3a4e5e);})['catch'](function(_0x2907ee){const _0x504f9a=_0xc8df04;if(_0x2907ee[_0x504f9a('0x25f4')]&&_0x2907ee[_0x504f9a('0x25f4')][_0x504f9a('0x61a')]&&_0x2907ee[_0x504f9a('0x25f4')]['errors']['length']){_0x522aa9['errors']=_0x2907ee[_0x504f9a('0x25f4')][_0x504f9a('0x61a')]||[{'message':_0x2907ee[_0x504f9a('0x1586')](),'type':_0x504f9a('0x248b')}];for(let _0x2140b2=0x0;_0x2140b2<_0x2907ee['data'][_0x504f9a('0x61a')][_0x504f9a('0x264b')];_0x2140b2++){_0x4e4e01[_0x504f9a('0xfc9')]({'title':_0x2907ee[_0x504f9a('0x25f4')][_0x504f9a('0x61a')][_0x2140b2][_0x504f9a('0x1345')],'msg':_0x2907ee['data'][_0x504f9a('0x61a')][_0x2140b2][_0x504f9a('0x1e70')]});}}else _0x4e4e01['error']({'title':_0x2907ee[_0x504f9a('0x52d')]?_0x504f9a('0x1e21')+_0x2907ee[_0x504f9a('0x52d')]+'\x20-\x20'+_0x2907ee['statusText']:'api.condition.update','msg':_0x2907ee[_0x504f9a('0x25f4')]?JSON[_0x504f9a('0xbac')](_0x2907ee[_0x504f9a('0x25f4')][_0x504f9a('0x1e70')]):_0x2907ee['toString']()});});}function _0x59727c(_0x41eefa){const _0x38bd70=_0x5e8a86;_0x522aa9[_0x38bd70('0x61a')]=[];const _0xf13fa2=_0x92acb7[_0x38bd70('0x1d26')]()[_0x38bd70('0xcdc')]('Are\x20you\x20sure?')[_0x38bd70('0xacc')](_0x38bd70('0x1d9'))[_0x38bd70('0x8e8')](_0x38bd70('0xc0'))['ok'](_0x38bd70('0x18'))[_0x38bd70('0x3f')](_0x38bd70('0x497'))['targetEvent'](_0x41eefa);_0x92acb7[_0x38bd70('0x1f80')](_0xf13fa2)[_0x38bd70('0x1166')](function(){const _0x127dfd=_0x38bd70;_0x23da6b['condition'][_0x127dfd('0x906')]({'id':_0x522aa9[_0x127dfd('0x9e2')]['id']})[_0x127dfd('0xa44')][_0x127dfd('0x1166')](function(){const _0x27fcc5=_0x127dfd;_0x2cfb05()[_0x27fcc5('0x127f')](_0x522aa9[_0x27fcc5('0x1802')],{'id':_0x522aa9[_0x27fcc5('0x9e2')]['id']}),_0x4e4e01['success']({'title':_0x27fcc5('0x1f3e'),'msg':(_0x522aa9[_0x27fcc5('0x9e2')]['name']||_0x27fcc5('0x9e2'))+_0x27fcc5('0x7cd')}),_0x1ad4b7(_0x522aa9[_0x27fcc5('0x9e2')]);})[_0x127dfd('0x1a80')](function(_0x3b634d){const _0x59c6c8=_0x127dfd;if(_0x3b634d[_0x59c6c8('0x25f4')]&&_0x3b634d['data'][_0x59c6c8('0x61a')]&&_0x3b634d[_0x59c6c8('0x25f4')]['errors'][_0x59c6c8('0x264b')]){_0x522aa9[_0x59c6c8('0x61a')]=_0x3b634d[_0x59c6c8('0x25f4')][_0x59c6c8('0x61a')]||[{'message':_0x3b634d[_0x59c6c8('0x1586')](),'type':_0x59c6c8('0x23d2')}];for(let _0xb01be3=0x0;_0xb01be3<_0x3b634d[_0x59c6c8('0x25f4')][_0x59c6c8('0x61a')][_0x59c6c8('0x264b')];_0xb01be3++){_0x4e4e01['error']({'title':_0x3b634d['data'][_0x59c6c8('0x61a')][_0xb01be3][_0x59c6c8('0x1345')],'msg':_0x3b634d[_0x59c6c8('0x25f4')][_0x59c6c8('0x61a')][_0xb01be3][_0x59c6c8('0x1e70')]});}}else _0x4e4e01['error']({'title':_0x3b634d[_0x59c6c8('0x52d')]?_0x59c6c8('0x1e21')+_0x3b634d[_0x59c6c8('0x52d')]+_0x59c6c8('0x11e1')+_0x3b634d[_0x59c6c8('0xe1b')]:_0x59c6c8('0x23d2'),'msg':_0x3b634d['data']?JSON['stringify'](_0x3b634d['data'][_0x59c6c8('0x1e70')]):_0x3b634d[_0x59c6c8('0x1e70')]||_0x3b634d['toString']()});});},function(){});}function _0x4b11bc(_0x2b08df){return _0x2b08df===null?undefined:new Date(_0x2b08df);}function _0x1ad4b7(_0x24b8dc){const _0x32f7ee=_0x5e8a86;_0x92acb7[_0x32f7ee('0x1197')](_0x24b8dc);}}const _0x41ab7b=_0x2c31c4,_0x1d6122=_0x2734b2['p']+_0x36e6f4('0x1880');_0x2715b8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x2715b8(_0x8039ab,_0x324f03,_0x49da23,_0x24ce1b,_0x26995e,_0x596969,_0x46f45e,_0x47f0bb,_0x23d49c){const _0x52ed4e=_0x36e6f4,_0x4886ef=this;_0x4886ef[_0x52ed4e('0x98')]=_0x23d49c['getCurrentUser'](),_0x4886ef[_0x52ed4e('0xe00')]={},_0x4886ef[_0x52ed4e('0x187e')]={'count':0x0,'rows':[]},_0x4886ef[_0x52ed4e('0x2502')]=[],_0x4886ef['query']={'fields':_0x52ed4e('0x28dc'),'limit':0xa,'page':0x1},_0x4886ef['fields']={'queue':_0x52ed4e('0x28ba'),'lastevent':_0x52ed4e('0x1d2c'),'routeId':_0x52ed4e('0x1aaf'),'agent':'Agent','account':_0x52ed4e('0x1758'),'interaction':'Interaction','message':_0x52ed4e('0x1720')},_0x4886ef[_0x52ed4e('0xa3')]={'abandoned':_0x52ed4e('0x135d'),'timeout':_0x52ed4e('0x1861'),'complete':_0x52ed4e('0x25af'),'rejected':_0x52ed4e('0x242a'),'called':'Ring','connect':_0x52ed4e('0x33c'),'nosuchnumber':'NoSuchNumber','busy':_0x52ed4e('0xe23'),'noanswer':_0x52ed4e('0x674'),'congestion':_0x52ed4e('0x25ac'),'agentreject':_0x52ed4e('0x2877')},_0x4886ef[_0x52ed4e('0x146d')]={'in':_0x52ed4e('0x5eb'),'out':_0x52ed4e('0x192e'),'accept':'Accepted','reject':_0x52ed4e('0x1a52')},_0x4886ef[_0x52ed4e('0xae0')]=_0x12f4cc,_0x4886ef[_0x52ed4e('0x103b')]=_0x2ea8ed,_0x4886ef['getTriggerAnyConditions']=_0x5d4d2a,_0x4886ef[_0x52ed4e('0x16e2')]=_0x1366bd,_0x4886ef[_0x52ed4e('0x2430')]=_0x49be8b,_0x4886ef['deleteConfirm']=_0x351685,_0x4886ef[_0x52ed4e('0xaf8')]=_0x2cda93,_0x4886ef[_0x52ed4e('0x170f')]=_0x52e804;function _0x12f4cc(_0x4b2867,_0x5d18b9){const _0x1d213c=_0x52ed4e;_0x4886ef[_0x1d213c('0xe00')]=_0x4b2867,_0x4886ef[_0x1d213c('0x243c')]=typeof _0x5d18b9!==_0x1d213c('0x1048')?_0x5d18b9:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4886ef[_0x1d213c('0x2218')][_0x1d213c('0x1ee5')]=_0x4886ef['trigger']['id'],_0x4886ef['query']['id']=_0x4886ef[_0x1d213c('0xe00')]['id'],_0x5d4d2a();}function _0x3b2457(){const _0x38c8eb=_0x52ed4e,_0x40cc04=_0x4886ef[_0x38c8eb('0xe00')][_0x38c8eb('0x1298')]+_0x4886ef[_0x38c8eb('0xe00')]['channel']===_0x38c8eb('0xde2')?'Websites':_0x38c8eb('0x1288'),_0xc2165a=_0x4886ef['trigger'][_0x38c8eb('0x1298')]+(_0x4886ef[_0x38c8eb('0xe00')]['channel']===_0x38c8eb('0xde2')?'Website':_0x38c8eb('0x1758'));let _0x4e6968;switch(_0x4886ef[_0x38c8eb('0xe00')][_0x38c8eb('0x1298')]){case'chat':_0x4e6968=0x1f6;break;case _0x38c8eb('0x1fc7'):_0x4e6968=0x386;break;case _0x38c8eb('0x1bfa'):_0x4e6968=0x25a;break;case _0x38c8eb('0x26c'):_0x4e6968=0x322;break;case _0x38c8eb('0x146c'):_0x4e6968=0x2be;break;case _0x38c8eb('0x116e'):_0x4e6968=0x836;break;}if(_0x23d49c[_0x38c8eb('0xe0f')]()){const _0x3bde3c=_0x4886ef[_0x38c8eb('0xe00')][_0x38c8eb('0x1298')];_0x47f0bb[_0xc2165a][_0x38c8eb('0xd83')]({'fields':'id,name','sort':'id','nolimit':_0x38c8eb('0xf3b')})[_0x38c8eb('0xa44')][_0x38c8eb('0x1166')](function(_0x645de3){const _0x3c4643=_0x38c8eb;_0x4886ef[_0x40cc04]=_0x645de3[_0x3c4643('0x269a')]||[];})[_0x38c8eb('0x1a80')](function(_0x3c9dc0){const _0x1702f5=_0x38c8eb;_0x46f45e[_0x1702f5('0xfc9')]({'title':_0x3c9dc0['status']?'API:'+_0x3c9dc0[_0x1702f5('0x52d')]+'\x20-\x20'+_0x3c9dc0['statusText']:'SYSTEM:GET_'+_0x3bde3c[_0x1702f5('0x1387')]()+_0x3bde3c==='chat'?_0x1702f5('0x14f3'):_0x1702f5('0x204d'),'msg':_0x3c9dc0[_0x1702f5('0x25f4')]?JSON[_0x1702f5('0xbac')](_0x3c9dc0[_0x1702f5('0x25f4')]):_0x3c9dc0['toString']()});});}else{const _0x19634d=_0x4886ef[_0x38c8eb('0xe00')][_0x38c8eb('0x1298')];_0x47f0bb[_0xc2165a]['get']({'fields':_0x38c8eb('0x1776'),'sort':'id','nolimit':_0x38c8eb('0xf3b')})['$promise'][_0x38c8eb('0x1166')](function(_0x44cffa){const _0x59f3e8=_0x38c8eb;_0x4886ef[_0x40cc04]=_0x44cffa[_0x59f3e8('0x269a')]||[];})['then'](function(){const _0x590ff9=_0x38c8eb;return _0x47f0bb[_0x590ff9('0x17aa')][_0x590ff9('0xd83')]({'userProfileId':_0x4886ef[_0x590ff9('0x98')][_0x590ff9('0xb86')],'sectionId':_0x4e6968})[_0x590ff9('0xa44')];})['then'](function(_0x2670ab){const _0x202ee0=_0x38c8eb,_0x296000=_0x2670ab&&_0x2670ab[_0x202ee0('0x269a')]?_0x2670ab['rows'][0x0]:null;if(!_0x296000){const _0x37ad1a=[],_0x105f16=[];_0x4886ef[_0x202ee0('0x187e')]['rows'][_0x202ee0('0x2782')](function(_0x3e5fe9){const _0xcb3cd2=_0x202ee0;if(_0x3e5fe9[_0xcb3cd2('0x22f3')]===_0xcb3cd2('0x1a32')){const _0x2ab869=_0x2cfb05()['find'](_0x4886ef[_0x40cc04],{'id':Number(_0x3e5fe9['value'])});_0x105f16[_0xcb3cd2('0x1514')](_0x2ab869);}});for(let _0x2d7972=0x0;_0x2d7972<_0x4886ef[_0x40cc04][_0x202ee0('0x264b')];_0x2d7972++){const _0x1ccb8d=_0x2cfb05()[_0x202ee0('0x1798')](_0x105f16,{'id':_0x4886ef[_0x40cc04][_0x2d7972]['id']});_0x1ccb8d&&(_0x4886ef[_0x40cc04][_0x2d7972]['canSelect']=![],_0x37ad1a[_0x202ee0('0x1514')](_0x4886ef[_0x40cc04][_0x2d7972]));}_0x4886ef[_0x40cc04]=_0x37ad1a;}else{if(!_0x296000['autoAssociation'])return _0x47f0bb[_0x202ee0('0x4b5')]['get']({'sectionId':_0x296000['id']})[_0x202ee0('0xa44')][_0x202ee0('0x1166')](function(_0x54af6f){const _0x451017=_0x202ee0,_0x571094=_0x2cfb05()['map'](_0x54af6f[_0x451017('0x269a')],function(_0x2455be){const _0x5b7ffa=_0x451017;return _0x2cfb05()['find'](_0x4886ef[_0x40cc04],{'id':_0x2455be[_0x5b7ffa('0x24e8')]});});let _0x258273=null;_0x258273=[],_0x4886ef[_0x451017('0x187e')]['rows']['forEach'](function(_0x5e93bb){const _0x33ca5a=_0x451017;if(_0x5e93bb['field']===_0x33ca5a('0x1a32')){const _0x1f40bb=_0x2cfb05()[_0x33ca5a('0xc38')](_0x4886ef[_0x40cc04],{'id':Number(_0x5e93bb[_0x33ca5a('0x18e0')])});_0x258273[_0x33ca5a('0x1514')](_0x1f40bb);}}),!_0x2cfb05()[_0x451017('0x1081')](_0x258273)&&_0x258273[_0x451017('0x2782')](function(_0x166d1b){const _0x25cd9d=_0x451017;if(!_0x2cfb05()[_0x25cd9d('0x1798')](_0x571094,['id',_0x166d1b['id']])){const _0x3b4926=_0x2cfb05()[_0x25cd9d('0xc38')](_0x4886ef[_0x40cc04],{'id':_0x166d1b['id']});_0x3b4926[_0x25cd9d('0x2378')]=![],_0x571094[_0x25cd9d('0x1514')](_0x3b4926);}}),_0x4886ef[_0x40cc04]=_0x571094;});}})['catch'](function(_0x477dac){const _0x3c021f=_0x38c8eb;_0x46f45e[_0x3c021f('0xfc9')]({'title':_0x477dac[_0x3c021f('0x52d')]?_0x3c021f('0x1e21')+_0x477dac[_0x3c021f('0x52d')]+_0x3c021f('0x11e1')+_0x477dac[_0x3c021f('0xe1b')]:_0x3c021f('0xfae')+_0x19634d[_0x3c021f('0x1387')]()+_0x19634d===_0x3c021f('0xde2')?_0x3c021f('0x14f3'):_0x3c021f('0x204d'),'msg':_0x477dac[_0x3c021f('0x25f4')]?JSON[_0x3c021f('0xbac')](_0x477dac['data']):_0x477dac[_0x3c021f('0x1586')]()});});}}function _0x5a6f00(){const _0x186878=_0x52ed4e,_0x470a86=[{'id':0x191,'type':_0x186878('0x14d8')},{'id':0x5dd,'type':_0x186878('0x587')}];let _0x487f79=null;_0x23d49c[_0x186878('0xe0f')]()?_0x47f0bb[_0x186878('0x1943')][_0x186878('0xd83')]({'fields':_0x186878('0x1c09'),'sort':_0x186878('0x4f0'),'nolimit':_0x186878('0xf3b')})['$promise'][_0x186878('0x1166')](function(_0x489652){const _0x410e1a=_0x186878;_0x4886ef[_0x410e1a('0x7a7')]=_0x489652[_0x410e1a('0x269a')]||[];})[_0x186878('0x1a80')](function(_0x5de068){const _0x51b34e=_0x186878;_0x46f45e['error']({'title':_0x5de068[_0x51b34e('0x52d')]?_0x51b34e('0x1e21')+_0x5de068[_0x51b34e('0x52d')]+_0x51b34e('0x11e1')+_0x5de068[_0x51b34e('0xe1b')]:_0x51b34e('0x250e'),'msg':_0x5de068[_0x51b34e('0x25f4')]?JSON[_0x51b34e('0xbac')](_0x5de068['data']):_0x5de068[_0x51b34e('0x1586')]()});}):_0x47f0bb[_0x186878('0x1943')]['get']({'fields':_0x186878('0x1c09'),'sort':_0x186878('0x4f0'),'nolimit':_0x186878('0xf3b')})[_0x186878('0xa44')]['then'](function(_0x10fd57){_0x487f79=_0x10fd57['rows']||[];})['then'](function(){const _0x35f512=_0x186878,_0x673703=[];for(let _0x4dcf1d=0x0;_0x4dcf1d<_0x470a86['length'];_0x4dcf1d++){_0x673703[_0x35f512('0x1514')](_0x47f0bb[_0x35f512('0x17aa')][_0x35f512('0xd83')]({'userProfileId':_0x4886ef[_0x35f512('0x98')][_0x35f512('0xb86')],'sectionId':_0x470a86[_0x4dcf1d]['id']})[_0x35f512('0xa44')]);}return _0x324f03[_0x35f512('0x2760')](_0x673703);})[_0x186878('0x1166')](function(_0x1453cc){const _0x5ef4a2=_0x186878,_0x19e348=_0x2cfb05()['map'](_0x1453cc,function(_0x4a71d7){const _0x513e06=a0_0x3f2c;return _0x4a71d7&&_0x4a71d7['rows']?_0x4a71d7[_0x513e06('0x269a')][0x0]:null;}),_0x4a0964=[];for(let _0x5bc8c1=0x0;_0x5bc8c1<_0x470a86[_0x5ef4a2('0x264b')];_0x5bc8c1++){const _0x3fef61=_0x2cfb05()['find'](_0x19e348,['sectionId',_0x470a86[_0x5bc8c1]['id']]);if(_0x3fef61){if(!_0x3fef61[_0x5ef4a2('0x1a2b')])_0x4a0964['push'](_0x47f0bb[_0x5ef4a2('0x4b5')]['get']({'sectionId':_0x3fef61['id']})['$promise']);else{const _0x38676b=[];_0x487f79[_0x5ef4a2('0x2782')](function(_0x251265){const _0x38d0c0=_0x5ef4a2;_0x251265[_0x38d0c0('0x1345')]===_0x470a86[_0x5bc8c1]['type']&&_0x38676b['push'](_0x251265);}),_0x4a0964[_0x5ef4a2('0x1514')]({'rows':_0x38676b,'count':_0x38676b[_0x5ef4a2('0x264b')]});}}}return _0x324f03['all'](_0x4a0964);})[_0x186878('0x1166')](function(_0x185239){const _0x56d510=_0x186878,_0x19cfb2=[],_0x2261cf=[];_0x4886ef[_0x56d510('0x187e')][_0x56d510('0x269a')][_0x56d510('0x2782')](function(_0x41d35c){const _0x10873c=_0x56d510;if(_0x41d35c[_0x10873c('0x22f3')]==='queue'){const _0x49cbbe=_0x2cfb05()['find'](_0x487f79,{'name':_0x41d35c[_0x10873c('0x18e0')]});_0x2261cf[_0x10873c('0x1514')](_0x49cbbe);}});for(let _0x1b4704=0x0;_0x1b4704<_0x185239['length'];_0x1b4704++){const _0x31a08c=_0x185239[_0x1b4704][_0x56d510('0x269a')]||[];_0x31a08c[_0x56d510('0x2782')](function(_0x44c74f){const _0x4c4ed7=_0x56d510;_0x19cfb2[_0x4c4ed7('0x1514')](_0x44c74f);});}!_0x2cfb05()[_0x56d510('0x1081')](_0x2261cf)&&_0x2261cf[_0x56d510('0x2782')](function(_0x413847){const _0x467b38=_0x56d510;if(!_0x2cfb05()['some'](_0x19cfb2,[_0x467b38('0x24e8'),_0x413847['id']])){const _0x515b1e=_0x2cfb05()['find'](_0x487f79,{'id':_0x413847['id']});_0x515b1e[_0x467b38('0x2378')]=![],_0x19cfb2['push'](_0x515b1e);}}),_0x4886ef['queues']=_0x19cfb2;})[_0x186878('0x1a80')](function(_0x4fd85c){const _0x383508=_0x186878;_0x46f45e['error']({'title':_0x4fd85c[_0x383508('0x52d')]?_0x383508('0x1e21')+_0x4fd85c[_0x383508('0x52d')]+_0x383508('0x11e1')+_0x4fd85c[_0x383508('0xe1b')]:'SYSTEM:GET_QUEUES','msg':_0x4fd85c[_0x383508('0x25f4')]?JSON[_0x383508('0xbac')](_0x4fd85c['data']):_0x4fd85c['toString']()});});}function _0x3c9cd3(){const _0x149c14=_0x52ed4e;_0x23d49c[_0x149c14('0xe0f')]()?_0x47f0bb['voiceExtension'][_0x149c14('0xd83')]({'fields':_0x149c14('0x27bd'),'type':'outbound','VoiceExtensionId':'null','nolimit':'true'})['$promise'][_0x149c14('0x1166')](function(_0x59bd08){const _0x4c9c62=_0x149c14;_0x4886ef[_0x4c9c62('0x2404')]=_0x59bd08[_0x4c9c62('0x269a')]||[];})[_0x149c14('0x1a80')](function(_0x2df5bb){const _0x1fe7ae=_0x149c14;_0x46f45e[_0x1fe7ae('0xfc9')]({'title':_0x2df5bb[_0x1fe7ae('0x52d')]?_0x1fe7ae('0x1e21')+_0x2df5bb['status']+_0x1fe7ae('0x11e1')+_0x2df5bb[_0x1fe7ae('0xe1b')]:_0x1fe7ae('0x261f'),'msg':_0x2df5bb[_0x1fe7ae('0x25f4')]?JSON[_0x1fe7ae('0xbac')](_0x2df5bb['data']):_0x2df5bb[_0x1fe7ae('0x1586')]()});}):_0x47f0bb[_0x149c14('0x1deb')][_0x149c14('0xd83')]({'fields':_0x149c14('0x27bd'),'type':'outbound','VoiceExtensionId':'null','nolimit':_0x149c14('0xf3b')})[_0x149c14('0xa44')][_0x149c14('0x1166')](function(_0x39501d){const _0x41e9e7=_0x149c14;_0x4886ef[_0x41e9e7('0x2404')]=_0x39501d[_0x41e9e7('0x269a')]||[];})[_0x149c14('0x1166')](function(){const _0x2e016f=_0x149c14;return _0x47f0bb[_0x2e016f('0x17aa')][_0x2e016f('0xd83')]({'userProfileId':_0x4886ef[_0x2e016f('0x98')][_0x2e016f('0xb86')],'sectionId':0x193})[_0x2e016f('0xa44')];})[_0x149c14('0x1166')](function(_0x23cfd4){const _0x52d196=_0x149c14,_0x2e8bfe=_0x23cfd4&&_0x23cfd4['rows']?_0x23cfd4[_0x52d196('0x269a')][0x0]:null;if(!_0x2e8bfe){const _0x4b42d6=[],_0x4b45d3=[];_0x4886ef[_0x52d196('0x187e')][_0x52d196('0x269a')]['forEach'](function(_0x342e83){const _0x533ff3=_0x52d196;if(_0x342e83[_0x533ff3('0x22f3')]===_0x533ff3('0x2423')){const _0x286166=_0x2cfb05()['find'](_0x4886ef[_0x533ff3('0x2404')],{'id':Number(_0x342e83[_0x533ff3('0x18e0')])});_0x4b45d3['push'](_0x286166);}});for(let _0x1464d3=0x0;_0x1464d3<_0x4886ef[_0x52d196('0x2404')][_0x52d196('0x264b')];_0x1464d3++){const _0x2be595=_0x2cfb05()[_0x52d196('0x1798')](_0x4b45d3,{'id':_0x4886ef['outboundRoutes'][_0x1464d3]['id']});_0x2be595&&(_0x4886ef[_0x52d196('0x2404')][_0x1464d3]['canSelect']=![],_0x4b42d6[_0x52d196('0x1514')](_0x4886ef[_0x52d196('0x2404')][_0x1464d3]));}_0x4886ef[_0x52d196('0x2404')]=_0x4b42d6;}else{if(!_0x2e8bfe[_0x52d196('0x1a2b')])return _0x47f0bb[_0x52d196('0x4b5')][_0x52d196('0xd83')]({'sectionId':_0x2e8bfe['id']})['$promise'][_0x52d196('0x1166')](function(_0x34c886){const _0xcaeec7=_0x52d196,_0x3621e3=_0x2cfb05()[_0xcaeec7('0x2563')](_0x34c886[_0xcaeec7('0x269a')],function(_0x443623){const _0x5c80ad=_0xcaeec7;return _0x2cfb05()[_0x5c80ad('0xc38')](_0x4886ef[_0x5c80ad('0x2404')],{'id':_0x443623['resourceId']});});let _0x4a58be=null;_0x4a58be=[],_0x4886ef[_0xcaeec7('0x187e')][_0xcaeec7('0x269a')]['forEach'](function(_0x1e9190){const _0x2e4617=_0xcaeec7;if(_0x1e9190[_0x2e4617('0x22f3')]===_0x2e4617('0x2423')){const _0x4a1e0f=_0x2cfb05()[_0x2e4617('0xc38')](_0x4886ef[_0x2e4617('0x2404')],{'id':Number(_0x1e9190[_0x2e4617('0x18e0')])});_0x4a58be[_0x2e4617('0x1514')](_0x4a1e0f);}}),!_0x2cfb05()[_0xcaeec7('0x1081')](_0x4a58be)&&_0x4a58be[_0xcaeec7('0x2782')](function(_0x5aa6b5){const _0xe74402=_0xcaeec7;if(!_0x2cfb05()[_0xe74402('0x1798')](_0x3621e3,['id',_0x5aa6b5['id']])){const _0x41d039=_0x2cfb05()[_0xe74402('0xc38')](_0x4886ef[_0xe74402('0x2404')],{'id':_0x5aa6b5['id']});_0x41d039['canSelect']=![],_0x3621e3[_0xe74402('0x1514')](_0x41d039);}}),_0x4886ef[_0xcaeec7('0x2404')]=_0x3621e3;});}})[_0x149c14('0x1a80')](function(_0xb79f25){const _0x362ed2=_0x149c14;_0x46f45e[_0x362ed2('0xfc9')]({'title':_0xb79f25[_0x362ed2('0x52d')]?_0x362ed2('0x1e21')+_0xb79f25['status']+_0x362ed2('0x11e1')+_0xb79f25['statusText']:'SYSTEM:GET_OUTBOUNDROUTES','msg':_0xb79f25['data']?JSON[_0x362ed2('0xbac')](_0xb79f25[_0x362ed2('0x25f4')]):_0xb79f25['toString']()});});}function _0x560607(){const _0x6347c3=_0x52ed4e;_0x23d49c[_0x6347c3('0xe0f')]()?_0x47f0bb[_0x6347c3('0x557')][_0x6347c3('0xd83')]({'fields':_0x6347c3('0xce1'),'sort':_0x6347c3('0x4f0'),'role':_0x6347c3('0x1eff'),'nolimit':'true'})[_0x6347c3('0xa44')][_0x6347c3('0x1166')](function(_0x57c32d){_0x4886ef['agents']=_0x57c32d['rows']||[];})['catch'](function(_0x580752){const _0x2dc242=_0x6347c3;_0x46f45e[_0x2dc242('0xfc9')]({'title':_0x580752[_0x2dc242('0x52d')]?'API:'+_0x580752[_0x2dc242('0x52d')]+_0x2dc242('0x11e1')+_0x580752[_0x2dc242('0xe1b')]:_0x2dc242('0xd4c'),'msg':_0x580752[_0x2dc242('0x25f4')]?JSON[_0x2dc242('0xbac')](_0x580752[_0x2dc242('0x25f4')]):_0x580752[_0x2dc242('0x1586')]()});}):_0x47f0bb[_0x6347c3('0x557')]['get']({'fields':_0x6347c3('0xce1'),'sort':_0x6347c3('0x4f0'),'role':_0x6347c3('0x1eff'),'nolimit':_0x6347c3('0xf3b')})[_0x6347c3('0xa44')][_0x6347c3('0x1166')](function(_0x46cbdd){const _0x663833=_0x6347c3;_0x4886ef[_0x663833('0x1f7e')]=_0x46cbdd[_0x663833('0x269a')]||[];})['then'](function(){const _0x50efd4=_0x6347c3;return _0x47f0bb[_0x50efd4('0x17aa')][_0x50efd4('0xd83')]({'userProfileId':_0x4886ef[_0x50efd4('0x98')]['userProfileId'],'sectionId':0xca})[_0x50efd4('0xa44')];})['then'](function(_0x49e6ef){const _0x2c552a=_0x6347c3,_0x245b38=_0x49e6ef&&_0x49e6ef[_0x2c552a('0x269a')]?_0x49e6ef[_0x2c552a('0x269a')][0x0]:null;if(!_0x245b38){const _0x63d51d=[],_0x1b180d=[];_0x4886ef[_0x2c552a('0x187e')]['rows']['forEach'](function(_0x365715){const _0x1e8611=_0x2c552a;if(_0x365715[_0x1e8611('0x22f3')]===_0x1e8611('0x1eff')){const _0x300c75=_0x2cfb05()[_0x1e8611('0xc38')](_0x4886ef[_0x1e8611('0x1f7e')],{'name':_0x365715['value']});_0x1b180d[_0x1e8611('0x1514')](_0x300c75);}});for(let _0x54c4b8=0x0;_0x54c4b8<_0x4886ef[_0x2c552a('0x1f7e')][_0x2c552a('0x264b')];_0x54c4b8++){const _0x28259f=_0x2cfb05()[_0x2c552a('0x1798')](_0x1b180d,{'id':_0x4886ef[_0x2c552a('0x1f7e')][_0x54c4b8]['id']});_0x28259f&&(_0x4886ef[_0x2c552a('0x1f7e')][_0x54c4b8][_0x2c552a('0x2378')]=![],_0x63d51d[_0x2c552a('0x1514')](_0x4886ef[_0x2c552a('0x1f7e')][_0x54c4b8]));}_0x4886ef['agents']=_0x63d51d;}else{if(!_0x245b38[_0x2c552a('0x1a2b')])return _0x47f0bb[_0x2c552a('0x4b5')][_0x2c552a('0xd83')]({'sectionId':_0x245b38['id']})[_0x2c552a('0xa44')][_0x2c552a('0x1166')](function(_0x5bb1c5){const _0x2fb179=_0x2c552a,_0x1dee27=_0x2cfb05()[_0x2fb179('0x2563')](_0x5bb1c5[_0x2fb179('0x269a')],function(_0x1776d2){const _0x2ff9f1=_0x2fb179;return _0x2cfb05()[_0x2ff9f1('0xc38')](_0x4886ef[_0x2ff9f1('0x1f7e')],{'id':_0x1776d2['resourceId']});});let _0x19b797=null;_0x19b797=[],_0x4886ef['triggerAnyConditions'][_0x2fb179('0x269a')][_0x2fb179('0x2782')](function(_0x150726){const _0x31d824=_0x2fb179;if(_0x150726['field']===_0x31d824('0x1eff')){const _0x3aaa44=_0x2cfb05()[_0x31d824('0xc38')](_0x4886ef['agents'],{'name':_0x150726['value']});_0x19b797[_0x31d824('0x1514')](_0x3aaa44);}}),!_0x2cfb05()[_0x2fb179('0x1081')](_0x19b797)&&_0x19b797[_0x2fb179('0x2782')](function(_0x61948f){const _0x49e344=_0x2fb179;if(!_0x2cfb05()['some'](_0x1dee27,['id',_0x61948f['id']])){const _0x2c93e2=_0x2cfb05()[_0x49e344('0xc38')](_0x4886ef[_0x49e344('0x1f7e')],{'id':_0x61948f['id']});_0x2c93e2['canSelect']=![],_0x1dee27[_0x49e344('0x1514')](_0x2c93e2);}}),_0x4886ef['agents']=_0x1dee27;});}})['catch'](function(_0xf33ba){const _0x3ec2e2=_0x6347c3;_0x46f45e[_0x3ec2e2('0xfc9')]({'title':_0xf33ba[_0x3ec2e2('0x52d')]?_0x3ec2e2('0x1e21')+_0xf33ba['status']+_0x3ec2e2('0x11e1')+_0xf33ba[_0x3ec2e2('0xe1b')]:_0x3ec2e2('0xd4c'),'msg':_0xf33ba[_0x3ec2e2('0x25f4')]?JSON[_0x3ec2e2('0xbac')](_0xf33ba[_0x3ec2e2('0x25f4')]):_0xf33ba[_0x3ec2e2('0x1586')]()});});}function _0xe8a1b4(){const _0x262411=_0x52ed4e;if(_0x4886ef[_0x262411('0xe00')]['channel']==='voice'){if(_0x2cfb05()[_0x262411('0x1798')](_0x4886ef[_0x262411('0x187e')][_0x262411('0x269a')],[_0x262411('0x22f3'),_0x262411('0x1d3e')])){if(!_0x4886ef[_0x262411('0x7a7')])_0x5a6f00();}if(_0x2cfb05()['some'](_0x4886ef[_0x262411('0x187e')][_0x262411('0x269a')],['field',_0x262411('0x2423')])){if(!_0x4886ef['outboundRoutes'])_0x3c9cd3();}if(_0x2cfb05()[_0x262411('0x1798')](_0x4886ef[_0x262411('0x187e')]['rows'],[_0x262411('0x22f3'),_0x262411('0x1eff')])){if(!_0x4886ef['agents'])_0x560607();}}else _0x3b2457();}function _0x2ea8ed(_0x55bb32){const _0x20163d=_0x52ed4e;_0x4886ef[_0x20163d('0x187e')]=_0x55bb32||{'count':0x0,'rows':[]},_0xe8a1b4();}function _0x5d4d2a(){const _0x14f515=_0x52ed4e;_0x4886ef[_0x14f515('0x2218')][_0x14f515('0x1098')]=(_0x4886ef[_0x14f515('0x2218')][_0x14f515('0x1a43')]-0x1)*_0x4886ef['query'][_0x14f515('0x163f')],_0x4886ef[_0x14f515('0x1f48')]=_0x47f0bb[_0x14f515('0xe00')][_0x14f515('0x249c')](_0x4886ef[_0x14f515('0x2218')],_0x2ea8ed)[_0x14f515('0xa44')];}function _0x1366bd(_0x27f701,_0x4697f9){const _0x45ff8e=_0x52ed4e;_0x26995e[_0x45ff8e('0x1f80')]({'controller':_0x45ff8e('0x23d6'),'controllerAs':'vm','templateUrl':_0x1d6122,'parent':angular[_0x45ff8e('0x1194')](_0x596969[_0x45ff8e('0x8d2')]),'targetEvent':_0x27f701,'clickOutsideToClose':!![],'locals':{'trigger':_0x4886ef[_0x45ff8e('0xe00')],'anyCondition':_0x4697f9,'anyConditions':_0x4886ef[_0x45ff8e('0x187e')][_0x45ff8e('0x269a')],'license':null,'setting':null,'crudPermissions':_0x4886ef['crudPermissions']}})['then'](function(_0x2cbb68){const _0x120b71=_0x45ff8e;_0x2cbb68&&(_0x4886ef[_0x120b71('0x187e')]={'count':_0x2cbb68[_0x120b71('0x264b')],'rows':_0x2cbb68},_0xe8a1b4());});}function _0x351685(_0x1f1a20,_0x1eaa78){const _0x341c01=_0x52ed4e,_0x13ed94=_0x26995e[_0x341c01('0x1d26')]()[_0x341c01('0xcdc')](_0x49da23[_0x341c01('0x25cc')]('TOOLS.NOTIFICATIONS.CONDITION_DELETE_TITLE'))[_0x341c01('0x8e8')](_0x341c01('0x13de'))[_0x341c01('0x203b')](_0x1eaa78)['ok']('OK')[_0x341c01('0x3f')](_0x49da23[_0x341c01('0x25cc')](_0x341c01('0x12a3')));_0x26995e[_0x341c01('0x1f80')](_0x13ed94)[_0x341c01('0x1166')](function(){_0x2cda93(_0x1f1a20,!![]);});}function _0x2cda93(_0x35bb41,_0x4d585e){const _0x111592=_0x52ed4e;_0x47f0bb[_0x111592('0x8ff')]['delete']({'id':_0x35bb41['id']})[_0x111592('0xa44')]['then'](function(){const _0xc8d58d=_0x111592;_0x5d4d2a(),_0x4d585e&&_0x46f45e['success']({'title':_0x49da23[_0xc8d58d('0x25cc')]('TOOLS.NOTIFICATIONS.CONDITION_DELETED_SUCCESS_TITLE')});})['catch'](function(_0x4ccf1c){const _0x20fba5=_0x111592;if(_0x4ccf1c[_0x20fba5('0x25f4')]&&_0x4ccf1c[_0x20fba5('0x25f4')][_0x20fba5('0x61a')]&&_0x4ccf1c[_0x20fba5('0x25f4')]['errors'][_0x20fba5('0x264b')]){_0x4886ef['errors']=_0x4ccf1c['data'][_0x20fba5('0x61a')]||[{'message':_0x4ccf1c['toString'](),'type':_0x20fba5('0x22a8')}];for(let _0x270b73=0x0;_0x270b73<_0x4ccf1c[_0x20fba5('0x25f4')][_0x20fba5('0x61a')][_0x20fba5('0x264b')];_0x270b73++){_0x46f45e[_0x20fba5('0xfc9')]({'title':_0x4ccf1c[_0x20fba5('0x25f4')][_0x20fba5('0x61a')][_0x270b73]['type'],'msg':_0x4ccf1c['data']['errors'][_0x270b73]['message']});}}else _0x46f45e['error']({'title':_0x4ccf1c[_0x20fba5('0x52d')]?'API:'+_0x4ccf1c[_0x20fba5('0x52d')]+_0x20fba5('0x11e1')+_0x4ccf1c[_0x20fba5('0xe1b')]:_0x20fba5('0x22a8'),'msg':_0x4ccf1c[_0x20fba5('0x25f4')]?JSON[_0x20fba5('0xbac')](_0x4ccf1c[_0x20fba5('0x25f4')][_0x20fba5('0x1e70')]):_0x4ccf1c[_0x20fba5('0x1e70')]||_0x4ccf1c[_0x20fba5('0x1586')]()});});}function _0x49be8b(){const _0x20d79=_0x52ed4e,_0x86951f=angular[_0x20d79('0x225f')](_0x4886ef[_0x20d79('0x2502')]);return _0x4886ef['selectedTriggerAnyConditions']=[],_0x86951f;}function _0x52e804(_0x5bd01e){const _0x39fd20=_0x52ed4e,_0x352571=_0x26995e[_0x39fd20('0x1d26')]()['title'](_0x49da23[_0x39fd20('0x25cc')](_0x39fd20('0x1bc9')))[_0x39fd20('0xacc')](_0x49da23[_0x39fd20('0x25cc')](_0x39fd20('0x1655'),{'total':_0x4886ef[_0x39fd20('0x2502')][_0x39fd20('0x264b')]}))['ariaLabel'](_0x39fd20('0x2be'))[_0x39fd20('0x203b')](_0x5bd01e)['ok']('OK')['cancel'](_0x49da23[_0x39fd20('0x25cc')](_0x39fd20('0x12a3')));_0x26995e[_0x39fd20('0x1f80')](_0x352571)[_0x39fd20('0x1166')](function(){const _0x3eb751=_0x39fd20;_0x4886ef[_0x3eb751('0x2502')][_0x3eb751('0x2782')](function(_0x3cfcb1){_0x2cda93(_0x3cfcb1);}),_0x4886ef[_0x3eb751('0x2502')]=[],_0x46f45e[_0x3eb751('0x103b')]({'title':_0x49da23[_0x3eb751('0x25cc')]('TOOLS.NOTIFICATIONS.CONDITIONS_DELETED_SUCCESS_TITLE')});});}let _0x3fca65=!![],_0x6e51fe=0x1;_0x8039ab[_0x52ed4e('0xe83')](_0x52ed4e('0x28b4'),function(_0x3f0a2d,_0x3e847d){const _0x2a9d7d=_0x52ed4e;_0x3fca65?_0x24ce1b(function(){_0x3fca65=![];}):(!_0x3e847d&&(_0x6e51fe=_0x4886ef[_0x2a9d7d('0x2218')]['page']),_0x3f0a2d!==_0x3e847d&&(_0x4886ef[_0x2a9d7d('0x2218')]['page']=0x1),!_0x3f0a2d&&(_0x4886ef[_0x2a9d7d('0x2218')]['page']=_0x6e51fe),_0x5d4d2a());});}const _0x2a1b57=_0x2715b8;_0x1ab77d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19b6'),_0x36e6f4('0x9e2'),_0x36e6f4('0xe00'),'api','Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x1ab77d(_0x395f9c,_0x253bc6,_0x3e7d7a,_0x4359a0,_0x9b5f77,_0x5799f9,_0xdc83dc,_0x2dfdc0,_0x18309d,_0x117e71,_0x223bc6,_0x6ec45,_0x2c084a){const _0x4e9d2c=_0x36e6f4,_0x357851=this;_0x357851[_0x4e9d2c('0x98')]=_0x117e71[_0x4e9d2c('0x26cd')](),_0x357851[_0x4e9d2c('0x9e2')]=angular['copy'](_0xdc83dc),_0x357851[_0x4e9d2c('0x19b6')]=angular['copy'](_0x5799f9),_0x357851[_0x4e9d2c('0xf8a')]=_0x6ec45,_0x357851[_0x4e9d2c('0x5c9')]=_0x223bc6,_0x357851[_0x4e9d2c('0x243c')]=_0x2c084a,_0x357851[_0x4e9d2c('0x128b')]={},_0x357851[_0x4e9d2c('0x2353')]=![],_0x357851['errors']=[],_0x357851['trigger']=angular[_0x4e9d2c('0x225f')](_0x2dfdc0);!_0x357851[_0x4e9d2c('0x9e2')]?(_0x357851[_0x4e9d2c('0x9e2')]={'operator':_0x4e9d2c('0x2147')},_0x357851[_0x4e9d2c('0x2353')]=!![]):_0x46f3f0();_0x357851[_0x4e9d2c('0x9e2')][_0x4e9d2c('0x2501')]=_0x395f9c[_0x4e9d2c('0x23f')]['id']||undefined,_0x357851['callStatuses']=[{'name':_0x4e9d2c('0x135d'),'value':'abandoned'},{'name':'Timeout','value':'timeout'},{'name':'Hangup','value':_0x4e9d2c('0x20c9')},{'name':'Reject','value':'rejected'},{'name':_0x4e9d2c('0x1a8e'),'value':_0x4e9d2c('0x239b')},{'name':'Answer','value':_0x4e9d2c('0x7bb')},{'name':_0x4e9d2c('0x1dc7'),'value':'nosuchnumber'},{'name':'Busy','value':_0x4e9d2c('0x2344')},{'name':_0x4e9d2c('0x674'),'value':_0x4e9d2c('0x24a6')},{'name':'Congestion','value':_0x4e9d2c('0x227b')},{'name':_0x4e9d2c('0x2877'),'value':'agentreject'}],_0x357851['onFieldSelection']=_0x1d5a8b,_0x357851[_0x4e9d2c('0x8b9')]=_0x3443b9,_0x357851[_0x4e9d2c('0x9f5')]=_0x193ed9,_0x357851[_0x4e9d2c('0x7a0')]=_0x51c5fe,_0x357851[_0x4e9d2c('0x24a0')]=_0x35573a;function _0x5b782a(){const _0x11e52c=_0x4e9d2c,_0x1598f0=[{'id':0x191,'type':'inbound'},{'id':0x5dd,'type':_0x11e52c('0x587')}];let _0x5ce7cc=null;_0x117e71['isAdmin']()?_0x18309d[_0x11e52c('0x1943')]['get']({'fields':_0x11e52c('0x1c09'),'sort':'name','nolimit':'true'})[_0x11e52c('0xa44')][_0x11e52c('0x1166')](function(_0x53313a){const _0x3f5b67=_0x11e52c;_0x357851[_0x3f5b67('0x7a7')]=_0x53313a[_0x3f5b67('0x269a')]||[];})[_0x11e52c('0x1a80')](function(_0xd12b8e){const _0x5baf96=_0x11e52c;_0x9b5f77[_0x5baf96('0xfc9')]({'title':_0xd12b8e['status']?_0x5baf96('0x1e21')+_0xd12b8e['status']+_0x5baf96('0x11e1')+_0xd12b8e['statusText']:_0x5baf96('0x250e'),'msg':_0xd12b8e[_0x5baf96('0x25f4')]?JSON[_0x5baf96('0xbac')](_0xd12b8e[_0x5baf96('0x25f4')]):_0xd12b8e[_0x5baf96('0x1586')]()});}):_0x18309d[_0x11e52c('0x1943')][_0x11e52c('0xd83')]({'fields':'id,name,type','sort':'name','nolimit':_0x11e52c('0xf3b')})[_0x11e52c('0xa44')][_0x11e52c('0x1166')](function(_0x77f740){const _0x10834c=_0x11e52c;_0x5ce7cc=_0x77f740[_0x10834c('0x269a')]||[];})[_0x11e52c('0x1166')](function(){const _0xd1ac72=_0x11e52c,_0x43b198=[];for(let _0x4a451b=0x0;_0x4a451b<_0x1598f0[_0xd1ac72('0x264b')];_0x4a451b++){_0x43b198[_0xd1ac72('0x1514')](_0x18309d[_0xd1ac72('0x17aa')][_0xd1ac72('0xd83')]({'userProfileId':_0x357851[_0xd1ac72('0x98')][_0xd1ac72('0xb86')],'sectionId':_0x1598f0[_0x4a451b]['id']})['$promise']);}return _0x3e7d7a[_0xd1ac72('0x2760')](_0x43b198);})[_0x11e52c('0x1166')](function(_0xc71ec2){const _0x4b79ec=_0x11e52c,_0x4fc8ab=_0x2cfb05()[_0x4b79ec('0x2563')](_0xc71ec2,function(_0x315649){const _0x5cc698=_0x4b79ec;return _0x315649&&_0x315649['rows']?_0x315649[_0x5cc698('0x269a')][0x0]:null;}),_0x23aa08=[];for(let _0x1a4894=0x0;_0x1a4894<_0x1598f0['length'];_0x1a4894++){const _0x1cb623=_0x2cfb05()[_0x4b79ec('0xc38')](_0x4fc8ab,['sectionId',_0x1598f0[_0x1a4894]['id']]);if(_0x1cb623){if(!_0x1cb623[_0x4b79ec('0x1a2b')])_0x23aa08[_0x4b79ec('0x1514')](_0x18309d['userProfileResource']['get']({'sectionId':_0x1cb623['id']})[_0x4b79ec('0xa44')]);else{const _0x125a41=[];_0x5ce7cc['forEach'](function(_0x434693){const _0x7856b8=_0x4b79ec;_0x434693[_0x7856b8('0x1345')]===_0x1598f0[_0x1a4894]['type']&&_0x125a41['push'](_0x434693);}),_0x23aa08['push']({'rows':_0x125a41,'count':_0x125a41[_0x4b79ec('0x264b')]});}}}return _0x3e7d7a[_0x4b79ec('0x2760')](_0x23aa08);})[_0x11e52c('0x1166')](function(_0x57caf7){const _0x36dfc6=_0x11e52c,_0x11a31e=[],_0xbf0fc4=[];_0x357851[_0x36dfc6('0x1323')][_0x36dfc6('0x269a')][_0x36dfc6('0x2782')](function(_0x1664ed){const _0x31dddd=_0x36dfc6;if(_0x1664ed['field']===_0x31dddd('0x1d3e')){const _0x2dcf58=_0x2cfb05()[_0x31dddd('0xc38')](_0x5ce7cc,{'name':_0x1664ed[_0x31dddd('0x18e0')]});_0xbf0fc4[_0x31dddd('0x1514')](_0x2dcf58);}});for(let _0x526a85=0x0;_0x526a85<_0x57caf7['length'];_0x526a85++){const _0x14059e=_0x57caf7[_0x526a85][_0x36dfc6('0x269a')]||[];_0x14059e[_0x36dfc6('0x2782')](function(_0x4c4739){const _0x2b3c8d=_0x36dfc6;_0x11a31e[_0x2b3c8d('0x1514')](_0x4c4739);});}!_0x2cfb05()[_0x36dfc6('0x1081')](_0xbf0fc4)&&_0xbf0fc4[_0x36dfc6('0x2782')](function(_0x507451){const _0x505028=_0x36dfc6;if(!_0x2cfb05()['some'](_0x11a31e,['resourceId',_0x507451['id']])){const _0x252f76=_0x2cfb05()['find'](_0x5ce7cc,{'id':_0x507451['id']});_0x252f76[_0x505028('0x2378')]=![],_0x11a31e['push'](_0x252f76);}}),_0x357851['queues']=_0x11a31e;})['catch'](function(_0x2b97eb){const _0x4abbda=_0x11e52c;_0x9b5f77[_0x4abbda('0xfc9')]({'title':_0x2b97eb[_0x4abbda('0x52d')]?'API:'+_0x2b97eb['status']+_0x4abbda('0x11e1')+_0x2b97eb[_0x4abbda('0xe1b')]:'SYSTEM:GET_QUEUES','msg':_0x2b97eb[_0x4abbda('0x25f4')]?JSON[_0x4abbda('0xbac')](_0x2b97eb['data']):_0x2b97eb['toString']()});});}function _0x4efb41(){const _0x1a02d4=_0x4e9d2c;_0x117e71[_0x1a02d4('0xe0f')]()?_0x18309d[_0x1a02d4('0x1deb')]['get']({'fields':_0x1a02d4('0x27bd'),'type':_0x1a02d4('0x587'),'VoiceExtensionId':_0x1a02d4('0x15d7'),'nolimit':_0x1a02d4('0xf3b')})[_0x1a02d4('0xa44')][_0x1a02d4('0x1166')](function(_0x44590e){const _0x9cb58d=_0x1a02d4;_0x357851[_0x9cb58d('0x2404')]=_0x44590e[_0x9cb58d('0x269a')]||[];})[_0x1a02d4('0x1a80')](function(_0x5ca01b){const _0x494d0c=_0x1a02d4;_0x9b5f77[_0x494d0c('0xfc9')]({'title':_0x5ca01b[_0x494d0c('0x52d')]?'API:'+_0x5ca01b[_0x494d0c('0x52d')]+'\x20-\x20'+_0x5ca01b['statusText']:'SYSTEM:GET_OUTBOUNDROUTES','msg':_0x5ca01b[_0x494d0c('0x25f4')]?JSON[_0x494d0c('0xbac')](_0x5ca01b[_0x494d0c('0x25f4')]):_0x5ca01b[_0x494d0c('0x1586')]()});}):_0x18309d[_0x1a02d4('0x1deb')][_0x1a02d4('0xd83')]({'fields':_0x1a02d4('0x27bd'),'type':_0x1a02d4('0x587'),'VoiceExtensionId':_0x1a02d4('0x15d7'),'nolimit':'true'})[_0x1a02d4('0xa44')][_0x1a02d4('0x1166')](function(_0x35fb90){const _0x2df3cc=_0x1a02d4;_0x357851[_0x2df3cc('0x2404')]=_0x35fb90[_0x2df3cc('0x269a')]||[];})[_0x1a02d4('0x1166')](function(){const _0x58bc45=_0x1a02d4;return _0x18309d['userProfileSection'][_0x58bc45('0xd83')]({'userProfileId':_0x357851[_0x58bc45('0x98')][_0x58bc45('0xb86')],'sectionId':0x193})[_0x58bc45('0xa44')];})[_0x1a02d4('0x1166')](function(_0x4e58d2){const _0x2f7afd=_0x1a02d4,_0x516dc8=_0x4e58d2&&_0x4e58d2[_0x2f7afd('0x269a')]?_0x4e58d2[_0x2f7afd('0x269a')][0x0]:null;if(!_0x516dc8){const _0x74c16c=[],_0x2992e5=[];_0x357851['triggerallConditions']['rows'][_0x2f7afd('0x2782')](function(_0x6b102a){const _0x5bc3cf=_0x2f7afd;if(_0x6b102a[_0x5bc3cf('0x22f3')]===_0x5bc3cf('0x2423')){const _0x50426a=_0x2cfb05()[_0x5bc3cf('0xc38')](_0x357851[_0x5bc3cf('0x2404')],{'id':Number(_0x6b102a[_0x5bc3cf('0x18e0')])});_0x2992e5['push'](_0x50426a);}});for(let _0x41dd50=0x0;_0x41dd50<_0x357851[_0x2f7afd('0x2404')][_0x2f7afd('0x264b')];_0x41dd50++){const _0x319ded=_0x2cfb05()[_0x2f7afd('0x1798')](_0x2992e5,{'id':_0x357851[_0x2f7afd('0x2404')][_0x41dd50]['id']});_0x319ded&&(_0x357851['outboundRoutes'][_0x41dd50][_0x2f7afd('0x2378')]=![],_0x74c16c[_0x2f7afd('0x1514')](_0x357851[_0x2f7afd('0x2404')][_0x41dd50]));}_0x357851['outboundRoutes']=_0x74c16c;}else{if(!_0x516dc8[_0x2f7afd('0x1a2b')])return _0x18309d[_0x2f7afd('0x4b5')][_0x2f7afd('0xd83')]({'sectionId':_0x516dc8['id']})[_0x2f7afd('0xa44')][_0x2f7afd('0x1166')](function(_0x120b37){const _0x2a9535=_0x2f7afd,_0x79a705=_0x2cfb05()['map'](_0x120b37[_0x2a9535('0x269a')],function(_0x2df29a){const _0x255b62=_0x2a9535;return _0x2cfb05()[_0x255b62('0xc38')](_0x357851[_0x255b62('0x2404')],{'id':_0x2df29a[_0x255b62('0x24e8')]});});let _0x145236=null;_0x145236=[],_0x357851[_0x2a9535('0x1323')][_0x2a9535('0x269a')][_0x2a9535('0x2782')](function(_0x44d18c){const _0x3d8863=_0x2a9535;if(_0x44d18c[_0x3d8863('0x22f3')]===_0x3d8863('0x2423')){const _0x5b4640=_0x2cfb05()[_0x3d8863('0xc38')](_0x357851[_0x3d8863('0x2404')],{'id':Number(_0x44d18c['value'])});_0x145236[_0x3d8863('0x1514')](_0x5b4640);}}),!_0x2cfb05()['isEmpty'](_0x145236)&&_0x145236[_0x2a9535('0x2782')](function(_0x4ffd0f){const _0x139ebe=_0x2a9535;if(!_0x2cfb05()[_0x139ebe('0x1798')](_0x79a705,['id',_0x4ffd0f['id']])){const _0x4c8b18=_0x2cfb05()['find'](_0x357851[_0x139ebe('0x2404')],{'id':_0x4ffd0f['id']});_0x4c8b18[_0x139ebe('0x2378')]=![],_0x79a705['push'](_0x4c8b18);}}),_0x357851[_0x2a9535('0x2404')]=_0x79a705;});}})[_0x1a02d4('0x1a80')](function(_0xfa80b8){const _0x15081d=_0x1a02d4;_0x9b5f77[_0x15081d('0xfc9')]({'title':_0xfa80b8[_0x15081d('0x52d')]?_0x15081d('0x1e21')+_0xfa80b8[_0x15081d('0x52d')]+_0x15081d('0x11e1')+_0xfa80b8[_0x15081d('0xe1b')]:_0x15081d('0x261f'),'msg':_0xfa80b8[_0x15081d('0x25f4')]?JSON[_0x15081d('0xbac')](_0xfa80b8[_0x15081d('0x25f4')]):_0xfa80b8[_0x15081d('0x1586')]()});});}function _0x3d8619(){const _0x334855=_0x4e9d2c;_0x117e71[_0x334855('0xe0f')]()?_0x18309d[_0x334855('0x557')][_0x334855('0xd83')]({'fields':_0x334855('0xce1'),'sort':_0x334855('0x4f0'),'role':_0x334855('0x1eff'),'nolimit':_0x334855('0xf3b')})[_0x334855('0xa44')][_0x334855('0x1166')](function(_0x353dd2){const _0x1a3d0c=_0x334855;_0x357851[_0x1a3d0c('0x1f7e')]=_0x353dd2[_0x1a3d0c('0x269a')]||[];})['catch'](function(_0x52be51){const _0x3d4714=_0x334855;_0x9b5f77['error']({'title':_0x52be51[_0x3d4714('0x52d')]?'API:'+_0x52be51[_0x3d4714('0x52d')]+_0x3d4714('0x11e1')+_0x52be51[_0x3d4714('0xe1b')]:_0x3d4714('0xd4c'),'msg':_0x52be51['data']?JSON[_0x3d4714('0xbac')](_0x52be51['data']):_0x52be51['toString']()});}):_0x18309d[_0x334855('0x557')][_0x334855('0xd83')]({'fields':_0x334855('0xce1'),'sort':_0x334855('0x4f0'),'role':_0x334855('0x1eff'),'nolimit':_0x334855('0xf3b')})[_0x334855('0xa44')][_0x334855('0x1166')](function(_0x2d6ea0){_0x357851['agents']=_0x2d6ea0['rows']||[];})[_0x334855('0x1166')](function(){const _0x482880=_0x334855;return _0x18309d[_0x482880('0x17aa')][_0x482880('0xd83')]({'userProfileId':_0x357851[_0x482880('0x98')][_0x482880('0xb86')],'sectionId':0xca})[_0x482880('0xa44')];})[_0x334855('0x1166')](function(_0x45765a){const _0x1d2b24=_0x334855,_0x164a4c=_0x45765a&&_0x45765a[_0x1d2b24('0x269a')]?_0x45765a['rows'][0x0]:null;if(!_0x164a4c){const _0x13e5aa=[],_0x681162=[];_0x357851[_0x1d2b24('0x1323')][_0x1d2b24('0x269a')]['forEach'](function(_0x322c57){const _0x44885b=_0x1d2b24;if(_0x322c57['field']===_0x44885b('0x1eff')){const _0x165455=_0x2cfb05()[_0x44885b('0xc38')](_0x357851[_0x44885b('0x1f7e')],{'name':_0x322c57[_0x44885b('0x18e0')]});_0x681162[_0x44885b('0x1514')](_0x165455);}});for(let _0xf1f5e9=0x0;_0xf1f5e9<_0x357851[_0x1d2b24('0x1f7e')]['length'];_0xf1f5e9++){const _0x1a21f9=_0x2cfb05()[_0x1d2b24('0x1798')](_0x681162,{'id':_0x357851['agents'][_0xf1f5e9]['id']});_0x1a21f9&&(_0x357851['agents'][_0xf1f5e9][_0x1d2b24('0x2378')]=![],_0x13e5aa[_0x1d2b24('0x1514')](_0x357851[_0x1d2b24('0x1f7e')][_0xf1f5e9]));}_0x357851['agents']=_0x13e5aa;}else{if(!_0x164a4c['autoAssociation'])return _0x18309d[_0x1d2b24('0x4b5')]['get']({'sectionId':_0x164a4c['id']})[_0x1d2b24('0xa44')][_0x1d2b24('0x1166')](function(_0x5432d5){const _0x2b19f5=_0x1d2b24,_0x1f8def=_0x2cfb05()[_0x2b19f5('0x2563')](_0x5432d5[_0x2b19f5('0x269a')],function(_0x4d298a){const _0x28ffb0=_0x2b19f5;return _0x2cfb05()[_0x28ffb0('0xc38')](_0x357851[_0x28ffb0('0x1f7e')],{'id':_0x4d298a[_0x28ffb0('0x24e8')]});});let _0x44f264=null;_0x44f264=[],_0x357851[_0x2b19f5('0x1323')][_0x2b19f5('0x269a')][_0x2b19f5('0x2782')](function(_0x3444c6){const _0x71ced3=_0x2b19f5;if(_0x3444c6[_0x71ced3('0x22f3')]===_0x71ced3('0x1eff')){const _0x45aeee=_0x2cfb05()['find'](_0x357851[_0x71ced3('0x1f7e')],{'name':_0x3444c6[_0x71ced3('0x18e0')]});_0x44f264[_0x71ced3('0x1514')](_0x45aeee);}}),!_0x2cfb05()[_0x2b19f5('0x1081')](_0x44f264)&&_0x44f264[_0x2b19f5('0x2782')](function(_0x87a250){const _0x3fcff1=_0x2b19f5;if(!_0x2cfb05()['some'](_0x1f8def,['id',_0x87a250['id']])){const _0x1e5f3b=_0x2cfb05()['find'](_0x357851[_0x3fcff1('0x1f7e')],{'id':_0x87a250['id']});_0x1e5f3b[_0x3fcff1('0x2378')]=![],_0x1f8def[_0x3fcff1('0x1514')](_0x1e5f3b);}}),_0x357851[_0x2b19f5('0x1f7e')]=_0x1f8def;});}})['catch'](function(_0xe77884){const _0x421438=_0x334855;_0x9b5f77['error']({'title':_0xe77884[_0x421438('0x52d')]?_0x421438('0x1e21')+_0xe77884[_0x421438('0x52d')]+'\x20-\x20'+_0xe77884[_0x421438('0xe1b')]:'SYSTEM:GET_AGENTS','msg':_0xe77884['data']?JSON[_0x421438('0xbac')](_0xe77884['data']):_0xe77884[_0x421438('0x1586')]()});});}function _0x1e4a24(){const _0x2febe2=_0x4e9d2c,_0x42fe35=_0x357851['trigger']['channel']+(_0x357851[_0x2febe2('0xe00')][_0x2febe2('0x1298')]===_0x2febe2('0xde2')?_0x2febe2('0x13b6'):_0x2febe2('0x1758'));let _0x4a4410;switch(_0x357851[_0x2febe2('0xe00')][_0x2febe2('0x1298')]){case _0x2febe2('0xde2'):_0x4a4410=0x1f6;break;case _0x2febe2('0x1fc7'):_0x4a4410=0x386;break;case _0x2febe2('0x1bfa'):_0x4a4410=0x25a;break;case _0x2febe2('0x26c'):_0x4a4410=0x322;break;case _0x2febe2('0x146c'):_0x4a4410=0x2be;break;case _0x2febe2('0x116e'):_0x4a4410=0x836;break;}if(_0x117e71[_0x2febe2('0xe0f')]()){const _0x5f3590=_0x357851[_0x2febe2('0xe00')][_0x2febe2('0x1298')];_0x18309d[_0x42fe35][_0x2febe2('0xd83')]({'fields':_0x2febe2('0x1776'),'sort':'id','nolimit':_0x2febe2('0xf3b')})[_0x2febe2('0xa44')][_0x2febe2('0x1166')](function(_0x31223f){const _0x330834=_0x2febe2;_0x357851[_0x330834('0x1a91')]=_0x31223f[_0x330834('0x269a')]||[];})['catch'](function(_0x5c9097){const _0x2cdd70=_0x2febe2;_0x9b5f77[_0x2cdd70('0xfc9')]({'title':_0x5c9097[_0x2cdd70('0x52d')]?_0x2cdd70('0x1e21')+_0x5c9097[_0x2cdd70('0x52d')]+_0x2cdd70('0x11e1')+_0x5c9097['statusText']:'SYSTEM:GET_'+_0x5f3590[_0x2cdd70('0x1387')]()+_0x5f3590==='chat'?_0x2cdd70('0x14f3'):'ACCOUNTS','msg':_0x5c9097[_0x2cdd70('0x25f4')]?JSON['stringify'](_0x5c9097[_0x2cdd70('0x25f4')]):_0x5c9097['toString']()});});}else _0x18309d[_0x42fe35][_0x2febe2('0xd83')]({'fields':_0x2febe2('0x1776'),'sort':'id','nolimit':_0x2febe2('0xf3b')})[_0x2febe2('0xa44')][_0x2febe2('0x1166')](function(_0x101606){const _0x25657d=_0x2febe2;_0x357851[_0x25657d('0x1a91')]=_0x101606['rows']||[];})[_0x2febe2('0x1166')](function(){const _0xadd105=_0x2febe2;return _0x18309d[_0xadd105('0x17aa')][_0xadd105('0xd83')]({'userProfileId':_0x357851[_0xadd105('0x98')][_0xadd105('0xb86')],'sectionId':_0x4a4410})[_0xadd105('0xa44')];})['then'](function(_0x306b4f){const _0x522d6c=_0x2febe2,_0x489520=_0x306b4f&&_0x306b4f[_0x522d6c('0x269a')]?_0x306b4f[_0x522d6c('0x269a')][0x0]:null;if(!_0x489520){const _0x48935d=[],_0x500209=[];_0x357851['triggerallConditions']['rows'][_0x522d6c('0x2782')](function(_0x42dfeb){const _0x1b0665=_0x522d6c;if(_0x42dfeb[_0x1b0665('0x22f3')]===_0x1b0665('0x1a32')){const _0x46d31b=_0x2cfb05()[_0x1b0665('0xc38')](_0x357851[_0x1b0665('0x1a91')],{'id':Number(_0x42dfeb[_0x1b0665('0x18e0')])});_0x500209[_0x1b0665('0x1514')](_0x46d31b);}});for(let _0x35a58b=0x0;_0x35a58b<_0x357851[_0x522d6c('0x1a91')]['length'];_0x35a58b++){const _0x4ec819=_0x2cfb05()[_0x522d6c('0x1798')](_0x500209,{'id':_0x357851[_0x522d6c('0x1a91')][_0x35a58b]['id']});_0x4ec819&&(_0x357851[_0x522d6c('0x1a91')][_0x35a58b][_0x522d6c('0x2378')]=![],_0x48935d[_0x522d6c('0x1514')](_0x357851[_0x522d6c('0x1a91')][_0x35a58b]));}_0x357851[_0x522d6c('0x1a91')]=_0x48935d;}else{if(!_0x489520['autoAssociation'])return _0x18309d[_0x522d6c('0x4b5')]['get']({'sectionId':_0x489520['id']})[_0x522d6c('0xa44')][_0x522d6c('0x1166')](function(_0x4c7eb8){const _0x26aa49=_0x522d6c,_0x269791=_0x2cfb05()[_0x26aa49('0x2563')](_0x4c7eb8[_0x26aa49('0x269a')],function(_0x4f37f1){const _0x3f8479=_0x26aa49;return _0x2cfb05()['find'](_0x357851[_0x3f8479('0x1a91')],{'id':_0x4f37f1[_0x3f8479('0x24e8')]});});let _0x444ce8=null;_0x444ce8=[],_0x357851['triggerallConditions'][_0x26aa49('0x269a')]['forEach'](function(_0x3d77d3){const _0x3df6e6=_0x26aa49;if(_0x3d77d3[_0x3df6e6('0x22f3')]==='account'){const _0x3b4ccf=_0x2cfb05()[_0x3df6e6('0xc38')](_0x357851[_0x3df6e6('0x1a91')],{'id':Number(_0x3d77d3[_0x3df6e6('0x18e0')])});_0x444ce8[_0x3df6e6('0x1514')](_0x3b4ccf);}}),!_0x2cfb05()['isEmpty'](_0x444ce8)&&_0x444ce8[_0x26aa49('0x2782')](function(_0x4d60c7){const _0x185da7=_0x26aa49;if(!_0x2cfb05()['some'](_0x269791,['id',_0x4d60c7['id']])){const _0x3ade57=_0x2cfb05()[_0x185da7('0xc38')](_0x357851['accounts'],{'id':_0x4d60c7['id']});_0x3ade57[_0x185da7('0x2378')]=![],_0x269791[_0x185da7('0x1514')](_0x3ade57);}}),_0x357851[_0x26aa49('0x1a91')]=_0x269791;});}})[_0x2febe2('0x1a80')](function(_0x1d1958){const _0x188d32=_0x2febe2,_0x372f02=_0x357851[_0x188d32('0xe00')][_0x188d32('0x1298')];_0x9b5f77[_0x188d32('0xfc9')]({'title':_0x1d1958['status']?_0x188d32('0x1e21')+_0x1d1958[_0x188d32('0x52d')]+_0x188d32('0x11e1')+_0x1d1958[_0x188d32('0xe1b')]:_0x188d32('0xfae')+_0x372f02[_0x188d32('0x1387')]()+_0x372f02===_0x188d32('0xde2')?'WEBSITES':'ACCOUNTS','msg':_0x1d1958[_0x188d32('0x25f4')]?JSON[_0x188d32('0xbac')](_0x1d1958['data']):_0x1d1958[_0x188d32('0x1586')]()});});}function _0x46f3f0(){const _0x24c37f=_0x4e9d2c;switch(_0x357851['allCondition'][_0x24c37f('0x22f3')]){case'queue':if(!_0x357851[_0x24c37f('0x7a7')])_0x5b782a();break;case'routeId':if(!_0x357851['outboundRoutes'])_0x4efb41();break;case _0x24c37f('0x1eff'):if(!_0x357851[_0x24c37f('0x1f7e')])_0x3d8619();break;case _0x24c37f('0x1a32'):_0x1e4a24();break;}}function _0x1d5a8b(){_0x46f3f0();}function _0x3443b9(){const _0x3aa0c5=_0x4e9d2c;_0x357851[_0x3aa0c5('0x61a')]=[],_0x18309d['trigger'][_0x3aa0c5('0x452')]({'id':_0x395f9c[_0x3aa0c5('0x23f')]['id']},_0x357851[_0x3aa0c5('0x9e2')])[_0x3aa0c5('0xa44')]['then'](function(_0x4f92ac){const _0x181665=_0x3aa0c5;_0x357851[_0x181665('0x19b6')][_0x181665('0x2450')](_0x4f92ac['toJSON']()),_0x9b5f77[_0x181665('0x103b')]({'title':_0x4359a0['instant'](_0x181665('0x24'))}),_0x35573a(_0x357851[_0x181665('0x19b6')]);})['catch'](function(_0xdc7ef5){const _0x1a9804=_0x3aa0c5;if(_0xdc7ef5[_0x1a9804('0x25f4')]&&_0xdc7ef5[_0x1a9804('0x25f4')][_0x1a9804('0x61a')]&&_0xdc7ef5[_0x1a9804('0x25f4')][_0x1a9804('0x61a')][_0x1a9804('0x264b')]){_0x357851[_0x1a9804('0x61a')]=_0xdc7ef5[_0x1a9804('0x25f4')][_0x1a9804('0x61a')]||[{'message':_0xdc7ef5[_0x1a9804('0x1586')](),'type':'api.condition.save'}];for(let _0x3f6751=0x0;_0x3f6751<_0xdc7ef5[_0x1a9804('0x25f4')]['errors'][_0x1a9804('0x264b')];_0x3f6751+=0x1){_0x9b5f77[_0x1a9804('0xfc9')]({'title':_0xdc7ef5['data']['errors'][_0x3f6751][_0x1a9804('0x1345')],'msg':_0xdc7ef5['data'][_0x1a9804('0x61a')][_0x3f6751][_0x1a9804('0x1e70')]});}}else _0x9b5f77['error']({'title':_0xdc7ef5['status']?_0x1a9804('0x1e21')+_0xdc7ef5[_0x1a9804('0x52d')]+'\x20-\x20'+_0xdc7ef5[_0x1a9804('0xe1b')]:_0x1a9804('0x1a4e'),'msg':_0xdc7ef5[_0x1a9804('0x25f4')]?JSON[_0x1a9804('0xbac')](_0xdc7ef5[_0x1a9804('0x25f4')][_0x1a9804('0x1e70')]):_0xdc7ef5[_0x1a9804('0x1586')]()});});}function _0x193ed9(){const _0x4317eb=_0x4e9d2c;_0x357851[_0x4317eb('0x61a')]=[],_0x18309d[_0x4317eb('0x8ff')][_0x4317eb('0x1449')]({'id':_0x357851[_0x4317eb('0x9e2')]['id']},_0x357851[_0x4317eb('0x9e2')])[_0x4317eb('0xa44')][_0x4317eb('0x1166')](function(){const _0x24b3de=_0x4317eb;_0x357851[_0x24b3de('0x19b6')]=_0x2cfb05()[_0x24b3de('0x2563')](_0x357851[_0x24b3de('0x19b6')],function(_0x266bc6){const _0x50913c=_0x24b3de;if(_0x266bc6['id']===_0x357851[_0x50913c('0x9e2')]['id'])return _0x357851[_0x50913c('0x9e2')];else return _0x266bc6;}),_0x9b5f77[_0x24b3de('0x103b')]({'title':_0x4359a0[_0x24b3de('0x25cc')](_0x24b3de('0x2c9'))}),_0x35573a(_0x357851[_0x24b3de('0x19b6')]);})[_0x4317eb('0x1a80')](function(_0x2f2f78){const _0x233c15=_0x4317eb;if(_0x2f2f78['data']&&_0x2f2f78['data'][_0x233c15('0x61a')]&&_0x2f2f78[_0x233c15('0x25f4')][_0x233c15('0x61a')][_0x233c15('0x264b')]){_0x357851[_0x233c15('0x61a')]=_0x2f2f78[_0x233c15('0x25f4')]['errors']||[{'message':_0x2f2f78[_0x233c15('0x1586')](),'type':_0x233c15('0x248b')}];for(let _0xade119=0x0;_0xade119<_0x2f2f78[_0x233c15('0x25f4')][_0x233c15('0x61a')][_0x233c15('0x264b')];_0xade119++){_0x9b5f77[_0x233c15('0xfc9')]({'title':_0x2f2f78['data'][_0x233c15('0x61a')][_0xade119]['type'],'msg':_0x2f2f78[_0x233c15('0x25f4')]['errors'][_0xade119][_0x233c15('0x1e70')]});}}else _0x9b5f77['error']({'title':_0x2f2f78['status']?_0x233c15('0x1e21')+_0x2f2f78[_0x233c15('0x52d')]+_0x233c15('0x11e1')+_0x2f2f78['statusText']:'api.condition.update','msg':_0x2f2f78[_0x233c15('0x25f4')]?JSON[_0x233c15('0xbac')](_0x2f2f78[_0x233c15('0x25f4')][_0x233c15('0x1e70')]):_0x2f2f78['toString']()});});}function _0x51c5fe(_0x3ddc3b){const _0x3673fb=_0x4e9d2c;_0x357851[_0x3673fb('0x61a')]=[];const _0x3a09fc=_0x253bc6['confirm']({'skipHide':!![]})['title'](_0x4359a0[_0x3673fb('0x25cc')]('TOOLS.NOTIFICATIONS.CONDITION_DELETE_TITLE'))[_0x3673fb('0x8e8')](_0x3673fb('0x13de'))['ok'](_0x4359a0[_0x3673fb('0x25cc')](_0x3673fb('0xa68')))[_0x3673fb('0x3f')](_0x4359a0[_0x3673fb('0x25cc')](_0x3673fb('0x12a3')))[_0x3673fb('0x203b')](_0x3ddc3b);_0x253bc6[_0x3673fb('0x1f80')](_0x3a09fc)['then'](function(){const _0x2cdb0c=_0x3673fb;_0x18309d[_0x2cdb0c('0x8ff')][_0x2cdb0c('0x906')]({'id':_0x357851[_0x2cdb0c('0x9e2')]['id']})['$promise']['then'](function(){const _0x5866fb=_0x2cdb0c;_0x357851['allConditions']=_0x2cfb05()['filter'](_0x357851['allConditions'],function(_0x471bbe){return _0x471bbe['id']!==_0x357851['allCondition']['id'];}),_0x9b5f77[_0x5866fb('0x103b')]({'title':_0x4359a0['instant'](_0x5866fb('0x287a'))}),_0x35573a(_0x357851[_0x5866fb('0x19b6')]);})[_0x2cdb0c('0x1a80')](function(_0x1a4f37){const _0x10732c=_0x2cdb0c;if(_0x1a4f37[_0x10732c('0x25f4')]&&_0x1a4f37['data'][_0x10732c('0x61a')]&&_0x1a4f37[_0x10732c('0x25f4')][_0x10732c('0x61a')][_0x10732c('0x264b')]){_0x357851['errors']=_0x1a4f37[_0x10732c('0x25f4')][_0x10732c('0x61a')]||[{'message':_0x1a4f37[_0x10732c('0x1586')](),'type':'api.condition.delete'}];for(let _0x2061ea=0x0;_0x2061ea<_0x1a4f37[_0x10732c('0x25f4')][_0x10732c('0x61a')][_0x10732c('0x264b')];_0x2061ea++){_0x9b5f77['error']({'title':_0x1a4f37[_0x10732c('0x25f4')][_0x10732c('0x61a')][_0x2061ea][_0x10732c('0x1345')],'msg':_0x1a4f37['data']['errors'][_0x2061ea][_0x10732c('0x1e70')]});}}else _0x9b5f77[_0x10732c('0xfc9')]({'title':_0x1a4f37[_0x10732c('0x52d')]?_0x10732c('0x1e21')+_0x1a4f37[_0x10732c('0x52d')]+'\x20-\x20'+_0x1a4f37[_0x10732c('0xe1b')]:_0x10732c('0x23d2'),'msg':_0x1a4f37[_0x10732c('0x25f4')]?JSON[_0x10732c('0xbac')](_0x1a4f37[_0x10732c('0x25f4')][_0x10732c('0x1e70')]):_0x1a4f37[_0x10732c('0x1e70')]||_0x1a4f37[_0x10732c('0x1586')]()});});},function(){});}function _0x35573a(_0x18eaff){const _0x4d8348=_0x4e9d2c;_0x253bc6[_0x4d8348('0x1197')](_0x18eaff);}}const _0x4d80e6=_0x1ab77d;_0x522e23[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x586'),'license',_0x36e6f4('0xf8a'),'api',_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0xe00'),_0x36e6f4('0x17aa')];function _0x522e23(_0x255b4c,_0x11d302,_0x5d37a2,_0x1f9dc4,_0x55a131,_0x3a4f45,_0x51d649,_0x1bcb7e,_0x4421fd){const _0x283dcf=_0x36e6f4,_0x308168=this;_0x308168[_0x283dcf('0x98')]=_0x51d649[_0x283dcf('0x26cd')](),_0x308168[_0x283dcf('0x5c9')]=_0x5d37a2,_0x308168['setting']=_0x1f9dc4,_0x308168[_0x283dcf('0xe00')]=_0x1bcb7e||_0x255b4c[_0x283dcf('0x23f')][_0x283dcf('0xe00')]||{},_0x308168[_0x283dcf('0x2669')]=_0x255b4c['params'][_0x283dcf('0xbe3')]||0x0;_0x255b4c[_0x283dcf('0x23f')][_0x283dcf('0x243c')]?_0x308168['crudPermissions']=_0x255b4c[_0x283dcf('0x23f')][_0x283dcf('0x243c')]:(_0x308168['userProfileSection']=_0x4421fd&&_0x4421fd['count']==0x1?_0x4421fd[_0x283dcf('0x269a')][0x0]:null,_0x308168[_0x283dcf('0x243c')]=_0x51d649[_0x283dcf('0xd87')](_0x308168[_0x283dcf('0x17aa')]?_0x308168[_0x283dcf('0x17aa')][_0x283dcf('0x243c')]:null));_0x308168[_0x283dcf('0x7f7')]=_0x3e2ac2,_0x308168[_0x283dcf('0x1c16')]=_0x31437a;function _0x3e2ac2(){const _0x4bb0c8=_0x283dcf;_0x255b4c['go'](_0x4bb0c8('0x1e20'),{},{'reload':_0x4bb0c8('0x1e20')});}function _0x31437a(){const _0x5052b6=_0x283dcf;_0x55a131[_0x5052b6('0xe00')][_0x5052b6('0x1449')]({'id':_0x308168[_0x5052b6('0xe00')]['id']},_0x308168['trigger'])[_0x5052b6('0xa44')][_0x5052b6('0x1166')](function(){const _0x3fa5a3=_0x5052b6;_0x3a4f45[_0x3fa5a3('0x103b')]({'title':_0x11d302[_0x3fa5a3('0x25cc')](_0x3fa5a3('0x1e4c'))});})['catch'](function(_0x548e95){const _0x134b95=_0x5052b6;_0x3a4f45[_0x134b95('0xfc9')]({'title':_0x548e95[_0x134b95('0x52d')]?_0x134b95('0x1e21')+_0x548e95[_0x134b95('0x52d')]+'\x20-\x20'+_0x548e95['statusText']:_0x134b95('0x22a8'),'msg':_0x548e95[_0x134b95('0x25f4')]?JSON[_0x134b95('0xbac')](_0x548e95[_0x134b95('0x25f4')]):_0x548e95[_0x134b95('0x1586')]()});});}}const _0x4e0631=_0x522e23,_0x24d736=_0x2734b2['p']+_0x36e6f4('0x1f8d');_0x188272[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),'$translate','triggers',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x188272(_0x3deb98,_0x5519a1,_0x179fa2,_0x3eb988,_0x120dc6,_0x4aac63,_0x46c41c,_0x5b1af7,_0xa3a08c,_0x512506,_0x443e13,_0x3c4bca,_0x9fd4b8,_0x2249a1){const _0x57afcd=_0x36e6f4,_0x26deff=this;_0x26deff[_0x57afcd('0x5c9')]=_0x9fd4b8,_0x26deff[_0x57afcd('0xf8a')]=_0x2249a1,_0x26deff[_0x57afcd('0x98')]=_0x3c4bca[_0x57afcd('0x26cd')](),_0x26deff['triggers']=_0x46c41c||{'count':0x0,'rows':[]},_0x26deff['userProfile']=_0x5b1af7,_0x26deff['userProfileSection']=_0xa3a08c&&_0xa3a08c[_0x57afcd('0x240f')]==0x1?_0xa3a08c[_0x57afcd('0x269a')][0x0]:null,_0x26deff[_0x57afcd('0x243c')]=_0x3c4bca[_0x57afcd('0xd87')](_0x26deff[_0x57afcd('0x17aa')]?_0x26deff['userProfileSection'][_0x57afcd('0x243c')]:null),_0x26deff[_0x57afcd('0x143d')]=[],_0x26deff[_0x57afcd('0x2218')]={'fields':_0x57afcd('0x13a9'),'sort':_0x57afcd('0x14dc'),'limit':0xa,'page':0x1},_0x26deff[_0x57afcd('0x1db4')]=_0x2e812d,_0x26deff[_0x57afcd('0xb50')]=_0x4f03d7,_0x26deff[_0x57afcd('0x103b')]=_0x3967bf,_0x26deff[_0x57afcd('0x1d82')]=_0x3ee9a9,_0x26deff[_0x57afcd('0x8d8')]=_0x28965c,_0x26deff[_0x57afcd('0x10b1')]=_0xf662f3,_0x26deff[_0x57afcd('0x23b6')]=_0x4056a4,_0x26deff[_0x57afcd('0x1a88')]=_0x2a136b,_0x26deff[_0x57afcd('0x1b9c')]=_0x4e69a2;function _0x2e812d(_0x3954e9){const _0x1e356c=_0x57afcd;_0x5519a1['go']('app.tools.triggers.edit',{'id':_0x3954e9['id'],'trigger':_0x3954e9,'crudPermissions':_0x26deff[_0x1e356c('0x243c')]});}function _0x4f03d7(_0x5ca717,_0x12a6e9){const _0x47f6cc=_0x57afcd;if(_0x26deff['crudPermissions'][_0x47f6cc('0x914')]||_0x26deff[_0x47f6cc('0x243c')]['canDelete']&&!_0x26deff['crudPermissions']['canEdit']){_0x2e812d(_0x12a6e9);return;}_0x179fa2[_0x47f6cc('0x1f80')]({'controller':_0x47f6cc('0x1af1'),'controllerAs':'vm','templateUrl':_0x24d736,'parent':angular[_0x47f6cc('0x1194')](_0x3eb988[_0x47f6cc('0x8d2')]),'targetEvent':_0x5ca717,'clickOutsideToClose':!![],'locals':{'trigger':_0x12a6e9,'triggers':_0x26deff[_0x47f6cc('0x1991')]['rows'],'license':_0x26deff[_0x47f6cc('0x5c9')],'setting':_0x26deff[_0x47f6cc('0xf8a')],'crudPermissions':_0x26deff['crudPermissions']}})[_0x47f6cc('0x1166')](function(_0x572a80){const _0x2bc355=_0x47f6cc;_0x572a80&&(_0x26deff[_0x2bc355('0x1991')]={'count':_0x572a80[_0x2bc355('0x264b')],'rows':_0x572a80});});}function _0x3967bf(_0x5c06f8){const _0x3fb4fb=_0x57afcd;_0x26deff[_0x3fb4fb('0x1991')]=_0x5c06f8||{'count':0x0,'rows':[]};}function _0x3ee9a9(){const _0x478de1=_0x57afcd;_0x26deff[_0x478de1('0x2218')][_0x478de1('0x1098')]=(_0x26deff[_0x478de1('0x2218')][_0x478de1('0x1a43')]-0x1)*_0x26deff[_0x478de1('0x2218')][_0x478de1('0x163f')],_0x3c4bca['isAdmin']()?_0x26deff[_0x478de1('0x1f48')]=_0x512506[_0x478de1('0xe00')][_0x478de1('0xd83')](_0x26deff[_0x478de1('0x2218')],_0x3967bf)[_0x478de1('0xa44')]:(_0x26deff[_0x478de1('0x2218')]['id']=_0x26deff[_0x478de1('0x7f')]['id'],_0x26deff[_0x478de1('0x2218')]['section']='Triggers',_0x26deff['promise']=_0x512506[_0x478de1('0x7f')][_0x478de1('0x263a')](_0x26deff[_0x478de1('0x2218')],_0x3967bf)[_0x478de1('0xa44')]);}function _0x28965c(_0x388f29,_0x4a50e5){const _0x37b79b=_0x57afcd,_0x27cfdb=_0x179fa2['confirm']()[_0x37b79b('0xcdc')](_0x4aac63[_0x37b79b('0x25cc')](_0x37b79b('0x5b9')))[_0x37b79b('0xacc')](_0x4aac63[_0x37b79b('0x25cc')](_0x37b79b('0x2523'),{'name':_0x388f29[_0x37b79b('0x4f0')]}))[_0x37b79b('0x8e8')](_0x37b79b('0x235c'))[_0x37b79b('0x203b')](_0x4a50e5)['ok']('OK')[_0x37b79b('0x3f')](_0x4aac63[_0x37b79b('0x25cc')](_0x37b79b('0x12a3')));_0x179fa2[_0x37b79b('0x1f80')](_0x27cfdb)['then'](function(){_0x7886a4(_0x388f29,!![]);});}function _0x7886a4(_0x4684a0,_0x12764e){const _0x5048fa=_0x57afcd;_0x512506[_0x5048fa('0xe00')][_0x5048fa('0x906')]({'id':_0x4684a0['id']})[_0x5048fa('0xa44')][_0x5048fa('0x1166')](function(){const _0x2dec80=_0x5048fa;_0x3ee9a9(),_0x12764e&&_0x443e13[_0x2dec80('0x103b')]({'title':_0x4aac63['instant'](_0x2dec80('0x56d'))});})['catch'](function(_0x57803a){const _0x23d75e=_0x5048fa;if(_0x57803a['data']&&_0x57803a[_0x23d75e('0x25f4')][_0x23d75e('0x61a')]&&_0x57803a[_0x23d75e('0x25f4')][_0x23d75e('0x61a')][_0x23d75e('0x264b')]){_0x26deff[_0x23d75e('0x61a')]=_0x57803a['data']['errors']||[{'message':_0x57803a['toString'](),'type':_0x23d75e('0x8b7')}];for(let _0x4984bf=0x0;_0x4984bf<_0x57803a[_0x23d75e('0x25f4')][_0x23d75e('0x61a')]['length'];_0x4984bf++){_0x443e13[_0x23d75e('0xfc9')]({'title':_0x57803a[_0x23d75e('0x25f4')][_0x23d75e('0x61a')][_0x4984bf]['type'],'msg':_0x57803a['data']['errors'][_0x4984bf][_0x23d75e('0x1e70')]});}}else _0x443e13['error']({'title':_0x57803a[_0x23d75e('0x52d')]?'API:'+_0x57803a[_0x23d75e('0x52d')]+_0x23d75e('0x11e1')+_0x57803a['statusText']:'SYSTEM:DELETEtrigger','msg':_0x57803a[_0x23d75e('0x25f4')]?JSON[_0x23d75e('0xbac')](_0x57803a[_0x23d75e('0x25f4')]['message']):_0x57803a[_0x23d75e('0x1e70')]||_0x57803a[_0x23d75e('0x1586')]()});});}function _0xf662f3(){const _0x55760f=_0x57afcd,_0x2a3ab0=angular['copy'](_0x26deff['selectedTriggers']);return _0x26deff[_0x55760f('0x143d')]=[],_0x2a3ab0;}function _0x4056a4(_0x32e0a6){const _0x2b5d3c=_0x57afcd,_0x1608b5=_0x179fa2[_0x2b5d3c('0x1d26')]()[_0x2b5d3c('0xcdc')](_0x4aac63[_0x2b5d3c('0x25cc')](_0x2b5d3c('0xb03')))['content'](_0x4aac63[_0x2b5d3c('0x25cc')]('TOOLS.NOTIFICATIONS.TRIGGERS_DELETE_MESSAGE',{'total':_0x26deff[_0x2b5d3c('0x143d')][_0x2b5d3c('0x264b')]}))['ariaLabel'](_0x2b5d3c('0x7c3'))[_0x2b5d3c('0x203b')](_0x32e0a6)['ok']('OK')[_0x2b5d3c('0x3f')](_0x4aac63[_0x2b5d3c('0x25cc')](_0x2b5d3c('0x12a3')));_0x179fa2[_0x2b5d3c('0x1f80')](_0x1608b5)[_0x2b5d3c('0x1166')](function(){const _0x38479c=_0x2b5d3c;_0x26deff[_0x38479c('0x143d')]['forEach'](function(_0x18e394){_0x7886a4(_0x18e394);}),_0x26deff[_0x38479c('0x143d')]=[],_0x443e13[_0x38479c('0x103b')]({'title':_0x4aac63[_0x38479c('0x25cc')](_0x38479c('0x118f'))});});}function _0x2a136b(){const _0x9603f4=_0x57afcd;_0x26deff[_0x9603f4('0x143d')]=[];}function _0x4e69a2(){const _0x269928=_0x57afcd;_0x26deff[_0x269928('0x143d')]=_0x26deff['triggers']['rows'];}let _0x52fef0=!![],_0x5e14f3=0x1;_0x3deb98[_0x57afcd('0xe83')]('vm.query.filter',function(_0x18c1d5,_0x128873){const _0x127d79=_0x57afcd;_0x52fef0?_0x120dc6(function(){_0x52fef0=![];}):(!_0x128873&&(_0x5e14f3=_0x26deff[_0x127d79('0x2218')][_0x127d79('0x1a43')]),_0x18c1d5!==_0x128873&&(_0x26deff[_0x127d79('0x2218')]['page']=0x1),!_0x18c1d5&&(_0x26deff[_0x127d79('0x2218')][_0x127d79('0x1a43')]=_0x5e14f3),_0x3ee9a9());});}const _0x34481b=_0x188272;_0x546885[_0x36e6f4('0x1294')]=['$stateProvider'];function _0x546885(_0xdd0cf3){const _0x1e814b=_0x36e6f4;_0xdd0cf3[_0x1e814b('0x63f')](_0x1e814b('0x1e20'),{'url':_0x1e814b('0x20a9'),'views':{'content@app':{'templateUrl':_0x5a911c,'controller':_0x1e814b('0x785')}},'resolve':{'triggers':[_0x1e814b('0x1fbc'),'Auth',function(_0x303a65,_0x3c4c81){const _0x46ed93=_0x1e814b;return _0x3c4c81[_0x46ed93('0x1ac6')](_0x46ed93('0xa7c'))?_0x303a65[_0x46ed93('0x18af')](_0x46ed93('0x1fd7'),{'fields':'createdAt,updatedAt,id,name,channel,status,description','sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x303a65[_0x46ed93('0x18af')](_0x46ed93('0x17c4'),{'id':_0x3c4c81['getCurrentUser']()[_0x46ed93('0xb86')],'section':_0x46ed93('0x10f4'),'fields':'createdAt,updatedAt,id,name,channel,status,description','sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x1e814b('0x21ef'),function(_0x4db53e,_0x2a20c7){const _0x2f5781=_0x1e814b;return _0x2a20c7['hasRole']('admin')?null:_0x4db53e['resolve'](_0x2f5781('0x697'),{'fields':_0x2f5781('0x686'),'id':_0x2a20c7[_0x2f5781('0x26cd')]()[_0x2f5781('0xb86')]});}],'userProfileSection':[_0x1e814b('0x1fbc'),_0x1e814b('0x21ef'),function(_0x503abe,_0x2bae7a){const _0x5bdae9=_0x1e814b;return _0x2bae7a[_0x5bdae9('0x1ac6')](_0x5bdae9('0xa7c'))?null:_0x503abe[_0x5bdae9('0x18af')](_0x5bdae9('0xaf'),{'fields':_0x5bdae9('0xe26'),'userProfileId':_0x2bae7a[_0x5bdae9('0x26cd')]()[_0x5bdae9('0xb86')],'sectionId':0x3f2});}]},'authenticate':!![],'permissionId':0x3f2,'bodyClass':'tools'})[_0x1e814b('0x63f')]('app.tools.triggers.edit',{'url':_0x1e814b('0x2233'),'params':{'trigger':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x1ba183,'controller':_0x1e814b('0x15fb')}},'resolve':{'trigger':[_0x1e814b('0x1fbc'),'$stateParams',function(_0x1478f2,_0x155eb7){const _0x27ac06=_0x1e814b;return _0x1478f2['resolve'](_0x27ac06('0x1fd7'),{'fields':'createdAt,updatedAt,id,name,channel,status,description','id':_0x155eb7['id']});}],'userProfileSection':[_0x1e814b('0x1fbc'),_0x1e814b('0x21ef'),function(_0x5f1149,_0xd2538f){const _0x5ef78b=_0x1e814b;return _0x5f1149['resolve'](_0x5ef78b('0xaf'),{'fields':_0x5ef78b('0xe26'),'userProfileId':_0xd2538f[_0x5ef78b('0x26cd')]()['userProfileId'],'sectionId':0x3f2});}]},'authenticate':!![],'permissionId':0x3f2,'bodyClass':'tools'});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x1e20'),[])[_0x36e6f4('0xe11')](_0x546885)['controller'](_0x36e6f4('0x1af1'),_0x5b32c5)[_0x36e6f4('0x75e')]('TriggerActionsController',_0x91845d)['controller']('CreateOrEditActionDialogController',_0x24e012)['controller'](_0x36e6f4('0xcb7'),_0x13229a)[_0x36e6f4('0x75e')](_0x36e6f4('0x1d0a'),_0x41ab7b)[_0x36e6f4('0x75e')](_0x36e6f4('0xfce'),_0x2a1b57)['controller'](_0x36e6f4('0x23d6'),_0x4d80e6)[_0x36e6f4('0x75e')]('TriggerController',_0x4e0631)[_0x36e6f4('0x75e')](_0x36e6f4('0x284f'),_0x34481b);const _0x13cb55=_0x2734b2['p']+'src/js/modules/main/apps/tools/views/cannedAnswers/cannedAnswers.html/cannedAnswers.html',_0x670f00=_0x2734b2['p']+'src/js/modules/main/apps/tools/views/customDashboards/customDashboards.html/customDashboards.html',_0x424c0b=_0x2734b2['p']+_0x36e6f4('0x1c68'),_0x3cae5c=_0x2734b2['p']+_0x36e6f4('0x72e'),_0x20e5fd=_0x2734b2['p']+'src/js/modules/main/apps/tools/views/intervals/edit/view.html/view.html',_0x2842e9=_0x2734b2['p']+_0x36e6f4('0x8ba'),_0x5bb3d4=_0x2734b2['p']+_0x36e6f4('0x183c'),_0x329e81=_0x2734b2['p']+_0x36e6f4('0x1909'),_0x2f2ab8=_0x2734b2['p']+_0x36e6f4('0x1fcd'),_0x4882dd=_0x2734b2['p']+_0x36e6f4('0x1f68'),_0x140d71=_0x2734b2['p']+_0x36e6f4('0x2009'),_0x5bde5a=_0x2734b2['p']+_0x36e6f4('0x8ee'),_0x54906c=_0x2734b2['p']+_0x36e6f4('0x2436'),_0x1292e7=_0x2734b2['p']+'src/js/modules/main/apps/tools/views/cannedAnswers/create/dialog.html/dialog.html';_0x4002ec['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x2684'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting'];function _0x4002ec(_0x54a092,_0x45f87a,_0xfd4bdd,_0x5ac7e2,_0x5b3bcc,_0x2f31a2,_0x5918bf,_0x58556e,_0x545d0b,_0x1accc8,_0x2b826e,_0x243caf,_0x1d32da,_0x2bae04,_0x324ec9,_0x3bb1ed,_0x1583af){const _0x2ee114=_0x36e6f4,_0x2cf2c2=this;_0x2cf2c2[_0x2ee114('0x5c9')]=_0x3bb1ed,_0x2cf2c2['setting']=_0x1583af,_0x2cf2c2['currentUser']=_0x324ec9[_0x2ee114('0x26cd')](),_0x2cf2c2['cannedAnswers']=_0x545d0b||{'count':0x0,'rows':[]},_0x2cf2c2['userProfile']=_0x1accc8,_0x2cf2c2[_0x2ee114('0x17aa')]=_0x2b826e&&_0x2b826e['count']==0x1?_0x2b826e[_0x2ee114('0x269a')][0x0]:null,_0x2cf2c2[_0x2ee114('0x243c')]=_0x324ec9[_0x2ee114('0xd87')](_0x2cf2c2['userProfileSection']?_0x2cf2c2[_0x2ee114('0x17aa')][_0x2ee114('0x243c')]:null),_0x2cf2c2[_0x2ee114('0x916')]=_0x2ee114('0x2684'),_0x2cf2c2[_0x2ee114('0xef5')]='',_0x2cf2c2['listOrderAsc']=null,_0x2cf2c2['selectedCannedAnswers']=[],_0x2cf2c2[_0x2ee114('0x2218')]={'fields':_0x2ee114('0x1b4'),'sort':_0x2ee114('0x14dc'),'MailAccountId':_0x2ee114('0x15d7'),'FaxAccountId':_0x2ee114('0x15d7'),'SmsAccountId':_0x2ee114('0x15d7'),'OpenchannelAccountId':_0x2ee114('0x15d7'),'ChatWebsiteId':_0x2ee114('0x15d7'),'limit':0xa,'page':0x1},_0x2cf2c2[_0x2ee114('0x1f8e')]=_0xfadb8f,_0x2cf2c2['deleteconfirm']=_0x647738,_0x2cf2c2[_0x2ee114('0x103b')]=_0x24ac0a,_0x2cf2c2['getCannedAnswers']=_0x40906b,_0x2cf2c2[_0x2ee114('0xe4f')]=_0x37baca,_0x2cf2c2[_0x2ee114('0x1f27')]=_0x3e069e,_0x2cf2c2[_0x2ee114('0xa8c')]=_0x24ceed,_0x2cf2c2[_0x2ee114('0x166b')]=_0xda5882,_0x2cf2c2[_0x2ee114('0x7b4')]=_0x52bd4a,_0x2cf2c2[_0x2ee114('0x1b24')]=_0x4ecf62;function _0xfadb8f(_0x51eb6d,_0xa82a92){const _0xd980d3=_0x2ee114;_0x5b3bcc[_0xd980d3('0x1f80')]({'controller':'CreateOrEditCannedAnswerDialogController','controllerAs':'vm','templateUrl':_0x1292e7,'parent':angular['element'](_0x2f31a2[_0xd980d3('0x8d2')]),'targetEvent':_0xa82a92,'clickOutsideToClose':!![],'locals':{'cannedAnswer':_0x51eb6d,'cannedAnswers':_0x2cf2c2[_0xd980d3('0x2684')]['rows'],'license':_0x2cf2c2[_0xd980d3('0x5c9')],'setting':null,'crudPermissions':_0x2cf2c2[_0xd980d3('0x243c')]}});}function _0x647738(_0x552f1d,_0x52a4f6){const _0x13b3e8=_0x2ee114,_0x24afe3=_0x5b3bcc[_0x13b3e8('0x1d26')]()[_0x13b3e8('0xcdc')](_0x13b3e8('0x288d')+_0x2cfb05()['startCase']('cannedAnswer')+'?')[_0x13b3e8('0xf3c')](_0x13b3e8('0x12b5')+(_0x552f1d[_0x13b3e8('0x4f0')]||'cannedAnswer')+_0x13b3e8('0xace')+_0x13b3e8('0x3f3'))[_0x13b3e8('0x8e8')](_0x13b3e8('0x11de'))[_0x13b3e8('0x203b')](_0x52a4f6)['ok']('OK')[_0x13b3e8('0x3f')](_0x13b3e8('0x2d3'));_0x5b3bcc[_0x13b3e8('0x1f80')](_0x24afe3)['then'](function(){_0x3e069e(_0x552f1d);},function(){const _0x58c695=_0x13b3e8;console[_0x58c695('0x455')](_0x58c695('0x2d3'));});}let _0x110d96=!![],_0x15991d=0x1;_0x54a092[_0x2ee114('0xe83')]('vm.query.filter',function(_0x336cfb,_0x19a3cd){const _0x33b338=_0x2ee114;_0x110d96?_0x5918bf(function(){_0x110d96=![];}):(!_0x19a3cd&&(_0x15991d=_0x2cf2c2[_0x33b338('0x2218')][_0x33b338('0x1a43')]),_0x336cfb!==_0x19a3cd&&(_0x2cf2c2[_0x33b338('0x2218')][_0x33b338('0x1a43')]=0x1),!_0x336cfb&&(_0x2cf2c2['query'][_0x33b338('0x1a43')]=_0x15991d),_0x2cf2c2[_0x33b338('0x20d2')]());});function _0x24ac0a(_0x3caf15){_0x2cf2c2['cannedAnswers']=_0x3caf15||{'count':0x0,'rows':[]};}function _0x40906b(){const _0x17172d=_0x2ee114;_0x2cf2c2['query'][_0x17172d('0x1098')]=(_0x2cf2c2[_0x17172d('0x2218')][_0x17172d('0x1a43')]-0x1)*_0x2cf2c2[_0x17172d('0x2218')][_0x17172d('0x163f')],_0x324ec9[_0x17172d('0x1ac6')]('admin')?_0x2cf2c2[_0x17172d('0x1f48')]=_0x243caf['cannedAnswer']['get'](_0x2cf2c2[_0x17172d('0x2218')],_0x24ac0a)['$promise']:(_0x2cf2c2['query']['id']=_0x2cf2c2['userProfile']['id'],_0x2cf2c2[_0x17172d('0x2218')]['section']=_0x17172d('0x160f'),_0x2cf2c2[_0x17172d('0x1f48')]=_0x243caf[_0x17172d('0x7f')]['getResources'](_0x2cf2c2[_0x17172d('0x2218')],_0x24ac0a)[_0x17172d('0xa44')]);}function _0x37baca(_0x4f2f14,_0x1585c0){const _0x328f5a=_0x2ee114;_0x5b3bcc[_0x328f5a('0x1f80')]({'controller':_0x328f5a('0x1948'),'controllerAs':'vm','templateUrl':_0x1292e7,'parent':angular[_0x328f5a('0x1194')](_0x2f31a2['body']),'targetEvent':_0x4f2f14,'clickOutsideToClose':!![],'locals':{'cannedAnswer':_0x1585c0,'cannedAnswers':_0x2cf2c2[_0x328f5a('0x2684')][_0x328f5a('0x269a')],'license':_0x2cf2c2[_0x328f5a('0x5c9')],'setting':_0x2cf2c2[_0x328f5a('0xf8a')],'crudPermissions':_0x2cf2c2[_0x328f5a('0x243c')]}});}function _0x3e069e(_0x165fc5){const _0x421742=_0x2ee114;_0x243caf['cannedAnswer'][_0x421742('0x906')]({'id':_0x165fc5['id']})[_0x421742('0xa44')][_0x421742('0x1166')](function(){const _0x5eab0f=_0x421742;_0x2cfb05()[_0x5eab0f('0x127f')](_0x2cf2c2[_0x5eab0f('0x2684')][_0x5eab0f('0x269a')],{'id':_0x165fc5['id']}),_0x2cf2c2[_0x5eab0f('0x2684')][_0x5eab0f('0x240f')]-=0x1,!_0x2cf2c2[_0x5eab0f('0x2684')]['rows']['length']&&_0x2cf2c2[_0x5eab0f('0x20d2')](),_0x2bae04[_0x5eab0f('0x103b')]({'title':_0x2cfb05()[_0x5eab0f('0xb35')](_0x5eab0f('0x1f98'))+_0x5eab0f('0x2b6'),'msg':_0x165fc5[_0x5eab0f('0x4f0')]?_0x165fc5[_0x5eab0f('0x4f0')]+_0x5eab0f('0x7cd'):''});})['catch'](function(_0xc899dc){const _0x542bdc=_0x421742;if(_0xc899dc[_0x542bdc('0x25f4')]&&_0xc899dc['data'][_0x542bdc('0x61a')]&&_0xc899dc[_0x542bdc('0x25f4')]['errors'][_0x542bdc('0x264b')]){_0x2cf2c2[_0x542bdc('0x61a')]=_0xc899dc[_0x542bdc('0x25f4')][_0x542bdc('0x61a')]||[{'message':_0xc899dc[_0x542bdc('0x1586')](),'type':_0x542bdc('0xf4b')}];for(let _0x319bcb=0x0;_0x319bcb<_0xc899dc[_0x542bdc('0x25f4')][_0x542bdc('0x61a')][_0x542bdc('0x264b')];_0x319bcb++){_0x2bae04[_0x542bdc('0xfc9')]({'title':_0xc899dc[_0x542bdc('0x25f4')]['errors'][_0x319bcb]['type'],'msg':_0xc899dc[_0x542bdc('0x25f4')][_0x542bdc('0x61a')][_0x319bcb][_0x542bdc('0x1e70')]});}}else _0x2bae04[_0x542bdc('0xfc9')]({'title':_0xc899dc[_0x542bdc('0x52d')]?_0x542bdc('0x1e21')+_0xc899dc[_0x542bdc('0x52d')]+_0x542bdc('0x11e1')+_0xc899dc[_0x542bdc('0xe1b')]:_0x542bdc('0xf4b'),'msg':_0xc899dc[_0x542bdc('0x25f4')]?JSON[_0x542bdc('0xbac')](_0xc899dc[_0x542bdc('0x25f4')][_0x542bdc('0x1e70')]):_0xc899dc[_0x542bdc('0x1e70')]||_0xc899dc[_0x542bdc('0x1586')]()});});}function _0x24ceed(){const _0x34f63a=_0x2ee114,_0x1a48d5=angular[_0x34f63a('0x225f')](_0x2cf2c2[_0x34f63a('0x1d59')]);return _0x2cf2c2[_0x34f63a('0x1d59')]=[],_0x1a48d5;}function _0xda5882(_0x1c04f0){const _0x5bca56=_0x2ee114,_0x20ca8c=_0x5b3bcc[_0x5bca56('0x1d26')]()[_0x5bca56('0xcdc')](_0x5bca56('0x1bc8'))[_0x5bca56('0xf3c')](_0x5bca56('0x12b5')+_0x2cf2c2[_0x5bca56('0x1d59')][_0x5bca56('0x264b')]+_0x5bca56('0x196d')+_0x5bca56('0x3f3'))[_0x5bca56('0x8e8')](_0x5bca56('0x15b0'))[_0x5bca56('0x203b')](_0x1c04f0)['ok']('OK')[_0x5bca56('0x3f')](_0x5bca56('0x2d3'));_0x5b3bcc[_0x5bca56('0x1f80')](_0x20ca8c)[_0x5bca56('0x1166')](function(){const _0x3d3b5d=_0x5bca56;_0x2cf2c2[_0x3d3b5d('0x1d59')][_0x3d3b5d('0x2782')](function(_0x41dc97){_0x3e069e(_0x41dc97);}),_0x2cf2c2['selectedCannedAnswers']=[];});}function _0x52bd4a(){const _0x32ac26=_0x2ee114;_0x2cf2c2[_0x32ac26('0x1d59')]=[];}function _0x4ecf62(){const _0x559ccc=_0x2ee114;_0x2cf2c2[_0x559ccc('0x1d59')]=_0x2cf2c2[_0x559ccc('0x2684')]['rows'];}}const _0x5e85d2=_0x4002ec;_0x4f4748[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0x2684'),_0x36e6f4('0x1b1f'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x4f4748(_0x37fdd8,_0x4fa35e,_0x1cbfef,_0x3ed8dc,_0x2645a1,_0xfd38c6,_0x2e74ad,_0x37b5a1,_0x97daa,_0x385fda,_0x162b2f,_0x386f3e,_0x5be834,_0x1e368e){const _0x430a29=_0x36e6f4,_0x4984f9=this;_0x4984f9[_0x430a29('0x98')]=_0x162b2f[_0x430a29('0x26cd')](),_0x4984f9[_0x430a29('0x61a')]=[],_0x4984f9[_0x430a29('0xf8a')]=_0x5be834,_0x4984f9['license']=_0x386f3e,_0x4984f9[_0x430a29('0x243c')]=_0x1e368e,_0x4984f9[_0x430a29('0x128b')]={},_0x4984f9[_0x430a29('0x2900')]=_0x4984f9[_0x430a29('0xf8a')]&&_0x4984f9[_0x430a29('0xf8a')][_0x430a29('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4984f9[_0x430a29('0xcdc')]=_0x430a29('0x99e'),_0x4984f9[_0x430a29('0x1b1f')]=angular[_0x430a29('0x225f')](_0x97daa),_0x4984f9[_0x430a29('0x2684')]=_0x37b5a1,_0x4984f9[_0x430a29('0x997')]=![];!_0x4984f9['cannedAnswer']&&(_0x4984f9[_0x430a29('0x1b1f')]={},_0x4984f9[_0x430a29('0xcdc')]='TOOLS.NEW_CANNEDANSWER',_0x4984f9['newCannedAnswer']=!![]);_0x4984f9['addNewCannedAnswer']=_0x9682f4,_0x4984f9[_0x430a29('0x1599')]=_0x3a29e7,_0x4984f9[_0x430a29('0x1f27')]=_0x4070fe,_0x4984f9[_0x430a29('0x1a9c')]=_0xf9fedc,_0x4984f9[_0x430a29('0x24a0')]=_0x182c09;function _0x9682f4(){const _0x5d59bb=_0x430a29;_0x4984f9[_0x5d59bb('0x61a')]=[],_0x385fda['cannedAnswer'][_0x5d59bb('0x9cc')](_0x4984f9['cannedAnswer'])['$promise'][_0x5d59bb('0x1166')](function(_0x2ce8df){const _0x592c1d=_0x5d59bb;_0x4984f9[_0x592c1d('0x2684')][_0x592c1d('0x2450')](_0x2ce8df['toJSON']()),_0x2e74ad[_0x592c1d('0x103b')]({'title':_0x592c1d('0x23e5'),'msg':_0x4984f9['cannedAnswer']['name']?_0x4984f9['cannedAnswer'][_0x592c1d('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x182c09(_0x2ce8df);})[_0x5d59bb('0x1a80')](function(_0xa485d7){const _0x578570=_0x5d59bb;if(_0xa485d7[_0x578570('0x25f4')]&&_0xa485d7['data']['errors']&&_0xa485d7['data']['errors'][_0x578570('0x264b')]){_0x4984f9[_0x578570('0x61a')]=_0xa485d7[_0x578570('0x25f4')][_0x578570('0x61a')]||[{'message':_0xa485d7[_0x578570('0x1586')](),'type':_0x578570('0xcca')}];for(let _0x134d86=0x0;_0x134d86<_0xa485d7[_0x578570('0x25f4')][_0x578570('0x61a')][_0x578570('0x264b')];_0x134d86+=0x1){_0x2e74ad[_0x578570('0xfc9')]({'title':_0xa485d7[_0x578570('0x25f4')][_0x578570('0x61a')][_0x134d86][_0x578570('0x1345')],'msg':_0xa485d7[_0x578570('0x25f4')][_0x578570('0x61a')][_0x134d86][_0x578570('0x1e70')]});}}else _0x2e74ad['error']({'title':_0xa485d7[_0x578570('0x52d')]?'API:'+_0xa485d7[_0x578570('0x52d')]+_0x578570('0x11e1')+_0xa485d7[_0x578570('0xe1b')]:'api.cannedAnswer.save','msg':_0xa485d7[_0x578570('0x25f4')]?JSON[_0x578570('0xbac')](_0xa485d7[_0x578570('0x25f4')][_0x578570('0x1e70')]):_0xa485d7['toString']()});});}function _0x3a29e7(){const _0xef086f=_0x430a29;_0x4984f9['errors']=[],_0x385fda['cannedAnswer'][_0xef086f('0x1449')]({'id':_0x4984f9[_0xef086f('0x1b1f')]['id']},_0x4984f9['cannedAnswer'])[_0xef086f('0xa44')][_0xef086f('0x1166')](function(_0x1ff0a0){const _0x225ce7=_0xef086f,_0x11fe31=_0x2cfb05()[_0x225ce7('0xc38')](_0x4984f9[_0x225ce7('0x2684')],{'id':_0x1ff0a0['id']});_0x11fe31&&_0x2cfb05()[_0x225ce7('0xcc3')](_0x11fe31,_0x2cfb05()[_0x225ce7('0x1a08')](_0x1ff0a0[_0x225ce7('0x2876')](),_0x2cfb05()['keys'](_0x11fe31))),_0x2e74ad[_0x225ce7('0x103b')]({'title':'CannedAnswer\x20properly\x20saved!','msg':_0x4984f9[_0x225ce7('0x1b1f')][_0x225ce7('0x4f0')]?_0x4984f9[_0x225ce7('0x1b1f')][_0x225ce7('0x4f0')]+_0x225ce7('0x7d'):''}),_0x182c09(_0x1ff0a0);})[_0xef086f('0x1a80')](function(_0x5681db){const _0x360269=_0xef086f;if(_0x5681db[_0x360269('0x25f4')]&&_0x5681db['data']['errors']&&_0x5681db[_0x360269('0x25f4')][_0x360269('0x61a')][_0x360269('0x264b')]){_0x4984f9['errors']=_0x5681db[_0x360269('0x25f4')][_0x360269('0x61a')]||[{'message':_0x5681db['toString'](),'type':_0x360269('0x122e')}];for(let _0x34c198=0x0;_0x34c198<_0x5681db['data'][_0x360269('0x61a')][_0x360269('0x264b')];_0x34c198++){_0x2e74ad[_0x360269('0xfc9')]({'title':_0x5681db['data'][_0x360269('0x61a')][_0x34c198]['type'],'msg':_0x5681db['data'][_0x360269('0x61a')][_0x34c198]['message']});}}else _0x2e74ad[_0x360269('0xfc9')]({'title':_0x5681db['status']?_0x360269('0x1e21')+_0x5681db[_0x360269('0x52d')]+_0x360269('0x11e1')+_0x5681db[_0x360269('0xe1b')]:_0x360269('0x122e'),'msg':_0x5681db[_0x360269('0x25f4')]?JSON['stringify'](_0x5681db['data'][_0x360269('0x1e70')]):_0x5681db[_0x360269('0x1586')]()});});}function _0x4070fe(_0x41f733){const _0x1c2ed2=_0x430a29;_0x4984f9[_0x1c2ed2('0x61a')]=[];const _0x2d798c=_0x3ed8dc[_0x1c2ed2('0x1d26')]()['title']('Are\x20you\x20sure?')[_0x1c2ed2('0xacc')](_0x1c2ed2('0x91b'))[_0x1c2ed2('0x8e8')](_0x1c2ed2('0x761'))['ok'](_0x1c2ed2('0x18'))[_0x1c2ed2('0x3f')](_0x1c2ed2('0x497'))['targetEvent'](_0x41f733);_0x3ed8dc[_0x1c2ed2('0x1f80')](_0x2d798c)['then'](function(){const _0x859fff=_0x1c2ed2;_0x385fda[_0x859fff('0x1b1f')][_0x859fff('0x906')]({'id':_0x4984f9[_0x859fff('0x1b1f')]['id']})['$promise']['then'](function(){const _0x32c889=_0x859fff;_0x2cfb05()[_0x32c889('0x127f')](_0x4984f9[_0x32c889('0x2684')],{'id':_0x4984f9[_0x32c889('0x1b1f')]['id']}),_0x2e74ad['success']({'title':'CannedAnswer\x20properly\x20deleted!','msg':(_0x4984f9['cannedAnswer'][_0x32c889('0x4f0')]||_0x32c889('0x1b1f'))+_0x32c889('0x7cd')}),_0x182c09(_0x4984f9[_0x32c889('0x1b1f')]);})[_0x859fff('0x1a80')](function(_0x5f02d0){const _0xc3005e=_0x859fff;if(_0x5f02d0[_0xc3005e('0x25f4')]&&_0x5f02d0[_0xc3005e('0x25f4')][_0xc3005e('0x61a')]&&_0x5f02d0[_0xc3005e('0x25f4')]['errors']['length']){_0x4984f9[_0xc3005e('0x61a')]=_0x5f02d0[_0xc3005e('0x25f4')][_0xc3005e('0x61a')]||[{'message':_0x5f02d0[_0xc3005e('0x1586')](),'type':_0xc3005e('0x1da9')}];for(let _0x41384c=0x0;_0x41384c<_0x5f02d0[_0xc3005e('0x25f4')][_0xc3005e('0x61a')][_0xc3005e('0x264b')];_0x41384c++){_0x2e74ad[_0xc3005e('0xfc9')]({'title':_0x5f02d0[_0xc3005e('0x25f4')]['errors'][_0x41384c][_0xc3005e('0x1345')],'msg':_0x5f02d0[_0xc3005e('0x25f4')][_0xc3005e('0x61a')][_0x41384c][_0xc3005e('0x1e70')]});}}else _0x2e74ad['error']({'title':_0x5f02d0[_0xc3005e('0x52d')]?_0xc3005e('0x1e21')+_0x5f02d0[_0xc3005e('0x52d')]+_0xc3005e('0x11e1')+_0x5f02d0[_0xc3005e('0xe1b')]:_0xc3005e('0x1da9'),'msg':_0x5f02d0['data']?JSON[_0xc3005e('0xbac')](_0x5f02d0[_0xc3005e('0x25f4')]['message']):_0x5f02d0[_0xc3005e('0x1e70')]||_0x5f02d0['toString']()});});},function(){});}function _0xf9fedc(_0x12e2e2){return _0x12e2e2===null?undefined:new Date(_0x12e2e2);}function _0x182c09(_0xf9e00b){const _0x232873=_0x430a29;_0x3ed8dc[_0x232873('0x1197')](_0xf9e00b);}}const _0xd6349b=_0x4f4748;_0x41b55e[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x1780'),_0x36e6f4('0x5a8'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x41b55e(_0x1ab0fe,_0x2a4e1d,_0x4f6e90,_0x5de8e6,_0x41b9f7,_0x32a584,_0x1c6028,_0x5e7d7f,_0x258dc8,_0x342fbe,_0x4ebc2d,_0x1c7560,_0x53c48a,_0x4bf2d7){const _0x1e1961=_0x36e6f4,_0x375651=this;_0x375651['currentUser']=_0x4ebc2d[_0x1e1961('0x26cd')](),_0x375651['errors']=[],_0x375651[_0x1e1961('0xf8a')]=_0x53c48a,_0x375651['license']=_0x1c7560,_0x375651[_0x1e1961('0x243c')]=_0x4bf2d7,_0x375651['hasModulePermissions']={},_0x375651[_0x1e1961('0x2900')]=_0x375651[_0x1e1961('0xf8a')]&&_0x375651[_0x1e1961('0xf8a')][_0x1e1961('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x375651[_0x1e1961('0xcdc')]=_0x1e1961('0x26b7'),_0x375651[_0x1e1961('0x5a8')]=angular[_0x1e1961('0x225f')](_0x258dc8),_0x375651[_0x1e1961('0x1780')]=_0x5e7d7f,_0x375651[_0x1e1961('0x201d')]=![];!_0x375651[_0x1e1961('0x5a8')]&&(_0x375651['customDashboard']={},_0x375651[_0x1e1961('0xcdc')]='TOOLS.NEW_CUSTOMDASHBOARD',_0x375651[_0x1e1961('0x201d')]=!![]);_0x375651[_0x1e1961('0x19b1')]=_0x1204f6,_0x375651[_0x1e1961('0x1cd')]=_0x4b54f6,_0x375651['deleteCustomDashboard']=_0x31e9be,_0x375651[_0x1e1961('0x1a9c')]=_0x106528,_0x375651[_0x1e1961('0x24a0')]=_0x386947;function _0x1204f6(){const _0x2a2f4f=_0x1e1961;_0x375651[_0x2a2f4f('0x61a')]=[],_0x342fbe[_0x2a2f4f('0xba2')][_0x2a2f4f('0x9cc')](_0x375651[_0x2a2f4f('0x5a8')])[_0x2a2f4f('0xa44')]['then'](function(_0x5f4d8d){const _0x3f25d6=_0x2a2f4f;_0x375651['customDashboards']['unshift'](_0x5f4d8d['toJSON']()),_0x1c6028['success']({'title':_0x3f25d6('0x167c'),'msg':_0x375651[_0x3f25d6('0x5a8')][_0x3f25d6('0x4f0')]?_0x375651[_0x3f25d6('0x5a8')][_0x3f25d6('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x386947(_0x5f4d8d);})['catch'](function(_0x2b1b91){const _0x5aafeb=_0x2a2f4f;if(_0x2b1b91['data']&&_0x2b1b91[_0x5aafeb('0x25f4')]['errors']&&_0x2b1b91[_0x5aafeb('0x25f4')][_0x5aafeb('0x61a')][_0x5aafeb('0x264b')]){_0x375651[_0x5aafeb('0x61a')]=_0x2b1b91[_0x5aafeb('0x25f4')][_0x5aafeb('0x61a')]||[{'message':_0x2b1b91[_0x5aafeb('0x1586')](),'type':'api.dashboard.save'}];for(let _0x5695d8=0x0;_0x5695d8<_0x2b1b91['data'][_0x5aafeb('0x61a')][_0x5aafeb('0x264b')];_0x5695d8+=0x1){_0x1c6028['error']({'title':_0x2b1b91[_0x5aafeb('0x25f4')][_0x5aafeb('0x61a')][_0x5695d8]['type'],'msg':_0x2b1b91[_0x5aafeb('0x25f4')][_0x5aafeb('0x61a')][_0x5695d8]['message']});}}else _0x1c6028[_0x5aafeb('0xfc9')]({'title':_0x2b1b91[_0x5aafeb('0x52d')]?'API:'+_0x2b1b91[_0x5aafeb('0x52d')]+_0x5aafeb('0x11e1')+_0x2b1b91[_0x5aafeb('0xe1b')]:_0x5aafeb('0x1873'),'msg':_0x2b1b91['data']?JSON[_0x5aafeb('0xbac')](_0x2b1b91['data']['message']):_0x2b1b91[_0x5aafeb('0x1586')]()});});}function _0x4b54f6(){const _0x25867a=_0x1e1961;_0x375651['errors']=[],_0x342fbe[_0x25867a('0xba2')][_0x25867a('0x1449')]({'id':_0x375651[_0x25867a('0x5a8')]['id']},_0x375651['customDashboard'])[_0x25867a('0xa44')][_0x25867a('0x1166')](function(_0x5aa40a){const _0x48195c=_0x25867a,_0x1e6cd6=_0x2cfb05()[_0x48195c('0xc38')](_0x375651[_0x48195c('0x1780')],{'id':_0x5aa40a['id']});_0x1e6cd6&&_0x2cfb05()['merge'](_0x1e6cd6,_0x2cfb05()[_0x48195c('0x1a08')](_0x5aa40a[_0x48195c('0x2876')](),_0x2cfb05()['keys'](_0x1e6cd6))),_0x1c6028[_0x48195c('0x103b')]({'title':_0x48195c('0x1454'),'msg':_0x375651['customDashboard']['name']?_0x375651[_0x48195c('0x5a8')][_0x48195c('0x4f0')]+_0x48195c('0x7d'):''}),_0x386947(_0x5aa40a);})[_0x25867a('0x1a80')](function(_0x3c4f3f){const _0x230ce5=_0x25867a;if(_0x3c4f3f['data']&&_0x3c4f3f[_0x230ce5('0x25f4')][_0x230ce5('0x61a')]&&_0x3c4f3f[_0x230ce5('0x25f4')][_0x230ce5('0x61a')][_0x230ce5('0x264b')]){_0x375651[_0x230ce5('0x61a')]=_0x3c4f3f['data'][_0x230ce5('0x61a')]||[{'message':_0x3c4f3f['toString'](),'type':_0x230ce5('0x224')}];for(let _0x481930=0x0;_0x481930<_0x3c4f3f[_0x230ce5('0x25f4')][_0x230ce5('0x61a')]['length'];_0x481930++){_0x1c6028[_0x230ce5('0xfc9')]({'title':_0x3c4f3f['data'][_0x230ce5('0x61a')][_0x481930][_0x230ce5('0x1345')],'msg':_0x3c4f3f['data'][_0x230ce5('0x61a')][_0x481930][_0x230ce5('0x1e70')]});}}else _0x1c6028[_0x230ce5('0xfc9')]({'title':_0x3c4f3f[_0x230ce5('0x52d')]?'API:'+_0x3c4f3f[_0x230ce5('0x52d')]+_0x230ce5('0x11e1')+_0x3c4f3f[_0x230ce5('0xe1b')]:_0x230ce5('0x224'),'msg':_0x3c4f3f[_0x230ce5('0x25f4')]?JSON[_0x230ce5('0xbac')](_0x3c4f3f[_0x230ce5('0x25f4')][_0x230ce5('0x1e70')]):_0x3c4f3f[_0x230ce5('0x1586')]()});});}function _0x31e9be(_0x47254e){const _0x16dd14=_0x1e1961;_0x375651['errors']=[];const _0x25a19f=_0x5de8e6['confirm']()[_0x16dd14('0xcdc')]('Are\x20you\x20sure?')[_0x16dd14('0xacc')]('The\x20customDashboard\x20will\x20be\x20deleted.')[_0x16dd14('0x8e8')](_0x16dd14('0x1a45'))['ok'](_0x16dd14('0x18'))[_0x16dd14('0x3f')](_0x16dd14('0x497'))[_0x16dd14('0x203b')](_0x47254e);_0x5de8e6[_0x16dd14('0x1f80')](_0x25a19f)[_0x16dd14('0x1166')](function(){const _0xe7c957=_0x16dd14;_0x342fbe[_0xe7c957('0xba2')][_0xe7c957('0x906')]({'id':_0x375651[_0xe7c957('0x5a8')]['id']})['$promise']['then'](function(){const _0x4357d2=_0xe7c957;_0x2cfb05()[_0x4357d2('0x127f')](_0x375651[_0x4357d2('0x1780')],{'id':_0x375651[_0x4357d2('0x5a8')]['id']}),_0x1c6028[_0x4357d2('0x103b')]({'title':_0x4357d2('0xc6f'),'msg':(_0x375651[_0x4357d2('0x5a8')][_0x4357d2('0x4f0')]||_0x4357d2('0x5a8'))+_0x4357d2('0x7cd')}),_0x386947(_0x375651[_0x4357d2('0x5a8')]);})[_0xe7c957('0x1a80')](function(_0x23f4f6){const _0x1f7586=_0xe7c957;if(_0x23f4f6[_0x1f7586('0x25f4')]&&_0x23f4f6['data'][_0x1f7586('0x61a')]&&_0x23f4f6['data'][_0x1f7586('0x61a')][_0x1f7586('0x264b')]){_0x375651['errors']=_0x23f4f6[_0x1f7586('0x25f4')][_0x1f7586('0x61a')]||[{'message':_0x23f4f6[_0x1f7586('0x1586')](),'type':'api.dashboard.delete'}];for(let _0x5a5ed9=0x0;_0x5a5ed9<_0x23f4f6['data']['errors'][_0x1f7586('0x264b')];_0x5a5ed9++){_0x1c6028[_0x1f7586('0xfc9')]({'title':_0x23f4f6['data']['errors'][_0x5a5ed9]['type'],'msg':_0x23f4f6[_0x1f7586('0x25f4')][_0x1f7586('0x61a')][_0x5a5ed9]['message']});}}else _0x1c6028[_0x1f7586('0xfc9')]({'title':_0x23f4f6[_0x1f7586('0x52d')]?_0x1f7586('0x1e21')+_0x23f4f6[_0x1f7586('0x52d')]+_0x1f7586('0x11e1')+_0x23f4f6['statusText']:'api.dashboard.delete','msg':_0x23f4f6[_0x1f7586('0x25f4')]?JSON[_0x1f7586('0xbac')](_0x23f4f6['data']['message']):_0x23f4f6[_0x1f7586('0x1e70')]||_0x23f4f6[_0x1f7586('0x1586')]()});});},function(){});}function _0x106528(_0x1e55f7){return _0x1e55f7===null?undefined:new Date(_0x1e55f7);}function _0x386947(_0x2594fd){_0x5de8e6['hide'](_0x2594fd);}}const _0x123879=_0x41b55e,_0x4492f8=_0x2734b2['p']+_0x36e6f4('0x26cc');_0x2aed8b[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),'$state','$mdSidenav',_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x1780'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x2aed8b(_0x5c185b,_0x40ae37,_0x162f83,_0x445b8f,_0xe60557,_0x326cee,_0x370fee,_0x40b7b9,_0xef79d,_0xd70d54,_0x27077f,_0x3690d7,_0x2330c3,_0x3f0bf0,_0x11ba9d,_0x1d01ea,_0x348ca4){const _0x2f762e=_0x36e6f4,_0xde8274=this;_0xde8274['license']=_0x1d01ea,_0xde8274[_0x2f762e('0xf8a')]=_0x348ca4,_0xde8274[_0x2f762e('0x98')]=_0x11ba9d[_0x2f762e('0x26cd')](),_0xde8274[_0x2f762e('0x1780')]=_0xef79d||{'count':0x0,'rows':[]},_0xde8274[_0x2f762e('0x7f')]=_0xd70d54,_0xde8274[_0x2f762e('0x17aa')]=_0x27077f&&_0x27077f[_0x2f762e('0x240f')]==0x1?_0x27077f[_0x2f762e('0x269a')][0x0]:null,_0xde8274[_0x2f762e('0x243c')]=_0x11ba9d[_0x2f762e('0xd87')](_0xde8274[_0x2f762e('0x17aa')]?_0xde8274[_0x2f762e('0x17aa')][_0x2f762e('0x243c')]:null),_0xde8274[_0x2f762e('0x916')]=_0x2f762e('0x1780'),_0xde8274[_0x2f762e('0xef5')]='',_0xde8274['listOrderAsc']=null,_0xde8274[_0x2f762e('0x2551')]=[],_0xde8274['query']={'fields':_0x2f762e('0x208e'),'sort':_0x2f762e('0x14dc'),'limit':0xa,'page':0x1},_0xde8274[_0x2f762e('0x1ff6')]=_0xfc4f14,_0xde8274[_0x2f762e('0x966')]=_0x3b2ea1,_0xde8274['deleteconfirm']=_0x4ac9d1,_0xde8274[_0x2f762e('0x103b')]=_0x4cb848,_0xde8274[_0x2f762e('0x40d')]=_0xa423ba,_0xde8274[_0x2f762e('0x1e76')]=_0x154b0a,_0xde8274[_0x2f762e('0xef1')]=_0x5e9552,_0xde8274[_0x2f762e('0xa5d')]=_0x1f7ff9,_0xde8274['deleteSelectedCustomDashboards']=_0x201dc4,_0xde8274['deselectCustomDashboards']=_0x4e3872,_0xde8274[_0x2f762e('0x46f')]=_0x365712;function _0xfc4f14(_0x116b2b){const _0x1c9c9a=_0x2f762e;_0x162f83['go']('app.tools.customDashboards.edit',{'id':_0x116b2b['id'],'customDashboard':_0x116b2b,'crudPermissions':_0xde8274[_0x1c9c9a('0x243c')]});}function _0x3b2ea1(_0x99c664){_0x162f83['go']('app.dashboards.custom',{'id':_0x99c664['id']});}function _0x4ac9d1(_0x5dc846,_0x1fc701){const _0x328b1a=_0x2f762e,_0x44f527=_0xe60557[_0x328b1a('0x1d26')]()[_0x328b1a('0xcdc')](_0x328b1a('0x288d')+_0x2cfb05()[_0x328b1a('0xb35')](_0x328b1a('0x5a8'))+'?')[_0x328b1a('0xf3c')](_0x328b1a('0x12b5')+(_0x5dc846[_0x328b1a('0x4f0')]||_0x328b1a('0x5a8'))+''+'\x20will\x20be\x20deleted.')[_0x328b1a('0x8e8')](_0x328b1a('0x11bc'))['targetEvent'](_0x1fc701)['ok']('OK')[_0x328b1a('0x3f')](_0x328b1a('0x2d3'));_0xe60557[_0x328b1a('0x1f80')](_0x44f527)[_0x328b1a('0x1166')](function(){_0x5e9552(_0x5dc846);},function(){const _0x347f0e=_0x328b1a;console['log'](_0x347f0e('0x2d3'));});}let _0x42255c=!![],_0x5b3eb8=0x1;_0x5c185b[_0x2f762e('0xe83')](_0x2f762e('0x12d8'),function(_0x3b9aa6,_0x47a089){const _0xfcd98c=_0x2f762e;_0x42255c?_0x370fee(function(){_0x42255c=![];}):(!_0x47a089&&(_0x5b3eb8=_0xde8274['query'][_0xfcd98c('0x1a43')]),_0x3b9aa6!==_0x47a089&&(_0xde8274[_0xfcd98c('0x2218')][_0xfcd98c('0x1a43')]=0x1),!_0x3b9aa6&&(_0xde8274['query'][_0xfcd98c('0x1a43')]=_0x5b3eb8),_0xde8274['getCustomDashboards']());});function _0x4cb848(_0x4137e2){const _0x2a67bd=_0x2f762e;_0xde8274[_0x2a67bd('0x1780')]=_0x4137e2||{'count':0x0,'rows':[]};}function _0xa423ba(){const _0x23e687=_0x2f762e;_0xde8274[_0x23e687('0x2218')][_0x23e687('0x1098')]=(_0xde8274[_0x23e687('0x2218')][_0x23e687('0x1a43')]-0x1)*_0xde8274['query'][_0x23e687('0x163f')],_0x11ba9d[_0x23e687('0x1ac6')]('admin')?_0xde8274[_0x23e687('0x1f48')]=_0x3690d7[_0x23e687('0xba2')][_0x23e687('0xd83')](_0xde8274[_0x23e687('0x2218')],_0x4cb848)[_0x23e687('0xa44')]:(_0xde8274['query']['id']=_0xde8274[_0x23e687('0x7f')]['id'],_0xde8274['query'][_0x23e687('0xe60')]=_0x23e687('0x1fc2'),_0xde8274['promise']=_0x3690d7[_0x23e687('0x7f')]['getResources'](_0xde8274[_0x23e687('0x2218')],_0x4cb848)[_0x23e687('0xa44')]);}function _0x154b0a(_0x5ef9ae,_0x2c8dc5){const _0x521f7f=_0x2f762e;_0xe60557['show']({'controller':_0x521f7f('0xb92'),'controllerAs':'vm','templateUrl':_0x4492f8,'parent':angular[_0x521f7f('0x1194')](_0x326cee[_0x521f7f('0x8d2')]),'targetEvent':_0x5ef9ae,'clickOutsideToClose':!![],'locals':{'customDashboard':_0x2c8dc5,'customDashboards':_0xde8274[_0x521f7f('0x1780')]['rows'],'license':_0xde8274['license'],'setting':_0xde8274[_0x521f7f('0xf8a')],'crudPermissions':_0xde8274['crudPermissions']}});}function _0x5e9552(_0x25ab8b){const _0x396c22=_0x2f762e;_0x3690d7[_0x396c22('0xba2')][_0x396c22('0x906')]({'id':_0x25ab8b['id']})[_0x396c22('0xa44')][_0x396c22('0x1166')](function(){const _0x2beb5f=_0x396c22;_0x2cfb05()[_0x2beb5f('0x127f')](_0xde8274[_0x2beb5f('0x1780')][_0x2beb5f('0x269a')],{'id':_0x25ab8b['id']}),_0xde8274[_0x2beb5f('0x1780')][_0x2beb5f('0x240f')]-=0x1,!_0xde8274['customDashboards'][_0x2beb5f('0x269a')][_0x2beb5f('0x264b')]&&_0xde8274['getCustomDashboards'](),_0x3f0bf0[_0x2beb5f('0x103b')]({'title':_0x2cfb05()['startCase'](_0x2beb5f('0xe94'))+_0x2beb5f('0x2b6'),'msg':_0x25ab8b[_0x2beb5f('0x4f0')]?_0x25ab8b[_0x2beb5f('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0x396c22('0x1a80')](function(_0x1a16c5){const _0x19b767=_0x396c22;if(_0x1a16c5[_0x19b767('0x25f4')]&&_0x1a16c5[_0x19b767('0x25f4')][_0x19b767('0x61a')]&&_0x1a16c5[_0x19b767('0x25f4')]['errors']['length']){_0xde8274[_0x19b767('0x61a')]=_0x1a16c5['data'][_0x19b767('0x61a')]||[{'message':_0x1a16c5[_0x19b767('0x1586')](),'type':'SYSTEM:DELETEdashboard'}];for(let _0x3902d0=0x0;_0x3902d0<_0x1a16c5['data']['errors'][_0x19b767('0x264b')];_0x3902d0++){_0x3f0bf0[_0x19b767('0xfc9')]({'title':_0x1a16c5['data']['errors'][_0x3902d0][_0x19b767('0x1345')],'msg':_0x1a16c5[_0x19b767('0x25f4')][_0x19b767('0x61a')][_0x3902d0][_0x19b767('0x1e70')]});}}else _0x3f0bf0[_0x19b767('0xfc9')]({'title':_0x1a16c5[_0x19b767('0x52d')]?_0x19b767('0x1e21')+_0x1a16c5['status']+_0x19b767('0x11e1')+_0x1a16c5[_0x19b767('0xe1b')]:_0x19b767('0x26b5'),'msg':_0x1a16c5[_0x19b767('0x25f4')]?JSON[_0x19b767('0xbac')](_0x1a16c5[_0x19b767('0x25f4')][_0x19b767('0x1e70')]):_0x1a16c5[_0x19b767('0x1e70')]||_0x1a16c5['toString']()});});}function _0x1f7ff9(){const _0x10f8fc=_0x2f762e,_0x5da6ce=angular[_0x10f8fc('0x225f')](_0xde8274[_0x10f8fc('0x2551')]);return _0xde8274[_0x10f8fc('0x2551')]=[],_0x5da6ce;}function _0x201dc4(_0x89eaaf){const _0x20b835=_0x2f762e,_0x42fa81=_0xe60557[_0x20b835('0x1d26')]()[_0x20b835('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20customDashboards?')['htmlContent'](''+_0xde8274['selectedCustomDashboards']['length']+_0x20b835('0x196d')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x20b835('0x1a9d'))[_0x20b835('0x203b')](_0x89eaaf)['ok']('OK')[_0x20b835('0x3f')](_0x20b835('0x2d3'));_0xe60557[_0x20b835('0x1f80')](_0x42fa81)['then'](function(){const _0x43c2ea=_0x20b835;_0xde8274[_0x43c2ea('0x2551')]['forEach'](function(_0x3716cc){_0x5e9552(_0x3716cc);}),_0xde8274[_0x43c2ea('0x2551')]=[];});}function _0x4e3872(){const _0x310588=_0x2f762e;_0xde8274[_0x310588('0x2551')]=[];}function _0x365712(){const _0x4b5cbc=_0x2f762e;_0xde8274[_0x4b5cbc('0x2551')]=_0xde8274[_0x4b5cbc('0x1780')][_0x4b5cbc('0x269a')];}}const _0x15de14=_0x2aed8b;_0x2d671a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x7b9'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x5a8'),_0x36e6f4('0x1780'),'$translate'];function _0x2d671a(_0x58b1ec,_0x3dc8d8,_0x68ffb6,_0x510fe9,_0x14ef9d,_0x23e3d8,_0x42a619){const _0x2863f4=_0x36e6f4,_0xd6689f=this;_0xd6689f[_0x2863f4('0x201d')]=!![],_0xd6689f[_0x2863f4('0x5a8')]=angular['copy'](_0x14ef9d),_0xd6689f[_0x2863f4('0x1780')]=_0x23e3d8,_0xd6689f[_0x2863f4('0xcdc')]=_0x42a619[_0x2863f4('0x25cc')](_0x2863f4('0x536'));_0x14ef9d&&_0x14ef9d['name']&&(_0xd6689f[_0x2863f4('0xcdc')]+=':\x20'+_0x14ef9d['name']);_0xd6689f[_0x2863f4('0x1626')]=_0x3ead29,_0xd6689f[_0x2863f4('0x24a0')]=_0x4f38a3;function _0x3ead29(){const _0xaa174c=_0x2863f4;return _0x510fe9[_0xaa174c('0xba2')][_0xaa174c('0xddc')]({'id':_0x14ef9d['id'],'includeAll':!![]},_0xd6689f[_0xaa174c('0x5a8')])['$promise']['then'](function(_0x2226c9){const _0x1ba67f=_0xaa174c;_0xd6689f[_0x1ba67f('0x1780')][_0x1ba67f('0x2450')](_0x2226c9[_0x1ba67f('0x2876')]()),_0x68ffb6[_0x1ba67f('0x103b')]({'title':_0x1ba67f('0x16d3'),'msg':_0xd6689f[_0x1ba67f('0x5a8')][_0x1ba67f('0x4f0')]?_0xd6689f[_0x1ba67f('0x5a8')][_0x1ba67f('0x4f0')]+_0x1ba67f('0x1273'):''}),_0x3dc8d8['go'](_0x1ba67f('0x1bb0'),{'id':_0x2226c9['id']}),_0x4f38a3(_0x2226c9);})[_0xaa174c('0x1a80')](function(_0x37f3d8){const _0xa391b3=_0xaa174c;if(_0x37f3d8[_0xa391b3('0x25f4')]&&_0x37f3d8[_0xa391b3('0x25f4')][_0xa391b3('0x61a')]&&_0x37f3d8[_0xa391b3('0x25f4')]['errors']['length']){_0xd6689f[_0xa391b3('0x61a')]=_0x37f3d8['data']['errors']||[{'message':_0x37f3d8['toString'](),'type':_0xa391b3('0x959')}];for(let _0x1cace3=0x0;_0x1cace3<_0x37f3d8[_0xa391b3('0x25f4')][_0xa391b3('0x61a')][_0xa391b3('0x264b')];_0x1cace3+=0x1){_0x68ffb6[_0xa391b3('0xfc9')]({'title':_0x37f3d8['data']['errors'][_0x1cace3][_0xa391b3('0x1345')],'msg':_0x37f3d8['data'][_0xa391b3('0x61a')][_0x1cace3][_0xa391b3('0x1e70')]});}}else _0x68ffb6[_0xa391b3('0xfc9')]({'title':_0x37f3d8['status']?'API:'+_0x37f3d8['status']+_0xa391b3('0x11e1')+_0x37f3d8[_0xa391b3('0xe1b')]:_0xa391b3('0x959'),'msg':_0x37f3d8['data']?JSON['stringify'](_0x37f3d8[_0xa391b3('0x25f4')][_0xa391b3('0x1e70')]):_0x37f3d8[_0xa391b3('0x1586')]()});});}function _0x4f38a3(_0x246ac1){_0x58b1ec['hide'](_0x246ac1);}}const _0x3b26d2=_0x2d671a,_0x369993=_0x2734b2['p']+_0x36e6f4('0x129');_0x378dd8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'socket',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3')];function _0x378dd8(_0x3903af,_0x3826ba,_0x57b70e,_0x45ad31,_0x377196){const _0x178e78=_0x36e6f4,_0x2c2c02=this;_0x2c2c02[_0x178e78('0x5a8')]={},_0x2c2c02[_0x178e78('0x20fd')]=_0x377196[_0x178e78('0x13fa')][_0x178e78('0x680')]({'fields':'id,name'}),_0x2c2c02[_0x178e78('0x24d5')]=_0x198c32,_0x2c2c02[_0x178e78('0xe80')]=_0x29eefc,_0x2c2c02[_0x178e78('0x1a50')]=_0xcf0d38;function _0x198c32(_0x1f74a8,_0x4673d7){const _0x1c5355=_0x178e78;return _0x2c2c02['crudPermissions']=typeof _0x4673d7!=='undefined'?_0x4673d7:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x2c2c02[_0x1c5355('0x5a8')]=_0x1f74a8,_0x2c2c02[_0x1c5355('0x5a8')]['draggable']={'enabled':!![],'handle':_0x1c5355('0x175f'),'stop':_0x3d46e0},_0x2c2c02['customDashboard'][_0x1c5355('0x2273')]={'enabled':!![],'handle':_0x1c5355('0x17a4'),'stop':_0x3d46e0},_0x2c2c02[_0x1c5355('0x5a8')][_0x1c5355('0x135')]=[],_0x377196[_0x1c5355('0xba2')][_0x1c5355('0xea5')]({'id':_0x1f74a8['id']})[_0x1c5355('0xa44')][_0x1c5355('0x1166')](function(_0x5b5495){const _0x4b3754=_0x1c5355;if(_0x5b5495&&_0x5b5495[_0x4b3754('0x240f')]&&_0x5b5495[_0x4b3754('0x269a')])for(let _0xda8d0e=0x0;_0xda8d0e<_0x5b5495[_0x4b3754('0x269a')]['length'];_0xda8d0e+=0x1){_0x5b5495[_0x4b3754('0x269a')][_0xda8d0e][_0x4b3754('0x20fd')]=_0x2c2c02[_0x4b3754('0x20fd')],_0x5b5495['rows'][_0xda8d0e][_0x4b3754('0xe15')]=_0x2cfb05()[_0x4b3754('0x2563')](_0x2c2c02[_0x4b3754('0x20fd')][_0x4b3754('0x269a')],'id'),_0x5b5495['rows'][_0xda8d0e][_0x4b3754('0x12a8')]='app/core/directives/ms-widget-engine/ms-widget-engine-'+_0x5b5495[_0x4b3754('0x269a')][_0xda8d0e][_0x4b3754('0x1345')]+_0x4b3754('0x1299')+_0x5b5495[_0x4b3754('0x269a')][_0xda8d0e][_0x4b3754('0x1345')]+_0x4b3754('0x2278'),_0x2c2c02[_0x4b3754('0x5a8')]['widgets'][_0x4b3754('0x1514')](_0x5b5495[_0x4b3754('0x269a')][_0xda8d0e]);}})['catch'](function(_0x3987ab){const _0x2afec9=_0x1c5355;console[_0x2afec9('0xfc9')](_0x3987ab);});}function _0x29eefc(_0x84cf9){const _0x2076de=_0x178e78;if(_0x84cf9&&_0x84cf9[_0x2076de('0x2216')])for(let _0x318052=0x0;_0x318052<_0x84cf9['attrs'][_0x2076de('0x264b')];_0x318052+=0x1){_0x84cf9[_0x2076de('0x2216')][_0x318052][_0x2076de('0x4f0')]===_0x2076de('0x22fa')&&(_0x84cf9[_0x2076de('0x2518')]=_0x84cf9[_0x2076de('0x2216')][_0x318052][_0x2076de('0x1345')]),_0x84cf9[_0x84cf9[_0x2076de('0x2216')][_0x318052][_0x2076de('0x4f0')]]=_0x84cf9[_0x2076de('0x2216')][_0x318052][_0x2076de('0x18e0')];}_0x3903af[_0x2076de('0x1f80')]({'controller':_0x2076de('0x1606'),'controllerAs':'vm','templateUrl':_0x369993,'parent':angular[_0x2076de('0x1194')](_0x3826ba['body']),'clickOutsideToClose':!![],'locals':{'dashboarditem':_0x84cf9,'dashboard':_0x2c2c02[_0x2076de('0x5a8')][_0x2076de('0x135')],'license':null,'setting':null,'crudPermissions':_0x2c2c02[_0x2076de('0x243c')]}})['then'](function(_0x23e0ea){const _0x32be5e=_0x2076de;if(_0x23e0ea)for(let _0x145318=0x0;_0x145318<_0x2c2c02[_0x32be5e('0x5a8')]['widgets']['length'];_0x145318+=0x1){_0x2c2c02[_0x32be5e('0x5a8')][_0x32be5e('0x135')][_0x145318]['id']===_0x23e0ea['id']&&(_0x2c2c02[_0x32be5e('0x5a8')][_0x32be5e('0x135')][_0x145318][_0x32be5e('0x2216')]=_0x23e0ea['attrs'],_0x2c2c02[_0x32be5e('0x5a8')]['widgets'][_0x145318]['voiceQueues']=_0x2c2c02[_0x32be5e('0x20fd')],_0x2c2c02['customDashboard'][_0x32be5e('0x135')][_0x145318][_0x32be5e('0xe15')]=_0x2cfb05()[_0x32be5e('0x2563')](_0x2c2c02[_0x32be5e('0x20fd')][_0x32be5e('0x269a')],'id'),_0x2c2c02[_0x32be5e('0x5a8')][_0x32be5e('0x135')][_0x145318][_0x32be5e('0x12a8')]='app/core/directives/ms-widget-engine/ms-widget-engine-'+_0x2c2c02[_0x32be5e('0x5a8')][_0x32be5e('0x135')][_0x145318]['type']+_0x32be5e('0x1299')+_0x2c2c02['customDashboard'][_0x32be5e('0x135')][_0x145318][_0x32be5e('0x1345')]+_0x32be5e('0x2278'));}});}function _0xcf0d38(_0x5cd3d5){const _0x91a0f7=_0x178e78,_0x54feea=_0x3903af[_0x91a0f7('0x1d26')]()['title'](_0x91a0f7('0xcfd')+_0x5cd3d5[_0x91a0f7('0xcdc')]+'?')[_0x91a0f7('0x2077')]('')[_0x91a0f7('0x8e8')](_0x91a0f7('0x26e5'))['ok'](_0x91a0f7('0x188f'))['cancel']('NO');_0x3903af[_0x91a0f7('0x1f80')](_0x54feea)[_0x91a0f7('0x1166')](function(){const _0x5c057c=_0x91a0f7;return _0x377196[_0x5c057c('0x20ac')][_0x5c057c('0x906')]({'id':_0x5cd3d5['id']})[_0x5c057c('0xa44')][_0x5c057c('0x1166')](function(){const _0x528242=_0x5c057c;_0x2cfb05()[_0x528242('0x127f')](_0x2c2c02[_0x528242('0x5a8')][_0x528242('0x135')],{'id':_0x5cd3d5['id']}),_0x45ad31[_0x528242('0x103b')]({'title':_0x528242('0x10e8'),'msg':_0x5cd3d5[_0x528242('0x4f0')]?_0x5cd3d5['name']+_0x528242('0x7cd'):_0x528242('0x12c1')});})['catch'](function(_0x4a9d26){const _0x59c46c=_0x5c057c;if(_0x4a9d26[_0x59c46c('0x25f4')]&&_0x4a9d26[_0x59c46c('0x25f4')][_0x59c46c('0x61a')]&&_0x4a9d26[_0x59c46c('0x25f4')][_0x59c46c('0x61a')][_0x59c46c('0x264b')]){_0x2c2c02[_0x59c46c('0x61a')]=_0x4a9d26[_0x59c46c('0x25f4')][_0x59c46c('0x61a')]||[{'message':_0x4a9d26[_0x59c46c('0x1586')](),'type':_0x59c46c('0x24b1')}];for(let _0x34bfd6=0x0;_0x34bfd6<_0x4a9d26['data'][_0x59c46c('0x61a')][_0x59c46c('0x264b')];_0x34bfd6++){_0x45ad31[_0x59c46c('0xfc9')]({'title':_0x4a9d26[_0x59c46c('0x25f4')][_0x59c46c('0x61a')][_0x34bfd6][_0x59c46c('0x1345')],'msg':_0x4a9d26['data'][_0x59c46c('0x61a')][_0x34bfd6][_0x59c46c('0x1e70')]});}}else _0x45ad31[_0x59c46c('0xfc9')]({'title':_0x4a9d26[_0x59c46c('0x52d')]?'API:'+_0x4a9d26[_0x59c46c('0x52d')]+_0x59c46c('0x11e1')+_0x4a9d26[_0x59c46c('0xe1b')]:'SYSTEM:DELETEdashboard','msg':_0x4a9d26[_0x59c46c('0x25f4')]?JSON[_0x59c46c('0xbac')](_0x4a9d26[_0x59c46c('0x25f4')][_0x59c46c('0x1e70')]):_0x4a9d26[_0x59c46c('0x1e70')]||_0x4a9d26[_0x59c46c('0x1586')]()});console['error'](_0x4a9d26);});});}function _0x3d46e0(_0x360c5e,_0x1740b1,_0x28ec8a){const _0x58e8e0=_0x178e78;return _0x377196[_0x58e8e0('0x20ac')][_0x58e8e0('0x1449')](_0x28ec8a)[_0x58e8e0('0xa44')]['catch'](function(_0x325cd3){const _0x57784e=_0x58e8e0;console[_0x57784e('0xfc9')](_0x325cd3);});}}const _0x47089b=_0x378dd8,_0x1c615f=_0x2734b2['p']+_0x36e6f4('0x1e9');_0x1285ce[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xba2'),_0x36e6f4('0x2860'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x1285ce(_0x58de11,_0x1637d4,_0x58da8d,_0x5a6c01,_0x1dc419,_0x56f445,_0x4678df,_0x200252,_0x337fa2,_0x19b9e9,_0x5b7f86,_0x55735b,_0x272b17,_0x46d4b4){const _0x23c3bf=_0x36e6f4,_0x259e38=this;_0x259e38[_0x23c3bf('0x98')]=_0x5b7f86[_0x23c3bf('0x26cd')](),_0x259e38[_0x23c3bf('0x61a')]=[],_0x259e38['setting']=_0x272b17,_0x259e38['license']=_0x55735b,_0x259e38[_0x23c3bf('0x243c')]=_0x46d4b4,_0x259e38[_0x23c3bf('0x128b')]={},_0x259e38['passwordPattern']=_0x259e38['setting']&&_0x259e38['setting'][_0x23c3bf('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x259e38['title']=_0x23c3bf('0x1532'),_0x259e38[_0x23c3bf('0x2860')]=angular['copy'](_0x337fa2),_0x259e38[_0x23c3bf('0xba2')]=_0x200252,_0x259e38[_0x23c3bf('0x24de')]=![],_0x259e38[_0x23c3bf('0x266f')]=[],_0x259e38[_0x23c3bf('0x2218')]={'fields':_0x23c3bf('0x67b'),'limit':0xa,'page':0x1,'sort':'-updatedAt'};!_0x259e38[_0x23c3bf('0x2860')]?(_0x259e38[_0x23c3bf('0x2860')]={'type':_0x23c3bf('0x135b'),'attrUrl':_0x23c3bf('0x15ce'),'attrHourFormat':'HH:mm:ss','attrTimezone':_0x23c3bf('0x1121'),'attrMetric':'total','attrSerie1':_0x23c3bf('0x25e7'),'attrSerie2':_0x23c3bf('0x15d7'),'attrSerie3':_0x23c3bf('0x15d7'),'attrRefresh':0xa,'attrFontSize':0x14,'foreground':_0x23c3bf('0x27e1'),'background':'#ffffff'},_0x259e38['title']=_0x23c3bf('0x20a3'),_0x259e38[_0x23c3bf('0x24de')]=!![]):_0x259e38[_0x23c3bf('0x2860')][_0x23c3bf('0x1345')]==_0x23c3bf('0xd69')&&(_0x259e38[_0x23c3bf('0x2677')]=_0x259e38['dashboarditem'][_0x23c3bf('0x2518')]===_0x23c3bf('0x2853')?_0x23c3bf('0x1ff5'):_0x23c3bf('0x17c2'),_0x19b9e9[_0x259e38[_0x23c3bf('0x2677')]][_0x23c3bf('0xd83')]({'fields':'id,name,parent'})['$promise'][_0x23c3bf('0x1166')](function(_0x4aad90){const _0x46a14a=_0x23c3bf;_0x259e38['currentReport']=_0x2cfb05()[_0x46a14a('0xc38')](_0x4aad90[_0x46a14a('0x269a')],{'id':_0x259e38[_0x46a14a('0x2860')][_0x46a14a('0x22fa')]}),_0x259e38[_0x46a14a('0x2860')][_0x46a14a('0x2659')]=_0x259e38['currentReport']['name'],_0x259e38['query']['parent']=_0x259e38[_0x46a14a('0x519')][_0x46a14a('0x5f6')];}));_0x259e38[_0x23c3bf('0x4cf')]=_0x5a001a,_0x259e38['saveDashboardItem']=_0xfc2d71,_0x259e38[_0x23c3bf('0x1971')]=_0x19ec64,_0x259e38[_0x23c3bf('0x1a9c')]=_0x4e0930,_0x259e38[_0x23c3bf('0x20aa')]=_0x2595fb,_0x259e38['selectReport']=_0xea1b97,_0x259e38['closeReportDialog']=_0x45d427,_0x259e38['searchReport']=_0x505dd4,_0x259e38[_0x23c3bf('0x24a0')]=_0x28e477,_0x19b9e9[_0x23c3bf('0x7eb')]['get']({})[_0x23c3bf('0xa44')][_0x23c3bf('0x1166')](function(_0x3a6ab4){const _0x58bb3b=_0x23c3bf;_0x259e38[_0x58bb3b('0x14c7')]=_0x3a6ab4[_0x58bb3b('0x269a')]||[];})[_0x23c3bf('0x1a80')](function(_0x32e261){const _0x33ad20=_0x23c3bf;_0x4678df['error']({'title':_0x32e261['status']?'API:'+_0x32e261[_0x33ad20('0x52d')]+_0x33ad20('0x11e1')+_0x32e261[_0x33ad20('0xe1b')]:_0x33ad20('0x27b9'),'msg':_0x32e261[_0x33ad20('0x25f4')]?JSON['stringify'](_0x32e261[_0x33ad20('0x25f4')]):_0x32e261[_0x33ad20('0x1586')]()});});const _0x550c71=[{'id':0x191,'type':_0x23c3bf('0x14d8')},{'id':0x5dd,'type':_0x23c3bf('0x587')}];let _0x3b3781=null;_0x5b7f86[_0x23c3bf('0x1ac6')](_0x23c3bf('0xa7c'))?_0x19b9e9[_0x23c3bf('0x1943')][_0x23c3bf('0xd83')]({'fields':_0x23c3bf('0x1c09'),'sort':_0x23c3bf('0x4f0'),'nolimit':_0x23c3bf('0xf3b')})[_0x23c3bf('0xa44')]['then'](function(_0x4c9c6a){const _0x5244a7=_0x23c3bf;_0x259e38[_0x5244a7('0x20fd')]=_0x4c9c6a[_0x5244a7('0x269a')]||[];})[_0x23c3bf('0x1a80')](function(_0x509d67){const _0x4812e6=_0x23c3bf;_0x4678df['error']({'title':_0x509d67[_0x4812e6('0x52d')]?_0x4812e6('0x1e21')+_0x509d67[_0x4812e6('0x52d')]+_0x4812e6('0x11e1')+_0x509d67[_0x4812e6('0xe1b')]:'SYSTEM:GET_VOICEQUEUES','msg':_0x509d67['data']?JSON[_0x4812e6('0xbac')](_0x509d67[_0x4812e6('0x25f4')]):_0x509d67[_0x4812e6('0x1586')]()});}):_0x19b9e9[_0x23c3bf('0x1943')][_0x23c3bf('0xd83')]({'fields':'id,name,type','sort':_0x23c3bf('0x4f0'),'nolimit':_0x23c3bf('0xf3b')})[_0x23c3bf('0xa44')]['then'](function(_0xe22a30){const _0x23302e=_0x23c3bf;_0x3b3781=_0xe22a30[_0x23302e('0x269a')]||[];})[_0x23c3bf('0x1166')](function(){const _0x1cc8a4=_0x23c3bf,_0x45d376=[];for(let _0x37f38d=0x0;_0x37f38d<_0x550c71[_0x1cc8a4('0x264b')];_0x37f38d++){_0x45d376[_0x1cc8a4('0x1514')](_0x19b9e9['userProfileSection'][_0x1cc8a4('0xd83')]({'userProfileId':_0x259e38[_0x1cc8a4('0x98')][_0x1cc8a4('0xb86')],'sectionId':_0x550c71[_0x37f38d]['id']})[_0x1cc8a4('0xa44')]);}return _0x1dc419[_0x1cc8a4('0x2760')](_0x45d376);})[_0x23c3bf('0x1166')](function(_0x9a5b42){const _0x380f5d=_0x23c3bf,_0x60dc18=_0x2cfb05()[_0x380f5d('0x2563')](_0x9a5b42,function(_0x4cf584){const _0x17bd62=_0x380f5d;return _0x4cf584&&_0x4cf584[_0x17bd62('0x269a')]?_0x4cf584['rows'][0x0]:null;}),_0x35b61c=[];for(let _0x3df38f=0x0;_0x3df38f<_0x550c71[_0x380f5d('0x264b')];_0x3df38f++){const _0x539753=_0x2cfb05()[_0x380f5d('0xc38')](_0x60dc18,['sectionId',_0x550c71[_0x3df38f]['id']]);if(_0x539753){if(!_0x539753[_0x380f5d('0x1a2b')])_0x35b61c[_0x380f5d('0x1514')](_0x19b9e9[_0x380f5d('0x4b5')]['get']({'sectionId':_0x539753['id']})[_0x380f5d('0xa44')]);else{const _0x1e8e1c=[];_0x3b3781[_0x380f5d('0x2782')](function(_0xbb9aac){const _0x50fcd2=_0x380f5d;_0xbb9aac[_0x50fcd2('0x1345')]===_0x550c71[_0x3df38f][_0x50fcd2('0x1345')]&&_0x1e8e1c[_0x50fcd2('0x1514')](_0xbb9aac);}),_0x35b61c[_0x380f5d('0x1514')]({'rows':_0x1e8e1c,'count':_0x1e8e1c[_0x380f5d('0x264b')]});}}}return _0x1dc419[_0x380f5d('0x2760')](_0x35b61c);})[_0x23c3bf('0x1166')](function(_0x33c5db){const _0x2f1225=_0x23c3bf,_0x16a5a3=[];let _0x306030=null;_0x259e38[_0x2f1225('0x2860')]&&(_0x306030=_0x2cfb05()[_0x2f1225('0xc38')](_0x3b3781,{'id':Number(_0x259e38[_0x2f1225('0x2860')][_0x2f1225('0x204f')])}));for(let _0x3d867a=0x0;_0x3d867a<_0x33c5db[_0x2f1225('0x264b')];_0x3d867a++){const _0x3e7ab8=_0x33c5db[_0x3d867a]['rows']||[];_0x3e7ab8['forEach'](function(_0x13b50a){const _0x1e39d6=_0x2f1225;_0x16a5a3[_0x1e39d6('0x1514')](_0x13b50a);});}_0x306030&&!_0x2cfb05()['some'](_0x16a5a3,[_0x2f1225('0x24e8'),_0x306030['id']])&&_0x3b3781['forEach'](function(_0x2a826a){const _0x5b717f=_0x2f1225;_0x2a826a['id']===_0x306030['id']&&(_0x2a826a[_0x5b717f('0x2378')]=![],_0x16a5a3['push'](_0x2a826a));}),_0x259e38['voiceQueues']=_0x16a5a3;})[_0x23c3bf('0x1a80')](function(_0x832378){const _0xee2fba=_0x23c3bf;_0x4678df['error']({'title':_0x832378[_0xee2fba('0x52d')]?_0xee2fba('0x1e21')+_0x832378[_0xee2fba('0x52d')]+_0xee2fba('0x11e1')+_0x832378[_0xee2fba('0xe1b')]:_0xee2fba('0x7b1'),'msg':_0x832378[_0xee2fba('0x25f4')]?JSON[_0xee2fba('0xbac')](_0x832378['data']):_0x832378['toString']()});});function _0x5a001a(){const _0x1fd9a2=_0x23c3bf;_0x259e38[_0x1fd9a2('0x61a')]=[],_0x19b9e9[_0x1fd9a2('0xba2')][_0x1fd9a2('0x28ab')]({'id':_0x1637d4[_0x1fd9a2('0x23f')]['id']},_0x259e38[_0x1fd9a2('0x2860')])[_0x1fd9a2('0xa44')][_0x1fd9a2('0x1166')](function(_0x142e59){const _0x2ad5eb=_0x1fd9a2;_0x259e38[_0x2ad5eb('0xba2')][_0x2ad5eb('0x2450')](_0x142e59[_0x2ad5eb('0x2876')]()),_0x4678df[_0x2ad5eb('0x103b')]({'title':_0x2ad5eb('0x1199'),'msg':_0x259e38[_0x2ad5eb('0x2860')][_0x2ad5eb('0x4f0')]?_0x259e38[_0x2ad5eb('0x2860')]['name']+_0x2ad5eb('0x1eda'):''}),_0x28e477(_0x142e59);})[_0x1fd9a2('0x1a80')](function(_0x1ac239){const _0x3d1344=_0x1fd9a2;if(_0x1ac239[_0x3d1344('0x25f4')]&&_0x1ac239[_0x3d1344('0x25f4')]['errors']&&_0x1ac239[_0x3d1344('0x25f4')][_0x3d1344('0x61a')]['length']){_0x259e38[_0x3d1344('0x61a')]=_0x1ac239['data'][_0x3d1344('0x61a')]||[{'message':_0x1ac239[_0x3d1344('0x1586')](),'type':_0x3d1344('0x4e9')}];for(let _0x4a2c05=0x0;_0x4a2c05<_0x1ac239[_0x3d1344('0x25f4')][_0x3d1344('0x61a')][_0x3d1344('0x264b')];_0x4a2c05+=0x1){_0x4678df['error']({'title':_0x1ac239['data'][_0x3d1344('0x61a')][_0x4a2c05]['type'],'msg':_0x1ac239['data'][_0x3d1344('0x61a')][_0x4a2c05][_0x3d1344('0x1e70')]});}}else _0x4678df[_0x3d1344('0xfc9')]({'title':_0x1ac239[_0x3d1344('0x52d')]?_0x3d1344('0x1e21')+_0x1ac239['status']+_0x3d1344('0x11e1')+_0x1ac239[_0x3d1344('0xe1b')]:_0x3d1344('0x4e9'),'msg':_0x1ac239[_0x3d1344('0x25f4')]?JSON[_0x3d1344('0xbac')](_0x1ac239[_0x3d1344('0x25f4')][_0x3d1344('0x1e70')]):_0x1ac239[_0x3d1344('0x1586')]()});});}function _0xfc2d71(){const _0x52d380=_0x23c3bf;_0x259e38[_0x52d380('0x61a')]=[],_0x19b9e9['dashboardItem']['update']({'id':_0x259e38[_0x52d380('0x2860')]['id']},_0x259e38['dashboarditem'])['$promise']['then'](function(_0x5cba5d){const _0x16f83b=_0x52d380,_0x578aa9=_0x2cfb05()['find'](_0x259e38[_0x16f83b('0xba2')],{'id':_0x5cba5d['id']});_0x578aa9&&_0x2cfb05()['merge'](_0x578aa9,_0x2cfb05()[_0x16f83b('0x1a08')](_0x5cba5d[_0x16f83b('0x2876')](),_0x2cfb05()[_0x16f83b('0x14a4')](_0x578aa9))),_0x4678df[_0x16f83b('0x103b')]({'title':_0x16f83b('0x1027'),'msg':_0x259e38[_0x16f83b('0x2860')][_0x16f83b('0x4f0')]?_0x259e38[_0x16f83b('0x2860')]['name']+'\x20has\x20been\x20saved!':''}),_0x28e477(_0x5cba5d);})[_0x52d380('0x1a80')](function(_0x457e00){const _0x19f089=_0x52d380;if(_0x457e00[_0x19f089('0x25f4')]&&_0x457e00['data'][_0x19f089('0x61a')]&&_0x457e00[_0x19f089('0x25f4')][_0x19f089('0x61a')]['length']){_0x259e38[_0x19f089('0x61a')]=_0x457e00[_0x19f089('0x25f4')]['errors']||[{'message':_0x457e00[_0x19f089('0x1586')](),'type':'api.dashboardItem.update'}];for(let _0x171e34=0x0;_0x171e34<_0x457e00[_0x19f089('0x25f4')][_0x19f089('0x61a')][_0x19f089('0x264b')];_0x171e34++){_0x4678df['error']({'title':_0x457e00['data'][_0x19f089('0x61a')][_0x171e34][_0x19f089('0x1345')],'msg':_0x457e00[_0x19f089('0x25f4')][_0x19f089('0x61a')][_0x171e34][_0x19f089('0x1e70')]});}}else _0x4678df[_0x19f089('0xfc9')]({'title':_0x457e00[_0x19f089('0x52d')]?_0x19f089('0x1e21')+_0x457e00[_0x19f089('0x52d')]+'\x20-\x20'+_0x457e00['statusText']:_0x19f089('0xb93'),'msg':_0x457e00[_0x19f089('0x25f4')]?JSON['stringify'](_0x457e00['data']['message']):_0x457e00['toString']()});});}function _0x19ec64(_0x1a7497){const _0x2f564c=_0x23c3bf;_0x259e38[_0x2f564c('0x61a')]=[];const _0x1f8649=_0x5a6c01[_0x2f564c('0x1d26')]()['title'](_0x2f564c('0x7fb'))[_0x2f564c('0xacc')](_0x2f564c('0x822'))[_0x2f564c('0x8e8')](_0x2f564c('0x1a8c'))['ok'](_0x2f564c('0x18'))[_0x2f564c('0x3f')](_0x2f564c('0x497'))[_0x2f564c('0x203b')](_0x1a7497);_0x5a6c01['show'](_0x1f8649)[_0x2f564c('0x1166')](function(){const _0x2176a8=_0x2f564c;_0x19b9e9[_0x2176a8('0x20ac')]['delete']({'id':_0x259e38[_0x2176a8('0x2860')]['id']})[_0x2176a8('0xa44')][_0x2176a8('0x1166')](function(){const _0x2b52c8=_0x2176a8;_0x2cfb05()[_0x2b52c8('0x127f')](_0x259e38['dashboard'],{'id':_0x259e38[_0x2b52c8('0x2860')]['id']}),_0x4678df[_0x2b52c8('0x103b')]({'title':_0x2b52c8('0x25c0'),'msg':(_0x259e38[_0x2b52c8('0x2860')][_0x2b52c8('0x4f0')]||_0x2b52c8('0x2860'))+'\x20has\x20been\x20deleted!'}),_0x28e477(_0x259e38[_0x2b52c8('0x2860')]);})[_0x2176a8('0x1a80')](function(_0x115b91){const _0x28712f=_0x2176a8;if(_0x115b91[_0x28712f('0x25f4')]&&_0x115b91[_0x28712f('0x25f4')][_0x28712f('0x61a')]&&_0x115b91[_0x28712f('0x25f4')]['errors'][_0x28712f('0x264b')]){_0x259e38['errors']=_0x115b91[_0x28712f('0x25f4')][_0x28712f('0x61a')]||[{'message':_0x115b91[_0x28712f('0x1586')](),'type':'api.dashboardItem.delete'}];for(let _0x181b31=0x0;_0x181b31<_0x115b91[_0x28712f('0x25f4')][_0x28712f('0x61a')][_0x28712f('0x264b')];_0x181b31++){_0x4678df[_0x28712f('0xfc9')]({'title':_0x115b91[_0x28712f('0x25f4')]['errors'][_0x181b31][_0x28712f('0x1345')],'msg':_0x115b91['data'][_0x28712f('0x61a')][_0x181b31][_0x28712f('0x1e70')]});}}else _0x4678df[_0x28712f('0xfc9')]({'title':_0x115b91[_0x28712f('0x52d')]?_0x28712f('0x1e21')+_0x115b91[_0x28712f('0x52d')]+'\x20-\x20'+_0x115b91[_0x28712f('0xe1b')]:'api.dashboardItem.delete','msg':_0x115b91['data']?JSON[_0x28712f('0xbac')](_0x115b91['data'][_0x28712f('0x1e70')]):_0x115b91[_0x28712f('0x1e70')]||_0x115b91['toString']()});});},function(){});}function _0x548f3e(){const _0x3d238f=_0x23c3bf,_0x2618bf={'core':{'multiple':![],'animation':!![],'error':function(_0x3f22fd){const _0x3c6bfa=a0_0x3f2c;console['error']('treeCtrl:\x20error\x20from\x20js\x20tree\x20-\x20'+angular[_0x3c6bfa('0xd2')](_0x3f22fd));},'check_callback':!![],'worker':!![]},'version':0x1,'plugins':[_0x3d238f('0x164c')]};return _0x259e38[_0x3d238f('0x98')][_0x3d238f('0x1e75')]!=='admin'?_0x19b9e9['userProfileSection'][_0x3d238f('0xd83')]({'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x259e38[_0x3d238f('0x98')][_0x3d238f('0xb86')],'sectionId':0x4b3})[_0x3d238f('0xa44')][_0x3d238f('0x1166')](function(_0xdddf91){const _0x2b1891=_0x3d238f;return _0x259e38[_0x2b1891('0x17aa')]=_0xdddf91&&_0xdddf91['count']==0x1?_0xdddf91[_0x2b1891('0x269a')][0x0]:null,_0x2618bf;})[_0x3d238f('0x1a80')](function(_0x3b93c1){const _0x5ea7cb=_0x3d238f;_0x4678df[_0x5ea7cb('0xfc9')]({'title':_0x5ea7cb('0x2272'),'msg':_0x3b93c1['message']});}):_0x2618bf;}function _0x119086(_0xf098bd){return _0xf098bd?{'loaded':_0x2ddb15,'select_node':_0x206f24}:{'loaded':_0x24d7d5,'select_node':_0x28d8e3};}function _0x206f24(_0x30d298,_0x3fa39d){const _0x3c33a0=_0x23c3bf;_0x259e38[_0x3c33a0('0x18c7')]['jstree'](!![])['deselect_all'](),_0x259e38[_0x3c33a0('0x18c7')][_0x3c33a0('0x14aa')](!![])[_0x3c33a0('0x13e')](),_0x259e38[_0x3c33a0('0xad5')]=_0x3fa39d[_0x3c33a0('0x22d1')],_0x259e38[_0x3c33a0('0xad5')]['custom']=!![],_0x259e38[_0x3c33a0('0x1967')]=_0x259e38[_0x3c33a0('0x1a4b')][_0x3c33a0('0x14aa')](!![])['get_path'](_0x259e38[_0x3c33a0('0xad5')])[_0x3c33a0('0x45a')]('/\x20'),_0x259e38[_0x3c33a0('0x2677')]=_0x3c33a0('0x1ff5'),_0x259e38[_0x3c33a0('0x2218')][_0x3c33a0('0x5f6')]=_0x3fa39d['node']['id'],_0x2595fb();}function _0x28d8e3(_0x568f96,_0x494574){const _0x34ff58=_0x23c3bf;_0x259e38[_0x34ff58('0x1a4b')][_0x34ff58('0x14aa')](!![])[_0x34ff58('0x1314')](),_0x259e38[_0x34ff58('0x1a4b')][_0x34ff58('0x14aa')](!![])['close_all'](),_0x259e38[_0x34ff58('0xad5')]=_0x494574['node'],_0x259e38[_0x34ff58('0xad5')][_0x34ff58('0x2853')]=![],_0x259e38[_0x34ff58('0x1967')]=_0x259e38[_0x34ff58('0x18c7')][_0x34ff58('0x14aa')](!![])[_0x34ff58('0x1fb2')](_0x259e38[_0x34ff58('0xad5')])[_0x34ff58('0x45a')]('/\x20'),_0x259e38['apiName']=_0x34ff58('0x17c2'),_0x259e38['query'][_0x34ff58('0x5f6')]=_0x494574[_0x34ff58('0x22d1')]['id'],_0x2595fb();}function _0x2ddb15(){const _0x2db116=_0x23c3bf;if(!_0x259e38[_0x2db116('0x24de')]&&_0x259e38[_0x2db116('0x2677')]===_0x2db116('0x1ff5')){const _0x306374=_0x259e38['treeCustomInstance']['jstree'](!![])[_0x2db116('0x10de')](_0x259e38[_0x2db116('0x2218')]['parent']);_0x206f24(null,{'node':_0x306374,'selected':_0x306374['id']});}}function _0x24d7d5(){const _0x26f4f9=_0x23c3bf;if(!_0x259e38[_0x26f4f9('0x24de')]&&_0x259e38['apiName']===_0x26f4f9('0x17c2')){const _0x261224=_0x259e38[_0x26f4f9('0x18c7')][_0x26f4f9('0x14aa')](!![])[_0x26f4f9('0x10de')](_0x259e38[_0x26f4f9('0x2218')][_0x26f4f9('0x5f6')]);_0x28d8e3(null,{'node':_0x261224,'selected':_0x261224['id']});}}function _0x2595fb(){const _0x1a8d5e=_0x23c3bf;_0x259e38['query'][_0x1a8d5e('0x1098')]=(_0x259e38[_0x1a8d5e('0x2218')][_0x1a8d5e('0x1a43')]-0x1)*_0x259e38[_0x1a8d5e('0x2218')][_0x1a8d5e('0x163f')];if(_0x259e38[_0x1a8d5e('0x2677')]){if(_0x259e38['currentUser'][_0x1a8d5e('0x1e75')]==='admin')_0x259e38[_0x1a8d5e('0x1f48')]=_0x19b9e9[_0x259e38[_0x1a8d5e('0x2677')]][_0x1a8d5e('0xd83')](_0x259e38[_0x1a8d5e('0x2218')],_0x5b195f)[_0x1a8d5e('0xa44')];else{if(!_0x259e38[_0x1a8d5e('0x17aa')])return _0x5b195f(null);else{if(_0x259e38[_0x1a8d5e('0x17aa')][_0x1a8d5e('0x1a2b')])_0x259e38[_0x1a8d5e('0x1f48')]=_0x19b9e9[_0x259e38[_0x1a8d5e('0x2677')]][_0x1a8d5e('0xd83')](_0x259e38[_0x1a8d5e('0x2218')],_0x5b195f)[_0x1a8d5e('0xa44')];else{let _0x29a52f=[];_0x259e38[_0x1a8d5e('0x1f48')]=_0x19b9e9[_0x259e38[_0x1a8d5e('0x2677')]][_0x1a8d5e('0xd83')](_0x259e38[_0x1a8d5e('0x2218')])[_0x1a8d5e('0xa44')][_0x1a8d5e('0x1166')](function(_0x23720a){const _0x45b082=_0x1a8d5e;return _0x29a52f=_0x23720a&&_0x23720a['rows']?_0x23720a[_0x45b082('0x269a')]:[],_0x29a52f[_0x45b082('0x264b')]>0x0?_0x19b9e9[_0x45b082('0x4b5')][_0x45b082('0xd83')]({'sectionId':_0x259e38[_0x45b082('0x17aa')]['id'],'type':_0x259e38[_0x45b082('0x2677')]===_0x45b082('0x17c2')?_0x45b082('0x2243'):_0x45b082('0x1cc5')})[_0x45b082('0xa44')]['then'](function(_0x206063){const _0x37ae34=_0x45b082,_0x5568f5=_0x206063&&_0x206063[_0x37ae34('0x269a')]?_0x206063['rows']:[];if(_0x5568f5['length']>0x0){const _0x403021=[];return _0x29a52f['forEach'](function(_0x5d2007){const _0x1634a4=_0x37ae34,_0xac81dc=_0x2cfb05()[_0x1634a4('0xc38')](_0x5568f5,[_0x1634a4('0x24e8'),_0x5d2007['id']]);if(_0xac81dc)_0x403021[_0x1634a4('0x1514')](_0x5d2007);}),_0x5b195f({'count':_0x403021[_0x37ae34('0x264b')],'rows':_0x403021});}else return _0x5b195f(null);}):_0x5b195f(null);})[_0x1a8d5e('0x1a80')](function(_0x3f0f90){const _0x42402e=_0x1a8d5e;_0x4678df[_0x42402e('0xfc9')]({'title':_0x3f0f90[_0x42402e('0x52d')]?_0x42402e('0x1e21')+_0x3f0f90['status']+_0x42402e('0x11e1')+_0x3f0f90[_0x42402e('0xe1b')]:'SYSTEM:GET_REPORTS','msg':_0x3f0f90['data']?JSON[_0x42402e('0xbac')](_0x3f0f90[_0x42402e('0x25f4')]):_0x3f0f90[_0x42402e('0x1586')]()});});}}}}}function _0x5b195f(_0x32b141){const _0x5f45e3=_0x23c3bf;_0x259e38['reports']=_0x32b141||{'count':0x0,'rows':[]},!_0x259e38[_0x5f45e3('0x24de')]&&_0x259e38[_0x5f45e3('0x266f')][_0x5f45e3('0x1514')](_0x2cfb05()[_0x5f45e3('0xc38')](_0x259e38[_0x5f45e3('0x352')][_0x5f45e3('0x269a')],{'id':_0x259e38[_0x5f45e3('0x519')]['id']}));}function _0x505dd4(){const _0x4327ba=_0x23c3bf;_0x259e38[_0x4327ba('0x22b')]=_0x259e38[_0x4327ba('0x14c7')][0x0]?angular[_0x4327ba('0x2524')](_0x259e38[_0x4327ba('0x14c7')][0x0][_0x4327ba('0x1b5f')]):[],_0x259e38[_0x4327ba('0x2775')]=_0x259e38[_0x4327ba('0x14c7')][0x1]?angular[_0x4327ba('0x2524')](_0x259e38['treeReports'][0x1][_0x4327ba('0x1b5f')]):[],_0x259e38['treeConfig']=_0x548f3e(),_0x259e38['treeDefaultEvents']=_0x119086(![]),_0x259e38['treeCustomEvents']=_0x119086(!![]),_0x5a6c01[_0x4327ba('0x1f80')]({'controller':function(){return _0x259e38;},'controllerAs':'vm','templateUrl':_0x1c615f,'autoWrap':!![],'skipHide':!![]});}function _0xea1b97(){const _0x79c73c=_0x23c3bf;_0x259e38[_0x79c73c('0x2860')][_0x79c73c('0x2659')]=_0x259e38[_0x79c73c('0x266f')][0x0][_0x79c73c('0x4f0')],_0x259e38[_0x79c73c('0x2860')]['attrReport']=_0x259e38[_0x79c73c('0x266f')][0x0]['id'],_0x259e38[_0x79c73c('0x2860')][_0x79c73c('0x2518')]=_0x259e38[_0x79c73c('0xad5')][_0x79c73c('0x2853')]?_0x79c73c('0x2853'):_0x79c73c('0x1526');if(!_0x259e38[_0x79c73c('0x24de')]){const _0xb4c23={'name':_0x79c73c('0x22fa'),'type':_0x259e38[_0x79c73c('0x2860')][_0x79c73c('0x2518')],'value':_0x259e38[_0x79c73c('0x266f')][0x0]['id']};_0x259e38[_0x79c73c('0x2860')][_0x79c73c('0x2216')]['splice'](_0x2cfb05()[_0x79c73c('0xede')](_0x259e38['dashboarditem'][_0x79c73c('0x2216')],0x1,_0xb4c23));}_0x58de11[_0x79c73c('0x1352')]['report'][_0x79c73c('0x27a2')](),_0x5a6c01[_0x79c73c('0x1197')]();}function _0x45d427(){_0x5a6c01['hide']();}function _0x4e0930(_0x1681ca){return _0x1681ca===null?undefined:new Date(_0x1681ca);}function _0x28e477(_0x342744){const _0x2bcaa9=_0x23c3bf;_0x5a6c01[_0x2bcaa9('0x1197')](_0x342744);}}const _0x4562a6=_0x1285ce,_0x5c9c46=_0x2734b2['p']+_0x36e6f4('0x3be');_0x2621d1['$inject']=['$state',_0x36e6f4('0x25e0'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'api',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5a8'),_0x36e6f4('0x17aa')];function _0x2621d1(_0x260102,_0x62ed10,_0x1eee5a,_0x3a25c9,_0x16af32,_0x411ac5,_0x2f9aff,_0x5e6b26,_0x8bc2a4,_0x103ad9,_0x5d2943,_0x32cbc2){const _0x382a0a=_0x36e6f4,_0x596297=this;_0x596297[_0x382a0a('0x98')]=_0x103ad9[_0x382a0a('0x26cd')](),_0x596297[_0x382a0a('0x5c9')]=_0x411ac5,_0x596297['setting']=_0x2f9aff,_0x596297['passwordPattern']=_0x596297['setting'][_0x382a0a('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x596297[_0x382a0a('0x246b')]=_0x62ed10[_0x382a0a('0x6f1')]()+_0x382a0a('0xc51')+_0x62ed10[_0x382a0a('0x1690')](),_0x596297[_0x382a0a('0x5a8')]=_0x5d2943||_0x260102['params'][_0x382a0a('0x5a8')]||{},_0x596297[_0x382a0a('0x17aa')]=_0x32cbc2&&_0x32cbc2[_0x382a0a('0x240f')]==0x1?_0x32cbc2[_0x382a0a('0x269a')][0x0]:null,_0x596297[_0x382a0a('0x243c')]=_0x103ad9[_0x382a0a('0xd87')](_0x596297[_0x382a0a('0x17aa')]?_0x596297[_0x382a0a('0x17aa')][_0x382a0a('0x243c')]:null),_0x596297[_0x382a0a('0x128b')]={},_0x596297[_0x382a0a('0x2669')]=_0x260102['params'][_0x382a0a('0xbe3')]||0x0,_0x596297[_0x382a0a('0x249d')]=_0x230dd0,_0x596297[_0x382a0a('0x22c1')]=_0x2ad531,_0x596297['alert']=_0x8bc2a4[_0x382a0a('0x1fa1')],_0x596297[_0x382a0a('0x21d9')]=_0x354f7c,_0x596297[_0x382a0a('0x1cd')]=_0x13d49b;function _0x230dd0(_0xd2ec2f,_0x2e7369){const _0x455308=_0x382a0a;_0x1eee5a[_0x455308('0x1f80')]({'controller':_0x455308('0x268a'),'controllerAs':'vm','templateUrl':_0x5c9c46,'parent':angular[_0x455308('0x1194')](_0x3a25c9['body']),'targetEvent':_0x2e7369,'clickOutsideToClose':!![],'locals':{'customDashboard':_0xd2ec2f,'customDashboards':_0x596297['customDashboards']?_0x596297[_0x455308('0x1780')][_0x455308('0x269a')]:[],'crudPermissions':_0x596297[_0x455308('0x243c')]}});}function _0x2ad531(_0x143fc8){const _0x4b3ae3=_0x382a0a;_0x260102['go'](_0x4b3ae3('0x20d7'),{'id':_0x143fc8['id']});}function _0x354f7c(){_0x260102['go']('app.tools.customDashboards',{},{'reload':'app.tools.customDashboards'});}function _0x13d49b(){const _0x3c4c9f=_0x382a0a;_0x5e6b26[_0x3c4c9f('0xba2')][_0x3c4c9f('0x1449')]({'id':_0x596297[_0x3c4c9f('0x5a8')]['id']},_0x596297[_0x3c4c9f('0x5a8')])[_0x3c4c9f('0xa44')][_0x3c4c9f('0x1166')](function(){const _0x59ba73=_0x3c4c9f;_0x8bc2a4[_0x59ba73('0x103b')]({'title':'CustomDashboard\x20updated!','msg':_0x596297[_0x59ba73('0x5a8')][_0x59ba73('0x4f0')]?_0x596297[_0x59ba73('0x5a8')][_0x59ba73('0x4f0')]+_0x59ba73('0xa17'):''});})[_0x3c4c9f('0x1a80')](function(_0x31abb7){const _0x680b05=_0x3c4c9f;_0x8bc2a4[_0x680b05('0xfc9')]({'title':_0x31abb7[_0x680b05('0x52d')]?'API:'+_0x31abb7['status']+'\x20-\x20'+_0x31abb7[_0x680b05('0xe1b')]:_0x680b05('0x2e3'),'msg':_0x31abb7[_0x680b05('0x25f4')]?JSON[_0x680b05('0xbac')](_0x31abb7[_0x680b05('0x25f4')]):_0x31abb7[_0x680b05('0x1586')]()});});}}const _0x3bd291=_0x2621d1;_0x3a9655[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0x164e'),_0x36e6f4('0x277c'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting','crudPermissions'];function _0x3a9655(_0x35e1c8,_0x4deb32,_0x2a40b6,_0x505c0e,_0x305f11,_0x32faed,_0x3811b6,_0x361e89,_0x26bf86,_0x3986ed,_0x12c03f,_0x415bca,_0x331b63,_0x26bc14){const _0x2300da=_0x36e6f4,_0x21b76c=this;_0x21b76c['currentUser']=_0x12c03f[_0x2300da('0x26cd')](),_0x21b76c[_0x2300da('0x61a')]=[],_0x21b76c[_0x2300da('0xf8a')]=_0x331b63,_0x21b76c['license']=_0x415bca,_0x21b76c[_0x2300da('0x243c')]=_0x26bc14,_0x21b76c[_0x2300da('0x128b')]={},_0x21b76c[_0x2300da('0x2900')]=_0x21b76c[_0x2300da('0xf8a')]&&_0x21b76c['setting'][_0x2300da('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x21b76c['title']='TOOLS.EDIT_INTERVAL',_0x21b76c['interval']=angular[_0x2300da('0x225f')](_0x26bf86),_0x21b76c[_0x2300da('0x164e')]=_0x361e89,_0x21b76c[_0x2300da('0x99d')]=![];!_0x21b76c['interval']&&(_0x21b76c[_0x2300da('0x277c')]={},_0x21b76c[_0x2300da('0xcdc')]=_0x2300da('0x412'),_0x21b76c[_0x2300da('0x99d')]=!![]);_0x21b76c[_0x2300da('0x1ebf')]=_0xcd81c1,_0x21b76c[_0x2300da('0x24be')]=_0x5c868d,_0x21b76c[_0x2300da('0x1f41')]=_0x12ad5e,_0x21b76c[_0x2300da('0x1a9c')]=_0x1a0414,_0x21b76c['closeDialog']=_0x5bfc62;function _0xcd81c1(){const _0x30d9a9=_0x2300da;_0x21b76c[_0x30d9a9('0x61a')]=[],_0x3986ed[_0x30d9a9('0x277c')][_0x30d9a9('0x9cc')](_0x21b76c[_0x30d9a9('0x277c')])['$promise'][_0x30d9a9('0x1166')](function(_0x5b1d6c){const _0x26c6e7=_0x30d9a9;_0x21b76c[_0x26c6e7('0x164e')][_0x26c6e7('0x2450')](_0x5b1d6c[_0x26c6e7('0x2876')]()),_0x3811b6[_0x26c6e7('0x103b')]({'title':_0x26c6e7('0xf10'),'msg':_0x21b76c['interval'][_0x26c6e7('0x4f0')]?_0x21b76c['interval'][_0x26c6e7('0x4f0')]+_0x26c6e7('0x1eda'):''}),_0x5bfc62(_0x5b1d6c);})[_0x30d9a9('0x1a80')](function(_0x395c48){const _0x3ebc23=_0x30d9a9;if(_0x395c48[_0x3ebc23('0x25f4')]&&_0x395c48[_0x3ebc23('0x25f4')]['errors']&&_0x395c48['data'][_0x3ebc23('0x61a')][_0x3ebc23('0x264b')]){_0x21b76c[_0x3ebc23('0x61a')]=_0x395c48[_0x3ebc23('0x25f4')]['errors']||[{'message':_0x395c48[_0x3ebc23('0x1586')](),'type':_0x3ebc23('0x1192')}];for(let _0x1d8765=0x0;_0x1d8765<_0x395c48[_0x3ebc23('0x25f4')][_0x3ebc23('0x61a')][_0x3ebc23('0x264b')];_0x1d8765+=0x1){_0x3811b6[_0x3ebc23('0xfc9')]({'title':_0x395c48[_0x3ebc23('0x25f4')][_0x3ebc23('0x61a')][_0x1d8765][_0x3ebc23('0x1345')],'msg':_0x395c48['data'][_0x3ebc23('0x61a')][_0x1d8765][_0x3ebc23('0x1e70')]});}}else _0x3811b6[_0x3ebc23('0xfc9')]({'title':_0x395c48[_0x3ebc23('0x52d')]?_0x3ebc23('0x1e21')+_0x395c48[_0x3ebc23('0x52d')]+_0x3ebc23('0x11e1')+_0x395c48[_0x3ebc23('0xe1b')]:_0x3ebc23('0x1192'),'msg':_0x395c48[_0x3ebc23('0x25f4')]?JSON[_0x3ebc23('0xbac')](_0x395c48[_0x3ebc23('0x25f4')]['message']):_0x395c48[_0x3ebc23('0x1586')]()});});}function _0x5c868d(){const _0x2b4aba=_0x2300da;_0x21b76c[_0x2b4aba('0x61a')]=[],_0x3986ed[_0x2b4aba('0x277c')]['update']({'id':_0x21b76c[_0x2b4aba('0x277c')]['id']},_0x21b76c['interval'])['$promise'][_0x2b4aba('0x1166')](function(_0x22f230){const _0xaf2223=_0x2b4aba,_0x82796a=_0x2cfb05()['find'](_0x21b76c[_0xaf2223('0x164e')],{'id':_0x22f230['id']});_0x82796a&&_0x2cfb05()['merge'](_0x82796a,_0x2cfb05()[_0xaf2223('0x1a08')](_0x22f230[_0xaf2223('0x2876')](),_0x2cfb05()[_0xaf2223('0x14a4')](_0x82796a))),_0x3811b6[_0xaf2223('0x103b')]({'title':_0xaf2223('0x1243'),'msg':_0x21b76c[_0xaf2223('0x277c')][_0xaf2223('0x4f0')]?_0x21b76c[_0xaf2223('0x277c')][_0xaf2223('0x4f0')]+_0xaf2223('0x7d'):''}),_0x5bfc62(_0x22f230);})[_0x2b4aba('0x1a80')](function(_0x5ce3a6){const _0x1d91ff=_0x2b4aba;if(_0x5ce3a6['data']&&_0x5ce3a6[_0x1d91ff('0x25f4')]['errors']&&_0x5ce3a6[_0x1d91ff('0x25f4')][_0x1d91ff('0x61a')]['length']){_0x21b76c[_0x1d91ff('0x61a')]=_0x5ce3a6[_0x1d91ff('0x25f4')][_0x1d91ff('0x61a')]||[{'message':_0x5ce3a6[_0x1d91ff('0x1586')](),'type':_0x1d91ff('0x2725')}];for(let _0x43a56c=0x0;_0x43a56c<_0x5ce3a6[_0x1d91ff('0x25f4')][_0x1d91ff('0x61a')][_0x1d91ff('0x264b')];_0x43a56c++){_0x3811b6[_0x1d91ff('0xfc9')]({'title':_0x5ce3a6[_0x1d91ff('0x25f4')][_0x1d91ff('0x61a')][_0x43a56c]['type'],'msg':_0x5ce3a6['data'][_0x1d91ff('0x61a')][_0x43a56c][_0x1d91ff('0x1e70')]});}}else _0x3811b6[_0x1d91ff('0xfc9')]({'title':_0x5ce3a6['status']?_0x1d91ff('0x1e21')+_0x5ce3a6['status']+_0x1d91ff('0x11e1')+_0x5ce3a6['statusText']:_0x1d91ff('0x2725'),'msg':_0x5ce3a6[_0x1d91ff('0x25f4')]?JSON[_0x1d91ff('0xbac')](_0x5ce3a6[_0x1d91ff('0x25f4')][_0x1d91ff('0x1e70')]):_0x5ce3a6[_0x1d91ff('0x1586')]()});});}function _0x12ad5e(_0x114c8d){const _0x121728=_0x2300da;_0x21b76c['errors']=[];const _0x2b48b3=_0x505c0e[_0x121728('0x1d26')]()[_0x121728('0xcdc')](_0x121728('0x7fb'))[_0x121728('0xacc')](_0x121728('0x15bf'))[_0x121728('0x8e8')]('Delete\x20Interval')['ok']('Delete')['cancel'](_0x121728('0x497'))[_0x121728('0x203b')](_0x114c8d);_0x505c0e['show'](_0x2b48b3)[_0x121728('0x1166')](function(){const _0xf4a789=_0x121728;_0x3986ed[_0xf4a789('0x277c')][_0xf4a789('0x906')]({'id':_0x21b76c[_0xf4a789('0x277c')]['id']})[_0xf4a789('0xa44')][_0xf4a789('0x1166')](function(){const _0x38cac8=_0xf4a789;_0x2cfb05()[_0x38cac8('0x127f')](_0x21b76c[_0x38cac8('0x164e')],{'id':_0x21b76c[_0x38cac8('0x277c')]['id']}),_0x3811b6[_0x38cac8('0x103b')]({'title':'Interval\x20properly\x20deleted!','msg':(_0x21b76c[_0x38cac8('0x277c')][_0x38cac8('0x4f0')]||_0x38cac8('0x277c'))+_0x38cac8('0x7cd')}),_0x5bfc62(_0x21b76c[_0x38cac8('0x277c')]);})[_0xf4a789('0x1a80')](function(_0x778556){const _0x4a1bb4=_0xf4a789;if(_0x778556[_0x4a1bb4('0x25f4')]&&_0x778556[_0x4a1bb4('0x25f4')][_0x4a1bb4('0x61a')]&&_0x778556[_0x4a1bb4('0x25f4')]['errors'][_0x4a1bb4('0x264b')]){_0x21b76c[_0x4a1bb4('0x61a')]=_0x778556[_0x4a1bb4('0x25f4')][_0x4a1bb4('0x61a')]||[{'message':_0x778556[_0x4a1bb4('0x1586')](),'type':_0x4a1bb4('0x71f')}];for(let _0x3e88a3=0x0;_0x3e88a3<_0x778556[_0x4a1bb4('0x25f4')][_0x4a1bb4('0x61a')]['length'];_0x3e88a3++){_0x3811b6[_0x4a1bb4('0xfc9')]({'title':_0x778556[_0x4a1bb4('0x25f4')][_0x4a1bb4('0x61a')][_0x3e88a3][_0x4a1bb4('0x1345')],'msg':_0x778556[_0x4a1bb4('0x25f4')]['errors'][_0x3e88a3][_0x4a1bb4('0x1e70')]});}}else _0x3811b6['error']({'title':_0x778556[_0x4a1bb4('0x52d')]?_0x4a1bb4('0x1e21')+_0x778556['status']+_0x4a1bb4('0x11e1')+_0x778556['statusText']:'api.interval.delete','msg':_0x778556[_0x4a1bb4('0x25f4')]?JSON[_0x4a1bb4('0xbac')](_0x778556['data'][_0x4a1bb4('0x1e70')]):_0x778556['message']||_0x778556[_0x4a1bb4('0x1586')]()});});},function(){});}function _0x1a0414(_0x2e47fa){return _0x2e47fa===null?undefined:new Date(_0x2e47fa);}function _0x5bfc62(_0x53eae2){const _0x2f1970=_0x2300da;_0x505c0e[_0x2f1970('0x1197')](_0x53eae2);}}const _0x509036=_0x3a9655;_0x45fca4[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),'$mdDialog',_0x36e6f4('0x25d0'),_0x36e6f4('0x124d'),_0x36e6f4('0x277c'),_0x36e6f4('0x164e'),'toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x45fca4(_0x2f9198,_0x77f27f,_0x22a48d,_0x4ad268,_0x16456f,_0xa17cc5,_0x3c7d28,_0x7fb466,_0x4588c4,_0x4f8cad){const _0x5be18c=_0x36e6f4,_0x9acc94=this;_0x9acc94['currentUser']=_0x4588c4['getCurrentUser'](),_0x9acc94[_0x5be18c('0x61a')]=[],_0x9acc94['title']=_0x5be18c('0x2879'),_0x9acc94['interval']=angular['copy'](_0x16456f),_0x9acc94['intervals']=_0xa17cc5,_0x9acc94['newInterval']=![],_0x9acc94['types']=[_0x5be18c('0x597'),_0x5be18c('0x2853')],_0x9acc94['crudPermissions']=_0x4f8cad,_0x9acc94['daysOfWeek']=_0x4ad268[_0x5be18c('0x28de')](),_0x9acc94[_0x5be18c('0x10b4')]=_0x4ad268[_0x5be18c('0x51d')](),_0x9acc94[_0x5be18c('0x2259')]=_0x4ad268[_0x5be18c('0x1c39')](),_0x9acc94['daysOfMonth']=_0x4ad268[_0x5be18c('0x2489')]();if(!_0x9acc94[_0x5be18c('0x277c')])_0x9acc94[_0x5be18c('0x277c')]={'interval':'*,*,*,*'},_0x9acc94['type']=_0x5be18c('0x597'),_0x9acc94[_0x5be18c('0xcdc')]=_0x5be18c('0x412'),_0x9acc94[_0x5be18c('0x99d')]=!![];else{if(_0x9acc94['interval'][_0x5be18c('0x277c')]!==_0x5be18c('0x16f')){_0x9acc94['type']='custom';const _0x4ed18a=_0x9acc94['interval']['interval']['split'](','),_0x3f20a9=_0x4ed18a[0x0],_0x47aae3=_0x4ed18a[0x1],_0x2b3687=_0x4ed18a[0x2],_0x4b0b3a=_0x4ed18a[0x3];if(_0x3f20a9!=='*'){const _0x2e3bdb=_0x3f20a9[_0x5be18c('0x25c8')]('-')[0x0],_0x5de955=_0x3f20a9[_0x5be18c('0x25c8')]('-')[0x1];let _0xb2ba2e;_0xb2ba2e=new Date(),_0xb2ba2e[_0x5be18c('0xe24')](Number(_0x2e3bdb['split'](':')[0x0])),_0xb2ba2e[_0x5be18c('0x790')](Number(_0x2e3bdb['split'](':')[0x1])),_0x9acc94[_0x5be18c('0x64d')]=_0xb2ba2e,_0xb2ba2e=new Date(),_0xb2ba2e[_0x5be18c('0xe24')](Number(_0x5de955[_0x5be18c('0x25c8')](':')[0x0])),_0xb2ba2e['setMinutes'](Number(_0x5de955[_0x5be18c('0x25c8')](':')[0x1])),_0x9acc94[_0x5be18c('0x2076')]=_0xb2ba2e;}_0x47aae3!=='*'&&(_0x9acc94['dayOfWeekFrom']=_0x47aae3[_0x5be18c('0x25c8')]('-')[0x0],_0x9acc94[_0x5be18c('0x1b81')]=_0x47aae3[_0x5be18c('0x25c8')]('-')[0x1]),_0x2b3687!=='*'&&(_0x9acc94['monthDayFrom']=_0x2b3687['split']('-')[0x0],_0x9acc94[_0x5be18c('0x1dbb')]=_0x2b3687[_0x5be18c('0x25c8')]('-')[0x1]),_0x4b0b3a!=='*'&&(_0x9acc94['monthFrom']=_0x4b0b3a[_0x5be18c('0x25c8')]('-')[0x0],_0x9acc94[_0x5be18c('0x1125')]=_0x4b0b3a[_0x5be18c('0x25c8')]('-')[0x1]);}else _0x9acc94[_0x5be18c('0x1345')]=_0x5be18c('0x597');}_0x2f9198[_0x5be18c('0x23f')]['id']&&!_0x9acc94[_0x5be18c('0x277c')]['application']&&(_0x9acc94['interval']['IntervalId']=_0x2f9198[_0x5be18c('0x23f')]['id']);_0x9acc94['interval'][_0x5be18c('0x186f')]&&_0x9acc94[_0x5be18c('0x277c')][_0x5be18c('0x50d')]&&(_0x9acc94[_0x5be18c('0x1345')]='list');_0x9acc94['addNewInterval']=_0x5b3038,_0x9acc94[_0x5be18c('0x24be')]=_0x33a2e0,_0x9acc94[_0x5be18c('0x24a0')]=_0x226b9b;_0x9acc94['interval'][_0x5be18c('0x50d')]&&(_0x4588c4[_0x5be18c('0x1ac6')](_0x5be18c('0xa7c'))?_0x7fb466[_0x5be18c('0x277c')][_0x5be18c('0xd83')]({'fields':_0x5be18c('0xd0a'),'IntervalId':_0x5be18c('0x15d7'),'nolimit':!![]})[_0x5be18c('0xa44')][_0x5be18c('0x1166')](function(_0x358dd0){const _0x40d754=_0x5be18c;_0x9acc94['intervals']=_0x358dd0[_0x40d754('0x269a')]||[];})[_0x5be18c('0x1a80')](function(_0x44e600){const _0x4b9507=_0x5be18c;_0x3c7d28[_0x4b9507('0xfc9')]({'title':_0x44e600[_0x4b9507('0x52d')]?_0x4b9507('0x1e21')+_0x44e600[_0x4b9507('0x52d')]+'\x20-\x20'+_0x44e600[_0x4b9507('0xe1b')]:'SYSTEM:GET_INTERVALS','msg':_0x44e600[_0x4b9507('0x25f4')]?JSON[_0x4b9507('0xbac')](_0x44e600['data']):_0x44e600[_0x4b9507('0x1586')]()});}):_0x7fb466[_0x5be18c('0x277c')]['get']({'fields':_0x5be18c('0xd0a'),'IntervalId':_0x5be18c('0x15d7'),'nolimit':!![]})[_0x5be18c('0xa44')][_0x5be18c('0x1166')](function(_0x4c03de){const _0x37b9d1=_0x5be18c;_0x9acc94[_0x37b9d1('0x164e')]=_0x4c03de['rows']||[];})['then'](function(){const _0x32d6cc=_0x5be18c;return _0x7fb466[_0x32d6cc('0x17aa')]['get']({'userProfileId':_0x9acc94['currentUser'][_0x32d6cc('0xb86')],'sectionId':0x3ec})[_0x32d6cc('0xa44')];})[_0x5be18c('0x1166')](function(_0x4a89e8){const _0x16a445=_0x5be18c,_0x52a9c0=_0x4a89e8&&_0x4a89e8[_0x16a445('0x269a')]?_0x4a89e8[_0x16a445('0x269a')][0x0]:null;if(!_0x52a9c0)_0x9acc94['intervals']=[];else{if(!_0x52a9c0[_0x16a445('0x1a2b')])return _0x7fb466[_0x16a445('0x4b5')][_0x16a445('0xd83')]({'sectionId':_0x52a9c0['id']})['$promise'][_0x16a445('0x1166')](function(_0x281f65){const _0x58eb7e=_0x16a445,_0x3d3bea=_0x281f65&&_0x281f65[_0x58eb7e('0x269a')]?_0x281f65[_0x58eb7e('0x269a')]:[],_0x3cd0ce=[];let _0x44bd8d=null;_0x9acc94[_0x58eb7e('0x277c')]&&(_0x44bd8d=_0x2cfb05()['find'](_0x9acc94[_0x58eb7e('0x164e')],{'name':_0x9acc94['interval']['IntervalId']})),_0x44bd8d&&!_0x2cfb05()[_0x58eb7e('0x1798')](_0x3d3bea,[_0x58eb7e('0x24e8'),_0x44bd8d['id']])&&_0x9acc94[_0x58eb7e('0x164e')][_0x58eb7e('0x2782')](function(_0x3eca16){const _0x3884ca=_0x58eb7e;_0x3eca16['id']===_0x44bd8d['id']&&(_0x3eca16[_0x3884ca('0x2378')]=![],_0x3cd0ce[_0x3884ca('0x1514')](_0x3eca16));}),_0x9acc94[_0x58eb7e('0x164e')]=_0x3cd0ce;});}})[_0x5be18c('0x1a80')](function(_0x1e5579){const _0x402b58=_0x5be18c;_0x3c7d28[_0x402b58('0xfc9')]({'title':_0x1e5579['status']?'API:'+_0x1e5579[_0x402b58('0x52d')]+_0x402b58('0x11e1')+_0x1e5579[_0x402b58('0xe1b')]:_0x402b58('0xbb4'),'msg':_0x1e5579[_0x402b58('0x25f4')]?JSON[_0x402b58('0xbac')](_0x1e5579['data']):_0x1e5579[_0x402b58('0x1586')]()});}));function _0x2813c1(){const _0x3d4780=_0x5be18c;switch(_0x9acc94[_0x3d4780('0x1345')]){case _0x3d4780('0x597'):case _0x3d4780('0x1480'):return _0x3d4780('0x16f');case _0x3d4780('0x2853'):{const _0x564e26=[];if(_0x9acc94[_0x3d4780('0x64d')]!=='*'&&_0x9acc94[_0x3d4780('0x64d')]&&_0x9acc94['timeRangeTo']){const _0x3403d9=(_0x9acc94[_0x3d4780('0x64d')][_0x3d4780('0x11fe')]()<0xa?'0':'')+_0x9acc94[_0x3d4780('0x64d')][_0x3d4780('0x11fe')]()+':'+((_0x9acc94[_0x3d4780('0x64d')][_0x3d4780('0x234')]()<0xa?'0':'')+_0x9acc94[_0x3d4780('0x64d')][_0x3d4780('0x234')]()),_0x43740a=(_0x9acc94[_0x3d4780('0x2076')][_0x3d4780('0x11fe')]()<0xa?'0':'')+_0x9acc94['timeRangeTo'][_0x3d4780('0x11fe')]()+':'+((_0x9acc94['timeRangeTo'][_0x3d4780('0x234')]()<0xa?'0':'')+_0x9acc94[_0x3d4780('0x2076')]['getMinutes']());_0x564e26['push'](_0x3403d9+'-'+_0x43740a);}else _0x564e26[_0x3d4780('0x1514')]('*');return _0x9acc94[_0x3d4780('0x1eca')]?_0x9acc94['dayOfWeekTo']?_0x564e26[_0x3d4780('0x1514')](_0x9acc94['dayOfWeekFrom']+'-'+_0x9acc94[_0x3d4780('0x1b81')]):_0x564e26[_0x3d4780('0x1514')](_0x9acc94[_0x3d4780('0x1eca')]):_0x564e26[_0x3d4780('0x1514')]('*'),_0x9acc94['monthDayFrom']?_0x9acc94['monthDayTo']?_0x564e26['push'](_0x9acc94[_0x3d4780('0x103d')]+'-'+_0x9acc94[_0x3d4780('0x1dbb')]):_0x564e26[_0x3d4780('0x1514')](_0x9acc94[_0x3d4780('0x103d')]):_0x564e26[_0x3d4780('0x1514')]('*'),_0x9acc94[_0x3d4780('0xdec')]?_0x9acc94[_0x3d4780('0x1125')]?_0x564e26[_0x3d4780('0x1514')](_0x9acc94['monthFrom']+'-'+_0x9acc94['monthTo']):_0x564e26['push'](_0x9acc94[_0x3d4780('0xdec')]):_0x564e26[_0x3d4780('0x1514')]('*'),_0x564e26[_0x3d4780('0x45a')]();}}}function _0x5b3038(){const _0x3dc833=_0x5be18c;_0x9acc94[_0x3dc833('0x61a')]=[],_0x9acc94[_0x3dc833('0x277c')]['interval']=_0x2813c1(),_0x7fb466[_0x3dc833('0x277c')]['save'](_0x9acc94[_0x3dc833('0x277c')])[_0x3dc833('0xa44')][_0x3dc833('0x1166')](function(_0x419dcb){const _0x2cbe31=_0x3dc833;_0x9acc94[_0x2cbe31('0x164e')][_0x2cbe31('0x1514')](_0x419dcb),_0x3c7d28['success']({'title':_0x2cbe31('0xf10'),'msg':_0x9acc94[_0x2cbe31('0x277c')][_0x2cbe31('0x4f0')]?_0x9acc94[_0x2cbe31('0x277c')][_0x2cbe31('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x226b9b();})[_0x3dc833('0x1a80')](function(_0x4fd15e){const _0x667a49=_0x3dc833;console[_0x667a49('0xfc9')](_0x4fd15e),_0x9acc94[_0x667a49('0x61a')]=_0x4fd15e[_0x667a49('0x25f4')][_0x667a49('0x61a')]||[{'message':_0x4fd15e[_0x667a49('0x1586')](),'type':_0x667a49('0x1192')}];});}function _0x33a2e0(){const _0x2eb053=_0x5be18c;_0x9acc94[_0x2eb053('0x61a')]=[],_0x9acc94[_0x2eb053('0x277c')]['interval']=_0x2813c1(),_0x9acc94[_0x2eb053('0x277c')][_0x2eb053('0x50d')]?(_0x9acc94[_0x2eb053('0x1345')]!==_0x2eb053('0x1480')&&(_0x9acc94['interval'][_0x2eb053('0x186f')]=null),_0x226b9b(_0x9acc94['interval'])):_0x7fb466[_0x2eb053('0x277c')][_0x2eb053('0x1449')]({'id':_0x9acc94['interval']['id']},_0x9acc94[_0x2eb053('0x277c')])[_0x2eb053('0xa44')][_0x2eb053('0x1166')](function(_0x3737b8){const _0x132698=_0x2eb053,_0x5abcc1=_0x2cfb05()[_0x132698('0xc38')](_0x9acc94[_0x132698('0x164e')],{'id':_0x3737b8['id']});_0x5abcc1&&_0x2cfb05()['merge'](_0x5abcc1,_0x3737b8),_0x3c7d28[_0x132698('0x103b')]({'title':_0x132698('0x1243'),'msg':_0x132698('0x1666')}),_0x226b9b();})[_0x2eb053('0x1a80')](function(_0x27333c){const _0x31b7ee=_0x2eb053;console['error'](_0x27333c),_0x9acc94[_0x31b7ee('0x61a')]=_0x27333c['data'][_0x31b7ee('0x61a')]||[{'message':_0x27333c[_0x31b7ee('0x1586')](),'type':_0x31b7ee('0x2725')}];});}function _0x226b9b(_0x493a95){_0x77f27f['hide'](_0x493a95);}}const _0x4cb4df=_0x45fca4,_0x4c8c01=_0x2734b2['p']+_0x36e6f4('0xc6a');_0x2d5c7e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),'$scope',_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x2d5c7e(_0x4fadca,_0xda74f4,_0x4af07f,_0x388874,_0x7f8743,_0xda85f1,_0x2408ea,_0x217550,_0x3a9036,_0x55a69d,_0x5a3c29){const _0x1f2adf=_0x36e6f4,_0x1d1c06=this;_0x1d1c06[_0x1f2adf('0x98')]=_0x5a3c29[_0x1f2adf('0x26cd')](),_0x1d1c06[_0x1f2adf('0x277c')]={},_0x1d1c06[_0x1f2adf('0x1453')]={'count':0x0,'rows':[]},_0x1d1c06['selectedIntervalIntervals']=[],_0x1d1c06[_0x1f2adf('0x243c')],_0x1d1c06[_0x1f2adf('0x2207')]={'animation':0x64,'onSort':function(_0xfba525){const _0x2b0e5a=_0x1f2adf;_0x55a69d[_0x2b0e5a('0x277c')]['addIntervals']({'id':_0x1d1c06['interval']['id']},_0xfba525[_0x2b0e5a('0xf1')])[_0x2b0e5a('0xa44')][_0x2b0e5a('0x1166')](function(_0x5c8b6a){const _0xf9995d=_0x2b0e5a;_0x1d1c06[_0xf9995d('0x1453')][_0xf9995d('0x269a')]=_0x5c8b6a;})[_0x2b0e5a('0x1a80')](function(_0x1fcd22){const _0x44b764=_0x2b0e5a;_0x3a9036[_0x44b764('0xfc9')]({'title':_0x1fcd22['status']?_0x44b764('0x1e21')+_0x1fcd22['status']+_0x44b764('0x11e1')+_0x1fcd22['statusText']:'SYSTEM:SORTABLETABLE','msg':_0x1fcd22[_0x44b764('0x25f4')]?JSON[_0x44b764('0xbac')](_0x1fcd22[_0x44b764('0x25f4')]):_0x1fcd22[_0x44b764('0x1586')]()});});}},_0x1d1c06[_0x1f2adf('0x2218')]={'fields':_0x1f2adf('0xbbb'),'nolimit':'true','limit':0xa,'page':0x1},_0x1d1c06[_0x1f2adf('0x24d5')]=_0xa93085,_0x1d1c06[_0x1f2adf('0x8a2')]=_0x12fde1,_0x1d1c06[_0x1f2adf('0x103b')]=_0xba5133,_0x1d1c06[_0x1f2adf('0xf93')]=_0x2f3569,_0x1d1c06[_0x1f2adf('0xf18')]=_0x2467f1,_0x1d1c06[_0x1f2adf('0xfc0')]=_0x3b5bbf,_0x1d1c06[_0x1f2adf('0x11d7')]=_0x173dff,_0x1d1c06['deleteSelectedIntervalIntervals']=_0x19627e;function _0xa93085(_0x20f686,_0x3cf1b5){const _0x5c99c1=_0x1f2adf;_0x1d1c06[_0x5c99c1('0x277c')]=_0x20f686,_0x1d1c06[_0x5c99c1('0x243c')]=typeof _0x3cf1b5!==_0x5c99c1('0x1048')?_0x3cf1b5:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1d1c06['sortableTable'][_0x5c99c1('0xbd0')]=!_0x1d1c06[_0x5c99c1('0x243c')][_0x5c99c1('0x1684')]?!![]:![],_0x1d1c06[_0x5c99c1('0x2218')]['id']=_0x1d1c06[_0x5c99c1('0x277c')]['id'],_0x2f3569();}function _0x12fde1(_0x3cac0c,_0x373bae){const _0xad0b1e=_0x1f2adf,_0x2bfe01=_0x2408ea[_0xad0b1e('0x1d26')]()[_0xad0b1e('0xcdc')](_0xad0b1e('0x18ca'))[_0xad0b1e('0xf3c')](_0xad0b1e('0x12b5')+(_0x3cac0c[_0xad0b1e('0x4f0')]||_0x3cac0c['id']&&_0x2cfb05()[_0xad0b1e('0x114b')](_0xad0b1e('0x19ea'))+_0x3cac0c['id']||'interval')+_0xad0b1e('0xace')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0xad0b1e('0x99a'))[_0xad0b1e('0x203b')](_0x373bae)['ok']('OK')[_0xad0b1e('0x3f')](_0xad0b1e('0x2d3'));_0x2408ea['show'](_0x2bfe01)['then'](function(){_0x173dff(_0x3cac0c);},function(){const _0x3c9fc0=_0xad0b1e;console['log'](_0x3c9fc0('0x2d3'));});}function _0xba5133(_0x17d821){_0x1d1c06['intervalIntervals']=_0x17d821||{'count':0x0,'rows':[]};}function _0x2f3569(){const _0x53c8fb=_0x1f2adf;_0x1d1c06['query'][_0x53c8fb('0x1098')]=(_0x1d1c06['query'][_0x53c8fb('0x1a43')]-0x1)*_0x1d1c06[_0x53c8fb('0x2218')]['limit'],_0x1d1c06['promise']=_0x55a69d[_0x53c8fb('0x277c')][_0x53c8fb('0x242')](_0x1d1c06[_0x53c8fb('0x2218')],_0xba5133)[_0x53c8fb('0xa44')];}function _0x2467f1(_0x321e8e,_0x25b69d){const _0x2975ed=_0x1f2adf;_0x2408ea[_0x2975ed('0x1f80')]({'controller':_0x2975ed('0x11d2'),'controllerAs':'vm','templateUrl':_0x4c8c01,'parent':angular[_0x2975ed('0x1194')](_0x217550[_0x2975ed('0x8d2')]),'targetEvent':_0x321e8e,'clickOutsideToClose':!![],'locals':{'interval':_0x25b69d,'intervals':_0x1d1c06['intervalIntervals'][_0x2975ed('0x269a')],'license':null,'setting':null,'crudPermissions':_0x1d1c06[_0x2975ed('0x243c')]}});}function _0x173dff(_0x430253){const _0x1addcf=_0x1f2adf;_0x55a69d[_0x1addcf('0x277c')][_0x1addcf('0x906')]({'id':_0x430253['id']})['$promise'][_0x1addcf('0x1166')](function(){const _0x171191=_0x1addcf;_0x2cfb05()[_0x171191('0x127f')](_0x1d1c06[_0x171191('0x1453')][_0x171191('0x269a')],{'id':_0x430253['id']}),_0x1d1c06[_0x171191('0x1453')][_0x171191('0x240f')]-=0x1,!_0x1d1c06[_0x171191('0x1453')][_0x171191('0x269a')][_0x171191('0x264b')]&&_0x2f3569(),_0x3a9036[_0x171191('0x103b')]({'title':_0x171191('0x1c3a'),'msg':_0x430253['name']?_0x430253[_0x171191('0x4f0')]+_0x171191('0x7cd'):''});})['catch'](function(_0x1d09c5){const _0x2285f4=_0x1addcf;if(_0x1d09c5[_0x2285f4('0x25f4')]&&_0x1d09c5[_0x2285f4('0x25f4')][_0x2285f4('0x61a')]&&_0x1d09c5['data']['errors'][_0x2285f4('0x264b')]){_0x1d1c06[_0x2285f4('0x61a')]=_0x1d09c5[_0x2285f4('0x25f4')]['errors']||[{'message':_0x1d09c5[_0x2285f4('0x1586')](),'type':_0x2285f4('0xe48')}];for(let _0x3fcc88=0x0;_0x3fcc88<_0x1d09c5[_0x2285f4('0x25f4')][_0x2285f4('0x61a')][_0x2285f4('0x264b')];_0x3fcc88++){_0x3a9036[_0x2285f4('0xfc9')]({'title':_0x1d09c5['data'][_0x2285f4('0x61a')][_0x3fcc88][_0x2285f4('0x1345')],'msg':_0x1d09c5[_0x2285f4('0x25f4')][_0x2285f4('0x61a')][_0x3fcc88][_0x2285f4('0x1e70')]});}}else _0x3a9036[_0x2285f4('0xfc9')]({'title':_0x1d09c5[_0x2285f4('0x52d')]?_0x2285f4('0x1e21')+_0x1d09c5['status']+'\x20-\x20'+_0x1d09c5[_0x2285f4('0xe1b')]:_0x2285f4('0xe48'),'msg':_0x1d09c5[_0x2285f4('0x25f4')]?JSON[_0x2285f4('0xbac')](_0x1d09c5[_0x2285f4('0x25f4')]['message']):_0x1d09c5[_0x2285f4('0x1e70')]||_0x1d09c5[_0x2285f4('0x1586')]()});});}function _0x3b5bbf(){const _0x1ab018=_0x1f2adf,_0x31de36=angular['copy'](_0x1d1c06[_0x1ab018('0x3a')]);return _0x1d1c06[_0x1ab018('0x3a')]=[],_0x31de36;}function _0x19627e(_0xa508f3){const _0x5d9767=_0x1f2adf,_0x42ee0f=_0x2408ea['confirm']()['title'](_0x5d9767('0xb22'))[_0x5d9767('0xf3c')](_0x5d9767('0x12b5')+_0x1d1c06[_0x5d9767('0x3a')][_0x5d9767('0x264b')]+'\x20selected'+_0x5d9767('0x3f3'))[_0x5d9767('0x8e8')]('delete\x20intervals')[_0x5d9767('0x203b')](_0xa508f3)['ok']('OK')[_0x5d9767('0x3f')](_0x5d9767('0x2d3'));_0x2408ea[_0x5d9767('0x1f80')](_0x42ee0f)[_0x5d9767('0x1166')](function(){const _0x46667e=_0x5d9767;_0x1d1c06['selectedIntervalIntervals']['forEach'](function(_0x37c7ec){_0x173dff(_0x37c7ec);}),_0x1d1c06[_0x46667e('0x3a')]=[];});}let _0xe4e3d4=!![],_0x4a75b3=0x1;_0xda74f4[_0x1f2adf('0xe83')]('vm_dc.query.filter',function(_0x5cfe8a,_0x49516b){const _0x206893=_0x1f2adf;_0xe4e3d4?_0xda85f1(function(){_0xe4e3d4=![];}):(!_0x49516b&&(_0x4a75b3=_0x1d1c06['query'][_0x206893('0x1a43')]),_0x5cfe8a!==_0x49516b&&(_0x1d1c06[_0x206893('0x2218')][_0x206893('0x1a43')]=0x1),!_0x5cfe8a&&(_0x1d1c06[_0x206893('0x2218')]['page']=_0x4a75b3),_0x2f3569());});}const _0x118b1b=_0x2d5c7e;_0xc84e9b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$document','$translate',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'api',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'interval',_0x36e6f4('0x17aa')];function _0xc84e9b(_0x2c2ff9,_0x39b51d,_0x552540,_0x2abf2c,_0x24b083,_0x1cdde3,_0x72968e,_0x28798a,_0x29fb51,_0x16e710,_0x16e612,_0x13ef8){const _0x3b780a=_0x36e6f4,_0xbbb8b6=this;_0xbbb8b6[_0x3b780a('0x98')]=_0x16e710[_0x3b780a('0x26cd')](),_0xbbb8b6[_0x3b780a('0x5c9')]=_0x1cdde3,_0xbbb8b6['setting']=_0x72968e,_0xbbb8b6[_0x3b780a('0x2900')]=_0xbbb8b6[_0x3b780a('0xf8a')][_0x3b780a('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xbbb8b6['location']=_0x39b51d[_0x3b780a('0x6f1')]()+_0x3b780a('0xc51')+_0x39b51d[_0x3b780a('0x1690')](),_0xbbb8b6[_0x3b780a('0x277c')]=_0x16e612||_0x2c2ff9[_0x3b780a('0x23f')][_0x3b780a('0x277c')]||{},_0xbbb8b6['userProfileSection']=_0x13ef8&&_0x13ef8['count']==0x1?_0x13ef8[_0x3b780a('0x269a')][0x0]:null,_0xbbb8b6['crudPermissions']=_0x16e710[_0x3b780a('0xd87')](_0xbbb8b6[_0x3b780a('0x17aa')]?_0xbbb8b6[_0x3b780a('0x17aa')][_0x3b780a('0x243c')]:null),_0xbbb8b6[_0x3b780a('0x128b')]={},_0xbbb8b6['selectedTab']=_0x2c2ff9['params'][_0x3b780a('0xbe3')]||0x0,_0xbbb8b6[_0x3b780a('0x31d')]=_0x29fb51[_0x3b780a('0x1fa1')],_0xbbb8b6['gotoIntervals']=_0x224f7b,_0xbbb8b6[_0x3b780a('0x24be')]=_0x567d8e;function _0x224f7b(){const _0x321bfb=_0x3b780a;_0x2c2ff9['go'](_0x321bfb('0x950'),{},{'reload':_0x321bfb('0x950')});}function _0x567d8e(){const _0x54af40=_0x3b780a;_0x28798a[_0x54af40('0x277c')]['update']({'id':_0xbbb8b6[_0x54af40('0x277c')]['id']},_0xbbb8b6['interval'])['$promise'][_0x54af40('0x1166')](function(){const _0x50fc3c=_0x54af40;_0x29fb51[_0x50fc3c('0x103b')]({'title':_0x50fc3c('0x1499'),'msg':_0xbbb8b6[_0x50fc3c('0x277c')][_0x50fc3c('0x4f0')]?_0xbbb8b6['interval'][_0x50fc3c('0x4f0')]+_0x50fc3c('0xa17'):''});})['catch'](function(_0x4494ec){const _0x53dfe=_0x54af40;_0x29fb51[_0x53dfe('0xfc9')]({'title':_0x4494ec[_0x53dfe('0x52d')]?_0x53dfe('0x1e21')+_0x4494ec[_0x53dfe('0x52d')]+_0x53dfe('0x11e1')+_0x4494ec[_0x53dfe('0xe1b')]:'SYSTEM:GETinterval','msg':_0x4494ec['data']?JSON[_0x53dfe('0xbac')](_0x4494ec['data']):_0x4494ec['toString']()});});}}const _0xe82b43=_0xc84e9b,_0x1f7104=_0x2734b2['p']+_0x36e6f4('0x1c86');_0x58681a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$mdSidenav',_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x164e'),_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x58681a(_0x3a2491,_0x45a659,_0x3d3019,_0x30daaf,_0x4b35a1,_0x3f53ab,_0x2652e3,_0x5a182f,_0x57038b,_0x52e08e,_0x3b76cc,_0x29c7b0,_0x478d47,_0x38631d,_0x47c37c,_0x334fee,_0x642180){const _0xa7f2b9=_0x36e6f4,_0x1167ac=this;_0x1167ac[_0xa7f2b9('0x5c9')]=_0x334fee,_0x1167ac[_0xa7f2b9('0xf8a')]=_0x642180,_0x1167ac[_0xa7f2b9('0x98')]=_0x47c37c['getCurrentUser'](),_0x1167ac[_0xa7f2b9('0x164e')]=_0x57038b||{'count':0x0,'rows':[]},_0x1167ac['userProfile']=_0x52e08e,_0x1167ac[_0xa7f2b9('0x17aa')]=_0x3b76cc&&_0x3b76cc[_0xa7f2b9('0x240f')]==0x1?_0x3b76cc['rows'][0x0]:null,_0x1167ac[_0xa7f2b9('0x243c')]=_0x47c37c[_0xa7f2b9('0xd87')](_0x1167ac[_0xa7f2b9('0x17aa')]?_0x1167ac['userProfileSection'][_0xa7f2b9('0x243c')]:null),_0x1167ac[_0xa7f2b9('0x916')]=_0xa7f2b9('0x164e'),_0x1167ac[_0xa7f2b9('0xef5')]='',_0x1167ac[_0xa7f2b9('0x104c')]=null,_0x1167ac[_0xa7f2b9('0x1437')]=[],_0x1167ac[_0xa7f2b9('0x2218')]={'fields':_0xa7f2b9('0x208e'),'sort':_0xa7f2b9('0x14dc'),'IntervalId':'null','limit':0xa,'page':0x1},_0x1167ac['editstate']=_0x3055e3,_0x1167ac[_0xa7f2b9('0x8d8')]=_0x3e021,_0x1167ac[_0xa7f2b9('0x103b')]=_0x23248c,_0x1167ac[_0xa7f2b9('0x242')]=_0x447def,_0x1167ac[_0xa7f2b9('0x1489')]=_0x3c70d6,_0x1167ac[_0xa7f2b9('0x1f41')]=_0x4b71ba,_0x1167ac[_0xa7f2b9('0xe9d')]=_0x615eb6,_0x1167ac[_0xa7f2b9('0xdd5')]=_0x14cee8,_0x1167ac[_0xa7f2b9('0x2835')]=_0x2512cd,_0x1167ac[_0xa7f2b9('0x1b05')]=_0x266b19;function _0x3055e3(_0x278b27){const _0x1e07e3=_0xa7f2b9;_0x3d3019['go'](_0x1e07e3('0x2e9'),{'id':_0x278b27['id'],'interval':_0x278b27,'crudPermissions':_0x1167ac[_0x1e07e3('0x243c')]});}function _0x3e021(_0x1e31d0,_0x4f170b){const _0x457728=_0xa7f2b9,_0x26f90a=_0x4b35a1[_0x457728('0x1d26')]()[_0x457728('0xcdc')](_0x457728('0x288d')+_0x2cfb05()[_0x457728('0xb35')](_0x457728('0x277c'))+'?')['htmlContent'](''+(_0x1e31d0[_0x457728('0x4f0')]||_0x457728('0x277c'))+''+'\x20will\x20be\x20deleted.')[_0x457728('0x8e8')](_0x457728('0x99a'))[_0x457728('0x203b')](_0x4f170b)['ok']('OK')[_0x457728('0x3f')]('CANCEL');_0x4b35a1[_0x457728('0x1f80')](_0x26f90a)['then'](function(){_0x4b71ba(_0x1e31d0);},function(){const _0x3328c3=_0x457728;console[_0x3328c3('0x455')](_0x3328c3('0x2d3'));});}let _0x2dc1a4=!![],_0x5a7faf=0x1;_0x3a2491[_0xa7f2b9('0xe83')](_0xa7f2b9('0x12d8'),function(_0x2abf8a,_0x5cf106){const _0x3717ba=_0xa7f2b9;_0x2dc1a4?_0x2652e3(function(){_0x2dc1a4=![];}):(!_0x5cf106&&(_0x5a7faf=_0x1167ac[_0x3717ba('0x2218')][_0x3717ba('0x1a43')]),_0x2abf8a!==_0x5cf106&&(_0x1167ac[_0x3717ba('0x2218')]['page']=0x1),!_0x2abf8a&&(_0x1167ac['query'][_0x3717ba('0x1a43')]=_0x5a7faf),_0x1167ac[_0x3717ba('0x242')]());});function _0x23248c(_0x2cdc81){const _0x5d7bdd=_0xa7f2b9;_0x1167ac[_0x5d7bdd('0x164e')]=_0x2cdc81||{'count':0x0,'rows':[]};}function _0x447def(){const _0x4ba359=_0xa7f2b9;_0x1167ac[_0x4ba359('0x2218')][_0x4ba359('0x1098')]=(_0x1167ac[_0x4ba359('0x2218')][_0x4ba359('0x1a43')]-0x1)*_0x1167ac[_0x4ba359('0x2218')][_0x4ba359('0x163f')],_0x47c37c[_0x4ba359('0x1ac6')](_0x4ba359('0xa7c'))?_0x1167ac[_0x4ba359('0x1f48')]=_0x29c7b0[_0x4ba359('0x277c')][_0x4ba359('0xd83')](_0x1167ac['query'],_0x23248c)[_0x4ba359('0xa44')]:(_0x1167ac[_0x4ba359('0x2218')]['id']=_0x1167ac['userProfile']['id'],_0x1167ac[_0x4ba359('0x2218')][_0x4ba359('0xe60')]='Intervals',_0x1167ac[_0x4ba359('0x1f48')]=_0x29c7b0[_0x4ba359('0x7f')][_0x4ba359('0x263a')](_0x1167ac[_0x4ba359('0x2218')],_0x23248c)[_0x4ba359('0xa44')]);}function _0x3c70d6(_0x3a3c66,_0x592259){const _0xbb880e=_0xa7f2b9;_0x4b35a1[_0xbb880e('0x1f80')]({'controller':_0xbb880e('0x77'),'controllerAs':'vm','templateUrl':_0x1f7104,'parent':angular[_0xbb880e('0x1194')](_0x3f53ab[_0xbb880e('0x8d2')]),'targetEvent':_0x3a3c66,'clickOutsideToClose':!![],'locals':{'interval':_0x592259,'intervals':_0x1167ac['intervals'][_0xbb880e('0x269a')],'license':_0x1167ac[_0xbb880e('0x5c9')],'setting':_0x1167ac[_0xbb880e('0xf8a')],'crudPermissions':_0x1167ac[_0xbb880e('0x243c')]}});}function _0x4b71ba(_0x1665bb){const _0x533e4e=_0xa7f2b9;_0x29c7b0[_0x533e4e('0x277c')][_0x533e4e('0x906')]({'id':_0x1665bb['id']})[_0x533e4e('0xa44')]['then'](function(){const _0x2cee22=_0x533e4e;_0x2cfb05()[_0x2cee22('0x127f')](_0x1167ac[_0x2cee22('0x164e')][_0x2cee22('0x269a')],{'id':_0x1665bb['id']}),_0x1167ac[_0x2cee22('0x164e')][_0x2cee22('0x240f')]-=0x1,!_0x1167ac[_0x2cee22('0x164e')][_0x2cee22('0x269a')]['length']&&_0x1167ac[_0x2cee22('0x242')](),_0x38631d[_0x2cee22('0x103b')]({'title':_0x2cfb05()['startCase'](_0x2cee22('0x1545'))+'\x20deleted!','msg':_0x1665bb['name']?_0x1665bb[_0x2cee22('0x4f0')]+_0x2cee22('0x7cd'):''});})[_0x533e4e('0x1a80')](function(_0x1c3607){const _0x43b435=_0x533e4e;if(_0x1c3607[_0x43b435('0x25f4')]&&_0x1c3607['data'][_0x43b435('0x61a')]&&_0x1c3607[_0x43b435('0x25f4')][_0x43b435('0x61a')][_0x43b435('0x264b')]){_0x1167ac[_0x43b435('0x61a')]=_0x1c3607[_0x43b435('0x25f4')][_0x43b435('0x61a')]||[{'message':_0x1c3607[_0x43b435('0x1586')](),'type':'SYSTEM:DELETEinterval'}];for(let _0x220012=0x0;_0x220012<_0x1c3607[_0x43b435('0x25f4')][_0x43b435('0x61a')][_0x43b435('0x264b')];_0x220012++){_0x38631d[_0x43b435('0xfc9')]({'title':_0x1c3607[_0x43b435('0x25f4')][_0x43b435('0x61a')][_0x220012]['type'],'msg':_0x1c3607[_0x43b435('0x25f4')][_0x43b435('0x61a')][_0x220012][_0x43b435('0x1e70')]});}}else _0x38631d['error']({'title':_0x1c3607[_0x43b435('0x52d')]?_0x43b435('0x1e21')+_0x1c3607[_0x43b435('0x52d')]+_0x43b435('0x11e1')+_0x1c3607[_0x43b435('0xe1b')]:_0x43b435('0x8e2'),'msg':_0x1c3607[_0x43b435('0x25f4')]?JSON['stringify'](_0x1c3607['data'][_0x43b435('0x1e70')]):_0x1c3607[_0x43b435('0x1e70')]||_0x1c3607[_0x43b435('0x1586')]()});});}function _0x615eb6(){const _0x45f5de=_0xa7f2b9,_0x3b995b=angular[_0x45f5de('0x225f')](_0x1167ac[_0x45f5de('0x1437')]);return _0x1167ac[_0x45f5de('0x1437')]=[],_0x3b995b;}function _0x14cee8(_0x577c2d){const _0x40d5fe=_0xa7f2b9,_0x3ea3ea=_0x4b35a1[_0x40d5fe('0x1d26')]()[_0x40d5fe('0xcdc')](_0x40d5fe('0xb22'))['htmlContent'](_0x40d5fe('0x12b5')+_0x1167ac[_0x40d5fe('0x1437')][_0x40d5fe('0x264b')]+_0x40d5fe('0x196d')+_0x40d5fe('0x3f3'))['ariaLabel'](_0x40d5fe('0x1255'))[_0x40d5fe('0x203b')](_0x577c2d)['ok']('OK')[_0x40d5fe('0x3f')](_0x40d5fe('0x2d3'));_0x4b35a1['show'](_0x3ea3ea)[_0x40d5fe('0x1166')](function(){const _0x321d7f=_0x40d5fe;_0x1167ac[_0x321d7f('0x1437')][_0x321d7f('0x2782')](function(_0x5931f6){_0x4b71ba(_0x5931f6);}),_0x1167ac[_0x321d7f('0x1437')]=[];});}function _0x2512cd(){_0x1167ac['selectedIntervals']=[];}function _0x266b19(){const _0x270df3=_0xa7f2b9;_0x1167ac['selectedIntervals']=_0x1167ac[_0x270df3('0x164e')]['rows'];}}const _0x563b82=_0x58681a;_0x23211b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0xe29'),'pause','api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x23211b(_0x119e02,_0x47fb1b,_0x2460ab,_0x356b83,_0x29baf9,_0x19d3ae,_0x21bd7c,_0x452a97,_0x35c84c,_0x390cc5,_0x2c6b4a,_0x584d9c,_0x49ce11,_0x4891e1){const _0x323bde=_0x36e6f4,_0x2b4054=this;_0x2b4054[_0x323bde('0x98')]=_0x2c6b4a[_0x323bde('0x26cd')](),_0x2b4054['errors']=[],_0x2b4054[_0x323bde('0xf8a')]=_0x49ce11,_0x2b4054[_0x323bde('0x5c9')]=_0x584d9c,_0x2b4054[_0x323bde('0x243c')]=_0x4891e1,_0x2b4054[_0x323bde('0x128b')]={},_0x2b4054['passwordPattern']=_0x2b4054[_0x323bde('0xf8a')]&&_0x2b4054[_0x323bde('0xf8a')][_0x323bde('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2b4054[_0x323bde('0xcdc')]='TOOLS.EDIT_PAUSE',_0x2b4054[_0x323bde('0x1e77')]=angular['copy'](_0x35c84c),_0x2b4054['pauses']=_0x452a97,_0x2b4054[_0x323bde('0x1beb')]=![];!_0x2b4054[_0x323bde('0x1e77')]&&(_0x2b4054['pause']={},_0x2b4054['title']='TOOLS.NEW_PAUSE',_0x2b4054[_0x323bde('0x1beb')]=!![]);_0x2b4054[_0x323bde('0x2d0')]=_0x379cda,_0x2b4054['savePause']=_0xadc29c,_0x2b4054['deletePause']=_0x6e7f7b,_0x2b4054[_0x323bde('0x1a9c')]=_0x2bfb28,_0x2b4054[_0x323bde('0x24a0')]=_0x5b83d7;function _0x379cda(){const _0x1d9111=_0x323bde;_0x2b4054[_0x1d9111('0x61a')]=[],_0x390cc5['pause'][_0x1d9111('0x9cc')](_0x2b4054['pause'])['$promise'][_0x1d9111('0x1166')](function(_0x34f0cf){const _0x10d0d6=_0x1d9111;_0x2b4054[_0x10d0d6('0xe29')][_0x10d0d6('0x2450')](_0x34f0cf[_0x10d0d6('0x2876')]()),_0x21bd7c[_0x10d0d6('0x103b')]({'title':_0x10d0d6('0x14c6'),'msg':_0x2b4054[_0x10d0d6('0x1e77')][_0x10d0d6('0x4f0')]?_0x2b4054[_0x10d0d6('0x1e77')][_0x10d0d6('0x4f0')]+_0x10d0d6('0x1eda'):''}),_0x5b83d7(_0x34f0cf);})[_0x1d9111('0x1a80')](function(_0x226b93){const _0x7ffbe0=_0x1d9111;if(_0x226b93['data']&&_0x226b93[_0x7ffbe0('0x25f4')]['errors']&&_0x226b93['data'][_0x7ffbe0('0x61a')][_0x7ffbe0('0x264b')]){_0x2b4054[_0x7ffbe0('0x61a')]=_0x226b93[_0x7ffbe0('0x25f4')][_0x7ffbe0('0x61a')]||[{'message':_0x226b93[_0x7ffbe0('0x1586')](),'type':_0x7ffbe0('0x1814')}];for(let _0x763a61=0x0;_0x763a61<_0x226b93[_0x7ffbe0('0x25f4')][_0x7ffbe0('0x61a')][_0x7ffbe0('0x264b')];_0x763a61+=0x1){_0x21bd7c[_0x7ffbe0('0xfc9')]({'title':_0x226b93['data'][_0x7ffbe0('0x61a')][_0x763a61][_0x7ffbe0('0x1345')],'msg':_0x226b93[_0x7ffbe0('0x25f4')][_0x7ffbe0('0x61a')][_0x763a61][_0x7ffbe0('0x1e70')]});}}else _0x21bd7c[_0x7ffbe0('0xfc9')]({'title':_0x226b93[_0x7ffbe0('0x52d')]?'API:'+_0x226b93[_0x7ffbe0('0x52d')]+_0x7ffbe0('0x11e1')+_0x226b93[_0x7ffbe0('0xe1b')]:_0x7ffbe0('0x1814'),'msg':_0x226b93[_0x7ffbe0('0x25f4')]?JSON[_0x7ffbe0('0xbac')](_0x226b93['data'][_0x7ffbe0('0x1e70')]):_0x226b93[_0x7ffbe0('0x1586')]()});});}function _0xadc29c(){const _0x364766=_0x323bde;_0x2b4054[_0x364766('0x61a')]=[],_0x390cc5[_0x364766('0x1e77')]['update']({'id':_0x2b4054[_0x364766('0x1e77')]['id']},_0x2b4054[_0x364766('0x1e77')])[_0x364766('0xa44')][_0x364766('0x1166')](function(_0x53cf58){const _0x1b609c=_0x364766,_0x4c5b7a=_0x2cfb05()[_0x1b609c('0xc38')](_0x2b4054[_0x1b609c('0xe29')],{'id':_0x53cf58['id']});_0x4c5b7a&&_0x2cfb05()['merge'](_0x4c5b7a,_0x2cfb05()[_0x1b609c('0x1a08')](_0x53cf58[_0x1b609c('0x2876')](),_0x2cfb05()['keys'](_0x4c5b7a))),_0x21bd7c[_0x1b609c('0x103b')]({'title':_0x1b609c('0x613'),'msg':_0x2b4054[_0x1b609c('0x1e77')][_0x1b609c('0x4f0')]?_0x2b4054['pause'][_0x1b609c('0x4f0')]+_0x1b609c('0x7d'):''}),_0x5b83d7(_0x53cf58);})[_0x364766('0x1a80')](function(_0x59dd14){const _0x3f6ecf=_0x364766;if(_0x59dd14[_0x3f6ecf('0x25f4')]&&_0x59dd14[_0x3f6ecf('0x25f4')][_0x3f6ecf('0x61a')]&&_0x59dd14[_0x3f6ecf('0x25f4')][_0x3f6ecf('0x61a')]['length']){_0x2b4054['errors']=_0x59dd14[_0x3f6ecf('0x25f4')][_0x3f6ecf('0x61a')]||[{'message':_0x59dd14[_0x3f6ecf('0x1586')](),'type':_0x3f6ecf('0x24f5')}];for(let _0x1c3442=0x0;_0x1c3442<_0x59dd14[_0x3f6ecf('0x25f4')][_0x3f6ecf('0x61a')][_0x3f6ecf('0x264b')];_0x1c3442++){_0x21bd7c[_0x3f6ecf('0xfc9')]({'title':_0x59dd14[_0x3f6ecf('0x25f4')]['errors'][_0x1c3442]['type'],'msg':_0x59dd14[_0x3f6ecf('0x25f4')][_0x3f6ecf('0x61a')][_0x1c3442][_0x3f6ecf('0x1e70')]});}}else _0x21bd7c[_0x3f6ecf('0xfc9')]({'title':_0x59dd14[_0x3f6ecf('0x52d')]?'API:'+_0x59dd14['status']+'\x20-\x20'+_0x59dd14[_0x3f6ecf('0xe1b')]:_0x3f6ecf('0x24f5'),'msg':_0x59dd14[_0x3f6ecf('0x25f4')]?JSON[_0x3f6ecf('0xbac')](_0x59dd14[_0x3f6ecf('0x25f4')][_0x3f6ecf('0x1e70')]):_0x59dd14[_0x3f6ecf('0x1586')]()});});}function _0x6e7f7b(_0x487408){const _0x3b1689=_0x323bde;_0x2b4054[_0x3b1689('0x61a')]=[];const _0xd9260=_0x356b83[_0x3b1689('0x1d26')]()[_0x3b1689('0xcdc')](_0x3b1689('0x7fb'))[_0x3b1689('0xacc')](_0x3b1689('0x285'))[_0x3b1689('0x8e8')](_0x3b1689('0xb1'))['ok']('Delete')[_0x3b1689('0x3f')](_0x3b1689('0x497'))[_0x3b1689('0x203b')](_0x487408);_0x356b83[_0x3b1689('0x1f80')](_0xd9260)['then'](function(){const _0x153014=_0x3b1689;_0x390cc5[_0x153014('0x1e77')]['delete']({'id':_0x2b4054['pause']['id']})['$promise']['then'](function(){const _0x3e8b74=_0x153014;_0x2cfb05()[_0x3e8b74('0x127f')](_0x2b4054['pauses'],{'id':_0x2b4054[_0x3e8b74('0x1e77')]['id']}),_0x21bd7c[_0x3e8b74('0x103b')]({'title':'Pause\x20properly\x20deleted!','msg':(_0x2b4054[_0x3e8b74('0x1e77')][_0x3e8b74('0x4f0')]||'pause')+_0x3e8b74('0x7cd')}),_0x5b83d7(_0x2b4054[_0x3e8b74('0x1e77')]);})['catch'](function(_0xfcd178){const _0x1ca2b4=_0x153014;if(_0xfcd178['data']&&_0xfcd178['data'][_0x1ca2b4('0x61a')]&&_0xfcd178[_0x1ca2b4('0x25f4')][_0x1ca2b4('0x61a')][_0x1ca2b4('0x264b')]){_0x2b4054[_0x1ca2b4('0x61a')]=_0xfcd178[_0x1ca2b4('0x25f4')]['errors']||[{'message':_0xfcd178[_0x1ca2b4('0x1586')](),'type':'api.pause.delete'}];for(let _0x57a42e=0x0;_0x57a42e<_0xfcd178[_0x1ca2b4('0x25f4')][_0x1ca2b4('0x61a')][_0x1ca2b4('0x264b')];_0x57a42e++){_0x21bd7c[_0x1ca2b4('0xfc9')]({'title':_0xfcd178['data'][_0x1ca2b4('0x61a')][_0x57a42e]['type'],'msg':_0xfcd178[_0x1ca2b4('0x25f4')][_0x1ca2b4('0x61a')][_0x57a42e][_0x1ca2b4('0x1e70')]});}}else _0x21bd7c[_0x1ca2b4('0xfc9')]({'title':_0xfcd178[_0x1ca2b4('0x52d')]?_0x1ca2b4('0x1e21')+_0xfcd178['status']+_0x1ca2b4('0x11e1')+_0xfcd178[_0x1ca2b4('0xe1b')]:_0x1ca2b4('0x1d85'),'msg':_0xfcd178['data']?JSON[_0x1ca2b4('0xbac')](_0xfcd178[_0x1ca2b4('0x25f4')][_0x1ca2b4('0x1e70')]):_0xfcd178[_0x1ca2b4('0x1e70')]||_0xfcd178[_0x1ca2b4('0x1586')]()});});},function(){});}function _0x2bfb28(_0x3cdccb){return _0x3cdccb===null?undefined:new Date(_0x3cdccb);}function _0x5b83d7(_0x3e5acc){const _0x30bd83=_0x323bde;_0x356b83[_0x30bd83('0x1197')](_0x3e5acc);}}const _0x44d8e2=_0x23211b,_0x5d772d=_0x2734b2['p']+_0x36e6f4('0x178a');_0x130dc0[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),'$mdDialog',_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0xe29'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),'api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x130dc0(_0xb2f064,_0x4d692d,_0x535607,_0x300c3c,_0x32c36a,_0x5e80f2,_0x107b8c,_0x48c063,_0x7b5634,_0x231e4f,_0x53e953,_0x542d8e,_0x21f63d,_0x779da0,_0x330a90,_0x4fd7a1,_0x4340d9){const _0x372e48=_0x36e6f4,_0xec8422=this;_0xec8422[_0x372e48('0x5c9')]=_0x4fd7a1,_0xec8422[_0x372e48('0xf8a')]=_0x4340d9,_0xec8422[_0x372e48('0x98')]=_0x330a90['getCurrentUser'](),_0xec8422[_0x372e48('0xe29')]=_0x7b5634||{'count':0x0,'rows':[]},_0xec8422[_0x372e48('0x7f')]=_0x231e4f,_0xec8422[_0x372e48('0x17aa')]=_0x53e953&&_0x53e953[_0x372e48('0x240f')]==0x1?_0x53e953[_0x372e48('0x269a')][0x0]:null,_0xec8422[_0x372e48('0x243c')]=_0x330a90['parseCrudPermissions'](_0xec8422[_0x372e48('0x17aa')]?_0xec8422[_0x372e48('0x17aa')][_0x372e48('0x243c')]:null),_0xec8422[_0x372e48('0x916')]=_0x372e48('0xe29'),_0xec8422[_0x372e48('0xef5')]='',_0xec8422[_0x372e48('0x104c')]=null,_0xec8422[_0x372e48('0xd4f')]=[],_0xec8422[_0x372e48('0x2218')]={'fields':_0x372e48('0x208e'),'sort':_0x372e48('0x14dc'),'limit':0xa,'page':0x1},_0xec8422[_0x372e48('0x1f8e')]=_0x1e2b38,_0xec8422[_0x372e48('0x8d8')]=_0x9339c2,_0xec8422[_0x372e48('0x103b')]=_0x29e254,_0xec8422[_0x372e48('0x304')]=_0x465c87,_0xec8422[_0x372e48('0xcf9')]=_0x539cf3,_0xec8422[_0x372e48('0x150c')]=_0x370924,_0xec8422['exportSelectedPauses']=_0xe8dadd,_0xec8422['deleteSelectedPauses']=_0x2ff696,_0xec8422[_0x372e48('0xe05')]=_0x35a532,_0xec8422[_0x372e48('0x2449')]=_0x1196e8;function _0x1e2b38(_0x1792c5,_0x371476){const _0x47c79e=_0x372e48;_0x32c36a[_0x47c79e('0x1f80')]({'controller':_0x47c79e('0x12e1'),'controllerAs':'vm','templateUrl':_0x5d772d,'parent':angular[_0x47c79e('0x1194')](_0x5e80f2[_0x47c79e('0x8d2')]),'targetEvent':_0x371476,'clickOutsideToClose':!![],'locals':{'pause':_0x1792c5,'pauses':_0xec8422[_0x47c79e('0xe29')]['rows'],'license':_0xec8422[_0x47c79e('0x5c9')],'setting':null,'crudPermissions':_0xec8422[_0x47c79e('0x243c')]}});}function _0x9339c2(_0x364b07,_0x57f4a2){const _0x693af0=_0x372e48,_0x13da5e=_0x32c36a[_0x693af0('0x1d26')]()[_0x693af0('0xcdc')](_0x693af0('0x288d')+_0x2cfb05()[_0x693af0('0xb35')](_0x693af0('0x1e77'))+'?')[_0x693af0('0xf3c')](_0x693af0('0x12b5')+(_0x364b07['name']||_0x693af0('0x1e77'))+_0x693af0('0xace')+'\x20will\x20be\x20deleted.')[_0x693af0('0x8e8')](_0x693af0('0x1d29'))[_0x693af0('0x203b')](_0x57f4a2)['ok']('OK')['cancel']('CANCEL');_0x32c36a['show'](_0x13da5e)['then'](function(){_0x370924(_0x364b07);},function(){const _0x795e7e=_0x693af0;console[_0x795e7e('0x455')](_0x795e7e('0x2d3'));});}let _0x47a500=!![],_0x32de4b=0x1;_0xb2f064[_0x372e48('0xe83')](_0x372e48('0x12d8'),function(_0x1e47af,_0xe69e6f){const _0x3bd3ec=_0x372e48;_0x47a500?_0x107b8c(function(){_0x47a500=![];}):(!_0xe69e6f&&(_0x32de4b=_0xec8422[_0x3bd3ec('0x2218')][_0x3bd3ec('0x1a43')]),_0x1e47af!==_0xe69e6f&&(_0xec8422[_0x3bd3ec('0x2218')][_0x3bd3ec('0x1a43')]=0x1),!_0x1e47af&&(_0xec8422[_0x3bd3ec('0x2218')]['page']=_0x32de4b),_0xec8422[_0x3bd3ec('0x304')]());});function _0x29e254(_0x30af5a){_0xec8422['pauses']=_0x30af5a||{'count':0x0,'rows':[]};}function _0x465c87(){const _0x3c75bb=_0x372e48;_0xec8422['query'][_0x3c75bb('0x1098')]=(_0xec8422['query'][_0x3c75bb('0x1a43')]-0x1)*_0xec8422[_0x3c75bb('0x2218')][_0x3c75bb('0x163f')],_0x330a90['hasRole'](_0x3c75bb('0xa7c'))?_0xec8422[_0x3c75bb('0x1f48')]=_0x542d8e[_0x3c75bb('0x1e77')][_0x3c75bb('0xd83')](_0xec8422[_0x3c75bb('0x2218')],_0x29e254)[_0x3c75bb('0xa44')]:(_0xec8422[_0x3c75bb('0x2218')]['id']=_0xec8422[_0x3c75bb('0x7f')]['id'],_0xec8422[_0x3c75bb('0x2218')][_0x3c75bb('0xe60')]=_0x3c75bb('0x1377'),_0xec8422['promise']=_0x542d8e[_0x3c75bb('0x7f')][_0x3c75bb('0x263a')](_0xec8422[_0x3c75bb('0x2218')],_0x29e254)[_0x3c75bb('0xa44')]);}function _0x539cf3(_0x44e7c1,_0x284507){const _0xe1091c=_0x372e48;_0x32c36a[_0xe1091c('0x1f80')]({'controller':_0xe1091c('0x12e1'),'controllerAs':'vm','templateUrl':_0x5d772d,'parent':angular[_0xe1091c('0x1194')](_0x5e80f2[_0xe1091c('0x8d2')]),'targetEvent':_0x44e7c1,'clickOutsideToClose':!![],'locals':{'pause':_0x284507,'pauses':_0xec8422['pauses']['rows'],'license':_0xec8422[_0xe1091c('0x5c9')],'setting':_0xec8422['setting'],'crudPermissions':_0xec8422[_0xe1091c('0x243c')]}});}function _0x370924(_0xf3ee9d){const _0x1f2808=_0x372e48;_0x542d8e[_0x1f2808('0x1e77')][_0x1f2808('0x906')]({'id':_0xf3ee9d['id']})[_0x1f2808('0xa44')]['then'](function(){const _0x123415=_0x1f2808;_0x2cfb05()[_0x123415('0x127f')](_0xec8422['pauses']['rows'],{'id':_0xf3ee9d['id']}),_0xec8422[_0x123415('0xe29')]['count']-=0x1,!_0xec8422['pauses'][_0x123415('0x269a')]['length']&&_0xec8422[_0x123415('0x304')](),_0x779da0['success']({'title':_0x2cfb05()[_0x123415('0xb35')](_0x123415('0x108'))+_0x123415('0x2b6'),'msg':_0xf3ee9d[_0x123415('0x4f0')]?_0xf3ee9d[_0x123415('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0x1f2808('0x1a80')](function(_0x166b1b){const _0x596383=_0x1f2808;if(_0x166b1b['data']&&_0x166b1b['data'][_0x596383('0x61a')]&&_0x166b1b[_0x596383('0x25f4')][_0x596383('0x61a')][_0x596383('0x264b')]){_0xec8422[_0x596383('0x61a')]=_0x166b1b[_0x596383('0x25f4')][_0x596383('0x61a')]||[{'message':_0x166b1b[_0x596383('0x1586')](),'type':_0x596383('0x1186')}];for(let _0x14f0a0=0x0;_0x14f0a0<_0x166b1b[_0x596383('0x25f4')][_0x596383('0x61a')][_0x596383('0x264b')];_0x14f0a0++){_0x779da0[_0x596383('0xfc9')]({'title':_0x166b1b[_0x596383('0x25f4')]['errors'][_0x14f0a0]['type'],'msg':_0x166b1b[_0x596383('0x25f4')]['errors'][_0x14f0a0]['message']});}}else _0x779da0[_0x596383('0xfc9')]({'title':_0x166b1b['status']?_0x596383('0x1e21')+_0x166b1b['status']+'\x20-\x20'+_0x166b1b['statusText']:'SYSTEM:DELETEpause','msg':_0x166b1b[_0x596383('0x25f4')]?JSON[_0x596383('0xbac')](_0x166b1b[_0x596383('0x25f4')]['message']):_0x166b1b[_0x596383('0x1e70')]||_0x166b1b[_0x596383('0x1586')]()});});}function _0xe8dadd(){const _0x2a46b2=_0x372e48,_0x274876=angular[_0x2a46b2('0x225f')](_0xec8422['selectedPauses']);return _0xec8422['selectedPauses']=[],_0x274876;}function _0x2ff696(_0x34366b){const _0x8447ca=_0x372e48,_0x3f64c4=_0x32c36a['confirm']()['title'](_0x8447ca('0x1435'))[_0x8447ca('0xf3c')](_0x8447ca('0x12b5')+_0xec8422['selectedPauses'][_0x8447ca('0x264b')]+_0x8447ca('0x196d')+'\x20will\x20be\x20deleted.')[_0x8447ca('0x8e8')](_0x8447ca('0x1f77'))[_0x8447ca('0x203b')](_0x34366b)['ok']('OK')['cancel'](_0x8447ca('0x2d3'));_0x32c36a['show'](_0x3f64c4)[_0x8447ca('0x1166')](function(){const _0x38f73d=_0x8447ca;_0xec8422['selectedPauses']['forEach'](function(_0x55a517){_0x370924(_0x55a517);}),_0xec8422[_0x38f73d('0xd4f')]=[];});}function _0x35a532(){const _0x5df3a1=_0x372e48;_0xec8422[_0x5df3a1('0xd4f')]=[];}function _0x1196e8(){const _0x5cdea4=_0x372e48;_0xec8422[_0x5cdea4('0xd4f')]=_0xec8422[_0x5cdea4('0xe29')][_0x5cdea4('0x269a')];}}const _0x3a2502=_0x130dc0,_0x8f2c8a=_0x2734b2['p']+_0x36e6f4('0x21aa');_0x55cbcc[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xa0a'),_0x36e6f4('0x892'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x55cbcc(_0x29b558,_0xa84596,_0x399bde,_0x4b6258,_0x13611d,_0x1fb568,_0x13f3d2,_0x3c2439,_0x9b0106,_0x3345d4,_0x12c2dd,_0x1d7c1f,_0x4f1c1b,_0x5afb9c){const _0x275e85=_0x36e6f4,_0x255ef7=this;_0x255ef7['currentUser']=_0x12c2dd[_0x275e85('0x26cd')](),_0x255ef7['errors']=[],_0x255ef7[_0x275e85('0xf8a')]=_0x4f1c1b,_0x255ef7['license']=_0x1d7c1f,_0x255ef7[_0x275e85('0x243c')]=_0x5afb9c,_0x255ef7[_0x275e85('0x128b')]={},_0x255ef7[_0x275e85('0x2900')]=_0x255ef7[_0x275e85('0xf8a')]&&_0x255ef7[_0x275e85('0xf8a')][_0x275e85('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x255ef7[_0x275e85('0xcdc')]=_0x275e85('0x858'),_0x255ef7[_0x275e85('0x892')]=angular['copy'](_0x9b0106),_0x255ef7[_0x275e85('0xa0a')]=_0x3c2439,_0x255ef7[_0x275e85('0x5a4')]=![],_0x255ef7[_0x275e85('0x266f')]=[],_0x255ef7[_0x275e85('0x2218')]={'fields':'createdAt,updatedAt,id,name,description,table,parent,conditions,joins','limit':0xa,'page':0x1,'sort':_0x275e85('0x14dc')};if(!_0x255ef7[_0x275e85('0x892')])_0x255ef7[_0x275e85('0x892')]={'output':_0x275e85('0x5ba'),'active':!![],'startAt':new Date(),'endAt':new Date(Date[_0x275e85('0x1e8f')]()+0x1e*0x18*0x3c*0x3c*0x3e8),'cron':'0\x200\x20*\x20*\x20*','subtractNumber':0x1,'subtractUnit':_0x275e85('0x664'),'sendMail':![],'sendIfEmpty':!![]},_0x255ef7[_0x275e85('0xcdc')]=_0x275e85('0x189d'),_0x255ef7[_0x275e85('0x5a4')]=!![];else{_0x255ef7[_0x275e85('0x2677')]=_0x255ef7[_0x275e85('0x892')][_0x275e85('0x1944')]?_0x275e85('0x17c2'):'analyticCustomReport';const _0x38b896=_0x255ef7[_0x275e85('0x892')][_0x275e85('0x1944')]?_0x255ef7[_0x275e85('0x892')][_0x275e85('0x1944')]:_0x255ef7[_0x275e85('0x892')]['CustomReportId'];_0x3345d4[_0x255ef7[_0x275e85('0x2677')]][_0x275e85('0xd83')]({'fields':_0x275e85('0x563')})[_0x275e85('0xa44')][_0x275e85('0x1166')](function(_0x18dc8d){const _0x8b648a=_0x275e85;_0x255ef7[_0x8b648a('0x519')]=_0x2cfb05()[_0x8b648a('0xc38')](_0x18dc8d['rows'],{'id':_0x38b896}),_0x255ef7['schedule'][_0x8b648a('0x2659')]=_0x255ef7[_0x8b648a('0x519')][_0x8b648a('0x4f0')],_0x255ef7[_0x8b648a('0x2218')]['parent']=_0x255ef7[_0x8b648a('0x519')][_0x8b648a('0x5f6')];});}_0x255ef7[_0x275e85('0x1053')]=_0x562f27,_0x255ef7[_0x275e85('0x1c4b')]=_0x310fc3,_0x255ef7[_0x275e85('0x23cb')]=_0xab35ae,_0x255ef7[_0x275e85('0x1a9c')]=_0x38e4e7,_0x255ef7[_0x275e85('0x20aa')]=_0x98b6a,_0x255ef7[_0x275e85('0x4da')]=_0x57e40f,_0x255ef7[_0x275e85('0x1e3a')]=_0x15e2d3,_0x255ef7[_0x275e85('0x2a1')]=_0x21d0a9,_0x255ef7['closeDialog']=_0x32ddbc,_0x3345d4['analyticTreeReport'][_0x275e85('0xd83')]({})[_0x275e85('0xa44')][_0x275e85('0x1166')](function(_0x3007d3){const _0xfc5bc=_0x275e85;_0x255ef7[_0xfc5bc('0x14c7')]=_0x3007d3[_0xfc5bc('0x269a')]||[];})[_0x275e85('0x1a80')](function(_0x1ca288){const _0x1b0880=_0x275e85;_0x13f3d2[_0x1b0880('0xfc9')]({'title':_0x1ca288[_0x1b0880('0x52d')]?_0x1b0880('0x1e21')+_0x1ca288[_0x1b0880('0x52d')]+_0x1b0880('0x11e1')+_0x1ca288[_0x1b0880('0xe1b')]:_0x1b0880('0x27b9'),'msg':_0x1ca288[_0x1b0880('0x25f4')]?JSON['stringify'](_0x1ca288['data']):_0x1ca288[_0x1b0880('0x1586')]()});}),_0x12c2dd[_0x275e85('0x1ac6')](_0x275e85('0xa7c'))?_0x3345d4['mailAccount'][_0x275e85('0xd83')]({'fields':_0x275e85('0x1776'),'sort':'name'})[_0x275e85('0xa44')][_0x275e85('0x1166')](function(_0x41cf6e){const _0x1676ec=_0x275e85;_0x255ef7[_0x1676ec('0xf85')]=_0x41cf6e['rows']||[];})['catch'](function(_0x3f1bbe){const _0x157d4b=_0x275e85;_0x13f3d2[_0x157d4b('0xfc9')]({'title':_0x3f1bbe['status']?'API:'+_0x3f1bbe[_0x157d4b('0x52d')]+_0x157d4b('0x11e1')+_0x3f1bbe['statusText']:_0x157d4b('0x4bd'),'msg':_0x3f1bbe['data']?JSON[_0x157d4b('0xbac')](_0x3f1bbe[_0x157d4b('0x25f4')]):_0x3f1bbe[_0x157d4b('0x1586')]()});}):_0x3345d4[_0x275e85('0x21b9')][_0x275e85('0xd83')]({'fields':_0x275e85('0x1776'),'sort':_0x275e85('0x4f0')})[_0x275e85('0xa44')][_0x275e85('0x1166')](function(_0x460aa2){const _0x431da2=_0x275e85;_0x255ef7[_0x431da2('0xf85')]=_0x460aa2[_0x431da2('0x269a')]||[];})[_0x275e85('0x1166')](function(){const _0x331d55=_0x275e85;return _0x3345d4[_0x331d55('0x17aa')][_0x331d55('0xd83')]({'userProfileId':_0x255ef7['currentUser'][_0x331d55('0xb86')],'sectionId':0x25a})[_0x331d55('0xa44')];})[_0x275e85('0x1166')](function(_0x2331a3){const _0x149236=_0x275e85,_0x233fca=_0x2331a3&&_0x2331a3[_0x149236('0x269a')]?_0x2331a3['rows'][0x0]:null;if(!_0x233fca){const _0xd94177=[];let _0x2be8ab=null;_0x255ef7[_0x149236('0x892')]&&(_0x2be8ab=_0x2cfb05()['find'](_0x255ef7[_0x149236('0xf85')],{'id':Number(_0x255ef7[_0x149236('0x892')][_0x149236('0x56')])}));for(let _0x5c2e18=0x0;_0x5c2e18<_0x255ef7['mailAccounts'][_0x149236('0x264b')];_0x5c2e18++){_0x2be8ab&&_0x255ef7['mailAccounts'][_0x5c2e18]['id']===_0x2be8ab['id']&&(_0x255ef7['mailAccounts'][_0x5c2e18]['canSelect']=![],_0xd94177[_0x149236('0x1514')](_0x255ef7[_0x149236('0xf85')][_0x5c2e18]));}_0x255ef7[_0x149236('0xf85')]=_0xd94177;}else{if(!_0x233fca['autoAssociation'])return _0x3345d4[_0x149236('0x4b5')][_0x149236('0xd83')]({'sectionId':_0x233fca['id']})['$promise']['then'](function(_0x29a91b){const _0xec55dc=_0x149236,_0x18960c=_0x2cfb05()[_0xec55dc('0x2563')](_0x29a91b['rows'],function(_0x2b7121){const _0x4c6053=_0xec55dc;return _0x2cfb05()[_0x4c6053('0xc38')](_0x255ef7[_0x4c6053('0xf85')],{'id':_0x2b7121[_0x4c6053('0x24e8')]});});let _0x34ad29=null;_0x255ef7[_0xec55dc('0x892')]&&(_0x34ad29=_0x2cfb05()[_0xec55dc('0xc38')](_0x255ef7[_0xec55dc('0xf85')],{'id':Number(_0x255ef7['schedule'][_0xec55dc('0x56')])}));if(_0x34ad29&&!_0x2cfb05()['some'](_0x18960c,['id',_0x34ad29['id']])){const _0x2e64a8=_0x2cfb05()[_0xec55dc('0xc38')](_0x255ef7[_0xec55dc('0xf85')],{'id':_0x34ad29['id']});_0x2e64a8[_0xec55dc('0x2378')]=![],_0x18960c[_0xec55dc('0x1514')](_0x2e64a8);}_0x255ef7[_0xec55dc('0xf85')]=_0x18960c;});}})['catch'](function(_0x11d435){const _0x19bb7f=_0x275e85;_0x13f3d2[_0x19bb7f('0xfc9')]({'title':_0x11d435['status']?_0x19bb7f('0x1e21')+_0x11d435[_0x19bb7f('0x52d')]+_0x19bb7f('0x11e1')+_0x11d435['statusText']:_0x19bb7f('0x5e'),'msg':_0x11d435['data']?JSON[_0x19bb7f('0xbac')](_0x11d435[_0x19bb7f('0x25f4')]):_0x11d435[_0x19bb7f('0x1586')]()});});function _0x562f27(){const _0x208034=_0x275e85;_0x255ef7[_0x208034('0x61a')]=[],_0x3345d4['schedule']['save'](_0x255ef7[_0x208034('0x892')])[_0x208034('0xa44')][_0x208034('0x1166')](function(_0x50a4f2){const _0x17e706=_0x208034;_0x255ef7[_0x17e706('0xa0a')]['unshift'](_0x50a4f2[_0x17e706('0x2876')]()),_0x13f3d2[_0x17e706('0x103b')]({'title':'Schedule\x20properly\x20created','msg':_0x255ef7[_0x17e706('0x892')][_0x17e706('0x4f0')]?_0x255ef7[_0x17e706('0x892')][_0x17e706('0x4f0')]+_0x17e706('0x1eda'):''}),_0x32ddbc(_0x50a4f2);})[_0x208034('0x1a80')](function(_0x24b612){const _0x16a8cc=_0x208034;if(_0x24b612[_0x16a8cc('0x25f4')]&&_0x24b612[_0x16a8cc('0x25f4')]['errors']&&_0x24b612['data'][_0x16a8cc('0x61a')][_0x16a8cc('0x264b')]){_0x255ef7['errors']=_0x24b612['data'][_0x16a8cc('0x61a')]||[{'message':_0x24b612[_0x16a8cc('0x1586')](),'type':_0x16a8cc('0xffb')}];for(let _0x2f0020=0x0;_0x2f0020<_0x24b612['data']['errors'][_0x16a8cc('0x264b')];_0x2f0020+=0x1){_0x13f3d2[_0x16a8cc('0xfc9')]({'title':_0x24b612['data']['errors'][_0x2f0020][_0x16a8cc('0x1345')],'msg':_0x24b612['data']['errors'][_0x2f0020][_0x16a8cc('0x1e70')]});}}else _0x13f3d2[_0x16a8cc('0xfc9')]({'title':_0x24b612['status']?_0x16a8cc('0x1e21')+_0x24b612[_0x16a8cc('0x52d')]+_0x16a8cc('0x11e1')+_0x24b612['statusText']:_0x16a8cc('0xffb'),'msg':_0x24b612['data']?JSON['stringify'](_0x24b612[_0x16a8cc('0x25f4')]['message']):_0x24b612['toString']()});});}function _0x310fc3(){const _0x553e72=_0x275e85;_0x255ef7[_0x553e72('0x61a')]=[],_0x3345d4[_0x553e72('0x892')]['update']({'id':_0x255ef7[_0x553e72('0x892')]['id']},_0x255ef7[_0x553e72('0x892')])[_0x553e72('0xa44')][_0x553e72('0x1166')](function(_0x52f99c){const _0x50a528=_0x553e72,_0x1ed9a3=_0x2cfb05()[_0x50a528('0xc38')](_0x255ef7[_0x50a528('0xa0a')],{'id':_0x52f99c['id']});_0x1ed9a3&&_0x2cfb05()[_0x50a528('0xcc3')](_0x1ed9a3,_0x2cfb05()['pick'](_0x52f99c['toJSON'](),_0x2cfb05()[_0x50a528('0x14a4')](_0x1ed9a3))),_0x13f3d2[_0x50a528('0x103b')]({'title':_0x50a528('0x2325'),'msg':_0x255ef7[_0x50a528('0x892')][_0x50a528('0x4f0')]?_0x255ef7[_0x50a528('0x892')][_0x50a528('0x4f0')]+_0x50a528('0x7d'):''}),_0x32ddbc(_0x52f99c);})['catch'](function(_0x2ab901){const _0x42b5fa=_0x553e72;if(_0x2ab901[_0x42b5fa('0x25f4')]&&_0x2ab901[_0x42b5fa('0x25f4')][_0x42b5fa('0x61a')]&&_0x2ab901[_0x42b5fa('0x25f4')][_0x42b5fa('0x61a')][_0x42b5fa('0x264b')]){_0x255ef7[_0x42b5fa('0x61a')]=_0x2ab901['data'][_0x42b5fa('0x61a')]||[{'message':_0x2ab901[_0x42b5fa('0x1586')](),'type':_0x42b5fa('0xa73')}];for(let _0x25b29f=0x0;_0x25b29f<_0x2ab901[_0x42b5fa('0x25f4')][_0x42b5fa('0x61a')][_0x42b5fa('0x264b')];_0x25b29f++){_0x13f3d2[_0x42b5fa('0xfc9')]({'title':_0x2ab901[_0x42b5fa('0x25f4')][_0x42b5fa('0x61a')][_0x25b29f][_0x42b5fa('0x1345')],'msg':_0x2ab901[_0x42b5fa('0x25f4')][_0x42b5fa('0x61a')][_0x25b29f][_0x42b5fa('0x1e70')]});}}else _0x13f3d2[_0x42b5fa('0xfc9')]({'title':_0x2ab901[_0x42b5fa('0x52d')]?'API:'+_0x2ab901[_0x42b5fa('0x52d')]+_0x42b5fa('0x11e1')+_0x2ab901[_0x42b5fa('0xe1b')]:_0x42b5fa('0xa73'),'msg':_0x2ab901[_0x42b5fa('0x25f4')]?JSON[_0x42b5fa('0xbac')](_0x2ab901[_0x42b5fa('0x25f4')][_0x42b5fa('0x1e70')]):_0x2ab901[_0x42b5fa('0x1586')]()});});}function _0xab35ae(_0x24366a){const _0x5633ac=_0x275e85;_0x255ef7[_0x5633ac('0x61a')]=[];const _0x393bed=_0x4b6258[_0x5633ac('0x1d26')]()[_0x5633ac('0xcdc')]('Are\x20you\x20sure?')[_0x5633ac('0xacc')](_0x5633ac('0x187a'))[_0x5633ac('0x8e8')](_0x5633ac('0xa21'))['ok'](_0x5633ac('0x18'))['cancel'](_0x5633ac('0x497'))[_0x5633ac('0x203b')](_0x24366a);_0x4b6258[_0x5633ac('0x1f80')](_0x393bed)[_0x5633ac('0x1166')](function(){const _0x288ac8=_0x5633ac;_0x3345d4[_0x288ac8('0x892')]['delete']({'id':_0x255ef7[_0x288ac8('0x892')]['id']})[_0x288ac8('0xa44')][_0x288ac8('0x1166')](function(){const _0x331ec2=_0x288ac8;_0x2cfb05()['remove'](_0x255ef7[_0x331ec2('0xa0a')],{'id':_0x255ef7[_0x331ec2('0x892')]['id']}),_0x13f3d2['success']({'title':'Schedule\x20properly\x20deleted!','msg':(_0x255ef7[_0x331ec2('0x892')][_0x331ec2('0x4f0')]||'schedule')+_0x331ec2('0x7cd')}),_0x32ddbc(_0x255ef7[_0x331ec2('0x892')]);})[_0x288ac8('0x1a80')](function(_0x50ae60){const _0x5e23a0=_0x288ac8;if(_0x50ae60[_0x5e23a0('0x25f4')]&&_0x50ae60['data'][_0x5e23a0('0x61a')]&&_0x50ae60['data'][_0x5e23a0('0x61a')][_0x5e23a0('0x264b')]){_0x255ef7[_0x5e23a0('0x61a')]=_0x50ae60[_0x5e23a0('0x25f4')][_0x5e23a0('0x61a')]||[{'message':_0x50ae60[_0x5e23a0('0x1586')](),'type':_0x5e23a0('0x1aeb')}];for(let _0x2d62b6=0x0;_0x2d62b6<_0x50ae60[_0x5e23a0('0x25f4')]['errors']['length'];_0x2d62b6++){_0x13f3d2['error']({'title':_0x50ae60[_0x5e23a0('0x25f4')][_0x5e23a0('0x61a')][_0x2d62b6][_0x5e23a0('0x1345')],'msg':_0x50ae60[_0x5e23a0('0x25f4')][_0x5e23a0('0x61a')][_0x2d62b6][_0x5e23a0('0x1e70')]});}}else _0x13f3d2[_0x5e23a0('0xfc9')]({'title':_0x50ae60['status']?'API:'+_0x50ae60['status']+_0x5e23a0('0x11e1')+_0x50ae60[_0x5e23a0('0xe1b')]:_0x5e23a0('0x1aeb'),'msg':_0x50ae60[_0x5e23a0('0x25f4')]?JSON[_0x5e23a0('0xbac')](_0x50ae60[_0x5e23a0('0x25f4')][_0x5e23a0('0x1e70')]):_0x50ae60['message']||_0x50ae60['toString']()});});},function(){});}function _0xd2f567(){const _0x2d13e5=_0x275e85,_0x169a94={'core':{'multiple':![],'animation':!![],'error':function(_0x12e631){const _0x5f0729=a0_0x3f2c;console['error'](_0x5f0729('0x1edc')+angular[_0x5f0729('0xd2')](_0x12e631));},'check_callback':!![],'worker':!![]},'version':0x1,'plugins':[_0x2d13e5('0x164c')]};return _0x255ef7['currentUser'][_0x2d13e5('0x1e75')]!==_0x2d13e5('0xa7c')?_0x3345d4[_0x2d13e5('0x17aa')][_0x2d13e5('0xd83')]({'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x255ef7['currentUser']['userProfileId'],'sectionId':0x4b3})[_0x2d13e5('0xa44')]['then'](function(_0xf6c099){const _0x5a33e8=_0x2d13e5;return _0x255ef7[_0x5a33e8('0x17aa')]=_0xf6c099&&_0xf6c099[_0x5a33e8('0x240f')]==0x1?_0xf6c099[_0x5a33e8('0x269a')][0x0]:null,_0x169a94;})['catch'](function(_0x2459f6){const _0x3df447=_0x2d13e5;_0x13f3d2[_0x3df447('0xfc9')]({'title':_0x3df447('0x2272'),'msg':_0x2459f6['message']});}):_0x169a94;}function _0xb3d474(_0x550d58){return _0x550d58?{'loaded':_0x30d8b3,'select_node':_0x200f4a}:{'loaded':_0x3f3533,'select_node':_0x29e155};}function _0x200f4a(_0x43adf5,_0x2ad22f){const _0x17eba9=_0x275e85;_0x255ef7[_0x17eba9('0x18c7')][_0x17eba9('0x14aa')](!![])[_0x17eba9('0x1314')](),_0x255ef7[_0x17eba9('0x18c7')][_0x17eba9('0x14aa')](!![])[_0x17eba9('0x13e')](),_0x255ef7[_0x17eba9('0xad5')]=_0x2ad22f[_0x17eba9('0x22d1')],_0x255ef7[_0x17eba9('0xad5')][_0x17eba9('0x2853')]=!![],_0x255ef7[_0x17eba9('0x1967')]=_0x255ef7[_0x17eba9('0x1a4b')][_0x17eba9('0x14aa')](!![])[_0x17eba9('0x1fb2')](_0x255ef7['currentNode'])[_0x17eba9('0x45a')]('/\x20'),_0x255ef7[_0x17eba9('0x2677')]='analyticCustomReport',_0x255ef7[_0x17eba9('0x2218')][_0x17eba9('0x5f6')]=_0x2ad22f['node']['id'],_0x98b6a();}function _0x29e155(_0x36ba10,_0x414486){const _0x417fb7=_0x275e85;_0x255ef7[_0x417fb7('0x1a4b')][_0x417fb7('0x14aa')](!![])[_0x417fb7('0x1314')](),_0x255ef7[_0x417fb7('0x1a4b')][_0x417fb7('0x14aa')](!![])['close_all'](),_0x255ef7[_0x417fb7('0xad5')]=_0x414486['node'],_0x255ef7[_0x417fb7('0xad5')][_0x417fb7('0x2853')]=![],_0x255ef7['currentPath']=_0x255ef7['treeDefaultInstance'][_0x417fb7('0x14aa')](!![])[_0x417fb7('0x1fb2')](_0x255ef7[_0x417fb7('0xad5')])['join']('/\x20'),_0x255ef7[_0x417fb7('0x2677')]=_0x417fb7('0x17c2'),_0x255ef7['query'][_0x417fb7('0x5f6')]=_0x414486['node']['id'],_0x98b6a();}function _0x30d8b3(){const _0x1ddf7a=_0x275e85;if(!_0x255ef7[_0x1ddf7a('0x5a4')]&&_0x255ef7[_0x1ddf7a('0x2677')]===_0x1ddf7a('0x1ff5')){const _0xe1e235=_0x255ef7[_0x1ddf7a('0x1a4b')]['jstree'](!![])[_0x1ddf7a('0x10de')](_0x255ef7['query'][_0x1ddf7a('0x5f6')]);_0x200f4a(null,{'node':_0xe1e235,'selected':_0xe1e235['id']});}}function _0x3f3533(){const _0x6d551=_0x275e85;if(!_0x255ef7[_0x6d551('0x5a4')]&&_0x255ef7[_0x6d551('0x2677')]==='analyticDefaultReport'){const _0x4171b4=_0x255ef7[_0x6d551('0x18c7')]['jstree'](!![])[_0x6d551('0x10de')](_0x255ef7[_0x6d551('0x2218')][_0x6d551('0x5f6')]);_0x29e155(null,{'node':_0x4171b4,'selected':_0x4171b4['id']});}}function _0x98b6a(){const _0x32e219=_0x275e85;_0x255ef7[_0x32e219('0x2218')][_0x32e219('0x1098')]=(_0x255ef7['query'][_0x32e219('0x1a43')]-0x1)*_0x255ef7[_0x32e219('0x2218')][_0x32e219('0x163f')];if(_0x255ef7[_0x32e219('0x2677')]){if(_0x255ef7[_0x32e219('0x98')]['role']===_0x32e219('0xa7c'))_0x255ef7['promise']=_0x3345d4[_0x255ef7['apiName']][_0x32e219('0xd83')](_0x255ef7[_0x32e219('0x2218')],_0x8252fc)[_0x32e219('0xa44')];else{if(!_0x255ef7[_0x32e219('0x17aa')])return _0x8252fc(null);else{if(_0x255ef7[_0x32e219('0x17aa')][_0x32e219('0x1a2b')])_0x255ef7[_0x32e219('0x1f48')]=_0x3345d4[_0x255ef7[_0x32e219('0x2677')]]['get'](_0x255ef7['query'],_0x8252fc)[_0x32e219('0xa44')];else{let _0x160c08=[];_0x255ef7[_0x32e219('0x1f48')]=_0x3345d4[_0x255ef7['apiName']][_0x32e219('0xd83')](_0x255ef7[_0x32e219('0x2218')])[_0x32e219('0xa44')][_0x32e219('0x1166')](function(_0x2c6962){const _0x5814f8=_0x32e219;return _0x160c08=_0x2c6962&&_0x2c6962[_0x5814f8('0x269a')]?_0x2c6962[_0x5814f8('0x269a')]:[],_0x160c08[_0x5814f8('0x264b')]>0x0?_0x3345d4['userProfileResource']['get']({'sectionId':_0x255ef7[_0x5814f8('0x17aa')]['id'],'type':_0x255ef7['apiName']===_0x5814f8('0x17c2')?_0x5814f8('0x2243'):_0x5814f8('0x1cc5')})[_0x5814f8('0xa44')][_0x5814f8('0x1166')](function(_0x476069){const _0x2c4543=_0x5814f8,_0x25ce76=_0x476069&&_0x476069['rows']?_0x476069[_0x2c4543('0x269a')]:[];if(_0x25ce76[_0x2c4543('0x264b')]>0x0){const _0x3f3644=[];return _0x160c08[_0x2c4543('0x2782')](function(_0x1cbcb0){const _0x3fd4e2=_0x2c4543,_0x7956b4=_0x2cfb05()[_0x3fd4e2('0xc38')](_0x25ce76,[_0x3fd4e2('0x24e8'),_0x1cbcb0['id']]);if(_0x7956b4)_0x3f3644[_0x3fd4e2('0x1514')](_0x1cbcb0);}),_0x8252fc({'count':_0x3f3644[_0x2c4543('0x264b')],'rows':_0x3f3644});}else return _0x8252fc(null);}):_0x8252fc(null);})[_0x32e219('0x1a80')](function(_0x512b8c){const _0x7435d3=_0x32e219;_0x13f3d2['error']({'title':_0x512b8c[_0x7435d3('0x52d')]?'API:'+_0x512b8c['status']+_0x7435d3('0x11e1')+_0x512b8c[_0x7435d3('0xe1b')]:_0x7435d3('0x2683'),'msg':_0x512b8c[_0x7435d3('0x25f4')]?JSON[_0x7435d3('0xbac')](_0x512b8c[_0x7435d3('0x25f4')]):_0x512b8c[_0x7435d3('0x1586')]()});});}}}}}function _0x8252fc(_0x360416){const _0x14eab2=_0x275e85;_0x255ef7[_0x14eab2('0x352')]=_0x360416||{'count':0x0,'rows':[]},!_0x255ef7[_0x14eab2('0x5a4')]&&_0x255ef7[_0x14eab2('0x266f')][_0x14eab2('0x1514')](_0x2cfb05()[_0x14eab2('0xc38')](_0x255ef7[_0x14eab2('0x352')][_0x14eab2('0x269a')],{'id':_0x255ef7[_0x14eab2('0x519')]['id']}));}function _0x21d0a9(){const _0x55f867=_0x275e85;_0x255ef7['treeDefaultData']=_0x255ef7['treeReports'][0x0]?angular['fromJson'](_0x255ef7[_0x55f867('0x14c7')][0x0]['tree']):[],_0x255ef7['treeCustomData']=_0x255ef7['treeReports'][0x1]?angular[_0x55f867('0x2524')](_0x255ef7['treeReports'][0x1][_0x55f867('0x1b5f')]):[],_0x255ef7[_0x55f867('0x28a0')]=_0xd2f567(),_0x255ef7[_0x55f867('0x21f2')]=_0xb3d474(![]),_0x255ef7[_0x55f867('0x6e0')]=_0xb3d474(!![]),_0x4b6258[_0x55f867('0x1f80')]({'controller':function(){return _0x255ef7;},'controllerAs':'vm','templateUrl':_0x8f2c8a,'autoWrap':!![],'skipHide':!![]});}function _0x57e40f(){const _0x33df7f=_0x275e85;_0x255ef7[_0x33df7f('0x892')][_0x33df7f('0x2659')]=_0x255ef7[_0x33df7f('0x266f')][0x0][_0x33df7f('0x4f0')],_0x255ef7[_0x33df7f('0xad5')]['custom']?(_0x255ef7[_0x33df7f('0x892')][_0x33df7f('0x251f')]=_0x255ef7[_0x33df7f('0x266f')][0x0]['id'],delete _0x255ef7[_0x33df7f('0x892')][_0x33df7f('0x1944')]):(_0x255ef7[_0x33df7f('0x892')]['DefaultReportId']=_0x255ef7[_0x33df7f('0x266f')][0x0]['id'],delete _0x255ef7[_0x33df7f('0x892')][_0x33df7f('0x251f')]),_0x29b558[_0x33df7f('0xc12')][_0x33df7f('0x2659')][_0x33df7f('0x27a2')](),_0x4b6258[_0x33df7f('0x1197')]();}function _0x15e2d3(){const _0x5e2a02=_0x275e85;_0x4b6258[_0x5e2a02('0x1197')]();}function _0x38e4e7(_0x57cfd0){return _0x57cfd0===null?undefined:new Date(_0x57cfd0);}function _0x32ddbc(_0x36c118){const _0x5adf99=_0x275e85;_0x4b6258[_0x5adf99('0x1197')](_0x36c118);}}const _0xbdfb4b=_0x55cbcc,_0x18aa54=_0x2734b2['p']+_0x36e6f4('0x245e');_0x2576f8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0xa0a'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x2576f8(_0x1e5c3a,_0x3583ad,_0x1e90cf,_0x1b286f,_0x3aa718,_0x111c07,_0x4151bf,_0x106c99,_0x629851,_0x37984b,_0x53d30c,_0x27538d,_0x23e08b,_0x498687,_0x262ac9,_0x1064a1,_0x17e291){const _0x5eac61=_0x36e6f4,_0x750249=this;_0x750249[_0x5eac61('0x5c9')]=_0x1064a1,_0x750249['setting']=_0x17e291,_0x750249['currentUser']=_0x262ac9['getCurrentUser'](),_0x750249[_0x5eac61('0xa0a')]=_0x629851||{'count':0x0,'rows':[]},_0x750249['userProfile']=_0x37984b,_0x750249['userProfileSection']=_0x53d30c&&_0x53d30c[_0x5eac61('0x240f')]==0x1?_0x53d30c[_0x5eac61('0x269a')][0x0]:null,_0x750249[_0x5eac61('0x243c')]=_0x262ac9[_0x5eac61('0xd87')](_0x750249[_0x5eac61('0x17aa')]?_0x750249[_0x5eac61('0x17aa')][_0x5eac61('0x243c')]:null),_0x750249[_0x5eac61('0x916')]='schedules',_0x750249['listOrder']='',_0x750249[_0x5eac61('0x104c')]=null,_0x750249['selectedScheduler']=[],_0x750249['query']={'fields':_0x5eac61('0xc5e'),'sort':_0x5eac61('0x14dc'),'limit':0xa,'page':0x1},_0x750249[_0x5eac61('0x1a79')]=_0x2cfb05()[_0x5eac61('0x155c')]([{'option':_0x5eac61('0x15a'),'value':_0x5eac61('0xbcb')},{'option':_0x5eac61('0x1c4'),'value':_0x5eac61('0x25a3')},{'option':_0x5eac61('0x1940'),'value':_0x5eac61('0xb2a')}],function(_0x395421){const _0x5a8be6=_0x5eac61;return _0x2cfb05()[_0x5a8be6('0xf3')](_0x395421['value'],new RegExp('\x27','g'),'');}),_0x750249['arraysubtractUnit']=_0x2cfb05()[_0x5eac61('0x155c')]([{'option':_0x5eac61('0x25e9'),'value':_0x5eac61('0x1c2d')},{'option':'Hours','value':_0x5eac61('0xb27')},{'option':'Days','value':_0x5eac61('0x2291')},{'option':_0x5eac61('0x17cb'),'value':_0x5eac61('0x18ad')},{'option':_0x5eac61('0x1b45'),'value':_0x5eac61('0xa86')},{'option':_0x5eac61('0x1612'),'value':'\x27quarters\x27'},{'option':_0x5eac61('0x1cc6'),'value':_0x5eac61('0x16f4')}],function(_0x19b02e){const _0x287a2d=_0x5eac61;return _0x2cfb05()[_0x287a2d('0xf3')](_0x19b02e[_0x287a2d('0x18e0')],new RegExp('\x27','g'),'');}),_0x750249[_0x5eac61('0x1f8e')]=_0x4f7af3,_0x750249[_0x5eac61('0x234a')]=_0x2dd75b,_0x750249[_0x5eac61('0x8d8')]=_0x880165,_0x750249[_0x5eac61('0x103b')]=_0x250487,_0x750249[_0x5eac61('0x2864')]=_0x750609,_0x750249[_0x5eac61('0x1418')]=_0x51316c,_0x750249[_0x5eac61('0x23cb')]=_0x1921bc,_0x750249['exportSelectedScheduler']=_0xf10e82,_0x750249[_0x5eac61('0x62f')]=_0x1f461c,_0x750249[_0x5eac61('0x11fb')]=_0x2fa4d9,_0x750249[_0x5eac61('0x630')]=_0x2489d5,_0x27538d['analyticTreeReport'][_0x5eac61('0xd83')]({})['$promise']['then'](function(_0x2f8a28){const _0x1af170=_0x5eac61;_0x750249['treeReports']=_0x2f8a28[_0x1af170('0x269a')]||[];})['catch'](function(_0x4d04b6){const _0x41d1f3=_0x5eac61;_0x498687[_0x41d1f3('0xfc9')]({'title':_0x4d04b6[_0x41d1f3('0x52d')]?'API:'+_0x4d04b6['status']+'\x20-\x20'+_0x4d04b6['statusText']:_0x41d1f3('0x27b9'),'msg':_0x4d04b6['data']?JSON[_0x41d1f3('0xbac')](_0x4d04b6[_0x41d1f3('0x25f4')]):_0x4d04b6[_0x41d1f3('0x1586')]()});}),_0x262ac9[_0x5eac61('0x1ac6')]('admin')?_0x27538d[_0x5eac61('0x21b9')]['get']({'fields':'id,name','sort':'name'})['$promise'][_0x5eac61('0x1166')](function(_0x9dbd43){_0x750249['mailAccounts']=_0x9dbd43['rows']||[];})[_0x5eac61('0x1a80')](function(_0x2369c6){const _0x229aab=_0x5eac61;_0x498687['error']({'title':_0x2369c6[_0x229aab('0x52d')]?_0x229aab('0x1e21')+_0x2369c6[_0x229aab('0x52d')]+_0x229aab('0x11e1')+_0x2369c6['statusText']:_0x229aab('0x4bd'),'msg':_0x2369c6[_0x229aab('0x25f4')]?JSON[_0x229aab('0xbac')](_0x2369c6[_0x229aab('0x25f4')]):_0x2369c6['toString']()});}):_0x27538d[_0x5eac61('0x21b9')][_0x5eac61('0xd83')]({'fields':'id,name','sort':_0x5eac61('0x4f0')})[_0x5eac61('0xa44')][_0x5eac61('0x1166')](function(_0x4d5d02){const _0x521129=_0x5eac61;_0x750249[_0x521129('0xf85')]=_0x4d5d02[_0x521129('0x269a')]||[];})[_0x5eac61('0x1166')](function(){const _0x517c73=_0x5eac61;return _0x27538d[_0x517c73('0x17aa')]['get']({'userProfileId':_0x750249[_0x517c73('0x98')][_0x517c73('0xb86')],'sectionId':0x25a})[_0x517c73('0xa44')];})[_0x5eac61('0x1166')](function(_0x5f26d9){const _0x3bb1ab=_0x5eac61,_0x993cf8=_0x5f26d9&&_0x5f26d9[_0x3bb1ab('0x269a')]?_0x5f26d9[_0x3bb1ab('0x269a')][0x0]:null;if(!_0x993cf8){const _0x3aa951=[];let _0x483636=null;_0x750249[_0x3bb1ab('0x892')]&&(_0x483636=_0x2cfb05()[_0x3bb1ab('0xc38')](_0x750249[_0x3bb1ab('0xf85')],{'id':Number(_0x750249[_0x3bb1ab('0x892')][_0x3bb1ab('0x56')])}));for(let _0x3dccc6=0x0;_0x3dccc6<_0x750249[_0x3bb1ab('0xf85')][_0x3bb1ab('0x264b')];_0x3dccc6++){_0x483636&&_0x750249[_0x3bb1ab('0xf85')][_0x3dccc6]['id']===_0x483636['id']&&(_0x750249[_0x3bb1ab('0xf85')][_0x3dccc6][_0x3bb1ab('0x2378')]=![],_0x3aa951['push'](_0x750249[_0x3bb1ab('0xf85')][_0x3dccc6]));}_0x750249[_0x3bb1ab('0xf85')]=_0x3aa951;}else{if(!_0x993cf8[_0x3bb1ab('0x1a2b')])return _0x27538d[_0x3bb1ab('0x4b5')][_0x3bb1ab('0xd83')]({'sectionId':_0x993cf8['id']})['$promise'][_0x3bb1ab('0x1166')](function(_0x539c41){const _0x38a998=_0x3bb1ab,_0x596f63=_0x2cfb05()[_0x38a998('0x2563')](_0x539c41[_0x38a998('0x269a')],function(_0x205334){const _0x425a5d=_0x38a998;return _0x2cfb05()[_0x425a5d('0xc38')](_0x750249[_0x425a5d('0xf85')],{'id':_0x205334[_0x425a5d('0x24e8')]});});let _0x3d16a4=null;_0x750249[_0x38a998('0x892')]&&(_0x3d16a4=_0x2cfb05()[_0x38a998('0xc38')](_0x750249[_0x38a998('0xf85')],{'id':Number(_0x750249[_0x38a998('0x892')][_0x38a998('0x56')])}));if(_0x3d16a4&&!_0x2cfb05()[_0x38a998('0x1798')](_0x596f63,['id',_0x3d16a4['id']])){const _0x4c25fd=_0x2cfb05()[_0x38a998('0xc38')](_0x750249[_0x38a998('0xf85')],{'id':_0x3d16a4['id']});_0x4c25fd['canSelect']=![],_0x596f63[_0x38a998('0x1514')](_0x4c25fd);}_0x750249[_0x38a998('0xf85')]=_0x596f63;});}})[_0x5eac61('0x1a80')](function(_0x54d1bd){const _0xdbd3c=_0x5eac61;_0x498687[_0xdbd3c('0xfc9')]({'title':_0x54d1bd[_0xdbd3c('0x52d')]?_0xdbd3c('0x1e21')+_0x54d1bd[_0xdbd3c('0x52d')]+_0xdbd3c('0x11e1')+_0x54d1bd['statusText']:_0xdbd3c('0x5e'),'msg':_0x54d1bd[_0xdbd3c('0x25f4')]?JSON[_0xdbd3c('0xbac')](_0x54d1bd[_0xdbd3c('0x25f4')]):_0x54d1bd[_0xdbd3c('0x1586')]()});});function _0x4f7af3(_0x3eb1c6,_0x125279){const _0x1dec71=_0x5eac61;_0x3aa718[_0x1dec71('0x1f80')]({'controller':_0x1dec71('0x2f1'),'controllerAs':'vm','templateUrl':_0x18aa54,'parent':angular[_0x1dec71('0x1194')](_0x111c07[_0x1dec71('0x8d2')]),'targetEvent':_0x125279,'clickOutsideToClose':!![],'locals':{'schedule':_0x3eb1c6,'schedules':_0x750249[_0x1dec71('0xa0a')][_0x1dec71('0x269a')],'license':_0x750249[_0x1dec71('0x5c9')],'setting':null,'crudPermissions':_0x750249[_0x1dec71('0x243c')]}});}function _0x2dd75b(_0x1937d9,_0x1ac6aa){const _0x18922a=_0x5eac61,_0x22dc5c=_0x3aa718['confirm']()[_0x18922a('0xcdc')](_0x18922a('0x24ca'))[_0x18922a('0xf3c')](_0x18922a('0x12b5')+(_0x1937d9[_0x18922a('0x4f0')]||_0x18922a('0x892'))+''+'\x20will\x20be\x20run.')[_0x18922a('0x8e8')](_0x18922a('0x150e'))['targetEvent'](_0x1ac6aa)['ok']('OK')[_0x18922a('0x3f')](_0x18922a('0x2d3'));_0x3aa718[_0x18922a('0x1f80')](_0x22dc5c)[_0x18922a('0x1166')](function(){const _0x5a7c86=_0x18922a;return _0x27538d[_0x5a7c86('0x892')][_0x5a7c86('0xca')]({'id':_0x1937d9['id']})[_0x5a7c86('0xa44')];},function(){const _0x1574f4=_0x18922a;console[_0x1574f4('0x455')](_0x1574f4('0x2d3'));});}function _0x880165(_0x10047d,_0x2f3e0d){const _0x282c55=_0x5eac61,_0x1a813f=_0x3aa718['confirm']()[_0x282c55('0xcdc')](_0x282c55('0x288d')+_0x2cfb05()[_0x282c55('0xb35')](_0x282c55('0x892'))+'?')[_0x282c55('0xf3c')](_0x282c55('0x12b5')+(_0x10047d['name']||_0x282c55('0x892'))+_0x282c55('0xace')+_0x282c55('0x3f3'))[_0x282c55('0x8e8')]('delete\x20schedule')[_0x282c55('0x203b')](_0x2f3e0d)['ok']('OK')[_0x282c55('0x3f')]('CANCEL');_0x3aa718[_0x282c55('0x1f80')](_0x1a813f)[_0x282c55('0x1166')](function(){_0x1921bc(_0x10047d);},function(){const _0x57c3b2=_0x282c55;console[_0x57c3b2('0x455')](_0x57c3b2('0x2d3'));});}let _0x49fdb4=!![],_0x70227f=0x1;_0x1e5c3a['$watch'](_0x5eac61('0x12d8'),function(_0xceb1a3,_0x35ce49){const _0x276006=_0x5eac61;_0x49fdb4?_0x4151bf(function(){_0x49fdb4=![];}):(!_0x35ce49&&(_0x70227f=_0x750249[_0x276006('0x2218')][_0x276006('0x1a43')]),_0xceb1a3!==_0x35ce49&&(_0x750249['query'][_0x276006('0x1a43')]=0x1),!_0xceb1a3&&(_0x750249['query']['page']=_0x70227f),_0x750249[_0x276006('0x2864')]());});function _0x250487(_0x52c6cd){_0x750249['schedules']=_0x52c6cd||{'count':0x0,'rows':[]};}function _0x750609(){const _0x1d9a5a=_0x5eac61;_0x750249[_0x1d9a5a('0x2218')][_0x1d9a5a('0x1098')]=(_0x750249[_0x1d9a5a('0x2218')]['page']-0x1)*_0x750249['query'][_0x1d9a5a('0x163f')],_0x262ac9[_0x1d9a5a('0x1ac6')](_0x1d9a5a('0xa7c'))?_0x750249[_0x1d9a5a('0x1f48')]=_0x27538d[_0x1d9a5a('0x892')]['get'](_0x750249[_0x1d9a5a('0x2218')],_0x250487)[_0x1d9a5a('0xa44')]:(_0x750249[_0x1d9a5a('0x2218')]['id']=_0x750249[_0x1d9a5a('0x7f')]['id'],_0x750249['query'][_0x1d9a5a('0xe60')]='Scheduler',_0x750249['promise']=_0x27538d['userProfile'][_0x1d9a5a('0x263a')](_0x750249['query'],_0x250487)[_0x1d9a5a('0xa44')]);}function _0x51316c(_0x3965ce,_0x4b891){const _0x2938c0=_0x5eac61;_0x3aa718[_0x2938c0('0x1f80')]({'controller':_0x2938c0('0x2f1'),'controllerAs':'vm','templateUrl':_0x18aa54,'parent':angular[_0x2938c0('0x1194')](_0x111c07[_0x2938c0('0x8d2')]),'targetEvent':_0x3965ce,'clickOutsideToClose':!![],'locals':{'schedule':_0x4b891,'schedules':_0x750249['schedules'][_0x2938c0('0x269a')],'license':_0x750249[_0x2938c0('0x5c9')],'setting':_0x750249[_0x2938c0('0xf8a')],'crudPermissions':_0x750249[_0x2938c0('0x243c')]}});}function _0x1921bc(_0x5794ba){const _0x31338b=_0x5eac61;_0x27538d[_0x31338b('0x892')][_0x31338b('0x906')]({'id':_0x5794ba['id']})[_0x31338b('0xa44')]['then'](function(){const _0x936ad0=_0x31338b;_0x2cfb05()[_0x936ad0('0x127f')](_0x750249[_0x936ad0('0xa0a')][_0x936ad0('0x269a')],{'id':_0x5794ba['id']}),_0x750249['schedules']['count']-=0x1,!_0x750249['schedules'][_0x936ad0('0x269a')]['length']&&_0x750249[_0x936ad0('0x2864')](),_0x498687[_0x936ad0('0x103b')]({'title':_0x2cfb05()['startCase']('Schedule')+_0x936ad0('0x2b6'),'msg':_0x5794ba[_0x936ad0('0x4f0')]?_0x5794ba[_0x936ad0('0x4f0')]+_0x936ad0('0x7cd'):''});})[_0x31338b('0x1a80')](function(_0x36df1){const _0x89adfc=_0x31338b;if(_0x36df1['data']&&_0x36df1[_0x89adfc('0x25f4')][_0x89adfc('0x61a')]&&_0x36df1[_0x89adfc('0x25f4')]['errors']['length']){_0x750249['errors']=_0x36df1[_0x89adfc('0x25f4')][_0x89adfc('0x61a')]||[{'message':_0x36df1[_0x89adfc('0x1586')](),'type':_0x89adfc('0x254a')}];for(let _0x5f04f6=0x0;_0x5f04f6<_0x36df1[_0x89adfc('0x25f4')][_0x89adfc('0x61a')]['length'];_0x5f04f6++){_0x498687[_0x89adfc('0xfc9')]({'title':_0x36df1[_0x89adfc('0x25f4')]['errors'][_0x5f04f6][_0x89adfc('0x1345')],'msg':_0x36df1[_0x89adfc('0x25f4')][_0x89adfc('0x61a')][_0x5f04f6][_0x89adfc('0x1e70')]});}}else _0x498687[_0x89adfc('0xfc9')]({'title':_0x36df1[_0x89adfc('0x52d')]?_0x89adfc('0x1e21')+_0x36df1[_0x89adfc('0x52d')]+'\x20-\x20'+_0x36df1[_0x89adfc('0xe1b')]:_0x89adfc('0x254a'),'msg':_0x36df1['data']?JSON[_0x89adfc('0xbac')](_0x36df1[_0x89adfc('0x25f4')][_0x89adfc('0x1e70')]):_0x36df1[_0x89adfc('0x1e70')]||_0x36df1[_0x89adfc('0x1586')]()});});}function _0xf10e82(){const _0x13173e=_0x5eac61,_0x33885f=angular['copy'](_0x750249[_0x13173e('0x228f')]);return _0x750249['selectedScheduler']=[],_0x33885f;}function _0x1f461c(_0x2b2925){const _0x5286d7=_0x5eac61,_0x5cf7e4=_0x3aa718[_0x5286d7('0x1d26')]()[_0x5286d7('0xcdc')](_0x5286d7('0x21de'))[_0x5286d7('0xf3c')](_0x5286d7('0x12b5')+_0x750249[_0x5286d7('0x228f')][_0x5286d7('0x264b')]+_0x5286d7('0x196d')+_0x5286d7('0x3f3'))[_0x5286d7('0x8e8')](_0x5286d7('0x20b7'))[_0x5286d7('0x203b')](_0x2b2925)['ok']('OK')[_0x5286d7('0x3f')](_0x5286d7('0x2d3'));_0x3aa718[_0x5286d7('0x1f80')](_0x5cf7e4)[_0x5286d7('0x1166')](function(){const _0x70e0b9=_0x5286d7;_0x750249[_0x70e0b9('0x228f')][_0x70e0b9('0x2782')](function(_0x586240){_0x1921bc(_0x586240);}),_0x750249[_0x70e0b9('0x228f')]=[];});}function _0x2fa4d9(){const _0x2a313d=_0x5eac61;_0x750249[_0x2a313d('0x228f')]=[];}function _0x2489d5(){const _0x1628d2=_0x5eac61;_0x750249[_0x1628d2('0x228f')]=_0x750249[_0x1628d2('0xa0a')]['rows'];}}const _0x4c9b32=_0x2576f8;_0x1e4a78[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x137'),'sound','api','Auth',_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x1e4a78(_0x31a058,_0x513487,_0x43c947,_0x1fc961,_0x511bca,_0x18f44d,_0x4290ad,_0x326442,_0x376dc0,_0x3b2955,_0x1e5356,_0x5aedc8,_0x2ce973,_0x49f4ea){const _0x459c00=_0x36e6f4,_0x12b9d5=this;_0x12b9d5[_0x459c00('0x98')]=_0x1e5356[_0x459c00('0x26cd')](),_0x12b9d5['errors']=[],_0x12b9d5[_0x459c00('0xf8a')]=_0x2ce973,_0x12b9d5['license']=_0x5aedc8,_0x12b9d5[_0x459c00('0x243c')]=_0x49f4ea,_0x12b9d5[_0x459c00('0x128b')]={},_0x12b9d5[_0x459c00('0x2900')]=_0x12b9d5['setting']&&_0x12b9d5[_0x459c00('0xf8a')][_0x459c00('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x12b9d5[_0x459c00('0xcdc')]=_0x459c00('0x1c49'),_0x12b9d5[_0x459c00('0x960')]=angular['copy'](_0x376dc0),_0x12b9d5[_0x459c00('0x137')]=_0x326442,_0x12b9d5[_0x459c00('0x104e')]=![];!_0x12b9d5[_0x459c00('0x960')]&&(_0x12b9d5[_0x459c00('0x960')]={},_0x12b9d5[_0x459c00('0xcdc')]=_0x459c00('0x1651'),_0x12b9d5[_0x459c00('0x104e')]=!![]);_0x12b9d5[_0x459c00('0x8a6')]=_0x1db493,_0x12b9d5[_0x459c00('0x4d0')]=_0x7e1bfe,_0x12b9d5[_0x459c00('0x96c')]=_0x8ec95e,_0x12b9d5['getDateFromString']=_0x27d8fc,_0x12b9d5[_0x459c00('0x24a0')]=_0xa0eb5f;function _0x1db493(){const _0x54547b=_0x459c00;_0x12b9d5[_0x54547b('0x61a')]=[],_0x3b2955[_0x54547b('0x960')][_0x54547b('0x9cc')](_0x12b9d5['sound'])[_0x54547b('0xa44')][_0x54547b('0x1166')](function(_0x2c0b63){const _0x325717=_0x54547b;_0x12b9d5[_0x325717('0x137')][_0x325717('0x2450')](_0x2c0b63[_0x325717('0x2876')]()),_0x4290ad[_0x325717('0x103b')]({'title':'Sound\x20properly\x20created','msg':_0x12b9d5[_0x325717('0x960')]['name']?_0x12b9d5[_0x325717('0x960')][_0x325717('0x4f0')]+_0x325717('0x1eda'):''}),_0xa0eb5f(_0x2c0b63);})[_0x54547b('0x1a80')](function(_0x3693e1){const _0x4cc353=_0x54547b;if(_0x3693e1[_0x4cc353('0x25f4')]&&_0x3693e1[_0x4cc353('0x25f4')][_0x4cc353('0x61a')]&&_0x3693e1[_0x4cc353('0x25f4')]['errors'][_0x4cc353('0x264b')]){_0x12b9d5[_0x4cc353('0x61a')]=_0x3693e1[_0x4cc353('0x25f4')][_0x4cc353('0x61a')]||[{'message':_0x3693e1['toString'](),'type':_0x4cc353('0x114e')}];for(let _0x24577b=0x0;_0x24577b<_0x3693e1[_0x4cc353('0x25f4')]['errors'][_0x4cc353('0x264b')];_0x24577b+=0x1){_0x4290ad[_0x4cc353('0xfc9')]({'title':_0x3693e1[_0x4cc353('0x25f4')]['errors'][_0x24577b]['type'],'msg':_0x3693e1[_0x4cc353('0x25f4')]['errors'][_0x24577b][_0x4cc353('0x1e70')]});}}else _0x4290ad['error']({'title':_0x3693e1[_0x4cc353('0x52d')]?'API:'+_0x3693e1[_0x4cc353('0x52d')]+'\x20-\x20'+_0x3693e1[_0x4cc353('0xe1b')]:_0x4cc353('0x114e'),'msg':_0x3693e1[_0x4cc353('0x25f4')]?JSON[_0x4cc353('0xbac')](_0x3693e1['data'][_0x4cc353('0x1e70')]):_0x3693e1['toString']()});});}function _0x7e1bfe(){const _0x2ff766=_0x459c00;_0x12b9d5[_0x2ff766('0x61a')]=[],_0x3b2955[_0x2ff766('0x960')][_0x2ff766('0x1449')]({'id':_0x12b9d5[_0x2ff766('0x960')]['id']},_0x12b9d5['sound'])[_0x2ff766('0xa44')][_0x2ff766('0x1166')](function(_0x1a3b52){const _0x1b4534=_0x2ff766,_0x38385e=_0x2cfb05()[_0x1b4534('0xc38')](_0x12b9d5['sounds'],{'id':_0x1a3b52['id']});_0x38385e&&_0x2cfb05()[_0x1b4534('0xcc3')](_0x38385e,_0x2cfb05()[_0x1b4534('0x1a08')](_0x1a3b52[_0x1b4534('0x2876')](),_0x2cfb05()['keys'](_0x38385e))),_0x4290ad[_0x1b4534('0x103b')]({'title':'Sound\x20properly\x20saved!','msg':_0x12b9d5['sound']['name']?_0x12b9d5[_0x1b4534('0x960')][_0x1b4534('0x4f0')]+_0x1b4534('0x7d'):''}),_0xa0eb5f(_0x1a3b52);})['catch'](function(_0x55ffdb){const _0x6ad6ba=_0x2ff766;if(_0x55ffdb['data']&&_0x55ffdb[_0x6ad6ba('0x25f4')][_0x6ad6ba('0x61a')]&&_0x55ffdb['data'][_0x6ad6ba('0x61a')]['length']){_0x12b9d5[_0x6ad6ba('0x61a')]=_0x55ffdb[_0x6ad6ba('0x25f4')][_0x6ad6ba('0x61a')]||[{'message':_0x55ffdb['toString'](),'type':_0x6ad6ba('0x929')}];for(let _0x1daaad=0x0;_0x1daaad<_0x55ffdb[_0x6ad6ba('0x25f4')][_0x6ad6ba('0x61a')]['length'];_0x1daaad++){_0x4290ad[_0x6ad6ba('0xfc9')]({'title':_0x55ffdb['data'][_0x6ad6ba('0x61a')][_0x1daaad][_0x6ad6ba('0x1345')],'msg':_0x55ffdb['data'][_0x6ad6ba('0x61a')][_0x1daaad]['message']});}}else _0x4290ad[_0x6ad6ba('0xfc9')]({'title':_0x55ffdb[_0x6ad6ba('0x52d')]?'API:'+_0x55ffdb[_0x6ad6ba('0x52d')]+_0x6ad6ba('0x11e1')+_0x55ffdb[_0x6ad6ba('0xe1b')]:'api.sound.update','msg':_0x55ffdb[_0x6ad6ba('0x25f4')]?JSON[_0x6ad6ba('0xbac')](_0x55ffdb[_0x6ad6ba('0x25f4')][_0x6ad6ba('0x1e70')]):_0x55ffdb['toString']()});});}function _0x8ec95e(_0x128682){const _0x34dfbf=_0x459c00;_0x12b9d5['errors']=[];const _0x200a40=_0x1fc961['confirm']()[_0x34dfbf('0xcdc')](_0x34dfbf('0x7fb'))[_0x34dfbf('0xacc')](_0x34dfbf('0x9b6'))['ariaLabel']('Delete\x20Sound')['ok'](_0x34dfbf('0x18'))[_0x34dfbf('0x3f')]('Cancel')[_0x34dfbf('0x203b')](_0x128682);_0x1fc961[_0x34dfbf('0x1f80')](_0x200a40)[_0x34dfbf('0x1166')](function(){const _0xcb1641=_0x34dfbf;_0x3b2955['sound'][_0xcb1641('0x906')]({'id':_0x12b9d5['sound']['id']})[_0xcb1641('0xa44')]['then'](function(){const _0x35f08e=_0xcb1641;_0x2cfb05()[_0x35f08e('0x127f')](_0x12b9d5[_0x35f08e('0x137')],{'id':_0x12b9d5[_0x35f08e('0x960')]['id']}),_0x4290ad[_0x35f08e('0x103b')]({'title':_0x35f08e('0x63c'),'msg':(_0x12b9d5[_0x35f08e('0x960')]['name']||'sound')+_0x35f08e('0x7cd')}),_0xa0eb5f(_0x12b9d5[_0x35f08e('0x960')]);})[_0xcb1641('0x1a80')](function(_0x10122c){const _0x59ed7a=_0xcb1641;if(_0x10122c[_0x59ed7a('0x25f4')]&&_0x10122c[_0x59ed7a('0x25f4')]['errors']&&_0x10122c[_0x59ed7a('0x25f4')][_0x59ed7a('0x61a')][_0x59ed7a('0x264b')]){_0x12b9d5[_0x59ed7a('0x61a')]=_0x10122c[_0x59ed7a('0x25f4')][_0x59ed7a('0x61a')]||[{'message':_0x10122c['toString'](),'type':'api.sound.delete'}];for(let _0x218fef=0x0;_0x218fef<_0x10122c[_0x59ed7a('0x25f4')][_0x59ed7a('0x61a')][_0x59ed7a('0x264b')];_0x218fef++){_0x4290ad[_0x59ed7a('0xfc9')]({'title':_0x10122c[_0x59ed7a('0x25f4')]['errors'][_0x218fef]['type'],'msg':_0x10122c[_0x59ed7a('0x25f4')][_0x59ed7a('0x61a')][_0x218fef][_0x59ed7a('0x1e70')]});}}else _0x4290ad[_0x59ed7a('0xfc9')]({'title':_0x10122c[_0x59ed7a('0x52d')]?_0x59ed7a('0x1e21')+_0x10122c[_0x59ed7a('0x52d')]+'\x20-\x20'+_0x10122c[_0x59ed7a('0xe1b')]:_0x59ed7a('0x1853'),'msg':_0x10122c[_0x59ed7a('0x25f4')]?JSON[_0x59ed7a('0xbac')](_0x10122c[_0x59ed7a('0x25f4')][_0x59ed7a('0x1e70')]):_0x10122c['message']||_0x10122c[_0x59ed7a('0x1586')]()});});},function(){});}function _0x27d8fc(_0x5459f1){return _0x5459f1===null?undefined:new Date(_0x5459f1);}function _0xa0eb5f(_0x11af6f){_0x1fc961['hide'](_0x11af6f);}}const _0x56a1b3=_0x1e4a78,_0x2b9dc9=_0x2734b2['p']+_0x36e6f4('0x4b'),_0x51e770=_0x2734b2['p']+_0x36e6f4('0xb04');_0x54eaeb['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),'$translate',_0x36e6f4('0x137'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),'toasty','Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x54eaeb(_0x29f2c9,_0x2a1a5e,_0x245762,_0x358032,_0x4629ee,_0x6239a2,_0x29effa,_0x3b9c1a,_0x230e01,_0x40d810,_0x4837b9,_0x439e77,_0x31dd9c,_0x38efc0,_0x1e71bc,_0x5cb144,_0x3ea6b0){const _0x5cd8c1=_0x36e6f4,_0x1d205a=this;_0x1d205a[_0x5cd8c1('0x5c9')]=_0x5cb144,_0x1d205a[_0x5cd8c1('0xf8a')]=_0x3ea6b0,_0x1d205a[_0x5cd8c1('0x98')]=_0x1e71bc[_0x5cd8c1('0x26cd')](),_0x1d205a[_0x5cd8c1('0x137')]=_0x230e01||{'count':0x0,'rows':[]},_0x1d205a[_0x5cd8c1('0x7f')]=_0x40d810,_0x1d205a[_0x5cd8c1('0x17aa')]=_0x4837b9&&_0x4837b9[_0x5cd8c1('0x240f')]==0x1?_0x4837b9[_0x5cd8c1('0x269a')][0x0]:null,_0x1d205a['crudPermissions']=_0x1e71bc[_0x5cd8c1('0xd87')](_0x1d205a['userProfileSection']?_0x1d205a[_0x5cd8c1('0x17aa')][_0x5cd8c1('0x243c')]:null),_0x1d205a[_0x5cd8c1('0x916')]='sounds',_0x1d205a[_0x5cd8c1('0xef5')]='',_0x1d205a[_0x5cd8c1('0x104c')]=null,_0x1d205a[_0x5cd8c1('0x27df')]=[],_0x1d205a[_0x5cd8c1('0x2218')]={'fields':_0x5cd8c1('0x1b0c'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x1d205a[_0x5cd8c1('0x1f8e')]=_0x5ee6c5,_0x1d205a[_0x5cd8c1('0x424')]=_0x5d4e03,_0x1d205a[_0x5cd8c1('0x8d8')]=_0xab6dd0,_0x1d205a[_0x5cd8c1('0x103b')]=_0x26c432,_0x1d205a[_0x5cd8c1('0x30a')]=_0xc1e108,_0x1d205a['createOrEditSound']=_0x481431,_0x1d205a[_0x5cd8c1('0x96c')]=_0x35518a,_0x1d205a[_0x5cd8c1('0x739')]=_0x3e3e1d,_0x1d205a[_0x5cd8c1('0x1772')]=_0x15b45d,_0x1d205a[_0x5cd8c1('0xfa9')]=_0x4d559d,_0x1d205a[_0x5cd8c1('0xdc7')]=_0x27cb08,_0x1d205a[_0x5cd8c1('0x2261')]=_0x4ba933;function _0x5ee6c5(_0x3c577b,_0x4a03f4){const _0x3158c2=_0x5cd8c1;_0x4629ee[_0x3158c2('0x1f80')]({'controller':_0x3158c2('0x1817'),'controllerAs':'vm','templateUrl':_0x2b9dc9,'parent':angular[_0x3158c2('0x1194')](_0x6239a2[_0x3158c2('0x8d2')]),'targetEvent':_0x4a03f4,'clickOutsideToClose':!![],'locals':{'sound':_0x3c577b,'sounds':_0x1d205a[_0x3158c2('0x137')]['rows'],'license':_0x1d205a['license'],'setting':null,'crudPermissions':_0x1d205a['crudPermissions']}});}function _0x5d4e03(_0x11ff0b){const _0x1fa1a0=_0x5cd8c1;return _0x439e77[_0x1fa1a0('0x960')][_0x1fa1a0('0x2ad')]({'id':_0x11ff0b['id']})[_0x1fa1a0('0xa44')][_0x1fa1a0('0x1166')](function(_0xd6d42d){const _0x4fbe0d=_0x1fa1a0,_0x5379fa=[_0xd6d42d[_0x4fbe0d('0x20ed')]];let _0xb97b69=_0x4fbe0d('0x2ad');const _0x5e53a0=new Blob(_0x5379fa,{'type':_0xd6d42d[_0x4fbe0d('0x1345')]});_0xb97b69=_0x11ff0b[_0x4fbe0d('0x237')]?_0x11ff0b[_0x4fbe0d('0x28d5')]+'.'+_0x11ff0b[_0x4fbe0d('0x237')]:_0x11ff0b['save_name'];const _0x2c6e65=window[_0x4fbe0d('0x136d')][_0x4fbe0d('0xdd')]('a');_0x2c6e65['setAttribute'](_0x4fbe0d('0x14f9'),URL['createObjectURL'](_0x5e53a0)),_0x2c6e65[_0x4fbe0d('0xffd')](_0x4fbe0d('0x2ad'),_0xb97b69),document['body'][_0x4fbe0d('0x21a')](_0x2c6e65),_0x2c6e65['click']();})['catch'](function(_0xce6118){const _0x2a4d25=_0x1fa1a0;if(_0xce6118[_0x2a4d25('0x25f4')]&&_0xce6118['data'][_0x2a4d25('0x61a')]&&_0xce6118[_0x2a4d25('0x25f4')]['errors']['length'])for(let _0x142933=0x0;_0x142933<_0xce6118[_0x2a4d25('0x25f4')][_0x2a4d25('0x61a')]['length'];_0x142933++){_0x38efc0[_0x2a4d25('0xfc9')]({'title':_0xce6118[_0x2a4d25('0x25f4')][_0x2a4d25('0x61a')][_0x142933][_0x2a4d25('0x1345')],'msg':_0xce6118[_0x2a4d25('0x25f4')]['errors'][_0x142933][_0x2a4d25('0x1e70')]});}else _0x38efc0[_0x2a4d25('0xfc9')]({'title':_0xce6118[_0x2a4d25('0x52d')]?_0x2a4d25('0x1e21')+_0xce6118[_0x2a4d25('0x52d')]+_0x2a4d25('0x11e1')+_0xce6118[_0x2a4d25('0xe1b')]:_0x2a4d25('0x114e'),'msg':_0xce6118['data']?JSON[_0x2a4d25('0xbac')](_0xce6118[_0x2a4d25('0x25f4')][_0x2a4d25('0x1e70')]):_0xce6118[_0x2a4d25('0x1586')]()});});}function _0xab6dd0(_0x576116,_0x1003a7){const _0x3d887b=_0x5cd8c1,_0x312f95=_0x4629ee['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x3d887b('0xb35')](_0x3d887b('0x960'))+'?')[_0x3d887b('0xf3c')](_0x3d887b('0x12b5')+(_0x576116[_0x3d887b('0x4f0')]||_0x3d887b('0x960'))+_0x3d887b('0xace')+_0x3d887b('0x3f3'))[_0x3d887b('0x8e8')](_0x3d887b('0x766'))['targetEvent'](_0x1003a7)['ok']('OK')[_0x3d887b('0x3f')](_0x3d887b('0x2d3'));_0x4629ee[_0x3d887b('0x1f80')](_0x312f95)['then'](function(){_0x35518a(_0x576116);},function(){const _0x955edf=_0x3d887b;console['log'](_0x955edf('0x2d3'));});}let _0x4e9981=!![],_0x2ace2b=0x1;_0x29f2c9[_0x5cd8c1('0xe83')]('vm.query.filter',function(_0x269f19,_0x54541e){const _0x48e887=_0x5cd8c1;_0x4e9981?_0x29effa(function(){_0x4e9981=![];}):(!_0x54541e&&(_0x2ace2b=_0x1d205a[_0x48e887('0x2218')]['page']),_0x269f19!==_0x54541e&&(_0x1d205a[_0x48e887('0x2218')][_0x48e887('0x1a43')]=0x1),!_0x269f19&&(_0x1d205a['query'][_0x48e887('0x1a43')]=_0x2ace2b),_0x1d205a[_0x48e887('0x30a')]());});function _0x26c432(_0x5ebc85){_0x1d205a['sounds']=_0x5ebc85||{'count':0x0,'rows':[]};}function _0xc1e108(){const _0x40a2cb=_0x5cd8c1;_0x1d205a[_0x40a2cb('0x2218')]['offset']=(_0x1d205a[_0x40a2cb('0x2218')][_0x40a2cb('0x1a43')]-0x1)*_0x1d205a[_0x40a2cb('0x2218')][_0x40a2cb('0x163f')],_0x1e71bc[_0x40a2cb('0x1ac6')]('admin')?_0x1d205a['promise']=_0x439e77[_0x40a2cb('0x960')][_0x40a2cb('0xd83')](_0x1d205a[_0x40a2cb('0x2218')],_0x26c432)['$promise']:(_0x1d205a[_0x40a2cb('0x2218')]['id']=_0x1d205a[_0x40a2cb('0x7f')]['id'],_0x1d205a[_0x40a2cb('0x2218')]['section']=_0x40a2cb('0x1ece'),_0x1d205a['promise']=_0x439e77['userProfile'][_0x40a2cb('0x263a')](_0x1d205a[_0x40a2cb('0x2218')],_0x26c432)['$promise']);}function _0x481431(_0x1768fb,_0x1d573c){const _0x2fcb71=_0x5cd8c1;_0x4629ee['show']({'controller':_0x2fcb71('0x1817'),'controllerAs':'vm','templateUrl':_0x2b9dc9,'parent':angular[_0x2fcb71('0x1194')](_0x6239a2[_0x2fcb71('0x8d2')]),'targetEvent':_0x1768fb,'clickOutsideToClose':!![],'locals':{'sound':_0x1d573c,'sounds':_0x1d205a[_0x2fcb71('0x137')][_0x2fcb71('0x269a')],'license':_0x1d205a[_0x2fcb71('0x5c9')],'setting':_0x1d205a['setting'],'crudPermissions':_0x1d205a[_0x2fcb71('0x243c')]}});}function _0x35518a(_0x1e57bd){const _0x159bae=_0x5cd8c1;_0x439e77['sound']['delete']({'id':_0x1e57bd['id']})[_0x159bae('0xa44')][_0x159bae('0x1166')](function(){const _0x2a401b=_0x159bae;_0x2cfb05()[_0x2a401b('0x127f')](_0x1d205a[_0x2a401b('0x137')][_0x2a401b('0x269a')],{'id':_0x1e57bd['id']}),_0x1d205a['sounds']['count']-=0x1,!_0x1d205a[_0x2a401b('0x137')][_0x2a401b('0x269a')][_0x2a401b('0x264b')]&&_0x1d205a['getSounds'](),_0x38efc0[_0x2a401b('0x103b')]({'title':_0x2cfb05()[_0x2a401b('0xb35')](_0x2a401b('0x1e67'))+_0x2a401b('0x2b6'),'msg':_0x1e57bd[_0x2a401b('0x4f0')]?_0x1e57bd[_0x2a401b('0x4f0')]+_0x2a401b('0x7cd'):''});})[_0x159bae('0x1a80')](function(_0x37f8f1){const _0x1602a0=_0x159bae;if(_0x37f8f1[_0x1602a0('0x25f4')]&&_0x37f8f1[_0x1602a0('0x25f4')][_0x1602a0('0x61a')]&&_0x37f8f1[_0x1602a0('0x25f4')]['errors'][_0x1602a0('0x264b')]){_0x1d205a[_0x1602a0('0x61a')]=_0x37f8f1[_0x1602a0('0x25f4')]['errors']||[{'message':_0x37f8f1[_0x1602a0('0x1586')](),'type':_0x1602a0('0x2611')}];for(let _0x479a64=0x0;_0x479a64<_0x37f8f1[_0x1602a0('0x25f4')][_0x1602a0('0x61a')]['length'];_0x479a64++){_0x38efc0[_0x1602a0('0xfc9')]({'title':_0x37f8f1[_0x1602a0('0x25f4')]['errors'][_0x479a64][_0x1602a0('0x1345')],'msg':_0x37f8f1[_0x1602a0('0x25f4')][_0x1602a0('0x61a')][_0x479a64][_0x1602a0('0x1e70')]});}}else _0x38efc0[_0x1602a0('0xfc9')]({'title':_0x37f8f1[_0x1602a0('0x52d')]?_0x1602a0('0x1e21')+_0x37f8f1['status']+'\x20-\x20'+_0x37f8f1[_0x1602a0('0xe1b')]:_0x1602a0('0x2611'),'msg':_0x37f8f1[_0x1602a0('0x25f4')]?JSON[_0x1602a0('0xbac')](_0x37f8f1[_0x1602a0('0x25f4')]['message']):_0x37f8f1['message']||_0x37f8f1[_0x1602a0('0x1586')]()});});}function _0x3e3e1d(){const _0x1d19ec=_0x5cd8c1,_0x440013=angular[_0x1d19ec('0x225f')](_0x1d205a['selectedSounds']);return _0x1d205a['selectedSounds']=[],_0x440013;}function _0x15b45d(_0x4d4770){const _0x31bfee=_0x5cd8c1,_0x59072c=_0x4629ee[_0x31bfee('0x1d26')]()[_0x31bfee('0xcdc')](_0x31bfee('0x17b2'))[_0x31bfee('0xf3c')](_0x31bfee('0x12b5')+_0x1d205a[_0x31bfee('0x27df')][_0x31bfee('0x264b')]+_0x31bfee('0x196d')+_0x31bfee('0x3f3'))[_0x31bfee('0x8e8')]('delete\x20Sounds')[_0x31bfee('0x203b')](_0x4d4770)['ok']('OK')[_0x31bfee('0x3f')](_0x31bfee('0x2d3'));_0x4629ee[_0x31bfee('0x1f80')](_0x59072c)[_0x31bfee('0x1166')](function(){const _0x11a1e0=_0x31bfee;_0x1d205a['selectedSounds'][_0x11a1e0('0x2782')](function(_0x13d986){_0x35518a(_0x13d986);}),_0x1d205a['selectedSounds']=[];});}function _0x4d559d(){_0x1d205a['selectedSounds']=[];}function _0x27cb08(){const _0x4bde51=_0x5cd8c1;_0x1d205a[_0x4bde51('0x27df')]=_0x1d205a[_0x4bde51('0x137')][_0x4bde51('0x269a')];}function _0x4ba933(_0x5125f0){const _0x16e251=_0x5cd8c1;_0x4629ee['show']({'controller':_0x16e251('0x1a72'),'controllerAs':'vm','templateUrl':_0x51e770,'parent':angular['element'](_0x6239a2[_0x16e251('0x8d2')]),'targetEvent':_0x5125f0,'clickOutsideToClose':!![],'locals':{'sounds':_0x1d205a[_0x16e251('0x137')][_0x16e251('0x269a')]}});}}const _0x3b87f3=_0x54eaeb;_0x2fc94a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x265d'),'toasty',_0x36e6f4('0x137'),'api','Auth'];function _0x2fc94a(_0x4661f,_0x3748ab,_0x42c2d0,_0x59fbc1,_0x26b935,_0x3a67e5){const _0x4ee805=_0x36e6f4,_0x12a75a=this,_0x1bdb5d=0xf,_0x4446a1=_0x1bdb5d*0x400*0x400;_0x12a75a[_0x4ee805('0x98')]=_0x3a67e5['getCurrentUser'](),_0x12a75a[_0x4ee805('0x61a')]=[],_0x12a75a[_0x4ee805('0xcdc')]=_0x4ee805('0x2058'),_0x12a75a[_0x4ee805('0x137')]=_0x59fbc1,_0x12a75a[_0x4ee805('0xb23')]=[],_0x12a75a[_0x4ee805('0x279a')]=_0x4ee805('0x192'),_0x12a75a[_0x4ee805('0x960')]={},_0x12a75a[_0x4ee805('0xd67')]={'maxChunkRetries':0x1,'chunkSize':_0x4446a1,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![],'target':_0x4ee805('0x1fc3')},_0x12a75a[_0x4ee805('0xe57')]={'flow':{}},_0x12a75a[_0x4ee805('0x1a5c')]=![],_0x12a75a[_0x4ee805('0xd20')]=_0x19109b,_0x12a75a[_0x4ee805('0x1d40')]=_0x16faec,_0x12a75a['fileSuccess']=_0x166694,_0x12a75a[_0x4ee805('0x22a6')]=_0x584b63,_0x12a75a[_0x4ee805('0x14c2')]=_0x448525,_0x12a75a[_0x4ee805('0x24a0')]=_0x1726c2;function _0x19109b(_0x483052){const _0x489142=_0x4ee805,_0x4b85be=[_0x489142('0xdef'),'mp3',_0x489142('0x1cd9')];if(!_0x2cfb05()[_0x489142('0x1257')](_0x4b85be,_0x483052[_0x489142('0x26a5')]()))return _0x42c2d0[_0x489142('0xfc9')]({'title':_0x489142('0x27fb')+_0x483052['getExtension'](),'msg':_0x489142('0x1020')+_0x4b85be[_0x489142('0x45a')]()}),![];if(_0x483052[_0x489142('0x2340')]>_0x4446a1)return _0x42c2d0[_0x489142('0xfc9')]({'title':'File\x20too\x20big','msg':'The\x20max\x20allowed\x20size\x20is\x20'+_0x1bdb5d+'MB'}),![];return _0x12a75a['sound']={'id':_0x483052['uniqueIdentifier'],'file':_0x483052},_0x12a75a['uploadSounds'][_0x489142('0x2450')](_0x12a75a[_0x489142('0x960')]),!![];}function _0x16faec(){const _0x4ba4b3=_0x4ee805;_0x12a75a[_0x4ba4b3('0x279a')]='uploading',_0x12a75a[_0x4ba4b3('0xe57')][_0x4ba4b3('0x13d1')][_0x4ba4b3('0x1ca3')][_0x4ba4b3('0x5fb')]={'X-Requested-With':_0x4ba4b3('0x1bc1'),'Authorization':_0x4ba4b3('0x24d4')+_0x4661f[_0x4ba4b3('0xd83')](_0x4ba4b3('0x10b6'))},_0x12a75a[_0x4ba4b3('0xe57')][_0x4ba4b3('0x13d1')]['opts'][_0x4ba4b3('0x2218')]={'role':_0x12a75a['currentUser'][_0x4ba4b3('0x1e75')],'userProfileId':_0x12a75a[_0x4ba4b3('0x98')][_0x4ba4b3('0xb86')]},_0x12a75a[_0x4ba4b3('0xe57')]['flow']['upload']();}function _0x166694(_0x35043a,_0x186a20){const _0x1693ac=_0x4ee805;_0x12a75a['sounds'][_0x1693ac('0x2450')](JSON[_0x1693ac('0x1295')](_0x186a20)),angular['forEach'](_0x12a75a[_0x1693ac('0xb23')],function(_0x4e6515){const _0x4f8189=_0x1693ac;if(_0x4e6515['id']===_0x35043a[_0x4f8189('0x20f4')]){const _0x512153=new FileReader();_0x512153[_0x4f8189('0x2030')](_0x4e6515[_0x4f8189('0x6bd')][_0x4f8189('0x6bd')]),_0x512153[_0x4f8189('0x15d4')]=function(_0x321402){const _0x446909=_0x4f8189;_0x4e6515[_0x446909('0xcac')]=_0x321402[_0x446909('0x21cc')]['result'];};}});}function _0x584b63(){const _0x1a7156=_0x4ee805;_0x12a75a['ngFlow']['flow'][_0x1a7156('0x3f')](),_0x42c2d0[_0x1a7156('0xfc9')]({'title':_0x1a7156('0x2129'),'msg':_0x1a7156('0x980')}),_0x12a75a[_0x1a7156('0x279a')]=_0x1a7156('0x1140');}function _0x448525(){const _0x395c0b=_0x4ee805;_0x12a75a[_0x395c0b('0x279a')]!==_0x395c0b('0x1140')&&(_0x12a75a[_0x395c0b('0x279a')]=_0x395c0b('0x280a'),_0x42c2d0['success']({'title':'Upload\x20completed','msg':_0x12a75a[_0x395c0b('0x960')][_0x395c0b('0x6bd')][_0x395c0b('0x4f0')]+_0x395c0b('0xe73')}));}function _0x1726c2(){_0x3748ab['hide']();}}const _0x3e1d75=_0x2fc94a;_0x3cf107[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q','$translate',_0x36e6f4('0x1d2e'),'tags','tag','api','Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x3cf107(_0x182901,_0x56a68d,_0x2fef47,_0x46cd94,_0x34ee2b,_0x131b6c,_0x515458,_0x210a82,_0x482985,_0x38496e,_0x1fcd56,_0x2fd1e4,_0x5e9ae1,_0x547802){const _0x57dc16=_0x36e6f4,_0xcf6f8a=this;_0xcf6f8a['currentUser']=_0x1fcd56[_0x57dc16('0x26cd')](),_0xcf6f8a['errors']=[],_0xcf6f8a[_0x57dc16('0xf8a')]=_0x5e9ae1,_0xcf6f8a[_0x57dc16('0x5c9')]=_0x2fd1e4,_0xcf6f8a[_0x57dc16('0x243c')]=_0x547802,_0xcf6f8a['hasModulePermissions']={},_0xcf6f8a[_0x57dc16('0x2900')]=_0xcf6f8a[_0x57dc16('0xf8a')]&&_0xcf6f8a[_0x57dc16('0xf8a')][_0x57dc16('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xcf6f8a[_0x57dc16('0xcdc')]='TOOLS.EDIT_TAG',_0xcf6f8a[_0x57dc16('0x1446')]=angular[_0x57dc16('0x225f')](_0x482985),_0xcf6f8a[_0x57dc16('0xb38')]=_0x210a82,_0xcf6f8a['newTag']=![];!_0xcf6f8a[_0x57dc16('0x1446')]&&(_0xcf6f8a[_0x57dc16('0x1446')]={},_0xcf6f8a[_0x57dc16('0xcdc')]=_0x57dc16('0x1129'),_0xcf6f8a[_0x57dc16('0xe54')]=!![]);_0xcf6f8a['addNewTag']=_0x7d1175,_0xcf6f8a[_0x57dc16('0x1da6')]=_0x340bf2,_0xcf6f8a[_0x57dc16('0x289c')]=_0x43f805,_0xcf6f8a[_0x57dc16('0x1a9c')]=_0x5c60ac,_0xcf6f8a[_0x57dc16('0x24a0')]=_0xcb982f;function _0x7d1175(){const _0xf6ef9b=_0x57dc16;_0xcf6f8a[_0xf6ef9b('0x61a')]=[],_0x38496e[_0xf6ef9b('0x1446')][_0xf6ef9b('0x9cc')](_0xcf6f8a[_0xf6ef9b('0x1446')])[_0xf6ef9b('0xa44')][_0xf6ef9b('0x1166')](function(_0x3b297a){const _0x1c416f=_0xf6ef9b;_0xcf6f8a[_0x1c416f('0xb38')]['unshift'](_0x3b297a[_0x1c416f('0x2876')]()),_0x515458[_0x1c416f('0x103b')]({'title':_0x1c416f('0x1da2'),'msg':_0xcf6f8a[_0x1c416f('0x1446')][_0x1c416f('0x4f0')]?_0xcf6f8a[_0x1c416f('0x1446')][_0x1c416f('0x4f0')]+_0x1c416f('0x1eda'):''}),_0xcb982f(_0x3b297a);})[_0xf6ef9b('0x1a80')](function(_0x422c41){const _0x4705dd=_0xf6ef9b;if(_0x422c41[_0x4705dd('0x25f4')]&&_0x422c41[_0x4705dd('0x25f4')][_0x4705dd('0x61a')]&&_0x422c41[_0x4705dd('0x25f4')][_0x4705dd('0x61a')]['length']){_0xcf6f8a[_0x4705dd('0x61a')]=_0x422c41[_0x4705dd('0x25f4')][_0x4705dd('0x61a')]||[{'message':_0x422c41[_0x4705dd('0x1586')](),'type':'api.tag.save'}];for(let _0x45a40f=0x0;_0x45a40f<_0x422c41[_0x4705dd('0x25f4')][_0x4705dd('0x61a')]['length'];_0x45a40f+=0x1){_0x515458[_0x4705dd('0xfc9')]({'title':_0x422c41[_0x4705dd('0x25f4')][_0x4705dd('0x61a')][_0x45a40f][_0x4705dd('0x1345')],'msg':_0x422c41['data'][_0x4705dd('0x61a')][_0x45a40f][_0x4705dd('0x1e70')]});}}else _0x515458['error']({'title':_0x422c41[_0x4705dd('0x52d')]?'API:'+_0x422c41['status']+'\x20-\x20'+_0x422c41['statusText']:_0x4705dd('0x2153'),'msg':_0x422c41['data']?JSON['stringify'](_0x422c41['data'][_0x4705dd('0x1e70')]):_0x422c41['toString']()});});}function _0x340bf2(){const _0x10d613=_0x57dc16;_0xcf6f8a[_0x10d613('0x61a')]=[],_0x38496e[_0x10d613('0x1446')][_0x10d613('0x1449')]({'id':_0xcf6f8a[_0x10d613('0x1446')]['id']},_0xcf6f8a[_0x10d613('0x1446')])['$promise'][_0x10d613('0x1166')](function(_0x1b0794){const _0x4bf1e3=_0x10d613,_0x382677=_0x2cfb05()[_0x4bf1e3('0xc38')](_0xcf6f8a[_0x4bf1e3('0xb38')],{'id':_0x1b0794['id']});_0x382677&&_0x2cfb05()['merge'](_0x382677,_0x2cfb05()[_0x4bf1e3('0x1a08')](_0x1b0794[_0x4bf1e3('0x2876')](),_0x2cfb05()['keys'](_0x382677))),_0x515458['success']({'title':_0x4bf1e3('0x351'),'msg':_0xcf6f8a['tag'][_0x4bf1e3('0x4f0')]?_0xcf6f8a[_0x4bf1e3('0x1446')][_0x4bf1e3('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0xcb982f(_0x1b0794);})['catch'](function(_0x57cf03){const _0x3bf8a9=_0x10d613;if(_0x57cf03['data']&&_0x57cf03[_0x3bf8a9('0x25f4')]['errors']&&_0x57cf03[_0x3bf8a9('0x25f4')][_0x3bf8a9('0x61a')][_0x3bf8a9('0x264b')]){_0xcf6f8a[_0x3bf8a9('0x61a')]=_0x57cf03[_0x3bf8a9('0x25f4')][_0x3bf8a9('0x61a')]||[{'message':_0x57cf03['toString'](),'type':_0x3bf8a9('0x1ae7')}];for(let _0x6a8b91=0x0;_0x6a8b91<_0x57cf03[_0x3bf8a9('0x25f4')][_0x3bf8a9('0x61a')][_0x3bf8a9('0x264b')];_0x6a8b91++){_0x515458['error']({'title':_0x57cf03[_0x3bf8a9('0x25f4')]['errors'][_0x6a8b91][_0x3bf8a9('0x1345')],'msg':_0x57cf03[_0x3bf8a9('0x25f4')][_0x3bf8a9('0x61a')][_0x6a8b91][_0x3bf8a9('0x1e70')]});}}else _0x515458['error']({'title':_0x57cf03[_0x3bf8a9('0x52d')]?'API:'+_0x57cf03[_0x3bf8a9('0x52d')]+_0x3bf8a9('0x11e1')+_0x57cf03[_0x3bf8a9('0xe1b')]:'api.tag.update','msg':_0x57cf03[_0x3bf8a9('0x25f4')]?JSON[_0x3bf8a9('0xbac')](_0x57cf03[_0x3bf8a9('0x25f4')][_0x3bf8a9('0x1e70')]):_0x57cf03[_0x3bf8a9('0x1586')]()});});}function _0x43f805(_0x37ca8a){const _0x29375a=_0x57dc16;_0xcf6f8a[_0x29375a('0x61a')]=[];const _0x184c71=_0x46cd94[_0x29375a('0x1d26')]()[_0x29375a('0xcdc')](_0x29375a('0x7fb'))[_0x29375a('0xacc')](_0x29375a('0x19d9'))[_0x29375a('0x8e8')](_0x29375a('0x53b'))['ok'](_0x29375a('0x18'))[_0x29375a('0x3f')](_0x29375a('0x497'))[_0x29375a('0x203b')](_0x37ca8a);_0x46cd94[_0x29375a('0x1f80')](_0x184c71)[_0x29375a('0x1166')](function(){const _0x23b54b=_0x29375a;_0x38496e['tag'][_0x23b54b('0x906')]({'id':_0xcf6f8a[_0x23b54b('0x1446')]['id']})[_0x23b54b('0xa44')][_0x23b54b('0x1166')](function(){const _0x1340dc=_0x23b54b;_0x2cfb05()['remove'](_0xcf6f8a[_0x1340dc('0xb38')],{'id':_0xcf6f8a[_0x1340dc('0x1446')]['id']}),_0x515458[_0x1340dc('0x103b')]({'title':_0x1340dc('0x110e'),'msg':(_0xcf6f8a[_0x1340dc('0x1446')]['name']||_0x1340dc('0x1446'))+'\x20has\x20been\x20deleted!'}),_0xcb982f(_0xcf6f8a[_0x1340dc('0x1446')]);})[_0x23b54b('0x1a80')](function(_0x3a31b2){const _0x4c385d=_0x23b54b;if(_0x3a31b2['data']&&_0x3a31b2['data'][_0x4c385d('0x61a')]&&_0x3a31b2[_0x4c385d('0x25f4')][_0x4c385d('0x61a')][_0x4c385d('0x264b')]){_0xcf6f8a[_0x4c385d('0x61a')]=_0x3a31b2[_0x4c385d('0x25f4')][_0x4c385d('0x61a')]||[{'message':_0x3a31b2[_0x4c385d('0x1586')](),'type':_0x4c385d('0xf8f')}];for(let _0x42e87e=0x0;_0x42e87e<_0x3a31b2[_0x4c385d('0x25f4')][_0x4c385d('0x61a')][_0x4c385d('0x264b')];_0x42e87e++){_0x515458[_0x4c385d('0xfc9')]({'title':_0x3a31b2[_0x4c385d('0x25f4')][_0x4c385d('0x61a')][_0x42e87e][_0x4c385d('0x1345')],'msg':_0x3a31b2[_0x4c385d('0x25f4')]['errors'][_0x42e87e][_0x4c385d('0x1e70')]});}}else _0x515458[_0x4c385d('0xfc9')]({'title':_0x3a31b2[_0x4c385d('0x52d')]?_0x4c385d('0x1e21')+_0x3a31b2[_0x4c385d('0x52d')]+_0x4c385d('0x11e1')+_0x3a31b2[_0x4c385d('0xe1b')]:_0x4c385d('0xf8f'),'msg':_0x3a31b2[_0x4c385d('0x25f4')]?JSON['stringify'](_0x3a31b2[_0x4c385d('0x25f4')][_0x4c385d('0x1e70')]):_0x3a31b2[_0x4c385d('0x1e70')]||_0x3a31b2[_0x4c385d('0x1586')]()});});},function(){});}function _0x5c60ac(_0x537782){return _0x537782===null?undefined:new Date(_0x537782);}function _0xcb982f(_0x38eac0){_0x46cd94['hide'](_0x38eac0);}}const _0x3e87c5=_0x3cf107,_0x328e56=_0x2734b2['p']+'src/js/modules/main/apps/tools/views/tags/create/dialog.html/dialog.html';_0x59e317['$inject']=[_0x36e6f4('0x36f'),'$window',_0x36e6f4('0x7b9'),'$mdSidenav',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0xb38'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'license','setting'];function _0x59e317(_0x209f34,_0x29138a,_0x5ea8b3,_0x47afb,_0x35db86,_0x59fd90,_0x39ef1f,_0x448513,_0x2e03db,_0x52381e,_0x3f6272,_0x35bae5,_0x5a13f7,_0x9ed123,_0x529f58,_0x427da4,_0x1729b3){const _0x3acf90=_0x36e6f4,_0x13c29c=this;_0x13c29c[_0x3acf90('0x5c9')]=_0x427da4,_0x13c29c['setting']=_0x1729b3,_0x13c29c[_0x3acf90('0x98')]=_0x529f58[_0x3acf90('0x26cd')](),_0x13c29c[_0x3acf90('0xb38')]=_0x2e03db||{'count':0x0,'rows':[]},_0x13c29c[_0x3acf90('0x7f')]=_0x52381e,_0x13c29c[_0x3acf90('0x17aa')]=_0x3f6272&&_0x3f6272[_0x3acf90('0x240f')]==0x1?_0x3f6272[_0x3acf90('0x269a')][0x0]:null,_0x13c29c[_0x3acf90('0x243c')]=_0x529f58[_0x3acf90('0xd87')](_0x13c29c[_0x3acf90('0x17aa')]?_0x13c29c[_0x3acf90('0x17aa')]['crudPermissions']:null),_0x13c29c[_0x3acf90('0x916')]=_0x3acf90('0xb38'),_0x13c29c[_0x3acf90('0xef5')]='',_0x13c29c[_0x3acf90('0x104c')]=null,_0x13c29c[_0x3acf90('0x1726')]=[],_0x13c29c[_0x3acf90('0x2218')]={'fields':_0x3acf90('0xb26'),'sort':_0x3acf90('0x14dc'),'limit':0xa,'page':0x1},_0x13c29c['editdialog']=_0x309515,_0x13c29c[_0x3acf90('0x8d8')]=_0x4584f8,_0x13c29c[_0x3acf90('0x103b')]=_0x3f7cc8,_0x13c29c[_0x3acf90('0x1524')]=_0x4151a6,_0x13c29c[_0x3acf90('0x1be')]=_0x1b09af,_0x13c29c[_0x3acf90('0x289c')]=_0x4b80ff,_0x13c29c[_0x3acf90('0xb90')]=_0x4035d7,_0x13c29c[_0x3acf90('0x14')]=_0x546b5d,_0x13c29c['deselectTags']=_0x323665,_0x13c29c[_0x3acf90('0x3fd')]=_0x2c19e1;function _0x309515(_0x40bbbe,_0x2d687e){const _0x4f0a95=_0x3acf90;_0x35db86[_0x4f0a95('0x1f80')]({'controller':'CreateOrEditTagDialogController','controllerAs':'vm','templateUrl':_0x328e56,'parent':angular[_0x4f0a95('0x1194')](_0x59fd90['body']),'targetEvent':_0x2d687e,'clickOutsideToClose':!![],'locals':{'tag':_0x40bbbe,'tags':_0x13c29c[_0x4f0a95('0xb38')][_0x4f0a95('0x269a')],'license':_0x13c29c[_0x4f0a95('0x5c9')],'setting':null,'crudPermissions':_0x13c29c[_0x4f0a95('0x243c')]}});}function _0x4584f8(_0x276b17,_0x34e741){const _0x53a73=_0x3acf90,_0x23489c=_0x35db86[_0x53a73('0x1d26')]()[_0x53a73('0xcdc')](_0x53a73('0x288d')+_0x2cfb05()['startCase']('tag')+'?')[_0x53a73('0xf3c')](_0x53a73('0x12b5')+(_0x276b17['name']||_0x53a73('0x1446'))+_0x53a73('0xace')+_0x53a73('0x3f3'))[_0x53a73('0x8e8')]('delete\x20tag')['targetEvent'](_0x34e741)['ok']('OK')[_0x53a73('0x3f')](_0x53a73('0x2d3'));_0x35db86['show'](_0x23489c)[_0x53a73('0x1166')](function(){_0x4b80ff(_0x276b17);},function(){const _0x162aec=_0x53a73;console['log'](_0x162aec('0x2d3'));});}let _0x20a10f=!![],_0x56acb4=0x1;_0x209f34[_0x3acf90('0xe83')]('vm.query.filter',function(_0x249817,_0x15f243){const _0x3ce71a=_0x3acf90;_0x20a10f?_0x39ef1f(function(){_0x20a10f=![];}):(!_0x15f243&&(_0x56acb4=_0x13c29c['query'][_0x3ce71a('0x1a43')]),_0x249817!==_0x15f243&&(_0x13c29c[_0x3ce71a('0x2218')][_0x3ce71a('0x1a43')]=0x1),!_0x249817&&(_0x13c29c[_0x3ce71a('0x2218')][_0x3ce71a('0x1a43')]=_0x56acb4),_0x13c29c[_0x3ce71a('0x1524')]());});function _0x3f7cc8(_0x565608){const _0x6e1ada=_0x3acf90;_0x13c29c[_0x6e1ada('0xb38')]=_0x565608||{'count':0x0,'rows':[]};}function _0x4151a6(){const _0x5126f7=_0x3acf90;_0x13c29c[_0x5126f7('0x2218')][_0x5126f7('0x1098')]=(_0x13c29c[_0x5126f7('0x2218')][_0x5126f7('0x1a43')]-0x1)*_0x13c29c[_0x5126f7('0x2218')][_0x5126f7('0x163f')],_0x529f58[_0x5126f7('0x1ac6')](_0x5126f7('0xa7c'))?_0x13c29c[_0x5126f7('0x1f48')]=_0x35bae5[_0x5126f7('0x1446')][_0x5126f7('0xd83')](_0x13c29c[_0x5126f7('0x2218')],_0x3f7cc8)[_0x5126f7('0xa44')]:(_0x13c29c[_0x5126f7('0x2218')]['id']=_0x13c29c[_0x5126f7('0x7f')]['id'],_0x13c29c[_0x5126f7('0x2218')][_0x5126f7('0xe60')]=_0x5126f7('0x21c2'),_0x13c29c[_0x5126f7('0x1f48')]=_0x35bae5[_0x5126f7('0x7f')][_0x5126f7('0x263a')](_0x13c29c[_0x5126f7('0x2218')],_0x3f7cc8)['$promise']);}function _0x1b09af(_0x40d87c,_0x263f4e){const _0x13fcb1=_0x3acf90;_0x35db86[_0x13fcb1('0x1f80')]({'controller':'CreateOrEditTagDialogController','controllerAs':'vm','templateUrl':_0x328e56,'parent':angular[_0x13fcb1('0x1194')](_0x59fd90[_0x13fcb1('0x8d2')]),'targetEvent':_0x40d87c,'clickOutsideToClose':!![],'locals':{'tag':_0x263f4e,'tags':_0x13c29c[_0x13fcb1('0xb38')]['rows'],'license':_0x13c29c[_0x13fcb1('0x5c9')],'setting':_0x13c29c['setting'],'crudPermissions':_0x13c29c[_0x13fcb1('0x243c')]}});}function _0x4b80ff(_0x3a30f9){const _0x834e19=_0x3acf90;_0x35bae5[_0x834e19('0x1446')]['delete']({'id':_0x3a30f9['id']})[_0x834e19('0xa44')][_0x834e19('0x1166')](function(){const _0x43fbf1=_0x834e19;_0x2cfb05()[_0x43fbf1('0x127f')](_0x13c29c['tags']['rows'],{'id':_0x3a30f9['id']}),_0x13c29c[_0x43fbf1('0xb38')]['count']-=0x1,!_0x13c29c[_0x43fbf1('0xb38')][_0x43fbf1('0x269a')][_0x43fbf1('0x264b')]&&_0x13c29c[_0x43fbf1('0x1524')](),_0x9ed123['success']({'title':_0x2cfb05()[_0x43fbf1('0xb35')]('Tag')+'\x20deleted!','msg':_0x3a30f9[_0x43fbf1('0x4f0')]?_0x3a30f9[_0x43fbf1('0x4f0')]+_0x43fbf1('0x7cd'):''});})['catch'](function(_0x3f1e2c){const _0x1874a3=_0x834e19;if(_0x3f1e2c['data']&&_0x3f1e2c[_0x1874a3('0x25f4')]['errors']&&_0x3f1e2c['data'][_0x1874a3('0x61a')]['length']){_0x13c29c[_0x1874a3('0x61a')]=_0x3f1e2c['data'][_0x1874a3('0x61a')]||[{'message':_0x3f1e2c['toString'](),'type':_0x1874a3('0x23ec')}];for(let _0x3a6cda=0x0;_0x3a6cda<_0x3f1e2c['data']['errors'][_0x1874a3('0x264b')];_0x3a6cda++){_0x9ed123[_0x1874a3('0xfc9')]({'title':_0x3f1e2c[_0x1874a3('0x25f4')][_0x1874a3('0x61a')][_0x3a6cda][_0x1874a3('0x1345')],'msg':_0x3f1e2c[_0x1874a3('0x25f4')]['errors'][_0x3a6cda][_0x1874a3('0x1e70')]});}}else _0x9ed123['error']({'title':_0x3f1e2c[_0x1874a3('0x52d')]?_0x1874a3('0x1e21')+_0x3f1e2c['status']+'\x20-\x20'+_0x3f1e2c[_0x1874a3('0xe1b')]:_0x1874a3('0x23ec'),'msg':_0x3f1e2c[_0x1874a3('0x25f4')]?JSON[_0x1874a3('0xbac')](_0x3f1e2c[_0x1874a3('0x25f4')][_0x1874a3('0x1e70')]):_0x3f1e2c['message']||_0x3f1e2c[_0x1874a3('0x1586')]()});});}function _0x4035d7(){const _0x313563=_0x3acf90,_0x2f3c8f=angular['copy'](_0x13c29c[_0x313563('0x1726')]);return _0x13c29c[_0x313563('0x1726')]=[],_0x2f3c8f;}function _0x546b5d(_0x5cb37b){const _0x404010=_0x3acf90,_0x495c35=_0x35db86[_0x404010('0x1d26')]()[_0x404010('0xcdc')](_0x404010('0xc2d'))['htmlContent'](_0x404010('0x12b5')+_0x13c29c[_0x404010('0x1726')]['length']+'\x20selected'+_0x404010('0x3f3'))[_0x404010('0x8e8')](_0x404010('0x2174'))[_0x404010('0x203b')](_0x5cb37b)['ok']('OK')['cancel']('CANCEL');_0x35db86[_0x404010('0x1f80')](_0x495c35)[_0x404010('0x1166')](function(){const _0x26223f=_0x404010;_0x13c29c['selectedTags'][_0x26223f('0x2782')](function(_0x5bbbb0){_0x4b80ff(_0x5bbbb0);}),_0x13c29c[_0x26223f('0x1726')]=[];});}function _0x323665(){const _0x35b2bc=_0x3acf90;_0x13c29c[_0x35b2bc('0x1726')]=[];}function _0x2c19e1(){const _0x52974e=_0x3acf90;_0x13c29c[_0x52974e('0x1726')]=_0x13c29c['tags'][_0x52974e('0x269a')];}}const _0xe59a7e=_0x59e317;_0x52d91a['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x12d0'),_0x36e6f4('0x243'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x52d91a(_0x5e8209,_0x24f661,_0x5ac271,_0x1035e9,_0x402505,_0x4e6bab,_0x344b55,_0x37d294,_0x40d008,_0x56b763,_0x13725e,_0x242c93,_0x597501,_0x9433a9){const _0x277937=_0x36e6f4,_0x16e4f1=this;_0x16e4f1[_0x277937('0x98')]=_0x13725e[_0x277937('0x26cd')](),_0x16e4f1[_0x277937('0x61a')]=[],_0x16e4f1[_0x277937('0xf8a')]=_0x597501,_0x16e4f1[_0x277937('0x5c9')]=_0x242c93,_0x16e4f1[_0x277937('0x243c')]=_0x9433a9,_0x16e4f1[_0x277937('0x128b')]={},_0x16e4f1['passwordPattern']=_0x16e4f1['setting']&&_0x16e4f1[_0x277937('0xf8a')][_0x277937('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x16e4f1[_0x277937('0xcdc')]=_0x277937('0x12ed'),_0x16e4f1[_0x277937('0x243')]=angular['copy'](_0x40d008),_0x16e4f1[_0x277937('0x12d0')]=_0x37d294,_0x16e4f1[_0x277937('0x1117')]=![];!_0x16e4f1[_0x277937('0x243')]&&(_0x16e4f1[_0x277937('0x243')]={},_0x16e4f1['title']='TOOLS.NEW_TEMPLATE',_0x16e4f1[_0x277937('0x1117')]=!![]);_0x16e4f1['addNewTemplate']=_0x591c72,_0x16e4f1[_0x277937('0x1589')]=_0x1777f9,_0x16e4f1[_0x277937('0x2c5')]=_0x2b4f81,_0x16e4f1[_0x277937('0x1a9c')]=_0x593836,_0x16e4f1['closeDialog']=_0x37c886;function _0x591c72(){const _0x396baf=_0x277937;_0x16e4f1[_0x396baf('0x61a')]=[],_0x56b763[_0x396baf('0x243')][_0x396baf('0x9cc')](_0x16e4f1[_0x396baf('0x243')])[_0x396baf('0xa44')]['then'](function(_0x3df30b){const _0x39060d=_0x396baf;_0x16e4f1[_0x39060d('0x12d0')]['unshift'](_0x3df30b[_0x39060d('0x2876')]()),_0x344b55[_0x39060d('0x103b')]({'title':_0x39060d('0x22f2'),'msg':_0x16e4f1['template'][_0x39060d('0x4f0')]?_0x16e4f1[_0x39060d('0x243')]['name']+_0x39060d('0x1eda'):''}),_0x37c886(_0x3df30b);})[_0x396baf('0x1a80')](function(_0x286e1b){const _0x3b72be=_0x396baf;if(_0x286e1b[_0x3b72be('0x25f4')]&&_0x286e1b[_0x3b72be('0x25f4')]['errors']&&_0x286e1b[_0x3b72be('0x25f4')][_0x3b72be('0x61a')][_0x3b72be('0x264b')]){_0x16e4f1[_0x3b72be('0x61a')]=_0x286e1b['data'][_0x3b72be('0x61a')]||[{'message':_0x286e1b['toString'](),'type':_0x3b72be('0xcf4')}];for(let _0x4e4c41=0x0;_0x4e4c41<_0x286e1b[_0x3b72be('0x25f4')]['errors'][_0x3b72be('0x264b')];_0x4e4c41+=0x1){_0x344b55[_0x3b72be('0xfc9')]({'title':_0x286e1b[_0x3b72be('0x25f4')][_0x3b72be('0x61a')][_0x4e4c41][_0x3b72be('0x1345')],'msg':_0x286e1b[_0x3b72be('0x25f4')]['errors'][_0x4e4c41][_0x3b72be('0x1e70')]});}}else _0x344b55[_0x3b72be('0xfc9')]({'title':_0x286e1b[_0x3b72be('0x52d')]?_0x3b72be('0x1e21')+_0x286e1b[_0x3b72be('0x52d')]+_0x3b72be('0x11e1')+_0x286e1b[_0x3b72be('0xe1b')]:'api.template.save','msg':_0x286e1b[_0x3b72be('0x25f4')]?JSON['stringify'](_0x286e1b[_0x3b72be('0x25f4')]['message']):_0x286e1b[_0x3b72be('0x1586')]()});});}function _0x1777f9(){const _0x289f62=_0x277937;_0x16e4f1[_0x289f62('0x61a')]=[],_0x56b763[_0x289f62('0x243')][_0x289f62('0x1449')]({'id':_0x16e4f1[_0x289f62('0x243')]['id']},_0x16e4f1[_0x289f62('0x243')])['$promise'][_0x289f62('0x1166')](function(_0x3afaed){const _0x1a9b61=_0x289f62,_0x15240d=_0x2cfb05()[_0x1a9b61('0xc38')](_0x16e4f1[_0x1a9b61('0x12d0')],{'id':_0x3afaed['id']});_0x15240d&&_0x2cfb05()[_0x1a9b61('0xcc3')](_0x15240d,_0x2cfb05()[_0x1a9b61('0x1a08')](_0x3afaed[_0x1a9b61('0x2876')](),_0x2cfb05()[_0x1a9b61('0x14a4')](_0x15240d))),_0x344b55[_0x1a9b61('0x103b')]({'title':_0x1a9b61('0x800'),'msg':_0x16e4f1['template'][_0x1a9b61('0x4f0')]?_0x16e4f1[_0x1a9b61('0x243')][_0x1a9b61('0x4f0')]+_0x1a9b61('0x7d'):''}),_0x37c886(_0x3afaed);})[_0x289f62('0x1a80')](function(_0x20840c){const _0x4bbe54=_0x289f62;if(_0x20840c['data']&&_0x20840c[_0x4bbe54('0x25f4')]['errors']&&_0x20840c[_0x4bbe54('0x25f4')]['errors']['length']){_0x16e4f1[_0x4bbe54('0x61a')]=_0x20840c[_0x4bbe54('0x25f4')][_0x4bbe54('0x61a')]||[{'message':_0x20840c[_0x4bbe54('0x1586')](),'type':_0x4bbe54('0x19dd')}];for(let _0x3a8dc6=0x0;_0x3a8dc6<_0x20840c[_0x4bbe54('0x25f4')][_0x4bbe54('0x61a')]['length'];_0x3a8dc6++){_0x344b55[_0x4bbe54('0xfc9')]({'title':_0x20840c['data']['errors'][_0x3a8dc6][_0x4bbe54('0x1345')],'msg':_0x20840c[_0x4bbe54('0x25f4')]['errors'][_0x3a8dc6]['message']});}}else _0x344b55[_0x4bbe54('0xfc9')]({'title':_0x20840c[_0x4bbe54('0x52d')]?_0x4bbe54('0x1e21')+_0x20840c[_0x4bbe54('0x52d')]+'\x20-\x20'+_0x20840c[_0x4bbe54('0xe1b')]:_0x4bbe54('0x19dd'),'msg':_0x20840c[_0x4bbe54('0x25f4')]?JSON[_0x4bbe54('0xbac')](_0x20840c[_0x4bbe54('0x25f4')]['message']):_0x20840c[_0x4bbe54('0x1586')]()});});}function _0x2b4f81(_0x1b2e86){const _0x4b9bfc=_0x277937;_0x16e4f1[_0x4b9bfc('0x61a')]=[];const _0xb228d2=_0x1035e9[_0x4b9bfc('0x1d26')]()[_0x4b9bfc('0xcdc')](_0x4b9bfc('0x7fb'))['content'](_0x4b9bfc('0x21db'))['ariaLabel'](_0x4b9bfc('0x245a'))['ok'](_0x4b9bfc('0x18'))[_0x4b9bfc('0x3f')]('Cancel')['targetEvent'](_0x1b2e86);_0x1035e9[_0x4b9bfc('0x1f80')](_0xb228d2)[_0x4b9bfc('0x1166')](function(){const _0x26917f=_0x4b9bfc;_0x56b763[_0x26917f('0x243')][_0x26917f('0x906')]({'id':_0x16e4f1['template']['id']})[_0x26917f('0xa44')][_0x26917f('0x1166')](function(){const _0x1a47e5=_0x26917f;_0x2cfb05()[_0x1a47e5('0x127f')](_0x16e4f1[_0x1a47e5('0x12d0')],{'id':_0x16e4f1[_0x1a47e5('0x243')]['id']}),_0x344b55[_0x1a47e5('0x103b')]({'title':'Template\x20properly\x20deleted!','msg':(_0x16e4f1[_0x1a47e5('0x243')][_0x1a47e5('0x4f0')]||_0x1a47e5('0x243'))+'\x20has\x20been\x20deleted!'}),_0x37c886(_0x16e4f1['template']);})['catch'](function(_0x5d5d9f){const _0x3a2f46=_0x26917f;if(_0x5d5d9f[_0x3a2f46('0x25f4')]&&_0x5d5d9f['data']['errors']&&_0x5d5d9f[_0x3a2f46('0x25f4')][_0x3a2f46('0x61a')][_0x3a2f46('0x264b')]){_0x16e4f1[_0x3a2f46('0x61a')]=_0x5d5d9f[_0x3a2f46('0x25f4')]['errors']||[{'message':_0x5d5d9f[_0x3a2f46('0x1586')](),'type':_0x3a2f46('0x1efb')}];for(let _0x3a57b9=0x0;_0x3a57b9<_0x5d5d9f[_0x3a2f46('0x25f4')][_0x3a2f46('0x61a')][_0x3a2f46('0x264b')];_0x3a57b9++){_0x344b55[_0x3a2f46('0xfc9')]({'title':_0x5d5d9f[_0x3a2f46('0x25f4')][_0x3a2f46('0x61a')][_0x3a57b9][_0x3a2f46('0x1345')],'msg':_0x5d5d9f['data']['errors'][_0x3a57b9]['message']});}}else _0x344b55[_0x3a2f46('0xfc9')]({'title':_0x5d5d9f[_0x3a2f46('0x52d')]?'API:'+_0x5d5d9f[_0x3a2f46('0x52d')]+'\x20-\x20'+_0x5d5d9f[_0x3a2f46('0xe1b')]:_0x3a2f46('0x1efb'),'msg':_0x5d5d9f['data']?JSON[_0x3a2f46('0xbac')](_0x5d5d9f['data'][_0x3a2f46('0x1e70')]):_0x5d5d9f[_0x3a2f46('0x1e70')]||_0x5d5d9f['toString']()});});},function(){});}function _0x593836(_0x3fa71c){return _0x3fa71c===null?undefined:new Date(_0x3fa71c);}function _0x37c886(_0x5e5b83){const _0x1da966=_0x277937;_0x1035e9[_0x1da966('0x1197')](_0x5e5b83);}}const _0x4c7132=_0x52d91a,_0x236cda=_0x2734b2['p']+_0x36e6f4('0x9c');_0x377ed5[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$window','$state',_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x12d0'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),'toasty','Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x377ed5(_0xd242c1,_0x2ed821,_0x5f110d,_0x329464,_0x4f5967,_0x3d4767,_0x18bfbc,_0x4c0ef9,_0x12bd78,_0x45d4d2,_0x20b946,_0x28e718,_0x5689fb,_0xe4b5c7,_0x2a5edf,_0x430aa4,_0x4d97d9){const _0x1cf9cb=_0x36e6f4,_0x376367=this;_0x376367[_0x1cf9cb('0x5c9')]=_0x430aa4,_0x376367[_0x1cf9cb('0xf8a')]=_0x4d97d9,_0x376367[_0x1cf9cb('0x98')]=_0x2a5edf[_0x1cf9cb('0x26cd')](),_0x376367['templates']=_0x12bd78||{'count':0x0,'rows':[]},_0x376367['userProfile']=_0x45d4d2,_0x376367[_0x1cf9cb('0x17aa')]=_0x20b946&&_0x20b946[_0x1cf9cb('0x240f')]==0x1?_0x20b946['rows'][0x0]:null,_0x376367[_0x1cf9cb('0x243c')]=_0x2a5edf[_0x1cf9cb('0xd87')](_0x376367[_0x1cf9cb('0x17aa')]?_0x376367['userProfileSection'][_0x1cf9cb('0x243c')]:null),_0x376367[_0x1cf9cb('0x916')]=_0x1cf9cb('0x12d0'),_0x376367[_0x1cf9cb('0xef5')]='',_0x376367['listOrderAsc']=null,_0x376367[_0x1cf9cb('0x191e')]=[],_0x376367['query']={'fields':'createdAt,updatedAt,id,name,html,description','sort':_0x1cf9cb('0x14dc'),'limit':0xa,'page':0x1},_0x376367[_0x1cf9cb('0x1f8e')]=_0x4c1fc6,_0x376367['deleteconfirm']=_0x486d20,_0x376367[_0x1cf9cb('0x103b')]=_0x587671,_0x376367[_0x1cf9cb('0x16a0')]=_0x1d3b0b,_0x376367[_0x1cf9cb('0x316')]=_0xfb8816,_0x376367['deleteTemplate']=_0x53b19c,_0x376367[_0x1cf9cb('0x8bb')]=_0x406f45,_0x376367[_0x1cf9cb('0x277')]=_0x5c2d79,_0x376367[_0x1cf9cb('0x24c7')]=_0x356b6f,_0x376367['selectAllTemplates']=_0xdd6cd6;function _0x4c1fc6(_0x3fd855,_0x5b7c1e){const _0x5c3153=_0x1cf9cb;_0x4f5967[_0x5c3153('0x1f80')]({'controller':_0x5c3153('0xe2d'),'controllerAs':'vm','templateUrl':_0x236cda,'parent':angular[_0x5c3153('0x1194')](_0x3d4767['body']),'targetEvent':_0x5b7c1e,'clickOutsideToClose':!![],'locals':{'template':_0x3fd855,'templates':_0x376367[_0x5c3153('0x12d0')]['rows'],'license':_0x376367[_0x5c3153('0x5c9')],'setting':null,'crudPermissions':_0x376367[_0x5c3153('0x243c')]}});}function _0x486d20(_0x3fb3c1,_0x5cc119){const _0x2692c3=_0x1cf9cb,_0x3ebe3e=_0x4f5967[_0x2692c3('0x1d26')]()['title'](_0x2692c3('0x288d')+_0x2cfb05()[_0x2692c3('0xb35')](_0x2692c3('0x243'))+'?')['htmlContent'](_0x2692c3('0x12b5')+(_0x3fb3c1[_0x2692c3('0x4f0')]||'template')+_0x2692c3('0xace')+'\x20will\x20be\x20deleted.')[_0x2692c3('0x8e8')]('delete\x20template')[_0x2692c3('0x203b')](_0x5cc119)['ok']('OK')['cancel']('CANCEL');_0x4f5967[_0x2692c3('0x1f80')](_0x3ebe3e)[_0x2692c3('0x1166')](function(){_0x53b19c(_0x3fb3c1);},function(){const _0x20f5a8=_0x2692c3;console[_0x20f5a8('0x455')](_0x20f5a8('0x2d3'));});}let _0x319b0a=!![],_0x2c7aeb=0x1;_0xd242c1[_0x1cf9cb('0xe83')](_0x1cf9cb('0x12d8'),function(_0x448c90,_0x315d72){const _0x35d967=_0x1cf9cb;_0x319b0a?_0x18bfbc(function(){_0x319b0a=![];}):(!_0x315d72&&(_0x2c7aeb=_0x376367[_0x35d967('0x2218')]['page']),_0x448c90!==_0x315d72&&(_0x376367[_0x35d967('0x2218')][_0x35d967('0x1a43')]=0x1),!_0x448c90&&(_0x376367[_0x35d967('0x2218')][_0x35d967('0x1a43')]=_0x2c7aeb),_0x376367['getTemplates']());});function _0x587671(_0x35c98b){_0x376367['templates']=_0x35c98b||{'count':0x0,'rows':[]};}function _0x1d3b0b(){const _0x3f6e95=_0x1cf9cb;_0x376367['query'][_0x3f6e95('0x1098')]=(_0x376367[_0x3f6e95('0x2218')]['page']-0x1)*_0x376367[_0x3f6e95('0x2218')]['limit'],_0x2a5edf[_0x3f6e95('0x1ac6')]('admin')?_0x376367[_0x3f6e95('0x1f48')]=_0x28e718[_0x3f6e95('0x243')][_0x3f6e95('0xd83')](_0x376367['query'],_0x587671)[_0x3f6e95('0xa44')]:(_0x376367['query']['id']=_0x376367['userProfile']['id'],_0x376367[_0x3f6e95('0x2218')][_0x3f6e95('0xe60')]=_0x3f6e95('0x9fd'),_0x376367[_0x3f6e95('0x1f48')]=_0x28e718[_0x3f6e95('0x7f')][_0x3f6e95('0x263a')](_0x376367[_0x3f6e95('0x2218')],_0x587671)[_0x3f6e95('0xa44')]);}function _0xfb8816(_0x1083a1,_0x12e4bf){const _0x5a6dbf=_0x1cf9cb;_0x4f5967[_0x5a6dbf('0x1f80')]({'controller':'CreateOrEditTemplateDialogController','controllerAs':'vm','templateUrl':_0x236cda,'parent':angular[_0x5a6dbf('0x1194')](_0x3d4767[_0x5a6dbf('0x8d2')]),'targetEvent':_0x1083a1,'clickOutsideToClose':!![],'locals':{'template':_0x12e4bf,'templates':_0x376367[_0x5a6dbf('0x12d0')][_0x5a6dbf('0x269a')],'license':_0x376367[_0x5a6dbf('0x5c9')],'setting':_0x376367[_0x5a6dbf('0xf8a')],'crudPermissions':_0x376367[_0x5a6dbf('0x243c')]}});}function _0x53b19c(_0x2a5108){const _0x456e82=_0x1cf9cb;_0x28e718[_0x456e82('0x243')][_0x456e82('0x906')]({'id':_0x2a5108['id']})['$promise'][_0x456e82('0x1166')](function(){const _0x3b25d9=_0x456e82;_0x2cfb05()[_0x3b25d9('0x127f')](_0x376367[_0x3b25d9('0x12d0')][_0x3b25d9('0x269a')],{'id':_0x2a5108['id']}),_0x376367[_0x3b25d9('0x12d0')]['count']-=0x1,!_0x376367[_0x3b25d9('0x12d0')][_0x3b25d9('0x269a')]['length']&&_0x376367[_0x3b25d9('0x16a0')](),_0xe4b5c7[_0x3b25d9('0x103b')]({'title':_0x2cfb05()['startCase'](_0x3b25d9('0x2814'))+_0x3b25d9('0x2b6'),'msg':_0x2a5108[_0x3b25d9('0x4f0')]?_0x2a5108['name']+_0x3b25d9('0x7cd'):''});})[_0x456e82('0x1a80')](function(_0x4c5262){const _0x26f7a2=_0x456e82;if(_0x4c5262[_0x26f7a2('0x25f4')]&&_0x4c5262[_0x26f7a2('0x25f4')][_0x26f7a2('0x61a')]&&_0x4c5262['data'][_0x26f7a2('0x61a')][_0x26f7a2('0x264b')]){_0x376367[_0x26f7a2('0x61a')]=_0x4c5262['data']['errors']||[{'message':_0x4c5262[_0x26f7a2('0x1586')](),'type':_0x26f7a2('0x1f10')}];for(let _0x4e5107=0x0;_0x4e5107<_0x4c5262[_0x26f7a2('0x25f4')][_0x26f7a2('0x61a')][_0x26f7a2('0x264b')];_0x4e5107++){_0xe4b5c7['error']({'title':_0x4c5262[_0x26f7a2('0x25f4')]['errors'][_0x4e5107]['type'],'msg':_0x4c5262[_0x26f7a2('0x25f4')][_0x26f7a2('0x61a')][_0x4e5107]['message']});}}else _0xe4b5c7[_0x26f7a2('0xfc9')]({'title':_0x4c5262[_0x26f7a2('0x52d')]?_0x26f7a2('0x1e21')+_0x4c5262[_0x26f7a2('0x52d')]+_0x26f7a2('0x11e1')+_0x4c5262[_0x26f7a2('0xe1b')]:'SYSTEM:DELETEtemplate','msg':_0x4c5262[_0x26f7a2('0x25f4')]?JSON[_0x26f7a2('0xbac')](_0x4c5262[_0x26f7a2('0x25f4')][_0x26f7a2('0x1e70')]):_0x4c5262['message']||_0x4c5262['toString']()});});}function _0x406f45(){const _0x476bd4=_0x1cf9cb,_0x1f500e=angular[_0x476bd4('0x225f')](_0x376367['selectedTemplates']);return _0x376367[_0x476bd4('0x191e')]=[],_0x1f500e;}function _0x5c2d79(_0x1a7848){const _0x3a2bcb=_0x1cf9cb,_0x3b207f=_0x4f5967['confirm']()['title'](_0x3a2bcb('0x47e'))[_0x3a2bcb('0xf3c')](_0x3a2bcb('0x12b5')+_0x376367[_0x3a2bcb('0x191e')][_0x3a2bcb('0x264b')]+_0x3a2bcb('0x196d')+_0x3a2bcb('0x3f3'))[_0x3a2bcb('0x8e8')](_0x3a2bcb('0x1e47'))[_0x3a2bcb('0x203b')](_0x1a7848)['ok']('OK')['cancel']('CANCEL');_0x4f5967[_0x3a2bcb('0x1f80')](_0x3b207f)['then'](function(){const _0x5f52db=_0x3a2bcb;_0x376367['selectedTemplates'][_0x5f52db('0x2782')](function(_0x2cf7f1){_0x53b19c(_0x2cf7f1);}),_0x376367[_0x5f52db('0x191e')]=[];});}function _0x356b6f(){const _0x5de0e2=_0x1cf9cb;_0x376367[_0x5de0e2('0x191e')]=[];}function _0xdd6cd6(){const _0x51aa15=_0x1cf9cb;_0x376367[_0x51aa15('0x191e')]=_0x376367[_0x51aa15('0x12d0')][_0x51aa15('0x269a')];}}const _0x505010=_0x377ed5;_0x3ac053[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0xf24'),_0x36e6f4('0x3b2'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'crudPermissions'];function _0x3ac053(_0x3bb5e1,_0x31cfe9,_0x51dae7,_0x1cf835,_0x19637b,_0x2f44b6,_0x2f8aed,_0x10504e,_0x1af392,_0x4e6c83,_0x1282f9,_0x1b1ec6,_0x1c9955,_0x35bc54){const _0x2f830d=_0x36e6f4,_0x5c5868=this;_0x5c5868[_0x2f830d('0x98')]=_0x1282f9[_0x2f830d('0x26cd')](),_0x5c5868[_0x2f830d('0x61a')]=[],_0x5c5868['setting']=_0x1c9955,_0x5c5868[_0x2f830d('0x5c9')]=_0x1b1ec6,_0x5c5868[_0x2f830d('0x243c')]=_0x35bc54,_0x5c5868[_0x2f830d('0x128b')]={},_0x5c5868[_0x2f830d('0x2900')]=_0x5c5868['setting']&&_0x5c5868[_0x2f830d('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5c5868[_0x2f830d('0xcdc')]=_0x2f830d('0x2847'),_0x5c5868[_0x2f830d('0x3b2')]=angular[_0x2f830d('0x225f')](_0x1af392),_0x5c5868[_0x2f830d('0xf24')]=_0x10504e,_0x5c5868[_0x2f830d('0x1d52')]=![];!_0x5c5868['trunk']&&(_0x5c5868['trunk']={'active':!![],'type':_0x2f830d('0x2549'),'dtmfmode':'rfc2833','qualify':_0x2f830d('0x55d'),'t38pt_udptl':'no'},_0x5c5868[_0x2f830d('0xcdc')]='TOOLS.NEW_TRUNK',_0x5c5868[_0x2f830d('0x1d52')]=!![]);_0x5c5868[_0x2f830d('0xf3a')]=_0x372650,_0x5c5868[_0x2f830d('0xb59')]=_0x511d1,_0x5c5868['deleteTrunk']=_0x11de9a,_0x5c5868[_0x2f830d('0x1a9c')]=_0xb3401f,_0x5c5868[_0x2f830d('0x24a0')]=_0x265953;function _0x372650(){const _0x4b0a2d=_0x2f830d;_0x5c5868[_0x4b0a2d('0x61a')]=[],_0x4e6c83[_0x4b0a2d('0x3b2')][_0x4b0a2d('0x9cc')](_0x5c5868[_0x4b0a2d('0x3b2')])[_0x4b0a2d('0xa44')][_0x4b0a2d('0x1166')](function(_0x12ed59){const _0x21d20d=_0x4b0a2d;_0x5c5868[_0x21d20d('0xf24')][_0x21d20d('0x2450')](_0x12ed59[_0x21d20d('0x2876')]()),_0x2f8aed[_0x21d20d('0x103b')]({'title':_0x21d20d('0x2005'),'msg':_0x5c5868[_0x21d20d('0x3b2')][_0x21d20d('0x4f0')]?_0x5c5868[_0x21d20d('0x3b2')][_0x21d20d('0x4f0')]+_0x21d20d('0x1eda'):''}),_0x265953(_0x12ed59);})[_0x4b0a2d('0x1a80')](function(_0x3a34a0){const _0x4c6b47=_0x4b0a2d;if(_0x3a34a0[_0x4c6b47('0x25f4')]&&_0x3a34a0[_0x4c6b47('0x25f4')][_0x4c6b47('0x61a')]&&_0x3a34a0[_0x4c6b47('0x25f4')][_0x4c6b47('0x61a')][_0x4c6b47('0x264b')]){_0x5c5868[_0x4c6b47('0x61a')]=_0x3a34a0['data'][_0x4c6b47('0x61a')]||[{'message':_0x3a34a0[_0x4c6b47('0x1586')](),'type':'api.trunk.save'}];for(let _0x4e9f14=0x0;_0x4e9f14<_0x3a34a0['data'][_0x4c6b47('0x61a')][_0x4c6b47('0x264b')];_0x4e9f14+=0x1){_0x2f8aed['error']({'title':_0x3a34a0[_0x4c6b47('0x25f4')][_0x4c6b47('0x61a')][_0x4e9f14][_0x4c6b47('0x1345')],'msg':_0x3a34a0[_0x4c6b47('0x25f4')]['errors'][_0x4e9f14][_0x4c6b47('0x1e70')]});}}else _0x2f8aed[_0x4c6b47('0xfc9')]({'title':_0x3a34a0['status']?_0x4c6b47('0x1e21')+_0x3a34a0[_0x4c6b47('0x52d')]+_0x4c6b47('0x11e1')+_0x3a34a0[_0x4c6b47('0xe1b')]:_0x4c6b47('0xb5c'),'msg':_0x3a34a0[_0x4c6b47('0x25f4')]?JSON['stringify'](_0x3a34a0[_0x4c6b47('0x25f4')]['message']):_0x3a34a0[_0x4c6b47('0x1586')]()});});}function _0x511d1(){const _0x56edbc=_0x2f830d;_0x5c5868['errors']=[],_0x4e6c83[_0x56edbc('0x3b2')][_0x56edbc('0x1449')]({'id':_0x5c5868['trunk']['id']},_0x5c5868[_0x56edbc('0x3b2')])['$promise'][_0x56edbc('0x1166')](function(_0xd0681){const _0x1b1650=_0x56edbc,_0x319e00=_0x2cfb05()[_0x1b1650('0xc38')](_0x5c5868[_0x1b1650('0xf24')],{'id':_0xd0681['id']});_0x319e00&&_0x2cfb05()[_0x1b1650('0xcc3')](_0x319e00,_0x2cfb05()[_0x1b1650('0x1a08')](_0xd0681[_0x1b1650('0x2876')](),_0x2cfb05()['keys'](_0x319e00))),_0x2f8aed[_0x1b1650('0x103b')]({'title':_0x1b1650('0xa81'),'msg':_0x5c5868[_0x1b1650('0x3b2')][_0x1b1650('0x4f0')]?_0x5c5868[_0x1b1650('0x3b2')][_0x1b1650('0x4f0')]+_0x1b1650('0x7d'):''}),_0x265953(_0xd0681);})[_0x56edbc('0x1a80')](function(_0x461956){const _0x657719=_0x56edbc;if(_0x461956[_0x657719('0x25f4')]&&_0x461956[_0x657719('0x25f4')]['errors']&&_0x461956[_0x657719('0x25f4')]['errors'][_0x657719('0x264b')]){_0x5c5868[_0x657719('0x61a')]=_0x461956[_0x657719('0x25f4')][_0x657719('0x61a')]||[{'message':_0x461956[_0x657719('0x1586')](),'type':_0x657719('0x1de1')}];for(let _0x26a445=0x0;_0x26a445<_0x461956[_0x657719('0x25f4')][_0x657719('0x61a')][_0x657719('0x264b')];_0x26a445++){_0x2f8aed[_0x657719('0xfc9')]({'title':_0x461956[_0x657719('0x25f4')][_0x657719('0x61a')][_0x26a445][_0x657719('0x1345')],'msg':_0x461956[_0x657719('0x25f4')][_0x657719('0x61a')][_0x26a445]['message']});}}else _0x2f8aed[_0x657719('0xfc9')]({'title':_0x461956[_0x657719('0x52d')]?'API:'+_0x461956[_0x657719('0x52d')]+_0x657719('0x11e1')+_0x461956['statusText']:_0x657719('0x1de1'),'msg':_0x461956['data']?JSON['stringify'](_0x461956[_0x657719('0x25f4')]['message']):_0x461956['toString']()});});}function _0x11de9a(_0x24688e){const _0x21d041=_0x2f830d;_0x5c5868[_0x21d041('0x61a')]=[];const _0x16c39d=_0x1cf835[_0x21d041('0x1d26')]()[_0x21d041('0xcdc')](_0x21d041('0x7fb'))['content'](_0x21d041('0x329'))[_0x21d041('0x8e8')](_0x21d041('0x15ba'))['ok'](_0x21d041('0x18'))['cancel'](_0x21d041('0x497'))[_0x21d041('0x203b')](_0x24688e);_0x1cf835[_0x21d041('0x1f80')](_0x16c39d)[_0x21d041('0x1166')](function(){const _0x2ecb29=_0x21d041;_0x4e6c83[_0x2ecb29('0x3b2')][_0x2ecb29('0x906')]({'id':_0x5c5868[_0x2ecb29('0x3b2')]['id']})[_0x2ecb29('0xa44')][_0x2ecb29('0x1166')](function(){const _0x185eb9=_0x2ecb29;_0x2cfb05()[_0x185eb9('0x127f')](_0x5c5868['trunks'],{'id':_0x5c5868['trunk']['id']}),_0x2f8aed[_0x185eb9('0x103b')]({'title':_0x185eb9('0x78'),'msg':(_0x5c5868[_0x185eb9('0x3b2')]['name']||'trunk')+'\x20has\x20been\x20deleted!'}),_0x265953(_0x5c5868[_0x185eb9('0x3b2')]);})[_0x2ecb29('0x1a80')](function(_0x1f00db){const _0x4387fb=_0x2ecb29;if(_0x1f00db[_0x4387fb('0x25f4')]&&_0x1f00db[_0x4387fb('0x25f4')]['errors']&&_0x1f00db[_0x4387fb('0x25f4')]['errors'][_0x4387fb('0x264b')]){_0x5c5868['errors']=_0x1f00db[_0x4387fb('0x25f4')][_0x4387fb('0x61a')]||[{'message':_0x1f00db[_0x4387fb('0x1586')](),'type':'api.trunk.delete'}];for(let _0x2f2b6a=0x0;_0x2f2b6a<_0x1f00db['data'][_0x4387fb('0x61a')][_0x4387fb('0x264b')];_0x2f2b6a++){_0x2f8aed[_0x4387fb('0xfc9')]({'title':_0x1f00db[_0x4387fb('0x25f4')][_0x4387fb('0x61a')][_0x2f2b6a][_0x4387fb('0x1345')],'msg':_0x1f00db[_0x4387fb('0x25f4')][_0x4387fb('0x61a')][_0x2f2b6a][_0x4387fb('0x1e70')]});}}else _0x2f8aed['error']({'title':_0x1f00db['status']?_0x4387fb('0x1e21')+_0x1f00db[_0x4387fb('0x52d')]+_0x4387fb('0x11e1')+_0x1f00db[_0x4387fb('0xe1b')]:_0x4387fb('0x80d'),'msg':_0x1f00db['data']?JSON['stringify'](_0x1f00db[_0x4387fb('0x25f4')]['message']):_0x1f00db['message']||_0x1f00db[_0x4387fb('0x1586')]()});});},function(){});}function _0xb3401f(_0x453b15){return _0x453b15===null?undefined:new Date(_0x453b15);}function _0x265953(_0xb20014){_0x1cf835['hide'](_0xb20014);}}const _0x50d6ff=_0x3ac053;_0x4fd2df[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x7b9'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x3b2'),_0x36e6f4('0xf24'),_0x36e6f4('0x586')];function _0x4fd2df(_0xcc4dc8,_0x1387b9,_0x5377cd,_0x309dd7,_0x5329f1,_0x178e94,_0x5920ca){const _0x374f8b=_0x36e6f4,_0x4c5165=this;_0x4c5165[_0x374f8b('0x1d52')]=!![],_0x4c5165[_0x374f8b('0x3b2')]=angular[_0x374f8b('0x225f')](_0x5329f1),_0x4c5165[_0x374f8b('0xf24')]=_0x178e94,_0x4c5165['title']=_0x5920ca[_0x374f8b('0x25cc')]('TOOLS.CLONE_TRUNK');_0x5329f1&&_0x5329f1[_0x374f8b('0x4f0')]&&(_0x4c5165[_0x374f8b('0xcdc')]+=':\x20'+_0x5329f1[_0x374f8b('0x4f0')]);_0x4c5165[_0x374f8b('0xf6d')]=_0x30e36d,_0x4c5165[_0x374f8b('0x24a0')]=_0xcb83dc;function _0x30e36d(){const _0x34c7ec=_0x374f8b;return _0x309dd7[_0x34c7ec('0x3b2')][_0x34c7ec('0xddc')]({'id':_0x5329f1['id']},_0x4c5165[_0x34c7ec('0x3b2')])[_0x34c7ec('0xa44')][_0x34c7ec('0x1166')](function(_0x3c9f54){const _0x1dc480=_0x34c7ec;_0x4c5165[_0x1dc480('0xf24')][_0x1dc480('0x2450')](_0x3c9f54['toJSON']()),_0x5377cd[_0x1dc480('0x103b')]({'title':_0x1dc480('0x1b01'),'msg':_0x4c5165[_0x1dc480('0x3b2')][_0x1dc480('0x4f0')]?_0x4c5165[_0x1dc480('0x3b2')][_0x1dc480('0x4f0')]+_0x1dc480('0x1273'):''}),_0x1387b9['go'](_0x1dc480('0x1f20'),{'id':_0x3c9f54['id']}),_0xcb83dc(_0x3c9f54);})['catch'](function(_0x18643d){const _0x42446c=_0x34c7ec;if(_0x18643d[_0x42446c('0x25f4')]&&_0x18643d[_0x42446c('0x25f4')][_0x42446c('0x61a')]&&_0x18643d[_0x42446c('0x25f4')][_0x42446c('0x61a')][_0x42446c('0x264b')]){_0x4c5165[_0x42446c('0x61a')]=_0x18643d[_0x42446c('0x25f4')][_0x42446c('0x61a')]||[{'message':_0x18643d[_0x42446c('0x1586')](),'type':_0x42446c('0x83c')}];for(let _0x2bd279=0x0;_0x2bd279<_0x18643d['data'][_0x42446c('0x61a')]['length'];_0x2bd279+=0x1){_0x5377cd[_0x42446c('0xfc9')]({'title':_0x18643d[_0x42446c('0x25f4')]['errors'][_0x2bd279][_0x42446c('0x1345')],'msg':_0x18643d[_0x42446c('0x25f4')][_0x42446c('0x61a')][_0x2bd279][_0x42446c('0x1e70')]});}}else _0x5377cd[_0x42446c('0xfc9')]({'title':_0x18643d['status']?'API:'+_0x18643d['status']+_0x42446c('0x11e1')+_0x18643d['statusText']:_0x42446c('0x83c'),'msg':_0x18643d[_0x42446c('0x25f4')]?JSON[_0x42446c('0xbac')](_0x18643d['data']['message']):_0x18643d[_0x42446c('0x1586')]()});});}function _0xcb83dc(_0x77db94){const _0xa219fa=_0x374f8b;_0xcc4dc8[_0xa219fa('0x1197')](_0x77db94);}}const _0xd334f1=_0x4fd2df,_0x20a681=_0x2734b2['p']+_0x36e6f4('0xb6a');_0x48f765['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'api',_0x36e6f4('0x1d2e'),'Auth','trunk',_0x36e6f4('0x17aa')];function _0x48f765(_0x479858,_0x2cd3f8,_0x306456,_0xc7c420,_0x2d2add,_0x5b1a48,_0x3094ee,_0x2765d1,_0x5d81dc,_0x3f73dd,_0x4f12c5,_0x54be7d){const _0x336b1d=_0x36e6f4,_0x571ed7=this;_0x571ed7[_0x336b1d('0x98')]=_0x3f73dd[_0x336b1d('0x26cd')](),_0x571ed7[_0x336b1d('0x5c9')]=_0x5b1a48,_0x571ed7[_0x336b1d('0xf8a')]=_0x3094ee,_0x571ed7[_0x336b1d('0x2900')]=_0x571ed7['setting'][_0x336b1d('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x571ed7[_0x336b1d('0x246b')]=_0x2cd3f8[_0x336b1d('0x6f1')]()+_0x336b1d('0xc51')+_0x2cd3f8[_0x336b1d('0x1690')](),_0x571ed7[_0x336b1d('0x3b2')]=_0x4f12c5||_0x479858[_0x336b1d('0x23f')]['trunk']||{},_0x571ed7['userProfileSection']=_0x54be7d&&_0x54be7d['count']==0x1?_0x54be7d[_0x336b1d('0x269a')][0x0]:null,_0x571ed7[_0x336b1d('0x243c')]=_0x3f73dd[_0x336b1d('0xd87')](_0x571ed7[_0x336b1d('0x17aa')]?_0x571ed7[_0x336b1d('0x17aa')][_0x336b1d('0x243c')]:null),_0x571ed7[_0x336b1d('0x128b')]={},_0x571ed7[_0x336b1d('0x2669')]=_0x479858[_0x336b1d('0x23f')][_0x336b1d('0xbe3')]||0x0,_0x571ed7[_0x336b1d('0x22c1')]=_0x17b256,_0x571ed7[_0x336b1d('0x249d')]=_0x33c4ac,_0x571ed7[_0x336b1d('0x31d')]=_0x5d81dc[_0x336b1d('0x1fa1')],_0x571ed7['gotoTrunks']=_0x38dd13,_0x571ed7[_0x336b1d('0xb59')]=_0x381161,_0x3f73dd[_0x336b1d('0x1ac6')](_0x336b1d('0xa7c'))?_0x2765d1[_0x336b1d('0x23b1')][_0x336b1d('0xd83')]({'fields':'id,name','sort':_0x336b1d('0x4f0')})['$promise'][_0x336b1d('0x1166')](function(_0x173e41){const _0x23781b=_0x336b1d;_0x571ed7[_0x23781b('0x160a')]=_0x173e41[_0x23781b('0x269a')]||[];})[_0x336b1d('0x1a80')](function(_0xebf88e){const _0x1804f2=_0x336b1d;_0x5d81dc[_0x1804f2('0xfc9')]({'title':_0xebf88e[_0x1804f2('0x52d')]?_0x1804f2('0x1e21')+_0xebf88e[_0x1804f2('0x52d')]+_0x1804f2('0x11e1')+_0xebf88e['statusText']:_0x1804f2('0x140d'),'msg':_0xebf88e[_0x1804f2('0x25f4')]?JSON['stringify'](_0xebf88e[_0x1804f2('0x25f4')]):_0xebf88e[_0x1804f2('0x1586')]()});}):_0x2765d1['voiceContext'][_0x336b1d('0xd83')]({'fields':_0x336b1d('0x1776'),'sort':'name'})[_0x336b1d('0xa44')][_0x336b1d('0x1166')](function(_0x1023a5){const _0x1bc96d=_0x336b1d;_0x571ed7[_0x1bc96d('0x160a')]=_0x1023a5[_0x1bc96d('0x269a')]||[];})[_0x336b1d('0x1166')](function(){const _0x24897d=_0x336b1d;return _0x2765d1[_0x24897d('0x17aa')][_0x24897d('0xd83')]({'userProfileId':_0x571ed7[_0x24897d('0x98')]['userProfileId'],'sectionId':0x195})[_0x24897d('0xa44')];})[_0x336b1d('0x1166')](function(_0x2f7eac){const _0x44238a=_0x336b1d,_0x140c5c=_0x2f7eac&&_0x2f7eac['rows']?_0x2f7eac[_0x44238a('0x269a')][0x0]:null;if(!_0x140c5c)return _0x2765d1[_0x44238a('0x23b1')]['get']({'fields':'id,name','sort':_0x44238a('0x4f0'),'defaultEntry':0x1})[_0x44238a('0xa44')][_0x44238a('0x1166')](function(_0x29a918){const _0x28e4f4=_0x44238a;_0x571ed7[_0x28e4f4('0x160a')]=_0x29a918[_0x28e4f4('0x269a')]||[];});else{if(!_0x140c5c[_0x44238a('0x1a2b')])return _0x2765d1[_0x44238a('0x4b5')][_0x44238a('0xd83')]({'sectionId':_0x140c5c['id']})[_0x44238a('0xa44')][_0x44238a('0x1166')](function(_0x5b10f9){const _0x242d40=_0x44238a,_0x5c45b3=_0x2cfb05()[_0x242d40('0x2563')](_0x5b10f9['rows'],function(_0x1b7b5b){const _0x443460=_0x242d40;return _0x2cfb05()[_0x443460('0xc38')](_0x571ed7['contexts'],{'id':_0x1b7b5b[_0x443460('0x24e8')]});});let _0x24d7dc=null;_0x571ed7[_0x242d40('0x3b2')]&&(_0x24d7dc=_0x2cfb05()[_0x242d40('0xc38')](_0x571ed7[_0x242d40('0x160a')],{'name':_0x571ed7[_0x242d40('0x3b2')]['context']}));if(_0x24d7dc&&!_0x2cfb05()['some'](_0x5c45b3,['id',_0x24d7dc['id']])){const _0xb2a3ef=_0x2cfb05()[_0x242d40('0xc38')](_0x571ed7[_0x242d40('0x160a')],{'id':_0x24d7dc['id']});_0xb2a3ef[_0x242d40('0x2378')]=![],_0x5c45b3[_0x242d40('0x1514')](_0xb2a3ef);}_0x571ed7['contexts']=_0x5c45b3;});}})[_0x336b1d('0x1a80')](function(_0x141604){const _0x5009ae=_0x336b1d;_0x5d81dc[_0x5009ae('0xfc9')]({'title':_0x141604[_0x5009ae('0x52d')]?'API:'+_0x141604['status']+'\x20-\x20'+_0x141604[_0x5009ae('0xe1b')]:'SYSTEM:GETcontexts','msg':_0x141604[_0x5009ae('0x25f4')]?JSON[_0x5009ae('0xbac')](_0x141604[_0x5009ae('0x25f4')]):_0x141604[_0x5009ae('0x1586')]()});});function _0x17b256(){const _0x2f547c=_0x336b1d;if(_0x3f73dd[_0x2f547c('0x1ac6')]('admin'))_0x479858['go'](_0x2f547c('0x13ae'),{});else return _0x2765d1['userProfileSection'][_0x2f547c('0xd83')]({'userProfileId':_0x3f73dd[_0x2f547c('0x26cd')]()[_0x2f547c('0xb86')],'sectionId':0x19b})[_0x2f547c('0xa44')]['then'](function(_0x75d981){const _0x388c8f=_0x2f547c,_0x2b2a0c=_0x75d981&&_0x75d981[_0x388c8f('0x269a')]?_0x75d981['rows'][0x0]:null;_0x2b2a0c&&_0x2b2a0c[_0x388c8f('0xc27')]?_0x479858['go'](_0x388c8f('0x13ae'),{}):_0x5d81dc[_0x388c8f('0x1fa1')]({'title':_0x2d2add[_0x388c8f('0x25cc')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x2d2add['instant'](_0x388c8f('0x2642'))});})['catch'](function(_0x27ac5c){const _0x310cec=_0x2f547c;_0x5d81dc[_0x310cec('0xfc9')]({'title':_0x27ac5c['status']?_0x310cec('0x1e21')+_0x27ac5c['status']+_0x310cec('0x11e1')+_0x27ac5c[_0x310cec('0xe1b')]:'USERPROFILE:GET_SECTION','msg':_0x27ac5c[_0x310cec('0x52d')]?JSON[_0x310cec('0xbac')](_0x27ac5c[_0x310cec('0x25f4')]):_0x27ac5c['toString']()});});}function _0x33c4ac(_0x5aa4be,_0x685e5a){const _0x2d9722=_0x336b1d;_0x306456[_0x2d9722('0x1f80')]({'controller':'TrunkcloneController','controllerAs':'vm','templateUrl':_0x20a681,'parent':angular[_0x2d9722('0x1194')](_0xc7c420[_0x2d9722('0x8d2')]),'targetEvent':_0x685e5a,'clickOutsideToClose':!![],'locals':{'trunk':_0x5aa4be,'trunks':_0x571ed7[_0x2d9722('0xf24')]?_0x571ed7[_0x2d9722('0xf24')]['rows']:[],'crudPermissions':_0x571ed7[_0x2d9722('0x243c')]}});}function _0x38dd13(){const _0x33b5eb=_0x336b1d;_0x479858['go'](_0x33b5eb('0x108d'),{},{'reload':_0x33b5eb('0x108d')});}function _0x381161(){const _0x416ef1=_0x336b1d;_0x2765d1['trunk'][_0x416ef1('0x1449')]({'id':_0x571ed7[_0x416ef1('0x3b2')]['id']},_0x571ed7[_0x416ef1('0x3b2')])[_0x416ef1('0xa44')][_0x416ef1('0x1166')](function(){const _0x156c34=_0x416ef1;_0x5d81dc['success']({'title':_0x156c34('0x1a8a'),'msg':_0x571ed7[_0x156c34('0x3b2')]['name']?_0x571ed7[_0x156c34('0x3b2')][_0x156c34('0x4f0')]+_0x156c34('0xa17'):''});})[_0x416ef1('0x1a80')](function(_0x53f362){const _0x1cee06=_0x416ef1;_0x5d81dc[_0x1cee06('0xfc9')]({'title':_0x53f362['status']?_0x1cee06('0x1e21')+_0x53f362[_0x1cee06('0x52d')]+_0x1cee06('0x11e1')+_0x53f362[_0x1cee06('0xe1b')]:'SYSTEM:GETtrunk','msg':_0x53f362[_0x1cee06('0x25f4')]?JSON[_0x1cee06('0xbac')](_0x53f362['data']):_0x53f362[_0x1cee06('0x1586')]()});});}}const _0x2d7d0c=_0x48f765,_0x17b3fe=_0x2734b2['p']+_0x36e6f4('0x1799');_0x20da0f[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),'$translate',_0x36e6f4('0xf24'),'userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x5c9'),'setting'];function _0x20da0f(_0x21cdae,_0x366561,_0x43fe67,_0x5de171,_0x551be6,_0xc53707,_0x2a4ef4,_0x3550ed,_0x131f16,_0x4bb5fa,_0x429e7d,_0x24faf5,_0x32df74,_0x510db7,_0x1544aa,_0x81827d,_0x2b5fee){const _0x2bbf15=_0x36e6f4,_0x55e207=this;_0x55e207[_0x2bbf15('0x5c9')]=_0x81827d,_0x55e207[_0x2bbf15('0xf8a')]=_0x2b5fee,_0x55e207[_0x2bbf15('0x98')]=_0x1544aa[_0x2bbf15('0x26cd')](),_0x55e207[_0x2bbf15('0xf24')]=_0x131f16||{'count':0x0,'rows':[]},_0x55e207[_0x2bbf15('0x7f')]=_0x4bb5fa,_0x55e207[_0x2bbf15('0x17aa')]=_0x429e7d&&_0x429e7d[_0x2bbf15('0x240f')]==0x1?_0x429e7d[_0x2bbf15('0x269a')][0x0]:null,_0x55e207[_0x2bbf15('0x243c')]=_0x1544aa[_0x2bbf15('0xd87')](_0x55e207['userProfileSection']?_0x55e207[_0x2bbf15('0x17aa')][_0x2bbf15('0x243c')]:null),_0x55e207[_0x2bbf15('0x916')]='trunks',_0x55e207['listOrder']='',_0x55e207[_0x2bbf15('0x104c')]=null,_0x55e207[_0x2bbf15('0x1092')]=[],_0x55e207['query']={'fields':_0x2bbf15('0x2f9'),'sort':_0x2bbf15('0x14dc'),'limit':0xa,'page':0x1},_0x55e207['arraytype']=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':'Friend','value':_0x2bbf15('0x1d41')},{'option':_0x2bbf15('0x1a6f'),'value':_0x2bbf15('0x247a')},{'option':_0x2bbf15('0x784'),'value':'\x27peer\x27'}],function(_0x346f99){const _0x5d7bce=_0x2bbf15;return _0x2cfb05()['replace'](_0x346f99[_0x5d7bce('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x8b4')]=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':_0x2bbf15('0x7f5'),'value':_0x2bbf15('0x366')},{'option':'info','value':'\x27info\x27'},{'option':_0x2bbf15('0x18fc'),'value':_0x2bbf15('0x178e')},{'option':_0x2bbf15('0x127a'),'value':'\x27inband\x27'},{'option':_0x2bbf15('0x110a'),'value':_0x2bbf15('0x1576')}],function(_0x3f13f2){const _0x1271b0=_0x2bbf15;return _0x2cfb05()['replace'](_0x3f13f2[_0x1271b0('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x1c9')]=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':_0x2bbf15('0x976'),'value':_0x2bbf15('0x553')},{'option':'comedia','value':_0x2bbf15('0x3e6')},{'option':_0x2bbf15('0x55d'),'value':_0x2bbf15('0x20b3')},{'option':'no','value':'\x27no\x27'},{'option':_0x2bbf15('0x122f'),'value':_0x2bbf15('0x130c')},{'option':_0x2bbf15('0x16a8'),'value':_0x2bbf15('0x1375')}],function(_0x207521){return _0x2cfb05()['replace'](_0x207521['value'],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0xcb2')]=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':_0x2bbf15('0x55d'),'value':'\x27yes\x27'},{'option':'no','value':'\x27no\x27'}],function(_0x1514b9){const _0x2cbc0f=_0x2bbf15;return _0x2cfb05()[_0x2cbc0f('0xf3')](_0x1514b9[_0x2cbc0f('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x140')]=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':'ulaw','value':_0x2bbf15('0x166f')},{'option':_0x2bbf15('0x157'),'value':'\x27alaw\x27'},{'option':_0x2bbf15('0x1cd9'),'value':_0x2bbf15('0xd74')},{'option':'g723','value':_0x2bbf15('0x1da4')},{'option':_0x2bbf15('0xc50'),'value':_0x2bbf15('0xdf6')},{'option':_0x2bbf15('0x27f0'),'value':_0x2bbf15('0x1ae2')},{'option':_0x2bbf15('0x19b7'),'value':_0x2bbf15('0x48d')},{'option':'ilbc','value':'\x27ilbc\x27'},{'option':_0x2bbf15('0x1f1d'),'value':_0x2bbf15('0x1fbd')},{'option':_0x2bbf15('0x173a'),'value':'\x27h264\x27'}],function(_0x5bafce){const _0x5a03d5=_0x2bbf15;return _0x2cfb05()[_0x5a03d5('0xf3')](_0x5bafce[_0x5a03d5('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x21c5')]=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':'port','value':'\x27port\x27'},{'option':_0x2bbf15('0x6a'),'value':_0x2bbf15('0x1972')},{'option':'very','value':_0x2bbf15('0x1bcc')}],function(_0x8cac1a){const _0x39448b=_0x2bbf15;return _0x2cfb05()[_0x39448b('0xf3')](_0x8cac1a[_0x39448b('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207['arraydirectmedia']=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':_0x2bbf15('0x55d'),'value':_0x2bbf15('0x20b3')},{'option':'no','value':_0x2bbf15('0x119b')},{'option':_0x2bbf15('0x1619'),'value':_0x2bbf15('0x1790')},{'option':_0x2bbf15('0x1449'),'value':_0x2bbf15('0x22c8')}],function(_0x4b0fb0){const _0x513949=_0x2bbf15;return _0x2cfb05()[_0x513949('0xf3')](_0x4b0fb0['value'],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x1fd0')]=_0x2cfb05()['keyBy']([{'option':_0x2bbf15('0x55d'),'value':_0x2bbf15('0x20b3')},{'option':'no','value':_0x2bbf15('0x119b')}],function(_0x51aa1a){const _0x57082b=_0x2bbf15;return _0x2cfb05()['replace'](_0x51aa1a[_0x57082b('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x11d6')]=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':_0x2bbf15('0x55d'),'value':_0x2bbf15('0x20b3')},{'option':'no','value':_0x2bbf15('0x119b')}],function(_0x52647a){const _0x2dec85=_0x2bbf15;return _0x2cfb05()[_0x2dec85('0xf3')](_0x52647a[_0x2dec85('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x705')]=_0x2cfb05()['keyBy']([{'option':_0x2bbf15('0x55d'),'value':_0x2bbf15('0x20b3')},{'option':'no','value':_0x2bbf15('0x119b')}],function(_0x4071a7){const _0x58ab40=_0x2bbf15;return _0x2cfb05()[_0x58ab40('0xf3')](_0x4071a7[_0x58ab40('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207['arraysendrpid']=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':_0x2bbf15('0x55d'),'value':'\x27yes\x27'},{'option':'no','value':_0x2bbf15('0x119b')},{'option':_0x2bbf15('0x1a68'),'value':_0x2bbf15('0xc26')}],function(_0x34cde5){const _0x23975a=_0x2bbf15;return _0x2cfb05()[_0x23975a('0xf3')](_0x34cde5['value'],new RegExp('\x27','g'),'');}),_0x55e207['arrayencryption']=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':'yes','value':_0x2bbf15('0x20b3')},{'option':'no','value':_0x2bbf15('0x119b')}],function(_0xd33ff3){const _0x2f809f=_0x2bbf15;return _0x2cfb05()[_0x2f809f('0xf3')](_0xd33ff3[_0x2f809f('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x1170')]=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':_0x2bbf15('0x8fc'),'value':'\x27udp\x27'},{'option':_0x2bbf15('0xe31'),'value':_0x2bbf15('0x1d5e')},{'option':'ws','value':_0x2bbf15('0x1eb6')},{'option':_0x2bbf15('0x83a'),'value':_0x2bbf15('0x28da')},{'option':_0x2bbf15('0xf49'),'value':'\x27tls\x27'}],function(_0x5769ed){const _0x5ba88c=_0x2bbf15;return _0x2cfb05()['replace'](_0x5769ed[_0x5ba88c('0x18e0')],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x1f32')]=_0x2cfb05()[_0x2bbf15('0x155c')]([{'option':'Yes','value':'\x27yes\x27'},{'option':'No','value':_0x2bbf15('0x119b')},{'option':_0x2bbf15('0x70f'),'value':_0x2bbf15('0x312')}],function(_0x29280f){const _0xb216e6=_0x2bbf15;return _0x2cfb05()[_0xb216e6('0xf3')](_0x29280f['value'],new RegExp('\x27','g'),'');}),_0x55e207[_0x2bbf15('0x1ff6')]=_0x50c729,_0x55e207[_0x2bbf15('0x249d')]=_0x10dc6b,_0x55e207[_0x2bbf15('0x182d')]=_0x5a51cc,_0x55e207[_0x2bbf15('0x8d8')]=_0x1eb826,_0x55e207[_0x2bbf15('0x103b')]=_0x8bd79,_0x55e207[_0x2bbf15('0x58')]=_0x486fb5,_0x55e207[_0x2bbf15('0x71e')]=_0xdbbcb1,_0x55e207[_0x2bbf15('0x1504')]=_0x22019f,_0x55e207[_0x2bbf15('0x271a')]=_0x3a851a,_0x55e207['deleteSelectedTrunks']=_0x1ffad0,_0x55e207[_0x2bbf15('0xdbf')]=_0x2eb903,_0x55e207[_0x2bbf15('0x1d07')]=_0x14d779;function _0x50c729(_0x32d788){const _0x4393e1=_0x2bbf15;_0x43fe67['go'](_0x4393e1('0x1f20'),{'id':_0x32d788['id'],'trunk':_0x32d788,'crudPermissions':_0x55e207['crudPermissions']});}function _0x10dc6b(_0x320331,_0x51131d){const _0x286100=_0x2bbf15;_0x551be6[_0x286100('0x1f80')]({'controller':_0x286100('0x1cd7'),'controllerAs':'vm','templateUrl':_0x20a681,'parent':angular['element'](_0xc53707[_0x286100('0x8d2')]),'targetEvent':_0x51131d,'clickOutsideToClose':!![],'locals':{'trunk':_0x320331,'trunks':_0x55e207[_0x286100('0xf24')]?_0x55e207[_0x286100('0xf24')]['rows']:[],'crudPermissions':_0x55e207[_0x286100('0x243c')]}});}function _0x5a51cc(){const _0x88951d=_0x2bbf15;if(_0x1544aa[_0x88951d('0x1ac6')](_0x88951d('0xa7c')))_0x43fe67['go'](_0x88951d('0x13ae'),{});else return _0x24faf5[_0x88951d('0x17aa')][_0x88951d('0xd83')]({'userProfileId':_0x1544aa['getCurrentUser']()[_0x88951d('0xb86')],'sectionId':0x19b})[_0x88951d('0xa44')][_0x88951d('0x1166')](function(_0x28727d){const _0xb6a58c=_0x88951d,_0x5529c1=_0x28727d&&_0x28727d['rows']?_0x28727d[_0xb6a58c('0x269a')][0x0]:null;_0x5529c1&&_0x5529c1[_0xb6a58c('0xc27')]?_0x43fe67['go'](_0xb6a58c('0x13ae'),{}):_0x510db7[_0xb6a58c('0x1fa1')]({'title':_0x3550ed[_0xb6a58c('0x25cc')](_0xb6a58c('0x627')),'msg':_0x3550ed[_0xb6a58c('0x25cc')](_0xb6a58c('0x2642'))});})['catch'](function(_0x302db8){const _0x5de685=_0x88951d;_0x510db7[_0x5de685('0xfc9')]({'title':_0x302db8[_0x5de685('0x52d')]?_0x5de685('0x1e21')+_0x302db8[_0x5de685('0x52d')]+_0x5de685('0x11e1')+_0x302db8[_0x5de685('0xe1b')]:_0x5de685('0x153e'),'msg':_0x302db8[_0x5de685('0x52d')]?JSON[_0x5de685('0xbac')](_0x302db8[_0x5de685('0x25f4')]):_0x302db8[_0x5de685('0x1586')]()});});}function _0x1eb826(_0x4bbd0c,_0x2cd06c){const _0x339a2f=_0x2bbf15,_0x38baaf=_0x551be6['confirm']()['title'](_0x339a2f('0x288d')+_0x2cfb05()[_0x339a2f('0xb35')]('trunk')+'?')[_0x339a2f('0xf3c')](_0x339a2f('0x12b5')+(_0x4bbd0c[_0x339a2f('0x4f0')]||_0x339a2f('0x3b2'))+''+_0x339a2f('0x3f3'))[_0x339a2f('0x8e8')]('delete\x20trunk')[_0x339a2f('0x203b')](_0x2cd06c)['ok']('OK')['cancel'](_0x339a2f('0x2d3'));_0x551be6[_0x339a2f('0x1f80')](_0x38baaf)[_0x339a2f('0x1166')](function(){_0x22019f(_0x4bbd0c);},function(){const _0x265430=_0x339a2f;console[_0x265430('0x455')]('CANCEL');});}let _0x1c9886=!![],_0x143179=0x1;_0x21cdae[_0x2bbf15('0xe83')]('vm.query.filter',function(_0x690a80,_0xf81a4a){const _0x2f027c=_0x2bbf15;_0x1c9886?_0x2a4ef4(function(){_0x1c9886=![];}):(!_0xf81a4a&&(_0x143179=_0x55e207[_0x2f027c('0x2218')][_0x2f027c('0x1a43')]),_0x690a80!==_0xf81a4a&&(_0x55e207[_0x2f027c('0x2218')][_0x2f027c('0x1a43')]=0x1),!_0x690a80&&(_0x55e207[_0x2f027c('0x2218')]['page']=_0x143179),_0x55e207[_0x2f027c('0x58')]());});function _0x8bd79(_0x2511d9){_0x55e207['trunks']=_0x2511d9||{'count':0x0,'rows':[]};}function _0x486fb5(){const _0x52de14=_0x2bbf15;_0x55e207[_0x52de14('0x2218')][_0x52de14('0x1098')]=(_0x55e207[_0x52de14('0x2218')]['page']-0x1)*_0x55e207['query'][_0x52de14('0x163f')],_0x1544aa[_0x52de14('0x1ac6')]('admin')?_0x55e207['promise']=_0x24faf5['trunk'][_0x52de14('0xd83')](_0x55e207[_0x52de14('0x2218')],_0x8bd79)['$promise']:(_0x55e207[_0x52de14('0x2218')]['id']=_0x55e207['userProfile']['id'],_0x55e207[_0x52de14('0x2218')][_0x52de14('0xe60')]=_0x52de14('0x2685'),_0x55e207[_0x52de14('0x1f48')]=_0x24faf5[_0x52de14('0x7f')][_0x52de14('0x263a')](_0x55e207['query'],_0x8bd79)['$promise']);}function _0xdbbcb1(_0x40a0a7,_0x12c160){const _0x4e0a93=_0x2bbf15;_0x551be6[_0x4e0a93('0x1f80')]({'controller':_0x4e0a93('0x1930'),'controllerAs':'vm','templateUrl':_0x17b3fe,'parent':angular[_0x4e0a93('0x1194')](_0xc53707[_0x4e0a93('0x8d2')]),'targetEvent':_0x40a0a7,'clickOutsideToClose':!![],'locals':{'trunk':_0x12c160,'trunks':_0x55e207[_0x4e0a93('0xf24')][_0x4e0a93('0x269a')],'license':_0x55e207['license'],'setting':_0x55e207[_0x4e0a93('0xf8a')],'crudPermissions':_0x55e207['crudPermissions']}});}function _0x22019f(_0x3ec8ef){const _0x2b3df6=_0x2bbf15;_0x24faf5['trunk']['delete']({'id':_0x3ec8ef['id']})[_0x2b3df6('0xa44')]['then'](function(){const _0x3cde64=_0x2b3df6;_0x2cfb05()[_0x3cde64('0x127f')](_0x55e207[_0x3cde64('0xf24')][_0x3cde64('0x269a')],{'id':_0x3ec8ef['id']}),_0x55e207[_0x3cde64('0xf24')][_0x3cde64('0x240f')]-=0x1,!_0x55e207[_0x3cde64('0xf24')][_0x3cde64('0x269a')][_0x3cde64('0x264b')]&&_0x55e207['getTrunks'](),_0x510db7[_0x3cde64('0x103b')]({'title':_0x2cfb05()[_0x3cde64('0xb35')](_0x3cde64('0x14c4'))+_0x3cde64('0x2b6'),'msg':_0x3ec8ef['name']?_0x3ec8ef[_0x3cde64('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0x2b3df6('0x1a80')](function(_0x2e8e03){const _0x57a8bb=_0x2b3df6;if(_0x2e8e03[_0x57a8bb('0x25f4')]&&_0x2e8e03['data'][_0x57a8bb('0x61a')]&&_0x2e8e03[_0x57a8bb('0x25f4')][_0x57a8bb('0x61a')][_0x57a8bb('0x264b')]){_0x55e207[_0x57a8bb('0x61a')]=_0x2e8e03[_0x57a8bb('0x25f4')]['errors']||[{'message':_0x2e8e03[_0x57a8bb('0x1586')](),'type':'SYSTEM:DELETEtrunk'}];for(let _0x4ebeea=0x0;_0x4ebeea<_0x2e8e03['data'][_0x57a8bb('0x61a')][_0x57a8bb('0x264b')];_0x4ebeea++){_0x510db7[_0x57a8bb('0xfc9')]({'title':_0x2e8e03['data'][_0x57a8bb('0x61a')][_0x4ebeea][_0x57a8bb('0x1345')],'msg':_0x2e8e03[_0x57a8bb('0x25f4')]['errors'][_0x4ebeea][_0x57a8bb('0x1e70')]});}}else _0x510db7[_0x57a8bb('0xfc9')]({'title':_0x2e8e03[_0x57a8bb('0x52d')]?_0x57a8bb('0x1e21')+_0x2e8e03[_0x57a8bb('0x52d')]+_0x57a8bb('0x11e1')+_0x2e8e03[_0x57a8bb('0xe1b')]:_0x57a8bb('0x118'),'msg':_0x2e8e03[_0x57a8bb('0x25f4')]?JSON[_0x57a8bb('0xbac')](_0x2e8e03[_0x57a8bb('0x25f4')][_0x57a8bb('0x1e70')]):_0x2e8e03[_0x57a8bb('0x1e70')]||_0x2e8e03[_0x57a8bb('0x1586')]()});});}function _0x3a851a(){const _0x11bfe1=_0x2bbf15,_0x5803ec=angular[_0x11bfe1('0x225f')](_0x55e207[_0x11bfe1('0x1092')]);return _0x55e207[_0x11bfe1('0x1092')]=[],_0x5803ec;}function _0x1ffad0(_0x40507c){const _0x57db51=_0x2bbf15,_0x389bfc=_0x551be6[_0x57db51('0x1d26')]()[_0x57db51('0xcdc')](_0x57db51('0x1614'))['htmlContent'](_0x57db51('0x12b5')+_0x55e207[_0x57db51('0x1092')][_0x57db51('0x264b')]+_0x57db51('0x196d')+_0x57db51('0x3f3'))[_0x57db51('0x8e8')](_0x57db51('0x217'))[_0x57db51('0x203b')](_0x40507c)['ok']('OK')[_0x57db51('0x3f')]('CANCEL');_0x551be6[_0x57db51('0x1f80')](_0x389bfc)[_0x57db51('0x1166')](function(){const _0x5824d0=_0x57db51;_0x55e207['selectedTrunks'][_0x5824d0('0x2782')](function(_0x594071){_0x22019f(_0x594071);}),_0x55e207[_0x5824d0('0x1092')]=[];});}function _0x2eb903(){const _0x14f540=_0x2bbf15;_0x55e207[_0x14f540('0x1092')]=[];}function _0x14d779(){const _0x264570=_0x2bbf15;_0x55e207[_0x264570('0x1092')]=_0x55e207[_0x264570('0xf24')][_0x264570('0x269a')];}}const _0x297694=_0x20da0f;_0x51980f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),'variables','variable',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x51980f(_0x3fa2a6,_0x133c5b,_0x1d81af,_0x3e0a97,_0x35adb,_0x23d06b,_0xd88fe1,_0x3c23e7,_0x105578,_0x3a2bd6,_0x3ee873,_0x1bbd8d,_0x515aa0,_0x3887ec){const _0x32d108=_0x36e6f4,_0x3e2c70=this;_0x3e2c70[_0x32d108('0x98')]=_0x3ee873[_0x32d108('0x26cd')](),_0x3e2c70[_0x32d108('0x61a')]=[],_0x3e2c70[_0x32d108('0xf8a')]=_0x515aa0,_0x3e2c70[_0x32d108('0x5c9')]=_0x1bbd8d,_0x3e2c70[_0x32d108('0x243c')]=_0x3887ec,_0x3e2c70[_0x32d108('0x128b')]={},_0x3e2c70['passwordPattern']=_0x3e2c70['setting']&&_0x3e2c70[_0x32d108('0xf8a')][_0x32d108('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3e2c70['title']=_0x32d108('0x5af'),_0x3e2c70[_0x32d108('0x734')]=angular[_0x32d108('0x225f')](_0x105578),_0x3e2c70[_0x32d108('0x57a')]=_0x3c23e7,_0x3e2c70['newVariable']=![];!_0x3e2c70[_0x32d108('0x734')]&&(_0x3e2c70[_0x32d108('0x734')]={},_0x3e2c70[_0x32d108('0xcdc')]='TOOLS.NEW_VARIABLE',_0x3e2c70[_0x32d108('0x2839')]=!![]);_0x3e2c70[_0x32d108('0xa49')]=_0x11ba2a,_0x3e2c70[_0x32d108('0x28ec')]=_0x53e82b,_0x3e2c70[_0x32d108('0xa83')]=_0x139a9f,_0x3e2c70[_0x32d108('0x1a9c')]=_0x54a019,_0x3e2c70[_0x32d108('0x24a0')]=_0x5cf67b;function _0x11ba2a(){const _0x2038c4=_0x32d108;_0x3e2c70[_0x2038c4('0x61a')]=[],_0x3a2bd6['variable'][_0x2038c4('0x9cc')](_0x3e2c70[_0x2038c4('0x734')])[_0x2038c4('0xa44')]['then'](function(_0x145c0c){const _0x8f6b30=_0x2038c4;_0x3e2c70[_0x8f6b30('0x57a')][_0x8f6b30('0x2450')](_0x145c0c[_0x8f6b30('0x2876')]()),_0xd88fe1[_0x8f6b30('0x103b')]({'title':_0x8f6b30('0x527'),'msg':_0x3e2c70[_0x8f6b30('0x734')][_0x8f6b30('0x4f0')]?_0x3e2c70[_0x8f6b30('0x734')]['name']+'\x20has\x20been\x20created!':''}),_0x5cf67b(_0x145c0c);})[_0x2038c4('0x1a80')](function(_0x4e5a82){const _0xfebed7=_0x2038c4;if(_0x4e5a82[_0xfebed7('0x25f4')]&&_0x4e5a82[_0xfebed7('0x25f4')][_0xfebed7('0x61a')]&&_0x4e5a82[_0xfebed7('0x25f4')][_0xfebed7('0x61a')][_0xfebed7('0x264b')]){_0x3e2c70['errors']=_0x4e5a82['data'][_0xfebed7('0x61a')]||[{'message':_0x4e5a82[_0xfebed7('0x1586')](),'type':'api.variable.save'}];for(let _0x124c48=0x0;_0x124c48<_0x4e5a82[_0xfebed7('0x25f4')][_0xfebed7('0x61a')][_0xfebed7('0x264b')];_0x124c48+=0x1){_0xd88fe1[_0xfebed7('0xfc9')]({'title':_0x4e5a82[_0xfebed7('0x25f4')][_0xfebed7('0x61a')][_0x124c48][_0xfebed7('0x1345')],'msg':_0x4e5a82[_0xfebed7('0x25f4')][_0xfebed7('0x61a')][_0x124c48]['message']});}}else _0xd88fe1[_0xfebed7('0xfc9')]({'title':_0x4e5a82[_0xfebed7('0x52d')]?_0xfebed7('0x1e21')+_0x4e5a82[_0xfebed7('0x52d')]+'\x20-\x20'+_0x4e5a82[_0xfebed7('0xe1b')]:_0xfebed7('0x2707'),'msg':_0x4e5a82[_0xfebed7('0x25f4')]?JSON[_0xfebed7('0xbac')](_0x4e5a82[_0xfebed7('0x25f4')]['message']):_0x4e5a82['toString']()});});}function _0x53e82b(){const _0x5a2ff9=_0x32d108;_0x3e2c70[_0x5a2ff9('0x61a')]=[],_0x3a2bd6['variable'][_0x5a2ff9('0x1449')]({'id':_0x3e2c70[_0x5a2ff9('0x734')]['id']},_0x3e2c70['variable'])[_0x5a2ff9('0xa44')]['then'](function(_0x4b9228){const _0x5d5340=_0x5a2ff9,_0x140125=_0x2cfb05()['find'](_0x3e2c70[_0x5d5340('0x57a')],{'id':_0x4b9228['id']});_0x140125&&_0x2cfb05()[_0x5d5340('0xcc3')](_0x140125,_0x2cfb05()[_0x5d5340('0x1a08')](_0x4b9228[_0x5d5340('0x2876')](),_0x2cfb05()[_0x5d5340('0x14a4')](_0x140125))),_0xd88fe1['success']({'title':_0x5d5340('0x913'),'msg':_0x3e2c70[_0x5d5340('0x734')][_0x5d5340('0x4f0')]?_0x3e2c70[_0x5d5340('0x734')][_0x5d5340('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x5cf67b(_0x4b9228);})[_0x5a2ff9('0x1a80')](function(_0x2cc677){const _0xab3337=_0x5a2ff9;if(_0x2cc677[_0xab3337('0x25f4')]&&_0x2cc677['data'][_0xab3337('0x61a')]&&_0x2cc677[_0xab3337('0x25f4')]['errors'][_0xab3337('0x264b')]){_0x3e2c70['errors']=_0x2cc677[_0xab3337('0x25f4')]['errors']||[{'message':_0x2cc677[_0xab3337('0x1586')](),'type':_0xab3337('0x141b')}];for(let _0x133e1d=0x0;_0x133e1d<_0x2cc677[_0xab3337('0x25f4')][_0xab3337('0x61a')]['length'];_0x133e1d++){_0xd88fe1[_0xab3337('0xfc9')]({'title':_0x2cc677['data']['errors'][_0x133e1d][_0xab3337('0x1345')],'msg':_0x2cc677['data']['errors'][_0x133e1d]['message']});}}else _0xd88fe1['error']({'title':_0x2cc677['status']?_0xab3337('0x1e21')+_0x2cc677[_0xab3337('0x52d')]+_0xab3337('0x11e1')+_0x2cc677[_0xab3337('0xe1b')]:_0xab3337('0x141b'),'msg':_0x2cc677[_0xab3337('0x25f4')]?JSON[_0xab3337('0xbac')](_0x2cc677[_0xab3337('0x25f4')][_0xab3337('0x1e70')]):_0x2cc677[_0xab3337('0x1586')]()});});}function _0x139a9f(_0x180929){const _0x110292=_0x32d108;_0x3e2c70[_0x110292('0x61a')]=[];const _0x325fd9=_0x3e0a97[_0x110292('0x1d26')]()['title']('Are\x20you\x20sure?')[_0x110292('0xacc')](_0x110292('0xbd'))['ariaLabel'](_0x110292('0x240e'))['ok'](_0x110292('0x18'))[_0x110292('0x3f')](_0x110292('0x497'))[_0x110292('0x203b')](_0x180929);_0x3e0a97[_0x110292('0x1f80')](_0x325fd9)[_0x110292('0x1166')](function(){const _0x42b29c=_0x110292;_0x3a2bd6[_0x42b29c('0x734')][_0x42b29c('0x906')]({'id':_0x3e2c70[_0x42b29c('0x734')]['id']})['$promise'][_0x42b29c('0x1166')](function(){const _0x2dd9f8=_0x42b29c;_0x2cfb05()[_0x2dd9f8('0x127f')](_0x3e2c70[_0x2dd9f8('0x57a')],{'id':_0x3e2c70[_0x2dd9f8('0x734')]['id']}),_0xd88fe1[_0x2dd9f8('0x103b')]({'title':'Variable\x20properly\x20deleted!','msg':(_0x3e2c70[_0x2dd9f8('0x734')][_0x2dd9f8('0x4f0')]||'variable')+'\x20has\x20been\x20deleted!'}),_0x5cf67b(_0x3e2c70[_0x2dd9f8('0x734')]);})[_0x42b29c('0x1a80')](function(_0x139222){const _0x51bcea=_0x42b29c;if(_0x139222[_0x51bcea('0x25f4')]&&_0x139222['data'][_0x51bcea('0x61a')]&&_0x139222[_0x51bcea('0x25f4')][_0x51bcea('0x61a')][_0x51bcea('0x264b')]){_0x3e2c70['errors']=_0x139222[_0x51bcea('0x25f4')][_0x51bcea('0x61a')]||[{'message':_0x139222[_0x51bcea('0x1586')](),'type':'api.variable.delete'}];for(let _0x228226=0x0;_0x228226<_0x139222[_0x51bcea('0x25f4')][_0x51bcea('0x61a')]['length'];_0x228226++){_0xd88fe1[_0x51bcea('0xfc9')]({'title':_0x139222[_0x51bcea('0x25f4')][_0x51bcea('0x61a')][_0x228226][_0x51bcea('0x1345')],'msg':_0x139222[_0x51bcea('0x25f4')][_0x51bcea('0x61a')][_0x228226][_0x51bcea('0x1e70')]});}}else _0xd88fe1[_0x51bcea('0xfc9')]({'title':_0x139222[_0x51bcea('0x52d')]?_0x51bcea('0x1e21')+_0x139222[_0x51bcea('0x52d')]+_0x51bcea('0x11e1')+_0x139222[_0x51bcea('0xe1b')]:_0x51bcea('0x1a60'),'msg':_0x139222['data']?JSON[_0x51bcea('0xbac')](_0x139222['data'][_0x51bcea('0x1e70')]):_0x139222[_0x51bcea('0x1e70')]||_0x139222[_0x51bcea('0x1586')]()});});},function(){});}function _0x54a019(_0x4e21dc){return _0x4e21dc===null?undefined:new Date(_0x4e21dc);}function _0x5cf67b(_0x1d5e7f){_0x3e0a97['hide'](_0x1d5e7f);}}const _0x5bec6d=_0x51980f,_0x13db5a=_0x2734b2['p']+_0x36e6f4('0x1886');_0x4b10c3[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$mdSidenav',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x57a'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x4b10c3(_0x394a22,_0x3f71f7,_0x5906ea,_0x3eeac8,_0x2d2779,_0x1a2ae7,_0x2f94be,_0x137e8a,_0x2b7f37,_0x1e8cc1,_0x1638ea,_0x34f8a0,_0x33f38c,_0x2fecda,_0x1d2215,_0x4d77b0,_0x2c8c04){const _0x3b53fe=_0x36e6f4,_0x2bc87c=this;_0x2bc87c[_0x3b53fe('0x5c9')]=_0x4d77b0,_0x2bc87c['setting']=_0x2c8c04,_0x2bc87c[_0x3b53fe('0x98')]=_0x1d2215['getCurrentUser'](),_0x2bc87c[_0x3b53fe('0x57a')]=_0x2b7f37||{'count':0x0,'rows':[]},_0x2bc87c[_0x3b53fe('0x7f')]=_0x1e8cc1,_0x2bc87c[_0x3b53fe('0x17aa')]=_0x1638ea&&_0x1638ea[_0x3b53fe('0x240f')]==0x1?_0x1638ea['rows'][0x0]:null,_0x2bc87c[_0x3b53fe('0x243c')]=_0x1d2215['parseCrudPermissions'](_0x2bc87c[_0x3b53fe('0x17aa')]?_0x2bc87c['userProfileSection']['crudPermissions']:null),_0x2bc87c[_0x3b53fe('0x916')]=_0x3b53fe('0x57a'),_0x2bc87c['listOrder']='',_0x2bc87c[_0x3b53fe('0x104c')]=null,_0x2bc87c[_0x3b53fe('0x908')]=[],_0x2bc87c[_0x3b53fe('0x2218')]={'fields':_0x3b53fe('0x208e'),'sort':_0x3b53fe('0x14dc'),'limit':0xa,'page':0x1},_0x2bc87c[_0x3b53fe('0x1f8e')]=_0x16bf31,_0x2bc87c[_0x3b53fe('0x8d8')]=_0x5a6b41,_0x2bc87c[_0x3b53fe('0x103b')]=_0x27423f,_0x2bc87c['getVariables']=_0x248479,_0x2bc87c[_0x3b53fe('0x311')]=_0x38189d,_0x2bc87c['deleteVariable']=_0x18684c,_0x2bc87c['exportSelectedVariables']=_0x502fec,_0x2bc87c[_0x3b53fe('0x21cf')]=_0x295103,_0x2bc87c[_0x3b53fe('0x278b')]=_0x4ee7f3,_0x2bc87c[_0x3b53fe('0x1564')]=_0x59e8c0;function _0x16bf31(_0xde49d,_0x4e6951){const _0x1c3b22=_0x3b53fe;_0x2d2779[_0x1c3b22('0x1f80')]({'controller':_0x1c3b22('0x27d0'),'controllerAs':'vm','templateUrl':_0x13db5a,'parent':angular[_0x1c3b22('0x1194')](_0x1a2ae7[_0x1c3b22('0x8d2')]),'targetEvent':_0x4e6951,'clickOutsideToClose':!![],'locals':{'variable':_0xde49d,'variables':_0x2bc87c[_0x1c3b22('0x57a')][_0x1c3b22('0x269a')],'license':_0x2bc87c[_0x1c3b22('0x5c9')],'setting':null,'crudPermissions':_0x2bc87c['crudPermissions']}});}function _0x5a6b41(_0x3b0b3b,_0x6c0c2e){const _0x39baf9=_0x3b53fe,_0x1aa12d=_0x2d2779[_0x39baf9('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x39baf9('0xb35')]('variable')+'?')[_0x39baf9('0xf3c')](''+(_0x3b0b3b['name']||_0x39baf9('0x734'))+_0x39baf9('0xace')+_0x39baf9('0x3f3'))[_0x39baf9('0x8e8')](_0x39baf9('0x1bda'))['targetEvent'](_0x6c0c2e)['ok']('OK')[_0x39baf9('0x3f')](_0x39baf9('0x2d3'));_0x2d2779[_0x39baf9('0x1f80')](_0x1aa12d)[_0x39baf9('0x1166')](function(){_0x18684c(_0x3b0b3b);},function(){const _0x4bc278=_0x39baf9;console[_0x4bc278('0x455')](_0x4bc278('0x2d3'));});}let _0x595e6a=!![],_0x2cac6d=0x1;_0x394a22[_0x3b53fe('0xe83')]('vm.query.filter',function(_0x4c7dbd,_0x50257b){const _0x3e04f3=_0x3b53fe;_0x595e6a?_0x2f94be(function(){_0x595e6a=![];}):(!_0x50257b&&(_0x2cac6d=_0x2bc87c['query']['page']),_0x4c7dbd!==_0x50257b&&(_0x2bc87c[_0x3e04f3('0x2218')]['page']=0x1),!_0x4c7dbd&&(_0x2bc87c['query']['page']=_0x2cac6d),_0x2bc87c[_0x3e04f3('0x19c2')]());});function _0x27423f(_0x487a72){const _0x49b26f=_0x3b53fe;_0x2bc87c[_0x49b26f('0x57a')]=_0x487a72||{'count':0x0,'rows':[]};}function _0x248479(){const _0x50081a=_0x3b53fe;_0x2bc87c[_0x50081a('0x2218')]['offset']=(_0x2bc87c[_0x50081a('0x2218')][_0x50081a('0x1a43')]-0x1)*_0x2bc87c['query'][_0x50081a('0x163f')],_0x1d2215['hasRole']('admin')?_0x2bc87c[_0x50081a('0x1f48')]=_0x34f8a0[_0x50081a('0x734')][_0x50081a('0xd83')](_0x2bc87c['query'],_0x27423f)['$promise']:(_0x2bc87c['query']['id']=_0x2bc87c[_0x50081a('0x7f')]['id'],_0x2bc87c['query'][_0x50081a('0xe60')]='Variables',_0x2bc87c['promise']=_0x34f8a0['userProfile']['getResources'](_0x2bc87c[_0x50081a('0x2218')],_0x27423f)[_0x50081a('0xa44')]);}function _0x38189d(_0x1e68d3,_0x3694b6){const _0x3d791d=_0x3b53fe;_0x2d2779[_0x3d791d('0x1f80')]({'controller':'CreateOrEditVariableDialogController','controllerAs':'vm','templateUrl':_0x13db5a,'parent':angular['element'](_0x1a2ae7[_0x3d791d('0x8d2')]),'targetEvent':_0x1e68d3,'clickOutsideToClose':!![],'locals':{'variable':_0x3694b6,'variables':_0x2bc87c[_0x3d791d('0x57a')][_0x3d791d('0x269a')],'license':_0x2bc87c[_0x3d791d('0x5c9')],'setting':_0x2bc87c[_0x3d791d('0xf8a')],'crudPermissions':_0x2bc87c[_0x3d791d('0x243c')]}});}function _0x18684c(_0x4d5e81){const _0x6cf95f=_0x3b53fe;_0x34f8a0[_0x6cf95f('0x734')][_0x6cf95f('0x906')]({'id':_0x4d5e81['id']})[_0x6cf95f('0xa44')]['then'](function(){const _0x395be8=_0x6cf95f;_0x2cfb05()[_0x395be8('0x127f')](_0x2bc87c[_0x395be8('0x57a')][_0x395be8('0x269a')],{'id':_0x4d5e81['id']}),_0x2bc87c[_0x395be8('0x57a')][_0x395be8('0x240f')]-=0x1,!_0x2bc87c[_0x395be8('0x57a')][_0x395be8('0x269a')]['length']&&_0x2bc87c[_0x395be8('0x19c2')](),_0x2fecda[_0x395be8('0x103b')]({'title':_0x2cfb05()[_0x395be8('0xb35')]('Variable')+_0x395be8('0x2b6'),'msg':_0x4d5e81[_0x395be8('0x4f0')]?_0x4d5e81[_0x395be8('0x4f0')]+_0x395be8('0x7cd'):''});})[_0x6cf95f('0x1a80')](function(_0x55ad46){const _0x264d18=_0x6cf95f;if(_0x55ad46[_0x264d18('0x25f4')]&&_0x55ad46[_0x264d18('0x25f4')][_0x264d18('0x61a')]&&_0x55ad46['data'][_0x264d18('0x61a')][_0x264d18('0x264b')]){_0x2bc87c[_0x264d18('0x61a')]=_0x55ad46[_0x264d18('0x25f4')][_0x264d18('0x61a')]||[{'message':_0x55ad46[_0x264d18('0x1586')](),'type':_0x264d18('0xabf')}];for(let _0x1083f5=0x0;_0x1083f5<_0x55ad46[_0x264d18('0x25f4')][_0x264d18('0x61a')]['length'];_0x1083f5++){_0x2fecda[_0x264d18('0xfc9')]({'title':_0x55ad46[_0x264d18('0x25f4')][_0x264d18('0x61a')][_0x1083f5][_0x264d18('0x1345')],'msg':_0x55ad46['data'][_0x264d18('0x61a')][_0x1083f5][_0x264d18('0x1e70')]});}}else _0x2fecda[_0x264d18('0xfc9')]({'title':_0x55ad46['status']?_0x264d18('0x1e21')+_0x55ad46[_0x264d18('0x52d')]+_0x264d18('0x11e1')+_0x55ad46[_0x264d18('0xe1b')]:'SYSTEM:DELETEvariable','msg':_0x55ad46[_0x264d18('0x25f4')]?JSON[_0x264d18('0xbac')](_0x55ad46[_0x264d18('0x25f4')]['message']):_0x55ad46[_0x264d18('0x1e70')]||_0x55ad46[_0x264d18('0x1586')]()});});}function _0x502fec(){const _0x188ff2=_0x3b53fe,_0x144ad0=angular[_0x188ff2('0x225f')](_0x2bc87c[_0x188ff2('0x908')]);return _0x2bc87c[_0x188ff2('0x908')]=[],_0x144ad0;}function _0x295103(_0x4d8174){const _0x14e3e9=_0x3b53fe,_0x442d43=_0x2d2779['confirm']()[_0x14e3e9('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20variables?')[_0x14e3e9('0xf3c')](''+_0x2bc87c['selectedVariables'][_0x14e3e9('0x264b')]+'\x20selected'+_0x14e3e9('0x3f3'))[_0x14e3e9('0x8e8')](_0x14e3e9('0x1a76'))[_0x14e3e9('0x203b')](_0x4d8174)['ok']('OK')['cancel'](_0x14e3e9('0x2d3'));_0x2d2779[_0x14e3e9('0x1f80')](_0x442d43)[_0x14e3e9('0x1166')](function(){const _0x278287=_0x14e3e9;_0x2bc87c[_0x278287('0x908')][_0x278287('0x2782')](function(_0x453938){_0x18684c(_0x453938);}),_0x2bc87c['selectedVariables']=[];});}function _0x4ee7f3(){_0x2bc87c['selectedVariables']=[];}function _0x59e8c0(){const _0x227da1=_0x3b53fe;_0x2bc87c[_0x227da1('0x908')]=_0x2bc87c[_0x227da1('0x57a')][_0x227da1('0x269a')];}}const _0x1cbf18=_0x4b10c3;_0x247dad[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x247dad(_0x18fd67,_0x204905){const _0x29a5a0=_0x36e6f4;_0x18fd67[_0x29a5a0('0x63f')](_0x29a5a0('0x19af'),{'abstract':!![],'url':_0x29a5a0('0x105e')})[_0x29a5a0('0x63f')](_0x29a5a0('0x1a46'),{'url':_0x29a5a0('0x2106'),'views':{'content@app':{'templateUrl':_0x13cb55,'controller':_0x29a5a0('0x2512')}},'resolve':{'cannedAnswers':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x3e21d7,_0x57e8d4){const _0x4a301e=_0x29a5a0;return _0x57e8d4[_0x4a301e('0x1ac6')](_0x4a301e('0xa7c'))?_0x3e21d7[_0x4a301e('0x18af')]('cannedAnswer@get',{'fields':_0x4a301e('0x1b4'),'sort':_0x4a301e('0x14dc'),'MailAccountId':'null','FaxAccountId':_0x4a301e('0x15d7'),'SmsAccountId':_0x4a301e('0x15d7'),'OpenchannelAccountId':'null','ChatWebsiteId':_0x4a301e('0x15d7'),'limit':0xa,'offset':0x0}):_0x3e21d7[_0x4a301e('0x18af')]('userProfile@getResources',{'id':_0x57e8d4[_0x4a301e('0x26cd')]()[_0x4a301e('0xb86')],'section':_0x4a301e('0x160f'),'fields':'createdAt,updatedAt,id,key,value,description','sort':'-updatedAt','MailAccountId':_0x4a301e('0x15d7'),'FaxAccountId':_0x4a301e('0x15d7'),'SmsAccountId':_0x4a301e('0x15d7'),'OpenchannelAccountId':_0x4a301e('0x15d7'),'ChatWebsiteId':_0x4a301e('0x15d7'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x4e83bc,_0x4eb402){const _0xcbd626=_0x29a5a0;return _0x4eb402['hasRole']('admin')?null:_0x4e83bc[_0xcbd626('0x18af')](_0xcbd626('0x697'),{'fields':_0xcbd626('0x686'),'id':_0x4eb402[_0xcbd626('0x26cd')]()[_0xcbd626('0xb86')]});}],'userProfileSection':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x352622,_0x273fc5){const _0x57bb1c=_0x29a5a0;return _0x273fc5['hasRole'](_0x57bb1c('0xa7c'))?null:_0x352622['resolve'](_0x57bb1c('0xaf'),{'fields':_0x57bb1c('0xe26'),'userProfileId':_0x273fc5[_0x57bb1c('0x26cd')]()[_0x57bb1c('0xb86')],'sectionId':0x3e9});}]},'authenticate':!![],'permissionId':0x3e9,'bodyClass':_0x29a5a0('0x28e6')})[_0x29a5a0('0x63f')](_0x29a5a0('0x977'),{'url':_0x29a5a0('0x341'),'views':{'content@app':{'templateUrl':_0x670f00,'controller':_0x29a5a0('0xf3e')}},'resolve':{'customDashboards':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x178ba,_0x2d0070){const _0x1c735b=_0x29a5a0;return _0x2d0070[_0x1c735b('0x1ac6')](_0x1c735b('0xa7c'))?_0x178ba[_0x1c735b('0x18af')](_0x1c735b('0x442'),{'fields':'createdAt,updatedAt,id,name,description','sort':_0x1c735b('0x14dc'),'limit':0xa,'offset':0x0}):_0x178ba[_0x1c735b('0x18af')]('userProfile@getResources',{'id':_0x2d0070[_0x1c735b('0x26cd')]()[_0x1c735b('0xb86')],'section':_0x1c735b('0x1fc2'),'fields':_0x1c735b('0x208e'),'sort':_0x1c735b('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver','Auth',function(_0x5f0661,_0xdbce12){const _0x8dc974=_0x29a5a0;return _0xdbce12[_0x8dc974('0x1ac6')](_0x8dc974('0xa7c'))?null:_0x5f0661['resolve'](_0x8dc974('0x697'),{'fields':_0x8dc974('0x686'),'id':_0xdbce12[_0x8dc974('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x525de6,_0x2d9d44){const _0x1c1881=_0x29a5a0;return _0x2d9d44[_0x1c1881('0x1ac6')](_0x1c1881('0xa7c'))?null:_0x525de6[_0x1c1881('0x18af')]('userProfileSection@get',{'fields':_0x1c1881('0xe26'),'userProfileId':_0x2d9d44[_0x1c1881('0x26cd')]()[_0x1c1881('0xb86')],'sectionId':0x3eb});}]},'authenticate':!![],'permissionId':0x3eb,'bodyClass':_0x29a5a0('0x28e6')})[_0x29a5a0('0x63f')]('app.tools.customDashboards.edit',{'url':_0x29a5a0('0x2233'),'params':{'customDashboard':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x424c0b,'controller':_0x29a5a0('0x86f')}},'resolve':{'customDashboard':[_0x29a5a0('0x1fbc'),'$stateParams',function(_0x544793,_0x568635){const _0xc368d3=_0x29a5a0;return _0x544793['resolve'](_0xc368d3('0x442'),{'fields':'createdAt,updatedAt,id,name,description','id':_0x568635['id']});}],'userProfileSection':['apiResolver',_0x29a5a0('0x21ef'),function(_0x173a9c,_0x474c20){const _0x161d66=_0x29a5a0;return _0x173a9c[_0x161d66('0x18af')]('userProfileSection@get',{'fields':_0x161d66('0xe26'),'userProfileId':_0x474c20[_0x161d66('0x26cd')]()[_0x161d66('0xb86')],'sectionId':0x3eb});}]},'authenticate':!![],'permissionId':0x3eb,'bodyClass':'tools'})[_0x29a5a0('0x63f')]('app.tools.intervals',{'url':_0x29a5a0('0x540'),'views':{'content@app':{'templateUrl':_0x3cae5c,'controller':_0x29a5a0('0x1e7f')}},'resolve':{'intervals':[_0x29a5a0('0x1fbc'),'Auth',function(_0xe4a5f9,_0x518f00){const _0x4be0cf=_0x29a5a0;return _0x518f00[_0x4be0cf('0x1ac6')](_0x4be0cf('0xa7c'))?_0xe4a5f9['resolve'](_0x4be0cf('0x145f'),{'fields':_0x4be0cf('0x208e'),'sort':_0x4be0cf('0x14dc'),'IntervalId':_0x4be0cf('0x15d7'),'limit':0xa,'offset':0x0}):_0xe4a5f9['resolve'](_0x4be0cf('0x17c4'),{'id':_0x518f00[_0x4be0cf('0x26cd')]()[_0x4be0cf('0xb86')],'section':'Intervals','fields':'createdAt,updatedAt,id,name,description','sort':_0x4be0cf('0x14dc'),'IntervalId':_0x4be0cf('0x15d7'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x487821,_0x22e78b){const _0x40d919=_0x29a5a0;return _0x22e78b[_0x40d919('0x1ac6')](_0x40d919('0xa7c'))?null:_0x487821[_0x40d919('0x18af')](_0x40d919('0x697'),{'fields':'id,name,crudPermissions','id':_0x22e78b[_0x40d919('0x26cd')]()[_0x40d919('0xb86')]});}],'userProfileSection':['apiResolver',_0x29a5a0('0x21ef'),function(_0x137053,_0x273b75){const _0x5bb068=_0x29a5a0;return _0x273b75['hasRole'](_0x5bb068('0xa7c'))?null:_0x137053[_0x5bb068('0x18af')](_0x5bb068('0xaf'),{'fields':_0x5bb068('0xe26'),'userProfileId':_0x273b75[_0x5bb068('0x26cd')]()[_0x5bb068('0xb86')],'sectionId':0x3ec});}]},'authenticate':!![],'permissionId':0x3ec,'bodyClass':_0x29a5a0('0x28e6')})['state'](_0x29a5a0('0x2e9'),{'url':_0x29a5a0('0x2233'),'params':{'interval':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x20e5fd,'controller':'IntervalController\x20as\x20vm'}},'resolve':{'interval':[_0x29a5a0('0x1fbc'),_0x29a5a0('0xf75'),function(_0x38b0aa,_0x3ebde8){const _0x49c340=_0x29a5a0;return _0x38b0aa[_0x49c340('0x18af')]('interval@get',{'fields':'createdAt,updatedAt,id,name,description','id':_0x3ebde8['id']});}],'userProfileSection':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x554f1e,_0x214246){const _0x5f3815=_0x29a5a0;return _0x554f1e[_0x5f3815('0x18af')](_0x5f3815('0xaf'),{'fields':_0x5f3815('0xe26'),'userProfileId':_0x214246[_0x5f3815('0x26cd')]()[_0x5f3815('0xb86')],'sectionId':0x3ec});}]},'authenticate':!![],'permissionId':0x3ec,'bodyClass':'tools'})['state'](_0x29a5a0('0x62d'),{'url':_0x29a5a0('0x72c'),'views':{'content@app':{'templateUrl':_0x2842e9,'controller':_0x29a5a0('0x1d3')}},'resolve':{'pauses':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x290949,_0x400de6){const _0x5161e0=_0x29a5a0;return _0x400de6[_0x5161e0('0x1ac6')](_0x5161e0('0xa7c'))?_0x290949[_0x5161e0('0x18af')](_0x5161e0('0x737'),{'fields':_0x5161e0('0x208e'),'sort':_0x5161e0('0x14dc'),'limit':0xa,'offset':0x0}):_0x290949[_0x5161e0('0x18af')](_0x5161e0('0x17c4'),{'id':_0x400de6[_0x5161e0('0x26cd')]()['userProfileId'],'section':_0x5161e0('0x1377'),'fields':_0x5161e0('0x208e'),'sort':_0x5161e0('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x356d85,_0x4bf516){const _0x7f5ac1=_0x29a5a0;return _0x4bf516[_0x7f5ac1('0x1ac6')](_0x7f5ac1('0xa7c'))?null:_0x356d85[_0x7f5ac1('0x18af')](_0x7f5ac1('0x697'),{'fields':_0x7f5ac1('0x686'),'id':_0x4bf516[_0x7f5ac1('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x3a1caa,_0x3ab1fb){const _0x554353=_0x29a5a0;return _0x3ab1fb[_0x554353('0x1ac6')](_0x554353('0xa7c'))?null:_0x3a1caa['resolve']('userProfileSection@get',{'fields':_0x554353('0xe26'),'userProfileId':_0x3ab1fb[_0x554353('0x26cd')]()['userProfileId'],'sectionId':0x3ed});}]},'authenticate':!![],'permissionId':0x3ed,'bodyClass':_0x29a5a0('0x28e6')})[_0x29a5a0('0x63f')](_0x29a5a0('0x1711'),{'url':_0x29a5a0('0x1df8'),'views':{'content@app':{'templateUrl':_0x5bb3d4,'controller':_0x29a5a0('0x6d5')}},'resolve':{'schedules':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x43d8ea,_0x34a992){const _0x89998d=_0x29a5a0;return _0x34a992[_0x89998d('0x1ac6')](_0x89998d('0xa7c'))?_0x43d8ea[_0x89998d('0x18af')](_0x89998d('0x172c'),{'fields':_0x89998d('0xc5e'),'sort':_0x89998d('0x14dc'),'limit':0xa,'offset':0x0}):_0x43d8ea[_0x89998d('0x18af')](_0x89998d('0x17c4'),{'id':_0x34a992[_0x89998d('0x26cd')]()[_0x89998d('0xb86')],'section':_0x89998d('0x2ab'),'fields':'createdAt,updatedAt,id,name,CustomReportId,DefaultReportId,output,active,startAt,endAt,cron,subtractNumber,subtractUnit,sendMail,MailAccountId,email,cc,bcc,sendIfEmpty,description','sort':_0x89998d('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x12250d,_0x845f6b){const _0x5a50a2=_0x29a5a0;return _0x845f6b['hasRole'](_0x5a50a2('0xa7c'))?null:_0x12250d[_0x5a50a2('0x18af')](_0x5a50a2('0x697'),{'fields':'id,name,crudPermissions','id':_0x845f6b[_0x5a50a2('0x26cd')]()[_0x5a50a2('0xb86')]});}],'userProfileSection':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x5efd53,_0x5747dc){const _0xc42abf=_0x29a5a0;return _0x5747dc[_0xc42abf('0x1ac6')]('admin')?null:_0x5efd53[_0xc42abf('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5747dc[_0xc42abf('0x26cd')]()[_0xc42abf('0xb86')],'sectionId':0x3ee});}]},'authenticate':!![],'permissionId':0x3ee,'bodyClass':_0x29a5a0('0x28e6')})[_0x29a5a0('0x63f')]('app.tools.sounds',{'url':_0x29a5a0('0x1232'),'views':{'content@app':{'templateUrl':_0x329e81,'controller':_0x29a5a0('0xe35')}},'resolve':{'sounds':[_0x29a5a0('0x1fbc'),'Auth',function(_0x2e41b3,_0x139494){const _0x353518=_0x29a5a0;return _0x139494['hasRole'](_0x353518('0xa7c'))?_0x2e41b3[_0x353518('0x18af')](_0x353518('0xd8a'),{'fields':_0x353518('0x1b0c'),'sort':_0x353518('0x14dc'),'limit':0xa,'offset':0x0}):_0x2e41b3[_0x353518('0x18af')](_0x353518('0x17c4'),{'id':_0x139494[_0x353518('0x26cd')]()[_0x353518('0xb86')],'section':_0x353518('0x1ece'),'fields':'createdAt,updatedAt,id,save_name,converted_format,name,audio,description','sort':_0x353518('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver','Auth',function(_0x34544c,_0x5abdc4){const _0x48a11d=_0x29a5a0;return _0x5abdc4[_0x48a11d('0x1ac6')](_0x48a11d('0xa7c'))?null:_0x34544c[_0x48a11d('0x18af')](_0x48a11d('0x697'),{'fields':_0x48a11d('0x686'),'id':_0x5abdc4[_0x48a11d('0x26cd')]()[_0x48a11d('0xb86')]});}],'userProfileSection':['apiResolver',_0x29a5a0('0x21ef'),function(_0x1e72ec,_0x1e822b){const _0x5a758d=_0x29a5a0;return _0x1e822b[_0x5a758d('0x1ac6')](_0x5a758d('0xa7c'))?null:_0x1e72ec[_0x5a758d('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x1e822b['getCurrentUser']()[_0x5a758d('0xb86')],'sectionId':0x3ef});}]},'authenticate':!![],'permissionId':0x3ef,'bodyClass':_0x29a5a0('0x28e6')})[_0x29a5a0('0x63f')]('app.tools.tags',{'url':'/tags','views':{'content@app':{'templateUrl':_0x2f2ab8,'controller':'TagsController\x20as\x20vm'}},'resolve':{'tags':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x26b307,_0x2fed1b){const _0x23d468=_0x29a5a0;return _0x2fed1b[_0x23d468('0x1ac6')](_0x23d468('0xa7c'))?_0x26b307['resolve']('tag@get',{'fields':_0x23d468('0xb26'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x26b307[_0x23d468('0x18af')](_0x23d468('0x17c4'),{'id':_0x2fed1b[_0x23d468('0x26cd')]()[_0x23d468('0xb86')],'section':'Tags','fields':_0x23d468('0xb26'),'sort':_0x23d468('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x29a5a0('0x21ef'),function(_0x20652e,_0x27d5e7){const _0x53c5cf=_0x29a5a0;return _0x27d5e7[_0x53c5cf('0x1ac6')]('admin')?null:_0x20652e[_0x53c5cf('0x18af')](_0x53c5cf('0x697'),{'fields':_0x53c5cf('0x686'),'id':_0x27d5e7['getCurrentUser']()['userProfileId']});}],'userProfileSection':['apiResolver','Auth',function(_0x5d46b,_0x185506){const _0x2e2f37=_0x29a5a0;return _0x185506[_0x2e2f37('0x1ac6')](_0x2e2f37('0xa7c'))?null:_0x5d46b['resolve']('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x185506[_0x2e2f37('0x26cd')]()[_0x2e2f37('0xb86')],'sectionId':0x3f0});}]},'authenticate':!![],'permissionId':0x3f0,'bodyClass':_0x29a5a0('0x28e6')})['state'](_0x29a5a0('0x13f4'),{'url':'/templates','views':{'content@app':{'templateUrl':_0x4882dd,'controller':_0x29a5a0('0x4d4')}},'resolve':{'templates':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x472338,_0x520e67){const _0x522fa2=_0x29a5a0;return _0x520e67['hasRole'](_0x522fa2('0xa7c'))?_0x472338[_0x522fa2('0x18af')]('template@get',{'fields':_0x522fa2('0x18d4'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x472338['resolve'](_0x522fa2('0x17c4'),{'id':_0x520e67[_0x522fa2('0x26cd')]()[_0x522fa2('0xb86')],'section':'Templates','fields':_0x522fa2('0x18d4'),'sort':_0x522fa2('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x29a5a0('0x21ef'),function(_0x814065,_0x532256){const _0x26aa86=_0x29a5a0;return _0x532256[_0x26aa86('0x1ac6')](_0x26aa86('0xa7c'))?null:_0x814065[_0x26aa86('0x18af')](_0x26aa86('0x697'),{'fields':_0x26aa86('0x686'),'id':_0x532256[_0x26aa86('0x26cd')]()[_0x26aa86('0xb86')]});}],'userProfileSection':['apiResolver',_0x29a5a0('0x21ef'),function(_0x499408,_0x1fb932){const _0x345879=_0x29a5a0;return _0x1fb932[_0x345879('0x1ac6')](_0x345879('0xa7c'))?null:_0x499408[_0x345879('0x18af')]('userProfileSection@get',{'fields':_0x345879('0xe26'),'userProfileId':_0x1fb932[_0x345879('0x26cd')]()[_0x345879('0xb86')],'sectionId':0x3f1});}]},'authenticate':!![],'permissionId':0x3f1,'bodyClass':'tools'})[_0x29a5a0('0x63f')](_0x29a5a0('0x108d'),{'url':_0x29a5a0('0x1994'),'views':{'content@app':{'templateUrl':_0x140d71,'controller':'TrunksController\x20as\x20vm'}},'resolve':{'trunks':['apiResolver',_0x29a5a0('0x21ef'),function(_0x2e956d,_0x2fd68a){const _0x3b9e93=_0x29a5a0;return _0x2fd68a['hasRole'](_0x3b9e93('0xa7c'))?_0x2e956d[_0x3b9e93('0x18af')](_0x3b9e93('0xfb8'),{'fields':_0x3b9e93('0x2f9'),'sort':_0x3b9e93('0x14dc'),'limit':0xa,'offset':0x0}):_0x2e956d['resolve'](_0x3b9e93('0x17c4'),{'id':_0x2fd68a[_0x3b9e93('0x26cd')]()[_0x3b9e93('0xb86')],'section':_0x3b9e93('0x2685'),'fields':_0x3b9e93('0x2f9'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x29a5a0('0x21ef'),function(_0x1c02bd,_0x1e1b62){const _0x1e4bf4=_0x29a5a0;return _0x1e1b62[_0x1e4bf4('0x1ac6')]('admin')?null:_0x1c02bd[_0x1e4bf4('0x18af')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x1e1b62['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x587e0a,_0x5347b4){const _0xb4a76f=_0x29a5a0;return _0x5347b4[_0xb4a76f('0x1ac6')](_0xb4a76f('0xa7c'))?null:_0x587e0a[_0xb4a76f('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5347b4[_0xb4a76f('0x26cd')]()[_0xb4a76f('0xb86')],'sectionId':0x3f3});}]},'authenticate':!![],'permissionId':0x3f3,'bodyClass':_0x29a5a0('0x28e6')})[_0x29a5a0('0x63f')](_0x29a5a0('0x1f20'),{'url':_0x29a5a0('0x2233'),'params':{'trunk':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x5bde5a,'controller':_0x29a5a0('0x338')}},'resolve':{'trunk':['apiResolver',_0x29a5a0('0xf75'),function(_0x349672,_0x11ecfe){const _0x2ee3fa=_0x29a5a0;return _0x349672['resolve'](_0x2ee3fa('0xfb8'),{'fields':_0x2ee3fa('0x2f9'),'id':_0x11ecfe['id']});}],'userProfileSection':['apiResolver',_0x29a5a0('0x21ef'),function(_0xca3c1c,_0x4ebcf1){const _0x114298=_0x29a5a0;return _0xca3c1c['resolve'](_0x114298('0xaf'),{'fields':_0x114298('0xe26'),'userProfileId':_0x4ebcf1[_0x114298('0x26cd')]()[_0x114298('0xb86')],'sectionId':0x3f3});}]},'authenticate':!![],'permissionId':0x3f3,'bodyClass':_0x29a5a0('0x28e6')})[_0x29a5a0('0x63f')](_0x29a5a0('0x1d75'),{'url':_0x29a5a0('0x247e'),'views':{'content@app':{'templateUrl':_0x54906c,'controller':_0x29a5a0('0x2486')}},'resolve':{'variables':['apiResolver',_0x29a5a0('0x21ef'),function(_0x130997,_0x5c908f){const _0x8a8f56=_0x29a5a0;return _0x5c908f[_0x8a8f56('0x1ac6')]('admin')?_0x130997['resolve'](_0x8a8f56('0x185a'),{'fields':_0x8a8f56('0x208e'),'sort':_0x8a8f56('0x14dc'),'limit':0xa,'offset':0x0}):_0x130997['resolve'](_0x8a8f56('0x17c4'),{'id':_0x5c908f[_0x8a8f56('0x26cd')]()['userProfileId'],'section':'Variables','fields':_0x8a8f56('0x208e'),'sort':_0x8a8f56('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x29a5a0('0x21ef'),function(_0x5aa914,_0x4abbe8){const _0x49185c=_0x29a5a0;return _0x4abbe8['hasRole']('admin')?null:_0x5aa914['resolve'](_0x49185c('0x697'),{'fields':_0x49185c('0x686'),'id':_0x4abbe8['getCurrentUser']()[_0x49185c('0xb86')]});}],'userProfileSection':[_0x29a5a0('0x1fbc'),_0x29a5a0('0x21ef'),function(_0x4ba80e,_0x45892d){const _0xd26597=_0x29a5a0;return _0x45892d[_0xd26597('0x1ac6')](_0xd26597('0xa7c'))?null:_0x4ba80e[_0xd26597('0x18af')](_0xd26597('0xaf'),{'fields':_0xd26597('0xe26'),'userProfileId':_0x45892d['getCurrentUser']()['userProfileId'],'sectionId':0x3f4});}]},'authenticate':!![],'permissionId':0x3f4,'bodyClass':_0x29a5a0('0x28e6')}),_0x204905[_0x29a5a0('0x95e')]('app/main/apps/tools');}angular[_0x36e6f4('0x896')](_0x36e6f4('0x19af'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),'flow',_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),'angular-cron-jobs',_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),'material.components.expansionPanels',_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),_0x36e6f4('0x17eb'),_0x36e6f4('0x1e20')])[_0x36e6f4('0xe11')](_0x247dad)[_0x36e6f4('0x75e')](_0x36e6f4('0xea2'),_0x5e85d2)['controller'](_0x36e6f4('0x1948'),_0xd6349b)[_0x36e6f4('0x75e')](_0x36e6f4('0xb92'),_0x123879)['controller'](_0x36e6f4('0x7c4'),_0x15de14)['controller'](_0x36e6f4('0x268a'),_0x3b26d2)[_0x36e6f4('0x75e')](_0x36e6f4('0x226c'),_0x47089b)['controller'](_0x36e6f4('0x1606'),_0x4562a6)['controller'](_0x36e6f4('0x398'),_0x3bd291)[_0x36e6f4('0x75e')](_0x36e6f4('0x77'),_0x509036)[_0x36e6f4('0x75e')]('EditAppintervalDialogController',_0x4cb4df)[_0x36e6f4('0x75e')](_0x36e6f4('0x276b'),_0x118b1b)['controller'](_0x36e6f4('0x713'),_0xe82b43)[_0x36e6f4('0x75e')](_0x36e6f4('0x23fd'),_0x563b82)['controller'](_0x36e6f4('0x12e1'),_0x44d8e2)[_0x36e6f4('0x75e')]('PausesController',_0x3a2502)['controller']('CreateOrEditScheduleDialogController',_0xbdfb4b)[_0x36e6f4('0x75e')](_0x36e6f4('0x85f'),_0x4c9b32)[_0x36e6f4('0x75e')](_0x36e6f4('0x1817'),_0x56a1b3)[_0x36e6f4('0x75e')](_0x36e6f4('0x6e2'),_0x3b87f3)[_0x36e6f4('0x75e')](_0x36e6f4('0x1a72'),_0x3e1d75)[_0x36e6f4('0x75e')](_0x36e6f4('0x2307'),_0x3e87c5)[_0x36e6f4('0x75e')](_0x36e6f4('0x1aa0'),_0xe59a7e)['controller'](_0x36e6f4('0xe2d'),_0x4c7132)[_0x36e6f4('0x75e')](_0x36e6f4('0x27d7'),_0x505010)[_0x36e6f4('0x75e')](_0x36e6f4('0x1930'),_0x50d6ff)[_0x36e6f4('0x75e')](_0x36e6f4('0x1cd7'),_0xd334f1)['controller']('TrunkController',_0x2d7d0c)[_0x36e6f4('0x75e')](_0x36e6f4('0x258d'),_0x297694)[_0x36e6f4('0x75e')](_0x36e6f4('0x27d0'),_0x5bec6d)[_0x36e6f4('0x75e')](_0x36e6f4('0xb8f'),_0x1cbf18);const _0x5293b2=_0x2734b2['p']+_0x36e6f4('0x26c5'),_0x4d11f6=_0x2734b2['p']+'src/js/modules/main/apps/callysquare/views/projects/edit/view.html/view.html';_0x419773[_0x36e6f4('0x1294')]=['$mdDialog',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x21ef'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x149f'),_0x36e6f4('0x2588'),_0x36e6f4('0x19e3'),_0x36e6f4('0x10e6'),_0x36e6f4('0x243c')];function _0x419773(_0x1de038,_0x3eb0e4,_0x27044e,_0x496559,_0x2fba38,_0x409b54,_0x320d1c,_0x14e555,_0x30b41d,_0x4f998f,_0x19fe8e){const _0x4f9372=_0x36e6f4,_0x3bfe35=this;_0x3bfe35[_0x4f9372('0x61a')]=[],_0x3bfe35['title']=_0x4f9372('0xf94'),_0x3bfe35[_0x4f9372('0x243c')]=_0x19fe8e,_0x3bfe35[_0x4f9372('0x2588')]=angular[_0x4f9372('0x225f')](_0x14e555),_0x3bfe35[_0x4f9372('0x1869')]=!![],_0x3bfe35[_0x4f9372('0x149f')]=_0x320d1c,_0x3bfe35[_0x4f9372('0x5e0')]=![],_0x3bfe35[_0x4f9372('0x10e6')]=_0x4f998f;!_0x3bfe35[_0x4f9372('0x2588')]&&(_0x3bfe35[_0x4f9372('0x2588')]={'name':'','description':''},_0x3bfe35[_0x4f9372('0xcdc')]=_0x4f9372('0x1134'),_0x3bfe35[_0x4f9372('0x5e0')]=!![]);_0x3bfe35['addNewProject']=_0x1e0caa,_0x3bfe35[_0x4f9372('0x16c1')]=_0xbfb8f,_0x3bfe35['deleteProject']=_0x47d3fd,_0x3bfe35['closeDialog']=_0x49e8d3;function _0x1e0caa(){const _0x28423b=_0x4f9372;_0x3bfe35['errors']=[],_0x30b41d[_0x28423b('0x7e4')][_0x28423b('0x9cc')](_0x3bfe35[_0x28423b('0x2588')])[_0x28423b('0xa44')][_0x28423b('0x1166')](function(_0x2dc00f){const _0x34b5a0=_0x28423b;return _0x30b41d['user']['addSquareProjects']({'id':_0x2fba38['getCurrentUser']()['id'],'ids':[_0x2dc00f['id']]})[_0x34b5a0('0xa44')],_0x2dc00f;})['then'](function(_0xf7d2a6){const _0x1ae6e2=_0x28423b;_0x3bfe35[_0x1ae6e2('0x149f')][_0x1ae6e2('0x2450')](_0xf7d2a6),_0x409b54[_0x1ae6e2('0x103b')]({'title':_0x1ae6e2('0x1694'),'msg':_0x3bfe35[_0x1ae6e2('0x2588')][_0x1ae6e2('0x4f0')]?_0x3bfe35[_0x1ae6e2('0x2588')]['name']+'\x20has\x20been\x20created!':''}),_0x49e8d3(_0xf7d2a6),_0x3bfe35[_0x1ae6e2('0x10e6')]&&(_0x3bfe35[_0x1ae6e2('0x1869')]?_0x3eb0e4['open'](_0x1ae6e2('0x1f39')+_0xf7d2a6['id'],_0x1ae6e2('0x180c')):_0x27044e['go'](_0x1ae6e2('0x23a3'),{'id':_0xf7d2a6['id']}));})[_0x28423b('0x1a80')](function(_0x33c30a){const _0x261bbc=_0x28423b;if(_0x33c30a['data']&&_0x33c30a[_0x261bbc('0x25f4')][_0x261bbc('0x61a')]&&_0x33c30a[_0x261bbc('0x25f4')]['errors']['length']){_0x3bfe35[_0x261bbc('0x61a')]=_0x33c30a['data'][_0x261bbc('0x61a')]||[{'message':_0x33c30a[_0x261bbc('0x1586')](),'type':'api.squareProject.save'}];for(let _0x41db94=0x0;_0x41db94<_0x33c30a['data'][_0x261bbc('0x61a')][_0x261bbc('0x264b')];_0x41db94++){_0x409b54[_0x261bbc('0xfc9')]({'title':_0x33c30a[_0x261bbc('0x25f4')]['errors'][_0x41db94][_0x261bbc('0x1345')],'msg':_0x33c30a[_0x261bbc('0x25f4')][_0x261bbc('0x61a')][_0x41db94]['message']});}}else _0x409b54[_0x261bbc('0xfc9')]({'title':_0x33c30a[_0x261bbc('0x52d')]?_0x261bbc('0x1e21')+_0x33c30a['status']+'\x20-\x20'+_0x33c30a[_0x261bbc('0xe1b')]:_0x261bbc('0x2613'),'msg':_0x33c30a[_0x261bbc('0x25f4')]?JSON[_0x261bbc('0xbac')](_0x33c30a[_0x261bbc('0x25f4')][_0x261bbc('0x1e70')]):_0x33c30a[_0x261bbc('0x1586')]()});});}function _0xbfb8f(){const _0x364689=_0x4f9372;_0x3bfe35[_0x364689('0x61a')]=[],_0x30b41d[_0x364689('0x7e4')][_0x364689('0x1449')]({'id':_0x3bfe35[_0x364689('0x2588')]['id']},_0x3bfe35[_0x364689('0x2588')])[_0x364689('0xa44')][_0x364689('0x1166')](function(_0x470ec2){const _0xf4304b=_0x364689,_0x86ae23=_0x2cfb05()[_0xf4304b('0xc38')](_0x3bfe35['projects'],{'id':_0x470ec2['id']});_0x86ae23&&_0x2cfb05()[_0xf4304b('0xcc3')](_0x86ae23,_0x470ec2),_0x409b54[_0xf4304b('0x103b')]({'title':_0xf4304b('0xb2f'),'msg':_0x3bfe35[_0xf4304b('0x2588')]['name']?_0x3bfe35['project'][_0xf4304b('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x49e8d3(_0x470ec2);})['catch'](function(_0x4968a9){const _0x4c4241=_0x364689;if(_0x4968a9[_0x4c4241('0x25f4')]&&_0x4968a9[_0x4c4241('0x25f4')][_0x4c4241('0x61a')]&&_0x4968a9['data']['errors'][_0x4c4241('0x264b')]){_0x3bfe35[_0x4c4241('0x61a')]=_0x4968a9[_0x4c4241('0x25f4')][_0x4c4241('0x61a')]||[{'message':_0x4968a9[_0x4c4241('0x1586')](),'type':_0x4c4241('0x2447')}];for(let _0x12ba5e=0x0;_0x12ba5e<_0x4968a9[_0x4c4241('0x25f4')]['errors'][_0x4c4241('0x264b')];_0x12ba5e++){_0x409b54[_0x4c4241('0xfc9')]({'title':_0x4968a9[_0x4c4241('0x25f4')][_0x4c4241('0x61a')][_0x12ba5e][_0x4c4241('0x1345')],'msg':_0x4968a9[_0x4c4241('0x25f4')][_0x4c4241('0x61a')][_0x12ba5e][_0x4c4241('0x1e70')]});}}else _0x409b54[_0x4c4241('0xfc9')]({'title':_0x4968a9[_0x4c4241('0x52d')]?_0x4c4241('0x1e21')+_0x4968a9[_0x4c4241('0x52d')]+_0x4c4241('0x11e1')+_0x4968a9['statusText']:_0x4c4241('0x2447'),'msg':_0x4968a9[_0x4c4241('0x25f4')]?JSON[_0x4c4241('0xbac')](_0x4968a9['data'][_0x4c4241('0x1e70')]):_0x4968a9[_0x4c4241('0x1586')]()});});}function _0x47d3fd(){const _0x2ceec3=_0x4f9372;_0x3bfe35[_0x2ceec3('0x61a')]=[];const _0x5255b4=_0x1de038[_0x2ceec3('0x1d26')]()[_0x2ceec3('0xcdc')](_0x2ceec3('0x7fb'))[_0x2ceec3('0xacc')]('The\x20project\x20will\x20be\x20deleted.')['ariaLabel']('Delete\x20Project')['ok']('Delete')[_0x2ceec3('0x3f')](_0x2ceec3('0x497'))['targetEvent'](event);_0x1de038[_0x2ceec3('0x1f80')](_0x5255b4)[_0x2ceec3('0x1166')](function(){const _0x32a6cd=_0x2ceec3;_0x30b41d[_0x32a6cd('0x7e4')][_0x32a6cd('0x906')]({'id':_0x3bfe35[_0x32a6cd('0x2588')]['id']})['$promise'][_0x32a6cd('0x1166')](function(){const _0x3185dc=_0x32a6cd;return _0x30b41d['squareProject'][_0x3185dc('0x1bcb')]({'id':_0x3bfe35[_0x3185dc('0x2588')]['id']})['$promise'];})[_0x32a6cd('0x1166')](function(_0x2c5611){const _0x501aa3=_0x32a6cd,_0x33ca13=[],_0x5edd1e=_0x2c5611[_0x501aa3('0x269a')];for(let _0x33a101=0x0;_0x33a101<_0x5edd1e[_0x501aa3('0x264b')];_0x33a101++){_0x33ca13[_0x501aa3('0x1514')](_0x30b41d[_0x501aa3('0x557')][_0x501aa3('0x24c1')]({'id':_0x2fba38[_0x501aa3('0x26cd')]()['id'],'ids':[_0x3bfe35[_0x501aa3('0x2588')]['id']]})[_0x501aa3('0xa44')]);}return _0x496559['all'](_0x33ca13);})['then'](function(){const _0x1ec1eb=_0x32a6cd;_0x2cfb05()[_0x1ec1eb('0x127f')](_0x3bfe35[_0x1ec1eb('0x149f')],{'id':_0x3bfe35[_0x1ec1eb('0x2588')]['id']}),_0x409b54[_0x1ec1eb('0x103b')]({'title':_0x1ec1eb('0x31a'),'msg':_0x3bfe35[_0x1ec1eb('0x2588')][_0x1ec1eb('0x4f0')]?_0x3bfe35[_0x1ec1eb('0x2588')][_0x1ec1eb('0x4f0')]+'\x20has\x20been\x20deleted!':''}),_0x49e8d3(_0x3bfe35['project']);})[_0x32a6cd('0x1a80')](function(_0x3c4b4a){const _0xfbcf03=_0x32a6cd;console['error'](_0x3c4b4a),_0x3bfe35[_0xfbcf03('0x61a')]=_0x3c4b4a['data'][_0xfbcf03('0x61a')]||[{'message':_0x3c4b4a[_0xfbcf03('0x1586')](),'type':'api.squareProject.delete'}];});},function(){});}function _0x49e8d3(_0x3eab5d){const _0x360de8=_0x4f9372;_0x1de038[_0x360de8('0x1197')](_0x3eab5d);}}const _0x21154a=_0x419773;_0x58231f['$inject']=[_0x36e6f4('0x265d'),'api',_0x36e6f4('0x1d2e'),_0x36e6f4('0x266'),'ispeechAsrLanguage',_0x36e6f4('0x1cc4'),_0x36e6f4('0x16b6'),_0x36e6f4('0x88'),_0x36e6f4('0x342'),'users',_0x36e6f4('0xf24'),_0x36e6f4('0x7a7'),_0x36e6f4('0x137'),_0x36e6f4('0x57a'),_0x36e6f4('0xd24'),'projects','contexts',_0x36e6f4('0x164e'),_0x36e6f4('0xf85'),'templates','lists',_0x36e6f4('0x43'),_0x36e6f4('0x24e5'),_0x36e6f4('0xd63'),'awsPollyRegion',_0x36e6f4('0x1d76'),_0x36e6f4('0xe29'),_0x36e6f4('0xeb1'),_0x36e6f4('0x1962'),_0x36e6f4('0x1b04'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x58231f(_0x3fa493,_0x5d6383,_0x2882f7,_0x4a4681,_0x5e98c8,_0x3fa8d8,_0x1eaa01,_0x27985f,_0x55e40e,_0x294e4e,_0x42e4f2,_0xf8ba6b,_0x14901b,_0x1ef3ed,_0x20f6e2,_0x486cee,_0x359a66,_0xb81e5,_0x44d588,_0xe95562,_0x18c908,_0x5695c3,_0x157ab6,_0x41b711,_0x38cd2c,_0x4a77a0,_0x2095ef,_0x10465d,_0x1d3da2,_0x3dbff7,_0x5afc0a,_0x12c1d2){const _0x3228e9=_0x36e6f4,_0xd9ebf0=this,_0x37c950={'playback':[_0x3228e9('0x103f')],'answer':['timeout'],'menu':['file_id',_0x3228e9('0x11f0'),_0x3228e9('0x2717'),_0x3228e9('0x1868')],'getdigits':[_0x3228e9('0x103f'),_0x3228e9('0x25cf'),_0x3228e9('0xee0'),_0x3228e9('0x25'),'retry'],'getsecretdigits':[_0x3228e9('0x103f'),_0x3228e9('0x25cf'),_0x3228e9('0xee0'),_0x3228e9('0x25'),'hiddendigitsnum',_0x3228e9('0x1868')],'vswitch':[_0x3228e9('0x25cf')],'database':[_0x3228e9('0x22e2'),_0x3228e9('0x2218')],'ext_dial':[_0x3228e9('0xb81'),_0x3228e9('0x2026'),_0x3228e9('0x651')],'set':[_0x3228e9('0x25cf')],'math':[_0x3228e9('0x25cf')],'gotoc':[_0x3228e9('0xe1c'),_0x3228e9('0x1ed1'),_0x3228e9('0xfde')],'system':[_0x3228e9('0x187')],'agi':['command'],'gotoif':[_0x3228e9('0x8ff')],'saydigits':[_0x3228e9('0x754')],'saynumber':[_0x3228e9('0xc45')],'sayphonetic':[_0x3228e9('0x1640')],'record':[_0x3228e9('0x6bd'),_0x3228e9('0x651')],'goal':[_0x3228e9('0x247d')],'dial':[_0x3228e9('0x15dd'),_0x3228e9('0x651')],'queue':['queue_id',_0x3228e9('0x651')],'callback':[_0x3228e9('0x19ec'),_0x3228e9('0x4f0'),_0x3228e9('0x2026'),_0x3228e9('0x1ca9')],'gotoiftime':['interval_id'],'voicemail':[_0x3228e9('0x1cfc')],'subproject':[_0x3228e9('0x1147')],'sendSMS':[_0x3228e9('0x140e'),'to',_0x3228e9('0xe69')],'sendMail':['account_id','to'],'sendFax':[_0x3228e9('0x11f5'),'to',_0x3228e9('0x1b87')],'google_cloud_tts':[_0x3228e9('0x1a04'),'google_cloud_tts_text_type',_0x3228e9('0x1640')],'tts':[_0x3228e9('0x1640')],'ispeechtts':[_0x3228e9('0x1640'),'key',_0x3228e9('0x17da')],'ispeechasr':[_0x3228e9('0x7ca'),_0x3228e9('0x651')],'custom_app':['application'],'googleasr':[_0x3228e9('0x7ca'),_0x3228e9('0x651')],'awspolly':[_0x3228e9('0xb60'),_0x3228e9('0x4c6'),'text','aws_text_type'],'lumenvoxtts':[_0x3228e9('0x1640')],'sestektts':[_0x3228e9('0x1640')],'lumenvoxasr':[_0x3228e9('0x1fa9')],'sestekasr':[_0x3228e9('0x1fa9')],'tildeasr':[_0x3228e9('0x1d13'),_0x3228e9('0x602'),_0x3228e9('0x19ed')],'login':[_0x3228e9('0x250d')],'pause':['findBy',_0x3228e9('0x181f')],'unpause':['findBy'],'logout':['findBy'],'dialogflow':[_0x3228e9('0x7ca'),_0x3228e9('0x1640'),_0x3228e9('0x120f')],'awslex':['aws_access_key_id',_0x3228e9('0x4c6'),_0x3228e9('0xcea'),_0x3228e9('0x1d27'),_0x3228e9('0x1640')],'sesteknda':[_0x3228e9('0x1640'),'ndauth_url',_0x3228e9('0x1b97'),_0x3228e9('0x26e8'),_0x3228e9('0x199f')],'restapi':[_0x3228e9('0xcac'),_0x3228e9('0xa50')],'mrcpsynth':['text'],'mrcprecog':[_0x3228e9('0x1fa9')],'dialogflowV2':['dialogflowV2_project_id',_0x3228e9('0x24af'),_0x3228e9('0x146f'),'dialogflowV2_language',_0x3228e9('0x1640')]},_0x24da0b={'queue':[_0x3228e9('0x103f')],'database':['variable_id'],'pause':[_0x3228e9('0x181f')]},_0x458529={'sendMail':['to','cc',_0x3228e9('0x209')],'voicemail':[_0x3228e9('0x1cfc')]};_0xd9ebf0['cellName']=_0x5695c3[_0x3228e9('0x13e9')],_0xd9ebf0[_0x3228e9('0x27db')]=_0x2cfb05()[_0x3228e9('0x2563')](_0x5695c3[_0x3228e9('0x27db')],function(_0x4ce917){const _0x196192=_0x3228e9;return{'name':_0x4ce917[_0x196192('0x4f0')],'value':_0x4ce917[_0x196192('0x18e0')],'defaultValue':_0x24da0b[_0xd9ebf0['cellName']]&&_0x2cfb05()[_0x196192('0x1257')](_0x24da0b[_0xd9ebf0[_0x196192('0x141e')]],_0x4ce917['name']),'required':_0x37c950[_0xd9ebf0['cellName']]&&_0x2cfb05()['includes'](_0x37c950[_0xd9ebf0[_0x196192('0x141e')]],_0x4ce917[_0x196192('0x4f0')]),'help':_0x458529[_0xd9ebf0[_0x196192('0x141e')]]&&_0x2cfb05()['includes'](_0x458529[_0xd9ebf0[_0x196192('0x141e')]],_0x4ce917[_0x196192('0x4f0')])};}),_0xd9ebf0[_0x3228e9('0x1ac1')]={'authMethod':[{'value':_0x3228e9('0x17a9'),'option':_0x3228e9('0x252a')},{'value':_0x3228e9('0x1b4e'),'option':_0x3228e9('0x22ca')}],'answer':[{'value':_0x3228e9('0x55d'),'option':_0x3228e9('0x193c')},{'value':'no','option':'No'}],'ndagenerate_audio':[{'value':0x1,'option':_0x3228e9('0x193c')},{'value':0x0,'option':'No'}],'ndaactivity_type':[{'value':'message','option':_0x3228e9('0x1720')},{'value':_0x3228e9('0xbf'),'option':_0x3228e9('0x91f')},{'value':_0x3228e9('0xa62'),'option':'Contact\x20Relation\x20Update'},{'value':_0x3228e9('0x1dee'),'option':_0x3228e9('0x381')}],'hiddendigitspos':[{'value':_0x3228e9('0x215c'),'option':_0x3228e9('0x177')},{'value':_0x3228e9('0x1ef5'),'option':_0x3228e9('0x10d6')}],'recordingFormat':[{'value':_0x3228e9('0xdef'),'option':_0x3228e9('0x15d9')},{'value':'gsm','option':_0x3228e9('0xaea')}],'intkey':[{'value':'#','option':'#'},{'value':'*','option':'*'}],'beep':[{'value':_0x3228e9('0x11df'),'option':_0x3228e9('0x193c')},{'value':_0x3228e9('0x2670'),'option':'No'}],'model':_0x4a4681,'ispeech_asr_language':_0x5e98c8,'ispeech_tts_language':_0x1eaa01,'languageCode':_0x27985f,'ssmlGender':[{'value':_0x3228e9('0x27d4'),'option':_0x3228e9('0x184f')},{'value':_0x3228e9('0x1476'),'option':'Male'}],'google_tts_language':_0x55e40e,'google_asr_language':_0x3fa8d8,'google_cloud_tts_text_type':[{'value':_0x3228e9('0x1640'),'option':'Text'},{'value':'ssml','option':_0x3228e9('0x279c')}],'aws_polly_region':_0x38cd2c,'aws_polly_voice':_0x41b711,'aws_text_type':[{'value':_0x3228e9('0x1640'),'option':_0x3228e9('0xef7')},{'value':_0x3228e9('0x1d15'),'option':'SSML'}],'callback_priority':[{'option':'Highest','value':0x4},{'option':_0x3228e9('0xf95'),'value':0x3},{'option':'Medium','value':0x2},{'option':_0x3228e9('0x2572'),'value':0x1},{'option':'Lowest','value':0x0}],'findBy':[{'value':'internal','option':_0x3228e9('0xb48')},{'value':_0x3228e9('0x2026'),'option':'Phone'},{'value':_0x3228e9('0x2459'),'option':'Mobile'}],'dialogflow_language':_0x10465d,'dialogflowV2_language':_0x1d3da2,'aws_lex_region':_0x3dbff7,'method':[{'value':'GET','option':_0x3228e9('0x1d65')},{'value':'POST','option':_0x3228e9('0x1c72')},{'value':_0x3228e9('0xc9d'),'option':_0x3228e9('0xc9d')},{'value':_0x3228e9('0x1f3a'),'option':_0x3228e9('0x1f3a')}]},_0xd9ebf0['crudPermissions']=_0x12c1d2,_0xd9ebf0[_0x3228e9('0xae0')]=_0x35ba61,_0xd9ebf0[_0x3228e9('0x24a0')]=_0x2d6cdb,_0xd9ebf0[_0x3228e9('0x1631')]=_0x21dcf8;function _0x35ba61(){const _0x2ced03=_0x3228e9;_0x5afc0a[_0x2ced03('0x1ac6')]('admin')?_0x2ef5a9():_0x123980();}function _0x21dcf8(_0x1af8e8,_0x58ac58,_0x50c341,_0x56d4b8){const _0x1abf25=_0x3228e9;return _0x2cfb05()[_0x1abf25('0x2563')](_0x1af8e8,function(_0x4d631d){const _0xa0428a=_0x1abf25;return{'value':_0x4d631d[_0x58ac58],'option':_0x4d631d[_0x50c341],'group':_0x56d4b8?_0x4d631d[_0x56d4b8]:undefined,'canSelect':typeof _0x4d631d[_0xa0428a('0x2378')]!=='undefined'?_0x4d631d[_0xa0428a('0x2378')]:!![]};});}function _0x2b61c0(_0x50ed0d,_0x2ed5cf,_0x40ba2c,_0x3046e5){const _0x306c88=_0x3228e9,_0x3a533d=_0x2cfb05()[_0x306c88('0x1c33')](_0x50ed0d,function(_0x404e9e){return _0x404e9e[_0x3046e5]===null;}),_0x48f7d6=[];return _0x2cfb05()[_0x306c88('0x2782')](_0x3a533d,function(_0x157663){const _0x599d58=_0x306c88;_0x48f7d6[_0x599d58('0x1514')]({'value':_0x157663[_0x2ed5cf],'option':_0x157663[_0x40ba2c]});const _0x3a1ca8=_0x2cfb05()['filter'](_0x50ed0d,function(_0x50bbb6){return _0x50bbb6[_0x3046e5]===_0x157663['id'];});_0x2cfb05()['forEach'](_0x3a1ca8,function(_0x2236a5){const _0x2b525f=_0x599d58;_0x48f7d6[_0x2b525f('0x1514')]({'value':_0x2236a5[_0x2ed5cf],'option':_0x2b525f('0x11e1')+_0x2236a5[_0x40ba2c]});});}),_0x48f7d6;}function _0x2ef5a9(){const _0x2d2f46=_0x3228e9,_0x462432={'sip_id':_0x21dcf8(_0x294e4e,'id',_0x2d2f46('0x6e1'),_0x2d2f46('0x1e75')),'trunk_name':_0x21dcf8(_0x42e4f2,'name','name'),'trunk_id':_0x21dcf8(_0x42e4f2,'id',_0x2d2f46('0x4f0')),'queue_id':_0x21dcf8(_0xf8ba6b,'id',_0x2d2f46('0x4f0')),'file_id':_0x21dcf8(_0x14901b,'id',_0x2d2f46('0x4f0')),'variable_id':_0x21dcf8(_0x1ef3ed,'id',_0x2d2f46('0x4f0')),'odbc_id':_0x21dcf8(_0x20f6e2,'id',_0x2d2f46('0x4f0')),'project_id':_0x21dcf8(_0x486cee,'id',_0x2d2f46('0x4f0')),'context':_0x21dcf8(_0x359a66,'id',_0x2d2f46('0x4f0')),'interval_id':_0x2b61c0(_0xb81e5,'id',_0x2d2f46('0x4f0'),_0x2d2f46('0x186f')),'account_id':_0x21dcf8(_0x44d588,'id',_0x2d2f46('0x4f0')),'template_id':_0x21dcf8(_0xe95562,'id',_0x2d2f46('0x4f0')),'list_id':_0x21dcf8(_0x18c908,'id',_0x2d2f46('0x4f0')),'sms_account_id':_0x21dcf8(_0x4a77a0,'id',_0x2d2f46('0x4f0')),'pause_id':_0x21dcf8(_0x2095ef,'id',_0x2d2f46('0x4f0'))},_0x5a3bd2=_0x2cfb05()['merge'](_0xd9ebf0[_0x2d2f46('0x1ac1')],_0x462432);_0xd9ebf0[_0x2d2f46('0x1ac1')]=_0x5a3bd2;}function _0x123980(){const _0xb52e6=_0x3228e9,_0x54995d=[_0xb52e6('0x15dd'),_0xb52e6('0xb81'),_0xb52e6('0x103'),_0xb52e6('0x1e04'),_0xb52e6('0x103f'),'variable_id',_0xb52e6('0x22e2'),_0xb52e6('0x1147'),_0xb52e6('0xe1c'),_0xb52e6('0x237e'),_0xb52e6('0x11f5'),'template_id',_0xb52e6('0x19ec'),_0xb52e6('0x140e'),_0xb52e6('0x181f')];for(let _0x2193ec=0x0;_0x2193ec<_0xd9ebf0[_0xb52e6('0x27db')][_0xb52e6('0x264b')];_0x2193ec++){if(_0x2cfb05()['includes'](_0x54995d,_0xd9ebf0[_0xb52e6('0x27db')][_0x2193ec]['name']))switch(_0xd9ebf0[_0xb52e6('0x27db')][_0x2193ec]['name']){case _0xb52e6('0x15dd'):_0x33cc0d();break;case'trunk_name':_0x46a6bf();break;case _0xb52e6('0x103'):_0x42f817();break;case _0xb52e6('0x1e04'):_0x52578b();break;case'file_id':_0x2a77c7();break;case'variable_id':_0x53cb64();break;case'odbc_id':_0x41a11f();break;case _0xb52e6('0x1147'):_0x259547();break;case _0xb52e6('0xe1c'):_0x3bd91e();break;case _0xb52e6('0x237e'):_0x421e57();break;case _0xb52e6('0x11f5'):_0x37ec27();break;case'template_id':_0x4146ef();break;case'list_id':_0x5d4fa0();break;case'sms_account_id':_0x242102();break;case _0xb52e6('0x181f'):_0x99d234();break;}}}function _0x33cc0d(){const _0x4f6397=_0x3228e9,_0x37bac3=Number(_0x2cfb05()[_0x4f6397('0xc38')](_0xd9ebf0['attributes'],{'name':_0x4f6397('0x15dd')})[_0x4f6397('0x18e0')]),_0x162265=_0x2cfb05()[_0x4f6397('0x1798')](_0x294e4e,{'id':_0x37bac3});if(!_0x162265&&_0x37bac3>0x0)return _0x5d6383['user'][_0x4f6397('0xd83')]({'id':_0x37bac3,'fields':_0x4f6397('0x5d2')})[_0x4f6397('0xa44')][_0x4f6397('0x1166')](function(_0x44a9ff){const _0x202210=_0x4f6397,_0x384637=_0x44a9ff['toJSON']();_0x384637[_0x202210('0x2378')]=![],_0x294e4e['push'](_0x384637),_0xd9ebf0[_0x202210('0x1ac1')][_0x202210('0x15dd')]=_0x21dcf8(_0x294e4e,'id','fullname',_0x202210('0x1e75'));})['catch'](function(_0x2d5ed5){const _0x85e5e8=_0x4f6397;_0x2882f7[_0x85e5e8('0xfc9')]({'title':_0x2d5ed5[_0x85e5e8('0x52d')]?'API:'+_0x2d5ed5[_0x85e5e8('0x52d')]+'\x20-\x20'+_0x2d5ed5['statusText']:_0x85e5e8('0x1f84'),'msg':_0x2d5ed5[_0x85e5e8('0x25f4')]?JSON[_0x85e5e8('0xbac')](_0x2d5ed5[_0x85e5e8('0x25f4')][_0x85e5e8('0x1e70')]):_0x2d5ed5[_0x85e5e8('0x1586')]()});});else _0xd9ebf0[_0x4f6397('0x1ac1')]['sip_id']=_0x21dcf8(_0x294e4e,'id',_0x4f6397('0x6e1'),_0x4f6397('0x1e75'));}function _0x5d4fa0(){const _0x3e54f8=_0x3228e9,_0x441be4=Number(_0x2cfb05()[_0x3e54f8('0xc38')](_0xd9ebf0[_0x3e54f8('0x27db')],{'name':_0x3e54f8('0x19ec')})[_0x3e54f8('0x18e0')]),_0x170424=_0x2cfb05()[_0x3e54f8('0x1798')](_0x18c908,{'id':_0x441be4});if(!_0x170424&&_0x441be4>0x0)return _0x5d6383[_0x3e54f8('0xdd9')][_0x3e54f8('0xd83')]({'id':_0x441be4,'fields':_0x3e54f8('0x1776')})[_0x3e54f8('0xa44')][_0x3e54f8('0x1166')](function(_0x35343c){const _0x1e65b5=_0x3e54f8,_0x403f4a=_0x35343c[_0x1e65b5('0x2876')]();_0x403f4a[_0x1e65b5('0x2378')]=![],_0x18c908['push'](_0x403f4a),_0xd9ebf0[_0x1e65b5('0x1ac1')][_0x1e65b5('0x19ec')]=_0x21dcf8(_0x18c908,'id','name');})['catch'](function(_0x5b4e98){const _0x1d2686=_0x3e54f8;_0x2882f7[_0x1d2686('0xfc9')]({'title':_0x5b4e98[_0x1d2686('0x52d')]?_0x1d2686('0x1e21')+_0x5b4e98[_0x1d2686('0x52d')]+_0x1d2686('0x11e1')+_0x5b4e98[_0x1d2686('0xe1b')]:'GET_LIST','msg':_0x5b4e98['data']?JSON[_0x1d2686('0xbac')](_0x5b4e98[_0x1d2686('0x25f4')][_0x1d2686('0x1e70')]):_0x5b4e98[_0x1d2686('0x1586')]()});});else _0xd9ebf0[_0x3e54f8('0x1ac1')][_0x3e54f8('0x19ec')]=_0x21dcf8(_0x18c908,'id','name');}function _0x42f817(){const _0x1dfb09=_0x3228e9,_0x1805b8=Number(_0x2cfb05()['find'](_0xd9ebf0[_0x1dfb09('0x27db')],{'name':'trunk_id'})[_0x1dfb09('0x18e0')]),_0x49fe61=_0x2cfb05()[_0x1dfb09('0x1798')](_0x42e4f2,{'id':_0x1805b8});if(!_0x49fe61&&_0x1805b8>0x0)return _0x5d6383[_0x1dfb09('0x3b2')][_0x1dfb09('0xd83')]({'id':_0x1805b8,'fields':_0x1dfb09('0x1776')})[_0x1dfb09('0xa44')][_0x1dfb09('0x1166')](function(_0x369e2d){const _0x539ff7=_0x1dfb09,_0x524120=_0x369e2d[_0x539ff7('0x2876')]();_0x524120[_0x539ff7('0x2378')]=![],_0x42e4f2['push'](_0x524120),_0xd9ebf0[_0x539ff7('0x1ac1')][_0x539ff7('0x103')]=_0x21dcf8(_0x42e4f2,'id','name');})['catch'](function(_0x16f0e8){const _0xc0a9b6=_0x1dfb09;_0x2882f7['error']({'title':_0x16f0e8['status']?'API:'+_0x16f0e8['status']+_0xc0a9b6('0x11e1')+_0x16f0e8[_0xc0a9b6('0xe1b')]:_0xc0a9b6('0x7c5'),'msg':_0x16f0e8['data']?JSON[_0xc0a9b6('0xbac')](_0x16f0e8[_0xc0a9b6('0x25f4')][_0xc0a9b6('0x1e70')]):_0x16f0e8['toString']()});});else _0xd9ebf0[_0x1dfb09('0x1ac1')]['trunk_id']=_0x21dcf8(_0x42e4f2,'id',_0x1dfb09('0x4f0'));}function _0x46a6bf(){const _0x114038=_0x3228e9,_0x3dde84=_0x2cfb05()[_0x114038('0xc38')](_0xd9ebf0[_0x114038('0x27db')],{'name':_0x114038('0xb81')})[_0x114038('0x18e0')],_0x16263f=_0x2cfb05()[_0x114038('0x1798')](_0x42e4f2,{'name':_0x3dde84});if(!_0x16263f&&_0x3dde84)return _0x5d6383[_0x114038('0x3b2')]['get']({'name':_0x3dde84,'fields':_0x114038('0x1776')})['$promise'][_0x114038('0x1166')](function(_0x13ec99){const _0x3dbbad=_0x114038;if(_0x13ec99[_0x3dbbad('0x240f')]>0x0&&_0x13ec99[_0x3dbbad('0x269a')][_0x3dbbad('0x264b')]>0x0){const _0x5538cb=_0x13ec99['rows'][0x0];_0x5538cb[_0x3dbbad('0x2378')]=![],_0x42e4f2[_0x3dbbad('0x1514')](_0x5538cb),_0xd9ebf0[_0x3dbbad('0x1ac1')][_0x3dbbad('0xb81')]=_0x21dcf8(_0x42e4f2,_0x3dbbad('0x4f0'),_0x3dbbad('0x4f0'));}})['catch'](function(_0x4968f5){const _0x14a1a2=_0x114038;_0x2882f7[_0x14a1a2('0xfc9')]({'title':_0x4968f5['status']?_0x14a1a2('0x1e21')+_0x4968f5[_0x14a1a2('0x52d')]+_0x14a1a2('0x11e1')+_0x4968f5['statusText']:_0x14a1a2('0x7c5'),'msg':_0x4968f5[_0x14a1a2('0x25f4')]?JSON['stringify'](_0x4968f5[_0x14a1a2('0x25f4')][_0x14a1a2('0x1e70')]):_0x4968f5[_0x14a1a2('0x1586')]()});});else _0xd9ebf0[_0x114038('0x1ac1')][_0x114038('0xb81')]=_0x21dcf8(_0x42e4f2,_0x114038('0x4f0'),_0x114038('0x4f0'));}function _0x52578b(){const _0x3abacc=_0x3228e9,_0x2330be=Number(_0x2cfb05()[_0x3abacc('0xc38')](_0xd9ebf0[_0x3abacc('0x27db')],{'name':_0x3abacc('0x1e04')})[_0x3abacc('0x18e0')]),_0x1a2d16=_0x2cfb05()['some'](_0xf8ba6b,{'id':_0x2330be});if(!_0x1a2d16&&_0x2330be>0x0)return _0x5d6383[_0x3abacc('0x1943')][_0x3abacc('0xd83')]({'id':_0x2330be,'fields':_0x3abacc('0x1776')})[_0x3abacc('0xa44')][_0x3abacc('0x1166')](function(_0x32b9da){const _0x4aca44=_0x3abacc,_0x197481=_0x32b9da['toJSON']();_0x197481[_0x4aca44('0x2378')]=![],_0xf8ba6b[_0x4aca44('0x1514')](_0x197481),_0xd9ebf0[_0x4aca44('0x1ac1')][_0x4aca44('0x1e04')]=_0x21dcf8(_0xf8ba6b,'id',_0x4aca44('0x4f0'));})['catch'](function(_0xf9dc1b){const _0x1aa0ef=_0x3abacc;_0x2882f7[_0x1aa0ef('0xfc9')]({'title':_0xf9dc1b['status']?_0x1aa0ef('0x1e21')+_0xf9dc1b[_0x1aa0ef('0x52d')]+'\x20-\x20'+_0xf9dc1b[_0x1aa0ef('0xe1b')]:_0x1aa0ef('0x30d'),'msg':_0xf9dc1b[_0x1aa0ef('0x25f4')]?JSON[_0x1aa0ef('0xbac')](_0xf9dc1b[_0x1aa0ef('0x25f4')]['message']):_0xf9dc1b[_0x1aa0ef('0x1586')]()});});else _0xd9ebf0[_0x3abacc('0x1ac1')][_0x3abacc('0x1e04')]=_0x21dcf8(_0xf8ba6b,'id','name');}function _0x2a77c7(){const _0x31bece=_0x3228e9,_0x3b0ca5=Number(_0x2cfb05()[_0x31bece('0xc38')](_0xd9ebf0[_0x31bece('0x27db')],{'name':_0x31bece('0x103f')})[_0x31bece('0x18e0')]),_0x5cb7ea=_0x2cfb05()[_0x31bece('0x1798')](_0x14901b,{'id':_0x3b0ca5});if(!_0x5cb7ea&&_0x3b0ca5>0x0)return _0x5d6383[_0x31bece('0x960')][_0x31bece('0xd83')]({'id':_0x3b0ca5,'fields':_0x31bece('0x1776')})[_0x31bece('0xa44')][_0x31bece('0x1166')](function(_0x588fb1){const _0x2bb772=_0x31bece,_0x315d86=_0x588fb1[_0x2bb772('0x2876')]();_0x315d86[_0x2bb772('0x2378')]=![],_0x14901b[_0x2bb772('0x1514')](_0x315d86),_0xd9ebf0[_0x2bb772('0x1ac1')][_0x2bb772('0x103f')]=_0x21dcf8(_0x14901b,'id',_0x2bb772('0x4f0'));})[_0x31bece('0x1a80')](function(_0x4dc01e){const _0x42ba05=_0x31bece;_0x2882f7['error']({'title':_0x4dc01e['status']?'API:'+_0x4dc01e['status']+'\x20-\x20'+_0x4dc01e[_0x42ba05('0xe1b')]:'GET_SOUND','msg':_0x4dc01e['data']?JSON[_0x42ba05('0xbac')](_0x4dc01e[_0x42ba05('0x25f4')][_0x42ba05('0x1e70')]):_0x4dc01e[_0x42ba05('0x1586')]()});});else _0xd9ebf0[_0x31bece('0x1ac1')][_0x31bece('0x103f')]=_0x21dcf8(_0x14901b,'id','name');}function _0x53cb64(){const _0x3117a5=_0x3228e9,_0x3a8e7=Number(_0x2cfb05()[_0x3117a5('0xc38')](_0xd9ebf0[_0x3117a5('0x27db')],{'name':'variable_id'})['value']),_0x2b0e4b=_0x2cfb05()[_0x3117a5('0x1798')](_0x1ef3ed,{'id':_0x3a8e7});if(!_0x2b0e4b&&_0x3a8e7>0x0)return _0x5d6383['variable'][_0x3117a5('0xd83')]({'id':_0x3a8e7,'fields':'id,name'})[_0x3117a5('0xa44')][_0x3117a5('0x1166')](function(_0x11907b){const _0x5c5975=_0x3117a5,_0x31ab23=_0x11907b[_0x5c5975('0x2876')]();_0x31ab23[_0x5c5975('0x2378')]=![],_0x1ef3ed[_0x5c5975('0x1514')](_0x31ab23),_0xd9ebf0['values']['variable_id']=_0x21dcf8(_0x1ef3ed,'id',_0x5c5975('0x4f0'));})[_0x3117a5('0x1a80')](function(_0x2b6b5a){const _0x3ac18a=_0x3117a5;_0x2882f7[_0x3ac18a('0xfc9')]({'title':_0x2b6b5a['status']?_0x3ac18a('0x1e21')+_0x2b6b5a[_0x3ac18a('0x52d')]+_0x3ac18a('0x11e1')+_0x2b6b5a[_0x3ac18a('0xe1b')]:_0x3ac18a('0x615'),'msg':_0x2b6b5a['data']?JSON['stringify'](_0x2b6b5a[_0x3ac18a('0x25f4')][_0x3ac18a('0x1e70')]):_0x2b6b5a['toString']()});});else _0xd9ebf0[_0x3117a5('0x1ac1')][_0x3117a5('0x25cf')]=_0x21dcf8(_0x1ef3ed,'id',_0x3117a5('0x4f0'));}function _0x41a11f(){const _0x1f087a=_0x3228e9,_0x2687fd=Number(_0x2cfb05()['find'](_0xd9ebf0['attributes'],{'name':_0x1f087a('0x22e2')})[_0x1f087a('0x18e0')]),_0x2a539b=_0x2cfb05()[_0x1f087a('0x1798')](_0x20f6e2,{'id':_0x2687fd});if(!_0x2a539b&&_0x2687fd>0x0)return _0x5d6383[_0x1f087a('0xb7b')][_0x1f087a('0xd83')]({'id':_0x2687fd,'fields':'id,name'})[_0x1f087a('0xa44')][_0x1f087a('0x1166')](function(_0x2350a3){const _0x53e575=_0x1f087a,_0x56c985=_0x2350a3[_0x53e575('0x2876')]();_0x56c985[_0x53e575('0x2378')]=![],_0x20f6e2[_0x53e575('0x1514')](_0x56c985),_0xd9ebf0[_0x53e575('0x1ac1')][_0x53e575('0x22e2')]=_0x21dcf8(_0x20f6e2,'id',_0x53e575('0x4f0'));})[_0x1f087a('0x1a80')](function(_0x167c18){const _0x4b4356=_0x1f087a;_0x2882f7[_0x4b4356('0xfc9')]({'title':_0x167c18[_0x4b4356('0x52d')]?_0x4b4356('0x1e21')+_0x167c18[_0x4b4356('0x52d')]+_0x4b4356('0x11e1')+_0x167c18[_0x4b4356('0xe1b')]:_0x4b4356('0x1ab7'),'msg':_0x167c18[_0x4b4356('0x25f4')]?JSON[_0x4b4356('0xbac')](_0x167c18[_0x4b4356('0x25f4')][_0x4b4356('0x1e70')]):_0x167c18['toString']()});});else _0xd9ebf0[_0x1f087a('0x1ac1')][_0x1f087a('0x22e2')]=_0x21dcf8(_0x20f6e2,'id',_0x1f087a('0x4f0'));}function _0x259547(){const _0x1a8938=_0x3228e9,_0x1f7aad=Number(_0x2cfb05()[_0x1a8938('0xc38')](_0xd9ebf0['attributes'],{'name':_0x1a8938('0x1147')})[_0x1a8938('0x18e0')]),_0x42abb3=_0x2cfb05()[_0x1a8938('0x1798')](_0x486cee,{'id':_0x1f7aad});if(!_0x42abb3&&_0x1f7aad>0x0)return _0x5d6383[_0x1a8938('0x7e4')][_0x1a8938('0xd83')]({'id':_0x1f7aad,'fields':_0x1a8938('0x1776')})[_0x1a8938('0xa44')][_0x1a8938('0x1166')](function(_0x18f533){const _0x1d1990=_0x1a8938,_0x45910a=_0x18f533[_0x1d1990('0x2876')]();_0x45910a['canSelect']=![],_0x486cee[_0x1d1990('0x1514')](_0x45910a),_0xd9ebf0['values'][_0x1d1990('0x1147')]=_0x21dcf8(_0x486cee,'id',_0x1d1990('0x4f0'));})[_0x1a8938('0x1a80')](function(_0x2a0032){const _0x32c253=_0x1a8938;_0x2882f7[_0x32c253('0xfc9')]({'title':_0x2a0032[_0x32c253('0x52d')]?_0x32c253('0x1e21')+_0x2a0032['status']+'\x20-\x20'+_0x2a0032[_0x32c253('0xe1b')]:_0x32c253('0x12e0'),'msg':_0x2a0032[_0x32c253('0x25f4')]?JSON['stringify'](_0x2a0032['data'][_0x32c253('0x1e70')]):_0x2a0032[_0x32c253('0x1586')]()});});else _0xd9ebf0[_0x1a8938('0x1ac1')][_0x1a8938('0x1147')]=_0x21dcf8(_0x486cee,'id',_0x1a8938('0x4f0'));}function _0x3bd91e(){const _0x19d206=_0x3228e9,_0xe1c4ee=Number(_0x2cfb05()[_0x19d206('0xc38')](_0xd9ebf0['attributes'],{'name':_0x19d206('0xe1c')})[_0x19d206('0x18e0')]),_0x1e88e5=_0x2cfb05()[_0x19d206('0x1798')](_0x359a66,{'id':_0xe1c4ee});if(!_0x1e88e5&&_0xe1c4ee>0x0)return _0x5d6383[_0x19d206('0x23b1')][_0x19d206('0xd83')]({'id':_0xe1c4ee,'fields':_0x19d206('0x1776')})['$promise'][_0x19d206('0x1166')](function(_0x3b0aa3){const _0x1828db=_0x19d206,_0x57e628=_0x3b0aa3[_0x1828db('0x2876')]();_0x57e628[_0x1828db('0x2378')]=![],_0x359a66[_0x1828db('0x1514')](_0x57e628),_0xd9ebf0['values'][_0x1828db('0xe1c')]=_0x21dcf8(_0x359a66,'id',_0x1828db('0x4f0'));})['catch'](function(_0x2a479c){const _0x4fef91=_0x19d206;_0x2882f7[_0x4fef91('0xfc9')]({'title':_0x2a479c[_0x4fef91('0x52d')]?_0x4fef91('0x1e21')+_0x2a479c['status']+_0x4fef91('0x11e1')+_0x2a479c[_0x4fef91('0xe1b')]:_0x4fef91('0x21ff'),'msg':_0x2a479c['data']?JSON[_0x4fef91('0xbac')](_0x2a479c['data']['message']):_0x2a479c[_0x4fef91('0x1586')]()});});else _0xd9ebf0['values'][_0x19d206('0xe1c')]=_0x21dcf8(_0x359a66,'id',_0x19d206('0x4f0'));}function _0x421e57(){const _0x7f9451=_0x3228e9,_0x55ac9f=Number(_0x2cfb05()[_0x7f9451('0xc38')](_0xd9ebf0[_0x7f9451('0x27db')],{'name':_0x7f9451('0x237e')})[_0x7f9451('0x18e0')]),_0x4ee003=_0x2cfb05()[_0x7f9451('0x1798')](_0xb81e5,{'id':_0x55ac9f});if(!_0x4ee003&&_0x55ac9f>0x0)return _0x5d6383[_0x7f9451('0x277c')]['get']({'id':_0x55ac9f,'fields':'id,name,IntervalId'})[_0x7f9451('0xa44')][_0x7f9451('0x1166')](function(_0x1e882e){const _0x4c46a6=_0x7f9451,_0x209707=_0x1e882e[_0x4c46a6('0x2876')]();_0x209707[_0x4c46a6('0x2378')]=![],_0xb81e5['push'](_0x209707),_0xd9ebf0['values'][_0x4c46a6('0x237e')]=_0x21dcf8(_0xb81e5,'id',_0x4c46a6('0x4f0'),_0x4c46a6('0x186f'));})[_0x7f9451('0x1a80')](function(_0x48edb7){const _0x25979a=_0x7f9451;_0x2882f7[_0x25979a('0xfc9')]({'title':_0x48edb7[_0x25979a('0x52d')]?_0x25979a('0x1e21')+_0x48edb7['status']+_0x25979a('0x11e1')+_0x48edb7['statusText']:_0x25979a('0x1bb1'),'msg':_0x48edb7['data']?JSON['stringify'](_0x48edb7['data']['message']):_0x48edb7[_0x25979a('0x1586')]()});});else _0xd9ebf0[_0x7f9451('0x1ac1')][_0x7f9451('0x237e')]=_0x21dcf8(_0xb81e5,'id',_0x7f9451('0x4f0'),'IntervalId');}function _0x37ec27(){const _0xa9f9fb=_0x3228e9,_0x5922d9=Number(_0x2cfb05()[_0xa9f9fb('0xc38')](_0xd9ebf0[_0xa9f9fb('0x27db')],{'name':'account_id'})['value']),_0x2892f7=_0x2cfb05()[_0xa9f9fb('0x1798')](_0x44d588,{'id':_0x5922d9});if(!_0x2892f7&&_0x5922d9>0x0)return _0x5d6383[_0xa9f9fb('0x21b9')]['get']({'id':_0x5922d9,'fields':_0xa9f9fb('0x1776')})[_0xa9f9fb('0xa44')]['then'](function(_0x3a6fda){const _0x17cf61=_0xa9f9fb,_0x28eb93=_0x3a6fda[_0x17cf61('0x2876')]();_0x28eb93['canSelect']=![],_0x44d588[_0x17cf61('0x1514')](_0x28eb93),_0xd9ebf0[_0x17cf61('0x1ac1')]['account_id']=_0x21dcf8(_0x44d588,'id',_0x17cf61('0x4f0'));})[_0xa9f9fb('0x1a80')](function(_0x3cdd5c){const _0x54cb04=_0xa9f9fb;_0x2882f7[_0x54cb04('0xfc9')]({'title':_0x3cdd5c[_0x54cb04('0x52d')]?_0x54cb04('0x1e21')+_0x3cdd5c[_0x54cb04('0x52d')]+_0x54cb04('0x11e1')+_0x3cdd5c[_0x54cb04('0xe1b')]:_0x54cb04('0x218a'),'msg':_0x3cdd5c[_0x54cb04('0x25f4')]?JSON['stringify'](_0x3cdd5c[_0x54cb04('0x25f4')][_0x54cb04('0x1e70')]):_0x3cdd5c[_0x54cb04('0x1586')]()});});else _0xd9ebf0[_0xa9f9fb('0x1ac1')][_0xa9f9fb('0x11f5')]=_0x21dcf8(_0x44d588,'id','name');}function _0x242102(){const _0x579653=_0x3228e9,_0x262c52=Number(_0x2cfb05()['find'](_0xd9ebf0[_0x579653('0x27db')],{'name':'sms_account_id'})[_0x579653('0x18e0')]),_0x5f49dc=_0x2cfb05()['some'](_0x4a77a0,{'id':_0x262c52});if(!_0x5f49dc&&_0x262c52>0x0)return _0x5d6383[_0x579653('0x27e5')][_0x579653('0xd83')]({'id':_0x262c52,'fields':_0x579653('0x1776')})[_0x579653('0xa44')]['then'](function(_0xe8c95d){const _0x5e9904=_0x579653,_0x56a079=_0xe8c95d[_0x5e9904('0x2876')]();_0x56a079['canSelect']=![],_0x4a77a0['push'](_0x56a079),_0xd9ebf0[_0x5e9904('0x1ac1')][_0x5e9904('0x140e')]=_0x21dcf8(_0x4a77a0,'id','name');})[_0x579653('0x1a80')](function(_0x4222f3){const _0x4e5a58=_0x579653;_0x2882f7['error']({'title':_0x4222f3[_0x4e5a58('0x52d')]?'API:'+_0x4222f3[_0x4e5a58('0x52d')]+_0x4e5a58('0x11e1')+_0x4222f3['statusText']:_0x4e5a58('0x1b98'),'msg':_0x4222f3[_0x4e5a58('0x25f4')]?JSON[_0x4e5a58('0xbac')](_0x4222f3[_0x4e5a58('0x25f4')]['message']):_0x4222f3[_0x4e5a58('0x1586')]()});});else _0xd9ebf0[_0x579653('0x1ac1')][_0x579653('0x140e')]=_0x21dcf8(_0x4a77a0,'id',_0x579653('0x4f0'));}function _0x4146ef(){const _0x21751b=_0x3228e9,_0x598656=Number(_0x2cfb05()[_0x21751b('0xc38')](_0xd9ebf0[_0x21751b('0x27db')],{'name':_0x21751b('0xd65')})['value']),_0x342f2f=_0x2cfb05()['some'](_0xe95562,{'id':_0x598656});if(!_0x342f2f&&_0x598656>0x0)return _0x5d6383[_0x21751b('0x243')][_0x21751b('0xd83')]({'id':_0x598656,'fields':'id,name'})[_0x21751b('0xa44')][_0x21751b('0x1166')](function(_0x328a54){const _0x11c85e=_0x21751b,_0x28e8a0=_0x328a54[_0x11c85e('0x2876')]();_0x28e8a0[_0x11c85e('0x2378')]=![],_0xe95562[_0x11c85e('0x1514')](_0x28e8a0),_0xd9ebf0[_0x11c85e('0x1ac1')][_0x11c85e('0xd65')]=_0x21dcf8(_0xe95562,'id',_0x11c85e('0x4f0'));})['catch'](function(_0x19520b){const _0x46ba3a=_0x21751b;_0x2882f7[_0x46ba3a('0xfc9')]({'title':_0x19520b[_0x46ba3a('0x52d')]?_0x46ba3a('0x1e21')+_0x19520b['status']+_0x46ba3a('0x11e1')+_0x19520b['statusText']:_0x46ba3a('0xa93'),'msg':_0x19520b[_0x46ba3a('0x25f4')]?JSON[_0x46ba3a('0xbac')](_0x19520b[_0x46ba3a('0x25f4')][_0x46ba3a('0x1e70')]):_0x19520b['toString']()});});else _0xd9ebf0[_0x21751b('0x1ac1')][_0x21751b('0xd65')]=_0x21dcf8(_0xe95562,'id',_0x21751b('0x4f0'));}function _0x99d234(){const _0x195668=_0x3228e9,_0x4c748a=Number(_0x2cfb05()['find'](_0xd9ebf0['attributes'],{'name':_0x195668('0x181f')})['value']),_0x391570=_0x2cfb05()[_0x195668('0x1798')](_0x2095ef,{'id':_0x4c748a});if(!_0x391570&&_0x4c748a>0x0)return _0x5d6383[_0x195668('0x1e77')]['get']({'id':_0x4c748a,'fields':'id,name'})[_0x195668('0xa44')][_0x195668('0x1166')](function(_0x44b0cb){const _0x2c68cb=_0x195668,_0x1c5046=_0x44b0cb['toJSON']();_0x1c5046[_0x2c68cb('0x2378')]=![],_0x2095ef['push'](_0x1c5046),_0xd9ebf0[_0x2c68cb('0x1ac1')][_0x2c68cb('0x181f')]=_0x21dcf8(_0x2095ef,'id','name');})['catch'](function(_0x4c0721){const _0x2a0ed8=_0x195668;_0x2882f7[_0x2a0ed8('0xfc9')]({'title':_0x4c0721['status']?_0x2a0ed8('0x1e21')+_0x4c0721[_0x2a0ed8('0x52d')]+_0x2a0ed8('0x11e1')+_0x4c0721[_0x2a0ed8('0xe1b')]:_0x2a0ed8('0x707'),'msg':_0x4c0721[_0x2a0ed8('0x25f4')]?JSON[_0x2a0ed8('0xbac')](_0x4c0721[_0x2a0ed8('0x25f4')][_0x2a0ed8('0x1e70')]):_0x4c0721[_0x2a0ed8('0x1586')]()});});else _0xd9ebf0['values']['pause_id']=_0x21dcf8(_0x2095ef,'id',_0x195668('0x4f0'));}function _0x2d6cdb(_0x4b886a){const _0x3e6cb3=_0x3228e9;_0x4b886a&&_0x157ab6(_0xd9ebf0['attributes']),_0x3fa493[_0x3e6cb3('0x1197')]();}}const _0x23a9c5=_0x58231f;function _0x2a8713(){return{'require':'ngModel','link':function(_0x5dd877,_0x1698ca,_0x14dfa4,_0x50e3ea){const _0x23e20d=a0_0x3f2c;_0x50e3ea[_0x23e20d('0x17b')]['push'](function(_0x2a1109){return''+_0x2a1109;}),_0x50e3ea[_0x23e20d('0xc93')][_0x23e20d('0x1514')](function(_0x1eea7c){return parseFloat(_0x1eea7c);});}};}const _0xbdd804=_0x2a8713;function _0x40aad6(){const _0x2e606a=_0x36e6f4;return[{'value':'da','option':_0x2e606a('0x7a4')},{'value':'en','option':_0x2e606a('0x1852')},{'value':'de','option':'German'},{'value':'it','option':_0x2e606a('0x1a40')},{'value':'es','option':'Spanish'},{'value':'fr','option':_0x2e606a('0x2746')},{'value':'id','option':_0x2e606a('0xebe')},{'value':'ja','option':'Japanese'},{'value':'ko','option':'Korean\x20(South\x20Korea)'},{'value':'nl','option':_0x2e606a('0x1025')},{'value':'no','option':_0x2e606a('0x522')},{'value':'pt','option':_0x2e606a('0x0')},{'value':_0x2e606a('0x26f8'),'option':_0x2e606a('0x2528')},{'value':'ru','option':_0x2e606a('0xf22')},{'value':'sv','option':_0x2e606a('0x277e')},{'value':'th','option':'Thai'},{'value':'uk','option':'Ukrainian'},{'value':_0x2e606a('0x124f'),'option':_0x2e606a('0xefc')},{'value':_0x2e606a('0x76b'),'option':'Chinese\x20(Hong\x20Kong)'},{'value':_0x2e606a('0x13ba'),'option':_0x2e606a('0x145a')}];}function _0x2bed43(){const _0x185fab=_0x36e6f4;return[{'value':'zh-HK','option':'Chinese\x20(Cantonese)'},{'value':'zh-CN','option':_0x185fab('0xefc')},{'value':_0x185fab('0x13ba'),'option':_0x185fab('0x145a')},{'value':'da','option':_0x185fab('0x7a4')},{'value':'nl','option':_0x185fab('0x1025')},{'value':'en','option':_0x185fab('0x1852')},{'value':_0x185fab('0x696'),'option':_0x185fab('0x27a0')},{'value':_0x185fab('0x1a20'),'option':'English\x20(Canada)'},{'value':'en-GB','option':_0x185fab('0x1cdd')},{'value':_0x185fab('0x18ce'),'option':_0x185fab('0x655')},{'value':_0x185fab('0x2722'),'option':_0x185fab('0x1f4')},{'value':'fr','option':_0x185fab('0x2746')},{'value':_0x185fab('0x1e95'),'option':_0x185fab('0x19bd')},{'value':_0x185fab('0x11e7'),'option':'France\x20(France)'},{'value':'de','option':'German'},{'value':'hi','option':'Hindi'},{'value':'id','option':_0x185fab('0xebe')},{'value':'it','option':_0x185fab('0x1a40')},{'value':'ja','option':_0x185fab('0x2688')},{'value':'ko','option':'Korean'},{'value':'no','option':_0x185fab('0x522')},{'value':'pl','option':_0x185fab('0x19b3')},{'value':_0x185fab('0x21b8'),'option':_0x185fab('0x702')},{'value':'pt-PT','option':'Portuguese\x20(Portugal)'},{'value':'ru','option':_0x185fab('0xf22')},{'value':'es','option':_0x185fab('0x2246')},{'value':_0x185fab('0x1b8a'),'option':_0x185fab('0x9e5')},{'value':'es-ES','option':_0x185fab('0x1f75')},{'value':'sw','option':_0x185fab('0x277e')},{'value':'th','option':'Thai'},{'value':'tr','option':'Turkish'},{'value':'uk','option':_0x185fab('0xd6b')}];}function _0x122950(){const _0x234c71=_0x36e6f4;return[{'value':_0x234c71('0x68d'),'option':_0x234c71('0x16b2')},{'value':'cs-CZ','option':_0x234c71('0x9ec')},{'value':_0x234c71('0xeaa'),'option':'Danish\x20(Denmark)'},{'value':_0x234c71('0x75c'),'option':_0x234c71('0xf36')},{'value':'el-GR','option':_0x234c71('0x114a')},{'value':_0x234c71('0x696'),'option':_0x234c71('0x1cc0')},{'value':_0x234c71('0x18ce'),'option':_0x234c71('0x655')},{'value':_0x234c71('0x11ff'),'option':_0x234c71('0x27d9')},{'value':_0x234c71('0x2722'),'option':_0x234c71('0x1f4')},{'value':_0x234c71('0x22b2'),'option':_0x234c71('0x1a56')},{'value':_0x234c71('0x10a9'),'option':_0x234c71('0x1296')},{'value':_0x234c71('0x1e95'),'option':_0x234c71('0x19bd')},{'value':'fr-FR','option':_0x234c71('0x1df5')},{'value':_0x234c71('0x14b8'),'option':_0x234c71('0x1f89')},{'value':'hu-HU','option':_0x234c71('0x2cb')},{'value':_0x234c71('0x1f0e'),'option':_0x234c71('0x319')},{'value':_0x234c71('0x595'),'option':_0x234c71('0x3ec')},{'value':_0x234c71('0x3ff'),'option':_0x234c71('0x1127')},{'value':_0x234c71('0x12e7'),'option':_0x234c71('0x347')},{'value':_0x234c71('0x11c1'),'option':'Mandarin\x20Chinese'},{'value':'nb-NO','option':_0x234c71('0x20c6')},{'value':'pl-PL','option':_0x234c71('0x3e0')},{'value':'pt-BR','option':_0x234c71('0x702')},{'value':'pt-PT','option':_0x234c71('0x1336')},{'value':_0x234c71('0x151b'),'option':_0x234c71('0x16bb')},{'value':'sk-SK','option':_0x234c71('0x5d5')},{'value':'es-ES','option':_0x234c71('0x1f75')},{'value':'sv-SE','option':_0x234c71('0xe27')},{'value':_0x234c71('0x147c'),'option':_0x234c71('0xab4')},{'value':_0x234c71('0x779'),'option':'Ukrainian\x20(Ukraine)'},{'value':'vi-VN','option':_0x234c71('0x22d2')}];}function _0x4f1dfb(){const _0x2d068a=_0x36e6f4;return[{'value':'af','option':_0x2d068a('0x21d5')},{'value':'sq','option':_0x2d068a('0x21a5')},{'value':'am','option':'Amharic'},{'value':'ar','option':_0x2d068a('0x16b2')},{'value':'hy','option':'Armenian'},{'value':'az','option':_0x2d068a('0x230d')},{'value':'eu','option':'Basque'},{'value':'be','option':_0x2d068a('0x1491')},{'value':'bn','option':_0x2d068a('0xfa8')},{'value':'bh','option':'Bihari'},{'value':'bs','option':_0x2d068a('0xaab')},{'value':'br','option':_0x2d068a('0xc52')},{'value':'bg','option':_0x2d068a('0x1754')},{'value':'km','option':'Cambodian'},{'value':'ca','option':_0x2d068a('0x153a')},{'value':_0x2d068a('0x124f'),'option':_0x2d068a('0xefc')},{'value':'zh-TW','option':_0x2d068a('0x145a')},{'value':'co','option':'Corsican'},{'value':'hr','option':_0x2d068a('0x15fa')},{'value':'cs','option':_0x2d068a('0x5c2')},{'value':'da','option':'Danish'},{'value':'nl','option':_0x2d068a('0x1025')},{'value':'en','option':'English'},{'value':'eo','option':_0x2d068a('0x1c43')},{'value':'et','option':_0x2d068a('0x15a5')},{'value':'fo','option':'Faroese'},{'value':'tl','option':_0x2d068a('0xf96')},{'value':'fi','option':'Finnish'},{'value':'fr','option':_0x2d068a('0x2746')},{'value':'fy','option':_0x2d068a('0x276c')},{'value':'gl','option':_0x2d068a('0x3d8')},{'value':'ka','option':_0x2d068a('0x12f1')},{'value':'de','option':_0x2d068a('0x20f')},{'value':'el','option':_0x2d068a('0x2691')},{'value':'gn','option':_0x2d068a('0xd8f')},{'value':'gu','option':_0x2d068a('0x211')},{'value':_0x2d068a('0x104d'),'option':_0x2d068a('0x1986')},{'value':'ha','option':_0x2d068a('0x19ab')},{'value':'iw','option':_0x2d068a('0x287')},{'value':'hi','option':_0x2d068a('0x473')},{'value':'hu','option':_0x2d068a('0x288e')},{'value':'is','option':_0x2d068a('0x1771')},{'value':'id','option':_0x2d068a('0xebe')},{'value':'ia','option':_0x2d068a('0x80c')},{'value':'ga','option':_0x2d068a('0x16ff')},{'value':'it','option':_0x2d068a('0x1a40')},{'value':'jw','option':_0x2d068a('0x229f')},{'value':'ja','option':'Japanese'},{'value':'kn','option':_0x2d068a('0x1fa7')},{'value':'kk','option':_0x2d068a('0x1ce9')},{'value':'rw','option':_0x2d068a('0x1f4b')},{'value':'rn','option':_0x2d068a('0x1548')},{'value':_0x2d068a('0x22e1'),'option':'Klingon'},{'value':'ku','option':_0x2d068a('0xebb')},{'value':'ko','option':_0x2d068a('0x511')},{'value':'ky','option':_0x2d068a('0xbfe')},{'value':'lo','option':'Laothian'},{'value':'la','option':'Latin'},{'value':'lv','option':_0x2d068a('0x2824')},{'value':'ln','option':_0x2d068a('0xe41')},{'value':'lt','option':_0x2d068a('0x13bd')},{'value':'mk','option':_0x2d068a('0xb42')},{'value':'mg','option':_0x2d068a('0x107a')},{'value':'ml','option':_0x2d068a('0x2731')},{'value':'mt','option':'Maltese'},{'value':'mi','option':_0x2d068a('0x1b3e')},{'value':'mr','option':_0x2d068a('0x263c')},{'value':'mo','option':_0x2d068a('0x1945')},{'value':'mn','option':_0x2d068a('0x2ea')},{'value':'sr-ME','option':'Montenegrin'},{'value':'ne','option':_0x2d068a('0x74a')},{'value':'no','option':_0x2d068a('0x522')},{'value':'nn','option':_0x2d068a('0x109d')},{'value':'oc','option':_0x2d068a('0x13ea')},{'value':'or','option':_0x2d068a('0x2230')},{'value':'om','option':_0x2d068a('0x1635')},{'value':'ps','option':'Pashto'},{'value':'fa','option':_0x2d068a('0x14b1')},{'value':_0x2d068a('0x128'),'option':'Pirate'},{'value':'pl','option':_0x2d068a('0x19b3')},{'value':_0x2d068a('0x21b8'),'option':_0x2d068a('0x702')},{'value':_0x2d068a('0x19f8'),'option':_0x2d068a('0x1336')},{'value':'pa','option':_0x2d068a('0x2a5')},{'value':'qu','option':'Quechua'},{'value':'ro','option':'Romanian'},{'value':'rm','option':'Romansh'},{'value':'ru','option':'Russian'},{'value':'gd','option':_0x2d068a('0x23e')},{'value':'sr','option':_0x2d068a('0x176a')},{'value':'sh','option':'Serbo-Croatian'},{'value':'st','option':'Sesotho'},{'value':'sn','option':'Shona'},{'value':'sd','option':_0x2d068a('0x1264')},{'value':'si','option':_0x2d068a('0x581')},{'value':'sk','option':'Slovak'},{'value':'sl','option':_0x2d068a('0xe37')},{'value':'so','option':_0x2d068a('0x2311')},{'value':'es','option':_0x2d068a('0x2246')},{'value':'su','option':_0x2d068a('0x1137')},{'value':'sw','option':_0x2d068a('0x15af')},{'value':'sv','option':_0x2d068a('0x277e')},{'value':'tg','option':'Tajik'},{'value':'ta','option':_0x2d068a('0x420')},{'value':'tt','option':_0x2d068a('0xdaf')},{'value':'te','option':_0x2d068a('0x9e6')},{'value':'th','option':'Thai'},{'value':'ti','option':_0x2d068a('0xcb')},{'value':'to','option':_0x2d068a('0x2599')},{'value':'tr','option':_0x2d068a('0x71a')},{'value':'tk','option':_0x2d068a('0x2402')},{'value':'tw','option':_0x2d068a('0xcab')},{'value':'ug','option':_0x2d068a('0x99')},{'value':'uk','option':_0x2d068a('0xd6b')},{'value':'ur','option':_0x2d068a('0x3ca')},{'value':'uz','option':_0x2d068a('0x33a')},{'value':'vi','option':_0x2d068a('0x1789')},{'value':'cy','option':_0x2d068a('0x2752')},{'value':'xh','option':'Xhosa'},{'value':'yi','option':_0x2d068a('0x1672')},{'value':'yo','option':_0x2d068a('0x1fd5')},{'value':'zu','option':_0x2d068a('0x65')}];}function _0x2a477f(){const _0x7d0023=_0x36e6f4;return[{'value':'af-ZA','option':'Afrikaans\x20(South\x20Africa)'},{'value':_0x7d0023('0x453'),'option':_0x7d0023('0x282a')},{'value':'hy-AM','option':_0x7d0023('0xbb9')},{'value':_0x7d0023('0x1259'),'option':'Azerbaijani\x20(Azerbaijan)'},{'value':_0x7d0023('0x1f0e'),'option':_0x7d0023('0x319')},{'value':'ms-MY','option':_0x7d0023('0x22a3')},{'value':_0x7d0023('0x12e6'),'option':_0x7d0023('0x11f4')},{'value':_0x7d0023('0xd2f'),'option':_0x7d0023('0x45')},{'value':_0x7d0023('0xb9'),'option':_0x7d0023('0x23cd')},{'value':_0x7d0023('0x879'),'option':_0x7d0023('0x9ec')},{'value':'da-DK','option':_0x7d0023('0x153d')},{'value':'de-DE','option':_0x7d0023('0x1620')},{'value':_0x7d0023('0x696'),'option':_0x7d0023('0x27a0')},{'value':_0x7d0023('0x1a20'),'option':_0x7d0023('0x28b8')},{'value':_0x7d0023('0x7f0'),'option':_0x7d0023('0x1494')},{'value':'en-GB','option':_0x7d0023('0x2220')},{'value':_0x7d0023('0x18ce'),'option':_0x7d0023('0x655')},{'value':'en-IE','option':'English\x20(Ireland)'},{'value':_0x7d0023('0x13ef'),'option':'English\x20(Kenya)'},{'value':_0x7d0023('0x3f7'),'option':'English\x20(New\x20Zealand)'},{'value':_0x7d0023('0x1b38'),'option':'English\x20(Nigeria)'},{'value':_0x7d0023('0x1014'),'option':_0x7d0023('0x9a4')},{'value':_0x7d0023('0x645'),'option':'English\x20(South\x20Africa)'},{'value':'en-TZ','option':_0x7d0023('0xc59')},{'value':_0x7d0023('0x2722'),'option':'English\x20(United\x20States)'},{'value':_0x7d0023('0x12b8'),'option':_0x7d0023('0x6ac')},{'value':_0x7d0023('0x1361'),'option':_0x7d0023('0x134c')},{'value':_0x7d0023('0x1258'),'option':'Spanish\x20(Chile)'},{'value':'es-CO','option':_0x7d0023('0x275e')},{'value':_0x7d0023('0x7ed'),'option':'Spanish\x20(Costa\x20Rica)'},{'value':'es-EC','option':'Spanish\x20(Ecuador)'},{'value':_0x7d0023('0x2212'),'option':_0x7d0023('0x14bf')},{'value':_0x7d0023('0xa11'),'option':_0x7d0023('0x1f75')},{'value':_0x7d0023('0x356'),'option':_0x7d0023('0x51')},{'value':_0x7d0023('0x1015'),'option':_0x7d0023('0x1009')},{'value':'es-HN','option':_0x7d0023('0xdb6')},{'value':'es-MX','option':_0x7d0023('0x11dd')},{'value':'es-NI','option':_0x7d0023('0x10e')},{'value':_0x7d0023('0x28ed'),'option':_0x7d0023('0x6a7')},{'value':_0x7d0023('0xa4e'),'option':_0x7d0023('0xb45')},{'value':_0x7d0023('0x13c0'),'option':_0x7d0023('0x257c')},{'value':_0x7d0023('0x1249'),'option':'Spanish\x20(Puerto\x20Rico)'},{'value':_0x7d0023('0x9ca'),'option':_0x7d0023('0xdd4')},{'value':_0x7d0023('0x1ec'),'option':_0x7d0023('0x1ead')},{'value':_0x7d0023('0xf8'),'option':_0x7d0023('0x233c')},{'value':_0x7d0023('0x18bd'),'option':'Basque\x20(Spain)'},{'value':_0x7d0023('0x10a9'),'option':_0x7d0023('0x1296')},{'value':_0x7d0023('0x1e95'),'option':_0x7d0023('0x19bd')},{'value':_0x7d0023('0x11e7'),'option':'French\x20(France)'},{'value':'gl-ES','option':_0x7d0023('0x9ef')},{'value':_0x7d0023('0x2542'),'option':_0x7d0023('0x1d83')},{'value':'gu-IN','option':_0x7d0023('0x2741')},{'value':'hr-HR','option':'Croatian\x20(Croatia)'},{'value':_0x7d0023('0x1d14'),'option':'Zulu\x20(South\x20Africa)'},{'value':_0x7d0023('0x1042'),'option':'Icelandic\x20(Iceland)'},{'value':'it-IT','option':'Italian\x20(Italy)'},{'value':_0x7d0023('0x17c'),'option':'Javanese\x20(Indonesia)'},{'value':_0x7d0023('0x810'),'option':'Kannada\x20(India)'},{'value':'km-KH','option':_0x7d0023('0x368')},{'value':_0x7d0023('0x1625'),'option':'Lao\x20(Laos)'},{'value':'lv-LV','option':'Latvian\x20(Latvia)'},{'value':_0x7d0023('0x10bb'),'option':_0x7d0023('0xead')},{'value':'hu-HU','option':'Hungarian\x20(Hungary)'},{'value':_0x7d0023('0x18b7'),'option':'Malayalam\x20(India)'},{'value':_0x7d0023('0xcf6'),'option':_0x7d0023('0x8ef')},{'value':_0x7d0023('0x177e'),'option':_0x7d0023('0xf36')},{'value':_0x7d0023('0x217f'),'option':'Nepali\x20(Nepal)'},{'value':_0x7d0023('0x1f2e'),'option':'Norwegian\x20Bokmal\x20(Norway)'},{'value':_0x7d0023('0x1406'),'option':'Polish\x20(Poland)'},{'value':'pt-BR','option':_0x7d0023('0x702')},{'value':_0x7d0023('0x19f8'),'option':_0x7d0023('0x1336')},{'value':'ro-RO','option':'Romanian\x20(Romania)'},{'value':_0x7d0023('0xf03'),'option':'Sinhala\x20(Srilanka)'},{'value':_0x7d0023('0x93'),'option':_0x7d0023('0x5d5')},{'value':'sl-SI','option':_0x7d0023('0x28a6')},{'value':_0x7d0023('0x1aa9'),'option':_0x7d0023('0x1cf7')},{'value':_0x7d0023('0x367'),'option':_0x7d0023('0x1d6d')},{'value':_0x7d0023('0x106b'),'option':_0x7d0023('0x1f91')},{'value':_0x7d0023('0x22b2'),'option':_0x7d0023('0x1a56')},{'value':'sv-SE','option':_0x7d0023('0xe27')},{'value':_0x7d0023('0xe4c'),'option':'Tamil\x20(India)'},{'value':_0x7d0023('0xbde'),'option':_0x7d0023('0x10d')},{'value':_0x7d0023('0x19b0'),'option':_0x7d0023('0x94f')},{'value':_0x7d0023('0x712'),'option':_0x7d0023('0x174a')},{'value':_0x7d0023('0xf7b'),'option':_0x7d0023('0x121')},{'value':_0x7d0023('0x568'),'option':_0x7d0023('0x22d2')},{'value':'tr-TR','option':_0x7d0023('0xab4')},{'value':_0x7d0023('0x429'),'option':'Urdu\x20(Pakistan)'},{'value':_0x7d0023('0x870'),'option':_0x7d0023('0x2242')},{'value':_0x7d0023('0x4ce'),'option':'Greek\x20(Greece)'},{'value':'bg-BG','option':_0x7d0023('0x1748')},{'value':_0x7d0023('0x151b'),'option':'Russian\x20(Russia)'},{'value':_0x7d0023('0xa41'),'option':_0x7d0023('0x1563')},{'value':_0x7d0023('0x779'),'option':_0x7d0023('0x51c')},{'value':_0x7d0023('0x22a9'),'option':'Hebrew\x20(Israel)'},{'value':'ar-IL','option':_0x7d0023('0x185b')},{'value':_0x7d0023('0x837'),'option':_0x7d0023('0x1a7')},{'value':'ar-AE','option':'Arabic\x20(United\x20Arab\x20Emirates)'},{'value':_0x7d0023('0x13e5'),'option':_0x7d0023('0x185d')},{'value':_0x7d0023('0x13a1'),'option':_0x7d0023('0x8f6')},{'value':_0x7d0023('0x1ffa'),'option':_0x7d0023('0x2405')},{'value':_0x7d0023('0x14b9'),'option':_0x7d0023('0x1240')},{'value':_0x7d0023('0x213d'),'option':_0x7d0023('0x1934')},{'value':_0x7d0023('0x25ae'),'option':_0x7d0023('0x25ee')},{'value':_0x7d0023('0x1ee1'),'option':'Arabic\x20(Tunisia)'},{'value':_0x7d0023('0x1b6f'),'option':_0x7d0023('0x1c19')},{'value':_0x7d0023('0x9e8'),'option':_0x7d0023('0x14f5')},{'value':_0x7d0023('0x2066'),'option':_0x7d0023('0xea9')},{'value':_0x7d0023('0x84'),'option':_0x7d0023('0x1d08')},{'value':'ar-EG','option':_0x7d0023('0x1af')},{'value':_0x7d0023('0x90c'),'option':'Persian\x20(Iran)'},{'value':_0x7d0023('0x14b8'),'option':'Hindi\x20(India)'},{'value':_0x7d0023('0xc21'),'option':_0x7d0023('0x1b75')},{'value':_0x7d0023('0x12e7'),'option':_0x7d0023('0x347')},{'value':'cmn-Hant-TW','option':_0x7d0023('0x22be')},{'value':'yue-Hant-HK','option':_0x7d0023('0x1b5a')},{'value':_0x7d0023('0x3ff'),'option':_0x7d0023('0x1127')},{'value':_0x7d0023('0x862'),'option':'Chinese,\x20Mandarin\x20(Simplified,\x20Hong\x20Kong)'},{'value':_0x7d0023('0x1b7f'),'option':_0x7d0023('0x2592')}];}function _0x2b0429(){const _0x208b85=_0x36e6f4;return[{'value':_0x208b85('0x23bd'),'option':_0x208b85('0x1731')},{'value':_0x208b85('0x1755'),'option':'US\x20English\x20Male'},{'value':_0x208b85('0x6db'),'option':'UK\x20English\x20Female'},{'value':_0x208b85('0x87'),'option':'UK\x20English\x20Male'},{'value':_0x208b85('0x1594'),'option':'Australian\x20English'},{'value':_0x208b85('0x1e07'),'option':_0x208b85('0xa3c')},{'value':_0x208b85('0x2412'),'option':_0x208b85('0x284e')},{'value':'chchinesefemale','option':_0x208b85('0x51a')},{'value':_0x208b85('0x16ba'),'option':_0x208b85('0x1e8d')},{'value':'hkchinesefemale','option':'Hong\x20Kong\x20Cantonese\x20Female'},{'value':_0x208b85('0x221c'),'option':_0x208b85('0x17b9')},{'value':_0x208b85('0x165f'),'option':_0x208b85('0x1ea')},{'value':_0x208b85('0x70e'),'option':'Japanese\x20Male'},{'value':_0x208b85('0x210c'),'option':_0x208b85('0x6f7')},{'value':_0x208b85('0x1d32'),'option':_0x208b85('0x6a3')},{'value':_0x208b85('0x242b'),'option':'Canadian\x20English\x20Female'},{'value':_0x208b85('0x1f0d'),'option':_0x208b85('0x1be9')},{'value':'brportuguesefemale','option':_0x208b85('0x231b')},{'value':'eurportuguesefemale','option':_0x208b85('0x7d0')},{'value':_0x208b85('0x2455'),'option':_0x208b85('0x19cd')},{'value':'eurspanishfemale','option':_0x208b85('0x1dbf')},{'value':'eurspanishmale','option':_0x208b85('0x2747')},{'value':'eurcatalanfemale','option':'European\x20Catalan\x20Female'},{'value':_0x208b85('0x1a92'),'option':_0x208b85('0xb40')},{'value':_0x208b85('0x11b0'),'option':'European\x20Danish\x20Female'},{'value':_0x208b85('0x1da'),'option':_0x208b85('0x1f69')},{'value':_0x208b85('0x1c64'),'option':_0x208b85('0x14e')},{'value':_0x208b85('0xa2b'),'option':_0x208b85('0x2da')},{'value':'eurnorwegianfemale','option':_0x208b85('0x798')},{'value':_0x208b85('0x24b8'),'option':'European\x20Dutch\x20Female'},{'value':_0x208b85('0x24a4'),'option':_0x208b85('0x2035')},{'value':'euritalianfemale','option':_0x208b85('0x16e8')},{'value':_0x208b85('0x1f28'),'option':_0x208b85('0x384')},{'value':'eurturkishfemale','option':_0x208b85('0x1d68')},{'value':'eurturkishmale','option':'European\x20Turkish\x20Male'},{'value':_0x208b85('0x1899'),'option':_0x208b85('0x1429')},{'value':_0x208b85('0x460'),'option':_0x208b85('0xe7e')},{'value':_0x208b85('0x24d1'),'option':_0x208b85('0x1016')},{'value':_0x208b85('0x136c'),'option':_0x208b85('0x39e')},{'value':'swswedishfemale','option':_0x208b85('0x28d0')},{'value':_0x208b85('0x88e'),'option':'Canadian\x20French\x20Female'},{'value':'cafrenchmale','option':_0x208b85('0x28e9')}];}function _0x3bd06d(){const _0x51a4e7=_0x36e6f4;return[{'value':_0x51a4e7('0x2722'),'option':_0x51a4e7('0x1f4')},{'value':_0x51a4e7('0x1a20'),'option':_0x51a4e7('0x28b8')},{'value':_0x51a4e7('0x11ff'),'option':_0x51a4e7('0x27d9')},{'value':_0x51a4e7('0x696'),'option':_0x51a4e7('0x27a0')},{'value':_0x51a4e7('0xa11'),'option':_0x51a4e7('0x1f75')},{'value':_0x51a4e7('0x97a'),'option':_0x51a4e7('0x11dd')},{'value':'it-IT','option':_0x51a4e7('0x1c26')},{'value':_0x51a4e7('0x11e7'),'option':_0x51a4e7('0x1620')},{'value':_0x51a4e7('0x1e95'),'option':_0x51a4e7('0x19bd')},{'value':_0x51a4e7('0x1406'),'option':_0x51a4e7('0x3e0')},{'value':_0x51a4e7('0x19f8'),'option':_0x51a4e7('0x1336')},{'value':'ca-ES','option':_0x51a4e7('0x12e3')},{'value':_0x51a4e7('0x13ba'),'option':'Chinese\x20(Taiwan)'},{'value':_0x51a4e7('0xeaa'),'option':_0x51a4e7('0x153d')},{'value':_0x51a4e7('0x3ff'),'option':_0x51a4e7('0x1127')},{'value':_0x51a4e7('0x12e7'),'option':'Korean\x20(Korea)'},{'value':_0x51a4e7('0x177e'),'option':_0x51a4e7('0xf36')},{'value':_0x51a4e7('0x1f2e'),'option':'Norwegian\x20(Norway)'},{'value':_0x51a4e7('0x21b8'),'option':_0x51a4e7('0x702')},{'value':'ru-RU','option':_0x51a4e7('0x16bb')},{'value':_0x51a4e7('0xa5e'),'option':_0x51a4e7('0xe27')},{'value':_0x51a4e7('0x124f'),'option':_0x51a4e7('0x18de')},{'value':_0x51a4e7('0x76b'),'option':_0x51a4e7('0x8d9')}];}function _0x2f2875(){const _0x40fd04=_0x36e6f4;return[{'value':'0','option':_0x40fd04('0x1cb5')},{'value':_0x40fd04('0x1643'),'option':_0x40fd04('0x74b')},{'value':_0x40fd04('0x6f6'),'option':_0x40fd04('0x24da')},{'value':_0x40fd04('0x173b'),'option':_0x40fd04('0xd2d')},{'value':_0x40fd04('0x2006'),'option':_0x40fd04('0x1879')},{'value':_0x40fd04('0x502'),'option':'Numbers\x20to\x20999'},{'value':_0x40fd04('0x12bf'),'option':_0x40fd04('0x57d')},{'value':'phonenumber','option':_0x40fd04('0x72')},{'value':'streets','option':_0x40fd04('0xf2d')},{'value':_0x40fd04('0x21f3'),'option':_0x40fd04('0x1ab4')}];}function _0x520f51(){const _0x3c37dd=_0x36e6f4;return[{'value':_0x3c37dd('0x28c0'),'option':_0x3c37dd('0x2513')},{'value':_0x3c37dd('0x1921'),'option':_0x3c37dd('0x220')},{'value':_0x3c37dd('0x1574'),'option':'Brian\x20(English,\x20British,\x20Male)'},{'value':_0x3c37dd('0x168e'),'option':_0x3c37dd('0x1ccf')},{'value':_0x3c37dd('0x247f'),'option':_0x3c37dd('0x1ffe')},{'value':_0x3c37dd('0x1141'),'option':_0x3c37dd('0x264')},{'value':_0x3c37dd('0x10d2'),'option':_0x3c37dd('0x1339')},{'value':_0x3c37dd('0x1aa8'),'option':_0x3c37dd('0x266c')},{'value':_0x3c37dd('0x1fd3'),'option':_0x3c37dd('0x2154')},{'value':'Dora','option':_0x3c37dd('0x2806')},{'value':_0x3c37dd('0x86d'),'option':_0x3c37dd('0x1ac7')},{'value':_0x3c37dd('0x1904'),'option':_0x3c37dd('0x2631')},{'value':_0x3c37dd('0x20cb'),'option':_0x3c37dd('0x2139')},{'value':_0x3c37dd('0x2214'),'option':_0x3c37dd('0x199c')},{'value':'Geraint','option':_0x3c37dd('0x556')},{'value':_0x3c37dd('0x22c'),'option':_0x3c37dd('0x2175')},{'value':_0x3c37dd('0x249b'),'option':_0x3c37dd('0x21a3')},{'value':_0x3c37dd('0x260f'),'option':_0x3c37dd('0x1670')},{'value':_0x3c37dd('0xcd6'),'option':'Ines\x20(Portuguese,\x20Female)'},{'value':_0x3c37dd('0x1969'),'option':'Ivy\x20(English,\x20US,\x20Female)'},{'value':_0x3c37dd('0x133'),'option':_0x3c37dd('0x8a5')},{'value':_0x3c37dd('0x1786'),'option':'Jan\x20(Polish,\x20Male)'},{'value':_0x3c37dd('0xb36'),'option':_0x3c37dd('0x1c97')},{'value':_0x3c37dd('0x16ac'),'option':'Joey\x20(English,\x20US,\x20Male)'},{'value':_0x3c37dd('0x1328'),'option':'Justin\x20(English,\x20US,\x20Male)'},{'value':_0x3c37dd('0x23b8'),'option':_0x3c37dd('0x504')},{'value':_0x3c37dd('0x1f'),'option':_0x3c37dd('0xa46')},{'value':_0x3c37dd('0x2753'),'option':'Kimberly\x20(English,\x20US,\x20Female)'},{'value':_0x3c37dd('0x1490'),'option':'Liv\x20(Norwegian,\x20Female)'},{'value':_0x3c37dd('0xba3'),'option':_0x3c37dd('0x12ec')},{'value':_0x3c37dd('0x1434'),'option':_0x3c37dd('0xa63')},{'value':'Maja','option':_0x3c37dd('0x4cd')},{'value':_0x3c37dd('0x2ce'),'option':_0x3c37dd('0x10e9')},{'value':_0x3c37dd('0x161f'),'option':'Mathieu\x20(French,\x20Male)'},{'value':_0x3c37dd('0x9b8'),'option':_0x3c37dd('0x1006')},{'value':_0x3c37dd('0xba'),'option':'Miguel\x20(Spanish,\x20US,\x20Male)'},{'value':_0x3c37dd('0x3cc'),'option':'Mizuki\x20(Japanese,\x20Female)'},{'value':_0x3c37dd('0x963'),'option':_0x3c37dd('0x1aca')},{'value':_0x3c37dd('0x253c'),'option':_0x3c37dd('0x12d7')},{'value':_0x3c37dd('0x2710'),'option':_0x3c37dd('0x2119')},{'value':_0x3c37dd('0x238b'),'option':'Raveena\x20(English,\x20Indian,\x20Female)'},{'value':'Ricardo','option':'Ricardo\x20(Portuguese,\x20Brazilian,\x20Male)'},{'value':_0x3c37dd('0x15f6'),'option':_0x3c37dd('0x1220')},{'value':_0x3c37dd('0x279d'),'option':_0x3c37dd('0x1844')},{'value':_0x3c37dd('0x283'),'option':_0x3c37dd('0x1b5')},{'value':'Tatyana','option':'Tatyana\x20(Russian,\x20Female)'},{'value':_0x3c37dd('0x8c7'),'option':_0x3c37dd('0x12f7')}];}function _0x2248c0(){const _0x2eeac2=_0x36e6f4;return[{'value':_0x2eeac2('0x1039'),'option':_0x2eeac2('0xc64')},{'value':_0x2eeac2('0x10c'),'option':_0x2eeac2('0x1eae')},{'value':_0x2eeac2('0x24a'),'option':_0x2eeac2('0x162f')},{'value':_0x2eeac2('0x69d'),'option':_0x2eeac2('0x1fbb')},{'value':_0x2eeac2('0x1741'),'option':_0x2eeac2('0x1a5')},{'value':_0x2eeac2('0x15c4'),'option':_0x2eeac2('0x5b3')},{'value':_0x2eeac2('0x243e'),'option':'EU\x20(Frankfurt)'},{'value':'eu-west-2','option':'EU\x20(London)'},{'value':'eu-west-3','option':'EU\x20(Paris)'},{'value':_0x2eeac2('0x390'),'option':_0x2eeac2('0x144a')},{'value':_0x2eeac2('0x9c0'),'option':_0x2eeac2('0xac9')},{'value':_0x2eeac2('0x180'),'option':_0x2eeac2('0x169a')},{'value':'ap-northeast-1','option':_0x2eeac2('0x1cd2')},{'value':_0x2eeac2('0x67f'),'option':_0x2eeac2('0x1202')},{'value':_0x2eeac2('0xa3d'),'option':_0x2eeac2('0x1e6c')}];}function _0x3fed50(){const _0x1d177f=_0x36e6f4;return[{'value':_0x1d177f('0x1039'),'option':_0x1d177f('0xc64')},{'value':_0x1d177f('0x69d'),'option':_0x1d177f('0x1fbb')},{'value':'eu-west-1','option':'EU\x20(Ireland)'},{'value':'ap-southeast-2','option':'Asia\x20Pacific\x20(Sydney)'}];}_0x1fcb5d['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),'currentXML',_0x36e6f4('0x24e5')];function _0x1fcb5d(_0x16642d,_0x18c367,_0x1baaf5,_0x181f0f){const _0x3420a7=this;_0x3420a7['project']={'preproduction':_0x1baaf5};function _0x5f174c(_0x5ad9e2){const _0x433595=a0_0x3f2c;_0x5ad9e2?(_0x181f0f(_0x3420a7[_0x433595('0x2588')][_0x433595('0xf66')]),_0x16642d[_0x433595('0x1197')](_0x3420a7[_0x433595('0x2588')]['preproduction'])):_0x16642d['hide']();}_0x3420a7['closeDialog']=_0x5f174c;}const _0x43fb06=_0x1fcb5d;_0xc44636[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x24e5')];function _0xc44636(_0x64f75b,_0x2a5315){const _0x1cd3ed=_0x36e6f4,_0x1f2dcf=this,_0x3ad305=0x5,_0x50c493=_0x3ad305*0x400*0x400;_0x1f2dcf[_0x1cd3ed('0x61a')]=[],_0x1f2dcf[_0x1cd3ed('0xd67')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x50c493,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x1f2dcf[_0x1cd3ed('0xe57')]={'flow':{}},_0x1f2dcf[_0x1cd3ed('0x1a5c')]=![],_0x1f2dcf[_0x1cd3ed('0x24a0')]=_0x5be2a4,_0x1f2dcf['fileAdded']=_0x2b4e0c;function _0x2b4e0c(_0x1ac45f){const _0x16c564=_0x1cd3ed;_0x1f2dcf[_0x16c564('0x61a')]=[];const _0x35ce78=[_0x16c564('0x1569')];!_0x2cfb05()[_0x16c564('0x1257')](_0x35ce78,_0x1ac45f[_0x16c564('0x26a5')]())&&_0x1f2dcf[_0x16c564('0x61a')]['push']({'message':_0x16c564('0x13f8')+_0x1ac45f[_0x16c564('0x26a5')]()+_0x16c564('0x11ec')});_0x1ac45f[_0x16c564('0x2340')]>_0x50c493&&_0x1f2dcf['errors'][_0x16c564('0x1514')]({'message':_0x16c564('0x1747')+_0x3ad305+'MB'});if(!_0x1f2dcf[_0x16c564('0x61a')]['length']){const _0x5762e9=new FileReader();_0x5762e9[_0x16c564('0x15d4')]=function(_0x4e48fc){const _0x3c1624=_0x16c564;_0x5be2a4(_0x4e48fc[_0x3c1624('0x21cc')][_0x3c1624('0x15b5')]);},_0x5762e9[_0x16c564('0x2194')](_0x1ac45f[_0x16c564('0x6bd')]);}}function _0x5be2a4(_0x51a3c7){const _0x1ae7a6=_0x1cd3ed;_0x51a3c7?(_0x2a5315(_0x51a3c7),_0x64f75b[_0x1ae7a6('0x1197')](_0x51a3c7)):_0x64f75b[_0x1ae7a6('0x1197')]();}}const _0x2e2b2f=_0xc44636;_0x52307f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x2588'),_0x36e6f4('0x19e3')];function _0x52307f(_0x2b39f6,_0x5d06c7,_0x330824,_0x29b3f7){const _0x40bc00=_0x36e6f4,_0x249190=this;_0x249190[_0x40bc00('0x2588')]=_0x2cfb05()[_0x40bc00('0xddc')](_0x330824);function _0x4640f5(){const _0x300246=_0x40bc00;_0x249190[_0x300246('0x61a')]=[],_0x29b3f7[_0x300246('0x7e4')][_0x300246('0x1449')]({'id':_0x249190['project']['id']},{'notes':_0x249190['project'][_0x300246('0x18a6')],'description':_0x249190[_0x300246('0x2588')][_0x300246('0x101c')]})[_0x300246('0xa44')][_0x300246('0x1166')](function(_0x2bedff){const _0xc7255b=_0x300246;_0x5d06c7['success']({'title':_0xc7255b('0xc8'),'msg':_0x249190[_0xc7255b('0x2588')][_0xc7255b('0x4f0')]?_0x249190[_0xc7255b('0x2588')]['name']+_0xc7255b('0xa17'):''}),_0x2b39f6[_0xc7255b('0x1197')](_0x2bedff);})[_0x300246('0x1a80')](function(_0x2ea057){const _0x4bf355=_0x300246;console[_0x4bf355('0xfc9')](_0x2ea057),_0x249190[_0x4bf355('0x61a')]=_0x2ea057[_0x4bf355('0x25f4')][_0x4bf355('0x61a')]||[{'message':_0x2ea057['toString'](),'type':'api.squareProject.update'}];});}function _0x1020d6(){const _0x263cb7=_0x40bc00;_0x2b39f6[_0x263cb7('0x1197')]();}_0x249190[_0x40bc00('0x24a0')]=_0x1020d6,_0x249190['save']=_0x4640f5;}const _0x2cd773=_0x52307f;_0x5120ed[_0x36e6f4('0x1294')]=['$mdDialog',_0x36e6f4('0x1d2e'),_0x36e6f4('0x149f'),'$window','$state'];function _0x5120ed(_0x4fee95,_0x44d030,_0x342572,_0x264b0e,_0x5b25e6){const _0x446d53=_0x36e6f4,_0x2784dd=this;_0x2784dd[_0x446d53('0x149f')]=_0x342572,_0x2784dd['id']='',_0x2784dd[_0x446d53('0x1869')]=!![];function _0x2ca963(_0x39b349){const _0x353ad9=_0x446d53;_0x2784dd[_0x353ad9('0x61a')]=[],_0x39b349?(_0x4fee95['hide'](),_0x2784dd[_0x353ad9('0x1869')]?_0x264b0e[_0x353ad9('0x1be3')](_0x353ad9('0x1f39')+_0x2784dd['id'],_0x353ad9('0x180c')):_0x5b25e6['go'](_0x353ad9('0x23a3'),{'id':_0x2784dd['id']})):_0x4fee95['hide']();}_0x2784dd[_0x446d53('0x24a0')]=_0x2ca963;}const _0x568119=_0x5120ed;_0x375cfe[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2588'),_0x36e6f4('0x149f'),_0x36e6f4('0x586')];function _0x375cfe(_0x5562cd,_0xcd025f,_0x438813,_0xd13391,_0x3b852b,_0x38a530){const _0x29cf3d=_0x36e6f4,_0x496008=this;_0x496008[_0x29cf3d('0x2588')]=_0xd13391,_0x496008[_0x29cf3d('0x23af')]=0x0,_0x496008[_0x29cf3d('0xbd7')]=[],_0x496008[_0x29cf3d('0x18e1')]=[],_0x496008[_0x29cf3d('0x24a0')]=_0x1d0855,_0x496008[_0x29cf3d('0xc68')]={'readOnly':![],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x29cf3d('0x4f0'),'line1':_0x29cf3d('0x6e1'),'line2':['name',_0x29cf3d('0x1eef')],'line3':'penalty','labelAll':_0x38a530[_0x29cf3d('0x25cc')](_0x29cf3d('0x1ed8')),'labelSelected':_0x38a530['instant'](_0x29cf3d('0x1333')),'transferCallback':function(_0x3c70b2,_0x170432){const _0x1caf11=_0x29cf3d;_0x438813[_0x1caf11('0x7e4')][_0x170432?_0x1caf11('0x20dc'):_0x1caf11('0x886')]({'id':_0x496008['project']['id'],'ids':_0x2cfb05()['map'](_0x3c70b2,'id'),'penalty':_0x496008[_0x1caf11('0x23af')]||0x0})[_0x1caf11('0xa44')]['then'](function(){const _0x536f48=_0x1caf11;_0xcd025f['success']({'title':_0x536f48('0x25a4')+(_0x170432?'removed':_0x536f48('0xaaa')),'msg':_0x536f48('0x17b5')+(_0x170432?'removed':'added')+'!'}),!_0x170432&&_0x437206();})['catch'](function(_0x190f8f){const _0x4205ce=_0x1caf11;_0xcd025f['error']({'title':_0x190f8f[_0x4205ce('0x52d')]?'API:'+_0x190f8f[_0x4205ce('0x52d')]+_0x4205ce('0x11e1')+_0x190f8f[_0x4205ce('0xe1b')]:'SYSTEM:squareProjects.ADDUSERS','msg':_0x190f8f['status']?JSON['stringify'](_0x190f8f['data']):_0x190f8f['toString']()});});}};function _0x437206(){const _0x56cfb8=_0x29cf3d;return _0x438813[_0x56cfb8('0x7e4')][_0x56cfb8('0x1bcb')]({'id':_0x496008[_0x56cfb8('0x2588')]['id'],'fields':_0x56cfb8('0x2361'),'nolimit':!![],'role':'user'})['$promise']['then'](function(_0x5a5935){const _0xad1c59=_0x56cfb8;return _0x496008[_0xad1c59('0x18e1')]=_0x5a5935['rows']?_0x2cfb05()['map'](_0x5a5935['rows'],function(_0x4c7aea){return _0x4c7aea;}):[],_0x496008[_0xad1c59('0xc68')][_0xad1c59('0x18e1')]=_0x496008[_0xad1c59('0x18e1')],_0x438813['user'][_0xad1c59('0xd83')]({'fields':_0xad1c59('0x46d'),'role':'user','nolimit':!![]})[_0xad1c59('0xa44')];})[_0x56cfb8('0x1166')](function(_0x451f09){const _0x11bbb2=_0x56cfb8;_0x496008['items']=_0x451f09[_0x11bbb2('0x269a')]?_0x2cfb05()['map'](_0x451f09[_0x11bbb2('0x269a')],function(_0xe9232f){return _0xe9232f;}):[],_0x496008['dualMultiselectOptions'][_0x11bbb2('0xbd7')]=_0x2cfb05()[_0x11bbb2('0x24ac')](_0x496008['items'],_0x496008[_0x11bbb2('0x18e1')],'id');})[_0x56cfb8('0x1a80')](function(_0x37904d){const _0x402454=_0x56cfb8;_0xcd025f['error']({'title':_0x37904d['status']?_0x402454('0x1e21')+_0x37904d['status']+'\x20-\x20'+_0x37904d[_0x402454('0xe1b')]:_0x402454('0xe3e'),'msg':_0x37904d['status']?JSON[_0x402454('0xbac')](_0x37904d[_0x402454('0x25f4')]):_0x37904d[_0x402454('0x1586')]()});});}function _0x1d0855(){const _0x18075d=_0x29cf3d;_0x5562cd[_0x18075d('0x1197')]();}_0x437206();}const _0x2371b0=_0x375cfe;_0x8642e5[_0x36e6f4('0x1294')]=['$mdDialog',_0x36e6f4('0x1d2e'),_0x36e6f4('0x2588'),_0x36e6f4('0x18a9'),_0x36e6f4('0x19e3'),'$window',_0x36e6f4('0x7b9')];function _0x8642e5(_0x88a4c9,_0x5cfb91,_0x55d0b5,_0x2dfb22,_0x23fc93,_0x2f2777,_0x54f86f){const _0x5c79c5=_0x36e6f4,_0x4c7238=this;_0x4c7238[_0x5c79c5('0x2588')]=angular[_0x5c79c5('0x225f')](_0x55d0b5),_0x4c7238['project'][_0x5c79c5('0x4f0')]+=_0x5c79c5('0x1f06'),_0x4c7238[_0x5c79c5('0x2588')][_0x5c79c5('0xf66')]=_0x2dfb22,_0x4c7238['newWindow']=!![];function _0x119aff(){const _0x5be5f2=_0x5c79c5;delete _0x4c7238['project']['id'],_0x23fc93[_0x5be5f2('0x7e4')][_0x5be5f2('0x9cc')](_0x4c7238[_0x5be5f2('0x2588')])[_0x5be5f2('0xa44')][_0x5be5f2('0x1166')](function(_0x4e8c34){const _0x11b0a7=_0x5be5f2;_0x5cfb91[_0x11b0a7('0x103b')]({'title':_0x11b0a7('0x1694'),'msg':_0x4c7238[_0x11b0a7('0x2588')][_0x11b0a7('0x4f0')]?_0x4c7238[_0x11b0a7('0x2588')][_0x11b0a7('0x4f0')]+_0x11b0a7('0x1eda'):''}),_0x88a4c9[_0x11b0a7('0x1197')](_0x4e8c34),_0x4c7238[_0x11b0a7('0x1869')]?_0x2f2777['open'](_0x11b0a7('0x1f39')+_0x4e8c34['id'],_0x11b0a7('0x180c')):_0x54f86f['go'](_0x11b0a7('0x23a3'),{'id':_0x4e8c34['id']});})[_0x5be5f2('0x1a80')](function(_0xfe74c9){const _0x1351ff=_0x5be5f2;console[_0x1351ff('0xfc9')](_0xfe74c9),_0x4c7238['errors']=_0xfe74c9[_0x1351ff('0x25f4')][_0x1351ff('0x61a')]||[{'message':_0xfe74c9[_0x1351ff('0x1586')](),'type':'api.squareProject.save'}];});}function _0x128464(){const _0x4909dc=_0x5c79c5;_0x88a4c9[_0x4909dc('0x1197')]();}_0x4c7238[_0x5c79c5('0x24a0')]=_0x128464,_0x4c7238[_0x5c79c5('0x9cc')]=_0x119aff;}const _0x46dc23=_0x8642e5,_0x40b928=_0x2734b2['p']+'src/js/modules/main/apps/callysquare/views/projects/edit/dialog/dialog.html/dialog.html',_0x388285=_0x2734b2['p']+_0x36e6f4('0x2a4'),_0x531563=_0x2734b2['p']+'src/js/modules/main/apps/callysquare/views/projects/edit/open/open.html/open.html',_0x28b4af=_0x2734b2['p']+_0x36e6f4('0x20c'),_0x551111=_0x2734b2['p']+_0x36e6f4('0x1af6'),_0x326681=_0x2734b2['p']+'src/js/modules/main/apps/callysquare/views/projects/edit/edit/edit.html/edit.html',_0x381e9=_0x2734b2['p']+_0x36e6f4('0x27c5');_0x4ad46a[_0x36e6f4('0x1294')]=['$state','$document',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'project','users',_0x36e6f4('0xf24'),_0x36e6f4('0x7a7'),_0x36e6f4('0x137'),'variables',_0x36e6f4('0xd24'),_0x36e6f4('0x160a'),_0x36e6f4('0x149f'),'intervals',_0x36e6f4('0xf85'),'templates','lists',_0x36e6f4('0x1d76'),_0x36e6f4('0xe29'),_0x36e6f4('0x17aa'),'Auth'];const _0x245330=window[_0x36e6f4('0xd3a')],_0x1e1a68=window[_0x36e6f4('0x666')];function _0x4ad46a(_0x47ef56,_0x47c71a,_0x34bad7,_0x47036e,_0x59f79b,_0x11ea58,_0x237251,_0x524a89,_0x2073e5,_0x4241b7,_0x1366eb,_0xf03366,_0x5be9b3,_0xc007d0,_0x3b77fd,_0x4cbee7,_0x485867,_0x960257,_0x2b552c,_0x26492d,_0x1bbef6,_0x38727f,_0x52e0d6,_0x1bbf84){const _0x586d05=_0x36e6f4,_0x44414c=this;_0x44414c[_0x586d05('0x98')]=_0x1bbf84[_0x586d05('0x26cd')](),_0x44414c['project']=_0x524a89||{},_0x44414c['userProfileSection']=_0x52e0d6&&_0x52e0d6['count']==0x1?_0x52e0d6[_0x586d05('0x269a')][0x0]:null,_0x44414c[_0x586d05('0x243c')]=_0x1bbf84[_0x586d05('0xd87')](_0x44414c[_0x586d05('0x17aa')]?_0x44414c[_0x586d05('0x17aa')][_0x586d05('0x243c')]:null),_0x44414c[_0x586d05('0xae0')]=_0xb66a10,_0x44414c[_0x586d05('0x20c1')]=_0x27e5a3,_0x44414c[_0x586d05('0xabe')]=_0x5a04fd,_0x44414c[_0x586d05('0x5e0')]=_0x57400b,_0x44414c[_0x586d05('0xb6')]=_0x4724ba,_0x44414c['saveProjectAs']=_0x42c654,_0x44414c[_0x586d05('0x2839')]=_0x20ff49,_0x44414c[_0x586d05('0x13b4')]=_0x3e1544,_0x44414c[_0x586d05('0xa9')]=_0x3f867c,_0x44414c['importXML']=_0x1fc7eb,_0x44414c[_0x586d05('0xa80')]=_0x24182b;function _0xb66a10(){const _0xc74b17=_0x586d05,_0x212bae=new _0x245330(_0x44414c,new _0x1e1a68(),document[_0xc74b17('0xc47')](_0xc74b17('0x1052')));_0x212bae['openString'](_0x44414c[_0xc74b17('0x2588')][_0xc74b17('0xf66')],_0x44414c['project'][_0xc74b17('0x4f0')],_0x44414c['project']);}function _0x5a04fd(_0x3ed37f,_0x2599b6){const _0x3d955d=_0x586d05;_0x34bad7[_0x3d955d('0x1f80')]({'controller':'MxGraphDialogController','controllerAs':'vm','templateUrl':_0x40b928,'parent':angular[_0x3d955d('0x1194')](_0x47c71a['body']),'clickOutsideToClose':!![],'locals':{'users':_0x2073e5[_0x3d955d('0x269a')]||[],'trunks':_0x4241b7[_0x3d955d('0x269a')]||[],'queues':_0x1366eb[_0x3d955d('0x269a')]||[],'sounds':_0xf03366[_0x3d955d('0x269a')]||[],'variables':_0x5be9b3[_0x3d955d('0x269a')]||[],'databases':_0xc007d0['rows']||[],'contexts':_0x3b77fd[_0x3d955d('0x269a')]||[],'projects':_0x4cbee7[_0x3d955d('0x269a')]||[],'intervals':_0x485867[_0x3d955d('0x269a')]||[],'mailAccounts':_0x960257['rows']||[],'smsAccounts':_0x1bbef6[_0x3d955d('0x269a')]||[],'pauses':_0x38727f[_0x3d955d('0x269a')]||[],'templates':_0x2b552c[_0x3d955d('0x269a')]||[],'lists':_0x26492d[_0x3d955d('0x269a')]||[],'cell':_0x3ed37f,'saveCallback':_0x2599b6,'crudPermissions':_0x44414c[_0x3d955d('0x243c')]}});}function _0x57400b(_0x25c017){const _0x455afe=_0x586d05;_0x34bad7['show']({'controller':'CreateOrEditSquareProjectDialogController','controllerAs':'vm','templateUrl':_0x388285,'parent':angular['element'](_0x47c71a[_0x455afe('0x8d2')]),'clickOutsideToClose':!![],'locals':{'project':_0x25c017,'projects':_0x4cbee7[_0x455afe('0x269a')],'openFromEditor':!![],'license':null,'setting':null,'crudPermissions':_0x44414c[_0x455afe('0x243c')]}});}function _0x4724ba(){const _0x3b69ef=_0x586d05;_0x34bad7[_0x3b69ef('0x1f80')]({'controller':_0x3b69ef('0x1d80'),'controllerAs':'vm','templateUrl':_0x531563,'parent':angular[_0x3b69ef('0x1194')](_0x47c71a[_0x3b69ef('0x8d2')]),'clickOutsideToClose':!![],'locals':{'projects':_0x4cbee7[_0x3b69ef('0x269a')]||[]}});}function _0x42c654(_0x1e8c0a){const _0x5a05dc=_0x586d05;_0x34bad7[_0x5a05dc('0x1f80')]({'controller':_0x5a05dc('0x129c'),'controllerAs':'vm','templateUrl':_0x28b4af,'parent':angular[_0x5a05dc('0x1194')](_0x47c71a[_0x5a05dc('0x8d2')]),'clickOutsideToClose':!![],'locals':{'project':_0x44414c[_0x5a05dc('0x2588')],'currentXML':_0x1e8c0a}})[_0x5a05dc('0x1166')](function(_0x137379){const _0x14a6f6=_0x5a05dc;_0x137379&&_0x4cbee7[_0x14a6f6('0x269a')][_0x14a6f6('0x1514')](_0x137379);});}function _0x3703f2(){return _0x47036e(function(_0x1dcd70,_0x3107f8){const _0x20e39e=a0_0x3f2c;return _0x237251[_0x20e39e('0x17aa')]['get']({'userProfileId':_0x44414c[_0x20e39e('0x98')][_0x20e39e('0xb86')],'sectionId':0x3f4})[_0x20e39e('0xa44')][_0x20e39e('0x1166')](function(_0x26de90){const _0x1db95c=_0x20e39e,_0x5b4705=_0x26de90['rows']?_0x26de90['rows'][0x0]:null,_0x31796a=_0x1bbf84[_0x1db95c('0xd87')](_0x5b4705?_0x5b4705[_0x1db95c('0x243c')]:null);_0x1dcd70(_0x31796a);})[_0x20e39e('0x1a80')](function(_0x2607f4){_0x3107f8(_0x2607f4);});});}function _0x20ff49(_0x381b19){return _0x3703f2()['then'](function(_0x144a89){const _0x4c4b5b=a0_0x3f2c;_0x144a89[_0x4c4b5b('0x1684')]?_0x34bad7[_0x4c4b5b('0x1f80')]({'controller':_0x4c4b5b('0x27d0'),'controllerAs':'vm','templateUrl':_0x13db5a,'parent':angular['element'](_0x47c71a[_0x4c4b5b('0x8d2')]),'clickOutsideToClose':!![],'locals':{'variable':_0x381b19,'variables':_0x5be9b3[_0x4c4b5b('0x269a')],'license':null,'setting':null,'crudPermissions':_0x144a89}}):_0x11ea58[_0x4c4b5b('0x1fa1')]({'title':_0x59f79b['instant']('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x59f79b[_0x4c4b5b('0x25cc')](_0x4c4b5b('0x1f9b'))});})['catch'](function(_0x544e99){const _0x5b1929=a0_0x3f2c;_0x11ea58[_0x5b1929('0xfc9')]({'title':_0x544e99['status']?_0x5b1929('0x1e21')+_0x544e99[_0x5b1929('0x52d')]+_0x5b1929('0x11e1')+_0x544e99[_0x5b1929('0xe1b')]:_0x5b1929('0x144e'),'msg':_0x544e99[_0x5b1929('0x25f4')]?JSON[_0x5b1929('0xbac')](_0x544e99['data']):_0x544e99[_0x5b1929('0x1586')]()});});}function _0x3e1544(_0x22dae1){const _0x441970=_0x586d05;_0x34bad7[_0x441970('0x1f80')]({'controller':_0x441970('0x1a62'),'controllerAs':'vm','templateUrl':_0x551111,'parent':angular['element'](_0x47c71a[_0x441970('0x8d2')]),'targetEvent':_0x22dae1,'clickOutsideToClose':!![],'locals':{'project':_0x44414c[_0x441970('0x2588')]}})['then'](function(_0x3f7a10){const _0xf778e6=_0x441970;_0x3f7a10&&_0x2cfb05()[_0xf778e6('0xcc3')](_0x44414c[_0xf778e6('0x2588')],_0x3f7a10);});}function _0x3f867c(_0x5e93d0,_0x3dd6ae){const _0x1a38e0=_0x586d05;_0x34bad7[_0x1a38e0('0x1f80')]({'controller':_0x1a38e0('0x419'),'controllerAs':'vm','templateUrl':_0x326681,'parent':angular[_0x1a38e0('0x1194')](_0x47c71a[_0x1a38e0('0x8d2')]),'clickOutsideToClose':!![],'locals':{'currentXML':_0x5e93d0,'saveCallback':_0x3dd6ae}})[_0x1a38e0('0x1166')](function(_0x174458){const _0x3fa62e=_0x1a38e0;_0x174458&&(_0x44414c['project'][_0x3fa62e('0xf66')]=_0x174458);});}function _0x1fc7eb(_0x1cf3d9){const _0x34bb7d=_0x586d05;_0x34bad7[_0x34bb7d('0x1f80')]({'controller':_0x34bb7d('0xe2'),'controllerAs':'vm','templateUrl':_0x381e9,'parent':angular[_0x34bb7d('0x1194')](_0x47c71a[_0x34bb7d('0x8d2')]),'clickOutsideToClose':!![],'locals':{'saveCallback':_0x1cf3d9}})[_0x34bb7d('0x1166')](function(_0x2aaa2e){const _0x2eb9aa=_0x34bb7d;_0x2aaa2e&&(_0x44414c[_0x2eb9aa('0x2588')][_0x2eb9aa('0xf66')]=_0x2aaa2e);});}function _0x27e5a3(_0x545469,_0x35d9ba){const _0x55a41d=_0x586d05,_0xc42862={'preproduction':_0x545469};_0x35d9ba&&(_0xc42862[_0x55a41d('0x80')]=_0x545469),_0x237251[_0x55a41d('0x7e4')][_0x55a41d('0x1449')]({'id':_0x44414c[_0x55a41d('0x2588')]['id']},_0xc42862)[_0x55a41d('0xa44')][_0x55a41d('0x1166')](function(_0x53ff69){const _0x4cc1d8=_0x55a41d;_0x11ea58['success']({'title':_0x4cc1d8('0x1e36')+(_0x35d9ba?'published':_0x4cc1d8('0x26ae'))+'!','msg':_0x44414c[_0x4cc1d8('0x2588')][_0x4cc1d8('0x4f0')]?_0x44414c['project'][_0x4cc1d8('0x4f0')]+'\x20has\x20been\x20'+(_0x35d9ba?_0x4cc1d8('0xff7'):_0x4cc1d8('0x26ae'))+'!':''}),_0x44414c[_0x4cc1d8('0x2588')]['preproduction']=_0x53ff69[_0x4cc1d8('0xf66')];})['catch'](function(_0x4fb5f4){const _0x337d3b=_0x55a41d;_0x11ea58[_0x337d3b('0xfc9')]({'title':_0x4fb5f4[_0x337d3b('0x52d')]?_0x337d3b('0x1e21')+_0x4fb5f4[_0x337d3b('0x52d')]+_0x337d3b('0x11e1')+_0x4fb5f4[_0x337d3b('0xe1b')]:_0x337d3b('0x16f1'),'msg':_0x4fb5f4[_0x337d3b('0x25f4')]?JSON[_0x337d3b('0xbac')](_0x4fb5f4[_0x337d3b('0x25f4')]):_0x4fb5f4[_0x337d3b('0x1586')]()});});}function _0x24182b(){const _0x1aae56=_0x586d05;_0x47ef56['go'](_0x1aae56('0x2040'),{},{'reload':_0x1aae56('0x2040')});}}const _0x49d549=_0x4ad46a;_0x1f0d70[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0xc46'),'projects','userProfile','userProfileSection',_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x1f0d70(_0x6d41c5,_0x2d23ba,_0x6e870f,_0x58e43c,_0x21f44f,_0x5dc6dd,_0xb548bf,_0x18b239,_0x3c0786,_0x1e4440,_0x104e73,_0x3b30a4,_0x34c8d9){const _0x15cfbf=_0x36e6f4,_0x4946a0=this;_0x4946a0[_0x15cfbf('0x98')]=_0x34c8d9['getCurrentUser'](),_0x4946a0['projects']=_0x58e43c||{'count':0x0,'rows':[]},_0x4946a0[_0x15cfbf('0x7f')]=_0x21f44f,_0x4946a0[_0x15cfbf('0x17aa')]=_0x5dc6dd&&_0x5dc6dd[_0x15cfbf('0x240f')]==0x1?_0x5dc6dd['rows'][0x0]:null,_0x4946a0[_0x15cfbf('0x243c')]=_0x34c8d9['parseCrudPermissions'](_0x4946a0['userProfileSection']?_0x4946a0[_0x15cfbf('0x17aa')]['crudPermissions']:null),_0x4946a0[_0x15cfbf('0x916')]=_0x15cfbf('0x149f'),_0x4946a0[_0x15cfbf('0xef5')]='',_0x4946a0[_0x15cfbf('0x104c')]=null,_0x4946a0['selectedProjects']=[],_0x4946a0[_0x15cfbf('0x2218')]={'fields':'id,name,description,notes','sort':'-updatedAt','limit':0xa,'page':0x1},_0x4946a0[_0x15cfbf('0x1ff6')]=_0x56584f,_0x4946a0[_0x15cfbf('0x8d8')]=_0x48ab2b,_0x4946a0[_0x15cfbf('0x103b')]=_0x3767bd,_0x4946a0[_0x15cfbf('0x948')]=_0x2e2c84,_0x4946a0['createOrEditProject']=_0x4d066c,_0x4946a0['deleteProject']=_0x5e2aed,_0x4946a0['exportSelectedProjects']=_0x4cb6e4,_0x4946a0['deleteSelectedProjects']=_0x244684,_0x4946a0['deselectProjects']=_0x4efb18,_0x4946a0['selectAllProjects']=_0x51267d;function _0x56584f(_0x218bcb){const _0x5c4634=_0x15cfbf;_0x2d23ba['go'](_0x5c4634('0x23a3'),{'id':_0x218bcb['id'],'crudPermissions':_0x4946a0[_0x5c4634('0x243c')]});}function _0x48ab2b(_0x2b91ee,_0x448fe0){const _0x3adec1=_0x15cfbf,_0x2cca13=_0x3c0786['confirm']()[_0x3adec1('0xcdc')](_0x3adec1('0x220f'))[_0x3adec1('0xf3c')](''+_0x2b91ee[_0x3adec1('0x4f0')]+_0x3adec1('0xace')+'\x20will\x20be\x20deleted.')[_0x3adec1('0x8e8')]('delete\x20project')['targetEvent'](_0x448fe0)['ok']('OK')[_0x3adec1('0x3f')](_0x3adec1('0x2d3'));_0x3c0786[_0x3adec1('0x1f80')](_0x2cca13)[_0x3adec1('0x1166')](function(){_0x5e2aed(_0x2b91ee);},function(){const _0x5e82c1=_0x3adec1;console[_0x5e82c1('0x455')]('CANCEL');});}let _0xb564cf=!![],_0x5d83ca=0x1;_0x6d41c5[_0x15cfbf('0xe83')](_0x15cfbf('0x12d8'),function(_0x383aae,_0x27e792){const _0x9d0bdf=_0x15cfbf;_0xb564cf?_0x104e73(function(){_0xb564cf=![];}):(!_0x27e792&&(_0x5d83ca=_0x4946a0[_0x9d0bdf('0x2218')][_0x9d0bdf('0x1a43')]),_0x383aae!==_0x27e792&&(_0x4946a0[_0x9d0bdf('0x2218')][_0x9d0bdf('0x1a43')]=0x1),!_0x383aae&&(_0x4946a0[_0x9d0bdf('0x2218')][_0x9d0bdf('0x1a43')]=_0x5d83ca),_0x4946a0['getProjects']());});function _0x3767bd(_0x1139aa){const _0x323cb8=_0x15cfbf;_0x4946a0[_0x323cb8('0x149f')]=_0x1139aa||{'count':0x0,'rows':[]};}function _0x2e2c84(){const _0xcf10db=_0x15cfbf;_0x4946a0[_0xcf10db('0x2218')]['offset']=(_0x4946a0[_0xcf10db('0x2218')][_0xcf10db('0x1a43')]-0x1)*_0x4946a0[_0xcf10db('0x2218')][_0xcf10db('0x163f')],_0x34c8d9[_0xcf10db('0x1ac6')]('admin')?_0x4946a0[_0xcf10db('0x1f48')]=_0xb548bf[_0xcf10db('0x7e4')][_0xcf10db('0xd83')](_0x4946a0[_0xcf10db('0x2218')],_0x3767bd)[_0xcf10db('0xa44')]:(_0x4946a0['query']['id']=_0x4946a0[_0xcf10db('0x7f')]['id'],_0x4946a0[_0xcf10db('0x2218')]['section']='SquareProjects',_0x4946a0[_0xcf10db('0x1f48')]=_0xb548bf[_0xcf10db('0x7f')][_0xcf10db('0x263a')](_0x4946a0['query'],_0x3767bd)['$promise']);}function _0x4d066c(_0x2451f7,_0x38778b){const _0x55ab18=_0x15cfbf;_0x3c0786[_0x55ab18('0x1f80')]({'controller':_0x55ab18('0x753'),'controllerAs':'vm','templateUrl':_0x388285,'parent':angular[_0x55ab18('0x1194')](_0x1e4440[_0x55ab18('0x8d2')]),'targetEvent':_0x2451f7,'clickOutsideToClose':!![],'locals':{'project':_0x38778b,'projects':_0x4946a0[_0x55ab18('0x149f')]['rows'],'openFromEditor':null,'setting':null,'crudPermissions':_0x4946a0[_0x55ab18('0x243c')]}});}function _0x5e2aed(_0x35bd44){const _0x31bfe4=_0x15cfbf;_0xb548bf[_0x31bfe4('0x7e4')][_0x31bfe4('0x906')]({'id':_0x35bd44['id']})['$promise'][_0x31bfe4('0x1166')](function(){const _0x24de88=_0x31bfe4;_0x2cfb05()['remove'](_0x4946a0[_0x24de88('0x149f')][_0x24de88('0x269a')],{'id':_0x35bd44['id']}),_0x4946a0[_0x24de88('0x149f')][_0x24de88('0x240f')]-=0x1,!_0x4946a0['projects'][_0x24de88('0x269a')][_0x24de88('0x264b')]&&_0x4946a0[_0x24de88('0x948')](),_0x3b30a4['success']({'title':'Project\x20deleted!','msg':_0x35bd44[_0x24de88('0x4f0')]?_0x35bd44[_0x24de88('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0x31bfe4('0x1a80')](function(_0x231924){const _0x556593=_0x31bfe4;if(_0x231924[_0x556593('0x25f4')]&&_0x231924[_0x556593('0x25f4')][_0x556593('0x61a')]&&_0x231924[_0x556593('0x25f4')]['errors'][_0x556593('0x264b')]){_0x4946a0[_0x556593('0x61a')]=_0x231924[_0x556593('0x25f4')][_0x556593('0x61a')]||[{'message':_0x231924['toString'](),'type':_0x556593('0x201c')}];for(let _0x1750a1=0x0;_0x1750a1<_0x231924[_0x556593('0x25f4')]['errors']['length'];_0x1750a1++){_0x3b30a4['error']({'title':_0x231924[_0x556593('0x25f4')]['errors'][_0x1750a1]['type'],'msg':_0x231924[_0x556593('0x25f4')]['errors'][_0x1750a1]['message']});}}else _0x3b30a4[_0x556593('0xfc9')]({'title':_0x231924[_0x556593('0x52d')]?_0x556593('0x1e21')+_0x231924[_0x556593('0x52d')]+_0x556593('0x11e1')+_0x231924['statusText']:'api.project.delete','msg':_0x231924[_0x556593('0x25f4')]?JSON['stringify'](_0x231924[_0x556593('0x25f4')][_0x556593('0x1e70')]):_0x231924['message']||_0x231924['toString']()});});}function _0x4cb6e4(){const _0x5758fb=_0x15cfbf,_0x4d443d=angular[_0x5758fb('0x225f')](_0x4946a0[_0x5758fb('0x11ce')]);return _0x4946a0[_0x5758fb('0x11ce')]=[],_0x4d443d;}function _0x244684(_0x3b65ac){const _0x515d75=_0x15cfbf,_0x123934=_0x3c0786['confirm']()[_0x515d75('0xcdc')](_0x515d75('0x1547'))[_0x515d75('0xf3c')](''+_0x4946a0[_0x515d75('0x11ce')][_0x515d75('0x264b')]+_0x515d75('0x196d')+'\x20will\x20be\x20deleted.')[_0x515d75('0x8e8')](_0x515d75('0x1369'))[_0x515d75('0x203b')](_0x3b65ac)['ok']('OK')[_0x515d75('0x3f')](_0x515d75('0x2d3'));_0x3c0786[_0x515d75('0x1f80')](_0x123934)[_0x515d75('0x1166')](function(){const _0x36f654=_0x515d75;_0x4946a0[_0x36f654('0x11ce')][_0x36f654('0x2782')](function(_0xb4e40e){_0x5e2aed(_0xb4e40e);}),_0x4946a0[_0x36f654('0x11ce')]=[];});}function _0x4efb18(){_0x4946a0['selectedProjects']=[];}function _0x51267d(){const _0x1cec1f=_0x15cfbf;_0x4946a0[_0x1cec1f('0x11ce')]=_0x4946a0[_0x1cec1f('0x149f')][_0x1cec1f('0x269a')];}}const _0x23b879=_0x1f0d70;_0x33e360[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x33e360(_0x311734){const _0x53586e=_0x36e6f4;_0x311734[_0x53586e('0x63f')](_0x53586e('0x2040'),{'url':_0x53586e('0x12da'),'views':{'content@app':{'templateUrl':_0x5293b2,'controller':_0x53586e('0xd8')}},'resolve':{'projects':[_0x53586e('0x1fbc'),_0x53586e('0x21ef'),function(_0x31e103,_0x4a04b9){const _0x3773dc=_0x53586e;return _0x4a04b9['hasRole'](_0x3773dc('0xa7c'))?_0x31e103[_0x3773dc('0x18af')](_0x3773dc('0x1fd2'),{'fields':_0x3773dc('0x1c6b'),'sort':_0x3773dc('0x4f0'),'limit':0xa,'offset':0x0}):_0x31e103[_0x3773dc('0x18af')]('userProfile@getResources',{'id':_0x4a04b9[_0x3773dc('0x26cd')]()[_0x3773dc('0xb86')],'section':_0x3773dc('0x2503'),'fields':_0x3773dc('0x1c6b'),'sort':_0x3773dc('0x4f0'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver','Auth',function(_0x4e6ee0,_0x401338){const _0x3775bc=_0x53586e;return _0x4e6ee0[_0x3775bc('0x18af')](_0x3775bc('0x697'),{'fields':'id,name,crudPermissions','id':_0x401338['getCurrentUser']()[_0x3775bc('0xb86')]});}],'userProfileSection':['apiResolver',_0x53586e('0x21ef'),function(_0x1162be,_0x24100b){const _0xad8efa=_0x53586e;return _0x1162be[_0xad8efa('0x18af')](_0xad8efa('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x24100b[_0xad8efa('0x26cd')]()[_0xad8efa('0xb86')],'sectionId':0x44f});}]},'authenticate':!![],'permissionId':0x44f,'bodyClass':_0x53586e('0xae5')})['state'](_0x53586e('0x23a3'),{'url':_0x53586e('0x10f3'),'views':{'content@app':{'templateUrl':_0x4d11f6,'controller':'ProjectController\x20as\x20vm'}},'params':{'crudPermissions':undefined},'resolve':{'project':['apiResolver','$stateParams',function(_0xf2e394,_0x405a4f){const _0x47dae4=_0x53586e;return _0xf2e394['resolve'](_0x47dae4('0x1fd2'),{'id':_0x405a4f['id']});}],'users':[_0x53586e('0x1fbc'),_0x53586e('0x21ef'),function(_0x7b58b5,_0x2979bc){const _0x19926f=_0x53586e;return _0x2979bc[_0x19926f('0x1ac6')]('admin')?_0x7b58b5[_0x19926f('0x18af')](_0x19926f('0x1c80'),{'fields':_0x19926f('0x5d2'),'sort':_0x19926f('0x4f0'),'nolimit':!![]}):_0x7b58b5[_0x19926f('0x18af')](_0x19926f('0x17c4'),{'id':_0x2979bc[_0x19926f('0x26cd')]()[_0x19926f('0xb86')],'section':'Users','mergeResources':!![],'fields':_0x19926f('0x5d2'),'sort':_0x19926f('0x4f0'),'nolimit':!![]});}],'trunks':['apiResolver','Auth',function(_0x4d251e,_0x537cb0){const _0x5c6615=_0x53586e;return _0x537cb0[_0x5c6615('0x1ac6')](_0x5c6615('0xa7c'))?_0x4d251e[_0x5c6615('0x18af')](_0x5c6615('0xfb8'),{'fields':'id,name','sort':_0x5c6615('0x4f0'),'nolimit':!![]}):_0x4d251e[_0x5c6615('0x18af')]('userProfile@getResources',{'id':_0x537cb0[_0x5c6615('0x26cd')]()[_0x5c6615('0xb86')],'section':_0x5c6615('0x2685'),'fields':'id,name','sort':_0x5c6615('0x4f0'),'nolimit':!![]});}],'queues':['apiResolver',_0x53586e('0x21ef'),function(_0x1e477b,_0x23cb51){const _0x3f92f5=_0x53586e;return _0x23cb51['hasRole'](_0x3f92f5('0xa7c'))?_0x1e477b[_0x3f92f5('0x18af')]('voiceQueue@get',{'type':_0x3f92f5('0x14d8'),'fields':_0x3f92f5('0x1776'),'sort':_0x3f92f5('0x4f0'),'nolimit':!![]}):_0x1e477b[_0x3f92f5('0x18af')]('userProfile@getResources',{'id':_0x23cb51[_0x3f92f5('0x26cd')]()[_0x3f92f5('0xb86')],'section':_0x3f92f5('0x1ba2'),'type':'inbound','fields':'id,name','sort':_0x3f92f5('0x4f0'),'nolimit':!![]});}],'sounds':[_0x53586e('0x1fbc'),'Auth',function(_0x3000d1,_0x3f1921){const _0xd9226f=_0x53586e;return _0x3f1921['hasRole'](_0xd9226f('0xa7c'))?_0x3000d1[_0xd9226f('0x18af')]('sound@get',{'fields':_0xd9226f('0x1776'),'sort':_0xd9226f('0x4f0'),'nolimit':!![]}):_0x3000d1['resolve'](_0xd9226f('0x17c4'),{'id':_0x3f1921['getCurrentUser']()[_0xd9226f('0xb86')],'section':_0xd9226f('0x1ece'),'fields':_0xd9226f('0x1776'),'sort':'name','nolimit':!![]});}],'variables':[_0x53586e('0x1fbc'),_0x53586e('0x21ef'),function(_0xd71e26,_0x1671c6){const _0x98bea3=_0x53586e;return _0x1671c6[_0x98bea3('0x1ac6')]('admin')?_0xd71e26[_0x98bea3('0x18af')](_0x98bea3('0x185a'),{'fields':_0x98bea3('0x1776'),'sort':_0x98bea3('0x4f0'),'nolimit':!![]}):_0xd71e26[_0x98bea3('0x18af')](_0x98bea3('0x17c4'),{'id':_0x1671c6[_0x98bea3('0x26cd')]()[_0x98bea3('0xb86')],'section':_0x98bea3('0xb77'),'fields':_0x98bea3('0x1776'),'sort':_0x98bea3('0x4f0'),'nolimit':!![]});}],'databases':['apiResolver','Auth',function(_0x564a2e,_0x19aff6){const _0x1bd077=_0x53586e;return _0x19aff6[_0x1bd077('0x1ac6')](_0x1bd077('0xa7c'))?_0x564a2e['resolve']('squareOdbc@get',{'fields':_0x1bd077('0x1776'),'sort':_0x1bd077('0x4f0'),'nolimit':!![]}):_0x564a2e[_0x1bd077('0x18af')](_0x1bd077('0x17c4'),{'id':_0x19aff6[_0x1bd077('0x26cd')]()[_0x1bd077('0xb86')],'section':_0x1bd077('0x1b6'),'fields':_0x1bd077('0x1776'),'sort':_0x1bd077('0x4f0'),'nolimit':!![]});}],'projects':[_0x53586e('0x1fbc'),_0x53586e('0x21ef'),function(_0x326d32,_0x79c930){const _0x33847a=_0x53586e;return _0x79c930[_0x33847a('0x1ac6')]('admin')?_0x326d32[_0x33847a('0x18af')](_0x33847a('0x1fd2'),{'fields':_0x33847a('0x1776'),'sort':'name','nolimit':!![]}):_0x326d32[_0x33847a('0x18af')]('userProfile@getResources',{'id':_0x79c930[_0x33847a('0x26cd')]()[_0x33847a('0xb86')],'section':_0x33847a('0x2503'),'fields':_0x33847a('0x1776'),'sort':'name','nolimit':!![]});}],'contexts':[_0x53586e('0x1fbc'),_0x53586e('0x21ef'),function(_0x2d3f51,_0x112f1d){const _0x2dcd58=_0x53586e;return _0x112f1d['hasRole'](_0x2dcd58('0xa7c'))?_0x2d3f51[_0x2dcd58('0x18af')](_0x2dcd58('0xa59'),{'fields':_0x2dcd58('0x1776'),'sort':_0x2dcd58('0x4f0'),'nolimit':!![]}):_0x2d3f51[_0x2dcd58('0x18af')](_0x2dcd58('0x17c4'),{'id':_0x112f1d[_0x2dcd58('0x26cd')]()['userProfileId'],'section':_0x2dcd58('0x136e'),'fields':_0x2dcd58('0x1776'),'sort':_0x2dcd58('0x4f0'),'nolimit':!![]});}],'intervals':[_0x53586e('0x1fbc'),_0x53586e('0x21ef'),function(_0x4530a6,_0x4e1c2b){const _0x3fffb8=_0x53586e;return _0x4e1c2b[_0x3fffb8('0x1ac6')](_0x3fffb8('0xa7c'))?_0x4530a6[_0x3fffb8('0x18af')]('interval@get',{'fields':_0x3fffb8('0x190c'),'sort':_0x3fffb8('0x4f0'),'nolimit':!![]}):_0x4530a6['resolve'](_0x3fffb8('0x17c4'),{'id':_0x4e1c2b['getCurrentUser']()['userProfileId'],'section':_0x3fffb8('0x463'),'fields':'id,name,IntervalId','sort':_0x3fffb8('0x4f0'),'nolimit':!![]});}],'mailAccounts':[_0x53586e('0x1fbc'),_0x53586e('0x21ef'),function(_0x5175b7,_0x2f6dcf){const _0x5642f1=_0x53586e;return _0x2f6dcf[_0x5642f1('0x1ac6')](_0x5642f1('0xa7c'))?_0x5175b7[_0x5642f1('0x18af')](_0x5642f1('0x1d62'),{'fields':_0x5642f1('0x1776'),'sort':_0x5642f1('0x4f0'),'nolimit':!![]}):_0x5175b7[_0x5642f1('0x18af')](_0x5642f1('0x17c4'),{'id':_0x2f6dcf[_0x5642f1('0x26cd')]()[_0x5642f1('0xb86')],'section':'MailAccounts','fields':_0x5642f1('0x1776'),'sort':_0x5642f1('0x4f0'),'nolimit':!![]});}],'templates':[_0x53586e('0x1fbc'),_0x53586e('0x21ef'),function(_0x359461,_0x55eeb1){const _0x5e89f6=_0x53586e;return _0x55eeb1['hasRole'](_0x5e89f6('0xa7c'))?_0x359461[_0x5e89f6('0x18af')](_0x5e89f6('0x872'),{'fields':_0x5e89f6('0x1776'),'sort':_0x5e89f6('0x4f0'),'nolimit':!![]}):_0x359461['resolve'](_0x5e89f6('0x17c4'),{'id':_0x55eeb1['getCurrentUser']()['userProfileId'],'section':'Templates','fields':'id,name','sort':_0x5e89f6('0x4f0'),'nolimit':!![]});}],'lists':[_0x53586e('0x1fbc'),'Auth',function(_0x118ad9,_0x473b90){const _0x127dc9=_0x53586e;return _0x473b90[_0x127dc9('0x1ac6')]('admin')?_0x118ad9['resolve'](_0x127dc9('0x4ee'),{'fields':'id,name','sort':_0x127dc9('0x4f0'),'nolimit':!![]}):_0x118ad9[_0x127dc9('0x18af')](_0x127dc9('0x17c4'),{'id':_0x473b90['getCurrentUser']()[_0x127dc9('0xb86')],'section':_0x127dc9('0x1cae'),'fields':'id,name','sort':_0x127dc9('0x4f0'),'nolimit':!![]});}],'smsAccounts':[_0x53586e('0x1fbc'),'Auth',function(_0x4f0c47,_0x49511a){const _0x2c4995=_0x53586e;return _0x49511a[_0x2c4995('0x1ac6')]('admin')?_0x4f0c47[_0x2c4995('0x18af')](_0x2c4995('0x1b3'),{'fields':_0x2c4995('0x1776'),'sort':_0x2c4995('0x4f0'),'nolimit':!![]}):_0x4f0c47[_0x2c4995('0x18af')](_0x2c4995('0x17c4'),{'id':_0x49511a[_0x2c4995('0x26cd')]()['userProfileId'],'section':'SmsAccounts','fields':_0x2c4995('0x1776'),'sort':_0x2c4995('0x4f0'),'nolimit':!![]});}],'pauses':['apiResolver','Auth',function(_0x2d98be,_0x4ad141){const _0x36565b=_0x53586e;return _0x4ad141[_0x36565b('0x1ac6')](_0x36565b('0xa7c'))?_0x2d98be[_0x36565b('0x18af')]('pause@get',{'fields':'id,name','sort':_0x36565b('0x4f0'),'nolimit':!![]}):_0x2d98be['resolve'](_0x36565b('0x17c4'),{'id':_0x4ad141[_0x36565b('0x26cd')]()[_0x36565b('0xb86')],'section':'Pauses','fields':_0x36565b('0x1776'),'sort':_0x36565b('0x4f0'),'nolimit':!![]});}],'userProfileSection':[_0x53586e('0x1fbc'),'Auth',function(_0x5e6fcd,_0x506256){const _0x41653a=_0x53586e;return _0x5e6fcd['resolve'](_0x41653a('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x506256['getCurrentUser']()[_0x41653a('0xb86')],'sectionId':0x44f});}]},'authenticate':!![],'permissionId':0x44f,'bodyClass':_0x53586e('0xae5')});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x2040'),[])['config'](_0x33e360)[_0x36e6f4('0x75e')]('CreateOrEditSquareProjectDialogController',_0x21154a)[_0x36e6f4('0x75e')](_0x36e6f4('0x14d'),_0x23a9c5)[_0x36e6f4('0x22e6')]('stringToNumber',_0xbdd804)[_0x36e6f4('0x87c')](_0x36e6f4('0x266'),_0x2f2875)[_0x36e6f4('0x87c')](_0x36e6f4('0x1372'),_0x3bd06d)[_0x36e6f4('0x87c')](_0x36e6f4('0x16b6'),_0x2b0429)[_0x36e6f4('0x87c')](_0x36e6f4('0x88'),_0x122950)[_0x36e6f4('0x87c')]('googleTtsLanguage',_0x4f1dfb)[_0x36e6f4('0x87c')](_0x36e6f4('0x1cc4'),_0x2a477f)[_0x36e6f4('0x87c')](_0x36e6f4('0xd63'),_0x520f51)[_0x36e6f4('0x87c')](_0x36e6f4('0x5cb'),_0x2248c0)[_0x36e6f4('0x87c')](_0x36e6f4('0x1b04'),_0x3fed50)[_0x36e6f4('0x87c')]('dialogFlowLanguage',_0x40aad6)[_0x36e6f4('0x87c')](_0x36e6f4('0x1962'),_0x2bed43)[_0x36e6f4('0x75e')]('MxGraphEditXMLController',_0x43fb06)['controller'](_0x36e6f4('0xe2'),_0x2e2b2f)[_0x36e6f4('0x75e')](_0x36e6f4('0x1a62'),_0x2cd773)[_0x36e6f4('0x75e')]('MxGraphOpenProjectController',_0x568119)[_0x36e6f4('0x75e')](_0x36e6f4('0x1dbc'),_0x2371b0)['controller']('MxGraphSaveProjectAsController',_0x46dc23)[_0x36e6f4('0x75e')]('ProjectController',_0x49d549)['controller'](_0x36e6f4('0x212'),_0x23b879);const _0x236250=_0x2734b2['p']+_0x36e6f4('0xe3b'),_0x598ef3=_0x2734b2['p']+_0x36e6f4('0x151c');_0x2a272e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0x14e9'),_0x36e6f4('0x1391'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x2a272e(_0xcc1369,_0x3fb796,_0x3c0e9a,_0xac7824,_0x1574eb,_0xf67dfa,_0x4894ac,_0x1a4b0c,_0x16b554,_0x418c38,_0x57b229,_0x53f5e4,_0x23e49e,_0x140f03){const _0x2279d5=_0x36e6f4,_0x2b1b8c=this;_0x2b1b8c[_0x2279d5('0x98')]=_0x57b229[_0x2279d5('0x26cd')](),_0x2b1b8c[_0x2279d5('0x61a')]=[],_0x2b1b8c[_0x2279d5('0xf8a')]=_0x23e49e,_0x2b1b8c[_0x2279d5('0x5c9')]=_0x53f5e4,_0x2b1b8c[_0x2279d5('0x243c')]=_0x140f03,_0x2b1b8c['hasModulePermissions']={},_0x2b1b8c[_0x2279d5('0x2900')]=_0x2b1b8c['setting']&&_0x2b1b8c[_0x2279d5('0xf8a')][_0x2279d5('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2b1b8c['title']=_0x2279d5('0x161c'),_0x2b1b8c['odbc']=angular[_0x2279d5('0x225f')](_0x16b554),_0x2b1b8c['odbcs']=_0x1a4b0c,_0x2b1b8c[_0x2279d5('0x1c59')]=![];!_0x2b1b8c[_0x2279d5('0x1391')]&&(_0x2b1b8c[_0x2279d5('0x1391')]={},_0x2b1b8c[_0x2279d5('0xcdc')]='CALLYSQUARE.NEW_ODBC',_0x2b1b8c[_0x2279d5('0x1c59')]=!![]);_0x2b1b8c[_0x2279d5('0x134a')]=_0x4343f5,_0x2b1b8c[_0x2279d5('0x18df')]=_0x3e4edf,_0x2b1b8c[_0x2279d5('0xb44')]=_0x3089c8,_0x2b1b8c['getDateFromString']=_0xc0ce07,_0x2b1b8c[_0x2279d5('0x24a0')]=_0x5cdf11;function _0x4343f5(){const _0x17916e=_0x2279d5;_0x2b1b8c[_0x17916e('0x61a')]=[],_0x418c38[_0x17916e('0xb7b')][_0x17916e('0x9cc')](_0x2b1b8c[_0x17916e('0x1391')])['$promise'][_0x17916e('0x1166')](function(_0x436802){const _0x260f9e=_0x17916e;_0x2b1b8c['odbcs'][_0x260f9e('0x2450')](_0x436802[_0x260f9e('0x2876')]()),_0x4894ac[_0x260f9e('0x103b')]({'title':_0x260f9e('0x1cf'),'msg':_0x2b1b8c[_0x260f9e('0x1391')][_0x260f9e('0x4f0')]?_0x2b1b8c[_0x260f9e('0x1391')][_0x260f9e('0x4f0')]+_0x260f9e('0x1eda'):''}),_0x5cdf11(_0x436802);})['catch'](function(_0x3e34ed){const _0xa0f6a3=_0x17916e;if(_0x3e34ed[_0xa0f6a3('0x25f4')]&&_0x3e34ed[_0xa0f6a3('0x25f4')][_0xa0f6a3('0x61a')]&&_0x3e34ed[_0xa0f6a3('0x25f4')][_0xa0f6a3('0x61a')][_0xa0f6a3('0x264b')]){_0x2b1b8c['errors']=_0x3e34ed['data'][_0xa0f6a3('0x61a')]||[{'message':_0x3e34ed[_0xa0f6a3('0x1586')](),'type':_0xa0f6a3('0x149d')}];for(let _0x27e12e=0x0;_0x27e12e<_0x3e34ed[_0xa0f6a3('0x25f4')][_0xa0f6a3('0x61a')][_0xa0f6a3('0x264b')];_0x27e12e+=0x1){_0x4894ac[_0xa0f6a3('0xfc9')]({'title':_0x3e34ed[_0xa0f6a3('0x25f4')][_0xa0f6a3('0x61a')][_0x27e12e][_0xa0f6a3('0x1345')],'msg':_0x3e34ed[_0xa0f6a3('0x25f4')][_0xa0f6a3('0x61a')][_0x27e12e]['message']});}}else _0x4894ac[_0xa0f6a3('0xfc9')]({'title':_0x3e34ed['status']?_0xa0f6a3('0x1e21')+_0x3e34ed['status']+_0xa0f6a3('0x11e1')+_0x3e34ed[_0xa0f6a3('0xe1b')]:'api.squareOdbc.save','msg':_0x3e34ed['data']?JSON[_0xa0f6a3('0xbac')](_0x3e34ed['data'][_0xa0f6a3('0x1e70')]):_0x3e34ed[_0xa0f6a3('0x1586')]()});});}function _0x3e4edf(){const _0x589b90=_0x2279d5;_0x2b1b8c[_0x589b90('0x61a')]=[],_0x418c38[_0x589b90('0xb7b')][_0x589b90('0x1449')]({'id':_0x2b1b8c[_0x589b90('0x1391')]['id']},_0x2b1b8c[_0x589b90('0x1391')])[_0x589b90('0xa44')]['then'](function(_0xa43c2e){const _0x104210=_0x589b90,_0x1a3cf7=_0x2cfb05()[_0x104210('0xc38')](_0x2b1b8c['odbcs'],{'id':_0xa43c2e['id']});_0x1a3cf7&&_0x2cfb05()[_0x104210('0xcc3')](_0x1a3cf7,_0x2cfb05()[_0x104210('0x1a08')](_0xa43c2e[_0x104210('0x2876')](),_0x2cfb05()['keys'](_0x1a3cf7))),_0x4894ac[_0x104210('0x103b')]({'title':_0x104210('0x19cc'),'msg':_0x2b1b8c[_0x104210('0x1391')][_0x104210('0x4f0')]?_0x2b1b8c[_0x104210('0x1391')]['name']+_0x104210('0x7d'):''}),_0x5cdf11(_0xa43c2e);})['catch'](function(_0x212bcc){const _0x4e35be=_0x589b90;if(_0x212bcc[_0x4e35be('0x25f4')]&&_0x212bcc[_0x4e35be('0x25f4')][_0x4e35be('0x61a')]&&_0x212bcc[_0x4e35be('0x25f4')][_0x4e35be('0x61a')][_0x4e35be('0x264b')]){_0x2b1b8c[_0x4e35be('0x61a')]=_0x212bcc['data'][_0x4e35be('0x61a')]||[{'message':_0x212bcc['toString'](),'type':'api.squareOdbc.update'}];for(let _0x9e50f9=0x0;_0x9e50f9<_0x212bcc['data'][_0x4e35be('0x61a')][_0x4e35be('0x264b')];_0x9e50f9++){_0x4894ac[_0x4e35be('0xfc9')]({'title':_0x212bcc[_0x4e35be('0x25f4')][_0x4e35be('0x61a')][_0x9e50f9][_0x4e35be('0x1345')],'msg':_0x212bcc[_0x4e35be('0x25f4')][_0x4e35be('0x61a')][_0x9e50f9]['message']});}}else _0x4894ac[_0x4e35be('0xfc9')]({'title':_0x212bcc[_0x4e35be('0x52d')]?_0x4e35be('0x1e21')+_0x212bcc[_0x4e35be('0x52d')]+_0x4e35be('0x11e1')+_0x212bcc[_0x4e35be('0xe1b')]:'api.squareOdbc.update','msg':_0x212bcc[_0x4e35be('0x25f4')]?JSON[_0x4e35be('0xbac')](_0x212bcc['data']['message']):_0x212bcc[_0x4e35be('0x1586')]()});});}function _0x3089c8(_0x54102d){const _0x8f8490=_0x2279d5;_0x2b1b8c['errors']=[];const _0x3b6849=_0xac7824['confirm']()[_0x8f8490('0xcdc')](_0x8f8490('0x7fb'))[_0x8f8490('0xacc')]('The\x20odbc\x20will\x20be\x20deleted.')[_0x8f8490('0x8e8')](_0x8f8490('0x5ab'))['ok']('Delete')[_0x8f8490('0x3f')](_0x8f8490('0x497'))[_0x8f8490('0x203b')](_0x54102d);_0xac7824[_0x8f8490('0x1f80')](_0x3b6849)[_0x8f8490('0x1166')](function(){const _0x572562=_0x8f8490;_0x418c38[_0x572562('0xb7b')]['delete']({'id':_0x2b1b8c[_0x572562('0x1391')]['id']})['$promise']['then'](function(){const _0xcb8d3d=_0x572562;_0x2cfb05()[_0xcb8d3d('0x127f')](_0x2b1b8c[_0xcb8d3d('0x14e9')],{'id':_0x2b1b8c[_0xcb8d3d('0x1391')]['id']}),_0x4894ac[_0xcb8d3d('0x103b')]({'title':_0xcb8d3d('0x18f8'),'msg':(_0x2b1b8c[_0xcb8d3d('0x1391')][_0xcb8d3d('0x4f0')]||_0xcb8d3d('0x1391'))+_0xcb8d3d('0x7cd')}),_0x5cdf11(_0x2b1b8c['odbc']);})[_0x572562('0x1a80')](function(_0x43bd45){const _0x987273=_0x572562;if(_0x43bd45[_0x987273('0x25f4')]&&_0x43bd45[_0x987273('0x25f4')][_0x987273('0x61a')]&&_0x43bd45[_0x987273('0x25f4')][_0x987273('0x61a')][_0x987273('0x264b')]){_0x2b1b8c[_0x987273('0x61a')]=_0x43bd45[_0x987273('0x25f4')][_0x987273('0x61a')]||[{'message':_0x43bd45['toString'](),'type':_0x987273('0xb2e')}];for(let _0x4c55a5=0x0;_0x4c55a5<_0x43bd45[_0x987273('0x25f4')][_0x987273('0x61a')][_0x987273('0x264b')];_0x4c55a5++){_0x4894ac[_0x987273('0xfc9')]({'title':_0x43bd45[_0x987273('0x25f4')][_0x987273('0x61a')][_0x4c55a5]['type'],'msg':_0x43bd45[_0x987273('0x25f4')][_0x987273('0x61a')][_0x4c55a5][_0x987273('0x1e70')]});}}else _0x4894ac[_0x987273('0xfc9')]({'title':_0x43bd45[_0x987273('0x52d')]?_0x987273('0x1e21')+_0x43bd45[_0x987273('0x52d')]+_0x987273('0x11e1')+_0x43bd45[_0x987273('0xe1b')]:_0x987273('0xb2e'),'msg':_0x43bd45[_0x987273('0x25f4')]?JSON[_0x987273('0xbac')](_0x43bd45[_0x987273('0x25f4')][_0x987273('0x1e70')]):_0x43bd45[_0x987273('0x1e70')]||_0x43bd45[_0x987273('0x1586')]()});});},function(){});}function _0xc0ce07(_0x291583){return _0x291583===null?undefined:new Date(_0x291583);}function _0x5cdf11(_0x545375){_0xac7824['hide'](_0x545375);}}const _0x43813c=_0x2a272e,_0xa02787=_0x2734b2['p']+_0x36e6f4('0x20bf');_0x1059cc[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$window',_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout','$translate','odbcs','userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x1059cc(_0x5da71d,_0x33b109,_0x7e6f35,_0xeae8e0,_0x4155ff,_0x5b1348,_0x345d02,_0x272400,_0x5f2a66,_0x475e73,_0x219faa,_0x5d8fc9,_0x62925b,_0x2e0a04,_0x56aa91,_0x1ab2ef,_0x55b77f){const _0x35fe3b=_0x36e6f4,_0x27625b=this;_0x27625b['license']=_0x1ab2ef,_0x27625b[_0x35fe3b('0xf8a')]=_0x55b77f,_0x27625b[_0x35fe3b('0x98')]=_0x56aa91[_0x35fe3b('0x26cd')](),_0x27625b['odbcs']=_0x5f2a66||{'count':0x0,'rows':[]},_0x27625b[_0x35fe3b('0x7f')]=_0x475e73,_0x27625b[_0x35fe3b('0x17aa')]=_0x219faa&&_0x219faa[_0x35fe3b('0x240f')]==0x1?_0x219faa['rows'][0x0]:null,_0x27625b[_0x35fe3b('0x243c')]=_0x56aa91[_0x35fe3b('0xd87')](_0x27625b[_0x35fe3b('0x17aa')]?_0x27625b[_0x35fe3b('0x17aa')][_0x35fe3b('0x243c')]:null),_0x27625b[_0x35fe3b('0x916')]=_0x35fe3b('0x14e9'),_0x27625b['listOrder']='',_0x27625b['listOrderAsc']=null,_0x27625b[_0x35fe3b('0x880')]=[],_0x27625b[_0x35fe3b('0x2218')]={'fields':'createdAt,updatedAt,id,name,dsn,description','sort':_0x35fe3b('0x14dc'),'limit':0xa,'page':0x1},_0x27625b['editdialog']=_0x1bddb5,_0x27625b[_0x35fe3b('0x1b8c')]=_0x443479,_0x27625b['deleteconfirm']=_0x44b7a1,_0x27625b['success']=_0x5e8294,_0x27625b['getODBC']=_0x472dac,_0x27625b[_0x35fe3b('0x1744')]=_0x39073e,_0x27625b['deleteOdbc']=_0x90e27f,_0x27625b[_0x35fe3b('0x5e8')]=_0x625d58,_0x27625b[_0x35fe3b('0x1ca2')]=_0x11d80d,_0x27625b['deselectODBC']=_0x354e91,_0x27625b[_0x35fe3b('0xb56')]=_0x4bdc6a;function _0x1bddb5(_0x20cf2e,_0xf21a59){const _0x6ba09c=_0x35fe3b;_0x4155ff[_0x6ba09c('0x1f80')]({'controller':_0x6ba09c('0x15f4'),'controllerAs':'vm','templateUrl':_0xa02787,'parent':angular[_0x6ba09c('0x1194')](_0x5b1348[_0x6ba09c('0x8d2')]),'targetEvent':_0xf21a59,'clickOutsideToClose':!![],'locals':{'odbc':_0x20cf2e,'odbcs':_0x27625b[_0x6ba09c('0x14e9')][_0x6ba09c('0x269a')],'license':_0x27625b[_0x6ba09c('0x5c9')],'setting':null,'crudPermissions':_0x27625b[_0x6ba09c('0x243c')]}});}function _0x443479(_0x3adfe6){const _0x4c299b=_0x35fe3b;return _0x5d8fc9[_0x4c299b('0xb7b')][_0x4c299b('0x45d')]({'id':_0x3adfe6['id']})[_0x4c299b('0xa44')][_0x4c299b('0x1166')](function(){const _0x1a8c72=_0x4c299b;_0x2e0a04[_0x1a8c72('0x103b')]({'title':'Square\x20ODBC\x20properly\x20tested','msg':_0x1a8c72('0x1fef')});})['catch'](function(_0x59c961){const _0x299243=_0x4c299b;_0x2e0a04[_0x299243('0xfc9')]({'title':'Square\x20ODBC\x20properly\x20tested','msg':_0x59c961['data']?JSON['stringify'](_0x59c961['data']):_0x59c961[_0x299243('0x1586')]()});});}function _0x44b7a1(_0x47d680,_0x5e3c40){const _0x13865b=_0x35fe3b,_0x5c24f1=_0x4155ff[_0x13865b('0x1d26')]()[_0x13865b('0xcdc')](_0x13865b('0x288d')+_0x2cfb05()['startCase'](_0x13865b('0x1391'))+'?')[_0x13865b('0xf3c')](_0x13865b('0x12b5')+(_0x47d680[_0x13865b('0x4f0')]||'odbc')+''+_0x13865b('0x3f3'))[_0x13865b('0x8e8')]('delete\x20odbc')[_0x13865b('0x203b')](_0x5e3c40)['ok']('OK')[_0x13865b('0x3f')]('CANCEL');_0x4155ff[_0x13865b('0x1f80')](_0x5c24f1)[_0x13865b('0x1166')](function(){_0x90e27f(_0x47d680);},function(){const _0x32e11f=_0x13865b;console[_0x32e11f('0x455')]('CANCEL');});}let _0x3ff25c=!![],_0x3e4c1a=0x1;_0x5da71d[_0x35fe3b('0xe83')](_0x35fe3b('0x12d8'),function(_0x442518,_0x2b3b5a){const _0x2f3c54=_0x35fe3b;_0x3ff25c?_0x345d02(function(){_0x3ff25c=![];}):(!_0x2b3b5a&&(_0x3e4c1a=_0x27625b[_0x2f3c54('0x2218')][_0x2f3c54('0x1a43')]),_0x442518!==_0x2b3b5a&&(_0x27625b[_0x2f3c54('0x2218')][_0x2f3c54('0x1a43')]=0x1),!_0x442518&&(_0x27625b[_0x2f3c54('0x2218')][_0x2f3c54('0x1a43')]=_0x3e4c1a),_0x27625b[_0x2f3c54('0x755')]());});function _0x5e8294(_0x2c1b2e){_0x27625b['odbcs']=_0x2c1b2e||{'count':0x0,'rows':[]};}function _0x472dac(){const _0x49f634=_0x35fe3b;_0x27625b[_0x49f634('0x2218')][_0x49f634('0x1098')]=(_0x27625b['query'][_0x49f634('0x1a43')]-0x1)*_0x27625b[_0x49f634('0x2218')][_0x49f634('0x163f')],_0x56aa91[_0x49f634('0x1ac6')](_0x49f634('0xa7c'))?_0x27625b[_0x49f634('0x1f48')]=_0x5d8fc9[_0x49f634('0xb7b')][_0x49f634('0xd83')](_0x27625b['query'],_0x5e8294)['$promise']:(_0x27625b['query']['id']=_0x27625b['userProfile']['id'],_0x27625b[_0x49f634('0x2218')]['section']='ODBC',_0x27625b[_0x49f634('0x1f48')]=_0x5d8fc9[_0x49f634('0x7f')]['getResources'](_0x27625b['query'],_0x5e8294)[_0x49f634('0xa44')]);}function _0x39073e(_0x20f30e,_0x43a581){const _0x21f1b4=_0x35fe3b;_0x4155ff[_0x21f1b4('0x1f80')]({'controller':'CreateOrEditOdbcDialogController','controllerAs':'vm','templateUrl':_0xa02787,'parent':angular[_0x21f1b4('0x1194')](_0x5b1348[_0x21f1b4('0x8d2')]),'targetEvent':_0x20f30e,'clickOutsideToClose':!![],'locals':{'odbc':_0x43a581,'odbcs':_0x27625b[_0x21f1b4('0x14e9')]['rows'],'license':_0x27625b[_0x21f1b4('0x5c9')],'setting':_0x27625b[_0x21f1b4('0xf8a')],'crudPermissions':_0x27625b[_0x21f1b4('0x243c')]}});}function _0x90e27f(_0x9d2d8f){const _0x25cf0a=_0x35fe3b;_0x5d8fc9[_0x25cf0a('0xb7b')][_0x25cf0a('0x906')]({'id':_0x9d2d8f['id']})[_0x25cf0a('0xa44')]['then'](function(){const _0x34db33=_0x25cf0a;_0x2cfb05()[_0x34db33('0x127f')](_0x27625b[_0x34db33('0x14e9')][_0x34db33('0x269a')],{'id':_0x9d2d8f['id']}),_0x27625b[_0x34db33('0x14e9')][_0x34db33('0x240f')]-=0x1,!_0x27625b[_0x34db33('0x14e9')]['rows'][_0x34db33('0x264b')]&&_0x27625b[_0x34db33('0x755')](),_0x2e0a04[_0x34db33('0x103b')]({'title':_0x2cfb05()[_0x34db33('0xb35')](_0x34db33('0x150a'))+_0x34db33('0x2b6'),'msg':_0x9d2d8f[_0x34db33('0x4f0')]?_0x9d2d8f['name']+_0x34db33('0x7cd'):''});})[_0x25cf0a('0x1a80')](function(_0xde99c4){const _0xbb459e=_0x25cf0a;if(_0xde99c4[_0xbb459e('0x25f4')]&&_0xde99c4[_0xbb459e('0x25f4')][_0xbb459e('0x61a')]&&_0xde99c4['data'][_0xbb459e('0x61a')][_0xbb459e('0x264b')]){_0x27625b[_0xbb459e('0x61a')]=_0xde99c4[_0xbb459e('0x25f4')]['errors']||[{'message':_0xde99c4[_0xbb459e('0x1586')](),'type':'SYSTEM:DELETEsquareOdbc'}];for(let _0x1f3e3b=0x0;_0x1f3e3b<_0xde99c4['data'][_0xbb459e('0x61a')]['length'];_0x1f3e3b++){_0x2e0a04[_0xbb459e('0xfc9')]({'title':_0xde99c4[_0xbb459e('0x25f4')]['errors'][_0x1f3e3b][_0xbb459e('0x1345')],'msg':_0xde99c4[_0xbb459e('0x25f4')][_0xbb459e('0x61a')][_0x1f3e3b]['message']});}}else _0x2e0a04[_0xbb459e('0xfc9')]({'title':_0xde99c4[_0xbb459e('0x52d')]?_0xbb459e('0x1e21')+_0xde99c4[_0xbb459e('0x52d')]+'\x20-\x20'+_0xde99c4['statusText']:'SYSTEM:DELETEsquareOdbc','msg':_0xde99c4['data']?JSON[_0xbb459e('0xbac')](_0xde99c4[_0xbb459e('0x25f4')][_0xbb459e('0x1e70')]):_0xde99c4[_0xbb459e('0x1e70')]||_0xde99c4['toString']()});});}function _0x625d58(){const _0x536013=_0x35fe3b,_0x14bfe3=angular[_0x536013('0x225f')](_0x27625b[_0x536013('0x880')]);return _0x27625b[_0x536013('0x880')]=[],_0x14bfe3;}function _0x11d80d(_0x27daa9){const _0x200259=_0x35fe3b,_0x6b4f17=_0x4155ff['confirm']()[_0x200259('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20odbcs?')[_0x200259('0xf3c')](_0x200259('0x12b5')+_0x27625b['selectedODBC'][_0x200259('0x264b')]+_0x200259('0x196d')+_0x200259('0x3f3'))[_0x200259('0x8e8')](_0x200259('0x327'))['targetEvent'](_0x27daa9)['ok']('OK')[_0x200259('0x3f')](_0x200259('0x2d3'));_0x4155ff['show'](_0x6b4f17)[_0x200259('0x1166')](function(){const _0x474661=_0x200259;_0x27625b[_0x474661('0x880')]['forEach'](function(_0x573866){_0x90e27f(_0x573866);}),_0x27625b[_0x474661('0x880')]=[];});}function _0x354e91(){const _0x2e7820=_0x35fe3b;_0x27625b[_0x2e7820('0x880')]=[];}function _0x4bdc6a(){const _0x26cd04=_0x35fe3b;_0x27625b[_0x26cd04('0x880')]=_0x27625b[_0x26cd04('0x14e9')][_0x26cd04('0x269a')];}}const _0x4bc222=_0x1059cc;_0x4d3872[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'squareRecordings',_0x36e6f4('0x2720'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x4d3872(_0x244a06,_0x149ff2,_0x370741,_0x52ea64,_0x52a35b,_0xa17050,_0x1ddbf8,_0xcc2355,_0x3bfd29,_0x3822ca,_0x36be73,_0x3a8e38,_0x4f64b9,_0x18d4bc){const _0x1e49e6=_0x36e6f4,_0x4d454d=this;_0x4d454d[_0x1e49e6('0x98')]=_0x36be73[_0x1e49e6('0x26cd')](),_0x4d454d[_0x1e49e6('0x61a')]=[],_0x4d454d[_0x1e49e6('0xf8a')]=_0x4f64b9,_0x4d454d[_0x1e49e6('0x5c9')]=_0x3a8e38,_0x4d454d[_0x1e49e6('0x243c')]=_0x18d4bc,_0x4d454d[_0x1e49e6('0x128b')]={},_0x4d454d[_0x1e49e6('0x2900')]=_0x4d454d[_0x1e49e6('0xf8a')]&&_0x4d454d[_0x1e49e6('0xf8a')][_0x1e49e6('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4d454d[_0x1e49e6('0xcdc')]='CALLYSQUARE.EDIT_SQUARERECORDING',_0x4d454d['squareRecording']=angular[_0x1e49e6('0x225f')](_0x3bfd29),_0x4d454d[_0x1e49e6('0x130f')]=_0xcc2355,_0x4d454d[_0x1e49e6('0x569')]=![];!_0x4d454d['squareRecording']&&(_0x4d454d['squareRecording']={},_0x4d454d[_0x1e49e6('0xcdc')]=_0x1e49e6('0x2138'),_0x4d454d[_0x1e49e6('0x569')]=!![]);_0x4d454d[_0x1e49e6('0x8fa')]=_0x5139fb,_0x4d454d[_0x1e49e6('0x243d')]=_0x4fa2bc,_0x4d454d['deleteSquareRecording']=_0x3829c7,_0x4d454d[_0x1e49e6('0x1a9c')]=_0x3179b4,_0x4d454d['closeDialog']=_0x35d0f7;function _0x5139fb(){const _0x49ec9e=_0x1e49e6;_0x4d454d['errors']=[],_0x3822ca[_0x49ec9e('0x2720')][_0x49ec9e('0x9cc')](_0x4d454d[_0x49ec9e('0x2720')])[_0x49ec9e('0xa44')][_0x49ec9e('0x1166')](function(_0x42b22b){const _0x35ec7a=_0x49ec9e;_0x4d454d[_0x35ec7a('0x130f')][_0x35ec7a('0x2450')](_0x42b22b[_0x35ec7a('0x2876')]()),_0x1ddbf8[_0x35ec7a('0x103b')]({'title':'SquareRecording\x20properly\x20created','msg':_0x4d454d[_0x35ec7a('0x2720')]['name']?_0x4d454d[_0x35ec7a('0x2720')][_0x35ec7a('0x4f0')]+_0x35ec7a('0x1eda'):''}),_0x35d0f7(_0x42b22b);})['catch'](function(_0x299ccb){const _0x5c7182=_0x49ec9e;if(_0x299ccb[_0x5c7182('0x25f4')]&&_0x299ccb[_0x5c7182('0x25f4')][_0x5c7182('0x61a')]&&_0x299ccb[_0x5c7182('0x25f4')][_0x5c7182('0x61a')][_0x5c7182('0x264b')]){_0x4d454d['errors']=_0x299ccb[_0x5c7182('0x25f4')][_0x5c7182('0x61a')]||[{'message':_0x299ccb['toString'](),'type':'api.squareRecording.save'}];for(let _0x215294=0x0;_0x215294<_0x299ccb[_0x5c7182('0x25f4')]['errors'][_0x5c7182('0x264b')];_0x215294+=0x1){_0x1ddbf8[_0x5c7182('0xfc9')]({'title':_0x299ccb['data'][_0x5c7182('0x61a')][_0x215294]['type'],'msg':_0x299ccb[_0x5c7182('0x25f4')][_0x5c7182('0x61a')][_0x215294][_0x5c7182('0x1e70')]});}}else _0x1ddbf8[_0x5c7182('0xfc9')]({'title':_0x299ccb[_0x5c7182('0x52d')]?_0x5c7182('0x1e21')+_0x299ccb[_0x5c7182('0x52d')]+_0x5c7182('0x11e1')+_0x299ccb[_0x5c7182('0xe1b')]:_0x5c7182('0x1ae5'),'msg':_0x299ccb[_0x5c7182('0x25f4')]?JSON[_0x5c7182('0xbac')](_0x299ccb['data'][_0x5c7182('0x1e70')]):_0x299ccb[_0x5c7182('0x1586')]()});});}function _0x4fa2bc(){const _0x1d1a6=_0x1e49e6;_0x4d454d[_0x1d1a6('0x61a')]=[],_0x3822ca[_0x1d1a6('0x2720')][_0x1d1a6('0x1449')]({'id':_0x4d454d[_0x1d1a6('0x2720')]['id']},_0x4d454d[_0x1d1a6('0x2720')])[_0x1d1a6('0xa44')]['then'](function(_0x5c60ed){const _0x4ff397=_0x1d1a6,_0x48688c=_0x2cfb05()[_0x4ff397('0xc38')](_0x4d454d[_0x4ff397('0x130f')],{'id':_0x5c60ed['id']});_0x48688c&&_0x2cfb05()[_0x4ff397('0xcc3')](_0x48688c,_0x2cfb05()[_0x4ff397('0x1a08')](_0x5c60ed['toJSON'](),_0x2cfb05()[_0x4ff397('0x14a4')](_0x48688c))),_0x1ddbf8['success']({'title':_0x4ff397('0x2089'),'msg':_0x4d454d['squareRecording'][_0x4ff397('0x4f0')]?_0x4d454d[_0x4ff397('0x2720')][_0x4ff397('0x4f0')]+_0x4ff397('0x7d'):''}),_0x35d0f7(_0x5c60ed);})[_0x1d1a6('0x1a80')](function(_0x226fae){const _0x4f424e=_0x1d1a6;if(_0x226fae[_0x4f424e('0x25f4')]&&_0x226fae[_0x4f424e('0x25f4')][_0x4f424e('0x61a')]&&_0x226fae['data'][_0x4f424e('0x61a')][_0x4f424e('0x264b')]){_0x4d454d['errors']=_0x226fae[_0x4f424e('0x25f4')]['errors']||[{'message':_0x226fae[_0x4f424e('0x1586')](),'type':'api.squareRecording.update'}];for(let _0xf9a1ed=0x0;_0xf9a1ed<_0x226fae[_0x4f424e('0x25f4')][_0x4f424e('0x61a')][_0x4f424e('0x264b')];_0xf9a1ed++){_0x1ddbf8[_0x4f424e('0xfc9')]({'title':_0x226fae[_0x4f424e('0x25f4')][_0x4f424e('0x61a')][_0xf9a1ed][_0x4f424e('0x1345')],'msg':_0x226fae['data']['errors'][_0xf9a1ed]['message']});}}else _0x1ddbf8[_0x4f424e('0xfc9')]({'title':_0x226fae[_0x4f424e('0x52d')]?_0x4f424e('0x1e21')+_0x226fae['status']+_0x4f424e('0x11e1')+_0x226fae['statusText']:'api.squareRecording.update','msg':_0x226fae[_0x4f424e('0x25f4')]?JSON[_0x4f424e('0xbac')](_0x226fae['data'][_0x4f424e('0x1e70')]):_0x226fae[_0x4f424e('0x1586')]()});});}function _0x3829c7(_0x52dac7){const _0x161edc=_0x1e49e6;_0x4d454d[_0x161edc('0x61a')]=[];const _0x48f63a=_0x52ea64[_0x161edc('0x1d26')]()[_0x161edc('0xcdc')](_0x161edc('0x7fb'))[_0x161edc('0xacc')]('The\x20squareRecording\x20will\x20be\x20deleted.')[_0x161edc('0x8e8')](_0x161edc('0x1c52'))['ok'](_0x161edc('0x18'))[_0x161edc('0x3f')](_0x161edc('0x497'))[_0x161edc('0x203b')](_0x52dac7);_0x52ea64[_0x161edc('0x1f80')](_0x48f63a)[_0x161edc('0x1166')](function(){const _0xa40b16=_0x161edc;_0x3822ca['squareRecording'][_0xa40b16('0x906')]({'id':_0x4d454d[_0xa40b16('0x2720')]['id']})[_0xa40b16('0xa44')][_0xa40b16('0x1166')](function(){const _0x370199=_0xa40b16;_0x2cfb05()[_0x370199('0x127f')](_0x4d454d[_0x370199('0x130f')],{'id':_0x4d454d[_0x370199('0x2720')]['id']}),_0x1ddbf8[_0x370199('0x103b')]({'title':_0x370199('0x255a'),'msg':(_0x4d454d[_0x370199('0x2720')][_0x370199('0x4f0')]||_0x370199('0x2720'))+_0x370199('0x7cd')}),_0x35d0f7(_0x4d454d[_0x370199('0x2720')]);})[_0xa40b16('0x1a80')](function(_0x326e40){const _0x588e2c=_0xa40b16;if(_0x326e40[_0x588e2c('0x25f4')]&&_0x326e40['data']['errors']&&_0x326e40[_0x588e2c('0x25f4')]['errors']['length']){_0x4d454d[_0x588e2c('0x61a')]=_0x326e40[_0x588e2c('0x25f4')][_0x588e2c('0x61a')]||[{'message':_0x326e40['toString'](),'type':'api.squareRecording.delete'}];for(let _0xcf28a3=0x0;_0xcf28a3<_0x326e40['data'][_0x588e2c('0x61a')]['length'];_0xcf28a3++){_0x1ddbf8['error']({'title':_0x326e40['data'][_0x588e2c('0x61a')][_0xcf28a3][_0x588e2c('0x1345')],'msg':_0x326e40['data'][_0x588e2c('0x61a')][_0xcf28a3][_0x588e2c('0x1e70')]});}}else _0x1ddbf8[_0x588e2c('0xfc9')]({'title':_0x326e40[_0x588e2c('0x52d')]?_0x588e2c('0x1e21')+_0x326e40[_0x588e2c('0x52d')]+'\x20-\x20'+_0x326e40[_0x588e2c('0xe1b')]:_0x588e2c('0x1c02'),'msg':_0x326e40[_0x588e2c('0x25f4')]?JSON['stringify'](_0x326e40['data'][_0x588e2c('0x1e70')]):_0x326e40[_0x588e2c('0x1e70')]||_0x326e40[_0x588e2c('0x1586')]()});});},function(){});}function _0x3179b4(_0x4a9470){return _0x4a9470===null?undefined:new Date(_0x4a9470);}function _0x35d0f7(_0x389c07){_0x52ea64['hide'](_0x389c07);}}const _0x127277=_0x4d3872,_0x11ec28=_0x2734b2['p']+_0x36e6f4('0x237a');_0x46531f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$window','$state','$mdSidenav',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x130f'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x46531f(_0x306637,_0x171013,_0x2e027e,_0x5dc10a,_0x4cab66,_0x51e437,_0x3dfd9f,_0x129631,_0x38ca63,_0x3c0da1,_0x27a0f7,_0x1fd84c,_0x2c48db,_0x1b5b17,_0x5bc9a1,_0x4300de,_0xf29e8c){const _0x3bb8d0=_0x36e6f4,_0x47bb2b=this;_0x47bb2b[_0x3bb8d0('0x5c9')]=_0x4300de,_0x47bb2b['setting']=_0xf29e8c,_0x47bb2b[_0x3bb8d0('0x98')]=_0x5bc9a1[_0x3bb8d0('0x26cd')](),_0x47bb2b[_0x3bb8d0('0x130f')]=_0x38ca63||{'count':0x0,'rows':[]},_0x47bb2b[_0x3bb8d0('0x7f')]=_0x3c0da1,_0x47bb2b[_0x3bb8d0('0x17aa')]=_0x27a0f7&&_0x27a0f7['count']==0x1?_0x27a0f7[_0x3bb8d0('0x269a')][0x0]:null,_0x47bb2b['crudPermissions']=_0x5bc9a1[_0x3bb8d0('0xd87')](_0x47bb2b[_0x3bb8d0('0x17aa')]?_0x47bb2b[_0x3bb8d0('0x17aa')][_0x3bb8d0('0x243c')]:null),_0x47bb2b[_0x3bb8d0('0x916')]='squareRecordings',_0x47bb2b[_0x3bb8d0('0xef5')]='',_0x47bb2b[_0x3bb8d0('0x104c')]=null,_0x47bb2b[_0x3bb8d0('0x110f')]=[],_0x47bb2b[_0x3bb8d0('0x2218')]={'fields':_0x3bb8d0('0x12f9'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x47bb2b[_0x3bb8d0('0x424')]=_0x19a428,_0x47bb2b[_0x3bb8d0('0x8d8')]=_0x25584e,_0x47bb2b[_0x3bb8d0('0x103b')]=_0x4bcc21,_0x47bb2b[_0x3bb8d0('0x1d79')]=_0x28c2b8,_0x47bb2b[_0x3bb8d0('0x81a')]=_0x2de2b0,_0x47bb2b['deleteSquareRecording']=_0x154e5b,_0x47bb2b[_0x3bb8d0('0x13c2')]=_0x1f6aef,_0x47bb2b[_0x3bb8d0('0x945')]=_0x48b441,_0x47bb2b[_0x3bb8d0('0x6ea')]=_0x3a1b07,_0x47bb2b['selectAllSquareRecordings']=_0x1116ca;function _0x19a428(_0x4ce5ed){const _0x2f87ae=_0x3bb8d0;return _0x1fd84c['squareRecording'][_0x2f87ae('0x2ad')]({'id':_0x4ce5ed['id']})[_0x2f87ae('0xa44')][_0x2f87ae('0x1166')](function(_0x4ed0d7){const _0x3d9ecf=_0x2f87ae,_0x1dca89=[_0x4ed0d7[_0x3d9ecf('0x20ed')]];let _0x86e497=_0x3d9ecf('0x2ad');const _0x3c021c=new Blob(_0x1dca89,{'type':_0x4ed0d7[_0x3d9ecf('0x1345')]});_0x86e497=_0x4ce5ed[_0x3d9ecf('0x1c21')]+_0x4ce5ed['format'];const _0x428e7c=window[_0x3d9ecf('0x136d')]['createElement']('a');_0x428e7c['setAttribute'](_0x3d9ecf('0x14f9'),URL[_0x3d9ecf('0x215a')](_0x3c021c)),_0x428e7c[_0x3d9ecf('0xffd')]('download',_0x86e497),document[_0x3d9ecf('0x8d2')][_0x3d9ecf('0x21a')](_0x428e7c),_0x428e7c[_0x3d9ecf('0x3b4')]();})['catch'](function(_0x5bf772){const _0x1d584a=_0x2f87ae;if(_0x5bf772[_0x1d584a('0x25f4')]&&_0x5bf772[_0x1d584a('0x25f4')][_0x1d584a('0x61a')]&&_0x5bf772[_0x1d584a('0x25f4')]['errors']['length'])for(let _0x2d5443=0x0;_0x2d5443<_0x5bf772['data'][_0x1d584a('0x61a')][_0x1d584a('0x264b')];_0x2d5443++){_0x1b5b17[_0x1d584a('0xfc9')]({'title':_0x5bf772['data'][_0x1d584a('0x61a')][_0x2d5443][_0x1d584a('0x1345')],'msg':_0x5bf772[_0x1d584a('0x25f4')]['errors'][_0x2d5443]['message']});}else _0x1b5b17[_0x1d584a('0xfc9')]({'title':_0x5bf772[_0x1d584a('0x52d')]?_0x1d584a('0x1e21')+_0x5bf772[_0x1d584a('0x52d')]+'\x20-\x20'+_0x5bf772[_0x1d584a('0xe1b')]:'api.squareRecording.save','msg':_0x5bf772['data']?JSON[_0x1d584a('0xbac')](_0x5bf772[_0x1d584a('0x25f4')]['message']):_0x5bf772[_0x1d584a('0x1586')]()});});}function _0x25584e(_0x5469a8,_0x18e8f3){const _0x406d55=_0x3bb8d0,_0x57eef2=_0x4cab66[_0x406d55('0x1d26')]()['title'](_0x406d55('0x288d')+_0x2cfb05()['startCase'](_0x406d55('0x2720'))+'?')[_0x406d55('0xf3c')](''+(_0x5469a8[_0x406d55('0x4f0')]||'squareRecording')+_0x406d55('0xace')+_0x406d55('0x3f3'))[_0x406d55('0x8e8')](_0x406d55('0x49'))[_0x406d55('0x203b')](_0x18e8f3)['ok']('OK')[_0x406d55('0x3f')]('CANCEL');_0x4cab66['show'](_0x57eef2)[_0x406d55('0x1166')](function(){_0x154e5b(_0x5469a8);},function(){const _0x39aa5a=_0x406d55;console['log'](_0x39aa5a('0x2d3'));});}let _0x1122b8=!![],_0x3ccc86=0x1;_0x306637[_0x3bb8d0('0xe83')](_0x3bb8d0('0x12d8'),function(_0x570f6c,_0x3f3151){const _0xe63393=_0x3bb8d0;_0x1122b8?_0x3dfd9f(function(){_0x1122b8=![];}):(!_0x3f3151&&(_0x3ccc86=_0x47bb2b[_0xe63393('0x2218')][_0xe63393('0x1a43')]),_0x570f6c!==_0x3f3151&&(_0x47bb2b[_0xe63393('0x2218')][_0xe63393('0x1a43')]=0x1),!_0x570f6c&&(_0x47bb2b[_0xe63393('0x2218')]['page']=_0x3ccc86),_0x47bb2b[_0xe63393('0x1d79')]());});function _0x4bcc21(_0x18db77){_0x47bb2b['squareRecordings']=_0x18db77||{'count':0x0,'rows':[]};}function _0x28c2b8(){const _0x2354c0=_0x3bb8d0;_0x47bb2b[_0x2354c0('0x2218')]['offset']=(_0x47bb2b['query']['page']-0x1)*_0x47bb2b[_0x2354c0('0x2218')][_0x2354c0('0x163f')],_0x5bc9a1[_0x2354c0('0x1ac6')](_0x2354c0('0xa7c'))?_0x47bb2b[_0x2354c0('0x1f48')]=_0x1fd84c[_0x2354c0('0x2720')]['get'](_0x47bb2b['query'],_0x4bcc21)[_0x2354c0('0xa44')]:(_0x47bb2b['query']['id']=_0x47bb2b[_0x2354c0('0x7f')]['id'],_0x47bb2b[_0x2354c0('0x2218')][_0x2354c0('0xe60')]='SquareRecordings',_0x47bb2b['promise']=_0x1fd84c[_0x2354c0('0x7f')][_0x2354c0('0x263a')](_0x47bb2b[_0x2354c0('0x2218')],_0x4bcc21)[_0x2354c0('0xa44')]);}function _0x2de2b0(_0x3c2676,_0x23a96a){const _0x1c134c=_0x3bb8d0;_0x4cab66[_0x1c134c('0x1f80')]({'controller':_0x1c134c('0x7e5'),'controllerAs':'vm','templateUrl':_0x11ec28,'parent':angular['element'](_0x51e437['body']),'targetEvent':_0x3c2676,'clickOutsideToClose':!![],'locals':{'squareRecording':_0x23a96a,'squareRecordings':_0x47bb2b[_0x1c134c('0x130f')][_0x1c134c('0x269a')],'license':_0x47bb2b['license'],'setting':_0x47bb2b[_0x1c134c('0xf8a')],'crudPermissions':_0x47bb2b[_0x1c134c('0x243c')]}});}function _0x154e5b(_0x53b22e){const _0x447744=_0x3bb8d0;_0x1fd84c[_0x447744('0x2720')][_0x447744('0x906')]({'id':_0x53b22e['id']})[_0x447744('0xa44')][_0x447744('0x1166')](function(){const _0x16dce6=_0x447744;_0x2cfb05()[_0x16dce6('0x127f')](_0x47bb2b[_0x16dce6('0x130f')]['rows'],{'id':_0x53b22e['id']}),_0x47bb2b[_0x16dce6('0x130f')][_0x16dce6('0x240f')]-=0x1,!_0x47bb2b[_0x16dce6('0x130f')][_0x16dce6('0x269a')][_0x16dce6('0x264b')]&&_0x47bb2b[_0x16dce6('0x1d79')](),_0x1b5b17[_0x16dce6('0x103b')]({'title':_0x2cfb05()[_0x16dce6('0xb35')](_0x16dce6('0xacb'))+_0x16dce6('0x2b6'),'msg':_0x53b22e['name']?_0x53b22e['name']+_0x16dce6('0x7cd'):''});})[_0x447744('0x1a80')](function(_0x49c690){const _0x4b9522=_0x447744;if(_0x49c690[_0x4b9522('0x25f4')]&&_0x49c690[_0x4b9522('0x25f4')][_0x4b9522('0x61a')]&&_0x49c690['data'][_0x4b9522('0x61a')][_0x4b9522('0x264b')]){_0x47bb2b[_0x4b9522('0x61a')]=_0x49c690[_0x4b9522('0x25f4')][_0x4b9522('0x61a')]||[{'message':_0x49c690['toString'](),'type':_0x4b9522('0x1a4')}];for(let _0x4c6f49=0x0;_0x4c6f49<_0x49c690[_0x4b9522('0x25f4')]['errors'][_0x4b9522('0x264b')];_0x4c6f49++){_0x1b5b17['error']({'title':_0x49c690['data'][_0x4b9522('0x61a')][_0x4c6f49][_0x4b9522('0x1345')],'msg':_0x49c690[_0x4b9522('0x25f4')]['errors'][_0x4c6f49]['message']});}}else _0x1b5b17[_0x4b9522('0xfc9')]({'title':_0x49c690[_0x4b9522('0x52d')]?_0x4b9522('0x1e21')+_0x49c690['status']+_0x4b9522('0x11e1')+_0x49c690['statusText']:'SYSTEM:DELETEsquareRecording','msg':_0x49c690['data']?JSON[_0x4b9522('0xbac')](_0x49c690['data'][_0x4b9522('0x1e70')]):_0x49c690[_0x4b9522('0x1e70')]||_0x49c690[_0x4b9522('0x1586')]()});});}function _0x1f6aef(){const _0x47f187=_0x3bb8d0,_0x13e5db=angular[_0x47f187('0x225f')](_0x47bb2b['selectedSquareRecordings']);return _0x47bb2b[_0x47f187('0x110f')]=[],_0x13e5db;}function _0x48b441(_0x244c05){const _0x27c599=_0x3bb8d0,_0x395136=_0x4cab66[_0x27c599('0x1d26')]()[_0x27c599('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20squareRecordings?')[_0x27c599('0xf3c')](''+_0x47bb2b[_0x27c599('0x110f')][_0x27c599('0x264b')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x27c599('0x8e8')](_0x27c599('0xdf'))[_0x27c599('0x203b')](_0x244c05)['ok']('OK')[_0x27c599('0x3f')](_0x27c599('0x2d3'));_0x4cab66[_0x27c599('0x1f80')](_0x395136)[_0x27c599('0x1166')](function(){const _0x737b36=_0x27c599;_0x47bb2b[_0x737b36('0x110f')][_0x737b36('0x2782')](function(_0x49883e){_0x154e5b(_0x49883e);}),_0x47bb2b[_0x737b36('0x110f')]=[];});}function _0x3a1b07(){const _0x1068ec=_0x3bb8d0;_0x47bb2b[_0x1068ec('0x110f')]=[];}function _0x1116ca(){const _0x5146f4=_0x3bb8d0;_0x47bb2b[_0x5146f4('0x110f')]=_0x47bb2b[_0x5146f4('0x130f')]['rows'];}}const _0x1cb87f=_0x46531f;_0x2d8842['$inject']=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x2d8842(_0x520f71,_0xd91f1b){const _0x1e77c5=_0x36e6f4;_0x520f71['state'](_0x1e77c5('0x1213'),{'abstract':!![],'url':_0x1e77c5('0x42a')})[_0x1e77c5('0x63f')](_0x1e77c5('0x2703'),{'url':_0x1e77c5('0x18fa'),'views':{'content@app':{'templateUrl':_0x236250,'controller':'OdbcsController\x20as\x20vm'}},'resolve':{'odbcs':[_0x1e77c5('0x1fbc'),'Auth',function(_0x100df4,_0x19c6f6){const _0x52d4bd=_0x1e77c5;return _0x19c6f6[_0x52d4bd('0x1ac6')](_0x52d4bd('0xa7c'))?_0x100df4[_0x52d4bd('0x18af')]('squareOdbc@get',{'fields':_0x52d4bd('0x2797'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x100df4['resolve'](_0x52d4bd('0x17c4'),{'id':_0x19c6f6[_0x52d4bd('0x26cd')]()[_0x52d4bd('0xb86')],'section':_0x52d4bd('0x1b6'),'fields':_0x52d4bd('0x2797'),'sort':_0x52d4bd('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x1e77c5('0x1fbc'),_0x1e77c5('0x21ef'),function(_0x1ee449,_0x235392){const _0x20a793=_0x1e77c5;return _0x235392[_0x20a793('0x1ac6')](_0x20a793('0xa7c'))?null:_0x1ee449[_0x20a793('0x18af')](_0x20a793('0x697'),{'fields':'id,name,crudPermissions','id':_0x235392[_0x20a793('0x26cd')]()[_0x20a793('0xb86')]});}],'userProfileSection':['apiResolver',_0x1e77c5('0x21ef'),function(_0x324cec,_0x188335){const _0x502086=_0x1e77c5;return _0x188335[_0x502086('0x1ac6')](_0x502086('0xa7c'))?null:_0x324cec[_0x502086('0x18af')](_0x502086('0xaf'),{'fields':_0x502086('0xe26'),'userProfileId':_0x188335[_0x502086('0x26cd')]()[_0x502086('0xb86')],'sectionId':0x44d});}]},'authenticate':!![],'permissionId':0x44d,'bodyClass':_0x1e77c5('0xae5')})[_0x1e77c5('0x63f')](_0x1e77c5('0x232b'),{'url':_0x1e77c5('0x21c8'),'views':{'content@app':{'templateUrl':_0x598ef3,'controller':'SquareRecordingsController\x20as\x20vm'}},'resolve':{'squareRecordings':['apiResolver',_0x1e77c5('0x21ef'),function(_0x41938b,_0x1b2d17){const _0xb5858a=_0x1e77c5;return _0x1b2d17[_0xb5858a('0x1ac6')]('admin')?_0x41938b[_0xb5858a('0x18af')](_0xb5858a('0xdda'),{'fields':_0xb5858a('0x12f9'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x41938b[_0xb5858a('0x18af')]('userProfile@getResources',{'id':_0x1b2d17['getCurrentUser']()[_0xb5858a('0xb86')],'section':_0xb5858a('0x19d8'),'fields':'createdAt,updatedAt,id,filename,projectName,uniqueid,callerid,extension,audio,savePath,format','sort':_0xb5858a('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x1e77c5('0x1fbc'),_0x1e77c5('0x21ef'),function(_0x9d837e,_0x4d684b){const _0x17bbea=_0x1e77c5;return _0x4d684b[_0x17bbea('0x1ac6')](_0x17bbea('0xa7c'))?null:_0x9d837e[_0x17bbea('0x18af')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x4d684b[_0x17bbea('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x1e77c5('0x1fbc'),_0x1e77c5('0x21ef'),function(_0x3a2cbb,_0x5524c2){const _0x5a7034=_0x1e77c5;return _0x5524c2[_0x5a7034('0x1ac6')]('admin')?null:_0x3a2cbb[_0x5a7034('0x18af')](_0x5a7034('0xaf'),{'fields':_0x5a7034('0xe26'),'userProfileId':_0x5524c2[_0x5a7034('0x26cd')]()[_0x5a7034('0xb86')],'sectionId':0x44e});}]},'authenticate':!![],'permissionId':0x44e,'bodyClass':_0x1e77c5('0xae5')}),_0xd91f1b[_0x1e77c5('0x95e')](_0x1e77c5('0x106f'));}angular[_0x36e6f4('0x896')]('app.callysquare',[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),'ngAnimate',_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),'mwFormUtils',_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),'ngEmbed','angularMaterialFormBuilder',_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),_0x36e6f4('0x2040')])[_0x36e6f4('0xe11')](_0x2d8842)[_0x36e6f4('0x75e')](_0x36e6f4('0x15f4'),_0x43813c)['controller']('OdbcsController',_0x4bc222)[_0x36e6f4('0x75e')](_0x36e6f4('0x7e5'),_0x127277)['controller']('SquareRecordingsController',_0x1cb87f);const _0x363a05=_0x2734b2['p']+'src/js/modules/main/apps/analytics/views/metrics/metrics.html/metrics.html',_0x1f86a6=_0x2734b2['p']+'src/js/modules/main/apps/analytics/views/extractedReports/extractedReports.html/extractedReports.html',_0x5d6d04=_0x2734b2['p']+_0x36e6f4('0x1019'),_0x1f0d1a=_0x2734b2['p']+_0x36e6f4('0x933');var _0x162101=_0x2734b2(0xd5a);_0x25b0c4[_0x36e6f4('0x1294')]=[_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x2659'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2677'),'treeCustomData'];function _0x25b0c4(_0x473af2,_0x2e3af4,_0x26295a,_0x3e710e,_0x12b58a,_0x45e02c,_0xf37f8c){const _0x175f1b=_0x36e6f4,_0x15dad9=this;_0x15dad9[_0x175f1b('0x61a')]=[],_0x15dad9['report']=angular[_0x175f1b('0x225f')](_0x3e710e),_0x15dad9[_0x175f1b('0x2659')][_0x175f1b('0x4f0')]+=_0x175f1b('0x21b1'),_0x15dad9[_0x175f1b('0x2775')]=_0xf37f8c,_0x15dad9[_0x175f1b('0xbcf')]={'core':{'multiple':![],'animation':!![],'error':function(_0x20d8ef){const _0x27474=_0x175f1b;console[_0x27474('0xfc9')](_0x27474('0x1edc')+angular[_0x27474('0xd2')](_0x20d8ef));},'check_callback':!![],'worker':!![]},'version':0x1,'plugins':[_0x175f1b('0x164c')]},_0x15dad9[_0x175f1b('0x6e0')]={'select_node':_0x6bf428},_0x15dad9['copyReport']=_0x92b6c9,_0x15dad9[_0x175f1b('0x24a0')]=_0x160def;function _0x92b6c9(){const _0x1d6d7d=_0x175f1b;_0x15dad9[_0x1d6d7d('0x61a')]=[];let _0x5a9333;_0x12b58a['analyticCustomReport'][_0x1d6d7d('0x9cc')]({'name':_0x15dad9[_0x1d6d7d('0x2659')][_0x1d6d7d('0x4f0')],'description':_0x15dad9[_0x1d6d7d('0x2659')][_0x1d6d7d('0x101c')],'table':_0x15dad9[_0x1d6d7d('0x2659')][_0x1d6d7d('0x916')],'conditions':_0x15dad9[_0x1d6d7d('0x2659')][_0x1d6d7d('0x1dfe')],'joins':_0x15dad9[_0x1d6d7d('0x2659')]['joins'],'parent':_0x15dad9[_0x1d6d7d('0xad5')]['id']})[_0x1d6d7d('0xa44')][_0x1d6d7d('0x1166')](function(_0x26b09a){const _0x4ebc0e=_0x1d6d7d;_0x5a9333=_0x26b09a,_0x26295a['success']({'title':_0x4ebc0e('0x58d'),'msg':_0x15dad9['report'][_0x4ebc0e('0x4f0')]?_0x15dad9[_0x4ebc0e('0x2659')]['name']+_0x4ebc0e('0x440'):''});const _0x5744fa={'fields':_0x4ebc0e('0x166e'),'nolimit':!![]};return _0x5744fa[_0x45e02c===_0x4ebc0e('0x1ff5')?_0x4ebc0e('0x251f'):_0x4ebc0e('0x1944')]=_0x15dad9[_0x4ebc0e('0x2659')]['id'],_0x12b58a['analyticFieldReport'][_0x4ebc0e('0xd83')](_0x5744fa)[_0x4ebc0e('0xa44')];})[_0x1d6d7d('0x1166')](function(_0x1a9b45){const _0x43ceaa=_0x1d6d7d,_0x3f74f3=_0x2cfb05()[_0x43ceaa('0x2563')](_0x1a9b45['rows'],function(_0x29aedb){const _0x1964ac=_0x43ceaa;return _0x2cfb05()[_0x1964ac('0x25a1')]({},_0x29aedb,{'CustomReportId':_0x5a9333['id']});});return _0x12b58a['analyticFieldReport'][_0x43ceaa('0x206')](_0x3f74f3)[_0x43ceaa('0xa44')];})[_0x1d6d7d('0x1166')](function(){const _0x3894cd=_0x1d6d7d;_0x26295a[_0x3894cd('0x103b')]({'title':'Fields\x20copied!','msg':'Fields\x20has\x20been\x20copied!'}),_0x160def();})['catch'](function(_0x248dd2){const _0x26a087=_0x1d6d7d;_0x26295a['error']({'title':_0x248dd2[_0x26a087('0x52d')]?_0x26a087('0x1e21')+_0x248dd2[_0x26a087('0x52d')]+_0x26a087('0x11e1')+_0x248dd2[_0x26a087('0xe1b')]:'SYSTEM:COPYREPORT','msg':_0x248dd2['data']?JSON['stringify'](_0x248dd2[_0x26a087('0x25f4')][_0x26a087('0x1e70')]):_0x248dd2[_0x26a087('0x1586')]()});});}function _0x6bf428(_0x22e3ed,_0x14017c){const _0x538ae9=_0x175f1b;_0x15dad9[_0x538ae9('0xad5')]=_0x14017c['node'];}function _0x160def(){const _0x19452e=_0x175f1b;_0x2e3af4[_0x19452e('0x1197')]();}}const _0x1902e5=_0x25b0c4;_0x17ca26[_0x36e6f4('0x1294')]=['$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x352'),_0x36e6f4('0x2659'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2677'),_0x36e6f4('0xad5'),'describeTable',_0x36e6f4('0x243c')];function _0x17ca26(_0x245dc7,_0x57baa8,_0x2fe8c6,_0x299cd2,_0x14637e,_0x5aa31b,_0x348cd2,_0x5a242f,_0x211b8c,_0xc612ac){const _0x59a1ce=_0x36e6f4,_0x24b9df=this;_0x24b9df['errors']=[],_0x24b9df['joinTables']=[],_0x24b9df[_0x59a1ce('0xcdc')]=_0x59a1ce('0x17a6'),_0x24b9df[_0x59a1ce('0x243c')]=_0xc612ac,_0x24b9df[_0x59a1ce('0x2659')]=angular['copy'](_0x14637e),_0x24b9df[_0x59a1ce('0x352')]=_0x299cd2,_0x24b9df[_0x59a1ce('0x15de')]=![],_0x24b9df[_0x59a1ce('0x12ca')]=_0x211b8c[_0x59a1ce('0x1631')](),_0x24b9df[_0x59a1ce('0x2424')]=[{'key':_0x59a1ce('0x45a'),'value':_0x59a1ce('0x358')},{'key':_0x59a1ce('0x1675'),'value':_0x59a1ce('0xc61')},{'key':_0x59a1ce('0xa42'),'value':_0x59a1ce('0xe1e')},{'key':_0x59a1ce('0x1d99'),'value':_0x59a1ce('0x2676')}];!_0x24b9df[_0x59a1ce('0x2659')]&&(_0x24b9df[_0x59a1ce('0x2659')]={'name':'','table':_0x59a1ce('0x25f6'),'description':'','parent':_0x5a242f['id']},_0x24b9df['title']=_0x59a1ce('0x2766'),_0x24b9df[_0x59a1ce('0x15de')]=!![]);_0x24b9df[_0x59a1ce('0x6f2')]=_0x53b6ba,_0x24b9df[_0x59a1ce('0x1698')]=_0x47a4a9,_0x24b9df[_0x59a1ce('0x21b0')]=_0x5ef8e2,_0x24b9df[_0x59a1ce('0x24a0')]=_0x1d35e6,_0x24b9df[_0x59a1ce('0x172f')]=_0xbf255,_0x24b9df[_0x59a1ce('0x717')]=_0x28f940,_0x24b9df[_0x59a1ce('0x18ea')]=_0x425142;function _0x28f940(_0x3d62a3){const _0x1e4ce7=_0x59a1ce;_0x24b9df['joinTables'][_0x1e4ce7('0x57b')](_0x3d62a3,0x1);}function _0x425142(_0x2babc2,_0xfe54f3,_0x377066){const _0x1caf15=_0x59a1ce,_0x50ada5=_0x2cfb05()[_0x1caf15('0xc38')](_0x24b9df[_0x1caf15('0x12ca')],{'name':_0x377066});_0x50ada5&&_0x50ada5[_0x1caf15('0x19e3')]&&_0x5aa31b[_0x50ada5[_0x1caf15('0x19e3')]]['describe']()[_0x1caf15('0xa44')]['then'](function(_0x3937c4){const _0xf06c92=_0x1caf15;_0x2babc2[_0xfe54f3]=_0x2cfb05()[_0xf06c92('0x13ca')](_0x2cfb05()[_0xf06c92('0x14a4')](_0x3937c4),[_0xf06c92('0xa44'),'$resolved']);})[_0x1caf15('0x1a80')](function(_0x115fa3){const _0x4d585b=_0x1caf15;console[_0x4d585b('0xfc9')](_0x115fa3);});}function _0xbf255(_0x353ed4){const _0xc93697=_0x59a1ce;_0x353ed4&&(delete _0x24b9df[_0xc93697('0x1511')],_0x24b9df[_0xc93697('0x1f7b')][_0xc93697('0x1514')](_0x353ed4));}function _0x53b6ba(){const _0x3f5cb4=_0x59a1ce;_0x24b9df[_0x3f5cb4('0x61a')]=[],_0x24b9df['report'][_0x3f5cb4('0xc91')]=_0x2cfb05()[_0x3f5cb4('0x2563')](_0x24b9df[_0x3f5cb4('0x1f7b')]||[],function(_0x306d77){const _0x47f191=_0x3f5cb4;return{'parentKey':_0x306d77['parentKey'],'foreignTable':_0x306d77[_0x47f191('0x4f0')],'foreignKey':_0x306d77[_0x47f191('0x643')],'type':_0x306d77['type'][_0x47f191('0x2574')]()};}),_0x24b9df[_0x3f5cb4('0x2659')]['joins']=JSON[_0x3f5cb4('0xbac')](_0x24b9df[_0x3f5cb4('0x2659')][_0x3f5cb4('0xc91')]),_0x5aa31b[_0x348cd2][_0x3f5cb4('0x9cc')](_0x24b9df['report'])['$promise'][_0x3f5cb4('0x1166')](function(_0x551e97){const _0x41f443=_0x3f5cb4;_0x24b9df['reports']['unshift'](_0x551e97),_0x2fe8c6[_0x41f443('0x103b')]({'title':'Report\x20properly\x20created','msg':_0x24b9df[_0x41f443('0x2659')][_0x41f443('0x4f0')]?_0x24b9df[_0x41f443('0x2659')][_0x41f443('0x4f0')]+_0x41f443('0x1eda'):''}),_0x1d35e6();})['catch'](function(_0xa6d218){const _0x18ba26=_0x3f5cb4;if(_0xa6d218[_0x18ba26('0x25f4')]&&_0xa6d218[_0x18ba26('0x25f4')]['errors']&&_0xa6d218[_0x18ba26('0x25f4')][_0x18ba26('0x61a')][_0x18ba26('0x264b')]){_0x24b9df[_0x18ba26('0x61a')]=_0xa6d218['data'][_0x18ba26('0x61a')]||[{'message':_0xa6d218[_0x18ba26('0x1586')](),'type':'api.analyticReport.save'}];for(let _0x60d9e4=0x0;_0x60d9e4<_0xa6d218[_0x18ba26('0x25f4')][_0x18ba26('0x61a')][_0x18ba26('0x264b')];_0x60d9e4++){_0x2fe8c6[_0x18ba26('0xfc9')]({'title':_0xa6d218[_0x18ba26('0x25f4')][_0x18ba26('0x61a')][_0x60d9e4][_0x18ba26('0x1345')],'msg':_0xa6d218['data']['errors'][_0x60d9e4][_0x18ba26('0x1e70')]});}}else _0x2fe8c6['error']({'title':_0xa6d218[_0x18ba26('0x52d')]?'API:'+_0xa6d218[_0x18ba26('0x52d')]+_0x18ba26('0x11e1')+_0xa6d218[_0x18ba26('0xe1b')]:_0x18ba26('0x14ed'),'msg':_0xa6d218[_0x18ba26('0x25f4')]?JSON[_0x18ba26('0xbac')](_0xa6d218['data'][_0x18ba26('0x1e70')]):_0xa6d218[_0x18ba26('0x1586')]()});});}function _0x47a4a9(){const _0x145762=_0x59a1ce;_0x24b9df[_0x145762('0x61a')]=[],_0x5aa31b[_0x348cd2][_0x145762('0x1449')]({'id':_0x24b9df[_0x145762('0x2659')]['id']},_0x24b9df[_0x145762('0x2659')])[_0x145762('0xa44')][_0x145762('0x1166')](function(_0x376026){const _0x408397=_0x145762,_0x384021=_0x2cfb05()[_0x408397('0xc38')](_0x24b9df[_0x408397('0x352')],{'id':_0x376026['id']});_0x384021&&_0x2cfb05()[_0x408397('0xcc3')](_0x384021,_0x376026),_0x2fe8c6['success']({'title':_0x408397('0x571'),'msg':_0x24b9df[_0x408397('0x2659')][_0x408397('0x4f0')]?_0x24b9df['report'][_0x408397('0x4f0')]+_0x408397('0x7d'):''}),_0x1d35e6();})[_0x145762('0x1a80')](function(_0x226570){const _0x1410a3=_0x145762;if(_0x226570[_0x1410a3('0x25f4')]&&_0x226570[_0x1410a3('0x25f4')]['errors']&&_0x226570[_0x1410a3('0x25f4')][_0x1410a3('0x61a')]['length']){_0x24b9df[_0x1410a3('0x61a')]=_0x226570[_0x1410a3('0x25f4')][_0x1410a3('0x61a')]||[{'message':_0x226570[_0x1410a3('0x1586')](),'type':'api.analyticReport.update'}];for(let _0xf38812=0x0;_0xf38812<_0x226570[_0x1410a3('0x25f4')]['errors'][_0x1410a3('0x264b')];_0xf38812++){_0x2fe8c6[_0x1410a3('0xfc9')]({'title':_0x226570[_0x1410a3('0x25f4')][_0x1410a3('0x61a')][_0xf38812][_0x1410a3('0x1345')],'msg':_0x226570['data'][_0x1410a3('0x61a')][_0xf38812][_0x1410a3('0x1e70')]});}}else _0x2fe8c6[_0x1410a3('0xfc9')]({'title':_0x226570[_0x1410a3('0x52d')]?'API:'+_0x226570[_0x1410a3('0x52d')]+'\x20-\x20'+_0x226570['statusText']:_0x1410a3('0x1661'),'msg':_0x226570['data']?JSON[_0x1410a3('0xbac')](_0x226570[_0x1410a3('0x25f4')][_0x1410a3('0x1e70')]):_0x226570['toString']()});});}function _0x5ef8e2(){const _0x28ae2f=_0x59a1ce;_0x24b9df[_0x28ae2f('0x61a')]=[];const _0x4ed9c0=_0x57baa8[_0x28ae2f('0x1d26')]()[_0x28ae2f('0xcdc')](_0x28ae2f('0x7fb'))['content'](_0x28ae2f('0x1fdf'))[_0x28ae2f('0x8e8')](_0x28ae2f('0x2539'))['ok'](_0x28ae2f('0x18'))[_0x28ae2f('0x3f')](_0x28ae2f('0x497'))[_0x28ae2f('0x203b')](event);_0x57baa8[_0x28ae2f('0x1f80')](_0x4ed9c0)[_0x28ae2f('0x1166')](function(){const _0x3e4328=_0x28ae2f;_0x5aa31b[_0x348cd2]['delete']({'id':_0x24b9df[_0x3e4328('0x2659')]['id']})[_0x3e4328('0xa44')]['then'](function(){const _0x1f90fd=_0x3e4328;_0x2cfb05()[_0x1f90fd('0x127f')](_0x24b9df[_0x1f90fd('0x352')],{'id':_0x24b9df[_0x1f90fd('0x2659')]['id']}),_0x2fe8c6['success']({'title':_0x1f90fd('0x1c9e'),'msg':_0x24b9df[_0x1f90fd('0x2659')][_0x1f90fd('0x4f0')]?_0x24b9df['report'][_0x1f90fd('0x4f0')]+_0x1f90fd('0x7cd'):''}),_0x1d35e6();})[_0x3e4328('0x1a80')](function(_0x33a96a){const _0x2a9471=_0x3e4328;_0x24b9df[_0x2a9471('0x61a')]=_0x33a96a[_0x2a9471('0x25f4')][_0x2a9471('0x61a')]||[{'message':_0x33a96a['toString'](),'type':_0x2a9471('0x13ff')}];});},function(){});}function _0x1d35e6(){const _0x424638=_0x59a1ce;_0x57baa8[_0x424638('0x1197')]();}}const _0xe61666=_0x17ca26;_0x450c85[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x28a2'),'toasty','sqlUtil'];function _0x450c85(_0x15939c,_0x4c167e,_0x2deb21,_0x6b50fb){const _0x485e79=_0x36e6f4,_0x5887a3=this;_0x5887a3['report']={},_0x5887a3[_0x485e79('0x1dfe')]=_0x6b50fb[_0x485e79('0x1e7a')],_0x5887a3['init']=_0x5051c1,_0x5887a3[_0x485e79('0x111b')]=_0x207e43,_0x5887a3[_0x485e79('0x27')]=_0x1d778c,_0x5887a3[_0x485e79('0x8a2')]=_0x38cf11,_0x5887a3[_0x485e79('0x84e')]=_0x97dc5f;function _0x5051c1(_0x18a1d2,_0x58e9d5){const _0x426dde=_0x485e79;_0x5887a3[_0x426dde('0x2659')]=_0x18a1d2,_0x5887a3[_0x426dde('0x2659')][_0x426dde('0x8ff')]=angular[_0x426dde('0x2524')](_0x18a1d2[_0x426dde('0x1dfe')])||{'group':{'operator':'AND','rules':[]}},_0x5887a3['crudPermissions']=typeof _0x58e9d5!==_0x426dde('0x1048')?_0x58e9d5:{'readOnly':!![],'canEdit':![],'canDelete':![]};for(let _0x44bbd0=0x0;_0x44bbd0<_0x5887a3[_0x426dde('0x2659')][_0x426dde('0x8ff')][_0x426dde('0x23fa')][_0x426dde('0x43d')][_0x426dde('0x264b')];_0x44bbd0++){if(_0x5887a3[_0x426dde('0x2659')]['condition'][_0x426dde('0x23fa')][_0x426dde('0x43d')][_0x44bbd0][_0x426dde('0x22f3')]){const _0x4d2dad=_0x5887a3['report'][_0x426dde('0x8ff')][_0x426dde('0x23fa')][_0x426dde('0x43d')][_0x44bbd0]['field'][_0x426dde('0x25c8')]('.');_0x4d2dad[_0x426dde('0x264b')]===0x1&&(_0x5887a3['report'][_0x426dde('0x8ff')]['group'][_0x426dde('0x43d')][_0x44bbd0]['field']=_0x5887a3[_0x426dde('0x2659')][_0x426dde('0x916')]+'.'+_0x5887a3['report'][_0x426dde('0x8ff')][_0x426dde('0x23fa')]['rules'][_0x44bbd0]['field']);}}_0x4c167e[_0x426dde('0x1068')](_0x5887a3['report']['table'])[_0x426dde('0x1166')](function(_0x3edfae){const _0x4f1e98=_0x426dde;_0x5887a3['columns']=_0x2cfb05()[_0x4f1e98('0x13ca')](_0x2cfb05()[_0x4f1e98('0x14a4')](_0x3edfae),['$promise',_0x4f1e98('0xfcd'),_0x4f1e98('0x262'),_0x4f1e98('0x6f9')]);})[_0x426dde('0x1a80')](function(_0x2f7b59){const _0x20b810=_0x426dde;_0x2deb21[_0x20b810('0xfc9')]({'title':_0x2f7b59[_0x20b810('0x52d')]?_0x20b810('0x1e21')+_0x2f7b59[_0x20b810('0x52d')]+_0x20b810('0x11e1')+_0x2f7b59[_0x20b810('0xe1b')]:'SYSTEM:DESCRIBE','msg':_0x2f7b59[_0x20b810('0x25f4')]?JSON['stringify'](_0x2f7b59['data']):_0x2f7b59[_0x20b810('0x1586')]()});});}function _0x207e43(_0x22e21f){_0x22e21f['unshift']({'condition':'=','field':'','value':''});}function _0x1d778c(_0x1d925){const _0x40521a=_0x485e79;_0x1d925[_0x40521a('0x1514')]({'group':{'operator':'AND','rules':[]}});}function _0x38cf11(_0x3d0328,_0x100b97,_0x30ef91){const _0x5f362f=_0x485e79,_0x2c04f2=_0x15939c[_0x5f362f('0x1d26')]()['title'](_0x5f362f('0x135a'))[_0x5f362f('0xf3c')]('The\x20item\x20will\x20be\x20deleted.')[_0x5f362f('0x8e8')]('delete\x20item')[_0x5f362f('0x203b')](_0x30ef91)['ok']('OK')[_0x5f362f('0x3f')](_0x5f362f('0x2d3'));_0x15939c[_0x5f362f('0x1f80')](_0x2c04f2)[_0x5f362f('0x1166')](function(){_0x3d0328['splice'](_0x100b97,0x1);},function(){const _0x382cb7=_0x5f362f;console[_0x382cb7('0x455')](_0x382cb7('0x2d3'));});}function _0x97dc5f(_0x31fe6b){const _0x2143ef=_0x485e79;return!_0x2cfb05()['includes']([_0x2143ef('0xfba'),_0x2143ef('0x1dbe'),'IS\x20EMPTY','IS\x20NOT\x20EMPTY'],_0x31fe6b);}}const _0x3a1ac6=_0x450c85;_0x246069[_0x36e6f4('0x1294')]=[_0x36e6f4('0x19e3')];function _0x246069(_0x49648a){const _0x44a8fa=_0x36e6f4,_0x1d939b={'cm_companies':'cmCompany','cm_contacts':_0x44a8fa('0x149e'),'cm_hopper':_0x44a8fa('0x256a'),'cm_hopper_final':'cmHopperFinal','cm_hopper_history':_0x44a8fa('0x1a26'),'cm_lists':_0x44a8fa('0xdd9'),'chat_websites':_0x44a8fa('0x1864'),'chat_queues':_0x44a8fa('0x1e45'),'chat_interactions':_0x44a8fa('0x1162'),'chat_messages':_0x44a8fa('0x1102'),'chat_offline_messages':_0x44a8fa('0x2213'),'report_chat_queue':_0x44a8fa('0x1029'),'report_chat_transfer':_0x44a8fa('0x1567'),'mail_accounts':_0x44a8fa('0x21b9'),'mail_queues':_0x44a8fa('0x24c9'),'mail_interactions':_0x44a8fa('0x382'),'mail_messages':_0x44a8fa('0x9d7'),'report_mail_queue':_0x44a8fa('0x20a0'),'report_mail_transfer':_0x44a8fa('0x1750'),'openchannel_accounts':_0x44a8fa('0x77f'),'openchannel_queues':_0x44a8fa('0x262f'),'openchannel_interactions':'openchannelInteraction','openchannel_messages':_0x44a8fa('0x1b90'),'report_openchannel_queue':_0x44a8fa('0x18a7'),'report_openchannel_transfer':_0x44a8fa('0x1506'),'sms_accounts':'smsAccount','sms_queues':'smsQueue','sms_interactions':_0x44a8fa('0x14c3'),'sms_messages':_0x44a8fa('0x1e6a'),'report_sms_queue':_0x44a8fa('0xc8b'),'report_sms_transfer':_0x44a8fa('0xee'),'fax_accounts':_0x44a8fa('0x2085'),'fax_queues':_0x44a8fa('0x1a5b'),'fax_interactions':_0x44a8fa('0x1342'),'fax_messages':_0x44a8fa('0x2790'),'report_fax_transfer':_0x44a8fa('0x17e9'),'report_fax_queue':_0x44a8fa('0xbf1'),'report_call':_0x44a8fa('0x26e0'),'report_agent':_0x44a8fa('0x7af'),'report_square':_0x44a8fa('0x25de'),'report_member':_0x44a8fa('0x21d'),'report_queue':_0x44a8fa('0x1ede'),'report_square_details':_0x44a8fa('0xfd5'),'report_dial':'voiceDialReport','report_jscripty_sessions':_0x44a8fa('0x3ed'),'report_jscripty_questions':_0x44a8fa('0x816'),'report_jscripty_answers':_0x44a8fa('0x228b'),'users':'user','voice_recordings':_0x44a8fa('0x1825'),'cdr':_0x44a8fa('0x6cd'),'whatsapp_accounts':_0x44a8fa('0xcc5'),'whatsapp_queues':_0x44a8fa('0x1bb6'),'whatsapp_interactions':'whatsappInteraction','whatsapp_messages':_0x44a8fa('0x101f'),'report_whatsapp_queue':_0x44a8fa('0x1c5f'),'report_whatsapp_transfer':_0x44a8fa('0x2852')};return{'getMap':function(){const _0x128a40=_0x44a8fa,_0x540147=[];return _0x2cfb05()[_0x128a40('0x941')](_0x1d939b,function(_0x4e9b74,_0x385b8a){_0x540147['push']({'name':_0x385b8a,'api':_0x4e9b74});}),_0x540147;},'getColumns':function(_0x36a2ac){const _0x3ce5a5=_0x44a8fa,_0x1f72e1=_0x1d939b[_0x36a2ac];return _0x49648a[_0x1f72e1]['describe']()[_0x3ce5a5('0xa44')];}};}const _0x358762=_0x246069;_0x2b8b6c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x2659'),'reportFields',_0x36e6f4('0x17b3'),_0x36e6f4('0x15d3'),_0x36e6f4('0x2022'),_0x36e6f4('0x662'),_0x36e6f4('0x19e3'),_0x36e6f4('0x243c')];function _0x2b8b6c(_0x1c0b65,_0x29787d,_0x255413,_0x373847,_0x512c05,_0x43e5f3,_0x34aef4,_0xf24c6f,_0x1c6ad8,_0x592351,_0x2a4d60,_0x3e3bb9){const _0x56b975=_0x36e6f4,_0x3dea33=this;_0x3dea33['errors']=[],_0x3dea33[_0x56b975('0xcdc')]=_0x56b975('0x28cf'),_0x3dea33[_0x56b975('0x2659')]=_0x512c05,_0x3dea33['reportField']=angular['copy'](_0x34aef4),_0x3dea33['reportFields']=_0x43e5f3,_0x3dea33[_0x56b975('0x15d3')]=_0xf24c6f,_0x3dea33[_0x56b975('0x2022')]=_0x1c6ad8,_0x3dea33['sqlUtil']=_0x592351,_0x3dea33['newReportField']=![],_0x3dea33[_0x56b975('0x243c')]=_0x3e3bb9;if(!_0x3dea33[_0x56b975('0x17b3')])_0x3dea33['reportField']={'type':_0x56b975('0x226d'),'function':null,'format':null,'groupBy':![],'orderBy':null},_0x3dea33[_0x56b975('0xcdc')]=_0x56b975('0x2014'),_0x3dea33['newReportField']=!![];else{_0x3dea33[_0x56b975('0x17b3')][_0x56b975('0x1345')]=_0x3dea33['reportField'][_0x56b975('0x2853')]?_0x56b975('0x2853'):_0x3dea33[_0x56b975('0x17b3')][_0x56b975('0x140c')]?_0x56b975('0x64c'):'column';if(_0x3dea33[_0x56b975('0x17b3')][_0x56b975('0x22f3')]&&!_0x3dea33['reportField'][_0x56b975('0x2853')]&&_0x2cfb05()[_0x56b975('0x2863')](_0x3dea33[_0x56b975('0x17b3')][_0x56b975('0x140c')])){const _0x26d6c6=_0x3dea33['reportField']['field']['split']('.');_0x26d6c6[_0x56b975('0x264b')]===0x1&&(_0x3dea33['reportField']['field']=_0x3dea33[_0x56b975('0x2659')][_0x56b975('0x916')]+'.'+_0x3dea33['reportField'][_0x56b975('0x22f3')]);}}_0x3dea33['addNewReportField']=_0x316360,_0x3dea33[_0x56b975('0x2093')]=_0x673b45,_0x3dea33[_0x56b975('0x26b4')]=_0x44dfd5,_0x3dea33['closeDialog']=_0x3db59d;function _0x316360(){const _0x154d2a=_0x56b975;_0x3dea33['errors']=[],_0x3dea33[_0x154d2a('0x17b3')][_0x154d2a('0x2853')]=_0x3dea33[_0x154d2a('0x17b3')][_0x154d2a('0x1345')]===_0x154d2a('0x2853'),_0x3dea33[_0x154d2a('0x17b3')][_0x154d2a('0x140c')]=_0x3dea33[_0x154d2a('0x17b3')]['type']===_0x154d2a('0x64c')?_0x3dea33[_0x154d2a('0x17b3')]['MetricId']:null,_0x3dea33[_0x154d2a('0x17b3')][_0x154d2a('0x251f')]=_0x3dea33[_0x154d2a('0x2659')]['id'],_0x2a4d60['analyticFieldReport'][_0x154d2a('0x9cc')](_0x3dea33[_0x154d2a('0x17b3')])[_0x154d2a('0xa44')][_0x154d2a('0x1166')](function(_0x2e7dc5){const _0x486765=_0x154d2a;_0x3dea33[_0x486765('0x2577')]['push'](_0x2e7dc5),_0x373847['success']({'title':'Report\x20field\x20properly\x20created','msg':_0x3dea33[_0x486765('0x17b3')][_0x486765('0x22f3')]?_0x3dea33[_0x486765('0x17b3')][_0x486765('0x22f3')]+_0x486765('0x1eda'):_0x3dea33['reportField'][_0x486765('0x1345')]+_0x486765('0x1eda')}),_0x3db59d();})[_0x154d2a('0x1a80')](function(_0x134212){const _0x493ec0=_0x154d2a;_0x3dea33['errors']=_0x134212[_0x493ec0('0x25f4')][_0x493ec0('0x61a')]||[{'message':_0x134212[_0x493ec0('0x1586')](),'type':_0x493ec0('0x1857')}];});}function _0x673b45(){const _0x5bc017=_0x56b975;_0x3dea33[_0x5bc017('0x61a')]=[],_0x3dea33['reportField']['custom']=_0x3dea33['reportField'][_0x5bc017('0x1345')]===_0x5bc017('0x2853'),_0x3dea33[_0x5bc017('0x17b3')][_0x5bc017('0x140c')]=_0x3dea33[_0x5bc017('0x17b3')][_0x5bc017('0x1345')]==='metric'?_0x3dea33['reportField'][_0x5bc017('0x140c')]:null,_0x2a4d60['analyticFieldReport'][_0x5bc017('0x1449')]({'id':_0x3dea33[_0x5bc017('0x17b3')]['id']},_0x3dea33[_0x5bc017('0x17b3')])[_0x5bc017('0xa44')][_0x5bc017('0x1166')](function(_0x2959fa){const _0x204ff9=_0x5bc017,_0x272174=_0x2cfb05()[_0x204ff9('0xc38')](_0x3dea33['reportFields'],{'id':_0x2959fa['id']});_0x272174&&_0x2cfb05()[_0x204ff9('0xcc3')](_0x272174,_0x2959fa),_0x373847['success']({'title':_0x204ff9('0x303'),'msg':_0x3dea33[_0x204ff9('0x17b3')][_0x204ff9('0x22f3')]?_0x3dea33[_0x204ff9('0x17b3')][_0x204ff9('0x22f3')]+_0x204ff9('0x7d'):''}),_0x3db59d();})[_0x5bc017('0x1a80')](function(_0x542f38){const _0x1b7bd8=_0x5bc017;_0x3dea33['errors']=_0x542f38[_0x1b7bd8('0x25f4')][_0x1b7bd8('0x61a')]||[{'message':_0x542f38[_0x1b7bd8('0x1586')](),'type':_0x1b7bd8('0x9c4')}];});}function _0x44dfd5(_0x5d361d){const _0x198066=_0x56b975;_0x3dea33[_0x198066('0x61a')]=[];const _0x368d7e=_0x255413[_0x198066('0x1d26')]()[_0x198066('0xcdc')](_0x198066('0x7fb'))[_0x198066('0xacc')](_0x198066('0x7e7'))[_0x198066('0x8e8')]('Delete\x20Report')['ok']('Delete')[_0x198066('0x3f')](_0x198066('0x497'))['targetEvent'](_0x5d361d);_0x255413[_0x198066('0x1f80')](_0x368d7e)['then'](function(){const _0x59d2ec=_0x198066;_0x2a4d60[_0x59d2ec('0x1405')][_0x59d2ec('0x906')]({'id':_0x3dea33[_0x59d2ec('0x17b3')]['id']})['$promise'][_0x59d2ec('0x1166')](function(){const _0x5ecdc0=_0x59d2ec;_0x2cfb05()[_0x5ecdc0('0x127f')](_0x3dea33['reportFields'],{'id':_0x3dea33[_0x5ecdc0('0x17b3')]['id']}),_0x373847[_0x5ecdc0('0x103b')]({'title':_0x5ecdc0('0xa67'),'msg':_0x3dea33['reportField'][_0x5ecdc0('0x22f3')]?_0x3dea33[_0x5ecdc0('0x17b3')]['field']+_0x5ecdc0('0x7cd'):''}),_0x3db59d();})[_0x59d2ec('0x1a80')](function(_0x520401){const _0x559245=_0x59d2ec;_0x3dea33[_0x559245('0x61a')]=_0x520401[_0x559245('0x25f4')][_0x559245('0x61a')]||[{'message':_0x520401['toString'](),'type':_0x559245('0x28aa')}];});},function(){});}function _0x3db59d(){const _0x36aa1e=_0x56b975;_0x255413[_0x36aa1e('0x1197')]();}}const _0x35547f=_0x2b8b6c,_0x2faa39=_0x2734b2['p']+_0x36e6f4('0x426');_0x2c3392[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),'$scope',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x28a2'),_0x36e6f4('0x662'),_0x36e6f4('0x586')];function _0x2c3392(_0x185a2c,_0x3f6261,_0x25a145,_0x18d9a8,_0x2c0d38,_0x38f83b,_0x111acb,_0x45794a,_0x2cfa88,_0x406365){const _0x51e96a=_0x36e6f4,_0x1f2dc2=this;_0x1f2dc2[_0x51e96a('0x2659')]={},_0x1f2dc2['reportFields']={'count':0x0,'rows':[]},_0x1f2dc2[_0x51e96a('0x1926')]=_0x2cfb05()[_0x51e96a('0x155c')](_0x2cfa88[_0x51e96a('0xefd')],_0x51e96a('0x18e0')),_0x1f2dc2[_0x51e96a('0x1531')]=_0x2cfb05()[_0x51e96a('0x155c')](_0x2cfa88['getFormats'],_0x51e96a('0x18e0')),_0x1f2dc2[_0x51e96a('0x1535')]=_0x2cfb05()['keyBy'](_0x2cfa88[_0x51e96a('0x1a4d')],_0x51e96a('0x18e0')),_0x1f2dc2[_0x51e96a('0xe63')]=_0x2cfb05()['keyBy'](_0x2cfa88[_0x51e96a('0x164a')],_0x51e96a('0x18e0')),_0x1f2dc2[_0x51e96a('0x145')]=[],_0x1f2dc2[_0x51e96a('0x2218')]={'fields':_0x51e96a('0x10fd'),'nolimit':!![]},_0x1f2dc2[_0x51e96a('0x2207')]={'animation':0x64,'onSort':function(_0x5e02b1){const _0x5e7fee=_0x51e96a;_0x111acb[_0x5e7fee('0x1405')][_0x5e7fee('0x2603')]({'id':_0x1f2dc2[_0x5e7fee('0x2659')]['id']},_0x5e02b1[_0x5e7fee('0xf1')])['$promise'][_0x5e7fee('0x1166')](function(_0x2f2e7b){const _0x32465e=_0x5e7fee;_0x1f2dc2[_0x32465e('0x2577')][_0x32465e('0x269a')]=_0x2f2e7b;})[_0x5e7fee('0x1a80')](function(_0x5becb6){const _0x229ec1=_0x5e7fee;_0x38f83b[_0x229ec1('0xfc9')]({'title':_0x5becb6['status']?_0x229ec1('0x1e21')+_0x5becb6['status']+_0x229ec1('0x11e1')+_0x5becb6['statusText']:_0x229ec1('0x18e3')});});}},_0x1f2dc2['init']=_0x1aacbe,_0x1f2dc2[_0x51e96a('0x8a2')]=_0x4d7364,_0x1f2dc2[_0x51e96a('0x103b')]=_0x3e13f0,_0x1f2dc2[_0x51e96a('0x20f2')]=_0x48f68f,_0x1f2dc2[_0x51e96a('0x694')]=_0x577ba2,_0x1f2dc2[_0x51e96a('0x26b4')]=_0x463407,_0x1f2dc2[_0x51e96a('0xdc9')]=_0x3192af,_0x1f2dc2[_0x51e96a('0x249a')]=_0x3d8b20,_0x1f2dc2['getMetricValue']=_0x1bdd0d;function _0x1aacbe(_0x454385,_0x2a54c7){const _0x10cf99=_0x51e96a;_0x1f2dc2[_0x10cf99('0x2659')]=_0x454385,_0x1f2dc2[_0x10cf99('0x2218')][_0x10cf99('0x251f')]=_0x1f2dc2[_0x10cf99('0x2659')]['id'],_0x1f2dc2['crudPermissions']=typeof _0x2a54c7!==_0x10cf99('0x1048')?_0x2a54c7:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1f2dc2[_0x10cf99('0x2207')][_0x10cf99('0xbd0')]=!_0x1f2dc2[_0x10cf99('0x243c')][_0x10cf99('0x1684')]?!![]:![],_0x45794a[_0x10cf99('0x1068')](_0x1f2dc2[_0x10cf99('0x2659')][_0x10cf99('0x916')])[_0x10cf99('0x1166')](function(_0x1e9f0a){const _0xd4cde4=_0x10cf99;return _0x1f2dc2[_0xd4cde4('0x2022')]=_0x2cfb05()[_0xd4cde4('0x13ca')](_0x2cfb05()['keys'](_0x1e9f0a),['$promise',_0xd4cde4('0xfcd')]),_0x111acb['analyticMetric'][_0xd4cde4('0xd83')]({'fields':_0xd4cde4('0xfa6'),'nolimit':!![]})[_0xd4cde4('0xa44')];})[_0x10cf99('0x1166')](function(_0x17f464){const _0x515077=_0x10cf99;_0x1f2dc2[_0x515077('0x15d3')]=_0x17f464[_0x515077('0x269a')];})[_0x10cf99('0x1a80')](function(_0x251573){const _0x20a046=_0x10cf99;_0x38f83b[_0x20a046('0xfc9')]({'title':_0x251573[_0x20a046('0x52d')]?'API:'+_0x251573[_0x20a046('0x52d')]+'\x20-\x20'+_0x251573[_0x20a046('0xe1b')]:_0x20a046('0xe2c'),'msg':_0x251573[_0x20a046('0x25f4')]?JSON[_0x20a046('0xbac')](_0x251573[_0x20a046('0x25f4')]):_0x251573['toString']()});}),_0x1f2dc2[_0x10cf99('0x20f2')]();}function _0x4d7364(_0xb8c063,_0x3f3859){const _0x111fbf=_0x51e96a,_0x4f258a=_0x18d9a8['confirm']()['title'](_0x111fbf('0xa61'))[_0x111fbf('0xf3c')](_0x111fbf('0x12b5')+_0xb8c063[_0x111fbf('0x22f3')]+_0x111fbf('0xace')+_0x111fbf('0x3f3'))[_0x111fbf('0x8e8')](_0x111fbf('0x2127'))[_0x111fbf('0x203b')](_0x3f3859)['ok']('OK')['cancel'](_0x111fbf('0x2d3'));_0x18d9a8['show'](_0x4f258a)['then'](function(){_0x463407(_0xb8c063);},function(){const _0x3c7156=_0x111fbf;console[_0x3c7156('0x455')](_0x3c7156('0x2d3'));});}let _0x33a170=!![];_0x3f6261['$watch'](_0x51e96a('0x2347'),function(){_0x33a170?_0x25a145(function(){_0x33a170=![];}):_0x1f2dc2['getReportFields']();});function _0x3e13f0(_0x5937f5){const _0x3dfc7f=_0x51e96a;_0x1f2dc2[_0x3dfc7f('0x2577')]=_0x5937f5||{'count':0x0,'rows':[]};}function _0x48f68f(){const _0x4fcb58=_0x51e96a;_0x1f2dc2[_0x4fcb58('0x1f48')]=_0x111acb['analyticFieldReport'][_0x4fcb58('0xd83')](_0x1f2dc2[_0x4fcb58('0x2218')],_0x3e13f0)[_0x4fcb58('0xa44')];}function _0x577ba2(_0x57c0b5,_0x299517){const _0x4c66a9=_0x51e96a;_0x18d9a8[_0x4c66a9('0x1f80')]({'controller':_0x4c66a9('0x4c0'),'controllerAs':'vm','templateUrl':_0x2faa39,'parent':angular[_0x4c66a9('0x1194')](_0x2c0d38[_0x4c66a9('0x8d2')]),'targetEvent':_0x57c0b5,'clickOutsideToClose':!![],'locals':{'report':_0x1f2dc2['report'],'reportField':_0x299517,'reportFields':_0x1f2dc2[_0x4c66a9('0x2577')][_0x4c66a9('0x269a')],'metrics':_0x1f2dc2[_0x4c66a9('0x15d3')],'columns':_0x1f2dc2[_0x4c66a9('0x2022')],'setting':null,'crudPermissions':_0x1f2dc2['crudPermissions']}});}function _0x463407(_0x4b4f8a){const _0x5bef0b=_0x51e96a;_0x111acb[_0x5bef0b('0x1405')][_0x5bef0b('0x906')]({'id':_0x4b4f8a['id']})[_0x5bef0b('0xa44')]['then'](function(){const _0x37d645=_0x5bef0b;_0x1f2dc2[_0x37d645('0x145')]=[],_0x2cfb05()[_0x37d645('0x127f')](_0x1f2dc2['reportFields'][_0x37d645('0x269a')],{'id':_0x4b4f8a['id']}),_0x1f2dc2['reportFields']['count']-=0x1,!_0x1f2dc2[_0x37d645('0x2577')][_0x37d645('0x269a')][_0x37d645('0x264b')]&&_0x1f2dc2[_0x37d645('0x20f2')](),_0x38f83b['success']({'title':_0x37d645('0x13cb'),'msg':_0x4b4f8a[_0x37d645('0x22f3')]?_0x4b4f8a[_0x37d645('0x22f3')]+'\x20has\x20been\x20deleted!':''});})[_0x5bef0b('0x1a80')](function(_0x1d7261){const _0x1c2c8c=_0x5bef0b;_0x38f83b[_0x1c2c8c('0xfc9')]({'title':_0x1d7261[_0x1c2c8c('0x52d')]?_0x1c2c8c('0x1e21')+_0x1d7261[_0x1c2c8c('0x52d')]+_0x1c2c8c('0x11e1')+_0x1d7261[_0x1c2c8c('0xe1b')]:'SYSTEM:DELETEFIELD','msg':_0x1d7261['data']?JSON[_0x1c2c8c('0xbac')](_0x1d7261[_0x1c2c8c('0x25f4')]):_0x1d7261[_0x1c2c8c('0x1586')]()});});}function _0x3192af(_0x570919){const _0x3ae932=_0x51e96a,_0x3fba26=_0x18d9a8[_0x3ae932('0x1d26')]()[_0x3ae932('0xcdc')](_0x3ae932('0x1d42'))[_0x3ae932('0xf3c')](_0x3ae932('0x12b5')+_0x1f2dc2[_0x3ae932('0x145')][_0x3ae932('0x264b')]+_0x3ae932('0x196d')+_0x3ae932('0x3f3'))['ariaLabel']('delete\x20fields')[_0x3ae932('0x203b')](_0x570919)['ok']('OK')['cancel'](_0x3ae932('0x2d3'));_0x18d9a8['show'](_0x3fba26)[_0x3ae932('0x1166')](function(){const _0x5c975c=_0x3ae932;_0x1f2dc2[_0x5c975c('0x145')][_0x5c975c('0x2782')](function(_0x28b8a0){_0x463407(_0x28b8a0);}),_0x1f2dc2[_0x5c975c('0x145')]=[];});}function _0x3d8b20(_0x4c4c06){const _0x4feeaf=_0x51e96a,_0x4543d1=_0x2cfb05()[_0x4feeaf('0xc38')](_0x1f2dc2[_0x4feeaf('0x15d3')],{'id':_0x4c4c06});return _0x4543d1?_0x4543d1[_0x4feeaf('0x4f0')]:_0x406365[_0x4feeaf('0x25cc')](_0x4feeaf('0x3d5'));}function _0x1bdd0d(_0x28b91c){const _0x37f846=_0x51e96a,_0x30e37f=_0x2cfb05()[_0x37f846('0xc38')](_0x1f2dc2[_0x37f846('0x15d3')],{'id':_0x28b91c});return _0x30e37f?_0x30e37f[_0x37f846('0x64c')]:_0x406365[_0x37f846('0x25cc')](_0x37f846('0x3d5'));}}const _0x311b51=_0x2c3392;function _0x1f6f70(){const _0x5ed0f1=_0x36e6f4,_0x474fe5=[{'value':_0x5ed0f1('0x1acc'),'option':function(_0x32792d){const _0x309362=_0x5ed0f1;return _0x309362('0x1c1e')+_0x32792d+')';}},{'value':_0x5ed0f1('0x24cb'),'option':function(_0x2fb878){return'COUNT\x20('+_0x2fb878+')';}},{'value':'COUNT\x20DISTINCT','option':function(_0x5b0112){return'COUNT\x20(DISTINCT\x20'+_0x5b0112+')';}},{'value':_0x5ed0f1('0xa37'),'option':function(_0xdfb844){const _0xfa1b76=_0x5ed0f1;return _0xfa1b76('0x1b85')+_0xdfb844+')';}},{'value':_0x5ed0f1('0x136a'),'option':function(_0x2d50c7){return'MIN\x20('+_0x2d50c7+')';}},{'value':_0x5ed0f1('0x1999'),'option':function(_0x47003a){const _0x2aa67a=_0x5ed0f1;return _0x2aa67a('0x111a')+_0x47003a+')';}},{'value':_0x5ed0f1('0xbe1'),'option':function(_0x38d582){const _0x27e3d6=_0x5ed0f1;return _0x27e3d6('0xb73')+_0x38d582+')';}},{'value':_0x5ed0f1('0xea'),'option':function(_0x415aee){const _0x10164b=_0x5ed0f1;return _0x10164b('0xb73')+_0x415aee+_0x10164b('0xa40')+_0x415aee+_0x10164b('0xc44');}},{'value':_0x5ed0f1('0x2c3'),'option':function(_0x3e0aa6){const _0x3c6ed5=_0x5ed0f1;return _0x3c6ed5('0xb73')+_0x3e0aa6+_0x3c6ed5('0xa40')+_0x3e0aa6+_0x3c6ed5('0x250a');}}],_0x1fec1d=[{'value':_0x5ed0f1('0x2796'),'option':function(_0x5a5022){const _0x38a5f4=_0x5ed0f1;return _0x38a5f4('0x1adb')+_0x5a5022+')';}},{'value':'DATE','option':function(_0x35beef){const _0x4a6e26=_0x5ed0f1;return _0x4a6e26('0x18f4')+_0x35beef+')';}},{'value':_0x5ed0f1('0x80a'),'option':function(_0x4b4a25){const _0x3b9988=_0x5ed0f1;return _0x3b9988('0x1f9')+_0x4b4a25+')';}},{'value':_0x5ed0f1('0x1b51'),'option':function(_0x330845){const _0x3b4c1e=_0x5ed0f1;return _0x3b4c1e('0xe59')+_0x330845+')';}},{'value':_0x5ed0f1('0xa7e'),'option':function(_0x551e2e){const _0x4869bf=_0x5ed0f1;return _0x4869bf('0x229c')+_0x551e2e+')';}}],_0x2916a3=[{'value':![],'option':function(){return'No';}},{'value':!![],'option':function(_0x4428c0){const _0x47a2b3=_0x5ed0f1;return _0x47a2b3('0x227c')+_0x4428c0;}}],_0x508fa0=[{'value':_0x5ed0f1('0x22d4'),'option':function(_0x2d467b){const _0x2280a3=_0x5ed0f1;return'ORDER\x20BY\x20'+_0x2d467b+_0x2280a3('0x1ef9');}},{'value':_0x5ed0f1('0x1e2b'),'option':function(_0x59591a){const _0x57b944=_0x5ed0f1;return'ORDER\x20BY\x20'+_0x59591a+_0x57b944('0xa96');}}],_0x556fc2=['=','!=','<','<=','>','>=',_0x5ed0f1('0x73f'),_0x5ed0f1('0x19bb'),_0x5ed0f1('0xfba'),_0x5ed0f1('0x1dbe'),_0x5ed0f1('0x1d1c'),_0x5ed0f1('0x827')];return{'getFunctions':_0x474fe5,'getFormats':_0x1fec1d,'getGroupBy':_0x2916a3,'getOrderBy':_0x508fa0,'getConditions':_0x556fc2};}const _0x45a694=_0x1f6f70;_0x203833[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),'toasty',_0x36e6f4('0x19e3'),'report',_0x36e6f4('0x21ef'),'userProfileSection'];function _0x203833(_0x438c4b,_0x5bbdf8,_0x496556,_0x3d45a6,_0x3b86a5,_0x3ef3b0){const _0x1d82f4=_0x36e6f4,_0x55cb26=this;_0x55cb26['report']=_0x3d45a6||{},_0x55cb26[_0x1d82f4('0x17aa')]=_0x3ef3b0&&_0x3ef3b0['count']==0x1?_0x3ef3b0[_0x1d82f4('0x269a')][0x0]:null,_0x55cb26[_0x1d82f4('0x243c')]=_0x3b86a5['parseCrudPermissions'](_0x55cb26[_0x1d82f4('0x17aa')]?_0x55cb26[_0x1d82f4('0x17aa')][_0x1d82f4('0x243c')]:null),_0x55cb26[_0x1d82f4('0x2669')]=_0x438c4b[_0x1d82f4('0x23f')]['tab']||0x0,_0x55cb26[_0x1d82f4('0x68c')]=_0x55affb,_0x55cb26[_0x1d82f4('0x1698')]=_0x4e1525,_0x55cb26['previewReport']=_0x3fac64,_0x55cb26[_0x1d82f4('0x16ec')]=_0x2cda9b,_0x55cb26[_0x1d82f4('0x16e7')]=_0x4ea76f,_0x55cb26[_0x1d82f4('0xd06')]=_0xbe9e51,_0x55cb26['valueReplacer']=_0x55a3e8;function _0x55affb(){const _0x3eacae=_0x1d82f4;_0x438c4b['go'](_0x3eacae('0x1fe2'),{},{'reload':_0x3eacae('0x1fe2')});}function _0x4e1525(){const _0x366671=_0x1d82f4;_0x55cb26[_0x366671('0x2659')][_0x366671('0x1dfe')]=angular['toJson'](_0x55cb26['report']['condition']),_0x496556[_0x366671('0x1ff5')][_0x366671('0x1449')]({'id':_0x55cb26[_0x366671('0x2659')]['id']},_0x2cfb05()[_0x366671('0x1414')](_0x55cb26['report'],'joins'))[_0x366671('0xa44')][_0x366671('0x1166')](function(){const _0x3afb36=_0x366671;_0x5bbdf8[_0x3afb36('0x103b')]({'title':'Report\x20updated!','msg':_0x55cb26[_0x3afb36('0x2659')][_0x3afb36('0x4f0')]?_0x55cb26[_0x3afb36('0x2659')]['name']+_0x3afb36('0xa17'):''});})['catch'](function(_0x4e52b4){const _0x16c4a6=_0x366671;_0x5bbdf8['error']({'title':_0x4e52b4[_0x16c4a6('0x52d')]?_0x16c4a6('0x1e21')+_0x4e52b4[_0x16c4a6('0x52d')]+_0x16c4a6('0x11e1')+_0x4e52b4[_0x16c4a6('0xe1b')]:_0x16c4a6('0x1712'),'msg':_0x4e52b4[_0x16c4a6('0x25f4')]?JSON[_0x16c4a6('0xbac')](_0x4e52b4['data']):_0x4e52b4['toString']()});});}function _0x3fac64(){const _0x413131=_0x1d82f4;_0x55cb26[_0x413131('0x2022')]=[],_0x55cb26[_0x413131('0x269a')]=[],_0x55cb26[_0x413131('0xfc9')]=![],_0x496556[_0x413131('0x1405')][_0x413131('0xd83')]({'fields':'field,alias','nolimit':!![],'CustomReportId':_0x55cb26[_0x413131('0x2659')]['id']})[_0x413131('0xa44')]['then'](function(_0x42750f){const _0x54837b=_0x413131;return _0x55cb26[_0x54837b('0x2022')]=_0x42750f?_0x42750f[_0x54837b('0x269a')]:[],_0x496556[_0x54837b('0x1ff5')]['preview']({'id':_0x55cb26[_0x54837b('0x2659')]['id']})[_0x54837b('0xa44')];})['then'](function(_0x47aebe){const _0x335bca=_0x413131;_0x55cb26[_0x335bca('0x269a')]=_0x47aebe;})[_0x413131('0x1a80')](function(_0x44a698){const _0x2a96f7=_0x413131;console['log'](_0x44a698),_0x55cb26['error']={'title':_0x44a698[_0x2a96f7('0x52d')]?_0x2a96f7('0x1e21')+_0x44a698[_0x2a96f7('0x52d')]+_0x2a96f7('0x11e1')+_0x44a698['statusText']:_0x2a96f7('0xa35'),'msg':_0x44a698[_0x2a96f7('0x25f4')]?_0x44a698[_0x2a96f7('0x25f4')][_0x2a96f7('0x1e70')]:_0x44a698[_0x2a96f7('0x1586')](),'sql':_0x44a698['data']?_0x44a698[_0x2a96f7('0x25f4')][_0x2a96f7('0x5f6')]?_0x44a698[_0x2a96f7('0x25f4')][_0x2a96f7('0x5f6')][_0x2a96f7('0x757')]:_0x2a96f7('0x7e3'):_0x2a96f7('0x7e3')},_0x5bbdf8[_0x2a96f7('0xfc9')](_0x55cb26['error']);});}function _0x55a3e8(_0x128246,_0x31df72){const _0x336374=_0x1d82f4;return _0x24273b()(_0x31df72,'YYYY-MM-DDTHH:mm:ssZ',!![])[_0x336374('0x26ef')]()&&(_0x31df72=_0x24273b()(_0x31df72,'')[_0x336374('0x128a')](_0x336374('0x1084'))),_0x31df72;}function _0x2cda9b(){const _0x418328=_0x1d82f4;return _0x55cb26[_0x418328('0xd5a')]=_0x418328('0x19c0'),_0x496556[_0x418328('0x1ff5')][_0x418328('0x2218')]({'id':_0x55cb26[_0x418328('0x2659')]['id']})[_0x418328('0xa44')]['then'](function(_0x2fb872){const _0x2e09b0=_0x418328;_0x55cb26[_0x2e09b0('0xd5a')]=_0x2fb872['sql'];})['catch'](function(_0x132f16){const _0xcdc0b0=_0x418328;_0x55cb26[_0xcdc0b0('0xd5a')]='',console[_0xcdc0b0('0x455')](_0x132f16),_0x55cb26[_0xcdc0b0('0xfc9')]={'title':_0x132f16[_0xcdc0b0('0x52d')]?'API:'+_0x132f16[_0xcdc0b0('0x52d')]+_0xcdc0b0('0x11e1')+_0x132f16[_0xcdc0b0('0xe1b')]:_0xcdc0b0('0xa35'),'msg':_0x132f16[_0xcdc0b0('0x25f4')]?_0x132f16[_0xcdc0b0('0x25f4')]['message']:_0x132f16['toString'](),'sql':_0x132f16[_0xcdc0b0('0x25f4')]?_0x132f16[_0xcdc0b0('0x25f4')]['parent']?_0x132f16[_0xcdc0b0('0x25f4')][_0xcdc0b0('0x5f6')]['sql']:'NO\x20QUERY':_0xcdc0b0('0x7e3')},_0x5bbdf8[_0xcdc0b0('0xfc9')](_0x55cb26[_0xcdc0b0('0xfc9')]);});}function _0x4ea76f(_0x1e2bb9,_0x17c487){const _0x5a6a42=_0x1d82f4;if(_0xbe9e51(_0x1e2bb9))return _0x2cfb05()[_0x5a6a42('0x2563')](_0x1e2bb9,_0x17c487)[_0x5a6a42('0x45a')](',');return'';}function _0xbe9e51(_0x2d974f){return _0x2cfb05()['isArray'](_0x2d974f);}}const _0xa920cf=_0x203833;_0x18105d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x2659'),_0x36e6f4('0x19e3'),'apiName'];function _0x18105d(_0x54eb2f,_0xf06b6f,_0x33d37f,_0x173eaa,_0x551bce,_0x1f4ecf){const _0x5e56c8=_0x36e6f4,_0x4df255=this;_0x4df255[_0x5e56c8('0x61a')]=[],_0x4df255[_0x5e56c8('0x2659')]=angular[_0x5e56c8('0x225f')](_0x173eaa),_0x4df255[_0x5e56c8('0x209d')]=_0x2b1b78,_0x4df255['closeDialog']=_0x56fa56,_0x5d4d6e();function _0x5d4d6e(){const _0x397b7f=_0x5e56c8;_0x4df255[_0x397b7f('0x2022')]=[],_0x4df255[_0x397b7f('0x269a')]=[],_0x4df255[_0x397b7f('0xfc9')]=![];const _0x3b8187={'fields':_0x397b7f('0x22e5'),'nolimit':!![]};_0x3b8187[_0x1f4ecf===_0x397b7f('0x1ff5')?_0x397b7f('0x251f'):'DefaultReportId']=_0x4df255[_0x397b7f('0x2659')]['id'],_0x4df255['promise']=_0x551bce[_0x397b7f('0x1405')][_0x397b7f('0xd83')](_0x3b8187)[_0x397b7f('0xa44')][_0x397b7f('0x1166')](function(_0x119832){const _0x2cb119=_0x397b7f;return _0x4df255[_0x2cb119('0x2022')]=_0x119832?_0x119832[_0x2cb119('0x269a')]:[],_0x551bce[_0x1f4ecf][_0x2cb119('0x1b37')]({'id':_0x4df255[_0x2cb119('0x2659')]['id']})[_0x2cb119('0xa44')];})[_0x397b7f('0x1166')](function(_0x32ebaa){const _0x21688f=_0x397b7f;_0x4df255[_0x21688f('0x269a')]=_0x32ebaa;})[_0x397b7f('0x1a80')](function(_0x1f9601){const _0x42b489=_0x397b7f;console[_0x42b489('0x455')](_0x1f9601),_0x4df255['error']={'title':_0x1f9601[_0x42b489('0x52d')]?_0x42b489('0x1e21')+_0x1f9601[_0x42b489('0x52d')]+_0x42b489('0x11e1')+_0x1f9601[_0x42b489('0xe1b')]:_0x42b489('0xa35'),'msg':_0x1f9601['data']?_0x1f9601['data'][_0x42b489('0x1e70')]:_0x1f9601[_0x42b489('0x1586')](),'sql':_0x1f9601[_0x42b489('0x25f4')]?_0x1f9601[_0x42b489('0x25f4')][_0x42b489('0x5f6')]?_0x1f9601['data'][_0x42b489('0x5f6')][_0x42b489('0x757')]:_0x42b489('0x7e3'):'NO\x20QUERY'},_0x33d37f[_0x42b489('0xfc9')](_0x4df255['error']);});}function _0x2b1b78(_0x1ae1d5,_0x58fa7c){const _0x3a48f6=_0x5e56c8;return _0x24273b()(_0x58fa7c,_0x3a48f6('0x470'),!![])[_0x3a48f6('0x26ef')]()&&(_0x58fa7c=_0x24273b()(_0x58fa7c,'')[_0x3a48f6('0x128a')](_0x3a48f6('0x1084'))),_0x58fa7c;}function _0x56fa56(){_0xf06b6f['hide']();}}const _0x5b2d39=_0x18105d,_0x1170d3=_0x2734b2['p']+_0x36e6f4('0x1c29'),_0x575ccb=_0x2734b2['p']+'src/js/modules/main/apps/analytics/views/reports/preview/dialog.html/dialog.html',_0x781546=_0x2734b2['p']+_0x36e6f4('0xe40'),_0x5e20fa=_0x2734b2['p']+'src/js/modules/main/apps/analytics/views/reports/create/dialog.html/dialog.html';_0x173417[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x8da'),_0x36e6f4('0x1c90'),'$mdDialog',_0x36e6f4('0x7b9'),_0x36e6f4('0x1566'),_0x36e6f4('0x586'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x14c7'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x173417(_0x3f2c22,_0x3057ef,_0x13cb9d,_0x48fa17,_0x271601,_0x2834fb,_0x3a0b88,_0x5043b7,_0x37a1df,_0x2d6d95,_0x4fce33,_0x1a2463,_0x5e21d1){const _0x13c539=_0x36e6f4,_0x3cf0e7=this;_0x3cf0e7[_0x13c539('0x98')]=_0x5e21d1['getCurrentUser'](),_0x3cf0e7[_0x13c539('0x352')]={'count':0x0,'rows':[]},_0x3cf0e7['userProfile']=_0x5043b7,_0x3cf0e7[_0x13c539('0x17aa')]=_0x37a1df&&_0x37a1df[_0x13c539('0x240f')]==0x1?_0x37a1df[_0x13c539('0x269a')][0x0]:null,_0x3cf0e7[_0x13c539('0x243c')]=_0x5e21d1[_0x13c539('0xd87')](_0x3cf0e7[_0x13c539('0x17aa')]?_0x3cf0e7['userProfileSection'][_0x13c539('0x243c')]:null),_0x3cf0e7[_0x13c539('0x269')]=[],_0x3cf0e7[_0x13c539('0x2218')]={'fields':_0x13c539('0x67b'),'limit':0xa,'page':0x1,'sort':_0x13c539('0x14dc')},_0x3cf0e7[_0x13c539('0x2677')]=null,_0x3cf0e7[_0x13c539('0x1967')]='',_0x3cf0e7[_0x13c539('0x23f0')]=!![],_0x3cf0e7['editstate']=_0x166803,_0x3cf0e7[_0x13c539('0x700')]=_0x3d98ae,_0x3cf0e7[_0x13c539('0xff2')]=_0x1c403c,_0x3cf0e7[_0x13c539('0x12f0')]=_0xed3350,_0x3cf0e7[_0x13c539('0x2591')]=_0x2fc95f,_0x3cf0e7[_0x13c539('0x8d8')]=_0x213125,_0x3cf0e7[_0x13c539('0x103b')]=_0x4e37e8,_0x3cf0e7['getReports']=_0x4ab920,_0x3cf0e7['createOrEditReport']=_0x553901,_0x3cf0e7[_0x13c539('0x875')]=_0x259b17,_0x3cf0e7[_0x13c539('0x21b0')]=_0x1eb319,_0x3cf0e7['exportSelectedReports']=_0x2d95c6,_0x3cf0e7[_0x13c539('0x2c2')]=_0x545e18,_0x3cf0e7['deselectReports']=_0x25c3c1,_0x3cf0e7[_0x13c539('0x5b5')]=_0x24d8d5,_0x3cf0e7[_0x13c539('0x22b')]=_0x4fce33[_0x13c539('0x269a')][0x0]?angular[_0x13c539('0x2524')](_0x4fce33[_0x13c539('0x269a')][0x0][_0x13c539('0x1b5f')]):[],_0x3cf0e7[_0x13c539('0x2775')]=_0x4fce33[_0x13c539('0x269a')][0x1]?angular[_0x13c539('0x2524')](_0x4fce33['rows'][0x1][_0x13c539('0x1b5f')]):[],_0x3cf0e7['treeDefaultConfig']=_0x120e76(![]),_0x3cf0e7[_0x13c539('0xbcf')]=_0x120e76(!![]),_0x3cf0e7['treeDefaultEvents']=_0x36e6a6(![]),_0x3cf0e7[_0x13c539('0x6e0')]=_0x36e6a6(!![]);function _0x166803(_0x2345b8){const _0x226174=_0x13c539;_0x271601['go'](_0x226174('0xb88'),{'id':_0x2345b8['id'],'crudPermissions':_0x3cf0e7[_0x226174('0x243c')]});}function _0x3d98ae(_0x19f75a,_0x51fa72){const _0xfc13f9=_0x13c539;_0x48fa17[_0xfc13f9('0x1f80')]({'controller':_0xfc13f9('0x1b9'),'controllerAs':'vm','templateUrl':_0x1170d3,'parent':angular['element'](_0x13cb9d[_0xfc13f9('0x8d2')]),'targetEvent':_0x51fa72,'clickOutsideToClose':!![],'locals':{'report':_0x19f75a,'apiName':_0x3cf0e7['apiName'],'treeCustomData':_0x3cf0e7[_0xfc13f9('0x1a4b')]['jstree'](!![])[_0xfc13f9('0x4fa')]('#')}})[_0xfc13f9('0x1951')](function(){});}function _0x1c403c(_0x4d559c,_0x1d815c){const _0x3073b1=_0x13c539;_0x48fa17[_0x3073b1('0x1f80')]({'controller':_0x3073b1('0x2bd'),'controllerAs':'vm','templateUrl':_0x575ccb,'parent':angular[_0x3073b1('0x1194')](_0x13cb9d[_0x3073b1('0x8d2')]),'targetEvent':_0x1d815c,'clickOutsideToClose':!![],'locals':{'report':_0x4d559c,'apiName':_0x3cf0e7[_0x3073b1('0x2677')]}});}function _0xed3350(_0x21afb6,_0x9ab1b6){const _0x225c67=_0x13c539;_0x48fa17['show']({'controller':_0x225c67('0xf90'),'controllerAs':'vm','templateUrl':_0x781546,'parent':angular[_0x225c67('0x1194')](_0x13cb9d[_0x225c67('0x8d2')]),'targetEvent':_0x9ab1b6,'clickOutsideToClose':!![],'locals':{'report':_0x21afb6,'apiName':_0x3cf0e7[_0x225c67('0x2677')],'currentPath':_0x3cf0e7[_0x225c67('0x1967')]}});}function _0x2fc95f(_0x44ee74){const _0x200a8f=_0x13c539;let _0x56dca0;_0x2d6d95['analyticMetric'][_0x200a8f('0xd83')]({'fields':_0x200a8f('0xfa6'),'nolimit':!![]})[_0x200a8f('0xa44')][_0x200a8f('0x1166')](function(_0x38eb64){const _0x3d7bdd=_0x200a8f;_0x56dca0=_0x2cfb05()['keyBy'](_0x38eb64[_0x3d7bdd('0x269a')],'id');const _0x206690={'fields':_0x3d7bdd('0x166e'),'nolimit':!![]};return _0x206690[_0x3cf0e7[_0x3d7bdd('0x2677')]===_0x3d7bdd('0x1ff5')?_0x3d7bdd('0x251f'):_0x3d7bdd('0x1944')]=_0x44ee74['id'],_0x2d6d95[_0x3d7bdd('0x1405')][_0x3d7bdd('0xd83')](_0x206690)[_0x3d7bdd('0xa44')];})[_0x200a8f('0x1166')](function(_0x49cde3){const _0x5b6846=_0x200a8f;for(let _0x1ed89a=0x0;_0x1ed89a<_0x49cde3[_0x5b6846('0x269a')]['length'];_0x1ed89a+=0x1){_0x49cde3[_0x5b6846('0x269a')][_0x1ed89a][_0x5b6846('0x140c')]&&(_0x49cde3['rows'][_0x1ed89a][_0x5b6846('0x22f3')]=_0x56dca0[_0x49cde3[_0x5b6846('0x269a')][_0x1ed89a][_0x5b6846('0x140c')]][_0x5b6846('0x64c')],_0x49cde3['rows'][_0x1ed89a][_0x5b6846('0x2853')]=!![]),delete _0x49cde3[_0x5b6846('0x269a')][_0x1ed89a][_0x5b6846('0x140c')];}const _0x16031b=_0x2834fb['document'][_0x5b6846('0xdd')]('a');_0x16031b[_0x5b6846('0x14f9')]=_0x5b6846('0x3a4')+_0x2834fb[_0x5b6846('0x202f')](angular[_0x5b6846('0xd2')]({'name':_0x44ee74['name'],'description':_0x44ee74['description'],'table':_0x44ee74[_0x5b6846('0x916')],'conditions':_0x44ee74[_0x5b6846('0x1dfe')],'joins':_0x44ee74[_0x5b6846('0xc91')],'fields':_0x49cde3[_0x5b6846('0x269a')]})),_0x16031b[_0x5b6846('0x2ad')]=_0x44ee74[_0x5b6846('0x4f0')]+_0x5b6846('0x19c4'),_0x16031b['target']=_0x5b6846('0x127c'),_0x16031b[_0x5b6846('0x3b4')](),_0x1a2463[_0x5b6846('0x103b')]({'title':_0x5b6846('0x28e'),'msg':_0x44ee74[_0x5b6846('0x4f0')]?_0x44ee74[_0x5b6846('0x4f0')]+_0x5b6846('0x13ec'):''});})['catch'](function(_0x1c1ebe){const _0x214432=_0x200a8f;_0x1a2463['error']({'title':_0x1c1ebe[_0x214432('0x52d')]?'API:'+_0x1c1ebe[_0x214432('0x52d')]+_0x214432('0x11e1')+_0x1c1ebe[_0x214432('0xe1b')]:_0x214432('0x13ad'),'msg':_0x1c1ebe[_0x214432('0x25f4')]?JSON[_0x214432('0xbac')](_0x1c1ebe[_0x214432('0x25f4')]):_0x1c1ebe[_0x214432('0x1586')]()});});}function _0x213125(_0x27898e,_0x5d8bf3){const _0x23fdb1=_0x13c539,_0x463920=_0x48fa17[_0x23fdb1('0x1d26')]()[_0x23fdb1('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20report?')[_0x23fdb1('0xf3c')](_0x23fdb1('0x12b5')+_0x27898e[_0x23fdb1('0x4f0')]+_0x23fdb1('0xace')+_0x23fdb1('0x3f3'))[_0x23fdb1('0x8e8')](_0x23fdb1('0x13b3'))['targetEvent'](_0x5d8bf3)['ok']('OK')[_0x23fdb1('0x3f')](_0x23fdb1('0x2d3'));_0x48fa17[_0x23fdb1('0x1f80')](_0x463920)[_0x23fdb1('0x1166')](function(){_0x1eb319(_0x27898e);},function(){const _0x1f664b=_0x23fdb1;console[_0x1f664b('0x455')](_0x1f664b('0x2d3'));});}let _0x47b531=!![],_0x3d0c3a=0x1;_0x3f2c22[_0x13c539('0xe83')](_0x13c539('0x12d8'),function(_0x457dea,_0x232bc9){const _0x5bccec=_0x13c539;_0x47b531?_0x3057ef(function(){_0x47b531=![];}):(!_0x232bc9&&(_0x3d0c3a=_0x3cf0e7['query'][_0x5bccec('0x1a43')]),_0x457dea!==_0x232bc9&&(_0x3cf0e7['query'][_0x5bccec('0x1a43')]=0x1),!_0x457dea&&(_0x3cf0e7[_0x5bccec('0x2218')][_0x5bccec('0x1a43')]=_0x3d0c3a),_0x3cf0e7[_0x5bccec('0x20aa')]());}),_0x3f2c22[_0x13c539('0xe83')](_0x13c539('0x2465'),function(_0x5775dc){const _0x54e403=_0x13c539;_0x3cf0e7[_0x54e403('0x18c7')]&&_0x3cf0e7['treeDefaultInstance']['jstree'](!![])['search'](_0x5775dc),_0x3cf0e7['treeCustomInstance']&&_0x3cf0e7[_0x54e403('0x1a4b')][_0x54e403('0x14aa')](!![])[_0x54e403('0xe07')](_0x5775dc);});function _0x4e37e8(_0x8bc686){const _0x19f379=_0x13c539;_0x3cf0e7[_0x19f379('0x352')]=_0x8bc686||{'count':0x0,'rows':[]};}function _0x4ab920(){const _0x28185d=_0x13c539;_0x3cf0e7[_0x28185d('0x2218')]['offset']=(_0x3cf0e7[_0x28185d('0x2218')]['page']-0x1)*_0x3cf0e7[_0x28185d('0x2218')][_0x28185d('0x163f')];if(_0x3cf0e7[_0x28185d('0x2677')]){if(_0x3cf0e7[_0x28185d('0x98')][_0x28185d('0x1e75')]==='admin'||_0x3cf0e7[_0x28185d('0x17aa')][_0x28185d('0x1a2b')])_0x3cf0e7['promise']=_0x2d6d95[_0x3cf0e7[_0x28185d('0x2677')]][_0x28185d('0xd83')](_0x3cf0e7[_0x28185d('0x2218')],_0x4e37e8)['$promise'];else{let _0x52b2d5=[];_0x3cf0e7[_0x28185d('0x1f48')]=_0x2d6d95[_0x3cf0e7['apiName']][_0x28185d('0xd83')](_0x3cf0e7['query'])['$promise'][_0x28185d('0x1166')](function(_0x14da3f){const _0x6a5586=_0x28185d;return _0x52b2d5=_0x14da3f&&_0x14da3f[_0x6a5586('0x269a')]?_0x14da3f[_0x6a5586('0x269a')]:[],_0x52b2d5[_0x6a5586('0x264b')]>0x0?_0x2d6d95[_0x6a5586('0x4b5')][_0x6a5586('0xd83')]({'sectionId':_0x3cf0e7[_0x6a5586('0x17aa')]['id'],'type':_0x3cf0e7[_0x6a5586('0x2677')]===_0x6a5586('0x17c2')?_0x6a5586('0x2243'):_0x6a5586('0x1cc5')})[_0x6a5586('0xa44')][_0x6a5586('0x1166')](function(_0x4b31d2){const _0x1a33cc=_0x6a5586,_0x26a4d8=_0x4b31d2&&_0x4b31d2[_0x1a33cc('0x269a')]?_0x4b31d2[_0x1a33cc('0x269a')]:[];if(_0x26a4d8[_0x1a33cc('0x264b')]>0x0){const _0x1c4aee=[];return _0x52b2d5[_0x1a33cc('0x2782')](function(_0x575d05){const _0x3d22b5=_0x1a33cc,_0x236801=_0x2cfb05()[_0x3d22b5('0xc38')](_0x26a4d8,[_0x3d22b5('0x24e8'),_0x575d05['id']]);if(_0x236801)_0x1c4aee[_0x3d22b5('0x1514')](_0x575d05);}),_0x4e37e8({'count':_0x1c4aee['length'],'rows':_0x1c4aee});}else return _0x4e37e8(null);}):_0x4e37e8(null);});}}}function _0x553901(_0x189e26,_0x643d4d){const _0x3cc145=_0x13c539;_0x48fa17[_0x3cc145('0x1f80')]({'controller':_0x3cc145('0x1b7c'),'controllerAs':'vm','templateUrl':_0x5e20fa,'parent':angular[_0x3cc145('0x1194')](_0x13cb9d[_0x3cc145('0x8d2')]),'targetEvent':_0x189e26,'clickOutsideToClose':!![],'locals':{'report':_0x643d4d,'reports':_0x3cf0e7[_0x3cc145('0x352')][_0x3cc145('0x269a')],'apiName':_0x3cf0e7['apiName'],'currentNode':_0x3cf0e7[_0x3cc145('0xad5')],'setting':null,'crudPermissions':_0x3cf0e7[_0x3cc145('0x243c')]}});}function _0x259b17(_0x1543ca){const _0xfd8806=_0x13c539;if(_0x1543ca[_0xfd8806('0x6bd')][_0xfd8806('0x1345')]===_0xfd8806('0x1254')){const _0x4545a1=new FileReader();_0x4545a1[_0xfd8806('0x15d4')]=function(_0x2a07a9){const _0x41cf03=_0xfd8806;console['log'](_0x2a07a9[_0x41cf03('0x21cc')][_0x41cf03('0x15b5')]);try{let _0x248770=atob(_0x2a07a9[_0x41cf03('0x21cc')]['result'][_0x41cf03('0x25c8')](',')[0x1]);_0x248770=angular['fromJson'](_0x248770),_0x2d6d95['analyticCustomReport']['save']({'name':_0x248770[_0x41cf03('0x4f0')],'description':_0x248770[_0x41cf03('0x101c')],'table':_0x248770[_0x41cf03('0x916')],'conditions':_0x248770[_0x41cf03('0x1dfe')],'joins':_0x248770['joins'],'parent':_0x3cf0e7[_0x41cf03('0xad5')]['id']})[_0x41cf03('0xa44')]['then'](function(_0x34b398){const _0x1811dd=_0x41cf03;_0x3cf0e7[_0x1811dd('0x352')][_0x1811dd('0x269a')]['unshift'](_0x34b398),_0x1a2463[_0x1811dd('0x103b')]({'title':_0x1811dd('0x17b6'),'msg':_0x34b398['name']?_0x34b398['name']+_0x1811dd('0x7d'):''});const _0x24be39=_0x2cfb05()[_0x1811dd('0x2563')](_0x248770[_0x1811dd('0xfe2')],function(_0x2d7700){const _0x1ba87d=_0x1811dd;return _0x2cfb05()[_0x1ba87d('0x25a1')]({},_0x2d7700,{'CustomReportId':_0x34b398['id']});});return _0x2d6d95['analyticFieldReport'][_0x1811dd('0x206')](_0x24be39)[_0x1811dd('0xa44')];})[_0x41cf03('0x1166')](function(){const _0x9ea381=_0x41cf03;_0x1a2463[_0x9ea381('0x103b')]({'title':_0x9ea381('0x6c'),'msg':_0x9ea381('0x588')});})[_0x41cf03('0x1a80')](function(_0x537704){const _0x3ad5ca=_0x41cf03;_0x1a2463[_0x3ad5ca('0xfc9')]({'title':_0x537704['status']?_0x3ad5ca('0x1e21')+_0x537704[_0x3ad5ca('0x52d')]+_0x3ad5ca('0x11e1')+_0x537704[_0x3ad5ca('0xe1b')]:_0x3ad5ca('0x200d'),'msg':_0x537704[_0x3ad5ca('0x25f4')]?JSON[_0x3ad5ca('0xbac')](_0x537704[_0x3ad5ca('0x25f4')]):_0x537704['toString']()});});}catch(_0x2809de){console[_0x41cf03('0xfc9')](_0x2809de),_0x1a2463['error']({'title':'Decode\x20File\x20Error','msg':_0x2809de[_0x41cf03('0x1586')]()});}},_0x4545a1['readAsDataURL'](_0x1543ca[_0xfd8806('0x6bd')]);}else _0x1a2463['error']({'title':_0xfd8806('0x7de'),'msg':'Please\x20use\x20only\x20json\x20files'});}function _0x1eb319(_0x4d01cc){const _0x24b7d9=_0x13c539;_0x3cf0e7[_0x24b7d9('0x2677')]&&_0x2d6d95[_0x3cf0e7[_0x24b7d9('0x2677')]][_0x24b7d9('0x906')]({'id':_0x4d01cc['id']})[_0x24b7d9('0xa44')][_0x24b7d9('0x1166')](function(){const _0x569fe3=_0x24b7d9;_0x2cfb05()[_0x569fe3('0x127f')](_0x3cf0e7[_0x569fe3('0x352')][_0x569fe3('0x269a')],{'id':_0x4d01cc['id']}),_0x3cf0e7[_0x569fe3('0x352')][_0x569fe3('0x240f')]-=0x1,!_0x3cf0e7['reports'][_0x569fe3('0x269a')][_0x569fe3('0x264b')]&&_0x3cf0e7[_0x569fe3('0x20aa')](),_0x1a2463[_0x569fe3('0x103b')]({'title':_0x569fe3('0x21fa'),'msg':_0x4d01cc[_0x569fe3('0x4f0')]?_0x4d01cc['name']+_0x569fe3('0x7cd'):''});})[_0x24b7d9('0x1a80')](function(_0x150971){const _0x3d44e4=_0x24b7d9;if(_0x150971[_0x3d44e4('0x25f4')]&&_0x150971[_0x3d44e4('0x25f4')][_0x3d44e4('0x61a')]&&_0x150971[_0x3d44e4('0x25f4')]['errors'][_0x3d44e4('0x264b')]){_0x3cf0e7[_0x3d44e4('0x61a')]=_0x150971[_0x3d44e4('0x25f4')][_0x3d44e4('0x61a')]||[{'message':_0x150971['toString'](),'type':_0x3d44e4('0x18b6')}];for(let _0x2f5174=0x0;_0x2f5174<_0x150971['data'][_0x3d44e4('0x61a')][_0x3d44e4('0x264b')];_0x2f5174++){_0x1a2463[_0x3d44e4('0xfc9')]({'title':_0x150971[_0x3d44e4('0x25f4')]['errors'][_0x2f5174]['type'],'msg':_0x150971[_0x3d44e4('0x25f4')][_0x3d44e4('0x61a')][_0x2f5174][_0x3d44e4('0x1e70')]});}}else _0x1a2463['error']({'title':_0x150971[_0x3d44e4('0x52d')]?_0x3d44e4('0x1e21')+_0x150971['status']+_0x3d44e4('0x11e1')+_0x150971[_0x3d44e4('0xe1b')]:_0x3d44e4('0x18b6'),'msg':_0x150971['data']?JSON[_0x3d44e4('0xbac')](_0x150971[_0x3d44e4('0x25f4')][_0x3d44e4('0x1e70')]):_0x150971[_0x3d44e4('0x1e70')]||_0x150971[_0x3d44e4('0x1586')]()});});}function _0x2d95c6(){const _0x529f6b=_0x13c539,_0x37cf5e=angular[_0x529f6b('0x225f')](_0x3cf0e7[_0x529f6b('0x269')]);return _0x3cf0e7[_0x529f6b('0x269')]=[],_0x37cf5e;}function _0x545e18(_0x47750e){const _0x1c479f=_0x13c539,_0x270fe8=_0x48fa17[_0x1c479f('0x1d26')]()[_0x1c479f('0xcdc')](_0x1c479f('0x1e99'))[_0x1c479f('0xf3c')](_0x1c479f('0x12b5')+_0x3cf0e7[_0x1c479f('0x269')]['length']+'\x20selected'+_0x1c479f('0x3f3'))['ariaLabel'](_0x1c479f('0x8eb'))['targetEvent'](_0x47750e)['ok']('OK')['cancel'](_0x1c479f('0x2d3'));_0x48fa17[_0x1c479f('0x1f80')](_0x270fe8)[_0x1c479f('0x1166')](function(){const _0xa45303=_0x1c479f;_0x3cf0e7[_0xa45303('0x269')][_0xa45303('0x2782')](function(_0xf8d3f2){_0x1eb319(_0xf8d3f2);}),_0x3cf0e7[_0xa45303('0x269')]=[];});}function _0x25c3c1(){const _0x1c7107=_0x13c539;_0x3cf0e7[_0x1c7107('0x269')]=[];}function _0x24d8d5(){const _0x21cdfb=_0x13c539;_0x3cf0e7[_0x21cdfb('0x269')]=_0x3cf0e7['reports'][_0x21cdfb('0x269a')];}function _0x1842b5(_0x1741ea,_0x644b52){const _0x4c80d8=_0x13c539;_0x3cf0e7['treeDefaultInstance']['jstree'](!![])[_0x4c80d8('0x1314')](),_0x3cf0e7[_0x4c80d8('0x18c7')]['jstree'](!![])['close_all'](),_0x3cf0e7[_0x4c80d8('0xad5')]=_0x644b52[_0x4c80d8('0x22d1')],_0x3cf0e7[_0x4c80d8('0xad5')]['custom']=!![],_0x3cf0e7[_0x4c80d8('0x1967')]=_0x3cf0e7[_0x4c80d8('0x1a4b')][_0x4c80d8('0x14aa')](!![])['get_path'](_0x3cf0e7[_0x4c80d8('0xad5')])[_0x4c80d8('0x45a')]('/\x20'),_0x3cf0e7[_0x4c80d8('0x2677')]=_0x4c80d8('0x1ff5'),_0x3cf0e7[_0x4c80d8('0x2218')][_0x4c80d8('0x5f6')]=_0x644b52[_0x4c80d8('0x22d1')]['id'],_0x4ab920();}function _0x4d9d28(_0xbcfb52,_0x9029f3){const _0x1f858f=_0x13c539;_0x3cf0e7['treeCustomInstance']['jstree'](!![])[_0x1f858f('0x1314')](),_0x3cf0e7[_0x1f858f('0x1a4b')][_0x1f858f('0x14aa')](!![])['close_all'](),_0x3cf0e7[_0x1f858f('0xad5')]=_0x9029f3[_0x1f858f('0x22d1')],_0x3cf0e7[_0x1f858f('0xad5')][_0x1f858f('0x2853')]=![],_0x3cf0e7['currentPath']=_0x3cf0e7[_0x1f858f('0x18c7')][_0x1f858f('0x14aa')](!![])['get_path'](_0x3cf0e7[_0x1f858f('0xad5')])[_0x1f858f('0x45a')]('/\x20'),_0x3cf0e7['apiName']=_0x1f858f('0x17c2'),_0x3cf0e7['query'][_0x1f858f('0x5f6')]=_0x9029f3['node']['id'],_0x4ab920();}function _0x1df11a(_0x3c0d27,_0x4bda64){const _0x270639=_0x13c539,_0x1e4122=angular[_0x270639('0xd2')](_0x3cf0e7['treeCustomInstance'][_0x270639('0x14aa')](!![])['get_json']('#'));_0x2d6d95[_0x270639('0x7eb')][_0x270639('0x1449')]({'id':0x2,'tree':_0x1e4122})[_0x270639('0xa44')]['then'](function(){const _0xcb90a2=_0x270639;_0x4fce33[_0xcb90a2('0x269a')][0x1]&&(_0x4fce33[_0xcb90a2('0x269a')][0x1][_0xcb90a2('0x1b5f')]=_0x1e4122),_0x1a2463['success']({'title':_0xcb90a2('0xb68'),'msg':_0x4bda64[_0xcb90a2('0x22d1')][_0xcb90a2('0x1640')]?_0x4bda64[_0xcb90a2('0x22d1')]['text']+_0xcb90a2('0xa17'):_0xcb90a2('0x985')});})['catch'](function(_0x16079f){const _0x56525b=_0x270639;_0x1a2463['error']({'title':_0x16079f['status']?'API:'+_0x16079f[_0x56525b('0x52d')]+_0x56525b('0x11e1')+_0x16079f[_0x56525b('0xe1b')]:'SYSTEM:UPDATEanalyticTreeReport','msg':_0x16079f[_0x56525b('0x25f4')]?JSON[_0x56525b('0xbac')](_0x16079f[_0x56525b('0x25f4')]):_0x16079f['toString']()});});}function _0x120e76(_0x417e8a){const _0x759a05=_0x13c539;return{'core':{'multiple':![],'animation':!![],'error':function(_0x365fda){const _0x3d8110=a0_0x3f2c;console['error'](_0x3d8110('0x1edc')+angular['toJson'](_0x365fda));},'check_callback':!![],'worker':!![]},'version':0x1,'plugins':_0x417e8a?[_0x759a05('0x77c'),'dnd',_0x759a05('0xe07'),_0x759a05('0x63f'),_0x759a05('0x164c')]:[_0x759a05('0xe07'),'state','wholerow'],'contextmenu':{'items':function(_0x32f75c){const _0x36f4a6=_0x759a05,_0x2a45d3={};return _0x3cf0e7[_0x36f4a6('0x243c')][_0x36f4a6('0x1684')]&&_0x2cfb05()[_0x36f4a6('0xa12')](_0x2a45d3,{'create':{'label':_0x3a0b88[_0x36f4a6('0x25cc')](_0x36f4a6('0xba5')),'action':function(){const _0x451f59=_0x36f4a6;_0x32f75c=_0x3cf0e7[_0x451f59('0x1a4b')][_0x451f59('0x14aa')](!![])[_0x451f59('0xdf2')](_0x32f75c),_0x3cf0e7[_0x451f59('0x1a4b')][_0x451f59('0x14aa')](!![])[_0x451f59('0x171f')](_0x32f75c);}},'rename':{'_disabled':_0x32f75c['parent']==='#','label':_0x3a0b88[_0x36f4a6('0x25cc')](_0x36f4a6('0x70a')),'action':function(){const _0x116fb5=_0x36f4a6;_0x3cf0e7[_0x116fb5('0x1a4b')][_0x116fb5('0x14aa')](!![])[_0x116fb5('0x171f')](_0x32f75c);}}}),_0x3cf0e7['crudPermissions'][_0x36f4a6('0x66')]&&_0x2cfb05()[_0x36f4a6('0xa12')](_0x2a45d3,{'remove':{'_disabled':_0x32f75c['parent']==='#','label':_0x3a0b88['instant']('ANALYTICS.REMOVE'),'action':function(){const _0x4fa6e2=_0x36f4a6,_0x20a48a=_0x48fa17[_0x4fa6e2('0x1d26')]()['title'](_0x4fa6e2('0x4c2'))['htmlContent'](_0x4fa6e2('0x12b5')+(_0x32f75c[_0x4fa6e2('0x1640')]?_0x32f75c[_0x4fa6e2('0x1640')]:_0x4fa6e2('0x1973'))+_0x4fa6e2('0xace')+'\x20and\x20its\x20subnode\x20will\x20be\x20deleted.')[_0x4fa6e2('0x8e8')](_0x4fa6e2('0x18f1'))['ok']('OK')['cancel'](_0x4fa6e2('0x2d3'));_0x48fa17[_0x4fa6e2('0x1f80')](_0x20a48a)['then'](function(){const _0x1faa11=_0x4fa6e2;let _0x3a41af=_0x3cf0e7['treeCustomInstance']['jstree'](!![])[_0x1faa11('0x23bc')](_0x32f75c);_0x3a41af=_0x3cf0e7[_0x1faa11('0x1a4b')][_0x1faa11('0x14aa')](!![])[_0x1faa11('0x10de')](_0x3a41af),_0x3cf0e7[_0x1faa11('0x1a4b')][_0x1faa11('0x14aa')](!![])[_0x1faa11('0x9b7')](_0x32f75c),_0x5d6cc2([_0x32f75c['id']][_0x1faa11('0x1c6a')](_0x32f75c[_0x1faa11('0x235d')]||[])),_0x3cf0e7[_0x1faa11('0x1a4b')][_0x1faa11('0x14aa')](!![])['select_node'](_0x3a41af);});}}}),_0x2a45d3;}}};}function _0x5d6cc2(_0x1bc88b){const _0x56d153=_0x13c539;return _0x2d6d95[_0x56d153('0x1ff5')][_0x56d153('0xd83')]({'parent':_0x1bc88b[_0x56d153('0x45a')](','),'fields':_0x56d153('0x1776')})[_0x56d153('0xa44')][_0x56d153('0x1166')](function(_0x471b56){const _0x17d79e=_0x56d153;_0x471b56&&_0x471b56[_0x17d79e('0x269a')]&&_0x471b56[_0x17d79e('0x269a')]['forEach'](function(_0x3e30dc){_0x1eb319(_0x3e30dc);});})[_0x56d153('0x1a80')](function(_0xd65079){const _0x157415=_0x56d153;_0x1a2463['error']({'title':_0xd65079[_0x157415('0x52d')]?_0x157415('0x1e21')+_0xd65079[_0x157415('0x52d')]+_0x157415('0x11e1')+_0xd65079[_0x157415('0xe1b')]:'SYSTEM:DELETEreportsByParents','msg':_0xd65079[_0x157415('0x25f4')]?JSON[_0x157415('0xbac')](_0xd65079[_0x157415('0x25f4')]):_0xd65079[_0x157415('0x1586')]()});});}function _0x36e6a6(_0x36106b){return _0x36106b?{'create_node':_0x1df11a,'rename_node':_0x1df11a,'move_node':_0x1df11a,'delete_node':_0x1df11a,'select_node':_0x1842b5}:{'select_node':_0x4d9d28};}}const _0xf7e78f=_0x173417,_0x5660c3=_0x2734b2['p']+_0x36e6f4('0x112b');_0x4f2633[_0x36e6f4('0x1294')]=['$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x2659'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2677'),'$document','currentPath'];function _0x4f2633(_0x39bb62,_0x18730a,_0x3309aa,_0x408c4e,_0x11c18a,_0x20c9b8,_0x21ff09,_0x51c05c){const _0x4dcdee=_0x36e6f4,_0x36212a=this;_0x36212a[_0x4dcdee('0x61a')]=[],_0x36212a['report']=angular['copy'](_0x408c4e),_0x36212a['export']={},_0x36212a[_0x4dcdee('0x8a9')]=_0x598cf5,_0x36212a['closeDialog']=_0x46ffb5,_0x36212a[_0x4dcdee('0x25e5')]=_0x232891,_0x232891();function _0x232891(){const _0x4059ef=_0x4dcdee;_0x36212a[_0x4059ef('0x1b8')]={'id':_0x36212a['report']['id'],'name':_0x36212a[_0x4059ef('0x2659')][_0x4059ef('0x4f0')],'startDate':new Date(_0x24273b()()['startOf'](_0x4059ef('0x16a'))),'endDate':new Date(_0x24273b()()[_0x4059ef('0x2589')](_0x4059ef('0x16a'))),'output':_0x4059ef('0x5ba'),'fullPath':_0x51c05c?_0x51c05c+'/'+_0x36212a[_0x4059ef('0x2659')][_0x4059ef('0x4f0')]:_0x36212a[_0x4059ef('0x2659')][_0x4059ef('0x4f0')]};}function _0x598cf5(_0x3442ac){const _0x469e6a=_0x4dcdee;_0x36212a[_0x469e6a('0x61a')]=[],_0x36212a[_0x469e6a('0x16d')]=_0x2cfb05()['assign']({},_0x36212a[_0x469e6a('0x1b8')],{'startDate':_0x24273b()(_0x36212a['export']['startDate'])[_0x469e6a('0x128a')]('YYYY-MM-DD\x20HH:mm:ss'),'endDate':_0x24273b()(_0x36212a['export'][_0x469e6a('0x15')])[_0x469e6a('0x128a')](_0x469e6a('0x1084'))}),_0x11c18a[_0x20c9b8][_0x469e6a('0xca')](_0x36212a['exportDate'])['$promise'][_0x469e6a('0x1166')](function(_0x208248){const _0x3ced2f=_0x469e6a;_0x36212a[_0x3ced2f('0x1b8')][_0x3ced2f('0x1eed')]===_0x3ced2f('0x2221')?_0x18730a[_0x3ced2f('0x1f80')]({'controller':'WebReportDialogController','controllerAs':'vm','templateUrl':_0x5660c3,'parent':angular['element'](_0x21ff09[_0x3ced2f('0x8d2')]),'targetEvent':_0x3442ac,'skipHide':!![],'locals':{'apiName':_0x20c9b8,'exportDate':_0x36212a[_0x3ced2f('0x16d')],'results':_0x208248},'resolve':{'columns':[_0x3ced2f('0x1fbc'),function(_0x18dc67){const _0x5022b7=_0x3ced2f,_0x470152={'fields':_0x5022b7('0x22e5'),'nolimit':!![]};return _0x470152[_0x20c9b8===_0x5022b7('0x1ff5')?_0x5022b7('0x251f'):_0x5022b7('0x1944')]=_0x36212a[_0x5022b7('0x2659')]['id'],_0x18dc67['resolve']('analyticFieldReport@get',_0x470152);}]}}):(_0x3309aa[_0x3ced2f('0x103b')]({'title':'Report\x20properly\x20run!','msg':_0x36212a['report'][_0x3ced2f('0x4f0')]?_0x36212a['report']['name']+'\x20has\x20been\x20run!':''}),_0x46ffb5());})[_0x469e6a('0x1a80')](function(_0x162cc0){const _0xaab5c1=_0x469e6a;_0x3309aa[_0xaab5c1('0xfc9')]({'title':_0x162cc0[_0xaab5c1('0x52d')]?_0xaab5c1('0x1e21')+_0x162cc0[_0xaab5c1('0x52d')]+_0xaab5c1('0x11e1')+_0x162cc0[_0xaab5c1('0xe1b')]:_0xaab5c1('0xe2c'),'msg':_0x162cc0[_0xaab5c1('0x25f4')]?JSON[_0xaab5c1('0xbac')](_0x162cc0[_0xaab5c1('0x25f4')][_0xaab5c1('0x1e70')]):_0x162cc0['toString']()});});}function _0x46ffb5(){_0x18730a['hide']();}}const _0x27d710=_0x4f2633;_0x4e9454[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),'api','columns',_0x36e6f4('0x2812'),'apiName','exportDate'];function _0x4e9454(_0x540ac9,_0x1a3308,_0x4bb704,_0x48093f,_0x609eae,_0x49296c,_0x56a62a){const _0x60da79=_0x36e6f4,_0x30c0c5=this;_0x30c0c5[_0x60da79('0x61a')]=[],_0x30c0c5[_0x60da79('0x2022')]=_0x48093f?_0x48093f['rows']:[],_0x30c0c5[_0x60da79('0x2812')]=_0x609eae||{'rows':[],'count':0x0},_0x30c0c5[_0x60da79('0x2218')]={'limit':0xa,'page':0x1},_0x30c0c5[_0x60da79('0x24a0')]=_0x541a7b,_0x30c0c5['getResults']=_0x5ef4f5,_0x30c0c5[_0x60da79('0x209d')]=_0x282cd4;function _0x5ef4f5(){const _0xc82342=_0x60da79;_0x56a62a['offset']=(_0x30c0c5[_0xc82342('0x2218')][_0xc82342('0x1a43')]-0x1)*_0x30c0c5[_0xc82342('0x2218')][_0xc82342('0x163f')],_0x56a62a[_0xc82342('0x163f')]=_0x30c0c5[_0xc82342('0x2218')][_0xc82342('0x163f')],_0x30c0c5[_0xc82342('0x1f48')]=_0x4bb704[_0x49296c][_0xc82342('0xca')](_0x56a62a,_0x295bfe)[_0xc82342('0xa44')];}function _0x282cd4(_0x94dbf3,_0xdf23a8){const _0x2dad66=_0x60da79;return _0x24273b()(_0xdf23a8,_0x2dad66('0x470'),!![])['isValid']()&&(_0xdf23a8=_0x24273b()(_0xdf23a8,'')[_0x2dad66('0x128a')](_0x2dad66('0x1084'))),_0xdf23a8;}function _0x295bfe(_0x365b26){const _0x1d6365=_0x60da79;_0x30c0c5[_0x1d6365('0x2812')]=_0x365b26||{'count':0x0,'rows':[]};}function _0x541a7b(){const _0x4eb4b7=_0x60da79;_0x540ac9[_0x4eb4b7('0x1197')]();}}const _0x43db70=_0x4e9454;_0xc14c72[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0xc14c72(_0x44f2f0){const _0x4ced72=_0x36e6f4;_0x44f2f0['state']('app.analytics.reports',{'url':'/reports','views':{'content@app':{'templateUrl':_0x5d6d04,'controller':_0x4ced72('0xefa')}},'resolve':{'treeReports':[_0x4ced72('0x1fbc'),function(_0x3331ae){const _0x34b17f=_0x4ced72;return _0x3331ae[_0x34b17f('0x18af')](_0x34b17f('0x2890'),{'fields':'id,tree','limit':0xa,'offset':0x0});}],'userProfile':[_0x4ced72('0x1fbc'),_0x4ced72('0x21ef'),function(_0x4b80e3,_0x1753f7){const _0x112f1e=_0x4ced72;return _0x4b80e3[_0x112f1e('0x18af')](_0x112f1e('0x697'),{'fields':'id,name,crudPermissions','id':_0x1753f7['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x4ced72('0x1fbc'),'Auth',function(_0x320157,_0x4a22d4){const _0x3b2afb=_0x4ced72;return _0x320157['resolve']('userProfileSection@get',{'fields':_0x3b2afb('0xe26'),'userProfileId':_0x4a22d4[_0x3b2afb('0x26cd')]()[_0x3b2afb('0xb86')],'sectionId':0x4b3});}]},'authenticate':!![],'permissionId':0x4b3,'bodyClass':_0x4ced72('0x18cc')})[_0x4ced72('0x63f')](_0x4ced72('0xb88'),{'url':_0x4ced72('0x2233'),'views':{'content@app':{'templateUrl':_0x1f0d1a,'controller':_0x4ced72('0xb10')}},'resolve':{'report':[_0x4ced72('0x1fbc'),'$stateParams','$q',_0x4ced72('0x28a2'),function(_0x20d442,_0x167bc2,_0x104670,_0x4dc37f){const _0x3ee13c=_0x4ced72;let _0x2928fb;return _0x20d442[_0x3ee13c('0x18af')](_0x3ee13c('0x1378'),{'fields':_0x3ee13c('0x120d'),'id':_0x167bc2['id']})['then'](function(_0x3ae80b){const _0x186ef6=_0x3ee13c,_0x4a2bce=[];_0x2928fb=_0x3ae80b;if(_0x2928fb['joins'])try{_0x2928fb[_0x186ef6('0xc91')]=JSON[_0x186ef6('0x1295')](_0x2928fb[_0x186ef6('0xc91')]);for(let _0xc58b5a=0x0;_0xc58b5a<_0x2928fb[_0x186ef6('0xc91')][_0x186ef6('0x264b')];_0xc58b5a+=0x1){_0x4a2bce[_0x186ef6('0x1514')](_0x4dc37f[_0x186ef6('0x1068')](_0x2928fb[_0x186ef6('0xc91')][_0xc58b5a][_0x186ef6('0x1847')]));}}catch(_0x43ada7){console['log'](_0x43ada7);}return _0x104670[_0x186ef6('0x2760')](_0x4a2bce);})['then'](function(_0x46835c){const _0x13c93b=_0x3ee13c;for(let _0x95ef0e=0x0;_0x95ef0e<_0x46835c['length'];_0x95ef0e+=0x1){_0x2928fb[_0x13c93b('0xc91')][_0x95ef0e]['foreignTableFields']=_0x2cfb05()[_0x13c93b('0x13ca')](_0x2cfb05()[_0x13c93b('0x14a4')](_0x46835c[_0x95ef0e]),[_0x13c93b('0xa44'),'$resolved']);}return _0x2928fb;});}],'userProfileSection':[_0x4ced72('0x1fbc'),_0x4ced72('0x21ef'),function(_0x1944fb,_0x156adb){const _0x5cb4a1=_0x4ced72;return _0x1944fb['resolve'](_0x5cb4a1('0xaf'),{'fields':_0x5cb4a1('0xe26'),'userProfileId':_0x156adb[_0x5cb4a1('0x26cd')]()[_0x5cb4a1('0xb86')],'sectionId':0x4b3});}]},'authenticate':!![],'permissionId':0x4b3,'bodyClass':_0x4ced72('0x18cc')});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x1fe2'),[_0x36e6f4('0x1e2f')])[_0x36e6f4('0xe11')](_0xc14c72)[_0x36e6f4('0x75e')](_0x36e6f4('0x1b9'),_0x1902e5)[_0x36e6f4('0x75e')]('CreateOrEditReportDialogController',_0xe61666)[_0x36e6f4('0x75e')](_0x36e6f4('0x1534'),_0x3a1ac6)[_0x36e6f4('0x87c')](_0x36e6f4('0x28a2'),_0x358762)['controller']('CreateOrEditReportFieldDialogController',_0x35547f)[_0x36e6f4('0x75e')](_0x36e6f4('0x2141'),_0x311b51)[_0x36e6f4('0x87c')]('sqlUtil',_0x45a694)[_0x36e6f4('0x75e')](_0x36e6f4('0x18f2'),_0xa920cf)[_0x36e6f4('0x75e')]('PreviewReportDialogController',_0x5b2d39)[_0x36e6f4('0x75e')](_0x36e6f4('0x2155'),_0xf7e78f)['controller'](_0x36e6f4('0xf90'),_0x27d710)[_0x36e6f4('0x75e')](_0x36e6f4('0x72b'),_0x43db70),_0x39dfd9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),'toasty','extractedReports',_0x36e6f4('0x1a7f'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x39dfd9(_0x12cb99,_0x34a0df,_0x3f2d6e,_0x1279b7,_0xd2404e,_0x3484df,_0x1f8e25,_0xfeed3c,_0x3df1aa,_0x4c6b4b,_0x4db472,_0x1817a6,_0x4d0b10,_0x2f0a72){const _0x10929f=_0x36e6f4,_0x49441e=this;_0x49441e[_0x10929f('0x98')]=_0x4db472[_0x10929f('0x26cd')](),_0x49441e['errors']=[],_0x49441e[_0x10929f('0xf8a')]=_0x4d0b10,_0x49441e[_0x10929f('0x5c9')]=_0x1817a6,_0x49441e[_0x10929f('0x243c')]=_0x2f0a72,_0x49441e['hasModulePermissions']={},_0x49441e[_0x10929f('0x2900')]=_0x49441e[_0x10929f('0xf8a')]&&_0x49441e[_0x10929f('0xf8a')][_0x10929f('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x49441e['title']=_0x10929f('0x462'),_0x49441e[_0x10929f('0x1a7f')]=angular[_0x10929f('0x225f')](_0x3df1aa),_0x49441e[_0x10929f('0x1223')]=_0xfeed3c,_0x49441e[_0x10929f('0x123e')]=![];!_0x49441e['extractedReport']&&(_0x49441e[_0x10929f('0x1a7f')]={},_0x49441e[_0x10929f('0xcdc')]=_0x10929f('0x24ec'),_0x49441e['newExtractedReport']=!![]);_0x49441e['addNewExtractedReport']=_0x53d4a6,_0x49441e[_0x10929f('0x683')]=_0x15b092,_0x49441e[_0x10929f('0x1622')]=_0x1c341b,_0x49441e['getDateFromString']=_0x461f55,_0x49441e['closeDialog']=_0x1e5648;function _0x53d4a6(){const _0x5c7c3f=_0x10929f;_0x49441e[_0x5c7c3f('0x61a')]=[],_0x4c6b4b[_0x5c7c3f('0x1cac')][_0x5c7c3f('0x9cc')](_0x49441e[_0x5c7c3f('0x1a7f')])[_0x5c7c3f('0xa44')][_0x5c7c3f('0x1166')](function(_0x2ffcad){const _0x1f9710=_0x5c7c3f;_0x49441e[_0x1f9710('0x1223')][_0x1f9710('0x2450')](_0x2ffcad['toJSON']()),_0x1f8e25['success']({'title':_0x1f9710('0xcb4'),'msg':_0x49441e[_0x1f9710('0x1a7f')][_0x1f9710('0x4f0')]?_0x49441e[_0x1f9710('0x1a7f')]['name']+_0x1f9710('0x1eda'):''}),_0x1e5648(_0x2ffcad);})['catch'](function(_0x4a0a8a){const _0x392261=_0x5c7c3f;if(_0x4a0a8a['data']&&_0x4a0a8a[_0x392261('0x25f4')][_0x392261('0x61a')]&&_0x4a0a8a[_0x392261('0x25f4')][_0x392261('0x61a')][_0x392261('0x264b')]){_0x49441e['errors']=_0x4a0a8a[_0x392261('0x25f4')][_0x392261('0x61a')]||[{'message':_0x4a0a8a[_0x392261('0x1586')](),'type':_0x392261('0x1b11')}];for(let _0x3964c6=0x0;_0x3964c6<_0x4a0a8a[_0x392261('0x25f4')]['errors'][_0x392261('0x264b')];_0x3964c6+=0x1){_0x1f8e25[_0x392261('0xfc9')]({'title':_0x4a0a8a[_0x392261('0x25f4')][_0x392261('0x61a')][_0x3964c6][_0x392261('0x1345')],'msg':_0x4a0a8a[_0x392261('0x25f4')][_0x392261('0x61a')][_0x3964c6][_0x392261('0x1e70')]});}}else _0x1f8e25[_0x392261('0xfc9')]({'title':_0x4a0a8a['status']?'API:'+_0x4a0a8a['status']+_0x392261('0x11e1')+_0x4a0a8a[_0x392261('0xe1b')]:_0x392261('0x1b11'),'msg':_0x4a0a8a[_0x392261('0x25f4')]?JSON[_0x392261('0xbac')](_0x4a0a8a[_0x392261('0x25f4')][_0x392261('0x1e70')]):_0x4a0a8a[_0x392261('0x1586')]()});});}function _0x15b092(){const _0x408057=_0x10929f;_0x49441e[_0x408057('0x61a')]=[],_0x4c6b4b['analyticExtractedReport'][_0x408057('0x1449')]({'id':_0x49441e[_0x408057('0x1a7f')]['id']},_0x49441e[_0x408057('0x1a7f')])[_0x408057('0xa44')][_0x408057('0x1166')](function(_0x2b4bc9){const _0x50a75=_0x408057,_0x5e8c60=_0x2cfb05()[_0x50a75('0xc38')](_0x49441e['extractedReports'],{'id':_0x2b4bc9['id']});_0x5e8c60&&_0x2cfb05()[_0x50a75('0xcc3')](_0x5e8c60,_0x2cfb05()[_0x50a75('0x1a08')](_0x2b4bc9[_0x50a75('0x2876')](),_0x2cfb05()[_0x50a75('0x14a4')](_0x5e8c60))),_0x1f8e25[_0x50a75('0x103b')]({'title':'ExtractedReport\x20properly\x20saved!','msg':_0x49441e[_0x50a75('0x1a7f')][_0x50a75('0x4f0')]?_0x49441e['extractedReport']['name']+_0x50a75('0x7d'):''}),_0x1e5648(_0x2b4bc9);})[_0x408057('0x1a80')](function(_0xd63b87){const _0x40ca00=_0x408057;if(_0xd63b87[_0x40ca00('0x25f4')]&&_0xd63b87[_0x40ca00('0x25f4')][_0x40ca00('0x61a')]&&_0xd63b87[_0x40ca00('0x25f4')]['errors']['length']){_0x49441e[_0x40ca00('0x61a')]=_0xd63b87[_0x40ca00('0x25f4')][_0x40ca00('0x61a')]||[{'message':_0xd63b87[_0x40ca00('0x1586')](),'type':_0x40ca00('0x10c3')}];for(let _0x47d2c2=0x0;_0x47d2c2<_0xd63b87[_0x40ca00('0x25f4')][_0x40ca00('0x61a')]['length'];_0x47d2c2++){_0x1f8e25['error']({'title':_0xd63b87[_0x40ca00('0x25f4')][_0x40ca00('0x61a')][_0x47d2c2]['type'],'msg':_0xd63b87[_0x40ca00('0x25f4')]['errors'][_0x47d2c2][_0x40ca00('0x1e70')]});}}else _0x1f8e25[_0x40ca00('0xfc9')]({'title':_0xd63b87[_0x40ca00('0x52d')]?_0x40ca00('0x1e21')+_0xd63b87['status']+'\x20-\x20'+_0xd63b87[_0x40ca00('0xe1b')]:_0x40ca00('0x10c3'),'msg':_0xd63b87['data']?JSON[_0x40ca00('0xbac')](_0xd63b87[_0x40ca00('0x25f4')]['message']):_0xd63b87[_0x40ca00('0x1586')]()});});}function _0x1c341b(_0x58696e){const _0x16ecc4=_0x10929f;_0x49441e['errors']=[];const _0x5b9ce3=_0x1279b7[_0x16ecc4('0x1d26')]()[_0x16ecc4('0xcdc')]('Are\x20you\x20sure?')['content'](_0x16ecc4('0x2f5'))[_0x16ecc4('0x8e8')]('Delete\x20ExtractedReport')['ok'](_0x16ecc4('0x18'))['cancel'](_0x16ecc4('0x497'))[_0x16ecc4('0x203b')](_0x58696e);_0x1279b7['show'](_0x5b9ce3)[_0x16ecc4('0x1166')](function(){const _0x2e9002=_0x16ecc4;_0x4c6b4b[_0x2e9002('0x1cac')][_0x2e9002('0x906')]({'id':_0x49441e[_0x2e9002('0x1a7f')]['id']})['$promise']['then'](function(){const _0xf0c48e=_0x2e9002;_0x2cfb05()[_0xf0c48e('0x127f')](_0x49441e[_0xf0c48e('0x1223')],{'id':_0x49441e['extractedReport']['id']}),_0x1f8e25[_0xf0c48e('0x103b')]({'title':_0xf0c48e('0x20ca'),'msg':(_0x49441e[_0xf0c48e('0x1a7f')][_0xf0c48e('0x4f0')]||_0xf0c48e('0x1a7f'))+_0xf0c48e('0x7cd')}),_0x1e5648(_0x49441e['extractedReport']);})[_0x2e9002('0x1a80')](function(_0x34d934){const _0x2ccebe=_0x2e9002;if(_0x34d934[_0x2ccebe('0x25f4')]&&_0x34d934[_0x2ccebe('0x25f4')]['errors']&&_0x34d934[_0x2ccebe('0x25f4')][_0x2ccebe('0x61a')][_0x2ccebe('0x264b')]){_0x49441e['errors']=_0x34d934['data'][_0x2ccebe('0x61a')]||[{'message':_0x34d934['toString'](),'type':_0x2ccebe('0x15e7')}];for(let _0x37c0ae=0x0;_0x37c0ae<_0x34d934[_0x2ccebe('0x25f4')]['errors']['length'];_0x37c0ae++){_0x1f8e25['error']({'title':_0x34d934[_0x2ccebe('0x25f4')]['errors'][_0x37c0ae]['type'],'msg':_0x34d934[_0x2ccebe('0x25f4')][_0x2ccebe('0x61a')][_0x37c0ae]['message']});}}else _0x1f8e25[_0x2ccebe('0xfc9')]({'title':_0x34d934[_0x2ccebe('0x52d')]?_0x2ccebe('0x1e21')+_0x34d934[_0x2ccebe('0x52d')]+'\x20-\x20'+_0x34d934['statusText']:_0x2ccebe('0x15e7'),'msg':_0x34d934[_0x2ccebe('0x25f4')]?JSON[_0x2ccebe('0xbac')](_0x34d934[_0x2ccebe('0x25f4')][_0x2ccebe('0x1e70')]):_0x34d934[_0x2ccebe('0x1e70')]||_0x34d934[_0x2ccebe('0x1586')]()});});},function(){});}function _0x461f55(_0x4c2bf3){return _0x4c2bf3===null?undefined:new Date(_0x4c2bf3);}function _0x1e5648(_0x57bd8c){const _0x22303d=_0x10929f;_0x1279b7[_0x22303d('0x1197')](_0x57bd8c);}}const _0x357083=_0x39dfd9,_0xfa578c=_0x2734b2['p']+_0x36e6f4('0x20bb');_0xa948be[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout','$translate',_0x36e6f4('0x1223'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting'];function _0xa948be(_0x5c59d2,_0x1f80ae,_0x548728,_0x2a94c4,_0x4c0a7d,_0x289e5a,_0x53aed1,_0x35bf1d,_0x31ba7e,_0x269c4e,_0x4da14a,_0x2d6233,_0x3c6788,_0x18fc50,_0x1b8865,_0x17a67d,_0x3b3b82){const _0x8c03c2=_0x36e6f4,_0x26423c=this;_0x26423c[_0x8c03c2('0x5c9')]=_0x17a67d,_0x26423c[_0x8c03c2('0xf8a')]=_0x3b3b82,_0x26423c['currentUser']=_0x1b8865[_0x8c03c2('0x26cd')](),_0x26423c['extractedReports']=_0x31ba7e||{'count':0x0,'rows':[]},_0x26423c['userProfile']=_0x269c4e,_0x26423c[_0x8c03c2('0x17aa')]=_0x4da14a&&_0x4da14a[_0x8c03c2('0x240f')]==0x1?_0x4da14a[_0x8c03c2('0x269a')][0x0]:null,_0x26423c[_0x8c03c2('0x243c')]=_0x1b8865[_0x8c03c2('0xd87')](_0x26423c[_0x8c03c2('0x17aa')]?_0x26423c[_0x8c03c2('0x17aa')][_0x8c03c2('0x243c')]:null),_0x26423c['table']=_0x8c03c2('0x1223'),_0x26423c[_0x8c03c2('0xef5')]='',_0x26423c[_0x8c03c2('0x104c')]=null,_0x26423c[_0x8c03c2('0x2810')]=[],_0x26423c[_0x8c03c2('0x2218')]={'fields':_0x8c03c2('0x1897'),'sort':_0x8c03c2('0x14dc'),'limit':0xa,'page':0x1},_0x26423c['editdialog']=_0x37551c,_0x26423c['downloadfile2']=_0x141d72,_0x26423c[_0x8c03c2('0x8d8')]=_0x29fdb0,_0x26423c[_0x8c03c2('0x103b')]=_0x51b81b,_0x26423c[_0x8c03c2('0x78f')]=_0x5b2add,_0x26423c[_0x8c03c2('0x20a8')]=_0x31e205,_0x26423c[_0x8c03c2('0x1622')]=_0x4d131f,_0x26423c[_0x8c03c2('0x4dc')]=_0x110664,_0x26423c[_0x8c03c2('0x1b56')]=_0x2e2226,_0x26423c[_0x8c03c2('0x282c')]=_0x2d2ff8,_0x26423c[_0x8c03c2('0xd91')]=_0x170f50;function _0x37551c(_0x33e1de,_0x44ffd6){const _0x3ad603=_0x8c03c2;_0x4c0a7d['show']({'controller':_0x3ad603('0x1729'),'controllerAs':'vm','templateUrl':_0xfa578c,'parent':angular[_0x3ad603('0x1194')](_0x289e5a[_0x3ad603('0x8d2')]),'targetEvent':_0x44ffd6,'clickOutsideToClose':!![],'locals':{'extractedReport':_0x33e1de,'extractedReports':_0x26423c[_0x3ad603('0x1223')][_0x3ad603('0x269a')],'license':_0x26423c['license'],'setting':null,'crudPermissions':_0x26423c[_0x3ad603('0x243c')]}});}function _0x141d72(_0x4d1f58){const _0x2fb8a3=_0x8c03c2;return _0x2d6233[_0x2fb8a3('0x1cac')][_0x2fb8a3('0x2ad')]({'id':_0x4d1f58['id']})[_0x2fb8a3('0xa44')]['then'](function(_0x2918f0){const _0x4d6cc6=_0x2fb8a3,_0x4509fd=[_0x2918f0[_0x4d6cc6('0x20ed')]];let _0x2bb951='download';const _0x3b1481=new Blob(_0x4509fd,{'type':_0x2918f0[_0x4d6cc6('0x1345')]});_0x2bb951=_0x4d1f58[_0x4d6cc6('0x1b0e')];const _0x215014=window['document'][_0x4d6cc6('0xdd')]('a');_0x215014[_0x4d6cc6('0xffd')](_0x4d6cc6('0x14f9'),URL[_0x4d6cc6('0x215a')](_0x3b1481)),_0x215014[_0x4d6cc6('0xffd')](_0x4d6cc6('0x2ad'),_0x2bb951),document[_0x4d6cc6('0x8d2')]['appendChild'](_0x215014),_0x215014[_0x4d6cc6('0x3b4')]();})[_0x2fb8a3('0x1a80')](function(_0x34e078){const _0x1a9304=_0x2fb8a3;if(_0x34e078['data']&&_0x34e078[_0x1a9304('0x25f4')]['errors']&&_0x34e078[_0x1a9304('0x25f4')][_0x1a9304('0x61a')]['length'])for(let _0x3463e0=0x0;_0x3463e0<_0x34e078['data'][_0x1a9304('0x61a')][_0x1a9304('0x264b')];_0x3463e0++){_0x18fc50[_0x1a9304('0xfc9')]({'title':_0x34e078[_0x1a9304('0x25f4')][_0x1a9304('0x61a')][_0x3463e0]['type'],'msg':_0x34e078[_0x1a9304('0x25f4')][_0x1a9304('0x61a')][_0x3463e0][_0x1a9304('0x1e70')]});}else _0x18fc50[_0x1a9304('0xfc9')]({'title':_0x34e078[_0x1a9304('0x52d')]?_0x1a9304('0x1e21')+_0x34e078[_0x1a9304('0x52d')]+'\x20-\x20'+_0x34e078[_0x1a9304('0xe1b')]:'api.analyticExtractedReport.save','msg':_0x34e078['data']?JSON[_0x1a9304('0xbac')](_0x34e078[_0x1a9304('0x25f4')][_0x1a9304('0x1e70')]):_0x34e078[_0x1a9304('0x1586')]()});});}function _0x29fdb0(_0x168e73,_0x15993b){const _0x56d5ec=_0x8c03c2,_0x2d0e6e=_0x4c0a7d['confirm']()[_0x56d5ec('0xcdc')](_0x56d5ec('0x288d')+_0x2cfb05()[_0x56d5ec('0xb35')](_0x56d5ec('0x1a7f'))+'?')[_0x56d5ec('0xf3c')](_0x56d5ec('0x12b5')+(_0x168e73[_0x56d5ec('0x4f0')]||'extractedReport')+''+_0x56d5ec('0x3f3'))[_0x56d5ec('0x8e8')]('delete\x20extractedReport')[_0x56d5ec('0x203b')](_0x15993b)['ok']('OK')[_0x56d5ec('0x3f')](_0x56d5ec('0x2d3'));_0x4c0a7d[_0x56d5ec('0x1f80')](_0x2d0e6e)[_0x56d5ec('0x1166')](function(){_0x4d131f(_0x168e73);},function(){const _0x5b82a4=_0x56d5ec;console[_0x5b82a4('0x455')](_0x5b82a4('0x2d3'));});}let _0x24cece=!![],_0x1e768d=0x1;_0x5c59d2[_0x8c03c2('0xe83')](_0x8c03c2('0x12d8'),function(_0xc8c8dc,_0x4acc37){const _0x4df12c=_0x8c03c2;_0x24cece?_0x53aed1(function(){_0x24cece=![];}):(!_0x4acc37&&(_0x1e768d=_0x26423c[_0x4df12c('0x2218')]['page']),_0xc8c8dc!==_0x4acc37&&(_0x26423c[_0x4df12c('0x2218')][_0x4df12c('0x1a43')]=0x1),!_0xc8c8dc&&(_0x26423c[_0x4df12c('0x2218')][_0x4df12c('0x1a43')]=_0x1e768d),_0x26423c[_0x4df12c('0x78f')]());});function _0x51b81b(_0x2a66fd){const _0x421090=_0x8c03c2;_0x26423c[_0x421090('0x1223')]=_0x2a66fd||{'count':0x0,'rows':[]};}function _0x5b2add(){const _0x2760e6=_0x8c03c2;_0x26423c[_0x2760e6('0x2218')][_0x2760e6('0x1098')]=(_0x26423c[_0x2760e6('0x2218')][_0x2760e6('0x1a43')]-0x1)*_0x26423c['query'][_0x2760e6('0x163f')],_0x1b8865[_0x2760e6('0x1ac6')](_0x2760e6('0xa7c'))?_0x26423c[_0x2760e6('0x1f48')]=_0x2d6233[_0x2760e6('0x1cac')][_0x2760e6('0xd83')](_0x26423c[_0x2760e6('0x2218')],_0x51b81b)[_0x2760e6('0xa44')]:(_0x26423c[_0x2760e6('0x2218')]['id']=_0x26423c['userProfile']['id'],_0x26423c[_0x2760e6('0x2218')][_0x2760e6('0xe60')]=_0x2760e6('0x1e5a'),_0x26423c[_0x2760e6('0x1f48')]=_0x2d6233[_0x2760e6('0x7f')][_0x2760e6('0x263a')](_0x26423c['query'],_0x51b81b)[_0x2760e6('0xa44')]);}function _0x31e205(_0xeacd1c,_0x4ab627){const _0x23340d=_0x8c03c2;_0x4c0a7d['show']({'controller':'CreateOrEditExtractedReportDialogController','controllerAs':'vm','templateUrl':_0xfa578c,'parent':angular[_0x23340d('0x1194')](_0x289e5a[_0x23340d('0x8d2')]),'targetEvent':_0xeacd1c,'clickOutsideToClose':!![],'locals':{'extractedReport':_0x4ab627,'extractedReports':_0x26423c[_0x23340d('0x1223')]['rows'],'license':_0x26423c[_0x23340d('0x5c9')],'setting':_0x26423c['setting'],'crudPermissions':_0x26423c[_0x23340d('0x243c')]}});}function _0x4d131f(_0x1dbc16){const _0x72f0fa=_0x8c03c2;_0x2d6233[_0x72f0fa('0x1cac')][_0x72f0fa('0x906')]({'id':_0x1dbc16['id']})[_0x72f0fa('0xa44')]['then'](function(){const _0xd29145=_0x72f0fa;_0x2cfb05()['remove'](_0x26423c[_0xd29145('0x1223')][_0xd29145('0x269a')],{'id':_0x1dbc16['id']}),_0x26423c['extractedReports'][_0xd29145('0x240f')]-=0x1,!_0x26423c[_0xd29145('0x1223')][_0xd29145('0x269a')][_0xd29145('0x264b')]&&_0x26423c[_0xd29145('0x78f')](),_0x18fc50[_0xd29145('0x103b')]({'title':_0x2cfb05()[_0xd29145('0xb35')]('ExtractedReport')+'\x20deleted!','msg':_0x1dbc16[_0xd29145('0x4f0')]?_0x1dbc16[_0xd29145('0x4f0')]+_0xd29145('0x7cd'):''});})['catch'](function(_0x24d63e){const _0x5a7d53=_0x72f0fa;if(_0x24d63e[_0x5a7d53('0x25f4')]&&_0x24d63e[_0x5a7d53('0x25f4')][_0x5a7d53('0x61a')]&&_0x24d63e[_0x5a7d53('0x25f4')][_0x5a7d53('0x61a')][_0x5a7d53('0x264b')]){_0x26423c[_0x5a7d53('0x61a')]=_0x24d63e[_0x5a7d53('0x25f4')][_0x5a7d53('0x61a')]||[{'message':_0x24d63e[_0x5a7d53('0x1586')](),'type':'SYSTEM:DELETEanalyticExtractedReport'}];for(let _0x36b33b=0x0;_0x36b33b<_0x24d63e['data'][_0x5a7d53('0x61a')]['length'];_0x36b33b++){_0x18fc50[_0x5a7d53('0xfc9')]({'title':_0x24d63e[_0x5a7d53('0x25f4')][_0x5a7d53('0x61a')][_0x36b33b]['type'],'msg':_0x24d63e[_0x5a7d53('0x25f4')][_0x5a7d53('0x61a')][_0x36b33b][_0x5a7d53('0x1e70')]});}}else _0x18fc50[_0x5a7d53('0xfc9')]({'title':_0x24d63e[_0x5a7d53('0x52d')]?'API:'+_0x24d63e[_0x5a7d53('0x52d')]+_0x5a7d53('0x11e1')+_0x24d63e[_0x5a7d53('0xe1b')]:_0x5a7d53('0x2776'),'msg':_0x24d63e[_0x5a7d53('0x25f4')]?JSON[_0x5a7d53('0xbac')](_0x24d63e['data'][_0x5a7d53('0x1e70')]):_0x24d63e[_0x5a7d53('0x1e70')]||_0x24d63e[_0x5a7d53('0x1586')]()});});}function _0x110664(){const _0x3edca9=_0x8c03c2,_0x5388e4=angular['copy'](_0x26423c[_0x3edca9('0x2810')]);return _0x26423c[_0x3edca9('0x2810')]=[],_0x5388e4;}function _0x2e2226(_0x2320d4){const _0x281b2c=_0x8c03c2,_0xeed38c=_0x4c0a7d[_0x281b2c('0x1d26')]()[_0x281b2c('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20extractedReports?')[_0x281b2c('0xf3c')](''+_0x26423c['selectedExtractedReports']['length']+_0x281b2c('0x196d')+_0x281b2c('0x3f3'))[_0x281b2c('0x8e8')](_0x281b2c('0x77d'))[_0x281b2c('0x203b')](_0x2320d4)['ok']('OK')[_0x281b2c('0x3f')](_0x281b2c('0x2d3'));_0x4c0a7d[_0x281b2c('0x1f80')](_0xeed38c)[_0x281b2c('0x1166')](function(){const _0x95dd03=_0x281b2c;_0x26423c[_0x95dd03('0x2810')][_0x95dd03('0x2782')](function(_0x4f9d54){_0x4d131f(_0x4f9d54);}),_0x26423c[_0x95dd03('0x2810')]=[];});}function _0x2d2ff8(){const _0x449f4b=_0x8c03c2;_0x26423c[_0x449f4b('0x2810')]=[];}function _0x170f50(){const _0x5a1c7f=_0x8c03c2;_0x26423c[_0x5a1c7f('0x2810')]=_0x26423c[_0x5a1c7f('0x1223')][_0x5a1c7f('0x269a')];}}const _0x3da683=_0xa948be;_0x170140[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x15d3'),_0x36e6f4('0x64c'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x170140(_0x55ff11,_0x4f637a,_0x231ea1,_0x4c1e82,_0x21714b,_0x35576f,_0x5f2d4b,_0x42e182,_0x1ee5a9,_0x2c50cf,_0x58c905,_0x19e091,_0x3b12d9,_0x5a7c97){const _0x5cebcd=_0x36e6f4,_0x29ed44=this;_0x29ed44[_0x5cebcd('0x98')]=_0x58c905[_0x5cebcd('0x26cd')](),_0x29ed44[_0x5cebcd('0x61a')]=[],_0x29ed44[_0x5cebcd('0xf8a')]=_0x3b12d9,_0x29ed44[_0x5cebcd('0x5c9')]=_0x19e091,_0x29ed44[_0x5cebcd('0x243c')]=_0x5a7c97,_0x29ed44[_0x5cebcd('0x128b')]={},_0x29ed44[_0x5cebcd('0x2900')]=_0x29ed44[_0x5cebcd('0xf8a')]&&_0x29ed44[_0x5cebcd('0xf8a')][_0x5cebcd('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x29ed44[_0x5cebcd('0xcdc')]=_0x5cebcd('0xb49'),_0x29ed44[_0x5cebcd('0x64c')]=angular[_0x5cebcd('0x225f')](_0x1ee5a9),_0x29ed44['metrics']=_0x42e182,_0x29ed44[_0x5cebcd('0x95b')]=![];!_0x29ed44[_0x5cebcd('0x64c')]&&(_0x29ed44[_0x5cebcd('0x64c')]={'table':_0x5cebcd('0x25f6')},_0x29ed44[_0x5cebcd('0xcdc')]=_0x5cebcd('0x15ed'),_0x29ed44[_0x5cebcd('0x95b')]=!![]);_0x29ed44['addNewMetric']=_0x4469bb,_0x29ed44[_0x5cebcd('0x16fa')]=_0x39d082,_0x29ed44['deleteMetric']=_0x4798ae,_0x29ed44[_0x5cebcd('0x1a9c')]=_0x10e308,_0x29ed44[_0x5cebcd('0x24a0')]=_0x35aa9f;function _0x4469bb(){const _0x5d9be4=_0x5cebcd;_0x29ed44['errors']=[],_0x2c50cf[_0x5d9be4('0x2e8')][_0x5d9be4('0x9cc')](_0x29ed44['metric'])[_0x5d9be4('0xa44')]['then'](function(_0x5841e2){const _0x56c775=_0x5d9be4;_0x29ed44['metrics'][_0x56c775('0x2450')](_0x5841e2[_0x56c775('0x2876')]()),_0x5f2d4b['success']({'title':_0x56c775('0x2142'),'msg':_0x29ed44[_0x56c775('0x64c')][_0x56c775('0x4f0')]?_0x29ed44[_0x56c775('0x64c')]['name']+_0x56c775('0x1eda'):''}),_0x35aa9f(_0x5841e2);})['catch'](function(_0x4fa4ee){const _0x1b441c=_0x5d9be4;if(_0x4fa4ee['data']&&_0x4fa4ee[_0x1b441c('0x25f4')][_0x1b441c('0x61a')]&&_0x4fa4ee[_0x1b441c('0x25f4')]['errors'][_0x1b441c('0x264b')]){_0x29ed44[_0x1b441c('0x61a')]=_0x4fa4ee[_0x1b441c('0x25f4')][_0x1b441c('0x61a')]||[{'message':_0x4fa4ee[_0x1b441c('0x1586')](),'type':_0x1b441c('0xe17')}];for(let _0x460ba5=0x0;_0x460ba5<_0x4fa4ee[_0x1b441c('0x25f4')]['errors'][_0x1b441c('0x264b')];_0x460ba5+=0x1){_0x5f2d4b['error']({'title':_0x4fa4ee[_0x1b441c('0x25f4')]['errors'][_0x460ba5][_0x1b441c('0x1345')],'msg':_0x4fa4ee[_0x1b441c('0x25f4')]['errors'][_0x460ba5]['message']});}}else _0x5f2d4b[_0x1b441c('0xfc9')]({'title':_0x4fa4ee[_0x1b441c('0x52d')]?_0x1b441c('0x1e21')+_0x4fa4ee['status']+_0x1b441c('0x11e1')+_0x4fa4ee[_0x1b441c('0xe1b')]:'api.analyticMetric.save','msg':_0x4fa4ee['data']?JSON['stringify'](_0x4fa4ee[_0x1b441c('0x25f4')][_0x1b441c('0x1e70')]):_0x4fa4ee[_0x1b441c('0x1586')]()});});}function _0x39d082(){const _0x134099=_0x5cebcd;_0x29ed44[_0x134099('0x61a')]=[],_0x2c50cf['analyticMetric'][_0x134099('0x1449')]({'id':_0x29ed44['metric']['id']},_0x29ed44[_0x134099('0x64c')])['$promise']['then'](function(_0x1fe583){const _0x54900e=_0x134099,_0x475c29=_0x2cfb05()[_0x54900e('0xc38')](_0x29ed44['metrics'],{'id':_0x1fe583['id']});_0x475c29&&_0x2cfb05()[_0x54900e('0xcc3')](_0x475c29,_0x2cfb05()[_0x54900e('0x1a08')](_0x1fe583['toJSON'](),_0x2cfb05()[_0x54900e('0x14a4')](_0x475c29))),_0x5f2d4b['success']({'title':_0x54900e('0xb65'),'msg':_0x29ed44[_0x54900e('0x64c')][_0x54900e('0x4f0')]?_0x29ed44['metric'][_0x54900e('0x4f0')]+_0x54900e('0x7d'):''}),_0x35aa9f(_0x1fe583);})['catch'](function(_0x114cb9){const _0x161eec=_0x134099;if(_0x114cb9[_0x161eec('0x25f4')]&&_0x114cb9['data'][_0x161eec('0x61a')]&&_0x114cb9[_0x161eec('0x25f4')][_0x161eec('0x61a')]['length']){_0x29ed44[_0x161eec('0x61a')]=_0x114cb9[_0x161eec('0x25f4')][_0x161eec('0x61a')]||[{'message':_0x114cb9[_0x161eec('0x1586')](),'type':_0x161eec('0x1f42')}];for(let _0x319fb0=0x0;_0x319fb0<_0x114cb9['data']['errors'][_0x161eec('0x264b')];_0x319fb0++){_0x5f2d4b[_0x161eec('0xfc9')]({'title':_0x114cb9[_0x161eec('0x25f4')][_0x161eec('0x61a')][_0x319fb0][_0x161eec('0x1345')],'msg':_0x114cb9[_0x161eec('0x25f4')][_0x161eec('0x61a')][_0x319fb0][_0x161eec('0x1e70')]});}}else _0x5f2d4b[_0x161eec('0xfc9')]({'title':_0x114cb9[_0x161eec('0x52d')]?_0x161eec('0x1e21')+_0x114cb9[_0x161eec('0x52d')]+_0x161eec('0x11e1')+_0x114cb9[_0x161eec('0xe1b')]:_0x161eec('0x1f42'),'msg':_0x114cb9[_0x161eec('0x25f4')]?JSON[_0x161eec('0xbac')](_0x114cb9['data']['message']):_0x114cb9[_0x161eec('0x1586')]()});});}function _0x4798ae(_0xed2fd9){const _0x5d2b23=_0x5cebcd;_0x29ed44[_0x5d2b23('0x61a')]=[];const _0x47638f=_0x4c1e82[_0x5d2b23('0x1d26')]()[_0x5d2b23('0xcdc')](_0x5d2b23('0x7fb'))[_0x5d2b23('0xacc')](_0x5d2b23('0x445'))[_0x5d2b23('0x8e8')](_0x5d2b23('0x21eb'))['ok'](_0x5d2b23('0x18'))['cancel'](_0x5d2b23('0x497'))[_0x5d2b23('0x203b')](_0xed2fd9);_0x4c1e82[_0x5d2b23('0x1f80')](_0x47638f)[_0x5d2b23('0x1166')](function(){const _0xd3ba1e=_0x5d2b23;_0x2c50cf[_0xd3ba1e('0x2e8')]['delete']({'id':_0x29ed44[_0xd3ba1e('0x64c')]['id']})[_0xd3ba1e('0xa44')][_0xd3ba1e('0x1166')](function(){const _0x5ea94f=_0xd3ba1e;_0x2cfb05()[_0x5ea94f('0x127f')](_0x29ed44[_0x5ea94f('0x15d3')],{'id':_0x29ed44[_0x5ea94f('0x64c')]['id']}),_0x5f2d4b['success']({'title':_0x5ea94f('0x1cc'),'msg':(_0x29ed44[_0x5ea94f('0x64c')]['name']||_0x5ea94f('0x64c'))+_0x5ea94f('0x7cd')}),_0x35aa9f(_0x29ed44[_0x5ea94f('0x64c')]);})[_0xd3ba1e('0x1a80')](function(_0x57e391){const _0x877a8b=_0xd3ba1e;if(_0x57e391['data']&&_0x57e391['data']['errors']&&_0x57e391[_0x877a8b('0x25f4')][_0x877a8b('0x61a')][_0x877a8b('0x264b')]){_0x29ed44['errors']=_0x57e391[_0x877a8b('0x25f4')][_0x877a8b('0x61a')]||[{'message':_0x57e391[_0x877a8b('0x1586')](),'type':_0x877a8b('0x532')}];for(let _0x44df67=0x0;_0x44df67<_0x57e391[_0x877a8b('0x25f4')][_0x877a8b('0x61a')][_0x877a8b('0x264b')];_0x44df67++){_0x5f2d4b['error']({'title':_0x57e391[_0x877a8b('0x25f4')]['errors'][_0x44df67][_0x877a8b('0x1345')],'msg':_0x57e391[_0x877a8b('0x25f4')]['errors'][_0x44df67][_0x877a8b('0x1e70')]});}}else _0x5f2d4b[_0x877a8b('0xfc9')]({'title':_0x57e391[_0x877a8b('0x52d')]?_0x877a8b('0x1e21')+_0x57e391[_0x877a8b('0x52d')]+_0x877a8b('0x11e1')+_0x57e391[_0x877a8b('0xe1b')]:'api.analyticMetric.delete','msg':_0x57e391[_0x877a8b('0x25f4')]?JSON[_0x877a8b('0xbac')](_0x57e391[_0x877a8b('0x25f4')][_0x877a8b('0x1e70')]):_0x57e391['message']||_0x57e391[_0x877a8b('0x1586')]()});});},function(){});}function _0x10e308(_0x5e1889){return _0x5e1889===null?undefined:new Date(_0x5e1889);}function _0x35aa9f(_0x26c0ff){const _0x58a3ff=_0x5cebcd;_0x4c1e82[_0x58a3ff('0x1197')](_0x26c0ff);}}const _0x437b9d=_0x170140,_0x34bf13=_0x2734b2['p']+_0x36e6f4('0x40c');_0x570eb3[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$window',_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'metrics','userProfile','userProfileSection',_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting'];function _0x570eb3(_0x2d53d0,_0x3c4b70,_0x1089af,_0x185c83,_0x5d57a4,_0x788c2d,_0x4aa9ea,_0xd11762,_0x2f8389,_0x5dede4,_0xdaecb4,_0x327bd5,_0x28c667,_0x5509f5,_0x2411e3,_0x256345,_0x23375d){const _0x172a11=_0x36e6f4,_0x273d47=this;_0x273d47[_0x172a11('0x5c9')]=_0x256345,_0x273d47[_0x172a11('0xf8a')]=_0x23375d,_0x273d47[_0x172a11('0x98')]=_0x2411e3['getCurrentUser'](),_0x273d47[_0x172a11('0x15d3')]=_0x2f8389||{'count':0x0,'rows':[]},_0x273d47[_0x172a11('0x7f')]=_0x5dede4,_0x273d47[_0x172a11('0x17aa')]=_0xdaecb4&&_0xdaecb4[_0x172a11('0x240f')]==0x1?_0xdaecb4[_0x172a11('0x269a')][0x0]:null,_0x273d47[_0x172a11('0x243c')]=_0x2411e3['parseCrudPermissions'](_0x273d47[_0x172a11('0x17aa')]?_0x273d47['userProfileSection'][_0x172a11('0x243c')]:null),_0x273d47['table']='metrics',_0x273d47[_0x172a11('0xef5')]='',_0x273d47[_0x172a11('0x104c')]=null,_0x273d47[_0x172a11('0x2f')]=[],_0x273d47['query']={'fields':'createdAt,updatedAt,id,name,table,metric,description','sort':_0x172a11('0x14dc'),'limit':0xa,'page':0x1},_0x273d47[_0x172a11('0xde5')]=_0x2cfb05()[_0x172a11('0x155c')]([{'option':'Agent\x20Report','value':_0x172a11('0x22cc')},{'option':_0x172a11('0x1ef0'),'value':_0x172a11('0x777')},{'option':'CDR','value':_0x172a11('0x794')},{'option':_0x172a11('0x154b'),'value':_0x172a11('0x11f')},{'option':_0x172a11('0x1a96'),'value':'\x27chat_interactions\x27'},{'option':'Chat\x20Messages','value':'\x27chat_messages\x27'},{'option':_0x172a11('0x2696'),'value':'\x27chat_offline_messages\x27'},{'option':'Chat\x20Queues','value':_0x172a11('0x2771')},{'option':_0x172a11('0x17fe'),'value':'\x27report_chat_queue\x27'},{'option':'Chat\x20Report\x20Transfer','value':_0x172a11('0x9d5')},{'option':_0x172a11('0x117'),'value':_0x172a11('0x53c')},{'option':_0x172a11('0x2326'),'value':_0x172a11('0x15aa')},{'option':'CSquare\x20Report','value':_0x172a11('0x257b')},{'option':_0x172a11('0x24f8'),'value':_0x172a11('0xf12')},{'option':_0x172a11('0x9a6'),'value':_0x172a11('0x50c')},{'option':_0x172a11('0x1266'),'value':_0x172a11('0x2134')},{'option':_0x172a11('0x24b2'),'value':_0x172a11('0x3c2')},{'option':_0x172a11('0x1a2c'),'value':'\x27cm_hopper_final\x27'},{'option':_0x172a11('0x20c2'),'value':_0x172a11('0x2011')},{'option':_0x172a11('0x1210'),'value':'\x27mail_interactions\x27'},{'option':'Email\x20Messages','value':_0x172a11('0x13aa')},{'option':_0x172a11('0x174b'),'value':_0x172a11('0x1d97')},{'option':'Email\x20Report\x20Queue','value':_0x172a11('0x9a')},{'option':'Email\x20Report\x20Transfer','value':_0x172a11('0x104b')},{'option':'Fax\x20Account','value':_0x172a11('0xf5f')},{'option':_0x172a11('0x1d4'),'value':'\x27fax_interactions\x27'},{'option':_0x172a11('0x16fb'),'value':_0x172a11('0x64f')},{'option':_0x172a11('0x1362'),'value':_0x172a11('0x1bf')},{'option':_0x172a11('0x1650'),'value':_0x172a11('0x1559')},{'option':_0x172a11('0x404'),'value':_0x172a11('0x964')},{'option':'Jscripty\x20Sessions','value':_0x172a11('0x26a0')},{'option':_0x172a11('0x531'),'value':_0x172a11('0x946')},{'option':_0x172a11('0x233d'),'value':_0x172a11('0x1148')},{'option':'Lists','value':'\x27cm_lists\x27'},{'option':'Member\x20Report','value':_0x172a11('0x331')},{'option':'Openchannel\x20Account','value':_0x172a11('0x1c18')},{'option':_0x172a11('0x1e91'),'value':_0x172a11('0xfa7')},{'option':_0x172a11('0x1120'),'value':_0x172a11('0x4bb')},{'option':_0x172a11('0x1fd6'),'value':_0x172a11('0x274d')},{'option':_0x172a11('0xc72'),'value':'\x27report_openchannel_queue\x27'},{'option':_0x172a11('0x10c9'),'value':_0x172a11('0xd4')},{'option':_0x172a11('0x1d8d'),'value':'\x27report_queue\x27'},{'option':_0x172a11('0xf4d'),'value':_0x172a11('0x335')},{'option':_0x172a11('0x23a1'),'value':_0x172a11('0x388')},{'option':_0x172a11('0xac0'),'value':'\x27sms_messages\x27'},{'option':_0x172a11('0x1a9f'),'value':'\x27sms_queues\x27'},{'option':_0x172a11('0x7f1'),'value':_0x172a11('0x1ebb')},{'option':_0x172a11('0x1f8f'),'value':_0x172a11('0x1bd1')},{'option':_0x172a11('0x1bc7'),'value':_0x172a11('0xd')},{'option':_0x172a11('0xaac'),'value':'\x27voice_recordings\x27'},{'option':'Whatsapp\x20Account','value':_0x172a11('0x2373')},{'option':'Whatsapp\x20Interaction','value':_0x172a11('0x2115')},{'option':_0x172a11('0x25e2'),'value':_0x172a11('0x28cd')},{'option':_0x172a11('0x1e27'),'value':_0x172a11('0xd5e')},{'option':_0x172a11('0x26bd'),'value':'\x27report_whatsapp_queue\x27'},{'option':_0x172a11('0x417'),'value':_0x172a11('0x14ad')}],function(_0xcc7169){const _0x359c4f=_0x172a11;return _0x2cfb05()[_0x359c4f('0xf3')](_0xcc7169['value'],new RegExp('\x27','g'),'');}),_0x273d47['editdialog']=_0x2c54e4,_0x273d47[_0x172a11('0x8d8')]=_0x4490e2,_0x273d47['success']=_0x123e6c,_0x273d47[_0x172a11('0x44a')]=_0x43b126,_0x273d47[_0x172a11('0x1a94')]=_0x4ef2a3,_0x273d47[_0x172a11('0xbdf')]=_0x2fac8b,_0x273d47['exportSelectedMetrics']=_0x3f79ea,_0x273d47['deleteSelectedMetrics']=_0x1501e8,_0x273d47[_0x172a11('0xf72')]=_0x2234c8,_0x273d47[_0x172a11('0x202a')]=_0x3af4bd;function _0x2c54e4(_0x2aafb1,_0x28a25b){const _0x1a9077=_0x172a11;_0x5d57a4[_0x1a9077('0x1f80')]({'controller':'CreateOrEditMetricDialogController','controllerAs':'vm','templateUrl':_0x34bf13,'parent':angular['element'](_0x788c2d[_0x1a9077('0x8d2')]),'targetEvent':_0x28a25b,'clickOutsideToClose':!![],'locals':{'metric':_0x2aafb1,'metrics':_0x273d47[_0x1a9077('0x15d3')]['rows'],'license':_0x273d47[_0x1a9077('0x5c9')],'setting':null,'crudPermissions':_0x273d47[_0x1a9077('0x243c')]}});}function _0x4490e2(_0x4d7cd9,_0x3a585e){const _0x5e8120=_0x172a11,_0x2bf065=_0x5d57a4['confirm']()[_0x5e8120('0xcdc')](_0x5e8120('0x288d')+_0x2cfb05()[_0x5e8120('0xb35')](_0x5e8120('0x64c'))+'?')[_0x5e8120('0xf3c')](_0x5e8120('0x12b5')+(_0x4d7cd9['name']||'metric')+''+_0x5e8120('0x3f3'))[_0x5e8120('0x8e8')](_0x5e8120('0x1808'))[_0x5e8120('0x203b')](_0x3a585e)['ok']('OK')[_0x5e8120('0x3f')]('CANCEL');_0x5d57a4[_0x5e8120('0x1f80')](_0x2bf065)[_0x5e8120('0x1166')](function(){_0x2fac8b(_0x4d7cd9);},function(){const _0x387d7d=_0x5e8120;console[_0x387d7d('0x455')](_0x387d7d('0x2d3'));});}let _0x2e896e=!![],_0x4ff732=0x1;_0x2d53d0[_0x172a11('0xe83')](_0x172a11('0x12d8'),function(_0x170a67,_0x15be49){const _0x29cee0=_0x172a11;_0x2e896e?_0x4aa9ea(function(){_0x2e896e=![];}):(!_0x15be49&&(_0x4ff732=_0x273d47['query'][_0x29cee0('0x1a43')]),_0x170a67!==_0x15be49&&(_0x273d47[_0x29cee0('0x2218')][_0x29cee0('0x1a43')]=0x1),!_0x170a67&&(_0x273d47[_0x29cee0('0x2218')][_0x29cee0('0x1a43')]=_0x4ff732),_0x273d47['getMetrics']());});function _0x123e6c(_0x17b924){const _0x3714c5=_0x172a11;_0x273d47[_0x3714c5('0x15d3')]=_0x17b924||{'count':0x0,'rows':[]};}function _0x43b126(){const _0x338975=_0x172a11;_0x273d47[_0x338975('0x2218')][_0x338975('0x1098')]=(_0x273d47[_0x338975('0x2218')][_0x338975('0x1a43')]-0x1)*_0x273d47[_0x338975('0x2218')][_0x338975('0x163f')],_0x2411e3[_0x338975('0x1ac6')](_0x338975('0xa7c'))?_0x273d47['promise']=_0x327bd5[_0x338975('0x2e8')]['get'](_0x273d47[_0x338975('0x2218')],_0x123e6c)[_0x338975('0xa44')]:(_0x273d47[_0x338975('0x2218')]['id']=_0x273d47[_0x338975('0x7f')]['id'],_0x273d47['query'][_0x338975('0xe60')]=_0x338975('0x27ed'),_0x273d47[_0x338975('0x1f48')]=_0x327bd5[_0x338975('0x7f')][_0x338975('0x263a')](_0x273d47[_0x338975('0x2218')],_0x123e6c)['$promise']);}function _0x4ef2a3(_0x4f3225,_0x5efbaf){const _0x3c5d8e=_0x172a11;_0x5d57a4[_0x3c5d8e('0x1f80')]({'controller':_0x3c5d8e('0x1393'),'controllerAs':'vm','templateUrl':_0x34bf13,'parent':angular['element'](_0x788c2d[_0x3c5d8e('0x8d2')]),'targetEvent':_0x4f3225,'clickOutsideToClose':!![],'locals':{'metric':_0x5efbaf,'metrics':_0x273d47['metrics'][_0x3c5d8e('0x269a')],'license':_0x273d47[_0x3c5d8e('0x5c9')],'setting':_0x273d47[_0x3c5d8e('0xf8a')],'crudPermissions':_0x273d47['crudPermissions']}});}function _0x2fac8b(_0x55bd72){const _0x4942cd=_0x172a11;_0x327bd5[_0x4942cd('0x2e8')]['delete']({'id':_0x55bd72['id']})[_0x4942cd('0xa44')][_0x4942cd('0x1166')](function(){const _0x17a8dc=_0x4942cd;_0x2cfb05()[_0x17a8dc('0x127f')](_0x273d47['metrics']['rows'],{'id':_0x55bd72['id']}),_0x273d47[_0x17a8dc('0x15d3')][_0x17a8dc('0x240f')]-=0x1,!_0x273d47[_0x17a8dc('0x15d3')][_0x17a8dc('0x269a')][_0x17a8dc('0x264b')]&&_0x273d47[_0x17a8dc('0x44a')](),_0x5509f5[_0x17a8dc('0x103b')]({'title':_0x2cfb05()[_0x17a8dc('0xb35')](_0x17a8dc('0x2873'))+'\x20deleted!','msg':_0x55bd72[_0x17a8dc('0x4f0')]?_0x55bd72[_0x17a8dc('0x4f0')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x32626f){const _0x2879c7=_0x4942cd;if(_0x32626f[_0x2879c7('0x25f4')]&&_0x32626f[_0x2879c7('0x25f4')][_0x2879c7('0x61a')]&&_0x32626f[_0x2879c7('0x25f4')][_0x2879c7('0x61a')][_0x2879c7('0x264b')]){_0x273d47[_0x2879c7('0x61a')]=_0x32626f[_0x2879c7('0x25f4')][_0x2879c7('0x61a')]||[{'message':_0x32626f['toString'](),'type':'SYSTEM:DELETEanalyticMetric'}];for(let _0x381a10=0x0;_0x381a10<_0x32626f['data'][_0x2879c7('0x61a')][_0x2879c7('0x264b')];_0x381a10++){_0x5509f5[_0x2879c7('0xfc9')]({'title':_0x32626f[_0x2879c7('0x25f4')][_0x2879c7('0x61a')][_0x381a10][_0x2879c7('0x1345')],'msg':_0x32626f[_0x2879c7('0x25f4')][_0x2879c7('0x61a')][_0x381a10][_0x2879c7('0x1e70')]});}}else _0x5509f5[_0x2879c7('0xfc9')]({'title':_0x32626f[_0x2879c7('0x52d')]?_0x2879c7('0x1e21')+_0x32626f[_0x2879c7('0x52d')]+_0x2879c7('0x11e1')+_0x32626f[_0x2879c7('0xe1b')]:_0x2879c7('0x16ea'),'msg':_0x32626f[_0x2879c7('0x25f4')]?JSON[_0x2879c7('0xbac')](_0x32626f['data'][_0x2879c7('0x1e70')]):_0x32626f['message']||_0x32626f['toString']()});});}function _0x3f79ea(){const _0x462a2e=_0x172a11,_0x5632f0=angular[_0x462a2e('0x225f')](_0x273d47['selectedMetrics']);return _0x273d47[_0x462a2e('0x2f')]=[],_0x5632f0;}function _0x1501e8(_0x3d85a6){const _0x9415be=_0x172a11,_0xc9a581=_0x5d57a4[_0x9415be('0x1d26')]()[_0x9415be('0xcdc')](_0x9415be('0x260b'))[_0x9415be('0xf3c')](_0x9415be('0x12b5')+_0x273d47['selectedMetrics'][_0x9415be('0x264b')]+_0x9415be('0x196d')+_0x9415be('0x3f3'))['ariaLabel'](_0x9415be('0x1191'))[_0x9415be('0x203b')](_0x3d85a6)['ok']('OK')[_0x9415be('0x3f')](_0x9415be('0x2d3'));_0x5d57a4[_0x9415be('0x1f80')](_0xc9a581)[_0x9415be('0x1166')](function(){const _0x44c8b2=_0x9415be;_0x273d47['selectedMetrics'][_0x44c8b2('0x2782')](function(_0x427fd8){_0x2fac8b(_0x427fd8);}),_0x273d47[_0x44c8b2('0x2f')]=[];});}function _0x2234c8(){const _0x59760b=_0x172a11;_0x273d47[_0x59760b('0x2f')]=[];}function _0x3af4bd(){const _0x591e87=_0x172a11;_0x273d47[_0x591e87('0x2f')]=_0x273d47[_0x591e87('0x15d3')]['rows'];}}const _0x14f748=_0x570eb3;_0x52025a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x52025a(_0x141962,_0x2dd4f6){const _0x2a8d9c=_0x36e6f4;_0x141962[_0x2a8d9c('0x63f')]('app.analytics',{'abstract':!![],'url':_0x2a8d9c('0x1a6b')})['state']('app.analytics.metrics',{'url':_0x2a8d9c('0xe0e'),'views':{'content@app':{'templateUrl':_0x363a05,'controller':'MetricsController\x20as\x20vm'}},'resolve':{'metrics':[_0x2a8d9c('0x1fbc'),_0x2a8d9c('0x21ef'),function(_0x30cc82,_0x44a30a){const _0x1a69a4=_0x2a8d9c;return _0x44a30a[_0x1a69a4('0x1ac6')](_0x1a69a4('0xa7c'))?_0x30cc82['resolve'](_0x1a69a4('0x27cc'),{'fields':_0x1a69a4('0x20df'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x30cc82['resolve']('userProfile@getResources',{'id':_0x44a30a[_0x1a69a4('0x26cd')]()[_0x1a69a4('0xb86')],'section':_0x1a69a4('0x27ed'),'fields':_0x1a69a4('0x20df'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x2a8d9c('0x21ef'),function(_0x3bfdb6,_0x402c23){const _0x22ec1c=_0x2a8d9c;return _0x402c23[_0x22ec1c('0x1ac6')](_0x22ec1c('0xa7c'))?null:_0x3bfdb6[_0x22ec1c('0x18af')](_0x22ec1c('0x697'),{'fields':_0x22ec1c('0x686'),'id':_0x402c23[_0x22ec1c('0x26cd')]()[_0x22ec1c('0xb86')]});}],'userProfileSection':[_0x2a8d9c('0x1fbc'),_0x2a8d9c('0x21ef'),function(_0x222cdf,_0x3922d2){const _0x4e5dd8=_0x2a8d9c;return _0x3922d2['hasRole'](_0x4e5dd8('0xa7c'))?null:_0x222cdf['resolve'](_0x4e5dd8('0xaf'),{'fields':_0x4e5dd8('0xe26'),'userProfileId':_0x3922d2[_0x4e5dd8('0x26cd')]()[_0x4e5dd8('0xb86')],'sectionId':0x4b1});}]},'authenticate':!![],'permissionId':0x4b1,'bodyClass':_0x2a8d9c('0x18cc')})[_0x2a8d9c('0x63f')]('app.analytics.extractedReports',{'url':_0x2a8d9c('0x27a6'),'views':{'content@app':{'templateUrl':_0x1f86a6,'controller':_0x2a8d9c('0x2c0')}},'resolve':{'extractedReports':[_0x2a8d9c('0x1fbc'),'Auth',function(_0x343955,_0x2fbe85){const _0x30b217=_0x2a8d9c;return _0x2fbe85['hasRole'](_0x30b217('0xa7c'))?_0x343955[_0x30b217('0x18af')](_0x30b217('0xee9'),{'fields':_0x30b217('0x1897'),'sort':_0x30b217('0x14dc'),'limit':0xa,'offset':0x0}):_0x343955[_0x30b217('0x18af')]('userProfile@getResources',{'id':_0x2fbe85[_0x30b217('0x26cd')]()[_0x30b217('0xb86')],'section':_0x30b217('0x1e5a'),'fields':_0x30b217('0x1897'),'sort':_0x30b217('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x2a8d9c('0x1fbc'),'Auth',function(_0x5d5615,_0x450bd7){const _0x3ea6ee=_0x2a8d9c;return _0x450bd7[_0x3ea6ee('0x1ac6')](_0x3ea6ee('0xa7c'))?null:_0x5d5615[_0x3ea6ee('0x18af')](_0x3ea6ee('0x697'),{'fields':_0x3ea6ee('0x686'),'id':_0x450bd7[_0x3ea6ee('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x2a8d9c('0x1fbc'),'Auth',function(_0x484dbd,_0x1a14af){const _0x48c5e3=_0x2a8d9c;return _0x1a14af[_0x48c5e3('0x1ac6')](_0x48c5e3('0xa7c'))?null:_0x484dbd[_0x48c5e3('0x18af')](_0x48c5e3('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x1a14af['getCurrentUser']()[_0x48c5e3('0xb86')],'sectionId':0x4b2});}]},'authenticate':!![],'permissionId':0x4b2,'bodyClass':_0x2a8d9c('0x18cc')}),_0x2dd4f6[_0x2a8d9c('0x95e')](_0x2a8d9c('0xcf'));}angular[_0x36e6f4('0x896')]('app.analytics',[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),'ckeditor',_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),'mwFormBuilder',_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),'ngclipboard',_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),_0x36e6f4('0x1fe2')])[_0x36e6f4('0xe11')](_0x52025a)[_0x36e6f4('0x75e')](_0x36e6f4('0x1729'),_0x357083)[_0x36e6f4('0x75e')](_0x36e6f4('0x1eb5'),_0x3da683)[_0x36e6f4('0x75e')](_0x36e6f4('0x1393'),_0x437b9d)[_0x36e6f4('0x75e')](_0x36e6f4('0x1bb5'),_0x14f748);const _0x2fe933=_0x2734b2['p']+_0x36e6f4('0x1a81'),_0x55409b=_0x2734b2['p']+_0x36e6f4('0x11b'),_0x26f42a=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/salesforceAccounts/salesforceAccounts.html/salesforceAccounts.html',_0x4caa85=_0x2734b2['p']+_0x36e6f4('0x454'),_0x433034=_0x2734b2['p']+_0x36e6f4('0x23db'),_0x1748f2=_0x2734b2['p']+_0x36e6f4('0x20fe'),_0x39b6e7=_0x2734b2['p']+_0x36e6f4('0x8ab'),_0x1f27d8=_0x2734b2['p']+_0x36e6f4('0x1ffc'),_0x361374=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/deskAccounts/deskAccounts.html/deskAccounts.html',_0xe5228b=_0x2734b2['p']+_0x36e6f4('0x1de0'),_0x986222=_0x2734b2['p']+_0x36e6f4('0x2705'),_0x267433=_0x2734b2['p']+_0x36e6f4('0xf76'),_0x1acc07=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/vtigerAccounts/vtigerAccounts.html/vtigerAccounts.html',_0x2b8972=_0x2734b2['p']+_0x36e6f4('0x91a'),_0x27b509=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/dynamics365Accounts/dynamics365Accounts.html/dynamics365Accounts.html',_0x292cfe=_0x2734b2['p']+_0x36e6f4('0xe08'),_0x2720ba=_0x2734b2['p']+_0x36e6f4('0x1ff'),_0x55025f=_0x2734b2['p']+_0x36e6f4('0x1cd3'),_0x5ba063=_0x2734b2['p']+_0x36e6f4('0xae8'),_0x2f3eab=_0x2734b2['p']+_0x36e6f4('0xddf');_0x2a2787[_0x36e6f4('0x1294')]=['$scope','$state',_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x148d'),_0x36e6f4('0x1d57'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x2a2787(_0x4a6259,_0x3bb31f,_0x6c9620,_0x4b4bee,_0x24436e,_0x410254,_0x1530fd,_0xb7347d,_0x337b7a,_0x52370a,_0x2b2903,_0x2d410f,_0x4320ea,_0x1c47e1){const _0x2d04d9=_0x36e6f4,_0x2e96d3=this;_0x2e96d3[_0x2d04d9('0x98')]=_0x2b2903[_0x2d04d9('0x26cd')](),_0x2e96d3[_0x2d04d9('0x61a')]=[],_0x2e96d3[_0x2d04d9('0xf8a')]=_0x4320ea,_0x2e96d3[_0x2d04d9('0x5c9')]=_0x2d410f,_0x2e96d3[_0x2d04d9('0x243c')]=_0x1c47e1,_0x2e96d3[_0x2d04d9('0x128b')]={},_0x2e96d3[_0x2d04d9('0x2900')]=_0x2e96d3['setting']&&_0x2e96d3[_0x2d04d9('0xf8a')][_0x2d04d9('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2e96d3[_0x2d04d9('0xcdc')]='INTEGRATIONS.EDIT_DESKACCOUNT',_0x2e96d3[_0x2d04d9('0x1d57')]=angular['copy'](_0x337b7a),_0x2e96d3[_0x2d04d9('0x148d')]=_0xb7347d,_0x2e96d3['newDeskAccount']=![];!_0x2e96d3[_0x2d04d9('0x1d57')]&&(_0x2e96d3['deskAccount']={'type':_0x2d04d9('0x73a'),'authType':_0x2d04d9('0x2d1'),'serverUrl':_0x6c9620['protocol']()+'://'+_0x6c9620[_0x2d04d9('0x1690')]()+(_0x6c9620['port']()?':'+_0x6c9620[_0x2d04d9('0x93d')]():'')},_0x2e96d3[_0x2d04d9('0xcdc')]=_0x2d04d9('0x87e'),_0x2e96d3[_0x2d04d9('0x16d7')]=!![]);_0x2e96d3[_0x2d04d9('0x1a66')]=_0x1ca189,_0x2e96d3['saveDeskAccount']=_0x2091d5,_0x2e96d3[_0x2d04d9('0x267')]=_0x20f82b,_0x2e96d3[_0x2d04d9('0x1a9c')]=_0x4edbd7,_0x2e96d3[_0x2d04d9('0x24a0')]=_0x4172e4;function _0x1ca189(){const _0x13fce2=_0x2d04d9;_0x2e96d3[_0x13fce2('0x61a')]=[],_0x52370a[_0x13fce2('0x1db9')][_0x13fce2('0x9cc')](_0x2e96d3['deskAccount'])[_0x13fce2('0xa44')][_0x13fce2('0x1166')](function(_0x21e0ed){const _0xcdee49=_0x13fce2;_0x2e96d3[_0xcdee49('0x148d')]['unshift'](_0x21e0ed[_0xcdee49('0x2876')]()),_0x1530fd[_0xcdee49('0x103b')]({'title':_0xcdee49('0x1682'),'msg':_0x2e96d3[_0xcdee49('0x1d57')]['name']?_0x2e96d3[_0xcdee49('0x1d57')][_0xcdee49('0x4f0')]+_0xcdee49('0x1eda'):''}),_0x4172e4(_0x21e0ed);})[_0x13fce2('0x1a80')](function(_0x1b7c45){const _0x390623=_0x13fce2;if(_0x1b7c45[_0x390623('0x25f4')]&&_0x1b7c45[_0x390623('0x25f4')][_0x390623('0x61a')]&&_0x1b7c45[_0x390623('0x25f4')][_0x390623('0x61a')][_0x390623('0x264b')]){_0x2e96d3[_0x390623('0x61a')]=_0x1b7c45[_0x390623('0x25f4')]['errors']||[{'message':_0x1b7c45[_0x390623('0x1586')](),'type':_0x390623('0x1592')}];for(let _0x36db20=0x0;_0x36db20<_0x1b7c45[_0x390623('0x25f4')][_0x390623('0x61a')][_0x390623('0x264b')];_0x36db20+=0x1){_0x1530fd['error']({'title':_0x1b7c45[_0x390623('0x25f4')][_0x390623('0x61a')][_0x36db20]['type'],'msg':_0x1b7c45[_0x390623('0x25f4')][_0x390623('0x61a')][_0x36db20]['message']});}}else _0x1530fd['error']({'title':_0x1b7c45['status']?_0x390623('0x1e21')+_0x1b7c45[_0x390623('0x52d')]+_0x390623('0x11e1')+_0x1b7c45[_0x390623('0xe1b')]:_0x390623('0x1592'),'msg':_0x1b7c45[_0x390623('0x25f4')]?JSON[_0x390623('0xbac')](_0x1b7c45[_0x390623('0x25f4')][_0x390623('0x1e70')]):_0x1b7c45[_0x390623('0x1586')]()});});}function _0x2091d5(){const _0x4ee423=_0x2d04d9;_0x2e96d3[_0x4ee423('0x61a')]=[],_0x52370a[_0x4ee423('0x1db9')][_0x4ee423('0x1449')]({'id':_0x2e96d3['deskAccount']['id']},_0x2e96d3['deskAccount'])[_0x4ee423('0xa44')][_0x4ee423('0x1166')](function(_0x4c1dc9){const _0x37e01a=_0x4ee423,_0x3c8d53=_0x2cfb05()[_0x37e01a('0xc38')](_0x2e96d3[_0x37e01a('0x148d')],{'id':_0x4c1dc9['id']});_0x3c8d53&&_0x2cfb05()[_0x37e01a('0xcc3')](_0x3c8d53,_0x2cfb05()['pick'](_0x4c1dc9['toJSON'](),_0x2cfb05()[_0x37e01a('0x14a4')](_0x3c8d53))),_0x1530fd[_0x37e01a('0x103b')]({'title':_0x37e01a('0x1688'),'msg':_0x2e96d3[_0x37e01a('0x1d57')][_0x37e01a('0x4f0')]?_0x2e96d3['deskAccount']['name']+_0x37e01a('0x7d'):''}),_0x4172e4(_0x4c1dc9);})[_0x4ee423('0x1a80')](function(_0x5e4f82){const _0x304a3a=_0x4ee423;if(_0x5e4f82['data']&&_0x5e4f82[_0x304a3a('0x25f4')]['errors']&&_0x5e4f82[_0x304a3a('0x25f4')][_0x304a3a('0x61a')][_0x304a3a('0x264b')]){_0x2e96d3['errors']=_0x5e4f82[_0x304a3a('0x25f4')][_0x304a3a('0x61a')]||[{'message':_0x5e4f82[_0x304a3a('0x1586')](),'type':_0x304a3a('0x1875')}];for(let _0x36855b=0x0;_0x36855b<_0x5e4f82[_0x304a3a('0x25f4')]['errors'][_0x304a3a('0x264b')];_0x36855b++){_0x1530fd[_0x304a3a('0xfc9')]({'title':_0x5e4f82['data'][_0x304a3a('0x61a')][_0x36855b][_0x304a3a('0x1345')],'msg':_0x5e4f82[_0x304a3a('0x25f4')][_0x304a3a('0x61a')][_0x36855b]['message']});}}else _0x1530fd[_0x304a3a('0xfc9')]({'title':_0x5e4f82['status']?_0x304a3a('0x1e21')+_0x5e4f82['status']+_0x304a3a('0x11e1')+_0x5e4f82[_0x304a3a('0xe1b')]:'api.intDeskAccount.update','msg':_0x5e4f82['data']?JSON[_0x304a3a('0xbac')](_0x5e4f82[_0x304a3a('0x25f4')][_0x304a3a('0x1e70')]):_0x5e4f82[_0x304a3a('0x1586')]()});});}function _0x20f82b(_0x301a3b){const _0x4f05b1=_0x2d04d9;_0x2e96d3[_0x4f05b1('0x61a')]=[];const _0x38deb7=_0x4b4bee['confirm']()[_0x4f05b1('0xcdc')](_0x4f05b1('0x7fb'))[_0x4f05b1('0xacc')](_0x4f05b1('0x2287'))[_0x4f05b1('0x8e8')](_0x4f05b1('0x234e'))['ok'](_0x4f05b1('0x18'))['cancel'](_0x4f05b1('0x497'))[_0x4f05b1('0x203b')](_0x301a3b);_0x4b4bee[_0x4f05b1('0x1f80')](_0x38deb7)[_0x4f05b1('0x1166')](function(){const _0x331729=_0x4f05b1;_0x52370a['intDeskAccount'][_0x331729('0x906')]({'id':_0x2e96d3[_0x331729('0x1d57')]['id']})[_0x331729('0xa44')][_0x331729('0x1166')](function(){const _0x885b0f=_0x331729;_0x2cfb05()['remove'](_0x2e96d3['deskAccounts'],{'id':_0x2e96d3[_0x885b0f('0x1d57')]['id']}),_0x1530fd[_0x885b0f('0x103b')]({'title':_0x885b0f('0x17bb'),'msg':(_0x2e96d3[_0x885b0f('0x1d57')][_0x885b0f('0x4f0')]||_0x885b0f('0x1d57'))+_0x885b0f('0x7cd')}),_0x4172e4(_0x2e96d3[_0x885b0f('0x1d57')]);})[_0x331729('0x1a80')](function(_0x1f6ee9){const _0x5e45b6=_0x331729;if(_0x1f6ee9['data']&&_0x1f6ee9[_0x5e45b6('0x25f4')][_0x5e45b6('0x61a')]&&_0x1f6ee9[_0x5e45b6('0x25f4')][_0x5e45b6('0x61a')]['length']){_0x2e96d3['errors']=_0x1f6ee9['data'][_0x5e45b6('0x61a')]||[{'message':_0x1f6ee9[_0x5e45b6('0x1586')](),'type':_0x5e45b6('0x231')}];for(let _0x103126=0x0;_0x103126<_0x1f6ee9[_0x5e45b6('0x25f4')][_0x5e45b6('0x61a')][_0x5e45b6('0x264b')];_0x103126++){_0x1530fd[_0x5e45b6('0xfc9')]({'title':_0x1f6ee9[_0x5e45b6('0x25f4')][_0x5e45b6('0x61a')][_0x103126][_0x5e45b6('0x1345')],'msg':_0x1f6ee9[_0x5e45b6('0x25f4')][_0x5e45b6('0x61a')][_0x103126][_0x5e45b6('0x1e70')]});}}else _0x1530fd[_0x5e45b6('0xfc9')]({'title':_0x1f6ee9[_0x5e45b6('0x52d')]?'API:'+_0x1f6ee9[_0x5e45b6('0x52d')]+_0x5e45b6('0x11e1')+_0x1f6ee9['statusText']:_0x5e45b6('0x231'),'msg':_0x1f6ee9[_0x5e45b6('0x25f4')]?JSON[_0x5e45b6('0xbac')](_0x1f6ee9[_0x5e45b6('0x25f4')][_0x5e45b6('0x1e70')]):_0x1f6ee9[_0x5e45b6('0x1e70')]||_0x1f6ee9[_0x5e45b6('0x1586')]()});});},function(){});}function _0x4edbd7(_0x548795){return _0x548795===null?undefined:new Date(_0x548795);}function _0x4172e4(_0x194519){const _0x4256e8=_0x2d04d9;_0x4b4bee[_0x4256e8('0x1197')](_0x194519);}}const _0x539d72=_0x2a2787,_0x3d6922=_0x2734b2['p']+_0x36e6f4('0x48');_0x5f09f4['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),'$mdDialog',_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x148d'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting'];function _0x5f09f4(_0xa454fb,_0x13684d,_0x343e14,_0x1022b2,_0x34c4d8,_0x1de36a,_0x3a82f2,_0x3f957b,_0x5b0e18,_0x206e38,_0x44943e,_0x414477,_0x3f733d,_0x4ca858,_0x596f33,_0x11c554,_0x49358d){const _0x33d964=_0x36e6f4,_0xcacdc2=this;_0xcacdc2['license']=_0x11c554,_0xcacdc2[_0x33d964('0xf8a')]=_0x49358d,_0xcacdc2[_0x33d964('0x98')]=_0x596f33['getCurrentUser'](),_0xcacdc2[_0x33d964('0x148d')]=_0x5b0e18||{'count':0x0,'rows':[]},_0xcacdc2[_0x33d964('0x7f')]=_0x206e38,_0xcacdc2[_0x33d964('0x17aa')]=_0x44943e&&_0x44943e[_0x33d964('0x240f')]==0x1?_0x44943e[_0x33d964('0x269a')][0x0]:null,_0xcacdc2[_0x33d964('0x243c')]=_0x596f33['parseCrudPermissions'](_0xcacdc2[_0x33d964('0x17aa')]?_0xcacdc2[_0x33d964('0x17aa')][_0x33d964('0x243c')]:null),_0xcacdc2['table']='deskAccounts',_0xcacdc2[_0x33d964('0xef5')]='',_0xcacdc2[_0x33d964('0x104c')]=null,_0xcacdc2[_0x33d964('0x2626')]=[],_0xcacdc2[_0x33d964('0x2218')]={'fields':'createdAt,updatedAt,id,name,type,remoteUri,authType,username,password,serverUrl,description','limit':0xa,'page':0x1},_0xcacdc2['arraytype']=_0x2cfb05()[_0x33d964('0x155c')]([{'option':_0x33d964('0x40b'),'value':_0x33d964('0x2496')},{'option':'New_Tab','value':_0x33d964('0x137e')}],function(_0x39319e){const _0x4e8ab1=_0x33d964;return _0x2cfb05()[_0x4e8ab1('0xf3')](_0x39319e[_0x4e8ab1('0x18e0')],new RegExp('\x27','g'),'');}),_0xcacdc2['arrayauthType']=_0x2cfb05()[_0x33d964('0x155c')]([{'option':_0x33d964('0x1265'),'value':_0x33d964('0x825')}],function(_0x2cc2c1){const _0x16d718=_0x33d964;return _0x2cfb05()[_0x16d718('0xf3')](_0x2cc2c1['value'],new RegExp('\x27','g'),'');}),_0xcacdc2[_0x33d964('0x1ff6')]=_0x570078,_0xcacdc2[_0x33d964('0x2113')]=_0x58a869,_0xcacdc2['deleteconfirm']=_0x5a4809,_0xcacdc2[_0x33d964('0x103b')]=_0x25aebb,_0xcacdc2[_0x33d964('0x2171')]=_0x3c8586,_0xcacdc2[_0x33d964('0x1777')]=_0x2159ca,_0xcacdc2['deleteDeskAccount']=_0x3d11c3,_0xcacdc2[_0x33d964('0x1acb')]=_0x40734e,_0xcacdc2[_0x33d964('0x7d3')]=_0x3ace8e,_0xcacdc2['deselectDeskAccounts']=_0x5404f7,_0xcacdc2[_0x33d964('0x2768')]=_0x39a5cf;function _0x570078(_0x527c67){const _0x1d5c07=_0x33d964;_0x343e14['go'](_0x1d5c07('0x39b'),{'id':_0x527c67['id'],'deskAccount':_0x527c67,'crudPermissions':_0xcacdc2[_0x1d5c07('0x243c')]});}function _0x58a869(_0x2f6515){const _0x23421e=_0x33d964;return _0x414477['intDeskAccount'][_0x23421e('0x18ea')]({'id':_0x2f6515['id'],'test':!![]})[_0x23421e('0xa44')][_0x23421e('0x1166')](function(){_0x4ca858['success']({'title':'DeskAccount\x20properly\x20tested','msg':'Connection\x20succeded!'});})[_0x23421e('0x1a80')](function(_0x493c4f){const _0x1e7876=_0x23421e;_0x4ca858[_0x1e7876('0xfc9')]({'title':'DeskAccount\x20properly\x20tested','msg':_0x493c4f[_0x1e7876('0x25f4')]?_0x493c4f[_0x1e7876('0x25f4')]['message']?_0x493c4f[_0x1e7876('0x25f4')]['message']:JSON[_0x1e7876('0xbac')](_0x493c4f[_0x1e7876('0x25f4')]):_0x493c4f[_0x1e7876('0x1586')]()});});}function _0x5a4809(_0x25241f,_0x146b1b){const _0x321f56=_0x33d964,_0x5e39d3=_0x34c4d8[_0x321f56('0x1d26')]()[_0x321f56('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()['startCase'](_0x321f56('0x1d57'))+'?')['htmlContent'](_0x321f56('0x12b5')+(_0x25241f[_0x321f56('0x4f0')]||_0x321f56('0x1d57'))+''+_0x321f56('0x3f3'))[_0x321f56('0x8e8')]('delete\x20deskAccount')['targetEvent'](_0x146b1b)['ok']('OK')[_0x321f56('0x3f')](_0x321f56('0x2d3'));_0x34c4d8[_0x321f56('0x1f80')](_0x5e39d3)[_0x321f56('0x1166')](function(){_0x3d11c3(_0x25241f);},function(){console['log']('CANCEL');});}let _0xd07f71=!![],_0x57082f=0x1;_0xa454fb[_0x33d964('0xe83')](_0x33d964('0x12d8'),function(_0x5e972a,_0x17108f){const _0x523e61=_0x33d964;_0xd07f71?_0x3a82f2(function(){_0xd07f71=![];}):(!_0x17108f&&(_0x57082f=_0xcacdc2['query'][_0x523e61('0x1a43')]),_0x5e972a!==_0x17108f&&(_0xcacdc2[_0x523e61('0x2218')][_0x523e61('0x1a43')]=0x1),!_0x5e972a&&(_0xcacdc2['query'][_0x523e61('0x1a43')]=_0x57082f),_0xcacdc2[_0x523e61('0x2171')]());});function _0x25aebb(_0x188844){_0xcacdc2['deskAccounts']=_0x188844||{'count':0x0,'rows':[]};}function _0x3c8586(){const _0x284a1a=_0x33d964;_0xcacdc2['query'][_0x284a1a('0x1098')]=(_0xcacdc2[_0x284a1a('0x2218')][_0x284a1a('0x1a43')]-0x1)*_0xcacdc2[_0x284a1a('0x2218')]['limit'],_0x596f33[_0x284a1a('0x1ac6')]('admin')?_0xcacdc2[_0x284a1a('0x1f48')]=_0x414477['intDeskAccount'][_0x284a1a('0xd83')](_0xcacdc2['query'],_0x25aebb)[_0x284a1a('0xa44')]:(_0xcacdc2[_0x284a1a('0x2218')]['id']=_0xcacdc2['userProfile']['id'],_0xcacdc2[_0x284a1a('0x2218')][_0x284a1a('0xe60')]=_0x284a1a('0x3e1'),_0xcacdc2[_0x284a1a('0x1f48')]=_0x414477['userProfile'][_0x284a1a('0x263a')](_0xcacdc2['query'],_0x25aebb)[_0x284a1a('0xa44')]);}function _0x2159ca(_0x4e2902,_0x3e0e17){const _0x2a3a7e=_0x33d964;_0x34c4d8['show']({'controller':_0x2a3a7e('0x932'),'controllerAs':'vm','templateUrl':_0x3d6922,'parent':angular['element'](_0x1de36a[_0x2a3a7e('0x8d2')]),'targetEvent':_0x4e2902,'clickOutsideToClose':!![],'locals':{'deskAccount':_0x3e0e17,'deskAccounts':_0xcacdc2[_0x2a3a7e('0x148d')][_0x2a3a7e('0x269a')],'license':_0xcacdc2['license'],'setting':_0xcacdc2[_0x2a3a7e('0xf8a')],'crudPermissions':_0xcacdc2[_0x2a3a7e('0x243c')]}});}function _0x3d11c3(_0xbf95a3){const _0x5115ce=_0x33d964;_0x414477[_0x5115ce('0x1db9')][_0x5115ce('0x906')]({'id':_0xbf95a3['id']})[_0x5115ce('0xa44')][_0x5115ce('0x1166')](function(){const _0x3d07ab=_0x5115ce;_0x2cfb05()[_0x3d07ab('0x127f')](_0xcacdc2[_0x3d07ab('0x148d')][_0x3d07ab('0x269a')],{'id':_0xbf95a3['id']}),_0xcacdc2[_0x3d07ab('0x148d')][_0x3d07ab('0x240f')]-=0x1,!_0xcacdc2[_0x3d07ab('0x148d')]['rows'][_0x3d07ab('0x264b')]&&_0xcacdc2[_0x3d07ab('0x2171')](),_0x4ca858[_0x3d07ab('0x103b')]({'title':_0x2cfb05()[_0x3d07ab('0xb35')]('DeskAccount')+_0x3d07ab('0x2b6'),'msg':_0xbf95a3[_0x3d07ab('0x4f0')]?_0xbf95a3['name']+_0x3d07ab('0x7cd'):''});})[_0x5115ce('0x1a80')](function(_0x1a638b){const _0xa272d3=_0x5115ce;if(_0x1a638b[_0xa272d3('0x25f4')]&&_0x1a638b[_0xa272d3('0x25f4')][_0xa272d3('0x61a')]&&_0x1a638b[_0xa272d3('0x25f4')][_0xa272d3('0x61a')]['length']){_0xcacdc2[_0xa272d3('0x61a')]=_0x1a638b[_0xa272d3('0x25f4')]['errors']||[{'message':_0x1a638b[_0xa272d3('0x1586')](),'type':'SYSTEM:DELETEintDeskAccount'}];for(let _0x159e56=0x0;_0x159e56<_0x1a638b[_0xa272d3('0x25f4')][_0xa272d3('0x61a')][_0xa272d3('0x264b')];_0x159e56++){_0x4ca858['error']({'title':_0x1a638b['data'][_0xa272d3('0x61a')][_0x159e56]['type'],'msg':_0x1a638b['data'][_0xa272d3('0x61a')][_0x159e56][_0xa272d3('0x1e70')]});}}else _0x4ca858[_0xa272d3('0xfc9')]({'title':_0x1a638b['status']?_0xa272d3('0x1e21')+_0x1a638b[_0xa272d3('0x52d')]+_0xa272d3('0x11e1')+_0x1a638b[_0xa272d3('0xe1b')]:_0xa272d3('0x838'),'msg':_0x1a638b[_0xa272d3('0x25f4')]?JSON[_0xa272d3('0xbac')](_0x1a638b[_0xa272d3('0x25f4')][_0xa272d3('0x1e70')]):_0x1a638b['message']||_0x1a638b[_0xa272d3('0x1586')]()});});}function _0x40734e(){const _0xde1ff0=_0x33d964,_0x2ed4d1=angular['copy'](_0xcacdc2[_0xde1ff0('0x2626')]);return _0xcacdc2[_0xde1ff0('0x2626')]=[],_0x2ed4d1;}function _0x3ace8e(_0x32aa7){const _0x550a87=_0x33d964,_0x569e1c=_0x34c4d8[_0x550a87('0x1d26')]()[_0x550a87('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20deskAccounts?')[_0x550a87('0xf3c')](_0x550a87('0x12b5')+_0xcacdc2[_0x550a87('0x2626')][_0x550a87('0x264b')]+_0x550a87('0x196d')+_0x550a87('0x3f3'))[_0x550a87('0x8e8')](_0x550a87('0x112'))[_0x550a87('0x203b')](_0x32aa7)['ok']('OK')[_0x550a87('0x3f')]('CANCEL');_0x34c4d8[_0x550a87('0x1f80')](_0x569e1c)[_0x550a87('0x1166')](function(){const _0x4fe736=_0x550a87;_0xcacdc2[_0x4fe736('0x2626')][_0x4fe736('0x2782')](function(_0x2b9392){_0x3d11c3(_0x2b9392);}),_0xcacdc2[_0x4fe736('0x2626')]=[];});}function _0x5404f7(){_0xcacdc2['selectedDeskAccounts']=[];}function _0x39a5cf(){const _0xa0b975=_0x33d964;_0xcacdc2[_0xa0b975('0x2626')]=_0xcacdc2[_0xa0b975('0x148d')]['rows'];}}const _0x4bef10=_0x5f09f4,_0x242a05=_0x2734b2['p']+_0x36e6f4('0x15ac'),_0x52e785=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/deskAccounts/edit/item/dialog.html/dialog.html';_0x5ed37b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x5ed37b(_0x3b462c,_0x27e443,_0x56c9dc,_0x51c24d,_0x248100){const _0x4d6196=_0x36e6f4,_0x5444e9=this;_0x5444e9[_0x4d6196('0x98')]=_0x248100[_0x4d6196('0x26cd')](),_0x5444e9[_0x4d6196('0x1d57')]={},_0x5444e9[_0x4d6196('0x869')]={},_0x5444e9[_0x4d6196('0xd54')]=[],_0x5444e9[_0x4d6196('0x18b2')]=-0x1,_0x5444e9[_0x4d6196('0x243c')],_0x5444e9[_0x4d6196('0x24d5')]=_0x2f7285,_0x5444e9[_0x4d6196('0x1d5b')]=_0x3c0bf4,_0x5444e9[_0x4d6196('0x8a7')]=_0x12a585,_0x5444e9[_0x4d6196('0x26fc')]=_0x143fa0,_0x5444e9['selectedTags']=[],_0x5444e9['selectTagsChanged']=_0x57948d,_0x56c9dc[_0x4d6196('0x1446')][_0x4d6196('0xd83')]({'nolimit':!![],'sort':_0x4d6196('0x4f0')})['$promise'][_0x4d6196('0x1166')](function(_0xa12054){const _0x35dd07=_0x4d6196;_0x5444e9[_0x35dd07('0xb38')]=_0xa12054[_0x35dd07('0x269a')]?_0xa12054[_0x35dd07('0x269a')]:[];})[_0x4d6196('0x1a80')](function(_0x21461c){const _0x2fc4cb=_0x4d6196;_0x51c24d[_0x2fc4cb('0xfc9')]({'title':_0x21461c[_0x2fc4cb('0x52d')]?_0x2fc4cb('0x1e21')+_0x21461c[_0x2fc4cb('0x52d')]+_0x2fc4cb('0x11e1')+_0x21461c[_0x2fc4cb('0xe1b')]:_0x2fc4cb('0x2597'),'msg':_0x21461c[_0x2fc4cb('0x25f4')]?JSON['stringify'](_0x21461c['data']):_0x21461c[_0x2fc4cb('0x1586')]()});});function _0x57948d(){const _0xef58a8=_0x4d6196;_0x56c9dc[_0xef58a8('0x1768')][_0xef58a8('0x61b')]({'id':_0x5444e9[_0xef58a8('0x869')]['id'],'ids':_0x5444e9[_0xef58a8('0x1726')]})[_0xef58a8('0xa44')][_0xef58a8('0x1166')](function(){const _0x25d932=_0xef58a8;_0x51c24d[_0x25d932('0x103b')]({'title':_0x25d932('0x19e6'),'msg':_0x25d932('0x189')});})[_0xef58a8('0x1a80')](function(_0x3d5686){const _0x3d32b9=_0xef58a8;_0x51c24d[_0x3d32b9('0xfc9')]({'title':_0x3d5686[_0x3d32b9('0x52d')]?'API:'+_0x3d5686[_0x3d32b9('0x52d')]+_0x3d32b9('0x11e1')+_0x3d5686[_0x3d32b9('0xe1b')]:_0x3d32b9('0x8f0'),'msg':_0x3d5686['data']?JSON[_0x3d32b9('0xbac')](_0x3d5686[_0x3d32b9('0x25f4')]):_0x3d5686[_0x3d32b9('0x1586')]()});});}function _0x2f7285(_0x307b64,_0x5d183e){const _0x552790=_0x4d6196;_0x5444e9['deskAccount']=_0x307b64,_0x5444e9[_0x552790('0x243c')]=typeof _0x5d183e!=='undefined'?_0x5d183e:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x56c9dc[_0x552790('0x1db9')][_0x552790('0x13db')]({'id':_0x5444e9[_0x552790('0x1d57')]['id'],'sort':'-updatedAt'})[_0x552790('0xa44')][_0x552790('0x1166')](function(_0x13aeda){const _0xeb7518=_0x552790;return _0x5444e9[_0xeb7518('0xd54')]=_0x13aeda[_0xeb7518('0x269a')]?_0x13aeda[_0xeb7518('0x269a')]:[],_0x5444e9['configurations'][_0xeb7518('0x264b')]&&_0x5444e9[_0xeb7518('0x1d5b')](0x0),_0x56c9dc[_0xeb7518('0x734')]['get']({'nolimit':!![],'sort':_0xeb7518('0x4f0')})[_0xeb7518('0xa44')];})[_0x552790('0x1166')](function(_0x102165){const _0x15046b=_0x552790;_0x5444e9['variables']=_0x102165[_0x15046b('0x269a')]?_0x102165[_0x15046b('0x269a')]:[],_0x5444e9[_0x15046b('0x217a')]=_0x2cfb05()[_0x15046b('0x155c')](_0x5444e9[_0x15046b('0x57a')],'id');})[_0x552790('0x1a80')](function(_0x59d4db){const _0x3e3d7d=_0x552790;_0x51c24d[_0x3e3d7d('0xfc9')]({'title':_0x59d4db[_0x3e3d7d('0x52d')]?_0x3e3d7d('0x1e21')+_0x59d4db[_0x3e3d7d('0x52d')]+_0x3e3d7d('0x11e1')+_0x59d4db[_0x3e3d7d('0xe1b')]:'SYSTEM:GETCONFIGURATION','msg':_0x59d4db[_0x3e3d7d('0x25f4')]?JSON['stringify'](_0x59d4db[_0x3e3d7d('0x25f4')]):_0x59d4db['toString']()});});}function _0x3c0bf4(_0x21effa){const _0x4e113c=_0x4d6196;_0x5444e9['deskConfiguration']=_0x5444e9[_0x4e113c('0xd54')][_0x21effa],_0x5444e9[_0x4e113c('0x18b2')]=_0x21effa,_0x56c9dc[_0x4e113c('0x1768')][_0x4e113c('0x154d')]({'id':_0x5444e9['deskConfiguration']['id']})['$promise'][_0x4e113c('0x1166')](function(_0x219cb9){const _0x4a39ff=_0x4e113c;return _0x5444e9[_0x4a39ff('0x2701')]=_0x219cb9['rows']?_0x219cb9['rows']:[],_0x56c9dc[_0x4a39ff('0x1768')][_0x4a39ff('0x28d4')]({'id':_0x5444e9[_0x4a39ff('0x869')]['id']})['$promise'];})[_0x4e113c('0x1166')](function(_0x1bdc42){const _0x5eba7b=_0x4e113c;return _0x5444e9[_0x5eba7b('0x1b3d')]=_0x1bdc42[_0x5eba7b('0x269a')]?_0x1bdc42['rows']:[],_0x56c9dc[_0x5eba7b('0x1768')][_0x5eba7b('0x18ea')]({'id':_0x5444e9['deskConfiguration']['id']})['$promise'];})[_0x4e113c('0x1166')](function(_0x4de2a7){const _0x9fa920=_0x4e113c;_0x5444e9['fields']=_0x4de2a7[_0x9fa920('0x269a')]?_0x4de2a7[_0x9fa920('0x269a')]:[];})['catch'](function(_0x59e829){const _0x528a7d=_0x4e113c;_0x51c24d[_0x528a7d('0xfc9')]({'title':_0x59e829[_0x528a7d('0x52d')]?_0x528a7d('0x1e21')+_0x59e829[_0x528a7d('0x52d')]+_0x528a7d('0x11e1')+_0x59e829[_0x528a7d('0xe1b')]:_0x528a7d('0x16c7'),'msg':_0x59e829['data']?JSON[_0x528a7d('0xbac')](_0x59e829[_0x528a7d('0x25f4')]):_0x59e829[_0x528a7d('0x1586')]()});}),_0x56c9dc['intDeskConfiguration']['getTags']({'id':_0x5444e9[_0x4e113c('0x869')]['id']})[_0x4e113c('0xa44')][_0x4e113c('0x1166')](function(_0xfb223e){const _0x46221f=_0x4e113c;_0x5444e9[_0x46221f('0x1726')]=_0xfb223e[_0x46221f('0x269a')]?_0x2cfb05()['map'](_0xfb223e[_0x46221f('0x269a')],'id'):[];})[_0x4e113c('0x1a80')](function(_0x5a6500){const _0xe7b81a=_0x4e113c;_0x51c24d['error']({'title':_0x5a6500[_0xe7b81a('0x52d')]?_0xe7b81a('0x1e21')+_0x5a6500[_0xe7b81a('0x52d')]+_0xe7b81a('0x11e1')+_0x5a6500[_0xe7b81a('0xe1b')]:_0xe7b81a('0x2597'),'msg':_0x5a6500[_0xe7b81a('0x25f4')]?JSON[_0xe7b81a('0xbac')](_0x5a6500[_0xe7b81a('0x25f4')]):_0x5a6500['toString']()});});}function _0x12a585(_0x1fd5be,_0x1620e9){const _0x2ca812=_0x4d6196;_0x3b462c[_0x2ca812('0x1f80')]({'controller':_0x2ca812('0x1bbb'),'controllerAs':'vm','templateUrl':_0x242a05,'parent':angular['element'](_0x27e443[_0x2ca812('0x8d2')]),'targetEvent':_0x1fd5be,'clickOutsideToClose':!![],'locals':{'deskConfiguration':_0x1620e9,'configurations':_0x5444e9[_0x2ca812('0xd54')],'license':null,'setting':null,'crudPermissions':_0x5444e9['crudPermissions']}})[_0x2ca812('0x1951')](function(){_0x5444e9['getDeskConfiguration'](0x0);});}function _0x143fa0(_0x583ce7,_0x310547){const _0xe61654=_0x4d6196,_0xc63f3d=_0x3b462c[_0xe61654('0x1d26')]()[_0xe61654('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20deskConfiguration?')['htmlContent'](''+(_0x310547[_0xe61654('0x4f0')]||_0xe61654('0x869'))+_0xe61654('0xace')+_0xe61654('0x3f3'))[_0xe61654('0x8e8')]('delete\x20deskConfiguration')[_0xe61654('0x203b')](_0x583ce7)['ok']('OK')[_0xe61654('0x3f')](_0xe61654('0x2d3'));_0x3b462c[_0xe61654('0x1f80')](_0xc63f3d)[_0xe61654('0x1166')](function(){const _0x2f48f7=_0xe61654;_0x56c9dc[_0x2f48f7('0x1768')]['delete']({'id':_0x310547['id']})['$promise'][_0x2f48f7('0x1166')](function(){const _0x1bc538=_0x2f48f7;_0x2cfb05()[_0x1bc538('0x127f')](_0x5444e9['configurations'],{'id':_0x310547['id']}),_0x51c24d['success']({'title':_0x1bc538('0x27cd'),'msg':_0x310547[_0x1bc538('0x4f0')]?_0x310547[_0x1bc538('0x4f0')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x90f564){const _0x7cd551=_0x2f48f7;_0x51c24d['error']({'title':_0x90f564[_0x7cd551('0x52d')]?_0x7cd551('0x1e21')+_0x90f564[_0x7cd551('0x52d')]+_0x7cd551('0x11e1')+_0x90f564['statusText']:_0x7cd551('0x19a8'),'msg':_0x90f564[_0x7cd551('0x25f4')]?JSON[_0x7cd551('0xbac')](_0x90f564[_0x7cd551('0x25f4')]):_0x90f564[_0x7cd551('0x1586')]()});})[_0x2f48f7('0x1951')](function(){const _0x2c260d=_0x2f48f7;_0x5444e9[_0x2c260d('0x1d5b')](0x0);});},function(){const _0x780b60=_0xe61654;console[_0x780b60('0x455')](_0x780b60('0x2d3'));});}_0x5444e9[_0x4d6196('0xd02')]=[],_0x5444e9[_0x4d6196('0x1a33')]=_0x5b53a5,_0x5444e9['deleteSubjectConfirm']=_0x45cd8f,_0x5444e9[_0x4d6196('0xeff')]=_0x4722db;function _0x5b53a5(_0x5ba7e1,_0x5076be){const _0x1f7b23=_0x4d6196;_0x3b462c[_0x1f7b23('0x1f80')]({'controller':_0x1f7b23('0x59c'),'controllerAs':'vm','templateUrl':_0x52e785,'parent':angular[_0x1f7b23('0x1194')](_0x27e443[_0x1f7b23('0x8d2')]),'targetEvent':_0x5ba7e1,'clickOutsideToClose':!![],'locals':{'type':_0x1f7b23('0x210d'),'item':_0x5076be,'items':_0x5444e9[_0x1f7b23('0x2701')],'configuration':_0x5444e9['deskConfiguration'],'account':_0x5444e9[_0x1f7b23('0x1d57')],'license':null,'setting':null,'crudPermissions':_0x5444e9[_0x1f7b23('0x243c')]}});}function _0x438a6e(_0x43447a){const _0x5e113c=_0x4d6196;_0x56c9dc[_0x5e113c('0xf9b')][_0x5e113c('0x906')]({'id':_0x43447a['id']})[_0x5e113c('0xa44')][_0x5e113c('0x1166')](function(){const _0x129040=_0x5e113c;_0x2cfb05()[_0x129040('0x127f')](_0x5444e9[_0x129040('0x2701')],{'id':_0x43447a['id']}),_0x51c24d[_0x129040('0x103b')]({'title':_0x129040('0x6f'),'msg':_0x129040('0x259f')});})[_0x5e113c('0x1a80')](function(_0x1c2bba){const _0x3f3d05=_0x5e113c;_0x51c24d['error']({'title':_0x1c2bba[_0x3f3d05('0x52d')]?'API:'+_0x1c2bba[_0x3f3d05('0x52d')]+'\x20-\x20'+_0x1c2bba['statusText']:_0x3f3d05('0x23ff'),'msg':_0x1c2bba[_0x3f3d05('0x25f4')]?JSON[_0x3f3d05('0xbac')](_0x1c2bba[_0x3f3d05('0x25f4')]):_0x1c2bba[_0x3f3d05('0x1586')]()});});}function _0x45cd8f(_0x165c67,_0x2d8025){const _0x268ad4=_0x4d6196,_0x4df1e0=_0x3b462c[_0x268ad4('0x1d26')]()['title'](_0x268ad4('0x11c8'))[_0x268ad4('0xf3c')](_0x268ad4('0x277a')+_0x268ad4('0x3f3'))[_0x268ad4('0x8e8')](_0x268ad4('0x87a'))[_0x268ad4('0x203b')](_0x165c67)['ok']('OK')[_0x268ad4('0x3f')](_0x268ad4('0x2d3'));_0x3b462c[_0x268ad4('0x1f80')](_0x4df1e0)[_0x268ad4('0x1166')](function(){_0x438a6e(_0x2d8025);},function(){const _0x428bc6=_0x268ad4;console[_0x428bc6('0x455')](_0x428bc6('0x2d3'));});}function _0x4722db(_0x3c60cd){const _0x627b77=_0x4d6196,_0x1b1a09=_0x3b462c[_0x627b77('0x1d26')]()['title'](_0x627b77('0x1d64'))['htmlContent'](_0x627b77('0x12b5')+_0x5444e9[_0x627b77('0xd02')][_0x627b77('0x264b')]+_0x627b77('0x196d')+_0x627b77('0x3f3'))[_0x627b77('0x8e8')](_0x627b77('0x5b2'))[_0x627b77('0x203b')](_0x3c60cd)['ok']('OK')[_0x627b77('0x3f')](_0x627b77('0x2d3'));_0x3b462c[_0x627b77('0x1f80')](_0x1b1a09)[_0x627b77('0x1166')](function(){const _0x1cb337=_0x627b77;_0x5444e9['selectedSubjects']['forEach'](function(_0x473f7b){_0x438a6e(_0x473f7b);}),_0x5444e9[_0x1cb337('0xd02')]=[];});}_0x5444e9['selectedDescriptions']=[],_0x5444e9[_0x4d6196('0x2185')]=_0x326dde,_0x5444e9['deleteDescriptionConfirm']=_0x1fd4c1,_0x5444e9[_0x4d6196('0x2269')]=_0x194c5e;function _0x326dde(_0x421c33,_0x38e8d5){const _0x443ba9=_0x4d6196;_0x3b462c[_0x443ba9('0x1f80')]({'controller':_0x443ba9('0x59c'),'controllerAs':'vm','templateUrl':_0x52e785,'parent':angular[_0x443ba9('0x1194')](_0x27e443[_0x443ba9('0x8d2')]),'targetEvent':_0x421c33,'clickOutsideToClose':!![],'locals':{'type':'description','item':_0x38e8d5,'items':_0x5444e9[_0x443ba9('0x1b3d')],'configuration':_0x5444e9[_0x443ba9('0x869')],'account':_0x5444e9[_0x443ba9('0x1d57')],'license':null,'setting':null,'crudPermissions':_0x5444e9[_0x443ba9('0x243c')]}});}function _0x1c0cc5(_0x1ce293){const _0x595679=_0x4d6196;_0x56c9dc[_0x595679('0xf9b')][_0x595679('0x906')]({'id':_0x1ce293['id']})[_0x595679('0xa44')][_0x595679('0x1166')](function(){const _0x6d9129=_0x595679;_0x2cfb05()[_0x6d9129('0x127f')](_0x5444e9['descriptions'],{'id':_0x1ce293['id']}),_0x51c24d[_0x6d9129('0x103b')]({'title':'Description\x20deleted!','msg':'Description\x20has\x20been\x20deleted!'});})[_0x595679('0x1a80')](function(_0x132fa9){const _0x17a78b=_0x595679;_0x51c24d['error']({'title':_0x132fa9[_0x17a78b('0x52d')]?_0x17a78b('0x1e21')+_0x132fa9['status']+_0x17a78b('0x11e1')+_0x132fa9[_0x17a78b('0xe1b')]:_0x17a78b('0x23ff'),'msg':_0x132fa9[_0x17a78b('0x25f4')]?JSON[_0x17a78b('0xbac')](_0x132fa9[_0x17a78b('0x25f4')]):_0x132fa9['toString']()});});}function _0x1fd4c1(_0x2181bf,_0x1685d7){const _0x1247f3=_0x4d6196,_0x3ab920=_0x3b462c[_0x1247f3('0x1d26')]()[_0x1247f3('0xcdc')](_0x1247f3('0x1baa'))['htmlContent'](_0x1247f3('0x1809')+'\x20will\x20be\x20deleted.')[_0x1247f3('0x8e8')](_0x1247f3('0x1bc0'))[_0x1247f3('0x203b')](_0x2181bf)['ok']('OK')[_0x1247f3('0x3f')](_0x1247f3('0x2d3'));_0x3b462c[_0x1247f3('0x1f80')](_0x3ab920)[_0x1247f3('0x1166')](function(){_0x1c0cc5(_0x1685d7);},function(){const _0x3b4a71=_0x1247f3;console[_0x3b4a71('0x455')](_0x3b4a71('0x2d3'));});}function _0x194c5e(_0x434f18){const _0x4b2b22=_0x4d6196,_0x245a2a=_0x3b462c[_0x4b2b22('0x1d26')]()[_0x4b2b22('0xcdc')](_0x4b2b22('0x29'))['htmlContent'](_0x4b2b22('0x12b5')+_0x5444e9[_0x4b2b22('0x968')][_0x4b2b22('0x264b')]+_0x4b2b22('0x196d')+_0x4b2b22('0x3f3'))[_0x4b2b22('0x8e8')](_0x4b2b22('0x17a'))[_0x4b2b22('0x203b')](_0x434f18)['ok']('OK')[_0x4b2b22('0x3f')](_0x4b2b22('0x2d3'));_0x3b462c[_0x4b2b22('0x1f80')](_0x245a2a)[_0x4b2b22('0x1166')](function(){const _0x39a9e0=_0x4b2b22;_0x5444e9[_0x39a9e0('0x968')]['forEach'](function(_0x485d30){_0x1c0cc5(_0x485d30);}),_0x5444e9[_0x39a9e0('0x968')]=[];});}_0x5444e9[_0x4d6196('0x16')]=[],_0x5444e9[_0x4d6196('0x27ad')]=_0xf67d11,_0x5444e9['deleteFieldConfirm']=_0x4490a0,_0x5444e9['deleteSelectedFields']=_0x30244f;function _0xf67d11(_0x177fa3,_0x38bb85){const _0x2051db=_0x4d6196;_0x3b462c[_0x2051db('0x1f80')]({'controller':_0x2051db('0x59c'),'controllerAs':'vm','templateUrl':_0x52e785,'parent':angular[_0x2051db('0x1194')](_0x27e443[_0x2051db('0x8d2')]),'targetEvent':_0x177fa3,'clickOutsideToClose':!![],'locals':{'type':'field','item':_0x38bb85,'items':_0x5444e9[_0x2051db('0xfe2')],'configuration':_0x5444e9['deskConfiguration'],'account':_0x5444e9[_0x2051db('0x1d57')],'license':null,'setting':null,'crudPermissions':_0x5444e9[_0x2051db('0x243c')]}});}function _0x1437cc(_0x5b477d){const _0x43a046=_0x4d6196;_0x56c9dc[_0x43a046('0xf9b')][_0x43a046('0x906')]({'id':_0x5b477d['id']})[_0x43a046('0xa44')][_0x43a046('0x1166')](function(){const _0x2b56aa=_0x43a046;_0x2cfb05()[_0x2b56aa('0x127f')](_0x5444e9[_0x2b56aa('0xfe2')],{'id':_0x5b477d['id']}),_0x51c24d['success']({'title':_0x2b56aa('0x13cb'),'msg':'Field\x20has\x20been\x20deleted!'});})[_0x43a046('0x1a80')](function(_0x15780d){const _0x276cfa=_0x43a046;_0x51c24d['error']({'title':_0x15780d['status']?_0x276cfa('0x1e21')+_0x15780d['status']+_0x276cfa('0x11e1')+_0x15780d[_0x276cfa('0xe1b')]:_0x276cfa('0x23ff'),'msg':_0x15780d[_0x276cfa('0x25f4')]?JSON[_0x276cfa('0xbac')](_0x15780d[_0x276cfa('0x25f4')]):_0x15780d[_0x276cfa('0x1586')]()});});}function _0x4490a0(_0x4405b4,_0x2ea33e){const _0xf97607=_0x4d6196,_0x3ea53c=_0x3b462c['confirm']()[_0xf97607('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0xf97607('0xf3c')](_0xf97607('0x13e0')+_0xf97607('0x3f3'))[_0xf97607('0x8e8')]('delete\x20field')['targetEvent'](_0x4405b4)['ok']('OK')[_0xf97607('0x3f')](_0xf97607('0x2d3'));_0x3b462c['show'](_0x3ea53c)[_0xf97607('0x1166')](function(){_0x1437cc(_0x2ea33e);},function(){const _0x34dd62=_0xf97607;console[_0x34dd62('0x455')](_0x34dd62('0x2d3'));});}function _0x30244f(_0x107fc8){const _0x2bd3df=_0x4d6196,_0x56c2ce=_0x3b462c['confirm']()[_0x2bd3df('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20fields?')[_0x2bd3df('0xf3c')](_0x2bd3df('0x12b5')+_0x5444e9[_0x2bd3df('0x16')][_0x2bd3df('0x264b')]+_0x2bd3df('0x196d')+_0x2bd3df('0x3f3'))[_0x2bd3df('0x8e8')](_0x2bd3df('0x219a'))[_0x2bd3df('0x203b')](_0x107fc8)['ok']('OK')[_0x2bd3df('0x3f')](_0x2bd3df('0x2d3'));_0x3b462c[_0x2bd3df('0x1f80')](_0x56c2ce)[_0x2bd3df('0x1166')](function(){const _0x5a1a2a=_0x2bd3df;_0x5444e9['selectedFields'][_0x5a1a2a('0x2782')](function(_0x25ce52){_0x1437cc(_0x25ce52);}),_0x5444e9[_0x5a1a2a('0x16')]=[];});}}const _0x384abf=_0x5ed37b;_0xab120b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xd54'),_0x36e6f4('0x869'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0xab120b(_0x4e2ef4,_0xe97f7d,_0x579cff,_0x9aad4b,_0x56b065,_0x643090,_0x33cc20,_0x532900,_0x53c24b,_0x17e0fe,_0x21cf98,_0x14602d,_0x24ff7f,_0x3fbf8d){const _0x1c91e2=_0x36e6f4,_0x1f965d=this;_0x1f965d[_0x1c91e2('0x98')]=_0x21cf98[_0x1c91e2('0x26cd')](),_0x1f965d[_0x1c91e2('0x61a')]=[],_0x1f965d[_0x1c91e2('0xf8a')]=_0x24ff7f,_0x1f965d['license']=_0x14602d,_0x1f965d[_0x1c91e2('0x243c')]=_0x3fbf8d,_0x1f965d[_0x1c91e2('0x128b')]={},_0x1f965d[_0x1c91e2('0x2900')]=_0x1f965d[_0x1c91e2('0xf8a')]&&_0x1f965d[_0x1c91e2('0xf8a')][_0x1c91e2('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1f965d[_0x1c91e2('0xcdc')]=_0x1c91e2('0xb5a'),_0x1f965d[_0x1c91e2('0x869')]=angular['copy'](_0x53c24b),_0x1f965d[_0x1c91e2('0xd54')]=_0x532900,_0x1f965d['newDeskConfiguration']=![];!_0x1f965d[_0x1c91e2('0x869')]&&(_0x1f965d[_0x1c91e2('0x869')]={'channel':_0x1c91e2('0x21da'),'type':_0x1c91e2('0x14d8')},_0x1f965d['title']=_0x1c91e2('0x1848'),_0x1f965d[_0x1c91e2('0x721')]=!![]);_0x1f965d['addNewDeskConfiguration']=_0x3b7483,_0x1f965d[_0x1c91e2('0x54')]=_0x3bdf67,_0x1f965d[_0x1c91e2('0x26fc')]=_0x2befee,_0x1f965d['getDateFromString']=_0x543af2,_0x1f965d[_0x1c91e2('0x24a0')]=_0x5e0a0b;function _0x3b7483(){const _0x20b840=_0x1c91e2;_0x1f965d['errors']=[],_0x17e0fe[_0x20b840('0x1db9')][_0x20b840('0x274a')]({'id':_0xe97f7d[_0x20b840('0x23f')]['id']},_0x1f965d['deskConfiguration'])[_0x20b840('0xa44')]['then'](function(_0x10c00b){const _0xb27e27=_0x20b840;_0x1f965d[_0xb27e27('0xd54')]['unshift'](_0x10c00b['toJSON']()),_0x33cc20[_0xb27e27('0x103b')]({'title':_0xb27e27('0x1529'),'msg':_0x1f965d[_0xb27e27('0x869')]['name']?_0x1f965d[_0xb27e27('0x869')][_0xb27e27('0x4f0')]+_0xb27e27('0x1eda'):''}),_0x5e0a0b(_0x10c00b);})[_0x20b840('0x1a80')](function(_0x167c67){const _0x5b931c=_0x20b840;if(_0x167c67[_0x5b931c('0x25f4')]&&_0x167c67[_0x5b931c('0x25f4')][_0x5b931c('0x61a')]&&_0x167c67[_0x5b931c('0x25f4')]['errors'][_0x5b931c('0x264b')]){_0x1f965d[_0x5b931c('0x61a')]=_0x167c67[_0x5b931c('0x25f4')][_0x5b931c('0x61a')]||[{'message':_0x167c67[_0x5b931c('0x1586')](),'type':_0x5b931c('0x1017')}];for(let _0x30d000=0x0;_0x30d000<_0x167c67[_0x5b931c('0x25f4')][_0x5b931c('0x61a')][_0x5b931c('0x264b')];_0x30d000+=0x1){_0x33cc20['error']({'title':_0x167c67[_0x5b931c('0x25f4')][_0x5b931c('0x61a')][_0x30d000][_0x5b931c('0x1345')],'msg':_0x167c67[_0x5b931c('0x25f4')][_0x5b931c('0x61a')][_0x30d000][_0x5b931c('0x1e70')]});}}else _0x33cc20['error']({'title':_0x167c67[_0x5b931c('0x52d')]?'API:'+_0x167c67['status']+'\x20-\x20'+_0x167c67['statusText']:_0x5b931c('0x1017'),'msg':_0x167c67[_0x5b931c('0x25f4')]?JSON[_0x5b931c('0xbac')](_0x167c67[_0x5b931c('0x25f4')][_0x5b931c('0x1e70')]):_0x167c67[_0x5b931c('0x1586')]()});});}function _0x3bdf67(){const _0xf662c5=_0x1c91e2;_0x1f965d[_0xf662c5('0x61a')]=[],_0x17e0fe['intDeskConfiguration']['update']({'id':_0x1f965d[_0xf662c5('0x869')]['id']},_0x1f965d['deskConfiguration'])['$promise'][_0xf662c5('0x1166')](function(_0x68cdc2){const _0x3b8717=_0xf662c5,_0x4750c3=_0x2cfb05()[_0x3b8717('0xc38')](_0x1f965d[_0x3b8717('0xd54')],{'id':_0x68cdc2['id']});_0x4750c3&&_0x2cfb05()[_0x3b8717('0xcc3')](_0x4750c3,_0x2cfb05()[_0x3b8717('0x1a08')](_0x68cdc2[_0x3b8717('0x2876')](),_0x2cfb05()[_0x3b8717('0x14a4')](_0x4750c3))),_0x33cc20[_0x3b8717('0x103b')]({'title':_0x3b8717('0x13b1'),'msg':_0x1f965d[_0x3b8717('0x869')][_0x3b8717('0x4f0')]?_0x1f965d[_0x3b8717('0x869')][_0x3b8717('0x4f0')]+_0x3b8717('0x7d'):''}),_0x5e0a0b(_0x68cdc2);})[_0xf662c5('0x1a80')](function(_0x53e235){const _0x45800b=_0xf662c5;if(_0x53e235['data']&&_0x53e235[_0x45800b('0x25f4')][_0x45800b('0x61a')]&&_0x53e235[_0x45800b('0x25f4')][_0x45800b('0x61a')][_0x45800b('0x264b')]){_0x1f965d['errors']=_0x53e235[_0x45800b('0x25f4')][_0x45800b('0x61a')]||[{'message':_0x53e235[_0x45800b('0x1586')](),'type':'api.intDeskConfiguration.update'}];for(let _0x432b56=0x0;_0x432b56<_0x53e235[_0x45800b('0x25f4')][_0x45800b('0x61a')][_0x45800b('0x264b')];_0x432b56++){_0x33cc20[_0x45800b('0xfc9')]({'title':_0x53e235[_0x45800b('0x25f4')]['errors'][_0x432b56][_0x45800b('0x1345')],'msg':_0x53e235[_0x45800b('0x25f4')][_0x45800b('0x61a')][_0x432b56][_0x45800b('0x1e70')]});}}else _0x33cc20[_0x45800b('0xfc9')]({'title':_0x53e235[_0x45800b('0x52d')]?_0x45800b('0x1e21')+_0x53e235[_0x45800b('0x52d')]+_0x45800b('0x11e1')+_0x53e235[_0x45800b('0xe1b')]:_0x45800b('0xe52'),'msg':_0x53e235[_0x45800b('0x25f4')]?JSON['stringify'](_0x53e235[_0x45800b('0x25f4')][_0x45800b('0x1e70')]):_0x53e235[_0x45800b('0x1586')]()});});}function _0x2befee(_0x3b35c0){const _0x25f362=_0x1c91e2;_0x1f965d[_0x25f362('0x61a')]=[];const _0x32ffd5=_0x9aad4b[_0x25f362('0x1d26')]()[_0x25f362('0xcdc')](_0x25f362('0x7fb'))[_0x25f362('0xacc')]('The\x20deskConfiguration\x20will\x20be\x20deleted.')[_0x25f362('0x8e8')](_0x25f362('0x16c3'))['ok'](_0x25f362('0x18'))['cancel'](_0x25f362('0x497'))[_0x25f362('0x203b')](_0x3b35c0);_0x9aad4b['show'](_0x32ffd5)[_0x25f362('0x1166')](function(){const _0x4cca20=_0x25f362;_0x17e0fe['intDeskConfiguration']['delete']({'id':_0x1f965d[_0x4cca20('0x869')]['id']})[_0x4cca20('0xa44')]['then'](function(){const _0x13cb5d=_0x4cca20;_0x2cfb05()['remove'](_0x1f965d['configurations'],{'id':_0x1f965d[_0x13cb5d('0x869')]['id']}),_0x33cc20['success']({'title':_0x13cb5d('0x1f19'),'msg':(_0x1f965d['deskConfiguration'][_0x13cb5d('0x4f0')]||_0x13cb5d('0x869'))+_0x13cb5d('0x7cd')}),_0x5e0a0b(_0x1f965d['deskConfiguration']);})[_0x4cca20('0x1a80')](function(_0x5ca622){const _0x130146=_0x4cca20;if(_0x5ca622[_0x130146('0x25f4')]&&_0x5ca622['data'][_0x130146('0x61a')]&&_0x5ca622[_0x130146('0x25f4')][_0x130146('0x61a')][_0x130146('0x264b')]){_0x1f965d[_0x130146('0x61a')]=_0x5ca622[_0x130146('0x25f4')]['errors']||[{'message':_0x5ca622[_0x130146('0x1586')](),'type':_0x130146('0x23e6')}];for(let _0x14c045=0x0;_0x14c045<_0x5ca622[_0x130146('0x25f4')][_0x130146('0x61a')][_0x130146('0x264b')];_0x14c045++){_0x33cc20[_0x130146('0xfc9')]({'title':_0x5ca622['data'][_0x130146('0x61a')][_0x14c045][_0x130146('0x1345')],'msg':_0x5ca622[_0x130146('0x25f4')][_0x130146('0x61a')][_0x14c045][_0x130146('0x1e70')]});}}else _0x33cc20[_0x130146('0xfc9')]({'title':_0x5ca622['status']?'API:'+_0x5ca622['status']+'\x20-\x20'+_0x5ca622[_0x130146('0xe1b')]:_0x130146('0x23e6'),'msg':_0x5ca622[_0x130146('0x25f4')]?JSON[_0x130146('0xbac')](_0x5ca622[_0x130146('0x25f4')][_0x130146('0x1e70')]):_0x5ca622[_0x130146('0x1e70')]||_0x5ca622[_0x130146('0x1586')]()});});},function(){});}function _0x543af2(_0x40d591){return _0x40d591===null?undefined:new Date(_0x40d591);}function _0x5e0a0b(_0x41791e){const _0x53504e=_0x1c91e2;_0x9aad4b[_0x53504e('0x1197')](_0x41791e);}}const _0x2e957d=_0xab120b;_0x4c40a2[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xd29'),_0x36e6f4('0xbd7'),_0x36e6f4('0x1301'),_0x36e6f4('0x1a32'),_0x36e6f4('0x1345'),'api','Auth','crudPermissions'];function _0x4c40a2(_0x53ab05,_0x1834de,_0x1e0745,_0x55c834,_0x57216e,_0x5d4a73,_0x41619d,_0x4851cf,_0x34312e,_0x903ea7,_0x15dfb2,_0x297b6c,_0xd4dda6){const _0x30087a=_0x36e6f4,_0x48bc11=this;_0x48bc11['currentUser']=_0x297b6c[_0x30087a('0x26cd')](),_0x48bc11[_0x30087a('0x61a')]=[],_0x48bc11[_0x30087a('0xcdc')]=_0x30087a('0x2012')+_0x2cfb05()[_0x30087a('0x113b')](_0x903ea7),_0x48bc11[_0x30087a('0x1301')]=angular[_0x30087a('0x225f')](_0x4851cf),_0x48bc11[_0x30087a('0xbd7')]=_0x41619d,_0x48bc11['type']=_0x903ea7,_0x48bc11[_0x30087a('0x243c')]=_0xd4dda6,_0x48bc11[_0x30087a('0x17c7')]=![];!_0x48bc11[_0x30087a('0x1301')]&&(_0x48bc11[_0x30087a('0x1301')]={'type':_0x30087a('0x102c')},_0x48bc11[_0x30087a('0x1301')][_0x2cfb05()[_0x30087a('0x92c')](_0x903ea7)+'Id']=_0x5d4a73['id'],_0x48bc11[_0x30087a('0xcdc')]=_0x30087a('0xf9c')+_0x2cfb05()[_0x30087a('0x113b')](_0x903ea7),_0x48bc11['newItem']=!![]);_0x48bc11[_0x30087a('0x1e8a')]=_0x38164c,_0x48bc11['saveItem']=_0x38f1ad,_0x48bc11[_0x30087a('0x18d3')]=_0x224bc0,_0x48bc11['getSelectedVariable']=_0xcae5e8,_0x48bc11['closeDialog']=_0x144ef3,_0x15dfb2[_0x30087a('0x734')][_0x30087a('0xd83')]({'nolimit':!![]})[_0x30087a('0xa44')][_0x30087a('0x1166')](function(_0x10b397){const _0x4f6d04=_0x30087a;return _0x48bc11[_0x4f6d04('0x57a')]=_0x10b397[_0x4f6d04('0x269a')]?_0x10b397['rows']:[],_0x15dfb2[_0x4f6d04('0x7af')][_0x4f6d04('0x23d0')]()[_0x4f6d04('0xa44')];})['then'](function(_0x54fcc2){const _0x3fc184=_0x30087a;return _0x48bc11[_0x3fc184('0x1d45')]=_0x2cfb05()[_0x3fc184('0x13ca')](_0x2cfb05()[_0x3fc184('0x14a4')](_0x54fcc2),['$promise',_0x3fc184('0xfcd'),'createdAt','updatedAt',_0x3fc184('0x978')]),_0x48bc11[_0x3fc184('0x1d45')]['push'](_0x3fc184('0xa29')),_0x15dfb2[_0x3fc184('0x21f9')][_0x3fc184('0x23d0')]()['$promise'];})[_0x30087a('0x1166')](function(_0x289392){const _0x5634d3=_0x30087a;_0x48bc11[_0x5634d3('0x1348')]=_0x2cfb05()['difference'](_0x2cfb05()[_0x5634d3('0x14a4')](_0x289392),['$promise',_0x5634d3('0xfcd'),_0x5634d3('0x262'),_0x5634d3('0x6f9'),_0x5634d3('0x978')]),_0x48bc11[_0x5634d3('0x1348')][_0x5634d3('0x1514')]('recordingURL');})[_0x30087a('0x1a80')](function(_0x5a4134){const _0x4ca7ea=_0x30087a;_0x57216e[_0x4ca7ea('0xfc9')]({'title':_0x5a4134[_0x4ca7ea('0x52d')]?_0x4ca7ea('0x1e21')+_0x5a4134[_0x4ca7ea('0x52d')]+'\x20-\x20'+_0x5a4134[_0x4ca7ea('0xe1b')]:_0x4ca7ea('0xfe5'),'msg':_0x5a4134[_0x4ca7ea('0x25f4')]?JSON[_0x4ca7ea('0xbac')](_0x5a4134[_0x4ca7ea('0x25f4')]):_0x5a4134['toString']()});}),_0x15dfb2['intDeskAccount'][_0x30087a('0x18ea')]({'id':_0x34312e['id'],'ticketType':_0x5d4a73['ticketType']?_0x5d4a73[_0x30087a('0x11ba')]:undefined})[_0x30087a('0xa44')][_0x30087a('0x1166')](function(_0x472bb7){const _0x4bae61=_0x30087a;_0x48bc11[_0x4bae61('0x606')]=!![],_0x48bc11[_0x4bae61('0xfe2')]=_0x472bb7['rows']?_0x472bb7[_0x4bae61('0x269a')]:[],_0x48bc11[_0x4bae61('0x1301')]['idField']&&(_0x48bc11[_0x4bae61('0x117e')]=_0x2cfb05()['find'](_0x48bc11['fields'],{'id':_0x48bc11[_0x4bae61('0x1301')][_0x4bae61('0x1143')]}));})[_0x30087a('0x1a80')](function(_0x55cd86){const _0x168cc1=_0x30087a;_0x48bc11['accountConnected']=![],console[_0x168cc1('0xfc9')](_0x55cd86);});function _0x38164c(){const _0x118d2e=_0x30087a;_0x48bc11[_0x118d2e('0x61a')]=[],_0x48bc11['customField']&&(_0x48bc11['item'][_0x118d2e('0x1143')]=_0x48bc11['customField']['id'],_0x48bc11[_0x118d2e('0x1301')][_0x118d2e('0x3c0')]=_0x48bc11[_0x118d2e('0x117e')][_0x118d2e('0x4f0')],_0x48bc11['item']['customField']=_0x48bc11[_0x118d2e('0x117e')][_0x118d2e('0x2853')]),_0x15dfb2[_0x118d2e('0xf9b')][_0x118d2e('0x9cc')](_0x48bc11[_0x118d2e('0x1301')])[_0x118d2e('0xa44')][_0x118d2e('0x1166')](function(_0x273423){const _0x43658f=_0x118d2e;_0x48bc11[_0x43658f('0xbd7')]['unshift'](_0x273423),_0x57216e['success']({'title':_0x2cfb05()['capitalize'](_0x903ea7)+_0x43658f('0x13f0'),'msg':_0x2cfb05()['capitalize'](_0x903ea7)+_0x43658f('0x1eda')}),_0x144ef3();})[_0x118d2e('0x1a80')](function(_0x529b3c){const _0x66e988=_0x118d2e;console[_0x66e988('0xfc9')](_0x529b3c),_0x48bc11['errors']=_0x529b3c[_0x66e988('0x25f4')][_0x66e988('0x61a')]||[{'message':_0x529b3c['toString'](),'type':_0x66e988('0x215d')}];});}function _0x38f1ad(){const _0x533e00=_0x30087a;_0x48bc11['errors']=[],_0x48bc11[_0x533e00('0x117e')]&&(_0x48bc11[_0x533e00('0x1301')][_0x533e00('0x1143')]=_0x48bc11[_0x533e00('0x117e')]['id'],_0x48bc11[_0x533e00('0x1301')]['nameField']=_0x48bc11[_0x533e00('0x117e')]['name'],_0x48bc11[_0x533e00('0x1301')][_0x533e00('0x117e')]=_0x48bc11['customField'][_0x533e00('0x2853')]),_0x15dfb2[_0x533e00('0xf9b')][_0x533e00('0x1449')]({'id':_0x48bc11[_0x533e00('0x1301')]['id']},_0x48bc11[_0x533e00('0x1301')])[_0x533e00('0xa44')][_0x533e00('0x1166')](function(_0x532ec1){const _0x44912d=_0x533e00,_0x2fb706=_0x2cfb05()['find'](_0x48bc11[_0x44912d('0xbd7')],{'id':_0x532ec1['id']});_0x2fb706&&_0x2cfb05()[_0x44912d('0xcc3')](_0x2fb706,_0x532ec1),_0x57216e[_0x44912d('0x103b')]({'title':_0x2cfb05()[_0x44912d('0x92c')](_0x903ea7)+'\x20properly\x20saved!','msg':_0x2cfb05()[_0x44912d('0x92c')](_0x903ea7)+_0x44912d('0x7d')}),_0x144ef3();})[_0x533e00('0x1a80')](function(_0x16b6d0){const _0x1d4595=_0x533e00;console[_0x1d4595('0xfc9')](_0x16b6d0),_0x48bc11[_0x1d4595('0x61a')]=_0x16b6d0['data'][_0x1d4595('0x61a')]||[{'message':_0x16b6d0[_0x1d4595('0x1586')](),'type':_0x1d4595('0x10cd')}];});}function _0x224bc0(_0xc5fcf3){const _0x4d2f59=_0x30087a;_0x48bc11[_0x4d2f59('0x61a')]=[];const _0x337603=_0x55c834[_0x4d2f59('0x1d26')]()[_0x4d2f59('0xcdc')](_0x4d2f59('0x7fb'))[_0x4d2f59('0xacc')](_0x4d2f59('0x135f')+_0x903ea7+_0x4d2f59('0x3f3'))[_0x4d2f59('0x8e8')]('Delete\x20'+_0x2cfb05()[_0x4d2f59('0x92c')](_0x903ea7))['ok']('Delete')[_0x4d2f59('0x3f')]('Cancel')['targetEvent'](_0xc5fcf3);_0x55c834[_0x4d2f59('0x1f80')](_0x337603)[_0x4d2f59('0x1166')](function(){const _0x3def20=_0x4d2f59;_0x15dfb2[_0x3def20('0xf9b')]['delete']({'id':_0x48bc11[_0x3def20('0x1301')]['id']})[_0x3def20('0xa44')][_0x3def20('0x1166')](function(){const _0x2e7c49=_0x3def20;_0x2cfb05()[_0x2e7c49('0x127f')](_0x48bc11['items'],{'id':_0x48bc11[_0x2e7c49('0x1301')]['id']}),_0x57216e[_0x2e7c49('0x103b')]({'title':_0x2cfb05()[_0x2e7c49('0x92c')](_0x903ea7)+_0x2e7c49('0x450'),'msg':_0x2cfb05()[_0x2e7c49('0x92c')](_0x903ea7)+_0x2e7c49('0x7cd')}),_0x144ef3();})['catch'](function(_0x3bb16a){const _0x1f057c=_0x3def20;console[_0x1f057c('0xfc9')](_0x3bb16a),_0x48bc11[_0x1f057c('0x61a')]=_0x3bb16a[_0x1f057c('0x25f4')][_0x1f057c('0x61a')]||[{'message':_0x3bb16a[_0x1f057c('0x1586')](),'type':_0x1f057c('0x2602')}];});},function(){});}function _0xcae5e8(){const _0x44d9a0=_0x30087a;return _0x48bc11['item'][_0x44d9a0('0xbdb')]!==undefined?_0x48bc11[_0x44d9a0('0x1301')][_0x44d9a0('0xbdb')]:_0x44d9a0('0x16a4');}function _0x144ef3(){const _0x58f12a=_0x30087a;_0x55c834[_0x58f12a('0x1197')]();}}const _0x4ee1d1=_0x4c40a2;_0x52d670[_0x36e6f4('0x1294')]=['$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$translate',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x1d57'),_0x36e6f4('0x17aa')];function _0x52d670(_0x3cd0fc,_0x13df33,_0x334078,_0x1980f5,_0x3aaaa3,_0x3c2a65,_0x439702,_0x130bf2,_0x1929b3,_0x526ac8,_0x568a3e,_0x2f2deb){const _0x5f527f=_0x36e6f4,_0x5c0e61=this;_0x5c0e61[_0x5f527f('0x98')]=_0x526ac8[_0x5f527f('0x26cd')](),_0x5c0e61['license']=_0x3c2a65,_0x5c0e61[_0x5f527f('0xf8a')]=_0x439702,_0x5c0e61[_0x5f527f('0x2900')]=_0x5c0e61[_0x5f527f('0xf8a')][_0x5f527f('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5c0e61[_0x5f527f('0x246b')]=_0x13df33[_0x5f527f('0x6f1')]()+'://'+_0x13df33[_0x5f527f('0x1690')](),_0x5c0e61[_0x5f527f('0x1d57')]=_0x568a3e||_0x3cd0fc[_0x5f527f('0x23f')][_0x5f527f('0x1d57')]||{},_0x5c0e61['userProfileSection']=_0x2f2deb&&_0x2f2deb[_0x5f527f('0x240f')]==0x1?_0x2f2deb[_0x5f527f('0x269a')][0x0]:null,_0x5c0e61[_0x5f527f('0x243c')]=_0x526ac8[_0x5f527f('0xd87')](_0x5c0e61[_0x5f527f('0x17aa')]?_0x5c0e61[_0x5f527f('0x17aa')][_0x5f527f('0x243c')]:null),_0x5c0e61[_0x5f527f('0x128b')]={},_0x5c0e61[_0x5f527f('0x2669')]=_0x3cd0fc['params'][_0x5f527f('0xbe3')]||0x0,_0x5c0e61[_0x5f527f('0x31d')]=_0x1929b3[_0x5f527f('0x1fa1')],_0x5c0e61[_0x5f527f('0xa76')]=_0x5828bc,_0x5c0e61[_0x5f527f('0x5d9')]=_0xbff26a;function _0x5828bc(){const _0xa03a37=_0x5f527f;_0x3cd0fc['go']('app.integrations.deskAccounts',{},{'reload':_0xa03a37('0xbaf')});}function _0xbff26a(){const _0x51ffa9=_0x5f527f;_0x130bf2[_0x51ffa9('0x1db9')][_0x51ffa9('0x1449')]({'id':_0x5c0e61[_0x51ffa9('0x1d57')]['id']},_0x5c0e61[_0x51ffa9('0x1d57')])[_0x51ffa9('0xa44')]['then'](function(){const _0x184c85=_0x51ffa9;_0x1929b3['success']({'title':_0x184c85('0x281d'),'msg':_0x5c0e61[_0x184c85('0x1d57')][_0x184c85('0x4f0')]?_0x5c0e61[_0x184c85('0x1d57')][_0x184c85('0x4f0')]+_0x184c85('0xa17'):''});})[_0x51ffa9('0x1a80')](function(_0x45befb){const _0x391a16=_0x51ffa9;_0x1929b3[_0x391a16('0xfc9')]({'title':_0x45befb['status']?'API:'+_0x45befb['status']+_0x391a16('0x11e1')+_0x45befb[_0x391a16('0xe1b')]:_0x391a16('0x2777'),'msg':_0x45befb['data']?JSON[_0x391a16('0xbac')](_0x45befb[_0x391a16('0x25f4')]):_0x45befb[_0x391a16('0x1586')]()});});}}const _0x1179be=_0x52d670;_0x380bb1[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x2131'),_0x36e6f4('0x10dd'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license','setting','crudPermissions'];function _0x380bb1(_0x347f35,_0x52a95c,_0x2a8f41,_0x74da09,_0x4f9e43,_0x625f23,_0x5efe4b,_0xa2d474,_0x2e5060,_0x30d912,_0x9cff5c,_0xb9bc3f,_0x13530c,_0x4180b7){const _0xd7c405=_0x36e6f4,_0x37040c=this;_0x37040c[_0xd7c405('0x98')]=_0x9cff5c[_0xd7c405('0x26cd')](),_0x37040c['errors']=[],_0x37040c['setting']=_0x13530c,_0x37040c[_0xd7c405('0x5c9')]=_0xb9bc3f,_0x37040c['crudPermissions']=_0x4180b7,_0x37040c[_0xd7c405('0x128b')]={},_0x37040c[_0xd7c405('0x2900')]=_0x37040c[_0xd7c405('0xf8a')]&&_0x37040c[_0xd7c405('0xf8a')][_0xd7c405('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x37040c['title']=_0xd7c405('0xdfb'),_0x37040c[_0xd7c405('0x10dd')]=angular[_0xd7c405('0x225f')](_0x2e5060),_0x37040c[_0xd7c405('0x2131')]=_0xa2d474,_0x37040c[_0xd7c405('0x19ae')]=![];!_0x37040c['dynamics365Account']&&(_0x37040c[_0xd7c405('0x10dd')]={'serverUrl':_0x2a8f41['protocol']()+_0xd7c405('0xc51')+_0x2a8f41['host']()+(_0x2a8f41['port']()?':'+_0x2a8f41[_0xd7c405('0x93d')]():'')},_0x37040c[_0xd7c405('0xcdc')]='INTEGRATIONS.NEW_DYNAMICS365ACCOUNT',_0x37040c[_0xd7c405('0x19ae')]=!![]);_0x37040c[_0xd7c405('0x206d')]=_0x413a69,_0x37040c[_0xd7c405('0x1ed0')]=_0x49c491,_0x37040c[_0xd7c405('0x18cf')]=_0x25ae17,_0x37040c[_0xd7c405('0x1a9c')]=_0x3fe20a,_0x37040c['closeDialog']=_0x1faa4f;function _0x413a69(){const _0xeb384a=_0xd7c405;_0x37040c[_0xeb384a('0x61a')]=[],_0x30d912[_0xeb384a('0x2176')][_0xeb384a('0x9cc')](_0x37040c[_0xeb384a('0x10dd')])[_0xeb384a('0xa44')][_0xeb384a('0x1166')](function(_0x37b7f5){const _0x543561=_0xeb384a;_0x37040c[_0x543561('0x2131')][_0x543561('0x2450')](_0x37b7f5[_0x543561('0x2876')]()),_0x5efe4b[_0x543561('0x103b')]({'title':'Dynamics365Account\x20properly\x20created','msg':_0x37040c['dynamics365Account']['name']?_0x37040c[_0x543561('0x10dd')][_0x543561('0x4f0')]+_0x543561('0x1eda'):''}),_0x1faa4f(_0x37b7f5);})[_0xeb384a('0x1a80')](function(_0x4d3ac3){const _0x15ed90=_0xeb384a;if(_0x4d3ac3[_0x15ed90('0x25f4')]&&_0x4d3ac3['data'][_0x15ed90('0x61a')]&&_0x4d3ac3[_0x15ed90('0x25f4')]['errors']['length']){_0x37040c[_0x15ed90('0x61a')]=_0x4d3ac3[_0x15ed90('0x25f4')][_0x15ed90('0x61a')]||[{'message':_0x4d3ac3[_0x15ed90('0x1586')](),'type':_0x15ed90('0x1493')}];for(let _0x182008=0x0;_0x182008<_0x4d3ac3['data'][_0x15ed90('0x61a')][_0x15ed90('0x264b')];_0x182008+=0x1){_0x5efe4b['error']({'title':_0x4d3ac3[_0x15ed90('0x25f4')][_0x15ed90('0x61a')][_0x182008][_0x15ed90('0x1345')],'msg':_0x4d3ac3['data'][_0x15ed90('0x61a')][_0x182008][_0x15ed90('0x1e70')]});}}else _0x5efe4b[_0x15ed90('0xfc9')]({'title':_0x4d3ac3[_0x15ed90('0x52d')]?_0x15ed90('0x1e21')+_0x4d3ac3[_0x15ed90('0x52d')]+_0x15ed90('0x11e1')+_0x4d3ac3[_0x15ed90('0xe1b')]:_0x15ed90('0x1493'),'msg':_0x4d3ac3[_0x15ed90('0x25f4')]?JSON['stringify'](_0x4d3ac3[_0x15ed90('0x25f4')][_0x15ed90('0x1e70')]):_0x4d3ac3[_0x15ed90('0x1586')]()});});}function _0x49c491(){const _0x56cb7d=_0xd7c405;_0x37040c[_0x56cb7d('0x61a')]=[],_0x30d912[_0x56cb7d('0x2176')][_0x56cb7d('0x1449')]({'id':_0x37040c[_0x56cb7d('0x10dd')]['id']},_0x37040c[_0x56cb7d('0x10dd')])['$promise'][_0x56cb7d('0x1166')](function(_0x42c812){const _0x19fdc9=_0x56cb7d,_0x39202d=_0x2cfb05()[_0x19fdc9('0xc38')](_0x37040c['dynamics365Accounts'],{'id':_0x42c812['id']});_0x39202d&&_0x2cfb05()[_0x19fdc9('0xcc3')](_0x39202d,_0x2cfb05()['pick'](_0x42c812[_0x19fdc9('0x2876')](),_0x2cfb05()[_0x19fdc9('0x14a4')](_0x39202d))),_0x5efe4b[_0x19fdc9('0x103b')]({'title':'Dynamics365Account\x20properly\x20saved!','msg':_0x37040c['dynamics365Account'][_0x19fdc9('0x4f0')]?_0x37040c['dynamics365Account'][_0x19fdc9('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x1faa4f(_0x42c812);})['catch'](function(_0x1a47f7){const _0x3944a4=_0x56cb7d;if(_0x1a47f7['data']&&_0x1a47f7['data'][_0x3944a4('0x61a')]&&_0x1a47f7[_0x3944a4('0x25f4')][_0x3944a4('0x61a')][_0x3944a4('0x264b')]){_0x37040c[_0x3944a4('0x61a')]=_0x1a47f7['data']['errors']||[{'message':_0x1a47f7[_0x3944a4('0x1586')](),'type':_0x3944a4('0x1401')}];for(let _0xbe4121=0x0;_0xbe4121<_0x1a47f7[_0x3944a4('0x25f4')][_0x3944a4('0x61a')][_0x3944a4('0x264b')];_0xbe4121++){_0x5efe4b['error']({'title':_0x1a47f7[_0x3944a4('0x25f4')][_0x3944a4('0x61a')][_0xbe4121][_0x3944a4('0x1345')],'msg':_0x1a47f7[_0x3944a4('0x25f4')][_0x3944a4('0x61a')][_0xbe4121][_0x3944a4('0x1e70')]});}}else _0x5efe4b['error']({'title':_0x1a47f7['status']?_0x3944a4('0x1e21')+_0x1a47f7[_0x3944a4('0x52d')]+'\x20-\x20'+_0x1a47f7[_0x3944a4('0xe1b')]:_0x3944a4('0x1401'),'msg':_0x1a47f7['data']?JSON[_0x3944a4('0xbac')](_0x1a47f7[_0x3944a4('0x25f4')]['message']):_0x1a47f7[_0x3944a4('0x1586')]()});});}function _0x25ae17(_0x50d7d9){const _0x229e76=_0xd7c405;_0x37040c[_0x229e76('0x61a')]=[];const _0x4cb5b5=_0x74da09[_0x229e76('0x1d26')]()[_0x229e76('0xcdc')](_0x229e76('0x7fb'))[_0x229e76('0xacc')](_0x229e76('0xc17'))['ariaLabel']('Delete\x20Dynamics365Account')['ok'](_0x229e76('0x18'))[_0x229e76('0x3f')](_0x229e76('0x497'))[_0x229e76('0x203b')](_0x50d7d9);_0x74da09[_0x229e76('0x1f80')](_0x4cb5b5)['then'](function(){const _0x2fc496=_0x229e76;_0x30d912[_0x2fc496('0x2176')][_0x2fc496('0x906')]({'id':_0x37040c['dynamics365Account']['id']})[_0x2fc496('0xa44')][_0x2fc496('0x1166')](function(){const _0x4b9128=_0x2fc496;_0x2cfb05()[_0x4b9128('0x127f')](_0x37040c[_0x4b9128('0x2131')],{'id':_0x37040c[_0x4b9128('0x10dd')]['id']}),_0x5efe4b[_0x4b9128('0x103b')]({'title':_0x4b9128('0x61'),'msg':(_0x37040c['dynamics365Account'][_0x4b9128('0x4f0')]||_0x4b9128('0x10dd'))+'\x20has\x20been\x20deleted!'}),_0x1faa4f(_0x37040c[_0x4b9128('0x10dd')]);})[_0x2fc496('0x1a80')](function(_0x5ebd2a){const _0x5f546c=_0x2fc496;if(_0x5ebd2a[_0x5f546c('0x25f4')]&&_0x5ebd2a[_0x5f546c('0x25f4')][_0x5f546c('0x61a')]&&_0x5ebd2a[_0x5f546c('0x25f4')][_0x5f546c('0x61a')][_0x5f546c('0x264b')]){_0x37040c[_0x5f546c('0x61a')]=_0x5ebd2a[_0x5f546c('0x25f4')]['errors']||[{'message':_0x5ebd2a[_0x5f546c('0x1586')](),'type':_0x5f546c('0x226e')}];for(let _0x27deb3=0x0;_0x27deb3<_0x5ebd2a['data'][_0x5f546c('0x61a')]['length'];_0x27deb3++){_0x5efe4b[_0x5f546c('0xfc9')]({'title':_0x5ebd2a['data']['errors'][_0x27deb3][_0x5f546c('0x1345')],'msg':_0x5ebd2a[_0x5f546c('0x25f4')][_0x5f546c('0x61a')][_0x27deb3][_0x5f546c('0x1e70')]});}}else _0x5efe4b[_0x5f546c('0xfc9')]({'title':_0x5ebd2a['status']?_0x5f546c('0x1e21')+_0x5ebd2a[_0x5f546c('0x52d')]+'\x20-\x20'+_0x5ebd2a[_0x5f546c('0xe1b')]:_0x5f546c('0x226e'),'msg':_0x5ebd2a[_0x5f546c('0x25f4')]?JSON[_0x5f546c('0xbac')](_0x5ebd2a[_0x5f546c('0x25f4')][_0x5f546c('0x1e70')]):_0x5ebd2a[_0x5f546c('0x1e70')]||_0x5ebd2a[_0x5f546c('0x1586')]()});});},function(){});}function _0x3fe20a(_0x42d72a){return _0x42d72a===null?undefined:new Date(_0x42d72a);}function _0x1faa4f(_0xfff147){const _0x378f79=_0xd7c405;_0x74da09[_0x378f79('0x1197')](_0xfff147);}}const _0x3ea028=_0x380bb1,_0x27e974=_0x2734b2['p']+_0x36e6f4('0x2745');_0x386c82[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x2131'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x386c82(_0x17cfe4,_0xcbca6b,_0x376024,_0x1e1075,_0x1c7ed1,_0x1b2a91,_0x4b19fc,_0x4499ad,_0x26e174,_0x35501f,_0x5bd993,_0x5ea7c9,_0x5b59bb,_0x4cd713,_0x33bdf1,_0x43cfe4,_0x3dcbf4){const _0x3ca59d=_0x36e6f4,_0xd7dfed=this;_0xd7dfed['license']=_0x43cfe4,_0xd7dfed[_0x3ca59d('0xf8a')]=_0x3dcbf4,_0xd7dfed[_0x3ca59d('0x98')]=_0x33bdf1[_0x3ca59d('0x26cd')](),_0xd7dfed['dynamics365Accounts']=_0x26e174||{'count':0x0,'rows':[]},_0xd7dfed[_0x3ca59d('0x7f')]=_0x35501f,_0xd7dfed[_0x3ca59d('0x17aa')]=_0x5bd993&&_0x5bd993[_0x3ca59d('0x240f')]==0x1?_0x5bd993[_0x3ca59d('0x269a')][0x0]:null,_0xd7dfed[_0x3ca59d('0x243c')]=_0x33bdf1[_0x3ca59d('0xd87')](_0xd7dfed[_0x3ca59d('0x17aa')]?_0xd7dfed[_0x3ca59d('0x17aa')]['crudPermissions']:null),_0xd7dfed[_0x3ca59d('0x916')]=_0x3ca59d('0x2131'),_0xd7dfed[_0x3ca59d('0xef5')]='',_0xd7dfed[_0x3ca59d('0x104c')]=null,_0xd7dfed[_0x3ca59d('0x194f')]=[],_0xd7dfed[_0x3ca59d('0x2218')]={'fields':_0x3ca59d('0x161'),'limit':0xa,'page':0x1},_0xd7dfed[_0x3ca59d('0x1ff6')]=_0x22ba47,_0xd7dfed[_0x3ca59d('0x2113')]=_0x3878e5,_0xd7dfed[_0x3ca59d('0x8d8')]=_0x59773a,_0xd7dfed['success']=_0x23bde1,_0xd7dfed[_0x3ca59d('0x1ea1')]=_0x541f55,_0xd7dfed[_0x3ca59d('0x68a')]=_0x24eb9d,_0xd7dfed[_0x3ca59d('0x18cf')]=_0x46d865,_0xd7dfed[_0x3ca59d('0x9e1')]=_0x586ac6,_0xd7dfed[_0x3ca59d('0x253f')]=_0x57f135,_0xd7dfed[_0x3ca59d('0x228d')]=_0x149361,_0xd7dfed['selectAllDynamics365Accounts']=_0x1b6490;function _0x22ba47(_0x180a1e){const _0x42b68b=_0x3ca59d;_0x376024['go'](_0x42b68b('0xb8a'),{'id':_0x180a1e['id'],'dynamics365Account':_0x180a1e,'crudPermissions':_0xd7dfed[_0x42b68b('0x243c')]});}function _0x3878e5(_0x2651d7){const _0x57c1e1=_0x3ca59d;return _0x5ea7c9[_0x57c1e1('0x2176')]['getFields']({'id':_0x2651d7['id'],'test':!![]})[_0x57c1e1('0xa44')][_0x57c1e1('0x1166')](function(){const _0x6b846c=_0x57c1e1;_0x4cd713[_0x6b846c('0x103b')]({'title':'Dynamics365Account\x20properly\x20tested','msg':_0x6b846c('0x1fef')});})['catch'](function(_0x3b27f3){const _0x357069=_0x57c1e1;_0x4cd713[_0x357069('0xfc9')]({'title':_0x357069('0x11d'),'msg':_0x3b27f3['data']?_0x3b27f3['data'][_0x357069('0x1e70')]?_0x3b27f3[_0x357069('0x25f4')]['message']:JSON[_0x357069('0xbac')](_0x3b27f3['data']):_0x3b27f3[_0x357069('0x1586')]()});});}function _0x59773a(_0x12951,_0x3f7b25){const _0x4d8bc7=_0x3ca59d,_0x2c5ba5=_0x1c7ed1[_0x4d8bc7('0x1d26')]()[_0x4d8bc7('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x4d8bc7('0xb35')]('dynamics365Account')+'?')[_0x4d8bc7('0xf3c')](_0x4d8bc7('0x12b5')+(_0x12951[_0x4d8bc7('0x4f0')]||_0x4d8bc7('0x10dd'))+''+_0x4d8bc7('0x3f3'))[_0x4d8bc7('0x8e8')]('delete\x20dynamics365Account')['targetEvent'](_0x3f7b25)['ok']('OK')['cancel']('CANCEL');_0x1c7ed1[_0x4d8bc7('0x1f80')](_0x2c5ba5)[_0x4d8bc7('0x1166')](function(){_0x46d865(_0x12951);},function(){const _0x4c6810=_0x4d8bc7;console['log'](_0x4c6810('0x2d3'));});}let _0x9ae647=!![],_0x11d00e=0x1;_0x17cfe4[_0x3ca59d('0xe83')](_0x3ca59d('0x12d8'),function(_0x476f94,_0x88e774){const _0x47c03b=_0x3ca59d;_0x9ae647?_0x4b19fc(function(){_0x9ae647=![];}):(!_0x88e774&&(_0x11d00e=_0xd7dfed[_0x47c03b('0x2218')][_0x47c03b('0x1a43')]),_0x476f94!==_0x88e774&&(_0xd7dfed[_0x47c03b('0x2218')]['page']=0x1),!_0x476f94&&(_0xd7dfed['query'][_0x47c03b('0x1a43')]=_0x11d00e),_0xd7dfed[_0x47c03b('0x1ea1')]());});function _0x23bde1(_0x13b2c0){_0xd7dfed['dynamics365Accounts']=_0x13b2c0||{'count':0x0,'rows':[]};}function _0x541f55(){const _0x28d2a4=_0x3ca59d;_0xd7dfed[_0x28d2a4('0x2218')][_0x28d2a4('0x1098')]=(_0xd7dfed[_0x28d2a4('0x2218')][_0x28d2a4('0x1a43')]-0x1)*_0xd7dfed[_0x28d2a4('0x2218')][_0x28d2a4('0x163f')],_0x33bdf1['hasRole'](_0x28d2a4('0xa7c'))?_0xd7dfed[_0x28d2a4('0x1f48')]=_0x5ea7c9['intDynamics365Account'][_0x28d2a4('0xd83')](_0xd7dfed[_0x28d2a4('0x2218')],_0x23bde1)[_0x28d2a4('0xa44')]:(_0xd7dfed['query']['id']=_0xd7dfed[_0x28d2a4('0x7f')]['id'],_0xd7dfed['query']['section']=_0x28d2a4('0x8c8'),_0xd7dfed['promise']=_0x5ea7c9['userProfile'][_0x28d2a4('0x263a')](_0xd7dfed[_0x28d2a4('0x2218')],_0x23bde1)[_0x28d2a4('0xa44')]);}function _0x24eb9d(_0x2e2b3a,_0x3dd177){const _0x3e032b=_0x3ca59d;_0x1c7ed1['show']({'controller':_0x3e032b('0x67a'),'controllerAs':'vm','templateUrl':_0x27e974,'parent':angular[_0x3e032b('0x1194')](_0x1b2a91[_0x3e032b('0x8d2')]),'targetEvent':_0x2e2b3a,'clickOutsideToClose':!![],'locals':{'dynamics365Account':_0x3dd177,'dynamics365Accounts':_0xd7dfed['dynamics365Accounts'][_0x3e032b('0x269a')],'license':_0xd7dfed[_0x3e032b('0x5c9')],'setting':_0xd7dfed[_0x3e032b('0xf8a')],'crudPermissions':_0xd7dfed['crudPermissions']}});}function _0x46d865(_0x21c655){const _0x1fcc99=_0x3ca59d;_0x5ea7c9[_0x1fcc99('0x2176')][_0x1fcc99('0x906')]({'id':_0x21c655['id']})[_0x1fcc99('0xa44')][_0x1fcc99('0x1166')](function(){const _0x31cd1b=_0x1fcc99;_0x2cfb05()['remove'](_0xd7dfed['dynamics365Accounts'][_0x31cd1b('0x269a')],{'id':_0x21c655['id']}),_0xd7dfed[_0x31cd1b('0x2131')][_0x31cd1b('0x240f')]-=0x1,!_0xd7dfed[_0x31cd1b('0x2131')]['rows'][_0x31cd1b('0x264b')]&&_0xd7dfed['getDynamics365Accounts'](),_0x4cd713[_0x31cd1b('0x103b')]({'title':_0x2cfb05()[_0x31cd1b('0xb35')](_0x31cd1b('0x17f'))+_0x31cd1b('0x2b6'),'msg':_0x21c655['name']?_0x21c655['name']+_0x31cd1b('0x7cd'):''});})[_0x1fcc99('0x1a80')](function(_0x464934){const _0x273479=_0x1fcc99;if(_0x464934[_0x273479('0x25f4')]&&_0x464934[_0x273479('0x25f4')][_0x273479('0x61a')]&&_0x464934[_0x273479('0x25f4')][_0x273479('0x61a')]['length']){_0xd7dfed['errors']=_0x464934[_0x273479('0x25f4')]['errors']||[{'message':_0x464934[_0x273479('0x1586')](),'type':_0x273479('0x2331')}];for(let _0x5e1644=0x0;_0x5e1644<_0x464934[_0x273479('0x25f4')][_0x273479('0x61a')][_0x273479('0x264b')];_0x5e1644++){_0x4cd713[_0x273479('0xfc9')]({'title':_0x464934[_0x273479('0x25f4')][_0x273479('0x61a')][_0x5e1644][_0x273479('0x1345')],'msg':_0x464934[_0x273479('0x25f4')][_0x273479('0x61a')][_0x5e1644]['message']});}}else _0x4cd713['error']({'title':_0x464934[_0x273479('0x52d')]?_0x273479('0x1e21')+_0x464934[_0x273479('0x52d')]+'\x20-\x20'+_0x464934[_0x273479('0xe1b')]:_0x273479('0x2331'),'msg':_0x464934['data']?JSON[_0x273479('0xbac')](_0x464934[_0x273479('0x25f4')][_0x273479('0x1e70')]):_0x464934[_0x273479('0x1e70')]||_0x464934[_0x273479('0x1586')]()});});}function _0x586ac6(){const _0x275ac2=_0x3ca59d,_0x3f976b=angular[_0x275ac2('0x225f')](_0xd7dfed[_0x275ac2('0x194f')]);return _0xd7dfed[_0x275ac2('0x194f')]=[],_0x3f976b;}function _0x57f135(_0x17475b){const _0x2941d2=_0x3ca59d,_0x41db3f=_0x1c7ed1[_0x2941d2('0x1d26')]()[_0x2941d2('0xcdc')](_0x2941d2('0x2614'))['htmlContent'](_0x2941d2('0x12b5')+_0xd7dfed[_0x2941d2('0x194f')]['length']+_0x2941d2('0x196d')+_0x2941d2('0x3f3'))[_0x2941d2('0x8e8')]('delete\x20Dynamics365Accounts')['targetEvent'](_0x17475b)['ok']('OK')[_0x2941d2('0x3f')]('CANCEL');_0x1c7ed1[_0x2941d2('0x1f80')](_0x41db3f)['then'](function(){const _0x7e2aba=_0x2941d2;_0xd7dfed[_0x7e2aba('0x194f')][_0x7e2aba('0x2782')](function(_0x12cc2a){_0x46d865(_0x12cc2a);}),_0xd7dfed['selectedDynamics365Accounts']=[];});}function _0x149361(){const _0x508e15=_0x3ca59d;_0xd7dfed[_0x508e15('0x194f')]=[];}function _0x1b6490(){const _0x404e0b=_0x3ca59d;_0xd7dfed[_0x404e0b('0x194f')]=_0xd7dfed[_0x404e0b('0x2131')]['rows'];}}const _0x23ddc5=_0x386c82,_0x552979=_0x2734b2['p']+_0x36e6f4('0x23d'),_0x474887=_0x2734b2['p']+_0x36e6f4('0xd75');_0xb7e42c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0xb7e42c(_0x4851ad,_0x1c760b,_0x4cc4eb,_0x57f0fa,_0xda87f0){const _0x4ae01f=_0x36e6f4,_0xedf4b0=this;_0xedf4b0[_0x4ae01f('0x98')]=_0xda87f0['getCurrentUser'](),_0xedf4b0[_0x4ae01f('0x10dd')]={},_0xedf4b0['dynamics365Configuration']={},_0xedf4b0[_0x4ae01f('0xd54')]=[],_0xedf4b0['selectedDynamics365Configuration']=-0x1,_0xedf4b0[_0x4ae01f('0x243c')],_0xedf4b0[_0x4ae01f('0x24d5')]=_0x24d50e,_0xedf4b0['getDynamics365Configuration']=_0x3c00a0,_0xedf4b0[_0x4ae01f('0x1dce')]=_0x28ba21,_0xedf4b0[_0x4ae01f('0xa7')]=_0x539fba;function _0x24d50e(_0x4ea373,_0x3042cb){const _0x49b713=_0x4ae01f;_0xedf4b0['dynamics365Account']=_0x4ea373,_0xedf4b0[_0x49b713('0x243c')]=typeof _0x3042cb!=='undefined'?_0x3042cb:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4cc4eb[_0x49b713('0x2176')][_0x49b713('0x13db')]({'id':_0xedf4b0[_0x49b713('0x10dd')]['id'],'sort':_0x49b713('0x14dc')})['$promise'][_0x49b713('0x1166')](function(_0x4b97d2){const _0x233c86=_0x49b713;return _0xedf4b0['configurations']=_0x4b97d2[_0x233c86('0x269a')]?_0x4b97d2[_0x233c86('0x269a')]:[],_0xedf4b0[_0x233c86('0xd54')]['length']&&_0xedf4b0[_0x233c86('0xf27')](0x0),_0x4cc4eb[_0x233c86('0x734')][_0x233c86('0xd83')]({'nolimit':!![],'sort':'name'})['$promise'];})[_0x49b713('0x1166')](function(_0x3e0afd){const _0x11972e=_0x49b713;_0xedf4b0[_0x11972e('0x57a')]=_0x3e0afd[_0x11972e('0x269a')]?_0x3e0afd['rows']:[],_0xedf4b0[_0x11972e('0x217a')]=_0x2cfb05()[_0x11972e('0x155c')](_0xedf4b0[_0x11972e('0x57a')],'id');})['catch'](function(_0x5552f3){const _0x363408=_0x49b713;_0x57f0fa[_0x363408('0xfc9')]({'title':_0x5552f3[_0x363408('0x52d')]?'API:'+_0x5552f3[_0x363408('0x52d')]+'\x20-\x20'+_0x5552f3[_0x363408('0xe1b')]:_0x363408('0x17ab'),'msg':_0x5552f3[_0x363408('0x25f4')]?JSON['stringify'](_0x5552f3[_0x363408('0x25f4')]):_0x5552f3['toString']()});});}function _0x3c00a0(_0x11f3e8){const _0x2cf62f=_0x4ae01f;_0xedf4b0[_0x2cf62f('0x97')]=_0xedf4b0[_0x2cf62f('0xd54')][_0x11f3e8],_0xedf4b0[_0x2cf62f('0x26dc')]=_0x11f3e8,_0x4cc4eb[_0x2cf62f('0xe58')][_0x2cf62f('0x154d')]({'id':_0xedf4b0[_0x2cf62f('0x97')]['id']})[_0x2cf62f('0xa44')][_0x2cf62f('0x1166')](function(_0x2a68e1){const _0x5c1734=_0x2cf62f;return _0xedf4b0[_0x5c1734('0x2701')]=_0x2a68e1['rows']?_0x2a68e1[_0x5c1734('0x269a')]:[],_0x4cc4eb['intDynamics365Configuration'][_0x5c1734('0x28d4')]({'id':_0xedf4b0[_0x5c1734('0x97')]['id']})[_0x5c1734('0xa44')];})[_0x2cf62f('0x1166')](function(_0x3e21bb){const _0x4e0fe3=_0x2cf62f;return _0xedf4b0[_0x4e0fe3('0x1b3d')]=_0x3e21bb[_0x4e0fe3('0x269a')]?_0x3e21bb['rows']:[],_0x4cc4eb[_0x4e0fe3('0xe58')][_0x4e0fe3('0x18ea')]({'id':_0xedf4b0['dynamics365Configuration']['id']})[_0x4e0fe3('0xa44')];})['then'](function(_0x5d0a13){const _0x34b4fb=_0x2cf62f;_0xedf4b0[_0x34b4fb('0xfe2')]=_0x5d0a13[_0x34b4fb('0x269a')]?_0x5d0a13[_0x34b4fb('0x269a')]:[];})['catch'](function(_0x2070d7){const _0xe96dc=_0x2cf62f;_0x57f0fa['error']({'title':_0x2070d7[_0xe96dc('0x52d')]?_0xe96dc('0x1e21')+_0x2070d7['status']+_0xe96dc('0x11e1')+_0x2070d7[_0xe96dc('0xe1b')]:_0xe96dc('0x16c7'),'msg':_0x2070d7['data']?JSON[_0xe96dc('0xbac')](_0x2070d7[_0xe96dc('0x25f4')]):_0x2070d7[_0xe96dc('0x1586')]()});});}function _0x28ba21(_0x37a77b,_0x17e1e6){const _0x3b800a=_0x4ae01f;_0x4851ad['show']({'controller':'CreateOrEditDynamics365ConfigurationDialogController','controllerAs':'vm','templateUrl':_0x552979,'parent':angular[_0x3b800a('0x1194')](_0x1c760b[_0x3b800a('0x8d2')]),'targetEvent':_0x37a77b,'clickOutsideToClose':!![],'locals':{'dynamics365Configuration':_0x17e1e6,'configurations':_0xedf4b0[_0x3b800a('0xd54')],'license':null,'setting':null,'crudPermissions':_0xedf4b0[_0x3b800a('0x243c')]}})[_0x3b800a('0x1951')](function(){const _0x36d294=_0x3b800a;_0xedf4b0[_0x36d294('0xf27')](0x0);});}function _0x539fba(_0x210af2,_0x388644){const _0x37f4c3=_0x4ae01f,_0x94c84d=_0x4851ad[_0x37f4c3('0x1d26')]()[_0x37f4c3('0xcdc')](_0x37f4c3('0x1616'))[_0x37f4c3('0xf3c')](_0x37f4c3('0x12b5')+(_0x388644['name']||_0x37f4c3('0x97'))+_0x37f4c3('0xace')+_0x37f4c3('0x3f3'))[_0x37f4c3('0x8e8')](_0x37f4c3('0x1582'))[_0x37f4c3('0x203b')](_0x210af2)['ok']('OK')[_0x37f4c3('0x3f')]('CANCEL');_0x4851ad[_0x37f4c3('0x1f80')](_0x94c84d)[_0x37f4c3('0x1166')](function(){const _0x81417a=_0x37f4c3;_0x4cc4eb[_0x81417a('0xe58')][_0x81417a('0x906')]({'id':_0x388644['id']})[_0x81417a('0xa44')][_0x81417a('0x1166')](function(){const _0x51945b=_0x81417a;_0x2cfb05()[_0x51945b('0x127f')](_0xedf4b0[_0x51945b('0xd54')],{'id':_0x388644['id']}),_0x57f0fa['success']({'title':'Dynamics365Configuration\x20deleted!','msg':_0x388644[_0x51945b('0x4f0')]?_0x388644['name']+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x2c819){const _0x231348=_0x81417a;_0x57f0fa['error']({'title':_0x2c819[_0x231348('0x52d')]?_0x231348('0x1e21')+_0x2c819[_0x231348('0x52d')]+_0x231348('0x11e1')+_0x2c819[_0x231348('0xe1b')]:_0x231348('0x19a8'),'msg':_0x2c819['data']?JSON[_0x231348('0xbac')](_0x2c819[_0x231348('0x25f4')]):_0x2c819[_0x231348('0x1586')]()});})['finally'](function(){const _0x2f1753=_0x81417a;_0xedf4b0[_0x2f1753('0xf27')](0x0);});},function(){const _0x13fac1=_0x37f4c3;console[_0x13fac1('0x455')](_0x13fac1('0x2d3'));});}_0xedf4b0[_0x4ae01f('0xd02')]=[],_0xedf4b0['createOrEditSubject']=_0x2c2911,_0xedf4b0[_0x4ae01f('0x2059')]=_0x400c36,_0xedf4b0['deleteSelectedSubjects']=_0x5dcab1;function _0x2c2911(_0x2eb32a,_0x443355){const _0x49017f=_0x4ae01f;_0x4851ad[_0x49017f('0x1f80')]({'controller':'CreateOrEditDynamics365AccountItemDialogController','controllerAs':'vm','templateUrl':_0x474887,'parent':angular['element'](_0x1c760b[_0x49017f('0x8d2')]),'targetEvent':_0x2eb32a,'clickOutsideToClose':!![],'locals':{'type':_0x49017f('0x210d'),'item':_0x443355,'items':_0xedf4b0['subjects'],'configuration':_0xedf4b0[_0x49017f('0x97')],'account':_0xedf4b0[_0x49017f('0x10dd')],'license':null,'setting':null,'crudPermissions':_0xedf4b0[_0x49017f('0x243c')]}});}function _0x365eb1(_0x3cbe42){const _0x569ce7=_0x4ae01f;_0x4cc4eb['intDynamics365Field'][_0x569ce7('0x906')]({'id':_0x3cbe42['id']})[_0x569ce7('0xa44')][_0x569ce7('0x1166')](function(){const _0x26259f=_0x569ce7;_0x2cfb05()[_0x26259f('0x127f')](_0xedf4b0['subjects'],{'id':_0x3cbe42['id']}),_0x57f0fa[_0x26259f('0x103b')]({'title':_0x26259f('0x6f'),'msg':_0x26259f('0x259f')});})['catch'](function(_0x1853a8){const _0x315543=_0x569ce7;_0x57f0fa[_0x315543('0xfc9')]({'title':_0x1853a8[_0x315543('0x52d')]?_0x315543('0x1e21')+_0x1853a8[_0x315543('0x52d')]+_0x315543('0x11e1')+_0x1853a8['statusText']:_0x315543('0x23ff'),'msg':_0x1853a8['data']?JSON[_0x315543('0xbac')](_0x1853a8[_0x315543('0x25f4')]):_0x1853a8[_0x315543('0x1586')]()});});}function _0x400c36(_0x28eff6,_0x51908f){const _0x1eb42c=_0x4ae01f,_0x140411=_0x4851ad[_0x1eb42c('0x1d26')]()[_0x1eb42c('0xcdc')](_0x1eb42c('0x11c8'))[_0x1eb42c('0xf3c')](_0x1eb42c('0x277a')+'\x20will\x20be\x20deleted.')[_0x1eb42c('0x8e8')]('delete\x20subject')[_0x1eb42c('0x203b')](_0x28eff6)['ok']('OK')[_0x1eb42c('0x3f')](_0x1eb42c('0x2d3'));_0x4851ad[_0x1eb42c('0x1f80')](_0x140411)[_0x1eb42c('0x1166')](function(){_0x365eb1(_0x51908f);},function(){const _0x299b92=_0x1eb42c;console[_0x299b92('0x455')](_0x299b92('0x2d3'));});}function _0x5dcab1(_0x3d4b49){const _0x189476=_0x4ae01f,_0x13ecc8=_0x4851ad[_0x189476('0x1d26')]()[_0x189476('0xcdc')](_0x189476('0x1d64'))[_0x189476('0xf3c')](_0x189476('0x12b5')+_0xedf4b0[_0x189476('0xd02')][_0x189476('0x264b')]+'\x20selected'+_0x189476('0x3f3'))[_0x189476('0x8e8')](_0x189476('0x5b2'))[_0x189476('0x203b')](_0x3d4b49)['ok']('OK')[_0x189476('0x3f')](_0x189476('0x2d3'));_0x4851ad[_0x189476('0x1f80')](_0x13ecc8)['then'](function(){const _0x39cf4f=_0x189476;_0xedf4b0[_0x39cf4f('0xd02')][_0x39cf4f('0x2782')](function(_0x341825){_0x365eb1(_0x341825);}),_0xedf4b0[_0x39cf4f('0xd02')]=[];});}_0xedf4b0['selectedDescriptions']=[],_0xedf4b0[_0x4ae01f('0x2185')]=_0x27e8f8,_0xedf4b0[_0x4ae01f('0xdf3')]=_0x49d0f1,_0xedf4b0[_0x4ae01f('0x2269')]=_0x538839;function _0x27e8f8(_0x58ca47,_0x21e24b){const _0x53a80c=_0x4ae01f;_0x4851ad[_0x53a80c('0x1f80')]({'controller':_0x53a80c('0xbd1'),'controllerAs':'vm','templateUrl':_0x474887,'parent':angular[_0x53a80c('0x1194')](_0x1c760b['body']),'targetEvent':_0x58ca47,'clickOutsideToClose':!![],'locals':{'type':_0x53a80c('0x101c'),'item':_0x21e24b,'items':_0xedf4b0[_0x53a80c('0x1b3d')],'configuration':_0xedf4b0['dynamics365Configuration'],'account':_0xedf4b0[_0x53a80c('0x10dd')],'license':null,'setting':null,'crudPermissions':_0xedf4b0[_0x53a80c('0x243c')]}});}function _0x3a4d8b(_0x2499aa){const _0x4f7e30=_0x4ae01f;_0x4cc4eb[_0x4f7e30('0x18bb')][_0x4f7e30('0x906')]({'id':_0x2499aa['id']})[_0x4f7e30('0xa44')]['then'](function(){const _0x5ad421=_0x4f7e30;_0x2cfb05()['remove'](_0xedf4b0[_0x5ad421('0x1b3d')],{'id':_0x2499aa['id']}),_0x57f0fa[_0x5ad421('0x103b')]({'title':'Description\x20deleted!','msg':_0x5ad421('0x12ae')});})[_0x4f7e30('0x1a80')](function(_0x13f370){const _0x56b080=_0x4f7e30;_0x57f0fa[_0x56b080('0xfc9')]({'title':_0x13f370[_0x56b080('0x52d')]?'API:'+_0x13f370[_0x56b080('0x52d')]+_0x56b080('0x11e1')+_0x13f370[_0x56b080('0xe1b')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x13f370[_0x56b080('0x25f4')]?JSON['stringify'](_0x13f370['data']):_0x13f370['toString']()});});}function _0x49d0f1(_0x255c6c,_0x2ccb78){const _0x368327=_0x4ae01f,_0xa153ed=_0x4851ad['confirm']()[_0x368327('0xcdc')](_0x368327('0x1baa'))[_0x368327('0xf3c')]('Description'+_0x368327('0x3f3'))[_0x368327('0x8e8')]('delete\x20description')['targetEvent'](_0x255c6c)['ok']('OK')[_0x368327('0x3f')](_0x368327('0x2d3'));_0x4851ad['show'](_0xa153ed)[_0x368327('0x1166')](function(){_0x3a4d8b(_0x2ccb78);},function(){const _0x4eb0b8=_0x368327;console['log'](_0x4eb0b8('0x2d3'));});}function _0x538839(_0x1f153a){const _0x358910=_0x4ae01f,_0x1af084=_0x4851ad[_0x358910('0x1d26')]()[_0x358910('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20descriptions?')[_0x358910('0xf3c')](_0x358910('0x12b5')+_0xedf4b0[_0x358910('0x968')][_0x358910('0x264b')]+_0x358910('0x196d')+_0x358910('0x3f3'))[_0x358910('0x8e8')](_0x358910('0x17a'))[_0x358910('0x203b')](_0x1f153a)['ok']('OK')[_0x358910('0x3f')]('CANCEL');_0x4851ad['show'](_0x1af084)[_0x358910('0x1166')](function(){const _0x422651=_0x358910;_0xedf4b0['selectedDescriptions']['forEach'](function(_0x2df363){_0x3a4d8b(_0x2df363);}),_0xedf4b0[_0x422651('0x968')]=[];});}_0xedf4b0[_0x4ae01f('0x16')]=[],_0xedf4b0[_0x4ae01f('0x27ad')]=_0x54087f,_0xedf4b0['deleteFieldConfirm']=_0xa9115b,_0xedf4b0['deleteSelectedFields']=_0x6b5d9f;function _0x54087f(_0x5c0c49,_0x4ea011){const _0x259f74=_0x4ae01f;_0x4851ad['show']({'controller':_0x259f74('0xbd1'),'controllerAs':'vm','templateUrl':_0x474887,'parent':angular[_0x259f74('0x1194')](_0x1c760b[_0x259f74('0x8d2')]),'targetEvent':_0x5c0c49,'clickOutsideToClose':!![],'locals':{'type':_0x259f74('0x22f3'),'item':_0x4ea011,'items':_0xedf4b0[_0x259f74('0xfe2')],'configuration':_0xedf4b0[_0x259f74('0x97')],'account':_0xedf4b0['dynamics365Account'],'license':null,'setting':null,'crudPermissions':_0xedf4b0[_0x259f74('0x243c')]}});}function _0x48632d(_0x1b3153){const _0xf068fc=_0x4ae01f;_0x4cc4eb['intDynamics365Field']['delete']({'id':_0x1b3153['id']})[_0xf068fc('0xa44')][_0xf068fc('0x1166')](function(){const _0x4058c2=_0xf068fc;_0x2cfb05()[_0x4058c2('0x127f')](_0xedf4b0['fields'],{'id':_0x1b3153['id']}),_0x57f0fa['success']({'title':_0x4058c2('0x13cb'),'msg':_0x4058c2('0x31e')});})[_0xf068fc('0x1a80')](function(_0x3b653d){const _0xb53d8d=_0xf068fc;_0x57f0fa[_0xb53d8d('0xfc9')]({'title':_0x3b653d[_0xb53d8d('0x52d')]?_0xb53d8d('0x1e21')+_0x3b653d[_0xb53d8d('0x52d')]+'\x20-\x20'+_0x3b653d[_0xb53d8d('0xe1b')]:_0xb53d8d('0x23ff'),'msg':_0x3b653d[_0xb53d8d('0x25f4')]?JSON[_0xb53d8d('0xbac')](_0x3b653d[_0xb53d8d('0x25f4')]):_0x3b653d[_0xb53d8d('0x1586')]()});});}function _0xa9115b(_0x3f9bc6,_0xb924cd){const _0x3c32ac=_0x4ae01f,_0x498152=_0x4851ad[_0x3c32ac('0x1d26')]()[_0x3c32ac('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x3c32ac('0xf3c')](_0x3c32ac('0x13e0')+_0x3c32ac('0x3f3'))[_0x3c32ac('0x8e8')]('delete\x20field')[_0x3c32ac('0x203b')](_0x3f9bc6)['ok']('OK')[_0x3c32ac('0x3f')]('CANCEL');_0x4851ad['show'](_0x498152)['then'](function(){_0x48632d(_0xb924cd);},function(){const _0x30a1f6=_0x3c32ac;console['log'](_0x30a1f6('0x2d3'));});}function _0x6b5d9f(_0xe3526a){const _0x20898e=_0x4ae01f,_0x12a7dd=_0x4851ad[_0x20898e('0x1d26')]()[_0x20898e('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20fields?')['htmlContent'](_0x20898e('0x12b5')+_0xedf4b0['selectedFields']['length']+_0x20898e('0x196d')+_0x20898e('0x3f3'))[_0x20898e('0x8e8')]('delete\x20fields')['targetEvent'](_0xe3526a)['ok']('OK')[_0x20898e('0x3f')](_0x20898e('0x2d3'));_0x4851ad[_0x20898e('0x1f80')](_0x12a7dd)[_0x20898e('0x1166')](function(){const _0x3e6548=_0x20898e;_0xedf4b0[_0x3e6548('0x16')][_0x3e6548('0x2782')](function(_0x1dd53f){_0x48632d(_0x1dd53f);}),_0xedf4b0[_0x3e6548('0x16')]=[];});}}const _0x6e1e7f=_0xb7e42c;_0x59ead9[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'configurations','dynamics365Configuration','api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting','crudPermissions'];function _0x59ead9(_0x3ef2fc,_0x25d826,_0x4027ac,_0x2aa6bc,_0x10a068,_0x234d52,_0x156d5e,_0x3ced35,_0x3b18f1,_0x1a0626,_0x5572c7,_0x53df02,_0x44924b,_0x2829a2){const _0xcb9bd8=_0x36e6f4,_0x3faa4c=this;_0x3faa4c['currentUser']=_0x5572c7[_0xcb9bd8('0x26cd')](),_0x3faa4c[_0xcb9bd8('0x61a')]=[],_0x3faa4c[_0xcb9bd8('0xf8a')]=_0x44924b,_0x3faa4c[_0xcb9bd8('0x5c9')]=_0x53df02,_0x3faa4c[_0xcb9bd8('0x243c')]=_0x2829a2,_0x3faa4c[_0xcb9bd8('0x128b')]={},_0x3faa4c[_0xcb9bd8('0x2900')]=_0x3faa4c[_0xcb9bd8('0xf8a')]&&_0x3faa4c[_0xcb9bd8('0xf8a')][_0xcb9bd8('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3faa4c[_0xcb9bd8('0xcdc')]=_0xcb9bd8('0x19e9'),_0x3faa4c[_0xcb9bd8('0x97')]=angular[_0xcb9bd8('0x225f')](_0x3b18f1),_0x3faa4c['configurations']=_0x3ced35,_0x3faa4c[_0xcb9bd8('0x1ae4')]=![];!_0x3faa4c[_0xcb9bd8('0x97')]&&(_0x3faa4c[_0xcb9bd8('0x97')]={'channel':_0xcb9bd8('0x21da'),'type':_0xcb9bd8('0x14d8'),'ticketType':_0xcb9bd8('0x12f3')},_0x3faa4c[_0xcb9bd8('0xcdc')]=_0xcb9bd8('0x1b33'),_0x3faa4c[_0xcb9bd8('0x1ae4')]=!![]);_0x3faa4c[_0xcb9bd8('0x1a70')]=_0x513c56,_0x3faa4c[_0xcb9bd8('0x1588')]=_0x3e7cf2,_0x3faa4c[_0xcb9bd8('0xa7')]=_0x4e164d,_0x3faa4c['getDateFromString']=_0x528c06,_0x3faa4c[_0xcb9bd8('0x24a0')]=_0x422d4e;function _0x513c56(){const _0x1a3222=_0xcb9bd8;_0x3faa4c[_0x1a3222('0x61a')]=[],_0x1a0626[_0x1a3222('0x2176')][_0x1a3222('0x274a')]({'id':_0x25d826[_0x1a3222('0x23f')]['id']},_0x3faa4c[_0x1a3222('0x97')])['$promise'][_0x1a3222('0x1166')](function(_0x4c3b9b){const _0x554a16=_0x1a3222;_0x3faa4c[_0x554a16('0xd54')]['unshift'](_0x4c3b9b[_0x554a16('0x2876')]()),_0x156d5e[_0x554a16('0x103b')]({'title':'Dynamics365Configuration\x20properly\x20created','msg':_0x3faa4c[_0x554a16('0x97')][_0x554a16('0x4f0')]?_0x3faa4c[_0x554a16('0x97')][_0x554a16('0x4f0')]+_0x554a16('0x1eda'):''}),_0x422d4e(_0x4c3b9b);})[_0x1a3222('0x1a80')](function(_0x29c786){const _0x388b25=_0x1a3222;if(_0x29c786[_0x388b25('0x25f4')]&&_0x29c786[_0x388b25('0x25f4')][_0x388b25('0x61a')]&&_0x29c786[_0x388b25('0x25f4')][_0x388b25('0x61a')]['length']){_0x3faa4c[_0x388b25('0x61a')]=_0x29c786[_0x388b25('0x25f4')][_0x388b25('0x61a')]||[{'message':_0x29c786[_0x388b25('0x1586')](),'type':_0x388b25('0x1d81')}];for(let _0x25fb36=0x0;_0x25fb36<_0x29c786['data'][_0x388b25('0x61a')]['length'];_0x25fb36+=0x1){_0x156d5e[_0x388b25('0xfc9')]({'title':_0x29c786[_0x388b25('0x25f4')][_0x388b25('0x61a')][_0x25fb36][_0x388b25('0x1345')],'msg':_0x29c786[_0x388b25('0x25f4')][_0x388b25('0x61a')][_0x25fb36][_0x388b25('0x1e70')]});}}else _0x156d5e['error']({'title':_0x29c786['status']?_0x388b25('0x1e21')+_0x29c786[_0x388b25('0x52d')]+_0x388b25('0x11e1')+_0x29c786['statusText']:_0x388b25('0x1d81'),'msg':_0x29c786[_0x388b25('0x25f4')]?JSON[_0x388b25('0xbac')](_0x29c786[_0x388b25('0x25f4')]['message']):_0x29c786['toString']()});});}function _0x3e7cf2(){const _0x60468e=_0xcb9bd8;_0x3faa4c[_0x60468e('0x61a')]=[],_0x1a0626[_0x60468e('0xe58')][_0x60468e('0x1449')]({'id':_0x3faa4c[_0x60468e('0x97')]['id']},_0x3faa4c[_0x60468e('0x97')])[_0x60468e('0xa44')][_0x60468e('0x1166')](function(_0x299f8b){const _0x33a0ad=_0x60468e,_0x378fdf=_0x2cfb05()[_0x33a0ad('0xc38')](_0x3faa4c[_0x33a0ad('0xd54')],{'id':_0x299f8b['id']});_0x378fdf&&_0x2cfb05()['merge'](_0x378fdf,_0x2cfb05()['pick'](_0x299f8b['toJSON'](),_0x2cfb05()['keys'](_0x378fdf))),_0x156d5e[_0x33a0ad('0x103b')]({'title':_0x33a0ad('0xd86'),'msg':_0x3faa4c[_0x33a0ad('0x97')][_0x33a0ad('0x4f0')]?_0x3faa4c['dynamics365Configuration'][_0x33a0ad('0x4f0')]+_0x33a0ad('0x7d'):''}),_0x422d4e(_0x299f8b);})['catch'](function(_0x30d7e0){const _0x559711=_0x60468e;if(_0x30d7e0[_0x559711('0x25f4')]&&_0x30d7e0['data'][_0x559711('0x61a')]&&_0x30d7e0[_0x559711('0x25f4')]['errors'][_0x559711('0x264b')]){_0x3faa4c[_0x559711('0x61a')]=_0x30d7e0[_0x559711('0x25f4')][_0x559711('0x61a')]||[{'message':_0x30d7e0[_0x559711('0x1586')](),'type':_0x559711('0x1db5')}];for(let _0xae928f=0x0;_0xae928f<_0x30d7e0[_0x559711('0x25f4')][_0x559711('0x61a')][_0x559711('0x264b')];_0xae928f++){_0x156d5e['error']({'title':_0x30d7e0['data'][_0x559711('0x61a')][_0xae928f][_0x559711('0x1345')],'msg':_0x30d7e0[_0x559711('0x25f4')]['errors'][_0xae928f][_0x559711('0x1e70')]});}}else _0x156d5e[_0x559711('0xfc9')]({'title':_0x30d7e0[_0x559711('0x52d')]?'API:'+_0x30d7e0[_0x559711('0x52d')]+_0x559711('0x11e1')+_0x30d7e0[_0x559711('0xe1b')]:_0x559711('0x1db5'),'msg':_0x30d7e0[_0x559711('0x25f4')]?JSON['stringify'](_0x30d7e0[_0x559711('0x25f4')][_0x559711('0x1e70')]):_0x30d7e0['toString']()});});}function _0x4e164d(_0x521029){const _0x1614c7=_0xcb9bd8;_0x3faa4c[_0x1614c7('0x61a')]=[];const _0xa3ef34=_0x2aa6bc[_0x1614c7('0x1d26')]()[_0x1614c7('0xcdc')](_0x1614c7('0x7fb'))[_0x1614c7('0xacc')](_0x1614c7('0x2628'))['ariaLabel'](_0x1614c7('0x17f8'))['ok']('Delete')['cancel'](_0x1614c7('0x497'))[_0x1614c7('0x203b')](_0x521029);_0x2aa6bc[_0x1614c7('0x1f80')](_0xa3ef34)['then'](function(){const _0x1d68d0=_0x1614c7;_0x1a0626[_0x1d68d0('0xe58')][_0x1d68d0('0x906')]({'id':_0x3faa4c['dynamics365Configuration']['id']})[_0x1d68d0('0xa44')][_0x1d68d0('0x1166')](function(){const _0x22b919=_0x1d68d0;_0x2cfb05()[_0x22b919('0x127f')](_0x3faa4c[_0x22b919('0xd54')],{'id':_0x3faa4c[_0x22b919('0x97')]['id']}),_0x156d5e[_0x22b919('0x103b')]({'title':_0x22b919('0xeb4'),'msg':(_0x3faa4c[_0x22b919('0x97')]['name']||_0x22b919('0x97'))+_0x22b919('0x7cd')}),_0x422d4e(_0x3faa4c[_0x22b919('0x97')]);})[_0x1d68d0('0x1a80')](function(_0x37b343){const _0x340c37=_0x1d68d0;if(_0x37b343[_0x340c37('0x25f4')]&&_0x37b343[_0x340c37('0x25f4')][_0x340c37('0x61a')]&&_0x37b343['data'][_0x340c37('0x61a')][_0x340c37('0x264b')]){_0x3faa4c['errors']=_0x37b343[_0x340c37('0x25f4')][_0x340c37('0x61a')]||[{'message':_0x37b343[_0x340c37('0x1586')](),'type':_0x340c37('0x19fc')}];for(let _0xf23de4=0x0;_0xf23de4<_0x37b343[_0x340c37('0x25f4')]['errors'][_0x340c37('0x264b')];_0xf23de4++){_0x156d5e[_0x340c37('0xfc9')]({'title':_0x37b343[_0x340c37('0x25f4')]['errors'][_0xf23de4][_0x340c37('0x1345')],'msg':_0x37b343[_0x340c37('0x25f4')][_0x340c37('0x61a')][_0xf23de4][_0x340c37('0x1e70')]});}}else _0x156d5e[_0x340c37('0xfc9')]({'title':_0x37b343['status']?_0x340c37('0x1e21')+_0x37b343[_0x340c37('0x52d')]+'\x20-\x20'+_0x37b343[_0x340c37('0xe1b')]:_0x340c37('0x19fc'),'msg':_0x37b343[_0x340c37('0x25f4')]?JSON[_0x340c37('0xbac')](_0x37b343[_0x340c37('0x25f4')]['message']):_0x37b343[_0x340c37('0x1e70')]||_0x37b343[_0x340c37('0x1586')]()});});},function(){});}function _0x528c06(_0x55a2f){return _0x55a2f===null?undefined:new Date(_0x55a2f);}function _0x422d4e(_0x1e8a88){const _0xc0705=_0xcb9bd8;_0x2aa6bc[_0xc0705('0x1197')](_0x1e8a88);}}const _0x40a601=_0x59ead9;_0x7a497a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'toasty',_0x36e6f4('0xd29'),_0x36e6f4('0xbd7'),_0x36e6f4('0x1301'),_0x36e6f4('0x1a32'),_0x36e6f4('0x1345'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x7a497a(_0x5a9bc2,_0x5f0e9b,_0x59d650,_0x2bfa0e,_0x5653db,_0x293a2c,_0x13ec77,_0x519358,_0x467d87,_0x1a7ec0,_0x11da78,_0x4b617f,_0x2e9cf4){const _0x42a815=_0x36e6f4,_0x2783b6=this;_0x2783b6['currentUser']=_0x4b617f[_0x42a815('0x26cd')](),_0x2783b6[_0x42a815('0x61a')]=[],_0x2783b6[_0x42a815('0xcdc')]='INTEGRATIONS.EDIT_'+_0x2cfb05()[_0x42a815('0x113b')](_0x1a7ec0),_0x2783b6[_0x42a815('0x1301')]=angular[_0x42a815('0x225f')](_0x519358),_0x2783b6[_0x42a815('0xbd7')]=_0x13ec77,_0x2783b6[_0x42a815('0x1345')]=_0x1a7ec0,_0x2783b6['crudPermissions']=_0x2e9cf4,_0x2783b6[_0x42a815('0x17c7')]=![];!_0x2783b6[_0x42a815('0x1301')]&&(_0x2783b6[_0x42a815('0x1301')]={'type':_0x42a815('0x102c')},_0x2783b6['item'][_0x2cfb05()[_0x42a815('0x92c')](_0x1a7ec0)+'Id']=_0x293a2c['id'],_0x2783b6[_0x42a815('0xcdc')]='INTEGRATIONS.NEW_'+_0x2cfb05()[_0x42a815('0x113b')](_0x1a7ec0),_0x2783b6[_0x42a815('0x17c7')]=!![]);_0x2783b6[_0x42a815('0x1e8a')]=_0x371a76,_0x2783b6[_0x42a815('0x13b8')]=_0xf723b7,_0x2783b6[_0x42a815('0x18d3')]=_0x93eabc,_0x2783b6[_0x42a815('0x1551')]=_0x2a9ae5,_0x2783b6[_0x42a815('0x24a0')]=_0x110a92,_0x11da78[_0x42a815('0x734')][_0x42a815('0xd83')]({'nolimit':!![]})[_0x42a815('0xa44')][_0x42a815('0x1166')](function(_0xddd19f){const _0x7974be=_0x42a815;return _0x2783b6['variables']=_0xddd19f[_0x7974be('0x269a')]?_0xddd19f[_0x7974be('0x269a')]:[],_0x11da78[_0x7974be('0x7af')][_0x7974be('0x23d0')]()[_0x7974be('0xa44')];})[_0x42a815('0x1166')](function(_0x244c4a){const _0x5d2b93=_0x42a815;return _0x2783b6['voiceAgentReportColumns']=_0x2cfb05()[_0x5d2b93('0x13ca')](_0x2cfb05()[_0x5d2b93('0x14a4')](_0x244c4a),[_0x5d2b93('0xa44'),'$resolved','createdAt',_0x5d2b93('0x6f9'),_0x5d2b93('0x978')]),_0x2783b6['voiceAgentReportColumns'][_0x5d2b93('0x1514')](_0x5d2b93('0xa29')),_0x11da78[_0x5d2b93('0x21f9')]['describe']()[_0x5d2b93('0xa44')];})['then'](function(_0x118f62){const _0x5d43cd=_0x42a815;_0x2783b6['voiceDialReportColumns']=_0x2cfb05()['difference'](_0x2cfb05()[_0x5d43cd('0x14a4')](_0x118f62),[_0x5d43cd('0xa44'),_0x5d43cd('0xfcd'),'createdAt','updatedAt',_0x5d43cd('0x978')]),_0x2783b6[_0x5d43cd('0x1348')][_0x5d43cd('0x1514')](_0x5d43cd('0xa29'));})['catch'](function(_0x2d0b27){const _0x22dc61=_0x42a815;_0x5653db['error']({'title':_0x2d0b27['status']?_0x22dc61('0x1e21')+_0x2d0b27[_0x22dc61('0x52d')]+'\x20-\x20'+_0x2d0b27['statusText']:'SYSTEM:GETVARIABLES','msg':_0x2d0b27[_0x22dc61('0x25f4')]?JSON['stringify'](_0x2d0b27[_0x22dc61('0x25f4')]):_0x2d0b27[_0x22dc61('0x1586')]()});}),_0x11da78['intDynamics365Account'][_0x42a815('0x18ea')]({'id':_0x467d87['id'],'ticketType':_0x293a2c[_0x42a815('0x11ba')]?_0x293a2c[_0x42a815('0x11ba')]:undefined})['$promise']['then'](function(_0x59e46b){const _0x48f18d=_0x42a815;_0x2783b6['accountConnected']=!![],_0x2783b6['fields']=_0x59e46b[_0x48f18d('0x269a')]?_0x59e46b[_0x48f18d('0x269a')]:[],_0x2783b6['item'][_0x48f18d('0x1143')]&&(_0x2783b6['customField']=_0x2cfb05()[_0x48f18d('0xc38')](_0x2783b6[_0x48f18d('0xfe2')],{'id':_0x2783b6['item']['idField']}));})['catch'](function(_0x137974){const _0x457c2e=_0x42a815;_0x2783b6[_0x457c2e('0x606')]=![],console[_0x457c2e('0xfc9')](_0x137974);});function _0x371a76(){const _0x47ffed=_0x42a815;_0x2783b6['errors']=[],_0x2783b6[_0x47ffed('0x117e')]&&(_0x2783b6[_0x47ffed('0x1301')]['idField']=_0x2783b6[_0x47ffed('0x117e')]['id'],_0x2783b6['item'][_0x47ffed('0x3c0')]=_0x2783b6[_0x47ffed('0x117e')][_0x47ffed('0x4f0')],_0x2783b6[_0x47ffed('0x1301')][_0x47ffed('0x117e')]=_0x2783b6[_0x47ffed('0x117e')][_0x47ffed('0x2853')]),_0x11da78[_0x47ffed('0x18bb')][_0x47ffed('0x9cc')](_0x2783b6[_0x47ffed('0x1301')])[_0x47ffed('0xa44')]['then'](function(_0x536b8b){const _0x57c483=_0x47ffed;_0x2783b6[_0x57c483('0xbd7')][_0x57c483('0x2450')](_0x536b8b),_0x5653db[_0x57c483('0x103b')]({'title':_0x2cfb05()[_0x57c483('0x92c')](_0x1a7ec0)+_0x57c483('0x13f0'),'msg':_0x2cfb05()[_0x57c483('0x92c')](_0x1a7ec0)+_0x57c483('0x1eda')}),_0x110a92();})[_0x47ffed('0x1a80')](function(_0x2e99f2){const _0x451186=_0x47ffed;console[_0x451186('0xfc9')](_0x2e99f2),_0x2783b6[_0x451186('0x61a')]=_0x2e99f2[_0x451186('0x25f4')][_0x451186('0x61a')]||[{'message':_0x2e99f2[_0x451186('0x1586')](),'type':_0x451186('0x215d')}];});}function _0xf723b7(){const _0x4bcef1=_0x42a815;_0x2783b6[_0x4bcef1('0x61a')]=[],_0x2783b6[_0x4bcef1('0x117e')]&&(_0x2783b6[_0x4bcef1('0x1301')][_0x4bcef1('0x1143')]=_0x2783b6[_0x4bcef1('0x117e')]['id'],_0x2783b6['item'][_0x4bcef1('0x3c0')]=_0x2783b6['customField'][_0x4bcef1('0x4f0')],_0x2783b6[_0x4bcef1('0x1301')][_0x4bcef1('0x117e')]=_0x2783b6[_0x4bcef1('0x117e')][_0x4bcef1('0x2853')]),_0x11da78['intDynamics365Field'][_0x4bcef1('0x1449')]({'id':_0x2783b6[_0x4bcef1('0x1301')]['id']},_0x2783b6['item'])[_0x4bcef1('0xa44')][_0x4bcef1('0x1166')](function(_0x30e5ff){const _0x593812=_0x4bcef1,_0x23143d=_0x2cfb05()[_0x593812('0xc38')](_0x2783b6[_0x593812('0xbd7')],{'id':_0x30e5ff['id']});_0x23143d&&_0x2cfb05()[_0x593812('0xcc3')](_0x23143d,_0x30e5ff),_0x5653db['success']({'title':_0x2cfb05()[_0x593812('0x92c')](_0x1a7ec0)+_0x593812('0x1a2f'),'msg':_0x2cfb05()['capitalize'](_0x1a7ec0)+'\x20has\x20been\x20saved!'}),_0x110a92();})[_0x4bcef1('0x1a80')](function(_0x580988){const _0x2dde15=_0x4bcef1;console[_0x2dde15('0xfc9')](_0x580988),_0x2783b6[_0x2dde15('0x61a')]=_0x580988[_0x2dde15('0x25f4')][_0x2dde15('0x61a')]||[{'message':_0x580988[_0x2dde15('0x1586')](),'type':'api.intItem.update'}];});}function _0x93eabc(_0x1c1bd5){const _0x482ddd=_0x42a815;_0x2783b6[_0x482ddd('0x61a')]=[];const _0x5d9806=_0x2bfa0e[_0x482ddd('0x1d26')]()[_0x482ddd('0xcdc')](_0x482ddd('0x7fb'))[_0x482ddd('0xacc')](_0x482ddd('0x135f')+_0x1a7ec0+_0x482ddd('0x3f3'))[_0x482ddd('0x8e8')](_0x482ddd('0x237c')+_0x2cfb05()[_0x482ddd('0x92c')](_0x1a7ec0))['ok'](_0x482ddd('0x18'))['cancel'](_0x482ddd('0x497'))['targetEvent'](_0x1c1bd5);_0x2bfa0e[_0x482ddd('0x1f80')](_0x5d9806)[_0x482ddd('0x1166')](function(){const _0x599d79=_0x482ddd;_0x11da78[_0x599d79('0x18bb')]['delete']({'id':_0x2783b6[_0x599d79('0x1301')]['id']})['$promise'][_0x599d79('0x1166')](function(){const _0x7f5e93=_0x599d79;_0x2cfb05()[_0x7f5e93('0x127f')](_0x2783b6[_0x7f5e93('0xbd7')],{'id':_0x2783b6[_0x7f5e93('0x1301')]['id']}),_0x5653db[_0x7f5e93('0x103b')]({'title':_0x2cfb05()[_0x7f5e93('0x92c')](_0x1a7ec0)+'\x20properly\x20deleted!','msg':_0x2cfb05()[_0x7f5e93('0x92c')](_0x1a7ec0)+'\x20has\x20been\x20deleted!'}),_0x110a92();})['catch'](function(_0x136f71){const _0x4ea555=_0x599d79;console[_0x4ea555('0xfc9')](_0x136f71),_0x2783b6[_0x4ea555('0x61a')]=_0x136f71[_0x4ea555('0x25f4')][_0x4ea555('0x61a')]||[{'message':_0x136f71[_0x4ea555('0x1586')](),'type':_0x4ea555('0x2602')}];});},function(){});}function _0x2a9ae5(){const _0x5ea5e7=_0x42a815;return _0x2783b6[_0x5ea5e7('0x1301')][_0x5ea5e7('0xbdb')]!==undefined?_0x2783b6[_0x5ea5e7('0x1301')]['variableName']:_0x5ea5e7('0x16a4');}function _0x110a92(){const _0x469644=_0x42a815;_0x2bfa0e[_0x469644('0x1197')]();}}const _0x48776e=_0x7a497a;_0x9844c7[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),'license','setting',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x10dd'),_0x36e6f4('0x17aa')];function _0x9844c7(_0x542640,_0x13ee03,_0x23dce1,_0x58b8f2,_0x5cf590,_0x29ddb3,_0x50ebde,_0x41c734,_0x42a2ed,_0xc9e60e,_0x51bf39,_0xbcf291){const _0x36f092=_0x36e6f4,_0x3da2bb=this;_0x3da2bb['currentUser']=_0xc9e60e[_0x36f092('0x26cd')](),_0x3da2bb[_0x36f092('0x5c9')]=_0x29ddb3,_0x3da2bb[_0x36f092('0xf8a')]=_0x50ebde,_0x3da2bb[_0x36f092('0x2900')]=_0x3da2bb[_0x36f092('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3da2bb['location']=_0x13ee03[_0x36f092('0x6f1')]()+'://'+_0x13ee03['host'](),_0x3da2bb['dynamics365Account']=_0x51bf39||_0x542640[_0x36f092('0x23f')][_0x36f092('0x10dd')]||{},_0x3da2bb[_0x36f092('0x17aa')]=_0xbcf291&&_0xbcf291[_0x36f092('0x240f')]==0x1?_0xbcf291[_0x36f092('0x269a')][0x0]:null,_0x3da2bb['crudPermissions']=_0xc9e60e[_0x36f092('0xd87')](_0x3da2bb[_0x36f092('0x17aa')]?_0x3da2bb[_0x36f092('0x17aa')]['crudPermissions']:null),_0x3da2bb[_0x36f092('0x128b')]={},_0x3da2bb[_0x36f092('0x2669')]=_0x542640[_0x36f092('0x23f')][_0x36f092('0xbe3')]||0x0,_0x3da2bb[_0x36f092('0x31d')]=_0x42a2ed[_0x36f092('0x1fa1')],_0x3da2bb[_0x36f092('0x1632')]=_0x14d8d1,_0x3da2bb[_0x36f092('0x1ed0')]=_0x3ad7f5;function _0x14d8d1(){const _0xae7934=_0x36f092;_0x542640['go'](_0xae7934('0x280c'),{},{'reload':_0xae7934('0x280c')});}function _0x3ad7f5(){const _0x156d02=_0x36f092;_0x41c734['intDynamics365Account'][_0x156d02('0x1449')]({'id':_0x3da2bb[_0x156d02('0x10dd')]['id']},_0x3da2bb[_0x156d02('0x10dd')])['$promise'][_0x156d02('0x1166')](function(){const _0x4e459a=_0x156d02;_0x42a2ed[_0x4e459a('0x103b')]({'title':_0x4e459a('0x83b'),'msg':_0x3da2bb[_0x4e459a('0x10dd')][_0x4e459a('0x4f0')]?_0x3da2bb[_0x4e459a('0x10dd')][_0x4e459a('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x156d02('0x1a80')](function(_0x2309d3){const _0x132c6b=_0x156d02;_0x42a2ed[_0x132c6b('0xfc9')]({'title':_0x2309d3['status']?_0x132c6b('0x1e21')+_0x2309d3[_0x132c6b('0x52d')]+_0x132c6b('0x11e1')+_0x2309d3[_0x132c6b('0xe1b')]:'SYSTEM:GETintDynamics365Account','msg':_0x2309d3[_0x132c6b('0x25f4')]?JSON[_0x132c6b('0xbac')](_0x2309d3[_0x132c6b('0x25f4')]):_0x2309d3[_0x132c6b('0x1586')]()});});}}const _0x596ed4=_0x9844c7;_0x4578d6['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate','toasty',_0x36e6f4('0x22f9'),_0x36e6f4('0xda0'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x4578d6(_0x117a73,_0x4ac021,_0x56b83d,_0xb42470,_0xb8251f,_0x5dcad7,_0x56ecbd,_0x68bf98,_0x12c88f,_0x132caa,_0x5573ff,_0x2fc8bc,_0x4ef6dd,_0x2c724f){const _0x160f75=_0x36e6f4,_0xef7fd7=this;_0xef7fd7[_0x160f75('0x98')]=_0x5573ff[_0x160f75('0x26cd')](),_0xef7fd7[_0x160f75('0x61a')]=[],_0xef7fd7[_0x160f75('0xf8a')]=_0x4ef6dd,_0xef7fd7['license']=_0x2fc8bc,_0xef7fd7[_0x160f75('0x243c')]=_0x2c724f,_0xef7fd7[_0x160f75('0x128b')]={},_0xef7fd7[_0x160f75('0x2900')]=_0xef7fd7[_0x160f75('0xf8a')]&&_0xef7fd7[_0x160f75('0xf8a')][_0x160f75('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xef7fd7[_0x160f75('0xcdc')]=_0x160f75('0x2406'),_0xef7fd7[_0x160f75('0xda0')]=angular[_0x160f75('0x225f')](_0x12c88f),_0xef7fd7[_0x160f75('0x22f9')]=_0x68bf98,_0xef7fd7[_0x160f75('0xcf0')]=![];!_0xef7fd7['freshdeskAccount']&&(_0xef7fd7['freshdeskAccount']={'serverUrl':_0x56b83d[_0x160f75('0x6f1')]()+'://'+_0x56b83d[_0x160f75('0x1690')]()+(_0x56b83d[_0x160f75('0x93d')]()?':'+_0x56b83d[_0x160f75('0x93d')]():'')},_0xef7fd7[_0x160f75('0xcdc')]=_0x160f75('0xdde'),_0xef7fd7[_0x160f75('0xcf0')]=!![]);_0xef7fd7[_0x160f75('0x829')]=_0x4e412c,_0xef7fd7['saveFreshdeskAccount']=_0x37759c,_0xef7fd7[_0x160f75('0xd90')]=_0x40e177,_0xef7fd7['getDateFromString']=_0xbb133a,_0xef7fd7[_0x160f75('0x24a0')]=_0x4c871b;function _0x4e412c(){const _0x57e8b0=_0x160f75;_0xef7fd7[_0x57e8b0('0x61a')]=[],_0x132caa[_0x57e8b0('0xc1e')][_0x57e8b0('0x9cc')](_0xef7fd7[_0x57e8b0('0xda0')])[_0x57e8b0('0xa44')][_0x57e8b0('0x1166')](function(_0x4cb503){const _0x379e8e=_0x57e8b0;_0xef7fd7[_0x379e8e('0x22f9')][_0x379e8e('0x2450')](_0x4cb503['toJSON']()),_0x56ecbd[_0x379e8e('0x103b')]({'title':_0x379e8e('0x1b16'),'msg':_0xef7fd7['freshdeskAccount'][_0x379e8e('0x4f0')]?_0xef7fd7[_0x379e8e('0xda0')]['name']+'\x20has\x20been\x20created!':''}),_0x4c871b(_0x4cb503);})[_0x57e8b0('0x1a80')](function(_0x33799a){const _0x181134=_0x57e8b0;if(_0x33799a[_0x181134('0x25f4')]&&_0x33799a[_0x181134('0x25f4')][_0x181134('0x61a')]&&_0x33799a[_0x181134('0x25f4')]['errors'][_0x181134('0x264b')]){_0xef7fd7[_0x181134('0x61a')]=_0x33799a[_0x181134('0x25f4')][_0x181134('0x61a')]||[{'message':_0x33799a['toString'](),'type':_0x181134('0xd22')}];for(let _0x210a58=0x0;_0x210a58<_0x33799a[_0x181134('0x25f4')][_0x181134('0x61a')][_0x181134('0x264b')];_0x210a58+=0x1){_0x56ecbd[_0x181134('0xfc9')]({'title':_0x33799a[_0x181134('0x25f4')][_0x181134('0x61a')][_0x210a58][_0x181134('0x1345')],'msg':_0x33799a[_0x181134('0x25f4')][_0x181134('0x61a')][_0x210a58][_0x181134('0x1e70')]});}}else _0x56ecbd['error']({'title':_0x33799a[_0x181134('0x52d')]?'API:'+_0x33799a['status']+_0x181134('0x11e1')+_0x33799a[_0x181134('0xe1b')]:'api.intFreshdeskAccount.save','msg':_0x33799a[_0x181134('0x25f4')]?JSON[_0x181134('0xbac')](_0x33799a[_0x181134('0x25f4')]['message']):_0x33799a[_0x181134('0x1586')]()});});}function _0x37759c(){const _0x446f14=_0x160f75;_0xef7fd7[_0x446f14('0x61a')]=[],_0x132caa[_0x446f14('0xc1e')][_0x446f14('0x1449')]({'id':_0xef7fd7['freshdeskAccount']['id']},_0xef7fd7['freshdeskAccount'])['$promise'][_0x446f14('0x1166')](function(_0xf5dda7){const _0x53d5e4=_0x446f14,_0x1e0e22=_0x2cfb05()[_0x53d5e4('0xc38')](_0xef7fd7[_0x53d5e4('0x22f9')],{'id':_0xf5dda7['id']});_0x1e0e22&&_0x2cfb05()[_0x53d5e4('0xcc3')](_0x1e0e22,_0x2cfb05()['pick'](_0xf5dda7[_0x53d5e4('0x2876')](),_0x2cfb05()[_0x53d5e4('0x14a4')](_0x1e0e22))),_0x56ecbd[_0x53d5e4('0x103b')]({'title':_0x53d5e4('0x15e3'),'msg':_0xef7fd7[_0x53d5e4('0xda0')]['name']?_0xef7fd7['freshdeskAccount'][_0x53d5e4('0x4f0')]+_0x53d5e4('0x7d'):''}),_0x4c871b(_0xf5dda7);})[_0x446f14('0x1a80')](function(_0x333146){const _0x5a7c9b=_0x446f14;if(_0x333146[_0x5a7c9b('0x25f4')]&&_0x333146[_0x5a7c9b('0x25f4')][_0x5a7c9b('0x61a')]&&_0x333146['data'][_0x5a7c9b('0x61a')]['length']){_0xef7fd7[_0x5a7c9b('0x61a')]=_0x333146[_0x5a7c9b('0x25f4')][_0x5a7c9b('0x61a')]||[{'message':_0x333146[_0x5a7c9b('0x1586')](),'type':_0x5a7c9b('0x2e0')}];for(let _0xb3d31a=0x0;_0xb3d31a<_0x333146['data'][_0x5a7c9b('0x61a')][_0x5a7c9b('0x264b')];_0xb3d31a++){_0x56ecbd[_0x5a7c9b('0xfc9')]({'title':_0x333146[_0x5a7c9b('0x25f4')]['errors'][_0xb3d31a]['type'],'msg':_0x333146['data'][_0x5a7c9b('0x61a')][_0xb3d31a][_0x5a7c9b('0x1e70')]});}}else _0x56ecbd['error']({'title':_0x333146['status']?_0x5a7c9b('0x1e21')+_0x333146['status']+_0x5a7c9b('0x11e1')+_0x333146[_0x5a7c9b('0xe1b')]:_0x5a7c9b('0x2e0'),'msg':_0x333146['data']?JSON[_0x5a7c9b('0xbac')](_0x333146[_0x5a7c9b('0x25f4')][_0x5a7c9b('0x1e70')]):_0x333146['toString']()});});}function _0x40e177(_0x4f69b3){const _0x49c9a4=_0x160f75;_0xef7fd7['errors']=[];const _0x4eab22=_0xb42470[_0x49c9a4('0x1d26')]()[_0x49c9a4('0xcdc')](_0x49c9a4('0x7fb'))[_0x49c9a4('0xacc')](_0x49c9a4('0x225e'))[_0x49c9a4('0x8e8')](_0x49c9a4('0x1d2d'))['ok']('Delete')[_0x49c9a4('0x3f')]('Cancel')[_0x49c9a4('0x203b')](_0x4f69b3);_0xb42470[_0x49c9a4('0x1f80')](_0x4eab22)[_0x49c9a4('0x1166')](function(){const _0x3c4577=_0x49c9a4;_0x132caa[_0x3c4577('0xc1e')][_0x3c4577('0x906')]({'id':_0xef7fd7[_0x3c4577('0xda0')]['id']})[_0x3c4577('0xa44')][_0x3c4577('0x1166')](function(){const _0x32e71e=_0x3c4577;_0x2cfb05()[_0x32e71e('0x127f')](_0xef7fd7[_0x32e71e('0x22f9')],{'id':_0xef7fd7[_0x32e71e('0xda0')]['id']}),_0x56ecbd['success']({'title':_0x32e71e('0x23a4'),'msg':(_0xef7fd7['freshdeskAccount'][_0x32e71e('0x4f0')]||_0x32e71e('0xda0'))+_0x32e71e('0x7cd')}),_0x4c871b(_0xef7fd7[_0x32e71e('0xda0')]);})[_0x3c4577('0x1a80')](function(_0x5260af){const _0x4d7bf4=_0x3c4577;if(_0x5260af[_0x4d7bf4('0x25f4')]&&_0x5260af['data'][_0x4d7bf4('0x61a')]&&_0x5260af['data'][_0x4d7bf4('0x61a')][_0x4d7bf4('0x264b')]){_0xef7fd7[_0x4d7bf4('0x61a')]=_0x5260af[_0x4d7bf4('0x25f4')][_0x4d7bf4('0x61a')]||[{'message':_0x5260af[_0x4d7bf4('0x1586')](),'type':_0x4d7bf4('0x2573')}];for(let _0x38b4c5=0x0;_0x38b4c5<_0x5260af[_0x4d7bf4('0x25f4')][_0x4d7bf4('0x61a')][_0x4d7bf4('0x264b')];_0x38b4c5++){_0x56ecbd['error']({'title':_0x5260af[_0x4d7bf4('0x25f4')]['errors'][_0x38b4c5][_0x4d7bf4('0x1345')],'msg':_0x5260af['data'][_0x4d7bf4('0x61a')][_0x38b4c5][_0x4d7bf4('0x1e70')]});}}else _0x56ecbd['error']({'title':_0x5260af[_0x4d7bf4('0x52d')]?_0x4d7bf4('0x1e21')+_0x5260af[_0x4d7bf4('0x52d')]+_0x4d7bf4('0x11e1')+_0x5260af[_0x4d7bf4('0xe1b')]:_0x4d7bf4('0x2573'),'msg':_0x5260af[_0x4d7bf4('0x25f4')]?JSON[_0x4d7bf4('0xbac')](_0x5260af[_0x4d7bf4('0x25f4')][_0x4d7bf4('0x1e70')]):_0x5260af[_0x4d7bf4('0x1e70')]||_0x5260af['toString']()});});},function(){});}function _0xbb133a(_0x31bb0c){return _0x31bb0c===null?undefined:new Date(_0x31bb0c);}function _0x4c871b(_0x141f3a){const _0x1d3a78=_0x160f75;_0xb42470[_0x1d3a78('0x1197')](_0x141f3a);}}const _0x5da993=_0x4578d6,_0xb9da3f=_0x2734b2['p']+_0x36e6f4('0x259d'),_0x5267cc=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/freshdeskAccounts/edit/item/dialog.html/dialog.html';_0x2f4b15['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'api',_0x36e6f4('0x1d2e'),'Auth'];function _0x2f4b15(_0x54c3da,_0x72a6c8,_0x34245d,_0x9ab340,_0x293fdc){const _0x195401=_0x36e6f4,_0x1f9cfb=this;_0x1f9cfb[_0x195401('0x98')]=_0x293fdc['getCurrentUser'](),_0x1f9cfb[_0x195401('0xda0')]={},_0x1f9cfb[_0x195401('0x1420')]={},_0x1f9cfb[_0x195401('0xd54')]=[],_0x1f9cfb[_0x195401('0x70b')]=-0x1,_0x1f9cfb[_0x195401('0x243c')],_0x1f9cfb[_0x195401('0x24d5')]=_0xb9ed50,_0x1f9cfb[_0x195401('0x585')]=_0x37d262,_0x1f9cfb[_0x195401('0x27aa')]=_0x23c415,_0x1f9cfb[_0x195401('0x1b54')]=_0x34c119,_0x1f9cfb[_0x195401('0x1726')]=[],_0x1f9cfb[_0x195401('0xa6a')]=_0x45c614,_0x34245d[_0x195401('0x1446')][_0x195401('0xd83')]({'nolimit':!![],'sort':_0x195401('0x4f0')})[_0x195401('0xa44')][_0x195401('0x1166')](function(_0x27d82a){const _0x29951e=_0x195401;_0x1f9cfb[_0x29951e('0xb38')]=_0x27d82a[_0x29951e('0x269a')]?_0x27d82a[_0x29951e('0x269a')]:[];})[_0x195401('0x1a80')](function(_0x21bd80){const _0x207db0=_0x195401;_0x9ab340[_0x207db0('0xfc9')]({'title':_0x21bd80['status']?_0x207db0('0x1e21')+_0x21bd80['status']+_0x207db0('0x11e1')+_0x21bd80[_0x207db0('0xe1b')]:_0x207db0('0x2597'),'msg':_0x21bd80[_0x207db0('0x25f4')]?JSON[_0x207db0('0xbac')](_0x21bd80[_0x207db0('0x25f4')]):_0x21bd80[_0x207db0('0x1586')]()});});function _0x45c614(){const _0x21be67=_0x195401;_0x34245d[_0x21be67('0x1fb1')][_0x21be67('0x61b')]({'id':_0x1f9cfb['freshdeskConfiguration']['id'],'ids':_0x1f9cfb[_0x21be67('0x1726')]})[_0x21be67('0xa44')][_0x21be67('0x1166')](function(){const _0x597e94=_0x21be67;_0x9ab340[_0x597e94('0x103b')]({'title':'Tags\x20set!','msg':'Tags\x20has\x20been\x20set!'});})['catch'](function(_0x237bcc){const _0x231ddc=_0x21be67;_0x9ab340[_0x231ddc('0xfc9')]({'title':_0x237bcc['status']?_0x231ddc('0x1e21')+_0x237bcc[_0x231ddc('0x52d')]+_0x231ddc('0x11e1')+_0x237bcc[_0x231ddc('0xe1b')]:_0x231ddc('0x8f0'),'msg':_0x237bcc['data']?JSON['stringify'](_0x237bcc[_0x231ddc('0x25f4')]):_0x237bcc[_0x231ddc('0x1586')]()});});}function _0xb9ed50(_0x14f0cd,_0x2a0d4e){const _0x48ee7f=_0x195401;_0x1f9cfb[_0x48ee7f('0xda0')]=_0x14f0cd,_0x1f9cfb[_0x48ee7f('0x243c')]=typeof _0x2a0d4e!==_0x48ee7f('0x1048')?_0x2a0d4e:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x34245d[_0x48ee7f('0xc1e')][_0x48ee7f('0x13db')]({'id':_0x1f9cfb[_0x48ee7f('0xda0')]['id'],'sort':_0x48ee7f('0x14dc')})[_0x48ee7f('0xa44')][_0x48ee7f('0x1166')](function(_0x39ba9e){const _0x2aa35d=_0x48ee7f;return _0x1f9cfb[_0x2aa35d('0xd54')]=_0x39ba9e['rows']?_0x39ba9e[_0x2aa35d('0x269a')]:[],_0x1f9cfb[_0x2aa35d('0xd54')][_0x2aa35d('0x264b')]&&_0x1f9cfb[_0x2aa35d('0x585')](0x0),_0x34245d[_0x2aa35d('0x734')][_0x2aa35d('0xd83')]({'nolimit':!![],'sort':_0x2aa35d('0x4f0')})[_0x2aa35d('0xa44')];})['then'](function(_0x10e62d){const _0x224481=_0x48ee7f;_0x1f9cfb[_0x224481('0x57a')]=_0x10e62d[_0x224481('0x269a')]?_0x10e62d[_0x224481('0x269a')]:[],_0x1f9cfb['variablesById']=_0x2cfb05()[_0x224481('0x155c')](_0x1f9cfb['variables'],'id');})[_0x48ee7f('0x1a80')](function(_0x53d416){const _0x1a036b=_0x48ee7f;_0x9ab340[_0x1a036b('0xfc9')]({'title':_0x53d416[_0x1a036b('0x52d')]?_0x1a036b('0x1e21')+_0x53d416[_0x1a036b('0x52d')]+'\x20-\x20'+_0x53d416[_0x1a036b('0xe1b')]:_0x1a036b('0x17ab'),'msg':_0x53d416[_0x1a036b('0x25f4')]?JSON[_0x1a036b('0xbac')](_0x53d416['data']):_0x53d416[_0x1a036b('0x1586')]()});});}function _0x37d262(_0x49dd8c){const _0x59e887=_0x195401;_0x1f9cfb[_0x59e887('0x1420')]=_0x1f9cfb[_0x59e887('0xd54')][_0x49dd8c],_0x1f9cfb[_0x59e887('0x70b')]=_0x49dd8c,_0x34245d[_0x59e887('0x1fb1')][_0x59e887('0x154d')]({'id':_0x1f9cfb['freshdeskConfiguration']['id']})[_0x59e887('0xa44')][_0x59e887('0x1166')](function(_0x5d19b4){const _0x5c9087=_0x59e887;return _0x1f9cfb['subjects']=_0x5d19b4[_0x5c9087('0x269a')]?_0x5d19b4[_0x5c9087('0x269a')]:[],_0x34245d[_0x5c9087('0x1fb1')][_0x5c9087('0x28d4')]({'id':_0x1f9cfb[_0x5c9087('0x1420')]['id']})[_0x5c9087('0xa44')];})['then'](function(_0x5d5e9f){const _0x4018e7=_0x59e887;return _0x1f9cfb['descriptions']=_0x5d5e9f[_0x4018e7('0x269a')]?_0x5d5e9f['rows']:[],_0x34245d[_0x4018e7('0x1fb1')][_0x4018e7('0x18ea')]({'id':_0x1f9cfb[_0x4018e7('0x1420')]['id']})[_0x4018e7('0xa44')];})[_0x59e887('0x1166')](function(_0x4292e2){const _0x7f2080=_0x59e887;_0x1f9cfb['fields']=_0x4292e2['rows']?_0x4292e2[_0x7f2080('0x269a')]:[];})['catch'](function(_0x51bb0a){const _0x4b246d=_0x59e887;_0x9ab340[_0x4b246d('0xfc9')]({'title':_0x51bb0a[_0x4b246d('0x52d')]?_0x4b246d('0x1e21')+_0x51bb0a[_0x4b246d('0x52d')]+_0x4b246d('0x11e1')+_0x51bb0a[_0x4b246d('0xe1b')]:_0x4b246d('0x16c7'),'msg':_0x51bb0a[_0x4b246d('0x25f4')]?JSON[_0x4b246d('0xbac')](_0x51bb0a[_0x4b246d('0x25f4')]):_0x51bb0a[_0x4b246d('0x1586')]()});}),_0x34245d['intFreshdeskConfiguration']['getTags']({'id':_0x1f9cfb['freshdeskConfiguration']['id']})['$promise'][_0x59e887('0x1166')](function(_0xb181ee){const _0xb71e53=_0x59e887;_0x1f9cfb[_0xb71e53('0x1726')]=_0xb181ee['rows']?_0x2cfb05()['map'](_0xb181ee[_0xb71e53('0x269a')],'id'):[];})[_0x59e887('0x1a80')](function(_0x28ddd9){const _0x3d326f=_0x59e887;_0x9ab340['error']({'title':_0x28ddd9[_0x3d326f('0x52d')]?'API:'+_0x28ddd9[_0x3d326f('0x52d')]+'\x20-\x20'+_0x28ddd9[_0x3d326f('0xe1b')]:_0x3d326f('0x2597'),'msg':_0x28ddd9[_0x3d326f('0x25f4')]?JSON['stringify'](_0x28ddd9['data']):_0x28ddd9['toString']()});});}function _0x23c415(_0x257edb,_0x13c569){const _0x5300a6=_0x195401;_0x54c3da[_0x5300a6('0x1f80')]({'controller':'CreateOrEditFreshdeskConfigurationDialogController','controllerAs':'vm','templateUrl':_0xb9da3f,'parent':angular[_0x5300a6('0x1194')](_0x72a6c8[_0x5300a6('0x8d2')]),'targetEvent':_0x257edb,'clickOutsideToClose':!![],'locals':{'freshdeskConfiguration':_0x13c569,'configurations':_0x1f9cfb[_0x5300a6('0xd54')],'license':null,'setting':null,'crudPermissions':_0x1f9cfb[_0x5300a6('0x243c')]}})['finally'](function(){const _0x4b346e=_0x5300a6;_0x1f9cfb[_0x4b346e('0x585')](0x0);});}function _0x34c119(_0x1e1a75,_0x16885a){const _0x269458=_0x195401,_0x3955ef=_0x54c3da['confirm']()[_0x269458('0xcdc')](_0x269458('0xf2a'))[_0x269458('0xf3c')](_0x269458('0x12b5')+(_0x16885a[_0x269458('0x4f0')]||_0x269458('0x1420'))+_0x269458('0xace')+'\x20will\x20be\x20deleted.')[_0x269458('0x8e8')](_0x269458('0x500'))[_0x269458('0x203b')](_0x1e1a75)['ok']('OK')[_0x269458('0x3f')](_0x269458('0x2d3'));_0x54c3da['show'](_0x3955ef)[_0x269458('0x1166')](function(){const _0xb604a9=_0x269458;_0x34245d[_0xb604a9('0x1fb1')]['delete']({'id':_0x16885a['id']})['$promise']['then'](function(){const _0x2f6b22=_0xb604a9;_0x2cfb05()[_0x2f6b22('0x127f')](_0x1f9cfb[_0x2f6b22('0xd54')],{'id':_0x16885a['id']}),_0x9ab340[_0x2f6b22('0x103b')]({'title':_0x2f6b22('0x16b'),'msg':_0x16885a[_0x2f6b22('0x4f0')]?_0x16885a[_0x2f6b22('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0xb604a9('0x1a80')](function(_0x5d6ae7){const _0x37ed34=_0xb604a9;_0x9ab340[_0x37ed34('0xfc9')]({'title':_0x5d6ae7['status']?'API:'+_0x5d6ae7[_0x37ed34('0x52d')]+_0x37ed34('0x11e1')+_0x5d6ae7[_0x37ed34('0xe1b')]:'SYSTEM:DELETECONFIGURATION','msg':_0x5d6ae7[_0x37ed34('0x25f4')]?JSON['stringify'](_0x5d6ae7[_0x37ed34('0x25f4')]):_0x5d6ae7['toString']()});})[_0xb604a9('0x1951')](function(){const _0x5cfada=_0xb604a9;_0x1f9cfb[_0x5cfada('0x585')](0x0);});},function(){const _0x1b1ece=_0x269458;console[_0x1b1ece('0x455')](_0x1b1ece('0x2d3'));});}_0x1f9cfb[_0x195401('0xd02')]=[],_0x1f9cfb['createOrEditSubject']=_0x16d111,_0x1f9cfb[_0x195401('0x2059')]=_0x1174ed,_0x1f9cfb['deleteSelectedSubjects']=_0x36acaf;function _0x16d111(_0x3dc5d2,_0x97289c){const _0x5d7b9b=_0x195401;_0x54c3da['show']({'controller':_0x5d7b9b('0x10e4'),'controllerAs':'vm','templateUrl':_0x5267cc,'parent':angular[_0x5d7b9b('0x1194')](_0x72a6c8[_0x5d7b9b('0x8d2')]),'targetEvent':_0x3dc5d2,'clickOutsideToClose':!![],'locals':{'type':_0x5d7b9b('0x210d'),'item':_0x97289c,'items':_0x1f9cfb[_0x5d7b9b('0x2701')],'configuration':_0x1f9cfb['freshdeskConfiguration'],'account':_0x1f9cfb[_0x5d7b9b('0xda0')],'license':null,'setting':null,'crudPermissions':_0x1f9cfb['crudPermissions']}});}function _0x2c4da8(_0x4dae46){const _0x1d7578=_0x195401;_0x34245d[_0x1d7578('0x23f4')][_0x1d7578('0x906')]({'id':_0x4dae46['id']})[_0x1d7578('0xa44')][_0x1d7578('0x1166')](function(){const _0x3389ac=_0x1d7578;_0x2cfb05()[_0x3389ac('0x127f')](_0x1f9cfb['subjects'],{'id':_0x4dae46['id']}),_0x9ab340[_0x3389ac('0x103b')]({'title':'Subject\x20deleted!','msg':'Subject\x20has\x20been\x20deleted!'});})[_0x1d7578('0x1a80')](function(_0x173938){const _0x236c56=_0x1d7578;_0x9ab340[_0x236c56('0xfc9')]({'title':_0x173938[_0x236c56('0x52d')]?_0x236c56('0x1e21')+_0x173938['status']+_0x236c56('0x11e1')+_0x173938[_0x236c56('0xe1b')]:_0x236c56('0x23ff'),'msg':_0x173938[_0x236c56('0x25f4')]?JSON['stringify'](_0x173938[_0x236c56('0x25f4')]):_0x173938['toString']()});});}function _0x1174ed(_0x1c5f88,_0x55dda5){const _0x105f33=_0x195401,_0xab18ab=_0x54c3da['confirm']()[_0x105f33('0xcdc')](_0x105f33('0x11c8'))['htmlContent'](_0x105f33('0x277a')+_0x105f33('0x3f3'))[_0x105f33('0x8e8')](_0x105f33('0x87a'))[_0x105f33('0x203b')](_0x1c5f88)['ok']('OK')[_0x105f33('0x3f')](_0x105f33('0x2d3'));_0x54c3da[_0x105f33('0x1f80')](_0xab18ab)[_0x105f33('0x1166')](function(){_0x2c4da8(_0x55dda5);},function(){const _0x5baa0d=_0x105f33;console[_0x5baa0d('0x455')](_0x5baa0d('0x2d3'));});}function _0x36acaf(_0x168a84){const _0x4f8176=_0x195401,_0x53124c=_0x54c3da[_0x4f8176('0x1d26')]()[_0x4f8176('0xcdc')](_0x4f8176('0x1d64'))[_0x4f8176('0xf3c')](_0x4f8176('0x12b5')+_0x1f9cfb[_0x4f8176('0xd02')][_0x4f8176('0x264b')]+_0x4f8176('0x196d')+_0x4f8176('0x3f3'))[_0x4f8176('0x8e8')](_0x4f8176('0x5b2'))[_0x4f8176('0x203b')](_0x168a84)['ok']('OK')[_0x4f8176('0x3f')](_0x4f8176('0x2d3'));_0x54c3da[_0x4f8176('0x1f80')](_0x53124c)[_0x4f8176('0x1166')](function(){const _0xa2c0d4=_0x4f8176;_0x1f9cfb[_0xa2c0d4('0xd02')][_0xa2c0d4('0x2782')](function(_0x4e0cf1){_0x2c4da8(_0x4e0cf1);}),_0x1f9cfb[_0xa2c0d4('0xd02')]=[];});}_0x1f9cfb[_0x195401('0x968')]=[],_0x1f9cfb[_0x195401('0x2185')]=_0x4a38c9,_0x1f9cfb[_0x195401('0xdf3')]=_0x3ab821,_0x1f9cfb[_0x195401('0x2269')]=_0x263781;function _0x4a38c9(_0x4c6e93,_0x478680){const _0x5b7316=_0x195401;_0x54c3da['show']({'controller':_0x5b7316('0x10e4'),'controllerAs':'vm','templateUrl':_0x5267cc,'parent':angular[_0x5b7316('0x1194')](_0x72a6c8[_0x5b7316('0x8d2')]),'targetEvent':_0x4c6e93,'clickOutsideToClose':!![],'locals':{'type':_0x5b7316('0x101c'),'item':_0x478680,'items':_0x1f9cfb[_0x5b7316('0x1b3d')],'configuration':_0x1f9cfb[_0x5b7316('0x1420')],'account':_0x1f9cfb[_0x5b7316('0xda0')],'license':null,'setting':null,'crudPermissions':_0x1f9cfb[_0x5b7316('0x243c')]}});}function _0xb2676c(_0x1364e1){const _0x8923a1=_0x195401;_0x34245d[_0x8923a1('0x23f4')][_0x8923a1('0x906')]({'id':_0x1364e1['id']})[_0x8923a1('0xa44')][_0x8923a1('0x1166')](function(){const _0x143c49=_0x8923a1;_0x2cfb05()[_0x143c49('0x127f')](_0x1f9cfb[_0x143c49('0x1b3d')],{'id':_0x1364e1['id']}),_0x9ab340[_0x143c49('0x103b')]({'title':_0x143c49('0x9c1'),'msg':_0x143c49('0x12ae')});})[_0x8923a1('0x1a80')](function(_0x4eb431){const _0x595231=_0x8923a1;_0x9ab340[_0x595231('0xfc9')]({'title':_0x4eb431[_0x595231('0x52d')]?_0x595231('0x1e21')+_0x4eb431[_0x595231('0x52d')]+'\x20-\x20'+_0x4eb431[_0x595231('0xe1b')]:_0x595231('0x23ff'),'msg':_0x4eb431[_0x595231('0x25f4')]?JSON[_0x595231('0xbac')](_0x4eb431[_0x595231('0x25f4')]):_0x4eb431[_0x595231('0x1586')]()});});}function _0x3ab821(_0x447ce9,_0x58bb13){const _0x1255ad=_0x195401,_0x5a4453=_0x54c3da[_0x1255ad('0x1d26')]()[_0x1255ad('0xcdc')](_0x1255ad('0x1baa'))[_0x1255ad('0xf3c')](_0x1255ad('0x1809')+'\x20will\x20be\x20deleted.')[_0x1255ad('0x8e8')](_0x1255ad('0x1bc0'))[_0x1255ad('0x203b')](_0x447ce9)['ok']('OK')[_0x1255ad('0x3f')](_0x1255ad('0x2d3'));_0x54c3da['show'](_0x5a4453)[_0x1255ad('0x1166')](function(){_0xb2676c(_0x58bb13);},function(){const _0x15541a=_0x1255ad;console[_0x15541a('0x455')]('CANCEL');});}function _0x263781(_0x2c2dd6){const _0xd97432=_0x195401,_0x37352b=_0x54c3da[_0xd97432('0x1d26')]()['title'](_0xd97432('0x29'))[_0xd97432('0xf3c')](_0xd97432('0x12b5')+_0x1f9cfb[_0xd97432('0x968')]['length']+_0xd97432('0x196d')+'\x20will\x20be\x20deleted.')[_0xd97432('0x8e8')](_0xd97432('0x17a'))[_0xd97432('0x203b')](_0x2c2dd6)['ok']('OK')['cancel'](_0xd97432('0x2d3'));_0x54c3da[_0xd97432('0x1f80')](_0x37352b)[_0xd97432('0x1166')](function(){const _0x2bc4e8=_0xd97432;_0x1f9cfb[_0x2bc4e8('0x968')][_0x2bc4e8('0x2782')](function(_0x1fa083){_0xb2676c(_0x1fa083);}),_0x1f9cfb[_0x2bc4e8('0x968')]=[];});}_0x1f9cfb[_0x195401('0x16')]=[],_0x1f9cfb[_0x195401('0x27ad')]=_0x3d2f91,_0x1f9cfb[_0x195401('0xbda')]=_0x33f756,_0x1f9cfb[_0x195401('0x1ace')]=_0x4ff037;function _0x3d2f91(_0x3ca1b8,_0x4c5186){const _0x5e3cd9=_0x195401;_0x54c3da['show']({'controller':'CreateOrEditFreshdeskAccountItemDialogController','controllerAs':'vm','templateUrl':_0x5267cc,'parent':angular[_0x5e3cd9('0x1194')](_0x72a6c8[_0x5e3cd9('0x8d2')]),'targetEvent':_0x3ca1b8,'clickOutsideToClose':!![],'locals':{'type':_0x5e3cd9('0x22f3'),'item':_0x4c5186,'items':_0x1f9cfb[_0x5e3cd9('0xfe2')],'configuration':_0x1f9cfb['freshdeskConfiguration'],'account':_0x1f9cfb['freshdeskAccount'],'license':null,'setting':null,'crudPermissions':_0x1f9cfb[_0x5e3cd9('0x243c')]}});}function _0x466d4d(_0x53350){const _0x345364=_0x195401;_0x34245d[_0x345364('0x23f4')][_0x345364('0x906')]({'id':_0x53350['id']})[_0x345364('0xa44')][_0x345364('0x1166')](function(){const _0x2ae08e=_0x345364;_0x2cfb05()[_0x2ae08e('0x127f')](_0x1f9cfb[_0x2ae08e('0xfe2')],{'id':_0x53350['id']}),_0x9ab340['success']({'title':_0x2ae08e('0x13cb'),'msg':'Field\x20has\x20been\x20deleted!'});})[_0x345364('0x1a80')](function(_0x329d4a){const _0x449598=_0x345364;_0x9ab340['error']({'title':_0x329d4a[_0x449598('0x52d')]?_0x449598('0x1e21')+_0x329d4a[_0x449598('0x52d')]+_0x449598('0x11e1')+_0x329d4a[_0x449598('0xe1b')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x329d4a[_0x449598('0x25f4')]?JSON[_0x449598('0xbac')](_0x329d4a[_0x449598('0x25f4')]):_0x329d4a[_0x449598('0x1586')]()});});}function _0x33f756(_0x50aa51,_0xb52097){const _0x4bee02=_0x195401,_0x5362a9=_0x54c3da[_0x4bee02('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x4bee02('0xf3c')]('Field'+_0x4bee02('0x3f3'))[_0x4bee02('0x8e8')](_0x4bee02('0x2127'))[_0x4bee02('0x203b')](_0x50aa51)['ok']('OK')[_0x4bee02('0x3f')](_0x4bee02('0x2d3'));_0x54c3da[_0x4bee02('0x1f80')](_0x5362a9)[_0x4bee02('0x1166')](function(){_0x466d4d(_0xb52097);},function(){const _0x244f9f=_0x4bee02;console['log'](_0x244f9f('0x2d3'));});}function _0x4ff037(_0x535074){const _0xc59ef8=_0x195401,_0xca7111=_0x54c3da['confirm']()['title'](_0xc59ef8('0x1d42'))['htmlContent'](_0xc59ef8('0x12b5')+_0x1f9cfb[_0xc59ef8('0x16')][_0xc59ef8('0x264b')]+_0xc59ef8('0x196d')+_0xc59ef8('0x3f3'))[_0xc59ef8('0x8e8')](_0xc59ef8('0x219a'))[_0xc59ef8('0x203b')](_0x535074)['ok']('OK')['cancel'](_0xc59ef8('0x2d3'));_0x54c3da[_0xc59ef8('0x1f80')](_0xca7111)['then'](function(){const _0xd8ad64=_0xc59ef8;_0x1f9cfb[_0xd8ad64('0x16')][_0xd8ad64('0x2782')](function(_0x177492){_0x466d4d(_0x177492);}),_0x1f9cfb['selectedFields']=[];});}}const _0x400992=_0x2f4b15;_0x3fa1e1[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0xd54'),_0x36e6f4('0x1420'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x3fa1e1(_0xe73b0e,_0x20d492,_0x2aebad,_0x1533b6,_0x1acc17,_0x5d161d,_0x204de5,_0x464215,_0x1f06c1,_0x47e95e,_0x493437,_0xe2b3bc,_0x46231c,_0x2d9c48){const _0x6776f0=_0x36e6f4,_0x5c77ea=this;_0x5c77ea['currentUser']=_0x493437[_0x6776f0('0x26cd')](),_0x5c77ea[_0x6776f0('0x61a')]=[],_0x5c77ea[_0x6776f0('0xf8a')]=_0x46231c,_0x5c77ea['license']=_0xe2b3bc,_0x5c77ea[_0x6776f0('0x243c')]=_0x2d9c48,_0x5c77ea[_0x6776f0('0x128b')]={},_0x5c77ea[_0x6776f0('0x2900')]=_0x5c77ea[_0x6776f0('0xf8a')]&&_0x5c77ea['setting'][_0x6776f0('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5c77ea[_0x6776f0('0xcdc')]=_0x6776f0('0x99b'),_0x5c77ea[_0x6776f0('0x1420')]=angular[_0x6776f0('0x225f')](_0x1f06c1),_0x5c77ea['configurations']=_0x464215,_0x5c77ea[_0x6776f0('0x9c9')]=![];!_0x5c77ea[_0x6776f0('0x1420')]&&(_0x5c77ea['freshdeskConfiguration']={'channel':_0x6776f0('0x21da'),'type':_0x6776f0('0x14d8')},_0x5c77ea[_0x6776f0('0xcdc')]=_0x6776f0('0xc13'),_0x5c77ea[_0x6776f0('0x9c9')]=!![]);_0x5c77ea['addNewFreshdeskConfiguration']=_0x5b61f1,_0x5c77ea[_0x6776f0('0x1f70')]=_0x37c3b0,_0x5c77ea['deleteFreshdeskConfiguration']=_0x1bec45,_0x5c77ea['getDateFromString']=_0x3d2b2f,_0x5c77ea[_0x6776f0('0x24a0')]=_0x2da93b;function _0x5b61f1(){const _0xbba996=_0x6776f0;_0x5c77ea[_0xbba996('0x61a')]=[],_0x47e95e[_0xbba996('0xc1e')][_0xbba996('0x274a')]({'id':_0x20d492[_0xbba996('0x23f')]['id']},_0x5c77ea[_0xbba996('0x1420')])[_0xbba996('0xa44')][_0xbba996('0x1166')](function(_0x427078){const _0x102f18=_0xbba996;_0x5c77ea[_0x102f18('0xd54')][_0x102f18('0x2450')](_0x427078[_0x102f18('0x2876')]()),_0x204de5[_0x102f18('0x103b')]({'title':_0x102f18('0x132a'),'msg':_0x5c77ea['freshdeskConfiguration']['name']?_0x5c77ea[_0x102f18('0x1420')]['name']+_0x102f18('0x1eda'):''}),_0x2da93b(_0x427078);})[_0xbba996('0x1a80')](function(_0x577c66){const _0x1bc384=_0xbba996;if(_0x577c66[_0x1bc384('0x25f4')]&&_0x577c66[_0x1bc384('0x25f4')][_0x1bc384('0x61a')]&&_0x577c66[_0x1bc384('0x25f4')][_0x1bc384('0x61a')]['length']){_0x5c77ea['errors']=_0x577c66[_0x1bc384('0x25f4')][_0x1bc384('0x61a')]||[{'message':_0x577c66['toString'](),'type':'api.intFreshdeskConfiguration.save'}];for(let _0x733518=0x0;_0x733518<_0x577c66[_0x1bc384('0x25f4')][_0x1bc384('0x61a')][_0x1bc384('0x264b')];_0x733518+=0x1){_0x204de5[_0x1bc384('0xfc9')]({'title':_0x577c66[_0x1bc384('0x25f4')][_0x1bc384('0x61a')][_0x733518][_0x1bc384('0x1345')],'msg':_0x577c66[_0x1bc384('0x25f4')][_0x1bc384('0x61a')][_0x733518][_0x1bc384('0x1e70')]});}}else _0x204de5['error']({'title':_0x577c66[_0x1bc384('0x52d')]?_0x1bc384('0x1e21')+_0x577c66[_0x1bc384('0x52d')]+_0x1bc384('0x11e1')+_0x577c66[_0x1bc384('0xe1b')]:'api.intFreshdeskConfiguration.save','msg':_0x577c66['data']?JSON[_0x1bc384('0xbac')](_0x577c66[_0x1bc384('0x25f4')][_0x1bc384('0x1e70')]):_0x577c66[_0x1bc384('0x1586')]()});});}function _0x37c3b0(){const _0x3237a7=_0x6776f0;_0x5c77ea['errors']=[],_0x47e95e[_0x3237a7('0x1fb1')][_0x3237a7('0x1449')]({'id':_0x5c77ea[_0x3237a7('0x1420')]['id']},_0x5c77ea[_0x3237a7('0x1420')])['$promise'][_0x3237a7('0x1166')](function(_0x4eb904){const _0x1d6f91=_0x3237a7,_0x3f2f01=_0x2cfb05()[_0x1d6f91('0xc38')](_0x5c77ea['configurations'],{'id':_0x4eb904['id']});_0x3f2f01&&_0x2cfb05()['merge'](_0x3f2f01,_0x2cfb05()[_0x1d6f91('0x1a08')](_0x4eb904[_0x1d6f91('0x2876')](),_0x2cfb05()['keys'](_0x3f2f01))),_0x204de5[_0x1d6f91('0x103b')]({'title':_0x1d6f91('0x2698'),'msg':_0x5c77ea['freshdeskConfiguration'][_0x1d6f91('0x4f0')]?_0x5c77ea[_0x1d6f91('0x1420')][_0x1d6f91('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x2da93b(_0x4eb904);})[_0x3237a7('0x1a80')](function(_0x28e873){const _0x428177=_0x3237a7;if(_0x28e873[_0x428177('0x25f4')]&&_0x28e873[_0x428177('0x25f4')]['errors']&&_0x28e873[_0x428177('0x25f4')]['errors'][_0x428177('0x264b')]){_0x5c77ea[_0x428177('0x61a')]=_0x28e873[_0x428177('0x25f4')]['errors']||[{'message':_0x28e873[_0x428177('0x1586')](),'type':_0x428177('0x20fb')}];for(let _0x4770fb=0x0;_0x4770fb<_0x28e873[_0x428177('0x25f4')][_0x428177('0x61a')][_0x428177('0x264b')];_0x4770fb++){_0x204de5['error']({'title':_0x28e873['data'][_0x428177('0x61a')][_0x4770fb]['type'],'msg':_0x28e873[_0x428177('0x25f4')][_0x428177('0x61a')][_0x4770fb]['message']});}}else _0x204de5[_0x428177('0xfc9')]({'title':_0x28e873['status']?_0x428177('0x1e21')+_0x28e873[_0x428177('0x52d')]+_0x428177('0x11e1')+_0x28e873[_0x428177('0xe1b')]:_0x428177('0x20fb'),'msg':_0x28e873[_0x428177('0x25f4')]?JSON[_0x428177('0xbac')](_0x28e873['data'][_0x428177('0x1e70')]):_0x28e873[_0x428177('0x1586')]()});});}function _0x1bec45(_0x1a5245){const _0x4bd538=_0x6776f0;_0x5c77ea['errors']=[];const _0x322f1f=_0x1533b6[_0x4bd538('0x1d26')]()[_0x4bd538('0xcdc')]('Are\x20you\x20sure?')['content'](_0x4bd538('0x66c'))[_0x4bd538('0x8e8')](_0x4bd538('0x1db'))['ok']('Delete')[_0x4bd538('0x3f')](_0x4bd538('0x497'))[_0x4bd538('0x203b')](_0x1a5245);_0x1533b6['show'](_0x322f1f)['then'](function(){const _0xf658a7=_0x4bd538;_0x47e95e[_0xf658a7('0x1fb1')][_0xf658a7('0x906')]({'id':_0x5c77ea[_0xf658a7('0x1420')]['id']})['$promise'][_0xf658a7('0x1166')](function(){const _0x2eaf3b=_0xf658a7;_0x2cfb05()[_0x2eaf3b('0x127f')](_0x5c77ea[_0x2eaf3b('0xd54')],{'id':_0x5c77ea['freshdeskConfiguration']['id']}),_0x204de5['success']({'title':_0x2eaf3b('0x13a0'),'msg':(_0x5c77ea[_0x2eaf3b('0x1420')]['name']||'freshdeskConfiguration')+'\x20has\x20been\x20deleted!'}),_0x2da93b(_0x5c77ea[_0x2eaf3b('0x1420')]);})[_0xf658a7('0x1a80')](function(_0x3cce74){const _0x106e88=_0xf658a7;if(_0x3cce74[_0x106e88('0x25f4')]&&_0x3cce74[_0x106e88('0x25f4')][_0x106e88('0x61a')]&&_0x3cce74[_0x106e88('0x25f4')][_0x106e88('0x61a')][_0x106e88('0x264b')]){_0x5c77ea[_0x106e88('0x61a')]=_0x3cce74[_0x106e88('0x25f4')]['errors']||[{'message':_0x3cce74[_0x106e88('0x1586')](),'type':_0x106e88('0x22d9')}];for(let _0x5cd365=0x0;_0x5cd365<_0x3cce74[_0x106e88('0x25f4')][_0x106e88('0x61a')]['length'];_0x5cd365++){_0x204de5[_0x106e88('0xfc9')]({'title':_0x3cce74['data'][_0x106e88('0x61a')][_0x5cd365][_0x106e88('0x1345')],'msg':_0x3cce74['data'][_0x106e88('0x61a')][_0x5cd365][_0x106e88('0x1e70')]});}}else _0x204de5[_0x106e88('0xfc9')]({'title':_0x3cce74[_0x106e88('0x52d')]?_0x106e88('0x1e21')+_0x3cce74[_0x106e88('0x52d')]+'\x20-\x20'+_0x3cce74[_0x106e88('0xe1b')]:_0x106e88('0x22d9'),'msg':_0x3cce74[_0x106e88('0x25f4')]?JSON['stringify'](_0x3cce74[_0x106e88('0x25f4')][_0x106e88('0x1e70')]):_0x3cce74[_0x106e88('0x1e70')]||_0x3cce74[_0x106e88('0x1586')]()});});},function(){});}function _0x3d2b2f(_0x18c329){return _0x18c329===null?undefined:new Date(_0x18c329);}function _0x2da93b(_0x25abfd){const _0x1e5cc9=_0x6776f0;_0x1533b6[_0x1e5cc9('0x1197')](_0x25abfd);}}const _0x45d522=_0x3fa1e1;_0x18338c[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xd29'),_0x36e6f4('0xbd7'),_0x36e6f4('0x1301'),_0x36e6f4('0x1a32'),'type',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x18338c(_0x12f91b,_0x4afa08,_0x36aa3d,_0x15c83a,_0x43c150,_0x13db49,_0x5c9419,_0x10238f,_0x5f0572,_0x580170,_0x5270e5,_0x361b6e,_0xa51081){const _0x4f184a=_0x36e6f4,_0x5a0e2c=this;_0x5a0e2c['currentUser']=_0x361b6e[_0x4f184a('0x26cd')](),_0x5a0e2c[_0x4f184a('0x61a')]=[],_0x5a0e2c[_0x4f184a('0xcdc')]=_0x4f184a('0x2012')+_0x2cfb05()['toUpper'](_0x580170),_0x5a0e2c[_0x4f184a('0x1301')]=angular[_0x4f184a('0x225f')](_0x10238f),_0x5a0e2c[_0x4f184a('0xbd7')]=_0x5c9419,_0x5a0e2c['type']=_0x580170,_0x5a0e2c[_0x4f184a('0x243c')]=_0xa51081,_0x5a0e2c[_0x4f184a('0x17c7')]=![];!_0x5a0e2c[_0x4f184a('0x1301')]&&(_0x5a0e2c[_0x4f184a('0x1301')]={'type':_0x4f184a('0x102c')},_0x5a0e2c['item'][_0x2cfb05()[_0x4f184a('0x92c')](_0x580170)+'Id']=_0x13db49['id'],_0x5a0e2c[_0x4f184a('0xcdc')]='INTEGRATIONS.NEW_'+_0x2cfb05()['toUpper'](_0x580170),_0x5a0e2c[_0x4f184a('0x17c7')]=!![]);_0x5a0e2c[_0x4f184a('0x1e8a')]=_0x4d7f94,_0x5a0e2c['saveItem']=_0x5a2eeb,_0x5a0e2c['deleteItem']=_0x405ebc,_0x5a0e2c[_0x4f184a('0x1551')]=_0xbc854c,_0x5a0e2c[_0x4f184a('0x24a0')]=_0x4c2619,_0x5270e5['variable']['get']({'nolimit':!![]})['$promise'][_0x4f184a('0x1166')](function(_0x4c8e9f){const _0x2ea89b=_0x4f184a;return _0x5a0e2c['variables']=_0x4c8e9f[_0x2ea89b('0x269a')]?_0x4c8e9f['rows']:[],_0x5270e5[_0x2ea89b('0x7af')][_0x2ea89b('0x23d0')]()[_0x2ea89b('0xa44')];})[_0x4f184a('0x1166')](function(_0x913684){const _0x3e7dd9=_0x4f184a;return _0x5a0e2c[_0x3e7dd9('0x1d45')]=_0x2cfb05()[_0x3e7dd9('0x13ca')](_0x2cfb05()[_0x3e7dd9('0x14a4')](_0x913684),[_0x3e7dd9('0xa44'),_0x3e7dd9('0xfcd'),_0x3e7dd9('0x262'),'updatedAt',_0x3e7dd9('0x978')]),_0x5a0e2c[_0x3e7dd9('0x1d45')][_0x3e7dd9('0x1514')](_0x3e7dd9('0xa29')),_0x5270e5[_0x3e7dd9('0x21f9')]['describe']()[_0x3e7dd9('0xa44')];})[_0x4f184a('0x1166')](function(_0x2adc3b){const _0x2b7cf3=_0x4f184a;_0x5a0e2c['voiceDialReportColumns']=_0x2cfb05()[_0x2b7cf3('0x13ca')](_0x2cfb05()[_0x2b7cf3('0x14a4')](_0x2adc3b),['$promise','$resolved',_0x2b7cf3('0x262'),_0x2b7cf3('0x6f9'),_0x2b7cf3('0x978')]),_0x5a0e2c[_0x2b7cf3('0x1348')][_0x2b7cf3('0x1514')](_0x2b7cf3('0xa29'));})[_0x4f184a('0x1a80')](function(_0xd25a5e){const _0x2cb68c=_0x4f184a;_0x43c150[_0x2cb68c('0xfc9')]({'title':_0xd25a5e[_0x2cb68c('0x52d')]?_0x2cb68c('0x1e21')+_0xd25a5e[_0x2cb68c('0x52d')]+'\x20-\x20'+_0xd25a5e[_0x2cb68c('0xe1b')]:_0x2cb68c('0xfe5'),'msg':_0xd25a5e[_0x2cb68c('0x25f4')]?JSON['stringify'](_0xd25a5e[_0x2cb68c('0x25f4')]):_0xd25a5e[_0x2cb68c('0x1586')]()});}),_0x5270e5[_0x4f184a('0xc1e')]['getFields']({'id':_0x5f0572['id'],'ticketType':_0x13db49[_0x4f184a('0x11ba')]?_0x13db49[_0x4f184a('0x11ba')]:undefined})[_0x4f184a('0xa44')][_0x4f184a('0x1166')](function(_0x212856){const _0x3cc75d=_0x4f184a;_0x5a0e2c[_0x3cc75d('0x606')]=!![],_0x5a0e2c[_0x3cc75d('0xfe2')]=_0x212856[_0x3cc75d('0x269a')]?_0x212856[_0x3cc75d('0x269a')]:[],_0x5a0e2c[_0x3cc75d('0x1301')][_0x3cc75d('0x1143')]&&(_0x5a0e2c[_0x3cc75d('0x117e')]=_0x2cfb05()[_0x3cc75d('0xc38')](_0x5a0e2c['fields'],{'id':_0x5a0e2c[_0x3cc75d('0x1301')][_0x3cc75d('0x1143')]}));})['catch'](function(_0x3e91bc){const _0x2338df=_0x4f184a;_0x5a0e2c[_0x2338df('0x606')]=![],console[_0x2338df('0xfc9')](_0x3e91bc);});function _0x4d7f94(){const _0xd2cd9=_0x4f184a;_0x5a0e2c[_0xd2cd9('0x61a')]=[],_0x5a0e2c[_0xd2cd9('0x117e')]&&(_0x5a0e2c[_0xd2cd9('0x1301')][_0xd2cd9('0x1143')]=_0x5a0e2c['customField']['id'],_0x5a0e2c[_0xd2cd9('0x1301')][_0xd2cd9('0x3c0')]=_0x5a0e2c['customField']['name'],_0x5a0e2c[_0xd2cd9('0x1301')]['customField']=_0x5a0e2c['customField']['custom']),_0x5270e5[_0xd2cd9('0x23f4')]['save'](_0x5a0e2c['item'])['$promise']['then'](function(_0x3f6e22){const _0x36b83e=_0xd2cd9;_0x5a0e2c[_0x36b83e('0xbd7')]['unshift'](_0x3f6e22),_0x43c150[_0x36b83e('0x103b')]({'title':_0x2cfb05()[_0x36b83e('0x92c')](_0x580170)+_0x36b83e('0x13f0'),'msg':_0x2cfb05()[_0x36b83e('0x92c')](_0x580170)+_0x36b83e('0x1eda')}),_0x4c2619();})[_0xd2cd9('0x1a80')](function(_0x3a02a7){const _0xaf240e=_0xd2cd9;console['error'](_0x3a02a7),_0x5a0e2c[_0xaf240e('0x61a')]=_0x3a02a7[_0xaf240e('0x25f4')][_0xaf240e('0x61a')]||[{'message':_0x3a02a7['toString'](),'type':_0xaf240e('0x215d')}];});}function _0x5a2eeb(){const _0x354fbc=_0x4f184a;_0x5a0e2c[_0x354fbc('0x61a')]=[],_0x5a0e2c[_0x354fbc('0x117e')]&&(_0x5a0e2c[_0x354fbc('0x1301')]['idField']=_0x5a0e2c[_0x354fbc('0x117e')]['id'],_0x5a0e2c[_0x354fbc('0x1301')]['nameField']=_0x5a0e2c[_0x354fbc('0x117e')]['name'],_0x5a0e2c[_0x354fbc('0x1301')]['customField']=_0x5a0e2c[_0x354fbc('0x117e')][_0x354fbc('0x2853')]),_0x5270e5[_0x354fbc('0x23f4')][_0x354fbc('0x1449')]({'id':_0x5a0e2c[_0x354fbc('0x1301')]['id']},_0x5a0e2c['item'])[_0x354fbc('0xa44')][_0x354fbc('0x1166')](function(_0x39ad89){const _0x2d5c0a=_0x354fbc,_0x517f98=_0x2cfb05()[_0x2d5c0a('0xc38')](_0x5a0e2c[_0x2d5c0a('0xbd7')],{'id':_0x39ad89['id']});_0x517f98&&_0x2cfb05()[_0x2d5c0a('0xcc3')](_0x517f98,_0x39ad89),_0x43c150[_0x2d5c0a('0x103b')]({'title':_0x2cfb05()[_0x2d5c0a('0x92c')](_0x580170)+'\x20properly\x20saved!','msg':_0x2cfb05()[_0x2d5c0a('0x92c')](_0x580170)+_0x2d5c0a('0x7d')}),_0x4c2619();})[_0x354fbc('0x1a80')](function(_0x1ba51d){const _0x961cce=_0x354fbc;console[_0x961cce('0xfc9')](_0x1ba51d),_0x5a0e2c[_0x961cce('0x61a')]=_0x1ba51d[_0x961cce('0x25f4')][_0x961cce('0x61a')]||[{'message':_0x1ba51d['toString'](),'type':_0x961cce('0x10cd')}];});}function _0x405ebc(_0x14ed95){const _0x1f99f1=_0x4f184a;_0x5a0e2c[_0x1f99f1('0x61a')]=[];const _0x2a5249=_0x15c83a[_0x1f99f1('0x1d26')]()[_0x1f99f1('0xcdc')](_0x1f99f1('0x7fb'))[_0x1f99f1('0xacc')](_0x1f99f1('0x135f')+_0x580170+_0x1f99f1('0x3f3'))[_0x1f99f1('0x8e8')]('Delete\x20'+_0x2cfb05()[_0x1f99f1('0x92c')](_0x580170))['ok'](_0x1f99f1('0x18'))[_0x1f99f1('0x3f')](_0x1f99f1('0x497'))['targetEvent'](_0x14ed95);_0x15c83a[_0x1f99f1('0x1f80')](_0x2a5249)['then'](function(){const _0x84287c=_0x1f99f1;_0x5270e5[_0x84287c('0x23f4')]['delete']({'id':_0x5a0e2c[_0x84287c('0x1301')]['id']})[_0x84287c('0xa44')][_0x84287c('0x1166')](function(){const _0x5a3880=_0x84287c;_0x2cfb05()[_0x5a3880('0x127f')](_0x5a0e2c[_0x5a3880('0xbd7')],{'id':_0x5a0e2c[_0x5a3880('0x1301')]['id']}),_0x43c150['success']({'title':_0x2cfb05()['capitalize'](_0x580170)+_0x5a3880('0x450'),'msg':_0x2cfb05()['capitalize'](_0x580170)+_0x5a3880('0x7cd')}),_0x4c2619();})['catch'](function(_0x307cc6){const _0x3a5ab2=_0x84287c;console[_0x3a5ab2('0xfc9')](_0x307cc6),_0x5a0e2c[_0x3a5ab2('0x61a')]=_0x307cc6['data'][_0x3a5ab2('0x61a')]||[{'message':_0x307cc6[_0x3a5ab2('0x1586')](),'type':_0x3a5ab2('0x2602')}];});},function(){});}function _0xbc854c(){const _0x3e13fd=_0x4f184a;return _0x5a0e2c[_0x3e13fd('0x1301')]['variableName']!==undefined?_0x5a0e2c[_0x3e13fd('0x1301')][_0x3e13fd('0xbdb')]:'Please\x20select\x20a\x20variable';}function _0x4c2619(){_0x15c83a['hide']();}}const _0x388d47=_0x18338c;_0x5eca0f['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0xda0'),_0x36e6f4('0x17aa')];function _0x5eca0f(_0x3f156d,_0x436d6f,_0x231c38,_0x22817f,_0x54c427,_0x3ec257,_0x2372b4,_0x100a0d,_0x14739c,_0xb68281,_0xf827d6,_0x36fc93){const _0x1e383d=_0x36e6f4,_0x3e5afc=this;_0x3e5afc[_0x1e383d('0x98')]=_0xb68281[_0x1e383d('0x26cd')](),_0x3e5afc[_0x1e383d('0x5c9')]=_0x3ec257,_0x3e5afc[_0x1e383d('0xf8a')]=_0x2372b4,_0x3e5afc['passwordPattern']=_0x3e5afc[_0x1e383d('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3e5afc['location']=_0x436d6f['protocol']()+_0x1e383d('0xc51')+_0x436d6f['host'](),_0x3e5afc[_0x1e383d('0xda0')]=_0xf827d6||_0x3f156d[_0x1e383d('0x23f')]['freshdeskAccount']||{},_0x3e5afc['userProfileSection']=_0x36fc93&&_0x36fc93[_0x1e383d('0x240f')]==0x1?_0x36fc93[_0x1e383d('0x269a')][0x0]:null,_0x3e5afc[_0x1e383d('0x243c')]=_0xb68281[_0x1e383d('0xd87')](_0x3e5afc[_0x1e383d('0x17aa')]?_0x3e5afc[_0x1e383d('0x17aa')][_0x1e383d('0x243c')]:null),_0x3e5afc[_0x1e383d('0x128b')]={},_0x3e5afc[_0x1e383d('0x2669')]=_0x3f156d[_0x1e383d('0x23f')][_0x1e383d('0xbe3')]||0x0,_0x3e5afc['alert']=_0x14739c[_0x1e383d('0x1fa1')],_0x3e5afc[_0x1e383d('0x1dde')]=_0x1d9835,_0x3e5afc[_0x1e383d('0xb9e')]=_0x51073a;function _0x1d9835(){const _0x55d295=_0x1e383d;_0x3f156d['go'](_0x55d295('0x28c7'),{},{'reload':_0x55d295('0x28c7')});}function _0x51073a(){const _0x327377=_0x1e383d;_0x100a0d[_0x327377('0xc1e')][_0x327377('0x1449')]({'id':_0x3e5afc[_0x327377('0xda0')]['id']},_0x3e5afc[_0x327377('0xda0')])[_0x327377('0xa44')]['then'](function(){const _0x5a0654=_0x327377;_0x14739c[_0x5a0654('0x103b')]({'title':_0x5a0654('0x24b'),'msg':_0x3e5afc[_0x5a0654('0xda0')][_0x5a0654('0x4f0')]?_0x3e5afc[_0x5a0654('0xda0')][_0x5a0654('0x4f0')]+_0x5a0654('0xa17'):''});})[_0x327377('0x1a80')](function(_0x231bed){const _0x12ff45=_0x327377;_0x14739c[_0x12ff45('0xfc9')]({'title':_0x231bed[_0x12ff45('0x52d')]?_0x12ff45('0x1e21')+_0x231bed[_0x12ff45('0x52d')]+'\x20-\x20'+_0x231bed[_0x12ff45('0xe1b')]:_0x12ff45('0xc3b'),'msg':_0x231bed['data']?JSON[_0x12ff45('0xbac')](_0x231bed[_0x12ff45('0x25f4')]):_0x231bed['toString']()});});}}const _0x166d08=_0x5eca0f,_0x32335c=_0x2734b2['p']+_0x36e6f4('0x2020');_0x4bcd7c[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x22f9'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting'];function _0x4bcd7c(_0x3872b9,_0x38188f,_0x3a6e49,_0x4d4be0,_0x1c344e,_0x1fddec,_0x189bbe,_0x17e922,_0x444092,_0x2b602d,_0x415701,_0x6001c3,_0x3fea2c,_0x278e67,_0x4437c6,_0x543a7c,_0x17dc10){const _0x4d6f8d=_0x36e6f4,_0x1a17b1=this;_0x1a17b1['license']=_0x543a7c,_0x1a17b1[_0x4d6f8d('0xf8a')]=_0x17dc10,_0x1a17b1[_0x4d6f8d('0x98')]=_0x4437c6[_0x4d6f8d('0x26cd')](),_0x1a17b1['freshdeskAccounts']=_0x444092||{'count':0x0,'rows':[]},_0x1a17b1[_0x4d6f8d('0x7f')]=_0x2b602d,_0x1a17b1[_0x4d6f8d('0x17aa')]=_0x415701&&_0x415701[_0x4d6f8d('0x240f')]==0x1?_0x415701['rows'][0x0]:null,_0x1a17b1['crudPermissions']=_0x4437c6[_0x4d6f8d('0xd87')](_0x1a17b1[_0x4d6f8d('0x17aa')]?_0x1a17b1[_0x4d6f8d('0x17aa')]['crudPermissions']:null),_0x1a17b1[_0x4d6f8d('0x916')]=_0x4d6f8d('0x22f9'),_0x1a17b1['listOrder']='',_0x1a17b1[_0x4d6f8d('0x104c')]=null,_0x1a17b1[_0x4d6f8d('0x1613')]=[],_0x1a17b1[_0x4d6f8d('0x2218')]={'fields':_0x4d6f8d('0x7d6'),'limit':0xa,'page':0x1},_0x1a17b1[_0x4d6f8d('0x1ff6')]=_0x137f1c,_0x1a17b1[_0x4d6f8d('0x2113')]=_0x33e965,_0x1a17b1['deleteconfirm']=_0x2e4b9b,_0x1a17b1[_0x4d6f8d('0x103b')]=_0x2a4431,_0x1a17b1[_0x4d6f8d('0x12e9')]=_0x175715,_0x1a17b1[_0x4d6f8d('0x1324')]=_0x1dec3a,_0x1a17b1['deleteFreshdeskAccount']=_0x31ca8b,_0x1a17b1['exportSelectedFreshdeskAccounts']=_0x49f465,_0x1a17b1['deleteSelectedFreshdeskAccounts']=_0x3ca536,_0x1a17b1[_0x4d6f8d('0x1b8f')]=_0x3a8eaf,_0x1a17b1[_0x4d6f8d('0x26d0')]=_0x5e7636;function _0x137f1c(_0x2797ed){const _0x2ce2e4=_0x4d6f8d;_0x3a6e49['go'](_0x2ce2e4('0x21e5'),{'id':_0x2797ed['id'],'freshdeskAccount':_0x2797ed,'crudPermissions':_0x1a17b1['crudPermissions']});}function _0x33e965(_0x546a5c){const _0x21b47c=_0x4d6f8d;return _0x6001c3['intFreshdeskAccount']['getFields']({'id':_0x546a5c['id'],'test':!![]})['$promise'][_0x21b47c('0x1166')](function(){const _0x24fa76=_0x21b47c;_0x278e67[_0x24fa76('0x103b')]({'title':'FreshdeskAccount\x20properly\x20tested','msg':_0x24fa76('0x1fef')});})[_0x21b47c('0x1a80')](function(_0x78a46){const _0x2175e6=_0x21b47c;_0x278e67[_0x2175e6('0xfc9')]({'title':_0x2175e6('0x84c'),'msg':_0x78a46['data']?_0x78a46[_0x2175e6('0x25f4')][_0x2175e6('0x1e70')]?_0x78a46['data'][_0x2175e6('0x1e70')]:JSON[_0x2175e6('0xbac')](_0x78a46[_0x2175e6('0x25f4')]):_0x78a46[_0x2175e6('0x1586')]()});});}function _0x2e4b9b(_0x402bae,_0x1a2884){const _0x44e3f2=_0x4d6f8d,_0x6687be=_0x1c344e['confirm']()[_0x44e3f2('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x44e3f2('0xb35')](_0x44e3f2('0xda0'))+'?')['htmlContent'](_0x44e3f2('0x12b5')+(_0x402bae['name']||_0x44e3f2('0xda0'))+_0x44e3f2('0xace')+_0x44e3f2('0x3f3'))[_0x44e3f2('0x8e8')](_0x44e3f2('0xa1'))['targetEvent'](_0x1a2884)['ok']('OK')[_0x44e3f2('0x3f')](_0x44e3f2('0x2d3'));_0x1c344e[_0x44e3f2('0x1f80')](_0x6687be)[_0x44e3f2('0x1166')](function(){_0x31ca8b(_0x402bae);},function(){const _0x1a5b77=_0x44e3f2;console[_0x1a5b77('0x455')](_0x1a5b77('0x2d3'));});}let _0x2d1855=!![],_0x2019dc=0x1;_0x3872b9[_0x4d6f8d('0xe83')](_0x4d6f8d('0x12d8'),function(_0x482766,_0x52bd95){const _0x2eb496=_0x4d6f8d;_0x2d1855?_0x189bbe(function(){_0x2d1855=![];}):(!_0x52bd95&&(_0x2019dc=_0x1a17b1['query']['page']),_0x482766!==_0x52bd95&&(_0x1a17b1[_0x2eb496('0x2218')][_0x2eb496('0x1a43')]=0x1),!_0x482766&&(_0x1a17b1['query'][_0x2eb496('0x1a43')]=_0x2019dc),_0x1a17b1[_0x2eb496('0x12e9')]());});function _0x2a4431(_0x4117a1){_0x1a17b1['freshdeskAccounts']=_0x4117a1||{'count':0x0,'rows':[]};}function _0x175715(){const _0x1fdab7=_0x4d6f8d;_0x1a17b1[_0x1fdab7('0x2218')][_0x1fdab7('0x1098')]=(_0x1a17b1[_0x1fdab7('0x2218')]['page']-0x1)*_0x1a17b1[_0x1fdab7('0x2218')]['limit'],_0x4437c6[_0x1fdab7('0x1ac6')](_0x1fdab7('0xa7c'))?_0x1a17b1['promise']=_0x6001c3[_0x1fdab7('0xc1e')][_0x1fdab7('0xd83')](_0x1a17b1[_0x1fdab7('0x2218')],_0x2a4431)[_0x1fdab7('0xa44')]:(_0x1a17b1['query']['id']=_0x1a17b1['userProfile']['id'],_0x1a17b1[_0x1fdab7('0x2218')]['section']=_0x1fdab7('0x1c35'),_0x1a17b1[_0x1fdab7('0x1f48')]=_0x6001c3[_0x1fdab7('0x7f')]['getResources'](_0x1a17b1['query'],_0x2a4431)[_0x1fdab7('0xa44')]);}function _0x1dec3a(_0x36827e,_0x11188a){const _0x28376b=_0x4d6f8d;_0x1c344e['show']({'controller':_0x28376b('0x1cf9'),'controllerAs':'vm','templateUrl':_0x32335c,'parent':angular[_0x28376b('0x1194')](_0x1fddec[_0x28376b('0x8d2')]),'targetEvent':_0x36827e,'clickOutsideToClose':!![],'locals':{'freshdeskAccount':_0x11188a,'freshdeskAccounts':_0x1a17b1[_0x28376b('0x22f9')][_0x28376b('0x269a')],'license':_0x1a17b1[_0x28376b('0x5c9')],'setting':_0x1a17b1[_0x28376b('0xf8a')],'crudPermissions':_0x1a17b1[_0x28376b('0x243c')]}});}function _0x31ca8b(_0x527a81){const _0x506ab8=_0x4d6f8d;_0x6001c3[_0x506ab8('0xc1e')][_0x506ab8('0x906')]({'id':_0x527a81['id']})['$promise'][_0x506ab8('0x1166')](function(){const _0x3b74ce=_0x506ab8;_0x2cfb05()[_0x3b74ce('0x127f')](_0x1a17b1[_0x3b74ce('0x22f9')][_0x3b74ce('0x269a')],{'id':_0x527a81['id']}),_0x1a17b1['freshdeskAccounts'][_0x3b74ce('0x240f')]-=0x1,!_0x1a17b1[_0x3b74ce('0x22f9')][_0x3b74ce('0x269a')][_0x3b74ce('0x264b')]&&_0x1a17b1[_0x3b74ce('0x12e9')](),_0x278e67[_0x3b74ce('0x103b')]({'title':_0x2cfb05()[_0x3b74ce('0xb35')](_0x3b74ce('0x28ac'))+'\x20deleted!','msg':_0x527a81[_0x3b74ce('0x4f0')]?_0x527a81[_0x3b74ce('0x4f0')]+_0x3b74ce('0x7cd'):''});})[_0x506ab8('0x1a80')](function(_0x1e9293){const _0x3cb01d=_0x506ab8;if(_0x1e9293['data']&&_0x1e9293[_0x3cb01d('0x25f4')][_0x3cb01d('0x61a')]&&_0x1e9293['data'][_0x3cb01d('0x61a')]['length']){_0x1a17b1[_0x3cb01d('0x61a')]=_0x1e9293[_0x3cb01d('0x25f4')][_0x3cb01d('0x61a')]||[{'message':_0x1e9293[_0x3cb01d('0x1586')](),'type':_0x3cb01d('0x1958')}];for(let _0x1116de=0x0;_0x1116de<_0x1e9293[_0x3cb01d('0x25f4')]['errors'][_0x3cb01d('0x264b')];_0x1116de++){_0x278e67[_0x3cb01d('0xfc9')]({'title':_0x1e9293['data']['errors'][_0x1116de][_0x3cb01d('0x1345')],'msg':_0x1e9293['data'][_0x3cb01d('0x61a')][_0x1116de][_0x3cb01d('0x1e70')]});}}else _0x278e67[_0x3cb01d('0xfc9')]({'title':_0x1e9293[_0x3cb01d('0x52d')]?_0x3cb01d('0x1e21')+_0x1e9293[_0x3cb01d('0x52d')]+_0x3cb01d('0x11e1')+_0x1e9293[_0x3cb01d('0xe1b')]:_0x3cb01d('0x1958'),'msg':_0x1e9293[_0x3cb01d('0x25f4')]?JSON[_0x3cb01d('0xbac')](_0x1e9293[_0x3cb01d('0x25f4')]['message']):_0x1e9293['message']||_0x1e9293[_0x3cb01d('0x1586')]()});});}function _0x49f465(){const _0x296bce=_0x4d6f8d,_0x4995c3=angular['copy'](_0x1a17b1[_0x296bce('0x1613')]);return _0x1a17b1['selectedFreshdeskAccounts']=[],_0x4995c3;}function _0x3ca536(_0x380551){const _0x53ba8f=_0x4d6f8d,_0x9aae8b=_0x1c344e[_0x53ba8f('0x1d26')]()[_0x53ba8f('0xcdc')](_0x53ba8f('0x18a'))[_0x53ba8f('0xf3c')](_0x53ba8f('0x12b5')+_0x1a17b1[_0x53ba8f('0x1613')][_0x53ba8f('0x264b')]+_0x53ba8f('0x196d')+_0x53ba8f('0x3f3'))[_0x53ba8f('0x8e8')](_0x53ba8f('0x28eb'))['targetEvent'](_0x380551)['ok']('OK')[_0x53ba8f('0x3f')]('CANCEL');_0x1c344e[_0x53ba8f('0x1f80')](_0x9aae8b)[_0x53ba8f('0x1166')](function(){const _0x58e98d=_0x53ba8f;_0x1a17b1['selectedFreshdeskAccounts'][_0x58e98d('0x2782')](function(_0x4346e7){_0x31ca8b(_0x4346e7);}),_0x1a17b1['selectedFreshdeskAccounts']=[];});}function _0x3a8eaf(){_0x1a17b1['selectedFreshdeskAccounts']=[];}function _0x5e7636(){const _0x2a5733=_0x4d6f8d;_0x1a17b1[_0x2a5733('0x1613')]=_0x1a17b1[_0x2a5733('0x22f9')][_0x2a5733('0x269a')];}}const _0xa0e81c=_0x4bcd7c;_0x27fa68[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0x163e'),_0x36e6f4('0x1e8b'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),'crudPermissions'];function _0x27fa68(_0x1deabc,_0x48fe6b,_0x4f97ac,_0x5cfc34,_0x1b8685,_0x3c850f,_0x5a45bd,_0x13f4a4,_0x25e2e4,_0x2226fa,_0xc2c60f,_0xca1752,_0x588e61,_0x138233){const _0x246a9e=_0x36e6f4,_0x456de0=this;_0x456de0[_0x246a9e('0x98')]=_0xc2c60f[_0x246a9e('0x26cd')](),_0x456de0[_0x246a9e('0x61a')]=[],_0x456de0['setting']=_0x588e61,_0x456de0[_0x246a9e('0x5c9')]=_0xca1752,_0x456de0[_0x246a9e('0x243c')]=_0x138233,_0x456de0[_0x246a9e('0x128b')]={},_0x456de0[_0x246a9e('0x2900')]=_0x456de0[_0x246a9e('0xf8a')]&&_0x456de0[_0x246a9e('0xf8a')][_0x246a9e('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x456de0[_0x246a9e('0xcdc')]=_0x246a9e('0x2cc'),_0x456de0['freshsalesAccount']=angular[_0x246a9e('0x225f')](_0x25e2e4),_0x456de0[_0x246a9e('0x163e')]=_0x13f4a4,_0x456de0[_0x246a9e('0x600')]=![];!_0x456de0['freshsalesAccount']&&(_0x456de0[_0x246a9e('0x1e8b')]={'serverUrl':_0x4f97ac[_0x246a9e('0x6f1')]()+'://'+_0x4f97ac[_0x246a9e('0x1690')]()+(_0x4f97ac[_0x246a9e('0x93d')]()?':'+_0x4f97ac[_0x246a9e('0x93d')]():'')},_0x456de0[_0x246a9e('0xcdc')]=_0x246a9e('0x1541'),_0x456de0[_0x246a9e('0x600')]=!![]);_0x456de0[_0x246a9e('0x69b')]=_0x262de5,_0x456de0[_0x246a9e('0x196e')]=_0x113af4,_0x456de0['deleteFreshsalesAccount']=_0x4a8a81,_0x456de0['getDateFromString']=_0x263701,_0x456de0[_0x246a9e('0x24a0')]=_0xc48065;function _0x262de5(){const _0x350006=_0x246a9e;_0x456de0['errors']=[],_0x2226fa[_0x350006('0x11cd')][_0x350006('0x9cc')](_0x456de0['freshsalesAccount'])[_0x350006('0xa44')][_0x350006('0x1166')](function(_0x595e50){const _0x4fb6d1=_0x350006;_0x456de0[_0x4fb6d1('0x163e')]['unshift'](_0x595e50[_0x4fb6d1('0x2876')]()),_0x5a45bd[_0x4fb6d1('0x103b')]({'title':'FreshsalesAccount\x20properly\x20created','msg':_0x456de0[_0x4fb6d1('0x1e8b')][_0x4fb6d1('0x4f0')]?_0x456de0['freshsalesAccount']['name']+'\x20has\x20been\x20created!':''}),_0xc48065(_0x595e50);})[_0x350006('0x1a80')](function(_0x4a9ada){const _0x2aefea=_0x350006;if(_0x4a9ada[_0x2aefea('0x25f4')]&&_0x4a9ada[_0x2aefea('0x25f4')]['errors']&&_0x4a9ada['data'][_0x2aefea('0x61a')][_0x2aefea('0x264b')]){_0x456de0[_0x2aefea('0x61a')]=_0x4a9ada[_0x2aefea('0x25f4')][_0x2aefea('0x61a')]||[{'message':_0x4a9ada[_0x2aefea('0x1586')](),'type':_0x2aefea('0x52')}];for(let _0x3d7bd2=0x0;_0x3d7bd2<_0x4a9ada[_0x2aefea('0x25f4')][_0x2aefea('0x61a')][_0x2aefea('0x264b')];_0x3d7bd2+=0x1){_0x5a45bd[_0x2aefea('0xfc9')]({'title':_0x4a9ada[_0x2aefea('0x25f4')][_0x2aefea('0x61a')][_0x3d7bd2][_0x2aefea('0x1345')],'msg':_0x4a9ada[_0x2aefea('0x25f4')][_0x2aefea('0x61a')][_0x3d7bd2][_0x2aefea('0x1e70')]});}}else _0x5a45bd[_0x2aefea('0xfc9')]({'title':_0x4a9ada[_0x2aefea('0x52d')]?_0x2aefea('0x1e21')+_0x4a9ada[_0x2aefea('0x52d')]+_0x2aefea('0x11e1')+_0x4a9ada[_0x2aefea('0xe1b')]:_0x2aefea('0x52'),'msg':_0x4a9ada['data']?JSON[_0x2aefea('0xbac')](_0x4a9ada[_0x2aefea('0x25f4')]['message']):_0x4a9ada[_0x2aefea('0x1586')]()});});}function _0x113af4(){const _0x4c90af=_0x246a9e;_0x456de0[_0x4c90af('0x61a')]=[],_0x2226fa[_0x4c90af('0x11cd')][_0x4c90af('0x1449')]({'id':_0x456de0[_0x4c90af('0x1e8b')]['id']},_0x456de0['freshsalesAccount'])['$promise'][_0x4c90af('0x1166')](function(_0x404ef9){const _0x3c893b=_0x4c90af,_0x2e4730=_0x2cfb05()['find'](_0x456de0[_0x3c893b('0x163e')],{'id':_0x404ef9['id']});_0x2e4730&&_0x2cfb05()['merge'](_0x2e4730,_0x2cfb05()[_0x3c893b('0x1a08')](_0x404ef9[_0x3c893b('0x2876')](),_0x2cfb05()[_0x3c893b('0x14a4')](_0x2e4730))),_0x5a45bd[_0x3c893b('0x103b')]({'title':_0x3c893b('0x904'),'msg':_0x456de0[_0x3c893b('0x1e8b')][_0x3c893b('0x4f0')]?_0x456de0[_0x3c893b('0x1e8b')]['name']+_0x3c893b('0x7d'):''}),_0xc48065(_0x404ef9);})[_0x4c90af('0x1a80')](function(_0x4fb7ee){const _0x4902d2=_0x4c90af;if(_0x4fb7ee[_0x4902d2('0x25f4')]&&_0x4fb7ee[_0x4902d2('0x25f4')][_0x4902d2('0x61a')]&&_0x4fb7ee['data'][_0x4902d2('0x61a')]['length']){_0x456de0[_0x4902d2('0x61a')]=_0x4fb7ee['data'][_0x4902d2('0x61a')]||[{'message':_0x4fb7ee['toString'](),'type':_0x4902d2('0xed2')}];for(let _0x3fdf25=0x0;_0x3fdf25<_0x4fb7ee['data'][_0x4902d2('0x61a')][_0x4902d2('0x264b')];_0x3fdf25++){_0x5a45bd[_0x4902d2('0xfc9')]({'title':_0x4fb7ee[_0x4902d2('0x25f4')][_0x4902d2('0x61a')][_0x3fdf25][_0x4902d2('0x1345')],'msg':_0x4fb7ee['data'][_0x4902d2('0x61a')][_0x3fdf25]['message']});}}else _0x5a45bd[_0x4902d2('0xfc9')]({'title':_0x4fb7ee[_0x4902d2('0x52d')]?_0x4902d2('0x1e21')+_0x4fb7ee['status']+_0x4902d2('0x11e1')+_0x4fb7ee[_0x4902d2('0xe1b')]:_0x4902d2('0xed2'),'msg':_0x4fb7ee[_0x4902d2('0x25f4')]?JSON[_0x4902d2('0xbac')](_0x4fb7ee[_0x4902d2('0x25f4')][_0x4902d2('0x1e70')]):_0x4fb7ee[_0x4902d2('0x1586')]()});});}function _0x4a8a81(_0x41fa31){const _0x1749df=_0x246a9e;_0x456de0['errors']=[];const _0x1ad9ed=_0x5cfc34[_0x1749df('0x1d26')]()[_0x1749df('0xcdc')](_0x1749df('0x7fb'))[_0x1749df('0xacc')](_0x1749df('0x25b0'))['ariaLabel'](_0x1749df('0x118a'))['ok'](_0x1749df('0x18'))['cancel'](_0x1749df('0x497'))[_0x1749df('0x203b')](_0x41fa31);_0x5cfc34['show'](_0x1ad9ed)[_0x1749df('0x1166')](function(){const _0x1f89b5=_0x1749df;_0x2226fa[_0x1f89b5('0x11cd')]['delete']({'id':_0x456de0[_0x1f89b5('0x1e8b')]['id']})[_0x1f89b5('0xa44')][_0x1f89b5('0x1166')](function(){const _0x50c89e=_0x1f89b5;_0x2cfb05()[_0x50c89e('0x127f')](_0x456de0[_0x50c89e('0x163e')],{'id':_0x456de0[_0x50c89e('0x1e8b')]['id']}),_0x5a45bd['success']({'title':_0x50c89e('0x10a0'),'msg':(_0x456de0[_0x50c89e('0x1e8b')][_0x50c89e('0x4f0')]||'freshsalesAccount')+'\x20has\x20been\x20deleted!'}),_0xc48065(_0x456de0[_0x50c89e('0x1e8b')]);})[_0x1f89b5('0x1a80')](function(_0x56edad){const _0x3952fe=_0x1f89b5;if(_0x56edad['data']&&_0x56edad['data'][_0x3952fe('0x61a')]&&_0x56edad[_0x3952fe('0x25f4')][_0x3952fe('0x61a')]['length']){_0x456de0[_0x3952fe('0x61a')]=_0x56edad[_0x3952fe('0x25f4')][_0x3952fe('0x61a')]||[{'message':_0x56edad['toString'](),'type':_0x3952fe('0x1536')}];for(let _0x23aa23=0x0;_0x23aa23<_0x56edad[_0x3952fe('0x25f4')][_0x3952fe('0x61a')]['length'];_0x23aa23++){_0x5a45bd['error']({'title':_0x56edad['data'][_0x3952fe('0x61a')][_0x23aa23][_0x3952fe('0x1345')],'msg':_0x56edad[_0x3952fe('0x25f4')][_0x3952fe('0x61a')][_0x23aa23][_0x3952fe('0x1e70')]});}}else _0x5a45bd['error']({'title':_0x56edad[_0x3952fe('0x52d')]?_0x3952fe('0x1e21')+_0x56edad[_0x3952fe('0x52d')]+_0x3952fe('0x11e1')+_0x56edad[_0x3952fe('0xe1b')]:_0x3952fe('0x1536'),'msg':_0x56edad['data']?JSON[_0x3952fe('0xbac')](_0x56edad['data']['message']):_0x56edad[_0x3952fe('0x1e70')]||_0x56edad[_0x3952fe('0x1586')]()});});},function(){});}function _0x263701(_0x5e3cbf){return _0x5e3cbf===null?undefined:new Date(_0x5e3cbf);}function _0xc48065(_0x19ba4b){const _0x104369=_0x246a9e;_0x5cfc34[_0x104369('0x1197')](_0x19ba4b);}}const _0x46784a=_0x27fa68,_0x3426e9=_0x2734b2['p']+_0x36e6f4('0xb7e'),_0x151f27=_0x2734b2['p']+_0x36e6f4('0x146b');_0x3ae1e0['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x3ae1e0(_0x7f826,_0x2e47d4,_0x43a00f,_0x30122a,_0x146e6d){const _0x326a47=_0x36e6f4,_0x491a7a=this;_0x491a7a[_0x326a47('0x98')]=_0x146e6d['getCurrentUser'](),_0x491a7a[_0x326a47('0x1e8b')]={},_0x491a7a['freshsalesConfiguration']={},_0x491a7a[_0x326a47('0xd54')]=[],_0x491a7a[_0x326a47('0x17ad')]=-0x1,_0x491a7a[_0x326a47('0x243c')],_0x491a7a[_0x326a47('0x24d5')]=_0x20c20b,_0x491a7a[_0x326a47('0x151d')]=_0x5a2757,_0x491a7a['createOrEditFreshsalesConfiguration']=_0x19080a,_0x491a7a['deleteFreshsalesConfiguration']=_0x1a8e2c;function _0x20c20b(_0x1f9ec5,_0x41d1da){const _0x15551e=_0x326a47;_0x491a7a[_0x15551e('0x1e8b')]=_0x1f9ec5,_0x491a7a[_0x15551e('0x243c')]=typeof _0x41d1da!==_0x15551e('0x1048')?_0x41d1da:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x43a00f['intFreshsalesAccount']['getConfigurations']({'id':_0x491a7a['freshsalesAccount']['id'],'sort':'-updatedAt'})[_0x15551e('0xa44')]['then'](function(_0x4c01c1){const _0x36bf83=_0x15551e;return _0x491a7a['configurations']=_0x4c01c1[_0x36bf83('0x269a')]?_0x4c01c1['rows']:[],_0x491a7a['configurations'][_0x36bf83('0x264b')]&&_0x491a7a['getFreshsalesConfiguration'](0x0),_0x43a00f[_0x36bf83('0x734')][_0x36bf83('0xd83')]({'nolimit':!![],'sort':_0x36bf83('0x4f0')})['$promise'];})[_0x15551e('0x1166')](function(_0x4ec896){const _0x3aed7d=_0x15551e;_0x491a7a['variables']=_0x4ec896[_0x3aed7d('0x269a')]?_0x4ec896['rows']:[],_0x491a7a[_0x3aed7d('0x217a')]=_0x2cfb05()[_0x3aed7d('0x155c')](_0x491a7a[_0x3aed7d('0x57a')],'id');})[_0x15551e('0x1a80')](function(_0x3b01ba){const _0xb8aae9=_0x15551e;_0x30122a[_0xb8aae9('0xfc9')]({'title':_0x3b01ba[_0xb8aae9('0x52d')]?_0xb8aae9('0x1e21')+_0x3b01ba[_0xb8aae9('0x52d')]+_0xb8aae9('0x11e1')+_0x3b01ba['statusText']:_0xb8aae9('0x17ab'),'msg':_0x3b01ba[_0xb8aae9('0x25f4')]?JSON[_0xb8aae9('0xbac')](_0x3b01ba[_0xb8aae9('0x25f4')]):_0x3b01ba['toString']()});});}function _0x5a2757(_0x1da52e){const _0x186985=_0x326a47;_0x491a7a['freshsalesConfiguration']=_0x491a7a[_0x186985('0xd54')][_0x1da52e],_0x491a7a['selectedFreshsalesConfiguration']=_0x1da52e,_0x43a00f[_0x186985('0x2647')][_0x186985('0x154d')]({'id':_0x491a7a['freshsalesConfiguration']['id']})[_0x186985('0xa44')]['then'](function(_0x34884f){const _0xc91068=_0x186985;return _0x491a7a['subjects']=_0x34884f['rows']?_0x34884f[_0xc91068('0x269a')]:[],_0x43a00f[_0xc91068('0x2647')][_0xc91068('0x28d4')]({'id':_0x491a7a[_0xc91068('0x2468')]['id']})[_0xc91068('0xa44')];})['then'](function(_0x1e5c1c){const _0x277a94=_0x186985;return _0x491a7a[_0x277a94('0x1b3d')]=_0x1e5c1c[_0x277a94('0x269a')]?_0x1e5c1c['rows']:[],_0x43a00f['intFreshsalesConfiguration'][_0x277a94('0x18ea')]({'id':_0x491a7a['freshsalesConfiguration']['id']})[_0x277a94('0xa44')];})['then'](function(_0x4677fd){const _0x33edd5=_0x186985;_0x491a7a[_0x33edd5('0xfe2')]=_0x4677fd['rows']?_0x4677fd[_0x33edd5('0x269a')]:[];})[_0x186985('0x1a80')](function(_0x4694a1){const _0x53c887=_0x186985;_0x30122a[_0x53c887('0xfc9')]({'title':_0x4694a1[_0x53c887('0x52d')]?_0x53c887('0x1e21')+_0x4694a1['status']+'\x20-\x20'+_0x4694a1[_0x53c887('0xe1b')]:_0x53c887('0x16c7'),'msg':_0x4694a1['data']?JSON['stringify'](_0x4694a1[_0x53c887('0x25f4')]):_0x4694a1[_0x53c887('0x1586')]()});});}function _0x19080a(_0x9fe963,_0x4db4e9){const _0x3bedb9=_0x326a47;_0x7f826[_0x3bedb9('0x1f80')]({'controller':_0x3bedb9('0x1cdf'),'controllerAs':'vm','templateUrl':_0x3426e9,'parent':angular['element'](_0x2e47d4[_0x3bedb9('0x8d2')]),'targetEvent':_0x9fe963,'clickOutsideToClose':!![],'locals':{'freshsalesConfiguration':_0x4db4e9,'configurations':_0x491a7a[_0x3bedb9('0xd54')],'license':null,'setting':null,'crudPermissions':_0x491a7a[_0x3bedb9('0x243c')]}})['finally'](function(){const _0x4b1caf=_0x3bedb9;_0x491a7a[_0x4b1caf('0x151d')](0x0);});}function _0x1a8e2c(_0x47ebba,_0x50c178){const _0x328319=_0x326a47,_0x5b0985=_0x7f826[_0x328319('0x1d26')]()[_0x328319('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20freshsalesConfiguration?')[_0x328319('0xf3c')](''+(_0x50c178[_0x328319('0x4f0')]||'freshsalesConfiguration')+_0x328319('0xace')+_0x328319('0x3f3'))[_0x328319('0x8e8')](_0x328319('0x22dd'))['targetEvent'](_0x47ebba)['ok']('OK')['cancel'](_0x328319('0x2d3'));_0x7f826['show'](_0x5b0985)['then'](function(){const _0x25561d=_0x328319;_0x43a00f['intFreshsalesConfiguration'][_0x25561d('0x906')]({'id':_0x50c178['id']})[_0x25561d('0xa44')][_0x25561d('0x1166')](function(){const _0x50cc6d=_0x25561d;_0x2cfb05()['remove'](_0x491a7a['configurations'],{'id':_0x50c178['id']}),_0x30122a[_0x50cc6d('0x103b')]({'title':_0x50cc6d('0x5ce'),'msg':_0x50c178[_0x50cc6d('0x4f0')]?_0x50c178[_0x50cc6d('0x4f0')]+_0x50cc6d('0x7cd'):''});})['catch'](function(_0x33160c){const _0x57c8f9=_0x25561d;_0x30122a['error']({'title':_0x33160c[_0x57c8f9('0x52d')]?_0x57c8f9('0x1e21')+_0x33160c[_0x57c8f9('0x52d')]+_0x57c8f9('0x11e1')+_0x33160c[_0x57c8f9('0xe1b')]:'SYSTEM:DELETECONFIGURATION','msg':_0x33160c[_0x57c8f9('0x25f4')]?JSON[_0x57c8f9('0xbac')](_0x33160c['data']):_0x33160c[_0x57c8f9('0x1586')]()});})[_0x25561d('0x1951')](function(){_0x491a7a['getFreshsalesConfiguration'](0x0);});},function(){const _0x59e9ef=_0x328319;console[_0x59e9ef('0x455')](_0x59e9ef('0x2d3'));});}_0x491a7a['selectedSubjects']=[],_0x491a7a['createOrEditSubject']=_0x3a1ed3,_0x491a7a['deleteSubjectConfirm']=_0x2b29d0,_0x491a7a[_0x326a47('0xeff')]=_0x5178b7;function _0x3a1ed3(_0x2e06d1,_0x595485){const _0x4c9442=_0x326a47;_0x7f826[_0x4c9442('0x1f80')]({'controller':_0x4c9442('0x14b7'),'controllerAs':'vm','templateUrl':_0x151f27,'parent':angular['element'](_0x2e47d4[_0x4c9442('0x8d2')]),'targetEvent':_0x2e06d1,'clickOutsideToClose':!![],'locals':{'type':_0x4c9442('0x210d'),'item':_0x595485,'items':_0x491a7a[_0x4c9442('0x2701')],'configuration':_0x491a7a[_0x4c9442('0x2468')],'account':_0x491a7a[_0x4c9442('0x1e8b')],'license':null,'setting':null,'crudPermissions':_0x491a7a[_0x4c9442('0x243c')]}});}function _0x1830c6(_0x9ab632){const _0x525231=_0x326a47;_0x43a00f[_0x525231('0x78b')][_0x525231('0x906')]({'id':_0x9ab632['id']})['$promise'][_0x525231('0x1166')](function(){const _0x31e3b6=_0x525231;_0x2cfb05()['remove'](_0x491a7a[_0x31e3b6('0x2701')],{'id':_0x9ab632['id']}),_0x30122a[_0x31e3b6('0x103b')]({'title':_0x31e3b6('0x6f'),'msg':_0x31e3b6('0x259f')});})['catch'](function(_0xf2698e){const _0x5e1670=_0x525231;_0x30122a[_0x5e1670('0xfc9')]({'title':_0xf2698e['status']?_0x5e1670('0x1e21')+_0xf2698e[_0x5e1670('0x52d')]+_0x5e1670('0x11e1')+_0xf2698e['statusText']:_0x5e1670('0x23ff'),'msg':_0xf2698e[_0x5e1670('0x25f4')]?JSON[_0x5e1670('0xbac')](_0xf2698e['data']):_0xf2698e[_0x5e1670('0x1586')]()});});}function _0x2b29d0(_0x3f558b,_0x4a6d44){const _0x4e1a36=_0x326a47,_0x859ee5=_0x7f826[_0x4e1a36('0x1d26')]()['title'](_0x4e1a36('0x11c8'))[_0x4e1a36('0xf3c')](_0x4e1a36('0x277a')+'\x20will\x20be\x20deleted.')[_0x4e1a36('0x8e8')](_0x4e1a36('0x87a'))['targetEvent'](_0x3f558b)['ok']('OK')[_0x4e1a36('0x3f')](_0x4e1a36('0x2d3'));_0x7f826[_0x4e1a36('0x1f80')](_0x859ee5)[_0x4e1a36('0x1166')](function(){_0x1830c6(_0x4a6d44);},function(){const _0x241ecb=_0x4e1a36;console[_0x241ecb('0x455')](_0x241ecb('0x2d3'));});}function _0x5178b7(_0x3e3f4b){const _0x3dcfeb=_0x326a47,_0x244780=_0x7f826[_0x3dcfeb('0x1d26')]()[_0x3dcfeb('0xcdc')](_0x3dcfeb('0x1d64'))['htmlContent'](_0x3dcfeb('0x12b5')+_0x491a7a[_0x3dcfeb('0xd02')][_0x3dcfeb('0x264b')]+_0x3dcfeb('0x196d')+'\x20will\x20be\x20deleted.')[_0x3dcfeb('0x8e8')](_0x3dcfeb('0x5b2'))[_0x3dcfeb('0x203b')](_0x3e3f4b)['ok']('OK')['cancel']('CANCEL');_0x7f826[_0x3dcfeb('0x1f80')](_0x244780)[_0x3dcfeb('0x1166')](function(){const _0x4c7c3b=_0x3dcfeb;_0x491a7a['selectedSubjects']['forEach'](function(_0x2b9265){_0x1830c6(_0x2b9265);}),_0x491a7a[_0x4c7c3b('0xd02')]=[];});}_0x491a7a[_0x326a47('0x968')]=[],_0x491a7a[_0x326a47('0x2185')]=_0xa6e8f4,_0x491a7a[_0x326a47('0xdf3')]=_0x1a8de7,_0x491a7a[_0x326a47('0x2269')]=_0x2393e4;function _0xa6e8f4(_0x1bfc3b,_0x4c1714){const _0x241190=_0x326a47;_0x7f826['show']({'controller':'CreateOrEditFreshsalesAccountItemDialogController','controllerAs':'vm','templateUrl':_0x151f27,'parent':angular[_0x241190('0x1194')](_0x2e47d4[_0x241190('0x8d2')]),'targetEvent':_0x1bfc3b,'clickOutsideToClose':!![],'locals':{'type':_0x241190('0x101c'),'item':_0x4c1714,'items':_0x491a7a[_0x241190('0x1b3d')],'configuration':_0x491a7a[_0x241190('0x2468')],'account':_0x491a7a[_0x241190('0x1e8b')],'license':null,'setting':null,'crudPermissions':_0x491a7a[_0x241190('0x243c')]}});}function _0x155541(_0x204e8a){const _0x1ce6ad=_0x326a47;_0x43a00f[_0x1ce6ad('0x78b')][_0x1ce6ad('0x906')]({'id':_0x204e8a['id']})[_0x1ce6ad('0xa44')][_0x1ce6ad('0x1166')](function(){const _0x2fb579=_0x1ce6ad;_0x2cfb05()[_0x2fb579('0x127f')](_0x491a7a[_0x2fb579('0x1b3d')],{'id':_0x204e8a['id']}),_0x30122a[_0x2fb579('0x103b')]({'title':_0x2fb579('0x9c1'),'msg':_0x2fb579('0x12ae')});})[_0x1ce6ad('0x1a80')](function(_0x56fc3c){const _0x2431e7=_0x1ce6ad;_0x30122a[_0x2431e7('0xfc9')]({'title':_0x56fc3c[_0x2431e7('0x52d')]?_0x2431e7('0x1e21')+_0x56fc3c['status']+_0x2431e7('0x11e1')+_0x56fc3c[_0x2431e7('0xe1b')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x56fc3c[_0x2431e7('0x25f4')]?JSON[_0x2431e7('0xbac')](_0x56fc3c[_0x2431e7('0x25f4')]):_0x56fc3c[_0x2431e7('0x1586')]()});});}function _0x1a8de7(_0x2afacd,_0x116afc){const _0x107d5e=_0x326a47,_0x5369a6=_0x7f826[_0x107d5e('0x1d26')]()['title'](_0x107d5e('0x1baa'))[_0x107d5e('0xf3c')](_0x107d5e('0x1809')+_0x107d5e('0x3f3'))[_0x107d5e('0x8e8')](_0x107d5e('0x1bc0'))[_0x107d5e('0x203b')](_0x2afacd)['ok']('OK')['cancel'](_0x107d5e('0x2d3'));_0x7f826[_0x107d5e('0x1f80')](_0x5369a6)['then'](function(){_0x155541(_0x116afc);},function(){const _0x5ee822=_0x107d5e;console['log'](_0x5ee822('0x2d3'));});}function _0x2393e4(_0xab9248){const _0x1b4c36=_0x326a47,_0x5d171a=_0x7f826[_0x1b4c36('0x1d26')]()[_0x1b4c36('0xcdc')](_0x1b4c36('0x29'))[_0x1b4c36('0xf3c')](_0x1b4c36('0x12b5')+_0x491a7a['selectedDescriptions']['length']+'\x20selected'+_0x1b4c36('0x3f3'))['ariaLabel'](_0x1b4c36('0x17a'))['targetEvent'](_0xab9248)['ok']('OK')['cancel'](_0x1b4c36('0x2d3'));_0x7f826[_0x1b4c36('0x1f80')](_0x5d171a)[_0x1b4c36('0x1166')](function(){const _0xc6cc07=_0x1b4c36;_0x491a7a[_0xc6cc07('0x968')][_0xc6cc07('0x2782')](function(_0x2c62ea){_0x155541(_0x2c62ea);}),_0x491a7a['selectedDescriptions']=[];});}_0x491a7a[_0x326a47('0x16')]=[],_0x491a7a[_0x326a47('0x27ad')]=_0xdbf732,_0x491a7a[_0x326a47('0xbda')]=_0xb1b6c,_0x491a7a[_0x326a47('0x1ace')]=_0x969a2;function _0xdbf732(_0x37ebf5,_0xe45cfa){const _0x191ee4=_0x326a47;_0x7f826[_0x191ee4('0x1f80')]({'controller':_0x191ee4('0x14b7'),'controllerAs':'vm','templateUrl':_0x151f27,'parent':angular['element'](_0x2e47d4['body']),'targetEvent':_0x37ebf5,'clickOutsideToClose':!![],'locals':{'type':_0x191ee4('0x22f3'),'item':_0xe45cfa,'items':_0x491a7a[_0x191ee4('0xfe2')],'configuration':_0x491a7a[_0x191ee4('0x2468')],'account':_0x491a7a[_0x191ee4('0x1e8b')],'license':null,'setting':null,'crudPermissions':_0x491a7a['crudPermissions']}});}function _0x5ad3eb(_0x43ee89){const _0x3985bb=_0x326a47;_0x43a00f[_0x3985bb('0x78b')][_0x3985bb('0x906')]({'id':_0x43ee89['id']})[_0x3985bb('0xa44')][_0x3985bb('0x1166')](function(){const _0x425472=_0x3985bb;_0x2cfb05()[_0x425472('0x127f')](_0x491a7a['fields'],{'id':_0x43ee89['id']}),_0x30122a[_0x425472('0x103b')]({'title':'Field\x20deleted!','msg':_0x425472('0x31e')});})[_0x3985bb('0x1a80')](function(_0xc7eb03){const _0xf787f5=_0x3985bb;_0x30122a['error']({'title':_0xc7eb03[_0xf787f5('0x52d')]?_0xf787f5('0x1e21')+_0xc7eb03['status']+_0xf787f5('0x11e1')+_0xc7eb03[_0xf787f5('0xe1b')]:_0xf787f5('0x23ff'),'msg':_0xc7eb03['data']?JSON[_0xf787f5('0xbac')](_0xc7eb03['data']):_0xc7eb03['toString']()});});}function _0xb1b6c(_0x4fe5fb,_0x30f7b2){const _0x34497f=_0x326a47,_0x38c878=_0x7f826[_0x34497f('0x1d26')]()[_0x34497f('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x34497f('0xf3c')]('Field'+_0x34497f('0x3f3'))['ariaLabel'](_0x34497f('0x2127'))[_0x34497f('0x203b')](_0x4fe5fb)['ok']('OK')[_0x34497f('0x3f')](_0x34497f('0x2d3'));_0x7f826[_0x34497f('0x1f80')](_0x38c878)['then'](function(){_0x5ad3eb(_0x30f7b2);},function(){const _0xad5de2=_0x34497f;console[_0xad5de2('0x455')](_0xad5de2('0x2d3'));});}function _0x969a2(_0x5bb7fe){const _0x2d3386=_0x326a47,_0x1f40b4=_0x7f826[_0x2d3386('0x1d26')]()[_0x2d3386('0xcdc')](_0x2d3386('0x1d42'))['htmlContent'](_0x2d3386('0x12b5')+_0x491a7a[_0x2d3386('0x16')][_0x2d3386('0x264b')]+_0x2d3386('0x196d')+_0x2d3386('0x3f3'))['ariaLabel']('delete\x20fields')[_0x2d3386('0x203b')](_0x5bb7fe)['ok']('OK')[_0x2d3386('0x3f')](_0x2d3386('0x2d3'));_0x7f826[_0x2d3386('0x1f80')](_0x1f40b4)[_0x2d3386('0x1166')](function(){const _0x252464=_0x2d3386;_0x491a7a[_0x252464('0x16')][_0x252464('0x2782')](function(_0x48a9b6){_0x5ad3eb(_0x48a9b6);}),_0x491a7a[_0x252464('0x16')]=[];});}}const _0x160f15=_0x3ae1e0;_0x2c5ada[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'configurations',_0x36e6f4('0x2468'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),'crudPermissions'];function _0x2c5ada(_0x3df328,_0x1b93a9,_0x1c5510,_0x2453f9,_0x1e83f1,_0x2583be,_0x2e4f19,_0x35e40e,_0x41b013,_0x3fc8ee,_0x418580,_0x479dfb,_0x94be86,_0x699a4){const _0x3a580c=_0x36e6f4,_0x12c852=this;_0x12c852[_0x3a580c('0x98')]=_0x418580[_0x3a580c('0x26cd')](),_0x12c852[_0x3a580c('0x61a')]=[],_0x12c852[_0x3a580c('0xf8a')]=_0x94be86,_0x12c852[_0x3a580c('0x5c9')]=_0x479dfb,_0x12c852[_0x3a580c('0x243c')]=_0x699a4,_0x12c852[_0x3a580c('0x128b')]={},_0x12c852['passwordPattern']=_0x12c852[_0x3a580c('0xf8a')]&&_0x12c852[_0x3a580c('0xf8a')][_0x3a580c('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x12c852[_0x3a580c('0xcdc')]=_0x3a580c('0x1b9a'),_0x12c852[_0x3a580c('0x2468')]=angular[_0x3a580c('0x225f')](_0x41b013),_0x12c852['configurations']=_0x35e40e,_0x12c852[_0x3a580c('0x1203')]=![];!_0x12c852[_0x3a580c('0x2468')]&&(_0x12c852['freshsalesConfiguration']={'channel':'voice','type':'inbound'},_0x12c852[_0x3a580c('0xcdc')]=_0x3a580c('0x505'),_0x12c852[_0x3a580c('0x1203')]=!![]);_0x12c852[_0x3a580c('0x2')]=_0x450d6a,_0x12c852[_0x3a580c('0x1ce')]=_0x27fb05,_0x12c852[_0x3a580c('0x17cf')]=_0x2f73c8,_0x12c852[_0x3a580c('0x1a9c')]=_0x1c2149,_0x12c852['closeDialog']=_0x5a5104;function _0x450d6a(){const _0x539388=_0x3a580c;_0x12c852[_0x539388('0x61a')]=[],_0x3fc8ee[_0x539388('0x11cd')][_0x539388('0x274a')]({'id':_0x1b93a9['params']['id']},_0x12c852['freshsalesConfiguration'])[_0x539388('0xa44')][_0x539388('0x1166')](function(_0x5f441a){const _0x24fbb0=_0x539388;_0x12c852['configurations'][_0x24fbb0('0x2450')](_0x5f441a[_0x24fbb0('0x2876')]()),_0x2e4f19[_0x24fbb0('0x103b')]({'title':_0x24fbb0('0x1bdf'),'msg':_0x12c852['freshsalesConfiguration'][_0x24fbb0('0x4f0')]?_0x12c852[_0x24fbb0('0x2468')]['name']+_0x24fbb0('0x1eda'):''}),_0x5a5104(_0x5f441a);})[_0x539388('0x1a80')](function(_0x480e49){const _0x7ded6b=_0x539388;if(_0x480e49['data']&&_0x480e49[_0x7ded6b('0x25f4')][_0x7ded6b('0x61a')]&&_0x480e49[_0x7ded6b('0x25f4')][_0x7ded6b('0x61a')][_0x7ded6b('0x264b')]){_0x12c852['errors']=_0x480e49[_0x7ded6b('0x25f4')][_0x7ded6b('0x61a')]||[{'message':_0x480e49[_0x7ded6b('0x1586')](),'type':_0x7ded6b('0x3b0')}];for(let _0x4abf3e=0x0;_0x4abf3e<_0x480e49[_0x7ded6b('0x25f4')][_0x7ded6b('0x61a')][_0x7ded6b('0x264b')];_0x4abf3e+=0x1){_0x2e4f19[_0x7ded6b('0xfc9')]({'title':_0x480e49['data']['errors'][_0x4abf3e][_0x7ded6b('0x1345')],'msg':_0x480e49['data'][_0x7ded6b('0x61a')][_0x4abf3e][_0x7ded6b('0x1e70')]});}}else _0x2e4f19['error']({'title':_0x480e49[_0x7ded6b('0x52d')]?_0x7ded6b('0x1e21')+_0x480e49[_0x7ded6b('0x52d')]+_0x7ded6b('0x11e1')+_0x480e49['statusText']:'api.intFreshsalesConfiguration.save','msg':_0x480e49[_0x7ded6b('0x25f4')]?JSON['stringify'](_0x480e49['data']['message']):_0x480e49['toString']()});});}function _0x27fb05(){const _0x58d187=_0x3a580c;_0x12c852[_0x58d187('0x61a')]=[],_0x3fc8ee[_0x58d187('0x2647')][_0x58d187('0x1449')]({'id':_0x12c852[_0x58d187('0x2468')]['id']},_0x12c852[_0x58d187('0x2468')])[_0x58d187('0xa44')]['then'](function(_0x40c7d1){const _0x3a3a3f=_0x58d187,_0x3852ed=_0x2cfb05()[_0x3a3a3f('0xc38')](_0x12c852['configurations'],{'id':_0x40c7d1['id']});_0x3852ed&&_0x2cfb05()[_0x3a3a3f('0xcc3')](_0x3852ed,_0x2cfb05()['pick'](_0x40c7d1['toJSON'](),_0x2cfb05()['keys'](_0x3852ed))),_0x2e4f19[_0x3a3a3f('0x103b')]({'title':_0x3a3a3f('0x22c6'),'msg':_0x12c852[_0x3a3a3f('0x2468')][_0x3a3a3f('0x4f0')]?_0x12c852['freshsalesConfiguration']['name']+_0x3a3a3f('0x7d'):''}),_0x5a5104(_0x40c7d1);})[_0x58d187('0x1a80')](function(_0xfe5d62){const _0x1a7829=_0x58d187;if(_0xfe5d62[_0x1a7829('0x25f4')]&&_0xfe5d62[_0x1a7829('0x25f4')][_0x1a7829('0x61a')]&&_0xfe5d62[_0x1a7829('0x25f4')][_0x1a7829('0x61a')]['length']){_0x12c852['errors']=_0xfe5d62['data'][_0x1a7829('0x61a')]||[{'message':_0xfe5d62['toString'](),'type':'api.intFreshsalesConfiguration.update'}];for(let _0x476d98=0x0;_0x476d98<_0xfe5d62[_0x1a7829('0x25f4')][_0x1a7829('0x61a')][_0x1a7829('0x264b')];_0x476d98++){_0x2e4f19[_0x1a7829('0xfc9')]({'title':_0xfe5d62[_0x1a7829('0x25f4')][_0x1a7829('0x61a')][_0x476d98][_0x1a7829('0x1345')],'msg':_0xfe5d62['data'][_0x1a7829('0x61a')][_0x476d98]['message']});}}else _0x2e4f19[_0x1a7829('0xfc9')]({'title':_0xfe5d62[_0x1a7829('0x52d')]?_0x1a7829('0x1e21')+_0xfe5d62[_0x1a7829('0x52d')]+'\x20-\x20'+_0xfe5d62[_0x1a7829('0xe1b')]:_0x1a7829('0x7b'),'msg':_0xfe5d62[_0x1a7829('0x25f4')]?JSON[_0x1a7829('0xbac')](_0xfe5d62['data'][_0x1a7829('0x1e70')]):_0xfe5d62[_0x1a7829('0x1586')]()});});}function _0x2f73c8(_0x27e51f){const _0x64bf48=_0x3a580c;_0x12c852[_0x64bf48('0x61a')]=[];const _0x4b798c=_0x2453f9[_0x64bf48('0x1d26')]()[_0x64bf48('0xcdc')](_0x64bf48('0x7fb'))['content']('The\x20freshsalesConfiguration\x20will\x20be\x20deleted.')[_0x64bf48('0x8e8')]('Delete\x20FreshsalesConfiguration')['ok']('Delete')[_0x64bf48('0x3f')](_0x64bf48('0x497'))['targetEvent'](_0x27e51f);_0x2453f9['show'](_0x4b798c)[_0x64bf48('0x1166')](function(){const _0x14731f=_0x64bf48;_0x3fc8ee[_0x14731f('0x2647')][_0x14731f('0x906')]({'id':_0x12c852[_0x14731f('0x2468')]['id']})[_0x14731f('0xa44')][_0x14731f('0x1166')](function(){const _0x11bee8=_0x14731f;_0x2cfb05()[_0x11bee8('0x127f')](_0x12c852['configurations'],{'id':_0x12c852['freshsalesConfiguration']['id']}),_0x2e4f19[_0x11bee8('0x103b')]({'title':_0x11bee8('0xb69'),'msg':(_0x12c852['freshsalesConfiguration'][_0x11bee8('0x4f0')]||_0x11bee8('0x2468'))+_0x11bee8('0x7cd')}),_0x5a5104(_0x12c852['freshsalesConfiguration']);})[_0x14731f('0x1a80')](function(_0x3e47ab){const _0x430e5b=_0x14731f;if(_0x3e47ab[_0x430e5b('0x25f4')]&&_0x3e47ab['data'][_0x430e5b('0x61a')]&&_0x3e47ab[_0x430e5b('0x25f4')]['errors'][_0x430e5b('0x264b')]){_0x12c852['errors']=_0x3e47ab['data']['errors']||[{'message':_0x3e47ab[_0x430e5b('0x1586')](),'type':'api.intFreshsalesConfiguration.delete'}];for(let _0x443104=0x0;_0x443104<_0x3e47ab[_0x430e5b('0x25f4')][_0x430e5b('0x61a')][_0x430e5b('0x264b')];_0x443104++){_0x2e4f19[_0x430e5b('0xfc9')]({'title':_0x3e47ab[_0x430e5b('0x25f4')][_0x430e5b('0x61a')][_0x443104][_0x430e5b('0x1345')],'msg':_0x3e47ab[_0x430e5b('0x25f4')][_0x430e5b('0x61a')][_0x443104]['message']});}}else _0x2e4f19[_0x430e5b('0xfc9')]({'title':_0x3e47ab[_0x430e5b('0x52d')]?_0x430e5b('0x1e21')+_0x3e47ab[_0x430e5b('0x52d')]+_0x430e5b('0x11e1')+_0x3e47ab['statusText']:_0x430e5b('0xc6c'),'msg':_0x3e47ab['data']?JSON[_0x430e5b('0xbac')](_0x3e47ab[_0x430e5b('0x25f4')][_0x430e5b('0x1e70')]):_0x3e47ab[_0x430e5b('0x1e70')]||_0x3e47ab['toString']()});});},function(){});}function _0x1c2149(_0x4d3b57){return _0x4d3b57===null?undefined:new Date(_0x4d3b57);}function _0x5a5104(_0x4f8b63){const _0xb68e2d=_0x3a580c;_0x2453f9[_0xb68e2d('0x1197')](_0x4f8b63);}}const _0x1b3c6c=_0x2c5ada;_0x59c6bb['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'toasty',_0x36e6f4('0xd29'),'items',_0x36e6f4('0x1301'),'account','type',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x59c6bb(_0x4a03d4,_0x42a382,_0x51ae8f,_0x2eb7a6,_0x473df6,_0x103b5d,_0x502a51,_0x4ff88e,_0x2569d8,_0xe93b1d,_0x51e8ed,_0x5cf6f6,_0x3e3fd3){const _0x76727e=_0x36e6f4,_0x14ca94=this;_0x14ca94[_0x76727e('0x98')]=_0x5cf6f6[_0x76727e('0x26cd')](),_0x14ca94[_0x76727e('0x61a')]=[],_0x14ca94[_0x76727e('0xcdc')]=_0x76727e('0x2012')+_0x2cfb05()[_0x76727e('0x113b')](_0xe93b1d),_0x14ca94[_0x76727e('0x1301')]=angular[_0x76727e('0x225f')](_0x4ff88e),_0x14ca94[_0x76727e('0xbd7')]=_0x502a51,_0x14ca94[_0x76727e('0x1345')]=_0xe93b1d,_0x14ca94[_0x76727e('0x243c')]=_0x3e3fd3,_0x14ca94[_0x76727e('0x17c7')]=![];!_0x14ca94[_0x76727e('0x1301')]&&(_0x14ca94[_0x76727e('0x1301')]={'type':'string'},_0x14ca94[_0x76727e('0x1301')][_0x2cfb05()[_0x76727e('0x92c')](_0xe93b1d)+'Id']=_0x103b5d['id'],_0x14ca94[_0x76727e('0xcdc')]=_0x76727e('0xf9c')+_0x2cfb05()[_0x76727e('0x113b')](_0xe93b1d),_0x14ca94[_0x76727e('0x17c7')]=!![]);_0x14ca94[_0x76727e('0x1e8a')]=_0x259824,_0x14ca94[_0x76727e('0x13b8')]=_0x1c05a9,_0x14ca94[_0x76727e('0x18d3')]=_0x2b367c,_0x14ca94[_0x76727e('0x1551')]=_0x1d4e89,_0x14ca94[_0x76727e('0x24a0')]=_0x59691f,_0x51e8ed[_0x76727e('0x734')][_0x76727e('0xd83')]({'nolimit':!![]})[_0x76727e('0xa44')][_0x76727e('0x1166')](function(_0x5425bb){const _0x4012ef=_0x76727e;return _0x14ca94[_0x4012ef('0x57a')]=_0x5425bb[_0x4012ef('0x269a')]?_0x5425bb[_0x4012ef('0x269a')]:[],_0x51e8ed['voiceAgentReport'][_0x4012ef('0x23d0')]()['$promise'];})[_0x76727e('0x1166')](function(_0x2b018c){const _0x21f41f=_0x76727e;return _0x14ca94[_0x21f41f('0x1d45')]=_0x2cfb05()[_0x21f41f('0x13ca')](_0x2cfb05()[_0x21f41f('0x14a4')](_0x2b018c),['$promise','$resolved',_0x21f41f('0x262'),_0x21f41f('0x6f9'),_0x21f41f('0x978')]),_0x14ca94[_0x21f41f('0x1d45')][_0x21f41f('0x1514')]('recordingURL'),_0x51e8ed['voiceDialReport'][_0x21f41f('0x23d0')]()[_0x21f41f('0xa44')];})[_0x76727e('0x1166')](function(_0x9f146c){const _0x5a623f=_0x76727e;_0x14ca94[_0x5a623f('0x1348')]=_0x2cfb05()[_0x5a623f('0x13ca')](_0x2cfb05()[_0x5a623f('0x14a4')](_0x9f146c),[_0x5a623f('0xa44'),_0x5a623f('0xfcd'),_0x5a623f('0x262'),'updatedAt',_0x5a623f('0x978')]),_0x14ca94[_0x5a623f('0x1348')][_0x5a623f('0x1514')]('recordingURL');})[_0x76727e('0x1a80')](function(_0x4a27ae){const _0x24fd41=_0x76727e;_0x473df6[_0x24fd41('0xfc9')]({'title':_0x4a27ae[_0x24fd41('0x52d')]?_0x24fd41('0x1e21')+_0x4a27ae[_0x24fd41('0x52d')]+_0x24fd41('0x11e1')+_0x4a27ae[_0x24fd41('0xe1b')]:_0x24fd41('0xfe5'),'msg':_0x4a27ae[_0x24fd41('0x25f4')]?JSON[_0x24fd41('0xbac')](_0x4a27ae[_0x24fd41('0x25f4')]):_0x4a27ae['toString']()});}),_0x51e8ed['intFreshsalesAccount'][_0x76727e('0x18ea')]({'id':_0x2569d8['id'],'ticketType':_0x103b5d[_0x76727e('0x11ba')]?_0x103b5d['ticketType']:undefined})[_0x76727e('0xa44')][_0x76727e('0x1166')](function(_0x263d9b){const _0x584a70=_0x76727e;_0x14ca94[_0x584a70('0x606')]=!![],_0x14ca94['fields']=_0x263d9b[_0x584a70('0x269a')]?_0x263d9b[_0x584a70('0x269a')]:[],_0x14ca94[_0x584a70('0x1301')][_0x584a70('0x1143')]&&(_0x14ca94[_0x584a70('0x117e')]=_0x2cfb05()[_0x584a70('0xc38')](_0x14ca94['fields'],{'id':_0x14ca94[_0x584a70('0x1301')][_0x584a70('0x1143')]}));})[_0x76727e('0x1a80')](function(_0x365b0f){const _0xbd28c3=_0x76727e;_0x14ca94[_0xbd28c3('0x606')]=![],console[_0xbd28c3('0xfc9')](_0x365b0f);});function _0x259824(){const _0x530f14=_0x76727e;_0x14ca94[_0x530f14('0x61a')]=[],_0x14ca94[_0x530f14('0x117e')]&&(_0x14ca94['item'][_0x530f14('0x1143')]=_0x14ca94['customField']['id'],_0x14ca94[_0x530f14('0x1301')][_0x530f14('0x3c0')]=_0x14ca94[_0x530f14('0x117e')][_0x530f14('0x4f0')],_0x14ca94[_0x530f14('0x1301')][_0x530f14('0x117e')]=_0x14ca94[_0x530f14('0x117e')][_0x530f14('0x2853')]),_0x51e8ed['intFreshsalesField'][_0x530f14('0x9cc')](_0x14ca94['item'])[_0x530f14('0xa44')][_0x530f14('0x1166')](function(_0x111336){const _0x1f6f5c=_0x530f14;_0x14ca94[_0x1f6f5c('0xbd7')][_0x1f6f5c('0x2450')](_0x111336),_0x473df6[_0x1f6f5c('0x103b')]({'title':_0x2cfb05()[_0x1f6f5c('0x92c')](_0xe93b1d)+_0x1f6f5c('0x13f0'),'msg':_0x2cfb05()[_0x1f6f5c('0x92c')](_0xe93b1d)+'\x20has\x20been\x20created!'}),_0x59691f();})['catch'](function(_0x514f41){const _0x1d9750=_0x530f14;console[_0x1d9750('0xfc9')](_0x514f41),_0x14ca94[_0x1d9750('0x61a')]=_0x514f41[_0x1d9750('0x25f4')]['errors']||[{'message':_0x514f41[_0x1d9750('0x1586')](),'type':_0x1d9750('0x215d')}];});}function _0x1c05a9(){const _0x2240ee=_0x76727e;_0x14ca94[_0x2240ee('0x61a')]=[],_0x14ca94[_0x2240ee('0x117e')]&&(_0x14ca94['item']['idField']=_0x14ca94[_0x2240ee('0x117e')]['id'],_0x14ca94['item'][_0x2240ee('0x3c0')]=_0x14ca94[_0x2240ee('0x117e')][_0x2240ee('0x4f0')],_0x14ca94[_0x2240ee('0x1301')][_0x2240ee('0x117e')]=_0x14ca94[_0x2240ee('0x117e')]['custom']),_0x51e8ed[_0x2240ee('0x78b')][_0x2240ee('0x1449')]({'id':_0x14ca94[_0x2240ee('0x1301')]['id']},_0x14ca94[_0x2240ee('0x1301')])[_0x2240ee('0xa44')][_0x2240ee('0x1166')](function(_0x391b68){const _0xa33708=_0x2240ee,_0x27a422=_0x2cfb05()['find'](_0x14ca94[_0xa33708('0xbd7')],{'id':_0x391b68['id']});_0x27a422&&_0x2cfb05()[_0xa33708('0xcc3')](_0x27a422,_0x391b68),_0x473df6['success']({'title':_0x2cfb05()['capitalize'](_0xe93b1d)+_0xa33708('0x1a2f'),'msg':_0x2cfb05()[_0xa33708('0x92c')](_0xe93b1d)+_0xa33708('0x7d')}),_0x59691f();})['catch'](function(_0x430a14){const _0xf81c6e=_0x2240ee;console['error'](_0x430a14),_0x14ca94[_0xf81c6e('0x61a')]=_0x430a14[_0xf81c6e('0x25f4')][_0xf81c6e('0x61a')]||[{'message':_0x430a14[_0xf81c6e('0x1586')](),'type':_0xf81c6e('0x10cd')}];});}function _0x2b367c(_0x1b886f){const _0x52cd06=_0x76727e;_0x14ca94['errors']=[];const _0x50388d=_0x2eb7a6[_0x52cd06('0x1d26')]()[_0x52cd06('0xcdc')](_0x52cd06('0x7fb'))['content'](_0x52cd06('0x135f')+_0xe93b1d+'\x20will\x20be\x20deleted.')[_0x52cd06('0x8e8')](_0x52cd06('0x237c')+_0x2cfb05()[_0x52cd06('0x92c')](_0xe93b1d))['ok']('Delete')[_0x52cd06('0x3f')](_0x52cd06('0x497'))[_0x52cd06('0x203b')](_0x1b886f);_0x2eb7a6['show'](_0x50388d)[_0x52cd06('0x1166')](function(){const _0x4399be=_0x52cd06;_0x51e8ed[_0x4399be('0x78b')]['delete']({'id':_0x14ca94[_0x4399be('0x1301')]['id']})[_0x4399be('0xa44')][_0x4399be('0x1166')](function(){const _0x5b4f92=_0x4399be;_0x2cfb05()['remove'](_0x14ca94['items'],{'id':_0x14ca94[_0x5b4f92('0x1301')]['id']}),_0x473df6['success']({'title':_0x2cfb05()[_0x5b4f92('0x92c')](_0xe93b1d)+'\x20properly\x20deleted!','msg':_0x2cfb05()['capitalize'](_0xe93b1d)+_0x5b4f92('0x7cd')}),_0x59691f();})[_0x4399be('0x1a80')](function(_0x2b7822){const _0x352c21=_0x4399be;console[_0x352c21('0xfc9')](_0x2b7822),_0x14ca94[_0x352c21('0x61a')]=_0x2b7822['data'][_0x352c21('0x61a')]||[{'message':_0x2b7822[_0x352c21('0x1586')](),'type':_0x352c21('0x2602')}];});},function(){});}function _0x1d4e89(){const _0x28086f=_0x76727e;return _0x14ca94[_0x28086f('0x1301')][_0x28086f('0xbdb')]!==undefined?_0x14ca94[_0x28086f('0x1301')][_0x28086f('0xbdb')]:_0x28086f('0x16a4');}function _0x59691f(){const _0xab1e1a=_0x76727e;_0x2eb7a6[_0xab1e1a('0x1197')]();}}const _0x54afa6=_0x59c6bb;_0x3ca44a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),'license',_0x36e6f4('0xf8a'),'api',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'freshsalesAccount',_0x36e6f4('0x17aa')];function _0x3ca44a(_0x34574c,_0x53af1c,_0xa04ff4,_0xdad966,_0x30764e,_0x24f843,_0x3350ad,_0x8460c9,_0x368fda,_0x280df0,_0x3d3a1f,_0x4021e9){const _0x9c8fcb=_0x36e6f4,_0x229e73=this;_0x229e73[_0x9c8fcb('0x98')]=_0x280df0[_0x9c8fcb('0x26cd')](),_0x229e73[_0x9c8fcb('0x5c9')]=_0x24f843,_0x229e73[_0x9c8fcb('0xf8a')]=_0x3350ad,_0x229e73['passwordPattern']=_0x229e73[_0x9c8fcb('0xf8a')][_0x9c8fcb('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x229e73[_0x9c8fcb('0x246b')]=_0x53af1c[_0x9c8fcb('0x6f1')]()+_0x9c8fcb('0xc51')+_0x53af1c['host'](),_0x229e73[_0x9c8fcb('0x1e8b')]=_0x3d3a1f||_0x34574c[_0x9c8fcb('0x23f')][_0x9c8fcb('0x1e8b')]||{},_0x229e73[_0x9c8fcb('0x17aa')]=_0x4021e9&&_0x4021e9[_0x9c8fcb('0x240f')]==0x1?_0x4021e9[_0x9c8fcb('0x269a')][0x0]:null,_0x229e73[_0x9c8fcb('0x243c')]=_0x280df0[_0x9c8fcb('0xd87')](_0x229e73[_0x9c8fcb('0x17aa')]?_0x229e73[_0x9c8fcb('0x17aa')][_0x9c8fcb('0x243c')]:null),_0x229e73[_0x9c8fcb('0x128b')]={},_0x229e73[_0x9c8fcb('0x2669')]=_0x34574c['params'][_0x9c8fcb('0xbe3')]||0x0,_0x229e73[_0x9c8fcb('0x31d')]=_0x368fda[_0x9c8fcb('0x1fa1')],_0x229e73[_0x9c8fcb('0x9f7')]=_0x3b114c,_0x229e73[_0x9c8fcb('0x196e')]=_0x5066c0;function _0x3b114c(){const _0x4c1dd1=_0x9c8fcb;_0x34574c['go'](_0x4c1dd1('0x1da7'),{},{'reload':_0x4c1dd1('0x1da7')});}function _0x5066c0(){const _0x570011=_0x9c8fcb;_0x8460c9[_0x570011('0x11cd')][_0x570011('0x1449')]({'id':_0x229e73['freshsalesAccount']['id']},_0x229e73['freshsalesAccount'])['$promise'][_0x570011('0x1166')](function(){const _0x4198db=_0x570011;_0x368fda[_0x4198db('0x103b')]({'title':_0x4198db('0x28b0'),'msg':_0x229e73['freshsalesAccount'][_0x4198db('0x4f0')]?_0x229e73[_0x4198db('0x1e8b')][_0x4198db('0x4f0')]+_0x4198db('0xa17'):''});})['catch'](function(_0x2d4909){const _0xd84f5=_0x570011;_0x368fda[_0xd84f5('0xfc9')]({'title':_0x2d4909[_0xd84f5('0x52d')]?'API:'+_0x2d4909[_0xd84f5('0x52d')]+'\x20-\x20'+_0x2d4909[_0xd84f5('0xe1b')]:_0xd84f5('0x273b'),'msg':_0x2d4909['data']?JSON[_0xd84f5('0xbac')](_0x2d4909[_0xd84f5('0x25f4')]):_0x2d4909['toString']()});});}}const _0x4ac1c6=_0x3ca44a,_0x1e1cb9=_0x2734b2['p']+_0x36e6f4('0xa30');_0x37aec3[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x163e'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),'api',_0x36e6f4('0x1f36'),'toasty','Auth','license',_0x36e6f4('0xf8a')];function _0x37aec3(_0x4fb06d,_0x2e99d1,_0x597963,_0x30c399,_0x59d57d,_0x311b96,_0x2e4ca5,_0x743a35,_0x415454,_0x4af151,_0x5d2374,_0xbe5846,_0x5e5bc9,_0x1988ec,_0xf20146,_0x47b44a,_0x55a37b){const _0x10a127=_0x36e6f4,_0x1ba722=this;_0x1ba722[_0x10a127('0x5c9')]=_0x47b44a,_0x1ba722[_0x10a127('0xf8a')]=_0x55a37b,_0x1ba722[_0x10a127('0x98')]=_0xf20146[_0x10a127('0x26cd')](),_0x1ba722[_0x10a127('0x163e')]=_0x415454||{'count':0x0,'rows':[]},_0x1ba722[_0x10a127('0x7f')]=_0x4af151,_0x1ba722['userProfileSection']=_0x5d2374&&_0x5d2374['count']==0x1?_0x5d2374[_0x10a127('0x269a')][0x0]:null,_0x1ba722['crudPermissions']=_0xf20146['parseCrudPermissions'](_0x1ba722['userProfileSection']?_0x1ba722[_0x10a127('0x17aa')][_0x10a127('0x243c')]:null),_0x1ba722[_0x10a127('0x916')]=_0x10a127('0x163e'),_0x1ba722['listOrder']='',_0x1ba722[_0x10a127('0x104c')]=null,_0x1ba722[_0x10a127('0xe4a')]=[],_0x1ba722[_0x10a127('0x2218')]={'fields':_0x10a127('0x7d6'),'limit':0xa,'page':0x1},_0x1ba722['editstate']=_0x43a457,_0x1ba722[_0x10a127('0x2113')]=_0x3c1e96,_0x1ba722[_0x10a127('0x8d8')]=_0x16beab,_0x1ba722[_0x10a127('0x103b')]=_0x2e0223,_0x1ba722[_0x10a127('0x2b7')]=_0x1ccbf3,_0x1ba722[_0x10a127('0x79a')]=_0x2626bb,_0x1ba722[_0x10a127('0x1e0a')]=_0x2d0e24,_0x1ba722[_0x10a127('0x1578')]=_0x429329,_0x1ba722[_0x10a127('0x17f3')]=_0x1329b3,_0x1ba722['deselectFreshsalesAccounts']=_0x3c980f,_0x1ba722[_0x10a127('0x1cec')]=_0x1d469b;function _0x43a457(_0x166dc6){const _0x4ffd2a=_0x10a127;_0x597963['go'](_0x4ffd2a('0x182f'),{'id':_0x166dc6['id'],'freshsalesAccount':_0x166dc6,'crudPermissions':_0x1ba722[_0x4ffd2a('0x243c')]});}function _0x3c1e96(_0x444a1d){const _0x40a868=_0x10a127;return _0xbe5846[_0x40a868('0x11cd')][_0x40a868('0x18ea')]({'id':_0x444a1d['id'],'test':!![]})[_0x40a868('0xa44')][_0x40a868('0x1166')](function(){const _0x829cca=_0x40a868;_0x1988ec[_0x829cca('0x103b')]({'title':_0x829cca('0x1e88'),'msg':_0x829cca('0x1fef')});})[_0x40a868('0x1a80')](function(_0x3488f1){const _0x5bce33=_0x40a868;_0x1988ec[_0x5bce33('0xfc9')]({'title':_0x5bce33('0x1e88'),'msg':_0x3488f1[_0x5bce33('0x25f4')]?_0x3488f1[_0x5bce33('0x25f4')][_0x5bce33('0x1e70')]?_0x3488f1[_0x5bce33('0x25f4')][_0x5bce33('0x1e70')]:JSON[_0x5bce33('0xbac')](_0x3488f1[_0x5bce33('0x25f4')]):_0x3488f1['toString']()});});}function _0x16beab(_0x2209fa,_0x18010d){const _0x2d58a7=_0x10a127,_0x1c511d=_0x59d57d[_0x2d58a7('0x1d26')]()[_0x2d58a7('0xcdc')](_0x2d58a7('0x288d')+_0x2cfb05()[_0x2d58a7('0xb35')](_0x2d58a7('0x1e8b'))+'?')[_0x2d58a7('0xf3c')](_0x2d58a7('0x12b5')+(_0x2209fa[_0x2d58a7('0x4f0')]||'freshsalesAccount')+''+_0x2d58a7('0x3f3'))[_0x2d58a7('0x8e8')](_0x2d58a7('0x1732'))['targetEvent'](_0x18010d)['ok']('OK')[_0x2d58a7('0x3f')](_0x2d58a7('0x2d3'));_0x59d57d[_0x2d58a7('0x1f80')](_0x1c511d)['then'](function(){_0x2d0e24(_0x2209fa);},function(){console['log']('CANCEL');});}let _0x2becd2=!![],_0x2079fe=0x1;_0x4fb06d['$watch'](_0x10a127('0x12d8'),function(_0x1e8143,_0x2e08d9){const _0x331dff=_0x10a127;_0x2becd2?_0x2e4ca5(function(){_0x2becd2=![];}):(!_0x2e08d9&&(_0x2079fe=_0x1ba722[_0x331dff('0x2218')][_0x331dff('0x1a43')]),_0x1e8143!==_0x2e08d9&&(_0x1ba722['query']['page']=0x1),!_0x1e8143&&(_0x1ba722[_0x331dff('0x2218')][_0x331dff('0x1a43')]=_0x2079fe),_0x1ba722[_0x331dff('0x2b7')]());});function _0x2e0223(_0x15d1fd){const _0x27344d=_0x10a127;_0x1ba722[_0x27344d('0x163e')]=_0x15d1fd||{'count':0x0,'rows':[]};}function _0x1ccbf3(){const _0x47e882=_0x10a127;_0x1ba722[_0x47e882('0x2218')][_0x47e882('0x1098')]=(_0x1ba722[_0x47e882('0x2218')]['page']-0x1)*_0x1ba722['query']['limit'],_0xf20146[_0x47e882('0x1ac6')](_0x47e882('0xa7c'))?_0x1ba722['promise']=_0xbe5846[_0x47e882('0x11cd')][_0x47e882('0xd83')](_0x1ba722[_0x47e882('0x2218')],_0x2e0223)['$promise']:(_0x1ba722[_0x47e882('0x2218')]['id']=_0x1ba722[_0x47e882('0x7f')]['id'],_0x1ba722['query'][_0x47e882('0xe60')]=_0x47e882('0x16b7'),_0x1ba722[_0x47e882('0x1f48')]=_0xbe5846[_0x47e882('0x7f')][_0x47e882('0x263a')](_0x1ba722[_0x47e882('0x2218')],_0x2e0223)[_0x47e882('0xa44')]);}function _0x2626bb(_0x19867f,_0x386581){const _0x1136b2=_0x10a127;_0x59d57d['show']({'controller':'CreateOrEditFreshsalesAccountDialogController','controllerAs':'vm','templateUrl':_0x1e1cb9,'parent':angular['element'](_0x311b96['body']),'targetEvent':_0x19867f,'clickOutsideToClose':!![],'locals':{'freshsalesAccount':_0x386581,'freshsalesAccounts':_0x1ba722[_0x1136b2('0x163e')][_0x1136b2('0x269a')],'license':_0x1ba722['license'],'setting':_0x1ba722[_0x1136b2('0xf8a')],'crudPermissions':_0x1ba722[_0x1136b2('0x243c')]}});}function _0x2d0e24(_0x514ba9){const _0x3ea8c2=_0x10a127;_0xbe5846[_0x3ea8c2('0x11cd')][_0x3ea8c2('0x906')]({'id':_0x514ba9['id']})[_0x3ea8c2('0xa44')][_0x3ea8c2('0x1166')](function(){const _0x59eae6=_0x3ea8c2;_0x2cfb05()[_0x59eae6('0x127f')](_0x1ba722[_0x59eae6('0x163e')]['rows'],{'id':_0x514ba9['id']}),_0x1ba722[_0x59eae6('0x163e')][_0x59eae6('0x240f')]-=0x1,!_0x1ba722[_0x59eae6('0x163e')][_0x59eae6('0x269a')]['length']&&_0x1ba722['getFreshsalesAccounts'](),_0x1988ec['success']({'title':_0x2cfb05()['startCase'](_0x59eae6('0x594'))+_0x59eae6('0x2b6'),'msg':_0x514ba9[_0x59eae6('0x4f0')]?_0x514ba9['name']+_0x59eae6('0x7cd'):''});})[_0x3ea8c2('0x1a80')](function(_0x512fbb){const _0x2b3ec9=_0x3ea8c2;if(_0x512fbb['data']&&_0x512fbb[_0x2b3ec9('0x25f4')][_0x2b3ec9('0x61a')]&&_0x512fbb['data'][_0x2b3ec9('0x61a')][_0x2b3ec9('0x264b')]){_0x1ba722[_0x2b3ec9('0x61a')]=_0x512fbb[_0x2b3ec9('0x25f4')]['errors']||[{'message':_0x512fbb[_0x2b3ec9('0x1586')](),'type':'SYSTEM:DELETEintFreshsalesAccount'}];for(let _0x6f9b0c=0x0;_0x6f9b0c<_0x512fbb[_0x2b3ec9('0x25f4')]['errors'][_0x2b3ec9('0x264b')];_0x6f9b0c++){_0x1988ec[_0x2b3ec9('0xfc9')]({'title':_0x512fbb[_0x2b3ec9('0x25f4')][_0x2b3ec9('0x61a')][_0x6f9b0c][_0x2b3ec9('0x1345')],'msg':_0x512fbb[_0x2b3ec9('0x25f4')][_0x2b3ec9('0x61a')][_0x6f9b0c]['message']});}}else _0x1988ec['error']({'title':_0x512fbb[_0x2b3ec9('0x52d')]?'API:'+_0x512fbb[_0x2b3ec9('0x52d')]+_0x2b3ec9('0x11e1')+_0x512fbb[_0x2b3ec9('0xe1b')]:'SYSTEM:DELETEintFreshsalesAccount','msg':_0x512fbb[_0x2b3ec9('0x25f4')]?JSON[_0x2b3ec9('0xbac')](_0x512fbb[_0x2b3ec9('0x25f4')]['message']):_0x512fbb[_0x2b3ec9('0x1e70')]||_0x512fbb[_0x2b3ec9('0x1586')]()});});}function _0x429329(){const _0x1c63f2=_0x10a127,_0x2b996e=angular[_0x1c63f2('0x225f')](_0x1ba722['selectedFreshsalesAccounts']);return _0x1ba722[_0x1c63f2('0xe4a')]=[],_0x2b996e;}function _0x1329b3(_0x21f4b0){const _0x1297b0=_0x10a127,_0x4b05ed=_0x59d57d[_0x1297b0('0x1d26')]()[_0x1297b0('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20freshsalesAccounts?')[_0x1297b0('0xf3c')](_0x1297b0('0x12b5')+_0x1ba722[_0x1297b0('0xe4a')][_0x1297b0('0x264b')]+_0x1297b0('0x196d')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x1297b0('0x21e'))[_0x1297b0('0x203b')](_0x21f4b0)['ok']('OK')[_0x1297b0('0x3f')](_0x1297b0('0x2d3'));_0x59d57d['show'](_0x4b05ed)[_0x1297b0('0x1166')](function(){const _0x4b5d49=_0x1297b0;_0x1ba722[_0x4b5d49('0xe4a')][_0x4b5d49('0x2782')](function(_0xc7ebfb){_0x2d0e24(_0xc7ebfb);}),_0x1ba722[_0x4b5d49('0xe4a')]=[];});}function _0x3c980f(){_0x1ba722['selectedFreshsalesAccounts']=[];}function _0x1d469b(){const _0x30e4a6=_0x10a127;_0x1ba722[_0x30e4a6('0xe4a')]=_0x1ba722[_0x30e4a6('0x163e')]['rows'];}}const _0x4c68be=_0x37aec3;_0x3860b9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x10a8'),'salesforceAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'crudPermissions'];function _0x3860b9(_0x2e7abd,_0x444d10,_0x5c95b1,_0x1cf67f,_0x36be9b,_0x188393,_0x591bc6,_0x2682f1,_0x2746e9,_0x249c14,_0x22c2ec,_0x367bd1,_0x5ee589,_0x25a43b){const _0x28ebf6=_0x36e6f4,_0x1d7c3a=this;_0x1d7c3a[_0x28ebf6('0x98')]=_0x22c2ec[_0x28ebf6('0x26cd')](),_0x1d7c3a['errors']=[],_0x1d7c3a['setting']=_0x5ee589,_0x1d7c3a[_0x28ebf6('0x5c9')]=_0x367bd1,_0x1d7c3a['crudPermissions']=_0x25a43b,_0x1d7c3a[_0x28ebf6('0x128b')]={},_0x1d7c3a[_0x28ebf6('0x2900')]=_0x1d7c3a[_0x28ebf6('0xf8a')]&&_0x1d7c3a[_0x28ebf6('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1d7c3a['title']=_0x28ebf6('0x2ec'),_0x1d7c3a[_0x28ebf6('0x2330')]=angular[_0x28ebf6('0x225f')](_0x2746e9),_0x1d7c3a['salesforceAccounts']=_0x2682f1,_0x1d7c3a[_0x28ebf6('0x16f8')]=![];!_0x1d7c3a[_0x28ebf6('0x2330')]&&(_0x1d7c3a['salesforceAccount']={'type':_0x28ebf6('0x73a'),'serverUrl':_0x5c95b1[_0x28ebf6('0x6f1')]()+_0x28ebf6('0xc51')+_0x5c95b1['host']()+(_0x5c95b1[_0x28ebf6('0x93d')]()?':'+_0x5c95b1['port']():'')},_0x1d7c3a['title']=_0x28ebf6('0xb34'),_0x1d7c3a[_0x28ebf6('0x16f8')]=!![]);_0x1d7c3a[_0x28ebf6('0xf54')]=_0x4c3545,_0x1d7c3a[_0x28ebf6('0x16fd')]=_0x523197,_0x1d7c3a[_0x28ebf6('0xcec')]=_0x4f5523,_0x1d7c3a[_0x28ebf6('0x1a9c')]=_0x44fdd7,_0x1d7c3a['closeDialog']=_0x51be6b;function _0x4c3545(){const _0x43de62=_0x28ebf6;_0x1d7c3a[_0x43de62('0x61a')]=[],_0x249c14[_0x43de62('0x164')][_0x43de62('0x9cc')](_0x1d7c3a[_0x43de62('0x2330')])[_0x43de62('0xa44')][_0x43de62('0x1166')](function(_0x1c907f){const _0x5754fa=_0x43de62;_0x1d7c3a['salesforceAccounts'][_0x5754fa('0x2450')](_0x1c907f['toJSON']()),_0x591bc6[_0x5754fa('0x103b')]({'title':_0x5754fa('0x168b'),'msg':_0x1d7c3a[_0x5754fa('0x2330')][_0x5754fa('0x4f0')]?_0x1d7c3a['salesforceAccount'][_0x5754fa('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x51be6b(_0x1c907f);})[_0x43de62('0x1a80')](function(_0x19108d){const _0xf16afb=_0x43de62;if(_0x19108d[_0xf16afb('0x25f4')]&&_0x19108d[_0xf16afb('0x25f4')][_0xf16afb('0x61a')]&&_0x19108d['data']['errors'][_0xf16afb('0x264b')]){_0x1d7c3a[_0xf16afb('0x61a')]=_0x19108d[_0xf16afb('0x25f4')][_0xf16afb('0x61a')]||[{'message':_0x19108d[_0xf16afb('0x1586')](),'type':'api.intSalesforceAccount.save'}];for(let _0x15d01f=0x0;_0x15d01f<_0x19108d[_0xf16afb('0x25f4')][_0xf16afb('0x61a')][_0xf16afb('0x264b')];_0x15d01f+=0x1){_0x591bc6[_0xf16afb('0xfc9')]({'title':_0x19108d['data'][_0xf16afb('0x61a')][_0x15d01f][_0xf16afb('0x1345')],'msg':_0x19108d['data'][_0xf16afb('0x61a')][_0x15d01f][_0xf16afb('0x1e70')]});}}else _0x591bc6[_0xf16afb('0xfc9')]({'title':_0x19108d[_0xf16afb('0x52d')]?_0xf16afb('0x1e21')+_0x19108d[_0xf16afb('0x52d')]+_0xf16afb('0x11e1')+_0x19108d[_0xf16afb('0xe1b')]:'api.intSalesforceAccount.save','msg':_0x19108d['data']?JSON[_0xf16afb('0xbac')](_0x19108d[_0xf16afb('0x25f4')][_0xf16afb('0x1e70')]):_0x19108d['toString']()});});}function _0x523197(){const _0x3ad213=_0x28ebf6;_0x1d7c3a[_0x3ad213('0x61a')]=[],_0x249c14['intSalesforceAccount'][_0x3ad213('0x1449')]({'id':_0x1d7c3a[_0x3ad213('0x2330')]['id']},_0x1d7c3a[_0x3ad213('0x2330')])[_0x3ad213('0xa44')][_0x3ad213('0x1166')](function(_0x382011){const _0x136796=_0x3ad213,_0x2e772c=_0x2cfb05()[_0x136796('0xc38')](_0x1d7c3a['salesforceAccounts'],{'id':_0x382011['id']});_0x2e772c&&_0x2cfb05()['merge'](_0x2e772c,_0x2cfb05()['pick'](_0x382011[_0x136796('0x2876')](),_0x2cfb05()['keys'](_0x2e772c))),_0x591bc6['success']({'title':_0x136796('0x25e1'),'msg':_0x1d7c3a[_0x136796('0x2330')][_0x136796('0x4f0')]?_0x1d7c3a[_0x136796('0x2330')][_0x136796('0x4f0')]+_0x136796('0x7d'):''}),_0x51be6b(_0x382011);})['catch'](function(_0x25157b){const _0xb3932d=_0x3ad213;if(_0x25157b[_0xb3932d('0x25f4')]&&_0x25157b['data']['errors']&&_0x25157b['data']['errors'][_0xb3932d('0x264b')]){_0x1d7c3a[_0xb3932d('0x61a')]=_0x25157b['data'][_0xb3932d('0x61a')]||[{'message':_0x25157b[_0xb3932d('0x1586')](),'type':'api.intSalesforceAccount.update'}];for(let _0x543ee4=0x0;_0x543ee4<_0x25157b['data']['errors'][_0xb3932d('0x264b')];_0x543ee4++){_0x591bc6[_0xb3932d('0xfc9')]({'title':_0x25157b[_0xb3932d('0x25f4')]['errors'][_0x543ee4][_0xb3932d('0x1345')],'msg':_0x25157b[_0xb3932d('0x25f4')][_0xb3932d('0x61a')][_0x543ee4]['message']});}}else _0x591bc6[_0xb3932d('0xfc9')]({'title':_0x25157b[_0xb3932d('0x52d')]?_0xb3932d('0x1e21')+_0x25157b[_0xb3932d('0x52d')]+_0xb3932d('0x11e1')+_0x25157b[_0xb3932d('0xe1b')]:'api.intSalesforceAccount.update','msg':_0x25157b[_0xb3932d('0x25f4')]?JSON[_0xb3932d('0xbac')](_0x25157b['data']['message']):_0x25157b[_0xb3932d('0x1586')]()});});}function _0x4f5523(_0x13c6b9){const _0x41f4cd=_0x28ebf6;_0x1d7c3a[_0x41f4cd('0x61a')]=[];const _0x977d=_0x1cf67f[_0x41f4cd('0x1d26')]()[_0x41f4cd('0xcdc')](_0x41f4cd('0x7fb'))['content']('The\x20salesforceAccount\x20will\x20be\x20deleted.')[_0x41f4cd('0x8e8')]('Delete\x20SalesforceAccount')['ok'](_0x41f4cd('0x18'))[_0x41f4cd('0x3f')](_0x41f4cd('0x497'))['targetEvent'](_0x13c6b9);_0x1cf67f[_0x41f4cd('0x1f80')](_0x977d)['then'](function(){const _0x195e41=_0x41f4cd;_0x249c14['intSalesforceAccount'][_0x195e41('0x906')]({'id':_0x1d7c3a['salesforceAccount']['id']})[_0x195e41('0xa44')][_0x195e41('0x1166')](function(){const _0x3965ac=_0x195e41;_0x2cfb05()['remove'](_0x1d7c3a[_0x3965ac('0x10a8')],{'id':_0x1d7c3a['salesforceAccount']['id']}),_0x591bc6['success']({'title':_0x3965ac('0xe02'),'msg':(_0x1d7c3a[_0x3965ac('0x2330')]['name']||_0x3965ac('0x2330'))+_0x3965ac('0x7cd')}),_0x51be6b(_0x1d7c3a[_0x3965ac('0x2330')]);})[_0x195e41('0x1a80')](function(_0x33f803){const _0x56a4db=_0x195e41;if(_0x33f803[_0x56a4db('0x25f4')]&&_0x33f803[_0x56a4db('0x25f4')][_0x56a4db('0x61a')]&&_0x33f803[_0x56a4db('0x25f4')]['errors'][_0x56a4db('0x264b')]){_0x1d7c3a['errors']=_0x33f803[_0x56a4db('0x25f4')]['errors']||[{'message':_0x33f803['toString'](),'type':_0x56a4db('0x20b6')}];for(let _0x428375=0x0;_0x428375<_0x33f803['data']['errors'][_0x56a4db('0x264b')];_0x428375++){_0x591bc6[_0x56a4db('0xfc9')]({'title':_0x33f803[_0x56a4db('0x25f4')][_0x56a4db('0x61a')][_0x428375][_0x56a4db('0x1345')],'msg':_0x33f803[_0x56a4db('0x25f4')][_0x56a4db('0x61a')][_0x428375][_0x56a4db('0x1e70')]});}}else _0x591bc6[_0x56a4db('0xfc9')]({'title':_0x33f803[_0x56a4db('0x52d')]?_0x56a4db('0x1e21')+_0x33f803[_0x56a4db('0x52d')]+'\x20-\x20'+_0x33f803[_0x56a4db('0xe1b')]:_0x56a4db('0x20b6'),'msg':_0x33f803[_0x56a4db('0x25f4')]?JSON['stringify'](_0x33f803[_0x56a4db('0x25f4')][_0x56a4db('0x1e70')]):_0x33f803[_0x56a4db('0x1e70')]||_0x33f803[_0x56a4db('0x1586')]()});});},function(){});}function _0x44fdd7(_0x5ac539){return _0x5ac539===null?undefined:new Date(_0x5ac539);}function _0x51be6b(_0x403344){const _0x4064f8=_0x28ebf6;_0x1cf67f[_0x4064f8('0x1197')](_0x403344);}}const _0x2465cd=_0x3860b9,_0x32eb57=_0x2734b2['p']+_0x36e6f4('0x1ac8'),_0x19887d=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/salesforceAccounts/edit/item/dialog.html/dialog.html';_0x3c7cd2[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x19e3'),'toasty',_0x36e6f4('0x21ef')];function _0x3c7cd2(_0xbba725,_0x3574e1,_0x59eab6,_0x68fe95,_0xdd7ddb){const _0x11fd62=_0x36e6f4,_0x586fa8=this;_0x586fa8[_0x11fd62('0x98')]=_0xdd7ddb[_0x11fd62('0x26cd')](),_0x586fa8[_0x11fd62('0x2330')]={},_0x586fa8[_0x11fd62('0x152d')]={},_0x586fa8[_0x11fd62('0xd54')]=[],_0x586fa8[_0x11fd62('0x27ae')]=-0x1,_0x586fa8[_0x11fd62('0x243c')],_0x586fa8[_0x11fd62('0x24d5')]=_0x299431,_0x586fa8[_0x11fd62('0x29f')]=_0x3175fb,_0x586fa8[_0x11fd62('0x2849')]=_0x3ff55b,_0x586fa8['deleteSalesforceConfiguration']=_0xe6c094,_0x586fa8['selectChangedAdvanced']=_0x5052e4;function _0x5052e4(){const _0x49050f=_0x11fd62;return _0x59eab6[_0x49050f('0xf04')][_0x49050f('0x1449')]({'id':_0x586fa8['salesforceConfiguration']['id']},_0x586fa8[_0x49050f('0x152d')])['$promise']['then'](function(){const _0x2d49a=_0x49050f;_0x68fe95[_0x2d49a('0x103b')]({'title':_0x2d49a('0x196b'),'msg':_0x2d49a('0x1b82')});})['catch'](function(_0x15b976){const _0x309dc8=_0x49050f;_0x68fe95[_0x309dc8('0xfc9')]({'title':_0x15b976[_0x309dc8('0x52d')]?_0x309dc8('0x1e21')+_0x15b976['status']+'\x20-\x20'+_0x15b976[_0x309dc8('0xe1b')]:_0x309dc8('0x6fc'),'msg':_0x15b976[_0x309dc8('0x25f4')]?JSON[_0x309dc8('0xbac')](_0x15b976[_0x309dc8('0x25f4')]):_0x15b976[_0x309dc8('0x1586')]()});});}function _0x299431(_0x3f63e1,_0x20de3f){const _0x16a6ff=_0x11fd62;_0x586fa8[_0x16a6ff('0x2330')]=_0x3f63e1,_0x586fa8['crudPermissions']=typeof _0x20de3f!==_0x16a6ff('0x1048')?_0x20de3f:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x59eab6[_0x16a6ff('0x164')][_0x16a6ff('0x13db')]({'id':_0x586fa8[_0x16a6ff('0x2330')]['id'],'sort':_0x16a6ff('0x14dc')})['$promise'][_0x16a6ff('0x1166')](function(_0x203789){const _0x154d54=_0x16a6ff;return _0x586fa8[_0x154d54('0xd54')]=_0x203789[_0x154d54('0x269a')]?_0x203789[_0x154d54('0x269a')]:[],_0x586fa8['configurations'][_0x154d54('0x264b')]&&_0x586fa8[_0x154d54('0x29f')](0x0),_0x59eab6['variable'][_0x154d54('0xd83')]({'nolimit':!![],'sort':'name'})[_0x154d54('0xa44')];})['then'](function(_0x4cb388){const _0x41a125=_0x16a6ff;_0x586fa8[_0x41a125('0x57a')]=_0x4cb388[_0x41a125('0x269a')]?_0x4cb388[_0x41a125('0x269a')]:[],_0x586fa8['variablesById']=_0x2cfb05()['keyBy'](_0x586fa8[_0x41a125('0x57a')],'id');})['catch'](function(_0x1f2fd3){const _0x63c03f=_0x16a6ff;_0x68fe95[_0x63c03f('0xfc9')]({'title':_0x1f2fd3[_0x63c03f('0x52d')]?_0x63c03f('0x1e21')+_0x1f2fd3['status']+_0x63c03f('0x11e1')+_0x1f2fd3[_0x63c03f('0xe1b')]:_0x63c03f('0x17ab'),'msg':_0x1f2fd3[_0x63c03f('0x25f4')]?JSON[_0x63c03f('0xbac')](_0x1f2fd3[_0x63c03f('0x25f4')]):_0x1f2fd3['toString']()});});}function _0x3175fb(_0x89b755){const _0x2be483=_0x11fd62;_0x586fa8[_0x2be483('0x152d')]=_0x586fa8[_0x2be483('0xd54')][_0x89b755],_0x586fa8['selectedSalesforceConfiguration']=_0x89b755,_0x59eab6['intSalesforceConfiguration'][_0x2be483('0x154d')]({'id':_0x586fa8[_0x2be483('0x152d')]['id']})['$promise'][_0x2be483('0x1166')](function(_0x50d7af){const _0x13f1b6=_0x2be483;return _0x586fa8[_0x13f1b6('0x2701')]=_0x50d7af[_0x13f1b6('0x269a')]?_0x50d7af['rows']:[],_0x59eab6['intSalesforceConfiguration'][_0x13f1b6('0x28d4')]({'id':_0x586fa8[_0x13f1b6('0x152d')]['id']})[_0x13f1b6('0xa44')];})[_0x2be483('0x1166')](function(_0x290180){const _0x2b4b95=_0x2be483;return _0x586fa8[_0x2b4b95('0x1b3d')]=_0x290180['rows']?_0x290180[_0x2b4b95('0x269a')]:[],_0x59eab6['intSalesforceConfiguration'][_0x2b4b95('0x18ea')]({'id':_0x586fa8['salesforceConfiguration']['id']})['$promise'];})[_0x2be483('0x1166')](function(_0x1dd026){const _0x296721=_0x2be483;_0x586fa8[_0x296721('0xfe2')]=_0x1dd026[_0x296721('0x269a')]?_0x1dd026[_0x296721('0x269a')]:[];})['catch'](function(_0x21423e){const _0x195157=_0x2be483;_0x68fe95[_0x195157('0xfc9')]({'title':_0x21423e['status']?_0x195157('0x1e21')+_0x21423e[_0x195157('0x52d')]+'\x20-\x20'+_0x21423e['statusText']:_0x195157('0x16c7'),'msg':_0x21423e[_0x195157('0x25f4')]?JSON[_0x195157('0xbac')](_0x21423e[_0x195157('0x25f4')]):_0x21423e['toString']()});});}function _0x3ff55b(_0x1bec48,_0x4afc8b){const _0x3b47e9=_0x11fd62;_0xbba725[_0x3b47e9('0x1f80')]({'controller':'CreateOrEditSalesforceConfigurationDialogController','controllerAs':'vm','templateUrl':_0x32eb57,'parent':angular[_0x3b47e9('0x1194')](_0x3574e1['body']),'targetEvent':_0x1bec48,'clickOutsideToClose':!![],'locals':{'salesforceConfiguration':_0x4afc8b,'configurations':_0x586fa8[_0x3b47e9('0xd54')],'license':null,'setting':null,'crudPermissions':_0x586fa8[_0x3b47e9('0x243c')]}})[_0x3b47e9('0x1951')](function(){const _0x2f6844=_0x3b47e9;_0x586fa8[_0x2f6844('0x29f')](0x0);});}function _0xe6c094(_0x1cb910,_0x291c85){const _0x3f8fe0=_0x11fd62,_0x163648=_0xbba725['confirm']()[_0x3f8fe0('0xcdc')](_0x3f8fe0('0x2571'))[_0x3f8fe0('0xf3c')](_0x3f8fe0('0x12b5')+(_0x291c85[_0x3f8fe0('0x4f0')]||_0x3f8fe0('0x152d'))+_0x3f8fe0('0xace')+_0x3f8fe0('0x3f3'))['ariaLabel'](_0x3f8fe0('0xb79'))[_0x3f8fe0('0x203b')](_0x1cb910)['ok']('OK')['cancel'](_0x3f8fe0('0x2d3'));_0xbba725['show'](_0x163648)[_0x3f8fe0('0x1166')](function(){const _0x2d4d67=_0x3f8fe0;_0x59eab6[_0x2d4d67('0xf04')][_0x2d4d67('0x906')]({'id':_0x291c85['id']})['$promise']['then'](function(){const _0x44b623=_0x2d4d67;_0x2cfb05()[_0x44b623('0x127f')](_0x586fa8[_0x44b623('0xd54')],{'id':_0x291c85['id']}),_0x68fe95['success']({'title':_0x44b623('0x25b2'),'msg':_0x291c85['name']?_0x291c85[_0x44b623('0x4f0')]+_0x44b623('0x7cd'):''});})[_0x2d4d67('0x1a80')](function(_0x238f25){const _0x25dde8=_0x2d4d67;_0x68fe95['error']({'title':_0x238f25[_0x25dde8('0x52d')]?_0x25dde8('0x1e21')+_0x238f25[_0x25dde8('0x52d')]+'\x20-\x20'+_0x238f25[_0x25dde8('0xe1b')]:_0x25dde8('0x19a8'),'msg':_0x238f25[_0x25dde8('0x25f4')]?JSON[_0x25dde8('0xbac')](_0x238f25[_0x25dde8('0x25f4')]):_0x238f25[_0x25dde8('0x1586')]()});})['finally'](function(){const _0x2bee7a=_0x2d4d67;_0x586fa8[_0x2bee7a('0x29f')](0x0);});},function(){const _0x580733=_0x3f8fe0;console[_0x580733('0x455')](_0x580733('0x2d3'));});}_0x586fa8[_0x11fd62('0xd02')]=[],_0x586fa8['createOrEditSubject']=_0x219cf8,_0x586fa8['deleteSubjectConfirm']=_0x47fb7b,_0x586fa8[_0x11fd62('0xeff')]=_0x211de5;function _0x219cf8(_0x397757,_0xd4503c){const _0x390605=_0x11fd62;_0xbba725['show']({'controller':_0x390605('0x21ec'),'controllerAs':'vm','templateUrl':_0x19887d,'parent':angular['element'](_0x3574e1['body']),'targetEvent':_0x397757,'clickOutsideToClose':!![],'locals':{'type':_0x390605('0x210d'),'item':_0xd4503c,'items':_0x586fa8[_0x390605('0x2701')],'configuration':_0x586fa8['salesforceConfiguration'],'account':_0x586fa8[_0x390605('0x2330')],'license':null,'setting':null,'crudPermissions':_0x586fa8['crudPermissions']}});}function _0x58f9cb(_0x58ba5b){const _0x36b7e3=_0x11fd62;_0x59eab6[_0x36b7e3('0x18fb')]['delete']({'id':_0x58ba5b['id']})['$promise']['then'](function(){const _0x534f4e=_0x36b7e3;_0x2cfb05()[_0x534f4e('0x127f')](_0x586fa8[_0x534f4e('0x2701')],{'id':_0x58ba5b['id']}),_0x68fe95[_0x534f4e('0x103b')]({'title':'Subject\x20deleted!','msg':_0x534f4e('0x259f')});})[_0x36b7e3('0x1a80')](function(_0x3f0d21){const _0x4f2a37=_0x36b7e3;_0x68fe95[_0x4f2a37('0xfc9')]({'title':_0x3f0d21[_0x4f2a37('0x52d')]?'API:'+_0x3f0d21['status']+_0x4f2a37('0x11e1')+_0x3f0d21[_0x4f2a37('0xe1b')]:_0x4f2a37('0x23ff'),'msg':_0x3f0d21['data']?JSON['stringify'](_0x3f0d21[_0x4f2a37('0x25f4')]):_0x3f0d21[_0x4f2a37('0x1586')]()});});}function _0x47fb7b(_0x4cd1f5,_0x5a925d){const _0xcd3746=_0x11fd62,_0x266b32=_0xbba725[_0xcd3746('0x1d26')]()[_0xcd3746('0xcdc')](_0xcd3746('0x11c8'))['htmlContent'](_0xcd3746('0x277a')+_0xcd3746('0x3f3'))['ariaLabel'](_0xcd3746('0x87a'))[_0xcd3746('0x203b')](_0x4cd1f5)['ok']('OK')['cancel']('CANCEL');_0xbba725[_0xcd3746('0x1f80')](_0x266b32)[_0xcd3746('0x1166')](function(){_0x58f9cb(_0x5a925d);},function(){const _0xe4cd04=_0xcd3746;console['log'](_0xe4cd04('0x2d3'));});}function _0x211de5(_0x34184b){const _0x3d335a=_0x11fd62,_0x320fc5=_0xbba725[_0x3d335a('0x1d26')]()[_0x3d335a('0xcdc')](_0x3d335a('0x1d64'))[_0x3d335a('0xf3c')](_0x3d335a('0x12b5')+_0x586fa8[_0x3d335a('0xd02')][_0x3d335a('0x264b')]+_0x3d335a('0x196d')+'\x20will\x20be\x20deleted.')[_0x3d335a('0x8e8')](_0x3d335a('0x5b2'))[_0x3d335a('0x203b')](_0x34184b)['ok']('OK')[_0x3d335a('0x3f')](_0x3d335a('0x2d3'));_0xbba725[_0x3d335a('0x1f80')](_0x320fc5)[_0x3d335a('0x1166')](function(){const _0x3e78e1=_0x3d335a;_0x586fa8['selectedSubjects'][_0x3e78e1('0x2782')](function(_0x28594f){_0x58f9cb(_0x28594f);}),_0x586fa8['selectedSubjects']=[];});}_0x586fa8[_0x11fd62('0x968')]=[],_0x586fa8[_0x11fd62('0x2185')]=_0xa2741a,_0x586fa8[_0x11fd62('0xdf3')]=_0x84be65,_0x586fa8[_0x11fd62('0x2269')]=_0x3021de;function _0xa2741a(_0x16f4f5,_0x4a49e9){const _0x470317=_0x11fd62;_0xbba725[_0x470317('0x1f80')]({'controller':_0x470317('0x21ec'),'controllerAs':'vm','templateUrl':_0x19887d,'parent':angular[_0x470317('0x1194')](_0x3574e1[_0x470317('0x8d2')]),'targetEvent':_0x16f4f5,'clickOutsideToClose':!![],'locals':{'type':_0x470317('0x101c'),'item':_0x4a49e9,'items':_0x586fa8['descriptions'],'configuration':_0x586fa8[_0x470317('0x152d')],'account':_0x586fa8[_0x470317('0x2330')],'license':null,'setting':null,'crudPermissions':_0x586fa8[_0x470317('0x243c')]}});}function _0x3316de(_0xc03565){const _0xaad24=_0x11fd62;_0x59eab6[_0xaad24('0x18fb')]['delete']({'id':_0xc03565['id']})['$promise'][_0xaad24('0x1166')](function(){const _0x5182df=_0xaad24;_0x2cfb05()[_0x5182df('0x127f')](_0x586fa8[_0x5182df('0x1b3d')],{'id':_0xc03565['id']}),_0x68fe95[_0x5182df('0x103b')]({'title':_0x5182df('0x9c1'),'msg':_0x5182df('0x12ae')});})[_0xaad24('0x1a80')](function(_0x55f741){const _0x2da941=_0xaad24;_0x68fe95[_0x2da941('0xfc9')]({'title':_0x55f741[_0x2da941('0x52d')]?'API:'+_0x55f741['status']+_0x2da941('0x11e1')+_0x55f741[_0x2da941('0xe1b')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x55f741['data']?JSON[_0x2da941('0xbac')](_0x55f741['data']):_0x55f741[_0x2da941('0x1586')]()});});}function _0x84be65(_0x4f15f6,_0x277381){const _0x42551c=_0x11fd62,_0x5ed314=_0xbba725[_0x42551c('0x1d26')]()[_0x42551c('0xcdc')](_0x42551c('0x1baa'))[_0x42551c('0xf3c')](_0x42551c('0x1809')+_0x42551c('0x3f3'))[_0x42551c('0x8e8')](_0x42551c('0x1bc0'))['targetEvent'](_0x4f15f6)['ok']('OK')[_0x42551c('0x3f')](_0x42551c('0x2d3'));_0xbba725[_0x42551c('0x1f80')](_0x5ed314)[_0x42551c('0x1166')](function(){_0x3316de(_0x277381);},function(){const _0x167423=_0x42551c;console[_0x167423('0x455')](_0x167423('0x2d3'));});}function _0x3021de(_0x30e83f){const _0x209549=_0x11fd62,_0x2933c1=_0xbba725[_0x209549('0x1d26')]()[_0x209549('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20descriptions?')[_0x209549('0xf3c')](''+_0x586fa8[_0x209549('0x968')][_0x209549('0x264b')]+_0x209549('0x196d')+_0x209549('0x3f3'))[_0x209549('0x8e8')](_0x209549('0x17a'))[_0x209549('0x203b')](_0x30e83f)['ok']('OK')[_0x209549('0x3f')](_0x209549('0x2d3'));_0xbba725['show'](_0x2933c1)[_0x209549('0x1166')](function(){const _0x2e93b8=_0x209549;_0x586fa8['selectedDescriptions'][_0x2e93b8('0x2782')](function(_0x772a61){_0x3316de(_0x772a61);}),_0x586fa8['selectedDescriptions']=[];});}_0x586fa8[_0x11fd62('0x16')]=[],_0x586fa8[_0x11fd62('0x27ad')]=_0x1bb8bf,_0x586fa8['deleteFieldConfirm']=_0x230e82,_0x586fa8[_0x11fd62('0x1ace')]=_0x43759d;function _0x1bb8bf(_0x4b7129,_0x4dfa40){const _0x126d03=_0x11fd62;_0xbba725[_0x126d03('0x1f80')]({'controller':_0x126d03('0x21ec'),'controllerAs':'vm','templateUrl':_0x19887d,'parent':angular[_0x126d03('0x1194')](_0x3574e1['body']),'targetEvent':_0x4b7129,'clickOutsideToClose':!![],'locals':{'type':'field','item':_0x4dfa40,'items':_0x586fa8[_0x126d03('0xfe2')],'configuration':_0x586fa8[_0x126d03('0x152d')],'account':_0x586fa8[_0x126d03('0x2330')],'license':null,'setting':null,'crudPermissions':_0x586fa8['crudPermissions']}});}function _0x257737(_0x3f1df5){const _0x344916=_0x11fd62;_0x59eab6[_0x344916('0x18fb')][_0x344916('0x906')]({'id':_0x3f1df5['id']})[_0x344916('0xa44')][_0x344916('0x1166')](function(){const _0x26a113=_0x344916;_0x2cfb05()['remove'](_0x586fa8['fields'],{'id':_0x3f1df5['id']}),_0x68fe95[_0x26a113('0x103b')]({'title':_0x26a113('0x13cb'),'msg':_0x26a113('0x31e')});})[_0x344916('0x1a80')](function(_0x5a5c8c){const _0x28e7c4=_0x344916;_0x68fe95[_0x28e7c4('0xfc9')]({'title':_0x5a5c8c[_0x28e7c4('0x52d')]?_0x28e7c4('0x1e21')+_0x5a5c8c[_0x28e7c4('0x52d')]+_0x28e7c4('0x11e1')+_0x5a5c8c['statusText']:_0x28e7c4('0x23ff'),'msg':_0x5a5c8c[_0x28e7c4('0x25f4')]?JSON[_0x28e7c4('0xbac')](_0x5a5c8c[_0x28e7c4('0x25f4')]):_0x5a5c8c[_0x28e7c4('0x1586')]()});});}function _0x230e82(_0xfdb02,_0xe8f6a2){const _0x26277e=_0x11fd62,_0x2b5ac6=_0xbba725[_0x26277e('0x1d26')]()[_0x26277e('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x26277e('0xf3c')](_0x26277e('0x13e0')+_0x26277e('0x3f3'))['ariaLabel']('delete\x20field')[_0x26277e('0x203b')](_0xfdb02)['ok']('OK')[_0x26277e('0x3f')](_0x26277e('0x2d3'));_0xbba725['show'](_0x2b5ac6)['then'](function(){_0x257737(_0xe8f6a2);},function(){const _0x1c841f=_0x26277e;console[_0x1c841f('0x455')]('CANCEL');});}function _0x43759d(_0x34b497){const _0x2040e7=_0x11fd62,_0x534905=_0xbba725['confirm']()[_0x2040e7('0xcdc')](_0x2040e7('0x1d42'))[_0x2040e7('0xf3c')](_0x2040e7('0x12b5')+_0x586fa8[_0x2040e7('0x16')][_0x2040e7('0x264b')]+_0x2040e7('0x196d')+_0x2040e7('0x3f3'))[_0x2040e7('0x8e8')](_0x2040e7('0x219a'))['targetEvent'](_0x34b497)['ok']('OK')[_0x2040e7('0x3f')](_0x2040e7('0x2d3'));_0xbba725[_0x2040e7('0x1f80')](_0x534905)[_0x2040e7('0x1166')](function(){const _0x2f368c=_0x2040e7;_0x586fa8[_0x2f368c('0x16')]['forEach'](function(_0x55bb91){_0x257737(_0x55bb91);}),_0x586fa8[_0x2f368c('0x16')]=[];});}}const _0x5046be=_0x3c7cd2;_0x1601b0['$inject']=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'configurations','salesforceConfiguration',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x1601b0(_0x16ca23,_0x31ccec,_0x22cb33,_0x5c028d,_0x44e59d,_0x179d7f,_0x16127e,_0x2a90e9,_0x572910,_0x29db89,_0x2dec66,_0x509141,_0x1e893e,_0x4812d0){const _0x4039d3=_0x36e6f4,_0x2f3861=this;_0x2f3861[_0x4039d3('0x98')]=_0x2dec66['getCurrentUser'](),_0x2f3861[_0x4039d3('0x61a')]=[],_0x2f3861['setting']=_0x1e893e,_0x2f3861[_0x4039d3('0x5c9')]=_0x509141,_0x2f3861[_0x4039d3('0x243c')]=_0x4812d0,_0x2f3861[_0x4039d3('0x128b')]={},_0x2f3861[_0x4039d3('0x2900')]=_0x2f3861['setting']&&_0x2f3861[_0x4039d3('0xf8a')][_0x4039d3('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2f3861[_0x4039d3('0xcdc')]='INTEGRATIONS.EDIT_SALESFORCECONFIGURATION',_0x2f3861['salesforceConfiguration']=angular['copy'](_0x572910),_0x2f3861[_0x4039d3('0xd54')]=_0x2a90e9,_0x2f3861[_0x4039d3('0x190d')]=![];!_0x2f3861['salesforceConfiguration']&&(_0x2f3861[_0x4039d3('0x152d')]={'channel':_0x4039d3('0x21da'),'type':'inbound','ticketType':_0x4039d3('0x285c')},_0x2f3861[_0x4039d3('0xcdc')]=_0x4039d3('0x156a'),_0x2f3861[_0x4039d3('0x190d')]=!![]);_0x2f3861[_0x4039d3('0x1496')]=_0x2689f3,_0x2f3861[_0x4039d3('0xdbc')]=_0x353dc7,_0x2f3861[_0x4039d3('0x1cbc')]=_0x598ae8,_0x2f3861[_0x4039d3('0x1a9c')]=_0x40f41f,_0x2f3861[_0x4039d3('0x24a0')]=_0x3f7c49;function _0x2689f3(){const _0x5d46ad=_0x4039d3;_0x2f3861[_0x5d46ad('0x61a')]=[],_0x29db89[_0x5d46ad('0x164')][_0x5d46ad('0x274a')]({'id':_0x31ccec[_0x5d46ad('0x23f')]['id']},_0x2f3861[_0x5d46ad('0x152d')])['$promise'][_0x5d46ad('0x1166')](function(_0x263a01){const _0x30eb25=_0x5d46ad;_0x2f3861[_0x30eb25('0xd54')]['unshift'](_0x263a01[_0x30eb25('0x2876')]()),_0x16127e[_0x30eb25('0x103b')]({'title':_0x30eb25('0x1f4a'),'msg':_0x2f3861[_0x30eb25('0x152d')]['name']?_0x2f3861[_0x30eb25('0x152d')]['name']+'\x20has\x20been\x20created!':''}),_0x3f7c49(_0x263a01);})[_0x5d46ad('0x1a80')](function(_0x89a038){const _0x31a0e5=_0x5d46ad;if(_0x89a038['data']&&_0x89a038['data'][_0x31a0e5('0x61a')]&&_0x89a038[_0x31a0e5('0x25f4')]['errors'][_0x31a0e5('0x264b')]){_0x2f3861[_0x31a0e5('0x61a')]=_0x89a038[_0x31a0e5('0x25f4')][_0x31a0e5('0x61a')]||[{'message':_0x89a038['toString'](),'type':_0x31a0e5('0x237d')}];for(let _0x18a716=0x0;_0x18a716<_0x89a038['data'][_0x31a0e5('0x61a')][_0x31a0e5('0x264b')];_0x18a716+=0x1){_0x16127e[_0x31a0e5('0xfc9')]({'title':_0x89a038['data']['errors'][_0x18a716]['type'],'msg':_0x89a038[_0x31a0e5('0x25f4')][_0x31a0e5('0x61a')][_0x18a716][_0x31a0e5('0x1e70')]});}}else _0x16127e['error']({'title':_0x89a038[_0x31a0e5('0x52d')]?'API:'+_0x89a038[_0x31a0e5('0x52d')]+_0x31a0e5('0x11e1')+_0x89a038[_0x31a0e5('0xe1b')]:'api.intSalesforceConfiguration.save','msg':_0x89a038[_0x31a0e5('0x25f4')]?JSON[_0x31a0e5('0xbac')](_0x89a038[_0x31a0e5('0x25f4')][_0x31a0e5('0x1e70')]):_0x89a038[_0x31a0e5('0x1586')]()});});}function _0x353dc7(){const _0x53c257=_0x4039d3;_0x2f3861[_0x53c257('0x61a')]=[],_0x29db89[_0x53c257('0xf04')][_0x53c257('0x1449')]({'id':_0x2f3861[_0x53c257('0x152d')]['id']},_0x2f3861['salesforceConfiguration'])[_0x53c257('0xa44')][_0x53c257('0x1166')](function(_0x4916f4){const _0x1fc37d=_0x53c257,_0x49c0aa=_0x2cfb05()[_0x1fc37d('0xc38')](_0x2f3861[_0x1fc37d('0xd54')],{'id':_0x4916f4['id']});_0x49c0aa&&_0x2cfb05()[_0x1fc37d('0xcc3')](_0x49c0aa,_0x2cfb05()[_0x1fc37d('0x1a08')](_0x4916f4[_0x1fc37d('0x2876')](),_0x2cfb05()[_0x1fc37d('0x14a4')](_0x49c0aa))),_0x16127e[_0x1fc37d('0x103b')]({'title':_0x1fc37d('0x1784'),'msg':_0x2f3861[_0x1fc37d('0x152d')]['name']?_0x2f3861[_0x1fc37d('0x152d')][_0x1fc37d('0x4f0')]+_0x1fc37d('0x7d'):''}),_0x3f7c49(_0x4916f4);})[_0x53c257('0x1a80')](function(_0x40f928){const _0x2e5a89=_0x53c257;if(_0x40f928[_0x2e5a89('0x25f4')]&&_0x40f928[_0x2e5a89('0x25f4')][_0x2e5a89('0x61a')]&&_0x40f928[_0x2e5a89('0x25f4')]['errors'][_0x2e5a89('0x264b')]){_0x2f3861[_0x2e5a89('0x61a')]=_0x40f928[_0x2e5a89('0x25f4')][_0x2e5a89('0x61a')]||[{'message':_0x40f928[_0x2e5a89('0x1586')](),'type':_0x2e5a89('0x22ab')}];for(let _0x3ba837=0x0;_0x3ba837<_0x40f928['data'][_0x2e5a89('0x61a')]['length'];_0x3ba837++){_0x16127e['error']({'title':_0x40f928['data'][_0x2e5a89('0x61a')][_0x3ba837]['type'],'msg':_0x40f928['data']['errors'][_0x3ba837][_0x2e5a89('0x1e70')]});}}else _0x16127e[_0x2e5a89('0xfc9')]({'title':_0x40f928[_0x2e5a89('0x52d')]?_0x2e5a89('0x1e21')+_0x40f928[_0x2e5a89('0x52d')]+_0x2e5a89('0x11e1')+_0x40f928['statusText']:_0x2e5a89('0x22ab'),'msg':_0x40f928[_0x2e5a89('0x25f4')]?JSON[_0x2e5a89('0xbac')](_0x40f928[_0x2e5a89('0x25f4')][_0x2e5a89('0x1e70')]):_0x40f928[_0x2e5a89('0x1586')]()});});}function _0x598ae8(_0x4eb10b){const _0x1fe0b0=_0x4039d3;_0x2f3861[_0x1fe0b0('0x61a')]=[];const _0xf76b1d=_0x5c028d[_0x1fe0b0('0x1d26')]()[_0x1fe0b0('0xcdc')]('Are\x20you\x20sure?')['content']('The\x20salesforceConfiguration\x20will\x20be\x20deleted.')[_0x1fe0b0('0x8e8')](_0x1fe0b0('0x18f7'))['ok']('Delete')[_0x1fe0b0('0x3f')](_0x1fe0b0('0x497'))[_0x1fe0b0('0x203b')](_0x4eb10b);_0x5c028d[_0x1fe0b0('0x1f80')](_0xf76b1d)[_0x1fe0b0('0x1166')](function(){const _0xecea7b=_0x1fe0b0;_0x29db89[_0xecea7b('0xf04')]['delete']({'id':_0x2f3861[_0xecea7b('0x152d')]['id']})[_0xecea7b('0xa44')][_0xecea7b('0x1166')](function(){const _0x86d48b=_0xecea7b;_0x2cfb05()[_0x86d48b('0x127f')](_0x2f3861[_0x86d48b('0xd54')],{'id':_0x2f3861[_0x86d48b('0x152d')]['id']}),_0x16127e['success']({'title':_0x86d48b('0x27a'),'msg':(_0x2f3861['salesforceConfiguration'][_0x86d48b('0x4f0')]||_0x86d48b('0x152d'))+_0x86d48b('0x7cd')}),_0x3f7c49(_0x2f3861[_0x86d48b('0x152d')]);})['catch'](function(_0x4119aa){const _0x36fe43=_0xecea7b;if(_0x4119aa[_0x36fe43('0x25f4')]&&_0x4119aa['data'][_0x36fe43('0x61a')]&&_0x4119aa[_0x36fe43('0x25f4')][_0x36fe43('0x61a')]['length']){_0x2f3861[_0x36fe43('0x61a')]=_0x4119aa[_0x36fe43('0x25f4')]['errors']||[{'message':_0x4119aa[_0x36fe43('0x1586')](),'type':_0x36fe43('0x2282')}];for(let _0x169c8c=0x0;_0x169c8c<_0x4119aa[_0x36fe43('0x25f4')][_0x36fe43('0x61a')]['length'];_0x169c8c++){_0x16127e['error']({'title':_0x4119aa[_0x36fe43('0x25f4')][_0x36fe43('0x61a')][_0x169c8c]['type'],'msg':_0x4119aa['data'][_0x36fe43('0x61a')][_0x169c8c][_0x36fe43('0x1e70')]});}}else _0x16127e[_0x36fe43('0xfc9')]({'title':_0x4119aa['status']?_0x36fe43('0x1e21')+_0x4119aa[_0x36fe43('0x52d')]+_0x36fe43('0x11e1')+_0x4119aa['statusText']:_0x36fe43('0x2282'),'msg':_0x4119aa[_0x36fe43('0x25f4')]?JSON[_0x36fe43('0xbac')](_0x4119aa[_0x36fe43('0x25f4')]['message']):_0x4119aa[_0x36fe43('0x1e70')]||_0x4119aa[_0x36fe43('0x1586')]()});});},function(){});}function _0x40f41f(_0x3dd703){return _0x3dd703===null?undefined:new Date(_0x3dd703);}function _0x3f7c49(_0x3e4ec3){_0x5c028d['hide'](_0x3e4ec3);}}const _0x359776=_0x1601b0;_0x18ff66[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xd29'),_0x36e6f4('0xbd7'),_0x36e6f4('0x1301'),_0x36e6f4('0x1a32'),'type',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x18ff66(_0xe3ae8a,_0x56e357,_0x504053,_0x50f170,_0x384bda,_0x413b76,_0x56b945,_0x2f4e1a,_0x2eed0a,_0x9c95ab,_0xfe4c82,_0x4c4656,_0x4e17e2){const _0x24f8e8=_0x36e6f4,_0x55128a=this;_0x55128a['currentUser']=_0x4c4656[_0x24f8e8('0x26cd')](),_0x55128a['errors']=[],_0x55128a[_0x24f8e8('0xcdc')]='INTEGRATIONS.EDIT_'+_0x2cfb05()[_0x24f8e8('0x113b')](_0x9c95ab),_0x55128a[_0x24f8e8('0x1301')]=angular[_0x24f8e8('0x225f')](_0x2f4e1a),_0x55128a[_0x24f8e8('0xbd7')]=_0x56b945,_0x55128a[_0x24f8e8('0x1345')]=_0x9c95ab,_0x55128a[_0x24f8e8('0x243c')]=_0x4e17e2,_0x55128a[_0x24f8e8('0x17c7')]=![];!_0x55128a['item']&&(_0x55128a['item']={'type':_0x24f8e8('0x102c')},_0x55128a[_0x24f8e8('0x1301')][_0x2cfb05()[_0x24f8e8('0x92c')](_0x9c95ab)+'Id']=_0x413b76['id'],_0x55128a[_0x24f8e8('0xcdc')]='INTEGRATIONS.NEW_'+_0x2cfb05()[_0x24f8e8('0x113b')](_0x9c95ab),_0x55128a[_0x24f8e8('0x17c7')]=!![]);_0x55128a['addNewItem']=_0x1830d4,_0x55128a[_0x24f8e8('0x13b8')]=_0x1fd102,_0x55128a[_0x24f8e8('0x18d3')]=_0x26d3b2,_0x55128a[_0x24f8e8('0x1551')]=_0x44e9b1,_0x55128a['closeDialog']=_0x1c5d13,_0xfe4c82['variable'][_0x24f8e8('0xd83')]({'nolimit':!![]})['$promise'][_0x24f8e8('0x1166')](function(_0x2801cf){const _0xbe1138=_0x24f8e8;return _0x55128a['variables']=_0x2801cf['rows']?_0x2801cf[_0xbe1138('0x269a')]:[],_0xfe4c82[_0xbe1138('0x7af')][_0xbe1138('0x23d0')]()[_0xbe1138('0xa44')];})['then'](function(_0x3eb8fc){const _0x4d2a7d=_0x24f8e8;return _0x55128a[_0x4d2a7d('0x1d45')]=_0x2cfb05()[_0x4d2a7d('0x13ca')](_0x2cfb05()[_0x4d2a7d('0x14a4')](_0x3eb8fc),['$promise',_0x4d2a7d('0xfcd'),'createdAt',_0x4d2a7d('0x6f9'),_0x4d2a7d('0x978')]),_0x55128a[_0x4d2a7d('0x1d45')]['push']('recordingURL'),_0xfe4c82[_0x4d2a7d('0x21f9')][_0x4d2a7d('0x23d0')]()['$promise'];})[_0x24f8e8('0x1166')](function(_0x28bb1f){const _0x4f373f=_0x24f8e8;_0x55128a[_0x4f373f('0x1348')]=_0x2cfb05()[_0x4f373f('0x13ca')](_0x2cfb05()[_0x4f373f('0x14a4')](_0x28bb1f),['$promise',_0x4f373f('0xfcd'),_0x4f373f('0x262'),_0x4f373f('0x6f9'),_0x4f373f('0x978')]),_0x55128a[_0x4f373f('0x1348')][_0x4f373f('0x1514')](_0x4f373f('0xa29'));})['catch'](function(_0xb326da){const _0x22b218=_0x24f8e8;_0x384bda[_0x22b218('0xfc9')]({'title':_0xb326da[_0x22b218('0x52d')]?_0x22b218('0x1e21')+_0xb326da[_0x22b218('0x52d')]+_0x22b218('0x11e1')+_0xb326da['statusText']:_0x22b218('0xfe5'),'msg':_0xb326da[_0x22b218('0x25f4')]?JSON[_0x22b218('0xbac')](_0xb326da[_0x22b218('0x25f4')]):_0xb326da['toString']()});}),_0xfe4c82[_0x24f8e8('0x164')][_0x24f8e8('0x18ea')]({'id':_0x2eed0a['id'],'ticketType':_0x413b76[_0x24f8e8('0x11ba')]?_0x413b76['ticketType']:undefined})['$promise'][_0x24f8e8('0x1166')](function(_0xa2a05b){const _0x2bd20d=_0x24f8e8;_0x55128a[_0x2bd20d('0x606')]=!![],_0x55128a[_0x2bd20d('0xfe2')]=_0xa2a05b[_0x2bd20d('0x269a')]?_0xa2a05b['rows']:[],_0x55128a[_0x2bd20d('0x1301')][_0x2bd20d('0x1143')]&&(_0x55128a['customField']=_0x2cfb05()[_0x2bd20d('0xc38')](_0x55128a[_0x2bd20d('0xfe2')],{'id':_0x55128a[_0x2bd20d('0x1301')][_0x2bd20d('0x1143')]}));})['catch'](function(_0xc9a0ec){const _0x188e50=_0x24f8e8;_0x55128a[_0x188e50('0x606')]=![],console[_0x188e50('0xfc9')](_0xc9a0ec);});function _0x1830d4(){const _0x171b61=_0x24f8e8;_0x55128a[_0x171b61('0x61a')]=[],_0x55128a[_0x171b61('0x117e')]&&(_0x55128a[_0x171b61('0x1301')][_0x171b61('0x1143')]=_0x55128a[_0x171b61('0x117e')]['id'],_0x55128a[_0x171b61('0x1301')]['nameField']=_0x55128a[_0x171b61('0x117e')][_0x171b61('0x4f0')],_0x55128a['item']['customField']=_0x55128a[_0x171b61('0x117e')][_0x171b61('0x2853')]),_0xfe4c82[_0x171b61('0x18fb')]['save'](_0x55128a[_0x171b61('0x1301')])[_0x171b61('0xa44')][_0x171b61('0x1166')](function(_0x5780c5){const _0x4cedf3=_0x171b61;_0x55128a[_0x4cedf3('0xbd7')][_0x4cedf3('0x2450')](_0x5780c5),_0x384bda[_0x4cedf3('0x103b')]({'title':_0x2cfb05()[_0x4cedf3('0x92c')](_0x9c95ab)+_0x4cedf3('0x13f0'),'msg':_0x2cfb05()[_0x4cedf3('0x92c')](_0x9c95ab)+_0x4cedf3('0x1eda')}),_0x1c5d13();})['catch'](function(_0x5ccda4){const _0x445e26=_0x171b61;console[_0x445e26('0xfc9')](_0x5ccda4),_0x55128a[_0x445e26('0x61a')]=_0x5ccda4['data'][_0x445e26('0x61a')]||[{'message':_0x5ccda4[_0x445e26('0x1586')](),'type':_0x445e26('0x215d')}];});}function _0x1fd102(){const _0x521780=_0x24f8e8;_0x55128a['errors']=[],_0x55128a[_0x521780('0x117e')]&&(_0x55128a[_0x521780('0x1301')][_0x521780('0x1143')]=_0x55128a['customField']['id'],_0x55128a['item'][_0x521780('0x3c0')]=_0x55128a[_0x521780('0x117e')][_0x521780('0x4f0')],_0x55128a[_0x521780('0x1301')]['customField']=_0x55128a['customField'][_0x521780('0x2853')]),_0xfe4c82[_0x521780('0x18fb')][_0x521780('0x1449')]({'id':_0x55128a[_0x521780('0x1301')]['id']},_0x55128a[_0x521780('0x1301')])[_0x521780('0xa44')][_0x521780('0x1166')](function(_0x10b683){const _0x5cb8c1=_0x521780,_0x4b764d=_0x2cfb05()[_0x5cb8c1('0xc38')](_0x55128a[_0x5cb8c1('0xbd7')],{'id':_0x10b683['id']});_0x4b764d&&_0x2cfb05()[_0x5cb8c1('0xcc3')](_0x4b764d,_0x10b683),_0x384bda[_0x5cb8c1('0x103b')]({'title':_0x2cfb05()[_0x5cb8c1('0x92c')](_0x9c95ab)+'\x20properly\x20saved!','msg':_0x2cfb05()[_0x5cb8c1('0x92c')](_0x9c95ab)+_0x5cb8c1('0x7d')}),_0x1c5d13();})[_0x521780('0x1a80')](function(_0x20d148){const _0x412617=_0x521780;console['error'](_0x20d148),_0x55128a[_0x412617('0x61a')]=_0x20d148[_0x412617('0x25f4')]['errors']||[{'message':_0x20d148['toString'](),'type':_0x412617('0x10cd')}];});}function _0x26d3b2(_0x1ce9c2){const _0xd2ebd7=_0x24f8e8;_0x55128a[_0xd2ebd7('0x61a')]=[];const _0xffd656=_0x50f170[_0xd2ebd7('0x1d26')]()[_0xd2ebd7('0xcdc')](_0xd2ebd7('0x7fb'))[_0xd2ebd7('0xacc')](_0xd2ebd7('0x135f')+_0x9c95ab+_0xd2ebd7('0x3f3'))[_0xd2ebd7('0x8e8')](_0xd2ebd7('0x237c')+_0x2cfb05()[_0xd2ebd7('0x92c')](_0x9c95ab))['ok']('Delete')[_0xd2ebd7('0x3f')](_0xd2ebd7('0x497'))[_0xd2ebd7('0x203b')](_0x1ce9c2);_0x50f170['show'](_0xffd656)[_0xd2ebd7('0x1166')](function(){const _0x3cd34b=_0xd2ebd7;_0xfe4c82[_0x3cd34b('0x18fb')][_0x3cd34b('0x906')]({'id':_0x55128a[_0x3cd34b('0x1301')]['id']})['$promise']['then'](function(){const _0x17e2fb=_0x3cd34b;_0x2cfb05()[_0x17e2fb('0x127f')](_0x55128a[_0x17e2fb('0xbd7')],{'id':_0x55128a['item']['id']}),_0x384bda['success']({'title':_0x2cfb05()['capitalize'](_0x9c95ab)+_0x17e2fb('0x450'),'msg':_0x2cfb05()[_0x17e2fb('0x92c')](_0x9c95ab)+_0x17e2fb('0x7cd')}),_0x1c5d13();})['catch'](function(_0x545902){const _0x42ae92=_0x3cd34b;console[_0x42ae92('0xfc9')](_0x545902),_0x55128a[_0x42ae92('0x61a')]=_0x545902[_0x42ae92('0x25f4')][_0x42ae92('0x61a')]||[{'message':_0x545902['toString'](),'type':_0x42ae92('0x2602')}];});},function(){});}function _0x44e9b1(){const _0x22a5f6=_0x24f8e8;return _0x55128a[_0x22a5f6('0x1301')]['variableName']!==undefined?_0x55128a[_0x22a5f6('0x1301')][_0x22a5f6('0xbdb')]:_0x22a5f6('0x16a4');}function _0x1c5d13(){const _0x1f641f=_0x24f8e8;_0x50f170[_0x1f641f('0x1197')]();}}const _0x4d1893=_0x18ff66;_0x1f9039[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x2330'),_0x36e6f4('0x17aa')];function _0x1f9039(_0x3e4df8,_0x4d6e33,_0x268af0,_0x3ed7ce,_0x26a8ed,_0x48ffcc,_0x17d12c,_0x356f9e,_0x5768cd,_0x3eb985,_0x27f2a3,_0x3400ab){const _0x4d02ca=_0x36e6f4,_0x125c54=this;_0x125c54[_0x4d02ca('0x98')]=_0x3eb985[_0x4d02ca('0x26cd')](),_0x125c54['license']=_0x48ffcc,_0x125c54[_0x4d02ca('0xf8a')]=_0x17d12c,_0x125c54['passwordPattern']=_0x125c54[_0x4d02ca('0xf8a')][_0x4d02ca('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x125c54[_0x4d02ca('0x246b')]=_0x4d6e33[_0x4d02ca('0x6f1')]()+'://'+_0x4d6e33[_0x4d02ca('0x1690')](),_0x125c54[_0x4d02ca('0x2330')]=_0x27f2a3||_0x3e4df8[_0x4d02ca('0x23f')][_0x4d02ca('0x2330')]||{},_0x125c54[_0x4d02ca('0x17aa')]=_0x3400ab&&_0x3400ab['count']==0x1?_0x3400ab[_0x4d02ca('0x269a')][0x0]:null,_0x125c54[_0x4d02ca('0x243c')]=_0x3eb985[_0x4d02ca('0xd87')](_0x125c54[_0x4d02ca('0x17aa')]?_0x125c54[_0x4d02ca('0x17aa')][_0x4d02ca('0x243c')]:null),_0x125c54[_0x4d02ca('0x128b')]={},_0x125c54['selectedTab']=_0x3e4df8[_0x4d02ca('0x23f')][_0x4d02ca('0xbe3')]||0x0,_0x125c54[_0x4d02ca('0x31d')]=_0x5768cd[_0x4d02ca('0x1fa1')],_0x125c54[_0x4d02ca('0x5c5')]=_0x2604cb,_0x125c54[_0x4d02ca('0x16fd')]=_0x594623;function _0x2604cb(){const _0x498dcf=_0x4d02ca;_0x3e4df8['go'](_0x498dcf('0x1df9'),{},{'reload':_0x498dcf('0x1df9')});}function _0x594623(){const _0x47541d=_0x4d02ca;_0x356f9e['intSalesforceAccount'][_0x47541d('0x1449')]({'id':_0x125c54['salesforceAccount']['id']},_0x125c54[_0x47541d('0x2330')])['$promise'][_0x47541d('0x1166')](function(){const _0x2d8133=_0x47541d;_0x5768cd[_0x2d8133('0x103b')]({'title':_0x2d8133('0x55'),'msg':_0x125c54['salesforceAccount'][_0x2d8133('0x4f0')]?_0x125c54[_0x2d8133('0x2330')][_0x2d8133('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x47541d('0x1a80')](function(_0x33b732){const _0x8932ab=_0x47541d;_0x5768cd[_0x8932ab('0xfc9')]({'title':_0x33b732[_0x8932ab('0x52d')]?'API:'+_0x33b732[_0x8932ab('0x52d')]+_0x8932ab('0x11e1')+_0x33b732['statusText']:_0x8932ab('0x1eec'),'msg':_0x33b732[_0x8932ab('0x25f4')]?JSON[_0x8932ab('0xbac')](_0x33b732[_0x8932ab('0x25f4')]):_0x33b732['toString']()});});}}const _0x366029=_0x1f9039,_0x13f163=_0x2734b2['p']+_0x36e6f4('0x13d4');_0x12fddb[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'salesforceAccounts',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x12fddb(_0x3a9875,_0x216656,_0x3695d6,_0x4ccde6,_0x9359b7,_0x33b567,_0xd9cc43,_0xf30fa5,_0x2d8dd7,_0x47e98e,_0x459f34,_0x54363f,_0x4edf82,_0x7488c6,_0x531d8e,_0x269808,_0x15599e){const _0x393c8b=_0x36e6f4,_0x14d8c8=this;_0x14d8c8['license']=_0x269808,_0x14d8c8[_0x393c8b('0xf8a')]=_0x15599e,_0x14d8c8[_0x393c8b('0x98')]=_0x531d8e[_0x393c8b('0x26cd')](),_0x14d8c8[_0x393c8b('0x10a8')]=_0x2d8dd7||{'count':0x0,'rows':[]},_0x14d8c8[_0x393c8b('0x7f')]=_0x47e98e,_0x14d8c8[_0x393c8b('0x17aa')]=_0x459f34&&_0x459f34[_0x393c8b('0x240f')]==0x1?_0x459f34['rows'][0x0]:null,_0x14d8c8[_0x393c8b('0x243c')]=_0x531d8e[_0x393c8b('0xd87')](_0x14d8c8['userProfileSection']?_0x14d8c8[_0x393c8b('0x17aa')][_0x393c8b('0x243c')]:null),_0x14d8c8[_0x393c8b('0x916')]='salesforceAccounts',_0x14d8c8[_0x393c8b('0xef5')]='',_0x14d8c8[_0x393c8b('0x104c')]=null,_0x14d8c8[_0x393c8b('0x1397')]=[],_0x14d8c8[_0x393c8b('0x2218')]={'fields':_0x393c8b('0x1742'),'limit':0xa,'page':0x1},_0x14d8c8['arraytype']=_0x2cfb05()[_0x393c8b('0x155c')]([{'option':_0x393c8b('0x40b'),'value':_0x393c8b('0x2496')},{'option':'New_Tab','value':_0x393c8b('0x137e')}],function(_0x59e7c2){const _0x52ff51=_0x393c8b;return _0x2cfb05()[_0x52ff51('0xf3')](_0x59e7c2[_0x52ff51('0x18e0')],new RegExp('\x27','g'),'');}),_0x14d8c8['editstate']=_0x4f3950,_0x14d8c8[_0x393c8b('0x2113')]=_0x14c19f,_0x14d8c8[_0x393c8b('0x8d8')]=_0xf9aa08,_0x14d8c8[_0x393c8b('0x103b')]=_0x1f7c47,_0x14d8c8[_0x393c8b('0x1b80')]=_0x23d7f3,_0x14d8c8[_0x393c8b('0x194e')]=_0x89c357,_0x14d8c8[_0x393c8b('0xcec')]=_0x446f57,_0x14d8c8[_0x393c8b('0x170b')]=_0x1112b3,_0x14d8c8[_0x393c8b('0x2418')]=_0x8cb9c7,_0x14d8c8[_0x393c8b('0x1f35')]=_0x4b26cb,_0x14d8c8['selectAllSalesforceAccounts']=_0x2e4e0c;function _0x4f3950(_0x2d668e){const _0x1371b3=_0x393c8b;_0x3695d6['go'](_0x1371b3('0x1445'),{'id':_0x2d668e['id'],'salesforceAccount':_0x2d668e,'crudPermissions':_0x14d8c8[_0x1371b3('0x243c')]});}function _0x14c19f(_0x315eb5){const _0x3a6d54=_0x393c8b;return _0x54363f[_0x3a6d54('0x164')][_0x3a6d54('0x18ea')]({'id':_0x315eb5['id'],'test':!![]})[_0x3a6d54('0xa44')][_0x3a6d54('0x1166')](function(){const _0x4d4a85=_0x3a6d54;_0x7488c6['success']({'title':'SalesforceAccount\x20properly\x20tested','msg':_0x4d4a85('0x1fef')});})['catch'](function(_0x58f24f){const _0x450e68=_0x3a6d54;_0x7488c6[_0x450e68('0xfc9')]({'title':_0x450e68('0x10c5'),'msg':_0x58f24f[_0x450e68('0x25f4')]?_0x58f24f[_0x450e68('0x25f4')][_0x450e68('0x1e70')]?_0x58f24f[_0x450e68('0x25f4')][_0x450e68('0x1e70')]:JSON[_0x450e68('0xbac')](_0x58f24f[_0x450e68('0x25f4')]):_0x58f24f[_0x450e68('0x1586')]()});});}function _0xf9aa08(_0x106192,_0x2c5cf7){const _0x309a3c=_0x393c8b,_0x53af07=_0x9359b7[_0x309a3c('0x1d26')]()['title'](_0x309a3c('0x288d')+_0x2cfb05()[_0x309a3c('0xb35')](_0x309a3c('0x2330'))+'?')[_0x309a3c('0xf3c')](_0x309a3c('0x12b5')+(_0x106192[_0x309a3c('0x4f0')]||'salesforceAccount')+_0x309a3c('0xace')+_0x309a3c('0x3f3'))['ariaLabel'](_0x309a3c('0x202c'))[_0x309a3c('0x203b')](_0x2c5cf7)['ok']('OK')['cancel']('CANCEL');_0x9359b7[_0x309a3c('0x1f80')](_0x53af07)[_0x309a3c('0x1166')](function(){_0x446f57(_0x106192);},function(){const _0x28ed01=_0x309a3c;console[_0x28ed01('0x455')](_0x28ed01('0x2d3'));});}let _0x57b525=!![],_0x237bcb=0x1;_0x3a9875[_0x393c8b('0xe83')](_0x393c8b('0x12d8'),function(_0x1c3b8b,_0x150026){const _0x14e824=_0x393c8b;_0x57b525?_0xd9cc43(function(){_0x57b525=![];}):(!_0x150026&&(_0x237bcb=_0x14d8c8[_0x14e824('0x2218')][_0x14e824('0x1a43')]),_0x1c3b8b!==_0x150026&&(_0x14d8c8['query'][_0x14e824('0x1a43')]=0x1),!_0x1c3b8b&&(_0x14d8c8[_0x14e824('0x2218')][_0x14e824('0x1a43')]=_0x237bcb),_0x14d8c8[_0x14e824('0x1b80')]());});function _0x1f7c47(_0x282cfe){_0x14d8c8['salesforceAccounts']=_0x282cfe||{'count':0x0,'rows':[]};}function _0x23d7f3(){const _0x506fcb=_0x393c8b;_0x14d8c8[_0x506fcb('0x2218')][_0x506fcb('0x1098')]=(_0x14d8c8[_0x506fcb('0x2218')][_0x506fcb('0x1a43')]-0x1)*_0x14d8c8['query'][_0x506fcb('0x163f')],_0x531d8e[_0x506fcb('0x1ac6')]('admin')?_0x14d8c8[_0x506fcb('0x1f48')]=_0x54363f[_0x506fcb('0x164')][_0x506fcb('0xd83')](_0x14d8c8[_0x506fcb('0x2218')],_0x1f7c47)[_0x506fcb('0xa44')]:(_0x14d8c8[_0x506fcb('0x2218')]['id']=_0x14d8c8[_0x506fcb('0x7f')]['id'],_0x14d8c8[_0x506fcb('0x2218')][_0x506fcb('0xe60')]=_0x506fcb('0x350'),_0x14d8c8['promise']=_0x54363f[_0x506fcb('0x7f')][_0x506fcb('0x263a')](_0x14d8c8[_0x506fcb('0x2218')],_0x1f7c47)[_0x506fcb('0xa44')]);}function _0x89c357(_0x47d82d,_0x48c316){const _0x4b6624=_0x393c8b;_0x9359b7[_0x4b6624('0x1f80')]({'controller':_0x4b6624('0x1fac'),'controllerAs':'vm','templateUrl':_0x13f163,'parent':angular[_0x4b6624('0x1194')](_0x33b567['body']),'targetEvent':_0x47d82d,'clickOutsideToClose':!![],'locals':{'salesforceAccount':_0x48c316,'salesforceAccounts':_0x14d8c8[_0x4b6624('0x10a8')][_0x4b6624('0x269a')],'license':_0x14d8c8[_0x4b6624('0x5c9')],'setting':_0x14d8c8[_0x4b6624('0xf8a')],'crudPermissions':_0x14d8c8[_0x4b6624('0x243c')]}});}function _0x446f57(_0x3faa7e){const _0x6fee4f=_0x393c8b;_0x54363f[_0x6fee4f('0x164')]['delete']({'id':_0x3faa7e['id']})['$promise']['then'](function(){const _0x45cb94=_0x6fee4f;_0x2cfb05()['remove'](_0x14d8c8[_0x45cb94('0x10a8')][_0x45cb94('0x269a')],{'id':_0x3faa7e['id']}),_0x14d8c8['salesforceAccounts'][_0x45cb94('0x240f')]-=0x1,!_0x14d8c8[_0x45cb94('0x10a8')][_0x45cb94('0x269a')][_0x45cb94('0x264b')]&&_0x14d8c8[_0x45cb94('0x1b80')](),_0x7488c6[_0x45cb94('0x103b')]({'title':_0x2cfb05()[_0x45cb94('0xb35')](_0x45cb94('0x26ec'))+_0x45cb94('0x2b6'),'msg':_0x3faa7e[_0x45cb94('0x4f0')]?_0x3faa7e['name']+_0x45cb94('0x7cd'):''});})[_0x6fee4f('0x1a80')](function(_0x20c9dc){const _0x5b31b4=_0x6fee4f;if(_0x20c9dc[_0x5b31b4('0x25f4')]&&_0x20c9dc[_0x5b31b4('0x25f4')][_0x5b31b4('0x61a')]&&_0x20c9dc['data'][_0x5b31b4('0x61a')][_0x5b31b4('0x264b')]){_0x14d8c8[_0x5b31b4('0x61a')]=_0x20c9dc['data'][_0x5b31b4('0x61a')]||[{'message':_0x20c9dc[_0x5b31b4('0x1586')](),'type':'SYSTEM:DELETEintSalesforceAccount'}];for(let _0x400cb9=0x0;_0x400cb9<_0x20c9dc[_0x5b31b4('0x25f4')][_0x5b31b4('0x61a')][_0x5b31b4('0x264b')];_0x400cb9++){_0x7488c6['error']({'title':_0x20c9dc['data'][_0x5b31b4('0x61a')][_0x400cb9]['type'],'msg':_0x20c9dc['data'][_0x5b31b4('0x61a')][_0x400cb9][_0x5b31b4('0x1e70')]});}}else _0x7488c6[_0x5b31b4('0xfc9')]({'title':_0x20c9dc[_0x5b31b4('0x52d')]?_0x5b31b4('0x1e21')+_0x20c9dc[_0x5b31b4('0x52d')]+_0x5b31b4('0x11e1')+_0x20c9dc[_0x5b31b4('0xe1b')]:'SYSTEM:DELETEintSalesforceAccount','msg':_0x20c9dc[_0x5b31b4('0x25f4')]?JSON['stringify'](_0x20c9dc[_0x5b31b4('0x25f4')][_0x5b31b4('0x1e70')]):_0x20c9dc['message']||_0x20c9dc['toString']()});});}function _0x1112b3(){const _0x2748e4=_0x393c8b,_0x3faaf3=angular[_0x2748e4('0x225f')](_0x14d8c8['selectedSalesforceAccounts']);return _0x14d8c8['selectedSalesforceAccounts']=[],_0x3faaf3;}function _0x8cb9c7(_0x119fef){const _0x5f01db=_0x393c8b,_0xd94ec7=_0x9359b7[_0x5f01db('0x1d26')]()[_0x5f01db('0xcdc')](_0x5f01db('0x1119'))['htmlContent'](_0x5f01db('0x12b5')+_0x14d8c8['selectedSalesforceAccounts'][_0x5f01db('0x264b')]+_0x5f01db('0x196d')+_0x5f01db('0x3f3'))[_0x5f01db('0x8e8')](_0x5f01db('0x2fc'))['targetEvent'](_0x119fef)['ok']('OK')[_0x5f01db('0x3f')]('CANCEL');_0x9359b7[_0x5f01db('0x1f80')](_0xd94ec7)[_0x5f01db('0x1166')](function(){const _0xefa17c=_0x5f01db;_0x14d8c8[_0xefa17c('0x1397')][_0xefa17c('0x2782')](function(_0x481dd5){_0x446f57(_0x481dd5);}),_0x14d8c8[_0xefa17c('0x1397')]=[];});}function _0x4b26cb(){const _0x400c74=_0x393c8b;_0x14d8c8[_0x400c74('0x1397')]=[];}function _0x2e4e0c(){const _0x71f725=_0x393c8b;_0x14d8c8[_0x71f725('0x1397')]=_0x14d8c8[_0x71f725('0x10a8')][_0x71f725('0x269a')];}}const _0x3cf41f=_0x12fddb;_0xb59643['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q','$translate','toasty',_0x36e6f4('0x18ba'),_0x36e6f4('0x2051'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0xb59643(_0x2c3e54,_0x8d5afa,_0x2d2380,_0x1cea9d,_0x558df3,_0x193fd3,_0x3edf3c,_0x5931d6,_0x583f05,_0x144ed3,_0x2ac71a,_0x378b88,_0x194287,_0x32421a){const _0x377663=_0x36e6f4,_0x6e9c9e=this;_0x6e9c9e[_0x377663('0x98')]=_0x2ac71a[_0x377663('0x26cd')](),_0x6e9c9e[_0x377663('0x61a')]=[],_0x6e9c9e[_0x377663('0xf8a')]=_0x194287,_0x6e9c9e[_0x377663('0x5c9')]=_0x378b88,_0x6e9c9e[_0x377663('0x243c')]=_0x32421a,_0x6e9c9e[_0x377663('0x128b')]={},_0x6e9c9e['passwordPattern']=_0x6e9c9e[_0x377663('0xf8a')]&&_0x6e9c9e['setting'][_0x377663('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x6e9c9e[_0x377663('0xcdc')]=_0x377663('0x18fd'),_0x6e9c9e['servicenowAccount']=angular['copy'](_0x583f05),_0x6e9c9e[_0x377663('0x18ba')]=_0x5931d6,_0x6e9c9e[_0x377663('0x1212')]=![];!_0x6e9c9e['servicenowAccount']&&(_0x6e9c9e[_0x377663('0x2051')]={'serverUrl':_0x2d2380['protocol']()+_0x377663('0xc51')+_0x2d2380[_0x377663('0x1690')]()+(_0x2d2380[_0x377663('0x93d')]()?':'+_0x2d2380[_0x377663('0x93d')]():'')},_0x6e9c9e[_0x377663('0xcdc')]=_0x377663('0x3ae'),_0x6e9c9e['newServicenowAccount']=!![]);_0x6e9c9e[_0x377663('0x1e52')]=_0x541c36,_0x6e9c9e[_0x377663('0x13bb')]=_0x51691a,_0x6e9c9e[_0x377663('0x704')]=_0x2881b5,_0x6e9c9e[_0x377663('0x1a9c')]=_0x548bb2,_0x6e9c9e[_0x377663('0x24a0')]=_0xaacc9b;function _0x541c36(){const _0x10d7ca=_0x377663;_0x6e9c9e[_0x10d7ca('0x61a')]=[],_0x144ed3[_0x10d7ca('0x148b')]['save'](_0x6e9c9e[_0x10d7ca('0x2051')])[_0x10d7ca('0xa44')][_0x10d7ca('0x1166')](function(_0x1dc0b7){const _0x1d1259=_0x10d7ca;_0x6e9c9e[_0x1d1259('0x18ba')][_0x1d1259('0x2450')](_0x1dc0b7[_0x1d1259('0x2876')]()),_0x3edf3c[_0x1d1259('0x103b')]({'title':'ServicenowAccount\x20properly\x20created','msg':_0x6e9c9e[_0x1d1259('0x2051')][_0x1d1259('0x4f0')]?_0x6e9c9e[_0x1d1259('0x2051')]['name']+_0x1d1259('0x1eda'):''}),_0xaacc9b(_0x1dc0b7);})[_0x10d7ca('0x1a80')](function(_0x317fe4){const _0x25f250=_0x10d7ca;if(_0x317fe4['data']&&_0x317fe4[_0x25f250('0x25f4')][_0x25f250('0x61a')]&&_0x317fe4[_0x25f250('0x25f4')][_0x25f250('0x61a')][_0x25f250('0x264b')]){_0x6e9c9e[_0x25f250('0x61a')]=_0x317fe4['data'][_0x25f250('0x61a')]||[{'message':_0x317fe4[_0x25f250('0x1586')](),'type':_0x25f250('0x21bd')}];for(let _0x22f9e4=0x0;_0x22f9e4<_0x317fe4[_0x25f250('0x25f4')][_0x25f250('0x61a')][_0x25f250('0x264b')];_0x22f9e4+=0x1){_0x3edf3c['error']({'title':_0x317fe4[_0x25f250('0x25f4')]['errors'][_0x22f9e4][_0x25f250('0x1345')],'msg':_0x317fe4[_0x25f250('0x25f4')][_0x25f250('0x61a')][_0x22f9e4][_0x25f250('0x1e70')]});}}else _0x3edf3c['error']({'title':_0x317fe4[_0x25f250('0x52d')]?_0x25f250('0x1e21')+_0x317fe4[_0x25f250('0x52d')]+_0x25f250('0x11e1')+_0x317fe4[_0x25f250('0xe1b')]:_0x25f250('0x21bd'),'msg':_0x317fe4[_0x25f250('0x25f4')]?JSON[_0x25f250('0xbac')](_0x317fe4[_0x25f250('0x25f4')][_0x25f250('0x1e70')]):_0x317fe4[_0x25f250('0x1586')]()});});}function _0x51691a(){const _0x26fdb7=_0x377663;_0x6e9c9e['errors']=[],_0x144ed3[_0x26fdb7('0x148b')][_0x26fdb7('0x1449')]({'id':_0x6e9c9e[_0x26fdb7('0x2051')]['id']},_0x6e9c9e[_0x26fdb7('0x2051')])[_0x26fdb7('0xa44')]['then'](function(_0x497dd5){const _0x13f0fa=_0x26fdb7,_0x206e67=_0x2cfb05()[_0x13f0fa('0xc38')](_0x6e9c9e['servicenowAccounts'],{'id':_0x497dd5['id']});_0x206e67&&_0x2cfb05()[_0x13f0fa('0xcc3')](_0x206e67,_0x2cfb05()[_0x13f0fa('0x1a08')](_0x497dd5['toJSON'](),_0x2cfb05()['keys'](_0x206e67))),_0x3edf3c[_0x13f0fa('0x103b')]({'title':_0x13f0fa('0xf88'),'msg':_0x6e9c9e[_0x13f0fa('0x2051')][_0x13f0fa('0x4f0')]?_0x6e9c9e[_0x13f0fa('0x2051')][_0x13f0fa('0x4f0')]+_0x13f0fa('0x7d'):''}),_0xaacc9b(_0x497dd5);})[_0x26fdb7('0x1a80')](function(_0x7b1939){const _0x8e007f=_0x26fdb7;if(_0x7b1939[_0x8e007f('0x25f4')]&&_0x7b1939[_0x8e007f('0x25f4')][_0x8e007f('0x61a')]&&_0x7b1939[_0x8e007f('0x25f4')][_0x8e007f('0x61a')][_0x8e007f('0x264b')]){_0x6e9c9e[_0x8e007f('0x61a')]=_0x7b1939['data'][_0x8e007f('0x61a')]||[{'message':_0x7b1939['toString'](),'type':_0x8e007f('0x16c4')}];for(let _0x405028=0x0;_0x405028<_0x7b1939[_0x8e007f('0x25f4')][_0x8e007f('0x61a')][_0x8e007f('0x264b')];_0x405028++){_0x3edf3c['error']({'title':_0x7b1939[_0x8e007f('0x25f4')][_0x8e007f('0x61a')][_0x405028][_0x8e007f('0x1345')],'msg':_0x7b1939[_0x8e007f('0x25f4')][_0x8e007f('0x61a')][_0x405028][_0x8e007f('0x1e70')]});}}else _0x3edf3c[_0x8e007f('0xfc9')]({'title':_0x7b1939[_0x8e007f('0x52d')]?_0x8e007f('0x1e21')+_0x7b1939['status']+_0x8e007f('0x11e1')+_0x7b1939[_0x8e007f('0xe1b')]:'api.intServicenowAccount.update','msg':_0x7b1939['data']?JSON[_0x8e007f('0xbac')](_0x7b1939[_0x8e007f('0x25f4')][_0x8e007f('0x1e70')]):_0x7b1939[_0x8e007f('0x1586')]()});});}function _0x2881b5(_0x30e2e7){const _0xba8c0b=_0x377663;_0x6e9c9e[_0xba8c0b('0x61a')]=[];const _0x29db7c=_0x1cea9d[_0xba8c0b('0x1d26')]()[_0xba8c0b('0xcdc')](_0xba8c0b('0x7fb'))[_0xba8c0b('0xacc')](_0xba8c0b('0x2143'))['ariaLabel'](_0xba8c0b('0xbf6'))['ok']('Delete')[_0xba8c0b('0x3f')]('Cancel')['targetEvent'](_0x30e2e7);_0x1cea9d[_0xba8c0b('0x1f80')](_0x29db7c)['then'](function(){const _0x17e629=_0xba8c0b;_0x144ed3[_0x17e629('0x148b')][_0x17e629('0x906')]({'id':_0x6e9c9e[_0x17e629('0x2051')]['id']})[_0x17e629('0xa44')]['then'](function(){const _0x3cf8ce=_0x17e629;_0x2cfb05()[_0x3cf8ce('0x127f')](_0x6e9c9e[_0x3cf8ce('0x18ba')],{'id':_0x6e9c9e[_0x3cf8ce('0x2051')]['id']}),_0x3edf3c['success']({'title':_0x3cf8ce('0x1ed'),'msg':(_0x6e9c9e[_0x3cf8ce('0x2051')][_0x3cf8ce('0x4f0')]||'servicenowAccount')+'\x20has\x20been\x20deleted!'}),_0xaacc9b(_0x6e9c9e[_0x3cf8ce('0x2051')]);})[_0x17e629('0x1a80')](function(_0x53daf7){const _0x3d5315=_0x17e629;if(_0x53daf7[_0x3d5315('0x25f4')]&&_0x53daf7[_0x3d5315('0x25f4')][_0x3d5315('0x61a')]&&_0x53daf7[_0x3d5315('0x25f4')][_0x3d5315('0x61a')]['length']){_0x6e9c9e[_0x3d5315('0x61a')]=_0x53daf7[_0x3d5315('0x25f4')][_0x3d5315('0x61a')]||[{'message':_0x53daf7[_0x3d5315('0x1586')](),'type':_0x3d5315('0x969')}];for(let _0x30d2ab=0x0;_0x30d2ab<_0x53daf7[_0x3d5315('0x25f4')][_0x3d5315('0x61a')][_0x3d5315('0x264b')];_0x30d2ab++){_0x3edf3c[_0x3d5315('0xfc9')]({'title':_0x53daf7[_0x3d5315('0x25f4')][_0x3d5315('0x61a')][_0x30d2ab][_0x3d5315('0x1345')],'msg':_0x53daf7['data']['errors'][_0x30d2ab][_0x3d5315('0x1e70')]});}}else _0x3edf3c[_0x3d5315('0xfc9')]({'title':_0x53daf7[_0x3d5315('0x52d')]?_0x3d5315('0x1e21')+_0x53daf7['status']+'\x20-\x20'+_0x53daf7[_0x3d5315('0xe1b')]:_0x3d5315('0x969'),'msg':_0x53daf7[_0x3d5315('0x25f4')]?JSON[_0x3d5315('0xbac')](_0x53daf7[_0x3d5315('0x25f4')][_0x3d5315('0x1e70')]):_0x53daf7[_0x3d5315('0x1e70')]||_0x53daf7[_0x3d5315('0x1586')]()});});},function(){});}function _0x548bb2(_0x3a7b4b){return _0x3a7b4b===null?undefined:new Date(_0x3a7b4b);}function _0xaacc9b(_0x4595b4){const _0x261dad=_0x377663;_0x1cea9d[_0x261dad('0x1197')](_0x4595b4);}}const _0x11ffe6=_0xb59643,_0x3a63c4=_0x2734b2['p']+_0x36e6f4('0x1cbf'),_0x314feb=_0x2734b2['p']+_0x36e6f4('0x2157');_0x30e3c9[_0x36e6f4('0x1294')]=['$mdDialog','$document',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x30e3c9(_0x2d9a6a,_0x272626,_0x5690b2,_0x3ec8df,_0x2977af){const _0x56af76=_0x36e6f4,_0x291a15=this;_0x291a15[_0x56af76('0x98')]=_0x2977af[_0x56af76('0x26cd')](),_0x291a15[_0x56af76('0x2051')]={},_0x291a15[_0x56af76('0xd9a')]={},_0x291a15[_0x56af76('0xd54')]=[],_0x291a15[_0x56af76('0xcbb')]=-0x1,_0x291a15[_0x56af76('0x243c')],_0x291a15[_0x56af76('0x24d5')]=_0x41bf82,_0x291a15[_0x56af76('0x1ea4')]=_0xa78784,_0x291a15[_0x56af76('0xc2e')]=_0x220b33,_0x291a15['deleteServicenowConfiguration']=_0x350b62;function _0x41bf82(_0x312d2a,_0x8ea076){const _0xdf9ef5=_0x56af76;_0x291a15[_0xdf9ef5('0x2051')]=_0x312d2a,_0x291a15[_0xdf9ef5('0x243c')]=typeof _0x8ea076!==_0xdf9ef5('0x1048')?_0x8ea076:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x5690b2['intServicenowAccount'][_0xdf9ef5('0x13db')]({'id':_0x291a15[_0xdf9ef5('0x2051')]['id'],'sort':_0xdf9ef5('0x14dc')})[_0xdf9ef5('0xa44')][_0xdf9ef5('0x1166')](function(_0x5a464d){const _0x2b8001=_0xdf9ef5;return _0x291a15['configurations']=_0x5a464d[_0x2b8001('0x269a')]?_0x5a464d[_0x2b8001('0x269a')]:[],_0x291a15['configurations'][_0x2b8001('0x264b')]&&_0x291a15['getServicenowConfiguration'](0x0),_0x5690b2[_0x2b8001('0x734')][_0x2b8001('0xd83')]({'nolimit':!![],'sort':_0x2b8001('0x4f0')})[_0x2b8001('0xa44')];})['then'](function(_0x4e9774){const _0x474040=_0xdf9ef5;_0x291a15[_0x474040('0x57a')]=_0x4e9774['rows']?_0x4e9774[_0x474040('0x269a')]:[],_0x291a15[_0x474040('0x217a')]=_0x2cfb05()[_0x474040('0x155c')](_0x291a15[_0x474040('0x57a')],'id');})[_0xdf9ef5('0x1a80')](function(_0x51414b){const _0x51381b=_0xdf9ef5;_0x3ec8df[_0x51381b('0xfc9')]({'title':_0x51414b[_0x51381b('0x52d')]?_0x51381b('0x1e21')+_0x51414b[_0x51381b('0x52d')]+'\x20-\x20'+_0x51414b['statusText']:_0x51381b('0x17ab'),'msg':_0x51414b['data']?JSON['stringify'](_0x51414b[_0x51381b('0x25f4')]):_0x51414b[_0x51381b('0x1586')]()});});}function _0xa78784(_0x36d19e){const _0x59fd20=_0x56af76;_0x291a15[_0x59fd20('0xd9a')]=_0x291a15['configurations'][_0x36d19e],_0x291a15[_0x59fd20('0xcbb')]=_0x36d19e,_0x5690b2[_0x59fd20('0x18c8')][_0x59fd20('0x154d')]({'id':_0x291a15['servicenowConfiguration']['id']})['$promise']['then'](function(_0x168d5e){const _0x333781=_0x59fd20;return _0x291a15['subjects']=_0x168d5e[_0x333781('0x269a')]?_0x168d5e[_0x333781('0x269a')]:[],_0x5690b2['intServicenowConfiguration'][_0x333781('0x28d4')]({'id':_0x291a15[_0x333781('0xd9a')]['id']})['$promise'];})[_0x59fd20('0x1166')](function(_0x1778e6){const _0x2ddfad=_0x59fd20;return _0x291a15[_0x2ddfad('0x1b3d')]=_0x1778e6[_0x2ddfad('0x269a')]?_0x1778e6[_0x2ddfad('0x269a')]:[],_0x5690b2[_0x2ddfad('0x18c8')][_0x2ddfad('0x18ea')]({'id':_0x291a15['servicenowConfiguration']['id']})[_0x2ddfad('0xa44')];})[_0x59fd20('0x1166')](function(_0x3b9a47){const _0x44f4a5=_0x59fd20;_0x291a15[_0x44f4a5('0xfe2')]=_0x3b9a47['rows']?_0x3b9a47['rows']:[];})[_0x59fd20('0x1a80')](function(_0x360abe){const _0x4336ca=_0x59fd20;_0x3ec8df['error']({'title':_0x360abe[_0x4336ca('0x52d')]?_0x4336ca('0x1e21')+_0x360abe[_0x4336ca('0x52d')]+_0x4336ca('0x11e1')+_0x360abe['statusText']:_0x4336ca('0x16c7'),'msg':_0x360abe[_0x4336ca('0x25f4')]?JSON[_0x4336ca('0xbac')](_0x360abe['data']):_0x360abe[_0x4336ca('0x1586')]()});});}function _0x220b33(_0x2e29cf,_0x154c1a){const _0x1379e9=_0x56af76;_0x2d9a6a[_0x1379e9('0x1f80')]({'controller':_0x1379e9('0x6d0'),'controllerAs':'vm','templateUrl':_0x3a63c4,'parent':angular[_0x1379e9('0x1194')](_0x272626[_0x1379e9('0x8d2')]),'targetEvent':_0x2e29cf,'clickOutsideToClose':!![],'locals':{'servicenowConfiguration':_0x154c1a,'configurations':_0x291a15[_0x1379e9('0xd54')],'license':null,'setting':null,'crudPermissions':_0x291a15[_0x1379e9('0x243c')]}})[_0x1379e9('0x1951')](function(){const _0x516bf9=_0x1379e9;_0x291a15[_0x516bf9('0x1ea4')](0x0);});}function _0x350b62(_0x11c0ed,_0x36b7de){const _0x3b6ca2=_0x56af76,_0x3bd665=_0x2d9a6a[_0x3b6ca2('0x1d26')]()[_0x3b6ca2('0xcdc')](_0x3b6ca2('0x1165'))[_0x3b6ca2('0xf3c')](_0x3b6ca2('0x12b5')+(_0x36b7de[_0x3b6ca2('0x4f0')]||_0x3b6ca2('0xd9a'))+''+_0x3b6ca2('0x3f3'))[_0x3b6ca2('0x8e8')](_0x3b6ca2('0x1860'))['targetEvent'](_0x11c0ed)['ok']('OK')[_0x3b6ca2('0x3f')](_0x3b6ca2('0x2d3'));_0x2d9a6a[_0x3b6ca2('0x1f80')](_0x3bd665)[_0x3b6ca2('0x1166')](function(){const _0x7cb555=_0x3b6ca2;_0x5690b2[_0x7cb555('0x18c8')][_0x7cb555('0x906')]({'id':_0x36b7de['id']})[_0x7cb555('0xa44')][_0x7cb555('0x1166')](function(){const _0x1ee405=_0x7cb555;_0x2cfb05()[_0x1ee405('0x127f')](_0x291a15[_0x1ee405('0xd54')],{'id':_0x36b7de['id']}),_0x3ec8df[_0x1ee405('0x103b')]({'title':'ServicenowConfiguration\x20deleted!','msg':_0x36b7de[_0x1ee405('0x4f0')]?_0x36b7de[_0x1ee405('0x4f0')]+_0x1ee405('0x7cd'):''});})['catch'](function(_0x3fa31a){const _0x2017b9=_0x7cb555;_0x3ec8df[_0x2017b9('0xfc9')]({'title':_0x3fa31a['status']?'API:'+_0x3fa31a[_0x2017b9('0x52d')]+_0x2017b9('0x11e1')+_0x3fa31a[_0x2017b9('0xe1b')]:_0x2017b9('0x19a8'),'msg':_0x3fa31a[_0x2017b9('0x25f4')]?JSON[_0x2017b9('0xbac')](_0x3fa31a[_0x2017b9('0x25f4')]):_0x3fa31a[_0x2017b9('0x1586')]()});})[_0x7cb555('0x1951')](function(){const _0x5bdfeb=_0x7cb555;_0x291a15[_0x5bdfeb('0x1ea4')](0x0);});},function(){const _0x31d905=_0x3b6ca2;console[_0x31d905('0x455')](_0x31d905('0x2d3'));});}_0x291a15[_0x56af76('0xd02')]=[],_0x291a15[_0x56af76('0x1a33')]=_0x33323d,_0x291a15['deleteSubjectConfirm']=_0x4e945c,_0x291a15['deleteSelectedSubjects']=_0x3c66df;function _0x33323d(_0x3332f2,_0x349e87){const _0x221a1d=_0x56af76;_0x2d9a6a['show']({'controller':_0x221a1d('0x3d6'),'controllerAs':'vm','templateUrl':_0x314feb,'parent':angular[_0x221a1d('0x1194')](_0x272626[_0x221a1d('0x8d2')]),'targetEvent':_0x3332f2,'clickOutsideToClose':!![],'locals':{'type':_0x221a1d('0x210d'),'item':_0x349e87,'items':_0x291a15[_0x221a1d('0x2701')],'configuration':_0x291a15[_0x221a1d('0xd9a')],'account':_0x291a15['servicenowAccount'],'license':null,'setting':null,'crudPermissions':_0x291a15[_0x221a1d('0x243c')]}});}function _0x23cc16(_0x2c66dd){const _0x597e64=_0x56af76;_0x5690b2[_0x597e64('0x1bde')][_0x597e64('0x906')]({'id':_0x2c66dd['id']})['$promise']['then'](function(){const _0x43d656=_0x597e64;_0x2cfb05()[_0x43d656('0x127f')](_0x291a15[_0x43d656('0x2701')],{'id':_0x2c66dd['id']}),_0x3ec8df[_0x43d656('0x103b')]({'title':_0x43d656('0x6f'),'msg':_0x43d656('0x259f')});})[_0x597e64('0x1a80')](function(_0x2ec0b3){const _0x42511c=_0x597e64;_0x3ec8df[_0x42511c('0xfc9')]({'title':_0x2ec0b3[_0x42511c('0x52d')]?_0x42511c('0x1e21')+_0x2ec0b3[_0x42511c('0x52d')]+'\x20-\x20'+_0x2ec0b3['statusText']:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x2ec0b3[_0x42511c('0x25f4')]?JSON[_0x42511c('0xbac')](_0x2ec0b3[_0x42511c('0x25f4')]):_0x2ec0b3[_0x42511c('0x1586')]()});});}function _0x4e945c(_0x16cdbd,_0xb43e6f){const _0x34dfc6=_0x56af76,_0x3479ed=_0x2d9a6a[_0x34dfc6('0x1d26')]()[_0x34dfc6('0xcdc')](_0x34dfc6('0x11c8'))[_0x34dfc6('0xf3c')](_0x34dfc6('0x277a')+_0x34dfc6('0x3f3'))[_0x34dfc6('0x8e8')](_0x34dfc6('0x87a'))[_0x34dfc6('0x203b')](_0x16cdbd)['ok']('OK')[_0x34dfc6('0x3f')](_0x34dfc6('0x2d3'));_0x2d9a6a[_0x34dfc6('0x1f80')](_0x3479ed)[_0x34dfc6('0x1166')](function(){_0x23cc16(_0xb43e6f);},function(){const _0x3ce75a=_0x34dfc6;console[_0x3ce75a('0x455')](_0x3ce75a('0x2d3'));});}function _0x3c66df(_0x5e9e66){const _0x46de3e=_0x56af76,_0x3f4aea=_0x2d9a6a[_0x46de3e('0x1d26')]()[_0x46de3e('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20subjects?')[_0x46de3e('0xf3c')](_0x46de3e('0x12b5')+_0x291a15[_0x46de3e('0xd02')][_0x46de3e('0x264b')]+'\x20selected'+_0x46de3e('0x3f3'))[_0x46de3e('0x8e8')]('delete\x20subjects')['targetEvent'](_0x5e9e66)['ok']('OK')[_0x46de3e('0x3f')]('CANCEL');_0x2d9a6a[_0x46de3e('0x1f80')](_0x3f4aea)['then'](function(){const _0x3b4979=_0x46de3e;_0x291a15['selectedSubjects']['forEach'](function(_0x2cca3d){_0x23cc16(_0x2cca3d);}),_0x291a15[_0x3b4979('0xd02')]=[];});}_0x291a15[_0x56af76('0x968')]=[],_0x291a15[_0x56af76('0x2185')]=_0x2325f5,_0x291a15[_0x56af76('0xdf3')]=_0x1f2165,_0x291a15[_0x56af76('0x2269')]=_0x237727;function _0x2325f5(_0x1e7498,_0x42ab69){const _0x5cb0d5=_0x56af76;_0x2d9a6a['show']({'controller':_0x5cb0d5('0x3d6'),'controllerAs':'vm','templateUrl':_0x314feb,'parent':angular[_0x5cb0d5('0x1194')](_0x272626[_0x5cb0d5('0x8d2')]),'targetEvent':_0x1e7498,'clickOutsideToClose':!![],'locals':{'type':'description','item':_0x42ab69,'items':_0x291a15['descriptions'],'configuration':_0x291a15[_0x5cb0d5('0xd9a')],'account':_0x291a15[_0x5cb0d5('0x2051')],'license':null,'setting':null,'crudPermissions':_0x291a15[_0x5cb0d5('0x243c')]}});}function _0x1c664c(_0x457166){const _0x3a4378=_0x56af76;_0x5690b2['intServicenowField'][_0x3a4378('0x906')]({'id':_0x457166['id']})[_0x3a4378('0xa44')][_0x3a4378('0x1166')](function(){const _0x2f98d1=_0x3a4378;_0x2cfb05()[_0x2f98d1('0x127f')](_0x291a15[_0x2f98d1('0x1b3d')],{'id':_0x457166['id']}),_0x3ec8df['success']({'title':_0x2f98d1('0x9c1'),'msg':'Description\x20has\x20been\x20deleted!'});})['catch'](function(_0x59b6a2){const _0x15cd95=_0x3a4378;_0x3ec8df['error']({'title':_0x59b6a2[_0x15cd95('0x52d')]?_0x15cd95('0x1e21')+_0x59b6a2[_0x15cd95('0x52d')]+_0x15cd95('0x11e1')+_0x59b6a2[_0x15cd95('0xe1b')]:_0x15cd95('0x23ff'),'msg':_0x59b6a2['data']?JSON[_0x15cd95('0xbac')](_0x59b6a2[_0x15cd95('0x25f4')]):_0x59b6a2['toString']()});});}function _0x1f2165(_0x1de78f,_0x184676){const _0x3daecc=_0x56af76,_0x9ba79=_0x2d9a6a[_0x3daecc('0x1d26')]()[_0x3daecc('0xcdc')](_0x3daecc('0x1baa'))[_0x3daecc('0xf3c')](_0x3daecc('0x1809')+_0x3daecc('0x3f3'))[_0x3daecc('0x8e8')]('delete\x20description')['targetEvent'](_0x1de78f)['ok']('OK')[_0x3daecc('0x3f')]('CANCEL');_0x2d9a6a[_0x3daecc('0x1f80')](_0x9ba79)['then'](function(){_0x1c664c(_0x184676);},function(){const _0x1c50b0=_0x3daecc;console[_0x1c50b0('0x455')](_0x1c50b0('0x2d3'));});}function _0x237727(_0x28be8d){const _0x3d9cf3=_0x56af76,_0x50da0c=_0x2d9a6a[_0x3d9cf3('0x1d26')]()[_0x3d9cf3('0xcdc')](_0x3d9cf3('0x29'))[_0x3d9cf3('0xf3c')](_0x3d9cf3('0x12b5')+_0x291a15[_0x3d9cf3('0x968')][_0x3d9cf3('0x264b')]+_0x3d9cf3('0x196d')+_0x3d9cf3('0x3f3'))[_0x3d9cf3('0x8e8')]('delete\x20descriptions')[_0x3d9cf3('0x203b')](_0x28be8d)['ok']('OK')['cancel']('CANCEL');_0x2d9a6a['show'](_0x50da0c)[_0x3d9cf3('0x1166')](function(){const _0x1ddab6=_0x3d9cf3;_0x291a15['selectedDescriptions'][_0x1ddab6('0x2782')](function(_0x50d369){_0x1c664c(_0x50d369);}),_0x291a15[_0x1ddab6('0x968')]=[];});}_0x291a15[_0x56af76('0x16')]=[],_0x291a15[_0x56af76('0x27ad')]=_0xb4c2b0,_0x291a15['deleteFieldConfirm']=_0x50baf1,_0x291a15[_0x56af76('0x1ace')]=_0x3f82f1;function _0xb4c2b0(_0x1de882,_0x598610){const _0x4bcdeb=_0x56af76;_0x2d9a6a[_0x4bcdeb('0x1f80')]({'controller':_0x4bcdeb('0x3d6'),'controllerAs':'vm','templateUrl':_0x314feb,'parent':angular[_0x4bcdeb('0x1194')](_0x272626[_0x4bcdeb('0x8d2')]),'targetEvent':_0x1de882,'clickOutsideToClose':!![],'locals':{'type':_0x4bcdeb('0x22f3'),'item':_0x598610,'items':_0x291a15['fields'],'configuration':_0x291a15[_0x4bcdeb('0xd9a')],'account':_0x291a15['servicenowAccount'],'license':null,'setting':null,'crudPermissions':_0x291a15['crudPermissions']}});}function _0x1e29d6(_0x2ac2cf){const _0xf3aa71=_0x56af76;_0x5690b2[_0xf3aa71('0x1bde')][_0xf3aa71('0x906')]({'id':_0x2ac2cf['id']})[_0xf3aa71('0xa44')]['then'](function(){const _0x1a09af=_0xf3aa71;_0x2cfb05()[_0x1a09af('0x127f')](_0x291a15[_0x1a09af('0xfe2')],{'id':_0x2ac2cf['id']}),_0x3ec8df[_0x1a09af('0x103b')]({'title':_0x1a09af('0x13cb'),'msg':_0x1a09af('0x31e')});})[_0xf3aa71('0x1a80')](function(_0x305d95){const _0x26e7cd=_0xf3aa71;_0x3ec8df['error']({'title':_0x305d95['status']?_0x26e7cd('0x1e21')+_0x305d95[_0x26e7cd('0x52d')]+'\x20-\x20'+_0x305d95[_0x26e7cd('0xe1b')]:_0x26e7cd('0x23ff'),'msg':_0x305d95['data']?JSON[_0x26e7cd('0xbac')](_0x305d95['data']):_0x305d95[_0x26e7cd('0x1586')]()});});}function _0x50baf1(_0x2f614c,_0x404f91){const _0x10abfa=_0x56af76,_0x59c25b=_0x2d9a6a[_0x10abfa('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x10abfa('0xf3c')](_0x10abfa('0x13e0')+_0x10abfa('0x3f3'))[_0x10abfa('0x8e8')](_0x10abfa('0x2127'))[_0x10abfa('0x203b')](_0x2f614c)['ok']('OK')[_0x10abfa('0x3f')](_0x10abfa('0x2d3'));_0x2d9a6a['show'](_0x59c25b)[_0x10abfa('0x1166')](function(){_0x1e29d6(_0x404f91);},function(){const _0x3cf24b=_0x10abfa;console[_0x3cf24b('0x455')](_0x3cf24b('0x2d3'));});}function _0x3f82f1(_0x2b7859){const _0x22222f=_0x56af76,_0x1cf791=_0x2d9a6a['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20fields?')[_0x22222f('0xf3c')](_0x22222f('0x12b5')+_0x291a15['selectedFields'][_0x22222f('0x264b')]+_0x22222f('0x196d')+_0x22222f('0x3f3'))[_0x22222f('0x8e8')](_0x22222f('0x219a'))[_0x22222f('0x203b')](_0x2b7859)['ok']('OK')[_0x22222f('0x3f')](_0x22222f('0x2d3'));_0x2d9a6a['show'](_0x1cf791)[_0x22222f('0x1166')](function(){const _0x2bc5df=_0x22222f;_0x291a15['selectedFields'][_0x2bc5df('0x2782')](function(_0xb1773b){_0x1e29d6(_0xb1773b);}),_0x291a15['selectedFields']=[];});}}const _0x4dc42a=_0x30e3c9;_0x34e7e7['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0xd54'),_0x36e6f4('0xd9a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),'crudPermissions'];function _0x34e7e7(_0x3ffa43,_0x1c5d4f,_0x28ea95,_0x3aeba1,_0x4a2856,_0x5dad32,_0x1b9744,_0x30a590,_0x54dfc8,_0x3309e6,_0x213c19,_0x53ff6a,_0x2013cf,_0x480621){const _0x2626ef=_0x36e6f4,_0x5994a8=this;_0x5994a8[_0x2626ef('0x98')]=_0x213c19[_0x2626ef('0x26cd')](),_0x5994a8[_0x2626ef('0x61a')]=[],_0x5994a8['setting']=_0x2013cf,_0x5994a8[_0x2626ef('0x5c9')]=_0x53ff6a,_0x5994a8[_0x2626ef('0x243c')]=_0x480621,_0x5994a8[_0x2626ef('0x128b')]={},_0x5994a8[_0x2626ef('0x2900')]=_0x5994a8[_0x2626ef('0xf8a')]&&_0x5994a8[_0x2626ef('0xf8a')][_0x2626ef('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5994a8[_0x2626ef('0xcdc')]=_0x2626ef('0x65d'),_0x5994a8[_0x2626ef('0xd9a')]=angular[_0x2626ef('0x225f')](_0x54dfc8),_0x5994a8[_0x2626ef('0xd54')]=_0x30a590,_0x5994a8['newServicenowConfiguration']=![];!_0x5994a8[_0x2626ef('0xd9a')]&&(_0x5994a8['servicenowConfiguration']={'channel':_0x2626ef('0x21da'),'type':'inbound'},_0x5994a8[_0x2626ef('0xcdc')]=_0x2626ef('0x267d'),_0x5994a8['newServicenowConfiguration']=!![]);_0x5994a8[_0x2626ef('0x509')]=_0x5146b2,_0x5994a8[_0x2626ef('0x1e94')]=_0x18ce7a,_0x5994a8[_0x2626ef('0x264a')]=_0x1489ba,_0x5994a8[_0x2626ef('0x1a9c')]=_0x31f343,_0x5994a8['closeDialog']=_0x46be3c;function _0x5146b2(){const _0x330c46=_0x2626ef;_0x5994a8[_0x330c46('0x61a')]=[],_0x3309e6[_0x330c46('0x148b')][_0x330c46('0x274a')]({'id':_0x1c5d4f[_0x330c46('0x23f')]['id']},_0x5994a8[_0x330c46('0xd9a')])[_0x330c46('0xa44')][_0x330c46('0x1166')](function(_0x4c2b03){const _0x2d8398=_0x330c46;_0x5994a8[_0x2d8398('0xd54')][_0x2d8398('0x2450')](_0x4c2b03[_0x2d8398('0x2876')]()),_0x1b9744[_0x2d8398('0x103b')]({'title':_0x2d8398('0xc4d'),'msg':_0x5994a8[_0x2d8398('0xd9a')][_0x2d8398('0x4f0')]?_0x5994a8[_0x2d8398('0xd9a')][_0x2d8398('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x46be3c(_0x4c2b03);})['catch'](function(_0x1fb813){const _0x454e61=_0x330c46;if(_0x1fb813[_0x454e61('0x25f4')]&&_0x1fb813['data'][_0x454e61('0x61a')]&&_0x1fb813[_0x454e61('0x25f4')][_0x454e61('0x61a')]['length']){_0x5994a8[_0x454e61('0x61a')]=_0x1fb813[_0x454e61('0x25f4')][_0x454e61('0x61a')]||[{'message':_0x1fb813[_0x454e61('0x1586')](),'type':_0x454e61('0x1e26')}];for(let _0x28b11e=0x0;_0x28b11e<_0x1fb813[_0x454e61('0x25f4')][_0x454e61('0x61a')][_0x454e61('0x264b')];_0x28b11e+=0x1){_0x1b9744[_0x454e61('0xfc9')]({'title':_0x1fb813[_0x454e61('0x25f4')][_0x454e61('0x61a')][_0x28b11e]['type'],'msg':_0x1fb813[_0x454e61('0x25f4')][_0x454e61('0x61a')][_0x28b11e][_0x454e61('0x1e70')]});}}else _0x1b9744[_0x454e61('0xfc9')]({'title':_0x1fb813[_0x454e61('0x52d')]?'API:'+_0x1fb813['status']+_0x454e61('0x11e1')+_0x1fb813['statusText']:_0x454e61('0x1e26'),'msg':_0x1fb813[_0x454e61('0x25f4')]?JSON['stringify'](_0x1fb813[_0x454e61('0x25f4')]['message']):_0x1fb813['toString']()});});}function _0x18ce7a(){const _0xba3366=_0x2626ef;_0x5994a8[_0xba3366('0x61a')]=[],_0x3309e6[_0xba3366('0x18c8')][_0xba3366('0x1449')]({'id':_0x5994a8[_0xba3366('0xd9a')]['id']},_0x5994a8[_0xba3366('0xd9a')])[_0xba3366('0xa44')][_0xba3366('0x1166')](function(_0x2e9b15){const _0x5ca15f=_0xba3366,_0x1567d2=_0x2cfb05()[_0x5ca15f('0xc38')](_0x5994a8[_0x5ca15f('0xd54')],{'id':_0x2e9b15['id']});_0x1567d2&&_0x2cfb05()[_0x5ca15f('0xcc3')](_0x1567d2,_0x2cfb05()['pick'](_0x2e9b15[_0x5ca15f('0x2876')](),_0x2cfb05()[_0x5ca15f('0x14a4')](_0x1567d2))),_0x1b9744['success']({'title':'ServicenowConfiguration\x20properly\x20saved!','msg':_0x5994a8[_0x5ca15f('0xd9a')][_0x5ca15f('0x4f0')]?_0x5994a8['servicenowConfiguration'][_0x5ca15f('0x4f0')]+_0x5ca15f('0x7d'):''}),_0x46be3c(_0x2e9b15);})[_0xba3366('0x1a80')](function(_0x167672){const _0x9321b7=_0xba3366;if(_0x167672[_0x9321b7('0x25f4')]&&_0x167672['data']['errors']&&_0x167672[_0x9321b7('0x25f4')][_0x9321b7('0x61a')][_0x9321b7('0x264b')]){_0x5994a8[_0x9321b7('0x61a')]=_0x167672[_0x9321b7('0x25f4')][_0x9321b7('0x61a')]||[{'message':_0x167672[_0x9321b7('0x1586')](),'type':_0x9321b7('0x2636')}];for(let _0x31d709=0x0;_0x31d709<_0x167672[_0x9321b7('0x25f4')]['errors'][_0x9321b7('0x264b')];_0x31d709++){_0x1b9744[_0x9321b7('0xfc9')]({'title':_0x167672[_0x9321b7('0x25f4')]['errors'][_0x31d709][_0x9321b7('0x1345')],'msg':_0x167672[_0x9321b7('0x25f4')][_0x9321b7('0x61a')][_0x31d709][_0x9321b7('0x1e70')]});}}else _0x1b9744[_0x9321b7('0xfc9')]({'title':_0x167672[_0x9321b7('0x52d')]?_0x9321b7('0x1e21')+_0x167672[_0x9321b7('0x52d')]+'\x20-\x20'+_0x167672[_0x9321b7('0xe1b')]:'api.intServicenowConfiguration.update','msg':_0x167672[_0x9321b7('0x25f4')]?JSON[_0x9321b7('0xbac')](_0x167672[_0x9321b7('0x25f4')][_0x9321b7('0x1e70')]):_0x167672['toString']()});});}function _0x1489ba(_0x78ae84){const _0x402b6e=_0x2626ef;_0x5994a8[_0x402b6e('0x61a')]=[];const _0x691b79=_0x3aeba1['confirm']()[_0x402b6e('0xcdc')](_0x402b6e('0x7fb'))[_0x402b6e('0xacc')]('The\x20servicenowConfiguration\x20will\x20be\x20deleted.')[_0x402b6e('0x8e8')]('Delete\x20ServicenowConfiguration')['ok']('Delete')[_0x402b6e('0x3f')]('Cancel')[_0x402b6e('0x203b')](_0x78ae84);_0x3aeba1[_0x402b6e('0x1f80')](_0x691b79)[_0x402b6e('0x1166')](function(){const _0x4cc082=_0x402b6e;_0x3309e6['intServicenowConfiguration'][_0x4cc082('0x906')]({'id':_0x5994a8[_0x4cc082('0xd9a')]['id']})[_0x4cc082('0xa44')][_0x4cc082('0x1166')](function(){const _0x4b649d=_0x4cc082;_0x2cfb05()[_0x4b649d('0x127f')](_0x5994a8[_0x4b649d('0xd54')],{'id':_0x5994a8[_0x4b649d('0xd9a')]['id']}),_0x1b9744['success']({'title':_0x4b649d('0x1ac2'),'msg':(_0x5994a8[_0x4b649d('0xd9a')][_0x4b649d('0x4f0')]||_0x4b649d('0xd9a'))+'\x20has\x20been\x20deleted!'}),_0x46be3c(_0x5994a8['servicenowConfiguration']);})[_0x4cc082('0x1a80')](function(_0x56d125){const _0x31ad1b=_0x4cc082;if(_0x56d125[_0x31ad1b('0x25f4')]&&_0x56d125[_0x31ad1b('0x25f4')]['errors']&&_0x56d125[_0x31ad1b('0x25f4')][_0x31ad1b('0x61a')][_0x31ad1b('0x264b')]){_0x5994a8['errors']=_0x56d125[_0x31ad1b('0x25f4')][_0x31ad1b('0x61a')]||[{'message':_0x56d125['toString'](),'type':_0x31ad1b('0x92d')}];for(let _0x2dbe0a=0x0;_0x2dbe0a<_0x56d125['data'][_0x31ad1b('0x61a')][_0x31ad1b('0x264b')];_0x2dbe0a++){_0x1b9744[_0x31ad1b('0xfc9')]({'title':_0x56d125[_0x31ad1b('0x25f4')][_0x31ad1b('0x61a')][_0x2dbe0a]['type'],'msg':_0x56d125[_0x31ad1b('0x25f4')]['errors'][_0x2dbe0a][_0x31ad1b('0x1e70')]});}}else _0x1b9744[_0x31ad1b('0xfc9')]({'title':_0x56d125['status']?_0x31ad1b('0x1e21')+_0x56d125['status']+_0x31ad1b('0x11e1')+_0x56d125[_0x31ad1b('0xe1b')]:_0x31ad1b('0x92d'),'msg':_0x56d125[_0x31ad1b('0x25f4')]?JSON[_0x31ad1b('0xbac')](_0x56d125[_0x31ad1b('0x25f4')][_0x31ad1b('0x1e70')]):_0x56d125[_0x31ad1b('0x1e70')]||_0x56d125['toString']()});});},function(){});}function _0x31f343(_0x156a5c){return _0x156a5c===null?undefined:new Date(_0x156a5c);}function _0x46be3c(_0x8be46){const _0x4b1d6c=_0x2626ef;_0x3aeba1[_0x4b1d6c('0x1197')](_0x8be46);}}const _0x422c10=_0x34e7e7;_0x5b023a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xd29'),'items',_0x36e6f4('0x1301'),_0x36e6f4('0x1a32'),_0x36e6f4('0x1345'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x5b023a(_0x59b758,_0x1c47e7,_0x38fb32,_0x2cb462,_0x79d3cc,_0x14c2b0,_0x258492,_0x5cae8f,_0x32318d,_0xa081e8,_0xf8e72b,_0x1c6bcd,_0x1ce7df){const _0x50e398=_0x36e6f4,_0x4c27fb=this;_0x4c27fb[_0x50e398('0x98')]=_0x1c6bcd['getCurrentUser'](),_0x4c27fb[_0x50e398('0x61a')]=[],_0x4c27fb[_0x50e398('0xcdc')]=_0x50e398('0x2012')+_0x2cfb05()[_0x50e398('0x113b')](_0xa081e8),_0x4c27fb['item']=angular['copy'](_0x5cae8f),_0x4c27fb[_0x50e398('0xbd7')]=_0x258492,_0x4c27fb['type']=_0xa081e8,_0x4c27fb['crudPermissions']=_0x1ce7df,_0x4c27fb[_0x50e398('0x17c7')]=![];!_0x4c27fb[_0x50e398('0x1301')]&&(_0x4c27fb['item']={'type':_0x50e398('0x102c')},_0x4c27fb[_0x50e398('0x1301')][_0x2cfb05()[_0x50e398('0x92c')](_0xa081e8)+'Id']=_0x14c2b0['id'],_0x4c27fb[_0x50e398('0xcdc')]=_0x50e398('0xf9c')+_0x2cfb05()['toUpper'](_0xa081e8),_0x4c27fb[_0x50e398('0x17c7')]=!![]);_0x4c27fb[_0x50e398('0x1e8a')]=_0x39ae03,_0x4c27fb[_0x50e398('0x13b8')]=_0x1f59a5,_0x4c27fb[_0x50e398('0x18d3')]=_0x31dd8f,_0x4c27fb[_0x50e398('0x1551')]=_0x3b5c21,_0x4c27fb[_0x50e398('0x24a0')]=_0x3957c4,_0xf8e72b[_0x50e398('0x734')][_0x50e398('0xd83')]({'nolimit':!![]})[_0x50e398('0xa44')][_0x50e398('0x1166')](function(_0x3815a2){const _0x25983e=_0x50e398;return _0x4c27fb[_0x25983e('0x57a')]=_0x3815a2[_0x25983e('0x269a')]?_0x3815a2[_0x25983e('0x269a')]:[],_0xf8e72b[_0x25983e('0x7af')][_0x25983e('0x23d0')]()[_0x25983e('0xa44')];})[_0x50e398('0x1166')](function(_0x126665){const _0x44fe35=_0x50e398;return _0x4c27fb[_0x44fe35('0x1d45')]=_0x2cfb05()['difference'](_0x2cfb05()[_0x44fe35('0x14a4')](_0x126665),['$promise',_0x44fe35('0xfcd'),'createdAt','updatedAt',_0x44fe35('0x978')]),_0x4c27fb[_0x44fe35('0x1d45')]['push'](_0x44fe35('0xa29')),_0xf8e72b[_0x44fe35('0x21f9')][_0x44fe35('0x23d0')]()['$promise'];})['then'](function(_0x271bcb){const _0x23aecd=_0x50e398;_0x4c27fb[_0x23aecd('0x1348')]=_0x2cfb05()[_0x23aecd('0x13ca')](_0x2cfb05()['keys'](_0x271bcb),[_0x23aecd('0xa44'),_0x23aecd('0xfcd'),'createdAt',_0x23aecd('0x6f9'),'sourceid']),_0x4c27fb[_0x23aecd('0x1348')][_0x23aecd('0x1514')]('recordingURL');})[_0x50e398('0x1a80')](function(_0x4f2d37){const _0x3b9475=_0x50e398;_0x79d3cc[_0x3b9475('0xfc9')]({'title':_0x4f2d37[_0x3b9475('0x52d')]?_0x3b9475('0x1e21')+_0x4f2d37[_0x3b9475('0x52d')]+'\x20-\x20'+_0x4f2d37[_0x3b9475('0xe1b')]:'SYSTEM:GETVARIABLES','msg':_0x4f2d37[_0x3b9475('0x25f4')]?JSON['stringify'](_0x4f2d37[_0x3b9475('0x25f4')]):_0x4f2d37[_0x3b9475('0x1586')]()});}),_0xf8e72b[_0x50e398('0x148b')][_0x50e398('0x18ea')]({'id':_0x32318d['id'],'ticketType':_0x14c2b0[_0x50e398('0x11ba')]?_0x14c2b0[_0x50e398('0x11ba')]:undefined})[_0x50e398('0xa44')][_0x50e398('0x1166')](function(_0x2ceba0){const _0x363e78=_0x50e398;_0x4c27fb['accountConnected']=!![],_0x4c27fb['fields']=_0x2ceba0[_0x363e78('0x269a')]?_0x2ceba0[_0x363e78('0x269a')]:[],_0x4c27fb[_0x363e78('0x1301')][_0x363e78('0x1143')]&&(_0x4c27fb[_0x363e78('0x117e')]=_0x2cfb05()['find'](_0x4c27fb['fields'],{'id':_0x4c27fb['item'][_0x363e78('0x1143')]}));})[_0x50e398('0x1a80')](function(_0x2afe20){const _0x2096cd=_0x50e398;_0x4c27fb[_0x2096cd('0x606')]=![],console[_0x2096cd('0xfc9')](_0x2afe20);});function _0x39ae03(){const _0x369d24=_0x50e398;_0x4c27fb[_0x369d24('0x61a')]=[],_0x4c27fb[_0x369d24('0x117e')]&&(_0x4c27fb[_0x369d24('0x1301')][_0x369d24('0x1143')]=_0x4c27fb[_0x369d24('0x117e')]['id'],_0x4c27fb[_0x369d24('0x1301')]['nameField']=_0x4c27fb[_0x369d24('0x117e')]['name'],_0x4c27fb[_0x369d24('0x1301')][_0x369d24('0x117e')]=_0x4c27fb[_0x369d24('0x117e')][_0x369d24('0x2853')]),_0xf8e72b[_0x369d24('0x1bde')][_0x369d24('0x9cc')](_0x4c27fb[_0x369d24('0x1301')])[_0x369d24('0xa44')][_0x369d24('0x1166')](function(_0x56a62e){const _0x198500=_0x369d24;_0x4c27fb[_0x198500('0xbd7')]['unshift'](_0x56a62e),_0x79d3cc['success']({'title':_0x2cfb05()[_0x198500('0x92c')](_0xa081e8)+_0x198500('0x13f0'),'msg':_0x2cfb05()[_0x198500('0x92c')](_0xa081e8)+_0x198500('0x1eda')}),_0x3957c4();})[_0x369d24('0x1a80')](function(_0x5b7e19){const _0x2d12a3=_0x369d24;console[_0x2d12a3('0xfc9')](_0x5b7e19),_0x4c27fb[_0x2d12a3('0x61a')]=_0x5b7e19[_0x2d12a3('0x25f4')]['errors']||[{'message':_0x5b7e19[_0x2d12a3('0x1586')](),'type':_0x2d12a3('0x215d')}];});}function _0x1f59a5(){const _0x413934=_0x50e398;_0x4c27fb[_0x413934('0x61a')]=[],_0x4c27fb[_0x413934('0x117e')]&&(_0x4c27fb[_0x413934('0x1301')]['idField']=_0x4c27fb[_0x413934('0x117e')]['id'],_0x4c27fb['item']['nameField']=_0x4c27fb['customField'][_0x413934('0x4f0')],_0x4c27fb[_0x413934('0x1301')]['customField']=_0x4c27fb[_0x413934('0x117e')][_0x413934('0x2853')]),_0xf8e72b[_0x413934('0x1bde')][_0x413934('0x1449')]({'id':_0x4c27fb[_0x413934('0x1301')]['id']},_0x4c27fb[_0x413934('0x1301')])[_0x413934('0xa44')][_0x413934('0x1166')](function(_0x1feeb8){const _0x260f38=_0x413934,_0x33324a=_0x2cfb05()[_0x260f38('0xc38')](_0x4c27fb['items'],{'id':_0x1feeb8['id']});_0x33324a&&_0x2cfb05()[_0x260f38('0xcc3')](_0x33324a,_0x1feeb8),_0x79d3cc['success']({'title':_0x2cfb05()['capitalize'](_0xa081e8)+_0x260f38('0x1a2f'),'msg':_0x2cfb05()[_0x260f38('0x92c')](_0xa081e8)+'\x20has\x20been\x20saved!'}),_0x3957c4();})[_0x413934('0x1a80')](function(_0x30d9fe){const _0x288029=_0x413934;console[_0x288029('0xfc9')](_0x30d9fe),_0x4c27fb[_0x288029('0x61a')]=_0x30d9fe['data']['errors']||[{'message':_0x30d9fe['toString'](),'type':_0x288029('0x10cd')}];});}function _0x31dd8f(_0x4872d3){const _0x34344e=_0x50e398;_0x4c27fb['errors']=[];const _0x5c888e=_0x2cb462[_0x34344e('0x1d26')]()['title'](_0x34344e('0x7fb'))['content'](_0x34344e('0x135f')+_0xa081e8+_0x34344e('0x3f3'))[_0x34344e('0x8e8')](_0x34344e('0x237c')+_0x2cfb05()['capitalize'](_0xa081e8))['ok'](_0x34344e('0x18'))[_0x34344e('0x3f')]('Cancel')[_0x34344e('0x203b')](_0x4872d3);_0x2cb462[_0x34344e('0x1f80')](_0x5c888e)[_0x34344e('0x1166')](function(){const _0x47f648=_0x34344e;_0xf8e72b[_0x47f648('0x1bde')][_0x47f648('0x906')]({'id':_0x4c27fb[_0x47f648('0x1301')]['id']})[_0x47f648('0xa44')]['then'](function(){const _0x37ac44=_0x47f648;_0x2cfb05()['remove'](_0x4c27fb[_0x37ac44('0xbd7')],{'id':_0x4c27fb['item']['id']}),_0x79d3cc[_0x37ac44('0x103b')]({'title':_0x2cfb05()[_0x37ac44('0x92c')](_0xa081e8)+_0x37ac44('0x450'),'msg':_0x2cfb05()[_0x37ac44('0x92c')](_0xa081e8)+_0x37ac44('0x7cd')}),_0x3957c4();})[_0x47f648('0x1a80')](function(_0x71b1be){const _0x335500=_0x47f648;console[_0x335500('0xfc9')](_0x71b1be),_0x4c27fb['errors']=_0x71b1be[_0x335500('0x25f4')][_0x335500('0x61a')]||[{'message':_0x71b1be['toString'](),'type':'api.item.delete'}];});},function(){});}function _0x3b5c21(){const _0x39db0e=_0x50e398;return _0x4c27fb[_0x39db0e('0x1301')][_0x39db0e('0xbdb')]!==undefined?_0x4c27fb[_0x39db0e('0x1301')][_0x39db0e('0xbdb')]:_0x39db0e('0x16a4');}function _0x3957c4(){const _0x568cd1=_0x50e398;_0x2cb462[_0x568cd1('0x1197')]();}}const _0x18e34d=_0x5b023a;_0x2783e4[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x19e3'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x2051'),'userProfileSection'];function _0x2783e4(_0x3611d1,_0x10b94f,_0x407666,_0x98c2ab,_0x48bd68,_0x14edb2,_0x518476,_0x4cca61,_0x5ab411,_0x6f699,_0x4c35a4,_0x467b7a){const _0xab2dd4=_0x36e6f4,_0x1f468b=this;_0x1f468b[_0xab2dd4('0x98')]=_0x6f699['getCurrentUser'](),_0x1f468b['license']=_0x14edb2,_0x1f468b[_0xab2dd4('0xf8a')]=_0x518476,_0x1f468b[_0xab2dd4('0x2900')]=_0x1f468b['setting'][_0xab2dd4('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1f468b['location']=_0x10b94f[_0xab2dd4('0x6f1')]()+'://'+_0x10b94f[_0xab2dd4('0x1690')](),_0x1f468b[_0xab2dd4('0x2051')]=_0x4c35a4||_0x3611d1[_0xab2dd4('0x23f')][_0xab2dd4('0x2051')]||{},_0x1f468b['userProfileSection']=_0x467b7a&&_0x467b7a[_0xab2dd4('0x240f')]==0x1?_0x467b7a[_0xab2dd4('0x269a')][0x0]:null,_0x1f468b['crudPermissions']=_0x6f699[_0xab2dd4('0xd87')](_0x1f468b[_0xab2dd4('0x17aa')]?_0x1f468b['userProfileSection']['crudPermissions']:null),_0x1f468b[_0xab2dd4('0x128b')]={},_0x1f468b[_0xab2dd4('0x2669')]=_0x3611d1[_0xab2dd4('0x23f')][_0xab2dd4('0xbe3')]||0x0,_0x1f468b[_0xab2dd4('0x31d')]=_0x5ab411[_0xab2dd4('0x1fa1')],_0x1f468b['gotoServicenowAccounts']=_0x46e580,_0x1f468b[_0xab2dd4('0x13bb')]=_0x45ab93;function _0x46e580(){const _0x15aac8=_0xab2dd4;_0x3611d1['go'](_0x15aac8('0x1c78'),{},{'reload':_0x15aac8('0x1c78')});}function _0x45ab93(){const _0x33ce59=_0xab2dd4;_0x4cca61[_0x33ce59('0x148b')]['update']({'id':_0x1f468b[_0x33ce59('0x2051')]['id']},_0x1f468b['servicenowAccount'])[_0x33ce59('0xa44')][_0x33ce59('0x1166')](function(){const _0x1dbbe2=_0x33ce59;_0x5ab411['success']({'title':_0x1dbbe2('0xc15'),'msg':_0x1f468b[_0x1dbbe2('0x2051')][_0x1dbbe2('0x4f0')]?_0x1f468b[_0x1dbbe2('0x2051')]['name']+_0x1dbbe2('0xa17'):''});})['catch'](function(_0x379456){const _0x290274=_0x33ce59;_0x5ab411['error']({'title':_0x379456[_0x290274('0x52d')]?_0x290274('0x1e21')+_0x379456[_0x290274('0x52d')]+_0x290274('0x11e1')+_0x379456[_0x290274('0xe1b')]:_0x290274('0x1949'),'msg':_0x379456[_0x290274('0x25f4')]?JSON[_0x290274('0xbac')](_0x379456[_0x290274('0x25f4')]):_0x379456[_0x290274('0x1586')]()});});}}const _0x3c9089=_0x2783e4,_0x1e25ee=_0x2734b2['p']+_0x36e6f4('0x26f');_0x20376f[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),'$translate','servicenowAccounts',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x20376f(_0xb9017a,_0x1ce383,_0x30613f,_0x2c166b,_0xda321f,_0x1789f4,_0x4f5317,_0x53dc96,_0x1981ec,_0x3bc3f8,_0x2edab2,_0x37debb,_0x330c31,_0x1b6acf,_0x171dd1,_0x341da9,_0x338a1f){const _0x208853=_0x36e6f4,_0x42d040=this;_0x42d040[_0x208853('0x5c9')]=_0x341da9,_0x42d040[_0x208853('0xf8a')]=_0x338a1f,_0x42d040[_0x208853('0x98')]=_0x171dd1['getCurrentUser'](),_0x42d040['servicenowAccounts']=_0x1981ec||{'count':0x0,'rows':[]},_0x42d040[_0x208853('0x7f')]=_0x3bc3f8,_0x42d040[_0x208853('0x17aa')]=_0x2edab2&&_0x2edab2[_0x208853('0x240f')]==0x1?_0x2edab2[_0x208853('0x269a')][0x0]:null,_0x42d040[_0x208853('0x243c')]=_0x171dd1['parseCrudPermissions'](_0x42d040['userProfileSection']?_0x42d040[_0x208853('0x17aa')][_0x208853('0x243c')]:null),_0x42d040['table']=_0x208853('0x18ba'),_0x42d040[_0x208853('0xef5')]='',_0x42d040[_0x208853('0x104c')]=null,_0x42d040[_0x208853('0x2894')]=[],_0x42d040[_0x208853('0x2218')]={'fields':_0x208853('0xe9'),'limit':0xa,'page':0x1},_0x42d040[_0x208853('0x1ff6')]=_0x1c75a4,_0x42d040[_0x208853('0x2113')]=_0x486d8d,_0x42d040[_0x208853('0x8d8')]=_0x2a0825,_0x42d040['success']=_0x5a9090,_0x42d040[_0x208853('0x225a')]=_0x5a17c0,_0x42d040['createOrEditServicenowAccount']=_0xc1e246,_0x42d040[_0x208853('0x704')]=_0x141842,_0x42d040[_0x208853('0x9cb')]=_0x327798,_0x42d040[_0x208853('0xa58')]=_0x9c73a6,_0x42d040['deselectServicenowAccounts']=_0x262a4a,_0x42d040[_0x208853('0x1ed3')]=_0x352e19;function _0x1c75a4(_0xced5fb){const _0x2c7e0e=_0x208853;_0x30613f['go'](_0x2c7e0e('0x62e'),{'id':_0xced5fb['id'],'servicenowAccount':_0xced5fb,'crudPermissions':_0x42d040[_0x2c7e0e('0x243c')]});}function _0x486d8d(_0x4a7f1f){const _0xcdcb1f=_0x208853;return _0x37debb[_0xcdcb1f('0x148b')][_0xcdcb1f('0x18ea')]({'id':_0x4a7f1f['id'],'test':!![]})[_0xcdcb1f('0xa44')][_0xcdcb1f('0x1166')](function(){const _0x197f84=_0xcdcb1f;_0x1b6acf['success']({'title':_0x197f84('0x2580'),'msg':_0x197f84('0x1fef')});})['catch'](function(_0x23566f){const _0x592698=_0xcdcb1f;_0x1b6acf[_0x592698('0xfc9')]({'title':_0x592698('0x2580'),'msg':_0x23566f[_0x592698('0x25f4')]?_0x23566f[_0x592698('0x25f4')][_0x592698('0x1e70')]?_0x23566f[_0x592698('0x25f4')]['message']:JSON[_0x592698('0xbac')](_0x23566f[_0x592698('0x25f4')]):_0x23566f[_0x592698('0x1586')]()});});}function _0x2a0825(_0x253cfd,_0x4f1c7d){const _0x2f7c55=_0x208853,_0x3bd878=_0xda321f[_0x2f7c55('0x1d26')]()[_0x2f7c55('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x2f7c55('0xb35')](_0x2f7c55('0x2051'))+'?')[_0x2f7c55('0xf3c')](''+(_0x253cfd[_0x2f7c55('0x4f0')]||_0x2f7c55('0x2051'))+_0x2f7c55('0xace')+_0x2f7c55('0x3f3'))[_0x2f7c55('0x8e8')]('delete\x20servicenowAccount')[_0x2f7c55('0x203b')](_0x4f1c7d)['ok']('OK')[_0x2f7c55('0x3f')](_0x2f7c55('0x2d3'));_0xda321f[_0x2f7c55('0x1f80')](_0x3bd878)[_0x2f7c55('0x1166')](function(){_0x141842(_0x253cfd);},function(){const _0x3d9dda=_0x2f7c55;console[_0x3d9dda('0x455')](_0x3d9dda('0x2d3'));});}let _0x475a5f=!![],_0x45d49b=0x1;_0xb9017a['$watch'](_0x208853('0x12d8'),function(_0x2423f7,_0x233b83){const _0x202fef=_0x208853;_0x475a5f?_0x4f5317(function(){_0x475a5f=![];}):(!_0x233b83&&(_0x45d49b=_0x42d040['query']['page']),_0x2423f7!==_0x233b83&&(_0x42d040[_0x202fef('0x2218')][_0x202fef('0x1a43')]=0x1),!_0x2423f7&&(_0x42d040[_0x202fef('0x2218')]['page']=_0x45d49b),_0x42d040[_0x202fef('0x225a')]());});function _0x5a9090(_0x355626){const _0x25f636=_0x208853;_0x42d040[_0x25f636('0x18ba')]=_0x355626||{'count':0x0,'rows':[]};}function _0x5a17c0(){const _0x8edc3f=_0x208853;_0x42d040[_0x8edc3f('0x2218')][_0x8edc3f('0x1098')]=(_0x42d040['query']['page']-0x1)*_0x42d040[_0x8edc3f('0x2218')][_0x8edc3f('0x163f')],_0x171dd1[_0x8edc3f('0x1ac6')](_0x8edc3f('0xa7c'))?_0x42d040['promise']=_0x37debb['intServicenowAccount'][_0x8edc3f('0xd83')](_0x42d040[_0x8edc3f('0x2218')],_0x5a9090)[_0x8edc3f('0xa44')]:(_0x42d040[_0x8edc3f('0x2218')]['id']=_0x42d040['userProfile']['id'],_0x42d040[_0x8edc3f('0x2218')]['section']=_0x8edc3f('0x4dd'),_0x42d040[_0x8edc3f('0x1f48')]=_0x37debb[_0x8edc3f('0x7f')][_0x8edc3f('0x263a')](_0x42d040[_0x8edc3f('0x2218')],_0x5a9090)[_0x8edc3f('0xa44')]);}function _0xc1e246(_0xb08dcd,_0x599bba){const _0x41dfc1=_0x208853;_0xda321f[_0x41dfc1('0x1f80')]({'controller':_0x41dfc1('0xfcb'),'controllerAs':'vm','templateUrl':_0x1e25ee,'parent':angular['element'](_0x1789f4[_0x41dfc1('0x8d2')]),'targetEvent':_0xb08dcd,'clickOutsideToClose':!![],'locals':{'servicenowAccount':_0x599bba,'servicenowAccounts':_0x42d040[_0x41dfc1('0x18ba')]['rows'],'license':_0x42d040[_0x41dfc1('0x5c9')],'setting':_0x42d040[_0x41dfc1('0xf8a')],'crudPermissions':_0x42d040[_0x41dfc1('0x243c')]}});}function _0x141842(_0x4680f3){const _0x2fc0b4=_0x208853;_0x37debb['intServicenowAccount'][_0x2fc0b4('0x906')]({'id':_0x4680f3['id']})[_0x2fc0b4('0xa44')][_0x2fc0b4('0x1166')](function(){const _0x3a196a=_0x2fc0b4;_0x2cfb05()[_0x3a196a('0x127f')](_0x42d040[_0x3a196a('0x18ba')][_0x3a196a('0x269a')],{'id':_0x4680f3['id']}),_0x42d040[_0x3a196a('0x18ba')][_0x3a196a('0x240f')]-=0x1,!_0x42d040[_0x3a196a('0x18ba')][_0x3a196a('0x269a')][_0x3a196a('0x264b')]&&_0x42d040['getServicenowAccounts'](),_0x1b6acf[_0x3a196a('0x103b')]({'title':_0x2cfb05()[_0x3a196a('0xb35')](_0x3a196a('0x1b57'))+_0x3a196a('0x2b6'),'msg':_0x4680f3[_0x3a196a('0x4f0')]?_0x4680f3[_0x3a196a('0x4f0')]+_0x3a196a('0x7cd'):''});})['catch'](function(_0x3f1eb5){const _0xfaf245=_0x2fc0b4;if(_0x3f1eb5[_0xfaf245('0x25f4')]&&_0x3f1eb5[_0xfaf245('0x25f4')][_0xfaf245('0x61a')]&&_0x3f1eb5[_0xfaf245('0x25f4')][_0xfaf245('0x61a')][_0xfaf245('0x264b')]){_0x42d040[_0xfaf245('0x61a')]=_0x3f1eb5['data']['errors']||[{'message':_0x3f1eb5[_0xfaf245('0x1586')](),'type':_0xfaf245('0x1407')}];for(let _0x4ce4b9=0x0;_0x4ce4b9<_0x3f1eb5[_0xfaf245('0x25f4')][_0xfaf245('0x61a')][_0xfaf245('0x264b')];_0x4ce4b9++){_0x1b6acf['error']({'title':_0x3f1eb5[_0xfaf245('0x25f4')][_0xfaf245('0x61a')][_0x4ce4b9][_0xfaf245('0x1345')],'msg':_0x3f1eb5[_0xfaf245('0x25f4')][_0xfaf245('0x61a')][_0x4ce4b9][_0xfaf245('0x1e70')]});}}else _0x1b6acf['error']({'title':_0x3f1eb5[_0xfaf245('0x52d')]?'API:'+_0x3f1eb5[_0xfaf245('0x52d')]+_0xfaf245('0x11e1')+_0x3f1eb5[_0xfaf245('0xe1b')]:_0xfaf245('0x1407'),'msg':_0x3f1eb5['data']?JSON['stringify'](_0x3f1eb5[_0xfaf245('0x25f4')]['message']):_0x3f1eb5['message']||_0x3f1eb5[_0xfaf245('0x1586')]()});});}function _0x327798(){const _0x20c230=_0x208853,_0x4d336e=angular[_0x20c230('0x225f')](_0x42d040['selectedServicenowAccounts']);return _0x42d040['selectedServicenowAccounts']=[],_0x4d336e;}function _0x9c73a6(_0x1d641){const _0x20b534=_0x208853,_0x103896=_0xda321f[_0x20b534('0x1d26')]()['title'](_0x20b534('0x1239'))[_0x20b534('0xf3c')](_0x20b534('0x12b5')+_0x42d040[_0x20b534('0x2894')][_0x20b534('0x264b')]+_0x20b534('0x196d')+'\x20will\x20be\x20deleted.')[_0x20b534('0x8e8')](_0x20b534('0x262b'))[_0x20b534('0x203b')](_0x1d641)['ok']('OK')[_0x20b534('0x3f')](_0x20b534('0x2d3'));_0xda321f[_0x20b534('0x1f80')](_0x103896)['then'](function(){const _0x252d04=_0x20b534;_0x42d040[_0x252d04('0x2894')][_0x252d04('0x2782')](function(_0x39f86f){_0x141842(_0x39f86f);}),_0x42d040['selectedServicenowAccounts']=[];});}function _0x262a4a(){_0x42d040['selectedServicenowAccounts']=[];}function _0x352e19(){const _0x2a0b52=_0x208853;_0x42d040[_0x2a0b52('0x2894')]=_0x42d040[_0x2a0b52('0x18ba')][_0x2a0b52('0x269a')];}}const _0x420c14=_0x20376f;_0x48f524[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'sugarcrmAccounts',_0x36e6f4('0x13b7'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x48f524(_0x4a39c1,_0x175071,_0x39143a,_0x1c6aa3,_0x3c6d98,_0x21f426,_0x5a77b2,_0x37c187,_0x3e1b64,_0x4795b6,_0x4a12d8,_0x37da98,_0x302112,_0x275c02){const _0x248bbc=_0x36e6f4,_0x97377d=this;_0x97377d[_0x248bbc('0x98')]=_0x4a12d8[_0x248bbc('0x26cd')](),_0x97377d[_0x248bbc('0x61a')]=[],_0x97377d['setting']=_0x302112,_0x97377d[_0x248bbc('0x5c9')]=_0x37da98,_0x97377d[_0x248bbc('0x243c')]=_0x275c02,_0x97377d['hasModulePermissions']={},_0x97377d[_0x248bbc('0x2900')]=_0x97377d['setting']&&_0x97377d[_0x248bbc('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x97377d[_0x248bbc('0xcdc')]=_0x248bbc('0xae6'),_0x97377d['sugarcrmAccount']=angular['copy'](_0x3e1b64),_0x97377d[_0x248bbc('0x1074')]=_0x37c187,_0x97377d['newSugarcrmAccount']=![];!_0x97377d['sugarcrmAccount']&&(_0x97377d[_0x248bbc('0x13b7')]={'serverUrl':_0x39143a['protocol']()+_0x248bbc('0xc51')+_0x39143a['host']()+(_0x39143a['port']()?':'+_0x39143a['port']():'')},_0x97377d[_0x248bbc('0xcdc')]=_0x248bbc('0x1c84'),_0x97377d[_0x248bbc('0x139')]=!![]);_0x97377d[_0x248bbc('0x3e8')]=_0x35c19e,_0x97377d[_0x248bbc('0x22a7')]=_0x57c4dd,_0x97377d[_0x248bbc('0x159e')]=_0x5982e9,_0x97377d[_0x248bbc('0x1a9c')]=_0x2bff3e,_0x97377d['closeDialog']=_0x5cc446;function _0x35c19e(){const _0x1f6d45=_0x248bbc;_0x97377d[_0x1f6d45('0x61a')]=[],_0x4795b6[_0x1f6d45('0x13d9')]['save'](_0x97377d['sugarcrmAccount'])[_0x1f6d45('0xa44')][_0x1f6d45('0x1166')](function(_0x48d0dc){const _0x4ba4d1=_0x1f6d45;_0x97377d[_0x4ba4d1('0x1074')]['unshift'](_0x48d0dc[_0x4ba4d1('0x2876')]()),_0x5a77b2[_0x4ba4d1('0x103b')]({'title':'SugarcrmAccount\x20properly\x20created','msg':_0x97377d['sugarcrmAccount'][_0x4ba4d1('0x4f0')]?_0x97377d['sugarcrmAccount'][_0x4ba4d1('0x4f0')]+_0x4ba4d1('0x1eda'):''}),_0x5cc446(_0x48d0dc);})[_0x1f6d45('0x1a80')](function(_0x5bf2a4){const _0x128c3a=_0x1f6d45;if(_0x5bf2a4[_0x128c3a('0x25f4')]&&_0x5bf2a4[_0x128c3a('0x25f4')]['errors']&&_0x5bf2a4[_0x128c3a('0x25f4')][_0x128c3a('0x61a')][_0x128c3a('0x264b')]){_0x97377d[_0x128c3a('0x61a')]=_0x5bf2a4[_0x128c3a('0x25f4')][_0x128c3a('0x61a')]||[{'message':_0x5bf2a4[_0x128c3a('0x1586')](),'type':_0x128c3a('0x1a1d')}];for(let _0x185e50=0x0;_0x185e50<_0x5bf2a4[_0x128c3a('0x25f4')]['errors'][_0x128c3a('0x264b')];_0x185e50+=0x1){_0x5a77b2[_0x128c3a('0xfc9')]({'title':_0x5bf2a4[_0x128c3a('0x25f4')][_0x128c3a('0x61a')][_0x185e50][_0x128c3a('0x1345')],'msg':_0x5bf2a4[_0x128c3a('0x25f4')]['errors'][_0x185e50][_0x128c3a('0x1e70')]});}}else _0x5a77b2[_0x128c3a('0xfc9')]({'title':_0x5bf2a4[_0x128c3a('0x52d')]?_0x128c3a('0x1e21')+_0x5bf2a4[_0x128c3a('0x52d')]+_0x128c3a('0x11e1')+_0x5bf2a4['statusText']:_0x128c3a('0x1a1d'),'msg':_0x5bf2a4['data']?JSON[_0x128c3a('0xbac')](_0x5bf2a4[_0x128c3a('0x25f4')][_0x128c3a('0x1e70')]):_0x5bf2a4[_0x128c3a('0x1586')]()});});}function _0x57c4dd(){const _0x4b47c5=_0x248bbc;_0x97377d[_0x4b47c5('0x61a')]=[],_0x4795b6[_0x4b47c5('0x13d9')][_0x4b47c5('0x1449')]({'id':_0x97377d[_0x4b47c5('0x13b7')]['id']},_0x97377d[_0x4b47c5('0x13b7')])[_0x4b47c5('0xa44')][_0x4b47c5('0x1166')](function(_0x47db6e){const _0x418fb0=_0x4b47c5,_0x3492a9=_0x2cfb05()[_0x418fb0('0xc38')](_0x97377d[_0x418fb0('0x1074')],{'id':_0x47db6e['id']});_0x3492a9&&_0x2cfb05()[_0x418fb0('0xcc3')](_0x3492a9,_0x2cfb05()[_0x418fb0('0x1a08')](_0x47db6e[_0x418fb0('0x2876')](),_0x2cfb05()[_0x418fb0('0x14a4')](_0x3492a9))),_0x5a77b2[_0x418fb0('0x103b')]({'title':_0x418fb0('0x1fff'),'msg':_0x97377d[_0x418fb0('0x13b7')]['name']?_0x97377d[_0x418fb0('0x13b7')][_0x418fb0('0x4f0')]+_0x418fb0('0x7d'):''}),_0x5cc446(_0x47db6e);})['catch'](function(_0x2e7bcb){const _0x4cc5bd=_0x4b47c5;if(_0x2e7bcb[_0x4cc5bd('0x25f4')]&&_0x2e7bcb[_0x4cc5bd('0x25f4')][_0x4cc5bd('0x61a')]&&_0x2e7bcb[_0x4cc5bd('0x25f4')][_0x4cc5bd('0x61a')]['length']){_0x97377d[_0x4cc5bd('0x61a')]=_0x2e7bcb['data'][_0x4cc5bd('0x61a')]||[{'message':_0x2e7bcb['toString'](),'type':_0x4cc5bd('0x4f9')}];for(let _0x2852f2=0x0;_0x2852f2<_0x2e7bcb['data'][_0x4cc5bd('0x61a')][_0x4cc5bd('0x264b')];_0x2852f2++){_0x5a77b2[_0x4cc5bd('0xfc9')]({'title':_0x2e7bcb[_0x4cc5bd('0x25f4')][_0x4cc5bd('0x61a')][_0x2852f2][_0x4cc5bd('0x1345')],'msg':_0x2e7bcb[_0x4cc5bd('0x25f4')][_0x4cc5bd('0x61a')][_0x2852f2][_0x4cc5bd('0x1e70')]});}}else _0x5a77b2['error']({'title':_0x2e7bcb[_0x4cc5bd('0x52d')]?_0x4cc5bd('0x1e21')+_0x2e7bcb[_0x4cc5bd('0x52d')]+'\x20-\x20'+_0x2e7bcb['statusText']:_0x4cc5bd('0x4f9'),'msg':_0x2e7bcb[_0x4cc5bd('0x25f4')]?JSON[_0x4cc5bd('0xbac')](_0x2e7bcb[_0x4cc5bd('0x25f4')][_0x4cc5bd('0x1e70')]):_0x2e7bcb[_0x4cc5bd('0x1586')]()});});}function _0x5982e9(_0x1945b4){const _0x5107ea=_0x248bbc;_0x97377d[_0x5107ea('0x61a')]=[];const _0x3aeb67=_0x1c6aa3[_0x5107ea('0x1d26')]()[_0x5107ea('0xcdc')](_0x5107ea('0x7fb'))[_0x5107ea('0xacc')]('The\x20sugarcrmAccount\x20will\x20be\x20deleted.')[_0x5107ea('0x8e8')](_0x5107ea('0x17ba'))['ok'](_0x5107ea('0x18'))[_0x5107ea('0x3f')]('Cancel')[_0x5107ea('0x203b')](_0x1945b4);_0x1c6aa3['show'](_0x3aeb67)['then'](function(){const _0x371379=_0x5107ea;_0x4795b6[_0x371379('0x13d9')]['delete']({'id':_0x97377d[_0x371379('0x13b7')]['id']})['$promise'][_0x371379('0x1166')](function(){const _0xf9d63=_0x371379;_0x2cfb05()[_0xf9d63('0x127f')](_0x97377d[_0xf9d63('0x1074')],{'id':_0x97377d[_0xf9d63('0x13b7')]['id']}),_0x5a77b2[_0xf9d63('0x103b')]({'title':_0xf9d63('0x899'),'msg':(_0x97377d['sugarcrmAccount'][_0xf9d63('0x4f0')]||_0xf9d63('0x13b7'))+'\x20has\x20been\x20deleted!'}),_0x5cc446(_0x97377d[_0xf9d63('0x13b7')]);})[_0x371379('0x1a80')](function(_0x401711){const _0x549c5f=_0x371379;if(_0x401711[_0x549c5f('0x25f4')]&&_0x401711[_0x549c5f('0x25f4')][_0x549c5f('0x61a')]&&_0x401711[_0x549c5f('0x25f4')][_0x549c5f('0x61a')][_0x549c5f('0x264b')]){_0x97377d[_0x549c5f('0x61a')]=_0x401711[_0x549c5f('0x25f4')][_0x549c5f('0x61a')]||[{'message':_0x401711[_0x549c5f('0x1586')](),'type':_0x549c5f('0x1862')}];for(let _0x554d8e=0x0;_0x554d8e<_0x401711[_0x549c5f('0x25f4')][_0x549c5f('0x61a')][_0x549c5f('0x264b')];_0x554d8e++){_0x5a77b2[_0x549c5f('0xfc9')]({'title':_0x401711[_0x549c5f('0x25f4')]['errors'][_0x554d8e][_0x549c5f('0x1345')],'msg':_0x401711[_0x549c5f('0x25f4')][_0x549c5f('0x61a')][_0x554d8e][_0x549c5f('0x1e70')]});}}else _0x5a77b2[_0x549c5f('0xfc9')]({'title':_0x401711[_0x549c5f('0x52d')]?'API:'+_0x401711[_0x549c5f('0x52d')]+_0x549c5f('0x11e1')+_0x401711[_0x549c5f('0xe1b')]:_0x549c5f('0x1862'),'msg':_0x401711[_0x549c5f('0x25f4')]?JSON[_0x549c5f('0xbac')](_0x401711[_0x549c5f('0x25f4')][_0x549c5f('0x1e70')]):_0x401711[_0x549c5f('0x1e70')]||_0x401711[_0x549c5f('0x1586')]()});});},function(){});}function _0x2bff3e(_0x2532e6){return _0x2532e6===null?undefined:new Date(_0x2532e6);}function _0x5cc446(_0x5c46b4){const _0x5499c5=_0x248bbc;_0x1c6aa3[_0x5499c5('0x1197')](_0x5c46b4);}}const _0x441c28=_0x48f524,_0x1ab3dd=_0x2734b2['p']+_0x36e6f4('0x116f'),_0x1779d3=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/sugarcrmAccounts/edit/item/dialog.html/dialog.html';_0x1ab471['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x19e3'),'toasty','Auth'];function _0x1ab471(_0x522cee,_0x4aaecc,_0x1476e3,_0x2e7428,_0x18ff46){const _0x26ebd6=_0x36e6f4,_0x3d173b=this;_0x3d173b[_0x26ebd6('0x98')]=_0x18ff46[_0x26ebd6('0x26cd')](),_0x3d173b[_0x26ebd6('0x13b7')]={},_0x3d173b[_0x26ebd6('0x280e')]={},_0x3d173b[_0x26ebd6('0xd54')]=[],_0x3d173b[_0x26ebd6('0xc63')]=-0x1,_0x3d173b[_0x26ebd6('0x243c')],_0x3d173b[_0x26ebd6('0x24d5')]=_0x4be6e9,_0x3d173b[_0x26ebd6('0x19f1')]=_0x36a965,_0x3d173b[_0x26ebd6('0x109b')]=_0xee861b,_0x3d173b[_0x26ebd6('0x4a5')]=_0xc95f91;function _0x4be6e9(_0x2a7c93,_0x4cb644){const _0x35fd4e=_0x26ebd6;_0x3d173b[_0x35fd4e('0x13b7')]=_0x2a7c93,_0x3d173b['crudPermissions']=typeof _0x4cb644!==_0x35fd4e('0x1048')?_0x4cb644:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1476e3[_0x35fd4e('0x13d9')][_0x35fd4e('0x13db')]({'id':_0x3d173b[_0x35fd4e('0x13b7')]['id'],'sort':_0x35fd4e('0x14dc')})['$promise'][_0x35fd4e('0x1166')](function(_0x3203eb){const _0x4beb1=_0x35fd4e;return _0x3d173b[_0x4beb1('0xd54')]=_0x3203eb[_0x4beb1('0x269a')]?_0x3203eb[_0x4beb1('0x269a')]:[],_0x3d173b['configurations'][_0x4beb1('0x264b')]&&_0x3d173b[_0x4beb1('0x19f1')](0x0),_0x1476e3['variable'][_0x4beb1('0xd83')]({'nolimit':!![],'sort':_0x4beb1('0x4f0')})[_0x4beb1('0xa44')];})[_0x35fd4e('0x1166')](function(_0x49e558){const _0x450610=_0x35fd4e;_0x3d173b[_0x450610('0x57a')]=_0x49e558[_0x450610('0x269a')]?_0x49e558[_0x450610('0x269a')]:[],_0x3d173b['variablesById']=_0x2cfb05()[_0x450610('0x155c')](_0x3d173b[_0x450610('0x57a')],'id');})['catch'](function(_0x5b2841){const _0x1bb0cf=_0x35fd4e;_0x2e7428[_0x1bb0cf('0xfc9')]({'title':_0x5b2841[_0x1bb0cf('0x52d')]?_0x1bb0cf('0x1e21')+_0x5b2841[_0x1bb0cf('0x52d')]+_0x1bb0cf('0x11e1')+_0x5b2841[_0x1bb0cf('0xe1b')]:'SYSTEM:GETCONFIGURATION','msg':_0x5b2841['data']?JSON[_0x1bb0cf('0xbac')](_0x5b2841[_0x1bb0cf('0x25f4')]):_0x5b2841[_0x1bb0cf('0x1586')]()});});}function _0x36a965(_0x13a1e0){const _0x44aa84=_0x26ebd6;_0x3d173b['sugarcrmConfiguration']=_0x3d173b[_0x44aa84('0xd54')][_0x13a1e0],_0x3d173b[_0x44aa84('0xc63')]=_0x13a1e0,_0x1476e3[_0x44aa84('0x1691')][_0x44aa84('0x154d')]({'id':_0x3d173b['sugarcrmConfiguration']['id']})[_0x44aa84('0xa44')][_0x44aa84('0x1166')](function(_0x4ac35d){const _0x3c4a02=_0x44aa84;return _0x3d173b[_0x3c4a02('0x2701')]=_0x4ac35d[_0x3c4a02('0x269a')]?_0x4ac35d['rows']:[],_0x1476e3[_0x3c4a02('0x1691')][_0x3c4a02('0x28d4')]({'id':_0x3d173b[_0x3c4a02('0x280e')]['id']})[_0x3c4a02('0xa44')];})[_0x44aa84('0x1166')](function(_0x5a4f73){const _0x79a03d=_0x44aa84;return _0x3d173b[_0x79a03d('0x1b3d')]=_0x5a4f73[_0x79a03d('0x269a')]?_0x5a4f73[_0x79a03d('0x269a')]:[],_0x1476e3[_0x79a03d('0x1691')][_0x79a03d('0x18ea')]({'id':_0x3d173b['sugarcrmConfiguration']['id']})[_0x79a03d('0xa44')];})['then'](function(_0x5f046c){const _0x3e2b95=_0x44aa84;_0x3d173b['fields']=_0x5f046c['rows']?_0x5f046c[_0x3e2b95('0x269a')]:[];})[_0x44aa84('0x1a80')](function(_0x204cf1){const _0x25bb63=_0x44aa84;_0x2e7428[_0x25bb63('0xfc9')]({'title':_0x204cf1[_0x25bb63('0x52d')]?_0x25bb63('0x1e21')+_0x204cf1[_0x25bb63('0x52d')]+'\x20-\x20'+_0x204cf1[_0x25bb63('0xe1b')]:_0x25bb63('0x16c7'),'msg':_0x204cf1['data']?JSON[_0x25bb63('0xbac')](_0x204cf1[_0x25bb63('0x25f4')]):_0x204cf1[_0x25bb63('0x1586')]()});});}function _0xee861b(_0xe2aa17,_0x3d68bf){const _0x59263a=_0x26ebd6;_0x522cee[_0x59263a('0x1f80')]({'controller':_0x59263a('0x2195'),'controllerAs':'vm','templateUrl':_0x1ab3dd,'parent':angular[_0x59263a('0x1194')](_0x4aaecc[_0x59263a('0x8d2')]),'targetEvent':_0xe2aa17,'clickOutsideToClose':!![],'locals':{'sugarcrmConfiguration':_0x3d68bf,'configurations':_0x3d173b[_0x59263a('0xd54')],'license':null,'setting':null,'crudPermissions':_0x3d173b['crudPermissions']}})['finally'](function(){const _0x4f96c7=_0x59263a;_0x3d173b[_0x4f96c7('0x19f1')](0x0);});}function _0xc95f91(_0x5a0c0b,_0x24cb06){const _0x10b7d2=_0x26ebd6,_0x1f4ceb=_0x522cee[_0x10b7d2('0x1d26')]()[_0x10b7d2('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20sugarcrmConfiguration?')['htmlContent'](''+(_0x24cb06[_0x10b7d2('0x4f0')]||_0x10b7d2('0x280e'))+_0x10b7d2('0xace')+_0x10b7d2('0x3f3'))[_0x10b7d2('0x8e8')](_0x10b7d2('0xff4'))['targetEvent'](_0x5a0c0b)['ok']('OK')[_0x10b7d2('0x3f')](_0x10b7d2('0x2d3'));_0x522cee['show'](_0x1f4ceb)[_0x10b7d2('0x1166')](function(){const _0x56f391=_0x10b7d2;_0x1476e3[_0x56f391('0x1691')]['delete']({'id':_0x24cb06['id']})[_0x56f391('0xa44')][_0x56f391('0x1166')](function(){const _0x3145e1=_0x56f391;_0x2cfb05()[_0x3145e1('0x127f')](_0x3d173b[_0x3145e1('0xd54')],{'id':_0x24cb06['id']}),_0x2e7428[_0x3145e1('0x103b')]({'title':'SugarcrmConfiguration\x20deleted!','msg':_0x24cb06[_0x3145e1('0x4f0')]?_0x24cb06[_0x3145e1('0x4f0')]+_0x3145e1('0x7cd'):''});})[_0x56f391('0x1a80')](function(_0x7aea9d){const _0x3808de=_0x56f391;_0x2e7428[_0x3808de('0xfc9')]({'title':_0x7aea9d[_0x3808de('0x52d')]?_0x3808de('0x1e21')+_0x7aea9d[_0x3808de('0x52d')]+'\x20-\x20'+_0x7aea9d[_0x3808de('0xe1b')]:'SYSTEM:DELETECONFIGURATION','msg':_0x7aea9d['data']?JSON[_0x3808de('0xbac')](_0x7aea9d[_0x3808de('0x25f4')]):_0x7aea9d['toString']()});})[_0x56f391('0x1951')](function(){const _0x2ad292=_0x56f391;_0x3d173b[_0x2ad292('0x19f1')](0x0);});},function(){const _0x203e05=_0x10b7d2;console[_0x203e05('0x455')](_0x203e05('0x2d3'));});}_0x3d173b[_0x26ebd6('0xd02')]=[],_0x3d173b[_0x26ebd6('0x1a33')]=_0x6fd9fb,_0x3d173b[_0x26ebd6('0x2059')]=_0x555856,_0x3d173b[_0x26ebd6('0xeff')]=_0x17a87f;function _0x6fd9fb(_0x345d22,_0x59d547){const _0x433559=_0x26ebd6;_0x522cee[_0x433559('0x1f80')]({'controller':_0x433559('0x2545'),'controllerAs':'vm','templateUrl':_0x1779d3,'parent':angular[_0x433559('0x1194')](_0x4aaecc[_0x433559('0x8d2')]),'targetEvent':_0x345d22,'clickOutsideToClose':!![],'locals':{'type':'subject','item':_0x59d547,'items':_0x3d173b[_0x433559('0x2701')],'configuration':_0x3d173b['sugarcrmConfiguration'],'account':_0x3d173b[_0x433559('0x13b7')],'license':null,'setting':null,'crudPermissions':_0x3d173b[_0x433559('0x243c')]}});}function _0xf4c84a(_0x3398e3){const _0x2f8fcd=_0x26ebd6;_0x1476e3[_0x2f8fcd('0xb3d')]['delete']({'id':_0x3398e3['id']})['$promise']['then'](function(){const _0x26f40b=_0x2f8fcd;_0x2cfb05()[_0x26f40b('0x127f')](_0x3d173b['subjects'],{'id':_0x3398e3['id']}),_0x2e7428[_0x26f40b('0x103b')]({'title':'Subject\x20deleted!','msg':_0x26f40b('0x259f')});})[_0x2f8fcd('0x1a80')](function(_0x35129e){const _0x477c1d=_0x2f8fcd;_0x2e7428[_0x477c1d('0xfc9')]({'title':_0x35129e[_0x477c1d('0x52d')]?'API:'+_0x35129e['status']+_0x477c1d('0x11e1')+_0x35129e['statusText']:_0x477c1d('0x23ff'),'msg':_0x35129e[_0x477c1d('0x25f4')]?JSON[_0x477c1d('0xbac')](_0x35129e['data']):_0x35129e['toString']()});});}function _0x555856(_0x1b98fb,_0x55db1f){const _0x5bec4b=_0x26ebd6,_0x1ef9e5=_0x522cee[_0x5bec4b('0x1d26')]()[_0x5bec4b('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20subject?')[_0x5bec4b('0xf3c')]('Subject'+_0x5bec4b('0x3f3'))['ariaLabel'](_0x5bec4b('0x87a'))[_0x5bec4b('0x203b')](_0x1b98fb)['ok']('OK')[_0x5bec4b('0x3f')](_0x5bec4b('0x2d3'));_0x522cee[_0x5bec4b('0x1f80')](_0x1ef9e5)[_0x5bec4b('0x1166')](function(){_0xf4c84a(_0x55db1f);},function(){console['log']('CANCEL');});}function _0x17a87f(_0x4ee701){const _0x2fe879=_0x26ebd6,_0x588f48=_0x522cee[_0x2fe879('0x1d26')]()[_0x2fe879('0xcdc')](_0x2fe879('0x1d64'))[_0x2fe879('0xf3c')](''+_0x3d173b[_0x2fe879('0xd02')][_0x2fe879('0x264b')]+_0x2fe879('0x196d')+_0x2fe879('0x3f3'))['ariaLabel'](_0x2fe879('0x5b2'))['targetEvent'](_0x4ee701)['ok']('OK')[_0x2fe879('0x3f')]('CANCEL');_0x522cee['show'](_0x588f48)[_0x2fe879('0x1166')](function(){const _0x40f8ff=_0x2fe879;_0x3d173b[_0x40f8ff('0xd02')][_0x40f8ff('0x2782')](function(_0x359044){_0xf4c84a(_0x359044);}),_0x3d173b[_0x40f8ff('0xd02')]=[];});}_0x3d173b[_0x26ebd6('0x968')]=[],_0x3d173b[_0x26ebd6('0x2185')]=_0x554fc8,_0x3d173b[_0x26ebd6('0xdf3')]=_0x13b066,_0x3d173b[_0x26ebd6('0x2269')]=_0x37d2eb;function _0x554fc8(_0x5b3c3a,_0x26be25){const _0x4d7505=_0x26ebd6;_0x522cee['show']({'controller':_0x4d7505('0x2545'),'controllerAs':'vm','templateUrl':_0x1779d3,'parent':angular[_0x4d7505('0x1194')](_0x4aaecc[_0x4d7505('0x8d2')]),'targetEvent':_0x5b3c3a,'clickOutsideToClose':!![],'locals':{'type':_0x4d7505('0x101c'),'item':_0x26be25,'items':_0x3d173b['descriptions'],'configuration':_0x3d173b[_0x4d7505('0x280e')],'account':_0x3d173b[_0x4d7505('0x13b7')],'license':null,'setting':null,'crudPermissions':_0x3d173b[_0x4d7505('0x243c')]}});}function _0x20e0b6(_0x221421){const _0x317954=_0x26ebd6;_0x1476e3[_0x317954('0xb3d')][_0x317954('0x906')]({'id':_0x221421['id']})[_0x317954('0xa44')][_0x317954('0x1166')](function(){const _0x2aa555=_0x317954;_0x2cfb05()[_0x2aa555('0x127f')](_0x3d173b[_0x2aa555('0x1b3d')],{'id':_0x221421['id']}),_0x2e7428[_0x2aa555('0x103b')]({'title':_0x2aa555('0x9c1'),'msg':'Description\x20has\x20been\x20deleted!'});})[_0x317954('0x1a80')](function(_0x3674a4){const _0x1881b1=_0x317954;_0x2e7428[_0x1881b1('0xfc9')]({'title':_0x3674a4[_0x1881b1('0x52d')]?_0x1881b1('0x1e21')+_0x3674a4[_0x1881b1('0x52d')]+_0x1881b1('0x11e1')+_0x3674a4['statusText']:_0x1881b1('0x23ff'),'msg':_0x3674a4[_0x1881b1('0x25f4')]?JSON[_0x1881b1('0xbac')](_0x3674a4[_0x1881b1('0x25f4')]):_0x3674a4[_0x1881b1('0x1586')]()});});}function _0x13b066(_0x2acec8,_0x5c105a){const _0x1d2255=_0x26ebd6,_0xf7498b=_0x522cee[_0x1d2255('0x1d26')]()[_0x1d2255('0xcdc')](_0x1d2255('0x1baa'))[_0x1d2255('0xf3c')](_0x1d2255('0x1809')+_0x1d2255('0x3f3'))['ariaLabel'](_0x1d2255('0x1bc0'))[_0x1d2255('0x203b')](_0x2acec8)['ok']('OK')[_0x1d2255('0x3f')](_0x1d2255('0x2d3'));_0x522cee['show'](_0xf7498b)['then'](function(){_0x20e0b6(_0x5c105a);},function(){const _0x5d012d=_0x1d2255;console[_0x5d012d('0x455')](_0x5d012d('0x2d3'));});}function _0x37d2eb(_0xc9cec5){const _0x91d162=_0x26ebd6,_0x5d1cd7=_0x522cee[_0x91d162('0x1d26')]()[_0x91d162('0xcdc')](_0x91d162('0x29'))['htmlContent'](_0x91d162('0x12b5')+_0x3d173b[_0x91d162('0x968')]['length']+'\x20selected'+_0x91d162('0x3f3'))[_0x91d162('0x8e8')](_0x91d162('0x17a'))['targetEvent'](_0xc9cec5)['ok']('OK')['cancel']('CANCEL');_0x522cee[_0x91d162('0x1f80')](_0x5d1cd7)[_0x91d162('0x1166')](function(){const _0x19022d=_0x91d162;_0x3d173b[_0x19022d('0x968')][_0x19022d('0x2782')](function(_0x5e42e5){_0x20e0b6(_0x5e42e5);}),_0x3d173b[_0x19022d('0x968')]=[];});}_0x3d173b[_0x26ebd6('0x16')]=[],_0x3d173b[_0x26ebd6('0x27ad')]=_0x5182fd,_0x3d173b[_0x26ebd6('0xbda')]=_0x3ae458,_0x3d173b[_0x26ebd6('0x1ace')]=_0x55f095;function _0x5182fd(_0x3dfb14,_0x5d7ad2){const _0x7b2136=_0x26ebd6;_0x522cee[_0x7b2136('0x1f80')]({'controller':_0x7b2136('0x2545'),'controllerAs':'vm','templateUrl':_0x1779d3,'parent':angular['element'](_0x4aaecc[_0x7b2136('0x8d2')]),'targetEvent':_0x3dfb14,'clickOutsideToClose':!![],'locals':{'type':_0x7b2136('0x22f3'),'item':_0x5d7ad2,'items':_0x3d173b['fields'],'configuration':_0x3d173b[_0x7b2136('0x280e')],'account':_0x3d173b[_0x7b2136('0x13b7')],'license':null,'setting':null,'crudPermissions':_0x3d173b[_0x7b2136('0x243c')]}});}function _0x3cfed0(_0x2ac8fe){const _0x4a1d23=_0x26ebd6;_0x1476e3[_0x4a1d23('0xb3d')]['delete']({'id':_0x2ac8fe['id']})[_0x4a1d23('0xa44')][_0x4a1d23('0x1166')](function(){const _0x4f0b3f=_0x4a1d23;_0x2cfb05()[_0x4f0b3f('0x127f')](_0x3d173b[_0x4f0b3f('0xfe2')],{'id':_0x2ac8fe['id']}),_0x2e7428['success']({'title':_0x4f0b3f('0x13cb'),'msg':'Field\x20has\x20been\x20deleted!'});})[_0x4a1d23('0x1a80')](function(_0x30aa06){const _0xfa83e2=_0x4a1d23;_0x2e7428[_0xfa83e2('0xfc9')]({'title':_0x30aa06['status']?'API:'+_0x30aa06[_0xfa83e2('0x52d')]+_0xfa83e2('0x11e1')+_0x30aa06['statusText']:_0xfa83e2('0x23ff'),'msg':_0x30aa06['data']?JSON[_0xfa83e2('0xbac')](_0x30aa06[_0xfa83e2('0x25f4')]):_0x30aa06['toString']()});});}function _0x3ae458(_0x1891c9,_0x25d94a){const _0x447936=_0x26ebd6,_0x113ed8=_0x522cee['confirm']()['title'](_0x447936('0xa61'))[_0x447936('0xf3c')](_0x447936('0x13e0')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x447936('0x2127'))[_0x447936('0x203b')](_0x1891c9)['ok']('OK')[_0x447936('0x3f')](_0x447936('0x2d3'));_0x522cee[_0x447936('0x1f80')](_0x113ed8)[_0x447936('0x1166')](function(){_0x3cfed0(_0x25d94a);},function(){const _0x2a119d=_0x447936;console[_0x2a119d('0x455')](_0x2a119d('0x2d3'));});}function _0x55f095(_0x571bb2){const _0x3695c2=_0x26ebd6,_0x2ee7c6=_0x522cee[_0x3695c2('0x1d26')]()['title'](_0x3695c2('0x1d42'))['htmlContent'](_0x3695c2('0x12b5')+_0x3d173b[_0x3695c2('0x16')]['length']+_0x3695c2('0x196d')+_0x3695c2('0x3f3'))[_0x3695c2('0x8e8')](_0x3695c2('0x219a'))[_0x3695c2('0x203b')](_0x571bb2)['ok']('OK')[_0x3695c2('0x3f')](_0x3695c2('0x2d3'));_0x522cee[_0x3695c2('0x1f80')](_0x2ee7c6)['then'](function(){_0x3d173b['selectedFields']['forEach'](function(_0xb85e86){_0x3cfed0(_0xb85e86);}),_0x3d173b['selectedFields']=[];});}}const _0xb2ef07=_0x1ab471;_0x59036b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty','configurations',_0x36e6f4('0x280e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),'crudPermissions'];function _0x59036b(_0x12527d,_0x11f003,_0x150060,_0x2ff6ad,_0x389d30,_0x4a8090,_0x253bfc,_0x2b5fc1,_0x345ace,_0x5e20e8,_0x2a4ff8,_0x241b34,_0x378674,_0x46c4a2){const _0x8a5230=_0x36e6f4,_0x3df8ea=this;_0x3df8ea[_0x8a5230('0x98')]=_0x2a4ff8['getCurrentUser'](),_0x3df8ea[_0x8a5230('0x61a')]=[],_0x3df8ea[_0x8a5230('0xf8a')]=_0x378674,_0x3df8ea[_0x8a5230('0x5c9')]=_0x241b34,_0x3df8ea[_0x8a5230('0x243c')]=_0x46c4a2,_0x3df8ea[_0x8a5230('0x128b')]={},_0x3df8ea[_0x8a5230('0x2900')]=_0x3df8ea[_0x8a5230('0xf8a')]&&_0x3df8ea[_0x8a5230('0xf8a')][_0x8a5230('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3df8ea[_0x8a5230('0xcdc')]=_0x8a5230('0x781'),_0x3df8ea['sugarcrmConfiguration']=angular[_0x8a5230('0x225f')](_0x345ace),_0x3df8ea['configurations']=_0x2b5fc1,_0x3df8ea[_0x8a5230('0xc97')]=![];!_0x3df8ea[_0x8a5230('0x280e')]&&(_0x3df8ea[_0x8a5230('0x280e')]={'channel':_0x8a5230('0x21da'),'type':_0x8a5230('0x14d8')},_0x3df8ea[_0x8a5230('0xcdc')]='INTEGRATIONS.NEW_SUGARCRMCONFIGURATION',_0x3df8ea[_0x8a5230('0xc97')]=!![]);_0x3df8ea['addNewSugarcrmConfiguration']=_0x48d40c,_0x3df8ea['saveSugarcrmConfiguration']=_0xacc1ee,_0x3df8ea[_0x8a5230('0x4a5')]=_0x38a06d,_0x3df8ea[_0x8a5230('0x1a9c')]=_0x337c46,_0x3df8ea['closeDialog']=_0x330fd1;function _0x48d40c(){const _0x4502f3=_0x8a5230;_0x3df8ea[_0x4502f3('0x61a')]=[],_0x5e20e8[_0x4502f3('0x13d9')][_0x4502f3('0x274a')]({'id':_0x11f003[_0x4502f3('0x23f')]['id']},_0x3df8ea[_0x4502f3('0x280e')])[_0x4502f3('0xa44')][_0x4502f3('0x1166')](function(_0x349c76){const _0x47e023=_0x4502f3;_0x3df8ea['configurations'][_0x47e023('0x2450')](_0x349c76[_0x47e023('0x2876')]()),_0x253bfc[_0x47e023('0x103b')]({'title':_0x47e023('0x1100'),'msg':_0x3df8ea[_0x47e023('0x280e')][_0x47e023('0x4f0')]?_0x3df8ea[_0x47e023('0x280e')]['name']+_0x47e023('0x1eda'):''}),_0x330fd1(_0x349c76);})['catch'](function(_0x59723d){const _0x1fd662=_0x4502f3;if(_0x59723d['data']&&_0x59723d[_0x1fd662('0x25f4')][_0x1fd662('0x61a')]&&_0x59723d[_0x1fd662('0x25f4')][_0x1fd662('0x61a')][_0x1fd662('0x264b')]){_0x3df8ea[_0x1fd662('0x61a')]=_0x59723d[_0x1fd662('0x25f4')][_0x1fd662('0x61a')]||[{'message':_0x59723d['toString'](),'type':_0x1fd662('0x1d84')}];for(let _0x388649=0x0;_0x388649<_0x59723d[_0x1fd662('0x25f4')][_0x1fd662('0x61a')][_0x1fd662('0x264b')];_0x388649+=0x1){_0x253bfc['error']({'title':_0x59723d[_0x1fd662('0x25f4')][_0x1fd662('0x61a')][_0x388649][_0x1fd662('0x1345')],'msg':_0x59723d[_0x1fd662('0x25f4')][_0x1fd662('0x61a')][_0x388649][_0x1fd662('0x1e70')]});}}else _0x253bfc[_0x1fd662('0xfc9')]({'title':_0x59723d[_0x1fd662('0x52d')]?_0x1fd662('0x1e21')+_0x59723d[_0x1fd662('0x52d')]+_0x1fd662('0x11e1')+_0x59723d['statusText']:_0x1fd662('0x1d84'),'msg':_0x59723d['data']?JSON[_0x1fd662('0xbac')](_0x59723d[_0x1fd662('0x25f4')][_0x1fd662('0x1e70')]):_0x59723d[_0x1fd662('0x1586')]()});});}function _0xacc1ee(){const _0x667689=_0x8a5230;_0x3df8ea[_0x667689('0x61a')]=[],_0x5e20e8[_0x667689('0x1691')]['update']({'id':_0x3df8ea[_0x667689('0x280e')]['id']},_0x3df8ea[_0x667689('0x280e')])['$promise'][_0x667689('0x1166')](function(_0x51033c){const _0x5a941c=_0x667689,_0x10f45e=_0x2cfb05()[_0x5a941c('0xc38')](_0x3df8ea[_0x5a941c('0xd54')],{'id':_0x51033c['id']});_0x10f45e&&_0x2cfb05()[_0x5a941c('0xcc3')](_0x10f45e,_0x2cfb05()[_0x5a941c('0x1a08')](_0x51033c[_0x5a941c('0x2876')](),_0x2cfb05()[_0x5a941c('0x14a4')](_0x10f45e))),_0x253bfc['success']({'title':_0x5a941c('0x139c'),'msg':_0x3df8ea[_0x5a941c('0x280e')][_0x5a941c('0x4f0')]?_0x3df8ea[_0x5a941c('0x280e')][_0x5a941c('0x4f0')]+_0x5a941c('0x7d'):''}),_0x330fd1(_0x51033c);})[_0x667689('0x1a80')](function(_0x2a6b61){const _0x570387=_0x667689;if(_0x2a6b61['data']&&_0x2a6b61[_0x570387('0x25f4')][_0x570387('0x61a')]&&_0x2a6b61[_0x570387('0x25f4')]['errors'][_0x570387('0x264b')]){_0x3df8ea[_0x570387('0x61a')]=_0x2a6b61[_0x570387('0x25f4')][_0x570387('0x61a')]||[{'message':_0x2a6b61[_0x570387('0x1586')](),'type':_0x570387('0x21e9')}];for(let _0x3a3ee3=0x0;_0x3a3ee3<_0x2a6b61['data'][_0x570387('0x61a')][_0x570387('0x264b')];_0x3a3ee3++){_0x253bfc['error']({'title':_0x2a6b61['data'][_0x570387('0x61a')][_0x3a3ee3][_0x570387('0x1345')],'msg':_0x2a6b61[_0x570387('0x25f4')][_0x570387('0x61a')][_0x3a3ee3]['message']});}}else _0x253bfc[_0x570387('0xfc9')]({'title':_0x2a6b61[_0x570387('0x52d')]?_0x570387('0x1e21')+_0x2a6b61[_0x570387('0x52d')]+'\x20-\x20'+_0x2a6b61[_0x570387('0xe1b')]:_0x570387('0x21e9'),'msg':_0x2a6b61['data']?JSON[_0x570387('0xbac')](_0x2a6b61[_0x570387('0x25f4')][_0x570387('0x1e70')]):_0x2a6b61[_0x570387('0x1586')]()});});}function _0x38a06d(_0x4d00af){const _0x1574d2=_0x8a5230;_0x3df8ea['errors']=[];const _0xf53344=_0x2ff6ad[_0x1574d2('0x1d26')]()['title'](_0x1574d2('0x7fb'))[_0x1574d2('0xacc')]('The\x20sugarcrmConfiguration\x20will\x20be\x20deleted.')[_0x1574d2('0x8e8')](_0x1574d2('0x5c0'))['ok'](_0x1574d2('0x18'))[_0x1574d2('0x3f')](_0x1574d2('0x497'))[_0x1574d2('0x203b')](_0x4d00af);_0x2ff6ad[_0x1574d2('0x1f80')](_0xf53344)[_0x1574d2('0x1166')](function(){const _0x59a3a2=_0x1574d2;_0x5e20e8[_0x59a3a2('0x1691')]['delete']({'id':_0x3df8ea[_0x59a3a2('0x280e')]['id']})[_0x59a3a2('0xa44')]['then'](function(){const _0x51f785=_0x59a3a2;_0x2cfb05()[_0x51f785('0x127f')](_0x3df8ea[_0x51f785('0xd54')],{'id':_0x3df8ea['sugarcrmConfiguration']['id']}),_0x253bfc[_0x51f785('0x103b')]({'title':_0x51f785('0x1fa2'),'msg':(_0x3df8ea[_0x51f785('0x280e')][_0x51f785('0x4f0')]||'sugarcrmConfiguration')+_0x51f785('0x7cd')}),_0x330fd1(_0x3df8ea[_0x51f785('0x280e')]);})[_0x59a3a2('0x1a80')](function(_0x160364){const _0x497ea5=_0x59a3a2;if(_0x160364[_0x497ea5('0x25f4')]&&_0x160364[_0x497ea5('0x25f4')]['errors']&&_0x160364[_0x497ea5('0x25f4')]['errors']['length']){_0x3df8ea[_0x497ea5('0x61a')]=_0x160364['data'][_0x497ea5('0x61a')]||[{'message':_0x160364['toString'](),'type':_0x497ea5('0xb9d')}];for(let _0x5857ea=0x0;_0x5857ea<_0x160364['data'][_0x497ea5('0x61a')][_0x497ea5('0x264b')];_0x5857ea++){_0x253bfc['error']({'title':_0x160364[_0x497ea5('0x25f4')][_0x497ea5('0x61a')][_0x5857ea][_0x497ea5('0x1345')],'msg':_0x160364[_0x497ea5('0x25f4')]['errors'][_0x5857ea]['message']});}}else _0x253bfc[_0x497ea5('0xfc9')]({'title':_0x160364[_0x497ea5('0x52d')]?'API:'+_0x160364[_0x497ea5('0x52d')]+'\x20-\x20'+_0x160364[_0x497ea5('0xe1b')]:'api.intSugarcrmConfiguration.delete','msg':_0x160364[_0x497ea5('0x25f4')]?JSON['stringify'](_0x160364[_0x497ea5('0x25f4')][_0x497ea5('0x1e70')]):_0x160364[_0x497ea5('0x1e70')]||_0x160364['toString']()});});},function(){});}function _0x337c46(_0x1f49db){return _0x1f49db===null?undefined:new Date(_0x1f49db);}function _0x330fd1(_0x5a3f8e){const _0x4a8399=_0x8a5230;_0x2ff6ad[_0x4a8399('0x1197')](_0x5a3f8e);}}const _0x31167b=_0x59036b;_0x4bbf79[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'toasty','configuration',_0x36e6f4('0xbd7'),_0x36e6f4('0x1301'),_0x36e6f4('0x1a32'),_0x36e6f4('0x1345'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x4bbf79(_0x1e2cb9,_0x13788b,_0x7e1b50,_0x392076,_0x16c3a5,_0x57a74a,_0x1ff766,_0x18e272,_0x32e350,_0x3223c3,_0x530b9f,_0x720788,_0x5920c2){const _0x566a6b=_0x36e6f4,_0x424a9b=this;_0x424a9b[_0x566a6b('0x98')]=_0x720788[_0x566a6b('0x26cd')](),_0x424a9b[_0x566a6b('0x61a')]=[],_0x424a9b[_0x566a6b('0xcdc')]=_0x566a6b('0x2012')+_0x2cfb05()[_0x566a6b('0x113b')](_0x3223c3),_0x424a9b[_0x566a6b('0x1301')]=angular[_0x566a6b('0x225f')](_0x18e272),_0x424a9b[_0x566a6b('0xbd7')]=_0x1ff766,_0x424a9b[_0x566a6b('0x1345')]=_0x3223c3,_0x424a9b[_0x566a6b('0x243c')]=_0x5920c2,_0x424a9b['newItem']=![];!_0x424a9b[_0x566a6b('0x1301')]&&(_0x424a9b[_0x566a6b('0x1301')]={'type':_0x566a6b('0x102c')},_0x424a9b['item'][_0x2cfb05()[_0x566a6b('0x92c')](_0x3223c3)+'Id']=_0x57a74a['id'],_0x424a9b[_0x566a6b('0xcdc')]=_0x566a6b('0xf9c')+_0x2cfb05()[_0x566a6b('0x113b')](_0x3223c3),_0x424a9b[_0x566a6b('0x17c7')]=!![]);_0x424a9b[_0x566a6b('0x1e8a')]=_0x5cc078,_0x424a9b[_0x566a6b('0x13b8')]=_0x19c706,_0x424a9b[_0x566a6b('0x18d3')]=_0x3c89a7,_0x424a9b[_0x566a6b('0x1551')]=_0x215422,_0x424a9b[_0x566a6b('0x24a0')]=_0x4a36f4,_0x530b9f['variable'][_0x566a6b('0xd83')]({'nolimit':!![]})[_0x566a6b('0xa44')][_0x566a6b('0x1166')](function(_0xaa4acb){const _0x38e1ec=_0x566a6b;return _0x424a9b[_0x38e1ec('0x57a')]=_0xaa4acb[_0x38e1ec('0x269a')]?_0xaa4acb[_0x38e1ec('0x269a')]:[],_0x530b9f[_0x38e1ec('0x7af')][_0x38e1ec('0x23d0')]()[_0x38e1ec('0xa44')];})[_0x566a6b('0x1166')](function(_0x20ceac){const _0x5a8d22=_0x566a6b;return _0x424a9b['voiceAgentReportColumns']=_0x2cfb05()['difference'](_0x2cfb05()[_0x5a8d22('0x14a4')](_0x20ceac),['$promise','$resolved',_0x5a8d22('0x262'),_0x5a8d22('0x6f9'),_0x5a8d22('0x978')]),_0x424a9b[_0x5a8d22('0x1d45')][_0x5a8d22('0x1514')](_0x5a8d22('0xa29')),_0x530b9f[_0x5a8d22('0x21f9')][_0x5a8d22('0x23d0')]()[_0x5a8d22('0xa44')];})[_0x566a6b('0x1166')](function(_0x3d156b){const _0x1408cd=_0x566a6b;_0x424a9b[_0x1408cd('0x1348')]=_0x2cfb05()[_0x1408cd('0x13ca')](_0x2cfb05()[_0x1408cd('0x14a4')](_0x3d156b),[_0x1408cd('0xa44'),_0x1408cd('0xfcd'),'createdAt','updatedAt',_0x1408cd('0x978')]),_0x424a9b[_0x1408cd('0x1348')][_0x1408cd('0x1514')]('recordingURL');})['catch'](function(_0x504349){const _0x4389d3=_0x566a6b;_0x16c3a5['error']({'title':_0x504349['status']?_0x4389d3('0x1e21')+_0x504349['status']+'\x20-\x20'+_0x504349['statusText']:_0x4389d3('0xfe5'),'msg':_0x504349[_0x4389d3('0x25f4')]?JSON[_0x4389d3('0xbac')](_0x504349[_0x4389d3('0x25f4')]):_0x504349['toString']()});}),_0x530b9f['intSugarcrmAccount'][_0x566a6b('0x18ea')]({'id':_0x32e350['id'],'ticketType':_0x57a74a[_0x566a6b('0x11ba')]?_0x57a74a[_0x566a6b('0x11ba')]:undefined})['$promise']['then'](function(_0x1c8c39){const _0x620035=_0x566a6b;_0x424a9b[_0x620035('0x606')]=!![],_0x424a9b[_0x620035('0xfe2')]=_0x1c8c39[_0x620035('0x269a')]?_0x1c8c39[_0x620035('0x269a')]:[],_0x424a9b['item'][_0x620035('0x1143')]&&(_0x424a9b[_0x620035('0x117e')]=_0x2cfb05()[_0x620035('0xc38')](_0x424a9b['fields'],{'id':_0x424a9b[_0x620035('0x1301')][_0x620035('0x1143')]}));})['catch'](function(_0x200897){const _0x40ac53=_0x566a6b;_0x424a9b[_0x40ac53('0x606')]=![],console[_0x40ac53('0xfc9')](_0x200897);});function _0x5cc078(){const _0x176fc3=_0x566a6b;_0x424a9b[_0x176fc3('0x61a')]=[],_0x424a9b['customField']&&(_0x424a9b[_0x176fc3('0x1301')][_0x176fc3('0x1143')]=_0x424a9b[_0x176fc3('0x117e')]['id'],_0x424a9b[_0x176fc3('0x1301')][_0x176fc3('0x3c0')]=_0x424a9b[_0x176fc3('0x117e')][_0x176fc3('0x4f0')],_0x424a9b[_0x176fc3('0x1301')][_0x176fc3('0x117e')]=_0x424a9b[_0x176fc3('0x117e')][_0x176fc3('0x2853')]),_0x530b9f['intSugarcrmField'][_0x176fc3('0x9cc')](_0x424a9b[_0x176fc3('0x1301')])[_0x176fc3('0xa44')][_0x176fc3('0x1166')](function(_0x41b70b){const _0x45483a=_0x176fc3;_0x424a9b['items'][_0x45483a('0x2450')](_0x41b70b),_0x16c3a5[_0x45483a('0x103b')]({'title':_0x2cfb05()[_0x45483a('0x92c')](_0x3223c3)+'\x20properly\x20created','msg':_0x2cfb05()['capitalize'](_0x3223c3)+_0x45483a('0x1eda')}),_0x4a36f4();})['catch'](function(_0x5aeefe){const _0x194da1=_0x176fc3;console[_0x194da1('0xfc9')](_0x5aeefe),_0x424a9b[_0x194da1('0x61a')]=_0x5aeefe[_0x194da1('0x25f4')][_0x194da1('0x61a')]||[{'message':_0x5aeefe[_0x194da1('0x1586')](),'type':_0x194da1('0x215d')}];});}function _0x19c706(){const _0x212522=_0x566a6b;_0x424a9b[_0x212522('0x61a')]=[],_0x424a9b[_0x212522('0x117e')]&&(_0x424a9b[_0x212522('0x1301')]['idField']=_0x424a9b[_0x212522('0x117e')]['id'],_0x424a9b['item'][_0x212522('0x3c0')]=_0x424a9b[_0x212522('0x117e')][_0x212522('0x4f0')],_0x424a9b[_0x212522('0x1301')][_0x212522('0x117e')]=_0x424a9b['customField'][_0x212522('0x2853')]),_0x530b9f[_0x212522('0xb3d')][_0x212522('0x1449')]({'id':_0x424a9b[_0x212522('0x1301')]['id']},_0x424a9b[_0x212522('0x1301')])[_0x212522('0xa44')][_0x212522('0x1166')](function(_0x3ab688){const _0x8a4b98=_0x212522,_0x2333dc=_0x2cfb05()[_0x8a4b98('0xc38')](_0x424a9b[_0x8a4b98('0xbd7')],{'id':_0x3ab688['id']});_0x2333dc&&_0x2cfb05()['merge'](_0x2333dc,_0x3ab688),_0x16c3a5['success']({'title':_0x2cfb05()[_0x8a4b98('0x92c')](_0x3223c3)+'\x20properly\x20saved!','msg':_0x2cfb05()['capitalize'](_0x3223c3)+_0x8a4b98('0x7d')}),_0x4a36f4();})['catch'](function(_0x15f7ea){const _0x2985f1=_0x212522;console[_0x2985f1('0xfc9')](_0x15f7ea),_0x424a9b[_0x2985f1('0x61a')]=_0x15f7ea[_0x2985f1('0x25f4')][_0x2985f1('0x61a')]||[{'message':_0x15f7ea[_0x2985f1('0x1586')](),'type':_0x2985f1('0x10cd')}];});}function _0x3c89a7(_0x543d87){const _0x372f95=_0x566a6b;_0x424a9b[_0x372f95('0x61a')]=[];const _0x3412ca=_0x392076[_0x372f95('0x1d26')]()[_0x372f95('0xcdc')](_0x372f95('0x7fb'))[_0x372f95('0xacc')](_0x372f95('0x135f')+_0x3223c3+_0x372f95('0x3f3'))[_0x372f95('0x8e8')](_0x372f95('0x237c')+_0x2cfb05()['capitalize'](_0x3223c3))['ok'](_0x372f95('0x18'))[_0x372f95('0x3f')]('Cancel')[_0x372f95('0x203b')](_0x543d87);_0x392076[_0x372f95('0x1f80')](_0x3412ca)['then'](function(){const _0x145ef3=_0x372f95;_0x530b9f[_0x145ef3('0xb3d')][_0x145ef3('0x906')]({'id':_0x424a9b[_0x145ef3('0x1301')]['id']})['$promise'][_0x145ef3('0x1166')](function(){const _0xb19cb3=_0x145ef3;_0x2cfb05()[_0xb19cb3('0x127f')](_0x424a9b[_0xb19cb3('0xbd7')],{'id':_0x424a9b[_0xb19cb3('0x1301')]['id']}),_0x16c3a5['success']({'title':_0x2cfb05()[_0xb19cb3('0x92c')](_0x3223c3)+_0xb19cb3('0x450'),'msg':_0x2cfb05()['capitalize'](_0x3223c3)+_0xb19cb3('0x7cd')}),_0x4a36f4();})[_0x145ef3('0x1a80')](function(_0xedb2ab){const _0xf97db1=_0x145ef3;console[_0xf97db1('0xfc9')](_0xedb2ab),_0x424a9b[_0xf97db1('0x61a')]=_0xedb2ab[_0xf97db1('0x25f4')][_0xf97db1('0x61a')]||[{'message':_0xedb2ab['toString'](),'type':_0xf97db1('0x2602')}];});},function(){});}function _0x215422(){const _0x516751=_0x566a6b;return _0x424a9b[_0x516751('0x1301')]['variableName']!==undefined?_0x424a9b[_0x516751('0x1301')][_0x516751('0xbdb')]:_0x516751('0x16a4');}function _0x4a36f4(){const _0x5009a0=_0x566a6b;_0x392076[_0x5009a0('0x1197')]();}}const _0xabb42d=_0x4bbf79;_0x44ce15[_0x36e6f4('0x1294')]=['$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$translate',_0x36e6f4('0x5c9'),'setting','api',_0x36e6f4('0x1d2e'),'Auth','sugarcrmAccount',_0x36e6f4('0x17aa')];function _0x44ce15(_0x119948,_0x5c3261,_0x105df0,_0x1044fd,_0x497f49,_0x205a66,_0xed1945,_0x1cfc72,_0x179641,_0x13f169,_0x3c4ad3,_0x39c8c3){const _0x26f830=_0x36e6f4,_0x31defd=this;_0x31defd[_0x26f830('0x98')]=_0x13f169[_0x26f830('0x26cd')](),_0x31defd[_0x26f830('0x5c9')]=_0x205a66,_0x31defd[_0x26f830('0xf8a')]=_0xed1945,_0x31defd['passwordPattern']=_0x31defd[_0x26f830('0xf8a')][_0x26f830('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x31defd['location']=_0x5c3261[_0x26f830('0x6f1')]()+_0x26f830('0xc51')+_0x5c3261[_0x26f830('0x1690')](),_0x31defd[_0x26f830('0x13b7')]=_0x3c4ad3||_0x119948[_0x26f830('0x23f')]['sugarcrmAccount']||{},_0x31defd[_0x26f830('0x17aa')]=_0x39c8c3&&_0x39c8c3[_0x26f830('0x240f')]==0x1?_0x39c8c3[_0x26f830('0x269a')][0x0]:null,_0x31defd['crudPermissions']=_0x13f169[_0x26f830('0xd87')](_0x31defd[_0x26f830('0x17aa')]?_0x31defd[_0x26f830('0x17aa')][_0x26f830('0x243c')]:null),_0x31defd[_0x26f830('0x128b')]={},_0x31defd[_0x26f830('0x2669')]=_0x119948[_0x26f830('0x23f')][_0x26f830('0xbe3')]||0x0,_0x31defd[_0x26f830('0x31d')]=_0x179641['info'],_0x31defd[_0x26f830('0x18f5')]=_0x17e229,_0x31defd['saveSugarcrmAccount']=_0x100ca5;function _0x17e229(){const _0x56ca31=_0x26f830;_0x119948['go']('app.integrations.sugarcrmAccounts',{},{'reload':_0x56ca31('0xc98')});}function _0x100ca5(){const _0x5f24e3=_0x26f830;_0x1cfc72[_0x5f24e3('0x13d9')]['update']({'id':_0x31defd[_0x5f24e3('0x13b7')]['id']},_0x31defd[_0x5f24e3('0x13b7')])['$promise'][_0x5f24e3('0x1166')](function(){const _0xfbabdf=_0x5f24e3;_0x179641[_0xfbabdf('0x103b')]({'title':_0xfbabdf('0x1e9a'),'msg':_0x31defd[_0xfbabdf('0x13b7')]['name']?_0x31defd[_0xfbabdf('0x13b7')]['name']+_0xfbabdf('0xa17'):''});})[_0x5f24e3('0x1a80')](function(_0x391e82){const _0x540f22=_0x5f24e3;_0x179641[_0x540f22('0xfc9')]({'title':_0x391e82[_0x540f22('0x52d')]?'API:'+_0x391e82[_0x540f22('0x52d')]+_0x540f22('0x11e1')+_0x391e82[_0x540f22('0xe1b')]:_0x540f22('0x13f1'),'msg':_0x391e82[_0x540f22('0x25f4')]?JSON[_0x540f22('0xbac')](_0x391e82[_0x540f22('0x25f4')]):_0x391e82['toString']()});});}}const _0x409c8d=_0x44ce15,_0x446bc3=_0x2734b2['p']+_0x36e6f4('0x9dd');_0x47d5b6[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x1074'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x47d5b6(_0x3eb401,_0x3c14e1,_0x4e7680,_0x373858,_0x53150d,_0x3e32aa,_0x566da7,_0x4e3d81,_0x1fd692,_0x368d74,_0x20bb91,_0x4f5ef0,_0x2fecba,_0x39dd64,_0x4b98dc,_0x58ceb8,_0x208a6f){const _0x13b459=_0x36e6f4,_0x49c3bb=this;_0x49c3bb[_0x13b459('0x5c9')]=_0x58ceb8,_0x49c3bb[_0x13b459('0xf8a')]=_0x208a6f,_0x49c3bb[_0x13b459('0x98')]=_0x4b98dc['getCurrentUser'](),_0x49c3bb[_0x13b459('0x1074')]=_0x1fd692||{'count':0x0,'rows':[]},_0x49c3bb['userProfile']=_0x368d74,_0x49c3bb[_0x13b459('0x17aa')]=_0x20bb91&&_0x20bb91['count']==0x1?_0x20bb91[_0x13b459('0x269a')][0x0]:null,_0x49c3bb[_0x13b459('0x243c')]=_0x4b98dc[_0x13b459('0xd87')](_0x49c3bb[_0x13b459('0x17aa')]?_0x49c3bb[_0x13b459('0x17aa')][_0x13b459('0x243c')]:null),_0x49c3bb[_0x13b459('0x916')]=_0x13b459('0x1074'),_0x49c3bb['listOrder']='',_0x49c3bb[_0x13b459('0x104c')]=null,_0x49c3bb['selectedSugarcrmAccounts']=[],_0x49c3bb[_0x13b459('0x2218')]={'fields':'createdAt,updatedAt,id,name,username,remoteUri,password,serverUrl,description','limit':0xa,'page':0x1},_0x49c3bb[_0x13b459('0x1ff6')]=_0x11b720,_0x49c3bb[_0x13b459('0x2113')]=_0x19aff2,_0x49c3bb['deleteconfirm']=_0x5b1b8c,_0x49c3bb[_0x13b459('0x103b')]=_0x1049a2,_0x49c3bb[_0x13b459('0x27ba')]=_0x39898d,_0x49c3bb['createOrEditSugarcrmAccount']=_0x4e310b,_0x49c3bb['deleteSugarcrmAccount']=_0x58ac7c,_0x49c3bb['exportSelectedSugarcrmAccounts']=_0x462f75,_0x49c3bb[_0x13b459('0x804')]=_0x5a0776,_0x49c3bb['deselectSugarcrmAccounts']=_0x18d5e2,_0x49c3bb[_0x13b459('0x477')]=_0x161b0b;function _0x11b720(_0x2fb41c){const _0x4eaabe=_0x13b459;_0x4e7680['go'](_0x4eaabe('0x207'),{'id':_0x2fb41c['id'],'sugarcrmAccount':_0x2fb41c,'crudPermissions':_0x49c3bb[_0x4eaabe('0x243c')]});}function _0x19aff2(_0x53e63a){const _0x2cdbe0=_0x13b459;return _0x4f5ef0['intSugarcrmAccount'][_0x2cdbe0('0x18ea')]({'id':_0x53e63a['id'],'test':!![]})['$promise'][_0x2cdbe0('0x1166')](function(){_0x39dd64['success']({'title':'SugarcrmAccount\x20properly\x20tested','msg':'Connection\x20succeded!'});})[_0x2cdbe0('0x1a80')](function(_0x4895cb){const _0x27e8e9=_0x2cdbe0;_0x39dd64[_0x27e8e9('0xfc9')]({'title':_0x27e8e9('0xde4'),'msg':_0x4895cb[_0x27e8e9('0x25f4')]?_0x4895cb[_0x27e8e9('0x25f4')][_0x27e8e9('0x1e70')]?_0x4895cb['data'][_0x27e8e9('0x1e70')]:JSON[_0x27e8e9('0xbac')](_0x4895cb[_0x27e8e9('0x25f4')]):_0x4895cb[_0x27e8e9('0x1586')]()});});}function _0x5b1b8c(_0xfadf0,_0x24f407){const _0x5cbf7e=_0x13b459,_0x52012b=_0x53150d[_0x5cbf7e('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x5cbf7e('0xb35')](_0x5cbf7e('0x13b7'))+'?')[_0x5cbf7e('0xf3c')](''+(_0xfadf0[_0x5cbf7e('0x4f0')]||_0x5cbf7e('0x13b7'))+_0x5cbf7e('0xace')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x5cbf7e('0x1dd4'))[_0x5cbf7e('0x203b')](_0x24f407)['ok']('OK')['cancel'](_0x5cbf7e('0x2d3'));_0x53150d[_0x5cbf7e('0x1f80')](_0x52012b)[_0x5cbf7e('0x1166')](function(){_0x58ac7c(_0xfadf0);},function(){const _0xe914aa=_0x5cbf7e;console[_0xe914aa('0x455')](_0xe914aa('0x2d3'));});}let _0x480842=!![],_0x341a4c=0x1;_0x3eb401['$watch'](_0x13b459('0x12d8'),function(_0xf2fd84,_0x28bb4c){const _0x2b4db7=_0x13b459;_0x480842?_0x566da7(function(){_0x480842=![];}):(!_0x28bb4c&&(_0x341a4c=_0x49c3bb[_0x2b4db7('0x2218')][_0x2b4db7('0x1a43')]),_0xf2fd84!==_0x28bb4c&&(_0x49c3bb[_0x2b4db7('0x2218')]['page']=0x1),!_0xf2fd84&&(_0x49c3bb[_0x2b4db7('0x2218')][_0x2b4db7('0x1a43')]=_0x341a4c),_0x49c3bb[_0x2b4db7('0x27ba')]());});function _0x1049a2(_0x14de4a){const _0xaf18b2=_0x13b459;_0x49c3bb[_0xaf18b2('0x1074')]=_0x14de4a||{'count':0x0,'rows':[]};}function _0x39898d(){const _0xf9fd2d=_0x13b459;_0x49c3bb[_0xf9fd2d('0x2218')][_0xf9fd2d('0x1098')]=(_0x49c3bb[_0xf9fd2d('0x2218')][_0xf9fd2d('0x1a43')]-0x1)*_0x49c3bb['query'][_0xf9fd2d('0x163f')],_0x4b98dc[_0xf9fd2d('0x1ac6')](_0xf9fd2d('0xa7c'))?_0x49c3bb[_0xf9fd2d('0x1f48')]=_0x4f5ef0[_0xf9fd2d('0x13d9')][_0xf9fd2d('0xd83')](_0x49c3bb[_0xf9fd2d('0x2218')],_0x1049a2)[_0xf9fd2d('0xa44')]:(_0x49c3bb[_0xf9fd2d('0x2218')]['id']=_0x49c3bb[_0xf9fd2d('0x7f')]['id'],_0x49c3bb[_0xf9fd2d('0x2218')][_0xf9fd2d('0xe60')]=_0xf9fd2d('0xe20'),_0x49c3bb[_0xf9fd2d('0x1f48')]=_0x4f5ef0[_0xf9fd2d('0x7f')]['getResources'](_0x49c3bb[_0xf9fd2d('0x2218')],_0x1049a2)[_0xf9fd2d('0xa44')]);}function _0x4e310b(_0x27394a,_0xffdda){const _0x591563=_0x13b459;_0x53150d[_0x591563('0x1f80')]({'controller':'CreateOrEditSugarcrmAccountDialogController','controllerAs':'vm','templateUrl':_0x446bc3,'parent':angular['element'](_0x3e32aa[_0x591563('0x8d2')]),'targetEvent':_0x27394a,'clickOutsideToClose':!![],'locals':{'sugarcrmAccount':_0xffdda,'sugarcrmAccounts':_0x49c3bb[_0x591563('0x1074')][_0x591563('0x269a')],'license':_0x49c3bb[_0x591563('0x5c9')],'setting':_0x49c3bb['setting'],'crudPermissions':_0x49c3bb[_0x591563('0x243c')]}});}function _0x58ac7c(_0x2ed103){const _0x45f0f4=_0x13b459;_0x4f5ef0[_0x45f0f4('0x13d9')]['delete']({'id':_0x2ed103['id']})[_0x45f0f4('0xa44')][_0x45f0f4('0x1166')](function(){const _0x56d2d5=_0x45f0f4;_0x2cfb05()[_0x56d2d5('0x127f')](_0x49c3bb[_0x56d2d5('0x1074')][_0x56d2d5('0x269a')],{'id':_0x2ed103['id']}),_0x49c3bb[_0x56d2d5('0x1074')]['count']-=0x1,!_0x49c3bb[_0x56d2d5('0x1074')][_0x56d2d5('0x269a')]['length']&&_0x49c3bb[_0x56d2d5('0x27ba')](),_0x39dd64[_0x56d2d5('0x103b')]({'title':_0x2cfb05()['startCase'](_0x56d2d5('0x993'))+'\x20deleted!','msg':_0x2ed103[_0x56d2d5('0x4f0')]?_0x2ed103[_0x56d2d5('0x4f0')]+'\x20has\x20been\x20deleted!':''});})[_0x45f0f4('0x1a80')](function(_0x1d8ba2){const _0x1acfdd=_0x45f0f4;if(_0x1d8ba2['data']&&_0x1d8ba2['data'][_0x1acfdd('0x61a')]&&_0x1d8ba2[_0x1acfdd('0x25f4')]['errors']['length']){_0x49c3bb['errors']=_0x1d8ba2[_0x1acfdd('0x25f4')][_0x1acfdd('0x61a')]||[{'message':_0x1d8ba2['toString'](),'type':_0x1acfdd('0x142')}];for(let _0x37d29d=0x0;_0x37d29d<_0x1d8ba2['data'][_0x1acfdd('0x61a')][_0x1acfdd('0x264b')];_0x37d29d++){_0x39dd64['error']({'title':_0x1d8ba2['data'][_0x1acfdd('0x61a')][_0x37d29d][_0x1acfdd('0x1345')],'msg':_0x1d8ba2[_0x1acfdd('0x25f4')][_0x1acfdd('0x61a')][_0x37d29d][_0x1acfdd('0x1e70')]});}}else _0x39dd64[_0x1acfdd('0xfc9')]({'title':_0x1d8ba2[_0x1acfdd('0x52d')]?_0x1acfdd('0x1e21')+_0x1d8ba2['status']+_0x1acfdd('0x11e1')+_0x1d8ba2[_0x1acfdd('0xe1b')]:_0x1acfdd('0x142'),'msg':_0x1d8ba2[_0x1acfdd('0x25f4')]?JSON[_0x1acfdd('0xbac')](_0x1d8ba2[_0x1acfdd('0x25f4')]['message']):_0x1d8ba2[_0x1acfdd('0x1e70')]||_0x1d8ba2[_0x1acfdd('0x1586')]()});});}function _0x462f75(){const _0x546cd0=_0x13b459,_0x5002fd=angular[_0x546cd0('0x225f')](_0x49c3bb[_0x546cd0('0xa45')]);return _0x49c3bb[_0x546cd0('0xa45')]=[],_0x5002fd;}function _0x5a0776(_0x4c6d92){const _0x5ce8e6=_0x13b459,_0x2be130=_0x53150d[_0x5ce8e6('0x1d26')]()[_0x5ce8e6('0xcdc')](_0x5ce8e6('0xdee'))[_0x5ce8e6('0xf3c')](_0x5ce8e6('0x12b5')+_0x49c3bb[_0x5ce8e6('0xa45')][_0x5ce8e6('0x264b')]+'\x20selected'+_0x5ce8e6('0x3f3'))[_0x5ce8e6('0x8e8')](_0x5ce8e6('0x119c'))[_0x5ce8e6('0x203b')](_0x4c6d92)['ok']('OK')['cancel'](_0x5ce8e6('0x2d3'));_0x53150d[_0x5ce8e6('0x1f80')](_0x2be130)[_0x5ce8e6('0x1166')](function(){const _0xbb6abd=_0x5ce8e6;_0x49c3bb[_0xbb6abd('0xa45')][_0xbb6abd('0x2782')](function(_0x426176){_0x58ac7c(_0x426176);}),_0x49c3bb['selectedSugarcrmAccounts']=[];});}function _0x18d5e2(){const _0x57f5f=_0x13b459;_0x49c3bb[_0x57f5f('0xa45')]=[];}function _0x161b0b(){const _0x536f55=_0x13b459;_0x49c3bb[_0x536f55('0xa45')]=_0x49c3bb['sugarcrmAccounts'][_0x536f55('0x269a')];}}const _0x2c91dd=_0x47d5b6;_0x3c3f71[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'vtigerAccounts','vtigerAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting','crudPermissions'];function _0x3c3f71(_0x4de712,_0x312935,_0x473f77,_0x308463,_0x5549df,_0x1ef33c,_0x3ff658,_0x4298b9,_0x6994fb,_0x3347fc,_0x3e9f04,_0x43bb9f,_0x5c2419,_0x5832e9){const _0x2dc5f8=_0x36e6f4,_0x430fdf=this;_0x430fdf[_0x2dc5f8('0x98')]=_0x3e9f04[_0x2dc5f8('0x26cd')](),_0x430fdf['errors']=[],_0x430fdf['setting']=_0x5c2419,_0x430fdf['license']=_0x43bb9f,_0x430fdf[_0x2dc5f8('0x243c')]=_0x5832e9,_0x430fdf[_0x2dc5f8('0x128b')]={},_0x430fdf[_0x2dc5f8('0x2900')]=_0x430fdf['setting']&&_0x430fdf[_0x2dc5f8('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x430fdf[_0x2dc5f8('0xcdc')]=_0x2dc5f8('0x22ac'),_0x430fdf[_0x2dc5f8('0x225c')]=angular[_0x2dc5f8('0x225f')](_0x6994fb),_0x430fdf[_0x2dc5f8('0x101b')]=_0x4298b9,_0x430fdf[_0x2dc5f8('0x1e90')]=![];!_0x430fdf[_0x2dc5f8('0x225c')]&&(_0x430fdf[_0x2dc5f8('0x225c')]={'serverUrl':_0x473f77[_0x2dc5f8('0x6f1')]()+'://'+_0x473f77[_0x2dc5f8('0x1690')]()+(_0x473f77[_0x2dc5f8('0x93d')]()?':'+_0x473f77[_0x2dc5f8('0x93d')]():'')},_0x430fdf[_0x2dc5f8('0xcdc')]=_0x2dc5f8('0x27e'),_0x430fdf[_0x2dc5f8('0x1e90')]=!![]);_0x430fdf[_0x2dc5f8('0x821')]=_0x1d3080,_0x430fdf[_0x2dc5f8('0x1bba')]=_0x234e37,_0x430fdf[_0x2dc5f8('0x2197')]=_0x3c60c8,_0x430fdf[_0x2dc5f8('0x1a9c')]=_0x1564f5,_0x430fdf[_0x2dc5f8('0x24a0')]=_0x329626;function _0x1d3080(){const _0x50fa85=_0x2dc5f8;_0x430fdf['errors']=[],_0x3347fc[_0x50fa85('0x1b52')][_0x50fa85('0x9cc')](_0x430fdf[_0x50fa85('0x225c')])[_0x50fa85('0xa44')][_0x50fa85('0x1166')](function(_0x379aa8){const _0x561aef=_0x50fa85;_0x430fdf['vtigerAccounts']['unshift'](_0x379aa8['toJSON']()),_0x3ff658[_0x561aef('0x103b')]({'title':_0x561aef('0x143b'),'msg':_0x430fdf[_0x561aef('0x225c')]['name']?_0x430fdf[_0x561aef('0x225c')]['name']+_0x561aef('0x1eda'):''}),_0x329626(_0x379aa8);})[_0x50fa85('0x1a80')](function(_0x119c1e){const _0x434152=_0x50fa85;if(_0x119c1e['data']&&_0x119c1e[_0x434152('0x25f4')][_0x434152('0x61a')]&&_0x119c1e[_0x434152('0x25f4')][_0x434152('0x61a')][_0x434152('0x264b')]){_0x430fdf[_0x434152('0x61a')]=_0x119c1e[_0x434152('0x25f4')][_0x434152('0x61a')]||[{'message':_0x119c1e[_0x434152('0x1586')](),'type':_0x434152('0x1d9c')}];for(let _0x302c1d=0x0;_0x302c1d<_0x119c1e[_0x434152('0x25f4')][_0x434152('0x61a')][_0x434152('0x264b')];_0x302c1d+=0x1){_0x3ff658['error']({'title':_0x119c1e['data'][_0x434152('0x61a')][_0x302c1d][_0x434152('0x1345')],'msg':_0x119c1e[_0x434152('0x25f4')][_0x434152('0x61a')][_0x302c1d]['message']});}}else _0x3ff658[_0x434152('0xfc9')]({'title':_0x119c1e[_0x434152('0x52d')]?'API:'+_0x119c1e['status']+_0x434152('0x11e1')+_0x119c1e[_0x434152('0xe1b')]:_0x434152('0x1d9c'),'msg':_0x119c1e[_0x434152('0x25f4')]?JSON['stringify'](_0x119c1e[_0x434152('0x25f4')]['message']):_0x119c1e[_0x434152('0x1586')]()});});}function _0x234e37(){const _0x1fb0af=_0x2dc5f8;_0x430fdf[_0x1fb0af('0x61a')]=[],_0x3347fc['intVtigerAccount']['update']({'id':_0x430fdf[_0x1fb0af('0x225c')]['id']},_0x430fdf[_0x1fb0af('0x225c')])[_0x1fb0af('0xa44')][_0x1fb0af('0x1166')](function(_0x2098d9){const _0x44e590=_0x1fb0af,_0x2440ad=_0x2cfb05()['find'](_0x430fdf[_0x44e590('0x101b')],{'id':_0x2098d9['id']});_0x2440ad&&_0x2cfb05()['merge'](_0x2440ad,_0x2cfb05()['pick'](_0x2098d9[_0x44e590('0x2876')](),_0x2cfb05()[_0x44e590('0x14a4')](_0x2440ad))),_0x3ff658[_0x44e590('0x103b')]({'title':_0x44e590('0xe5c'),'msg':_0x430fdf[_0x44e590('0x225c')][_0x44e590('0x4f0')]?_0x430fdf[_0x44e590('0x225c')][_0x44e590('0x4f0')]+_0x44e590('0x7d'):''}),_0x329626(_0x2098d9);})['catch'](function(_0x308073){const _0x151937=_0x1fb0af;if(_0x308073[_0x151937('0x25f4')]&&_0x308073['data']['errors']&&_0x308073[_0x151937('0x25f4')]['errors']['length']){_0x430fdf['errors']=_0x308073[_0x151937('0x25f4')]['errors']||[{'message':_0x308073[_0x151937('0x1586')](),'type':_0x151937('0x5bb')}];for(let _0x452ca5=0x0;_0x452ca5<_0x308073[_0x151937('0x25f4')][_0x151937('0x61a')][_0x151937('0x264b')];_0x452ca5++){_0x3ff658[_0x151937('0xfc9')]({'title':_0x308073[_0x151937('0x25f4')][_0x151937('0x61a')][_0x452ca5][_0x151937('0x1345')],'msg':_0x308073[_0x151937('0x25f4')]['errors'][_0x452ca5][_0x151937('0x1e70')]});}}else _0x3ff658[_0x151937('0xfc9')]({'title':_0x308073[_0x151937('0x52d')]?_0x151937('0x1e21')+_0x308073[_0x151937('0x52d')]+_0x151937('0x11e1')+_0x308073[_0x151937('0xe1b')]:_0x151937('0x5bb'),'msg':_0x308073['data']?JSON[_0x151937('0xbac')](_0x308073[_0x151937('0x25f4')][_0x151937('0x1e70')]):_0x308073[_0x151937('0x1586')]()});});}function _0x3c60c8(_0x45022e){const _0x270c43=_0x2dc5f8;_0x430fdf['errors']=[];const _0x2d2d21=_0x308463[_0x270c43('0x1d26')]()[_0x270c43('0xcdc')]('Are\x20you\x20sure?')[_0x270c43('0xacc')](_0x270c43('0xe4d'))['ariaLabel']('Delete\x20VtigerAccount')['ok'](_0x270c43('0x18'))[_0x270c43('0x3f')]('Cancel')[_0x270c43('0x203b')](_0x45022e);_0x308463[_0x270c43('0x1f80')](_0x2d2d21)[_0x270c43('0x1166')](function(){const _0x351ddc=_0x270c43;_0x3347fc[_0x351ddc('0x1b52')]['delete']({'id':_0x430fdf['vtigerAccount']['id']})[_0x351ddc('0xa44')][_0x351ddc('0x1166')](function(){const _0x570c9e=_0x351ddc;_0x2cfb05()[_0x570c9e('0x127f')](_0x430fdf[_0x570c9e('0x101b')],{'id':_0x430fdf['vtigerAccount']['id']}),_0x3ff658[_0x570c9e('0x103b')]({'title':_0x570c9e('0x20da'),'msg':(_0x430fdf['vtigerAccount']['name']||'vtigerAccount')+_0x570c9e('0x7cd')}),_0x329626(_0x430fdf[_0x570c9e('0x225c')]);})['catch'](function(_0x539f81){const _0x1b6407=_0x351ddc;if(_0x539f81[_0x1b6407('0x25f4')]&&_0x539f81[_0x1b6407('0x25f4')][_0x1b6407('0x61a')]&&_0x539f81[_0x1b6407('0x25f4')][_0x1b6407('0x61a')][_0x1b6407('0x264b')]){_0x430fdf['errors']=_0x539f81[_0x1b6407('0x25f4')][_0x1b6407('0x61a')]||[{'message':_0x539f81['toString'](),'type':'api.intVtigerAccount.delete'}];for(let _0x4d5d4b=0x0;_0x4d5d4b<_0x539f81[_0x1b6407('0x25f4')]['errors'][_0x1b6407('0x264b')];_0x4d5d4b++){_0x3ff658['error']({'title':_0x539f81['data'][_0x1b6407('0x61a')][_0x4d5d4b][_0x1b6407('0x1345')],'msg':_0x539f81[_0x1b6407('0x25f4')]['errors'][_0x4d5d4b]['message']});}}else _0x3ff658[_0x1b6407('0xfc9')]({'title':_0x539f81[_0x1b6407('0x52d')]?_0x1b6407('0x1e21')+_0x539f81[_0x1b6407('0x52d')]+'\x20-\x20'+_0x539f81[_0x1b6407('0xe1b')]:_0x1b6407('0x2898'),'msg':_0x539f81['data']?JSON[_0x1b6407('0xbac')](_0x539f81['data']['message']):_0x539f81[_0x1b6407('0x1e70')]||_0x539f81[_0x1b6407('0x1586')]()});});},function(){});}function _0x1564f5(_0x4bc814){return _0x4bc814===null?undefined:new Date(_0x4bc814);}function _0x329626(_0xf575ff){_0x308463['hide'](_0xf575ff);}}const _0x2e70a7=_0x3c3f71,_0x3989e8=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/vtigerAccounts/edit/configurations/dialog.html/dialog.html',_0x471b39=_0x2734b2['p']+_0x36e6f4('0x157a');_0x180768['$inject']=[_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x19e3'),'toasty',_0x36e6f4('0x21ef')];function _0x180768(_0x82f774,_0x49c6aa,_0x4a2b29,_0x3083f0,_0x13d0fb){const _0xf64a7=_0x36e6f4,_0x94267b=this;_0x94267b[_0xf64a7('0x98')]=_0x13d0fb['getCurrentUser'](),_0x94267b['vtigerAccount']={},_0x94267b[_0xf64a7('0xe91')]={},_0x94267b['configurations']=[],_0x94267b[_0xf64a7('0x70d')]=-0x1,_0x94267b[_0xf64a7('0x243c')],_0x94267b[_0xf64a7('0x24d5')]=_0x4cb35a,_0x94267b[_0xf64a7('0x1128')]=_0x4e3628,_0x94267b['createOrEditVtigerConfiguration']=_0x17d2f4,_0x94267b[_0xf64a7('0x189a')]=_0x736414;function _0x4cb35a(_0x1bea39,_0x1fd3df){const _0x571e6b=_0xf64a7;_0x94267b['vtigerAccount']=_0x1bea39,_0x94267b[_0x571e6b('0x243c')]=typeof _0x1fd3df!==_0x571e6b('0x1048')?_0x1fd3df:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4a2b29[_0x571e6b('0x1b52')]['getConfigurations']({'id':_0x94267b[_0x571e6b('0x225c')]['id'],'sort':_0x571e6b('0x14dc')})[_0x571e6b('0xa44')][_0x571e6b('0x1166')](function(_0x1184a8){const _0x2a941c=_0x571e6b;return _0x94267b[_0x2a941c('0xd54')]=_0x1184a8[_0x2a941c('0x269a')]?_0x1184a8[_0x2a941c('0x269a')]:[],_0x94267b['configurations']['length']&&_0x94267b['getVtigerConfiguration'](0x0),_0x4a2b29[_0x2a941c('0x734')][_0x2a941c('0xd83')]({'nolimit':!![],'sort':_0x2a941c('0x4f0')})[_0x2a941c('0xa44')];})[_0x571e6b('0x1166')](function(_0x2373c6){const _0x51bac6=_0x571e6b;_0x94267b[_0x51bac6('0x57a')]=_0x2373c6[_0x51bac6('0x269a')]?_0x2373c6[_0x51bac6('0x269a')]:[],_0x94267b[_0x51bac6('0x217a')]=_0x2cfb05()[_0x51bac6('0x155c')](_0x94267b[_0x51bac6('0x57a')],'id');})[_0x571e6b('0x1a80')](function(_0x27c1ed){const _0x258256=_0x571e6b;_0x3083f0[_0x258256('0xfc9')]({'title':_0x27c1ed[_0x258256('0x52d')]?_0x258256('0x1e21')+_0x27c1ed[_0x258256('0x52d')]+_0x258256('0x11e1')+_0x27c1ed['statusText']:_0x258256('0x17ab'),'msg':_0x27c1ed['data']?JSON[_0x258256('0xbac')](_0x27c1ed[_0x258256('0x25f4')]):_0x27c1ed['toString']()});});}function _0x4e3628(_0x30fcb7){const _0x4d9b63=_0xf64a7;_0x94267b['vtigerConfiguration']=_0x94267b[_0x4d9b63('0xd54')][_0x30fcb7],_0x94267b[_0x4d9b63('0x70d')]=_0x30fcb7,_0x4a2b29[_0x4d9b63('0x2582')][_0x4d9b63('0x154d')]({'id':_0x94267b[_0x4d9b63('0xe91')]['id']})[_0x4d9b63('0xa44')][_0x4d9b63('0x1166')](function(_0x6ccd0e){const _0x1a2398=_0x4d9b63;return _0x94267b[_0x1a2398('0x2701')]=_0x6ccd0e[_0x1a2398('0x269a')]?_0x6ccd0e['rows']:[],_0x4a2b29[_0x1a2398('0x2582')][_0x1a2398('0x28d4')]({'id':_0x94267b['vtigerConfiguration']['id']})[_0x1a2398('0xa44')];})['then'](function(_0x410987){const _0x43f922=_0x4d9b63;return _0x94267b[_0x43f922('0x1b3d')]=_0x410987['rows']?_0x410987['rows']:[],_0x4a2b29['intVtigerConfiguration']['getFields']({'id':_0x94267b[_0x43f922('0xe91')]['id']})['$promise'];})[_0x4d9b63('0x1166')](function(_0xf615ca){_0x94267b['fields']=_0xf615ca['rows']?_0xf615ca['rows']:[];})[_0x4d9b63('0x1a80')](function(_0x2b0a54){const _0x83dca6=_0x4d9b63;_0x3083f0[_0x83dca6('0xfc9')]({'title':_0x2b0a54[_0x83dca6('0x52d')]?_0x83dca6('0x1e21')+_0x2b0a54['status']+'\x20-\x20'+_0x2b0a54[_0x83dca6('0xe1b')]:'SYSTEM:GETConfigurations','msg':_0x2b0a54[_0x83dca6('0x25f4')]?JSON[_0x83dca6('0xbac')](_0x2b0a54[_0x83dca6('0x25f4')]):_0x2b0a54[_0x83dca6('0x1586')]()});});}function _0x17d2f4(_0x47cd64,_0x1a0a0d){const _0x55239f=_0xf64a7;_0x82f774[_0x55239f('0x1f80')]({'controller':_0x55239f('0x1d31'),'controllerAs':'vm','templateUrl':_0x3989e8,'parent':angular['element'](_0x49c6aa['body']),'targetEvent':_0x47cd64,'clickOutsideToClose':!![],'locals':{'vtigerConfiguration':_0x1a0a0d,'configurations':_0x94267b['configurations'],'license':null,'setting':null,'crudPermissions':_0x94267b[_0x55239f('0x243c')]}})[_0x55239f('0x1951')](function(){_0x94267b['getVtigerConfiguration'](0x0);});}function _0x736414(_0x3da6ba,_0xd8dc03){const _0x59fe3a=_0xf64a7,_0x2caac5=_0x82f774[_0x59fe3a('0x1d26')]()[_0x59fe3a('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20vtigerConfiguration?')['htmlContent'](_0x59fe3a('0x12b5')+(_0xd8dc03[_0x59fe3a('0x4f0')]||'vtigerConfiguration')+_0x59fe3a('0xace')+_0x59fe3a('0x3f3'))[_0x59fe3a('0x8e8')](_0x59fe3a('0x80f'))[_0x59fe3a('0x203b')](_0x3da6ba)['ok']('OK')[_0x59fe3a('0x3f')](_0x59fe3a('0x2d3'));_0x82f774[_0x59fe3a('0x1f80')](_0x2caac5)[_0x59fe3a('0x1166')](function(){const _0x352a66=_0x59fe3a;_0x4a2b29[_0x352a66('0x2582')]['delete']({'id':_0xd8dc03['id']})[_0x352a66('0xa44')][_0x352a66('0x1166')](function(){const _0x422b00=_0x352a66;_0x2cfb05()[_0x422b00('0x127f')](_0x94267b['configurations'],{'id':_0xd8dc03['id']}),_0x3083f0[_0x422b00('0x103b')]({'title':_0x422b00('0x1306'),'msg':_0xd8dc03[_0x422b00('0x4f0')]?_0xd8dc03['name']+_0x422b00('0x7cd'):''});})[_0x352a66('0x1a80')](function(_0x2e5957){const _0x51fcb6=_0x352a66;_0x3083f0['error']({'title':_0x2e5957[_0x51fcb6('0x52d')]?_0x51fcb6('0x1e21')+_0x2e5957[_0x51fcb6('0x52d')]+'\x20-\x20'+_0x2e5957[_0x51fcb6('0xe1b')]:'SYSTEM:DELETECONFIGURATION','msg':_0x2e5957['data']?JSON[_0x51fcb6('0xbac')](_0x2e5957[_0x51fcb6('0x25f4')]):_0x2e5957[_0x51fcb6('0x1586')]()});})[_0x352a66('0x1951')](function(){const _0x1236e0=_0x352a66;_0x94267b[_0x1236e0('0x1128')](0x0);});},function(){const _0x2140bd=_0x59fe3a;console['log'](_0x2140bd('0x2d3'));});}_0x94267b[_0xf64a7('0xd02')]=[],_0x94267b[_0xf64a7('0x1a33')]=_0xc4c55b,_0x94267b[_0xf64a7('0x2059')]=_0xefe5d6,_0x94267b[_0xf64a7('0xeff')]=_0x3eb7a1;function _0xc4c55b(_0x189760,_0x24993c){const _0x227cf2=_0xf64a7;_0x82f774[_0x227cf2('0x1f80')]({'controller':_0x227cf2('0x1d4c'),'controllerAs':'vm','templateUrl':_0x471b39,'parent':angular[_0x227cf2('0x1194')](_0x49c6aa[_0x227cf2('0x8d2')]),'targetEvent':_0x189760,'clickOutsideToClose':!![],'locals':{'type':_0x227cf2('0x210d'),'item':_0x24993c,'items':_0x94267b[_0x227cf2('0x2701')],'configuration':_0x94267b[_0x227cf2('0xe91')],'account':_0x94267b[_0x227cf2('0x225c')],'license':null,'setting':null,'crudPermissions':_0x94267b[_0x227cf2('0x243c')]}});}function _0x3a174a(_0x4d020b){const _0x5d1d42=_0xf64a7;_0x4a2b29[_0x5d1d42('0x9c5')][_0x5d1d42('0x906')]({'id':_0x4d020b['id']})[_0x5d1d42('0xa44')][_0x5d1d42('0x1166')](function(){const _0x1003c6=_0x5d1d42;_0x2cfb05()[_0x1003c6('0x127f')](_0x94267b[_0x1003c6('0x2701')],{'id':_0x4d020b['id']}),_0x3083f0['success']({'title':'Subject\x20deleted!','msg':_0x1003c6('0x259f')});})[_0x5d1d42('0x1a80')](function(_0x22904b){const _0x15ae36=_0x5d1d42;_0x3083f0[_0x15ae36('0xfc9')]({'title':_0x22904b[_0x15ae36('0x52d')]?_0x15ae36('0x1e21')+_0x22904b[_0x15ae36('0x52d')]+_0x15ae36('0x11e1')+_0x22904b[_0x15ae36('0xe1b')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x22904b[_0x15ae36('0x25f4')]?JSON[_0x15ae36('0xbac')](_0x22904b['data']):_0x22904b[_0x15ae36('0x1586')]()});});}function _0xefe5d6(_0x2565af,_0x3eb738){const _0x4343c2=_0xf64a7,_0x3398a0=_0x82f774[_0x4343c2('0x1d26')]()[_0x4343c2('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20subject?')['htmlContent'](_0x4343c2('0x277a')+_0x4343c2('0x3f3'))[_0x4343c2('0x8e8')](_0x4343c2('0x87a'))['targetEvent'](_0x2565af)['ok']('OK')[_0x4343c2('0x3f')]('CANCEL');_0x82f774[_0x4343c2('0x1f80')](_0x3398a0)[_0x4343c2('0x1166')](function(){_0x3a174a(_0x3eb738);},function(){const _0x11e2b9=_0x4343c2;console['log'](_0x11e2b9('0x2d3'));});}function _0x3eb7a1(_0x36001c){const _0xd24822=_0xf64a7,_0x5f722d=_0x82f774[_0xd24822('0x1d26')]()[_0xd24822('0xcdc')](_0xd24822('0x1d64'))['htmlContent'](_0xd24822('0x12b5')+_0x94267b[_0xd24822('0xd02')][_0xd24822('0x264b')]+_0xd24822('0x196d')+_0xd24822('0x3f3'))['ariaLabel'](_0xd24822('0x5b2'))[_0xd24822('0x203b')](_0x36001c)['ok']('OK')[_0xd24822('0x3f')]('CANCEL');_0x82f774[_0xd24822('0x1f80')](_0x5f722d)[_0xd24822('0x1166')](function(){const _0x196066=_0xd24822;_0x94267b[_0x196066('0xd02')]['forEach'](function(_0x10669a){_0x3a174a(_0x10669a);}),_0x94267b['selectedSubjects']=[];});}_0x94267b[_0xf64a7('0x968')]=[],_0x94267b[_0xf64a7('0x2185')]=_0x36cace,_0x94267b[_0xf64a7('0xdf3')]=_0x7b570f,_0x94267b['deleteSelectedDescriptions']=_0x25b108;function _0x36cace(_0x3ccfd6,_0x2d8b29){const _0x347b91=_0xf64a7;_0x82f774[_0x347b91('0x1f80')]({'controller':'CreateOrEditVtigerAccountItemDialogController','controllerAs':'vm','templateUrl':_0x471b39,'parent':angular[_0x347b91('0x1194')](_0x49c6aa['body']),'targetEvent':_0x3ccfd6,'clickOutsideToClose':!![],'locals':{'type':_0x347b91('0x101c'),'item':_0x2d8b29,'items':_0x94267b[_0x347b91('0x1b3d')],'configuration':_0x94267b['vtigerConfiguration'],'account':_0x94267b['vtigerAccount'],'license':null,'setting':null,'crudPermissions':_0x94267b[_0x347b91('0x243c')]}});}function _0x2d4ded(_0x2412b9){const _0x5db41d=_0xf64a7;_0x4a2b29['intVtigerField'][_0x5db41d('0x906')]({'id':_0x2412b9['id']})[_0x5db41d('0xa44')]['then'](function(){const _0x168fda=_0x5db41d;_0x2cfb05()[_0x168fda('0x127f')](_0x94267b['descriptions'],{'id':_0x2412b9['id']}),_0x3083f0['success']({'title':_0x168fda('0x9c1'),'msg':_0x168fda('0x12ae')});})[_0x5db41d('0x1a80')](function(_0x22200b){const _0x345c6a=_0x5db41d;_0x3083f0[_0x345c6a('0xfc9')]({'title':_0x22200b['status']?_0x345c6a('0x1e21')+_0x22200b[_0x345c6a('0x52d')]+_0x345c6a('0x11e1')+_0x22200b[_0x345c6a('0xe1b')]:_0x345c6a('0x23ff'),'msg':_0x22200b[_0x345c6a('0x25f4')]?JSON[_0x345c6a('0xbac')](_0x22200b[_0x345c6a('0x25f4')]):_0x22200b[_0x345c6a('0x1586')]()});});}function _0x7b570f(_0x13940b,_0x31654b){const _0x3104bb=_0xf64a7,_0x1a9d19=_0x82f774[_0x3104bb('0x1d26')]()[_0x3104bb('0xcdc')](_0x3104bb('0x1baa'))[_0x3104bb('0xf3c')](_0x3104bb('0x1809')+_0x3104bb('0x3f3'))[_0x3104bb('0x8e8')](_0x3104bb('0x1bc0'))[_0x3104bb('0x203b')](_0x13940b)['ok']('OK')[_0x3104bb('0x3f')](_0x3104bb('0x2d3'));_0x82f774[_0x3104bb('0x1f80')](_0x1a9d19)['then'](function(){_0x2d4ded(_0x31654b);},function(){const _0x5d04d1=_0x3104bb;console[_0x5d04d1('0x455')](_0x5d04d1('0x2d3'));});}function _0x25b108(_0x3e7d76){const _0x252119=_0xf64a7,_0x4a463f=_0x82f774['confirm']()['title'](_0x252119('0x29'))['htmlContent'](_0x252119('0x12b5')+_0x94267b[_0x252119('0x968')][_0x252119('0x264b')]+_0x252119('0x196d')+_0x252119('0x3f3'))[_0x252119('0x8e8')](_0x252119('0x17a'))[_0x252119('0x203b')](_0x3e7d76)['ok']('OK')[_0x252119('0x3f')](_0x252119('0x2d3'));_0x82f774['show'](_0x4a463f)[_0x252119('0x1166')](function(){const _0x4074d9=_0x252119;_0x94267b['selectedDescriptions'][_0x4074d9('0x2782')](function(_0xed420c){_0x2d4ded(_0xed420c);}),_0x94267b['selectedDescriptions']=[];});}_0x94267b[_0xf64a7('0x16')]=[],_0x94267b['createOrEditField']=_0x170cf1,_0x94267b[_0xf64a7('0xbda')]=_0x2f1904,_0x94267b[_0xf64a7('0x1ace')]=_0x5a0747;function _0x170cf1(_0x3609f9,_0x65e188){const _0x3c5f61=_0xf64a7;_0x82f774[_0x3c5f61('0x1f80')]({'controller':_0x3c5f61('0x1d4c'),'controllerAs':'vm','templateUrl':_0x471b39,'parent':angular['element'](_0x49c6aa['body']),'targetEvent':_0x3609f9,'clickOutsideToClose':!![],'locals':{'type':_0x3c5f61('0x22f3'),'item':_0x65e188,'items':_0x94267b[_0x3c5f61('0xfe2')],'configuration':_0x94267b[_0x3c5f61('0xe91')],'account':_0x94267b[_0x3c5f61('0x225c')],'license':null,'setting':null,'crudPermissions':_0x94267b['crudPermissions']}});}function _0x5cea15(_0x36816e){const _0x2969c9=_0xf64a7;_0x4a2b29[_0x2969c9('0x9c5')]['delete']({'id':_0x36816e['id']})['$promise']['then'](function(){const _0x4db1b3=_0x2969c9;_0x2cfb05()[_0x4db1b3('0x127f')](_0x94267b[_0x4db1b3('0xfe2')],{'id':_0x36816e['id']}),_0x3083f0[_0x4db1b3('0x103b')]({'title':_0x4db1b3('0x13cb'),'msg':_0x4db1b3('0x31e')});})[_0x2969c9('0x1a80')](function(_0x2c6652){const _0x46dc97=_0x2969c9;_0x3083f0[_0x46dc97('0xfc9')]({'title':_0x2c6652[_0x46dc97('0x52d')]?_0x46dc97('0x1e21')+_0x2c6652[_0x46dc97('0x52d')]+_0x46dc97('0x11e1')+_0x2c6652[_0x46dc97('0xe1b')]:_0x46dc97('0x23ff'),'msg':_0x2c6652['data']?JSON[_0x46dc97('0xbac')](_0x2c6652[_0x46dc97('0x25f4')]):_0x2c6652[_0x46dc97('0x1586')]()});});}function _0x2f1904(_0x3614d,_0x5aca0e){const _0x581fa9=_0xf64a7,_0x432db4=_0x82f774['confirm']()[_0x581fa9('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')['htmlContent']('Field'+_0x581fa9('0x3f3'))[_0x581fa9('0x8e8')](_0x581fa9('0x2127'))['targetEvent'](_0x3614d)['ok']('OK')[_0x581fa9('0x3f')]('CANCEL');_0x82f774[_0x581fa9('0x1f80')](_0x432db4)[_0x581fa9('0x1166')](function(){_0x5cea15(_0x5aca0e);},function(){const _0x3233b4=_0x581fa9;console[_0x3233b4('0x455')]('CANCEL');});}function _0x5a0747(_0x4098df){const _0x32605d=_0xf64a7,_0x433558=_0x82f774[_0x32605d('0x1d26')]()[_0x32605d('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20fields?')[_0x32605d('0xf3c')](''+_0x94267b[_0x32605d('0x16')][_0x32605d('0x264b')]+_0x32605d('0x196d')+_0x32605d('0x3f3'))['ariaLabel']('delete\x20fields')[_0x32605d('0x203b')](_0x4098df)['ok']('OK')['cancel'](_0x32605d('0x2d3'));_0x82f774['show'](_0x433558)[_0x32605d('0x1166')](function(){const _0x42cbe4=_0x32605d;_0x94267b[_0x42cbe4('0x16')][_0x42cbe4('0x2782')](function(_0x2af812){_0x5cea15(_0x2af812);}),_0x94267b['selectedFields']=[];});}}const _0x6ad8f5=_0x180768;_0x47e06c[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),'$location','$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xd54'),_0x36e6f4('0xe91'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x47e06c(_0x62448b,_0x1fe3c0,_0x460bce,_0x11bf10,_0x5cd498,_0x1e8d21,_0x56aa49,_0x102be3,_0x5db7b7,_0x516d30,_0x3c6e7a,_0x294df9,_0x1ec1c6,_0x5d0cbe){const _0x454b17=_0x36e6f4,_0x2583c3=this;_0x2583c3['currentUser']=_0x3c6e7a['getCurrentUser'](),_0x2583c3[_0x454b17('0x61a')]=[],_0x2583c3['setting']=_0x1ec1c6,_0x2583c3[_0x454b17('0x5c9')]=_0x294df9,_0x2583c3[_0x454b17('0x243c')]=_0x5d0cbe,_0x2583c3[_0x454b17('0x128b')]={},_0x2583c3[_0x454b17('0x2900')]=_0x2583c3[_0x454b17('0xf8a')]&&_0x2583c3[_0x454b17('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2583c3[_0x454b17('0xcdc')]='INTEGRATIONS.EDIT_VTIGERCONFIGURATION',_0x2583c3[_0x454b17('0xe91')]=angular['copy'](_0x5db7b7),_0x2583c3[_0x454b17('0xd54')]=_0x102be3,_0x2583c3[_0x454b17('0x1778')]=![];!_0x2583c3[_0x454b17('0xe91')]&&(_0x2583c3['vtigerConfiguration']={'channel':_0x454b17('0x21da'),'type':_0x454b17('0x14d8')},_0x2583c3[_0x454b17('0xcdc')]='INTEGRATIONS.NEW_VTIGERCONFIGURATION',_0x2583c3[_0x454b17('0x1778')]=!![]);_0x2583c3[_0x454b17('0x1cc3')]=_0x2aadc3,_0x2583c3[_0x454b17('0x263')]=_0x112fef,_0x2583c3[_0x454b17('0x189a')]=_0x5a927f,_0x2583c3[_0x454b17('0x1a9c')]=_0xd1f956,_0x2583c3[_0x454b17('0x24a0')]=_0xbef6c9;function _0x2aadc3(){const _0x5740b0=_0x454b17;_0x2583c3['errors']=[],_0x516d30[_0x5740b0('0x1b52')][_0x5740b0('0x274a')]({'id':_0x1fe3c0['params']['id']},_0x2583c3[_0x5740b0('0xe91')])[_0x5740b0('0xa44')][_0x5740b0('0x1166')](function(_0x4020fa){const _0xd98fcb=_0x5740b0;_0x2583c3['configurations'][_0xd98fcb('0x2450')](_0x4020fa['toJSON']()),_0x56aa49['success']({'title':_0xd98fcb('0x1c41'),'msg':_0x2583c3[_0xd98fcb('0xe91')]['name']?_0x2583c3['vtigerConfiguration']['name']+_0xd98fcb('0x1eda'):''}),_0xbef6c9(_0x4020fa);})[_0x5740b0('0x1a80')](function(_0x3e4b43){const _0x6c4b11=_0x5740b0;if(_0x3e4b43[_0x6c4b11('0x25f4')]&&_0x3e4b43['data'][_0x6c4b11('0x61a')]&&_0x3e4b43['data'][_0x6c4b11('0x61a')][_0x6c4b11('0x264b')]){_0x2583c3[_0x6c4b11('0x61a')]=_0x3e4b43[_0x6c4b11('0x25f4')][_0x6c4b11('0x61a')]||[{'message':_0x3e4b43[_0x6c4b11('0x1586')](),'type':_0x6c4b11('0x1ebc')}];for(let _0x10d7cf=0x0;_0x10d7cf<_0x3e4b43[_0x6c4b11('0x25f4')][_0x6c4b11('0x61a')][_0x6c4b11('0x264b')];_0x10d7cf+=0x1){_0x56aa49[_0x6c4b11('0xfc9')]({'title':_0x3e4b43[_0x6c4b11('0x25f4')][_0x6c4b11('0x61a')][_0x10d7cf][_0x6c4b11('0x1345')],'msg':_0x3e4b43['data'][_0x6c4b11('0x61a')][_0x10d7cf][_0x6c4b11('0x1e70')]});}}else _0x56aa49[_0x6c4b11('0xfc9')]({'title':_0x3e4b43[_0x6c4b11('0x52d')]?_0x6c4b11('0x1e21')+_0x3e4b43[_0x6c4b11('0x52d')]+'\x20-\x20'+_0x3e4b43[_0x6c4b11('0xe1b')]:_0x6c4b11('0x1ebc'),'msg':_0x3e4b43[_0x6c4b11('0x25f4')]?JSON[_0x6c4b11('0xbac')](_0x3e4b43[_0x6c4b11('0x25f4')]['message']):_0x3e4b43[_0x6c4b11('0x1586')]()});});}function _0x112fef(){const _0x395ecc=_0x454b17;_0x2583c3[_0x395ecc('0x61a')]=[],_0x516d30[_0x395ecc('0x2582')][_0x395ecc('0x1449')]({'id':_0x2583c3[_0x395ecc('0xe91')]['id']},_0x2583c3['vtigerConfiguration'])[_0x395ecc('0xa44')]['then'](function(_0x2fcf95){const _0x415d12=_0x395ecc,_0x260fca=_0x2cfb05()[_0x415d12('0xc38')](_0x2583c3[_0x415d12('0xd54')],{'id':_0x2fcf95['id']});_0x260fca&&_0x2cfb05()[_0x415d12('0xcc3')](_0x260fca,_0x2cfb05()[_0x415d12('0x1a08')](_0x2fcf95[_0x415d12('0x2876')](),_0x2cfb05()[_0x415d12('0x14a4')](_0x260fca))),_0x56aa49[_0x415d12('0x103b')]({'title':_0x415d12('0x27a1'),'msg':_0x2583c3[_0x415d12('0xe91')][_0x415d12('0x4f0')]?_0x2583c3[_0x415d12('0xe91')][_0x415d12('0x4f0')]+_0x415d12('0x7d'):''}),_0xbef6c9(_0x2fcf95);})[_0x395ecc('0x1a80')](function(_0x838b63){const _0x2f142a=_0x395ecc;if(_0x838b63[_0x2f142a('0x25f4')]&&_0x838b63[_0x2f142a('0x25f4')][_0x2f142a('0x61a')]&&_0x838b63['data'][_0x2f142a('0x61a')][_0x2f142a('0x264b')]){_0x2583c3['errors']=_0x838b63[_0x2f142a('0x25f4')][_0x2f142a('0x61a')]||[{'message':_0x838b63[_0x2f142a('0x1586')](),'type':_0x2f142a('0x184d')}];for(let _0x5c183c=0x0;_0x5c183c<_0x838b63[_0x2f142a('0x25f4')][_0x2f142a('0x61a')][_0x2f142a('0x264b')];_0x5c183c++){_0x56aa49[_0x2f142a('0xfc9')]({'title':_0x838b63[_0x2f142a('0x25f4')][_0x2f142a('0x61a')][_0x5c183c][_0x2f142a('0x1345')],'msg':_0x838b63[_0x2f142a('0x25f4')][_0x2f142a('0x61a')][_0x5c183c][_0x2f142a('0x1e70')]});}}else _0x56aa49['error']({'title':_0x838b63[_0x2f142a('0x52d')]?'API:'+_0x838b63[_0x2f142a('0x52d')]+_0x2f142a('0x11e1')+_0x838b63['statusText']:_0x2f142a('0x184d'),'msg':_0x838b63['data']?JSON['stringify'](_0x838b63[_0x2f142a('0x25f4')][_0x2f142a('0x1e70')]):_0x838b63['toString']()});});}function _0x5a927f(_0x22e095){const _0x4a4602=_0x454b17;_0x2583c3[_0x4a4602('0x61a')]=[];const _0x42b9cd=_0x11bf10[_0x4a4602('0x1d26')]()[_0x4a4602('0xcdc')](_0x4a4602('0x7fb'))[_0x4a4602('0xacc')](_0x4a4602('0xcfe'))[_0x4a4602('0x8e8')](_0x4a4602('0x263e'))['ok'](_0x4a4602('0x18'))['cancel'](_0x4a4602('0x497'))[_0x4a4602('0x203b')](_0x22e095);_0x11bf10['show'](_0x42b9cd)[_0x4a4602('0x1166')](function(){const _0x5078bb=_0x4a4602;_0x516d30[_0x5078bb('0x2582')][_0x5078bb('0x906')]({'id':_0x2583c3[_0x5078bb('0xe91')]['id']})[_0x5078bb('0xa44')][_0x5078bb('0x1166')](function(){const _0x2ef6d5=_0x5078bb;_0x2cfb05()[_0x2ef6d5('0x127f')](_0x2583c3[_0x2ef6d5('0xd54')],{'id':_0x2583c3[_0x2ef6d5('0xe91')]['id']}),_0x56aa49[_0x2ef6d5('0x103b')]({'title':'VtigerConfiguration\x20properly\x20deleted!','msg':(_0x2583c3[_0x2ef6d5('0xe91')][_0x2ef6d5('0x4f0')]||_0x2ef6d5('0xe91'))+_0x2ef6d5('0x7cd')}),_0xbef6c9(_0x2583c3[_0x2ef6d5('0xe91')]);})[_0x5078bb('0x1a80')](function(_0x26c39b){const _0x5329b9=_0x5078bb;if(_0x26c39b[_0x5329b9('0x25f4')]&&_0x26c39b['data'][_0x5329b9('0x61a')]&&_0x26c39b[_0x5329b9('0x25f4')][_0x5329b9('0x61a')][_0x5329b9('0x264b')]){_0x2583c3[_0x5329b9('0x61a')]=_0x26c39b['data'][_0x5329b9('0x61a')]||[{'message':_0x26c39b['toString'](),'type':'api.intVtigerConfiguration.delete'}];for(let _0x37aa40=0x0;_0x37aa40<_0x26c39b[_0x5329b9('0x25f4')][_0x5329b9('0x61a')][_0x5329b9('0x264b')];_0x37aa40++){_0x56aa49[_0x5329b9('0xfc9')]({'title':_0x26c39b[_0x5329b9('0x25f4')][_0x5329b9('0x61a')][_0x37aa40]['type'],'msg':_0x26c39b[_0x5329b9('0x25f4')]['errors'][_0x37aa40][_0x5329b9('0x1e70')]});}}else _0x56aa49[_0x5329b9('0xfc9')]({'title':_0x26c39b[_0x5329b9('0x52d')]?_0x5329b9('0x1e21')+_0x26c39b[_0x5329b9('0x52d')]+'\x20-\x20'+_0x26c39b[_0x5329b9('0xe1b')]:_0x5329b9('0x1c7c'),'msg':_0x26c39b[_0x5329b9('0x25f4')]?JSON[_0x5329b9('0xbac')](_0x26c39b[_0x5329b9('0x25f4')][_0x5329b9('0x1e70')]):_0x26c39b[_0x5329b9('0x1e70')]||_0x26c39b[_0x5329b9('0x1586')]()});});},function(){});}function _0xd1f956(_0x4c04d4){return _0x4c04d4===null?undefined:new Date(_0x4c04d4);}function _0xbef6c9(_0x280416){const _0x1155b8=_0x454b17;_0x11bf10[_0x1155b8('0x1197')](_0x280416);}}const _0x4a36fc=_0x47e06c;_0x38d56b[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog',_0x36e6f4('0x1d2e'),_0x36e6f4('0xd29'),_0x36e6f4('0xbd7'),_0x36e6f4('0x1301'),_0x36e6f4('0x1a32'),_0x36e6f4('0x1345'),'api','Auth',_0x36e6f4('0x243c')];function _0x38d56b(_0x5e8859,_0x422dc3,_0x2b5c2c,_0x5a169c,_0x20c187,_0x4d093d,_0x22fd85,_0x4470bf,_0x8b098d,_0x5aed22,_0x543cc6,_0x2eefae,_0x5015a3){const _0x1a01f9=_0x36e6f4,_0x28eeb5=this;_0x28eeb5[_0x1a01f9('0x98')]=_0x2eefae[_0x1a01f9('0x26cd')](),_0x28eeb5[_0x1a01f9('0x61a')]=[],_0x28eeb5[_0x1a01f9('0xcdc')]='INTEGRATIONS.EDIT_'+_0x2cfb05()[_0x1a01f9('0x113b')](_0x5aed22),_0x28eeb5[_0x1a01f9('0x1301')]=angular[_0x1a01f9('0x225f')](_0x4470bf),_0x28eeb5[_0x1a01f9('0xbd7')]=_0x22fd85,_0x28eeb5['type']=_0x5aed22,_0x28eeb5['crudPermissions']=_0x5015a3,_0x28eeb5[_0x1a01f9('0x17c7')]=![];!_0x28eeb5[_0x1a01f9('0x1301')]&&(_0x28eeb5[_0x1a01f9('0x1301')]={'type':_0x1a01f9('0x102c')},_0x28eeb5['item'][_0x2cfb05()['capitalize'](_0x5aed22)+'Id']=_0x4d093d['id'],_0x28eeb5[_0x1a01f9('0xcdc')]=_0x1a01f9('0xf9c')+_0x2cfb05()[_0x1a01f9('0x113b')](_0x5aed22),_0x28eeb5[_0x1a01f9('0x17c7')]=!![]);_0x28eeb5[_0x1a01f9('0x1e8a')]=_0x202399,_0x28eeb5[_0x1a01f9('0x13b8')]=_0x3fed4e,_0x28eeb5[_0x1a01f9('0x18d3')]=_0x2a2ccf,_0x28eeb5[_0x1a01f9('0x1551')]=_0x2c9916,_0x28eeb5[_0x1a01f9('0x24a0')]=_0x12012c,_0x543cc6['variable']['get']({'nolimit':!![]})[_0x1a01f9('0xa44')][_0x1a01f9('0x1166')](function(_0x40eb4f){const _0x252f6e=_0x1a01f9;return _0x28eeb5['variables']=_0x40eb4f['rows']?_0x40eb4f['rows']:[],_0x543cc6[_0x252f6e('0x7af')]['describe']()[_0x252f6e('0xa44')];})[_0x1a01f9('0x1166')](function(_0x484093){const _0x592ea9=_0x1a01f9;return _0x28eeb5[_0x592ea9('0x1d45')]=_0x2cfb05()[_0x592ea9('0x13ca')](_0x2cfb05()[_0x592ea9('0x14a4')](_0x484093),[_0x592ea9('0xa44'),_0x592ea9('0xfcd'),_0x592ea9('0x262'),_0x592ea9('0x6f9'),_0x592ea9('0x978')]),_0x28eeb5[_0x592ea9('0x1d45')][_0x592ea9('0x1514')]('recordingURL'),_0x543cc6[_0x592ea9('0x21f9')][_0x592ea9('0x23d0')]()[_0x592ea9('0xa44')];})[_0x1a01f9('0x1166')](function(_0x11745f){const _0x37d8aa=_0x1a01f9;_0x28eeb5[_0x37d8aa('0x1348')]=_0x2cfb05()[_0x37d8aa('0x13ca')](_0x2cfb05()[_0x37d8aa('0x14a4')](_0x11745f),[_0x37d8aa('0xa44'),_0x37d8aa('0xfcd'),'createdAt',_0x37d8aa('0x6f9'),'sourceid']),_0x28eeb5['voiceDialReportColumns'][_0x37d8aa('0x1514')]('recordingURL');})[_0x1a01f9('0x1a80')](function(_0x5542c0){const _0x52ebb6=_0x1a01f9;_0x20c187[_0x52ebb6('0xfc9')]({'title':_0x5542c0['status']?'API:'+_0x5542c0[_0x52ebb6('0x52d')]+_0x52ebb6('0x11e1')+_0x5542c0['statusText']:_0x52ebb6('0xfe5'),'msg':_0x5542c0[_0x52ebb6('0x25f4')]?JSON[_0x52ebb6('0xbac')](_0x5542c0[_0x52ebb6('0x25f4')]):_0x5542c0[_0x52ebb6('0x1586')]()});}),_0x543cc6[_0x1a01f9('0x1b52')][_0x1a01f9('0x18ea')]({'id':_0x8b098d['id'],'ticketType':_0x4d093d['ticketType']?_0x4d093d['ticketType']:undefined})['$promise'][_0x1a01f9('0x1166')](function(_0x2e2c1d){const _0x32838f=_0x1a01f9;_0x28eeb5[_0x32838f('0x606')]=!![],_0x28eeb5[_0x32838f('0xfe2')]=_0x2e2c1d[_0x32838f('0x269a')]?_0x2e2c1d[_0x32838f('0x269a')]:[],_0x28eeb5[_0x32838f('0x1301')][_0x32838f('0x1143')]&&(_0x28eeb5['customField']=_0x2cfb05()[_0x32838f('0xc38')](_0x28eeb5[_0x32838f('0xfe2')],{'id':_0x28eeb5[_0x32838f('0x1301')][_0x32838f('0x1143')]}));})[_0x1a01f9('0x1a80')](function(_0x2f3231){const _0x416c47=_0x1a01f9;_0x28eeb5[_0x416c47('0x606')]=![],console['error'](_0x2f3231);});function _0x202399(){const _0xf6a35e=_0x1a01f9;_0x28eeb5['errors']=[],_0x28eeb5['customField']&&(_0x28eeb5['item'][_0xf6a35e('0x1143')]=_0x28eeb5[_0xf6a35e('0x117e')]['id'],_0x28eeb5[_0xf6a35e('0x1301')]['nameField']=_0x28eeb5[_0xf6a35e('0x117e')][_0xf6a35e('0x4f0')],_0x28eeb5['item'][_0xf6a35e('0x117e')]=_0x28eeb5['customField']['custom']),_0x543cc6[_0xf6a35e('0x9c5')][_0xf6a35e('0x9cc')](_0x28eeb5[_0xf6a35e('0x1301')])[_0xf6a35e('0xa44')][_0xf6a35e('0x1166')](function(_0x1a45a7){const _0x224ac9=_0xf6a35e;_0x28eeb5[_0x224ac9('0xbd7')]['unshift'](_0x1a45a7),_0x20c187[_0x224ac9('0x103b')]({'title':_0x2cfb05()[_0x224ac9('0x92c')](_0x5aed22)+_0x224ac9('0x13f0'),'msg':_0x2cfb05()[_0x224ac9('0x92c')](_0x5aed22)+_0x224ac9('0x1eda')}),_0x12012c();})['catch'](function(_0x48bf5a){const _0x5d6e01=_0xf6a35e;console['error'](_0x48bf5a),_0x28eeb5[_0x5d6e01('0x61a')]=_0x48bf5a['data']['errors']||[{'message':_0x48bf5a[_0x5d6e01('0x1586')](),'type':'api.item.save'}];});}function _0x3fed4e(){const _0x269e99=_0x1a01f9;_0x28eeb5[_0x269e99('0x61a')]=[],_0x28eeb5['customField']&&(_0x28eeb5['item'][_0x269e99('0x1143')]=_0x28eeb5[_0x269e99('0x117e')]['id'],_0x28eeb5[_0x269e99('0x1301')][_0x269e99('0x3c0')]=_0x28eeb5['customField'][_0x269e99('0x4f0')],_0x28eeb5[_0x269e99('0x1301')][_0x269e99('0x117e')]=_0x28eeb5[_0x269e99('0x117e')][_0x269e99('0x2853')]),_0x543cc6[_0x269e99('0x9c5')][_0x269e99('0x1449')]({'id':_0x28eeb5[_0x269e99('0x1301')]['id']},_0x28eeb5[_0x269e99('0x1301')])[_0x269e99('0xa44')]['then'](function(_0x488099){const _0x56ab28=_0x269e99,_0x333f59=_0x2cfb05()['find'](_0x28eeb5[_0x56ab28('0xbd7')],{'id':_0x488099['id']});_0x333f59&&_0x2cfb05()[_0x56ab28('0xcc3')](_0x333f59,_0x488099),_0x20c187['success']({'title':_0x2cfb05()['capitalize'](_0x5aed22)+_0x56ab28('0x1a2f'),'msg':_0x2cfb05()[_0x56ab28('0x92c')](_0x5aed22)+_0x56ab28('0x7d')}),_0x12012c();})[_0x269e99('0x1a80')](function(_0x14f331){const _0x436a27=_0x269e99;console[_0x436a27('0xfc9')](_0x14f331),_0x28eeb5[_0x436a27('0x61a')]=_0x14f331[_0x436a27('0x25f4')][_0x436a27('0x61a')]||[{'message':_0x14f331[_0x436a27('0x1586')](),'type':_0x436a27('0x10cd')}];});}function _0x2a2ccf(_0x2b92be){const _0x204f08=_0x1a01f9;_0x28eeb5[_0x204f08('0x61a')]=[];const _0x194738=_0x5a169c['confirm']()['title']('Are\x20you\x20sure?')[_0x204f08('0xacc')](_0x204f08('0x135f')+_0x5aed22+_0x204f08('0x3f3'))[_0x204f08('0x8e8')](_0x204f08('0x237c')+_0x2cfb05()[_0x204f08('0x92c')](_0x5aed22))['ok']('Delete')[_0x204f08('0x3f')](_0x204f08('0x497'))[_0x204f08('0x203b')](_0x2b92be);_0x5a169c['show'](_0x194738)[_0x204f08('0x1166')](function(){const _0x1d8f35=_0x204f08;_0x543cc6['intVtigerField'][_0x1d8f35('0x906')]({'id':_0x28eeb5[_0x1d8f35('0x1301')]['id']})[_0x1d8f35('0xa44')]['then'](function(){const _0x4d5116=_0x1d8f35;_0x2cfb05()[_0x4d5116('0x127f')](_0x28eeb5[_0x4d5116('0xbd7')],{'id':_0x28eeb5['item']['id']}),_0x20c187[_0x4d5116('0x103b')]({'title':_0x2cfb05()['capitalize'](_0x5aed22)+'\x20properly\x20deleted!','msg':_0x2cfb05()[_0x4d5116('0x92c')](_0x5aed22)+'\x20has\x20been\x20deleted!'}),_0x12012c();})[_0x1d8f35('0x1a80')](function(_0x21760f){const _0x1236e5=_0x1d8f35;console[_0x1236e5('0xfc9')](_0x21760f),_0x28eeb5[_0x1236e5('0x61a')]=_0x21760f['data'][_0x1236e5('0x61a')]||[{'message':_0x21760f['toString'](),'type':'api.item.delete'}];});},function(){});}function _0x2c9916(){const _0x494482=_0x1a01f9;return _0x28eeb5[_0x494482('0x1301')][_0x494482('0xbdb')]!==undefined?_0x28eeb5[_0x494482('0x1301')]['variableName']:'Please\x20select\x20a\x20variable';}function _0x12012c(){const _0x37b5c9=_0x1a01f9;_0x5a169c[_0x37b5c9('0x1197')]();}}const _0x288b23=_0x38d56b;_0x3415f3[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'api','toasty','Auth',_0x36e6f4('0x225c'),_0x36e6f4('0x17aa')];function _0x3415f3(_0x57a8d1,_0x789cf7,_0xabfc17,_0x5adbcc,_0x21bb2b,_0xb9152d,_0x22c467,_0x9933ac,_0x624716,_0xfaa643,_0x2f9d2d,_0xc35dca){const _0x2a6491=_0x36e6f4,_0x4b92cb=this;_0x4b92cb[_0x2a6491('0x98')]=_0xfaa643[_0x2a6491('0x26cd')](),_0x4b92cb[_0x2a6491('0x5c9')]=_0xb9152d,_0x4b92cb[_0x2a6491('0xf8a')]=_0x22c467,_0x4b92cb[_0x2a6491('0x2900')]=_0x4b92cb['setting'][_0x2a6491('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4b92cb[_0x2a6491('0x246b')]=_0x789cf7[_0x2a6491('0x6f1')]()+_0x2a6491('0xc51')+_0x789cf7[_0x2a6491('0x1690')](),_0x4b92cb['vtigerAccount']=_0x2f9d2d||_0x57a8d1['params'][_0x2a6491('0x225c')]||{},_0x4b92cb['userProfileSection']=_0xc35dca&&_0xc35dca[_0x2a6491('0x240f')]==0x1?_0xc35dca[_0x2a6491('0x269a')][0x0]:null,_0x4b92cb[_0x2a6491('0x243c')]=_0xfaa643[_0x2a6491('0xd87')](_0x4b92cb[_0x2a6491('0x17aa')]?_0x4b92cb[_0x2a6491('0x17aa')][_0x2a6491('0x243c')]:null),_0x4b92cb[_0x2a6491('0x128b')]={},_0x4b92cb[_0x2a6491('0x2669')]=_0x57a8d1[_0x2a6491('0x23f')]['tab']||0x0,_0x4b92cb[_0x2a6491('0x31d')]=_0x624716[_0x2a6491('0x1fa1')],_0x4b92cb[_0x2a6491('0x636')]=_0x3fedc9,_0x4b92cb[_0x2a6491('0x1bba')]=_0x3272a0;function _0x3fedc9(){const _0x227f20=_0x2a6491;_0x57a8d1['go'](_0x227f20('0x173d'),{},{'reload':_0x227f20('0x173d')});}function _0x3272a0(){const _0x20d259=_0x2a6491;_0x9933ac[_0x20d259('0x1b52')][_0x20d259('0x1449')]({'id':_0x4b92cb[_0x20d259('0x225c')]['id']},_0x4b92cb[_0x20d259('0x225c')])[_0x20d259('0xa44')][_0x20d259('0x1166')](function(){const _0x35f9dc=_0x20d259;_0x624716[_0x35f9dc('0x103b')]({'title':_0x35f9dc('0xa27'),'msg':_0x4b92cb[_0x35f9dc('0x225c')][_0x35f9dc('0x4f0')]?_0x4b92cb['vtigerAccount'][_0x35f9dc('0x4f0')]+_0x35f9dc('0xa17'):''});})[_0x20d259('0x1a80')](function(_0x2e8489){const _0x56db0c=_0x20d259;_0x624716['error']({'title':_0x2e8489[_0x56db0c('0x52d')]?'API:'+_0x2e8489[_0x56db0c('0x52d')]+'\x20-\x20'+_0x2e8489[_0x56db0c('0xe1b')]:_0x56db0c('0x7a3'),'msg':_0x2e8489[_0x56db0c('0x25f4')]?JSON[_0x56db0c('0xbac')](_0x2e8489[_0x56db0c('0x25f4')]):_0x2e8489['toString']()});});}}const _0x3d6fd9=_0x3415f3,_0x4883c4=_0x2734b2['p']+_0x36e6f4('0x17a2');_0x27b23a['$inject']=['$scope','$window',_0x36e6f4('0x7b9'),'$mdSidenav','$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'vtigerAccounts','userProfile',_0x36e6f4('0x17aa'),'api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x27b23a(_0x23d4ab,_0x2deab1,_0x5b5190,_0x54fa90,_0x1489f0,_0x876207,_0x2a18e1,_0x164a88,_0x3fafba,_0x39c398,_0x5686ee,_0x453c8c,_0x1dcb31,_0x4f1343,_0xaf1c85,_0x411060,_0x8620e1){const _0x2986e5=_0x36e6f4,_0x1728a4=this;_0x1728a4[_0x2986e5('0x5c9')]=_0x411060,_0x1728a4['setting']=_0x8620e1,_0x1728a4['currentUser']=_0xaf1c85['getCurrentUser'](),_0x1728a4[_0x2986e5('0x101b')]=_0x3fafba||{'count':0x0,'rows':[]},_0x1728a4[_0x2986e5('0x7f')]=_0x39c398,_0x1728a4[_0x2986e5('0x17aa')]=_0x5686ee&&_0x5686ee[_0x2986e5('0x240f')]==0x1?_0x5686ee[_0x2986e5('0x269a')][0x0]:null,_0x1728a4[_0x2986e5('0x243c')]=_0xaf1c85[_0x2986e5('0xd87')](_0x1728a4[_0x2986e5('0x17aa')]?_0x1728a4[_0x2986e5('0x17aa')][_0x2986e5('0x243c')]:null),_0x1728a4[_0x2986e5('0x916')]=_0x2986e5('0x101b'),_0x1728a4[_0x2986e5('0xef5')]='',_0x1728a4[_0x2986e5('0x104c')]=null,_0x1728a4['selectedVtigerAccounts']=[],_0x1728a4['query']={'fields':_0x2986e5('0x20c5'),'limit':0xa,'page':0x1},_0x1728a4[_0x2986e5('0x1ff6')]=_0x3c3e17,_0x1728a4['testtestintegrationaccount']=_0x31a6ca,_0x1728a4[_0x2986e5('0x8d8')]=_0x4d15bc,_0x1728a4[_0x2986e5('0x103b')]=_0x5c1d98,_0x1728a4[_0x2986e5('0x8d6')]=_0x1861fe,_0x1728a4[_0x2986e5('0x199a')]=_0x4f9c1b,_0x1728a4[_0x2986e5('0x2197')]=_0x27dc90,_0x1728a4[_0x2986e5('0x1bd3')]=_0x28240e,_0x1728a4[_0x2986e5('0xb7d')]=_0x1d54e7,_0x1728a4[_0x2986e5('0xc8a')]=_0xe01b74,_0x1728a4['selectAllVtigerAccounts']=_0x2a026c;function _0x3c3e17(_0xbb39f5){const _0x256b1b=_0x2986e5;_0x5b5190['go'](_0x256b1b('0x17af'),{'id':_0xbb39f5['id'],'vtigerAccount':_0xbb39f5,'crudPermissions':_0x1728a4['crudPermissions']});}function _0x31a6ca(_0x270ad5){const _0x506270=_0x2986e5;return _0x453c8c[_0x506270('0x1b52')][_0x506270('0x18ea')]({'id':_0x270ad5['id'],'test':!![]})[_0x506270('0xa44')][_0x506270('0x1166')](function(){const _0x5650dd=_0x506270;_0x4f1343['success']({'title':_0x5650dd('0x15b'),'msg':_0x5650dd('0x1fef')});})[_0x506270('0x1a80')](function(_0x10c721){const _0x400c95=_0x506270;_0x4f1343['error']({'title':_0x400c95('0x15b'),'msg':_0x10c721[_0x400c95('0x25f4')]?_0x10c721[_0x400c95('0x25f4')][_0x400c95('0x1e70')]?_0x10c721[_0x400c95('0x25f4')][_0x400c95('0x1e70')]:JSON[_0x400c95('0xbac')](_0x10c721[_0x400c95('0x25f4')]):_0x10c721[_0x400c95('0x1586')]()});});}function _0x4d15bc(_0x307810,_0x148ee6){const _0x40cc77=_0x2986e5,_0x5c4a84=_0x1489f0[_0x40cc77('0x1d26')]()['title'](_0x40cc77('0x288d')+_0x2cfb05()[_0x40cc77('0xb35')](_0x40cc77('0x225c'))+'?')[_0x40cc77('0xf3c')](_0x40cc77('0x12b5')+(_0x307810[_0x40cc77('0x4f0')]||_0x40cc77('0x225c'))+_0x40cc77('0xace')+_0x40cc77('0x3f3'))[_0x40cc77('0x8e8')](_0x40cc77('0x21f7'))[_0x40cc77('0x203b')](_0x148ee6)['ok']('OK')[_0x40cc77('0x3f')](_0x40cc77('0x2d3'));_0x1489f0[_0x40cc77('0x1f80')](_0x5c4a84)[_0x40cc77('0x1166')](function(){_0x27dc90(_0x307810);},function(){const _0x14980b=_0x40cc77;console[_0x14980b('0x455')](_0x14980b('0x2d3'));});}let _0x3c9f8c=!![],_0x139589=0x1;_0x23d4ab[_0x2986e5('0xe83')](_0x2986e5('0x12d8'),function(_0x13e8fd,_0xa5069f){const _0x1955aa=_0x2986e5;_0x3c9f8c?_0x2a18e1(function(){_0x3c9f8c=![];}):(!_0xa5069f&&(_0x139589=_0x1728a4[_0x1955aa('0x2218')]['page']),_0x13e8fd!==_0xa5069f&&(_0x1728a4[_0x1955aa('0x2218')]['page']=0x1),!_0x13e8fd&&(_0x1728a4[_0x1955aa('0x2218')][_0x1955aa('0x1a43')]=_0x139589),_0x1728a4[_0x1955aa('0x8d6')]());});function _0x5c1d98(_0x1bfba0){const _0x2c131d=_0x2986e5;_0x1728a4[_0x2c131d('0x101b')]=_0x1bfba0||{'count':0x0,'rows':[]};}function _0x1861fe(){const _0x1b2fe9=_0x2986e5;_0x1728a4['query'][_0x1b2fe9('0x1098')]=(_0x1728a4['query'][_0x1b2fe9('0x1a43')]-0x1)*_0x1728a4[_0x1b2fe9('0x2218')][_0x1b2fe9('0x163f')],_0xaf1c85[_0x1b2fe9('0x1ac6')](_0x1b2fe9('0xa7c'))?_0x1728a4[_0x1b2fe9('0x1f48')]=_0x453c8c[_0x1b2fe9('0x1b52')][_0x1b2fe9('0xd83')](_0x1728a4[_0x1b2fe9('0x2218')],_0x5c1d98)['$promise']:(_0x1728a4['query']['id']=_0x1728a4[_0x1b2fe9('0x7f')]['id'],_0x1728a4[_0x1b2fe9('0x2218')]['section']=_0x1b2fe9('0xd9b'),_0x1728a4[_0x1b2fe9('0x1f48')]=_0x453c8c[_0x1b2fe9('0x7f')]['getResources'](_0x1728a4[_0x1b2fe9('0x2218')],_0x5c1d98)['$promise']);}function _0x4f9c1b(_0x413325,_0x1d5b29){const _0x5f1358=_0x2986e5;_0x1489f0[_0x5f1358('0x1f80')]({'controller':_0x5f1358('0x23f5'),'controllerAs':'vm','templateUrl':_0x4883c4,'parent':angular['element'](_0x876207[_0x5f1358('0x8d2')]),'targetEvent':_0x413325,'clickOutsideToClose':!![],'locals':{'vtigerAccount':_0x1d5b29,'vtigerAccounts':_0x1728a4['vtigerAccounts'][_0x5f1358('0x269a')],'license':_0x1728a4[_0x5f1358('0x5c9')],'setting':_0x1728a4['setting'],'crudPermissions':_0x1728a4[_0x5f1358('0x243c')]}});}function _0x27dc90(_0x3ddf95){const _0x11f35a=_0x2986e5;_0x453c8c[_0x11f35a('0x1b52')][_0x11f35a('0x906')]({'id':_0x3ddf95['id']})[_0x11f35a('0xa44')][_0x11f35a('0x1166')](function(){const _0x5d594c=_0x11f35a;_0x2cfb05()[_0x5d594c('0x127f')](_0x1728a4[_0x5d594c('0x101b')][_0x5d594c('0x269a')],{'id':_0x3ddf95['id']}),_0x1728a4['vtigerAccounts'][_0x5d594c('0x240f')]-=0x1,!_0x1728a4['vtigerAccounts'][_0x5d594c('0x269a')][_0x5d594c('0x264b')]&&_0x1728a4[_0x5d594c('0x8d6')](),_0x4f1343[_0x5d594c('0x103b')]({'title':_0x2cfb05()['startCase'](_0x5d594c('0x1849'))+_0x5d594c('0x2b6'),'msg':_0x3ddf95[_0x5d594c('0x4f0')]?_0x3ddf95[_0x5d594c('0x4f0')]+_0x5d594c('0x7cd'):''});})[_0x11f35a('0x1a80')](function(_0x4d2891){const _0x3e9f2b=_0x11f35a;if(_0x4d2891[_0x3e9f2b('0x25f4')]&&_0x4d2891[_0x3e9f2b('0x25f4')][_0x3e9f2b('0x61a')]&&_0x4d2891[_0x3e9f2b('0x25f4')][_0x3e9f2b('0x61a')][_0x3e9f2b('0x264b')]){_0x1728a4['errors']=_0x4d2891[_0x3e9f2b('0x25f4')][_0x3e9f2b('0x61a')]||[{'message':_0x4d2891[_0x3e9f2b('0x1586')](),'type':_0x3e9f2b('0x46e')}];for(let _0x39159d=0x0;_0x39159d<_0x4d2891[_0x3e9f2b('0x25f4')][_0x3e9f2b('0x61a')]['length'];_0x39159d++){_0x4f1343[_0x3e9f2b('0xfc9')]({'title':_0x4d2891[_0x3e9f2b('0x25f4')][_0x3e9f2b('0x61a')][_0x39159d][_0x3e9f2b('0x1345')],'msg':_0x4d2891[_0x3e9f2b('0x25f4')][_0x3e9f2b('0x61a')][_0x39159d]['message']});}}else _0x4f1343[_0x3e9f2b('0xfc9')]({'title':_0x4d2891[_0x3e9f2b('0x52d')]?'API:'+_0x4d2891[_0x3e9f2b('0x52d')]+'\x20-\x20'+_0x4d2891[_0x3e9f2b('0xe1b')]:_0x3e9f2b('0x46e'),'msg':_0x4d2891['data']?JSON['stringify'](_0x4d2891[_0x3e9f2b('0x25f4')]['message']):_0x4d2891['message']||_0x4d2891['toString']()});});}function _0x28240e(){const _0xe6fcdc=_0x2986e5,_0x2a049b=angular[_0xe6fcdc('0x225f')](_0x1728a4['selectedVtigerAccounts']);return _0x1728a4[_0xe6fcdc('0x23a')]=[],_0x2a049b;}function _0x1d54e7(_0xda305b){const _0xc95dd1=_0x2986e5,_0x138f94=_0x1489f0['confirm']()[_0xc95dd1('0xcdc')](_0xc95dd1('0x134e'))[_0xc95dd1('0xf3c')](''+_0x1728a4[_0xc95dd1('0x23a')]['length']+_0xc95dd1('0x196d')+_0xc95dd1('0x3f3'))[_0xc95dd1('0x8e8')](_0xc95dd1('0x5f4'))['targetEvent'](_0xda305b)['ok']('OK')[_0xc95dd1('0x3f')](_0xc95dd1('0x2d3'));_0x1489f0['show'](_0x138f94)[_0xc95dd1('0x1166')](function(){const _0x405bef=_0xc95dd1;_0x1728a4[_0x405bef('0x23a')][_0x405bef('0x2782')](function(_0xf5c6e6){_0x27dc90(_0xf5c6e6);}),_0x1728a4[_0x405bef('0x23a')]=[];});}function _0xe01b74(){const _0x184158=_0x2986e5;_0x1728a4[_0x184158('0x23a')]=[];}function _0x2a026c(){const _0x47df36=_0x2986e5;_0x1728a4[_0x47df36('0x23a')]=_0x1728a4[_0x47df36('0x101b')][_0x47df36('0x269a')];}}const _0x5ba5ab=_0x27b23a;_0x13a935['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty','zendeskAccounts',_0x36e6f4('0x1a8d'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'crudPermissions'];function _0x13a935(_0x9f4ee7,_0x2407b4,_0x1d3522,_0x5e5b61,_0x56d696,_0x494124,_0x20abff,_0x4ec75f,_0x4f9da3,_0x55dcfc,_0x206fa1,_0x200ca1,_0x5424b9,_0x1f47b5){const _0x27a76a=_0x36e6f4,_0x2bdad4=this;_0x2bdad4[_0x27a76a('0x98')]=_0x206fa1['getCurrentUser'](),_0x2bdad4[_0x27a76a('0x61a')]=[],_0x2bdad4[_0x27a76a('0xf8a')]=_0x5424b9,_0x2bdad4[_0x27a76a('0x5c9')]=_0x200ca1,_0x2bdad4[_0x27a76a('0x243c')]=_0x1f47b5,_0x2bdad4[_0x27a76a('0x128b')]={},_0x2bdad4['passwordPattern']=_0x2bdad4[_0x27a76a('0xf8a')]&&_0x2bdad4[_0x27a76a('0xf8a')][_0x27a76a('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2bdad4[_0x27a76a('0xcdc')]=_0x27a76a('0x2516'),_0x2bdad4[_0x27a76a('0x1a8d')]=angular[_0x27a76a('0x225f')](_0x4f9da3),_0x2bdad4[_0x27a76a('0xf34')]=_0x4ec75f,_0x2bdad4['newZendeskAccount']=![];!_0x2bdad4[_0x27a76a('0x1a8d')]&&(_0x2bdad4[_0x27a76a('0x1a8d')]={'type':_0x27a76a('0x73a'),'authType':_0x27a76a('0x26e8'),'serverUrl':_0x1d3522[_0x27a76a('0x6f1')]()+_0x27a76a('0xc51')+_0x1d3522[_0x27a76a('0x1690')]()+(_0x1d3522[_0x27a76a('0x93d')]()?':'+_0x1d3522[_0x27a76a('0x93d')]():'')},_0x2bdad4[_0x27a76a('0xcdc')]=_0x27a76a('0xe8b'),_0x2bdad4[_0x27a76a('0x14da')]=!![]);_0x2bdad4[_0x27a76a('0x1032')]=_0x427780,_0x2bdad4[_0x27a76a('0x27e6')]=_0x2592a3,_0x2bdad4[_0x27a76a('0x405')]=_0x396bb5,_0x2bdad4[_0x27a76a('0x1a9c')]=_0xa26e,_0x2bdad4[_0x27a76a('0x24a0')]=_0x3d7b4a;function _0x427780(){const _0xd1946f=_0x27a76a;_0x2bdad4[_0xd1946f('0x61a')]=[],_0x55dcfc[_0xd1946f('0x2290')][_0xd1946f('0x9cc')](_0x2bdad4[_0xd1946f('0x1a8d')])[_0xd1946f('0xa44')][_0xd1946f('0x1166')](function(_0xdbaf7d){const _0x8dbabc=_0xd1946f;_0x2bdad4[_0x8dbabc('0xf34')][_0x8dbabc('0x2450')](_0xdbaf7d[_0x8dbabc('0x2876')]()),_0x20abff[_0x8dbabc('0x103b')]({'title':'ZendeskAccount\x20properly\x20created','msg':_0x2bdad4[_0x8dbabc('0x1a8d')][_0x8dbabc('0x4f0')]?_0x2bdad4['zendeskAccount'][_0x8dbabc('0x4f0')]+_0x8dbabc('0x1eda'):''}),_0x3d7b4a(_0xdbaf7d);})['catch'](function(_0x321964){const _0x35687f=_0xd1946f;if(_0x321964['data']&&_0x321964['data'][_0x35687f('0x61a')]&&_0x321964[_0x35687f('0x25f4')][_0x35687f('0x61a')]['length']){_0x2bdad4['errors']=_0x321964[_0x35687f('0x25f4')][_0x35687f('0x61a')]||[{'message':_0x321964[_0x35687f('0x1586')](),'type':_0x35687f('0xea8')}];for(let _0x365701=0x0;_0x365701<_0x321964[_0x35687f('0x25f4')][_0x35687f('0x61a')][_0x35687f('0x264b')];_0x365701+=0x1){_0x20abff[_0x35687f('0xfc9')]({'title':_0x321964[_0x35687f('0x25f4')]['errors'][_0x365701][_0x35687f('0x1345')],'msg':_0x321964[_0x35687f('0x25f4')][_0x35687f('0x61a')][_0x365701][_0x35687f('0x1e70')]});}}else _0x20abff[_0x35687f('0xfc9')]({'title':_0x321964[_0x35687f('0x52d')]?_0x35687f('0x1e21')+_0x321964['status']+'\x20-\x20'+_0x321964['statusText']:_0x35687f('0xea8'),'msg':_0x321964[_0x35687f('0x25f4')]?JSON[_0x35687f('0xbac')](_0x321964['data'][_0x35687f('0x1e70')]):_0x321964[_0x35687f('0x1586')]()});});}function _0x2592a3(){const _0x3911cc=_0x27a76a;_0x2bdad4['errors']=[],_0x55dcfc[_0x3911cc('0x2290')][_0x3911cc('0x1449')]({'id':_0x2bdad4[_0x3911cc('0x1a8d')]['id']},_0x2bdad4['zendeskAccount'])['$promise'][_0x3911cc('0x1166')](function(_0x198d68){const _0x16d47e=_0x3911cc,_0x2186d1=_0x2cfb05()['find'](_0x2bdad4[_0x16d47e('0xf34')],{'id':_0x198d68['id']});_0x2186d1&&_0x2cfb05()['merge'](_0x2186d1,_0x2cfb05()[_0x16d47e('0x1a08')](_0x198d68['toJSON'](),_0x2cfb05()[_0x16d47e('0x14a4')](_0x2186d1))),_0x20abff[_0x16d47e('0x103b')]({'title':_0x16d47e('0x9a8'),'msg':_0x2bdad4['zendeskAccount'][_0x16d47e('0x4f0')]?_0x2bdad4[_0x16d47e('0x1a8d')]['name']+_0x16d47e('0x7d'):''}),_0x3d7b4a(_0x198d68);})['catch'](function(_0x8493cf){const _0x18ac61=_0x3911cc;if(_0x8493cf[_0x18ac61('0x25f4')]&&_0x8493cf[_0x18ac61('0x25f4')][_0x18ac61('0x61a')]&&_0x8493cf[_0x18ac61('0x25f4')][_0x18ac61('0x61a')][_0x18ac61('0x264b')]){_0x2bdad4[_0x18ac61('0x61a')]=_0x8493cf['data']['errors']||[{'message':_0x8493cf[_0x18ac61('0x1586')](),'type':'api.intZendeskAccount.update'}];for(let _0x431eaf=0x0;_0x431eaf<_0x8493cf[_0x18ac61('0x25f4')][_0x18ac61('0x61a')][_0x18ac61('0x264b')];_0x431eaf++){_0x20abff[_0x18ac61('0xfc9')]({'title':_0x8493cf[_0x18ac61('0x25f4')]['errors'][_0x431eaf][_0x18ac61('0x1345')],'msg':_0x8493cf[_0x18ac61('0x25f4')]['errors'][_0x431eaf][_0x18ac61('0x1e70')]});}}else _0x20abff['error']({'title':_0x8493cf[_0x18ac61('0x52d')]?_0x18ac61('0x1e21')+_0x8493cf[_0x18ac61('0x52d')]+_0x18ac61('0x11e1')+_0x8493cf[_0x18ac61('0xe1b')]:_0x18ac61('0x1db3'),'msg':_0x8493cf[_0x18ac61('0x25f4')]?JSON['stringify'](_0x8493cf['data'][_0x18ac61('0x1e70')]):_0x8493cf[_0x18ac61('0x1586')]()});});}function _0x396bb5(_0x52b052){const _0x45b74e=_0x27a76a;_0x2bdad4['errors']=[];const _0x50f0fb=_0x5e5b61[_0x45b74e('0x1d26')]()[_0x45b74e('0xcdc')]('Are\x20you\x20sure?')[_0x45b74e('0xacc')](_0x45b74e('0xcfb'))['ariaLabel'](_0x45b74e('0xf07'))['ok'](_0x45b74e('0x18'))[_0x45b74e('0x3f')](_0x45b74e('0x497'))['targetEvent'](_0x52b052);_0x5e5b61[_0x45b74e('0x1f80')](_0x50f0fb)[_0x45b74e('0x1166')](function(){const _0x360a32=_0x45b74e;_0x55dcfc[_0x360a32('0x2290')][_0x360a32('0x906')]({'id':_0x2bdad4[_0x360a32('0x1a8d')]['id']})[_0x360a32('0xa44')][_0x360a32('0x1166')](function(){const _0x34daa8=_0x360a32;_0x2cfb05()['remove'](_0x2bdad4[_0x34daa8('0xf34')],{'id':_0x2bdad4[_0x34daa8('0x1a8d')]['id']}),_0x20abff['success']({'title':'ZendeskAccount\x20properly\x20deleted!','msg':(_0x2bdad4['zendeskAccount'][_0x34daa8('0x4f0')]||_0x34daa8('0x1a8d'))+'\x20has\x20been\x20deleted!'}),_0x3d7b4a(_0x2bdad4[_0x34daa8('0x1a8d')]);})[_0x360a32('0x1a80')](function(_0x31b020){const _0x8e82e1=_0x360a32;if(_0x31b020[_0x8e82e1('0x25f4')]&&_0x31b020['data'][_0x8e82e1('0x61a')]&&_0x31b020['data'][_0x8e82e1('0x61a')][_0x8e82e1('0x264b')]){_0x2bdad4[_0x8e82e1('0x61a')]=_0x31b020[_0x8e82e1('0x25f4')][_0x8e82e1('0x61a')]||[{'message':_0x31b020[_0x8e82e1('0x1586')](),'type':_0x8e82e1('0x16a2')}];for(let _0x4fa1c9=0x0;_0x4fa1c9<_0x31b020[_0x8e82e1('0x25f4')][_0x8e82e1('0x61a')][_0x8e82e1('0x264b')];_0x4fa1c9++){_0x20abff['error']({'title':_0x31b020[_0x8e82e1('0x25f4')]['errors'][_0x4fa1c9]['type'],'msg':_0x31b020[_0x8e82e1('0x25f4')][_0x8e82e1('0x61a')][_0x4fa1c9]['message']});}}else _0x20abff['error']({'title':_0x31b020[_0x8e82e1('0x52d')]?_0x8e82e1('0x1e21')+_0x31b020['status']+_0x8e82e1('0x11e1')+_0x31b020[_0x8e82e1('0xe1b')]:_0x8e82e1('0x16a2'),'msg':_0x31b020['data']?JSON['stringify'](_0x31b020['data'][_0x8e82e1('0x1e70')]):_0x31b020[_0x8e82e1('0x1e70')]||_0x31b020[_0x8e82e1('0x1586')]()});});},function(){});}function _0xa26e(_0x2fa6d8){return _0x2fa6d8===null?undefined:new Date(_0x2fa6d8);}function _0x3d7b4a(_0x12b4c4){const _0x53fd89=_0x27a76a;_0x5e5b61[_0x53fd89('0x1197')](_0x12b4c4);}}const _0x576640=_0x13a935;_0x2dbb55[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'toasty','configuration',_0x36e6f4('0xbd7'),_0x36e6f4('0x1301'),_0x36e6f4('0x1a32'),_0x36e6f4('0x1345'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x2dbb55(_0x12cf0c,_0x38439e,_0x1e0fdc,_0x299ed0,_0x289285,_0x4a3073,_0x2d6813,_0x3ec10d,_0x1f5c5f,_0x5e69e5,_0x5b4347,_0x1fade5,_0x243f3b){const _0x1a83c4=_0x36e6f4,_0x495e38=this;_0x495e38[_0x1a83c4('0x98')]=_0x1fade5[_0x1a83c4('0x26cd')](),_0x495e38[_0x1a83c4('0x61a')]=[],_0x495e38[_0x1a83c4('0xcdc')]=_0x1a83c4('0x2012')+_0x2cfb05()[_0x1a83c4('0x113b')](_0x5e69e5),_0x495e38[_0x1a83c4('0x1301')]=angular[_0x1a83c4('0x225f')](_0x3ec10d),_0x495e38[_0x1a83c4('0xbd7')]=_0x2d6813,_0x495e38['type']=_0x5e69e5,_0x495e38[_0x1a83c4('0x243c')]=_0x243f3b,_0x495e38[_0x1a83c4('0x17c7')]=![];!_0x495e38[_0x1a83c4('0x1301')]&&(_0x495e38['item']={'type':'string'},_0x495e38['item'][_0x2cfb05()['capitalize'](_0x5e69e5)+'Id']=_0x4a3073['id'],_0x495e38['title']=_0x1a83c4('0xf9c')+_0x2cfb05()[_0x1a83c4('0x113b')](_0x5e69e5),_0x495e38['newItem']=!![]);_0x495e38['addNewItem']=_0x20c5a6,_0x495e38[_0x1a83c4('0x13b8')]=_0x484b3c,_0x495e38[_0x1a83c4('0x18d3')]=_0x1d51aa,_0x495e38['getSelectedVariable']=_0x53ab2b,_0x495e38[_0x1a83c4('0x24a0')]=_0x459c19,_0x5b4347['variable'][_0x1a83c4('0xd83')]({'nolimit':!![]})[_0x1a83c4('0xa44')][_0x1a83c4('0x1166')](function(_0x2bba81){const _0x35feae=_0x1a83c4;return _0x495e38['variables']=_0x2bba81[_0x35feae('0x269a')]?_0x2bba81[_0x35feae('0x269a')]:[],_0x5b4347[_0x35feae('0x7af')][_0x35feae('0x23d0')]()['$promise'];})[_0x1a83c4('0x1166')](function(_0x1270aa){const _0xfc73f7=_0x1a83c4;return _0x495e38[_0xfc73f7('0x1d45')]=_0x2cfb05()['difference'](_0x2cfb05()[_0xfc73f7('0x14a4')](_0x1270aa),[_0xfc73f7('0xa44'),'$resolved','createdAt','updatedAt',_0xfc73f7('0x978')]),_0x495e38[_0xfc73f7('0x1d45')][_0xfc73f7('0x1514')](_0xfc73f7('0xa29')),_0x5b4347[_0xfc73f7('0x21f9')][_0xfc73f7('0x23d0')]()['$promise'];})[_0x1a83c4('0x1166')](function(_0x1abd54){const _0xd7e1d9=_0x1a83c4;_0x495e38['voiceDialReportColumns']=_0x2cfb05()['difference'](_0x2cfb05()[_0xd7e1d9('0x14a4')](_0x1abd54),[_0xd7e1d9('0xa44'),_0xd7e1d9('0xfcd'),'createdAt',_0xd7e1d9('0x6f9'),_0xd7e1d9('0x978')]),_0x495e38[_0xd7e1d9('0x1348')][_0xd7e1d9('0x1514')](_0xd7e1d9('0xa29'));})[_0x1a83c4('0x1a80')](function(_0x2284b2){const _0x3f0de1=_0x1a83c4;_0x289285['error']({'title':_0x2284b2[_0x3f0de1('0x52d')]?'API:'+_0x2284b2['status']+_0x3f0de1('0x11e1')+_0x2284b2[_0x3f0de1('0xe1b')]:_0x3f0de1('0xfe5'),'msg':_0x2284b2[_0x3f0de1('0x25f4')]?JSON[_0x3f0de1('0xbac')](_0x2284b2[_0x3f0de1('0x25f4')]):_0x2284b2[_0x3f0de1('0x1586')]()});}),_0x5b4347['intZendeskAccount'][_0x1a83c4('0x18ea')]({'id':_0x1f5c5f['id'],'ticketType':_0x4a3073['ticketType']?_0x4a3073[_0x1a83c4('0x11ba')]:undefined})[_0x1a83c4('0xa44')]['then'](function(_0x972ce3){const _0x3e7204=_0x1a83c4;_0x495e38[_0x3e7204('0x606')]=!![],_0x495e38[_0x3e7204('0xfe2')]=_0x972ce3[_0x3e7204('0x269a')]?_0x972ce3[_0x3e7204('0x269a')]:[],_0x495e38[_0x3e7204('0x1301')][_0x3e7204('0x1143')]&&(_0x495e38[_0x3e7204('0x117e')]=_0x2cfb05()['find'](_0x495e38[_0x3e7204('0xfe2')],{'id':_0x495e38['item'][_0x3e7204('0x1143')]}));})['catch'](function(_0x4d7ec8){const _0x192b12=_0x1a83c4;_0x495e38[_0x192b12('0x606')]=![],console[_0x192b12('0xfc9')](_0x4d7ec8);});function _0x20c5a6(){const _0x904e24=_0x1a83c4;_0x495e38[_0x904e24('0x61a')]=[],_0x495e38[_0x904e24('0x117e')]&&(_0x495e38[_0x904e24('0x1301')]['idField']=_0x495e38[_0x904e24('0x117e')]['id'],_0x495e38[_0x904e24('0x1301')][_0x904e24('0x3c0')]=_0x495e38[_0x904e24('0x117e')]['name'],_0x495e38[_0x904e24('0x1301')][_0x904e24('0x117e')]=_0x495e38[_0x904e24('0x117e')][_0x904e24('0x2853')]),_0x5b4347[_0x904e24('0x1a97')]['save'](_0x495e38['item'])[_0x904e24('0xa44')]['then'](function(_0x718553){const _0x1cd199=_0x904e24;_0x495e38[_0x1cd199('0xbd7')][_0x1cd199('0x2450')](_0x718553),_0x289285['success']({'title':_0x2cfb05()['capitalize'](_0x5e69e5)+'\x20properly\x20created','msg':_0x2cfb05()[_0x1cd199('0x92c')](_0x5e69e5)+_0x1cd199('0x1eda')}),_0x459c19();})[_0x904e24('0x1a80')](function(_0x192605){const _0x14d91d=_0x904e24;console[_0x14d91d('0xfc9')](_0x192605),_0x495e38['errors']=_0x192605[_0x14d91d('0x25f4')][_0x14d91d('0x61a')]||[{'message':_0x192605[_0x14d91d('0x1586')](),'type':_0x14d91d('0x215d')}];});}function _0x484b3c(){const _0x294c42=_0x1a83c4;_0x495e38[_0x294c42('0x61a')]=[],_0x495e38[_0x294c42('0x117e')]&&(_0x495e38[_0x294c42('0x1301')][_0x294c42('0x1143')]=_0x495e38['customField']['id'],_0x495e38['item'][_0x294c42('0x3c0')]=_0x495e38[_0x294c42('0x117e')][_0x294c42('0x4f0')],_0x495e38['item'][_0x294c42('0x117e')]=_0x495e38[_0x294c42('0x117e')]['custom']),_0x5b4347[_0x294c42('0x1a97')][_0x294c42('0x1449')]({'id':_0x495e38[_0x294c42('0x1301')]['id']},_0x495e38[_0x294c42('0x1301')])[_0x294c42('0xa44')][_0x294c42('0x1166')](function(_0x4f9f24){const _0x4a7e14=_0x294c42,_0x4b8ca4=_0x2cfb05()[_0x4a7e14('0xc38')](_0x495e38[_0x4a7e14('0xbd7')],{'id':_0x4f9f24['id']});_0x4b8ca4&&_0x2cfb05()[_0x4a7e14('0xcc3')](_0x4b8ca4,_0x4f9f24),_0x289285[_0x4a7e14('0x103b')]({'title':_0x2cfb05()['capitalize'](_0x5e69e5)+_0x4a7e14('0x1a2f'),'msg':_0x2cfb05()[_0x4a7e14('0x92c')](_0x5e69e5)+_0x4a7e14('0x7d')}),_0x459c19();})['catch'](function(_0x1dc41c){const _0x5846b5=_0x294c42;console[_0x5846b5('0xfc9')](_0x1dc41c),_0x495e38[_0x5846b5('0x61a')]=_0x1dc41c[_0x5846b5('0x25f4')][_0x5846b5('0x61a')]||[{'message':_0x1dc41c[_0x5846b5('0x1586')](),'type':_0x5846b5('0x10cd')}];});}function _0x1d51aa(_0x46581a){const _0x4a18d8=_0x1a83c4;_0x495e38[_0x4a18d8('0x61a')]=[];const _0x582fa0=_0x299ed0[_0x4a18d8('0x1d26')]()[_0x4a18d8('0xcdc')](_0x4a18d8('0x7fb'))['content']('The\x20'+_0x5e69e5+_0x4a18d8('0x3f3'))[_0x4a18d8('0x8e8')]('Delete\x20'+_0x2cfb05()[_0x4a18d8('0x92c')](_0x5e69e5))['ok']('Delete')[_0x4a18d8('0x3f')](_0x4a18d8('0x497'))[_0x4a18d8('0x203b')](_0x46581a);_0x299ed0['show'](_0x582fa0)[_0x4a18d8('0x1166')](function(){const _0x1ddd09=_0x4a18d8;_0x5b4347[_0x1ddd09('0x1a97')][_0x1ddd09('0x906')]({'id':_0x495e38[_0x1ddd09('0x1301')]['id']})[_0x1ddd09('0xa44')][_0x1ddd09('0x1166')](function(){const _0x170e1e=_0x1ddd09;_0x2cfb05()['remove'](_0x495e38['items'],{'id':_0x495e38[_0x170e1e('0x1301')]['id']}),_0x289285[_0x170e1e('0x103b')]({'title':_0x2cfb05()['capitalize'](_0x5e69e5)+'\x20properly\x20deleted!','msg':_0x2cfb05()[_0x170e1e('0x92c')](_0x5e69e5)+_0x170e1e('0x7cd')}),_0x459c19();})['catch'](function(_0x1695bd){const _0x525a8f=_0x1ddd09;console[_0x525a8f('0xfc9')](_0x1695bd),_0x495e38[_0x525a8f('0x61a')]=_0x1695bd[_0x525a8f('0x25f4')][_0x525a8f('0x61a')]||[{'message':_0x1695bd[_0x525a8f('0x1586')](),'type':_0x525a8f('0x2602')}];});},function(){});}function _0x53ab2b(){const _0x46d045=_0x1a83c4;return _0x495e38[_0x46d045('0x1301')][_0x46d045('0xbdb')]!==undefined?_0x495e38[_0x46d045('0x1301')][_0x46d045('0xbdb')]:_0x46d045('0x16a4');}function _0x459c19(){const _0x6ec21e=_0x1a83c4;_0x299ed0[_0x6ec21e('0x1197')]();}}const _0x4d1df7=_0x2dbb55;_0xa63b12[_0x36e6f4('0x1294')]=['$state',_0x36e6f4('0x25e0'),'$mdDialog','$document',_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x1a8d'),_0x36e6f4('0x17aa')];function _0xa63b12(_0x1fed6b,_0x24bf34,_0x55f645,_0x4a0662,_0x2f9c50,_0x403be1,_0x22ad54,_0x1d3b62,_0x2a6467,_0x552505,_0x4fc039,_0x2fa155){const _0xcbdfd7=_0x36e6f4,_0x3eb96f=this;_0x3eb96f[_0xcbdfd7('0x98')]=_0x552505[_0xcbdfd7('0x26cd')](),_0x3eb96f['license']=_0x403be1,_0x3eb96f[_0xcbdfd7('0xf8a')]=_0x22ad54,_0x3eb96f[_0xcbdfd7('0x2900')]=_0x3eb96f[_0xcbdfd7('0xf8a')][_0xcbdfd7('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3eb96f[_0xcbdfd7('0x246b')]=_0x24bf34[_0xcbdfd7('0x6f1')]()+_0xcbdfd7('0xc51')+_0x24bf34[_0xcbdfd7('0x1690')](),_0x3eb96f[_0xcbdfd7('0x1a8d')]=_0x4fc039||_0x1fed6b[_0xcbdfd7('0x23f')][_0xcbdfd7('0x1a8d')]||{},_0x3eb96f[_0xcbdfd7('0x17aa')]=_0x2fa155&&_0x2fa155[_0xcbdfd7('0x240f')]==0x1?_0x2fa155[_0xcbdfd7('0x269a')][0x0]:null,_0x3eb96f['crudPermissions']=_0x552505['parseCrudPermissions'](_0x3eb96f[_0xcbdfd7('0x17aa')]?_0x3eb96f[_0xcbdfd7('0x17aa')][_0xcbdfd7('0x243c')]:null),_0x3eb96f[_0xcbdfd7('0x128b')]={},_0x3eb96f['selectedTab']=_0x1fed6b['params'][_0xcbdfd7('0xbe3')]||0x0,_0x3eb96f['alert']=_0x2a6467[_0xcbdfd7('0x1fa1')],_0x3eb96f[_0xcbdfd7('0x180b')]=_0x3721d9,_0x3eb96f['saveZendeskAccount']=_0x5cc717;function _0x3721d9(){const _0x170107=_0xcbdfd7;_0x1fed6b['go'](_0x170107('0x1600'),{},{'reload':_0x170107('0x1600')});}function _0x5cc717(){const _0x2508bc=_0xcbdfd7;_0x1d3b62[_0x2508bc('0x2290')][_0x2508bc('0x1449')]({'id':_0x3eb96f['zendeskAccount']['id']},_0x3eb96f['zendeskAccount'])[_0x2508bc('0xa44')][_0x2508bc('0x1166')](function(){const _0x3d90d0=_0x2508bc;_0x2a6467[_0x3d90d0('0x103b')]({'title':_0x3d90d0('0x1c27'),'msg':_0x3eb96f[_0x3d90d0('0x1a8d')][_0x3d90d0('0x4f0')]?_0x3eb96f['zendeskAccount']['name']+_0x3d90d0('0xa17'):''});})[_0x2508bc('0x1a80')](function(_0x2606c1){const _0x3bbfe9=_0x2508bc;_0x2a6467[_0x3bbfe9('0xfc9')]({'title':_0x2606c1[_0x3bbfe9('0x52d')]?'API:'+_0x2606c1[_0x3bbfe9('0x52d')]+_0x3bbfe9('0x11e1')+_0x2606c1[_0x3bbfe9('0xe1b')]:_0x3bbfe9('0x2416'),'msg':_0x2606c1['data']?JSON[_0x3bbfe9('0xbac')](_0x2606c1[_0x3bbfe9('0x25f4')]):_0x2606c1[_0x3bbfe9('0x1586')]()});});}}const _0x5c516e=_0xa63b12,_0xb0c1f=_0x2734b2['p']+_0x36e6f4('0x21d0'),_0x417ae7=_0x2734b2['p']+_0x36e6f4('0x1f7');_0x29100b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x19e3'),'toasty',_0x36e6f4('0x21ef')];function _0x29100b(_0x3fdbbe,_0x531c26,_0x4c3544,_0x42a690,_0x17e224){const _0xb7348d=_0x36e6f4,_0x310241=this;_0x310241['currentUser']=_0x17e224[_0xb7348d('0x26cd')](),_0x310241[_0xb7348d('0x1a8d')]={},_0x310241[_0xb7348d('0x7f8')]={},_0x310241[_0xb7348d('0xbdd')]=[],_0x310241[_0xb7348d('0x1408')]=-0x1,_0x310241['crudPermissions'],_0x310241[_0xb7348d('0x24d5')]=_0xc40fb5,_0x310241[_0xb7348d('0x714')]=_0x1264ea,_0x310241[_0xb7348d('0x19d1')]=_0x3388dc,_0x310241[_0xb7348d('0x254f')]=_0x143952,_0x310241[_0xb7348d('0x1726')]=[],_0x310241[_0xb7348d('0xa6a')]=_0x318b9e,_0x4c3544[_0xb7348d('0x1446')]['get']({'nolimit':!![],'sort':_0xb7348d('0x4f0')})[_0xb7348d('0xa44')][_0xb7348d('0x1166')](function(_0xf8b9b1){const _0x526bc7=_0xb7348d;_0x310241[_0x526bc7('0xb38')]=_0xf8b9b1[_0x526bc7('0x269a')]?_0xf8b9b1[_0x526bc7('0x269a')]:[];})[_0xb7348d('0x1a80')](function(_0x8aa72e){const _0x2d1da1=_0xb7348d;_0x42a690['error']({'title':_0x8aa72e[_0x2d1da1('0x52d')]?'API:'+_0x8aa72e[_0x2d1da1('0x52d')]+_0x2d1da1('0x11e1')+_0x8aa72e[_0x2d1da1('0xe1b')]:_0x2d1da1('0x2597'),'msg':_0x8aa72e[_0x2d1da1('0x25f4')]?JSON[_0x2d1da1('0xbac')](_0x8aa72e[_0x2d1da1('0x25f4')]):_0x8aa72e[_0x2d1da1('0x1586')]()});});function _0x318b9e(){const _0x4697de=_0xb7348d;_0x4c3544['intZendeskConfiguration'][_0x4697de('0x61b')]({'id':_0x310241[_0x4697de('0x7f8')]['id'],'ids':_0x310241[_0x4697de('0x1726')]})[_0x4697de('0xa44')]['then'](function(){const _0x3ba69a=_0x4697de;_0x42a690['success']({'title':_0x3ba69a('0x19e6'),'msg':_0x3ba69a('0x189')});})[_0x4697de('0x1a80')](function(_0x304852){const _0x35e9f2=_0x4697de;_0x42a690['error']({'title':_0x304852['status']?_0x35e9f2('0x1e21')+_0x304852[_0x35e9f2('0x52d')]+_0x35e9f2('0x11e1')+_0x304852[_0x35e9f2('0xe1b')]:_0x35e9f2('0x8f0'),'msg':_0x304852[_0x35e9f2('0x25f4')]?JSON[_0x35e9f2('0xbac')](_0x304852[_0x35e9f2('0x25f4')]):_0x304852['toString']()});});}function _0xc40fb5(_0x196e1f,_0x46ce79){const _0x1bac39=_0xb7348d;_0x310241['zendeskAccount']=_0x196e1f,_0x310241[_0x1bac39('0x243c')]=typeof _0x46ce79!=='undefined'?_0x46ce79:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4c3544[_0x1bac39('0x2290')][_0x1bac39('0x13db')]({'id':_0x310241['zendeskAccount']['id'],'sort':'-updatedAt'})['$promise'][_0x1bac39('0x1166')](function(_0x1c4925){const _0x5d4308=_0x1bac39;return _0x310241[_0x5d4308('0xbdd')]=_0x1c4925['rows']?_0x1c4925['rows']:[],_0x310241[_0x5d4308('0xbdd')][_0x5d4308('0x264b')]&&_0x310241[_0x5d4308('0x714')](0x0),_0x4c3544[_0x5d4308('0x734')][_0x5d4308('0xd83')]({'nolimit':!![],'sort':_0x5d4308('0x4f0')})['$promise'];})[_0x1bac39('0x1166')](function(_0x593458){const _0x478b95=_0x1bac39;_0x310241[_0x478b95('0x57a')]=_0x593458['rows']?_0x593458['rows']:[],_0x310241[_0x478b95('0x217a')]=_0x2cfb05()[_0x478b95('0x155c')](_0x310241['variables'],'id');})[_0x1bac39('0x1a80')](function(_0x5668e0){const _0x4bada0=_0x1bac39;_0x42a690['error']({'title':_0x5668e0['status']?_0x4bada0('0x1e21')+_0x5668e0['status']+_0x4bada0('0x11e1')+_0x5668e0[_0x4bada0('0xe1b')]:_0x4bada0('0x17ab'),'msg':_0x5668e0[_0x4bada0('0x25f4')]?JSON['stringify'](_0x5668e0[_0x4bada0('0x25f4')]):_0x5668e0['toString']()});});}function _0x1264ea(_0x16df10){const _0x45f2c2=_0xb7348d;_0x310241['zendeskConfiguration']=_0x310241[_0x45f2c2('0xbdd')][_0x16df10],_0x310241[_0x45f2c2('0x1408')]=_0x16df10,_0x4c3544[_0x45f2c2('0xaf9')][_0x45f2c2('0x154d')]({'id':_0x310241[_0x45f2c2('0x7f8')]['id']})[_0x45f2c2('0xa44')][_0x45f2c2('0x1166')](function(_0x263e18){const _0x5b0fd1=_0x45f2c2;return _0x310241[_0x5b0fd1('0x2701')]=_0x263e18[_0x5b0fd1('0x269a')]?_0x263e18['rows']:[],_0x4c3544[_0x5b0fd1('0xaf9')]['getDescriptions']({'id':_0x310241['zendeskConfiguration']['id']})['$promise'];})[_0x45f2c2('0x1166')](function(_0xe6439b){const _0x190112=_0x45f2c2;return _0x310241['descriptions']=_0xe6439b[_0x190112('0x269a')]?_0xe6439b['rows']:[],_0x4c3544[_0x190112('0xaf9')][_0x190112('0x18ea')]({'id':_0x310241[_0x190112('0x7f8')]['id']})[_0x190112('0xa44')];})['then'](function(_0x2d9ff7){const _0x62d97=_0x45f2c2;_0x310241[_0x62d97('0xfe2')]=_0x2d9ff7[_0x62d97('0x269a')]?_0x2d9ff7['rows']:[];})['catch'](function(_0x1a319b){const _0x53d15c=_0x45f2c2;_0x42a690[_0x53d15c('0xfc9')]({'title':_0x1a319b[_0x53d15c('0x52d')]?_0x53d15c('0x1e21')+_0x1a319b[_0x53d15c('0x52d')]+_0x53d15c('0x11e1')+_0x1a319b[_0x53d15c('0xe1b')]:_0x53d15c('0x16c7'),'msg':_0x1a319b[_0x53d15c('0x25f4')]?JSON[_0x53d15c('0xbac')](_0x1a319b['data']):_0x1a319b['toString']()});}),_0x4c3544[_0x45f2c2('0xaf9')]['getTags']({'id':_0x310241[_0x45f2c2('0x7f8')]['id']})[_0x45f2c2('0xa44')][_0x45f2c2('0x1166')](function(_0x319d89){const _0x286e54=_0x45f2c2;_0x310241[_0x286e54('0x1726')]=_0x319d89['rows']?_0x2cfb05()['map'](_0x319d89[_0x286e54('0x269a')],'id'):[];})[_0x45f2c2('0x1a80')](function(_0x3502f2){const _0x3e301f=_0x45f2c2;_0x42a690[_0x3e301f('0xfc9')]({'title':_0x3502f2[_0x3e301f('0x52d')]?_0x3e301f('0x1e21')+_0x3502f2[_0x3e301f('0x52d')]+_0x3e301f('0x11e1')+_0x3502f2[_0x3e301f('0xe1b')]:_0x3e301f('0x2597'),'msg':_0x3502f2[_0x3e301f('0x25f4')]?JSON[_0x3e301f('0xbac')](_0x3502f2[_0x3e301f('0x25f4')]):_0x3502f2[_0x3e301f('0x1586')]()});});}function _0x3388dc(_0x4555e5,_0x321d73){const _0x2e0532=_0xb7348d;_0x3fdbbe[_0x2e0532('0x1f80')]({'controller':_0x2e0532('0x1ad8'),'controllerAs':'vm','templateUrl':_0xb0c1f,'parent':angular[_0x2e0532('0x1194')](_0x531c26[_0x2e0532('0x8d2')]),'targetEvent':_0x4555e5,'clickOutsideToClose':!![],'locals':{'zendeskConfiguration':_0x321d73,'zendeskConfigurations':_0x310241[_0x2e0532('0xbdd')],'license':null,'setting':null,'crudPermissions':_0x310241[_0x2e0532('0x243c')]}})[_0x2e0532('0x1951')](function(){const _0x3dce16=_0x2e0532;_0x310241[_0x3dce16('0x714')](0x0);});}function _0x143952(_0x324654,_0x1b28cc){const _0x561e2f=_0xb7348d,_0x54fe5d=_0x3fdbbe['confirm']()[_0x561e2f('0xcdc')](_0x561e2f('0xb33'))[_0x561e2f('0xf3c')](_0x561e2f('0x12b5')+(_0x1b28cc[_0x561e2f('0x4f0')]||'zendeskConfiguration')+_0x561e2f('0xace')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x561e2f('0x12d1'))[_0x561e2f('0x203b')](_0x324654)['ok']('OK')[_0x561e2f('0x3f')](_0x561e2f('0x2d3'));_0x3fdbbe[_0x561e2f('0x1f80')](_0x54fe5d)['then'](function(){const _0x3887b1=_0x561e2f;_0x4c3544['intZendeskConfiguration'][_0x3887b1('0x906')]({'id':_0x1b28cc['id']})[_0x3887b1('0xa44')][_0x3887b1('0x1166')](function(){const _0x378f91=_0x3887b1;_0x2cfb05()[_0x378f91('0x127f')](_0x310241['zendeskConfigurations'],{'id':_0x1b28cc['id']}),_0x42a690['success']({'title':'ZendeskConfiguration\x20deleted!','msg':_0x1b28cc[_0x378f91('0x4f0')]?_0x1b28cc[_0x378f91('0x4f0')]+_0x378f91('0x7cd'):''});})[_0x3887b1('0x1a80')](function(_0x22ff9e){const _0x2f8cf2=_0x3887b1;_0x42a690[_0x2f8cf2('0xfc9')]({'title':_0x22ff9e[_0x2f8cf2('0x52d')]?_0x2f8cf2('0x1e21')+_0x22ff9e[_0x2f8cf2('0x52d')]+'\x20-\x20'+_0x22ff9e['statusText']:_0x2f8cf2('0x19a8'),'msg':_0x22ff9e[_0x2f8cf2('0x25f4')]?JSON[_0x2f8cf2('0xbac')](_0x22ff9e[_0x2f8cf2('0x25f4')]):_0x22ff9e[_0x2f8cf2('0x1586')]()});})[_0x3887b1('0x1951')](function(){const _0x1e3d63=_0x3887b1;_0x310241[_0x1e3d63('0x714')](0x0);});},function(){const _0xbfdf82=_0x561e2f;console[_0xbfdf82('0x455')](_0xbfdf82('0x2d3'));});}_0x310241[_0xb7348d('0xd02')]=[],_0x310241[_0xb7348d('0x1a33')]=_0xfbe88b,_0x310241[_0xb7348d('0x2059')]=_0x39b65d,_0x310241['deleteSelectedSubjects']=_0x1d00de;function _0xfbe88b(_0x5f1c8e,_0x4bdc8c){const _0x2513d0=_0xb7348d;_0x3fdbbe[_0x2513d0('0x1f80')]({'controller':_0x2513d0('0x1d87'),'controllerAs':'vm','templateUrl':_0x417ae7,'parent':angular['element'](_0x531c26[_0x2513d0('0x8d2')]),'targetEvent':_0x5f1c8e,'clickOutsideToClose':!![],'locals':{'type':_0x2513d0('0x210d'),'item':_0x4bdc8c,'items':_0x310241['subjects'],'configuration':_0x310241['zendeskConfiguration'],'account':_0x310241[_0x2513d0('0x1a8d')],'license':null,'setting':null,'crudPermissions':_0x310241[_0x2513d0('0x243c')]}});}function _0x940394(_0x8d67e3){const _0x2412be=_0xb7348d;_0x4c3544[_0x2412be('0x1a97')][_0x2412be('0x906')]({'id':_0x8d67e3['id']})[_0x2412be('0xa44')]['then'](function(){const _0x148461=_0x2412be;_0x2cfb05()[_0x148461('0x127f')](_0x310241['subjects'],{'id':_0x8d67e3['id']}),_0x42a690[_0x148461('0x103b')]({'title':_0x148461('0x6f'),'msg':'Subject\x20has\x20been\x20deleted!'});})[_0x2412be('0x1a80')](function(_0xebe91a){const _0x248bb5=_0x2412be;_0x42a690[_0x248bb5('0xfc9')]({'title':_0xebe91a[_0x248bb5('0x52d')]?_0x248bb5('0x1e21')+_0xebe91a['status']+'\x20-\x20'+_0xebe91a[_0x248bb5('0xe1b')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0xebe91a[_0x248bb5('0x25f4')]?JSON[_0x248bb5('0xbac')](_0xebe91a[_0x248bb5('0x25f4')]):_0xebe91a[_0x248bb5('0x1586')]()});});}function _0x39b65d(_0x387538,_0x421a12){const _0x2ec697=_0xb7348d,_0x3eccdf=_0x3fdbbe[_0x2ec697('0x1d26')]()['title'](_0x2ec697('0x11c8'))[_0x2ec697('0xf3c')](_0x2ec697('0x277a')+_0x2ec697('0x3f3'))[_0x2ec697('0x8e8')]('delete\x20subject')['targetEvent'](_0x387538)['ok']('OK')[_0x2ec697('0x3f')]('CANCEL');_0x3fdbbe[_0x2ec697('0x1f80')](_0x3eccdf)[_0x2ec697('0x1166')](function(){_0x940394(_0x421a12);},function(){const _0x55b624=_0x2ec697;console[_0x55b624('0x455')]('CANCEL');});}function _0x1d00de(_0xcfb250){const _0x9a218d=_0xb7348d,_0x398bdb=_0x3fdbbe['confirm']()[_0x9a218d('0xcdc')](_0x9a218d('0x1d64'))[_0x9a218d('0xf3c')](_0x9a218d('0x12b5')+_0x310241[_0x9a218d('0xd02')][_0x9a218d('0x264b')]+_0x9a218d('0x196d')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x9a218d('0x5b2'))[_0x9a218d('0x203b')](_0xcfb250)['ok']('OK')[_0x9a218d('0x3f')](_0x9a218d('0x2d3'));_0x3fdbbe['show'](_0x398bdb)[_0x9a218d('0x1166')](function(){const _0x3c96f3=_0x9a218d;_0x310241[_0x3c96f3('0xd02')][_0x3c96f3('0x2782')](function(_0x46c033){_0x940394(_0x46c033);}),_0x310241[_0x3c96f3('0xd02')]=[];});}_0x310241[_0xb7348d('0x968')]=[],_0x310241[_0xb7348d('0x2185')]=_0x36b43,_0x310241[_0xb7348d('0xdf3')]=_0x2bd579,_0x310241[_0xb7348d('0x2269')]=_0x58e8df;function _0x36b43(_0x1270f9,_0xaee09c){const _0x29dad3=_0xb7348d;_0x3fdbbe[_0x29dad3('0x1f80')]({'controller':_0x29dad3('0x1d87'),'controllerAs':'vm','templateUrl':_0x417ae7,'parent':angular[_0x29dad3('0x1194')](_0x531c26['body']),'targetEvent':_0x1270f9,'clickOutsideToClose':!![],'locals':{'type':_0x29dad3('0x101c'),'item':_0xaee09c,'items':_0x310241[_0x29dad3('0x1b3d')],'configuration':_0x310241[_0x29dad3('0x7f8')],'account':_0x310241['zendeskAccount'],'license':null,'setting':null,'crudPermissions':_0x310241['crudPermissions']}});}function _0x340742(_0x2a8b45){const _0x8f45bb=_0xb7348d;_0x4c3544[_0x8f45bb('0x1a97')][_0x8f45bb('0x906')]({'id':_0x2a8b45['id']})['$promise'][_0x8f45bb('0x1166')](function(){const _0x46b1d9=_0x8f45bb;_0x2cfb05()[_0x46b1d9('0x127f')](_0x310241[_0x46b1d9('0x1b3d')],{'id':_0x2a8b45['id']}),_0x42a690[_0x46b1d9('0x103b')]({'title':_0x46b1d9('0x9c1'),'msg':_0x46b1d9('0x12ae')});})[_0x8f45bb('0x1a80')](function(_0x349b4f){const _0x34631d=_0x8f45bb;_0x42a690[_0x34631d('0xfc9')]({'title':_0x349b4f[_0x34631d('0x52d')]?'API:'+_0x349b4f[_0x34631d('0x52d')]+_0x34631d('0x11e1')+_0x349b4f[_0x34631d('0xe1b')]:_0x34631d('0x23ff'),'msg':_0x349b4f[_0x34631d('0x25f4')]?JSON[_0x34631d('0xbac')](_0x349b4f[_0x34631d('0x25f4')]):_0x349b4f['toString']()});});}function _0x2bd579(_0x235194,_0x1bc5d7){const _0x496bf2=_0xb7348d,_0x3c96ea=_0x3fdbbe[_0x496bf2('0x1d26')]()['title'](_0x496bf2('0x1baa'))[_0x496bf2('0xf3c')](_0x496bf2('0x1809')+_0x496bf2('0x3f3'))[_0x496bf2('0x8e8')](_0x496bf2('0x1bc0'))[_0x496bf2('0x203b')](_0x235194)['ok']('OK')[_0x496bf2('0x3f')](_0x496bf2('0x2d3'));_0x3fdbbe['show'](_0x3c96ea)[_0x496bf2('0x1166')](function(){_0x340742(_0x1bc5d7);},function(){const _0x582bb9=_0x496bf2;console[_0x582bb9('0x455')](_0x582bb9('0x2d3'));});}function _0x58e8df(_0x2c9779){const _0x4a35d4=_0xb7348d,_0x456cb8=_0x3fdbbe[_0x4a35d4('0x1d26')]()[_0x4a35d4('0xcdc')](_0x4a35d4('0x29'))[_0x4a35d4('0xf3c')](_0x4a35d4('0x12b5')+_0x310241[_0x4a35d4('0x968')][_0x4a35d4('0x264b')]+_0x4a35d4('0x196d')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x4a35d4('0x17a'))['targetEvent'](_0x2c9779)['ok']('OK')[_0x4a35d4('0x3f')](_0x4a35d4('0x2d3'));_0x3fdbbe[_0x4a35d4('0x1f80')](_0x456cb8)[_0x4a35d4('0x1166')](function(){const _0x4b9f31=_0x4a35d4;_0x310241['selectedDescriptions'][_0x4b9f31('0x2782')](function(_0x2bedc3){_0x340742(_0x2bedc3);}),_0x310241[_0x4b9f31('0x968')]=[];});}_0x310241[_0xb7348d('0x16')]=[],_0x310241[_0xb7348d('0x27ad')]=_0x395d42,_0x310241[_0xb7348d('0xbda')]=_0x3ab6d1,_0x310241[_0xb7348d('0x1ace')]=_0x257366;function _0x395d42(_0x39625f,_0x2cd346){const _0x41dbe2=_0xb7348d;_0x3fdbbe[_0x41dbe2('0x1f80')]({'controller':'CreateOrEditZendeskAccountItemDialogController','controllerAs':'vm','templateUrl':_0x417ae7,'parent':angular[_0x41dbe2('0x1194')](_0x531c26[_0x41dbe2('0x8d2')]),'targetEvent':_0x39625f,'clickOutsideToClose':!![],'locals':{'type':'field','item':_0x2cd346,'items':_0x310241[_0x41dbe2('0xfe2')],'configuration':_0x310241[_0x41dbe2('0x7f8')],'account':_0x310241[_0x41dbe2('0x1a8d')],'license':null,'setting':null,'crudPermissions':_0x310241[_0x41dbe2('0x243c')]}});}function _0x4c84f5(_0xad46d9){const _0x4e472b=_0xb7348d;_0x4c3544['intZendeskField'][_0x4e472b('0x906')]({'id':_0xad46d9['id']})[_0x4e472b('0xa44')][_0x4e472b('0x1166')](function(){const _0x2dec8e=_0x4e472b;_0x2cfb05()[_0x2dec8e('0x127f')](_0x310241[_0x2dec8e('0xfe2')],{'id':_0xad46d9['id']}),_0x42a690['success']({'title':_0x2dec8e('0x13cb'),'msg':'Field\x20has\x20been\x20deleted!'});})[_0x4e472b('0x1a80')](function(_0x2828a0){const _0x3c7b1e=_0x4e472b;_0x42a690['error']({'title':_0x2828a0[_0x3c7b1e('0x52d')]?_0x3c7b1e('0x1e21')+_0x2828a0['status']+_0x3c7b1e('0x11e1')+_0x2828a0[_0x3c7b1e('0xe1b')]:_0x3c7b1e('0x23ff'),'msg':_0x2828a0[_0x3c7b1e('0x25f4')]?JSON[_0x3c7b1e('0xbac')](_0x2828a0['data']):_0x2828a0[_0x3c7b1e('0x1586')]()});});}function _0x3ab6d1(_0x288de8,_0x39e356){const _0x356aa4=_0xb7348d,_0x40a559=_0x3fdbbe[_0x356aa4('0x1d26')]()[_0x356aa4('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x356aa4('0xf3c')](_0x356aa4('0x13e0')+_0x356aa4('0x3f3'))[_0x356aa4('0x8e8')](_0x356aa4('0x2127'))[_0x356aa4('0x203b')](_0x288de8)['ok']('OK')[_0x356aa4('0x3f')](_0x356aa4('0x2d3'));_0x3fdbbe[_0x356aa4('0x1f80')](_0x40a559)[_0x356aa4('0x1166')](function(){_0x4c84f5(_0x39e356);},function(){const _0x3db393=_0x356aa4;console[_0x3db393('0x455')](_0x3db393('0x2d3'));});}function _0x257366(_0x79f5d6){const _0x72bed9=_0xb7348d,_0x4cc8f4=_0x3fdbbe[_0x72bed9('0x1d26')]()[_0x72bed9('0xcdc')](_0x72bed9('0x1d42'))[_0x72bed9('0xf3c')](''+_0x310241[_0x72bed9('0x16')]['length']+'\x20selected'+_0x72bed9('0x3f3'))[_0x72bed9('0x8e8')]('delete\x20fields')[_0x72bed9('0x203b')](_0x79f5d6)['ok']('OK')[_0x72bed9('0x3f')](_0x72bed9('0x2d3'));_0x3fdbbe[_0x72bed9('0x1f80')](_0x4cc8f4)[_0x72bed9('0x1166')](function(){const _0x374e87=_0x72bed9;_0x310241['selectedFields'][_0x374e87('0x2782')](function(_0x4fd876){_0x4c84f5(_0x4fd876);}),_0x310241['selectedFields']=[];});}}const _0x5eab8b=_0x29100b;_0x31ee51[_0x36e6f4('0x1294')]=['$scope','$state',_0x36e6f4('0x25e0'),'$mdDialog','$q','$translate','toasty',_0x36e6f4('0xbdd'),'zendeskConfiguration',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting','crudPermissions'];function _0x31ee51(_0x1f9fc9,_0x4df270,_0x590f1b,_0x4d02ea,_0x244dd8,_0x438087,_0x14101f,_0x112a4f,_0x38929c,_0x19856e,_0x2f25b4,_0x4cef46,_0x1477ba,_0x35172e){const _0x3d3ae8=_0x36e6f4,_0x263bab=this;_0x263bab[_0x3d3ae8('0x98')]=_0x2f25b4['getCurrentUser'](),_0x263bab[_0x3d3ae8('0x61a')]=[],_0x263bab[_0x3d3ae8('0xf8a')]=_0x1477ba,_0x263bab[_0x3d3ae8('0x5c9')]=_0x4cef46,_0x263bab[_0x3d3ae8('0x243c')]=_0x35172e,_0x263bab[_0x3d3ae8('0x128b')]={},_0x263bab[_0x3d3ae8('0x2900')]=_0x263bab[_0x3d3ae8('0xf8a')]&&_0x263bab['setting'][_0x3d3ae8('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x263bab[_0x3d3ae8('0xcdc')]=_0x3d3ae8('0x1bbe'),_0x263bab[_0x3d3ae8('0x7f8')]=angular[_0x3d3ae8('0x225f')](_0x38929c),_0x263bab[_0x3d3ae8('0xbdd')]=_0x112a4f,_0x263bab['newZendeskConfiguration']=![];!_0x263bab[_0x3d3ae8('0x7f8')]&&(_0x263bab[_0x3d3ae8('0x7f8')]={'channel':_0x3d3ae8('0x21da'),'type':_0x3d3ae8('0x14d8')},_0x263bab[_0x3d3ae8('0xcdc')]='INTEGRATIONS.NEW_ZENDESKCONFIGURATION',_0x263bab[_0x3d3ae8('0xef0')]=!![]);_0x263bab[_0x3d3ae8('0xedc')]=_0x2cb673,_0x263bab[_0x3d3ae8('0x21af')]=_0x5add42,_0x263bab[_0x3d3ae8('0x254f')]=_0x23354a,_0x263bab[_0x3d3ae8('0x1a9c')]=_0x41676c,_0x263bab[_0x3d3ae8('0x24a0')]=_0x287e56;function _0x2cb673(){const _0x353de4=_0x3d3ae8;_0x263bab[_0x353de4('0x61a')]=[],_0x19856e[_0x353de4('0x2290')][_0x353de4('0x274a')]({'id':_0x4df270[_0x353de4('0x23f')]['id']},_0x263bab[_0x353de4('0x7f8')])[_0x353de4('0xa44')][_0x353de4('0x1166')](function(_0x602e32){const _0x6b879=_0x353de4;_0x263bab['zendeskConfigurations'][_0x6b879('0x2450')](_0x602e32[_0x6b879('0x2876')]()),_0x14101f[_0x6b879('0x103b')]({'title':'ZendeskConfiguration\x20properly\x20created','msg':_0x263bab[_0x6b879('0x7f8')][_0x6b879('0x4f0')]?_0x263bab['zendeskConfiguration'][_0x6b879('0x4f0')]+_0x6b879('0x1eda'):''}),_0x287e56(_0x602e32);})[_0x353de4('0x1a80')](function(_0x1fc0df){const _0x4a6e74=_0x353de4;if(_0x1fc0df[_0x4a6e74('0x25f4')]&&_0x1fc0df[_0x4a6e74('0x25f4')]['errors']&&_0x1fc0df[_0x4a6e74('0x25f4')][_0x4a6e74('0x61a')][_0x4a6e74('0x264b')]){_0x263bab['errors']=_0x1fc0df[_0x4a6e74('0x25f4')][_0x4a6e74('0x61a')]||[{'message':_0x1fc0df[_0x4a6e74('0x1586')](),'type':_0x4a6e74('0xb1a')}];for(let _0x1d97d8=0x0;_0x1d97d8<_0x1fc0df[_0x4a6e74('0x25f4')]['errors']['length'];_0x1d97d8+=0x1){_0x14101f[_0x4a6e74('0xfc9')]({'title':_0x1fc0df[_0x4a6e74('0x25f4')]['errors'][_0x1d97d8][_0x4a6e74('0x1345')],'msg':_0x1fc0df['data'][_0x4a6e74('0x61a')][_0x1d97d8]['message']});}}else _0x14101f[_0x4a6e74('0xfc9')]({'title':_0x1fc0df[_0x4a6e74('0x52d')]?_0x4a6e74('0x1e21')+_0x1fc0df[_0x4a6e74('0x52d')]+_0x4a6e74('0x11e1')+_0x1fc0df[_0x4a6e74('0xe1b')]:_0x4a6e74('0xb1a'),'msg':_0x1fc0df[_0x4a6e74('0x25f4')]?JSON[_0x4a6e74('0xbac')](_0x1fc0df[_0x4a6e74('0x25f4')][_0x4a6e74('0x1e70')]):_0x1fc0df[_0x4a6e74('0x1586')]()});});}function _0x5add42(){const _0x361771=_0x3d3ae8;_0x263bab[_0x361771('0x61a')]=[],_0x19856e[_0x361771('0xaf9')][_0x361771('0x1449')]({'id':_0x263bab['zendeskConfiguration']['id']},_0x263bab['zendeskConfiguration'])[_0x361771('0xa44')][_0x361771('0x1166')](function(_0x70b030){const _0x2976d5=_0x361771,_0x29d478=_0x2cfb05()[_0x2976d5('0xc38')](_0x263bab[_0x2976d5('0xbdd')],{'id':_0x70b030['id']});_0x29d478&&_0x2cfb05()['merge'](_0x29d478,_0x2cfb05()['pick'](_0x70b030[_0x2976d5('0x2876')](),_0x2cfb05()[_0x2976d5('0x14a4')](_0x29d478))),_0x14101f[_0x2976d5('0x103b')]({'title':_0x2976d5('0x8c3'),'msg':_0x263bab[_0x2976d5('0x7f8')][_0x2976d5('0x4f0')]?_0x263bab['zendeskConfiguration']['name']+'\x20has\x20been\x20saved!':''}),_0x287e56(_0x70b030);})[_0x361771('0x1a80')](function(_0x37212a){const _0x3d4ae9=_0x361771;if(_0x37212a['data']&&_0x37212a[_0x3d4ae9('0x25f4')][_0x3d4ae9('0x61a')]&&_0x37212a[_0x3d4ae9('0x25f4')]['errors'][_0x3d4ae9('0x264b')]){_0x263bab[_0x3d4ae9('0x61a')]=_0x37212a[_0x3d4ae9('0x25f4')][_0x3d4ae9('0x61a')]||[{'message':_0x37212a[_0x3d4ae9('0x1586')](),'type':_0x3d4ae9('0x21a2')}];for(let _0x3c7761=0x0;_0x3c7761<_0x37212a['data'][_0x3d4ae9('0x61a')][_0x3d4ae9('0x264b')];_0x3c7761++){_0x14101f[_0x3d4ae9('0xfc9')]({'title':_0x37212a[_0x3d4ae9('0x25f4')][_0x3d4ae9('0x61a')][_0x3c7761][_0x3d4ae9('0x1345')],'msg':_0x37212a[_0x3d4ae9('0x25f4')][_0x3d4ae9('0x61a')][_0x3c7761]['message']});}}else _0x14101f[_0x3d4ae9('0xfc9')]({'title':_0x37212a[_0x3d4ae9('0x52d')]?_0x3d4ae9('0x1e21')+_0x37212a[_0x3d4ae9('0x52d')]+_0x3d4ae9('0x11e1')+_0x37212a[_0x3d4ae9('0xe1b')]:_0x3d4ae9('0x21a2'),'msg':_0x37212a[_0x3d4ae9('0x25f4')]?JSON['stringify'](_0x37212a[_0x3d4ae9('0x25f4')][_0x3d4ae9('0x1e70')]):_0x37212a[_0x3d4ae9('0x1586')]()});});}function _0x23354a(_0x4a39af){const _0x3e79c0=_0x3d3ae8;_0x263bab[_0x3e79c0('0x61a')]=[];const _0x520501=_0x4d02ea[_0x3e79c0('0x1d26')]()[_0x3e79c0('0xcdc')](_0x3e79c0('0x7fb'))[_0x3e79c0('0xacc')]('The\x20zendeskConfiguration\x20will\x20be\x20deleted.')[_0x3e79c0('0x8e8')](_0x3e79c0('0x192a'))['ok'](_0x3e79c0('0x18'))['cancel'](_0x3e79c0('0x497'))[_0x3e79c0('0x203b')](_0x4a39af);_0x4d02ea['show'](_0x520501)[_0x3e79c0('0x1166')](function(){const _0x585b06=_0x3e79c0;_0x19856e[_0x585b06('0xaf9')][_0x585b06('0x906')]({'id':_0x263bab['zendeskConfiguration']['id']})['$promise'][_0x585b06('0x1166')](function(){const _0x4e66ce=_0x585b06;_0x2cfb05()[_0x4e66ce('0x127f')](_0x263bab[_0x4e66ce('0xbdd')],{'id':_0x263bab[_0x4e66ce('0x7f8')]['id']}),_0x14101f[_0x4e66ce('0x103b')]({'title':'ZendeskConfiguration\x20properly\x20deleted!','msg':(_0x263bab[_0x4e66ce('0x7f8')]['name']||_0x4e66ce('0x7f8'))+'\x20has\x20been\x20deleted!'}),_0x287e56(_0x263bab[_0x4e66ce('0x7f8')]);})['catch'](function(_0x52bbc9){const _0x4cebd9=_0x585b06;if(_0x52bbc9[_0x4cebd9('0x25f4')]&&_0x52bbc9[_0x4cebd9('0x25f4')][_0x4cebd9('0x61a')]&&_0x52bbc9[_0x4cebd9('0x25f4')][_0x4cebd9('0x61a')][_0x4cebd9('0x264b')]){_0x263bab[_0x4cebd9('0x61a')]=_0x52bbc9[_0x4cebd9('0x25f4')][_0x4cebd9('0x61a')]||[{'message':_0x52bbc9[_0x4cebd9('0x1586')](),'type':_0x4cebd9('0x46')}];for(let _0x4401f2=0x0;_0x4401f2<_0x52bbc9[_0x4cebd9('0x25f4')][_0x4cebd9('0x61a')][_0x4cebd9('0x264b')];_0x4401f2++){_0x14101f[_0x4cebd9('0xfc9')]({'title':_0x52bbc9['data'][_0x4cebd9('0x61a')][_0x4401f2]['type'],'msg':_0x52bbc9[_0x4cebd9('0x25f4')][_0x4cebd9('0x61a')][_0x4401f2][_0x4cebd9('0x1e70')]});}}else _0x14101f[_0x4cebd9('0xfc9')]({'title':_0x52bbc9[_0x4cebd9('0x52d')]?_0x4cebd9('0x1e21')+_0x52bbc9[_0x4cebd9('0x52d')]+_0x4cebd9('0x11e1')+_0x52bbc9['statusText']:'api.intZendeskConfiguration.delete','msg':_0x52bbc9[_0x4cebd9('0x25f4')]?JSON['stringify'](_0x52bbc9[_0x4cebd9('0x25f4')][_0x4cebd9('0x1e70')]):_0x52bbc9['message']||_0x52bbc9['toString']()});});},function(){});}function _0x41676c(_0xa10fa9){return _0xa10fa9===null?undefined:new Date(_0xa10fa9);}function _0x287e56(_0x31b3df){const _0x25978c=_0x3d3ae8;_0x4d02ea[_0x25978c('0x1197')](_0x31b3df);}}const _0x5b3894=_0x31ee51,_0x1fd494=_0x2734b2['p']+_0x36e6f4('0x1c4a');_0xef64b4[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0xf34'),'userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0xef64b4(_0x1ce11e,_0x5382ee,_0x1fbfeb,_0xf2f34,_0x4c12a5,_0x2920a5,_0x8e53b9,_0x49ebed,_0x5876da,_0x2bec3f,_0x3ba30e,_0x2cdbb2,_0xbe06a7,_0x417f85,_0x4e0f3f,_0x215b55,_0x377d72){const _0x384fff=_0x36e6f4,_0x490491=this;_0x490491['license']=_0x215b55,_0x490491['setting']=_0x377d72,_0x490491[_0x384fff('0x98')]=_0x4e0f3f[_0x384fff('0x26cd')](),_0x490491[_0x384fff('0xf34')]=_0x5876da||{'count':0x0,'rows':[]},_0x490491[_0x384fff('0x7f')]=_0x2bec3f,_0x490491[_0x384fff('0x17aa')]=_0x3ba30e&&_0x3ba30e[_0x384fff('0x240f')]==0x1?_0x3ba30e[_0x384fff('0x269a')][0x0]:null,_0x490491[_0x384fff('0x243c')]=_0x4e0f3f[_0x384fff('0xd87')](_0x490491[_0x384fff('0x17aa')]?_0x490491['userProfileSection'][_0x384fff('0x243c')]:null),_0x490491[_0x384fff('0x916')]=_0x384fff('0xf34'),_0x490491[_0x384fff('0xef5')]='',_0x490491['listOrderAsc']=null,_0x490491[_0x384fff('0x24a8')]=[],_0x490491['query']={'fields':_0x384fff('0x1e71'),'limit':0xa,'page':0x1},_0x490491[_0x384fff('0x2736')]=_0x2cfb05()[_0x384fff('0x155c')]([{'option':_0x384fff('0x40b'),'value':_0x384fff('0x2496')},{'option':_0x384fff('0x205c'),'value':'\x27newTab\x27'}],function(_0x302528){const _0x551af2=_0x384fff;return _0x2cfb05()[_0x551af2('0xf3')](_0x302528[_0x551af2('0x18e0')],new RegExp('\x27','g'),'');}),_0x490491[_0x384fff('0x1038')]=_0x2cfb05()[_0x384fff('0x155c')]([{'option':_0x384fff('0x1c9c'),'value':_0x384fff('0xb84')},{'option':_0x384fff('0xb4b'),'value':_0x384fff('0x14cb')}],function(_0x21d32a){const _0x2c4f4c=_0x384fff;return _0x2cfb05()[_0x2c4f4c('0xf3')](_0x21d32a[_0x2c4f4c('0x18e0')],new RegExp('\x27','g'),'');}),_0x490491[_0x384fff('0x1ff6')]=_0x1d3904,_0x490491[_0x384fff('0x2113')]=_0x2cd4a2,_0x490491[_0x384fff('0x8d8')]=_0x4c2ee2,_0x490491[_0x384fff('0x103b')]=_0x5da586,_0x490491[_0x384fff('0x1763')]=_0x1648cd,_0x490491[_0x384fff('0xea0')]=_0xd88f9d,_0x490491['deleteZendeskAccount']=_0x74b949,_0x490491['exportSelectedZendeskAccounts']=_0x907799,_0x490491[_0x384fff('0x1ee2')]=_0x3d9b5b,_0x490491[_0x384fff('0x634')]=_0x58110e,_0x490491['selectAllZendeskAccounts']=_0x15e554;function _0x1d3904(_0x187ed6){const _0x58fc85=_0x384fff;_0x1fbfeb['go'](_0x58fc85('0x2630'),{'id':_0x187ed6['id'],'zendeskAccount':_0x187ed6,'crudPermissions':_0x490491[_0x58fc85('0x243c')]});}function _0x2cd4a2(_0x388507){const _0x3000e7=_0x384fff;return _0x2cdbb2['intZendeskAccount'][_0x3000e7('0x18ea')]({'id':_0x388507['id'],'test':!![]})[_0x3000e7('0xa44')][_0x3000e7('0x1166')](function(){const _0x53cac8=_0x3000e7;_0x417f85[_0x53cac8('0x103b')]({'title':_0x53cac8('0x1992'),'msg':_0x53cac8('0x1fef')});})[_0x3000e7('0x1a80')](function(_0x2a1754){const _0x1b3fb1=_0x3000e7;_0x417f85[_0x1b3fb1('0xfc9')]({'title':_0x1b3fb1('0x1992'),'msg':_0x2a1754[_0x1b3fb1('0x25f4')]?_0x2a1754[_0x1b3fb1('0x25f4')][_0x1b3fb1('0x1e70')]?_0x2a1754['data'][_0x1b3fb1('0x1e70')]:JSON['stringify'](_0x2a1754[_0x1b3fb1('0x25f4')]):_0x2a1754[_0x1b3fb1('0x1586')]()});});}function _0x4c2ee2(_0x25d6cb,_0x2ca714){const _0x1ae605=_0x384fff,_0x3eeebd=_0x4c12a5[_0x1ae605('0x1d26')]()[_0x1ae605('0xcdc')](_0x1ae605('0x288d')+_0x2cfb05()[_0x1ae605('0xb35')]('zendeskAccount')+'?')[_0x1ae605('0xf3c')](''+(_0x25d6cb[_0x1ae605('0x4f0')]||_0x1ae605('0x1a8d'))+_0x1ae605('0xace')+_0x1ae605('0x3f3'))['ariaLabel'](_0x1ae605('0x213f'))[_0x1ae605('0x203b')](_0x2ca714)['ok']('OK')[_0x1ae605('0x3f')](_0x1ae605('0x2d3'));_0x4c12a5['show'](_0x3eeebd)['then'](function(){_0x74b949(_0x25d6cb);},function(){const _0x4bc064=_0x1ae605;console[_0x4bc064('0x455')]('CANCEL');});}let _0x1bedb4=!![],_0x57571a=0x1;_0x1ce11e[_0x384fff('0xe83')](_0x384fff('0x12d8'),function(_0x14e777,_0x446c7a){const _0x191429=_0x384fff;_0x1bedb4?_0x8e53b9(function(){_0x1bedb4=![];}):(!_0x446c7a&&(_0x57571a=_0x490491[_0x191429('0x2218')][_0x191429('0x1a43')]),_0x14e777!==_0x446c7a&&(_0x490491[_0x191429('0x2218')][_0x191429('0x1a43')]=0x1),!_0x14e777&&(_0x490491['query'][_0x191429('0x1a43')]=_0x57571a),_0x490491[_0x191429('0x1763')]());});function _0x5da586(_0x1f5715){const _0x214e3f=_0x384fff;_0x490491[_0x214e3f('0xf34')]=_0x1f5715||{'count':0x0,'rows':[]};}function _0x1648cd(){const _0x3dafa7=_0x384fff;_0x490491[_0x3dafa7('0x2218')]['offset']=(_0x490491[_0x3dafa7('0x2218')]['page']-0x1)*_0x490491['query']['limit'],_0x4e0f3f[_0x3dafa7('0x1ac6')](_0x3dafa7('0xa7c'))?_0x490491[_0x3dafa7('0x1f48')]=_0x2cdbb2[_0x3dafa7('0x2290')]['get'](_0x490491[_0x3dafa7('0x2218')],_0x5da586)[_0x3dafa7('0xa44')]:(_0x490491['query']['id']=_0x490491[_0x3dafa7('0x7f')]['id'],_0x490491[_0x3dafa7('0x2218')][_0x3dafa7('0xe60')]=_0x3dafa7('0xc99'),_0x490491['promise']=_0x2cdbb2[_0x3dafa7('0x7f')]['getResources'](_0x490491[_0x3dafa7('0x2218')],_0x5da586)[_0x3dafa7('0xa44')]);}function _0xd88f9d(_0x191ba6,_0x4260ca){const _0x251122=_0x384fff;_0x4c12a5[_0x251122('0x1f80')]({'controller':_0x251122('0x13e4'),'controllerAs':'vm','templateUrl':_0x1fd494,'parent':angular[_0x251122('0x1194')](_0x2920a5[_0x251122('0x8d2')]),'targetEvent':_0x191ba6,'clickOutsideToClose':!![],'locals':{'zendeskAccount':_0x4260ca,'zendeskAccounts':_0x490491[_0x251122('0xf34')][_0x251122('0x269a')],'license':_0x490491[_0x251122('0x5c9')],'setting':_0x490491[_0x251122('0xf8a')],'crudPermissions':_0x490491[_0x251122('0x243c')]}});}function _0x74b949(_0xb20e5e){const _0x4a09b2=_0x384fff;_0x2cdbb2[_0x4a09b2('0x2290')][_0x4a09b2('0x906')]({'id':_0xb20e5e['id']})[_0x4a09b2('0xa44')]['then'](function(){const _0x4f674c=_0x4a09b2;_0x2cfb05()[_0x4f674c('0x127f')](_0x490491[_0x4f674c('0xf34')][_0x4f674c('0x269a')],{'id':_0xb20e5e['id']}),_0x490491['zendeskAccounts'][_0x4f674c('0x240f')]-=0x1,!_0x490491['zendeskAccounts'][_0x4f674c('0x269a')][_0x4f674c('0x264b')]&&_0x490491[_0x4f674c('0x1763')](),_0x417f85[_0x4f674c('0x103b')]({'title':_0x2cfb05()[_0x4f674c('0xb35')](_0x4f674c('0x12df'))+'\x20deleted!','msg':_0xb20e5e[_0x4f674c('0x4f0')]?_0xb20e5e[_0x4f674c('0x4f0')]+_0x4f674c('0x7cd'):''});})[_0x4a09b2('0x1a80')](function(_0xe31b2){const _0x3e8963=_0x4a09b2;if(_0xe31b2[_0x3e8963('0x25f4')]&&_0xe31b2[_0x3e8963('0x25f4')][_0x3e8963('0x61a')]&&_0xe31b2[_0x3e8963('0x25f4')]['errors'][_0x3e8963('0x264b')]){_0x490491[_0x3e8963('0x61a')]=_0xe31b2['data'][_0x3e8963('0x61a')]||[{'message':_0xe31b2[_0x3e8963('0x1586')](),'type':'SYSTEM:DELETEintZendeskAccount'}];for(let _0x15bd11=0x0;_0x15bd11<_0xe31b2[_0x3e8963('0x25f4')][_0x3e8963('0x61a')][_0x3e8963('0x264b')];_0x15bd11++){_0x417f85['error']({'title':_0xe31b2[_0x3e8963('0x25f4')]['errors'][_0x15bd11][_0x3e8963('0x1345')],'msg':_0xe31b2['data'][_0x3e8963('0x61a')][_0x15bd11]['message']});}}else _0x417f85[_0x3e8963('0xfc9')]({'title':_0xe31b2[_0x3e8963('0x52d')]?'API:'+_0xe31b2[_0x3e8963('0x52d')]+_0x3e8963('0x11e1')+_0xe31b2['statusText']:_0x3e8963('0x1788'),'msg':_0xe31b2[_0x3e8963('0x25f4')]?JSON[_0x3e8963('0xbac')](_0xe31b2['data'][_0x3e8963('0x1e70')]):_0xe31b2[_0x3e8963('0x1e70')]||_0xe31b2[_0x3e8963('0x1586')]()});});}function _0x907799(){const _0x3979ba=_0x384fff,_0x4afea1=angular[_0x3979ba('0x225f')](_0x490491[_0x3979ba('0x24a8')]);return _0x490491['selectedZendeskAccounts']=[],_0x4afea1;}function _0x3d9b5b(_0x5af1b4){const _0x5269a4=_0x384fff,_0x62cd66=_0x4c12a5[_0x5269a4('0x1d26')]()['title'](_0x5269a4('0xd6'))['htmlContent'](_0x5269a4('0x12b5')+_0x490491[_0x5269a4('0x24a8')]['length']+_0x5269a4('0x196d')+_0x5269a4('0x3f3'))[_0x5269a4('0x8e8')](_0x5269a4('0x11b4'))['targetEvent'](_0x5af1b4)['ok']('OK')['cancel'](_0x5269a4('0x2d3'));_0x4c12a5['show'](_0x62cd66)[_0x5269a4('0x1166')](function(){const _0x4ebdde=_0x5269a4;_0x490491[_0x4ebdde('0x24a8')]['forEach'](function(_0x342826){_0x74b949(_0x342826);}),_0x490491[_0x4ebdde('0x24a8')]=[];});}function _0x58110e(){const _0x48123d=_0x384fff;_0x490491[_0x48123d('0x24a8')]=[];}function _0x15e554(){const _0x631f13=_0x384fff;_0x490491[_0x631f13('0x24a8')]=_0x490491[_0x631f13('0xf34')][_0x631f13('0x269a')];}}const _0x266617=_0xef64b4;_0x2ea8ff[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'zohoAccounts',_0x36e6f4('0x216d'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x2ea8ff(_0x19be0f,_0x271d1c,_0x5268ba,_0x336e35,_0x21f488,_0x500150,_0x3b6742,_0x5d2183,_0x5809b9,_0x42b0a7,_0x441b10,_0x3e604e,_0x309bac,_0x311e95){const _0x145578=_0x36e6f4,_0x2c2b1a=this;_0x2c2b1a[_0x145578('0x98')]=_0x441b10[_0x145578('0x26cd')](),_0x2c2b1a[_0x145578('0x61a')]=[],_0x2c2b1a['setting']=_0x309bac,_0x2c2b1a[_0x145578('0x5c9')]=_0x3e604e,_0x2c2b1a[_0x145578('0x243c')]=_0x311e95,_0x2c2b1a[_0x145578('0x128b')]={},_0x2c2b1a[_0x145578('0x2900')]=_0x2c2b1a['setting']&&_0x2c2b1a[_0x145578('0xf8a')][_0x145578('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2c2b1a[_0x145578('0xcdc')]=_0x145578('0x2038'),_0x2c2b1a[_0x145578('0x216d')]=angular['copy'](_0x5809b9),_0x2c2b1a[_0x145578('0x10ca')]=_0x5d2183,_0x2c2b1a[_0x145578('0x256')]=![];!_0x2c2b1a['zohoAccount']&&(_0x2c2b1a['zohoAccount']={'host':_0x145578('0x285b'),'zone':'EU','serverUrl':_0x5268ba[_0x145578('0x6f1')]()+_0x145578('0xc51')+_0x5268ba['host']()+(_0x5268ba['port']()?':'+_0x5268ba[_0x145578('0x93d')]():'')},_0x2c2b1a[_0x145578('0xcdc')]=_0x145578('0x205b'),_0x2c2b1a[_0x145578('0x256')]=!![]);_0x2c2b1a[_0x145578('0x15c7')]=_0x293e00,_0x2c2b1a[_0x145578('0x1bd')]=_0x7e3dc0,_0x2c2b1a[_0x145578('0x1a8f')]=_0x2e4030,_0x2c2b1a['getDateFromString']=_0x4aa424,_0x2c2b1a['closeDialog']=_0x1a8bf6;function _0x293e00(){const _0x5b77c8=_0x145578;_0x2c2b1a[_0x5b77c8('0x61a')]=[],_0x42b0a7[_0x5b77c8('0x11d1')][_0x5b77c8('0x9cc')](_0x2c2b1a[_0x5b77c8('0x216d')])['$promise'][_0x5b77c8('0x1166')](function(_0x38df09){const _0x1c0935=_0x5b77c8;_0x2c2b1a[_0x1c0935('0x10ca')][_0x1c0935('0x2450')](_0x38df09[_0x1c0935('0x2876')]()),_0x3b6742[_0x1c0935('0x103b')]({'title':_0x1c0935('0x1de6'),'msg':_0x2c2b1a[_0x1c0935('0x216d')][_0x1c0935('0x4f0')]?_0x2c2b1a[_0x1c0935('0x216d')]['name']+_0x1c0935('0x1eda'):''}),_0x1a8bf6(_0x38df09);})[_0x5b77c8('0x1a80')](function(_0x1fa52a){const _0x4f17e=_0x5b77c8;if(_0x1fa52a[_0x4f17e('0x25f4')]&&_0x1fa52a[_0x4f17e('0x25f4')][_0x4f17e('0x61a')]&&_0x1fa52a[_0x4f17e('0x25f4')][_0x4f17e('0x61a')][_0x4f17e('0x264b')]){_0x2c2b1a[_0x4f17e('0x61a')]=_0x1fa52a['data'][_0x4f17e('0x61a')]||[{'message':_0x1fa52a[_0x4f17e('0x1586')](),'type':_0x4f17e('0x122c')}];for(let _0x397968=0x0;_0x397968<_0x1fa52a[_0x4f17e('0x25f4')]['errors'][_0x4f17e('0x264b')];_0x397968+=0x1){_0x3b6742[_0x4f17e('0xfc9')]({'title':_0x1fa52a['data'][_0x4f17e('0x61a')][_0x397968][_0x4f17e('0x1345')],'msg':_0x1fa52a[_0x4f17e('0x25f4')]['errors'][_0x397968][_0x4f17e('0x1e70')]});}}else _0x3b6742[_0x4f17e('0xfc9')]({'title':_0x1fa52a[_0x4f17e('0x52d')]?_0x4f17e('0x1e21')+_0x1fa52a[_0x4f17e('0x52d')]+_0x4f17e('0x11e1')+_0x1fa52a[_0x4f17e('0xe1b')]:_0x4f17e('0x122c'),'msg':_0x1fa52a[_0x4f17e('0x25f4')]?JSON[_0x4f17e('0xbac')](_0x1fa52a[_0x4f17e('0x25f4')][_0x4f17e('0x1e70')]):_0x1fa52a[_0x4f17e('0x1586')]()});});}function _0x7e3dc0(){const _0x46b150=_0x145578;_0x2c2b1a[_0x46b150('0x61a')]=[],_0x42b0a7['intZohoAccount']['update']({'id':_0x2c2b1a[_0x46b150('0x216d')]['id']},_0x2c2b1a['zohoAccount'])[_0x46b150('0xa44')]['then'](function(_0x258de6){const _0x3ef1b6=_0x46b150,_0x5310b8=_0x2cfb05()[_0x3ef1b6('0xc38')](_0x2c2b1a[_0x3ef1b6('0x10ca')],{'id':_0x258de6['id']});_0x5310b8&&_0x2cfb05()[_0x3ef1b6('0xcc3')](_0x5310b8,_0x2cfb05()['pick'](_0x258de6[_0x3ef1b6('0x2876')](),_0x2cfb05()['keys'](_0x5310b8))),_0x3b6742[_0x3ef1b6('0x103b')]({'title':_0x3ef1b6('0x28ee'),'msg':_0x2c2b1a['zohoAccount'][_0x3ef1b6('0x4f0')]?_0x2c2b1a['zohoAccount']['name']+'\x20has\x20been\x20saved!':''}),_0x1a8bf6(_0x258de6);})[_0x46b150('0x1a80')](function(_0x5da4b6){const _0x5a3a3e=_0x46b150;if(_0x5da4b6[_0x5a3a3e('0x25f4')]&&_0x5da4b6['data']['errors']&&_0x5da4b6['data'][_0x5a3a3e('0x61a')][_0x5a3a3e('0x264b')]){_0x2c2b1a[_0x5a3a3e('0x61a')]=_0x5da4b6[_0x5a3a3e('0x25f4')][_0x5a3a3e('0x61a')]||[{'message':_0x5da4b6['toString'](),'type':_0x5a3a3e('0x741')}];for(let _0x1a5731=0x0;_0x1a5731<_0x5da4b6[_0x5a3a3e('0x25f4')][_0x5a3a3e('0x61a')][_0x5a3a3e('0x264b')];_0x1a5731++){_0x3b6742['error']({'title':_0x5da4b6['data']['errors'][_0x1a5731][_0x5a3a3e('0x1345')],'msg':_0x5da4b6['data'][_0x5a3a3e('0x61a')][_0x1a5731][_0x5a3a3e('0x1e70')]});}}else _0x3b6742[_0x5a3a3e('0xfc9')]({'title':_0x5da4b6[_0x5a3a3e('0x52d')]?'API:'+_0x5da4b6[_0x5a3a3e('0x52d')]+_0x5a3a3e('0x11e1')+_0x5da4b6['statusText']:_0x5a3a3e('0x741'),'msg':_0x5da4b6[_0x5a3a3e('0x25f4')]?JSON[_0x5a3a3e('0xbac')](_0x5da4b6[_0x5a3a3e('0x25f4')][_0x5a3a3e('0x1e70')]):_0x5da4b6[_0x5a3a3e('0x1586')]()});});}function _0x2e4030(_0x2ddff5){const _0x3f371f=_0x145578;_0x2c2b1a[_0x3f371f('0x61a')]=[];const _0x2150fb=_0x336e35[_0x3f371f('0x1d26')]()['title']('Are\x20you\x20sure?')['content'](_0x3f371f('0x1998'))[_0x3f371f('0x8e8')](_0x3f371f('0x15d1'))['ok'](_0x3f371f('0x18'))[_0x3f371f('0x3f')]('Cancel')[_0x3f371f('0x203b')](_0x2ddff5);_0x336e35[_0x3f371f('0x1f80')](_0x2150fb)[_0x3f371f('0x1166')](function(){const _0x2080b9=_0x3f371f;_0x42b0a7[_0x2080b9('0x11d1')][_0x2080b9('0x906')]({'id':_0x2c2b1a[_0x2080b9('0x216d')]['id']})[_0x2080b9('0xa44')][_0x2080b9('0x1166')](function(){const _0x76eda7=_0x2080b9;_0x2cfb05()['remove'](_0x2c2b1a['zohoAccounts'],{'id':_0x2c2b1a[_0x76eda7('0x216d')]['id']}),_0x3b6742[_0x76eda7('0x103b')]({'title':_0x76eda7('0xd61'),'msg':(_0x2c2b1a[_0x76eda7('0x216d')]['name']||_0x76eda7('0x216d'))+'\x20has\x20been\x20deleted!'}),_0x1a8bf6(_0x2c2b1a[_0x76eda7('0x216d')]);})[_0x2080b9('0x1a80')](function(_0x1ecb70){const _0x5c1646=_0x2080b9;if(_0x1ecb70['data']&&_0x1ecb70['data'][_0x5c1646('0x61a')]&&_0x1ecb70[_0x5c1646('0x25f4')][_0x5c1646('0x61a')][_0x5c1646('0x264b')]){_0x2c2b1a['errors']=_0x1ecb70['data'][_0x5c1646('0x61a')]||[{'message':_0x1ecb70[_0x5c1646('0x1586')](),'type':_0x5c1646('0x1832')}];for(let _0x12c48d=0x0;_0x12c48d<_0x1ecb70[_0x5c1646('0x25f4')][_0x5c1646('0x61a')][_0x5c1646('0x264b')];_0x12c48d++){_0x3b6742[_0x5c1646('0xfc9')]({'title':_0x1ecb70['data'][_0x5c1646('0x61a')][_0x12c48d][_0x5c1646('0x1345')],'msg':_0x1ecb70[_0x5c1646('0x25f4')][_0x5c1646('0x61a')][_0x12c48d]['message']});}}else _0x3b6742['error']({'title':_0x1ecb70[_0x5c1646('0x52d')]?_0x5c1646('0x1e21')+_0x1ecb70[_0x5c1646('0x52d')]+_0x5c1646('0x11e1')+_0x1ecb70['statusText']:_0x5c1646('0x1832'),'msg':_0x1ecb70[_0x5c1646('0x25f4')]?JSON[_0x5c1646('0xbac')](_0x1ecb70[_0x5c1646('0x25f4')][_0x5c1646('0x1e70')]):_0x1ecb70[_0x5c1646('0x1e70')]||_0x1ecb70[_0x5c1646('0x1586')]()});});},function(){});}function _0x4aa424(_0x3c3c30){return _0x3c3c30===null?undefined:new Date(_0x3c3c30);}function _0x1a8bf6(_0x5e2fd1){const _0x477582=_0x145578;_0x336e35[_0x477582('0x1197')](_0x5e2fd1);}}const _0xa38844=_0x2ea8ff,_0x5dc259=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/zohoAccounts/edit/configurations/dialog.html/dialog.html',_0x4207d2=_0x2734b2['p']+_0x36e6f4('0x1a9a');_0x5c865a['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x5c865a(_0x55127d,_0x3bca04,_0x13b29a,_0xf9c553,_0x34c867){const _0x529412=_0x36e6f4,_0x3d194d=this;_0x3d194d[_0x529412('0x98')]=_0x34c867[_0x529412('0x26cd')](),_0x3d194d[_0x529412('0x216d')]={},_0x3d194d['zohoConfiguration']={},_0x3d194d[_0x529412('0xd54')]=[],_0x3d194d['selectedZohoConfiguration']=-0x1,_0x3d194d[_0x529412('0x243c')],_0x3d194d[_0x529412('0x24d5')]=_0x2f65cd,_0x3d194d['getZohoConfiguration']=_0x5e3043,_0x3d194d[_0x529412('0x1209')]=_0x4cd700,_0x3d194d['deleteZohoConfiguration']=_0x1c80a9,_0x3d194d[_0x529412('0x10c2')]=_0x484a7f;function _0x484a7f(){const _0x694714=_0x529412;return _0x13b29a[_0x694714('0x57c')][_0x694714('0x1449')]({'id':_0x3d194d['zohoConfiguration']['id']},_0x3d194d[_0x694714('0x1fa0')])[_0x694714('0xa44')][_0x694714('0x1166')](function(){const _0x148672=_0x694714;_0xf9c553[_0x148672('0x103b')]({'title':_0x148672('0x196b'),'msg':_0x148672('0x1b82')});})[_0x694714('0x1a80')](function(_0x3a0d0d){const _0xf39e25=_0x694714;_0xf9c553['error']({'title':_0x3a0d0d[_0xf39e25('0x52d')]?_0xf39e25('0x1e21')+_0x3a0d0d[_0xf39e25('0x52d')]+'\x20-\x20'+_0x3a0d0d[_0xf39e25('0xe1b')]:_0xf39e25('0x6fc'),'msg':_0x3a0d0d[_0xf39e25('0x25f4')]?JSON[_0xf39e25('0xbac')](_0x3a0d0d[_0xf39e25('0x25f4')]):_0x3a0d0d[_0xf39e25('0x1586')]()});});}function _0x2f65cd(_0x4a0916,_0x1e9eeb){const _0x4ec8ea=_0x529412;_0x3d194d[_0x4ec8ea('0x216d')]=_0x4a0916,_0x3d194d[_0x4ec8ea('0x243c')]=typeof _0x1e9eeb!==_0x4ec8ea('0x1048')?_0x1e9eeb:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x13b29a['intZohoAccount'][_0x4ec8ea('0x13db')]({'id':_0x3d194d[_0x4ec8ea('0x216d')]['id'],'sort':'-updatedAt'})['$promise'][_0x4ec8ea('0x1166')](function(_0x213e49){const _0x2e7e9c=_0x4ec8ea;return _0x3d194d['configurations']=_0x213e49['rows']?_0x213e49[_0x2e7e9c('0x269a')]:[],_0x3d194d[_0x2e7e9c('0xd54')][_0x2e7e9c('0x264b')]&&_0x3d194d[_0x2e7e9c('0x2376')](0x0),_0x13b29a['variable'][_0x2e7e9c('0xd83')]({'nolimit':!![],'sort':_0x2e7e9c('0x4f0')})['$promise'];})[_0x4ec8ea('0x1166')](function(_0x5e1709){const _0x241ae4=_0x4ec8ea;_0x3d194d[_0x241ae4('0x57a')]=_0x5e1709[_0x241ae4('0x269a')]?_0x5e1709['rows']:[],_0x3d194d['variablesById']=_0x2cfb05()[_0x241ae4('0x155c')](_0x3d194d[_0x241ae4('0x57a')],'id');})[_0x4ec8ea('0x1a80')](function(_0xdcdd03){const _0x4bbd68=_0x4ec8ea;_0xf9c553[_0x4bbd68('0xfc9')]({'title':_0xdcdd03[_0x4bbd68('0x52d')]?_0x4bbd68('0x1e21')+_0xdcdd03[_0x4bbd68('0x52d')]+_0x4bbd68('0x11e1')+_0xdcdd03[_0x4bbd68('0xe1b')]:'SYSTEM:GETCONFIGURATION','msg':_0xdcdd03['data']?JSON[_0x4bbd68('0xbac')](_0xdcdd03[_0x4bbd68('0x25f4')]):_0xdcdd03[_0x4bbd68('0x1586')]()});});}function _0x5e3043(_0x9b648){const _0xf0e244=_0x529412;_0x3d194d[_0xf0e244('0x1fa0')]=_0x3d194d['configurations'][_0x9b648],_0x3d194d[_0xf0e244('0x1471')]=_0x9b648,_0x13b29a[_0xf0e244('0x57c')]['getSubjects']({'id':_0x3d194d[_0xf0e244('0x1fa0')]['id']})[_0xf0e244('0xa44')]['then'](function(_0x2573ae){const _0x4e8b42=_0xf0e244;return _0x3d194d[_0x4e8b42('0x2701')]=_0x2573ae['rows']?_0x2573ae[_0x4e8b42('0x269a')]:[],_0x13b29a[_0x4e8b42('0x57c')][_0x4e8b42('0x28d4')]({'id':_0x3d194d[_0x4e8b42('0x1fa0')]['id']})[_0x4e8b42('0xa44')];})[_0xf0e244('0x1166')](function(_0x51d9ad){const _0x1cb9c8=_0xf0e244;return _0x3d194d[_0x1cb9c8('0x1b3d')]=_0x51d9ad[_0x1cb9c8('0x269a')]?_0x51d9ad['rows']:[],_0x13b29a[_0x1cb9c8('0x57c')][_0x1cb9c8('0x18ea')]({'id':_0x3d194d['zohoConfiguration']['id']})[_0x1cb9c8('0xa44')];})['then'](function(_0x314f3b){const _0x2e8b4f=_0xf0e244;_0x3d194d[_0x2e8b4f('0xfe2')]=_0x314f3b[_0x2e8b4f('0x269a')]?_0x314f3b['rows']:[];})['catch'](function(_0x2a6b2c){const _0x47cd2f=_0xf0e244;_0xf9c553[_0x47cd2f('0xfc9')]({'title':_0x2a6b2c[_0x47cd2f('0x52d')]?_0x47cd2f('0x1e21')+_0x2a6b2c['status']+_0x47cd2f('0x11e1')+_0x2a6b2c[_0x47cd2f('0xe1b')]:_0x47cd2f('0x16c7'),'msg':_0x2a6b2c['data']?JSON[_0x47cd2f('0xbac')](_0x2a6b2c[_0x47cd2f('0x25f4')]):_0x2a6b2c['toString']()});});}function _0x4cd700(_0x381e35,_0x5d5670){const _0x53fd98=_0x529412;_0x55127d[_0x53fd98('0x1f80')]({'controller':'CreateOrEditZohoConfigurationDialogController','controllerAs':'vm','templateUrl':_0x5dc259,'parent':angular[_0x53fd98('0x1194')](_0x3bca04[_0x53fd98('0x8d2')]),'targetEvent':_0x381e35,'clickOutsideToClose':!![],'locals':{'zohoConfiguration':_0x5d5670,'configurations':_0x3d194d['configurations'],'license':null,'setting':null,'crudPermissions':_0x3d194d[_0x53fd98('0x243c')]}})[_0x53fd98('0x1951')](function(){const _0x46b11c=_0x53fd98;_0x3d194d[_0x46b11c('0x2376')](0x0);});}function _0x1c80a9(_0x3bdd47,_0x219691){const _0x15b73a=_0x529412,_0x216404=_0x55127d[_0x15b73a('0x1d26')]()[_0x15b73a('0xcdc')](_0x15b73a('0x653'))['htmlContent'](_0x15b73a('0x12b5')+(_0x219691[_0x15b73a('0x4f0')]||_0x15b73a('0x1fa0'))+_0x15b73a('0xace')+_0x15b73a('0x3f3'))['ariaLabel'](_0x15b73a('0x14b4'))[_0x15b73a('0x203b')](_0x3bdd47)['ok']('OK')[_0x15b73a('0x3f')]('CANCEL');_0x55127d['show'](_0x216404)[_0x15b73a('0x1166')](function(){const _0x16ab36=_0x15b73a;_0x13b29a[_0x16ab36('0x57c')][_0x16ab36('0x906')]({'id':_0x219691['id']})[_0x16ab36('0xa44')][_0x16ab36('0x1166')](function(){const _0xa9642a=_0x16ab36;_0x2cfb05()[_0xa9642a('0x127f')](_0x3d194d[_0xa9642a('0xd54')],{'id':_0x219691['id']}),_0xf9c553[_0xa9642a('0x103b')]({'title':'ZohoConfiguration\x20deleted!','msg':_0x219691[_0xa9642a('0x4f0')]?_0x219691[_0xa9642a('0x4f0')]+_0xa9642a('0x7cd'):''});})[_0x16ab36('0x1a80')](function(_0x46a615){const _0x36a348=_0x16ab36;_0xf9c553['error']({'title':_0x46a615['status']?_0x36a348('0x1e21')+_0x46a615[_0x36a348('0x52d')]+_0x36a348('0x11e1')+_0x46a615[_0x36a348('0xe1b')]:_0x36a348('0x19a8'),'msg':_0x46a615[_0x36a348('0x25f4')]?JSON['stringify'](_0x46a615[_0x36a348('0x25f4')]):_0x46a615[_0x36a348('0x1586')]()});})['finally'](function(){const _0x43ae3e=_0x16ab36;_0x3d194d[_0x43ae3e('0x2376')](0x0);});},function(){const _0x49032d=_0x15b73a;console[_0x49032d('0x455')](_0x49032d('0x2d3'));});}_0x3d194d[_0x529412('0xd02')]=[],_0x3d194d[_0x529412('0x1a33')]=_0x28d6c4,_0x3d194d[_0x529412('0x2059')]=_0x32bf22,_0x3d194d['deleteSelectedSubjects']=_0x21320e;function _0x28d6c4(_0x64133b,_0x17b105){const _0x3d3445=_0x529412;_0x55127d[_0x3d3445('0x1f80')]({'controller':'CreateOrEditZohoAccountItemDialogController','controllerAs':'vm','templateUrl':_0x4207d2,'parent':angular[_0x3d3445('0x1194')](_0x3bca04[_0x3d3445('0x8d2')]),'targetEvent':_0x64133b,'clickOutsideToClose':!![],'locals':{'type':_0x3d3445('0x210d'),'item':_0x17b105,'items':_0x3d194d[_0x3d3445('0x2701')],'configuration':_0x3d194d[_0x3d3445('0x1fa0')],'account':_0x3d194d[_0x3d3445('0x216d')],'license':null,'setting':null,'crudPermissions':_0x3d194d['crudPermissions']}});}function _0x77787d(_0x5e41c5){const _0x23529c=_0x529412;_0x13b29a[_0x23529c('0xf62')][_0x23529c('0x906')]({'id':_0x5e41c5['id']})['$promise']['then'](function(){const _0x3a3d4a=_0x23529c;_0x2cfb05()[_0x3a3d4a('0x127f')](_0x3d194d[_0x3a3d4a('0x2701')],{'id':_0x5e41c5['id']}),_0xf9c553[_0x3a3d4a('0x103b')]({'title':'Subject\x20deleted!','msg':_0x3a3d4a('0x259f')});})[_0x23529c('0x1a80')](function(_0x528391){const _0x27753d=_0x23529c;_0xf9c553[_0x27753d('0xfc9')]({'title':_0x528391[_0x27753d('0x52d')]?_0x27753d('0x1e21')+_0x528391[_0x27753d('0x52d')]+_0x27753d('0x11e1')+_0x528391[_0x27753d('0xe1b')]:_0x27753d('0x23ff'),'msg':_0x528391['data']?JSON[_0x27753d('0xbac')](_0x528391[_0x27753d('0x25f4')]):_0x528391[_0x27753d('0x1586')]()});});}function _0x32bf22(_0x31cebe,_0x1f3045){const _0x2dc686=_0x529412,_0x264995=_0x55127d['confirm']()[_0x2dc686('0xcdc')](_0x2dc686('0x11c8'))[_0x2dc686('0xf3c')]('Subject'+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x2dc686('0x87a'))['targetEvent'](_0x31cebe)['ok']('OK')[_0x2dc686('0x3f')](_0x2dc686('0x2d3'));_0x55127d[_0x2dc686('0x1f80')](_0x264995)['then'](function(){_0x77787d(_0x1f3045);},function(){const _0x300ef5=_0x2dc686;console[_0x300ef5('0x455')](_0x300ef5('0x2d3'));});}function _0x21320e(_0x432d8c){const _0x34c9b1=_0x529412,_0x2e636e=_0x55127d[_0x34c9b1('0x1d26')]()[_0x34c9b1('0xcdc')](_0x34c9b1('0x1d64'))[_0x34c9b1('0xf3c')](_0x34c9b1('0x12b5')+_0x3d194d[_0x34c9b1('0xd02')]['length']+_0x34c9b1('0x196d')+_0x34c9b1('0x3f3'))[_0x34c9b1('0x8e8')](_0x34c9b1('0x5b2'))[_0x34c9b1('0x203b')](_0x432d8c)['ok']('OK')[_0x34c9b1('0x3f')]('CANCEL');_0x55127d[_0x34c9b1('0x1f80')](_0x2e636e)['then'](function(){const _0x5bd330=_0x34c9b1;_0x3d194d['selectedSubjects'][_0x5bd330('0x2782')](function(_0x535ce9){_0x77787d(_0x535ce9);}),_0x3d194d['selectedSubjects']=[];});}_0x3d194d[_0x529412('0x968')]=[],_0x3d194d[_0x529412('0x2185')]=_0x435de2,_0x3d194d['deleteDescriptionConfirm']=_0x37a050,_0x3d194d[_0x529412('0x2269')]=_0x10add8;function _0x435de2(_0xd5c22,_0x1b81ae){const _0x322a4e=_0x529412;_0x55127d[_0x322a4e('0x1f80')]({'controller':'CreateOrEditZohoAccountItemDialogController','controllerAs':'vm','templateUrl':_0x4207d2,'parent':angular[_0x322a4e('0x1194')](_0x3bca04[_0x322a4e('0x8d2')]),'targetEvent':_0xd5c22,'clickOutsideToClose':!![],'locals':{'type':_0x322a4e('0x101c'),'item':_0x1b81ae,'items':_0x3d194d[_0x322a4e('0x1b3d')],'configuration':_0x3d194d[_0x322a4e('0x1fa0')],'account':_0x3d194d['zohoAccount'],'license':null,'setting':null,'crudPermissions':_0x3d194d[_0x322a4e('0x243c')]}});}function _0xb7cce6(_0x2652eb){const _0xbea69d=_0x529412;_0x13b29a[_0xbea69d('0xf62')][_0xbea69d('0x906')]({'id':_0x2652eb['id']})['$promise']['then'](function(){const _0x4fa996=_0xbea69d;_0x2cfb05()['remove'](_0x3d194d[_0x4fa996('0x1b3d')],{'id':_0x2652eb['id']}),_0xf9c553['success']({'title':_0x4fa996('0x9c1'),'msg':_0x4fa996('0x12ae')});})[_0xbea69d('0x1a80')](function(_0x7a159f){const _0x3c7c80=_0xbea69d;_0xf9c553['error']({'title':_0x7a159f[_0x3c7c80('0x52d')]?_0x3c7c80('0x1e21')+_0x7a159f[_0x3c7c80('0x52d')]+_0x3c7c80('0x11e1')+_0x7a159f['statusText']:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x7a159f[_0x3c7c80('0x25f4')]?JSON[_0x3c7c80('0xbac')](_0x7a159f['data']):_0x7a159f['toString']()});});}function _0x37a050(_0x5803f0,_0x3ac8ba){const _0x3cada5=_0x529412,_0x3de6d9=_0x55127d[_0x3cada5('0x1d26')]()[_0x3cada5('0xcdc')](_0x3cada5('0x1baa'))[_0x3cada5('0xf3c')](_0x3cada5('0x1809')+_0x3cada5('0x3f3'))[_0x3cada5('0x8e8')](_0x3cada5('0x1bc0'))['targetEvent'](_0x5803f0)['ok']('OK')[_0x3cada5('0x3f')](_0x3cada5('0x2d3'));_0x55127d[_0x3cada5('0x1f80')](_0x3de6d9)[_0x3cada5('0x1166')](function(){_0xb7cce6(_0x3ac8ba);},function(){const _0x23b0c8=_0x3cada5;console['log'](_0x23b0c8('0x2d3'));});}function _0x10add8(_0xe6cc28){const _0x4f7607=_0x529412,_0x91fae8=_0x55127d[_0x4f7607('0x1d26')]()[_0x4f7607('0xcdc')](_0x4f7607('0x29'))['htmlContent'](_0x4f7607('0x12b5')+_0x3d194d['selectedDescriptions'][_0x4f7607('0x264b')]+_0x4f7607('0x196d')+_0x4f7607('0x3f3'))[_0x4f7607('0x8e8')](_0x4f7607('0x17a'))['targetEvent'](_0xe6cc28)['ok']('OK')[_0x4f7607('0x3f')](_0x4f7607('0x2d3'));_0x55127d[_0x4f7607('0x1f80')](_0x91fae8)[_0x4f7607('0x1166')](function(){const _0x32b5c4=_0x4f7607;_0x3d194d[_0x32b5c4('0x968')][_0x32b5c4('0x2782')](function(_0x576842){_0xb7cce6(_0x576842);}),_0x3d194d['selectedDescriptions']=[];});}_0x3d194d[_0x529412('0x16')]=[],_0x3d194d[_0x529412('0x27ad')]=_0x47b248,_0x3d194d[_0x529412('0xbda')]=_0x289143,_0x3d194d['deleteSelectedFields']=_0x2877e1;function _0x47b248(_0x14ef78,_0x31385f){const _0x178ef9=_0x529412;_0x55127d[_0x178ef9('0x1f80')]({'controller':'CreateOrEditZohoAccountItemDialogController','controllerAs':'vm','templateUrl':_0x4207d2,'parent':angular[_0x178ef9('0x1194')](_0x3bca04[_0x178ef9('0x8d2')]),'targetEvent':_0x14ef78,'clickOutsideToClose':!![],'locals':{'type':_0x178ef9('0x22f3'),'item':_0x31385f,'items':_0x3d194d[_0x178ef9('0xfe2')],'configuration':_0x3d194d['zohoConfiguration'],'account':_0x3d194d['zohoAccount'],'license':null,'setting':null,'crudPermissions':_0x3d194d['crudPermissions']}});}function _0x1cb85d(_0x1eeab6){const _0x20b547=_0x529412;_0x13b29a['intZohoField']['delete']({'id':_0x1eeab6['id']})['$promise'][_0x20b547('0x1166')](function(){const _0x1eb94b=_0x20b547;_0x2cfb05()[_0x1eb94b('0x127f')](_0x3d194d['fields'],{'id':_0x1eeab6['id']}),_0xf9c553['success']({'title':_0x1eb94b('0x13cb'),'msg':_0x1eb94b('0x31e')});})['catch'](function(_0x2d54c6){const _0x5ebbf6=_0x20b547;_0xf9c553[_0x5ebbf6('0xfc9')]({'title':_0x2d54c6['status']?_0x5ebbf6('0x1e21')+_0x2d54c6[_0x5ebbf6('0x52d')]+_0x5ebbf6('0x11e1')+_0x2d54c6[_0x5ebbf6('0xe1b')]:_0x5ebbf6('0x23ff'),'msg':_0x2d54c6[_0x5ebbf6('0x25f4')]?JSON[_0x5ebbf6('0xbac')](_0x2d54c6[_0x5ebbf6('0x25f4')]):_0x2d54c6[_0x5ebbf6('0x1586')]()});});}function _0x289143(_0x22e5ac,_0x5dcce2){const _0x27d85a=_0x529412,_0x37fc1c=_0x55127d[_0x27d85a('0x1d26')]()[_0x27d85a('0xcdc')](_0x27d85a('0xa61'))['htmlContent'](_0x27d85a('0x13e0')+_0x27d85a('0x3f3'))[_0x27d85a('0x8e8')](_0x27d85a('0x2127'))['targetEvent'](_0x22e5ac)['ok']('OK')['cancel'](_0x27d85a('0x2d3'));_0x55127d[_0x27d85a('0x1f80')](_0x37fc1c)[_0x27d85a('0x1166')](function(){_0x1cb85d(_0x5dcce2);},function(){const _0x5e9ee4=_0x27d85a;console[_0x5e9ee4('0x455')](_0x5e9ee4('0x2d3'));});}function _0x2877e1(_0x42d39e){const _0x40453a=_0x529412,_0x3fa017=_0x55127d[_0x40453a('0x1d26')]()[_0x40453a('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20fields?')[_0x40453a('0xf3c')](_0x40453a('0x12b5')+_0x3d194d[_0x40453a('0x16')][_0x40453a('0x264b')]+_0x40453a('0x196d')+_0x40453a('0x3f3'))[_0x40453a('0x8e8')](_0x40453a('0x219a'))[_0x40453a('0x203b')](_0x42d39e)['ok']('OK')[_0x40453a('0x3f')]('CANCEL');_0x55127d[_0x40453a('0x1f80')](_0x3fa017)[_0x40453a('0x1166')](function(){const _0x16482b=_0x40453a;_0x3d194d[_0x16482b('0x16')][_0x16482b('0x2782')](function(_0x54ffd){_0x1cb85d(_0x54ffd);}),_0x3d194d[_0x16482b('0x16')]=[];});}}const _0xae9aed=_0x5c865a;_0x3f5bd9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0xd54'),_0x36e6f4('0x1fa0'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x3f5bd9(_0x254a90,_0x382188,_0x3b02ac,_0xce5dd2,_0x2644c4,_0x2d2526,_0xd4570b,_0x445905,_0x46456a,_0x2333d2,_0xace544,_0x3650a3,_0x4b1694,_0x3af905){const _0x6fa966=_0x36e6f4,_0x3b4628=this;_0x3b4628[_0x6fa966('0x98')]=_0xace544[_0x6fa966('0x26cd')](),_0x3b4628['errors']=[],_0x3b4628[_0x6fa966('0xf8a')]=_0x4b1694,_0x3b4628[_0x6fa966('0x5c9')]=_0x3650a3,_0x3b4628[_0x6fa966('0x243c')]=_0x3af905,_0x3b4628['hasModulePermissions']={},_0x3b4628[_0x6fa966('0x2900')]=_0x3b4628[_0x6fa966('0xf8a')]&&_0x3b4628[_0x6fa966('0xf8a')][_0x6fa966('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3b4628['title']=_0x6fa966('0x11e4'),_0x3b4628['zohoConfiguration']=angular[_0x6fa966('0x225f')](_0x46456a),_0x3b4628[_0x6fa966('0xd54')]=_0x445905,_0x3b4628[_0x6fa966('0x118e')]=![];!_0x3b4628[_0x6fa966('0x1fa0')]&&(_0x3b4628['zohoConfiguration']={'channel':_0x6fa966('0x21da'),'type':_0x6fa966('0x14d8')},_0x3b4628[_0x6fa966('0xcdc')]=_0x6fa966('0x1433'),_0x3b4628[_0x6fa966('0x118e')]=!![]);_0x3b4628['addNewZohoConfiguration']=_0x2d2d97,_0x3b4628[_0x6fa966('0x6d1')]=_0x570197,_0x3b4628['deleteZohoConfiguration']=_0xa66ad,_0x3b4628[_0x6fa966('0x1a9c')]=_0x121510,_0x3b4628['closeDialog']=_0x1c3a32;function _0x2d2d97(){const _0x2be721=_0x6fa966;_0x3b4628[_0x2be721('0x61a')]=[],_0x2333d2[_0x2be721('0x11d1')]['addConfiguration']({'id':_0x382188[_0x2be721('0x23f')]['id']},_0x3b4628[_0x2be721('0x1fa0')])[_0x2be721('0xa44')]['then'](function(_0x203f98){const _0x775113=_0x2be721;_0x3b4628[_0x775113('0xd54')][_0x775113('0x2450')](_0x203f98[_0x775113('0x2876')]()),_0xd4570b['success']({'title':_0x775113('0x12a5'),'msg':_0x3b4628['zohoConfiguration'][_0x775113('0x4f0')]?_0x3b4628['zohoConfiguration'][_0x775113('0x4f0')]+_0x775113('0x1eda'):''}),_0x1c3a32(_0x203f98);})[_0x2be721('0x1a80')](function(_0x29a15d){const _0x52271e=_0x2be721;if(_0x29a15d[_0x52271e('0x25f4')]&&_0x29a15d[_0x52271e('0x25f4')][_0x52271e('0x61a')]&&_0x29a15d[_0x52271e('0x25f4')]['errors'][_0x52271e('0x264b')]){_0x3b4628[_0x52271e('0x61a')]=_0x29a15d[_0x52271e('0x25f4')][_0x52271e('0x61a')]||[{'message':_0x29a15d[_0x52271e('0x1586')](),'type':_0x52271e('0x1653')}];for(let _0x3c99cd=0x0;_0x3c99cd<_0x29a15d[_0x52271e('0x25f4')][_0x52271e('0x61a')][_0x52271e('0x264b')];_0x3c99cd+=0x1){_0xd4570b[_0x52271e('0xfc9')]({'title':_0x29a15d[_0x52271e('0x25f4')][_0x52271e('0x61a')][_0x3c99cd]['type'],'msg':_0x29a15d[_0x52271e('0x25f4')]['errors'][_0x3c99cd][_0x52271e('0x1e70')]});}}else _0xd4570b[_0x52271e('0xfc9')]({'title':_0x29a15d[_0x52271e('0x52d')]?_0x52271e('0x1e21')+_0x29a15d['status']+_0x52271e('0x11e1')+_0x29a15d['statusText']:'api.intZohoConfiguration.save','msg':_0x29a15d[_0x52271e('0x25f4')]?JSON[_0x52271e('0xbac')](_0x29a15d[_0x52271e('0x25f4')]['message']):_0x29a15d[_0x52271e('0x1586')]()});});}function _0x570197(){const _0x569beb=_0x6fa966;_0x3b4628['errors']=[],_0x2333d2['intZohoConfiguration'][_0x569beb('0x1449')]({'id':_0x3b4628[_0x569beb('0x1fa0')]['id']},_0x3b4628['zohoConfiguration'])[_0x569beb('0xa44')][_0x569beb('0x1166')](function(_0x306259){const _0x1e482f=_0x569beb,_0x44a67e=_0x2cfb05()[_0x1e482f('0xc38')](_0x3b4628[_0x1e482f('0xd54')],{'id':_0x306259['id']});_0x44a67e&&_0x2cfb05()[_0x1e482f('0xcc3')](_0x44a67e,_0x2cfb05()['pick'](_0x306259[_0x1e482f('0x2876')](),_0x2cfb05()['keys'](_0x44a67e))),_0xd4570b['success']({'title':_0x1e482f('0x6a0'),'msg':_0x3b4628['zohoConfiguration'][_0x1e482f('0x4f0')]?_0x3b4628[_0x1e482f('0x1fa0')][_0x1e482f('0x4f0')]+_0x1e482f('0x7d'):''}),_0x1c3a32(_0x306259);})[_0x569beb('0x1a80')](function(_0x46c2f7){const _0x351b48=_0x569beb;if(_0x46c2f7[_0x351b48('0x25f4')]&&_0x46c2f7[_0x351b48('0x25f4')][_0x351b48('0x61a')]&&_0x46c2f7[_0x351b48('0x25f4')][_0x351b48('0x61a')][_0x351b48('0x264b')]){_0x3b4628[_0x351b48('0x61a')]=_0x46c2f7['data'][_0x351b48('0x61a')]||[{'message':_0x46c2f7[_0x351b48('0x1586')](),'type':_0x351b48('0x17a8')}];for(let _0x1f7028=0x0;_0x1f7028<_0x46c2f7['data'][_0x351b48('0x61a')][_0x351b48('0x264b')];_0x1f7028++){_0xd4570b[_0x351b48('0xfc9')]({'title':_0x46c2f7[_0x351b48('0x25f4')][_0x351b48('0x61a')][_0x1f7028][_0x351b48('0x1345')],'msg':_0x46c2f7[_0x351b48('0x25f4')][_0x351b48('0x61a')][_0x1f7028]['message']});}}else _0xd4570b[_0x351b48('0xfc9')]({'title':_0x46c2f7[_0x351b48('0x52d')]?'API:'+_0x46c2f7[_0x351b48('0x52d')]+'\x20-\x20'+_0x46c2f7[_0x351b48('0xe1b')]:_0x351b48('0x17a8'),'msg':_0x46c2f7[_0x351b48('0x25f4')]?JSON[_0x351b48('0xbac')](_0x46c2f7[_0x351b48('0x25f4')]['message']):_0x46c2f7['toString']()});});}function _0xa66ad(_0x5139e0){const _0x48bf9f=_0x6fa966;_0x3b4628[_0x48bf9f('0x61a')]=[];const _0xc43514=_0xce5dd2['confirm']()[_0x48bf9f('0xcdc')]('Are\x20you\x20sure?')[_0x48bf9f('0xacc')]('The\x20zohoConfiguration\x20will\x20be\x20deleted.')[_0x48bf9f('0x8e8')](_0x48bf9f('0x197d'))['ok'](_0x48bf9f('0x18'))[_0x48bf9f('0x3f')](_0x48bf9f('0x497'))[_0x48bf9f('0x203b')](_0x5139e0);_0xce5dd2[_0x48bf9f('0x1f80')](_0xc43514)[_0x48bf9f('0x1166')](function(){const _0x3f37e2=_0x48bf9f;_0x2333d2['intZohoConfiguration'][_0x3f37e2('0x906')]({'id':_0x3b4628[_0x3f37e2('0x1fa0')]['id']})[_0x3f37e2('0xa44')][_0x3f37e2('0x1166')](function(){const _0x181980=_0x3f37e2;_0x2cfb05()[_0x181980('0x127f')](_0x3b4628[_0x181980('0xd54')],{'id':_0x3b4628['zohoConfiguration']['id']}),_0xd4570b['success']({'title':_0x181980('0x1cc2'),'msg':(_0x3b4628[_0x181980('0x1fa0')][_0x181980('0x4f0')]||_0x181980('0x1fa0'))+_0x181980('0x7cd')}),_0x1c3a32(_0x3b4628[_0x181980('0x1fa0')]);})[_0x3f37e2('0x1a80')](function(_0x3568e4){const _0x1c588b=_0x3f37e2;if(_0x3568e4[_0x1c588b('0x25f4')]&&_0x3568e4[_0x1c588b('0x25f4')][_0x1c588b('0x61a')]&&_0x3568e4[_0x1c588b('0x25f4')][_0x1c588b('0x61a')]['length']){_0x3b4628[_0x1c588b('0x61a')]=_0x3568e4['data'][_0x1c588b('0x61a')]||[{'message':_0x3568e4['toString'](),'type':_0x1c588b('0x92b')}];for(let _0x311dbc=0x0;_0x311dbc<_0x3568e4['data'][_0x1c588b('0x61a')][_0x1c588b('0x264b')];_0x311dbc++){_0xd4570b[_0x1c588b('0xfc9')]({'title':_0x3568e4[_0x1c588b('0x25f4')][_0x1c588b('0x61a')][_0x311dbc][_0x1c588b('0x1345')],'msg':_0x3568e4[_0x1c588b('0x25f4')][_0x1c588b('0x61a')][_0x311dbc]['message']});}}else _0xd4570b[_0x1c588b('0xfc9')]({'title':_0x3568e4['status']?_0x1c588b('0x1e21')+_0x3568e4[_0x1c588b('0x52d')]+_0x1c588b('0x11e1')+_0x3568e4[_0x1c588b('0xe1b')]:_0x1c588b('0x92b'),'msg':_0x3568e4[_0x1c588b('0x25f4')]?JSON[_0x1c588b('0xbac')](_0x3568e4[_0x1c588b('0x25f4')]['message']):_0x3568e4[_0x1c588b('0x1e70')]||_0x3568e4[_0x1c588b('0x1586')]()});});},function(){});}function _0x121510(_0x110fb1){return _0x110fb1===null?undefined:new Date(_0x110fb1);}function _0x1c3a32(_0x31a35f){const _0x4fb437=_0x6fa966;_0xce5dd2[_0x4fb437('0x1197')](_0x31a35f);}}const _0xc8e80=_0x3f5bd9;_0x26c08e['$inject']=['$scope','$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xd29'),'items',_0x36e6f4('0x1301'),_0x36e6f4('0x1a32'),'type',_0x36e6f4('0x19e3'),'Auth','crudPermissions'];function _0x26c08e(_0x3d8b26,_0xa3b332,_0x2494db,_0x2b73d6,_0x2726fd,_0x59a884,_0xf671a6,_0x2eafed,_0x35b622,_0x41a2ac,_0x1de84a,_0x43b332,_0x33c1b3){const _0x5e2a3b=_0x36e6f4,_0x2ed081=this;_0x2ed081[_0x5e2a3b('0x98')]=_0x43b332[_0x5e2a3b('0x26cd')](),_0x2ed081['errors']=[],_0x2ed081[_0x5e2a3b('0xcdc')]=_0x5e2a3b('0x2012')+_0x2cfb05()['toUpper'](_0x41a2ac),_0x2ed081[_0x5e2a3b('0x1301')]=angular[_0x5e2a3b('0x225f')](_0x2eafed),_0x2ed081[_0x5e2a3b('0xbd7')]=_0xf671a6,_0x2ed081[_0x5e2a3b('0x1345')]=_0x41a2ac,_0x2ed081['crudPermissions']=_0x33c1b3,_0x2ed081[_0x5e2a3b('0x17c7')]=![];!_0x2ed081[_0x5e2a3b('0x1301')]&&(_0x2ed081[_0x5e2a3b('0x1301')]={'type':_0x5e2a3b('0x102c')},_0x2ed081[_0x5e2a3b('0x1301')][_0x2cfb05()['capitalize'](_0x41a2ac)+'Id']=_0x59a884['id'],_0x2ed081[_0x5e2a3b('0xcdc')]='INTEGRATIONS.NEW_'+_0x2cfb05()['toUpper'](_0x41a2ac),_0x2ed081[_0x5e2a3b('0x17c7')]=!![]);_0x2ed081['addNewItem']=_0x5f24ad,_0x2ed081[_0x5e2a3b('0x13b8')]=_0x567f23,_0x2ed081['deleteItem']=_0x48d79b,_0x2ed081[_0x5e2a3b('0x1551')]=_0xa9e76f,_0x2ed081[_0x5e2a3b('0x24a0')]=_0xf3eec4,_0x1de84a[_0x5e2a3b('0x734')][_0x5e2a3b('0xd83')]({'nolimit':!![]})['$promise']['then'](function(_0xa531b7){const _0x23dd11=_0x5e2a3b;return _0x2ed081[_0x23dd11('0x57a')]=_0xa531b7[_0x23dd11('0x269a')]?_0xa531b7[_0x23dd11('0x269a')]:[],_0x1de84a[_0x23dd11('0x7af')]['describe']()[_0x23dd11('0xa44')];})[_0x5e2a3b('0x1166')](function(_0x104cf7){const _0x48db25=_0x5e2a3b;return _0x2ed081[_0x48db25('0x1d45')]=_0x2cfb05()[_0x48db25('0x13ca')](_0x2cfb05()['keys'](_0x104cf7),['$promise',_0x48db25('0xfcd'),_0x48db25('0x262'),_0x48db25('0x6f9'),_0x48db25('0x978')]),_0x2ed081['voiceAgentReportColumns'][_0x48db25('0x1514')](_0x48db25('0xa29')),_0x1de84a[_0x48db25('0x21f9')][_0x48db25('0x23d0')]()[_0x48db25('0xa44')];})['then'](function(_0x499fc0){const _0x350199=_0x5e2a3b;_0x2ed081['voiceDialReportColumns']=_0x2cfb05()[_0x350199('0x13ca')](_0x2cfb05()[_0x350199('0x14a4')](_0x499fc0),[_0x350199('0xa44'),_0x350199('0xfcd'),_0x350199('0x262'),_0x350199('0x6f9'),'sourceid']),_0x2ed081[_0x350199('0x1348')]['push'](_0x350199('0xa29'));})['catch'](function(_0x3224fb){const _0x4c6731=_0x5e2a3b;_0x2726fd[_0x4c6731('0xfc9')]({'title':_0x3224fb[_0x4c6731('0x52d')]?_0x4c6731('0x1e21')+_0x3224fb[_0x4c6731('0x52d')]+_0x4c6731('0x11e1')+_0x3224fb['statusText']:_0x4c6731('0xfe5'),'msg':_0x3224fb[_0x4c6731('0x25f4')]?JSON[_0x4c6731('0xbac')](_0x3224fb[_0x4c6731('0x25f4')]):_0x3224fb[_0x4c6731('0x1586')]()});}),_0x1de84a[_0x5e2a3b('0x11d1')]['getFields']({'id':_0x35b622['id'],'ticketType':_0x59a884['ticketType']?_0x59a884['ticketType']:undefined})[_0x5e2a3b('0xa44')][_0x5e2a3b('0x1166')](function(_0x4a721b){const _0x507ac7=_0x5e2a3b;_0x2ed081[_0x507ac7('0x606')]=!![],_0x2ed081[_0x507ac7('0xfe2')]=_0x4a721b['rows']?_0x4a721b[_0x507ac7('0x269a')]:[],_0x2ed081[_0x507ac7('0x1301')]['idField']&&(_0x2ed081[_0x507ac7('0x117e')]=_0x2cfb05()[_0x507ac7('0xc38')](_0x2ed081[_0x507ac7('0xfe2')],{'id':_0x2ed081['item']['idField']}));})[_0x5e2a3b('0x1a80')](function(_0x471648){const _0x5a6643=_0x5e2a3b;_0x2ed081[_0x5a6643('0x606')]=![],console['error'](_0x471648);});function _0x5f24ad(){const _0x4fe7d5=_0x5e2a3b;_0x2ed081['errors']=[],_0x2ed081[_0x4fe7d5('0x117e')]&&(_0x2ed081[_0x4fe7d5('0x1301')][_0x4fe7d5('0x1143')]=_0x2ed081['customField']['id'],_0x2ed081[_0x4fe7d5('0x1301')]['nameField']=_0x2ed081[_0x4fe7d5('0x117e')][_0x4fe7d5('0x4f0')],_0x2ed081[_0x4fe7d5('0x1301')]['customField']=_0x2ed081['customField'][_0x4fe7d5('0x2853')]),_0x1de84a['intZohoField'][_0x4fe7d5('0x9cc')](_0x2ed081[_0x4fe7d5('0x1301')])[_0x4fe7d5('0xa44')][_0x4fe7d5('0x1166')](function(_0x33e5ec){const _0x377469=_0x4fe7d5;_0x2ed081[_0x377469('0xbd7')][_0x377469('0x2450')](_0x33e5ec),_0x2726fd[_0x377469('0x103b')]({'title':_0x2cfb05()[_0x377469('0x92c')](_0x41a2ac)+'\x20properly\x20created','msg':_0x2cfb05()[_0x377469('0x92c')](_0x41a2ac)+'\x20has\x20been\x20created!'}),_0xf3eec4();})[_0x4fe7d5('0x1a80')](function(_0x286c6d){const _0x439bf4=_0x4fe7d5;console['error'](_0x286c6d),_0x2ed081[_0x439bf4('0x61a')]=_0x286c6d['data'][_0x439bf4('0x61a')]||[{'message':_0x286c6d[_0x439bf4('0x1586')](),'type':_0x439bf4('0x215d')}];});}function _0x567f23(){const _0x565dd1=_0x5e2a3b;_0x2ed081['errors']=[],_0x2ed081['customField']&&(_0x2ed081[_0x565dd1('0x1301')][_0x565dd1('0x1143')]=_0x2ed081[_0x565dd1('0x117e')]['id'],_0x2ed081[_0x565dd1('0x1301')][_0x565dd1('0x3c0')]=_0x2ed081['customField'][_0x565dd1('0x4f0')],_0x2ed081[_0x565dd1('0x1301')][_0x565dd1('0x117e')]=_0x2ed081[_0x565dd1('0x117e')][_0x565dd1('0x2853')]),_0x1de84a[_0x565dd1('0xf62')][_0x565dd1('0x1449')]({'id':_0x2ed081['item']['id']},_0x2ed081[_0x565dd1('0x1301')])[_0x565dd1('0xa44')][_0x565dd1('0x1166')](function(_0x46f4f0){const _0x3a4dcd=_0x565dd1,_0x295606=_0x2cfb05()['find'](_0x2ed081[_0x3a4dcd('0xbd7')],{'id':_0x46f4f0['id']});_0x295606&&_0x2cfb05()[_0x3a4dcd('0xcc3')](_0x295606,_0x46f4f0),_0x2726fd[_0x3a4dcd('0x103b')]({'title':_0x2cfb05()[_0x3a4dcd('0x92c')](_0x41a2ac)+_0x3a4dcd('0x1a2f'),'msg':_0x2cfb05()[_0x3a4dcd('0x92c')](_0x41a2ac)+_0x3a4dcd('0x7d')}),_0xf3eec4();})[_0x565dd1('0x1a80')](function(_0x109fff){const _0x4e78e2=_0x565dd1;console[_0x4e78e2('0xfc9')](_0x109fff),_0x2ed081[_0x4e78e2('0x61a')]=_0x109fff[_0x4e78e2('0x25f4')]['errors']||[{'message':_0x109fff[_0x4e78e2('0x1586')](),'type':_0x4e78e2('0x10cd')}];});}function _0x48d79b(_0x8c8a8c){const _0x433d25=_0x5e2a3b;_0x2ed081[_0x433d25('0x61a')]=[];const _0x4e7f42=_0x2b73d6[_0x433d25('0x1d26')]()[_0x433d25('0xcdc')](_0x433d25('0x7fb'))[_0x433d25('0xacc')](_0x433d25('0x135f')+_0x41a2ac+_0x433d25('0x3f3'))[_0x433d25('0x8e8')](_0x433d25('0x237c')+_0x2cfb05()['capitalize'](_0x41a2ac))['ok'](_0x433d25('0x18'))[_0x433d25('0x3f')](_0x433d25('0x497'))[_0x433d25('0x203b')](_0x8c8a8c);_0x2b73d6['show'](_0x4e7f42)[_0x433d25('0x1166')](function(){const _0x1d5f3b=_0x433d25;_0x1de84a[_0x1d5f3b('0xf62')]['delete']({'id':_0x2ed081['item']['id']})[_0x1d5f3b('0xa44')]['then'](function(){const _0xf809f=_0x1d5f3b;_0x2cfb05()[_0xf809f('0x127f')](_0x2ed081[_0xf809f('0xbd7')],{'id':_0x2ed081[_0xf809f('0x1301')]['id']}),_0x2726fd[_0xf809f('0x103b')]({'title':_0x2cfb05()['capitalize'](_0x41a2ac)+'\x20properly\x20deleted!','msg':_0x2cfb05()[_0xf809f('0x92c')](_0x41a2ac)+_0xf809f('0x7cd')}),_0xf3eec4();})['catch'](function(_0x18b032){const _0x418b39=_0x1d5f3b;console[_0x418b39('0xfc9')](_0x18b032),_0x2ed081[_0x418b39('0x61a')]=_0x18b032[_0x418b39('0x25f4')]['errors']||[{'message':_0x18b032[_0x418b39('0x1586')](),'type':_0x418b39('0x2602')}];});},function(){});}function _0xa9e76f(){const _0x48529b=_0x5e2a3b;return _0x2ed081[_0x48529b('0x1301')][_0x48529b('0xbdb')]!==undefined?_0x2ed081[_0x48529b('0x1301')][_0x48529b('0xbdb')]:_0x48529b('0x16a4');}function _0xf3eec4(){const _0x30bcb8=_0x5e2a3b;_0x2b73d6[_0x30bcb8('0x1197')]();}}const _0x359da7=_0x26c08e;_0x11bf3a['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x216d'),_0x36e6f4('0x17aa')];function _0x11bf3a(_0x203714,_0xcbd984,_0x1488c4,_0x47558b,_0x2d37ae,_0x329712,_0x11f3ce,_0x16d83e,_0x32d54a,_0x31014f,_0x4f8a67,_0x549276){const _0x27293e=_0x36e6f4,_0x2f9014=this;_0x2f9014[_0x27293e('0x98')]=_0x31014f['getCurrentUser'](),_0x2f9014[_0x27293e('0x5c9')]=_0x329712,_0x2f9014[_0x27293e('0xf8a')]=_0x11f3ce,_0x2f9014[_0x27293e('0x2900')]=_0x2f9014[_0x27293e('0xf8a')][_0x27293e('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2f9014[_0x27293e('0x246b')]=_0xcbd984['protocol']()+_0x27293e('0xc51')+_0xcbd984[_0x27293e('0x1690')](),_0x2f9014[_0x27293e('0x216d')]=_0x4f8a67||_0x203714[_0x27293e('0x23f')][_0x27293e('0x216d')]||{},_0x2f9014[_0x27293e('0x17aa')]=_0x549276&&_0x549276[_0x27293e('0x240f')]==0x1?_0x549276[_0x27293e('0x269a')][0x0]:null,_0x2f9014['crudPermissions']=_0x31014f['parseCrudPermissions'](_0x2f9014[_0x27293e('0x17aa')]?_0x2f9014[_0x27293e('0x17aa')]['crudPermissions']:null),_0x2f9014[_0x27293e('0x128b')]={},_0x2f9014['selectedTab']=_0x203714[_0x27293e('0x23f')]['tab']||0x0,_0x2f9014[_0x27293e('0x31d')]=_0x32d54a['info'],_0x2f9014[_0x27293e('0x2dc')]=_0x3c3162,_0x2f9014[_0x27293e('0x1bd')]=_0x4148a9;function _0x3c3162(){const _0x5a226e=_0x27293e;_0x203714['go']('app.integrations.zohoAccounts',{},{'reload':_0x5a226e('0x11f3')});}function _0x4148a9(){const _0x4dec6a=_0x27293e;_0x16d83e[_0x4dec6a('0x11d1')]['update']({'id':_0x2f9014[_0x4dec6a('0x216d')]['id']},_0x2f9014['zohoAccount'])['$promise'][_0x4dec6a('0x1166')](function(){const _0x316139=_0x4dec6a;_0x32d54a[_0x316139('0x103b')]({'title':_0x316139('0x17d4'),'msg':_0x2f9014[_0x316139('0x216d')]['name']?_0x2f9014[_0x316139('0x216d')][_0x316139('0x4f0')]+_0x316139('0xa17'):''});})[_0x4dec6a('0x1a80')](function(_0x3dadc9){const _0x41527b=_0x4dec6a;_0x32d54a['error']({'title':_0x3dadc9[_0x41527b('0x52d')]?_0x41527b('0x1e21')+_0x3dadc9[_0x41527b('0x52d')]+'\x20-\x20'+_0x3dadc9[_0x41527b('0xe1b')]:_0x41527b('0xea1'),'msg':_0x3dadc9['data']?JSON[_0x41527b('0xbac')](_0x3dadc9[_0x41527b('0x25f4')]):_0x3dadc9[_0x41527b('0x1586')]()});});}}const _0x3a85ba=_0x11bf3a,_0x57d0b1=_0x2734b2['p']+'src/js/modules/main/apps/integrations/views/zohoAccounts/create/dialog.html/dialog.html';_0x37e04c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'zohoAccounts',_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x19e3'),'msUtils',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x37e04c(_0x4f4fd9,_0xe083ae,_0x2630f9,_0x5a5f3b,_0x5d20f0,_0x4a6664,_0x1b6e3d,_0x1d3d74,_0x11ba98,_0x4bb9e3,_0x23ccc0,_0x1d8bc3,_0x5c1577,_0x453208,_0x26006a,_0x4c267b,_0x298e65){const _0x57f39c=_0x36e6f4,_0x5809b2=this;_0x5809b2[_0x57f39c('0x5c9')]=_0x4c267b,_0x5809b2[_0x57f39c('0xf8a')]=_0x298e65,_0x5809b2['currentUser']=_0x26006a[_0x57f39c('0x26cd')](),_0x5809b2[_0x57f39c('0x10ca')]=_0x11ba98||{'count':0x0,'rows':[]},_0x5809b2[_0x57f39c('0x7f')]=_0x4bb9e3,_0x5809b2[_0x57f39c('0x17aa')]=_0x23ccc0&&_0x23ccc0['count']==0x1?_0x23ccc0[_0x57f39c('0x269a')][0x0]:null,_0x5809b2[_0x57f39c('0x243c')]=_0x26006a[_0x57f39c('0xd87')](_0x5809b2[_0x57f39c('0x17aa')]?_0x5809b2[_0x57f39c('0x17aa')]['crudPermissions']:null),_0x5809b2[_0x57f39c('0x916')]='zohoAccounts',_0x5809b2['listOrder']='',_0x5809b2[_0x57f39c('0x104c')]=null,_0x5809b2['selectedZohoAccounts']=[],_0x5809b2['query']={'fields':_0x57f39c('0x9c7'),'limit':0xa,'page':0x1},_0x5809b2[_0x57f39c('0x2811')]=_0x2cfb05()[_0x57f39c('0x155c')]([{'option':_0x57f39c('0x285b'),'value':_0x57f39c('0x3ad')},{'option':'zoho.eu','value':_0x57f39c('0x1250')}],function(_0x42f1b3){const _0x551831=_0x57f39c;return _0x2cfb05()[_0x551831('0xf3')](_0x42f1b3[_0x551831('0x18e0')],new RegExp('\x27','g'),'');}),_0x5809b2[_0x57f39c('0x9ce')]=_0x2cfb05()[_0x57f39c('0x155c')]([{'option':'US','value':'\x27US\x27'},{'option':'AU','value':_0x57f39c('0xbef')},{'option':'EU','value':'\x27EU\x27'},{'option':'IN','value':_0x57f39c('0x2601')},{'option':'CN','value':_0x57f39c('0x20fc')}],function(_0x464e02){const _0xe076d8=_0x57f39c;return _0x2cfb05()[_0xe076d8('0xf3')](_0x464e02[_0xe076d8('0x18e0')],new RegExp('\x27','g'),'');}),_0x5809b2[_0x57f39c('0x1ff6')]=_0x5ade57,_0x5809b2[_0x57f39c('0x2113')]=_0x14d36b,_0x5809b2[_0x57f39c('0x8d8')]=_0x4b1673,_0x5809b2[_0x57f39c('0x103b')]=_0x517490,_0x5809b2[_0x57f39c('0x1a5a')]=_0x417b3d,_0x5809b2[_0x57f39c('0x91d')]=_0x5875f3,_0x5809b2[_0x57f39c('0x1a8f')]=_0x44b53a,_0x5809b2[_0x57f39c('0xe88')]=_0x197cf9,_0x5809b2[_0x57f39c('0x22fe')]=_0x29d327,_0x5809b2[_0x57f39c('0x1c4f')]=_0x4b0ffc,_0x5809b2[_0x57f39c('0x688')]=_0x109f2e;function _0x5ade57(_0x488128){const _0x405915=_0x57f39c;_0x2630f9['go'](_0x405915('0x1d10'),{'id':_0x488128['id'],'zohoAccount':_0x488128,'crudPermissions':_0x5809b2[_0x405915('0x243c')]});}function _0x14d36b(_0x1e61ce){const _0x3638df=_0x57f39c;return _0x1d8bc3[_0x3638df('0x11d1')][_0x3638df('0x18ea')]({'id':_0x1e61ce['id'],'test':!![]})['$promise'][_0x3638df('0x1166')](function(){const _0x159bea=_0x3638df;_0x453208[_0x159bea('0x103b')]({'title':_0x159bea('0x1bf3'),'msg':_0x159bea('0x1fef')});})['catch'](function(_0x355402){const _0x48789c=_0x3638df;_0x453208[_0x48789c('0xfc9')]({'title':_0x48789c('0x1bf3'),'msg':_0x355402[_0x48789c('0x25f4')]?_0x355402[_0x48789c('0x25f4')]['message']?_0x355402[_0x48789c('0x25f4')]['message']:JSON[_0x48789c('0xbac')](_0x355402[_0x48789c('0x25f4')]):_0x355402[_0x48789c('0x1586')]()});});}function _0x4b1673(_0x50af76,_0xb86c82){const _0x5e35f9=_0x57f39c,_0x400269=_0x5d20f0[_0x5e35f9('0x1d26')]()['title'](_0x5e35f9('0x288d')+_0x2cfb05()[_0x5e35f9('0xb35')](_0x5e35f9('0x216d'))+'?')[_0x5e35f9('0xf3c')](_0x5e35f9('0x12b5')+(_0x50af76['name']||_0x5e35f9('0x216d'))+_0x5e35f9('0xace')+'\x20will\x20be\x20deleted.')[_0x5e35f9('0x8e8')](_0x5e35f9('0x24eb'))[_0x5e35f9('0x203b')](_0xb86c82)['ok']('OK')[_0x5e35f9('0x3f')](_0x5e35f9('0x2d3'));_0x5d20f0[_0x5e35f9('0x1f80')](_0x400269)['then'](function(){_0x44b53a(_0x50af76);},function(){const _0x1b4d02=_0x5e35f9;console[_0x1b4d02('0x455')](_0x1b4d02('0x2d3'));});}let _0x2ad71c=!![],_0x1789c9=0x1;_0x4f4fd9[_0x57f39c('0xe83')](_0x57f39c('0x12d8'),function(_0xe9cb2a,_0x71059a){const _0x1855c3=_0x57f39c;_0x2ad71c?_0x1b6e3d(function(){_0x2ad71c=![];}):(!_0x71059a&&(_0x1789c9=_0x5809b2['query'][_0x1855c3('0x1a43')]),_0xe9cb2a!==_0x71059a&&(_0x5809b2[_0x1855c3('0x2218')]['page']=0x1),!_0xe9cb2a&&(_0x5809b2[_0x1855c3('0x2218')][_0x1855c3('0x1a43')]=_0x1789c9),_0x5809b2['getZohoAccounts']());});function _0x517490(_0x647251){const _0x470ad3=_0x57f39c;_0x5809b2[_0x470ad3('0x10ca')]=_0x647251||{'count':0x0,'rows':[]};}function _0x417b3d(){const _0x4da25d=_0x57f39c;_0x5809b2[_0x4da25d('0x2218')]['offset']=(_0x5809b2[_0x4da25d('0x2218')]['page']-0x1)*_0x5809b2[_0x4da25d('0x2218')][_0x4da25d('0x163f')],_0x26006a[_0x4da25d('0x1ac6')](_0x4da25d('0xa7c'))?_0x5809b2[_0x4da25d('0x1f48')]=_0x1d8bc3['intZohoAccount'][_0x4da25d('0xd83')](_0x5809b2[_0x4da25d('0x2218')],_0x517490)[_0x4da25d('0xa44')]:(_0x5809b2['query']['id']=_0x5809b2['userProfile']['id'],_0x5809b2[_0x4da25d('0x2218')][_0x4da25d('0xe60')]=_0x4da25d('0x1f5b'),_0x5809b2[_0x4da25d('0x1f48')]=_0x1d8bc3[_0x4da25d('0x7f')]['getResources'](_0x5809b2['query'],_0x517490)['$promise']);}function _0x5875f3(_0x6b988c,_0x3708ff){const _0x1ac578=_0x57f39c;_0x5d20f0[_0x1ac578('0x1f80')]({'controller':_0x1ac578('0x1c53'),'controllerAs':'vm','templateUrl':_0x57d0b1,'parent':angular['element'](_0x4a6664[_0x1ac578('0x8d2')]),'targetEvent':_0x6b988c,'clickOutsideToClose':!![],'locals':{'zohoAccount':_0x3708ff,'zohoAccounts':_0x5809b2[_0x1ac578('0x10ca')][_0x1ac578('0x269a')],'license':_0x5809b2['license'],'setting':_0x5809b2[_0x1ac578('0xf8a')],'crudPermissions':_0x5809b2['crudPermissions']}});}function _0x44b53a(_0x5e59c6){const _0x4951cd=_0x57f39c;_0x1d8bc3[_0x4951cd('0x11d1')]['delete']({'id':_0x5e59c6['id']})['$promise'][_0x4951cd('0x1166')](function(){const _0x8de93a=_0x4951cd;_0x2cfb05()['remove'](_0x5809b2['zohoAccounts']['rows'],{'id':_0x5e59c6['id']}),_0x5809b2['zohoAccounts'][_0x8de93a('0x240f')]-=0x1,!_0x5809b2[_0x8de93a('0x10ca')]['rows'][_0x8de93a('0x264b')]&&_0x5809b2['getZohoAccounts'](),_0x453208[_0x8de93a('0x103b')]({'title':_0x2cfb05()[_0x8de93a('0xb35')]('ZohoAccount')+_0x8de93a('0x2b6'),'msg':_0x5e59c6[_0x8de93a('0x4f0')]?_0x5e59c6['name']+_0x8de93a('0x7cd'):''});})[_0x4951cd('0x1a80')](function(_0x1f32b5){const _0x1abbdf=_0x4951cd;if(_0x1f32b5['data']&&_0x1f32b5[_0x1abbdf('0x25f4')][_0x1abbdf('0x61a')]&&_0x1f32b5[_0x1abbdf('0x25f4')][_0x1abbdf('0x61a')][_0x1abbdf('0x264b')]){_0x5809b2['errors']=_0x1f32b5[_0x1abbdf('0x25f4')][_0x1abbdf('0x61a')]||[{'message':_0x1f32b5[_0x1abbdf('0x1586')](),'type':'SYSTEM:DELETEintZohoAccount'}];for(let _0x3c2121=0x0;_0x3c2121<_0x1f32b5[_0x1abbdf('0x25f4')][_0x1abbdf('0x61a')][_0x1abbdf('0x264b')];_0x3c2121++){_0x453208[_0x1abbdf('0xfc9')]({'title':_0x1f32b5['data'][_0x1abbdf('0x61a')][_0x3c2121]['type'],'msg':_0x1f32b5['data'][_0x1abbdf('0x61a')][_0x3c2121]['message']});}}else _0x453208[_0x1abbdf('0xfc9')]({'title':_0x1f32b5['status']?_0x1abbdf('0x1e21')+_0x1f32b5[_0x1abbdf('0x52d')]+'\x20-\x20'+_0x1f32b5['statusText']:_0x1abbdf('0x596'),'msg':_0x1f32b5[_0x1abbdf('0x25f4')]?JSON['stringify'](_0x1f32b5[_0x1abbdf('0x25f4')]['message']):_0x1f32b5[_0x1abbdf('0x1e70')]||_0x1f32b5[_0x1abbdf('0x1586')]()});});}function _0x197cf9(){const _0x327bfe=_0x57f39c,_0x50e272=angular[_0x327bfe('0x225f')](_0x5809b2[_0x327bfe('0x6c1')]);return _0x5809b2[_0x327bfe('0x6c1')]=[],_0x50e272;}function _0x29d327(_0x40965f){const _0x595a1d=_0x57f39c,_0x416b44=_0x5d20f0[_0x595a1d('0x1d26')]()[_0x595a1d('0xcdc')](_0x595a1d('0xe98'))[_0x595a1d('0xf3c')](_0x595a1d('0x12b5')+_0x5809b2[_0x595a1d('0x6c1')][_0x595a1d('0x264b')]+_0x595a1d('0x196d')+_0x595a1d('0x3f3'))[_0x595a1d('0x8e8')]('delete\x20ZohoAccounts')[_0x595a1d('0x203b')](_0x40965f)['ok']('OK')['cancel']('CANCEL');_0x5d20f0[_0x595a1d('0x1f80')](_0x416b44)[_0x595a1d('0x1166')](function(){const _0x18b6ab=_0x595a1d;_0x5809b2[_0x18b6ab('0x6c1')][_0x18b6ab('0x2782')](function(_0x111fd5){_0x44b53a(_0x111fd5);}),_0x5809b2[_0x18b6ab('0x6c1')]=[];});}function _0x4b0ffc(){_0x5809b2['selectedZohoAccounts']=[];}function _0x109f2e(){const _0x23ad93=_0x57f39c;_0x5809b2[_0x23ad93('0x6c1')]=_0x5809b2[_0x23ad93('0x10ca')]['rows'];}}const _0x25e88f=_0x37e04c;_0xf47e83['$inject']=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0xf47e83(_0xa7445b,_0x14eff3){const _0x31a92f=_0x36e6f4;_0xa7445b[_0x31a92f('0x63f')](_0x31a92f('0x5f2'),{'abstract':!![],'url':_0x31a92f('0x1b1d')})[_0x31a92f('0x63f')](_0x31a92f('0x1600'),{'url':'/zendeskAccounts','views':{'content@app':{'templateUrl':_0x2fe933,'controller':_0x31a92f('0x20be')}},'resolve':{'zendeskAccounts':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x330e80,_0xe76f9e){const _0x1a8e9a=_0x31a92f;return _0xe76f9e[_0x1a8e9a('0x1ac6')]('admin')?_0x330e80[_0x1a8e9a('0x18af')](_0x1a8e9a('0x10aa'),{'fields':'createdAt,updatedAt,id,name,type,username,remoteUri,authType,password,token,serverUrl,description','limit':0xa,'offset':0x0}):_0x330e80[_0x1a8e9a('0x18af')](_0x1a8e9a('0x17c4'),{'id':_0xe76f9e[_0x1a8e9a('0x26cd')]()['userProfileId'],'section':_0x1a8e9a('0xc99'),'fields':_0x1a8e9a('0x1e71'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x58e924,_0x2ebaa6){const _0x4acf20=_0x31a92f;return _0x2ebaa6[_0x4acf20('0x1ac6')](_0x4acf20('0xa7c'))?null:_0x58e924[_0x4acf20('0x18af')](_0x4acf20('0x697'),{'fields':_0x4acf20('0x686'),'id':_0x2ebaa6[_0x4acf20('0x26cd')]()[_0x4acf20('0xb86')]});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x4d19d8,_0x496895){const _0x3a25d8=_0x31a92f;return _0x496895[_0x3a25d8('0x1ac6')](_0x3a25d8('0xa7c'))?null:_0x4d19d8[_0x3a25d8('0x18af')](_0x3a25d8('0xaf'),{'fields':_0x3a25d8('0xe26'),'userProfileId':_0x496895[_0x3a25d8('0x26cd')]()[_0x3a25d8('0xb86')],'sectionId':0x515});}]},'authenticate':!![],'permissionId':0x515,'bodyClass':'integrations'})[_0x31a92f('0x63f')](_0x31a92f('0x2630'),{'url':_0x31a92f('0x2233'),'params':{'zendeskAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x55409b,'controller':_0x31a92f('0xd42')}},'resolve':{'zendeskAccount':[_0x31a92f('0x1fbc'),_0x31a92f('0xf75'),function(_0x3a99d7,_0x3d4ff5){const _0x3172e5=_0x31a92f;return _0x3a99d7['resolve'](_0x3172e5('0x10aa'),{'fields':_0x3172e5('0x1e71'),'id':_0x3d4ff5['id']});}],'userProfileSection':['apiResolver',_0x31a92f('0x21ef'),function(_0xa6ef30,_0x12dbd8){const _0x2f401c=_0x31a92f;return _0xa6ef30[_0x2f401c('0x18af')](_0x2f401c('0xaf'),{'fields':_0x2f401c('0xe26'),'userProfileId':_0x12dbd8[_0x2f401c('0x26cd')]()['userProfileId'],'sectionId':0x515});}]},'authenticate':!![],'permissionId':0x515,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0x1df9'),{'url':'/salesforceAccounts','views':{'content@app':{'templateUrl':_0x26f42a,'controller':_0x31a92f('0xbff')}},'resolve':{'salesforceAccounts':[_0x31a92f('0x1fbc'),'Auth',function(_0x55542c,_0x28e494){const _0x52aa7d=_0x31a92f;return _0x28e494[_0x52aa7d('0x1ac6')](_0x52aa7d('0xa7c'))?_0x55542c[_0x52aa7d('0x18af')]('intSalesforceAccount@get',{'fields':_0x52aa7d('0x1742'),'limit':0xa,'offset':0x0}):_0x55542c[_0x52aa7d('0x18af')](_0x52aa7d('0x17c4'),{'id':_0x28e494[_0x52aa7d('0x26cd')]()['userProfileId'],'section':_0x52aa7d('0x350'),'fields':_0x52aa7d('0x1742'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x31a92f('0x1fbc'),'Auth',function(_0x319a09,_0xf1094a){const _0x1b10a7=_0x31a92f;return _0xf1094a['hasRole']('admin')?null:_0x319a09[_0x1b10a7('0x18af')](_0x1b10a7('0x697'),{'fields':'id,name,crudPermissions','id':_0xf1094a[_0x1b10a7('0x26cd')]()[_0x1b10a7('0xb86')]});}],'userProfileSection':['apiResolver',_0x31a92f('0x21ef'),function(_0x1cb4f0,_0x3e6735){const _0x31899c=_0x31a92f;return _0x3e6735[_0x31899c('0x1ac6')](_0x31899c('0xa7c'))?null:_0x1cb4f0[_0x31899c('0x18af')](_0x31899c('0xaf'),{'fields':_0x31899c('0xe26'),'userProfileId':_0x3e6735['getCurrentUser']()['userProfileId'],'sectionId':0x516});}]},'authenticate':!![],'permissionId':0x516,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0x1445'),{'url':'/:id?tab','params':{'salesforceAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x4caa85,'controller':'SalesforceAccountController\x20as\x20vm'}},'resolve':{'salesforceAccount':[_0x31a92f('0x1fbc'),'$stateParams',function(_0x2a8c13,_0x38ee99){const _0x5afd4d=_0x31a92f;return _0x2a8c13[_0x5afd4d('0x18af')]('intSalesforceAccount@get',{'fields':_0x5afd4d('0x1742'),'id':_0x38ee99['id']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x1237c8,_0x33fe65){const _0xd6577=_0x31a92f;return _0x1237c8[_0xd6577('0x18af')](_0xd6577('0xaf'),{'fields':_0xd6577('0xe26'),'userProfileId':_0x33fe65[_0xd6577('0x26cd')]()[_0xd6577('0xb86')],'sectionId':0x516});}]},'authenticate':!![],'permissionId':0x516,'bodyClass':_0x31a92f('0x1ba0')})['state'](_0x31a92f('0x28c7'),{'url':'/freshdeskAccounts','views':{'content@app':{'templateUrl':_0x433034,'controller':'FreshdeskAccountsController\x20as\x20vm'}},'resolve':{'freshdeskAccounts':['apiResolver',_0x31a92f('0x21ef'),function(_0x4273bc,_0x52d794){const _0x400cbf=_0x31a92f;return _0x52d794[_0x400cbf('0x1ac6')]('admin')?_0x4273bc[_0x400cbf('0x18af')](_0x400cbf('0x6b4'),{'fields':_0x400cbf('0x7d6'),'limit':0xa,'offset':0x0}):_0x4273bc[_0x400cbf('0x18af')](_0x400cbf('0x17c4'),{'id':_0x52d794[_0x400cbf('0x26cd')]()['userProfileId'],'section':_0x400cbf('0x1c35'),'fields':_0x400cbf('0x7d6'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x54ba82,_0x27d816){const _0xed48e1=_0x31a92f;return _0x27d816[_0xed48e1('0x1ac6')](_0xed48e1('0xa7c'))?null:_0x54ba82[_0xed48e1('0x18af')](_0xed48e1('0x697'),{'fields':_0xed48e1('0x686'),'id':_0x27d816[_0xed48e1('0x26cd')]()[_0xed48e1('0xb86')]});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x4dd67b,_0x55afca){const _0x4027d4=_0x31a92f;return _0x55afca[_0x4027d4('0x1ac6')](_0x4027d4('0xa7c'))?null:_0x4dd67b['resolve'](_0x4027d4('0xaf'),{'fields':_0x4027d4('0xe26'),'userProfileId':_0x55afca['getCurrentUser']()['userProfileId'],'sectionId':0x517});}]},'authenticate':!![],'permissionId':0x517,'bodyClass':'integrations'})[_0x31a92f('0x63f')](_0x31a92f('0x21e5'),{'url':_0x31a92f('0x2233'),'params':{'freshdeskAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x1748f2,'controller':_0x31a92f('0x9ea')}},'resolve':{'freshdeskAccount':[_0x31a92f('0x1fbc'),_0x31a92f('0xf75'),function(_0x19235f,_0x4134a7){const _0x405185=_0x31a92f;return _0x19235f[_0x405185('0x18af')](_0x405185('0x6b4'),{'fields':_0x405185('0x7d6'),'id':_0x4134a7['id']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x4dd46d,_0x3cedfb){const _0x3527dd=_0x31a92f;return _0x4dd46d['resolve'](_0x3527dd('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x3cedfb[_0x3527dd('0x26cd')]()[_0x3527dd('0xb86')],'sectionId':0x517});}]},'authenticate':!![],'permissionId':0x517,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0xc98'),{'url':_0x31a92f('0x51f'),'views':{'content@app':{'templateUrl':_0x39b6e7,'controller':_0x31a92f('0xcff')}},'resolve':{'sugarcrmAccounts':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x1ecc13,_0x4bcd7a){const _0x2f29cd=_0x31a92f;return _0x4bcd7a[_0x2f29cd('0x1ac6')](_0x2f29cd('0xa7c'))?_0x1ecc13[_0x2f29cd('0x18af')](_0x2f29cd('0x799'),{'fields':_0x2f29cd('0x1b8b'),'limit':0xa,'offset':0x0}):_0x1ecc13[_0x2f29cd('0x18af')](_0x2f29cd('0x17c4'),{'id':_0x4bcd7a[_0x2f29cd('0x26cd')]()['userProfileId'],'section':_0x2f29cd('0xe20'),'fields':'createdAt,updatedAt,id,name,username,remoteUri,password,serverUrl,description','limit':0xa,'offset':0x0});}],'userProfile':[_0x31a92f('0x1fbc'),'Auth',function(_0x18ca3c,_0x41cff9){const _0x37be82=_0x31a92f;return _0x41cff9[_0x37be82('0x1ac6')](_0x37be82('0xa7c'))?null:_0x18ca3c['resolve']('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x41cff9[_0x37be82('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x51343a,_0x3bb084){const _0xa41c9=_0x31a92f;return _0x3bb084['hasRole'](_0xa41c9('0xa7c'))?null:_0x51343a[_0xa41c9('0x18af')](_0xa41c9('0xaf'),{'fields':_0xa41c9('0xe26'),'userProfileId':_0x3bb084[_0xa41c9('0x26cd')]()[_0xa41c9('0xb86')],'sectionId':0x519});}]},'authenticate':!![],'permissionId':0x519,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0x207'),{'url':_0x31a92f('0x2233'),'params':{'sugarcrmAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x1f27d8,'controller':_0x31a92f('0x1500')}},'resolve':{'sugarcrmAccount':[_0x31a92f('0x1fbc'),_0x31a92f('0xf75'),function(_0x68fc1f,_0xa76609){const _0x337834=_0x31a92f;return _0x68fc1f[_0x337834('0x18af')](_0x337834('0x799'),{'fields':_0x337834('0x1b8b'),'id':_0xa76609['id']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x2d0afa,_0x2ed97a){const _0x16b88f=_0x31a92f;return _0x2d0afa[_0x16b88f('0x18af')](_0x16b88f('0xaf'),{'fields':_0x16b88f('0xe26'),'userProfileId':_0x2ed97a[_0x16b88f('0x26cd')]()['userProfileId'],'sectionId':0x519});}]},'authenticate':!![],'permissionId':0x519,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')]('app.integrations.deskAccounts',{'url':_0x31a92f('0x2744'),'views':{'content@app':{'templateUrl':_0x361374,'controller':'DeskAccountsController\x20as\x20vm'}},'resolve':{'deskAccounts':[_0x31a92f('0x1fbc'),'Auth',function(_0x5e1b0f,_0xc99760){const _0x39607d=_0x31a92f;return _0xc99760[_0x39607d('0x1ac6')](_0x39607d('0xa7c'))?_0x5e1b0f[_0x39607d('0x18af')](_0x39607d('0xf15'),{'fields':_0x39607d('0x113c'),'limit':0xa,'offset':0x0}):_0x5e1b0f[_0x39607d('0x18af')]('userProfile@getResources',{'id':_0xc99760[_0x39607d('0x26cd')]()[_0x39607d('0xb86')],'section':'DeskAccounts','fields':_0x39607d('0x113c'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x5bf7e7,_0x5de47a){const _0x572355=_0x31a92f;return _0x5de47a[_0x572355('0x1ac6')](_0x572355('0xa7c'))?null:_0x5bf7e7[_0x572355('0x18af')](_0x572355('0x697'),{'fields':_0x572355('0x686'),'id':_0x5de47a[_0x572355('0x26cd')]()[_0x572355('0xb86')]});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x55751b,_0x56d493){const _0x42424c=_0x31a92f;return _0x56d493[_0x42424c('0x1ac6')](_0x42424c('0xa7c'))?null:_0x55751b[_0x42424c('0x18af')](_0x42424c('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x56d493[_0x42424c('0x26cd')]()[_0x42424c('0xb86')],'sectionId':0x51a});}]},'authenticate':!![],'permissionId':0x51a,'bodyClass':'integrations'})[_0x31a92f('0x63f')](_0x31a92f('0x39b'),{'url':_0x31a92f('0x2233'),'params':{'deskAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0xe5228b,'controller':_0x31a92f('0xcb9')}},'resolve':{'deskAccount':[_0x31a92f('0x1fbc'),'$stateParams',function(_0x1ca4ec,_0x25d58f){const _0x41b21a=_0x31a92f;return _0x1ca4ec[_0x41b21a('0x18af')](_0x41b21a('0xf15'),{'fields':_0x41b21a('0x113c'),'id':_0x25d58f['id']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x5164b2,_0x46ebe7){const _0x3129da=_0x31a92f;return _0x5164b2['resolve']('userProfileSection@get',{'fields':_0x3129da('0xe26'),'userProfileId':_0x46ebe7['getCurrentUser']()[_0x3129da('0xb86')],'sectionId':0x51a});}]},'authenticate':!![],'permissionId':0x51a,'bodyClass':'integrations'})[_0x31a92f('0x63f')](_0x31a92f('0x11f3'),{'url':_0x31a92f('0x1bd0'),'views':{'content@app':{'templateUrl':_0x986222,'controller':'ZohoAccountsController\x20as\x20vm'}},'resolve':{'zohoAccounts':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x147667,_0x150506){const _0x58982c=_0x31a92f;return _0x150506[_0x58982c('0x1ac6')](_0x58982c('0xa7c'))?_0x147667[_0x58982c('0x18af')](_0x58982c('0x58e'),{'fields':'createdAt,updatedAt,id,name,host,zone,clientId,clientSecret,code,refreshToken,serverUrl,description','limit':0xa,'offset':0x0}):_0x147667[_0x58982c('0x18af')](_0x58982c('0x17c4'),{'id':_0x150506[_0x58982c('0x26cd')]()[_0x58982c('0xb86')],'section':'ZohoAccounts','fields':_0x58982c('0x9c7'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x5f437f,_0x511c6a){const _0xecc02b=_0x31a92f;return _0x511c6a['hasRole'](_0xecc02b('0xa7c'))?null:_0x5f437f[_0xecc02b('0x18af')](_0xecc02b('0x697'),{'fields':_0xecc02b('0x686'),'id':_0x511c6a[_0xecc02b('0x26cd')]()[_0xecc02b('0xb86')]});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x36fe24,_0x29452b){const _0x478dfa=_0x31a92f;return _0x29452b[_0x478dfa('0x1ac6')](_0x478dfa('0xa7c'))?null:_0x36fe24[_0x478dfa('0x18af')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x29452b[_0x478dfa('0x26cd')]()[_0x478dfa('0xb86')],'sectionId':0x51b});}]},'authenticate':!![],'permissionId':0x51b,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0x1d10'),{'url':_0x31a92f('0x2233'),'params':{'zohoAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x267433,'controller':_0x31a92f('0x3a5')}},'resolve':{'zohoAccount':[_0x31a92f('0x1fbc'),'$stateParams',function(_0x363c3b,_0x560c76){const _0x144cdc=_0x31a92f;return _0x363c3b[_0x144cdc('0x18af')](_0x144cdc('0x58e'),{'fields':_0x144cdc('0x9c7'),'id':_0x560c76['id']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0xfbf0ae,_0x3ba548){const _0x2fb4f1=_0x31a92f;return _0xfbf0ae[_0x2fb4f1('0x18af')](_0x2fb4f1('0xaf'),{'fields':_0x2fb4f1('0xe26'),'userProfileId':_0x3ba548['getCurrentUser']()[_0x2fb4f1('0xb86')],'sectionId':0x51b});}]},'authenticate':!![],'permissionId':0x51b,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0x173d'),{'url':_0x31a92f('0x25fe'),'views':{'content@app':{'templateUrl':_0x1acc07,'controller':_0x31a92f('0x100e')}},'resolve':{'vtigerAccounts':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x2885b5,_0x23a48d){const _0x401082=_0x31a92f;return _0x23a48d[_0x401082('0x1ac6')](_0x401082('0xa7c'))?_0x2885b5[_0x401082('0x18af')](_0x401082('0x2655'),{'fields':'createdAt,updatedAt,id,name,description,username,accessKey,remoteUri,serverUrl','limit':0xa,'offset':0x0}):_0x2885b5['resolve'](_0x401082('0x17c4'),{'id':_0x23a48d[_0x401082('0x26cd')]()[_0x401082('0xb86')],'section':_0x401082('0xd9b'),'fields':'createdAt,updatedAt,id,name,description,username,accessKey,remoteUri,serverUrl','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x31a92f('0x21ef'),function(_0x191e03,_0x2ca219){const _0x4de1be=_0x31a92f;return _0x2ca219['hasRole'](_0x4de1be('0xa7c'))?null:_0x191e03[_0x4de1be('0x18af')](_0x4de1be('0x697'),{'fields':_0x4de1be('0x686'),'id':_0x2ca219[_0x4de1be('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x568599,_0x3d837c){const _0x134461=_0x31a92f;return _0x3d837c[_0x134461('0x1ac6')](_0x134461('0xa7c'))?null:_0x568599[_0x134461('0x18af')](_0x134461('0xaf'),{'fields':_0x134461('0xe26'),'userProfileId':_0x3d837c['getCurrentUser']()[_0x134461('0xb86')],'sectionId':0x51c});}]},'authenticate':!![],'permissionId':0x51c,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0x17af'),{'url':'/:id?tab','params':{'vtigerAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x2b8972,'controller':'VtigerAccountController\x20as\x20vm'}},'resolve':{'vtigerAccount':[_0x31a92f('0x1fbc'),_0x31a92f('0xf75'),function(_0xd4b35e,_0x2a021b){const _0x287229=_0x31a92f;return _0xd4b35e[_0x287229('0x18af')](_0x287229('0x2655'),{'fields':_0x287229('0x20c5'),'id':_0x2a021b['id']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x4bc85d,_0x1e421e){const _0x2e77e6=_0x31a92f;return _0x4bc85d[_0x2e77e6('0x18af')](_0x2e77e6('0xaf'),{'fields':_0x2e77e6('0xe26'),'userProfileId':_0x1e421e[_0x2e77e6('0x26cd')]()[_0x2e77e6('0xb86')],'sectionId':0x51c});}]},'authenticate':!![],'permissionId':0x51c,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0x280c'),{'url':_0x31a92f('0x1c2'),'views':{'content@app':{'templateUrl':_0x27b509,'controller':_0x31a92f('0x1284')}},'resolve':{'dynamics365Accounts':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x1c4f46,_0x5441d7){const _0x1c9539=_0x31a92f;return _0x5441d7[_0x1c9539('0x1ac6')]('admin')?_0x1c4f46[_0x1c9539('0x18af')](_0x1c9539('0x272c'),{'fields':'createdAt,updatedAt,id,name,username,password,remoteUri,tenantId,clientId,clientSecret,serverUrl,description','limit':0xa,'offset':0x0}):_0x1c4f46[_0x1c9539('0x18af')]('userProfile@getResources',{'id':_0x5441d7[_0x1c9539('0x26cd')]()['userProfileId'],'section':_0x1c9539('0x8c8'),'fields':_0x1c9539('0x161'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x24a0af,_0x2fcc4a){const _0x2d8861=_0x31a92f;return _0x2fcc4a['hasRole']('admin')?null:_0x24a0af[_0x2d8861('0x18af')](_0x2d8861('0x697'),{'fields':_0x2d8861('0x686'),'id':_0x2fcc4a[_0x2d8861('0x26cd')]()[_0x2d8861('0xb86')]});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x5a76d5,_0x4b61ea){const _0x32115b=_0x31a92f;return _0x4b61ea[_0x32115b('0x1ac6')](_0x32115b('0xa7c'))?null:_0x5a76d5['resolve']('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x4b61ea[_0x32115b('0x26cd')]()[_0x32115b('0xb86')],'sectionId':0x51d});}]},'authenticate':!![],'permissionId':0x51d,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0xb8a'),{'url':'/:id?tab','params':{'dynamics365Account':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x292cfe,'controller':_0x31a92f('0x9b5')}},'resolve':{'dynamics365Account':[_0x31a92f('0x1fbc'),_0x31a92f('0xf75'),function(_0x5a52c0,_0x3b7118){const _0x1fc62c=_0x31a92f;return _0x5a52c0[_0x1fc62c('0x18af')](_0x1fc62c('0x272c'),{'fields':_0x1fc62c('0x161'),'id':_0x3b7118['id']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x4e1c00,_0x51a672){const _0x4e6364=_0x31a92f;return _0x4e1c00[_0x4e6364('0x18af')](_0x4e6364('0xaf'),{'fields':_0x4e6364('0xe26'),'userProfileId':_0x51a672[_0x4e6364('0x26cd')]()[_0x4e6364('0xb86')],'sectionId':0x51d});}]},'authenticate':!![],'permissionId':0x51d,'bodyClass':'integrations'})['state']('app.integrations.servicenowAccounts',{'url':_0x31a92f('0xab7'),'views':{'content@app':{'templateUrl':_0x2720ba,'controller':_0x31a92f('0x1f1f')}},'resolve':{'servicenowAccounts':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x4f4ca7,_0x54526f){const _0x21064b=_0x31a92f;return _0x54526f[_0x21064b('0x1ac6')]('admin')?_0x4f4ca7[_0x21064b('0x18af')](_0x21064b('0x750'),{'fields':_0x21064b('0xe9'),'limit':0xa,'offset':0x0}):_0x4f4ca7[_0x21064b('0x18af')](_0x21064b('0x17c4'),{'id':_0x54526f[_0x21064b('0x26cd')]()[_0x21064b('0xb86')],'section':_0x21064b('0x4dd'),'fields':_0x21064b('0xe9'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x31a92f('0x21ef'),function(_0x567def,_0x421039){const _0x417bb4=_0x31a92f;return _0x421039[_0x417bb4('0x1ac6')](_0x417bb4('0xa7c'))?null:_0x567def['resolve'](_0x417bb4('0x697'),{'fields':_0x417bb4('0x686'),'id':_0x421039[_0x417bb4('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x5f00d6,_0x7eba23){const _0x27fae7=_0x31a92f;return _0x7eba23['hasRole'](_0x27fae7('0xa7c'))?null:_0x5f00d6['resolve'](_0x27fae7('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x7eba23[_0x27fae7('0x26cd')]()['userProfileId'],'sectionId':0x51e});}]},'authenticate':!![],'permissionId':0x51e,'bodyClass':'integrations'})[_0x31a92f('0x63f')](_0x31a92f('0x62e'),{'url':'/:id?tab','params':{'servicenowAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x55025f,'controller':_0x31a92f('0x14e4')}},'resolve':{'servicenowAccount':[_0x31a92f('0x1fbc'),_0x31a92f('0xf75'),function(_0x12bd54,_0x89960f){const _0x1cbebc=_0x31a92f;return _0x12bd54[_0x1cbebc('0x18af')](_0x1cbebc('0x750'),{'fields':_0x1cbebc('0xe9'),'id':_0x89960f['id']});}],'userProfileSection':[_0x31a92f('0x1fbc'),'Auth',function(_0xd5f213,_0x3f2cbf){const _0x30a881=_0x31a92f;return _0xd5f213['resolve'](_0x30a881('0xaf'),{'fields':_0x30a881('0xe26'),'userProfileId':_0x3f2cbf[_0x30a881('0x26cd')]()[_0x30a881('0xb86')],'sectionId':0x51e});}]},'authenticate':!![],'permissionId':0x51e,'bodyClass':_0x31a92f('0x1ba0')})[_0x31a92f('0x63f')](_0x31a92f('0x1da7'),{'url':_0x31a92f('0x6b'),'views':{'content@app':{'templateUrl':_0x5ba063,'controller':_0x31a92f('0x1a95')}},'resolve':{'freshsalesAccounts':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x120d73,_0xbd4a4a){const _0x5d5a27=_0x31a92f;return _0xbd4a4a['hasRole'](_0x5d5a27('0xa7c'))?_0x120d73['resolve'](_0x5d5a27('0x1b30'),{'fields':'createdAt,updatedAt,id,name,username,remoteUri,apiKey,serverUrl,description','limit':0xa,'offset':0x0}):_0x120d73['resolve'](_0x5d5a27('0x17c4'),{'id':_0xbd4a4a[_0x5d5a27('0x26cd')]()[_0x5d5a27('0xb86')],'section':_0x5d5a27('0x16b7'),'fields':_0x5d5a27('0x7d6'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x11b788,_0x60f52){const _0x3ad2e0=_0x31a92f;return _0x60f52[_0x3ad2e0('0x1ac6')]('admin')?null:_0x11b788['resolve']('userProfile@get',{'fields':_0x3ad2e0('0x686'),'id':_0x60f52[_0x3ad2e0('0x26cd')]()[_0x3ad2e0('0xb86')]});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x43b8f5,_0x18ec15){const _0xabc27=_0x31a92f;return _0x18ec15[_0xabc27('0x1ac6')]('admin')?null:_0x43b8f5['resolve'](_0xabc27('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x18ec15['getCurrentUser']()[_0xabc27('0xb86')],'sectionId':0x518});}]},'authenticate':!![],'permissionId':0x518,'bodyClass':'integrations'})[_0x31a92f('0x63f')](_0x31a92f('0x182f'),{'url':_0x31a92f('0x2233'),'params':{'freshsalesAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x2f3eab,'controller':'FreshsalesAccountController\x20as\x20vm'}},'resolve':{'freshsalesAccount':[_0x31a92f('0x1fbc'),_0x31a92f('0xf75'),function(_0x4c5a05,_0x4be804){const _0x31bafd=_0x31a92f;return _0x4c5a05['resolve'](_0x31bafd('0x1b30'),{'fields':_0x31bafd('0x7d6'),'id':_0x4be804['id']});}],'userProfileSection':[_0x31a92f('0x1fbc'),_0x31a92f('0x21ef'),function(_0x4e0708,_0x3fccb3){const _0x2eba29=_0x31a92f;return _0x4e0708[_0x2eba29('0x18af')](_0x2eba29('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x3fccb3[_0x2eba29('0x26cd')]()[_0x2eba29('0xb86')],'sectionId':0x518});}]},'authenticate':!![],'permissionId':0x518,'bodyClass':_0x31a92f('0x1ba0')}),_0x14eff3[_0x31a92f('0x95e')]('app/main/apps/integrations');}angular[_0x36e6f4('0x896')](_0x36e6f4('0x5f2'),['ngCsv',_0x36e6f4('0xfb6'),'md.data.table',_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),'mwFormUtils',_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411')])[_0x36e6f4('0xe11')](_0xf47e83)[_0x36e6f4('0x75e')]('CreateOrEditDeskAccountDialogController',_0x539d72)[_0x36e6f4('0x75e')](_0x36e6f4('0x2235'),_0x4bef10)[_0x36e6f4('0x75e')](_0x36e6f4('0x183'),_0x384abf)[_0x36e6f4('0x75e')](_0x36e6f4('0x1bbb'),_0x2e957d)[_0x36e6f4('0x75e')](_0x36e6f4('0x59c'),_0x4ee1d1)['controller']('DeskAccountController',_0x1179be)[_0x36e6f4('0x75e')]('CreateOrEditDynamics365AccountDialogController',_0x3ea028)[_0x36e6f4('0x75e')](_0x36e6f4('0x1791'),_0x23ddc5)[_0x36e6f4('0x75e')](_0x36e6f4('0x1c50'),_0x6e1e7f)[_0x36e6f4('0x75e')](_0x36e6f4('0x1455'),_0x40a601)[_0x36e6f4('0x75e')](_0x36e6f4('0xbd1'),_0x48776e)[_0x36e6f4('0x75e')](_0x36e6f4('0x21f0'),_0x596ed4)[_0x36e6f4('0x75e')](_0x36e6f4('0x1cf9'),_0x5da993)[_0x36e6f4('0x75e')](_0x36e6f4('0x17d0'),_0x400992)['controller'](_0x36e6f4('0x4b2'),_0x45d522)[_0x36e6f4('0x75e')](_0x36e6f4('0x10e4'),_0x388d47)['controller'](_0x36e6f4('0x449'),_0x166d08)[_0x36e6f4('0x75e')](_0x36e6f4('0x15c3'),_0xa0e81c)[_0x36e6f4('0x75e')](_0x36e6f4('0x2485'),_0x46784a)[_0x36e6f4('0x75e')](_0x36e6f4('0x3c7'),_0x160f15)[_0x36e6f4('0x75e')](_0x36e6f4('0x1cdf'),_0x1b3c6c)[_0x36e6f4('0x75e')](_0x36e6f4('0x14b7'),_0x54afa6)[_0x36e6f4('0x75e')](_0x36e6f4('0x1474'),_0x4ac1c6)[_0x36e6f4('0x75e')](_0x36e6f4('0x1571'),_0x4c68be)[_0x36e6f4('0x75e')](_0x36e6f4('0x1fac'),_0x2465cd)[_0x36e6f4('0x75e')]('SalesforceAccountConfigurationsController',_0x5046be)[_0x36e6f4('0x75e')]('CreateOrEditSalesforceConfigurationDialogController',_0x359776)[_0x36e6f4('0x75e')](_0x36e6f4('0x21ec'),_0x4d1893)['controller'](_0x36e6f4('0xffc'),_0x366029)['controller'](_0x36e6f4('0x1028'),_0x3cf41f)[_0x36e6f4('0x75e')](_0x36e6f4('0xfcb'),_0x11ffe6)[_0x36e6f4('0x75e')]('ServicenowAccountConfigurationsController',_0x4dc42a)['controller'](_0x36e6f4('0x6d0'),_0x422c10)[_0x36e6f4('0x75e')](_0x36e6f4('0x3d6'),_0x18e34d)[_0x36e6f4('0x75e')]('ServicenowAccountController',_0x3c9089)[_0x36e6f4('0x75e')](_0x36e6f4('0x10d8'),_0x420c14)[_0x36e6f4('0x75e')](_0x36e6f4('0x1e11'),_0x441c28)['controller'](_0x36e6f4('0x232a'),_0xb2ef07)[_0x36e6f4('0x75e')](_0x36e6f4('0x2195'),_0x31167b)['controller'](_0x36e6f4('0x2545'),_0xabb42d)['controller']('SugarcrmAccountController',_0x409c8d)[_0x36e6f4('0x75e')](_0x36e6f4('0x1155'),_0x2c91dd)[_0x36e6f4('0x75e')](_0x36e6f4('0x23f5'),_0x2e70a7)['controller'](_0x36e6f4('0x970'),_0x6ad8f5)[_0x36e6f4('0x75e')](_0x36e6f4('0x1d31'),_0x4a36fc)['controller'](_0x36e6f4('0x1d4c'),_0x288b23)['controller'](_0x36e6f4('0x4f1'),_0x3d6fd9)['controller'](_0x36e6f4('0x37e'),_0x5ba5ab)['controller']('CreateOrEditZendeskAccountDialogController',_0x576640)[_0x36e6f4('0x75e')](_0x36e6f4('0x1d87'),_0x4d1df7)[_0x36e6f4('0x75e')](_0x36e6f4('0x4e6'),_0x5c516e)[_0x36e6f4('0x75e')]('ZendeskAccountConfigurationsController',_0x5eab8b)[_0x36e6f4('0x75e')](_0x36e6f4('0x1ad8'),_0x5b3894)[_0x36e6f4('0x75e')]('ZendeskAccountsController',_0x266617)[_0x36e6f4('0x75e')](_0x36e6f4('0x1c53'),_0xa38844)[_0x36e6f4('0x75e')]('ZohoAccountConfigurationsController',_0xae9aed)[_0x36e6f4('0x75e')](_0x36e6f4('0x118c'),_0xc8e80)[_0x36e6f4('0x75e')](_0x36e6f4('0xcf5'),_0x359da7)[_0x36e6f4('0x75e')](_0x36e6f4('0x81'),_0x3a85ba)['controller'](_0x36e6f4('0x2759'),_0x25e88f);const _0x295f68=_0x2734b2['p']+_0x36e6f4('0x1544'),_0x5846d6=_0x2734b2['p']+_0x36e6f4('0x18a8'),_0x2e71a7=_0x2734b2['p']+_0x36e6f4('0x283b');_0x18ba39[_0x36e6f4('0x1294')]=['$document','$mdDialog','$state','license',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3')];function _0x18ba39(_0x117fce,_0x59d718,_0x3b61b0,_0x271677,_0x38602b,_0xa1677b){const _0x270931=_0x36e6f4,_0x1fca65=this;_0x1fca65[_0x270931('0x5c9')]=_0x271677||{},_0x1fca65['agents']=0x0,_0x1fca65[_0x270931('0x21f6')]=0x0,_0x1fca65['telephones']=0x0,_0x1fca65[_0x270931('0x2371')]=[{'name':_0x270931('0x21da'),'icon':_0x270931('0x1473')},{'name':_0x270931('0xde2'),'icon':_0x270931('0xc49')},{'name':_0x270931('0x1bfa'),'icon':'icon-email'},{'name':'messaging','icon':_0x270931('0x1392')},{'name':_0x270931('0x1fc7'),'icon':_0x270931('0x23fb')},{'name':'openchannel','icon':_0x270931('0x2052')},{'name':_0x270931('0x116e'),'icon':_0x270931('0x19b9')}],_0x1fca65[_0x270931('0x1219')]=[{'name':'cm','icon':'icon-account-circle'},{'name':_0x270931('0x21ee'),'icon':_0x270931('0x150b')},{'name':'jscripty','icon':_0x270931('0x1692')}],_0x1fca65[_0x270931('0x1187')]=[{'name':'webrtc','icon':'icon-server-plus'},{'name':_0x270931('0x1e5e'),'icon':'icon-fish'},{'name':_0x270931('0x2853'),'icon':_0x270931('0x1a65')},{'name':_0x270931('0x158'),'icon':_0x270931('0x2569')},{'name':'ai','icon':_0x270931('0x1dc0')}],_0x1fca65[_0x270931('0x2000')]=[{'name':'callysquare','icon':_0x270931('0x641'),'restart':!![],'label':_0x270931('0x2371'),'enabled':'voice'},{'name':_0x270931('0x1fe9'),'icon':_0x270931('0x1e2c'),'restart':![],'label':_0x270931('0x2000'),'enabled':_0x270931('0xde2')}],_0x1fca65[_0x270931('0x8e0')]=[{'name':'update','icon':_0x270931('0x8fd')}],_0xa1677b[_0x270931('0x557')]['get']({'fields':'id','role':_0x270931('0x1eff'),'online':!![]})[_0x270931('0xa44')][_0x270931('0x1166')](function(_0x572716){const _0xc4ab38=_0x270931;return _0x1fca65['agents']=_0x572716&&_0x572716['count']?_0x572716[_0xc4ab38('0x240f')]:0x0,_0xa1677b['user'][_0xc4ab38('0xd83')]({'fields':'id','role':_0xc4ab38('0x603')})[_0xc4ab38('0xa44')];})[_0x270931('0x1166')](function(_0x3b1537){const _0x1c504f=_0x270931;return _0x1fca65[_0x1c504f('0x21f6')]=_0x3b1537&&_0x3b1537[_0x1c504f('0x240f')]?_0x3b1537['count']:0x0,_0xa1677b[_0x1c504f('0x557')]['get']({'fields':'id','role':_0x1c504f('0x887')})['$promise'];})[_0x270931('0x1166')](function(_0x5c6bdc){const _0x57e28e=_0x270931;_0x1fca65[_0x57e28e('0x20f9')]=_0x5c6bdc&&_0x5c6bdc[_0x57e28e('0x240f')]?_0x5c6bdc['count']:0x0;})[_0x270931('0x1a80')](function(_0x589be2){console['log'](_0x589be2);});function _0x3da989(_0x1cb39d){const _0x40da5c=_0x270931;_0x59d718[_0x40da5c('0x1f80')]({'controller':_0x40da5c('0x14f1'),'controllerAs':'vm','templateUrl':_0x5846d6,'parent':angular[_0x40da5c('0x1194')](_0x117fce[_0x40da5c('0x8d2')]),'targetEvent':_0x1cb39d,'clickOutsideToClose':!![],'locals':{'license':_0x271677}});}function _0x1f4b62(_0x1a964f){const _0x1cbbe5=_0x270931;_0x59d718[_0x1cbbe5('0x1f80')]({'controller':_0x1cbbe5('0x108a'),'controllerAs':'vm','templateUrl':_0x2e71a7,'parent':angular['element'](_0x117fce['body']),'targetEvent':_0x1a964f,'clickOutsideToClose':!![],'locals':{'license':_0x271677,'channels':_0x1fca65[_0x1cbbe5('0x2371')],'modules':_0x1fca65[_0x1cbbe5('0x1219')],'addons':_0x1fca65[_0x1cbbe5('0x1187')],'sessions':_0x1fca65[_0x1cbbe5('0x2000')],'others':_0x1fca65[_0x1cbbe5('0x8e0')]}});}function _0x372aa3(){const _0x1a5e50=_0x270931;_0x3b61b0['go'](_0x1a5e50('0xb2'),{'tab':0x1});}_0x1fca65[_0x270931('0x2388')]=_0x1f4b62,_0x1fca65[_0x270931('0x2605')]=_0x3da989,_0x1fca65[_0x270931('0x1c36')]=_0x372aa3;}const _0x4e1aae=_0x18ba39;_0x136f1e['$inject']=[_0x36e6f4('0x265d'),'toasty',_0x36e6f4('0x5c9'),'channels',_0x36e6f4('0x1219'),'addons',_0x36e6f4('0x2000'),'others',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x586')];function _0x136f1e(_0x8ea158,_0x275957,_0x374ad5,_0x5009b7,_0x4d7960,_0x3913af,_0x2a9838,_0x429c78,_0xa48760,_0x186f12,_0x2a76bf){const _0x44022b=_0x36e6f4,_0x485fe8=this;_0x485fe8['errors']=[],_0x485fe8[_0x44022b('0x557')]=_0x186f12[_0x44022b('0x26cd')](),_0x485fe8[_0x44022b('0x5c9')]=angular[_0x44022b('0x225f')](_0x374ad5),_0x485fe8[_0x44022b('0x2371')]=_0x5009b7,_0x485fe8[_0x44022b('0x1219')]=_0x4d7960,_0x485fe8[_0x44022b('0x1187')]=_0x3913af,_0x485fe8[_0x44022b('0x2000')]=_0x2a9838,_0x485fe8[_0x44022b('0x8e0')]=_0x429c78,_0x485fe8[_0x44022b('0x5c9')]['name']=_0x485fe8[_0x44022b('0x557')]['fullname'],_0x485fe8['license']['email']=_0x485fe8['user'][_0x44022b('0x66f')],_0x485fe8[_0x44022b('0x23c3')]=_0x188e2a,_0x485fe8[_0x44022b('0x24a0')]=_0x555ed2;function _0x188e2a(){const _0x31ab84=_0x44022b;_0x485fe8[_0x31ab84('0x61a')]=[],_0x485fe8[_0x31ab84('0x916')]=_0x31ab84('0xbc2');for(const _0x21a510 in _0x485fe8[_0x31ab84('0x5c9')]){typeof _0x485fe8['license'][_0x21a510]!==_0x31ab84('0x1048')&&!_0x2cfb05()[_0x31ab84('0x1257')](['$promise',_0x31ab84('0xfcd')],_0x21a510)&&(_0x374ad5[_0x21a510]===_0x485fe8[_0x31ab84('0x5c9')][_0x21a510]?_0x485fe8[_0x31ab84('0x916')]+='|'+_0x21a510+'|'+(_0x374ad5[_0x21a510]!==undefined?_0x374ad5[_0x21a510]:'')+'|'+_0x485fe8['license'][_0x21a510]+'|\x0a':_0x485fe8[_0x31ab84('0x916')]+='|'+_0x21a510+'|{color:red}'+(_0x374ad5[_0x21a510]!==undefined?_0x374ad5[_0x21a510]:'')+_0x31ab84('0x115b')+_0x485fe8['license'][_0x21a510]+_0x31ab84('0xe61'));}_0xa48760['jira'][_0x31ab84('0x9cc')]({'key':_0x31ab84('0x425'),'summary':_0x31ab84('0x12d6'),'description':_0x485fe8['table'],'issuetype':_0x31ab84('0xce8')})[_0x31ab84('0xa44')][_0x31ab84('0x1166')](function(){const _0x35fc0c=_0x31ab84;_0x275957[_0x35fc0c('0x103b')]({'title':_0x35fc0c('0xad6'),'msg':_0x2a76bf[_0x35fc0c('0x25cc')](_0x35fc0c('0x855')),'timeout':0x3a98}),_0x555ed2();})[_0x31ab84('0x1a80')](function(_0x1041f7){const _0x47b859=_0x31ab84;console[_0x47b859('0xfc9')](_0x1041f7),_0x485fe8[_0x47b859('0x61a')]=[{'message':_0x2a76bf[_0x47b859('0x25cc')](_0x47b859('0x7d8')),'type':'api.jira'}];});}function _0x555ed2(){_0x8ea158['hide']();}}const _0x5e4fbc=_0x136f1e;_0x47afc0['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x5c9'),_0x36e6f4('0x19e3')];function _0x47afc0(_0x46f0dc,_0x41576d,_0x417162,_0x5e8ae9){const _0x2f6f87=_0x36e6f4,_0x1b4af2=this;_0x1b4af2[_0x2f6f87('0x61a')]=[],_0x1b4af2['license']=angular[_0x2f6f87('0x225f')](_0x417162),_0x1b4af2['licenseKey'],_0x1b4af2['updateLicense']=_0x27c268,_0x1b4af2[_0x2f6f87('0x24a0')]=_0x2dd244;function _0x27c268(){const _0x110488=_0x2f6f87;return _0x5e8ae9[_0x110488('0x5c9')]['update']({'id':0x1,'key':_0x1b4af2['licenseKey']})[_0x110488('0xa44')][_0x110488('0x1166')](function(_0x19bc9e){const _0x36e6b5=_0x110488;_0x19bc9e&&(_0x19bc9e[_0x36e6b5('0x16a3')]?_0x41576d[_0x36e6b5('0xfc9')]({'title':_0x36e6b5('0x720'),'msg':_0x36e6b5('0x29d')}):_0x41576d[_0x36e6b5('0x103b')]({'title':_0x36e6b5('0x11ea'),'msg':_0x36e6b5('0x564')}));})[_0x110488('0x1a80')](function(_0x56d45b){const _0x210c21=_0x110488;_0x41576d[_0x210c21('0xfc9')]({'title':_0x56d45b[_0x210c21('0x52d')]?_0x210c21('0x1e21')+_0x56d45b[_0x210c21('0x52d')]+_0x210c21('0x11e1')+_0x56d45b[_0x210c21('0xe1b')]:_0x210c21('0x14ae'),'msg':_0x56d45b[_0x210c21('0x25f4')]?JSON[_0x210c21('0xbac')](_0x56d45b[_0x210c21('0x25f4')]):_0x56d45b[_0x210c21('0x1586')]()});});}function _0x2dd244(){const _0x3a0885=_0x2f6f87;_0x46f0dc[_0x3a0885('0x1197')]();}}const _0x4fa0c9=_0x47afc0;_0x1a158a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x1a158a(_0x335cf6){const _0x4d84ab=_0x36e6f4;_0x335cf6[_0x4d84ab('0x63f')](_0x4d84ab('0x23b5'),{'url':_0x4d84ab('0xc3a'),'views':{'content@app':{'templateUrl':_0x295f68,'controller':'LicenseController\x20as\x20vm'}},'authenticate':!![],'permissionId':0x578,'bodyClass':_0x4d84ab('0x2017')});}angular['module'](_0x36e6f4('0x23b5'),[])[_0x36e6f4('0xe11')](_0x1a158a)[_0x36e6f4('0x75e')](_0x36e6f4('0x1d7e'),_0x4e1aae)[_0x36e6f4('0x75e')](_0x36e6f4('0x108a'),_0x5e4fbc)['controller']('UpdateLicenseDialogController',_0x4fa0c9);const _0x5c86f7=_0x2734b2['p']+_0x36e6f4('0x2593');_0x1cfbf9[_0x36e6f4('0x1294')]=['$scope','$interval',_0x36e6f4('0x265d'),'$state','system',_0x36e6f4('0x558'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3')];function _0x1cfbf9(_0x38e19e,_0x1ef58f,_0x57f988,_0x16c219,_0x3e0ffc,_0x48e042,_0x2d8481,_0x3bfc64){const _0x2d65d1=_0x36e6f4,_0x2694ac=this;let _0x4c7fff=null;_0x2694ac[_0x2d65d1('0x1c2b')]=_0x3e0ffc||{},_0x2694ac[_0x2d65d1('0x558')]=_0x48e042?_0x48e042['rows']:[],_0x2694ac[_0x2d65d1('0x4c7')]=0x7,_0x2694ac[_0x2d65d1('0x2669')]=_0x16c219[_0x2d65d1('0x23f')][_0x2d65d1('0xbe3')]||0x0,_0x2694ac[_0x2d65d1('0x83e')]=_0xc0a2a5,_0x2694ac['getProcesses']=_0x6043db,_0x2694ac[_0x2d65d1('0x5d0')]=_0x44b4ab,_0x2694ac['updateProcess']=_0x1ba6a3;function _0x44b4ab(){const _0x593b8b=_0x2d65d1;_0x1ef58f[_0x593b8b('0x3f')](_0x4c7fff),_0x4c7fff=null;}function _0x1ba6a3(_0x4f8211,_0x2257d3,_0x42fe31){const _0x4df500=_0x2d65d1,_0x6f22a4=_0x57f988[_0x4df500('0x1d26')]()[_0x4df500('0xcdc')](_0x4df500('0x208d')+_0x2257d3+'?')[_0x4df500('0x2077')]('The\x20status\x20will\x20be\x20changed\x20to:\x20'+_0x42fe31[_0x4df500('0x1387')]())[_0x4df500('0x8e8')]('Lucky\x20day')[_0x4df500('0x203b')](_0x4f8211)['ok']('Ok')[_0x4df500('0x3f')](_0x4df500('0x497'));_0x57f988['show'](_0x6f22a4)[_0x4df500('0x1166')](function(){const _0x1dc609=_0x4df500;return _0x3bfc64['pm2'][_0x1dc609('0x1449')]({'id':_0x2257d3,'status':_0x42fe31});})['then'](function(){const _0x15719f=_0x4df500;_0x1ef58f(_0x2694ac[_0x15719f('0x1ee')],0x3e8,0x1);})[_0x4df500('0x1166')](function(){const _0x8a2beb=_0x4df500;_0x2d8481[_0x8a2beb('0x103b')]({'title':_0x8a2beb('0x1b5b'),'msg':_0x8a2beb('0x6f0')+_0x42fe31});});}function _0xc0a2a5(){const _0x5107e4=_0x2d65d1;return _0x3bfc64[_0x5107e4('0x1c2b')]['get']()['$promise'][_0x5107e4('0x1166')](function(_0xc31515){const _0x113b87=_0x5107e4;_0x2cfb05()[_0x113b87('0xcc3')](_0x2694ac[_0x113b87('0x1c2b')],_0xc31515);})[_0x5107e4('0x1a80')](_0x2694ac[_0x5107e4('0x5d0')]);}function _0x6043db(){const _0x11c300=_0x2d65d1;return _0x3bfc64[_0x11c300('0x271e')][_0x11c300('0xd83')]()[_0x11c300('0xa44')][_0x11c300('0x1166')](function(_0x118519){const _0xa48c7a=_0x11c300;_0x2cfb05()['merge'](_0x2694ac[_0xa48c7a('0x558')],_0x118519?_0x118519['rows']:[]);})['catch'](_0x2694ac['cancelInterval']);}_0x4c7fff=_0x1ef58f(_0x2694ac['getInfo'],0x1388),_0x38e19e[_0x2d65d1('0x3d2')](_0x2d65d1('0x1c3f'),function(){const _0x574b9a=_0x2d65d1;_0x2694ac[_0x574b9a('0x5d0')]();});}const _0xda5bd5=_0x1cfbf9;_0x487620[_0x36e6f4('0x1294')]=['$stateProvider'];function _0x487620(_0x25624c){const _0x2ed974=_0x36e6f4;_0x25624c['state'](_0x2ed974('0xb2'),{'url':_0x2ed974('0x274c'),'views':{'content@app':{'templateUrl':_0x5c86f7,'controller':'SystemController\x20as\x20vm'}},'resolve':{'system':[_0x2ed974('0x1fbc'),function(_0x307c5e){const _0x3114d5=_0x2ed974;return _0x307c5e[_0x3114d5('0x18af')](_0x3114d5('0x123c'));}],'processes':[_0x2ed974('0x1fbc'),function(_0x418670){const _0x3eac9a=_0x2ed974;return _0x418670[_0x3eac9a('0x18af')]('pm2@get');}]},'authenticate':!![],'permissionId':0x578,'bodyClass':_0x2ed974('0x2017')});}angular[_0x36e6f4('0x896')](_0x36e6f4('0xb2'),[])[_0x36e6f4('0xe11')](_0x487620)[_0x36e6f4('0x75e')](_0x36e6f4('0xb6c'),_0xda5bd5);const _0x198041=_0x2734b2['p']+_0x36e6f4('0x56f');_0x291a75['$inject']=['$mdDialog',_0x36e6f4('0x10eb'),_0x36e6f4('0x1566'),_0x36e6f4('0x8da'),'api'];function _0x291a75(_0x5db8e6,_0x38abee,_0x19e743,_0x480eb5,_0x50cf61){const _0x4431ec=_0x36e6f4,_0x29dce4=this;_0x29dce4[_0x4431ec('0xcdc')]=_0x4431ec('0x210f'),_0x29dce4[_0x4431ec('0xd40')]=0x0,_0x29dce4[_0x4431ec('0xdab')]=!![],_0x29dce4[_0x4431ec('0x1eed')]=_0x4431ec('0x2217'),_0x29dce4['success']=!![],_0x29dce4[_0x4431ec('0x277c')]=_0x38abee(function(){const _0x25c08f=_0x4431ec;_0x29dce4['progress']<0x5a&&(_0x29dce4[_0x25c08f('0xd40')]+=0x1);},0x3e8),_0x50cf61[_0x4431ec('0x92e')]['fetch']()[_0x4431ec('0xa44')]['then'](function(_0x1e90c2){const _0x19ff96=_0x4431ec;return _0x29dce4[_0x19ff96('0x1eed')]=_0x1e90c2[_0x19ff96('0x1eed')]+'...',_0x50cf61['version']['reset']()['$promise'];})['then'](function(_0x2cd7a9){const _0xcf6709=_0x4431ec;return _0x29dce4[_0xcf6709('0x1eed')]=_0x2cd7a9[_0xcf6709('0x1eed')]+_0xcf6709('0x2827'),_0x50cf61[_0xcf6709('0x92e')][_0xcf6709('0x2473')]()[_0xcf6709('0xa44')];})[_0x4431ec('0x1166')](function(_0x4de9e3){const _0x49acc8=_0x4431ec;return _0x29dce4[_0x49acc8('0x1eed')]=_0x4de9e3['output']+_0x49acc8('0x2827'),_0x50cf61[_0x49acc8('0x92e')][_0x49acc8('0x24ab')]()[_0x49acc8('0xa44')];})[_0x4431ec('0x1166')](function(_0x5e4cfc){const _0x2e3b2f=_0x4431ec;return _0x29dce4[_0x2e3b2f('0x1eed')]=_0x5e4cfc[_0x2e3b2f('0x1eed')]+_0x2e3b2f('0x2827'),_0x50cf61[_0x2e3b2f('0x92e')]['restart']()['$promise'];})['then'](function(){const _0x5fa782=_0x4431ec;_0x29dce4['output']=_0x5fa782('0x1af5'),_0x480eb5(function(){const _0x16ac7c=_0x5fa782;_0x29dce4[_0x16ac7c('0xe0a')]();},0x7530);})['catch'](function(_0x4ca4e3){const _0x41a39c=_0x4431ec;_0x29dce4['success']=![],_0x29dce4[_0x41a39c('0xe0a')](),_0x29dce4[_0x41a39c('0x1eed')]=JSON[_0x41a39c('0xbac')](_0x4ca4e3);});function _0x472782(){const _0x3c8d2a=_0x4431ec;angular[_0x3c8d2a('0x1e3f')](_0x29dce4['interval'])&&(_0x38abee[_0x3c8d2a('0x3f')](_0x29dce4['interval']),_0x29dce4[_0x3c8d2a('0x277c')]=undefined),_0x29dce4['progress']=0x64,_0x29dce4[_0x3c8d2a('0xdab')]=![];}function _0x244acb(){const _0x33fb06=_0x4431ec;_0x19e743[_0x33fb06('0x246b')][_0x33fb06('0x12b0')]();}function _0x26ccb2(){const _0x37cbb2=_0x4431ec;_0x5db8e6[_0x37cbb2('0x1197')]();}_0x29dce4[_0x4431ec('0x24a0')]=_0x26ccb2,_0x29dce4[_0x4431ec('0x12b0')]=_0x244acb,_0x29dce4[_0x4431ec('0xe0a')]=_0x472782;}const _0x353d75=_0x291a75,_0x23a567=_0x2734b2['p']+'src/js/modules/main/apps/settings/views/updates/update/dialog.html/dialog.html';_0x477fd8['$inject']=[_0x36e6f4('0x265d'),_0x36e6f4('0x10eb'),_0x36e6f4('0x1c90'),_0x36e6f4('0x92e')];function _0x477fd8(_0x301200,_0xe410c8,_0x4147a0,_0x497f06){const _0x2fa067=_0x36e6f4,_0x374051=this;_0x374051[_0x2fa067('0x92e')]=_0x497f06||{};function _0xa7f626(_0x439d8c){const _0x3dd1e4=_0x2fa067,_0x47dd49=_0x301200[_0x3dd1e4('0x1d26')]()['title']('Would\x20you\x20like\x20to\x20update\x20your\x20system?')[_0x3dd1e4('0xf3c')]('The\x20system\x20request\x20time\x20for\x20the\x20update\x20should\x20be\x20below\x201\x20minute.

Do\x20you\x20agree\x20the\x20terms\x20of\x20this\x20End\x20User\x20License\x20Agreement?')['ariaLabel']('')[_0x3dd1e4('0x203b')](_0x439d8c)['clickOutsideToClose'](!![])[_0x3dd1e4('0x5f6')](angular[_0x3dd1e4('0x1194')](_0x4147a0[_0x3dd1e4('0x8d2')]))['ok'](_0x3dd1e4('0xf0a'))[_0x3dd1e4('0x3f')](_0x3dd1e4('0x7e9'));_0x301200[_0x3dd1e4('0x1f80')](_0x47dd49)[_0x3dd1e4('0x1166')](function(){const _0x360a18=_0x3dd1e4;_0x301200[_0x360a18('0x1f80')]({'controller':'UpdateDialogController','controllerAs':'vm','templateUrl':_0x23a567,'parent':angular[_0x360a18('0x1194')](_0x4147a0[_0x360a18('0x8d2')]),'targetEvent':_0x439d8c,'clickOutsideToClose':![]});});}_0x374051['updateConfirm']=_0xa7f626;}const _0x3bf2f6=_0x477fd8;_0x1edff5[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x1edff5(_0x1197a8){const _0x5646db=_0x36e6f4;_0x1197a8['state'](_0x5646db('0xf45'),{'url':_0x5646db('0xb7c'),'views':{'content@app':{'templateUrl':_0x198041,'controller':_0x5646db('0x1bed')}},'resolve':{'version':[_0x5646db('0x1fbc'),function(_0x246d76){const _0x13a988=_0x5646db;return _0x246d76[_0x13a988('0x18af')](_0x13a988('0x42f'),{'latest':!![]});}],'userProfile':[_0x5646db('0x1fbc'),_0x5646db('0x21ef'),function(_0x12acba,_0xa3f217){const _0x576ffd=_0x5646db;return _0x12acba[_0x576ffd('0x18af')]('userProfile@get',{'fields':_0x576ffd('0x686'),'id':_0xa3f217[_0x576ffd('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x5646db('0x1fbc'),'Auth',function(_0x438b1c,_0x36e01d){const _0x4ed003=_0x5646db;return _0x438b1c[_0x4ed003('0x18af')](_0x4ed003('0xaf'),{'fields':_0x4ed003('0xe26'),'userProfileId':_0x36e01d[_0x4ed003('0x26cd')]()[_0x4ed003('0xb86')],'sectionId':0x578});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':'settings'});}angular['module'](_0x36e6f4('0xf45'),[])[_0x36e6f4('0xe11')](_0x1edff5)[_0x36e6f4('0x75e')]('UpdateDialogController',_0x353d75)[_0x36e6f4('0x75e')](_0x36e6f4('0x201e'),_0x3bf2f6);const _0x266dc5=_0x2734b2['p']+_0x36e6f4('0x1572'),_0xc8551d=_0x2734b2['p']+'src/js/modules/main/apps/settings/views/smtps/smtps.html/smtps.html',_0x3ab858=_0x2734b2['p']+_0x36e6f4('0x14be'),_0x1c3de1=_0x2734b2['p']+_0x36e6f4('0xf00'),_0x43d312=_0x2734b2['p']+_0x36e6f4('0x28c8'),_0x5969f0=_0x2734b2['p']+_0x36e6f4('0xe55');_0x3201f5['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x1913'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a')];function _0x3201f5(_0x4b1478,_0x8b2c80,_0x19cc1f,_0x33c679,_0x3bebb5,_0x577778,_0x47ca58,_0x583220,_0x20a3e6,_0x3d9f70,_0xd090fb,_0x5b7b8a,_0x2c5434,_0x196c97,_0x5bdd21){const _0x569e86=_0x36e6f4,_0xe4604=this;_0xe4604[_0x569e86('0x5c9')]=_0x196c97,_0xe4604[_0x569e86('0xf8a')]=_0x5bdd21,_0xe4604[_0x569e86('0x98')]=_0x2c5434[_0x569e86('0x26cd')](),_0xe4604[_0x569e86('0x1913')]=_0x20a3e6||{'count':0x0,'rows':[]},_0xe4604[_0x569e86('0x916')]='cloudProviders',_0xe4604['listOrder']='',_0xe4604[_0x569e86('0x104c')]=null,_0xe4604[_0x569e86('0xa95')]=[],_0xe4604[_0x569e86('0x2218')]={'fields':_0x569e86('0x7f3'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0xe4604[_0x569e86('0x2188')]=_0x2cfb05()[_0x569e86('0x155c')]([{'option':_0x569e86('0x847'),'value':'\x27AmazonAWS\x27'}],function(_0x23e408){const _0x2f86dc=_0x569e86;return _0x2cfb05()[_0x2f86dc('0xf3')](_0x23e408[_0x2f86dc('0x18e0')],new RegExp('\x27','g'),'');}),_0xe4604[_0x569e86('0x1f8e')]=_0x1b9a5f,_0xe4604['deleteconfirm']=_0x593532,_0xe4604[_0x569e86('0x103b')]=_0x32386c,_0xe4604[_0x569e86('0x26eb')]=_0x131446,_0xe4604[_0x569e86('0x1bd8')]=_0x5d299a,_0xe4604['deleteCloudProvider']=_0x1bcbd9,_0xe4604[_0x569e86('0xfa2')]=_0xd5e438,_0xe4604[_0x569e86('0x2763')]=_0x1be8a3,_0xe4604[_0x569e86('0x21e1')]=_0x5d878a,_0xe4604[_0x569e86('0x928')]=_0xaed765;function _0x1b9a5f(_0x1d75f3,_0x463c9f){const _0x9cd4ee=_0x569e86;_0x3bebb5[_0x9cd4ee('0x1f80')]({'controller':_0x9cd4ee('0x1c28'),'controllerAs':'vm','templateUrl':_0x5969f0,'parent':angular['element'](_0x577778[_0x9cd4ee('0x8d2')]),'targetEvent':_0x463c9f,'clickOutsideToClose':!![],'locals':{'cloudProvider':_0x1d75f3,'cloudProviders':_0xe4604[_0x9cd4ee('0x1913')]['rows'],'license':_0xe4604[_0x9cd4ee('0x5c9')],'setting':null,'crudPermissions':_0xe4604[_0x9cd4ee('0x243c')]}});}function _0x593532(_0x2328f2,_0x1d7ef7){const _0x38ac96=_0x569e86,_0x5ca711=_0x3bebb5[_0x38ac96('0x1d26')]()[_0x38ac96('0xcdc')](_0x38ac96('0x288d')+_0x2cfb05()[_0x38ac96('0xb35')](_0x38ac96('0x16c6'))+'?')[_0x38ac96('0xf3c')](''+(_0x2328f2[_0x38ac96('0x4f0')]||'cloudProvider')+_0x38ac96('0xace')+_0x38ac96('0x3f3'))[_0x38ac96('0x8e8')](_0x38ac96('0x1f46'))[_0x38ac96('0x203b')](_0x1d7ef7)['ok']('OK')[_0x38ac96('0x3f')](_0x38ac96('0x2d3'));_0x3bebb5[_0x38ac96('0x1f80')](_0x5ca711)[_0x38ac96('0x1166')](function(){_0x1bcbd9(_0x2328f2);},function(){const _0x466703=_0x38ac96;console[_0x466703('0x455')](_0x466703('0x2d3'));});}let _0xf6a6fe=!![],_0xb6a954=0x1;_0x4b1478['$watch']('vm.query.filter',function(_0x4369fc,_0x1682d3){const _0x33c6e3=_0x569e86;_0xf6a6fe?_0x47ca58(function(){_0xf6a6fe=![];}):(!_0x1682d3&&(_0xb6a954=_0xe4604['query'][_0x33c6e3('0x1a43')]),_0x4369fc!==_0x1682d3&&(_0xe4604[_0x33c6e3('0x2218')][_0x33c6e3('0x1a43')]=0x1),!_0x4369fc&&(_0xe4604[_0x33c6e3('0x2218')][_0x33c6e3('0x1a43')]=_0xb6a954),_0xe4604[_0x33c6e3('0x26eb')]());});function _0x32386c(_0x3fbf48){const _0x4ee275=_0x569e86;_0xe4604[_0x4ee275('0x1913')]=_0x3fbf48||{'count':0x0,'rows':[]};}function _0x131446(){const _0x47a797=_0x569e86;_0xe4604[_0x47a797('0x2218')][_0x47a797('0x1098')]=(_0xe4604[_0x47a797('0x2218')]['page']-0x1)*_0xe4604[_0x47a797('0x2218')]['limit'],_0x2c5434['hasRole'](_0x47a797('0xa7c'))?_0xe4604[_0x47a797('0x1f48')]=_0x3d9f70[_0x47a797('0x16c6')][_0x47a797('0xd83')](_0xe4604[_0x47a797('0x2218')],_0x32386c)[_0x47a797('0xa44')]:(_0xe4604['query']['id']=_0xe4604[_0x47a797('0x7f')]['id'],_0xe4604[_0x47a797('0x2218')][_0x47a797('0xe60')]=_0x47a797('0x1c0b'),_0xe4604[_0x47a797('0x1f48')]=_0x3d9f70[_0x47a797('0x7f')][_0x47a797('0x263a')](_0xe4604[_0x47a797('0x2218')],_0x32386c)['$promise']);}function _0x5d299a(_0x4ed03e,_0x34528e){const _0x426c09=_0x569e86;_0x3bebb5[_0x426c09('0x1f80')]({'controller':_0x426c09('0x1c28'),'controllerAs':'vm','templateUrl':_0x5969f0,'parent':angular[_0x426c09('0x1194')](_0x577778['body']),'targetEvent':_0x4ed03e,'clickOutsideToClose':!![],'locals':{'cloudProvider':_0x34528e,'cloudProviders':_0xe4604[_0x426c09('0x1913')]['rows'],'license':_0xe4604[_0x426c09('0x5c9')],'setting':_0xe4604[_0x426c09('0xf8a')],'crudPermissions':_0xe4604[_0x426c09('0x243c')]}});}function _0x1bcbd9(_0x1d478c){const _0x503de9=_0x569e86;_0x3d9f70['cloudProvider']['delete']({'id':_0x1d478c['id']})[_0x503de9('0xa44')][_0x503de9('0x1166')](function(){const _0x11b80f=_0x503de9;_0x2cfb05()[_0x11b80f('0x127f')](_0xe4604[_0x11b80f('0x1913')][_0x11b80f('0x269a')],{'id':_0x1d478c['id']}),_0xe4604['cloudProviders'][_0x11b80f('0x240f')]-=0x1,!_0xe4604[_0x11b80f('0x1913')][_0x11b80f('0x269a')][_0x11b80f('0x264b')]&&_0xe4604[_0x11b80f('0x26eb')](),_0x5b7b8a[_0x11b80f('0x103b')]({'title':_0x2cfb05()[_0x11b80f('0xb35')](_0x11b80f('0x2482'))+_0x11b80f('0x2b6'),'msg':_0x1d478c[_0x11b80f('0x4f0')]?_0x1d478c[_0x11b80f('0x4f0')]+_0x11b80f('0x7cd'):''});})[_0x503de9('0x1a80')](function(_0x58f31f){const _0x22f8b7=_0x503de9;if(_0x58f31f['data']&&_0x58f31f[_0x22f8b7('0x25f4')][_0x22f8b7('0x61a')]&&_0x58f31f[_0x22f8b7('0x25f4')][_0x22f8b7('0x61a')]['length']){_0xe4604['errors']=_0x58f31f[_0x22f8b7('0x25f4')][_0x22f8b7('0x61a')]||[{'message':_0x58f31f[_0x22f8b7('0x1586')](),'type':_0x22f8b7('0x439')}];for(let _0x9a2e38=0x0;_0x9a2e38<_0x58f31f[_0x22f8b7('0x25f4')]['errors'][_0x22f8b7('0x264b')];_0x9a2e38++){_0x5b7b8a[_0x22f8b7('0xfc9')]({'title':_0x58f31f[_0x22f8b7('0x25f4')][_0x22f8b7('0x61a')][_0x9a2e38]['type'],'msg':_0x58f31f['data']['errors'][_0x9a2e38]['message']});}}else _0x5b7b8a[_0x22f8b7('0xfc9')]({'title':_0x58f31f[_0x22f8b7('0x52d')]?_0x22f8b7('0x1e21')+_0x58f31f[_0x22f8b7('0x52d')]+_0x22f8b7('0x11e1')+_0x58f31f[_0x22f8b7('0xe1b')]:_0x22f8b7('0x439'),'msg':_0x58f31f['data']?JSON[_0x22f8b7('0xbac')](_0x58f31f[_0x22f8b7('0x25f4')][_0x22f8b7('0x1e70')]):_0x58f31f[_0x22f8b7('0x1e70')]||_0x58f31f[_0x22f8b7('0x1586')]()});});}function _0xd5e438(){const _0x4b60a0=_0x569e86,_0x55e905=angular[_0x4b60a0('0x225f')](_0xe4604[_0x4b60a0('0xa95')]);return _0xe4604[_0x4b60a0('0xa95')]=[],_0x55e905;}function _0x1be8a3(_0x1a6f78){const _0x3b33e7=_0x569e86,_0x4cfffa=_0x3bebb5[_0x3b33e7('0x1d26')]()[_0x3b33e7('0xcdc')](_0x3b33e7('0x458'))['htmlContent'](_0x3b33e7('0x12b5')+_0xe4604[_0x3b33e7('0xa95')]['length']+'\x20selected'+_0x3b33e7('0x3f3'))[_0x3b33e7('0x8e8')]('delete\x20CloudProviders')[_0x3b33e7('0x203b')](_0x1a6f78)['ok']('OK')[_0x3b33e7('0x3f')](_0x3b33e7('0x2d3'));_0x3bebb5[_0x3b33e7('0x1f80')](_0x4cfffa)[_0x3b33e7('0x1166')](function(){const _0x1e9120=_0x3b33e7;_0xe4604[_0x1e9120('0xa95')][_0x1e9120('0x2782')](function(_0x277286){_0x1bcbd9(_0x277286);}),_0xe4604[_0x1e9120('0xa95')]=[];});}function _0x5d878a(){_0xe4604['selectedAiTools']=[];}function _0xaed765(){const _0x439356=_0x569e86;_0xe4604[_0x439356('0xa95')]=_0xe4604[_0x439356('0x1913')][_0x439356('0x269a')];}}const _0x2c55e3=_0x3201f5;_0x5cf234['$inject']=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x1913'),_0x36e6f4('0x16c6'),'api','Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x5cf234(_0x216327,_0x4652b5,_0x151800,_0x3e305d,_0x44e901,_0x25185e,_0x27f060,_0x22271f,_0x17dabf,_0x579a01,_0x2fd143,_0x4f261a,_0x1c3c28){const _0x4e4378=_0x36e6f4,_0x3f0f6d=this;_0x3f0f6d['currentUser']=_0x2fd143[_0x4e4378('0x26cd')](),_0x3f0f6d[_0x4e4378('0x61a')]=[],_0x3f0f6d['setting']=_0x1c3c28,_0x3f0f6d['license']=_0x4f261a,_0x3f0f6d['hasModulePermissions']={},_0x3f0f6d[_0x4e4378('0x2900')]=_0x3f0f6d[_0x4e4378('0xf8a')]&&_0x3f0f6d[_0x4e4378('0xf8a')][_0x4e4378('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3f0f6d[_0x4e4378('0xcdc')]=_0x4e4378('0x22e'),_0x3f0f6d['cloudProvider']=angular['copy'](_0x17dabf),_0x3f0f6d['cloudProviders']=_0x22271f,_0x3f0f6d[_0x4e4378('0x16f3')]=![];!_0x3f0f6d['cloudProvider']&&(_0x3f0f6d[_0x4e4378('0x16c6')]={},_0x3f0f6d[_0x4e4378('0xcdc')]='SETTINGS.NEW_CLOUDPROVIDER',_0x3f0f6d[_0x4e4378('0x16f3')]=!![]);_0x3f0f6d[_0x4e4378('0x23ab')]=_0x46167c,_0x3f0f6d['saveCloudProvider']=_0x39223,_0x3f0f6d['deleteCloudProvider']=_0x3287fe,_0x3f0f6d[_0x4e4378('0x1a9c')]=_0x16d1fd,_0x3f0f6d[_0x4e4378('0x24a0')]=_0x2cc8c5;function _0x46167c(){const _0x2674cc=_0x4e4378;_0x3f0f6d['errors']=[],_0x579a01['cloudProvider'][_0x2674cc('0x9cc')](_0x3f0f6d['cloudProvider'])['$promise'][_0x2674cc('0x1166')](function(_0xcdafe0){const _0x1f804a=_0x2674cc;_0x3f0f6d[_0x1f804a('0x1913')][_0x1f804a('0x2450')](_0xcdafe0[_0x1f804a('0x2876')]()),_0x27f060[_0x1f804a('0x103b')]({'title':_0x1f804a('0x805'),'msg':_0x3f0f6d['cloudProvider'][_0x1f804a('0x4f0')]?_0x3f0f6d[_0x1f804a('0x16c6')][_0x1f804a('0x4f0')]+_0x1f804a('0x1eda'):''}),_0x2cc8c5(_0xcdafe0);})['catch'](function(_0x49d80e){const _0x42f8f9=_0x2674cc;if(_0x49d80e[_0x42f8f9('0x25f4')]&&_0x49d80e['data'][_0x42f8f9('0x61a')]&&_0x49d80e[_0x42f8f9('0x25f4')][_0x42f8f9('0x61a')][_0x42f8f9('0x264b')]){_0x3f0f6d[_0x42f8f9('0x61a')]=_0x49d80e[_0x42f8f9('0x25f4')][_0x42f8f9('0x61a')]||[{'message':_0x49d80e[_0x42f8f9('0x1586')](),'type':_0x42f8f9('0xfac')}];for(let _0x20eb86=0x0;_0x20eb86<_0x49d80e[_0x42f8f9('0x25f4')][_0x42f8f9('0x61a')][_0x42f8f9('0x264b')];_0x20eb86+=0x1){_0x27f060['error']({'title':_0x49d80e[_0x42f8f9('0x25f4')][_0x42f8f9('0x61a')][_0x20eb86]['type'],'msg':_0x49d80e[_0x42f8f9('0x25f4')][_0x42f8f9('0x61a')][_0x20eb86][_0x42f8f9('0x1e70')]});}}else _0x27f060[_0x42f8f9('0xfc9')]({'title':_0x49d80e[_0x42f8f9('0x52d')]?_0x42f8f9('0x1e21')+_0x49d80e['status']+'\x20-\x20'+_0x49d80e[_0x42f8f9('0xe1b')]:_0x42f8f9('0xfac'),'msg':_0x49d80e[_0x42f8f9('0x25f4')]?JSON[_0x42f8f9('0xbac')](_0x49d80e[_0x42f8f9('0x25f4')][_0x42f8f9('0x1e70')]):_0x49d80e[_0x42f8f9('0x1586')]()});});}function _0x39223(){const _0x509389=_0x4e4378;_0x3f0f6d[_0x509389('0x61a')]=[],_0x579a01['cloudProvider'][_0x509389('0x1449')]({'id':_0x3f0f6d[_0x509389('0x16c6')]['id']},_0x3f0f6d[_0x509389('0x16c6')])['$promise']['then'](function(_0x23b569){const _0x39df40=_0x509389,_0x32a383=_0x2cfb05()[_0x39df40('0xc38')](_0x3f0f6d[_0x39df40('0x1913')],{'id':_0x23b569['id']});_0x32a383&&_0x2cfb05()[_0x39df40('0xcc3')](_0x32a383,_0x2cfb05()['pick'](_0x23b569[_0x39df40('0x2876')](),_0x2cfb05()['keys'](_0x32a383))),_0x27f060[_0x39df40('0x103b')]({'title':_0x39df40('0x4a4'),'msg':_0x3f0f6d[_0x39df40('0x16c6')][_0x39df40('0x4f0')]?_0x3f0f6d[_0x39df40('0x16c6')][_0x39df40('0x4f0')]+_0x39df40('0x7d'):''}),_0x2cc8c5(_0x23b569);})[_0x509389('0x1a80')](function(_0x252152){const _0x5ca9b8=_0x509389;if(_0x252152[_0x5ca9b8('0x25f4')]&&_0x252152[_0x5ca9b8('0x25f4')][_0x5ca9b8('0x61a')]&&_0x252152[_0x5ca9b8('0x25f4')][_0x5ca9b8('0x61a')][_0x5ca9b8('0x264b')]){_0x3f0f6d['errors']=_0x252152[_0x5ca9b8('0x25f4')][_0x5ca9b8('0x61a')]||[{'message':_0x252152[_0x5ca9b8('0x1586')](),'type':_0x5ca9b8('0x1fcb')}];for(let _0x30ac07=0x0;_0x30ac07<_0x252152[_0x5ca9b8('0x25f4')][_0x5ca9b8('0x61a')]['length'];_0x30ac07++){_0x27f060[_0x5ca9b8('0xfc9')]({'title':_0x252152[_0x5ca9b8('0x25f4')][_0x5ca9b8('0x61a')][_0x30ac07][_0x5ca9b8('0x1345')],'msg':_0x252152[_0x5ca9b8('0x25f4')][_0x5ca9b8('0x61a')][_0x30ac07][_0x5ca9b8('0x1e70')]});}}else _0x27f060[_0x5ca9b8('0xfc9')]({'title':_0x252152['status']?_0x5ca9b8('0x1e21')+_0x252152[_0x5ca9b8('0x52d')]+_0x5ca9b8('0x11e1')+_0x252152[_0x5ca9b8('0xe1b')]:_0x5ca9b8('0x1fcb'),'msg':_0x252152['data']?JSON[_0x5ca9b8('0xbac')](_0x252152[_0x5ca9b8('0x25f4')][_0x5ca9b8('0x1e70')]):_0x252152['toString']()});});}function _0x3287fe(_0x1f80fa){const _0x3bf677=_0x4e4378;_0x3f0f6d[_0x3bf677('0x61a')]=[];const _0x33441a=_0x3e305d[_0x3bf677('0x1d26')]()[_0x3bf677('0xcdc')](_0x3bf677('0x7fb'))[_0x3bf677('0xacc')](_0x3bf677('0x377'))[_0x3bf677('0x8e8')](_0x3bf677('0x2478'))['ok']('Delete')[_0x3bf677('0x3f')](_0x3bf677('0x497'))['targetEvent'](_0x1f80fa);_0x3e305d[_0x3bf677('0x1f80')](_0x33441a)[_0x3bf677('0x1166')](function(){const _0x2de2c1=_0x3bf677;_0x579a01[_0x2de2c1('0x16c6')]['delete']({'id':_0x3f0f6d['cloudProvider']['id']})['$promise'][_0x2de2c1('0x1166')](function(){const _0x1f863a=_0x2de2c1;_0x2cfb05()[_0x1f863a('0x127f')](_0x3f0f6d[_0x1f863a('0x1913')],{'id':_0x3f0f6d['cloudProvider']['id']}),_0x27f060['success']({'title':_0x1f863a('0x919'),'msg':(_0x3f0f6d['cloudProvider'][_0x1f863a('0x4f0')]||_0x1f863a('0x16c6'))+_0x1f863a('0x7cd')}),_0x2cc8c5(_0x3f0f6d[_0x1f863a('0x16c6')]);})[_0x2de2c1('0x1a80')](function(_0x102d80){const _0x59b51c=_0x2de2c1;if(_0x102d80[_0x59b51c('0x25f4')]&&_0x102d80[_0x59b51c('0x25f4')]['errors']&&_0x102d80['data']['errors'][_0x59b51c('0x264b')]){_0x3f0f6d[_0x59b51c('0x61a')]=_0x102d80[_0x59b51c('0x25f4')]['errors']||[{'message':_0x102d80[_0x59b51c('0x1586')](),'type':'api.cloudProvider.delete'}];for(let _0xe9a974=0x0;_0xe9a974<_0x102d80[_0x59b51c('0x25f4')][_0x59b51c('0x61a')][_0x59b51c('0x264b')];_0xe9a974++){_0x27f060[_0x59b51c('0xfc9')]({'title':_0x102d80['data'][_0x59b51c('0x61a')][_0xe9a974][_0x59b51c('0x1345')],'msg':_0x102d80[_0x59b51c('0x25f4')][_0x59b51c('0x61a')][_0xe9a974][_0x59b51c('0x1e70')]});}}else _0x27f060[_0x59b51c('0xfc9')]({'title':_0x102d80[_0x59b51c('0x52d')]?_0x59b51c('0x1e21')+_0x102d80[_0x59b51c('0x52d')]+_0x59b51c('0x11e1')+_0x102d80[_0x59b51c('0xe1b')]:_0x59b51c('0x2080'),'msg':_0x102d80[_0x59b51c('0x25f4')]?JSON[_0x59b51c('0xbac')](_0x102d80[_0x59b51c('0x25f4')]['message']):_0x102d80['message']||_0x102d80[_0x59b51c('0x1586')]()});});},function(){});}function _0x16d1fd(_0x445cb7){return _0x445cb7===null?undefined:new Date(_0x445cb7);}function _0x2cc8c5(_0x405497){const _0x3b0c03=_0x4e4378;_0x3e305d[_0x3b0c03('0x1197')](_0x405497);}}const _0x48ee47=_0x5cf234;_0x471f0b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x7c6'),_0x36e6f4('0x715'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license','setting',_0x36e6f4('0x243c')];function _0x471f0b(_0x535f01,_0x1b18b5,_0x4f2743,_0x535e9b,_0x6b571,_0x340323,_0x386c8d,_0x31d068,_0x2c7053,_0x5cf0e5,_0x440880,_0x30c052,_0xc09d86,_0x21297c){const _0x2085ad=_0x36e6f4,_0x464fbb=this;_0x464fbb[_0x2085ad('0x98')]=_0x440880[_0x2085ad('0x26cd')](),_0x464fbb[_0x2085ad('0x61a')]=[],_0x464fbb[_0x2085ad('0xf8a')]=_0xc09d86,_0x464fbb[_0x2085ad('0x5c9')]=_0x30c052,_0x464fbb[_0x2085ad('0x243c')]=_0x21297c,_0x464fbb[_0x2085ad('0x128b')]={},_0x464fbb[_0x2085ad('0x2900')]=_0x464fbb[_0x2085ad('0xf8a')]&&_0x464fbb[_0x2085ad('0xf8a')][_0x2085ad('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x464fbb['title']=_0x2085ad('0x2057'),_0x464fbb[_0x2085ad('0x715')]=angular[_0x2085ad('0x225f')](_0x2c7053),_0x464fbb[_0x2085ad('0x7c6')]=_0x31d068,_0x464fbb[_0x2085ad('0x1f01')]=![];!_0x464fbb[_0x2085ad('0x715')]&&(_0x464fbb['customization']={},_0x464fbb[_0x2085ad('0xcdc')]='SETTINGS.NEW_CUSTOMIZATION',_0x464fbb[_0x2085ad('0x1f01')]=!![]);_0x464fbb[_0x2085ad('0x1285')]=_0x49d5df,_0x464fbb[_0x2085ad('0x2679')]=_0x332f2a,_0x464fbb[_0x2085ad('0x1533')]=_0x2e02a9,_0x464fbb['getDateFromString']=_0x79dfde,_0x464fbb[_0x2085ad('0x24a0')]=_0x21c1bf;function _0x49d5df(){const _0x239c34=_0x2085ad;_0x464fbb[_0x239c34('0x61a')]=[],_0x5cf0e5[_0x239c34('0xf8a')][_0x239c34('0x9cc')](_0x464fbb[_0x239c34('0x715')])[_0x239c34('0xa44')][_0x239c34('0x1166')](function(_0x2d6cb8){const _0x3a1900=_0x239c34;_0x464fbb[_0x3a1900('0x7c6')][_0x3a1900('0x2450')](_0x2d6cb8[_0x3a1900('0x2876')]()),_0x386c8d[_0x3a1900('0x103b')]({'title':'Customization\x20properly\x20created','msg':_0x464fbb[_0x3a1900('0x715')][_0x3a1900('0x4f0')]?_0x464fbb[_0x3a1900('0x715')][_0x3a1900('0x4f0')]+_0x3a1900('0x1eda'):''}),_0x21c1bf(_0x2d6cb8);})[_0x239c34('0x1a80')](function(_0x1cc47e){const _0xf75b43=_0x239c34;if(_0x1cc47e[_0xf75b43('0x25f4')]&&_0x1cc47e['data']['errors']&&_0x1cc47e[_0xf75b43('0x25f4')][_0xf75b43('0x61a')][_0xf75b43('0x264b')]){_0x464fbb[_0xf75b43('0x61a')]=_0x1cc47e['data']['errors']||[{'message':_0x1cc47e['toString'](),'type':'api.setting.save'}];for(let _0x4f407b=0x0;_0x4f407b<_0x1cc47e[_0xf75b43('0x25f4')][_0xf75b43('0x61a')][_0xf75b43('0x264b')];_0x4f407b+=0x1){_0x386c8d['error']({'title':_0x1cc47e[_0xf75b43('0x25f4')][_0xf75b43('0x61a')][_0x4f407b][_0xf75b43('0x1345')],'msg':_0x1cc47e['data'][_0xf75b43('0x61a')][_0x4f407b][_0xf75b43('0x1e70')]});}}else _0x386c8d['error']({'title':_0x1cc47e[_0xf75b43('0x52d')]?_0xf75b43('0x1e21')+_0x1cc47e[_0xf75b43('0x52d')]+'\x20-\x20'+_0x1cc47e['statusText']:_0xf75b43('0x17fc'),'msg':_0x1cc47e[_0xf75b43('0x25f4')]?JSON[_0xf75b43('0xbac')](_0x1cc47e['data'][_0xf75b43('0x1e70')]):_0x1cc47e['toString']()});});}function _0x332f2a(){const _0x3b574c=_0x2085ad;_0x464fbb[_0x3b574c('0x61a')]=[],_0x5cf0e5['setting'][_0x3b574c('0x1449')]({'id':_0x464fbb[_0x3b574c('0x715')]['id']},_0x464fbb[_0x3b574c('0x715')])['$promise']['then'](function(_0x355949){const _0x592a88=_0x3b574c,_0x2f2435=_0x2cfb05()['find'](_0x464fbb[_0x592a88('0x7c6')],{'id':_0x355949['id']});_0x2f2435&&_0x2cfb05()[_0x592a88('0xcc3')](_0x2f2435,_0x2cfb05()['pick'](_0x355949[_0x592a88('0x2876')](),_0x2cfb05()[_0x592a88('0x14a4')](_0x2f2435))),_0x386c8d[_0x592a88('0x103b')]({'title':_0x592a88('0x19e5'),'msg':_0x464fbb['customization'][_0x592a88('0x4f0')]?_0x464fbb[_0x592a88('0x715')][_0x592a88('0x4f0')]+_0x592a88('0x7d'):''}),_0x21c1bf(_0x355949);})[_0x3b574c('0x1a80')](function(_0x40f69b){const _0x399513=_0x3b574c;if(_0x40f69b[_0x399513('0x25f4')]&&_0x40f69b[_0x399513('0x25f4')][_0x399513('0x61a')]&&_0x40f69b[_0x399513('0x25f4')][_0x399513('0x61a')][_0x399513('0x264b')]){_0x464fbb[_0x399513('0x61a')]=_0x40f69b[_0x399513('0x25f4')][_0x399513('0x61a')]||[{'message':_0x40f69b[_0x399513('0x1586')](),'type':_0x399513('0xb53')}];for(let _0x2250c0=0x0;_0x2250c0<_0x40f69b[_0x399513('0x25f4')]['errors'][_0x399513('0x264b')];_0x2250c0++){_0x386c8d[_0x399513('0xfc9')]({'title':_0x40f69b['data'][_0x399513('0x61a')][_0x2250c0][_0x399513('0x1345')],'msg':_0x40f69b['data']['errors'][_0x2250c0][_0x399513('0x1e70')]});}}else _0x386c8d[_0x399513('0xfc9')]({'title':_0x40f69b[_0x399513('0x52d')]?_0x399513('0x1e21')+_0x40f69b[_0x399513('0x52d')]+_0x399513('0x11e1')+_0x40f69b[_0x399513('0xe1b')]:_0x399513('0xb53'),'msg':_0x40f69b[_0x399513('0x25f4')]?JSON['stringify'](_0x40f69b[_0x399513('0x25f4')][_0x399513('0x1e70')]):_0x40f69b['toString']()});});}function _0x2e02a9(_0xe03778){const _0x1499ba=_0x2085ad;_0x464fbb[_0x1499ba('0x61a')]=[];const _0x18eb2e=_0x535e9b['confirm']()[_0x1499ba('0xcdc')](_0x1499ba('0x7fb'))[_0x1499ba('0xacc')]('The\x20customization\x20will\x20be\x20deleted.')[_0x1499ba('0x8e8')](_0x1499ba('0xca0'))['ok'](_0x1499ba('0x18'))['cancel'](_0x1499ba('0x497'))[_0x1499ba('0x203b')](_0xe03778);_0x535e9b[_0x1499ba('0x1f80')](_0x18eb2e)[_0x1499ba('0x1166')](function(){const _0x5c10bd=_0x1499ba;_0x5cf0e5[_0x5c10bd('0xf8a')]['delete']({'id':_0x464fbb[_0x5c10bd('0x715')]['id']})['$promise'][_0x5c10bd('0x1166')](function(){const _0x4c05bb=_0x5c10bd;_0x2cfb05()['remove'](_0x464fbb['customizations'],{'id':_0x464fbb['customization']['id']}),_0x386c8d[_0x4c05bb('0x103b')]({'title':_0x4c05bb('0xe4'),'msg':(_0x464fbb[_0x4c05bb('0x715')][_0x4c05bb('0x4f0')]||_0x4c05bb('0x715'))+_0x4c05bb('0x7cd')}),_0x21c1bf(_0x464fbb['customization']);})['catch'](function(_0x2ad715){const _0x4cf7d6=_0x5c10bd;if(_0x2ad715[_0x4cf7d6('0x25f4')]&&_0x2ad715[_0x4cf7d6('0x25f4')][_0x4cf7d6('0x61a')]&&_0x2ad715[_0x4cf7d6('0x25f4')][_0x4cf7d6('0x61a')][_0x4cf7d6('0x264b')]){_0x464fbb[_0x4cf7d6('0x61a')]=_0x2ad715[_0x4cf7d6('0x25f4')][_0x4cf7d6('0x61a')]||[{'message':_0x2ad715[_0x4cf7d6('0x1586')](),'type':'api.setting.delete'}];for(let _0x188ae8=0x0;_0x188ae8<_0x2ad715[_0x4cf7d6('0x25f4')]['errors']['length'];_0x188ae8++){_0x386c8d[_0x4cf7d6('0xfc9')]({'title':_0x2ad715[_0x4cf7d6('0x25f4')][_0x4cf7d6('0x61a')][_0x188ae8][_0x4cf7d6('0x1345')],'msg':_0x2ad715[_0x4cf7d6('0x25f4')][_0x4cf7d6('0x61a')][_0x188ae8][_0x4cf7d6('0x1e70')]});}}else _0x386c8d[_0x4cf7d6('0xfc9')]({'title':_0x2ad715['status']?_0x4cf7d6('0x1e21')+_0x2ad715[_0x4cf7d6('0x52d')]+'\x20-\x20'+_0x2ad715[_0x4cf7d6('0xe1b')]:'api.setting.delete','msg':_0x2ad715[_0x4cf7d6('0x25f4')]?JSON['stringify'](_0x2ad715[_0x4cf7d6('0x25f4')][_0x4cf7d6('0x1e70')]):_0x2ad715['message']||_0x2ad715['toString']()});});},function(){});}function _0x79dfde(_0x3d4956){return _0x3d4956===null?undefined:new Date(_0x3d4956);}function _0x21c1bf(_0x515ce6){const _0x5b1a49=_0x2085ad;_0x535e9b[_0x5b1a49('0x1197')](_0x515ce6);}}const _0x969763=_0x471f0b;_0x3b18f4[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7c6'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x5c9'),_0x36e6f4('0x21ef')];function _0x3b18f4(_0x1c3c2f,_0x49ee4e,_0x50f380,_0x523293,_0x3362f8){const _0xcf9ef2=_0x36e6f4,_0x5d0ed8=this;_0x5d0ed8['currentUser']=_0x3362f8['getCurrentUser'](),_0x5d0ed8[_0xcf9ef2('0x5c9')]=_0x523293,_0x5d0ed8['customizations']=_0x1c3c2f,_0x5d0ed8[_0xcf9ef2('0x715')]={};_0x5d0ed8[_0xcf9ef2('0x7c6')]&&_0x5d0ed8[_0xcf9ef2('0x7c6')]['rows']&&_0x5d0ed8[_0xcf9ef2('0x7c6')][_0xcf9ef2('0x269a')][_0xcf9ef2('0x264b')]&&(_0x5d0ed8['customization']=_0x5d0ed8['customizations']['rows'][0x0]);_0x5d0ed8[_0xcf9ef2('0x2679')]=_0x184256;function _0x184256(){const _0x6824a5=_0xcf9ef2;_0x5d0ed8['customization']['id']?_0x49ee4e[_0x6824a5('0xf8a')]['update']({'id':_0x5d0ed8['customization']['id']},_0x5d0ed8[_0x6824a5('0x715')])[_0x6824a5('0xa44')][_0x6824a5('0x1166')](function(){const _0x141455=_0x6824a5;_0x50f380[_0x141455('0x103b')]({'title':'Customization\x20updated!','msg':_0x5d0ed8[_0x141455('0x715')][_0x141455('0x4f0')]?_0x5d0ed8['customization'][_0x141455('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x6824a5('0x1a80')](function(_0x29c9f8){const _0x21b69a=_0x6824a5;_0x50f380[_0x21b69a('0xfc9')]({'title':_0x29c9f8[_0x21b69a('0x52d')]?_0x21b69a('0x1e21')+_0x29c9f8['status']+'\x20-\x20'+_0x29c9f8['statusText']:_0x21b69a('0x1076'),'msg':_0x29c9f8[_0x21b69a('0x25f4')]?JSON[_0x21b69a('0xbac')](_0x29c9f8[_0x21b69a('0x25f4')]):_0x29c9f8[_0x21b69a('0x1586')]()});}):_0x49ee4e[_0x6824a5('0xf8a')]['save'](_0x5d0ed8[_0x6824a5('0x715')])[_0x6824a5('0xa44')]['then'](function(_0xd96d74){const _0x2bb882=_0x6824a5;_0x2cfb05()[_0x2bb882('0xcc3')](_0x5d0ed8[_0x2bb882('0x715')],_0xd96d74),_0x50f380[_0x2bb882('0x103b')]({'title':'Customization\x20updated!','msg':_0x5d0ed8['customization'][_0x2bb882('0x4f0')]?_0x5d0ed8[_0x2bb882('0x715')][_0x2bb882('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x6824a5('0x1a80')](function(_0x563cf4){const _0x42f9d9=_0x6824a5;_0x50f380[_0x42f9d9('0xfc9')]({'title':_0x563cf4[_0x42f9d9('0x52d')]?_0x42f9d9('0x1e21')+_0x563cf4[_0x42f9d9('0x52d')]+_0x42f9d9('0x11e1')+_0x563cf4['statusText']:_0x42f9d9('0x1076'),'msg':_0x563cf4[_0x42f9d9('0x25f4')]?JSON[_0x42f9d9('0xbac')](_0x563cf4[_0x42f9d9('0x25f4')]):_0x563cf4[_0x42f9d9('0x1586')]()});});}}const _0x429982=_0x3b18f4;_0x4ce76c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),'toasty'];function _0x4ce76c(_0x63d367,_0xf717f2){const _0x5edf4d=_0x36e6f4,_0x1be3cf=this,_0x2147c2=0x8,_0x8db030=_0x2147c2*0x400*0x400;_0x1be3cf['customization']={},_0x1be3cf[_0x5edf4d('0xd67')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x8db030,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x1be3cf['ngFlow']={'flow':{}},_0x1be3cf[_0x5edf4d('0x1a5c')]=![],_0x1be3cf['fileAdded']=_0x48d23f,_0x1be3cf[_0x5edf4d('0x1d40')]=_0x56ce96,_0x1be3cf[_0x5edf4d('0x1dea')]=_0x1162b5,_0x1be3cf[_0x5edf4d('0x24d5')]=_0x51a61f;function _0x51a61f(_0x216cf6){const _0x1effc5=_0x5edf4d;_0x1be3cf[_0x1effc5('0x715')]=angular['copy'](_0x216cf6),_0x1be3cf[_0x1effc5('0xd67')][_0x1effc5('0x21cc')]=_0x1effc5('0x343')[_0x1effc5('0xf3')](_0x1effc5('0x1585'),_0x1be3cf[_0x1effc5('0x715')]['id']),_0x1be3cf[_0x1effc5('0x715')][_0x1effc5('0x1b17')]=[];}function _0x48d23f(_0x35c078){const _0x323375=_0x5edf4d,_0xc84d10=['png',_0x323375('0x1cd0'),_0x323375('0x217e')];if(!_0x2cfb05()[_0x323375('0x1257')](_0xc84d10,_0x35c078[_0x323375('0x26a5')]()))return _0xf717f2[_0x323375('0xfc9')]({'title':_0x323375('0x27fb')+_0x35c078[_0x323375('0x26a5')](),'msg':_0x323375('0x1020')+_0xc84d10[_0x323375('0x45a')]()}),![];if(_0x35c078[_0x323375('0x2340')]>_0x8db030)return _0xf717f2[_0x323375('0xfc9')]({'title':_0x323375('0x11e6'),'msg':_0x323375('0x12c0')+_0x2147c2+'MB'}),![];const _0xbd6509={'id':_0x35c078['uniqueIdentifier'],'file':_0x35c078,'type':'uploading'};return _0x1be3cf[_0x323375('0x715')][_0x323375('0x1b17')]['unshift'](_0xbd6509),!![];}function _0x56ce96(){const _0x1a65e8=_0x5edf4d;_0x1be3cf['ngFlow'][_0x1a65e8('0x13d1')][_0x1a65e8('0x1ca3')][_0x1a65e8('0x5fb')]={'X-Requested-With':_0x1a65e8('0x1bc1'),'Authorization':_0x1a65e8('0x24d4')+_0x63d367[_0x1a65e8('0xd83')]('motion.token')},_0x1be3cf['ngFlow'][_0x1a65e8('0x13d1')]['upload']();}function _0x1162b5(_0x469dab){const _0xd24162=_0x5edf4d;angular[_0xd24162('0x2782')](_0x1be3cf['customization'][_0xd24162('0x1b17')],function(_0x12713e){const _0x1ac4de=_0xd24162;if(_0x12713e['id']===_0x469dab[_0x1ac4de('0x20f4')]){const _0x24804f=new FileReader();_0x24804f[_0x1ac4de('0x2030')](_0x12713e[_0x1ac4de('0x6bd')]['file']),_0x24804f['onload']=function(_0x1218b6){const _0x4896a3=_0x1ac4de;_0x12713e[_0x4896a3('0xcac')]=_0x1218b6[_0x4896a3('0x21cc')][_0x4896a3('0x15b5')];},_0x12713e[_0x1ac4de('0x1345')]=_0x1ac4de('0x19f5');}});}}const _0x40453d=_0x4ce76c;_0x2bfe8a[_0x36e6f4('0x1294')]=['$cookies','toasty'];function _0x2bfe8a(_0x3bf6f5,_0x38eec9){const _0x9d1250=_0x36e6f4,_0x3508ef=this,_0x1dfb6d=0x8,_0x1b4180=_0x1dfb6d*0x400*0x400;_0x3508ef[_0x9d1250('0x715')]={},_0x3508ef['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x1b4180,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x3508ef[_0x9d1250('0xe57')]={'flow':{}},_0x3508ef[_0x9d1250('0x1a5c')]=![],_0x3508ef[_0x9d1250('0xd20')]=_0x29bede,_0x3508ef[_0x9d1250('0x1d40')]=_0x387f19,_0x3508ef[_0x9d1250('0x1dea')]=_0x1af878,_0x3508ef[_0x9d1250('0x24d5')]=_0x143222;function _0x143222(_0x49a7e5){const _0x3597cb=_0x9d1250;_0x3508ef[_0x3597cb('0x715')]=angular['copy'](_0x49a7e5),_0x3508ef[_0x3597cb('0xd67')][_0x3597cb('0x21cc')]=_0x3597cb('0x28a3')[_0x3597cb('0xf3')](_0x3597cb('0x1585'),_0x3508ef[_0x3597cb('0x715')]['id']),_0x3508ef[_0x3597cb('0x715')]['images']=[];}function _0x29bede(_0x31c31c){const _0x35c02d=_0x9d1250,_0x218688=[_0x35c02d('0xccc'),_0x35c02d('0x1cd0')];if(!_0x2cfb05()[_0x35c02d('0x1257')](_0x218688,_0x31c31c[_0x35c02d('0x26a5')]()))return _0x38eec9[_0x35c02d('0xfc9')]({'title':_0x35c02d('0x27fb')+_0x31c31c['getExtension'](),'msg':_0x35c02d('0x1020')+_0x218688[_0x35c02d('0x45a')]()}),![];if(_0x31c31c['size']>_0x1b4180)return _0x38eec9['error']({'title':_0x35c02d('0x11e6'),'msg':_0x35c02d('0x12c0')+_0x1dfb6d+'MB'}),![];const _0x4838ea={'id':_0x31c31c[_0x35c02d('0x20f4')],'file':_0x31c31c,'type':_0x35c02d('0x32f')};return _0x3508ef[_0x35c02d('0x715')][_0x35c02d('0x1b17')][_0x35c02d('0x2450')](_0x4838ea),!![];}function _0x387f19(){const _0x5986a3=_0x9d1250;_0x3508ef[_0x5986a3('0xe57')][_0x5986a3('0x13d1')]['opts'][_0x5986a3('0x5fb')]={'X-Requested-With':_0x5986a3('0x1bc1'),'Authorization':_0x5986a3('0x24d4')+_0x3bf6f5['get'](_0x5986a3('0x10b6'))},_0x3508ef[_0x5986a3('0xe57')][_0x5986a3('0x13d1')][_0x5986a3('0x1d40')]();}function _0x1af878(_0x76e618){const _0x52b595=_0x9d1250;angular['forEach'](_0x3508ef[_0x52b595('0x715')]['images'],function(_0x15f712){const _0x3f1faf=_0x52b595;if(_0x15f712['id']===_0x76e618['uniqueIdentifier']){const _0x3d030a=new FileReader();_0x3d030a[_0x3f1faf('0x2030')](_0x15f712[_0x3f1faf('0x6bd')][_0x3f1faf('0x6bd')]),_0x3d030a[_0x3f1faf('0x15d4')]=function(_0x3f0c9b){const _0x159886=_0x3f1faf;_0x15f712[_0x159886('0xcac')]=_0x3f0c9b[_0x159886('0x21cc')][_0x159886('0x15b5')];},_0x15f712['type']=_0x3f1faf('0x19f5');}});}}const _0x5a5f33=_0x2bfe8a;_0x1616f2[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),'toasty'];function _0x1616f2(_0x169a38,_0x5c54be){const _0x3d88be=_0x36e6f4,_0x5003c4=this,_0x45ba57=0x8,_0x4de6df=_0x45ba57*0x400*0x400;_0x5003c4[_0x3d88be('0x715')]={},_0x5003c4['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x4de6df,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x5003c4['ngFlow']={'flow':{}},_0x5003c4[_0x3d88be('0x1a5c')]=![],_0x5003c4[_0x3d88be('0xd20')]=_0x385d4b,_0x5003c4['upload']=_0x36ec30,_0x5003c4[_0x3d88be('0x1dea')]=_0x4d1a60,_0x5003c4[_0x3d88be('0x24d5')]=_0x68302f;function _0x68302f(_0x438eeb){const _0x5685f8=_0x3d88be;_0x5003c4[_0x5685f8('0x715')]=angular[_0x5685f8('0x225f')](_0x438eeb),_0x5003c4['ngFlowOptions'][_0x5685f8('0x21cc')]=_0x5685f8('0x24b4')[_0x5685f8('0xf3')](':id',_0x5003c4[_0x5685f8('0x715')]['id']),_0x5003c4[_0x5685f8('0x715')]['images']=[];}function _0x385d4b(_0x2260bf){const _0x4cf887=_0x3d88be,_0x146a89=[_0x4cf887('0xccc'),_0x4cf887('0x1cd0')];if(!_0x2cfb05()[_0x4cf887('0x1257')](_0x146a89,_0x2260bf['getExtension']()))return _0x5c54be[_0x4cf887('0xfc9')]({'title':_0x4cf887('0x27fb')+_0x2260bf[_0x4cf887('0x26a5')](),'msg':_0x4cf887('0x1020')+_0x146a89[_0x4cf887('0x45a')]()}),![];if(_0x2260bf[_0x4cf887('0x2340')]>_0x4de6df)return _0x5c54be[_0x4cf887('0xfc9')]({'title':_0x4cf887('0x11e6'),'msg':_0x4cf887('0x12c0')+_0x45ba57+'MB'}),![];const _0x59ace6={'id':_0x2260bf[_0x4cf887('0x20f4')],'file':_0x2260bf,'type':_0x4cf887('0x32f')};return _0x5003c4['customization'][_0x4cf887('0x1b17')][_0x4cf887('0x2450')](_0x59ace6),!![];}function _0x36ec30(){const _0x4325b9=_0x3d88be;_0x5003c4[_0x4325b9('0xe57')][_0x4325b9('0x13d1')][_0x4325b9('0x1ca3')][_0x4325b9('0x5fb')]={'X-Requested-With':_0x4325b9('0x1bc1'),'Authorization':_0x4325b9('0x24d4')+_0x169a38['get'](_0x4325b9('0x10b6'))},_0x5003c4['ngFlow'][_0x4325b9('0x13d1')][_0x4325b9('0x1d40')]();}function _0x4d1a60(_0x1d8afb){const _0x4952b7=_0x3d88be;angular[_0x4952b7('0x2782')](_0x5003c4[_0x4952b7('0x715')][_0x4952b7('0x1b17')],function(_0x281de7){const _0x3ca7a4=_0x4952b7;if(_0x281de7['id']===_0x1d8afb['uniqueIdentifier']){const _0x46a25a=new FileReader();_0x46a25a[_0x3ca7a4('0x2030')](_0x281de7[_0x3ca7a4('0x6bd')][_0x3ca7a4('0x6bd')]),_0x46a25a[_0x3ca7a4('0x15d4')]=function(_0x2e3e9b){const _0x6203d6=_0x3ca7a4;_0x281de7[_0x6203d6('0xcac')]=_0x2e3e9b[_0x6203d6('0x21cc')][_0x6203d6('0x15b5')];},_0x281de7[_0x3ca7a4('0x1345')]=_0x3ca7a4('0x19f5');}});}}const _0x42c3f0=_0x1616f2;_0x2afd79[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x1d2e')];function _0x2afd79(_0x45bfa2,_0x4fe2d9){const _0x5387cf=_0x36e6f4,_0x5ed689=this,_0x397219=0x8,_0x2dfb7a=_0x397219*0x400*0x400;_0x5ed689[_0x5387cf('0x715')]={},_0x5ed689[_0x5387cf('0xd67')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x2dfb7a,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x5ed689['ngFlow']={'flow':{}},_0x5ed689[_0x5387cf('0x1a5c')]=![],_0x5ed689['fileAdded']=_0x3005fe,_0x5ed689[_0x5387cf('0x1d40')]=_0x934d8a,_0x5ed689[_0x5387cf('0x1dea')]=_0x21f841,_0x5ed689[_0x5387cf('0x24d5')]=_0xe59698;function _0xe59698(_0x409208){const _0x2fb226=_0x5387cf;_0x5ed689[_0x2fb226('0x715')]=angular[_0x2fb226('0x225f')](_0x409208),_0x5ed689[_0x2fb226('0xd67')]['target']='/api/settings/1/preferred'['replace'](_0x2fb226('0x1585'),_0x5ed689[_0x2fb226('0x715')]['id']),_0x5ed689[_0x2fb226('0x715')][_0x2fb226('0x1b17')]=[];}function _0x3005fe(_0x34498e){const _0x2b184e=_0x5387cf,_0x9f26cb=['png',_0x2b184e('0x1cd0')];if(!_0x2cfb05()[_0x2b184e('0x1257')](_0x9f26cb,_0x34498e[_0x2b184e('0x26a5')]()))return _0x4fe2d9[_0x2b184e('0xfc9')]({'title':'Invalid\x20extension:\x20'+_0x34498e['getExtension'](),'msg':_0x2b184e('0x1020')+_0x9f26cb[_0x2b184e('0x45a')]()}),![];if(_0x34498e['size']>_0x2dfb7a)return _0x4fe2d9[_0x2b184e('0xfc9')]({'title':_0x2b184e('0x11e6'),'msg':_0x2b184e('0x12c0')+_0x397219+'MB'}),![];const _0x5e96c2={'id':_0x34498e[_0x2b184e('0x20f4')],'file':_0x34498e,'type':_0x2b184e('0x32f')};return _0x5ed689[_0x2b184e('0x715')]['images']['unshift'](_0x5e96c2),!![];}function _0x934d8a(){const _0x2a7965=_0x5387cf;_0x5ed689[_0x2a7965('0xe57')]['flow']['opts'][_0x2a7965('0x5fb')]={'X-Requested-With':_0x2a7965('0x1bc1'),'Authorization':_0x2a7965('0x24d4')+_0x45bfa2[_0x2a7965('0xd83')](_0x2a7965('0x10b6'))},_0x5ed689[_0x2a7965('0xe57')][_0x2a7965('0x13d1')][_0x2a7965('0x1d40')]();}function _0x21f841(_0x413dd7){const _0x340a4a=_0x5387cf;angular[_0x340a4a('0x2782')](_0x5ed689[_0x340a4a('0x715')][_0x340a4a('0x1b17')],function(_0x40b07d){const _0x438e56=_0x340a4a;if(_0x40b07d['id']===_0x413dd7[_0x438e56('0x20f4')]){const _0x371da0=new FileReader();_0x371da0[_0x438e56('0x2030')](_0x40b07d['file'][_0x438e56('0x6bd')]),_0x371da0[_0x438e56('0x15d4')]=function(_0x2dd092){const _0x427cce=_0x438e56;_0x40b07d[_0x427cce('0xcac')]=_0x2dd092[_0x427cce('0x21cc')][_0x427cce('0x15b5')];},_0x40b07d[_0x438e56('0x1345')]='image';}});}}const _0x30c2bb=_0x2afd79;_0x5ef26d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xa0b'),'general',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),'crudPermissions'];function _0x5ef26d(_0x2be9a2,_0x2443e7,_0x53cab7,_0x57a8db,_0x23f9d0,_0x2f25ee,_0x499199,_0x3b4032,_0x495698,_0xe974f6,_0x237d8a,_0x23dee9,_0x2eea7c,_0x23a4e0){const _0x2e62d7=_0x36e6f4,_0x10272a=this;_0x10272a[_0x2e62d7('0x98')]=_0x237d8a['getCurrentUser'](),_0x10272a[_0x2e62d7('0x61a')]=[],_0x10272a[_0x2e62d7('0xf8a')]=_0x2eea7c,_0x10272a[_0x2e62d7('0x5c9')]=_0x23dee9,_0x10272a[_0x2e62d7('0x243c')]=_0x23a4e0,_0x10272a[_0x2e62d7('0x128b')]={},_0x10272a['passwordPattern']=_0x10272a['setting']&&_0x10272a[_0x2e62d7('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x10272a['title']=_0x2e62d7('0x1f6d'),_0x10272a[_0x2e62d7('0x1718')]=angular[_0x2e62d7('0x225f')](_0x495698),_0x10272a[_0x2e62d7('0xa0b')]=_0x3b4032,_0x10272a[_0x2e62d7('0x2713')]=![];!_0x10272a[_0x2e62d7('0x1718')]&&(_0x10272a[_0x2e62d7('0x1718')]={'min_internal':0x3e8,'chatTimeout':0x1e,'phoneBarAutoUpdater':!![],'phoneBarAutoUpdaterUrl':_0x2e62d7('0x192d'),'splitSizeCsv':0x1388,'splitSizePdf':0x3e8,'splitSizeXlsx':0x1388,'messagesAlignment':_0x2e62d7('0x25f7'),'phoneBarRememberMeEnabled':!![],'allowedLoginAttempts':0x5,'blockDuration':0xa,'loginMailFrequency':0xa,'enforcePasswordHistory':!![],'passwordHistoryLimit':0x3},_0x10272a[_0x2e62d7('0xcdc')]='SETTINGS.NEW_GENERAL',_0x10272a[_0x2e62d7('0x2713')]=!![]);_0x10272a[_0x2e62d7('0x55f')]=_0x10853a,_0x10272a['saveGeneral']=_0x452d6b,_0x10272a[_0x2e62d7('0x2622')]=_0x31ab60,_0x10272a[_0x2e62d7('0x1a9c')]=_0xe7c233,_0x10272a[_0x2e62d7('0x24a0')]=_0x520f94,_0xe974f6[_0x2e62d7('0x16c6')]['get']({'fields':_0x2e62d7('0x1776'),'sort':_0x2e62d7('0x4f0'),'nolimit':_0x2e62d7('0xf3b')})['$promise'][_0x2e62d7('0x1166')](function(_0x5e5de4){const _0x2b2d65=_0x2e62d7;_0x10272a[_0x2b2d65('0x1913')]=_0x5e5de4[_0x2b2d65('0x269a')]||[];})[_0x2e62d7('0x1a80')](function(_0x5dc246){const _0x2d3764=_0x2e62d7;_0x499199[_0x2d3764('0xfc9')]({'title':_0x5dc246['status']?_0x2d3764('0x1e21')+_0x5dc246[_0x2d3764('0x52d')]+_0x2d3764('0x11e1')+_0x5dc246[_0x2d3764('0xe1b')]:'SYSTEM:GET_CLOUDPROVIDERS','msg':_0x5dc246[_0x2d3764('0x25f4')]?JSON[_0x2d3764('0xbac')](_0x5dc246[_0x2d3764('0x25f4')]):_0x5dc246[_0x2d3764('0x1586')]()});});function _0x10853a(){const _0x572afc=_0x2e62d7;_0x10272a[_0x572afc('0x61a')]=[],_0xe974f6[_0x572afc('0xf8a')][_0x572afc('0x9cc')](_0x10272a[_0x572afc('0x1718')])[_0x572afc('0xa44')][_0x572afc('0x1166')](function(_0x422e18){const _0x5cc0b7=_0x572afc;_0x10272a[_0x5cc0b7('0xa0b')]['unshift'](_0x422e18['toJSON']()),_0x499199[_0x5cc0b7('0x103b')]({'title':_0x5cc0b7('0x21df'),'msg':_0x10272a['general'][_0x5cc0b7('0x4f0')]?_0x10272a[_0x5cc0b7('0x1718')][_0x5cc0b7('0x4f0')]+_0x5cc0b7('0x1eda'):''}),_0x520f94(_0x422e18);})[_0x572afc('0x1a80')](function(_0x4a8f93){const _0x224cd2=_0x572afc;if(_0x4a8f93[_0x224cd2('0x25f4')]&&_0x4a8f93[_0x224cd2('0x25f4')][_0x224cd2('0x61a')]&&_0x4a8f93[_0x224cd2('0x25f4')][_0x224cd2('0x61a')][_0x224cd2('0x264b')]){_0x10272a[_0x224cd2('0x61a')]=_0x4a8f93[_0x224cd2('0x25f4')][_0x224cd2('0x61a')]||[{'message':_0x4a8f93[_0x224cd2('0x1586')](),'type':_0x224cd2('0x17fc')}];for(let _0x2afd47=0x0;_0x2afd47<_0x4a8f93[_0x224cd2('0x25f4')][_0x224cd2('0x61a')]['length'];_0x2afd47+=0x1){_0x499199[_0x224cd2('0xfc9')]({'title':_0x4a8f93[_0x224cd2('0x25f4')][_0x224cd2('0x61a')][_0x2afd47][_0x224cd2('0x1345')],'msg':_0x4a8f93[_0x224cd2('0x25f4')]['errors'][_0x2afd47][_0x224cd2('0x1e70')]});}}else _0x499199[_0x224cd2('0xfc9')]({'title':_0x4a8f93[_0x224cd2('0x52d')]?_0x224cd2('0x1e21')+_0x4a8f93[_0x224cd2('0x52d')]+_0x224cd2('0x11e1')+_0x4a8f93[_0x224cd2('0xe1b')]:_0x224cd2('0x17fc'),'msg':_0x4a8f93['data']?JSON[_0x224cd2('0xbac')](_0x4a8f93[_0x224cd2('0x25f4')]['message']):_0x4a8f93[_0x224cd2('0x1586')]()});});}function _0x452d6b(){const _0x4619fc=_0x2e62d7;_0x10272a['errors']=[],_0xe974f6['setting'][_0x4619fc('0x1449')]({'id':_0x10272a[_0x4619fc('0x1718')]['id']},_0x10272a[_0x4619fc('0x1718')])[_0x4619fc('0xa44')][_0x4619fc('0x1166')](function(_0x4c2e25){const _0x435af7=_0x4619fc,_0x2fce30=_0x2cfb05()[_0x435af7('0xc38')](_0x10272a['generals'],{'id':_0x4c2e25['id']});_0x2fce30&&_0x2cfb05()[_0x435af7('0xcc3')](_0x2fce30,_0x2cfb05()[_0x435af7('0x1a08')](_0x4c2e25[_0x435af7('0x2876')](),_0x2cfb05()[_0x435af7('0x14a4')](_0x2fce30))),_0x499199['success']({'title':_0x435af7('0x34d'),'msg':_0x10272a[_0x435af7('0x1718')][_0x435af7('0x4f0')]?_0x10272a['general']['name']+_0x435af7('0x7d'):''}),_0x520f94(_0x4c2e25);})['catch'](function(_0x4e1a9d){const _0x5b11db=_0x4619fc;if(_0x4e1a9d[_0x5b11db('0x25f4')]&&_0x4e1a9d[_0x5b11db('0x25f4')][_0x5b11db('0x61a')]&&_0x4e1a9d[_0x5b11db('0x25f4')][_0x5b11db('0x61a')][_0x5b11db('0x264b')]){_0x10272a[_0x5b11db('0x61a')]=_0x4e1a9d[_0x5b11db('0x25f4')][_0x5b11db('0x61a')]||[{'message':_0x4e1a9d['toString'](),'type':_0x5b11db('0xb53')}];for(let _0x4b9efc=0x0;_0x4b9efc<_0x4e1a9d[_0x5b11db('0x25f4')][_0x5b11db('0x61a')][_0x5b11db('0x264b')];_0x4b9efc++){_0x499199[_0x5b11db('0xfc9')]({'title':_0x4e1a9d[_0x5b11db('0x25f4')]['errors'][_0x4b9efc][_0x5b11db('0x1345')],'msg':_0x4e1a9d[_0x5b11db('0x25f4')][_0x5b11db('0x61a')][_0x4b9efc][_0x5b11db('0x1e70')]});}}else _0x499199[_0x5b11db('0xfc9')]({'title':_0x4e1a9d['status']?_0x5b11db('0x1e21')+_0x4e1a9d['status']+_0x5b11db('0x11e1')+_0x4e1a9d[_0x5b11db('0xe1b')]:_0x5b11db('0xb53'),'msg':_0x4e1a9d[_0x5b11db('0x25f4')]?JSON[_0x5b11db('0xbac')](_0x4e1a9d['data'][_0x5b11db('0x1e70')]):_0x4e1a9d[_0x5b11db('0x1586')]()});});}function _0x31ab60(_0x1ac418){const _0x4be7f0=_0x2e62d7;_0x10272a['errors']=[];const _0x2f4738=_0x57a8db[_0x4be7f0('0x1d26')]()[_0x4be7f0('0xcdc')](_0x4be7f0('0x7fb'))[_0x4be7f0('0xacc')](_0x4be7f0('0x8f7'))[_0x4be7f0('0x8e8')](_0x4be7f0('0x550'))['ok'](_0x4be7f0('0x18'))[_0x4be7f0('0x3f')](_0x4be7f0('0x497'))['targetEvent'](_0x1ac418);_0x57a8db[_0x4be7f0('0x1f80')](_0x2f4738)[_0x4be7f0('0x1166')](function(){const _0xf1b3f6=_0x4be7f0;_0xe974f6['setting'][_0xf1b3f6('0x906')]({'id':_0x10272a[_0xf1b3f6('0x1718')]['id']})['$promise']['then'](function(){const _0x370cec=_0xf1b3f6;_0x2cfb05()['remove'](_0x10272a[_0x370cec('0xa0b')],{'id':_0x10272a[_0x370cec('0x1718')]['id']}),_0x499199[_0x370cec('0x103b')]({'title':_0x370cec('0x195e'),'msg':(_0x10272a[_0x370cec('0x1718')]['name']||'general')+_0x370cec('0x7cd')}),_0x520f94(_0x10272a[_0x370cec('0x1718')]);})['catch'](function(_0x1dc7cb){const _0x102384=_0xf1b3f6;if(_0x1dc7cb[_0x102384('0x25f4')]&&_0x1dc7cb['data'][_0x102384('0x61a')]&&_0x1dc7cb[_0x102384('0x25f4')][_0x102384('0x61a')][_0x102384('0x264b')]){_0x10272a[_0x102384('0x61a')]=_0x1dc7cb[_0x102384('0x25f4')][_0x102384('0x61a')]||[{'message':_0x1dc7cb['toString'](),'type':_0x102384('0x10af')}];for(let _0x2f8208=0x0;_0x2f8208<_0x1dc7cb[_0x102384('0x25f4')]['errors'][_0x102384('0x264b')];_0x2f8208++){_0x499199['error']({'title':_0x1dc7cb[_0x102384('0x25f4')][_0x102384('0x61a')][_0x2f8208][_0x102384('0x1345')],'msg':_0x1dc7cb[_0x102384('0x25f4')]['errors'][_0x2f8208][_0x102384('0x1e70')]});}}else _0x499199[_0x102384('0xfc9')]({'title':_0x1dc7cb[_0x102384('0x52d')]?_0x102384('0x1e21')+_0x1dc7cb[_0x102384('0x52d')]+'\x20-\x20'+_0x1dc7cb[_0x102384('0xe1b')]:_0x102384('0x10af'),'msg':_0x1dc7cb[_0x102384('0x25f4')]?JSON[_0x102384('0xbac')](_0x1dc7cb[_0x102384('0x25f4')]['message']):_0x1dc7cb[_0x102384('0x1e70')]||_0x1dc7cb['toString']()});});},function(){});}function _0xe7c233(_0x57b381){return _0x57b381===null?undefined:new Date(_0x57b381);}function _0x520f94(_0x438f30){_0x57a8db['hide'](_0x438f30);}}const _0x23e884=_0x5ef26d;_0x19263f[_0x36e6f4('0x1294')]=[_0x36e6f4('0xa0b'),_0x36e6f4('0x19e3'),'toasty','license',_0x36e6f4('0x21ef')];function _0x19263f(_0x58b3fa,_0x1e821c,_0x2357f7,_0x2e83ce,_0x25792a){const _0x1a356d=_0x36e6f4,_0x41e3f7=this;_0x41e3f7['currentUser']=_0x25792a[_0x1a356d('0x26cd')](),_0x41e3f7[_0x1a356d('0x5c9')]=_0x2e83ce,_0x41e3f7[_0x1a356d('0xa0b')]=_0x58b3fa,_0x41e3f7[_0x1a356d('0x1718')]={};_0x41e3f7[_0x1a356d('0xa0b')]&&_0x41e3f7['generals'][_0x1a356d('0x269a')]&&_0x41e3f7[_0x1a356d('0xa0b')][_0x1a356d('0x269a')][_0x1a356d('0x264b')]&&(_0x41e3f7[_0x1a356d('0x1718')]=_0x41e3f7[_0x1a356d('0xa0b')][_0x1a356d('0x269a')][0x0]);_0x1e821c[_0x1a356d('0x16c6')][_0x1a356d('0xd83')]({'fields':_0x1a356d('0x1776'),'sort':_0x1a356d('0x4f0'),'nolimit':_0x1a356d('0xf3b')})[_0x1a356d('0xa44')][_0x1a356d('0x1166')](function(_0x33eece){const _0x111468=_0x1a356d;_0x41e3f7[_0x111468('0x1913')]=_0x33eece[_0x111468('0x269a')]||[];})[_0x1a356d('0x1a80')](function(_0x3e5c7f){const _0xb953c3=_0x1a356d;_0x2357f7[_0xb953c3('0xfc9')]({'title':_0x3e5c7f[_0xb953c3('0x52d')]?_0xb953c3('0x1e21')+_0x3e5c7f[_0xb953c3('0x52d')]+_0xb953c3('0x11e1')+_0x3e5c7f[_0xb953c3('0xe1b')]:'SYSTEM:GET_CLOUDPROVIDERS','msg':_0x3e5c7f[_0xb953c3('0x25f4')]?JSON['stringify'](_0x3e5c7f[_0xb953c3('0x25f4')]):_0x3e5c7f[_0xb953c3('0x1586')]()});}),_0x41e3f7[_0x1a356d('0x25b9')]=_0xa3c478;function _0xa3c478(){const _0x1e7f02=_0x1a356d;_0x41e3f7[_0x1e7f02('0x1718')]['id']?_0x1e821c[_0x1e7f02('0xf8a')]['update']({'id':_0x41e3f7['general']['id']},_0x41e3f7['general'])[_0x1e7f02('0xa44')][_0x1e7f02('0x1166')](function(){const _0x28a1f4=_0x1e7f02;_0x2357f7['success']({'title':_0x28a1f4('0x1205'),'msg':_0x41e3f7[_0x28a1f4('0x1718')]['name']?_0x41e3f7[_0x28a1f4('0x1718')]['name']+'\x20has\x20been\x20updated!':''});})[_0x1e7f02('0x1a80')](function(_0x4c6abe){const _0x296a8a=_0x1e7f02;_0x2357f7['error']({'title':_0x4c6abe[_0x296a8a('0x52d')]?'API:'+_0x4c6abe[_0x296a8a('0x52d')]+_0x296a8a('0x11e1')+_0x4c6abe[_0x296a8a('0xe1b')]:_0x296a8a('0x1076'),'msg':_0x4c6abe[_0x296a8a('0x25f4')]?JSON[_0x296a8a('0xbac')](_0x4c6abe['data']):_0x4c6abe['toString']()});}):_0x1e821c['setting'][_0x1e7f02('0x9cc')](_0x41e3f7[_0x1e7f02('0x1718')])['$promise'][_0x1e7f02('0x1166')](function(_0x14de5e){const _0x22f15a=_0x1e7f02;_0x2cfb05()[_0x22f15a('0xcc3')](_0x41e3f7[_0x22f15a('0x1718')],_0x14de5e),_0x2357f7[_0x22f15a('0x103b')]({'title':'General\x20updated!','msg':_0x41e3f7[_0x22f15a('0x1718')][_0x22f15a('0x4f0')]?_0x41e3f7['general']['name']+_0x22f15a('0xa17'):''});})[_0x1e7f02('0x1a80')](function(_0x51dd7f){const _0x22284a=_0x1e7f02;_0x2357f7[_0x22284a('0xfc9')]({'title':_0x51dd7f['status']?_0x22284a('0x1e21')+_0x51dd7f['status']+_0x22284a('0x11e1')+_0x51dd7f[_0x22284a('0xe1b')]:'SYSTEM:GETsetting','msg':_0x51dd7f[_0x22284a('0x25f4')]?JSON[_0x22284a('0xbac')](_0x51dd7f[_0x22284a('0x25f4')]):_0x51dd7f[_0x22284a('0x1586')]()});});}}const _0x533527=_0x19263f;_0x14d70b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x7e'),'network',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x14d70b(_0x53012f,_0x1d4890,_0x3f8b24,_0x482e81,_0x5690db,_0x10b7a0,_0x5da8ab,_0x116d38,_0x36823d,_0x4c2ebd,_0x436935,_0x21d3fd,_0x105c93){const _0x3efea1=_0x36e6f4,_0x3dc2d9=this;_0x3dc2d9[_0x3efea1('0x98')]=_0x436935[_0x3efea1('0x26cd')](),_0x3dc2d9[_0x3efea1('0x61a')]=[],_0x3dc2d9['setting']=_0x105c93,_0x3dc2d9[_0x3efea1('0x5c9')]=_0x21d3fd,_0x3dc2d9[_0x3efea1('0x128b')]={},_0x3dc2d9[_0x3efea1('0x2900')]=_0x3dc2d9[_0x3efea1('0xf8a')]&&_0x3dc2d9['setting'][_0x3efea1('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3dc2d9['title']='SETTINGS.EDIT_NETWORK',_0x3dc2d9['network']=angular[_0x3efea1('0x225f')](_0x36823d),_0x3dc2d9[_0x3efea1('0x7e')]=_0x116d38,_0x3dc2d9[_0x3efea1('0x1469')]=![];!_0x3dc2d9[_0x3efea1('0x2638')]&&(_0x3dc2d9['network']={'type':_0x3efea1('0x2672')},_0x3dc2d9[_0x3efea1('0xcdc')]=_0x3efea1('0x1f8b'),_0x3dc2d9[_0x3efea1('0x1469')]=!![]);_0x3dc2d9[_0x3efea1('0x1ba4')]=_0x9a8e64,_0x3dc2d9[_0x3efea1('0x282f')]=_0x4c8ab3,_0x3dc2d9[_0x3efea1('0x1acf')]=_0x145fd1,_0x3dc2d9[_0x3efea1('0x1a9c')]=_0x4c64c4,_0x3dc2d9[_0x3efea1('0x24a0')]=_0x35b462;function _0x9a8e64(){const _0x4a7d3f=_0x3efea1;_0x3dc2d9[_0x4a7d3f('0x61a')]=[],_0x4c2ebd['network'][_0x4a7d3f('0x9cc')](_0x3dc2d9[_0x4a7d3f('0x2638')])[_0x4a7d3f('0xa44')][_0x4a7d3f('0x1166')](function(_0x1a73d3){const _0x4c3fc9=_0x4a7d3f;_0x3dc2d9[_0x4c3fc9('0x7e')][_0x4c3fc9('0x2450')](_0x1a73d3[_0x4c3fc9('0x2876')]()),_0x5da8ab[_0x4c3fc9('0x103b')]({'title':'Network\x20properly\x20created','msg':_0x3dc2d9[_0x4c3fc9('0x2638')]['name']?_0x3dc2d9['network']['name']+_0x4c3fc9('0x1eda'):''}),_0x35b462(_0x1a73d3);})[_0x4a7d3f('0x1a80')](function(_0x46a37c){const _0x2b5847=_0x4a7d3f;if(_0x46a37c[_0x2b5847('0x25f4')]&&_0x46a37c['data'][_0x2b5847('0x61a')]&&_0x46a37c[_0x2b5847('0x25f4')][_0x2b5847('0x61a')][_0x2b5847('0x264b')]){_0x3dc2d9[_0x2b5847('0x61a')]=_0x46a37c[_0x2b5847('0x25f4')][_0x2b5847('0x61a')]||[{'message':_0x46a37c['toString'](),'type':_0x2b5847('0xb47')}];for(let _0x24f70e=0x0;_0x24f70e<_0x46a37c[_0x2b5847('0x25f4')]['errors']['length'];_0x24f70e+=0x1){_0x5da8ab['error']({'title':_0x46a37c[_0x2b5847('0x25f4')][_0x2b5847('0x61a')][_0x24f70e][_0x2b5847('0x1345')],'msg':_0x46a37c['data']['errors'][_0x24f70e][_0x2b5847('0x1e70')]});}}else _0x5da8ab['error']({'title':_0x46a37c[_0x2b5847('0x52d')]?'API:'+_0x46a37c[_0x2b5847('0x52d')]+_0x2b5847('0x11e1')+_0x46a37c[_0x2b5847('0xe1b')]:_0x2b5847('0xb47'),'msg':_0x46a37c['data']?JSON[_0x2b5847('0xbac')](_0x46a37c[_0x2b5847('0x25f4')][_0x2b5847('0x1e70')]):_0x46a37c[_0x2b5847('0x1586')]()});});}function _0x4c8ab3(){const _0x47f954=_0x3efea1;_0x3dc2d9[_0x47f954('0x61a')]=[],_0x4c2ebd[_0x47f954('0x2638')][_0x47f954('0x1449')]({'id':_0x3dc2d9['network']['id']},_0x3dc2d9[_0x47f954('0x2638')])[_0x47f954('0xa44')][_0x47f954('0x1166')](function(_0x2aa613){const _0x33ebc5=_0x47f954,_0x8b82c0=_0x2cfb05()[_0x33ebc5('0xc38')](_0x3dc2d9['networks'],{'id':_0x2aa613['id']});_0x8b82c0&&_0x2cfb05()[_0x33ebc5('0xcc3')](_0x8b82c0,_0x2cfb05()[_0x33ebc5('0x1a08')](_0x2aa613[_0x33ebc5('0x2876')](),_0x2cfb05()['keys'](_0x8b82c0))),_0x5da8ab[_0x33ebc5('0x103b')]({'title':'Network\x20properly\x20saved!','msg':_0x3dc2d9['network'][_0x33ebc5('0x4f0')]?_0x3dc2d9[_0x33ebc5('0x2638')][_0x33ebc5('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x35b462(_0x2aa613);})[_0x47f954('0x1a80')](function(_0x209bc1){const _0x1bc2b3=_0x47f954;if(_0x209bc1[_0x1bc2b3('0x25f4')]&&_0x209bc1[_0x1bc2b3('0x25f4')][_0x1bc2b3('0x61a')]&&_0x209bc1['data'][_0x1bc2b3('0x61a')][_0x1bc2b3('0x264b')]){_0x3dc2d9['errors']=_0x209bc1[_0x1bc2b3('0x25f4')][_0x1bc2b3('0x61a')]||[{'message':_0x209bc1[_0x1bc2b3('0x1586')](),'type':_0x1bc2b3('0x2168')}];for(let _0x236984=0x0;_0x236984<_0x209bc1[_0x1bc2b3('0x25f4')][_0x1bc2b3('0x61a')][_0x1bc2b3('0x264b')];_0x236984++){_0x5da8ab[_0x1bc2b3('0xfc9')]({'title':_0x209bc1[_0x1bc2b3('0x25f4')][_0x1bc2b3('0x61a')][_0x236984]['type'],'msg':_0x209bc1['data']['errors'][_0x236984][_0x1bc2b3('0x1e70')]});}}else _0x5da8ab[_0x1bc2b3('0xfc9')]({'title':_0x209bc1['status']?_0x1bc2b3('0x1e21')+_0x209bc1[_0x1bc2b3('0x52d')]+_0x1bc2b3('0x11e1')+_0x209bc1[_0x1bc2b3('0xe1b')]:_0x1bc2b3('0x2168'),'msg':_0x209bc1[_0x1bc2b3('0x25f4')]?JSON[_0x1bc2b3('0xbac')](_0x209bc1[_0x1bc2b3('0x25f4')][_0x1bc2b3('0x1e70')]):_0x209bc1[_0x1bc2b3('0x1586')]()});});}function _0x145fd1(_0x4acbad){const _0x3998cf=_0x3efea1;_0x3dc2d9[_0x3998cf('0x61a')]=[];const _0x1219b9=_0x482e81[_0x3998cf('0x1d26')]()[_0x3998cf('0xcdc')](_0x3998cf('0x7fb'))[_0x3998cf('0xacc')](_0x3998cf('0x10f0'))[_0x3998cf('0x8e8')](_0x3998cf('0xa8f'))['ok']('Delete')['cancel'](_0x3998cf('0x497'))['targetEvent'](_0x4acbad);_0x482e81[_0x3998cf('0x1f80')](_0x1219b9)[_0x3998cf('0x1166')](function(){const _0x11178b=_0x3998cf;_0x4c2ebd[_0x11178b('0x2638')][_0x11178b('0x906')]({'id':_0x3dc2d9[_0x11178b('0x2638')]['id']})[_0x11178b('0xa44')][_0x11178b('0x1166')](function(){const _0x8918a8=_0x11178b;_0x2cfb05()[_0x8918a8('0x127f')](_0x3dc2d9[_0x8918a8('0x7e')],{'id':_0x3dc2d9['network']['id']}),_0x5da8ab['success']({'title':'Network\x20properly\x20deleted!','msg':(_0x3dc2d9['network'][_0x8918a8('0x4f0')]||_0x8918a8('0x2638'))+_0x8918a8('0x7cd')}),_0x35b462(_0x3dc2d9[_0x8918a8('0x2638')]);})['catch'](function(_0x4a396a){const _0x4bad14=_0x11178b;if(_0x4a396a[_0x4bad14('0x25f4')]&&_0x4a396a[_0x4bad14('0x25f4')]['errors']&&_0x4a396a[_0x4bad14('0x25f4')]['errors'][_0x4bad14('0x264b')]){_0x3dc2d9[_0x4bad14('0x61a')]=_0x4a396a['data'][_0x4bad14('0x61a')]||[{'message':_0x4a396a[_0x4bad14('0x1586')](),'type':_0x4bad14('0x1436')}];for(let _0x58f173=0x0;_0x58f173<_0x4a396a[_0x4bad14('0x25f4')][_0x4bad14('0x61a')][_0x4bad14('0x264b')];_0x58f173++){_0x5da8ab[_0x4bad14('0xfc9')]({'title':_0x4a396a['data'][_0x4bad14('0x61a')][_0x58f173]['type'],'msg':_0x4a396a[_0x4bad14('0x25f4')][_0x4bad14('0x61a')][_0x58f173][_0x4bad14('0x1e70')]});}}else _0x5da8ab[_0x4bad14('0xfc9')]({'title':_0x4a396a[_0x4bad14('0x52d')]?'API:'+_0x4a396a[_0x4bad14('0x52d')]+_0x4bad14('0x11e1')+_0x4a396a['statusText']:_0x4bad14('0x1436'),'msg':_0x4a396a['data']?JSON[_0x4bad14('0xbac')](_0x4a396a[_0x4bad14('0x25f4')][_0x4bad14('0x1e70')]):_0x4a396a[_0x4bad14('0x1e70')]||_0x4a396a[_0x4bad14('0x1586')]()});});},function(){});}function _0x4c64c4(_0x29f0ff){return _0x29f0ff===null?undefined:new Date(_0x29f0ff);}function _0x35b462(_0x4f33f1){const _0x42cf4a=_0x3efea1;_0x482e81[_0x42cf4a('0x1197')](_0x4f33f1);}}const _0x5a9cb5=_0x14d70b,_0x134247=_0x2734b2['p']+_0x36e6f4('0xb6e');_0x33b624[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x7e'),'api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x5c9'),'setting'];function _0x33b624(_0x41b65e,_0x3aab9b,_0x5b265d,_0x12c14b,_0x1b9e6d,_0x2db8ce,_0x1f21b9,_0x46b16d,_0x42e48d,_0x2366f3,_0x12a00c,_0x35740c,_0x47cb18,_0x491fb9,_0x13ada2){const _0x2b902f=_0x36e6f4,_0x2029c2=this;_0x2029c2['license']=_0x491fb9,_0x2029c2['setting']=_0x13ada2,_0x2029c2[_0x2b902f('0x98')]=_0x47cb18['getCurrentUser'](),_0x2029c2[_0x2b902f('0x7e')]=_0x42e48d||{'count':0x0,'rows':[]},_0x2029c2[_0x2b902f('0x916')]=_0x2b902f('0x7e'),_0x2029c2[_0x2b902f('0xef5')]='',_0x2029c2[_0x2b902f('0x104c')]=null,_0x2029c2[_0x2b902f('0x2610')]=[],_0x2029c2[_0x2b902f('0x2218')]={'fields':_0x2b902f('0x1297'),'sort':_0x2b902f('0x14dc'),'limit':0xa,'page':0x1},_0x2029c2[_0x2b902f('0x2736')]=_0x2cfb05()[_0x2b902f('0x155c')]([{'option':_0x2b902f('0x20f0'),'value':'\x27localnet\x27'},{'option':_0x2b902f('0x1fb6'),'value':_0x2b902f('0x2104')},{'option':'Turn','value':_0x2b902f('0x231d')},{'option':_0x2b902f('0x228a'),'value':_0x2b902f('0xf8c')}],function(_0x496dd3){const _0x2bc404=_0x2b902f;return _0x2cfb05()[_0x2bc404('0xf3')](_0x496dd3[_0x2bc404('0x18e0')],new RegExp('\x27','g'),'');}),_0x2029c2[_0x2b902f('0x1f8e')]=_0x4fa617,_0x2029c2[_0x2b902f('0x8d8')]=_0x424451,_0x2029c2[_0x2b902f('0x103b')]=_0x5a7673,_0x2029c2['getNetworks']=_0x2bc908,_0x2029c2[_0x2b902f('0x1c20')]=_0x4be944,_0x2029c2['deleteNetwork']=_0x87d572,_0x2029c2['exportSelectedNetworks']=_0x5f25d1,_0x2029c2[_0x2b902f('0x1088')]=_0x16840c,_0x2029c2[_0x2b902f('0x7f6')]=_0x8b3297,_0x2029c2['selectAllNetworks']=_0x2094e1;function _0x4fa617(_0x470b98,_0x2155d8){const _0x293580=_0x2b902f;_0x1b9e6d[_0x293580('0x1f80')]({'controller':_0x293580('0x4a6'),'controllerAs':'vm','templateUrl':_0x134247,'parent':angular[_0x293580('0x1194')](_0x2db8ce[_0x293580('0x8d2')]),'targetEvent':_0x2155d8,'clickOutsideToClose':!![],'locals':{'network':_0x470b98,'networks':_0x2029c2[_0x293580('0x7e')][_0x293580('0x269a')],'license':_0x2029c2[_0x293580('0x5c9')],'setting':null,'crudPermissions':_0x2029c2[_0x293580('0x243c')]}});}function _0x424451(_0x9f47bd,_0x1f1c39){const _0x3c1c40=_0x2b902f,_0x1fc650=_0x1b9e6d[_0x3c1c40('0x1d26')]()[_0x3c1c40('0xcdc')](_0x3c1c40('0x288d')+_0x2cfb05()[_0x3c1c40('0xb35')](_0x3c1c40('0x2638'))+'?')[_0x3c1c40('0xf3c')](_0x3c1c40('0x12b5')+(_0x9f47bd[_0x3c1c40('0x4f0')]||'network')+'
'+_0x3c1c40('0x3f3'))[_0x3c1c40('0x8e8')](_0x3c1c40('0x1a1c'))[_0x3c1c40('0x203b')](_0x1f1c39)['ok']('OK')[_0x3c1c40('0x3f')](_0x3c1c40('0x2d3'));_0x1b9e6d[_0x3c1c40('0x1f80')](_0x1fc650)[_0x3c1c40('0x1166')](function(){_0x87d572(_0x9f47bd);},function(){const _0x487098=_0x3c1c40;console['log'](_0x487098('0x2d3'));});}let _0x3e1f16=!![],_0x50ad1b=0x1;_0x41b65e[_0x2b902f('0xe83')](_0x2b902f('0x12d8'),function(_0x134af7,_0x34322b){const _0x162af9=_0x2b902f;_0x3e1f16?_0x1f21b9(function(){_0x3e1f16=![];}):(!_0x34322b&&(_0x50ad1b=_0x2029c2[_0x162af9('0x2218')][_0x162af9('0x1a43')]),_0x134af7!==_0x34322b&&(_0x2029c2[_0x162af9('0x2218')]['page']=0x1),!_0x134af7&&(_0x2029c2[_0x162af9('0x2218')][_0x162af9('0x1a43')]=_0x50ad1b),_0x2029c2['getNetworks']());});function _0x5a7673(_0x32b0d2){_0x2029c2['networks']=_0x32b0d2||{'count':0x0,'rows':[]};}function _0x2bc908(){const _0x2810e5=_0x2b902f;_0x2029c2[_0x2810e5('0x2218')]['offset']=(_0x2029c2[_0x2810e5('0x2218')][_0x2810e5('0x1a43')]-0x1)*_0x2029c2['query'][_0x2810e5('0x163f')],_0x47cb18[_0x2810e5('0x1ac6')]('admin')?_0x2029c2['promise']=_0x2366f3[_0x2810e5('0x2638')][_0x2810e5('0xd83')](_0x2029c2[_0x2810e5('0x2218')],_0x5a7673)[_0x2810e5('0xa44')]:(_0x2029c2[_0x2810e5('0x2218')]['id']=_0x2029c2['userProfile']['id'],_0x2029c2[_0x2810e5('0x2218')][_0x2810e5('0xe60')]=_0x2810e5('0x2b4'),_0x2029c2[_0x2810e5('0x1f48')]=_0x2366f3[_0x2810e5('0x7f')]['getResources'](_0x2029c2['query'],_0x5a7673)['$promise']);}function _0x4be944(_0x475f1b,_0x25f2cb){const _0x26113c=_0x2b902f;_0x1b9e6d[_0x26113c('0x1f80')]({'controller':_0x26113c('0x4a6'),'controllerAs':'vm','templateUrl':_0x134247,'parent':angular[_0x26113c('0x1194')](_0x2db8ce[_0x26113c('0x8d2')]),'targetEvent':_0x475f1b,'clickOutsideToClose':!![],'locals':{'network':_0x25f2cb,'networks':_0x2029c2[_0x26113c('0x7e')]['rows'],'license':_0x2029c2[_0x26113c('0x5c9')],'setting':_0x2029c2['setting'],'crudPermissions':_0x2029c2['crudPermissions']}});}function _0x87d572(_0x522c4f){const _0x2c41a2=_0x2b902f;_0x2366f3['network'][_0x2c41a2('0x906')]({'id':_0x522c4f['id']})[_0x2c41a2('0xa44')][_0x2c41a2('0x1166')](function(){const _0x14bb0e=_0x2c41a2;_0x2cfb05()[_0x14bb0e('0x127f')](_0x2029c2['networks'][_0x14bb0e('0x269a')],{'id':_0x522c4f['id']}),_0x2029c2['networks']['count']-=0x1,!_0x2029c2[_0x14bb0e('0x7e')][_0x14bb0e('0x269a')]['length']&&_0x2029c2['getNetworks'](),_0x35740c[_0x14bb0e('0x103b')]({'title':_0x2cfb05()[_0x14bb0e('0xb35')](_0x14bb0e('0x233b'))+_0x14bb0e('0x2b6'),'msg':_0x522c4f[_0x14bb0e('0x4f0')]?_0x522c4f['name']+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x322b2c){const _0x1a5626=_0x2c41a2;if(_0x322b2c[_0x1a5626('0x25f4')]&&_0x322b2c[_0x1a5626('0x25f4')][_0x1a5626('0x61a')]&&_0x322b2c[_0x1a5626('0x25f4')][_0x1a5626('0x61a')]['length']){_0x2029c2[_0x1a5626('0x61a')]=_0x322b2c[_0x1a5626('0x25f4')][_0x1a5626('0x61a')]||[{'message':_0x322b2c[_0x1a5626('0x1586')](),'type':'SYSTEM:DELETEnetwork'}];for(let _0x1c8c5f=0x0;_0x1c8c5f<_0x322b2c[_0x1a5626('0x25f4')][_0x1a5626('0x61a')]['length'];_0x1c8c5f++){_0x35740c['error']({'title':_0x322b2c[_0x1a5626('0x25f4')][_0x1a5626('0x61a')][_0x1c8c5f][_0x1a5626('0x1345')],'msg':_0x322b2c[_0x1a5626('0x25f4')][_0x1a5626('0x61a')][_0x1c8c5f][_0x1a5626('0x1e70')]});}}else _0x35740c[_0x1a5626('0xfc9')]({'title':_0x322b2c['status']?_0x1a5626('0x1e21')+_0x322b2c['status']+'\x20-\x20'+_0x322b2c[_0x1a5626('0xe1b')]:_0x1a5626('0x106c'),'msg':_0x322b2c[_0x1a5626('0x25f4')]?JSON['stringify'](_0x322b2c['data'][_0x1a5626('0x1e70')]):_0x322b2c[_0x1a5626('0x1e70')]||_0x322b2c[_0x1a5626('0x1586')]()});});}function _0x5f25d1(){const _0x3f6c06=_0x2b902f,_0x38f3c3=angular[_0x3f6c06('0x225f')](_0x2029c2[_0x3f6c06('0x2610')]);return _0x2029c2[_0x3f6c06('0x2610')]=[],_0x38f3c3;}function _0x16840c(_0x328ac7){const _0x4981b6=_0x2b902f,_0x32ba08=_0x1b9e6d[_0x4981b6('0x1d26')]()['title'](_0x4981b6('0x26d6'))[_0x4981b6('0xf3c')](_0x4981b6('0x12b5')+_0x2029c2[_0x4981b6('0x2610')][_0x4981b6('0x264b')]+'\x20selected
'+_0x4981b6('0x3f3'))['ariaLabel'](_0x4981b6('0x988'))[_0x4981b6('0x203b')](_0x328ac7)['ok']('OK')['cancel'](_0x4981b6('0x2d3'));_0x1b9e6d[_0x4981b6('0x1f80')](_0x32ba08)[_0x4981b6('0x1166')](function(){const _0x51c739=_0x4981b6;_0x2029c2[_0x51c739('0x2610')][_0x51c739('0x2782')](function(_0x2e8624){_0x87d572(_0x2e8624);}),_0x2029c2['selectedNetworks']=[];});}function _0x8b3297(){const _0x3cd14b=_0x2b902f;_0x2029c2[_0x3cd14b('0x2610')]=[];}function _0x2094e1(){const _0x4d423d=_0x2b902f;_0x2029c2['selectedNetworks']=_0x2029c2[_0x4d423d('0x7e')][_0x4d423d('0x269a')];}}const _0x2023b9=_0x33b624;_0x40177d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x15b2'),'smtp','api','Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x40177d(_0x432adb,_0x34432c,_0x369aef,_0x57cb4f,_0x4df935,_0xd7f137,_0xbc7dc0,_0x3e336c,_0x15b788,_0x40108b,_0x2c16ae,_0x2b1385,_0x22f70b,_0xe4124a){const _0x3e7f93=_0x36e6f4,_0x55d8d2=this;_0x55d8d2[_0x3e7f93('0x98')]=_0x2c16ae[_0x3e7f93('0x26cd')](),_0x55d8d2[_0x3e7f93('0x61a')]=[],_0x55d8d2['setting']=_0x22f70b,_0x55d8d2[_0x3e7f93('0x5c9')]=_0x2b1385,_0x55d8d2[_0x3e7f93('0x243c')]=_0xe4124a,_0x55d8d2[_0x3e7f93('0x128b')]={},_0x55d8d2[_0x3e7f93('0x2900')]=_0x55d8d2[_0x3e7f93('0xf8a')]&&_0x55d8d2[_0x3e7f93('0xf8a')][_0x3e7f93('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x55d8d2[_0x3e7f93('0xcdc')]=_0x3e7f93('0x1645'),_0x55d8d2[_0x3e7f93('0x1ed7')]=angular['copy'](_0x15b788),_0x55d8d2[_0x3e7f93('0x15b2')]=_0x3e336c,_0x55d8d2[_0x3e7f93('0x533')]=![];!_0x55d8d2[_0x3e7f93('0x1ed7')]&&(_0x55d8d2[_0x3e7f93('0x1ed7')]={'service':!![]},_0x55d8d2[_0x3e7f93('0xcdc')]='SETTINGS.NEW_SMTP',_0x55d8d2['newSmtp']=!![]);_0x55d8d2[_0x3e7f93('0x10a3')]=_0x44b8aa,_0x55d8d2['saveSmtp']=_0x3fa571,_0x55d8d2[_0x3e7f93('0x14bb')]=_0x522139,_0x55d8d2[_0x3e7f93('0x1a9c')]=_0x205d9d,_0x55d8d2[_0x3e7f93('0x24a0')]=_0x5ce013;function _0x44b8aa(){const _0x60f6ed=_0x3e7f93;_0x55d8d2[_0x60f6ed('0x61a')]=[],_0x40108b[_0x60f6ed('0x21b9')][_0x60f6ed('0x9cc')](_0x55d8d2[_0x60f6ed('0x1ed7')])[_0x60f6ed('0xa44')][_0x60f6ed('0x1166')](function(_0x7e38e1){const _0x5a5149=_0x60f6ed;_0x55d8d2[_0x5a5149('0x15b2')][_0x5a5149('0x2450')](_0x7e38e1[_0x5a5149('0x2876')]()),_0xbc7dc0[_0x5a5149('0x103b')]({'title':_0x5a5149('0xc58'),'msg':_0x55d8d2[_0x5a5149('0x1ed7')][_0x5a5149('0x4f0')]?_0x55d8d2[_0x5a5149('0x1ed7')][_0x5a5149('0x4f0')]+_0x5a5149('0x1eda'):''}),_0x5ce013(_0x7e38e1);})[_0x60f6ed('0x1a80')](function(_0x30ee0b){const _0x406bb1=_0x60f6ed;if(_0x30ee0b[_0x406bb1('0x25f4')]&&_0x30ee0b['data'][_0x406bb1('0x61a')]&&_0x30ee0b[_0x406bb1('0x25f4')][_0x406bb1('0x61a')][_0x406bb1('0x264b')]){_0x55d8d2['errors']=_0x30ee0b[_0x406bb1('0x25f4')][_0x406bb1('0x61a')]||[{'message':_0x30ee0b['toString'](),'type':'api.mailAccount.save'}];for(let _0x124e6d=0x0;_0x124e6d<_0x30ee0b[_0x406bb1('0x25f4')][_0x406bb1('0x61a')][_0x406bb1('0x264b')];_0x124e6d+=0x1){_0xbc7dc0['error']({'title':_0x30ee0b[_0x406bb1('0x25f4')][_0x406bb1('0x61a')][_0x124e6d]['type'],'msg':_0x30ee0b['data'][_0x406bb1('0x61a')][_0x124e6d][_0x406bb1('0x1e70')]});}}else _0xbc7dc0[_0x406bb1('0xfc9')]({'title':_0x30ee0b[_0x406bb1('0x52d')]?_0x406bb1('0x1e21')+_0x30ee0b[_0x406bb1('0x52d')]+_0x406bb1('0x11e1')+_0x30ee0b[_0x406bb1('0xe1b')]:_0x406bb1('0x211b'),'msg':_0x30ee0b[_0x406bb1('0x25f4')]?JSON['stringify'](_0x30ee0b[_0x406bb1('0x25f4')]['message']):_0x30ee0b[_0x406bb1('0x1586')]()});});}function _0x3fa571(){const _0x5e23d9=_0x3e7f93;_0x55d8d2[_0x5e23d9('0x61a')]=[],_0x40108b[_0x5e23d9('0x21b9')]['update']({'id':_0x55d8d2[_0x5e23d9('0x1ed7')]['id']},_0x55d8d2[_0x5e23d9('0x1ed7')])[_0x5e23d9('0xa44')]['then'](function(_0x3b40e1){const _0x2bc26a=_0x5e23d9,_0x52bea9=_0x2cfb05()[_0x2bc26a('0xc38')](_0x55d8d2[_0x2bc26a('0x15b2')],{'id':_0x3b40e1['id']});_0x52bea9&&_0x2cfb05()[_0x2bc26a('0xcc3')](_0x52bea9,_0x2cfb05()[_0x2bc26a('0x1a08')](_0x3b40e1[_0x2bc26a('0x2876')](),_0x2cfb05()[_0x2bc26a('0x14a4')](_0x52bea9))),_0xbc7dc0[_0x2bc26a('0x103b')]({'title':_0x2bc26a('0xb1d'),'msg':_0x55d8d2[_0x2bc26a('0x1ed7')][_0x2bc26a('0x4f0')]?_0x55d8d2['smtp']['name']+_0x2bc26a('0x7d'):''}),_0x5ce013(_0x3b40e1);})[_0x5e23d9('0x1a80')](function(_0x3f4165){const _0x532cef=_0x5e23d9;if(_0x3f4165[_0x532cef('0x25f4')]&&_0x3f4165[_0x532cef('0x25f4')][_0x532cef('0x61a')]&&_0x3f4165[_0x532cef('0x25f4')][_0x532cef('0x61a')][_0x532cef('0x264b')]){_0x55d8d2['errors']=_0x3f4165['data'][_0x532cef('0x61a')]||[{'message':_0x3f4165['toString'](),'type':_0x532cef('0x2750')}];for(let _0x1fc610=0x0;_0x1fc610<_0x3f4165['data']['errors'][_0x532cef('0x264b')];_0x1fc610++){_0xbc7dc0[_0x532cef('0xfc9')]({'title':_0x3f4165['data'][_0x532cef('0x61a')][_0x1fc610][_0x532cef('0x1345')],'msg':_0x3f4165[_0x532cef('0x25f4')]['errors'][_0x1fc610][_0x532cef('0x1e70')]});}}else _0xbc7dc0[_0x532cef('0xfc9')]({'title':_0x3f4165[_0x532cef('0x52d')]?_0x532cef('0x1e21')+_0x3f4165[_0x532cef('0x52d')]+_0x532cef('0x11e1')+_0x3f4165[_0x532cef('0xe1b')]:_0x532cef('0x2750'),'msg':_0x3f4165['data']?JSON['stringify'](_0x3f4165[_0x532cef('0x25f4')][_0x532cef('0x1e70')]):_0x3f4165[_0x532cef('0x1586')]()});});}function _0x522139(_0x24c876){const _0x232557=_0x3e7f93;_0x55d8d2[_0x232557('0x61a')]=[];const _0x106cb8=_0x57cb4f[_0x232557('0x1d26')]()[_0x232557('0xcdc')](_0x232557('0x7fb'))[_0x232557('0xacc')](_0x232557('0x1a30'))['ariaLabel'](_0x232557('0x11b3'))['ok']('Delete')[_0x232557('0x3f')](_0x232557('0x497'))['targetEvent'](_0x24c876);_0x57cb4f['show'](_0x106cb8)['then'](function(){const _0x13e2ce=_0x232557;_0x40108b['mailAccount'][_0x13e2ce('0x906')]({'id':_0x55d8d2[_0x13e2ce('0x1ed7')]['id']})[_0x13e2ce('0xa44')][_0x13e2ce('0x1166')](function(){const _0x57faaf=_0x13e2ce;_0x2cfb05()[_0x57faaf('0x127f')](_0x55d8d2[_0x57faaf('0x15b2')],{'id':_0x55d8d2['smtp']['id']}),_0xbc7dc0['success']({'title':_0x57faaf('0x1241'),'msg':(_0x55d8d2[_0x57faaf('0x1ed7')][_0x57faaf('0x4f0')]||'smtp')+_0x57faaf('0x7cd')}),_0x5ce013(_0x55d8d2[_0x57faaf('0x1ed7')]);})[_0x13e2ce('0x1a80')](function(_0x434f47){const _0x242d81=_0x13e2ce;if(_0x434f47[_0x242d81('0x25f4')]&&_0x434f47[_0x242d81('0x25f4')][_0x242d81('0x61a')]&&_0x434f47[_0x242d81('0x25f4')][_0x242d81('0x61a')][_0x242d81('0x264b')]){_0x55d8d2[_0x242d81('0x61a')]=_0x434f47[_0x242d81('0x25f4')][_0x242d81('0x61a')]||[{'message':_0x434f47[_0x242d81('0x1586')](),'type':_0x242d81('0x492')}];for(let _0x1e629f=0x0;_0x1e629f<_0x434f47[_0x242d81('0x25f4')][_0x242d81('0x61a')][_0x242d81('0x264b')];_0x1e629f++){_0xbc7dc0[_0x242d81('0xfc9')]({'title':_0x434f47['data'][_0x242d81('0x61a')][_0x1e629f]['type'],'msg':_0x434f47[_0x242d81('0x25f4')][_0x242d81('0x61a')][_0x1e629f]['message']});}}else _0xbc7dc0[_0x242d81('0xfc9')]({'title':_0x434f47[_0x242d81('0x52d')]?_0x242d81('0x1e21')+_0x434f47[_0x242d81('0x52d')]+_0x242d81('0x11e1')+_0x434f47[_0x242d81('0xe1b')]:_0x242d81('0x492'),'msg':_0x434f47[_0x242d81('0x25f4')]?JSON[_0x242d81('0xbac')](_0x434f47['data']['message']):_0x434f47[_0x242d81('0x1e70')]||_0x434f47[_0x242d81('0x1586')]()});});},function(){});}function _0x205d9d(_0x568e51){return _0x568e51===null?undefined:new Date(_0x568e51);}function _0x5ce013(_0x349dfb){_0x57cb4f['hide'](_0x349dfb);}}const _0x440824=_0x40177d;_0x2d54dd['$inject']=[_0x36e6f4('0x15b2'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x5c9'),'Auth'];function _0x2d54dd(_0x37bb92,_0x5c4392,_0x8e555d,_0x1c8bdb,_0x5c3db3){const _0x1bff6a=_0x36e6f4,_0x27fc8f=this;_0x27fc8f['currentUser']=_0x5c3db3[_0x1bff6a('0x26cd')](),_0x27fc8f[_0x1bff6a('0x5c9')]=_0x1c8bdb,_0x27fc8f[_0x1bff6a('0x15b2')]=_0x37bb92,_0x27fc8f[_0x1bff6a('0x1ed7')]={};_0x27fc8f[_0x1bff6a('0x15b2')]&&_0x27fc8f[_0x1bff6a('0x15b2')]['rows']&&_0x27fc8f['smtps']['rows']['length']?_0x27fc8f[_0x1bff6a('0x1ed7')]=_0x27fc8f[_0x1bff6a('0x15b2')][_0x1bff6a('0x269a')][0x0]:_0x27fc8f['smtp']={'service':!![],'Smtp':{'service':null}};_0x27fc8f[_0x1bff6a('0x5da')]=_0x18a220,_0x27fc8f[_0x1bff6a('0x1126')]=_0x4888cc;function _0x4888cc(){const _0x56c781=_0x1bff6a;_0x27fc8f['smtp']['id']&&_0x5c4392['mailAccount'][_0x56c781('0x1126')]({'id':_0x27fc8f[_0x56c781('0x1ed7')]['id']})[_0x56c781('0xa44')][_0x56c781('0x1166')](function(){const _0x1214ab=_0x56c781;_0x8e555d['success']({'title':_0x1214ab('0x22ce'),'msg':_0x27fc8f[_0x1214ab('0x1ed7')]['name']?_0x27fc8f[_0x1214ab('0x1ed7')]['name']+'\x20has\x20been\x20verified!':''});})[_0x56c781('0x1a80')](function(_0x36a26c){const _0x3f10a5=_0x56c781;_0x8e555d['error']({'title':_0x3f10a5('0x1b07'),'msg':_0x36a26c[_0x3f10a5('0x25f4')]?JSON[_0x3f10a5('0xbac')](_0x36a26c['data']):_0x36a26c[_0x3f10a5('0x1586')](),'timeout':0x2710});});}function _0x18a220(){const _0x4aac26=_0x1bff6a;_0x27fc8f[_0x4aac26('0x1ed7')]['id']?_0x5c4392['mailAccount']['update']({'id':_0x27fc8f[_0x4aac26('0x1ed7')]['id']},_0x27fc8f['smtp'])[_0x4aac26('0xa44')]['then'](function(){const _0x12b09d=_0x4aac26;_0x8e555d['success']({'title':'Smtp\x20updated!','msg':_0x27fc8f[_0x12b09d('0x1ed7')]['name']?_0x27fc8f[_0x12b09d('0x1ed7')]['name']+_0x12b09d('0xa17'):''});})[_0x4aac26('0x1a80')](function(_0x6ef241){const _0x5ec8f3=_0x4aac26;_0x8e555d[_0x5ec8f3('0xfc9')]({'title':_0x6ef241[_0x5ec8f3('0x52d')]?_0x5ec8f3('0x1e21')+_0x6ef241['status']+_0x5ec8f3('0x11e1')+_0x6ef241[_0x5ec8f3('0xe1b')]:_0x5ec8f3('0xabc'),'msg':_0x6ef241['data']?JSON[_0x5ec8f3('0xbac')](_0x6ef241[_0x5ec8f3('0x25f4')]):_0x6ef241['toString']()});}):_0x5c4392[_0x4aac26('0x21b9')]['save'](_0x27fc8f[_0x4aac26('0x1ed7')])['$promise']['then'](function(_0x3da14d){const _0xfa0ab1=_0x4aac26;_0x2cfb05()['merge'](_0x27fc8f[_0xfa0ab1('0x1ed7')],_0x3da14d),_0x8e555d['success']({'title':_0xfa0ab1('0xc0b'),'msg':_0x27fc8f[_0xfa0ab1('0x1ed7')][_0xfa0ab1('0x4f0')]?_0x27fc8f[_0xfa0ab1('0x1ed7')][_0xfa0ab1('0x4f0')]+_0xfa0ab1('0xa17'):''});})[_0x4aac26('0x1a80')](function(_0x12121f){const _0xf80101=_0x4aac26;_0x8e555d[_0xf80101('0xfc9')]({'title':_0x12121f['status']?_0xf80101('0x1e21')+_0x12121f[_0xf80101('0x52d')]+_0xf80101('0x11e1')+_0x12121f['statusText']:'SYSTEM:GETmailAccount','msg':_0x12121f[_0xf80101('0x25f4')]?JSON[_0xf80101('0xbac')](_0x12121f[_0xf80101('0x25f4')]):_0x12121f[_0xf80101('0x1586')]()});});}}const _0x1dc1f2=_0x2d54dd;_0x532118[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),'$translatePartialLoaderProvider'];function _0x532118(_0x2354e5,_0x49e18e){const _0xde5fc8=_0x36e6f4;_0x2354e5[_0xde5fc8('0x63f')](_0xde5fc8('0x224e'),{'abstract':!![],'url':_0xde5fc8('0x528')})[_0xde5fc8('0x63f')](_0xde5fc8('0x26a4'),{'url':'/generals','views':{'content@app':{'templateUrl':_0x266dc5,'controller':'GeneralsController\x20as\x20vm'}},'resolve':{'generals':['apiResolver',function(_0x5bfc0e){return _0x5bfc0e['resolve']('setting@get',{'fields':'createdAt,updatedAt,id,min_internal,securePassword,callRecordingEncryption,chatTimeout,phoneBarAutoUpdater,defaultScreenRecordingPath,phoneBarAutoUpdaterUrl,enableEmailPreview,split,splitSizeCsv,splitSizePdf,splitSizeXlsx,messagesAlignment,phoneBarRememberMeEnabled,rtlSupport,allowedLoginAttempts,blockDuration,loginMailFrequency,language,bucket,transcribe,transcribeRegion,transcribeAccountId,sentiment,sentimentRegion,sentimentAccountId,googleSsoEnabled,enforcePasswordHistory,passwordHistoryLimit','limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':_0xde5fc8('0x2017')})['state'](_0xde5fc8('0x2fa'),{'url':_0xde5fc8('0x131f'),'views':{'content@app':{'templateUrl':_0xc8551d,'controller':_0xde5fc8('0xe5a')}},'resolve':{'smtps':[_0xde5fc8('0x1fbc'),function(_0x299c9c){const _0xe7a99d=_0xde5fc8;return _0x299c9c[_0xe7a99d('0x18af')](_0xe7a99d('0x1d62'),{'fields':'createdAt,updatedAt,id,service,name,email,Smtp.service,Smtp.host,Smtp.port,Smtp.secure,Smtp.authentication,Smtp.user,Smtp.pass,description','service':'1','limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':_0xde5fc8('0x2017')})[_0xde5fc8('0x63f')](_0xde5fc8('0xb0b'),{'url':'/networks','views':{'content@app':{'templateUrl':_0x3ab858,'controller':'NetworksController\x20as\x20vm'}},'resolve':{'networks':[_0xde5fc8('0x1fbc'),function(_0x41486){const _0x5d5ad8=_0xde5fc8;return _0x41486[_0x5d5ad8('0x18af')](_0x5d5ad8('0x1ab6'),{'fields':_0x5d5ad8('0x1297'),'sort':_0x5d5ad8('0x14dc'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':_0xde5fc8('0x2017')})[_0xde5fc8('0x63f')]('app.settings.customizations',{'url':_0xde5fc8('0x1f34'),'views':{'content@app':{'templateUrl':_0x1c3de1,'controller':'CustomizationsController\x20as\x20vm'}},'resolve':{'customizations':[_0xde5fc8('0x1fbc'),function(_0x14dfdf){const _0x59f35f=_0xde5fc8;return _0x14dfdf[_0x59f35f('0x18af')](_0x59f35f('0xa4d'),{'fields':_0x59f35f('0x125b'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':'settings'})['state']('app.settings.cloudProviders',{'url':_0xde5fc8('0xb83'),'views':{'content@app':{'templateUrl':_0x43d312,'controller':_0xde5fc8('0x23d4')}},'resolve':{'cloudProviders':[_0xde5fc8('0x1fbc'),function(_0x16e284){const _0x238723=_0xde5fc8;return _0x16e284['resolve'](_0x238723('0x2767'),{'fields':_0x238723('0x7f3'),'sort':_0x238723('0x14dc'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':_0xde5fc8('0x2017')}),_0x49e18e['addPart'](_0xde5fc8('0x49f'));}angular[_0x36e6f4('0x896')](_0x36e6f4('0x224e'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),'md.data.table','flow',_0x36e6f4('0x107d'),'ckeditor','ng-sortable',_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),'ngclipboard',_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),'angularMaterialFormBuilder',_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),_0x36e6f4('0xf45'),_0x36e6f4('0x23b5'),_0x36e6f4('0xb2')])[_0x36e6f4('0xe11')](_0x532118)[_0x36e6f4('0x75e')](_0x36e6f4('0xd73'),_0x2c55e3)[_0x36e6f4('0x75e')]('CreateOrEditCloudProviderDialogController',_0x48ee47)[_0x36e6f4('0x75e')](_0x36e6f4('0x9fc'),_0x969763)[_0x36e6f4('0x75e')](_0x36e6f4('0x49e'),_0x429982)[_0x36e6f4('0x75e')]('CustomizationfaviconController',_0x40453d)[_0x36e6f4('0x75e')](_0x36e6f4('0x1b66'),_0x5a5f33)[_0x36e6f4('0x75e')](_0x36e6f4('0x1db7'),_0x42c3f0)[_0x36e6f4('0x75e')](_0x36e6f4('0xc5a'),_0x30c2bb)['controller'](_0x36e6f4('0x209c'),_0x23e884)[_0x36e6f4('0x75e')](_0x36e6f4('0xc7b'),_0x533527)[_0x36e6f4('0x75e')](_0x36e6f4('0x4a6'),_0x5a9cb5)[_0x36e6f4('0x75e')](_0x36e6f4('0x2658'),_0x2023b9)[_0x36e6f4('0x75e')](_0x36e6f4('0xb09'),_0x440824)['controller'](_0x36e6f4('0x35f'),_0x1dc1f2);const _0x1ecd76=_0x2734b2['p']+_0x36e6f4('0x11a7'),_0x5f5836=_0x2734b2['p']+_0x36e6f4('0x5b7'),_0x145033=_0x2734b2['p']+_0x36e6f4('0x2562'),_0x4ef973=_0x2734b2['p']+_0x36e6f4('0x12b2'),_0x1cbbb9=_0x2734b2['p']+_0x36e6f4('0x1a5f'),_0x1488b7=_0x2734b2['p']+_0x36e6f4('0xdce'),_0x5a22d1=_0x2734b2['p']+'src/js/modules/main/apps/motiondialer/views/realtime/ivr_campaigns/view.html/view.html',_0x1ed08b=_0x2734b2['p']+_0x36e6f4('0x4fc');_0x432884[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$window',_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef'),'socket',_0x36e6f4('0x1d2e'),_0x36e6f4('0x1f7e'),_0x36e6f4('0x4ea')];function _0x432884(_0x591465,_0x553227,_0x3c5c6a,_0x30ca45,_0x5a71fa,_0x4328b3,_0x321a40,_0x57a922,_0x33e2fd,_0x2553ad,_0x233212,_0x481d1e,_0x4713f8,_0x4c1f02){const _0x4aa87d=_0x36e6f4,_0x5a3f3a=this;_0x5a3f3a[_0x4aa87d('0x98')]=_0x2553ad[_0x4aa87d('0x26cd')](),_0x5a3f3a[_0x4aa87d('0x1f7e')]=_0x4713f8?_0x4713f8:[],_0x5a3f3a[_0x4aa87d('0x4ea')]=_0x4c1f02,_0x5a3f3a[_0x4aa87d('0x224c')]={'count':0x0,'rows':[]},_0x5a3f3a[_0x4aa87d('0xc6e')]=![],_0x5a3f3a[_0x4aa87d('0x1a73')]=!![],_0x5a3f3a[_0x4aa87d('0x7f')]=_0x57a922,_0x5a3f3a[_0x4aa87d('0x17aa')]=_0x33e2fd&&_0x33e2fd[_0x4aa87d('0x240f')]==0x1?_0x33e2fd[_0x4aa87d('0x269a')][0x0]:null,_0x5a3f3a[_0x4aa87d('0x243c')]=_0x2553ad[_0x4aa87d('0xd87')](_0x5a3f3a[_0x4aa87d('0x17aa')]?_0x5a3f3a[_0x4aa87d('0x17aa')][_0x4aa87d('0x243c')]:null),_0x5a3f3a[_0x4aa87d('0x2218')]={'fields':_0x4aa87d('0x1cd1'),'type':'outbound','queuecallerexitreason':'TIMEOUT'+','+'ABANDONED','sort':_0x4aa87d('0x14dc'),'limit':0xa,'page':0x1},_0x5a3f3a[_0x4aa87d('0x17df')]=_0x564019,_0x5a3f3a[_0x4aa87d('0x1def')]=_0x21e448,_0x5a3f3a[_0x4aa87d('0x2327')]=_0x46a952,_0x5a3f3a[_0x4aa87d('0xbb5')]=_0x239f03,_0x5a3f3a[_0x4aa87d('0x944')]=_0x439b16,_0x5a3f3a[_0x4aa87d('0x10f')]=_0x314774,_0x233212[_0x4aa87d('0xe82')](_0x4aa87d('0x2615'),_0x5a3f3a[_0x4aa87d('0x944')]),_0x233212['on']('voiceQueueReport:update',_0x5a3f3a[_0x4aa87d('0x10f')]),_0xfb3250();function _0xfb3250(){const _0x18e1e1=_0x4aa87d;let _0x8235f7=_0x5a71fa[_0x18e1e1('0x275')][_0x18e1e1('0x15f7')](_0x18e1e1('0xb62')+_0x5a3f3a['currentUser']['id']);if(_0x8235f7)_0x8235f7=JSON['parse'](_0x8235f7),_0x8235f7&&_0x8235f7[_0x18e1e1('0x2218')]&&(_0x5a3f3a['query']=_0x2cfb05()[_0x18e1e1('0xcc3')](_0x8235f7['query'],_0x2cfb05()[_0x18e1e1('0x1414')](_0x5a3f3a[_0x18e1e1('0x2218')],[_0x18e1e1('0x1aba'),_0x18e1e1('0x163f'),_0x18e1e1('0x1a43')])),_0x5a3f3a[_0x18e1e1('0x2218')]=_0x2cfb05()[_0x18e1e1('0x1414')](_0x5a3f3a['query'],_0x18e1e1('0x1c33')));else{const _0x3fe7c3={'$gte':_0x24273b()()[_0x18e1e1('0x1659')]('month')[_0x18e1e1('0x13f2')](0x0,!![])[_0x18e1e1('0x128a')](),'$lte':_0x24273b()()[_0x18e1e1('0x2589')](_0x18e1e1('0x2e7'))[_0x18e1e1('0x13f2')](0x0,!![])['format']()};_0x5a3f3a[_0x18e1e1('0x2218')][_0x18e1e1('0x262')]=_0x3fe7c3;}_0x2553ad['hasRole'](_0x18e1e1('0xa7c'))?_0x321a40[_0x18e1e1('0x557')]['getQueues']({'id':_0x2553ad[_0x18e1e1('0x26cd')]()['id'],'fields':_0x18e1e1('0x1776'),'channel':_0x18e1e1('0x21da'),'type':_0x18e1e1('0x587'),'nolimit':!![]})[_0x18e1e1('0xa44')][_0x18e1e1('0x1166')](function(_0x4dd579){const _0x5158fc=_0x18e1e1;_0x5a3f3a[_0x5158fc('0x7a7')]=_0x4dd579||{'count':0x0,'rows':[]},_0x5a3f3a[_0x5158fc('0x2392')]=_0x2cfb05()[_0x5158fc('0x1f4d')](_0x2cfb05()[_0x5158fc('0x155c')](_0x5a3f3a[_0x5158fc('0x7a7')][_0x5158fc('0x269a')],'name'),_0x5158fc('0x4f0'));})[_0x18e1e1('0x1a80')](function(_0x48d187){const _0x2f4ddd=_0x18e1e1;console[_0x2f4ddd('0xfc9')](_0x48d187);})[_0x18e1e1('0x1951')](function(){const _0x1cdecb=_0x18e1e1;_0x5a3f3a[_0x1cdecb('0x6cb')]=_0x204247(),_0x5a3f3a[_0x1cdecb('0x17df')]();}):_0x321a40[_0x18e1e1('0x7f')][_0x18e1e1('0x263a')]({'id':_0x5a3f3a[_0x18e1e1('0x98')][_0x18e1e1('0xb86')],'section':_0x18e1e1('0x9f4'),'channel':_0x18e1e1('0x21da'),'type':_0x18e1e1('0x587'),'sort':_0x18e1e1('0x14dc'),'nolimit':!![]})[_0x18e1e1('0xa44')][_0x18e1e1('0x1166')](function(_0x4cbe86){const _0xfd5c39=_0x18e1e1;_0x5a3f3a[_0xfd5c39('0x7a7')]=_0x4cbe86||{'count':0x0,'rows':[]},_0x5a3f3a[_0xfd5c39('0x2392')]=_0x2cfb05()[_0xfd5c39('0x1f4d')](_0x2cfb05()[_0xfd5c39('0x155c')](_0x5a3f3a[_0xfd5c39('0x7a7')][_0xfd5c39('0x269a')],_0xfd5c39('0x4f0')),_0xfd5c39('0x4f0'));})[_0x18e1e1('0x1a80')](function(_0x395a71){const _0x24fbf6=_0x18e1e1;console[_0x24fbf6('0xfc9')](_0x395a71);})[_0x18e1e1('0x1951')](function(){const _0x126108=_0x18e1e1;_0x5a3f3a[_0x126108('0x6cb')]=_0x204247(),_0x5a3f3a[_0x126108('0x17df')]();});}function _0x204247(){const _0xc67dfe=_0x4aa87d;return[{'name':_0xc67dfe('0x2567'),'key':_0xc67dfe('0x262'),'type':_0xc67dfe('0x1643'),'label':_0xc67dfe('0x16d9')},{'name':'Agent','key':_0xc67dfe('0x6b0'),'type':_0xc67dfe('0x88a'),'label':_0xc67dfe('0x1db1'),'options':_0x5a3f3a[_0xc67dfe('0x1f7e')][_0xc67dfe('0x269a')],'customOptions':[{'value':'\x27null\x27','translate':_0xc67dfe('0x216b')},{'value':undefined,'translate':_0xc67dfe('0x2150')}]},{'name':_0xc67dfe('0xaaf'),'key':_0xc67dfe('0x1d3e'),'type':_0xc67dfe('0x2162'),'label':_0xc67dfe('0x1428'),'options':_0x5a3f3a[_0xc67dfe('0x7a7')]['rows']}];}function _0x564019(){const _0xa48122=_0x4aa87d;_0x5a3f3a[_0xa48122('0x1a73')]=![],_0x5a3f3a['queues'][_0xa48122('0x240f')]>0x0?(_0x5a3f3a['query'][_0xa48122('0x1d3e')]=_0x5a3f3a[_0xa48122('0x7a7')][_0xa48122('0x240f')]===0x1?_0x5a3f3a['queues']['rows'][0x0][_0xa48122('0x4f0')]:_0x5a3f3a[_0xa48122('0x2218')][_0xa48122('0x1d3e')],_0x5a3f3a[_0xa48122('0x2218')]['offset']=(_0x5a3f3a['query']['page']-0x1)*_0x5a3f3a['query'][_0xa48122('0x163f')],_0x5a71fa['localStorage'][_0xa48122('0xa26')](_0xa48122('0xb62')+_0x5a3f3a['currentUser']['id'],JSON['stringify']({'query':_0x2cfb05()[_0xa48122('0x1414')](_0x5a3f3a[_0xa48122('0x2218')],_0xa48122('0x1d3e'))})),_0x5a3f3a[_0xa48122('0x1f48')]=_0x321a40[_0xa48122('0x1ede')][_0xa48122('0x1cdb')](_0x5a3f3a['query'],_0x3fe95a)[_0xa48122('0xa44')]):_0x3fe95a(null);}function _0x3fe95a(_0x507d33){const _0x4f2172=_0x4aa87d;_0x5a3f3a[_0x4f2172('0x224c')]=_0x507d33||{'count':0x0,'rows':[]},_0x5a3f3a[_0x4f2172('0x1a73')]=!![];}function _0x21e448(){const _0x35ae7e=_0x4aa87d;_0x5a3f3a[_0x35ae7e('0xc6e')]=![],_0x5a3f3a[_0x35ae7e('0x17df')]();}function _0x439b16(_0x15fc2e){const _0x5b3e32=_0x4aa87d,_0x417480=_0x5b3e32('0x587');_0x15fc2e&&_0x5a3f3a['queuesMap']&&_0x15fc2e[_0x5b3e32('0x1d3e')][_0x5b3e32('0x1345')]===_0x417480&&_0x5a3f3a[_0x5b3e32('0x2392')][_0x15fc2e['queue']]&&(_0x5a3f3a[_0x5b3e32('0xc6e')]=!![]);}function _0x314774(_0x4704ef){const _0x340c43=_0x4aa87d;if(_0x4704ef){const _0x4831e9=_0x2cfb05()[_0x340c43('0xede')](_0x5a3f3a[_0x340c43('0x224c')][_0x340c43('0x269a')],['id',_0x4704ef['id']]);_0x4831e9>=0x0&&_0x2cfb05()['merge'](_0x5a3f3a[_0x340c43('0x224c')]['rows'][_0x4831e9],_0x4704ef);}}function _0x46a952(_0x62a17a,_0x23eb01){const _0x145aa8=_0x4aa87d;_0x62a17a&&_0x321a40[_0x145aa8('0x1ede')][_0x145aa8('0x1449')]({'id':_0x62a17a['id'],'lastAssignedTo':_0x23eb01?_0x23eb01['name']:null,'assigned':_0x23eb01?!![]:![]})[_0x145aa8('0xa44')][_0x145aa8('0x1a80')](function(_0x321396){const _0xb76921=_0x145aa8;console[_0xb76921('0x455')](_0x321396);});}function _0x239f03(_0x1afa88){const _0x24f00d=_0x4aa87d;_0x3c5c6a['show']({'controller':'DisposeAbandonedCallDialogController','controllerAs':'vm','templateUrl':_0x1ed08b,'parent':angular['element'](_0x30ca45['body']),'targetEvent':_0x1afa88,'resolve':{'globalDispositions':[_0x24f00d('0x1fbc'),function(_0x2a025e){const _0x2fa6fd=_0x24f00d;return _0x2a025e['resolve'](_0x2fa6fd('0x1e98'),{'MailAccountId':'null','FaxAccountId':_0x2fa6fd('0x15d7'),'SmsAccountId':'null','WhatsappAccountId':'null','OpenchannelAccountId':'null','ChatWebsiteId':_0x2fa6fd('0x15d7'),'ListId':_0x2fa6fd('0x15d7')});}]},'locals':{'dispositions':_0x5a3f3a[_0x24f00d('0x4ea')],'call':_0x1afa88}})[_0x24f00d('0x1166')](function(_0x2f468d){const _0x26eca7=_0x24f00d;if(_0x2f468d){const _0x3d0b3e={'id':_0x1afa88['id'],'disposition':_0x2f468d[_0x26eca7('0xdc6')]||null,'secondDisposition':_0x2f468d['secondLevel']||null,'thirdDisposition':_0x2f468d[_0x26eca7('0x1d91')]||null};_0x321a40[_0x26eca7('0x1ede')][_0x26eca7('0x1449')](_0x3d0b3e)['$promise'][_0x26eca7('0x1a80')](function(_0x1c7ce3){const _0xff7be8=_0x26eca7;console[_0xff7be8('0x455')](_0x1c7ce3);});}});}let _0x415de7=!![],_0x1698ea=0x1;_0x591465[_0x4aa87d('0xe83')](_0x4aa87d('0x12d8'),function(_0x26a225,_0x75f24e){const _0x5b336f=_0x4aa87d;_0x415de7?_0x553227(function(){_0x415de7=![];}):(!_0x75f24e&&(_0x1698ea=_0x5a3f3a[_0x5b336f('0x2218')][_0x5b336f('0x1a43')]),_0x26a225!==_0x75f24e&&(_0x5a3f3a[_0x5b336f('0x2218')][_0x5b336f('0x1a43')]=0x1),!_0x26a225&&(_0x5a3f3a[_0x5b336f('0x2218')][_0x5b336f('0x1a43')]=_0x1698ea),_0x5a3f3a[_0x5b336f('0x17df')]());}),_0x591465['$on'](_0x4aa87d('0x1c3f'),function(){const _0x352128=_0x4aa87d;_0x233212[_0x352128('0x1800')]('voiceQueueReport:save'),_0x233212[_0x352128('0x1800')]('voiceQueueReport:update');});}const _0x5c86d7=_0x432884;_0x5eeb2b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$q',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x18bc'),'pauses',_0x36e6f4('0x1f7e'),_0x36e6f4('0x24b7'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),'toasty',_0x36e6f4('0x1a02'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'$interval'];function _0x5eeb2b(_0x2e593b,_0x492edb,_0x88cc13,_0x236237,_0x3abbcd,_0x447917,_0x473ccf,_0x56ebb0,_0x25bd34,_0x431dc6,_0x5aa82b,_0x2f9861,_0x3ae691,_0x11a929,_0x26298a,_0x1e0179,_0x517280,_0x1afbcc){const _0x5b057d=_0x36e6f4,_0x2d985c=this,_0x4ffcaa=[_0x5b057d('0x1a82'),'online',_0x5b057d('0x2318'),_0x5b057d('0x3dc'),_0x5b057d('0x246c'),_0x5b057d('0x3dc'),_0x5b057d('0x1eef'),'address',_0x5b057d('0x1c5c'),_0x5b057d('0x287f'),'mailPause','smsPause',_0x5b057d('0x11ee'),'faxPause','voicePause',_0x5b057d('0x6a8'),_0x5b057d('0x1b39'),_0x5b057d('0x18ae'),_0x5b057d('0x2627'),_0x5b057d('0x361'),_0x5b057d('0x1462'),_0x5b057d('0x1107'),_0x5b057d('0x8cf'),_0x5b057d('0x82d'),_0x5b057d('0x1da1'),_0x5b057d('0x2681'),_0x5b057d('0x1ee6'),_0x5b057d('0x840'),_0x5b057d('0x1f33'),_0x5b057d('0x25d8'),'smsStatus','whatsappStatus','faxStatus',_0x5b057d('0x17e1'),'chatStatusTime','openchannelStatusTime',_0x5b057d('0x1955'),'smsStatusTime',_0x5b057d('0x11a8'),_0x5b057d('0x4f3'),_0x5b057d('0x18c9'),_0x5b057d('0x1d3e'),_0x5b057d('0x1ad2'),_0x5b057d('0x158'),_0x5b057d('0x2167'),'phoneBarEnableAutomaticScreenRecording'],_0x21a88b=[_0x5b057d('0x1c5c'),_0x5b057d('0x287f'),_0x5b057d('0xb4'),_0x5b057d('0x178d'),_0x5b057d('0x11ee'),_0x5b057d('0x5aa'),_0x5b057d('0x2540'),'online'];_0x2d985c[_0x5b057d('0x98')]=_0x1e0179[_0x5b057d('0x26cd')](),_0x2d985c['availableStates']=[_0x5b057d('0x1628'),_0x5b057d('0x133e'),_0x5b057d('0x2344'),_0x5b057d('0x158e'),_0x5b057d('0x521')],_0x2d985c[_0x5b057d('0xe29')]=_0x473ccf||{'count':0x0,'rows':[]},_0x2d985c[_0x5b057d('0x5c9')]=_0x517280,_0x2d985c[_0x5b057d('0x7f')]=_0x11a929,_0x2d985c['userProfileSection']=_0x26298a&&_0x26298a[_0x5b057d('0x240f')]==0x1?_0x26298a[_0x5b057d('0x269a')][0x0]:null,_0x2d985c[_0x5b057d('0x243c')]=_0x1e0179[_0x5b057d('0xd87')](_0x2d985c[_0x5b057d('0x17aa')]?_0x2d985c[_0x5b057d('0x17aa')]['crudPermissions']:null),_0x2d985c[_0x5b057d('0x1f7e')]=_0x56ebb0?_0x2cfb05()['keyBy'](_0x56ebb0[_0x5b057d('0x269a')]?_0x56ebb0[_0x5b057d('0x269a')]:[],'id'):{},_0x2d985c[_0x5b057d('0x24b7')]=_0x25bd34?_0x2cfb05()[_0x5b057d('0x155c')](_0x25bd34['rows']?_0x25bd34[_0x5b057d('0x269a')]:[],'id'):{},_0x2d985c['paginatedAgents']={},_0x2d985c[_0x5b057d('0x173f')]=![],_0x2d985c['order']=[],_0x2d985c[_0x5b057d('0x4c4')]={};for(const _0x55cb96 in _0x2d985c[_0x5b057d('0x1f7e')]){typeof _0x2d985c['agents'][_0x55cb96]!==_0x5b057d('0x1048')&&(_0x2d985c[_0x5b057d('0x1f7e')][_0x55cb96][_0x5b057d('0x24d5')]=!![]);}_0x2d985c['query']={'limit':0xa,'page':0x1,'order':_0x5b057d('0x6e1'),'globalStatusFilter':'','pauseTypeFilter':''},_0x2d985c[_0x5b057d('0x885')]=_0x58f7df,_0x2d985c[_0x5b057d('0xaf7')]=_0x365624,_0x2d985c[_0x5b057d('0x1e77')]=_0x17c2bd,_0x2d985c[_0x5b057d('0xecc')]=_0x4e3bcd,_0x2d985c[_0x5b057d('0x6df')]=_0x581d25,_0x2d985c[_0x5b057d('0x72f')]=_0x2d170a,_0x2d985c['getAgentGlobalStatus']=_0x1bb1e4,_0x2d985c[_0x5b057d('0x882')]=_0x407a72,_0x2d985c[_0x5b057d('0x5ad')]=_0x1f941e,_0x2d985c[_0x5b057d('0xb02')]=_0xa09a30,_0x2d985c[_0x5b057d('0x1303')]=_0x206b5d,_0x2d985c[_0x5b057d('0x2232')]=_0xdde8ea,_0x2d985c['onInit']=_0x48b9f4,_0x2d985c[_0x5b057d('0x223a')]=_0x1d8a63,_0x2d985c[_0x5b057d('0x1923')]=_0x584d73,_0x2d985c[_0x5b057d('0x2845')]=_0x5014bd,_0x5aa82b['on'](_0x5b057d('0x26b2'),_0x2d985c[_0x5b057d('0x1303')]),_0x5aa82b['on']('user:update',_0x2d985c[_0x5b057d('0x2232')]),_0x5aa82b['on']('user:agentconnect',_0x2d985c[_0x5b057d('0x223a')]),_0x5aa82b['on'](_0x5b057d('0x1c99'),_0x2d985c['onComplete']),_0x48b9f4();let _0x3cf868=_0x1afbcc(function(){const _0x2ee4c7=_0x5b057d;_0x2d985c[_0x2ee4c7('0x173f')]&&(_0x2d985c[_0x2ee4c7('0x173f')]=![],_0x48b9f4());},0x3e7);function _0x48b9f4(){const _0x2c3123=_0x5b057d;_0x2d985c['load']=![];const _0x5f35be=_0x492edb[_0x2c3123('0x24d8')]();_0x2d985c['promise']=_0x5f35be['promise'],_0x2d985c[_0x2c3123('0x220b')]=[],_0x2d985c[_0x2c3123('0xa99')]=[],_0x2cfb05()['forIn'](_0x2d985c['agents'],function(_0x53ff3a,_0x308c9c){const _0x353d81=_0x2c3123;_0x2d985c['rpcAgents'][_0x308c9c]&&_0x2cfb05()[_0x353d81('0xcc3')](_0x53ff3a,_0x2cfb05()[_0x353d81('0x1a08')](_0x2cfb05()['omit'](_0x2d985c[_0x353d81('0x24b7')][_0x308c9c],_0x21a88b),_0x4ffcaa)),_0x1bb1e4(_0x53ff3a),_0x53ff3a[_0x353d81('0xb41')]?(_0x2d985c[_0x353d81('0x220b')][_0x353d81('0x1514')](_0x53ff3a),_0x2d985c['agentInternal'][_0x53ff3a[_0x353d81('0x1eef')]]=_0x308c9c):_0x53ff3a[_0x353d81('0x25b3')]=_0x2cfb05()[_0x353d81('0xa53')](_0x24273b()()[_0x353d81('0x128a')]('x'));});_0x2d985c[_0x2c3123('0x2218')][_0x2c3123('0xf4')]&&_0x2cfb05()[_0x2c3123('0x127f')](_0x2d985c['filteredAgents'],function(_0x5a3775){const _0x4bc5ca=_0x2c3123;return _0x5a3775[_0x4bc5ca('0xe34')]!==_0x2d985c[_0x4bc5ca('0x2218')][_0x4bc5ca('0xf4')];});_0x2d985c[_0x2c3123('0x2218')][_0x2c3123('0x2121')]&&_0x2cfb05()['remove'](_0x2d985c['filteredAgents'],function(_0xc980cd){const _0x3a9a08=_0x2c3123;return _0xc980cd[_0x3a9a08('0x246c')]!==_0x2d985c[_0x3a9a08('0x2218')][_0x3a9a08('0x2121')];});_0x2d985c['query'][_0x2c3123('0x1c33')]&&_0x2cfb05()[_0x2c3123('0x127f')](_0x2d985c[_0x2c3123('0x220b')],function(_0x5dc0f3){const _0x99ebbf=_0x2c3123;return _0x5dc0f3[_0x99ebbf('0x6e1')]['toLowerCase']()['indexOf'](_0x2d985c[_0x99ebbf('0x2218')]['filter'][_0x99ebbf('0x2574')]())<0x0;});_0x2d985c[_0x2c3123('0x220b')]=_0x407a6e(_0x2d985c[_0x2c3123('0x220b')]);const _0xa9b564=(_0x2d985c[_0x2c3123('0x2218')]['page']-0x1)*_0x2d985c[_0x2c3123('0x2218')][_0x2c3123('0x163f')];_0x2d985c[_0x2c3123('0x5e5')]=_0x2cfb05()[_0x2c3123('0x3e5')](_0x2d985c['filteredAgents'],_0xa9b564)[_0x2c3123('0x233')](0x0,_0x2d985c['query']['limit']);for(let _0x3d9e69=0x0;_0x3d9e69<_0x2d985c[_0x2c3123('0x5e5')]['length'];_0x3d9e69+=0x1){_0x2d985c[_0x2c3123('0xa99')][_0x2c3123('0x1514')](_0x2d985c[_0x2c3123('0x5e5')][_0x3d9e69]['id']);}_0x5f35be[_0x2c3123('0x18af')](),_0x2d985c[_0x2c3123('0x173f')]=!![];}function _0x206b5d(_0x7585c8){const _0x350a1b=_0x5b057d;_0x2d985c[_0x350a1b('0x1f7e')][_0x7585c8['id']]&&(_0x2cfb05()[_0x350a1b('0xcc3')](_0x2d985c[_0x350a1b('0x1f7e')][_0x7585c8['id']],_0x2cfb05()[_0x350a1b('0x1a08')](_0x2cfb05()[_0x350a1b('0x1414')](_0x7585c8,_0x21a88b),_0x4ffcaa)),_0x2cfb05()[_0x350a1b('0xcc3')](_0x2d985c['rpcAgents'][_0x7585c8['id']],_0x2cfb05()[_0x350a1b('0x1a08')](_0x2cfb05()[_0x350a1b('0x1414')](_0x7585c8,_0x21a88b),_0x4ffcaa)),_0x1bb1e4(_0x2d985c['agents'][_0x7585c8['id']]));}function _0xdde8ea(_0x571d72){const _0x33dc86=_0x5b057d;_0x2d985c[_0x33dc86('0x1f7e')][_0x571d72['id']]&&(_0x2cfb05()[_0x33dc86('0xcc3')](_0x2d985c[_0x33dc86('0x1f7e')][_0x571d72['id']],_0x2cfb05()[_0x33dc86('0x1a08')](_0x571d72,_0x4ffcaa)),_0x2cfb05()[_0x33dc86('0xcc3')](_0x2d985c['rpcAgents'][_0x571d72['id']],_0x2cfb05()[_0x33dc86('0x1a08')](_0x571d72,_0x4ffcaa)),_0x571d72['lastPauseAt']&&(_0x2d985c[_0x33dc86('0x1f7e')][_0x571d72['id']][_0x33dc86('0x25b3')]=_0x571d72[_0x33dc86('0x3dc')],_0x2d985c[_0x33dc86('0x24b7')][_0x571d72['id']][_0x33dc86('0x25b3')]=_0x571d72[_0x33dc86('0x3dc')]),_0x1bb1e4(_0x2d985c[_0x33dc86('0x1f7e')][_0x571d72['id']]));}function _0x1d8a63(_0x45a485){const _0x4af769=_0x5b057d;_0x2d985c['agents'][_0x2d985c[_0x4af769('0x4c4')][_0x45a485['destaccountcode']]]&&(_0x2cfb05()[_0x4af769('0xcc3')](_0x2d985c[_0x4af769('0x1f7e')][_0x2d985c[_0x4af769('0x4c4')][_0x45a485[_0x4af769('0x25fc')]]],_0x2cfb05()[_0x4af769('0x1a08')](_0x45a485,[_0x4af769('0x1d3e'),'destconnectedlinenum'])),_0x2cfb05()[_0x4af769('0xcc3')](_0x2d985c[_0x4af769('0x24b7')][_0x2d985c['agentInternal'][_0x45a485[_0x4af769('0x25fc')]]],_0x2cfb05()[_0x4af769('0x1a08')](_0x45a485,['queue',_0x4af769('0x1ad2')])));}function _0x584d73(_0x4eac19){const _0x335cf4=_0x5b057d;_0x2d985c[_0x335cf4('0x1f7e')][_0x2d985c['agentInternal'][_0x4eac19[_0x335cf4('0x25fc')]]]&&(_0x2d985c[_0x335cf4('0x1f7e')][_0x2d985c[_0x335cf4('0x4c4')][_0x4eac19[_0x335cf4('0x25fc')]]]=_0x2cfb05()[_0x335cf4('0x1414')](_0x2d985c[_0x335cf4('0x1f7e')][_0x2d985c[_0x335cf4('0x4c4')][_0x4eac19[_0x335cf4('0x25fc')]]],[_0x335cf4('0x1d3e'),_0x335cf4('0x1ad2')]),_0x2d985c[_0x335cf4('0x24b7')][_0x2d985c[_0x335cf4('0x4c4')][_0x4eac19[_0x335cf4('0x25fc')]]]=_0x2cfb05()['omit'](_0x2d985c[_0x335cf4('0x24b7')][_0x2d985c[_0x335cf4('0x4c4')][_0x4eac19['destaccountcode']]],['queue',_0x335cf4('0x1ad2')]));}function _0x58f7df(_0x22a22f){const _0x46f23e=_0x5b057d;return _0x431dc6['user']['logout']({'id':_0x22a22f['id'],'device':_0x46f23e('0xf01'),'agent_id':_0x22a22f['id'],'agent_name':_0x22a22f['name']})[_0x46f23e('0xa44')][_0x46f23e('0x1166')](function(){const _0x43a9a2=_0x46f23e;_0x2f9861[_0x43a9a2('0x103b')]({'title':_0x43a9a2('0x16a7'),'msg':_0x22a22f[_0x43a9a2('0x6e1')]+'\x20\x20properly\x20logout'}),_0x2d985c[_0x43a9a2('0x1f7e')][_0x22a22f['id']]&&(_0x2d985c['agents'][_0x22a22f['id']][_0x43a9a2('0xb41')]=![]),_0x2d985c[_0x43a9a2('0x24b7')][_0x22a22f['id']]&&(_0x2d985c[_0x43a9a2('0x24b7')][_0x22a22f['id']]['online']=![]),_0x48b9f4();})[_0x46f23e('0x1a80')](function(_0x5667de){const _0x4b6ec0=_0x46f23e;_0x2f9861[_0x4b6ec0('0xfc9')]({'title':_0x5667de['status']?'API:'+_0x5667de['status']+'\x20-\x20'+_0x5667de[_0x4b6ec0('0xe1b')]:_0x4b6ec0('0x1e3c'),'msg':_0x5667de[_0x4b6ec0('0x25f4')]?JSON[_0x4b6ec0('0xbac')](_0x5667de[_0x4b6ec0('0x25f4')]['message']):_0x5667de[_0x4b6ec0('0x1586')]()});});}function _0x17c2bd(_0x2ede9c,_0x3e94f4){const _0x5b77cb=_0x5b057d;return _0x431dc6[_0x5b77cb('0x557')]['pause']({'id':_0x2ede9c['id'],'type':_0x3e94f4})[_0x5b77cb('0xa44')][_0x5b77cb('0x1166')](function(_0x3f3844){const _0x46e49c=_0x5b77cb;_0x2d985c[_0x46e49c('0x1f7e')][_0x2ede9c['id']]&&_0x2cfb05()[_0x46e49c('0xcc3')](_0x2d985c['agents'][_0x2ede9c['id']],_0x2cfb05()['pick'](_0x3f3844,_0x4ffcaa)),_0x2d985c['rpcAgents'][_0x2ede9c['id']]&&_0x2cfb05()[_0x46e49c('0xcc3')](_0x2d985c[_0x46e49c('0x24b7')][_0x2ede9c['id']],_0x2cfb05()['pick'](_0x3f3844,_0x4ffcaa)),_0x1bb1e4(_0x2d985c['agents'][_0x2ede9c['id']]);})['catch'](function(_0x4dfc92){const _0x2745d3=_0x5b77cb;_0x2f9861[_0x2745d3('0xfc9')]({'title':_0x4dfc92[_0x2745d3('0x52d')]?'API:'+_0x4dfc92[_0x2745d3('0x52d')]+_0x2745d3('0x11e1')+_0x4dfc92[_0x2745d3('0xe1b')]:_0x2745d3('0x1e3c'),'msg':_0x4dfc92[_0x2745d3('0x25f4')]?JSON['stringify'](_0x4dfc92[_0x2745d3('0x25f4')][_0x2745d3('0x1e70')]):_0x4dfc92[_0x2745d3('0x1586')]()});});}function _0x4e3bcd(_0x2a728e){const _0x226804=_0x5b057d;return _0x431dc6[_0x226804('0x557')][_0x226804('0x20eb')]({'id':_0x2a728e['id']})[_0x226804('0xa44')][_0x226804('0x1166')](function(_0x55c385){const _0xb08c24=_0x226804;_0x2d985c[_0xb08c24('0x1f7e')][_0x2a728e['id']]&&_0x2cfb05()[_0xb08c24('0xcc3')](_0x2d985c[_0xb08c24('0x1f7e')][_0x2a728e['id']],_0x2cfb05()['pick'](_0x55c385,_0x4ffcaa)),_0x2d985c['rpcAgents'][_0x2a728e['id']]&&_0x2cfb05()[_0xb08c24('0xcc3')](_0x2d985c[_0xb08c24('0x24b7')][_0x2a728e['id']],_0x2cfb05()['pick'](_0x55c385,_0x4ffcaa)),_0x1bb1e4(_0x2d985c[_0xb08c24('0x1f7e')][_0x2a728e['id']]);})['catch'](function(_0x41988e){const _0x4c8f11=_0x226804;_0x2f9861[_0x4c8f11('0xfc9')]({'title':_0x41988e[_0x4c8f11('0x52d')]?_0x4c8f11('0x1e21')+_0x41988e[_0x4c8f11('0x52d')]+_0x4c8f11('0x11e1')+_0x41988e[_0x4c8f11('0xe1b')]:_0x4c8f11('0x1e3c'),'msg':_0x41988e[_0x4c8f11('0x25f4')]?JSON[_0x4c8f11('0xbac')](_0x41988e[_0x4c8f11('0x25f4')][_0x4c8f11('0x1e70')]):_0x41988e[_0x4c8f11('0x1586')]()});});}function _0x581d25(_0x3f2b38){const _0x3edb96=_0x5b057d;_0x236237['show'](_0x236237[_0x3edb96('0x31d')]()[_0x3edb96('0x2339')](!![])[_0x3edb96('0xcdc')](_0x3edb96('0x58a'))[_0x3edb96('0xf3c')](_0x3edb96('0x1174'))['ok']('Ok')['targetEvent'](_0x3f2b38));}function _0x365624(_0x31fead,_0x25be2b){const _0x137858=_0x5b057d;_0x236237[_0x137858('0x1f80')]({'controller':_0x137858('0xf19'),'controllerAs':'vm','templateUrl':_0x49c5be,'parent':angular[_0x137858('0x1194')](_0x3abbcd[_0x137858('0x8d2')]),'targetEvent':_0x25be2b,'clickOutsideToClose':!![],'locals':{'agent':_0x31fead,'agents':[],'channel':'voice','direction':'outbound','crudPermissions':_0x2d985c[_0x137858('0x243c')]}});}function _0x407a72(_0x1837af){const _0xe0a4a=_0x5b057d;return _0x1837af===_0xe0a4a('0x1e77')||_0x1837af===_0xe0a4a('0x6e8');}function _0x1f941e(_0x25fa2c){return _0x25fa2c==='pause';}function _0xa09a30(_0x36adcc){const _0x502c64=_0x5b057d;return _0x36adcc===_0x502c64('0x6e8');}function _0x3bf514(_0x70ba4a){const _0x362175=_0x5b057d;return _0x70ba4a===_0x362175('0xdb0')||_0x70ba4a==='unknown'||_0x70ba4a===_0x362175('0x14dd')||_0x70ba4a===_0x362175('0x1628')||_0x2cfb05()[_0x362175('0x2863')](_0x70ba4a);}function _0x2d170a(_0x581a1a,_0xb45ffc){const _0x300d24=_0x5b057d;if(_0xb45ffc==='voice'){if(_0x581a1a[_0xb45ffc+_0x300d24('0x28f6')]!==_0x300d24('0xdb0'))return _0x581a1a[_0xb45ffc+_0x300d24('0x28f6')];if(_0x581a1a[_0xb45ffc+_0x300d24('0x108')])return _0x581a1a[_0xb45ffc+_0x300d24('0x28f6')]=_0x300d24('0x1e77'),_0x300d24('0x1e77');return _0x300d24('0xdb0');}else{if(_0x581a1a[_0xb45ffc+'Pause'])return _0x581a1a[_0xb45ffc+_0x300d24('0x28f6')]=_0x300d24('0x1e77'),_0x300d24('0x1e77');return _0x581a1a[_0xb45ffc+'Status'];}}function _0x1bb1e4(_0x2ffe75){const _0x56e6d1=_0x5b057d;let _0x377e93='unknown';if(_0x2cfb05()[_0x56e6d1('0x2285')]([_0x2d170a(_0x2ffe75,_0x56e6d1('0x21da')),_0x2d170a(_0x2ffe75,_0x56e6d1('0xde2')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x1bfa')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x26c')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x146c')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x116e')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x1fc7'))],_0x407a72))_0x377e93='pause';else{if(_0x2cfb05()[_0x56e6d1('0x1798')]([_0x2d170a(_0x2ffe75,_0x56e6d1('0x21da')),_0x2d170a(_0x2ffe75,_0x56e6d1('0xde2')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x1bfa')),_0x2d170a(_0x2ffe75,'openchannel'),_0x2d170a(_0x2ffe75,_0x56e6d1('0x146c')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x116e')),_0x2d170a(_0x2ffe75,'fax')],_0x407a72))_0x377e93='*pause';else _0x2cfb05()['every']([_0x2d170a(_0x2ffe75,_0x56e6d1('0x21da')),_0x2d170a(_0x2ffe75,_0x56e6d1('0xde2')),_0x2d170a(_0x2ffe75,'mail'),_0x2d170a(_0x2ffe75,_0x56e6d1('0x26c')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x146c')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x116e')),_0x2d170a(_0x2ffe75,_0x56e6d1('0x1fc7'))],_0x3bf514)?_0x377e93='idle':_0x377e93=_0x56e6d1('0x2344');}_0x2ffe75['globalStatus']!==_0x377e93&&(_0x2ffe75[_0x56e6d1('0xe34')]=_0x377e93,_0x2ffe75[_0x56e6d1('0x24d5')]?(_0x2ffe75[_0x56e6d1('0x24d5')]=![],_0x2ffe75['globalStatusTime']=_0x407a72(_0x377e93)?_0x2cfb05()[_0x56e6d1('0xa53')](_0x24273b()(_0x2ffe75[_0x56e6d1('0x3dc')])[_0x56e6d1('0x128a')]('x')):_0x2cfb05()[_0x56e6d1('0x28bc')]([_0x2ffe75[_0x56e6d1('0x18c9')],_0x2ffe75[_0x56e6d1('0x1507')],_0x2ffe75[_0x56e6d1('0x1955')],_0x2ffe75[_0x56e6d1('0x2357')],_0x2ffe75[_0x56e6d1('0x11a8')],_0x2ffe75['openchannelStatusTime'],_0x2ffe75[_0x56e6d1('0x4f3')]])):_0x2ffe75['globalStatusTime']=_0x2cfb05()[_0x56e6d1('0xa53')](_0x24273b()()[_0x56e6d1('0x128a')]('x')));}function _0x407a6e(_0x344d76){const _0x51497f=_0x5b057d,_0x40207c=_0x2cfb05()[_0x51497f('0x1783')](_0x2d985c[_0x51497f('0x2218')][_0x51497f('0xa99')],'-')?'desc':_0x51497f('0x17d');return _0x2cfb05()['orderBy'](_0x344d76,[_0x2d985c[_0x51497f('0x2218')]['order'][_0x51497f('0xf3')]('-','')],[_0x40207c]);}function _0x4974b6(){const _0x569816=_0x5b057d;_0x3cf868&&(_0x1afbcc[_0x569816('0x3f')](_0x3cf868),_0x3cf868=null);}function _0x5014bd(_0x57e66a,_0x43ad45){const _0x41c831=_0x5b057d;return _0x431dc6[_0x41c831('0x557')][_0x41c831('0x1449')]({'id':_0x57e66a['id']},{'screenrecording':_0x43ad45})[_0x41c831('0xa44')][_0x41c831('0x1a80')](function(_0x565349){const _0xd2948d=_0x41c831;_0x2f9861[_0xd2948d('0xfc9')]({'title':_0x565349[_0xd2948d('0x52d')]?'API:'+_0x565349[_0xd2948d('0x52d')]+_0xd2948d('0x11e1')+_0x565349['statusText']:_0xd2948d('0x1103'),'msg':_0x565349[_0xd2948d('0x25f4')]?JSON[_0xd2948d('0xbac')](_0x565349[_0xd2948d('0x25f4')]['message']):_0x565349['toString']()});});}_0x2e593b[_0x5b057d('0x3d2')]('$destroy',function(){const _0xa708ed=_0x5b057d;_0x5aa82b['removeAllListeners'](_0xa708ed('0x26b2')),_0x5aa82b[_0xa708ed('0x1800')](_0xa708ed('0x19d5')),_0x5aa82b[_0xa708ed('0x1800')](_0xa708ed('0x10fc')),_0x5aa82b[_0xa708ed('0x1800')](_0xa708ed('0x1c99')),_0x4974b6();});}const _0x1c858b=_0x5eeb2b,_0x438cf9=_0x2734b2['p']+_0x36e6f4('0x2356');_0xb396db[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x10eb'),_0x36e6f4('0x218f'),_0x36e6f4('0x1163'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),'userProfile',_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0xb396db(_0x21e71b,_0x1c7a23,_0x14f0db,_0x424ca7,_0x2aad88,_0x10bf7d,_0x4ac1ca,_0x394f07,_0x16cd30,_0x16be07,_0x5e5835,_0x5a478d){const _0x32f564=_0x36e6f4,_0x5a7106=this,_0x5568d4=[_0x32f564('0x4f0'),_0x32f564('0x1c0e'),_0x32f564('0x1271'),_0x32f564('0x1e70'),'originated',_0x32f564('0x186f'),_0x32f564('0x28a9'),'Trunk',_0x32f564('0x1ce4'),'ivrAnswerCallsDay',_0x32f564('0xaa6'),_0x32f564('0x2292'),_0x32f564('0x101c')];_0x5a7106[_0x32f564('0x98')]=_0x5a478d[_0x32f564('0x26cd')](),_0x5a7106[_0x32f564('0x240f')]=_0x4ac1ca['count'],_0x5a7106[_0x32f564('0x1163')]=_0x4ac1ca?_0x2cfb05()[_0x32f564('0x155c')](_0x4ac1ca[_0x32f564('0x269a')]?_0x4ac1ca[_0x32f564('0x269a')]:[],'id'):{},_0x5a7106[_0x32f564('0x218f')]=_0x10bf7d?_0x2cfb05()['keyBy'](_0x10bf7d[_0x32f564('0x269a')]?_0x10bf7d[_0x32f564('0x269a')]:[],'id'):{},_0x5a7106[_0x32f564('0x7f')]=_0x16be07,_0x5a7106[_0x32f564('0x17aa')]=_0x5e5835&&_0x5e5835[_0x32f564('0x240f')]==0x1?_0x5e5835[_0x32f564('0x269a')][0x0]:null,_0x5a7106[_0x32f564('0x243c')]=_0x5a478d['parseCrudPermissions'](_0x5a7106[_0x32f564('0x17aa')]?_0x5a7106['userProfileSection']['crudPermissions']:null),_0x5a7106[_0x32f564('0x2218')]={'sort':'-updatedAt','limit':0xa,'page':0x1},_0x5a7106[_0x32f564('0x103b')]=_0x122694,_0x5a7106[_0x32f564('0x1214')]=_0x4f2cb3,_0x5a7106[_0x32f564('0x1303')]=_0x360148,_0x5a7106[_0x32f564('0x1089')]=_0x49da2f,_0x5a7106[_0x32f564('0x24ff')]=_0x49ea96,_0x16cd30[_0x32f564('0xe82')](_0x32f564('0x3c8'),_0x5a7106[_0x32f564('0x1303')]),_0x5a7106[_0x32f564('0x277c')]=_0x2aad88(function(){},0x3e7);function _0x49da2f(){const _0x105aa5=_0x32f564;_0x2cfb05()['forIn'](_0x5a7106[_0x105aa5('0x1163')],function(_0x31ad74,_0x11b172){const _0x3a6472=_0x105aa5;_0x5a7106[_0x3a6472('0x218f')][_0x11b172]&&_0x2cfb05()[_0x3a6472('0xcc3')](_0x31ad74,_0x2cfb05()[_0x3a6472('0x1a08')](_0x5a7106['rpcCampaigns'][_0x11b172],_0x5568d4));});}function _0x360148(_0x39e3c2){const _0x39e9a2=_0x32f564;_0x5a7106[_0x39e9a2('0x1163')][_0x39e3c2['id']]&&(_0x2cfb05()[_0x39e9a2('0xcc3')](_0x5a7106[_0x39e9a2('0x1163')][_0x39e3c2['id']],_0x2cfb05()[_0x39e9a2('0x1a08')](_0x39e3c2,_0x5568d4)),_0x2cfb05()[_0x39e9a2('0xcc3')](_0x5a7106['rpcCampaigns'][_0x39e3c2['id']],_0x2cfb05()[_0x39e9a2('0x1a08')](_0x39e3c2,_0x5568d4)));}let _0x47f8ce=!![],_0x2724d0=0x1;_0x21e71b[_0x32f564('0xe83')](_0x32f564('0x12d8'),function(_0x196dc9,_0x4978a6){const _0x2243db=_0x32f564;_0x47f8ce?_0x1c7a23(function(){_0x47f8ce=![];}):(!_0x4978a6&&(_0x2724d0=_0x5a7106[_0x2243db('0x2218')][_0x2243db('0x1a43')]),_0x196dc9!==_0x4978a6&&(_0x5a7106[_0x2243db('0x2218')][_0x2243db('0x1a43')]=0x1),!_0x196dc9&&(_0x5a7106[_0x2243db('0x2218')][_0x2243db('0x1a43')]=_0x2724d0),_0x5a7106[_0x2243db('0x1214')]());});function _0x122694(_0x178ac6){const _0x16d164=_0x32f564;_0x5a7106[_0x16d164('0x240f')]=_0x178ac6['count'],_0x5a7106['campaigns']=_0x178ac6?_0x2cfb05()[_0x16d164('0x155c')](_0x178ac6[_0x16d164('0x269a')]?_0x178ac6[_0x16d164('0x269a')]:[],'id'):{},_0x49da2f();}function _0x4f2cb3(){const _0x534d9f=_0x32f564;_0x5a7106[_0x534d9f('0x2218')][_0x534d9f('0x1098')]=(_0x5a7106['query']['page']-0x1)*_0x5a7106['query']['limit'],_0x5a478d[_0x534d9f('0x1ac6')]('admin')?_0x5a7106['promise']=_0x394f07['campaign'][_0x534d9f('0xd83')](_0x5a7106[_0x534d9f('0x2218')],_0x122694)[_0x534d9f('0xa44')]:(_0x5a7106['query']['id']=_0x5a7106[_0x534d9f('0x7f')]['id'],_0x5a7106[_0x534d9f('0x2218')][_0x534d9f('0xe60')]='IvrCampaigns',_0x5a7106[_0x534d9f('0x1f48')]=_0x394f07['userProfile'][_0x534d9f('0x263a')](_0x5a7106[_0x534d9f('0x2218')],_0x122694)[_0x534d9f('0xa44')]);}function _0x49ea96(_0x327a10,_0x10eea1){const _0x12e868=_0x32f564;_0x14f0db['show']({'controller':_0x12e868('0xb5f'),'controllerAs':'vm','templateUrl':_0x438cf9,'parent':angular[_0x12e868('0x1194')](_0x424ca7[_0x12e868('0x8d2')]),'targetEvent':_0x327a10,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x10eea1,'ivrCampaigns':_0x2cfb05()[_0x12e868('0x1ac1')](_0x5a7106[_0x12e868('0x1163')]),'license':null,'setting':null,'crudPermissions':_0x5a7106['crudPermissions']}});}_0x21e71b[_0x32f564('0x3d2')](_0x32f564('0x1c3f'),function(){const _0x3a66db=_0x32f564;_0x16cd30[_0x3a66db('0x1800')](_0x3a66db('0x3c8')),_0x5a7106[_0x3a66db('0x277c')]&&_0x2aad88[_0x3a66db('0x3f')](_0x5a7106[_0x3a66db('0x277c')]);});}const _0x507bf8=_0xb396db;_0x5c18ed[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x8da'),'$mdDialog','agents',_0x36e6f4('0x7a7'),'rpcVoiceQueuesChannels','api',_0x36e6f4('0x2661'),_0x36e6f4('0x1a02'),'toasty',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x5c18ed(_0x454346,_0xfacb0b,_0x3f8d74,_0x2179b1,_0x1fabd1,_0x1b4b85,_0x360045,_0x1ce79e,_0xfcd86b,_0x347131,_0x274319,_0x379708,_0x473906){const _0x3e1ca3=_0x36e6f4,_0x22260a=this;_0x22260a[_0x3e1ca3('0x98')]=_0x473906[_0x3e1ca3('0x26cd')](),_0x22260a[_0x3e1ca3('0x1f7e')]=_0x2179b1||{'count':0x0,'rows':[]},_0x22260a[_0x3e1ca3('0x7a7')]=_0x1fabd1?_0x2cfb05()[_0x3e1ca3('0x155c')](_0x1fabd1['rows']?_0x1fabd1[_0x3e1ca3('0x269a')]:[],_0x3e1ca3('0x4f0')):{},_0x22260a[_0x3e1ca3('0x1f93')]=_0x1b4b85?_0x2cfb05()[_0x3e1ca3('0x155c')](_0x1b4b85['rows']?_0x2cfb05()['filter'](_0x1b4b85['rows'],{'type':_0x3e1ca3('0x587')}):[],_0x3e1ca3('0x1c21')):{},_0x22260a[_0x3e1ca3('0x2177')]={},_0x22260a[_0x3e1ca3('0x7f')]=_0x274319,_0x22260a[_0x3e1ca3('0x17aa')]=_0x379708&&_0x379708['count']==0x1?_0x379708[_0x3e1ca3('0x269a')][0x0]:null,_0x22260a[_0x3e1ca3('0x243c')]=_0x473906[_0x3e1ca3('0xd87')](_0x22260a[_0x3e1ca3('0x17aa')]?_0x22260a[_0x3e1ca3('0x17aa')][_0x3e1ca3('0x243c')]:null),_0x22260a['queryChannels']={'limit':0xa,'page':0x1},_0x22260a['getSize']=_0x555450,_0x22260a['$onInit']=_0x43324a,_0x22260a['onSave']=_0x5bcde6,_0x22260a[_0x3e1ca3('0x20e2')]=_0x9b5004,_0x22260a[_0x3e1ca3('0x133d')]=_0x5be56c,_0x22260a[_0x3e1ca3('0x23a5')]=_0x27ea17,_0x22260a[_0x3e1ca3('0xad0')]=_0x1b1a54,_0x1ce79e['on']('voice_queue_channel:save',_0x22260a[_0x3e1ca3('0x1303')]),_0x1ce79e['on'](_0x3e1ca3('0x14fe'),_0x22260a[_0x3e1ca3('0x20e2')]);function _0x555450(_0x1bbf08){const _0x2700c0=_0x3e1ca3;return _0x2cfb05()[_0x2700c0('0x2340')](_0x1bbf08);}function _0x43324a(){const _0x3270d4=_0x3e1ca3;_0x2cfb05()[_0x3270d4('0x941')](_0x22260a['rpcVoiceQueuesChannelsTmp'],function(_0xef667,_0x2ccb07){const _0x2c21b2=_0x3270d4;_0x2cfb05()[_0x2c21b2('0xc38')](_0x22260a[_0x2c21b2('0x7a7')],{'name':_0xef667[_0x2c21b2('0x4f0')]})&&(_0x22260a[_0x2c21b2('0x2177')][_0x2ccb07]=_0xef667);});}function _0x5bcde6(_0x3001cd){const _0x3adc24=_0x3e1ca3;_0x3001cd[_0x3adc24('0x1345')]===_0x3adc24('0x587')&&(_0x2cfb05()['find'](_0x22260a[_0x3adc24('0x7a7')],{'name':_0x3001cd[_0x3adc24('0x4f0')]})&&(_0x22260a[_0x3adc24('0x2177')][_0x3001cd[_0x3adc24('0x1c21')]]=_0x3001cd));}function _0x9b5004(_0x58efbf){const _0xf07f1b=_0x3e1ca3;_0x22260a[_0xf07f1b('0x2177')][_0x58efbf[_0xf07f1b('0x1c21')]]&&delete _0x22260a['rpcVoiceQueuesChannels'][_0x58efbf[_0xf07f1b('0x1c21')]];}function _0x5be56c(_0x262b02){const _0x65ce4a=_0x3e1ca3;return _0x360045[_0x65ce4a('0x13fa')][_0x65ce4a('0x1abc')]({'uniqueid':_0x262b02})[_0x65ce4a('0xa44')][_0x65ce4a('0x1166')](function(_0x481780){const _0x3aca1c=_0x65ce4a;_0x347131[_0x3aca1c('0x103b')]({'title':_0x3aca1c('0x177a')+_0x262b02+_0x3aca1c('0x176b'),'msg':_0x481780[_0x3aca1c('0x1e70')]||''});})[_0x65ce4a('0x1a80')](function(_0x4f5f64){const _0x36c388=_0x65ce4a;_0x347131[_0x36c388('0xfc9')]({'title':_0x4f5f64['status']+_0x36c388('0x11e1')+_0x4f5f64[_0x36c388('0xe1b')],'msg':JSON['stringify'](_0x4f5f64[_0x36c388('0x25f4')])||_0x4f5f64['message'][_0x36c388('0x45a')]('\x20')});});}function _0x27ea17(_0x33db71,_0x27c681,_0x31bbf0){const _0x3db04a=_0x3e1ca3;return _0x360045['rpc'][_0x3db04a('0xb2c')]({'uniqueid':_0x33db71,'exten':_0x27c681,'context':_0x31bbf0})[_0x3db04a('0xa44')][_0x3db04a('0x1166')](function(_0x2459d9){const _0x3cfb11=_0x3db04a;_0x347131[_0x3cfb11('0x103b')]({'title':_0x3cfb11('0x177a')+_0x33db71+'\x20properly\x20redirect!','msg':_0x2459d9[_0x3cfb11('0x1e70')]||''});})['catch'](function(_0x5d1955){const _0x575ffe=_0x3db04a;_0x347131[_0x575ffe('0xfc9')]({'title':_0x5d1955[_0x575ffe('0x52d')]+'\x20-\x20'+_0x5d1955[_0x575ffe('0xe1b')],'msg':JSON[_0x575ffe('0xbac')](_0x5d1955['data'])||_0x5d1955[_0x575ffe('0x1e70')][_0x575ffe('0x45a')]('\x20')});});}function _0x1b1a54(_0x572ae2,_0x4fd819){const _0xe2e49d=_0x3e1ca3,_0x400c8d=_0x3f8d74[_0xe2e49d('0x2081')]()[_0xe2e49d('0xcdc')]('Which\x20number\x20do\x20you\x20want\x20transfer\x20the\x20call\x20to?')['placeholder'](_0xe2e49d('0x223'))[_0xe2e49d('0x203b')](_0x572ae2)['ok']('Ok')[_0xe2e49d('0x3f')]('Cancel');return _0x3f8d74['show'](_0x400c8d)[_0xe2e49d('0x1166')](function(_0x1568fd){const _0x5cdaa4=_0xe2e49d;return _0x360045[_0x5cdaa4('0x13fa')][_0x5cdaa4('0xb2c')]({'uniqueid':_0x4fd819,'exten':_0x1568fd})['$promise'];})[_0xe2e49d('0x1166')](function(_0x5f4de5){const _0x257d96=_0xe2e49d;_0x347131[_0x257d96('0x103b')]({'title':_0x257d96('0x177a')+_0x4fd819+_0x257d96('0xe51'),'msg':_0x5f4de5[_0x257d96('0x1e70')]||''});})['catch'](function(_0x332cd8){const _0x47f971=_0xe2e49d;_0x347131[_0x47f971('0xfc9')]({'title':_0x332cd8[_0x47f971('0x52d')]+'\x20-\x20'+_0x332cd8[_0x47f971('0xe1b')],'msg':JSON['stringify'](_0x332cd8[_0x47f971('0x25f4')])||_0x332cd8[_0x47f971('0x1e70')][_0x47f971('0x45a')]('\x20')});});}_0x454346[_0x3e1ca3('0x3d2')](_0x3e1ca3('0x1c3f'),function(){const _0x5126d2=_0x3e1ca3;_0x1ce79e[_0x5126d2('0x1800')](_0x5126d2('0x196a')),_0x1ce79e[_0x5126d2('0x1800')](_0x5126d2('0x14fe'));});}const _0x379172=_0x5c18ed;_0x2df05e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$timeout',_0x36e6f4('0x10eb'),_0x36e6f4('0x7a7'),_0x36e6f4('0x744'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x2df05e(_0x55dc12,_0x2e89b6,_0x747f73,_0x5200c5,_0x4ec922,_0x272769,_0x25847c,_0x2954c4,_0x1faba8,_0x544e3d){const _0x4954ab=_0x36e6f4,_0x4958d5=this,_0x5b27eb=[_0x4954ab('0x25e7'),'answered',_0x4954ab('0x4c9'),_0x4954ab('0xa08'),_0x4954ab('0xb76'),_0x4954ab('0x265f'),_0x4954ab('0x1895'),_0x4954ab('0x120c'),'outboundNoSuchCallsDay',_0x4954ab('0x27c4'),_0x4954ab('0xb51'),'outboundDropCallsDayCallersExit',_0x4954ab('0x1b60'),'outboundOriginateFailureCallsDay',_0x4954ab('0x461'),_0x4954ab('0x1ea9'),_0x4954ab('0x1ba9')];_0x4958d5[_0x4954ab('0x240f')]=_0x5200c5[_0x4954ab('0x240f')],_0x4958d5['queues']=_0x5200c5?_0x2cfb05()[_0x4954ab('0x155c')](_0x5200c5['rows']?_0x5200c5[_0x4954ab('0x269a')]:[],'id'):{},_0x4958d5['rpcQueues']=_0x4ec922?_0x2cfb05()[_0x4954ab('0x155c')](_0x4ec922[_0x4954ab('0x269a')]?_0x4ec922['rows']:[],'id'):{},_0x4958d5['userProfile']=_0x2954c4,_0x4958d5['userProfileSection']=_0x1faba8&&_0x1faba8['count']==0x1?_0x1faba8[_0x4954ab('0x269a')][0x0]:null,_0x4958d5[_0x4954ab('0x243c')]=_0x544e3d[_0x4954ab('0xd87')](_0x4958d5[_0x4954ab('0x17aa')]?_0x4958d5[_0x4954ab('0x17aa')][_0x4954ab('0x243c')]:null);_0x544e3d[_0x4954ab('0x1ac6')](_0x4954ab('0xa7c'))?_0x4958d5[_0x4954ab('0x2218')]={'type':_0x4954ab('0x587'),'fields':_0x4954ab('0x1776'),'sort':'-updatedAt','limit':0xa,'page':0x1}:_0x4958d5[_0x4954ab('0x2218')]={'id':_0x544e3d[_0x4954ab('0x26cd')]()['id'],'channel':_0x4954ab('0x21da'),'type':_0x4954ab('0x587'),'fields':_0x4954ab('0x1776'),'sort':'-updatedAt','limit':0xa,'page':0x1};_0x4958d5[_0x4954ab('0x103b')]=_0x59f746,_0x4958d5[_0x4954ab('0x152a')]=_0x5f0f3b,_0x4958d5[_0x4954ab('0x1303')]=_0x140887,_0x4958d5['$onInit']=_0x1d3395,_0x25847c[_0x4954ab('0xe82')](_0x4954ab('0xa60'),_0x4958d5[_0x4954ab('0x1303')]),_0x4958d5[_0x4954ab('0x277c')]=_0x747f73(function(){},0x3e7);function _0x1d3395(){const _0x2d890a=_0x4954ab;_0x2cfb05()[_0x2d890a('0x941')](_0x4958d5['queues'],function(_0xe1e635,_0x1af272){const _0x18b7a7=_0x2d890a;_0x4958d5[_0x18b7a7('0x744')][_0x1af272]&&_0x2cfb05()['merge'](_0xe1e635,_0x2cfb05()[_0x18b7a7('0x1a08')](_0x4958d5[_0x18b7a7('0x744')][_0x1af272],_0x5b27eb));});}function _0x140887(_0x105cbf){const _0x169c28=_0x4954ab;_0x4958d5['queues'][_0x105cbf['id']]&&_0x2cfb05()[_0x169c28('0xcc3')](_0x4958d5[_0x169c28('0x7a7')][_0x105cbf['id']],_0x2cfb05()[_0x169c28('0x1a08')](_0x105cbf,_0x5b27eb));}let _0x229463=!![],_0x57fd58=0x1;_0x55dc12[_0x4954ab('0xe83')](_0x4954ab('0x12d8'),function(_0x48b63c,_0x228104){const _0x55706d=_0x4954ab;_0x229463?_0x2e89b6(function(){_0x229463=![];}):(!_0x228104&&(_0x57fd58=_0x4958d5[_0x55706d('0x2218')]['page']),_0x48b63c!==_0x228104&&(_0x4958d5[_0x55706d('0x2218')][_0x55706d('0x1a43')]=0x1),!_0x48b63c&&(_0x4958d5[_0x55706d('0x2218')]['page']=_0x57fd58),_0x4958d5[_0x55706d('0x152a')]());});function _0x59f746(_0x2bd9f9){const _0x2dd654=_0x4954ab;_0x4958d5['count']=_0x2bd9f9[_0x2dd654('0x240f')],_0x4958d5['queues']=_0x2bd9f9?_0x2cfb05()[_0x2dd654('0x155c')](_0x2bd9f9[_0x2dd654('0x269a')]?_0x2bd9f9[_0x2dd654('0x269a')]:[],'id'):{},_0x1d3395();}function _0x5f0f3b(){const _0x1a7333=_0x4954ab;_0x4958d5[_0x1a7333('0x2218')][_0x1a7333('0x1098')]=(_0x4958d5['query']['page']-0x1)*_0x4958d5[_0x1a7333('0x2218')][_0x1a7333('0x163f')],_0x544e3d[_0x1a7333('0x1ac6')](_0x1a7333('0xa7c'))?_0x4958d5[_0x1a7333('0x1f48')]=_0x272769['voiceQueue']['get'](_0x4958d5['query'],_0x59f746)[_0x1a7333('0xa44')]:(_0x4958d5[_0x1a7333('0x2218')]['id']=_0x4958d5['userProfile']['id'],_0x4958d5[_0x1a7333('0x2218')][_0x1a7333('0xe60')]=_0x1a7333('0x9f4'),_0x4958d5[_0x1a7333('0x1f48')]=_0x272769['userProfile'][_0x1a7333('0x263a')](_0x4958d5[_0x1a7333('0x2218')],_0x59f746)[_0x1a7333('0xa44')]);}_0x55dc12[_0x4954ab('0x3d2')](_0x4954ab('0x1c3f'),function(){const _0x38e446=_0x4954ab;_0x25847c[_0x38e446('0x1800')](_0x38e446('0xa60')),_0x4958d5[_0x38e446('0x277c')]&&_0x747f73[_0x38e446('0x3f')](_0x4958d5[_0x38e446('0x277c')]);});}const _0x193ed4=_0x2df05e,_0xefbac1=_0x2734b2['p']+'src/js/modules/main/apps/motiondialer/views/queueCampaigns/create/dialog.html/dialog.html',_0x2eb7fe=_0x2734b2['p']+_0x36e6f4('0x26f6'),_0x1848c7=_0x2734b2['p']+'src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/agentadd/agentadd.html/agentadd.html';_0x20874a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1c90'),_0x36e6f4('0x10eb'),_0x36e6f4('0x7a7'),_0x36e6f4('0x744'),'api',_0x36e6f4('0x2661'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x20874a(_0x1ee976,_0x59bf7b,_0x1b4c69,_0x26187a,_0x162035,_0x43c24e,_0x566718,_0x105d9c,_0x4e652e,_0x5d6bb9,_0x3a35a3,_0x4f194e,_0x83f896,_0x23e177){const _0x31e348=_0x36e6f4,_0xf2932f=this,_0xd03e53=[_0x31e348('0x1570'),_0x31e348('0x44b'),_0x31e348('0x288a'),_0x31e348('0x46a'),_0x31e348('0x67d'),_0x31e348('0x20ab'),'message',_0x31e348('0x6c9'),_0x31e348('0x20ae'),_0x31e348('0x14c4'),'paused',_0x31e348('0x6b5'),_0x31e348('0x196'),_0x31e348('0x1988'),_0x31e348('0x7e1'),_0x31e348('0x28d7'),_0x31e348('0x2561'),_0x31e348('0x5e2'),'dialPredictiveIntervalMaxThreshold',_0x31e348('0x889'),_0x31e348('0x1a9b'),_0x31e348('0xbc5'),_0x31e348('0xb3'),_0x31e348('0xc43'),_0x31e348('0x2899'),_0x31e348('0x9ae'),_0x31e348('0x28a1')];_0xf2932f[_0x31e348('0x98')]=_0x23e177[_0x31e348('0x26cd')](),_0xf2932f[_0x31e348('0x240f')]=_0x566718[_0x31e348('0x240f')]?_0x566718['count']:0x0,_0xf2932f['queues']=_0x566718?_0x2cfb05()['keyBy'](_0x566718[_0x31e348('0x269a')]?_0x566718['rows']:[],'id'):{},_0xf2932f[_0x31e348('0x744')]=_0x105d9c?_0x2cfb05()['keyBy'](_0x105d9c[_0x31e348('0x269a')]?_0x105d9c[_0x31e348('0x269a')]:[],'id'):{},_0xf2932f['userProfile']=_0x4f194e,_0xf2932f['userProfileSection']=_0x83f896&&_0x83f896[_0x31e348('0x240f')]==0x1?_0x83f896[_0x31e348('0x269a')][0x0]:null,_0xf2932f[_0x31e348('0x243c')]=_0x23e177[_0x31e348('0xd87')](_0xf2932f[_0x31e348('0x17aa')]?_0xf2932f[_0x31e348('0x17aa')][_0x31e348('0x243c')]:null);_0x23e177[_0x31e348('0x1ac6')](_0x31e348('0xa7c'))?_0xf2932f[_0x31e348('0x2218')]={'type':_0x31e348('0x587'),'sort':_0x31e348('0x14dc'),'limit':0xa,'page':0x1}:_0xf2932f['query']={'id':_0xf2932f['currentUser']['id'],'channel':'voice','type':'outbound','sort':_0x31e348('0x14dc'),'limit':0xa,'page':0x1};_0xf2932f[_0x31e348('0x103b')]=_0x3d3566,_0xf2932f[_0x31e348('0x152a')]=_0x893d39,_0xf2932f[_0x31e348('0xabb')]=_0x48475c,_0xf2932f[_0x31e348('0x1611')]=_0x524a74,_0xf2932f[_0x31e348('0x33f')]=_0x421721,_0xf2932f[_0x31e348('0xeba')]=_0x5dbd86,_0xf2932f[_0x31e348('0x1303')]=_0x25ca24,_0xf2932f[_0x31e348('0xfb')]=_0x327699,_0xf2932f['onPause']=_0x10b081,_0xf2932f[_0x31e348('0xb9a')]=_0x5cd1d1,_0xf2932f[_0x31e348('0x1696')]=_0x2694ea,_0xf2932f[_0x31e348('0x1089')]=_0x2813fd,_0xf2932f[_0x31e348('0xa99')]=[],_0x2cfb05()[_0x31e348('0x941')](_0xf2932f[_0x31e348('0x7a7')],function(_0xd683f9){const _0x4a42ed=_0x31e348;_0xf2932f['order'][_0x4a42ed('0x1514')](_0xd683f9['id']);}),_0x5d6bb9[_0x31e348('0xe82')](_0x31e348('0xa60'),_0xf2932f[_0x31e348('0x1303')]),_0xf2932f[_0x31e348('0x277c')]=_0x43c24e(function(){},0x3e7),_0x5d6bb9['on'](_0x31e348('0x1591'),_0xf2932f[_0x31e348('0xfb')]),_0x5d6bb9['on']('user:update',_0xf2932f[_0x31e348('0x212c')]),_0x5d6bb9['on'](_0x31e348('0x25f0'),_0xf2932f[_0x31e348('0x1696')]),_0x5d6bb9['on'](_0x31e348('0x663'),_0xf2932f[_0x31e348('0xb9a')]);function _0x2813fd(){const _0xe4416a=_0x31e348,_0x57f2d3=[];return _0x2cfb05()[_0xe4416a('0x941')](_0xf2932f[_0xe4416a('0x7a7')],function(_0x5d71e0,_0x523c0b){const _0x784716=_0xe4416a;_0x5d71e0[_0x784716('0x18b')]=0x0,_0x5d71e0[_0x784716('0x2689')]=0x0,_0xf2932f[_0x784716('0x7a7')][_0x523c0b][_0x784716('0x1f7e')]={},_0x57f2d3[_0x784716('0x1514')](_0x4e652e[_0x784716('0x1943')][_0x784716('0x27d1')]({'id':_0x523c0b})[_0x784716('0xa44')]),_0xf2932f[_0x784716('0x744')][_0x523c0b]&&_0x2cfb05()['merge'](_0x5d71e0,_0x2cfb05()[_0x784716('0x1a08')](_0xf2932f[_0x784716('0x744')][_0x523c0b],_0xd03e53));}),_0x26187a[_0xe4416a('0x2760')](_0x57f2d3)[_0xe4416a('0x1166')](function(_0x3995a4){const _0x314ffc=_0xe4416a;for(let _0x4a64a9=0x0;_0x4a64a9<_0x3995a4[_0x314ffc('0x264b')];_0x4a64a9+=0x1){for(let _0x243268=0x0;_0x243268<_0x3995a4[_0x4a64a9]['rows'][_0x314ffc('0x264b')];_0x243268++){_0x3995a4[_0x4a64a9][_0x314ffc('0x269a')][_0x243268][_0x314ffc('0x18b')]&&_0xf2932f[_0x314ffc('0x7a7')][_0x3995a4[_0x4a64a9]['rows'][_0x243268][_0x314ffc('0xc69')]][_0x314ffc('0x18b')]++,_0xf2932f[_0x314ffc('0x7a7')][_0x3995a4[_0x4a64a9][_0x314ffc('0x269a')][_0x243268][_0x314ffc('0xc69')]][_0x314ffc('0x2689')]++,_0xf2932f['queues'][_0x3995a4[_0x4a64a9][_0x314ffc('0x269a')][_0x243268]['VoiceQueueId']][_0x314ffc('0x1f7e')][_0x3995a4[_0x4a64a9][_0x314ffc('0x269a')][_0x243268]['UserId']]=_0x3995a4[_0x4a64a9][_0x314ffc('0x269a')][_0x243268][_0x314ffc('0xc69')];}}})[_0xe4416a('0x1a80')](function(_0x127fd1){const _0x59c014=_0xe4416a;console[_0x59c014('0xfc9')](_0x127fd1);});}function _0x25ca24(_0x4aaa82){const _0x8eca2e=_0x31e348;_0xf2932f['queues'][_0x4aaa82['id']]&&(_0x2cfb05()[_0x8eca2e('0xcc3')](_0xf2932f[_0x8eca2e('0x7a7')][_0x4aaa82['id']],_0x2cfb05()[_0x8eca2e('0x1a08')](_0x4aaa82,_0xd03e53)),_0x2cfb05()['isNil'](_0x4aaa82[_0x8eca2e('0x6b5')])&&(_0xf2932f['queues'][_0x4aaa82['id']][_0x8eca2e('0x6b5')]=undefined));}function _0x327699(_0x5ce249){const _0xd4d9c=_0x31e348;_0xf2932f[_0xd4d9c('0x7a7')][_0x5ce249[_0xd4d9c('0x70')]]&&_0xf2932f[_0xd4d9c('0x7a7')][_0x5ce249[_0xd4d9c('0x70')]][_0xd4d9c('0x2689')]++;}function _0x10b081(_0x3673c0){const _0x3d710a=_0x31e348;console[_0x3d710a('0x455')]('onPause',_0x3673c0);if(_0x3673c0[_0x3d710a('0x2540')])_0x2cfb05()[_0x3d710a('0x941')](_0xf2932f[_0x3d710a('0x7a7')],function(_0x2c449b){const _0x247b3c=_0x3d710a;_0x2c449b['agents'][_0x3673c0['id']]&&(_0x2c449b[_0x247b3c('0x18b')]+=0x1,console[_0x247b3c('0x455')](_0x247b3c('0x1e77')));});else!_0x3673c0[_0x3d710a('0x2540')]&&_0x2cfb05()[_0x3d710a('0x941')](_0xf2932f[_0x3d710a('0x7a7')],function(_0x36b239){const _0x2965d1=_0x3d710a;_0x36b239[_0x2965d1('0x1f7e')][_0x3673c0['id']]&&(_0x36b239[_0x2965d1('0x18b')]>0x0&&(_0x36b239[_0x2965d1('0x18b')]-=0x1,console[_0x2965d1('0x455')](_0x2965d1('0x20eb'))));});}function _0x5cd1d1(_0x1ddd4b){const _0x407e29=_0x31e348;console['log'](_0x407e29('0x26c1'),_0x1ddd4b),_0xf2932f[_0x407e29('0x7a7')][_0x1ddd4b[_0x407e29('0xc69')]]&&(_0xf2932f['queues'][_0x1ddd4b['VoiceQueueId']][_0x407e29('0x2689')]+=0x1,_0xf2932f[_0x407e29('0x7a7')][_0x1ddd4b[_0x407e29('0xc69')]][_0x407e29('0x1f7e')][_0x1ddd4b[_0x407e29('0x122a')]]=_0x1ddd4b[_0x407e29('0xc69')]);}function _0x2694ea(_0xbd07da){const _0x9e6b3c=_0x31e348;console[_0x9e6b3c('0x455')]('onLogout',_0xbd07da),_0xf2932f[_0x9e6b3c('0x7a7')][_0xbd07da[_0x9e6b3c('0xc69')]]&&_0xf2932f['queues'][_0xbd07da[_0x9e6b3c('0xc69')]]['loggedInDb']>0x0&&(_0xf2932f[_0x9e6b3c('0x7a7')][_0xbd07da[_0x9e6b3c('0xc69')]]['loggedInDb']-=0x1,delete _0xf2932f[_0x9e6b3c('0x7a7')][_0xbd07da['VoiceQueueId']][_0x9e6b3c('0x1f7e')][_0xbd07da[_0x9e6b3c('0x122a')]]);}let _0x5a765a=!![],_0x2c15a7=0x1;_0x1ee976[_0x31e348('0xe83')](_0x31e348('0x12d8'),function(_0x176bf2,_0x411c53){const _0x3cf511=_0x31e348;_0x5a765a?_0x59bf7b(function(){_0x5a765a=![];}):(!_0x411c53&&(_0x2c15a7=_0xf2932f[_0x3cf511('0x2218')]['page']),_0x176bf2!==_0x411c53&&(_0xf2932f[_0x3cf511('0x2218')][_0x3cf511('0x1a43')]=0x1),!_0x176bf2&&(_0xf2932f[_0x3cf511('0x2218')][_0x3cf511('0x1a43')]=_0x2c15a7),_0xf2932f['getQueues']());});function _0x3d3566(_0x3109d6){const _0x5682f7=_0x31e348;_0xf2932f[_0x5682f7('0x240f')]=_0x3109d6[_0x5682f7('0x240f')],_0xf2932f[_0x5682f7('0x7a7')]=_0x3109d6?_0x2cfb05()[_0x5682f7('0x155c')](_0x3109d6[_0x5682f7('0x269a')]?_0x3109d6[_0x5682f7('0x269a')]:[],'id'):{};if(_0x3109d6[_0x5682f7('0x269a')]){_0xf2932f[_0x5682f7('0xa99')]=[];for(let _0x2496e4=0x0;_0x2496e4<_0x3109d6[_0x5682f7('0x269a')]['length'];_0x2496e4++){_0xf2932f[_0x5682f7('0xa99')][_0x5682f7('0x1514')](_0x3109d6['rows'][_0x2496e4]['id']);}}_0x2813fd();}function _0x893d39(){const _0xeb1cb5=_0x31e348;_0xf2932f[_0xeb1cb5('0x2218')]['offset']=(_0xf2932f[_0xeb1cb5('0x2218')][_0xeb1cb5('0x1a43')]-0x1)*_0xf2932f[_0xeb1cb5('0x2218')][_0xeb1cb5('0x163f')],_0x23e177[_0xeb1cb5('0x1ac6')]('admin')?_0xf2932f['promise']=_0x4e652e['voiceQueue'][_0xeb1cb5('0xd83')](_0xf2932f[_0xeb1cb5('0x2218')],_0x3d3566)['$promise']:(_0xf2932f[_0xeb1cb5('0x2218')]['id']=_0xf2932f['userProfile']['id'],_0xf2932f['query'][_0xeb1cb5('0xe60')]='QueueCampaigns',_0xf2932f['promise']=_0x4e652e['userProfile'][_0xeb1cb5('0x263a')](_0xf2932f['query'],_0x3d3566)[_0xeb1cb5('0xa44')]);}function _0x48475c(_0x4ff77a,_0x51a7e2){const _0x505ce7=_0x31e348;_0x1b4c69['show']({'controller':_0x505ce7('0x740'),'controllerAs':'vm','templateUrl':_0xefbac1,'parent':angular[_0x505ce7('0x1194')](_0x162035['body']),'targetEvent':_0x4ff77a,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x51a7e2,'queueCampaigns':_0x2cfb05()[_0x505ce7('0x1ac1')](_0xf2932f[_0x505ce7('0x7a7')]),'license':null,'setting':null,'crudPermissions':_0xf2932f['crudPermissions']}});}function _0x524a74(_0x4740f5,_0x130aa2){const _0x10cb65=_0x31e348;_0x1b4c69[_0x10cb65('0x1f80')]({'controller':'PredictiveQueueCampaignDialogController','controllerAs':'vm','templateUrl':_0x2eb7fe,'parent':angular[_0x10cb65('0x1194')](_0x162035[_0x10cb65('0x8d2')]),'targetEvent':_0x4740f5,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x130aa2}});}function _0x421721(_0x3aa7d0,_0x1d713c){const _0x22dbc7=_0x31e348;_0x1b4c69[_0x22dbc7('0x1f80')]({'controller':_0x22dbc7('0x27c1'),'controllerAs':'vm','templateUrl':_0x1848c7,'parent':angular[_0x22dbc7('0x1194')](_0x162035['body']),'targetEvent':_0x3aa7d0,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x1d713c,'queueCampaigns':_0xf2932f['queues']?_0xf2932f[_0x22dbc7('0x7a7')][_0x22dbc7('0x269a')]:[],'realtime':!![],'crudPermissions':_0xf2932f['crudPermissions']}});}function _0x5dbd86(_0x25e554){const _0x12396e=_0x31e348;return _0x4e652e[_0x12396e('0x1943')][_0x12396e('0x1449')](_0x25e554)['$promise'][_0x12396e('0x1166')](function(){const _0x58393b=_0x12396e;_0x3a35a3['success']({'title':_0x58393b('0x75b'),'msg':_0x25e554[_0x58393b('0x4f0')]?_0x25e554[_0x58393b('0x4f0')]+_0x58393b('0xa17'):''});})[_0x12396e('0x1a80')](function(_0x3a98ee){const _0x2b19ad=_0x12396e;_0x3a35a3['error']({'title':_0x2b19ad('0xa98'),'msg':_0x3a98ee['message']});});}_0x1ee976['$on'](_0x31e348('0x1c3f'),function(){const _0x2f5dbb=_0x31e348;_0x5d6bb9[_0x2f5dbb('0x1800')](_0x2f5dbb('0xa60')),_0xf2932f['interval']&&_0x43c24e[_0x2f5dbb('0x3f')](_0xf2932f[_0x2f5dbb('0x277c')]),_0x5d6bb9['removeAllListeners'](_0x2f5dbb('0x1591')),_0x5d6bb9[_0x2f5dbb('0x1800')](_0x2f5dbb('0x19d5')),_0x5d6bb9[_0x2f5dbb('0x1800')](_0x2f5dbb('0x25f0')),_0x5d6bb9[_0x2f5dbb('0x1800')]('userVoiceQueue:save');});}const _0x44a90d=_0x20874a;_0x48a205[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x10eb'),_0x36e6f4('0x1915')];function _0x48a205(_0x2990d2,_0x450b1a,_0x2333bf){const _0x3a3239=_0x36e6f4,_0x3267c0=this;_0x3267c0[_0x3a3239('0x1915')]=_0x2333bf,_0x3267c0[_0x3a3239('0x239c')]=_0x3ebd4f,_0x3267c0[_0x3a3239('0x1351')]=_0x45780a,_0x3267c0['closeDialog']=_0x37e854;function _0x3ebd4f(_0x4d8ff0,_0x2598c7){const _0x581267=_0x3a3239;return _0x24273b()(_0x4d8ff0)[_0x581267('0x126a')]('m',_0x2598c7)[_0x581267('0x128a')](_0x581267('0x1a09'));}function _0x45780a(_0x30f1f5){const _0x6ceee5=_0x3a3239;return _0x24273b()(_0x30f1f5)[_0x6ceee5('0x128a')](_0x6ceee5('0x1a09'));}function _0x37e854(){const _0x4ff793=_0x3a3239;_0x2990d2[_0x4ff793('0x1197')]();}}const _0x38bf62=_0x48a205;function _0xd6ae10(){const _0x2b6582=_0x36e6f4;return{'status':{'registered':'green-300-fg\x20icon-checkbox-marked-circle','unregistered':'red-300-fg\x20icon-close-circle','lagged':_0x2b6582('0x278f'),'reachable':_0x2b6582('0x23ca'),'unreachable':_0x2b6582('0x278f'),'unknown':_0x2b6582('0x2125')},'state':{'unknown':'grey-fg\x20icon-phone-hangup','not_inuse':_0x2b6582('0xa1e'),'inuse':_0x2b6582('0xa2f'),'busy':'red-300-fg\x20icon-phone-locked','invalid':'grey-fg\x20icon-phone-hangup','unavailable':'grey-fg\x20icon-phone-hangup','ringing':_0x2b6582('0x132c'),'ringinuse':_0x2b6582('0x132c'),'onhold':'blue-300-fg\x20icon-phone-paused'},'channelStatus':{'ring':_0x2b6582('0x132c'),'up':_0x2b6582('0x20b2'),'hangup':_0x2b6582('0x9e3')},'channelStatusOut':{'ring':'blue-300-fg\x20icon-phone-outgoing','up':_0x2b6582('0x20b2'),'hangup':_0x2b6582('0x9e3')}};}const _0x4e1e6b=_0xd6ae10;_0x3f3d4a[_0x36e6f4('0x1294')]=['$scope','$state',_0x36e6f4('0x2661')];function _0x3f3d4a(_0x296e31,_0x4cb155,_0x2435ca){const _0x1139b5=_0x36e6f4,_0x526020=this;_0x2435ca[_0x1139b5('0x670')](),_0x2435ca[_0x1139b5('0x7bb')](),_0x526020[_0x1139b5('0x2669')]=0x0;switch(_0x4cb155['current'][_0x1139b5('0x4f0')]){case _0x1139b5('0x1e00'):_0x526020[_0x1139b5('0x2669')]=0x0;break;case'app.motiondialer.realtime.queues':_0x526020['selectedTab']=0x1;break;case'app.motiondialer.realtime.queue_calls':_0x526020[_0x1139b5('0x2669')]=0x2;break;case _0x1139b5('0x1d2'):_0x526020[_0x1139b5('0x2669')]=0x3;break;case _0x1139b5('0x183e'):_0x526020[_0x1139b5('0x2669')]=0x4;break;case _0x1139b5('0x2328'):_0x526020[_0x1139b5('0x2669')]=0x5;break;default:_0x526020[_0x1139b5('0x2669')]=0x0,_0x4cb155['go'](_0x1139b5('0x1e00'));}_0x296e31['$watch'](_0x1139b5('0x27a7'),function(_0x38a7b9,_0x54fc73){const _0x48bb39=_0x1139b5;if(_0x38a7b9!==_0x54fc73)switch(_0x38a7b9){case 0x0:_0x4cb155['go'](_0x48bb39('0x1e00'));break;case 0x1:_0x4cb155['go'](_0x48bb39('0x745'));break;case 0x2:_0x4cb155['go']('app.motiondialer.realtime.queue_calls');break;case 0x3:_0x4cb155['go'](_0x48bb39('0x1d2'));break;case 0x4:_0x4cb155['go'](_0x48bb39('0x183e'));break;case 0x5:_0x4cb155['go']('app.motiondialer.realtime.ivr_campaigns');break;default:_0x4cb155['go']('app.motiondialer.realtime.agents');}});}const _0x2f897a=_0x3f3d4a;_0x58382e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x58382e(_0x4a672b){const _0x3bac6e=_0x36e6f4;_0x4a672b[_0x3bac6e('0x63f')](_0x3bac6e('0x1f08'),{'url':_0x3bac6e('0x1c2e'),'views':{'content@app':{'templateUrl':_0x1ecd76,'controller':_0x3bac6e('0x41d')}},'resolve':{'userProfile':['apiResolver','Auth',function(_0x2766ea,_0x50c7b3){const _0x42210d=_0x3bac6e;return _0x50c7b3[_0x42210d('0x1ac6')]('admin')?null:_0x2766ea['resolve']('userProfile@get',{'fields':_0x42210d('0x686'),'id':_0x50c7b3['getCurrentUser']()['userProfileId']});}],'userProfileSection':['apiResolver',_0x3bac6e('0x21ef'),function(_0x1cf35d,_0x42843e){const _0x47587e=_0x3bac6e;return _0x42843e['hasRole'](_0x47587e('0xa7c'))?null:_0x1cf35d['resolve'](_0x47587e('0xaf'),{'fields':_0x47587e('0xe26'),'userProfileId':_0x42843e[_0x47587e('0x26cd')]()['userProfileId'],'sectionId':0x5e6});}]},'authenticate':!![],'permissionId':0x5e6})[_0x3bac6e('0x63f')]('app.motiondialer.realtime.agents',{'url':_0x3bac6e('0x730'),'controller':_0x3bac6e('0x89f'),'templateUrl':_0x5f5836,'resolve':{'pauses':[_0x3bac6e('0x1fbc'),function(_0x19ac27){const _0x54d8d2=_0x3bac6e;return _0x19ac27[_0x54d8d2('0x18af')](_0x54d8d2('0x737'),{'nolimit':!![]});}],'agents':['apiResolver',_0x3bac6e('0x21ef'),function(_0x2304c4,_0xe7819c){const _0xceca7e=_0x3bac6e;return _0xe7819c[_0xceca7e('0x1ac6')]('admin')?_0x2304c4[_0xceca7e('0x18af')](_0xceca7e('0x1c80'),{'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':'agent','sort':_0xceca7e('0x6e1'),'nolimit':!![]}):_0x2304c4['resolve'](_0xceca7e('0x17c4'),{'id':_0xe7819c[_0xceca7e('0x26cd')]()[_0xceca7e('0xb86')],'section':_0xceca7e('0x2391'),'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0xceca7e('0x1eff'),'sort':_0xceca7e('0x6e1'),'nolimit':!![]});}],'userProfile':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x5337af,_0x4fdc64){const _0x4b92b4=_0x3bac6e;return _0x4fdc64['hasRole']('admin')?null:_0x5337af[_0x4b92b4('0x18af')](_0x4b92b4('0x697'),{'fields':_0x4b92b4('0x686'),'id':_0x4fdc64[_0x4b92b4('0x26cd')]()[_0x4b92b4('0xb86')]});}],'userProfileSection':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x290cc8,_0x237440){const _0x45d45b=_0x3bac6e;return _0x237440[_0x45d45b('0x1ac6')]('admin')?null:_0x290cc8[_0x45d45b('0x18af')](_0x45d45b('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x237440[_0x45d45b('0x26cd')]()[_0x45d45b('0xb86')],'sectionId':0xca});}],'rpcAgents':[_0x3bac6e('0x1fbc'),function(_0x5edf92){const _0x429dd8=_0x3bac6e;return _0x5edf92[_0x429dd8('0x18af')](_0x429dd8('0xfab'));}]},'authenticate':!![],'permissionId':0x5e6})[_0x3bac6e('0x63f')](_0x3bac6e('0x745'),{'url':_0x3bac6e('0x1bd2'),'controller':'QueuesMotionDialerRealtimeController\x20as\x20vm','templateUrl':_0x145033,'resolve':{'queues':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x328088,_0x121404){const _0x3ac0d1=_0x3bac6e;return _0x121404[_0x3ac0d1('0x1ac6')](_0x3ac0d1('0xa7c'))?_0x328088['resolve']('voiceQueue@get',{'type':_0x3ac0d1('0x587'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x328088[_0x3ac0d1('0x18af')](_0x3ac0d1('0x17c4'),{'id':_0x121404[_0x3ac0d1('0x26cd')]()[_0x3ac0d1('0xb86')],'section':_0x3ac0d1('0x9f4'),'channel':_0x3ac0d1('0x21da'),'type':_0x3ac0d1('0x587'),'sort':_0x3ac0d1('0x14dc'),'limit':0xa,'page':0x1});}],'userProfile':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0xe3c301,_0x10c219){const _0x3b0e51=_0x3bac6e;return _0x10c219['hasRole'](_0x3b0e51('0xa7c'))?null:_0xe3c301[_0x3b0e51('0x18af')](_0x3b0e51('0x697'),{'fields':_0x3b0e51('0x686'),'id':_0x10c219[_0x3b0e51('0x26cd')]()[_0x3b0e51('0xb86')]});}],'userProfileSection':[_0x3bac6e('0x1fbc'),'Auth',function(_0x3717db,_0x5b809d){const _0x24c224=_0x3bac6e;return _0x5b809d[_0x24c224('0x1ac6')](_0x24c224('0xa7c'))?null:_0x3717db[_0x24c224('0x18af')]('userProfileSection@get',{'fields':_0x24c224('0xe26'),'userProfileId':_0x5b809d['getCurrentUser']()[_0x24c224('0xb86')],'sectionId':0x5dd});}],'rpcQueues':[_0x3bac6e('0x1fbc'),function(_0x172581){const _0x4cb7f2=_0x3bac6e;return _0x172581[_0x4cb7f2('0x18af')](_0x4cb7f2('0x85d'));}]},'authenticate':!![],'permissionId':0x5e6})['state'](_0x3bac6e('0x1023'),{'url':'/queue_calls','controller':_0x3bac6e('0x239d'),'templateUrl':_0x4ef973,'resolve':{'agents':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x31c283,_0x3d16fe){const _0x2aa815=_0x3bac6e;return _0x3d16fe[_0x2aa815('0x1ac6')]('admin')?_0x31c283['resolve'](_0x2aa815('0x1c80'),{'fields':_0x2aa815('0x1111'),'role':_0x2aa815('0x1eff'),'nolimit':!![]}):_0x31c283[_0x2aa815('0x18af')]('userProfile@getResources',{'id':_0x3d16fe[_0x2aa815('0x26cd')]()[_0x2aa815('0xb86')],'section':_0x2aa815('0x2391'),'fields':_0x2aa815('0x1111'),'role':_0x2aa815('0x1eff'),'nolimit':!![]});}],'queues':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x1d5793,_0x3afe9e){const _0x5982f3=_0x3bac6e;return _0x3afe9e['hasRole'](_0x5982f3('0xa7c'))?_0x1d5793[_0x5982f3('0x18af')](_0x5982f3('0x2700'),{'type':_0x5982f3('0x587'),'sort':_0x5982f3('0x14dc'),'nolimit':!![]}):_0x1d5793[_0x5982f3('0x18af')](_0x5982f3('0x17c4'),{'id':_0x3afe9e[_0x5982f3('0x26cd')]()['userProfileId'],'section':_0x5982f3('0x9f4'),'channel':'voice','type':_0x5982f3('0x587'),'sort':_0x5982f3('0x14dc'),'nolimit':!![]});}],'userProfile':['apiResolver','Auth',function(_0x252838,_0x4269ed){const _0x2bbd38=_0x3bac6e;return _0x4269ed['hasRole']('admin')?null:_0x252838['resolve']('userProfile@get',{'fields':_0x2bbd38('0x686'),'id':_0x4269ed[_0x2bbd38('0x26cd')]()[_0x2bbd38('0xb86')]});}],'userProfileSection':[_0x3bac6e('0x1fbc'),'Auth',function(_0x282a98,_0x361d10){const _0x590a8d=_0x3bac6e;return _0x361d10[_0x590a8d('0x1ac6')](_0x590a8d('0xa7c'))?null:_0x282a98[_0x590a8d('0x18af')](_0x590a8d('0xaf'),{'fields':_0x590a8d('0xe26'),'userProfileId':_0x361d10[_0x590a8d('0x26cd')]()[_0x590a8d('0xb86')],'sectionId':0x5dd});}],'rpcVoiceQueuesChannels':[_0x3bac6e('0x1fbc'),function(_0x35328d){const _0x16ab46=_0x3bac6e;return _0x35328d['resolve'](_0x16ab46('0x25a'));}]},'authenticate':!![],'permissionId':0x5e6})['state'](_0x3bac6e('0x1d2'),{'url':_0x3bac6e('0x2714'),'controller':'AbandonedCallsMotionDialerRealtimeController\x20as\x20vm','templateUrl':_0x1cbbb9,'resolve':{'agents':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x2be5dd,_0xb7fbc3){const _0x35fa89=_0x3bac6e;return _0xb7fbc3[_0x35fa89('0x1ac6')](_0x35fa89('0xa7c'))?_0x2be5dd[_0x35fa89('0x18af')](_0x35fa89('0x1c80'),{'fields':'id,name,role,context','role':_0x35fa89('0x1eff'),'nolimit':!![]}):_0x2be5dd[_0x35fa89('0x18af')](_0x35fa89('0x17c4'),{'id':_0xb7fbc3[_0x35fa89('0x26cd')]()[_0x35fa89('0xb86')],'section':_0x35fa89('0x2391'),'fields':_0x35fa89('0x1111'),'role':_0x35fa89('0x1eff'),'nolimit':!![]});}],'queues':['apiResolver',_0x3bac6e('0x21ef'),function(_0x4eea6f,_0x53ed9b){const _0x2e4cd5=_0x3bac6e;return _0x53ed9b[_0x2e4cd5('0x1ac6')](_0x2e4cd5('0xa7c'))?_0x4eea6f[_0x2e4cd5('0x18af')](_0x2e4cd5('0x2700'),{'type':_0x2e4cd5('0x587'),'sort':_0x2e4cd5('0x14dc'),'nolimit':!![]}):_0x4eea6f['resolve'](_0x2e4cd5('0x17c4'),{'id':_0x53ed9b[_0x2e4cd5('0x26cd')]()[_0x2e4cd5('0xb86')],'section':_0x2e4cd5('0x9f4'),'channel':'voice','type':'outbound','sort':_0x2e4cd5('0x14dc'),'nolimit':!![]});}],'dispositions':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x2074df,_0x18b5a5){const _0x474490=_0x3bac6e;return _0x18b5a5[_0x474490('0x1ac6')](_0x474490('0xa7c'))?_0x2074df[_0x474490('0x18af')](_0x474490('0x1e98'),{'fields':'createdAt,updatedAt,id,name,level,ParentId','sort':'-updatedAt','MailAccountId':'null','FaxAccountId':_0x474490('0x15d7'),'SmsAccountId':_0x474490('0x15d7'),'WhatsappAccountId':_0x474490('0x15d7'),'OpenchannelAccountId':_0x474490('0x15d7'),'ChatWebsiteId':_0x474490('0x15d7'),'ListId':_0x474490('0x15d7'),'nolimit':!![]}):_0x2074df['resolve'](_0x474490('0x17c4'),{'id':_0x18b5a5[_0x474490('0x26cd')]()[_0x474490('0xb86')],'section':_0x474490('0x10fb'),'fields':'createdAt,updatedAt,id,name','sort':_0x474490('0x14dc'),'MailAccountId':_0x474490('0x15d7'),'FaxAccountId':_0x474490('0x15d7'),'SmsAccountId':_0x474490('0x15d7'),'WhatsappAccountId':_0x474490('0x15d7'),'OpenchannelAccountId':'null','ChatWebsiteId':_0x474490('0x15d7'),'ListId':_0x474490('0x15d7'),'nolimit':!![]});}],'userProfile':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x82a0fb,_0x5243af){const _0x120fe5=_0x3bac6e;return _0x5243af['hasRole'](_0x120fe5('0xa7c'))?null:_0x82a0fb['resolve'](_0x120fe5('0x697'),{'fields':_0x120fe5('0x686'),'id':_0x5243af[_0x120fe5('0x26cd')]()[_0x120fe5('0xb86')]});}],'userProfileSection':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x3fcaf5,_0x548803){const _0x359964=_0x3bac6e;return _0x548803[_0x359964('0x1ac6')]('admin')?null:_0x3fcaf5[_0x359964('0x18af')](_0x359964('0xaf'),{'fields':_0x359964('0xe26'),'userProfileId':_0x548803[_0x359964('0x26cd')]()[_0x359964('0xb86')],'sectionId':0x5dd});}]},'authenticate':!![],'permissionId':0x5e6})[_0x3bac6e('0x63f')](_0x3bac6e('0x183e'),{'url':_0x3bac6e('0x268d'),'controller':'QueueParamsMotionDialerRealtimeController\x20as\x20vm','templateUrl':_0x1488b7,'resolve':{'queues':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x110f12,_0x3ea916){const _0x212743=_0x3bac6e;return _0x3ea916['hasRole']('admin')?_0x110f12[_0x212743('0x18af')](_0x212743('0x2700'),{'type':'outbound','fields':_0x212743('0x1776'),'sort':_0x212743('0x14dc'),'limit':0xa,'offset':0x0}):_0x110f12['resolve'](_0x212743('0x17c4'),{'id':_0x3ea916['getCurrentUser']()[_0x212743('0xb86')],'section':_0x212743('0x9f4'),'channel':_0x212743('0x21da'),'type':'outbound','sort':_0x212743('0x14dc'),'nolimit':!![]});}],'userProfile':[_0x3bac6e('0x1fbc'),'Auth',function(_0x4b1fbb,_0x3eb753){const _0x9d2820=_0x3bac6e;return _0x3eb753['hasRole'](_0x9d2820('0xa7c'))?null:_0x4b1fbb[_0x9d2820('0x18af')](_0x9d2820('0x697'),{'fields':_0x9d2820('0x686'),'id':_0x3eb753[_0x9d2820('0x26cd')]()[_0x9d2820('0xb86')]});}],'userProfileSection':['apiResolver',_0x3bac6e('0x21ef'),function(_0x5985be,_0x260c6e){const _0x3e7a66=_0x3bac6e;return _0x260c6e['hasRole'](_0x3e7a66('0xa7c'))?null:_0x5985be[_0x3e7a66('0x18af')]('userProfileSection@get',{'fields':_0x3e7a66('0xe26'),'userProfileId':_0x260c6e[_0x3e7a66('0x26cd')]()['userProfileId'],'sectionId':0x5dd});}],'rpcQueues':[_0x3bac6e('0x1fbc'),function(_0x28bff9){const _0x335661=_0x3bac6e;return _0x28bff9[_0x335661('0x18af')](_0x335661('0x85d'));}]},'authenticate':!![],'permissionId':0x5e6})[_0x3bac6e('0x63f')](_0x3bac6e('0x2328'),{'url':'/ivr_campaigns','controller':_0x3bac6e('0x189b'),'templateUrl':_0x5a22d1,'resolve':{'campaigns':[_0x3bac6e('0x1fbc'),'Auth',function(_0x433402,_0x23925c){const _0x4b567d=_0x3bac6e;return _0x23925c[_0x4b567d('0x1ac6')](_0x4b567d('0xa7c'))?_0x433402[_0x4b567d('0x18af')](_0x4b567d('0xa31'),{'sort':_0x4b567d('0x14dc'),'limit':0xa,'offset':0x0}):_0x433402[_0x4b567d('0x18af')](_0x4b567d('0x17c4'),{'id':_0x23925c[_0x4b567d('0x26cd')]()[_0x4b567d('0xb86')],'section':_0x4b567d('0x9d3'),'sort':_0x4b567d('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x3fde7e,_0x23c012){const _0x59b869=_0x3bac6e;return _0x23c012['hasRole'](_0x59b869('0xa7c'))?null:_0x3fde7e['resolve'](_0x59b869('0x697'),{'fields':_0x59b869('0x686'),'id':_0x23c012['getCurrentUser']()[_0x59b869('0xb86')]});}],'userProfileSection':[_0x3bac6e('0x1fbc'),_0x3bac6e('0x21ef'),function(_0x4e669e,_0x88e48d){const _0xb66ce4=_0x3bac6e;return _0x88e48d[_0xb66ce4('0x1ac6')](_0xb66ce4('0xa7c'))?null:_0x4e669e[_0xb66ce4('0x18af')](_0xb66ce4('0xaf'),{'fields':_0xb66ce4('0xe26'),'userProfileId':_0x88e48d[_0xb66ce4('0x26cd')]()[_0xb66ce4('0xb86')],'sectionId':0x5de});}],'rpcCampaigns':[_0x3bac6e('0x1fbc'),function(_0x2b9253){const _0x4fcc70=_0x3bac6e;return _0x2b9253[_0x4fcc70('0x18af')](_0x4fcc70('0x197c'));}]},'authenticate':!![],'permissionId':0x5e6});}angular['module'](_0x36e6f4('0x1f08'),[])[_0x36e6f4('0xe11')](_0x58382e)['controller'](_0x36e6f4('0x98a'),_0x5c86d7)[_0x36e6f4('0x75e')]('AgentsMotionDialerRealtimeController',_0x1c858b)[_0x36e6f4('0x75e')](_0x36e6f4('0x1164'),_0x507bf8)[_0x36e6f4('0x75e')](_0x36e6f4('0x742'),_0x379172)[_0x36e6f4('0x75e')](_0x36e6f4('0x26e4'),_0x193ed4)[_0x36e6f4('0x75e')](_0x36e6f4('0x2536'),_0x44a90d)[_0x36e6f4('0x75e')]('PredictiveQueueCampaignDialogController',_0x38bf62)[_0x36e6f4('0x87c')](_0x36e6f4('0x1a02'),_0x4e1e6b)['controller'](_0x36e6f4('0x2778'),_0x2f897a);const _0x28598d=_0x2734b2['p']+_0x36e6f4('0x61e'),_0xe20aad=_0x2734b2['p']+_0x36e6f4('0x1db8'),_0x1bfa25=_0x2734b2['p']+_0x36e6f4('0x1cbd'),_0x1666fc=_0x2734b2['p']+_0x36e6f4('0x2807');_0x1efa02[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x5b8'),_0x36e6f4('0xedf'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x1efa02(_0x4cc00b,_0x19c43f,_0x367753,_0x1b23c5,_0x2c1ab5,_0xe14dbb,_0x1ea677,_0x3d8277,_0x426276,_0x25c7dd,_0x164273,_0x29becf,_0x5ad2a0,_0x377ab8){const _0x1bb0f9=_0x36e6f4,_0x1b5da5=this;_0x1b5da5['currentUser']=_0x164273[_0x1bb0f9('0x26cd')](),_0x1b5da5[_0x1bb0f9('0x61a')]=[],_0x1b5da5[_0x1bb0f9('0xf8a')]=_0x5ad2a0,_0x1b5da5[_0x1bb0f9('0x5c9')]=_0x29becf,_0x1b5da5[_0x1bb0f9('0x243c')]=_0x377ab8,_0x1b5da5['hasModulePermissions']={},_0x1b5da5[_0x1bb0f9('0x2900')]=_0x1b5da5['setting']&&_0x1b5da5[_0x1bb0f9('0xf8a')][_0x1bb0f9('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1b5da5[_0x1bb0f9('0xcdc')]=_0x1bb0f9('0x57e'),_0x1b5da5['ivrCampaign']=angular[_0x1bb0f9('0x225f')](_0x426276),_0x1b5da5[_0x1bb0f9('0x5b8')]=_0x3d8277,_0x1b5da5[_0x1bb0f9('0x3f6')]=![];!_0x1b5da5[_0x1bb0f9('0xedf')]&&(_0x1b5da5[_0x1bb0f9('0xedf')]={'active':!![],'type':'ivr','dialCheckDuplicateType':'always','dialCutDigit':0x0,'limitCalls':0x1e,'dialRandomLastDigitCallerIdNumber':0x0,'dialOriginateTimeout':0x1e,'dialGlobalMaxRetry':0x4,'dialCongestionMaxRetry':0x3,'dialCongestionRetryFrequency':0x96,'dialBusyMaxRetry':0x3,'dialBusyRetryFrequency':0x96,'dialNoAnswerMaxRetry':0x3,'dialNoAnswerRetryFrequency':0x96,'dialNoSuchNumberMaxRetry':0x3,'dialNoSuchNumberRetryFrequency':0x96,'dialDropMaxRetry':0x3,'dialDropRetryFrequency':0x96,'dialAbandonedMaxRetry':0x3,'dialAbandonedRetryFrequency':0x96,'dialMachineMaxRetry':0x3,'dialMachineRetryFrequency':0x96,'dialAgentRejectMaxRetry':0x3,'dialAgentRejectRetryFrequency':0x96,'dialOrderByScheduledAt':'ASC','dialGlobalInterval':'07:00-22:00,*,*,*','dialAMDInitialSilence':0x9c4,'dialAMDGreeting':0x5dc,'dialAMDAfterGreetingSilence':0x320,'dialAMDTotalAnalysisTime':0x1388,'dialAMDMinWordLength':0x64,'dialAMDBetweenWordsSilence':0x32,'dialAMDMaximumNumberOfWords':0x3,'dialAMDSilenceThreshold':0x100,'dialAMDMaximumWordLength':0x1388},_0x1b5da5[_0x1bb0f9('0xcdc')]='MOTIONDIALER.NEW_IVRCAMPAIGN',_0x1b5da5['newIvrCampaign']=!![]);_0x1b5da5[_0x1bb0f9('0x270')]=_0x20927a,_0x1b5da5[_0x1bb0f9('0x123a')]=_0x149828,_0x1b5da5[_0x1bb0f9('0x1537')]=_0x2aacf1,_0x1b5da5['getDateFromString']=_0x1fda31,_0x1b5da5[_0x1bb0f9('0x24a0')]=_0x156cf2,_0x164273[_0x1bb0f9('0x1ac6')](_0x1bb0f9('0xa7c'))?_0x25c7dd[_0x1bb0f9('0x3b2')][_0x1bb0f9('0xd83')]({'fields':_0x1bb0f9('0x1776'),'sort':_0x1bb0f9('0x4f0'),'table':_0x1bb0f9('0xf3b')})['$promise'][_0x1bb0f9('0x1166')](function(_0x4f525b){const _0x24ae63=_0x1bb0f9;_0x1b5da5[_0x24ae63('0xf24')]=_0x4f525b[_0x24ae63('0x269a')]||[];})[_0x1bb0f9('0x1a80')](function(_0x2e3009){const _0x38a3b5=_0x1bb0f9;_0x1ea677[_0x38a3b5('0xfc9')]({'title':_0x2e3009[_0x38a3b5('0x52d')]?_0x38a3b5('0x1e21')+_0x2e3009[_0x38a3b5('0x52d')]+'\x20-\x20'+_0x2e3009[_0x38a3b5('0xe1b')]:'SYSTEM:GET_TRUNKS','msg':_0x2e3009[_0x38a3b5('0x25f4')]?JSON[_0x38a3b5('0xbac')](_0x2e3009[_0x38a3b5('0x25f4')]):_0x2e3009[_0x38a3b5('0x1586')]()});}):_0x25c7dd[_0x1bb0f9('0x3b2')][_0x1bb0f9('0xd83')]({'fields':_0x1bb0f9('0x1776'),'sort':'name','table':_0x1bb0f9('0xf3b')})[_0x1bb0f9('0xa44')][_0x1bb0f9('0x1166')](function(_0xbd21a3){const _0x16f94f=_0x1bb0f9;_0x1b5da5[_0x16f94f('0xf24')]=_0xbd21a3['rows']||[];})[_0x1bb0f9('0x1166')](function(){const _0x23c693=_0x1bb0f9;return _0x25c7dd[_0x23c693('0x17aa')]['get']({'userProfileId':_0x1b5da5[_0x23c693('0x98')]['userProfileId'],'sectionId':0x3f3})[_0x23c693('0xa44')];})[_0x1bb0f9('0x1166')](function(_0xb8ae03){const _0x300f40=_0x1bb0f9,_0x15354e=_0xb8ae03&&_0xb8ae03[_0x300f40('0x269a')]?_0xb8ae03[_0x300f40('0x269a')][0x0]:null;if(!_0x15354e)_0x1b5da5[_0x300f40('0xf24')]=[];else{if(!_0x15354e['autoAssociation'])return _0x25c7dd[_0x300f40('0x4b5')][_0x300f40('0xd83')]({'sectionId':_0x15354e['id']})[_0x300f40('0xa44')][_0x300f40('0x1166')](function(_0x50f001){const _0x4f5eb6=_0x300f40,_0x2c9574=_0x2cfb05()[_0x4f5eb6('0x2563')](_0x50f001[_0x4f5eb6('0x269a')],function(_0x4298f9){const _0x181488=_0x4f5eb6;return _0x2cfb05()['find'](_0x1b5da5['trunks'],{'id':_0x4298f9[_0x181488('0x24e8')]});});_0x1b5da5['trunks'][_0x4f5eb6('0x2782')](function(_0x51afbf){const _0x31e698=_0x4f5eb6;!_0x2cfb05()[_0x31e698('0x1798')](_0x2c9574,['id',_0x51afbf['id']])&&(_0x51afbf['canSelect']=![]),_0x2c9574[_0x31e698('0x1514')](_0x51afbf);}),_0x1b5da5[_0x4f5eb6('0xf24')]=_0x2c9574;});}})[_0x1bb0f9('0x1a80')](function(_0x215f58){const _0x3cc594=_0x1bb0f9;_0x1ea677[_0x3cc594('0xfc9')]({'title':_0x215f58[_0x3cc594('0x52d')]?'API:'+_0x215f58['status']+_0x3cc594('0x11e1')+_0x215f58[_0x3cc594('0xe1b')]:_0x3cc594('0x1d44'),'msg':_0x215f58['data']?JSON[_0x3cc594('0xbac')](_0x215f58[_0x3cc594('0x25f4')]):_0x215f58['toString']()});}),_0x164273[_0x1bb0f9('0x1ac6')](_0x1bb0f9('0xa7c'))?_0x25c7dd[_0x1bb0f9('0x7e4')]['get']({'fields':_0x1bb0f9('0x1776'),'sort':'name'})[_0x1bb0f9('0xa44')]['then'](function(_0x456ff3){const _0x2e8d81=_0x1bb0f9;_0x1b5da5['projects']=_0x456ff3[_0x2e8d81('0x269a')]||[];})[_0x1bb0f9('0x1a80')](function(_0x12d5cd){const _0x212e45=_0x1bb0f9;_0x1ea677[_0x212e45('0xfc9')]({'title':_0x12d5cd[_0x212e45('0x52d')]?_0x212e45('0x1e21')+_0x12d5cd['status']+_0x212e45('0x11e1')+_0x12d5cd[_0x212e45('0xe1b')]:_0x212e45('0x178b'),'msg':_0x12d5cd['data']?JSON[_0x212e45('0xbac')](_0x12d5cd['data']):_0x12d5cd['toString']()});}):_0x25c7dd['squareProject'][_0x1bb0f9('0xd83')]({'fields':_0x1bb0f9('0x1776'),'sort':_0x1bb0f9('0x4f0')})[_0x1bb0f9('0xa44')][_0x1bb0f9('0x1166')](function(_0x9ff242){const _0x1fdedd=_0x1bb0f9;_0x1b5da5[_0x1fdedd('0x149f')]=_0x9ff242['rows']||[];})['then'](function(){const _0x163e39=_0x1bb0f9;return _0x25c7dd[_0x163e39('0x17aa')]['get']({'userProfileId':_0x1b5da5[_0x163e39('0x98')][_0x163e39('0xb86')],'sectionId':0x44f})['$promise'];})[_0x1bb0f9('0x1166')](function(_0x1bd25f){const _0x34128d=_0x1bb0f9,_0x53db7c=_0x1bd25f&&_0x1bd25f['rows']?_0x1bd25f[_0x34128d('0x269a')][0x0]:null;if(!_0x53db7c){const _0x4962e3=[];let _0x35f227=null;_0x1b5da5['ivrCampaign']&&(_0x35f227=_0x2cfb05()['find'](_0x1b5da5[_0x34128d('0x149f')],{'id':Number(_0x1b5da5['ivrCampaign'][_0x34128d('0x28a9')])}));for(let _0x55ee4d=0x0;_0x55ee4d<_0x1b5da5[_0x34128d('0x149f')][_0x34128d('0x264b')];_0x55ee4d++){_0x35f227&&_0x1b5da5['projects'][_0x55ee4d]['id']===_0x35f227['id']&&(_0x1b5da5['projects'][_0x55ee4d][_0x34128d('0x2378')]=![],_0x4962e3[_0x34128d('0x1514')](_0x1b5da5['projects'][_0x55ee4d]));}_0x1b5da5[_0x34128d('0x149f')]=_0x4962e3;}else{if(!_0x53db7c[_0x34128d('0x1a2b')])return _0x25c7dd[_0x34128d('0x4b5')][_0x34128d('0xd83')]({'sectionId':_0x53db7c['id']})[_0x34128d('0xa44')][_0x34128d('0x1166')](function(_0x3e93ec){const _0x4c8ba9=_0x34128d,_0x16134b=_0x2cfb05()[_0x4c8ba9('0x2563')](_0x3e93ec[_0x4c8ba9('0x269a')],function(_0x2b2409){return _0x2cfb05()['find'](_0x1b5da5['projects'],{'id':_0x2b2409['resourceId']});});let _0x524a1f=null;_0x1b5da5['ivrCampaign']&&(_0x524a1f=_0x2cfb05()[_0x4c8ba9('0xc38')](_0x1b5da5[_0x4c8ba9('0x149f')],{'id':Number(_0x1b5da5[_0x4c8ba9('0xedf')][_0x4c8ba9('0x28a9')])}));if(_0x524a1f&&!_0x2cfb05()[_0x4c8ba9('0x1798')](_0x16134b,['id',_0x524a1f['id']])){const _0x450748=_0x2cfb05()['find'](_0x1b5da5[_0x4c8ba9('0x149f')],{'id':_0x524a1f['id']});_0x450748[_0x4c8ba9('0x2378')]=![],_0x16134b[_0x4c8ba9('0x1514')](_0x450748);}_0x1b5da5['projects']=_0x16134b;});}})['catch'](function(_0x27b6a3){const _0x167fc3=_0x1bb0f9;_0x1ea677[_0x167fc3('0xfc9')]({'title':_0x27b6a3[_0x167fc3('0x52d')]?_0x167fc3('0x1e21')+_0x27b6a3[_0x167fc3('0x52d')]+'\x20-\x20'+_0x27b6a3[_0x167fc3('0xe1b')]:'SYSTEM:GETprojects','msg':_0x27b6a3[_0x167fc3('0x25f4')]?JSON['stringify'](_0x27b6a3[_0x167fc3('0x25f4')]):_0x27b6a3[_0x167fc3('0x1586')]()});}),_0x164273[_0x1bb0f9('0x1ac6')](_0x1bb0f9('0xa7c'))?_0x25c7dd[_0x1bb0f9('0x277c')][_0x1bb0f9('0xd83')]({'fields':_0x1bb0f9('0x1776'),'sort':_0x1bb0f9('0x4f0'),'IntervalId':_0x1bb0f9('0x15d7')})[_0x1bb0f9('0xa44')][_0x1bb0f9('0x1166')](function(_0x1cee87){const _0x4d6d1b=_0x1bb0f9;_0x1b5da5['interval']=_0x1cee87[_0x4d6d1b('0x269a')]||[];})[_0x1bb0f9('0x1a80')](function(_0x3f770c){const _0x3d5c6a=_0x1bb0f9;_0x1ea677[_0x3d5c6a('0xfc9')]({'title':_0x3f770c['status']?_0x3d5c6a('0x1e21')+_0x3f770c['status']+_0x3d5c6a('0x11e1')+_0x3f770c[_0x3d5c6a('0xe1b')]:_0x3d5c6a('0x2451'),'msg':_0x3f770c[_0x3d5c6a('0x25f4')]?JSON[_0x3d5c6a('0xbac')](_0x3f770c[_0x3d5c6a('0x25f4')]):_0x3f770c['toString']()});}):_0x25c7dd[_0x1bb0f9('0x277c')]['get']({'fields':'id,name','sort':_0x1bb0f9('0x4f0'),'IntervalId':_0x1bb0f9('0x15d7')})[_0x1bb0f9('0xa44')][_0x1bb0f9('0x1166')](function(_0x12741f){const _0x26373b=_0x1bb0f9;_0x1b5da5[_0x26373b('0x277c')]=_0x12741f[_0x26373b('0x269a')]||[];})[_0x1bb0f9('0x1166')](function(){const _0x10de2f=_0x1bb0f9;return _0x25c7dd[_0x10de2f('0x17aa')][_0x10de2f('0xd83')]({'userProfileId':_0x1b5da5[_0x10de2f('0x98')][_0x10de2f('0xb86')],'sectionId':0x3ec})[_0x10de2f('0xa44')];})[_0x1bb0f9('0x1166')](function(_0x4ca5b9){const _0x1be5c0=_0x1bb0f9,_0x30afc1=_0x4ca5b9&&_0x4ca5b9['rows']?_0x4ca5b9['rows'][0x0]:null;if(!_0x30afc1){const _0x2f1312=[];let _0x3408a8=null;_0x1b5da5[_0x1be5c0('0xedf')]&&(_0x3408a8=_0x2cfb05()[_0x1be5c0('0xc38')](_0x1b5da5['interval'],{'id':Number(_0x1b5da5[_0x1be5c0('0xedf')][_0x1be5c0('0x186f')])}));for(let _0x515950=0x0;_0x515950<_0x1b5da5[_0x1be5c0('0x277c')][_0x1be5c0('0x264b')];_0x515950++){_0x3408a8&&_0x1b5da5[_0x1be5c0('0x277c')][_0x515950]['id']===_0x3408a8['id']&&(_0x1b5da5[_0x1be5c0('0x277c')][_0x515950]['canSelect']=![],_0x2f1312[_0x1be5c0('0x1514')](_0x1b5da5['interval'][_0x515950]));}_0x1b5da5[_0x1be5c0('0x277c')]=_0x2f1312;}else{if(!_0x30afc1[_0x1be5c0('0x1a2b')])return _0x25c7dd[_0x1be5c0('0x4b5')][_0x1be5c0('0xd83')]({'sectionId':_0x30afc1['id']})[_0x1be5c0('0xa44')][_0x1be5c0('0x1166')](function(_0x3135a3){const _0x41824a=_0x1be5c0,_0x2f608a=_0x2cfb05()[_0x41824a('0x2563')](_0x3135a3[_0x41824a('0x269a')],function(_0xb5973c){const _0x165694=_0x41824a;return _0x2cfb05()[_0x165694('0xc38')](_0x1b5da5[_0x165694('0x277c')],{'id':_0xb5973c['resourceId']});});let _0x200aaa=null;_0x1b5da5['ivrCampaign']&&(_0x200aaa=_0x2cfb05()['find'](_0x1b5da5[_0x41824a('0x277c')],{'id':Number(_0x1b5da5[_0x41824a('0xedf')][_0x41824a('0x186f')])}));if(_0x200aaa&&!_0x2cfb05()[_0x41824a('0x1798')](_0x2f608a,['id',_0x200aaa['id']])){const _0x3fe20e=_0x2cfb05()[_0x41824a('0xc38')](_0x1b5da5[_0x41824a('0x277c')],{'id':_0x200aaa['id']});_0x3fe20e[_0x41824a('0x2378')]=![],_0x2f608a[_0x41824a('0x1514')](_0x3fe20e);}_0x1b5da5[_0x41824a('0x277c')]=_0x2f608a;});}})[_0x1bb0f9('0x1a80')](function(_0x10c857){const _0x4f5574=_0x1bb0f9;_0x1ea677['error']({'title':_0x10c857[_0x4f5574('0x52d')]?'API:'+_0x10c857[_0x4f5574('0x52d')]+_0x4f5574('0x11e1')+_0x10c857['statusText']:_0x4f5574('0xe48'),'msg':_0x10c857[_0x4f5574('0x25f4')]?JSON[_0x4f5574('0xbac')](_0x10c857[_0x4f5574('0x25f4')]):_0x10c857[_0x4f5574('0x1586')]()});});function _0x20927a(){const _0x25de00=_0x1bb0f9;_0x1b5da5[_0x25de00('0x61a')]=[],_0x25c7dd[_0x25de00('0xb13')]['save'](_0x1b5da5[_0x25de00('0xedf')])[_0x25de00('0xa44')][_0x25de00('0x1166')](function(_0x22651c){const _0x15069d=_0x25de00;_0x1b5da5['ivrCampaigns'][_0x15069d('0x2450')](_0x22651c[_0x15069d('0x2876')]()),_0x1ea677['success']({'title':_0x15069d('0x1cce'),'msg':_0x1b5da5['ivrCampaign']['name']?_0x1b5da5[_0x15069d('0xedf')]['name']+_0x15069d('0x1eda'):''}),_0x156cf2(_0x22651c);})[_0x25de00('0x1a80')](function(_0x3197c0){const _0x3de410=_0x25de00;if(_0x3197c0['data']&&_0x3197c0[_0x3de410('0x25f4')][_0x3de410('0x61a')]&&_0x3197c0[_0x3de410('0x25f4')][_0x3de410('0x61a')][_0x3de410('0x264b')]){_0x1b5da5[_0x3de410('0x61a')]=_0x3197c0[_0x3de410('0x25f4')][_0x3de410('0x61a')]||[{'message':_0x3197c0[_0x3de410('0x1586')](),'type':_0x3de410('0x178c')}];for(let _0x1fd03c=0x0;_0x1fd03c<_0x3197c0[_0x3de410('0x25f4')]['errors'][_0x3de410('0x264b')];_0x1fd03c+=0x1){_0x1ea677[_0x3de410('0xfc9')]({'title':_0x3197c0[_0x3de410('0x25f4')]['errors'][_0x1fd03c]['type'],'msg':_0x3197c0[_0x3de410('0x25f4')][_0x3de410('0x61a')][_0x1fd03c][_0x3de410('0x1e70')]});}}else _0x1ea677[_0x3de410('0xfc9')]({'title':_0x3197c0[_0x3de410('0x52d')]?_0x3de410('0x1e21')+_0x3197c0[_0x3de410('0x52d')]+_0x3de410('0x11e1')+_0x3197c0[_0x3de410('0xe1b')]:'api.campaign.save','msg':_0x3197c0[_0x3de410('0x25f4')]?JSON[_0x3de410('0xbac')](_0x3197c0[_0x3de410('0x25f4')][_0x3de410('0x1e70')]):_0x3197c0[_0x3de410('0x1586')]()});});}function _0x149828(){const _0x48818b=_0x1bb0f9;_0x1b5da5[_0x48818b('0x61a')]=[],_0x25c7dd[_0x48818b('0xb13')][_0x48818b('0x1449')]({'id':_0x1b5da5[_0x48818b('0xedf')]['id']},_0x1b5da5[_0x48818b('0xedf')])['$promise']['then'](function(_0x394c2f){const _0x417e16=_0x48818b,_0x39e886=_0x2cfb05()[_0x417e16('0xc38')](_0x1b5da5[_0x417e16('0x5b8')],{'id':_0x394c2f['id']});_0x39e886&&_0x2cfb05()[_0x417e16('0xcc3')](_0x39e886,_0x2cfb05()['pick'](_0x394c2f['toJSON'](),_0x2cfb05()['keys'](_0x39e886))),_0x1ea677[_0x417e16('0x103b')]({'title':'IvrCampaign\x20properly\x20saved!','msg':_0x1b5da5[_0x417e16('0xedf')][_0x417e16('0x4f0')]?_0x1b5da5[_0x417e16('0xedf')][_0x417e16('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x156cf2(_0x394c2f);})[_0x48818b('0x1a80')](function(_0x5be2f4){const _0x47c769=_0x48818b;if(_0x5be2f4[_0x47c769('0x25f4')]&&_0x5be2f4['data'][_0x47c769('0x61a')]&&_0x5be2f4['data']['errors'][_0x47c769('0x264b')]){_0x1b5da5[_0x47c769('0x61a')]=_0x5be2f4[_0x47c769('0x25f4')][_0x47c769('0x61a')]||[{'message':_0x5be2f4['toString'](),'type':_0x47c769('0x1395')}];for(let _0x332aa6=0x0;_0x332aa6<_0x5be2f4[_0x47c769('0x25f4')]['errors'][_0x47c769('0x264b')];_0x332aa6++){_0x1ea677[_0x47c769('0xfc9')]({'title':_0x5be2f4[_0x47c769('0x25f4')][_0x47c769('0x61a')][_0x332aa6][_0x47c769('0x1345')],'msg':_0x5be2f4[_0x47c769('0x25f4')][_0x47c769('0x61a')][_0x332aa6]['message']});}}else _0x1ea677[_0x47c769('0xfc9')]({'title':_0x5be2f4[_0x47c769('0x52d')]?'API:'+_0x5be2f4[_0x47c769('0x52d')]+_0x47c769('0x11e1')+_0x5be2f4[_0x47c769('0xe1b')]:'api.campaign.update','msg':_0x5be2f4[_0x47c769('0x25f4')]?JSON[_0x47c769('0xbac')](_0x5be2f4['data'][_0x47c769('0x1e70')]):_0x5be2f4[_0x47c769('0x1586')]()});});}function _0x2aacf1(_0xa20ec7){const _0x5da4e0=_0x1bb0f9;_0x1b5da5[_0x5da4e0('0x61a')]=[];const _0x28738f=_0x1b23c5['confirm']()[_0x5da4e0('0xcdc')](_0x5da4e0('0x7fb'))[_0x5da4e0('0xacc')](_0x5da4e0('0x1963'))[_0x5da4e0('0x8e8')](_0x5da4e0('0x7c0'))['ok'](_0x5da4e0('0x18'))['cancel'](_0x5da4e0('0x497'))[_0x5da4e0('0x203b')](_0xa20ec7);_0x1b23c5[_0x5da4e0('0x1f80')](_0x28738f)[_0x5da4e0('0x1166')](function(){const _0x2d5c58=_0x5da4e0;_0x25c7dd[_0x2d5c58('0xb13')][_0x2d5c58('0x906')]({'id':_0x1b5da5['ivrCampaign']['id']})[_0x2d5c58('0xa44')][_0x2d5c58('0x1166')](function(){const _0x23f986=_0x2d5c58;_0x2cfb05()['remove'](_0x1b5da5['ivrCampaigns'],{'id':_0x1b5da5[_0x23f986('0xedf')]['id']}),_0x1ea677[_0x23f986('0x103b')]({'title':_0x23f986('0x15fe'),'msg':(_0x1b5da5[_0x23f986('0xedf')][_0x23f986('0x4f0')]||_0x23f986('0xedf'))+_0x23f986('0x7cd')}),_0x156cf2(_0x1b5da5[_0x23f986('0xedf')]);})[_0x2d5c58('0x1a80')](function(_0x500d14){const _0x2f0370=_0x2d5c58;if(_0x500d14[_0x2f0370('0x25f4')]&&_0x500d14[_0x2f0370('0x25f4')][_0x2f0370('0x61a')]&&_0x500d14[_0x2f0370('0x25f4')][_0x2f0370('0x61a')][_0x2f0370('0x264b')]){_0x1b5da5['errors']=_0x500d14[_0x2f0370('0x25f4')][_0x2f0370('0x61a')]||[{'message':_0x500d14['toString'](),'type':_0x2f0370('0xdc2')}];for(let _0xbb87c6=0x0;_0xbb87c6<_0x500d14[_0x2f0370('0x25f4')]['errors'][_0x2f0370('0x264b')];_0xbb87c6++){_0x1ea677[_0x2f0370('0xfc9')]({'title':_0x500d14[_0x2f0370('0x25f4')][_0x2f0370('0x61a')][_0xbb87c6]['type'],'msg':_0x500d14[_0x2f0370('0x25f4')][_0x2f0370('0x61a')][_0xbb87c6][_0x2f0370('0x1e70')]});}}else _0x1ea677[_0x2f0370('0xfc9')]({'title':_0x500d14[_0x2f0370('0x52d')]?_0x2f0370('0x1e21')+_0x500d14['status']+_0x2f0370('0x11e1')+_0x500d14[_0x2f0370('0xe1b')]:_0x2f0370('0xdc2'),'msg':_0x500d14[_0x2f0370('0x25f4')]?JSON[_0x2f0370('0xbac')](_0x500d14['data']['message']):_0x500d14['message']||_0x500d14[_0x2f0370('0x1586')]()});});},function(){});}function _0x1fda31(_0x4976e4){return _0x4976e4===null?undefined:new Date(_0x4976e4);}function _0x156cf2(_0x4ac2df){const _0x5e8b06=_0x1bb0f9;_0x1b23c5[_0x5e8b06('0x1197')](_0x4ac2df);}}const _0x3ac5a5=_0x1efa02;_0x18d3a4['$inject']=[_0x36e6f4('0x265d'),'$q','toasty','api',_0x36e6f4('0xedf'),_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x18d3a4(_0x3aa79e,_0x11fc5d,_0x30ac38,_0x120608,_0x55775e,_0x5d6e41,_0x331c53,_0x2dd9fc,_0x57f8d1){const _0x33bc61=_0x36e6f4,_0x248830=this;_0x248830[_0x33bc61('0x98')]=_0x2dd9fc[_0x33bc61('0x26cd')](),_0x248830[_0x33bc61('0xedf')]=_0x55775e,_0x248830['crudPermissions']=_0x57f8d1,_0x248830['apiRoute']=_0x33bc61('0x1943'),_0x248830[_0x33bc61('0x1bb3')]=_0x33bc61('0x7c8'),_0x248830[_0x33bc61('0x7dd')]=_0x33bc61('0x16b4'),_0x248830[_0x33bc61('0x10d1')]=_0x33bc61('0x54d'),_0x248830['items']=[],_0x248830[_0x33bc61('0x10ab')]=[],_0x248830[_0x33bc61('0x18e1')]=[],_0x248830[_0x33bc61('0x2111')]=[],_0x248830[_0x33bc61('0x2781')]=[],_0x248830[_0x33bc61('0x14d7')]=![],_0x248830[_0x33bc61('0x34b')]=![],_0x248830['dualMultiselectOptions']={'readOnly':!_0x248830[_0x33bc61('0x243c')][_0x33bc61('0x1684')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':![],'orderBy':_0x33bc61('0x4f0'),'line1':_0x33bc61('0x4f0'),'line2':'','line3':'','labelAll':_0x5d6e41[_0x33bc61('0x25cc')](_0x33bc61('0x1676')),'labelSelected':_0x5d6e41['instant'](_0x33bc61('0x834')),'transferCallback':function(){const _0x54dc8b=_0x33bc61,_0x12c214=_0x2cfb05()[_0x54dc8b('0x2802')](_0x248830[_0x54dc8b('0x2781')],_0x248830[_0x54dc8b('0x18e1')],'id');_0x248830[_0x54dc8b('0x14d7')]=_0x2cfb05()['isEmpty'](_0x12c214)?![]:!![];}},_0x248830[_0x33bc61('0xae0')]=_0x3ecd70,_0x248830['saveLists']=_0x382394,_0x248830[_0x33bc61('0x24a0')]=_0x107c1e;function _0x3ecd70(){const _0x1739d1=_0x33bc61;return _0x2dd9fc[_0x1739d1('0x1ac6')](_0x1739d1('0xa7c'))?_0x285d01()[_0x1739d1('0x1a80')](function(_0x3854e6){const _0x42e7d2=_0x1739d1;_0x30ac38[_0x42e7d2('0xfc9')]({'title':_0x3854e6['status']?'API:'+_0x3854e6[_0x42e7d2('0x52d')]+_0x42e7d2('0x11e1')+_0x3854e6[_0x42e7d2('0xe1b')]:'SYSTEM:GETLISTS','msg':_0x3854e6[_0x42e7d2('0x52d')]?JSON[_0x42e7d2('0xbac')](_0x3854e6[_0x42e7d2('0x25f4')]):_0x3854e6[_0x42e7d2('0x1586')]()});}):_0x554743()[_0x1739d1('0x1166')](function(_0xd67c42){const _0x4a2388=_0x1739d1;return _0x248830[_0x4a2388('0xe60')]=_0xd67c42,_0x285d01();})[_0x1739d1('0x1a80')](function(_0x562a51){const _0x23e753=_0x1739d1;_0x30ac38[_0x23e753('0xfc9')]({'title':_0x562a51[_0x23e753('0x52d')]?_0x23e753('0x1e21')+_0x562a51[_0x23e753('0x52d')]+_0x23e753('0x11e1')+_0x562a51[_0x23e753('0xe1b')]:_0x23e753('0x14e6'),'msg':_0x562a51[_0x23e753('0x52d')]?JSON[_0x23e753('0xbac')](_0x562a51[_0x23e753('0x25f4')]):_0x562a51[_0x23e753('0x1586')]()});});}function _0x554743(){return _0x11fc5d(function(_0x44f504,_0xf61b44){const _0xa147d8=a0_0x3f2c;_0x120608[_0xa147d8('0x17aa')][_0xa147d8('0xd83')]({'userProfileId':_0x248830[_0xa147d8('0x98')][_0xa147d8('0xb86')],'name':_0xa147d8('0x1cae')})[_0xa147d8('0xa44')][_0xa147d8('0x1166')](function(_0x33b888){const _0xbc9cc2=_0xa147d8,_0x2aba0c=_0x33b888&&_0x33b888[_0xbc9cc2('0x269a')]?_0x33b888[_0xbc9cc2('0x269a')][0x0]:null;_0x44f504(_0x2aba0c);})[_0xa147d8('0x1a80')](function(_0x23851f){_0xf61b44(_0x23851f);});});}function _0x285d01(){return _0x11fc5d(function(_0x19fce4,_0x49b14e){const _0x3676a2=a0_0x3f2c;return _0x7cfda8()[_0x3676a2('0x1166')](function(_0x42b743){const _0x35c11b=_0x3676a2;return _0x248830[_0x35c11b('0xbd7')]=_0x42b743[_0x35c11b('0x269a')]?_0x42b743[_0x35c11b('0x269a')]:[],_0x2dd9fc[_0x35c11b('0x1ac6')](_0x35c11b('0xa7c'))?_0x42b743:_0x248830[_0x35c11b('0xe60')]?_0x248830['section'][_0x35c11b('0x1a2b')]?_0x42b743:_0x4e7e08():null;})['then'](function(_0x504bb9){const _0x6d9830=_0x3676a2,_0x1a6ccc=_0x504bb9&&_0x504bb9[_0x6d9830('0x269a')]?_0x504bb9[_0x6d9830('0x269a')]:[];return _0x248830['allowedItems']=_0x2cfb05()[_0x6d9830('0x2563')](_0x1a6ccc,function(_0x19d786){const _0xd36544=_0x6d9830;return _0x2cfb05()[_0xd36544('0xc38')](_0x248830['items'],{'id':_0x2dd9fc[_0xd36544('0x1ac6')](_0xd36544('0xa7c'))||_0x248830[_0xd36544('0xe60')]['autoAssociation']?_0x19d786['id']:_0x19d786[_0xd36544('0x24e8')]});}),_0x248830['startingAllowedItems']=angular['copy'](_0x248830[_0x6d9830('0x10ab')]),_0x248830[_0x6d9830('0xbd7')][_0x6d9830('0x2782')](function(_0x9020b){const _0x5960b5=_0x6d9830,_0x21b662=_0x2cfb05()[_0x5960b5('0xc38')](_0x248830['allowedItems'],{'id':_0x9020b['id']});_0x248830[_0x5960b5('0x98')][_0x5960b5('0x1e75')]===_0x5960b5('0xa7c')?_0x9020b[_0x5960b5('0x26ef')]=!![]:_0x9020b[_0x5960b5('0x26ef')]=typeof _0x21b662!=='undefined'?!![]:![];}),_0x40480b();})[_0x3676a2('0x1166')](function(_0x37ae42){const _0x3ccbd4=_0x3676a2,_0x3c0e61=_0x37ae42&&_0x37ae42[_0x3ccbd4('0x269a')]?_0x37ae42[_0x3ccbd4('0x269a')]:[];_0x248830['selectedItems']=_0x2cfb05()[_0x3ccbd4('0x2563')](_0x3c0e61,function(_0x46d1a4){return _0x2cfb05()['find'](_0x248830['items'],{'id':_0x46d1a4['id']});}),_0x248830[_0x3ccbd4('0x2781')]=angular[_0x3ccbd4('0x225f')](_0x248830[_0x3ccbd4('0x18e1')]),_0x248830[_0x3ccbd4('0xc68')][_0x3ccbd4('0x18e1')]=_0x248830[_0x3ccbd4('0x18e1')],_0x248830['dualMultiselectOptions']['items']=_0x2cfb05()[_0x3ccbd4('0x24ac')](_0x248830['allowedItems'],_0x248830['dualMultiselectOptions']['selectedItems'],'id'),_0x19fce4();})[_0x3676a2('0x1a80')](function(_0x46d54a){_0x49b14e(_0x46d54a);});});}function _0x4e7e08(){return _0x11fc5d(function(_0x3a558f,_0x4499b0){const _0x7aecc3=a0_0x3f2c;return _0x120608[_0x7aecc3('0x4b5')][_0x7aecc3('0xd83')]({'sectionId':_0x248830['section']['id'],'nolimit':!![]})[_0x7aecc3('0xa44')][_0x7aecc3('0x1166')](function(_0x33e990){_0x3a558f(_0x33e990);})[_0x7aecc3('0x1a80')](function(_0x507145){_0x4499b0(_0x507145);});});}function _0x40480b(){return _0x11fc5d(function(_0x2661b7,_0x2f55a9){const _0x2b8c55=a0_0x3f2c,_0x47e64a=_0x120608[_0x248830[_0x2b8c55('0x19dc')]];return _0x47e64a[_0x248830['getApi']]({'id':_0x248830['ivrCampaign']['id'],'fields':_0x2b8c55('0x1776'),'nolimit':!![]})[_0x2b8c55('0xa44')][_0x2b8c55('0x1166')](function(_0x31525d){_0x2661b7(_0x31525d);})[_0x2b8c55('0x1a80')](function(_0xd2d506){_0x2f55a9(_0xd2d506);});});}function _0x7cfda8(){return _0x11fc5d(function(_0x7a8d5a,_0x3cc7bb){const _0x52ce38=a0_0x3f2c;return _0x120608[_0x52ce38('0xdd9')][_0x52ce38('0xd83')]({'fields':_0x52ce38('0x1776'),'nolimit':!![]})[_0x52ce38('0xa44')][_0x52ce38('0x1166')](function(_0x37f25a){_0x7a8d5a(_0x37f25a);})[_0x52ce38('0x1a80')](function(_0x19ada7){_0x3cc7bb(_0x19ada7);});});}function _0x41be5a(_0x34aea0){return _0x11fc5d(function(_0x24845f,_0x56a340){const _0x4bef4b=a0_0x3f2c;if(_0x2cfb05()['isEmpty'](_0x34aea0))_0x24845f();else{const _0x24ae7f=_0x120608[_0x248830['apiRoute']];_0x24ae7f[_0x248830[_0x4bef4b('0x7dd')]]({'id':_0x248830[_0x4bef4b('0xedf')]['id'],'ids':_0x2cfb05()[_0x4bef4b('0x2563')](_0x34aea0,'id')})[_0x4bef4b('0xa44')]['then'](function(){_0x24845f();})['catch'](function(_0x3c20e0){_0x56a340(_0x3c20e0);});}});}function _0x100403(_0x4e36d9){return _0x11fc5d(function(_0x93dc10,_0x392af3){const _0x388398=a0_0x3f2c;if(_0x2cfb05()[_0x388398('0x1081')](_0x4e36d9))_0x93dc10();else{const _0x3b53b6=_0x120608[_0x248830[_0x388398('0x19dc')]];_0x3b53b6[_0x248830[_0x388398('0x10d1')]]({'id':_0x248830['ivrCampaign']['id'],'ids':_0x2cfb05()['map'](_0x4e36d9,'id')})[_0x388398('0xa44')][_0x388398('0x1166')](function(){_0x93dc10();})[_0x388398('0x1a80')](function(_0x312b11){_0x392af3(_0x312b11);});}});}function _0x382394(){const _0x58c061=_0x33bc61;_0x248830[_0x58c061('0x34b')]=!![];const _0x46817b=_0x2cfb05()[_0x58c061('0x24ac')](_0x248830[_0x58c061('0x2781')],_0x248830[_0x58c061('0x18e1')],'id'),_0x415bb0=_0x2cfb05()[_0x58c061('0x24ac')](_0x248830[_0x58c061('0x18e1')],_0x248830[_0x58c061('0x2781')],'id');return _0x100403(_0x46817b)[_0x58c061('0x1166')](function(){return _0x41be5a(_0x415bb0);})[_0x58c061('0x1166')](function(){const _0x5e89b3=_0x58c061;_0x248830[_0x5e89b3('0x14d7')]=![],_0x248830['startingAllowedItems']=angular[_0x5e89b3('0x225f')](_0x248830[_0x5e89b3('0x10ab')]),_0x248830[_0x5e89b3('0x2781')]=angular[_0x5e89b3('0x225f')](_0x248830[_0x5e89b3('0x18e1')]),_0x30ac38[_0x5e89b3('0x103b')]({'title':_0x5e89b3('0x983'),'msg':_0x5e89b3('0x9ed')});})['catch'](function(_0x485434){const _0x2dc260=_0x58c061;_0x30ac38[_0x2dc260('0xfc9')]({'title':_0x485434[_0x2dc260('0x52d')]?_0x2dc260('0x1e21')+_0x485434[_0x2dc260('0x52d')]+_0x2dc260('0x11e1')+_0x485434[_0x2dc260('0xe1b')]:_0x2dc260('0x1b29'),'msg':_0x485434['status']?JSON[_0x2dc260('0xbac')](_0x485434[_0x2dc260('0x25f4')]):_0x485434[_0x2dc260('0x1586')]()});})['finally'](function(){_0x248830['loading']=![];});}function _0x107c1e(){const _0x1683fb=_0x33bc61;_0x3aa79e[_0x1683fb('0x1197')]();}}const _0x4cea70=_0x18d3a4;_0x5c91b3[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$state','toasty',_0x36e6f4('0x19e3'),'ivrCampaign',_0x36e6f4('0x5b8'),'$translate'];function _0x5c91b3(_0x536816,_0x7bb65d,_0x541a5a,_0x474df4,_0x164742,_0x58b0ce,_0x4e03bf){const _0x399c47=_0x36e6f4,_0x2ba726=this;_0x2ba726[_0x399c47('0x3f6')]=!![],_0x2ba726[_0x399c47('0xedf')]=angular[_0x399c47('0x225f')](_0x164742),_0x2ba726[_0x399c47('0x5b8')]=_0x58b0ce,_0x2ba726[_0x399c47('0xcdc')]=_0x4e03bf['instant'](_0x399c47('0x1b71'));_0x164742&&_0x164742[_0x399c47('0x4f0')]&&(_0x2ba726[_0x399c47('0xcdc')]+=':\x20'+_0x164742['name']);_0x2ba726[_0x399c47('0x2477')]=_0x3e29cc,_0x2ba726['closeDialog']=_0x1aec67;function _0x3e29cc(){const _0x3dc194=_0x399c47;return _0x474df4[_0x3dc194('0xb13')][_0x3dc194('0xddc')]({'id':_0x164742['id']},_0x2ba726[_0x3dc194('0xedf')])['$promise']['then'](function(_0x352a00){const _0x282a2e=_0x3dc194;_0x2ba726[_0x282a2e('0x5b8')][_0x282a2e('0x2450')](_0x352a00[_0x282a2e('0x2876')]()),_0x541a5a[_0x282a2e('0x103b')]({'title':'IvrCampaign\x20properly\x20cloned','msg':_0x2ba726[_0x282a2e('0xedf')][_0x282a2e('0x4f0')]?_0x2ba726[_0x282a2e('0xedf')][_0x282a2e('0x4f0')]+_0x282a2e('0x1273'):''}),_0x7bb65d['go'](_0x282a2e('0x2329'),{'id':_0x352a00['id']}),_0x1aec67(_0x352a00);})['catch'](function(_0x260d0a){const _0x4644cc=_0x3dc194;if(_0x260d0a[_0x4644cc('0x25f4')]&&_0x260d0a[_0x4644cc('0x25f4')][_0x4644cc('0x61a')]&&_0x260d0a['data'][_0x4644cc('0x61a')]['length']){_0x2ba726[_0x4644cc('0x61a')]=_0x260d0a[_0x4644cc('0x25f4')]['errors']||[{'message':_0x260d0a[_0x4644cc('0x1586')](),'type':_0x4644cc('0xbb1')}];for(let _0x728d80=0x0;_0x728d80<_0x260d0a['data'][_0x4644cc('0x61a')][_0x4644cc('0x264b')];_0x728d80+=0x1){_0x541a5a[_0x4644cc('0xfc9')]({'title':_0x260d0a[_0x4644cc('0x25f4')]['errors'][_0x728d80][_0x4644cc('0x1345')],'msg':_0x260d0a['data'][_0x4644cc('0x61a')][_0x728d80][_0x4644cc('0x1e70')]});}}else _0x541a5a[_0x4644cc('0xfc9')]({'title':_0x260d0a[_0x4644cc('0x52d')]?_0x4644cc('0x1e21')+_0x260d0a['status']+'\x20-\x20'+_0x260d0a[_0x4644cc('0xe1b')]:'api.campaign.clone','msg':_0x260d0a[_0x4644cc('0x25f4')]?JSON[_0x4644cc('0xbac')](_0x260d0a[_0x4644cc('0x25f4')][_0x4644cc('0x1e70')]):_0x260d0a[_0x4644cc('0x1586')]()});});}function _0x1aec67(_0x371976){const _0x37121d=_0x399c47;_0x536816[_0x37121d('0x1197')](_0x371976);}}const _0x44fa10=_0x5c91b3;_0x225966[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),'$scope',_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x225966(_0x34e001,_0x177415,_0x2b67ac,_0x298c9e,_0x1f321e,_0x127765,_0x5db6e8,_0x599875,_0x20b28d,_0xf0fa86,_0x1f8b6d){const _0x43c67c=_0x36e6f4,_0x1afd0c=this;_0x1afd0c['currentUser']=_0x1f8b6d['getCurrentUser'](),_0x1afd0c[_0x43c67c('0xedf')]={},_0x1afd0c[_0x43c67c('0x926')]={'count':0x0,'rows':[]},_0x1afd0c[_0x43c67c('0x57f')]=[],_0x1afd0c['crudPermissions'],_0x1afd0c[_0x43c67c('0x2218')]={'fields':_0x43c67c('0xc5d'),'sort':_0x43c67c('0x83'),'limit':0xa,'page':0x1},_0x1afd0c[_0x43c67c('0x24d5')]=_0x3c43a,_0x1afd0c[_0x43c67c('0x8a2')]=_0x438ebc,_0x1afd0c[_0x43c67c('0x103b')]=_0x33aa03,_0x1afd0c[_0x43c67c('0x7ba')]=_0x53f10d,_0x1afd0c[_0x43c67c('0xe64')]=_0x357c80,_0x1afd0c[_0x43c67c('0x860')]=_0x2be6ac,_0x1afd0c[_0x43c67c('0x191d')]=_0x131806;function _0x3c43a(_0x4409c4,_0x34b888){const _0x5b9a3a=_0x43c67c;_0x1afd0c[_0x5b9a3a('0xedf')]=_0x4409c4,_0x1afd0c[_0x5b9a3a('0x243c')]=typeof _0x34b888!==_0x5b9a3a('0x1048')?_0x34b888:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1afd0c[_0x5b9a3a('0x2218')][_0x5b9a3a('0xd88')]=_0x1afd0c[_0x5b9a3a('0xedf')]['id'],_0x1afd0c[_0x5b9a3a('0x2218')]['id']=_0x1afd0c[_0x5b9a3a('0xedf')]['id'],_0x53f10d();}function _0x438ebc(_0x2d2b0c,_0x1673ac){const _0x17e6e0=_0x43c67c,_0xd9b1c2=_0x5db6e8['confirm']()[_0x17e6e0('0xcdc')](_0x17e6e0('0x39'))[_0x17e6e0('0xf3c')](''+(_0x2d2b0c[_0x17e6e0('0x4f0')]||_0x2d2b0c['id']&&_0x2cfb05()[_0x17e6e0('0x114b')]('hopperBlack\x20#')+_0x2d2b0c['id']||_0x17e6e0('0x2434'))+''+_0x17e6e0('0x3f3'))[_0x17e6e0('0x8e8')]('delete\x20hopperBlack')[_0x17e6e0('0x203b')](_0x1673ac)['ok']('OK')[_0x17e6e0('0x3f')]('CANCEL');_0x5db6e8['show'](_0xd9b1c2)[_0x17e6e0('0x1166')](function(){_0x2be6ac(_0x2d2b0c);},function(){const _0x160c7d=_0x17e6e0;console[_0x160c7d('0x455')](_0x160c7d('0x2d3'));});}function _0x33aa03(_0x9778e3){const _0x2e80e0=_0x43c67c;_0x1afd0c[_0x2e80e0('0x926')]=_0x9778e3||{'count':0x0,'rows':[]};}function _0x53f10d(){const _0x1596c4=_0x43c67c;_0x1afd0c[_0x1596c4('0x2218')][_0x1596c4('0x1098')]=(_0x1afd0c['query']['page']-0x1)*_0x1afd0c[_0x1596c4('0x2218')][_0x1596c4('0x163f')],_0x1afd0c[_0x1596c4('0x1f48')]=_0xf0fa86[_0x1596c4('0xb13')]['getHopperBlacks'](_0x1afd0c[_0x1596c4('0x2218')],_0x33aa03)[_0x1596c4('0xa44')];}function _0x2be6ac(_0x2a13a4){const _0x4769ef=_0x43c67c;_0xf0fa86[_0x4769ef('0x2434')]['delete']({'id':_0x2a13a4['id']})[_0x4769ef('0xa44')][_0x4769ef('0x1166')](function(){const _0x1e451a=_0x4769ef;_0x2cfb05()[_0x1e451a('0x127f')](_0x1afd0c['ivrCampaignHopperBlacks'][_0x1e451a('0x269a')],{'id':_0x2a13a4['id']}),_0x1afd0c['ivrCampaignHopperBlacks'][_0x1e451a('0x240f')]-=0x1,!_0x1afd0c[_0x1e451a('0x926')][_0x1e451a('0x269a')][_0x1e451a('0x264b')]&&_0x53f10d(),_0x20b28d['success']({'title':_0x1e451a('0x1e31'),'msg':_0x2a13a4['name']?_0x2a13a4[_0x1e451a('0x4f0')]+_0x1e451a('0x7cd'):''});})[_0x4769ef('0x1a80')](function(_0x5b7215){const _0x40774a=_0x4769ef;if(_0x5b7215[_0x40774a('0x25f4')]&&_0x5b7215[_0x40774a('0x25f4')][_0x40774a('0x61a')]&&_0x5b7215[_0x40774a('0x25f4')][_0x40774a('0x61a')]['length']){_0x1afd0c[_0x40774a('0x61a')]=_0x5b7215[_0x40774a('0x25f4')]['errors']||[{'message':_0x5b7215[_0x40774a('0x1586')](),'type':_0x40774a('0x6d2')}];for(let _0x5e15a6=0x0;_0x5e15a6<_0x5b7215['data'][_0x40774a('0x61a')]['length'];_0x5e15a6++){_0x20b28d[_0x40774a('0xfc9')]({'title':_0x5b7215[_0x40774a('0x25f4')][_0x40774a('0x61a')][_0x5e15a6][_0x40774a('0x1345')],'msg':_0x5b7215[_0x40774a('0x25f4')][_0x40774a('0x61a')][_0x5e15a6][_0x40774a('0x1e70')]});}}else _0x20b28d[_0x40774a('0xfc9')]({'title':_0x5b7215[_0x40774a('0x52d')]?_0x40774a('0x1e21')+_0x5b7215[_0x40774a('0x52d')]+'\x20-\x20'+_0x5b7215['statusText']:_0x40774a('0x6d2'),'msg':_0x5b7215['data']?JSON['stringify'](_0x5b7215[_0x40774a('0x25f4')][_0x40774a('0x1e70')]):_0x5b7215['message']||_0x5b7215['toString']()});});}function _0x357c80(){const _0x1610c3=_0x43c67c,_0xee75dd=angular[_0x1610c3('0x225f')](_0x1afd0c[_0x1610c3('0x57f')]);return _0x1afd0c[_0x1610c3('0x57f')]=[],_0xee75dd;}function _0x131806(_0x277da3){const _0x325270=_0x43c67c,_0xa830b1=_0x5db6e8['confirm']()[_0x325270('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20hopperBlacks?')['htmlContent'](''+_0x1afd0c['selectedIvrCampaignHopperBlacks'][_0x325270('0x264b')]+_0x325270('0x196d')+_0x325270('0x3f3'))[_0x325270('0x8e8')](_0x325270('0x1bca'))[_0x325270('0x203b')](_0x277da3)['ok']('OK')[_0x325270('0x3f')](_0x325270('0x2d3'));_0x5db6e8['show'](_0xa830b1)[_0x325270('0x1166')](function(){const _0x17ae8e=_0x325270;_0x1afd0c[_0x17ae8e('0x57f')][_0x17ae8e('0x2782')](function(_0x57279c){_0x2be6ac(_0x57279c);}),_0x1afd0c[_0x17ae8e('0x57f')]=[];});}let _0x497b00=!![],_0xf47a0b=0x1;_0x177415[_0x43c67c('0xe83')](_0x43c67c('0x28b4'),function(_0x3dcbc9,_0x41fb9c){const _0x29f569=_0x43c67c;_0x497b00?_0x127765(function(){_0x497b00=![];}):(!_0x41fb9c&&(_0xf47a0b=_0x1afd0c[_0x29f569('0x2218')][_0x29f569('0x1a43')]),_0x3dcbc9!==_0x41fb9c&&(_0x1afd0c['query'][_0x29f569('0x1a43')]=0x1),!_0x3dcbc9&&(_0x1afd0c['query'][_0x29f569('0x1a43')]=_0xf47a0b),_0x53f10d());});}const _0x3c0b3a=_0x225966;_0xde6898[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),'$state','$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x21ef')];function _0xde6898(_0x18d07f,_0x418624,_0x19cb37,_0x4393ff,_0x1214bb,_0xe9adb6,_0x807415,_0x1f1c22,_0x4b904a,_0x49f6be,_0x3c60f9){const _0x31c065=_0x36e6f4,_0x123c60=this;_0x123c60[_0x31c065('0x98')]=_0x3c60f9[_0x31c065('0x26cd')](),_0x123c60['contacts']={},_0x123c60[_0x31c065('0xedf')]={},_0x123c60[_0x31c065('0x2283')]={'count':0x0,'rows':[]},_0x123c60[_0x31c065('0x4ff')]=[],_0x123c60[_0x31c065('0x243c')],_0x123c60[_0x31c065('0x2218')]={'fields':_0x31c065('0x90d'),'sort':_0x31c065('0x83'),'limit':0xa,'page':0x1},_0x123c60[_0x31c065('0x24d5')]=_0x32405d,_0x123c60['deleteConfirm']=_0x4d7592,_0x123c60[_0x31c065('0x103b')]=_0x5f6cd8,_0x123c60['getIvrCampaignHopperFinals']=_0x369d17,_0x123c60[_0x31c065('0x19d2')]=_0x52972e,_0x123c60[_0x31c065('0x280b')]=_0x2a52d2,_0x123c60[_0x31c065('0x849')]=_0x578352,_0x123c60[_0x31c065('0x11c2')]=_0xd9245a,_0x123c60['moveContactsIvrCampaignHopperFinal']=_0x542181,_0x123c60[_0x31c065('0x26a3')]=_0x5d0a76,_0x123c60[_0x31c065('0x284c')]=_0xfb6d14,_0x123c60['moveSelectedIvrCampaignHopperFinals']=_0x4b0775;function _0x32405d(_0x3daad2,_0x1e6d2d){const _0x4848cc=_0x31c065;_0x123c60['ivrCampaign']=_0x3daad2,_0x123c60['crudPermissions']=typeof _0x1e6d2d!=='undefined'?_0x1e6d2d:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x123c60[_0x4848cc('0x2218')][_0x4848cc('0xd88')]=_0x123c60[_0x4848cc('0xedf')]['id'],_0x123c60['query']['id']=_0x123c60[_0x4848cc('0xedf')]['id'],_0x369d17();}function _0x4d7592(_0x406bbc,_0x599afa){const _0x31f1f3=_0x31c065,_0x4cb069=_0x807415[_0x31f1f3('0x1d26')]()[_0x31f1f3('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20hopperFinal?')[_0x31f1f3('0xf3c')](_0x31f1f3('0x12b5')+(_0x406bbc[_0x31f1f3('0x4f0')]||_0x406bbc['id']&&_0x2cfb05()['upperFirst'](_0x31f1f3('0x1f2'))+_0x406bbc['id']||'hopperFinal')+_0x31f1f3('0xace')+'\x20will\x20be\x20deleted.')[_0x31f1f3('0x8e8')]('delete\x20hopperFinal')[_0x31f1f3('0x203b')](_0x599afa)['ok']('OK')[_0x31f1f3('0x3f')](_0x31f1f3('0x2d3'));_0x807415['show'](_0x4cb069)[_0x31f1f3('0x1166')](function(){_0x2a52d2(_0x406bbc);},function(){const _0x562e7e=_0x31f1f3;console[_0x562e7e('0x455')]('CANCEL');});}function _0x5f6cd8(_0xd5cc44){const _0x859c59=_0x31c065;_0x123c60[_0x859c59('0x2283')]=_0xd5cc44||{'count':0x0,'rows':[]};}function _0x369d17(){const _0x223c9e=_0x31c065;_0x123c60[_0x223c9e('0x2218')][_0x223c9e('0x1098')]=(_0x123c60[_0x223c9e('0x2218')][_0x223c9e('0x1a43')]-0x1)*_0x123c60[_0x223c9e('0x2218')][_0x223c9e('0x163f')],_0x123c60['promise']=_0x49f6be[_0x223c9e('0xb13')][_0x223c9e('0x1e1c')](_0x123c60[_0x223c9e('0x2218')],_0x5f6cd8)[_0x223c9e('0xa44')];}function _0x2a52d2(_0x3b0d8e){const _0x56dbe7=_0x31c065;_0x49f6be[_0x56dbe7('0x1384')][_0x56dbe7('0x906')]({'id':_0x3b0d8e['id']})[_0x56dbe7('0xa44')][_0x56dbe7('0x1166')](function(){const _0x1576cf=_0x56dbe7;_0x2cfb05()[_0x1576cf('0x127f')](_0x123c60[_0x1576cf('0x2283')][_0x1576cf('0x269a')],{'id':_0x3b0d8e['id']}),_0x123c60[_0x1576cf('0x2283')][_0x1576cf('0x240f')]-=0x1,!_0x123c60[_0x1576cf('0x2283')][_0x1576cf('0x269a')][_0x1576cf('0x264b')]&&_0x369d17(),_0x4b904a[_0x1576cf('0x103b')]({'title':_0x1576cf('0x276f'),'msg':_0x3b0d8e[_0x1576cf('0x4f0')]?_0x3b0d8e[_0x1576cf('0x4f0')]+_0x1576cf('0x7cd'):''});})[_0x56dbe7('0x1a80')](function(_0x221c22){const _0x2594be=_0x56dbe7;if(_0x221c22[_0x2594be('0x25f4')]&&_0x221c22[_0x2594be('0x25f4')][_0x2594be('0x61a')]&&_0x221c22[_0x2594be('0x25f4')][_0x2594be('0x61a')]['length']){_0x123c60[_0x2594be('0x61a')]=_0x221c22[_0x2594be('0x25f4')][_0x2594be('0x61a')]||[{'message':_0x221c22[_0x2594be('0x1586')](),'type':_0x2594be('0x6d2')}];for(let _0x3761da=0x0;_0x3761da<_0x221c22[_0x2594be('0x25f4')][_0x2594be('0x61a')][_0x2594be('0x264b')];_0x3761da++){_0x4b904a[_0x2594be('0xfc9')]({'title':_0x221c22['data'][_0x2594be('0x61a')][_0x3761da][_0x2594be('0x1345')],'msg':_0x221c22[_0x2594be('0x25f4')][_0x2594be('0x61a')][_0x3761da][_0x2594be('0x1e70')]});}}else _0x4b904a['error']({'title':_0x221c22[_0x2594be('0x52d')]?_0x2594be('0x1e21')+_0x221c22['status']+_0x2594be('0x11e1')+_0x221c22[_0x2594be('0xe1b')]:'SYSTEM:GETcampaign','msg':_0x221c22[_0x2594be('0x25f4')]?JSON['stringify'](_0x221c22[_0x2594be('0x25f4')][_0x2594be('0x1e70')]):_0x221c22['message']||_0x221c22[_0x2594be('0x1586')]()});});}function _0x52972e(){const _0x5c7335=angular['copy'](_0x123c60['selectedIvrCampaignHopperFinals']);return _0x123c60['selectedIvrCampaignHopperFinals']=[],_0x5c7335;}function _0x578352(_0x527775){const _0x46cd14=_0x31c065,_0x45386b=_0x807415[_0x46cd14('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20hopperFinals?')[_0x46cd14('0xf3c')](_0x46cd14('0x12b5')+_0x123c60['selectedIvrCampaignHopperFinals']['length']+_0x46cd14('0x196d')+'\x20will\x20be\x20deleted.')[_0x46cd14('0x8e8')](_0x46cd14('0x107e'))[_0x46cd14('0x203b')](_0x527775)['ok']('OK')[_0x46cd14('0x3f')](_0x46cd14('0x2d3'));_0x807415[_0x46cd14('0x1f80')](_0x45386b)['then'](function(){_0x123c60['selectedIvrCampaignHopperFinals']['forEach'](function(_0xe644e2){_0x2a52d2(_0xe644e2);}),_0x123c60['selectedIvrCampaignHopperFinals']=[];});}function _0x542181(_0x3cbea2){const _0x25d3a4=_0x31c065;_0x49f6be[_0x25d3a4('0x1806')]['moveContactsIvrCampaignHopperFinal']({'id':_0x123c60['query']['id'],'state':_0x3cbea2})[_0x25d3a4('0xa44')][_0x25d3a4('0x1166')](function(_0x132233){const _0x3f18f0=_0x25d3a4;_0x2cfb05()[_0x3f18f0('0x2863')](_0x132233)&&_0x2cfb05()[_0x3f18f0('0x2863')](_0x132233[0x0])?_0x4b904a[_0x3f18f0('0x1fa1')]({'title':'Restored\x20Contacts','msg':'0'}):_0x4b904a[_0x3f18f0('0x1fa1')]({'title':_0x3f18f0('0x1fe8'),'msg':JSON[_0x3f18f0('0xbac')](_0x132233[0x0][_0x3f18f0('0x23c7')])});})['catch'](function(_0x205351){const _0x208a67=_0x25d3a4;_0x4b904a[_0x208a67('0xfc9')]({'title':_0x205351[_0x208a67('0x52d')]?_0x208a67('0x1e21')+_0x205351[_0x208a67('0x52d')]+_0x208a67('0x11e1')+_0x205351[_0x208a67('0xe1b')]:_0x208a67('0x1c74'),'msg':_0x205351[_0x208a67('0x25f4')]?JSON[_0x208a67('0xbac')](_0x205351['data'][_0x208a67('0x1e70')]):_0x205351[_0x208a67('0x1e70')]||_0x205351['toString']()});});}function _0x5d0a76(_0x5621d9){const _0x2f735e=_0x31c065;_0x49f6be[_0x2f735e('0x1806')][_0x2f735e('0x26a3')]({'id':_0x5621d9})[_0x2f735e('0xa44')][_0x2f735e('0x1166')](function(_0xdde386){const _0x4f4535=_0x2f735e;_0x2cfb05()['merge'](_0x123c60[_0x4f4535('0xca8')],_0xdde386[0x0]);})[_0x2f735e('0x1a80')](function(_0x71ed99){const _0x387a63=_0x2f735e;_0x4b904a[_0x387a63('0xfc9')]({'title':_0x71ed99[_0x387a63('0x52d')]?_0x387a63('0x1e21')+_0x71ed99['status']+'\x20-\x20'+_0x71ed99[_0x387a63('0xe1b')]:_0x387a63('0x6d2'),'msg':_0x71ed99['data']?JSON['stringify'](_0x71ed99[_0x387a63('0x25f4')][_0x387a63('0x1e70')]):_0x71ed99['message']||_0x71ed99[_0x387a63('0x1586')]()});});}function _0x4b0775(_0x2f98c1){const _0x19b0ee=_0x31c065,_0x2fe8ff=_0x807415[_0x19b0ee('0x1d26')]()[_0x19b0ee('0xcdc')](_0x19b0ee('0x17ef'))[_0x19b0ee('0xf3c')](_0x19b0ee('0xcad')+'\x20will\x20be\x20restored.')[_0x19b0ee('0x8e8')](_0x19b0ee('0x18d8'))['targetEvent'](_0x2f98c1)['ok']('OK')['cancel'](_0x19b0ee('0x2d3'));_0x807415['show'](_0x2fe8ff)[_0x19b0ee('0x1166')](function(){const _0x5ba468=_0x19b0ee;_0x123c60['selectedIvrCampaignHopperFinals'][_0x5ba468('0x2782')](function(_0x3a1532){_0xd9245a(_0x3a1532);}),_0x123c60[_0x5ba468('0x4ff')]=[];});}function _0xfb6d14(_0x42d9a0,_0x638652){const _0x3f8e09=_0x31c065,_0x484a0b=_0x807415[_0x3f8e09('0x1d26')]()[_0x3f8e09('0xcdc')](_0x3f8e09('0xd48'))[_0x3f8e09('0xf3c')](''+_0x3f8e09('0x21a4')+_0x3f8e09('0xace')+_0x3f8e09('0x2648'))['ariaLabel'](_0x3f8e09('0x1f3c'))[_0x3f8e09('0x203b')](_0x638652)['ok']('OK')[_0x3f8e09('0x3f')]('CANCEL');_0x807415[_0x3f8e09('0x1f80')](_0x484a0b)['then'](function(){_0xd9245a(_0x42d9a0);},function(){const _0x29316a=_0x3f8e09;console[_0x29316a('0x455')]('CANCEL');});}function _0x11acc5(_0x4e511d){const _0x17ce04=_0x31c065,_0x42782b={};return _0x42782b[_0x17ce04('0x2026')]=_0x4e511d[_0x17ce04('0x26a8')],_0x42782b[_0x17ce04('0x1c5e')]=_0x24273b()()[_0x17ce04('0x128a')](_0x17ce04('0x1084')),_0x42782b[_0x17ce04('0x1736')]=0x0,_0x42782b['countcongestionretry']=0x0,_0x42782b[_0x17ce04('0x1c7')]=0x0,_0x42782b[_0x17ce04('0x1422')]=0x0,_0x42782b[_0x17ce04('0x1a17')]=_0x4e511d[_0x17ce04('0x1a17')],_0x42782b[_0x17ce04('0x23c')]=_0x4e511d[_0x17ce04('0x23c')],_0x42782b[_0x17ce04('0x122a')]=_0x4e511d['deleted']?null:_0x4e511d[_0x17ce04('0x122a')],_0x42782b[_0x17ce04('0xc69')]=_0x4e511d[_0x17ce04('0xc69')],_0x42782b[_0x17ce04('0xd88')]=_0x4e511d['CampaignId'],_0x42782b['priority']=_0x4e511d[_0x17ce04('0xc10')]?0x3:0x2,_0x42782b[_0x17ce04('0xc10')]=_0x4e511d[_0x17ce04('0xc10')]?!![]:![],_0x42782b;}function _0x49fb27(_0x430b90){const _0x5bcb83=_0x31c065,_0x170753={};return _0x170753['calleridnum']=_0x430b90[_0x5bcb83('0x26a8')],_0x170753[_0x5bcb83('0x1f24')]=_0x430b90[_0x5bcb83('0x1f24')],_0x170753[_0x5bcb83('0x1c5e')]=_0x24273b()()[_0x5bcb83('0x128a')](_0x5bcb83('0x1084')),_0x170753[_0x5bcb83('0x1736')]=_0x430b90[_0x5bcb83('0x1736')],_0x170753[_0x5bcb83('0x406')]=_0x430b90[_0x5bcb83('0x406')],_0x170753[_0x5bcb83('0x1c7')]=_0x430b90[_0x5bcb83('0x1c7')],_0x170753[_0x5bcb83('0x1422')]=_0x430b90['countglobal'],_0x170753[_0x5bcb83('0x1a17')]=_0x430b90['ContactId'],_0x170753[_0x5bcb83('0x23c')]=_0x430b90[_0x5bcb83('0x23c')],_0x170753[_0x5bcb83('0x122a')]=_0x3c60f9[_0x5bcb83('0x26cd')]()['id'],_0x170753[_0x5bcb83('0xc69')]=_0x430b90[_0x5bcb83('0xc69')],_0x170753[_0x5bcb83('0xd88')]=_0x430b90[_0x5bcb83('0xd88')],_0x170753[_0x5bcb83('0x451')]=_0x24273b()()[_0x5bcb83('0x128a')](_0x5bcb83('0x1084')),_0x170753[_0x5bcb83('0x28ca')]=!![],_0x170753['state']=0x19,_0x170753[_0x5bcb83('0x718')]=_0x5bcb83('0x142b'),_0x170753['campaign']=_0x430b90[_0x5bcb83('0xb13')],_0x170753[_0x5bcb83('0x1eaf')]=_0x430b90[_0x5bcb83('0xc69')]?'queue':_0x5bcb83('0x681'),_0x170753;}function _0xd9245a(_0x449f68){const _0x7fe2c3=_0x31c065;_0x49f6be[_0x7fe2c3('0x1806')][_0x7fe2c3('0x915')](_0x449f68)[_0x7fe2c3('0xa44')][_0x7fe2c3('0x1166')](function(_0x26944c){const _0x45ec69=_0x7fe2c3;_0x4b904a[_0x45ec69('0x1fa1')]({'title':_0x45ec69('0xcc4'),'msg':_0x45ec69('0x541')+_0x26944c['ContactId']});})[_0x7fe2c3('0x1a80')](function(_0x2db49e){const _0x43e2f7=_0x7fe2c3;_0x2db49e[_0x43e2f7('0x25f4')]===_0x43e2f7('0x486')?_0x49f6be[_0x43e2f7('0x256a')][_0x43e2f7('0x9cc')](_0x11acc5(_0x449f68))[_0x43e2f7('0xa44')][_0x43e2f7('0x1166')](function(_0x3235f7){const _0x82b6f4=_0x43e2f7;_0x4b904a[_0x82b6f4('0x1fa1')]({'title':_0x82b6f4('0xab1'),'msg':'Contact\x20ID\x20'+_0x3235f7[_0x82b6f4('0x1a17')]}),_0x3235f7[_0x82b6f4('0x1a17')]&&_0x49f6be[_0x82b6f4('0x1a26')][_0x82b6f4('0x9cc')](_0x49fb27(_0x449f68));})[_0x43e2f7('0x1a80')](function(_0x4b23b2){const _0x35185b=_0x43e2f7;!_0x2cfb05()['isNil'](_0x4b23b2[_0x35185b('0x25f4')])&&_0x4b23b2['data']['message']===_0x35185b('0x2271')?_0x4b904a[_0x35185b('0x1fa1')]({'title':_0x35185b('0xcc4'),'msg':_0x35185b('0x541')+_0x449f68[_0x35185b('0x1a17')]}):_0x4b904a[_0x35185b('0xfc9')]({'title':_0x4b23b2[_0x35185b('0x52d')]?'API:'+_0x4b23b2[_0x35185b('0x52d')]+_0x35185b('0x11e1')+_0x4b23b2[_0x35185b('0xe1b')]:_0x35185b('0x1c74'),'msg':_0x4b23b2[_0x35185b('0x25f4')]?JSON[_0x35185b('0xbac')](_0x4b23b2[_0x35185b('0x25f4')][_0x35185b('0x1e70')]):_0x4b23b2[_0x35185b('0x1e70')]||_0x4b23b2['toString']()});}):_0x4b904a[_0x43e2f7('0xfc9')]({'title':_0x2db49e[_0x43e2f7('0x52d')]?_0x43e2f7('0x1e21')+_0x2db49e['status']+'\x20-\x20'+_0x2db49e[_0x43e2f7('0xe1b')]:_0x43e2f7('0x1c74'),'msg':_0x2db49e[_0x43e2f7('0x25f4')]?JSON[_0x43e2f7('0xbac')](_0x2db49e[_0x43e2f7('0x25f4')][_0x43e2f7('0x1e70')]):_0x2db49e[_0x43e2f7('0x1e70')]||_0x2db49e[_0x43e2f7('0x1586')]()});});}let _0x598982=!![],_0x1784a3=0x1;_0x418624[_0x31c065('0xe83')](_0x31c065('0x28b4'),function(_0x150f85,_0x274f5e){const _0xa583dd=_0x31c065;_0x598982?_0xe9adb6(function(){_0x598982=![];}):(!_0x274f5e&&(_0x1784a3=_0x123c60[_0xa583dd('0x2218')][_0xa583dd('0x1a43')]),_0x150f85!==_0x274f5e&&(_0x123c60[_0xa583dd('0x2218')][_0xa583dd('0x1a43')]=0x1),!_0x150f85&&(_0x123c60[_0xa583dd('0x2218')][_0xa583dd('0x1a43')]=_0x1784a3),_0x369d17());});}const _0x46dc13=_0xde6898;_0x765f0['$inject']=['$cookies',_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q','$translate',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x765f0(_0x59ed4c,_0x522498,_0x323ae0,_0x57ec8f,_0x22e06b,_0x888e23,_0x439ffa,_0x3ee0a9,_0x37b72c,_0x11586a,_0x225aa0){const _0x148813=_0x36e6f4,_0x4892f8=this;_0x4892f8[_0x148813('0x98')]=_0x225aa0[_0x148813('0x26cd')](),_0x4892f8['ivrCampaign']={},_0x4892f8[_0x148813('0x1727')]={'count':0x0,'rows':[]},_0x4892f8['selectedIvrCampaignHopperHistories']=[],_0x4892f8['crudPermissions'],_0x4892f8['query']={'fields':_0x148813('0xcf1'),'sort':_0x148813('0x83'),'limit':0xa,'page':0x1},_0x4892f8[_0x148813('0x24d5')]=_0x39b6c4,_0x4892f8['deleteConfirm']=_0x4b56cd,_0x4892f8[_0x148813('0x103b')]=_0x46c85e,_0x4892f8['getIvrCampaignHopperHistories']=_0x2d01c6,_0x4892f8['exportSelectedIvrCampaignHopperHistories']=_0x1c1d61,_0x4892f8[_0x148813('0x19a5')]=_0x4091ed,_0x4892f8['deleteSelectedIvrCampaignHopperHistories']=_0x265063;function _0x39b6c4(_0x2a129f,_0x37bedd){const _0x2b5fc9=_0x148813;_0x4892f8[_0x2b5fc9('0xedf')]=_0x2a129f,_0x4892f8[_0x2b5fc9('0x243c')]=typeof _0x37bedd!=='undefined'?_0x37bedd:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4892f8[_0x2b5fc9('0x2218')][_0x2b5fc9('0xd88')]=_0x4892f8['ivrCampaign']['id'],_0x4892f8['query']['id']=_0x4892f8['ivrCampaign']['id'],_0x2d01c6();}function _0x4b56cd(_0x5b13ac,_0x192229){const _0x5b896a=_0x148813,_0x3a0fa7=_0x439ffa[_0x5b896a('0x1d26')]()['title'](_0x5b896a('0x19b5'))[_0x5b896a('0xf3c')](_0x5b896a('0x12b5')+(_0x5b13ac[_0x5b896a('0x4f0')]||_0x5b13ac['id']&&_0x2cfb05()[_0x5b896a('0x114b')](_0x5b896a('0x1b4d'))+_0x5b13ac['id']||'hopperHistory')+''+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x5b896a('0x261'))['targetEvent'](_0x192229)['ok']('OK')['cancel']('CANCEL');_0x439ffa[_0x5b896a('0x1f80')](_0x3a0fa7)[_0x5b896a('0x1166')](function(){_0x4091ed(_0x5b13ac);},function(){const _0x462e6b=_0x5b896a;console[_0x462e6b('0x455')](_0x462e6b('0x2d3'));});}function _0x46c85e(_0x5a1f91){const _0x4142d9=_0x148813;_0x4892f8[_0x4142d9('0x1727')]=_0x5a1f91||{'count':0x0,'rows':[]};}function _0x2d01c6(){const _0x4b0205=_0x148813;_0x4892f8[_0x4b0205('0x2218')][_0x4b0205('0x1098')]=(_0x4892f8[_0x4b0205('0x2218')][_0x4b0205('0x1a43')]-0x1)*_0x4892f8[_0x4b0205('0x2218')][_0x4b0205('0x163f')],_0x4892f8[_0x4b0205('0x1f48')]=_0x11586a['campaign'][_0x4b0205('0x2825')](_0x4892f8[_0x4b0205('0x2218')],_0x46c85e)[_0x4b0205('0xa44')];}function _0x4091ed(_0x2676a3){const _0x5b04a6=_0x148813;_0x11586a[_0x5b04a6('0x1946')]['delete']({'id':_0x2676a3['id']})[_0x5b04a6('0xa44')][_0x5b04a6('0x1166')](function(){const _0x3a7e25=_0x5b04a6;_0x2cfb05()['remove'](_0x4892f8[_0x3a7e25('0x1727')][_0x3a7e25('0x269a')],{'id':_0x2676a3['id']}),_0x4892f8[_0x3a7e25('0x1727')][_0x3a7e25('0x240f')]-=0x1,!_0x4892f8[_0x3a7e25('0x1727')][_0x3a7e25('0x269a')][_0x3a7e25('0x264b')]&&_0x2d01c6(),_0x37b72c[_0x3a7e25('0x103b')]({'title':_0x3a7e25('0x1887'),'msg':_0x2676a3['name']?_0x2676a3[_0x3a7e25('0x4f0')]+_0x3a7e25('0x7cd'):''});})[_0x5b04a6('0x1a80')](function(_0x4e00b6){const _0x3596e5=_0x5b04a6;if(_0x4e00b6[_0x3596e5('0x25f4')]&&_0x4e00b6['data'][_0x3596e5('0x61a')]&&_0x4e00b6['data']['errors'][_0x3596e5('0x264b')]){_0x4892f8[_0x3596e5('0x61a')]=_0x4e00b6[_0x3596e5('0x25f4')][_0x3596e5('0x61a')]||[{'message':_0x4e00b6[_0x3596e5('0x1586')](),'type':'SYSTEM:GETcampaign'}];for(let _0x54a809=0x0;_0x54a809<_0x4e00b6['data'][_0x3596e5('0x61a')][_0x3596e5('0x264b')];_0x54a809++){_0x37b72c[_0x3596e5('0xfc9')]({'title':_0x4e00b6[_0x3596e5('0x25f4')]['errors'][_0x54a809]['type'],'msg':_0x4e00b6[_0x3596e5('0x25f4')][_0x3596e5('0x61a')][_0x54a809]['message']});}}else _0x37b72c[_0x3596e5('0xfc9')]({'title':_0x4e00b6['status']?_0x3596e5('0x1e21')+_0x4e00b6[_0x3596e5('0x52d')]+_0x3596e5('0x11e1')+_0x4e00b6['statusText']:'SYSTEM:GETcampaign','msg':_0x4e00b6[_0x3596e5('0x25f4')]?JSON['stringify'](_0x4e00b6[_0x3596e5('0x25f4')]['message']):_0x4e00b6[_0x3596e5('0x1e70')]||_0x4e00b6['toString']()});});}function _0x1c1d61(){const _0x50674e=_0x148813,_0xf080bc=angular[_0x50674e('0x225f')](_0x4892f8['selectedIvrCampaignHopperHistories']);return _0x4892f8[_0x50674e('0x127e')]=[],_0xf080bc;}function _0x265063(_0x2e55d4){const _0x1476f3=_0x148813,_0x140ecb=_0x439ffa[_0x1476f3('0x1d26')]()[_0x1476f3('0xcdc')](_0x1476f3('0xeee'))[_0x1476f3('0xf3c')](_0x1476f3('0x12b5')+_0x4892f8[_0x1476f3('0x127e')]['length']+_0x1476f3('0x196d')+_0x1476f3('0x3f3'))['ariaLabel'](_0x1476f3('0x1710'))[_0x1476f3('0x203b')](_0x2e55d4)['ok']('OK')[_0x1476f3('0x3f')](_0x1476f3('0x2d3'));_0x439ffa['show'](_0x140ecb)[_0x1476f3('0x1166')](function(){const _0x4d870c=_0x1476f3;_0x4892f8[_0x4d870c('0x127e')][_0x4d870c('0x2782')](function(_0x386964){_0x4091ed(_0x386964);}),_0x4892f8[_0x4d870c('0x127e')]=[];});}let _0x26b58a=!![],_0x1b664d=0x1;_0x522498[_0x148813('0xe83')](_0x148813('0x28b4'),function(_0x5bc45d,_0x2a1fa8){const _0x452a42=_0x148813;_0x26b58a?_0x888e23(function(){_0x26b58a=![];}):(!_0x2a1fa8&&(_0x1b664d=_0x4892f8['query'][_0x452a42('0x1a43')]),_0x5bc45d!==_0x2a1fa8&&(_0x4892f8[_0x452a42('0x2218')][_0x452a42('0x1a43')]=0x1),!_0x5bc45d&&(_0x4892f8['query'][_0x452a42('0x1a43')]=_0x1b664d),_0x2d01c6());});}const _0x1a9f64=_0x765f0;_0x522011[_0x36e6f4('0x1294')]=['$cookies','$scope','$state','$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'Auth'];function _0x522011(_0x50988f,_0x54842e,_0x29ed71,_0x53a8e4,_0x256925,_0x3641b3,_0x3656e7,_0x3f5b59,_0x50a5af,_0x275eb2,_0x3c91fb){const _0x448c76=_0x36e6f4,_0x6b9b86=this;_0x6b9b86[_0x448c76('0x98')]=_0x3c91fb[_0x448c76('0x26cd')](),_0x6b9b86[_0x448c76('0xedf')]={},_0x6b9b86[_0x448c76('0x1486')]={'count':0x0,'rows':[]},_0x6b9b86[_0x448c76('0x36b')]=[],_0x6b9b86[_0x448c76('0x243c')],_0x6b9b86[_0x448c76('0x2218')]={'fields':_0x448c76('0x383'),'sort':_0x448c76('0x14dc'),'limit':0xa,'page':0x1},_0x6b9b86['arraypriority']=_0x2cfb05()[_0x448c76('0x155c')]([{'option':_0x448c76('0xb06'),'value':_0x448c76('0x5d')},{'option':_0x448c76('0xf95'),'value':_0x448c76('0x2687')},{'option':_0x448c76('0x3e9'),'value':_0x448c76('0x246e')},{'option':_0x448c76('0x2572'),'value':_0x448c76('0x54e')},{'option':_0x448c76('0x4'),'value':_0x448c76('0x125f')}],function(_0x4e00c3){const _0x173e36=_0x448c76;return _0x2cfb05()['replace'](_0x4e00c3[_0x173e36('0x18e0')],new RegExp('\x27','g'),'');}),_0x6b9b86[_0x448c76('0x24d5')]=_0x3b3f29,_0x6b9b86['deleteConfirm']=_0x1b21aa,_0x6b9b86[_0x448c76('0x103b')]=_0xc4a830,_0x6b9b86[_0x448c76('0x2293')]=_0x20ef96,_0x6b9b86['createOrEditIvrCampaignHopper']=_0x5154ca,_0x6b9b86[_0x448c76('0x2397')]=_0x15f7ab,_0x6b9b86[_0x448c76('0x1d9b')]=_0x184e4a,_0x6b9b86[_0x448c76('0x1c55')]=_0x4e5d1e,_0x3c91fb[_0x448c76('0x1ac6')](_0x448c76('0xa7c'))?_0x275eb2[_0x448c76('0x557')][_0x448c76('0xd83')]({'fields':_0x448c76('0x1776'),'role':_0x448c76('0x1eff'),'sort':_0x448c76('0x4f0'),'nolimit':'true'})[_0x448c76('0xa44')][_0x448c76('0x1166')](function(_0x266358){const _0x487771=_0x448c76;_0x6b9b86[_0x487771('0x1f7e')]=_0x266358[_0x487771('0x269a')]||[];})[_0x448c76('0x1a80')](function(_0x5d5836){const _0x2022e6=_0x448c76;_0x50a5af[_0x2022e6('0xfc9')]({'title':_0x5d5836[_0x2022e6('0x52d')]?_0x2022e6('0x1e21')+_0x5d5836[_0x2022e6('0x52d')]+_0x2022e6('0x11e1')+_0x5d5836[_0x2022e6('0xe1b')]:_0x2022e6('0xd4c'),'msg':_0x5d5836['data']?JSON[_0x2022e6('0xbac')](_0x5d5836['data']):_0x5d5836[_0x2022e6('0x1586')]()});}):_0x275eb2[_0x448c76('0x557')][_0x448c76('0xd83')]({'fields':_0x448c76('0x1776'),'role':_0x448c76('0x1eff'),'sort':_0x448c76('0x4f0'),'nolimit':'true'})[_0x448c76('0xa44')][_0x448c76('0x1166')](function(_0x126fb5){const _0x5d2c56=_0x448c76;_0x6b9b86['agents']=_0x126fb5[_0x5d2c56('0x269a')]||[];})[_0x448c76('0x1166')](function(){const _0x14329e=_0x448c76;return _0x275eb2[_0x14329e('0x17aa')][_0x14329e('0xd83')]({'userProfileId':_0x6b9b86[_0x14329e('0x98')]['userProfileId'],'sectionId':0xca})[_0x14329e('0xa44')];})[_0x448c76('0x1166')](function(_0x42b34e){const _0x4b9904=_0x448c76,_0x31d236=_0x42b34e&&_0x42b34e[_0x4b9904('0x269a')]?_0x42b34e[_0x4b9904('0x269a')][0x0]:null;if(!_0x31d236)_0x6b9b86['agents']=[];else{if(!_0x31d236['autoAssociation'])return _0x275eb2[_0x4b9904('0x4b5')][_0x4b9904('0xd83')]({'sectionId':_0x31d236['id']})[_0x4b9904('0xa44')][_0x4b9904('0x1166')](function(_0x5db02f){const _0x443240=_0x4b9904,_0x25d5f1=_0x2cfb05()[_0x443240('0x2563')](_0x5db02f[_0x443240('0x269a')],function(_0x1c7033){const _0x3d2f1a=_0x443240;return _0x2cfb05()[_0x3d2f1a('0xc38')](_0x6b9b86[_0x3d2f1a('0x1f7e')],{'id':_0x1c7033['resourceId']});});_0x6b9b86[_0x443240('0x1f7e')][_0x443240('0x2782')](function(_0x2c316d){const _0x5e2445=_0x443240;!_0x2cfb05()[_0x5e2445('0x1798')](_0x25d5f1,['id',_0x2c316d['id']])&&(_0x2c316d['canSelect']=![]),_0x25d5f1[_0x5e2445('0x1514')](_0x2c316d);}),_0x6b9b86[_0x443240('0x1f7e')]=_0x25d5f1;});}})[_0x448c76('0x1a80')](function(_0x2a77ba){const _0xd3daba=_0x448c76;_0x50a5af[_0xd3daba('0xfc9')]({'title':_0x2a77ba['status']?_0xd3daba('0x1e21')+_0x2a77ba[_0xd3daba('0x52d')]+'\x20-\x20'+_0x2a77ba[_0xd3daba('0xe1b')]:_0xd3daba('0xdc5'),'msg':_0x2a77ba[_0xd3daba('0x25f4')]?JSON[_0xd3daba('0xbac')](_0x2a77ba['data']):_0x2a77ba[_0xd3daba('0x1586')]()});});function _0x3b3f29(_0x254c3d,_0x2227d5){const _0x53d288=_0x448c76;_0x6b9b86['ivrCampaign']=_0x254c3d,_0x6b9b86[_0x53d288('0x243c')]=typeof _0x2227d5!=='undefined'?_0x2227d5:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x6b9b86[_0x53d288('0x2218')][_0x53d288('0xd88')]=_0x6b9b86[_0x53d288('0xedf')]['id'],_0x6b9b86[_0x53d288('0x2218')]['id']=_0x6b9b86['ivrCampaign']['id'],_0x20ef96();}function _0x1b21aa(_0x4414ac,_0x2e9ce6){const _0x5c472c=_0x448c76,_0x4daef8=_0x3656e7['confirm']()[_0x5c472c('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20hopper?')['htmlContent'](_0x5c472c('0x12b5')+(_0x4414ac[_0x5c472c('0x4f0')]||_0x4414ac['id']&&_0x2cfb05()[_0x5c472c('0x114b')]('hopper\x20#')+_0x4414ac['id']||_0x5c472c('0x1d98'))+''+'\x20will\x20be\x20deleted.')['ariaLabel']('delete\x20hopper')[_0x5c472c('0x203b')](_0x2e9ce6)['ok']('OK')[_0x5c472c('0x3f')](_0x5c472c('0x2d3'));_0x3656e7[_0x5c472c('0x1f80')](_0x4daef8)[_0x5c472c('0x1166')](function(){_0x184e4a(_0x4414ac);},function(){const _0x212440=_0x5c472c;console[_0x212440('0x455')](_0x212440('0x2d3'));});}function _0xc4a830(_0x4790aa){const _0x39180e=_0x448c76;_0x6b9b86[_0x39180e('0x1486')]=_0x4790aa||{'count':0x0,'rows':[]};}function _0x20ef96(){const _0x5e188b=_0x448c76;_0x6b9b86[_0x5e188b('0x2218')][_0x5e188b('0x1098')]=(_0x6b9b86[_0x5e188b('0x2218')]['page']-0x1)*_0x6b9b86[_0x5e188b('0x2218')]['limit'],_0x6b9b86['promise']=_0x275eb2[_0x5e188b('0xb13')][_0x5e188b('0xfee')](_0x6b9b86[_0x5e188b('0x2218')],_0xc4a830)[_0x5e188b('0xa44')];}function _0x5154ca(_0x4bbf74,_0x5ccd01){const _0x523d73=_0x448c76;_0x3656e7[_0x523d73('0x1f80')]({'controller':_0x523d73('0x155d'),'controllerAs':'vm','templateUrl':_0x24ef4f,'parent':angular[_0x523d73('0x1194')](_0x3f5b59[_0x523d73('0x8d2')]),'targetEvent':_0x4bbf74,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x6b9b86[_0x523d73('0xedf')],'hopper':_0x5ccd01,'hoppers':_0x6b9b86['ivrCampaignHoppers'][_0x523d73('0x269a')],'license':null,'setting':null,'crudPermissions':_0x6b9b86['crudPermissions']}});}function _0x184e4a(_0x37f1ca){const _0x120726=_0x448c76;_0x275eb2['cmHopper']['delete']({'id':_0x37f1ca['id']})['$promise']['then'](function(){const _0x5e4231=a0_0x3f2c;_0x2cfb05()[_0x5e4231('0x127f')](_0x6b9b86[_0x5e4231('0x1486')]['rows'],{'id':_0x37f1ca['id']}),_0x6b9b86[_0x5e4231('0x1486')][_0x5e4231('0x240f')]-=0x1,!_0x6b9b86[_0x5e4231('0x1486')][_0x5e4231('0x269a')][_0x5e4231('0x264b')]&&_0x20ef96(),_0x50a5af[_0x5e4231('0x103b')]({'title':'Hopper\x20deleted!','msg':_0x37f1ca[_0x5e4231('0x4f0')]?_0x37f1ca['name']+_0x5e4231('0x7cd'):''});})[_0x120726('0x1a80')](function(_0x477ddb){const _0x54c321=_0x120726;if(_0x477ddb['data']&&_0x477ddb[_0x54c321('0x25f4')][_0x54c321('0x61a')]&&_0x477ddb['data'][_0x54c321('0x61a')]['length']){_0x6b9b86[_0x54c321('0x61a')]=_0x477ddb[_0x54c321('0x25f4')][_0x54c321('0x61a')]||[{'message':_0x477ddb['toString'](),'type':_0x54c321('0x6d2')}];for(let _0x1b1517=0x0;_0x1b1517<_0x477ddb[_0x54c321('0x25f4')][_0x54c321('0x61a')][_0x54c321('0x264b')];_0x1b1517++){_0x50a5af[_0x54c321('0xfc9')]({'title':_0x477ddb[_0x54c321('0x25f4')]['errors'][_0x1b1517]['type'],'msg':_0x477ddb[_0x54c321('0x25f4')][_0x54c321('0x61a')][_0x1b1517][_0x54c321('0x1e70')]});}}else _0x50a5af[_0x54c321('0xfc9')]({'title':_0x477ddb[_0x54c321('0x52d')]?_0x54c321('0x1e21')+_0x477ddb[_0x54c321('0x52d')]+_0x54c321('0x11e1')+_0x477ddb['statusText']:_0x54c321('0x6d2'),'msg':_0x477ddb['data']?JSON[_0x54c321('0xbac')](_0x477ddb[_0x54c321('0x25f4')]['message']):_0x477ddb['message']||_0x477ddb['toString']()});});}function _0x15f7ab(){const _0x15a048=_0x448c76,_0x2505c5=angular[_0x15a048('0x225f')](_0x6b9b86[_0x15a048('0x36b')]);return _0x6b9b86['selectedIvrCampaignHoppers']=[],_0x2505c5;}function _0x4e5d1e(_0x5f26fd){const _0x10a019=_0x448c76,_0x3cb4f8=_0x3656e7[_0x10a019('0x1d26')]()['title'](_0x10a019('0x16be'))[_0x10a019('0xf3c')](_0x10a019('0x12b5')+_0x6b9b86[_0x10a019('0x36b')][_0x10a019('0x264b')]+_0x10a019('0x196d')+_0x10a019('0x3f3'))[_0x10a019('0x8e8')](_0x10a019('0x242e'))[_0x10a019('0x203b')](_0x5f26fd)['ok']('OK')[_0x10a019('0x3f')](_0x10a019('0x2d3'));_0x3656e7[_0x10a019('0x1f80')](_0x3cb4f8)['then'](function(){const _0x2dc666=_0x10a019;_0x6b9b86[_0x2dc666('0x36b')][_0x2dc666('0x2782')](function(_0x37df72){_0x184e4a(_0x37df72);}),_0x6b9b86[_0x2dc666('0x36b')]=[];});}let _0x4f5933=!![],_0x4c5ea3=0x1;_0x54842e[_0x448c76('0xe83')]('vm_dc.query.filter',function(_0x2d6039,_0x3c1a5e){const _0x4dc44c=_0x448c76;_0x4f5933?_0x3641b3(function(){_0x4f5933=![];}):(!_0x3c1a5e&&(_0x4c5ea3=_0x6b9b86[_0x4dc44c('0x2218')][_0x4dc44c('0x1a43')]),_0x2d6039!==_0x3c1a5e&&(_0x6b9b86['query'][_0x4dc44c('0x1a43')]=0x1),!_0x2d6039&&(_0x6b9b86[_0x4dc44c('0x2218')][_0x4dc44c('0x1a43')]=_0x4c5ea3),_0x20ef96());});}const _0x4eead9=_0x522011;_0x6ff9b9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'hoppers','hopper',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x6ff9b9(_0x5ee3b8,_0x3313ab,_0x159009,_0x1dc898,_0x19ddf5,_0x2cb0e7,_0x1999ec,_0x4b0425,_0x40717f,_0x427557,_0x1fa383,_0x13961d,_0x4838bd,_0x1c1709){const _0x256608=_0x36e6f4,_0x2d8e96=this;_0x2d8e96[_0x256608('0x98')]=_0x1fa383[_0x256608('0x26cd')](),_0x2d8e96[_0x256608('0x61a')]=[],_0x2d8e96[_0x256608('0xf8a')]=_0x4838bd,_0x2d8e96['license']=_0x13961d,_0x2d8e96[_0x256608('0x243c')]=_0x1c1709,_0x2d8e96['hasModulePermissions']={},_0x2d8e96['passwordPattern']=_0x2d8e96['setting']&&_0x2d8e96[_0x256608('0xf8a')][_0x256608('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2d8e96[_0x256608('0xcdc')]='MOTIONDIALER.EDIT_HOPPER',_0x2d8e96[_0x256608('0x1d98')]=angular[_0x256608('0x225f')](_0x40717f),_0x2d8e96[_0x256608('0x28c4')]=_0x4b0425,_0x2d8e96['newHopper']=![];!_0x2d8e96['hopper']&&(_0x2d8e96[_0x256608('0x1d98')]={},_0x2d8e96[_0x256608('0xcdc')]=_0x256608('0x47a'),_0x2d8e96[_0x256608('0x1e01')]=!![]);_0x3313ab[_0x256608('0x23f')]['id']&&(_0x2d8e96[_0x256608('0x1d98')][_0x256608('0xd88')]=_0x3313ab['params']['id']);_0x2d8e96[_0x256608('0x2576')]=_0x2132ad,_0x2d8e96['saveHopper']=_0x5ebec1,_0x2d8e96[_0x256608('0x2526')]=_0x41b79e,_0x2d8e96['getDateFromString']=_0x4dae0b,_0x2d8e96[_0x256608('0x24a0')]=_0x42438d,_0x1fa383['hasRole'](_0x256608('0xa7c'))?_0x427557['user'][_0x256608('0xd83')]({'fields':_0x256608('0x1776'),'role':'agent','sort':'name','nolimit':_0x256608('0xf3b')})[_0x256608('0xa44')][_0x256608('0x1166')](function(_0x318110){const _0xf043d6=_0x256608;_0x2d8e96[_0xf043d6('0x1f7e')]=_0x318110['rows']||[];})[_0x256608('0x1a80')](function(_0x1fc155){const _0x98ff14=_0x256608;_0x1999ec[_0x98ff14('0xfc9')]({'title':_0x1fc155[_0x98ff14('0x52d')]?_0x98ff14('0x1e21')+_0x1fc155[_0x98ff14('0x52d')]+_0x98ff14('0x11e1')+_0x1fc155[_0x98ff14('0xe1b')]:_0x98ff14('0xd4c'),'msg':_0x1fc155[_0x98ff14('0x25f4')]?JSON[_0x98ff14('0xbac')](_0x1fc155['data']):_0x1fc155[_0x98ff14('0x1586')]()});}):_0x427557['user'][_0x256608('0xd83')]({'fields':'id,name','role':_0x256608('0x1eff'),'sort':_0x256608('0x4f0'),'nolimit':_0x256608('0xf3b')})[_0x256608('0xa44')][_0x256608('0x1166')](function(_0x571b74){const _0x586493=_0x256608;_0x2d8e96[_0x586493('0x1f7e')]=_0x571b74['rows']||[];})[_0x256608('0x1166')](function(){const _0x4312cf=_0x256608;return _0x427557[_0x4312cf('0x17aa')][_0x4312cf('0xd83')]({'userProfileId':_0x2d8e96['currentUser'][_0x4312cf('0xb86')],'sectionId':0xca})['$promise'];})[_0x256608('0x1166')](function(_0x21eb14){const _0x4f9d1a=_0x256608,_0x4a696f=_0x21eb14&&_0x21eb14['rows']?_0x21eb14[_0x4f9d1a('0x269a')][0x0]:null;if(!_0x4a696f)_0x2d8e96[_0x4f9d1a('0x1f7e')]=[];else{if(!_0x4a696f[_0x4f9d1a('0x1a2b')])return _0x427557[_0x4f9d1a('0x4b5')][_0x4f9d1a('0xd83')]({'sectionId':_0x4a696f['id']})[_0x4f9d1a('0xa44')][_0x4f9d1a('0x1166')](function(_0xd8bb54){const _0x48b54e=_0x4f9d1a,_0x31a5e3=_0x2cfb05()[_0x48b54e('0x2563')](_0xd8bb54[_0x48b54e('0x269a')],function(_0x582331){const _0x5f0663=_0x48b54e;return _0x2cfb05()[_0x5f0663('0xc38')](_0x2d8e96[_0x5f0663('0x1f7e')],{'id':_0x582331['resourceId']});});_0x2d8e96[_0x48b54e('0x1f7e')]['forEach'](function(_0x231dae){const _0x36cfb0=_0x48b54e;!_0x2cfb05()[_0x36cfb0('0x1798')](_0x31a5e3,['id',_0x231dae['id']])&&(_0x231dae[_0x36cfb0('0x2378')]=![]),_0x31a5e3[_0x36cfb0('0x1514')](_0x231dae);}),_0x2d8e96['agents']=_0x31a5e3;});}})[_0x256608('0x1a80')](function(_0x5325bb){const _0xc457d5=_0x256608;_0x1999ec[_0xc457d5('0xfc9')]({'title':_0x5325bb[_0xc457d5('0x52d')]?_0xc457d5('0x1e21')+_0x5325bb[_0xc457d5('0x52d')]+_0xc457d5('0x11e1')+_0x5325bb[_0xc457d5('0xe1b')]:_0xc457d5('0xdc5'),'msg':_0x5325bb['data']?JSON[_0xc457d5('0xbac')](_0x5325bb[_0xc457d5('0x25f4')]):_0x5325bb['toString']()});});function _0x2132ad(){const _0x15f849=_0x256608;_0x2d8e96[_0x15f849('0x61a')]=[],_0x427557[_0x15f849('0x256a')][_0x15f849('0x9cc')](_0x2d8e96[_0x15f849('0x1d98')])[_0x15f849('0xa44')][_0x15f849('0x1166')](function(_0x188b3a){const _0x33a6b7=_0x15f849;_0x2d8e96[_0x33a6b7('0x28c4')][_0x33a6b7('0x2450')](_0x188b3a[_0x33a6b7('0x2876')]()),_0x1999ec[_0x33a6b7('0x103b')]({'title':_0x33a6b7('0x1371'),'msg':_0x2d8e96['hopper'][_0x33a6b7('0x4f0')]?_0x2d8e96[_0x33a6b7('0x1d98')][_0x33a6b7('0x4f0')]+_0x33a6b7('0x1eda'):''}),_0x42438d(_0x188b3a);})[_0x15f849('0x1a80')](function(_0x367e32){const _0x221e9c=_0x15f849;if(_0x367e32[_0x221e9c('0x25f4')]&&_0x367e32[_0x221e9c('0x25f4')][_0x221e9c('0x61a')]&&_0x367e32[_0x221e9c('0x25f4')][_0x221e9c('0x61a')]['length']){_0x2d8e96[_0x221e9c('0x61a')]=_0x367e32[_0x221e9c('0x25f4')][_0x221e9c('0x61a')]||[{'message':_0x367e32[_0x221e9c('0x1586')](),'type':_0x221e9c('0x2594')}];for(let _0x501cf8=0x0;_0x501cf8<_0x367e32[_0x221e9c('0x25f4')][_0x221e9c('0x61a')][_0x221e9c('0x264b')];_0x501cf8+=0x1){_0x1999ec[_0x221e9c('0xfc9')]({'title':_0x367e32['data'][_0x221e9c('0x61a')][_0x501cf8]['type'],'msg':_0x367e32[_0x221e9c('0x25f4')]['errors'][_0x501cf8][_0x221e9c('0x1e70')]});}}else _0x1999ec[_0x221e9c('0xfc9')]({'title':_0x367e32[_0x221e9c('0x52d')]?_0x221e9c('0x1e21')+_0x367e32[_0x221e9c('0x52d')]+_0x221e9c('0x11e1')+_0x367e32[_0x221e9c('0xe1b')]:_0x221e9c('0x2594'),'msg':_0x367e32[_0x221e9c('0x25f4')]?JSON[_0x221e9c('0xbac')](_0x367e32[_0x221e9c('0x25f4')]['message']):_0x367e32['toString']()});});}function _0x5ebec1(){const _0x57b031=_0x256608;_0x2d8e96['errors']=[];let _0x4ac056,_0x50ba88,_0x489501,_0x4fd4d7;_0x2d8e96[_0x57b031('0x1d98')][_0x57b031('0x122a')]=_0x2d8e96[_0x57b031('0x1d98')][_0x57b031('0xc10')]?_0x2d8e96[_0x57b031('0x1d98')][_0x57b031('0x122a')]:null,_0x2d8e96[_0x57b031('0x1d98')][_0x57b031('0x2520')]=_0x1fa383[_0x57b031('0x26cd')]()['id'],_0x427557[_0x57b031('0x256a')][_0x57b031('0xd83')]({'id':_0x2d8e96[_0x57b031('0x1d98')]['id'],'attributes':['scheduledat']})['$promise']['then'](function(_0x173b0e){const _0x44162e=_0x57b031;_0x2cfb05()[_0x44162e('0x2863')](_0x173b0e)||_0x2cfb05()[_0x44162e('0x1081')](_0x173b0e)?_0x4ac056=_0x24273b()()[_0x44162e('0x128a')]('YYYY-MM-DD\x20HH:mm:ss'):_0x4ac056=_0x173b0e[_0x44162e('0x1c5e')];})[_0x57b031('0x1951')](function(){const _0x402413=_0x57b031;_0x427557[_0x402413('0x256a')][_0x402413('0x1449')]({'id':_0x2d8e96[_0x402413('0x1d98')]['id']},_0x2cfb05()['omit'](_0x2d8e96['hopper'],[_0x402413('0xc69'),_0x402413('0xd88'),_0x402413('0x1a17'),_0x402413('0x23c')]))[_0x402413('0xa44')][_0x402413('0x1166')](function(_0x26a3e4){const _0x10f5fb=_0x402413;_0x50ba88=_0x26a3e4,_0x427557[_0x10f5fb('0x149e')][_0x10f5fb('0xd83')]({'id':_0x50ba88[_0x10f5fb('0x1a17')],'attributes':[_0x10f5fb('0x18cb'),_0x10f5fb('0xeb0')]})[_0x10f5fb('0xa44')][_0x10f5fb('0x1166')](function(_0x120859){const _0x1f1582=_0x10f5fb;!_0x2cfb05()[_0x1f1582('0x2863')](_0x120859)&&!_0x2cfb05()[_0x1f1582('0x2863')](_0x120859[_0x1f1582('0x18cb')])&&(_0x489501=_0x120859[_0x1f1582('0x18cb')],!_0x2cfb05()[_0x1f1582('0x2863')](_0x120859[_0x1f1582('0xeb0')])&&(_0x489501+='\x20'+_0x120859[_0x1f1582('0xeb0')]));})[_0x10f5fb('0x1a80')](function(){_0x489501=undefined;})['finally'](function(){const _0x2f273b=_0x10f5fb;_0x427557[_0x2f273b('0xb13')]['get']({'raw':![],'id':_0x50ba88[_0x2f273b('0xd88')],'attributes':[_0x2f273b('0x4f0')]})[_0x2f273b('0xa44')][_0x2f273b('0x1166')](function(_0x203b54){const _0x4597f4=_0x2f273b;_0x4fd4d7=_0x203b54[_0x4597f4('0x4f0')];})[_0x2f273b('0x1a80')](function(){_0x4fd4d7=undefined;})[_0x2f273b('0x1951')](function(){const _0x396d2c=_0x2f273b;_0x427557['cmHopperHistory'][_0x396d2c('0x9cc')]({'state':0x18,'statedesc':_0x396d2c('0xb8d'),'scheduledat':_0x4ac056,'calleridnum':_0x50ba88[_0x396d2c('0x2026')],'calleridname':_0x489501,'campaigntype':_0x50ba88[_0x396d2c('0xc69')]?_0x396d2c('0x1d3e'):'ivr','campaign':_0x4fd4d7,'editedat':_0x24273b()()[_0x396d2c('0x128a')](_0x396d2c('0x1084')),'edited':!![],'ListId':_0x50ba88[_0x396d2c('0x23c')],'UserId':_0x1fa383[_0x396d2c('0x26cd')]()['id'],'VoiceQueueId':_0x50ba88[_0x396d2c('0xc69')],'CampaignId':_0x50ba88['CampaignId'],'ContactId':_0x50ba88[_0x396d2c('0x1a17')],'callback':_0x50ba88['callback'],'callbackuniqueid':_0x50ba88[_0x396d2c('0xff')],'countbusyretry':_0x50ba88[_0x396d2c('0x1736')],'countcongestionretry':_0x50ba88['countcongestionretry'],'countglobal':_0x50ba88[_0x396d2c('0x1422')],'countnoanswerretry':_0x50ba88[_0x396d2c('0x1c7')],'followuptime':_0x50ba88[_0x396d2c('0x8be')],'recallme':_0x50ba88[_0x396d2c('0xc10')]});});});const _0x2d3c91=_0x2cfb05()[_0x10f5fb('0xc38')](_0x2d8e96[_0x10f5fb('0x28c4')],{'id':_0x26a3e4['id']});_0x2d3c91&&_0x2cfb05()[_0x10f5fb('0xcc3')](_0x2d3c91,_0x2cfb05()[_0x10f5fb('0x1a08')](_0x26a3e4[_0x10f5fb('0x2876')](),_0x2cfb05()['keys'](_0x2d3c91))),_0x1999ec[_0x10f5fb('0x103b')]({'title':_0x10f5fb('0x108f'),'msg':_0x2d8e96['hopper'][_0x10f5fb('0x4f0')]?_0x2d8e96[_0x10f5fb('0x1d98')]['name']+_0x10f5fb('0x7d'):''}),_0x42438d(_0x26a3e4);})[_0x402413('0x1a80')](function(_0x24ecdb){const _0x513d71=_0x402413;if(_0x24ecdb[_0x513d71('0x25f4')]&&_0x24ecdb[_0x513d71('0x25f4')][_0x513d71('0x61a')]&&_0x24ecdb[_0x513d71('0x25f4')][_0x513d71('0x61a')][_0x513d71('0x264b')]){_0x2d8e96[_0x513d71('0x61a')]=_0x24ecdb[_0x513d71('0x25f4')][_0x513d71('0x61a')]||[{'message':_0x24ecdb[_0x513d71('0x1586')](),'type':_0x513d71('0xd28')}];for(let _0x209d81=0x0;_0x209d81<_0x24ecdb['data'][_0x513d71('0x61a')][_0x513d71('0x264b')];_0x209d81++){_0x1999ec[_0x513d71('0xfc9')]({'title':_0x24ecdb['data']['errors'][_0x209d81][_0x513d71('0x1345')],'msg':_0x24ecdb['data'][_0x513d71('0x61a')][_0x209d81][_0x513d71('0x1e70')]});}}else _0x1999ec[_0x513d71('0xfc9')]({'title':_0x24ecdb['status']?_0x513d71('0x1e21')+_0x24ecdb['status']+_0x513d71('0x11e1')+_0x24ecdb['statusText']:_0x513d71('0xd28'),'msg':_0x24ecdb['data']?JSON['stringify'](_0x24ecdb[_0x513d71('0x25f4')][_0x513d71('0x1e70')]):_0x24ecdb[_0x513d71('0x1586')]()});});});}function _0x41b79e(_0x49cee3){const _0xec0b19=_0x256608;_0x2d8e96['errors']=[];const _0x5657ae=_0x1dc898[_0xec0b19('0x1d26')]()['title']('Are\x20you\x20sure?')[_0xec0b19('0xacc')](_0xec0b19('0xe6c'))[_0xec0b19('0x8e8')]('Delete\x20Hopper')['ok']('Delete')['cancel'](_0xec0b19('0x497'))[_0xec0b19('0x203b')](_0x49cee3);_0x1dc898[_0xec0b19('0x1f80')](_0x5657ae)[_0xec0b19('0x1166')](function(){const _0x146741=_0xec0b19;_0x427557[_0x146741('0x256a')][_0x146741('0x906')]({'id':_0x2d8e96[_0x146741('0x1d98')]['id']})[_0x146741('0xa44')]['then'](function(){const _0x26f57d=_0x146741;_0x2cfb05()[_0x26f57d('0x127f')](_0x2d8e96[_0x26f57d('0x28c4')],{'id':_0x2d8e96[_0x26f57d('0x1d98')]['id']}),_0x1999ec[_0x26f57d('0x103b')]({'title':_0x26f57d('0x40a'),'msg':(_0x2d8e96['hopper'][_0x26f57d('0x4f0')]||_0x26f57d('0x1d98'))+'\x20has\x20been\x20deleted!'}),_0x42438d(_0x2d8e96['hopper']);})[_0x146741('0x1a80')](function(_0x186ad4){const _0x491d4a=_0x146741;if(_0x186ad4[_0x491d4a('0x25f4')]&&_0x186ad4[_0x491d4a('0x25f4')][_0x491d4a('0x61a')]&&_0x186ad4[_0x491d4a('0x25f4')][_0x491d4a('0x61a')][_0x491d4a('0x264b')]){_0x2d8e96[_0x491d4a('0x61a')]=_0x186ad4[_0x491d4a('0x25f4')][_0x491d4a('0x61a')]||[{'message':_0x186ad4['toString'](),'type':_0x491d4a('0x14fb')}];for(let _0x37a106=0x0;_0x37a106<_0x186ad4['data']['errors'][_0x491d4a('0x264b')];_0x37a106++){_0x1999ec[_0x491d4a('0xfc9')]({'title':_0x186ad4[_0x491d4a('0x25f4')][_0x491d4a('0x61a')][_0x37a106][_0x491d4a('0x1345')],'msg':_0x186ad4['data'][_0x491d4a('0x61a')][_0x37a106][_0x491d4a('0x1e70')]});}}else _0x1999ec['error']({'title':_0x186ad4[_0x491d4a('0x52d')]?_0x491d4a('0x1e21')+_0x186ad4[_0x491d4a('0x52d')]+_0x491d4a('0x11e1')+_0x186ad4['statusText']:_0x491d4a('0x14fb'),'msg':_0x186ad4[_0x491d4a('0x25f4')]?JSON[_0x491d4a('0xbac')](_0x186ad4[_0x491d4a('0x25f4')][_0x491d4a('0x1e70')]):_0x186ad4['message']||_0x186ad4[_0x491d4a('0x1586')]()});});},function(){});}function _0x4dae0b(_0x3df99a){return _0x3df99a===null?undefined:new Date(_0x3df99a);}function _0x42438d(_0x3e8800){const _0xed20a4=_0x256608;_0x1dc898[_0xed20a4('0x1197')](_0x3e8800);}}const _0x42740f=_0x6ff9b9;_0x1a0b07[_0x36e6f4('0x1294')]=['api',_0x36e6f4('0x1d2e')];function _0x1a0b07(_0x5f07f6,_0x274e44){const _0x3cd11e=_0x36e6f4,_0x225ce8=this;_0x225ce8[_0x3cd11e('0xedf')]={},_0x225ce8[_0x3cd11e('0x24d5')]=_0x2992d9;function _0x2992d9(_0x907f5c){const _0x594763=_0x3cd11e;_0x225ce8[_0x594763('0xedf')]=_0x907f5c,_0x5f07f6[_0x594763('0x256a')][_0x594763('0xd83')]({'limit':0x0,'CampaignId':_0x907f5c['id']})[_0x594763('0xa44')]['then'](function(_0x4d27c7){const _0x1aef39=_0x594763;return _0x225ce8['total']=_0x4d27c7[_0x1aef39('0x240f')]||0x0,_0x5f07f6[_0x1aef39('0x256a')][_0x1aef39('0xd83')]({'limit':0x0,'CampaignId':_0x907f5c['id'],'active':![],'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0})[_0x1aef39('0xa44')];})[_0x594763('0x1166')](function(_0x2d6c63){const _0x11d5a0=_0x594763;return _0x225ce8[_0x11d5a0('0xaef')]=_0x2d6c63['count']||0x0,_0x5f07f6[_0x11d5a0('0x1806')]['get']({'limit':0x0,'CampaignId':_0x907f5c['id']})[_0x11d5a0('0xa44')];})[_0x594763('0x1166')](function(_0x544527){const _0x3a28e2=_0x594763;_0x225ce8['closed']=_0x544527[_0x3a28e2('0x240f')]||0x0;})[_0x594763('0x1a80')](function(_0x48709f){const _0xd8a3a7=_0x594763;_0x274e44['error']({'title':_0x48709f[_0xd8a3a7('0x52d')]?_0xd8a3a7('0x1e21')+_0x48709f[_0xd8a3a7('0x52d')]+_0xd8a3a7('0x11e1')+_0x48709f['statusText']:_0xd8a3a7('0x2597'),'msg':_0x48709f[_0xd8a3a7('0x25f4')]?JSON[_0xd8a3a7('0xbac')](_0x48709f[_0xd8a3a7('0x25f4')]):_0x48709f['toString']()});});}}const _0x19e2d9=_0x1a0b07;_0x201fa4[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0xedf'),'$translate',_0x36e6f4('0x8da'),'Auth',_0x36e6f4('0x243c')];function _0x201fa4(_0x384f8f,_0x4275ff,_0x26840c,_0xd28eba,_0x5ceddd,_0x2bf13c,_0x35af4e,_0x2ff112,_0x2f65c1){const _0x23df92=_0x36e6f4,_0x1abe3e=this;_0x1abe3e[_0x23df92('0x98')]=_0x2ff112[_0x23df92('0x26cd')](),_0x1abe3e[_0x23df92('0xedf')]=_0x5ceddd,_0x1abe3e[_0x23df92('0x243c')]=_0x2f65c1,_0x1abe3e['apiRoute']=_0x23df92('0xb13'),_0x1abe3e['getApi']=_0x23df92('0x5a1'),_0x1abe3e[_0x23df92('0x7dd')]=_0x23df92('0x1e0b'),_0x1abe3e['removeApi']='removeLists',_0x1abe3e[_0x23df92('0xbd7')]=[],_0x1abe3e[_0x23df92('0x10ab')]=[],_0x1abe3e[_0x23df92('0x18e1')]=[],_0x1abe3e['startingAllowedItems']=[],_0x1abe3e[_0x23df92('0x2781')]=[],_0x1abe3e['pendingChanges']=![],_0x1abe3e[_0x23df92('0x34b')]=![],_0x1abe3e[_0x23df92('0xc68')]={'readOnly':!_0x1abe3e['crudPermissions']['canEdit'],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':![],'orderBy':_0x23df92('0x4f0'),'line1':_0x23df92('0x4f0'),'line2':'','line3':'','labelAll':_0x2bf13c['instant'](_0x23df92('0x1676')),'labelSelected':_0x2bf13c[_0x23df92('0x25cc')](_0x23df92('0x834')),'transferCallback':function(){const _0x27b973=_0x23df92,_0x351d6e=_0x2cfb05()[_0x27b973('0x2802')](_0x1abe3e['startingSelectedItems'],_0x1abe3e[_0x27b973('0x18e1')],'id');_0x1abe3e[_0x27b973('0x14d7')]=_0x2cfb05()[_0x27b973('0x1081')](_0x351d6e)?![]:!![];}},_0x1abe3e['onInit']=_0x102847,_0x1abe3e[_0x23df92('0x12a9')]=_0x1270b8,_0x1abe3e[_0x23df92('0x24a0')]=_0x280ca0;function _0x102847(){const _0x18411c=_0x23df92;return _0x2ff112['hasRole']('admin')?_0x114a5e()[_0x18411c('0x1a80')](function(_0xa9ed88){const _0x96f901=_0x18411c;_0x26840c[_0x96f901('0xfc9')]({'title':_0xa9ed88['status']?'API:'+_0xa9ed88[_0x96f901('0x52d')]+_0x96f901('0x11e1')+_0xa9ed88['statusText']:'SYSTEM:GETLISTS','msg':_0xa9ed88[_0x96f901('0x52d')]?JSON[_0x96f901('0xbac')](_0xa9ed88['data']):_0xa9ed88['toString']()});}):_0x54c479()[_0x18411c('0x1166')](function(_0x2eabf4){const _0x191cd2=_0x18411c;return _0x1abe3e[_0x191cd2('0xe60')]=_0x2eabf4,_0x114a5e();})[_0x18411c('0x1a80')](function(_0x5d846b){const _0x553960=_0x18411c;_0x26840c[_0x553960('0xfc9')]({'title':_0x5d846b['status']?_0x553960('0x1e21')+_0x5d846b['status']+'\x20-\x20'+_0x5d846b[_0x553960('0xe1b')]:_0x553960('0x14e6'),'msg':_0x5d846b[_0x553960('0x52d')]?JSON['stringify'](_0x5d846b['data']):_0x5d846b[_0x553960('0x1586')]()});});}function _0x54c479(){return _0x4275ff(function(_0x201ee1,_0x1b8bc2){const _0x1c7c34=a0_0x3f2c;_0xd28eba['userProfileSection']['get']({'userProfileId':_0x1abe3e['currentUser'][_0x1c7c34('0xb86')],'name':_0x1c7c34('0x1cae')})[_0x1c7c34('0xa44')][_0x1c7c34('0x1166')](function(_0x1cec91){const _0x485179=_0x1c7c34,_0xa8f183=_0x1cec91&&_0x1cec91[_0x485179('0x269a')]?_0x1cec91[_0x485179('0x269a')][0x0]:null;_0x201ee1(_0xa8f183);})[_0x1c7c34('0x1a80')](function(_0x356ece){_0x1b8bc2(_0x356ece);});});}function _0x114a5e(){return _0x4275ff(function(_0x2c423a,_0x232a4f){const _0x4baaad=a0_0x3f2c;return _0x23ab68()[_0x4baaad('0x1166')](function(_0x585e14){const _0x186c1d=_0x4baaad;return _0x1abe3e[_0x186c1d('0xbd7')]=_0x585e14[_0x186c1d('0x269a')]?_0x585e14[_0x186c1d('0x269a')]:[],_0x2ff112[_0x186c1d('0x1ac6')]('admin')?_0x585e14:_0x1abe3e['section']?_0x1abe3e[_0x186c1d('0xe60')]['autoAssociation']?_0x585e14:_0x1f64b8():null;})[_0x4baaad('0x1166')](function(_0x1a57e4){const _0x4166b6=_0x4baaad,_0x283700=_0x1a57e4&&_0x1a57e4[_0x4166b6('0x269a')]?_0x1a57e4[_0x4166b6('0x269a')]:[];return _0x1abe3e['allowedItems']=_0x2cfb05()[_0x4166b6('0x2563')](_0x283700,function(_0x357dbf){const _0x1e6b0c=_0x4166b6;return _0x2cfb05()[_0x1e6b0c('0xc38')](_0x1abe3e['items'],{'id':_0x2ff112[_0x1e6b0c('0x1ac6')](_0x1e6b0c('0xa7c'))||_0x1abe3e[_0x1e6b0c('0xe60')][_0x1e6b0c('0x1a2b')]?_0x357dbf['id']:_0x357dbf[_0x1e6b0c('0x24e8')]});}),_0x1abe3e['startingAllowedItems']=angular['copy'](_0x1abe3e[_0x4166b6('0x10ab')]),_0x1abe3e[_0x4166b6('0xbd7')][_0x4166b6('0x2782')](function(_0x4bc13a){const _0x331c0f=_0x4166b6,_0x560d8a=_0x2cfb05()[_0x331c0f('0xc38')](_0x1abe3e[_0x331c0f('0x10ab')],{'id':_0x4bc13a['id']});_0x1abe3e[_0x331c0f('0x98')]['role']==='admin'?_0x4bc13a['isValid']=!![]:_0x4bc13a[_0x331c0f('0x26ef')]=typeof _0x560d8a!==_0x331c0f('0x1048')?!![]:![];}),_0x2d25e7();})['then'](function(_0x4bd02d){const _0x7ffa68=_0x4baaad,_0x4947fb=_0x4bd02d&&_0x4bd02d[_0x7ffa68('0x269a')]?_0x4bd02d[_0x7ffa68('0x269a')]:[];_0x1abe3e['selectedItems']=_0x2cfb05()[_0x7ffa68('0x2563')](_0x4947fb,function(_0x59dad1){const _0x199399=_0x7ffa68;return _0x2cfb05()[_0x199399('0xc38')](_0x1abe3e[_0x199399('0xbd7')],{'id':_0x59dad1['id']});}),_0x1abe3e[_0x7ffa68('0x2781')]=angular[_0x7ffa68('0x225f')](_0x1abe3e['selectedItems']),_0x1abe3e['dualMultiselectOptions']['selectedItems']=_0x1abe3e[_0x7ffa68('0x18e1')],_0x1abe3e[_0x7ffa68('0xc68')][_0x7ffa68('0xbd7')]=_0x2cfb05()['differenceBy'](_0x1abe3e[_0x7ffa68('0x10ab')],_0x1abe3e[_0x7ffa68('0xc68')][_0x7ffa68('0x18e1')],'id'),_0x2c423a();})[_0x4baaad('0x1a80')](function(_0x8da748){_0x232a4f(_0x8da748);});});}function _0x1f64b8(){return _0x4275ff(function(_0x3ecfea,_0x2e4588){const _0x4ffdac=a0_0x3f2c;return _0xd28eba['userProfileResource'][_0x4ffdac('0xd83')]({'sectionId':_0x1abe3e[_0x4ffdac('0xe60')]['id'],'nolimit':!![]})[_0x4ffdac('0xa44')][_0x4ffdac('0x1166')](function(_0x36c8ac){_0x3ecfea(_0x36c8ac);})[_0x4ffdac('0x1a80')](function(_0x162e4a){_0x2e4588(_0x162e4a);});});}function _0x2d25e7(){return _0x4275ff(function(_0x4e3e57,_0x2b10f0){const _0x419180=a0_0x3f2c,_0x5ad7a2=_0xd28eba[_0x1abe3e['apiRoute']];return _0x5ad7a2[_0x1abe3e[_0x419180('0x1bb3')]]({'id':_0x1abe3e[_0x419180('0xedf')]['id'],'fields':_0x419180('0x1776'),'nolimit':!![]})[_0x419180('0xa44')][_0x419180('0x1166')](function(_0x370415){_0x4e3e57(_0x370415);})[_0x419180('0x1a80')](function(_0x2ac6f1){_0x2b10f0(_0x2ac6f1);});});}function _0x23ab68(){return _0x4275ff(function(_0x4e3252,_0xa709c8){const _0xc2e5f7=a0_0x3f2c;return _0xd28eba['cmList']['get']({'fields':_0xc2e5f7('0x1776'),'nolimit':!![]})[_0xc2e5f7('0xa44')]['then'](function(_0x26302f){_0x4e3252(_0x26302f);})[_0xc2e5f7('0x1a80')](function(_0x42ae8c){_0xa709c8(_0x42ae8c);});});}function _0x474797(_0x18732b){return _0x4275ff(function(_0x350b51,_0x470bd8){const _0x362457=a0_0x3f2c;if(_0x2cfb05()[_0x362457('0x1081')](_0x18732b))_0x350b51();else{const _0x37cd6b=_0xd28eba[_0x1abe3e[_0x362457('0x19dc')]];_0x37cd6b[_0x1abe3e['addApi']]({'id':_0x1abe3e[_0x362457('0xedf')]['id'],'ids':_0x2cfb05()[_0x362457('0x2563')](_0x18732b,'id')})[_0x362457('0xa44')][_0x362457('0x1166')](function(){_0x350b51();})[_0x362457('0x1a80')](function(_0xeb3e5c){_0x470bd8(_0xeb3e5c);});}});}function _0x4861cf(_0x3dc4f4){return _0x4275ff(function(_0x3a4e88,_0x4e5f00){const _0x405183=a0_0x3f2c;if(_0x2cfb05()[_0x405183('0x1081')](_0x3dc4f4))_0x3a4e88();else{const _0x572fdc=_0xd28eba[_0x1abe3e[_0x405183('0x19dc')]];_0x572fdc[_0x1abe3e[_0x405183('0x10d1')]]({'id':_0x1abe3e[_0x405183('0xedf')]['id'],'ids':_0x2cfb05()[_0x405183('0x2563')](_0x3dc4f4,'id')})[_0x405183('0xa44')][_0x405183('0x1166')](function(){_0x3a4e88();})['catch'](function(_0x5c5520){_0x4e5f00(_0x5c5520);});}});}function _0x1270b8(){const _0x464b99=_0x23df92;_0x1abe3e[_0x464b99('0x34b')]=!![];const _0x1d2cc0=_0x2cfb05()[_0x464b99('0x24ac')](_0x1abe3e['startingSelectedItems'],_0x1abe3e[_0x464b99('0x18e1')],'id'),_0x5d9083=_0x2cfb05()[_0x464b99('0x24ac')](_0x1abe3e[_0x464b99('0x18e1')],_0x1abe3e['startingSelectedItems'],'id');return _0x4861cf(_0x1d2cc0)[_0x464b99('0x1166')](function(){return _0x474797(_0x5d9083);})[_0x464b99('0x1166')](function(){const _0xe78b4=_0x464b99;_0x1abe3e[_0xe78b4('0x14d7')]=![],_0x1abe3e[_0xe78b4('0x2111')]=angular['copy'](_0x1abe3e[_0xe78b4('0x10ab')]),_0x1abe3e[_0xe78b4('0x2781')]=angular[_0xe78b4('0x225f')](_0x1abe3e['selectedItems']),_0x26840c['success']({'title':_0xe78b4('0x983'),'msg':_0xe78b4('0x9ed')});})[_0x464b99('0x1a80')](function(_0x388975){const _0x1ea47b=_0x464b99;_0x26840c[_0x1ea47b('0xfc9')]({'title':_0x388975[_0x1ea47b('0x52d')]?_0x1ea47b('0x1e21')+_0x388975[_0x1ea47b('0x52d')]+_0x1ea47b('0x11e1')+_0x388975[_0x1ea47b('0xe1b')]:_0x1ea47b('0x1b29'),'msg':_0x388975[_0x1ea47b('0x52d')]?JSON[_0x1ea47b('0xbac')](_0x388975[_0x1ea47b('0x25f4')]):_0x388975[_0x1ea47b('0x1586')]()});})[_0x464b99('0x1951')](function(){_0x1abe3e['loading']=![];});}function _0x280ca0(){_0x384f8f['hide']();}}const _0x29d0f9=_0x201fa4;_0x4a91d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$mdDialog','toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0xedf'),'listsCampaign',_0x36e6f4('0x1e7e'),'$q'];function _0x4a91d(_0x257a1b,_0x25604d,_0x5dbbb8,_0x3c1a11,_0xb01b22,_0x3a1ef4,_0xf9df99,_0x544801){const _0x53aa34=_0x36e6f4,_0x24465f=this;_0x24465f[_0x53aa34('0x1300')]=[],_0x24465f[_0x53aa34('0xbd7')]=_0x3a1ef4?_0x3a1ef4:[],_0x24465f['loading']=![],_0x24465f['closeDialog']=_0x5ec518,_0x24465f[_0x53aa34('0xf56')]=_0x163beb,_0x24465f['toggle']=_0x22a811,_0x24465f['isIndeterminate']=_0x4474bb,_0x24465f['isChecked']=_0x630923,_0x24465f[_0x53aa34('0xe50')]=_0x119cef,_0x24465f[_0x53aa34('0xb87')]=_0x22b663;function _0x22a811(_0x12b056,_0x2e7864){const _0x78ef28=_0x53aa34,_0x1ead1e=_0x2e7864[_0x78ef28('0x2379')](_0x12b056);_0x1ead1e>-0x1?_0x2e7864['splice'](_0x1ead1e,0x1):_0x2e7864[_0x78ef28('0x1514')](_0x12b056);}function _0x163beb(_0x4f2f3e,_0x521930){const _0x3cc122=_0x53aa34;return _0x521930[_0x3cc122('0x2379')](_0x4f2f3e)>-0x1;}function _0x4474bb(){const _0x14c15e=_0x53aa34;return _0x24465f[_0x14c15e('0x1300')][_0x14c15e('0x264b')]!==0x0&&_0x24465f[_0x14c15e('0x1300')]['length']!==_0x24465f[_0x14c15e('0xbd7')][_0x14c15e('0x264b')];}function _0x630923(){const _0x40b7c2=_0x53aa34;return _0x24465f[_0x40b7c2('0x1300')][_0x40b7c2('0x264b')]===_0x24465f[_0x40b7c2('0xbd7')]['length'];}function _0x119cef(){const _0x474ceb=_0x53aa34;if(_0x24465f[_0x474ceb('0x1300')]['length']===_0x24465f['items'][_0x474ceb('0x264b')])_0x24465f[_0x474ceb('0x1300')]=[];else(_0x24465f[_0x474ceb('0x1300')][_0x474ceb('0x264b')]===0x0||_0x24465f[_0x474ceb('0x1300')]['length']>0x0)&&(_0x24465f[_0x474ceb('0x1300')]=_0x24465f[_0x474ceb('0xbd7')][_0x474ceb('0x233')](0x0));}function _0x5ec518(){const _0x126b26=_0x53aa34;_0x25604d[_0x126b26('0x1197')]();}function _0x22b663(){_0x24465f['loading']=!![];const _0x3e51ad=_0x2f1806();_0x3e51ad['finally'](function(){const _0x5c591e=a0_0x3f2c;_0x24465f[_0x5c591e('0x34b')]=![],_0x5ec518();});}function _0x2f1806(){return _0x544801(function(_0x4a3748){const _0x1500bd=a0_0x3f2c;for(let _0x1a7b09=0x0;_0x1a7b09<_0x24465f[_0x1500bd('0x1300')][_0x1500bd('0x264b')];_0x1a7b09+=0x1){_0x3e2271(_0xb01b22['id'],_0x24465f[_0x1500bd('0x1300')][_0x1a7b09]);}_0x935d1d(_0x4a3748);});}function _0x3e2271(_0xc5b7ec,_0x11ad41){const _0x1342d0=_0x11ad41['id'];_0xf9df99['enqueue'](function(){const _0x269de9=a0_0x3f2c;return _0x3c1a11[_0x269de9('0xb13')][_0x269de9('0xed4')]({'id':_0xc5b7ec,'ids':_0x1342d0})['$promise'][_0x269de9('0x1166')](function(){const _0x2a7669=_0x269de9;return _0x3c1a11[_0x2a7669('0xb13')][_0x2a7669('0x1e0b')]({'id':_0xc5b7ec,'ids':_0x1342d0,'dialCheckDuplicateType':'never'})[_0x2a7669('0xa44')];})['then'](function(){const _0x51c8b1=_0x269de9;_0x5dbbb8[_0x51c8b1('0x103b')]({'title':_0x51c8b1('0xc7e'),'msg':_0x51c8b1('0xdac')+_0x11ad41['name']+_0x51c8b1('0x25e4')});})[_0x269de9('0x1a80')](function(_0x4002c8){const _0x2fb534=_0x269de9;_0x5dbbb8[_0x2fb534('0xfc9')]({'title':_0x4002c8[_0x2fb534('0x52d')]?_0x2fb534('0x1e21')+_0x4002c8[_0x2fb534('0x52d')]+'\x20-\x20'+_0x4002c8[_0x2fb534('0xe1b')]:_0x2fb534('0x26f9'),'msg':_0x4002c8['status']?JSON['stringify'](_0x4002c8[_0x2fb534('0x25f4')]):_0x4002c8['toString']()});});});}function _0x935d1d(_0x12dee4){const _0x2fcd9b=_0x53aa34;_0xf9df99[_0x2fcd9b('0x370')](function(){return _0x12dee4();});}}const _0x30cea3=_0x4a91d,_0x2a1237=_0x2734b2['p']+_0x36e6f4('0x1936'),_0x3c2cd5=_0x2734b2['p']+_0x36e6f4('0x23c5'),_0x11c6b5=_0x2734b2['p']+_0x36e6f4('0x2239'),_0x2975bb=_0x2734b2['p']+'src/js/modules/main/apps/motiondialer/views/ivrCampaigns/edit/resetlist/resetlist.html/resetlist.html';_0xb08194[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0xedf'),_0x36e6f4('0x17aa')];function _0xb08194(_0x5375ab,_0x5e7707,_0x47835d,_0xad6dd8,_0x10308c,_0x437eb6,_0x22b0f1,_0x2caada,_0x2b8792,_0x3c2ac1,_0x509a83,_0x4d9d31){const _0x202de8=_0x36e6f4,_0x3b12f9=this;_0x3b12f9[_0x202de8('0x98')]=_0x3c2ac1[_0x202de8('0x26cd')](),_0x3b12f9[_0x202de8('0x5c9')]=_0x437eb6,_0x3b12f9['setting']=_0x22b0f1,_0x3b12f9[_0x202de8('0x2900')]=_0x3b12f9[_0x202de8('0xf8a')][_0x202de8('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3b12f9[_0x202de8('0x246b')]=_0x5e7707[_0x202de8('0x6f1')]()+_0x202de8('0xc51')+_0x5e7707[_0x202de8('0x1690')](),_0x3b12f9['ivrCampaign']=_0x509a83||_0x5375ab[_0x202de8('0x23f')][_0x202de8('0xedf')]||{},_0x3b12f9[_0x202de8('0x17aa')]=_0x4d9d31&&_0x4d9d31['count']==0x1?_0x4d9d31[_0x202de8('0x269a')][0x0]:null,_0x3b12f9[_0x202de8('0x243c')]=_0x3c2ac1[_0x202de8('0xd87')](_0x3b12f9[_0x202de8('0x17aa')]?_0x3b12f9[_0x202de8('0x17aa')][_0x202de8('0x243c')]:null),_0x3b12f9[_0x202de8('0x128b')]={},_0x3b12f9[_0x202de8('0x2669')]=_0x5375ab[_0x202de8('0x23f')][_0x202de8('0xbe3')]||0x0,_0x3b12f9[_0x202de8('0x249d')]=_0x114b37,_0x3b12f9[_0x202de8('0x2112')]=_0x31e76a,_0x3b12f9[_0x202de8('0xe2b')]=_0x136898,_0x3b12f9[_0x202de8('0x738')]=_0x2592eb,_0x3b12f9[_0x202de8('0x22c1')]=_0x1cfc2f,_0x3b12f9[_0x202de8('0x31d')]=_0x2b8792[_0x202de8('0x1fa1')],_0x3b12f9['gotoIvrCampaigns']=_0x49041d,_0x3b12f9[_0x202de8('0x123a')]=_0x75c767,_0x3c2ac1[_0x202de8('0x1ac6')]('admin')?_0x2caada[_0x202de8('0x3b2')][_0x202de8('0xd83')]({'fields':_0x202de8('0x1776'),'sort':_0x202de8('0x4f0')})['$promise'][_0x202de8('0x1166')](function(_0x3f5b01){const _0x4aadfc=_0x202de8;_0x3b12f9[_0x4aadfc('0xf24')]=_0x3f5b01[_0x4aadfc('0x269a')]||[];})[_0x202de8('0x1a80')](function(_0x38e8a4){const _0x3f6511=_0x202de8;_0x2b8792[_0x3f6511('0xfc9')]({'title':_0x38e8a4[_0x3f6511('0x52d')]?'API:'+_0x38e8a4[_0x3f6511('0x52d')]+_0x3f6511('0x11e1')+_0x38e8a4['statusText']:'SYSTEM:GET_TRUNKS','msg':_0x38e8a4[_0x3f6511('0x25f4')]?JSON['stringify'](_0x38e8a4[_0x3f6511('0x25f4')]):_0x38e8a4[_0x3f6511('0x1586')]()});}):_0x2caada[_0x202de8('0x3b2')][_0x202de8('0xd83')]({'fields':'id,name','sort':_0x202de8('0x4f0')})[_0x202de8('0xa44')]['then'](function(_0x3222c3){const _0x1fd329=_0x202de8;_0x3b12f9['trunks']=_0x3222c3[_0x1fd329('0x269a')]||[];})[_0x202de8('0x1166')](function(){const _0x409c59=_0x202de8;return _0x2caada[_0x409c59('0x17aa')]['get']({'userProfileId':_0x3b12f9[_0x409c59('0x98')][_0x409c59('0xb86')],'sectionId':0x3f3})[_0x409c59('0xa44')];})[_0x202de8('0x1166')](function(_0x3ce963){const _0x2f5e5d=_0x202de8,_0x1d7952=_0x3ce963&&_0x3ce963[_0x2f5e5d('0x269a')]?_0x3ce963[_0x2f5e5d('0x269a')][0x0]:null;if(!_0x1d7952)_0x3b12f9['trunks']=[];else{if(!_0x1d7952['autoAssociation'])return _0x2caada[_0x2f5e5d('0x4b5')][_0x2f5e5d('0xd83')]({'sectionId':_0x1d7952['id']})[_0x2f5e5d('0xa44')][_0x2f5e5d('0x1166')](function(_0x37e82d){const _0x10cf0c=_0x2f5e5d,_0x52c16a=_0x2cfb05()[_0x10cf0c('0x2563')](_0x37e82d[_0x10cf0c('0x269a')],function(_0x334249){const _0x2ed7af=_0x10cf0c;return _0x2cfb05()[_0x2ed7af('0xc38')](_0x3b12f9[_0x2ed7af('0xf24')],{'id':_0x334249[_0x2ed7af('0x24e8')]});});_0x3b12f9['trunks'][_0x10cf0c('0x2782')](function(_0x5c02ab){const _0x1f30e3=_0x10cf0c;!_0x2cfb05()[_0x1f30e3('0x1798')](_0x52c16a,['id',_0x5c02ab['id']])&&(_0x5c02ab[_0x1f30e3('0x2378')]=![]),_0x52c16a['push'](_0x5c02ab);}),_0x3b12f9[_0x10cf0c('0xf24')]=_0x52c16a;});}})[_0x202de8('0x1a80')](function(_0x248fe0){const _0x4f7f39=_0x202de8;_0x2b8792[_0x4f7f39('0xfc9')]({'title':_0x248fe0['status']?_0x4f7f39('0x1e21')+_0x248fe0[_0x4f7f39('0x52d')]+_0x4f7f39('0x11e1')+_0x248fe0[_0x4f7f39('0xe1b')]:'SYSTEM:GETtrunks','msg':_0x248fe0['data']?JSON[_0x4f7f39('0xbac')](_0x248fe0[_0x4f7f39('0x25f4')]):_0x248fe0[_0x4f7f39('0x1586')]()});}),_0x3c2ac1[_0x202de8('0x1ac6')](_0x202de8('0xa7c'))?_0x2caada[_0x202de8('0x7e4')][_0x202de8('0xd83')]({'fields':'id,name','sort':_0x202de8('0x4f0')})[_0x202de8('0xa44')][_0x202de8('0x1166')](function(_0x5aa080){const _0x5700e0=_0x202de8;_0x3b12f9[_0x5700e0('0x149f')]=_0x5aa080[_0x5700e0('0x269a')]||[];})['catch'](function(_0x2156a9){const _0x1b4067=_0x202de8;_0x2b8792[_0x1b4067('0xfc9')]({'title':_0x2156a9[_0x1b4067('0x52d')]?_0x1b4067('0x1e21')+_0x2156a9[_0x1b4067('0x52d')]+_0x1b4067('0x11e1')+_0x2156a9[_0x1b4067('0xe1b')]:_0x1b4067('0x178b'),'msg':_0x2156a9[_0x1b4067('0x25f4')]?JSON[_0x1b4067('0xbac')](_0x2156a9[_0x1b4067('0x25f4')]):_0x2156a9[_0x1b4067('0x1586')]()});}):_0x2caada[_0x202de8('0x7e4')][_0x202de8('0xd83')]({'fields':_0x202de8('0x1776'),'sort':_0x202de8('0x4f0')})['$promise']['then'](function(_0x3342bb){const _0x399a89=_0x202de8;_0x3b12f9[_0x399a89('0x149f')]=_0x3342bb[_0x399a89('0x269a')]||[];})[_0x202de8('0x1166')](function(){const _0x44a5bb=_0x202de8;return _0x2caada[_0x44a5bb('0x17aa')][_0x44a5bb('0xd83')]({'userProfileId':_0x3b12f9['currentUser'][_0x44a5bb('0xb86')],'sectionId':0x44f})['$promise'];})[_0x202de8('0x1166')](function(_0x4ae615){const _0x9092d8=_0x202de8,_0x4eeb44=_0x4ae615&&_0x4ae615[_0x9092d8('0x269a')]?_0x4ae615[_0x9092d8('0x269a')][0x0]:null;if(!_0x4eeb44){const _0x44843e=[];let _0x10eed4=null;_0x3b12f9[_0x9092d8('0xedf')]&&(_0x10eed4=_0x2cfb05()[_0x9092d8('0xc38')](_0x3b12f9[_0x9092d8('0x149f')],{'id':Number(_0x3b12f9[_0x9092d8('0xedf')][_0x9092d8('0x28a9')])}));for(let _0x1a583e=0x0;_0x1a583e<_0x3b12f9['projects'][_0x9092d8('0x264b')];_0x1a583e++){_0x10eed4&&_0x3b12f9['projects'][_0x1a583e]['id']===_0x10eed4['id']&&(_0x3b12f9[_0x9092d8('0x149f')][_0x1a583e][_0x9092d8('0x2378')]=![],_0x44843e[_0x9092d8('0x1514')](_0x3b12f9[_0x9092d8('0x149f')][_0x1a583e]));}_0x3b12f9[_0x9092d8('0x149f')]=_0x44843e;}else{if(!_0x4eeb44[_0x9092d8('0x1a2b')])return _0x2caada['userProfileResource']['get']({'sectionId':_0x4eeb44['id']})[_0x9092d8('0xa44')][_0x9092d8('0x1166')](function(_0x1cd846){const _0x523344=_0x9092d8,_0x8b1211=_0x2cfb05()['map'](_0x1cd846[_0x523344('0x269a')],function(_0x138dc2){const _0x582e94=_0x523344;return _0x2cfb05()[_0x582e94('0xc38')](_0x3b12f9['projects'],{'id':_0x138dc2[_0x582e94('0x24e8')]});});let _0x4410f0=null;_0x3b12f9['ivrCampaign']&&(_0x4410f0=_0x2cfb05()[_0x523344('0xc38')](_0x3b12f9['projects'],{'id':Number(_0x3b12f9['ivrCampaign'][_0x523344('0x28a9')])}));if(_0x4410f0&&!_0x2cfb05()['some'](_0x8b1211,['id',_0x4410f0['id']])){const _0x341ae0=_0x2cfb05()[_0x523344('0xc38')](_0x3b12f9[_0x523344('0x149f')],{'id':_0x4410f0['id']});_0x341ae0['canSelect']=![],_0x8b1211[_0x523344('0x1514')](_0x341ae0);}_0x3b12f9[_0x523344('0x149f')]=_0x8b1211;});}})[_0x202de8('0x1a80')](function(_0x18cc86){const _0x375aa8=_0x202de8;_0x2b8792[_0x375aa8('0xfc9')]({'title':_0x18cc86['status']?_0x375aa8('0x1e21')+_0x18cc86[_0x375aa8('0x52d')]+_0x375aa8('0x11e1')+_0x18cc86['statusText']:_0x375aa8('0x10f2'),'msg':_0x18cc86['data']?JSON[_0x375aa8('0xbac')](_0x18cc86['data']):_0x18cc86[_0x375aa8('0x1586')]()});}),_0x3c2ac1[_0x202de8('0x1ac6')](_0x202de8('0xa7c'))?_0x2caada[_0x202de8('0x277c')][_0x202de8('0xd83')]({'fields':_0x202de8('0x1776'),'sort':_0x202de8('0x4f0'),'IntervalId':_0x202de8('0x15d7')})[_0x202de8('0xa44')][_0x202de8('0x1166')](function(_0x425f9e){const _0x22e4cc=_0x202de8;_0x3b12f9[_0x22e4cc('0x277c')]=_0x425f9e[_0x22e4cc('0x269a')]||[];})[_0x202de8('0x1a80')](function(_0x4b3a87){const _0x2ddfce=_0x202de8;_0x2b8792[_0x2ddfce('0xfc9')]({'title':_0x4b3a87[_0x2ddfce('0x52d')]?'API:'+_0x4b3a87[_0x2ddfce('0x52d')]+_0x2ddfce('0x11e1')+_0x4b3a87['statusText']:'SYSTEM:GET_INTERVAL','msg':_0x4b3a87[_0x2ddfce('0x25f4')]?JSON[_0x2ddfce('0xbac')](_0x4b3a87['data']):_0x4b3a87['toString']()});}):_0x2caada[_0x202de8('0x277c')]['get']({'fields':_0x202de8('0x1776'),'sort':_0x202de8('0x4f0'),'IntervalId':_0x202de8('0x15d7')})[_0x202de8('0xa44')][_0x202de8('0x1166')](function(_0x255adf){const _0x1f557b=_0x202de8;_0x3b12f9[_0x1f557b('0x277c')]=_0x255adf['rows']||[];})[_0x202de8('0x1166')](function(){const _0x486d2a=_0x202de8;return _0x2caada[_0x486d2a('0x17aa')][_0x486d2a('0xd83')]({'userProfileId':_0x3b12f9[_0x486d2a('0x98')][_0x486d2a('0xb86')],'sectionId':0x3ec})['$promise'];})['then'](function(_0x5a0ca1){const _0x19462b=_0x202de8,_0x110646=_0x5a0ca1&&_0x5a0ca1[_0x19462b('0x269a')]?_0x5a0ca1[_0x19462b('0x269a')][0x0]:null;if(!_0x110646){const _0xf4da82=[];let _0xd3fc1a=null;_0x3b12f9[_0x19462b('0xedf')]&&(_0xd3fc1a=_0x2cfb05()['find'](_0x3b12f9[_0x19462b('0x277c')],{'id':Number(_0x3b12f9[_0x19462b('0xedf')][_0x19462b('0x186f')])}));for(let _0x44e0b9=0x0;_0x44e0b9<_0x3b12f9['interval'][_0x19462b('0x264b')];_0x44e0b9++){_0xd3fc1a&&_0x3b12f9[_0x19462b('0x277c')][_0x44e0b9]['id']===_0xd3fc1a['id']&&(_0x3b12f9[_0x19462b('0x277c')][_0x44e0b9][_0x19462b('0x2378')]=![],_0xf4da82[_0x19462b('0x1514')](_0x3b12f9[_0x19462b('0x277c')][_0x44e0b9]));}_0x3b12f9[_0x19462b('0x277c')]=_0xf4da82;}else{if(!_0x110646[_0x19462b('0x1a2b')])return _0x2caada[_0x19462b('0x4b5')][_0x19462b('0xd83')]({'sectionId':_0x110646['id']})[_0x19462b('0xa44')][_0x19462b('0x1166')](function(_0x3aa930){const _0x44f69f=_0x19462b,_0x6cafee=_0x2cfb05()[_0x44f69f('0x2563')](_0x3aa930['rows'],function(_0x121d04){const _0x5b7459=_0x44f69f;return _0x2cfb05()[_0x5b7459('0xc38')](_0x3b12f9[_0x5b7459('0x277c')],{'id':_0x121d04[_0x5b7459('0x24e8')]});});let _0x308293=null;_0x3b12f9[_0x44f69f('0xedf')]&&(_0x308293=_0x2cfb05()['find'](_0x3b12f9[_0x44f69f('0x277c')],{'id':Number(_0x3b12f9['ivrCampaign'][_0x44f69f('0x186f')])}));if(_0x308293&&!_0x2cfb05()[_0x44f69f('0x1798')](_0x6cafee,['id',_0x308293['id']])){const _0x5dc91d=_0x2cfb05()[_0x44f69f('0xc38')](_0x3b12f9[_0x44f69f('0x277c')],{'id':_0x308293['id']});_0x5dc91d[_0x44f69f('0x2378')]=![],_0x6cafee[_0x44f69f('0x1514')](_0x5dc91d);}_0x3b12f9['interval']=_0x6cafee;});}})[_0x202de8('0x1a80')](function(_0x15e2f9){const _0x43e152=_0x202de8;_0x2b8792[_0x43e152('0xfc9')]({'title':_0x15e2f9[_0x43e152('0x52d')]?_0x43e152('0x1e21')+_0x15e2f9[_0x43e152('0x52d')]+'\x20-\x20'+_0x15e2f9[_0x43e152('0xe1b')]:_0x43e152('0xe48'),'msg':_0x15e2f9[_0x43e152('0x25f4')]?JSON['stringify'](_0x15e2f9[_0x43e152('0x25f4')]):_0x15e2f9[_0x43e152('0x1586')]()});});function _0x114b37(_0x3430ff,_0x2441c6){const _0x4455f2=_0x202de8;_0x47835d['show']({'controller':_0x4455f2('0x1520'),'controllerAs':'vm','templateUrl':_0x2a1237,'parent':angular[_0x4455f2('0x1194')](_0xad6dd8['body']),'targetEvent':_0x2441c6,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x3430ff,'ivrCampaigns':_0x3b12f9[_0x4455f2('0x5b8')]?_0x3b12f9['ivrCampaigns'][_0x4455f2('0x269a')]:[],'crudPermissions':_0x3b12f9[_0x4455f2('0x243c')]}});}function _0x31e76a(_0x5750e7,_0x287f89){const _0x4b2097=_0x202de8;_0x47835d[_0x4b2097('0x1f80')]({'controller':_0x4b2097('0x2ae'),'controllerAs':'vm','templateUrl':_0x3c2cd5,'parent':angular['element'](_0xad6dd8[_0x4b2097('0x8d2')]),'targetEvent':_0x287f89,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x5750e7,'ivrCampaigns':_0x3b12f9[_0x4b2097('0x5b8')]?_0x3b12f9['ivrCampaigns'][_0x4b2097('0x269a')]:[],'crudPermissions':_0x3b12f9[_0x4b2097('0x243c')]}});}function _0x136898(_0x75458e,_0x34f07e){const _0x461764=_0x202de8;_0x47835d['show']({'controller':_0x461764('0x17d7'),'controllerAs':'vm','templateUrl':_0x11c6b5,'parent':angular[_0x461764('0x1194')](_0xad6dd8[_0x461764('0x8d2')]),'targetEvent':_0x34f07e,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x75458e,'ivrCampaigns':_0x3b12f9[_0x461764('0x5b8')]?_0x3b12f9[_0x461764('0x5b8')]['rows']:[],'crudPermissions':_0x3b12f9[_0x461764('0x243c')]}});}function _0x449805(_0x36da4c,_0x13c653){const _0x41c8a7=_0x202de8,_0x4f339e=_0x13c653['id'];_0x2caada[_0x41c8a7('0xb13')]['removeLists']({'id':_0x36da4c,'ids':_0x4f339e})['$promise']['then'](function(){const _0x3e261e=_0x41c8a7;return _0x2caada[_0x3e261e('0xb13')]['addLists']({'id':_0x36da4c,'ids':_0x4f339e,'dialCheckDuplicateType':'never'})['$promise'];})[_0x41c8a7('0x1166')](function(){const _0x1a140f=_0x41c8a7;_0x2b8792[_0x1a140f('0x103b')]({'title':'Reset\x20Succesfull','msg':'List\x20'+_0x13c653['name']+_0x1a140f('0x25e4')});})['catch'](function(_0x5a9c82){const _0x538606=_0x41c8a7;_0x2b8792[_0x538606('0xfc9')]({'title':_0x5a9c82['status']?_0x538606('0x1e21')+_0x5a9c82[_0x538606('0x52d')]+_0x538606('0x11e1')+_0x5a9c82[_0x538606('0xe1b')]:_0x538606('0x23b9'),'msg':_0x5a9c82[_0x538606('0x52d')]?JSON['stringify'](_0x5a9c82['data']):_0x5a9c82[_0x538606('0x1586')]()});});}function _0x2592eb(_0x58669d,_0x2a4feb){const _0x5a4602=_0x202de8;_0x2caada['campaign'][_0x5a4602('0x5a1')]({'id':_0x58669d['id'],'fields':_0x5a4602('0x1776'),'nolimit':!![]})[_0x5a4602('0xa44')][_0x5a4602('0x1166')](function(_0x5df3d9){const _0x5e6c71=_0x5a4602;if(_0x2cfb05()[_0x5e6c71('0x2863')](_0x5df3d9[_0x5e6c71('0x269a')])||_0x2cfb05()[_0x5e6c71('0x1081')](_0x5df3d9['rows']))_0x2b8792[_0x5e6c71('0x1fa1')]({'title':_0x5e6c71('0x26be')});else{if(_0x5df3d9[_0x5e6c71('0x269a')][_0x5e6c71('0x264b')]===0x1){const _0x468c1b=_0x47835d[_0x5e6c71('0x1d26')]()['title'](_0x5e6c71('0x12c4')+_0x5df3d9['rows'][0x0][_0x5e6c71('0x4f0')]+'\x20?')[_0x5e6c71('0xf3c')](_0x5e6c71('0x12b5')+_0x5df3d9[_0x5e6c71('0x269a')][0x0][_0x5e6c71('0x4f0')]+''+'\x20will\x20be\x20reset.')[_0x5e6c71('0x8e8')]('Reset\x20List')[_0x5e6c71('0x203b')](_0x2a4feb)['ok']('OK')[_0x5e6c71('0x3f')](_0x5e6c71('0x2d3'));_0x47835d[_0x5e6c71('0x1f80')](_0x468c1b)['then'](function(){const _0x6ba0f5=_0x5e6c71;_0x449805(_0x3b12f9['ivrCampaign']['id'],_0x5df3d9[_0x6ba0f5('0x269a')][0x0]);});}else _0x47835d[_0x5e6c71('0x1f80')]({'controller':'IvrCampaignresetlistController','controllerAs':'vm','templateUrl':_0x2975bb,'parent':angular[_0x5e6c71('0x1194')](_0xad6dd8[_0x5e6c71('0x8d2')]),'targetEvent':_0x2a4feb,'clickOutsideToClose':![],'locals':{'ivrCampaign':_0x58669d,'listsCampaign':_0x5df3d9?_0x5df3d9['rows']:[]}});}})[_0x5a4602('0x1a80')](function(_0x3db3f4){const _0x1857b9=_0x5a4602;_0x2b8792[_0x1857b9('0xfc9')]({'title':_0x3db3f4[_0x1857b9('0x52d')]?'API:'+_0x3db3f4[_0x1857b9('0x52d')]+_0x1857b9('0x11e1')+_0x3db3f4['statusText']:_0x1857b9('0x2ff'),'msg':_0x3db3f4[_0x1857b9('0x52d')]?JSON[_0x1857b9('0xbac')](_0x3db3f4[_0x1857b9('0x25f4')]):_0x3db3f4['toString']()});});}function _0x1cfc2f(){const _0x43e7a4=_0x202de8;if(_0x3c2ac1[_0x43e7a4('0x1ac6')]('admin'))_0x5375ab['go'](_0x43e7a4('0x2328'),{});else return _0x2caada[_0x43e7a4('0x17aa')][_0x43e7a4('0xd83')]({'userProfileId':_0x3c2ac1['getCurrentUser']()[_0x43e7a4('0xb86')],'sectionId':0x5e6})[_0x43e7a4('0xa44')]['then'](function(_0x1f61f4){const _0x4b2446=_0x43e7a4,_0x27a185=_0x1f61f4&&_0x1f61f4[_0x4b2446('0x269a')]?_0x1f61f4['rows'][0x0]:null;_0x27a185&&_0x27a185[_0x4b2446('0xc27')]?_0x5375ab['go'](_0x4b2446('0x2328'),{}):_0x2b8792[_0x4b2446('0x1fa1')]({'title':_0x10308c['instant'](_0x4b2446('0x627')),'msg':_0x10308c['instant'](_0x4b2446('0x2642'))});})[_0x43e7a4('0x1a80')](function(_0x2956f1){const _0x57e741=_0x43e7a4;_0x2b8792[_0x57e741('0xfc9')]({'title':_0x2956f1['status']?_0x57e741('0x1e21')+_0x2956f1[_0x57e741('0x52d')]+_0x57e741('0x11e1')+_0x2956f1[_0x57e741('0xe1b')]:_0x57e741('0x153e'),'msg':_0x2956f1[_0x57e741('0x52d')]?JSON[_0x57e741('0xbac')](_0x2956f1['data']):_0x2956f1[_0x57e741('0x1586')]()});});}function _0x49041d(){const _0x1aca93=_0x202de8;_0x5375ab['go'](_0x1aca93('0x100'),{},{'reload':_0x1aca93('0x100')});}function _0x75c767(){const _0x1e3322=_0x202de8;_0x2caada['campaign']['update']({'id':_0x3b12f9['ivrCampaign']['id']},_0x3b12f9[_0x1e3322('0xedf')])[_0x1e3322('0xa44')][_0x1e3322('0x1166')](function(){const _0x141b9f=_0x1e3322;_0x2b8792[_0x141b9f('0x103b')]({'title':_0x141b9f('0x22c2'),'msg':_0x3b12f9[_0x141b9f('0xedf')]['name']?_0x3b12f9['ivrCampaign'][_0x141b9f('0x4f0')]+_0x141b9f('0xa17'):''});})[_0x1e3322('0x1a80')](function(_0x1d2bd1){const _0x507d5a=_0x1e3322;_0x2b8792[_0x507d5a('0xfc9')]({'title':_0x1d2bd1[_0x507d5a('0x52d')]?_0x507d5a('0x1e21')+_0x1d2bd1[_0x507d5a('0x52d')]+_0x507d5a('0x11e1')+_0x1d2bd1[_0x507d5a('0xe1b')]:_0x507d5a('0x6d2'),'msg':_0x1d2bd1[_0x507d5a('0x25f4')]?JSON['stringify'](_0x1d2bd1[_0x507d5a('0x25f4')]):_0x1d2bd1[_0x507d5a('0x1586')]()});});}}const _0x4ab048=_0xb08194;_0x5cbcf8[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x5b8'),_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),'Auth','license','setting'];function _0x5cbcf8(_0x314226,_0x277adf,_0x21787a,_0x37b0fb,_0x443306,_0x377cd7,_0x1863aa,_0x33ebae,_0x1c8c90,_0x2a67e0,_0x2fa128,_0x3f2e0e,_0x27424d,_0x3ba557,_0x49e909,_0x3fbc72,_0x261997){const _0x43427f=_0x36e6f4,_0x55c16a=this;_0x55c16a[_0x43427f('0x5c9')]=_0x3fbc72,_0x55c16a[_0x43427f('0xf8a')]=_0x261997,_0x55c16a['currentUser']=_0x49e909[_0x43427f('0x26cd')](),_0x55c16a[_0x43427f('0x5b8')]=_0x1c8c90||{'count':0x0,'rows':[]},_0x55c16a[_0x43427f('0x7f')]=_0x2a67e0,_0x55c16a['userProfileSection']=_0x2fa128&&_0x2fa128[_0x43427f('0x240f')]==0x1?_0x2fa128['rows'][0x0]:null,_0x55c16a[_0x43427f('0x243c')]=_0x49e909[_0x43427f('0xd87')](_0x55c16a[_0x43427f('0x17aa')]?_0x55c16a['userProfileSection']['crudPermissions']:null),_0x55c16a['table']=_0x43427f('0x5b8'),_0x55c16a[_0x43427f('0xef5')]='',_0x55c16a[_0x43427f('0x104c')]=null,_0x55c16a[_0x43427f('0x3d0')]=[],_0x55c16a['query']={'fields':_0x43427f('0x2547'),'type':_0x43427f('0x681'),'sort':_0x43427f('0x14dc'),'limit':0xa,'page':0x1},_0x55c16a['arraydialCheckDuplicateType']=_0x2cfb05()[_0x43427f('0x155c')]([{'option':_0x43427f('0x1cff'),'value':'\x27always\x27'},{'option':'NEVER','value':_0x43427f('0x130c')},{'option':_0x43427f('0x284a'),'value':'\x27onlyIfOpen\x27'}],function(_0x2ebb68){const _0xe5c3b3=_0x43427f;return _0x2cfb05()[_0xe5c3b3('0xf3')](_0x2ebb68[_0xe5c3b3('0x18e0')],new RegExp('\x27','g'),'');}),_0x55c16a['arraydialOrderByScheduledAt']=_0x2cfb05()[_0x43427f('0x155c')]([{'option':_0x43427f('0x1e2b'),'value':_0x43427f('0x16fc')},{'option':_0x43427f('0x22d4'),'value':_0x43427f('0x139b')}],function(_0x27f775){const _0x537278=_0x43427f;return _0x2cfb05()[_0x537278('0xf3')](_0x27f775['value'],new RegExp('\x27','g'),'');}),_0x55c16a[_0x43427f('0x1ff6')]=_0x55beef,_0x55c16a['clonedialog']=_0x35c549,_0x55c16a[_0x43427f('0x2112')]=_0x4f9a0a,_0x55c16a[_0x43427f('0xe2b')]=_0x2262e7,_0x55c16a['deleteconfirm']=_0x6ead6c,_0x55c16a[_0x43427f('0x182d')]=_0x2cfa54,_0x55c16a['success']=_0x3bcb20,_0x55c16a['getIvrCampaigns']=_0x16ab57,_0x55c16a[_0x43427f('0x24ff')]=_0x118cfe,_0x55c16a[_0x43427f('0x1537')]=_0x2be1ba,_0x55c16a['exportSelectedIvrCampaigns']=_0x4c8486,_0x55c16a[_0x43427f('0x1c23')]=_0x4f17d9,_0x55c16a['deselectIvrCampaigns']=_0x3f50f8,_0x55c16a[_0x43427f('0x1309')]=_0x4d47ae,_0x49e909['hasRole'](_0x43427f('0xa7c'))?_0x3f2e0e[_0x43427f('0x3b2')][_0x43427f('0xd83')]({'fields':'id,name','sort':_0x43427f('0x4f0'),'table':'true'})[_0x43427f('0xa44')][_0x43427f('0x1166')](function(_0x3b438c){const _0xc10a08=_0x43427f;_0x55c16a[_0xc10a08('0xf24')]=_0x3b438c[_0xc10a08('0x269a')]||[];})[_0x43427f('0x1a80')](function(_0x5230ca){const _0x14c526=_0x43427f;_0x3ba557[_0x14c526('0xfc9')]({'title':_0x5230ca[_0x14c526('0x52d')]?_0x14c526('0x1e21')+_0x5230ca[_0x14c526('0x52d')]+_0x14c526('0x11e1')+_0x5230ca[_0x14c526('0xe1b')]:_0x14c526('0x12a6'),'msg':_0x5230ca['data']?JSON['stringify'](_0x5230ca[_0x14c526('0x25f4')]):_0x5230ca['toString']()});}):_0x3f2e0e[_0x43427f('0x3b2')][_0x43427f('0xd83')]({'fields':_0x43427f('0x1776'),'sort':_0x43427f('0x4f0'),'table':'true'})[_0x43427f('0xa44')][_0x43427f('0x1166')](function(_0x5c9ccb){const _0x592dac=_0x43427f;_0x55c16a[_0x592dac('0xf24')]=_0x5c9ccb[_0x592dac('0x269a')]||[];})[_0x43427f('0x1166')](function(){const _0x501ba1=_0x43427f;return _0x3f2e0e['userProfileSection'][_0x501ba1('0xd83')]({'userProfileId':_0x55c16a[_0x501ba1('0x98')][_0x501ba1('0xb86')],'sectionId':0x3f3})['$promise'];})['then'](function(_0x5e2656){const _0x2e1b45=_0x43427f,_0x54d72b=_0x5e2656&&_0x5e2656['rows']?_0x5e2656[_0x2e1b45('0x269a')][0x0]:null;if(!_0x54d72b)_0x55c16a[_0x2e1b45('0xf24')]=[];else{if(!_0x54d72b[_0x2e1b45('0x1a2b')])return _0x3f2e0e[_0x2e1b45('0x4b5')][_0x2e1b45('0xd83')]({'sectionId':_0x54d72b['id']})[_0x2e1b45('0xa44')]['then'](function(_0x2a9907){const _0x13fe15=_0x2e1b45,_0x507bf7=_0x2cfb05()['map'](_0x2a9907['rows'],function(_0x5a180e){const _0xf2bfc4=a0_0x3f2c;return _0x2cfb05()[_0xf2bfc4('0xc38')](_0x55c16a['trunks'],{'id':_0x5a180e['resourceId']});});_0x55c16a[_0x13fe15('0xf24')][_0x13fe15('0x2782')](function(_0x1256c9){const _0x24de82=_0x13fe15;!_0x2cfb05()[_0x24de82('0x1798')](_0x507bf7,['id',_0x1256c9['id']])&&(_0x1256c9[_0x24de82('0x2378')]=![]),_0x507bf7[_0x24de82('0x1514')](_0x1256c9);}),_0x55c16a[_0x13fe15('0xf24')]=_0x507bf7;});}})['catch'](function(_0x42b462){const _0x11dbe5=_0x43427f;_0x3ba557[_0x11dbe5('0xfc9')]({'title':_0x42b462[_0x11dbe5('0x52d')]?'API:'+_0x42b462[_0x11dbe5('0x52d')]+'\x20-\x20'+_0x42b462[_0x11dbe5('0xe1b')]:_0x11dbe5('0x1d44'),'msg':_0x42b462[_0x11dbe5('0x25f4')]?JSON[_0x11dbe5('0xbac')](_0x42b462[_0x11dbe5('0x25f4')]):_0x42b462[_0x11dbe5('0x1586')]()});}),_0x49e909[_0x43427f('0x1ac6')](_0x43427f('0xa7c'))?_0x3f2e0e['squareProject'][_0x43427f('0xd83')]({'fields':_0x43427f('0x1776'),'sort':_0x43427f('0x4f0')})[_0x43427f('0xa44')][_0x43427f('0x1166')](function(_0x15aeda){const _0x4ef03b=_0x43427f;_0x55c16a[_0x4ef03b('0x149f')]=_0x15aeda[_0x4ef03b('0x269a')]||[];})[_0x43427f('0x1a80')](function(_0x8b09a5){const _0x24b981=_0x43427f;_0x3ba557[_0x24b981('0xfc9')]({'title':_0x8b09a5[_0x24b981('0x52d')]?_0x24b981('0x1e21')+_0x8b09a5['status']+_0x24b981('0x11e1')+_0x8b09a5['statusText']:_0x24b981('0x178b'),'msg':_0x8b09a5[_0x24b981('0x25f4')]?JSON[_0x24b981('0xbac')](_0x8b09a5[_0x24b981('0x25f4')]):_0x8b09a5['toString']()});}):_0x3f2e0e[_0x43427f('0x7e4')][_0x43427f('0xd83')]({'fields':_0x43427f('0x1776'),'sort':'name'})['$promise'][_0x43427f('0x1166')](function(_0x28a3ce){const _0xf86fa5=_0x43427f;_0x55c16a['projects']=_0x28a3ce[_0xf86fa5('0x269a')]||[];})[_0x43427f('0x1166')](function(){const _0x2f419a=_0x43427f;return _0x3f2e0e[_0x2f419a('0x17aa')][_0x2f419a('0xd83')]({'userProfileId':_0x55c16a[_0x2f419a('0x98')][_0x2f419a('0xb86')],'sectionId':0x44f})[_0x2f419a('0xa44')];})[_0x43427f('0x1166')](function(_0x26e085){const _0x3d11c6=_0x43427f,_0x3add3a=_0x26e085&&_0x26e085['rows']?_0x26e085['rows'][0x0]:null;if(!_0x3add3a){const _0x33eb93=[],_0x2b3862=[];_0x55c16a['ivrCampaigns'][_0x3d11c6('0x269a')][_0x3d11c6('0x2782')](function(_0x29424c){const _0x4bb4c5=_0x3d11c6,_0x1d181e=_0x2cfb05()[_0x4bb4c5('0xc38')](_0x55c16a[_0x4bb4c5('0x149f')],{'id':Number(_0x29424c['SquareProjectId'])});_0x2b3862[_0x4bb4c5('0x1514')](_0x1d181e);});for(let _0x2bc835=0x0;_0x2bc835<_0x55c16a[_0x3d11c6('0x149f')][_0x3d11c6('0x264b')];_0x2bc835++){const _0x5b9af7=_0x2cfb05()['some'](_0x2b3862,{'id':_0x55c16a[_0x3d11c6('0x149f')][_0x2bc835]['id']});_0x5b9af7&&(_0x55c16a[_0x3d11c6('0x149f')][_0x2bc835][_0x3d11c6('0x2378')]=![],_0x33eb93['push'](_0x55c16a[_0x3d11c6('0x149f')][_0x2bc835]));}_0x55c16a[_0x3d11c6('0x149f')]=_0x33eb93;}else{if(!_0x3add3a[_0x3d11c6('0x1a2b')])return _0x3f2e0e[_0x3d11c6('0x4b5')]['get']({'sectionId':_0x3add3a['id']})['$promise'][_0x3d11c6('0x1166')](function(_0x1b8edd){const _0x56cfff=_0x3d11c6,_0x4a0dc3=_0x2cfb05()['map'](_0x1b8edd['rows'],function(_0x2e9d67){const _0x5a24c7=a0_0x3f2c;return _0x2cfb05()['find'](_0x55c16a['projects'],{'id':_0x2e9d67[_0x5a24c7('0x24e8')]});});let _0x1d9379=null;_0x1d9379=[],_0x55c16a[_0x56cfff('0x5b8')][_0x56cfff('0x269a')][_0x56cfff('0x2782')](function(_0x43463e){const _0x3f2083=_0x56cfff,_0x547f38=_0x2cfb05()[_0x3f2083('0xc38')](_0x55c16a['projects'],{'id':Number(_0x43463e['SquareProjectId'])});_0x1d9379[_0x3f2083('0x1514')](_0x547f38);}),!_0x2cfb05()['isEmpty'](_0x1d9379)&&_0x1d9379[_0x56cfff('0x2782')](function(_0x3d4aa6){const _0x3c3d03=_0x56cfff;if(!_0x2cfb05()[_0x3c3d03('0x1798')](_0x4a0dc3,['id',_0x3d4aa6['id']])){const _0x5b1e78=_0x2cfb05()[_0x3c3d03('0xc38')](_0x55c16a[_0x3c3d03('0x149f')],{'id':_0x3d4aa6['id']});_0x5b1e78['canSelect']=![],_0x4a0dc3[_0x3c3d03('0x1514')](_0x5b1e78);}}),_0x55c16a[_0x56cfff('0x149f')]=_0x4a0dc3;});}})['catch'](function(_0x5cc699){const _0x25b92e=_0x43427f;_0x3ba557[_0x25b92e('0xfc9')]({'title':_0x5cc699[_0x25b92e('0x52d')]?_0x25b92e('0x1e21')+_0x5cc699[_0x25b92e('0x52d')]+'\x20-\x20'+_0x5cc699[_0x25b92e('0xe1b')]:_0x25b92e('0x10f2'),'msg':_0x5cc699[_0x25b92e('0x25f4')]?JSON['stringify'](_0x5cc699['data']):_0x5cc699[_0x25b92e('0x1586')]()});}),_0x49e909[_0x43427f('0x1ac6')](_0x43427f('0xa7c'))?_0x3f2e0e[_0x43427f('0x277c')][_0x43427f('0xd83')]({'fields':_0x43427f('0x1776'),'sort':'name','IntervalId':_0x43427f('0x15d7')})['$promise'][_0x43427f('0x1166')](function(_0x3055bf){const _0x5b0fa6=_0x43427f;_0x55c16a[_0x5b0fa6('0x277c')]=_0x3055bf['rows']||[];})[_0x43427f('0x1a80')](function(_0x14b95d){const _0x52543a=_0x43427f;_0x3ba557[_0x52543a('0xfc9')]({'title':_0x14b95d[_0x52543a('0x52d')]?_0x52543a('0x1e21')+_0x14b95d[_0x52543a('0x52d')]+_0x52543a('0x11e1')+_0x14b95d[_0x52543a('0xe1b')]:'SYSTEM:GET_INTERVAL','msg':_0x14b95d[_0x52543a('0x25f4')]?JSON[_0x52543a('0xbac')](_0x14b95d[_0x52543a('0x25f4')]):_0x14b95d[_0x52543a('0x1586')]()});}):_0x3f2e0e[_0x43427f('0x277c')]['get']({'fields':'id,name','sort':_0x43427f('0x4f0'),'IntervalId':_0x43427f('0x15d7')})['$promise']['then'](function(_0x60bdc0){const _0x1d0d73=_0x43427f;_0x55c16a['interval']=_0x60bdc0[_0x1d0d73('0x269a')]||[];})[_0x43427f('0x1166')](function(){const _0x4364e2=_0x43427f;return _0x3f2e0e[_0x4364e2('0x17aa')][_0x4364e2('0xd83')]({'userProfileId':_0x55c16a['currentUser']['userProfileId'],'sectionId':0x3ec})[_0x4364e2('0xa44')];})[_0x43427f('0x1166')](function(_0x2a39c8){const _0x52082a=_0x43427f,_0x4d0256=_0x2a39c8&&_0x2a39c8[_0x52082a('0x269a')]?_0x2a39c8[_0x52082a('0x269a')][0x0]:null;if(!_0x4d0256){const _0x86e954=[];let _0x4bfdf7=null;_0x55c16a[_0x52082a('0xedf')]&&(_0x4bfdf7=_0x2cfb05()[_0x52082a('0xc38')](_0x55c16a['interval'],{'id':Number(_0x55c16a['ivrCampaign']['IntervalId'])}));for(let _0x33c06b=0x0;_0x33c06b<_0x55c16a[_0x52082a('0x277c')][_0x52082a('0x264b')];_0x33c06b++){_0x4bfdf7&&_0x55c16a[_0x52082a('0x277c')][_0x33c06b]['id']===_0x4bfdf7['id']&&(_0x55c16a['interval'][_0x33c06b][_0x52082a('0x2378')]=![],_0x86e954['push'](_0x55c16a[_0x52082a('0x277c')][_0x33c06b]));}_0x55c16a[_0x52082a('0x277c')]=_0x86e954;}else{if(!_0x4d0256[_0x52082a('0x1a2b')])return _0x3f2e0e[_0x52082a('0x4b5')][_0x52082a('0xd83')]({'sectionId':_0x4d0256['id']})[_0x52082a('0xa44')][_0x52082a('0x1166')](function(_0x22e0ac){const _0x1c3108=_0x52082a,_0x5cb525=_0x2cfb05()[_0x1c3108('0x2563')](_0x22e0ac[_0x1c3108('0x269a')],function(_0x5f4fa4){const _0x9cd17d=_0x1c3108;return _0x2cfb05()[_0x9cd17d('0xc38')](_0x55c16a[_0x9cd17d('0x277c')],{'id':_0x5f4fa4[_0x9cd17d('0x24e8')]});});let _0x357f11=null;_0x55c16a[_0x1c3108('0xedf')]&&(_0x357f11=_0x2cfb05()[_0x1c3108('0xc38')](_0x55c16a['interval'],{'id':Number(_0x55c16a[_0x1c3108('0xedf')]['IntervalId'])}));if(_0x357f11&&!_0x2cfb05()[_0x1c3108('0x1798')](_0x5cb525,['id',_0x357f11['id']])){const _0x3c38e1=_0x2cfb05()[_0x1c3108('0xc38')](_0x55c16a[_0x1c3108('0x277c')],{'id':_0x357f11['id']});_0x3c38e1[_0x1c3108('0x2378')]=![],_0x5cb525[_0x1c3108('0x1514')](_0x3c38e1);}_0x55c16a[_0x1c3108('0x277c')]=_0x5cb525;});}})[_0x43427f('0x1a80')](function(_0x2bbbde){const _0x4dfd46=_0x43427f;_0x3ba557[_0x4dfd46('0xfc9')]({'title':_0x2bbbde[_0x4dfd46('0x52d')]?_0x4dfd46('0x1e21')+_0x2bbbde[_0x4dfd46('0x52d')]+_0x4dfd46('0x11e1')+_0x2bbbde['statusText']:_0x4dfd46('0xe48'),'msg':_0x2bbbde[_0x4dfd46('0x25f4')]?JSON[_0x4dfd46('0xbac')](_0x2bbbde['data']):_0x2bbbde['toString']()});});function _0x55beef(_0x3e7b58){const _0x56e64a=_0x43427f;_0x21787a['go']('app.motiondialer.ivrCampaigns.edit',{'id':_0x3e7b58['id'],'ivrCampaign':_0x3e7b58,'crudPermissions':_0x55c16a[_0x56e64a('0x243c')]});}function _0x35c549(_0x297cdf,_0x2ef258){const _0x4e530f=_0x43427f;_0x443306[_0x4e530f('0x1f80')]({'controller':'IvrCampaigncloneController','controllerAs':'vm','templateUrl':_0x2a1237,'parent':angular[_0x4e530f('0x1194')](_0x377cd7[_0x4e530f('0x8d2')]),'targetEvent':_0x2ef258,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x297cdf,'ivrCampaigns':_0x55c16a[_0x4e530f('0x5b8')]?_0x55c16a[_0x4e530f('0x5b8')][_0x4e530f('0x269a')]:[],'crudPermissions':_0x55c16a[_0x4e530f('0x243c')]}});}function _0x4f9a0a(_0xbfa260,_0x391add){const _0x121d8a=_0x43427f;_0x443306['show']({'controller':_0x121d8a('0x2ae'),'controllerAs':'vm','templateUrl':_0x3c2cd5,'parent':angular[_0x121d8a('0x1194')](_0x377cd7['body']),'targetEvent':_0x391add,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0xbfa260,'ivrCampaigns':_0x55c16a[_0x121d8a('0x5b8')]?_0x55c16a[_0x121d8a('0x5b8')][_0x121d8a('0x269a')]:[],'crudPermissions':_0x55c16a['crudPermissions']}});}function _0x2262e7(_0x4bd05a,_0x5cb73c){const _0x54775f=_0x43427f;_0x443306[_0x54775f('0x1f80')]({'controller':'IvrCampaignblacklistaddController','controllerAs':'vm','templateUrl':_0x11c6b5,'parent':angular[_0x54775f('0x1194')](_0x377cd7['body']),'targetEvent':_0x5cb73c,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x4bd05a,'ivrCampaigns':_0x55c16a[_0x54775f('0x5b8')]?_0x55c16a['ivrCampaigns'][_0x54775f('0x269a')]:[],'crudPermissions':_0x55c16a['crudPermissions']}});}function _0x6ead6c(_0x49a455,_0x1c6c44){const _0x33b156=_0x43427f,_0x46e744=_0x443306[_0x33b156('0x1d26')]()[_0x33b156('0xcdc')](_0x33b156('0x288d')+_0x2cfb05()[_0x33b156('0xb35')](_0x33b156('0xedf'))+'?')[_0x33b156('0xf3c')](_0x33b156('0x12b5')+(_0x49a455['name']||_0x33b156('0xedf'))+_0x33b156('0xace')+_0x33b156('0x3f3'))[_0x33b156('0x8e8')](_0x33b156('0x4ba'))[_0x33b156('0x203b')](_0x1c6c44)['ok']('OK')['cancel'](_0x33b156('0x2d3'));_0x443306[_0x33b156('0x1f80')](_0x46e744)[_0x33b156('0x1166')](function(){_0x2be1ba(_0x49a455);},function(){const _0x32e8eb=_0x33b156;console[_0x32e8eb('0x455')](_0x32e8eb('0x2d3'));});}function _0x2cfa54(){const _0x34508f=_0x43427f;if(_0x49e909['hasRole'](_0x34508f('0xa7c')))_0x21787a['go']('app.motiondialer.realtime.ivr_campaigns',{});else return _0x3f2e0e['userProfileSection'][_0x34508f('0xd83')]({'userProfileId':_0x49e909[_0x34508f('0x26cd')]()[_0x34508f('0xb86')],'sectionId':0x5e6})[_0x34508f('0xa44')][_0x34508f('0x1166')](function(_0x1898d0){const _0x412727=_0x34508f,_0x331434=_0x1898d0&&_0x1898d0[_0x412727('0x269a')]?_0x1898d0[_0x412727('0x269a')][0x0]:null;_0x331434&&_0x331434[_0x412727('0xc27')]?_0x21787a['go']('app.motiondialer.realtime.ivr_campaigns',{}):_0x3ba557['info']({'title':_0x33ebae[_0x412727('0x25cc')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x33ebae[_0x412727('0x25cc')](_0x412727('0x2642'))});})[_0x34508f('0x1a80')](function(_0x11c334){const _0x5b4461=_0x34508f;_0x3ba557[_0x5b4461('0xfc9')]({'title':_0x11c334[_0x5b4461('0x52d')]?_0x5b4461('0x1e21')+_0x11c334['status']+_0x5b4461('0x11e1')+_0x11c334['statusText']:'USERPROFILE:GET_SECTION','msg':_0x11c334[_0x5b4461('0x52d')]?JSON[_0x5b4461('0xbac')](_0x11c334[_0x5b4461('0x25f4')]):_0x11c334[_0x5b4461('0x1586')]()});});}let _0x3b8c86=!![],_0x17ea46=0x1;_0x314226[_0x43427f('0xe83')](_0x43427f('0x12d8'),function(_0x366733,_0x28bb4f){const _0x9ea4a0=_0x43427f;_0x3b8c86?_0x1863aa(function(){_0x3b8c86=![];}):(!_0x28bb4f&&(_0x17ea46=_0x55c16a[_0x9ea4a0('0x2218')]['page']),_0x366733!==_0x28bb4f&&(_0x55c16a[_0x9ea4a0('0x2218')][_0x9ea4a0('0x1a43')]=0x1),!_0x366733&&(_0x55c16a[_0x9ea4a0('0x2218')][_0x9ea4a0('0x1a43')]=_0x17ea46),_0x55c16a[_0x9ea4a0('0x1c3c')]());});function _0x3bcb20(_0xb98daf){const _0x248606=_0x43427f;_0x55c16a[_0x248606('0x5b8')]=_0xb98daf||{'count':0x0,'rows':[]};}function _0x16ab57(){const _0x539be2=_0x43427f;_0x55c16a[_0x539be2('0x2218')][_0x539be2('0x1098')]=(_0x55c16a[_0x539be2('0x2218')]['page']-0x1)*_0x55c16a[_0x539be2('0x2218')][_0x539be2('0x163f')],_0x49e909[_0x539be2('0x1ac6')]('admin')?_0x55c16a['promise']=_0x3f2e0e[_0x539be2('0xb13')][_0x539be2('0xd83')](_0x55c16a[_0x539be2('0x2218')],_0x3bcb20)['$promise']:(_0x55c16a[_0x539be2('0x2218')]['id']=_0x55c16a[_0x539be2('0x7f')]['id'],_0x55c16a['query'][_0x539be2('0xe60')]='IvrCampaigns',_0x55c16a[_0x539be2('0x1f48')]=_0x3f2e0e[_0x539be2('0x7f')][_0x539be2('0x263a')](_0x55c16a['query'],_0x3bcb20)['$promise']);}function _0x118cfe(_0xc2f726,_0x71eb5a){const _0x5b6b6c=_0x43427f;_0x443306[_0x5b6b6c('0x1f80')]({'controller':_0x5b6b6c('0xb5f'),'controllerAs':'vm','templateUrl':_0x438cf9,'parent':angular['element'](_0x377cd7[_0x5b6b6c('0x8d2')]),'targetEvent':_0xc2f726,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x71eb5a,'ivrCampaigns':_0x55c16a[_0x5b6b6c('0x5b8')][_0x5b6b6c('0x269a')],'license':_0x55c16a[_0x5b6b6c('0x5c9')],'setting':_0x55c16a[_0x5b6b6c('0xf8a')],'crudPermissions':_0x55c16a[_0x5b6b6c('0x243c')]}});}function _0x2be1ba(_0x38042c){const _0x156370=_0x43427f;_0x3f2e0e[_0x156370('0xb13')]['delete']({'id':_0x38042c['id']})[_0x156370('0xa44')][_0x156370('0x1166')](function(){const _0x2b7f45=_0x156370;_0x2cfb05()['remove'](_0x55c16a['ivrCampaigns'][_0x2b7f45('0x269a')],{'id':_0x38042c['id']}),_0x55c16a['ivrCampaigns']['count']-=0x1,!_0x55c16a[_0x2b7f45('0x5b8')][_0x2b7f45('0x269a')][_0x2b7f45('0x264b')]&&_0x55c16a['getIvrCampaigns'](),_0x3ba557[_0x2b7f45('0x103b')]({'title':_0x2cfb05()[_0x2b7f45('0xb35')](_0x2b7f45('0x21d4'))+_0x2b7f45('0x2b6'),'msg':_0x38042c[_0x2b7f45('0x4f0')]?_0x38042c[_0x2b7f45('0x4f0')]+_0x2b7f45('0x7cd'):''});})[_0x156370('0x1a80')](function(_0x2ee2f2){const _0x4bc63f=_0x156370;if(_0x2ee2f2[_0x4bc63f('0x25f4')]&&_0x2ee2f2[_0x4bc63f('0x25f4')][_0x4bc63f('0x61a')]&&_0x2ee2f2[_0x4bc63f('0x25f4')][_0x4bc63f('0x61a')][_0x4bc63f('0x264b')]){_0x55c16a[_0x4bc63f('0x61a')]=_0x2ee2f2[_0x4bc63f('0x25f4')][_0x4bc63f('0x61a')]||[{'message':_0x2ee2f2[_0x4bc63f('0x1586')](),'type':_0x4bc63f('0x19fb')}];for(let _0x219969=0x0;_0x219969<_0x2ee2f2[_0x4bc63f('0x25f4')][_0x4bc63f('0x61a')][_0x4bc63f('0x264b')];_0x219969++){_0x3ba557[_0x4bc63f('0xfc9')]({'title':_0x2ee2f2[_0x4bc63f('0x25f4')][_0x4bc63f('0x61a')][_0x219969][_0x4bc63f('0x1345')],'msg':_0x2ee2f2[_0x4bc63f('0x25f4')]['errors'][_0x219969][_0x4bc63f('0x1e70')]});}}else _0x3ba557[_0x4bc63f('0xfc9')]({'title':_0x2ee2f2[_0x4bc63f('0x52d')]?'API:'+_0x2ee2f2[_0x4bc63f('0x52d')]+_0x4bc63f('0x11e1')+_0x2ee2f2['statusText']:_0x4bc63f('0x19fb'),'msg':_0x2ee2f2[_0x4bc63f('0x25f4')]?JSON[_0x4bc63f('0xbac')](_0x2ee2f2[_0x4bc63f('0x25f4')][_0x4bc63f('0x1e70')]):_0x2ee2f2[_0x4bc63f('0x1e70')]||_0x2ee2f2[_0x4bc63f('0x1586')]()});});}function _0x4c8486(){const _0x8f96dd=_0x43427f,_0x47c9fb=angular[_0x8f96dd('0x225f')](_0x55c16a[_0x8f96dd('0x3d0')]);return _0x55c16a[_0x8f96dd('0x3d0')]=[],_0x47c9fb;}function _0x4f17d9(_0x305265){const _0x4a8ce9=_0x43427f,_0x3ad07c=_0x443306[_0x4a8ce9('0x1d26')]()['title'](_0x4a8ce9('0x8e1'))[_0x4a8ce9('0xf3c')](_0x4a8ce9('0x12b5')+_0x55c16a[_0x4a8ce9('0x3d0')]['length']+_0x4a8ce9('0x196d')+_0x4a8ce9('0x3f3'))[_0x4a8ce9('0x8e8')](_0x4a8ce9('0x87b'))['targetEvent'](_0x305265)['ok']('OK')['cancel'](_0x4a8ce9('0x2d3'));_0x443306[_0x4a8ce9('0x1f80')](_0x3ad07c)[_0x4a8ce9('0x1166')](function(){const _0xee86ee=_0x4a8ce9;_0x55c16a[_0xee86ee('0x3d0')][_0xee86ee('0x2782')](function(_0x142a22){_0x2be1ba(_0x142a22);}),_0x55c16a[_0xee86ee('0x3d0')]=[];});}function _0x3f50f8(){const _0x3daf6e=_0x43427f;_0x55c16a[_0x3daf6e('0x3d0')]=[];}function _0x4d47ae(){const _0x470539=_0x43427f;_0x55c16a[_0x470539('0x3d0')]=_0x55c16a['ivrCampaigns'][_0x470539('0x269a')];}}const _0xa07ebf=_0x5cbcf8;_0x5de11d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x182c'),'queueCampaign',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license','setting',_0x36e6f4('0x243c')];function _0x5de11d(_0x547a16,_0x5c0207,_0x1ab37b,_0x4bafa0,_0x1c211a,_0x426246,_0x12f48e,_0x4ef901,_0x493836,_0x4b95fd,_0x532f3d,_0x11b6e8,_0x1d4ded,_0x21708b){const _0x13b736=_0x36e6f4,_0x5e4cf0=this;_0x5e4cf0[_0x13b736('0x98')]=_0x532f3d[_0x13b736('0x26cd')](),_0x5e4cf0[_0x13b736('0x61a')]=[],_0x5e4cf0['setting']=_0x1d4ded,_0x5e4cf0[_0x13b736('0x5c9')]=_0x11b6e8,_0x5e4cf0[_0x13b736('0x243c')]=_0x21708b,_0x5e4cf0['hasModulePermissions']={},_0x5e4cf0[_0x13b736('0x2900')]=_0x5e4cf0[_0x13b736('0xf8a')]&&_0x5e4cf0['setting'][_0x13b736('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5e4cf0[_0x13b736('0xcdc')]=_0x13b736('0x28d9'),_0x5e4cf0[_0x13b736('0x1915')]=angular[_0x13b736('0x225f')](_0x493836),_0x5e4cf0[_0x13b736('0x182c')]=_0x4ef901,_0x5e4cf0[_0x13b736('0x1dd1')]=![];!_0x5e4cf0[_0x13b736('0x1915')]&&(_0x5e4cf0['queueCampaign']={'dialActive':!![],'type':'outbound','dialCheckDuplicateType':_0x13b736('0x597'),'dialCutDigit':0x0,'autopause':'no','ringinuse':'no','timeoutrestart':'no','setinterfacevar':'no','setqueuevar':'no','setqueueentryvar':'no','dialOrderByScheduledAt':_0x13b736('0x22d4'),'dialGlobalInterval':'07:00-22:00,*,*,*','dialAMDInitialSilence':0x9c4,'dialAMDGreeting':0x5dc,'dialAMDAfterGreetingSilence':0x320,'dialAMDTotalAnalysisTime':0x1388,'dialAMDMinWordLength':0x64,'dialAMDBetweenWordsSilence':0x32,'dialAMDMaximumNumberOfWords':0x3,'dialAMDSilenceThreshold':0x100,'dialAMDMaximumWordLength':0x1388,'dialMethod':_0x13b736('0x2211'),'dialPowerLevel':0x1,'dialPredictiveOptimization':_0x13b736('0x1546'),'dialPredictiveOptimizationPercentage':0x3,'dialPredictiveInterval':0xa,'dialLimitQueue':0x0,'dialRandomLastDigitCallerIdNumber':0x0,'dialOriginateTimeout':0x1e,'dialQueueOptions':_0x13b736('0x1b94'),'dialQueueTimeout':0x3,'strategy':_0x13b736('0xa1b'),'timeout':0x3,'retry':0x3,'weight':0x1,'dialGlobalMaxRetry':0x4,'dialCongestionMaxRetry':0x3,'dialCongestionRetryFrequency':0x96,'dialBusyMaxRetry':0x3,'dialBusyRetryFrequency':0x96,'dialNoAnswerMaxRetry':0x3,'dialNoAnswerRetryFrequency':0x96,'dialNoSuchNumberMaxRetry':0x3,'dialNoSuchNumberRetryFrequency':0x96,'dialDropMaxRetry':0x3,'dialDropRetryFrequency':0x96,'dialAbandonedMaxRetry':0x3,'dialAbandonedRetryFrequency':0x96,'dialMachineMaxRetry':0x3,'dialMachineRetryFrequency':0x96,'dialAgentRejectMaxRetry':0x3,'dialAgentRejectRetryFrequency':0x96,'dialPredictiveIntervalMaxThreshold':0x14,'dialPredictiveIntervalMinThreshold':0xa},_0x5e4cf0[_0x13b736('0xcdc')]=_0x13b736('0x158b'),_0x5e4cf0[_0x13b736('0x1dd1')]=!![]);_0x5e4cf0['addNewQueueCampaign']=_0x3b7ce4,_0x5e4cf0['saveQueueCampaign']=_0x110610,_0x5e4cf0[_0x13b736('0x1f26')]=_0x2e5e69,_0x5e4cf0['getDateFromString']=_0x325a60,_0x5e4cf0[_0x13b736('0x24a0')]=_0x34f421,_0x532f3d['hasRole'](_0x13b736('0xa7c'))?_0x4b95fd[_0x13b736('0x3b2')][_0x13b736('0xd83')]({'fields':_0x13b736('0x1776'),'sort':_0x13b736('0x4f0')})[_0x13b736('0xa44')][_0x13b736('0x1166')](function(_0x2c534c){const _0x37a425=_0x13b736;_0x5e4cf0[_0x37a425('0xf24')]=_0x2c534c[_0x37a425('0x269a')]||[];})[_0x13b736('0x1a80')](function(_0x51cfb9){const _0x2b7892=_0x13b736;_0x12f48e['error']({'title':_0x51cfb9['status']?_0x2b7892('0x1e21')+_0x51cfb9[_0x2b7892('0x52d')]+_0x2b7892('0x11e1')+_0x51cfb9[_0x2b7892('0xe1b')]:_0x2b7892('0x12a6'),'msg':_0x51cfb9[_0x2b7892('0x25f4')]?JSON[_0x2b7892('0xbac')](_0x51cfb9['data']):_0x51cfb9['toString']()});}):_0x4b95fd[_0x13b736('0x3b2')][_0x13b736('0xd83')]({'fields':_0x13b736('0x1776'),'sort':_0x13b736('0x4f0')})[_0x13b736('0xa44')][_0x13b736('0x1166')](function(_0x510a8a){const _0xc896b2=_0x13b736;_0x5e4cf0[_0xc896b2('0xf24')]=_0x510a8a['rows']||[];})[_0x13b736('0x1166')](function(){const _0x2aaa70=_0x13b736;return _0x4b95fd['userProfileSection'][_0x2aaa70('0xd83')]({'userProfileId':_0x5e4cf0[_0x2aaa70('0x98')][_0x2aaa70('0xb86')],'sectionId':0x3f3})[_0x2aaa70('0xa44')];})[_0x13b736('0x1166')](function(_0xfa1f7f){const _0x22470e=_0x13b736,_0x33b8b6=_0xfa1f7f&&_0xfa1f7f[_0x22470e('0x269a')]?_0xfa1f7f[_0x22470e('0x269a')][0x0]:null;if(!_0x33b8b6){const _0x341e11=[];let _0x3cb7ae=null;_0x5e4cf0['queueCampaign']&&(_0x3cb7ae=_0x2cfb05()[_0x22470e('0xc38')](_0x5e4cf0[_0x22470e('0xf24')],{'id':Number(_0x5e4cf0[_0x22470e('0x1915')][_0x22470e('0x1ce4')])}));for(let _0x1a80c4=0x0;_0x1a80c4<_0x5e4cf0[_0x22470e('0xf24')]['length'];_0x1a80c4++){_0x3cb7ae&&_0x5e4cf0[_0x22470e('0xf24')][_0x1a80c4]['id']===_0x3cb7ae['id']&&(_0x5e4cf0[_0x22470e('0xf24')][_0x1a80c4]['canSelect']=![],_0x341e11['push'](_0x5e4cf0[_0x22470e('0xf24')][_0x1a80c4]));}_0x5e4cf0['trunks']=_0x341e11;}else{if(!_0x33b8b6[_0x22470e('0x1a2b')])return _0x4b95fd[_0x22470e('0x4b5')]['get']({'sectionId':_0x33b8b6['id']})[_0x22470e('0xa44')][_0x22470e('0x1166')](function(_0x111a22){const _0x3596b1=_0x22470e,_0x5504f2=_0x2cfb05()[_0x3596b1('0x2563')](_0x111a22[_0x3596b1('0x269a')],function(_0x32df2a){const _0x559d30=_0x3596b1;return _0x2cfb05()['find'](_0x5e4cf0[_0x559d30('0xf24')],{'id':_0x32df2a[_0x559d30('0x24e8')]});});let _0x12d458=null;_0x5e4cf0[_0x3596b1('0x1915')]&&(_0x12d458=_0x2cfb05()[_0x3596b1('0xc38')](_0x5e4cf0[_0x3596b1('0xf24')],{'id':Number(_0x5e4cf0[_0x3596b1('0x1915')][_0x3596b1('0x1ce4')])}));if(_0x12d458&&!_0x2cfb05()[_0x3596b1('0x1798')](_0x5504f2,['id',_0x12d458['id']])){const _0x338170=_0x2cfb05()['find'](_0x5e4cf0[_0x3596b1('0xf24')],{'id':_0x12d458['id']});_0x338170[_0x3596b1('0x2378')]=![],_0x5504f2[_0x3596b1('0x1514')](_0x338170);}_0x5e4cf0[_0x3596b1('0xf24')]=_0x5504f2;});}})[_0x13b736('0x1a80')](function(_0x2b669a){const _0xabf271=_0x13b736;_0x12f48e['error']({'title':_0x2b669a[_0xabf271('0x52d')]?_0xabf271('0x1e21')+_0x2b669a[_0xabf271('0x52d')]+_0xabf271('0x11e1')+_0x2b669a[_0xabf271('0xe1b')]:_0xabf271('0x1d44'),'msg':_0x2b669a[_0xabf271('0x25f4')]?JSON[_0xabf271('0xbac')](_0x2b669a['data']):_0x2b669a[_0xabf271('0x1586')]()});}),_0x532f3d[_0x13b736('0x1ac6')](_0x13b736('0xa7c'))?_0x4b95fd[_0x13b736('0x277c')][_0x13b736('0xd83')]({'fields':_0x13b736('0x1776'),'sort':'name','IntervalId':_0x13b736('0x15d7')})[_0x13b736('0xa44')]['then'](function(_0x41b493){const _0x234060=_0x13b736;_0x5e4cf0['interval']=_0x41b493[_0x234060('0x269a')]||[];})[_0x13b736('0x1a80')](function(_0x309d22){const _0x125a40=_0x13b736;_0x12f48e['error']({'title':_0x309d22[_0x125a40('0x52d')]?'API:'+_0x309d22[_0x125a40('0x52d')]+_0x125a40('0x11e1')+_0x309d22['statusText']:'SYSTEM:GET_INTERVAL','msg':_0x309d22['data']?JSON['stringify'](_0x309d22[_0x125a40('0x25f4')]):_0x309d22[_0x125a40('0x1586')]()});}):_0x4b95fd[_0x13b736('0x277c')][_0x13b736('0xd83')]({'fields':'id,name','sort':_0x13b736('0x4f0'),'IntervalId':_0x13b736('0x15d7')})[_0x13b736('0xa44')][_0x13b736('0x1166')](function(_0x194a1c){const _0x526a9a=_0x13b736;_0x5e4cf0['interval']=_0x194a1c[_0x526a9a('0x269a')]||[];})[_0x13b736('0x1166')](function(){const _0x483078=_0x13b736;return _0x4b95fd['userProfileSection'][_0x483078('0xd83')]({'userProfileId':_0x5e4cf0['currentUser'][_0x483078('0xb86')],'sectionId':0x3ec})[_0x483078('0xa44')];})[_0x13b736('0x1166')](function(_0x54875a){const _0x377eb6=_0x13b736,_0x4cad00=_0x54875a&&_0x54875a[_0x377eb6('0x269a')]?_0x54875a[_0x377eb6('0x269a')][0x0]:null;if(!_0x4cad00){const _0xb57a64=[];let _0x196c13=null;_0x5e4cf0['queueCampaign']&&(_0x196c13=_0x2cfb05()['find'](_0x5e4cf0[_0x377eb6('0x277c')],{'id':Number(_0x5e4cf0[_0x377eb6('0x1915')][_0x377eb6('0x186f')])}));for(let _0x45756b=0x0;_0x45756b<_0x5e4cf0[_0x377eb6('0x277c')][_0x377eb6('0x264b')];_0x45756b++){_0x196c13&&_0x5e4cf0['interval'][_0x45756b]['id']===_0x196c13['id']&&(_0x5e4cf0[_0x377eb6('0x277c')][_0x45756b][_0x377eb6('0x2378')]=![],_0xb57a64[_0x377eb6('0x1514')](_0x5e4cf0['interval'][_0x45756b]));}_0x5e4cf0['interval']=_0xb57a64;}else{if(!_0x4cad00[_0x377eb6('0x1a2b')])return _0x4b95fd[_0x377eb6('0x4b5')]['get']({'sectionId':_0x4cad00['id']})[_0x377eb6('0xa44')][_0x377eb6('0x1166')](function(_0xf62b2b){const _0x3ece98=_0x377eb6,_0x151f8e=_0x2cfb05()[_0x3ece98('0x2563')](_0xf62b2b[_0x3ece98('0x269a')],function(_0x1aeae9){const _0x3bf7b0=_0x3ece98;return _0x2cfb05()[_0x3bf7b0('0xc38')](_0x5e4cf0['interval'],{'id':_0x1aeae9[_0x3bf7b0('0x24e8')]});});let _0x9aff69=null;_0x5e4cf0[_0x3ece98('0x1915')]&&(_0x9aff69=_0x2cfb05()[_0x3ece98('0xc38')](_0x5e4cf0[_0x3ece98('0x277c')],{'id':Number(_0x5e4cf0[_0x3ece98('0x1915')]['IntervalId'])}));if(_0x9aff69&&!_0x2cfb05()[_0x3ece98('0x1798')](_0x151f8e,['id',_0x9aff69['id']])){const _0x1682ee=_0x2cfb05()[_0x3ece98('0xc38')](_0x5e4cf0[_0x3ece98('0x277c')],{'id':_0x9aff69['id']});_0x1682ee[_0x3ece98('0x2378')]=![],_0x151f8e[_0x3ece98('0x1514')](_0x1682ee);}_0x5e4cf0[_0x3ece98('0x277c')]=_0x151f8e;});}})[_0x13b736('0x1a80')](function(_0x3010b3){const _0x49a0c2=_0x13b736;_0x12f48e[_0x49a0c2('0xfc9')]({'title':_0x3010b3[_0x49a0c2('0x52d')]?'API:'+_0x3010b3[_0x49a0c2('0x52d')]+_0x49a0c2('0x11e1')+_0x3010b3[_0x49a0c2('0xe1b')]:_0x49a0c2('0xe48'),'msg':_0x3010b3[_0x49a0c2('0x25f4')]?JSON[_0x49a0c2('0xbac')](_0x3010b3[_0x49a0c2('0x25f4')]):_0x3010b3[_0x49a0c2('0x1586')]()});});function _0x3b7ce4(){const _0x531f09=_0x13b736;_0x5e4cf0[_0x531f09('0x61a')]=[],_0x4b95fd['voiceQueue'][_0x531f09('0x9cc')](_0x5e4cf0[_0x531f09('0x1915')])[_0x531f09('0xa44')]['then'](function(_0x5da9cc){const _0xea41fd=_0x531f09;_0x5e4cf0[_0xea41fd('0x182c')][_0xea41fd('0x2450')](_0x5da9cc[_0xea41fd('0x2876')]()),_0x12f48e[_0xea41fd('0x103b')]({'title':'QueueCampaign\x20properly\x20created','msg':_0x5e4cf0['queueCampaign'][_0xea41fd('0x4f0')]?_0x5e4cf0[_0xea41fd('0x1915')]['name']+_0xea41fd('0x1eda'):''}),_0x34f421(_0x5da9cc);})[_0x531f09('0x1a80')](function(_0x83c1b7){const _0x85fa2b=_0x531f09;if(_0x83c1b7['data']&&_0x83c1b7[_0x85fa2b('0x25f4')][_0x85fa2b('0x61a')]&&_0x83c1b7['data'][_0x85fa2b('0x61a')][_0x85fa2b('0x264b')]){_0x5e4cf0[_0x85fa2b('0x61a')]=_0x83c1b7['data'][_0x85fa2b('0x61a')]||[{'message':_0x83c1b7[_0x85fa2b('0x1586')](),'type':_0x85fa2b('0x14ca')}];for(let _0x5dac51=0x0;_0x5dac51<_0x83c1b7[_0x85fa2b('0x25f4')][_0x85fa2b('0x61a')][_0x85fa2b('0x264b')];_0x5dac51+=0x1){_0x12f48e[_0x85fa2b('0xfc9')]({'title':_0x83c1b7[_0x85fa2b('0x25f4')]['errors'][_0x5dac51][_0x85fa2b('0x1345')],'msg':_0x83c1b7['data'][_0x85fa2b('0x61a')][_0x5dac51][_0x85fa2b('0x1e70')]});}}else _0x12f48e[_0x85fa2b('0xfc9')]({'title':_0x83c1b7['status']?_0x85fa2b('0x1e21')+_0x83c1b7[_0x85fa2b('0x52d')]+_0x85fa2b('0x11e1')+_0x83c1b7[_0x85fa2b('0xe1b')]:_0x85fa2b('0x14ca'),'msg':_0x83c1b7[_0x85fa2b('0x25f4')]?JSON[_0x85fa2b('0xbac')](_0x83c1b7[_0x85fa2b('0x25f4')][_0x85fa2b('0x1e70')]):_0x83c1b7[_0x85fa2b('0x1586')]()});});}function _0x110610(){const _0xaea5c2=_0x13b736;_0x5e4cf0[_0xaea5c2('0x61a')]=[],_0x4b95fd[_0xaea5c2('0x1943')][_0xaea5c2('0x1449')]({'id':_0x5e4cf0[_0xaea5c2('0x1915')]['id']},_0x5e4cf0['queueCampaign'])[_0xaea5c2('0xa44')][_0xaea5c2('0x1166')](function(_0x3fd9cd){const _0x168861=_0xaea5c2,_0x318637=_0x2cfb05()['find'](_0x5e4cf0['queueCampaigns'],{'id':_0x3fd9cd['id']});_0x318637&&_0x2cfb05()[_0x168861('0xcc3')](_0x318637,_0x2cfb05()[_0x168861('0x1a08')](_0x3fd9cd[_0x168861('0x2876')](),_0x2cfb05()[_0x168861('0x14a4')](_0x318637))),_0x12f48e[_0x168861('0x103b')]({'title':'QueueCampaign\x20properly\x20saved!','msg':_0x5e4cf0[_0x168861('0x1915')][_0x168861('0x4f0')]?_0x5e4cf0[_0x168861('0x1915')][_0x168861('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x34f421(_0x3fd9cd);})[_0xaea5c2('0x1a80')](function(_0x2b5286){const _0x2974b1=_0xaea5c2;if(_0x2b5286[_0x2974b1('0x25f4')]&&_0x2b5286[_0x2974b1('0x25f4')]['errors']&&_0x2b5286[_0x2974b1('0x25f4')][_0x2974b1('0x61a')]['length']){_0x5e4cf0[_0x2974b1('0x61a')]=_0x2b5286[_0x2974b1('0x25f4')][_0x2974b1('0x61a')]||[{'message':_0x2b5286['toString'](),'type':_0x2974b1('0x1aed')}];for(let _0x60b910=0x0;_0x60b910<_0x2b5286['data']['errors'][_0x2974b1('0x264b')];_0x60b910++){_0x12f48e['error']({'title':_0x2b5286[_0x2974b1('0x25f4')][_0x2974b1('0x61a')][_0x60b910][_0x2974b1('0x1345')],'msg':_0x2b5286['data'][_0x2974b1('0x61a')][_0x60b910][_0x2974b1('0x1e70')]});}}else _0x12f48e[_0x2974b1('0xfc9')]({'title':_0x2b5286[_0x2974b1('0x52d')]?'API:'+_0x2b5286['status']+_0x2974b1('0x11e1')+_0x2b5286[_0x2974b1('0xe1b')]:_0x2974b1('0x1aed'),'msg':_0x2b5286['data']?JSON[_0x2974b1('0xbac')](_0x2b5286[_0x2974b1('0x25f4')][_0x2974b1('0x1e70')]):_0x2b5286['toString']()});});}function _0x2e5e69(_0x2d3832){const _0x4db6c6=_0x13b736;_0x5e4cf0[_0x4db6c6('0x61a')]=[];const _0x34552c=_0x4bafa0['confirm']()['title'](_0x4db6c6('0x7fb'))[_0x4db6c6('0xacc')]('The\x20queueCampaign\x20will\x20be\x20deleted.')['ariaLabel']('Delete\x20QueueCampaign')['ok']('Delete')[_0x4db6c6('0x3f')]('Cancel')[_0x4db6c6('0x203b')](_0x2d3832);_0x4bafa0[_0x4db6c6('0x1f80')](_0x34552c)[_0x4db6c6('0x1166')](function(){const _0x50613b=_0x4db6c6;_0x4b95fd[_0x50613b('0x1943')][_0x50613b('0x906')]({'id':_0x5e4cf0[_0x50613b('0x1915')]['id']})[_0x50613b('0xa44')][_0x50613b('0x1166')](function(){const _0x5c732d=_0x50613b;_0x2cfb05()[_0x5c732d('0x127f')](_0x5e4cf0[_0x5c732d('0x182c')],{'id':_0x5e4cf0['queueCampaign']['id']}),_0x12f48e[_0x5c732d('0x103b')]({'title':_0x5c732d('0xad4'),'msg':(_0x5e4cf0[_0x5c732d('0x1915')][_0x5c732d('0x4f0')]||_0x5c732d('0x1915'))+_0x5c732d('0x7cd')}),_0x34f421(_0x5e4cf0[_0x5c732d('0x1915')]);})[_0x50613b('0x1a80')](function(_0x1d1085){const _0x533a40=_0x50613b;if(_0x1d1085['data']&&_0x1d1085['data'][_0x533a40('0x61a')]&&_0x1d1085[_0x533a40('0x25f4')]['errors'][_0x533a40('0x264b')]){_0x5e4cf0['errors']=_0x1d1085[_0x533a40('0x25f4')][_0x533a40('0x61a')]||[{'message':_0x1d1085[_0x533a40('0x1586')](),'type':_0x533a40('0x221d')}];for(let _0x592576=0x0;_0x592576<_0x1d1085[_0x533a40('0x25f4')][_0x533a40('0x61a')][_0x533a40('0x264b')];_0x592576++){_0x12f48e[_0x533a40('0xfc9')]({'title':_0x1d1085[_0x533a40('0x25f4')][_0x533a40('0x61a')][_0x592576][_0x533a40('0x1345')],'msg':_0x1d1085[_0x533a40('0x25f4')][_0x533a40('0x61a')][_0x592576][_0x533a40('0x1e70')]});}}else _0x12f48e['error']({'title':_0x1d1085[_0x533a40('0x52d')]?_0x533a40('0x1e21')+_0x1d1085[_0x533a40('0x52d')]+'\x20-\x20'+_0x1d1085[_0x533a40('0xe1b')]:_0x533a40('0x221d'),'msg':_0x1d1085[_0x533a40('0x25f4')]?JSON[_0x533a40('0xbac')](_0x1d1085['data']['message']):_0x1d1085[_0x533a40('0x1e70')]||_0x1d1085[_0x533a40('0x1586')]()});});},function(){});}function _0x325a60(_0x21b8b7){return _0x21b8b7===null?undefined:new Date(_0x21b8b7);}function _0x34f421(_0x153ab0){const _0x7217fc=_0x13b736;_0x4bafa0[_0x7217fc('0x1197')](_0x153ab0);}}const _0x278b4c=_0x5de11d;_0x4cd114[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x1915'),_0x36e6f4('0x182c'),'realtime',_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x4cd114(_0x2a15c2,_0x175182,_0x163eec,_0x53c113,_0x55790a,_0x5b0f56,_0x394b4c,_0x29b08f,_0x2ecd61,_0x1d766d){const _0x157e15=_0x36e6f4,_0x79e5c5=this;_0x79e5c5['currentUser']=_0x2ecd61['getCurrentUser'](),_0x79e5c5[_0x157e15('0x1915')]=_0x55790a,_0x79e5c5[_0x157e15('0x243c')]=_0x1d766d,_0x79e5c5[_0x157e15('0x23af')]=0x0,_0x79e5c5[_0x157e15('0xf01')]=_0x394b4c,_0x79e5c5[_0x157e15('0xbd7')]=[],_0x79e5c5['allowedItems']=[],_0x79e5c5[_0x157e15('0x18e1')]=[],_0x79e5c5[_0x157e15('0x2111')]=[],_0x79e5c5[_0x157e15('0x2781')]=[],_0x79e5c5[_0x157e15('0x14d7')]=![],_0x79e5c5[_0x157e15('0xae0')]=_0x49919d,_0x79e5c5[_0x157e15('0x1d92')]=_0x1ba415,_0x79e5c5['closeDialog']=_0x180ad1,_0x79e5c5[_0x157e15('0xc68')]={'readOnly':!_0x79e5c5[_0x157e15('0x243c')][_0x157e15('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x157e15('0x4f0'),'line1':_0x157e15('0x6e1'),'line2':['name',_0x157e15('0x1eef')],'line3':'penalty','labelAll':_0x29b08f['instant'](_0x157e15('0xd01')),'labelSelected':_0x29b08f[_0x157e15('0x25cc')](_0x157e15('0x24f4')),'transferCallback':function(_0x40859f,_0x200b42){const _0x53c8f0=_0x157e15;_0x200b42?_0x40859f[_0x53c8f0('0x2782')](function(_0x3cd72f){const _0x1dca69=_0x53c8f0;_0x3cd72f[_0x1dca69('0x23af')]=undefined;}):_0x40859f[_0x53c8f0('0x2782')](function(_0x151acb){const _0x415198=_0x53c8f0;_0x151acb[_0x415198('0x23af')]=_0x415198('0x11e8')+_0x79e5c5['penalty'];});const _0x828da6=_0x2cfb05()[_0x53c8f0('0x1c71')](_0x79e5c5[_0x53c8f0('0x2781')],_0x79e5c5[_0x53c8f0('0x18e1')],function(_0x5d7eb6,_0x4f0e9f){return _0x5d7eb6['id']===_0x4f0e9f['id']&&_0x5d7eb6['penalty']===_0x4f0e9f['penalty'];});_0x79e5c5[_0x53c8f0('0x14d7')]=_0x2cfb05()[_0x53c8f0('0x1081')](_0x828da6)?![]:!![];}};function _0x49919d(){const _0xb46e96=_0x157e15;return _0x2ecd61[_0xb46e96('0x1ac6')]('admin')?_0x50e34b()[_0xb46e96('0x1a80')](function(_0x5cacb4){const _0x16f177=_0xb46e96;_0x163eec[_0x16f177('0xfc9')]({'title':_0x5cacb4['status']?_0x16f177('0x1e21')+_0x5cacb4[_0x16f177('0x52d')]+_0x16f177('0x11e1')+_0x5cacb4[_0x16f177('0xe1b')]:_0x16f177('0xd4c'),'msg':_0x5cacb4[_0x16f177('0x52d')]?JSON[_0x16f177('0xbac')](_0x5cacb4[_0x16f177('0x25f4')]):_0x5cacb4[_0x16f177('0x1586')]()});}):_0x47def3()[_0xb46e96('0x1166')](function(_0x4e2fc8){const _0xfc247e=_0xb46e96;return _0x79e5c5[_0xfc247e('0xe60')]=_0x4e2fc8,_0x50e34b();})['catch'](function(_0x4dab2d){const _0xb6754e=_0xb46e96;_0x163eec['error']({'title':_0x4dab2d['status']?_0xb6754e('0x1e21')+_0x4dab2d[_0xb6754e('0x52d')]+_0xb6754e('0x11e1')+_0x4dab2d[_0xb6754e('0xe1b')]:_0xb6754e('0xd4c'),'msg':_0x4dab2d[_0xb6754e('0x52d')]?JSON[_0xb6754e('0xbac')](_0x4dab2d['data']):_0x4dab2d[_0xb6754e('0x1586')]()});});}function _0x47def3(){return _0x175182(function(_0x1a9d6e,_0x34acb5){const _0x56a37a=a0_0x3f2c;_0x53c113['userProfileSection'][_0x56a37a('0xd83')]({'userProfileId':_0x79e5c5['currentUser']['userProfileId'],'name':_0x56a37a('0x2391')})[_0x56a37a('0xa44')][_0x56a37a('0x1166')](function(_0x514ee3){const _0x5ea735=_0x56a37a,_0x5bf9ce=_0x514ee3&&_0x514ee3[_0x5ea735('0x269a')]?_0x514ee3[_0x5ea735('0x269a')][0x0]:null;_0x1a9d6e(_0x5bf9ce);})['catch'](function(_0x60157c){_0x34acb5(_0x60157c);});});}function _0x50e34b(){return _0x175182(function(_0x2bd92d,_0x132154){const _0x157fb7=a0_0x3f2c;return _0x311e64()[_0x157fb7('0x1166')](function(_0xe57d32){const _0x4bac68=_0x157fb7;return _0x79e5c5[_0x4bac68('0xbd7')]=_0xe57d32[_0x4bac68('0x269a')]?_0xe57d32[_0x4bac68('0x269a')]:[],_0x2ecd61[_0x4bac68('0x1ac6')](_0x4bac68('0xa7c'))?_0xe57d32:_0x79e5c5['section']?_0x79e5c5[_0x4bac68('0xe60')]['autoAssociation']?_0xe57d32:_0x4e8ed9():null;})[_0x157fb7('0x1166')](function(_0x2ac118){const _0x5a1452=_0x157fb7,_0x306b1f=_0x2ac118&&_0x2ac118[_0x5a1452('0x269a')]?_0x2ac118['rows']:[];return _0x79e5c5[_0x5a1452('0x10ab')]=_0x2cfb05()[_0x5a1452('0x2563')](_0x306b1f,function(_0xacd50e){const _0x4be4a5=_0x5a1452;return _0x2cfb05()['find'](_0x79e5c5[_0x4be4a5('0xbd7')],{'id':_0x2ecd61[_0x4be4a5('0x1ac6')](_0x4be4a5('0xa7c'))||_0x79e5c5[_0x4be4a5('0xe60')][_0x4be4a5('0x1a2b')]?_0xacd50e['id']:_0xacd50e[_0x4be4a5('0x24e8')]});}),_0x79e5c5[_0x5a1452('0x2111')]=angular[_0x5a1452('0x225f')](_0x79e5c5['allowedItems']),_0x79e5c5[_0x5a1452('0xbd7')][_0x5a1452('0x2782')](function(_0xc6c051){const _0x1ae66c=_0x5a1452,_0x3141b7=_0x2cfb05()[_0x1ae66c('0xc38')](_0x79e5c5['allowedItems'],{'id':_0xc6c051['id']});_0x2ecd61[_0x1ae66c('0x1ac6')](_0x1ae66c('0xa7c'))?_0xc6c051[_0x1ae66c('0x26ef')]=!![]:_0xc6c051[_0x1ae66c('0x26ef')]=typeof _0x3141b7!==_0x1ae66c('0x1048')?!![]:![];}),_0x4fbb13();})[_0x157fb7('0x1166')](function(_0x25d9d9){const _0xdf429a=_0x157fb7,_0x1e1d8d=_0x25d9d9&&_0x25d9d9[_0xdf429a('0x269a')]?_0x25d9d9['rows']:[];_0x79e5c5['selectedItems']=_0x2cfb05()[_0xdf429a('0x2563')](_0x1e1d8d,function(_0x395a49){const _0x39a4c4=_0xdf429a,_0x54617b=_0x2cfb05()[_0x39a4c4('0xc38')](_0x79e5c5[_0x39a4c4('0xbd7')],{'id':_0x395a49['id']});return _0x54617b['penalty']=_0x395a49[_0x39a4c4('0x1dcc')]?_0x39a4c4('0x11e8')+_0x395a49['UserVoiceQueue'][_0x39a4c4('0x23af')]:'',_0x54617b['internal']=typeof _0x395a49[_0x39a4c4('0x1eef')]!==_0x39a4c4('0x1048')?'<'+_0x395a49[_0x39a4c4('0x1eef')]+'>':'',_0x54617b;}),_0x79e5c5['startingSelectedItems']=angular[_0xdf429a('0x225f')](_0x79e5c5['selectedItems']),_0x79e5c5[_0xdf429a('0xc68')][_0xdf429a('0x18e1')]=_0x79e5c5[_0xdf429a('0x18e1')],_0x79e5c5[_0xdf429a('0xc68')][_0xdf429a('0xbd7')]=_0x2cfb05()[_0xdf429a('0x24ac')](_0x79e5c5[_0xdf429a('0x10ab')],_0x79e5c5['dualMultiselectOptions'][_0xdf429a('0x18e1')],'id'),_0x2bd92d();})[_0x157fb7('0x1a80')](function(_0x485b49){_0x132154(_0x485b49);});});}function _0x4e8ed9(){return _0x175182(function(_0x57a257,_0x388063){const _0x14ae0e=a0_0x3f2c;return _0x53c113[_0x14ae0e('0x4b5')][_0x14ae0e('0xd83')]({'sectionId':_0x79e5c5['section']['id'],'nolimit':!![]})['$promise']['then'](function(_0x2ef895){_0x57a257(_0x2ef895);})[_0x14ae0e('0x1a80')](function(_0x602304){_0x388063(_0x602304);});});}function _0x4fbb13(){return _0x175182(function(_0x3ebadb,_0x1f0e25){const _0x16b9c3=a0_0x3f2c;return _0x53c113[_0x16b9c3('0x1943')][_0x16b9c3('0x261c')]({'id':_0x79e5c5[_0x16b9c3('0x1915')]['id'],'fields':_0x16b9c3('0x1459'),'nolimit':!![],'role':'agent'})[_0x16b9c3('0xa44')][_0x16b9c3('0x1166')](function(_0x2b0a7e){_0x3ebadb(_0x2b0a7e);})[_0x16b9c3('0x1a80')](function(_0x2735e7){_0x1f0e25(_0x2735e7);});});}function _0x311e64(){return _0x175182(function(_0x434630,_0x1af4dd){const _0x42735b=a0_0x3f2c;return _0x53c113[_0x42735b('0x557')][_0x42735b('0xd83')]({'fields':_0x42735b('0x1459'),'nolimit':!![],'role':_0x42735b('0x1eff')})['$promise'][_0x42735b('0x1166')](function(_0x55b93b){_0x434630(_0x55b93b);})[_0x42735b('0x1a80')](function(_0x255882){_0x1af4dd(_0x255882);});});}function _0x309879(_0x303532){return _0x175182(function(_0x1d81e4,_0x3203b6){const _0x2446f8=a0_0x3f2c;if(_0x2cfb05()[_0x2446f8('0x1081')](_0x303532))_0x1d81e4();else{const _0x2838bf=[],_0x3c25e6=_0x2cfb05()[_0x2446f8('0x1535')](_0x303532,_0x2446f8('0x23af'));for(let _0x20610f=0x0;_0x20610f'+_0x2179ec('0x3f3'))[_0x2179ec('0x8e8')](_0x2179ec('0x1fcc'))[_0x2179ec('0x203b')](_0x49e8b9)['ok']('OK')['cancel'](_0x2179ec('0x2d3'));_0x3885e7['show'](_0x2ea2e8)[_0x2179ec('0x1166')](function(){_0x1d40a5(_0x251db3);},function(){console['log']('CANCEL');});}function _0x3cbcd5(_0x268b06){const _0x517691=_0x2692a0;_0x530e74[_0x517691('0x3bf')]=_0x268b06||{'count':0x0,'rows':[]};}function _0x2a9bf0(){const _0x556954=_0x2692a0;_0x530e74[_0x556954('0x2218')][_0x556954('0x1098')]=(_0x530e74[_0x556954('0x2218')][_0x556954('0x1a43')]-0x1)*_0x530e74[_0x556954('0x2218')][_0x556954('0x163f')],_0x530e74['promise']=_0x5c2f91[_0x556954('0x1943')][_0x556954('0x260a')](_0x530e74['query'],_0x3cbcd5)[_0x556954('0xa44')];}function _0x1d40a5(_0xd48ec6){const _0x3676c3=_0x2692a0;_0x5c2f91[_0x3676c3('0x2434')]['delete']({'id':_0xd48ec6['id']})[_0x3676c3('0xa44')][_0x3676c3('0x1166')](function(){const _0x3fb042=_0x3676c3;_0x2cfb05()['remove'](_0x530e74[_0x3fb042('0x3bf')][_0x3fb042('0x269a')],{'id':_0xd48ec6['id']}),_0x530e74[_0x3fb042('0x3bf')][_0x3fb042('0x240f')]-=0x1,!_0x530e74[_0x3fb042('0x3bf')][_0x3fb042('0x269a')]['length']&&_0x2a9bf0(),_0x26f6b3[_0x3fb042('0x103b')]({'title':_0x3fb042('0x1e31'),'msg':_0xd48ec6['name']?_0xd48ec6[_0x3fb042('0x4f0')]+_0x3fb042('0x7cd'):''});})[_0x3676c3('0x1a80')](function(_0x1bf3f1){const _0x52bd02=_0x3676c3;if(_0x1bf3f1[_0x52bd02('0x25f4')]&&_0x1bf3f1[_0x52bd02('0x25f4')][_0x52bd02('0x61a')]&&_0x1bf3f1[_0x52bd02('0x25f4')][_0x52bd02('0x61a')][_0x52bd02('0x264b')]){_0x530e74[_0x52bd02('0x61a')]=_0x1bf3f1[_0x52bd02('0x25f4')]['errors']||[{'message':_0x1bf3f1[_0x52bd02('0x1586')](),'type':'SYSTEM:GETvoiceQueue'}];for(let _0x5b2470=0x0;_0x5b2470<_0x1bf3f1['data'][_0x52bd02('0x61a')][_0x52bd02('0x264b')];_0x5b2470++){_0x26f6b3[_0x52bd02('0xfc9')]({'title':_0x1bf3f1[_0x52bd02('0x25f4')]['errors'][_0x5b2470][_0x52bd02('0x1345')],'msg':_0x1bf3f1['data'][_0x52bd02('0x61a')][_0x5b2470]['message']});}}else _0x26f6b3['error']({'title':_0x1bf3f1[_0x52bd02('0x52d')]?_0x52bd02('0x1e21')+_0x1bf3f1[_0x52bd02('0x52d')]+_0x52bd02('0x11e1')+_0x1bf3f1[_0x52bd02('0xe1b')]:_0x52bd02('0x1c74'),'msg':_0x1bf3f1[_0x52bd02('0x25f4')]?JSON[_0x52bd02('0xbac')](_0x1bf3f1[_0x52bd02('0x25f4')][_0x52bd02('0x1e70')]):_0x1bf3f1['message']||_0x1bf3f1['toString']()});});}function _0x15f008(){const _0x48b4c9=_0x2692a0,_0x10489e=angular[_0x48b4c9('0x225f')](_0x530e74[_0x48b4c9('0x20de')]);return _0x530e74[_0x48b4c9('0x20de')]=[],_0x10489e;}function _0x59f776(_0x27dc13){const _0x17ac0f=_0x2692a0,_0x5105bc=_0x3885e7[_0x17ac0f('0x1d26')]()[_0x17ac0f('0xcdc')](_0x17ac0f('0xdd2'))[_0x17ac0f('0xf3c')](''+_0x530e74[_0x17ac0f('0x20de')][_0x17ac0f('0x264b')]+_0x17ac0f('0x196d')+'\x20will\x20be\x20deleted.')[_0x17ac0f('0x8e8')]('delete\x20hopperBlacks')[_0x17ac0f('0x203b')](_0x27dc13)['ok']('OK')[_0x17ac0f('0x3f')]('CANCEL');_0x3885e7[_0x17ac0f('0x1f80')](_0x5105bc)['then'](function(){const _0x2e4bc9=_0x17ac0f;_0x530e74['selectedQueueCampaignHopperBlacks'][_0x2e4bc9('0x2782')](function(_0x148469){_0x1d40a5(_0x148469);}),_0x530e74[_0x2e4bc9('0x20de')]=[];});}let _0x365bd0=!![],_0x5a9133=0x1;_0x3b8349[_0x2692a0('0xe83')](_0x2692a0('0x28b4'),function(_0x249000,_0x552a43){const _0x2edcef=_0x2692a0;_0x365bd0?_0x46531a(function(){_0x365bd0=![];}):(!_0x552a43&&(_0x5a9133=_0x530e74['query'][_0x2edcef('0x1a43')]),_0x249000!==_0x552a43&&(_0x530e74[_0x2edcef('0x2218')][_0x2edcef('0x1a43')]=0x1),!_0x249000&&(_0x530e74[_0x2edcef('0x2218')][_0x2edcef('0x1a43')]=_0x5a9133),_0x2a9bf0());});}const _0x36ded2=_0x3cc9db;_0xb03c91[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0xb03c91(_0x1b0341,_0xcff8c8,_0x26ffd5,_0x4a8c10,_0x426e5e,_0x31e399,_0x3e34be,_0x4596c8,_0x178959,_0x3f4334,_0x4d8dbf){const _0x5bfc18=_0x36e6f4,_0xd1be92=this;_0xd1be92[_0x5bfc18('0x98')]=_0x4d8dbf[_0x5bfc18('0x26cd')](),_0xd1be92[_0x5bfc18('0xca8')]={},_0xd1be92['queueCampaign']={},_0xd1be92[_0x5bfc18('0x8a1')]={'count':0x0,'rows':[]},_0xd1be92[_0x5bfc18('0x2509')]=[],_0xd1be92[_0x5bfc18('0x243c')],_0xd1be92[_0x5bfc18('0x2218')]={'fields':'createdAt,updatedAt,uniqueid,ContactId,calleridnum,calleridname,statedesc,countcongestionretry,countbusyretry,countnoanswerretry,countnosuchnumberretry,countdropretry,countabandonedretry,countmachineretry,countagentrejectretry,countglobal,scheduledat,starttime,responsetime,endtime,disposition,secondDisposition,thirdDisposition,ListId,UserId,VoiceQueueId,CampaignId,recallme,deleted,campaign','sort':_0x5bfc18('0x83'),'limit':0xa,'page':0x1},_0xd1be92['init']=_0xafba07,_0xd1be92[_0x5bfc18('0x8a2')]=_0x28770f,_0xd1be92['success']=_0x11f8ea,_0xd1be92[_0x5bfc18('0x11d0')]=_0x229ca5,_0xd1be92[_0x5bfc18('0x15f')]=_0x43c9fe,_0xd1be92[_0x5bfc18('0x1827')]=_0x4310e2,_0xd1be92[_0x5bfc18('0x19df')]=_0x5f3f16,_0xd1be92[_0x5bfc18('0x1867')]=_0x3b6f47,_0xd1be92[_0x5bfc18('0x54c')]=_0x5d156,_0xd1be92[_0x5bfc18('0x8e6')]=_0x5f10a4,_0xd1be92[_0x5bfc18('0x284c')]=_0x441417,_0xd1be92[_0x5bfc18('0x2032')]=_0x306889;function _0xafba07(_0x128428,_0x2849d9){const _0x588e8e=_0x5bfc18;_0xd1be92[_0x588e8e('0x1915')]=_0x128428,_0xd1be92[_0x588e8e('0x243c')]=typeof _0x2849d9!=='undefined'?_0x2849d9:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0xd1be92[_0x588e8e('0x2218')][_0x588e8e('0xc69')]=_0xd1be92['queueCampaign']['id'],_0xd1be92[_0x588e8e('0x2218')]['id']=_0xd1be92[_0x588e8e('0x1915')]['id'],_0x229ca5();}function _0x28770f(_0x22899f,_0x453588){const _0x101047=_0x5bfc18,_0x5d6c09=_0x3e34be['confirm']()[_0x101047('0xcdc')](_0x101047('0x9e0'))[_0x101047('0xf3c')](''+(_0x22899f[_0x101047('0x4f0')]||_0x22899f['id']&&_0x2cfb05()['upperFirst'](_0x101047('0x1f2'))+_0x22899f['id']||'hopperFinal')+_0x101047('0xace')+_0x101047('0x3f3'))[_0x101047('0x8e8')](_0x101047('0x8bf'))[_0x101047('0x203b')](_0x453588)['ok']('OK')['cancel']('CANCEL');_0x3e34be[_0x101047('0x1f80')](_0x5d6c09)[_0x101047('0x1166')](function(){_0x4310e2(_0x22899f);},function(){const _0xdaf7f7=_0x101047;console[_0xdaf7f7('0x455')]('CANCEL');});}function _0x11f8ea(_0x156920){const _0x54b7ab=_0x5bfc18;_0xd1be92[_0x54b7ab('0x8a1')]=_0x156920||{'count':0x0,'rows':[]};}function _0x229ca5(){const _0x4e85bc=_0x5bfc18;_0xd1be92[_0x4e85bc('0x2218')][_0x4e85bc('0x1098')]=(_0xd1be92['query'][_0x4e85bc('0x1a43')]-0x1)*_0xd1be92[_0x4e85bc('0x2218')][_0x4e85bc('0x163f')],_0xd1be92['promise']=_0x3f4334[_0x4e85bc('0x1943')][_0x4e85bc('0x1e1c')](_0xd1be92[_0x4e85bc('0x2218')],_0x11f8ea)[_0x4e85bc('0xa44')];}function _0x4310e2(_0x480866){const _0x5be7c5=_0x5bfc18;_0x3f4334[_0x5be7c5('0x1384')][_0x5be7c5('0x906')]({'id':_0x480866['id']})[_0x5be7c5('0xa44')][_0x5be7c5('0x1166')](function(){const _0x510de6=_0x5be7c5;_0x2cfb05()[_0x510de6('0x127f')](_0xd1be92[_0x510de6('0x8a1')][_0x510de6('0x269a')],{'id':_0x480866['id']}),_0xd1be92[_0x510de6('0x8a1')][_0x510de6('0x240f')]-=0x1,!_0xd1be92[_0x510de6('0x8a1')][_0x510de6('0x269a')][_0x510de6('0x264b')]&&_0x229ca5(),_0x178959[_0x510de6('0x103b')]({'title':_0x510de6('0x276f'),'msg':_0x480866[_0x510de6('0x4f0')]?_0x480866[_0x510de6('0x4f0')]+_0x510de6('0x7cd'):''});})[_0x5be7c5('0x1a80')](function(_0x2b8fd2){const _0x5b21ea=_0x5be7c5;if(_0x2b8fd2['data']&&_0x2b8fd2['data'][_0x5b21ea('0x61a')]&&_0x2b8fd2[_0x5b21ea('0x25f4')][_0x5b21ea('0x61a')]['length']){_0xd1be92[_0x5b21ea('0x61a')]=_0x2b8fd2[_0x5b21ea('0x25f4')]['errors']||[{'message':_0x2b8fd2[_0x5b21ea('0x1586')](),'type':'SYSTEM:GETvoiceQueue'}];for(let _0x46723c=0x0;_0x46723c<_0x2b8fd2[_0x5b21ea('0x25f4')][_0x5b21ea('0x61a')][_0x5b21ea('0x264b')];_0x46723c++){_0x178959[_0x5b21ea('0xfc9')]({'title':_0x2b8fd2[_0x5b21ea('0x25f4')][_0x5b21ea('0x61a')][_0x46723c][_0x5b21ea('0x1345')],'msg':_0x2b8fd2[_0x5b21ea('0x25f4')]['errors'][_0x46723c][_0x5b21ea('0x1e70')]});}}else _0x178959[_0x5b21ea('0xfc9')]({'title':_0x2b8fd2[_0x5b21ea('0x52d')]?_0x5b21ea('0x1e21')+_0x2b8fd2[_0x5b21ea('0x52d')]+_0x5b21ea('0x11e1')+_0x2b8fd2[_0x5b21ea('0xe1b')]:_0x5b21ea('0x1c74'),'msg':_0x2b8fd2[_0x5b21ea('0x25f4')]?JSON[_0x5b21ea('0xbac')](_0x2b8fd2[_0x5b21ea('0x25f4')][_0x5b21ea('0x1e70')]):_0x2b8fd2['message']||_0x2b8fd2[_0x5b21ea('0x1586')]()});});}function _0x43c9fe(){const _0x3414db=_0x5bfc18,_0x2aa532=angular['copy'](_0xd1be92[_0x3414db('0x2509')]);return _0xd1be92[_0x3414db('0x2509')]=[],_0x2aa532;}function _0x5f3f16(_0x50577){const _0x467d0b=_0x5bfc18,_0x3c9765=_0x3e34be[_0x467d0b('0x1d26')]()['title'](_0x467d0b('0xbce'))[_0x467d0b('0xf3c')](''+_0xd1be92['selectedQueueCampaignHopperFinals'][_0x467d0b('0x264b')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x467d0b('0x8e8')]('delete\x20hopperFinals')[_0x467d0b('0x203b')](_0x50577)['ok']('OK')[_0x467d0b('0x3f')](_0x467d0b('0x2d3'));_0x3e34be[_0x467d0b('0x1f80')](_0x3c9765)[_0x467d0b('0x1166')](function(){const _0x5c1517=_0x467d0b;_0xd1be92['selectedQueueCampaignHopperFinals'][_0x5c1517('0x2782')](function(_0x2c93de){_0x4310e2(_0x2c93de);}),_0xd1be92['selectedQueueCampaignHopperFinals']=[];});}function _0x5d156(_0x872806){const _0x348fcd=_0x5bfc18;_0x3f4334[_0x348fcd('0x1806')][_0x348fcd('0x54c')]({'id':_0xd1be92[_0x348fcd('0x2218')]['id'],'state':_0x872806})['$promise'][_0x348fcd('0x1166')](function(_0x4b62d8){const _0x1d883b=_0x348fcd;_0x2cfb05()[_0x1d883b('0x2863')](_0x4b62d8)&&_0x2cfb05()[_0x1d883b('0x2863')](_0x4b62d8[0x0])?_0x178959['info']({'title':_0x1d883b('0x1fe8'),'msg':'0'}):_0x178959[_0x1d883b('0x1fa1')]({'title':_0x1d883b('0x1fe8'),'msg':JSON[_0x1d883b('0xbac')](_0x4b62d8[0x0][_0x1d883b('0x23c7')])});})[_0x348fcd('0x1a80')](function(_0x206e0d){const _0x5d8efa=_0x348fcd;_0x178959['error']({'title':_0x206e0d[_0x5d8efa('0x52d')]?_0x5d8efa('0x1e21')+_0x206e0d['status']+'\x20-\x20'+_0x206e0d[_0x5d8efa('0xe1b')]:'SYSTEM:GETvoiceQueue','msg':_0x206e0d[_0x5d8efa('0x25f4')]?JSON[_0x5d8efa('0xbac')](_0x206e0d[_0x5d8efa('0x25f4')][_0x5d8efa('0x1e70')]):_0x206e0d['message']||_0x206e0d[_0x5d8efa('0x1586')]()});});}function _0x5f10a4(_0x6ce95f){const _0x35ce4e=_0x5bfc18;_0x3f4334[_0x35ce4e('0x1806')][_0x35ce4e('0x8e6')]({'id':_0x6ce95f})[_0x35ce4e('0xa44')][_0x35ce4e('0x1166')](function(_0x597285){const _0x2ae47c=_0x35ce4e;_0x2cfb05()[_0x2ae47c('0xcc3')](_0xd1be92['contacts'],_0x597285[0x0]);})['catch'](function(_0xc53e4f){const _0x4b546b=_0x35ce4e;_0x178959[_0x4b546b('0xfc9')]({'title':_0xc53e4f[_0x4b546b('0x52d')]?_0x4b546b('0x1e21')+_0xc53e4f[_0x4b546b('0x52d')]+_0x4b546b('0x11e1')+_0xc53e4f['statusText']:'SYSTEM:GETvoiceQueue','msg':_0xc53e4f[_0x4b546b('0x25f4')]?JSON[_0x4b546b('0xbac')](_0xc53e4f[_0x4b546b('0x25f4')][_0x4b546b('0x1e70')]):_0xc53e4f['message']||_0xc53e4f['toString']()});});}function _0x306889(_0x4faf34){const _0x5e71f9=_0x5bfc18,_0x1e86bf=_0x3e34be[_0x5e71f9('0x1d26')]()[_0x5e71f9('0xcdc')](_0x5e71f9('0x17ef'))[_0x5e71f9('0xf3c')]('\x20Contacts\x20selected'+_0x5e71f9('0x2648'))['ariaLabel']('Restore\x20Contacts')['targetEvent'](_0x4faf34)['ok']('OK')[_0x5e71f9('0x3f')](_0x5e71f9('0x2d3'));_0x3e34be['show'](_0x1e86bf)['then'](function(){const _0x139047=_0x5e71f9;_0xd1be92['selectedQueueCampaignHopperFinals'][_0x139047('0x2782')](function(_0x156635){_0x3b6f47(_0x156635);}),_0xd1be92['selectedQueueCampaignHopperFinals']=[];});}function _0x441417(_0x1305df,_0x5e4979){const _0x5f0eb9=_0x5bfc18,_0x5737f2=_0x3e34be[_0x5f0eb9('0x1d26')]()[_0x5f0eb9('0xcdc')](_0x5f0eb9('0xd48'))[_0x5f0eb9('0xf3c')](_0x5f0eb9('0x12b5')+_0x5f0eb9('0x21a4')+_0x5f0eb9('0xace')+'\x20will\x20be\x20restored.')[_0x5f0eb9('0x8e8')](_0x5f0eb9('0x1f3c'))[_0x5f0eb9('0x203b')](_0x5e4979)['ok']('OK')[_0x5f0eb9('0x3f')](_0x5f0eb9('0x2d3'));_0x3e34be[_0x5f0eb9('0x1f80')](_0x5737f2)['then'](function(){_0x3b6f47(_0x1305df);},function(){const _0x359189=_0x5f0eb9;console['log'](_0x359189('0x2d3'));});}function _0x460e52(_0x3e6c12){const _0x584452=_0x5bfc18,_0x94c1aa={};return _0x94c1aa['phone']=_0x3e6c12[_0x584452('0x26a8')],_0x94c1aa[_0x584452('0x1c5e')]=_0x24273b()()[_0x584452('0x128a')](_0x584452('0x1084')),_0x94c1aa[_0x584452('0x1736')]=0x0,_0x94c1aa['countcongestionretry']=0x0,_0x94c1aa['countnoanswerretry']=0x0,_0x94c1aa[_0x584452('0x1422')]=0x0,_0x94c1aa[_0x584452('0x1a17')]=_0x3e6c12['ContactId'],_0x94c1aa[_0x584452('0x23c')]=_0x3e6c12[_0x584452('0x23c')],_0x94c1aa[_0x584452('0x122a')]=_0x3e6c12['deleted']?null:_0x3e6c12['UserId'],_0x94c1aa[_0x584452('0xc69')]=_0x3e6c12[_0x584452('0xc69')],_0x94c1aa[_0x584452('0xd88')]=_0x3e6c12[_0x584452('0xd88')],_0x94c1aa['priority']=_0x3e6c12[_0x584452('0xc10')]?0x3:0x2,_0x94c1aa[_0x584452('0xc10')]=_0x3e6c12[_0x584452('0xc10')]?!![]:![],_0x94c1aa;}function _0x1d86a4(_0x4da43c){const _0x3b34d0=_0x5bfc18,_0x3085d0={};return _0x3085d0['calleridnum']=_0x4da43c['calleridnum'],_0x3085d0[_0x3b34d0('0x1f24')]=_0x4da43c[_0x3b34d0('0x1f24')],_0x3085d0[_0x3b34d0('0x1c5e')]=_0x24273b()()[_0x3b34d0('0x128a')]('YYYY-MM-DD\x20HH:mm:ss'),_0x3085d0[_0x3b34d0('0x1736')]=_0x4da43c['countbusyretry'],_0x3085d0[_0x3b34d0('0x406')]=_0x4da43c[_0x3b34d0('0x406')],_0x3085d0['countnoanswerretry']=_0x4da43c[_0x3b34d0('0x1c7')],_0x3085d0[_0x3b34d0('0x1422')]=_0x4da43c[_0x3b34d0('0x1422')],_0x3085d0[_0x3b34d0('0x1a17')]=_0x4da43c[_0x3b34d0('0x1a17')],_0x3085d0[_0x3b34d0('0x23c')]=_0x4da43c[_0x3b34d0('0x23c')],_0x3085d0[_0x3b34d0('0x122a')]=_0x4d8dbf['getCurrentUser']()['id'],_0x3085d0[_0x3b34d0('0xc69')]=_0x4da43c[_0x3b34d0('0xc69')],_0x3085d0['CampaignId']=_0x4da43c['CampaignId'],_0x3085d0[_0x3b34d0('0x451')]=_0x24273b()()[_0x3b34d0('0x128a')](_0x3b34d0('0x1084')),_0x3085d0[_0x3b34d0('0x28ca')]=!![],_0x3085d0['state']=0x19,_0x3085d0['statedesc']='Restored',_0x3085d0[_0x3b34d0('0xb13')]=_0x4da43c[_0x3b34d0('0xb13')],_0x3085d0[_0x3b34d0('0x1eaf')]=_0x4da43c['VoiceQueueId']?_0x3b34d0('0x1d3e'):_0x3b34d0('0x681'),_0x3085d0;}function _0x3b6f47(_0x2bce90){const _0x167e89=_0x5bfc18;_0x3f4334[_0x167e89('0x1806')][_0x167e89('0x915')](_0x2bce90)['$promise']['then'](function(_0x58c40c){const _0x4d43a3=_0x167e89;_0x178959[_0x4d43a3('0x1fa1')]({'title':_0x4d43a3('0xcc4'),'msg':_0x4d43a3('0x541')+_0x58c40c[_0x4d43a3('0x1a17')]});})[_0x167e89('0x1a80')](function(_0x134c7b){const _0x3628dd=_0x167e89;_0x134c7b['data']==='Not\x20Found'?_0x3f4334[_0x3628dd('0x256a')][_0x3628dd('0x9cc')](_0x460e52(_0x2bce90))[_0x3628dd('0xa44')]['then'](function(_0x37cacb){const _0x221d67=_0x3628dd;_0x178959[_0x221d67('0x1fa1')]({'title':_0x221d67('0xab1'),'msg':_0x221d67('0x541')+_0x37cacb[_0x221d67('0x1a17')]}),_0x37cacb[_0x221d67('0x1a17')]&&_0x3f4334['cmHopperHistory']['save'](_0x1d86a4(_0x2bce90));})[_0x3628dd('0x1a80')](function(_0x457796){const _0x3de7ab=_0x3628dd;!_0x2cfb05()[_0x3de7ab('0x2863')](_0x457796[_0x3de7ab('0x25f4')])&&_0x457796[_0x3de7ab('0x25f4')]['message']==='Validation\x20error'?_0x178959['info']({'title':'The\x20contact\x20is\x20in\x20the\x20hopper','msg':_0x3de7ab('0x541')+_0x2bce90[_0x3de7ab('0x1a17')]}):_0x178959[_0x3de7ab('0xfc9')]({'title':_0x457796['status']?_0x3de7ab('0x1e21')+_0x457796[_0x3de7ab('0x52d')]+_0x3de7ab('0x11e1')+_0x457796[_0x3de7ab('0xe1b')]:_0x3de7ab('0x1c74'),'msg':_0x457796['data']?JSON['stringify'](_0x457796['data'][_0x3de7ab('0x1e70')]):_0x457796[_0x3de7ab('0x1e70')]||_0x457796[_0x3de7ab('0x1586')]()});}):_0x178959[_0x3628dd('0xfc9')]({'title':_0x134c7b[_0x3628dd('0x52d')]?_0x3628dd('0x1e21')+_0x134c7b[_0x3628dd('0x52d')]+_0x3628dd('0x11e1')+_0x134c7b[_0x3628dd('0xe1b')]:_0x3628dd('0x1c74'),'msg':_0x134c7b[_0x3628dd('0x25f4')]?JSON[_0x3628dd('0xbac')](_0x134c7b[_0x3628dd('0x25f4')]['message']):_0x134c7b[_0x3628dd('0x1e70')]||_0x134c7b[_0x3628dd('0x1586')]()});});}let _0x432e8c=!![],_0x1fdf16=0x1;_0xcff8c8[_0x5bfc18('0xe83')](_0x5bfc18('0x28b4'),function(_0x50a7eb,_0x302950){const _0x33dcaf=_0x5bfc18;_0x432e8c?_0x31e399(function(){_0x432e8c=![];}):(!_0x302950&&(_0x1fdf16=_0xd1be92[_0x33dcaf('0x2218')][_0x33dcaf('0x1a43')]),_0x50a7eb!==_0x302950&&(_0xd1be92[_0x33dcaf('0x2218')][_0x33dcaf('0x1a43')]=0x1),!_0x50a7eb&&(_0xd1be92[_0x33dcaf('0x2218')]['page']=_0x1fdf16),_0x229ca5());});}const _0x393f20=_0xb03c91;_0xe2d7e2['$inject']=['$cookies',_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0xe2d7e2(_0xaceb35,_0x58b566,_0x397fa7,_0xc2dcb7,_0x2ca5d1,_0x3c7d58,_0x448d28,_0x92fe01,_0xb0bfed,_0x1208e4,_0x562c2f){const _0x1e9215=_0x36e6f4,_0x50f987=this;_0x50f987[_0x1e9215('0x98')]=_0x562c2f[_0x1e9215('0x26cd')](),_0x50f987[_0x1e9215('0x1915')]={},_0x50f987['queueCampaignHopperHistories']={'count':0x0,'rows':[]},_0x50f987[_0x1e9215('0x19ee')]=[],_0x50f987['crudPermissions'],_0x50f987[_0x1e9215('0x2218')]={'fields':_0x1e9215('0xcf1'),'sort':_0x1e9215('0x83'),'limit':0xa,'page':0x1},_0x50f987[_0x1e9215('0x24d5')]=_0x3ebac3,_0x50f987[_0x1e9215('0x8a2')]=_0x21efa4,_0x50f987['success']=_0x350fdd,_0x50f987[_0x1e9215('0x11af')]=_0x10d39d,_0x50f987[_0x1e9215('0x11f6')]=_0x3e7b01,_0x50f987['deleteQueueCampaignHopperHistory']=_0x38266c,_0x50f987[_0x1e9215('0x6be')]=_0x4c7bdb;function _0x3ebac3(_0x46d79c,_0x18023a){const _0x467dbf=_0x1e9215;_0x50f987[_0x467dbf('0x1915')]=_0x46d79c,_0x50f987[_0x467dbf('0x243c')]=typeof _0x18023a!==_0x467dbf('0x1048')?_0x18023a:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x50f987['query'][_0x467dbf('0xc69')]=_0x50f987[_0x467dbf('0x1915')]['id'],_0x50f987['query']['id']=_0x50f987['queueCampaign']['id'],_0x10d39d();}function _0x21efa4(_0xf08821,_0xc07805){const _0x1fc367=_0x1e9215,_0x882f1=_0x448d28[_0x1fc367('0x1d26')]()[_0x1fc367('0xcdc')](_0x1fc367('0x19b5'))[_0x1fc367('0xf3c')](_0x1fc367('0x12b5')+(_0xf08821[_0x1fc367('0x4f0')]||_0xf08821['id']&&_0x2cfb05()[_0x1fc367('0x114b')](_0x1fc367('0x1b4d'))+_0xf08821['id']||_0x1fc367('0x1946'))+''+_0x1fc367('0x3f3'))[_0x1fc367('0x8e8')]('delete\x20hopperHistory')[_0x1fc367('0x203b')](_0xc07805)['ok']('OK')['cancel'](_0x1fc367('0x2d3'));_0x448d28[_0x1fc367('0x1f80')](_0x882f1)[_0x1fc367('0x1166')](function(){_0x38266c(_0xf08821);},function(){const _0x13ee44=_0x1fc367;console[_0x13ee44('0x455')](_0x13ee44('0x2d3'));});}function _0x350fdd(_0x57f12b){const _0x24d3c1=_0x1e9215;_0x50f987[_0x24d3c1('0x59')]=_0x57f12b||{'count':0x0,'rows':[]};}function _0x10d39d(){const _0x43136e=_0x1e9215;_0x50f987['query'][_0x43136e('0x1098')]=(_0x50f987[_0x43136e('0x2218')][_0x43136e('0x1a43')]-0x1)*_0x50f987[_0x43136e('0x2218')][_0x43136e('0x163f')],_0x50f987[_0x43136e('0x1f48')]=_0x1208e4[_0x43136e('0x1943')][_0x43136e('0x2825')](_0x50f987[_0x43136e('0x2218')],_0x350fdd)[_0x43136e('0xa44')];}function _0x38266c(_0x3b0a60){const _0x59fedc=_0x1e9215;_0x1208e4[_0x59fedc('0x1946')][_0x59fedc('0x906')]({'id':_0x3b0a60['id']})['$promise'][_0x59fedc('0x1166')](function(){const _0x50f85e=_0x59fedc;_0x2cfb05()['remove'](_0x50f987[_0x50f85e('0x59')][_0x50f85e('0x269a')],{'id':_0x3b0a60['id']}),_0x50f987[_0x50f85e('0x59')]['count']-=0x1,!_0x50f987[_0x50f85e('0x59')]['rows']['length']&&_0x10d39d(),_0xb0bfed[_0x50f85e('0x103b')]({'title':_0x50f85e('0x1887'),'msg':_0x3b0a60[_0x50f85e('0x4f0')]?_0x3b0a60['name']+_0x50f85e('0x7cd'):''});})[_0x59fedc('0x1a80')](function(_0x930872){const _0x3895e6=_0x59fedc;if(_0x930872[_0x3895e6('0x25f4')]&&_0x930872['data'][_0x3895e6('0x61a')]&&_0x930872['data'][_0x3895e6('0x61a')]['length']){_0x50f987['errors']=_0x930872[_0x3895e6('0x25f4')][_0x3895e6('0x61a')]||[{'message':_0x930872[_0x3895e6('0x1586')](),'type':_0x3895e6('0x1c74')}];for(let _0x29f4a2=0x0;_0x29f4a2<_0x930872[_0x3895e6('0x25f4')][_0x3895e6('0x61a')]['length'];_0x29f4a2++){_0xb0bfed['error']({'title':_0x930872[_0x3895e6('0x25f4')][_0x3895e6('0x61a')][_0x29f4a2][_0x3895e6('0x1345')],'msg':_0x930872['data']['errors'][_0x29f4a2][_0x3895e6('0x1e70')]});}}else _0xb0bfed[_0x3895e6('0xfc9')]({'title':_0x930872[_0x3895e6('0x52d')]?'API:'+_0x930872[_0x3895e6('0x52d')]+_0x3895e6('0x11e1')+_0x930872['statusText']:_0x3895e6('0x1c74'),'msg':_0x930872[_0x3895e6('0x25f4')]?JSON[_0x3895e6('0xbac')](_0x930872[_0x3895e6('0x25f4')][_0x3895e6('0x1e70')]):_0x930872['message']||_0x930872[_0x3895e6('0x1586')]()});});}function _0x3e7b01(){const _0x2156d0=_0x1e9215,_0xa8dd9d=angular['copy'](_0x50f987[_0x2156d0('0x19ee')]);return _0x50f987[_0x2156d0('0x19ee')]=[],_0xa8dd9d;}function _0x4c7bdb(_0x58c53c){const _0x1d61bd=_0x1e9215,_0x485f96=_0x448d28[_0x1d61bd('0x1d26')]()[_0x1d61bd('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20hopperHistories?')[_0x1d61bd('0xf3c')](_0x1d61bd('0x12b5')+_0x50f987[_0x1d61bd('0x19ee')][_0x1d61bd('0x264b')]+'\x20selected'+_0x1d61bd('0x3f3'))[_0x1d61bd('0x8e8')](_0x1d61bd('0x1710'))['targetEvent'](_0x58c53c)['ok']('OK')[_0x1d61bd('0x3f')](_0x1d61bd('0x2d3'));_0x448d28['show'](_0x485f96)[_0x1d61bd('0x1166')](function(){const _0x401c3b=_0x1d61bd;_0x50f987[_0x401c3b('0x19ee')][_0x401c3b('0x2782')](function(_0x21c8a7){_0x38266c(_0x21c8a7);}),_0x50f987[_0x401c3b('0x19ee')]=[];});}let _0x2c0016=!![],_0x5c5297=0x1;_0x58b566['$watch']('vm_dc.query.filter',function(_0x2ef5b9,_0x44fd04){const _0x3f93db=_0x1e9215;_0x2c0016?_0x3c7d58(function(){_0x2c0016=![];}):(!_0x44fd04&&(_0x5c5297=_0x50f987[_0x3f93db('0x2218')][_0x3f93db('0x1a43')]),_0x2ef5b9!==_0x44fd04&&(_0x50f987['query'][_0x3f93db('0x1a43')]=0x1),!_0x2ef5b9&&(_0x50f987[_0x3f93db('0x2218')]['page']=_0x5c5297),_0x10d39d());});}const _0x4b4815=_0xe2d7e2;_0x1ac467[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),_0x36e6f4('0x36f'),'$state','$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0x1ac467(_0x6f590c,_0x3494de,_0x5554cb,_0x5efc6d,_0x511fca,_0x5232ca,_0x3a0b22,_0xf728eb,_0x293a72,_0x5e9f1a,_0x3f1ec9){const _0x5add7f=_0x36e6f4,_0x38f432=this;_0x38f432[_0x5add7f('0x98')]=_0x3f1ec9[_0x5add7f('0x26cd')](),_0x38f432['queueCampaign']={},_0x38f432['queueCampaignHoppers']={'count':0x0,'rows':[]},_0x38f432['selectedQueueCampaignHoppers']=[],_0x38f432[_0x5add7f('0x243c')],_0x38f432[_0x5add7f('0x2218')]={'fields':_0x5add7f('0x16dc'),'sort':_0x5add7f('0x14dc'),'limit':0xa,'page':0x1},_0x38f432[_0x5add7f('0x1ccc')]=_0x2cfb05()['keyBy']([{'option':_0x5add7f('0xb06'),'value':_0x5add7f('0x5d')},{'option':'High','value':'\x273\x27'},{'option':_0x5add7f('0x3e9'),'value':_0x5add7f('0x246e')},{'option':'Low','value':_0x5add7f('0x54e')},{'option':_0x5add7f('0x4'),'value':_0x5add7f('0x125f')}],function(_0x3acb9d){const _0x1ffd76=_0x5add7f;return _0x2cfb05()[_0x1ffd76('0xf3')](_0x3acb9d['value'],new RegExp('\x27','g'),'');}),_0x38f432['init']=_0x12c42d,_0x38f432[_0x5add7f('0x8a2')]=_0x5c132b,_0x38f432['success']=_0x527179,_0x38f432[_0x5add7f('0x2364')]=_0x45fe78,_0x38f432['createOrEditQueueCampaignHopper']=_0x5d7c68,_0x38f432[_0x5add7f('0xfe0')]=_0x2e67dc,_0x38f432[_0x5add7f('0xc70')]=_0x34daf2,_0x38f432[_0x5add7f('0x2448')]=_0x19513d,_0x3f1ec9[_0x5add7f('0x1ac6')]('admin')?_0x5e9f1a[_0x5add7f('0x557')][_0x5add7f('0xd83')]({'fields':_0x5add7f('0x1776'),'role':'agent','sort':_0x5add7f('0x4f0'),'nolimit':_0x5add7f('0xf3b')})[_0x5add7f('0xa44')][_0x5add7f('0x1166')](function(_0x3ecf57){const _0x4adddb=_0x5add7f;_0x38f432[_0x4adddb('0x1f7e')]=_0x3ecf57[_0x4adddb('0x269a')]||[];})[_0x5add7f('0x1a80')](function(_0x5b5f93){const _0x6e33d7=_0x5add7f;_0x293a72[_0x6e33d7('0xfc9')]({'title':_0x5b5f93['status']?'API:'+_0x5b5f93[_0x6e33d7('0x52d')]+_0x6e33d7('0x11e1')+_0x5b5f93[_0x6e33d7('0xe1b')]:_0x6e33d7('0xd4c'),'msg':_0x5b5f93[_0x6e33d7('0x25f4')]?JSON['stringify'](_0x5b5f93[_0x6e33d7('0x25f4')]):_0x5b5f93[_0x6e33d7('0x1586')]()});}):_0x5e9f1a[_0x5add7f('0x557')][_0x5add7f('0xd83')]({'fields':_0x5add7f('0x1776'),'role':_0x5add7f('0x1eff'),'sort':_0x5add7f('0x4f0'),'nolimit':_0x5add7f('0xf3b')})[_0x5add7f('0xa44')][_0x5add7f('0x1166')](function(_0x471b0f){const _0x4f7b5f=_0x5add7f;_0x38f432[_0x4f7b5f('0x1f7e')]=_0x471b0f[_0x4f7b5f('0x269a')]||[];})[_0x5add7f('0x1166')](function(){const _0x289c16=_0x5add7f;return _0x5e9f1a[_0x289c16('0x17aa')][_0x289c16('0xd83')]({'userProfileId':_0x38f432[_0x289c16('0x98')][_0x289c16('0xb86')],'sectionId':0xca})['$promise'];})[_0x5add7f('0x1166')](function(_0x4537b5){const _0x1bdee2=_0x5add7f,_0x4c64bd=_0x4537b5&&_0x4537b5[_0x1bdee2('0x269a')]?_0x4537b5[_0x1bdee2('0x269a')][0x0]:null;if(!_0x4c64bd){const _0x3b8fe5=[];let _0x1d3714=null;_0x38f432[_0x1bdee2('0x1915')]&&(_0x1d3714=_0x2cfb05()[_0x1bdee2('0xc38')](_0x38f432[_0x1bdee2('0x1f7e')],{'id':Number(_0x38f432[_0x1bdee2('0x1915')][_0x1bdee2('0x122a')])}));for(let _0x54498b=0x0;_0x54498b<_0x38f432[_0x1bdee2('0x1f7e')]['length'];_0x54498b++){_0x1d3714&&_0x38f432[_0x1bdee2('0x1f7e')][_0x54498b]['id']===_0x1d3714['id']&&(_0x38f432[_0x1bdee2('0x1f7e')][_0x54498b][_0x1bdee2('0x2378')]=![],_0x3b8fe5[_0x1bdee2('0x1514')](_0x38f432['agents'][_0x54498b]));}_0x38f432[_0x1bdee2('0x1f7e')]=_0x3b8fe5;}else{if(!_0x4c64bd['autoAssociation'])return _0x5e9f1a[_0x1bdee2('0x4b5')][_0x1bdee2('0xd83')]({'sectionId':_0x4c64bd['id']})[_0x1bdee2('0xa44')][_0x1bdee2('0x1166')](function(_0x4945f4){const _0x408519=_0x1bdee2,_0x31b61a=_0x2cfb05()[_0x408519('0x2563')](_0x4945f4['rows'],function(_0x3aa2fb){const _0x114714=_0x408519;return _0x2cfb05()[_0x114714('0xc38')](_0x38f432[_0x114714('0x1f7e')],{'id':_0x3aa2fb[_0x114714('0x24e8')]});});let _0x52c8f0=null;_0x38f432[_0x408519('0x1915')]&&(_0x52c8f0=_0x2cfb05()[_0x408519('0xc38')](_0x38f432[_0x408519('0x1f7e')],{'id':Number(_0x38f432[_0x408519('0x1915')][_0x408519('0x122a')])}));if(_0x52c8f0&&!_0x2cfb05()['some'](_0x31b61a,['id',_0x52c8f0['id']])){const _0x45813e=_0x2cfb05()['find'](_0x38f432['agents'],{'id':_0x52c8f0['id']});_0x45813e[_0x408519('0x2378')]=![],_0x31b61a[_0x408519('0x1514')](_0x45813e);}_0x38f432[_0x408519('0x1f7e')]=_0x31b61a;});}})['catch'](function(_0x5f3296){const _0x2b451d=_0x5add7f;_0x293a72[_0x2b451d('0xfc9')]({'title':_0x5f3296[_0x2b451d('0x52d')]?_0x2b451d('0x1e21')+_0x5f3296[_0x2b451d('0x52d')]+'\x20-\x20'+_0x5f3296['statusText']:_0x2b451d('0xdc5'),'msg':_0x5f3296[_0x2b451d('0x25f4')]?JSON['stringify'](_0x5f3296[_0x2b451d('0x25f4')]):_0x5f3296[_0x2b451d('0x1586')]()});});function _0x12c42d(_0x2f83fa,_0x1c292f){const _0x1aedca=_0x5add7f;_0x38f432[_0x1aedca('0x1915')]=_0x2f83fa,_0x38f432[_0x1aedca('0x243c')]=typeof _0x1c292f!==_0x1aedca('0x1048')?_0x1c292f:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x38f432['query']['VoiceQueueId']=_0x38f432[_0x1aedca('0x1915')]['id'],_0x38f432[_0x1aedca('0x2218')]['id']=_0x38f432[_0x1aedca('0x1915')]['id'],_0x45fe78();}function _0x5c132b(_0x5dc842,_0x524366){const _0x5592c0=_0x5add7f,_0xd045e8=_0x3a0b22[_0x5592c0('0x1d26')]()['title'](_0x5592c0('0x186e'))[_0x5592c0('0xf3c')](_0x5592c0('0x12b5')+(_0x5dc842[_0x5592c0('0x4f0')]||_0x5dc842['id']&&_0x2cfb05()['upperFirst'](_0x5592c0('0xee8'))+_0x5dc842['id']||'hopper')+_0x5592c0('0xace')+_0x5592c0('0x3f3'))[_0x5592c0('0x8e8')]('delete\x20hopper')[_0x5592c0('0x203b')](_0x524366)['ok']('OK')[_0x5592c0('0x3f')]('CANCEL');_0x3a0b22[_0x5592c0('0x1f80')](_0xd045e8)[_0x5592c0('0x1166')](function(){_0x34daf2(_0x5dc842);},function(){const _0x3940e4=_0x5592c0;console[_0x3940e4('0x455')](_0x3940e4('0x2d3'));});}function _0x527179(_0x1af958){const _0x27fe37=_0x5add7f;_0x38f432[_0x27fe37('0xd2c')]=_0x1af958||{'count':0x0,'rows':[]};}function _0x45fe78(){const _0x12de0=_0x5add7f;_0x38f432[_0x12de0('0x2218')][_0x12de0('0x1098')]=(_0x38f432[_0x12de0('0x2218')][_0x12de0('0x1a43')]-0x1)*_0x38f432[_0x12de0('0x2218')][_0x12de0('0x163f')],_0x38f432['promise']=_0x5e9f1a['voiceQueue'][_0x12de0('0xfee')](_0x38f432[_0x12de0('0x2218')],_0x527179)[_0x12de0('0xa44')];}function _0x5d7c68(_0x26cd61,_0x47831b){const _0x37d2bf=_0x5add7f;_0x3a0b22[_0x37d2bf('0x1f80')]({'controller':_0x37d2bf('0x1c8c'),'controllerAs':'vm','templateUrl':_0x8db371,'parent':angular[_0x37d2bf('0x1194')](_0xf728eb[_0x37d2bf('0x8d2')]),'targetEvent':_0x26cd61,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x38f432['queueCampaign'],'hopper':_0x47831b,'hoppers':_0x38f432[_0x37d2bf('0xd2c')][_0x37d2bf('0x269a')],'license':null,'setting':null,'crudPermissions':_0x38f432[_0x37d2bf('0x243c')]}});}function _0x34daf2(_0x37b3b8){const _0x475624=_0x5add7f;_0x5e9f1a[_0x475624('0x256a')][_0x475624('0x906')]({'id':_0x37b3b8['id']})[_0x475624('0xa44')][_0x475624('0x1166')](function(){const _0x45c54a=_0x475624;_0x2cfb05()[_0x45c54a('0x127f')](_0x38f432[_0x45c54a('0xd2c')][_0x45c54a('0x269a')],{'id':_0x37b3b8['id']}),_0x38f432['queueCampaignHoppers']['count']-=0x1,!_0x38f432[_0x45c54a('0xd2c')][_0x45c54a('0x269a')][_0x45c54a('0x264b')]&&_0x45fe78(),_0x293a72[_0x45c54a('0x103b')]({'title':'Hopper\x20deleted!','msg':_0x37b3b8['name']?_0x37b3b8['name']+_0x45c54a('0x7cd'):''});})[_0x475624('0x1a80')](function(_0x160ed6){const _0x7dbe0e=_0x475624;if(_0x160ed6[_0x7dbe0e('0x25f4')]&&_0x160ed6[_0x7dbe0e('0x25f4')][_0x7dbe0e('0x61a')]&&_0x160ed6[_0x7dbe0e('0x25f4')][_0x7dbe0e('0x61a')][_0x7dbe0e('0x264b')]){_0x38f432[_0x7dbe0e('0x61a')]=_0x160ed6[_0x7dbe0e('0x25f4')][_0x7dbe0e('0x61a')]||[{'message':_0x160ed6[_0x7dbe0e('0x1586')](),'type':_0x7dbe0e('0x1c74')}];for(let _0x11d129=0x0;_0x11d129<_0x160ed6['data'][_0x7dbe0e('0x61a')][_0x7dbe0e('0x264b')];_0x11d129++){_0x293a72['error']({'title':_0x160ed6[_0x7dbe0e('0x25f4')]['errors'][_0x11d129][_0x7dbe0e('0x1345')],'msg':_0x160ed6['data']['errors'][_0x11d129][_0x7dbe0e('0x1e70')]});}}else _0x293a72[_0x7dbe0e('0xfc9')]({'title':_0x160ed6[_0x7dbe0e('0x52d')]?_0x7dbe0e('0x1e21')+_0x160ed6[_0x7dbe0e('0x52d')]+_0x7dbe0e('0x11e1')+_0x160ed6[_0x7dbe0e('0xe1b')]:_0x7dbe0e('0x1c74'),'msg':_0x160ed6[_0x7dbe0e('0x25f4')]?JSON[_0x7dbe0e('0xbac')](_0x160ed6['data'][_0x7dbe0e('0x1e70')]):_0x160ed6[_0x7dbe0e('0x1e70')]||_0x160ed6[_0x7dbe0e('0x1586')]()});});}function _0x2e67dc(){const _0xa39ac6=_0x5add7f,_0x453b7f=angular[_0xa39ac6('0x225f')](_0x38f432[_0xa39ac6('0x2304')]);return _0x38f432[_0xa39ac6('0x2304')]=[],_0x453b7f;}function _0x19513d(_0x5b146b){const _0xe9b408=_0x5add7f,_0x4f5032=_0x3a0b22[_0xe9b408('0x1d26')]()[_0xe9b408('0xcdc')](_0xe9b408('0x16be'))['htmlContent'](''+_0x38f432['selectedQueueCampaignHoppers'][_0xe9b408('0x264b')]+_0xe9b408('0x196d')+_0xe9b408('0x3f3'))[_0xe9b408('0x8e8')](_0xe9b408('0x242e'))[_0xe9b408('0x203b')](_0x5b146b)['ok']('OK')[_0xe9b408('0x3f')](_0xe9b408('0x2d3'));_0x3a0b22[_0xe9b408('0x1f80')](_0x4f5032)[_0xe9b408('0x1166')](function(){const _0x1d137e=_0xe9b408;_0x38f432[_0x1d137e('0x2304')][_0x1d137e('0x2782')](function(_0x5bd403){_0x34daf2(_0x5bd403);}),_0x38f432[_0x1d137e('0x2304')]=[];});}let _0x492048=!![],_0x50b85b=0x1;_0x3494de[_0x5add7f('0xe83')]('vm_dc.query.filter',function(_0x3349e1,_0x41a00d){const _0x2fbbc5=_0x5add7f;_0x492048?_0x5232ca(function(){_0x492048=![];}):(!_0x41a00d&&(_0x50b85b=_0x38f432[_0x2fbbc5('0x2218')][_0x2fbbc5('0x1a43')]),_0x3349e1!==_0x41a00d&&(_0x38f432[_0x2fbbc5('0x2218')][_0x2fbbc5('0x1a43')]=0x1),!_0x3349e1&&(_0x38f432[_0x2fbbc5('0x2218')][_0x2fbbc5('0x1a43')]=_0x50b85b),_0x45fe78());});}const _0x26b5ec=_0x1ac467;_0x54f592[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state','$location','$mdDialog','$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),'hoppers',_0x36e6f4('0x1d98'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x54f592(_0x205db5,_0x51a165,_0x2fdce6,_0x49a1bf,_0x39433a,_0x281d5d,_0x1e14e6,_0x4b4770,_0x3dc0a5,_0x4ccb43,_0x5c4c0a,_0x340448,_0x39267d,_0x4a49e8){const _0x1a6047=_0x36e6f4,_0x1bf49c=this;_0x1bf49c[_0x1a6047('0x98')]=_0x5c4c0a[_0x1a6047('0x26cd')](),_0x1bf49c[_0x1a6047('0x61a')]=[],_0x1bf49c[_0x1a6047('0xf8a')]=_0x39267d,_0x1bf49c[_0x1a6047('0x5c9')]=_0x340448,_0x1bf49c[_0x1a6047('0x243c')]=_0x4a49e8,_0x1bf49c[_0x1a6047('0x128b')]={},_0x1bf49c[_0x1a6047('0x2900')]=_0x1bf49c['setting']&&_0x1bf49c[_0x1a6047('0xf8a')][_0x1a6047('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1bf49c[_0x1a6047('0xcdc')]=_0x1a6047('0xc'),_0x1bf49c[_0x1a6047('0x1d98')]=angular[_0x1a6047('0x225f')](_0x3dc0a5),_0x1bf49c[_0x1a6047('0x28c4')]=_0x4b4770,_0x1bf49c[_0x1a6047('0x1e01')]=![];!_0x1bf49c[_0x1a6047('0x1d98')]&&(_0x1bf49c['hopper']={},_0x1bf49c[_0x1a6047('0xcdc')]=_0x1a6047('0x47a'),_0x1bf49c[_0x1a6047('0x1e01')]=!![]);_0x51a165[_0x1a6047('0x23f')]['id']&&(_0x1bf49c['hopper']['VoiceQueueId']=_0x51a165[_0x1a6047('0x23f')]['id']);_0x1bf49c[_0x1a6047('0x2576')]=_0x250c30,_0x1bf49c[_0x1a6047('0x8bd')]=_0x1479f0,_0x1bf49c[_0x1a6047('0x2526')]=_0x3f2643,_0x1bf49c[_0x1a6047('0x1a9c')]=_0xed9e58,_0x1bf49c[_0x1a6047('0x24a0')]=_0x3971fe,_0x5c4c0a[_0x1a6047('0x1ac6')](_0x1a6047('0xa7c'))?_0x4ccb43['user'][_0x1a6047('0xd83')]({'fields':_0x1a6047('0x1776'),'role':_0x1a6047('0x1eff'),'sort':_0x1a6047('0x4f0'),'nolimit':_0x1a6047('0xf3b')})[_0x1a6047('0xa44')][_0x1a6047('0x1166')](function(_0x23af2f){_0x1bf49c['agents']=_0x23af2f['rows']||[];})['catch'](function(_0x328888){const _0xa92cba=_0x1a6047;_0x1e14e6[_0xa92cba('0xfc9')]({'title':_0x328888['status']?_0xa92cba('0x1e21')+_0x328888[_0xa92cba('0x52d')]+_0xa92cba('0x11e1')+_0x328888['statusText']:_0xa92cba('0xd4c'),'msg':_0x328888[_0xa92cba('0x25f4')]?JSON['stringify'](_0x328888['data']):_0x328888[_0xa92cba('0x1586')]()});}):_0x4ccb43[_0x1a6047('0x557')][_0x1a6047('0xd83')]({'fields':_0x1a6047('0x1776'),'role':_0x1a6047('0x1eff'),'sort':_0x1a6047('0x4f0'),'nolimit':'true'})[_0x1a6047('0xa44')][_0x1a6047('0x1166')](function(_0x35e910){const _0x163922=_0x1a6047;_0x1bf49c[_0x163922('0x1f7e')]=_0x35e910[_0x163922('0x269a')]||[];})[_0x1a6047('0x1166')](function(){const _0x2bee9f=_0x1a6047;return _0x4ccb43['userProfileSection'][_0x2bee9f('0xd83')]({'userProfileId':_0x1bf49c[_0x2bee9f('0x98')][_0x2bee9f('0xb86')],'sectionId':0xca})['$promise'];})[_0x1a6047('0x1166')](function(_0x1414e6){const _0x42b224=_0x1a6047,_0x2a85c2=_0x1414e6&&_0x1414e6[_0x42b224('0x269a')]?_0x1414e6['rows'][0x0]:null;if(!_0x2a85c2){const _0x2309ba=[];let _0x3db21a=null;_0x1bf49c[_0x42b224('0x1d98')]&&(_0x3db21a=_0x2cfb05()[_0x42b224('0xc38')](_0x1bf49c[_0x42b224('0x1f7e')],{'id':Number(_0x1bf49c[_0x42b224('0x1d98')][_0x42b224('0x122a')])}));for(let _0x5c8d8e=0x0;_0x5c8d8e<_0x1bf49c[_0x42b224('0x1f7e')]['length'];_0x5c8d8e++){_0x3db21a&&_0x1bf49c[_0x42b224('0x1f7e')][_0x5c8d8e]['id']===_0x3db21a['id']&&(_0x1bf49c['agents'][_0x5c8d8e]['canSelect']=![],_0x2309ba[_0x42b224('0x1514')](_0x1bf49c['agents'][_0x5c8d8e]));}_0x1bf49c[_0x42b224('0x1f7e')]=_0x2309ba;}else{if(!_0x2a85c2[_0x42b224('0x1a2b')])return _0x4ccb43['userProfileResource'][_0x42b224('0xd83')]({'sectionId':_0x2a85c2['id']})['$promise']['then'](function(_0x272e5b){const _0x50035e=_0x42b224,_0x4137e7=_0x2cfb05()[_0x50035e('0x2563')](_0x272e5b['rows'],function(_0x4e978c){const _0x516dc3=_0x50035e;return _0x2cfb05()[_0x516dc3('0xc38')](_0x1bf49c['agents'],{'id':_0x4e978c[_0x516dc3('0x24e8')]});});let _0x3a5191=null;_0x1bf49c[_0x50035e('0x1d98')]&&(_0x3a5191=_0x2cfb05()[_0x50035e('0xc38')](_0x1bf49c[_0x50035e('0x1f7e')],{'id':Number(_0x1bf49c[_0x50035e('0x1d98')][_0x50035e('0x122a')])}));if(_0x3a5191&&!_0x2cfb05()['some'](_0x4137e7,['id',_0x3a5191['id']])){const _0x148ab5=_0x2cfb05()[_0x50035e('0xc38')](_0x1bf49c[_0x50035e('0x1f7e')],{'id':_0x3a5191['id']});_0x148ab5[_0x50035e('0x2378')]=![],_0x4137e7[_0x50035e('0x1514')](_0x148ab5);}_0x1bf49c[_0x50035e('0x1f7e')]=_0x4137e7;});}})[_0x1a6047('0x1a80')](function(_0x90ced9){const _0x542c70=_0x1a6047;_0x1e14e6['error']({'title':_0x90ced9['status']?_0x542c70('0x1e21')+_0x90ced9['status']+_0x542c70('0x11e1')+_0x90ced9[_0x542c70('0xe1b')]:'SYSTEM:GETagents','msg':_0x90ced9[_0x542c70('0x25f4')]?JSON['stringify'](_0x90ced9['data']):_0x90ced9['toString']()});});function _0x250c30(){const _0x5643ca=_0x1a6047;_0x1bf49c['errors']=[],_0x4ccb43[_0x5643ca('0x256a')]['save'](_0x1bf49c['hopper'])[_0x5643ca('0xa44')][_0x5643ca('0x1166')](function(_0x45857b){const _0x24e058=_0x5643ca;_0x1bf49c[_0x24e058('0x28c4')][_0x24e058('0x2450')](_0x45857b[_0x24e058('0x2876')]()),_0x1e14e6[_0x24e058('0x103b')]({'title':_0x24e058('0x1371'),'msg':_0x1bf49c[_0x24e058('0x1d98')][_0x24e058('0x4f0')]?_0x1bf49c[_0x24e058('0x1d98')][_0x24e058('0x4f0')]+'\x20has\x20been\x20created!':''}),_0x3971fe(_0x45857b);})[_0x5643ca('0x1a80')](function(_0x576812){const _0x211888=_0x5643ca;if(_0x576812['data']&&_0x576812['data']['errors']&&_0x576812[_0x211888('0x25f4')][_0x211888('0x61a')][_0x211888('0x264b')]){_0x1bf49c[_0x211888('0x61a')]=_0x576812[_0x211888('0x25f4')][_0x211888('0x61a')]||[{'message':_0x576812[_0x211888('0x1586')](),'type':'api.cmHopper.save'}];for(let _0x53134d=0x0;_0x53134d<_0x576812[_0x211888('0x25f4')][_0x211888('0x61a')][_0x211888('0x264b')];_0x53134d+=0x1){_0x1e14e6[_0x211888('0xfc9')]({'title':_0x576812['data'][_0x211888('0x61a')][_0x53134d][_0x211888('0x1345')],'msg':_0x576812[_0x211888('0x25f4')][_0x211888('0x61a')][_0x53134d][_0x211888('0x1e70')]});}}else _0x1e14e6['error']({'title':_0x576812[_0x211888('0x52d')]?_0x211888('0x1e21')+_0x576812[_0x211888('0x52d')]+'\x20-\x20'+_0x576812[_0x211888('0xe1b')]:_0x211888('0x2594'),'msg':_0x576812[_0x211888('0x25f4')]?JSON[_0x211888('0xbac')](_0x576812[_0x211888('0x25f4')][_0x211888('0x1e70')]):_0x576812[_0x211888('0x1586')]()});});}function _0x1479f0(){const _0x57bb48=_0x1a6047;_0x1bf49c[_0x57bb48('0x61a')]=[];let _0x4f937d,_0x315ccb,_0xbf7f2d,_0xb9eb1e;_0x1bf49c[_0x57bb48('0x1d98')][_0x57bb48('0x122a')]=_0x1bf49c[_0x57bb48('0x1d98')]['recallme']?_0x1bf49c[_0x57bb48('0x1d98')][_0x57bb48('0x122a')]:null,_0x1bf49c['hopper'][_0x57bb48('0x2520')]=_0x5c4c0a[_0x57bb48('0x26cd')]()['id'],_0x4ccb43[_0x57bb48('0x256a')]['get']({'id':_0x1bf49c['hopper']['id'],'attributes':['scheduledat']})['$promise'][_0x57bb48('0x1166')](function(_0x4929a2){const _0x23c384=_0x57bb48;_0x2cfb05()[_0x23c384('0x2863')](_0x4929a2)||_0x2cfb05()['isEmpty'](_0x4929a2)?_0x4f937d=_0x24273b()()[_0x23c384('0x128a')](_0x23c384('0x1084')):_0x4f937d=_0x4929a2['scheduledat'];})[_0x57bb48('0x1951')](function(){const _0x36e735=_0x57bb48;_0x4ccb43[_0x36e735('0x256a')]['update']({'id':_0x1bf49c[_0x36e735('0x1d98')]['id']},_0x2cfb05()[_0x36e735('0x1414')](_0x1bf49c[_0x36e735('0x1d98')],['VoiceQueueId',_0x36e735('0xd88'),_0x36e735('0x1a17'),_0x36e735('0x23c')]))['$promise'][_0x36e735('0x1166')](function(_0xb83d28){const _0x227c7b=_0x36e735;_0x315ccb=_0xb83d28,_0x4ccb43[_0x227c7b('0x149e')]['get']({'id':_0x315ccb[_0x227c7b('0x1a17')],'attributes':[_0x227c7b('0x18cb'),_0x227c7b('0xeb0')]})[_0x227c7b('0xa44')][_0x227c7b('0x1166')](function(_0x2c3116){const _0x54642a=_0x227c7b;!_0x2cfb05()[_0x54642a('0x2863')](_0x2c3116)&&!_0x2cfb05()[_0x54642a('0x2863')](_0x2c3116[_0x54642a('0x18cb')])&&(_0xbf7f2d=_0x2c3116[_0x54642a('0x18cb')],!_0x2cfb05()[_0x54642a('0x2863')](_0x2c3116[_0x54642a('0xeb0')])&&(_0xbf7f2d+='\x20'+_0x2c3116[_0x54642a('0xeb0')]));})[_0x227c7b('0x1a80')](function(){_0xbf7f2d=undefined;})[_0x227c7b('0x1951')](function(){const _0x444718=_0x227c7b;_0x4ccb43[_0x444718('0x1943')][_0x444718('0xd83')]({'raw':![],'id':_0x315ccb[_0x444718('0xc69')],'attributes':[_0x444718('0x4f0')]})['$promise'][_0x444718('0x1166')](function(_0x28f14c){const _0x568e44=_0x444718;_0xb9eb1e=_0x28f14c[_0x568e44('0x4f0')];})[_0x444718('0x1a80')](function(){_0xb9eb1e=undefined;})[_0x444718('0x1951')](function(){const _0x55e561=_0x444718;_0x4ccb43['cmHopperHistory'][_0x55e561('0x9cc')]({'state':0x18,'statedesc':_0x55e561('0xb8d'),'scheduledat':_0x4f937d,'calleridnum':_0x315ccb['phone'],'calleridname':_0xbf7f2d,'campaigntype':_0x315ccb['VoiceQueueId']?_0x55e561('0x1d3e'):_0x55e561('0x681'),'campaign':_0xb9eb1e,'editedat':_0x24273b()()[_0x55e561('0x128a')](_0x55e561('0x1084')),'edited':!![],'ListId':_0x315ccb['ListId'],'UserId':_0x5c4c0a[_0x55e561('0x26cd')]()['id'],'VoiceQueueId':_0x315ccb['VoiceQueueId'],'CampaignId':_0x315ccb[_0x55e561('0xd88')],'ContactId':_0x315ccb[_0x55e561('0x1a17')],'callback':_0x315ccb[_0x55e561('0x1eb')],'callbackuniqueid':_0x315ccb[_0x55e561('0xff')],'countbusyretry':_0x315ccb[_0x55e561('0x1736')],'countcongestionretry':_0x315ccb['countcongestionretry'],'countglobal':_0x315ccb['countglobal'],'countnoanswerretry':_0x315ccb[_0x55e561('0x1c7')],'followuptime':_0x315ccb[_0x55e561('0x8be')],'recallme':_0x315ccb[_0x55e561('0xc10')]});});});const _0xe0aa54=_0x2cfb05()['find'](_0x1bf49c[_0x227c7b('0x28c4')],{'id':_0xb83d28['id']});_0xe0aa54&&_0x2cfb05()[_0x227c7b('0xcc3')](_0xe0aa54,_0x2cfb05()[_0x227c7b('0x1a08')](_0xb83d28[_0x227c7b('0x2876')](),_0x2cfb05()[_0x227c7b('0x14a4')](_0xe0aa54))),_0x1e14e6['success']({'title':_0x227c7b('0x108f'),'msg':_0x1bf49c[_0x227c7b('0x1d98')]['name']?_0x1bf49c[_0x227c7b('0x1d98')]['name']+_0x227c7b('0x7d'):''}),_0x3971fe(_0xb83d28);})[_0x36e735('0x1a80')](function(_0x284b02){const _0x2df6c2=_0x36e735;if(_0x284b02['data']&&_0x284b02[_0x2df6c2('0x25f4')]['errors']&&_0x284b02['data']['errors']['length']){_0x1bf49c['errors']=_0x284b02['data'][_0x2df6c2('0x61a')]||[{'message':_0x284b02[_0x2df6c2('0x1586')](),'type':_0x2df6c2('0xd28')}];for(let _0x4ef418=0x0;_0x4ef418<_0x284b02[_0x2df6c2('0x25f4')]['errors'][_0x2df6c2('0x264b')];_0x4ef418++){_0x1e14e6[_0x2df6c2('0xfc9')]({'title':_0x284b02[_0x2df6c2('0x25f4')]['errors'][_0x4ef418]['type'],'msg':_0x284b02[_0x2df6c2('0x25f4')][_0x2df6c2('0x61a')][_0x4ef418]['message']});}}else _0x1e14e6['error']({'title':_0x284b02[_0x2df6c2('0x52d')]?_0x2df6c2('0x1e21')+_0x284b02[_0x2df6c2('0x52d')]+_0x2df6c2('0x11e1')+_0x284b02[_0x2df6c2('0xe1b')]:_0x2df6c2('0xd28'),'msg':_0x284b02[_0x2df6c2('0x25f4')]?JSON[_0x2df6c2('0xbac')](_0x284b02['data'][_0x2df6c2('0x1e70')]):_0x284b02[_0x2df6c2('0x1586')]()});});});}function _0x3f2643(_0x9e535f){const _0x3e58b6=_0x1a6047;_0x1bf49c['errors']=[];const _0x2ddece=_0x49a1bf['confirm']()['title'](_0x3e58b6('0x7fb'))[_0x3e58b6('0xacc')](_0x3e58b6('0xe6c'))[_0x3e58b6('0x8e8')]('Delete\x20Hopper')['ok'](_0x3e58b6('0x18'))[_0x3e58b6('0x3f')](_0x3e58b6('0x497'))[_0x3e58b6('0x203b')](_0x9e535f);_0x49a1bf['show'](_0x2ddece)['then'](function(){const _0x438429=_0x3e58b6;_0x4ccb43['cmHopper']['delete']({'id':_0x1bf49c[_0x438429('0x1d98')]['id']})[_0x438429('0xa44')][_0x438429('0x1166')](function(){const _0x121109=_0x438429;_0x2cfb05()[_0x121109('0x127f')](_0x1bf49c[_0x121109('0x28c4')],{'id':_0x1bf49c[_0x121109('0x1d98')]['id']}),_0x1e14e6['success']({'title':_0x121109('0x40a'),'msg':(_0x1bf49c[_0x121109('0x1d98')][_0x121109('0x4f0')]||_0x121109('0x1d98'))+_0x121109('0x7cd')}),_0x3971fe(_0x1bf49c[_0x121109('0x1d98')]);})[_0x438429('0x1a80')](function(_0x274797){const _0x30475a=_0x438429;if(_0x274797['data']&&_0x274797[_0x30475a('0x25f4')][_0x30475a('0x61a')]&&_0x274797[_0x30475a('0x25f4')]['errors'][_0x30475a('0x264b')]){_0x1bf49c['errors']=_0x274797['data'][_0x30475a('0x61a')]||[{'message':_0x274797['toString'](),'type':_0x30475a('0x14fb')}];for(let _0x399710=0x0;_0x399710<_0x274797[_0x30475a('0x25f4')][_0x30475a('0x61a')][_0x30475a('0x264b')];_0x399710++){_0x1e14e6['error']({'title':_0x274797[_0x30475a('0x25f4')][_0x30475a('0x61a')][_0x399710][_0x30475a('0x1345')],'msg':_0x274797[_0x30475a('0x25f4')]['errors'][_0x399710]['message']});}}else _0x1e14e6[_0x30475a('0xfc9')]({'title':_0x274797[_0x30475a('0x52d')]?'API:'+_0x274797[_0x30475a('0x52d')]+_0x30475a('0x11e1')+_0x274797[_0x30475a('0xe1b')]:_0x30475a('0x14fb'),'msg':_0x274797[_0x30475a('0x25f4')]?JSON[_0x30475a('0xbac')](_0x274797[_0x30475a('0x25f4')][_0x30475a('0x1e70')]):_0x274797[_0x30475a('0x1e70')]||_0x274797[_0x30475a('0x1586')]()});});},function(){});}function _0xed9e58(_0x53954d){return _0x53954d===null?undefined:new Date(_0x53954d);}function _0x3971fe(_0x447177){const _0x353491=_0x1a6047;_0x49a1bf[_0x353491('0x1197')](_0x447177);}}const _0x32ac7c=_0x54f592;_0x18e929[_0x36e6f4('0x1294')]=['api',_0x36e6f4('0x1d2e')];function _0x18e929(_0x459f37,_0x372c2d){const _0x2e328e=_0x36e6f4,_0x116c29=this;_0x116c29[_0x2e328e('0x1915')]={},_0x116c29[_0x2e328e('0x24d5')]=_0x2fc9b8;function _0x2fc9b8(_0x4dca4c){const _0x83f11a=_0x2e328e;_0x116c29['queueCampaign']=_0x4dca4c,_0x459f37[_0x83f11a('0x256a')][_0x83f11a('0xd83')]({'limit':0x0,'VoiceQueueId':_0x4dca4c['id']})[_0x83f11a('0xa44')]['then'](function(_0x4e07ee){const _0x47ccd4=_0x83f11a;return _0x116c29[_0x47ccd4('0x25e7')]=_0x4e07ee[_0x47ccd4('0x240f')]||0x0,_0x459f37[_0x47ccd4('0x256a')][_0x47ccd4('0xd83')]({'limit':0x0,'VoiceQueueId':_0x4dca4c['id'],'active':![],'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0})['$promise'];})[_0x83f11a('0x1166')](function(_0x10387a){const _0xbfded9=_0x83f11a;return _0x116c29[_0xbfded9('0xaef')]=_0x10387a[_0xbfded9('0x240f')]||0x0,_0x459f37[_0xbfded9('0x1806')][_0xbfded9('0xd83')]({'limit':0x0,'VoiceQueueId':_0x4dca4c['id']})[_0xbfded9('0xa44')];})[_0x83f11a('0x1166')](function(_0x1afd26){const _0x24abb0=_0x83f11a;_0x116c29['closed']=_0x1afd26[_0x24abb0('0x240f')]||0x0;})['catch'](function(_0x454b7c){const _0x5df013=_0x83f11a;_0x372c2d[_0x5df013('0xfc9')]({'title':_0x454b7c[_0x5df013('0x52d')]?'API:'+_0x454b7c[_0x5df013('0x52d')]+_0x5df013('0x11e1')+_0x454b7c[_0x5df013('0xe1b')]:'SYSTEM:GETTAGS','msg':_0x454b7c[_0x5df013('0x25f4')]?JSON[_0x5df013('0xbac')](_0x454b7c[_0x5df013('0x25f4')]):_0x454b7c[_0x5df013('0x1586')]()});});}}const _0x1cb31a=_0x18e929;_0x51f14f['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1915'),_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x51f14f(_0x71c7e2,_0x11fe95,_0x5d439f,_0x3d0b18,_0x1b2be9,_0x37c13f,_0x3ab9ce,_0x2b06fa,_0x1eb181){const _0x410159=_0x36e6f4,_0x32d146=this;_0x32d146[_0x410159('0x98')]=_0x2b06fa[_0x410159('0x26cd')](),_0x32d146[_0x410159('0x1915')]=_0x1b2be9,_0x32d146[_0x410159('0x243c')]=_0x1eb181,_0x32d146[_0x410159('0x19dc')]='voiceQueue',_0x32d146[_0x410159('0x1bb3')]=_0x410159('0x5a1'),_0x32d146[_0x410159('0x7dd')]=_0x410159('0x1e0b'),_0x32d146[_0x410159('0x10d1')]=_0x410159('0xed4'),_0x32d146[_0x410159('0xbd7')]=[],_0x32d146[_0x410159('0x10ab')]=[],_0x32d146['selectedItems']=[],_0x32d146[_0x410159('0x2111')]=[],_0x32d146[_0x410159('0x2781')]=[],_0x32d146['pendingChanges']=![],_0x32d146[_0x410159('0x34b')]=![],_0x32d146['dualMultiselectOptions']={'readOnly':!_0x32d146['crudPermissions'][_0x410159('0x1684')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':![],'orderBy':_0x410159('0x4f0'),'line1':_0x410159('0x4f0'),'line2':'','line3':'','labelAll':_0x37c13f[_0x410159('0x25cc')](_0x410159('0x1676')),'labelSelected':_0x37c13f['instant'](_0x410159('0x834')),'transferCallback':function(){const _0x55bac7=_0x410159,_0x15f9bf=_0x2cfb05()['xorBy'](_0x32d146[_0x55bac7('0x2781')],_0x32d146['selectedItems'],'id');_0x32d146['pendingChanges']=_0x2cfb05()[_0x55bac7('0x1081')](_0x15f9bf)?![]:!![];}},_0x32d146['onInit']=_0x139200,_0x32d146[_0x410159('0x12a9')]=_0x132ec1,_0x32d146['closeDialog']=_0x59644d;function _0x139200(){const _0x252b40=_0x410159;return _0x2b06fa[_0x252b40('0x1ac6')](_0x252b40('0xa7c'))?_0x43da76()[_0x252b40('0x1a80')](function(_0x22e090){const _0x5bcb0d=_0x252b40;_0x5d439f['error']({'title':_0x22e090[_0x5bcb0d('0x52d')]?_0x5bcb0d('0x1e21')+_0x22e090[_0x5bcb0d('0x52d')]+_0x5bcb0d('0x11e1')+_0x22e090[_0x5bcb0d('0xe1b')]:_0x5bcb0d('0x14e6'),'msg':_0x22e090[_0x5bcb0d('0x52d')]?JSON[_0x5bcb0d('0xbac')](_0x22e090[_0x5bcb0d('0x25f4')]):_0x22e090[_0x5bcb0d('0x1586')]()});}):_0x1c671e()['then'](function(_0x36c743){const _0x4f4f50=_0x252b40;return _0x32d146[_0x4f4f50('0xe60')]=_0x36c743,_0x43da76();})['catch'](function(_0x54fcf7){const _0x1a55ed=_0x252b40;_0x5d439f[_0x1a55ed('0xfc9')]({'title':_0x54fcf7[_0x1a55ed('0x52d')]?'API:'+_0x54fcf7[_0x1a55ed('0x52d')]+_0x1a55ed('0x11e1')+_0x54fcf7['statusText']:_0x1a55ed('0x14e6'),'msg':_0x54fcf7['status']?JSON[_0x1a55ed('0xbac')](_0x54fcf7['data']):_0x54fcf7['toString']()});});}function _0x1c671e(){return _0x11fe95(function(_0x5dcf9a,_0x56b85e){const _0x1b3262=a0_0x3f2c;_0x3d0b18[_0x1b3262('0x17aa')][_0x1b3262('0xd83')]({'userProfileId':_0x32d146[_0x1b3262('0x98')][_0x1b3262('0xb86')],'name':_0x1b3262('0x1cae')})[_0x1b3262('0xa44')][_0x1b3262('0x1166')](function(_0x59db61){const _0x13ef1d=_0x1b3262,_0x3dd402=_0x59db61&&_0x59db61[_0x13ef1d('0x269a')]?_0x59db61[_0x13ef1d('0x269a')][0x0]:null;_0x5dcf9a(_0x3dd402);})[_0x1b3262('0x1a80')](function(_0x15aa4f){_0x56b85e(_0x15aa4f);});});}function _0x43da76(){return _0x11fe95(function(_0x394e26,_0x24143e){const _0x5218f5=a0_0x3f2c;return _0x3de7f4()[_0x5218f5('0x1166')](function(_0x44e567){const _0x3f2236=_0x5218f5;return _0x32d146[_0x3f2236('0xbd7')]=_0x44e567[_0x3f2236('0x269a')]?_0x44e567[_0x3f2236('0x269a')]:[],_0x2b06fa[_0x3f2236('0x1ac6')](_0x3f2236('0xa7c'))?_0x44e567:_0x32d146[_0x3f2236('0xe60')]?_0x32d146[_0x3f2236('0xe60')][_0x3f2236('0x1a2b')]?_0x44e567:_0x5ed34c():null;})['then'](function(_0x42cb94){const _0x2c710a=_0x5218f5,_0x155ea7=_0x42cb94&&_0x42cb94[_0x2c710a('0x269a')]?_0x42cb94[_0x2c710a('0x269a')]:[];return _0x32d146[_0x2c710a('0x10ab')]=_0x2cfb05()[_0x2c710a('0x2563')](_0x155ea7,function(_0x2ab5d7){const _0x1f92af=_0x2c710a;return _0x2cfb05()[_0x1f92af('0xc38')](_0x32d146[_0x1f92af('0xbd7')],{'id':_0x2b06fa['hasRole'](_0x1f92af('0xa7c'))||_0x32d146[_0x1f92af('0xe60')][_0x1f92af('0x1a2b')]?_0x2ab5d7['id']:_0x2ab5d7['resourceId']});}),_0x32d146[_0x2c710a('0x2111')]=angular[_0x2c710a('0x225f')](_0x32d146[_0x2c710a('0x10ab')]),_0x32d146[_0x2c710a('0xbd7')]['forEach'](function(_0x213c16){const _0x316f37=_0x2c710a,_0x56026b=_0x2cfb05()[_0x316f37('0xc38')](_0x32d146[_0x316f37('0x10ab')],{'id':_0x213c16['id']});_0x32d146[_0x316f37('0x98')]['role']==='admin'?_0x213c16[_0x316f37('0x26ef')]=!![]:_0x213c16[_0x316f37('0x26ef')]=typeof _0x56026b!==_0x316f37('0x1048')?!![]:![];}),_0x55ce99();})[_0x5218f5('0x1166')](function(_0x15421c){const _0x28e3ec=_0x5218f5,_0x21838f=_0x15421c&&_0x15421c['rows']?_0x15421c['rows']:[];_0x32d146['selectedItems']=_0x2cfb05()['map'](_0x21838f,function(_0x401b4a){const _0x90184d=a0_0x3f2c;return _0x2cfb05()['find'](_0x32d146[_0x90184d('0xbd7')],{'id':_0x401b4a['id']});}),_0x32d146[_0x28e3ec('0x2781')]=angular[_0x28e3ec('0x225f')](_0x32d146[_0x28e3ec('0x18e1')]),_0x32d146['dualMultiselectOptions']['selectedItems']=_0x32d146[_0x28e3ec('0x18e1')],_0x32d146[_0x28e3ec('0xc68')][_0x28e3ec('0xbd7')]=_0x2cfb05()['differenceBy'](_0x32d146[_0x28e3ec('0x10ab')],_0x32d146['dualMultiselectOptions']['selectedItems'],'id'),_0x394e26();})[_0x5218f5('0x1a80')](function(_0x5a15a4){_0x24143e(_0x5a15a4);});});}function _0x5ed34c(){return _0x11fe95(function(_0xb9aea5,_0x240dea){const _0x524e8e=a0_0x3f2c;return _0x3d0b18['userProfileResource'][_0x524e8e('0xd83')]({'sectionId':_0x32d146[_0x524e8e('0xe60')]['id'],'nolimit':!![]})[_0x524e8e('0xa44')][_0x524e8e('0x1166')](function(_0x27950e){_0xb9aea5(_0x27950e);})[_0x524e8e('0x1a80')](function(_0x57a98c){_0x240dea(_0x57a98c);});});}function _0x55ce99(){return _0x11fe95(function(_0x290e5c,_0x4776a2){const _0x574f1f=a0_0x3f2c,_0x143166=_0x3d0b18[_0x32d146[_0x574f1f('0x19dc')]];return _0x143166[_0x32d146[_0x574f1f('0x1bb3')]]({'id':_0x32d146[_0x574f1f('0x1915')]['id'],'fields':'id,name','nolimit':!![]})['$promise']['then'](function(_0x2c5502){_0x290e5c(_0x2c5502);})[_0x574f1f('0x1a80')](function(_0xc1b53e){_0x4776a2(_0xc1b53e);});});}function _0x3de7f4(){return _0x11fe95(function(_0x365901,_0x2997a5){const _0x54cd64=a0_0x3f2c;return _0x3d0b18['cmList']['get']({'fields':_0x54cd64('0x1776'),'nolimit':!![]})[_0x54cd64('0xa44')][_0x54cd64('0x1166')](function(_0x133dae){_0x365901(_0x133dae);})[_0x54cd64('0x1a80')](function(_0x45ff69){_0x2997a5(_0x45ff69);});});}function _0x14262e(_0x26fd2d){return _0x11fe95(function(_0x25a6e0,_0x59886f){const _0x34640c=a0_0x3f2c;if(_0x2cfb05()[_0x34640c('0x1081')](_0x26fd2d))_0x25a6e0();else{const _0x5f47c2=_0x3d0b18[_0x32d146['apiRoute']];_0x5f47c2[_0x32d146[_0x34640c('0x7dd')]]({'id':_0x32d146[_0x34640c('0x1915')]['id'],'ids':_0x2cfb05()[_0x34640c('0x2563')](_0x26fd2d,'id')})['$promise']['then'](function(){_0x25a6e0();})[_0x34640c('0x1a80')](function(_0x2d181c){_0x59886f(_0x2d181c);});}});}function _0x1cdcb1(_0x5d6f65){return _0x11fe95(function(_0x5e980f,_0x121118){const _0x56425d=a0_0x3f2c;if(_0x2cfb05()[_0x56425d('0x1081')](_0x5d6f65))_0x5e980f();else{const _0x43eb6c=_0x3d0b18[_0x32d146[_0x56425d('0x19dc')]];_0x43eb6c[_0x32d146[_0x56425d('0x10d1')]]({'id':_0x32d146['queueCampaign']['id'],'ids':_0x2cfb05()['map'](_0x5d6f65,'id')})[_0x56425d('0xa44')][_0x56425d('0x1166')](function(){_0x5e980f();})['catch'](function(_0x3193a6){_0x121118(_0x3193a6);});}});}function _0x132ec1(){const _0x2ba123=_0x410159;_0x32d146[_0x2ba123('0x34b')]=!![];const _0x4bf0cc=_0x2cfb05()['differenceBy'](_0x32d146['startingSelectedItems'],_0x32d146[_0x2ba123('0x18e1')],'id'),_0x1f5b7f=_0x2cfb05()[_0x2ba123('0x24ac')](_0x32d146['selectedItems'],_0x32d146[_0x2ba123('0x2781')],'id');return _0x1cdcb1(_0x4bf0cc)['then'](function(){return _0x14262e(_0x1f5b7f);})[_0x2ba123('0x1166')](function(){const _0x1dffa5=_0x2ba123;_0x32d146[_0x1dffa5('0x14d7')]=![],_0x32d146[_0x1dffa5('0x2111')]=angular['copy'](_0x32d146[_0x1dffa5('0x10ab')]),_0x32d146['startingSelectedItems']=angular['copy'](_0x32d146[_0x1dffa5('0x18e1')]),_0x5d439f[_0x1dffa5('0x103b')]({'title':_0x1dffa5('0x983'),'msg':_0x1dffa5('0x9ed')});})['catch'](function(_0x3db299){const _0x83124f=_0x2ba123;_0x5d439f[_0x83124f('0xfc9')]({'title':_0x3db299[_0x83124f('0x52d')]?_0x83124f('0x1e21')+_0x3db299['status']+_0x83124f('0x11e1')+_0x3db299[_0x83124f('0xe1b')]:_0x83124f('0x1b29'),'msg':_0x3db299[_0x83124f('0x52d')]?JSON['stringify'](_0x3db299['data']):_0x3db299[_0x83124f('0x1586')]()});})['finally'](function(){const _0x7b1af0=_0x2ba123;_0x32d146[_0x7b1af0('0x34b')]=![];});}function _0x59644d(){const _0x314fff=_0x410159;_0x71c7e2[_0x314fff('0x1197')]();}}const _0x46701c=_0x51f14f;_0x1a0a51[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x1915'),_0x36e6f4('0x1075'),_0x36e6f4('0x1e7e'),'$q'];function _0x1a0a51(_0x425b11,_0x20a36f,_0x5b6c74,_0x5ce1d9,_0x4187cf,_0x179a18,_0x19bdb7,_0x479325){const _0x37491e=_0x36e6f4,_0xfcc5a2=this;_0xfcc5a2[_0x37491e('0x1300')]=[],_0xfcc5a2['items']=_0x179a18?_0x179a18:[],_0xfcc5a2[_0x37491e('0x34b')]=![],_0xfcc5a2[_0x37491e('0x24a0')]=_0x370d60,_0xfcc5a2['exists']=_0x48fd6f,_0xfcc5a2[_0x37491e('0xc60')]=_0x3cba8e,_0xfcc5a2[_0x37491e('0x27b5')]=_0x299c1f,_0xfcc5a2[_0x37491e('0x154e')]=_0x36c59c,_0xfcc5a2[_0x37491e('0xe50')]=_0x413e69,_0xfcc5a2['listSelected']=_0x5e374d;function _0x3cba8e(_0x3c0fbe,_0x3bd12c){const _0x24cecf=_0x37491e,_0x55ec92=_0x3bd12c[_0x24cecf('0x2379')](_0x3c0fbe);_0x55ec92>-0x1?_0x3bd12c['splice'](_0x55ec92,0x1):_0x3bd12c[_0x24cecf('0x1514')](_0x3c0fbe);}function _0x48fd6f(_0x455e50,_0x41fb25){const _0x27dfd6=_0x37491e;return _0x41fb25[_0x27dfd6('0x2379')](_0x455e50)>-0x1;}function _0x299c1f(){const _0x317974=_0x37491e;return _0xfcc5a2[_0x317974('0x1300')][_0x317974('0x264b')]!==0x0&&_0xfcc5a2['selected'][_0x317974('0x264b')]!==_0xfcc5a2['items']['length'];}function _0x36c59c(){const _0x5ef6fe=_0x37491e;return _0xfcc5a2[_0x5ef6fe('0x1300')][_0x5ef6fe('0x264b')]===_0xfcc5a2[_0x5ef6fe('0xbd7')][_0x5ef6fe('0x264b')];}function _0x413e69(){const _0x17fbf7=_0x37491e;if(_0xfcc5a2[_0x17fbf7('0x1300')][_0x17fbf7('0x264b')]===_0xfcc5a2[_0x17fbf7('0xbd7')][_0x17fbf7('0x264b')])_0xfcc5a2['selected']=[];else(_0xfcc5a2['selected']['length']===0x0||_0xfcc5a2[_0x17fbf7('0x1300')][_0x17fbf7('0x264b')]>0x0)&&(_0xfcc5a2[_0x17fbf7('0x1300')]=_0xfcc5a2[_0x17fbf7('0xbd7')][_0x17fbf7('0x233')](0x0));}function _0x370d60(){const _0x324a87=_0x37491e;_0x20a36f[_0x324a87('0x1197')]();}function _0x5e374d(){const _0x420c0f=_0x37491e;_0xfcc5a2[_0x420c0f('0x34b')]=!![];const _0x4640b4=_0x5e5672();_0x4640b4[_0x420c0f('0x1951')](function(){const _0xa65644=_0x420c0f;_0xfcc5a2[_0xa65644('0x34b')]=![],_0x370d60();});}function _0x5e5672(){return _0x479325(function(_0x2c266a){const _0x31a674=a0_0x3f2c;for(let _0x1fe349=0x0;_0x1fe349<_0xfcc5a2[_0x31a674('0x1300')][_0x31a674('0x264b')];_0x1fe349+=0x1){_0x3b1282(_0x4187cf['id'],_0xfcc5a2[_0x31a674('0x1300')][_0x1fe349]);}_0x13d97f(_0x2c266a);});}function _0x3b1282(_0x3cb957,_0x1da8ed){const _0x594c78=_0x37491e,_0x1b8ebb=_0x1da8ed['id'];_0x19bdb7[_0x594c78('0x370')](function(){const _0x191fa7=_0x594c78;return _0x5ce1d9[_0x191fa7('0x1943')][_0x191fa7('0xed4')]({'id':_0x3cb957,'ids':_0x1b8ebb})[_0x191fa7('0xa44')][_0x191fa7('0x1166')](function(){const _0x202f9b=_0x191fa7;return _0x5ce1d9[_0x202f9b('0x1943')]['addLists']({'id':_0x3cb957,'ids':_0x1b8ebb,'dialCheckDuplicateType':_0x202f9b('0x122f')})['$promise'];})[_0x191fa7('0x1166')](function(){const _0x1146e4=_0x191fa7;_0x5b6c74[_0x1146e4('0x103b')]({'title':_0x1146e4('0xc7e'),'msg':_0x1146e4('0xdac')+_0x1da8ed['name']+_0x1146e4('0x25e4')});})['catch'](function(_0x5672be){const _0x838b5c=_0x191fa7;_0x5b6c74[_0x838b5c('0xfc9')]({'title':_0x5672be[_0x838b5c('0x52d')]?'API:'+_0x5672be[_0x838b5c('0x52d')]+_0x838b5c('0x11e1')+_0x5672be[_0x838b5c('0xe1b')]:_0x838b5c('0x26f9'),'msg':_0x5672be['status']?JSON[_0x838b5c('0xbac')](_0x5672be['data']):_0x5672be['toString']()});});});}function _0x13d97f(_0x3b9e08){const _0x27646e=_0x37491e;_0x19bdb7[_0x27646e('0x370')](function(){return _0x3b9e08();});}}const _0x27a58f=_0x1a0a51;_0x1dd39f[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'queueCampaign',_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x1dd39f(_0x10f56b,_0x31f96b,_0x493fef,_0x495bb9,_0xc36bea,_0x4c49a3,_0x59433e,_0x29dc6f){const _0x3da761=_0x36e6f4,_0x50fcbd=this;_0x50fcbd[_0x3da761('0x98')]=_0x59433e[_0x3da761('0x26cd')](),_0x50fcbd[_0x3da761('0x1915')]=_0xc36bea,_0x50fcbd[_0x3da761('0x243c')]=_0x29dc6f,_0x50fcbd['penalty']=0x0,_0x50fcbd[_0x3da761('0xbd7')]=[],_0x50fcbd[_0x3da761('0x10ab')]=[],_0x50fcbd[_0x3da761('0x18e1')]=[],_0x50fcbd[_0x3da761('0x2111')]=[],_0x50fcbd[_0x3da761('0x2781')]=[],_0x50fcbd[_0x3da761('0x14d7')]=![],_0x50fcbd[_0x3da761('0xc68')]={'readOnly':!_0x50fcbd[_0x3da761('0x243c')][_0x3da761('0x1684')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x3da761('0x4f0'),'line1':_0x3da761('0x4f0'),'line2':'','line3':'','labelAll':_0x4c49a3[_0x3da761('0x25cc')](_0x3da761('0x20ef')),'labelSelected':_0x4c49a3[_0x3da761('0x25cc')](_0x3da761('0x21a6')),'transferCallback':function(_0x4f4498,_0x1beae1){const _0x3e0cea=_0x3da761;_0x1beae1?_0x4f4498['forEach'](function(_0x68c42c){const _0x527af9=a0_0x3f2c;_0x68c42c[_0x527af9('0x23af')]=undefined;}):_0x4f4498['forEach'](function(_0x55d69f){const _0x3c1333=a0_0x3f2c;_0x55d69f['penalty']=_0x3c1333('0x11e8')+_0x50fcbd['penalty'];});const _0x4c7e9b=_0x2cfb05()[_0x3e0cea('0x2802')](_0x50fcbd[_0x3e0cea('0x2781')],_0x50fcbd[_0x3e0cea('0x18e1')],'id');_0x50fcbd[_0x3e0cea('0x14d7')]=_0x2cfb05()[_0x3e0cea('0x1081')](_0x4c7e9b)?![]:!![];}},_0x50fcbd[_0x3da761('0xae0')]=_0x21771c,_0x50fcbd[_0x3da761('0x1add')]=_0x911fdb,_0x50fcbd[_0x3da761('0x24a0')]=_0x16606e;function _0x21771c(){const _0x154440=_0x3da761;return _0x59433e[_0x154440('0x1ac6')]('admin')?_0x4b9ddb()[_0x154440('0x1a80')](function(_0x3331f8){const _0x397ba2=_0x154440;_0x493fef[_0x397ba2('0xfc9')]({'title':_0x3331f8['status']?_0x397ba2('0x1e21')+_0x3331f8[_0x397ba2('0x52d')]+'\x20-\x20'+_0x3331f8[_0x397ba2('0xe1b')]:_0x397ba2('0x1031'),'msg':_0x3331f8['status']?JSON[_0x397ba2('0xbac')](_0x3331f8[_0x397ba2('0x25f4')]):_0x3331f8['toString']()});}):_0x2297c9()['then'](function(_0x1d9545){return _0x50fcbd['section']=_0x1d9545,_0x4b9ddb();})[_0x154440('0x1a80')](function(_0x2a8e0e){const _0x1a2593=_0x154440;_0x493fef[_0x1a2593('0xfc9')]({'title':_0x2a8e0e[_0x1a2593('0x52d')]?'API:'+_0x2a8e0e[_0x1a2593('0x52d')]+_0x1a2593('0x11e1')+_0x2a8e0e['statusText']:_0x1a2593('0x1031'),'msg':_0x2a8e0e['status']?JSON[_0x1a2593('0xbac')](_0x2a8e0e[_0x1a2593('0x25f4')]):_0x2a8e0e[_0x1a2593('0x1586')]()});});}function _0x2297c9(){return _0x31f96b(function(_0x33ca6a,_0x13aa9e){const _0x142644=a0_0x3f2c;_0x495bb9['userProfileSection'][_0x142644('0xd83')]({'userProfileId':_0x50fcbd[_0x142644('0x98')]['userProfileId'],'name':_0x142644('0x289e')})['$promise'][_0x142644('0x1166')](function(_0x1a92df){const _0x2800b3=_0x142644,_0x46e006=_0x1a92df&&_0x1a92df[_0x2800b3('0x269a')]?_0x1a92df['rows'][0x0]:null;_0x33ca6a(_0x46e006);})['catch'](function(_0x1718db){_0x13aa9e(_0x1718db);});});}function _0x4b9ddb(){return _0x31f96b(function(_0x52f6a8,_0x45bc06){const _0xed6c2c=a0_0x3f2c;return _0x3d1b6e()[_0xed6c2c('0x1166')](function(_0x8e3bc7){const _0x4438c8=_0xed6c2c;return _0x50fcbd[_0x4438c8('0xbd7')]=_0x8e3bc7[_0x4438c8('0x269a')]?_0x8e3bc7['rows']:[],_0x59433e[_0x4438c8('0x1ac6')](_0x4438c8('0xa7c'))?_0x8e3bc7:_0x50fcbd[_0x4438c8('0xe60')]?_0x50fcbd[_0x4438c8('0xe60')][_0x4438c8('0x1a2b')]?_0x8e3bc7:_0x311ed4():null;})[_0xed6c2c('0x1166')](function(_0x5ca42d){const _0x77eacd=_0xed6c2c,_0xe11ebb=_0x5ca42d&&_0x5ca42d[_0x77eacd('0x269a')]?_0x5ca42d['rows']:[];return _0x50fcbd[_0x77eacd('0x10ab')]=_0x2cfb05()[_0x77eacd('0x2563')](_0xe11ebb,function(_0x44b919){const _0x12d932=_0x77eacd;return _0x2cfb05()[_0x12d932('0xc38')](_0x50fcbd[_0x12d932('0xbd7')],{'id':_0x59433e[_0x12d932('0x1ac6')](_0x12d932('0xa7c'))||_0x50fcbd['section']['autoAssociation']?_0x44b919['id']:_0x44b919[_0x12d932('0x24e8')]});}),_0x50fcbd[_0x77eacd('0xbd7')][_0x77eacd('0x2782')](function(_0x573fc0){const _0x5d5a00=_0x77eacd,_0x39e6da=_0x2cfb05()[_0x5d5a00('0xc38')](_0x50fcbd[_0x5d5a00('0x10ab')],{'id':_0x573fc0['id']});_0x59433e[_0x5d5a00('0x1ac6')](_0x5d5a00('0xa7c'))?_0x573fc0[_0x5d5a00('0x26ef')]=!![]:_0x573fc0[_0x5d5a00('0x26ef')]=typeof _0x39e6da!==_0x5d5a00('0x1048')?!![]:![];}),_0x16bb6c();})[_0xed6c2c('0x1166')](function(_0x16bf57){const _0xaa95d3=_0xed6c2c,_0x5e239b=_0x16bf57&&_0x16bf57[_0xaa95d3('0x269a')]?_0x16bf57[_0xaa95d3('0x269a')]:[];_0x50fcbd[_0xaa95d3('0x18e1')]=_0x2cfb05()[_0xaa95d3('0x2563')](_0x5e239b,function(_0x1e9b1b){const _0x487e47=_0xaa95d3;return _0x2cfb05()[_0x487e47('0xc38')](_0x50fcbd[_0x487e47('0xbd7')],{'id':_0x1e9b1b['id']});}),_0x50fcbd[_0xaa95d3('0x2781')]=angular[_0xaa95d3('0x225f')](_0x50fcbd['selectedItems']),_0x50fcbd[_0xaa95d3('0xc68')][_0xaa95d3('0x18e1')]=_0x50fcbd[_0xaa95d3('0x18e1')],_0x50fcbd[_0xaa95d3('0xc68')][_0xaa95d3('0xbd7')]=_0x2cfb05()[_0xaa95d3('0x24ac')](_0x50fcbd['allowedItems'],_0x50fcbd[_0xaa95d3('0xc68')][_0xaa95d3('0x18e1')],'id'),_0x52f6a8();})[_0xed6c2c('0x1a80')](function(_0x1c2b53){_0x45bc06(_0x1c2b53);});});}function _0x311ed4(){return _0x31f96b(function(_0x36f66e,_0x18ed31){const _0xd8c3eb=a0_0x3f2c;return _0x495bb9['userProfileResource']['get']({'sectionId':_0x50fcbd[_0xd8c3eb('0xe60')]['id'],'nolimit':!![]})[_0xd8c3eb('0xa44')][_0xd8c3eb('0x1166')](function(_0x2d3141){_0x36f66e(_0x2d3141);})[_0xd8c3eb('0x1a80')](function(_0x38aa57){_0x18ed31(_0x38aa57);});});}function _0x16bb6c(){return _0x31f96b(function(_0x3006c3,_0xbb75dd){const _0x30681b=a0_0x3f2c;return _0x495bb9[_0x30681b('0x1943')][_0x30681b('0x1448')]({'id':_0x50fcbd['queueCampaign']['id'],'fields':'id,name','nolimit':!![]})[_0x30681b('0xa44')][_0x30681b('0x1166')](function(_0x4293ce){_0x3006c3(_0x4293ce);})[_0x30681b('0x1a80')](function(_0x5f16e6){_0xbb75dd(_0x5f16e6);});});}function _0x3d1b6e(){return _0x31f96b(function(_0x59039f,_0x55bc14){const _0x3a0d23=a0_0x3f2c;return _0x495bb9[_0x3a0d23('0x1e37')][_0x3a0d23('0xd83')]({'fields':_0x3a0d23('0x1776'),'nolimit':!![]})['$promise'][_0x3a0d23('0x1166')](function(_0x42af27){_0x59039f(_0x42af27);})[_0x3a0d23('0x1a80')](function(_0x32079d){_0x55bc14(_0x32079d);});});}function _0x579ac5(_0x2846a1){return _0x31f96b(function(_0xc2c2b4,_0xec301){const _0x24a992=a0_0x3f2c;if(_0x2cfb05()['isEmpty'](_0x2846a1))_0xc2c2b4();else{const _0x39836b=_0x2cfb05()['map'](_0x2846a1,function(_0x320061){const _0x1bece8=a0_0x3f2c;return{'id':_0x320061['id'],'penalty':_0x2cfb05()[_0x1bece8('0x1f49')](_0x320061[_0x1bece8('0x23af')],'penalty\x20')};});return _0x495bb9[_0x24a992('0x1943')][_0x24a992('0x16e0')]({'id':_0x50fcbd[_0x24a992('0x1915')]['id'],'teams':_0x39836b})['$promise'][_0x24a992('0x1166')](function(){_0xc2c2b4();})[_0x24a992('0x1a80')](function(_0x3c9d22){_0xec301(_0x3c9d22);});}});}function _0x578f5f(_0x5c0b9d){return _0x31f96b(function(_0x83ba94,_0x586d15){const _0x13c645=a0_0x3f2c;_0x2cfb05()[_0x13c645('0x1081')](_0x5c0b9d)?_0x83ba94():_0x495bb9['voiceQueue'][_0x13c645('0x8f')]({'id':_0x50fcbd[_0x13c645('0x1915')]['id'],'ids':_0x2cfb05()['map'](_0x5c0b9d,'id')})[_0x13c645('0xa44')]['then'](function(){_0x83ba94();})[_0x13c645('0x1a80')](function(_0x1af6c5){_0x586d15(_0x1af6c5);});});}function _0x911fdb(){const _0x5252d0=_0x3da761,_0x2ce98d=_0x2cfb05()[_0x5252d0('0x24ac')](_0x50fcbd['startingSelectedItems'],_0x50fcbd[_0x5252d0('0x18e1')],'id'),_0x3bf81f=_0x2cfb05()[_0x5252d0('0x24ac')](_0x50fcbd['selectedItems'],_0x50fcbd[_0x5252d0('0x2781')],'id');return _0x578f5f(_0x2ce98d)['then'](function(){return _0x579ac5(_0x3bf81f);})[_0x5252d0('0x1166')](function(){const _0x19afb6=_0x5252d0;_0x50fcbd[_0x19afb6('0x14d7')]=![],_0x50fcbd[_0x19afb6('0x2111')]=angular['copy'](_0x50fcbd[_0x19afb6('0x10ab')]),_0x50fcbd['startingSelectedItems']=angular[_0x19afb6('0x225f')](_0x50fcbd[_0x19afb6('0x18e1')]),_0x493fef[_0x19afb6('0x103b')]({'title':_0x19afb6('0x983'),'msg':_0x19afb6('0x1f6b')});})[_0x5252d0('0x1a80')](function(_0x19b77f){const _0x1ab554=_0x5252d0;_0x493fef['error']({'title':_0x19b77f[_0x1ab554('0x52d')]?_0x1ab554('0x1e21')+_0x19b77f['status']+_0x1ab554('0x11e1')+_0x19b77f[_0x1ab554('0xe1b')]:_0x1ab554('0x1b29'),'msg':_0x19b77f[_0x1ab554('0x52d')]?JSON['stringify'](_0x19b77f[_0x1ab554('0x25f4')]):_0x19b77f[_0x1ab554('0x1586')]()});});}function _0x16606e(){_0x10f56b['hide']();}}const _0x1cf161=_0x1dd39f,_0x4152b6=_0x2734b2['p']+_0x36e6f4('0x1e43'),_0x5568c3=_0x2734b2['p']+_0x36e6f4('0x12'),_0x356b7b=_0x2734b2['p']+_0x36e6f4('0xf8b'),_0x3650af=_0x2734b2['p']+_0x36e6f4('0x2096'),_0x4944f2=_0x2734b2['p']+'src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/resetlist/resetlist.html/resetlist.html';_0x30c142[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'$translate',_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x1915'),_0x36e6f4('0x17aa')];function _0x30c142(_0x120753,_0x2191cf,_0x5aa60b,_0x1e1fac,_0x15d2cb,_0x2922cb,_0x454c1d,_0x4ef822,_0x3f8c49,_0x1bfba4,_0x23f53c,_0x10592b){const _0x4f8221=_0x36e6f4,_0x54a440=this;_0x54a440[_0x4f8221('0x98')]=_0x1bfba4[_0x4f8221('0x26cd')](),_0x54a440['license']=_0x2922cb,_0x54a440[_0x4f8221('0xf8a')]=_0x454c1d,_0x54a440['passwordPattern']=_0x54a440['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x54a440['location']=_0x2191cf[_0x4f8221('0x6f1')]()+_0x4f8221('0xc51')+_0x2191cf[_0x4f8221('0x1690')](),_0x54a440[_0x4f8221('0x1915')]=_0x23f53c||_0x120753[_0x4f8221('0x23f')][_0x4f8221('0x1915')]||{},_0x54a440[_0x4f8221('0x17aa')]=_0x10592b&&_0x10592b['count']==0x1?_0x10592b[_0x4f8221('0x269a')][0x0]:null,_0x54a440[_0x4f8221('0x243c')]=_0x1bfba4['parseCrudPermissions'](_0x54a440[_0x4f8221('0x17aa')]?_0x54a440[_0x4f8221('0x17aa')][_0x4f8221('0x243c')]:null),_0x54a440[_0x4f8221('0x128b')]={},_0x54a440[_0x4f8221('0x2669')]=_0x120753[_0x4f8221('0x23f')]['tab']||0x0,_0x54a440['clonedialog']=_0x5d8ee2,_0x54a440[_0x4f8221('0x2112')]=_0x1a3488,_0x54a440[_0x4f8221('0xe2b')]=_0x563fa5,_0x54a440['teamadddialog']=_0x3caa59,_0x54a440[_0x4f8221('0x1728')]=_0x51a3fb,_0x54a440[_0x4f8221('0x738')]=_0x55503b,_0x54a440['gotogoto']=_0x2a2834,_0x54a440[_0x4f8221('0x31d')]=_0x3f8c49['info'],_0x54a440[_0x4f8221('0x795')]=_0x32a621,_0x54a440[_0x4f8221('0x2169')]=_0x42576c,_0x1bfba4[_0x4f8221('0x1ac6')](_0x4f8221('0xa7c'))?_0x4ef822[_0x4f8221('0x8d3')][_0x4f8221('0xd83')]({'fields':_0x4f8221('0x1776'),'nolimit':_0x4f8221('0xf3b')})[_0x4f8221('0xa44')][_0x4f8221('0x1166')](function(_0x3f24a2){_0x54a440['musiconholds']=_0x3f24a2['rows']||[];})[_0x4f8221('0x1a80')](function(_0x15ba16){const _0x31a08a=_0x4f8221;_0x3f8c49[_0x31a08a('0xfc9')]({'title':_0x15ba16[_0x31a08a('0x52d')]?_0x31a08a('0x1e21')+_0x15ba16[_0x31a08a('0x52d')]+_0x31a08a('0x11e1')+_0x15ba16[_0x31a08a('0xe1b')]:_0x31a08a('0x25d2'),'msg':_0x15ba16['data']?JSON[_0x31a08a('0xbac')](_0x15ba16['data']):_0x15ba16[_0x31a08a('0x1586')]()});}):_0x4ef822[_0x4f8221('0x8d3')]['get']({'fields':_0x4f8221('0x1776'),'nolimit':_0x4f8221('0xf3b')})[_0x4f8221('0xa44')]['then'](function(_0x48e512){const _0x464672=_0x4f8221;_0x54a440['musiconholds']=_0x48e512[_0x464672('0x269a')]||[];})[_0x4f8221('0x1166')](function(){const _0x5297c9=_0x4f8221;return _0x4ef822[_0x5297c9('0x17aa')][_0x5297c9('0xd83')]({'userProfileId':_0x54a440[_0x5297c9('0x98')]['userProfileId'],'sectionId':0x197})[_0x5297c9('0xa44')];})[_0x4f8221('0x1166')](function(_0x56897d){const _0x314de9=_0x4f8221,_0xe647b0=_0x56897d&&_0x56897d[_0x314de9('0x269a')]?_0x56897d[_0x314de9('0x269a')][0x0]:null;if(!_0xe647b0)return _0x4ef822[_0x314de9('0x8d3')][_0x314de9('0xd83')]({'fields':_0x314de9('0x1776'),'nolimit':'true','defaultEntry':0x1})[_0x314de9('0xa44')][_0x314de9('0x1166')](function(_0x54fec7){const _0x230ff6=_0x314de9;_0x54a440[_0x230ff6('0x10ad')]=_0x54fec7[_0x230ff6('0x269a')]||[];});else{if(!_0xe647b0['autoAssociation'])return _0x4ef822['userProfileResource'][_0x314de9('0xd83')]({'sectionId':_0xe647b0['id']})[_0x314de9('0xa44')]['then'](function(_0x35a650){const _0x45c8ff=_0x314de9,_0x10cab7=_0x2cfb05()[_0x45c8ff('0x2563')](_0x35a650['rows'],function(_0x3c1af5){const _0x108eb7=_0x45c8ff;return _0x2cfb05()[_0x108eb7('0xc38')](_0x54a440[_0x108eb7('0x10ad')],{'id':_0x3c1af5[_0x108eb7('0x24e8')]});});let _0x255167=null;_0x54a440['queueCampaign']&&(_0x255167=_0x2cfb05()[_0x45c8ff('0xc38')](_0x54a440[_0x45c8ff('0x10ad')],{'name':_0x54a440[_0x45c8ff('0x1915')][_0x45c8ff('0x98e')]}));if(_0x255167&&!_0x2cfb05()[_0x45c8ff('0x1798')](_0x10cab7,['id',_0x255167['id']])){const _0x5ca3ba=_0x2cfb05()[_0x45c8ff('0xc38')](_0x54a440[_0x45c8ff('0x10ad')],{'id':_0x255167['id']});_0x5ca3ba[_0x45c8ff('0x2378')]=![],_0x10cab7[_0x45c8ff('0x1514')](_0x5ca3ba);}_0x54a440[_0x45c8ff('0x10ad')]=_0x10cab7;});}})['catch'](function(_0x32b8b4){const _0x450a8a=_0x4f8221;_0x3f8c49[_0x450a8a('0xfc9')]({'title':_0x32b8b4['status']?_0x450a8a('0x1e21')+_0x32b8b4[_0x450a8a('0x52d')]+'\x20-\x20'+_0x32b8b4[_0x450a8a('0xe1b')]:'SYSTEM:GETmusiconholds','msg':_0x32b8b4[_0x450a8a('0x25f4')]?JSON[_0x450a8a('0xbac')](_0x32b8b4[_0x450a8a('0x25f4')]):_0x32b8b4[_0x450a8a('0x1586')]()});}),_0x1bfba4[_0x4f8221('0x1ac6')](_0x4f8221('0xa7c'))?_0x4ef822['trunk'][_0x4f8221('0xd83')]({'fields':_0x4f8221('0x1776'),'sort':_0x4f8221('0x4f0')})[_0x4f8221('0xa44')][_0x4f8221('0x1166')](function(_0x4c8791){const _0x5dc37c=_0x4f8221;_0x54a440['trunks']=_0x4c8791[_0x5dc37c('0x269a')]||[];})[_0x4f8221('0x1a80')](function(_0x517374){const _0x28df47=_0x4f8221;_0x3f8c49[_0x28df47('0xfc9')]({'title':_0x517374[_0x28df47('0x52d')]?'API:'+_0x517374['status']+_0x28df47('0x11e1')+_0x517374['statusText']:_0x28df47('0x12a6'),'msg':_0x517374[_0x28df47('0x25f4')]?JSON[_0x28df47('0xbac')](_0x517374['data']):_0x517374[_0x28df47('0x1586')]()});}):_0x4ef822[_0x4f8221('0x3b2')][_0x4f8221('0xd83')]({'fields':_0x4f8221('0x1776'),'sort':_0x4f8221('0x4f0')})['$promise'][_0x4f8221('0x1166')](function(_0x5b9771){const _0x3d0f88=_0x4f8221;_0x54a440[_0x3d0f88('0xf24')]=_0x5b9771['rows']||[];})[_0x4f8221('0x1166')](function(){const _0x20daa6=_0x4f8221;return _0x4ef822[_0x20daa6('0x17aa')]['get']({'userProfileId':_0x54a440[_0x20daa6('0x98')][_0x20daa6('0xb86')],'sectionId':0x3f3})[_0x20daa6('0xa44')];})['then'](function(_0x5614e7){const _0x40a13d=_0x4f8221,_0x4a2b15=_0x5614e7&&_0x5614e7['rows']?_0x5614e7[_0x40a13d('0x269a')][0x0]:null;if(!_0x4a2b15){const _0x2a62d2=[];let _0x32f8d4=null;_0x54a440[_0x40a13d('0x1915')]&&(_0x32f8d4=_0x2cfb05()[_0x40a13d('0xc38')](_0x54a440['trunks'],{'id':Number(_0x54a440[_0x40a13d('0x1915')][_0x40a13d('0x1ce4')])}));for(let _0x51c858=0x0;_0x51c858<_0x54a440[_0x40a13d('0xf24')][_0x40a13d('0x264b')];_0x51c858++){_0x32f8d4&&_0x54a440[_0x40a13d('0xf24')][_0x51c858]['id']===_0x32f8d4['id']&&(_0x54a440[_0x40a13d('0xf24')][_0x51c858][_0x40a13d('0x2378')]=![],_0x2a62d2[_0x40a13d('0x1514')](_0x54a440[_0x40a13d('0xf24')][_0x51c858]));}_0x54a440[_0x40a13d('0xf24')]=_0x2a62d2;}else{if(!_0x4a2b15['autoAssociation'])return _0x4ef822[_0x40a13d('0x4b5')]['get']({'sectionId':_0x4a2b15['id']})[_0x40a13d('0xa44')][_0x40a13d('0x1166')](function(_0x4ebcf8){const _0xf01cc2=_0x40a13d,_0x101ae3=_0x2cfb05()['map'](_0x4ebcf8[_0xf01cc2('0x269a')],function(_0x2ee16d){const _0x52a059=_0xf01cc2;return _0x2cfb05()[_0x52a059('0xc38')](_0x54a440['trunks'],{'id':_0x2ee16d[_0x52a059('0x24e8')]});});let _0xc65735=null;_0x54a440[_0xf01cc2('0x1915')]&&(_0xc65735=_0x2cfb05()[_0xf01cc2('0xc38')](_0x54a440[_0xf01cc2('0xf24')],{'id':Number(_0x54a440['queueCampaign'][_0xf01cc2('0x1ce4')])}));if(_0xc65735&&!_0x2cfb05()['some'](_0x101ae3,['id',_0xc65735['id']])){const _0x1aebdf=_0x2cfb05()['find'](_0x54a440[_0xf01cc2('0xf24')],{'id':_0xc65735['id']});_0x1aebdf['canSelect']=![],_0x101ae3[_0xf01cc2('0x1514')](_0x1aebdf);}_0x54a440[_0xf01cc2('0xf24')]=_0x101ae3;});}})[_0x4f8221('0x1a80')](function(_0x3e7bb7){const _0xb7e84e=_0x4f8221;_0x3f8c49['error']({'title':_0x3e7bb7[_0xb7e84e('0x52d')]?_0xb7e84e('0x1e21')+_0x3e7bb7['status']+_0xb7e84e('0x11e1')+_0x3e7bb7['statusText']:_0xb7e84e('0x1d44'),'msg':_0x3e7bb7['data']?JSON[_0xb7e84e('0xbac')](_0x3e7bb7[_0xb7e84e('0x25f4')]):_0x3e7bb7[_0xb7e84e('0x1586')]()});}),_0x1bfba4[_0x4f8221('0x1ac6')](_0x4f8221('0xa7c'))?_0x4ef822['squareProject'][_0x4f8221('0xd83')]({'fields':_0x4f8221('0x1776'),'sort':_0x4f8221('0x4f0')})[_0x4f8221('0xa44')][_0x4f8221('0x1166')](function(_0x5da278){const _0x36cc31=_0x4f8221;_0x54a440[_0x36cc31('0x149f')]=_0x5da278[_0x36cc31('0x269a')]||[];})[_0x4f8221('0x1a80')](function(_0x1dfd3c){const _0x30e2d6=_0x4f8221;_0x3f8c49[_0x30e2d6('0xfc9')]({'title':_0x1dfd3c['status']?'API:'+_0x1dfd3c['status']+_0x30e2d6('0x11e1')+_0x1dfd3c['statusText']:'SYSTEM:GET_PROJECTS','msg':_0x1dfd3c['data']?JSON[_0x30e2d6('0xbac')](_0x1dfd3c['data']):_0x1dfd3c[_0x30e2d6('0x1586')]()});}):_0x4ef822[_0x4f8221('0x7e4')]['get']({'fields':_0x4f8221('0x1776'),'sort':_0x4f8221('0x4f0')})[_0x4f8221('0xa44')]['then'](function(_0xdb8cf4){const _0x6cc61e=_0x4f8221;_0x54a440[_0x6cc61e('0x149f')]=_0xdb8cf4[_0x6cc61e('0x269a')]||[];})[_0x4f8221('0x1166')](function(){const _0x59b54b=_0x4f8221;return _0x4ef822['userProfileSection']['get']({'userProfileId':_0x54a440[_0x59b54b('0x98')][_0x59b54b('0xb86')],'sectionId':0x44f})['$promise'];})[_0x4f8221('0x1166')](function(_0x5ba114){const _0x272dc7=_0x4f8221,_0x7dda2d=_0x5ba114&&_0x5ba114[_0x272dc7('0x269a')]?_0x5ba114[_0x272dc7('0x269a')][0x0]:null;if(!_0x7dda2d){const _0x4a7849=[];let _0x1695b0=null;_0x54a440[_0x272dc7('0x1915')]&&(_0x1695b0=_0x2cfb05()[_0x272dc7('0xc38')](_0x54a440[_0x272dc7('0x149f')],{'name':_0x54a440['queueCampaign']['dialQueueProject']}));for(let _0xc9b7f5=0x0;_0xc9b7f5<_0x54a440[_0x272dc7('0x149f')][_0x272dc7('0x264b')];_0xc9b7f5++){_0x1695b0&&_0x54a440[_0x272dc7('0x149f')][_0xc9b7f5]['id']===_0x1695b0['id']&&(_0x54a440[_0x272dc7('0x149f')][_0xc9b7f5][_0x272dc7('0x2378')]=![],_0x4a7849[_0x272dc7('0x1514')](_0x54a440[_0x272dc7('0x149f')][_0xc9b7f5]));}_0x54a440['projects']=_0x4a7849;}else{if(!_0x7dda2d[_0x272dc7('0x1a2b')])return _0x4ef822[_0x272dc7('0x4b5')][_0x272dc7('0xd83')]({'sectionId':_0x7dda2d['id']})[_0x272dc7('0xa44')][_0x272dc7('0x1166')](function(_0x24ff54){const _0x4bd3b4=_0x272dc7,_0x3d4a94=_0x2cfb05()['map'](_0x24ff54['rows'],function(_0x2c929c){const _0x5e94b8=a0_0x3f2c;return _0x2cfb05()[_0x5e94b8('0xc38')](_0x54a440['projects'],{'id':_0x2c929c[_0x5e94b8('0x24e8')]});});let _0x114f96=null;_0x54a440[_0x4bd3b4('0x1915')]&&(_0x114f96=_0x2cfb05()[_0x4bd3b4('0xc38')](_0x54a440['projects'],{'name':_0x54a440['queueCampaign'][_0x4bd3b4('0xaa6')]}));if(_0x114f96&&!_0x2cfb05()[_0x4bd3b4('0x1798')](_0x3d4a94,['id',_0x114f96['id']])){const _0x57cc0f=_0x2cfb05()[_0x4bd3b4('0xc38')](_0x54a440[_0x4bd3b4('0x149f')],{'id':_0x114f96['id']});_0x57cc0f[_0x4bd3b4('0x2378')]=![],_0x3d4a94[_0x4bd3b4('0x1514')](_0x57cc0f);}_0x54a440['projects']=_0x3d4a94;});}})[_0x4f8221('0x1a80')](function(_0x37d93f){const _0x4bf2a9=_0x4f8221;_0x3f8c49['error']({'title':_0x37d93f[_0x4bf2a9('0x52d')]?_0x4bf2a9('0x1e21')+_0x37d93f[_0x4bf2a9('0x52d')]+_0x4bf2a9('0x11e1')+_0x37d93f[_0x4bf2a9('0xe1b')]:'SYSTEM:GETprojects','msg':_0x37d93f[_0x4bf2a9('0x25f4')]?JSON[_0x4bf2a9('0xbac')](_0x37d93f[_0x4bf2a9('0x25f4')]):_0x37d93f['toString']()});}),_0x1bfba4['hasRole'](_0x4f8221('0xa7c'))?_0x4ef822['interval'][_0x4f8221('0xd83')]({'fields':_0x4f8221('0x1776'),'sort':'name','IntervalId':_0x4f8221('0x15d7')})['$promise'][_0x4f8221('0x1166')](function(_0x2a0862){const _0x3a22c6=_0x4f8221;_0x54a440['interval']=_0x2a0862[_0x3a22c6('0x269a')]||[];})['catch'](function(_0x12aa89){const _0x4ee39b=_0x4f8221;_0x3f8c49[_0x4ee39b('0xfc9')]({'title':_0x12aa89[_0x4ee39b('0x52d')]?_0x4ee39b('0x1e21')+_0x12aa89[_0x4ee39b('0x52d')]+_0x4ee39b('0x11e1')+_0x12aa89[_0x4ee39b('0xe1b')]:'SYSTEM:GET_INTERVAL','msg':_0x12aa89[_0x4ee39b('0x25f4')]?JSON[_0x4ee39b('0xbac')](_0x12aa89[_0x4ee39b('0x25f4')]):_0x12aa89[_0x4ee39b('0x1586')]()});}):_0x4ef822['interval'][_0x4f8221('0xd83')]({'fields':_0x4f8221('0x1776'),'sort':_0x4f8221('0x4f0'),'IntervalId':_0x4f8221('0x15d7')})[_0x4f8221('0xa44')][_0x4f8221('0x1166')](function(_0x433aea){const _0xee0b92=_0x4f8221;_0x54a440['interval']=_0x433aea[_0xee0b92('0x269a')]||[];})[_0x4f8221('0x1166')](function(){const _0x3fef47=_0x4f8221;return _0x4ef822[_0x3fef47('0x17aa')][_0x3fef47('0xd83')]({'userProfileId':_0x54a440[_0x3fef47('0x98')]['userProfileId'],'sectionId':0x3ec})[_0x3fef47('0xa44')];})['then'](function(_0x280536){const _0x3c17cc=_0x4f8221,_0x397718=_0x280536&&_0x280536['rows']?_0x280536[_0x3c17cc('0x269a')][0x0]:null;if(!_0x397718){const _0x587a0d=[];let _0xef2383=null;_0x54a440[_0x3c17cc('0x1915')]&&(_0xef2383=_0x2cfb05()[_0x3c17cc('0xc38')](_0x54a440[_0x3c17cc('0x277c')],{'id':Number(_0x54a440[_0x3c17cc('0x1915')][_0x3c17cc('0x186f')])}));for(let _0x28aa45=0x0;_0x28aa45<_0x54a440[_0x3c17cc('0x277c')][_0x3c17cc('0x264b')];_0x28aa45++){_0xef2383&&_0x54a440['interval'][_0x28aa45]['id']===_0xef2383['id']&&(_0x54a440['interval'][_0x28aa45]['canSelect']=![],_0x587a0d['push'](_0x54a440['interval'][_0x28aa45]));}_0x54a440[_0x3c17cc('0x277c')]=_0x587a0d;}else{if(!_0x397718['autoAssociation'])return _0x4ef822[_0x3c17cc('0x4b5')][_0x3c17cc('0xd83')]({'sectionId':_0x397718['id']})['$promise'][_0x3c17cc('0x1166')](function(_0x21bd07){const _0x487949=_0x3c17cc,_0x3dc7e7=_0x2cfb05()[_0x487949('0x2563')](_0x21bd07[_0x487949('0x269a')],function(_0x5c2043){const _0x2d9dc5=_0x487949;return _0x2cfb05()[_0x2d9dc5('0xc38')](_0x54a440['interval'],{'id':_0x5c2043['resourceId']});});let _0x454ccd=null;_0x54a440['queueCampaign']&&(_0x454ccd=_0x2cfb05()['find'](_0x54a440['interval'],{'id':Number(_0x54a440[_0x487949('0x1915')][_0x487949('0x186f')])}));if(_0x454ccd&&!_0x2cfb05()[_0x487949('0x1798')](_0x3dc7e7,['id',_0x454ccd['id']])){const _0x117aaa=_0x2cfb05()[_0x487949('0xc38')](_0x54a440[_0x487949('0x277c')],{'id':_0x454ccd['id']});_0x117aaa[_0x487949('0x2378')]=![],_0x3dc7e7['push'](_0x117aaa);}_0x54a440[_0x487949('0x277c')]=_0x3dc7e7;});}})[_0x4f8221('0x1a80')](function(_0x3ab52f){const _0x5ba06b=_0x4f8221;_0x3f8c49[_0x5ba06b('0xfc9')]({'title':_0x3ab52f[_0x5ba06b('0x52d')]?_0x5ba06b('0x1e21')+_0x3ab52f[_0x5ba06b('0x52d')]+_0x5ba06b('0x11e1')+_0x3ab52f['statusText']:_0x5ba06b('0xe48'),'msg':_0x3ab52f[_0x5ba06b('0x25f4')]?JSON[_0x5ba06b('0xbac')](_0x3ab52f[_0x5ba06b('0x25f4')]):_0x3ab52f[_0x5ba06b('0x1586')]()});}),_0x1bfba4[_0x4f8221('0x1ac6')](_0x4f8221('0xa7c'))?_0x4ef822[_0x4f8221('0x1e77')][_0x4f8221('0xd83')]({'fields':'name,id','sort':'name','nolimit':_0x4f8221('0xf3b')})[_0x4f8221('0xa44')][_0x4f8221('0x1166')](function(_0x5c340a){const _0x3ea5fa=_0x4f8221;_0x54a440[_0x3ea5fa('0xe29')]=_0x5c340a[_0x3ea5fa('0x269a')]||[];})[_0x4f8221('0x1a80')](function(_0x558e2b){const _0x584c29=_0x4f8221;_0x3f8c49[_0x584c29('0xfc9')]({'title':_0x558e2b[_0x584c29('0x52d')]?'API:'+_0x558e2b[_0x584c29('0x52d')]+_0x584c29('0x11e1')+_0x558e2b['statusText']:'SYSTEM:GET_PAUSES','msg':_0x558e2b[_0x584c29('0x25f4')]?JSON[_0x584c29('0xbac')](_0x558e2b[_0x584c29('0x25f4')]):_0x558e2b[_0x584c29('0x1586')]()});}):_0x4ef822[_0x4f8221('0x1e77')][_0x4f8221('0xd83')]({'fields':_0x4f8221('0xcb8'),'sort':_0x4f8221('0x4f0'),'nolimit':_0x4f8221('0xf3b')})[_0x4f8221('0xa44')][_0x4f8221('0x1166')](function(_0x486057){const _0x2a9bd1=_0x4f8221;_0x54a440[_0x2a9bd1('0xe29')]=_0x486057[_0x2a9bd1('0x269a')]||[];})['then'](function(){const _0x1f6e93=_0x4f8221;return _0x4ef822[_0x1f6e93('0x17aa')]['get']({'userProfileId':_0x54a440[_0x1f6e93('0x98')][_0x1f6e93('0xb86')],'sectionId':0x3ed})['$promise'];})[_0x4f8221('0x1166')](function(_0x11047b){const _0x513938=_0x4f8221,_0x1edb5a=_0x11047b&&_0x11047b[_0x513938('0x269a')]?_0x11047b[_0x513938('0x269a')][0x0]:null;if(!_0x1edb5a)_0x54a440[_0x513938('0xe29')]=[];else{if(!_0x1edb5a[_0x513938('0x1a2b')])return _0x4ef822[_0x513938('0x4b5')][_0x513938('0xd83')]({'sectionId':_0x1edb5a['id']})[_0x513938('0xa44')][_0x513938('0x1166')](function(_0x14c5ff){const _0x340ebd=_0x513938,_0x345aaa=_0x2cfb05()['map'](_0x14c5ff[_0x340ebd('0x269a')],function(_0x58012f){const _0x2f0948=_0x340ebd;return _0x2cfb05()[_0x2f0948('0xc38')](_0x54a440['pauses'],{'id':_0x58012f[_0x2f0948('0x24e8')]});});_0x54a440['pauses'][_0x340ebd('0x2782')](function(_0x4cbd59){const _0x37d71e=_0x340ebd;!_0x2cfb05()['some'](_0x345aaa,['id',_0x4cbd59['id']])&&(_0x4cbd59[_0x37d71e('0x2378')]=![]),_0x345aaa[_0x37d71e('0x1514')](_0x4cbd59);}),_0x54a440[_0x340ebd('0xe29')]=_0x345aaa;});}})[_0x4f8221('0x1a80')](function(_0x4de2cb){const _0x5496b3=_0x4f8221;_0x3f8c49[_0x5496b3('0xfc9')]({'title':_0x4de2cb[_0x5496b3('0x52d')]?_0x5496b3('0x1e21')+_0x4de2cb[_0x5496b3('0x52d')]+_0x5496b3('0x11e1')+_0x4de2cb['statusText']:_0x5496b3('0x1488'),'msg':_0x4de2cb[_0x5496b3('0x25f4')]?JSON['stringify'](_0x4de2cb['data']):_0x4de2cb[_0x5496b3('0x1586')]()});});function _0x5d8ee2(_0x11c4c5,_0x1549b3){const _0x1a3064=_0x4f8221;_0x5aa60b[_0x1a3064('0x1f80')]({'controller':_0x1a3064('0x1892'),'controllerAs':'vm','templateUrl':_0x4152b6,'parent':angular['element'](_0x1e1fac[_0x1a3064('0x8d2')]),'targetEvent':_0x1549b3,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x11c4c5,'queueCampaigns':_0x54a440[_0x1a3064('0x182c')]?_0x54a440[_0x1a3064('0x182c')][_0x1a3064('0x269a')]:[],'crudPermissions':_0x54a440[_0x1a3064('0x243c')]}});}function _0x1a3488(_0x470dfa,_0x4ff0cd){const _0xa2d32a=_0x4f8221;_0x5aa60b[_0xa2d32a('0x1f80')]({'controller':_0xa2d32a('0x2c6'),'controllerAs':'vm','templateUrl':_0x5568c3,'parent':angular[_0xa2d32a('0x1194')](_0x1e1fac[_0xa2d32a('0x8d2')]),'targetEvent':_0x4ff0cd,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x470dfa,'queueCampaigns':_0x54a440[_0xa2d32a('0x182c')]?_0x54a440['queueCampaigns'][_0xa2d32a('0x269a')]:[],'crudPermissions':_0x54a440[_0xa2d32a('0x243c')]}});}function _0x563fa5(_0x122fae,_0x35babe){const _0x30e935=_0x4f8221;_0x5aa60b[_0x30e935('0x1f80')]({'controller':'QueueCampaignblacklistaddController','controllerAs':'vm','templateUrl':_0x356b7b,'parent':angular[_0x30e935('0x1194')](_0x1e1fac[_0x30e935('0x8d2')]),'targetEvent':_0x35babe,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x122fae,'queueCampaigns':_0x54a440[_0x30e935('0x182c')]?_0x54a440[_0x30e935('0x182c')][_0x30e935('0x269a')]:[],'crudPermissions':_0x54a440[_0x30e935('0x243c')]}});}function _0x3caa59(_0x311bed,_0x10131b){const _0x50dbae=_0x4f8221;_0x5aa60b[_0x50dbae('0x1f80')]({'controller':_0x50dbae('0x24c6'),'controllerAs':'vm','templateUrl':_0x3650af,'parent':angular[_0x50dbae('0x1194')](_0x1e1fac[_0x50dbae('0x8d2')]),'targetEvent':_0x10131b,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x311bed,'queueCampaigns':_0x54a440['queueCampaigns']?_0x54a440[_0x50dbae('0x182c')]['rows']:[],'crudPermissions':_0x54a440['crudPermissions']}});}function _0x51a3fb(_0x5f2e3f,_0x76ef6){const _0x8608ad=_0x4f8221;_0x5aa60b[_0x8608ad('0x1f80')]({'controller':_0x8608ad('0x27c1'),'controllerAs':'vm','templateUrl':_0x1848c7,'parent':angular[_0x8608ad('0x1194')](_0x1e1fac[_0x8608ad('0x8d2')]),'targetEvent':_0x76ef6,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x5f2e3f,'queueCampaigns':_0x54a440['queueCampaigns']?_0x54a440['queueCampaigns'][_0x8608ad('0x269a')]:[],'crudPermissions':_0x54a440[_0x8608ad('0x243c')],'realtime':![]}});}function _0x4dc46a(_0xb51052,_0x143ae2){const _0xd0190c=_0x4f8221,_0x381b98=_0x143ae2['id'];_0x4ef822[_0xd0190c('0x1943')][_0xd0190c('0xed4')]({'id':_0xb51052,'ids':_0x381b98})[_0xd0190c('0xa44')]['then'](function(){const _0x1af70e=_0xd0190c;return _0x4ef822[_0x1af70e('0x1943')][_0x1af70e('0x1e0b')]({'id':_0xb51052,'ids':_0x381b98,'dialCheckDuplicateType':'never'})[_0x1af70e('0xa44')];})[_0xd0190c('0x1166')](function(){const _0x1d114e=_0xd0190c;_0x3f8c49[_0x1d114e('0x103b')]({'title':_0x1d114e('0xc7e'),'msg':_0x1d114e('0xdac')+_0x143ae2[_0x1d114e('0x4f0')]+_0x1d114e('0x25e4')});})[_0xd0190c('0x1a80')](function(_0x5661db){const _0x46b1ab=_0xd0190c;_0x3f8c49[_0x46b1ab('0xfc9')]({'title':_0x5661db[_0x46b1ab('0x52d')]?_0x46b1ab('0x1e21')+_0x5661db[_0x46b1ab('0x52d')]+_0x46b1ab('0x11e1')+_0x5661db['statusText']:_0x46b1ab('0x261b'),'msg':_0x5661db[_0x46b1ab('0x52d')]?JSON['stringify'](_0x5661db[_0x46b1ab('0x25f4')]):_0x5661db[_0x46b1ab('0x1586')]()});});}function _0x55503b(_0x35609c,_0x17b97a){const _0x16143e=_0x4f8221;_0x4ef822[_0x16143e('0x1943')][_0x16143e('0x5a1')]({'id':_0x35609c['id'],'fields':_0x16143e('0x1776'),'nolimit':!![]})[_0x16143e('0xa44')][_0x16143e('0x1166')](function(_0x22b0d8){const _0x62ec84=_0x16143e;if(_0x2cfb05()['isNil'](_0x22b0d8['rows'])||_0x2cfb05()[_0x62ec84('0x1081')](_0x22b0d8[_0x62ec84('0x269a')]))_0x3f8c49[_0x62ec84('0x1fa1')]({'title':_0x62ec84('0x26be')});else{if(_0x22b0d8[_0x62ec84('0x269a')][_0x62ec84('0x264b')]===0x1){const _0x451287=_0x5aa60b['confirm']()[_0x62ec84('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20reset\x20the\x20list\x20'+_0x22b0d8[_0x62ec84('0x269a')][0x0][_0x62ec84('0x4f0')]+'\x20?')['htmlContent'](''+_0x22b0d8[_0x62ec84('0x269a')][0x0][_0x62ec84('0x4f0')]+''+_0x62ec84('0x1f29'))['ariaLabel'](_0x62ec84('0x4a'))[_0x62ec84('0x203b')](_0x17b97a)['ok']('OK')[_0x62ec84('0x3f')](_0x62ec84('0x2d3'));_0x5aa60b[_0x62ec84('0x1f80')](_0x451287)['then'](function(){const _0x1efddd=_0x62ec84;_0x4dc46a(_0x54a440[_0x1efddd('0x1915')]['id'],_0x22b0d8[_0x1efddd('0x269a')][0x0]);});}else _0x5aa60b[_0x62ec84('0x1f80')]({'controller':_0x62ec84('0x1fba'),'controllerAs':'vm','templateUrl':_0x4944f2,'parent':angular[_0x62ec84('0x1194')](_0x1e1fac['body']),'targetEvent':_0x17b97a,'clickOutsideToClose':![],'locals':{'queueCampaign':_0x35609c,'listsCampaign':_0x22b0d8?_0x22b0d8['rows']:[]}});}})['catch'](function(_0x1b8950){const _0x177998=_0x16143e;_0x3f8c49[_0x177998('0xfc9')]({'title':_0x1b8950[_0x177998('0x52d')]?_0x177998('0x1e21')+_0x1b8950[_0x177998('0x52d')]+_0x177998('0x11e1')+_0x1b8950[_0x177998('0xe1b')]:_0x177998('0x2ff'),'msg':_0x1b8950[_0x177998('0x52d')]?JSON['stringify'](_0x1b8950[_0x177998('0x25f4')]):_0x1b8950[_0x177998('0x1586')]()});});}function _0x2a2834(){const _0x4313a9=_0x4f8221;if(_0x1bfba4[_0x4313a9('0x1ac6')]('admin'))_0x120753['go'](_0x4313a9('0x745'),{});else return _0x4ef822['userProfileSection']['get']({'userProfileId':_0x1bfba4['getCurrentUser']()[_0x4313a9('0xb86')],'sectionId':0x5e6})[_0x4313a9('0xa44')]['then'](function(_0x4d7eb3){const _0x2f777f=_0x4313a9,_0xb024d9=_0x4d7eb3&&_0x4d7eb3[_0x2f777f('0x269a')]?_0x4d7eb3[_0x2f777f('0x269a')][0x0]:null;_0xb024d9&&_0xb024d9[_0x2f777f('0xc27')]?_0x120753['go'](_0x2f777f('0x745'),{}):_0x3f8c49['info']({'title':_0x15d2cb[_0x2f777f('0x25cc')](_0x2f777f('0x627')),'msg':_0x15d2cb[_0x2f777f('0x25cc')](_0x2f777f('0x2642'))});})['catch'](function(_0x4b1394){const _0xb4ea35=_0x4313a9;_0x3f8c49['error']({'title':_0x4b1394[_0xb4ea35('0x52d')]?_0xb4ea35('0x1e21')+_0x4b1394['status']+_0xb4ea35('0x11e1')+_0x4b1394[_0xb4ea35('0xe1b')]:_0xb4ea35('0x153e'),'msg':_0x4b1394[_0xb4ea35('0x52d')]?JSON[_0xb4ea35('0xbac')](_0x4b1394[_0xb4ea35('0x25f4')]):_0x4b1394['toString']()});});}function _0x32a621(){const _0x357f66=_0x4f8221;_0x120753['go'](_0x357f66('0xd3c'),{},{'reload':_0x357f66('0xd3c')});}function _0x42576c(){const _0x83f644=_0x4f8221;_0x4ef822['voiceQueue']['update']({'id':_0x54a440[_0x83f644('0x1915')]['id']},_0x54a440[_0x83f644('0x1915')])['$promise'][_0x83f644('0x1166')](function(){const _0x5b50dc=_0x83f644;_0x3f8c49[_0x5b50dc('0x103b')]({'title':_0x5b50dc('0x1a38'),'msg':_0x54a440[_0x5b50dc('0x1915')][_0x5b50dc('0x4f0')]?_0x54a440[_0x5b50dc('0x1915')][_0x5b50dc('0x4f0')]+_0x5b50dc('0xa17'):''});})[_0x83f644('0x1a80')](function(_0x433c71){const _0x4c85d6=_0x83f644;_0x3f8c49[_0x4c85d6('0xfc9')]({'title':_0x433c71['status']?'API:'+_0x433c71[_0x4c85d6('0x52d')]+_0x4c85d6('0x11e1')+_0x433c71[_0x4c85d6('0xe1b')]:'SYSTEM:GETvoiceQueue','msg':_0x433c71[_0x4c85d6('0x25f4')]?JSON[_0x4c85d6('0xbac')](_0x433c71[_0x4c85d6('0x25f4')]):_0x433c71['toString']()});});}}const _0x423ee4=_0x30c142;_0xfe0aa0[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$window',_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),'$mdDialog','$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'queueCampaigns',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),'api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0xfe0aa0(_0x5b1e04,_0x2128d7,_0x2e3643,_0xd80f62,_0x328b91,_0x36ae05,_0x37b1be,_0x37fca0,_0x32a8e0,_0x2bbcce,_0x49e0e5,_0x4e958e,_0x47e680,_0x5bc4ce,_0x56fd59,_0x3a07ee,_0x22251d){const _0x4129b6=_0x36e6f4,_0x364032=this;_0x364032[_0x4129b6('0x5c9')]=_0x3a07ee,_0x364032['setting']=_0x22251d,_0x364032[_0x4129b6('0x98')]=_0x56fd59[_0x4129b6('0x26cd')](),_0x364032[_0x4129b6('0x182c')]=_0x32a8e0||{'count':0x0,'rows':[]},_0x364032[_0x4129b6('0x7f')]=_0x2bbcce,_0x364032['userProfileSection']=_0x49e0e5&&_0x49e0e5[_0x4129b6('0x240f')]==0x1?_0x49e0e5[_0x4129b6('0x269a')][0x0]:null,_0x364032[_0x4129b6('0x243c')]=_0x56fd59[_0x4129b6('0xd87')](_0x364032[_0x4129b6('0x17aa')]?_0x364032[_0x4129b6('0x17aa')][_0x4129b6('0x243c')]:null),_0x364032[_0x4129b6('0x916')]=_0x4129b6('0x182c'),_0x364032[_0x4129b6('0xef5')]='',_0x364032[_0x4129b6('0x104c')]=null,_0x364032[_0x4129b6('0xd6d')]=[],_0x364032['query']={'fields':_0x4129b6('0x2413'),'type':_0x4129b6('0x587'),'sort':'-updatedAt','channel':'voice','limit':0xa,'page':0x1},_0x364032[_0x4129b6('0x245c')]=_0x2cfb05()['keyBy']([{'option':_0x4129b6('0x1cff'),'value':'\x27always\x27'},{'option':_0x4129b6('0x1de3'),'value':_0x4129b6('0x130c')},{'option':_0x4129b6('0x284a'),'value':_0x4129b6('0x1a35')}],function(_0x40a091){const _0x5af9af=_0x4129b6;return _0x2cfb05()['replace'](_0x40a091[_0x5af9af('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032[_0x4129b6('0x1a1b')]=_0x2cfb05()['keyBy']([{'option':_0x4129b6('0x193c'),'value':_0x4129b6('0x1bf5')},{'option':'No','value':'\x27no\x27'}],function(_0x8f48a8){const _0x1311a7=_0x4129b6;return _0x2cfb05()['replace'](_0x8f48a8[_0x1311a7('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032[_0x4129b6('0x195a')]=_0x2cfb05()['keyBy']([{'option':_0x4129b6('0x193c'),'value':_0x4129b6('0x20b3')},{'option':'No','value':_0x4129b6('0x119b')}],function(_0x21b808){const _0x13ef6d=_0x4129b6;return _0x2cfb05()[_0x13ef6d('0xf3')](_0x21b808[_0x13ef6d('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032['arraytimeoutrestart']=_0x2cfb05()[_0x4129b6('0x155c')]([{'option':_0x4129b6('0x193c'),'value':_0x4129b6('0x20b3')},{'option':'No','value':_0x4129b6('0x119b')}],function(_0x4589f1){const _0x5da1e1=_0x4129b6;return _0x2cfb05()[_0x5da1e1('0xf3')](_0x4589f1[_0x5da1e1('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032[_0x4129b6('0x2060')]=_0x2cfb05()[_0x4129b6('0x155c')]([{'option':_0x4129b6('0x1882'),'value':'\x27\x27'},{'option':'wav','value':_0x4129b6('0x91c')},{'option':_0x4129b6('0xd43'),'value':_0x4129b6('0x1ac3')},{'option':_0x4129b6('0x1cd9'),'value':_0x4129b6('0xd74')}],function(_0x5ce59b){const _0x8beb1e=_0x4129b6;return _0x2cfb05()['replace'](_0x5ce59b[_0x8beb1e('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032['arraysetinterfacevar']=_0x2cfb05()[_0x4129b6('0x155c')]([{'option':_0x4129b6('0x193c'),'value':'\x27yes\x27'},{'option':'No','value':_0x4129b6('0x119b')}],function(_0x46bb2e){const _0x6684f1=_0x4129b6;return _0x2cfb05()[_0x6684f1('0xf3')](_0x46bb2e['value'],new RegExp('\x27','g'),'');}),_0x364032[_0x4129b6('0xf4f')]=_0x2cfb05()['keyBy']([{'option':'Yes','value':'\x27yes\x27'},{'option':'No','value':_0x4129b6('0x119b')}],function(_0xde6179){const _0x582cce=_0x4129b6;return _0x2cfb05()[_0x582cce('0xf3')](_0xde6179[_0x582cce('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032[_0x4129b6('0x2620')]=_0x2cfb05()[_0x4129b6('0x155c')]([{'option':'Yes','value':_0x4129b6('0x20b3')},{'option':'No','value':_0x4129b6('0x119b')}],function(_0x517011){const _0x5073b6=_0x4129b6;return _0x2cfb05()['replace'](_0x517011[_0x5073b6('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032[_0x4129b6('0xdd8')]=_0x2cfb05()[_0x4129b6('0x155c')]([{'option':_0x4129b6('0x1e2b'),'value':_0x4129b6('0x16fc')},{'option':_0x4129b6('0x22d4'),'value':_0x4129b6('0x139b')}],function(_0x9c27b0){const _0x549d78=_0x4129b6;return _0x2cfb05()[_0x549d78('0xf3')](_0x9c27b0[_0x549d78('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032[_0x4129b6('0x150d')]=_0x2cfb05()[_0x4129b6('0x155c')]([{'option':_0x4129b6('0x591'),'value':'\x27progressive\x27'},{'option':_0x4129b6('0x1c66'),'value':'\x27power\x27'},{'option':'Predictive','value':'\x27predictive\x27'},{'option':_0x4129b6('0xc05'),'value':_0x4129b6('0x1829')},{'option':_0x4129b6('0x2544'),'value':_0x4129b6('0x1ce3')}],function(_0x21c3e9){const _0x3d15b3=_0x4129b6;return _0x2cfb05()['replace'](_0x21c3e9[_0x3d15b3('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032['arraydialPredictiveOptimization']=_0x2cfb05()[_0x4129b6('0x155c')]([{'option':_0x4129b6('0x1e7d'),'value':_0x4129b6('0x1fdb')},{'option':_0x4129b6('0x10bd'),'value':_0x4129b6('0xcc0')}],function(_0x3a128f){const _0x36e680=_0x4129b6;return _0x2cfb05()[_0x36e680('0xf3')](_0x3a128f[_0x36e680('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032[_0x4129b6('0x1440')]=_0x2cfb05()['keyBy']([{'option':_0x4129b6('0xa13'),'value':'\x27rrmemory\x27'},{'option':_0x4129b6('0x652'),'value':'\x27roundrobin\x27','ngIf':_0x4129b6('0x8d7')},{'option':_0x4129b6('0x19f0'),'value':'\x27leastrecent\x27','ngIf':_0x4129b6('0x1cf1')},{'option':_0x4129b6('0xd77'),'value':_0x4129b6('0x23ce'),'ngIf':_0x4129b6('0x1cf1')},{'option':'Random','value':_0x4129b6('0x7ad'),'ngIf':_0x4129b6('0x1cf1')},{'option':_0x4129b6('0x29e'),'value':_0x4129b6('0x2838'),'ngIf':_0x4129b6('0x1cf1')},{'option':'Weight\x20Random','value':_0x4129b6('0x49a'),'ngIf':'vm.queueCampaign.dialMethod\x20!==\x20\x27booked\x27'}],function(_0x29b4b8){const _0x472ea=_0x4129b6;return _0x2cfb05()['replace'](_0x29b4b8[_0x472ea('0x18e0')],new RegExp('\x27','g'),'');}),_0x364032['editstate']=_0x404f56,_0x364032[_0x4129b6('0x249d')]=_0x3c111c,_0x364032[_0x4129b6('0x2112')]=_0x371454,_0x364032[_0x4129b6('0xe2b')]=_0x3ed1eb,_0x364032[_0x4129b6('0x292')]=_0x4f2d4a,_0x364032[_0x4129b6('0x1728')]=_0x3de203,_0x364032[_0x4129b6('0x8d8')]=_0x56adfb,_0x364032[_0x4129b6('0x182d')]=_0x50019c,_0x364032['success']=_0x5a8783,_0x364032[_0x4129b6('0x478')]=_0x1f40ec,_0x364032['createOrEditQueueCampaign']=_0x486f18,_0x364032[_0x4129b6('0x1f26')]=_0x6c61e5,_0x364032[_0x4129b6('0x204')]=_0x2b9d9f,_0x364032['deleteSelectedQueueCampaigns']=_0x1404af,_0x364032['deselectQueueCampaigns']=_0x110eb2,_0x364032[_0x4129b6('0x1c91')]=_0xfcae0,_0x56fd59['hasRole'](_0x4129b6('0xa7c'))?_0x4e958e[_0x4129b6('0x3b2')][_0x4129b6('0xd83')]({'fields':_0x4129b6('0x1776'),'sort':_0x4129b6('0x4f0')})[_0x4129b6('0xa44')][_0x4129b6('0x1166')](function(_0x7ff90b){const _0x4ebe1a=_0x4129b6;_0x364032[_0x4ebe1a('0xf24')]=_0x7ff90b[_0x4ebe1a('0x269a')]||[];})[_0x4129b6('0x1a80')](function(_0x4c8935){const _0x2edfbd=_0x4129b6;_0x5bc4ce[_0x2edfbd('0xfc9')]({'title':_0x4c8935[_0x2edfbd('0x52d')]?'API:'+_0x4c8935[_0x2edfbd('0x52d')]+_0x2edfbd('0x11e1')+_0x4c8935['statusText']:_0x2edfbd('0x12a6'),'msg':_0x4c8935['data']?JSON[_0x2edfbd('0xbac')](_0x4c8935[_0x2edfbd('0x25f4')]):_0x4c8935[_0x2edfbd('0x1586')]()});}):_0x4e958e['trunk'][_0x4129b6('0xd83')]({'fields':_0x4129b6('0x1776'),'sort':_0x4129b6('0x4f0')})[_0x4129b6('0xa44')][_0x4129b6('0x1166')](function(_0x2d4054){const _0x4f501a=_0x4129b6;_0x364032[_0x4f501a('0xf24')]=_0x2d4054[_0x4f501a('0x269a')]||[];})[_0x4129b6('0x1166')](function(){const _0x2a3a26=_0x4129b6;return _0x4e958e[_0x2a3a26('0x17aa')][_0x2a3a26('0xd83')]({'userProfileId':_0x364032[_0x2a3a26('0x98')]['userProfileId'],'sectionId':0x3f3})[_0x2a3a26('0xa44')];})[_0x4129b6('0x1166')](function(_0x28bf0a){const _0x483324=_0x4129b6,_0x29464b=_0x28bf0a&&_0x28bf0a['rows']?_0x28bf0a[_0x483324('0x269a')][0x0]:null;if(!_0x29464b){const _0x24a593=[],_0x16bd79=[];_0x364032['queueCampaigns']['rows'][_0x483324('0x2782')](function(_0x1ddab3){const _0x21fe4d=_0x483324,_0x23c292=_0x2cfb05()['find'](_0x364032[_0x21fe4d('0xf24')],{'id':Number(_0x1ddab3['TrunkId'])});_0x16bd79['push'](_0x23c292);});for(let _0x1b90f4=0x0;_0x1b90f4<_0x364032[_0x483324('0xf24')][_0x483324('0x264b')];_0x1b90f4++){const _0x46e790=_0x2cfb05()[_0x483324('0x1798')](_0x16bd79,{'id':_0x364032['trunks'][_0x1b90f4]['id']});_0x46e790&&(_0x364032['trunks'][_0x1b90f4][_0x483324('0x2378')]=![],_0x24a593['push'](_0x364032[_0x483324('0xf24')][_0x1b90f4]));}_0x364032['trunks']=_0x24a593;}else{if(!_0x29464b['autoAssociation'])return _0x4e958e[_0x483324('0x4b5')]['get']({'sectionId':_0x29464b['id']})[_0x483324('0xa44')][_0x483324('0x1166')](function(_0x563856){const _0x56a325=_0x483324,_0x38f317=_0x2cfb05()[_0x56a325('0x2563')](_0x563856[_0x56a325('0x269a')],function(_0xd30f94){const _0x4ead24=_0x56a325;return _0x2cfb05()[_0x4ead24('0xc38')](_0x364032[_0x4ead24('0xf24')],{'id':_0xd30f94[_0x4ead24('0x24e8')]});});let _0xd6d9c3=null;_0xd6d9c3=[],_0x364032[_0x56a325('0x182c')][_0x56a325('0x269a')][_0x56a325('0x2782')](function(_0x552de3){const _0x3207bb=_0x56a325,_0x2e1a1e=_0x2cfb05()['find'](_0x364032[_0x3207bb('0xf24')],{'id':Number(_0x552de3[_0x3207bb('0x1ce4')])});_0xd6d9c3[_0x3207bb('0x1514')](_0x2e1a1e);}),!_0x2cfb05()[_0x56a325('0x1081')](_0xd6d9c3)&&_0xd6d9c3['forEach'](function(_0x5b9d5d){const _0x31fec5=_0x56a325;if(!_0x2cfb05()[_0x31fec5('0x1798')](_0x38f317,['id',_0x5b9d5d['id']])){const _0x2d5aea=_0x2cfb05()[_0x31fec5('0xc38')](_0x364032[_0x31fec5('0xf24')],{'id':_0x5b9d5d['id']});_0x2d5aea[_0x31fec5('0x2378')]=![],_0x38f317[_0x31fec5('0x1514')](_0x2d5aea);}}),_0x364032[_0x56a325('0xf24')]=_0x38f317;});}})[_0x4129b6('0x1a80')](function(_0x30538d){const _0x57e041=_0x4129b6;_0x5bc4ce[_0x57e041('0xfc9')]({'title':_0x30538d['status']?'API:'+_0x30538d[_0x57e041('0x52d')]+_0x57e041('0x11e1')+_0x30538d[_0x57e041('0xe1b')]:_0x57e041('0x1d44'),'msg':_0x30538d[_0x57e041('0x25f4')]?JSON[_0x57e041('0xbac')](_0x30538d[_0x57e041('0x25f4')]):_0x30538d[_0x57e041('0x1586')]()});}),_0x56fd59[_0x4129b6('0x1ac6')](_0x4129b6('0xa7c'))?_0x4e958e[_0x4129b6('0x277c')]['get']({'fields':_0x4129b6('0x1776'),'sort':'name','IntervalId':_0x4129b6('0x15d7')})['$promise'][_0x4129b6('0x1166')](function(_0x1e4c73){const _0x10ab15=_0x4129b6;_0x364032[_0x10ab15('0x277c')]=_0x1e4c73[_0x10ab15('0x269a')]||[];})[_0x4129b6('0x1a80')](function(_0x30f4f3){const _0x598cc0=_0x4129b6;_0x5bc4ce[_0x598cc0('0xfc9')]({'title':_0x30f4f3['status']?_0x598cc0('0x1e21')+_0x30f4f3[_0x598cc0('0x52d')]+_0x598cc0('0x11e1')+_0x30f4f3['statusText']:'SYSTEM:GET_INTERVAL','msg':_0x30f4f3['data']?JSON[_0x598cc0('0xbac')](_0x30f4f3[_0x598cc0('0x25f4')]):_0x30f4f3['toString']()});}):_0x4e958e[_0x4129b6('0x277c')][_0x4129b6('0xd83')]({'fields':_0x4129b6('0x1776'),'sort':_0x4129b6('0x4f0'),'IntervalId':'null'})[_0x4129b6('0xa44')]['then'](function(_0x1153ee){const _0x48217d=_0x4129b6;_0x364032['interval']=_0x1153ee[_0x48217d('0x269a')]||[];})['then'](function(){const _0x55ee87=_0x4129b6;return _0x4e958e[_0x55ee87('0x17aa')][_0x55ee87('0xd83')]({'userProfileId':_0x364032[_0x55ee87('0x98')][_0x55ee87('0xb86')],'sectionId':0x3ec})[_0x55ee87('0xa44')];})[_0x4129b6('0x1166')](function(_0x21ab15){const _0x2dcbce=_0x4129b6,_0x17089e=_0x21ab15&&_0x21ab15[_0x2dcbce('0x269a')]?_0x21ab15[_0x2dcbce('0x269a')][0x0]:null;if(!_0x17089e){const _0x578d9b=[];let _0x508e1c=null;_0x364032[_0x2dcbce('0x1915')]&&(_0x508e1c=_0x2cfb05()['find'](_0x364032[_0x2dcbce('0x277c')],{'id':Number(_0x364032[_0x2dcbce('0x1915')][_0x2dcbce('0x186f')])}));for(let _0x5e56ea=0x0;_0x5e56ea<_0x364032[_0x2dcbce('0x277c')][_0x2dcbce('0x264b')];_0x5e56ea++){_0x508e1c&&_0x364032['interval'][_0x5e56ea]['id']===_0x508e1c['id']&&(_0x364032[_0x2dcbce('0x277c')][_0x5e56ea]['canSelect']=![],_0x578d9b[_0x2dcbce('0x1514')](_0x364032[_0x2dcbce('0x277c')][_0x5e56ea]));}_0x364032[_0x2dcbce('0x277c')]=_0x578d9b;}else{if(!_0x17089e['autoAssociation'])return _0x4e958e[_0x2dcbce('0x4b5')]['get']({'sectionId':_0x17089e['id']})[_0x2dcbce('0xa44')]['then'](function(_0x25a6fa){const _0x587b97=_0x2dcbce,_0x3d8c2f=_0x2cfb05()[_0x587b97('0x2563')](_0x25a6fa['rows'],function(_0x56ea81){const _0x5857c6=_0x587b97;return _0x2cfb05()['find'](_0x364032[_0x5857c6('0x277c')],{'id':_0x56ea81[_0x5857c6('0x24e8')]});});let _0x3df5a6=null;_0x364032[_0x587b97('0x1915')]&&(_0x3df5a6=_0x2cfb05()[_0x587b97('0xc38')](_0x364032['interval'],{'id':Number(_0x364032[_0x587b97('0x1915')][_0x587b97('0x186f')])}));if(_0x3df5a6&&!_0x2cfb05()[_0x587b97('0x1798')](_0x3d8c2f,['id',_0x3df5a6['id']])){const _0x4b34a0=_0x2cfb05()['find'](_0x364032[_0x587b97('0x277c')],{'id':_0x3df5a6['id']});_0x4b34a0['canSelect']=![],_0x3d8c2f['push'](_0x4b34a0);}_0x364032[_0x587b97('0x277c')]=_0x3d8c2f;});}})[_0x4129b6('0x1a80')](function(_0x45e9fc){const _0x5de4ff=_0x4129b6;_0x5bc4ce[_0x5de4ff('0xfc9')]({'title':_0x45e9fc[_0x5de4ff('0x52d')]?_0x5de4ff('0x1e21')+_0x45e9fc[_0x5de4ff('0x52d')]+'\x20-\x20'+_0x45e9fc['statusText']:_0x5de4ff('0xe48'),'msg':_0x45e9fc['data']?JSON['stringify'](_0x45e9fc[_0x5de4ff('0x25f4')]):_0x45e9fc[_0x5de4ff('0x1586')]()});});function _0x404f56(_0x2af309){const _0x11be9f=_0x4129b6;_0x2e3643['go'](_0x11be9f('0x14d4'),{'id':_0x2af309['id'],'queueCampaign':_0x2af309,'crudPermissions':_0x364032['crudPermissions']});}function _0x3c111c(_0x516a77,_0x570a11){const _0x5ee17f=_0x4129b6;_0x328b91[_0x5ee17f('0x1f80')]({'controller':_0x5ee17f('0x1892'),'controllerAs':'vm','templateUrl':_0x4152b6,'parent':angular[_0x5ee17f('0x1194')](_0x36ae05[_0x5ee17f('0x8d2')]),'targetEvent':_0x570a11,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x516a77,'queueCampaigns':_0x364032[_0x5ee17f('0x182c')]?_0x364032[_0x5ee17f('0x182c')][_0x5ee17f('0x269a')]:[],'crudPermissions':_0x364032[_0x5ee17f('0x243c')]}});}function _0x371454(_0x4bad4f,_0xa028d1){const _0x140507=_0x4129b6;_0x328b91[_0x140507('0x1f80')]({'controller':_0x140507('0x2c6'),'controllerAs':'vm','templateUrl':_0x5568c3,'parent':angular[_0x140507('0x1194')](_0x36ae05['body']),'targetEvent':_0xa028d1,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x4bad4f,'queueCampaigns':_0x364032[_0x140507('0x182c')]?_0x364032[_0x140507('0x182c')][_0x140507('0x269a')]:[],'crudPermissions':_0x364032[_0x140507('0x243c')]}});}function _0x3ed1eb(_0x4a74d5,_0x4c7354){const _0x397c67=_0x4129b6;_0x328b91[_0x397c67('0x1f80')]({'controller':_0x397c67('0x245f'),'controllerAs':'vm','templateUrl':_0x356b7b,'parent':angular['element'](_0x36ae05['body']),'targetEvent':_0x4c7354,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x4a74d5,'queueCampaigns':_0x364032[_0x397c67('0x182c')]?_0x364032[_0x397c67('0x182c')][_0x397c67('0x269a')]:[],'crudPermissions':_0x364032[_0x397c67('0x243c')]}});}function _0x4f2d4a(_0x2da205,_0x3b4386){const _0x8b0bda=_0x4129b6;_0x328b91['show']({'controller':_0x8b0bda('0x24c6'),'controllerAs':'vm','templateUrl':_0x3650af,'parent':angular[_0x8b0bda('0x1194')](_0x36ae05[_0x8b0bda('0x8d2')]),'targetEvent':_0x3b4386,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x2da205,'queueCampaigns':_0x364032[_0x8b0bda('0x182c')]?_0x364032[_0x8b0bda('0x182c')]['rows']:[],'crudPermissions':_0x364032[_0x8b0bda('0x243c')]}});}function _0x3de203(_0xbe27d6,_0x23dc56){const _0x3e72eb=_0x4129b6;_0x328b91[_0x3e72eb('0x1f80')]({'controller':'QueueCampaignagentaddController','controllerAs':'vm','templateUrl':_0x1848c7,'parent':angular[_0x3e72eb('0x1194')](_0x36ae05[_0x3e72eb('0x8d2')]),'targetEvent':_0x23dc56,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0xbe27d6,'queueCampaigns':_0x364032[_0x3e72eb('0x182c')]?_0x364032[_0x3e72eb('0x182c')][_0x3e72eb('0x269a')]:[],'crudPermissions':_0x364032['crudPermissions'],'realtime':![]}});}function _0x56adfb(_0x350e75,_0x40b147){const _0x32ce3e=_0x4129b6,_0x343dbd=_0x328b91[_0x32ce3e('0x1d26')]()[_0x32ce3e('0xcdc')](_0x32ce3e('0x288d')+_0x2cfb05()[_0x32ce3e('0xb35')](_0x32ce3e('0x1915'))+'?')[_0x32ce3e('0xf3c')](''+(_0x350e75[_0x32ce3e('0x4f0')]||_0x32ce3e('0x1915'))+''+'\x20will\x20be\x20deleted.')[_0x32ce3e('0x8e8')](_0x32ce3e('0x2350'))['targetEvent'](_0x40b147)['ok']('OK')[_0x32ce3e('0x3f')](_0x32ce3e('0x2d3'));_0x328b91[_0x32ce3e('0x1f80')](_0x343dbd)[_0x32ce3e('0x1166')](function(){_0x6c61e5(_0x350e75);},function(){const _0x48f037=_0x32ce3e;console[_0x48f037('0x455')](_0x48f037('0x2d3'));});}function _0x50019c(){const _0x43bab1=_0x4129b6;if(_0x56fd59['hasRole'](_0x43bab1('0xa7c')))_0x2e3643['go'](_0x43bab1('0x745'),{});else return _0x4e958e[_0x43bab1('0x17aa')][_0x43bab1('0xd83')]({'userProfileId':_0x56fd59[_0x43bab1('0x26cd')]()[_0x43bab1('0xb86')],'sectionId':0x5e6})[_0x43bab1('0xa44')]['then'](function(_0x558015){const _0x312866=_0x43bab1,_0x45dfc0=_0x558015&&_0x558015['rows']?_0x558015['rows'][0x0]:null;_0x45dfc0&&_0x45dfc0['enabled']?_0x2e3643['go'](_0x312866('0x745'),{}):_0x5bc4ce[_0x312866('0x1fa1')]({'title':_0x37fca0['instant'](_0x312866('0x627')),'msg':_0x37fca0[_0x312866('0x25cc')](_0x312866('0x2642'))});})[_0x43bab1('0x1a80')](function(_0x5efba5){const _0x14129a=_0x43bab1;_0x5bc4ce[_0x14129a('0xfc9')]({'title':_0x5efba5[_0x14129a('0x52d')]?'API:'+_0x5efba5['status']+_0x14129a('0x11e1')+_0x5efba5[_0x14129a('0xe1b')]:_0x14129a('0x153e'),'msg':_0x5efba5['status']?JSON[_0x14129a('0xbac')](_0x5efba5[_0x14129a('0x25f4')]):_0x5efba5[_0x14129a('0x1586')]()});});}let _0x3b905d=!![],_0xf0c50a=0x1;_0x5b1e04[_0x4129b6('0xe83')](_0x4129b6('0x12d8'),function(_0x3499b8,_0x242de3){const _0x55211a=_0x4129b6;_0x3b905d?_0x37b1be(function(){_0x3b905d=![];}):(!_0x242de3&&(_0xf0c50a=_0x364032[_0x55211a('0x2218')][_0x55211a('0x1a43')]),_0x3499b8!==_0x242de3&&(_0x364032[_0x55211a('0x2218')][_0x55211a('0x1a43')]=0x1),!_0x3499b8&&(_0x364032[_0x55211a('0x2218')][_0x55211a('0x1a43')]=_0xf0c50a),_0x364032[_0x55211a('0x478')]());});function _0x5a8783(_0xa7e990){_0x364032['queueCampaigns']=_0xa7e990||{'count':0x0,'rows':[]};}function _0x1f40ec(){const _0x5442e8=_0x4129b6;_0x364032[_0x5442e8('0x2218')][_0x5442e8('0x1098')]=(_0x364032['query'][_0x5442e8('0x1a43')]-0x1)*_0x364032[_0x5442e8('0x2218')]['limit'],_0x56fd59[_0x5442e8('0x1ac6')](_0x5442e8('0xa7c'))?_0x364032['promise']=_0x4e958e[_0x5442e8('0x1943')]['get'](_0x364032['query'],_0x5a8783)[_0x5442e8('0xa44')]:(_0x364032[_0x5442e8('0x2218')]['id']=_0x364032[_0x5442e8('0x7f')]['id'],_0x364032[_0x5442e8('0x2218')][_0x5442e8('0xe60')]=_0x5442e8('0x9f4'),_0x364032['promise']=_0x4e958e[_0x5442e8('0x7f')][_0x5442e8('0x263a')](_0x364032[_0x5442e8('0x2218')],_0x5a8783)[_0x5442e8('0xa44')]);}function _0x486f18(_0x3d86b2,_0x5a238b){const _0x49d4cf=_0x4129b6;_0x328b91[_0x49d4cf('0x1f80')]({'controller':_0x49d4cf('0x740'),'controllerAs':'vm','templateUrl':_0xefbac1,'parent':angular[_0x49d4cf('0x1194')](_0x36ae05[_0x49d4cf('0x8d2')]),'targetEvent':_0x3d86b2,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x5a238b,'queueCampaigns':_0x364032[_0x49d4cf('0x182c')][_0x49d4cf('0x269a')],'license':_0x364032[_0x49d4cf('0x5c9')],'setting':_0x364032['setting'],'crudPermissions':_0x364032[_0x49d4cf('0x243c')]}});}function _0x6c61e5(_0x4a9286){const _0x526f3c=_0x4129b6;_0x4e958e[_0x526f3c('0x1943')][_0x526f3c('0x906')]({'id':_0x4a9286['id']})[_0x526f3c('0xa44')]['then'](function(){const _0x2c0cf1=_0x526f3c;_0x2cfb05()[_0x2c0cf1('0x127f')](_0x364032[_0x2c0cf1('0x182c')][_0x2c0cf1('0x269a')],{'id':_0x4a9286['id']}),_0x364032[_0x2c0cf1('0x182c')][_0x2c0cf1('0x240f')]-=0x1,!_0x364032[_0x2c0cf1('0x182c')][_0x2c0cf1('0x269a')][_0x2c0cf1('0x264b')]&&_0x364032['getQueueCampaigns'](),_0x5bc4ce[_0x2c0cf1('0x103b')]({'title':_0x2cfb05()['startCase']('QueueCampaign')+_0x2c0cf1('0x2b6'),'msg':_0x4a9286['name']?_0x4a9286['name']+'\x20has\x20been\x20deleted!':''});})[_0x526f3c('0x1a80')](function(_0x256202){const _0x28aa46=_0x526f3c;if(_0x256202[_0x28aa46('0x25f4')]&&_0x256202[_0x28aa46('0x25f4')][_0x28aa46('0x61a')]&&_0x256202[_0x28aa46('0x25f4')]['errors'][_0x28aa46('0x264b')]){_0x364032[_0x28aa46('0x61a')]=_0x256202[_0x28aa46('0x25f4')][_0x28aa46('0x61a')]||[{'message':_0x256202[_0x28aa46('0x1586')](),'type':_0x28aa46('0x466')}];for(let _0x569dd0=0x0;_0x569dd0<_0x256202[_0x28aa46('0x25f4')][_0x28aa46('0x61a')][_0x28aa46('0x264b')];_0x569dd0++){_0x5bc4ce[_0x28aa46('0xfc9')]({'title':_0x256202[_0x28aa46('0x25f4')]['errors'][_0x569dd0][_0x28aa46('0x1345')],'msg':_0x256202[_0x28aa46('0x25f4')]['errors'][_0x569dd0]['message']});}}else _0x5bc4ce[_0x28aa46('0xfc9')]({'title':_0x256202[_0x28aa46('0x52d')]?_0x28aa46('0x1e21')+_0x256202[_0x28aa46('0x52d')]+_0x28aa46('0x11e1')+_0x256202[_0x28aa46('0xe1b')]:_0x28aa46('0x466'),'msg':_0x256202['data']?JSON[_0x28aa46('0xbac')](_0x256202[_0x28aa46('0x25f4')]['message']):_0x256202['message']||_0x256202[_0x28aa46('0x1586')]()});});}function _0x2b9d9f(){const _0x4ccbe8=_0x4129b6,_0x54c620=angular[_0x4ccbe8('0x225f')](_0x364032[_0x4ccbe8('0xd6d')]);return _0x364032[_0x4ccbe8('0xd6d')]=[],_0x54c620;}function _0x1404af(_0x4b0297){const _0x5a3ebc=_0x4129b6,_0x192bf0=_0x328b91['confirm']()[_0x5a3ebc('0xcdc')](_0x5a3ebc('0x76e'))['htmlContent'](_0x5a3ebc('0x12b5')+_0x364032[_0x5a3ebc('0xd6d')][_0x5a3ebc('0x264b')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x5a3ebc('0x8e8')](_0x5a3ebc('0x1e3b'))[_0x5a3ebc('0x203b')](_0x4b0297)['ok']('OK')['cancel']('CANCEL');_0x328b91[_0x5a3ebc('0x1f80')](_0x192bf0)[_0x5a3ebc('0x1166')](function(){const _0x505449=_0x5a3ebc;_0x364032[_0x505449('0xd6d')][_0x505449('0x2782')](function(_0x367fdc){_0x6c61e5(_0x367fdc);}),_0x364032['selectedQueueCampaigns']=[];});}function _0x110eb2(){const _0x456c98=_0x4129b6;_0x364032[_0x456c98('0xd6d')]=[];}function _0xfcae0(){const _0x14983f=_0x4129b6;_0x364032[_0x14983f('0xd6d')]=_0x364032[_0x14983f('0x182c')]['rows'];}}const _0x42a38e=_0xfe0aa0;_0x3bbe13[_0x36e6f4('0x1294')]=['$stateProvider',_0x36e6f4('0x1562')];function _0x3bbe13(_0x473681,_0x1002db){const _0x346864=_0x36e6f4;_0x473681[_0x346864('0x63f')](_0x346864('0xa6e'),{'abstract':!![],'url':_0x346864('0x26f4')})[_0x346864('0x63f')](_0x346864('0xd3c'),{'url':_0x346864('0x172e'),'views':{'content@app':{'templateUrl':_0x28598d,'controller':_0x346864('0x11fd')}},'resolve':{'queueCampaigns':['apiResolver',_0x346864('0x21ef'),function(_0x16a817,_0x194489){const _0x3a22b8=_0x346864;return _0x194489[_0x3a22b8('0x1ac6')](_0x3a22b8('0xa7c'))?_0x16a817[_0x3a22b8('0x18af')](_0x3a22b8('0x2700'),{'fields':_0x3a22b8('0x2413'),'type':_0x3a22b8('0x587'),'sort':_0x3a22b8('0x14dc'),'channel':_0x3a22b8('0x21da'),'limit':0xa,'offset':0x0}):_0x16a817['resolve'](_0x3a22b8('0x17c4'),{'id':_0x194489['getCurrentUser']()[_0x3a22b8('0xb86')],'section':_0x3a22b8('0x9f4'),'fields':'createdAt,updatedAt,id,name,dialActive,TrunkId,TrunkBackupId,type,IntervalId,dialCheckDuplicateType,dialCutDigit,acw,acwTimeout,autopause,ringinuse,memberdelay,timeoutrestart,monitor_format,context,setinterfacevar,setqueuevar,setqueueentryvar,dialOrderByScheduledAt,dialRecallMeTimeout,dialRecallInQueue,dialGlobalInterval,dialTimezone,dialAMDActive,dialAMDInitialSilence,dialAMDGreeting,dialAMDAfterGreetingSilence,dialAMDTotalAnalysisTime,dialAMDMinWordLength,dialAMDBetweenWordsSilence,dialAMDMaximumNumberOfWords,dialAMDSilenceThreshold,dialAMDMaximumWordLength,dialMethod,dialPowerLevel,dialPredictiveOptimization,dialPredictiveOptimizationPercentage,dialPredictiveInterval,dialLimitQueue,dialOriginateCallerIdName,dialOriginateCallerIdNumber,dialRandomLastDigitCallerIdNumber,dialOriginateTimeout,dialPrefix,dialQueueOptions,dialQueueTimeout,strategy,timeout,retry,wrapuptime,weight,musiconhold,dialQueueProject,dialQueueProject2,dialAgiAfterHangupAgent,dialGlobalMaxRetry,dialCongestionMaxRetry,dialCongestionRetryFrequency,dialBusyMaxRetry,dialBusyRetryFrequency,dialNoAnswerMaxRetry,dialNoAnswerRetryFrequency,dialNoSuchNumberMaxRetry,dialNoSuchNumberRetryFrequency,dialDropMaxRetry,dialDropRetryFrequency,dialAbandonedMaxRetry,dialAbandonedRetryFrequency,dialMachineMaxRetry,dialMachineRetryFrequency,dialAgentRejectMaxRetry,dialAgentRejectRetryFrequency,description,mandatoryDisposition,mandatoryDispositionPauseId,dialPredictiveIntervalMaxThreshold,dialPredictiveIntervalMinThreshold','type':_0x3a22b8('0x587'),'sort':_0x3a22b8('0x14dc'),'channel':_0x3a22b8('0x21da'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x346864('0x1fbc'),_0x346864('0x21ef'),function(_0x5b5385,_0x5ca710){const _0x54523b=_0x346864;return _0x5ca710[_0x54523b('0x1ac6')](_0x54523b('0xa7c'))?null:_0x5b5385[_0x54523b('0x18af')](_0x54523b('0x697'),{'fields':'id,name,crudPermissions','id':_0x5ca710[_0x54523b('0x26cd')]()[_0x54523b('0xb86')]});}],'userProfileSection':[_0x346864('0x1fbc'),_0x346864('0x21ef'),function(_0xa77321,_0x83df51){const _0x1bd030=_0x346864;return _0x83df51[_0x1bd030('0x1ac6')](_0x1bd030('0xa7c'))?null:_0xa77321[_0x1bd030('0x18af')]('userProfileSection@get',{'fields':_0x1bd030('0xe26'),'userProfileId':_0x83df51['getCurrentUser']()[_0x1bd030('0xb86')],'sectionId':0x5dd});}]},'authenticate':!![],'permissionId':0x5dd,'bodyClass':_0x346864('0x1b48')})[_0x346864('0x63f')](_0x346864('0x14d4'),{'url':'/:id?tab','params':{'queueCampaign':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0xe20aad,'controller':'QueueCampaignController\x20as\x20vm'}},'resolve':{'queueCampaign':['apiResolver',_0x346864('0xf75'),function(_0x94d171,_0xe8250a){const _0x1ddc2b=_0x346864;return _0x94d171['resolve']('voiceQueue@get',{'fields':_0x1ddc2b('0x2413'),'id':_0xe8250a['id']});}],'userProfileSection':['apiResolver',_0x346864('0x21ef'),function(_0x216c4b,_0x1a6f26){const _0x5c1735=_0x346864;return _0x216c4b['resolve']('userProfileSection@get',{'fields':_0x5c1735('0xe26'),'userProfileId':_0x1a6f26['getCurrentUser']()[_0x5c1735('0xb86')],'sectionId':0x5dd});}]},'authenticate':!![],'permissionId':0x5dd,'bodyClass':'motiondialer'})[_0x346864('0x63f')](_0x346864('0x100'),{'url':_0x346864('0xfa0'),'views':{'content@app':{'templateUrl':_0x1bfa25,'controller':_0x346864('0xaa4')}},'resolve':{'ivrCampaigns':['apiResolver',_0x346864('0x21ef'),function(_0x132a38,_0x3b6431){const _0x4b3dc3=_0x346864;return _0x3b6431[_0x4b3dc3('0x1ac6')](_0x4b3dc3('0xa7c'))?_0x132a38[_0x4b3dc3('0x18af')]('campaign@get',{'fields':_0x4b3dc3('0x2547'),'type':_0x4b3dc3('0x681'),'sort':_0x4b3dc3('0x14dc'),'limit':0xa,'offset':0x0}):_0x132a38[_0x4b3dc3('0x18af')]('userProfile@getResources',{'id':_0x3b6431[_0x4b3dc3('0x26cd')]()[_0x4b3dc3('0xb86')],'section':_0x4b3dc3('0x9d3'),'fields':'createdAt,updatedAt,id,name,active,TrunkId,TrunkBackupId,type,IntervalId,dialCheckDuplicateType,dialCutDigit,SquareProjectId,limitCalls,description,dialOriginateCallerIdName,dialOriginateCallerIdNumber,dialRandomLastDigitCallerIdNumber,dialOriginateTimeout,dialGlobalMaxRetry,dialCongestionMaxRetry,dialCongestionRetryFrequency,dialBusyMaxRetry,dialBusyRetryFrequency,dialNoAnswerMaxRetry,dialNoAnswerRetryFrequency,dialNoSuchNumberMaxRetry,dialNoSuchNumberRetryFrequency,dialDropMaxRetry,dialDropRetryFrequency,dialAbandonedMaxRetry,dialAbandonedRetryFrequency,dialMachineMaxRetry,dialMachineRetryFrequency,dialAgentRejectMaxRetry,dialAgentRejectRetryFrequency,dialOrderByScheduledAt,dialGlobalInterval,dialTimezone,dialPrefix,dialAMDActive,dialAMDInitialSilence,dialAMDGreeting,dialAMDAfterGreetingSilence,dialAMDTotalAnalysisTime,dialAMDMinWordLength,dialAMDBetweenWordsSilence,dialAMDMaximumNumberOfWords,dialAMDSilenceThreshold,dialAMDMaximumWordLength','type':_0x4b3dc3('0x681'),'sort':_0x4b3dc3('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x346864('0x21ef'),function(_0x184753,_0x11df66){const _0x11fd4f=_0x346864;return _0x11df66[_0x11fd4f('0x1ac6')](_0x11fd4f('0xa7c'))?null:_0x184753['resolve'](_0x11fd4f('0x697'),{'fields':_0x11fd4f('0x686'),'id':_0x11df66[_0x11fd4f('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x346864('0x1fbc'),_0x346864('0x21ef'),function(_0x5e0403,_0x5efbb8){const _0x23cedb=_0x346864;return _0x5efbb8[_0x23cedb('0x1ac6')](_0x23cedb('0xa7c'))?null:_0x5e0403[_0x23cedb('0x18af')]('userProfileSection@get',{'fields':_0x23cedb('0xe26'),'userProfileId':_0x5efbb8[_0x23cedb('0x26cd')]()[_0x23cedb('0xb86')],'sectionId':0x5de});}]},'authenticate':!![],'permissionId':0x5de,'bodyClass':_0x346864('0x1b48')})[_0x346864('0x63f')](_0x346864('0x2329'),{'url':_0x346864('0x2233'),'params':{'ivrCampaign':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x1666fc,'controller':'IvrCampaignController\x20as\x20vm'}},'resolve':{'ivrCampaign':[_0x346864('0x1fbc'),'$stateParams',function(_0xde729d,_0x205af5){const _0x1c7a5=_0x346864;return _0xde729d[_0x1c7a5('0x18af')](_0x1c7a5('0xa31'),{'fields':_0x1c7a5('0x2547'),'id':_0x205af5['id']});}],'userProfileSection':[_0x346864('0x1fbc'),_0x346864('0x21ef'),function(_0x214469,_0x9c2be9){const _0x249154=_0x346864;return _0x214469[_0x249154('0x18af')](_0x249154('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x9c2be9['getCurrentUser']()[_0x249154('0xb86')],'sectionId':0x5de});}]},'authenticate':!![],'permissionId':0x5de,'bodyClass':_0x346864('0x1b48')}),_0x1002db[_0x346864('0x95e')]('app/main/apps/motiondialer');}angular[_0x36e6f4('0x896')](_0x36e6f4('0xa6e'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),'flow',_0x36e6f4('0x107d'),'ckeditor',_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),'ngAnimate',_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),'angular-cron-jobs',_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),'chart.js',_0x36e6f4('0x411'),_0x36e6f4('0x1f08')])[_0x36e6f4('0xe11')](_0x3bbe13)[_0x36e6f4('0x75e')](_0x36e6f4('0xb5f'),_0x3ac5a5)[_0x36e6f4('0x75e')](_0x36e6f4('0x17d7'),_0x4cea70)[_0x36e6f4('0x75e')]('IvrCampaigncloneController',_0x44fa10)[_0x36e6f4('0x75e')](_0x36e6f4('0x28a'),_0x3c0b3a)[_0x36e6f4('0x75e')](_0x36e6f4('0x1e72'),_0x46dc13)[_0x36e6f4('0x75e')](_0x36e6f4('0x26f7'),_0x1a9f64)[_0x36e6f4('0x75e')](_0x36e6f4('0x259e'),_0x4eead9)[_0x36e6f4('0x75e')](_0x36e6f4('0x155d'),_0x42740f)[_0x36e6f4('0x75e')](_0x36e6f4('0x291'),_0x19e2d9)[_0x36e6f4('0x75e')]('IvrCampaignlistaddController',_0x29d0f9)['controller'](_0x36e6f4('0x918'),_0x30cea3)['controller']('IvrCampaignController',_0x4ab048)['controller'](_0x36e6f4('0xbf5'),_0xa07ebf)[_0x36e6f4('0x75e')](_0x36e6f4('0x740'),_0x278b4c)['controller'](_0x36e6f4('0x27c1'),_0x32e937)[_0x36e6f4('0x75e')](_0x36e6f4('0x245f'),_0x330df2)[_0x36e6f4('0x75e')]('QueueCampaigncloneController',_0x23f948)[_0x36e6f4('0x75e')](_0x36e6f4('0x220d'),_0x36ded2)[_0x36e6f4('0x75e')](_0x36e6f4('0xab0'),_0x393f20)[_0x36e6f4('0x75e')](_0x36e6f4('0x1e5f'),_0x4b4815)[_0x36e6f4('0x75e')](_0x36e6f4('0x1cba'),_0x26b5ec)['controller'](_0x36e6f4('0x1c8c'),_0x32ac7c)[_0x36e6f4('0x75e')](_0x36e6f4('0x1e83'),_0x1cb31a)[_0x36e6f4('0x75e')]('QueueCampaignlistaddController',_0x46701c)[_0x36e6f4('0x75e')](_0x36e6f4('0x1fba'),_0x27a58f)['controller'](_0x36e6f4('0x24c6'),_0x1cf161)[_0x36e6f4('0x75e')](_0x36e6f4('0x1938'),_0x423ee4)['controller']('QueueCampaignsController',_0x42a38e);const _0x5ec99a=_0x2734b2['p']+'src/js/modules/main/apps/help/views/about/about.html/about.html';_0x3fa578[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1fa1'),_0x36e6f4('0x5c9'),'api'];function _0x2f01d4(_0x280c27){const _0x3eb66f=_0x36e6f4,_0x39a837=_0x24273b()(_0x280c27);return _0x39a837[_0x3eb66f('0x26ef')]()?_0x39a837[_0x3eb66f('0x128a')](_0x3eb66f('0xa7b')):'';}function _0x3fa578(_0x34ac42,_0x5bbb35,_0x1a12f5){const _0x1768db=_0x36e6f4,_0x819f7c=this;_0x819f7c[_0x1768db('0xf06')]=_0x1a12f5['baseUrl'],_0x819f7c['info']={..._0x34ac42,'buildDate':_0x2f01d4(_0x34ac42[_0x1768db('0x23ee')]),'commitDate':_0x2f01d4(_0x34ac42[_0x1768db('0x1c22')]),'client':{'name':_0x1768db('0x251a'),'version':_0x1768db('0x8e'),'shortHash':_0x1768db('0xeca'),'branch':_0x1768db('0x17e3'),'tag':'','committedOn':_0x1768db('0xff6'),'buildDate':'2020-11-12T18:56:25.149Z'}},_0x819f7c['license']=_0x5bbb35;}const _0x141621=_0x3fa578;_0x297448[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c')];function _0x297448(_0x14ccc3){const _0x544b23=_0x36e6f4;_0x14ccc3['state'](_0x544b23('0x333'),{'url':_0x544b23('0xfcf'),'views':{'content@app':{'templateUrl':_0x5ec99a,'controller':_0x544b23('0x2002')}},'resolve':{'info':[_0x544b23('0x1fbc'),function(_0x205fb2){const _0x1fc944=_0x544b23;return _0x205fb2[_0x1fc944('0x18af')](_0x1fc944('0x42f'));}]},'authenticate':!![],'permissionId':0x640,'bodyClass':'help'});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x333'),[])[_0x36e6f4('0xe11')](_0x297448)[_0x36e6f4('0x75e')](_0x36e6f4('0x19a4'),_0x141621),_0xc742b1[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),'$translatePartialLoaderProvider'];function _0xc742b1(_0x85c28a,_0x5b4328){const _0x1527fb=_0x36e6f4;_0x85c28a[_0x1527fb('0x63f')](_0x1527fb('0x53a'),{'abstract':!![],'url':_0x1527fb('0x21b3')}),_0x5b4328[_0x1527fb('0x95e')]('app/main/apps/help');}angular[_0x36e6f4('0x896')](_0x36e6f4('0x53a'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),'flow','mdColorPicker',_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),'ngAria',_0x36e6f4('0x2467'),'mdPickers',_0x36e6f4('0xe12'),'mwFormViewer','mwFormUtils',_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),'angular.filter','app.help.about'])[_0x36e6f4('0xe11')](_0xc742b1);const _0x4d7bf1=_0x2734b2['p']+_0x36e6f4('0x162c'),_0x456e43=_0x2734b2['p']+'src/js/modules/main/apps/jscripty/views/projects/edit/view.html/view.html';_0x63da4c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x149f'),'project',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x63da4c(_0x3a4b22,_0x46c918,_0x553790,_0x4d8180,_0x137579,_0x419ba8,_0x321fd3,_0x2af3d3,_0x1f4389,_0x102cdc,_0x588111,_0xbb1c89,_0x54ee0b,_0x25b823){const _0x1ce5df=_0x36e6f4,_0x53f424=this;_0x53f424[_0x1ce5df('0x98')]=_0x588111[_0x1ce5df('0x26cd')](),_0x53f424[_0x1ce5df('0x61a')]=[],_0x53f424[_0x1ce5df('0xf8a')]=_0x54ee0b,_0x53f424[_0x1ce5df('0x5c9')]=_0xbb1c89,_0x53f424[_0x1ce5df('0x243c')]=_0x25b823,_0x53f424[_0x1ce5df('0x128b')]={},_0x53f424[_0x1ce5df('0x2900')]=_0x53f424[_0x1ce5df('0xf8a')]&&_0x53f424[_0x1ce5df('0xf8a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x53f424[_0x1ce5df('0xcdc')]=_0x1ce5df('0x1eaa'),_0x53f424['project']=angular[_0x1ce5df('0x225f')](_0x1f4389),_0x53f424[_0x1ce5df('0x149f')]=_0x2af3d3,_0x53f424[_0x1ce5df('0x5e0')]=![];!_0x53f424[_0x1ce5df('0x2588')]&&(_0x53f424[_0x1ce5df('0x2588')]={'enableUncompleteSave':!![],'sendUnpauseOnSubmit':!![]},_0x53f424[_0x1ce5df('0xcdc')]=_0x1ce5df('0x13e2'),_0x53f424['newProject']=!![]);_0x53f424[_0x1ce5df('0x2421')]=_0x589726,_0x53f424[_0x1ce5df('0x16c1')]=_0x25f5b1,_0x53f424['deleteProject']=_0x2a3d79,_0x53f424[_0x1ce5df('0x1a9c')]=_0x5cfe86,_0x53f424[_0x1ce5df('0x24a0')]=_0x387785;function _0x589726(){const _0x5207b4=_0x1ce5df;_0x53f424['errors']=[],_0x102cdc[_0x5207b4('0x129b')][_0x5207b4('0x9cc')](_0x53f424[_0x5207b4('0x2588')])[_0x5207b4('0xa44')][_0x5207b4('0x1166')](function(_0x193c85){const _0x3fa591=_0x5207b4;_0x53f424['projects'][_0x3fa591('0x2450')](_0x193c85[_0x3fa591('0x2876')]()),_0x321fd3['success']({'title':'Project\x20properly\x20created','msg':_0x53f424[_0x3fa591('0x2588')][_0x3fa591('0x4f0')]?_0x53f424[_0x3fa591('0x2588')][_0x3fa591('0x4f0')]+_0x3fa591('0x1eda'):''}),_0x387785(_0x193c85);})[_0x5207b4('0x1a80')](function(_0x726065){const _0x30d391=_0x5207b4;if(_0x726065[_0x30d391('0x25f4')]&&_0x726065[_0x30d391('0x25f4')][_0x30d391('0x61a')]&&_0x726065[_0x30d391('0x25f4')]['errors']['length']){_0x53f424[_0x30d391('0x61a')]=_0x726065[_0x30d391('0x25f4')]['errors']||[{'message':_0x726065['toString'](),'type':_0x30d391('0x119e')}];for(let _0x443d37=0x0;_0x443d37<_0x726065[_0x30d391('0x25f4')]['errors'][_0x30d391('0x264b')];_0x443d37+=0x1){_0x321fd3[_0x30d391('0xfc9')]({'title':_0x726065['data'][_0x30d391('0x61a')][_0x443d37][_0x30d391('0x1345')],'msg':_0x726065['data'][_0x30d391('0x61a')][_0x443d37][_0x30d391('0x1e70')]});}}else _0x321fd3[_0x30d391('0xfc9')]({'title':_0x726065[_0x30d391('0x52d')]?_0x30d391('0x1e21')+_0x726065[_0x30d391('0x52d')]+_0x30d391('0x11e1')+_0x726065['statusText']:_0x30d391('0x119e'),'msg':_0x726065[_0x30d391('0x25f4')]?JSON[_0x30d391('0xbac')](_0x726065[_0x30d391('0x25f4')][_0x30d391('0x1e70')]):_0x726065[_0x30d391('0x1586')]()});});}function _0x25f5b1(){const _0x374d0c=_0x1ce5df;_0x53f424['errors']=[],_0x102cdc[_0x374d0c('0x129b')][_0x374d0c('0x1449')]({'id':_0x53f424[_0x374d0c('0x2588')]['id']},_0x53f424[_0x374d0c('0x2588')])[_0x374d0c('0xa44')][_0x374d0c('0x1166')](function(_0x3b54e5){const _0x315fb0=_0x374d0c,_0x1724a7=_0x2cfb05()['find'](_0x53f424[_0x315fb0('0x149f')],{'id':_0x3b54e5['id']});_0x1724a7&&_0x2cfb05()['merge'](_0x1724a7,_0x2cfb05()[_0x315fb0('0x1a08')](_0x3b54e5[_0x315fb0('0x2876')](),_0x2cfb05()['keys'](_0x1724a7))),_0x321fd3[_0x315fb0('0x103b')]({'title':_0x315fb0('0xb2f'),'msg':_0x53f424[_0x315fb0('0x2588')]['name']?_0x53f424[_0x315fb0('0x2588')]['name']+_0x315fb0('0x7d'):''}),_0x387785(_0x3b54e5);})[_0x374d0c('0x1a80')](function(_0x467f66){const _0x3c14a3=_0x374d0c;if(_0x467f66[_0x3c14a3('0x25f4')]&&_0x467f66[_0x3c14a3('0x25f4')][_0x3c14a3('0x61a')]&&_0x467f66[_0x3c14a3('0x25f4')][_0x3c14a3('0x61a')][_0x3c14a3('0x264b')]){_0x53f424[_0x3c14a3('0x61a')]=_0x467f66[_0x3c14a3('0x25f4')][_0x3c14a3('0x61a')]||[{'message':_0x467f66[_0x3c14a3('0x1586')](),'type':_0x3c14a3('0x2144')}];for(let _0x465af3=0x0;_0x465af3<_0x467f66['data']['errors'][_0x3c14a3('0x264b')];_0x465af3++){_0x321fd3[_0x3c14a3('0xfc9')]({'title':_0x467f66[_0x3c14a3('0x25f4')][_0x3c14a3('0x61a')][_0x465af3][_0x3c14a3('0x1345')],'msg':_0x467f66[_0x3c14a3('0x25f4')]['errors'][_0x465af3][_0x3c14a3('0x1e70')]});}}else _0x321fd3[_0x3c14a3('0xfc9')]({'title':_0x467f66['status']?_0x3c14a3('0x1e21')+_0x467f66['status']+_0x3c14a3('0x11e1')+_0x467f66[_0x3c14a3('0xe1b')]:_0x3c14a3('0x2144'),'msg':_0x467f66['data']?JSON[_0x3c14a3('0xbac')](_0x467f66[_0x3c14a3('0x25f4')][_0x3c14a3('0x1e70')]):_0x467f66[_0x3c14a3('0x1586')]()});});}function _0x2a3d79(_0xf6bea2){const _0x3d48fe=_0x1ce5df;_0x53f424['errors']=[];const _0x3eb959=_0x4d8180['confirm']()[_0x3d48fe('0xcdc')]('Are\x20you\x20sure?')['content'](_0x3d48fe('0x30'))[_0x3d48fe('0x8e8')]('Delete\x20Project')['ok'](_0x3d48fe('0x18'))[_0x3d48fe('0x3f')]('Cancel')[_0x3d48fe('0x203b')](_0xf6bea2);_0x4d8180[_0x3d48fe('0x1f80')](_0x3eb959)[_0x3d48fe('0x1166')](function(){const _0x318274=_0x3d48fe;_0x102cdc['jscriptyProject'][_0x318274('0x906')]({'id':_0x53f424['project']['id']})[_0x318274('0xa44')][_0x318274('0x1166')](function(){const _0x129ab7=_0x318274;_0x2cfb05()['remove'](_0x53f424[_0x129ab7('0x149f')],{'id':_0x53f424[_0x129ab7('0x2588')]['id']}),_0x321fd3[_0x129ab7('0x103b')]({'title':'Project\x20properly\x20deleted!','msg':(_0x53f424[_0x129ab7('0x2588')][_0x129ab7('0x4f0')]||_0x129ab7('0x2588'))+_0x129ab7('0x7cd')}),_0x387785(_0x53f424['project']);})[_0x318274('0x1a80')](function(_0x9d9101){const _0x2ea7ba=_0x318274;if(_0x9d9101['data']&&_0x9d9101[_0x2ea7ba('0x25f4')][_0x2ea7ba('0x61a')]&&_0x9d9101['data'][_0x2ea7ba('0x61a')]['length']){_0x53f424[_0x2ea7ba('0x61a')]=_0x9d9101['data']['errors']||[{'message':_0x9d9101[_0x2ea7ba('0x1586')](),'type':_0x2ea7ba('0x198b')}];for(let _0x40357f=0x0;_0x40357f<_0x9d9101[_0x2ea7ba('0x25f4')][_0x2ea7ba('0x61a')][_0x2ea7ba('0x264b')];_0x40357f++){_0x321fd3[_0x2ea7ba('0xfc9')]({'title':_0x9d9101[_0x2ea7ba('0x25f4')][_0x2ea7ba('0x61a')][_0x40357f][_0x2ea7ba('0x1345')],'msg':_0x9d9101[_0x2ea7ba('0x25f4')]['errors'][_0x40357f][_0x2ea7ba('0x1e70')]});}}else _0x321fd3[_0x2ea7ba('0xfc9')]({'title':_0x9d9101[_0x2ea7ba('0x52d')]?_0x2ea7ba('0x1e21')+_0x9d9101[_0x2ea7ba('0x52d')]+'\x20-\x20'+_0x9d9101[_0x2ea7ba('0xe1b')]:_0x2ea7ba('0x198b'),'msg':_0x9d9101[_0x2ea7ba('0x25f4')]?JSON[_0x2ea7ba('0xbac')](_0x9d9101[_0x2ea7ba('0x25f4')][_0x2ea7ba('0x1e70')]):_0x9d9101[_0x2ea7ba('0x1e70')]||_0x9d9101[_0x2ea7ba('0x1586')]()});});},function(){});}function _0x5cfe86(_0x352563){return _0x352563===null?undefined:new Date(_0x352563);}function _0x387785(_0x5ea077){_0x4d8180['hide'](_0x5ea077);}}const _0x58bf3c=_0x63da4c;_0x2d203e[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1566'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0xf69')];function _0x2d203e(_0xd6c10a,_0x33504b,_0x27ae42,_0x6cd951,_0x27516d,_0x6953e1){const _0x19611f=_0x36e6f4,_0x4a4efd=this;_0x4a4efd[_0x19611f('0x2588')]={},_0x4a4efd['localizationMap']=_0x6953e1;const _0x2abe11=new Date();_0x2abe11[_0x19611f('0xe24')](0x0,0x0,0x0,0x0),_0x4a4efd[_0x19611f('0x25f3')]={'dateStart':new Date(_0x2abe11[_0x19611f('0x1e4f')](),_0x2abe11[_0x19611f('0xd60')](),0x1),'dateEnd':new Date(_0x2abe11[_0x19611f('0x1e4f')](),_0x2abe11[_0x19611f('0xd60')]()+0x1,0x0),'selectedTemplate':'TM'},_0x4a4efd['init']=_0x59dec1,_0x4a4efd[_0x19611f('0x1dcf')]=_0xd70e3d,_0x4a4efd['getAnswers']=_0x36282e;function _0x36282e(){const _0x1b41e7=_0x19611f;return _0x4a4efd[_0x1b41e7('0x203f')]=![],_0x6cd951['jscriptyProject']['getAnswers']({'id':_0x4a4efd['project']['id'],'sort':_0x1b41e7('0xc67'),'createdAt':{'$gte':_0x24273b()(_0x4a4efd[_0x1b41e7('0x25f3')]['dateStart'])[_0x1b41e7('0x126a')](0x0,'hours')[_0x1b41e7('0x126a')](0x0,_0x1b41e7('0xcf7'))[_0x1b41e7('0x126a')](0x0,_0x1b41e7('0x1aa6'))[_0x1b41e7('0x13f2')](0x0,!![])['format'](),'$lte':_0x24273b()(_0x4a4efd[_0x1b41e7('0x25f3')][_0x1b41e7('0x15c6')])[_0x1b41e7('0x126a')](0x17,_0x1b41e7('0xf08'))['add'](0x3b,_0x1b41e7('0xcf7'))[_0x1b41e7('0x126a')](0x3b,'seconds')['utcOffset'](0x0,!![])[_0x1b41e7('0x128a')]()},'nolimit':!![]})[_0x1b41e7('0xa44')][_0x1b41e7('0x1166')](function(_0x559897){const _0x50c3a4=_0x1b41e7;if(_0x559897&&_0x559897['rows']&&typeof _0x559897[_0x50c3a4('0x240f')]!==_0x50c3a4('0x1048')){_0x4a4efd[_0x50c3a4('0x9fe')]={};for(let _0xdae2=0x0,_0x2ca578=_0x559897[_0x50c3a4('0x240f')];_0xdae2<_0x2ca578;_0xdae2++){_0x559897['rows'][_0xdae2][_0x50c3a4('0x28db')]&&(_0x4a4efd[_0x50c3a4('0x203f')]=!![],typeof _0x4a4efd[_0x50c3a4('0x9fe')][_0x559897['rows'][_0xdae2]['questionId']]===_0x50c3a4('0x1048')&&(_0x4a4efd[_0x50c3a4('0x9fe')][_0x559897[_0x50c3a4('0x269a')][_0xdae2][_0x50c3a4('0x28db')]]={'question':_0x559897[_0x50c3a4('0x269a')][_0xdae2][_0x50c3a4('0x9b')],'answers':{},'sum':0x0}),_0x559897[_0x50c3a4('0x269a')][_0xdae2]['answer']===''&&(_0x559897[_0x50c3a4('0x269a')][_0xdae2][_0x50c3a4('0x1de9')]=_0x50c3a4('0x1c2a')),_0x4a4efd[_0x50c3a4('0x9fe')][_0x559897[_0x50c3a4('0x269a')][_0xdae2][_0x50c3a4('0x28db')]]['answers'][_0x559897[_0x50c3a4('0x269a')][_0xdae2][_0x50c3a4('0x1de9')]]?_0x4a4efd[_0x50c3a4('0x9fe')][_0x559897[_0x50c3a4('0x269a')][_0xdae2][_0x50c3a4('0x28db')]]['answers'][_0x559897[_0x50c3a4('0x269a')][_0xdae2][_0x50c3a4('0x1de9')]]+=0x1:_0x4a4efd[_0x50c3a4('0x9fe')][_0x559897[_0x50c3a4('0x269a')][_0xdae2][_0x50c3a4('0x28db')]][_0x50c3a4('0x9fe')][_0x559897[_0x50c3a4('0x269a')][_0xdae2]['answer']]=0x1,_0x4a4efd[_0x50c3a4('0x9fe')][_0x559897[_0x50c3a4('0x269a')][_0xdae2][_0x50c3a4('0x28db')]][_0x50c3a4('0x1e9b')]+=0x1);}}})[_0x1b41e7('0x1a80')](function(_0x407331){const _0x315d93=_0x1b41e7;_0x27516d[_0x315d93('0xfc9')]({'title':_0x407331[_0x315d93('0x52d')]?'API:'+_0x407331['status']+_0x315d93('0x11e1')+_0x407331['statusText']:_0x315d93('0x1d69'),'msg':_0x407331[_0x315d93('0x25f4')]?JSON[_0x315d93('0xbac')](_0x407331['data']):_0x407331[_0x315d93('0x1586')]()});});}function _0x59dec1(_0x2a4897){const _0x2b90a2=_0x19611f;_0x4a4efd[_0x2b90a2('0x2588')]=_0x2a4897,_0x4a4efd[_0x2b90a2('0xab8')]();}function _0xd70e3d(){const _0x276314=_0x19611f;return _0x6cd951['jscriptyProject'][_0x276314('0x1dcf')]({'id':_0x4a4efd[_0x276314('0x2588')]['id'],'startTime':{'$gte':_0x4a4efd[_0x276314('0x25f3')]['dateStart'],'$lte':_0x24273b()(_0x4a4efd[_0x276314('0x25f3')][_0x276314('0x15c6')])['add'](0x17,'hours')[_0x276314('0x126a')](0x3b,_0x276314('0xcf7'))[_0x276314('0x126a')](0x3b,'seconds')[_0x276314('0x128a')]()},'nolimit':!![]})[_0x276314('0xa44')][_0x276314('0x1166')](function(_0x4573e4){const _0x14ed80=_0x276314;if(typeof _0x4573e4[_0x14ed80('0x264b')]!==_0x14ed80('0x1048')){const _0x30a97a=[_0x4573e4[_0x14ed80('0x20ed')]],_0x11f826=new Blob(_0x30a97a,{'type':_0x4573e4['type']}),_0x22edb5=window['document'][_0x14ed80('0xdd')]('a');_0x22edb5[_0x14ed80('0xffd')](_0x14ed80('0x14f9'),URL[_0x14ed80('0x215a')](_0x11f826)),_0x22edb5[_0x14ed80('0xffd')](_0x14ed80('0x2ad'),_0x14ed80('0x2565')+_0x4a4efd[_0x14ed80('0x2588')]['id']+_0x14ed80('0x1e1')),_0x22edb5[_0x14ed80('0x3b4')]();}else _0x27516d[_0x14ed80('0x1fa1')]({'title':'EXPORT','msg':_0x14ed80('0x1ecf')});})[_0x276314('0x1a80')](function(_0x52ce11){const _0x199d13=_0x276314;_0x27516d['error']({'title':_0x52ce11[_0x199d13('0x52d')]?_0x199d13('0x1e21')+_0x52ce11['status']+'\x20-\x20'+_0x52ce11['statusText']:'api.jscriptyProject.getSummary','msg':_0x52ce11[_0x199d13('0x25f4')]?JSON[_0x199d13('0xbac')](_0x52ce11['data']):_0x52ce11['toString']()});});}}const _0x10a4e8=_0x2d203e;;function _0x2c0fe6(){const _0x41d53d=_0x36e6f4,_0x3a2a21=this;_0x3a2a21[_0x41d53d('0x2588')]={},_0x3a2a21[_0x41d53d('0x3bd')]={'questionTypes':[_0x41d53d('0x1640'),_0x41d53d('0x489'),_0x41d53d('0x1ad7'),_0x41d53d('0x79d'),'select',_0x41d53d('0xc45'),_0x41d53d('0x1643'),_0x41d53d('0x12bf'),_0x41d53d('0x66f'),_0x41d53d('0x23e2'),_0x41d53d('0xcac')],'elementTypes':[_0x41d53d('0x9b'),_0x41d53d('0x1781')]},_0x3a2a21[_0x41d53d('0x24d5')]=_0x3ab9fe,_0x3a2a21[_0x41d53d('0x617')]=_0x1bc0d4;function _0x1bc0d4(_0x10d4d9){const _0x310169=_0x41d53d;if(_0x2cfb05()[_0x310169('0x2863')](_0x10d4d9))return![];try{JSON[_0x310169('0x1295')](_0x10d4d9);}catch(_0x51a9cf){return![];}return!![];}function _0x3ab9fe(_0x3cc5f1){const _0x3606df=_0x41d53d;_0x3a2a21['project']=_0x3cc5f1;if(_0x2cfb05()[_0x3606df('0x186')](_0x3cc5f1['formData']))_0x3a2a21[_0x3606df('0x2588')][_0x3606df('0x1ff2')]=_0x3cc5f1[_0x3606df('0x1ff2')];else _0x3a2a21[_0x3606df('0x617')](_0x3cc5f1[_0x3606df('0x1ff2')])?_0x3a2a21[_0x3606df('0x2588')]['formData']=JSON[_0x3606df('0x1295')](_0x3cc5f1[_0x3606df('0x1ff2')]):_0x3a2a21[_0x3606df('0x2588')][_0x3606df('0x1ff2')]={};}}const _0x3d8ed2=_0x2c0fe6;_0x57332d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$state',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'project',_0x36e6f4('0x149f'),_0x36e6f4('0x586')];function _0x57332d(_0x5cc7cd,_0x25b1aa,_0x47329d,_0x17441f,_0x37efaf,_0x562c84,_0x2cd4a9){const _0x1a0c2a=_0x36e6f4,_0x35b3c1=this;_0x35b3c1['newProject']=!![],_0x35b3c1[_0x1a0c2a('0x2588')]=angular[_0x1a0c2a('0x225f')](_0x37efaf),_0x35b3c1[_0x1a0c2a('0x149f')]=_0x562c84,_0x35b3c1[_0x1a0c2a('0xcdc')]=_0x2cd4a9[_0x1a0c2a('0x25cc')](_0x1a0c2a('0x95f'));_0x37efaf&&_0x37efaf[_0x1a0c2a('0x4f0')]&&(_0x35b3c1['title']+=':\x20'+_0x37efaf[_0x1a0c2a('0x4f0')]);_0x35b3c1[_0x1a0c2a('0x1293')]=_0x22fada,_0x35b3c1[_0x1a0c2a('0x24a0')]=_0x84874c;function _0x22fada(){const _0x4d101c=_0x1a0c2a;return _0x17441f[_0x4d101c('0x129b')]['clone']({'id':_0x37efaf['id']},_0x35b3c1[_0x4d101c('0x2588')])[_0x4d101c('0xa44')]['then'](function(_0x240e95){const _0xaf368f=_0x4d101c;_0x35b3c1[_0xaf368f('0x149f')][_0xaf368f('0x2450')](_0x240e95[_0xaf368f('0x2876')]()),_0x47329d['success']({'title':_0xaf368f('0x2215'),'msg':_0x35b3c1[_0xaf368f('0x2588')]['name']?_0x35b3c1['project'][_0xaf368f('0x4f0')]+_0xaf368f('0x1273'):''}),_0x25b1aa['go']('app.jscripty.projects.edit',{'id':_0x240e95['id']}),_0x84874c(_0x240e95);})[_0x4d101c('0x1a80')](function(_0x408138){const _0xa8534e=_0x4d101c;if(_0x408138[_0xa8534e('0x25f4')]&&_0x408138[_0xa8534e('0x25f4')]['errors']&&_0x408138[_0xa8534e('0x25f4')]['errors'][_0xa8534e('0x264b')]){_0x35b3c1[_0xa8534e('0x61a')]=_0x408138[_0xa8534e('0x25f4')][_0xa8534e('0x61a')]||[{'message':_0x408138['toString'](),'type':_0xa8534e('0x1a87')}];for(let _0x4e09ba=0x0;_0x4e09ba<_0x408138['data'][_0xa8534e('0x61a')][_0xa8534e('0x264b')];_0x4e09ba+=0x1){_0x47329d[_0xa8534e('0xfc9')]({'title':_0x408138[_0xa8534e('0x25f4')][_0xa8534e('0x61a')][_0x4e09ba][_0xa8534e('0x1345')],'msg':_0x408138['data'][_0xa8534e('0x61a')][_0x4e09ba]['message']});}}else _0x47329d[_0xa8534e('0xfc9')]({'title':_0x408138['status']?_0xa8534e('0x1e21')+_0x408138[_0xa8534e('0x52d')]+'\x20-\x20'+_0x408138['statusText']:_0xa8534e('0x1a87'),'msg':_0x408138[_0xa8534e('0x25f4')]?JSON[_0xa8534e('0xbac')](_0x408138[_0xa8534e('0x25f4')][_0xa8534e('0x1e70')]):_0x408138['toString']()});});}function _0x84874c(_0x5c8cd5){_0x5cc7cd['hide'](_0x5c8cd5);}}const _0x1b32dd=_0x57332d;_0x17e605[_0x36e6f4('0x1294')]=['$q',_0x36e6f4('0x265d'),'$scope'];function _0x17e605(_0x5bda9d,_0x98e18f,_0x53f859){const _0x3a2a13=_0x36e6f4,_0x2fdfd3=this;_0x2fdfd3[_0x3a2a13('0x2588')]={},_0x2fdfd3['responseData']={},_0x2fdfd3[_0x3a2a13('0x1c5d')]={},_0x2fdfd3['init']=_0x25e3d1,_0x2fdfd3[_0x3a2a13('0xfd8')]=_0x3af556,_0x2fdfd3['resetViewer']=_0x2b7794;function _0x25e3d1(_0xdaaacc){const _0x3386e2=_0x3a2a13;_0x2fdfd3[_0x3386e2('0x2588')]=_0xdaaacc,_0x53f859[_0x3386e2('0x3d2')](_0x3386e2('0x1656'),function(_0x58646c,_0x29a909){const _0x1182a1=_0x3386e2;if(_0x29a909['currentPage']&&_0x2fdfd3['project'][_0x1182a1('0x1ff2')]&&_0x2fdfd3[_0x1182a1('0x2588')][_0x1182a1('0x1ff2')][_0x1182a1('0x4a8')])for(let _0x297883=0x0,_0x121aa5=_0x2fdfd3[_0x1182a1('0x2588')][_0x1182a1('0x1ff2')][_0x1182a1('0x4a8')][_0x1182a1('0x264b')];_0x297883<_0x121aa5;_0x297883++){if(_0x29a909[_0x1182a1('0x25c5')][_0x1182a1('0xc45')]<_0x297883+0x1&&_0x2fdfd3['project'][_0x1182a1('0x1ff2')]['pages'][_0x297883][_0x1182a1('0x17d1')])for(let _0x4d8ccd=0x0,_0x4721ce=_0x2fdfd3[_0x1182a1('0x2588')][_0x1182a1('0x1ff2')][_0x1182a1('0x4a8')][_0x297883][_0x1182a1('0x17d1')][_0x1182a1('0x264b')];_0x4d8ccd<_0x4721ce;_0x4d8ccd++){_0x2fdfd3[_0x1182a1('0x2588')][_0x1182a1('0x1ff2')]['pages'][_0x297883]['elements'][_0x4d8ccd]['type']===_0x1182a1('0x9b')&&_0x2fdfd3['project'][_0x1182a1('0x1ff2')][_0x1182a1('0x4a8')][_0x297883][_0x1182a1('0x17d1')][_0x4d8ccd][_0x1182a1('0x9b')]&&delete _0x2fdfd3[_0x1182a1('0x6de')][_0x2fdfd3[_0x1182a1('0x2588')][_0x1182a1('0x1ff2')][_0x1182a1('0x4a8')][_0x297883][_0x1182a1('0x17d1')][_0x4d8ccd][_0x1182a1('0x9b')]['id']];}}});}function _0x3af556(_0x64d679){const _0xd0ae04=_0x3a2a13,_0x33096f=_0x5bda9d[_0xd0ae04('0x24d8')](),_0x55181b=_0x98e18f[_0xd0ae04('0x1d26')]()['title'](_0xd0ae04('0x1714'))[_0xd0ae04('0x2077')]('')[_0xd0ae04('0x8e8')](_0xd0ae04('0xa'))['targetEvent'](_0x64d679)['ok'](_0xd0ae04('0x430'))[_0xd0ae04('0x3f')](_0xd0ae04('0x2d3'));return _0x98e18f[_0xd0ae04('0x1f80')](_0x55181b)['then'](function(){const _0xcb3012=_0xd0ae04;_0x33096f[_0xcb3012('0x18af')](!![]);},function(){_0x33096f['reject']();}),_0x33096f[_0xd0ae04('0x1f48')];}function _0x2b7794(){const _0x94520a=_0x3a2a13;_0x2fdfd3[_0x94520a('0x1c5d')][_0x94520a('0x1aa')]&&_0x2fdfd3[_0x94520a('0x1c5d')]['reset']();}}const _0x47238d=_0x17e605,_0x4a84a0=_0x2734b2['p']+_0x36e6f4('0x1856');_0xe1acd2[_0x36e6f4('0x1294')]=['$cookies',_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef')];function _0xe1acd2(_0x4b6946,_0x352de7,_0x15f0cb,_0x56a2b6,_0x42dd68,_0x46709e,_0x212e14,_0x22d2de,_0x1e4963,_0x2aec6f,_0x1798b8){const _0x491fb5=_0x36e6f4,_0x3d3a94=this;_0x3d3a94[_0x491fb5('0x98')]=_0x1798b8[_0x491fb5('0x26cd')](),_0x3d3a94[_0x491fb5('0x2588')]={},_0x3d3a94[_0x491fb5('0x994')]={'count':0x0,'rows':[]},_0x3d3a94[_0x491fb5('0x9f6')]=[],_0x3d3a94['crudPermissions'],_0x3d3a94['query']={'fields':_0x491fb5('0x1e08'),'sort':_0x491fb5('0x1083'),'limit':0xa,'page':0x1},_0x3d3a94[_0x491fb5('0x24d5')]=_0x4e5ec8,_0x3d3a94[_0x491fb5('0x8a2')]=_0x2a31c0,_0x3d3a94[_0x491fb5('0x103b')]=_0x50103f,_0x3d3a94['getProjectSessions']=_0x8690f6,_0x3d3a94['createOrEditProjectSession']=_0x3a55e6,_0x3d3a94['showQuestionsProjectSession']=_0x5eddab,_0x3d3a94[_0x491fb5('0x2773')]=_0x22b8d3,_0x3d3a94[_0x491fb5('0xb7')]=_0x558d45,_0x3d3a94['deleteSelectedProjectSessions']=_0x207034;function _0x4e5ec8(_0x40dfe3,_0x9cf786){const _0x7e185e=_0x491fb5;_0x3d3a94[_0x7e185e('0x2588')]=_0x40dfe3,_0x3d3a94[_0x7e185e('0x243c')]=typeof _0x9cf786!=='undefined'?_0x9cf786:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3d3a94[_0x7e185e('0x2218')]['id']=_0x3d3a94[_0x7e185e('0x2588')]['id'],_0x8690f6();}function _0x2a31c0(_0xfdaff5,_0x3aabb9){const _0x560514=_0x491fb5,_0x307e3c=_0x212e14[_0x560514('0x1d26')]()['title'](_0x560514('0x248e'))[_0x560514('0xf3c')](_0x560514('0x12b5')+(_0xfdaff5['name']||_0xfdaff5['id']&&_0x2cfb05()[_0x560514('0x114b')](_0x560514('0x85e'))+_0xfdaff5['id']||'session')+_0x560514('0xace')+_0x560514('0x3f3'))['ariaLabel'](_0x560514('0x8fb'))[_0x560514('0x203b')](_0x3aabb9)['ok']('OK')['cancel'](_0x560514('0x2d3'));_0x212e14[_0x560514('0x1f80')](_0x307e3c)[_0x560514('0x1166')](function(){_0x558d45(_0xfdaff5);},function(){const _0x497147=_0x560514;console[_0x497147('0x455')](_0x497147('0x2d3'));});}function _0x50103f(_0x481ee2){const _0x4e50f7=_0x491fb5;_0x3d3a94[_0x4e50f7('0x994')]=_0x481ee2||{'count':0x0,'rows':[]};}function _0x8690f6(){const _0x5a2f5b=_0x491fb5;_0x3d3a94[_0x5a2f5b('0x2218')][_0x5a2f5b('0x1098')]=(_0x3d3a94[_0x5a2f5b('0x2218')][_0x5a2f5b('0x1a43')]-0x1)*_0x3d3a94[_0x5a2f5b('0x2218')][_0x5a2f5b('0x163f')],_0x3d3a94['promise']=_0x2aec6f['jscriptyProject']['getSessions'](_0x3d3a94[_0x5a2f5b('0x2218')],_0x50103f)[_0x5a2f5b('0xa44')];}function _0x3a55e6(_0x5f06b7,_0x5bedc0){const _0x32bef9=_0x491fb5;_0x212e14[_0x32bef9('0x1f80')]({'controller':_0x32bef9('0xe33'),'controllerAs':'vm','templateUrl':_0x4a84a0,'parent':angular[_0x32bef9('0x1194')](_0x22d2de[_0x32bef9('0x8d2')]),'targetEvent':_0x5f06b7,'clickOutsideToClose':!![],'locals':{'project':_0x3d3a94[_0x32bef9('0x2588')],'session':_0x5bedc0,'sessions':_0x3d3a94[_0x32bef9('0x994')][_0x32bef9('0x269a')],'license':null,'setting':null,'crudPermissions':_0x3d3a94[_0x32bef9('0x243c')]}});}function _0x5eddab(_0x23932e,_0x5d66a9){const _0x46e839=_0x491fb5;_0x212e14[_0x46e839('0x1f80')]({'controller':_0x46e839('0xdfe'),'controllerAs':'vm','templateUrl':_0x4a84a0,'parent':angular[_0x46e839('0x1194')](_0x22d2de[_0x46e839('0x8d2')]),'targetEvent':_0x23932e,'clickOutsideToClose':!![],'resolve':{'questions':[_0x46e839('0x1fbc'),function(_0x33c139){const _0x519731=_0x46e839;return _0x33c139[_0x519731('0x18af')](_0x519731('0x864'),{'fields':_0x519731('0x2690'),'sort':'id','id':_0x5d66a9['id']});}]},'locals':{'project':_0x3d3a94[_0x46e839('0x2588')],'session':_0x5d66a9}});}function _0x558d45(_0x438a83){const _0x43b791=_0x491fb5;_0x2aec6f[_0x43b791('0x3ed')][_0x43b791('0x906')]({'id':_0x438a83['id']})['$promise']['then'](function(){const _0x522d64=_0x43b791;_0x2cfb05()[_0x522d64('0x127f')](_0x3d3a94[_0x522d64('0x994')]['rows'],{'id':_0x438a83['id']}),_0x3d3a94[_0x522d64('0x994')]['count']-=0x1,!_0x3d3a94['projectSessions'][_0x522d64('0x269a')]['length']&&_0x8690f6(),_0x1e4963[_0x522d64('0x103b')]({'title':_0x522d64('0x2674'),'msg':_0x438a83[_0x522d64('0x4f0')]?_0x438a83[_0x522d64('0x4f0')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x500844){const _0x3c7852=_0x43b791;if(_0x500844[_0x3c7852('0x25f4')]&&_0x500844[_0x3c7852('0x25f4')][_0x3c7852('0x61a')]&&_0x500844['data'][_0x3c7852('0x61a')]['length']){_0x3d3a94[_0x3c7852('0x61a')]=_0x500844[_0x3c7852('0x25f4')][_0x3c7852('0x61a')]||[{'message':_0x500844[_0x3c7852('0x1586')](),'type':_0x3c7852('0x2352')}];for(let _0x2d110e=0x0;_0x2d110e<_0x500844[_0x3c7852('0x25f4')]['errors'][_0x3c7852('0x264b')];_0x2d110e++){_0x1e4963[_0x3c7852('0xfc9')]({'title':_0x500844['data'][_0x3c7852('0x61a')][_0x2d110e][_0x3c7852('0x1345')],'msg':_0x500844[_0x3c7852('0x25f4')]['errors'][_0x2d110e][_0x3c7852('0x1e70')]});}}else _0x1e4963[_0x3c7852('0xfc9')]({'title':_0x500844[_0x3c7852('0x52d')]?_0x3c7852('0x1e21')+_0x500844[_0x3c7852('0x52d')]+_0x3c7852('0x11e1')+_0x500844[_0x3c7852('0xe1b')]:'SYSTEM:GETjscriptyProject','msg':_0x500844[_0x3c7852('0x25f4')]?JSON['stringify'](_0x500844[_0x3c7852('0x25f4')][_0x3c7852('0x1e70')]):_0x500844[_0x3c7852('0x1e70')]||_0x500844[_0x3c7852('0x1586')]()});});}function _0x22b8d3(){const _0x51f279=_0x491fb5,_0x5c7032=angular[_0x51f279('0x225f')](_0x3d3a94['selectedProjectSessions']);return _0x3d3a94[_0x51f279('0x9f6')]=[],_0x5c7032;}function _0x207034(_0x5dc4af){const _0x309bb1=_0x491fb5,_0x4cbb3a=_0x212e14[_0x309bb1('0x1d26')]()[_0x309bb1('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20sessions?')[_0x309bb1('0xf3c')](_0x309bb1('0x12b5')+_0x3d3a94[_0x309bb1('0x9f6')]['length']+_0x309bb1('0x196d')+_0x309bb1('0x3f3'))['ariaLabel'](_0x309bb1('0x1793'))[_0x309bb1('0x203b')](_0x5dc4af)['ok']('OK')[_0x309bb1('0x3f')](_0x309bb1('0x2d3'));_0x212e14[_0x309bb1('0x1f80')](_0x4cbb3a)[_0x309bb1('0x1166')](function(){const _0x214383=_0x309bb1;_0x3d3a94[_0x214383('0x9f6')][_0x214383('0x2782')](function(_0x18750c){_0x558d45(_0x18750c);}),_0x3d3a94[_0x214383('0x9f6')]=[];});}let _0x48cbf7=!![],_0x1f6330=0x1;_0x352de7['$watch'](_0x491fb5('0x28b4'),function(_0x1d0073,_0x5756f9){const _0x4ce7d7=_0x491fb5;_0x48cbf7?_0x46709e(function(){_0x48cbf7=![];}):(!_0x5756f9&&(_0x1f6330=_0x3d3a94[_0x4ce7d7('0x2218')][_0x4ce7d7('0x1a43')]),_0x1d0073!==_0x5756f9&&(_0x3d3a94[_0x4ce7d7('0x2218')][_0x4ce7d7('0x1a43')]=0x1),!_0x1d0073&&(_0x3d3a94[_0x4ce7d7('0x2218')][_0x4ce7d7('0x1a43')]=_0x1f6330),_0x8690f6());});}const _0x4a10a9=_0xe1acd2;_0x3c6bb0[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state','$location','$mdDialog',_0x36e6f4('0x1d2e'),'session',_0x36e6f4('0x4ac'),_0x36e6f4('0x2588')];function _0x3c6bb0(_0x55a68f,_0x4b7b77,_0x3f5e62,_0x475f6d,_0x7a4863,_0x4606fe,_0x3e91f5,_0x28fd85){const _0x234be=_0x36e6f4,_0x374b47=this;_0x374b47[_0x234be('0xcdc')]=_0x234be('0x7ec'),_0x374b47[_0x234be('0x25d7')]=_0x4606fe,_0x374b47[_0x234be('0x4ac')]=_0x3e91f5,_0x374b47['project']=_0x28fd85;function _0x72fb17(_0x2c9e95){const _0xf44c63=_0x234be;_0x475f6d[_0xf44c63('0x1197')](_0x2c9e95);}_0x374b47[_0x234be('0x24a0')]=_0x72fb17;}const _0x4fd5c4=_0x3c6bb0,_0x33566c=_0x2734b2['p']+_0x36e6f4('0x1543');_0xac61f3['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog',_0x36e6f4('0x1c90'),'$translate',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x2588'),_0x36e6f4('0x17aa')];function _0xac61f3(_0x5bbe25,_0x38debd,_0x1c6b64,_0x4abcbc,_0x2d29ce,_0x5b5a50,_0x30c0a3,_0x1aba9e,_0x226d26,_0x13b72a,_0x150562,_0x4e2ce9){const _0x2f831b=_0x36e6f4,_0x596b3b=this;_0x596b3b[_0x2f831b('0x98')]=_0x13b72a[_0x2f831b('0x26cd')](),_0x596b3b[_0x2f831b('0x5c9')]=_0x5b5a50,_0x596b3b[_0x2f831b('0xf8a')]=_0x30c0a3,_0x596b3b['passwordPattern']=_0x596b3b[_0x2f831b('0xf8a')][_0x2f831b('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x596b3b[_0x2f831b('0x246b')]=_0x38debd[_0x2f831b('0x6f1')]()+_0x2f831b('0xc51')+_0x38debd[_0x2f831b('0x1690')](),_0x596b3b[_0x2f831b('0x2588')]=_0x150562||_0x5bbe25[_0x2f831b('0x23f')][_0x2f831b('0x2588')]||{},_0x596b3b['userProfileSection']=_0x4e2ce9&&_0x4e2ce9[_0x2f831b('0x240f')]==0x1?_0x4e2ce9['rows'][0x0]:null,_0x596b3b['crudPermissions']=_0x13b72a[_0x2f831b('0xd87')](_0x596b3b['userProfileSection']?_0x596b3b[_0x2f831b('0x17aa')][_0x2f831b('0x243c')]:null),_0x596b3b[_0x2f831b('0x128b')]={},_0x596b3b[_0x2f831b('0x2669')]=_0x5bbe25[_0x2f831b('0x23f')]['tab']||0x0,_0x596b3b[_0x2f831b('0x249d')]=_0x5bf238,_0x596b3b[_0x2f831b('0x31d')]=_0x226d26[_0x2f831b('0x1fa1')],_0x596b3b['gotoProjects']=_0x503c6b,_0x596b3b['saveProject']=_0x44ac53;function _0x5bf238(_0x5525f7,_0x60b4c2){const _0x2c2c5d=_0x2f831b;_0x1c6b64[_0x2c2c5d('0x1f80')]({'controller':'ProjectcloneController','controllerAs':'vm','templateUrl':_0x33566c,'parent':angular[_0x2c2c5d('0x1194')](_0x4abcbc[_0x2c2c5d('0x8d2')]),'targetEvent':_0x60b4c2,'clickOutsideToClose':!![],'locals':{'project':_0x5525f7,'projects':_0x596b3b[_0x2c2c5d('0x149f')]?_0x596b3b[_0x2c2c5d('0x149f')][_0x2c2c5d('0x269a')]:[],'crudPermissions':_0x596b3b[_0x2c2c5d('0x243c')]}});}function _0x503c6b(){const _0x545466=_0x2f831b;_0x5bbe25['go'](_0x545466('0x37a'),{},{'reload':_0x545466('0x37a')});}function _0x44ac53(){const _0x24b64a=_0x2f831b;_0x1aba9e[_0x24b64a('0x129b')]['update']({'id':_0x596b3b[_0x24b64a('0x2588')]['id']},_0x596b3b[_0x24b64a('0x2588')])['$promise'][_0x24b64a('0x1166')](function(){const _0x18d344=_0x24b64a;_0x226d26[_0x18d344('0x103b')]({'title':'Project\x20updated!','msg':_0x596b3b[_0x18d344('0x2588')]['name']?_0x596b3b[_0x18d344('0x2588')]['name']+'\x20has\x20been\x20updated!':''});})[_0x24b64a('0x1a80')](function(_0x3c128c){const _0x12e41f=_0x24b64a;_0x226d26['error']({'title':_0x3c128c[_0x12e41f('0x52d')]?'API:'+_0x3c128c[_0x12e41f('0x52d')]+_0x12e41f('0x11e1')+_0x3c128c['statusText']:_0x12e41f('0x2352'),'msg':_0x3c128c[_0x12e41f('0x25f4')]?JSON[_0x12e41f('0xbac')](_0x3c128c[_0x12e41f('0x25f4')]):_0x3c128c['toString']()});});}}const _0x561c6a=_0xac61f3,_0x477c4b=_0x2734b2['p']+_0x36e6f4('0x2583');_0x53eebf[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),'$mdDialog',_0x36e6f4('0x1c90'),'$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x149f'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),'api',_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x53eebf(_0x34fbd8,_0x236b7c,_0xa9f8e3,_0x424146,_0x53efc3,_0x250c4d,_0x24de2c,_0xf252c2,_0x2e135f,_0x178774,_0x5c7234,_0x50c84a,_0x1a6192,_0xccfc41,_0x5a1aa8,_0x511aba,_0x46ad06){const _0x42d3e6=_0x36e6f4,_0x56e126=this;_0x56e126[_0x42d3e6('0x5c9')]=_0x511aba,_0x56e126[_0x42d3e6('0xf8a')]=_0x46ad06,_0x56e126[_0x42d3e6('0x98')]=_0x5a1aa8[_0x42d3e6('0x26cd')](),_0x56e126['projects']=_0x2e135f||{'count':0x0,'rows':[]},_0x56e126[_0x42d3e6('0x7f')]=_0x178774,_0x56e126[_0x42d3e6('0x17aa')]=_0x5c7234&&_0x5c7234[_0x42d3e6('0x240f')]==0x1?_0x5c7234['rows'][0x0]:null,_0x56e126[_0x42d3e6('0x243c')]=_0x5a1aa8[_0x42d3e6('0xd87')](_0x56e126[_0x42d3e6('0x17aa')]?_0x56e126[_0x42d3e6('0x17aa')][_0x42d3e6('0x243c')]:null),_0x56e126['table']=_0x42d3e6('0x149f'),_0x56e126[_0x42d3e6('0xef5')]='',_0x56e126['listOrderAsc']=null,_0x56e126[_0x42d3e6('0x11ce')]=[],_0x56e126['query']={'fields':_0x42d3e6('0x1aad'),'sort':_0x42d3e6('0x14dc'),'limit':0xa,'page':0x1},_0x56e126[_0x42d3e6('0x1ff6')]=_0x24847e,_0x56e126[_0x42d3e6('0x249d')]=_0xcdc503,_0x56e126[_0x42d3e6('0xb7f')]=_0x503cfb,_0x56e126[_0x42d3e6('0x8d8')]=_0x3fa93e,_0x56e126['success']=_0x37cb1d,_0x56e126['getProjects']=_0x3b7a33,_0x56e126['createOrEditProject']=_0x3ed689,_0x56e126[_0x42d3e6('0x14b')]=_0xce6c26,_0x56e126[_0x42d3e6('0x66b')]=_0x5bb03a,_0x56e126[_0x42d3e6('0x668')]=_0x1eaf80,_0x56e126[_0x42d3e6('0xfc5')]=_0x5578ed,_0x56e126[_0x42d3e6('0x325')]=_0x2a7486;function _0x24847e(_0xf711d4){const _0xcd6464=_0x42d3e6;_0xa9f8e3['go'](_0xcd6464('0x20e6'),{'id':_0xf711d4['id'],'project':_0xf711d4,'crudPermissions':_0x56e126[_0xcd6464('0x243c')]});}function _0xcdc503(_0xa7311a,_0x29fda1){const _0x4a6170=_0x42d3e6;_0x53efc3['show']({'controller':_0x4a6170('0x1022'),'controllerAs':'vm','templateUrl':_0x33566c,'parent':angular[_0x4a6170('0x1194')](_0x250c4d[_0x4a6170('0x8d2')]),'targetEvent':_0x29fda1,'clickOutsideToClose':!![],'locals':{'project':_0xa7311a,'projects':_0x56e126[_0x4a6170('0x149f')]?_0x56e126[_0x4a6170('0x149f')][_0x4a6170('0x269a')]:[],'crudPermissions':_0x56e126[_0x4a6170('0x243c')]}});}function _0x503cfb(_0x40e626){const _0x7763dc=_0x42d3e6;_0xa9f8e3['go'](_0x7763dc('0x20e6'),{'id':_0x40e626['id'],'tab':0x3});}function _0x3fa93e(_0x1b59d4,_0x23b44d){const _0x1a6b71=_0x42d3e6,_0x5659f1=_0x53efc3['confirm']()[_0x1a6b71('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()[_0x1a6b71('0xb35')]('project')+'?')[_0x1a6b71('0xf3c')](_0x1a6b71('0x12b5')+(_0x1b59d4[_0x1a6b71('0x4f0')]||'project')+_0x1a6b71('0xace')+_0x1a6b71('0x3f3'))[_0x1a6b71('0x8e8')](_0x1a6b71('0x3f0'))['targetEvent'](_0x23b44d)['ok']('OK')[_0x1a6b71('0x3f')](_0x1a6b71('0x2d3'));_0x53efc3[_0x1a6b71('0x1f80')](_0x5659f1)['then'](function(){_0xce6c26(_0x1b59d4);},function(){const _0x32cc50=_0x1a6b71;console[_0x32cc50('0x455')](_0x32cc50('0x2d3'));});}let _0x57c96b=!![],_0x4eb330=0x1;_0x34fbd8['$watch'](_0x42d3e6('0x12d8'),function(_0x5dfba7,_0x241820){const _0x132ebf=_0x42d3e6;_0x57c96b?_0x24de2c(function(){_0x57c96b=![];}):(!_0x241820&&(_0x4eb330=_0x56e126['query'][_0x132ebf('0x1a43')]),_0x5dfba7!==_0x241820&&(_0x56e126['query']['page']=0x1),!_0x5dfba7&&(_0x56e126[_0x132ebf('0x2218')][_0x132ebf('0x1a43')]=_0x4eb330),_0x56e126[_0x132ebf('0x948')]());});function _0x37cb1d(_0x2329fc){_0x56e126['projects']=_0x2329fc||{'count':0x0,'rows':[]};}function _0x3b7a33(){const _0x3fbd6b=_0x42d3e6;_0x56e126[_0x3fbd6b('0x2218')][_0x3fbd6b('0x1098')]=(_0x56e126[_0x3fbd6b('0x2218')]['page']-0x1)*_0x56e126[_0x3fbd6b('0x2218')][_0x3fbd6b('0x163f')],_0x5a1aa8[_0x3fbd6b('0x1ac6')]('admin')?_0x56e126[_0x3fbd6b('0x1f48')]=_0x50c84a[_0x3fbd6b('0x129b')][_0x3fbd6b('0xd83')](_0x56e126[_0x3fbd6b('0x2218')],_0x37cb1d)[_0x3fbd6b('0xa44')]:(_0x56e126[_0x3fbd6b('0x2218')]['id']=_0x56e126[_0x3fbd6b('0x7f')]['id'],_0x56e126[_0x3fbd6b('0x2218')]['section']='Projects',_0x56e126[_0x3fbd6b('0x1f48')]=_0x50c84a['userProfile']['getResources'](_0x56e126[_0x3fbd6b('0x2218')],_0x37cb1d)[_0x3fbd6b('0xa44')]);}function _0x3ed689(_0x4fbc7c,_0x12c725){const _0x3a71c2=_0x42d3e6;_0x53efc3[_0x3a71c2('0x1f80')]({'controller':'CreateOrEditProjectDialogController','controllerAs':'vm','templateUrl':_0x477c4b,'parent':angular[_0x3a71c2('0x1194')](_0x250c4d[_0x3a71c2('0x8d2')]),'targetEvent':_0x4fbc7c,'clickOutsideToClose':!![],'locals':{'project':_0x12c725,'projects':_0x56e126[_0x3a71c2('0x149f')][_0x3a71c2('0x269a')],'license':_0x56e126[_0x3a71c2('0x5c9')],'setting':_0x56e126[_0x3a71c2('0xf8a')],'crudPermissions':_0x56e126[_0x3a71c2('0x243c')]}});}function _0xce6c26(_0x40c5bc){const _0x640fa6=_0x42d3e6;_0x50c84a[_0x640fa6('0x129b')][_0x640fa6('0x906')]({'id':_0x40c5bc['id']})['$promise'][_0x640fa6('0x1166')](function(){const _0x2c123a=_0x640fa6;_0x2cfb05()[_0x2c123a('0x127f')](_0x56e126[_0x2c123a('0x149f')][_0x2c123a('0x269a')],{'id':_0x40c5bc['id']}),_0x56e126[_0x2c123a('0x149f')]['count']-=0x1,!_0x56e126['projects'][_0x2c123a('0x269a')][_0x2c123a('0x264b')]&&_0x56e126[_0x2c123a('0x948')](),_0xccfc41[_0x2c123a('0x103b')]({'title':_0x2cfb05()[_0x2c123a('0xb35')](_0x2c123a('0x1593'))+_0x2c123a('0x2b6'),'msg':_0x40c5bc[_0x2c123a('0x4f0')]?_0x40c5bc[_0x2c123a('0x4f0')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x5dc5fe){const _0xb2cfb9=_0x640fa6;if(_0x5dc5fe[_0xb2cfb9('0x25f4')]&&_0x5dc5fe['data'][_0xb2cfb9('0x61a')]&&_0x5dc5fe[_0xb2cfb9('0x25f4')][_0xb2cfb9('0x61a')][_0xb2cfb9('0x264b')]){_0x56e126['errors']=_0x5dc5fe['data'][_0xb2cfb9('0x61a')]||[{'message':_0x5dc5fe['toString'](),'type':_0xb2cfb9('0x1a61')}];for(let _0x50dc59=0x0;_0x50dc59<_0x5dc5fe[_0xb2cfb9('0x25f4')][_0xb2cfb9('0x61a')][_0xb2cfb9('0x264b')];_0x50dc59++){_0xccfc41['error']({'title':_0x5dc5fe[_0xb2cfb9('0x25f4')][_0xb2cfb9('0x61a')][_0x50dc59][_0xb2cfb9('0x1345')],'msg':_0x5dc5fe[_0xb2cfb9('0x25f4')][_0xb2cfb9('0x61a')][_0x50dc59][_0xb2cfb9('0x1e70')]});}}else _0xccfc41[_0xb2cfb9('0xfc9')]({'title':_0x5dc5fe['status']?_0xb2cfb9('0x1e21')+_0x5dc5fe['status']+_0xb2cfb9('0x11e1')+_0x5dc5fe[_0xb2cfb9('0xe1b')]:_0xb2cfb9('0x1a61'),'msg':_0x5dc5fe['data']?JSON[_0xb2cfb9('0xbac')](_0x5dc5fe[_0xb2cfb9('0x25f4')][_0xb2cfb9('0x1e70')]):_0x5dc5fe[_0xb2cfb9('0x1e70')]||_0x5dc5fe['toString']()});});}function _0x5bb03a(){const _0x34ce13=_0x42d3e6,_0x365190=angular[_0x34ce13('0x225f')](_0x56e126[_0x34ce13('0x11ce')]);return _0x56e126[_0x34ce13('0x11ce')]=[],_0x365190;}function _0x1eaf80(_0x2b30a6){const _0x29c6fe=_0x42d3e6,_0x179cb0=_0x53efc3[_0x29c6fe('0x1d26')]()[_0x29c6fe('0xcdc')](_0x29c6fe('0x1547'))['htmlContent'](''+_0x56e126[_0x29c6fe('0x11ce')]['length']+_0x29c6fe('0x196d')+'\x20will\x20be\x20deleted.')[_0x29c6fe('0x8e8')](_0x29c6fe('0x1369'))[_0x29c6fe('0x203b')](_0x2b30a6)['ok']('OK')['cancel'](_0x29c6fe('0x2d3'));_0x53efc3['show'](_0x179cb0)[_0x29c6fe('0x1166')](function(){const _0x1b51db=_0x29c6fe;_0x56e126[_0x1b51db('0x11ce')][_0x1b51db('0x2782')](function(_0x1bf0de){_0xce6c26(_0x1bf0de);}),_0x56e126[_0x1b51db('0x11ce')]=[];});}function _0x5578ed(){const _0x26bade=_0x42d3e6;_0x56e126[_0x26bade('0x11ce')]=[];}function _0x2a7486(){const _0x560cd6=_0x42d3e6;_0x56e126[_0x560cd6('0x11ce')]=_0x56e126['projects'][_0x560cd6('0x269a')];}}const _0x10392c=_0x53eebf;_0x5e274b[_0x36e6f4('0x1294')]=['$stateProvider',_0x36e6f4('0x1562')];function _0x5e274b(_0x414c87,_0x31b357){const _0x153b94=_0x36e6f4;_0x414c87['state'](_0x153b94('0xce0'),{'abstract':!![],'url':'/jscripty'})[_0x153b94('0x63f')](_0x153b94('0x37a'),{'url':_0x153b94('0x12da'),'views':{'content@app':{'templateUrl':_0x4d7bf1,'controller':_0x153b94('0x25f9')}},'resolve':{'projects':[_0x153b94('0x1fbc'),_0x153b94('0x21ef'),function(_0x1da76e,_0x1f8d15){const _0x566f1a=_0x153b94;return _0x1f8d15['hasRole'](_0x566f1a('0xa7c'))?_0x1da76e[_0x566f1a('0x18af')](_0x566f1a('0x154'),{'fields':_0x566f1a('0x1aad'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x1da76e[_0x566f1a('0x18af')](_0x566f1a('0x17c4'),{'id':_0x1f8d15[_0x566f1a('0x26cd')]()['userProfileId'],'section':_0x566f1a('0xda5'),'fields':_0x566f1a('0x1aad'),'sort':_0x566f1a('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x153b94('0x21ef'),function(_0x188f37,_0x467ef3){const _0x3c9db6=_0x153b94;return _0x467ef3[_0x3c9db6('0x1ac6')](_0x3c9db6('0xa7c'))?null:_0x188f37[_0x3c9db6('0x18af')](_0x3c9db6('0x697'),{'fields':_0x3c9db6('0x686'),'id':_0x467ef3[_0x3c9db6('0x26cd')]()[_0x3c9db6('0xb86')]});}],'userProfileSection':[_0x153b94('0x1fbc'),_0x153b94('0x21ef'),function(_0x39202f,_0x452c55){const _0x9128fe=_0x153b94;return _0x452c55[_0x9128fe('0x1ac6')](_0x9128fe('0xa7c'))?null:_0x39202f[_0x9128fe('0x18af')](_0x9128fe('0xaf'),{'fields':_0x9128fe('0xe26'),'userProfileId':_0x452c55[_0x9128fe('0x26cd')]()[_0x9128fe('0xb86')],'sectionId':0x6a5});}]},'authenticate':!![],'permissionId':0x6a5,'bodyClass':_0x153b94('0x179f')})['state'](_0x153b94('0x20e6'),{'url':_0x153b94('0x2233'),'params':{'project':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x456e43,'controller':'JscriptyProjectController\x20as\x20vm'}},'resolve':{'project':['apiResolver',_0x153b94('0xf75'),function(_0x35c874,_0x39c023){const _0x40da5f=_0x153b94;return _0x35c874[_0x40da5f('0x18af')](_0x40da5f('0x154'),{'fields':_0x40da5f('0x1aad'),'id':_0x39c023['id']});}],'userProfileSection':['apiResolver','Auth',function(_0xf147fc,_0x5efbd1){const _0xed85ed=_0x153b94;return _0xf147fc['resolve'](_0xed85ed('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5efbd1[_0xed85ed('0x26cd')]()[_0xed85ed('0xb86')],'sectionId':0x6a5});}]},'authenticate':!![],'permissionId':0x6a5,'bodyClass':_0x153b94('0x179f')}),_0x31b357[_0x153b94('0x95e')](_0x153b94('0x1812'));}angular[_0x36e6f4('0x896')](_0x36e6f4('0xce0'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),'ngEmbed',_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),'chart.js',_0x36e6f4('0x411')])[_0x36e6f4('0xe11')](_0x5e274b)['controller']('CreateOrEditProjectDialogController',_0x58bf3c)[_0x36e6f4('0x75e')](_0x36e6f4('0x1a3'),_0x10a4e8)[_0x36e6f4('0x75e')](_0x36e6f4('0xc8c'),_0x3d8ed2)[_0x36e6f4('0x75e')]('ProjectcloneController',_0x1b32dd)[_0x36e6f4('0x75e')]('ProjectViewerController',_0x47238d)[_0x36e6f4('0x75e')](_0x36e6f4('0x1109'),_0x4a10a9)['controller']('ShowQuestionsSessionDialogController',_0x4fd5c4)[_0x36e6f4('0x75e')](_0x36e6f4('0x5a7'),_0x561c6a)[_0x36e6f4('0x75e')]('JscriptyProjectsController',_0x10392c);const _0x268121=_0x2734b2['p']+_0x36e6f4('0xe8c'),_0x27a771=_0x2734b2['p']+_0x36e6f4('0x15e1');_0x56b959['$inject']=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q','$translate',_0x36e6f4('0x1d2e'),_0x36e6f4('0x812'),_0x36e6f4('0xc0e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x56b959(_0x442217,_0x2772a3,_0x5ac2fb,_0x490ca2,_0x8fc454,_0x22a8bc,_0x4bd57a,_0x3919d7,_0x203002,_0x58096d,_0x40a917,_0x1dcb12,_0x120aa4,_0x32804d){const _0x4dcaba=_0x36e6f4,_0x2ca5be=this;_0x2ca5be['currentUser']=_0x40a917[_0x4dcaba('0x26cd')](),_0x2ca5be[_0x4dcaba('0x61a')]=[],_0x2ca5be[_0x4dcaba('0xf8a')]=_0x120aa4,_0x2ca5be['license']=_0x1dcb12,_0x2ca5be['crudPermissions']=_0x32804d,_0x2ca5be[_0x4dcaba('0x128b')]={},_0x2ca5be['passwordPattern']=_0x2ca5be['setting']&&_0x2ca5be[_0x4dcaba('0xf8a')][_0x4dcaba('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2ca5be[_0x4dcaba('0xcdc')]=_0x4dcaba('0x1914'),_0x2ca5be[_0x4dcaba('0xc0e')]=angular['copy'](_0x203002),_0x2ca5be[_0x4dcaba('0x812')]=_0x3919d7,_0x2ca5be[_0x4dcaba('0x48a')]=![];!_0x2ca5be[_0x4dcaba('0xc0e')]&&(_0x2ca5be['plugin']={},_0x2ca5be['title']=_0x4dcaba('0x2343'),_0x2ca5be['newPlugin']=!![]);_0x2ca5be[_0x4dcaba('0x2ca')]=_0x3a7377,_0x2ca5be[_0x4dcaba('0x682')]=_0x208a71,_0x2ca5be[_0x4dcaba('0x699')]=_0x231bc6,_0x2ca5be[_0x4dcaba('0x1a9c')]=_0x4292c4,_0x2ca5be[_0x4dcaba('0x24a0')]=_0x11ba6a;function _0x3a7377(){const _0x283048=_0x4dcaba;_0x2ca5be[_0x283048('0x61a')]=[],_0x58096d[_0x283048('0xc0e')][_0x283048('0x9cc')](_0x2ca5be[_0x283048('0xc0e')])[_0x283048('0xa44')]['then'](function(_0x4f0681){const _0x1a5896=_0x283048;_0x2ca5be[_0x1a5896('0x812')][_0x1a5896('0x2450')](_0x4f0681[_0x1a5896('0x2876')]()),_0x4bd57a[_0x1a5896('0x103b')]({'title':_0x1a5896('0x5dc'),'msg':_0x2ca5be[_0x1a5896('0xc0e')][_0x1a5896('0x4f0')]?_0x2ca5be['plugin']['name']+_0x1a5896('0x1eda'):''}),_0x11ba6a(_0x4f0681);})['catch'](function(_0x255a7d){const _0x3a93ac=_0x283048;if(_0x255a7d[_0x3a93ac('0x25f4')]&&_0x255a7d[_0x3a93ac('0x25f4')][_0x3a93ac('0x61a')]&&_0x255a7d[_0x3a93ac('0x25f4')][_0x3a93ac('0x61a')][_0x3a93ac('0x264b')]){_0x2ca5be[_0x3a93ac('0x61a')]=_0x255a7d[_0x3a93ac('0x25f4')][_0x3a93ac('0x61a')]||[{'message':_0x255a7d[_0x3a93ac('0x1586')](),'type':'api.plugin.save'}];for(let _0x59e184=0x0;_0x59e184<_0x255a7d[_0x3a93ac('0x25f4')]['errors'][_0x3a93ac('0x264b')];_0x59e184+=0x1){_0x4bd57a[_0x3a93ac('0xfc9')]({'title':_0x255a7d[_0x3a93ac('0x25f4')]['errors'][_0x59e184][_0x3a93ac('0x1345')],'msg':_0x255a7d[_0x3a93ac('0x25f4')][_0x3a93ac('0x61a')][_0x59e184][_0x3a93ac('0x1e70')]});}}else _0x4bd57a['error']({'title':_0x255a7d[_0x3a93ac('0x52d')]?'API:'+_0x255a7d['status']+'\x20-\x20'+_0x255a7d[_0x3a93ac('0xe1b')]:_0x3a93ac('0xe0c'),'msg':_0x255a7d[_0x3a93ac('0x25f4')]?JSON[_0x3a93ac('0xbac')](_0x255a7d['data']['message']):_0x255a7d['toString']()});});}function _0x208a71(){const _0x2ebd93=_0x4dcaba;_0x2ca5be['errors']=[],_0x58096d[_0x2ebd93('0xc0e')]['update']({'id':_0x2ca5be[_0x2ebd93('0xc0e')]['id']},_0x2ca5be['plugin'])[_0x2ebd93('0xa44')][_0x2ebd93('0x1166')](function(_0x2e4401){const _0x350efb=_0x2ebd93,_0x31502c=_0x2cfb05()[_0x350efb('0xc38')](_0x2ca5be[_0x350efb('0x812')],{'id':_0x2e4401['id']});_0x31502c&&_0x2cfb05()['merge'](_0x31502c,_0x2cfb05()[_0x350efb('0x1a08')](_0x2e4401[_0x350efb('0x2876')](),_0x2cfb05()['keys'](_0x31502c))),_0x4bd57a[_0x350efb('0x103b')]({'title':'Plugin\x20properly\x20saved!','msg':_0x2ca5be['plugin'][_0x350efb('0x4f0')]?_0x2ca5be[_0x350efb('0xc0e')]['name']+_0x350efb('0x7d'):''}),_0x11ba6a(_0x2e4401);})['catch'](function(_0x40c46e){const _0xd2c944=_0x2ebd93;if(_0x40c46e[_0xd2c944('0x25f4')]&&_0x40c46e[_0xd2c944('0x25f4')]['errors']&&_0x40c46e[_0xd2c944('0x25f4')][_0xd2c944('0x61a')][_0xd2c944('0x264b')]){_0x2ca5be[_0xd2c944('0x61a')]=_0x40c46e[_0xd2c944('0x25f4')][_0xd2c944('0x61a')]||[{'message':_0x40c46e[_0xd2c944('0x1586')](),'type':_0xd2c944('0x18ef')}];for(let _0x4b06d3=0x0;_0x4b06d3<_0x40c46e[_0xd2c944('0x25f4')][_0xd2c944('0x61a')]['length'];_0x4b06d3++){_0x4bd57a[_0xd2c944('0xfc9')]({'title':_0x40c46e[_0xd2c944('0x25f4')][_0xd2c944('0x61a')][_0x4b06d3][_0xd2c944('0x1345')],'msg':_0x40c46e['data'][_0xd2c944('0x61a')][_0x4b06d3][_0xd2c944('0x1e70')]});}}else _0x4bd57a[_0xd2c944('0xfc9')]({'title':_0x40c46e[_0xd2c944('0x52d')]?_0xd2c944('0x1e21')+_0x40c46e[_0xd2c944('0x52d')]+'\x20-\x20'+_0x40c46e[_0xd2c944('0xe1b')]:_0xd2c944('0x18ef'),'msg':_0x40c46e[_0xd2c944('0x25f4')]?JSON[_0xd2c944('0xbac')](_0x40c46e['data'][_0xd2c944('0x1e70')]):_0x40c46e[_0xd2c944('0x1586')]()});});}function _0x231bc6(_0x509136){const _0x2fccb6=_0x4dcaba;_0x2ca5be[_0x2fccb6('0x61a')]=[];const _0x3a21ea=_0x490ca2[_0x2fccb6('0x1d26')]()[_0x2fccb6('0xcdc')]('Are\x20you\x20sure?')[_0x2fccb6('0xacc')](_0x2fccb6('0xda4'))[_0x2fccb6('0x8e8')]('Delete\x20Plugin')['ok']('Delete')[_0x2fccb6('0x3f')](_0x2fccb6('0x497'))[_0x2fccb6('0x203b')](_0x509136);_0x490ca2[_0x2fccb6('0x1f80')](_0x3a21ea)[_0x2fccb6('0x1166')](function(){const _0x2543b5=_0x2fccb6;_0x58096d[_0x2543b5('0xc0e')]['delete']({'id':_0x2ca5be['plugin']['id']})[_0x2543b5('0xa44')]['then'](function(){const _0x3e692d=_0x2543b5;_0x2cfb05()[_0x3e692d('0x127f')](_0x2ca5be[_0x3e692d('0x812')],{'id':_0x2ca5be['plugin']['id']}),_0x4bd57a[_0x3e692d('0x103b')]({'title':_0x3e692d('0x18d5'),'msg':(_0x2ca5be[_0x3e692d('0xc0e')][_0x3e692d('0x4f0')]||_0x3e692d('0xc0e'))+'\x20has\x20been\x20deleted!'}),_0x11ba6a(_0x2ca5be[_0x3e692d('0xc0e')]);})[_0x2543b5('0x1a80')](function(_0x2ba9df){const _0x5b2231=_0x2543b5;if(_0x2ba9df[_0x5b2231('0x25f4')]&&_0x2ba9df[_0x5b2231('0x25f4')][_0x5b2231('0x61a')]&&_0x2ba9df[_0x5b2231('0x25f4')][_0x5b2231('0x61a')]['length']){_0x2ca5be[_0x5b2231('0x61a')]=_0x2ba9df['data'][_0x5b2231('0x61a')]||[{'message':_0x2ba9df[_0x5b2231('0x1586')](),'type':_0x5b2231('0xf17')}];for(let _0x2d719e=0x0;_0x2d719e<_0x2ba9df['data'][_0x5b2231('0x61a')]['length'];_0x2d719e++){_0x4bd57a['error']({'title':_0x2ba9df[_0x5b2231('0x25f4')][_0x5b2231('0x61a')][_0x2d719e][_0x5b2231('0x1345')],'msg':_0x2ba9df[_0x5b2231('0x25f4')][_0x5b2231('0x61a')][_0x2d719e]['message']});}}else _0x4bd57a[_0x5b2231('0xfc9')]({'title':_0x2ba9df['status']?_0x5b2231('0x1e21')+_0x2ba9df[_0x5b2231('0x52d')]+_0x5b2231('0x11e1')+_0x2ba9df[_0x5b2231('0xe1b')]:'api.plugin.delete','msg':_0x2ba9df[_0x5b2231('0x25f4')]?JSON[_0x5b2231('0xbac')](_0x2ba9df['data'][_0x5b2231('0x1e70')]):_0x2ba9df[_0x5b2231('0x1e70')]||_0x2ba9df['toString']()});});},function(){});}function _0x4292c4(_0x2d45f7){return _0x2d45f7===null?undefined:new Date(_0x2d45f7);}function _0x11ba6a(_0x1ef595){const _0x307b12=_0x4dcaba;_0x490ca2[_0x307b12('0x1197')](_0x1ef595);}}const _0x5b79ac=_0x56b959;_0x2ab2f4['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0xc0e'),_0x36e6f4('0x17aa')];function _0x2ab2f4(_0x1f3746,_0x160a01,_0x2c0d55,_0x3660e0,_0x1a8986,_0x48a290,_0x43180d,_0x1d8f07,_0x1453e3,_0x4e2b39,_0x44b7be,_0x5feb73){const _0x3d4950=_0x36e6f4,_0x2ef901=this;_0x2ef901[_0x3d4950('0x98')]=_0x4e2b39[_0x3d4950('0x26cd')](),_0x2ef901[_0x3d4950('0x5c9')]=_0x48a290,_0x2ef901[_0x3d4950('0xf8a')]=_0x43180d,_0x2ef901['passwordPattern']=_0x2ef901['setting'][_0x3d4950('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2ef901[_0x3d4950('0x246b')]=_0x160a01[_0x3d4950('0x6f1')]()+_0x3d4950('0xc51')+_0x160a01['host'](),_0x2ef901[_0x3d4950('0xc0e')]=_0x44b7be||_0x1f3746[_0x3d4950('0x23f')][_0x3d4950('0xc0e')]||{},_0x2ef901[_0x3d4950('0x17aa')]=_0x5feb73&&_0x5feb73[_0x3d4950('0x240f')]==0x1?_0x5feb73[_0x3d4950('0x269a')][0x0]:null,_0x2ef901[_0x3d4950('0x243c')]=_0x4e2b39[_0x3d4950('0xd87')](_0x2ef901[_0x3d4950('0x17aa')]?_0x2ef901[_0x3d4950('0x17aa')][_0x3d4950('0x243c')]:null),_0x2ef901['hasModulePermissions']={},_0x2ef901[_0x3d4950('0x2669')]=_0x1f3746[_0x3d4950('0x23f')][_0x3d4950('0xbe3')]||0x0,_0x2ef901[_0x3d4950('0x31d')]=_0x1453e3[_0x3d4950('0x1fa1')],_0x2ef901['gotoPlugins']=_0x459b7d,_0x2ef901['savePlugin']=_0x57e37b;function _0x459b7d(){const _0x22eec5=_0x3d4950;_0x1f3746['go'](_0x22eec5('0x165e'),{},{'reload':_0x22eec5('0x165e')});}function _0x57e37b(){const _0x5de165=_0x3d4950;_0x1d8f07['plugin'][_0x5de165('0x1449')]({'id':_0x2ef901[_0x5de165('0xc0e')]['id']},_0x2ef901[_0x5de165('0xc0e')])[_0x5de165('0xa44')][_0x5de165('0x1166')](function(){const _0x4194fb=_0x5de165;_0x1453e3[_0x4194fb('0x103b')]({'title':_0x4194fb('0x1652'),'msg':_0x2ef901[_0x4194fb('0xc0e')][_0x4194fb('0x4f0')]?_0x2ef901[_0x4194fb('0xc0e')][_0x4194fb('0x4f0')]+_0x4194fb('0xa17'):''});})[_0x5de165('0x1a80')](function(_0x3a763d){const _0x28bb59=_0x5de165;_0x1453e3[_0x28bb59('0xfc9')]({'title':_0x3a763d[_0x28bb59('0x52d')]?'API:'+_0x3a763d['status']+_0x28bb59('0x11e1')+_0x3a763d['statusText']:_0x28bb59('0x37b'),'msg':_0x3a763d['data']?JSON['stringify'](_0x3a763d[_0x28bb59('0x25f4')]):_0x3a763d['toString']()});});}}const _0xccce64=_0x2ab2f4,_0x3b35fd=_0x2734b2['p']+_0x36e6f4('0x731'),_0x32364a=_0x2734b2['p']+_0x36e6f4('0x1b1');_0x31b7a3[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state',_0x36e6f4('0xc46'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x812'),_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),'Auth',_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x31b7a3(_0x7d5838,_0x488ad5,_0x4d857b,_0x4a0585,_0x2c5fde,_0x596709,_0x373b60,_0x3d0cb1,_0x1a4cad,_0x3f1f7f,_0x367f68,_0x24ea6e,_0x205140,_0x3414dc,_0x1fad5b,_0x1c9416,_0x56d4e1){const _0x564dea=_0x36e6f4,_0x330ad3=this;_0x330ad3[_0x564dea('0x5c9')]=_0x1c9416,_0x330ad3[_0x564dea('0xf8a')]=_0x56d4e1,_0x330ad3[_0x564dea('0x98')]=_0x1fad5b[_0x564dea('0x26cd')](),_0x330ad3[_0x564dea('0x812')]=_0x1a4cad||{'count':0x0,'rows':[]},_0x330ad3[_0x564dea('0x7f')]=_0x3f1f7f,_0x330ad3['userProfileSection']=_0x367f68&&_0x367f68[_0x564dea('0x240f')]==0x1?_0x367f68['rows'][0x0]:null,_0x330ad3[_0x564dea('0x243c')]=_0x1fad5b[_0x564dea('0xd87')](_0x330ad3[_0x564dea('0x17aa')]?_0x330ad3[_0x564dea('0x17aa')][_0x564dea('0x243c')]:null),_0x330ad3[_0x564dea('0x916')]=_0x564dea('0x812'),_0x330ad3[_0x564dea('0xef5')]='',_0x330ad3[_0x564dea('0x104c')]=null,_0x330ad3[_0x564dea('0x1c94')]=[],_0x330ad3[_0x564dea('0x2218')]={'fields':'createdAt,updatedAt,id,name,type,active,description,icon,sidebar,path,adminUrl,agentUrl,scriptName,scriptPath,version','sort':_0x564dea('0x4f0'),'limit':0xa,'page':0x1},_0x330ad3[_0x564dea('0x15c8')]=![],_0x330ad3[_0x564dea('0x903')]=_0x2cfb05()['keyBy']([{'option':_0x564dea('0x70f'),'value':_0x564dea('0x312')},{'option':_0x564dea('0x1fec'),'value':'\x27adminOnly\x27'},{'option':_0x564dea('0x14a7'),'value':_0x564dea('0x1d51')},{'option':_0x564dea('0xc35'),'value':_0x564dea('0x130c')}],function(_0x16d7f1){return _0x2cfb05()['replace'](_0x16d7f1['value'],new RegExp('\x27','g'),'');}),_0x330ad3['installplugin']=_0x5e6ecf,_0x330ad3[_0x564dea('0x1ff6')]=_0x21a8a6,_0x330ad3[_0x564dea('0x1627')]=_0x1464af,_0x330ad3[_0x564dea('0x1afb')]=_0x5b9e75,_0x330ad3['downloadfile2']=_0x407550,_0x330ad3[_0x564dea('0x1cd5')]=_0x216969,_0x330ad3['deleteconfirm']=_0x29946b,_0x330ad3[_0x564dea('0x103b')]=_0x1b3f59,_0x330ad3[_0x564dea('0xc07')]=_0x38a737,_0x330ad3[_0x564dea('0x689')]=_0x30f26f,_0x330ad3[_0x564dea('0x699')]=_0x236671,_0x330ad3[_0x564dea('0x974')]=_0x38343e,_0x330ad3[_0x564dea('0x198')]=_0x497abd,_0x330ad3['deselectPlugins']=_0x54e6d8,_0x330ad3[_0x564dea('0x25f5')]=_0x48317c,_0x330ad3[_0x564dea('0x23be')]=_0x26c5c4;function _0x5e6ecf(_0x4f0b10){const _0x1d759e=_0x564dea;if(_0x4f0b10['type']===_0x1d759e('0x12fe'))_0x330ad3[_0x1d759e('0x15c8')]=!![],_0x24ea6e['pm2']['save']({'name':_0x4f0b10[_0x1d759e('0x1996')],'script':_0x4f0b10[_0x1d759e('0x2566')]+'/'+_0x4f0b10[_0x1d759e('0xfd4')]})[_0x1d759e('0xa44')][_0x1d759e('0x1166')](function(){const _0x3a170e=_0x1d759e;return _0x4f0b10[_0x3a170e('0x1c0e')]=!![],_0x24ea6e['plugin'][_0x3a170e('0x1449')]({'id':_0x4f0b10['id']},_0x4f0b10)[_0x3a170e('0xa44')];})[_0x1d759e('0x1166')](function(){const _0x100fb4=_0x1d759e;_0x330ad3['installing']=![],_0x3414dc[_0x100fb4('0x103b')]({'title':_0x100fb4('0x7e2'),'msg':_0x4f0b10[_0x100fb4('0x4f0')]?_0x4f0b10[_0x100fb4('0x4f0')]+_0x100fb4('0x1d78'):''});})[_0x1d759e('0x1a80')](function(_0x5a226a){const _0x2b4cc5=_0x1d759e;if(_0x5a226a['data']&&_0x5a226a[_0x2b4cc5('0x25f4')]['errors']&&_0x5a226a['data'][_0x2b4cc5('0x61a')][_0x2b4cc5('0x264b')]){_0x330ad3[_0x2b4cc5('0x61a')]=_0x5a226a[_0x2b4cc5('0x25f4')]['errors']||[{'message':_0x5a226a[_0x2b4cc5('0x1586')](),'type':_0x2b4cc5('0x1dcb')}];for(let _0x30e502=0x0;_0x30e502<_0x5a226a[_0x2b4cc5('0x25f4')]['errors'][_0x2b4cc5('0x264b')];_0x30e502++){_0x3414dc[_0x2b4cc5('0xfc9')]({'title':_0x5a226a[_0x2b4cc5('0x25f4')][_0x2b4cc5('0x61a')][_0x30e502]['type'],'msg':_0x5a226a['data'][_0x2b4cc5('0x61a')][_0x30e502][_0x2b4cc5('0x1e70')]});}}else _0x3414dc[_0x2b4cc5('0xfc9')]({'title':_0x5a226a[_0x2b4cc5('0x52d')]?'API:'+_0x5a226a[_0x2b4cc5('0x52d')]+_0x2b4cc5('0x11e1')+_0x5a226a[_0x2b4cc5('0xe1b')]:'api.pm2.save','msg':_0x5a226a[_0x2b4cc5('0x25f4')]?JSON['stringify'](_0x5a226a[_0x2b4cc5('0x25f4')]['message']):_0x5a226a[_0x2b4cc5('0x1e70')]||_0x5a226a[_0x2b4cc5('0x1586')]()});});else return _0x4f0b10[_0x1d759e('0x1c0e')]=!![],_0x24ea6e[_0x1d759e('0xc0e')][_0x1d759e('0x1449')]({'id':_0x4f0b10['id']},_0x4f0b10)['$promise'][_0x1d759e('0x1166')](function(){const _0x1474c5=_0x1d759e;_0x3414dc[_0x1474c5('0x103b')]({'title':_0x1474c5('0x7e2'),'msg':_0x4f0b10[_0x1474c5('0x4f0')]?_0x4f0b10['name']+'\x20has\x20been\x20installed!':''});})[_0x1d759e('0x1a80')](function(_0x55f859){const _0x5be785=_0x1d759e;if(_0x55f859['data']&&_0x55f859['data']['errors']&&_0x55f859[_0x5be785('0x25f4')][_0x5be785('0x61a')]['length']){_0x330ad3[_0x5be785('0x61a')]=_0x55f859['data'][_0x5be785('0x61a')]||[{'message':_0x55f859[_0x5be785('0x1586')](),'type':_0x5be785('0x18ef')}];for(let _0x5b8f29=0x0;_0x5b8f29<_0x55f859[_0x5be785('0x25f4')][_0x5be785('0x61a')][_0x5be785('0x264b')];_0x5b8f29++){_0x3414dc[_0x5be785('0xfc9')]({'title':_0x55f859[_0x5be785('0x25f4')][_0x5be785('0x61a')][_0x5b8f29][_0x5be785('0x1345')],'msg':_0x55f859[_0x5be785('0x25f4')][_0x5be785('0x61a')][_0x5b8f29][_0x5be785('0x1e70')]});}}else _0x3414dc[_0x5be785('0xfc9')]({'title':_0x55f859[_0x5be785('0x52d')]?'API:'+_0x55f859['status']+_0x5be785('0x11e1')+_0x55f859['statusText']:_0x5be785('0x18ef'),'msg':_0x55f859[_0x5be785('0x25f4')]?JSON['stringify'](_0x55f859[_0x5be785('0x25f4')][_0x5be785('0x1e70')]):_0x55f859[_0x5be785('0x1e70')]||_0x55f859[_0x5be785('0x1586')]()});});}function _0x21a8a6(_0x40e61e){const _0x38fad5=_0x564dea;_0x4d857b['go'](_0x38fad5('0x1fb4'),{'id':_0x40e61e['id'],'plugin':_0x40e61e,'crudPermissions':_0x330ad3[_0x38fad5('0x243c')]});}function _0x1464af(_0x44e3d2,_0x45554e){const _0x1b17f7=_0x564dea,_0x30359f=_0x2c5fde['confirm']()[_0x1b17f7('0xcdc')](_0x1b17f7('0x2452'))[_0x1b17f7('0xf3c')](_0x1b17f7('0x12b5')+(_0x44e3d2[_0x1b17f7('0x4f0')]||_0x1b17f7('0xc0e'))+_0x1b17f7('0xace')+_0x1b17f7('0x378'))[_0x1b17f7('0x8e8')](_0x1b17f7('0x1d2f'))[_0x1b17f7('0x203b')](_0x45554e)['ok']('OK')[_0x1b17f7('0x3f')](_0x1b17f7('0x2d3'));_0x2c5fde[_0x1b17f7('0x1f80')](_0x30359f)[_0x1b17f7('0x1166')](function(){_0x1fb99f(_0x44e3d2);},function(){const _0x18c2c9=_0x1b17f7;console[_0x18c2c9('0x455')](_0x18c2c9('0x2d3'));});}function _0x1fb99f(_0x470a9e){const _0x309d65=_0x564dea;_0x24ea6e[_0x309d65('0x271e')][_0x309d65('0xd83')]()[_0x309d65('0xa44')][_0x309d65('0x1166')](function(_0x28c8b9){const _0x509e3a=_0x309d65;if(!_0x28c8b9||!_0x28c8b9['rows'])throw new Error(_0x509e3a('0x1fa8'));const _0x5de702=_0x2cfb05()[_0x509e3a('0xc38')](_0x28c8b9[_0x509e3a('0x269a')],{'name':_0x470a9e[_0x509e3a('0x1996')]});if(!_0x5de702)throw new Error(_0x509e3a('0x1556'));_0x24ea6e['pm2'][_0x509e3a('0x1449')]({'id':_0x5de702[_0x509e3a('0x84d')],'status':'stopped'})['$promise'][_0x509e3a('0x1166')](function(){const _0x5ee171=_0x509e3a;_0x3414dc[_0x5ee171('0x103b')]({'title':_0x5ee171('0x177c'),'msg':_0x5ee171('0x176f')});});})[_0x309d65('0x1a80')](function(_0x47e5fb){const _0x4065bc=_0x309d65;if(_0x47e5fb[_0x4065bc('0x25f4')]&&_0x47e5fb[_0x4065bc('0x25f4')][_0x4065bc('0x61a')]&&_0x47e5fb[_0x4065bc('0x25f4')][_0x4065bc('0x61a')][_0x4065bc('0x264b')]){_0x330ad3[_0x4065bc('0x61a')]=_0x47e5fb['data'][_0x4065bc('0x61a')]||[{'message':_0x47e5fb[_0x4065bc('0x1586')](),'type':'api.pm2.update'}];for(let _0x1230f5=0x0;_0x1230f5<_0x47e5fb[_0x4065bc('0x25f4')][_0x4065bc('0x61a')][_0x4065bc('0x264b')];_0x1230f5++){_0x3414dc['error']({'title':_0x47e5fb['data'][_0x4065bc('0x61a')][_0x1230f5][_0x4065bc('0x1345')],'msg':_0x47e5fb['data'][_0x4065bc('0x61a')][_0x1230f5][_0x4065bc('0x1e70')]});}}else _0x3414dc[_0x4065bc('0xfc9')]({'title':_0x47e5fb[_0x4065bc('0x52d')]?_0x4065bc('0x1e21')+_0x47e5fb[_0x4065bc('0x52d')]+_0x4065bc('0x11e1')+_0x47e5fb[_0x4065bc('0xe1b')]:_0x4065bc('0x2800'),'msg':_0x47e5fb[_0x4065bc('0x25f4')]?JSON[_0x4065bc('0xbac')](_0x47e5fb['data']['message']):_0x47e5fb[_0x4065bc('0x1e70')]||_0x47e5fb['toString']()});});}function _0x5b9e75(_0x55f000,_0x5434e5){const _0x2edece=_0x564dea,_0x136f22=_0x2c5fde['confirm']()[_0x2edece('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20restart\x20the\x20plugin\x20attached\x20process?')[_0x2edece('0xf3c')](_0x2edece('0x12b5')+(_0x55f000[_0x2edece('0x4f0')]||_0x2edece('0xc0e'))+_0x2edece('0xace')+_0x2edece('0x922'))[_0x2edece('0x8e8')](_0x2edece('0x12b9'))[_0x2edece('0x203b')](_0x5434e5)['ok']('OK')[_0x2edece('0x3f')](_0x2edece('0x2d3'));_0x2c5fde[_0x2edece('0x1f80')](_0x136f22)['then'](function(){_0x589675(_0x55f000);},function(){const _0x1878a6=_0x2edece;console['log'](_0x1878a6('0x2d3'));});}function _0x589675(_0x3856fc){const _0x1ddc37=_0x564dea;_0x24ea6e[_0x1ddc37('0x271e')][_0x1ddc37('0xd83')]()[_0x1ddc37('0xa44')][_0x1ddc37('0x1166')](function(_0x40d0ae){const _0x24bd82=_0x1ddc37;if(!_0x40d0ae||!_0x40d0ae[_0x24bd82('0x269a')])throw new Error(_0x24bd82('0x1fa8'));const _0x45b185=_0x2cfb05()[_0x24bd82('0xc38')](_0x40d0ae[_0x24bd82('0x269a')],{'name':_0x3856fc[_0x24bd82('0x1996')]});if(!_0x45b185)throw new Error(_0x24bd82('0x1556'));_0x24ea6e['pm2'][_0x24bd82('0x1449')]({'id':_0x45b185[_0x24bd82('0x84d')],'status':'online'})['$promise'][_0x24bd82('0x1166')](function(){const _0x34bcf5=_0x24bd82;_0x3414dc[_0x34bcf5('0x103b')]({'title':_0x34bcf5('0x19ac'),'msg':_0x34bcf5('0x1797')});});})[_0x1ddc37('0x1a80')](function(_0x159ffa){const _0x2ec3c8=_0x1ddc37;if(_0x159ffa['data']&&_0x159ffa['data'][_0x2ec3c8('0x61a')]&&_0x159ffa[_0x2ec3c8('0x25f4')][_0x2ec3c8('0x61a')][_0x2ec3c8('0x264b')]){_0x330ad3[_0x2ec3c8('0x61a')]=_0x159ffa['data']['errors']||[{'message':_0x159ffa['toString'](),'type':'api.pm2.update'}];for(let _0x19fe53=0x0;_0x19fe53<_0x159ffa[_0x2ec3c8('0x25f4')][_0x2ec3c8('0x61a')][_0x2ec3c8('0x264b')];_0x19fe53++){_0x3414dc[_0x2ec3c8('0xfc9')]({'title':_0x159ffa[_0x2ec3c8('0x25f4')][_0x2ec3c8('0x61a')][_0x19fe53][_0x2ec3c8('0x1345')],'msg':_0x159ffa[_0x2ec3c8('0x25f4')]['errors'][_0x19fe53]['message']});}}else _0x3414dc['error']({'title':_0x159ffa['status']?_0x2ec3c8('0x1e21')+_0x159ffa['status']+_0x2ec3c8('0x11e1')+_0x159ffa[_0x2ec3c8('0xe1b')]:_0x2ec3c8('0x2800'),'msg':_0x159ffa[_0x2ec3c8('0x25f4')]?JSON[_0x2ec3c8('0xbac')](_0x159ffa[_0x2ec3c8('0x25f4')][_0x2ec3c8('0x1e70')]):_0x159ffa[_0x2ec3c8('0x1e70')]||_0x159ffa[_0x2ec3c8('0x1586')]()});});}function _0x407550(_0x3d6181){const _0x4958e6=_0x564dea;return _0x24ea6e[_0x4958e6('0xc0e')]['download']({'id':_0x3d6181['id']})[_0x4958e6('0xa44')][_0x4958e6('0x1166')](function(_0x1fa0e0){const _0x59d8f3=_0x4958e6,_0x4ac2ef=[_0x1fa0e0[_0x59d8f3('0x20ed')]];let _0x322995=_0x59d8f3('0x2ad');const _0x299bea=new Blob(_0x4ac2ef,{'type':_0x1fa0e0[_0x59d8f3('0x1345')]});_0x322995=_0x3d6181[_0x59d8f3('0x4f0')][_0x59d8f3('0xf3')]('\x20','_')[_0x59d8f3('0x2574')]()+'.zip';const _0x2b4e7f=window[_0x59d8f3('0x136d')]['createElement']('a');_0x2b4e7f[_0x59d8f3('0xffd')](_0x59d8f3('0x14f9'),URL['createObjectURL'](_0x299bea)),_0x2b4e7f[_0x59d8f3('0xffd')]('download',_0x322995),document[_0x59d8f3('0x8d2')]['appendChild'](_0x2b4e7f),_0x2b4e7f[_0x59d8f3('0x3b4')]();})[_0x4958e6('0x1a80')](function(_0x374759){const _0x2036bc=_0x4958e6;if(_0x374759[_0x2036bc('0x25f4')]&&_0x374759[_0x2036bc('0x25f4')][_0x2036bc('0x61a')]&&_0x374759['data'][_0x2036bc('0x61a')]['length'])for(let _0x1471a9=0x0;_0x1471a9<_0x374759['data']['errors'][_0x2036bc('0x264b')];_0x1471a9++){_0x3414dc['error']({'title':_0x374759[_0x2036bc('0x25f4')][_0x2036bc('0x61a')][_0x1471a9]['type'],'msg':_0x374759[_0x2036bc('0x25f4')][_0x2036bc('0x61a')][_0x1471a9][_0x2036bc('0x1e70')]});}else _0x3414dc[_0x2036bc('0xfc9')]({'title':_0x374759[_0x2036bc('0x52d')]?'API:'+_0x374759['status']+_0x2036bc('0x11e1')+_0x374759['statusText']:_0x2036bc('0xe0c'),'msg':_0x374759['data']?JSON[_0x2036bc('0xbac')](_0x374759[_0x2036bc('0x25f4')][_0x2036bc('0x1e70')]):_0x374759[_0x2036bc('0x1586')]()});});}function _0x216969(_0x181bf7,_0x37b4c1){const _0x17490c=_0x564dea,_0x4ae3b6=_0x2c5fde['confirm']()[_0x17490c('0xcdc')](_0x17490c('0x27eb'))[_0x17490c('0xf3c')](_0x17490c('0x12b5')+(_0x181bf7['name']||_0x17490c('0xc0e'))+''+_0x17490c('0x15b1'))[_0x17490c('0x8e8')](_0x17490c('0x4aa'))[_0x17490c('0x203b')](_0x37b4c1)['ok']('OK')['cancel']('CANCEL');_0x2c5fde[_0x17490c('0x1f80')](_0x4ae3b6)['then'](function(){_0x89fde8(_0x181bf7);},function(){const _0x5d6c6b=_0x17490c;console[_0x5d6c6b('0x455')](_0x5d6c6b('0x2d3'));});}function _0x89fde8(_0x5ceca3){const _0x23b8bc=_0x564dea;return _0x5ceca3['type']===_0x23b8bc('0x12fe')&&_0x24ea6e['pm2'][_0x23b8bc('0xd83')]()[_0x23b8bc('0xa44')][_0x23b8bc('0x1166')](function(_0x29bb6e){const _0x3d5ddc=_0x23b8bc;if(!_0x29bb6e||!_0x29bb6e[_0x3d5ddc('0x269a')])throw new Error(_0x3d5ddc('0x1fa8'));const _0x3d11fb=_0x2cfb05()[_0x3d5ddc('0xc38')](_0x29bb6e['rows'],{'name':_0x5ceca3[_0x3d5ddc('0x1996')]});if(!_0x3d11fb)throw new Error(_0x3d5ddc('0x1556'));_0x24ea6e[_0x3d5ddc('0x271e')][_0x3d5ddc('0x906')]({'id':_0x3d11fb[_0x3d5ddc('0x84d')],'name':_0x5ceca3[_0x3d5ddc('0x1996')]})[_0x3d5ddc('0xa44')];})[_0x23b8bc('0x1a80')](function(_0x44eafe){const _0x409f23=_0x23b8bc;_0x3414dc[_0x409f23('0xfc9')]({'title':_0x44eafe[_0x409f23('0x52d')]?'API:'+_0x44eafe[_0x409f23('0x52d')]+'\x20-\x20'+_0x44eafe[_0x409f23('0xe1b')]:_0x409f23('0x873'),'msg':_0x44eafe[_0x409f23('0x25f4')]?JSON['stringify'](_0x44eafe[_0x409f23('0x25f4')]['message']):_0x44eafe[_0x409f23('0x1e70')]||_0x44eafe['toString']()});}),_0x5ceca3[_0x23b8bc('0x1c0e')]=![],_0x24ea6e[_0x23b8bc('0xc0e')]['update']({'id':_0x5ceca3['id']},_0x5ceca3)[_0x23b8bc('0xa44')]['then'](function(){const _0x3e560a=_0x23b8bc;_0x3414dc[_0x3e560a('0x103b')]({'title':'Plugin\x20uninstalled!','msg':_0x5ceca3['name']?_0x5ceca3[_0x3e560a('0x4f0')]+'\x20has\x20been\x20uninstalled!':''});})['catch'](function(_0x43e76f){const _0x39b6d2=_0x23b8bc;if(_0x43e76f[_0x39b6d2('0x25f4')]&&_0x43e76f[_0x39b6d2('0x25f4')]['errors']&&_0x43e76f[_0x39b6d2('0x25f4')]['errors'][_0x39b6d2('0x264b')]){_0x330ad3[_0x39b6d2('0x61a')]=_0x43e76f[_0x39b6d2('0x25f4')][_0x39b6d2('0x61a')]||[{'message':_0x43e76f[_0x39b6d2('0x1586')](),'type':_0x39b6d2('0x18ef')}];for(let _0x5bc351=0x0;_0x5bc351<_0x43e76f[_0x39b6d2('0x25f4')][_0x39b6d2('0x61a')][_0x39b6d2('0x264b')];_0x5bc351++){_0x3414dc[_0x39b6d2('0xfc9')]({'title':_0x43e76f[_0x39b6d2('0x25f4')][_0x39b6d2('0x61a')][_0x5bc351][_0x39b6d2('0x1345')],'msg':_0x43e76f[_0x39b6d2('0x25f4')][_0x39b6d2('0x61a')][_0x5bc351][_0x39b6d2('0x1e70')]});}}else _0x3414dc[_0x39b6d2('0xfc9')]({'title':_0x43e76f[_0x39b6d2('0x52d')]?_0x39b6d2('0x1e21')+_0x43e76f[_0x39b6d2('0x52d')]+'\x20-\x20'+_0x43e76f[_0x39b6d2('0xe1b')]:_0x39b6d2('0x18ef'),'msg':_0x43e76f[_0x39b6d2('0x25f4')]?JSON[_0x39b6d2('0xbac')](_0x43e76f[_0x39b6d2('0x25f4')][_0x39b6d2('0x1e70')]):_0x43e76f[_0x39b6d2('0x1e70')]||_0x43e76f[_0x39b6d2('0x1586')]()});});}function _0x29946b(_0x3244c3,_0x3e99b8){const _0x5b92c6=_0x564dea,_0x210558=_0x2c5fde[_0x5b92c6('0x1d26')]()[_0x5b92c6('0xcdc')](_0x5b92c6('0x288d')+_0x2cfb05()[_0x5b92c6('0xb35')](_0x5b92c6('0xc0e'))+'?')[_0x5b92c6('0xf3c')](_0x5b92c6('0x12b5')+(_0x3244c3[_0x5b92c6('0x4f0')]||_0x5b92c6('0xc0e'))+_0x5b92c6('0xace')+_0x5b92c6('0x3f3'))[_0x5b92c6('0x8e8')](_0x5b92c6('0x208c'))[_0x5b92c6('0x203b')](_0x3e99b8)['ok']('OK')[_0x5b92c6('0x3f')](_0x5b92c6('0x2d3'));_0x2c5fde['show'](_0x210558)[_0x5b92c6('0x1166')](function(){_0x236671(_0x3244c3);},function(){console['log']('CANCEL');});}let _0x17da22=!![],_0x19fd01=0x1;_0x7d5838['$watch'](_0x564dea('0x12d8'),function(_0x3f59c5,_0x118c36){const _0x3423cf=_0x564dea;_0x17da22?_0x373b60(function(){_0x17da22=![];}):(!_0x118c36&&(_0x19fd01=_0x330ad3['query']['page']),_0x3f59c5!==_0x118c36&&(_0x330ad3['query'][_0x3423cf('0x1a43')]=0x1),!_0x3f59c5&&(_0x330ad3[_0x3423cf('0x2218')][_0x3423cf('0x1a43')]=_0x19fd01),_0x330ad3[_0x3423cf('0xc07')]());});function _0x1b3f59(_0x4347f3){const _0x15a2a5=_0x564dea;_0x330ad3[_0x15a2a5('0x812')]=_0x4347f3||{'count':0x0,'rows':[]};}function _0x38a737(){const _0xc685cc=_0x564dea;_0x330ad3['query'][_0xc685cc('0x1098')]=(_0x330ad3[_0xc685cc('0x2218')][_0xc685cc('0x1a43')]-0x1)*_0x330ad3['query']['limit'],_0x1fad5b[_0xc685cc('0x1ac6')](_0xc685cc('0xa7c'))?_0x330ad3[_0xc685cc('0x1f48')]=_0x24ea6e[_0xc685cc('0xc0e')]['get'](_0x330ad3[_0xc685cc('0x2218')],_0x1b3f59)['$promise']:(_0x330ad3[_0xc685cc('0x2218')]['id']=_0x330ad3['userProfile']['id'],_0x330ad3[_0xc685cc('0x2218')][_0xc685cc('0xe60')]=_0xc685cc('0x1893'),_0x330ad3[_0xc685cc('0x1f48')]=_0x24ea6e[_0xc685cc('0x7f')][_0xc685cc('0x263a')](_0x330ad3['query'],_0x1b3f59)[_0xc685cc('0xa44')]);}function _0x30f26f(_0x5c292c,_0x5aa6ab){const _0x50539b=_0x564dea;_0x2c5fde['show']({'controller':_0x50539b('0x1602'),'controllerAs':'vm','templateUrl':_0x3b35fd,'parent':angular['element'](_0x596709[_0x50539b('0x8d2')]),'targetEvent':_0x5c292c,'clickOutsideToClose':!![],'locals':{'plugin':_0x5aa6ab,'plugins':_0x330ad3['plugins'][_0x50539b('0x269a')],'license':_0x330ad3[_0x50539b('0x5c9')],'setting':_0x330ad3['setting'],'crudPermissions':_0x330ad3[_0x50539b('0x243c')]}});}function _0x236671(_0x4b4b1d){const _0x445f3d=_0x564dea;_0x4b4b1d[_0x445f3d('0x1c0e')]&&_0x4b4b1d['type']==_0x445f3d('0x12fe')&&_0x24ea6e['pm2'][_0x445f3d('0xd83')]()['$promise'][_0x445f3d('0x1166')](function(_0x12da7e){const _0x3b362c=_0x445f3d;if(!_0x12da7e||!_0x12da7e[_0x3b362c('0x269a')])return _0x3414dc[_0x3b362c('0xfc9')]({'title':_0x3b362c('0xd34'),'msg':'Failed\x20to\x20retrieve\x20pm2\x20processes'});const _0xcd950a=_0x2cfb05()[_0x3b362c('0xc38')](_0x12da7e['rows'],{'name':_0x4b4b1d[_0x3b362c('0x1996')]});if(!_0xcd950a){console[_0x3b362c('0x455')](_0x3b362c('0x676'),_0x4b4b1d[_0x3b362c('0x1996')]);return;}_0x24ea6e[_0x3b362c('0x271e')][_0x3b362c('0x906')]({'id':_0xcd950a[_0x3b362c('0x84d')],'name':_0x4b4b1d['scriptName']})[_0x3b362c('0xa44')];})[_0x445f3d('0x1a80')](function(){const _0xc71421=_0x445f3d;return _0x3414dc[_0xc71421('0xfc9')]({'title':'PM2\x20process\x20not\x20found!','msg':'Failed\x20to\x20delete\x20the\x20attached\x20pm2\x20process'});}),_0x24ea6e[_0x445f3d('0xc0e')][_0x445f3d('0x906')]({'id':_0x4b4b1d['id']})['$promise'][_0x445f3d('0x1166')](function(){const _0x1ce5f5=_0x445f3d;_0x2cfb05()[_0x1ce5f5('0x127f')](_0x330ad3[_0x1ce5f5('0x812')][_0x1ce5f5('0x269a')],{'id':_0x4b4b1d['id']}),_0x330ad3['plugins'][_0x1ce5f5('0x240f')]-=0x1,!_0x330ad3['plugins'][_0x1ce5f5('0x269a')][_0x1ce5f5('0x264b')]&&_0x330ad3[_0x1ce5f5('0xc07')](),_0x3414dc[_0x1ce5f5('0x103b')]({'title':_0x2cfb05()['startCase'](_0x1ce5f5('0x19be'))+_0x1ce5f5('0x2b6'),'msg':_0x4b4b1d[_0x1ce5f5('0x4f0')]?_0x4b4b1d['name']+_0x1ce5f5('0x7cd'):''});})[_0x445f3d('0x1a80')](function(_0x1c9f6f){const _0x8e134c=_0x445f3d;if(_0x1c9f6f[_0x8e134c('0x25f4')]&&_0x1c9f6f[_0x8e134c('0x25f4')][_0x8e134c('0x61a')]&&_0x1c9f6f[_0x8e134c('0x25f4')][_0x8e134c('0x61a')]['length']){_0x330ad3[_0x8e134c('0x61a')]=_0x1c9f6f[_0x8e134c('0x25f4')][_0x8e134c('0x61a')]||[{'message':_0x1c9f6f[_0x8e134c('0x1586')](),'type':_0x8e134c('0x69c')}];for(let _0x498126=0x0;_0x498126<_0x1c9f6f[_0x8e134c('0x25f4')][_0x8e134c('0x61a')]['length'];_0x498126++){_0x3414dc['error']({'title':_0x1c9f6f[_0x8e134c('0x25f4')]['errors'][_0x498126][_0x8e134c('0x1345')],'msg':_0x1c9f6f[_0x8e134c('0x25f4')]['errors'][_0x498126]['message']});}}else _0x3414dc[_0x8e134c('0xfc9')]({'title':_0x1c9f6f[_0x8e134c('0x52d')]?_0x8e134c('0x1e21')+_0x1c9f6f[_0x8e134c('0x52d')]+_0x8e134c('0x11e1')+_0x1c9f6f[_0x8e134c('0xe1b')]:_0x8e134c('0x69c'),'msg':_0x1c9f6f[_0x8e134c('0x25f4')]?JSON[_0x8e134c('0xbac')](_0x1c9f6f[_0x8e134c('0x25f4')][_0x8e134c('0x1e70')]):_0x1c9f6f[_0x8e134c('0x1e70')]||_0x1c9f6f[_0x8e134c('0x1586')]()});});}function _0x38343e(){const _0x58b93b=_0x564dea,_0x59287b=angular[_0x58b93b('0x225f')](_0x330ad3['selectedPlugins']);return _0x330ad3[_0x58b93b('0x1c94')]=[],_0x59287b;}function _0x497abd(_0xc2c403){const _0x1d539d=_0x564dea,_0x45d03f=_0x2c5fde['confirm']()[_0x1d539d('0xcdc')](_0x1d539d('0x2585'))['htmlContent'](_0x1d539d('0x12b5')+_0x330ad3[_0x1d539d('0x1c94')][_0x1d539d('0x264b')]+_0x1d539d('0x196d')+_0x1d539d('0x3f3'))[_0x1d539d('0x8e8')](_0x1d539d('0xb71'))[_0x1d539d('0x203b')](_0xc2c403)['ok']('OK')['cancel']('CANCEL');_0x2c5fde[_0x1d539d('0x1f80')](_0x45d03f)[_0x1d539d('0x1166')](function(){const _0x3553ed=_0x1d539d;_0x330ad3['selectedPlugins'][_0x3553ed('0x2782')](function(_0x3e459e){_0x236671(_0x3e459e);}),_0x330ad3['selectedPlugins']=[];});}function _0x54e6d8(){_0x330ad3['selectedPlugins']=[];}function _0x48317c(){const _0x2462ca=_0x564dea;_0x330ad3[_0x2462ca('0x1c94')]=_0x330ad3[_0x2462ca('0x812')][_0x2462ca('0x269a')];}function _0x26c5c4(_0x29c1cc){const _0x2a9425=_0x564dea;_0x2c5fde[_0x2a9425('0x1f80')]({'controller':_0x2a9425('0x1b55'),'controllerAs':'vm','templateUrl':_0x32364a,'parent':angular[_0x2a9425('0x1194')](_0x596709['body']),'targetEvent':_0x29c1cc,'clickOutsideToClose':!![],'locals':{'plugins':_0x330ad3[_0x2a9425('0x812')]['rows']}});}}const _0x559faa=_0x31b7a3;_0x38a68b['$inject']=['$cookies',_0x36e6f4('0x265d'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x812'),'api','Auth'];function _0x38a68b(_0x295aef,_0x40ac66,_0x1d0aca,_0x4da765,_0x28e1f0,_0x2d9de7){const _0xc505bb=_0x36e6f4,_0x293255=this,_0x4d3cec=0x2,_0x45a63b=_0x4d3cec*0x400*0x400;_0x293255[_0xc505bb('0x98')]=_0x2d9de7[_0xc505bb('0x26cd')](),_0x293255[_0xc505bb('0x61a')]=[],_0x293255['title']=_0xc505bb('0x1e12'),_0x293255[_0xc505bb('0x812')]=_0x4da765,_0x293255['uploadPlugins']=[],_0x293255[_0xc505bb('0x279a')]='none',_0x293255['plugin']={},_0x293255[_0xc505bb('0xd67')]={'maxChunkRetries':0x1,'chunkSize':_0x45a63b,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![],'target':_0xc505bb('0x133a')},_0x293255[_0xc505bb('0xe57')]={'flow':{}},_0x293255[_0xc505bb('0x1a5c')]=![],_0x293255['fileAdded']=_0x6c74e7,_0x293255[_0xc505bb('0x1d40')]=_0x5394c0,_0x293255[_0xc505bb('0x1dea')]=_0x7f431c,_0x293255[_0xc505bb('0x22a6')]=_0x17f97d,_0x293255[_0xc505bb('0x14c2')]=_0x2783b2,_0x293255[_0xc505bb('0x24a0')]=_0x5f0b17;function _0x6c74e7(_0x5db850){const _0x2b91eb=_0xc505bb,_0x1edc7e=[_0x2b91eb('0x153f')];if(!_0x2cfb05()['includes'](_0x1edc7e,_0x5db850[_0x2b91eb('0x26a5')]()))return _0x1d0aca[_0x2b91eb('0xfc9')]({'title':'Invalid\x20extension:\x20'+_0x5db850[_0x2b91eb('0x26a5')](),'msg':_0x2b91eb('0x1020')+_0x1edc7e['join']()}),![];if(_0x5db850[_0x2b91eb('0x2340')]>_0x45a63b)return _0x1d0aca[_0x2b91eb('0xfc9')]({'title':_0x2b91eb('0x11e6'),'msg':_0x2b91eb('0x12c0')+_0x4d3cec+'MB'}),![];return _0x293255['plugin']={'id':_0x5db850[_0x2b91eb('0x20f4')],'file':_0x5db850},_0x293255[_0x2b91eb('0x1236')][_0x2b91eb('0x2450')](_0x293255['plugin']),!![];}function _0x5394c0(){const _0x448163=_0xc505bb;_0x293255[_0x448163('0x279a')]=_0x448163('0x32f'),_0x293255[_0x448163('0xe57')][_0x448163('0x13d1')][_0x448163('0x1ca3')][_0x448163('0x5fb')]={'X-Requested-With':'XMLHttpRequest','Authorization':_0x448163('0x24d4')+_0x295aef[_0x448163('0xd83')](_0x448163('0x10b6'))},_0x293255['ngFlow'][_0x448163('0x13d1')][_0x448163('0x1ca3')][_0x448163('0x2218')]={'role':_0x293255['currentUser'][_0x448163('0x1e75')],'userProfileId':_0x293255[_0x448163('0x98')][_0x448163('0xb86')]},_0x293255[_0x448163('0xe57')][_0x448163('0x13d1')][_0x448163('0x1d40')]();}function _0x7f431c(_0x16a4bb,_0x30e59e){const _0x1982e0=_0xc505bb;_0x293255[_0x1982e0('0x812')]['unshift'](JSON[_0x1982e0('0x1295')](_0x30e59e)),angular[_0x1982e0('0x2782')](_0x293255[_0x1982e0('0x1236')],function(_0x18fa65){const _0x439ee5=_0x1982e0;if(_0x18fa65['id']===_0x16a4bb[_0x439ee5('0x20f4')]){const _0x52c784=new FileReader();_0x52c784['readAsDataURL'](_0x18fa65['file'][_0x439ee5('0x6bd')]),_0x52c784[_0x439ee5('0x15d4')]=function(_0x1c64de){const _0x27d4e3=_0x439ee5;_0x18fa65[_0x27d4e3('0xcac')]=_0x1c64de[_0x27d4e3('0x21cc')][_0x27d4e3('0x15b5')];};}});}function _0x17f97d(){const _0x2a292e=_0xc505bb;_0x293255[_0x2a292e('0xe57')][_0x2a292e('0x13d1')]['cancel'](),_0x1d0aca[_0x2a292e('0xfc9')]({'title':'Upload\x20error','msg':_0x2a292e('0xe74')}),_0x293255[_0x2a292e('0x279a')]=_0x2a292e('0x1140');}function _0x2783b2(){const _0x4ef76f=_0xc505bb;_0x293255[_0x4ef76f('0x279a')]!==_0x4ef76f('0x1140')&&(_0x293255[_0x4ef76f('0x279a')]=_0x4ef76f('0x280a'),_0x1d0aca[_0x4ef76f('0x103b')]({'title':_0x4ef76f('0x1bcd'),'msg':_0x293255[_0x4ef76f('0xc0e')]['file'][_0x4ef76f('0x4f0')]+_0x4ef76f('0xe73')}));}function _0x5f0b17(){_0x40ac66['hide']();}}const _0x228d38=_0x38a68b;_0x12ca94[_0x36e6f4('0x1294')]=['$stateProvider',_0x36e6f4('0x1562')];function _0x12ca94(_0x40d0fe,_0x39b4b1){const _0x1d5e05=_0x36e6f4;_0x40d0fe[_0x1d5e05('0x63f')](_0x1d5e05('0x5c1'),{'abstract':!![],'url':'/marketplace'})[_0x1d5e05('0x63f')](_0x1d5e05('0x165e'),{'url':'/plugins','views':{'content@app':{'templateUrl':_0x268121,'controller':_0x1d5e05('0x1a7e')}},'resolve':{'plugins':['apiResolver',_0x1d5e05('0x21ef'),function(_0x17c756,_0x51f611){const _0x3d4a1=_0x1d5e05;return _0x51f611[_0x3d4a1('0x1ac6')](_0x3d4a1('0xa7c'))?_0x17c756[_0x3d4a1('0x18af')](_0x3d4a1('0x21c6'),{'fields':_0x3d4a1('0x20f8'),'sort':_0x3d4a1('0x4f0'),'limit':0xa,'offset':0x0}):_0x17c756[_0x3d4a1('0x18af')](_0x3d4a1('0x17c4'),{'id':_0x51f611[_0x3d4a1('0x26cd')]()['userProfileId'],'section':_0x3d4a1('0x1893'),'fields':_0x3d4a1('0x20f8'),'sort':_0x3d4a1('0x4f0'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x1d5e05('0x1fbc'),_0x1d5e05('0x21ef'),function(_0xc9a903,_0x12d18e){const _0x3202e2=_0x1d5e05;return _0x12d18e[_0x3202e2('0x1ac6')]('admin')?null:_0xc9a903[_0x3202e2('0x18af')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x12d18e[_0x3202e2('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x1d5e05('0x1fbc'),_0x1d5e05('0x21ef'),function(_0x2eca9e,_0x1d7757){const _0x14e0e7=_0x1d5e05;return _0x1d7757[_0x14e0e7('0x1ac6')](_0x14e0e7('0xa7c'))?null:_0x2eca9e[_0x14e0e7('0x18af')](_0x14e0e7('0xaf'),{'fields':_0x14e0e7('0xe26'),'userProfileId':_0x1d7757['getCurrentUser']()[_0x14e0e7('0xb86')],'sectionId':0x709});}]},'authenticate':!![],'permissionId':0x709,'bodyClass':_0x1d5e05('0x1717')})[_0x1d5e05('0x63f')](_0x1d5e05('0x1fb4'),{'url':'/:id?tab','params':{'plugin':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x27a771,'controller':_0x1d5e05('0x1845')}},'resolve':{'plugin':['apiResolver',_0x1d5e05('0xf75'),function(_0x400420,_0x4079e2){const _0x450d5a=_0x1d5e05;return _0x400420[_0x450d5a('0x18af')]('plugin@get',{'fields':_0x450d5a('0x20f8'),'id':_0x4079e2['id']});}],'userProfileSection':[_0x1d5e05('0x1fbc'),_0x1d5e05('0x21ef'),function(_0x9f6a2,_0x2c98f7){const _0x1594bd=_0x1d5e05;return _0x9f6a2['resolve']('userProfileSection@get',{'fields':_0x1594bd('0xe26'),'userProfileId':_0x2c98f7['getCurrentUser']()[_0x1594bd('0xb86')],'sectionId':0x709});}]},'authenticate':!![],'permissionId':0x709,'bodyClass':_0x1d5e05('0x1717')}),_0x39b4b1[_0x1d5e05('0x95e')](_0x1d5e05('0x145e'));}angular['module'](_0x36e6f4('0x5c1'),['ngCsv',_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),_0x36e6f4('0x13d1'),_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),'ngAnimate',_0x36e6f4('0x2819'),'mwFormBuilder','mwFormViewer','mwFormUtils',_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),'chart.js','angular.filter'])[_0x36e6f4('0xe11')](_0x12ca94)[_0x36e6f4('0x75e')]('CreateOrEditPluginDialogController',_0x5b79ac)['controller'](_0x36e6f4('0x63'),_0xccce64)['controller'](_0x36e6f4('0x233f'),_0x559faa)['controller'](_0x36e6f4('0x1b55'),_0x228d38);const _0x5b0525=_0x2734b2['p']+'src/js/modules/main/apps/plugins/views/plugin/plugin.html/plugin.html';_0x2c595b['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x36f'),'$sce',_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),_0x36e6f4('0x21ef')];function _0x2c595b(_0x5f2e60,_0x564024,_0x53528d,_0x300951,_0xbd2cda,_0x48183a){const _0x2b92a6=_0x36e6f4,_0x1bc955=this;_0x1bc955[_0x2b92a6('0x98')]=_0x48183a[_0x2b92a6('0x26cd')](),_0x1bc955[_0x2b92a6('0xc0e')]={},_0x1bc955['getTrustedURL']=_0x53bd3b,_0x300951[_0x2b92a6('0xc0e')][_0x2b92a6('0xd83')]({'id':_0x5f2e60[_0x2b92a6('0x23f')]['id']})[_0x2b92a6('0xa44')][_0x2b92a6('0x1166')](function(_0x5f3cb3){const _0xb90e6e=_0x2b92a6;if(_0x5f3cb3)return _0x1bc955[_0xb90e6e('0xc0e')]=_0x5f3cb3,_0x300951[_0xb90e6e('0xc0e')][_0xb90e6e('0xd83')]({'id':_0x1bc955[_0xb90e6e('0xc0e')]['id']})[_0xb90e6e('0xa44')];})[_0x2b92a6('0x1a80')](function(){const _0x6b0fa9=_0x2b92a6;_0x1bc955[_0x6b0fa9('0xc0e')]=undefined;});function _0x53bd3b(){const _0x95a57d=_0x2b92a6;return _0x53528d['trustAsResourceUrl'](_0x1bc955['plugin'][_0x95a57d('0x1b5e')]);}}const _0x4ffbfe=_0x2c595b;_0x2a81c8[_0x36e6f4('0x1294')]=['$stateProvider'];function _0x2a81c8(_0x3d003a){const _0x1d3724=_0x36e6f4;_0x3d003a['state'](_0x1d3724('0x1159'),{'url':'/plugin/:id','views':{'content@app':{'templateUrl':_0x5b0525,'controller':_0x1d3724('0x2065')}},'resolve':{},'authenticate':!![],'bodyClass':_0x1d3724('0x812')});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x1159'),[])[_0x36e6f4('0xe11')](_0x2a81c8)['controller'](_0x36e6f4('0x1ade'),_0x4ffbfe),_0x409781[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x409781(_0x4aa073,_0x19d5d1){const _0x400432=_0x36e6f4;_0x4aa073['state'](_0x400432('0x1e03'),{'abstract':!![],'url':'/plugins'}),_0x19d5d1[_0x400432('0x95e')](_0x400432('0x1f76'));}angular['module'](_0x36e6f4('0x1e03'),['ngCsv','ngPassword',_0x36e6f4('0x196c'),'flow',_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),'ng-sortable','ngAria',_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),'mwFormBuilder','mwFormViewer',_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411'),_0x36e6f4('0x1159')])[_0x36e6f4('0xe11')](_0x409781);const _0x179e01=_0x2734b2['p']+'src/js/modules/main/apps/video/views/screenRecordings/screenRecordings.html/screenRecordings.html';_0x2cbd68[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x16d6'),'screenRecording',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'license',_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x2cbd68(_0xfca447,_0x530205,_0x3bd0a4,_0x370d3c,_0x4803d1,_0x1a829a,_0x51991d,_0x836bb9,_0x5baa64,_0x14af98,_0x54a0fe,_0x458e81,_0xa2dd36,_0x339d59){const _0x431493=_0x36e6f4,_0x4fdf4c=this;_0x4fdf4c['currentUser']=_0x54a0fe[_0x431493('0x26cd')](),_0x4fdf4c[_0x431493('0x61a')]=[],_0x4fdf4c[_0x431493('0xf8a')]=_0xa2dd36,_0x4fdf4c['license']=_0x458e81,_0x4fdf4c[_0x431493('0x243c')]=_0x339d59,_0x4fdf4c[_0x431493('0x128b')]={},_0x4fdf4c['passwordPattern']=_0x4fdf4c['setting']&&_0x4fdf4c[_0x431493('0xf8a')][_0x431493('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4fdf4c[_0x431493('0xcdc')]=_0x431493('0xa84'),_0x4fdf4c[_0x431493('0x2845')]=angular['copy'](_0x5baa64),_0x4fdf4c['screenRecordings']=_0x836bb9,_0x4fdf4c[_0x431493('0xb17')]=![];!_0x4fdf4c[_0x431493('0x2845')]&&(_0x4fdf4c[_0x431493('0x2845')]={},_0x4fdf4c[_0x431493('0xcdc')]=_0x431493('0x26c8'),_0x4fdf4c['newscreenRecording']=!![]);_0x4fdf4c[_0x431493('0x1dae')]=_0x527430,_0x4fdf4c[_0x431493('0x277f')]=_0x497f5e,_0x4fdf4c['deletescreenRecording']=_0x29dc4d,_0x4fdf4c['getDateFromString']=_0x150f2b,_0x4fdf4c['closeDialog']=_0xbb6948,_0x14af98[_0x431493('0x557')][_0x431493('0xd83')]({'fields':_0x431493('0xce1'),'sort':_0x431493('0x4f0'),'nolimit':_0x431493('0xf3b')})['$promise'][_0x431493('0x1166')](function(_0xf1a3ea){const _0x19da0c=_0x431493;_0x4fdf4c[_0x19da0c('0x21f6')]=_0xf1a3ea[_0x19da0c('0x269a')]||[];})[_0x431493('0x1a80')](function(_0x2f49d6){const _0x132cf8=_0x431493;_0x51991d[_0x132cf8('0xfc9')]({'title':_0x2f49d6[_0x132cf8('0x52d')]?_0x132cf8('0x1e21')+_0x2f49d6['status']+_0x132cf8('0x11e1')+_0x2f49d6[_0x132cf8('0xe1b')]:'SYSTEM:GET_USERS','msg':_0x2f49d6[_0x132cf8('0x25f4')]?JSON['stringify'](_0x2f49d6[_0x132cf8('0x25f4')]):_0x2f49d6[_0x132cf8('0x1586')]()});});function _0x527430(){const _0x586181=_0x431493;_0x4fdf4c[_0x586181('0x61a')]=[],_0x14af98[_0x586181('0x2845')]['save'](_0x4fdf4c[_0x586181('0x2845')])[_0x586181('0xa44')][_0x586181('0x1166')](function(_0x3e6d06){const _0xbcb633=_0x586181;_0x4fdf4c[_0xbcb633('0x16d6')][_0xbcb633('0x2450')](_0x3e6d06[_0xbcb633('0x2876')]()),_0x51991d[_0xbcb633('0x103b')]({'title':_0xbcb633('0x2821'),'msg':_0x4fdf4c[_0xbcb633('0x2845')][_0xbcb633('0x4f0')]?_0x4fdf4c[_0xbcb633('0x2845')]['name']+_0xbcb633('0x1eda'):''}),_0xbb6948(_0x3e6d06);})[_0x586181('0x1a80')](function(_0x1468da){const _0x53c81b=_0x586181;if(_0x1468da[_0x53c81b('0x25f4')]&&_0x1468da['data'][_0x53c81b('0x61a')]&&_0x1468da[_0x53c81b('0x25f4')][_0x53c81b('0x61a')]['length']){_0x4fdf4c[_0x53c81b('0x61a')]=_0x1468da[_0x53c81b('0x25f4')]['errors']||[{'message':_0x1468da[_0x53c81b('0x1586')](),'type':'api.screenRecording.save'}];for(let _0x3e86fc=0x0;_0x3e86fc<_0x1468da[_0x53c81b('0x25f4')][_0x53c81b('0x61a')][_0x53c81b('0x264b')];_0x3e86fc+=0x1){_0x51991d['error']({'title':_0x1468da['data'][_0x53c81b('0x61a')][_0x3e86fc]['type'],'msg':_0x1468da[_0x53c81b('0x25f4')][_0x53c81b('0x61a')][_0x3e86fc][_0x53c81b('0x1e70')]});}}else _0x51991d[_0x53c81b('0xfc9')]({'title':_0x1468da['status']?'API:'+_0x1468da[_0x53c81b('0x52d')]+'\x20-\x20'+_0x1468da[_0x53c81b('0xe1b')]:_0x53c81b('0x953'),'msg':_0x1468da[_0x53c81b('0x25f4')]?JSON[_0x53c81b('0xbac')](_0x1468da[_0x53c81b('0x25f4')][_0x53c81b('0x1e70')]):_0x1468da[_0x53c81b('0x1586')]()});});}function _0x497f5e(){const _0x116488=_0x431493;_0x4fdf4c[_0x116488('0x61a')]=[],_0x14af98[_0x116488('0x2845')]['update']({'id':_0x4fdf4c['screenRecording']['id']},_0x4fdf4c[_0x116488('0x2845')])[_0x116488('0xa44')][_0x116488('0x1166')](function(_0x4c8b4b){const _0x3e8d1a=_0x116488,_0x4b9a84=_0x2cfb05()[_0x3e8d1a('0xc38')](_0x4fdf4c[_0x3e8d1a('0x16d6')],{'id':_0x4c8b4b['id']});_0x4b9a84&&_0x2cfb05()['merge'](_0x4b9a84,_0x2cfb05()[_0x3e8d1a('0x1a08')](_0x4c8b4b[_0x3e8d1a('0x2876')](),_0x2cfb05()[_0x3e8d1a('0x14a4')](_0x4b9a84))),_0x51991d[_0x3e8d1a('0x103b')]({'title':'screenRecording\x20properly\x20saved!','msg':_0x4fdf4c[_0x3e8d1a('0x2845')][_0x3e8d1a('0x4f0')]?_0x4fdf4c[_0x3e8d1a('0x2845')]['name']+_0x3e8d1a('0x7d'):''}),_0xbb6948(_0x4c8b4b);})['catch'](function(_0x4af8bb){const _0x543dc2=_0x116488;if(_0x4af8bb['data']&&_0x4af8bb[_0x543dc2('0x25f4')][_0x543dc2('0x61a')]&&_0x4af8bb[_0x543dc2('0x25f4')][_0x543dc2('0x61a')][_0x543dc2('0x264b')]){_0x4fdf4c['errors']=_0x4af8bb[_0x543dc2('0x25f4')]['errors']||[{'message':_0x4af8bb[_0x543dc2('0x1586')](),'type':_0x543dc2('0x2004')}];for(let _0xef56c=0x0;_0xef56c<_0x4af8bb[_0x543dc2('0x25f4')][_0x543dc2('0x61a')][_0x543dc2('0x264b')];_0xef56c++){_0x51991d[_0x543dc2('0xfc9')]({'title':_0x4af8bb['data'][_0x543dc2('0x61a')][_0xef56c][_0x543dc2('0x1345')],'msg':_0x4af8bb[_0x543dc2('0x25f4')][_0x543dc2('0x61a')][_0xef56c]['message']});}}else _0x51991d[_0x543dc2('0xfc9')]({'title':_0x4af8bb['status']?_0x543dc2('0x1e21')+_0x4af8bb[_0x543dc2('0x52d')]+'\x20-\x20'+_0x4af8bb[_0x543dc2('0xe1b')]:_0x543dc2('0x2004'),'msg':_0x4af8bb[_0x543dc2('0x25f4')]?JSON[_0x543dc2('0xbac')](_0x4af8bb[_0x543dc2('0x25f4')][_0x543dc2('0x1e70')]):_0x4af8bb[_0x543dc2('0x1586')]()});});}function _0x29dc4d(_0x216ffb){const _0x5d0ec9=_0x431493;_0x4fdf4c[_0x5d0ec9('0x61a')]=[];const _0x11cbc9=_0x370d3c['confirm']()['title'](_0x5d0ec9('0x7fb'))[_0x5d0ec9('0xacc')](_0x5d0ec9('0x167b'))[_0x5d0ec9('0x8e8')]('Delete\x20screenRecording')['ok'](_0x5d0ec9('0x18'))['cancel'](_0x5d0ec9('0x497'))[_0x5d0ec9('0x203b')](_0x216ffb);_0x370d3c[_0x5d0ec9('0x1f80')](_0x11cbc9)[_0x5d0ec9('0x1166')](function(){const _0x163e79=_0x5d0ec9;_0x14af98[_0x163e79('0x2845')][_0x163e79('0x906')]({'id':_0x4fdf4c[_0x163e79('0x2845')]['id']})[_0x163e79('0xa44')][_0x163e79('0x1166')](function(){const _0x1bc52f=_0x163e79;_0x2cfb05()[_0x1bc52f('0x127f')](_0x4fdf4c[_0x1bc52f('0x16d6')],{'id':_0x4fdf4c['screenRecording']['id']}),_0x51991d[_0x1bc52f('0x103b')]({'title':_0x1bc52f('0x1b0f'),'msg':(_0x4fdf4c[_0x1bc52f('0x2845')][_0x1bc52f('0x4f0')]||_0x1bc52f('0x2845'))+_0x1bc52f('0x7cd')}),_0xbb6948(_0x4fdf4c[_0x1bc52f('0x2845')]);})[_0x163e79('0x1a80')](function(_0x4a91de){const _0xb577c9=_0x163e79;if(_0x4a91de[_0xb577c9('0x25f4')]&&_0x4a91de[_0xb577c9('0x25f4')][_0xb577c9('0x61a')]&&_0x4a91de[_0xb577c9('0x25f4')][_0xb577c9('0x61a')][_0xb577c9('0x264b')]){_0x4fdf4c[_0xb577c9('0x61a')]=_0x4a91de[_0xb577c9('0x25f4')]['errors']||[{'message':_0x4a91de[_0xb577c9('0x1586')](),'type':_0xb577c9('0x54b')}];for(let _0x51df74=0x0;_0x51df74<_0x4a91de[_0xb577c9('0x25f4')][_0xb577c9('0x61a')]['length'];_0x51df74++){_0x51991d['error']({'title':_0x4a91de[_0xb577c9('0x25f4')][_0xb577c9('0x61a')][_0x51df74][_0xb577c9('0x1345')],'msg':_0x4a91de[_0xb577c9('0x25f4')][_0xb577c9('0x61a')][_0x51df74][_0xb577c9('0x1e70')]});}}else _0x51991d[_0xb577c9('0xfc9')]({'title':_0x4a91de[_0xb577c9('0x52d')]?_0xb577c9('0x1e21')+_0x4a91de[_0xb577c9('0x52d')]+_0xb577c9('0x11e1')+_0x4a91de[_0xb577c9('0xe1b')]:_0xb577c9('0x54b'),'msg':_0x4a91de[_0xb577c9('0x25f4')]?JSON[_0xb577c9('0xbac')](_0x4a91de['data'][_0xb577c9('0x1e70')]):_0x4a91de[_0xb577c9('0x1e70')]||_0x4a91de['toString']()});});},function(){});}function _0x150f2b(_0x28406a){return _0x28406a===null?undefined:new Date(_0x28406a);}function _0xbb6948(_0xb950bf){_0x370d3c['hide'](_0xb950bf);}}const _0x3ab4ad=_0x2cbd68;_0x509bab['$inject']=['$scope',_0x36e6f4('0x265d'),'toasty',_0x36e6f4('0x19e3'),_0x36e6f4('0x224d'),_0x36e6f4('0x21b5'),_0x36e6f4('0x8ce'),_0x36e6f4('0x9eb'),_0x36e6f4('0x971'),'$q'];function _0x509bab(_0x5aa911,_0x49baa0,_0x467b73,_0x2aaa1c,_0x5a7aa5,_0x4fe1be,_0x6c7745,_0x2f30d2,_0x29e52b,_0x3acb7b){const _0x19dbde=_0x36e6f4,_0x18b2ca=this;_0x18b2ca['loading']=![],_0x18b2ca[_0x19dbde('0x224d')]=Object['assign']({},_0x5a7aa5),_0x18b2ca['route']=_0x19dbde('0x2845'),_0x18b2ca[_0x19dbde('0x1194')]=_0x29e52b,_0x18b2ca[_0x19dbde('0x21b5')]=Object['assign']({},_0x4fe1be),_0x18b2ca['path']=_0x2f30d2,_0x18b2ca[_0x19dbde('0x8ce')]=_0x6c7745,_0x18b2ca['app']=_0x19dbde('0x7ea'),_0x18b2ca['model']='screenRecording',console['log']('TCL:\x20vm.path',_0x18b2ca[_0x19dbde('0x2566')]),console[_0x19dbde('0x455')]('TCL:\x20vm.recording[vm.path]',_0x18b2ca['recording'][_0x18b2ca[_0x19dbde('0x2566')]]),_0x18b2ca[_0x19dbde('0x1e15')]=_0x18b2ca[_0x19dbde('0x224d')][_0x18b2ca[_0x19dbde('0x2566')]]['indexOf']('/')>-0x1?_0x18b2ca[_0x19dbde('0x224d')][_0x18b2ca['path']][_0x19dbde('0x192f')](_0x18b2ca['recording'][_0x18b2ca[_0x19dbde('0x2566')]][_0x19dbde('0x19da')]('/')+0x1):_0x18b2ca[_0x19dbde('0x224d')][_0x18b2ca['path']][_0x19dbde('0x2379')]('\x5c')>-0x1?_0x18b2ca['recording'][_0x18b2ca[_0x19dbde('0x2566')]]['substring'](_0x18b2ca[_0x19dbde('0x224d')][_0x18b2ca['path']][_0x19dbde('0x19da')]('\x5c')+0x1):_0x18b2ca[_0x19dbde('0x224d')][_0x18b2ca['path']],_0x18b2ca[_0x19dbde('0x128a')]=![];_0x2cfb05()[_0x19dbde('0x2863')](_0x18b2ca[_0x19dbde('0x224d')][_0x19dbde('0x128a')])&&(_0x18b2ca[_0x19dbde('0x224d')][_0x19dbde('0x128a')]=_0x18b2ca[_0x19dbde('0x1e15')][_0x19dbde('0x233')](_0x18b2ca['filename'][_0x19dbde('0x19da')]('.')));(_0x18b2ca[_0x19dbde('0x224d')][_0x19dbde('0x128a')]===_0x19dbde('0xf37')&&_0x18b2ca[_0x19dbde('0x1194')]===_0x19dbde('0xeeb')||_0x18b2ca[_0x19dbde('0x224d')][_0x19dbde('0x128a')]==='.mp4'&&_0x18b2ca[_0x19dbde('0x1194')]===_0x19dbde('0x7ea'))&&(_0x18b2ca[_0x19dbde('0x128a')]=!![]);_0x18b2ca[_0x19dbde('0x638')]=!![];_0x18b2ca[_0x19dbde('0x128a')]&&_0x5d58dd();function _0x5d58dd(){const _0x4b50f6=_0x19dbde,_0x3b7758=_0x3acb7b[_0x4b50f6('0x24d8')]();return _0x2aaa1c[_0x4b50f6('0x2845')]['download']({'id':_0x18b2ca[_0x4b50f6('0x224d')]['id'],'path':String(_0x18b2ca[_0x4b50f6('0x2566')])})['$promise']['then'](function(){const _0x160e33=_0x4b50f6;_0x18b2ca[_0x160e33('0x128a')]=!![],_0x18b2ca['found']=!![],_0x3b7758[_0x160e33('0x18af')]();})['catch'](function(){const _0x23de98=_0x4b50f6;console['log'](_0x23de98('0x137d')),_0x18b2ca[_0x23de98('0x128a')]=![],_0x18b2ca[_0x23de98('0x638')]=![],_0x3b7758[_0x23de98('0x18af')]();}),_0x3b7758[_0x4b50f6('0x1f48')];}if(!_0x2cfb05()[_0x19dbde('0x2863')](_0x4fe1be[_0x19dbde('0x1c0c')])&&_0x4fe1be[_0x19dbde('0x1c0c')]){_0x18b2ca[_0x19dbde('0x1c0c')]=Object[_0x19dbde('0xa12')]({},_0x5a7aa5);const _0x1ddc8e=Object[_0x19dbde('0x14a4')](_0x5a7aa5);_0x1ddc8e[_0x19dbde('0x2782')](function(_0x364be5){const _0x42e4d3=_0x19dbde;String(_0x364be5[0x0][_0x42e4d3('0x1387')]())===String(_0x364be5[0x0])&&delete _0x18b2ca[_0x42e4d3('0x1c0c')][_0x364be5];}),_0x18b2ca[_0x19dbde('0x1870')]={};if(!_0x2cfb05()[_0x19dbde('0x2863')](_0x4fe1be[_0x19dbde('0x3e7')])&&_0x4fe1be['propertiesList'][_0x19dbde('0x264b')]>0x0){_0x18b2ca[_0x19dbde('0x1870')]=Object[_0x19dbde('0xa12')]({},_0x5a7aa5);const _0x58acb4=_0x4fe1be[_0x19dbde('0x3e7')],_0x2fcc1e=Object[_0x19dbde('0x14a4')](_0x5a7aa5);let _0x2e979d=!![];_0x2fcc1e[_0x19dbde('0x2782')](function(_0x42e11e){const _0x316521=_0x19dbde;_0x2e979d=!![],_0x58acb4['forEach'](function(_0xf4382c){String(_0x42e11e)===String(_0xf4382c)&&(_0x2e979d=![]);}),_0x2e979d&&delete _0x18b2ca[_0x316521('0x1870')][_0x42e11e];}),_0x18b2ca['properties']=_0x18b2ca[_0x19dbde('0x1870')];}if(!_0x2cfb05()['isNil'](_0x4fe1be[_0x19dbde('0x1d24')])&&_0x4fe1be[_0x19dbde('0x1d24')][_0x19dbde('0x264b')]>0x0){_0x18b2ca[_0x19dbde('0xeed')]={};const _0x46eb53=_0x4fe1be['extraData'];for(let _0x489e51=0x0;_0x489e51<_0x46eb53[_0x19dbde('0x264b')];_0x489e51++){const _0x5cf902=_0x46eb53[_0x489e51][_0x19dbde('0x1ac1')],_0x57ce97=_0x46eb53[_0x489e51][_0x19dbde('0x1404')];for(let _0x5367f9=0x0;_0x5367f9<_0x5cf902['length'];_0x5367f9++){_0x18b2ca[_0x19dbde('0xeed')][_0x5cf902[_0x5367f9]['text']]=_0x5a7aa5[_0x57ce97][_0x5cf902[_0x5367f9][_0x19dbde('0x7ca')]];}}_0x18b2ca[_0x19dbde('0x1c0c')]=Object['assign']({},_0x18b2ca[_0x19dbde('0x1870')],_0x18b2ca['propertiesExtra']);}}_0x18b2ca[_0x19dbde('0x24a0')]=_0x2c5722;function _0x2c5722(){const _0x5d2214=_0x19dbde;_0x49baa0[_0x5d2214('0x1197')]();}}const _0x790055=_0x509bab,_0x3c8522=_0x2734b2['p']+'src/js/modules/main/apps/video/views/screenRecordings/create/dialog.html/dialog.html',_0x31c8f7=_0x2734b2['p']+_0x36e6f4('0x20b0');_0x33a454['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),'$mdDialog','$document','$timeout',_0x36e6f4('0x586'),_0x36e6f4('0x16d6'),_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0x33a454(_0x4d19c7,_0x35b533,_0x353058,_0xf1844f,_0x1d6cdb,_0x25936b,_0xce9a02,_0x3db11a,_0x145300,_0x3c23d2,_0x5c1a5b,_0xa2fb2,_0x527bb3,_0x19a583,_0x4e3487,_0x4b2f36,_0x33c307){const _0x2c56e9=_0x36e6f4,_0x40d973=this;_0x40d973[_0x2c56e9('0x5c9')]=_0x4b2f36,_0x40d973[_0x2c56e9('0xf8a')]=_0x33c307,_0x40d973[_0x2c56e9('0x98')]=_0x4e3487['getCurrentUser'](),_0x40d973[_0x2c56e9('0x16d6')]=_0x145300||{'count':0x0,'rows':[]},_0x40d973[_0x2c56e9('0x7f')]=_0x3c23d2,_0x40d973[_0x2c56e9('0x17aa')]=_0x5c1a5b&&_0x5c1a5b[_0x2c56e9('0x240f')]==0x1?_0x5c1a5b[_0x2c56e9('0x269a')][0x0]:null,_0x40d973['crudPermissions']=_0x4e3487['parseCrudPermissions'](_0x40d973[_0x2c56e9('0x17aa')]?_0x40d973['userProfileSection'][_0x2c56e9('0x243c')]:null),_0x40d973['table']=_0x2c56e9('0x16d6'),_0x40d973[_0x2c56e9('0xef5')]='',_0x40d973[_0x2c56e9('0x104c')]=null,_0x40d973['selectedScreenRecordings']=[],_0x40d973['query']={'fields':_0x2c56e9('0x69f'),'createdAt':'@msUtils.firstLastDayMonth()','includeAll':_0x2c56e9('0xf3b'),'sort':_0x2c56e9('0x14dc'),'limit':0xa,'page':0x1},_0x40d973[_0x2c56e9('0x2218')][_0x2c56e9('0x262')]=_0x527bb3[_0x2c56e9('0x1024')](),_0x40d973[_0x2c56e9('0x6cb')]=_0x5b9e74();function _0x5b9e74(){const _0x134900=_0x2c56e9;return[{'name':_0x134900('0x2567'),'key':_0x134900('0x262'),'type':_0x134900('0x1643'),'label':'DASHBOARDS.SELECT_DATE_RANGE'}];}_0x40d973[_0x2c56e9('0x1c15')]=_0x108e4c,_0x40d973[_0x2c56e9('0x424')]=_0x729c7c,_0x40d973[_0x2c56e9('0x8d8')]=_0x415491,_0x40d973[_0x2c56e9('0x103b')]=_0x2fbbfe,_0x40d973['getScreenRecordings']=_0x10c2e3,_0x40d973[_0x2c56e9('0x554')]=_0xc37fa6,_0x40d973['deletescreenRecording']=_0x4c488e,_0x40d973[_0x2c56e9('0x3df')]=_0x19463a,_0x40d973[_0x2c56e9('0x28ea')]=_0x3edafd,_0x40d973[_0x2c56e9('0x28e7')]=_0x976d8b,_0x40d973[_0x2c56e9('0x73d')]=_0x4e82f4,_0x40d973['convertDuration']=_0x536daf,_0xa2fb2[_0x2c56e9('0x557')][_0x2c56e9('0xd83')]({'fields':_0x2c56e9('0xce1'),'sort':'name','nolimit':_0x2c56e9('0xf3b')})[_0x2c56e9('0xa44')][_0x2c56e9('0x1166')](function(_0x231ede){const _0x4773ff=_0x2c56e9;_0x40d973[_0x4773ff('0x21f6')]=_0x231ede[_0x4773ff('0x269a')]||[];})[_0x2c56e9('0x1a80')](function(_0x56f6f2){const _0x1f0994=_0x2c56e9;_0x19a583[_0x1f0994('0xfc9')]({'title':_0x56f6f2[_0x1f0994('0x52d')]?_0x1f0994('0x1e21')+_0x56f6f2[_0x1f0994('0x52d')]+'\x20-\x20'+_0x56f6f2[_0x1f0994('0xe1b')]:_0x1f0994('0x13e3'),'msg':_0x56f6f2['data']?JSON['stringify'](_0x56f6f2['data']):_0x56f6f2[_0x1f0994('0x1586')]()});});function _0x108e4c(_0x1f1b16,_0x352ed8,_0x353f0c,_0x24db8e,_0x532778){const _0x2bf6e8=_0x2c56e9,_0x2bd83d={'upperTitle':![],'lowerTitle':!![],'properties':!![],'propertiesIcon':'icon-video','propertiesList':['format',_0x2bf6e8('0x1d50'),_0x2bf6e8('0x12fc'),_0x2bf6e8('0x18d6'),_0x2bf6e8('0x1dc6'),'createdAt'],'extraData':[{'model':_0x2bf6e8('0x1a6f'),'values':[{'key':'name','text':_0x2bf6e8('0xea7')}]}]},_0x162bc8={};_0x162bc8[_0x2bf6e8('0x16a8')]=_0x2bf6e8('0x2845'),_0x162bc8[_0x2bf6e8('0x4f0')]=_0x2bf6e8('0x16d6'),_0x162bc8[_0x2bf6e8('0x1404')]=_0x2bf6e8('0x2845'),_0x162bc8[_0x2bf6e8('0x431')]=_0x2bf6e8('0x2845'),_0x24db8e=String(_0x24db8e);const _0xef22c2=String(_0x353f0c);console[_0x2bf6e8('0x455')](_0x2bf6e8('0x1ee8'),String(_0x353f0c)),_0x1d6cdb[_0x2bf6e8('0x1f80')]({'controller':'ScreenRecordingplayController','controllerAs':'vm','templateUrl':_0x31c8f7,'parent':angular[_0x2bf6e8('0x1194')](_0x25936b['body']),'targetEvent':_0x352ed8,'clickOutsideToClose':!![],'locals':{'recording':_0x1f1b16,'recordings':_0x40d973[_0x2bf6e8('0x16d6')][_0x2bf6e8('0x269a')],'license':_0x40d973[_0x2bf6e8('0x5c9')],'setting':null,'item':_0x162bc8,'actionOptions':_0x2bd83d,'label':_0x24db8e,'varPath':_0xef22c2,'elementTag':String(_0x532778)}});}function _0x729c7c(_0x1060a3){const _0x1936a9=_0x2c56e9;let _0xaa7ee5=![];const _0x437576=!_0x2cfb05()['isNil'](_0x1060a3[_0x1936a9('0x128a')])?_0x1060a3['format']:_0x1060a3[_0x1936a9('0x18e0')][_0x1936a9('0x192f')](_0x1060a3['value'][_0x1936a9('0x19da')]('.'));_0xaa7ee5=_0x437576==='.mp4'?!![]:![];const _0x41d271=_0x1060a3[_0x1936a9('0x18e0')]['lastIndexOf']('/')>-0x1?_0x1060a3[_0x1936a9('0x18e0')][_0x1936a9('0x192f')](_0x1060a3[_0x1936a9('0x18e0')][_0x1936a9('0x19da')]('/')+0x1):_0x1060a3[_0x1936a9('0x18e0')][_0x1936a9('0x19da')]('\x5c')>-0x1?_0x1060a3['value'][_0x1936a9('0x192f')](_0x1060a3[_0x1936a9('0x18e0')][_0x1936a9('0x19da')]('\x5c')+0x1):_0x1060a3[_0x1936a9('0x18e0')];return _0xa2fb2[_0x1936a9('0x2845')]['download']({'id':_0x1060a3['id']})[_0x1936a9('0xa44')][_0x1936a9('0x1166')](function(_0x11daa3){const _0x65939b=_0x1936a9,_0x56dd4d=[_0x11daa3[_0x65939b('0x20ed')]];let _0x255134=_0x65939b('0x2ad');const _0x52d7d9=new Blob(_0x56dd4d,{'type':_0x11daa3[_0x65939b('0x1345')]});_0x255134=_0x41d271;const _0x1d0082=window[_0x65939b('0x136d')]['createElement']('a');_0x1d0082[_0x65939b('0xffd')]('href',URL[_0x65939b('0x215a')](_0x52d7d9)),_0x1d0082[_0x65939b('0xffd')](_0x65939b('0x2ad'),_0x255134),document['body'][_0x65939b('0x21a')](_0x1d0082),_0x1d0082[_0x65939b('0x3b4')]();})[_0x1936a9('0x1a80')](function(_0x2770de){const _0xded75=_0x1936a9;if(_0x2770de['data']&&_0x2770de[_0xded75('0x25f4')][_0xded75('0x61a')]&&_0x2770de['data'][_0xded75('0x61a')][_0xded75('0x264b')])for(let _0x572cbb=0x0;_0x572cbb<_0x2770de[_0xded75('0x25f4')][_0xded75('0x61a')]['length'];_0x572cbb++){_0x19a583['error']({'title':_0x2770de['data'][_0xded75('0x61a')][_0x572cbb][_0xded75('0x1345')],'msg':_0x2770de[_0xded75('0x25f4')][_0xded75('0x61a')][_0x572cbb]['message']});}else{if(String(_0x2770de[_0xded75('0x52d')])===_0xded75('0x24e7')&&_0xaa7ee5===![])_0x19a583['info']({'title':_0x3db11a[_0xded75('0x25cc')](_0xded75('0x16da')),'msg':_0x3db11a['instant'](_0xded75('0x24df'))});else String(_0x2770de[_0xded75('0x52d')])===_0xded75('0x24e7')?_0x19a583[_0xded75('0x1fa1')]({'title':_0x3db11a[_0xded75('0x25cc')]('VIDEO.CANT_DOWNLOAD_THIS_FILE'),'msg':_0x3db11a[_0xded75('0x25cc')]('VIDEO.FILE_NOT_FOUND')}):_0x19a583[_0xded75('0xfc9')]({'title':_0x2770de[_0xded75('0x52d')]?_0xded75('0x1e21')+_0x2770de[_0xded75('0x52d')]+_0xded75('0x11e1')+_0x2770de[_0xded75('0xe1b')]:_0xded75('0x953'),'msg':_0x2770de[_0xded75('0x25f4')]?JSON['stringify'](_0x2770de[_0xded75('0x25f4')][_0xded75('0x1e70')]):_0x2770de[_0xded75('0x1586')]()});}});}function _0x415491(_0x24e10b,_0x5f1a42){const _0x4f8982=_0x2c56e9,_0x262939=_0x1d6cdb[_0x4f8982('0x1d26')]()[_0x4f8982('0xcdc')](_0x4f8982('0x288d')+_0x2cfb05()[_0x4f8982('0xb35')](_0x4f8982('0x2845'))+'?')['htmlContent'](_0x4f8982('0x12b5')+(_0x24e10b['name']||_0x4f8982('0x2845'))+_0x4f8982('0xace')+_0x4f8982('0x3f3'))['ariaLabel'](_0x4f8982('0x13e8'))[_0x4f8982('0x203b')](_0x5f1a42)['ok']('OK')['cancel'](_0x4f8982('0x2d3'));_0x1d6cdb['show'](_0x262939)[_0x4f8982('0x1166')](function(){_0x4c488e(_0x24e10b);},function(){const _0x374eca=_0x4f8982;console[_0x374eca('0x455')](_0x374eca('0x2d3'));});}let _0x1c530c=!![],_0x3208b8=0x1;_0x4d19c7[_0x2c56e9('0xe83')]('vm.query.filter',function(_0x522190,_0xefec1b){const _0x484495=_0x2c56e9;_0x1c530c?_0xce9a02(function(){_0x1c530c=![];}):(!_0xefec1b&&(_0x3208b8=_0x40d973[_0x484495('0x2218')][_0x484495('0x1a43')]),_0x522190!==_0xefec1b&&(_0x40d973[_0x484495('0x2218')]['page']=0x1),!_0x522190&&(_0x40d973[_0x484495('0x2218')][_0x484495('0x1a43')]=_0x3208b8),_0x40d973['getScreenRecordings']());});function _0x536daf(_0x572fc7){const _0x11128b=_0x2c56e9,_0x41c971=Math['floor'](_0x572fc7/0x3e8%0x3c),_0x28f025=Math[_0x11128b('0x813')](_0x572fc7/(0x3e8*0x3c)%0x3c),_0x201f0=Math[_0x11128b('0x813')](_0x572fc7/(0x3e8*0x3c*0x3c)%0x18),_0x1376e8=_0x201f0<0xa?'0'+String(_0x201f0):String(_0x201f0),_0x2f3568=_0x28f025<0xa?'0'+String(_0x28f025):String(_0x28f025),_0x5d263b=_0x41c971<0xa?'0'+String(_0x41c971):String(_0x41c971);return _0x1376e8+':'+_0x2f3568+':'+_0x5d263b;}function _0x2fbbfe(_0x3335ff){const _0x29b03a=_0x2c56e9;_0x40d973[_0x29b03a('0x16d6')]=_0x3335ff||{'count':0x0,'rows':[]};}function _0x10c2e3(){const _0x5e6c90=_0x2c56e9;_0x40d973['query']['offset']=(_0x40d973[_0x5e6c90('0x2218')][_0x5e6c90('0x1a43')]-0x1)*_0x40d973[_0x5e6c90('0x2218')]['limit'],_0x4e3487[_0x5e6c90('0x1ac6')](_0x5e6c90('0xa7c'))?_0x40d973['promise']=_0xa2fb2[_0x5e6c90('0x2845')][_0x5e6c90('0xd83')](_0x40d973[_0x5e6c90('0x2218')],_0x2fbbfe)[_0x5e6c90('0xa44')]:(_0x40d973[_0x5e6c90('0x2218')]['id']=_0x40d973[_0x5e6c90('0x7f')]['id'],_0x40d973[_0x5e6c90('0x2218')][_0x5e6c90('0xe60')]=_0x5e6c90('0x286d'),_0x40d973[_0x5e6c90('0x1f48')]=_0xa2fb2['userProfile'][_0x5e6c90('0x263a')](_0x40d973['query'],_0x2fbbfe)[_0x5e6c90('0xa44')]);}function _0xc37fa6(_0x483c54,_0x5943be){const _0x449dae=_0x2c56e9;_0x1d6cdb[_0x449dae('0x1f80')]({'controller':_0x449dae('0x25eb'),'controllerAs':'vm','templateUrl':_0x3c8522,'parent':angular[_0x449dae('0x1194')](_0x25936b[_0x449dae('0x8d2')]),'targetEvent':_0x483c54,'clickOutsideToClose':!![],'locals':{'screenRecording':_0x5943be,'screenRecordings':_0x40d973[_0x449dae('0x16d6')][_0x449dae('0x269a')],'license':_0x40d973[_0x449dae('0x5c9')],'setting':_0x40d973[_0x449dae('0xf8a')],'crudPermissions':_0x40d973[_0x449dae('0x243c')]}});}function _0x4c488e(_0x2a2c11){const _0x593ef4=_0x2c56e9;_0xa2fb2['screenRecording'][_0x593ef4('0x906')]({'id':_0x2a2c11['id']})[_0x593ef4('0xa44')]['then'](function(){const _0x320b07=_0x593ef4;_0x2cfb05()[_0x320b07('0x127f')](_0x40d973[_0x320b07('0x16d6')][_0x320b07('0x269a')],{'id':_0x2a2c11['id']}),_0x40d973[_0x320b07('0x16d6')][_0x320b07('0x240f')]-=0x1,!_0x40d973['screenRecordings'][_0x320b07('0x269a')][_0x320b07('0x264b')]&&_0x40d973['getScreenRecordings'](),_0x19a583[_0x320b07('0x103b')]({'title':_0x2cfb05()[_0x320b07('0xb35')](_0x320b07('0x2845'))+'\x20deleted!','msg':_0x2a2c11['name']?_0x2a2c11['name']+'\x20has\x20been\x20deleted!':''});})[_0x593ef4('0x1a80')](function(_0x179c03){const _0x442946=_0x593ef4;if(_0x179c03[_0x442946('0x25f4')]&&_0x179c03[_0x442946('0x25f4')][_0x442946('0x61a')]&&_0x179c03['data'][_0x442946('0x61a')]['length']){_0x40d973[_0x442946('0x61a')]=_0x179c03[_0x442946('0x25f4')][_0x442946('0x61a')]||[{'message':_0x179c03[_0x442946('0x1586')](),'type':_0x442946('0x1279')}];for(let _0x14b066=0x0;_0x14b066<_0x179c03[_0x442946('0x25f4')][_0x442946('0x61a')][_0x442946('0x264b')];_0x14b066++){_0x19a583[_0x442946('0xfc9')]({'title':_0x179c03['data'][_0x442946('0x61a')][_0x14b066][_0x442946('0x1345')],'msg':_0x179c03[_0x442946('0x25f4')]['errors'][_0x14b066]['message']});}}else _0x19a583['error']({'title':_0x179c03[_0x442946('0x52d')]?_0x442946('0x1e21')+_0x179c03[_0x442946('0x52d')]+_0x442946('0x11e1')+_0x179c03[_0x442946('0xe1b')]:_0x442946('0x1279'),'msg':_0x179c03[_0x442946('0x25f4')]?JSON[_0x442946('0xbac')](_0x179c03[_0x442946('0x25f4')][_0x442946('0x1e70')]):_0x179c03[_0x442946('0x1e70')]||_0x179c03[_0x442946('0x1586')]()});});}function _0x19463a(){const _0x1bbd6d=_0x2c56e9,_0x5a284b=angular[_0x1bbd6d('0x225f')](_0x40d973[_0x1bbd6d('0xc9')]);return _0x40d973['selectedScreenRecordings']=[],_0x5a284b;}function _0x3edafd(_0x24815f){const _0x20c2fc=_0x2c56e9,_0x1737be=_0x1d6cdb[_0x20c2fc('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20screenRecordings?')[_0x20c2fc('0xf3c')](''+_0x40d973[_0x20c2fc('0xc9')]['length']+_0x20c2fc('0x196d')+_0x20c2fc('0x3f3'))[_0x20c2fc('0x8e8')](_0x20c2fc('0xa3a'))[_0x20c2fc('0x203b')](_0x24815f)['ok']('OK')['cancel'](_0x20c2fc('0x2d3'));_0x1d6cdb[_0x20c2fc('0x1f80')](_0x1737be)[_0x20c2fc('0x1166')](function(){const _0x8f38d2=_0x20c2fc;_0x40d973[_0x8f38d2('0xc9')]['forEach'](function(_0x32cd28){_0x4c488e(_0x32cd28);}),_0x40d973[_0x8f38d2('0xc9')]=[];});}function _0x976d8b(){const _0x325794=_0x2c56e9;_0x40d973[_0x325794('0xc9')]=[];}function _0x4e82f4(){const _0x4fb1ea=_0x2c56e9;_0x40d973[_0x4fb1ea('0xc9')]=_0x40d973[_0x4fb1ea('0x16d6')][_0x4fb1ea('0x269a')];}}const _0x4a46fb=_0x33a454;_0x155559[_0x36e6f4('0x1294')]=['$stateProvider',_0x36e6f4('0x1562')];function _0x155559(_0x292a79,_0x2c6ea4){const _0x4e0a94=_0x36e6f4;_0x292a79[_0x4e0a94('0x63f')](_0x4e0a94('0x443'),{'abstract':!![],'url':_0x4e0a94('0x16b1')})[_0x4e0a94('0x63f')](_0x4e0a94('0xdcb'),{'url':_0x4e0a94('0xde8'),'views':{'content@app':{'templateUrl':_0x179e01,'controller':_0x4e0a94('0x28a8')}},'resolve':{'screenRecordings':[_0x4e0a94('0x1fbc'),_0x4e0a94('0x21ef'),'msUtils',function(_0x23002d,_0x55c70b,_0x2ae838){const _0x399f4a=_0x4e0a94;return _0x55c70b[_0x399f4a('0x1ac6')]('admin')?_0x23002d[_0x399f4a('0x18af')](_0x399f4a('0x22d'),{'fields':_0x399f4a('0x69f'),'createdAt':_0x2ae838[_0x399f4a('0x1024')](),'includeAll':_0x399f4a('0xf3b'),'sort':_0x399f4a('0x14dc'),'limit':0xa,'offset':0x0}):_0x23002d[_0x399f4a('0x18af')](_0x399f4a('0x17c4'),{'id':_0x55c70b[_0x399f4a('0x26cd')]()[_0x399f4a('0xb86')],'section':_0x399f4a('0x286d'),'fields':_0x399f4a('0x69f'),'createdAt':_0x2ae838['firstLastDayMonth'](),'includeAll':'true','sort':_0x399f4a('0x14dc'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x4e0a94('0x1fbc'),_0x4e0a94('0x21ef'),function(_0xcd7728,_0x383cf2){const _0x1f0400=_0x4e0a94;return _0x383cf2['hasRole'](_0x1f0400('0xa7c'))?null:_0xcd7728[_0x1f0400('0x18af')](_0x1f0400('0x697'),{'fields':_0x1f0400('0x686'),'id':_0x383cf2[_0x1f0400('0x26cd')]()['userProfileId']});}],'userProfileSection':[_0x4e0a94('0x1fbc'),_0x4e0a94('0x21ef'),function(_0x27aee1,_0x3536ed){const _0x1bb00c=_0x4e0a94;return _0x3536ed[_0x1bb00c('0x1ac6')](_0x1bb00c('0xa7c'))?null:_0x27aee1['resolve'](_0x1bb00c('0xaf'),{'fields':_0x1bb00c('0xe26'),'userProfileId':_0x3536ed['getCurrentUser']()[_0x1bb00c('0xb86')],'sectionId':0x7d1});}]},'authenticate':!![],'permissionId':0x7d1,'bodyClass':'video'}),_0x2c6ea4[_0x4e0a94('0x95e')](_0x4e0a94('0x28c5'));}angular['module'](_0x36e6f4('0x443'),[_0x36e6f4('0x441'),_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),'flow',_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),'ng-sortable','ngAria',_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),_0x36e6f4('0x19bc'),'angular-cron-jobs',_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),_0x36e6f4('0x1b41'),_0x36e6f4('0x1fd1'),_0x36e6f4('0x411')])['config'](_0x155559)[_0x36e6f4('0x75e')](_0x36e6f4('0x25eb'),_0x3ab4ad)[_0x36e6f4('0x75e')](_0x36e6f4('0xed0'),_0x790055)['controller'](_0x36e6f4('0x10e5'),_0x4a46fb);const _0xe7fffa=_0x2734b2['p']+_0x36e6f4('0x43c'),_0x4a5787=_0x2734b2['p']+_0x36e6f4('0x1468'),_0xcea762=_0x2734b2['p']+'src/js/modules/main/apps/whatsapp/views/realtime/queues/view.html/view.html';_0x5853d0[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$q',_0x36e6f4('0x8da'),'$mdDialog',_0x36e6f4('0x1c90'),'$filter','pauses','agents',_0x36e6f4('0x24b7'),_0x36e6f4('0x19e3'),'socket',_0x36e6f4('0x1d2e'),'helperClasses',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0x10eb')];function _0x5853d0(_0x50e31f,_0x36c10d,_0x4202e1,_0x1882c1,_0x3cbd96,_0x1e89a9,_0x9a0f29,_0x4c3bb6,_0x5411a4,_0x118365,_0xbdf493,_0x5650fb,_0x322c44,_0x108745,_0x590244,_0x3bd7c1,_0x3c9707,_0x5778a6){const _0x47ccb3=_0x36e6f4,_0x20266c=this,_0x43b2e9=['userpic',_0x47ccb3('0xb41'),_0x47ccb3('0x2318'),_0x47ccb3('0x3dc'),_0x47ccb3('0x246c'),_0x47ccb3('0x3dc'),_0x47ccb3('0x1eef'),_0x47ccb3('0x16a6'),_0x47ccb3('0x1c5c'),_0x47ccb3('0x287f'),_0x47ccb3('0xb4'),_0x47ccb3('0x178d'),_0x47ccb3('0x11ee'),'faxPause','voicePause','chatCapacity',_0x47ccb3('0x1b39'),_0x47ccb3('0x18ae'),'smsCapacity','whatsappCapacity',_0x47ccb3('0x1462'),_0x47ccb3('0x1107'),_0x47ccb3('0x8cf'),_0x47ccb3('0x82d'),_0x47ccb3('0x1da1'),'whatsappCurrentCapacity',_0x47ccb3('0x1ee6'),'chatStatus',_0x47ccb3('0x1f33'),'mailStatus',_0x47ccb3('0x1c1a'),_0x47ccb3('0x1a5d'),_0x47ccb3('0x276d'),_0x47ccb3('0x17e1'),_0x47ccb3('0x1507'),_0x47ccb3('0x43e'),_0x47ccb3('0x1955'),_0x47ccb3('0x2357'),_0x47ccb3('0x11a8'),_0x47ccb3('0x4f3'),_0x47ccb3('0x18c9'),_0x47ccb3('0x1d3e'),_0x47ccb3('0x1ad2'),_0x47ccb3('0x158'),_0x47ccb3('0x2167'),'phoneBarEnableAutomaticScreenRecording'],_0x5a37a3=[_0x47ccb3('0x1c5c'),'openchannelPause',_0x47ccb3('0xb4'),_0x47ccb3('0x178d'),_0x47ccb3('0x11ee'),_0x47ccb3('0x5aa'),_0x47ccb3('0x2540'),_0x47ccb3('0xb41')];_0x20266c['currentUser']=_0x3bd7c1[_0x47ccb3('0x26cd')](),_0x20266c['availableStates']=[_0x47ccb3('0x1628'),_0x47ccb3('0x133e'),_0x47ccb3('0x2344'),_0x47ccb3('0x158e'),_0x47ccb3('0x521')],_0x20266c[_0x47ccb3('0xe29')]=_0x9a0f29||{'count':0x0,'rows':[]},_0x20266c[_0x47ccb3('0x5c9')]=_0x3c9707,_0x20266c[_0x47ccb3('0x7f')]=_0x108745,_0x20266c[_0x47ccb3('0x17aa')]=_0x590244&&_0x590244[_0x47ccb3('0x240f')]==0x1?_0x590244[_0x47ccb3('0x269a')][0x0]:null,_0x20266c[_0x47ccb3('0x243c')]=_0x3bd7c1[_0x47ccb3('0xd87')](_0x20266c[_0x47ccb3('0x17aa')]?_0x20266c['userProfileSection']['crudPermissions']:null),_0x20266c[_0x47ccb3('0x1f7e')]=_0x4c3bb6?_0x2cfb05()['keyBy'](_0x4c3bb6[_0x47ccb3('0x269a')]?_0x4c3bb6[_0x47ccb3('0x269a')]:[],'id'):{},_0x20266c['rpcAgents']=_0x5411a4?_0x2cfb05()[_0x47ccb3('0x155c')](_0x5411a4[_0x47ccb3('0x269a')]?_0x5411a4[_0x47ccb3('0x269a')]:[],'id'):{},_0x20266c[_0x47ccb3('0x5e5')]={},_0x20266c[_0x47ccb3('0x173f')]=![],_0x20266c[_0x47ccb3('0xa99')]=[],_0x20266c[_0x47ccb3('0x4c4')]={};for(const _0x5231b2 in _0x20266c[_0x47ccb3('0x1f7e')]){typeof _0x20266c[_0x47ccb3('0x1f7e')][_0x5231b2]!==_0x47ccb3('0x1048')&&(_0x20266c[_0x47ccb3('0x1f7e')][_0x5231b2]['init']=!![]);}_0x20266c[_0x47ccb3('0x2218')]={'limit':0xa,'page':0x1,'order':_0x47ccb3('0x6e1'),'globalStatusFilter':'','pauseTypeFilter':''},_0x20266c[_0x47ccb3('0x885')]=_0x52adb7,_0x20266c[_0x47ccb3('0xaf7')]=_0xeb949d,_0x20266c[_0x47ccb3('0x1e77')]=_0x4110de,_0x20266c['unPause']=_0x3bf78e,_0x20266c[_0x47ccb3('0x6df')]=_0x46749e,_0x20266c[_0x47ccb3('0x72f')]=_0x4ce13f,_0x20266c[_0x47ccb3('0x28b5')]=_0x346a30,_0x20266c['isPause']=_0xf51fe,_0x20266c['checkPause']=_0x34f5d3,_0x20266c['isPartialPause']=_0x560661,_0x20266c[_0x47ccb3('0x1303')]=_0x2c8da7,_0x20266c[_0x47ccb3('0x2232')]=_0x437e78,_0x20266c[_0x47ccb3('0xae0')]=_0x25718f,_0x20266c[_0x47ccb3('0x223a')]=_0x236b92,_0x20266c['onComplete']=_0x291ab1,_0x20266c[_0x47ccb3('0x2845')]=_0x365146,_0xbdf493['on']('user:save',_0x20266c[_0x47ccb3('0x1303')]),_0xbdf493['on'](_0x47ccb3('0x19d5'),_0x20266c[_0x47ccb3('0x2232')]),_0xbdf493['on'](_0x47ccb3('0x10fc'),_0x20266c[_0x47ccb3('0x223a')]),_0xbdf493['on']('user:agentcomplete',_0x20266c[_0x47ccb3('0x1923')]),_0x25718f();let _0x2ac53a=_0x5778a6(function(){const _0x3211b0=_0x47ccb3;_0x20266c[_0x3211b0('0x173f')]&&(_0x20266c['load']=![],_0x25718f());},0x3e7);function _0x25718f(){const _0x184b09=_0x47ccb3;_0x20266c[_0x184b09('0x173f')]=![];const _0x108325=_0x36c10d[_0x184b09('0x24d8')]();_0x20266c[_0x184b09('0x1f48')]=_0x108325[_0x184b09('0x1f48')],_0x20266c[_0x184b09('0x220b')]=[],_0x20266c[_0x184b09('0xa99')]=[],_0x2cfb05()[_0x184b09('0x941')](_0x20266c[_0x184b09('0x1f7e')],function(_0x278ef9,_0x103b76){const _0x58b8e3=_0x184b09;_0x20266c[_0x58b8e3('0x24b7')][_0x103b76]&&_0x2cfb05()[_0x58b8e3('0xcc3')](_0x278ef9,_0x2cfb05()[_0x58b8e3('0x1a08')](_0x2cfb05()[_0x58b8e3('0x1414')](_0x20266c[_0x58b8e3('0x24b7')][_0x103b76],_0x5a37a3),_0x43b2e9)),_0x346a30(_0x278ef9),_0x278ef9[_0x58b8e3('0xb41')]?(_0x20266c[_0x58b8e3('0x220b')][_0x58b8e3('0x1514')](_0x278ef9),_0x20266c[_0x58b8e3('0x4c4')][_0x278ef9[_0x58b8e3('0x1eef')]]=_0x103b76):_0x278ef9[_0x58b8e3('0x25b3')]=_0x2cfb05()[_0x58b8e3('0xa53')](_0x24273b()()[_0x58b8e3('0x128a')]('x'));});_0x20266c[_0x184b09('0x2218')]['globalStatusFilter']&&_0x2cfb05()[_0x184b09('0x127f')](_0x20266c[_0x184b09('0x220b')],function(_0x2734f6){const _0x3cebf3=_0x184b09;return _0x2734f6[_0x3cebf3('0xe34')]!==_0x20266c[_0x3cebf3('0x2218')][_0x3cebf3('0xf4')];});_0x20266c[_0x184b09('0x2218')][_0x184b09('0x2121')]&&_0x2cfb05()[_0x184b09('0x127f')](_0x20266c['filteredAgents'],function(_0x596bc5){const _0xe509c4=_0x184b09;return _0x596bc5[_0xe509c4('0x246c')]!==_0x20266c[_0xe509c4('0x2218')]['pauseTypeFilter'];});_0x20266c[_0x184b09('0x2218')][_0x184b09('0x1c33')]&&_0x2cfb05()['remove'](_0x20266c[_0x184b09('0x220b')],function(_0x2d9d3e){const _0x440f40=_0x184b09;return _0x2d9d3e['fullname']['toLowerCase']()[_0x440f40('0x2379')](_0x20266c[_0x440f40('0x2218')][_0x440f40('0x1c33')][_0x440f40('0x2574')]())<0x0;});_0x20266c[_0x184b09('0x220b')]=_0x535bd4(_0x20266c['filteredAgents']);const _0xf7a2df=(_0x20266c[_0x184b09('0x2218')]['page']-0x1)*_0x20266c['query'][_0x184b09('0x163f')];_0x20266c[_0x184b09('0x5e5')]=_0x2cfb05()['drop'](_0x20266c[_0x184b09('0x220b')],_0xf7a2df)[_0x184b09('0x233')](0x0,_0x20266c[_0x184b09('0x2218')]['limit']);for(let _0x128801=0x0;_0x128801<_0x20266c[_0x184b09('0x5e5')][_0x184b09('0x264b')];_0x128801+=0x1){_0x20266c['order']['push'](_0x20266c[_0x184b09('0x5e5')][_0x128801]['id']);}_0x108325[_0x184b09('0x18af')](),_0x20266c[_0x184b09('0x173f')]=!![];}function _0x2c8da7(_0x23490c){const _0xd7cbdc=_0x47ccb3;_0x20266c[_0xd7cbdc('0x1f7e')][_0x23490c['id']]&&(_0x2cfb05()[_0xd7cbdc('0xcc3')](_0x20266c[_0xd7cbdc('0x1f7e')][_0x23490c['id']],_0x2cfb05()['pick'](_0x2cfb05()['omit'](_0x23490c,_0x5a37a3),_0x43b2e9)),_0x2cfb05()[_0xd7cbdc('0xcc3')](_0x20266c[_0xd7cbdc('0x24b7')][_0x23490c['id']],_0x2cfb05()[_0xd7cbdc('0x1a08')](_0x2cfb05()[_0xd7cbdc('0x1414')](_0x23490c,_0x5a37a3),_0x43b2e9)),_0x346a30(_0x20266c['agents'][_0x23490c['id']]));}function _0x437e78(_0x36491e){const _0x58b77f=_0x47ccb3;_0x20266c[_0x58b77f('0x1f7e')][_0x36491e['id']]&&(_0x2cfb05()[_0x58b77f('0xcc3')](_0x20266c[_0x58b77f('0x1f7e')][_0x36491e['id']],_0x2cfb05()[_0x58b77f('0x1a08')](_0x36491e,_0x43b2e9)),_0x2cfb05()[_0x58b77f('0xcc3')](_0x20266c[_0x58b77f('0x24b7')][_0x36491e['id']],_0x2cfb05()[_0x58b77f('0x1a08')](_0x36491e,_0x43b2e9)),_0x36491e[_0x58b77f('0x3dc')]&&(_0x20266c[_0x58b77f('0x1f7e')][_0x36491e['id']][_0x58b77f('0x25b3')]=_0x36491e[_0x58b77f('0x3dc')],_0x20266c[_0x58b77f('0x24b7')][_0x36491e['id']][_0x58b77f('0x25b3')]=_0x36491e[_0x58b77f('0x3dc')]),_0x346a30(_0x20266c[_0x58b77f('0x1f7e')][_0x36491e['id']]));}function _0x236b92(_0x2798f5){const _0x27a660=_0x47ccb3;_0x20266c[_0x27a660('0x1f7e')][_0x20266c[_0x27a660('0x4c4')][_0x2798f5[_0x27a660('0x25fc')]]]&&(_0x2cfb05()[_0x27a660('0xcc3')](_0x20266c[_0x27a660('0x1f7e')][_0x20266c[_0x27a660('0x4c4')][_0x2798f5['destaccountcode']]],_0x2cfb05()[_0x27a660('0x1a08')](_0x2798f5,[_0x27a660('0x1d3e'),_0x27a660('0x1ad2')])),_0x2cfb05()[_0x27a660('0xcc3')](_0x20266c[_0x27a660('0x24b7')][_0x20266c['agentInternal'][_0x2798f5[_0x27a660('0x25fc')]]],_0x2cfb05()[_0x27a660('0x1a08')](_0x2798f5,[_0x27a660('0x1d3e'),_0x27a660('0x1ad2')])));}function _0x291ab1(_0x285177){const _0x2d8640=_0x47ccb3;_0x20266c[_0x2d8640('0x1f7e')][_0x20266c['agentInternal'][_0x285177[_0x2d8640('0x25fc')]]]&&(_0x20266c[_0x2d8640('0x1f7e')][_0x20266c[_0x2d8640('0x4c4')][_0x285177['destaccountcode']]]=_0x2cfb05()['omit'](_0x20266c[_0x2d8640('0x1f7e')][_0x20266c[_0x2d8640('0x4c4')][_0x285177[_0x2d8640('0x25fc')]]],[_0x2d8640('0x1d3e'),_0x2d8640('0x1ad2')]),_0x20266c[_0x2d8640('0x24b7')][_0x20266c[_0x2d8640('0x4c4')][_0x285177[_0x2d8640('0x25fc')]]]=_0x2cfb05()[_0x2d8640('0x1414')](_0x20266c['rpcAgents'][_0x20266c[_0x2d8640('0x4c4')][_0x285177[_0x2d8640('0x25fc')]]],['queue',_0x2d8640('0x1ad2')]));}function _0x52adb7(_0x21a92d){const _0x137586=_0x47ccb3;return _0x118365[_0x137586('0x557')]['logout']({'id':_0x21a92d['id'],'device':'realtime','agent_id':_0x21a92d['id'],'agent_name':_0x21a92d['name']})[_0x137586('0xa44')]['then'](function(){const _0x547e74=_0x137586;_0x5650fb[_0x547e74('0x103b')]({'title':_0x547e74('0x16a7'),'msg':_0x21a92d[_0x547e74('0x6e1')]+'\x20\x20properly\x20logout'}),_0x20266c[_0x547e74('0x1f7e')][_0x21a92d['id']]&&(_0x20266c[_0x547e74('0x1f7e')][_0x21a92d['id']][_0x547e74('0xb41')]=![]),_0x20266c[_0x547e74('0x24b7')][_0x21a92d['id']]&&(_0x20266c['rpcAgents'][_0x21a92d['id']]['online']=![]),_0x25718f();})['catch'](function(_0xb7f684){const _0x3b7c2b=_0x137586;_0x5650fb[_0x3b7c2b('0xfc9')]({'title':_0xb7f684['status']?_0x3b7c2b('0x1e21')+_0xb7f684[_0x3b7c2b('0x52d')]+_0x3b7c2b('0x11e1')+_0xb7f684[_0x3b7c2b('0xe1b')]:_0x3b7c2b('0x1e3c'),'msg':_0xb7f684[_0x3b7c2b('0x25f4')]?JSON['stringify'](_0xb7f684[_0x3b7c2b('0x25f4')][_0x3b7c2b('0x1e70')]):_0xb7f684[_0x3b7c2b('0x1586')]()});});}function _0x4110de(_0x3034d5,_0x20097b){const _0x10fe2b=_0x47ccb3;return _0x118365[_0x10fe2b('0x557')][_0x10fe2b('0x1e77')]({'id':_0x3034d5['id'],'type':_0x20097b})[_0x10fe2b('0xa44')][_0x10fe2b('0x1166')](function(_0x571af7){const _0x247073=_0x10fe2b;_0x20266c['agents'][_0x3034d5['id']]&&_0x2cfb05()[_0x247073('0xcc3')](_0x20266c[_0x247073('0x1f7e')][_0x3034d5['id']],_0x2cfb05()['pick'](_0x571af7,_0x43b2e9)),_0x20266c[_0x247073('0x24b7')][_0x3034d5['id']]&&_0x2cfb05()[_0x247073('0xcc3')](_0x20266c[_0x247073('0x24b7')][_0x3034d5['id']],_0x2cfb05()[_0x247073('0x1a08')](_0x571af7,_0x43b2e9)),_0x346a30(_0x20266c[_0x247073('0x1f7e')][_0x3034d5['id']]);})[_0x10fe2b('0x1a80')](function(_0x5afba2){const _0x3c410c=_0x10fe2b;_0x5650fb[_0x3c410c('0xfc9')]({'title':_0x5afba2['status']?'API:'+_0x5afba2[_0x3c410c('0x52d')]+_0x3c410c('0x11e1')+_0x5afba2[_0x3c410c('0xe1b')]:_0x3c410c('0x1e3c'),'msg':_0x5afba2[_0x3c410c('0x25f4')]?JSON[_0x3c410c('0xbac')](_0x5afba2[_0x3c410c('0x25f4')]['message']):_0x5afba2['toString']()});});}function _0x3bf78e(_0x4744a0){const _0x382d29=_0x47ccb3;return _0x118365[_0x382d29('0x557')][_0x382d29('0x20eb')]({'id':_0x4744a0['id']})[_0x382d29('0xa44')][_0x382d29('0x1166')](function(_0xe32c78){const _0x449330=_0x382d29;_0x20266c[_0x449330('0x1f7e')][_0x4744a0['id']]&&_0x2cfb05()[_0x449330('0xcc3')](_0x20266c['agents'][_0x4744a0['id']],_0x2cfb05()[_0x449330('0x1a08')](_0xe32c78,_0x43b2e9)),_0x20266c[_0x449330('0x24b7')][_0x4744a0['id']]&&_0x2cfb05()[_0x449330('0xcc3')](_0x20266c[_0x449330('0x24b7')][_0x4744a0['id']],_0x2cfb05()[_0x449330('0x1a08')](_0xe32c78,_0x43b2e9)),_0x346a30(_0x20266c['agents'][_0x4744a0['id']]);})[_0x382d29('0x1a80')](function(_0x3b35fe){const _0x31874c=_0x382d29;_0x5650fb[_0x31874c('0xfc9')]({'title':_0x3b35fe['status']?_0x31874c('0x1e21')+_0x3b35fe['status']+_0x31874c('0x11e1')+_0x3b35fe[_0x31874c('0xe1b')]:_0x31874c('0x1e3c'),'msg':_0x3b35fe[_0x31874c('0x25f4')]?JSON[_0x31874c('0xbac')](_0x3b35fe['data'][_0x31874c('0x1e70')]):_0x3b35fe[_0x31874c('0x1586')]()});});}function _0x46749e(_0x1ce242){const _0x58a76f=_0x47ccb3;_0x1882c1[_0x58a76f('0x1f80')](_0x1882c1[_0x58a76f('0x31d')]()[_0x58a76f('0x2339')](!![])[_0x58a76f('0xcdc')](_0x58a76f('0x58a'))['htmlContent']('
TODO\x20legend\x20status\x20+\x20state
')['ok']('Ok')[_0x58a76f('0x203b')](_0x1ce242));}function _0xeb949d(_0x4ac351,_0x30ec11){const _0xca0a0f=_0x47ccb3;_0x1882c1[_0xca0a0f('0x1f80')]({'controller':_0xca0a0f('0xf19'),'controllerAs':'vm','templateUrl':_0x49c5be,'parent':angular[_0xca0a0f('0x1194')](_0x3cbd96[_0xca0a0f('0x8d2')]),'targetEvent':_0x30ec11,'clickOutsideToClose':!![],'locals':{'agent':_0x4ac351,'agents':[],'channel':'whatsapp','direction':'inbound','crudPermissions':_0x20266c['crudPermissions']}});}function _0xf51fe(_0x59c4fa){const _0x5db2a5=_0x47ccb3;return _0x59c4fa===_0x5db2a5('0x1e77')||_0x59c4fa===_0x5db2a5('0x6e8');}function _0x34f5d3(_0x1cc03b){return _0x1cc03b==='pause';}function _0x560661(_0x4703ad){return _0x4703ad==='*pause';}function _0x4643e4(_0x4f3d6a){const _0x48bba4=_0x47ccb3;return _0x4f3d6a===_0x48bba4('0xdb0')||_0x4f3d6a==='unknown'||_0x4f3d6a===_0x48bba4('0x14dd')||_0x4f3d6a===_0x48bba4('0x1628')||_0x2cfb05()['isNil'](_0x4f3d6a);}function _0x4ce13f(_0x40c1f9,_0x1a515e){const _0x17d5d8=_0x47ccb3;if(_0x1a515e===_0x17d5d8('0x21da')){if(_0x40c1f9[_0x1a515e+'Status']!==_0x17d5d8('0xdb0'))return _0x40c1f9[_0x1a515e+'Status'];if(_0x40c1f9[_0x1a515e+'Pause'])return _0x40c1f9[_0x1a515e+_0x17d5d8('0x28f6')]='pause',_0x17d5d8('0x1e77');return _0x17d5d8('0xdb0');}else{if(_0x40c1f9[_0x1a515e+_0x17d5d8('0x108')])return _0x40c1f9[_0x1a515e+_0x17d5d8('0x28f6')]=_0x17d5d8('0x1e77'),'pause';return _0x40c1f9[_0x1a515e+'Status'];}}function _0x346a30(_0x32cb80){const _0x450c2d=_0x47ccb3;let _0x151121='unknown';if(_0x2cfb05()['every']([_0x4ce13f(_0x32cb80,_0x450c2d('0x21da')),_0x4ce13f(_0x32cb80,_0x450c2d('0xde2')),_0x4ce13f(_0x32cb80,_0x450c2d('0x1bfa')),_0x4ce13f(_0x32cb80,'openchannel'),_0x4ce13f(_0x32cb80,'sms'),_0x4ce13f(_0x32cb80,_0x450c2d('0x116e')),_0x4ce13f(_0x32cb80,'fax')],_0xf51fe))_0x151121=_0x450c2d('0x1e77');else{if(_0x2cfb05()[_0x450c2d('0x1798')]([_0x4ce13f(_0x32cb80,_0x450c2d('0x21da')),_0x4ce13f(_0x32cb80,_0x450c2d('0xde2')),_0x4ce13f(_0x32cb80,_0x450c2d('0x1bfa')),_0x4ce13f(_0x32cb80,_0x450c2d('0x26c')),_0x4ce13f(_0x32cb80,'sms'),_0x4ce13f(_0x32cb80,_0x450c2d('0x116e')),_0x4ce13f(_0x32cb80,'fax')],_0xf51fe))_0x151121='*pause';else _0x2cfb05()[_0x450c2d('0x2285')]([_0x4ce13f(_0x32cb80,_0x450c2d('0x21da')),_0x4ce13f(_0x32cb80,_0x450c2d('0xde2')),_0x4ce13f(_0x32cb80,_0x450c2d('0x1bfa')),_0x4ce13f(_0x32cb80,_0x450c2d('0x26c')),_0x4ce13f(_0x32cb80,_0x450c2d('0x146c')),_0x4ce13f(_0x32cb80,_0x450c2d('0x116e')),_0x4ce13f(_0x32cb80,_0x450c2d('0x1fc7'))],_0x4643e4)?_0x151121=_0x450c2d('0xdb0'):_0x151121=_0x450c2d('0x2344');}_0x32cb80[_0x450c2d('0xe34')]!==_0x151121&&(_0x32cb80[_0x450c2d('0xe34')]=_0x151121,_0x32cb80[_0x450c2d('0x24d5')]?(_0x32cb80['init']=![],_0x32cb80[_0x450c2d('0x25b3')]=_0xf51fe(_0x151121)?_0x2cfb05()[_0x450c2d('0xa53')](_0x24273b()(_0x32cb80[_0x450c2d('0x3dc')])['format']('x')):_0x2cfb05()['max']([_0x32cb80[_0x450c2d('0x18c9')],_0x32cb80[_0x450c2d('0x1507')],_0x32cb80[_0x450c2d('0x1955')],_0x32cb80[_0x450c2d('0x2357')],_0x32cb80[_0x450c2d('0x11a8')],_0x32cb80[_0x450c2d('0x43e')],_0x32cb80['faxStatusTime']])):_0x32cb80['globalStatusTime']=_0x2cfb05()['toNumber'](_0x24273b()()[_0x450c2d('0x128a')]('x')));}function _0x535bd4(_0x25814d){const _0x4233d2=_0x47ccb3,_0x192c99=_0x2cfb05()[_0x4233d2('0x1783')](_0x20266c[_0x4233d2('0x2218')][_0x4233d2('0xa99')],'-')?_0x4233d2('0x1dc3'):_0x4233d2('0x17d');return _0x2cfb05()[_0x4233d2('0xe63')](_0x25814d,[_0x20266c[_0x4233d2('0x2218')][_0x4233d2('0xa99')]['replace']('-','')],[_0x192c99]);}function _0x29a78e(){_0x2ac53a&&(_0x5778a6['cancel'](_0x2ac53a),_0x2ac53a=null);}function _0x365146(_0x5d33b0,_0x182db7){const _0x60c6c9=_0x47ccb3;return _0x118365[_0x60c6c9('0x557')][_0x60c6c9('0x1449')]({'id':_0x5d33b0['id']},{'screenrecording':_0x182db7})[_0x60c6c9('0xa44')][_0x60c6c9('0x1a80')](function(_0x34d979){const _0x87f264=_0x60c6c9;_0x5650fb[_0x87f264('0xfc9')]({'title':_0x34d979[_0x87f264('0x52d')]?_0x87f264('0x1e21')+_0x34d979['status']+_0x87f264('0x11e1')+_0x34d979['statusText']:_0x87f264('0x1103'),'msg':_0x34d979['data']?JSON[_0x87f264('0xbac')](_0x34d979[_0x87f264('0x25f4')][_0x87f264('0x1e70')]):_0x34d979[_0x87f264('0x1586')]()});});}_0x50e31f['$on'](_0x47ccb3('0x1c3f'),function(){const _0x509cbf=_0x47ccb3;_0xbdf493['removeAllListeners'](_0x509cbf('0x26b2')),_0xbdf493[_0x509cbf('0x1800')](_0x509cbf('0x19d5')),_0xbdf493[_0x509cbf('0x1800')](_0x509cbf('0x10fc')),_0xbdf493[_0x509cbf('0x1800')](_0x509cbf('0x1c99')),_0x29a78e();});}const _0x2c63fa=_0x5853d0,_0x51b24c=_0x2734b2['p']+'src/js/modules/main/apps/whatsapp/views/whatsappQueues/create/dialog.html/dialog.html',_0x54a35d=_0x2734b2['p']+_0x36e6f4('0x95c');_0x1b3994['$inject']=[_0x36e6f4('0x36f'),_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1c90'),'$interval',_0x36e6f4('0x7a7'),_0x36e6f4('0x744'),_0x36e6f4('0x19e3'),_0x36e6f4('0x2661'),'toasty',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x21ef')];function _0x1b3994(_0x365155,_0x243009,_0x2a504c,_0x1843e9,_0x25c7bd,_0x315961,_0x231f10,_0x4c5d2d,_0x289518,_0x263b72,_0x42e420,_0x159178,_0x13a4fa,_0x245856){const _0x1848a4=_0x36e6f4,_0x11452a=this,_0x4f2ae4=[_0x1848a4('0x1570'),_0x1848a4('0x44b'),_0x1848a4('0x288a'),'talking',_0x1848a4('0x67d'),_0x1848a4('0x20ab'),_0x1848a4('0x1e70'),_0x1848a4('0x6c9'),_0x1848a4('0x20ae'),'Trunk',_0x1848a4('0x18b')];_0x11452a[_0x1848a4('0x98')]=_0x245856[_0x1848a4('0x26cd')](),_0x11452a[_0x1848a4('0x240f')]=_0x231f10[_0x1848a4('0x240f')]?_0x231f10['count']:0x0,_0x11452a[_0x1848a4('0x7a7')]=_0x231f10?_0x2cfb05()[_0x1848a4('0x155c')](_0x231f10[_0x1848a4('0x269a')]?_0x231f10[_0x1848a4('0x269a')]:[],'id'):{},_0x11452a[_0x1848a4('0x744')]=_0x4c5d2d?_0x2cfb05()[_0x1848a4('0x155c')](_0x4c5d2d[_0x1848a4('0x269a')]?_0x4c5d2d['rows']:[],'id'):{},_0x11452a[_0x1848a4('0x7f')]=_0x159178,_0x11452a[_0x1848a4('0x17aa')]=_0x13a4fa&&_0x13a4fa[_0x1848a4('0x240f')]==0x1?_0x13a4fa[_0x1848a4('0x269a')][0x0]:null,_0x11452a[_0x1848a4('0x243c')]=_0x245856['parseCrudPermissions'](_0x11452a['userProfileSection']?_0x11452a['userProfileSection'][_0x1848a4('0x243c')]:null);_0x245856[_0x1848a4('0x1ac6')](_0x1848a4('0xa7c'))?_0x11452a['query']={'type':_0x1848a4('0x14d8'),'sort':_0x1848a4('0x14dc'),'limit':0xa,'page':0x1}:_0x11452a[_0x1848a4('0x2218')]={'id':_0x11452a[_0x1848a4('0x98')]['id'],'channel':_0x1848a4('0x116e'),'type':'inbound','sort':_0x1848a4('0x14dc'),'limit':0xa,'page':0x1};_0x11452a[_0x1848a4('0x103b')]=_0xc369ee,_0x11452a[_0x1848a4('0x152a')]=_0x215eea,_0x11452a['createOrEditWhatsappQueue']=_0x320e0b,_0x11452a[_0x1848a4('0x33f')]=_0x4a7936,_0x11452a['updateQueue']=_0x8658e9,_0x11452a[_0x1848a4('0x1303')]=_0x1de058,_0x11452a[_0x1848a4('0xfb')]=_0x3d37d9,_0x11452a['onRemoveMember']=_0x5729cd,_0x11452a[_0x1848a4('0x212c')]=_0x6181f1,_0x11452a[_0x1848a4('0xb9a')]=_0x2f60f7,_0x11452a[_0x1848a4('0x1696')]=_0x19447d,_0x11452a[_0x1848a4('0x1089')]=_0x5f5db5,_0x11452a[_0x1848a4('0xa99')]=[],_0x2cfb05()[_0x1848a4('0x941')](_0x11452a[_0x1848a4('0x7a7')],function(_0x2ac0a2){const _0x293a3d=_0x1848a4;_0x11452a[_0x293a3d('0xa99')][_0x293a3d('0x1514')](_0x2ac0a2['id']);}),_0x263b72['on'](_0x1848a4('0x2476'),_0x11452a['onSave']),_0x263b72['on'](_0x1848a4('0x842'),_0x11452a[_0x1848a4('0xfb')]),_0x263b72['on'](_0x1848a4('0x259b'),_0x11452a[_0x1848a4('0xfe9')]),_0x263b72['on'](_0x1848a4('0x19d5'),_0x11452a[_0x1848a4('0x212c')]),_0x263b72['on'](_0x1848a4('0x25f0'),_0x11452a['onLogout']),_0x263b72['on'](_0x1848a4('0x663'),_0x11452a[_0x1848a4('0xb9a')]);function _0x5f5db5(){const _0x28e095=_0x1848a4,_0x19a040=[];return _0x2cfb05()[_0x28e095('0x941')](_0x11452a[_0x28e095('0x7a7')],function(_0x468136,_0x2b928b){const _0x2ca627=_0x28e095;_0x468136['paused']=0x0,_0x468136['loggedInDb']=0x0,_0x11452a['queues'][_0x2b928b]['agents']={},_0x19a040[_0x2ca627('0x1514')](_0x289518[_0x2ca627('0x1bb6')][_0x2ca627('0x27d1')]({'id':_0x2b928b})['$promise']),_0x11452a[_0x2ca627('0x744')][_0x2b928b]&&_0x2cfb05()[_0x2ca627('0xcc3')](_0x468136,_0x2cfb05()[_0x2ca627('0x1a08')](_0x11452a['rpcQueues'][_0x2b928b],_0x4f2ae4));}),_0x1843e9['all'](_0x19a040)[_0x28e095('0x1166')](function(_0x4ef537){const _0xc18115=_0x28e095;for(let _0x47b617=0x0;_0x47b617<_0x4ef537[_0xc18115('0x264b')];_0x47b617+=0x1){for(let _0x41ef1f=0x0;_0x41ef1f<_0x4ef537[_0x47b617]['rows'][_0xc18115('0x264b')];_0x41ef1f++){_0x4ef537[_0x47b617]['rows'][_0x41ef1f][_0xc18115('0x18b')]&&_0x11452a[_0xc18115('0x7a7')][_0x4ef537[_0x47b617][_0xc18115('0x269a')][_0x41ef1f][_0xc18115('0x1adf')]][_0xc18115('0x18b')]++,_0x11452a[_0xc18115('0x7a7')][_0x4ef537[_0x47b617]['rows'][_0x41ef1f]['WhatsappQueueId']][_0xc18115('0x2689')]++,_0x11452a[_0xc18115('0x7a7')][_0x4ef537[_0x47b617][_0xc18115('0x269a')][_0x41ef1f][_0xc18115('0x1adf')]]['agents'][_0x4ef537[_0x47b617]['rows'][_0x41ef1f][_0xc18115('0x122a')]]=_0x4ef537[_0x47b617][_0xc18115('0x269a')][_0x41ef1f][_0xc18115('0x1adf')];}}})[_0x28e095('0x1a80')](function(_0x3ce27f){const _0x3a2e7e=_0x28e095;console[_0x3a2e7e('0xfc9')](_0x3ce27f);});}function _0x1de058(_0x19849b){const _0x31a569=_0x1848a4;_0x11452a[_0x31a569('0x7a7')][_0x19849b['id']]&&_0x2cfb05()[_0x31a569('0xcc3')](_0x11452a[_0x31a569('0x7a7')][_0x19849b['id']],_0x2cfb05()[_0x31a569('0x1a08')](_0x19849b,_0x4f2ae4));}function _0x3d37d9(_0x4a71c3){const _0x35cf55=_0x1848a4;_0x11452a[_0x35cf55('0x7a7')][_0x4a71c3[_0x35cf55('0x1adf')]]&&_0x11452a[_0x35cf55('0x7a7')][_0x4a71c3['WhatsappQueueId']]['loggedInDb']++;}function _0x5729cd(_0x1785e5){const _0x35b93a=_0x1848a4;_0x11452a[_0x35b93a('0x7a7')][_0x1785e5[_0x35b93a('0x1adf')]]&&_0x11452a[_0x35b93a('0x7a7')][_0x1785e5['WhatsappQueueId']][_0x35b93a('0x2689')]--;}function _0x6181f1(_0x160e9e){const _0x599ab5=_0x1848a4;console[_0x599ab5('0x455')]('onPause',_0x160e9e);if(_0x160e9e[_0x599ab5('0x2540')])_0x2cfb05()['forIn'](_0x11452a[_0x599ab5('0x7a7')],function(_0x5e1d39){const _0x3c3900=_0x599ab5;_0x5e1d39[_0x3c3900('0x1f7e')][_0x160e9e['id']]&&(_0x5e1d39[_0x3c3900('0x18b')]+=0x1,console[_0x3c3900('0x455')]('pause'));});else!_0x160e9e[_0x599ab5('0x2540')]&&_0x2cfb05()['forIn'](_0x11452a[_0x599ab5('0x7a7')],function(_0x31f7ce){const _0x448546=_0x599ab5;_0x31f7ce[_0x448546('0x1f7e')][_0x160e9e['id']]&&(_0x31f7ce[_0x448546('0x18b')]>0x0&&(_0x31f7ce['paused']-=0x1,console[_0x448546('0x455')](_0x448546('0x20eb'))));});}function _0x2f60f7(_0x4dcfb5){const _0x451840=_0x1848a4;console[_0x451840('0x455')](_0x451840('0x26c1'),_0x4dcfb5),_0x11452a['queues'][_0x4dcfb5[_0x451840('0x1adf')]]&&(_0x11452a[_0x451840('0x7a7')][_0x4dcfb5[_0x451840('0x1adf')]][_0x451840('0x2689')]+=0x1,_0x11452a[_0x451840('0x7a7')][_0x4dcfb5[_0x451840('0x1adf')]][_0x451840('0x1f7e')][_0x4dcfb5['UserId']]=_0x4dcfb5[_0x451840('0x1adf')]);}function _0x19447d(_0x576683){const _0x1e60e5=_0x1848a4;console[_0x1e60e5('0x455')](_0x1e60e5('0x1696'),_0x576683),_0x11452a[_0x1e60e5('0x7a7')][_0x576683['WhatsappQueueId']]&&_0x11452a[_0x1e60e5('0x7a7')][_0x576683['WhatsappQueueId']]['loggedInDb']>0x0&&(_0x11452a[_0x1e60e5('0x7a7')][_0x576683['WhatsappQueueId']]['loggedInDb']-=0x1,delete _0x11452a[_0x1e60e5('0x7a7')][_0x576683[_0x1e60e5('0x1adf')]][_0x1e60e5('0x1f7e')][_0x576683[_0x1e60e5('0x122a')]]);}let _0x535b5c=!![],_0x1bd180=0x1;_0x365155['$watch'](_0x1848a4('0x12d8'),function(_0x36feea,_0x33ac0d){const _0xf1d1d1=_0x1848a4;_0x535b5c?_0x243009(function(){_0x535b5c=![];}):(!_0x33ac0d&&(_0x1bd180=_0x11452a['query']['page']),_0x36feea!==_0x33ac0d&&(_0x11452a[_0xf1d1d1('0x2218')][_0xf1d1d1('0x1a43')]=0x1),!_0x36feea&&(_0x11452a['query'][_0xf1d1d1('0x1a43')]=_0x1bd180),_0x11452a[_0xf1d1d1('0x152a')]());});function _0xc369ee(_0x29444c){const _0x530643=_0x1848a4;_0x11452a['count']=_0x29444c[_0x530643('0x240f')],_0x11452a[_0x530643('0x7a7')]=_0x29444c?_0x2cfb05()['keyBy'](_0x29444c['rows']?_0x29444c[_0x530643('0x269a')]:[],'id'):{};if(_0x29444c[_0x530643('0x269a')]){_0x11452a[_0x530643('0xa99')]=[];for(let _0x49a279=0x0;_0x49a279<_0x29444c[_0x530643('0x269a')]['length'];_0x49a279++){_0x11452a['order'][_0x530643('0x1514')](_0x29444c[_0x530643('0x269a')][_0x49a279]['id']);}}_0x5f5db5();}function _0x215eea(){const _0xfd06a7=_0x1848a4;_0x11452a[_0xfd06a7('0x2218')][_0xfd06a7('0x1098')]=(_0x11452a['query'][_0xfd06a7('0x1a43')]-0x1)*_0x11452a[_0xfd06a7('0x2218')][_0xfd06a7('0x163f')],_0x245856[_0xfd06a7('0x1ac6')]('admin')?_0x11452a[_0xfd06a7('0x1f48')]=_0x289518[_0xfd06a7('0x1bb6')]['get'](_0x11452a[_0xfd06a7('0x2218')],_0xc369ee)[_0xfd06a7('0xa44')]:(_0x11452a[_0xfd06a7('0x2218')]['id']=_0x11452a[_0xfd06a7('0x7f')]['id'],_0x11452a[_0xfd06a7('0x2218')][_0xfd06a7('0xe60')]=_0xfd06a7('0x2727'),_0x11452a[_0xfd06a7('0x1f48')]=_0x289518['userProfile'][_0xfd06a7('0x263a')](_0x11452a[_0xfd06a7('0x2218')],_0xc369ee)[_0xfd06a7('0xa44')]);}function _0x320e0b(_0x1f0a83,_0x4dc004){const _0xbaa5aa=_0x1848a4;_0x2a504c[_0xbaa5aa('0x1f80')]({'controller':_0xbaa5aa('0x1553'),'controllerAs':'vm','templateUrl':_0x51b24c,'parent':angular[_0xbaa5aa('0x1194')](_0x25c7bd['body']),'targetEvent':_0x1f0a83,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x4dc004,'whatsappQueues':_0x2cfb05()[_0xbaa5aa('0x1ac1')](_0x11452a['queues']),'license':null,'setting':null,'crudPermissions':_0x11452a[_0xbaa5aa('0x243c')]}});}function _0x4a7936(_0x58408b,_0x2d6f2a){const _0x3d22b2=_0x1848a4;_0x2a504c[_0x3d22b2('0x1f80')]({'controller':_0x3d22b2('0x644'),'controllerAs':'vm','templateUrl':_0x54a35d,'parent':angular['element'](_0x25c7bd[_0x3d22b2('0x8d2')]),'targetEvent':_0x58408b,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x2d6f2a,'whatsappQueues':_0x11452a[_0x3d22b2('0x7a7')]?_0x11452a[_0x3d22b2('0x7a7')][_0x3d22b2('0x269a')]:[],'realtime':![],'crudPermissions':_0x11452a['crudPermissions']}});}function _0x8658e9(_0x140177){const _0x36a317=_0x1848a4;return _0x289518[_0x36a317('0x1bb6')][_0x36a317('0x1449')](_0x140177)[_0x36a317('0xa44')][_0x36a317('0x1166')](function(){const _0x36bf46=_0x36a317;_0x42e420['success']({'title':_0x36bf46('0x75b'),'msg':_0x140177[_0x36bf46('0x4f0')]?_0x140177[_0x36bf46('0x4f0')]+'\x20has\x20been\x20updated!':''});})[_0x36a317('0x1a80')](function(_0x2a8775){const _0x3c1083=_0x36a317;_0x42e420['error']({'title':_0x3c1083('0xa98'),'msg':_0x2a8775[_0x3c1083('0x1e70')]});});}_0x365155['$on'](_0x1848a4('0x1c3f'),function(){const _0x5524e5=_0x1848a4;_0x263b72[_0x5524e5('0x1800')](_0x5524e5('0x2476')),_0x263b72['removeAllListeners'](_0x5524e5('0x259b')),_0x263b72[_0x5524e5('0x1800')](_0x5524e5('0x842')),_0x263b72[_0x5524e5('0x1800')](_0x5524e5('0x19d5')),_0x263b72['removeAllListeners'](_0x5524e5('0x25f0')),_0x263b72['removeAllListeners'](_0x5524e5('0x663'));});}const _0x22bf27=_0x1b3994;function _0x57e023(){const _0x5409e9=_0x36e6f4;return{'status':{'registered':_0x5409e9('0x23ca'),'unregistered':'red-300-fg\x20icon-close-circle','lagged':'red-300-fg\x20icon-close-circle','reachable':'green-300-fg\x20icon-checkbox-marked-circle','unreachable':_0x5409e9('0x278f'),'unknown':_0x5409e9('0x2125')},'state':{'unknown':_0x5409e9('0x1d48'),'not_inuse':_0x5409e9('0xa1e'),'inuse':_0x5409e9('0xa2f'),'busy':_0x5409e9('0x18d2'),'invalid':_0x5409e9('0x1d48'),'unavailable':_0x5409e9('0x1d48'),'ringing':_0x5409e9('0x132c'),'ringinuse':_0x5409e9('0x132c'),'onhold':_0x5409e9('0x23d9')},'channelStatus':{'ring':_0x5409e9('0x132c'),'up':_0x5409e9('0x20b2'),'hangup':_0x5409e9('0x9e3')},'channelStatusOut':{'ring':_0x5409e9('0xac'),'up':_0x5409e9('0x20b2'),'hangup':_0x5409e9('0x9e3')}};}const _0x1fab42=_0x57e023;_0x5e8d3f[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x7b9'),_0x36e6f4('0x2661')];function _0x5e8d3f(_0x2ed174,_0x452492,_0x565676){const _0x107a20=_0x36e6f4,_0x5d8d2e=this;_0x565676[_0x107a20('0x670')](),_0x565676[_0x107a20('0x7bb')](),_0x5d8d2e['selectedTab']=0x0;switch(_0x452492['current'][_0x107a20('0x4f0')]){case _0x107a20('0x1a78'):_0x5d8d2e[_0x107a20('0x2669')]=0x0;break;case'app.whatsapp.realtime.queues':_0x5d8d2e[_0x107a20('0x2669')]=0x1;break;default:_0x5d8d2e[_0x107a20('0x2669')]=0x0,_0x452492['go'](_0x107a20('0x1a78'));}_0x2ed174['$watch'](_0x107a20('0x27a7'),function(_0x4a0994,_0xa6fca2){const _0x2c948e=_0x107a20;if(_0x4a0994!==_0xa6fca2)switch(_0x4a0994){case 0x0:_0x452492['go'](_0x2c948e('0x1a78'));break;case 0x1:_0x452492['go'](_0x2c948e('0x2210'));break;default:_0x452492['go']('app.whatsapp.realtime.agents');break;}});}const _0x3eac2b=_0x5e8d3f;_0x393185['$inject']=[_0x36e6f4('0x259c')];function _0x393185(_0x194ecf){const _0x32001a=_0x36e6f4;_0x194ecf[_0x32001a('0x63f')](_0x32001a('0x791'),{'url':'/realtime','views':{'content@app':{'templateUrl':_0xe7fffa,'controller':'WhatsappRealtimeController\x20as\x20vm'}},'resolve':{'userProfile':[_0x32001a('0x1fbc'),'Auth',function(_0x3fb74b,_0x3b50bc){const _0x749b74=_0x32001a;return _0x3b50bc[_0x749b74('0x1ac6')](_0x749b74('0xa7c'))?null:_0x3fb74b[_0x749b74('0x18af')](_0x749b74('0x697'),{'fields':_0x749b74('0x686'),'id':_0x3b50bc[_0x749b74('0x26cd')]()[_0x749b74('0xb86')]});}],'userProfileSection':['apiResolver',_0x32001a('0x21ef'),function(_0xfb511e,_0x12f853){const _0x31234e=_0x32001a;return _0x12f853[_0x31234e('0x1ac6')](_0x31234e('0xa7c'))?null:_0xfb511e[_0x31234e('0x18af')](_0x31234e('0xaf'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x12f853[_0x31234e('0x26cd')]()[_0x31234e('0xb86')],'sectionId':0x83e});}]},'authenticate':!![],'permissionId':0x83e})['state'](_0x32001a('0x1a78'),{'url':_0x32001a('0x730'),'controller':_0x32001a('0x60a'),'templateUrl':_0x4a5787,'resolve':{'pauses':['apiResolver',function(_0x44a687){const _0x345f14=_0x32001a;return _0x44a687[_0x345f14('0x18af')]('pause@get',{'nolimit':!![]});}],'agents':[_0x32001a('0x1fbc'),_0x32001a('0x21ef'),function(_0x3e40d1,_0xdb0c02){const _0x55a124=_0x32001a;return _0xdb0c02[_0x55a124('0x1ac6')](_0x55a124('0xa7c'))?_0x3e40d1[_0x55a124('0x18af')]('user@get',{'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':'agent','sort':_0x55a124('0x6e1'),'nolimit':!![]}):_0x3e40d1[_0x55a124('0x18af')](_0x55a124('0x17c4'),{'id':_0xdb0c02[_0x55a124('0x26cd')]()[_0x55a124('0xb86')],'section':'Agents','fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0x55a124('0x1eff'),'sort':_0x55a124('0x6e1'),'nolimit':!![]});}],'userProfile':[_0x32001a('0x1fbc'),'Auth',function(_0x3d8f5f,_0x313e4d){const _0x85b55a=_0x32001a;return _0x313e4d[_0x85b55a('0x1ac6')](_0x85b55a('0xa7c'))?null:_0x3d8f5f[_0x85b55a('0x18af')](_0x85b55a('0x697'),{'fields':_0x85b55a('0x686'),'id':_0x313e4d[_0x85b55a('0x26cd')]()[_0x85b55a('0xb86')]});}],'userProfileSection':[_0x32001a('0x1fbc'),_0x32001a('0x21ef'),function(_0x45b4ba,_0x2264ef){const _0x4c6cd6=_0x32001a;return _0x2264ef['hasRole'](_0x4c6cd6('0xa7c'))?null:_0x45b4ba[_0x4c6cd6('0x18af')](_0x4c6cd6('0xaf'),{'fields':_0x4c6cd6('0xe26'),'userProfileId':_0x2264ef['getCurrentUser']()[_0x4c6cd6('0xb86')],'sectionId':0xca});}],'rpcAgents':['apiResolver',function(_0x3160ec){const _0x4c6714=_0x32001a;return _0x3160ec['resolve'](_0x4c6714('0xfab'));}]},'authenticate':!![],'permissionId':0x83e})[_0x32001a('0x63f')](_0x32001a('0x2210'),{'url':_0x32001a('0x1bd2'),'controller':_0x32001a('0x6c8'),'templateUrl':_0xcea762,'resolve':{'queues':[_0x32001a('0x1fbc'),_0x32001a('0x21ef'),function(_0x1e2e5d,_0xf0cbe1){const _0x3ca1b1=_0x32001a;return _0xf0cbe1[_0x3ca1b1('0x1ac6')]('admin')?_0x1e2e5d[_0x3ca1b1('0x18af')](_0x3ca1b1('0x1850'),{'type':'inbound','sort':_0x3ca1b1('0x14dc'),'limit':0xa,'offset':0x0}):_0x1e2e5d['resolve'](_0x3ca1b1('0x17c4'),{'id':_0xf0cbe1[_0x3ca1b1('0x26cd')]()[_0x3ca1b1('0xb86')],'section':_0x3ca1b1('0x2727'),'channel':_0x3ca1b1('0x116e'),'type':_0x3ca1b1('0x14d8'),'sort':_0x3ca1b1('0x14dc'),'limit':0xa,'page':0x1});}],'userProfile':[_0x32001a('0x1fbc'),_0x32001a('0x21ef'),function(_0x5f3b4,_0x5def24){const _0x2c06b9=_0x32001a;return _0x5def24[_0x2c06b9('0x1ac6')](_0x2c06b9('0xa7c'))?null:_0x5f3b4[_0x2c06b9('0x18af')](_0x2c06b9('0x697'),{'fields':_0x2c06b9('0x686'),'id':_0x5def24['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x32001a('0x1fbc'),_0x32001a('0x21ef'),function(_0x1627ae,_0x2e2d98){const _0x3d17ee=_0x32001a;return _0x2e2d98['hasRole'](_0x3d17ee('0xa7c'))?null:_0x1627ae['resolve'](_0x3d17ee('0xaf'),{'fields':_0x3d17ee('0xe26'),'userProfileId':_0x2e2d98[_0x3d17ee('0x26cd')]()[_0x3d17ee('0xb86')],'sectionId':0x835});}],'rpcQueues':[_0x32001a('0x1fbc'),function(_0x80fae0){const _0x13ec71=_0x32001a;return _0x80fae0[_0x13ec71('0x18af')](_0x13ec71('0x2581'));}]},'authenticate':!![],'permissionId':0x83e});}angular[_0x36e6f4('0x896')](_0x36e6f4('0x791'),[])[_0x36e6f4('0xe11')](_0x393185)['controller'](_0x36e6f4('0x1ab1'),_0x2c63fa)[_0x36e6f4('0x75e')](_0x36e6f4('0x160'),_0x22bf27)['factory']('helperClasses',_0x1fab42)[_0x36e6f4('0x75e')](_0x36e6f4('0x1b4a'),_0x3eac2b);const _0x4c1ae7=_0x2734b2['p']+'src/js/modules/main/apps/whatsapp/views/whatsappQueues/whatsappQueues.html/whatsappQueues.html',_0x52dcc0=_0x2734b2['p']+_0x36e6f4('0x1317'),_0x450957=_0x2734b2['p']+_0x36e6f4('0xf68'),_0x4fa553=_0x2734b2['p']+_0x36e6f4('0x16d5');_0xe4c571[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0x1974'),'whatsappAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0xe4c571(_0x48cef0,_0x45e614,_0x1d02a4,_0x50aeeb,_0x1b675e,_0x31cf2d,_0x475385,_0x405343,_0x4e737e,_0x13f870,_0x5ca0d7,_0x16ab5b,_0x7847bd,_0x20dc0c){const _0x2c8c1a=_0x36e6f4,_0x7b9b2d=this;_0x7b9b2d[_0x2c8c1a('0x98')]=_0x5ca0d7[_0x2c8c1a('0x26cd')](),_0x7b9b2d[_0x2c8c1a('0x61a')]=[],_0x7b9b2d[_0x2c8c1a('0xf8a')]=_0x7847bd,_0x7b9b2d['license']=_0x16ab5b,_0x7b9b2d['crudPermissions']=_0x20dc0c,_0x7b9b2d[_0x2c8c1a('0x128b')]={},_0x7b9b2d[_0x2c8c1a('0x2900')]=_0x7b9b2d[_0x2c8c1a('0xf8a')]&&_0x7b9b2d['setting'][_0x2c8c1a('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x7b9b2d[_0x2c8c1a('0xcdc')]='WHATSAPP.EDIT_WHATSAPPACCOUNT',_0x7b9b2d[_0x2c8c1a('0xcc5')]=angular[_0x2c8c1a('0x225f')](_0x4e737e),_0x7b9b2d['whatsappAccounts']=_0x405343,_0x7b9b2d[_0x2c8c1a('0x14ef')]=![];!_0x7b9b2d[_0x2c8c1a('0xcc5')]&&(_0x7b9b2d[_0x2c8c1a('0xcc5')]={'remote':_0x1d02a4[_0x2c8c1a('0x6f1')]()+_0x2c8c1a('0xc51')+_0x1d02a4[_0x2c8c1a('0x1690')]()+(_0x1d02a4[_0x2c8c1a('0x93d')]()?':'+_0x1d02a4[_0x2c8c1a('0x93d')]():''),'type':'twilio','notificationSound':!![],'queueTransferTimeout':0x12c,'waitForTheAssignedAgent':0xa,'agentTransferTimeout':0x12c},_0x7b9b2d[_0x2c8c1a('0xcdc')]=_0x2c8c1a('0x640'),_0x7b9b2d['newWhatsappAccount']=!![]);_0x45e614[_0x2c8c1a('0x23f')]['id']&&(_0x7b9b2d[_0x2c8c1a('0xcc5')][_0x2c8c1a('0x1b88')]=_0x45e614[_0x2c8c1a('0x23f')]['id']);_0x7b9b2d['addNewWhatsappAccount']=_0x17c9e6,_0x7b9b2d[_0x2c8c1a('0x1cb3')]=_0x41eb5c,_0x7b9b2d['deleteWhatsappAccount']=_0x3ba24e,_0x7b9b2d[_0x2c8c1a('0x1a9c')]=_0x1518d4,_0x7b9b2d[_0x2c8c1a('0x24a0')]=_0x26ed8c,_0x5ca0d7['hasRole'](_0x2c8c1a('0xa7c'))?_0x13f870[_0x2c8c1a('0xdd9')][_0x2c8c1a('0xd83')]({'fields':_0x2c8c1a('0x1776'),'sort':'name'})[_0x2c8c1a('0xa44')][_0x2c8c1a('0x1166')](function(_0x405e07){const _0x46c974=_0x2c8c1a;_0x7b9b2d[_0x46c974('0x8de')]=_0x405e07[_0x46c974('0x269a')]||[];})[_0x2c8c1a('0x1a80')](function(_0x1452b5){const _0x40c9b7=_0x2c8c1a;_0x475385['error']({'title':_0x1452b5[_0x40c9b7('0x52d')]?_0x40c9b7('0x1e21')+_0x1452b5['status']+'\x20-\x20'+_0x1452b5[_0x40c9b7('0xe1b')]:'SYSTEM:GET_LISTS','msg':_0x1452b5[_0x40c9b7('0x25f4')]?JSON[_0x40c9b7('0xbac')](_0x1452b5[_0x40c9b7('0x25f4')]):_0x1452b5[_0x40c9b7('0x1586')]()});}):_0x13f870['cmList'][_0x2c8c1a('0xd83')]({'fields':_0x2c8c1a('0x1776'),'sort':_0x2c8c1a('0x4f0')})['$promise']['then'](function(_0xa0069a){const _0xe73689=_0x2c8c1a;_0x7b9b2d[_0xe73689('0x8de')]=_0xa0069a[_0xe73689('0x269a')]||[];})[_0x2c8c1a('0x1166')](function(){const _0x3261e4=_0x2c8c1a;return _0x13f870[_0x3261e4('0x17aa')][_0x3261e4('0xd83')]({'userProfileId':_0x7b9b2d[_0x3261e4('0x98')][_0x3261e4('0xb86')],'sectionId':0x12d})[_0x3261e4('0xa44')];})['then'](function(_0x511345){const _0x1ec505=_0x2c8c1a,_0x4a48c0=_0x511345&&_0x511345[_0x1ec505('0x269a')]?_0x511345[_0x1ec505('0x269a')][0x0]:null;if(!_0x4a48c0){const _0x147791=[];let _0x58770f=null;_0x7b9b2d['whatsappAccount']&&(_0x58770f=_0x2cfb05()['find'](_0x7b9b2d[_0x1ec505('0x8de')],{'id':Number(_0x7b9b2d[_0x1ec505('0xcc5')][_0x1ec505('0x23c')])}));for(let _0x336774=0x0;_0x336774<_0x7b9b2d[_0x1ec505('0x8de')][_0x1ec505('0x264b')];_0x336774++){_0x58770f&&_0x7b9b2d[_0x1ec505('0x8de')][_0x336774]['id']===_0x58770f['id']&&(_0x7b9b2d[_0x1ec505('0x8de')][_0x336774][_0x1ec505('0x2378')]=![],_0x147791[_0x1ec505('0x1514')](_0x7b9b2d[_0x1ec505('0x8de')][_0x336774]));}_0x7b9b2d[_0x1ec505('0x8de')]=_0x147791;}else{if(!_0x4a48c0['autoAssociation'])return _0x13f870['userProfileResource'][_0x1ec505('0xd83')]({'sectionId':_0x4a48c0['id']})[_0x1ec505('0xa44')][_0x1ec505('0x1166')](function(_0x5b2985){const _0x5886df=_0x1ec505,_0x331ce9=_0x2cfb05()[_0x5886df('0x2563')](_0x5b2985[_0x5886df('0x269a')],function(_0x408af3){const _0x5b0e5d=_0x5886df;return _0x2cfb05()[_0x5b0e5d('0xc38')](_0x7b9b2d[_0x5b0e5d('0x8de')],{'id':_0x408af3[_0x5b0e5d('0x24e8')]});});let _0x36c6ee=null;_0x7b9b2d[_0x5886df('0xcc5')]&&(_0x36c6ee=_0x2cfb05()[_0x5886df('0xc38')](_0x7b9b2d[_0x5886df('0x8de')],{'id':Number(_0x7b9b2d['whatsappAccount']['ListId'])}));if(_0x36c6ee&&!_0x2cfb05()[_0x5886df('0x1798')](_0x331ce9,['id',_0x36c6ee['id']])){const _0x3f4f74=_0x2cfb05()[_0x5886df('0xc38')](_0x7b9b2d[_0x5886df('0x8de')],{'id':_0x36c6ee['id']});_0x3f4f74[_0x5886df('0x2378')]=![],_0x331ce9['push'](_0x3f4f74);}_0x7b9b2d['lists']=_0x331ce9;});}})[_0x2c8c1a('0x1a80')](function(_0x1c4f32){const _0x354638=_0x2c8c1a;_0x475385[_0x354638('0xfc9')]({'title':_0x1c4f32[_0x354638('0x52d')]?'API:'+_0x1c4f32['status']+_0x354638('0x11e1')+_0x1c4f32[_0x354638('0xe1b')]:_0x354638('0x1248'),'msg':_0x1c4f32[_0x354638('0x25f4')]?JSON[_0x354638('0xbac')](_0x1c4f32[_0x354638('0x25f4')]):_0x1c4f32['toString']()});}),_0x5ca0d7[_0x2c8c1a('0x1ac6')](_0x2c8c1a('0xa7c'))?_0x13f870['pause'][_0x2c8c1a('0xd83')]({'fields':'name,id','sort':'name','nolimit':_0x2c8c1a('0xf3b')})[_0x2c8c1a('0xa44')][_0x2c8c1a('0x1166')](function(_0x48e8d4){const _0x5b9b10=_0x2c8c1a;_0x7b9b2d['pauses']=_0x48e8d4[_0x5b9b10('0x269a')]||[];})['catch'](function(_0x5473cc){const _0x57aaf4=_0x2c8c1a;_0x475385[_0x57aaf4('0xfc9')]({'title':_0x5473cc[_0x57aaf4('0x52d')]?_0x57aaf4('0x1e21')+_0x5473cc['status']+_0x57aaf4('0x11e1')+_0x5473cc[_0x57aaf4('0xe1b')]:'SYSTEM:GET_PAUSES','msg':_0x5473cc[_0x57aaf4('0x25f4')]?JSON[_0x57aaf4('0xbac')](_0x5473cc['data']):_0x5473cc[_0x57aaf4('0x1586')]()});}):_0x13f870[_0x2c8c1a('0x1e77')]['get']({'fields':'name,id','sort':_0x2c8c1a('0x4f0'),'nolimit':'true'})[_0x2c8c1a('0xa44')][_0x2c8c1a('0x1166')](function(_0x42a8ce){const _0x5f3b56=_0x2c8c1a;_0x7b9b2d['pauses']=_0x42a8ce[_0x5f3b56('0x269a')]||[];})[_0x2c8c1a('0x1166')](function(){const _0x4394c4=_0x2c8c1a;return _0x13f870[_0x4394c4('0x17aa')][_0x4394c4('0xd83')]({'userProfileId':_0x7b9b2d['currentUser'][_0x4394c4('0xb86')],'sectionId':0x3ed})['$promise'];})[_0x2c8c1a('0x1166')](function(_0x379c20){const _0x13145c=_0x2c8c1a,_0x35dad3=_0x379c20&&_0x379c20[_0x13145c('0x269a')]?_0x379c20['rows'][0x0]:null;if(!_0x35dad3)_0x7b9b2d[_0x13145c('0xe29')]=[];else{if(!_0x35dad3[_0x13145c('0x1a2b')])return _0x13f870['userProfileResource'][_0x13145c('0xd83')]({'sectionId':_0x35dad3['id']})[_0x13145c('0xa44')][_0x13145c('0x1166')](function(_0x2743ef){const _0x51fc7f=_0x13145c,_0x1683d4=_0x2cfb05()['map'](_0x2743ef['rows'],function(_0x46a8c8){const _0x55fe49=a0_0x3f2c;return _0x2cfb05()['find'](_0x7b9b2d[_0x55fe49('0xe29')],{'id':_0x46a8c8[_0x55fe49('0x24e8')]});});_0x7b9b2d[_0x51fc7f('0xe29')][_0x51fc7f('0x2782')](function(_0x1ef61a){const _0x42211e=_0x51fc7f;!_0x2cfb05()[_0x42211e('0x1798')](_0x1683d4,['id',_0x1ef61a['id']])&&(_0x1ef61a[_0x42211e('0x2378')]=![]),_0x1683d4[_0x42211e('0x1514')](_0x1ef61a);}),_0x7b9b2d['pauses']=_0x1683d4;});}})['catch'](function(_0x2e7f73){const _0x8d51d3=_0x2c8c1a;_0x475385[_0x8d51d3('0xfc9')]({'title':_0x2e7f73[_0x8d51d3('0x52d')]?_0x8d51d3('0x1e21')+_0x2e7f73['status']+'\x20-\x20'+_0x2e7f73['statusText']:'SYSTEM:GETpauses','msg':_0x2e7f73[_0x8d51d3('0x25f4')]?JSON[_0x8d51d3('0xbac')](_0x2e7f73['data']):_0x2e7f73[_0x8d51d3('0x1586')]()});});function _0x17c9e6(){const _0x2658d2=_0x2c8c1a;_0x7b9b2d[_0x2658d2('0x61a')]=[],_0x13f870['whatsappAccount']['save'](_0x7b9b2d[_0x2658d2('0xcc5')])[_0x2658d2('0xa44')][_0x2658d2('0x1166')](function(_0x38c128){const _0x57d301=_0x2658d2;_0x7b9b2d['whatsappAccounts'][_0x57d301('0x2450')](_0x38c128[_0x57d301('0x2876')]()),_0x475385[_0x57d301('0x103b')]({'title':'WhatsappAccount\x20properly\x20created','msg':_0x7b9b2d[_0x57d301('0xcc5')][_0x57d301('0x4f0')]?_0x7b9b2d['whatsappAccount'][_0x57d301('0x4f0')]+_0x57d301('0x1eda'):''}),_0x26ed8c(_0x38c128);})[_0x2658d2('0x1a80')](function(_0x44a024){const _0x3012a3=_0x2658d2;if(_0x44a024[_0x3012a3('0x25f4')]&&_0x44a024[_0x3012a3('0x25f4')][_0x3012a3('0x61a')]&&_0x44a024[_0x3012a3('0x25f4')][_0x3012a3('0x61a')][_0x3012a3('0x264b')]){_0x7b9b2d[_0x3012a3('0x61a')]=_0x44a024[_0x3012a3('0x25f4')]['errors']||[{'message':_0x44a024[_0x3012a3('0x1586')](),'type':_0x3012a3('0x18f6')}];for(let _0x4defa9=0x0;_0x4defa9<_0x44a024[_0x3012a3('0x25f4')][_0x3012a3('0x61a')]['length'];_0x4defa9+=0x1){_0x475385[_0x3012a3('0xfc9')]({'title':_0x44a024['data'][_0x3012a3('0x61a')][_0x4defa9][_0x3012a3('0x1345')],'msg':_0x44a024[_0x3012a3('0x25f4')][_0x3012a3('0x61a')][_0x4defa9]['message']});}}else _0x475385[_0x3012a3('0xfc9')]({'title':_0x44a024['status']?_0x3012a3('0x1e21')+_0x44a024[_0x3012a3('0x52d')]+'\x20-\x20'+_0x44a024[_0x3012a3('0xe1b')]:_0x3012a3('0x18f6'),'msg':_0x44a024[_0x3012a3('0x25f4')]?JSON[_0x3012a3('0xbac')](_0x44a024[_0x3012a3('0x25f4')][_0x3012a3('0x1e70')]):_0x44a024[_0x3012a3('0x1586')]()});});}function _0x41eb5c(){const _0x4b9063=_0x2c8c1a;_0x7b9b2d[_0x4b9063('0x61a')]=[],_0x13f870[_0x4b9063('0xcc5')][_0x4b9063('0x1449')]({'id':_0x7b9b2d['whatsappAccount']['id']},_0x7b9b2d[_0x4b9063('0xcc5')])['$promise'][_0x4b9063('0x1166')](function(_0x3c3865){const _0xa06289=_0x4b9063,_0x3fe7f8=_0x2cfb05()['find'](_0x7b9b2d[_0xa06289('0x1974')],{'id':_0x3c3865['id']});_0x3fe7f8&&_0x2cfb05()[_0xa06289('0xcc3')](_0x3fe7f8,_0x2cfb05()[_0xa06289('0x1a08')](_0x3c3865[_0xa06289('0x2876')](),_0x2cfb05()[_0xa06289('0x14a4')](_0x3fe7f8))),_0x475385['success']({'title':_0xa06289('0xfa5'),'msg':_0x7b9b2d['whatsappAccount'][_0xa06289('0x4f0')]?_0x7b9b2d[_0xa06289('0xcc5')]['name']+_0xa06289('0x7d'):''}),_0x26ed8c(_0x3c3865);})[_0x4b9063('0x1a80')](function(_0x5e7179){const _0x5dc32d=_0x4b9063;if(_0x5e7179['data']&&_0x5e7179[_0x5dc32d('0x25f4')][_0x5dc32d('0x61a')]&&_0x5e7179[_0x5dc32d('0x25f4')][_0x5dc32d('0x61a')]['length']){_0x7b9b2d[_0x5dc32d('0x61a')]=_0x5e7179[_0x5dc32d('0x25f4')][_0x5dc32d('0x61a')]||[{'message':_0x5e7179['toString'](),'type':_0x5dc32d('0x6d')}];for(let _0x2d11b5=0x0;_0x2d11b5<_0x5e7179[_0x5dc32d('0x25f4')]['errors'][_0x5dc32d('0x264b')];_0x2d11b5++){_0x475385[_0x5dc32d('0xfc9')]({'title':_0x5e7179['data'][_0x5dc32d('0x61a')][_0x2d11b5][_0x5dc32d('0x1345')],'msg':_0x5e7179[_0x5dc32d('0x25f4')]['errors'][_0x2d11b5][_0x5dc32d('0x1e70')]});}}else _0x475385['error']({'title':_0x5e7179[_0x5dc32d('0x52d')]?_0x5dc32d('0x1e21')+_0x5e7179[_0x5dc32d('0x52d')]+_0x5dc32d('0x11e1')+_0x5e7179['statusText']:_0x5dc32d('0x6d'),'msg':_0x5e7179[_0x5dc32d('0x25f4')]?JSON[_0x5dc32d('0xbac')](_0x5e7179['data'][_0x5dc32d('0x1e70')]):_0x5e7179[_0x5dc32d('0x1586')]()});});}function _0x3ba24e(_0x5c8efa){const _0x5a0586=_0x2c8c1a;_0x7b9b2d[_0x5a0586('0x61a')]=[];const _0x1d3ce7=_0x50aeeb[_0x5a0586('0x1d26')]()[_0x5a0586('0xcdc')](_0x5a0586('0x7fb'))[_0x5a0586('0xacc')](_0x5a0586('0x1ec2'))[_0x5a0586('0x8e8')](_0x5a0586('0x1157'))['ok'](_0x5a0586('0x18'))[_0x5a0586('0x3f')](_0x5a0586('0x497'))[_0x5a0586('0x203b')](_0x5c8efa);_0x50aeeb[_0x5a0586('0x1f80')](_0x1d3ce7)[_0x5a0586('0x1166')](function(){const _0x230232=_0x5a0586;_0x13f870[_0x230232('0xcc5')][_0x230232('0x906')]({'id':_0x7b9b2d['whatsappAccount']['id']})[_0x230232('0xa44')][_0x230232('0x1166')](function(){const _0x4e67dd=_0x230232;_0x2cfb05()[_0x4e67dd('0x127f')](_0x7b9b2d[_0x4e67dd('0x1974')],{'id':_0x7b9b2d[_0x4e67dd('0xcc5')]['id']}),_0x475385['success']({'title':_0x4e67dd('0x1310'),'msg':(_0x7b9b2d[_0x4e67dd('0xcc5')][_0x4e67dd('0x4f0')]||_0x4e67dd('0xcc5'))+_0x4e67dd('0x7cd')}),_0x26ed8c(_0x7b9b2d['whatsappAccount']);})['catch'](function(_0x198e28){const _0x52a1f3=_0x230232;if(_0x198e28['data']&&_0x198e28[_0x52a1f3('0x25f4')]['errors']&&_0x198e28[_0x52a1f3('0x25f4')]['errors'][_0x52a1f3('0x264b')]){_0x7b9b2d[_0x52a1f3('0x61a')]=_0x198e28[_0x52a1f3('0x25f4')][_0x52a1f3('0x61a')]||[{'message':_0x198e28[_0x52a1f3('0x1586')](),'type':_0x52a1f3('0x1644')}];for(let _0x21f5fa=0x0;_0x21f5fa<_0x198e28[_0x52a1f3('0x25f4')]['errors'][_0x52a1f3('0x264b')];_0x21f5fa++){_0x475385[_0x52a1f3('0xfc9')]({'title':_0x198e28[_0x52a1f3('0x25f4')][_0x52a1f3('0x61a')][_0x21f5fa][_0x52a1f3('0x1345')],'msg':_0x198e28[_0x52a1f3('0x25f4')][_0x52a1f3('0x61a')][_0x21f5fa][_0x52a1f3('0x1e70')]});}}else _0x475385[_0x52a1f3('0xfc9')]({'title':_0x198e28['status']?_0x52a1f3('0x1e21')+_0x198e28[_0x52a1f3('0x52d')]+_0x52a1f3('0x11e1')+_0x198e28[_0x52a1f3('0xe1b')]:_0x52a1f3('0x1644'),'msg':_0x198e28['data']?JSON[_0x52a1f3('0xbac')](_0x198e28[_0x52a1f3('0x25f4')][_0x52a1f3('0x1e70')]):_0x198e28[_0x52a1f3('0x1e70')]||_0x198e28[_0x52a1f3('0x1586')]()});});},function(){});}function _0x1518d4(_0x59e8f7){return _0x59e8f7===null?undefined:new Date(_0x59e8f7);}function _0x26ed8c(_0x5af627){const _0x14dbcf=_0x2c8c1a;_0x50aeeb[_0x14dbcf('0x1197')](_0x5af627);}}const _0xe606e0=_0xe4c571,_0x201999=_0x2734b2['p']+_0x36e6f4('0x2e4'),_0x22ff99=_0x2734b2['p']+'src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/amazonlex/dialog.html/dialog.html',_0x33d3d0=_0x2734b2['p']+'src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/autoreply/dialog.html/dialog.html',_0xd74371=_0x2734b2['p']+'src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/close/dialog.html/dialog.html',_0x2684ac=_0x2734b2['p']+_0x36e6f4('0x1244'),_0x4de138=_0x2734b2['p']+_0x36e6f4('0x282'),_0x3e6318=_0x2734b2['p']+_0x36e6f4('0xd2e'),_0x20ebfe=_0x2734b2['p']+_0x36e6f4('0x1f30'),_0x4408dc=_0x2734b2['p']+_0x36e6f4('0x1f79'),_0x48cc39=_0x2734b2['p']+_0x36e6f4('0x68'),_0x57cae2=_0x2734b2['p']+_0x36e6f4('0x20bc'),_0x4acb11=_0x2734b2['p']+'src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/tag/dialog.html/dialog.html';_0x3e51e1[_0x36e6f4('0x1294')]=['api',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),'toasty',_0x36e6f4('0x21ef')];const _0x374044={'agent':_0x201999,'amazonlex':_0x22ff99,'autoreply':_0x33d3d0,'close':_0xd74371,'dialogflow':_0x2684ac,'gotoif':_0x4de138,'gotop':_0x3e6318,'interval':_0x20ebfe,'noop':_0x4408dc,'queue':_0x48cc39,'system':_0x57cae2,'tag':_0x4acb11};function _0x3e51e1(_0x28ad1b,_0x4fedd9,_0x2832bd,_0x47296b,_0x3fb2cf){const _0x474d08=_0x36e6f4,_0x8f6c34=this;_0x8f6c34[_0x474d08('0x98')]=_0x3fb2cf[_0x474d08('0x26cd')](),_0x8f6c34[_0x474d08('0xcc5')]={},_0x8f6c34[_0x474d08('0x4a1')]={'count':0x0,'rows':[]},_0x8f6c34['selectedWhatsappAccountApps']=[],_0x8f6c34[_0x474d08('0x243c')],_0x8f6c34[_0x474d08('0x2218')]={'sort':'priority'},_0x8f6c34['apps']=_0x2cfb05()['reject'](_0x2cfb05()[_0x474d08('0x1eba')]([{'app':_0x474d08('0x1545'),'appType':_0x474d08('0x277c'),'types':[_0x474d08('0x597'),_0x474d08('0x2853'),_0x474d08('0x1480')],'fields':[],'isApp':![]},{'app':_0x474d08('0x2652'),'appType':_0x474d08('0x2652'),'type':_0x474d08('0x2652'),'icon':_0x474d08('0x283f'),'interval':_0x474d08('0x16f'),'required':!![],'isApp':!![],'fields':[{'title':'Value','name':_0x474d08('0x18e0'),'type':_0x474d08('0x1640'),'param':0x0}]},{'app':'system','appType':'system','type':_0x474d08('0x1c2b'),'icon':_0x474d08('0x283f'),'interval':'*,*,*,*','required':!![],'isApp':!![],'extraApi':[{'name':_0x474d08('0x57a'),'field':{'name':'variable','key':'name'},'route':_0x474d08('0x734'),'filters':{'fields':_0x474d08('0x1776'),'sort':_0x474d08('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':'Command','name':_0x474d08('0x187'),'type':_0x474d08('0x1640'),'required':!![],'param':0x0},{'title':_0x474d08('0x2d5'),'name':'variable','type':_0x474d08('0x2550'),'values':'variables','value':_0x474d08('0x15f0'),'option':_0x474d08('0x15f0'),'defaultValues':[{'value':'\x27\x27','option':'None'}],'defaultValue':'\x27\x27','param':0x1}]},{'app':_0x474d08('0x6e6'),'appType':_0x474d08('0x6e6'),'type':_0x474d08('0x1a03'),'icon':_0x474d08('0x283f'),'interval':_0x474d08('0x16f'),'isApp':!![],'fields':[{'title':'Priority','name':_0x474d08('0xfde'),'type':'number','required':!![],'min':0x0,'param':0x0}]},{'app':_0x474d08('0x30f'),'appType':_0x474d08('0x30f'),'type':_0x474d08('0x30f'),'icon':_0x474d08('0x283f'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x474d08('0x1cdc'),'name':'condition','type':_0x474d08('0x1640'),'required':!![],'param':0x0},{'title':_0x474d08('0x13a6'),'name':'truepriority','type':_0x474d08('0xc45'),'min':0x1,'required':!![],'param':0x1},{'title':_0x474d08('0x1d7a'),'name':'falsepriority','type':_0x474d08('0xc45'),'min':0x1,'required':!![],'param':0x2}]},{'app':_0x474d08('0x1d3e'),'appType':'queue','foreignKey':_0x474d08('0x1adf'),'type':_0x474d08('0x1d3e'),'icon':'icon-apps','interval':_0x474d08('0x16f'),'isApp':!![],'extraApi':[{'name':_0x474d08('0x7a7'),'field':{'name':_0x474d08('0x1d3e'),'key':_0x474d08('0x4f0')},'route':_0x474d08('0x1bb6'),'filters':{'fields':_0x474d08('0x1c09'),'sort':_0x474d08('0x4f0'),'nolimit':!![]},'permissions':{'section':0x836}}],'fields':[{'title':'Queue','name':_0x474d08('0x1d3e'),'type':'apiselect','values':_0x474d08('0x7a7'),'value':_0x474d08('0x24ad'),'option':_0x474d08('0x24ad'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':_0x474d08('0x1861'),'name':_0x474d08('0x651'),'type':'number','max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x12c,'param':0x1}]},{'app':_0x474d08('0x1eff'),'appType':'agent','type':_0x474d08('0x1eff'),'foreignKey':_0x474d08('0x122a'),'icon':'icon-apps','interval':_0x474d08('0x16f'),'isApp':!![],'extraApi':[{'name':_0x474d08('0x1f7e'),'field':{'name':'agent','key':_0x474d08('0x4f0')},'route':_0x474d08('0x557'),'filters':{'fields':'id,name','sort':_0x474d08('0x4f0'),'nolimit':!![],'role':'agent'},'permissions':{'section':0xca}}],'fields':[{'title':_0x474d08('0x89b'),'name':_0x474d08('0x1eff'),'type':_0x474d08('0x2550'),'values':_0x474d08('0x1f7e'),'value':_0x474d08('0x1530'),'option':_0x474d08('0x1530'),'required':!![],'param':0x0},{'title':_0x474d08('0x1861'),'name':'timeout','type':_0x474d08('0xc45'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':_0x474d08('0x1af7'),'appType':'autoreply','type':_0x474d08('0x1af7'),'icon':_0x474d08('0x283f'),'interval':_0x474d08('0x16f'),'isApp':!![],'fields':[{'title':'times','name':_0x474d08('0x265e'),'type':_0x474d08('0x88a'),'defaultValue':'1','values':[{'option':'One\x20Time','value':'1'},{'option':_0x474d08('0x70f'),'value':'0'}],'required':!![],'param':0x0},{'title':_0x474d08('0xef7'),'name':_0x474d08('0x1640'),'type':_0x474d08('0x489'),'required':!![],'param':0x1}]},{'app':_0x474d08('0x1a7b'),'appType':_0x474d08('0x1a7b'),'type':_0x474d08('0x1a7b'),'icon':_0x474d08('0x283f'),'interval':_0x474d08('0x16f'),'isApp':!![],'fields':[{'title':_0x474d08('0x9b9'),'name':_0x474d08('0x12e8'),'type':_0x474d08('0x1640'),'required':!![],'param':0x0}]},{'app':_0x474d08('0x1446'),'appType':_0x474d08('0x1446'),'type':_0x474d08('0x1446'),'foreignKey':_0x474d08('0x8f5'),'icon':'icon-apps','interval':_0x474d08('0x16f'),'isApp':!![],'extraApi':[{'name':_0x474d08('0xb38'),'field':{'name':_0x474d08('0x1446'),'key':_0x474d08('0x4f0')},'route':_0x474d08('0x1446'),'filters':{'fields':'id,name','sort':_0x474d08('0x4f0'),'nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x474d08('0x1b35'),'name':_0x474d08('0x1446'),'type':_0x474d08('0x2550'),'values':_0x474d08('0xb38'),'value':'tag.name','option':_0x474d08('0xc2c'),'required':!![],'param':0x0}]},{'app':'dialogflow','appType':_0x474d08('0xded'),'type':_0x474d08('0xded'),'icon':_0x474d08('0x283f'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':'Key','name':_0x474d08('0x7ca'),'type':_0x474d08('0x1640'),'required':!![],'param':0x0},{'title':'language','name':_0x474d08('0xedb'),'type':'select','defaultValue':'\x27en\x27','values':[{'option':'Danish','value':_0x474d08('0xacf')},{'option':_0x474d08('0x1852'),'value':_0x474d08('0x17bf')},{'option':_0x474d08('0x20f'),'value':_0x474d08('0x15bd')},{'option':_0x474d08('0x1a40'),'value':_0x474d08('0x1dd3')},{'option':'Spanish','value':_0x474d08('0x14d0')},{'option':_0x474d08('0x2746'),'value':'\x27fr\x27'},{'option':_0x474d08('0xebe'),'value':_0x474d08('0x2872')},{'option':'Japanese','value':_0x474d08('0x1764')},{'option':_0x474d08('0x347'),'value':_0x474d08('0x82e')},{'option':_0x474d08('0x1025'),'value':_0x474d08('0x4f5')},{'option':'Norwegian','value':'\x27no\x27'},{'option':_0x474d08('0x0'),'value':'\x27pt\x27'},{'option':_0x474d08('0x2528'),'value':_0x474d08('0x1136')},{'option':_0x474d08('0xf22'),'value':_0x474d08('0x543')},{'option':_0x474d08('0x277e'),'value':_0x474d08('0x297')},{'option':_0x474d08('0x24f9'),'value':_0x474d08('0x1d2b')},{'option':_0x474d08('0xd6b'),'value':_0x474d08('0x38e')},{'option':'Chinese\x20(Simplified)','value':_0x474d08('0x244a')},{'option':_0x474d08('0x8d9'),'value':_0x474d08('0x21c7')},{'option':_0x474d08('0x145a'),'value':_0x474d08('0x2348')}],'required':!![],'param':0x1},{'title':'welcomemessage','name':_0x474d08('0x1634'),'type':_0x474d08('0x489'),'maxlength':0xff,'required':![],'param':0x2,'help':!![]}]},{'app':'dialogflowV2','appType':_0x474d08('0x1636'),'type':_0x474d08('0x1636'),'icon':_0x474d08('0x283f'),'interval':_0x474d08('0x16f'),'isApp':!![],'fields':[{'title':_0x474d08('0x23'),'name':_0x474d08('0x1b0a'),'type':_0x474d08('0x1640'),'required':!![],'param':0x0},{'title':'ClientEmail','name':'clientEmail','type':_0x474d08('0x1640'),'required':!![],'param':0x1},{'title':_0x474d08('0x17dd'),'name':_0x474d08('0x170e'),'type':_0x474d08('0x489'),'required':!![],'param':0x2},{'title':_0x474d08('0xedb'),'name':_0x474d08('0xedb'),'type':_0x474d08('0x88a'),'defaultValue':'\x27en\x27','values':[{'value':'\x27zh-HK\x27','option':_0x474d08('0x2837')},{'value':_0x474d08('0x244a'),'option':_0x474d08('0xefc')},{'value':_0x474d08('0x2348'),'option':_0x474d08('0x145a')},{'value':'\x27da\x27','option':'Danish'},{'value':'\x27nl\x27','option':'Dutch'},{'value':'\x27en\x27','option':_0x474d08('0x1852')},{'value':_0x474d08('0x457'),'option':_0x474d08('0x27a0')},{'value':_0x474d08('0x2270'),'option':_0x474d08('0x28b8')},{'value':_0x474d08('0x60d'),'option':_0x474d08('0x1cdd')},{'value':'\x27en-IN\x27','option':_0x474d08('0x655')},{'value':_0x474d08('0x25ba'),'option':_0x474d08('0x1f4')},{'value':_0x474d08('0x5f0'),'option':_0x474d08('0x2746')},{'value':'\x27fr-CA\x27','option':'French\x20(Canada)'},{'value':_0x474d08('0x1cb9'),'option':'\x27France\x20(France)'},{'value':_0x474d08('0x15bd'),'option':_0x474d08('0x20f')},{'value':_0x474d08('0x9bd'),'option':'Hindi'},{'value':'\x27id\x27','option':_0x474d08('0xebe')},{'value':'\x27it\x27','option':_0x474d08('0x1a40')},{'value':_0x474d08('0x1764'),'option':'Japanese'},{'value':'\x27ko\x27','option':_0x474d08('0x511')},{'value':_0x474d08('0x119b'),'option':_0x474d08('0x522')},{'value':_0x474d08('0x27c'),'option':_0x474d08('0x19b3')},{'value':_0x474d08('0x271c'),'option':_0x474d08('0x702')},{'value':'\x27pt-PT\x27','option':'Portuguese\x20(Portugal)'},{'value':'\x27ru\x27','option':'Russian'},{'value':_0x474d08('0x14d0'),'option':_0x474d08('0x2246')},{'value':_0x474d08('0x14e3'),'option':'Spanish\x20(Latin\x20America)'},{'value':_0x474d08('0x1cfa'),'option':'Spanish\x20(Spain)'},{'value':_0x474d08('0x1ae8'),'option':'Swedish'},{'value':_0x474d08('0x1d2b'),'option':_0x474d08('0x24f9')},{'value':_0x474d08('0x1d58'),'option':_0x474d08('0x71a')},{'value':_0x474d08('0x38e'),'option':_0x474d08('0xd6b')}],'required':!![],'param':0x3},{'title':_0x474d08('0x1634'),'name':_0x474d08('0x1634'),'type':'textarea','maxlength':0xff,'param':0x4,'help':!![]}]},{'app':_0x474d08('0x86c'),'appType':'amazonlex','type':_0x474d08('0x86c'),'icon':_0x474d08('0x283f'),'interval':_0x474d08('0x16f'),'isApp':!![],'fields':[{'title':_0x474d08('0xee6'),'name':_0x474d08('0xee6'),'type':'text','required':!![],'param':0x0},{'title':'secretaccesskey','name':'secretaccesskey','type':_0x474d08('0x1640'),'required':!![],'param':0x1},{'title':_0x474d08('0x25a2'),'name':_0x474d08('0x25a2'),'type':_0x474d08('0x88a'),'defaultValue':_0x474d08('0x2891'),'values':[{'option':_0x474d08('0xc64'),'value':_0x474d08('0x2891')},{'option':'US\x20West\x20(Oregon)','value':'\x27us-west-2\x27'},{'option':'EU\x20(Ireland)','value':_0x474d08('0x658')},{'option':'Asia\x20Pacific\x20(Sydney)','value':_0x474d08('0xaed')}],'required':!![],'param':0x2},{'title':_0x474d08('0x1ac4'),'name':_0x474d08('0x1ac4'),'type':_0x474d08('0x1640'),'required':!![],'param':0x3},{'title':_0x474d08('0x1634'),'name':_0x474d08('0x1634'),'type':_0x474d08('0x489'),'maxlength':0xff,'required':![],'param':0x4,'help':!![]}]}],['app']),{'isApp':![]}),_0x8f6c34[_0x474d08('0x1480')]={'group':{'name':_0x474d08('0x1b27'),'pull':'clone'},'animation':0x64,'sort':![]},_0x8f6c34['applications']={'group':{'name':_0x474d08('0x103e'),'put':'opt1'},'animation':0x64,'onAdd':function(_0x459b12){_0x5dcbcc(_0x459b12,_0x459b12['newIndex']);},'onSort':function(){_0x358953();}},_0x8f6c34[_0x474d08('0x24d5')]=_0x580497,_0x8f6c34[_0x474d08('0x8a2')]=_0x2ddbda,_0x8f6c34[_0x474d08('0x1927')]=_0x471911,_0x8f6c34[_0x474d08('0x5b4')]=_0x5dcbcc,_0x8f6c34[_0x474d08('0x1a93')]=_0x40c3e4,_0x8f6c34[_0x474d08('0x2830')]=_0x3aada9,_0x8f6c34[_0x474d08('0x1920')]=_0x1c69f8,_0x8f6c34[_0x474d08('0x20a6')]=_0x358953,_0x8f6c34['getIntervals']=_0x3b60ea;function _0x580497(_0x324dca,_0xa76637){const _0x8cdce1=_0x474d08;_0x8f6c34[_0x8cdce1('0xcc5')]=_0x324dca,_0x8f6c34[_0x8cdce1('0x243c')]=typeof _0xa76637!=='undefined'?_0xa76637:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x8f6c34['applications'][_0x8cdce1('0xbd0')]=!_0x8f6c34[_0x8cdce1('0x243c')][_0x8cdce1('0x1684')]?!![]:![],_0x8f6c34[_0x8cdce1('0x2218')]['id']=_0x324dca['id'],_0x8f6c34['query'][_0x8cdce1('0x1a55')]=!![],_0x8f6c34[_0x8cdce1('0x2218')][_0x8cdce1('0x49d')]=!![],_0x8f6c34[_0x8cdce1('0x1927')](),_0x8f6c34[_0x8cdce1('0x242')]();}function _0x2ddbda(_0x1713bf,_0x4eb243,_0x2d0371){const _0x2d0f75=_0x474d08,_0x4c294a=_0x4fedd9[_0x2d0f75('0x1d26')]()[_0x2d0f75('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20application?')[_0x2d0f75('0xf3c')](_0x2d0f75('0x12b5')+_0x1713bf[_0x2d0f75('0x746')]+'
'+_0x2d0f75('0x3f3'))['ariaLabel']('delete\x20application')[_0x2d0f75('0x203b')](_0x2d0371)['ok']('OK')['cancel'](_0x2d0f75('0x2d3'));_0x4fedd9[_0x2d0f75('0x1f80')](_0x4c294a)[_0x2d0f75('0x1166')](function(){const _0x55df3a=_0x2d0f75;_0x8f6c34['whatsappAccountApps'][_0x55df3a('0x269a')][_0x55df3a('0x57b')](_0x4eb243,0x1),_0x358953();},function(){console['log']('CANCEL');});}function _0x5dcbcc(_0x4e938c,_0x46ed5c){const _0x4ac104=_0x474d08;if(_0x8f6c34[_0x4ac104('0x4a1')][_0x4ac104('0x269a')][_0x4ac104('0x264b')]){const _0x17d261=_0x8f6c34[_0x4ac104('0x4a1')]['rows'][_0x46ed5c]?_0x8f6c34['whatsappAccountApps'][_0x4ac104('0x269a')][_0x46ed5c]:_0x8f6c34[_0x4ac104('0x4a1')][_0x4ac104('0x269a')][0x0],_0xda6cff=(_0x17d261[_0x4ac104('0x83f')]||_0x17d261[_0x4ac104('0x746')])[_0x4ac104('0x2574')]();_0x4fedd9[_0x4ac104('0x1f80')]({'controller':_0x4ac104('0x1d5')+_0xda6cff+_0x4ac104('0x8a4'),'controllerAs':'vm','templateUrl':_0x374044[_0xda6cff],'parent':angular[_0x4ac104('0x1194')](_0x2832bd[_0x4ac104('0x8d2')]),'targetEvent':_0x4e938c,'clickOutsideToClose':!![],'locals':{'whatsappAccountApp':_0x17d261,'whatsappAccount':_0x8f6c34['whatsappAccount'],'crudPermissions':_0x8f6c34[_0x4ac104('0x243c')]}})[_0x4ac104('0x1166')](function(_0x367173){const _0x2ec00c=_0x4ac104;_0x367173&&(_0x367173['id']?_0x8f6c34[_0x2ec00c('0x4a1')][_0x2ec00c('0x269a')][_0x46ed5c]=_0x367173:_0x8f6c34['whatsappAccountApps'][_0x2ec00c('0x269a')]['splice'](_0x46ed5c,0x0,_0x367173),_0x358953());})[_0x4ac104('0x1a80')](function(_0x2f9ac6){const _0x368d3b=_0x4ac104;_0x2f9ac6&&_0x47296b[_0x368d3b('0xfc9')]({'title':_0x2f9ac6[_0x368d3b('0x52d')]?_0x368d3b('0x1e21')+_0x2f9ac6[_0x368d3b('0x52d')]+'\x20-\x20'+_0x2f9ac6[_0x368d3b('0xe1b')]:_0x368d3b('0x2e5'),'msg':_0x2f9ac6['data']?JSON[_0x368d3b('0xbac')](_0x2f9ac6[_0x368d3b('0x25f4')]):_0x2f9ac6[_0x368d3b('0x1586')]()});});}}function _0x40c3e4(_0x187dee,_0x25fde0){const _0x807578=_0x474d08;if(_0x8f6c34[_0x807578('0x4a1')][_0x807578('0x269a')][_0x807578('0x264b')]){const _0x85736b=_0x8f6c34[_0x807578('0x4a1')][_0x807578('0x269a')][_0x25fde0]?_0x8f6c34[_0x807578('0x4a1')][_0x807578('0x269a')][_0x25fde0]:_0x8f6c34['whatsappAccountApps'][_0x807578('0x269a')][0x0];_0x4fedd9[_0x807578('0x1f80')]({'controller':_0x807578('0x895'),'controllerAs':'vm','templateUrl':_0x20ebfe,'parent':angular[_0x807578('0x1194')](_0x2832bd[_0x807578('0x8d2')]),'targetEvent':_0x187dee,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x85736b['interval'],'IntervalId':_0x85736b[_0x807578('0x186f')],'application':!![]},'intervals':[],'crudPermissions':_0x8f6c34[_0x807578('0x243c')]}})['then'](function(_0x81567c){const _0x3ab08b=_0x807578;_0x81567c&&(_0x85736b[_0x3ab08b('0x277c')]=_0x81567c[_0x3ab08b('0x277c')]||_0x3ab08b('0x16f'),_0x85736b[_0x3ab08b('0x186f')]=_0x81567c[_0x3ab08b('0x186f')]||null,_0x358953());});}}function _0x358953(){const _0x357b95=_0x474d08;let _0x115a19=0x1,_0x907ee1=[];for(let _0x24ff2b=0x0;_0x24ff2b<_0x8f6c34[_0x357b95('0x4a1')][_0x357b95('0x269a')][_0x357b95('0x264b')];_0x24ff2b++){const _0x11b695=_0x8f6c34[_0x357b95('0x4a1')][_0x357b95('0x269a')][_0x24ff2b],_0x416a76=[],_0x127a31=[];_0x11b695[_0x357b95('0x164e')]=_0x11b695[_0x357b95('0x277c')]!=='*,*,*,*'?[_0x11b695[_0x357b95('0x277c')]]:_0x11b695[_0x357b95('0x186f')]?_0x2cfb05()[_0x357b95('0x2563')](_0x2cfb05()[_0x357b95('0x1c33')](_0x8f6c34[_0x357b95('0x164e')]['rows'],{'IntervalId':_0x11b695[_0x357b95('0x186f')]}),_0x357b95('0x277c')):[],_0x11b695[_0x357b95('0xe1c')]=_0x8f6c34[_0x357b95('0xcc5')]['context'],_0x11b695[_0x357b95('0x23ae')]=_0x8f6c34[_0x357b95('0xcc5')][_0x357b95('0x23ae')],_0x11b695[_0x357b95('0x1345')]&&(_0x11b695['type']=_0x11b695[_0x357b95('0x1345')]['toLowerCase']()),_0x11b695[_0x357b95('0xfde')]=_0x416a76['length']?_0x2cfb05()[_0x357b95('0x1ef5')](_0x416a76)[_0x357b95('0xfde')]+0x1:_0x115a19,_0x115a19=(_0x127a31[_0x357b95('0x264b')]?_0x2cfb05()[_0x357b95('0x1ef5')](_0x127a31)[_0x357b95('0xfde')]:_0x11b695[_0x357b95('0xfde')])+0x1,_0x907ee1=_0x2cfb05()[_0x357b95('0x1c6a')](_0x907ee1,_0x416a76,[_0x11b695],_0x127a31);}_0x28ad1b[_0x357b95('0xcc5')][_0x357b95('0x153b')]({'id':_0x8f6c34['whatsappAccount']['id']},_0x2cfb05()['sortBy'](_0x907ee1,_0x357b95('0xfde')))['$promise']['then'](function(_0x246c24){const _0x146833=_0x357b95;_0x8f6c34[_0x146833('0x4a1')][_0x146833('0x269a')]=_0x246c24['rows'];})[_0x357b95('0x1a80')](function(_0x2389b5){console['error'](_0x2389b5);});}function _0x1d4398(_0xf2ba2e){const _0x7a2b48=_0x474d08;_0x8f6c34[_0x7a2b48('0x4a1')]=_0xf2ba2e||{'count':0x0,'rows':[]};}function _0x3b60ea(){const _0x569c4d=_0x474d08;return _0x28ad1b['interval'][_0x569c4d('0xd83')]({'fields':'id,interval,IntervalId'})[_0x569c4d('0xa44')][_0x569c4d('0x1166')](function(_0x3173d9){const _0x5267dd=_0x569c4d;_0x8f6c34[_0x5267dd('0x164e')]=_0x3173d9;})[_0x569c4d('0x1a80')](function(_0x555160){const _0x4b9d8a=_0x569c4d;console[_0x4b9d8a('0xfc9')](_0x555160);});}function _0x471911(){const _0x2179f4=_0x474d08;_0x8f6c34[_0x2179f4('0x1f48')]=_0x28ad1b[_0x2179f4('0xcc5')]['getApplications'](_0x8f6c34['query'],_0x1d4398)['$promise'];}function _0x3aada9(_0x1e0897){const _0x36c268=_0x474d08;_0x2cfb05()[_0x36c268('0x127f')](_0x8f6c34[_0x36c268('0x4a1')]['rows'],{'id':_0x1e0897['id']}),_0x358953(),_0x47296b['success']({'title':_0x36c268('0x11c0'),'msg':_0x1e0897[_0x36c268('0x746')]?_0x1e0897[_0x36c268('0x746')]+_0x36c268('0x7cd'):''});}function _0x1c69f8(_0x4ab8e9){const _0x395dce=_0x474d08,_0x383205=_0x4fedd9[_0x395dce('0x1d26')]()['title'](_0x395dce('0x2338'))[_0x395dce('0xf3c')](_0x395dce('0x12b5')+_0x8f6c34[_0x395dce('0x1d0d')][_0x395dce('0x264b')]+_0x395dce('0x196d')+_0x395dce('0x3f3'))['ariaLabel'](_0x395dce('0x106e'))[_0x395dce('0x203b')](_0x4ab8e9)['ok']('OK')[_0x395dce('0x3f')](_0x395dce('0x2d3'));_0x4fedd9[_0x395dce('0x1f80')](_0x383205)[_0x395dce('0x1166')](function(){const _0x3520ec=_0x395dce;_0x8f6c34[_0x3520ec('0x1d0d')]['forEach'](function(_0xe48829){const _0x50e92a=_0x3520ec;_0x2cfb05()['remove'](_0x8f6c34[_0x50e92a('0x4a1')][_0x50e92a('0x269a')],{'id':_0xe48829['id']});}),_0x8f6c34[_0x3520ec('0x1d0d')]=[],_0x358953();});}}const _0x4c608b=_0x3e51e1;_0x57b8d3[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0xcc5'),'whatsappAccounts',_0x36e6f4('0xf01'),'$translate',_0x36e6f4('0x21ef'),'crudPermissions'];function _0x57b8d3(_0x49590a,_0x57e0ba,_0x211d76,_0x335497,_0x4917ec,_0x1e2363,_0x43a712,_0x3cb10b,_0x310022,_0x19244a){const _0x38e60d=_0x36e6f4,_0x5089eb=this;_0x5089eb[_0x38e60d('0x98')]=_0x310022[_0x38e60d('0x26cd')](),_0x5089eb[_0x38e60d('0xcc5')]=_0x4917ec,_0x5089eb[_0x38e60d('0x243c')]=_0x19244a,_0x5089eb['realtime']=_0x43a712,_0x5089eb[_0x38e60d('0xbd7')]=[],_0x5089eb[_0x38e60d('0x10ab')]=[],_0x5089eb[_0x38e60d('0x18e1')]=[],_0x5089eb[_0x38e60d('0x2111')]=[],_0x5089eb[_0x38e60d('0x2781')]=[],_0x5089eb['pendingChanges']=![],_0x5089eb[_0x38e60d('0xae0')]=_0x484bd5,_0x5089eb[_0x38e60d('0x1d92')]=_0x10db42,_0x5089eb['closeDialog']=_0x4ecdca,_0x5089eb[_0x38e60d('0xc68')]={'readOnly':!_0x5089eb[_0x38e60d('0x243c')]['canEdit'],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x38e60d('0x4f0'),'line1':_0x38e60d('0x6e1'),'line2':[_0x38e60d('0x4f0'),'internal'],'line3':'','labelAll':_0x3cb10b[_0x38e60d('0x25cc')]('WHATSAPP.ALL_AGENTS'),'labelSelected':_0x3cb10b[_0x38e60d('0x25cc')]('WHATSAPP.SELECTED_AGENTS'),'transferCallback':function(){const _0xc50226=_0x38e60d,_0x36f9db=_0x2cfb05()[_0xc50226('0x2802')](_0x5089eb[_0xc50226('0x2781')],_0x5089eb['selectedItems'],'id');_0x5089eb[_0xc50226('0x14d7')]=_0x2cfb05()['isEmpty'](_0x36f9db)?![]:!![];}};function _0x484bd5(){const _0x54ea16=_0x38e60d;return _0x310022[_0x54ea16('0x1ac6')](_0x54ea16('0xa7c'))?_0x57bd23()[_0x54ea16('0x1a80')](function(_0x1cdc21){const _0x2f7b57=_0x54ea16;_0x211d76['error']({'title':_0x1cdc21['status']?_0x2f7b57('0x1e21')+_0x1cdc21[_0x2f7b57('0x52d')]+_0x2f7b57('0x11e1')+_0x1cdc21['statusText']:_0x2f7b57('0xd4c'),'msg':_0x1cdc21[_0x2f7b57('0x52d')]?JSON[_0x2f7b57('0xbac')](_0x1cdc21[_0x2f7b57('0x25f4')]):_0x1cdc21[_0x2f7b57('0x1586')]()});}):_0x104da3()[_0x54ea16('0x1166')](function(_0x107be0){const _0x24ccb5=_0x54ea16;return _0x5089eb[_0x24ccb5('0xe60')]=_0x107be0,_0x57bd23();})[_0x54ea16('0x1a80')](function(_0xa3c613){const _0x30a348=_0x54ea16;_0x211d76[_0x30a348('0xfc9')]({'title':_0xa3c613[_0x30a348('0x52d')]?_0x30a348('0x1e21')+_0xa3c613[_0x30a348('0x52d')]+_0x30a348('0x11e1')+_0xa3c613[_0x30a348('0xe1b')]:_0x30a348('0xd4c'),'msg':_0xa3c613['status']?JSON[_0x30a348('0xbac')](_0xa3c613[_0x30a348('0x25f4')]):_0xa3c613[_0x30a348('0x1586')]()});});}function _0x104da3(){return _0x57e0ba(function(_0x4bc5d2,_0x4b9ff3){const _0x93cbb2=a0_0x3f2c;_0x335497[_0x93cbb2('0x17aa')][_0x93cbb2('0xd83')]({'userProfileId':_0x5089eb[_0x93cbb2('0x98')]['userProfileId'],'name':_0x93cbb2('0x2391')})[_0x93cbb2('0xa44')][_0x93cbb2('0x1166')](function(_0x51d43d){const _0x2374c7=_0x93cbb2,_0x1fb505=_0x51d43d&&_0x51d43d['rows']?_0x51d43d[_0x2374c7('0x269a')][0x0]:null;_0x4bc5d2(_0x1fb505);})['catch'](function(_0x3b7456){_0x4b9ff3(_0x3b7456);});});}function _0x57bd23(){return _0x57e0ba(function(_0x4c949a,_0x1c18f6){const _0x2b6594=a0_0x3f2c;return _0x3331f5()[_0x2b6594('0x1166')](function(_0x1a685e){const _0x5e948a=_0x2b6594;return _0x5089eb[_0x5e948a('0xbd7')]=_0x1a685e[_0x5e948a('0x269a')]?_0x1a685e[_0x5e948a('0x269a')]:[],_0x310022['hasRole'](_0x5e948a('0xa7c'))?_0x1a685e:_0x5089eb['section']?_0x5089eb[_0x5e948a('0xe60')]['autoAssociation']?_0x1a685e:_0x55ea19():null;})[_0x2b6594('0x1166')](function(_0x2e1316){const _0x45c287=_0x2b6594,_0x29a519=_0x2e1316&&_0x2e1316['rows']?_0x2e1316[_0x45c287('0x269a')]:[];return _0x5089eb[_0x45c287('0x10ab')]=_0x2cfb05()['map'](_0x29a519,function(_0x131fdb){const _0xaacef5=_0x45c287;return _0x2cfb05()[_0xaacef5('0xc38')](_0x5089eb[_0xaacef5('0xbd7')],{'id':_0x310022[_0xaacef5('0x1ac6')]('admin')||_0x5089eb[_0xaacef5('0xe60')][_0xaacef5('0x1a2b')]?_0x131fdb['id']:_0x131fdb[_0xaacef5('0x24e8')]});}),_0x5089eb[_0x45c287('0x2111')]=angular[_0x45c287('0x225f')](_0x5089eb[_0x45c287('0x10ab')]),_0x5089eb['items'][_0x45c287('0x2782')](function(_0x573e68){const _0x2dfc40=_0x45c287,_0x1d9ee8=_0x2cfb05()[_0x2dfc40('0xc38')](_0x5089eb[_0x2dfc40('0x10ab')],{'id':_0x573e68['id']});_0x310022['hasRole'](_0x2dfc40('0xa7c'))?_0x573e68[_0x2dfc40('0x26ef')]=!![]:_0x573e68[_0x2dfc40('0x26ef')]=typeof _0x1d9ee8!==_0x2dfc40('0x1048')?!![]:![];}),_0x47be4f();})['then'](function(_0x3a033f){const _0x39e0a6=_0x2b6594,_0x456609=_0x3a033f&&_0x3a033f[_0x39e0a6('0x269a')]?_0x3a033f['rows']:[];_0x5089eb[_0x39e0a6('0x18e1')]=_0x2cfb05()[_0x39e0a6('0x2563')](_0x456609,function(_0xca5680){const _0x2e9136=_0x39e0a6,_0x4c86cd=_0x2cfb05()['find'](_0x5089eb[_0x2e9136('0xbd7')],{'id':_0xca5680['id']});return _0x4c86cd[_0x2e9136('0x23af')]=_0xca5680[_0x2e9136('0xec9')]?_0x2e9136('0x11e8')+_0xca5680[_0x2e9136('0xec9')][_0x2e9136('0x23af')]:'',_0x4c86cd[_0x2e9136('0x1eef')]=typeof _0xca5680[_0x2e9136('0x1eef')]!==_0x2e9136('0x1048')?'<'+_0xca5680[_0x2e9136('0x1eef')]+'>':'',_0x4c86cd;}),_0x5089eb['startingSelectedItems']=angular['copy'](_0x5089eb[_0x39e0a6('0x18e1')]),_0x5089eb[_0x39e0a6('0xc68')]['selectedItems']=_0x5089eb['selectedItems'],_0x5089eb[_0x39e0a6('0xc68')][_0x39e0a6('0xbd7')]=_0x2cfb05()[_0x39e0a6('0x24ac')](_0x5089eb[_0x39e0a6('0x10ab')],_0x5089eb['dualMultiselectOptions'][_0x39e0a6('0x18e1')],'id'),_0x4c949a();})['catch'](function(_0x416291){_0x1c18f6(_0x416291);});});}function _0x55ea19(){return _0x57e0ba(function(_0x171e03,_0x4f2452){const _0xd3521e=a0_0x3f2c;return _0x335497[_0xd3521e('0x4b5')]['get']({'sectionId':_0x5089eb[_0xd3521e('0xe60')]['id'],'nolimit':!![]})['$promise'][_0xd3521e('0x1166')](function(_0x13f37f){_0x171e03(_0x13f37f);})[_0xd3521e('0x1a80')](function(_0xf90d33){_0x4f2452(_0xf90d33);});});}function _0x47be4f(){return _0x57e0ba(function(_0x3709a8,_0x3c9e31){const _0x1769fa=a0_0x3f2c;return _0x335497['whatsappAccount'][_0x1769fa('0x261c')]({'id':_0x5089eb[_0x1769fa('0xcc5')]['id'],'fields':'id,name,internal,fullname','nolimit':!![],'role':_0x1769fa('0x1eff')})[_0x1769fa('0xa44')][_0x1769fa('0x1166')](function(_0x5b1044){_0x3709a8(_0x5b1044);})[_0x1769fa('0x1a80')](function(_0x4fa686){_0x3c9e31(_0x4fa686);});});}function _0x3331f5(){return _0x57e0ba(function(_0x26075c,_0x21bb78){const _0x195256=a0_0x3f2c;return _0x335497[_0x195256('0x557')]['get']({'fields':_0x195256('0x1459'),'nolimit':!![],'role':'agent'})['$promise'][_0x195256('0x1166')](function(_0x59d3ef){_0x26075c(_0x59d3ef);})[_0x195256('0x1a80')](function(_0x139b74){_0x21bb78(_0x139b74);});});}function _0x3d4857(_0x40f3a5){return _0x57e0ba(function(_0x175cf9,_0x3ca689){const _0x132a9f=a0_0x3f2c;_0x2cfb05()['isEmpty'](_0x40f3a5)?_0x175cf9():_0x335497[_0x132a9f('0xcc5')][_0x132a9f('0x275c')]({'id':_0x5089eb[_0x132a9f('0xcc5')]['id'],'ids':_0x2cfb05()['map'](_0x40f3a5,'id')})[_0x132a9f('0xa44')]['then'](function(){_0x175cf9();})[_0x132a9f('0x1a80')](function(_0xba3ca9){_0x3ca689(_0xba3ca9);});});}function _0x465234(_0x54c4cd){return _0x57e0ba(function(_0x37c801,_0x3f4da0){const _0x4e9163=a0_0x3f2c;_0x2cfb05()[_0x4e9163('0x1081')](_0x54c4cd)?_0x37c801():_0x335497[_0x4e9163('0xcc5')][_0x4e9163('0x269d')]({'id':_0x5089eb[_0x4e9163('0xcc5')]['id'],'ids':_0x2cfb05()['map'](_0x54c4cd,'id')})[_0x4e9163('0xa44')][_0x4e9163('0x1166')](function(){_0x37c801();})[_0x4e9163('0x1a80')](function(_0x4512e){_0x3f4da0(_0x4512e);});});}function _0x10db42(){const _0x17e2c8=_0x38e60d,_0x5be55f=_0x2cfb05()[_0x17e2c8('0x24ac')](_0x5089eb['startingSelectedItems'],_0x5089eb[_0x17e2c8('0x18e1')],'id'),_0x4d7c8d=_0x2cfb05()[_0x17e2c8('0x24ac')](_0x5089eb[_0x17e2c8('0x18e1')],_0x5089eb['startingSelectedItems'],'id');return _0x465234(_0x5be55f)[_0x17e2c8('0x1166')](function(){return _0x3d4857(_0x4d7c8d);})[_0x17e2c8('0x1166')](function(){const _0x5c26e8=_0x17e2c8;_0x5089eb[_0x5c26e8('0x14d7')]=![],_0x5089eb[_0x5c26e8('0x2111')]=angular[_0x5c26e8('0x225f')](_0x5089eb['allowedItems']),_0x5089eb[_0x5c26e8('0x2781')]=angular[_0x5c26e8('0x225f')](_0x5089eb['selectedItems']),_0x211d76[_0x5c26e8('0x103b')]({'title':'SUCCESS','msg':'Agents\x20association\x20has\x20been\x20updated!'});})[_0x17e2c8('0x1a80')](function(_0x59c38b){const _0x249736=_0x17e2c8;_0x211d76[_0x249736('0xfc9')]({'title':_0x59c38b[_0x249736('0x52d')]?_0x249736('0x1e21')+_0x59c38b['status']+_0x249736('0x11e1')+_0x59c38b[_0x249736('0xe1b')]:_0x249736('0x1b29'),'msg':_0x59c38b['status']?JSON[_0x249736('0xbac')](_0x59c38b[_0x249736('0x25f4')]):_0x59c38b[_0x249736('0x1586')]()});});}function _0x4ecdca(){_0x49590a['hide']();}}const _0x23ac3c=_0x57b8d3;_0x166f10[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x9d'),'whatsappAccount',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x166f10(_0x259abe,_0x4752dc,_0x374a15,_0x13cf2d,_0x152199,_0x42a9a3,_0xf5de1c,_0x64afae){const _0x1544a3=_0x36e6f4,_0x3ddb2c=this;_0x3ddb2c['currentUser']=_0xf5de1c['getCurrentUser'](),_0x3ddb2c[_0x1544a3('0x61a')]=[],_0x3ddb2c[_0x1544a3('0xcdc')]=_0x1544a3('0xb4a')+(_0x13cf2d['appType']||_0x13cf2d['app'])[_0x1544a3('0x1387')](),_0x3ddb2c[_0x1544a3('0x1eff')]=angular['copy'](_0x13cf2d),_0x3ddb2c[_0x1544a3('0x243c')]=_0x64afae,_0x3ddb2c[_0x1544a3('0x128b')]={};if(_0x3ddb2c[_0x1544a3('0x1eff')]['appdata'])switch(_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x83f')]?_0x3ddb2c[_0x1544a3('0x1eff')]['appType'][_0x1544a3('0x2574')]():_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x746')][_0x1544a3('0x2574')]()){case _0x1544a3('0x2853'):break;case'dialogflow':{const _0x35dc3f=_0x3ddb2c[_0x1544a3('0x1eff')]['appdata'][_0x1544a3('0x25c8')](',');_0x3ddb2c['agent'][_0x1544a3('0x7ca')]=_0x35dc3f[0x0],_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0xedb')]=_0x35dc3f[0x1],_0x3ddb2c['agent']['welcomemessage']=_0x35dc3f[_0x1544a3('0x233')](0x2,_0x35dc3f[_0x1544a3('0x264b')])[_0x1544a3('0x45a')](',');}break;case _0x1544a3('0x1636'):{const _0x1fb3dd=_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x823')]['split'](',');_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x1b0a')]=_0x1fb3dd[0x0],_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x27f3')]=_0x1fb3dd[0x1],_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x170e')]=_0x1fb3dd[0x2],_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0xedb')]=_0x1fb3dd[0x3],_0x3ddb2c['agent']['welcomemessage']=_0x1fb3dd[_0x1544a3('0x233')](0x4,_0x1fb3dd[_0x1544a3('0x264b')])[_0x1544a3('0x45a')](',');}break;case _0x1544a3('0x86c'):{const _0x38273d=_0x3ddb2c[_0x1544a3('0x1eff')]['appdata'][_0x1544a3('0x25c8')](',');_0x3ddb2c['agent'][_0x1544a3('0xee6')]=_0x38273d[0x0],_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x125')]=_0x38273d[0x1],_0x3ddb2c[_0x1544a3('0x1eff')]['lexregion']=_0x38273d[0x2],_0x3ddb2c['agent']['botname']=_0x38273d[0x3],_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x1634')]=_0x38273d[_0x1544a3('0x233')](0x4,_0x38273d[_0x1544a3('0x264b')])[_0x1544a3('0x45a')](',');}break;case _0x1544a3('0x1af7'):{const _0x299d31=_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x823')][_0x1544a3('0x25c8')](',');_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x265e')]=isNaN(_0x299d31[0x0])?_0x299d31[0x0]:parseInt(_0x299d31[0x0],0xa),_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x1640')]=_0x299d31[_0x1544a3('0x233')](0x1,_0x299d31[_0x1544a3('0x264b')])[_0x1544a3('0x45a')](',');}break;case _0x1544a3('0x1e70'):_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x1640')]=_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x823')];break;case _0x1544a3('0xceb'):_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x4f0')]=_0x3ddb2c[_0x1544a3('0x1eff')]['appdata'][_0x1544a3('0x25c8')]('=')[0x0],_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x18e0')]=_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x823')][_0x1544a3('0x25c8')]('=')[0x1];break;case _0x1544a3('0x1034'):_0x3ddb2c['agent'][_0x1544a3('0x2588')]=_0x3ddb2c['agent'][_0x1544a3('0x823')];break;default:{const _0x563299=_0x3ddb2c[_0x1544a3('0x1eff')]['appdata'][_0x1544a3('0x25c8')](',');_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x1eff')]=_0x2cfb05()[_0x1544a3('0x1081')](_0x563299[0x0])?_0x563299[0x0]:isNaN(_0x563299[0x0])?_0x563299[0x0]:parseInt(_0x563299[0x0],0xa),_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x651')]=_0x2cfb05()['isEmpty'](_0x563299[0x1])?_0x563299[0x1]:isNaN(_0x563299[0x1])?_0x563299[0x1]:parseInt(_0x563299[0x1],0xa);}break;}else _0x3ddb2c['agent'][_0x1544a3('0x651')]=0x1e;_0x3ddb2c['agent']['type']&&_0x3ddb2c['agent']['type']['toLowerCase']()===_0x1544a3('0x587')&&_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x83f')][_0x1544a3('0x2574')]()==='outbounddial'&&(_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x265a')]=_0x3ddb2c['agent'][_0x1544a3('0x2026')]?_0x3ddb2c['agent'][_0x1544a3('0x2026')][_0x1544a3('0x25c8')]('$')[0x0]:undefined,_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x1f02')]=_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x992')]?_0x1544a3('0xa4c')+_0x3ddb2c[_0x1544a3('0x1eff')][_0x1544a3('0x992')]:undefined);_0x3ddb2c[_0x1544a3('0xf14')]=_0x23dbf9,_0x3ddb2c[_0x1544a3('0x24a0')]=_0x3849a8,_0xf5de1c[_0x1544a3('0x1ac6')](_0x1544a3('0xa7c'))?_0x42a9a3[_0x1544a3('0x557')]['get']({'fields':'id,name','sort':_0x1544a3('0x4f0'),'nolimit':_0x1544a3('0xf3b'),'role':_0x1544a3('0x1eff')})['$promise'][_0x1544a3('0x1166')](function(_0x2894db){const _0x502c44=_0x1544a3;_0x3ddb2c[_0x502c44('0x1f7e')]=_0x2894db[_0x502c44('0x269a')]||[];})['catch'](function(_0x5d5cd4){const _0x4756fe=_0x1544a3;_0x374a15[_0x4756fe('0xfc9')]({'title':_0x5d5cd4[_0x4756fe('0x52d')]?_0x4756fe('0x1e21')+_0x5d5cd4['status']+_0x4756fe('0x11e1')+_0x5d5cd4[_0x4756fe('0xe1b')]:_0x4756fe('0xd4c'),'msg':_0x5d5cd4[_0x4756fe('0x25f4')]?JSON[_0x4756fe('0xbac')](_0x5d5cd4['data']):_0x5d5cd4[_0x4756fe('0x1586')]()});}):_0x42a9a3[_0x1544a3('0x557')][_0x1544a3('0xd83')]({'fields':'id,name','sort':_0x1544a3('0x4f0'),'nolimit':_0x1544a3('0xf3b'),'role':'agent'})[_0x1544a3('0xa44')]['then'](function(_0x321810){const _0x61e73f=_0x1544a3;_0x3ddb2c['agents']=_0x321810[_0x61e73f('0x269a')]||[];})['then'](function(){const _0x466f48=_0x1544a3;return _0x42a9a3[_0x466f48('0x17aa')][_0x466f48('0xd83')]({'userProfileId':_0x3ddb2c[_0x466f48('0x98')]['userProfileId'],'sectionId':0xca})[_0x466f48('0xa44')];})[_0x1544a3('0x1166')](function(_0x366eaa){const _0x408768=_0x1544a3,_0x3dbae1=_0x366eaa&&_0x366eaa['rows']?_0x366eaa[_0x408768('0x269a')][0x0]:null;if(!_0x3dbae1){const _0x25caa5=[];let _0x3b375a=null;_0x3ddb2c[_0x408768('0x1eff')]&&(_0x3b375a=_0x2cfb05()[_0x408768('0xc38')](_0x3ddb2c[_0x408768('0x1f7e')],{'name':_0x3ddb2c['agent'][_0x408768('0x1eff')]}));for(let _0x2067e1=0x0;_0x2067e1<_0x3ddb2c['agents'][_0x408768('0x264b')];_0x2067e1++){_0x3b375a&&_0x3ddb2c[_0x408768('0x1f7e')][_0x2067e1]['id']===_0x3b375a['id']&&(_0x3ddb2c[_0x408768('0x1f7e')][_0x2067e1][_0x408768('0x2378')]=![],_0x25caa5[_0x408768('0x1514')](_0x3ddb2c[_0x408768('0x1f7e')][_0x2067e1]));}_0x3ddb2c[_0x408768('0x1f7e')]=_0x25caa5;}else{if(!_0x3dbae1[_0x408768('0x1a2b')])return _0x42a9a3[_0x408768('0x4b5')]['get']({'sectionId':_0x3dbae1['id']})['$promise']['then'](function(_0x32e3ff){const _0x561a4f=_0x408768,_0x2dc398=_0x2cfb05()['map'](_0x32e3ff[_0x561a4f('0x269a')],function(_0x536af6){const _0xad7367=_0x561a4f;return _0x2cfb05()[_0xad7367('0xc38')](_0x3ddb2c[_0xad7367('0x1f7e')],{'id':_0x536af6[_0xad7367('0x24e8')]});});let _0x30044f=null;_0x3ddb2c[_0x561a4f('0x1eff')]&&(_0x30044f=_0x2cfb05()[_0x561a4f('0xc38')](_0x3ddb2c[_0x561a4f('0x1f7e')],{'name':_0x3ddb2c['agent'][_0x561a4f('0x1eff')]}));if(_0x30044f&&!_0x2cfb05()['some'](_0x2dc398,['id',_0x30044f['id']])){const _0x1c43ed=_0x2cfb05()[_0x561a4f('0xc38')](_0x3ddb2c[_0x561a4f('0x1f7e')],{'id':_0x30044f['id']});_0x1c43ed[_0x561a4f('0x2378')]=![],_0x2dc398[_0x561a4f('0x1514')](_0x1c43ed);}_0x3ddb2c['agents']=_0x2dc398;});}})[_0x1544a3('0x1a80')](function(_0x1eeef7){const _0x425e6b=_0x1544a3;_0x374a15[_0x425e6b('0xfc9')]({'title':_0x1eeef7['status']?'API:'+_0x1eeef7[_0x425e6b('0x52d')]+_0x425e6b('0x11e1')+_0x1eeef7[_0x425e6b('0xe1b')]:_0x425e6b('0xdc5'),'msg':_0x1eeef7['data']?JSON[_0x425e6b('0xbac')](_0x1eeef7[_0x425e6b('0x25f4')]):_0x1eeef7[_0x425e6b('0x1586')]()});});function _0x23dbf9(){const _0xd5a436=_0x1544a3;_0x3ddb2c[_0xd5a436('0x61a')]=[];const _0x138870=[];_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0x1345')]&&_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0x1345')][_0xd5a436('0x2574')]()==='outbound'&&_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0x83f')]===_0xd5a436('0x867')&&(_0x3ddb2c[_0xd5a436('0x1eff')]['phone']=_0x152199[_0xd5a436('0x2848')]?(_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0x265a')]||'')+_0xd5a436('0x881')+_0x152199[_0xd5a436('0x2848')]+'}':(_0x3ddb2c['agent'][_0xd5a436('0x265a')]||'')+_0xd5a436('0x1d1'),_0x152199[_0xd5a436('0x28cb')]!=='none'?_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0xd39')][_0xd5a436('0x2379')](_0xd5a436('0x1059'))<0x0&&(_0x3ddb2c[_0xd5a436('0x1eff')]['options']+='U(xcally-mixmonitor-context)'):_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0xd39')]=_0x3ddb2c['agent'][_0xd5a436('0xd39')]['replace'](_0xd5a436('0x1059'),''));const _0x45f8b8=_0x2cfb05()['find'](_0x3ddb2c[_0xd5a436('0x1f7e')],{'name':_0x3ddb2c['agent'][_0xd5a436('0x1eff')]});_0x45f8b8&&(_0x3ddb2c[_0xd5a436('0x1eff')]['UserId']=_0x45f8b8['id']);if(_0x3ddb2c[_0xd5a436('0x1eff')]['appType']&&_0x3ddb2c['agent'][_0xd5a436('0x83f')]===_0xd5a436('0x2853')){}else switch((_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0x746')]||_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0x83f')])['toLowerCase']()){case _0xd5a436('0xceb'):_0x3ddb2c[_0xd5a436('0x1eff')]['appdata']=_0x3ddb2c[_0xd5a436('0x1eff')]['name']+'='+_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0x18e0')];break;case _0xd5a436('0x2853'):break;default:_0x138870[0x0]=_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0x1eff')],_0x138870[0x1]=_0x3ddb2c[_0xd5a436('0x1eff')][_0xd5a436('0x651')],_0x3ddb2c['agent'][_0xd5a436('0x823')]=_0x138870[_0xd5a436('0x45a')](',');}_0x3849a8(_0x3ddb2c[_0xd5a436('0x1eff')]);}function _0x3849a8(_0x6b99b9){const _0x48ddc3=_0x1544a3;_0x259abe[_0x48ddc3('0x1197')](_0x6b99b9);}}const _0x5e79d5=_0x166f10;_0x1f7be6[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),'whatsappAccountApp',_0x36e6f4('0xcc5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x1f7be6(_0x52fb00,_0x2d8421,_0x9c107c,_0x1b2f6b,_0x462c42,_0x6378bb,_0x17670a,_0x47919c){const _0x5c4903=_0x36e6f4,_0x1b65e3=this;_0x1b65e3['currentUser']=_0x17670a[_0x5c4903('0x26cd')](),_0x1b65e3[_0x5c4903('0x61a')]=[],_0x1b65e3[_0x5c4903('0xcdc')]=_0x5c4903('0xb4a')+(_0x1b2f6b[_0x5c4903('0x83f')]||_0x1b2f6b[_0x5c4903('0x746')])[_0x5c4903('0x1387')](),_0x1b65e3[_0x5c4903('0x86c')]=angular[_0x5c4903('0x225f')](_0x1b2f6b),_0x1b65e3[_0x5c4903('0x243c')]=_0x47919c,_0x1b65e3[_0x5c4903('0x128b')]={};if(_0x1b65e3['amazonlex'][_0x5c4903('0x823')])switch(_0x1b65e3['amazonlex'][_0x5c4903('0x83f')]?_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x83f')]['toLowerCase']():_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x746')][_0x5c4903('0x2574')]()){case _0x5c4903('0x2853'):break;case _0x5c4903('0xded'):{const _0x534314=_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x823')]['split'](',');_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x7ca')]=_0x534314[0x0],_0x1b65e3[_0x5c4903('0x86c')]['language']=_0x534314[0x1],_0x1b65e3['amazonlex']['welcomemessage']=_0x534314[_0x5c4903('0x233')](0x2,_0x534314[_0x5c4903('0x264b')])[_0x5c4903('0x45a')](',');}break;case _0x5c4903('0x1636'):{const _0xff52ed=_0x1b65e3['amazonlex'][_0x5c4903('0x823')][_0x5c4903('0x25c8')](',');_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x1b0a')]=_0xff52ed[0x0],_0x1b65e3['amazonlex'][_0x5c4903('0x27f3')]=_0xff52ed[0x1],_0x1b65e3[_0x5c4903('0x86c')]['privateKey']=_0xff52ed[0x2],_0x1b65e3['amazonlex']['language']=_0xff52ed[0x3],_0x1b65e3[_0x5c4903('0x86c')]['welcomemessage']=_0xff52ed[_0x5c4903('0x233')](0x4,_0xff52ed[_0x5c4903('0x264b')])['join'](',');}break;case'amazonlex':{const _0x134ef1=_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x823')][_0x5c4903('0x25c8')](',');_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0xee6')]=_0x134ef1[0x0],_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x125')]=_0x134ef1[0x1],_0x1b65e3['amazonlex'][_0x5c4903('0x25a2')]=_0x134ef1[0x2],_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x1ac4')]=_0x134ef1[0x3],_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x1634')]=_0x134ef1['slice'](0x4,_0x134ef1[_0x5c4903('0x264b')])[_0x5c4903('0x45a')](',');}break;case _0x5c4903('0x1af7'):{const _0x4899ac=_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x823')]['split'](',');_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x265e')]=isNaN(_0x4899ac[0x0])?_0x4899ac[0x0]:parseInt(_0x4899ac[0x0],0xa),_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x1640')]=_0x4899ac[_0x5c4903('0x233')](0x1,_0x4899ac[_0x5c4903('0x264b')])[_0x5c4903('0x45a')](',');}break;case _0x5c4903('0x1e70'):_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x1640')]=_0x1b65e3['amazonlex'][_0x5c4903('0x823')];break;case _0x5c4903('0xceb'):_0x1b65e3['amazonlex'][_0x5c4903('0x4f0')]=_0x1b65e3[_0x5c4903('0x86c')]['appdata'][_0x5c4903('0x25c8')]('=')[0x0],_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x18e0')]=_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x823')]['split']('=')[0x1];break;case _0x5c4903('0x1034'):_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x2588')]=_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x823')];break;default:{const _0x2022c1=_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x823')][_0x5c4903('0x25c8')](',');_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0xee6')]=_0x2cfb05()['isEmpty'](_0x2022c1[0x0])?_0x2022c1[0x0]:isNaN(_0x2022c1[0x0])?_0x2022c1[0x0]:parseInt(_0x2022c1[0x0],0xa),_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x125')]=_0x2cfb05()[_0x5c4903('0x1081')](_0x2022c1[0x1])?_0x2022c1[0x1]:isNaN(_0x2022c1[0x1])?_0x2022c1[0x1]:parseInt(_0x2022c1[0x1],0xa),_0x1b65e3[_0x5c4903('0x86c')]['lexregion']=_0x2cfb05()[_0x5c4903('0x1081')](_0x2022c1[0x2])?_0x2022c1[0x2]:isNaN(_0x2022c1[0x2])?_0x2022c1[0x2]:parseInt(_0x2022c1[0x2],0xa),_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x1ac4')]=_0x2cfb05()[_0x5c4903('0x1081')](_0x2022c1[0x3])?_0x2022c1[0x3]:isNaN(_0x2022c1[0x3])?_0x2022c1[0x3]:parseInt(_0x2022c1[0x3],0xa),_0x1b65e3['amazonlex']['welcomemessage']=_0x2cfb05()['isEmpty'](_0x2022c1[0x4])?_0x2022c1[0x4]:isNaN(_0x2022c1[0x4])?_0x2022c1[0x4]:parseInt(_0x2022c1[0x4],0xa);}break;}else _0x1b65e3[_0x5c4903('0x86c')]['lexregion']=_0x5c4903('0x1039');_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x1345')]&&_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x1345')][_0x5c4903('0x2574')]()===_0x5c4903('0x587')&&_0x1b65e3['amazonlex'][_0x5c4903('0x83f')][_0x5c4903('0x2574')]()===_0x5c4903('0x2884')&&(_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x265a')]=_0x1b65e3['amazonlex'][_0x5c4903('0x2026')]?_0x1b65e3['amazonlex']['phone'][_0x5c4903('0x25c8')]('$')[0x0]:undefined,_0x1b65e3['amazonlex'][_0x5c4903('0x1f02')]=_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x992')]?_0x5c4903('0xa4c')+_0x1b65e3[_0x5c4903('0x86c')][_0x5c4903('0x992')]:undefined);_0x1b65e3[_0x5c4903('0xf14')]=_0x5e0dcf,_0x1b65e3[_0x5c4903('0x24a0')]=_0xd97a82;function _0x5e0dcf(){const _0x29d804=_0x5c4903;_0x1b65e3[_0x29d804('0x61a')]=[];const _0x43a592=[];_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x1345')]&&_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x1345')]['toLowerCase']()===_0x29d804('0x587')&&_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x83f')]==='outboundDial'&&(_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x2026')]=_0x462c42[_0x29d804('0x2848')]?(_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x265a')]||'')+_0x29d804('0x881')+_0x462c42[_0x29d804('0x2848')]+'}':(_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x265a')]||'')+_0x29d804('0x1d1'),_0x462c42[_0x29d804('0x28cb')]!=='none'?_0x1b65e3[_0x29d804('0x86c')]['options']['indexOf']('U(xcally-mixmonitor-context)')<0x0&&(_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0xd39')]+=_0x29d804('0x1059')):_0x1b65e3[_0x29d804('0x86c')]['options']=_0x1b65e3[_0x29d804('0x86c')]['options'][_0x29d804('0xf3')](_0x29d804('0x1059'),''));if(_0x1b65e3['amazonlex']['appType']&&_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x83f')]===_0x29d804('0x2853')){}else switch((_0x1b65e3['amazonlex']['app']||_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x83f')])[_0x29d804('0x2574')]()){case _0x29d804('0xceb'):_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x823')]=_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x4f0')]+'='+_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x18e0')];break;case _0x29d804('0x2853'):break;default:_0x43a592[0x0]=_0x1b65e3[_0x29d804('0x86c')]['accesskeyid'],_0x43a592[0x1]=_0x1b65e3['amazonlex']['secretaccesskey'],_0x43a592[0x2]=_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x25a2')],_0x43a592[0x3]=_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x1ac4')],_0x43a592[0x4]=_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x1634')],_0x1b65e3[_0x29d804('0x86c')][_0x29d804('0x823')]=_0x43a592['join'](',');}_0xd97a82(_0x1b65e3[_0x29d804('0x86c')]);}function _0xd97a82(_0x40fd70){const _0x53b31b=_0x5c4903;_0x52fb00[_0x53b31b('0x1197')](_0x40fd70);}}const _0x4bb52d=_0x1f7be6;_0x457503[_0x36e6f4('0x1294')]=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x9d'),_0x36e6f4('0xcc5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x457503(_0x1d754b,_0xe5f6cd,_0x101953,_0xa2e5a6,_0x12984f,_0x4222b0,_0x54b239,_0x220fb1){const _0x536d8e=_0x36e6f4,_0x176ecc=this;_0x176ecc[_0x536d8e('0x98')]=_0x54b239['getCurrentUser'](),_0x176ecc[_0x536d8e('0x61a')]=[],_0x176ecc[_0x536d8e('0xcdc')]=_0x536d8e('0xb4a')+(_0xa2e5a6[_0x536d8e('0x83f')]||_0xa2e5a6[_0x536d8e('0x746')])['toUpperCase'](),_0x176ecc[_0x536d8e('0x1af7')]=angular[_0x536d8e('0x225f')](_0xa2e5a6),_0x176ecc['crudPermissions']=_0x220fb1,_0x176ecc[_0x536d8e('0x128b')]={};if(_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x823')])switch(_0x176ecc['autoreply']['appType']?_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x83f')][_0x536d8e('0x2574')]():_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x746')][_0x536d8e('0x2574')]()){case'custom':break;case _0x536d8e('0xded'):{const _0x1a1e87=_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x823')]['split'](',');_0x176ecc[_0x536d8e('0x1af7')]['key']=_0x1a1e87[0x0],_0x176ecc['autoreply'][_0x536d8e('0xedb')]=_0x1a1e87[0x1],_0x176ecc['autoreply'][_0x536d8e('0x1634')]=_0x1a1e87[_0x536d8e('0x233')](0x2,_0x1a1e87[_0x536d8e('0x264b')])[_0x536d8e('0x45a')](',');}break;case _0x536d8e('0x1636'):{const _0x3c30db=_0x176ecc['autoreply'][_0x536d8e('0x823')][_0x536d8e('0x25c8')](',');_0x176ecc['autoreply'][_0x536d8e('0x1b0a')]=_0x3c30db[0x0],_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x27f3')]=_0x3c30db[0x1],_0x176ecc[_0x536d8e('0x1af7')]['privateKey']=_0x3c30db[0x2],_0x176ecc['autoreply']['language']=_0x3c30db[0x3],_0x176ecc[_0x536d8e('0x1af7')]['welcomemessage']=_0x3c30db[_0x536d8e('0x233')](0x4,_0x3c30db[_0x536d8e('0x264b')])[_0x536d8e('0x45a')](',');}break;case _0x536d8e('0x86c'):{const _0x214aa7=_0x176ecc['autoreply']['appdata'][_0x536d8e('0x25c8')](',');_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0xee6')]=_0x214aa7[0x0],_0x176ecc['autoreply'][_0x536d8e('0x125')]=_0x214aa7[0x1],_0x176ecc[_0x536d8e('0x1af7')]['lexregion']=_0x214aa7[0x2],_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x1ac4')]=_0x214aa7[0x3],_0x176ecc[_0x536d8e('0x1af7')]['welcomemessage']=_0x214aa7['slice'](0x4,_0x214aa7[_0x536d8e('0x264b')])[_0x536d8e('0x45a')](',');}break;case _0x536d8e('0x1af7'):{const _0x197706=_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x823')]['split'](',');_0x176ecc[_0x536d8e('0x1af7')]['times']=isNaN(_0x197706[0x0])?_0x197706[0x0]:parseInt(_0x197706[0x0],0xa),_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x1640')]=_0x197706['slice'](0x1,_0x197706[_0x536d8e('0x264b')])[_0x536d8e('0x45a')](',');}break;case _0x536d8e('0x1e70'):_0x176ecc['autoreply'][_0x536d8e('0x1640')]=_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x823')];break;case'set':_0x176ecc['autoreply']['name']=_0x176ecc['autoreply'][_0x536d8e('0x823')][_0x536d8e('0x25c8')]('=')[0x0],_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x18e0')]=_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x823')][_0x536d8e('0x25c8')]('=')[0x1];break;case'agi':_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x2588')]=_0x176ecc['autoreply'][_0x536d8e('0x823')];break;default:{const _0x4e3f52=_0x176ecc['autoreply'][_0x536d8e('0x823')][_0x536d8e('0x25c8')](',');_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x265e')]=_0x2cfb05()[_0x536d8e('0x1081')](_0x4e3f52[0x0])?_0x4e3f52[0x0]:isNaN(_0x4e3f52[0x0])?_0x4e3f52[0x0]:parseInt(_0x4e3f52[0x0],0xa),_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x1640')]=_0x2cfb05()[_0x536d8e('0x1081')](_0x4e3f52[0x1])?_0x4e3f52[0x1]:isNaN(_0x4e3f52[0x1])?_0x4e3f52[0x1]:parseInt(_0x4e3f52[0x1],0xa);}break;}else _0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x265e')]=0x1;_0x176ecc['autoreply'][_0x536d8e('0x1345')]&&_0x176ecc['autoreply'][_0x536d8e('0x1345')][_0x536d8e('0x2574')]()===_0x536d8e('0x587')&&_0x176ecc['autoreply'][_0x536d8e('0x83f')][_0x536d8e('0x2574')]()===_0x536d8e('0x2884')&&(_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x265a')]=_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x2026')]?_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x2026')][_0x536d8e('0x25c8')]('$')[0x0]:undefined,_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x1f02')]=_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x992')]?'CALLERID(all)='+_0x176ecc[_0x536d8e('0x1af7')][_0x536d8e('0x992')]:undefined);_0x176ecc[_0x536d8e('0xf14')]=_0x5a8f45,_0x176ecc[_0x536d8e('0x24a0')]=_0x1bf45b;function _0x5a8f45(){const _0x47634d=_0x536d8e;_0x176ecc[_0x47634d('0x61a')]=[];const _0x20360c=[];_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0x1345')]&&_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0x1345')][_0x47634d('0x2574')]()===_0x47634d('0x587')&&_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0x83f')]==='outboundDial'&&(_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0x2026')]=_0x12984f[_0x47634d('0x2848')]?(_0x176ecc[_0x47634d('0x1af7')]['prefix']||'')+'${EXTEN:'+_0x12984f[_0x47634d('0x2848')]+'}':(_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0x265a')]||'')+'${EXTEN}',_0x12984f['recordingFormat']!=='none'?_0x176ecc[_0x47634d('0x1af7')]['options'][_0x47634d('0x2379')](_0x47634d('0x1059'))<0x0&&(_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0xd39')]+=_0x47634d('0x1059')):_0x176ecc['autoreply'][_0x47634d('0xd39')]=_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0xd39')]['replace'](_0x47634d('0x1059'),''));if(_0x176ecc['autoreply'][_0x47634d('0x83f')]&&_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0x83f')]==='custom'){}else switch((_0x176ecc['autoreply'][_0x47634d('0x746')]||_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0x83f')])[_0x47634d('0x2574')]()){case _0x47634d('0xceb'):_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0x823')]=_0x176ecc['autoreply']['name']+'='+_0x176ecc[_0x47634d('0x1af7')]['value'];break;case'custom':break;default:_0x20360c[0x0]=_0x176ecc[_0x47634d('0x1af7')][_0x47634d('0x265e')],_0x20360c[0x1]=_0x176ecc['autoreply'][_0x47634d('0x1640')],_0x176ecc['autoreply'][_0x47634d('0x823')]=_0x20360c['join'](',');}_0x1bf45b(_0x176ecc[_0x47634d('0x1af7')]);}function _0x1bf45b(_0x31e334){const _0x3cb2af=_0x536d8e;_0x1d754b[_0x3cb2af('0x1197')](_0x31e334);}}const _0x178411=_0x457503;_0x564e15[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x9d'),_0x36e6f4('0xcc5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x564e15(_0x490ce8,_0x1d74d9,_0x3f3d48,_0x468323,_0x16616e,_0x399f06,_0x16879d,_0x6bef4){const _0xe86d1=_0x36e6f4,_0xcbfe62=this;_0xcbfe62[_0xe86d1('0x98')]=_0x16879d['getCurrentUser'](),_0xcbfe62[_0xe86d1('0x61a')]=[],_0xcbfe62[_0xe86d1('0xcdc')]=_0xe86d1('0xb4a')+(_0x468323[_0xe86d1('0x83f')]||_0x468323['app'])[_0xe86d1('0x1387')](),_0xcbfe62['close']=angular[_0xe86d1('0x225f')](_0x468323),_0xcbfe62[_0xe86d1('0x243c')]=_0x6bef4,_0xcbfe62[_0xe86d1('0x128b')]={};if(_0xcbfe62[_0xe86d1('0x1a7b')]['appdata'])switch(_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x83f')]?_0xcbfe62['close']['appType']['toLowerCase']():_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x746')][_0xe86d1('0x2574')]()){case _0xe86d1('0x2853'):break;case'dialogflow':{const _0x2e6ab2=_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x823')][_0xe86d1('0x25c8')](',');_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x7ca')]=_0x2e6ab2[0x0],_0xcbfe62['close'][_0xe86d1('0xedb')]=_0x2e6ab2[0x1],_0xcbfe62['close']['welcomemessage']=_0x2e6ab2[_0xe86d1('0x233')](0x2,_0x2e6ab2[_0xe86d1('0x264b')])['join'](',');}break;case'dialogflowv2':{const _0x2628f5=_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x823')]['split'](',');_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x1b0a')]=_0x2628f5[0x0],_0xcbfe62['close'][_0xe86d1('0x27f3')]=_0x2628f5[0x1],_0xcbfe62['close'][_0xe86d1('0x170e')]=_0x2628f5[0x2],_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0xedb')]=_0x2628f5[0x3],_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x1634')]=_0x2628f5[_0xe86d1('0x233')](0x4,_0x2628f5[_0xe86d1('0x264b')])[_0xe86d1('0x45a')](',');}break;case _0xe86d1('0x86c'):{const _0x2cb229=_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x823')][_0xe86d1('0x25c8')](',');_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0xee6')]=_0x2cb229[0x0],_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x125')]=_0x2cb229[0x1],_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x25a2')]=_0x2cb229[0x2],_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x1ac4')]=_0x2cb229[0x3],_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x1634')]=_0x2cb229[_0xe86d1('0x233')](0x4,_0x2cb229[_0xe86d1('0x264b')])['join'](',');}break;case _0xe86d1('0x1af7'):{const _0x8fdaa2=_0xcbfe62[_0xe86d1('0x1a7b')]['appdata']['split'](',');_0xcbfe62['close']['times']=isNaN(_0x8fdaa2[0x0])?_0x8fdaa2[0x0]:parseInt(_0x8fdaa2[0x0],0xa),_0xcbfe62[_0xe86d1('0x1a7b')]['text']=_0x8fdaa2[_0xe86d1('0x233')](0x1,_0x8fdaa2[_0xe86d1('0x264b')])[_0xe86d1('0x45a')](',');}break;case _0xe86d1('0x1e70'):_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x1640')]=_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x823')];break;case _0xe86d1('0xceb'):_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x4f0')]=_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x823')]['split']('=')[0x0],_0xcbfe62[_0xe86d1('0x1a7b')]['value']=_0xcbfe62['close'][_0xe86d1('0x823')][_0xe86d1('0x25c8')]('=')[0x1];break;case _0xe86d1('0x1034'):_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x2588')]=_0xcbfe62[_0xe86d1('0x1a7b')]['appdata'];break;default:{const _0x3455d8=_0xcbfe62['close'][_0xe86d1('0x823')][_0xe86d1('0x25c8')](',');_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x12e8')]=_0x2cfb05()[_0xe86d1('0x1081')](_0x3455d8[0x0])?_0x3455d8[0x0]:isNaN(_0x3455d8[0x0])?_0x3455d8[0x0]:parseInt(_0x3455d8[0x0],0xa);}break;}else{}_0xcbfe62['close'][_0xe86d1('0x1345')]&&_0xcbfe62['close'][_0xe86d1('0x1345')]['toLowerCase']()===_0xe86d1('0x587')&&_0xcbfe62['close']['appType'][_0xe86d1('0x2574')]()===_0xe86d1('0x2884')&&(_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x265a')]=_0xcbfe62['close'][_0xe86d1('0x2026')]?_0xcbfe62['close']['phone'][_0xe86d1('0x25c8')]('$')[0x0]:undefined,_0xcbfe62[_0xe86d1('0x1a7b')]['callerId']=_0xcbfe62[_0xe86d1('0x1a7b')][_0xe86d1('0x992')]?_0xe86d1('0xa4c')+_0xcbfe62['close']['callerID']:undefined);_0xcbfe62['saveWhatsappAccountApp']=_0x494f0e,_0xcbfe62[_0xe86d1('0x24a0')]=_0x56ffd4;function _0x494f0e(){const _0xece9e6=_0xe86d1;_0xcbfe62[_0xece9e6('0x61a')]=[];const _0x5e6afb=[];_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0x1345')]&&_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0x1345')]['toLowerCase']()==='outbound'&&_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0x83f')]===_0xece9e6('0x867')&&(_0xcbfe62['close'][_0xece9e6('0x2026')]=_0x16616e['cutdigits']?(_0xcbfe62['close'][_0xece9e6('0x265a')]||'')+_0xece9e6('0x881')+_0x16616e[_0xece9e6('0x2848')]+'}':(_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0x265a')]||'')+_0xece9e6('0x1d1'),_0x16616e[_0xece9e6('0x28cb')]!==_0xece9e6('0x192')?_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0xd39')][_0xece9e6('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0xcbfe62['close'][_0xece9e6('0xd39')]+=_0xece9e6('0x1059')):_0xcbfe62[_0xece9e6('0x1a7b')]['options']=_0xcbfe62['close'][_0xece9e6('0xd39')]['replace'](_0xece9e6('0x1059'),''));if(_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0x83f')]&&_0xcbfe62[_0xece9e6('0x1a7b')]['appType']==='custom'){}else switch((_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0x746')]||_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0x83f')])[_0xece9e6('0x2574')]()){case'set':_0xcbfe62['close']['appdata']=_0xcbfe62[_0xece9e6('0x1a7b')]['name']+'='+_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0x18e0')];break;case _0xece9e6('0x2853'):break;default:_0x5e6afb[0x0]=_0xcbfe62[_0xece9e6('0x1a7b')][_0xece9e6('0x12e8')],_0xcbfe62[_0xece9e6('0x1a7b')]['appdata']=_0x5e6afb[_0xece9e6('0x45a')](',');}_0x56ffd4(_0xcbfe62[_0xece9e6('0x1a7b')]);}function _0x56ffd4(_0xc6e7ea){const _0x77e2ba=_0xe86d1;_0x490ce8[_0x77e2ba('0x1197')](_0xc6e7ea);}}const _0x1ba77c=_0x564e15;_0x55f684[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q','toasty','whatsappAccountApp',_0x36e6f4('0xcc5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x55f684(_0xdf201d,_0x9e259e,_0x42fdc2,_0x3d19e5,_0x134f8a,_0x4b0b8e,_0x2d5c41,_0x38ffe5){const _0xf85891=_0x36e6f4,_0x4b60be=this;_0x4b60be[_0xf85891('0x98')]=_0x2d5c41[_0xf85891('0x26cd')](),_0x4b60be[_0xf85891('0x61a')]=[],_0x4b60be['title']=_0xf85891('0xb4a')+(_0x3d19e5[_0xf85891('0x83f')]||_0x3d19e5['app'])['toUpperCase'](),_0x4b60be['dialogflow']=angular[_0xf85891('0x225f')](_0x3d19e5),_0x4b60be[_0xf85891('0x243c')]=_0x38ffe5,_0x4b60be[_0xf85891('0x128b')]={};if(_0x4b60be[_0xf85891('0xded')][_0xf85891('0x823')])switch(_0x4b60be[_0xf85891('0xded')][_0xf85891('0x83f')]?_0x4b60be[_0xf85891('0xded')][_0xf85891('0x83f')][_0xf85891('0x2574')]():_0x4b60be[_0xf85891('0xded')][_0xf85891('0x746')]['toLowerCase']()){case'custom':break;case _0xf85891('0xded'):{const _0x54e499=_0x4b60be[_0xf85891('0xded')][_0xf85891('0x823')][_0xf85891('0x25c8')](',');_0x4b60be['dialogflow'][_0xf85891('0x7ca')]=_0x54e499[0x0],_0x4b60be[_0xf85891('0xded')][_0xf85891('0xedb')]=_0x54e499[0x1],_0x4b60be[_0xf85891('0xded')][_0xf85891('0x1634')]=_0x54e499[_0xf85891('0x233')](0x2,_0x54e499[_0xf85891('0x264b')])[_0xf85891('0x45a')](',');}break;case _0xf85891('0x1636'):{const _0x912517=_0x4b60be[_0xf85891('0xded')][_0xf85891('0x823')]['split'](',');_0x4b60be[_0xf85891('0xded')][_0xf85891('0x1b0a')]=_0x912517[0x0],_0x4b60be[_0xf85891('0xded')][_0xf85891('0x27f3')]=_0x912517[0x1],_0x4b60be[_0xf85891('0xded')][_0xf85891('0x170e')]=_0x912517[0x2],_0x4b60be['dialogflow'][_0xf85891('0xedb')]=_0x912517[0x3],_0x4b60be[_0xf85891('0xded')][_0xf85891('0x1634')]=_0x912517[_0xf85891('0x233')](0x4,_0x912517[_0xf85891('0x264b')])[_0xf85891('0x45a')](',');}break;case'amazonlex':{const _0xbd76ab=_0x4b60be['dialogflow'][_0xf85891('0x823')][_0xf85891('0x25c8')](',');_0x4b60be[_0xf85891('0xded')][_0xf85891('0xee6')]=_0xbd76ab[0x0],_0x4b60be[_0xf85891('0xded')]['secretaccesskey']=_0xbd76ab[0x1],_0x4b60be[_0xf85891('0xded')][_0xf85891('0x25a2')]=_0xbd76ab[0x2],_0x4b60be[_0xf85891('0xded')][_0xf85891('0x1ac4')]=_0xbd76ab[0x3],_0x4b60be[_0xf85891('0xded')][_0xf85891('0x1634')]=_0xbd76ab[_0xf85891('0x233')](0x4,_0xbd76ab[_0xf85891('0x264b')])[_0xf85891('0x45a')](',');}break;case _0xf85891('0x1af7'):{const _0xddcb9f=_0x4b60be[_0xf85891('0xded')][_0xf85891('0x823')][_0xf85891('0x25c8')](',');_0x4b60be['dialogflow'][_0xf85891('0x265e')]=isNaN(_0xddcb9f[0x0])?_0xddcb9f[0x0]:parseInt(_0xddcb9f[0x0],0xa),_0x4b60be[_0xf85891('0xded')][_0xf85891('0x1640')]=_0xddcb9f[_0xf85891('0x233')](0x1,_0xddcb9f[_0xf85891('0x264b')])[_0xf85891('0x45a')](',');}break;case _0xf85891('0x1e70'):_0x4b60be['dialogflow']['text']=_0x4b60be[_0xf85891('0xded')][_0xf85891('0x823')];break;case _0xf85891('0xceb'):_0x4b60be[_0xf85891('0xded')]['name']=_0x4b60be['dialogflow'][_0xf85891('0x823')][_0xf85891('0x25c8')]('=')[0x0],_0x4b60be[_0xf85891('0xded')][_0xf85891('0x18e0')]=_0x4b60be[_0xf85891('0xded')]['appdata']['split']('=')[0x1];break;case'agi':_0x4b60be[_0xf85891('0xded')][_0xf85891('0x2588')]=_0x4b60be[_0xf85891('0xded')][_0xf85891('0x823')];break;default:{const _0x470c7a=_0x4b60be[_0xf85891('0xded')]['appdata']['split'](',');_0x4b60be[_0xf85891('0xded')][_0xf85891('0x7ca')]=_0x2cfb05()[_0xf85891('0x1081')](_0x470c7a[0x0])?_0x470c7a[0x0]:isNaN(_0x470c7a[0x0])?_0x470c7a[0x0]:parseInt(_0x470c7a[0x0],0xa),_0x4b60be['dialogflow'][_0xf85891('0xedb')]=_0x2cfb05()['isEmpty'](_0x470c7a[0x1])?_0x470c7a[0x1]:isNaN(_0x470c7a[0x1])?_0x470c7a[0x1]:parseInt(_0x470c7a[0x1],0xa),_0x4b60be['dialogflow'][_0xf85891('0x1634')]=_0x2cfb05()[_0xf85891('0x1081')](_0x470c7a[0x2])?_0x470c7a[0x2]:isNaN(_0x470c7a[0x2])?_0x470c7a[0x2]:parseInt(_0x470c7a[0x2],0xa);}break;}else _0x4b60be[_0xf85891('0xded')][_0xf85891('0xedb')]='en';_0x4b60be[_0xf85891('0xded')][_0xf85891('0x1345')]&&_0x4b60be[_0xf85891('0xded')]['type']['toLowerCase']()==='outbound'&&_0x4b60be['dialogflow']['appType'][_0xf85891('0x2574')]()===_0xf85891('0x2884')&&(_0x4b60be[_0xf85891('0xded')]['prefix']=_0x4b60be[_0xf85891('0xded')][_0xf85891('0x2026')]?_0x4b60be[_0xf85891('0xded')][_0xf85891('0x2026')][_0xf85891('0x25c8')]('$')[0x0]:undefined,_0x4b60be[_0xf85891('0xded')][_0xf85891('0x1f02')]=_0x4b60be[_0xf85891('0xded')]['callerID']?'CALLERID(all)='+_0x4b60be['dialogflow'][_0xf85891('0x992')]:undefined);_0x4b60be['saveWhatsappAccountApp']=_0x1a2d79,_0x4b60be[_0xf85891('0x24a0')]=_0x38cbd4;function _0x1a2d79(){const _0x20d5bb=_0xf85891;_0x4b60be['errors']=[];const _0x4ead8d=[];_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0x1345')]&&_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0x1345')][_0x20d5bb('0x2574')]()==='outbound'&&_0x4b60be['dialogflow'][_0x20d5bb('0x83f')]===_0x20d5bb('0x867')&&(_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0x2026')]=_0x134f8a[_0x20d5bb('0x2848')]?(_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0x265a')]||'')+'${EXTEN:'+_0x134f8a[_0x20d5bb('0x2848')]+'}':(_0x4b60be[_0x20d5bb('0xded')]['prefix']||'')+_0x20d5bb('0x1d1'),_0x134f8a[_0x20d5bb('0x28cb')]!=='none'?_0x4b60be[_0x20d5bb('0xded')]['options']['indexOf'](_0x20d5bb('0x1059'))<0x0&&(_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0xd39')]+='U(xcally-mixmonitor-context)'):_0x4b60be[_0x20d5bb('0xded')]['options']=_0x4b60be['dialogflow'][_0x20d5bb('0xd39')][_0x20d5bb('0xf3')]('U(xcally-mixmonitor-context)',''));if(_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0x83f')]&&_0x4b60be['dialogflow']['appType']==='custom'){}else switch((_0x4b60be[_0x20d5bb('0xded')]['app']||_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0x83f')])[_0x20d5bb('0x2574')]()){case'set':_0x4b60be['dialogflow'][_0x20d5bb('0x823')]=_0x4b60be['dialogflow'][_0x20d5bb('0x4f0')]+'='+_0x4b60be[_0x20d5bb('0xded')]['value'];break;case _0x20d5bb('0x2853'):break;default:_0x4ead8d[0x0]=_0x4b60be[_0x20d5bb('0xded')]['key'],_0x4ead8d[0x1]=_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0xedb')],_0x4ead8d[0x2]=_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0x1634')],_0x4b60be[_0x20d5bb('0xded')][_0x20d5bb('0x823')]=_0x4ead8d['join'](',');}_0x38cbd4(_0x4b60be[_0x20d5bb('0xded')]);}function _0x38cbd4(_0x2c4825){const _0x482819=_0xf85891;_0xdf201d[_0x482819('0x1197')](_0x2c4825);}}const _0x17c76e=_0x55f684;_0x30fcdb[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x9d'),_0x36e6f4('0xcc5'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x30fcdb(_0x5f0b97,_0x4280b5,_0xb4bd95,_0x567776,_0xaecbbe,_0x3ae5da,_0x347fb1,_0x2f63a0){const _0x578ab6=_0x36e6f4,_0x51f8d1=this;_0x51f8d1[_0x578ab6('0x98')]=_0x347fb1[_0x578ab6('0x26cd')](),_0x51f8d1['errors']=[],_0x51f8d1['title']='WHATSAPP.EDIT_'+(_0x567776[_0x578ab6('0x83f')]||_0x567776[_0x578ab6('0x746')])[_0x578ab6('0x1387')](),_0x51f8d1[_0x578ab6('0x30f')]=angular['copy'](_0x567776),_0x51f8d1['crudPermissions']=_0x2f63a0,_0x51f8d1[_0x578ab6('0x128b')]={};if(_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x823')])switch(_0x51f8d1['gotoif'][_0x578ab6('0x83f')]?_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x83f')]['toLowerCase']():_0x51f8d1['gotoif']['app']['toLowerCase']()){case _0x578ab6('0x2853'):break;case _0x578ab6('0xded'):{const _0x4fa471=_0x51f8d1['gotoif'][_0x578ab6('0x823')]['split'](',');_0x51f8d1[_0x578ab6('0x30f')]['key']=_0x4fa471[0x0],_0x51f8d1[_0x578ab6('0x30f')]['language']=_0x4fa471[0x1],_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x1634')]=_0x4fa471['slice'](0x2,_0x4fa471[_0x578ab6('0x264b')])[_0x578ab6('0x45a')](',');}break;case'dialogflowv2':{const _0x4201eb=_0x51f8d1['gotoif'][_0x578ab6('0x823')][_0x578ab6('0x25c8')](',');_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x1b0a')]=_0x4201eb[0x0],_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x27f3')]=_0x4201eb[0x1],_0x51f8d1[_0x578ab6('0x30f')]['privateKey']=_0x4201eb[0x2],_0x51f8d1['gotoif'][_0x578ab6('0xedb')]=_0x4201eb[0x3],_0x51f8d1['gotoif']['welcomemessage']=_0x4201eb[_0x578ab6('0x233')](0x4,_0x4201eb[_0x578ab6('0x264b')])['join'](',');}break;case _0x578ab6('0x86c'):{const _0x404c81=_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x823')][_0x578ab6('0x25c8')](',');_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0xee6')]=_0x404c81[0x0],_0x51f8d1['gotoif'][_0x578ab6('0x125')]=_0x404c81[0x1],_0x51f8d1[_0x578ab6('0x30f')]['lexregion']=_0x404c81[0x2],_0x51f8d1['gotoif'][_0x578ab6('0x1ac4')]=_0x404c81[0x3],_0x51f8d1[_0x578ab6('0x30f')]['welcomemessage']=_0x404c81[_0x578ab6('0x233')](0x4,_0x404c81['length'])[_0x578ab6('0x45a')](',');}break;case'autoreply':{const _0x113956=_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x823')][_0x578ab6('0x25c8')](',');_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x265e')]=isNaN(_0x113956[0x0])?_0x113956[0x0]:parseInt(_0x113956[0x0],0xa),_0x51f8d1['gotoif'][_0x578ab6('0x1640')]=_0x113956['slice'](0x1,_0x113956[_0x578ab6('0x264b')])[_0x578ab6('0x45a')](',');}break;case _0x578ab6('0x1e70'):_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x1640')]=_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x823')];break;case'set':_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x4f0')]=_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x823')][_0x578ab6('0x25c8')]('=')[0x0],_0x51f8d1['gotoif'][_0x578ab6('0x18e0')]=_0x51f8d1['gotoif']['appdata'][_0x578ab6('0x25c8')]('=')[0x1];break;case _0x578ab6('0x1034'):_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x2588')]=_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x823')];break;default:{const _0x545567=_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x823')]['split'](',');_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x8ff')]=_0x2cfb05()[_0x578ab6('0x1081')](_0x545567[0x0])?_0x545567[0x0]:isNaN(_0x545567[0x0])?_0x545567[0x0]:parseInt(_0x545567[0x0],0xa),_0x51f8d1['gotoif'][_0x578ab6('0x13a6')]=_0x2cfb05()['isEmpty'](_0x545567[0x1])?_0x545567[0x1]:isNaN(_0x545567[0x1])?_0x545567[0x1]:parseInt(_0x545567[0x1],0xa),_0x51f8d1['gotoif'][_0x578ab6('0x1d7a')]=_0x2cfb05()['isEmpty'](_0x545567[0x2])?_0x545567[0x2]:isNaN(_0x545567[0x2])?_0x545567[0x2]:parseInt(_0x545567[0x2],0xa);}break;}else{}_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x1345')]&&_0x51f8d1['gotoif'][_0x578ab6('0x1345')]['toLowerCase']()==='outbound'&&_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x83f')][_0x578ab6('0x2574')]()===_0x578ab6('0x2884')&&(_0x51f8d1[_0x578ab6('0x30f')]['prefix']=_0x51f8d1['gotoif'][_0x578ab6('0x2026')]?_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x2026')]['split']('$')[0x0]:undefined,_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x1f02')]=_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x992')]?_0x578ab6('0xa4c')+_0x51f8d1[_0x578ab6('0x30f')][_0x578ab6('0x992')]:undefined);_0x51f8d1[_0x578ab6('0xf14')]=_0x35db8a,_0x51f8d1[_0x578ab6('0x24a0')]=_0x37a951;function _0x35db8a(){const _0x2a5b2a=_0x578ab6;_0x51f8d1[_0x2a5b2a('0x61a')]=[];const _0x67f227=[];_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0x1345')]&&_0x51f8d1[_0x2a5b2a('0x30f')]['type'][_0x2a5b2a('0x2574')]()===_0x2a5b2a('0x587')&&_0x51f8d1['gotoif'][_0x2a5b2a('0x83f')]==='outboundDial'&&(_0x51f8d1[_0x2a5b2a('0x30f')]['phone']=_0xaecbbe[_0x2a5b2a('0x2848')]?(_0x51f8d1['gotoif']['prefix']||'')+'${EXTEN:'+_0xaecbbe['cutdigits']+'}':(_0x51f8d1[_0x2a5b2a('0x30f')]['prefix']||'')+'${EXTEN}',_0xaecbbe[_0x2a5b2a('0x28cb')]!==_0x2a5b2a('0x192')?_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0xd39')][_0x2a5b2a('0x2379')](_0x2a5b2a('0x1059'))<0x0&&(_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0xd39')]+=_0x2a5b2a('0x1059')):_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0xd39')]=_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0xd39')][_0x2a5b2a('0xf3')](_0x2a5b2a('0x1059'),''));if(_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0x83f')]&&_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0x83f')]===_0x2a5b2a('0x2853')){}else switch((_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0x746')]||_0x51f8d1[_0x2a5b2a('0x30f')]['appType'])[_0x2a5b2a('0x2574')]()){case _0x2a5b2a('0xceb'):_0x51f8d1['gotoif'][_0x2a5b2a('0x823')]=_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0x4f0')]+'='+_0x51f8d1[_0x2a5b2a('0x30f')][_0x2a5b2a('0x18e0')];break;case _0x2a5b2a('0x2853'):break;default:_0x67f227[0x0]=_0x51f8d1[_0x2a5b2a('0x30f')]['condition'],_0x67f227[0x1]=_0x51f8d1['gotoif'][_0x2a5b2a('0x13a6')],_0x67f227[0x2]=_0x51f8d1['gotoif'][_0x2a5b2a('0x1d7a')],_0x51f8d1['gotoif']['appdata']=_0x67f227[_0x2a5b2a('0x45a')](',');}_0x37a951(_0x51f8d1[_0x2a5b2a('0x30f')]);}function _0x37a951(_0x7dcb40){const _0x1e3b04=_0x578ab6;_0x5f0b97[_0x1e3b04('0x1197')](_0x7dcb40);}}const _0x4720c3=_0x30fcdb;_0x3e7b41[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x9d'),_0x36e6f4('0xcc5'),_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x3e7b41(_0x2c622b,_0x2c81af,_0x3e52be,_0x3a3ed6,_0x333d17,_0x2838d8,_0x2d6b0c,_0x1edf7c){const _0x428720=_0x36e6f4,_0x25f637=this;_0x25f637[_0x428720('0x98')]=_0x2d6b0c[_0x428720('0x26cd')](),_0x25f637['errors']=[],_0x25f637[_0x428720('0xcdc')]=_0x428720('0xb4a')+(_0x3a3ed6[_0x428720('0x83f')]||_0x3a3ed6['app'])['toUpperCase'](),_0x25f637[_0x428720('0x6e6')]=angular[_0x428720('0x225f')](_0x3a3ed6),_0x25f637[_0x428720('0x243c')]=_0x1edf7c,_0x25f637[_0x428720('0x128b')]={};if(_0x25f637[_0x428720('0x6e6')][_0x428720('0x823')])switch(_0x25f637[_0x428720('0x6e6')][_0x428720('0x83f')]?_0x25f637[_0x428720('0x6e6')]['appType'][_0x428720('0x2574')]():_0x25f637[_0x428720('0x6e6')][_0x428720('0x746')][_0x428720('0x2574')]()){case _0x428720('0x2853'):break;case'dialogflow':{const _0x5ce9cd=_0x25f637['gotop'][_0x428720('0x823')][_0x428720('0x25c8')](',');_0x25f637[_0x428720('0x6e6')]['key']=_0x5ce9cd[0x0],_0x25f637[_0x428720('0x6e6')][_0x428720('0xedb')]=_0x5ce9cd[0x1],_0x25f637[_0x428720('0x6e6')][_0x428720('0x1634')]=_0x5ce9cd[_0x428720('0x233')](0x2,_0x5ce9cd[_0x428720('0x264b')])[_0x428720('0x45a')](',');}break;case _0x428720('0x1636'):{const _0x217f1f=_0x25f637[_0x428720('0x6e6')]['appdata'][_0x428720('0x25c8')](',');_0x25f637[_0x428720('0x6e6')][_0x428720('0x1b0a')]=_0x217f1f[0x0],_0x25f637['gotop']['clientEmail']=_0x217f1f[0x1],_0x25f637[_0x428720('0x6e6')]['privateKey']=_0x217f1f[0x2],_0x25f637['gotop'][_0x428720('0xedb')]=_0x217f1f[0x3],_0x25f637[_0x428720('0x6e6')][_0x428720('0x1634')]=_0x217f1f[_0x428720('0x233')](0x4,_0x217f1f['length'])[_0x428720('0x45a')](',');}break;case _0x428720('0x86c'):{const _0x5745f9=_0x25f637[_0x428720('0x6e6')][_0x428720('0x823')]['split'](',');_0x25f637[_0x428720('0x6e6')][_0x428720('0xee6')]=_0x5745f9[0x0],_0x25f637[_0x428720('0x6e6')][_0x428720('0x125')]=_0x5745f9[0x1],_0x25f637[_0x428720('0x6e6')][_0x428720('0x25a2')]=_0x5745f9[0x2],_0x25f637[_0x428720('0x6e6')][_0x428720('0x1ac4')]=_0x5745f9[0x3],_0x25f637['gotop']['welcomemessage']=_0x5745f9['slice'](0x4,_0x5745f9[_0x428720('0x264b')])['join'](',');}break;case _0x428720('0x1af7'):{const _0x3baa59=_0x25f637[_0x428720('0x6e6')]['appdata']['split'](',');_0x25f637[_0x428720('0x6e6')][_0x428720('0x265e')]=isNaN(_0x3baa59[0x0])?_0x3baa59[0x0]:parseInt(_0x3baa59[0x0],0xa),_0x25f637[_0x428720('0x6e6')][_0x428720('0x1640')]=_0x3baa59[_0x428720('0x233')](0x1,_0x3baa59['length'])[_0x428720('0x45a')](',');}break;case _0x428720('0x1e70'):_0x25f637[_0x428720('0x6e6')][_0x428720('0x1640')]=_0x25f637['gotop'][_0x428720('0x823')];break;case _0x428720('0xceb'):_0x25f637[_0x428720('0x6e6')][_0x428720('0x4f0')]=_0x25f637[_0x428720('0x6e6')][_0x428720('0x823')]['split']('=')[0x0],_0x25f637[_0x428720('0x6e6')][_0x428720('0x18e0')]=_0x25f637['gotop'][_0x428720('0x823')][_0x428720('0x25c8')]('=')[0x1];break;case _0x428720('0x1034'):_0x25f637[_0x428720('0x6e6')][_0x428720('0x2588')]=_0x25f637['gotop'][_0x428720('0x823')];break;default:{const _0x393457=_0x25f637['gotop']['appdata'][_0x428720('0x25c8')](',');_0x25f637[_0x428720('0x6e6')][_0x428720('0xfde')]=_0x2cfb05()[_0x428720('0x1081')](_0x393457[0x0])?_0x393457[0x0]:isNaN(_0x393457[0x0])?_0x393457[0x0]:parseInt(_0x393457[0x0],0xa);}break;}else{}_0x25f637[_0x428720('0x6e6')][_0x428720('0x1345')]&&_0x25f637[_0x428720('0x6e6')][_0x428720('0x1345')][_0x428720('0x2574')]()===_0x428720('0x587')&&_0x25f637[_0x428720('0x6e6')][_0x428720('0x83f')]['toLowerCase']()===_0x428720('0x2884')&&(_0x25f637[_0x428720('0x6e6')][_0x428720('0x265a')]=_0x25f637[_0x428720('0x6e6')]['phone']?_0x25f637[_0x428720('0x6e6')][_0x428720('0x2026')][_0x428720('0x25c8')]('$')[0x0]:undefined,_0x25f637[_0x428720('0x6e6')]['callerId']=_0x25f637[_0x428720('0x6e6')][_0x428720('0x992')]?'CALLERID(all)='+_0x25f637[_0x428720('0x6e6')][_0x428720('0x992')]:undefined);_0x25f637[_0x428720('0xf14')]=_0x105013,_0x25f637['closeDialog']=_0x241a57;function _0x105013(){const _0x10e1e3=_0x428720;_0x25f637[_0x10e1e3('0x61a')]=[];const _0x4619a7=[];_0x25f637['gotop'][_0x10e1e3('0x1345')]&&_0x25f637['gotop']['type'][_0x10e1e3('0x2574')]()===_0x10e1e3('0x587')&&_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0x83f')]==='outboundDial'&&(_0x25f637['gotop'][_0x10e1e3('0x2026')]=_0x333d17[_0x10e1e3('0x2848')]?(_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0x265a')]||'')+_0x10e1e3('0x881')+_0x333d17[_0x10e1e3('0x2848')]+'}':(_0x25f637['gotop'][_0x10e1e3('0x265a')]||'')+_0x10e1e3('0x1d1'),_0x333d17[_0x10e1e3('0x28cb')]!==_0x10e1e3('0x192')?_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0xd39')][_0x10e1e3('0x2379')](_0x10e1e3('0x1059'))<0x0&&(_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0xd39')]+=_0x10e1e3('0x1059')):_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0xd39')]=_0x25f637['gotop']['options'][_0x10e1e3('0xf3')](_0x10e1e3('0x1059'),''));if(_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0x83f')]&&_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0x83f')]===_0x10e1e3('0x2853')){}else switch((_0x25f637['gotop'][_0x10e1e3('0x746')]||_0x25f637['gotop']['appType'])['toLowerCase']()){case _0x10e1e3('0xceb'):_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0x823')]=_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0x4f0')]+'='+_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0x18e0')];break;case _0x10e1e3('0x2853'):break;default:_0x4619a7[0x0]=_0x25f637[_0x10e1e3('0x6e6')]['priority'],_0x25f637[_0x10e1e3('0x6e6')][_0x10e1e3('0x823')]=_0x4619a7['join'](',');}_0x241a57(_0x25f637[_0x10e1e3('0x6e6')]);}function _0x241a57(_0x3f4073){const _0xc7b7ef=_0x428720;_0x2c622b[_0xc7b7ef('0x1197')](_0x3f4073);}}const _0x1b7f99=_0x3e7b41;_0xce1827['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x265d'),_0x36e6f4('0x25d0'),'IndexFactory','interval',_0x36e6f4('0x164e'),_0x36e6f4('0x1d2e'),'api','Auth',_0x36e6f4('0x243c')];function _0xce1827(_0x3883b9,_0x1b8b53,_0x4d9b5c,_0x9576fb,_0x30ec57,_0xd3eba3,_0x4a0ca2,_0x53405e,_0x3b2e8d,_0x42f5b1){const _0x4ad8ee=_0x36e6f4,_0x24a9b7=this;_0x24a9b7[_0x4ad8ee('0x98')]=_0x3b2e8d['getCurrentUser'](),_0x24a9b7[_0x4ad8ee('0x61a')]=[],_0x24a9b7[_0x4ad8ee('0xcdc')]='TOOLS.EDIT_INTERVAL',_0x24a9b7[_0x4ad8ee('0x277c')]=angular['copy'](_0x30ec57),_0x24a9b7[_0x4ad8ee('0x164e')]=_0xd3eba3,_0x24a9b7[_0x4ad8ee('0x99d')]=![],_0x24a9b7['types']=[_0x4ad8ee('0x597'),_0x4ad8ee('0x2853'),'list'],_0x24a9b7[_0x4ad8ee('0x243c')]=_0x42f5b1,_0x24a9b7[_0x4ad8ee('0x5ef')]=_0x9576fb['getDaysOfWeek'](),_0x24a9b7['monthNumber']=_0x9576fb[_0x4ad8ee('0x51d')](),_0x24a9b7[_0x4ad8ee('0x2259')]=_0x9576fb[_0x4ad8ee('0x1c39')](),_0x24a9b7[_0x4ad8ee('0x1fc0')]=_0x9576fb['getDaysOfMonth']();if(!_0x24a9b7['interval'])_0x24a9b7[_0x4ad8ee('0x277c')]={'interval':_0x4ad8ee('0x16f')},_0x24a9b7[_0x4ad8ee('0x1345')]=_0x4ad8ee('0x597'),_0x24a9b7[_0x4ad8ee('0xcdc')]='TOOLS.NEW_INTERVAL',_0x24a9b7['newInterval']=!![];else{if(_0x24a9b7[_0x4ad8ee('0x277c')][_0x4ad8ee('0x277c')]!==_0x4ad8ee('0x16f')){_0x24a9b7['type']=_0x4ad8ee('0x2853');const _0x241161=_0x24a9b7[_0x4ad8ee('0x277c')][_0x4ad8ee('0x277c')][_0x4ad8ee('0x25c8')](','),_0x319baf=_0x241161[0x0],_0x2ea465=_0x241161[0x1],_0x334329=_0x241161[0x2],_0x299567=_0x241161[0x3];if(_0x319baf!=='*'){const _0x547089=_0x319baf[_0x4ad8ee('0x25c8')]('-')[0x0],_0x58b4f3=_0x319baf['split']('-')[0x1];let _0x256a3d;_0x256a3d=new Date(),_0x256a3d[_0x4ad8ee('0xe24')](Number(_0x547089['split'](':')[0x0])),_0x256a3d[_0x4ad8ee('0x790')](Number(_0x547089[_0x4ad8ee('0x25c8')](':')[0x1])),_0x24a9b7[_0x4ad8ee('0x64d')]=_0x256a3d,_0x256a3d=new Date(),_0x256a3d[_0x4ad8ee('0xe24')](Number(_0x58b4f3['split'](':')[0x0])),_0x256a3d[_0x4ad8ee('0x790')](Number(_0x58b4f3['split'](':')[0x1])),_0x24a9b7['timeRangeTo']=_0x256a3d;}_0x2ea465!=='*'&&(_0x24a9b7['dayOfWeekFrom']=_0x2ea465[_0x4ad8ee('0x25c8')]('-')[0x0],_0x24a9b7[_0x4ad8ee('0x1b81')]=_0x2ea465[_0x4ad8ee('0x25c8')]('-')[0x1]),_0x334329!=='*'&&(_0x24a9b7[_0x4ad8ee('0x103d')]=_0x334329[_0x4ad8ee('0x25c8')]('-')[0x0],_0x24a9b7['monthDayTo']=_0x334329[_0x4ad8ee('0x25c8')]('-')[0x1]),_0x299567!=='*'&&(_0x24a9b7[_0x4ad8ee('0xdec')]=_0x299567[_0x4ad8ee('0x25c8')]('-')[0x0],_0x24a9b7[_0x4ad8ee('0x1125')]=_0x299567[_0x4ad8ee('0x25c8')]('-')[0x1]);}else _0x24a9b7['type']=_0x4ad8ee('0x597');}_0x3883b9[_0x4ad8ee('0x23f')]['id']&&!_0x24a9b7[_0x4ad8ee('0x277c')][_0x4ad8ee('0x50d')]&&(_0x24a9b7[_0x4ad8ee('0x277c')][_0x4ad8ee('0x186f')]=_0x3883b9[_0x4ad8ee('0x23f')]['id']);_0x24a9b7[_0x4ad8ee('0x277c')][_0x4ad8ee('0x186f')]&&_0x24a9b7[_0x4ad8ee('0x277c')][_0x4ad8ee('0x50d')]&&(_0x24a9b7[_0x4ad8ee('0x1345')]=_0x4ad8ee('0x1480'));_0x24a9b7[_0x4ad8ee('0x1ebf')]=_0x15461c,_0x24a9b7[_0x4ad8ee('0x24be')]=_0x2d74f6,_0x24a9b7[_0x4ad8ee('0x24a0')]=_0x1de415;_0x24a9b7[_0x4ad8ee('0x277c')][_0x4ad8ee('0x50d')]&&(_0x3b2e8d[_0x4ad8ee('0x1ac6')](_0x4ad8ee('0xa7c'))?_0x53405e[_0x4ad8ee('0x277c')]['get']({'fields':_0x4ad8ee('0xd0a'),'IntervalId':'null','nolimit':!![]})[_0x4ad8ee('0xa44')][_0x4ad8ee('0x1166')](function(_0x1bee79){const _0xc3f48a=_0x4ad8ee;_0x24a9b7[_0xc3f48a('0x164e')]=_0x1bee79[_0xc3f48a('0x269a')]||[];})[_0x4ad8ee('0x1a80')](function(_0x12e41c){const _0x30410e=_0x4ad8ee;_0x4a0ca2[_0x30410e('0xfc9')]({'title':_0x12e41c['status']?_0x30410e('0x1e21')+_0x12e41c['status']+_0x30410e('0x11e1')+_0x12e41c[_0x30410e('0xe1b')]:_0x30410e('0xbb4'),'msg':_0x12e41c[_0x30410e('0x25f4')]?JSON[_0x30410e('0xbac')](_0x12e41c[_0x30410e('0x25f4')]):_0x12e41c['toString']()});}):_0x53405e[_0x4ad8ee('0x277c')][_0x4ad8ee('0xd83')]({'fields':'id,name,interval,IntervalId','IntervalId':_0x4ad8ee('0x15d7'),'nolimit':!![]})[_0x4ad8ee('0xa44')][_0x4ad8ee('0x1166')](function(_0x159cab){const _0x1d1155=_0x4ad8ee;_0x24a9b7[_0x1d1155('0x164e')]=_0x159cab[_0x1d1155('0x269a')]||[];})[_0x4ad8ee('0x1166')](function(){const _0x1fa100=_0x4ad8ee;return _0x53405e[_0x1fa100('0x17aa')][_0x1fa100('0xd83')]({'userProfileId':_0x24a9b7['currentUser']['userProfileId'],'sectionId':0x3ec})[_0x1fa100('0xa44')];})[_0x4ad8ee('0x1166')](function(_0x5d9661){const _0x597f92=_0x4ad8ee,_0x28c32a=_0x5d9661&&_0x5d9661[_0x597f92('0x269a')]?_0x5d9661['rows'][0x0]:null;if(!_0x28c32a)_0x24a9b7[_0x597f92('0x164e')]=[];else{if(!_0x28c32a[_0x597f92('0x1a2b')])return _0x53405e[_0x597f92('0x4b5')][_0x597f92('0xd83')]({'sectionId':_0x28c32a['id']})[_0x597f92('0xa44')]['then'](function(_0x266d9c){const _0x2d201c=_0x597f92,_0x5ddd8a=_0x266d9c&&_0x266d9c['rows']?_0x266d9c[_0x2d201c('0x269a')]:[],_0x2710e6=[];let _0x43e46b=null;_0x24a9b7[_0x2d201c('0x277c')]&&(_0x43e46b=_0x2cfb05()[_0x2d201c('0xc38')](_0x24a9b7['intervals'],{'name':_0x24a9b7[_0x2d201c('0x277c')][_0x2d201c('0x186f')]})),_0x43e46b&&!_0x2cfb05()[_0x2d201c('0x1798')](_0x5ddd8a,['resourceId',_0x43e46b['id']])&&_0x24a9b7['intervals'][_0x2d201c('0x2782')](function(_0x83da19){const _0x1f69ae=_0x2d201c;_0x83da19['id']===_0x43e46b['id']&&(_0x83da19[_0x1f69ae('0x2378')]=![],_0x2710e6[_0x1f69ae('0x1514')](_0x83da19));}),_0x24a9b7[_0x2d201c('0x164e')]=_0x2710e6;});}})[_0x4ad8ee('0x1a80')](function(_0x3b5db1){const _0x2a1c4a=_0x4ad8ee;_0x4a0ca2[_0x2a1c4a('0xfc9')]({'title':_0x3b5db1[_0x2a1c4a('0x52d')]?'API:'+_0x3b5db1['status']+'\x20-\x20'+_0x3b5db1[_0x2a1c4a('0xe1b')]:_0x2a1c4a('0xbb4'),'msg':_0x3b5db1[_0x2a1c4a('0x25f4')]?JSON[_0x2a1c4a('0xbac')](_0x3b5db1[_0x2a1c4a('0x25f4')]):_0x3b5db1['toString']()});}));function _0x5bc465(){const _0x365768=_0x4ad8ee;switch(_0x24a9b7[_0x365768('0x1345')]){case _0x365768('0x597'):case'list':return _0x365768('0x16f');case _0x365768('0x2853'):{const _0x567754=[];if(_0x24a9b7[_0x365768('0x64d')]!=='*'&&_0x24a9b7[_0x365768('0x64d')]&&_0x24a9b7[_0x365768('0x2076')]){const _0x4a74c8=(_0x24a9b7[_0x365768('0x64d')][_0x365768('0x11fe')]()<0xa?'0':'')+_0x24a9b7[_0x365768('0x64d')][_0x365768('0x11fe')]()+':'+((_0x24a9b7[_0x365768('0x64d')][_0x365768('0x234')]()<0xa?'0':'')+_0x24a9b7['timeRangeFrom'][_0x365768('0x234')]()),_0x4118aa=(_0x24a9b7['timeRangeTo'][_0x365768('0x11fe')]()<0xa?'0':'')+_0x24a9b7[_0x365768('0x2076')][_0x365768('0x11fe')]()+':'+((_0x24a9b7['timeRangeTo']['getMinutes']()<0xa?'0':'')+_0x24a9b7[_0x365768('0x2076')][_0x365768('0x234')]());_0x567754[_0x365768('0x1514')](_0x4a74c8+'-'+_0x4118aa);}else _0x567754[_0x365768('0x1514')]('*');return _0x24a9b7['dayOfWeekFrom']?_0x24a9b7[_0x365768('0x1b81')]?_0x567754[_0x365768('0x1514')](_0x24a9b7[_0x365768('0x1eca')]+'-'+_0x24a9b7[_0x365768('0x1b81')]):_0x567754['push'](_0x24a9b7['dayOfWeekFrom']):_0x567754['push']('*'),_0x24a9b7['monthDayFrom']?_0x24a9b7[_0x365768('0x1dbb')]?_0x567754[_0x365768('0x1514')](_0x24a9b7[_0x365768('0x103d')]+'-'+_0x24a9b7[_0x365768('0x1dbb')]):_0x567754[_0x365768('0x1514')](_0x24a9b7[_0x365768('0x103d')]):_0x567754[_0x365768('0x1514')]('*'),_0x24a9b7[_0x365768('0xdec')]?_0x24a9b7[_0x365768('0x1125')]?_0x567754[_0x365768('0x1514')](_0x24a9b7[_0x365768('0xdec')]+'-'+_0x24a9b7['monthTo']):_0x567754['push'](_0x24a9b7['monthFrom']):_0x567754[_0x365768('0x1514')]('*'),_0x567754[_0x365768('0x45a')]();}}}function _0x15461c(){const _0x14edfe=_0x4ad8ee;_0x24a9b7['errors']=[],_0x24a9b7['interval'][_0x14edfe('0x277c')]=_0x5bc465(),_0x53405e[_0x14edfe('0x277c')][_0x14edfe('0x9cc')](_0x24a9b7['interval'])['$promise'][_0x14edfe('0x1166')](function(_0x3c6fa6){const _0x57a431=_0x14edfe;_0x24a9b7['intervals']['push'](_0x3c6fa6),_0x4a0ca2[_0x57a431('0x103b')]({'title':_0x57a431('0xf10'),'msg':_0x24a9b7[_0x57a431('0x277c')][_0x57a431('0x4f0')]?_0x24a9b7[_0x57a431('0x277c')][_0x57a431('0x4f0')]+_0x57a431('0x1eda'):''}),_0x1de415();})['catch'](function(_0x772cb1){const _0x3578e7=_0x14edfe;console['error'](_0x772cb1),_0x24a9b7[_0x3578e7('0x61a')]=_0x772cb1[_0x3578e7('0x25f4')][_0x3578e7('0x61a')]||[{'message':_0x772cb1['toString'](),'type':'api.interval.save'}];});}function _0x2d74f6(){const _0x409195=_0x4ad8ee;_0x24a9b7[_0x409195('0x61a')]=[],_0x24a9b7['interval'][_0x409195('0x277c')]=_0x5bc465(),_0x24a9b7[_0x409195('0x277c')][_0x409195('0x50d')]?(_0x24a9b7[_0x409195('0x1345')]!=='list'&&(_0x24a9b7['interval'][_0x409195('0x186f')]=null),_0x1de415(_0x24a9b7[_0x409195('0x277c')])):_0x53405e[_0x409195('0x277c')][_0x409195('0x1449')]({'id':_0x24a9b7[_0x409195('0x277c')]['id']},_0x24a9b7[_0x409195('0x277c')])[_0x409195('0xa44')][_0x409195('0x1166')](function(_0x5ace1c){const _0x3f655a=_0x409195,_0x5f04a5=_0x2cfb05()['find'](_0x24a9b7['intervals'],{'id':_0x5ace1c['id']});_0x5f04a5&&_0x2cfb05()[_0x3f655a('0xcc3')](_0x5f04a5,_0x5ace1c),_0x4a0ca2[_0x3f655a('0x103b')]({'title':_0x3f655a('0x1243'),'msg':_0x3f655a('0x1666')}),_0x1de415();})[_0x409195('0x1a80')](function(_0x329e52){const _0x36be95=_0x409195;console['error'](_0x329e52),_0x24a9b7[_0x36be95('0x61a')]=_0x329e52['data'][_0x36be95('0x61a')]||[{'message':_0x329e52['toString'](),'type':_0x36be95('0x2725')}];});}function _0x1de415(_0x5be2ac){const _0x16a3dc=_0x4ad8ee;_0x1b8b53[_0x16a3dc('0x1197')](_0x5be2ac);}}const _0x5c8359=_0xce1827;_0x555399[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x9d'),_0x36e6f4('0xcc5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),'crudPermissions'];function _0x555399(_0x352bf5,_0x371a6f,_0x3fd152,_0x27352f,_0x1ac979,_0x10b3b8,_0x2a9d30,_0xd5d548){const _0x1e023c=_0x36e6f4,_0x1a4544=this;_0x1a4544[_0x1e023c('0x98')]=_0x2a9d30[_0x1e023c('0x26cd')](),_0x1a4544[_0x1e023c('0x61a')]=[],_0x1a4544['title']=_0x1e023c('0xb4a')+(_0x27352f['appType']||_0x27352f[_0x1e023c('0x746')])[_0x1e023c('0x1387')](),_0x1a4544['noop']=angular['copy'](_0x27352f),_0x1a4544['crudPermissions']=_0xd5d548,_0x1a4544[_0x1e023c('0x128b')]={};if(_0x1a4544[_0x1e023c('0x2652')]['appdata'])switch(_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x83f')]?_0x1a4544[_0x1e023c('0x2652')]['appType'][_0x1e023c('0x2574')]():_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x746')][_0x1e023c('0x2574')]()){case'custom':break;case _0x1e023c('0xded'):{const _0x50f8d2=_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x823')][_0x1e023c('0x25c8')](',');_0x1a4544[_0x1e023c('0x2652')]['key']=_0x50f8d2[0x0],_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0xedb')]=_0x50f8d2[0x1],_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x1634')]=_0x50f8d2[_0x1e023c('0x233')](0x2,_0x50f8d2[_0x1e023c('0x264b')])[_0x1e023c('0x45a')](',');}break;case _0x1e023c('0x1636'):{const _0xa67f27=_0x1a4544['noop']['appdata'][_0x1e023c('0x25c8')](',');_0x1a4544[_0x1e023c('0x2652')]['projectId']=_0xa67f27[0x0],_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x27f3')]=_0xa67f27[0x1],_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x170e')]=_0xa67f27[0x2],_0x1a4544[_0x1e023c('0x2652')]['language']=_0xa67f27[0x3],_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x1634')]=_0xa67f27[_0x1e023c('0x233')](0x4,_0xa67f27[_0x1e023c('0x264b')])[_0x1e023c('0x45a')](',');}break;case _0x1e023c('0x86c'):{const _0x555fd4=_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x823')][_0x1e023c('0x25c8')](',');_0x1a4544[_0x1e023c('0x2652')]['accesskeyid']=_0x555fd4[0x0],_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x125')]=_0x555fd4[0x1],_0x1a4544[_0x1e023c('0x2652')]['lexregion']=_0x555fd4[0x2],_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x1ac4')]=_0x555fd4[0x3],_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x1634')]=_0x555fd4['slice'](0x4,_0x555fd4[_0x1e023c('0x264b')])[_0x1e023c('0x45a')](',');}break;case _0x1e023c('0x1af7'):{const _0x558847=_0x1a4544['noop'][_0x1e023c('0x823')][_0x1e023c('0x25c8')](',');_0x1a4544['noop'][_0x1e023c('0x265e')]=isNaN(_0x558847[0x0])?_0x558847[0x0]:parseInt(_0x558847[0x0],0xa),_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x1640')]=_0x558847['slice'](0x1,_0x558847[_0x1e023c('0x264b')])[_0x1e023c('0x45a')](',');}break;case'message':_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x1640')]=_0x1a4544[_0x1e023c('0x2652')]['appdata'];break;case _0x1e023c('0xceb'):_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x4f0')]=_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x823')][_0x1e023c('0x25c8')]('=')[0x0],_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x18e0')]=_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x823')][_0x1e023c('0x25c8')]('=')[0x1];break;case _0x1e023c('0x1034'):_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x2588')]=_0x1a4544['noop'][_0x1e023c('0x823')];break;default:{const _0x2cc411=_0x1a4544[_0x1e023c('0x2652')]['appdata'][_0x1e023c('0x25c8')](',');_0x1a4544[_0x1e023c('0x2652')]['value']=_0x2cfb05()[_0x1e023c('0x1081')](_0x2cc411[0x0])?_0x2cc411[0x0]:isNaN(_0x2cc411[0x0])?_0x2cc411[0x0]:parseInt(_0x2cc411[0x0],0xa);}break;}else{}_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x1345')]&&_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x1345')][_0x1e023c('0x2574')]()==='outbound'&&_0x1a4544['noop']['appType'][_0x1e023c('0x2574')]()==='outbounddial'&&(_0x1a4544[_0x1e023c('0x2652')]['prefix']=_0x1a4544[_0x1e023c('0x2652')]['phone']?_0x1a4544[_0x1e023c('0x2652')][_0x1e023c('0x2026')]['split']('$')[0x0]:undefined,_0x1a4544['noop'][_0x1e023c('0x1f02')]=_0x1a4544['noop'][_0x1e023c('0x992')]?_0x1e023c('0xa4c')+_0x1a4544[_0x1e023c('0x2652')]['callerID']:undefined);_0x1a4544[_0x1e023c('0xf14')]=_0x14816c,_0x1a4544[_0x1e023c('0x24a0')]=_0x2d9fba;function _0x14816c(){const _0x3535dd=_0x1e023c;_0x1a4544['errors']=[];const _0x3a6819=[];_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0x1345')]&&_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0x1345')][_0x3535dd('0x2574')]()===_0x3535dd('0x587')&&_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0x83f')]===_0x3535dd('0x867')&&(_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0x2026')]=_0x1ac979['cutdigits']?(_0x1a4544['noop'][_0x3535dd('0x265a')]||'')+_0x3535dd('0x881')+_0x1ac979['cutdigits']+'}':(_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0x265a')]||'')+_0x3535dd('0x1d1'),_0x1ac979[_0x3535dd('0x28cb')]!==_0x3535dd('0x192')?_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0xd39')]['indexOf'](_0x3535dd('0x1059'))<0x0&&(_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0xd39')]+='U(xcally-mixmonitor-context)'):_0x1a4544['noop']['options']=_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0xd39')]['replace'](_0x3535dd('0x1059'),''));if(_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0x83f')]&&_0x1a4544[_0x3535dd('0x2652')]['appType']===_0x3535dd('0x2853')){}else switch((_0x1a4544['noop']['app']||_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0x83f')])[_0x3535dd('0x2574')]()){case _0x3535dd('0xceb'):_0x1a4544[_0x3535dd('0x2652')]['appdata']=_0x1a4544[_0x3535dd('0x2652')]['name']+'='+_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0x18e0')];break;case _0x3535dd('0x2853'):break;default:_0x3a6819[0x0]=_0x1a4544[_0x3535dd('0x2652')][_0x3535dd('0x18e0')],_0x1a4544['noop']['appdata']=_0x3a6819[_0x3535dd('0x45a')](',');}_0x2d9fba(_0x1a4544[_0x3535dd('0x2652')]);}function _0x2d9fba(_0x34c52d){const _0x453cc8=_0x1e023c;_0x352bf5[_0x453cc8('0x1197')](_0x34c52d);}}const _0x500d66=_0x555399;_0x1a1161['$inject']=['$mdDialog','$q','toasty',_0x36e6f4('0x9d'),'whatsappAccount',_0x36e6f4('0x19e3'),'Auth',_0x36e6f4('0x243c')];function _0x1a1161(_0x152f12,_0x1aeb73,_0x49d8f8,_0x52d920,_0x3c2e31,_0x669f7e,_0x1b12ea,_0x1af231){const _0x1539c8=_0x36e6f4,_0x281325=this;_0x281325[_0x1539c8('0x98')]=_0x1b12ea[_0x1539c8('0x26cd')](),_0x281325[_0x1539c8('0x61a')]=[],_0x281325['title']=_0x1539c8('0xb4a')+(_0x52d920[_0x1539c8('0x83f')]||_0x52d920[_0x1539c8('0x746')])['toUpperCase'](),_0x281325[_0x1539c8('0x1d3e')]=angular[_0x1539c8('0x225f')](_0x52d920),_0x281325[_0x1539c8('0x243c')]=_0x1af231,_0x281325[_0x1539c8('0x128b')]={};if(_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x823')])switch(_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x83f')]?_0x281325[_0x1539c8('0x1d3e')]['appType'][_0x1539c8('0x2574')]():_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x746')][_0x1539c8('0x2574')]()){case _0x1539c8('0x2853'):break;case _0x1539c8('0xded'):{const _0x2bde61=_0x281325['queue'][_0x1539c8('0x823')][_0x1539c8('0x25c8')](',');_0x281325[_0x1539c8('0x1d3e')]['key']=_0x2bde61[0x0],_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0xedb')]=_0x2bde61[0x1],_0x281325[_0x1539c8('0x1d3e')]['welcomemessage']=_0x2bde61['slice'](0x2,_0x2bde61[_0x1539c8('0x264b')])[_0x1539c8('0x45a')](',');}break;case _0x1539c8('0x1636'):{const _0x164f49=_0x281325[_0x1539c8('0x1d3e')]['appdata']['split'](',');_0x281325[_0x1539c8('0x1d3e')]['projectId']=_0x164f49[0x0],_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x27f3')]=_0x164f49[0x1],_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x170e')]=_0x164f49[0x2],_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0xedb')]=_0x164f49[0x3],_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x1634')]=_0x164f49['slice'](0x4,_0x164f49['length'])[_0x1539c8('0x45a')](',');}break;case'amazonlex':{const _0x142ea4=_0x281325[_0x1539c8('0x1d3e')]['appdata'][_0x1539c8('0x25c8')](',');_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0xee6')]=_0x142ea4[0x0],_0x281325['queue']['secretaccesskey']=_0x142ea4[0x1],_0x281325['queue'][_0x1539c8('0x25a2')]=_0x142ea4[0x2],_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x1ac4')]=_0x142ea4[0x3],_0x281325['queue'][_0x1539c8('0x1634')]=_0x142ea4[_0x1539c8('0x233')](0x4,_0x142ea4[_0x1539c8('0x264b')])[_0x1539c8('0x45a')](',');}break;case _0x1539c8('0x1af7'):{const _0x18bf30=_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x823')]['split'](',');_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x265e')]=isNaN(_0x18bf30[0x0])?_0x18bf30[0x0]:parseInt(_0x18bf30[0x0],0xa),_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x1640')]=_0x18bf30[_0x1539c8('0x233')](0x1,_0x18bf30[_0x1539c8('0x264b')])[_0x1539c8('0x45a')](',');}break;case _0x1539c8('0x1e70'):_0x281325['queue'][_0x1539c8('0x1640')]=_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x823')];break;case _0x1539c8('0xceb'):_0x281325[_0x1539c8('0x1d3e')]['name']=_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x823')][_0x1539c8('0x25c8')]('=')[0x0],_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x18e0')]=_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x823')][_0x1539c8('0x25c8')]('=')[0x1];break;case _0x1539c8('0x1034'):_0x281325['queue'][_0x1539c8('0x2588')]=_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x823')];break;default:{const _0x2daf14=_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x823')][_0x1539c8('0x25c8')](',');_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x1d3e')]=_0x2cfb05()[_0x1539c8('0x1081')](_0x2daf14[0x0])?_0x2daf14[0x0]:isNaN(_0x2daf14[0x0])?_0x2daf14[0x0]:parseInt(_0x2daf14[0x0],0xa),_0x281325[_0x1539c8('0x1d3e')]['timeout']=_0x2cfb05()[_0x1539c8('0x1081')](_0x2daf14[0x1])?_0x2daf14[0x1]:isNaN(_0x2daf14[0x1])?_0x2daf14[0x1]:parseInt(_0x2daf14[0x1],0xa);}break;}else _0x281325[_0x1539c8('0x1d3e')]['queue']=0x12c,_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x651')]=0x12c;_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x1345')]&&_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x1345')][_0x1539c8('0x2574')]()===_0x1539c8('0x587')&&_0x281325['queue'][_0x1539c8('0x83f')][_0x1539c8('0x2574')]()===_0x1539c8('0x2884')&&(_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x265a')]=_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x2026')]?_0x281325[_0x1539c8('0x1d3e')]['phone'][_0x1539c8('0x25c8')]('$')[0x0]:undefined,_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x1f02')]=_0x281325[_0x1539c8('0x1d3e')]['callerID']?'CALLERID(all)='+_0x281325[_0x1539c8('0x1d3e')][_0x1539c8('0x992')]:undefined);_0x281325['saveWhatsappAccountApp']=_0x4b9308,_0x281325[_0x1539c8('0x24a0')]=_0x569e76,_0x1b12ea['hasRole'](_0x1539c8('0xa7c'))?_0x669f7e['whatsappQueue']['get']({'fields':_0x1539c8('0x1c09'),'sort':_0x1539c8('0x4f0'),'nolimit':'true'})[_0x1539c8('0xa44')]['then'](function(_0x4a9d40){const _0x5662fc=_0x1539c8;_0x281325[_0x5662fc('0x7a7')]=_0x4a9d40['rows']||[];})[_0x1539c8('0x1a80')](function(_0x25fec5){const _0xae2508=_0x1539c8;_0x49d8f8['error']({'title':_0x25fec5[_0xae2508('0x52d')]?_0xae2508('0x1e21')+_0x25fec5[_0xae2508('0x52d')]+_0xae2508('0x11e1')+_0x25fec5['statusText']:_0xae2508('0x2029'),'msg':_0x25fec5[_0xae2508('0x25f4')]?JSON[_0xae2508('0xbac')](_0x25fec5[_0xae2508('0x25f4')]):_0x25fec5[_0xae2508('0x1586')]()});}):_0x669f7e[_0x1539c8('0x1bb6')]['get']({'fields':_0x1539c8('0x1c09'),'sort':'name','nolimit':_0x1539c8('0xf3b')})[_0x1539c8('0xa44')][_0x1539c8('0x1166')](function(_0x4af558){const _0x98b641=_0x1539c8;_0x281325[_0x98b641('0x7a7')]=_0x4af558[_0x98b641('0x269a')]||[];})['then'](function(){const _0x33cdee=_0x1539c8;return _0x669f7e['userProfileSection']['get']({'userProfileId':_0x281325[_0x33cdee('0x98')][_0x33cdee('0xb86')],'sectionId':0x836})[_0x33cdee('0xa44')];})[_0x1539c8('0x1166')](function(_0x5a1dec){const _0x2e8504=_0x1539c8,_0x5c689c=_0x5a1dec&&_0x5a1dec[_0x2e8504('0x269a')]?_0x5a1dec[_0x2e8504('0x269a')][0x0]:null;if(!_0x5c689c){const _0x4762aa=[];let _0x405a05=null;_0x281325[_0x2e8504('0x1d3e')]&&(_0x405a05=_0x2cfb05()['find'](_0x281325['queues'],{'name':_0x281325['queue'][_0x2e8504('0x1d3e')]}));for(let _0x3af8ce=0x0;_0x3af8ce<_0x281325[_0x2e8504('0x7a7')]['length'];_0x3af8ce++){_0x405a05&&_0x281325['queues'][_0x3af8ce]['id']===_0x405a05['id']&&(_0x281325[_0x2e8504('0x7a7')][_0x3af8ce][_0x2e8504('0x2378')]=![],_0x4762aa[_0x2e8504('0x1514')](_0x281325[_0x2e8504('0x7a7')][_0x3af8ce]));}_0x281325[_0x2e8504('0x7a7')]=_0x4762aa;}else{if(!_0x5c689c[_0x2e8504('0x1a2b')])return _0x669f7e[_0x2e8504('0x4b5')]['get']({'sectionId':_0x5c689c['id']})[_0x2e8504('0xa44')]['then'](function(_0x51dc68){const _0x18c417=_0x2e8504,_0x2ca3b4=_0x2cfb05()['map'](_0x51dc68[_0x18c417('0x269a')],function(_0x1ed432){const _0x2b49df=_0x18c417;return _0x2cfb05()[_0x2b49df('0xc38')](_0x281325[_0x2b49df('0x7a7')],{'id':_0x1ed432[_0x2b49df('0x24e8')]});});let _0x237b9c=null;_0x281325[_0x18c417('0x1d3e')]&&(_0x237b9c=_0x2cfb05()[_0x18c417('0xc38')](_0x281325[_0x18c417('0x7a7')],{'name':_0x281325[_0x18c417('0x1d3e')][_0x18c417('0x1d3e')]}));if(_0x237b9c&&!_0x2cfb05()[_0x18c417('0x1798')](_0x2ca3b4,['id',_0x237b9c['id']])){const _0x2e600d=_0x2cfb05()['find'](_0x281325['queues'],{'id':_0x237b9c['id']});_0x2e600d[_0x18c417('0x2378')]=![],_0x2ca3b4[_0x18c417('0x1514')](_0x2e600d);}_0x281325[_0x18c417('0x7a7')]=_0x2ca3b4;});}})[_0x1539c8('0x1a80')](function(_0x2787a1){const _0x471501=_0x1539c8;_0x49d8f8[_0x471501('0xfc9')]({'title':_0x2787a1[_0x471501('0x52d')]?_0x471501('0x1e21')+_0x2787a1[_0x471501('0x52d')]+_0x471501('0x11e1')+_0x2787a1[_0x471501('0xe1b')]:'SYSTEM:GETqueues','msg':_0x2787a1[_0x471501('0x25f4')]?JSON[_0x471501('0xbac')](_0x2787a1[_0x471501('0x25f4')]):_0x2787a1[_0x471501('0x1586')]()});});function _0x4b9308(){const _0x25ced5=_0x1539c8;_0x281325[_0x25ced5('0x61a')]=[];const _0x41b7e6=[];_0x281325['queue'][_0x25ced5('0x1345')]&&_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0x1345')]['toLowerCase']()===_0x25ced5('0x587')&&_0x281325[_0x25ced5('0x1d3e')]['appType']===_0x25ced5('0x867')&&(_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0x2026')]=_0x3c2e31['cutdigits']?(_0x281325['queue'][_0x25ced5('0x265a')]||'')+'${EXTEN:'+_0x3c2e31[_0x25ced5('0x2848')]+'}':(_0x281325['queue'][_0x25ced5('0x265a')]||'')+_0x25ced5('0x1d1'),_0x3c2e31[_0x25ced5('0x28cb')]!==_0x25ced5('0x192')?_0x281325['queue'][_0x25ced5('0xd39')]['indexOf'](_0x25ced5('0x1059'))<0x0&&(_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0xd39')]+=_0x25ced5('0x1059')):_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0xd39')]=_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0xd39')][_0x25ced5('0xf3')](_0x25ced5('0x1059'),''));const _0x57f146=_0x2cfb05()['find'](_0x281325[_0x25ced5('0x7a7')],{'name':_0x281325['queue']['queue']});_0x57f146&&(_0x281325[_0x25ced5('0x1d3e')][_0x2cfb05()[_0x25ced5('0x92c')](_0x25ced5('0x116e'))+_0x25ced5('0x1366')]=_0x57f146['id']);if(_0x281325['queue'][_0x25ced5('0x83f')]&&_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0x83f')]===_0x25ced5('0x2853')){}else switch((_0x281325['queue'][_0x25ced5('0x746')]||_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0x83f')])['toLowerCase']()){case'set':_0x281325[_0x25ced5('0x1d3e')]['appdata']=_0x281325['queue'][_0x25ced5('0x4f0')]+'='+_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0x18e0')];break;case _0x25ced5('0x2853'):break;default:_0x41b7e6[0x0]=_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0x1d3e')],_0x41b7e6[0x1]=_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0x651')],_0x281325[_0x25ced5('0x1d3e')][_0x25ced5('0x823')]=_0x41b7e6[_0x25ced5('0x45a')](',');}_0x569e76(_0x281325[_0x25ced5('0x1d3e')]);}function _0x569e76(_0x3addff){_0x152f12['hide'](_0x3addff);}}const _0x1247a1=_0x1a1161;_0x3da8e0['$inject']=['$mdDialog','$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x9d'),_0x36e6f4('0xcc5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x3da8e0(_0xdc1e91,_0xace7ac,_0x29c65b,_0x5c427f,_0x53a196,_0xba92a7,_0x11ff6b,_0x359a33){const _0x5e519a=_0x36e6f4,_0x154d9c=this;_0x154d9c[_0x5e519a('0x98')]=_0x11ff6b[_0x5e519a('0x26cd')](),_0x154d9c['errors']=[],_0x154d9c[_0x5e519a('0xcdc')]=_0x5e519a('0xb4a')+(_0x5c427f[_0x5e519a('0x83f')]||_0x5c427f['app'])['toUpperCase'](),_0x154d9c[_0x5e519a('0x1c2b')]=angular[_0x5e519a('0x225f')](_0x5c427f),_0x154d9c[_0x5e519a('0x243c')]=_0x359a33,_0x154d9c['hasModulePermissions']={};if(_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x823')])switch(_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x83f')]?_0x154d9c['system']['appType'][_0x5e519a('0x2574')]():_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x746')][_0x5e519a('0x2574')]()){case _0x5e519a('0x2853'):break;case _0x5e519a('0xded'):{const _0x4871c6=_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x823')][_0x5e519a('0x25c8')](',');_0x154d9c['system'][_0x5e519a('0x7ca')]=_0x4871c6[0x0],_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0xedb')]=_0x4871c6[0x1],_0x154d9c['system'][_0x5e519a('0x1634')]=_0x4871c6[_0x5e519a('0x233')](0x2,_0x4871c6[_0x5e519a('0x264b')])[_0x5e519a('0x45a')](',');}break;case _0x5e519a('0x1636'):{const _0x26a438=_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x823')][_0x5e519a('0x25c8')](',');_0x154d9c[_0x5e519a('0x1c2b')]['projectId']=_0x26a438[0x0],_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x27f3')]=_0x26a438[0x1],_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x170e')]=_0x26a438[0x2],_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0xedb')]=_0x26a438[0x3],_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x1634')]=_0x26a438[_0x5e519a('0x233')](0x4,_0x26a438[_0x5e519a('0x264b')])[_0x5e519a('0x45a')](',');}break;case _0x5e519a('0x86c'):{const _0x14d6b2=_0x154d9c['system'][_0x5e519a('0x823')][_0x5e519a('0x25c8')](',');_0x154d9c[_0x5e519a('0x1c2b')]['accesskeyid']=_0x14d6b2[0x0],_0x154d9c['system'][_0x5e519a('0x125')]=_0x14d6b2[0x1],_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x25a2')]=_0x14d6b2[0x2],_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x1ac4')]=_0x14d6b2[0x3],_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x1634')]=_0x14d6b2[_0x5e519a('0x233')](0x4,_0x14d6b2[_0x5e519a('0x264b')])['join'](',');}break;case _0x5e519a('0x1af7'):{const _0x42c6e0=_0x154d9c['system'][_0x5e519a('0x823')][_0x5e519a('0x25c8')](',');_0x154d9c['system'][_0x5e519a('0x265e')]=isNaN(_0x42c6e0[0x0])?_0x42c6e0[0x0]:parseInt(_0x42c6e0[0x0],0xa),_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x1640')]=_0x42c6e0['slice'](0x1,_0x42c6e0['length'])[_0x5e519a('0x45a')](',');}break;case _0x5e519a('0x1e70'):_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x1640')]=_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x823')];break;case _0x5e519a('0xceb'):_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x4f0')]=_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x823')][_0x5e519a('0x25c8')]('=')[0x0],_0x154d9c['system']['value']=_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x823')][_0x5e519a('0x25c8')]('=')[0x1];break;case _0x5e519a('0x1034'):_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x2588')]=_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x823')];break;default:{const _0x104be2=_0x154d9c[_0x5e519a('0x1c2b')]['appdata']['split'](',');_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x187')]=_0x2cfb05()[_0x5e519a('0x1081')](_0x104be2[0x0])?_0x104be2[0x0]:isNaN(_0x104be2[0x0])?_0x104be2[0x0]:parseInt(_0x104be2[0x0],0xa),_0x154d9c['system'][_0x5e519a('0x734')]=_0x2cfb05()['isEmpty'](_0x104be2[0x1])?_0x104be2[0x1]:isNaN(_0x104be2[0x1])?_0x104be2[0x1]:parseInt(_0x104be2[0x1],0xa);}break;}else _0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x734')]='';_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x1345')]&&_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x1345')][_0x5e519a('0x2574')]()===_0x5e519a('0x587')&&_0x154d9c[_0x5e519a('0x1c2b')]['appType'][_0x5e519a('0x2574')]()===_0x5e519a('0x2884')&&(_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x265a')]=_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x2026')]?_0x154d9c['system'][_0x5e519a('0x2026')][_0x5e519a('0x25c8')]('$')[0x0]:undefined,_0x154d9c[_0x5e519a('0x1c2b')][_0x5e519a('0x1f02')]=_0x154d9c[_0x5e519a('0x1c2b')]['callerID']?_0x5e519a('0xa4c')+_0x154d9c[_0x5e519a('0x1c2b')]['callerID']:undefined);_0x154d9c['saveWhatsappAccountApp']=_0x1a6832,_0x154d9c['closeDialog']=_0x1dd7d5,_0x11ff6b['hasRole'](_0x5e519a('0xa7c'))?_0xba92a7['variable']['get']({'fields':_0x5e519a('0x1776'),'sort':_0x5e519a('0x4f0'),'nolimit':_0x5e519a('0xf3b')})['$promise'][_0x5e519a('0x1166')](function(_0x3c8a1a){_0x154d9c['variables']=_0x3c8a1a['rows']||[];})['catch'](function(_0x5eb828){const _0xd7332a=_0x5e519a;_0x29c65b[_0xd7332a('0xfc9')]({'title':_0x5eb828[_0xd7332a('0x52d')]?_0xd7332a('0x1e21')+_0x5eb828['status']+_0xd7332a('0x11e1')+_0x5eb828[_0xd7332a('0xe1b')]:_0xd7332a('0xcf8'),'msg':_0x5eb828['data']?JSON[_0xd7332a('0xbac')](_0x5eb828[_0xd7332a('0x25f4')]):_0x5eb828[_0xd7332a('0x1586')]()});}):_0xba92a7[_0x5e519a('0x734')][_0x5e519a('0xd83')]({'fields':_0x5e519a('0x1776'),'sort':_0x5e519a('0x4f0'),'nolimit':_0x5e519a('0xf3b')})[_0x5e519a('0xa44')][_0x5e519a('0x1166')](function(_0x48f58d){const _0x53db92=_0x5e519a;_0x154d9c[_0x53db92('0x57a')]=_0x48f58d['rows']||[];})[_0x5e519a('0x1166')](function(){const _0x105ec1=_0x5e519a;return _0xba92a7['userProfileSection'][_0x105ec1('0xd83')]({'userProfileId':_0x154d9c[_0x105ec1('0x98')]['userProfileId'],'sectionId':0x3f4})[_0x105ec1('0xa44')];})['then'](function(_0x5a0421){const _0x6e1cd=_0x5e519a,_0x27690f=_0x5a0421&&_0x5a0421[_0x6e1cd('0x269a')]?_0x5a0421[_0x6e1cd('0x269a')][0x0]:null;if(!_0x27690f){const _0x2a6d9d=[];let _0x29f2e9=null;_0x154d9c['system']&&(_0x29f2e9=_0x2cfb05()[_0x6e1cd('0xc38')](_0x154d9c[_0x6e1cd('0x57a')],{'name':_0x154d9c[_0x6e1cd('0x1c2b')][_0x6e1cd('0x734')]}));for(let _0xe0e3a6=0x0;_0xe0e3a6<_0x154d9c[_0x6e1cd('0x57a')][_0x6e1cd('0x264b')];_0xe0e3a6++){_0x29f2e9&&_0x154d9c[_0x6e1cd('0x57a')][_0xe0e3a6]['id']===_0x29f2e9['id']&&(_0x154d9c['variables'][_0xe0e3a6][_0x6e1cd('0x2378')]=![],_0x2a6d9d[_0x6e1cd('0x1514')](_0x154d9c[_0x6e1cd('0x57a')][_0xe0e3a6]));}_0x154d9c['variables']=_0x2a6d9d;}else{if(!_0x27690f[_0x6e1cd('0x1a2b')])return _0xba92a7['userProfileResource']['get']({'sectionId':_0x27690f['id']})['$promise'][_0x6e1cd('0x1166')](function(_0x1896d0){const _0x45ac7a=_0x6e1cd,_0x2d003f=_0x2cfb05()['map'](_0x1896d0[_0x45ac7a('0x269a')],function(_0x229543){const _0x171e53=_0x45ac7a;return _0x2cfb05()['find'](_0x154d9c[_0x171e53('0x57a')],{'id':_0x229543[_0x171e53('0x24e8')]});});let _0x48e9bf=null;_0x154d9c[_0x45ac7a('0x1c2b')]&&(_0x48e9bf=_0x2cfb05()[_0x45ac7a('0xc38')](_0x154d9c[_0x45ac7a('0x57a')],{'name':_0x154d9c[_0x45ac7a('0x1c2b')][_0x45ac7a('0x734')]}));if(_0x48e9bf&&!_0x2cfb05()[_0x45ac7a('0x1798')](_0x2d003f,['id',_0x48e9bf['id']])){const _0x21a30d=_0x2cfb05()['find'](_0x154d9c[_0x45ac7a('0x57a')],{'id':_0x48e9bf['id']});_0x21a30d['canSelect']=![],_0x2d003f[_0x45ac7a('0x1514')](_0x21a30d);}_0x154d9c[_0x45ac7a('0x57a')]=_0x2d003f;});}})[_0x5e519a('0x1a80')](function(_0x53ecd0){const _0x1be0de=_0x5e519a;_0x29c65b['error']({'title':_0x53ecd0[_0x1be0de('0x52d')]?_0x1be0de('0x1e21')+_0x53ecd0[_0x1be0de('0x52d')]+_0x1be0de('0x11e1')+_0x53ecd0[_0x1be0de('0xe1b')]:'SYSTEM:GETvariables','msg':_0x53ecd0['data']?JSON[_0x1be0de('0xbac')](_0x53ecd0['data']):_0x53ecd0[_0x1be0de('0x1586')]()});});function _0x1a6832(){const _0x37af92=_0x5e519a;_0x154d9c['errors']=[];const _0x4c33c2=[];_0x154d9c[_0x37af92('0x1c2b')]['type']&&_0x154d9c['system']['type'][_0x37af92('0x2574')]()===_0x37af92('0x587')&&_0x154d9c['system']['appType']===_0x37af92('0x867')&&(_0x154d9c[_0x37af92('0x1c2b')]['phone']=_0x53a196['cutdigits']?(_0x154d9c[_0x37af92('0x1c2b')][_0x37af92('0x265a')]||'')+'${EXTEN:'+_0x53a196[_0x37af92('0x2848')]+'}':(_0x154d9c['system'][_0x37af92('0x265a')]||'')+_0x37af92('0x1d1'),_0x53a196[_0x37af92('0x28cb')]!=='none'?_0x154d9c[_0x37af92('0x1c2b')]['options'][_0x37af92('0x2379')]('U(xcally-mixmonitor-context)')<0x0&&(_0x154d9c[_0x37af92('0x1c2b')][_0x37af92('0xd39')]+=_0x37af92('0x1059')):_0x154d9c['system'][_0x37af92('0xd39')]=_0x154d9c[_0x37af92('0x1c2b')][_0x37af92('0xd39')]['replace'](_0x37af92('0x1059'),''));if(_0x154d9c[_0x37af92('0x1c2b')][_0x37af92('0x83f')]&&_0x154d9c[_0x37af92('0x1c2b')][_0x37af92('0x83f')]===_0x37af92('0x2853')){}else switch((_0x154d9c[_0x37af92('0x1c2b')][_0x37af92('0x746')]||_0x154d9c['system'][_0x37af92('0x83f')])['toLowerCase']()){case'set':_0x154d9c[_0x37af92('0x1c2b')]['appdata']=_0x154d9c['system'][_0x37af92('0x4f0')]+'='+_0x154d9c[_0x37af92('0x1c2b')][_0x37af92('0x18e0')];break;case'custom':break;default:_0x4c33c2[0x0]=_0x154d9c[_0x37af92('0x1c2b')]['command'],_0x4c33c2[0x1]=_0x154d9c[_0x37af92('0x1c2b')][_0x37af92('0x734')],_0x154d9c[_0x37af92('0x1c2b')]['appdata']=_0x4c33c2[_0x37af92('0x45a')](',');}_0x1dd7d5(_0x154d9c[_0x37af92('0x1c2b')]);}function _0x1dd7d5(_0x499d93){const _0x346fd0=_0x5e519a;_0xdc1e91[_0x346fd0('0x1197')](_0x499d93);}}const _0x4ea36f=_0x3da8e0;_0x4452d1['$inject']=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x9d'),_0x36e6f4('0xcc5'),_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x4452d1(_0x2468b2,_0x20a577,_0x1ce9b6,_0x148db3,_0x1c6a22,_0x5e3d2a,_0x511c50,_0x4910dd){const _0x345db0=_0x36e6f4,_0x5d2a88=this;_0x5d2a88[_0x345db0('0x98')]=_0x511c50[_0x345db0('0x26cd')](),_0x5d2a88[_0x345db0('0x61a')]=[],_0x5d2a88['title']='WHATSAPP.EDIT_'+(_0x148db3[_0x345db0('0x83f')]||_0x148db3[_0x345db0('0x746')])[_0x345db0('0x1387')](),_0x5d2a88[_0x345db0('0x1446')]=angular[_0x345db0('0x225f')](_0x148db3),_0x5d2a88[_0x345db0('0x243c')]=_0x4910dd,_0x5d2a88[_0x345db0('0x128b')]={};if(_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x823')])switch(_0x5d2a88[_0x345db0('0x1446')]['appType']?_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x83f')][_0x345db0('0x2574')]():_0x5d2a88[_0x345db0('0x1446')]['app'][_0x345db0('0x2574')]()){case'custom':break;case _0x345db0('0xded'):{const _0x45de2a=_0x5d2a88['tag'][_0x345db0('0x823')][_0x345db0('0x25c8')](',');_0x5d2a88['tag'][_0x345db0('0x7ca')]=_0x45de2a[0x0],_0x5d2a88['tag'][_0x345db0('0xedb')]=_0x45de2a[0x1],_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x1634')]=_0x45de2a[_0x345db0('0x233')](0x2,_0x45de2a[_0x345db0('0x264b')])['join'](',');}break;case _0x345db0('0x1636'):{const _0x213327=_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x823')][_0x345db0('0x25c8')](',');_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x1b0a')]=_0x213327[0x0],_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x27f3')]=_0x213327[0x1],_0x5d2a88['tag'][_0x345db0('0x170e')]=_0x213327[0x2],_0x5d2a88[_0x345db0('0x1446')]['language']=_0x213327[0x3],_0x5d2a88[_0x345db0('0x1446')]['welcomemessage']=_0x213327['slice'](0x4,_0x213327[_0x345db0('0x264b')])['join'](',');}break;case _0x345db0('0x86c'):{const _0x50c54e=_0x5d2a88[_0x345db0('0x1446')]['appdata'][_0x345db0('0x25c8')](',');_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0xee6')]=_0x50c54e[0x0],_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x125')]=_0x50c54e[0x1],_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x25a2')]=_0x50c54e[0x2],_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x1ac4')]=_0x50c54e[0x3],_0x5d2a88['tag']['welcomemessage']=_0x50c54e[_0x345db0('0x233')](0x4,_0x50c54e[_0x345db0('0x264b')])[_0x345db0('0x45a')](',');}break;case _0x345db0('0x1af7'):{const _0x5e8b6c=_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x823')]['split'](',');_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x265e')]=isNaN(_0x5e8b6c[0x0])?_0x5e8b6c[0x0]:parseInt(_0x5e8b6c[0x0],0xa),_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x1640')]=_0x5e8b6c[_0x345db0('0x233')](0x1,_0x5e8b6c[_0x345db0('0x264b')])[_0x345db0('0x45a')](',');}break;case _0x345db0('0x1e70'):_0x5d2a88[_0x345db0('0x1446')]['text']=_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x823')];break;case _0x345db0('0xceb'):_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x4f0')]=_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x823')][_0x345db0('0x25c8')]('=')[0x0],_0x5d2a88[_0x345db0('0x1446')]['value']=_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x823')][_0x345db0('0x25c8')]('=')[0x1];break;case _0x345db0('0x1034'):_0x5d2a88[_0x345db0('0x1446')]['project']=_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x823')];break;default:{const _0x16a772=_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x823')]['split'](',');_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x1446')]=_0x2cfb05()[_0x345db0('0x1081')](_0x16a772[0x0])?_0x16a772[0x0]:isNaN(_0x16a772[0x0])?_0x16a772[0x0]:parseInt(_0x16a772[0x0],0xa);}break;}else{}_0x5d2a88['tag'][_0x345db0('0x1345')]&&_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x1345')]['toLowerCase']()===_0x345db0('0x587')&&_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x83f')]['toLowerCase']()===_0x345db0('0x2884')&&(_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x265a')]=_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x2026')]?_0x5d2a88['tag'][_0x345db0('0x2026')]['split']('$')[0x0]:undefined,_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x1f02')]=_0x5d2a88[_0x345db0('0x1446')][_0x345db0('0x992')]?_0x345db0('0xa4c')+_0x5d2a88[_0x345db0('0x1446')]['callerID']:undefined);_0x5d2a88[_0x345db0('0xf14')]=_0x26f590,_0x5d2a88['closeDialog']=_0x4a4bca,_0x511c50[_0x345db0('0x1ac6')](_0x345db0('0xa7c'))?_0x5e3d2a[_0x345db0('0x1446')][_0x345db0('0xd83')]({'fields':'id,name','sort':_0x345db0('0x4f0'),'nolimit':_0x345db0('0xf3b')})[_0x345db0('0xa44')][_0x345db0('0x1166')](function(_0x363d07){const _0x2789e2=_0x345db0;_0x5d2a88[_0x2789e2('0xb38')]=_0x363d07[_0x2789e2('0x269a')]||[];})[_0x345db0('0x1a80')](function(_0x263e45){const _0x207da4=_0x345db0;_0x1ce9b6[_0x207da4('0xfc9')]({'title':_0x263e45[_0x207da4('0x52d')]?'API:'+_0x263e45[_0x207da4('0x52d')]+_0x207da4('0x11e1')+_0x263e45['statusText']:_0x207da4('0x402'),'msg':_0x263e45[_0x207da4('0x25f4')]?JSON[_0x207da4('0xbac')](_0x263e45[_0x207da4('0x25f4')]):_0x263e45[_0x207da4('0x1586')]()});}):_0x5e3d2a[_0x345db0('0x1446')][_0x345db0('0xd83')]({'fields':_0x345db0('0x1776'),'sort':'name','nolimit':_0x345db0('0xf3b')})[_0x345db0('0xa44')][_0x345db0('0x1166')](function(_0x148855){const _0x295e44=_0x345db0;_0x5d2a88[_0x295e44('0xb38')]=_0x148855['rows']||[];})[_0x345db0('0x1166')](function(){const _0x22ce0f=_0x345db0;return _0x5e3d2a[_0x22ce0f('0x17aa')][_0x22ce0f('0xd83')]({'userProfileId':_0x5d2a88[_0x22ce0f('0x98')][_0x22ce0f('0xb86')],'sectionId':0x3f0})[_0x22ce0f('0xa44')];})[_0x345db0('0x1166')](function(_0x2a25a6){const _0x4a14bd=_0x345db0,_0x2a33fa=_0x2a25a6&&_0x2a25a6[_0x4a14bd('0x269a')]?_0x2a25a6['rows'][0x0]:null;if(!_0x2a33fa){const _0x3c38b6=[];let _0x28aa05=null;_0x5d2a88['tag']&&(_0x28aa05=_0x2cfb05()[_0x4a14bd('0xc38')](_0x5d2a88[_0x4a14bd('0xb38')],{'name':_0x5d2a88[_0x4a14bd('0x1446')][_0x4a14bd('0x1446')]}));for(let _0x14aca3=0x0;_0x14aca3<_0x5d2a88[_0x4a14bd('0xb38')][_0x4a14bd('0x264b')];_0x14aca3++){_0x28aa05&&_0x5d2a88[_0x4a14bd('0xb38')][_0x14aca3]['id']===_0x28aa05['id']&&(_0x5d2a88[_0x4a14bd('0xb38')][_0x14aca3]['canSelect']=![],_0x3c38b6[_0x4a14bd('0x1514')](_0x5d2a88[_0x4a14bd('0xb38')][_0x14aca3]));}_0x5d2a88[_0x4a14bd('0xb38')]=_0x3c38b6;}else{if(!_0x2a33fa[_0x4a14bd('0x1a2b')])return _0x5e3d2a[_0x4a14bd('0x4b5')][_0x4a14bd('0xd83')]({'sectionId':_0x2a33fa['id']})[_0x4a14bd('0xa44')][_0x4a14bd('0x1166')](function(_0x3962be){const _0x17f95c=_0x4a14bd,_0x409e2b=_0x2cfb05()[_0x17f95c('0x2563')](_0x3962be[_0x17f95c('0x269a')],function(_0x3dad12){const _0x106243=_0x17f95c;return _0x2cfb05()[_0x106243('0xc38')](_0x5d2a88[_0x106243('0xb38')],{'id':_0x3dad12[_0x106243('0x24e8')]});});let _0x47137f=null;_0x5d2a88[_0x17f95c('0x1446')]&&(_0x47137f=_0x2cfb05()[_0x17f95c('0xc38')](_0x5d2a88['tags'],{'name':_0x5d2a88[_0x17f95c('0x1446')]['tag']}));if(_0x47137f&&!_0x2cfb05()[_0x17f95c('0x1798')](_0x409e2b,['id',_0x47137f['id']])){const _0x5b510f=_0x2cfb05()[_0x17f95c('0xc38')](_0x5d2a88['tags'],{'id':_0x47137f['id']});_0x5b510f[_0x17f95c('0x2378')]=![],_0x409e2b[_0x17f95c('0x1514')](_0x5b510f);}_0x5d2a88[_0x17f95c('0xb38')]=_0x409e2b;});}})[_0x345db0('0x1a80')](function(_0xb0cdc2){const _0x3be788=_0x345db0;_0x1ce9b6[_0x3be788('0xfc9')]({'title':_0xb0cdc2[_0x3be788('0x52d')]?_0x3be788('0x1e21')+_0xb0cdc2[_0x3be788('0x52d')]+_0x3be788('0x11e1')+_0xb0cdc2[_0x3be788('0xe1b')]:_0x3be788('0x9e'),'msg':_0xb0cdc2[_0x3be788('0x25f4')]?JSON[_0x3be788('0xbac')](_0xb0cdc2[_0x3be788('0x25f4')]):_0xb0cdc2[_0x3be788('0x1586')]()});});function _0x26f590(){const _0x3d87f3=_0x345db0;_0x5d2a88['errors']=[];const _0x443e2c=[];_0x5d2a88[_0x3d87f3('0x1446')][_0x3d87f3('0x1345')]&&_0x5d2a88[_0x3d87f3('0x1446')][_0x3d87f3('0x1345')][_0x3d87f3('0x2574')]()===_0x3d87f3('0x587')&&_0x5d2a88[_0x3d87f3('0x1446')]['appType']===_0x3d87f3('0x867')&&(_0x5d2a88['tag']['phone']=_0x1c6a22['cutdigits']?(_0x5d2a88[_0x3d87f3('0x1446')]['prefix']||'')+_0x3d87f3('0x881')+_0x1c6a22[_0x3d87f3('0x2848')]+'}':(_0x5d2a88[_0x3d87f3('0x1446')]['prefix']||'')+_0x3d87f3('0x1d1'),_0x1c6a22['recordingFormat']!==_0x3d87f3('0x192')?_0x5d2a88[_0x3d87f3('0x1446')][_0x3d87f3('0xd39')]['indexOf'](_0x3d87f3('0x1059'))<0x0&&(_0x5d2a88[_0x3d87f3('0x1446')]['options']+='U(xcally-mixmonitor-context)'):_0x5d2a88[_0x3d87f3('0x1446')]['options']=_0x5d2a88['tag'][_0x3d87f3('0xd39')][_0x3d87f3('0xf3')](_0x3d87f3('0x1059'),''));const _0x56bab6=_0x2cfb05()[_0x3d87f3('0xc38')](_0x5d2a88[_0x3d87f3('0xb38')],{'name':_0x5d2a88['tag']['tag']});_0x56bab6&&(_0x5d2a88[_0x3d87f3('0x1446')]['TagId']=_0x56bab6['id']);if(_0x5d2a88[_0x3d87f3('0x1446')]['appType']&&_0x5d2a88[_0x3d87f3('0x1446')][_0x3d87f3('0x83f')]===_0x3d87f3('0x2853')){}else switch((_0x5d2a88['tag']['app']||_0x5d2a88[_0x3d87f3('0x1446')][_0x3d87f3('0x83f')])[_0x3d87f3('0x2574')]()){case _0x3d87f3('0xceb'):_0x5d2a88[_0x3d87f3('0x1446')][_0x3d87f3('0x823')]=_0x5d2a88[_0x3d87f3('0x1446')][_0x3d87f3('0x4f0')]+'='+_0x5d2a88[_0x3d87f3('0x1446')][_0x3d87f3('0x18e0')];break;case _0x3d87f3('0x2853'):break;default:_0x443e2c[0x0]=_0x5d2a88['tag'][_0x3d87f3('0x1446')],_0x5d2a88[_0x3d87f3('0x1446')][_0x3d87f3('0x823')]=_0x443e2c['join'](',');}_0x4a4bca(_0x5d2a88[_0x3d87f3('0x1446')]);}function _0x4a4bca(_0x3fc2ea){const _0x24b6bc=_0x345db0;_0x2468b2[_0x24b6bc('0x1197')](_0x3fc2ea);}}const _0x132db8=_0x4452d1;_0x3ab8fc['$inject']=['$cookies',_0x36e6f4('0x36f'),'$state','$q','$translate',_0x36e6f4('0x8da'),_0x36e6f4('0x265d'),'$document',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),'Auth'];function _0x3ab8fc(_0x1a2613,_0x4fb278,_0x5f4300,_0x453dd4,_0x35ac91,_0x42ab6a,_0x295585,_0x503cbe,_0x360204,_0x3d378e,_0x2d2f02){const _0x22c86a=_0x36e6f4,_0x5b2ccb=this;_0x5b2ccb[_0x22c86a('0x98')]=_0x2d2f02[_0x22c86a('0x26cd')](),_0x5b2ccb[_0x22c86a('0xcc5')]={},_0x5b2ccb[_0x22c86a('0x10bc')]={'count':0x0,'rows':[]},_0x5b2ccb[_0x22c86a('0x1f22')]=[],_0x5b2ccb[_0x22c86a('0x243c')],_0x5b2ccb[_0x22c86a('0x2218')]={'read':_0x22c86a('0x15d7'),'closed':_0x22c86a('0x15d7'),'sort':'-createdAt','includeAll':_0x22c86a('0xf3b'),'limit':0xa,'page':0x1},_0x5b2ccb[_0x22c86a('0x24d5')]=_0x2e258f,_0x5b2ccb[_0x22c86a('0x8a2')]=_0x3cb522,_0x5b2ccb[_0x22c86a('0x7fc')]=_0x192851,_0x5b2ccb[_0x22c86a('0x103b')]=_0x2ce8e0,_0x5b2ccb['getWhatsappAccountInteractions']=_0x3def38,_0x5b2ccb[_0x22c86a('0x1782')]=_0x45cda8,_0x5b2ccb[_0x22c86a('0x138b')]=_0x41dc73,_0x5b2ccb[_0x22c86a('0x6b9')]=_0x16c092,_0x5b2ccb[_0x22c86a('0x1d5a')]=_0x3eb416,_0x5b2ccb['deleteSelectedWhatsappAccountInteractions']=_0x5ba7d9;function _0x2e258f(_0x5f08f1,_0x4967e1){const _0x4cb762=_0x22c86a;_0x5b2ccb['whatsappAccount']=_0x5f08f1,_0x5b2ccb['crudPermissions']=typeof _0x4967e1!=='undefined'?_0x4967e1:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x5b2ccb[_0x4cb762('0x2218')][_0x4cb762('0x1b88')]=_0x5b2ccb[_0x4cb762('0xcc5')]['id'],_0x5b2ccb[_0x4cb762('0x1291')]={'fields':_0x8044ce()},_0xd8426();}function _0xd8426(){const _0x53250c=_0x22c86a;return _0x3d378e[_0x53250c('0x1446')]['get']()[_0x53250c('0xa44')]['then'](function(_0x28195f){const _0x4d5022=_0x53250c;_0x5b2ccb[_0x4d5022('0xb38')]=_0x28195f||{'count':0x0,'rows':[]};})[_0x53250c('0x1166')](function(){_0x5b2ccb['quickFilters']=_0x2a12d8();});}function _0x2a12d8(){const _0x15ad2e=_0x22c86a;return[{'name':_0x15ad2e('0x2567'),'key':_0x15ad2e('0x262'),'type':_0x15ad2e('0x1643'),'label':_0x15ad2e('0x16d9')},{'name':'Messages','key':_0x15ad2e('0x123'),'type':_0x15ad2e('0x88a'),'label':_0x15ad2e('0x379'),'customOptions':[{'value':0x0,'translate':_0x15ad2e('0x2c8')},{'value':0x1,'translate':_0x15ad2e('0x1057')},{'value':null,'translate':_0x15ad2e('0x2150')}]},{'name':'Status','key':'closed','type':_0x15ad2e('0x88a'),'label':'DASHBOARDS.SELECT_STATUS','customOptions':[{'value':0x0,'translate':_0x15ad2e('0xdeb')},{'value':0x1,'translate':_0x15ad2e('0x58f')},{'value':null,'translate':_0x15ad2e('0x2150')}]},{'name':'Agent','key':'UserId','type':_0x15ad2e('0x88a'),'label':_0x15ad2e('0x1db1'),'customOptions':[{'value':_0x15ad2e('0x15d7'),'translate':_0x15ad2e('0x216b')},{'value':undefined,'translate':_0x15ad2e('0x2150')}]},{'name':_0x15ad2e('0x1b35'),'key':_0x15ad2e('0x1446'),'type':_0x15ad2e('0x2162'),'label':'DASHBOARDS.SELECT_TAG','options':_0x5b2ccb[_0x15ad2e('0xb38')][_0x15ad2e('0x269a')],'placeholder':_0x15ad2e('0x2223')}];}function _0x8044ce(){const _0xb6f62b=_0x22c86a;return[{'name':'Id','column':'id','type':_0xb6f62b('0xc45')},{'name':_0xb6f62b('0x21a4'),'column':_0xb6f62b('0x21a4'),'type':'autocomplete','options':{'searchFields':[_0xb6f62b('0x18cb'),_0xb6f62b('0xeb0'),_0xb6f62b('0x66f')],'route':{'model':_0xb6f62b('0x149e'),'action':_0xb6f62b('0xd83'),'params':{'fields':'id,firstName,lastName,email','Contact':_0xb6f62b('0x145b'),'nolimit':!![]}},'extraOperators':[_0xb6f62b('0x2836')],'excludedOperators':['$ne']}},{'name':'Subject','column':_0xb6f62b('0x210d'),'type':_0xb6f62b('0x1640'),'options':{'excludedOperators':[_0xb6f62b('0x110'),_0xb6f62b('0x2646')]}},{'name':'Body','column':'plainBody','type':_0xb6f62b('0x1640'),'options':{'excludedOperators':[_0xb6f62b('0x110'),'$ne']}},{'name':'Status','column':'closed','type':_0xb6f62b('0x88a'),'values':[{'id':0x0,'translate':'DASHBOARDS.OPENED'},{'id':0x1,'translate':_0xb6f62b('0x58f')}],'options':{'excludedOperators':['$ne']}},{'name':_0xb6f62b('0x89b'),'column':'User','type':'autocomplete','options':{'table':'i','route':{'model':_0xb6f62b('0x557'),'action':_0xb6f62b('0xd83'),'params':{'role':'agent','fields':_0xb6f62b('0xce1'),'nolimit':!![]}},'searchFields':[_0xb6f62b('0x6e1'),_0xb6f62b('0x4f0')],'extraOperators':[_0xb6f62b('0x2836')],'excludedOperators':['$ne']}},{'name':_0xb6f62b('0x21c2'),'column':'Tag','type':_0xb6f62b('0x2162'),'options':{'route':{'model':_0xb6f62b('0x1446'),'action':_0xb6f62b('0xd83'),'params':{'nolimit':!![]}},'excludedOperators':['$notIn']}},{'name':_0xb6f62b('0x2567'),'column':_0xb6f62b('0x262'),'type':_0xb6f62b('0x1643'),'options':{'excludedOperators':[_0xb6f62b('0x2646')]}},{'name':_0xb6f62b('0xf43'),'column':'unreadMessages','type':_0xb6f62b('0x88a'),'values':[{'id':0x1,'translate':_0xb6f62b('0x1057')},{'id':0x0,'translate':_0xb6f62b('0x2c8')}],'options':{'excludedOperators':[_0xb6f62b('0x2646')]}}];}function _0x41dc73(){const _0x223432=_0x22c86a;_0x295585['show']({'controller':_0x223432('0x27f'),'controllerAs':'vm','templateUrl':_0x120bea,'parent':angular['element'](_0x503cbe[_0x223432('0x8d2')]),'clickOutsideToClose':![],'locals':{'fields':_0x5b2ccb['advancedSearch'][_0x223432('0xfe2')],'color':undefined,'storagePath':'whatsapp.whatsappAccounts'},'fullscreen':!![]})[_0x223432('0x1166')](function(_0x51aa36){const _0x63fd2a=_0x223432;_0x5b2ccb[_0x63fd2a('0x2218')]['search']=_0x51aa36===![]?undefined:_0x51aa36;if(_0x5b2ccb[_0x63fd2a('0x2218')][_0x63fd2a('0xe07')])_0x3def38();else _0x51aa36===![]&&_0x3def38();})[_0x223432('0x1a80')](function(_0x2a0aa8){const _0x23bb62=_0x223432;_0x360204[_0x23bb62('0xfc9')]({'title':_0x23bb62('0x2272'),'msg':_0x2a0aa8[_0x23bb62('0x25f4')]?JSON[_0x23bb62('0xbac')](_0x2a0aa8[_0x23bb62('0x25f4')]['message']):_0x2a0aa8[_0x23bb62('0x1586')]()});});}function _0x192851(_0x14231e,_0x26fc46,_0xf8db60){const _0x58234a=_0x22c86a;return _0x3d378e[_0x58234a('0x2073')][_0x58234a('0x2ad')]({'id':_0x14231e['id'],'exists':!![],'attachments':_0xf8db60})[_0x58234a('0xa44')]['then'](function(_0x3fa2f5){const _0x466aff=_0x58234a,_0x50e01e=[_0x3fa2f5[_0x466aff('0x20ed')]];let _0x471139='interaction'+_0x14231e['id'];const _0x43c439=new Blob(_0x50e01e,{'type':_0x3fa2f5[_0x466aff('0x1345')]});_0x471139='whatsapp-interaction'+_0x14231e['id']+'.zip';const _0x4c388e=window[_0x466aff('0x136d')][_0x466aff('0xdd')]('a');_0x4c388e['setAttribute'](_0x466aff('0x14f9'),URL[_0x466aff('0x215a')](_0x43c439)),_0x4c388e[_0x466aff('0xffd')](_0x466aff('0x2ad'),_0x471139),document[_0x466aff('0x8d2')]['appendChild'](_0x4c388e),_0x4c388e[_0x466aff('0x3b4')]();})[_0x58234a('0x1a80')](function(_0x19500a){const _0x528cad=_0x58234a;if(_0x19500a[_0x528cad('0x25f4')]&&_0x19500a[_0x528cad('0x25f4')][_0x528cad('0x61a')]&&_0x19500a[_0x528cad('0x25f4')][_0x528cad('0x61a')][_0x528cad('0x264b')])for(let _0x87c986=0x0;_0x87c986<_0x19500a[_0x528cad('0x25f4')][_0x528cad('0x61a')][_0x528cad('0x264b')];_0x87c986+=0x1){_0x360204[_0x528cad('0xfc9')]({'title':_0x19500a[_0x528cad('0x25f4')][_0x528cad('0x61a')][_0x87c986][_0x528cad('0x1345')],'msg':_0x19500a[_0x528cad('0x25f4')][_0x528cad('0x61a')][_0x87c986][_0x528cad('0x1e70')]});}else _0x360204[_0x528cad('0xfc9')]({'title':_0x19500a[_0x528cad('0x52d')]?'API:'+_0x19500a['status']+_0x528cad('0x11e1')+_0x19500a[_0x528cad('0xe1b')]:_0x528cad('0x18f6'),'msg':_0x19500a[_0x528cad('0x25f4')]?JSON[_0x528cad('0xbac')](_0x19500a[_0x528cad('0x25f4')][_0x528cad('0x1e70')]):_0x19500a[_0x528cad('0x1586')]()});});}function _0x3cb522(_0x15a90f,_0x3e3b65){const _0x484ca7=_0x22c86a,_0xc489de=_0x295585[_0x484ca7('0x1d26')]()[_0x484ca7('0xcdc')](_0x484ca7('0xced'))['htmlContent'](_0x484ca7('0x12b5')+(_0x15a90f['name']||_0x15a90f['id']&&_0x2cfb05()[_0x484ca7('0x114b')](_0x484ca7('0x2625'))+_0x15a90f['id']||_0x484ca7('0x25e6'))+''+'\x20will\x20be\x20deleted.')[_0x484ca7('0x8e8')](_0x484ca7('0xa04'))[_0x484ca7('0x203b')](_0x3e3b65)['ok']('OK')[_0x484ca7('0x3f')]('CANCEL');_0x295585[_0x484ca7('0x1f80')](_0xc489de)[_0x484ca7('0x1166')](function(){_0x3eb416(_0x15a90f);},function(){const _0x1091e8=_0x484ca7;console[_0x1091e8('0x455')](_0x1091e8('0x2d3'));});}function _0x2ce8e0(_0x505776){const _0x565adc=_0x22c86a;_0x5b2ccb[_0x565adc('0x10bc')]=_0x505776||{'count':0x0,'rows':[]};for(let _0xea3b0f=0x0;_0xea3b0f<_0x5b2ccb[_0x565adc('0x10bc')][_0x565adc('0x269a')][_0x565adc('0x264b')];_0xea3b0f+=0x1){const _0x532f78=_0x5b2ccb[_0x565adc('0x10bc')][_0x565adc('0x269a')][_0xea3b0f];_0x43d842(_0x532f78),_0x532f78[_0x565adc('0x121b')][_0x565adc('0x4f0')]=_0x3c9be3(_0x532f78);}}function _0x3def38(){const _0x4cba6c=_0x22c86a;_0x5b2ccb[_0x4cba6c('0x2218')][_0x4cba6c('0x1098')]=(_0x5b2ccb[_0x4cba6c('0x2218')][_0x4cba6c('0x1a43')]-0x1)*_0x5b2ccb['query'][_0x4cba6c('0x163f')],_0x5b2ccb[_0x4cba6c('0x1f48')]=_0x3d378e[_0x4cba6c('0x2073')]['get'](_0x5b2ccb['query'],_0x2ce8e0)[_0x4cba6c('0xa44')];}function _0x45cda8(_0x329884,_0x5756b5){const _0x293008=_0x22c86a;_0x295585[_0x293008('0x1f80')]({'controller':_0x293008('0x19ad'),'controllerAs':'vm','templateUrl':_0xbfcb18,'parent':angular[_0x293008('0x1194')](_0x503cbe[_0x293008('0x8d2')]),'targetEvent':_0x329884,'clickOutsideToClose':!![],'onShowing':function(_0xef9aa0){const _0x129974=_0x293008;_0xef9aa0['vm'][_0x129974('0x24d5')]({'id':0x1,'channel':_0x129974('0x116e'),'interaction':_0x5756b5,'spy':!![]},_0x4fb278[_0x129974('0x23ac')]['vm'][_0x129974('0xf8a')]);}});}function _0x3eb416(_0x5be9e2){const _0x413e60=_0x22c86a;_0x3d378e[_0x413e60('0x2073')][_0x413e60('0x906')]({'id':_0x5be9e2['id']})['$promise']['then'](function(){const _0x452497=_0x413e60;_0x2cfb05()['remove'](_0x5b2ccb['whatsappAccountInteractions'][_0x452497('0x269a')],{'id':_0x5be9e2['id']}),_0x5b2ccb['whatsappAccountInteractions']['count']-=0x1,!_0x5b2ccb[_0x452497('0x10bc')][_0x452497('0x269a')][_0x452497('0x264b')]&&_0x3def38(),_0x360204[_0x452497('0x103b')]({'title':'Interaction\x20deleted!','msg':_0x5be9e2['name']?_0x5be9e2[_0x452497('0x4f0')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x3bf2e6){const _0x3d963f=_0x413e60;if(_0x3bf2e6[_0x3d963f('0x25f4')]&&_0x3bf2e6[_0x3d963f('0x25f4')]['errors']&&_0x3bf2e6[_0x3d963f('0x25f4')][_0x3d963f('0x61a')][_0x3d963f('0x264b')]){_0x5b2ccb['errors']=_0x3bf2e6[_0x3d963f('0x25f4')][_0x3d963f('0x61a')]||[{'message':_0x3bf2e6[_0x3d963f('0x1586')](),'type':_0x3d963f('0x82c')}];for(let _0x1fb935=0x0;_0x1fb935<_0x3bf2e6[_0x3d963f('0x25f4')][_0x3d963f('0x61a')][_0x3d963f('0x264b')];_0x1fb935++){_0x360204[_0x3d963f('0xfc9')]({'title':_0x3bf2e6[_0x3d963f('0x25f4')]['errors'][_0x1fb935][_0x3d963f('0x1345')],'msg':_0x3bf2e6[_0x3d963f('0x25f4')]['errors'][_0x1fb935][_0x3d963f('0x1e70')]});}}else _0x360204[_0x3d963f('0xfc9')]({'title':_0x3bf2e6[_0x3d963f('0x52d')]?_0x3d963f('0x1e21')+_0x3bf2e6[_0x3d963f('0x52d')]+_0x3d963f('0x11e1')+_0x3bf2e6[_0x3d963f('0xe1b')]:_0x3d963f('0x82c'),'msg':_0x3bf2e6[_0x3d963f('0x25f4')]?JSON[_0x3d963f('0xbac')](_0x3bf2e6[_0x3d963f('0x25f4')]['message']):_0x3bf2e6['message']||_0x3bf2e6[_0x3d963f('0x1586')]()});});}function _0x16c092(){const _0x271a12=_0x22c86a,_0xe0651a=angular[_0x271a12('0x225f')](_0x5b2ccb[_0x271a12('0x1f22')]);return _0x5b2ccb[_0x271a12('0x1f22')]=[],_0xe0651a;}function _0x5ba7d9(_0x17485c){const _0x181946=_0x22c86a,_0x131970=_0x295585['confirm']()[_0x181946('0xcdc')](_0x181946('0x5dd'))[_0x181946('0xf3c')](_0x181946('0x12b5')+_0x5b2ccb[_0x181946('0x1f22')][_0x181946('0x264b')]+_0x181946('0x196d')+_0x181946('0x3f3'))[_0x181946('0x8e8')](_0x181946('0x1623'))['targetEvent'](_0x17485c)['ok']('OK')[_0x181946('0x3f')](_0x181946('0x2d3'));_0x295585['show'](_0x131970)['then'](function(){const _0x525bc2=_0x181946;_0x5b2ccb['selectedWhatsappAccountInteractions'][_0x525bc2('0x2782')](function(_0x1655c7){_0x3eb416(_0x1655c7);}),_0x5b2ccb[_0x525bc2('0x1f22')]=[];});}function _0x43d842(_0x430597){const _0x31777d=_0x22c86a;_0x430597['Contact']?_0x430597[_0x31777d('0x15cf')]=(_0x430597[_0x31777d('0x21a4')][_0x31777d('0x18cb')]||'')+'\x20'+(_0x430597[_0x31777d('0x21a4')]['lastName']||''):_0x430597[_0x31777d('0x15cf')]=_0x35ac91['instant']('DASHBOARDS.UNKNOWN');}function _0x3c9be3(_0x39b7e5){const _0x41b58d=_0x22c86a;if(_0x39b7e5[_0x41b58d('0x122a')])return _0x39b7e5[_0x41b58d('0x122a')]===_0x5b2ccb['currentUser']['id']?_0x35ac91[_0x41b58d('0x25cc')](_0x41b58d('0x15ae')):_0x39b7e5[_0x41b58d('0x121b')]['fullname']+'\x20<'+_0x39b7e5[_0x41b58d('0x121b')][_0x41b58d('0x1eef')]+'>';return _0x35ac91['instant'](_0x41b58d('0x216b'));}let _0x2fc7e7=!![],_0xd0a6f7=0x1;_0x4fb278[_0x22c86a('0xe83')](_0x22c86a('0x28b4'),function(_0x18b6cd,_0x5f1cad){const _0x19bfcb=_0x22c86a;_0x2fc7e7?_0x42ab6a(function(){_0x2fc7e7=![];}):(!_0x5f1cad&&(_0xd0a6f7=_0x5b2ccb['query'][_0x19bfcb('0x1a43')]),_0x18b6cd!==_0x5f1cad&&(_0x5b2ccb[_0x19bfcb('0x2218')][_0x19bfcb('0x1a43')]=0x1),!_0x18b6cd&&(_0x5b2ccb[_0x19bfcb('0x2218')]['page']=_0xd0a6f7),_0x3def38());});}const _0x57ba21=_0x3ab8fc,_0x18545e=_0x2734b2['p']+_0x36e6f4('0x1c82');_0x65a464['$inject']=['$state',_0x36e6f4('0x25e0'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0xcc5'),_0x36e6f4('0x17aa')];function _0x65a464(_0x719077,_0x4d88d0,_0xb99392,_0xe8d544,_0x401cd9,_0x17886f,_0x1d9f92,_0x15ab9b,_0x352eae,_0x498bf8,_0x462f19,_0x12fd8d){const _0x32bdad=_0x36e6f4,_0xb8742f=this;_0xb8742f[_0x32bdad('0x98')]=_0x498bf8['getCurrentUser'](),_0xb8742f[_0x32bdad('0x5c9')]=_0x17886f,_0xb8742f[_0x32bdad('0xf8a')]=_0x1d9f92,_0xb8742f['passwordPattern']=_0xb8742f[_0x32bdad('0xf8a')][_0x32bdad('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xb8742f[_0x32bdad('0x246b')]=_0x4d88d0[_0x32bdad('0x6f1')]()+_0x32bdad('0xc51')+_0x4d88d0['host'](),_0xb8742f[_0x32bdad('0xcc5')]=_0x462f19||_0x719077['params'][_0x32bdad('0xcc5')]||{},_0xb8742f[_0x32bdad('0x17aa')]=_0x12fd8d&&_0x12fd8d[_0x32bdad('0x240f')]==0x1?_0x12fd8d['rows'][0x0]:null,_0xb8742f[_0x32bdad('0x243c')]=_0x498bf8[_0x32bdad('0xd87')](_0xb8742f['userProfileSection']?_0xb8742f[_0x32bdad('0x17aa')][_0x32bdad('0x243c')]:null),_0xb8742f[_0x32bdad('0x128b')]={},_0xb8742f[_0x32bdad('0x2669')]=_0x719077[_0x32bdad('0x23f')][_0x32bdad('0xbe3')]||0x0,_0xb8742f[_0x32bdad('0x1728')]=_0x21f832,_0xb8742f['alert']=_0x352eae[_0x32bdad('0x1fa1')],_0xb8742f[_0x32bdad('0xc3f')]=_0x168e81,_0xb8742f[_0x32bdad('0x1cb3')]=_0x55f4d5,_0x498bf8[_0x32bdad('0x1ac6')]('admin')?_0x15ab9b[_0x32bdad('0xdd9')][_0x32bdad('0xd83')]({'fields':'id,name','sort':_0x32bdad('0x4f0')})[_0x32bdad('0xa44')][_0x32bdad('0x1166')](function(_0x44d01f){const _0x24e7f3=_0x32bdad;_0xb8742f[_0x24e7f3('0x8de')]=_0x44d01f[_0x24e7f3('0x269a')]||[];})[_0x32bdad('0x1a80')](function(_0x36a595){const _0xaec6f6=_0x32bdad;_0x352eae['error']({'title':_0x36a595[_0xaec6f6('0x52d')]?_0xaec6f6('0x1e21')+_0x36a595[_0xaec6f6('0x52d')]+_0xaec6f6('0x11e1')+_0x36a595['statusText']:'SYSTEM:GET_LISTS','msg':_0x36a595[_0xaec6f6('0x25f4')]?JSON[_0xaec6f6('0xbac')](_0x36a595[_0xaec6f6('0x25f4')]):_0x36a595[_0xaec6f6('0x1586')]()});}):_0x15ab9b['cmList']['get']({'fields':_0x32bdad('0x1776'),'sort':'name'})['$promise'][_0x32bdad('0x1166')](function(_0x23ee10){const _0x566d8b=_0x32bdad;_0xb8742f['lists']=_0x23ee10[_0x566d8b('0x269a')]||[];})[_0x32bdad('0x1166')](function(){const _0x54e0e9=_0x32bdad;return _0x15ab9b[_0x54e0e9('0x17aa')][_0x54e0e9('0xd83')]({'userProfileId':_0xb8742f[_0x54e0e9('0x98')][_0x54e0e9('0xb86')],'sectionId':0x12d})['$promise'];})[_0x32bdad('0x1166')](function(_0xee297b){const _0x10a96c=_0x32bdad,_0x804fd0=_0xee297b&&_0xee297b['rows']?_0xee297b[_0x10a96c('0x269a')][0x0]:null;if(!_0x804fd0){const _0xf875c5=[];let _0x56733f=null;_0xb8742f['whatsappAccount']&&(_0x56733f=_0x2cfb05()['find'](_0xb8742f['lists'],{'id':Number(_0xb8742f[_0x10a96c('0xcc5')][_0x10a96c('0x23c')])}));for(let _0x15d7d5=0x0;_0x15d7d5<_0xb8742f[_0x10a96c('0x8de')][_0x10a96c('0x264b')];_0x15d7d5++){_0x56733f&&_0xb8742f[_0x10a96c('0x8de')][_0x15d7d5]['id']===_0x56733f['id']&&(_0xb8742f[_0x10a96c('0x8de')][_0x15d7d5][_0x10a96c('0x2378')]=![],_0xf875c5['push'](_0xb8742f[_0x10a96c('0x8de')][_0x15d7d5]));}_0xb8742f[_0x10a96c('0x8de')]=_0xf875c5;}else{if(!_0x804fd0[_0x10a96c('0x1a2b')])return _0x15ab9b['userProfileResource'][_0x10a96c('0xd83')]({'sectionId':_0x804fd0['id']})[_0x10a96c('0xa44')]['then'](function(_0x230c65){const _0x1cac53=_0x10a96c,_0x5bfbfa=_0x2cfb05()[_0x1cac53('0x2563')](_0x230c65[_0x1cac53('0x269a')],function(_0x515f3c){const _0x949faf=_0x1cac53;return _0x2cfb05()[_0x949faf('0xc38')](_0xb8742f[_0x949faf('0x8de')],{'id':_0x515f3c[_0x949faf('0x24e8')]});});let _0x52f00f=null;_0xb8742f['whatsappAccount']&&(_0x52f00f=_0x2cfb05()[_0x1cac53('0xc38')](_0xb8742f[_0x1cac53('0x8de')],{'id':Number(_0xb8742f['whatsappAccount'][_0x1cac53('0x23c')])}));if(_0x52f00f&&!_0x2cfb05()[_0x1cac53('0x1798')](_0x5bfbfa,['id',_0x52f00f['id']])){const _0x5e423c=_0x2cfb05()[_0x1cac53('0xc38')](_0xb8742f[_0x1cac53('0x8de')],{'id':_0x52f00f['id']});_0x5e423c[_0x1cac53('0x2378')]=![],_0x5bfbfa[_0x1cac53('0x1514')](_0x5e423c);}_0xb8742f[_0x1cac53('0x8de')]=_0x5bfbfa;});}})[_0x32bdad('0x1a80')](function(_0x10e3ce){const _0x137e48=_0x32bdad;_0x352eae['error']({'title':_0x10e3ce[_0x137e48('0x52d')]?_0x137e48('0x1e21')+_0x10e3ce[_0x137e48('0x52d')]+_0x137e48('0x11e1')+_0x10e3ce[_0x137e48('0xe1b')]:_0x137e48('0x1248'),'msg':_0x10e3ce[_0x137e48('0x25f4')]?JSON[_0x137e48('0xbac')](_0x10e3ce[_0x137e48('0x25f4')]):_0x10e3ce[_0x137e48('0x1586')]()});}),_0x498bf8[_0x32bdad('0x1ac6')]('admin')?_0x15ab9b[_0x32bdad('0x1e77')]['get']({'fields':_0x32bdad('0xcb8'),'sort':_0x32bdad('0x4f0'),'nolimit':_0x32bdad('0xf3b')})[_0x32bdad('0xa44')][_0x32bdad('0x1166')](function(_0x4c31f0){const _0x207b9d=_0x32bdad;_0xb8742f[_0x207b9d('0xe29')]=_0x4c31f0[_0x207b9d('0x269a')]||[];})[_0x32bdad('0x1a80')](function(_0x186898){const _0x47d8d7=_0x32bdad;_0x352eae[_0x47d8d7('0xfc9')]({'title':_0x186898[_0x47d8d7('0x52d')]?_0x47d8d7('0x1e21')+_0x186898[_0x47d8d7('0x52d')]+_0x47d8d7('0x11e1')+_0x186898['statusText']:_0x47d8d7('0x18ed'),'msg':_0x186898['data']?JSON[_0x47d8d7('0xbac')](_0x186898['data']):_0x186898['toString']()});}):_0x15ab9b[_0x32bdad('0x1e77')][_0x32bdad('0xd83')]({'fields':_0x32bdad('0xcb8'),'sort':_0x32bdad('0x4f0'),'nolimit':_0x32bdad('0xf3b')})['$promise']['then'](function(_0x29dd9d){const _0x2036c1=_0x32bdad;_0xb8742f[_0x2036c1('0xe29')]=_0x29dd9d[_0x2036c1('0x269a')]||[];})[_0x32bdad('0x1166')](function(){const _0x4286af=_0x32bdad;return _0x15ab9b['userProfileSection'][_0x4286af('0xd83')]({'userProfileId':_0xb8742f['currentUser'][_0x4286af('0xb86')],'sectionId':0x3ed})['$promise'];})[_0x32bdad('0x1166')](function(_0x202f4a){const _0x2b35fe=_0x32bdad,_0x25b770=_0x202f4a&&_0x202f4a[_0x2b35fe('0x269a')]?_0x202f4a[_0x2b35fe('0x269a')][0x0]:null;if(!_0x25b770)_0xb8742f[_0x2b35fe('0xe29')]=[];else{if(!_0x25b770[_0x2b35fe('0x1a2b')])return _0x15ab9b['userProfileResource']['get']({'sectionId':_0x25b770['id']})[_0x2b35fe('0xa44')][_0x2b35fe('0x1166')](function(_0x1afba0){const _0x12d245=_0x2b35fe,_0x54b4b4=_0x2cfb05()[_0x12d245('0x2563')](_0x1afba0[_0x12d245('0x269a')],function(_0x290dc0){const _0xfaf1a9=_0x12d245;return _0x2cfb05()['find'](_0xb8742f[_0xfaf1a9('0xe29')],{'id':_0x290dc0[_0xfaf1a9('0x24e8')]});});_0xb8742f[_0x12d245('0xe29')][_0x12d245('0x2782')](function(_0x4260ae){const _0x351b7b=_0x12d245;!_0x2cfb05()['some'](_0x54b4b4,['id',_0x4260ae['id']])&&(_0x4260ae[_0x351b7b('0x2378')]=![]),_0x54b4b4[_0x351b7b('0x1514')](_0x4260ae);}),_0xb8742f[_0x12d245('0xe29')]=_0x54b4b4;});}})[_0x32bdad('0x1a80')](function(_0x48b1a4){const _0x41176f=_0x32bdad;_0x352eae[_0x41176f('0xfc9')]({'title':_0x48b1a4[_0x41176f('0x52d')]?'API:'+_0x48b1a4[_0x41176f('0x52d')]+_0x41176f('0x11e1')+_0x48b1a4[_0x41176f('0xe1b')]:'SYSTEM:GETpauses','msg':_0x48b1a4['data']?JSON[_0x41176f('0xbac')](_0x48b1a4[_0x41176f('0x25f4')]):_0x48b1a4['toString']()});});function _0x21f832(_0x5bd125,_0x14f283){const _0x437d25=_0x32bdad;_0xb99392[_0x437d25('0x1f80')]({'controller':_0x437d25('0x1577'),'controllerAs':'vm','templateUrl':_0x18545e,'parent':angular[_0x437d25('0x1194')](_0xe8d544[_0x437d25('0x8d2')]),'targetEvent':_0x14f283,'clickOutsideToClose':!![],'locals':{'whatsappAccount':_0x5bd125,'whatsappAccounts':_0xb8742f[_0x437d25('0x1974')]?_0xb8742f[_0x437d25('0x1974')][_0x437d25('0x269a')]:[],'crudPermissions':_0xb8742f['crudPermissions'],'realtime':![]}});}function _0x168e81(){const _0x590879=_0x32bdad;_0x719077['go'](_0x590879('0x317'),{},{'reload':_0x590879('0x317')});}function _0x55f4d5(){const _0x58538b=_0x32bdad;_0x15ab9b[_0x58538b('0xcc5')][_0x58538b('0x1449')]({'id':_0xb8742f[_0x58538b('0xcc5')]['id']},_0xb8742f[_0x58538b('0xcc5')])['$promise'][_0x58538b('0x1166')](function(){const _0x18090=_0x58538b;_0x352eae[_0x18090('0x103b')]({'title':_0x18090('0x2f6'),'msg':_0xb8742f[_0x18090('0xcc5')][_0x18090('0x4f0')]?_0xb8742f[_0x18090('0xcc5')][_0x18090('0x4f0')]+_0x18090('0xa17'):''});})[_0x58538b('0x1a80')](function(_0x161004){const _0xddadfa=_0x58538b;_0x352eae[_0xddadfa('0xfc9')]({'title':_0x161004[_0xddadfa('0x52d')]?_0xddadfa('0x1e21')+_0x161004[_0xddadfa('0x52d')]+'\x20-\x20'+_0x161004[_0xddadfa('0xe1b')]:_0xddadfa('0x82c'),'msg':_0x161004[_0xddadfa('0x25f4')]?JSON[_0xddadfa('0xbac')](_0x161004[_0xddadfa('0x25f4')]):_0x161004['toString']()});});}}const _0x19ed16=_0x65a464,_0x38a2b6=_0x2734b2['p']+_0x36e6f4('0x3f2');_0x28bdbc[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1bc6'),'$scope',_0x36e6f4('0x7b9'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x8da'),'$mdDialog','$document',_0x36e6f4('0x1d2e'),'api',_0x36e6f4('0x21ef')];function _0x28bdbc(_0x11659f,_0x12932f,_0x2de9be,_0x27e2be,_0x4c1546,_0x541655,_0x9b7fcf,_0x3f9be3,_0x57a983,_0x44ff15,_0x4f97ef){const _0x3a7ebb=_0x36e6f4,_0x349651=this;_0x349651[_0x3a7ebb('0x98')]=_0x4f97ef['getCurrentUser'](),_0x349651[_0x3a7ebb('0xcc5')]={},_0x349651[_0x3a7ebb('0x28e1')]={'count':0x0,'rows':[]},_0x349651[_0x3a7ebb('0x10cb')]=[],_0x349651[_0x3a7ebb('0x243c')],_0x349651[_0x3a7ebb('0x2218')]={'fields':_0x3a7ebb('0x1b4'),'limit':0xa,'page':0x1},_0x349651[_0x3a7ebb('0x24d5')]=_0x3fbe2c,_0x349651[_0x3a7ebb('0x8a2')]=_0x19751f,_0x349651[_0x3a7ebb('0x103b')]=_0x51b4b8,_0x349651[_0x3a7ebb('0x1fe0')]=_0x554243,_0x349651[_0x3a7ebb('0xb3a')]=_0xef5dad,_0x349651['exportSelectedWhatsappAccountWhatsappCannedAnswers']=_0x59abfc,_0x349651['deleteWhatsappAccountWhatsappCannedAnswer']=_0x3c2ba6,_0x349651['deleteSelectedWhatsappAccountWhatsappCannedAnswers']=_0x5ccc68;function _0x3fbe2c(_0x2cd934,_0x3eec02){const _0x2f08df=_0x3a7ebb;_0x349651['whatsappAccount']=_0x2cd934,_0x349651[_0x2f08df('0x243c')]=typeof _0x3eec02!==_0x2f08df('0x1048')?_0x3eec02:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x349651[_0x2f08df('0x2218')][_0x2f08df('0x1b88')]=_0x349651[_0x2f08df('0xcc5')]['id'],_0x349651[_0x2f08df('0x2218')]['id']=_0x349651[_0x2f08df('0xcc5')]['id'],_0x554243();}function _0x19751f(_0x38389b,_0x13b65d){const _0x5e1bc0=_0x3a7ebb,_0x295390=_0x9b7fcf[_0x5e1bc0('0x1d26')]()[_0x5e1bc0('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20whatsappCannedAnswer?')['htmlContent'](_0x5e1bc0('0x12b5')+(_0x38389b[_0x5e1bc0('0x4f0')]||_0x38389b['id']&&_0x2cfb05()[_0x5e1bc0('0x114b')](_0x5e1bc0('0x1b92'))+_0x38389b['id']||'whatsappCannedAnswer')+_0x5e1bc0('0xace')+_0x5e1bc0('0x3f3'))[_0x5e1bc0('0x8e8')](_0x5e1bc0('0x1997'))[_0x5e1bc0('0x203b')](_0x13b65d)['ok']('OK')[_0x5e1bc0('0x3f')]('CANCEL');_0x9b7fcf[_0x5e1bc0('0x1f80')](_0x295390)['then'](function(){_0x3c2ba6(_0x38389b);},function(){const _0x4c3e4a=_0x5e1bc0;console[_0x4c3e4a('0x455')](_0x4c3e4a('0x2d3'));});}function _0x51b4b8(_0x3e216e){const _0x366c4a=_0x3a7ebb;_0x349651[_0x366c4a('0x28e1')]=_0x3e216e||{'count':0x0,'rows':[]};}function _0x554243(){const _0x1b470d=_0x3a7ebb;_0x349651[_0x1b470d('0x2218')]['offset']=(_0x349651[_0x1b470d('0x2218')][_0x1b470d('0x1a43')]-0x1)*_0x349651[_0x1b470d('0x2218')][_0x1b470d('0x163f')],_0x349651[_0x1b470d('0x1f48')]=_0x44ff15['whatsappAccount']['getAnswers'](_0x349651[_0x1b470d('0x2218')],_0x51b4b8)[_0x1b470d('0xa44')];}function _0xef5dad(_0x1311e1,_0x285e68){const _0x3f8830=_0x3a7ebb;_0x9b7fcf[_0x3f8830('0x1f80')]({'controller':'CreateOrEditWhatsappCannedAnswerDialogController','controllerAs':'vm','templateUrl':_0x38a2b6,'parent':angular[_0x3f8830('0x1194')](_0x3f9be3['body']),'targetEvent':_0x1311e1,'clickOutsideToClose':!![],'locals':{'whatsappAccount':_0x349651[_0x3f8830('0xcc5')],'whatsappCannedAnswer':_0x285e68,'whatsappCannedAnswers':_0x349651[_0x3f8830('0x28e1')][_0x3f8830('0x269a')],'license':null,'setting':null,'crudPermissions':_0x349651['crudPermissions']}});}function _0x3c2ba6(_0x17e9be){const _0xb195bd=_0x3a7ebb;_0x44ff15['cannedAnswer']['delete']({'id':_0x17e9be['id']})[_0xb195bd('0xa44')][_0xb195bd('0x1166')](function(){const _0x4f14c7=_0xb195bd;_0x2cfb05()[_0x4f14c7('0x127f')](_0x349651[_0x4f14c7('0x28e1')]['rows'],{'id':_0x17e9be['id']}),_0x349651[_0x4f14c7('0x28e1')][_0x4f14c7('0x240f')]-=0x1,!_0x349651[_0x4f14c7('0x28e1')][_0x4f14c7('0x269a')]['length']&&_0x554243(),_0x57a983['success']({'title':_0x4f14c7('0x901'),'msg':_0x17e9be[_0x4f14c7('0x4f0')]?_0x17e9be['name']+_0x4f14c7('0x7cd'):''});})[_0xb195bd('0x1a80')](function(_0x420147){const _0x3a2db9=_0xb195bd;if(_0x420147[_0x3a2db9('0x25f4')]&&_0x420147[_0x3a2db9('0x25f4')][_0x3a2db9('0x61a')]&&_0x420147[_0x3a2db9('0x25f4')]['errors']['length']){_0x349651[_0x3a2db9('0x61a')]=_0x420147[_0x3a2db9('0x25f4')]['errors']||[{'message':_0x420147[_0x3a2db9('0x1586')](),'type':_0x3a2db9('0x82c')}];for(let _0x2cc360=0x0;_0x2cc360<_0x420147['data'][_0x3a2db9('0x61a')][_0x3a2db9('0x264b')];_0x2cc360++){_0x57a983[_0x3a2db9('0xfc9')]({'title':_0x420147[_0x3a2db9('0x25f4')][_0x3a2db9('0x61a')][_0x2cc360][_0x3a2db9('0x1345')],'msg':_0x420147['data'][_0x3a2db9('0x61a')][_0x2cc360][_0x3a2db9('0x1e70')]});}}else _0x57a983[_0x3a2db9('0xfc9')]({'title':_0x420147[_0x3a2db9('0x52d')]?'API:'+_0x420147['status']+_0x3a2db9('0x11e1')+_0x420147[_0x3a2db9('0xe1b')]:_0x3a2db9('0x82c'),'msg':_0x420147[_0x3a2db9('0x25f4')]?JSON['stringify'](_0x420147[_0x3a2db9('0x25f4')][_0x3a2db9('0x1e70')]):_0x420147[_0x3a2db9('0x1e70')]||_0x420147['toString']()});});}function _0x59abfc(){const _0x3c62dd=_0x3a7ebb,_0x112d02=angular['copy'](_0x349651[_0x3c62dd('0x10cb')]);return _0x349651[_0x3c62dd('0x10cb')]=[],_0x112d02;}function _0x5ccc68(_0xddc922){const _0x57f5b6=_0x3a7ebb,_0x12dd7c=_0x9b7fcf[_0x57f5b6('0x1d26')]()[_0x57f5b6('0xcdc')](_0x57f5b6('0x42c'))[_0x57f5b6('0xf3c')](_0x57f5b6('0x12b5')+_0x349651[_0x57f5b6('0x10cb')][_0x57f5b6('0x264b')]+_0x57f5b6('0x196d')+_0x57f5b6('0x3f3'))[_0x57f5b6('0x8e8')](_0x57f5b6('0x1f1'))['targetEvent'](_0xddc922)['ok']('OK')[_0x57f5b6('0x3f')](_0x57f5b6('0x2d3'));_0x9b7fcf[_0x57f5b6('0x1f80')](_0x12dd7c)[_0x57f5b6('0x1166')](function(){const _0x542b63=_0x57f5b6;_0x349651[_0x542b63('0x10cb')][_0x542b63('0x2782')](function(_0x7ac2a2){_0x3c2ba6(_0x7ac2a2);}),_0x349651[_0x542b63('0x10cb')]=[];});}let _0x12a4c2=!![],_0x5eb66e=0x1;_0x12932f[_0x3a7ebb('0xe83')]('vm_dc.query.filter',function(_0x1a570d,_0x2c67bf){const _0x37b549=_0x3a7ebb;_0x12a4c2?_0x541655(function(){_0x12a4c2=![];}):(!_0x2c67bf&&(_0x5eb66e=_0x349651[_0x37b549('0x2218')][_0x37b549('0x1a43')]),_0x1a570d!==_0x2c67bf&&(_0x349651[_0x37b549('0x2218')][_0x37b549('0x1a43')]=0x1),!_0x1a570d&&(_0x349651[_0x37b549('0x2218')][_0x37b549('0x1a43')]=_0x5eb66e),_0x554243());});}const _0x503f66=_0x28bdbc;_0x3f84af[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),'$state',_0x36e6f4('0x25e0'),_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x586'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x2787'),_0x36e6f4('0x2349'),'api',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting',_0x36e6f4('0x243c')];function _0x3f84af(_0x8a9c2b,_0x5356b7,_0x40601a,_0x803530,_0x25785b,_0xaad26d,_0x38ca0f,_0x359b0a,_0x173073,_0x163372,_0x214239,_0x4e9edc,_0x346f82,_0x356a45){const _0x3a9c41=_0x36e6f4,_0xc1a638=this;_0xc1a638[_0x3a9c41('0x98')]=_0x214239['getCurrentUser'](),_0xc1a638[_0x3a9c41('0x61a')]=[],_0xc1a638[_0x3a9c41('0xf8a')]=_0x346f82,_0xc1a638['license']=_0x4e9edc,_0xc1a638[_0x3a9c41('0x243c')]=_0x356a45,_0xc1a638['hasModulePermissions']={},_0xc1a638['passwordPattern']=_0xc1a638[_0x3a9c41('0xf8a')]&&_0xc1a638[_0x3a9c41('0xf8a')][_0x3a9c41('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xc1a638[_0x3a9c41('0xcdc')]='WHATSAPP.EDIT_WHATSAPPCANNEDANSWER',_0xc1a638[_0x3a9c41('0x2349')]=angular[_0x3a9c41('0x225f')](_0x173073),_0xc1a638[_0x3a9c41('0x2787')]=_0x359b0a,_0xc1a638[_0x3a9c41('0x20e5')]=![];!_0xc1a638['whatsappCannedAnswer']&&(_0xc1a638['whatsappCannedAnswer']={},_0xc1a638[_0x3a9c41('0xcdc')]=_0x3a9c41('0x15ec'),_0xc1a638[_0x3a9c41('0x20e5')]=!![]);_0x5356b7[_0x3a9c41('0x23f')]['id']&&(_0xc1a638[_0x3a9c41('0x2349')][_0x3a9c41('0x1b88')]=_0x5356b7[_0x3a9c41('0x23f')]['id']);_0xc1a638[_0x3a9c41('0xff8')]=_0x551530,_0xc1a638[_0x3a9c41('0xa15')]=_0x111fb7,_0xc1a638[_0x3a9c41('0xb29')]=_0x4b3e6c,_0xc1a638['getDateFromString']=_0x98a48,_0xc1a638[_0x3a9c41('0x24a0')]=_0x88840d;function _0x551530(){const _0x531227=_0x3a9c41;_0xc1a638[_0x531227('0x61a')]=[],_0x163372[_0x531227('0x1b1f')][_0x531227('0x9cc')](_0xc1a638[_0x531227('0x2349')])[_0x531227('0xa44')]['then'](function(_0x2f8cf8){const _0x38f2aa=_0x531227;_0xc1a638['whatsappCannedAnswers'][_0x38f2aa('0x2450')](_0x2f8cf8[_0x38f2aa('0x2876')]()),_0x38ca0f[_0x38f2aa('0x103b')]({'title':_0x38f2aa('0x7b7'),'msg':_0xc1a638['whatsappCannedAnswer'][_0x38f2aa('0x4f0')]?_0xc1a638[_0x38f2aa('0x2349')]['name']+'\x20has\x20been\x20created!':''}),_0x88840d(_0x2f8cf8);})[_0x531227('0x1a80')](function(_0x4e94ff){const _0x132cdf=_0x531227;if(_0x4e94ff['data']&&_0x4e94ff[_0x132cdf('0x25f4')][_0x132cdf('0x61a')]&&_0x4e94ff[_0x132cdf('0x25f4')][_0x132cdf('0x61a')][_0x132cdf('0x264b')]){_0xc1a638[_0x132cdf('0x61a')]=_0x4e94ff[_0x132cdf('0x25f4')]['errors']||[{'message':_0x4e94ff[_0x132cdf('0x1586')](),'type':_0x132cdf('0xcca')}];for(let _0x22dfce=0x0;_0x22dfce<_0x4e94ff[_0x132cdf('0x25f4')][_0x132cdf('0x61a')][_0x132cdf('0x264b')];_0x22dfce+=0x1){_0x38ca0f[_0x132cdf('0xfc9')]({'title':_0x4e94ff[_0x132cdf('0x25f4')]['errors'][_0x22dfce][_0x132cdf('0x1345')],'msg':_0x4e94ff[_0x132cdf('0x25f4')][_0x132cdf('0x61a')][_0x22dfce][_0x132cdf('0x1e70')]});}}else _0x38ca0f[_0x132cdf('0xfc9')]({'title':_0x4e94ff[_0x132cdf('0x52d')]?_0x132cdf('0x1e21')+_0x4e94ff[_0x132cdf('0x52d')]+'\x20-\x20'+_0x4e94ff[_0x132cdf('0xe1b')]:_0x132cdf('0xcca'),'msg':_0x4e94ff[_0x132cdf('0x25f4')]?JSON[_0x132cdf('0xbac')](_0x4e94ff[_0x132cdf('0x25f4')][_0x132cdf('0x1e70')]):_0x4e94ff[_0x132cdf('0x1586')]()});});}function _0x111fb7(){const _0x1a0eeb=_0x3a9c41;_0xc1a638[_0x1a0eeb('0x61a')]=[],_0x163372[_0x1a0eeb('0x1b1f')][_0x1a0eeb('0x1449')]({'id':_0xc1a638['whatsappCannedAnswer']['id']},_0xc1a638[_0x1a0eeb('0x2349')])[_0x1a0eeb('0xa44')][_0x1a0eeb('0x1166')](function(_0x1b00d5){const _0x42dd1e=_0x1a0eeb,_0x53226f=_0x2cfb05()['find'](_0xc1a638['whatsappCannedAnswers'],{'id':_0x1b00d5['id']});_0x53226f&&_0x2cfb05()[_0x42dd1e('0xcc3')](_0x53226f,_0x2cfb05()[_0x42dd1e('0x1a08')](_0x1b00d5[_0x42dd1e('0x2876')](),_0x2cfb05()['keys'](_0x53226f))),_0x38ca0f[_0x42dd1e('0x103b')]({'title':'WhatsappCannedAnswer\x20properly\x20saved!','msg':_0xc1a638[_0x42dd1e('0x2349')][_0x42dd1e('0x4f0')]?_0xc1a638[_0x42dd1e('0x2349')][_0x42dd1e('0x4f0')]+'\x20has\x20been\x20saved!':''}),_0x88840d(_0x1b00d5);})['catch'](function(_0x36999b){const _0x4cedca=_0x1a0eeb;if(_0x36999b[_0x4cedca('0x25f4')]&&_0x36999b['data'][_0x4cedca('0x61a')]&&_0x36999b['data'][_0x4cedca('0x61a')][_0x4cedca('0x264b')]){_0xc1a638[_0x4cedca('0x61a')]=_0x36999b[_0x4cedca('0x25f4')]['errors']||[{'message':_0x36999b[_0x4cedca('0x1586')](),'type':'api.cannedAnswer.update'}];for(let _0x2d0a67=0x0;_0x2d0a67<_0x36999b[_0x4cedca('0x25f4')]['errors'][_0x4cedca('0x264b')];_0x2d0a67++){_0x38ca0f[_0x4cedca('0xfc9')]({'title':_0x36999b[_0x4cedca('0x25f4')][_0x4cedca('0x61a')][_0x2d0a67][_0x4cedca('0x1345')],'msg':_0x36999b[_0x4cedca('0x25f4')][_0x4cedca('0x61a')][_0x2d0a67]['message']});}}else _0x38ca0f['error']({'title':_0x36999b[_0x4cedca('0x52d')]?'API:'+_0x36999b[_0x4cedca('0x52d')]+_0x4cedca('0x11e1')+_0x36999b['statusText']:_0x4cedca('0x122e'),'msg':_0x36999b[_0x4cedca('0x25f4')]?JSON[_0x4cedca('0xbac')](_0x36999b[_0x4cedca('0x25f4')]['message']):_0x36999b[_0x4cedca('0x1586')]()});});}function _0x4b3e6c(_0x39d7d1){const _0x3be74c=_0x3a9c41;_0xc1a638['errors']=[];const _0x523067=_0x803530[_0x3be74c('0x1d26')]()[_0x3be74c('0xcdc')](_0x3be74c('0x7fb'))['content'](_0x3be74c('0x1706'))[_0x3be74c('0x8e8')](_0x3be74c('0x1fe6'))['ok']('Delete')[_0x3be74c('0x3f')](_0x3be74c('0x497'))[_0x3be74c('0x203b')](_0x39d7d1);_0x803530[_0x3be74c('0x1f80')](_0x523067)[_0x3be74c('0x1166')](function(){const _0x1ca2b5=_0x3be74c;_0x163372['cannedAnswer'][_0x1ca2b5('0x906')]({'id':_0xc1a638[_0x1ca2b5('0x2349')]['id']})[_0x1ca2b5('0xa44')][_0x1ca2b5('0x1166')](function(){const _0x190dc9=_0x1ca2b5;_0x2cfb05()[_0x190dc9('0x127f')](_0xc1a638[_0x190dc9('0x2787')],{'id':_0xc1a638[_0x190dc9('0x2349')]['id']}),_0x38ca0f[_0x190dc9('0x103b')]({'title':_0x190dc9('0xca3'),'msg':(_0xc1a638[_0x190dc9('0x2349')][_0x190dc9('0x4f0')]||_0x190dc9('0x2349'))+_0x190dc9('0x7cd')}),_0x88840d(_0xc1a638[_0x190dc9('0x2349')]);})[_0x1ca2b5('0x1a80')](function(_0xb0fd0f){const _0x492337=_0x1ca2b5;if(_0xb0fd0f[_0x492337('0x25f4')]&&_0xb0fd0f[_0x492337('0x25f4')][_0x492337('0x61a')]&&_0xb0fd0f[_0x492337('0x25f4')]['errors']['length']){_0xc1a638[_0x492337('0x61a')]=_0xb0fd0f[_0x492337('0x25f4')][_0x492337('0x61a')]||[{'message':_0xb0fd0f['toString'](),'type':'api.cannedAnswer.delete'}];for(let _0x4ca5b6=0x0;_0x4ca5b6<_0xb0fd0f[_0x492337('0x25f4')][_0x492337('0x61a')][_0x492337('0x264b')];_0x4ca5b6++){_0x38ca0f['error']({'title':_0xb0fd0f['data'][_0x492337('0x61a')][_0x4ca5b6]['type'],'msg':_0xb0fd0f[_0x492337('0x25f4')][_0x492337('0x61a')][_0x4ca5b6]['message']});}}else _0x38ca0f[_0x492337('0xfc9')]({'title':_0xb0fd0f[_0x492337('0x52d')]?_0x492337('0x1e21')+_0xb0fd0f[_0x492337('0x52d')]+_0x492337('0x11e1')+_0xb0fd0f[_0x492337('0xe1b')]:_0x492337('0x1da9'),'msg':_0xb0fd0f['data']?JSON['stringify'](_0xb0fd0f['data'][_0x492337('0x1e70')]):_0xb0fd0f[_0x492337('0x1e70')]||_0xb0fd0f[_0x492337('0x1586')]()});});},function(){});}function _0x98a48(_0x52a54f){return _0x52a54f===null?undefined:new Date(_0x52a54f);}function _0x88840d(_0x5194e){const _0x5712d2=_0x3a9c41;_0x803530[_0x5712d2('0x1197')](_0x5194e);}}const _0x30b941=_0x3f84af;_0x18de9a['$inject']=[_0x36e6f4('0x36f'),'$window',_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),'$mdDialog',_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef')];function _0x18de9a(_0x46ecd6,_0x507616,_0x4e6b2a,_0x486fbf,_0x10b9a5,_0x2b17c9,_0x441600,_0x75c51b,_0x1a55fe,_0x29c498,_0x1ecf16){const _0x339fa3=_0x36e6f4,_0x694cb6=this;_0x694cb6[_0x339fa3('0x98')]=_0x1ecf16[_0x339fa3('0x26cd')](),_0x694cb6[_0x339fa3('0x4ea')]={'count':0x0,'rows':[]},_0x694cb6[_0x339fa3('0x1082')]=[],_0x694cb6[_0x339fa3('0x243c')],_0x694cb6['levels']={'first':_0x339fa3('0xc31'),'second':_0x339fa3('0x580'),'third':_0x339fa3('0x1144')},_0x694cb6[_0x339fa3('0x2218')]={'fields':'id,level,name,description,ParentId,createdAt,updatedAt','sort':_0x339fa3('0x14dc'),'limit':0xa,'page':0x1},_0x694cb6[_0x339fa3('0x24d5')]=_0x4f31b0,_0x694cb6['deleteConfirm']=_0x2d961d,_0x694cb6['success']=_0x4e691a,_0x694cb6[_0x339fa3('0x3e')]=_0x3c504d,_0x694cb6[_0x339fa3('0x782')]=_0x31b52b,_0x694cb6[_0x339fa3('0x27c6')]=_0x2d964c,_0x694cb6['exportSelectedDispositions']=_0x425ab0,_0x694cb6[_0x339fa3('0x14b5')]=_0xf2026e,_0x694cb6['deselectDispositions']=_0x54fcb5,_0x694cb6[_0x339fa3('0xd7c')]=_0x2246f6;function _0x4f31b0(_0x59cfa5,_0xe3e9ca){const _0x401d9b=_0x339fa3;_0x694cb6[_0x401d9b('0xcc5')]=_0x59cfa5||{},_0x694cb6[_0x401d9b('0x243c')]=typeof _0xe3e9ca!=='undefined'?_0xe3e9ca:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x694cb6['query']['WhatsappAccountId']=_0x694cb6['whatsappAccount']['id'],_0x694cb6[_0x401d9b('0x2218')]['id']=_0x694cb6['whatsappAccount']['id'],_0x3c504d();}function _0x31b52b(_0x12ffa8,_0x58d6d1){const _0x45a0e3=_0x339fa3;_0x10b9a5[_0x45a0e3('0x1f80')]({'controller':_0x45a0e3('0x17a3'),'controllerAs':'vm','templateUrl':_0x14e8d3,'parent':angular['element'](_0x2b17c9[_0x45a0e3('0x8d2')]),'targetEvent':_0x12ffa8,'clickOutsideToClose':!![],'locals':{'disposition':_0x58d6d1,'dispositions':_0x694cb6[_0x45a0e3('0x4ea')][_0x45a0e3('0x269a')],'model':{'id':_0x694cb6['whatsappAccount']['id'],'field':_0x45a0e3('0x1b88')},'license':null,'setting':null,'crudPermissions':_0x694cb6[_0x45a0e3('0x243c')]}})[_0x45a0e3('0x1166')](function(_0x5ce695){if(_0x5ce695)_0x3c504d();});}function _0x2d961d(_0xa84dd9,_0x31fb30){const _0x1089c7=_0x339fa3,_0xaa9604=_0x2cfb05()[_0x1089c7('0x1798')](_0x694cb6[_0x1089c7('0x4ea')]['rows'],[_0x1089c7('0x11fa'),_0xa84dd9['id']]),_0x3c9f87=_0x10b9a5[_0x1089c7('0x1d26')]()[_0x1089c7('0xcdc')](_0x75c51b['instant'](_0x1089c7('0x1ac5')))[_0x1089c7('0xacc')](_0x75c51b[_0x1089c7('0x25cc')]('TOOLS.NOTIFICATIONS.'+(_0xaa9604?_0x1089c7('0xc7a'):'DISPOSITION_DELETE_MESSAGE'),{'name':_0xa84dd9['name']}))[_0x1089c7('0x8e8')]('Delete\x20disposition')[_0x1089c7('0x203b')](_0x31fb30)['ok']('OK')['cancel'](_0x75c51b[_0x1089c7('0x25cc')]('TOOLS.CANCEL'));_0x10b9a5['show'](_0x3c9f87)['then'](function(){_0x2d964c(_0xa84dd9);});}function _0x4e691a(_0x19d091){const _0x5307db=_0x339fa3;_0x694cb6[_0x5307db('0x4ea')]=_0x19d091||{'count':0x0,'rows':[]};}function _0x3c504d(){const _0x19f779=_0x339fa3;_0x694cb6['query'][_0x19f779('0x1098')]=(_0x694cb6[_0x19f779('0x2218')]['page']-0x1)*_0x694cb6[_0x19f779('0x2218')][_0x19f779('0x163f')],_0x694cb6['promise']=_0x1a55fe[_0x19f779('0xcc5')][_0x19f779('0x3e')](_0x694cb6[_0x19f779('0x2218')],_0x4e691a)['$promise'];}function _0x2d964c(_0x468aa4){const _0x3f04f9=_0x339fa3;_0x1a55fe[_0x3f04f9('0x12e8')][_0x3f04f9('0x906')]({'id':_0x468aa4['id']})[_0x3f04f9('0xa44')][_0x3f04f9('0x1166')](function(){const _0x3c0a80=_0x3f04f9;_0x3c504d(),_0x29c498[_0x3c0a80('0x103b')]({'title':_0x75c51b[_0x3c0a80('0x25cc')]('TOOLS.NOTIFICATIONS.DISPOSITION_DELETED_SUCCESS_TITLE')});})['catch'](function(_0x550dc0){const _0x1d931c=_0x3f04f9;if(_0x550dc0[_0x1d931c('0x25f4')]&&_0x550dc0[_0x1d931c('0x25f4')][_0x1d931c('0x61a')]&&_0x550dc0[_0x1d931c('0x25f4')][_0x1d931c('0x61a')][_0x1d931c('0x264b')]){_0x694cb6['errors']=_0x550dc0[_0x1d931c('0x25f4')][_0x1d931c('0x61a')]||[{'message':_0x550dc0['toString'](),'type':'SYSTEM:DELETEdisposition'}];for(let _0x23d463=0x0;_0x23d463<_0x550dc0[_0x1d931c('0x25f4')][_0x1d931c('0x61a')][_0x1d931c('0x264b')];_0x23d463++){_0x29c498[_0x1d931c('0xfc9')]({'title':_0x550dc0[_0x1d931c('0x25f4')]['errors'][_0x23d463]['type'],'msg':_0x550dc0[_0x1d931c('0x25f4')][_0x1d931c('0x61a')][_0x23d463]['message']});}}else _0x29c498[_0x1d931c('0xfc9')]({'title':_0x550dc0[_0x1d931c('0x52d')]?_0x1d931c('0x1e21')+_0x550dc0[_0x1d931c('0x52d')]+'\x20-\x20'+_0x550dc0['statusText']:_0x1d931c('0x1b2c'),'msg':_0x550dc0[_0x1d931c('0x25f4')]?JSON[_0x1d931c('0xbac')](_0x550dc0[_0x1d931c('0x25f4')][_0x1d931c('0x1e70')]):_0x550dc0['message']||_0x550dc0[_0x1d931c('0x1586')]()});});}function _0x425ab0(){const _0x2adeab=_0x339fa3,_0x4dc609=angular[_0x2adeab('0x225f')](_0x694cb6[_0x2adeab('0x1082')]);return _0x694cb6[_0x2adeab('0x1082')]=[],_0x4dc609;}function _0xf2026e(_0x56d535){const _0x455c26=_0x339fa3,_0x4aa7e9=_0x10b9a5[_0x455c26('0x1d26')]()[_0x455c26('0xcdc')](_0x75c51b[_0x455c26('0x25cc')](_0x455c26('0x24fd')))[_0x455c26('0xacc')](_0x75c51b[_0x455c26('0x25cc')]('TOOLS.NOTIFICATIONS.DISPOSITIONS_DELETE_MESSAGE',{'total':_0x694cb6[_0x455c26('0x1082')][_0x455c26('0x264b')]}))['ariaLabel'](_0x455c26('0x19b'))['targetEvent'](_0x56d535)['ok']('OK')[_0x455c26('0x3f')](_0x75c51b[_0x455c26('0x25cc')]('TOOLS.CANCEL'));_0x10b9a5[_0x455c26('0x1f80')](_0x4aa7e9)[_0x455c26('0x1166')](function(){const _0x18aff8=_0x455c26;_0x694cb6[_0x18aff8('0x1082')][_0x18aff8('0x2782')](function(_0x4ebc14){_0x2d964c(_0x4ebc14);}),_0x694cb6[_0x18aff8('0x1082')]=[];});}function _0x54fcb5(){const _0x3dba2a=_0x339fa3;_0x694cb6[_0x3dba2a('0x1082')]=[];}function _0x2246f6(){const _0x299e63=_0x339fa3;_0x694cb6[_0x299e63('0x1082')]=_0x694cb6['dispositions'][_0x299e63('0x269a')];}let _0x5cba9b=!![],_0x3a6979=0x1;_0x46ecd6['$watch']('vm_dc.query.filter',function(_0x37c26e,_0x2130cc){const _0x35ce0f=_0x339fa3;_0x5cba9b?_0x441600(function(){_0x5cba9b=![];}):(!_0x2130cc&&(_0x3a6979=_0x694cb6[_0x35ce0f('0x2218')][_0x35ce0f('0x1a43')]),_0x37c26e!==_0x2130cc&&(_0x694cb6[_0x35ce0f('0x2218')][_0x35ce0f('0x1a43')]=0x1),!_0x37c26e&&(_0x694cb6[_0x35ce0f('0x2218')][_0x35ce0f('0x1a43')]=_0x3a6979),_0x3c504d());});}const _0xe7f703=_0x18de9a,_0xf498e4=_0x2734b2['p']+_0x36e6f4('0x2264');_0x58b0b6[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1566'),'$state','$mdSidenav','$mdDialog','$document',_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'whatsappAccounts',_0x36e6f4('0x7f'),_0x36e6f4('0x17aa'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),'toasty',_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),'setting'];function _0x58b0b6(_0x59c177,_0x40920a,_0x152669,_0x2d9e39,_0x1432ad,_0x525f7b,_0x1919a3,_0x2db200,_0x12997a,_0x558d6a,_0x75e903,_0x37df35,_0x42dc7a,_0x5e4f90,_0xe621c1,_0x1f5e72,_0x1d154c){const _0x10921c=_0x36e6f4,_0x348dac=this;_0x348dac[_0x10921c('0x5c9')]=_0x1f5e72,_0x348dac[_0x10921c('0xf8a')]=_0x1d154c,_0x348dac[_0x10921c('0x98')]=_0xe621c1[_0x10921c('0x26cd')](),_0x348dac['whatsappAccounts']=_0x12997a||{'count':0x0,'rows':[]},_0x348dac[_0x10921c('0x7f')]=_0x558d6a,_0x348dac['userProfileSection']=_0x75e903&&_0x75e903[_0x10921c('0x240f')]==0x1?_0x75e903[_0x10921c('0x269a')][0x0]:null,_0x348dac['crudPermissions']=_0xe621c1['parseCrudPermissions'](_0x348dac[_0x10921c('0x17aa')]?_0x348dac['userProfileSection'][_0x10921c('0x243c')]:null),_0x348dac[_0x10921c('0x916')]=_0x10921c('0x1974'),_0x348dac[_0x10921c('0xef5')]='',_0x348dac['listOrderAsc']=null,_0x348dac[_0x10921c('0x1c98')]=[],_0x348dac[_0x10921c('0x2218')]={'fields':_0x10921c('0x495'),'sort':_0x10921c('0x14dc'),'limit':0xa,'page':0x1},_0x348dac['arraytype']=_0x2cfb05()[_0x10921c('0x155c')]([{'option':_0x10921c('0x2464'),'value':_0x10921c('0x114c')}],function(_0x4f5e11){return _0x2cfb05()['replace'](_0x4f5e11['value'],new RegExp('\x27','g'),'');}),_0x348dac[_0x10921c('0x1ff6')]=_0x389d60,_0x348dac[_0x10921c('0x5e9')]=_0x5831e2,_0x348dac[_0x10921c('0x1728')]=_0x58b22d,_0x348dac[_0x10921c('0x8d8')]=_0x558cd7,_0x348dac['success']=_0x462dd7,_0x348dac[_0x10921c('0x22a4')]=_0x312413,_0x348dac[_0x10921c('0x389')]=_0x1957d8,_0x348dac[_0x10921c('0x16f7')]=_0x2473b2,_0x348dac[_0x10921c('0xe3c')]=_0x236845,_0x348dac[_0x10921c('0x198c')]=_0x5dd73f,_0x348dac['deselectWhatsappAccounts']=_0x36a0f9,_0x348dac[_0x10921c('0x25d4')]=_0x4623b1,_0xe621c1[_0x10921c('0x1ac6')](_0x10921c('0xa7c'))?_0x37df35['cmList'][_0x10921c('0xd83')]({'fields':'id,name','sort':'name'})[_0x10921c('0xa44')]['then'](function(_0x5683bb){const _0xf175db=_0x10921c;_0x348dac['lists']=_0x5683bb[_0xf175db('0x269a')]||[];})[_0x10921c('0x1a80')](function(_0x30b0e2){const _0x1e95e1=_0x10921c;_0x5e4f90['error']({'title':_0x30b0e2[_0x1e95e1('0x52d')]?_0x1e95e1('0x1e21')+_0x30b0e2[_0x1e95e1('0x52d')]+_0x1e95e1('0x11e1')+_0x30b0e2[_0x1e95e1('0xe1b')]:_0x1e95e1('0x520'),'msg':_0x30b0e2['data']?JSON[_0x1e95e1('0xbac')](_0x30b0e2[_0x1e95e1('0x25f4')]):_0x30b0e2[_0x1e95e1('0x1586')]()});}):_0x37df35[_0x10921c('0xdd9')][_0x10921c('0xd83')]({'fields':_0x10921c('0x1776'),'sort':_0x10921c('0x4f0')})['$promise']['then'](function(_0x9a362e){const _0x5900f9=_0x10921c;_0x348dac[_0x5900f9('0x8de')]=_0x9a362e[_0x5900f9('0x269a')]||[];})[_0x10921c('0x1166')](function(){const _0x1d0c1d=_0x10921c;return _0x37df35['userProfileSection'][_0x1d0c1d('0xd83')]({'userProfileId':_0x348dac['currentUser'][_0x1d0c1d('0xb86')],'sectionId':0x12d})[_0x1d0c1d('0xa44')];})[_0x10921c('0x1166')](function(_0x360cc3){const _0x42a340=_0x10921c,_0x1d325a=_0x360cc3&&_0x360cc3['rows']?_0x360cc3['rows'][0x0]:null;if(!_0x1d325a){const _0x1bfe4b=[];let _0x168f29=null;_0x348dac['whatsappAccount']&&(_0x168f29=_0x2cfb05()[_0x42a340('0xc38')](_0x348dac[_0x42a340('0x8de')],{'id':Number(_0x348dac[_0x42a340('0xcc5')][_0x42a340('0x23c')])}));for(let _0xf2b083=0x0;_0xf2b083<_0x348dac[_0x42a340('0x8de')][_0x42a340('0x264b')];_0xf2b083++){_0x168f29&&_0x348dac[_0x42a340('0x8de')][_0xf2b083]['id']===_0x168f29['id']&&(_0x348dac[_0x42a340('0x8de')][_0xf2b083][_0x42a340('0x2378')]=![],_0x1bfe4b[_0x42a340('0x1514')](_0x348dac['lists'][_0xf2b083]));}_0x348dac[_0x42a340('0x8de')]=_0x1bfe4b;}else{if(!_0x1d325a[_0x42a340('0x1a2b')])return _0x37df35[_0x42a340('0x4b5')][_0x42a340('0xd83')]({'sectionId':_0x1d325a['id']})[_0x42a340('0xa44')]['then'](function(_0x48c307){const _0xa44ad1=_0x42a340,_0x48326f=_0x2cfb05()[_0xa44ad1('0x2563')](_0x48c307[_0xa44ad1('0x269a')],function(_0x27aef8){const _0x2395cd=_0xa44ad1;return _0x2cfb05()[_0x2395cd('0xc38')](_0x348dac[_0x2395cd('0x8de')],{'id':_0x27aef8[_0x2395cd('0x24e8')]});});let _0x3a7912=null;_0x348dac[_0xa44ad1('0xcc5')]&&(_0x3a7912=_0x2cfb05()['find'](_0x348dac[_0xa44ad1('0x8de')],{'id':Number(_0x348dac[_0xa44ad1('0xcc5')][_0xa44ad1('0x23c')])}));if(_0x3a7912&&!_0x2cfb05()[_0xa44ad1('0x1798')](_0x48326f,['id',_0x3a7912['id']])){const _0x1020e3=_0x2cfb05()['find'](_0x348dac[_0xa44ad1('0x8de')],{'id':_0x3a7912['id']});_0x1020e3[_0xa44ad1('0x2378')]=![],_0x48326f[_0xa44ad1('0x1514')](_0x1020e3);}_0x348dac['lists']=_0x48326f;});}})[_0x10921c('0x1a80')](function(_0x2b10fa){const _0xdacdec=_0x10921c;_0x5e4f90['error']({'title':_0x2b10fa[_0xdacdec('0x52d')]?_0xdacdec('0x1e21')+_0x2b10fa[_0xdacdec('0x52d')]+_0xdacdec('0x11e1')+_0x2b10fa['statusText']:_0xdacdec('0x1248'),'msg':_0x2b10fa[_0xdacdec('0x25f4')]?JSON[_0xdacdec('0xbac')](_0x2b10fa[_0xdacdec('0x25f4')]):_0x2b10fa[_0xdacdec('0x1586')]()});}),_0xe621c1[_0x10921c('0x1ac6')](_0x10921c('0xa7c'))?_0x37df35['pause'][_0x10921c('0xd83')]({'fields':'name,id','sort':_0x10921c('0x4f0'),'nolimit':_0x10921c('0xf3b')})[_0x10921c('0xa44')]['then'](function(_0x3f9661){const _0x3f9729=_0x10921c;_0x348dac[_0x3f9729('0xe29')]=_0x3f9661[_0x3f9729('0x269a')]||[];})[_0x10921c('0x1a80')](function(_0x449a6d){const _0x2af4ed=_0x10921c;_0x5e4f90['error']({'title':_0x449a6d[_0x2af4ed('0x52d')]?_0x2af4ed('0x1e21')+_0x449a6d[_0x2af4ed('0x52d')]+_0x2af4ed('0x11e1')+_0x449a6d[_0x2af4ed('0xe1b')]:_0x2af4ed('0x18ed'),'msg':_0x449a6d[_0x2af4ed('0x25f4')]?JSON[_0x2af4ed('0xbac')](_0x449a6d[_0x2af4ed('0x25f4')]):_0x449a6d['toString']()});}):_0x37df35[_0x10921c('0x1e77')][_0x10921c('0xd83')]({'fields':_0x10921c('0xcb8'),'sort':'name','nolimit':_0x10921c('0xf3b')})['$promise']['then'](function(_0x3cfe86){const _0x576fdc=_0x10921c;_0x348dac[_0x576fdc('0xe29')]=_0x3cfe86[_0x576fdc('0x269a')]||[];})[_0x10921c('0x1166')](function(){const _0x4db049=_0x10921c;return _0x37df35[_0x4db049('0x17aa')]['get']({'userProfileId':_0x348dac[_0x4db049('0x98')][_0x4db049('0xb86')],'sectionId':0x3ed})[_0x4db049('0xa44')];})[_0x10921c('0x1166')](function(_0x385a45){const _0x20128e=_0x10921c,_0x31b9b3=_0x385a45&&_0x385a45[_0x20128e('0x269a')]?_0x385a45[_0x20128e('0x269a')][0x0]:null;if(!_0x31b9b3)_0x348dac['pauses']=[];else{if(!_0x31b9b3[_0x20128e('0x1a2b')])return _0x37df35['userProfileResource'][_0x20128e('0xd83')]({'sectionId':_0x31b9b3['id']})['$promise'][_0x20128e('0x1166')](function(_0x387db8){const _0x124fd7=_0x20128e,_0xe93d6e=_0x2cfb05()[_0x124fd7('0x2563')](_0x387db8[_0x124fd7('0x269a')],function(_0x4f85a){const _0xa56f23=_0x124fd7;return _0x2cfb05()['find'](_0x348dac['pauses'],{'id':_0x4f85a[_0xa56f23('0x24e8')]});});_0x348dac[_0x124fd7('0xe29')][_0x124fd7('0x2782')](function(_0x3ba1d8){const _0x318aab=_0x124fd7;!_0x2cfb05()[_0x318aab('0x1798')](_0xe93d6e,['id',_0x3ba1d8['id']])&&(_0x3ba1d8['canSelect']=![]),_0xe93d6e['push'](_0x3ba1d8);}),_0x348dac['pauses']=_0xe93d6e;});}})[_0x10921c('0x1a80')](function(_0x27967a){const _0x458044=_0x10921c;_0x5e4f90[_0x458044('0xfc9')]({'title':_0x27967a[_0x458044('0x52d')]?'API:'+_0x27967a[_0x458044('0x52d')]+_0x458044('0x11e1')+_0x27967a[_0x458044('0xe1b')]:_0x458044('0x1488'),'msg':_0x27967a[_0x458044('0x25f4')]?JSON['stringify'](_0x27967a[_0x458044('0x25f4')]):_0x27967a[_0x458044('0x1586')]()});});function _0x389d60(_0x39ffaf){const _0x88cd51=_0x10921c;_0x152669['go'](_0x88cd51('0x7e8'),{'id':_0x39ffaf['id'],'whatsappAccount':_0x39ffaf,'crudPermissions':_0x348dac[_0x88cd51('0x243c')]});}function _0x5831e2(_0x319d30){_0x152669['go']('app.whatsapp.whatsappAccounts.edit',{'id':_0x319d30['id'],'tab':0x5});}function _0x58b22d(_0x4e1589,_0x2878ed){const _0x19f7b4=_0x10921c;_0x1432ad['show']({'controller':'WhatsappAccountagentaddController','controllerAs':'vm','templateUrl':_0x18545e,'parent':angular[_0x19f7b4('0x1194')](_0x525f7b[_0x19f7b4('0x8d2')]),'targetEvent':_0x2878ed,'clickOutsideToClose':!![],'locals':{'whatsappAccount':_0x4e1589,'whatsappAccounts':_0x348dac[_0x19f7b4('0x1974')]?_0x348dac[_0x19f7b4('0x1974')][_0x19f7b4('0x269a')]:[],'crudPermissions':_0x348dac[_0x19f7b4('0x243c')],'realtime':![]}});}function _0x558cd7(_0x4e6461,_0x2885d1){const _0x22a000=_0x10921c,_0x5b11e0=_0x1432ad['confirm']()[_0x22a000('0xcdc')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2cfb05()['startCase'](_0x22a000('0xcc5'))+'?')[_0x22a000('0xf3c')](_0x22a000('0x12b5')+(_0x4e6461[_0x22a000('0x4f0')]||_0x22a000('0xcc5'))+_0x22a000('0xace')+_0x22a000('0x3f3'))[_0x22a000('0x8e8')]('delete\x20whatsappAccount')[_0x22a000('0x203b')](_0x2885d1)['ok']('OK')[_0x22a000('0x3f')](_0x22a000('0x2d3'));_0x1432ad[_0x22a000('0x1f80')](_0x5b11e0)[_0x22a000('0x1166')](function(){_0x2473b2(_0x4e6461);},function(){const _0x448820=_0x22a000;console[_0x448820('0x455')](_0x448820('0x2d3'));});}let _0x47f2fd=!![],_0xfd83f3=0x1;_0x59c177[_0x10921c('0xe83')](_0x10921c('0x12d8'),function(_0x499655,_0x31c4c2){const _0x28fb6a=_0x10921c;_0x47f2fd?_0x1919a3(function(){_0x47f2fd=![];}):(!_0x31c4c2&&(_0xfd83f3=_0x348dac['query'][_0x28fb6a('0x1a43')]),_0x499655!==_0x31c4c2&&(_0x348dac['query'][_0x28fb6a('0x1a43')]=0x1),!_0x499655&&(_0x348dac[_0x28fb6a('0x2218')][_0x28fb6a('0x1a43')]=_0xfd83f3),_0x348dac[_0x28fb6a('0x22a4')]());});function _0x462dd7(_0x54e43d){_0x348dac['whatsappAccounts']=_0x54e43d||{'count':0x0,'rows':[]};}function _0x312413(){const _0x134bdb=_0x10921c;_0x348dac[_0x134bdb('0x2218')][_0x134bdb('0x1098')]=(_0x348dac[_0x134bdb('0x2218')][_0x134bdb('0x1a43')]-0x1)*_0x348dac[_0x134bdb('0x2218')][_0x134bdb('0x163f')],_0xe621c1['hasRole'](_0x134bdb('0xa7c'))?_0x348dac[_0x134bdb('0x1f48')]=_0x37df35[_0x134bdb('0xcc5')]['get'](_0x348dac['query'],_0x462dd7)[_0x134bdb('0xa44')]:(_0x348dac[_0x134bdb('0x2218')]['id']=_0x348dac['userProfile']['id'],_0x348dac[_0x134bdb('0x2218')]['section']=_0x134bdb('0x171a'),_0x348dac[_0x134bdb('0x1f48')]=_0x37df35['userProfile']['getResources'](_0x348dac['query'],_0x462dd7)[_0x134bdb('0xa44')]);}function _0x1957d8(_0x1c2b8c,_0xbd3950){const _0x2b2a00=_0x10921c;_0x1432ad[_0x2b2a00('0x1f80')]({'controller':_0x2b2a00('0x1305'),'controllerAs':'vm','templateUrl':_0xf498e4,'parent':angular[_0x2b2a00('0x1194')](_0x525f7b[_0x2b2a00('0x8d2')]),'targetEvent':_0x1c2b8c,'clickOutsideToClose':!![],'locals':{'whatsappAccount':_0xbd3950,'whatsappAccounts':_0x348dac[_0x2b2a00('0x1974')]['rows'],'license':_0x348dac[_0x2b2a00('0x5c9')],'setting':_0x348dac[_0x2b2a00('0xf8a')],'crudPermissions':_0x348dac['crudPermissions']}});}function _0x2473b2(_0x180bff){const _0x2e34a4=_0x10921c;_0x37df35[_0x2e34a4('0xcc5')]['delete']({'id':_0x180bff['id']})[_0x2e34a4('0xa44')][_0x2e34a4('0x1166')](function(){const _0x117dea=_0x2e34a4;_0x2cfb05()[_0x117dea('0x127f')](_0x348dac['whatsappAccounts']['rows'],{'id':_0x180bff['id']}),_0x348dac[_0x117dea('0x1974')][_0x117dea('0x240f')]-=0x1,!_0x348dac['whatsappAccounts']['rows'][_0x117dea('0x264b')]&&_0x348dac[_0x117dea('0x22a4')](),_0x5e4f90['success']({'title':_0x2cfb05()['startCase']('WhatsappAccount')+_0x117dea('0x2b6'),'msg':_0x180bff[_0x117dea('0x4f0')]?_0x180bff['name']+_0x117dea('0x7cd'):''});})[_0x2e34a4('0x1a80')](function(_0x40c90e){const _0x8a32b0=_0x2e34a4;if(_0x40c90e[_0x8a32b0('0x25f4')]&&_0x40c90e[_0x8a32b0('0x25f4')][_0x8a32b0('0x61a')]&&_0x40c90e[_0x8a32b0('0x25f4')][_0x8a32b0('0x61a')][_0x8a32b0('0x264b')]){_0x348dac[_0x8a32b0('0x61a')]=_0x40c90e['data'][_0x8a32b0('0x61a')]||[{'message':_0x40c90e['toString'](),'type':_0x8a32b0('0x93e')}];for(let _0x59061c=0x0;_0x59061c<_0x40c90e['data']['errors'][_0x8a32b0('0x264b')];_0x59061c++){_0x5e4f90['error']({'title':_0x40c90e[_0x8a32b0('0x25f4')][_0x8a32b0('0x61a')][_0x59061c][_0x8a32b0('0x1345')],'msg':_0x40c90e['data']['errors'][_0x59061c]['message']});}}else _0x5e4f90[_0x8a32b0('0xfc9')]({'title':_0x40c90e['status']?'API:'+_0x40c90e[_0x8a32b0('0x52d')]+_0x8a32b0('0x11e1')+_0x40c90e[_0x8a32b0('0xe1b')]:_0x8a32b0('0x93e'),'msg':_0x40c90e['data']?JSON[_0x8a32b0('0xbac')](_0x40c90e[_0x8a32b0('0x25f4')][_0x8a32b0('0x1e70')]):_0x40c90e[_0x8a32b0('0x1e70')]||_0x40c90e[_0x8a32b0('0x1586')]()});});}function _0x236845(){const _0xea0cbf=_0x10921c,_0x17cfdb=angular['copy'](_0x348dac['selectedWhatsappAccounts']);return _0x348dac[_0xea0cbf('0x1c98')]=[],_0x17cfdb;}function _0x5dd73f(_0x5b794c){const _0x4fdcca=_0x10921c,_0x585763=_0x1432ad[_0x4fdcca('0x1d26')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20whatsappAccounts?')[_0x4fdcca('0xf3c')](''+_0x348dac[_0x4fdcca('0x1c98')][_0x4fdcca('0x264b')]+_0x4fdcca('0x196d')+_0x4fdcca('0x3f3'))['ariaLabel']('delete\x20WhatsappAccounts')[_0x4fdcca('0x203b')](_0x5b794c)['ok']('OK')[_0x4fdcca('0x3f')](_0x4fdcca('0x2d3'));_0x1432ad[_0x4fdcca('0x1f80')](_0x585763)[_0x4fdcca('0x1166')](function(){const _0x41080a=_0x4fdcca;_0x348dac[_0x41080a('0x1c98')]['forEach'](function(_0x56c383){_0x2473b2(_0x56c383);}),_0x348dac['selectedWhatsappAccounts']=[];});}function _0x36a0f9(){const _0x547ddd=_0x10921c;_0x348dac[_0x547ddd('0x1c98')]=[];}function _0x4623b1(){const _0x9b6ebb=_0x10921c;_0x348dac[_0x9b6ebb('0x1c98')]=_0x348dac[_0x9b6ebb('0x1974')]['rows'];}}const _0x53f522=_0x58b0b6;_0x5acb37[_0x36e6f4('0x1294')]=['$scope',_0x36e6f4('0x7b9'),_0x36e6f4('0x25e0'),'$mdDialog','$q',_0x36e6f4('0x586'),'toasty',_0x36e6f4('0x147f'),'whatsappQueue',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a'),_0x36e6f4('0x243c')];function _0x5acb37(_0x2e55f,_0x218029,_0x441136,_0x42e93a,_0xfa3ed2,_0x207594,_0x4f5426,_0x79a790,_0x23bf9a,_0x5b1e51,_0x9e4896,_0x459fe2,_0x8fd136,_0x1d1492){const _0x3fff43=_0x36e6f4,_0xf68195=this;_0xf68195[_0x3fff43('0x98')]=_0x9e4896[_0x3fff43('0x26cd')](),_0xf68195[_0x3fff43('0x61a')]=[],_0xf68195[_0x3fff43('0xf8a')]=_0x8fd136,_0xf68195['license']=_0x459fe2,_0xf68195[_0x3fff43('0x243c')]=_0x1d1492,_0xf68195[_0x3fff43('0x128b')]={},_0xf68195[_0x3fff43('0x2900')]=_0xf68195[_0x3fff43('0xf8a')]&&_0xf68195[_0x3fff43('0xf8a')][_0x3fff43('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xf68195[_0x3fff43('0xcdc')]='WHATSAPP.EDIT_WHATSAPPQUEUE',_0xf68195[_0x3fff43('0x1bb6')]=angular[_0x3fff43('0x225f')](_0x23bf9a),_0xf68195['whatsappQueues']=_0x79a790,_0xf68195[_0x3fff43('0x279')]=![];!_0xf68195['whatsappQueue']&&(_0xf68195[_0x3fff43('0x1bb6')]={'strategy':_0x3fff43('0x278c'),'timeout':0xa},_0xf68195[_0x3fff43('0xcdc')]='WHATSAPP.NEW_WHATSAPPQUEUE',_0xf68195[_0x3fff43('0x279')]=!![]);_0xf68195['addNewWhatsappQueue']=_0x4f26a5,_0xf68195[_0x3fff43('0x1b1b')]=_0x3403b6,_0xf68195['deleteWhatsappQueue']=_0x51a663,_0xf68195[_0x3fff43('0x1a9c')]=_0x3849b4,_0xf68195[_0x3fff43('0x24a0')]=_0x292c56;function _0x4f26a5(){const _0x3dbf95=_0x3fff43;_0xf68195[_0x3dbf95('0x61a')]=[],_0x5b1e51['whatsappQueue'][_0x3dbf95('0x9cc')](_0xf68195[_0x3dbf95('0x1bb6')])['$promise'][_0x3dbf95('0x1166')](function(_0x5f1802){const _0x57270e=_0x3dbf95;_0xf68195[_0x57270e('0x147f')]['unshift'](_0x5f1802[_0x57270e('0x2876')]()),_0x4f5426[_0x57270e('0x103b')]({'title':_0x57270e('0x1c12'),'msg':_0xf68195['whatsappQueue']['name']?_0xf68195[_0x57270e('0x1bb6')][_0x57270e('0x4f0')]+_0x57270e('0x1eda'):''}),_0x292c56(_0x5f1802);})['catch'](function(_0x188457){const _0x30deaf=_0x3dbf95;if(_0x188457[_0x30deaf('0x25f4')]&&_0x188457[_0x30deaf('0x25f4')][_0x30deaf('0x61a')]&&_0x188457[_0x30deaf('0x25f4')][_0x30deaf('0x61a')]['length']){_0xf68195[_0x30deaf('0x61a')]=_0x188457['data'][_0x30deaf('0x61a')]||[{'message':_0x188457['toString'](),'type':'api.whatsappQueue.save'}];for(let _0x1128a1=0x0;_0x1128a1<_0x188457[_0x30deaf('0x25f4')][_0x30deaf('0x61a')][_0x30deaf('0x264b')];_0x1128a1+=0x1){_0x4f5426['error']({'title':_0x188457[_0x30deaf('0x25f4')][_0x30deaf('0x61a')][_0x1128a1][_0x30deaf('0x1345')],'msg':_0x188457['data']['errors'][_0x1128a1]['message']});}}else _0x4f5426[_0x30deaf('0xfc9')]({'title':_0x188457[_0x30deaf('0x52d')]?_0x30deaf('0x1e21')+_0x188457['status']+_0x30deaf('0x11e1')+_0x188457[_0x30deaf('0xe1b')]:_0x30deaf('0x17e6'),'msg':_0x188457[_0x30deaf('0x25f4')]?JSON[_0x30deaf('0xbac')](_0x188457[_0x30deaf('0x25f4')][_0x30deaf('0x1e70')]):_0x188457[_0x30deaf('0x1586')]()});});}function _0x3403b6(){const _0x287e4f=_0x3fff43;_0xf68195['errors']=[],_0x5b1e51['whatsappQueue']['update']({'id':_0xf68195[_0x287e4f('0x1bb6')]['id']},_0xf68195['whatsappQueue'])[_0x287e4f('0xa44')][_0x287e4f('0x1166')](function(_0x205951){const _0x2afd85=_0x287e4f,_0x5636b2=_0x2cfb05()[_0x2afd85('0xc38')](_0xf68195[_0x2afd85('0x147f')],{'id':_0x205951['id']});_0x5636b2&&_0x2cfb05()[_0x2afd85('0xcc3')](_0x5636b2,_0x2cfb05()[_0x2afd85('0x1a08')](_0x205951['toJSON'](),_0x2cfb05()[_0x2afd85('0x14a4')](_0x5636b2))),_0x4f5426['success']({'title':_0x2afd85('0x3a2'),'msg':_0xf68195[_0x2afd85('0x1bb6')][_0x2afd85('0x4f0')]?_0xf68195[_0x2afd85('0x1bb6')][_0x2afd85('0x4f0')]+_0x2afd85('0x7d'):''}),_0x292c56(_0x205951);})[_0x287e4f('0x1a80')](function(_0x49efe1){const _0x5a7387=_0x287e4f;if(_0x49efe1[_0x5a7387('0x25f4')]&&_0x49efe1[_0x5a7387('0x25f4')][_0x5a7387('0x61a')]&&_0x49efe1[_0x5a7387('0x25f4')][_0x5a7387('0x61a')][_0x5a7387('0x264b')]){_0xf68195[_0x5a7387('0x61a')]=_0x49efe1[_0x5a7387('0x25f4')][_0x5a7387('0x61a')]||[{'message':_0x49efe1[_0x5a7387('0x1586')](),'type':_0x5a7387('0x15da')}];for(let _0x55c567=0x0;_0x55c567<_0x49efe1[_0x5a7387('0x25f4')][_0x5a7387('0x61a')]['length'];_0x55c567++){_0x4f5426[_0x5a7387('0xfc9')]({'title':_0x49efe1['data'][_0x5a7387('0x61a')][_0x55c567][_0x5a7387('0x1345')],'msg':_0x49efe1[_0x5a7387('0x25f4')][_0x5a7387('0x61a')][_0x55c567]['message']});}}else _0x4f5426['error']({'title':_0x49efe1['status']?_0x5a7387('0x1e21')+_0x49efe1[_0x5a7387('0x52d')]+_0x5a7387('0x11e1')+_0x49efe1[_0x5a7387('0xe1b')]:_0x5a7387('0x15da'),'msg':_0x49efe1[_0x5a7387('0x25f4')]?JSON[_0x5a7387('0xbac')](_0x49efe1['data']['message']):_0x49efe1[_0x5a7387('0x1586')]()});});}function _0x51a663(_0x187199){const _0x32f068=_0x3fff43;_0xf68195[_0x32f068('0x61a')]=[];const _0x584451=_0x42e93a[_0x32f068('0x1d26')]()[_0x32f068('0xcdc')](_0x32f068('0x7fb'))[_0x32f068('0xacc')](_0x32f068('0x1719'))[_0x32f068('0x8e8')]('Delete\x20WhatsappQueue')['ok'](_0x32f068('0x18'))[_0x32f068('0x3f')]('Cancel')['targetEvent'](_0x187199);_0x42e93a['show'](_0x584451)[_0x32f068('0x1166')](function(){const _0x8c5972=_0x32f068;_0x5b1e51['whatsappQueue']['delete']({'id':_0xf68195[_0x8c5972('0x1bb6')]['id']})[_0x8c5972('0xa44')][_0x8c5972('0x1166')](function(){const _0x201bee=_0x8c5972;_0x2cfb05()['remove'](_0xf68195[_0x201bee('0x147f')],{'id':_0xf68195[_0x201bee('0x1bb6')]['id']}),_0x4f5426[_0x201bee('0x103b')]({'title':'WhatsappQueue\x20properly\x20deleted!','msg':(_0xf68195[_0x201bee('0x1bb6')][_0x201bee('0x4f0')]||_0x201bee('0x1bb6'))+'\x20has\x20been\x20deleted!'}),_0x292c56(_0xf68195['whatsappQueue']);})[_0x8c5972('0x1a80')](function(_0x2a7a99){const _0x55ea9f=_0x8c5972;if(_0x2a7a99['data']&&_0x2a7a99[_0x55ea9f('0x25f4')][_0x55ea9f('0x61a')]&&_0x2a7a99[_0x55ea9f('0x25f4')][_0x55ea9f('0x61a')]['length']){_0xf68195[_0x55ea9f('0x61a')]=_0x2a7a99[_0x55ea9f('0x25f4')][_0x55ea9f('0x61a')]||[{'message':_0x2a7a99[_0x55ea9f('0x1586')](),'type':_0x55ea9f('0x5be')}];for(let _0x3c497b=0x0;_0x3c497b<_0x2a7a99['data'][_0x55ea9f('0x61a')][_0x55ea9f('0x264b')];_0x3c497b++){_0x4f5426[_0x55ea9f('0xfc9')]({'title':_0x2a7a99[_0x55ea9f('0x25f4')][_0x55ea9f('0x61a')][_0x3c497b][_0x55ea9f('0x1345')],'msg':_0x2a7a99[_0x55ea9f('0x25f4')][_0x55ea9f('0x61a')][_0x3c497b]['message']});}}else _0x4f5426[_0x55ea9f('0xfc9')]({'title':_0x2a7a99[_0x55ea9f('0x52d')]?_0x55ea9f('0x1e21')+_0x2a7a99['status']+'\x20-\x20'+_0x2a7a99['statusText']:_0x55ea9f('0x5be'),'msg':_0x2a7a99[_0x55ea9f('0x25f4')]?JSON[_0x55ea9f('0xbac')](_0x2a7a99['data'][_0x55ea9f('0x1e70')]):_0x2a7a99[_0x55ea9f('0x1e70')]||_0x2a7a99[_0x55ea9f('0x1586')]()});});},function(){});}function _0x3849b4(_0x5eabf5){return _0x5eabf5===null?undefined:new Date(_0x5eabf5);}function _0x292c56(_0x6f2596){_0x42e93a['hide'](_0x6f2596);}}const _0x54b6dc=_0x5acb37;_0x3ff80d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1bb6'),_0x36e6f4('0x147f'),_0x36e6f4('0xf01'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x3ff80d(_0x4f25ac,_0x225fdf,_0x171a5c,_0x4113dc,_0xdddae7,_0x485331,_0x56d050,_0x567716,_0x57ab7e,_0x26337d){const _0x3b4d1c=_0x36e6f4,_0x4742f8=this;_0x4742f8['currentUser']=_0x57ab7e['getCurrentUser'](),_0x4742f8[_0x3b4d1c('0x1bb6')]=_0xdddae7,_0x4742f8[_0x3b4d1c('0x243c')]=_0x26337d,_0x4742f8[_0x3b4d1c('0xf01')]=_0x56d050,_0x4742f8['items']=[],_0x4742f8[_0x3b4d1c('0x10ab')]=[],_0x4742f8['selectedItems']=[],_0x4742f8[_0x3b4d1c('0x2111')]=[],_0x4742f8[_0x3b4d1c('0x2781')]=[],_0x4742f8['pendingChanges']=![],_0x4742f8['onInit']=_0x2015c3,_0x4742f8[_0x3b4d1c('0x1d92')]=_0x266cec,_0x4742f8['closeDialog']=_0x427b74,_0x4742f8[_0x3b4d1c('0xc68')]={'readOnly':!_0x4742f8['crudPermissions'][_0x3b4d1c('0x1684')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x3b4d1c('0x4f0'),'line1':_0x3b4d1c('0x6e1'),'line2':[_0x3b4d1c('0x4f0'),_0x3b4d1c('0x1eef')],'line3':'','labelAll':_0x567716['instant'](_0x3b4d1c('0x142a')),'labelSelected':_0x567716[_0x3b4d1c('0x25cc')](_0x3b4d1c('0x19c')),'transferCallback':function(){const _0x352670=_0x3b4d1c,_0x499b83=_0x2cfb05()['xorBy'](_0x4742f8[_0x352670('0x2781')],_0x4742f8[_0x352670('0x18e1')],'id');_0x4742f8[_0x352670('0x14d7')]=_0x2cfb05()[_0x352670('0x1081')](_0x499b83)?![]:!![];}};function _0x2015c3(){const _0x305b44=_0x3b4d1c;return _0x57ab7e['hasRole'](_0x305b44('0xa7c'))?_0x3024fb()[_0x305b44('0x1a80')](function(_0x184eba){const _0x15afdc=_0x305b44;_0x171a5c[_0x15afdc('0xfc9')]({'title':_0x184eba[_0x15afdc('0x52d')]?_0x15afdc('0x1e21')+_0x184eba[_0x15afdc('0x52d')]+_0x15afdc('0x11e1')+_0x184eba[_0x15afdc('0xe1b')]:'SYSTEM:GET_AGENTS','msg':_0x184eba['status']?JSON[_0x15afdc('0xbac')](_0x184eba['data']):_0x184eba[_0x15afdc('0x1586')]()});}):_0x8f221b()[_0x305b44('0x1166')](function(_0x134f41){const _0x65047b=_0x305b44;return _0x4742f8[_0x65047b('0xe60')]=_0x134f41,_0x3024fb();})[_0x305b44('0x1a80')](function(_0x3d2b2a){const _0x12107c=_0x305b44;_0x171a5c[_0x12107c('0xfc9')]({'title':_0x3d2b2a[_0x12107c('0x52d')]?_0x12107c('0x1e21')+_0x3d2b2a[_0x12107c('0x52d')]+_0x12107c('0x11e1')+_0x3d2b2a[_0x12107c('0xe1b')]:_0x12107c('0xd4c'),'msg':_0x3d2b2a[_0x12107c('0x52d')]?JSON[_0x12107c('0xbac')](_0x3d2b2a['data']):_0x3d2b2a[_0x12107c('0x1586')]()});});}function _0x8f221b(){return _0x225fdf(function(_0x34ccb3,_0x428c37){const _0x4f4a71=a0_0x3f2c;_0x4113dc[_0x4f4a71('0x17aa')][_0x4f4a71('0xd83')]({'userProfileId':_0x4742f8['currentUser'][_0x4f4a71('0xb86')],'name':'Agents'})[_0x4f4a71('0xa44')]['then'](function(_0x13fdfc){const _0x566821=_0x4f4a71,_0x5e3e81=_0x13fdfc&&_0x13fdfc[_0x566821('0x269a')]?_0x13fdfc[_0x566821('0x269a')][0x0]:null;_0x34ccb3(_0x5e3e81);})[_0x4f4a71('0x1a80')](function(_0x28d99f){_0x428c37(_0x28d99f);});});}function _0x3024fb(){return _0x225fdf(function(_0x49b3d2,_0x502625){const _0x3d37d4=a0_0x3f2c;return _0x3c3a11()[_0x3d37d4('0x1166')](function(_0x52fac4){const _0x81e781=_0x3d37d4;return _0x4742f8[_0x81e781('0xbd7')]=_0x52fac4[_0x81e781('0x269a')]?_0x52fac4[_0x81e781('0x269a')]:[],_0x57ab7e['hasRole']('admin')?_0x52fac4:_0x4742f8[_0x81e781('0xe60')]?_0x4742f8[_0x81e781('0xe60')][_0x81e781('0x1a2b')]?_0x52fac4:_0x58fbb4():null;})['then'](function(_0x356837){const _0x2d198d=_0x3d37d4,_0x417255=_0x356837&&_0x356837[_0x2d198d('0x269a')]?_0x356837['rows']:[];return _0x4742f8['allowedItems']=_0x2cfb05()[_0x2d198d('0x2563')](_0x417255,function(_0x3bf176){const _0x3eab0e=_0x2d198d;return _0x2cfb05()[_0x3eab0e('0xc38')](_0x4742f8[_0x3eab0e('0xbd7')],{'id':_0x57ab7e[_0x3eab0e('0x1ac6')](_0x3eab0e('0xa7c'))||_0x4742f8[_0x3eab0e('0xe60')][_0x3eab0e('0x1a2b')]?_0x3bf176['id']:_0x3bf176[_0x3eab0e('0x24e8')]});}),_0x4742f8[_0x2d198d('0x2111')]=angular[_0x2d198d('0x225f')](_0x4742f8[_0x2d198d('0x10ab')]),_0x4742f8[_0x2d198d('0xbd7')]['forEach'](function(_0x2a1499){const _0x117b5b=_0x2d198d,_0x205c53=_0x2cfb05()[_0x117b5b('0xc38')](_0x4742f8[_0x117b5b('0x10ab')],{'id':_0x2a1499['id']});_0x57ab7e[_0x117b5b('0x1ac6')](_0x117b5b('0xa7c'))?_0x2a1499['isValid']=!![]:_0x2a1499[_0x117b5b('0x26ef')]=typeof _0x205c53!=='undefined'?!![]:![];}),_0x181499();})[_0x3d37d4('0x1166')](function(_0x321a16){const _0x2965e6=_0x3d37d4,_0x2973e1=_0x321a16&&_0x321a16[_0x2965e6('0x269a')]?_0x321a16[_0x2965e6('0x269a')]:[];_0x4742f8['selectedItems']=_0x2cfb05()[_0x2965e6('0x2563')](_0x2973e1,function(_0x4c5086){const _0x332129=_0x2965e6,_0x11ae22=_0x2cfb05()[_0x332129('0xc38')](_0x4742f8[_0x332129('0xbd7')],{'id':_0x4c5086['id']});return _0x11ae22[_0x332129('0x23af')]=_0x4c5086[_0x332129('0x2225')]?_0x332129('0x11e8')+_0x4c5086[_0x332129('0x2225')][_0x332129('0x23af')]:'',_0x11ae22[_0x332129('0x1eef')]=typeof _0x4c5086['internal']!==_0x332129('0x1048')?'<'+_0x4c5086['internal']+'>':'',_0x11ae22;}),_0x4742f8[_0x2965e6('0x2781')]=angular[_0x2965e6('0x225f')](_0x4742f8[_0x2965e6('0x18e1')]),_0x4742f8[_0x2965e6('0xc68')][_0x2965e6('0x18e1')]=_0x4742f8['selectedItems'],_0x4742f8[_0x2965e6('0xc68')][_0x2965e6('0xbd7')]=_0x2cfb05()[_0x2965e6('0x24ac')](_0x4742f8['allowedItems'],_0x4742f8[_0x2965e6('0xc68')][_0x2965e6('0x18e1')],'id'),_0x49b3d2();})[_0x3d37d4('0x1a80')](function(_0x5c30d1){_0x502625(_0x5c30d1);});});}function _0x58fbb4(){return _0x225fdf(function(_0x1959ab,_0x24f304){const _0x36a10b=a0_0x3f2c;return _0x4113dc[_0x36a10b('0x4b5')][_0x36a10b('0xd83')]({'sectionId':_0x4742f8[_0x36a10b('0xe60')]['id'],'nolimit':!![]})[_0x36a10b('0xa44')][_0x36a10b('0x1166')](function(_0x50f72a){_0x1959ab(_0x50f72a);})[_0x36a10b('0x1a80')](function(_0x525d8b){_0x24f304(_0x525d8b);});});}function _0x181499(){return _0x225fdf(function(_0x34a979,_0x43ab17){const _0x46fd63=a0_0x3f2c;return _0x4113dc['whatsappQueue'][_0x46fd63('0x261c')]({'id':_0x4742f8['whatsappQueue']['id'],'fields':_0x46fd63('0x1459'),'nolimit':!![],'role':'agent'})[_0x46fd63('0xa44')]['then'](function(_0x32d7d4){_0x34a979(_0x32d7d4);})[_0x46fd63('0x1a80')](function(_0x42b06e){_0x43ab17(_0x42b06e);});});}function _0x3c3a11(){return _0x225fdf(function(_0x1eaa09,_0x2e6a40){const _0x564d0f=a0_0x3f2c;return _0x4113dc[_0x564d0f('0x557')][_0x564d0f('0xd83')]({'fields':_0x564d0f('0x1459'),'nolimit':!![],'role':'agent'})[_0x564d0f('0xa44')][_0x564d0f('0x1166')](function(_0x3d6541){_0x1eaa09(_0x3d6541);})['catch'](function(_0x332588){_0x2e6a40(_0x332588);});});}function _0x3bf4ad(_0x37ff69){return _0x225fdf(function(_0x70eca4,_0x5b44ff){const _0x1d26d2=a0_0x3f2c;_0x2cfb05()[_0x1d26d2('0x1081')](_0x37ff69)?_0x70eca4():_0x4113dc[_0x1d26d2('0x1bb6')]['addAgents']({'id':_0x4742f8[_0x1d26d2('0x1bb6')]['id'],'ids':_0x2cfb05()[_0x1d26d2('0x2563')](_0x37ff69,'id')})[_0x1d26d2('0xa44')][_0x1d26d2('0x1166')](function(){_0x70eca4();})[_0x1d26d2('0x1a80')](function(_0x58f6bf){_0x5b44ff(_0x58f6bf);});});}function _0x26833c(_0x263f5d){return _0x225fdf(function(_0x2baa8f,_0x49d1a3){const _0x136ad9=a0_0x3f2c;_0x2cfb05()[_0x136ad9('0x1081')](_0x263f5d)?_0x2baa8f():_0x4113dc[_0x136ad9('0x1bb6')][_0x136ad9('0x269d')]({'id':_0x4742f8[_0x136ad9('0x1bb6')]['id'],'ids':_0x2cfb05()[_0x136ad9('0x2563')](_0x263f5d,'id')})['$promise']['then'](function(){_0x2baa8f();})[_0x136ad9('0x1a80')](function(_0x50b78b){_0x49d1a3(_0x50b78b);});});}function _0x266cec(){const _0xc59c7a=_0x3b4d1c,_0x27344c=_0x2cfb05()['differenceBy'](_0x4742f8[_0xc59c7a('0x2781')],_0x4742f8[_0xc59c7a('0x18e1')],'id'),_0x18ef91=_0x2cfb05()['differenceBy'](_0x4742f8['selectedItems'],_0x4742f8[_0xc59c7a('0x2781')],'id');return _0x26833c(_0x27344c)[_0xc59c7a('0x1166')](function(){return _0x3bf4ad(_0x18ef91);})[_0xc59c7a('0x1166')](function(){const _0x2692f4=_0xc59c7a;_0x4742f8[_0x2692f4('0x14d7')]=![],_0x4742f8[_0x2692f4('0x2111')]=angular[_0x2692f4('0x225f')](_0x4742f8['allowedItems']),_0x4742f8[_0x2692f4('0x2781')]=angular['copy'](_0x4742f8[_0x2692f4('0x18e1')]),_0x171a5c[_0x2692f4('0x103b')]({'title':'SUCCESS','msg':_0x2692f4('0x1673')});})['catch'](function(_0x3e78af){const _0x4a5ad9=_0xc59c7a;_0x171a5c[_0x4a5ad9('0xfc9')]({'title':_0x3e78af['status']?_0x4a5ad9('0x1e21')+_0x3e78af[_0x4a5ad9('0x52d')]+'\x20-\x20'+_0x3e78af[_0x4a5ad9('0xe1b')]:'SYSTEM:LISTS_ASSOCIATION','msg':_0x3e78af[_0x4a5ad9('0x52d')]?JSON[_0x4a5ad9('0xbac')](_0x3e78af[_0x4a5ad9('0x25f4')]):_0x3e78af[_0x4a5ad9('0x1586')]()});});}function _0x427b74(){_0x4f25ac['hide']();}}const _0x3425eb=_0x3ff80d;_0x58233a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x265d'),'$q',_0x36e6f4('0x1d2e'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1bb6'),_0x36e6f4('0x586'),_0x36e6f4('0x21ef'),_0x36e6f4('0x243c')];function _0x58233a(_0x4c7e5d,_0x11826f,_0x25431a,_0x3f456e,_0x1c7964,_0x2b5fcc,_0x3a6369,_0x3cc7cc){const _0xf66185=_0x36e6f4,_0x193734=this;_0x193734[_0xf66185('0x98')]=_0x3a6369['getCurrentUser'](),_0x193734['whatsappQueue']=_0x1c7964,_0x193734[_0xf66185('0x243c')]=_0x3cc7cc,_0x193734[_0xf66185('0xbd7')]=[],_0x193734[_0xf66185('0x10ab')]=[],_0x193734[_0xf66185('0x18e1')]=[],_0x193734['startingAllowedItems']=[],_0x193734[_0xf66185('0x2781')]=[],_0x193734['pendingChanges']=![],_0x193734['dualMultiselectOptions']={'readOnly':!_0x193734['crudPermissions']['canEdit'],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0xf66185('0x4f0'),'line1':'name','line2':'','line3':'','labelAll':_0x2b5fcc[_0xf66185('0x25cc')](_0xf66185('0x6e5')),'labelSelected':_0x2b5fcc[_0xf66185('0x25cc')]('WHATSAPP.SELECTED_TEAMS'),'transferCallback':function(){const _0x101bbd=_0xf66185,_0x5efa06=_0x2cfb05()[_0x101bbd('0x2802')](_0x193734['startingSelectedItems'],_0x193734['selectedItems'],'id');_0x193734[_0x101bbd('0x14d7')]=_0x2cfb05()[_0x101bbd('0x1081')](_0x5efa06)?![]:!![];}},_0x193734[_0xf66185('0xae0')]=_0x518377,_0x193734[_0xf66185('0x1add')]=_0x1241b4,_0x193734['closeDialog']=_0x9f398a;function _0x518377(){const _0x393b56=_0xf66185;return _0x3a6369[_0x393b56('0x1ac6')](_0x393b56('0xa7c'))?_0x1aabc3()[_0x393b56('0x1a80')](function(_0x502cb0){const _0x56c52f=_0x393b56;_0x25431a[_0x56c52f('0xfc9')]({'title':_0x502cb0[_0x56c52f('0x52d')]?'API:'+_0x502cb0['status']+_0x56c52f('0x11e1')+_0x502cb0[_0x56c52f('0xe1b')]:'SYSTEM:GET_TEAMS','msg':_0x502cb0['status']?JSON[_0x56c52f('0xbac')](_0x502cb0[_0x56c52f('0x25f4')]):_0x502cb0[_0x56c52f('0x1586')]()});}):_0xfc36fa()[_0x393b56('0x1166')](function(_0x2cb800){const _0x25076f=_0x393b56;return _0x193734[_0x25076f('0xe60')]=_0x2cb800,_0x1aabc3();})[_0x393b56('0x1a80')](function(_0x351c49){const _0x2e27a0=_0x393b56;_0x25431a['error']({'title':_0x351c49[_0x2e27a0('0x52d')]?_0x2e27a0('0x1e21')+_0x351c49['status']+_0x2e27a0('0x11e1')+_0x351c49[_0x2e27a0('0xe1b')]:_0x2e27a0('0x1031'),'msg':_0x351c49[_0x2e27a0('0x52d')]?JSON['stringify'](_0x351c49['data']):_0x351c49[_0x2e27a0('0x1586')]()});});}function _0xfc36fa(){return _0x11826f(function(_0x277fa4,_0x548969){const _0x5c2880=a0_0x3f2c;_0x3f456e[_0x5c2880('0x17aa')]['get']({'userProfileId':_0x193734['currentUser']['userProfileId'],'name':_0x5c2880('0x289e')})[_0x5c2880('0xa44')]['then'](function(_0x56e74d){const _0x464808=_0x5c2880,_0x435ea1=_0x56e74d&&_0x56e74d[_0x464808('0x269a')]?_0x56e74d['rows'][0x0]:null;_0x277fa4(_0x435ea1);})['catch'](function(_0x147436){_0x548969(_0x147436);});});}function _0x1aabc3(){return _0x11826f(function(_0x35d2a1,_0x97e5f9){const _0x2888d2=a0_0x3f2c;return _0x5e02c0()['then'](function(_0x26d354){const _0x4dc5ec=a0_0x3f2c;return _0x193734[_0x4dc5ec('0xbd7')]=_0x26d354['rows']?_0x26d354[_0x4dc5ec('0x269a')]:[],_0x3a6369[_0x4dc5ec('0x1ac6')]('admin')?_0x26d354:_0x193734[_0x4dc5ec('0xe60')]?_0x193734[_0x4dc5ec('0xe60')]['autoAssociation']?_0x26d354:_0x4a237d():null;})[_0x2888d2('0x1166')](function(_0x458f1d){const _0x4f5617=_0x2888d2,_0x24813f=_0x458f1d&&_0x458f1d[_0x4f5617('0x269a')]?_0x458f1d[_0x4f5617('0x269a')]:[];return _0x193734[_0x4f5617('0x10ab')]=_0x2cfb05()[_0x4f5617('0x2563')](_0x24813f,function(_0x2eada2){const _0x493a9b=_0x4f5617;return _0x2cfb05()[_0x493a9b('0xc38')](_0x193734[_0x493a9b('0xbd7')],{'id':_0x3a6369[_0x493a9b('0x1ac6')](_0x493a9b('0xa7c'))||_0x193734['section'][_0x493a9b('0x1a2b')]?_0x2eada2['id']:_0x2eada2[_0x493a9b('0x24e8')]});}),_0x193734['items']['forEach'](function(_0xee97ce){const _0x2cc837=_0x4f5617,_0xc2cabf=_0x2cfb05()[_0x2cc837('0xc38')](_0x193734[_0x2cc837('0x10ab')],{'id':_0xee97ce['id']});_0x3a6369['hasRole'](_0x2cc837('0xa7c'))?_0xee97ce['isValid']=!![]:_0xee97ce[_0x2cc837('0x26ef')]=typeof _0xc2cabf!==_0x2cc837('0x1048')?!![]:![];}),_0x4471c5();})[_0x2888d2('0x1166')](function(_0x4cff21){const _0x47deaf=_0x2888d2,_0x3068bf=_0x4cff21&&_0x4cff21[_0x47deaf('0x269a')]?_0x4cff21[_0x47deaf('0x269a')]:[];_0x193734['selectedItems']=_0x2cfb05()[_0x47deaf('0x2563')](_0x3068bf,function(_0x2ff676){const _0x26f489=_0x47deaf;return _0x2cfb05()[_0x26f489('0xc38')](_0x193734[_0x26f489('0xbd7')],{'id':_0x2ff676['id']});}),_0x193734[_0x47deaf('0x2781')]=angular[_0x47deaf('0x225f')](_0x193734[_0x47deaf('0x18e1')]),_0x193734[_0x47deaf('0xc68')][_0x47deaf('0x18e1')]=_0x193734[_0x47deaf('0x18e1')],_0x193734['dualMultiselectOptions']['items']=_0x2cfb05()[_0x47deaf('0x24ac')](_0x193734[_0x47deaf('0x10ab')],_0x193734[_0x47deaf('0xc68')]['selectedItems'],'id'),_0x35d2a1();})[_0x2888d2('0x1a80')](function(_0xfc3622){_0x97e5f9(_0xfc3622);});});}function _0x4a237d(){return _0x11826f(function(_0x5e8a14,_0x203cb0){const _0x93392a=a0_0x3f2c;return _0x3f456e[_0x93392a('0x4b5')][_0x93392a('0xd83')]({'sectionId':_0x193734[_0x93392a('0xe60')]['id'],'nolimit':!![]})['$promise'][_0x93392a('0x1166')](function(_0x498383){_0x5e8a14(_0x498383);})[_0x93392a('0x1a80')](function(_0x372a69){_0x203cb0(_0x372a69);});});}function _0x4471c5(){return _0x11826f(function(_0x27b93e,_0x5ee7e8){const _0x4a1f95=a0_0x3f2c;return _0x3f456e[_0x4a1f95('0x1bb6')]['getTeams']({'id':_0x193734[_0x4a1f95('0x1bb6')]['id'],'fields':_0x4a1f95('0x1776'),'nolimit':!![]})[_0x4a1f95('0xa44')]['then'](function(_0xc7ee79){_0x27b93e(_0xc7ee79);})['catch'](function(_0x25ec72){_0x5ee7e8(_0x25ec72);});});}function _0x5e02c0(){return _0x11826f(function(_0xcd7c5e,_0x490ddc){const _0x55a293=a0_0x3f2c;return _0x3f456e[_0x55a293('0x1e37')]['get']({'fields':_0x55a293('0x1776'),'nolimit':!![]})['$promise'][_0x55a293('0x1166')](function(_0x178588){_0xcd7c5e(_0x178588);})[_0x55a293('0x1a80')](function(_0x48a6dd){_0x490ddc(_0x48a6dd);});});}function _0xcb5cce(_0x3a6de2){return _0x11826f(function(_0x15a038,_0x1d33fe){const _0x9581e7=a0_0x3f2c;_0x2cfb05()['isEmpty'](_0x3a6de2)?_0x15a038():_0x3f456e['whatsappQueue'][_0x9581e7('0x16e0')]({'id':_0x193734[_0x9581e7('0x1bb6')]['id'],'ids':_0x2cfb05()[_0x9581e7('0x2563')](_0x3a6de2,'id')})[_0x9581e7('0xa44')]['then'](function(){_0x15a038();})[_0x9581e7('0x1a80')](function(_0x2e7a97){_0x1d33fe(_0x2e7a97);});});}function _0x1e09b9(_0x425519){return _0x11826f(function(_0x3707eb,_0x20120c){const _0x4b59a8=a0_0x3f2c;_0x2cfb05()[_0x4b59a8('0x1081')](_0x425519)?_0x3707eb():_0x3f456e[_0x4b59a8('0x1bb6')][_0x4b59a8('0x8f')]({'id':_0x193734['whatsappQueue']['id'],'ids':_0x2cfb05()[_0x4b59a8('0x2563')](_0x425519,'id')})[_0x4b59a8('0xa44')][_0x4b59a8('0x1166')](function(){_0x3707eb();})[_0x4b59a8('0x1a80')](function(_0x56f972){_0x20120c(_0x56f972);});});}function _0x1241b4(){const _0x1bc731=_0xf66185,_0x37200e=_0x2cfb05()[_0x1bc731('0x24ac')](_0x193734[_0x1bc731('0x2781')],_0x193734['selectedItems'],'id'),_0x2f5cf6=_0x2cfb05()[_0x1bc731('0x24ac')](_0x193734[_0x1bc731('0x18e1')],_0x193734[_0x1bc731('0x2781')],'id');return _0x1e09b9(_0x37200e)[_0x1bc731('0x1166')](function(){return _0xcb5cce(_0x2f5cf6);})[_0x1bc731('0x1166')](function(){const _0x56a9f1=_0x1bc731;_0x193734[_0x56a9f1('0x14d7')]=![],_0x193734[_0x56a9f1('0x2111')]=angular['copy'](_0x193734[_0x56a9f1('0x10ab')]),_0x193734[_0x56a9f1('0x2781')]=angular[_0x56a9f1('0x225f')](_0x193734[_0x56a9f1('0x18e1')]),_0x25431a[_0x56a9f1('0x103b')]({'title':_0x56a9f1('0x983'),'msg':_0x56a9f1('0x1f6b')});})['catch'](function(_0x112503){const _0x1718dc=_0x1bc731;_0x25431a[_0x1718dc('0xfc9')]({'title':_0x112503[_0x1718dc('0x52d')]?_0x1718dc('0x1e21')+_0x112503['status']+_0x1718dc('0x11e1')+_0x112503['statusText']:_0x1718dc('0x1b29'),'msg':_0x112503[_0x1718dc('0x52d')]?JSON[_0x1718dc('0xbac')](_0x112503['data']):_0x112503[_0x1718dc('0x1586')]()});});}function _0x9f398a(){const _0x3ed3da=_0xf66185;_0x4c7e5d[_0x3ed3da('0x1197')]();}}const _0x53c97e=_0x58233a,_0x30860f=_0x2734b2['p']+_0x36e6f4('0x1a6e');_0x5d7ba9[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),'$location',_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x586'),'license',_0x36e6f4('0xf8a'),'api',_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x1bb6'),_0x36e6f4('0x17aa')];function _0x5d7ba9(_0x3e19c3,_0xbd47de,_0x50c37d,_0x4e7409,_0x116fc7,_0x5272a1,_0x3fba25,_0x5ba480,_0x3a901e,_0x4dece2,_0x243070,_0x10013c){const _0x40e4d6=_0x36e6f4,_0x141cd1=this;_0x141cd1[_0x40e4d6('0x98')]=_0x4dece2[_0x40e4d6('0x26cd')](),_0x141cd1[_0x40e4d6('0x5c9')]=_0x5272a1,_0x141cd1[_0x40e4d6('0xf8a')]=_0x3fba25,_0x141cd1[_0x40e4d6('0x2900')]=_0x141cd1[_0x40e4d6('0xf8a')][_0x40e4d6('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x141cd1[_0x40e4d6('0x246b')]=_0xbd47de[_0x40e4d6('0x6f1')]()+_0x40e4d6('0xc51')+_0xbd47de['host'](),_0x141cd1[_0x40e4d6('0x1bb6')]=_0x243070||_0x3e19c3['params'][_0x40e4d6('0x1bb6')]||{},_0x141cd1[_0x40e4d6('0x17aa')]=_0x10013c&&_0x10013c['count']==0x1?_0x10013c[_0x40e4d6('0x269a')][0x0]:null,_0x141cd1[_0x40e4d6('0x243c')]=_0x4dece2[_0x40e4d6('0xd87')](_0x141cd1[_0x40e4d6('0x17aa')]?_0x141cd1[_0x40e4d6('0x17aa')][_0x40e4d6('0x243c')]:null),_0x141cd1[_0x40e4d6('0x128b')]={},_0x141cd1[_0x40e4d6('0x2669')]=_0x3e19c3[_0x40e4d6('0x23f')][_0x40e4d6('0xbe3')]||0x0,_0x141cd1['teamadddialog']=_0x9d5c3e,_0x141cd1['agentadddialog']=_0x4a079b,_0x141cd1['alert']=_0x3a901e['info'],_0x141cd1[_0x40e4d6('0x6bc')]=_0x13615c,_0x141cd1[_0x40e4d6('0x1b1b')]=_0x2e188f;function _0x9d5c3e(_0x1a271c,_0x1d7876){const _0x217099=_0x40e4d6;_0x50c37d['show']({'controller':_0x217099('0xdbd'),'controllerAs':'vm','templateUrl':_0x30860f,'parent':angular[_0x217099('0x1194')](_0x4e7409['body']),'targetEvent':_0x1d7876,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x1a271c,'whatsappQueues':_0x141cd1[_0x217099('0x147f')]?_0x141cd1[_0x217099('0x147f')][_0x217099('0x269a')]:[],'crudPermissions':_0x141cd1[_0x217099('0x243c')]}});}function _0x4a079b(_0x3c742b,_0x3dd725){const _0xf81f66=_0x40e4d6;_0x50c37d[_0xf81f66('0x1f80')]({'controller':_0xf81f66('0x644'),'controllerAs':'vm','templateUrl':_0x54a35d,'parent':angular[_0xf81f66('0x1194')](_0x4e7409[_0xf81f66('0x8d2')]),'targetEvent':_0x3dd725,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x3c742b,'whatsappQueues':_0x141cd1['whatsappQueues']?_0x141cd1[_0xf81f66('0x147f')][_0xf81f66('0x269a')]:[],'crudPermissions':_0x141cd1[_0xf81f66('0x243c')],'realtime':![]}});}function _0x13615c(){const _0x41a269=_0x40e4d6;_0x3e19c3['go'](_0x41a269('0x1a'),{},{'reload':_0x41a269('0x1a')});}function _0x2e188f(){const _0x508979=_0x40e4d6;_0x5ba480[_0x508979('0x1bb6')][_0x508979('0x1449')]({'id':_0x141cd1['whatsappQueue']['id']},_0x141cd1[_0x508979('0x1bb6')])[_0x508979('0xa44')]['then'](function(){const _0x4d2d3c=_0x508979;_0x3a901e[_0x4d2d3c('0x103b')]({'title':_0x4d2d3c('0x1185'),'msg':_0x141cd1[_0x4d2d3c('0x1bb6')][_0x4d2d3c('0x4f0')]?_0x141cd1['whatsappQueue'][_0x4d2d3c('0x4f0')]+_0x4d2d3c('0xa17'):''});})[_0x508979('0x1a80')](function(_0x390463){const _0x5289d4=_0x508979;_0x3a901e[_0x5289d4('0xfc9')]({'title':_0x390463[_0x5289d4('0x52d')]?_0x5289d4('0x1e21')+_0x390463['status']+_0x5289d4('0x11e1')+_0x390463['statusText']:_0x5289d4('0x135c'),'msg':_0x390463[_0x5289d4('0x25f4')]?JSON[_0x5289d4('0xbac')](_0x390463[_0x5289d4('0x25f4')]):_0x390463[_0x5289d4('0x1586')]()});});}}const _0x1952c0=_0x5d7ba9;_0xb890b3['$inject']=['$scope',_0x36e6f4('0x1566'),_0x36e6f4('0x7b9'),_0x36e6f4('0xc46'),_0x36e6f4('0x265d'),_0x36e6f4('0x1c90'),_0x36e6f4('0x8da'),_0x36e6f4('0x586'),'whatsappQueues',_0x36e6f4('0x7f'),'userProfileSection',_0x36e6f4('0x19e3'),_0x36e6f4('0x1f36'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x21ef'),_0x36e6f4('0x5c9'),_0x36e6f4('0xf8a')];function _0xb890b3(_0x5e65ee,_0x41f08d,_0xdf409c,_0x4e991e,_0x484493,_0x286733,_0x3a9ec7,_0x4830c7,_0xfb84ce,_0x49c2cf,_0x3a5661,_0x403777,_0x14f6c9,_0x5e9214,_0xfdaec0,_0x308259,_0x30c02e){const _0x528123=_0x36e6f4,_0x2301a1=this;_0x2301a1[_0x528123('0x5c9')]=_0x308259,_0x2301a1[_0x528123('0xf8a')]=_0x30c02e,_0x2301a1[_0x528123('0x98')]=_0xfdaec0[_0x528123('0x26cd')](),_0x2301a1['whatsappQueues']=_0xfb84ce||{'count':0x0,'rows':[]},_0x2301a1[_0x528123('0x7f')]=_0x49c2cf,_0x2301a1[_0x528123('0x17aa')]=_0x3a5661&&_0x3a5661[_0x528123('0x240f')]==0x1?_0x3a5661[_0x528123('0x269a')][0x0]:null,_0x2301a1[_0x528123('0x243c')]=_0xfdaec0['parseCrudPermissions'](_0x2301a1['userProfileSection']?_0x2301a1[_0x528123('0x17aa')][_0x528123('0x243c')]:null),_0x2301a1['table']=_0x528123('0x147f'),_0x2301a1[_0x528123('0xef5')]='',_0x2301a1[_0x528123('0x104c')]=null,_0x2301a1[_0x528123('0xa1d')]=[],_0x2301a1[_0x528123('0x2218')]={'fields':_0x528123('0xf26'),'sort':_0x528123('0x14dc'),'channel':_0x528123('0x116e'),'limit':0xa,'page':0x1},_0x2301a1[_0x528123('0x1440')]=_0x2cfb05()[_0x528123('0x155c')]([{'option':_0x528123('0xb16'),'value':_0x528123('0x1792')},{'option':_0x528123('0x75'),'value':'\x27rrmemory\x27'}],function(_0x5f3d1b){const _0x37c2f9=_0x528123;return _0x2cfb05()[_0x37c2f9('0xf3')](_0x5f3d1b['value'],new RegExp('\x27','g'),'');}),_0x2301a1[_0x528123('0x1ff6')]=_0x53cba7,_0x2301a1[_0x528123('0x292')]=_0x2a62c3,_0x2301a1[_0x528123('0x1728')]=_0x1c15c7,_0x2301a1[_0x528123('0x8d8')]=_0x17ccde,_0x2301a1[_0x528123('0x182d')]=_0x4d0304,_0x2301a1[_0x528123('0x103b')]=_0x134f52,_0x2301a1['getWhatsappQueues']=_0x3aee57,_0x2301a1[_0x528123('0x2854')]=_0x418b08,_0x2301a1[_0x528123('0x436')]=_0x4a91a9,_0x2301a1['exportSelectedWhatsappQueues']=_0x59d5d9,_0x2301a1['deleteSelectedWhatsappQueues']=_0x385996,_0x2301a1[_0x528123('0x216f')]=_0x5a9096,_0x2301a1['selectAllWhatsappQueues']=_0x510868;function _0x53cba7(_0x4c708a){_0xdf409c['go']('app.whatsapp.whatsappQueues.edit',{'id':_0x4c708a['id'],'whatsappQueue':_0x4c708a,'crudPermissions':_0x2301a1['crudPermissions']});}function _0x2a62c3(_0x5de65e,_0x106ffd){const _0x22bdc4=_0x528123;_0x484493[_0x22bdc4('0x1f80')]({'controller':_0x22bdc4('0xdbd'),'controllerAs':'vm','templateUrl':_0x30860f,'parent':angular[_0x22bdc4('0x1194')](_0x286733[_0x22bdc4('0x8d2')]),'targetEvent':_0x106ffd,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x5de65e,'whatsappQueues':_0x2301a1[_0x22bdc4('0x147f')]?_0x2301a1[_0x22bdc4('0x147f')]['rows']:[],'crudPermissions':_0x2301a1[_0x22bdc4('0x243c')]}});}function _0x1c15c7(_0x200a0f,_0x3165ba){const _0x1e261a=_0x528123;_0x484493[_0x1e261a('0x1f80')]({'controller':_0x1e261a('0x644'),'controllerAs':'vm','templateUrl':_0x54a35d,'parent':angular[_0x1e261a('0x1194')](_0x286733['body']),'targetEvent':_0x3165ba,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x200a0f,'whatsappQueues':_0x2301a1['whatsappQueues']?_0x2301a1[_0x1e261a('0x147f')][_0x1e261a('0x269a')]:[],'crudPermissions':_0x2301a1[_0x1e261a('0x243c')],'realtime':![]}});}function _0x17ccde(_0x1d1364,_0xbffe60){const _0x3218e0=_0x528123,_0x2be38e=_0x484493[_0x3218e0('0x1d26')]()[_0x3218e0('0xcdc')](_0x3218e0('0x288d')+_0x2cfb05()['startCase'](_0x3218e0('0x1bb6'))+'?')[_0x3218e0('0xf3c')](_0x3218e0('0x12b5')+(_0x1d1364['name']||_0x3218e0('0x1bb6'))+_0x3218e0('0xace')+_0x3218e0('0x3f3'))[_0x3218e0('0x8e8')](_0x3218e0('0x244e'))[_0x3218e0('0x203b')](_0xbffe60)['ok']('OK')['cancel']('CANCEL');_0x484493[_0x3218e0('0x1f80')](_0x2be38e)[_0x3218e0('0x1166')](function(){_0x4a91a9(_0x1d1364);},function(){const _0x4c8272=_0x3218e0;console['log'](_0x4c8272('0x2d3'));});}function _0x4d0304(){const _0x1f24e8=_0x528123;if(_0xfdaec0[_0x1f24e8('0x1ac6')]('admin'))_0xdf409c['go']('app.whatsapp.realtime.queues',{});else return _0x403777[_0x1f24e8('0x17aa')][_0x1f24e8('0xd83')]({'userProfileId':_0xfdaec0[_0x1f24e8('0x26cd')]()[_0x1f24e8('0xb86')],'sectionId':0x83e})['$promise'][_0x1f24e8('0x1166')](function(_0x4402b8){const _0x182d78=_0x1f24e8,_0x468be1=_0x4402b8&&_0x4402b8[_0x182d78('0x269a')]?_0x4402b8['rows'][0x0]:null;_0x468be1&&_0x468be1[_0x182d78('0xc27')]?_0xdf409c['go'](_0x182d78('0x2210'),{}):_0x5e9214[_0x182d78('0x1fa1')]({'title':_0x4830c7[_0x182d78('0x25cc')](_0x182d78('0x627')),'msg':_0x4830c7[_0x182d78('0x25cc')](_0x182d78('0x2642'))});})[_0x1f24e8('0x1a80')](function(_0x4cd70f){const _0x41c164=_0x1f24e8;_0x5e9214[_0x41c164('0xfc9')]({'title':_0x4cd70f[_0x41c164('0x52d')]?'API:'+_0x4cd70f[_0x41c164('0x52d')]+_0x41c164('0x11e1')+_0x4cd70f[_0x41c164('0xe1b')]:'USERPROFILE:GET_SECTION','msg':_0x4cd70f[_0x41c164('0x52d')]?JSON[_0x41c164('0xbac')](_0x4cd70f[_0x41c164('0x25f4')]):_0x4cd70f['toString']()});});}let _0x13b154=!![],_0x3df33f=0x1;_0x5e65ee[_0x528123('0xe83')](_0x528123('0x12d8'),function(_0x3c7346,_0x3c7287){const _0x3f9218=_0x528123;_0x13b154?_0x3a9ec7(function(){_0x13b154=![];}):(!_0x3c7287&&(_0x3df33f=_0x2301a1[_0x3f9218('0x2218')][_0x3f9218('0x1a43')]),_0x3c7346!==_0x3c7287&&(_0x2301a1[_0x3f9218('0x2218')][_0x3f9218('0x1a43')]=0x1),!_0x3c7346&&(_0x2301a1[_0x3f9218('0x2218')]['page']=_0x3df33f),_0x2301a1[_0x3f9218('0xfb1')]());});function _0x134f52(_0x1a16a9){const _0x2041dc=_0x528123;_0x2301a1[_0x2041dc('0x147f')]=_0x1a16a9||{'count':0x0,'rows':[]};}function _0x3aee57(){const _0x2ddf42=_0x528123;_0x2301a1[_0x2ddf42('0x2218')][_0x2ddf42('0x1098')]=(_0x2301a1['query']['page']-0x1)*_0x2301a1[_0x2ddf42('0x2218')][_0x2ddf42('0x163f')],_0xfdaec0[_0x2ddf42('0x1ac6')]('admin')?_0x2301a1[_0x2ddf42('0x1f48')]=_0x403777[_0x2ddf42('0x1bb6')][_0x2ddf42('0xd83')](_0x2301a1[_0x2ddf42('0x2218')],_0x134f52)[_0x2ddf42('0xa44')]:(_0x2301a1[_0x2ddf42('0x2218')]['id']=_0x2301a1['userProfile']['id'],_0x2301a1[_0x2ddf42('0x2218')][_0x2ddf42('0xe60')]=_0x2ddf42('0x2727'),_0x2301a1['promise']=_0x403777[_0x2ddf42('0x7f')][_0x2ddf42('0x263a')](_0x2301a1[_0x2ddf42('0x2218')],_0x134f52)[_0x2ddf42('0xa44')]);}function _0x418b08(_0x1d3ca6,_0x1dbd0e){const _0x35e670=_0x528123;_0x484493[_0x35e670('0x1f80')]({'controller':'CreateOrEditWhatsappQueueDialogController','controllerAs':'vm','templateUrl':_0x51b24c,'parent':angular[_0x35e670('0x1194')](_0x286733[_0x35e670('0x8d2')]),'targetEvent':_0x1d3ca6,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x1dbd0e,'whatsappQueues':_0x2301a1[_0x35e670('0x147f')][_0x35e670('0x269a')],'license':_0x2301a1[_0x35e670('0x5c9')],'setting':_0x2301a1[_0x35e670('0xf8a')],'crudPermissions':_0x2301a1[_0x35e670('0x243c')]}});}function _0x4a91a9(_0x4bc5b6){const _0x207058=_0x528123;_0x403777[_0x207058('0x1bb6')]['delete']({'id':_0x4bc5b6['id']})[_0x207058('0xa44')]['then'](function(){const _0x35263e=_0x207058;_0x2cfb05()[_0x35263e('0x127f')](_0x2301a1['whatsappQueues']['rows'],{'id':_0x4bc5b6['id']}),_0x2301a1[_0x35263e('0x147f')]['count']-=0x1,!_0x2301a1[_0x35263e('0x147f')][_0x35263e('0x269a')][_0x35263e('0x264b')]&&_0x2301a1[_0x35263e('0xfb1')](),_0x5e9214[_0x35263e('0x103b')]({'title':_0x2cfb05()['startCase'](_0x35263e('0x1071'))+_0x35263e('0x2b6'),'msg':_0x4bc5b6[_0x35263e('0x4f0')]?_0x4bc5b6[_0x35263e('0x4f0')]+_0x35263e('0x7cd'):''});})[_0x207058('0x1a80')](function(_0x1d1a1d){const _0x411db6=_0x207058;if(_0x1d1a1d[_0x411db6('0x25f4')]&&_0x1d1a1d[_0x411db6('0x25f4')][_0x411db6('0x61a')]&&_0x1d1a1d[_0x411db6('0x25f4')][_0x411db6('0x61a')][_0x411db6('0x264b')]){_0x2301a1['errors']=_0x1d1a1d[_0x411db6('0x25f4')]['errors']||[{'message':_0x1d1a1d[_0x411db6('0x1586')](),'type':_0x411db6('0x1ad4')}];for(let _0x1739e5=0x0;_0x1739e5<_0x1d1a1d[_0x411db6('0x25f4')][_0x411db6('0x61a')]['length'];_0x1739e5++){_0x5e9214['error']({'title':_0x1d1a1d['data'][_0x411db6('0x61a')][_0x1739e5][_0x411db6('0x1345')],'msg':_0x1d1a1d['data'][_0x411db6('0x61a')][_0x1739e5]['message']});}}else _0x5e9214[_0x411db6('0xfc9')]({'title':_0x1d1a1d[_0x411db6('0x52d')]?_0x411db6('0x1e21')+_0x1d1a1d[_0x411db6('0x52d')]+_0x411db6('0x11e1')+_0x1d1a1d['statusText']:_0x411db6('0x1ad4'),'msg':_0x1d1a1d[_0x411db6('0x25f4')]?JSON[_0x411db6('0xbac')](_0x1d1a1d[_0x411db6('0x25f4')][_0x411db6('0x1e70')]):_0x1d1a1d[_0x411db6('0x1e70')]||_0x1d1a1d['toString']()});});}function _0x59d5d9(){const _0x5e7e15=_0x528123,_0x5e2f59=angular[_0x5e7e15('0x225f')](_0x2301a1['selectedWhatsappQueues']);return _0x2301a1[_0x5e7e15('0xa1d')]=[],_0x5e2f59;}function _0x385996(_0x55a199){const _0x5b5e8e=_0x528123,_0x4f6db2=_0x484493['confirm']()[_0x5b5e8e('0xcdc')](_0x5b5e8e('0x1f4c'))[_0x5b5e8e('0xf3c')](_0x5b5e8e('0x12b5')+_0x2301a1[_0x5b5e8e('0xa1d')][_0x5b5e8e('0x264b')]+'\x20selected'+_0x5b5e8e('0x3f3'))[_0x5b5e8e('0x8e8')](_0x5b5e8e('0x42b'))['targetEvent'](_0x55a199)['ok']('OK')['cancel'](_0x5b5e8e('0x2d3'));_0x484493[_0x5b5e8e('0x1f80')](_0x4f6db2)['then'](function(){const _0x546de2=_0x5b5e8e;_0x2301a1[_0x546de2('0xa1d')][_0x546de2('0x2782')](function(_0x4a6121){_0x4a91a9(_0x4a6121);}),_0x2301a1['selectedWhatsappQueues']=[];});}function _0x5a9096(){_0x2301a1['selectedWhatsappQueues']=[];}function _0x510868(){const _0x406f47=_0x528123;_0x2301a1['selectedWhatsappQueues']=_0x2301a1['whatsappQueues'][_0x406f47('0x269a')];}}const _0x49d7db=_0xb890b3;_0x486e9c[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),'$translatePartialLoaderProvider'];function _0x486e9c(_0x27bc19,_0x2bfa4b){const _0x54d3c5=_0x36e6f4;_0x27bc19['state'](_0x54d3c5('0x13c3'),{'abstract':!![],'url':_0x54d3c5('0xd58')})['state'](_0x54d3c5('0x1a'),{'url':'/whatsappQueues','views':{'content@app':{'templateUrl':_0x4c1ae7,'controller':_0x54d3c5('0x94c')}},'resolve':{'whatsappQueues':[_0x54d3c5('0x1fbc'),_0x54d3c5('0x21ef'),function(_0x5f5160,_0x4132cf){const _0x87a799=_0x54d3c5;return _0x4132cf['hasRole'](_0x87a799('0xa7c'))?_0x5f5160['resolve']('whatsappQueue@get',{'fields':_0x87a799('0xf26'),'sort':_0x87a799('0x14dc'),'channel':_0x87a799('0x116e'),'limit':0xa,'offset':0x0}):_0x5f5160[_0x87a799('0x18af')](_0x87a799('0x17c4'),{'id':_0x4132cf[_0x87a799('0x26cd')]()[_0x87a799('0xb86')],'section':_0x87a799('0x2727'),'fields':_0x87a799('0xf26'),'sort':'-updatedAt','channel':_0x87a799('0x116e'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x54d3c5('0x1fbc'),_0x54d3c5('0x21ef'),function(_0x30a22d,_0x5552d1){const _0x37a979=_0x54d3c5;return _0x5552d1[_0x37a979('0x1ac6')]('admin')?null:_0x30a22d['resolve'](_0x37a979('0x697'),{'fields':_0x37a979('0x686'),'id':_0x5552d1[_0x37a979('0x26cd')]()[_0x37a979('0xb86')]});}],'userProfileSection':[_0x54d3c5('0x1fbc'),_0x54d3c5('0x21ef'),function(_0x15038a,_0x665c8){const _0x48c644=_0x54d3c5;return _0x665c8[_0x48c644('0x1ac6')](_0x48c644('0xa7c'))?null:_0x15038a[_0x48c644('0x18af')](_0x48c644('0xaf'),{'fields':_0x48c644('0xe26'),'userProfileId':_0x665c8['getCurrentUser']()[_0x48c644('0xb86')],'sectionId':0x835});}]},'authenticate':!![],'permissionId':0x835,'bodyClass':_0x54d3c5('0x116e')})[_0x54d3c5('0x63f')](_0x54d3c5('0x1bce'),{'url':_0x54d3c5('0x2233'),'params':{'whatsappQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x52dcc0,'controller':_0x54d3c5('0x15b9')}},'resolve':{'whatsappQueue':['apiResolver',_0x54d3c5('0xf75'),function(_0x1d8bac,_0x2e4cf3){const _0x39f533=_0x54d3c5;return _0x1d8bac[_0x39f533('0x18af')](_0x39f533('0x1850'),{'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','id':_0x2e4cf3['id']});}],'userProfileSection':[_0x54d3c5('0x1fbc'),_0x54d3c5('0x21ef'),function(_0x776a7d,_0x3c85e1){const _0x268093=_0x54d3c5;return _0x776a7d[_0x268093('0x18af')](_0x268093('0xaf'),{'fields':_0x268093('0xe26'),'userProfileId':_0x3c85e1[_0x268093('0x26cd')]()[_0x268093('0xb86')],'sectionId':0x835});}]},'authenticate':!![],'permissionId':0x835,'bodyClass':_0x54d3c5('0x116e')})[_0x54d3c5('0x63f')](_0x54d3c5('0x317'),{'url':_0x54d3c5('0x17c9'),'views':{'content@app':{'templateUrl':_0x450957,'controller':_0x54d3c5('0x1413')}},'resolve':{'whatsappAccounts':[_0x54d3c5('0x1fbc'),_0x54d3c5('0x21ef'),function(_0xcc98a6,_0x5a5120){const _0x4331b0=_0x54d3c5;return _0x5a5120[_0x4331b0('0x1ac6')](_0x4331b0('0xa7c'))?_0xcc98a6[_0x4331b0('0x18af')](_0x4331b0('0x27bb'),{'fields':_0x4331b0('0x495'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0xcc98a6['resolve'](_0x4331b0('0x17c4'),{'id':_0x5a5120[_0x4331b0('0x26cd')]()[_0x4331b0('0xb86')],'section':_0x4331b0('0x171a'),'fields':'createdAt,updatedAt,id,name,key,ListId,remote,token,type,accountSid,authToken,phone,receiveUrl,deliveryReportUrl,notificationShake,notificationSound,notificationTemplate,queueTransfer,queueTransferTimeout,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,agentTransfer,agentTransferTimeout,description','sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':[_0x54d3c5('0x1fbc'),_0x54d3c5('0x21ef'),function(_0x134e4d,_0x17556c){const _0x2f36a0=_0x54d3c5;return _0x17556c[_0x2f36a0('0x1ac6')](_0x2f36a0('0xa7c'))?null:_0x134e4d[_0x2f36a0('0x18af')](_0x2f36a0('0x697'),{'fields':_0x2f36a0('0x686'),'id':_0x17556c[_0x2f36a0('0x26cd')]()[_0x2f36a0('0xb86')]});}],'userProfileSection':['apiResolver',_0x54d3c5('0x21ef'),function(_0x512c53,_0x27ca65){const _0x252b91=_0x54d3c5;return _0x27ca65[_0x252b91('0x1ac6')](_0x252b91('0xa7c'))?null:_0x512c53[_0x252b91('0x18af')](_0x252b91('0xaf'),{'fields':_0x252b91('0xe26'),'userProfileId':_0x27ca65['getCurrentUser']()[_0x252b91('0xb86')],'sectionId':0x836});}]},'authenticate':!![],'permissionId':0x836,'bodyClass':'whatsapp'})[_0x54d3c5('0x63f')]('app.whatsapp.whatsappAccounts.edit',{'url':_0x54d3c5('0x2233'),'params':{'whatsappAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x4fa553,'controller':_0x54d3c5('0x12b7')}},'resolve':{'whatsappAccount':[_0x54d3c5('0x1fbc'),_0x54d3c5('0xf75'),function(_0x52ba52,_0xa382d3){const _0x4e5e09=_0x54d3c5;return _0x52ba52[_0x4e5e09('0x18af')](_0x4e5e09('0x27bb'),{'fields':_0x4e5e09('0x495'),'id':_0xa382d3['id']});}],'userProfileSection':[_0x54d3c5('0x1fbc'),_0x54d3c5('0x21ef'),function(_0x285a68,_0x188cc8){const _0x5f3b11=_0x54d3c5;return _0x285a68[_0x5f3b11('0x18af')](_0x5f3b11('0xaf'),{'fields':_0x5f3b11('0xe26'),'userProfileId':_0x188cc8[_0x5f3b11('0x26cd')]()[_0x5f3b11('0xb86')],'sectionId':0x836});}]},'authenticate':!![],'permissionId':0x836,'bodyClass':_0x54d3c5('0x116e')}),_0x2bfa4b[_0x54d3c5('0x95e')]('app/main/apps/whatsapp');}angular[_0x36e6f4('0x896')](_0x36e6f4('0x13c3'),['ngCsv',_0x36e6f4('0xfb6'),_0x36e6f4('0x196c'),'flow',_0x36e6f4('0x107d'),_0x36e6f4('0x8e9'),_0x36e6f4('0x2749'),_0x36e6f4('0x22ee'),_0x36e6f4('0x2467'),_0x36e6f4('0x2819'),_0x36e6f4('0xe12'),_0x36e6f4('0x8f3'),_0x36e6f4('0x1a00'),'ngclipboard',_0x36e6f4('0x26fe'),_0x36e6f4('0x2870'),_0x36e6f4('0x8e5'),'material.components.expansionPanels','chart.js','angular.filter',_0x36e6f4('0x791')])['config'](_0x486e9c)[_0x36e6f4('0x75e')](_0x36e6f4('0x1305'),_0xe606e0)[_0x36e6f4('0x75e')](_0x36e6f4('0x1826'),_0x4c608b)['controller'](_0x36e6f4('0x1577'),_0x23ac3c)['controller'](_0x36e6f4('0xeb6'),_0x5e79d5)[_0x36e6f4('0x75e')](_0x36e6f4('0x97b'),_0x4bb52d)[_0x36e6f4('0x75e')](_0x36e6f4('0x9b0'),_0x178411)[_0x36e6f4('0x75e')]('EditWhatsappAccountAppcloseDialogController',_0x1ba77c)[_0x36e6f4('0x75e')]('EditWhatsappAccountAppdialogflowDialogController',_0x17c76e)['controller'](_0x36e6f4('0x268f'),_0x4720c3)[_0x36e6f4('0x75e')](_0x36e6f4('0x155'),_0x1b7f99)[_0x36e6f4('0x75e')](_0x36e6f4('0x895'),_0x5c8359)[_0x36e6f4('0x75e')](_0x36e6f4('0x1e7b'),_0x500d66)[_0x36e6f4('0x75e')]('EditWhatsappAccountAppqueueDialogController',_0x1247a1)['controller']('EditWhatsappAccountAppsystemDialogController',_0x4ea36f)[_0x36e6f4('0x75e')](_0x36e6f4('0x23ed'),_0x132db8)[_0x36e6f4('0x75e')](_0x36e6f4('0xc79'),_0x57ba21)['controller'](_0x36e6f4('0x1993'),_0x19ed16)[_0x36e6f4('0x75e')](_0x36e6f4('0xae9'),_0x503f66)['controller'](_0x36e6f4('0x16c2'),_0x30b941)[_0x36e6f4('0x75e')]('WhatsappAccountDispositionsController',_0xe7f703)[_0x36e6f4('0x75e')]('WhatsappAccountsController',_0x53f522)[_0x36e6f4('0x75e')]('CreateOrEditWhatsappQueueDialogController',_0x54b6dc)[_0x36e6f4('0x75e')](_0x36e6f4('0x644'),_0x3425eb)[_0x36e6f4('0x75e')]('WhatsappQueueteamaddController',_0x53c97e)[_0x36e6f4('0x75e')](_0x36e6f4('0x197a'),_0x1952c0)[_0x36e6f4('0x75e')]('WhatsappQueuesController',_0x49d7db);const _0x4c26de=_0x2734b2['p']+_0x36e6f4('0x1704'),_0x39d824=_0x2734b2['p']+_0x36e6f4('0x12e2'),_0xb78951=_0x2734b2['p']+'src/js/modules/core/layouts/content-with-toolbar.html/content-with-toolbar.html',_0x4288cf=_0x2734b2['p']+_0x36e6f4('0x179'),_0x29a6af=_0x2734b2['p']+_0x36e6f4('0x18e2'),_0x1fdd0a=_0x2734b2['p']+_0x36e6f4('0xa14'),_0x3edb26=_0x2734b2['p']+'src/js/modules/core/layouts/vertical-navigation.html/vertical-navigation.html';_0x3ab93b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0x1566'),_0x36e6f4('0x1bc6'),'$timeout',_0x36e6f4('0x19e3'),_0x36e6f4('0x21ef'),_0x36e6f4('0xf8a')];function _0x3ab93b(_0x41ca2c,_0x455cd2,_0x23fa25,_0x5f3fc3,_0x1bfea3,_0x165ddf,_0x982d93){const _0x26aafd=_0x36e6f4,_0x2f8d37=this;_0x2f8d37[_0x26aafd('0x7b8')]=![],_0x2f8d37[_0x26aafd('0xdf7')]=![],_0x2f8d37[_0x26aafd('0xf06')]=_0x1bfea3[_0x26aafd('0xf06')];function _0x31337f(){const _0x147549=_0x26aafd;if(_0x41ca2c['params'][_0x147549('0x1f67')]&&_0x41ca2c[_0x147549('0x23f')][_0x147549('0x1246')])return _0x165ddf[_0x147549('0x14ff')](),_0x2f8d37['progresslogin']=!![],_0x23fa25[_0x147549('0x1be2')](_0x147549('0x10b6'),_0x41ca2c[_0x147549('0x23f')][_0x147549('0x1f67')]),_0x1bfea3['user'][_0x147549('0xd83')]({'id':_0x41ca2c[_0x147549('0x23f')]['userId']})['$promise'][_0x147549('0x1166')](function(_0x504cf4){const _0x5426e6=_0x147549;_0x504cf4&&(_0x165ddf['setCurrentUser'](_0x504cf4),_0x41ca2c['go'](_0x5426e6('0x202e')));})['finally'](function(){const _0x2b58d8=_0x147549;_0x2f8d37[_0x2b58d8('0x7b8')]=![];});else _0x165ddf[_0x147549('0x225d')]()&&_0x41ca2c['go'](_0x147549('0x202e'));_0x2f8d37[_0x147549('0xdf7')]=_0x982d93[_0x147549('0xdf7')];}function _0x5ee8d3(){const _0x21a120=_0x26aafd;return _0x2f8d37['progresslogin']=!![],_0x2f8d37[_0x21a120('0x1e70')]='',_0x165ddf['login'](_0x2f8d37[_0x21a120('0x1bff')])[_0x21a120('0x1166')](function(){const _0x832e10=_0x21a120;return _0x41ca2c['go'](_0x832e10('0x202e'));})['catch'](function(_0x1d8d0e){const _0x568d92=_0x21a120;_0x2f8d37[_0x568d92('0x1e70')]=_0x1d8d0e[_0x568d92('0x25f4')]?_0x1d8d0e['data'][_0x568d92('0x1e70')]:_0x1d8d0e[_0x568d92('0x1e70')];})[_0x21a120('0x1951')](function(){const _0x40b029=_0x21a120;_0x2f8d37[_0x40b029('0x7b8')]=![];});}function _0xa18b41(_0x38b7d0){const _0x111148=_0x26aafd;_0x2f8d37[_0x111148('0x1e70')]='',_0x455cd2[_0x111148('0x246b')][_0x111148('0x14f9')]=_0x165ddf[_0x111148('0x9')](_0x38b7d0);}_0x2f8d37['login']=_0x5ee8d3,_0x2f8d37['loginOauth']=_0xa18b41,_0x2f8d37['onInit']=_0x31337f,_0x2f8d37[_0x26aafd('0xae0')]();}const _0x2a4960=_0x3ab93b;_0x589b81[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x589b81(_0x5def85,_0x2cec34){const _0x1c0d4=_0x36e6f4;_0x5def85[_0x1c0d4('0x63f')](_0x1c0d4('0xf5c'),{'url':'/login?token&userId','views':{'main@':{'templateUrl':_0x39d824,'controller':_0x1c0d4('0x1326')},'content@app.login':{'templateUrl':_0x4c26de,'controller':'LoginController\x20as\x20vm'}},'bodyClass':_0x1c0d4('0x1419')}),_0x2cec34['addPart']('app/login');}angular[_0x36e6f4('0x896')](_0x36e6f4('0xf5c'),[])['config'](_0x589b81)[_0x36e6f4('0x75e')](_0x36e6f4('0x1715'),_0x2a4960);const _0x22206c=_0x2734b2['p']+_0x36e6f4('0xb4d');_0x34fa5b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x21ef'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x586'),'$state',_0x36e6f4('0x19e3')];function _0x34fa5b(_0x4a8560,_0xcd8f66,_0x38168d,_0x318187,_0x52800e){const _0x3c4139=_0x36e6f4,_0x471229=this;_0x471229[_0x3c4139('0x1bff')]={},_0x471229[_0x3c4139('0xf06')]=_0x52800e['baseUrl'];function _0x523412(){const _0x90fb84=_0x3c4139;_0x4a8560[_0x90fb84('0x225d')]()&&_0x318187['go']('app.dashboards.general');}function _0x4dcac7(){const _0x2f649b=_0x3c4139;return _0x52800e[_0x2f649b('0x1667')][_0x2f649b('0x25dd')](_0x471229[_0x2f649b('0x1bff')])[_0x2f649b('0xa44')][_0x2f649b('0x1166')](function(){const _0x172bc7=_0x2f649b;_0xcd8f66[_0x172bc7('0x103b')]({'title':_0x38168d[_0x172bc7('0x25cc')](_0x172bc7('0x158f')),'msg':_0x38168d[_0x172bc7('0x25cc')](_0x172bc7('0x1101'))});})[_0x2f649b('0x1a80')](function(_0x591764){const _0x2007d1=_0x2f649b;_0x591764&&_0xcd8f66[_0x2007d1('0xfc9')]({'title':_0x38168d[_0x2007d1('0x25cc')](_0x2007d1('0x1601')),'msg':_0x591764['data']?_0x591764[_0x2007d1('0x25f4')][_0x2007d1('0x1e70')]||_0x591764[_0x2007d1('0x1e70')]||_0x591764:_0x591764['message']||_0x591764});});}_0x471229[_0x3c4139('0x250b')]=_0x4dcac7,_0x471229[_0x3c4139('0xae0')]=_0x523412;}const _0x370500=_0x34fa5b;_0x2dbdc1[_0x36e6f4('0x1294')]=['$stateProvider',_0x36e6f4('0x1562')];function _0x2dbdc1(_0x598ab4,_0x578d08){const _0xc2e310=_0x36e6f4;_0x598ab4[_0xc2e310('0x63f')](_0xc2e310('0x7be'),{'url':_0xc2e310('0x1a85'),'views':{'main@':{'templateUrl':_0x39d824,'controller':'MainController\x20as\x20vm'},'content@app.forgot':{'templateUrl':_0x22206c,'controller':_0xc2e310('0xbbe')}},'bodyClass':_0xc2e310('0x25dd')}),_0x578d08['addPart'](_0xc2e310('0x19a7'));}angular[_0x36e6f4('0x896')](_0x36e6f4('0x7be'),[])[_0x36e6f4('0xe11')](_0x2dbdc1)['controller'](_0x36e6f4('0x1872'),_0x370500);const _0x4d9b3f=_0x2734b2['p']+'src/js/modules/reset/reset.html/reset.html';_0x3e2464[_0x36e6f4('0x1294')]=[_0x36e6f4('0x21ef'),'toasty',_0x36e6f4('0x586'),_0x36e6f4('0x7b9'),_0x36e6f4('0x19e3'),'$stateParams'];function _0x3e2464(_0x180ca6,_0x591ee4,_0x463fd5,_0x50aae6,_0x189c2b,_0x4f971c){const _0x2ff88a=_0x36e6f4,_0x376161=this;_0x376161[_0x2ff88a('0x1bff')]={'token':_0x4f971c['token']},_0x376161[_0x2ff88a('0xf8a')]={},_0x376161[_0x2ff88a('0xf06')]=_0x189c2b[_0x2ff88a('0xf06')];function _0x22ded0(){const _0x19ac69=_0x2ff88a;return _0x180ca6[_0x19ac69('0x225d')]()&&_0x50aae6['go']('app.dashboards.general'),_0x189c2b['setting'][_0x19ac69('0x923')]({'id':0x1})['$promise'][_0x19ac69('0x1166')](function(_0xd38818){const _0x4b73cb=_0x19ac69;_0x376161['setting']=_0xd38818,_0x376161['passwordPattern']=_0x376161[_0x4b73cb('0xf8a')][_0x4b73cb('0x2798')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'';})[_0x19ac69('0x1a80')](function(_0x1b1ff8){const _0xbe24a4=_0x19ac69;_0x1b1ff8&&_0x591ee4[_0xbe24a4('0xfc9')]({'title':_0xbe24a4('0x1646'),'msg':_0x1b1ff8[_0xbe24a4('0x25f4')]?_0x1b1ff8[_0xbe24a4('0x25f4')][_0xbe24a4('0x1e70')]||_0x1b1ff8[_0xbe24a4('0x1e70')]||_0x1b1ff8:_0x1b1ff8['message']||_0x1b1ff8});});}function _0x26098a(){const _0x2a2c8b=_0x2ff88a;return _0x189c2b[_0x2a2c8b('0x1667')]['reset'](_0x376161['form'])[_0x2a2c8b('0xa44')][_0x2a2c8b('0x1166')](function(){const _0x73a7a=_0x2a2c8b;_0x591ee4[_0x73a7a('0x103b')]({'title':_0x463fd5[_0x73a7a('0x25cc')](_0x73a7a('0x22f')),'msg':_0x463fd5[_0x73a7a('0x25cc')]('RESETPASSWORD.PASSWORD_RESET_MESSAGE')}),_0x50aae6['go'](_0x73a7a('0xf5c'));})[_0x2a2c8b('0x1a80')](function(_0x108150){const _0x48696a=_0x2a2c8b;_0x108150&&_0x591ee4[_0x48696a('0xfc9')]({'title':_0x463fd5[_0x48696a('0x25cc')](_0x48696a('0x1745')),'msg':_0x108150['data']?_0x108150[_0x48696a('0x25f4')][_0x48696a('0x1e70')]||_0x108150[_0x48696a('0x1e70')]||_0x108150:_0x108150[_0x48696a('0x1e70')]||_0x108150});});}_0x376161[_0x2ff88a('0x175b')]=_0x26098a,_0x376161[_0x2ff88a('0xae0')]=_0x22ded0;}const _0x1baf3f=_0x3e2464;_0x3e1c70[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),'$translatePartialLoaderProvider'];function _0x3e1c70(_0x4bd11c,_0x51546e){const _0x1d428c=_0x36e6f4;_0x4bd11c['state']('app.reset',{'url':'/reset/:token','views':{'main@':{'templateUrl':_0x39d824,'controller':'MainController\x20as\x20vm'},'content@app.reset':{'templateUrl':_0x4d9b3f,'controller':_0x1d428c('0x400')}},'bodyClass':_0x1d428c('0x1aa')}),_0x51546e[_0x1d428c('0x95e')]('app/reset');}angular[_0x36e6f4('0x896')](_0x36e6f4('0x479'),[])[_0x36e6f4('0xe11')](_0x3e1c70)[_0x36e6f4('0x75e')](_0x36e6f4('0x1518'),_0x1baf3f);const _0x3029d0=_0x2734b2['p']+_0x36e6f4('0x6d3');_0x291202['$inject']=[_0x36e6f4('0x7b9'),_0x36e6f4('0x8da'),'$q',_0x36e6f4('0x770')];function _0x291202(_0x52b96d,_0x293db0,_0x5b8eb5,_0x4c6c76){const _0x25e062=_0x36e6f4,_0xf07013=this;function _0xb0529c(_0x5a5419){const _0x362b32=a0_0x3f2c;let _0x450dc5=[];const _0x62aa23=_0x4c6c76[_0x362b32('0x2584')](),_0x3bce75=_0x5b8eb5['defer']();for(let _0x10fc15=0x0;_0x10fc15<_0x62aa23['length'];_0x10fc15+=0x1){_0x62aa23[_0x10fc15]['uisref']&&_0x450dc5[_0x362b32('0x1514')](_0x62aa23[_0x10fc15]);}return _0x5a5419&&(_0x450dc5=_0x450dc5[_0x362b32('0x1c33')](function(_0x2d56fc){const _0x240d83=_0x362b32;if(_0x2d56fc[_0x240d83('0xcdc')][_0x240d83('0x2574')]()['includes'](_0x5a5419[_0x240d83('0x2574')]()))return!![];})),_0x293db0(function(){const _0x1e61a9=_0x362b32;_0x3bce75[_0x1e61a9('0x18af')](_0x450dc5);},0x3e8),_0x3bce75['promise'];}function _0x3f699f(_0x467205){const _0x5e8ed7=a0_0x3f2c;_0x467205[_0x5e8ed7('0x1c1c')]&&(_0x467205[_0x5e8ed7('0x1677')]?_0x52b96d['go'](_0x467205[_0x5e8ed7('0x63f')],_0x467205['stateParams']):_0x52b96d['go'](_0x467205['state']));}_0xf07013[_0x25e062('0xe07')]=_0xb0529c,_0xf07013[_0x25e062('0xf1b')]=_0x3f699f;}const _0x19e37f=_0x291202;_0x445a7a[_0x36e6f4('0x1294')]=[_0x36e6f4('0x259c'),_0x36e6f4('0x1562')];function _0x445a7a(_0x53c0d3,_0x57a5b8){const _0x3532bf=_0x36e6f4;_0x53c0d3[_0x3532bf('0x63f')](_0x3532bf('0x286e'),{'url':_0x3532bf('0xa55'),'views':{'main@':{'templateUrl':_0x39d824,'controller':_0x3532bf('0x1326')},'content@app.errors_error-404':{'templateUrl':_0x3029d0,'controller':_0x3532bf('0x28fe')}},'params':{'status':0x194,'statusText':'','data':{},'config':{}},'bodyClass':_0x3532bf('0xfb3')}),_0x57a5b8['addPart'](_0x3532bf('0xb39'));}angular[_0x36e6f4('0x896')](_0x36e6f4('0x20a2'),[])[_0x36e6f4('0xe11')](_0x445a7a)[_0x36e6f4('0x75e')](_0x36e6f4('0x6a6'),_0x19e37f);const _0x514cd7=_0x2734b2['p']+_0x36e6f4('0x39c');_0x1fd70d[_0x36e6f4('0x1294')]=[_0x36e6f4('0x7b9'),_0x36e6f4('0xd2a')];function _0x1fd70d(_0x2d3499,_0x45ece5){const _0x1428d5=_0x36e6f4,_0x4f1f48=this;function _0x29711f(){const _0x568e0e=a0_0x3f2c;_0x45ece5[_0x568e0e('0x1674')](_0x568e0e('0x395'),_0x4f1f48[_0x568e0e('0xfc9')])[_0x568e0e('0x1166')](function(_0x154dbd){const _0x45b9b6=_0x568e0e;_0x4f1f48[_0x45b9b6('0x20ba')]=!![],_0x154dbd[_0x45b9b6('0x25f4')]&&(_0x4f1f48[_0x45b9b6('0x1af3')]=_0x154dbd[_0x45b9b6('0x25f4')]['id']);},function(){const _0x2289fb=_0x568e0e;_0x4f1f48[_0x2289fb('0x20ba')]=![];});}_0x4f1f48[_0x1428d5('0x1af3')]='',_0x4f1f48[_0x1428d5('0x20ba')]=![],_0x4f1f48[_0x1428d5('0xfc9')]=_0x2d3499['params'],_0x4f1f48['sendReport']=_0x29711f;}const _0x1df775=_0x1fd70d;_0x40522a[_0x36e6f4('0x1294')]=['$stateProvider',_0x36e6f4('0x1562')];function _0x40522a(_0x100d35,_0x57b741){const _0x40c05d=_0x36e6f4;_0x100d35[_0x40c05d('0x63f')](_0x40c05d('0x1ff7'),{'url':_0x40c05d('0x1b64'),'views':{'main@':{'templateUrl':_0x39d824,'controller':'MainController\x20as\x20vm'},'content@app.errors_error-500':{'templateUrl':_0x514cd7,'controller':'Error500Controller\x20as\x20vm'}},'params':{'status':0x1f4,'statusText':'','data':{},'config':{}},'bodyClass':'error-500'}),_0x57b741['addPart'](_0x40c05d('0x59e'));}angular[_0x36e6f4('0x896')](_0x36e6f4('0x28fd'),[])[_0x36e6f4('0xe11')](_0x40522a)[_0x36e6f4('0x75e')](_0x36e6f4('0xc95'),_0x1df775);;angular[_0x36e6f4('0x896')](_0x36e6f4('0x2208'),[_0x36e6f4('0x20a2'),_0x36e6f4('0x28fd')]),_0x176ea2[_0x36e6f4('0x1294')]=[_0x36e6f4('0x1376')];function _0x176ea2(_0x485d38){const _0x365853=_0x36e6f4,_0xfe50da={};return _0xfe50da['baseUrl']=!![]?'api/':0x0,_0xfe50da[_0x365853('0x1667')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'auth/local',{},{'local':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1b62')},'forgot':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1340')},'reset':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x211d'),'params':{'token':_0x365853('0x2374')}},'user':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'auth/local/user/:token','params':{'token':_0x365853('0x2374')}},'google':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xbbd')}}),_0xfe50da[_0x365853('0xbf0')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xbf0')),_0xfe50da[_0x365853('0x13fa')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x13fa'),{},{'startMonitor':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'rpc/voice/channels/:uniqueid/mixmonitor','params':{'uniqueid':_0x365853('0x4a7')}},'stopMonitor':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x9a3'),'params':{'uniqueid':_0x365853('0x4a7')}},'getVoiceChannels':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0xfbc')},'getVoiceQueues':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x156e')},'getChatQueues':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x1dc9')},'getMailQueues':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x22ba')},'getSmsQueues':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x21d1')},'getWhatsappQueues':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'rpc/sms/queues'},'getOpenchannelQueues':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x5d1')},'getFaxQueues':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'rpc/fax/queues'},'getVoiceQueuesPreview':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x156')},'getVoiceQueuesChannels':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14a8')},'getVoiceQueuesChannel':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xb54')},'getVoiceQueuesChannelHangup':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1b34')},'getVoiceQueuesChannelRedirect':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x979')},'getOutbound':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'rpc/outbound'},'getOutboundChannels':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1')},'getAgents':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x152b')},'setAgentCapacity':{'method':_0x365853('0x1be2'),'url':_0xfe50da['baseUrl']+_0x365853('0xc18'),'params':{'id':_0x365853('0x43f')}},'getTelephones':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x62a')},'getTrunks':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x253e')},'getCampaigns':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'rpc/campaigns'},'getMailAccounts':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1b6a')},'getFaxAccounts':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x141a')},'getChatQueuesWaitingInteractions':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'rpc/chat/queues/waitinginteractions'},'getMailQueuesWaitingInteractions':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x469')},'getOpenchannelQueuesWaitingInteractions':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x1ff8')},'getOpenchannelQueuesIdWaitingInteractions':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1a0')},'getSmsQueuesWaitingInteractions':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0xcdf')},'getFaxQueuesWaitingInteractions':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xac4')},'getWhatsappQueuesWaitingInteractions':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xe39')},'mailQueueNotify':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x204e'),'params':{'id':'@id'}},'chatQueueNotify':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x56c'),'params':{'id':_0x365853('0x43f')}},'faxQueueNotify':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x268c'),'params':{'id':_0x365853('0x43f')}},'smsQueueNotify':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2706'),'params':{'id':_0x365853('0x43f')}},'openchannelQueueNotify':{'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0xf50'),'params':{'id':'@id'}},'agentNotify':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e33'),'params':{'id':_0x365853('0x43f')}}}),_0xfe50da[_0x365853('0x92e')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'version',{},{'fetch':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xa88')},'reset':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x28ef')},'pull':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2822')},'restart':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x27d6')},'migrations':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1685')}}),_0xfe50da['system']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1c2b'),{},{'killProcess':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x206b'),'params':{'pid':_0x365853('0x17b1')}}}),_0xfe50da[_0x365853('0x271e')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2809'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2'),'isArray':!![]}}),_0xfe50da['user']=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x1e5b'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e62')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/clone','params':{'includeAll':'@includeAll'}},'bulkCreate':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xbee'),'isArray':!![]},'addContacts':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x15ab')},'changePassword':{'isArray':![],'method':'put','url':_0xfe50da[_0x365853('0xf06')]+'users/:id/password'},'addQueues':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'users/:id/queues'},'removeQueues':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+'users/:id/queues'},'addAvatar':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x38c')},'getAvatar':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'users/:id/avatar'},'getContacts':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x15ab')},'getQueues':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1c6d')},'getVoiceQueuesRt':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x264e')},'getGroups':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x271b')},'getRecordings':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1821')},'getScreenRecordings':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x73')},'getChatInteractions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/chat/interactions'},'getOpenchannelInteractions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/openchannel/interactions'},'getMailInteractions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xe38')},'getSmsInteractions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/sms/interactions'},'getFaxInteractions':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x167e')},'getWhatsappInteractions':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'users/:id/whatsapp/interactions'},'login':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x74f')},'logout':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/logout'},'pause':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2645')},'unpause':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/unpause'},'getTeams':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'users/:id/teams'},'addTeams':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x247c')},'removeTeams':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/teams'},'getLists':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'users/:id/lists'},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2186')},'addChatInteractions':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x193e')},'removeChatInteractions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x193e')},'addMailInteractions':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x97e')},'removeMailInteractions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/mail_interactions'},'addFaxInteractions':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x161d')},'removeFaxInteractions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x161d')},'addSmsInteractions':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2122')},'removeSmsInteractions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/sms_interactions'},'addOpenchannelInteractions':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'users/:id/openchannel_interactions'},'removeOpenchannelInteractions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2460')},'addWhatsappInteractions':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1cbb')},'removeWhatsappInteractions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1cbb')},'getVoicePrefixes':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x107c')},'getFaxAccounts':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1218')},'addFaxAccounts':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1218')},'removeFaxAccounts':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1218')},'getMailAccounts':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/mail_accounts'},'addMailAccounts':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1842')},'removeMailAccounts':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1842')},'getOpenchannelAccounts':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x13e1')},'addOpenchannelAccounts':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x13e1')},'removeOpenchannelAccounts':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x13e1')},'getSmsAccounts':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x162d')},'addSmsAccounts':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/sms_accounts'},'removeSmsAccounts':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x162d')},'getChatWebsites':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1bbd')},'addChatWebsites':{'isArray':!![],'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0x1bbd')},'removeChatWebsites':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1bbd')},'getWhatsappAccounts':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x212a')},'addWhatsappAccounts':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x212a')},'removeWhatsappAccounts':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x212a')},'getSquareProjects':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x5cc')},'addSquareProjects':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x5cc')},'removeSquareProjects':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x5cc')},'getScheduledCalls':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'users/:id/scheduled_calls'},'getApiKey':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x278d')},'createApiKey':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x278d')},'removeApiKey':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x278d')},'whoami':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2623')}}),_0xfe50da[_0x365853('0x35c')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e78'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x18d1')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2529'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x23b1')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x2534'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x28be')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x973'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['voiceExtension']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x277b'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xadd')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'voice/extensions/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'addApplications':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1d4a')}}),_0xfe50da[_0x365853('0x8d3')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2586'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1686')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1bd6'),'params':{'includeAll':_0x365853('0x2281')}},'addSound':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1365')},'removeSound':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x1b74')},'getSounds':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1365')}}),_0xfe50da[_0x365853('0x1943')]=_0x485d38(_0xfe50da['baseUrl']+'voice/queues/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x25a6')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x802'),'params':{'includeAll':_0x365853('0x2281')}},'getHoppers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'voice/queues/:id/hoppers'},'getHopperHistories':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2649')},'getHopperFinals':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x7f9')},'getHopperBlacks':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1358')},'getTeams':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x55b')},'addTeams':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'voice/queues/:id/teams'},'removeTeams':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x55b')},'addAgents':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc40')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc40')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'voice/queues/:id/users'},'getMembers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x10b5')},'getLists':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'voice/queues/:id/lists'},'addLists':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xff0')},'removeLists':{'isArray':!![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0xff0')},'getBlackLists':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'voice/queues/:id/blacklists'},'addBlackLists':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1662')},'removeBlackLists':{'isArray':!![],'method':'delete','url':_0xfe50da['baseUrl']+'voice/queues/:id/blacklists'}}),_0xfe50da[_0x365853('0x1825')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2640'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x208f')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1a3e'),'params':{'includeAll':_0x365853('0x2281')}},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x241d'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x1f481c,_0x56013d){const _0x261792=_0x365853,_0x287f46=_0x56013d();return{'type':_0x287f46[_0x261792('0x1e1e')],'length':_0x287f46['content-length'],'buffer':_0x1f481c};}},'downloads':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'voice/recordings/:id/downloads'},'runTranscribe':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2440')},'downloadTranscribe':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2440'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x22b24e,_0x5869f4){const _0xc435d4=_0x365853,_0x4b3109=_0x5869f4();return{'type':_0x4b3109[_0xc435d4('0x1e1e')],'length':_0x4b3109[_0xc435d4('0x3bb')],'buffer':_0x22b24e};}}}),_0xfe50da['screenRecording']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'screen/recordings/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x157c')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x27dd'),'params':{'includeAll':_0x365853('0x2281')}},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'screen/recordings/:id/download','responseType':'arraybuffer','cache':![],'transformResponse':function(_0x262fc9,_0x587fb1){const _0x54051e=_0x587fb1();return{'type':_0x54051e['content-type'],'length':_0x54051e['content-length'],'buffer':_0x262fc9};}}}),_0xfe50da[_0x365853('0x8d4')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'voice/mails/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x257d')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x24c5'),'params':{'includeAll':_0x365853('0x2281')}},'getMessages':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x173e')}}),_0xfe50da['voiceMailMessage']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'voice/mails/messages/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'voice/mails/messages/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xbc'),'params':{'includeAll':_0x365853('0x2281')}},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'voice/mails/messages/:id/download','responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x2a30ee,_0x1fd030){const _0x2f4e67=_0x365853,_0x26da0b=_0x1fd030();return{'type':_0x26da0b[_0x2f4e67('0x1e1e')],'length':_0x26da0b['content-length'],'buffer':_0x2a30ee};}}}),_0xfe50da['voiceCallReport']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x6a4'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0xb8b')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14e8'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x21f9')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'voice/dials/reports/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'voice/dials/reports/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1037'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['voiceAgentReport']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e73'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x526')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2254'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1ede')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0xce4'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf7f')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x203a'),'params':{'includeAll':'@includeAll'}},'getVoiceQueuesReport':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xad8')}}),_0xfe50da[_0x365853('0x21d')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x2296'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f8c')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'members/reports/:id/clone','params':{'includeAll':'@includeAll'}}}),_0xfe50da['trunk']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x22ff'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x155f')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x2453'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1311')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f0c'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2257')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1874'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x222c')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd51'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x93c')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x31'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x21b9')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2579'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'mail/accounts/describe'},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'mail/accounts/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'addDisposition':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf6e')},'getDispositions':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf6e')},'removeDispositions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/accounts/:id/dispositions'},'addAnswer':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2e')},'getAnswers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2e')},'removeAnswers':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2e')},'getImap':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x144c')},'addImap':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x144c')},'removeImap':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x144c')},'getSmtp':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/accounts/:id/out_servers'},'addSmtp':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/accounts/:id/out_servers'},'removeSmtp':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+'mail/accounts/:id/out_servers'},'addInteraction':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x152')},'getInteractions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/accounts/:id/interactions'},'addApplications':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1070')},'getApplications':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1070')},'getMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x12bd')},'send':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'mail/accounts/:id/send'},'verifySmtp':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x6bf')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e65')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+'mail/accounts/:id/users'},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e65')}}),_0xfe50da['mailQueue']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x3a8'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'mail/queues/describe'},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'mail/queues/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'getMembers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e10')},'getTeams':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2662')},'addTeams':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2662')},'removeTeams':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2662')},'addAgents':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14bd')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/queues/:id/users'},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14bd')}}),_0xfe50da[_0x365853('0x1c44')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0xbf4'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'mail/substatuses/describe'},'clone':{'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0x107f'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x382')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2279'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x93b')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/interactions/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'addMessage':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x119a')},'getMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/interactions/:id/messages'},'addTags':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1a69')},'removeTags':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/interactions/:id/tags'},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1be5'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x4c42b7,_0x672094){const _0x2f8e06=_0x365853,_0x206307=_0x672094();return{'type':_0x206307[_0x2f8e06('0x1e1e')],'length':_0x206307[_0x2f8e06('0x3bb')],'buffer':_0x4c42b7};}}}),_0xfe50da[_0x365853('0x9d7')]=_0x485d38(_0xfe50da['baseUrl']+'mail/messages/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x177b')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd8e'),'params':{'includeAll':_0x365853('0x2281')}},'accept':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da['baseUrl']+_0x365853('0x15dc')},'reject':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/messages/:id/reject'},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0xab9'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x388a7a,_0x3d5c5a){const _0x1d9e62=_0x365853,_0x34563a=_0x3d5c5a();return{'type':_0x34563a[_0x1d9e62('0x1e1e')],'length':_0x34563a['content-length'],'buffer':_0x388a7a};}}}),_0xfe50da[_0x365853('0xa7f')]=_0x485d38(_0xfe50da['baseUrl']+'mail/applications/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x28a7')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2410'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x20a0')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x1c81'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x184c')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'mail/reports/queue/:id/clone','params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0xba2')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14fa'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x274b')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1b3a'),'params':{'includeAll':_0x365853('0x2281')}},'addItem':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'dashboards/:id/items'},'getItems':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x30e')}}),_0xfe50da[_0x365853('0x20ac')]=_0x485d38(_0xfe50da['baseUrl']+'dashboards/items/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x15cb')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'dashboards/items/:id/clone','params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['faxAccount']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'fax/accounts/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2751')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'fax/accounts/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'addDisposition':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x26dd')},'getDispositions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x26dd')},'removeDispositions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x26dd')},'addAnswer':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0xcdb')},'getAnswers':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0xcdb')},'removeAnswers':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xcdb')},'addInteraction':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'fax/accounts/:id/interactions'},'getInteractions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x7ef')},'addApplications':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x139a')},'getApplications':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x139a')},'addAccountApplications':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x21ad')},'updateAccountApplications':{'isArray':![],'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0x207e')},'getMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x278a')},'send':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1188')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x275f')},'removeAgents':{'isArray':![],'method':'delete','url':_0xfe50da['baseUrl']+_0x365853('0x275f')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x275f')}}),_0xfe50da[_0x365853('0x229d')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1054'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x258b')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'fax/applications/:id/clone','params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['faxInteraction']=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x1d95'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f7d')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2888'),'params':{'includeAll':_0x365853('0x2281')}},'addMessage':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2db')},'getMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2db')},'addTags':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0xa90')},'removeTags':{'isArray':![],'method':'delete','url':_0xfe50da['baseUrl']+_0x365853('0xa90')},'download':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x13b2'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x4c0bd5,_0x5881ea){const _0xc6f9d6=_0x5881ea();return{'type':_0xc6f9d6['content-type'],'length':_0xc6f9d6['content-length'],'buffer':_0x4c0bd5};}}}),_0xfe50da['faxMessage']=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x1e9e'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1ed4')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2858'),'params':{'includeAll':_0x365853('0x2281')}},'accept':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x164d')},'reject':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da['baseUrl']+_0x365853('0x28f1')},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'fax/messages/:id/download','responseType':'arraybuffer','cache':![],'transformResponse':function(_0x2c7c4d,_0x245755){const _0x200e6d=_0x365853,_0x4e7f92=_0x245755();return{'type':_0x4e7f92[_0x200e6d('0x1e1e')],'length':_0x4e7f92[_0x200e6d('0x3bb')],'buffer':_0x2c7c4d};}}}),_0xfe50da[_0x365853('0x1a5b')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'fax/queues/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x8fe')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x604'),'params':{'includeAll':_0x365853('0x2281')}},'getMembers':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+'fax/queues/:id/members'},'getTeams':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x5c7')},'addTeams':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x5c7')},'removeTeams':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x5c7')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'fax/queues/:id/users'},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f23')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'fax/queues/:id/users'}}),_0xfe50da[_0x365853('0xbf1')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x238c'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x19a6')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1a9e'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['smsAccount']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'sms/accounts/:id',{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0xd1c')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1c75'),'params':{'includeAll':_0x365853('0x2281')}},'addDisposition':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'sms/accounts/:id/dispositions'},'getDispositions':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x1721')},'removeDispositions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1721')},'addAnswer':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x302')},'getAnswers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x302')},'removeAnswers':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'sms/accounts/:id/canned_answers'},'notify':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x26af')},'addApplications':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'sms/accounts/:id/applications'},'getApplications':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0xf20')},'getInteractions':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+'sms/accounts/:id/interactions'},'send':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'sms/accounts/:id/send'},'status':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x86b')},'statusGet':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x86b')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1604')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1604')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1604')}}),_0xfe50da[_0x365853('0x190e')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'sms/applications/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1709')},'clone':{'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0x2202'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x14c3')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x1ab'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x10ba')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1dd2'),'params':{'includeAll':'@includeAll'}},'addMessage':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x2116')},'getMessages':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2116')},'addTags':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf9d')},'removeTags':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf9d')},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x82a'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x124be5,_0x50d5b8){const _0x215e65=_0x365853,_0x73addf=_0x50d5b8();return{'type':_0x73addf[_0x215e65('0x1e1e')],'length':_0x73addf[_0x215e65('0x3bb')],'buffer':_0x124be5};}}}),_0xfe50da['smsMessage']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x286c'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'sms/messages/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x244f'),'params':{'includeAll':_0x365853('0x2281')}},'accept':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da['baseUrl']+_0x365853('0xbf8')},'reject':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da[_0x365853('0xf06')]+'sms/messages/:id/reject'},'status':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x26d9')}}),_0xfe50da[_0x365853('0x73c')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0xe16'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1287')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xdbb'),'params':{'includeAll':_0x365853('0x2281')}},'getMembers':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xccb')},'getTeams':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x23cf')},'addTeams':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'sms/queues/:id/teams'},'removeTeams':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x23cf')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd50')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0xd50')},'getAgents':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd50')}}),_0xfe50da[_0x365853('0x77f')]=_0x485d38(_0xfe50da['baseUrl']+'openchannel/accounts/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'openchannel/accounts/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'openchannel/accounts/:id/clone','params':{'includeAll':'@includeAll'}},'addDisposition':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'openchannel/accounts/:id/dispositions'},'getDispositions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x574')},'removeDispositions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+'openchannel/accounts/:id/dispositions'},'addAnswer':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x23a9')},'getAnswers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'openchannel/accounts/:id/canned_answers'},'removeAnswers':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x23a9')},'notify':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x12dd')},'addApplications':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2314')},'getApplications':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x2314')},'getInteractions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x102f')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'openchannel/accounts/:id/users'},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x23de')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x23de')},'send':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x279e')}}),_0xfe50da['openchannelApplication']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xbc4'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1505')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x25b8'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x1b9e')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'openchannel/interactions/:id',{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc6b')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xed5'),'params':{'includeAll':_0x365853('0x2281')}},'addMessage':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x19e7')},'getMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'openchannel/interactions/:id/messages'},'addTags':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'openchannel/interactions/:id/tags'},'removeTags':{'isArray':![],'method':'delete','url':_0xfe50da['baseUrl']+_0x365853('0xd59')},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x336'),'responseType':'arraybuffer','cache':![],'transformResponse':function(_0x259b43,_0x249e4f){const _0x5718f2=_0x365853,_0x190667=_0x249e4f();return{'type':_0x190667[_0x5718f2('0x1e1e')],'length':_0x190667[_0x5718f2('0x3bb')],'buffer':_0x259b43};}}}),_0xfe50da['openchannelMessage']=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x2a3'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x47c')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'openchannel/messages/:id/clone','params':{'includeAll':'@includeAll'}},'accept':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2820')},'reject':{'isArray':![],'method':'put','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x216c')}}),_0xfe50da['openchannelQueue']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x626'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1538')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x620'),'params':{'includeAll':'@includeAll'}},'getMembers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'openchannel/queues/:id/members'},'getTeams':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf7')},'addTeams':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0xf7')},'removeTeams':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf7')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x126')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'openchannel/queues/:id/users'},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'openchannel/queues/:id/users'}}),_0xfe50da[_0x365853('0x1864')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'chat/websites/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'chat/websites/describe'},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1bd5'),'params':{'includeAll':_0x365853('0x2281')}},'addDisposition':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x365')},'getDispositions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x365')},'removeDispositions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/websites/:id/dispositions'},'addAnswer':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'chat/websites/:id/canned_answers'},'getAnswers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x3ab')},'removeAnswers':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x3ab')},'addLogo':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1cbe')},'addAvatar':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x235')},'addCustomerAvatar':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x159c')},'addSystemAvatar':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/websites/:id/system_avatar'},'getLogo':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x1cbe')},'getAvatar':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x235')},'getCustomerAvatar':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x159c')},'getSystemAvatar':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x5ac')},'notify':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x484')},'offline':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/websites/:id/offline'},'addInteraction':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x268')},'getInteractions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x268')},'getSnippet':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1ed5')},'addApplications':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1d4e')},'getApplications':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1d4e')},'addProactiveActions':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'chat/websites/:id/proactive_actions'},'getProactiveActions':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0xd47')},'getFields':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1b19')},'getOfflineMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1b25')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x10e7')},'removeAgents':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x10e7')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x10e7')}}),_0xfe50da[_0x365853('0x18a7')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'openchannel/reports/queue/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'openchannel/reports/queue/describe'},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'openchannel/reports/queue/:id/clone','params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x18dd')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'chat/applications/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x12dc')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'chat/applications/:id/clone','params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1162')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x20af'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x22a')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x26bc'),'params':{'includeAll':'@includeAll'}},'createVidaooSession':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x85c')},'customUpdate':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x172d')},'abandon':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x45c')},'attachmentUpload':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1d01')},'attachmentDownload':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1ce7')},'close':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x4d6')},'addMessage':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'chat/interactions/:id/messages'},'getMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x139d')},'getMyMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xdb5')},'addTags':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1a74')},'removeTags':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/interactions/:id/tags'},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x234c'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x391a78,_0x946d0a){const _0x8d2891=_0x365853,_0x14fef5=_0x946d0a();return{'type':_0x14fef5[_0x8d2891('0x1e1e')],'length':_0x14fef5[_0x8d2891('0x3bb')],'buffer':_0x391a78};}}}),_0xfe50da[_0x365853('0x1102')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'chat/messages/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xa0')},'clone':{'method':'post','url':_0xfe50da['baseUrl']+'chat/messages/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'accept':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/messages/:id/accept'},'reject':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/messages/:id/reject'}}),_0xfe50da[_0x365853('0x2213')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xa43'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/offline_messages/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2018'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['chatQueue']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x237b'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x16e6')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x160d'),'params':{'includeAll':_0x365853('0x2281')}},'getMembers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x9d0')},'getTeams':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/queues/:id/teams'},'addTeams':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x13bc')},'removeTeams':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/queues/:id/teams'},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x182a')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x182a')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x182a')}}),_0xfe50da[_0x365853('0x2183')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xb25'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x19c7')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1502'),'params':{'includeAll':_0x365853('0x2281')}},'getUnread':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x61f')},'addMembers':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1c31')},'getMembers':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+'chat/groups/:id/members'},'removeMembers':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1c31')},'addMessage':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc8e')},'getMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc8e')}}),_0xfe50da[_0x365853('0x1f2f')]=_0x485d38(_0xfe50da['baseUrl']+'chat/proactive_actions/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1c06')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x13d5'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0xc39')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'cm/companies/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x255b')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xebf'),'params':{'includeAll':'@includeAll'}},'addContacts':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x252e')},'getContacts':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'cm/companies/:id/contacts'}}),_0xfe50da[_0x365853('0x149e')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14c8'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'cm/contacts/describe'},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf74'),'params':{'includeAll':_0x365853('0x2281')}},'merge':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/contacts/merge'},'bulkCreate':{'isArray':![],'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0x29b')},'getTags':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x861')},'setTags':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/contacts/:id/tags'},'getHoppers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/contacts/:id/hoppers'},'getHopperHistories':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/contacts/:id/hopper_histories'},'getHopperFinals':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1ad0')},'getJscriptySessions':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x9c8')},'uploadCsv':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/contacts/csv'},'upload':{'isArray':![],'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0xd7d')},'import':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e4d')}}),_0xfe50da[_0x365853('0x256a')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x18ab'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x22b7')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'cm/hopper/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'getPreview':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf1d')},'getOpenContacts':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x24c0')}}),_0xfe50da['cmHopperBlack']=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x161e'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf11')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0xa5'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1806')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x40'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2146')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x158d'),'params':{'includeAll':_0x365853('0x2281')}},'countContactsQueueCampaignHopperFinal':{'isArray':!![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1a86')},'countContactsIvrCampaignHopperFinal':{'isArray':!![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1621')},'moveContactsQueueCampaignHopperFinal':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/hopper_final/voice/queue/moveContacts/:id'},'moveContactsIvrCampaignHopperFinal':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/hopper_final/voice/campaign/moveContacts/:id'},'checkContactHopper':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x19c5')}}),_0xfe50da[_0x365853('0x1a26')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'cm/hopper_history/:id',{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x202b')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x18ff'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['cmCustomField']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x15a3'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x2008')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2521'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x79f')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x1f14'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x248')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xdf0'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1ea0')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'automations/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'automations/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x218'),'params':{'includeAll':_0x365853('0x2281')}},'addConditions':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'automations/:id/conditions'},'getConditions':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x27de')},'addActions':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x106')},'getActions':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x106')}}),_0xfe50da[_0x365853('0x1b1f')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'canned_answers/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e6f')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x20b8'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x12e8')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x21ba'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da['baseUrl']+'dispositions/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x7c1'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['condition']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'conditions/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x240d')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x270b'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x277c')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x98b'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'intervals/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'intervals/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'addInterval':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf86')},'getIntervals':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf86')},'addIntervals':{'isArray':!![],'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0x393')}}),_0xfe50da['pause']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2209'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x2531')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2082'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['cdr']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f11'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14ea')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xa54'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['voiceQueuesLog']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1ae6'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x7bd')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1bee'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x892')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xcd3'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc6')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e82'),'params':{'includeAll':_0x365853('0x2281')}},'run':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xbcd')}}),_0xfe50da[_0x365853('0x960')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2041'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0xac8')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1ca7'),'params':{'includeAll':_0x365853('0x2281')}},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf99'),'responseType':'arraybuffer','cache':![],'transformResponse':function(_0x45650c,_0x5ae494){const _0x345793=_0x365853,_0x905bd=_0x5ae494();return{'type':_0x905bd['content-type'],'length':_0x905bd[_0x345793('0x3bb')],'buffer':_0x45650c};}},'delete':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2041')}}),_0xfe50da[_0x365853('0x1446')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1ed6'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x26cb')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1481'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['template']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f5f'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'templates/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'templates/:id/clone','params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0xe00')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x2303'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x524')},'clone':{'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0x5de'),'params':{'includeAll':_0x365853('0x2281')}},'addAllCondition':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1bfc')},'addAnyCondition':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x121f')},'getAllConditions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'triggers/:id/all_conditions'},'getAnyConditions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'triggers/:id/any_conditions'},'addAction':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x16d2')},'getActions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'triggers/:id/actions'}}),_0xfe50da[_0x365853('0x734')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x267c'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x206e')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'variables/:id/clone','params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x2742')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xe01'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x7e6')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/:id/clone','params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x709')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x6ce'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x801')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x22af'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1ff5')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x12fb'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1d03')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14d1'),'params':{'includeAll':_0x365853('0x2281')}},'preview':{'isArray':!![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'analytics/custom_reports/:id/preview'},'run':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x186c')},'query':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x105d')}}),_0xfe50da['analyticDefaultReport']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'analytics/default_reports/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x182b')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'analytics/default_reports/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'preview':{'isArray':!![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x21fd')},'run':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1a3f')},'query':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xe3f')}}),_0xfe50da['analyticExtractedReport']=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x240a'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'analytics/extracted_reports/describe'},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc36'),'params':{'includeAll':_0x365853('0x2281')}},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x273e'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x446c2c,_0x4be43e){const _0x51fcd3=_0x365853,_0x303948=_0x4be43e();return{'type':_0x303948[_0x51fcd3('0x1e1e')],'length':_0x303948[_0x51fcd3('0x3bb')],'buffer':_0x446c2c};}}}),_0xfe50da['analyticMetric']=_0x485d38(_0xfe50da['baseUrl']+'analytics/metrics/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x934')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'analytics/metrics/:id/clone','params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['analyticFieldReport']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x669'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xe3')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x191c'),'params':{'includeAll':_0x365853('0x2281')}},'bulkCreate':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x59f'),'isArray':!![]},'bulkDestroy':{'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xef8'),'isArray':!![]},'addFields':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'analytics/field_reports/:id/create_many'}}),_0xfe50da[_0x365853('0x7eb')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1d23'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x490')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'analytics/tree_reports/:id/clone','params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x164')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'integrations/salesforce/accounts/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x263d')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0xde1'),'params':{'includeAll':_0x365853('0x2281')}},'getConfigurations':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xe10')},'addConfiguration':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xe10')},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x21ca')}}),_0xfe50da[_0x365853('0xf04')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1911'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x116a')},'clone':{'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0x25c1'),'params':{'includeAll':'@includeAll'}},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2d8')},'getSubjects':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc01')},'getDescriptions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x156f')}}),_0xfe50da[_0x365853('0x18fb')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1ff9'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0xebd')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/salesforce/fields/:id/clone','params':{'includeAll':'@includeAll'}}}),_0xfe50da['intSugarcrmAccount']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x418'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x494')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd7f'),'params':{'includeAll':_0x365853('0x2281')}},'getConfigurations':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/sugarcrm/accounts/:id/configurations'},'addConfiguration':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2692')},'getFields':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x401')}}),_0xfe50da[_0x365853('0x1691')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x5b0'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2407')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'integrations/sugarcrm/configurations/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'integrations/sugarcrm/configurations/:id/fields'},'getSubjects':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'integrations/sugarcrm/configurations/:id/subjects'},'getDescriptions':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'integrations/sugarcrm/configurations/:id/descriptions'}}),_0xfe50da['intSugarcrmField']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x170d'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x188c')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x111f'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1db9')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14c0'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x2163')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x270d'),'params':{'includeAll':_0x365853('0x2281')}},'getConfigurations':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/desk/accounts/:id/configurations'},'addConfiguration':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1398')},'getFields':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x25a7')}}),_0xfe50da[_0x365853('0x1768')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x961'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x21b')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2774'),'params':{'includeAll':_0x365853('0x2281')}},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xab6')},'getSubjects':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc83')},'getDescriptions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0xe28')},'getTags':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1528')},'setTags':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1528')}}),_0xfe50da[_0x365853('0xf9b')]=_0x485d38(_0xfe50da['baseUrl']+'integrations/desk/fields/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x25ab')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x17fb'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['intZohoAccount']=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0xec'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x27c8')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc25'),'params':{'includeAll':'@includeAll'}},'getConfigurations':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/zoho/accounts/:id/configurations'},'addConfiguration':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf9f')},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'integrations/zoho/accounts/:id/fields'}}),_0xfe50da[_0x365853('0x57c')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x809'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/zoho/configurations/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x221'),'params':{'includeAll':_0x365853('0x2281')}},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xbc1')},'getSubjects':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2c')},'getDescriptions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1eb7')}}),_0xfe50da[_0x365853('0xf62')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1fad'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'integrations/zoho/fields/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/zoho/fields/:id/clone','params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x2290')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x1eb2'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x376')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x905'),'params':{'includeAll':_0x365853('0x2281')}},'getConfigurations':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x515')},'addConfiguration':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x515')},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x27ec')}}),_0xfe50da[_0x365853('0xaf9')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x255c'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x262a')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1d33'),'params':{'includeAll':'@includeAll'}},'getFields':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'integrations/zendesk/configurations/:id/fields'},'getSubjects':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x142e')},'getDescriptions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x112c')},'getTags':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2833')},'setTags':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/zendesk/configurations/:id/tags'}}),_0xfe50da[_0x365853('0x1a97')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'integrations/zendesk/fields/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x1353')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x27c3'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0xc1e')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x199e'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'integrations/freshdesk/accounts/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f59'),'params':{'includeAll':'@includeAll'}},'getConfigurations':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x24e9')},'addConfiguration':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x24e9')},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/freshdesk/accounts/:id/fields'}}),_0xfe50da[_0x365853('0x1fb1')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'integrations/freshdesk/configurations/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/freshdesk/configurations/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1fc9'),'params':{'includeAll':'@includeAll'}},'getFields':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1c63')},'getSubjects':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc0a')},'getDescriptions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf23')},'getTags':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/freshdesk/configurations/:id/tags'},'setTags':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1a10')}}),_0xfe50da[_0x365853('0x23f4')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x224f'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'integrations/freshdesk/fields/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/freshdesk/fields/:id/clone','params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['intVtigerAccount']=_0x485d38(_0xfe50da['baseUrl']+'integrations/vtiger/accounts/:id',{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x211f')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1795'),'params':{'includeAll':_0x365853('0x2281')}},'getConfigurations':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/vtiger/accounts/:id/configurations'},'addConfiguration':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x14f0')},'getFields':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x6c6')}}),_0xfe50da[_0x365853('0x2582')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x24e1'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x15e6')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'integrations/vtiger/configurations/:id/clone','params':{'includeAll':'@includeAll'}},'getFields':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x2ed')},'getSubjects':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1263')},'getDescriptions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x5fe')}}),_0xfe50da[_0x365853('0x9c5')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xccd'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1bea')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1e0'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x148b')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x290'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x8cd')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1fc'),'params':{'includeAll':_0x365853('0x2281')}},'getConfigurations':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'integrations/servicenow/accounts/:id/configurations'},'addConfiguration':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x538')},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1734')}}),_0xfe50da['intServicenowConfiguration']=_0x485d38(_0xfe50da['baseUrl']+'integrations/servicenow/configurations/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x8f1')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x19a'),'params':{'includeAll':_0x365853('0x2281')}},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/servicenow/configurations/:id/fields'},'getSubjects':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x30b')},'getDescriptions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf61')}}),_0xfe50da['intServicenowField']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1eea'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1898')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xcef'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x2176')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'integrations/dynamics365/accounts/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x735')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2575'),'params':{'includeAll':_0x365853('0x2281')}},'getConfigurations':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x12cc')},'addConfiguration':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x12cc')},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'integrations/dynamics365/accounts/:id/fields'}}),_0xfe50da['intDynamics365Configuration']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x288f'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1919')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'integrations/dynamics365/configurations/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x25ea')},'getSubjects':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'integrations/dynamics365/configurations/:id/subjects'},'getDescriptions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'integrations/dynamics365/configurations/:id/descriptions'}}),_0xfe50da[_0x365853('0x18bb')]=_0x485d38(_0xfe50da['baseUrl']+'integrations/dynamics365/fields/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xfdb')},'clone':{'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0xf2'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x11cd')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x438'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1509')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xe67'),'params':{'includeAll':_0x365853('0x2281')}},'getConfigurations':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+'integrations/freshsales/accounts/:id/configurations'},'addConfiguration':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x19c8')},'getFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x63a')}}),_0xfe50da['intFreshsalesConfiguration']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'integrations/freshsales/configurations/:id',{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0xbd9')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1495'),'params':{'includeAll':_0x365853('0x2281')}},'getSubjects':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x13a3')},'getDescriptions':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x188b')},'getFields':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1a28')}}),_0xfe50da[_0x365853('0x78b')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'integrations/freshsales/fields/:id',{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x21a7')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1b65'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x2638')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x266d'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x28b2')},'clone':{'method':'post','url':_0xfe50da['baseUrl']+_0x365853('0x2425'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x1029')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0xd09'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/reports/queue/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x136'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['chatInternalMessage']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'chat/internal/messages/:id',{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'chat/internal/messages/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x111'),'params':{'includeAll':_0x365853('0x2281')}},'getUsers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x168c')}}),_0xfe50da[_0x365853('0x228b')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xcb1'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2a')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x186b'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x816')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f0a'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x22c9')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1d1a'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x3ed')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0xd57'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x28ce')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x25d'),'params':{'includeAll':'@includeAll'}},'getQuestions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x92')}}),_0xfe50da[_0x365853('0xc8b')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x24b6'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xdcc')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'sms/reports/queue/:id/clone','params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0x25de')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x18e9'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1452')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x11fc'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da['squareReportDetail']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x15d8'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x10ac')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x99f'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x129b')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x281b'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x567')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'jscripty/projects/:id/clone','params':{'includeAll':'@includeAll'}},'getSessions':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'jscripty/projects/:id/sessions'},'getAnswers':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2369')},'getSummary':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'jscripty/projects/:id/summary','responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x52c3a5,_0xe40c07){const _0xa0bbd4=_0x365853,_0x26b023=_0xe40c07();return{'type':_0x26b023[_0xa0bbd4('0x1e1e')],'length':_0x26b023['content-length'],'buffer':_0x52c3a5};}}}),_0xfe50da[_0x365853('0xf8a')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f96'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x13a7')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0xa34'),'params':{'includeAll':_0x365853('0x2281')}},'addLogo':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'settings/:id/logo'},'addLogoLogin':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x19d3')},'getLogo':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'settings/:id/logo'},'getLogoLogin':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x19d3')},'gdpr':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0xc1a')},'addPreferred':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc62')},'getPreferred':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc62')},'addFavicon':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x939')},'getFavicon':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'settings/:id/favicon'}}),_0xfe50da[_0x365853('0xb7b')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x12ba'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x751')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'square/odbc/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'test':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1f90')}}),_0xfe50da[_0x365853('0x7e4')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x4e8'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1261')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x11db'),'params':{'includeAll':'@includeAll'}},'addUsers':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd4d')},'removeUsers':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd4d')},'getUsers':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd4d')}}),_0xfe50da[_0x365853('0x2720')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd4a'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x234b')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x274e'),'params':{'includeAll':_0x365853('0x2281')}},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x10a7'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x437ef7,_0x540d4f){const _0x1deea3=_0x365853,_0x2db8a4=_0x540d4f();return{'type':_0x2db8a4[_0x1deea3('0x1e1e')],'length':_0x2db8a4['content-length'],'buffer':_0x437ef7};}}}),_0xfe50da['squareMessage']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2570'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x803')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xcae'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1e37')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x281e'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xade')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'teams/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'getQueues':{'isArray':!![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x483')},'addQueues':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'teams/:id/queues'},'removeQueues':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x483')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e06')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x1e06')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1e06')}}),_0xfe50da[_0x365853('0x5c9')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x7b2'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'license/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x17c8'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0xb13')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd7e'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xcd0')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x256d'),'params':{'includeAll':'@includeAll'}},'getHoppers':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'campaigns/:id/hoppers'},'getHopperHistories':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x5')},'getHopperFinals':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'campaigns/:id/hopper_finals'},'getHopperBlacks':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x18b9')},'getLists':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'campaigns/:id/lists'},'addLists':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'campaigns/:id/lists'},'removeLists':{'isArray':!![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+'campaigns/:id/lists'},'getBlackLists':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x12ab')},'addBlackLists':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x12ab')},'removeBlackLists':{'isArray':!![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x12ab')}}),_0xfe50da[_0x365853('0x2726')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'migrations/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2904')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x298'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x21bc')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x267b'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x11d4')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x27ac'),'params':{'includeAll':'@includeAll'}},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd07'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0xc22b38,_0x117f2b){const _0x2eaa56=_0x365853,_0x17da8c=_0x117f2b();return{'type':_0x17da8c[_0x2eaa56('0x1e1e')],'length':_0x17da8c[_0x2eaa56('0x3bb')],'buffer':_0xc22b38};}}}),_0xfe50da[_0x365853('0xc0e')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xbcc'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'plugins/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1bc'),'params':{'includeAll':_0x365853('0x2281')}},'download':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2226'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x34883a,_0x3bdbda){const _0x5139af=_0x365853,_0x2803ad=_0x3bdbda();return{'type':_0x2803ad[_0x5139af('0x1e1e')],'length':_0x2803ad[_0x5139af('0x3bb')],'buffer':_0x34883a};}},'upload':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x188a')},'delete':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xbcc')},'webhookGet':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1105')},'webhookPost':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1105')}}),_0xfe50da['mailTransferReport']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xb75'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xba4')},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x20d4'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1567')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xa06'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x765')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x701'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x17e9')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x24dc'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1400')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x114f'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da['openchannelTransferReport']=_0x485d38(_0xfe50da['baseUrl']+'openchannel/reports/transfer/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x4fe')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1fa5'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da[_0x365853('0xee')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x421'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+'sms/reports/transfer/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x159'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0xdd9')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x27e8'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1c42')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'cm/lists/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'addDisposition':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/lists/:id/dispositions'},'getDispositions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2732')},'removeDispositions':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2732')},'addContacts':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'cm/lists/:id/contacts'},'getContacts':{'isArray':!![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/lists/:id/contacts'},'getContactsCsv':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x990'),'responseType':'arraybuffer','cache':![],'transformResponse':function(_0x227996,_0x5b3657){const _0x47b7f3=_0x365853,_0x24f660=_0x5b3657();return{'type':_0x24f660[_0x47b7f3('0x1e1e')],'length':_0x24f660['content-length'],'buffer':_0x227996};}},'addCustomField':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x2818')},'getCustomFields':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'cm/lists/:id/fields'},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf46')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf46')},'getAgents':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf46')}}),_0xfe50da[_0x365853('0x1d96')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2ee'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xed9')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x10fe'),'params':{'includeAll':_0x365853('0x2281')}},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1e2a')},'removeAgents':{'isArray':![],'method':'delete','url':_0xfe50da['baseUrl']+'voice/prefixes/:id/users'},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1e2a')}}),_0xfe50da['userProfile']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1b32'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2300')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'userProfiles/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'addSections':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x15a4')},'removeSections':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+_0x365853('0x15a4')},'getSections':{'isArray':!![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x15a4')},'addResources':{'isArray':!![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x10d9')},'removeResources':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x10d9')},'getResources':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x10d9')}}),_0xfe50da['userProfileSection']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'userProfile/sections/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x77e')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x273d'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da['userProfileResource']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'userProfile/resources/:id',{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x126b')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'userProfile/resources/:id/clone','params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x10b3')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc53'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'notifications/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0xaa7'),'params':{'includeAll':_0x365853('0x2281')}},'sendNotification':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2850')}}),_0xfe50da[_0x365853('0xcc5')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'whatsapp/accounts/:id',{'id':'@id'},{'update':{'method':'put'},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+'whatsapp/accounts/describe'},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x27b3'),'params':{'includeAll':_0x365853('0x2281')}},'addDisposition':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'whatsapp/accounts/:id/dispositions'},'getDispositions':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2355')},'removeDispositions':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x2355')},'addAnswer':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x100b')},'getAnswers':{'isArray':![],'method':'get','url':_0xfe50da['baseUrl']+_0x365853('0x100b')},'removeAnswers':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da['baseUrl']+'whatsapp/accounts/:id/canned_answers'},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+'whatsapp/accounts/:id/users'},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc1f')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xc1f')},'addApplications':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x399')},'getApplications':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x399')},'notify':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1c3')},'send':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1409')}}),_0xfe50da[_0x365853('0x27b6')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+'whatsapp/applications/:id',{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1138')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x84f'),'params':{'includeAll':'@includeAll'}}}),_0xfe50da['whatsappInteraction']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x259'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'whatsapp/interactions/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x101e'),'params':{'includeAll':_0x365853('0x2281')}},'addMessage':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x1b28')},'getMessages':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0x1b28')},'addTags':{'isArray':![],'method':'post','url':_0xfe50da[_0x365853('0xf06')]+'whatsapp/interactions/:id/tags'},'removeTags':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x136f')},'download':{'isArray':![],'method':'get','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xd98'),'responseType':_0x365853('0x17ac'),'cache':![],'transformResponse':function(_0x359779,_0x26e51d){const _0x2c7523=_0x365853,_0x4ee44f=_0x26e51d();return{'type':_0x4ee44f[_0x2c7523('0x1e1e')],'length':_0x4ee44f[_0x2c7523('0x3bb')],'buffer':_0x359779};}}}),_0xfe50da[_0x365853('0x101f')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x4d'),{'id':_0x365853('0x43f')},{'update':{'method':'put'},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'whatsapp/messages/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+'whatsapp/messages/:id/clone','params':{'includeAll':_0x365853('0x2281')}},'accept':{'isArray':![],'method':'put','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x179d')},'reject':{'isArray':![],'method':_0x365853('0x1be2'),'url':_0xfe50da['baseUrl']+_0x365853('0x1346')},'status':{'isArray':![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x1b72')}}),_0xfe50da['whatsappQueueReport']=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x188e'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x917')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xeb2'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x2852')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x23dc'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x47')},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0x314'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da[_0x365853('0x1bb6')]=_0x485d38(_0xfe50da[_0x365853('0xf06')]+_0x365853('0x11b8'),{'id':_0x365853('0x43f')},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'whatsapp/queues/describe'},'clone':{'method':'post','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xf42'),'params':{'includeAll':_0x365853('0x2281')}},'getMembers':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x8b6')},'getTeams':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da['baseUrl']+_0x365853('0xa23')},'addTeams':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da['baseUrl']+_0x365853('0xa23')},'removeTeams':{'isArray':![],'method':'delete','url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xa23')},'addAgents':{'isArray':!![],'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x4d1')},'removeAgents':{'isArray':![],'method':_0x365853('0x906'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x4d1')},'getAgents':{'isArray':![],'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0x4d1')}}),_0xfe50da[_0x365853('0x16c6')]=_0x485d38(_0xfe50da['baseUrl']+_0x365853('0x560'),{'id':'@id'},{'update':{'method':_0x365853('0x1be2')},'describe':{'method':_0x365853('0xd83'),'url':_0xfe50da[_0x365853('0xf06')]+'cloudProviders/describe'},'clone':{'method':_0x365853('0x1674'),'url':_0xfe50da[_0x365853('0xf06')]+_0x365853('0xaa1'),'params':{'includeAll':_0x365853('0x2281')}}}),_0xfe50da;}const _0x59813b=_0x176ea2;_0x22e213[_0x36e6f4('0x1294')]=[_0x36e6f4('0x37'),'toastyConfigProvider'];function _0x22e213(_0x527e8e,_0x1644af){const _0x1092d8=_0x36e6f4;_0x1644af[_0x1092d8('0x3ef')]({'position':'top-right','sound':![],'html':!![],'theme':_0x1092d8('0x252')}),_0x527e8e[_0x1092d8('0xeef')](_0x1092d8('0xb12'),{'urlTemplate':_0x1092d8('0x1357')}),_0x527e8e['preferredLanguage']('en'),_0x527e8e['useSanitizeValueStrategy'](null);}const _0x3455c1=_0x22e213;_0xd1904b[_0x36e6f4('0x1294')]=[_0x36e6f4('0x3af'),_0x36e6f4('0x586'),_0x36e6f4('0x1bc6'),_0x36e6f4('0x19e3'),_0x36e6f4('0x1d2e')];function _0xd1904b(_0x4d145c,_0x1fe6a2,_0x51fbf7,_0x370014,_0xc94703){const _0x590ea4=_0x36e6f4,_0x9668b2=this;_0x9668b2[_0x590ea4('0xfd')]=_0x4d145c[_0x590ea4('0xfd')],_0x9668b2['direction']=_0x590ea4('0x132');const _0x286961=['ar','fa','he'],_0x222a42=_0x51fbf7['get'](_0x590ea4('0x27e7'));_0x222a42&&(_0x1fe6a2[_0x590ea4('0xc54')](_0x222a42),_0x286961[_0x590ea4('0x2379')](_0x222a42)>=0x0&&_0x370014[_0x590ea4('0xf8a')][_0x590ea4('0xd83')]({'id':0x1})[_0x590ea4('0xa44')][_0x590ea4('0x1166')](function(_0x12f720){const _0x207d43=_0x590ea4;_0x12f720&&_0x12f720[_0x207d43('0x6e4')]&&(_0x9668b2[_0x207d43('0x2788')]=_0x207d43('0x1c92'));})[_0x590ea4('0x1a80')](function(_0x30a75c){const _0x515327=_0x590ea4;_0x30a75c&&_0xc94703[_0x515327('0xfc9')]({'title':_0x515327('0x1646'),'msg':_0x30a75c[_0x515327('0x25f4')]?_0x30a75c[_0x515327('0x25f4')][_0x515327('0x1e70')]||_0x30a75c['message']||_0x30a75c:_0x30a75c[_0x515327('0x1e70')]||_0x30a75c});}));}const _0x11cf39=_0xd1904b;_0x334252[_0x36e6f4('0x1294')]=[_0x36e6f4('0x586')],_0x18c060[_0x36e6f4('0x1294')]=[_0x36e6f4('0x18bc'),_0x36e6f4('0x586')];function _0x18c060(_0x4b14d9,_0x126b9d){return function(_0x53d7f3){const _0x171ecb=a0_0x3f2c,_0x2aeedd=new Date(),_0x413831=new Date(_0x53d7f3);if(_0x413831[_0x171ecb('0xba8')]()===_0x2aeedd[_0x171ecb('0xba8')]()&&_0x413831['getMonth']()===_0x2aeedd[_0x171ecb('0xd60')]()&&_0x413831[_0x171ecb('0x1e4f')]()===_0x2aeedd[_0x171ecb('0x1e4f')]())return _0x4b14d9(_0x171ecb('0x1643'))(_0x413831['getTime'](),'shortTime');if(_0x413831[_0x171ecb('0xba8')]()===_0x2aeedd[_0x171ecb('0xba8')]()-0x1&&_0x413831[_0x171ecb('0xd60')]()===_0x2aeedd['getMonth']()&&_0x413831[_0x171ecb('0x1e4f')]()===_0x2aeedd[_0x171ecb('0x1e4f')]())return _0x126b9d['instant'](_0x171ecb('0x349'))+'\x20'+_0x4b14d9('date')(_0x413831[_0x171ecb('0x5cd')](),_0x171ecb('0x1bdc'));return _0x4b14d9(_0x171ecb('0x1643'))(_0x413831[_0x171ecb('0x5cd')](),'MMM\x20d,\x20y\x20h:mm\x20a');};}function _0x24ac73(){return function(_0x12436b,_0xe3d937,_0x2b66f5){const _0x4983e0={};let _0x43fa69=0x0,_0x34f936;for(_0x34f936 in _0x12436b){_0x43fa69>=_0x2b66f5&&(_0x4983e0[_0x34f936]=_0x12436b[_0x34f936]);if(++_0x43fa69===_0x2b66f5+_0xe3d937)break;}return _0x4983e0;};}function _0x40f423(){const _0x40d6fa=_0x36e6f4,_0x59d12c=[{'value':'jan'},{'value':_0x40d6fa('0x28ae')},{'value':_0x40d6fa('0x105')},{'value':_0x40d6fa('0x1d')},{'value':'may'},{'value':_0x40d6fa('0x2098')},{'value':_0x40d6fa('0x3d4')},{'value':'aug'},{'value':_0x40d6fa('0x1d25')},{'value':_0x40d6fa('0x217c')},{'value':_0x40d6fa('0xb98')},{'value':_0x40d6fa('0x236a')}],_0xd3de1=[{'value':'1'},{'value':'2'},{'value':'3'},{'value':'4'},{'value':'5'},{'value':'6'},{'value':'7'},{'value':'8'},{'value':'9'},{'value':'10'},{'value':'11'},{'value':'12'}],_0x57eb62=[{'value':'mon'},{'value':_0x40d6fa('0x1444')},{'value':_0x40d6fa('0xd53')},{'value':_0x40d6fa('0x108c')},{'value':_0x40d6fa('0xf')},{'value':'sat'},{'value':_0x40d6fa('0x75f')}],_0x4abc0f=[0x1,0x2,0x3,0x4,0x5,0x6,0x7,0x8,0x9,0xa,0xb,0xc,0xd,0xe,0xf,0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f];return{'getMonthName':function(){return _0x59d12c;},'getMonthNumber':function(){return _0xd3de1;},'getDaysOfWeek':function(){return _0x57eb62;},'getDaysOfMonth':function(){return _0x4abc0f;}};}function _0x334252(_0x5992c4){const _0x14f8e6=_0x36e6f4;return{'Today':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0xec5')),'Yesterday':_0x5992c4['instant'](_0x14f8e6('0x349')),'This\x20Week':_0x5992c4['instant'](_0x14f8e6('0x1743')),'Last\x20Week':_0x5992c4['instant'](_0x14f8e6('0xcd8')),'This\x20Month':_0x5992c4['instant']('DASHBOARDS.THIS_MONTH'),'Last\x20Month':_0x5992c4[_0x14f8e6('0x25cc')]('DASHBOARDS.LAST_MONTH'),'This\x20Year':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x2431')),'Last\x20Year':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0xe79')),'January':_0x5992c4['instant'](_0x14f8e6('0x9db')),'February':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x1eb9')),'March':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x2792')),'April':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x272a')),'May':_0x5992c4[_0x14f8e6('0x25cc')]('DASHBOARDS.MAY'),'June':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x10c4')),'July':_0x5992c4['instant']('DASHBOARDS.JULY'),'August':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x278')),'September':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x642')),'October':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x1331')),'November':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x2164')),'December':_0x5992c4['instant'](_0x14f8e6('0x2151')),'Mon':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x81b')),'Tue':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x616')),'Wed':_0x5992c4['instant']('DASHBOARDS.WED'),'Thu':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x1fb5')),'Fri':_0x5992c4['instant'](_0x14f8e6('0xcc6')),'Sat':_0x5992c4[_0x14f8e6('0x25cc')](_0x14f8e6('0x13c6')),'Sun':_0x5992c4[_0x14f8e6('0x25cc')]('DASHBOARDS.SUN')};}function _0x161677(){return{'enqueue':function(_0x4afb67){const _0x49f0cd=a0_0x3f2c;this[_0x49f0cd('0x1e9f')]=this[_0x49f0cd('0x1e9f')]?this[_0x49f0cd('0x1e9f')]['finally'](_0x4afb67):_0x4afb67();}};}const _0x200158=_0x2734b2['p']+_0x36e6f4('0x920'),_0x3263d9=_0x2734b2['p']+_0x36e6f4('0x25a8'),_0x4b6e75=_0x2734b2['p']+'src/js/modules/navigation/layouts/vertical-navigation/navigation.html/navigation.html',_0x330ca0=_0x2734b2['p']+'src/js/modules/navigation/layouts/vertical-navigation-fullwidth-toolbar-2/navigation.html/navigation.html',_0x4f4dc8=_0x2734b2['p']+_0x36e6f4('0xc92'),_0x3d18cb=_0x2734b2['p']+_0x36e6f4('0x23a6'),_0x4b8c28=_0x2734b2['p']+_0x36e6f4('0x1a58');_0x3db1ea[_0x36e6f4('0x1294')]=['$stateProvider',_0x36e6f4('0x24b9'),_0x36e6f4('0x2334')];function _0x3db1ea(_0x4f1e80,_0x5632b5,_0x409dd8){const _0x52dfe2=_0x36e6f4;_0x409dd8[_0x52dfe2('0x1a11')](!![]),_0x5632b5[_0x52dfe2('0x52e')](_0x52dfe2('0x239'));let _0x4f5a6c;angular[_0x52dfe2('0x4ed')](['ngCookies'])['invoke'](['$cookies',function(_0xe42a03){_0x4f5a6c=_0xe42a03;}]);const _0x1c28f2=_0x4f5a6c[_0x52dfe2('0xd83')](_0x52dfe2('0x1aa4'))||'verticalNavigation',_0x5d8ecd={'verticalNavigation':{'main':_0x3edb26,'toolbar':_0x200158,'navigation':_0x4b6e75,'header':_0x4f4dc8,'footer':_0x3d18cb},'verticalNavigationFullwidthToolbar':{'main':_0x1fdd0a,'toolbar':'','navigation':_0x4b6e75},'verticalNavigationFullwidthToolbar2':{'main':_0x29a6af,'toolbar':'','navigation':_0x330ca0},'horizontalNavigation':{'main':_0x4288cf,'toolbar':'','navigation':_0x3263d9},'contentOnly':{'main':_0x39d824,'toolbar':'','navigation':''},'contentWithToolbar':{'main':_0xb78951,'toolbar':'','navigation':''}};_0x4f1e80[_0x52dfe2('0x63f')](_0x52dfe2('0x746'),{'abstract':!![],'views':{'main@':{'templateUrl':_0x5d8ecd[_0x1c28f2]['main'],'controller':_0x52dfe2('0x1326')},'toolbar@app':{'templateUrl':_0x5d8ecd[_0x1c28f2][_0x52dfe2('0x25be')],'controller':_0x52dfe2('0x2368')},'navigation@app':{'templateUrl':_0x5d8ecd[_0x1c28f2][_0x52dfe2('0x15ea')],'controller':_0x52dfe2('0x593')},'quickPanel@app':{'templateUrl':_0x4b8c28,'controller':'QuickPanelController\x20as\x20vm'},'header@app':{'templateUrl':_0x5d8ecd[_0x1c28f2][_0x52dfe2('0x28b9')],'controller':_0x52dfe2('0xf89')},'footer@app':{'templateUrl':_0x5d8ecd[_0x1c28f2][_0x52dfe2('0xd21')],'controller':_0x52dfe2('0x206f')}},'resolve':{'license':[_0x52dfe2('0x1fbc'),function(_0x191f46){const _0x12b56e=_0x52dfe2;return _0x191f46[_0x12b56e('0x18af')](_0x12b56e('0x240b'));}],'setting':[_0x52dfe2('0x1fbc'),function(_0x265b68){const _0x1a6eff=_0x52dfe2;return _0x265b68[_0x1a6eff('0x18af')](_0x1a6eff('0xa4d'),{'id':0x1});}]}});}const _0x361149=_0x3db1ea;_0x524f30['$inject']=[_0x36e6f4('0x66d'),_0x36e6f4('0xc90')];function _0x524f30(_0x576cd0,_0x3b3080){const _0xe4fb4e=_0x36e6f4;_0x576cd0[_0xe4fb4e('0x11c6')]({},_0x3b3080[_0xe4fb4e('0x157d')]),_0x576cd0[_0xe4fb4e('0x1705')]({},_0x3b3080[_0xe4fb4e('0x910')]);}const _0x2c9654=_0x524f30;var _0x2caff9=_0x2734b2(0x15ef);_0x66ceaf['$inject']=[_0x36e6f4('0x1cab'),_0x36e6f4('0x21ef')];function _0x66ceaf(_0x4f58cd,_0x3bb520){let _0x450941;function _0x2c0c5f(){const _0x175c43=a0_0x3f2c,_0x2898be=!![]?window['io']:0x0,_0x43cf55={'query':_0x175c43('0x269e')+_0x3bb520[_0x175c43('0x26cd')]()['id'],'transports':[_0x175c43('0x239f'),_0x175c43('0x22e3')]};_0x450941=!![]?_0x2898be(_0x43cf55):0x0;}return{'connect':_0x2c0c5f,'on':function(_0x3cacae,_0x5d55c5){const _0x31ecd2=a0_0x3f2c;_0x5d55c5=_0x5d55c5||angular[_0x31ecd2('0x2652')],!_0x450941&&_0x2c0c5f(),_0x450941['on'](_0x3cacae,function(){const _0x20f027=_0x31ecd2,_0x42845c=arguments;_0x4f58cd[_0x20f027('0x19d6')](function(){const _0x4cce3f=_0x20f027;_0x5d55c5[_0x4cce3f('0x1343')](_0x450941,_0x42845c);});});},'onWithoutApply':function(_0x25284f,_0x128b7c){_0x128b7c=_0x128b7c||angular['noop'],!_0x450941&&_0x2c0c5f(),_0x450941['on'](_0x25284f,function(){const _0x1b25dc=a0_0x3f2c;_0x128b7c[_0x1b25dc('0x1343')](_0x450941,arguments);});},'emit':function(_0x4a0e6f,_0x189fc2,_0x531bdf){const _0x392029=a0_0x3f2c;_0x531bdf=_0x531bdf||angular[_0x392029('0x2652')],!_0x450941&&_0x2c0c5f(),_0x450941[_0x392029('0x230b')](_0x4a0e6f,_0x189fc2,function(){const _0xcc68dd=_0x392029,_0x5aeece=arguments;_0x4f58cd[_0xcc68dd('0x19d6')](function(){const _0x1647f3=_0xcc68dd;_0x531bdf[_0x1647f3('0x1343')](_0x450941,_0x5aeece);});});},'removeAllListeners':function(_0x39f09d){const _0x2aac15=a0_0x3f2c;!_0x450941&&_0x2c0c5f(),_0x450941[_0x2aac15('0x1800')](_0x39f09d);},'removeListener':function(_0xb20c84,_0x3b85d9){const _0x197444=a0_0x3f2c;!_0x450941&&_0x2c0c5f(),_0x450941[_0x197444('0x2755')](_0xb20c84,_0x3b85d9);},'disconnect':function(){const _0xe93ef=a0_0x3f2c;!_0x450941&&_0x2c0c5f(),_0x450941[_0xe93ef('0x670')]();}};}const _0x2e80d7=_0x66ceaf;_0x986f36[_0x36e6f4('0x1294')]=[_0x36e6f4('0x36f'),_0x36e6f4('0x1cab'),'$translate',_0x36e6f4('0x770'),_0x36e6f4('0x2256'),_0x36e6f4('0x21ef'),_0x36e6f4('0x1d2e'),_0x36e6f4('0x5c9'),'api',_0x36e6f4('0xf8a')];function _0x986f36(_0x49b6a2,_0x563b46,_0x39c0d9,_0x1e9ce2,_0x20ad22,_0x3fb6fe,_0x397a3d,_0x2e643c,_0x368e5b,_0x541544){const _0x295808=_0x36e6f4,_0x4c0955=this;_0x397a3d[_0x295808('0x1657')]();function _0x192702(){const _0x1027c4=_0x295808;return _0x3fb6fe[_0x1027c4('0x26cd')]()&&_0x3fb6fe[_0x1027c4('0x1ac6')]('agent');}_0x4c0955[_0x295808('0x1d6f')]=_0x192702;function _0x41b916(_0x6a9e38,_0xbd2521){const _0x308b16=_0x295808;return{'id':_0x6a9e38,'title':_0xbd2521['name']||_0x308b16('0xaf2'),'state':_0x308b16('0x20d7'),'stateParams':_0xbd2521,'weight':0x2,'hidden':function(){const _0xa6e55b=_0x308b16;return _0x3fb6fe[_0xa6e55b('0x1ac6')](_0xa6e55b('0x1eff'))||!_0x3fb6fe[_0xa6e55b('0x1167')](_0x6a9e38)&&!_0x3fb6fe['hasRole'](_0xa6e55b('0xa7c'));}};}function _0x2959eb(_0x2499bc,_0x105793){const _0x318062=_0x295808;return{'id':_0x2499bc,'title':_0x105793[_0x318062('0x4f0')]||_0x318062('0xaf2'),'state':_0x318062('0x1159'),'stateParams':_0x105793,'weight':0x2,'hidden':function(){const _0x189736=_0x318062;return _0x3fb6fe[_0x189736('0x1ac6')](_0x189736('0x1eff'))||!_0x3fb6fe['hasPermission'](_0x2499bc)&&!_0x3fb6fe[_0x189736('0x1ac6')]('admin');}};}function _0x5923a5(_0x93d837,_0x5b422e){const _0x1aa584=_0x295808,_0x3b4b73={'user':_0x2cfb05()[_0x1aa584('0x1a08')](_0x3fb6fe[_0x1aa584('0x26cd')](),['id',_0x1aa584('0x4f0'),_0x1aa584('0x6e1'),_0x1aa584('0x66f'),_0x1aa584('0x1e75'),_0x1aa584('0x1eef'),'interface'])};_0x5b422e[_0x1aa584('0x86')]=_0x5f0cec()[_0x1aa584('0x26a1')](_0x5b422e[_0x1aa584('0x86')],_0x3b4b73),_0x20ad22[_0x1aa584('0x13b8')](_0x1aa584('0x19d7')+_0x93d837,{'id':_0x93d837,'title':_0x5b422e[_0x1aa584('0x4f0')],'translate':_0x5b422e[_0x1aa584('0x4f0')],'state':_0x1aa584('0x3d7')+_0x5b422e['id'],'stateParams':_0x5b422e,'view':_0x1aa584('0xc0e'),'icon':_0x5b422e[_0x1aa584('0x1865')],'weight':0xc,'hidden':function(){return!_0x3fb6fe['hasPermission'](_0x93d837);}});}_0x1e9ce2[_0x295808('0x13b8')]('apps',{'title':'APPS','group':!![],'weight':0x1,'hidden':function(){const _0x4b3650=_0x295808;return _0x3fb6fe[_0x4b3650('0x1ac6')]('agent');}}),_0x368e5b[_0x295808('0x92e')]['get']()[_0x295808('0xa44')]['then'](function(_0x118789){const _0x47278e=_0x295808;_0x4c0955['version']=_0x118789&&_0x118789[_0x47278e('0x22b5')]?_0x118789['current']:'UNKNOWN';})[_0x295808('0x1a80')](function(){const _0x2998df=_0x295808;_0x4c0955[_0x2998df('0x92e')]='UNKNOWN';})[_0x295808('0x1951')](function(){const _0x47168d=_0x295808;_0x1e9ce2['saveItem'](_0x47168d('0x92e'),{'title':_0x47168d('0x27fd')+_0x4c0955[_0x47168d('0x92e')],'group':!![],'weight':0x2,'hidden':function(){const _0x354f77=_0x47168d;return _0x3fb6fe[_0x354f77('0x1ac6')](_0x354f77('0x1eff'));}});});function _0x282af1(_0x33bb8b){const _0x1ed27c=_0x295808;return _0x2cfb05()[_0x1ed27c('0x2563')](_0x33bb8b[_0x1ed27c('0x9df')],function(_0x14c9c1){return _0x14c9c1['id'];});}_0x3fb6fe['isLoggedIn']()&&(_0x2e643c[_0x295808('0x241')]&&_0x397a3d[_0x295808('0x1ded')]({'msg':_0x39c0d9[_0x295808('0x25cc')](_0x295808('0x22f6')),'showClose':!![],'timeout':![]}),_0x368e5b[_0x295808('0xba2')][_0x295808('0xd83')]()[_0x295808('0xa44')][_0x295808('0x1166')](function(_0x2fd28e){const _0x4c11f9=_0x295808;let _0x1d510f=0x0;for(let _0x2b5757=0x0;_0x2b5757<_0x2fd28e[_0x4c11f9('0x269a')]['length'];_0x2b5757+=0x1){_0x1d510f=0x1869f+_0x2fd28e[_0x4c11f9('0x269a')][_0x2b5757]['id'],_0x1e9ce2[_0x4c11f9('0x13b8')](_0x4c11f9('0x2016')+_0x1d510f,_0x41b916(_0x1d510f,_0x2fd28e['rows'][_0x2b5757]));}}),_0x368e5b[_0x295808('0xc0e')][_0x295808('0xd83')]({'active':!![]})['$promise'][_0x295808('0x1166')](function(_0x1a3f78){const _0xb6b37=_0x295808;let _0x13c99a=0x0;if(_0x1a3f78[_0xb6b37('0x240f')]){const _0x425f35=_0x2cfb05()[_0xb6b37('0x1c33')](_0x1a3f78['rows'],function(_0x50d5c0){const _0x4f3fd2=_0xb6b37;return _0x50d5c0[_0x4f3fd2('0x234f')]!=_0x4f3fd2('0x122f')&&_0x50d5c0['sidebar']!=_0x4f3fd2('0x5f5');});if(_0x425f35['length']>0x0){_0x1e9ce2[_0xb6b37('0x13b8')](_0xb6b37('0x4bf'),{'id':0x76c,'title':_0xb6b37('0x1893'),'translate':_0xb6b37('0x10a2'),'icon':_0xb6b37('0x283f'),'permissions':{'hidden':!![]},'weight':0x11,'hidden':function(){const _0xaa4644=_0xb6b37;return _0x3fb6fe[_0xaa4644('0x1ac6')]('agent')||!_0x3fb6fe['hasChildrenPermissions'](_0x282af1(this))&&!_0x3fb6fe['hasRole']('admin');}});for(let _0x5de053=0x0;_0x5de053<_0x425f35[_0xb6b37('0x264b')];_0x5de053+=0x1){_0x13c99a=0x15b38+_0x425f35[_0x5de053]['id'],_0x1e9ce2[_0xb6b37('0x13b8')](_0xb6b37('0x1d77')+_0x13c99a,_0x2959eb(_0x13c99a,_0x425f35[_0x5de053]));}_0x1e9ce2[_0xb6b37('0x1aba')]();}const _0x3a7b11=_0x2cfb05()[_0xb6b37('0x1c33')](_0x1a3f78['rows'],function(_0x5eeed1){const _0x237660=_0xb6b37;return _0x5eeed1[_0x237660('0x234f')]!='never'&&_0x5eeed1[_0x237660('0x234f')]!='adminOnly';});if(_0x3a7b11[_0xb6b37('0x264b')]>0x0)for(let _0x133d40=0x0;_0x133d40<_0x3a7b11['length'];_0x133d40+=0x1){_0x13c99a=0x15b38+_0x3a7b11[_0x133d40]['id'],_0x5923a5(_0x13c99a,_0x3a7b11[_0x133d40]);}}})),_0x2e643c[_0x295808('0x2853')]&&!_0x541544[_0x295808('0x1466')]&&_0x541544[_0x295808('0x11f9')]&&angular['element']('#pageTitle')['html'](_0x541544['pageTitle']),_0x1e9ce2['saveItem']('apps.dashboards',{'id':0x64,'title':_0x295808('0x20c8'),'translate':_0x295808('0x24a3'),'icon':_0x295808('0x1457'),'weight':0x2,'hidden':function(){const _0xd0dc21=_0x295808;return _0x3fb6fe['hasRole']('agent')||!_0x3fb6fe['hasChildrenPermissions'](_0x282af1(this))&&!_0x3fb6fe[_0xd0dc21('0x1ac6')](_0xd0dc21('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x25c'),{'id':0x65,'title':'General','route':'','translate':_0x295808('0x8dd'),'state':'app.dashboards.general','weight':0x1,'hidden':function(){const _0x2b002b=_0x295808;return _0x3fb6fe[_0x2b002b('0x1ac6')](_0x2b002b('0x1eff'))||!_0x3fb6fe[_0x2b002b('0x1167')](0x65)&&!_0x3fb6fe['hasRole'](_0x2b002b('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0xc74'),{'id':0xc8,'title':'Staff','translate':_0x295808('0x21a0'),'icon':_0x295808('0x5a2'),'weight':0x3,'hidden':function(){const _0x1877cc=_0x295808;return _0x3fb6fe[_0x1877cc('0x1ac6')]('agent')||!_0x3fb6fe['hasChildrenPermissions'](_0x282af1(this))&&!_0x3fb6fe[_0x1877cc('0x1ac6')](_0x1877cc('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.staff.users',{'id':0xc9,'title':'Users','route':_0x295808('0x557'),'translate':_0x295808('0xd3'),'state':'app.staff.users','weight':0x1,'permissions':{'hidden':!![]},'hidden':function(){const _0x3ea17d=_0x295808;return _0x3fb6fe['hasRole'](_0x3ea17d('0x1eff'))||_0x3fb6fe[_0x3ea17d('0x1ac6')](_0x3ea17d('0x557'))||!_0x3fb6fe['hasPermission'](0xc9)&&!_0x3fb6fe[_0x3ea17d('0x1ac6')](_0x3ea17d('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1d9f'),{'id':0xca,'title':_0x295808('0x2391'),'route':'user','translate':_0x295808('0x281f'),'state':_0x295808('0x2484'),'weight':0x1,'hidden':function(){const _0x33762b=_0x295808;return _0x3fb6fe['hasRole'](_0x33762b('0x1eff'))||!_0x3fb6fe['hasPermission'](0xca)&&!_0x3fb6fe[_0x33762b('0x1ac6')](_0x33762b('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x2414'),{'id':0xcb,'title':_0x295808('0x2323'),'route':'user','translate':'STAFF.TELEPHONES','state':_0x295808('0x1e59'),'weight':0x1,'hidden':function(){const _0x150c7e=_0x295808;return _0x3fb6fe[_0x150c7e('0x1ac6')](_0x150c7e('0x1eff'))||!_0x3fb6fe['hasPermission'](0xcb)&&!_0x3fb6fe[_0x150c7e('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.staff.teams',{'id':0xcc,'title':_0x295808('0x289e'),'route':_0x295808('0x1e37'),'translate':_0x295808('0x17b7'),'state':_0x295808('0x1055'),'weight':0x1,'hidden':function(){const _0x2920ae=_0x295808;return _0x3fb6fe[_0x2920ae('0x1ac6')](_0x2920ae('0x1eff'))||!_0x3fb6fe[_0x2920ae('0x1167')](0xcc)&&!_0x3fb6fe[_0x2920ae('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x88b'),{'id':0xcd,'title':_0x295808('0x137a'),'route':'userProfile','translate':_0x295808('0xb0d'),'state':'app.staff.userProfiles','weight':0x1,'permissions':{'hidden':!![]},'hidden':function(){const _0x665b3f=_0x295808;return _0x3fb6fe[_0x665b3f('0x1ac6')](_0x665b3f('0x1eff'))||!_0x3fb6fe[_0x665b3f('0x1167')](0xcd)&&!_0x3fb6fe[_0x665b3f('0x1ac6')](_0x665b3f('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x26b'),{'id':0x12c,'title':_0x295808('0xffe'),'translate':_0x295808('0x878'),'icon':'icon-account-circle','weight':0x4,'license':'cm','hidden':function(){const _0x115956=_0x295808;return!_0x2e643c['cm']||_0x3fb6fe[_0x115956('0x1ac6')](_0x115956('0x1eff'))||!_0x3fb6fe['hasChildrenPermissions'](_0x282af1(this))&&!_0x3fb6fe[_0x115956('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x2336'),{'id':0x12d,'title':_0x295808('0x1cae'),'route':_0x295808('0xdd9'),'translate':_0x295808('0x2df'),'state':_0x295808('0x24c4'),'weight':0x2,'hidden':function(){const _0x5e30be=_0x295808;return _0x3fb6fe[_0x5e30be('0x1ac6')](_0x5e30be('0x1eff'))||!_0x3fb6fe[_0x5e30be('0x1167')](0x12d)&&!_0x3fb6fe[_0x5e30be('0x1ac6')](_0x5e30be('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.contactmanager.companies',{'id':0x12e,'title':_0x295808('0x117'),'route':_0x295808('0xc39'),'translate':'CONTACTMANAGER.COMPANIES','state':_0x295808('0x1af0'),'weight':0x3,'hidden':function(){const _0xf93a3=_0x295808;return _0x3fb6fe[_0xf93a3('0x1ac6')](_0xf93a3('0x1eff'))||!_0x3fb6fe['hasPermission'](0x12e)&&!_0x3fb6fe[_0xf93a3('0x1ac6')](_0xf93a3('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x1f00'),{'id':0x130,'title':'GlobalCustomFields','route':_0x295808('0x300'),'translate':_0x295808('0x1960'),'state':_0x295808('0xab5'),'weight':0x4,'permissions':{'association':![]},'hidden':function(){const _0x46a9e4=_0x295808;return _0x3fb6fe[_0x46a9e4('0x1ac6')](_0x46a9e4('0x1eff'))||!_0x3fb6fe['hasPermission'](0x130)&&!_0x3fb6fe[_0x46a9e4('0x1ac6')](_0x46a9e4('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x1637'),{'id':0x12f,'title':'Contacts','route':'','translate':'CONTACTMANAGER.CONTACTS','state':'app.contactmanager.contacts','weight':0x1,'permissions':{'association':![]},'hidden':function(){const _0x48b765=_0x295808;return _0x3fb6fe[_0x48b765('0x1ac6')](_0x48b765('0x1eff'))||!_0x3fb6fe['hasPermission'](0x12f)&&!_0x3fb6fe['hasRole'](_0x48b765('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x2663'),{'id':0x190,'title':'Voice','translate':'VOICE.VOICE','icon':_0x295808('0x1473'),'weight':0x5,'license':_0x295808('0x21da'),'hidden':function(){const _0x1ee938=_0x295808;return!_0x2e643c[_0x1ee938('0x21da')]||_0x3fb6fe[_0x1ee938('0x1ac6')](_0x1ee938('0x1eff'))||!_0x3fb6fe[_0x1ee938('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0x1ee938('0x1ac6')](_0x1ee938('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x56e'),{'id':0x191,'title':_0x295808('0x1ba2'),'route':_0x295808('0x1943'),'translate':'VOICE.VOICEQUEUES','state':_0x295808('0x2409'),'weight':0x1,'channel':'voice','hidden':function(){const _0x329b98=_0x295808;return _0x3fb6fe['hasRole']('agent')||!_0x3fb6fe['hasPermission'](0x191)&&!_0x3fb6fe[_0x329b98('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1475'),{'id':0x192,'title':_0x295808('0x679'),'route':_0x295808('0x1deb'),'translate':_0x295808('0xf0'),'state':_0x295808('0x2107'),'weight':0x1,'hidden':function(){const _0x2bc51f=_0x295808;return _0x3fb6fe[_0x2bc51f('0x1ac6')](_0x2bc51f('0x1eff'))||!_0x3fb6fe[_0x2bc51f('0x1167')](0x192)&&!_0x3fb6fe[_0x2bc51f('0x1ac6')](_0x2bc51f('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x240c'),{'id':0x193,'title':'OutboundRoutes','route':_0x295808('0x1deb'),'translate':'VOICE.OUTBOUNDROUTES','state':'app.voice.outboundroutes','weight':0x1,'hidden':function(){const _0x26459d=_0x295808;return _0x3fb6fe[_0x26459d('0x1ac6')]('agent')||!_0x3fb6fe['hasPermission'](0x193)&&!_0x3fb6fe['hasRole'](_0x26459d('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x12ac'),{'id':0x194,'title':_0x295808('0x21ce'),'route':_0x295808('0x1deb'),'translate':_0x295808('0x28f8'),'state':_0x295808('0x2b0'),'weight':0x1,'hidden':function(){const _0x20cc8c=_0x295808;return _0x3fb6fe[_0x20cc8c('0x1ac6')]('agent')||!_0x3fb6fe[_0x20cc8c('0x1167')](0x194)&&!_0x3fb6fe[_0x20cc8c('0x1ac6')](_0x20cc8c('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.voice.contexts',{'id':0x195,'title':_0x295808('0x136e'),'route':_0x295808('0x23b1'),'translate':'VOICE.CONTEXTS','state':_0x295808('0x839'),'weight':0x1,'hidden':function(){const _0xae2ad4=_0x295808;return _0x3fb6fe[_0xae2ad4('0x1ac6')](_0xae2ad4('0x1eff'))||!_0x3fb6fe[_0xae2ad4('0x1167')](0x195)&&!_0x3fb6fe['hasRole'](_0xae2ad4('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.voice.voicemails',{'id':0x196,'title':_0x295808('0x1116'),'route':_0x295808('0x8d4'),'translate':_0x295808('0x1cf5'),'state':_0x295808('0x27be'),'weight':0x1,'hidden':function(){const _0x582de4=_0x295808;return _0x3fb6fe[_0x582de4('0x1ac6')](_0x582de4('0x1eff'))||!_0x3fb6fe[_0x582de4('0x1167')](0x196)&&!_0x3fb6fe[_0x582de4('0x1ac6')]('admin');}}),_0x1e9ce2['saveItem'](_0x295808('0x1d0c'),{'id':0x197,'title':_0x295808('0x1a14'),'route':'voiceMusicOnHold','translate':_0x295808('0x12c8'),'state':_0x295808('0x1b42'),'weight':0x1,'hidden':function(){const _0x5740d3=_0x295808;return _0x3fb6fe[_0x5740d3('0x1ac6')](_0x5740d3('0x1eff'))||!_0x3fb6fe[_0x5740d3('0x1167')](0x197)&&!_0x3fb6fe[_0x5740d3('0x1ac6')](_0x5740d3('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.voice.voiceRecordings',{'id':0x198,'title':_0x295808('0x262e'),'route':'voiceRecording','translate':_0x295808('0x45e'),'state':_0x295808('0x20a1'),'weight':0x1,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x25d6a2=_0x295808;return _0x3fb6fe[_0x25d6a2('0x1ac6')]('agent')||!_0x3fb6fe[_0x25d6a2('0x1167')](0x198)&&!_0x3fb6fe[_0x25d6a2('0x1ac6')](_0x25d6a2('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x124c'),{'id':0x199,'title':_0x295808('0x61c'),'route':_0x295808('0x35c'),'translate':_0x295808('0x21c'),'state':_0x295808('0x1ec3'),'weight':0x1,'hidden':function(){const _0x3271e3=_0x295808;return _0x3fb6fe[_0x3271e3('0x1ac6')](_0x3271e3('0x1eff'))||!_0x3fb6fe[_0x3271e3('0x1167')](0x199)&&!_0x3fb6fe[_0x3271e3('0x1ac6')](_0x3271e3('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1aac'),{'id':0x19a,'title':_0x295808('0x2385'),'route':_0x295808('0x1d96'),'translate':_0x295808('0x1552'),'state':_0x295808('0x2666'),'weight':0x1,'hidden':function(){const _0x4006be=_0x295808;return _0x3fb6fe['hasRole'](_0x4006be('0x1eff'))||!_0x3fb6fe['hasPermission'](0x19a)&&!_0x3fb6fe[_0x4006be('0x1ac6')](_0x4006be('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x24ef'),{'id':0x19b,'title':_0x295808('0x16de'),'route':'','translate':_0x295808('0x20dd'),'state':_0x295808('0x468'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0xd21dcd=_0x295808;return _0x3fb6fe[_0xd21dcd('0x1ac6')](_0xd21dcd('0x1eff'))||!_0x3fb6fe['hasPermission'](0x19b)&&!_0x3fb6fe[_0xd21dcd('0x1ac6')](_0xd21dcd('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x26b0'),{'id':0x1f4,'title':_0x295808('0x771'),'translate':_0x295808('0x14f8'),'icon':_0x295808('0xc49'),'weight':0x6,'license':_0x295808('0xde2'),'hidden':function(){const _0x33006d=_0x295808;return!_0x2e643c[_0x33006d('0xde2')]||_0x3fb6fe[_0x33006d('0x1ac6')](_0x33006d('0x1eff'))||!_0x3fb6fe[_0x33006d('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0x33006d('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0xa2c'),{'id':0x1f5,'title':_0x295808('0x1858'),'route':_0x295808('0x1e45'),'translate':_0x295808('0x28d3'),'state':_0x295808('0x1515'),'weight':0x1,'channel':_0x295808('0xde2'),'hidden':function(){const _0x162336=_0x295808;return _0x3fb6fe[_0x162336('0x1ac6')](_0x162336('0x1eff'))||!_0x3fb6fe[_0x162336('0x1167')](0x1f5)&&!_0x3fb6fe[_0x162336('0x1ac6')](_0x162336('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x12b3'),{'id':0x1f6,'title':'ChatWebsites','route':'chatWebsite','translate':'CHAT.CHATWEBSITES','state':_0x295808('0xcd'),'weight':0x1,'channel':_0x295808('0xde2'),'hidden':function(){const _0x4aa0d8=_0x295808;return _0x3fb6fe['hasRole']('agent')||!_0x3fb6fe[_0x4aa0d8('0x1167')](0x1f6)&&!_0x3fb6fe['hasRole'](_0x4aa0d8('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0xd66'),{'id':0x1fe,'title':_0x295808('0x16de'),'route':'','translate':_0x295808('0x11c7'),'state':_0x295808('0x286f'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x59e5d5=_0x295808;return _0x3fb6fe['hasRole']('agent')||!_0x3fb6fe['hasPermission'](0x1fe)&&!_0x3fb6fe[_0x59e5d5('0x1ac6')](_0x59e5d5('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x5b'),{'id':0x258,'title':_0x295808('0x22e7'),'translate':'MAIL.MAIL','icon':_0x295808('0x142d'),'weight':0x7,'license':_0x295808('0x1bfa'),'hidden':function(){const _0x1a7f25=_0x295808;return!_0x2e643c[_0x1a7f25('0x1bfa')]||_0x3fb6fe[_0x1a7f25('0x1ac6')](_0x1a7f25('0x1eff'))||!_0x3fb6fe[_0x1a7f25('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0x1a7f25('0x1ac6')](_0x1a7f25('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0xf5'),{'id':0x259,'title':_0x295808('0x5f8'),'route':_0x295808('0x24c9'),'translate':_0x295808('0x4d7'),'state':_0x295808('0x2025'),'weight':0x1,'channel':_0x295808('0x1bfa'),'hidden':function(){const _0x1caeaa=_0x295808;return _0x3fb6fe[_0x1caeaa('0x1ac6')]('agent')||!_0x3fb6fe[_0x1caeaa('0x1167')](0x259)&&!_0x3fb6fe[_0x1caeaa('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.mail.mailAccounts',{'id':0x25a,'title':_0x295808('0x17bd'),'route':_0x295808('0x21b9'),'translate':_0x295808('0x2173'),'state':'app.mail.mailAccounts','weight':0x1,'channel':_0x295808('0x1bfa'),'hidden':function(){const _0x3ccbaf=_0x295808;return _0x3fb6fe[_0x3ccbaf('0x1ac6')](_0x3ccbaf('0x1eff'))||!_0x3fb6fe['hasPermission'](0x25a)&&!_0x3fb6fe[_0x3ccbaf('0x1ac6')]('admin');}}),_0x1e9ce2['saveItem'](_0x295808('0x23d3'),{'id':0x25b,'title':_0x295808('0xd68'),'route':_0x295808('0x1c44'),'translate':_0x295808('0x1d1f'),'state':_0x295808('0x2618'),'weight':0x1,'channel':'mail','permissions':{'association':![]},'hidden':function(){const _0x48eae4=_0x295808;return _0x3fb6fe[_0x48eae4('0x1ac6')](_0x48eae4('0x1eff'))||!_0x3fb6fe[_0x48eae4('0x1167')](0x25b)&&!_0x3fb6fe[_0x48eae4('0x1ac6')](_0x48eae4('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x257e'),{'id':0x262,'title':_0x295808('0x16de'),'route':'','translate':_0x295808('0x2401'),'state':_0x295808('0x26ba'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x59681c=_0x295808;return _0x3fb6fe[_0x59681c('0x1ac6')]('agent')||!_0x3fb6fe[_0x59681c('0x1167')](0x262)&&!_0x3fb6fe[_0x59681c('0x1ac6')](_0x59681c('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0xdca'),{'id':0x2bc,'title':'Sms','translate':_0x295808('0x131c'),'icon':'icon-message-text','weight':0x8,'license':_0x295808('0x684'),'hidden':function(){const _0x32df2c=_0x295808;return!_0x2e643c[_0x32df2c('0x684')]||_0x3fb6fe['hasRole'](_0x32df2c('0x1eff'))||!_0x3fb6fe[_0x32df2c('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0x32df2c('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x26cf'),{'id':0x2bd,'title':_0x295808('0x24e4'),'route':'smsQueue','translate':_0x295808('0x1820'),'state':'app.sms.smsQueues','weight':0x1,'channel':_0x295808('0x146c'),'hidden':function(){const _0x18cacc=_0x295808;return _0x3fb6fe[_0x18cacc('0x1ac6')](_0x18cacc('0x1eff'))||!_0x3fb6fe['hasPermission'](0x2bd)&&!_0x3fb6fe[_0x18cacc('0x1ac6')](_0x18cacc('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x85'),{'id':0x2be,'title':_0x295808('0x1442'),'route':_0x295808('0x27e5'),'translate':_0x295808('0x1008'),'state':_0x295808('0x248d'),'weight':0x1,'channel':_0x295808('0x146c'),'hidden':function(){const _0x3489fa=_0x295808;return _0x3fb6fe[_0x3489fa('0x1ac6')](_0x3489fa('0x1eff'))||!_0x3fb6fe[_0x3489fa('0x1167')](0x2be)&&!_0x3fb6fe[_0x3489fa('0x1ac6')]('admin');}}),_0x1e9ce2['saveItem'](_0x295808('0x1386'),{'id':0x2c6,'title':_0x295808('0x16de'),'route':'','translate':'SMS.REALTIME','state':_0x295808('0x1e4b'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x2c3dc5=_0x295808;return _0x3fb6fe[_0x2c3dc5('0x1ac6')](_0x2c3dc5('0x1eff'))||!_0x3fb6fe['hasPermission'](0x2c6)&&!_0x3fb6fe['hasRole'](_0x2c3dc5('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.openchannel',{'id':0x320,'title':_0x295808('0x1753'),'translate':_0x295808('0x251'),'icon':_0x295808('0x2052'),'weight':0x9,'license':_0x295808('0x26c'),'hidden':function(){const _0xe142ab=_0x295808;return!_0x2e643c[_0xe142ab('0x26c')]||_0x3fb6fe[_0xe142ab('0x1ac6')](_0xe142ab('0x1eff'))||!_0x3fb6fe[_0xe142ab('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0xe142ab('0x1ac6')](_0xe142ab('0xa7c'));}}),_0x1e9ce2['saveItem']('apps.openchannel.openchannelQueues',{'id':0x321,'title':'OpenchannelQueues','route':_0x295808('0x262f'),'translate':'OPENCHANNEL.OPENCHANNELQUEUES','state':'app.openchannel.openchannelQueues','weight':0x1,'channel':'openChannel','hidden':function(){const _0x423689=_0x295808;return _0x3fb6fe[_0x423689('0x1ac6')](_0x423689('0x1eff'))||!_0x3fb6fe[_0x423689('0x1167')](0x321)&&!_0x3fb6fe['hasRole'](_0x423689('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1af8'),{'id':0x322,'title':_0x295808('0x1575'),'route':_0x295808('0x77f'),'translate':_0x295808('0xe75'),'state':'app.openchannel.openchannelAccounts','weight':0x1,'channel':_0x295808('0x1f1a'),'hidden':function(){const _0x17217a=_0x295808;return _0x3fb6fe[_0x17217a('0x1ac6')](_0x17217a('0x1eff'))||!_0x3fb6fe[_0x17217a('0x1167')](0x322)&&!_0x3fb6fe['hasRole'](_0x17217a('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x2851'),{'id':0x32a,'title':_0x295808('0x16de'),'route':'','translate':_0x295808('0x1e5'),'state':'app.openchannel.realtime','weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x554cc4=_0x295808;return _0x3fb6fe[_0x554cc4('0x1ac6')]('agent')||!_0x3fb6fe[_0x554cc4('0x1167')](0x32a)&&!_0x3fb6fe[_0x554cc4('0x1ac6')](_0x554cc4('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1508'),{'id':0x384,'title':'Fax','translate':_0x295808('0x124b'),'icon':_0x295808('0x23fb'),'weight':0xa,'license':_0x295808('0x1fc7'),'hidden':function(){const _0x2592c6=_0x295808;return!_0x2e643c[_0x2592c6('0x1fc7')]||_0x3fb6fe[_0x2592c6('0x1ac6')](_0x2592c6('0x1eff'))||!_0x3fb6fe[_0x2592c6('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0x2592c6('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.fax.faxQueues',{'id':0x385,'title':_0x295808('0x1e54'),'route':_0x295808('0x1a5b'),'translate':_0x295808('0x1b83'),'state':_0x295808('0x18e5'),'weight':0x1,'channel':_0x295808('0x1fc7'),'hidden':function(){const _0x386c34=_0x295808;return _0x3fb6fe['hasRole'](_0x386c34('0x1eff'))||!_0x3fb6fe[_0x386c34('0x1167')](0x385)&&!_0x3fb6fe['hasRole'](_0x386c34('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x32e'),{'id':0x386,'title':_0x295808('0x1c3b'),'route':_0x295808('0x2085'),'translate':_0x295808('0xb5'),'state':_0x295808('0x1c56'),'weight':0x1,'channel':'fax','hidden':function(){const _0x4731f8=_0x295808;return _0x3fb6fe['hasRole']('agent')||!_0x3fb6fe[_0x4731f8('0x1167')](0x386)&&!_0x3fb6fe[_0x4731f8('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1211'),{'id':0x38e,'title':_0x295808('0x16de'),'route':'','translate':'FAX.REALTIME','state':'app.fax.realtime','weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x2bfb8b=_0x295808;return _0x3fb6fe[_0x2bfb8b('0x1ac6')](_0x2bfb8b('0x1eff'))||!_0x3fb6fe[_0x2bfb8b('0x1167')](0x38e)&&!_0x3fb6fe[_0x2bfb8b('0x1ac6')](_0x2bfb8b('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.tools',{'id':0x3e8,'title':_0x295808('0x14b3'),'translate':_0x295808('0xe1f'),'icon':_0x295808('0x287b'),'weight':0xf,'hidden':function(){const _0x59fa75=_0x295808;return _0x3fb6fe[_0x59fa75('0x1ac6')](_0x59fa75('0x1eff'))||!_0x3fb6fe[_0x59fa75('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0x59fa75('0x1ac6')](_0x59fa75('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.tools.cannedAnswers',{'id':0x3e9,'title':'CannedAnswers','route':'cannedAnswer','translate':_0x295808('0x16f6'),'state':'app.tools.cannedAnswers','weight':0x1,'hidden':function(){const _0xd61ba7=_0x295808;return _0x3fb6fe[_0xd61ba7('0x1ac6')](_0xd61ba7('0x1eff'))||!_0x3fb6fe[_0xd61ba7('0x1167')](0x3e9)&&!_0x3fb6fe['hasRole']('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x2284'),{'id':0x3eb,'title':'CustomDashboards','route':_0x295808('0xba2'),'translate':_0x295808('0x1425'),'state':_0x295808('0x977'),'weight':0x3,'hidden':function(){const _0xb64bd3=_0x295808;return _0x3fb6fe[_0xb64bd3('0x1ac6')]('agent')||!_0x3fb6fe[_0xb64bd3('0x1167')](0x3eb)&&!_0x3fb6fe['hasRole'](_0xb64bd3('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x11bb'),{'id':0x3ec,'title':'Intervals','route':'interval','translate':_0x295808('0x169'),'state':_0x295808('0x950'),'weight':0x4,'hidden':function(){const _0x57d7e2=_0x295808;return _0x3fb6fe[_0x57d7e2('0x1ac6')](_0x57d7e2('0x1eff'))||!_0x3fb6fe[_0x57d7e2('0x1167')](0x3ec)&&!_0x3fb6fe[_0x57d7e2('0x1ac6')](_0x57d7e2('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x8c'),{'id':0x3ed,'title':_0x295808('0x1377'),'route':_0x295808('0x1e77'),'translate':_0x295808('0xdd1'),'state':'app.tools.pauses','weight':0x5,'hidden':function(){const _0x181ee5=_0x295808;return _0x3fb6fe['hasRole'](_0x181ee5('0x1eff'))||!_0x3fb6fe[_0x181ee5('0x1167')](0x3ed)&&!_0x3fb6fe[_0x181ee5('0x1ac6')](_0x181ee5('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x2801'),{'id':0x3ee,'title':_0x295808('0x2ab'),'route':_0x295808('0x892'),'translate':_0x295808('0xbc0'),'state':_0x295808('0x1711'),'weight':0x6,'hidden':function(){const _0x1425f0=_0x295808;return _0x3fb6fe[_0x1425f0('0x1ac6')]('agent')||!_0x3fb6fe[_0x1425f0('0x1167')](0x3ee)&&!_0x3fb6fe[_0x1425f0('0x1ac6')](_0x1425f0('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0xda7'),{'id':0x3ef,'title':'Sounds','route':_0x295808('0x960'),'translate':_0x295808('0x22b9'),'state':'app.tools.sounds','weight':0x7,'hidden':function(){const _0x579dc6=_0x295808;return _0x3fb6fe[_0x579dc6('0x1ac6')]('agent')||!_0x3fb6fe[_0x579dc6('0x1167')](0x3ef)&&!_0x3fb6fe[_0x579dc6('0x1ac6')](_0x579dc6('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.tools.tags',{'id':0x3f0,'title':_0x295808('0x21c2'),'route':_0x295808('0x1446'),'translate':'TOOLS.TAGS','state':_0x295808('0x1f6e'),'weight':0x8,'hidden':function(){const _0x573809=_0x295808;return _0x3fb6fe[_0x573809('0x1ac6')]('agent')||!_0x3fb6fe[_0x573809('0x1167')](0x3f0)&&!_0x3fb6fe[_0x573809('0x1ac6')](_0x573809('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x2490'),{'id':0x3f1,'title':_0x295808('0x9fd'),'route':'template','translate':_0x295808('0x2616'),'state':'app.tools.templates','weight':0x9,'hidden':function(){const _0x213cfa=_0x295808;return _0x3fb6fe['hasRole'](_0x213cfa('0x1eff'))||!_0x3fb6fe[_0x213cfa('0x1167')](0x3f1)&&!_0x3fb6fe[_0x213cfa('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1354'),{'id':0x3f3,'title':_0x295808('0x2685'),'route':_0x295808('0x3b2'),'translate':_0x295808('0x5ea'),'state':_0x295808('0x108d'),'weight':0xb,'hidden':function(){const _0x2f2dfb=_0x295808;return _0x3fb6fe[_0x2f2dfb('0x1ac6')]('agent')||!_0x3fb6fe['hasPermission'](0x3f3)&&!_0x3fb6fe[_0x2f2dfb('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x17f0'),{'id':0x3f4,'title':_0x295808('0xb77'),'route':'variable','translate':_0x295808('0x1fe'),'state':_0x295808('0x1d75'),'weight':0xc,'hidden':function(){const _0x51bd81=_0x295808;return _0x3fb6fe[_0x51bd81('0x1ac6')](_0x51bd81('0x1eff'))||!_0x3fb6fe[_0x51bd81('0x1167')](0x3f4)&&!_0x3fb6fe[_0x51bd81('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x282e'),{'id':0x3ea,'title':_0x295808('0x10fb'),'route':_0x295808('0x12e8'),'translate':_0x295808('0x1c6'),'state':_0x295808('0x17eb'),'weight':0x2,'hidden':function(){const _0x562b39=_0x295808;return _0x3fb6fe['hasRole'](_0x562b39('0x1eff'))||!_0x3fb6fe[_0x562b39('0x1167')](0x3ea)&&!_0x3fb6fe[_0x562b39('0x1ac6')]('admin');}}),_0x1e9ce2['saveItem'](_0x295808('0x222b'),{'id':0x3f2,'title':_0x295808('0x10f4'),'route':'','translate':_0x295808('0xecf'),'state':_0x295808('0x1e20'),'weight':0xa,'hidden':function(){const _0xf05e21=_0x295808;return _0x3fb6fe[_0xf05e21('0x1ac6')](_0xf05e21('0x1eff'))||!_0x3fb6fe[_0xf05e21('0x1167')](0x3f2)&&!_0x3fb6fe[_0xf05e21('0x1ac6')](_0xf05e21('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x42'),{'id':0x44c,'title':_0x295808('0x678'),'translate':'CALLYSQUARE.CALLYSQUARE','icon':_0x295808('0x641'),'weight':0xd,'license':_0x295808('0x21da'),'hidden':function(){const _0x291772=_0x295808;return!_0x2e643c['voice']||_0x3fb6fe['hasRole'](_0x291772('0x1eff'))||!_0x3fb6fe['hasChildrenPermissions'](_0x282af1(this))&&!_0x3fb6fe[_0x291772('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x129a'),{'id':0x44d,'title':_0x295808('0x1b6'),'route':_0x295808('0xb7b'),'translate':_0x295808('0x2445'),'state':_0x295808('0x2703'),'weight':0x2,'hidden':function(){const _0x492aa1=_0x295808;return _0x3fb6fe[_0x492aa1('0x1ac6')](_0x492aa1('0x1eff'))||!_0x3fb6fe[_0x492aa1('0x1167')](0x44d)&&!_0x3fb6fe[_0x492aa1('0x1ac6')](_0x492aa1('0xa7c'));}}),_0x1e9ce2['saveItem']('apps.callysquare.squareRecordings',{'id':0x44e,'title':'SquareRecordings','route':_0x295808('0x2720'),'translate':'CALLYSQUARE.SQUARERECORDINGS','state':_0x295808('0x232b'),'weight':0x3,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x4abc01=_0x295808;return _0x3fb6fe[_0x4abc01('0x1ac6')](_0x4abc01('0x1eff'))||!_0x3fb6fe[_0x4abc01('0x1167')](0x44e)&&!_0x3fb6fe[_0x4abc01('0x1ac6')](_0x4abc01('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x17b4'),{'id':0x44f,'title':_0x295808('0xda5'),'route':_0x295808('0x7e4'),'translate':_0x295808('0x4d3'),'state':_0x295808('0x2040'),'weight':0x1,'hidden':function(){const _0x252839=_0x295808;return _0x3fb6fe['hasRole'](_0x252839('0x1eff'))||!_0x3fb6fe[_0x252839('0x1167')](0x44f)&&!_0x3fb6fe[_0x252839('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x48c'),{'id':0x4b0,'title':_0x295808('0xe4e'),'translate':_0x295808('0x2252'),'icon':_0x295808('0x1d06'),'weight':0x10,'hidden':function(){const _0x30f80b=_0x295808;return _0x3fb6fe[_0x30f80b('0x1ac6')](_0x30f80b('0x1eff'))||!_0x3fb6fe['hasChildrenPermissions'](_0x282af1(this))&&!_0x3fb6fe[_0x30f80b('0x1ac6')](_0x30f80b('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0xa48'),{'id':0x4b1,'title':_0x295808('0x27ed'),'route':_0x295808('0x2e8'),'translate':_0x295808('0x1ddc'),'state':_0x295808('0x857'),'weight':0x3,'hidden':function(){const _0x4aadd5=_0x295808;return _0x3fb6fe[_0x4aadd5('0x1ac6')](_0x4aadd5('0x1eff'))||!_0x3fb6fe['hasPermission'](0x4b1)&&!_0x3fb6fe[_0x4aadd5('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x843'),{'id':0x4b2,'title':_0x295808('0x1e5a'),'route':'analyticExtractedReport','translate':_0x295808('0xfc4'),'state':_0x295808('0x789'),'weight':0x2,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0xbbe488=_0x295808;return _0x3fb6fe[_0xbbe488('0x1ac6')](_0xbbe488('0x1eff'))||!_0x3fb6fe[_0xbbe488('0x1167')](0x4b2)&&!_0x3fb6fe['hasRole'](_0xbbe488('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0xf7a'),{'id':0x4b3,'title':_0x295808('0x2165'),'route':'','translate':'ANALYTICS.REPORTS','state':'app.analytics.reports','weight':0x1,'hidden':function(){const _0x475e78=_0x295808;return _0x3fb6fe[_0x475e78('0x1ac6')]('agent')||!_0x3fb6fe['hasPermission'](0x4b3)&&!_0x3fb6fe[_0x475e78('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1d35'),{'id':0x514,'title':_0x295808('0x897'),'translate':'INTEGRATIONS.INTEGRATIONS','icon':'icon-heart','weight':0x11,'hidden':function(){const _0xb1fe44=_0x295808;return _0x3fb6fe[_0xb1fe44('0x1ac6')](_0xb1fe44('0x1eff'))||!_0x3fb6fe['hasChildrenPermissions'](_0x282af1(this))&&!_0x3fb6fe[_0xb1fe44('0x1ac6')](_0xb1fe44('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1956'),{'id':0x515,'title':_0x295808('0xc99'),'route':_0x295808('0x2290'),'translate':_0x295808('0x1ab0'),'state':'app.integrations.zendeskAccounts','weight':0x1,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x2b08ef=_0x295808;return _0x3fb6fe[_0x2b08ef('0x1ac6')](_0x2b08ef('0x1eff'))||!_0x3fb6fe[_0x2b08ef('0x1167')](0x515)&&!_0x3fb6fe[_0x2b08ef('0x1ac6')](_0x2b08ef('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x4b8'),{'id':0x516,'title':_0x295808('0x350'),'route':_0x295808('0x164'),'translate':_0x295808('0x22b3'),'state':_0x295808('0x1df9'),'weight':0x2,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x1d3cb2=_0x295808;return _0x3fb6fe[_0x1d3cb2('0x1ac6')]('agent')||!_0x3fb6fe[_0x1d3cb2('0x1167')](0x516)&&!_0x3fb6fe['hasRole'](_0x1d3cb2('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x7a6'),{'id':0x517,'title':_0x295808('0x1c35'),'route':_0x295808('0xc1e'),'translate':_0x295808('0x1b43'),'state':_0x295808('0x28c7'),'weight':0x3,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0xce0219=_0x295808;return _0x3fb6fe['hasRole'](_0xce0219('0x1eff'))||!_0x3fb6fe[_0xce0219('0x1167')](0x517)&&!_0x3fb6fe['hasRole'](_0xce0219('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x1f3b'),{'id':0x519,'title':_0x295808('0xe20'),'route':_0x295808('0x13d9'),'translate':_0x295808('0x2e2'),'state':'app.integrations.sugarcrmAccounts','weight':0x4,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x452249=_0x295808;return _0x3fb6fe['hasRole']('agent')||!_0x3fb6fe['hasPermission'](0x519)&&!_0x3fb6fe[_0x452249('0x1ac6')]('admin');}}),_0x1e9ce2['saveItem'](_0x295808('0x1021'),{'id':0x51a,'title':_0x295808('0x3e1'),'route':_0x295808('0x1db9'),'translate':_0x295808('0x272'),'state':'app.integrations.deskAccounts','weight':0x5,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x2e4357=_0x295808;return _0x3fb6fe['hasRole'](_0x2e4357('0x1eff'))||!_0x3fb6fe[_0x2e4357('0x1167')](0x51a)&&!_0x3fb6fe[_0x2e4357('0x1ac6')](_0x2e4357('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1450'),{'id':0x51b,'title':_0x295808('0x1f5b'),'route':_0x295808('0x11d1'),'translate':'INTEGRATIONS.ZOHOACCOUNTS','state':_0x295808('0x11f3'),'weight':0x6,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x2f82c6=_0x295808;return _0x3fb6fe[_0x2f82c6('0x1ac6')]('agent')||!_0x3fb6fe[_0x2f82c6('0x1167')](0x51b)&&!_0x3fb6fe[_0x2f82c6('0x1ac6')](_0x2f82c6('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0xb0c'),{'id':0x51c,'title':_0x295808('0xd9b'),'route':_0x295808('0x1b52'),'translate':_0x295808('0x117b'),'state':'app.integrations.vtigerAccounts','weight':0x7,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0xc74474=_0x295808;return _0x3fb6fe[_0xc74474('0x1ac6')](_0xc74474('0x1eff'))||!_0x3fb6fe[_0xc74474('0x1167')](0x51c)&&!_0x3fb6fe[_0xc74474('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1f5c'),{'id':0x51d,'title':_0x295808('0x8c8'),'route':_0x295808('0x2176'),'translate':_0x295808('0xe45'),'state':_0x295808('0x280c'),'weight':0x8,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x1fd65c=_0x295808;return _0x3fb6fe['hasRole'](_0x1fd65c('0x1eff'))||!_0x3fb6fe['hasPermission'](0x51d)&&!_0x3fb6fe[_0x1fd65c('0x1ac6')](_0x1fd65c('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x17d2'),{'id':0x51e,'title':'ServicenowAccounts','route':_0x295808('0x148b'),'translate':_0x295808('0x1e4a'),'state':_0x295808('0x1c78'),'weight':0x9,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x1a8bd8=_0x295808;return _0x3fb6fe[_0x1a8bd8('0x1ac6')](_0x1a8bd8('0x1eff'))||!_0x3fb6fe[_0x1a8bd8('0x1167')](0x51e)&&!_0x3fb6fe[_0x1a8bd8('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x16aa'),{'id':0x518,'title':_0x295808('0x16b7'),'route':_0x295808('0x11cd'),'translate':_0x295808('0x288c'),'state':_0x295808('0x1da7'),'weight':0xa,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x37feeb=_0x295808;return _0x3fb6fe[_0x37feeb('0x1ac6')](_0x37feeb('0x1eff'))||!_0x3fb6fe[_0x37feeb('0x1167')](0x518)&&!_0x3fb6fe[_0x37feeb('0x1ac6')](_0x37feeb('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.settings',{'id':0x578,'title':'Settings','translate':_0x295808('0x1fb7'),'icon':_0x295808('0x1770'),'weight':0x14,'permissions':{'hidden':!![]},'hidden':function(){const _0x40a02d=_0x295808;return _0x3fb6fe[_0x40a02d('0x1ac6')](_0x40a02d('0x1eff'))||!_0x3fb6fe[_0x40a02d('0x1167')](0x578)&&!_0x3fb6fe[_0x40a02d('0x1ac6')](_0x40a02d('0xa7c'))||_0x3fb6fe['hasRole'](_0x40a02d('0xa7c'))&&!_0x3fb6fe['getCurrentUser']()[_0x40a02d('0x1c8b')];}}),_0x1e9ce2['saveItem'](_0x295808('0x2108'),{'id':0x579,'title':_0x295808('0x4a2'),'route':_0x295808('0xf8a'),'translate':_0x295808('0x85b'),'state':'app.settings.generals','weight':0x1,'hidden':function(){const _0x285b24=_0x295808;return _0x3fb6fe['hasRole']('agent')||!_0x3fb6fe[_0x285b24('0x1167')](0x578)&&!_0x3fb6fe['hasRole'](_0x285b24('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x2095'),{'id':0x57a,'title':_0x295808('0x1c57'),'route':_0x295808('0x21b9'),'translate':_0x295808('0x1290'),'state':'app.settings.smtps','weight':0x1,'hidden':function(){const _0x50ec0b=_0x295808;return _0x3fb6fe[_0x50ec0b('0x1ac6')](_0x50ec0b('0x1eff'))||!_0x3fb6fe[_0x50ec0b('0x1167')](0x578)&&!_0x3fb6fe['hasRole'](_0x50ec0b('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x893'),{'id':0x57b,'title':_0x295808('0x2b4'),'route':_0x295808('0x2638'),'translate':_0x295808('0x1ff1'),'state':_0x295808('0xb0b'),'weight':0x1,'hidden':function(){const _0x515ef1=_0x295808;return _0x3fb6fe[_0x515ef1('0x1ac6')](_0x515ef1('0x1eff'))||!_0x3fb6fe[_0x515ef1('0x1167')](0x578)&&!_0x3fb6fe[_0x515ef1('0x1ac6')](_0x515ef1('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x21ed'),{'id':0x57f,'title':'Customizations','route':_0x295808('0xf8a'),'translate':_0x295808('0x1e0f'),'state':'app.settings.customizations','weight':0x1,'hidden':function(){const _0x3ebcd9=_0x295808;return!_0x2e643c['custom']||_0x3fb6fe['hasRole'](_0x3ebcd9('0x1eff'))||!_0x3fb6fe['hasPermission'](0x578)&&!_0x3fb6fe['hasRole']('admin');}}),_0x1e9ce2['saveItem'](_0x295808('0xa9c'),{'id':0x580,'title':_0x295808('0x1c0b'),'route':_0x295808('0x16c6'),'translate':_0x295808('0x1427'),'state':_0x295808('0xa82'),'weight':0x1,'hidden':function(){const _0x382db8=_0x295808;return!_0x2e643c['ai']||_0x3fb6fe[_0x382db8('0x1ac6')]('agent')||!_0x3fb6fe[_0x382db8('0x1167')](0x578)&&!_0x3fb6fe[_0x382db8('0x1ac6')](_0x382db8('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x1c4e'),{'id':0x57c,'title':_0x295808('0x40f'),'route':'','translate':_0x295808('0xcf2'),'state':_0x295808('0xf45'),'weight':0x1,'hidden':function(){const _0x211a07=_0x295808;return!_0x2e643c[_0x211a07('0x1449')]||_0x3fb6fe[_0x211a07('0x1ac6')](_0x211a07('0x1eff'))||!_0x3fb6fe[_0x211a07('0x1167')](0x578)&&!_0x3fb6fe[_0x211a07('0x1ac6')](_0x211a07('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x148f'),{'id':0x57d,'title':_0x295808('0x2881'),'route':'','translate':_0x295808('0x940'),'state':'app.settings.license','weight':0x1,'hidden':function(){const _0x46a880=_0x295808;return _0x3fb6fe[_0x46a880('0x1ac6')](_0x46a880('0x1eff'))||!_0x3fb6fe[_0x46a880('0x1167')](0x578)&&!_0x3fb6fe[_0x46a880('0x1ac6')](_0x46a880('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0xc37'),{'id':0x57e,'title':_0x295808('0x270a'),'route':'','translate':_0x295808('0x9f'),'state':_0x295808('0xb2'),'weight':0x1,'hidden':function(){const _0x83b9a2=_0x295808;return _0x3fb6fe[_0x83b9a2('0x1ac6')](_0x83b9a2('0x1eff'))||!_0x3fb6fe['hasPermission'](0x578)&&!_0x3fb6fe[_0x83b9a2('0x1ac6')](_0x83b9a2('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.motiondialer',{'id':0x5dc,'title':_0x295808('0x189f'),'translate':_0x295808('0x10e1'),'icon':'icon-fire','weight':0x5,'license':'dialer','hidden':function(){const _0x5f2965=_0x295808;return!_0x2e643c[_0x5f2965('0x21ee')]||_0x3fb6fe[_0x5f2965('0x1ac6')]('agent')||!_0x3fb6fe[_0x5f2965('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0x5f2965('0x1ac6')](_0x5f2965('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x2880'),{'id':0x5dd,'title':_0x295808('0x9f4'),'route':_0x295808('0x1943'),'translate':_0x295808('0x1f43'),'state':_0x295808('0xd3c'),'weight':0x1,'channel':_0x295808('0x1957'),'hidden':function(){const _0x50a44f=_0x295808;return _0x3fb6fe[_0x50a44f('0x1ac6')](_0x50a44f('0x1eff'))||!_0x3fb6fe[_0x50a44f('0x1167')](0x5dd)&&!_0x3fb6fe['hasRole'](_0x50a44f('0xa7c'));}}),_0x1e9ce2['saveItem'](_0x295808('0x1c9d'),{'id':0x5de,'title':_0x295808('0x9d3'),'route':'campaign','translate':_0x295808('0x1828'),'state':'app.motiondialer.ivrCampaigns','weight':0x1,'hidden':function(){const _0x5f33db=_0x295808;return _0x3fb6fe[_0x5f33db('0x1ac6')]('agent')||!_0x3fb6fe[_0x5f33db('0x1167')](0x5de)&&!_0x3fb6fe[_0x5f33db('0x1ac6')](_0x5f33db('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x256e'),{'id':0x5e6,'title':'Realtime','route':'','translate':'MOTIONDIALER.REALTIME','state':_0x295808('0x1f08'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x2bcdf4=_0x295808;return _0x3fb6fe[_0x2bcdf4('0x1ac6')](_0x2bcdf4('0x1eff'))||!_0x3fb6fe['hasPermission'](0x5e6)&&!_0x3fb6fe[_0x2bcdf4('0x1ac6')]('admin');}}),_0x1e9ce2['saveItem'](_0x295808('0x275d'),{'id':0x640,'title':_0x295808('0xeae'),'translate':_0x295808('0xe3a'),'icon':_0x295808('0x294'),'weight':0x15,'permissions':{'association':![]},'hidden':function(){const _0x59363d=_0x295808;return _0x3fb6fe[_0x59363d('0x1ac6')](_0x59363d('0x1eff'))||!_0x3fb6fe[_0x59363d('0x1167')](0x640)&&!_0x3fb6fe[_0x59363d('0x1ac6')](_0x59363d('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.help.about',{'id':0x641,'title':_0x295808('0x975'),'route':'','translate':_0x295808('0x1072'),'state':_0x295808('0x333'),'weight':0x1,'hidden':function(){const _0x183be7=_0x295808;return _0x3fb6fe[_0x183be7('0x1ac6')](_0x183be7('0x1eff'))||!_0x3fb6fe[_0x183be7('0x1167')](0x640)&&!_0x3fb6fe['hasRole']('admin');}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.jscripty',{'id':0x6a4,'title':_0x295808('0x179f'),'translate':_0x295808('0x1eb1'),'icon':'icon-script','weight':0xe,'license':_0x295808('0x179f'),'hidden':function(){const _0x1fc481=_0x295808;return!_0x2e643c[_0x1fc481('0x179f')]||_0x3fb6fe[_0x1fc481('0x1ac6')](_0x1fc481('0x1eff'))||!_0x3fb6fe[_0x1fc481('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0x1fc481('0x1ac6')](_0x1fc481('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x2b2'),{'id':0x6a5,'title':_0x295808('0xda5'),'route':_0x295808('0x129b'),'translate':_0x295808('0xd30'),'state':_0x295808('0x37a'),'weight':0x1,'hidden':function(){const _0x2431c7=_0x295808;return _0x3fb6fe[_0x2431c7('0x1ac6')](_0x2431c7('0x1eff'))||!_0x3fb6fe[_0x2431c7('0x1167')](0x6a5)&&!_0x3fb6fe[_0x2431c7('0x1ac6')]('admin');}}),_0x1e9ce2['saveItem']('apps.marketplace',{'id':0x708,'title':_0x295808('0x22b4'),'translate':_0x295808('0x659'),'icon':_0x295808('0x1106'),'weight':0x12,'hidden':function(){const _0x2020df=_0x295808;return _0x3fb6fe[_0x2020df('0x1ac6')](_0x2020df('0x1eff'))||!_0x3fb6fe[_0x2020df('0x1649')](_0x282af1(this))&&!_0x3fb6fe[_0x2020df('0x1ac6')](_0x2020df('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0xc84'),{'id':0x709,'title':_0x295808('0x1893'),'route':'plugin','translate':_0x295808('0x204b'),'state':'app.marketplace.plugins','weight':0x1,'hidden':function(){const _0x47ac60=_0x295808;return _0x3fb6fe[_0x47ac60('0x1ac6')](_0x47ac60('0x1eff'))||!_0x3fb6fe[_0x47ac60('0x1167')](0x709)&&!_0x3fb6fe['hasRole']('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x7aa'),{'id':0x7d0,'title':_0x295808('0xb9f'),'translate':_0x295808('0x203e'),'icon':_0x295808('0x2569'),'weight':0xc,'license':_0x295808('0x158'),'hidden':function(){const _0x4a048c=_0x295808;return!_0x2e643c[_0x4a048c('0x158')]||_0x3fb6fe[_0x4a048c('0x1ac6')](_0x4a048c('0x1eff'))||!_0x3fb6fe['hasChildrenPermissions'](_0x282af1(this))&&!_0x3fb6fe[_0x4a048c('0x1ac6')](_0x4a048c('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x155e'),{'id':0x7d1,'title':_0x295808('0x286d'),'route':'screenRecording','translate':_0x295808('0x9a7'),'state':'app.video.screenRecordings','weight':0x1,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x370a64=_0x295808;return _0x3fb6fe[_0x370a64('0x1ac6')](_0x370a64('0x1eff'))||!_0x3fb6fe[_0x370a64('0x1167')](0x7d1)&&!_0x3fb6fe[_0x370a64('0x1ac6')](_0x370a64('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.whatsapp',{'id':0x834,'title':_0x295808('0x4e5'),'translate':'WHATSAPP.WHATSAPP','icon':_0x295808('0x19b9'),'weight':0xb,'license':_0x295808('0x116e'),'hidden':function(){const _0x23ae93=_0x295808;return!_0x2e643c[_0x23ae93('0x116e')]||_0x3fb6fe[_0x23ae93('0x1ac6')](_0x23ae93('0x1eff'))||!_0x3fb6fe[_0x23ae93('0x1649')](_0x282af1(this))&&!_0x3fb6fe['hasRole'](_0x23ae93('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x201b'),{'id':0x835,'title':_0x295808('0x2727'),'route':_0x295808('0x1bb6'),'translate':_0x295808('0xf6b'),'state':_0x295808('0x1a'),'weight':0x1,'channel':_0x295808('0x116e'),'hidden':function(){const _0x428cf5=_0x295808;return _0x3fb6fe['hasRole'](_0x428cf5('0x1eff'))||!_0x3fb6fe['hasPermission'](0x835)&&!_0x3fb6fe[_0x428cf5('0x1ac6')](_0x428cf5('0xa7c'));}}),_0x1e9ce2[_0x295808('0x13b8')]('apps.whatsapp.whatsappAccounts',{'id':0x836,'title':_0x295808('0x171a'),'route':_0x295808('0xcc5'),'translate':'WHATSAPP.WHATSAPPACCOUNTS','state':_0x295808('0x317'),'weight':0x1,'channel':_0x295808('0x116e'),'hidden':function(){const _0x575177=_0x295808;return _0x3fb6fe[_0x575177('0x1ac6')](_0x575177('0x1eff'))||!_0x3fb6fe[_0x575177('0x1167')](0x836)&&!_0x3fb6fe[_0x575177('0x1ac6')]('admin');}}),_0x1e9ce2[_0x295808('0x13b8')](_0x295808('0x485'),{'id':0x83e,'title':'Realtime','route':'','translate':_0x295808('0x23e9'),'state':_0x295808('0x791'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x13d64f=_0x295808;return _0x3fb6fe[_0x13d64f('0x1ac6')](_0x13d64f('0x1eff'))||!_0x3fb6fe[_0x13d64f('0x1167')](0x83e)&&!_0x3fb6fe[_0x13d64f('0x1ac6')]('admin');}}),_0x1e9ce2['sort'](),_0x20ad22[_0x295808('0x13b8')]('apps',{'title':_0x295808('0x12ef'),'group':!![],'weight':0x1}),_0x20ad22[_0x295808('0x13b8')](_0x295808('0x16b8'),{'id':0x64,'title':_0x295808('0x2772'),'translate':_0x295808('0xddb'),'icon':_0x295808('0x2499'),'weight':0x1}),_0x20ad22['saveItem'](_0x295808('0xf83'),{'id':0x65,'title':'Dashboard','translate':_0x295808('0x22df'),'state':_0x295808('0xba2'),'view':_0x295808('0xba2'),'icon':_0x295808('0x1457'),'iconClass':_0x295808('0x121c'),'weight':0x1,'hidden':function(){const _0x1e1e3b=_0x295808;return!_0x3fb6fe[_0x1e1e3b('0x1167')](0x65);}}),_0x20ad22[_0x295808('0x13b8')](_0x295808('0x826'),{'id':0x66,'title':_0x295808('0x2326'),'translate':'DASHBOARDS.CONTACTS','state':_0x295808('0xca8'),'view':'contacts','icon':'icon-account-circle','iconClass':_0x295808('0x2403'),'weight':0x2,'hidden':function(){return!_0x2e643c['cm']||!_0x3fb6fe['hasPermission'](0x66);}}),_0x20ad22[_0x295808('0x13b8')](_0x295808('0x1e0d'),{'id':0x67,'title':_0x295808('0x2326'),'translate':_0x295808('0x535'),'state':_0x295808('0x114'),'view':_0x295808('0x114'),'icon':_0x295808('0x5a2'),'iconClass':_0x295808('0x2403'),'weight':0x3,'hidden':function(){const _0x5a3ca6=_0x295808;return!_0x2e643c['cm']||!_0x3fb6fe[_0x5a3ca6('0x1167')](0x67);}}),_0x20ad22['saveItem'](_0x295808('0x2061'),{'id':0x71,'title':_0x295808('0x2590'),'translate':_0x295808('0x13d7'),'state':_0x295808('0x2ac'),'view':_0x295808('0x2ac'),'icon':_0x295808('0x86a'),'iconClass':'blue-grey-fg','weight':0x3,'hidden':function(){const _0x586cb6=_0x295808;return!_0x2e643c[_0x586cb6('0x21ee')]||!_0x3fb6fe[_0x586cb6('0x1167')](0x71);}}),_0x20ad22['saveItem'](_0x295808('0x487'),{'id':0x6e,'title':_0x295808('0x334'),'translate':_0x295808('0xbb3'),'state':_0x295808('0x21da'),'view':_0x295808('0x21da'),'icon':'icon-phone','iconClass':'blue-A700-fg','weight':0x4,'hidden':function(){const _0x59b14d=_0x295808;return!_0x2e643c['voice']||!_0x3fb6fe[_0x59b14d('0x1167')](0x6e);}}),_0x20ad22['saveItem'](_0x295808('0x1160'),{'id':0x6f,'title':_0x295808('0x2525'),'translate':'DASHBOARDS.ABANDONED','state':_0x295808('0x183f'),'view':'abandoned','icon':_0x295808('0x172b'),'iconClass':'blue-fg','weight':0x5,'hidden':function(){const _0x4295d7=_0x295808;return!_0x2e643c[_0x4295d7('0x21da')]||!_0x3fb6fe[_0x4295d7('0x1167')](0x6f);}}),_0x20ad22[_0x295808('0x13b8')](_0x295808('0xbe2'),{'id':0x68,'title':_0x295808('0xaff'),'translate':_0x295808('0x142f'),'state':_0x295808('0x1ef3'),'view':_0x295808('0x1ef3'),'icon':_0x295808('0x1207'),'iconClass':_0x295808('0x108b'),'weight':0x6,'hidden':function(){const _0x594b73=_0x295808;return!_0x2e643c['voice']||!_0x3fb6fe[_0x594b73('0x1167')](0x68);}}),_0x20ad22[_0x295808('0x13b8')]('apps.home.chat',{'id':0x69,'title':_0x295808('0x771'),'translate':'DASHBOARDS.CHAT','state':_0x295808('0xde2'),'view':_0x295808('0xde2'),'icon':_0x295808('0xc49'),'iconClass':_0x295808('0x2351'),'weight':0x7,'hidden':function(){const _0xa4fc6=_0x295808;return!_0x2e643c['chat']||!_0x3fb6fe[_0xa4fc6('0x1167')](0x69);}}),_0x20ad22[_0x295808('0x13b8')](_0x295808('0x56a'),{'id':0x6a,'title':_0x295808('0x22e7'),'translate':'DASHBOARDS.MAIL','state':_0x295808('0x1bfa'),'view':_0x295808('0x1bfa'),'icon':_0x295808('0x142d'),'iconClass':_0x295808('0x691'),'weight':0x8,'hidden':function(){const _0x419364=_0x295808;return!_0x2e643c[_0x419364('0x1bfa')]||!_0x3fb6fe[_0x419364('0x1167')](0x6a);}}),_0x20ad22[_0x295808('0x13b8')](_0x295808('0x12d2'),{'id':0x6b,'title':_0x295808('0x21a9'),'translate':'DASHBOARDS.SMS','state':'sms','view':_0x295808('0x146c'),'icon':_0x295808('0x1392'),'iconClass':_0x295808('0x2905'),'weight':0x9,'hidden':function(){const _0x3faa78=_0x295808;return!_0x2e643c[_0x3faa78('0x684')]||!_0x3fb6fe[_0x3faa78('0x1167')](0x6b);}}),_0x20ad22[_0x295808('0x13b8')](_0x295808('0x888'),{'id':0x6c,'title':_0x295808('0x1753'),'translate':_0x295808('0xe30'),'state':_0x295808('0x26c'),'view':_0x295808('0x26c'),'icon':_0x295808('0x2052'),'iconClass':_0x295808('0x11aa'),'weight':0xa,'hidden':function(){const _0x3c1bdb=_0x295808;return!_0x2e643c[_0x3c1bdb('0x26c')]||!_0x3fb6fe[_0x3c1bdb('0x1167')](0x6c);}}),_0x20ad22['saveItem'](_0x295808('0x4b4'),{'id':0x6d,'title':'Fax','translate':'DASHBOARDS.FAX','state':_0x295808('0x1fc7'),'view':_0x295808('0x1fc7'),'icon':'icon-deskphone','iconClass':_0x295808('0x74c'),'weight':0xb,'hidden':function(){const _0x156150=_0x295808;return!_0x2e643c[_0x156150('0x1fc7')]||!_0x3fb6fe[_0x156150('0x1167')](0x6d);}}),_0x20ad22[_0x295808('0x13b8')](_0x295808('0x171'),{'id':0x72,'title':'Whatsapp','translate':'DASHBOARDS.WHATSAPP','state':_0x295808('0x116e'),'view':_0x295808('0x116e'),'icon':_0x295808('0x19b9'),'iconClass':_0x295808('0x1f95'),'weight':0xc,'hidden':function(){return!_0x2e643c['whatsapp']||!_0x3fb6fe['hasPermission'](0x72);}}),_0x49b6a2[_0x295808('0x3d2')](_0x295808('0x1142'),function(_0x373c1b){const _0x198b91=_0x295808;_0x373c1b['targetScope'][_0x198b91('0x3ba')]===_0x49b6a2['$id']&&_0x563b46[_0x198b91('0x1d73')](_0x198b91('0x501'));});}const _0x313e74=_0x986f36;;const _0x30a8b0=['angular-toasty',_0x36e6f4('0x175a'),_0x36e6f4('0x2145'),'app.navigation',_0x36e6f4('0x2099'),_0x36e6f4('0x25aa'),_0x36e6f4('0x10c8'),_0x36e6f4('0x1f05'),'app.dashboards',_0x36e6f4('0x957'),_0x36e6f4('0x1b7b'),_0x36e6f4('0x62'),_0x36e6f4('0xb66'),_0x36e6f4('0x1e3'),_0x36e6f4('0x24f3'),_0x36e6f4('0x1c1'),_0x36e6f4('0x1df6'),_0x36e6f4('0x19af'),'app.callysquare','app.analytics',_0x36e6f4('0x5f2'),_0x36e6f4('0x224e'),'app.motiondialer',_0x36e6f4('0x53a'),'app.jscripty',_0x36e6f4('0x5c1'),'app.plugins',_0x36e6f4('0x443'),_0x36e6f4('0x13c3'),_0x36e6f4('0xf5c'),_0x36e6f4('0x7be'),_0x36e6f4('0x479'),_0x36e6f4('0x2208')];angular[_0x36e6f4('0x896')]('motion',_0x30a8b0)['factory'](_0x36e6f4('0x19e3'),_0x59813b)[_0x36e6f4('0xe11')](_0x3455c1)['controller'](_0x36e6f4('0x725'),_0x11cf39)['filter'](_0x36e6f4('0x1d30'),_0x24ac73)['filter'](_0x36e6f4('0x2564'),_0x18c060)[_0x36e6f4('0x87c')](_0x36e6f4('0x124d'),_0x40f423)[_0x36e6f4('0x87c')]('dateFilterLocalizationFactory',_0x334252)['factory']('Sequence',_0x161677)[_0x36e6f4('0xe11')](_0x361149)[_0x36e6f4('0xca')](_0x2c9654)[_0x36e6f4('0x87c')](_0x36e6f4('0x2661'),_0x2e80d7)[_0x36e6f4('0x75e')](_0x36e6f4('0x1edb'),_0x313e74);},0x1a2c:(_0x553889,_0x37dea7,_0x3e9489)=>{const _0x21aa35=_0x19af2d;var _0x1bb058={'./af':0xae2,'./af.js':0xae2,'./ar':0x363,'./ar-dz':0x1022,'./ar-dz.js':0x1022,'./ar-kw':0x17f7,'./ar-kw.js':0x17f7,'./ar-ly':0x1928,'./ar-ly.js':0x1928,'./ar-ma':0x1e16,'./ar-ma.js':0x1e16,'./ar-sa':0x1798,'./ar-sa.js':0x1798,'./ar-tn':0x1bbc,'./ar-tn.js':0x1bbc,'./ar.js':0x363,'./az':0x43b,'./az.js':0x43b,'./be':0x2650,'./be.js':0x2650,'./bg':0x2092,'./bg.js':0x2092,'./bm':0x1d0e,'./bm.js':0x1d0e,'./bn':0x22c9,'./bn-bd':0x1851,'./bn-bd.js':0x1851,'./bn.js':0x22c9,'./bo':0x618,'./bo.js':0x618,'./br':0x4fe,'./br.js':0x4fe,'./bs':0x26e,'./bs.js':0x26e,'./ca':0x9a4,'./ca.js':0x9a4,'./cs':0x16be,'./cs.js':0x16be,'./cv':0x36d,'./cv.js':0x36d,'./cy':0x1ccd,'./cy.js':0x1ccd,'./da':0x12ac,'./da.js':0x12ac,'./de':0x260c,'./de-at':0xd9,'./de-at.js':0xd9,'./de-ch':0x37e,'./de-ch.js':0x37e,'./de.js':0x260c,'./dv':0x14b4,'./dv.js':0x14b4,'./el':0x345,'./el.js':0x345,'./en-au':0x209c,'./en-au.js':0x209c,'./en-ca':0x1ef5,'./en-ca.js':0x1ef5,'./en-gb':0x8c3,'./en-gb.js':0x8c3,'./en-ie':0x1924,'./en-ie.js':0x1924,'./en-il':0x1c27,'./en-il.js':0x1c27,'./en-in':0x104f,'./en-in.js':0x104f,'./en-nz':0x18af,'./en-nz.js':0x18af,'./en-sg':0x67e,'./en-sg.js':0x67e,'./eo':0xb63,'./eo.js':0xb63,'./es':0x1617,'./es-do':0x1483,'./es-do.js':0x1483,'./es-mx':0x17e0,'./es-mx.js':0x17e0,'./es-us':0x47a,'./es-us.js':0x47a,'./es.js':0x1617,'./et':0x15e3,'./et.js':0x15e3,'./eu':0x1e53,'./eu.js':0x1e53,'./fa':0x1b2f,'./fa.js':0x1b2f,'./fi':0x769,'./fi.js':0x769,'./fil':0x9f5,'./fil.js':0x9f5,'./fo':0x1256,'./fo.js':0x1256,'./fr':0x1176,'./fr-ca':0xbe9,'./fr-ca.js':0xbe9,'./fr-ch':0x91a,'./fr-ch.js':0x91a,'./fr.js':0x1176,'./fy':0x13b4,'./fy.js':0x13b4,'./ga':0x244f,'./ga.js':0x244f,'./gd':0x835,'./gd.js':0x835,'./gl':0x225a,'./gl.js':0x225a,'./gom-deva':0x1ecc,'./gom-deva.js':0x1ecc,'./gom-latn':0xc60,'./gom-latn.js':0xc60,'./gu':0x14e5,'./gu.js':0x14e5,'./he':0x106e,'./he.js':0x106e,'./hi':0x5e,'./hi.js':0x5e,'./hr':0x13c,'./hr.js':0x13c,'./hu':0x85a,'./hu.js':0x85a,'./hy-am':0x58f,'./hy-am.js':0x58f,'./id':0x2402,'./id.js':0x2402,'./is':0x87,'./is.js':0x87,'./it':0x272,'./it-ch':0x96,'./it-ch.js':0x96,'./it.js':0x272,'./ja':0x23df,'./ja.js':0x23df,'./jv':0x10be,'./jv.js':0x10be,'./ka':0x839,'./ka.js':0x839,'./kk':0x1e5c,'./kk.js':0x1e5c,'./km':0x2236,'./km.js':0x2236,'./kn':0x2442,'./kn.js':0x2442,'./ko':0xe92,'./ko.js':0xe92,'./ku':0x580,'./ku.js':0x580,'./ky':0xcdb,'./ky.js':0xcdb,'./lb':0x1ab9,'./lb.js':0x1ab9,'./lo':0x155a,'./lo.js':0x155a,'./lt':0x1b62,'./lt.js':0x1b62,'./lv':0x1dab,'./lv.js':0x1dab,'./me':0x2685,'./me.js':0x2685,'./mi':0x1575,'./mi.js':0x1575,'./mk':0x174e,'./mk.js':0x174e,'./ml':0x1cad,'./ml.js':0x1cad,'./mn':0x13fb,'./mn.js':0x13fb,'./mr':0x172,'./mr.js':0x172,'./ms':0x2677,'./ms-my':0x4d5,'./ms-my.js':0x4d5,'./ms.js':0x2677,'./mt':0x84e,'./mt.js':0x84e,'./my':0x1815,'./my.js':0x1815,'./nb':0x133c,'./nb.js':0x133c,'./ne':0x1a58,'./ne.js':0x1a58,'./nl':0xf3d,'./nl-be':0x2656,'./nl-be.js':0x2656,'./nl.js':0xf3d,'./nn':0xf25,'./nn.js':0xf25,'./oc-lnc':0x857,'./oc-lnc.js':0x857,'./pa-in':0x16e2,'./pa-in.js':0x16e2,'./pl':0x118f,'./pl.js':0x118f,'./pt':0x2530,'./pt-br':0x1f23,'./pt-br.js':0x1f23,'./pt.js':0x2530,'./ro':0x193b,'./ro.js':0x193b,'./ru':0x701,'./ru.js':0x701,'./sd':0x3b6,'./sd.js':0x3b6,'./se':0x1ea,'./se.js':0x1ea,'./si':0x7c,'./si.js':0x7c,'./sk':0x1099,'./sk.js':0x1099,'./sl':0x1379,'./sl.js':0x1379,'./sq':0x450,'./sq.js':0x450,'./sr':0x23ab,'./sr-cyrl':0x26bb,'./sr-cyrl.js':0x26bb,'./sr.js':0x23ab,'./ss':0x1705,'./ss.js':0x1705,'./sv':0x2238,'./sv.js':0x2238,'./sw':0x494,'./sw.js':0x494,'./ta':0x1ca5,'./ta.js':0x1ca5,'./te':0xc26,'./te.js':0xc26,'./tet':0x82f,'./tet.js':0x82f,'./tg':0x1c99,'./tg.js':0x1c99,'./th':0x2351,'./th.js':0x2351,'./tk':0x232d,'./tk.js':0x232d,'./tl-ph':0x1688,'./tl-ph.js':0x1688,'./tlh':0x24e4,'./tlh.js':0x24e4,'./tr':0x95d,'./tr.js':0x95d,'./tzl':0x203e,'./tzl.js':0x203e,'./tzm':0x452,'./tzm-latn':0x2bb,'./tzm-latn.js':0x2bb,'./tzm.js':0x452,'./ug-cn':0x2448,'./ug-cn.js':0x2448,'./uk':0x1e0b,'./uk.js':0x1e0b,'./ur':0xed3,'./ur.js':0xed3,'./uz':0x1a87,'./uz-latn':0x24c,'./uz-latn.js':0x24c,'./uz.js':0x1a87,'./vi':0x1622,'./vi.js':0x1622,'./x-pseudo':0x111a,'./x-pseudo.js':0x111a,'./yo':0x16ad,'./yo.js':0x16ad,'./zh-cn':0xeff,'./zh-cn.js':0xeff,'./zh-hk':0x165e,'./zh-hk.js':0x165e,'./zh-mo':0x264f,'./zh-mo.js':0x264f,'./zh-tw':0x1038,'./zh-tw.js':0x1038};function _0x3b3567(_0x313ea3){var _0x4170e6=_0x41820f(_0x313ea3);return _0x3e9489(_0x4170e6);}function _0x41820f(_0x28b190){const _0x4a298d=a0_0x3f2c;if(!_0x3e9489['o'](_0x1bb058,_0x28b190)){var _0x1d5900=new Error(_0x4a298d('0x1f8')+_0x28b190+'\x27');_0x1d5900[_0x4a298d('0x1af3')]=_0x4a298d('0x357');throw _0x1d5900;}return _0x1bb058[_0x28b190];}_0x3b3567[_0x21aa35('0x14a4')]=function _0x4b51ae(){const _0x842cc8=_0x21aa35;return Object[_0x842cc8('0x14a4')](_0x1bb058);},_0x3b3567['resolve']=_0x41820f,_0x553889[_0x21aa35('0x2c4')]=_0x3b3567,_0x3b3567['id']=0x1a2c;},0x1666:_0x4aa2c0=>{const _0x4e0eb1=_0x19af2d;'use strict';_0x4aa2c0[_0x4e0eb1('0x2c4')]=angular;}},0x0,[[0x2069,0x29a,0x301]]]); \ No newline at end of file diff --git a/public/app-b3578f2c445f491907bd.js b/public/app-b3578f2c445f491907bd.js new file mode 100644 index 0000000..471d3ed --- /dev/null +++ b/public/app-b3578f2c445f491907bd.js @@ -0,0 +1,21 @@ +/*! + * @license + * ************************************************************************* + * * * + * * xCALLY Motion - The Omnichannel Contact Center * + * * Copyright (c) Xenialab s.r.l. All Rights Reserved * + * * * + * ************************************************************************* + * * * + * * Email: info@xcally.com * + * * Website: https://www.xcally.com * + * * * + * ************************************************************************* + * * * + * * The SOFTWARE PRODUCT is protected by copyright laws and international * + * * copyright treaties, as well as other intellectual property laws and * + * * treaties. The SOFTWARE PRODUCT is licensed, not sold. * + * * * + * ************************************************************************* + */ +const a0_0x598e=['ar-LB','uploadState','delete\x20session','\x20properly\x20deleted!','SETTINGS.JIRA_ERROR_MESSAGE','\x20has\x20been\x20done!','smsInteractionTags:save','cmCompany','PausesController\x20as\x20vm','VOICE.NEW_VOICEQUEUE','vm.voiceQueue.joinempty.length\x20===\x201\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27invalid\x27','deleteSelectedDescriptions','VOICE.EDIT_CHANSPY','loadNextPage','Swedish\x20(Sweden)','SYSTEM:GET_INTERVAL','getScreenRecordings','truepriority','MAIL.NEW_MAILCANNEDANSWER','\x22path\x22\x20must\x20be\x20a\x20string\x20(eg.\x20`dashboard.project`)','api.voiceExtension.update','EditFaxAccountAppintervalDialogController','squareProject','enableSettings','refer','deleteSelectedMailAccountMailCannedAnswers','$lte','sms/applications/:id','gotoFaxAccounts','cs-CZ','apps.integrations.dynamics365Accounts','integrations/freshdesk/accounts/:id','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20internalroutes?','icon-minus-circle','selectedZohoConfiguration','MailQueueId','Rounded','grey-fg\x20icon-phone-hangup','src/js/modules/main/apps/fax/views/faxQueues/edit/teamadd/teamadd.html/teamadd.html','rec','Sundanese','addGroup','goto','palette','getJscriptyProjects','Karl\x20(Icelandic,\x20Male)','deleteSubjectConfirm','WHATSAPP.SELECTED_AGENTS','addSections','The\x20salesforceAccount\x20will\x20be\x20deleted.','ChatInteractionId','delete\x20voiceRecording','freshsalesAccounts','Australia/Broken_Hill','selectAllServicenowAccounts','src/js/modules/main/apps/mail/views/mailSubtatuses/create/dialog.html/dialog.html','apps.openchannel','green-300-fg\x20icon-phone-hangup','smsTransferReport','\x27--\x27','opts','msApi::resolveSuccess','Breton','setHours','agentadddialog','CDR(prefix)=noprefix','FreshdeskAccount\x20properly\x20saved!','America/Detroit','excludedOperators','onSave','integrations/zendesk/fields/:id','deleteVoicemail','delete\x20globalCustomField','Geraint','Lotte\x20(Dutch,\x20Female)','CDR(routeid)=','createObjectURL','api.condition.save','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20whatsappCannedAnswers?','hu-HU','setUserStatus','\x27adminOnly\x27','addBlackLists','Report\x20downloaded!','America/Porto_Velho','difference','\x20properly\x20created','AVG\x20(','searchText','app.voice.realtime.agents','America/Rainy_River','saveVoicemail','api.setting.delete','otherwise','Hungarian','QUICKPANEL.INFO','QueueCampaignteamaddController','ckeditor','app.fax.faxAccounts.edit','MAX\x20(','\x27predictive\x27','AgentsVoiceRealtimeController\x20as\x20vm','src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/apps/close/dialog.html/dialog.html','setCurrentUser','Company\x20properly\x20saved!','EditChatWebsiteAppdialogflowDialogController','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20whatsappAccounts?','/vtigerAccounts','scheduleForm','subString','getFaxAccounts','kn-IN','createdAt,updatedAt,id,format,value,type,uniqueid,calleridnum,exten,connectedlinenum,queue,rating,audio,transcribeStatus,UserId','cdr','mailQueue@get','app.integrations.servicenowAccounts','MsTabScrollController','$destroy\x20event\x20fired','America/Indiana/Knox','fresh','countnoanswerretry','createOrEditTrunk','selectChangedAdvanced','integrations/salesforce/accounts/:id/configurations','TOOLBAR.ARABIC','apps.integrations.salesforceAccounts','unhold\x20->\x20session','api.voiceMusicOnHold.delete','chat/interactions/:id/custom_update','chat/reports/queue/describe','delete\x20Lists','Australia/Brisbane','onUnhold\x20->\x20session,\x20data','openchannel/queues/:id/teams','voiceQueuesLog/:id','\x27fewestcalls\x27','SYSTEM:DELETEwhatsappAccount','duplicates','app.dashboards.general.dialer','exportSelectedOpenchannelAccounts','expandAnimation','#2e62b1','runtranscriberuntranscribesentiment','TOOLBAR.POLISH','blue-fg','onForceLogout\x20->\x20data','You\x20must\x20have\x20at\x20least\x20one\x20theme\x20named\x20\x22default\x22','openchannel/reports/queue/describe','id,fullname,role','WhatsappQueue\x20properly\x20created','container','MARKETPLACE.UPLOAD_PLUGIN','Malay\x20(Malaysia)','OutboundRoutesController','TelephoneController','getSmsQueues','HANGUPCAUSE_38','analyticFieldReport','getMailAccounts','\x27opus\x27','finally','app.fax.faxAccounts','https://www.xcally.com/bar/phonebar/autoupdater.xml','openchannel_queue_waiting_interaction:remove','schedules/:id/clone','onSaveChatQueue','apps.voice.internalroutes','SYSTEM:DELETEvoiceMusicOnHold','whatsapp/queues/describe','stateRegistry','urlParse','WhatsappAccount\x20updated!','getPreview','\x27{{voiceMail.mailbox}}@from-voicemail\x27','\x22resource\x22\x20must\x20be\x20an\x20array\x20and\x20it\x20must\x20follow\x20$resource\x20definition','CompanyId','TelephonesVoiceRealtimeController\x20as\x20vm','HeaderController\x20as\x20vm','MsSearchBarController\x20as\x20vm','America/Moncton','/faxAccounts','selectedDynamics365Accounts','agentForm','delete\x20ivrCampaign','originatePreview','src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/dialogflow/dialog.html/dialog.html','selectedMailAccountInteractions','src/js/modules/main/apps/voice/views/chanSpies/create/dialog.html/dialog.html','createOrEditZendeskConfiguration','jira','voiceMusicOnHold','app.sms.realtime.queues','/users','AgentHomeDashboardMultiChannelFaxController','newSalesforceConfiguration','createOrEditContact','Zendesk','\x22\x20target=\x22_self\x22>','KEY_CODE','id=','app.voice','saveInboundRouteApp','internalroute','getOpenchannelAccountApps','SETTINGS.EDIT_CLOUDPROVIDER','height','EditWhatsappAccountAppgotopDialogController','CreateOrEditZohoConfigurationDialogController','originateInProgress','src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/gotop/dialog.html/dialog.html','mail-interaction','isOpen','app.sms.smsAccounts','selectedDispositions','addNewTeam','openchannelTransferReport','onRemoveUserFaxQueue','$rootScope','basename','pop','Tag','sumDuration','voice/mohs/:id','newSmsCannedAnswer','delete\x20Metrics','FaxQueue\x20updated!','tables','filter','SETTINGS.NEW_CUSTOMIZATION','voiceCalls','selectAllTags','Asia/Macau','userProfile','app.mail.mailQueues','The\x20sound\x20will\x20be\x20deleted.','YYYY-MM-DD','updateView','userProfileId','white','subsections','/assets/images/theme-options/horizontal-nav.jpg','CreateOrEditDashboardItemDialogController','attachment','times','UserList','TrunksVoiceRealtimeController','clientEmail','TeamsController','America/Indiana/Marengo','DASHBOARDS.TODAY','Delete\x20ZendeskAccount','Failed\x20to\x20retrieve\x20pm2\x20processes','WHATSAPP.NEW_WHATSAPPACCOUNT','SETTINGS.NEW_CLOUDPROVIDER','reload','Import\x20has\x20been\x20stopped!','rpc@getSmsQueues','saveMailQueue','cloudProvider','deselectMetrics','lastMessageAt','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20zohoAccounts?','turn:','Project\x20deleted!','Unable\x20to\x20convert\x20question','api.variable.update','app.tools.sounds','Are\x20you\x20sure?','getFaxQueuesWaitingInteractions','xml','AgentHomeVoiceDetailsController','api.intFreshsalesConfiguration.save','America/Argentina/Catamarca','success','Safari','DEFAULT\x20PAUSE','saveSquareRecording','\x27/var/opt/motion2/server/files/sounds/converted/{{appdata.save_name}}\x27','anySecondLevelDisposition','motionConfig','onVoiceQueue','deselectWhatsappQueues','Delete\x20SalesforceConfiguration','hues','ChatQueuesController\x20as\x20vm','exportSelectedUsers','addNewPlugin','America/Edmonton','children','busy','networks/:id/clone','toUpper','ChatQueueId','NO_ANSWER','intervalIntervals','Delete\x20User','\x27/var/opt/motion2/server/files/sounds/converted/{{sound.save_name}}\x27','context.name','delete\x20template','Options','List\x20properly\x20created!','user_has_fax_interactions:remove','api.cmList.save','America/Nassau','integrations/sugarcrm/accounts/describe','src/js/modules/navigation/layouts/vertical-navigation/navigation.html/navigation.html','UserChatDashboardGeneralController','chat/applications/:id/clone','mdPickers','onlineForm','addNewFaxQueue','not_inuse','createdAt,updatedAt,id,token,agentIdentifier,customerAlias,messageFontSize,name,key,address,remote,ListId,fidelity,timeout,agentAlias,closingQuestion,formSubmitSuccessMessage,formSubmitFailureMessage,color,color_focus,color_button,textColor,backgroundColor,fontSize,header_shape,showAgentAvatar,showCustomerAvatar,alignment,verticalAlignment,messagesAlignment,defaultTitle,animation,defaultWhiteLabel,whiteLabel,defaultLogo,conditionAgreement,autoclose,enableUnmanagedNote,unmanagedMessage,skipUnmanaged,sendUnmanaged,enableCustomerWriting,waitingTitle,waitingMessage,closingMessage,noteTitle,placeholderMessage,skipMessageButton,enableRating,ratingType,ratingStarsNumber,enableFeedback,feedbackTitle,forwardTranscript,forwardTranscriptMessage,closingMessageButton,download_transcript,enableCustomerAttachment,enableSendButton,enableCustomerCheckmarks,systemAlias,enquiry_enable,enquiry_forwarding,enquiry_forwarding_address,name_title,username_placeholder,email_title,email_placeholder,header_online,hideWhenOffline,header_offline,start_chat_button,offline_chat_button,offlineMessageSubject,offlineMessageBody,offline_message,message_title,enquiry_message_placeholder,enquiry_button,rating_message,rating_send,rating_skip,onlineForm,offlineForm,mapKey,mapKeyOffline,forwardOffline,forwardOfflineAddress,IntervalId,timezone,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout,vidaooEscalation,vidaooApiKey','testtestOdbc','ChatWebsite\x20updated!','getFolded','onaddstream','sat','toUpperCase','INTEGRATIONS.NEW_SERVICENOWCONFIGURATION','Galician\x20(Spain)','createdAt,updatedAt,id,name,key,token,replyUri,ListId,waitForTheAssignedAgent,mapKey,mandatoryDisposition,mandatoryDispositionPauseId,description,receiveUri,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','html','invoke','speakerVolume','Delete\x20FreshsalesConfiguration','servicenowAccount','Zulu','cm/contacts/:id/hoppers','MIN\x20(','smsQueuesTotal','fax/accounts/describe','src/js/modules/main/apps/chat/views/chatWebsites/create/dialog.html/dialog.html','ngFlowOptions','Delete\x20ChatQueue','unmute','America/Merida','SYSTEM:GETtrunks','Pacific/Port_Moresby','top-right','CreateOrEditFreshdeskAccountItemDialogController','Email\x20Interaction','smsInteractionDownload','Edited','record','INTEGRATIONS.EDIT_ZENDESKACCOUNT','deleteSelectedFreshdeskAccounts','src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/agi/dialog.html/dialog.html','src/js/modules/main/apps/mail/views/mailQueues/edit/agentadd/agentadd.html/agentadd.html','onSaveUserOpenchannelQueue','found','trustAsHtml','CONTACTMANAGER.COPY_CONTACT','newChatQueue','pause','addNewInboundRoute','addNewSmsCannedAnswer','moveSelectedIvrCampaignHopperFinals','schedules','currentPage','es-CR','delete\x20trunk','ar-OM','Asia/Novosibirsk','openchannelQueues','contentWithToolbar','$pristine','selectedFaxAccountInteractions','Dynamics365Account\x20properly\x20tested','src/js/modules/main/apps/sms/views/realtime/realtime.html/realtime.html','Error\x20creating\x20queue!','CreateOrEditAnyConditionDialogController','COUNT','createdAt,updatedAt,id,appdata,type,exten,context,description','tail','/reports','webrtc::settings','getMailSubstatuses','Thai','SEC_TO_TIME\x20(','saveMetric','eu-west-3','onIntegrationAccountSelection','addContacts','createdAt,updatedAt,id,appdata,type,exten,context,recordingFormat,cutdigits,description','openchannel/interactions/:id','ms-nav','currentSidebarTab','\x27ap-southeast-2\x27','minimize','Twi','.mp4','\x27peer\x27','getCustomFields','America/Grand_Turk','updateAccountApplications','api/users/','CustomDashboard\x20properly\x20deleted!','$startsWith','InternalRouteController','dddd','\x27token\x27','QueueId','onInteractionOpen','TOOLBAR.ITALIAN','setLockedItem','icon-format-text','America/Phoenix','The\x20pause\x20will\x20be\x20deleted.','src/js/modules/core/directives/ms-phonebar/record/dialog.html/dialog.html','app.dashboards.general.whatsapp','SmsQueueteamaddController','api.jscriptyProject.save','integrations/dynamics365/configurations/:id/clone','src/js/modules/main/apps/voice/views/voicePrefixes/edit/agentadd/agentadd.html/agentadd.html','\x27comedia\x27','mailInteractions','exportSelectedFreshdeskAccounts','api.intFreshdeskConfiguration.delete','onSaveChatQueueChannel','integrations/freshdesk/fields/:id/clone','src/js/modules/main/apps/integrations/views/deskAccounts/edit/view.html/view.html','sms_account_id','UsersController\x20as\x20vm','constant','autocomplete','newWindow','TAB','integrations/freshsales/fields/describe','deleteZendeskConfiguration','TOOLS.NOTIFICATIONS.CONDITION_SAVED_SUCCESS_TITLE','arrayannounce_position','apps.tools','cm/contacts/upload','sortable','Delete\x20action','\x27tcp\x27','applyFilter','getSquareRecordings','removeAgents','TOOLS.NOTIFICATIONS.DISPOSITIONS_DELETE_TITLE','IvrCampaign\x20properly\x20created','composeInteraction','@autocomplete','apikeymanagerdialog','teams','TriggerAllConditionsController','Lithuanian\x20(Lithuania)','Util','delete\x20mailAccount','SYSTEM:GETcampaign','newSugarcrmAccount','DISPOSITION_DELETE_MESSAGE','STAFF.EDIT_USER','The\x20array\x20must\x20have\x203\x20or\x204\x20colors.','\x27cdr\x27','\x20properly\x20hangup!','mailCannedAnswer','adminUrl','selectedChatQueues','awsPollyVoice','lastLoginAt','getMonth','TOOLS.NEW_VARIABLE','pause@get','downloadMessage','exportSelectedInboundRoutes','saveOrPublishProject','vi-VN','newTrigger','shortTime','rpcWhatsappQueues','Schedule\x20properly\x20deleted!','selectedTeams','CampaignId','SMS.ALL_TEAMS','whatsapp/applications/:id/clone','createdAt,updatedAt,id,interactionid,channel,format,value,rating,UserId,duration,startedAt,closedAt','STAFF.ALL_QUEUES_','European\x20Italian\x20Male','ChatWebsiteagentAvatarController','Chrome','mailCannedAnswer\x20#','login','msVerticalStepper','isDefined','Catalan\x20(Catalan)','delete\x20interval','OpenchannelAccount\x20properly\x20created','arraycrudPermissions','nl-NL','metrics','capacity','sidebar','msNavigationHorizontal','EditOpenchannelAccountApp','uploading','$animate','delete\x20SalesforceAccounts','sendDTMF','integrations/freshsales/configurations/describe','deleteMailCannedAnswer','src/js/modules/main/apps/staff/views/telephones/telephones.html/telephones.html','showDialpad','Last\x20Year','Hangup_Cause','null','\x27all\x27','Medium','-03:30','webbar:hangup','AgentHomeSmsController','Europe/Prague','src/js/modules/main/apps/marketplace/views/plugins/edit/view.html/view.html','OpenchannelAccountsController','addNewMetric','cmn-Hant-TW','arrayextensionMonitor','exportSelectedPauses','zohoAccount','getIntervals','Years','columnWidth','allowEdit','msRecording','Asia/Hovd','whatsapp/applications/describe','A100','src/js/modules/main/apps/integrations/views/zendeskAccounts/create/dialog.html/dialog.html','integrations/vtiger/fields/describe','Asia/Kolkata','integrations/freshdesk/configurations/:id/clone','voice/transfers/reports/:id','/api/transfer?number=','exportSelectedPlugins','OpenchannelQueuesController\x20as\x20vm','autocompleteRequireMatch','userWhatsappQueue:remove','SmsQueueagentaddController','setItem','addContactTab','MAIL.MAILACCOUNTS','api.dashboard.save','every','|{color:red}','Smtp','INTEGRATIONS.ZOHOACCOUNTS','userMailQueue:remove','users/:id/whatsapp_interactions','resetlistdialog','Quechua','300','tab-container','whatsappMessage:update','getTelephones','/pauses','newSmtp','id,name,crudPermissions','autoAssociation','uisref','selectedServicenowConfiguration','voicePrefixes','ChatWebsitecustomerAvatarController','openchannelInteractionTags:save','thirdLevel','Norwegian\x20(Nynorsk)','wav49','America/Glace_Bay','AppZone','ms-tab-scroll','kind','integrations/zendesk/configurations/:id/clone','selectedQueueCampaigns','errors','DASHBOARDS.FEBRUARY','SYSTEM:GETsetting','#F44336','getFirstAvailableContact','src/js/modules/main/apps/integrations/views/zohoAccounts/edit/view.html/view.html','api.intFreshdeskAccount.save','callNumber','voiceQueueReport:save','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20applications?','Error500Controller\x20as\x20vm','getSelectedVariable','journey','srcObject','TCL:\x20\x20path','onUpdateMailInteraction','MAIL.MAIL','src/js/modules/main/apps/whatsapp/views/whatsappQueues/create/dialog.html/dialog.html','Reset\x20Succesfull','\x27alternate\x27','Armenian','\x27limit\x27','MAIL.NEW_MAILSUBSTATUS','removeSound','You\x20can\x27t\x20reply\x20or\x20send\x20an\x20email.\x20Please\x20contact\x20the\x20administrator!','\x20ORDER\x20BY\x20','id,alias','getTracks','QueueNotify','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/agi/dialog.html/dialog.html','removeByInteraction','The\x20component\x20will\x20be\x20deleted.','editDraft','intZendeskAccount','cm/hopper_black/describe','CKEDITOR','src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/gotop/dialog.html/dialog.html','createdAt','/attachment_download?attachId=','dashboard','SmsAccount','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20companies?','tabs','section','ms-nav-title','getOpenchannelQueuesWaitingInteractions','{color}|*','app.settings','propertiesExtra','onSaveFaxInteraction','U(xcally-mixmonitor-context)','SMS.SMS','api.jira','ContactController\x20as\x20vm','NO\x20AUTH','rpc@getFaxQueues','src/js/modules/main/apps/sms/views/smsQueues/edit/view.html/view.html','addNewSmsQueue','chat/reports/transfer/describe','ChatCannedAnswer\x20properly\x20saved!','SoundsController\x20as\x20vm','Europe/Sofia','Brian\x20(English,\x20British,\x20Male)','Asia/Aqtobe','months','\x27info\x27','/accounts','addNewFreshdeskAccount','users/:id/whatsapp/interactions','createOrEditVtigerAccount','TOOLS.NOTIFICATIONS.CONDITION_DELETED_SUCCESS_TITLE','onSaveVoiceQueue','\x27udp\x27','brportuguesefemale','Company','apps.staff.users','src/js/modules/main/apps/tools/views/tags/tags.html/tags.html','faxMessage','MailAccountId','deleteSugarcrmAccount','America/Guyana','getResponseSheetHeaders','Dora\x20(Icelandic,\x20Female)','verticalNavigation','pcConfig','show','platform','\x27linear\x27','isEstablished','Scots\x20Gaelic','getSalesforceConfiguration','red-300-fg\x20icon-close-circle','g726','\x27zh-TW\x27','analytics/default_reports/:id/preview','outboundrouteApp','voice_queue:save','Indian/Christmas','getVoicemails','Report\x20saved!','TOOLS.DISPOSITIONS','selectAllFreshdeskAccounts','EditSmsAccountApp','Ivy','progress','English\x20(Great\x20Britain)','onRemoveSmsQueueChannel','paginatedInteractions','src/js/modules/main/apps/dashboards/views/general/user/sms/user.general.sms.html/user.general.sms.html','displayCannedAnswerInput','api.faxQueue.delete','Latvian\x20(Latvia)','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20servicenowAccounts?','
TODO\x20legend\x20status\x20+\x20state
','List\x20name','assigned','createOrEditOpenchannelAccountOpenchannelCannedAnswer','hy-AM','getIvrCampaignHopperBlacks','.html','CreateOrEditSmtpDialogController','CONTACTMANAGER.NEW_CONTACT','src/js/modules/main/apps/integrations/views/sugarcrmAccounts/edit/view.html/view.html','Queue','failed','Antarctica/Troll','saveProject','app/main/apps/plugins','selectAllScreenRecordings','gotoOutboundRoutes','WHATSAPP.EDIT_WHATSAPPACCOUNT','integrations/desk/fields/:id/clone','SYSTEM:GETinterval','app.voice.voicePrefixes','smsCapacity','userOpenchannelQueue:save','readAsText','OPENCHANNEL.NEW_OPENCHANNELQUEUE','motion2.home.','currentConferenceSessions','whatsappInteraction:update','UNKNOWN','delete\x20subject','NotificationController','Trunk\x20properly\x20saved!','deselectTriggers','UserSmsAccount','voicemailMessages','apiName','\x27whatsapp_accounts\x27','importReport','QueueCampaignlistaddController','Notification\x20creating\x20error','openchannelCapacity','app.integrations.zohoAccounts.edit','SugarcrmAccount\x20properly\x20tested','api.disposition.update','deleteSelectedMailAccounts','The\x20voicemail\x20will\x20be\x20deleted.','grey-A400-bg','isStepNumberValid','UsersController','createOrEditMotionDialerQueue','50\x20100\x20200\x20A100','mail/accounts/:id/dispositions','Interval\x20has\x20been\x20saved!','ms-masonry-item','api.campaign.save','FaxAccountController\x20as\x20vm','$setDirty','vm_dc.query.filter','sum','red','Finnish','Pirate','STAFF.PERMISSIONS_ALL_RESOURCES','General','Dynamics365Configuration\x20properly\x20deleted!','ANALYTICS.EDIT_EXTRACTEDREPORT','Tigrinya','/queue_params','integrations/salesforce/accounts/:id','src/js/modules/main/apps/dashboards/views/general/agent/agent.general.html/agent.general.html','','Catalan','complete','flip','src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/listadd/listadd.html/listadd.html','selectedOpenchannelAccountApps','FORGOTPASSWORD.PASSWORD_RESET_ERROR','/freshdeskAccounts','saveFreshdeskAccount','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20mailAccounts?','colors','src/js/modules/main/apps/jscripty/views/projects/edit/view.html/view.html','createOrEditExtractedReport','voiceQueueReport','emojioneArea','app.errors.error-404','motion2.home.openchannel:','listOrder','CreateOrEditTriggerDialogController','Delete\x20WhatsappCannedAnswer','Atlantic/Azores','InboundRoute\x20updated!','version/reset','globalStatusTime','chat','MALE','#2d323e','getSmsQueuesWaitingInteractions','selectedFaxAccountApps','onEnableAutomaticScreenRecordingSelection','app.voice.chanSpies','\x27twilio\x27','Command','mailAccountInteractions','CreateOrEditServicenowAccountItemDialogController','MAILACCOUNT:SEND','ChatWebsitesController\x20as\x20vm','md-','\x27openchannel_interactions\x27','VoiceRealtimeController\x20as\x20vm','Pacific/Efate','Edge','VOICE.EDIT_VOICEMAIL','Sinhalese','deleteChatWebsiteChatCannedAnswer','src/js/modules/header/layouts/vertical-navigation/header.html/header.html','MergeContactDialogController','Context','deleteSelectedSugarcrmAccounts','Allowing\x20disposition\x20for\x20call\x20%s','America/Manaus','app.motiondialer.ivrCampaigns.edit','Swahili\x20(Kenya)','createOrEditChatWebsiteOfflineMessage','OpenchannelQueue\x20properly\x20deleted!','removeItem','api.intDeskConfiguration.update','uselessFields','tag','setting@get','selectedCompanies','deselectVoicePrefixes','runReport','getActions','rpc@getFaxAccounts','\x27alpha\x27','deleteSmsAccountInteraction','Unlicensed','CreateOrEditListDialogController','src/js/modules/main/apps/motiondialer/views/ivrCampaigns/edit/resetlist/resetlist.html/resetlist.html','transcribeStatus','icon-account-multiple','PM2\x20process\x20not\x20found!','FreshsalesAccount\x20properly\x20saved!','idField','delete\x20VoiceQueues','DASHBOARDS.MON','Project','src/js/modules/main/apps/whatsapp/views/whatsappQueues/edit/teamadd/teamadd.html/teamadd.html','createOrEditTriggerAction','en-AU','disable','counter','runTranscribe','fax/applications/:id/clone','WhatsappInteractionId','arrayshowWebBar','freshsalesConfiguration','api.campaign.clone','CHAT.NEW_CHATPROACTIVEACTION','erlangCallToSecond','apps.home.chat','#616161','Kurdish','app.motiondialer.realtime.abandonedcalls','integrations/sugarcrm/configurations/:id/fields','app.tools.intervals.edit','addInteractionTab','getFields','selectedFreshsalesAccounts','GET_TEMPLATE','VOICE.RUNTRANSCRIBESENTIMENT_VOICERECORDING','CSV\x20stop\x20import\x20process\x20failed!','downloadfile2','queueCampaignHopperHistories','America/Campo_Grande','SmsCannedAnswer\x20deleted!','Pacific/Guam','integrations/servicenow/accounts/:id/configurations','Contact\x20ID\x20','volume','\x2741\x27','ssml','exportSelectedSmsAccounts','openchannelStatus','mailAccount@get','Indian/Cocos','api.openchannel.account','GlobalCustomFields','hopper\x20#','motion2.user:','DASHBOARDS.SELECT_SUBSTATUS','$apply','whatsapp/queues/:id/members','SmsInteractionId','webbar:answer','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/custom/dialog.html/dialog.html','s:\x20Skip\x20the\x20playback\x20of\x20the\x20channel\x20type\x20(i.e.\x20SIP,\x20IAX,\x20etc)\x20when\x20speaking\x20the\x20selected\x20channel\x20name.','CONTACTMANAGER.EDIT_COMPANY','selectedTriggerAnyConditions','api.pm2.update','onConfirmed\x20->\x20session,\x20data','src/js/modules/main/apps/settings/views/license/update/dialog.html/dialog.html','attrSerie','getNavigation','deleteIvrCampaign','sessions','MusicOnHoldMohSoundsController','whatsapp/accounts/:id/dispositions','EditSmsAccountAppsystemDialogController','pm2','addNewChatCannedAnswer','plugin:save','survey','STAFF.EDIT_TEAM','CONTACTMANAGER.GLOBALCUSTOMFIELDS','app.fax.realtime.trunks','realtime','Antarctica/Syowa','updating','integrations/freshdesk/fields/describe','ChatQueueController\x20as\x20vm','api.template.save','api.analyticFieldReport.save','switch','integrationTab','getAgentStatus','loadLastMessage','selectedVoicemails','ChatWebsiteofflineFormController','app.settings.smtps','squareOdbc@get','VOICE.OUTBOUND','ORDER\x20BY\x20','queues','angular-toasty','src/js/modules/main/apps/motiondialer/views/queueCampaigns/queueCampaigns.html/queueCampaigns.html','api/cm/contacts/upload','cm/hopper_black/:id/clone','AccountId','\x27uk\x27','Realtime','es-MX','OutboundRoutes','Online','MailSubstatusesController\x20as\x20vm','src/js/modules/main/apps/motiondialer/views/realtime/queue_calls/view.html/view.html','api.squareOdbc.update','deleteCustomField','insertHtml','uploadPlugins','tree','\x27IN\x27','QueueCampaigncloneController','DASHBOARDS.CALL_DISPOSED','orderBy','Century\x20Gothic,Futura,Didact\x20Gothic,san-serif','pdf','icon-playlist-plus','MsWidgetController','WhatsappRealtimeController\x20as\x20vm','first','SYSTEM:PAUSEUSER','exportSelectedIvrCampaignHopperHistories','teal','$timeout','uniqueid,calleridnum,statedesc,starttime,disposition,secondDisposition,thirdDisposition','getMessagesAlignment','SYSTEM:GETintServicenowAccount','selectedOutboundRouteApps','Openchannel\x20Report\x20Queue','strict','UploadSoundDialogController','The\x20mohSound\x20will\x20be\x20deleted.','motion-paleblue','Africa/Tripoli','Browser\x20notifications\x20are\x20not\x20supported\x20by\x20the\x20browser.\x20Normal\x20notifications\x20will\x20be\x20used.','completed','VoicePrefixesController','/sms','previousStep','QueueCampaignHopperStatisticsController','patchConference','deleteMetric','app.whatsapp.realtime','saveMailSubstatus','refer\x20->\x20session','setupSteps','selectedFields','createdAt,updatedAt,id,name,level,ParentId','whatsapp.whatsappAccounts','integrations/desk/accounts/:id/fields','api.template.delete','msNavigation::collapse','SYSTEM:UPDATEVOICECALLREPORT','FAX.NEW_FAXACCOUNT','addTrack','canSelect','$digest','arrayauthType','Lowest','square/odbc/:id/clone','Africa/Casablanca','isDraft','zendeskAccounts','Error\x20creating\x20list!','LocalNET','Portuguese','delete\x20OpenchannelQueues','Delete\x20Template','The\x20chatWebsite\x20will\x20be\x20deleted.','selectedIntervals','api.intSugarcrmAccount.save','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20agent?','src/js/modules/main/apps/integrations/views/servicenowAccounts/create/dialog.html/dialog.html','onSaveFaxQueue','api.intServicenowAccount.save','vm.voiceQueue.joinempty.length\x20===\x201\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27wrapup\x27','exportSelectedTemplates','TOOLS.EDIT_PAUSE','ready','\x20succeded!','newContext','fr-CA','SmsAccounts','Project\x20updated!','areaText','voiceCallReport','Away','saveOpenchannelAccount','SYSTEM:UPDATECONFIGURATIONFIELD','newDeskConfiguration','IndexController','WebReportDialogController','createOrEditDeskConfiguration','MetricsController','api.intDynamics365Account.save','#21467e','responsive','openchannel_queue_waiting_interaction:save','SYSTEM:DELETEvoiceChanSpy','Europe/Rome','apps','UserProfile\x20updated!','api.chatWebsite.delete','ap-south-1','spy','IvrCampaignlistaddController','plugin_','Delete\x20MailSubstatus','Delete\x20ChatWebsite','src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/agent/dialog.html/dialog.html','Asia/Shanghai','America/Argentina/La_Rioja','GlobalCustomField\x20properly\x20saved!','integrations/freshsales/accounts/:id/configurations','addNewServicenowAccount','$locationProvider','Minutes','active','faxAccountInteractions','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20mailCannedAnswers?','step','api.userProfile.update','delete\x20ZendeskAccounts','Brazilian','selectedTriggerActions','The\x20project\x20will\x20be\x20deleted.','userProfileSection@get','$id','selectedIvrCampaignHopperHistories','onVoiceChannelRemove\x20->\x20\x20key,\x20tab,\x20tab.calls','getVtigerAccounts','Notification','selectedSugarcrmConfiguration','Pacific/Guadalcanal','api.analyticExtractedReport.save','\x27chat_messages\x27','rpc@getAgents','stopping','onVoiceChannelRemove\x20->\x20evt','selectedIndex','Spanish\x20(Guatemala)','get_node','cellName','chat_queue_waiting_interaction:remove','onSaveVoiceQueueReport','rpcChatQueuesWaitingInteractions','EditInternalApphangupDialogController','testtestintegrationaccount','+13:00','select_node','Voice','intServicenowAccount@get','leave','abandonedCalls','users/:id/avatar','SYSTEM:DELETEfaxAccount','arraytimeoutrestart','ANALYTICS.REPORTS','Are\x20you\x20sure\x20want\x20to\x20uninstall\x20the\x20plugin?','\x20will\x20be\x20overwritten\x20by\x20the\x20fields\x20of\x20the\x20contact\x20#','Type\x20the\x20file\x20name.','FAX.FAXACCOUNTS','newInternalRoute','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20cloudProviders?','map','deleteUser','EditoutboundApp','Macedonian','onStart','chatInteraction@get','shortcuts','ar-TN','isSupported','DASHBOARDS.READ','newWhatsappCannedAnswer','SYSTEM:GETagents','SYSTEM:GETvariables','$eq','calls','Russian\x20(Russia)','INTEGRATIONS.EDIT_SUGARCRMACCOUNT','300\x20400','onChangeVisibility','app.callysquare.odbcs','squareOdbc','saveInboundRoute','ANALYTICS.EXTRACTEDREPORTS','Call\x20Report','America/Yellowknife','integrations/freshsales/configurations/:id','getResponseSheet','md-no-ink','SYSTEM:DELETEpause','=>%3B=','year','100','selectedSalesforceConfiguration','inboundrouteApp','$onInit','America/Chihuahua','List\x20updated!','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20outboundroutes?','voiceRecordings','getFreshsalesConfiguration','onSaveMember','src/js/modules/main/apps/chat/views/chatWebsites/edit/offlineMessages/dialog.html/dialog.html','Asia/Kabul','eu-ES','installplugin','endOf','Belarusian','ngclipboard','user:agentcomplete','\x27report_call\x27','api.intDynamics365Configuration.save','api.analyticReport.save','arraysmsMethod','trigger:browser:popup','gotoPlugins','deleteInboundRouteApp','newExtractedReport','users','rfc2833','api.telephone.changePassword','src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/blacklistadd/blacklistadd.html/blacklistadd.html','id,fullname,internal','vm.voiceQueue.joinempty.length\x20===\x201\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27yes\x27','Error\x20creating\x20company!','delete\x20Odbcs','ms-navigation-folded-open','$valid','ckEditorInstance','integrations/vtiger/accounts/:id/configurations','downloadWhatsappInteraction','openchannelCannedAnswers','block','app.integrations.dynamics365Accounts.edit','AgentReject','ProjectSessionsController','SYSTEM:COPYREPORT','newItem','src/js/modules/core/directives/ms-widget-engine/ms-widget-engine.html/ms-widget-engine.html','SYSTEM:GET','sms/interactions/:id/clone','getTriggerActions','en-GB','icon-keyboard','List\x20properly\x20created','OpenchannelQueues','ui.router.state.events','ZohoConfiguration\x20deleted!','api.contact.update','SYSTEM:DELETEteam','MAIL.EDIT_','userProfiles/:id/sections','setNavigationScope','integrations/salesforce/configurations/:id/fields','getVoiceQueuesChannelRedirect','exportSelectedChatWebsiteProactiveActions','Mathieu\x20(French,\x20Male)','mainForm','mail/messages/:id/accept','integration','ShowMessageInfoDialogController','src/js/modules/main/apps/tools/views/pauses/create/dialog.html/dialog.html','app.quick-panel','remove','HH:mm','isPause','TOOLS.CLONE_TRUNK','removeCookies','exportSelectedLists','selectedContact','app.fax.realtime.agents','cmn-Hans-CN','AgentsOpenchannelRealtimeController','newCustomField','saveAllCondition','createOrEditUserProfile','Inactive','microphone','moveContactsIvrCampaignHopperFinal','The\x20','iframe','EditInternalAppcustomDialogController','INTEGRATIONS.NEW_DESKACCOUNT','hideStep','dial','openchannelQueue:remove','src/js/modules/main/apps/integrations/views/freshsalesAccounts/freshsalesAccounts.html/freshsalesAccounts.html','proactive','teams/:id/clone','privateKey','addApi','getWhatsappAccountApps','selectedMailAccountMailCannedAnswers','Asia/Pyongyang','English\x20(US)','Salli','ilbc','from-voip-provider','SYSTEM:GETUSERS','UserOpenchannelDashboardGeneralController','showInfo','getDescriptions','orange-A700-bg','Klingon','America/Belize','polling','closeReportDialog','euritalianmale','api.plugin.update','sms/messages/:id','America/Kentucky/Monticello','unionBy','udp','voice/mohs/:id/sounds/:id2','api.tag.save','src/js/modules/main/apps/integrations/views/sugarcrmAccounts/create/dialog.html/dialog.html','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20application?','Asia\x20Pacific\x20(Seoul)','cafrenchmale','Comic\x20Sans\x20MS','MOTIONDIALER.ALL_LISTS','voiceQueues','showMessageInfo','api/attachments','Key','cm/contacts/:id/clone','whatsappInteraction:save','IS\x20NOT\x20EMPTY','Version','monitor','jabraSession','exportSelectedAiTools','INTEGRATIONS.SUGARCRMACCOUNTS','\x27pt\x27','French\x20(France)','deletechanSpy','DASHBOARDS.DRAFT_SAVE_WARNING_MESSAGE','onSaveChatInteraction','selectAllOpenchannelAccounts','SYSTEM:DELETEcmCompany','English\x20(Philippines)','es-VE','onload','contrast3','mail/accounts/:id/in_servers','deleteChatWebsiteOfflineMessage','disposition','cloudProviders/:id/clone','apps.analytics.extractedReports','apr','src/js/modules/core/directives/ms-navigation/templates/horizontal.html/horizontal.html','api.analyticReportField.delete','chatInteraction:save','ExtractedReportsController\x20as\x20vm','+04:00','defer','api.analyticExtractedReport.update','rurussianfemale','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20node?','onResultClick','user:forcelogout','\x20will\x20be\x20restored.','vm.agent.showWebBar\x20==\x201','ZohoAccountController\x20as\x20vm','CreateOrEditFreshdeskAccountDialogController','app.analytics','AgentGeneralPopupController','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20offlineMessage?','Tools','src/js/modules/main/apps/motiondialer/views/realtime/queues/view.html/view.html','getSmsAccountLabel','\x27files\x27','createOrEditscreenRecording','exportSelectedOpenchannelAccountInteractions','/musiconholds','es-ES','Dynamics365Configuration\x20properly\x20created','eurportuguesemale','Asia/Chita','openchannel/accounts/:id/send','differenceBy','app.mail.realtime.queues','Message:update','whatsappCannedAnswer\x20#','ChatWebsiteagentaddController','startTimeAttr','apps.chat.chatQueues','msHorizontalStepper','.results','chat/queues/:id','disposeCall','parentDisposition','Contact\x20updated!','app.voice.realtime.abandonedcalls','addNewHopper','vm.queueCampaign.dialMethod\x20===\x20\x27booked\x27','src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/apps/gotoif/dialog.html/dialog.html','Turkish\x20(Turkey)','Asia/Tashkent','The\x20report\x20will\x20be\x20deleted.','DASHBOARDS.ALL','Teams\x20association\x20has\x20been\x20updated!','Vietnamese','src/js/modules/core/directives/ms-click-to-call/ms-click-to-call.html/ms-click-to-call.html','InboundRoutesController','msShortcuts','Romanian','VoiceRecordingsController','browser','src/js/modules/main/apps/chat/views/chatWebsites/edit/proactive/dialog.html/dialog.html','ServicenowConfiguration\x20properly\x20deleted!','agentUrl','src/js/modules/core/directives/ms-phonebar/referAttended/dialog.html/dialog.html','gotoLastStep','\x27h264\x27','saveWhatsappQueue','Trunks','SYSTEM:DELETEintSalesforceAccount','queryFinal.filter','da-DK','opt2','src/js/modules/main/apps/voice/views/internalroutes/edit/view.html/view.html','delete\x20list','memberReport','apps.integrations.sugarcrmAccounts','The\x20odbc\x20will\x20be\x20deleted.','src/js/modules/main/apps/motiondialer/views/realtime/queue_params/view.html/view.html','EditSmsAccountAppgotoifDialogController','selectedQueueCampaignHopperHistories','deleteChatQueue','isEqual','voice/agents/reports/describe','VOICE.EDIT_VOICEPREFIX','defaultHeaderWhiteLabel','apps.plugins.plugin_','TIMEOUT','delete\x20hopperHistories','deleteSmsAccount','src/js/modules/main/apps/settings/views/smtps/smtps.html/smtps.html','checkbox','America/Havana','Indian/Mauritius','src/js/modules/main/apps/dashboards/views/general/user/mail/user.general.mail.html/user.general.mail.html','/outbound_calls','dashboarditem','port','app.staff.telephones.edit','Delete\x20actions','onPause','deleteSelectedAgents','MailSubstatus\x20properly\x20created','SYSTEM:GETcmList','browserVersion','ChatWebsitesController','\x27rrmemory\x27','motion2.home.abandoned.voice.calls:','ivrCampaignHopperFinals','smsInteraction:update','api.cmCustomField.delete','getInfo','apiResolver','intZohoAccount@get','deleteTrunk','VOICE.SELECT_TYPE','Korean\x20(South\x20Korea)','rpcWhatsappQueuesWaitingInteractions','getMailQueues','$destroy','chat/websites/:id/canned_answers','SYSTEM:GET_PAUSES','src/js/modules/auth/services/hotdesk/dialog.html/dialog.html','Delete\x20Company','enableUncompleteSave','CALLYSQUARE.EDIT_SQUARERECORDING','hopperBlack','addNewUserProfile','icon-calendar-clock','reports','src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/tag/dialog.html/dialog.html','JSCRIPTY.EDIT_PROJECT','schedules/:id/run','Jscripty\x20Questions','DeskAccount','Preview','getQueues','Wide','api.sound.update','src/js/modules/main/apps/dashboards/views/general/user/user.general.html/user.general.html','.json','selectedAiTools','anyThirdLevelDisposition','hasBlackLists','api.intVtigerConfiguration.update','outboundDial','CreateOrEditSquareProjectDialogController','AgentHomePluginsController','DropRate','onActionInit','deselectSugarcrmAccounts','interval\x20#','ddays','rgba','\x27ringing\x27','called','g722','Dialer\x20Hopper\x20Logs','outboundCongestionCallsDay','selectedIvrCampaignHoppers','generate','\x27chat_websites\x27','analytics/extracted_reports/:id/download','The\x20plugin\x20will\x20be\x20deleted.','deleteVtigerAccount','Africa/Ndjamena','userSmsQueue:remove','Male','\x27friend\x27','destcalleridnum','getDynamics365Configuration','getDynamics365Accounts','cloudProviders','\x20has\x20been\x20run!','CallySquare','VOICE.CANT_DOWNLOAD_THIS_FILE','queryReport','isIndeterminate','','_XCALLY_MIXMONITOR_FORMAT=','formData','chatApplication','src/js/modules/main/apps/voice/views/realtime/abandonedcalls/view.html/view.html','routeId','Whatsapp\x20Interaction','delete\x20VtigerAccounts','unregistered','rpcCampaigns','selectedMusicOnHolds','externaldial','vm.voiceQueue.joinempty.length\x20===\x201\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27strict\x27','attachments/:id/clone','IvrCampaignHopperHistoriesController','Attachments','openchannel_queue:save','motion-theme-options','OPENCHANNEL.EDIT_','TOOLS.UPLOAD_SOUND','ChatQueues','webkitNotification','pt-br','gotoProcess','selectedQueueCampaignHoppers','isAgent','count','readOnly','Asia/Jakarta','lastName','OutboundCallsVoiceRealtimeController\x20as\x20vm','Your\x20survey\x20session\x20has\x20been\x20properly\x20saved!','api.whatsappAccount.update','swswedishfemale','EditSmsAccountAppgotopDialogController','mwFormBuilder','selectedTab','delete\x20agent','Accepted','French','deleteCustomDashboard','saveTag','src/js/modules/main/apps/integrations/views/deskAccounts/create/dialog.html/dialog.html','Asia/Tbilisi','setConditionStatus','cloneIvrCampaign','Portuguese\x20(Nrazilian)','lime-A700','countContactsIvrCampaignHopperFinal','EditInternalAppinternaldialDialogController','deleteSelectedTriggerActions','newsAlertHide','src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/noop/dialog.html/dialog.html','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20openchannelQueues?','The\x20ivrCampaign\x20will\x20be\x20deleted.','error','\x27shortinfo\x27','Module\x20updated!','isNumber','CreateOrEditMusicOnHoldDialogController','voiceRecording','\x27gmail\x27','loose','arraysetinterfacevar','openchannel/queues/:id/users','CHAT.EDIT_CHATWEBSITE','whatsapp/applications/:id','Emma','SYSTEM:GET_MUSICONHOLDS','erlangAbandonmentRate','delete\x20squareRecording','id,name,AccountId','secondLevel','src/js/modules/main/apps/openchannel/views/openchannelAccounts/openchannelAccounts.html/openchannelAccounts.html','exportSelectedCannedAnswers','US\x20English\x20Female','analytics/field_reports/create_many','createOrEditZohoAccount','removeUsers','api.team.delete','createMediaStreamDestination','voiceMails','id,name,role,context','results','motion2.home:','src/js/modules/main/apps/tools/views/cannedAnswers/cannedAnswers.html/cannedAnswers.html','deleteOpenchannelCannedAnswer','response','jscripty/questions/reports/:id/clone','sip','Contact\x20deleted!','mergeContact','Radio\x20Buttons','Delete\x20disposition','apps.whatsapp.whatsappQueues','https://','create_node','calleridname','motion.token','icon-fire','removeSections','WHATSAPP.EDIT_WHATSAPPQUEUE','chanSpy\x20properly\x20saved!','processLimit','month','dashboards/:id/items','controlsList','keys','api.condition.update','voicePrefix@get','ne-NP','disposedAt','600','$between','newMohSound','delete_node','The\x20openchannelCannedAnswer\x20will\x20be\x20deleted.','target','ComposeSmsInteractionDialogController','api.voiceMail.save','api','pt-BR','mohSounds','unknown-os','userVoiceQueue:remove','Liv\x20(Norwegian,\x20Female)','apiAccountRoute','integrations/zoho/accounts/:id/configurations','uniqueid','msNav::expandMatchingToggles','customFieldsMap','\x27ulaw\x27','MOTIONDIALER.SELECTED_LISTS','getApi','apps.fax.faxAccounts','src/js/modules/main/apps/mail/views/mailQueues/mailQueues.html/mailQueues.html','INTEGRATIONS.INTEGRATIONS','id,action,contact,data1,data2,data3,data4,data5,data6,data7,createdAt,updatedAt','SETTINGS.EDIT_GENERAL','WhatsappAccountagentaddController','#ebf1fa','Asia/Irkutsk','deleteAllCondition','delete\x20deskConfiguration','createdAt,updatedAt,uniqueid,ContactId,calleridnum,calleridname,statedesc,scheduledat,starttime,responsetime,endtime','green-300-fg\x20icon-checkbox-marked-circle','fax/interactions/:id/download','variables/:id','File\x20name','whatsappApplication','GET_VARIABLE','motionBullFields','src/js/modules/main/apps/settings/views/cloudProviders/create/dialog.html/dialog.html',',height=','pid','treeStructure','CHAT.EDIT_CHATPROACTIVEACTION','DASHBOARDS.DECEMBER','DASHBOARDS.NO_DISPOSITION_SET','Delete\x20SquareRecording','removeInfoBar','bg-BG','newCloudProvider','createdAt,updatedAt,id,name,phone,vat,fax,companyId,type,website,emailDomain,email,description,sStreet,sPostalCode,sCity,sCountry,street,postalCode,city,country','ACCOUNTS','debug','chat-interaction','The\x20chatQueue\x20will\x20be\x20deleted.','0.54','smsApplication','Voicemail\x20properly\x20created','delete\x20openchannelCannedAnswers','apps.tools.schedules','The\x20vtigerAccount\x20will\x20be\x20deleted.','\x20will\x20be\x20run.','selectedItemChange','onWithoutApply','apps.home.dashboard','data','Incoming','Node\x20has\x20been\x20updated!','src/js/modules/main/apps/sms/views/smsAccounts/edit/smsCannedAnswers/dialog.html/dialog.html','SugarcrmAccount\x20updated!','selectAllUsers','src/js/modules/main/apps/tools/views/cannedAnswers/create/dialog.html/dialog.html','countdown','Europe/Madrid','IntervalId','chatWebsite@get','bcc','DENIED','api.intDeskAccount.delete','onSaveOutbound','trunks/:id/clone','HotDeskDialogController','FaxInteractionId','Maja\x20(Polish,\x20Female)','databases','Sound\x20properly\x20created','lexregion','chat/internal/messages/:id/clone','$endsWith','Telephone\x20password\x20properly\x20updated!','ndassistant_url','addSquareProjects','The\x20smtp\x20will\x20be\x20deleted.','ChatWebsite\x20properly\x20saved!','chatQueueReport','settings','table','getTrunks','id,exten','Queue\x20properly\x20updated!','app.analytics.extractedReports','scroll','newZendeskAccount','ms-widget-back','spyfaxInteraction','src/js/modules/main/apps/fax/views/faxAccounts/edit/view.html/view.html','app.fax.realtime.accounts','deletePlugin','vm_voice.query.filter','src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/close/dialog.html/dialog.html','credential','checkboxes','AgentGeneralHomeController','Today','delete\x20proactive','inuse','vm.voiceQueue.leavewhenempty.length\x20===\x201\x20&&\x20vm.voiceQueue.leavewhenempty[0]\x20===\x20\x27strict\x27','bull','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20faxAccounts?','outboundDropRate','MAIL.EDIT_MAILQUEUE','MAIL.EDIT_MAILACCOUNT','src/js/modules/main/apps/callysquare/views/projects/create/dialog.html/dialog.html','deselectPlugins','internalDial','MxGraphImportXMLController','arraymonitor_format','hasPermission','msNavFoldService','composeMailInteraction','Star','FreshdeskAccount\x20properly\x20created','msApi::requestStart','src/js/modules/main/apps/staff/views/users/edit/view.html/view.html','published','\x27null\x27','src/js/modules/main/apps/integrations/views/salesforceAccounts/create/dialog.html/dialog.html','$broadcast','scrollTop','src/js/modules/main/apps/jscripty/views/projects/create/dialog.html/dialog.html','apps.voice.inboundroutes','Russian\x20Male','outboundNoAnswerCallsDay','TOOLS.NEW_ALLCONDITION','ulaw','app.footer','VoiceQueue\x20properly\x20saved!','CONTACTMANAGER.EDIT_GLOBALCUSTOMFIELD','whatsappCannedAnswer','preview','newSchedule','id,name,strategy,type','getVtigerConfiguration','api.intSugarcrmConfiguration.update','Scheduled\x20Calls','uriLocation','groupBy','Subject','selectAllVoiceRecordings','The\x20whatsappQueue\x20will\x20be\x20deleted.','src/js/modules/main/apps/mail/views/mailAccounts/create/dialog.html/dialog.html','api.interval.update','deleteFaxQueuesWaitingInteractions','MailQueue\x20properly\x20deleted!','targetScope','Delete\x20','name','getApiKey','\x27ASC\x27','AgentHomeWhatsappController','CreateOrEditSmsAccountDialogController','propertiesList','Project\x20properly\x20created','Pacific/Funafuti','intFreshsalesAccount@get','SalesforceAccounts','Hangup','Malayalam','SYSTEM:GETprojects','api.intServicenowAccount.delete','extend','Interaction:save','callbackQueue','Spanish\x20(Uruguay)','OpenchannelQueuesController','deleteSelectedIntervalIntervals','removeCondition','importXML','ChatWebsitelogoController','mailQueue:remove','newAction','getVoiceQueuesChannels','hours','is-IS','Queue\x20Report','src/js/modules/main/apps/contactmanager/views/contacts/import/import.html/import.html','Sounds','Partially\x20Enabled','Cannot\x20upload\x20the\x20plugin','/system?tab','Agent','amber-fg','SmsAccountSmsCannedAnswersController','Application_Name','Project\x20properly\x20saved!','api.intZendeskAccount.save','newMetric','es-PY','Salesforce','CreateOrEditFreshsalesAccountDialogController','NOBEEP','Subject\x20deleted!','TOOLBAR.USER_FORCE_LOGOUT','INTEGRATIONS.EDIT_ZENDESKCONFIGURATION','SalesforceAccountsController','America/Argentina/Mendoza','api.sound.save','You\x20can\x27t\x20remove\x20service\x20account','saveSmsQueue','msDialogRecording','\x20has\x20been\x20cloned!','unhold','openchannelMessage:save','Europe/Copenhagen','delete\x20user','association','QueueCampaign\x20properly\x20deleted!','/zendeskAccounts','currentStepNumber','never','alias','alreadyExistsTab','\x27pt-PT\x27','chat/groups/describe','selectedLanguage','collapseOnBlur','saveExtractedReport','*pause','Would\x20you\x20like\x20to\x20merge\x20your\x20contacs?','api.whatsapp.account','md-scale','es-HN','src/js/modules/main/apps/motiondialer/views/realtime/queues/predictive/dialog.html/dialog.html','sms/messages/:id/status','BookedProgressive','outbounddial','Europe/Malta','English\x20(United\x20States)','minute','div_session_','/odbcs','retry','queue','msChipColor','Plugin\x20properly\x20saved!','\x27id\x27','ServicenowAccount\x20properly\x20saved!','MsTimelineController','','@msUtils.firstLastDayMonth()','ms-color-picker-button','Delete\x20SmsQueue','MAIL.UNKNOWN','then','exportSelectedFreshsalesAccounts','Agent\x20properly\x20deleted!','Azerbaijani','openchannel/accounts/describe','vm.voiceQueue.leavewhenempty.length\x20===\x201\x20&&\x20vm.voiceQueue.leavewhenempty[0]\x20===\x20\x27yes\x27','startedAt','\x27xlsx\x27','getTriggerAllConditions','newAllCondition','sip_id','mail/accounts/:id/clone','selectedMailAccounts','deleteTrigger','quickFilterManager','office2013','getFaxQueues','Plugin\x20properly\x20deleted!','ms-nav-folded\x20ms-nav-folded-open','America/Managua','CONTACTMANAGER.ERRORS.PHONEBAR_API','Mail\x20Account\x20not\x20deleted!','users/:id/openchannel_accounts','onSaveQueue','max','\x27cm_hopper_history\x27','createOrEditOpenchannelAccount','deleteSmsQueue','auth','campaigns/describe','ContactManager','addNewFreshsalesAccount','newDeskAccount','addNewExtractedReport','api.mailQueue.delete','VOICE.INBOUNDROUTES','*|\x0a','DeskAccounts','settings/:id','SETTINGS.NEW_GENERAL','ap-southeast-1','Voice\x20Recordings','deleteFreshdeskAccount','customFieldForm','CreateOrEditInternalRouteDialogController','openchannel/queues/describe','SYSTEM:GETfaxAccount','MOTLICENSE','ServicenowAccountController','saveMailAccount','src/js/modules/main/apps/integrations/views/vtigerAccounts/edit/item/dialog.html/dialog.html','src/js/modules/main/apps/voice/views/musiconholds/create/dialog.html/dialog.html','keyup','deleteItem','stateService','getTriggers','Left\x20Join','selectedSmsAccountApps','chatWebsiteOfflineMessages','openchannelQueue:save','/api/chat/websites/:id/system_avatar','createdAt,updatedAt,ContactId,phone','countdownattr','Pacific/Tarawa','Persian','Delete\x20CustomField','CreateOrEditZendeskConfigurationDialogController','UserProfile\x20properly\x20saved!','\x27always\x27','app.settings.cloudProviders','api/plugins','addAccountApplications','src/js/modules/main/apps/staff/views/agents/edit/changepassword/changepassword.html/changepassword.html','/forgot','STAFF.PERMISSIONS_WARNING_CLOSE','/freshsalesAccounts','ngCsv','deselectCustomDashboards','apiRoute','deleteSelectedWhatsappAccountWhatsappCannedAnswers','ms-navigation-folded','defaultPageTitle','contacts','America/Miquelon','querySearch','addJscriptyTab','welcomemessage','redirectToAgent','command','getCannedAnswers','\x27en-AU\x27','src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/autoreply/dialog.html/dialog.html','Last','fax/interactions/:id/messages','European\x20German\x20Female','app.navigation','MONITOR_OPTIONS=ab','onUpdateOpenchannelInteraction','showNotification','h264','exports','_XCALLY_MIXMONITOR_UNIQUEID=${UNIQUEID}','campaign','api.intSalesforceAccount.save','CreateOrEditPauseDialogController','onSaveUserSmsQueue','EditoutboundAppoutbounddialDialogController','User\x20password\x20properly\x20updated!','exportcsvcontactsexport','limit','appdata.name','freshdesk','createOrEditMetric','version@get','SMS.NEW_SMSACCOUNT','dashboards/items/describe','getFullYear','OdbcsController','chatInteractionTags:save','English\x20(Canada)','lo-LA','InboundRouteActionsController','userOpenchannelQueue:remove','CustomDashboards','app.integrations.zendeskAccounts','Chinese\x20(Traditional)','api.voicePrefix.save','members','isJsonString','createOrEditNetwork','from','America/Indiana/Indianapolis','app/reset','dialogFlowV2Language','ha1','Hungarian\x20Female','UservoicePrefix','api.item.delete','getFaxAccountApps','unPause','delete\x20Users','remote','src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/amazonlex/dialog.html/dialog.html','http://127.0.0.1:','src/js/modules/main/apps/integrations/views/sugarcrmAccounts/edit/item/dialog.html/dialog.html','AdvancedSearchController','ivr','faxPause','selectedContexts','cdr/:id/clone','bodyEl','Legend','Asia\x20Pacific\x20(Singapore)','America/Costa_Rica','CustomDashboardcloneController','DASHBOARDS.RECALLME','integrations/vtiger/fields/:id/clone','Basic','queryFinal','pid\x20is\x20unknown','telephones','getIvrCampaignHopperHistories','userProfile/sections/:id','templateSettings','fromKey','VIDEO.EDIT_SCREENRECORDING','version','Arabic\x20(Israel)','id,name,internal,fullname','gotoAgents','src/js/modules/main/apps/integrations/views/dynamics365Accounts/dynamics365Accounts.html/dynamics365Accounts.html','sms/accounts/:id/applications','CloudProvider','\x27nl\x27','track','voiceQueuesLog/:id/clone','passwordResetAt','indent','InternalRouteController\x20as\x20vm','SMS\x20Messages','src/js/modules/main/apps/tools/views/pauses/pauses.html/pauses.html','EditSmsAccountAppcloseDialogController','Message\x20properly\x20accepted!','addNewZohoAccount','integrations/sugarcrm/fields/:id','callerID','Are\x20you\x20sure\x20want\x20to\x20restore\x20the\x20contact?','intSalesforceField','app.whatsapp.whatsappQueues','onSaveChannel','Ewa','sortBy','delete\x20intervals','MsNavController','fetch','concat','Company\x20name','settings/describe','gotoInternalRoutes','canned_answers/describe','SMS.EDIT_SMSACCOUNT','integrations/sugarcrm/configurations/:id/subjects','ChatCannedAnswer\x20properly\x20deleted!','listsMap','onListSelection','reportType','\x27admin\x27','\x27update\x27','deleteChatWebsiteChatProactiveAction','membername','createdAt,updatedAt,id,name,html,description','agents','deleteMailAccountApp','EditMailAccountAppqueueDialogController','node','.UNKNOWN','recordingFormat','tue','Value','Arabic\x20(Tunisia)','MusicOnHoldsController\x20as\x20vm','ProjectAnswersController','CONTACT\x20NOT\x20AVAILABLE','newUserProfile','Pacific/Palau','Record','src/js/modules/core/directives/ms-stepper/templates/horizontal/horizontal.html/horizontal.html','onMessageUpdate','newFreshdeskAccount','src/js/modules/main/apps/contactmanager/views/contacts/duplicate/dialog.html/dialog.html','gotoStep','Canadian\x20English\x20Female','EU\x20(Paris)','app.motiondialer.realtime.queues','getMailAccountInteractions','src/js/modules/main/apps/staff/views/teams/teams.html/teams.html','apps.fax','w:\x20Enable\x20whisper\x20mode,\x20so\x20the\x20spying\x20channel\x20can\x20talk\x20to\x20the\x20spied-on\x20channel.','Session\x20properly\x20created.','src/js/modules/main/apps/staff/views/userProfiles/edit/permissionsmanage/permissionsmanage.html/permissionsmanage.html','api.dashboard.clone','mailPause','openchannelInteraction:update','Enrique\x20(Spanish,\x20Castilian,\x20Male)','EditWhatsappAccountAppdialogflowDialogController','FreshsalesAccount\x20properly\x20tested','voiceQueue:update','es-DO','getHopperFinals','api.jscriptyProject.update','odbcs','voice/mails/:id/messages','composeSmsInteraction','selectedReportFields','isObjectLike','ExtractedReport\x20properly\x20saved!','UserapikeymanagerController','triggers/describe','VOICE.NEW_VOICEPREFIX','Highest','whatsappAccountApps','list_id','Kyrgyz','WebSocketInterface','gridster','Agreement','MailQueueteamaddController','eurturkishmale','Trunk\x20properly\x20created','getHopperBlacks','exportSelectedChanSpies','displayValue','SMS.EDIT_','getAttachments','The\x20dynamics365Account\x20will\x20be\x20deleted.','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20chatCannedAnswers?','boxed','chat/groups/:id/messages','Trident/7','getPlugins','saveInternalRouteApp','SmsAccount\x20properly\x20deleted!','SYSTEM:GEToutboundRoutes','addNewVoiceRecording','shouldInterpolate','onUpdateSmsInteraction','safari','some','createOrEditChatWebsiteChatCannedAnswer','talking','$scope','||FIELD||OLD||NEW||\x0a','fontFamily','Invisible','arraydialOrderByScheduledAt',':8089/ws','apps.whatsapp.realtime','stringToNumber','openchannelQueue:update','accesskeyid','gotoWhatsappAccounts','selectedChatWebsiteChatCannedAnswers','@uniqueid','refresh','app.tools.customDashboards','GET_MAIL_ACCOUNT','api.user.save','newHopper','es-CO','toggleClass','deleteZohoAccount','api.whatsappQueue.update','msApi::resolveError','Thumb','/cloudProviders','Delete\x20MohSound','pauses/:id/clone','Dial','api.openchannelAccount.delete','2nd','newFreshsalesConfiguration','mail/queues/describe','ACCOUNT:SEND','agentInternal','selectedOperator','voice/queues/:id/blacklists','result','addNewCustomDashboard','DASHBOARDS.TAGS','src/js/modules/main/apps/staff/views/agents/agents.html/agents.html','yes','MailInteractionId','chain','id,name,fullname,userpic','addNewSugarcrmAccount','addPart','CreateOrEditChatCannedAnswerDialogController','googleCloudTtslanguageCode','EditInternalAppdialDialogController','Answer','sugarcrmConfiguration','OpenchannelRealtimeController\x20as\x20vm','THEMES','scrollEl','DeskConfiguration\x20deleted!','PredictiveQueueCampaignDialogController','newMusicOnHold','xmd-contactid','eurczechfemale','src/js/modules/main/apps/motiondialer/views/realtime/ivr_campaigns/view.html/view.html','TOOLS.NOTIFICATIONS.ACTION_DELETED_SUCCESS_TITLE','src/js/modules/main/apps/fax/views/faxQueues/create/dialog.html/dialog.html','AgentHomeDashboardController','Delete\x20Hopper','es-419','deleteSelectedScreenRecordings','Weight\x20Random','whatsappQueue:update','onUpdateMailQueue','createdAt,updatedAt,id,name,username,password,email,remoteUri,serverUrl,description','rpcSmsQueuesWaitingInteractions','rpc/sms/queues/:id/notify','createdAt,updatedAt,id,name,key,email,ListId,active,cservice,Imap.service,Imap.host,Imap.port,Imap.tls,Imap.authentication,Imap.user,Imap.password,Imap.mailbox,Imap.connTimeout,Imap.authTimeout,Smtp.service,Smtp.host,Smtp.port,Smtp.secure,Smtp.authentication,Smtp.user,Smtp.pass,cauthentication,cuser,cpassword,fontFamily,fontSize,template,markAsUnread,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','icon-apps','square/projects/describe','America/Bahia_Banderas','createOrEditTemplate','params','Fax\x20Queues','dialogflowV2_project_id','deleteSalesforceConfiguration','addNewServicenowConfiguration','\x27hours\x27','customField','EditHopperDialogController','mwFormViewer','User\x20properly\x20deleted!','voice/queues/reports/index','addNewvoicePrefix','separatorKeys','mediaConstraints','TriggerAnyConditionsController','/abandonedcalls','AgentHomeFaxController','Team\x20properly\x20created','.csv','app/main/apps/voice','createdAt,updatedAt,id,name,type,remoteUri,authType,username,password,serverUrl,description','Variable\x20properly\x20deleted!','TransferMessageDialogController','#353a48','-10:00','newSmsAccount','Delete\x20OpenchannelCannedAnswer','faxAccount:update','Datetime','Irish','enable','exportSelectedMusicOnHolds','api.trunk.delete','priorities','addNewOutboundRoute','migration','getHopperHistories','app.fax.realtime','ms-nav-toggle','MailQueueController\x20as\x20vm','selectedMailQueues','vm.voiceQueue.leavewhenempty.length\x20===\x201\x20&&\x20vm.voiceQueue.leavewhenempty[0]\x20===\x20\x27wrapup\x27','Hindi','UserController\x20as\x20vm','addClass','src/js/modules/main/apps/staff/views/telephones/create/dialog.html/dialog.html','EditChatWebsiteAppintervalDialogController','PluginController\x20as\x20vm','id,name,parent','squareRecording','indexOf','SYSTEM:DELETEtag','Whatsapp\x20Messages','+02:00','api.tag.update','src/js/modules/main/apps/staff/views/users/users.html/users.html','cm/contacts/merge','14400','cm/lists/:id/fields','SMS.NEW_SMSCANNEDANSWER','addNewInternalRoute','User\x20API\x20key\x20updated!','/marketplace','whatsappCannedAnswers','resourceId','AboutController','IS\x20NULL','app.settings.networks','INTEGRATIONS.EDIT_SALESFORCECONFIGURATION','selectSession','chat/queues/:id/members','Europe/Tirane','SYSTEM:GET_MODULE_PERMISSIONS','api.cmHopper.update','The\x20voiceQueue\x20will\x20be\x20deleted.','selectedWhatsappQueues','turn','/companies','ChatWebsite','src/js/modules/forgot/forgot.html/forgot.html','French\x20(Canada)','Re:','IndexFactory','mohSound','newvoicePrefix','intFreshdeskField','setFolded',';font-size:','webcall','templates','VOICE.CONTEXTS','endtime','addItem','createOrEditField','STAFF.CLOSE','Asia/Kuching','src/js/modules/main/apps/analytics/views/reports/run/web/dialog.html/dialog.html','deleteQueueCampaignHopperBlack','VOICE.WRONG_EXTENSION','selectedSmsQueues','es-SV','createdAt,updatedAt,id,defaultLogo,defaultLoginLogo,defaultFavicon,defaultHeaderWhiteLabel,headerWhiteLabel,defaultPageTitle,pageTitle,defaultPreferred','FaxQueue\x20properly\x20saved!','voice/mails/messages/describe','originateHook\x20->\x20payload','Error','ServicenowAccountConfigurationsController','src/js/modules/core/directives/ms-tab-scroll/ms-tab-scroll.html/ms-tab-scroll.html','selectedFaxQueues','src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/noop/dialog.html/dialog.html','Delete\x20Project','Freshdesk','Spanish\x20(Dominican\x20Republic)','app.contactmanager.companies','answerHook\x20->\x20payload','YYYY-MM-DD\x20HH:mm:ss','Agent\x20password\x20properly\x20updated!','jscriptySessions','Icelandic','contactManager','addShortcut','FaxAccount\x20properly\x20deleted!','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20customFields?','mwForm.pageEvents.changePage','chatQueuesTotal','client_email','DASHBOARDS.ATTENTION','outboundRoutes','newSmsQueue','openchannelApplication','Australia/Darwin','apps.tools.templates','3.0.0-alpha','set','delete\x20freshdeskConfiguration','virtual','predictiveIntervalDroppedCallsTimeout','app.mail.mailSubtatuses','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20message?','integrations/desk/accounts/:id/configurations','Disagree','getAnswers','exportSelectedOpenchannelAccountOpenchannelCannedAnswers','CreateOrEditchanSpyDialogController','rtl','mailSubtatuses','src/js/modules/main/apps/motiondialer/views/ivrCampaigns/edit/blacklistadd/blacklistadd.html/blacklistadd.html','ChatQueueteamaddController','getIvrCampaigns','/userProfiles','OutboundCallsVoiceRealtimeController','/api/settings/1/favicon','motion2.home.chat:','chatWebsiteProactiveActions','scriptName','VoiceQueues','addNewQueueCampaign','lastMessage','src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/dialogflow/dialog.html/dialog.html','prototype','HANGUPCAUSE_17','jpjapanesefemale','XCALLY-MOTION-ANSWER=1','mailInteractionTags:save','eurnorwegianfemale','The\x20customization\x20will\x20be\x20deleted.','createdAt,updatedAt,id,name,key,token,replyUri,ListId,waitForTheAssignedAgent,mapKey,description,receiveUri,notificationSound,notificationShake,notificationTemplate','onSaveOpenchannelInteraction','getPauses','@from-voicemail','isInProgress','Agents\x20association\x20has\x20been\x20updated!','FreshdeskConfiguration\x20deleted!','rurussianmale','app.login','Delete\x20Schedule','whatsapp_queue_waiting_interaction:save','CustomDashboard\x20updated!','arraypriority','getTags','contrast4','getContexts','spysmsInteraction','iPod','900','EditWhatsappAccountAppintervalDialogController','voicemail','src/js/modules/core/directives/ms-phonebar/prefix/dialog.html/dialog.html','schedule','Message\x20has\x20been\x20accepted!','INTEGRATIONS.EDIT_SERVICENOWCONFIGURATION','QUICKPANEL.EDIT_CHATGROUP','createOrEditMusicOnHoldMohSound','respectItemOrder','SYSTEM:GETmailQueue','omit','AgentHomeContactsController','UserProfile\x20properly\x20deleted!','deleteChatQueuesWaitingInteractions','mapArray','createdAt,updatedAt,id,name,service,data2,data1','available','icon-dots-horizontal','ta-LK','goTo','Greek\x20(Greece)','service','id,starttime,endtime,membername,projectname','message','America/La_Paz','English\x20(Kenya)','auto','registerForm','ms-navigation-folded\x20ms-navigation-folded-open','STAFF.','app.settings.updates','requestSucceeded','WHATSAPP.EDIT_','lastPauseAt','Not\x20Found','callbackuniqueid','America/Belem','getChatInteractions','intZohoConfiguration','removeLists','src/js/modules/navigation/layouts/vertical-navigation-fullwidth-toolbar-2/navigation.html/navigation.html','app/main/apps/contactmanager','FAX.ALL_TEAMS','DASHBOARDS.MYCONTACTS','chat/interactions/:id/abandon','ListCustomFieldsController','DashboardCustomController','src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/gotop/dialog.html/dialog.html','userChatQueue:save','VOICE.EDIT_VOICERECORDING','generals','addNewVariable','\x27fr-CA\x27','deleteOpenchannelAccountApp','deleteOutboundRouteApp','green-A700-fg','src/js/modules/main/apps/chat/views/chatWebsites/chatWebsites.html/chatWebsites.html','attrReport','EditInternalAppqueueDialogController','cm_contacts','getAgents','src/js/modules/main/apps/contactmanager/views/lists/edit/customFields/dialog.html/dialog.html','icon-deskphone','$stateParams','SYSTEM:GET_USERS','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20trunks?','List\x20properly\x20saved!','createdAt,updatedAt,id,key,value,description','magicline','integrations/zoho/configurations/:id/descriptions','Asia/Beirut','isNil','failedRows','filterByPropIds','exportSelectedInternalRoutes','api.team.update','project.name','TOOLS.NOTIFICATIONS.CONDITION_CREATED_SUCCESS_TITLE','deselectMailSubstatuses','\x27s\x27','MyBody','navigator','queueNotifyMethod','integrations/sugarcrm/accounts/:id/clone','id,firstName,lastName,email','UploadPluginDialogController','America/Ojinaga','speakerId','squareProject@get','Atlantic/South_Georgia','Africa/Ceuta','editWhatsappAccountApp','0px','waitImagesLoaded','deselectAgents','isNavFoldedOpen','OPENCHANNEL.REALTIME','fax_queue_waiting_interaction:remove','DASHBOARDS.FAX','/deskAccounts','createOrEditSquareRecording','End\x20of\x20Conversation','exportSelectedTelephones','fax/queues/:id/users','moveContactsQueueCampaignHopperFinal','delete\x20mohSound','setFormatTime','currentReport','SmsQueueId','dialogflow_language','SMS\x20Account','onUpdateSmsQueue','getFunctions','\x27pdf\x27','treeDefaultData','src/js/modules/main/apps/integrations/views/dynamics365Accounts/edit/configurations/dialog.html/dialog.html','isHiddenField','src/js/modules/main/apps/staff/views/agents/edit/teamadd/teamadd.html/teamadd.html','lastIn','newReport','CAMPAIGN\x20NOT\x20ACTIVE','permissions','none','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20item?','Windows\x20App','onAddstream\x20->\x20data','Contexts','$[${XCALLY-MOTION-ANSWER}=0]?Answer','downloadSmsInteraction','\x27turn\x27','America/Puerto_Rico','src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/set/dialog.html/dialog.html','newCannedAnswer','selectSession\x20->\x20session','ZendeskAccount\x20properly\x20created','getFreshsalesAccounts','uri','SYSTEM:GETqueues','Error\x20creating\x20notification\x20for\x20incoming\x20call','interaction\x20#','hue','$state','mail/applications/describe','toLowerCase','deleteSelectedQueueCampaignHoppers','\x20selected','whatsappTransferReport','openchannelAccountOpenchannelCannedAnswers','isFunction','rgb(','voice/extensions/describe','TOOLS.EDIT_SCHEDULE','hopperFinal\x20#','Mads\x20(Danish,\x20Male)','apps.video','isCompatibleBrowser','msApi.resolve\x20requires\x20correct\x20action\x20parameter\x20(resourceName@methodName)','addQueues','Trasfer\x20properly\x20done!','schedule@get','isArray','users/:id/password','src/js/modules/core/directives/ms-stepper/templates/vertical/step/vertical-step.html/vertical-step.html','Chat\x20Offline\x20Messages','FreshsalesAccounts','openchannel/applications/:id/clone','selectedMetrics','America/Cayman','Beepall','$viewValue','previewdialog','src/js/modules/core/directives/ms-info-bar/ms-info-bar.html/ms-info-bar.html','mail/accounts/:id/canned_answers','deleteInternalRoute','The\x20general\x20will\x20be\x20deleted.','mailInteraction','America/Indiana/Winamac','isFormValid','\x27en-US\x27','saveFreshdeskConfiguration','toolbar','gotoVoiceQueues','chat/websites/:id/system_avatar','Turn','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20chatProactiveAction?','getDeskConfiguration','Ukrainian','src/js/modules/main/apps/integrations/views/zendeskAccounts/edit/zendeskConfigurations/dialog.html/dialog.html','Slovak','rundialog','Unknown','DASHBOARDS.ME','Telephone\x20properly\x20deleted!','\x20has\x20been\x20updated!','Delete\x20SugarcrmConfiguration','eurspanishmale','UserWhatsappDashboardGeneralController\x20as\x20vm','sms_queue_waiting_interaction:save','whatsapp_queue:save','isChecked','MAIL.ALL_AGENTS','chatQueue@get','api.voiceRecording.delete','jscripty/projects/:id','render','INTEGRATIONS.NEW_DYNAMICS365CONFIGURATION','\x27es-ES\x27','cm/companies/describe','id,name,dialPrefix','ClientEmail','MailQueues','styles','Albanian','group','Urdu\x20(Pakistan)','users/:id/openchannel_interactions','analytics/extracted_reports/describe','selectAllMailSubstatuses','refreshContacts','expanded','VOICE.NEW_INBOUNDROUTE','getReceivers','mandatoryDisposition','hiddenBCC','api.voiceMusicOnHold.save','SalesforceAccountsController\x20as\x20vm','SYSTEM:DELETEsound','/api/settings/1/logo_login','hmac','chat/websites/:id/customer_avatar','formViewer','isWebRTCSupported','faxAccountApp','delete\x20fields','onFieldChange','partial','cm/contacts/:id/hopper_histories','Naja\x20(Danish,\x20Female)','\x27wrandom\x27','MailQueueagentaddController','Asia/Dubai','Phone','deleteSelectedDeskAccounts','app.voice.musiconholds.edit','voice_queue_channel:save','app.settings.customizations','TOOLS.CANCEL','Moldavian','apps.analytics','vm.selectedTab','createOrEditCompany','ChatGroupController','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/externaldial/dialog.html/dialog.html','OpenchannelAccountInteractionsController','SYSTEM:GET_VARIABLES','Spanish\x20(Colombia)','screen/recordings/:id/clone','remote-audio','America/Rankin_Inlet','saveServicenowConfiguration','saveDashboardItem','PreviewReportDialogController','CreateOrEditCustomizationDialogController','onReply','inboundQueues','newGeneral','audio','US\x20West\x20(N.\x20California)','/api/chat/websites/','src/js/modules/main/apps/callysquare/views/projects/edit/view.html/view.html','addNewPause','VtigerAccount\x20updated!','rpc/chat/queues/waitinginteractions','sms/accounts/:id/interactions','Raveena','uninstallplugin','deleteTelephone','filterSingleByTags','America/Argentina/Cordoba','Polish\x20(Poland)','addCall\x20->\x20target,\x20inbound,\x20fullname','postalCode','Latin','replaceTrack','FaxRealtimeController\x20as\x20vm','createdAt,updatedAt,id,name,table,metric,description','attributes','autoCreate','default','cm/lists/:id/dispositions','SYSTEM:DELETEcannedAnswer','SYSTEM:GETwhatsappAccounts','delete\x20servicenowConfiguration','STAFF.NEW_USER','ur-IN','getLabelByMessage','\x27ko\x27','Member\x20Report','InternalRoute\x20updated!','\x22>','api.smsAccount.delete','intSugarcrmConfiguration','networks','myQueues','CONTACTMANAGER.NEW_CUSTOMFIELD','app/main/apps/dashboards/views/general/agent/home/abandoned/dispose/dialog.html','exists','apps.marketplace.plugins','onSaveWhatsappQueueChannel','deleteSelectedOpenchannelAccountInteractions','intVtigerField','src/js/modules/main/apps/whatsapp/views/whatsappQueues/whatsappQueues.html/whatsappQueues.html','\x27report_jscripty_answers\x27','DialogController','SYSTEM:DELETEcmCustomField','chatQueue:save','deleteSelectedChatWebsiteProactiveActions','src/js/modules/main/apps/mail/views/realtime/queues/view.html/view.html','UserProfilePermissionsController','app.errors.error-500','SYSTEM:GETopenchannelAccount','Indonesian','createOrEditWhatsappAccountWhatsappCannedAnswer','\x27tls\x27','\x27plivo\x27','SYSTEM:GET_FAXACCOUNTS','utc','+03:30','/avatar','searchResultClick','Serbian\x20(Serbia)','newTag','exportSelectedTeams','The\x20openchannelQueue\x20will\x20be\x20deleted.','deleteFieldConfirm','Delete\x20SalesforceAccount','delete\x20subjects','originalMessage','Arabic\x20(Iraq)','transferCallback','createdAt,updatedAt,id,name,description,dialPrefix','Invalid\x20extension:\x20','analytics','ResetPasswordController','upload','voice/prefixes/describe','onRemoveOpenchannelQueue','Oromo','src/js/modules/main/apps/tools/views/customDashboards/create/dialog.html/dialog.html','app.jscripty','Timeout','Dynamics365Accounts','actions','GET_USER','ASC','smsAccount','saveZendeskAccount','id,name','=ngModel','onClose','analytics/field_reports/destroy_many','=viewModel','Fields\x20has\x20been\x20copied!','#1a3865','streets','equals','mail/interactions/:id/messages','deleteSelectedWhatsappAccountApps','getFaxAccountInteractions','hideLoadingIndicator','jscripty/questions/reports/:id','\x27alaw\x27','src/js/modules/core/directives/ms-quick-filter/ms-quick-filter.html/ms-quick-filter.html','Asia/Singapore','pt-PT','source','Delete\x20SmsAccount','vm.query','api.voiceRecording.save','runconfirm','OutboundRoute\x20properly\x20saved!','deleteSelectedMusicOnHoldMohSounds','app.whatsapp.whatsappAccounts.edit','SYSTEM:GETLISTS','voice/mails/messages/:id/download','AgentsMotionDialerRealtimeController','UpdateDialogController','UserSmsDashboardGeneralController','=template','delete\x20team','phoneBarEnableScreenRecordingByAgent','delete\x20Agents','listFields','\x27IAX\x27','deleteWhatsappAccountApp','wait','questions','-bg','CreateOrEditCloudProviderDialogController','selectedVoicePrefixes','Session\x20save\x20error','id,type,calleridnum,calleridname,queue,queuecallerabandonAt,queuecallerexitAt,queuecallerexitreason,assigned,lastAssignedTo,updatedAt,disposition,secondDisposition,thirdDisposition','SugarcrmAccount\x20properly\x20deleted!','moveSelectedQueueCampaignHopperFinals','ml-IN','^msTimeline','EditFaxAccountAppgotopDialogController','SYSTEM:GETvoiceQueue','\x27roundrobin\x27','Asia/Choibalsan','\x27WAV\x27','icon-hangouts','selectedVtigerAccounts','odbc_id','vtigerAccount','isStepDisabled','=endTime','INTEGRATIONS.EDIT_FRESHSALESACCOUNT','toggleMobileBar','+10:00','whatsappQueues','changeLanguage','Whatsapp\x20Report\x20Queue','lime-A700-bg','integrations/zoho/accounts/describe','onNewRTCSession\x20->\x20vm_pb.sessions','whatsapp/messages/:id/clone','deselectODBC','English\x20(India)','/triggers','getZendeskConfiguration','radio','start3WayConf','Gwineth\x20(Welsh,\x20Female)','integrations/freshdesk/accounts/:id/configurations','api.screenRecording.update','saveAgents','OPENCHANNEL.UNKNOWN','MouseOver','TOOLBAR.HINDI','mouseEventIgnoreTimeout','getVoicePrefixes','extension','intDynamics365Account@get','voice/chanspy/:id','getInternalRouteApps','aug','content','deselectTemplates','rpcFaxAccounts','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20zendeskAccounts?','Malayalam\x20(India)','blurCollapse','STAFF.TEAMS','intFreshsalesAccount','helperClasses','apps.marketplace','selectedChatWebsiteApps','TOOLS.VARIABLES','The\x20smsCannedAnswer\x20will\x20be\x20deleted.','_self','Account','Home','delete\x20mailCannedAnswer','cmList@get','SalesforceConfiguration\x20properly\x20saved!','OutboundRoutesController\x20as\x20vm','Europe/Simferopol','red-fg','America/Thule','getResults','pageTitle','toggleHorizontalMobileMenu','prompt','src/js/modules/main/apps/staff/views/telephones/edit/view.html/view.html','motion.selectedTheme','Odbc','whatsapp/accounts/describe','src/js/modules/main/apps/voice/views/outboundroutes/edit/view.html/view.html','','jscriptyProject','MailAccountInteractionsController','CHAT.CHATWEBSITES','mailAccountMailCannedAnswers','arrayjoinempty','rpc/mail/queues/:id/notify','\x27report_openchannel_queue\x27','UserFaxDashboardGeneralController\x20as\x20vm','$translatePartialLoader','wasUserInPause','searchTerm','ms-navigation-horizontal','updateConfirm','interaction','columnName','fax/interactions/:id/tags','selectedSounds','DashboardItem\x20properly\x20created','Unable\x20to\x20open\x20the\x20contact','accentPalette','OpenchannelQueue\x20properly\x20saved!','timeRangeTo','api.intServicenowConfiguration.update','MainController\x20as\x20vm','WhatsappAccountController','rpc/voice/channels','TOOLBAR.NOTIFICATION_TITLE_RECIPIENT','MsShortcuts.query','loginSSO','addNewTemplate','delete\x20mailCannedAnswers','Last\x20Week','newPause','api.dashboardItem.delete','SugarcrmConfiguration\x20deleted!','IvrCampaignresetlistController','report','playback','rpcTelephones','searchInProgress','onDispositionChange','VIDEO.FILE_NOT_FOUND','vtigerConfiguration','jscripty/sessions/reports/describe','SYSTEM:GET_TEMPLATES','settings/:id/logo','MsStepperController\x20as\x20MsStepper','whatsappCurrentCapacity','app.dashboards.general.mail','getServicenowConfiguration','callerId','voice/mohs/:id/sounds','Marathi','VOICE.ALL','CALLERID(all)=','icon-checkbox-marked-outline','uploadSounds','/whatsappQueues','api.analyticreport.delete','OpenchannelAccountagentaddController','faxInteraction@get','getAllConditions','id,name,role','goToTrunk','+08:30','Voicemail','SugarcrmConfiguration\x20properly\x20deleted!','license','voiceMail@get','fonts','Delete\x20Trunk','getNotifications','integrations/salesforce/configurations/:id/clone','SYSTEM:GET_SMSACCOUNTS','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20subjects?','saveShortcuts','Caller_ID','getChatWebsiteLabel','selectedMode','VoiceQueuesController\x20as\x20vm','id,level,name,description,ParentId,createdAt,updatedAt','deleteSelectedIvrCampaignHopperHistories','api.intDeskAccount.update','mail/messages/:id/download','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20deskConfiguration?','app.contactmanager.companies.edit','ZendeskAccount\x20properly\x20tested','interactionId','mail/applications/:id/clone','Channel\x20','replyMessage','INTEGRATIONS.NEW_VTIGERCONFIGURATION','app.openchannel.openchannelAccounts.edit','CALLYSQUARE.SELECTED_USERS','Loading...','SalesforceAccountConfigurationsController','ignoreMouseEvents','\x27externip\x27','analytics/custom_reports/describe','ServicenowAccountsController\x20as\x20vm','onChange','enableDtmfTone','\x20not\x20found','saveDeskConfiguration','app.dashboards.general.openchannel','skype','assignTo','ivrCampaign','Select','SYSTEM:GET_OUTBOUNDROUTES','\x27whatsapp_messages\x27','verticalNavigationFullwidthToolbar','QUICKPANEL.NEW_INTERNAL_MESSAGE','api.contact.save','Gwineth','saveReportField','Asia/Brunei','integrations/freshsales/configurations/:id/fields','closed\x20===\x200','CompaniesController\x20as\x20vm','apps.mail.mailAccounts','ListDispositionsController','selectedHues','WHATSAPP.WHATSAPPQUEUES','sound.name','Restored\x20Contact','deselectVtigerAccounts','save','rpc/fax/accounts','app.whatsapp','cross_join','selectedVtigerConfiguration','CHAT.ALL_AGENTS','SYSTEM:GETvoiceExtension','utcOffset','getFaxAccountLabel','ur-PK','app.chat','analytics/metrics/:id/clone','Conchita','\x27sms_messages\x27','empty','deleteSelectedMailSubstatuses','deleteFaxAccountApp','Spanish\x20(Mexico)','deleteSelectedMailQueues','VOICE.NEW_INTERNALROUTE','green-A700','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20interaction?','CALLYSQUARE.SQUARERECORDINGS','VIDEO.VIDEO','English\x20(Ghana)','/smsAccounts','current','openMailDraft','intZendeskField','motionThemes','retrieveUser','delete\x20WhatsappAccounts','mail/reports/queue/:id','onLogout','api.faxAccount.save','getChatQueues','app.fax.faxQueues','Bengali','chat_queue_waiting_interaction:save','select','America/Eirunepe','$mdToast','rpc/chat/queues','createOrEditInterval','apps.chat','Draft','Intervals','US\x20Money','handleResultClick','putOtherCallsOnHold','green-A700-bg','obj','CONTACTMANAGER.COMPANIES','Canadian\x20French\x20Female','Dynamics365Account','delete\x20freshdeskAccount','UserFaxQueue','EditMailAccountAppintervalDialogController','msFormWizardForm','Kannada','Fax\x20Report\x20Transfer','stream','-09:30','Delete\x20dispositions','vm.voiceQueue.leavewhenempty.length\x20===\x201\x20&&\x20vm.voiceQueue.leavewhenempty[0]\x20===\x20\x27inuse\x27','square/recordings/:id/download','app.motiondialer.ivrCampaigns','chatWebsiteChatCannedAnswers','deselectContexts','CreateOrEditFaxQueueDialogController','acceptedMessages','\x27SIP\x27','mail/applications/:id','app/main/apps/openchannel','createdAt,updatedAt,id,name,description,table,conditions,joins','tag@get','\x27ru\x27','ta-MY','Invalid\x20transfer','/assets/images/theme-options/content-only.jpg','createdAt,updatedAt,uniqueid,ContactId,calleridnum,calleridname,statedesc,countcongestionretry,countbusyretry,countnoanswerretry,countnosuchnumberretry,countdropretry,countabandonedretry,countmachineretry,countagentrejectretry,countglobal,scheduledat,starttime,responsetime,endtime,disposition,ListId,UserId,VoiceQueueId,CampaignId,recallme,deleted,campaign','src/js/modules/main/apps/chat/views/chatQueues/edit/agentadd/agentadd.html/agentadd.html','FreshdeskAccount','snakecase','SYSTEM:DELETEmailSubstatus','addMinutes','EditMailAccountAppgotoifDialogController','deleteFreshdeskConfiguration','America/Indiana/Vevay','\x27basic\x27','EditSmsAccountAppqueueDialogController','onSearchBarCollapse','ChatWebsiteController\x20as\x20vm','msMasonryItem:finishReLayout','src/js/modules/core/directives/ms-material-color-picker/ms-material-color-picker.html/ms-material-color-picker.html','Smtp\x20properly\x20verified','src/js/modules/main/apps/staff/views/agents/edit/view.html/view.html','getGroups','intZohoAccount','TagId','MsNavigationNodeController','voicemails','Calibri,\x20Verdana,\x20Geneva,\x20sans-serif','SalesforceAccount','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20description?','api.jscriptyProject.delete','English\x20(South\x20Africa)','/jscripty','Karl','lastIndexOf','/openchannelAccounts','servicenow','saveSmtp','DASHBOARDS.NOVEMBER','api.chatAccounts.account','headers','Hopper\x20properly\x20deleted!','OutboundRoute\x20properly\x20created','apps.integrations','selectedCannedAnswers','firstLevelDisposition','newMailQueue','-04:00','fax_queue_waiting_interaction:save','bind','mailAccount','aws_lex_region','SETTINGS.SYSTEM','Fax','generateApiKey','DASHBOARDS.OCTOBER','$location','requestPermission','\x22\x20does\x20not\x20exist!\x20Falling\x20back\x20to\x20the\x20\x22default\x22\x20theme.','mailStatus','SYSTEM:DELETEcloudProvider','ChatProactiveAction\x20properly\x20created','delete\x20ServicenowAccounts','CHAT.NEW_CHATWEBSITE','languages','Message\x20properly\x20sent!','SYSTEM:GETsounds','addVoiceQueuesChannels','grammar','groups','temporarilyIgnoreMouseEvents','app.dashboards.general.chat','reply','TOOLS.NOTIFICATIONS.CONDITIONS_DELETE_TITLE','\x27SIP/{{multipleUsers.name}}\x27','CreateOrEditGlobalCustomFieldDialogController','Auth','setAgentCapacity','sa-east-1','onSaveSmsInteraction','deleteMailAccount','General\x20properly\x20saved!','userChatQueue:remove','animateHeightClass','ar-XA','googleTtsLanguage','Croatian','createdAt,updatedAt,id,min_internal,securePassword,callRecordingEncryption,chatTimeout,phoneBarAutoUpdater,defaultScreenRecordingPath,phoneBarAutoUpdaterUrl,enableEmailPreview,split,splitSizeCsv,splitSizePdf,splitSizeXlsx,messagesAlignment,phoneBarRememberMeEnabled,rtlSupport,allowedLoginAttempts,blockDuration,loginMailFrequency,language,bucket,transcribe,transcribeRegion,transcribeAccountId,sentiment,sentimentRegion,sentimentAccountId,googleSsoEnabled,enforcePasswordHistory,passwordHistoryLimit','id,uniqueid,calleridnum,statedesc,scheduledat,starttime,endtime','teal-fg','/about','INTEGRATIONS.DYNAMICS365ACCOUNTS','TOOLS.TEMPLATES','pink','src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/externaldial/dialog.html/dialog.html','deleteSelectedChanSpies','sms/accounts/describe','src/js/modules/main/apps/callysquare/views/squareRecordings/create/dialog.html/dialog.html','Marathi\x20(India)','exportSelectedIvrCampaignHopperFinals','match','resetForm','DefaultReports','$mdMenu','Urdu','closeFolded','Please\x20select\x20a\x20variable','integrationReport','English\x20(Australia)','Module\x20not\x20included\x20in\x20the\x20license','SETTINGS.NEW_NETWORK','Lithuanian','exportSelectedVoiceQueues','QueueParamsVoiceRealtimeController','openchannelAccountApp','hold\x20->\x20session','uploadSound','deleteSmtp','chat/messages/:id/reject','selectAllSmsAccounts','Are\x20you\x20sure\x20want\x20to\x20close\x20the\x20','Africa/Abidjan','','MOTIONDIALER.EDIT_HOPPER','whatsapp/queues/:id/clone','VtigerConfiguration\x20deleted!','app.settings.system','saveDialog','addNewDashboardItem','optionsBuilder','omniChannels','FaxQueueagentaddController','blue-A700-fg','Camino','fax/reports/queue/:id/clone','English\x20(Australian)','Attached\x20pm2\x20process\x20successfully\x20restarted','Dialer\x20Hopper\x20Processing','voice/calls/reports/describe','VariablesController\x20as\x20vm','IntervalController\x20as\x20vm','apps.sms','\x27S\x27','api.disposition.delete','playrecording','o:\x20Only\x20listen\x20to\x20audio\x20coming\x20from\x20this\x20channel.','cm/hopper_final/:id','queue_id','Spanish','onInteractionClose','tr-TR','selectedFreshdeskConfiguration','CreateOrEditSugarcrmAccountItemDialogController','ProjectViewerController','saveMohSound','custom','msMasonryItem','autoClose','vm.voiceQueue.joinempty.length\x20===\x201\x20\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27no\x27','2400','api.chatProactiveAction.delete','\x20-\x20','uniq','multipleUsers','notification:send','api.variable.save','countcongestionretry','\x20deleted!','XMLHttpRequest','Project\x20','voice/recordings/:id/clone','Europe/Volgograd','SmtpController','Your\x20password\x20properly\x20updated','MailQueue','updateProcess','mailQueues','string','mailStatusTime','Agent\x20properly\x20created','CustomField\x20properly\x20saved!','Asia/Makassar','Delete\x20MailCannedAnswer','integrations/sugarcrm/accounts/:id/fields','INTEGRATIONS.NEW_ZOHOCONFIGURATION','left','last','loadShortcuts','alternate','service-worker.js','EditInboundAppplaybackDialogController','osVersion','WhatsappAccount\x20properly\x20deleted!','\x20has\x20been\x20copied!','msApi::resolveStart','Waiting\x20to\x20restart\x20motion...','VERSION\x20','saveDeskAccount','apps.tools.triggers','isString','delete\x20Voicemails','lt-LT','registered','integrations/servicenow/configurations/describe','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20voiceQueues?','Last\x20Month','outboundNoSuchCallsDay','verticalNavigationFullwidthToolbar2','ChatWebsiteonlineFormController','delete\x20customFields','createOrEditPlugin','app.tools.trunks.edit','The\x20customField\x20will\x20be\x20deleted.','src/js/modules/main/apps/integrations/views/servicenowAccounts/edit/configurations/dialog.html/dialog.html','US\x20West\x20(Oregon)','UserVoiceDashboardGeneralController\x20as\x20vm','integrations/desk/accounts/:id/clone','Europe/Amsterdam','\x27mail_messages\x27','chat/websites/:id/users','SETTINGS.LICENSE','timeRangeFrom','gotoif','user_has_chat_interactions:remove','users/:id/sms/interactions','-updatedAt','IS_NOT_AMONG','userLists','Asia/Seoul','ANALYTICS.ANALYTICS','delete\x20whatsappCannedAnswers','chatOfflineMessage','VIDEO.SCREENRECORDINGS','_path','arrayoptions','apps.jscripty','rpc@getChatQueues','selectedVariables','mailInteraction:save','api.analyticExtractedReport.delete','SYSTEM:GETpauses','X-callback-url:\x20','scales','src/js/modules/main/apps/sms/views/realtime/agents/view.html/view.html','updateLayoutMode','Agent\x20Report','updateLayoutStyle','mailMessage:update','customFields','QueuesChatRealtimeController\x20as\x20vm','#FFC107','getSounds','Messages','ZohoAccountsController','TOOLS.DELETE','.eml','Miguel\x20(Spanish,\x20US,\x20Male)','CONTACTMANAGER.ALL_AGENTS','MxGraphSaveProjectAsController','\x27pt-br\x27','medium','src/js/modules/main/apps/voice/views/outboundroutes/edit/apps/outbounddial/dialog.html/dialog.html','SETTINGS.LICENSE_REQUEST_SENT','Pacific/Enderbury','secondLevelDisposition','primaryPalette','smsQueueReport','Chinese\x20(Hong\x20Kong)','pascalprecht.translate','TOOLS.EDIT_INTERVAL','editstate','th-TH','delete\x20SquareRecordings','src/js/modules/main/apps/sms/views/smsQueues/smsQueues.html/smsQueues.html','ProjectBuilderController','intSalesforceAccount@get','src/js/modules/main/apps/fax/views/faxAccounts/faxAccounts.html/faxAccounts.html','migrations/:id/clone','app.integrations.vtigerAccounts.edit','whatsapp/reports/transfer/:id','chatGroup:remove','Type\x20the\x20target','TriggerActionsController','toDate','quickFilters','onNewRTCSession\x20->\x20data','openchannelQueue@get','xAnswerMode','mailInteraction:update','Faroese','toInteger','HopperHistory\x20deleted!','delete\x20faxQueue','deleteDynamics365Account','STAFF.NOTIFICATIONS.PERMISSIONS_ENABLED_ALL_SUCCESS_TITLE','app/core/directives/ms-phonebar/sounds/beep.ogg','addRecording','EditOpenchannelAccountAppgotoifDialogController','MsThemeOptionsController\x20as\x20vm','src/js/modules/main/apps/chat/views/chatWebsites/edit/view.html/view.html','square/recordings/:id/clone','firstName,lastName,phone,mobile','Hungarian\x20(Hungary)','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20telephones?','getInstallInfo','app.errors_error-404','selectAllQueueCampaigns','CONTACTMANAGER.EDIT_HOPPER','selectAllNetworks','Delete\x20condition','mailMessage','chat/websites/:id/avatar','deleteSelectedIvrCampaigns','America/Bogota','addAllCondition','\x27loose\x27','apps.voice.realtime','ContextsController','src/js/modules/main/apps/analytics/views/extractedReports/extractedReports.html/extractedReports.html','toggleCollapsed','OpenchannelCannedAnswer\x20properly\x20deleted!','user','/assets/images/theme-options/vertical-nav.jpg','addMembers','globalCustomFields','queuesMap','Tags\x20set!','collapsable','Europe/Vienna','Smtp\x20verified!','-02:00','users/:id/fax_interactions','hasRole','src/js/modules/main/apps/sms/views/smsQueues/edit/teamadd/teamadd.html/teamadd.html','FaxAccountsController','Asia/Magadan','vm.voiceQueue.joinempty.length\x20===\x201\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27unknown\x27','AgentsMailRealtimeController','app.tools.intervals','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20servicenowConfiguration?','id-ID','src/js/modules/main/apps/staff/views/agents/create/dialog.html/dialog.html','UserSmsQueue','.draggable','\x27France\x20(France)','SETTINGS.SETTINGS','deleteTeam','grey-fg\x20icon-minus-circle','selectedDescriptions','UserWhatsappQueue','
','motion.folded','templates/:id/clone','CreateOrEditChatQueueDialogController','usspanishfemale','apps.voice.voiceRecordings','Africa/Monrovia','delete\x20odbc','msg_id','UserProfileController','voice/queues/:id/members','Horizontal\x20Navigation','userWhatsappQueue:save','deleteSelectedODBC','demo','rpcFaxQueues','forward','app.settings.generals','\x22\x20err:','src/js/modules/main/apps/motiondialer/views/ivrCampaigns/ivrCampaigns.html/ivrCampaigns.html','Outbound\x20route\x20not\x20deleted!','app/main/apps/settings','msMasonryController','getMailAccountMailCannedAnswers','fax/accounts/updateaccountapplications','getSummary','XCALLY-MOTION-ANSWER=0','api.whatsappQueue.save','Import\x20process\x20failed!','TOOLBAR.FRENCH','gotoVoicemails','deleteIvrCampaignHopperFinal','contrast','SYSTEM:SENDMESSAGE','vm.voiceQueue.joinempty.length\x20===\x201\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27loose\x27','apps.settings.cloudProviders','\x27preview\x27','app/core/directives/ms-phonebar/sounds/incoming-call.ogg','queryChannels','addNewCompany','@pid','salesforceAccounts','integrations/zoho/configurations/:id','mailApplication','record\x20->\x20session','digits','Report\x20Field\x20properly\x20saved!','deleteSelectedListCustomFields','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20project?','CreateOrEditOdbcDialogController','Project\x20properly\x20cloned','eu-west-2','backgroundPalette','CreateOrEditTeamDialogController','interactionsgoto','fa-IR','onUpdateChatQueue','SIP','intervals/describe','getProcesses','intersection','type','TOOLS.NEW_CUSTOMDASHBOARD','voice','src/js/modules/main/apps/analytics/views/reports/create/dialog.html/dialog.html','userFaxQueue:remove','openchannel-interaction','gotocontactsgoto','userProfileResource','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20cannedAnswers?','api.voicePrefix.delete','exportSelectedMailSubstatuses','delete\x20smsCannedAnswers','intervals/:id/sub_intervals/create_many','integrations/dynamics365/accounts/describe','createdAt,updatedAt,id,name,key,headerinfo,TrunkId,localstationid,ListId,waitForTheAssignedAgent,description,ecm,minrate,maxrate,modem,gateway,faxdetect,t38timeout,tech,acceptMethod,acceptUrl,rejectMethod,rejectUrl,closeMethod,closeUrl,notificationSound,notificationShake,notificationTemplate','MOTIONDIALER.QUEUECAMPAIGNS','ngJsTree','whatsappMessage','faxAccountApps','OpenchannelQueueId','webrtc','SETTINGS.GENERAL','contact','
\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Queue:\x20','Report\x20properly\x20run!',',${EXTEN},','MAIL.SELECTED_AGENTS','queueCampaignHopperFinals','Asia/Amman','SmsQueues','SYSTEM:GET_PROJECTS','ShowQuestionsSessionDialogController','sectionColor','\x27fax_messages\x27','Netscape','microphoneVolume','callCallback\x20->\x20url,\x20params','internalrouteApp','isoWeek','Supported\x20extensions:\x20','session','attachments/describe','MOTIONDIALER.CLONE_IVRCAMPAIGN','','apps.settings','progresslogin','VoiceQueue\x20properly\x20deleted!','confirmed','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20smsAccounts?','data5','deleteFreshsalesConfiguration','api.mailAccount.delete','dialogflowv2','delete\x20whatsappQueue','editedat','SYSTEM:GETchatWebsite','SUCCESS','About','chatCapacity','downloadTranscribe','selectColor','DASHBOARDS.CHAT','$translateProvider','userSmsQueue:save','rpc/voice/queues/channels/:uniqueid/redirect/:exten','phone','accountConnected','warning','\x27es\x27','TOOLBAR.HEBREW','ZohoAccount','hopperHistory','api.voiceQueue.delete','head','api.voiceMail.update','startTime','Chantal\x20(French,\x20Canadian,\x20Female)','DASHBOARDS.UNTITLED','app.tools.schedules','-11:00','integrations/salesforce/accounts/describe','SYSTEM:GETintVtigerAccount','The\x20faxAccount\x20will\x20be\x20deleted.','automations/:id/conditions','src/js/modules/main/apps/mail/views/mailAccounts/edit/apps/system/dialog.html/dialog.html','gotoMailQueues','\x27integrationTab\x27','voiceMail.mailbox','SYSTEM:DELETEtrigger','thu','/var/opt/motion2/server/files/sounds/converted/','app.motiondialer.realtime','hue-1','src/js/modules/main/apps/dashboards/views/general/user/openchannel/user.general.openchannel.html/user.general.openchannel.html','vendor','\x27voice\x27','deleteSelectedSmsQueues','getProjectSessions','Agentchange_avatarController','showFaxInteraction','ispeechAsrLanguage','src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/tag/dialog.html/dialog.html','src/js/modules/main/apps/tools/views/triggers/edit/allconditions/create/dialog.html/dialog.html','ServicenowAccount\x20properly\x20deleted!','#3c4252','converted_format','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20customField?','iCab','newMailSubstatus','msScrollConfigProvider','Description','\x27inband\x27','Carmen','Tag\x20properly\x20saved!','reLayout','-03:00','uploadError','icon-sitemap','
\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','...','New\x20Item','mail/accounts/:id/users','createdAt,updatedAt,id,name,channel,status,description','description','Pacific/Tongatapu','Czech','createdAt,updatedAt,id,name,dsn,description','general','screenrecording','pending','ap-northeast-1','icon-phone','FreshdeskAccountController','CreateOrEditInboundRouteDialogController','deleteSmsQueuesWaitingInteractions','\x27never\x27','app.integrations.freshsalesAccounts','chat/reports/transfer/:id','err','VOICE.EDIT_INTERNALROUTE','teams/describe','usersMap','delete','\x27clickatell\x27','CreateOrEditFreshdeskConfigurationDialogController','openchannel/reports/queue/:id/clone','getTriggerAnyConditions','userProfile/sections/describe','accept','triggerActions','setActiveTheme','api.variable.delete','team','musiconholds','closed','onLogin','/servicenowAccounts','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20deskAccounts?','style','PLUGINS.PLUGINS','arrayusereqphone','integrations/sugarcrm/fields/:id/clone','mail_queue:save','apps.mail','\x27inuse\x27','Korean\x20Male','English\x20(Nigeria)','src/js/modules/main/apps/contactmanager/views/lists/create/dialog.html/dialog.html','InternalRoutesController','basic','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20freshdeskAccounts?','selectAllContacts','\x27password\x27','STAFF.EDIT_AGENT','Alphabetical','getFormats','CreateOrEditOutboundRouteDialogController','mail/substatuses/:id','OfflineMessage\x20deleted!','Turkmen','src/js/modules/main/apps/contactmanager/views/companies/edit/view.html/view.html','mobileBarActive','macro','CustomizationpreferredController','Accept','getConditions','Sms','saveHopper','..a','Please\x20retry\x20with\x20a\x20new\x20file','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20inboundroutes?','voice/queues/:id/lists','MailAccountsController\x20as\x20vm','id,name,type,dialMethod,dialActive','Contacts','api/sounds','src/js/modules/main/apps/integrations/views/vtigerAccounts/edit/configurations/dialog.html/dialog.html','themes','fax.faxAccounts','firstStep','Delete\x20ZendeskConfiguration','queueCampaignHopperBlacks','STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_MESSAGE','src/js/modules/main/apps/tools/views/tags/create/dialog.html/dialog.html','api.pm2.save','$resource','#main','Please\x20enable\x20browser\x20notifications!','ms-stepper','delete\x20mailQueue','SYSTEM:ADDFIELDS','MailQueue\x20properly\x20saved!','src/js/modules/main/apps/voice/views/realtime/realtime.html/realtime.html','private_key','UserchangepasswordController','intervals/:id/sub_intervals','firstLevel','fax/accounts/:id/interactions','user_has_chat_interactions:save','Calibri','src/js/modules/main/apps/contactmanager/views/contacts/contacts.html/contacts.html','Tatar','getBoundingClientRect','ndauth_url','cmCompany@get','get_json','assets/images/business/queueCampaigns.jpg','uploadPlugin','unknown','SmsQueue\x20properly\x20created','channel','Network','/queueCampaigns','zohoAccounts','isOnHold','intFreshsalesField','uploadComplete','-createdAt','DASHBOARDS.JULY','Chinese,\x20Mandarin\x20(Simplified,\x20China)','

','thirdLevelDisposition','VOICE.ALL_TEAMS','SYSTEM:DELETEwhatsappQueue','src/js/modules/main/apps/chat/views/chatQueues/edit/teamadd/teamadd.html/teamadd.html','delete\x20outboundroute','app.video','Variable','jv-ID','sms_queue:save','mailTransferReport','exportSelectedODBC','src/js/modules/main/apps/integrations/views/zendeskAccounts/edit/view.html/view.html','saveInternalRoute','TOOLS.TRIGGERS','ERROR\x20OPENING\x20JSCRIPTY\x20PROJECT','src/js/modules/core/theme-options/theme-options.html/theme-options.html','closeDialpad','plugins/:id/download','smsQueues','src/js/modules/main/apps/mail/views/mailAccounts/edit/apps/interval/dialog.html/dialog.html','Interval\x20deleted!','alaw','next','page','filteredAgents','deleteSelectedChatWebsiteInteractions','tagName','UserMailQueue','/snippet?token=','getSmsInteractions','Arguments','allowDelete','lists','vm.voiceQueue.joinempty.length\x20===\x201\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27paused\x27','Dutch','Notification\x20API\x20not\x20supported','Italian\x20(Italy)\x20/\x20Finnish\x20(Finland)','intFreshdeskAccount@get','/license','America/Argentina/Ushuaia','hasIntegrationsPermissions','ruri','passwordExpiresDays','delete\x20InboundRoutes','Condition','teamadddialog','monthsS','plugin@get','mapAgentsId','whatsapp/interactions/:id','phoneBarEnableSettings','&autoStart','OpenchannelAccountOpenchannelCannedAnswersController','savename','msNavigation','smsAccountApps','ZendeskAccount\x20updated!','dashboard:update','CHAT.OFFLINE_MESSAGE','ProjectsController','gotoIntervals','priority','\x27sms_interactions\x27','AgentsOpenchannelRealtimeController\x20as\x20vm','VOICE.RUNSENTIMENT_VOICERECORDING','FaxAccountId','OpenchannelRealtimeController','rpc/voice/channels/:uniqueid/stopmixmonitor','12000','f5f407f','delete\x20interactions','intervalAttr','app.jscripty.projects.edit','SYSTEM:GETCONFIGURATION','intDeskAccount','Variable\x20properly\x20created','InteractionDialogController','+05:30','src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/hoppers/dialog.html/dialog.html','enter','addMessage','app.fax','cm/custom_fields/describe','getVoiceChannels','holdHook\x20->\x20payload','onSaveOpenchannelQueue','newQueueCampaign','asc','src/js/modules/main/apps/contactmanager/views/lists/edit/agentadd/agentadd.html/agentadd.html','/api/settings/1/preferred','exportSelectedQueueCampaignHoppers','scrollWidth','Telugu\x20(India)','SquareRecording\x20properly\x20saved!','The\x20voicePrefix\x20will\x20be\x20deleted.','ChatQueueController','rpc/mail/accounts','targetEvent','AND','RunReportDialogController','\x273\x27','vm.queryFinal.filter','SYSTEM:UPDATECMHOPPERHISTORY','sortableOptions','editMailAccountApp','ar-DZ','api.intDeskConfiguration.save','Website','faxInteractions','ComposeOpenchannelInteractionDialogController','saveTelephone','createdAt,updatedAt,id,name,VoiceExtensionId,callerIdAll,description','content-type','/telephones','$promise','api.voiceChanSpy.update','$substring','PreviewDialogController','isMobile','openchannel/messages/:id/reject','nextContact','selectedReport','campaigns/:id/clone','api.intFreshdeskAccount.update','app.voice.voiceQueues.edit','Asia/Almaty','firstDayMonth','duration','Invalid\x20tag\x20name.','ZendeskConfiguration\x20properly\x20deleted!','addNewCloudProvider','main','outboundrouteApps','createOrEditProjectSession','align','Customization\x20properly\x20deleted!','createOrEditDisposition','src/js/modules/main/apps/voice/views/voicePrefixes/voicePrefixes.html/voicePrefixes.html','app/core/directives/ms-phonebar/sounds/dialpad/','VOICE.REALTIME','TOOLS.NOTIFICATIONS.TRIGGER_DELETE_MESSAGE','Dynamics365AccountConfigurationsController','gdpr','api.chatProactiveAction.save','amber-A200','autoAnswer','Tahoma','arraySmtp.service','api.intDynamics365Configuration.delete','Yes','createOrEditOutboundRoute','src/js/modules/core/directives/ms-stepper/templates/vertical/vertical.html/vertical.html','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20ivrCampaigns?','Image\x20is\x20loaded','customFieldsForm','InboundRouteController','getTemplates','src/js/modules/main/apps/voice/views/realtime/outbound_calls/view.html/view.html','setSinkId','integrations/zendesk/configurations/:id/tags','intervals/:id/clone','delete\x20Contexts','motion','InboundRouteController\x20as\x20vm','openchannel/reports/queue/:id','src/js/modules/main/apps/integrations/views/vtigerAccounts/create/dialog.html/dialog.html','icon-chart-line','getDaysOfWeek','apps.integrations.servicenowAccounts','deleteDeskAccount','api.openchannelQueue.update','Azerbaijani\x20(Azerbaijan)','TOOLS.NOTIFICATIONS.ACTIONS_DELETED_SUCCESS_TITLE','src/js/modules/main/apps/mail/views/mailAccounts/edit/view.html/view.html','getMetricName','onSaveSmsQueue','\x27port\x27','Indian/Maldives','Norwegian\x20Bokmal\x20(Norway)','#BDBDBD','GET_SOUND','deleteGroup','Trebuchet\x20MS,Helvetica,sans-serif','intervals','onSaveUserMailQueue','reportFields','CreateOrEditDynamics365ConfigurationDialogController','drafts','phoneBarDnd','Delete\x20Contact','exportSelectedCustomDashboards','permission','interactionid','app/main/apps/whatsapp','toNumber','FaxQueuesController','msClickToCall','uniqBy','apps.settings.customizations','outboundrouteid=','voice_queue_channel:remove','LoginController\x20as\x20vm','+11:00','Trunk\x20properly\x20cloned','cm/lists/:id/users','Report\x20properly\x20deleted!','vm_ac.chatWebsite.remote','selectAllCannedAnswers','selectedMailSubstatuses','saveFaxAccountApp','Interaction\x20has\x20been\x20closed!','GotoIfTime','DASHBOARDS.YESTERDAY','addNewChatWebsite','addNewDeskConfiguration','exportSelectedDeskAccounts','The\x20mailAccount\x20will\x20be\x20deleted.','Slovenian\x20(Slovenia)','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20sessions?','ComposeMailInteractionDialogController','citystate','voice/recordings/:id/download','isNaN','deleteWhatsappAccountWhatsappCannedAnswer','app.integrations.sugarcrmAccounts','MailRealtimeController\x20as\x20vm','faxQueues','\x27right\x27','CreateOrEditDeskAccountItemDialogController','convertDuration','chat/websites/:id/offline_messages','-01:00','Email\x20Account','black','role','URI','deleteSelectedSmsAccounts','America/Yakutat','AbandonedCallsMotionDialerRealtimeController\x20as\x20vm','canned_answers/:id/clone','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20hopper?','saveSmsAccount','deleteReport','opus','','canDelete','resolve','voiceMailMessage','Restore\x20Contact','\x27report_jscripty_sessions\x27','api.dashboardItem.save','AllCondition\x20properly\x20created','createOrEditTeam','createOrEditMailQueue','Asia/Anadyr','delete\x20Schedules','VIDEO.CANT_DOWNLOAD_THIS_FILE','SYSTEM:GETintZendeskAccount','addNewDynamics365Configuration','exportSelectedFaxAccounts','Europe/Chisinau','apps.sms.smsAccounts','ngValue','DESC','CustomDashboardsController\x20as\x20vm','screenRecording@get','intZendeskConfiguration','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/interval/dialog.html/dialog.html','-copy','Infobip','firstName','gotoIvrCampaigns','SmsAccount\x20properly\x20saved!','intSugarcrmAccount@get','VOICE.ALL_AGENTS','deselectFaxQueues','src/js/modules/main/apps/contactmanager/views/contacts/merge/dialog.html/dialog.html','Japanese\x20Female','delete\x20IvrCampaigns','Khmer\x20(Cambodia)','userpic','rpc/whatsapp/queues/waitinginteractions','ChatQueuesController','\x20is\x20not\x20supported!','/voice','AgentBusyFactor','api.smsQueue.update','4800','src/js/modules/main/apps/callysquare/views/projects/edit/edit/edit.html/edit.html','disableGetContact','app.motiondialer.realtime.queue_calls','Pacific/Rarotonga','tags/describe','deleteSelectedCustomDashboards','af-ZA','VOICE.EDIT_INBOUNDROUTE','Dispositions','-message','SYSTEM:ivrCampaign.REMOVELIST','searchReport','exportSelectedProjectSessions','ivrCampaigns','deleteSmsAccountSmsCannedAnswer','TrunkId','app/header','DASHBOARDS.ACCEPT_ELSEWHERE','monthDayFrom','outboundDropCallsDayTimeout','faxQueueReport','extraOperators','selectedMailAccountApps','Template','CreateOrEditFreshsalesConfigurationDialogController','/agents','SYSTEM:EDITMODALSHOW','Hebrew','\x27sv\x27','getSmsAccounts','src/js/modules/main/apps/voice/views/musiconholds/musiconholds.html/musiconholds.html','src/js/modules/main/apps/integrations/views/deskAccounts/deskAccounts.html/deskAccounts.html','Vertical\x20Navigation\x20with\x20Fullwidth\x20Toolbar','merge','CreateOrEditServicenowConfigurationDialogController','\x274800\x27','deleteFreshsalesAccount','src/js/modules/main/apps/fax/views/realtime/trunks/view.html/view.html','freshsalesAccount','title','smsAccount@get','USERPROFILE:GET_SECTION','createdAt,updatedAt,uniqueid,ContactId,calleridnum,calleridname,statedesc,countcongestionretry,countbusyretry,countnoanswerretry,countnosuchnumberretry,countdropretry,countabandonedretry,countmachineretry,countagentrejectretry,countglobal,scheduledat,starttime,responsetime,endtime,disposition,secondDisposition,thirdDisposition,ListId,UserId,VoiceQueueId,CampaignId,recallme,deleted,campaign','No\x20answers\x20available','intFreshdeskConfiguration','src/js/modules/main/apps/staff/views/teams/edit/agentadd/agentadd.html/agentadd.html','onVoiceExtensionUpdate','intSalesforceAccount','gotoReports','api.cmCustomField.save','es-GT','api.intServicenowAccount.update','EditInternalAppintervalDialogController','deleteCompany','faxMessage:update','saveMusicOnHold','apps.voice','ERROR\x20OPEN\x20CONTACT','createdAt,updatedAt,id,role,fullname,name,alias,showWebBar,email,phone,mobile,userpic,password,hotdesk,autointernal,internal,loginInPause,description,dtlscertfile,dtlsprivatekey,voicemail,transport,host,nat,type,allow,callerid,context,callgroup,pickupgroup,chanspy,videosupport,extensionMonitor,chatCapacity,mailCapacity,smsCapacity,openchannelCapacity,faxCapacity,whatsappCapacity,phoneBarEnableSettings,phoneBarAutoAnswer,phoneBarAutoAnswerDelay,phoneBarRingInUse,phoneBarEnableRecording,phoneBarEnableDtmfTone,phoneBarDnd,phoneBarUnansweredCallBadge,phoneBarEnableJaws,phoneBarOutboundProxy,phoneBarUnconditional,phoneBarUnconditionalNumber,phoneBarRemoteControl,phoneBarRemoteControlPort,phoneBarExpires,phoneBarListenPort,permissions,allowmessenger,phoneBarPrefixRequired,passwordResetAt,disabled,blocked,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/gotoif/dialog.html/dialog.html','SETTINGS.SMTP','msNavigation::stateMatched','AgentHomeAbandonedVoiceController','api.intVtigerAccount.save','eurfinnishfemale','fax/messages/:id/accept','src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/autoreply/dialog.html/dialog.html','STAFF.PERMISSIONS_SECTION_TITLE','MailAccountActionsController','voice/extensions/:id/applications','isFirstStep','English','Uighur','SYSTEM:GET_','\x27hotmail\x27','communications','deleteSelectedUsers','createOrEditSugarcrmConfiguration','fromTemplate','SYSTEM:GET_TREE_REPORT_STRUCTURE','multipleChoices','Motion\x20supports\x20multiple\x20translations\x20through\x20angular-translate\x20module,\x20but\x20currently\x20we\x20do\x20not\x20support\x20the\x20selected\x20language.\x20If\x20you\x20want\x20to\x20help\x20us,\x20send\x20us\x20a\x20message.','voiceAgentReport','integrations/vtiger/accounts/:id','expand','chat/websites/:id/interactions','cmCustomField','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/ringgroup/dialog.html/dialog.html','\x20has\x20been\x20saved!','SYSTEM:GETopenchannelAccounts','src/js/modules/main/apps/tools/views/trunks/trunks.html/trunks.html','Would\x20you\x20like\x20to\x20delete\x20','rows','api.voiceContext.delete','square/projects/:id/users','selectedTemplates','EU\x20(Frankfurt)','full-height','agentcompleteAt','removeApiKey','integrations/dynamics365/fields/:id/clone','Error404Controller','onRemoveFaxQueueChannel','deleteTag','isReschedule','IntervalsController\x20as\x20vm','app.staff.userProfiles.edit','multiselect','export','getDeskAccounts','transferHook\x20->\x20payload','ERROR\x20UPDATE\x20LOCAL\x20TABS','isMyAccount','loadingProgress','Schedule\x20properly\x20created','GRANTED',',xX,,,300,,,,,','INTEGRATIONS.NEW_VTIGERACCOUNT','addTab','\x27newTab\x27','The\x20freshdeskAccount\x20will\x20be\x20deleted.','integrations/dynamics365/accounts/:id/configurations','onSaveMailInteraction','/realtime','icon-script','HMAC','absorbEvent','saveOutboundRoute','WhatsappQueueagentaddController','closeDialog','Widget\x20deleted!','en-NG','orange','ngMessages','/callysquare','Europe/Samara','matchingField','facebook','src/js/modules/main/apps/mail/views/mailAccounts/edit/apps/tag/dialog.html/dialog.html','spychatInteraction','arraysubtractUnit','showWebBar','ap-southeast-2','getTeams','app.mail.realtime.agents','id,name,channel,status,description,createdAt,updatedAt','delete\x20zohoConfiguration','maxDateRange','scheduledCalls','src/js/modules/main/apps/integrations/views/deskAccounts/edit/item/dialog.html/dialog.html','gotoDeskAccounts','integrations/zendesk/fields/describe','Boxed','api.analyticReport.delete','STAFF.NOTIFICATIONS.PERMISSIONS_SAVED_SUCCESS_MESSAGE','Asia/Samarkand','messaging','app.plugins','FAX.EDIT_','CONTACTMANAGER.EDIT_LIST','MetricId','N/A','Georgian\x20(Georgia)','agentname','user:called','chat/groups/:id/clone','id,name,save_name','TOOLS.NOTIFICATIONS.DISPOSITION_CREATED_SUCCESS_TITLE','delete\x20Templates','disposition@get','ms-timeline-item','transferNumber','Delete\x20WhatsappAccount','reject','user_has_whatsapp_interactions:save','voiceQueue:remove','America/Santiago','\x27wav\x27','plugin:update','The\x20variable\x20will\x20be\x20deleted.','us-east-1','timer-stop','src/js/modules/main/apps/dashboards/views/general/agent/interaction/composeMail/dialog.html/dialog.html','arraytransport','projectSessions','rpcFaxQueuesWaitingInteractions','\x27agent_alias\x27','ActionId','SystemController','dropping','app.integrations','injector','api.faxAccount.update','awsLexRegion','Tags\x20has\x20been\x20set!','INTEGRATIONS.EDIT_SALESFORCEACCOUNT','selectedListCustomFields','changepassworddialog','delete\x20Teams','src/js/modules/main/apps/staff/views/users/create/dialog.html/dialog.html','label','openchannel/queues/:id/clone','activateHueSelection','deselectPauses','HELP.HELP','defaultEntry','selectedPlugins','SYSTEM:GET_TRUNKS','SMS\x20Queues','change','api.interval.delete','.ms-nav-button','get_path','DASHBOARDS.NONE','cm/custom_fields/:id','chat/interactions/describe','Corsican','downloadfile','SYSTEM:DELETEnetwork','others','TagInteractionDialogController','createOrEditVariable','integrations/dynamics365/configurations/:id/subjects','VtigerAccountController\x20as\x20vm','CreateOrEditSquareRecordingDialogController','integrations/freshdesk/fields/:id','STAFF.CLONE_USERPROFILE','MsNavigationController','monthDayTo','AgentFullname','newGlobalCustomField','cloudProviders/:id','UserOpenchannelAccount','America/Cambridge_Bay','msTimelineItem','deleteSugarcrmConfiguration','customTree','deleteSelectedContexts','Dynamics365AccountController\x20as\x20vm','createOrEditSmsAccount','inboundroute','getHeaderErrors','\x27power\x27','getMailAccountApps','deleteWhatsappCannedAnswer','ondevicechange','cm/companies/:id','STAFF.ALL_TEAMS','msMasonry:relayoutFinished','api.openchannelQueue.save','integrations/vtiger/configurations/:id/descriptions','getMailAccountLabel','internalroutes','src/js/modules/main/apps/tools/views/variables/variables.html/variables.html','TelephonesVoiceRealtimeController','app.mail.realtime.accounts','deleteMusicOnHoldMohSound','\x27strict\x27','createdAt,updatedAt,id,token,agentIdentifier,customerAlias,messageFontSize,name,key,address,remote,ListId,fidelity,timeout,agentAlias,closingQuestion,formSubmitSuccessMessage,formSubmitFailureMessage,color,color_focus,color_button,textColor,backgroundColor,fontSize,header_shape,showAgentAvatar,showCustomerAvatar,alignment,verticalAlignment,messagesAlignment,defaultTitle,animation,defaultWhiteLabel,whiteLabel,defaultLogo,conditionAgreement,autoclose,enableUnmanagedNote,unmanagedMessage,skipUnmanaged,sendUnmanaged,enableCustomerWriting,waitingTitle,waitingMessage,closingMessage,noteTitle,placeholderMessage,skipMessageButton,enableRating,ratingType,ratingStarsNumber,enableFeedback,forwardTranscript,forwardTranscriptMessage,closingMessageButton,download_transcript,enableCustomerAttachment,systemAlias,enquiry_enable,enquiry_forwarding,enquiry_forwarding_address,name_title,username_placeholder,email_title,email_placeholder,header_online,hideWhenOffline,header_offline,start_chat_button,offline_chat_button,offlineMessageSubject,offlineMessageBody,header_offline,offline_message,message_title,enquiry_message_placeholder,enquiry_button,rating_message,rating_send,rating_skip,acceptMethod,acceptUrl,rejectMethod,rejectUrl,closeMethod,closeUrl,onlineForm,offlineForm,mapKey,mapKeyOffline,forwardTranscript,forwardOffline,forwardOfflineAddress,IntervalId,timezone,waitForTheAssignedAgent,description,notificationSound,notificationShake,notificationTemplate','delete\x20item','deleteSelectedMailAccountApps','DASHBOARDS.SELECT_DATE','intSugarcrmField','deleteWhatsappAccount','Join','users/:id/sms_interactions','Europe/Moscow','SYSTEM:GETvoiceRecording','hue-3','hopperHistory\x20#','api.voiceMusicOnHold.update','arrayoutput','transfer','/metrics','rpcCalls','numbersto999','jscriptyQuestionReport','OdbcsController\x20as\x20vm','msMasonry:relayoutStarted','deleteMusicOnHold','#2196f3','whatsapp/accounts/:id/applications','exportSelectedAgents','SYSTEM:GET_REPORTS','selectedScreenRecordings','whatsapp/accounts/:id/clone','mailSubstatus@get','America/Lima','nov','deleteWhatsappQueue','Always','\x20ms','force_rport','onhold','sortableTable','getAssignedCompanies','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/goto/dialog.html/dialog.html','formatdate','openchannel/interactions/:id/clone','removeAttachment','Indonesian\x20(Indonesia)','exportSelectedTriggers','STAFF.NOTIFICATIONS.PERMISSIONS_ENABLED_ALL_SUCCESS_MESSAGE_NO_RESOURCES','integrations/servicenow/fields/:id/clone','chat/reports/queue/:id','addEventListener','sumHoldTime','src/js/modules/main/apps/tools/views/customDashboards/edit/view.html/view.html','PhoneBar\x20API\x20Error','Tamil\x20(India)','France\x20(France)','jscriptySessionReport','gotoInboundRoutes','checkRange','CreateOrEditVtigerConfigurationDialogController','arrayautopause','onRemoveUserChatQueue','Russian','analyticExtractedReport@get','ariaLabel','licenseKey','fail\x20callbackurl:\x22','compact','days','clear','voiceRecording@get','Delete\x20VtigerAccount','addNewMusicOnHold','faxAccount:save','MetricsController\x20as\x20vm','SmsAccount\x20updated!','integrations/servicenow/configurations/:id/subjects','api.user.removeApiKey','License','Carla','INTEGRATIONS.EDIT_ZOHOCONFIGURATION','Message\x20has\x20been\x20rejected!','CreateOrEditDynamics365AccountDialogController','ms-timeline','onUpdateVoiceQueue','allconditions','TOOLBAR.CHINESETRADITIONAL','createOrEditWhatsappQueue','#chat-dialog','onFinish','enqueue','Astrid\x20(Swedish,\x20Female)','selectedQueueCampaignHopperBlacks','isUndefined','addNewSalesforceConfiguration','Pacific/Norfolk','selectedDynamics365Configuration','OpenchannelAccountId','ChatQueueagentaddController','EditInboundAppvoicemailDialogController','src/js/modules/main/apps/motiondialer/views/ivrCampaigns/create/dialog.html/dialog.html','saveDynamics365Configuration','SYSTEM:UNPAUSEUSER','queryHopper','AgentGeneralJscriptyController','Penelope','api.screenRecording.save','America/Nome','createOrEditServicenowAccount','\x27report_sms_transfer\x27','gotoMusicOnHolds','src/js/modules/main/apps/openchannel/views/openchannelQueues/edit/agentadd/agentadd.html/agentadd.html','html-area','src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/custom/dialog.html/dialog.html','AgentHomeAbandonedBullController','SIP/','apps.whatsapp','Jscripty\x20can\x27t\x20open\x20the\x20contact','integrations/salesforce/accounts/:id/fields','ivrCampaignHopperHistories','delete\x20salesforceAccount','faxCapacity','integrations/zoho/configurations/describe','CustomDashboardController\x20as\x20vm','freshdeskAccounts','queryJscriptySession','endTime','SYSTEM:GETtrigger','onTransferCallback\x20->\x20session,\x20textContent,\x20position,\x20delay','faxInteraction:save','app.voice.realtime.outbound_calls','\x27cm_hopper\x27','Delete\x20ServicenowConfiguration','ClickSend','layoutStyle','Japanese\x20Male','isLoggedIn','marketplace','500','api.voiceContext.update','EditMailAccountAppautoreplyDialogController','onRemoveSmsQueue','saveCustomDashboard','Delete\x20DeskConfiguration','targetChanged','dialMethod','UserWhatsappAccount','mailAccounts','createOrEditDescription','src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/gotoif/dialog.html/dialog.html','Canadian\x20French\x20Male','getChatWebsiteInteractions','FaxAccount\x20properly\x20saved!','MOTIONDIALER.SELECTED_TEAMS','inboundrouteApps','app.tools.tags','chat/groups/:id/unread','id,name,metric,table','Macro','CreateOrEditZendeskAccountDialogController','src/js/modules/main/apps/chat/views/chatQueues/create/dialog.html/dialog.html','Hebrew\x20(Israel)','models','\x2721\x27','SYSTEM:GETTAGS','9888','horizontal','Polish','rule','multiBarChart','ChatWebsiteActionsController','SYSTEM:GETjscriptyProject','faxQueue@get','America/Argentina/Salta','mailbox','always','CHAT.SELECTED_TEAMS','DASHBOARDS.OPENED','voiceQueuesTotal','msFontFamily','ExtractedReport\x20properly\x20created','NavigationController\x20as\x20vm','newDynamics365Configuration','arraytype','createdAt,updatedAt,id,customer_id,fullname,email,password,mailbox,context,tz,attach,envelope,delete,emailbody,emailsubject,maxsecs,maxmsg','Invalid\x20company\x20name.','nospace','Outbound\x20Call','stopUpload','Unable\x20to\x20shutdown\x20Jabra\x20library','cm/hopper_final/describe','spymailInteraction','red-300-fg\x20icon-phone-in-talk','Start\x20Date','ComposeFaxInteractionDialogController','src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/tag/dialog.html/dialog.html','extraData','UserId','','app.voice.outboundroutes','shutdown','Whatsapp\x20Queues','openSettings','saveSmsAccountApp','CreateOrEditIvrCampaignDialogController','Delete\x20Widget','3rd','chanSpy','America/Paramaribo','hour','countglobal','smsQueue:update','The\x20extension\x20','createOrEditDynamics365Account','openDraft','INTEGRATIONS.EDIT_FRESHSALESCONFIGURATION','Tatyana\x20(Russian,\x20Female)','usmoney','','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20freshsalesConfiguration?','conditions/:id/clone','America/Hermosillo','Europe/Gibraltar','arrayvideosupport','SugarcrmAccount','CustomField\x20properly\x20deleted!','','mixmonitorid','top\x20right','operators','Dashboard','selectAllContexts','mminutes','ANALYTICS.NEW_METRIC','apps.chat.chatWebsites','icon-audiobook','ZohoAccount\x20properly\x20tested','analyticMetric@get','app.chat.realtime','addApplications','createdAt,updatedAt,id,name,description,createdAt,formData,enableUncompleteSave',':id','allDispositions','src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/ringgroup/dialog.html/dialog.html','apps.motiondialer','destconnectedlinenum','queueMethod','getZohoConfiguration','webbar:unhold','addNewMailQueue','play','delete\x20SugarcrmAccounts','HH:mm:ss','api.pause.delete','chat/websites/:id/fields','integrations/dynamics365/fields/describe','Europe/Riga','rpc/agents','globalStatusFilter','startcase','duplicate','whatsapp/interactions/:id/download','\x27pai\x27','exportSelectedGlobalCustomFields','You\x20can\x27t\x20remove\x20an\x20outbound\x20route\x20associated\x20to\x20an\x20out\x20prefix','SETTINGS.AITOOLS','voicePrefix','deep-orange','$mdSidenav','src/js/modules/main/apps/analytics/views/reports/run/dialog.html/dialog.html','\x27datetime\x27','openString','image','Numbers\x20to\x2099','apps.integrations.freshdeskAccounts','delete\x20SmsQueues','Lists','deselectInternalRoutes','Windows','chat/interactions/:id/tags','SYSTEM:GETtags','ERROR','Kimberly','whatsappAccount@get','cannedAnswers','customDashboards','editChatWebsiteApp','onRemoteTransfer\x20->\x20evt,\x20data','companiesMap','chatMessage:update','onTransfer','src/js/modules/main/apps/sms/views/smsAccounts/edit/agentadd/agentadd.html/agentadd.html','EditChatWebsiteAppnoopDialogController','deletedAt','noop','src/js/modules/main/apps/voice/views/outboundroutes/create/dialog.html/dialog.html','showIncompleteSubmitButton','MohSound\x20deleted!','Do\x20you\x20want\x20to\x20close\x20the\x20interaction?','Spanish\x20(Nicaragua)','users/:id/fax_accounts','Delete\x20VtigerConfiguration','TrunksController\x20as\x20vm','TeamsController\x20as\x20vm','Lucky\x20day','faxQueuesTotal','getIconByChannel','green-300-fg\x20icon-phone-in-talk','crudPermissions','MailCannedAnswer\x20properly\x20saved!','onRemoveMailQueue','WHATSAPP.WHATSAPP','integrations/zendesk/configurations/:id','zh-HK','api.intServicenowConfiguration.save','variableName','selectedPalette','$attrs','MusicOnHold\x20properly\x20saved!','agentcalledAt','stop\x20plugin\x20process','starttime','FaxAccountInteractionsController','uk-UA','save_name','\x27q\x27','TelephonechangepasswordController','hi-IN','/mailSubtatuses','AgentHomeScheduledCallsController','SmsAccountDispositionsController','voice/mails/messages/:id','WHATSAPP.NEW_WHATSAPPCANNEDANSWER','templates/describe','SYSTEM:DELETEintFreshdeskAccount','voice_outbound_channel:save','delete\x20Pauses','The\x20vtigerConfiguration\x20will\x20be\x20deleted.','fileSuccess','This\x20Month','voice/mails/:id/clone','faxQueue:update','sessionTarget','You\x20are\x20not\x20the\x20owner\x20of\x20the\x20last\x20message!','AllCondition\x20properly\x20deleted!','W:\x20Enable\x20private\x20whisper\x20mode,\x20so\x20the\x20spying\x20channel\x20can\x20talk\x20to\x20the\x20spied-on\x20channel\x20but\x20cannot\x20listen\x20to\x20that\x20channel.','Nepali\x20(Nepal)','deleteSelectedProjects','interval','findBy','0.26','CreateOrEditSugarcrmConfigurationDialogController','dispose','exportSelectedUserProfiles','SquareRecording','MOTIONDIALER.ALL_AGENTS','deleteSelectedContacts','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20voicePrefixes?','Transfer','unshift','ServicenowAccount\x20properly\x20created','STAFF.AGENTS','api.sms.account','selectedSmsAccountSmsCannedAnswers','whatsappInteractionTags:save','OpenchannelQueueagentaddController','exportSelectedWhatsappQueues','Pacific/Auckland','\x20DESC','deleteQueueCampaignHopperFinal','Reports','Process\x20restarted!','dashboards/:id/clone','unlicensed','cm/hopper/preview','rpc/openchannel/queues/waitinginteractions','src/js/modules/main/apps/tools/views/intervals/intervals.html/intervals.html','IS_LESS_THAN','IvrCampaign\x20properly\x20saved!','en-CA','UserProfileController\x20as\x20vm','scrollLeft','\x27ws\x27','Plugin\x20installed!','app/main/apps/dashboards','The\x20cloudProvider\x20will\x20be\x20deleted.','TOOLBAR.STAY_LOGGED','dashboard@get','smsInteractions','onActionSelection','CreateOrEditScheduleDialogController','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20plugins?','src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/interval/dialog.html/dialog.html','):Goto(','TOOLS.NOTIFICATIONS.ACTIONS_DELETE_TITLE','sessionId\x20required','saved','trunks/describe','German','deleteChatCannedAnswer','deleteChatWebsite','companies','integrations/zendesk/configurations/describe','FreshdeskConfiguration\x20properly\x20created','rpc/fax/queues','auth/local/forgot','src/js/modules/main/apps/analytics/views/reports/copy/dialog.html/dialog.html','getExtension','Pacific/Galapagos','grey','saveTrigger','delete\x20Dynamics365Accounts','focus','SMS.NEW_SMSQUEUE','faxInteractionDownload','createOrEditContext','run','apps.integrations.vtigerAccounts','createOrEditTriggerAnyCondition','apps.contactmanager.contacts','TeamagentaddController','calleridnum','EditOpenchannelAccountAppnoopDialogController','onCollapse','Ricardo','botname','msHorizontalStepperStep','evt','Outlook365','src/js/modules/main/apps/motiondialer/views/ivrCampaigns/edit/listadd/listadd.html/listadd.html','CreateOrEditActionDialogController','ivrTotalCallsDays','VtigerAccount\x20properly\x20saved!','altDate','\x27cm_lists\x27','exportSelectedVariables','msScrollOptions','MyTitle','ANALYTICS.METRICS','EditOpenchannelAccountAppagentDialogController','QuickPanelController','ca-central-1','createOrEditIvrCampaign','apps.home.abandoned','fullname','Network\x20properly\x20created','Task','opt1','users/:id/queues','UserChatQueue','MSIE','700','firstLastDayMonth','The\x20freshsalesConfiguration\x20will\x20be\x20deleted.','Read_permission','app.integrations.freshsalesAccounts.edit','WhatsappCannedAnswer\x20deleted!','delete\x20customField','createdAt,updatedAt,id,name,mode,directory,application,format,sort','treeDefaultEvents','src/js/modules/main/apps/tools/views/triggers/edit/anyconditions/create/dialog.html/dialog.html','SugarcrmAccountsController\x20as\x20vm','intDeskAccount@get','VoiceRecording\x20properly\x20deleted!','api.user.delete','src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/queue/dialog.html/dialog.html','sounds','src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/queue/dialog.html/dialog.html','Disposition','saveUser','checkSectionResources','createdAt,updatedAt,id,name,interval','createdAt,updatedAt,id,name,dialActive,TrunkId,TrunkBackupId,type,IntervalId,dialCheckDuplicateType,dialCutDigit,acw,acwTimeout,autopause,ringinuse,memberdelay,timeoutrestart,monitor_format,context,setinterfacevar,setqueuevar,setqueueentryvar,dialOrderByScheduledAt,dialRecallMeTimeout,dialRecallInQueue,dialGlobalInterval,dialTimezone,dialAMDActive,dialAMDInitialSilence,dialAMDGreeting,dialAMDAfterGreetingSilence,dialAMDTotalAnalysisTime,dialAMDMinWordLength,dialAMDBetweenWordsSilence,dialAMDMaximumNumberOfWords,dialAMDSilenceThreshold,dialAMDMaximumWordLength,dialMethod,dialPowerLevel,dialPredictiveOptimization,dialPredictiveOptimizationPercentage,dialPredictiveInterval,dialLimitQueue,dialOriginateCallerIdName,dialOriginateCallerIdNumber,dialRandomLastDigitCallerIdNumber,dialOriginateTimeout,dialPrefix,dialQueueOptions,dialQueueTimeout,strategy,timeout,retry,wrapuptime,weight,musiconhold,dialQueueProject,dialQueueProject2,dialAgiAfterHangupAgent,dialGlobalMaxRetry,dialCongestionMaxRetry,dialCongestionRetryFrequency,dialBusyMaxRetry,dialBusyRetryFrequency,dialNoAnswerMaxRetry,dialNoAnswerRetryFrequency,dialNoSuchNumberMaxRetry,dialNoSuchNumberRetryFrequency,dialDropMaxRetry,dialDropRetryFrequency,dialAbandonedMaxRetry,dialAbandonedRetryFrequency,dialMachineMaxRetry,dialMachineRetryFrequency,dialAgentRejectMaxRetry,dialAgentRejectRetryFrequency,description,mandatoryDisposition,mandatoryDispositionPauseId,dialPredictiveIntervalMaxThreshold,dialPredictiveIntervalMinThreshold','mailQueuesTotal','cm/hopper_final/checkContactHopper','QueueCampaignHopperHistoriesController','delete\x20hopperHistory','src/js/modules/main/apps/voice/views/realtime/agents/view.html/view.html','eurspanishfemale','FORGOTPASSWORD.LINK_SENT','Team\x20properly\x20deleted!','Restored','chatAccounts','SYSTEM:GETlists','SmsQueue\x20properly\x20saved!','intServicenowConfiguration','createdAt,updatedAt,id,name,basename,savename,type,startDate,endDate,status,output,reportId,reportType','reportField','DASHBOARDS.MAY','400','addNewContext','us-east-2','OpenchannelCannedAnswer\x20properly\x20saved!','currentUser','EditChatWebsiteAppsystemDialogController','addLists','interface','error-404','createdAt,updatedAt,id,type,value,username,password','appType','\x27quarters\x27','Indian/Mahe','deleteSelectedScheduler','Basque\x20(Spain)','may','basicstyles','resultsLoading','src/js/modules/main/apps/integrations/views/salesforceAccounts/edit/configurations/dialog.html/dialog.html','SYSTEM:queueCampaign.REMOVELIST','Numbers\x20to\x20999','newIvrCampaign','openchannelAccountApps','SYSTEM:GETreport','ChatInternalController','DASHBOARDS.SELECT_ACCOUNT','chatMessage','arraydtmfmode','queryResult','hkchinesefemale','app.errors','api.chatGroup.delete','agent\x20updated!','createdAt,updatedAt,id,name,description','disabled','createOrEditSound','/ivr_campaigns','localStorage','Contact\x20not\x20available','delete\x20servicenowAccount','TOOLBAR.PASSWORD_EXPIRE_REMAINING_DAYS','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20proactive?','STAFF.CONFIRM','api.telephone.save','America/Bahia','orientation','selectedQueueCampaignHopperFinals','getOutboundRouteApps','animate','setFoldedOpen','currentNode','openchannel.openchannelAccounts','pl-PL','application','number','whatsapp/reports/transfer/:id/clone','attrs','$element','CreateOrEditZendeskAccountItemDialogController','location','app.voice.inboundroutes.edit','Delete_permission','angucomplete-alt:changeInput','SYSTEM:GETchatAccounts','mouseenter','api.smsAccount.save','refreshDate','wide','onProgress\x20->\x20session,\x20data','unreadMessages','\x27zoho.com\x27','MotionDialer','es-PA','addons','position','IvrCampaignblacklistaddController','\x27unknown\x27','api.voiceQueue.clone','newServicenowConfiguration','FreshsalesAccountController\x20as\x20vm','+13:45','Pacific/Bougainville','CONTACTMANAGER.NEW_HOPPER','selectedChatWebsiteInteractions','More','api.action.save','unreadTotalGroupMessages','icon-checkbox-marked-circle','\x27mail_accounts\x27','gu-IN','selectedContacts','AgentHomeDashboardMultiChannelMailController','code','extravar','delete\x20cannedAnswer','projects','editdialog','Delete\x20ChatCannedAnswer','EditOpenchannelAccountAppautoreplyDialogController','/internalroutes','cannedAnswer@get','en-TZ','app.voice.voiceRecordings','whatsapp/queues/:id','/sugarcrmAccounts','queryHistory.filter','chatQueues','deviceInfo','NoSuchNumber','getIvrCampaignHoppers','session\x20#','Call_Status','savePlugin','ChatWebsiteInteractionsController','cm/contacts/:id/hopper_finals','ChatWebsiteChatDispositionsController','src/js/modules/main/apps/openchannel/views/realtime/realtime.html/realtime.html','startingAllowedItems','app.dashboards.general.user','Are\x20you\x20sure\x20want\x20to\x20stop\x20the\x20plugin\x20attached\x20process?','openchannel','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20users?','app.sms','TOOLS.NOTIFICATIONS.TRIGGERS_DELETED_SUCCESS_TITLE','Dynamics365Account\x20properly\x20saved!','DELETE','api.chatQueue.save','DashboardItem\x20properly\x20saved!','dayOfWeekTo','ALWAYS','onClick','INTEGRATIONS.NEW_SUGARCRMCONFIGURATION','goToEditState','TOOLS.NOTIFICATIONS.CONDITIONS_DELETED_SUCCESS_TITLE','Korean\x20Female','The\x20smsQueue\x20will\x20be\x20deleted.','auth/local/reset/:token','MsPhonebarController','app.dashboards.custom','offlineForm','EditChatWebsiteAppqueueDialogController','chat/applications/describe','GET_INTERVAL','chatGroup','\x27cm_contacts\x27','sessionId','rpcAgents','Spanish\x20(Chile)','INTEGRATIONS.DESKACCOUNTS','Outbound','onSaveWhatsappQueue','newChatWebsite','project_id','America/Santarem','QueueCampaignagentaddController','url','sms','INTEGRATIONS.EDIT_DYNAMICS365CONFIGURATION','msBlink','apps.analytics.reports','CreateOrEditAgentDialogController','triggers/:id/any_conditions','api.squareRecording.update','Delete\x20MailQueue','CloudProvider\x20properly\x20saved!','saveTeam','Warning','notification','\x20Contacts\x20selected','cmContact@getHopperFinals','SYSTEM:GETusers','delete\x20vtigerAccount','deleteSelectedIvrCampaignHoppers','$stateChangeSuccess','vm.voiceQueue.joinempty.length\x20===\x201\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27unavailable\x27','chatWebsiteInteractions','squareRecordings','Dora','AgentsMotionDialerRealtimeController\x20as\x20vm','selectedProjectSessions','ChatWebsiteChatCannedAnswersController','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20projects?','MusicOnHold\x20updated!','Help','DASHBOARDS.DASHBOARDS','maxdigit','dateFilterLocalizationFactory','hasChildrenPermissions','vm.detailForm.$pristine','chatQueue','textContent','High','Gecko','clearFilter','sounds/:id/clone','version/fetch','createdAt,updatedAt,id,name,host,zone,clientId,clientSecret,code,refreshToken,serverUrl,description','aws_access_key_id','Delete\x20Odbc','\x27zoho.eu\x27','toTrusted','chanSpy\x20properly\x20deleted!','newServicenowAccount','integrations/vtiger/accounts/:id/fields','cm/lists/:id/contacts','bot','inbound','Pacific/Wallis','HANGUPCAUSE_41','integrations/freshsales/fields/:id/clone','joinTables','angular-cron-jobs','chatCurrentCapacity','angucomplete-alt','call_id','exportSelectedTriggerAnyConditions','newNetwork','AgentsMailRealtimeController\x20as\x20vm','analytics/custom_reports/:id/preview','api\x20preview','mailServerOut','WhatsappAccountInteractionsController','triggers/:id/actions','addNewCannedAnswer','UserProfilepermissionsmanageController','0.00','Uzbek','Ines\x20(Portuguese,\x20Female)','attrVoiceQueues','saveReport','Smpt\x20id\x20unknown','voice/contexts/:id','api.staff.save','app.staff.agents','us-west-2','mailAccountApps','MailAccountsRealtimeController\x20as\x20vm','addNewCustomization','Javanese\x20(Indonesia)','socket','delete\x20sugarcrmConfiguration','addTeams','AgentsController\x20as\x20vm','canGoInConference','addNewSchedule','screenRecording\x20properly\x20saved!','fax/interactions/describe','KDE','huhungarianfemale','/:id?tab','addNewAllCondition','New\x20Report\x20Field','VoiceMusicOnHoldId','length','SYSTEM:DELETEjscriptyProject','chart.js','vm.password','America/Inuvik','square/odbc/describe','userStatusOptions','placeholder','rpc@getTelephones','\x27wrapup\x27','apps.tools.customDashboards','CustomDashboardItemsController','QueueCampaignController\x20as\x20vm','FaxQueueteamaddController','Inbound','configurations','createOrEditVoicemail','getConfigurations','EditMailAccountApptagDialogController','mailSubstatus','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20odbcs?','rpc@getMailQueues','\x20yyyy','teams/:id/users','chat/queues/describe','finals','VOICE.EDIT_VOICEQUEUE','faxCurrentCapacity','app.help.about','newDisposition','getBlackLists','cm/hopper/:id','ms-nav-folded-open','Would\x20you\x20like\x20to\x20save\x20your\x20survey?','idle','What\x20would\x20you\x20name\x20your\x20list?','RequestLicenseDialogController','src/js/modules/toolbar/layouts/vertical-navigation/toolbar.html/toolbar.html','\x2714400\x27','rpc/agents/:id/capacity','TelephonesController\x20as\x20vm','TOOLBAR.TURKISH','options','\x27user\x27','Brian','app.voice.realtime.queues','TOOLS.CUSTOMDASHBOARDS','\x27unavailable\x27','properties','WhatsappQueuesController\x20as\x20vm','deselectServicenowAccounts','\x271\x27','exportSelectedIntervalIntervals','VoiceQueueagentaddController','apps.staff.userProfiles','selectAllProjects','jpg','MailAccountagentaddController','authenticate','QUICKPANEL.NEW_CHATGROUP','app.tools.triggers.edit','Danish\x20(Denmark)','fax/accounts/addaccountapplications','CreateOrEditQueueCampaignDialogController','deleteProject','ChatWebsiteId','Jscripty\x20Sessions','Company\x20updated!','\x27th\x27','ukenglishmale','abandoned','ChatWebsiteScriptController','+07:00','square/details/reports/describe','EditInboundAppringgroupDialogController','analytics/extracted_reports/:id','delete\x20InternalRoutes','EditOpenchannelAccountAppamazonlexDialogController','src/js/modules/errors/500/error-500.html/error-500.html','Portuguese\x20(Brazil)','createdAt,updatedAt,id,name,description,crudPermissions','vm.voiceQueue.leavewhenempty.length\x20===\x201\x20&&\x20vm.voiceQueue.leavewhenempty[0]\x20===\x20\x27invalid\x27','Asia\x20Pacific\x20(Sydney)','newWhatsappAccount','saveSalesforceAccount','jscripty/projects/:id/summary','when','ExecIf','Teams','MAIL.NEW_MAILACCOUNT','\x20is\x20not\x20valid','OmniWeb/','Africa/Accra','mailCurrentCapacity','Pacific/Gambier','ceil','CreateOrEditMailAccountDialogController','api.trigger.update','saveDisposition','\x27agent_fullname\x27','SETTINGS.CUSTOMIZATIONS','showInteraction','TagsController\x20as\x20vm','selectedResultIndex','hiddendigitsnum','RR\x20Memory','ChatQueue\x20properly\x20created','app.chat.realtime.queues','forIn','ChatWebsitesystemAvatarController','unreadMessage','sms/accounts/:id/notify','European\x20Czech\x20Female','@token','resources','EditWhatsappAccountAppcloseDialogController','TOOLS.NOTIFICATIONS.DISPOSITION_DELETE_TITLE','Portuguese\x20(European)','onInternalMessageUpdate','openchannelStatusTime','intFreshdeskAccount','\x20properly\x20saved!','responseData','congestion','voiceStatus','delete\x20FaxAccounts','','DASHBOARDS.MAIL','mail/queues/:id/users','apps.voice.voiceQueues','highlight','eurfrenchfemale','globalCustomFieldForm','CONTACTMANAGER.SELECTED_AGENTS','Asia/Ust-Nera','src/js/modules/main/apps/voice/views/realtime/telephones/view.html/view.html','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20zendeskConfiguration?','app.tools.dispositions','deleteSelectedChatWebsiteChatCannedAnswers','BLACKLIST','Arabic\x20(Algeria)','addNewIvrCampaign','src/js/modules/main/apps/staff/views/users/edit/changepassword/changepassword.html/changepassword.html','SYSTEM:GET_VOICEQUEUES','Maltese','integrations/servicenow/accounts/:id/fields','api.project.delete','full','Context\x20properly\x20saved!','SETTINGS.NEW_SMTP','rpc/openchannel/queues/:id/notify','PrefixDialogController','Europe/Stockholm','analytics/custom_reports/:id/clone','/plugin/:id','DASHBOARDS.SELECT_DATE_RANGE','.ms-search-bar-results','bottom_right','zendeskAccount','InteractionId','newVtigerAccount','chat/internal/messages/describe','pauseTypeFilter','Asia/Baghdad','src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/agentadd/agentadd.html/agentadd.html','app.mail.mailQueues.edit','Attached\x20pm2\x20process\x20successfully\x20stopped','appVersion','SmsQueuesController','RecordDialogController','SYSTEM:GETmailAccount','#4CAF50','app.integrations.servicenowAccounts.edit','GROUP_CONCAT','question','EditFaxAccountAppcloseDialogController','open','ServicenowConfiguration\x20properly\x20saved!','isSame','allowmessenger','keyCode','rules','applyTo','sms/accounts/:id/canned_answers','fax/accounts/:id/applications','Templates','TOOLS.NOTIFICATIONS.TRIGGER_SAVED_SUCCESS_TITLE','intSalesforceConfiguration','ServicenowAccountsController','tcp','The\x20max\x20allowed\x20size\x20is\x20','OpenchannelInteractionId','useSanitizeValueStrategy','src/js/modules/navigation/layouts/horizontal-navigation/navigation.html/navigation.html','getObject','startOf','CreateOrEditReportFieldDialogController','deleteWidget','SYSTEM:GET_SOUNDS','api.user.update','xorWith','displayName','voice/recordings/:id','mohSound\x20#','join','SYSTEM:GET_VOICEMAILS','delete\x20sugarcrmAccount','hasClass','WhatsappQueueId','EditInternalAppsetDialogController','AEC','Email\x20Messages','sound','createdAt,updatedAt,id,name,key,ListId,remote,token,type,accountSid,authToken,phone,receiveUrl,deliveryReportUrl,notificationShake,notificationSound,notificationTemplate,queueTransfer,queueTransferTimeout,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,agentTransfer,agentTransferTimeout,description','ms-form-wizard','Delete\x20Dynamics365Configuration','onChangeEnableAllResources','clonedialog','Email\x20Report\x20Queue','cmHopperFinal','MarketplacePluginsController\x20as\x20vm','pickerModel','\x27pt-BR\x27','toggleMsNavigationFolded','America/Atikokan','cm/lists/:id','deleteOpenchannelAccountInteraction','delete\x20salesforceConfiguration','showOpenchannelInteraction','vm_home.sidebar','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20mailSubtatuses?','lll\x20Z','api.intSugarcrmAccount.update','Fax\x20Report\x20Queue','integrations/vtiger/configurations/:id/subjects','call','users/:id/fax/interactions','palettes','CHAT.EDIT_CHATQUEUE','networks/:id','app.motiondialer.realtime.agents','#ffffff','prefixes','out','saveWhatsappAccountApp','cm/hopper_final/campaign/countAttributes/:id','TOOLS.EDIT_ALLCONDITION','users/:id/square_projects','mute','selectAllMetrics','CloudProvidersController\x20as\x20vm','referAttended\x20->\x20session','EditMailAccountAppsystemDialogController','api.cloudProvider.save','ZendeskAccountsController\x20as\x20vm','Project\x20properly\x20deleted!','createdAt,updatedAt,id,name,description,table,parent,conditions,joins','b:\x20Only\x20spy\x20on\x20channels\x20involved\x20in\x20a\x20bridged\x20call.','Field\x20deleted!','createdAt,updatedAt,id,name,description,color','timeout','msAdvancedSearch','firstName,lastName,mobile','src/js/modules/main/apps/contactmanager/views/globalCustomFields/create/dialog.html/dialog.html','selectedMusicOnHoldMohSounds','America/Montevideo','selectAllGlobalCustomFields','FAX.EDIT_FAXACCOUNT','telephoneForm','delete\x20metric','dispositions/:id','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20templates?','SYSTEM:DELETEvoiceQueue','SYSTEM:GETvoiceQueues','fax/messages/:id/clone','SchedulesController\x20as\x20vm','api.intSalesforceAccount.update','saveReschedule','daysOfWeek','TrunksVoiceRealtimeController\x20as\x20vm','SYSTEM:GETConfigurations','setTags','WhatsappQueue','stepNumber','DeskAccount\x20updated!','voice/mails/:id','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20hopperFinal?','Agent\x20logout','src/js/modules/main/apps/callysquare/views/projects/edit/info/info.html/info.html','onSelectListSuccess','lastDayMonth','listCustomFields','name,id','removeQueues','selectAllTelephones','hasSectionsPermissions','America/Indiana/Petersburg','Start\x20Video\x20Call','condition','RescheduleCallDialogController','monthFrom','ChatGroupId','src/js/modules/main/apps/tools/views/trunks/edit/clone/clone.html/clone.html','contexts','createList','createdAt,updatedAt,id,name,type,username,remoteUri,authType,password,token,serverUrl,description','Europe/Kiev','API:ERROR','addSound','onSaveUserFaxQueue','gotoNextStep','ms-shortcuts','chatQueue:remove','putOtherCallsOnHold\x20->\x20session','Fax\x20Interaction','dualMultiselectOptions','src/js/modules/main/apps/voice/views/musiconholds/edit/mohSounds/dialog.html/dialog.html','contactSearch','channelStatusOut','src/js/modules/main/apps/staff/views/teams/create/dialog.html/dialog.html','\x27report_whatsapp_transfer\x27','SquareProjectId','whatsapp/messages/:id/accept','icon-crosshairs','\x27rfc2833\x27','CreateOrEditProjectDialogController','onLogged','contents','Hopper\x20properly\x20saved!','closest','America/Santa_Isabel','SYSTEM:GETsmsAccounts','Delete\x20CloudProvider','WhatsappQueueteamaddController','ngMaterial','getDateFromString','apps.motiondialer.realtime','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?','onConnect','drop','CANCEL','Somali','Antarctica/Vostok','CTI\x20URL','SMS\x20Report\x20Transfer','whatsapp/accounts/:id','src/js/modules/main/apps/sms/views/smsAccounts/create/dialog.html/dialog.html','deleteSmsCannedAnswer','INTEGRATIONS.EDIT_FRESHDESKCONFIGURATION','msNavToggle','delete\x20vtigerConfiguration','getLists','stopInterval','src/js/modules/main/apps/voice/views/realtime/trunks/view.html/view.html','EditInternalAppgotoDialogController','STAFF.ALL_AGENTS','SYSTEM:queueCampaign.RESETLIST','floor','src/js/modules/main/apps/voice/views/voiceRecordings/create/dialog.html/dialog.html','getContacts','NetworksController','isActive','getZendeskAccounts','automation','variable_id','msTabScroll','SYSTEM:GETvoiceMusicOnHold','America/Boa_Vista','QueueCampaign\x20properly\x20created','ANALYTICS.CREATE','gotoPreviousStep','top','Spanish\x20(Costa\x20Rica)','The\x20status\x20will\x20be\x20changed\x20to:\x20','app.contactmanager.globalCustomFields','INTEGRATIONS.NEW_FRESHDESKCONFIGURATION','getUsers','.result','Marlene','SYSTEM:DESCRIBE','CONTACTMANAGER.NEW_COMPANY','arraysidebar','/voicePrefixes','VOICE.INBOUND','CustomField\x20deleted!','ZendeskAccount\x20properly\x20saved!','deleteServicenowAccount','whatsapp','api.intSugarcrmConfiguration.save','microphoneMute','$document','extractedReports','CreateOrEditVtigerAccountDialogController','There\x20has\x20been\x20an\x20error\x20while\x20trying\x20to\x20save\x20your\x20survey\x20session!','app.tools','app.analytics.reports.edit','src/js/modules/main/apps/tools/views/intervals/create/dialog.html/dialog.html','actions/describe','Justin','deleteSelectedReportFields','CreateOrEditOpenchannelCannedAnswerDialogController','selectedcrudPermissions','SYSTEM:DELETEvoiceMail','addNewDisposition','downloadOpenchannelInteraction','createdAt,updatedAt,id,ContactId,phone,countcongestionretry,countbusyretry,countnoanswerretry,countnosuchnumberretry,countdropretry,countabandonedretry,countmachineretry,countagentrejectretry,scheduledat,priority','SmsRealtimeController','api.cloudProvider.update','Arabic\x20(Oman)','both','api.tag.delete','deleteSelectedOpenchannelAccountOpenchannelCannedAnswers','elements','\x27chat_interactions\x27','SYSTEM:GET_CHATACCOUNTS','LicenseController','en-US','DASHBOARDS.OPENCHANNEL','preventDefault','users/:id/login','delete\x20queueCampaign','selectAllExtractedReports','src/js/modules/main/apps/settings/views/generals/generals.html/generals.html','app.voice.realtime','editOutboundRouteApp','getQueueCampaignHopperHistories','MailRealtimeController','IvrCampaignsController\x20as\x20vm','getOpenchannelInteractions','verifysmtpverifysmtp','integrations/sugarcrm/fields/describe','getVoiceQueues','createdAt,updatedAt,id,field,alias,function,format,groupBy,orderBy,custom,MetricId','hide','variable@get','X-CID:\x20','MsWidgetEngineMultibarChartController','Sesotho','delete\x20internalroute','selectAllVoiceQueues','cmn-Hans-HK','Africa/Maputo','selectedMailShowSystemMessage','tls','_new','EditFaxAccountAppgotoifDialogController','getSenders','rpc/sms/queues','invite','replace','chat/messages/:id','questionId','TCL:\x20vm.path','Integration_Tab','rpc@getOutboundChannels','user_has_fax_interactions:save','SYSTEM:GET_USERPROFILES','ENTER','Maxim\x20(Russian,\x20Male)','00:00:00','amber-A200-bg','sessionConf','addNewProject','username','deleteSelectedSubjects','substring','queueCampaignHoppers','requestLicense','The\x20license\x20has\x20been\x20updated!','America/North_Dakota/Center','INTEGRATIONS.NEW_DYNAMICS365ACCOUNT','apps.home.recordings','src/js/modules/main/apps/plugins/views/plugin/plugin.html/plugin.html','443','protocol','isEmpty','createOrEditInternalRoute','saveQueueCampaign','originator','contcts','\x277200\x27','VIDEO.WRONG_EXTENSION','VOICE.RUNTRANSCRIBE_VOICERECORDING','editInboundRouteApp','integrations/desk/accounts/describe','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20freshdeskConfiguration?','Contact\x20properly\x20created','Campaign\x20Without\x20Lists','resizable','Delete\x20CustomDashboard','id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','registerMainForm','motion.shortcuts','Status\x20properly\x20changed\x20to:\x20','getRegisteredPalettes','api.agent.changePassword','Arial','\x27gsm\x27','Slovenian','DuplicateContactDialogController','round','getElementById','addNewMohSound','interval@get','Asia/Jayapura','zh-CN','xx-hacker','fi-FI','delete\x20MailSubstatuss','deleteMailQueue','DispositionsController','VoiceRecording\x20updated!','apps.home.whatsapp','Body','replyAll','answer','interactions','app.marketplace','Linux','selectedField','INTEGRATIONS.EDIT_','square/recordings/describe','Metric\x20properly\x20saved!','/contexts','QueuesMotionDialerRealtimeController\x20as\x20vm','America/Tegucigalpa','ms-stepper-step','newCustomDashboard','app.whatsapp.whatsappAccounts','getWhatsappQueuesWaitingInteractions','FooterController\x20as\x20vm','draftManager','unpause','Asia/Dili','avgTalkTime','CustomDashboard\x20properly\x20saved!','searchFields','createOrEditReportField','Arabic\x20(Lebanon)','revokeObjectURL','CreateOrEditSoundDialogController','selectedSubjects','home.whatsapp','GET_ODBC','SmsAccountsController\x20as\x20vm','campaigns/:id/blacklists','exportSelectedChatWebsiteOfflineMessages','VOICE.SELECTED_AGENTS','deselect_all','#interaction-content','channels','Message\x20deleted!','progressive','createOrEditvoicePrefix','runtranscribesentimentSelectedVoiceRecordings','Yesterday','DASHBOARDS.MARCH','app.integrations.salesforceAccounts.edit','Warning!\x20You\x20won\x27t\x20select\x20a\x20different\x20list\x20for\x20the\x20contact\x20','voiceDialReport','commitDate','API\x20reject\x20message\x20not\x20found:\x20','trigger@get','The\x20template\x20will\x20be\x20deleted.','api.smsAccount.update','Variable\x20properly\x20saved!','DisposeCallDialogController','EditoutboundAppcustomDialogController','gotoCustomDashboards','integrationTypes','delete\x20Variables','allCondition','values','AgentsSmsRealtimeController\x20as\x20vm','IvrCampaign\x20properly\x20cloned','selectAllWhatsappQueues','filtered','QueueCampaign\x20properly\x20cloned','The\x20tag\x20will\x20be\x20deleted.','The\x20project\x20cannot\x20be\x20started','app.openchannel','Amy\x20(English,\x20British,\x20Female)','Outgoing','Dashboards','newTemplate','isBetween','selectAllDeskAccounts','src/js/modules/main/apps/motiondialer/views/realtime/realtime.html/realtime.html','Turkish','QueueCampaignresetlistController','CreateOrEditTagDialogController','Chat\x20Interaction','api.intZohoConfiguration.save','Hans\x20(German,\x20Male)','network@get','md-toolbar','userForm','getQuestionWithResponseList','src/js/modules/main/apps/fax/views/faxQueues/faxQueues.html/faxQueues.html','CDR(tag)=','SugarcrmAccountsController','MARKETPLACE.PLUGINS','The\x20telephone\x20will\x20be\x20deleted.','PREVIEW','ZohoConfiguration\x20properly\x20created','Trunk','whatsappStatusTime','rpcMailQueues','Queues\x20association\x20has\x20been\x20updated!','users/:id/chat_websites','#3470ca','To\x20is\x20mandatory','CreateOrEditscreenRecordingDialogController','foreground','differenceWith','Zulu\x20(South\x20Africa)','api.chatWebsite.save','outbound','src/js/modules/main/apps/voice/views/inboundroutes/edit/view.html/view.html','delete\x20DeskAccounts','CreateOrEditSalesforceAccountDialogController','CreateOrEditChatWebsiteDialogController','Resource\x20part\x20\x22','DeskAccount\x20properly\x20saved!','/openchannel','arraycallcounter','EditoutboundAppintervalDialogController','callStatuses','newSalesforceAccount','Danish','sendUnpauseOnSubmit','\x27eu-west-1\x27','America/Caracas','api.mailSubstatus.delete','api.voiceExtension.delete','saveMailCannedAnswer','FaxQueuesController\x20as\x20vm','dashboards/:id','content-length','automations/:id','$cookies','autoAnswerDelay','unknown-version','OpenchannelAccount\x20properly\x20saved!','removeApi','DESCRIBE_CM_CONTACTS','Mailbox@Context','Naja','WHATSAPP.EDIT_WHATSAPPCANNEDANSWER','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20subject?','$ne','selectAllWhatsappAccounts','Nicole\x20(English,\x20Austrialian,\x20Female)','deselectGlobalCustomFields','pTalking','#ececee','\x27EU\x27','EditFaxAccountApp','src/js/modules/main/apps/voice/views/realtime/queue_params/view.html/view.html','deleteSelectedFaxAccountInteractions','color','CreateOrEditHopperVoiceQueueIdDialogController','es-BO','oldPassword','analytics/field_reports/:id/create_many','api.pause.save','pauseType','openchannelInteraction','vtigerAccounts','selectAllDispositions','\x27zh-HK\x27','app.dashboards','QueuesFaxRealtimeController\x20as\x20vm','integrations/servicenow/configurations/:id/descriptions','ServicenowAccountController\x20as\x20vm','saveInterval','savePassword','chatInteraction','clearSelection','Abandoned','/queue_calls','src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/view.html/view.html','deselectIntervals','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/set/dialog.html/dialog.html','formatter','startDate','chatInternalMessage:save','falsepriority','chat/reports/transfer/:id/clone','Bosnian','Linear','src/js/modules/main/apps/integrations/views/servicenowAccounts/edit/view.html/view.html','app.integrations.deskAccounts.edit','Chat\x20Report\x20Transfer','Switch','getDaysOfMonth','src/js/modules/quick-panel/tabs/groups/create/dialog.html/dialog.html','STAFF.NEW_TELEPHONE','\x20will\x20be\x20reset.','app/main/apps/chat','SYSTEM:GET_TEAMS','salesforceConfiguration','variablesById','orange-fg','viber','lastAssignedTo','angucomplete-alt:clearInput','','SYSTEM:USERPROFILE.ADDSECTIONS','UpdatesController\x20as\x20vm','CreateOrEditTemplateDialogController','noanswer','load','CustomizationsController','sms/applications/:id/clone','SYSTEM:GET_TREEREPORTS','dateStart','recentEmojis','api.intFreshsalesConfiguration.update','analytics/metrics/describe','indigo-A100-fg','sms/queues/:id/members','hh:mm:ss','+14:00','motion.cookieAlertHide:','addNewAgent','Rule','plainBody','SMSACCOUNT:SEND','ChatRealtimeController\x20as\x20vm','getContact','Atlantic/Canary','getScheduler','blue-A700','SYSTEM:GETfaxAccounts','api.analyticMetric.update','Widget\x20has\x20been\x20deleted!','Chat\x20Messages','Context\x20properly\x20created','api.network.delete','getODBC','valueReplacer','createdAt,updatedAt,id,filename,projectName,uniqueid,callerid,extension,audio,savePath,format','jstree','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20smsCannedAnswer?','IvrCampaignHopperFinalsController','ringall','ringingVolume','onSaveWhatsappInteraction','sugarcrmAccounts','Dynamics365','csv','trustAsResourceUrl','src/js/modules/main/apps/voice/views/voiceQueues/edit/teamadd/teamadd.html/teamadd.html','FaxAccountActionsController','Asia/Dushanbe','src/js/modules/main/apps/staff/views/userProfiles/edit/view.html/view.html','delete\x20descriptions','Tahoma,Geneva,sans-serif','\x27beepall\x27','blacklist','whatsappPause','yearsS','loadedSection','^msNav','api.intZendeskAccount.update','$get','Delete\x20Report','api.cmList.update','Url','DASHBOARDS.SELECT_READ_UNREAD','undefined','modelCtrl','\x27fr\x27','onMessageSave','createOrEditMusicOnHold','enumerateDevices','$watch','onRemoveVoiceQueue','Would\x20you\x20like\x20to\x20change\x20the\x20status\x20of\x20the\x20process\x20#','\x27dropRate\x27','Plugin\x20not\x20deleted!','api.intZohoAccount.delete','TOOLS.SOUNDS','vm.selectedTags','app.voice.realtime.queue_calls','Portuguese\x20(Portugal)','SYSTEM:DELETEintServicenowAccount','MOTIONDIALER.MOTIONDIALER','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20musiconholds?','EditSmsAccountAppautoreplyDialogController','freshsales','app/main/apps/marketplace','createdAt,updatedAt,id,callerid,duration,audio,stamp,msg_id','api.intZohoConfiguration.delete','SMS.SMSACCOUNTS','queueAdd','/dashboards','chatCannedAnswers','promise','motion2.home.whatsapp:','STAFF.STAFF','usspanishmale','delete\x20whatsappAccount','api.voiceMail.delete','SETTINGS.NETWORKS','SalesforceAccount\x20properly\x20saved!','createdAt,updatedAt,id,name,description,username,accessKey,remoteUri,serverUrl','msWidgetFront','delete\x20OpenchannelAccounts','api.fax.account','clickOutsideToClose','voiceQueuesSelected','Asia/Vladivostok','createdAt,updatedAt,id,name,key,token,remote,ListId,type,phone,accountSid,authId,authToken,smsMethod,username,password,baseUrl,apiKey,senderString,deliveryReport,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,receiveUrl,deliveryReportUrl,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','$templateFactory','SYSTEM:UPDATEanalyticTreeReport','hopperIds','Interaction','refreshAbandonedCalls','Asia/Nicosia','deselectChatWebsites','fields','SYSTEM:DELETEdisposition','treeCustomData','European\x20German\x20Male','Bearer\x20','api.chatQueue.update','DASHBOARDS.LAST_YEAR','Europe/Vilnius','America/Godthab','deleteTemplate','motion-client','api.openchannelAccount.update','dialogFlowLanguage','src/js/modules/main/apps/sms/views/smsAccounts/edit/view.html/view.html','trunk@get','getAnyConditions','ms-navigation-horizontal-node','Quarters','data4','startsWith','jun','offHook','Agent\x20updated!','src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/agent/dialog.html/dialog.html','VOICE.VOICE','_blank','AgentsWhatsappRealtimeController\x20as\x20vm','WHATSAPP.NEW_WHATSAPPQUEUE','FaxAccountsRealtimeController\x20as\x20vm','newList','deleteChatWebsiteApp','America/Maceio','/trunks','CreateOrEditReportDialogController','GET_CONTEXT','app/login','CreateOrEditUserProfileDialogController','ZendeskAccountsController','CDR(type)=inbound','openchannelMessage','showWhatsappInteraction','Interval\x20properly\x20saved!','queryMessage','ResetPasswordController\x20as\x20vm','onSaveOpenchannelQueueChannel','\x27thumb\x27','FreshdeskAccountConfigurationsController','findLast','onUpdateWhatsappQueue','ATTACHMENTS:GET','/integrations','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/playback/dialog.html/dialog.html','apps.integrations.freshsalesAccounts','newZohoAccount','EditMailAccountAppnoopDialogController','paginate','selectAll','outboundBusyCallsDay','Atlantic/Madeira','MailCannedAnswer\x20properly\x20created','Dynamics365AccountsController\x20as\x20vm','wechat','CustomDashboard','ZendeskAccount\x20properly\x20deleted!','company','api.intDeskAccount.save','api.intZendeskConfiguration.delete','motionConfigProvider','SYSTEM:DELETEtrunk','deleteSelectedIvrCampaignHopperFinals','arrayrecordingFormat','labels','blur','openContact','api.intSalesforceConfiguration.update','body','jscripty','createdAt,updatedAt,id,name,prefix,options,auth,password,record,recordingFormat,description','download','campaigns/:id/hoppers','directive','Pashto','Carla\x20(Italian,\x20Female)','addNewSmtp','EditOpenchannelAccountAppintervalDialogController','src/js/modules/main/apps/voice/views/outboundroutes/outboundroutes.html/outboundroutes.html','user:save','EditFaxAccountAppsystemDialogController','write','SugarcrmConfiguration\x20properly\x20created','deleteSelectedFaxQueues','redirectToNumber','network','descriptions','selectedDeskAccounts','IS_GREATER_THAN','delete\x20hopper','src/js/modules/main/apps/tools/views/triggers/create/dialog.html/dialog.html','createOrEditCloudProvider','VoiceExtensionId','deleteSelectedWhatsappAccounts','.zip','CreateOrEditDeskConfigurationDialogController','UserVoiceQueue','smsCurrentCapacity','getContactsCsv','tab','eu-west-1','api.intFreshsalesConfiguration.delete','src/js/modules/main/apps/settings/views/license/request/dialog.html/dialog.html','NO\x20QUERY','newMail','flow','addNewList','users/:id','ATTENTION','CannedAnswer\x20properly\x20saved!','selectedTrunks','sep','analyticExtractedReport','What\x20would\x20you\x20name\x20your\x20company?','blue','delete\x20openchannelAccount','customization','SalesforceAccount\x20updated!','filename','app.staff','Abandon','api.intDeskConfiguration.delete','userProfile@getResources','app.voice.realtime.telephones','msWidgetEngine','dispositions','mail/queues/:id/clone','unknown-browser','selectedZohoAccounts','AbandonedCallsVoiceRealtimeController','CONTACTMANAGER.EDIT_CUSTOMFIELD','\x27us-east-1\x27','Zoho','Marketplace','dashboarditemForm','api.item.save','OpenchannelCannedAnswer\x20deleted!','referAttended','wed','CONTACTMANAGER.CONTACTS','SYSTEM:GETPAUSES','populateResults','deleteCloudProvider','Customization\x20properly\x20created','getVoiceQueuesPreview','Europe/Lisbon','CreateOrEditZohoAccountItemDialogController','msMasonry:relayout','src/js/modules/main/apps/whatsapp/views/realtime/agents/view.html/view.html','dashboards/items/:id/clone','api.cmCompany.update','chatPause','selected','getInternalRoutes','deselectCannedAnswers','ms-navigation-horizontal-mobile-menu-active','\x27B\x27','Telephones','smsQueue','||MailAccountId:=$eq[','SMS\x20Report\x20Queue','VoicePrefixesController\x20as\x20vm','deselectSmsQueues','preproduction','AboutController\x20as\x20vm','saveCustomField','msRandomClass','SYSTEM:GET_OPENCHANNELACCOUNTS','motion2.home.mail:','jan','DASHBOARDS.THU','\x20session,\x20data','logout','DeskAccount\x20properly\x20tested','VOICE.VOICEMAILS','CHAT.SELECTED_AGENTS','OpenchannelAccount','Numbers\x20to\x209','draggable','chip-disabled','createOrEditOpenchannelQueue','File\x20too\x20big','ServicenowAccount\x20properly\x20tested','search','Sound\x20properly\x20saved!','openchannelQueuesTotal','home.contacts','delete\x20interaction','currentTab','webbar:originate','VOICE.INTERNAL','host','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20sounds?','agi','transformContact','gotoFreshdeskAccounts','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20fields?','passwordPattern','FreshsalesConfiguration\x20properly\x20saved!','Priority','STAFF.USERS','saveCannedAnswer','src/js/modules/main/apps/openchannel/views/openchannelQueues/create/dialog.html/dialog.html','src/js/modules/main/apps/contactmanager/views/lists/lists.html/lists.html','src/js/modules/main/apps/voice/views/voiceQueues/create/dialog.html/dialog.html','request','America/Iqaluit','addNewTag','Maja','msNav::forceCollapse','src/js/modules/main/apps/tools/views/templates/create/dialog.html/dialog.html','groupsToArray','integrations/desk/accounts/:id','\x2716\x27','OutboundRoute','QueuesVoiceRealtimeController\x20as\x20vm','voice/calls/reports/:id/clone','api.dashboardItem.update','api.intVtigerAccount.update','ms-target','advancedSearch','mail/interactions/:id/tags','integrations/vtiger/fields/:id','stop','\x20attached\x20process\x20will\x20be\x20restarted.','Australia/Currie','saveSugarcrmAccount','showSmsInteraction','Antarctica/Palmer','unavailable','chat/offline_messages/:id','deleteSelectedPlugins','isActiveTab','CopyReportDialogController','messagesAlignment','app.voice.realtime.trunks','getResponseSheetRow','angular.filter','UserChatWebsite','vm.queryHistory.filter','UserOpenchannelDashboardGeneralController\x20as\x20vm','onUserUpdate','apps.tools.dispositions','addNewVtigerConfiguration','timer-clear','call\x20with\x20session\x20Id\x20','onTabScroll','api.intSalesforceAccount.delete','getFreshdeskConfiguration','IntervalController','Dynamics365AccountController','America/Scoresbysund','IS\x20EMPTY','getMultiBarChart','es-CL','VoiceQueueId','+01:00','$translatePartialLoaderProvider','users/:id/queues_rt','editOpenchannelAccountApp','ReportController\x20as\x20vm','Fax\x20','app.voice.realtime.queue_params','createOrEditTag','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20reports?','ChatQueue','ForgotPasswordController','delete\x20Trunks','dec','delete\x20Contacts','cancel','rpcTrunks','ms-info-bar-active','SYSTEM:DELETEopenchannelAccount','dispositionsValues','motionbar','selectedChatWebsites','Swahili\x20(Tanzania)','chatStatusTime','api.intSugarcrmConfiguration.delete','Pacific/Pago_Pago','very','motion2.home.sms:','app.tools.templates','license/:id/clone','URL','chatQueue:update','isCustomField','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20queueCampaigns?','onChangeAutoAssociation','view','rpcQueues','openchannelPause','endOfConversation','whatsapp/accounts/:id/canned_answers','0\x200\x20*\x20*\x20*','VoicemailsController\x20as\x20vm','src/js/modules/main/apps/chat/views/chatWebsites/edit/chatCannedAnswers/dialog.html/dialog.html','deleteSelectedOpenchannelAccounts','ChatWebsites','closedAt','delete\x20MusicOnHolds','Georgian','language','paused','CreateOrEditSalesforceConfigurationDialogController','America/Mexico_City','CustomDashboardController','apps.voice.outboundroutes','selectedSection','src/js/modules/main/apps/mail/views/mailAccounts/edit/apps/gotop/dialog.html/dialog.html','Right\x20Join','America/Port-au-Prince','fax/messages/:id/reject','The\x20chatProactiveAction\x20will\x20be\x20deleted.','icon-heart','exportSelectedTags','translate3d(','COUNT\x20(','CDR(destination)=','ringGroup','Bulgarian\x20(Bulgaria)','newCompany','QueueCampaignblacklistaddController','api.intFreshsalesAccount.delete','integrations/freshsales/configurations/:id/descriptions','MOTIONDIALER.EDIT_QUEUECAMPAIGN','fri','MotionDialerQueueId','/networks','chat/applications/:id','WhatsappQueue\x20properly\x20deleted!','STAFF.USERPROFILES','Intelepeer','api.mail.account','CustomReports','NOT\x20LIKE','SYSTEM:DELETEvoiceRecording','Begin\x20forwarded\x20message:

From:\x20{{\x20from\x20}}
Subject:\x20{{\x20subject\x20}}
Date:\x20{{\x20date\x20}},\x20at\x20{{\x20time\x20}}
To:\x20{{\x20to\x20}}','createdAt,updatedAt,id,name,CustomReportId,DefaultReportId,output,active,startAt,endAt,cron,subtractNumber,subtractUnit,sendMail,MailAccountId,email,cc,bcc,sendIfEmpty,description','size','localHold','isExtra','OpenchannelAccountsController\x20as\x20vm','smsMessage','Networks','blue-grey-A200','contextmenu','fax/reports/queue/describe','Voicemails','cloneTrunk','QueueCampaigns','addNewInterval','treeConfig','Queue:\x20','listadddialog','delete\x20Tags','blue-300-fg\x20icon-phone-paused','The\x20theme\x20\x22','cm/contacts/:id/jscripty_sessions','deselectVoiceQueues','interval_id','src/js/modules/main/apps/whatsapp/views/realtime/realtime.html/realtime.html','openchannel/queues/:id/members','FreshdeskAccount\x20updated!','$eval','exten','api.voiceQueue.save','triggerAllConditions','selectAllMusicOnHolds','OPENCHANNEL.OPENCHANNELACCOUNTS','SYSTEM:GETcontexts','\x20has\x20been\x20installed!','CreateOrEditVariableDialogController','addNewVoiceQueue','\x27website_alias\x27','openchannel/accounts/:id/dispositions','terminate','Ring','createOrEditZendeskAccount','European\x20Spanish\x20Male','Slovak\x20(Slovakia)','voiceMail','customizations','ChanSpies','User\x20not\x20deleted!','saveVoiceQueue','smsStatusTime','delete\x20hopperBlack','ru-RU','chatInternalMessage','smsCannedAnswer','deleteSelectedVoiceRecordings','removeShortcut','deleteSelectedWhatsappQueues','app.chat.chatWebsites','scheduled','rpcSmsQueues','api.intFreshdeskAccount.delete','CustomField\x20properly\x20created','\x27ringall\x27','searchOptions','columns','deleteOdbc','isJabraInitialized','squareRecording@get','participants','browserName','READ_PERMISSION','copy','icon-message-text','motion-blue','saveTeams','jscripty/sessions/reports/:id/questions','filterHiddenStep','api.jscriptyProject.clone','delete\x20chatCannedAnswer','Ukrainian\x20(Ukraine)','Content\x20with\x20Toolbar','getServicenowAccounts','src/js/modules/main/apps/openchannel/views/openchannelQueues/edit/teamadd/teamadd.html/teamadd.html','America/Fort_Nelson','trunk','agentAdd','originated','DASHBOARDS.ENABLED','FreshsalesAccountsController','TOOLS.NOTIFICATIONS.TRIGGER_DELETE_TITLE','scrollHeight','FaxAccountsController\x20as\x20vm','inline','Fax\x20Account','twilio','CONTACTMANAGER.LISTS','gotogoto','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20contacts?','dynamics365Accounts','dashboardSections','fax/reports/transfer/:id/clone','VOICE.VOICEPREFIXES','ringgroup','squareReport','INTEGRATIONS.EDIT_VTIGERCONFIGURATION','numbersto99','Greek','loginOauth','selectAllVoicePrefixes','en-IN','fileAdded','apiselect','analyticTreeReport','app.openchannel.realtime','WhatsappCannedAnswer\x20properly\x20saved!','SYSTEM:DELETEFIELD','sms/queues/:id/users','finish','globalLists','src/js/modules/main/apps/integrations/views/vtigerAccounts/vtigerAccounts.html/vtigerAccounts.html','src/js/modules/main/apps/integrations/views/freshdeskAccounts/freshdeskAccounts.html/freshdeskAccounts.html','chat/websites/:id/applications','CreateOrEditTelephoneDialogController','Schedule\x20properly\x20saved!','Japanese','apps.dashboards.custom_','contrast1','api.voiceQueue.getBlackLists','allReportsSelected','gsm','selectedSquareRecordings','integrations/desk/configurations/:id','EditChatWebsiteAppgotopDialogController','onUserCalled','Start\x20new\x20recording','No\x20images','hotdesk','ivrCampaignHopperBlacks','mail/messages/:id/clone','pt\x22>

','VtigerAccount\x20properly\x20deleted!','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20globalCustomFields?','America/Jamaica','\x279600\x27','America/Argentina/Rio_Gallegos','CompanyController','deleteSelectedCannedAnswers','FreshsalesConfiguration\x20deleted!','app/errors/500','useLoader','','api.campaign.update','STAFF.NOTIFICATIONS.PERMISSIONS_DISABLED_ALL_SUCCESS_TITLE','windowWidth','EDIT_PERMISSION','addNewTelephone','api.intFreshdeskConfiguration.update','\x27en\x27','MsSearchBarController','contact_import_error','openchannel/accounts/:id','vm.globalCustomField.type','icon-video','showQuestionsProjectSession','src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/apps/noop/dialog.html/dialog.html','app.chat.chatWebsites.edit','mandatoryDispositionPause','src/js/modules/main/apps/dashboards/views/general/agent/contact/dispose/dialog.html/dialog.html','id,name,mapAgentsId,waiting','Report\x20field\x20properly\x20created','hiddenCC','onFirstLevelSelection','spyopenchannelInteraction','voice/mails/messages/:id/clone','screenRecording\x20properly\x20created','freshdeskAccount','delete\x20pause','America/Whitehorse','\x27rounded\x27','mindigit','getFreshdeskAccounts','selectedOutboundRoutes','cm/hopper_final/voice/campaign/moveContacts/:id','Asia/Thimphu','STAFF.EDIT_USERPROFILE','STAFF.PERMISSIONS_WARNING_ENABLE_ALL','apiKey','src/js/modules/main/apps/integrations/views/zohoAccounts/zohoAccounts.html/zohoAccounts.html','api.squareOdbc.delete','api.mailAccount.update','TriggerController','Europe/London','krkoreanfemale','userAgent','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20','EditMailAccountAppcloseDialogController','dashboards/describe','newscreenRecording','dispositions/:id/clone','editInternalRouteApp','fas\x20fa-robot','createdAt,updatedAt,id,format,value,type,uniqueid,calleridnum,exten,connectedlinenum,queue,membername,rating,audio,userDisposition,userSecondDisposition,userThirdDisposition,transcribeStatus,fileText,failureReason,sentiment,sPositive,sNegative,sNeutral,sMixed','Welsh','dd\x20MMM\x20yyyy','queueaddchannel','onFaxMessageSave','Restore\x20Contacts','white-bg','SYSTEM:DELETEplugin','getHeader','\x27hi\x27','deskAccounts','\x27nonat\x27','JscriptyProjectsController\x20as\x20vm','deleteNetwork','+08:00','delete\x20Intervals','\x27report_fax_transfer\x27','selectedDeskConfiguration','fax/accounts/:id/users','rpc','loadMore','DASHBOARDS.JANUARY','getUserMedia','CreateOrEditHopperCampaignIdDialogController','$stateChangeStart','ListagentaddController','msNavigationItem','hasSectionPermissions','FreshdeskAccount\x20properly\x20deleted!','EditWhatsappAccountApp','America/Winnipeg','$interval','getItem','unreadTotalMessages','VoiceQueueController','log','osName','src/js/modules/main/apps/whatsapp/views/whatsappQueues/edit/agentadd/agentadd.html/agentadd.html','selectedLists','Africa/Windhoek','dialPredictiveIntervalMinThreshold','id,name,IntervalId','category','Agent\x20Only','api.intZendeskAccount.delete','Russell\x20(English,\x20Austrialian,\x20Male)','Arabic\x20(Egypt)','deselectFreshdeskAccounts','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20schedules?','/customDashboards','app/core/directives/ms-widget-engine/ms-widget-engine-','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/dial/dialog.html/dialog.html','Asia/Tehran','src/js/modules/main/apps/integrations/views/sugarcrmAccounts/sugarcrmAccounts.html/sugarcrmAccounts.html','rpc/voice/channels/:uniqueid/mixmonitor','onRemoveFaxQueue','outboundroutes','cm/hopper_history/describe','European\x20Portuguese\x20Male','contactFields','destroy','$emit','attachments','selectAllTrunks','FAX.NEW_FAXQUEUE','deleteSelectedZohoAccounts','UserProfile','delete\x20company','awsPollyRegion','LOCAL_LOGIN','selectedSalesforceAccounts','Internal\x20Call','screenRecordings','#275498','src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/autoreply/dialog.html/dialog.html','seconds','*,*,*,*','icon-whatsapp','cloneCustomDashboard','OmniWeb','src/js/modules/main/apps/voice/views/chanSpies/chanSpies.html/chanSpies.html','SYSTEM:DELETE_HOPPER','arraysetqueuevar','getMinutes','Odbc\x20properly\x20deleted!','dropRate','api.intSugarcrmAccount.delete','MailQueue\x20properly\x20created','COUNT\x20(DISTINCT\x20','The\x20contact\x20will\x20be\x20deleted.','ParentId','InboundRoutes','jscriptySessionReport@getQuestions','Firefox','Interval\x20properly\x20deleted!','createdAt,updatedAt,id,name,strategy,timeout,description','FreshsalesAccount\x20updated!','auenglishfemale','','newVoicemail','deselectVoicemails','app.sms.smsQueues.edit','max-width:\x20500px;','copydialog','<%3B','SYSTEM:LISTS_ASSOCIATION','#5c616f','MailAccount\x20updated!','Default','cm/lists/:id/contacts/csv','VoiceRecordings','DASHBOARDS.SELECT_STATUS','Mizuki\x20(Japanese,\x20Female)','smsAccountInteractions','STAFF.TELEPHONES','exportSelectedMailAccountMailCannedAnswers','CDR(type)=outbound','deletePause','YYYY-MM-DDTHH:mm:ssZ','restartplugin','\x27US\x27','CustomReportId','integrations/freshsales/configurations/:id/clone','globalUserLists','admin,user','Input','EditChatWebsiteAppagentDialogController','right_join','SYSTEM:USERPROFILE.REMOVESECTIONS','smsPause','rpc/fax/queues/:id/notify','Australia/Hobart','SalesforceAccount\x20properly\x20tested','integrations/zendesk/accounts/:id','ShowOfflineMessageOfflineMessageDialogController','isSearchBarVisible','^msNavigationHorizontalNode','onSaveMailQueueChannel','sr-RS','app.mail.mailAccounts','delete\x20applications','src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/apps/queue/dialog.html/dialog.html','SYSTEM:DELETEintSugarcrmAccount','cmList@getCustomFields','pluginId','apps.home.openchannel','toggle','Times\x20New\x20Roman,Times,serif','AbandonedCallsVoiceRealtimeController\x20as\x20vm','whatsappAccountInteractions','removeAllListeners','vm.selectedCompany','QueueCampaignHopperFinalsController','whatsapp/messages/:id','plugins/webhook','/api/auth/','deselectZendeskAccounts','Delete\x20FreshdeskConfiguration','delete\x20dynamics365Account','sr-ME','src/js/modules/main/apps/jscripty/views/projects/projects.html/projects.html','hangup','msNavIsFolded','src/js/modules/main/apps/mail/views/mailAccounts/edit/apps/autoreply/dialog.html/dialog.html','Estonian','square/odbc/:id/test','integrations/salesforce/fields/:id/clone','CreateOrEditChatGroupDialogController','onSaveMailQueue','offlineMessage','List\x20','src/js/modules/login/login.html/login.html','zohoConfiguration','am-ET','Read','triggerallConditions','app.callysquare.squareRecordings','src/js/modules/main/apps/fax/views/realtime/agents/view.html/view.html','addNewOpenchannelQueue','Tag\x20name','exportSelectedVoicemailMessages','selectedTriggers','editHopper','campaigntype','Agents','EditFaxAccountAppagentDialogController','/tools','autoStart','api.openchannelMessage.accept','delete\x20context','Tag\x20properly\x20deleted!','TOOLS.NEW_TEMPLATE','installing','openDialog','integrations/desk/configurations/:id/fields','userProfile/resources/:id','JscriptyProjectsController','text','jpjapanesemale','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20interval?','WhatsappAccountController\x20as\x20vm','/dispositions','selectedNetworks','VIDEO.NEW_SCREENRECORDING','\x27infobip\x27','QUICKPANEL.WARNING','CreateOrEditZohoAccountDialogController','audioinput','Delete\x20Agent','queueCampaign','app/main/apps/integrations','CreateOrEditMailQueueDialogController','onHold\x20->\x20session,\x20data','exportSelectedZendeskAccounts','app.staff.telephones','sugarcrmAccount','This\x20Week','setFoldable','intFreshsalesConfiguration','api.condition.delete','delete\x20telephone','addNewscreenRecording','/whatsapp','SYSTEM:DELETEopenchannelQueue','voice/queues/reports/describe','now','users/:id/mail_interactions','Lucida\x20Sans\x20Unicode,Lucida\x20Grande,sans-serif','notifications/:id','auth/google','chat/interactions/:id/my_messages','404','api.voiceQueue.update','apps.voice.voicemails','storagePath','VoiceQueue\x20updated!','getAgentGlobalStatus','src/js/modules/main/apps/video/views/screenRecordings/create/dialog.html/dialog.html','UserFaxAccount','toJson','The\x20inboundroute\x20will\x20be\x20deleted.','voiceContext@get','notification:remove','HANGUPCAUSE_1','api.intZendeskConfiguration.update','AgentAlias','left_join','chat/groups/:id','European\x20Polish\x20Female','outboundanswerRate','motion2.home.contacts:','addNewContact','QuickPanelController\x20as\x20vm','SYSTEM:DELETEvariable','Hotmail','find','jscriptyAnswerReport','The\x20system\x20request\x20time\x20for\x20the\x20update\x20should\x20be\x20below\x201\x20minute.

Do\x20you\x20agree\x20the\x20terms\x20of\x20this\x20End\x20User\x20License\x20Agreement?','getChatWebsiteOfflineMessages','whatsapp/accounts/:id/users','minutesS','MOTIONDIALER.EDIT_IVRCAMPAIGN','newTelephone','MusicOnHold','openchannel/accounts/:id/interactions','onSaveCampaign','jscriptyProject@get','statusList','updateLocalStorage','/openchannelQueues','layoutModes','sms/interactions/describe','icon-console','SYSTEM:GETintSalesforceAccount','CustomDashboard\x20properly\x20created','UserMailDashboardGeneralController','deleteExtractedReport','delete\x20SmsAccounts','Spanish\x20(Ecuador)','mail/out_servers/:id/clone','SYSTEM:DELETEdashboard','closeReason','Integrations','src/js/modules/main/apps/integrations/views/freshdeskAccounts/edit/configurations/dialog.html/dialog.html','newReportField','$setValidity','Tamil','api.intSalesforceConfiguration.save','square/reports/:id/clone','saveContext','DASHBOARDS.SEPTEMBER','SquareRecording\x20properly\x20created','Antarctica/Casey','integrations','deselectTeams','CreateOrEditMailSubstatusDialogController','pm2@get','accounts','campaign@get','America/Matamoros','back','WhatsappAccountId','rejected','TOOLBAR.CHANGE_LANGUAGE_TITLE','exportSelectedChatWebsites','showMenu','deleteReportField','extraHeaders','HANGUPCAUSE_16','0.7','src/js/modules/main/apps/contactmanager/views/companies/create/dialog.html/dialog.html','triggerAnyConditions','The\x20user\x20will\x20be\x20deleted.','src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/teamadd/teamadd.html/teamadd.html','getAuthenticationType','PluginController','/callysquare/projects/','\x22\x20is\x20not\x20defined\x20in\x20the\x20api\x20service!','getAiTools','allowedItems','msApi::requestSuccess','moveConfirm','JSCRIPTY.JSCRIPTY','-04:30','channelStatus','app.sms.realtime.agents','#1e2129','DASHBOARDS.LAST_MONTH','selectAllPauses','src/js/modules/main/apps/dashboards/views/general/agent/interaction/tag/dialog.html/dialog.html','api.plugin.save','getUserDeviceMediaExt','INTEGRATIONS.NEW_FRESHSALESCONFIGURATION','intServicenowField','User\x20API\x20key\x20removed!','saveAgent','intVtigerAccount@get','CONTACTS\x20NOT\x20AVAILABLE','deleteZohoConfiguration','-=400','killProcess','api.openchannelAccount.save','callysquare','voiceChanSpy','\x27report_mail_transfer\x27','Filipino\x20(Philippines)','Successful\x20call','hoppers','autoSelectOperator','api.contact.delete','CHAT.EDIT_','src/js/modules/main/apps/voice/views/realtime/queue_calls/view.html/view.html','joinTypes','apps.voice.chanSpies','createdAt,updatedAt,id,name,active,TrunkId,TrunkBackupId,type,IntervalId,dialCheckDuplicateType,dialCutDigit,SquareProjectId,limitCalls,description,dialOriginateCallerIdName,dialOriginateCallerIdNumber,dialRandomLastDigitCallerIdNumber,dialOriginateTimeout,dialGlobalMaxRetry,dialCongestionMaxRetry,dialCongestionRetryFrequency,dialBusyMaxRetry,dialBusyRetryFrequency,dialNoAnswerMaxRetry,dialNoAnswerRetryFrequency,dialNoSuchNumberMaxRetry,dialNoSuchNumberRetryFrequency,dialDropMaxRetry,dialDropRetryFrequency,dialAbandonedMaxRetry,dialAbandonedRetryFrequency,dialMachineMaxRetry,dialMachineRetryFrequency,dialAgentRejectMaxRetry,dialAgentRejectRetryFrequency,dialOrderByScheduledAt,dialGlobalInterval,dialTimezone,dialPrefix,dialAMDActive,dialAMDInitialSilence,dialAMDGreeting,dialAMDAfterGreetingSilence,dialAMDTotalAnalysisTime,dialAMDMinWordLength,dialAMDBetweenWordsSilence,dialAMDMaximumNumberOfWords,dialAMDSilenceThreshold,dialAMDMaximumWordLength','value','saveOutboundRouteApp','Connection\x20succeded!','mail/interactions/:id','confirm','Mathieu','\x27onlyIfOpen\x27','delete\x20musiconhold','CreateOrEditTrunkDialogController','vm.customField.type','ka-GE','setPlaceholder','timer','api.trigger.delete','migrations/describe','pauses/:id','No\x20corresponding\x20process\x20found','mozNotification','$selectedColor','root','queryOptions','MusicOnHold\x20properly\x20created','app.callysquare.projects.edit','api.schedule.update','src/js/modules/main/apps/help/views/about/about.html/about.html','selectAllIntervals','newZendeskConfiguration','Interaction\x20deleted!','timelineOptions','selectAllFaxQueues','exportSelectedDynamics365Accounts','onRemoveWhatsappQueue','AgentHomeDashboardMultiChannelChatController','TOOLS.NOTIFICATIONS.ACTION_DELETE_TITLE','PERMISSIONS','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20teams?','Refer\x20Attended','desktopNotification','CannedAnswer\x20properly\x20created','email','chatProactiveAction\x20#','app.voice.outboundroutes.edit','user_has_mail_interactions:save','EditChatWebsiteAppamazonlexDialogController','analyticMetric','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20sugarcrmConfiguration?','treeReports','Icelandic\x20(Iceland)','APPS','apps.tools.sounds','mail/out_servers/:id','msNavigationHorizontalItem','getUnread','cmCustomField@get','_interactions:remove','exportSelectedSquareRecordings','/plugins','home.openchannel','TemplatesController','selectedVoiceQueues','src/js/modules/main/apps/integrations/views/deskAccounts/edit/configurations/dialog.html/dialog.html','sms/interactions/:id','Comic\x20Sans\x20MS,cursive','saveVariable','VariablesController','User\x20updated!','MARKETPLACE.EDIT_PLUGIN','cm/hopper_final/:id/clone','MotionDialerRealtimeController\x20as\x20vm','getScheduledCalls','runtranscribeSelectedVoiceRecordings','fromJson','UserProfilesController','STAFF.NEW_TEAM','onUpdateFaxInteraction','Emojis','OwnerId','removeTab','src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/whatsappCannedAnswers/dialog.html/dialog.html','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20interactions?','The\x20internalroute\x20will\x20be\x20deleted.','selectedInternalRoutes','deleteList','predictiveIntervalAvgHoldtime','Antarctica/Davis','mailAccountApp','selectAllFreshsalesAccounts','msUtils','securePassword','numbersto9','ExtractedReport\x20properly\x20deleted!','template','CHAT.NEW_CHATCANNEDANSWER','offset','mapValues','selectedInboundRouteApps','Configuration','0.3','start','Arabic\x20(United\x20Arab\x20Emirates)','apps.home.fax','Sound\x20properly\x20deleted!','plugin','ToolbarController\x20as\x20vm','dashboards','motiondialer','$parent','FEMALE','newTeam','delete\x20hopperFinals','xAnswerAfterSec','getMusicOnHoldMohSounds','getMessages','OPENCHANNEL.SELECTED_AGENTS','motionBarOptions','api.screenRecording.delete','createdAt,updatedAt,id,name,username,password,remoteUri,tenantId,clientId,clientSecret,serverUrl,description','createOrEditPause','newIndex','listOrderAsc','outboundUnknownCallsDay','findIndex','layoutStyles','tags','Call\x20%s\x20not\x20found\x20or\x20already\x20completed','getActiveItem','Chantal','$viewContentAnimationEnded','chat/interactions/:id/attachment_download','America/Curacao','-stamp','ico','\x27agentBusyFactor\x27','rpc/voice/queues/channels/:uniqueid','VoiceRecordingController','gotoLists','onMultiselectSelection','DASHBOARDS.NEW_CONTACT','DASHBOARDS.HOME','SMS.SELECTED_AGENTS','removeColor','Description\x20deleted!','ANALYTICS.NO_METRIC_FOUND','cm/lists/:id/clone','id,uniqueid,calleridnum,statedesc,starttime,disposition','whatsappQueuesTotal','/settings','European\x20Turkish\x20Male','\x27squared\x27','src/js/modules/main/apps/mail/views/realtime/accounts/view.html/view.html','levels','Substatus','api.voiceRecording.update','\x22\x20called\x20successfully','whatsappQueue:save','Waiting...','cm/contacts/describe','$translate','Raveena\x20(English,\x20Indian,\x20Female)','MMM\x20d,\x20y\x20h:mm\x20a','exportSelectedVoicemails','newOpenchannelQueue','CreateOrEditVoiceRecordingDialogController','millis','SYSTEM:DELETEsquareOdbc','onUpdateFaxQueue','Delete\x20triggers','ONLY_IF_OPEN','\x272400\x27','lastOut','newchanSpy','icon-checkbox-blank-circle-outline','int','es-AR','createdAt,updatedAt,id,starttime,endtime,membername,calleridnum,completed','app.marketplace.plugins','edited','sms/accounts/:id/users','agentOnly','clearConditions','xCALLY\x20Motion','deleteContact','popup','stun','SYSTEM:DELETECONFIGURATIONFIELD','api.interval.save','api.userProfile.clone','notifications/:id/clone','European\x20Catalan\x20Female','api.squareRecording.save','English\x20(UK)','wav','deleteWhatsappQueuesWaitingInteractions','selectAllZohoAccounts','apps.home.sms','rtlSupport','account','data2','vm.customFieldsForm.$pristine','isAdmin','app.tools.customDashboards.edit','Scheduled\x20call','square/recordings/:id','smsAccountSmsCannedAnswers','after','mail/reports/transfer/:id/clone','chat/websites/:id/dispositions','delete\x20GlobalCustomFields','GROUP_CONCAT\x20(','DASHBOARDS.RECORDINGS','deselectMailAccounts','staff','whatsapp/queues/:id/users','saveUserProfile','motNotification','click','internal','getChatWebsiteApps','id,fullname,name,internal','key','newCustomization','Asia/Aqtau','deleteSelectedTriggerAnyConditions','getChanSpies','stopMonitor','accountProperty','api.chatProactiveAction.update','Explorer','Openchannel','TriggersController\x20as\x20vm','ChatQueue\x20properly\x20saved!','gotoSalesforceAccounts','msFormWizard','fontColor','runsentimentSelectedVoiceRecordings','exportSelectedIvrCampaignHopperBlacks','handleKeyboardAction','sourceid','The\x20globalCustomField\x20will\x20be\x20deleted.','users/:id/api_key','selectAllDynamics365Accounts','onFieldSelection','app.staff.userProfiles','Delete\x20Plugin','deleteSquareRecording','\x2738\x27','serviceWorker','dialogflowV2','home.sms','integrations/zendesk/configurations/:id/fields','downloadChatInteraction','FAX.EDIT_FAXQUEUE','userProfiles/:id/clone','badges','Asia/Bishkek','voiceDialReportColumns','cancelInterval','selectAllMailAccounts','\x27report_openchannel_transfer\x27','api.intZendeskConfiguration.save','mapKey','toasty','api.faxQueue.update','api.mailSubstatus.update','Delete\x20FaxQueue','fax/reports/transfer/:id','app','app.voice.internalroutes','third','ngCookies','destaccountcode','deleteSelectedSmsAccountSmsCannedAnswers','TOOLS.EDIT_VARIABLE','motionTheming','agentNotify','createdAt,updatedAt,id,name,type,strategy,timeout,maxlen,retry,wrapuptime,weight,joinempty,leavewhenempty,musiconhold,announce,description,periodic_announce,queue_reporthold,queue_youarenext,queue_thereare,queue_callswaiting,queue_holdtime,queue_minutes,queue_minute,queue_seconds,queue_thankyou,announce_frequency,min_announce_frequency,periodic_announce_frequency,random_periodic_announce,announce_holdtime,announce_position,announce_position_limit,reportholdtime,acw,acwTimeout,autopause,ringinuse,memberdelay,timeoutrestart,monitor_format,context,setinterfacevar,setqueuevar,setqueueentryvar,servicelevel,mandatoryDisposition,mandatoryDispositionPauseId','fax/reports/transfer/describe','endValue','ms-nav-toggle-items','HANGUPCAUSE_22','src/js/modules/main/apps/analytics/views/reports/preview/dialog.html/dialog.html','AgentchangepasswordController','minDateRange','trunk_name','saveSection','arraydirectmedia','SYSTEM:GETsmsAccount','CreateOrEditWhatsappCannedAnswerDialogController','+12:00','Text','allowedStandardFields','The\x20metric\x20will\x20be\x20deleted.','selectedUserProfiles','selectedExtractedReports','CALLYSQUARE.EDIT_PROJECT','requestFailed','selectAllIvrCampaigns','arrayencryption','MxGraphUpdateInfoController','createdAt,updatedAt,id,name,key,token,remote,ListId,phone,type,accountSid,authId,authToken,whatsappMethod,username,password,senderString,deliveryReport,waitForTheAssignedAgent,description,receiveUrl,deliveryReportUrl,notificationSound,notificationShake,notificationTemplate','Emma\x20(English,\x20British,\x20Female)','src/js/modules/main/apps/integrations/views/freshdeskAccounts/edit/item/dialog.html/dialog.html','selectAllReports','CreateOrEditFaxAccountDialogController','chat/websites/:id/snippet','ng-sortable','Status','src/js/modules/main/apps/analytics/views/metrics/metrics.html/metrics.html','selectAllSalesforceAccounts','gotop','answers','hopper','controller','Sindhi','chat/messages/describe','auth/local','Verdana','voice/contexts/describe','Pacific/Pitcairn','VOICE.NEW_VOICERECORDING','Europe/Dublin','UserVoiceDashboardDialerController','User','optionalStep','api.rpc.notify','MarketplacePluginsController','amazonlex','OPENCHANNEL.ALL_AGENTS','CALLYSQUARE.ODBC','deleteOutboundRoute','DeskConfiguration\x20properly\x20saved!','/assets/images/theme-options/vertical-nav-with-full-toolbar.jpg','whatsappInteraction','dialQueueProject','ProjectController','Africa/Khartoum','^msHorizontalStepper','app/main/apps/jscripty','font,colorbutton,autogrow,autoembed,autocorrect,googlethisterm,pastebase64','src/js/modules/main/apps/voice/views/inboundroutes/inboundroutes.html/inboundroutes.html','affectedRows','isInConference','Yoruba','isStepOptional','Delete\x20List','src/js/modules/main/apps/analytics/views/reports/edit/field/dialog.html/dialog.html','app.analytics.metrics','app.integrations.freshdeskAccounts.edit','Classic+','startProgressive','selectedInternalRouteApps','app.integrations.vtigerAccounts','SquareRecordings','Pauses','deleteOpenchannelQueuesWaitingInteractions','getSugarcrmAccounts','UserOpenchannelQueue','users/:id/sms_accounts','MxGraphDialogController','onInit','getContactLabel','exportSelectedProjects','name.name','microphoneId','Delete\x20Telephone','apply','deleteSelectedInboundRoutes','Guarani','ngPassword','onReadyEditor','servicenowConfiguration','-07:00','timer-start','limitCalls','types','TOOLS.TRUNKS','Delete\x20ZohoAccount','Editor','deleteIntervalInterval','Chinese\x20(Cantonese)','Email\x20Queues','addNewSalesforceAccount','sms/accounts/:id','+03:00','\x270\x27','ComposeWhatsappInteractionDialogController','SYSTEM:GETmailAccounts','integrations/freshdesk/configurations/:id/fields','close_all','DASHBOARDS.INFO','newPlugin','app/main/apps/analytics','msDatepickerFix','Europe/Budapest','Brazilian\x20Portuguese\x20Female','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20metrics?','row','weight','delete\x20MailAccounts','VtigerAccountsController\x20as\x20vm','mail/accounts/:id/out_servers','ta-IN','monthNumber','src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/interval/dialog.html/dialog.html','SSO_LOGIN','analytics/default_reports/describe','phoneBarRemoteControlPort','The\x20network\x20will\x20be\x20deleted.','startCase','tags/:id','Upload\x20completed','SmsAccountagentaddController','globalCustomField','OpenchannelAccounts','TOOLS.PAUSES','Jacek','VOICE.EDIT_MUSICONHOLD','integrations/freshsales/configurations/:id/subjects','Mads','placed','tech','EU\x20(Ireland)','api.analyticMetric.save','agentCapacity','whatsapp/accounts/:id/notify','deleteMohSound','deleteAction','deviceId','transferLastMessage','\x27da\x27','src/js/modules/main/apps/dashboards/views/custom/custom.html/custom.html','Courier\x20New,Courier,monospace','api.cmHopper.save','ms-navigation-horizontal-item','vm.query.filter','Asia/Krasnoyarsk','Freshsales','openFolded','setCurrentStep','$[${XCALLY-MOTION-PROGRESS}=0]?Progress','UpdatesController','id,name,interval,IntervalId','POST','module','VOICE.FILE_NOT_FOUND','aws_secret_access_key','setBaseUrl','penalty','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20customDashboards?','countbusyretry','SmsQueueController\x20as\x20vm','selectedOpenchannelAccounts','px,','onIcecandidate\x20->\x20session,\x20data','selectAllAgents','monthName','\x27de\x27','speakerMute','sql','users/:id/screen_recordings','QueuesWhatsappRealtimeController\x20as\x20vm','Europe/Luxembourg','UserProfiles','src/js/modules/main/apps/integrations/views/dynamics365Accounts/edit/view.html/view.html','SYSTEM:DELETEanalyticExtractedReport','Delete\x20Interval','SYSTEM:GETwhatsappAccount','webbar:hold','account_id','SYSTEM:GETopenchannelQueue','Spanish\x20(Latin\x20America)','TriggerAllId','appendChild','SYSTEM:DELETECONFIGURATION','app.contactmanager.contacts','setThemesList','answered','$mdDialog','delay','Taiwan\x20Chinese\x20Female','onSaveSmsQueueChannel','$in','voiceContext','=msNavigationHorizontalNode','ListId','9600','outboundBlacklistCallsDay','delete\x20hopperBlacks','Norwegian','src/js/modules/main/apps/integrations/views/vtigerAccounts/edit/view.html/view.html','Time','forwardTemplate','automations/:id/actions','\x20has\x20been\x20','paramDefaults','WHATSAPP.ALL_AGENTS','isIntegrationDisabled','DASHBOARDS.VOICE','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20messages?','app.staff.users.edit','rounded','MailSubstatus\x20properly\x20deleted!','InternalRoute','addNewCustomField','recording','icon-tile-four','SYSTEM:GET_INTERVALS','subject','selectedReports','EditSmsAccountAppamazonlexDialogController','OPENCHANNEL.ALL_TEAMS','fax/accounts/:id/clone','fromUrl','On\x20{{\x20date\x20}},\x20at\x20{{\x20time\x20}},\x20{{\x20from\x20}}\x20wrote:','SYSTEM:DELETEscreenRecording','get','QueueCallsVoiceRealtimeController\x20as\x20vm','SugarcrmAccounts','/assets/images/theme-options/content-with-toolbar.jpg','Asia/Hong_Kong','Module\x20has\x20been\x20updated!','arrayleavewhenempty','The\x20trunk\x20will\x20be\x20deleted.','AgentHomeVoiceController','users/:id/openchannel/interactions','css','MailQueuesController','integrations/dynamics365/accounts/:id/clone','The\x20whatsappAccount\x20will\x20be\x20deleted.','Delete\x20Dynamics365Account','ProjectID','app.staff.users','dragging','id,field,operator,value,createdAt,updatedAt','getValues','European\x20Portuguese\x20Female','app.mail.realtime','delete\x20ZohoAccounts','AgentqueueaddController','FAX.SELECTED_AGENTS','addNewOdbc','IvrCampaignController\x20as\x20vm','Atlantic/Stanley','The\x20contact\x20is\x20in\x20the\x20hopper','Thai\x20(Thailand)','handleMouseenter','internalControl','delete\x20zendeskConfiguration','chatInteractions','user_has_openchannel_interactions:remove','addNewDeskAccount','What\x20would\x20you\x20name\x20your\x20tag?','recordingURL','TOOLS.NEW_INTERVAL','FAX:SEND','password','api.mailQueue.update','Weeks','analytics/default_reports/:id/run','addNote','src/js/modules/main/apps/motiondialer/views/queueCampaigns/create/dialog.html/dialog.html','Updates','cm/lists/describe','/video','urlForward','isValidRange','SYSTEM:DELETEvoicePrefix','app.voice.internalroutes.edit','deleteVoiceQueuesChannels','mail/interactions/:id/clone','es-UY','/mail','globalCompanies','Delete\x20General','newVoiceRecording','deleteSelectedServicenowAccounts','ServicenowAccount\x20updated!','ringingId','subjects','ChatRealtimeController','userMailQueue:save','ChatWebsite\x20properly\x20deleted!','EU\x20(London)','Email\x20','deleteDeskConfiguration','previewReport','Asia/Jerusalem','app.integrations.salesforceAccounts','ExternIP','userId','detailForm','users/:id/scheduled_calls','^msVerticalStepper','musiconhold','deleteSchedule','TOOLS.NOTIFICATIONS.DISPOSITIONS_DELETE_MESSAGE','src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/agentadd/agentadd.html/agentadd.html','SmsAccountsController','intZohoField','arrayratingType','vm.voiceQueue.leavewhenempty.length\x20===\x201\x20&&\x20vm.voiceQueue.leavewhenempty[0]\x20===\x20\x27paused\x27','apps.callysquare.odbcs','Admin','mail/accounts/:id/messages','\x27stun\x27','red-A700-bg','Error\x20updating\x20locally\x20stored\x20tabs','app.integrations.sugarcrmAccounts.edit','Unable\x20to\x20play\x20autoAnswer\x20notification','CreateOrEditDispositionDialogController','onHook','templates/:id','Fields\x20saved!','agent.name','amd','light','users/:id/lists','TOOLBAR.NOTIFICATION_TITLE','$evalAsync','src/js/modules/main/apps/callysquare/views/projects/edit/import/import.html/import.html','Asia/Khandyga','VOICE.NEW_CHANSPY','disableCustomScrollbars','Field\x20has\x20been\x20deleted!','delete\x20field','X-Answer-After','api.faxQueue.save','selectedDisposition','exportSelectedScreenRecordings','getVariables','newDashboardItem','mwForm.pageEvents.pageCurrentChanged','SugarcrmAccountConfigurationsController','newFaxQueue','ctrlMethods','deleteSelectedSmsAccountInteractions','\x20will\x20be\x20deleted.','it-IT','MailMessageId','Delete\x20Customization','rpc/telephones','trimEnd','quick-panel','web','offsetHeight','Context\x20properly\x20deleted!','src/js/modules/main/apps/mail/views/mailSubtatuses/mailSubtatuses.html/mailSubtatuses.html','FreshdeskConfiguration\x20properly\x20deleted!','Sound','app.integrations.zohoAccounts','Contact\x20properly\x20updated!','Technology/Resource','SugarcrmAccountController','widgets','country','day','abandonRate','mail/queues/:id','chatInteraction:update','openchannel/messages/describe','delete\x20freshsalesConfiguration','selectedWhatsappAccounts','SmtpController\x20as\x20vm','saveZohoConfiguration','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20mohSound?','America/Los_Angeles','voice/prefixes/:id/clone','id,name,strategy,type,penalty','app.jscripty.projects','intDynamics365Configuration','apps.help.about','UserProfilesController\x20as\x20vm','updateCondition','contrast2','stepTitleTranslate','action','exportSelectedQueueCampaigns','Unable\x20to\x20find\x20a\x20valid\x20call\x20to\x20answer','selectAllOutboundRoutes','monthTo','warnPalette','/general','=interval','vm.voiceQueue.joinempty.length\x20===\x201\x20&&\x20vm.voiceQueue.joinempty[0]\x20===\x20\x27inuse\x27','inboundroutes','Service\x20Worker\x20is\x20not\x20supported','sumBillable','input','squareMessage','trunk.name','chatMessage:save','associatedReports','Pacific/Kosrae','vm_bull.query.filter','members/reports/:id','WHATSAPP.SELECTED_TEAMS','whatsapp/reports/transfer/describe','secondsS','chat/websites/:id/proactive_actions','deleteServicenowConfiguration','FAX.REALTIME','addUsers','multipleUsers.name','Error\x20initializing\x20Jabra\x20integration','vm.queryHopper.filter','license/:id','outboundroute','Europe/Paris','MOTIONDIALER.ALL_TEAMS','America/Barbados','InboundRoute\x20properly\x20saved!','/schedules','Latvian','parse','integrations/servicenow/configurations/:id/clone','agi://127.0.0.1/square,','local','saveNetwork','gotoContacts','jscripty/sessions/reports/:id/clone','foreignTableFields','America/Argentina/San_Luis','SYSTEM:DELETEintFreshsalesAccount','internalrouteApps','histories','/analytics','EditInternalAppagiDialogController','limitObjectFromTo','Cristiano\x20(Portuguese,\x20Male)','TOOLS.NEW_SCHEDULE','$mdConstant','api.cmList.delete','id,name,enabled,includeAll,autoAssociation,crudPermissions','messageStatuses','saveTrunk','conf','newDynamics365Account','importContacts','apps.sms.realtime','md5secret','SmsAccountId','editCompany','app.contactmanager','getVoiceChannels\x20->\x20session','Inbound\x20Call','TrunksFaxRealtimeController','The\x20company\x20will\x20be\x20deleted.','Pacific/Chatham','square/messages/:id','asterisk','deleteVoiceQueue','desc','read1stAt','\x27g726\x27','ReportsController','MOTIONDIALER.NEW_QUEUECAMPAIGN','fullPath','ngModel','TOOLBAR.ENGLISH','selectAllODBC','openchannelAccountInteractions','whatsappAccountWhatsappCannedAnswers','cdr/describe','app.integrations.zendeskAccounts.edit','MusicOnHoldController','isPartialPause','availableOperators','automations/describe','ro-RO','screenRecording','buttonClicked','getConfig','QueuesSmsRealtimeController','flipWidget','App\x20deleted!','api.trunk.clone','createdAt,updatedAt,id,name,key,token,remote,ListId,phone,type,accountSid,authId,authToken,smsMethod,username,password,senderString,deliveryReport,waitForTheAssignedAgent,description,receiveUrl,deliveryReportUrl,notificationSound,notificationShake,notificationTemplate','in-right-aligned','home.mycontacts','Contact\x20properly\x20merged!','deleteSelectedSmsAccountApps','US\x20English\x20Male','saveVoiceRecording','Asia/Oral','second','updateQueue','iPad','Asia/Pontianak','selectAllChatQueues','stateClass','TOOLBAR.DUTCH','rpc/mail/queues','jabraClicked','selectedIvrCampaigns','Unable\x20to\x20retrieve\x20voice\x20channels','Pacific/Kwajalein','dialerCall','tools','$invalid','integrations/zendesk/accounts/:id/clone','setToggleItem','hangupHook\x20->\x20sessionToHangup','Random','deselectExtractedReports','selectAllInboundRoutes','fax/accounts/:id/dispositions','undo','api.pause.update','typeWrapper','exportSelectedScheduler','integrations/zendesk/accounts/:id/fields','-06:00','factory','The\x20dynamics365Configuration\x20will\x20be\x20deleted.','InternalRoutesController\x20as\x20vm','user.name','openchannelCurrentCapacity','collapsed','','substr','faxQueue:save','clearDate','src/js/modules/main/apps/contactmanager/views/lists/edit/view.html/view.html','api.whatsappAccount.save','createdAt,updatedAt,id,format,value,type,uniqueid,calleridnum,exten,connectedlinenum,queue,rating,audio,transcribestatus,UserId','Content\x20Only','newAgent','ngFlow','deselectTags','hostname','rpc@getTrunks','Set','getBaseUrl','Gsm','Asia/Yekaterinburg','api.user.createApiKey','g723','error-500','src/js/modules/main/apps/sms/views/realtime/queues/view.html/view.html','timeoutId','buffer','hidden','SmsQueue\x20updated!','userStatus','setMinutes','TemplatesController\x20as\x20vm','getWhatsappAccounts','app/main/apps/callysquare','Amy','VoiceRecordingController\x20as\x20vm','IvrCampaignsMotionDialerRealtimeController','apps.settings.networks','Africa/Algiers','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20offlineMessages?','gotoFaxQueues','lastStep','years','app.motiondialer.realtime.ivr_campaigns','split','api.userProfile.delete','America/Regina','voice_outbound_channel:remove','Settings','apps.plugins','createApiKey','element','blue-grey-A200-bg','voice/queues/:id/users','Custom','push','1st','resetViewer','SYSTEM:GETVARIABLES','createOrEditFaxQueue','icon-fish','DASHBOARDS.SELECT_CAMPAIGN','arraybuffer','saveSugarcrmConfiguration','restart\x20plugin\x20process','MIN','downloadMailInteraction','dashboardItems','api.inteactionMessage.get','chat/queues/:id/teams','openchannel/messages/:id/clone','trimStart','FromId','api.trunk.update','Asia/Novokuznetsk','getMonthName','||User:=$eq[','HopperBlack\x20deleted!','integrations/reports/:id','display','id,name,dialActive','Oriya','\x27e\x27','showOnPageHidden','cm/hopper/opencontacts','SYSTEM:DELETEsmsQueue','Plugin\x20uninstalled!','toString','COMMA','integrations/salesforce/configurations/:id/descriptions','prev','ring','Swedish','pendingCondition','webrtc::logout','MOTIONDIALER.IVRCAMPAIGNS','scheduledat','createElement','api.action.delete','Tonga','deleteSelectedCompanies','terminate\x20->\x20session','analyticTreeReport@get','updatedAt','user@getLists','The\x20salesforceConfiguration\x20will\x20be\x20deleted.','addConfiguration','WhatsappQueue\x20updated!','','Delete\x20Voicemail','createdAt,updatedAt,id,role,fullname,name,email,password,description,autointernal,internal,voicemail,transport,nat,allow,callerid,context,callgroup,pickupgroup,videosupport,encryption,phone,mobile','column','src/js/modules/main/apps/analytics/views/metrics/create/dialog.html/dialog.html','SmsAccountController\x20as\x20vm','hasShortcut','timer-stopped','sw-TZ','Interaction\x20has\x20been\x20tagged!','mobile','src/js/modules/main/apps/sms/views/smsQueues/create/dialog.html/dialog.html','cm/hopper_final/voice/queue/countAttributes/:id','MusicOnHoldController\x20as\x20vm','field','api.intVtigerConfiguration.delete','^msFormWizard','Vietnamese\x20(Vietnam)','AgentHomeChatController','Dutch\x20(Netherlands)','Plugin','selectAllChanSpies','Gujarati','api.cmCompany.save','Asia/Ashgabat','ServicenowAccounts','TrunkController\x20as\x20vm','sms/messages/:id/accept','isJabraEnabled','queueCampaigns','addCustomField','app.settings.license','addNewWhatsappQueue','reLayoutDebounce','removeBlackLists','userProfiles/:id/resources','RESCHEDULE','STAFF.NOTIFICATIONS.PERMISSIONS_DISABLED_ALL_SUCCESS_MESSAGE','maxTimeUnit','SalesforceConfiguration\x20deleted!','chat/groups/:id/members','English\x20(Tanzania)','recallme','downloadtranscribe','CreateOrEditCompanyDialogController','createOrEditZohoConfiguration','America/Danmarkshavn','header','id,name,type','\x27yes\x27','en-KE','SYSTEM:DELETEintDynamics365Account','delete\x20voicePrefix','Template\x20properly\x20saved!','getClass','rpcVoiceQueuesChannels','mon','onRemoveMember','delete\x20inboundroute','splice','api.disposition.save','square/projects/:id/clone','api.intZohoAccount.update','analytics/tree_reports/:id/clone','Pacific/Chuuk','appid','getLockedItems','saveFaxQueue','user_has_whatsapp_interactions:remove','secretaccesskey','theme','voiceQueue','$sce','deleteSelectedFields','formats','address','msNavTitle','Giorgio\x20(Italian,\x20Male)','deleteQueueCampaign','src/js/modules/main/apps/tools/views/dispositions/create/dialog.html/dialog.html','\x2718\x27','src/js/modules/core/layouts/vertical-navigation.html/vertical-navigation.html','src/js/modules/main/apps/voice/views/voicePrefixes/create/dialog.html/dialog.html','Android','Accounts','Arabic','OpenchannelQueueteamaddController','dialogflow','/assets/images/theme-options/vertical-nav-with-full-toolbar-2.jpg','Message','mailCannedAnswers','Extension','mp3','/errors/error-404','$window','src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/apps/interval/dialog.html/dialog.html','TriggersController','msNavigationAgentService','VoiceQueueController\x20as\x20vm','telegram','integrations/zoho/fields/:id','method','api.network.save','ServicenowConfiguration\x20deleted!','newChatGroup','whatsappQueueReport','saveContact','smsMessage:update','Chat','id,interval,IntervalId','Delete\x20OpenchannelAccount','Ricardo\x20(Portuguese,\x20Brazilian,\x20Male)','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/hangup/dialog.html/dialog.html','faxAccount@get','msScrollConfig','Report\x20properly\x20copied!','mar','apps.staff.agents','deleteDisposition','ROUND\x20(','Asia/Gaza','src/js/modules/main/apps/fax/views/realtime/accounts/view.html/view.html','/ivrCampaigns','CannedAnswer\x20properly\x20deleted!','\x20properly\x20redirect!','rpcOpenchannelQueuesWaitingInteractions','SYSTEM:DOWNLOADJSON','getAgentLabel','delete\x20project','CONTACTS\x20NOT\x20AVAILABLE.\x20REWINDING\x20THE\x20LIST','America/Dawson','nolimit','series','selectedList','\x27cm_hopper_final\x27','.txt','configuration','Spanish\x20(Spain)','newMailAccount','scope','Hacker','voice/recordings/:id/downloads','deleteVoiceRecording','Congestion','Variables','EditChatWebsiteAppautoreplyDialogController','file_id','integrations/dynamics365/configurations/:id/descriptions','countContactsQueueCampaignHopperFinal','+05:00','exportSelectedSalesforceAccounts','faxQueue','triggers/:id/all_conditions','DEFAULT','Restored\x20Contacts','UserDashboardGeneralController','openchannelQueue','Asia/Damascus','$http','getHistories','CreateOrEditNetworkDialogController','createCompany','AgentController\x20as\x20vm','toggleFolded','Swedish\x20Female','setOrientation','CustomDashboard\x20properly\x20cloned','getSubjects','Dynamics365Configuration\x20properly\x20saved!','src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/agent/dialog.html/dialog.html','America/Araguaina','saveGlobalCustomField','right','getCurrentUser','OpenchannelQueue\x20properly\x20created','finishCallback','done','isObject','\x27force_rport\x27','getProjects','oldPasswordMatch','License\x20Request','VtigerAccountController','IAX','te-IN','America/Boise','IS_GREATER_THAN_OR_EQUAL_TO','getLogo','voiceAgentReportColumns','admin','setActiveItem','selectedIvrCampaignHopperFinals','GlobalCustomFieldsController','arraytable','material.components.expansionPanels','Delete\x20CannedAnswer','ticketType','\x27report_whatsapp_queue\x27','${EXTEN}','Chinese,\x20Mandarin\x20(Simplified,\x20Hong\x20Kong)','icon-account-circle','fax/messages/:id/download','The\x20squareRecording\x20will\x20be\x20deleted.','exportSelectedMailQueues','ChatQueue\x20updated!','getRemoteStreams','Carmen\x20(Romanian,\x20Female)','VoiceQueueteamaddController','paginatedAgents','English\x20(New\x20Zealand)','Resource\x20\x22','arraysetqueueentryvar','assignIn','level','read','selectAllChatWebsites','deleteSelectedMetrics','://','Europe/Uzhgorod','newOutboundRoute','rpc/voice/queues/channels/:uniqueid/hangup','plugins/describe','\x20ASC)','WhatsappQueues','Twilio','ToId','SUM\x20(','treeDefaultConfig','delete\x20Plugins','inReplyTo','remotePlayer','analyticDefaultReport','route','SYSTEM:GETvoiceMails','/screenRecordings','blue-300-fg\x20icon-phone-incoming','','selectAllInternalRoutes','mailQueue:update','attachment_path','deleteProjectSession','reportRoute','TOOLS.NOTIFICATIONS.ACTIONS_DELETE_MESSAGE','newVtigerConfiguration','Celine','xmd-voicequeueid','src/js/modules/main/apps/settings/views/system/system.html/system.html','Call\x20properly\x20handled!','selectTagsChanged','trunks','delete\x20chatProactiveAction','selectedTags','Label','Telugu','CONTACTMANAGER.EDIT_CONTACT','EditInboundAppintervalDialogController','gotoOpenchannelQueues','pendingChanges','closeTab','param','WhatsappAccount\x20properly\x20saved!','onRemoveChatQueueChannel','TOOLS.NOTIFICATIONS.DISPOSITION_DELETED_SUCCESS_TITLE','resume','selectedScheduler','@includeAll','path','openchannel/accounts/:id/users','Atlantic/Bermuda','newVariable','Pause','delete\x20Sounds','predictiveIntervalAvailable','newRTCSession','src/js/modules/main/apps/openchannel/views/openchannelAccounts/create/dialog.html/dialog.html','sms/accounts/:id/dispositions','projectId','unit','background','Motion\x20License\x20Request','msApi::requestError','FreshdeskAccounts','zoho.com','users/:id/mail_accounts','openAdvancedSearch','selectedOpenchannelQueues','Ewa\x20(Polish,\x20Female)','src/js/modules/main/apps/whatsapp/views/whatsappQueues/edit/view.html/view.html','SmsQueueController','ENTER_BR','\x0a\x20\x20\x20\x20See\x20More','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20chatCannedAnswer?','General\x20properly\x20created','app.toolbar','msSidenavHelper','api.analyticMetric.delete','sseconds','getReportFields','The\x20customDashboard\x20will\x20be\x20deleted.','createOrEditChatWebsite','Mozilla','png','QueueCampaign\x20updated!','Dial\x20Report','predictiveIntervalAvgTalktime','onBefore','api.mailQueue.save','selectedZendeskConfiguration','CALLYSQUARE.CALLYSQUARE','createOrEditFreshdeskAccount','ANALYTICS.NEW_REPORT','mailQueueReport','getHoppers','exportSelectedServicenowAccounts','Delete\x20Sound','campaigns/:id/hopper_histories','DASHBOARDS.SELECT_AGENT','Prefix','saveLists','shiftKey','getOutboundRoutes','app.openchannel.openchannelQueues','app.integrations.dynamics365Accounts','app.voice.inboundroutes','note','User\x20properly\x20created','Spanish\x20(Honduras)','IvrCampaignHoppersController','delete\x20QueueCampaigns','msSplashScreen::remove','showOfflineMessageChatWebsiteOfflineMessage','ZohoAccountsController\x20as\x20vm','variables','Triggers','selectedChatWebsiteProactiveActions','field,alias','/help','api.squareRecording.delete','onplay','#9ea1a9','hasIdAnswers','delete\x20chatWebsite','addNewSugarcrmConfiguration','src/js/modules/main/apps/tools/views/sounds/sounds.html/sounds.html','Italian','CHAT.CHATQUEUES','UserVoiceDashboardDialerController\x20as\x20vm','TOOLS.CLONE_CUSTOMDASHBOARD','goalname','delete\x20description','AiTools','editXML','chatInternalMessage:update','changeDisplayCannedAnswerInputValue','integrations/freshdesk/configurations/:id/subjects','fax/accounts/:id/messages','a..','clearDispositionSelection','getSections','DASHBOARDS.UNREAD','id,type,uniqueid,tag,starttime,endtime,source,destination,userDisposition,userSecondDisposition,userThirdDisposition,note,duration,billableseconds,answertime','newProject','Companies','selectedFaxAccounts','app.tools.trunks','/lists','ProjectcloneController','getMonthNumber','path\x20must\x20be\x20a\x20string\x20(eg.\x20`dashboard.project`)','mediaDevices','width:\x20265px;','api.intVtigerConfiguration.save','EditWhatsappAccountAppnoopDialogController','src/js/modules/main/apps/integrations/views/dynamics365Accounts/create/dialog.html/dialog.html','DISPOSITION_DELETE_MESSAGE_CHILDREN','digit','Liv','deleteSelectedQueueCampaignHopperBlacks','user_has_','
\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Extra:\x20','api.template.update','onEnableScreenRecordingByAgentSelection','arrayringinuse','\x27csc\x27','The\x20mailSubstatus\x20will\x20be\x20deleted.','deleteFaxAccount','app.motiondialer.realtime.queue_params','America/Argentina/San_Juan','Position','selectContact','Peer','#c2d4ef','INTEGRATIONS.EDIT_VTIGERACCOUNT','exportSelectedChatQueues','selectAllTriggers','cmn-CN','exportSelectedDispositions','VOICE.VOICEQUEUES','api.chatQueue.delete','AgentGeneralIframeController','users/:id/teams','onComplete','\x22\x20style=\x22display:none\x22','sk-SK','src/js/modules/main/apps/voice/views/internalroutes/edit/apps/queue/dialog.html/dialog.html','actions/:id/clone','chanSpy\x20properly\x20created','$setUntouched','Fewest\x20Calls','=msNavigationNode','phoneBarEnableAutomaticScreenRecording','\x20and\x20its\x20subnode\x20will\x20be\x20deleted.','SYSTEM:DELETEschedule','min','app.openchannel.openchannelAccounts','ForgotPasswordController\x20as\x20vm','app.chat.chatQueues.edit','Userchange_avatarController','selectedItem','treeCustomConfig','total','DASHBOARDS.SELECT_TAG','src/js/modules/main/apps/analytics/views/reports/reports.html/reports.html','allResourcesEnabled','describe','delete\x20openchannelCannedAnswer','fontSize','Delete\x20InboundRoute','\x27g722\x27','msResponsiveTable','api.campaign.delete','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20hopperHistory?','id,fullname','GET','\x27more\x27','Europe/Helsinki','You\x20can\x27t\x20remove\x20yourself','$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):Set(CALLERID(all)=','saveSalesforceConfiguration','getTrustedURL','variable.name','unmanaged','TOOLS.NEW_TRUNK','AgentHomeDashboardVoiceController','voicePrefix\x20properly\x20created','ja-JP','COUNT\x20DISTINCT','integrations/:id','ScreenRecordings','deleteSelectedPauses','mail/accounts/:id/interactions','\x27skebby\x27','\x22\x20is\x20not\x20defined!','src/js/modules/main/apps/integrations/views/zendeskAccounts/zendeskAccounts.html/zendeskAccounts.html','app.header','SYSTEM:DELETEanalyticMetric','firstName,lastName,fax','\x27es-419\x27','info','dialer','variables/describe','SYSTEM:GET_CLOUDPROVIDERS','currentPath','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20hoppers?','SYSTEM:DELETEintDeskAccount','md.data.table','deleteWhatsappAccountInteraction','includes','apps.home.mail','whatsapp/interactions/:id/clone','deleteSelectedTemplates','src/js/modules/main/apps/mail/views/mailAccounts/edit/apps/gotoif/dialog.html/dialog.html','UserTeam','SMS.ALL_AGENTS','selectedSmsAccountInteractions','Request\x20sent!','chanSpies','/api/originate/','onSearchBarExpand','analyticFieldReport@get','getScrollEl','Delete\x20OpenchannelQueue','saveMailAccountApp','contactmanager','googleSsoEnabled','Arial,Helvetica,sans-serif','customDashboard','Interlingua','whatsappMessage:save','analytics/field_reports/:id/clone','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20chatWebsites?','setAs','pauses','userProfile/resources/:id/clone','mail/queues/:id/teams','$setViewValue','api.voiceChanSpy.delete','SYSTEM:DELETEmailAccount','Australia/Lord_Howe','voiceExtension:update','src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/apps/agent/dialog.html/dialog.html','deleteSelectedQueueCampaignHopperFinals','callback','SYSTEM:DESCRIBE_CM_CONTACT','connection','\x27days\x27','apps.callysquare.projects','field,alias,function,format,groupBy,orderBy,custom,MetricId','The\x20whatsappCannedAnswer\x20will\x20be\x20deleted.','VtigerAccountConfigurationsController','sv-SE','red-300-fg\x20icon-phone-hangup','false','toolbarColor','Joanna\x20(English,\x20US,\x20Female)','getVoiceCalls','SYSTEM:GET_SECTIONS_PERMISSIONS','Rejected','eu-central-1','getVoiceQueuesChannelHangup','Antarctica/Macquarie','take','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20voiceRecordings?','Joey','FaxQueues','\x27wav49\x27','Staff','api.attachment.delete','arraymaxrate','apps.callysquare.squareRecordings','src/js/modules/reset/reset.html/reset.html','api.setting.save','context','SYSTEM:DELETEintZohoAccount','globalTags','append','oct','smsInteraction','horizontalNavigation','\x2717\x27','forms','SYSTEM:GET_QUEUES','arraymode','INTEGRATIONS.NEW_','userProfileSection','statusClass','MailAccountController','\x20has\x20been\x20reset','src/js/modules/main/apps/chat/views/chatQueues/edit/view.html/view.html','stopplugin','smsCannedAnswers','faxInteraction:update','setScrollEl','smtp','MailAccountController\x20as\x20vm','nonat','America/Sitka','apps.voice.voicePrefixes','hopperBlack\x20#','Interval','\x27agi://127.0.0.1/square,{{project.name}}\x27','Ines','pieChart','getByInteraction','Validation\x20error','QuickFilterManager::setPlaceholder','mmonths','UserProfilecloneController','delete\x20report','Europe/Andorra','contactInfo','Upload\x20error','getOpenchannelAccountOpenchannelCannedAnswers','app.forgot','TOOLBAR.RUSSIAN','provider','Chinese\x20Female','America/St_Johns','user_has_mail_interactions:remove','Unable\x20to\x20init\x20media\x20devices','\x27en-IN\x27','md-background-bg\x20md-hue-3','mail/messages/:id','CreateOrEditVoiceQueueDialogController','Delete','userVoiceQueueRt:save','online','stateParams','SmsQueue\x20properly\x20deleted!','USERPROFILE:GETRESOURCES(','exportSelectedChatWebsiteInteractions','Openchannel\x20Queues','SmsQueuesController\x20as\x20vm','template_id','cloudProviders/describe','Canada\x20(Central)','app.help','fax_queue:save','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20voicemails?','Network\x20properly\x20saved!','Hindi\x20(India)','integrations/desk/fields/:id','OPENCHANNEL.EDIT_OPENCHANNELQUEUE','createdAt,updatedAt,role,userProfileId,id,fullname,name,email,phone,mobile,userpic,password,description,autointernal,internal,transport,nat,allow,context,callgroup,pickupgroup,passwordResetAt,apiKey,videosupport,disabled,blocked','substatus','-starttime','Openchannel\x20Account','The\x20zendeskAccount\x20will\x20be\x20deleted.','msPhonebar','answerRate','FaxAccountsRealtimeController','Are\x20you\x20sure\x20want\x20to\x20restart\x20the\x20plugin\x20attached\x20process?','SYSTEM:DELETE.customDashboard','queuecallerleaveAt','ChatInternalMessageId','app.staff.teams','agent','deselectCompanies','phoneBarEnableRecording','getChannelByItem','src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/agentadd/agentadd.html/agentadd.html','MailAccount','dayOfWeekFrom','Company\x20properly\x20created','EditOpenchannelAccountAppsystemDialogController','ChatCannedAnswer\x20properly\x20created','rpcVoiceQueuesChannelsTmp','id,phone,scheduledat,priority,recallme,VoiceQueueId,CampaignId,UserId','saveOpenchannelQueue','SYSTEM:GETvoiceMail','list','vTiger','newContact','Pause\x20properly\x20saved!','OpenchannelQueueController','Korean','MailSubstatuses','DisposeAbandonedCallDialogController','binding','jaws','uniqueid,calleridnum,statedesc,scheduledat,starttime,endtime','$watchGroup','Asia/Tokyo','bar-container','parser','+06:30','WhatsappAccountsController\x20as\x20vm','teams/:id/queues','Not\x20defined','NotFoundError','cancelUpdateCondition','src/js/modules/main/apps/contactmanager/views/globalCustomFields/globalCustomFields.html/globalCustomFields.html','containerPos','/api/jira','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20whatsappCannedAnswer?','rpc@getMailAccounts','apps.home.scheduled','api.mailAccount.save','EditWhatsappAccountAppsystemDialogController','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20hopperFinals?','Lotte','motion.authenticationtype','delete\x20Group','timezone','diff','SYSTEM:DELETEfaxQueue','DeskConfiguration\x20properly\x20created','src/js/modules/main/apps/tools/views/schedules/partialViews/reports/treeReports.html/treeReports.html','bottom-right','src/js/modules/main/apps/integrations/views/salesforceAccounts/salesforceAccounts.html/salesforceAccounts.html','ensureSelectedResultIsVisible','api_key','registerStep','smsCannedAnswer\x20#','parent','api.voiceChanSpy.save','EditWhatsappAccountAppamazonlexDialogController','Europe/Monaco','motion2.realtime.abandoned.bull.abandonedCalls:','settings/:id/favicon','motion.layoutStyle','fax/accounts/:id/send','voice/queues/:id/hopper_finals','analytics/field_reports/:id','openchannel/queues/:id','CDR','Chinese,\x20Cantonese\x20(Traditional,\x20Hong\x20Kong)','message\x20#','\x27sms_queues\x27','blue-300-fg\x20icon-phone-outgoing','\x27fr-FR\x27','MsFormWizardController\x20as\x20msWizard','ar-PS','saveChatQueue','nextStep','newFaxAccount','Celine\x20(French,\x20Female)','Customer\x20Ip','uniqueIdentifier','FreshsalesAccount\x20properly\x20created','outboundDropCallsDayCallersExit','test','api.openchannelQueue.delete','nb-NO','ZohoAccount\x20properly\x20saved!','Delete\x20UserProfile','selectedVoicemailMessages','HopperFinal\x20deleted!','findSessionBySessionId\x20->\x20sessionId,\x20vm_pb.sessions','src/js/modules/main/apps/marketplace/views/plugins/plugins.html/plugins.html','CreateOrEditDeskAccountDialogController','app.errors_error-500','delete\x20tag','DASHBOARDS.LICENSE_EXPIRE_REMAINING_DAYS','INTEGRATIONS.EDIT_FRESHDESKACCOUNT','app.voice.voicemails','cm/hopper_history/:id/clone','SYSTEM:DELETEintVtigerAccount','Sequence','deleteSelectedDispositions','TOOLBAR.WARNING','TrunkcloneController','deleteHopper','src/js/modules/main/apps/callysquare/views/projects/edit/dialog/dialog.html/dialog.html','output','app.plugins.plugin','\x274\x27','auth/local/user/:token','motion2.home.mycontacts:','getReports','rpc/outbound/channels','ChanSpiesController','WhatsappAccounts','\x20MMM','dynamics365Account','\x27invalid\x27','composeFaxInteraction','deleteTriggerAnyCondition','CreateOrEditExtractedReportDialogController','query','','SYSTEM:GETuser','IntervalsController','\x27route\x27','startingSelectedItems','Edit_permission','integrations/freshsales/fields/:id','selectAllVtigerAccounts','
\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Call\x20from:\x20','AgentDashboardGeneralController','saveCallback','deleteSmsAccountApp','delete\x20zendeskAccount','src/js/modules/main/apps/callysquare/views/projects/edit/saveAs/saveAs.html/saveAs.html','mr-IN','deleteSelectedIntervals','SYSTEM:GETintFreshsalesAccount','voiceStatusTime','Cannot\x20upload\x20the\x20sound','newUser','selectedWhatsappAccountInteractions','cm/contacts/:id','Field','UK\x20English\x20Male','downloadFaxInteraction','deskConfiguration','\x27en-GB\x27','fax/applications/:id','STAFF.CANCEL','Verdana,Geneva,sans-serif','selectedSugarcrmAccounts','selectAllSmsQueues','Europe/Tallinn','app.chat.chatQueues','rpc@getOutbound','add','propertiesDefault','Arabic\x20(Qatar)','List\x20properly\x20deleted!','\x27no\x27','SYSTEM:GETintZohoAccount','newMailCannedAnswer','queryHistory','getNetworks','src/js/modules/main/apps/fax/views/faxQueues/edit/view.html/view.html','penalty\x20','src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/gotop/dialog.html/dialog.html','INTEGRATIONS.NEW_DESKCONFIGURATION','twchinesefemale','Hopper\x20properly\x20created','XCALLY-MOTION-PROGRESS=0','square/odbc/:id','SystemController\x20as\x20vm','deleteSelectedVoicePrefixes','html5Mode','integrations/freshdesk/configurations/describe','IvrCampaigns','deleteSelectedUserProfiles','msApi','apps.contactmanager','arrayzone','hasMicrophone','readAsDataURL','SYSTEM:DELETEintZendeskAccount','EditSmsAccountAppintervalDialogController','America/Blanc-Sablon','msTimeline','Delete\x20FaxAccount','newInboundRoute','campaigns/:id','fax','whatsapp/interactions/:id/tags','integrations/freshsales/accounts/:id/clone','cmContact@get','createOrEditIvrCampaignHopper','deleteSelectedMusicOnHolds','item','-05:00','+00:00','integrations/sugarcrm/configurations/:id/descriptions','Chinese\x20Male','gotoChatWebsites','Limit','flash','DADHI','deleteSelectedChatWebsiteApps','onIntegrationInit','onUpdateOpenchannelQueue','exportSelectedQueueCampaignHopperFinals','Hopper\x20deleted!','ar-IQ','Low','selectAllZendeskAccounts','deleteOpenchannelAccount','pm_id','mail/substatuses/describe','clearLockedItems','The\x20voiceRecording\x20will\x20be\x20deleted.','Asia/Omsk','isBoolean','chatProactiveAction','autoreply','mailCapacity','Pacific/Majuro','DASHBOARDS.DISABLED','/smsQueues','src/js/modules/main/apps/tools/views/triggers/edit/actions/create/dialog.html/dialog.html','UserMailAccount','voiceQueue:save','campaign:save','describeTable','hopperFinal','saveCustomization','EditMailAccountApp','Dynamics365AccountsController','standardDate','square/details/reports/:id/clone','src/js/modules/main/apps/voice/views/contexts/contexts.html/contexts.html','statedesc','onSelectList','\x27once\x27','VOICE.EDIT_','getResources','$filter','delete\x20extractedReport','icon-email','messageId','off','EditorUi','webrtc::transfer','createdAt,updatedAt,id,name,active,host,secret,defaultuser,context,callerid,type,dtmfmode,nat,qualify,allow,insecure,call_limit,registry,description,directmedia,callcounter,fromdomain,fromuser,outboundproxy,usereqphone,trustrpid,sendrpid,encryption,port,transport,t38pt_udptl,videosupport,otherFields','addNewWhatsappCannedAnswer','app.mail','CreateOrEditFreshsalesAccountItemDialogController','contentOnly','saveZohoAccount','DASHBOARDS.THIS_WEEK','voice/transfers/reports/describe','src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/amazonlex/dialog.html/dialog.html','MailAccount\x20properly\x20created','selectAllCustomDashboards','alert','sms/interactions/:id/download','EditOpenchannelAccountAppgotopDialogController','motionPalettes','fax/queues/:id/members','Hong\x20Kong\x20Cantonese\x20Female','debugEnabled','model','Romanian\x20(Romania)','Europe/Kaliningrad','QueueCampaignController','app.contactmanager.lists.edit','MailSubstatusesController','getExtractedReports','steps','Smtp\x20properly\x20saved!','src/js/modules/main/apps/integrations/views/zohoAccounts/create/dialog.html/dialog.html','fax/accounts/:id/canned_answers','EditOpenchannelAccountAppqueueDialogController','getSugarcrmConfiguration','TOOLS.NEW_SOUND','CHAT.REALTIME','HANGUPCAUSE_21','voice/queues/:id/hopper_histories','SmsCannedAnswer\x20properly\x20created','saveChatGroup','faxAccount','ivrAnswerCallsDay','createdAt,updatedAt,id,name,type,username,remoteUri,password,clientId,clientSecret,securityToken,serverUrl,description','OutboundRouteController','attr','Gmail','Australia/Sydney','intDeskConfiguration','SYSTEM:DELETEsmsAccount','isLastStep','MsStepperController','bn-IN','orange-bg','setConfig','saveDynamics365Account','vm_rf.query.filter','\x27report_queue\x27','selectedTriggerAllConditions','\x27leastrecent\x27','ms-target-wrap','German\x20(Germany)','prop','groupId','su-ID','\x27KHOMP\x27','Urdu\x20(India)','Owner','newOdbc','deleteSelectedIvrCampaignHopperBlacks','xm-mail-content-','app/core/directives/ms-phonebar/sounds/outgoing-call.ogg','FAX.FAXQUEUES','beep','MsShortcutsController','delete\x20ChatWebsites','WebRTC','-08:00','\x272\x27','SYSTEM:GET_FIELDS','All\x20unfilled\x20values\x20of\x20the\x20contact\x20#','primary','voice/dials/reports/:id/clone','America/Cayenne','motion2.home.scheduled:','krkoreanmale','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20hopperBlacks?','toggleAll','ended','downloadtranscribefile2','WhatsappQueuesController','/dialer','/teams','src/js/modules/main/apps/dashboards/views/general/agent/interaction/composeFax/dialog.html/dialog.html','CreateOrEditSugarcrmAccountDialogController','update','thirdDisposition','The\x20file\x20is\x20too\x20big.\x20The\x20max\x20allowed\x20size\x20is\x20','saveFaxAccount','SYSTEM:DELETEuser','api.voiceContext.save','chat/offline_messages/describe','getSize','\x20\x20properly\x20logout','rpc@getVoiceQueuesChannels','CreateOrEditWhatsappQueueDialogController','CreateOrEditCannedAnswerDialogController','UserVoiceDashboardGeneralController','zendeskConfigurations','integrations/desk/configurations/:id/tags','metric','hideDelay','Pacific/Tahiti','settings/:id/clone','LoginController','app/quick-panel','sqlUtil','\x27DESC\x27','openchannelAccount@get','addNewchanSpy','STAFF.NOTIFICATIONS.PERMISSIONS_SAVED_SUCCESS_TITLE','Africa/Cairo','SYSTEM:DELETEvoiceContext','Error\x20retrieving\x20user\x20profile\x20permissions','delete\x20voiceQueue','${EXTEN:','authInterceptor','ServicenowAccount','DefaultReportId','SYSTEM:UPDATEBLACKLIST','apps.tools.trunks','es-PR','localnet','api.squareProject.update','allConditions','$log','statusText','-id','mail/substatuses/:id/clone','New_Tab','deselectSmsAccounts','selectedIvrCampaignHopperBlacks','ngSanitize','SugarcrmConfiguration\x20properly\x20saved!','saveSettings','apps.tools.pauses','EditChatWebsiteAppgotoifDialogController','America/Toronto','Interval\x20properly\x20created','currentXML','\x27cm_companies\x27','onInternalMessageSave','countDown','CreateOrEditMetricDialogController','incoming','denied','src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/system/dialog.html/dialog.html','textarea','src/js/modules/main/apps/mail/views/mailAccounts/edit/apps/close/dialog.html/dialog.html','app.whatsapp.realtime.queues','apps.motiondialer.queueCampaigns','dnd','ReportFieldsController','getQueueCampaignHopperFinals','id,mailbox','id,phone,scheduledat,recallme,priority,UserId,OwnerId','IS_LESS_THAN_OR_EQUAL_TO','removeSquareProjects','SYSTEM:analyticFieldReport','browserGroupId','\x27pl\x27','\x27g723\x27','api.trunk.save','Stun','FaxAccountagentaddController','pick','createOrEditSchedule','availableStates','telephone','First','followuptime','icon-label','icon-radiobox-marked','motion2.','EditSmsAccountApptagDialogController','#5688d3','keyBy','deleteSelectedSounds','fax/queues/:id/teams','voiceExtension@get','deleteChatWebsiteInteraction','Atlantic/Cape_Verde','toJSON','src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/view.html/view.html','getOpenchannelAccounts','newOpenchannelCannedAnswer','/tags','The\x20zohoAccount\x20will\x20be\x20deleted.','ListsController','arrayhost','addNewFreshdeskConfiguration','ListController\x20as\x20vm','blue-grey','intDeskField','app.callysquare.projects','getChatWebsites','mail/interactions/:id/download','EditSmsAccountAppdialogflowDialogController','Mail','system','hasDashboardPermissions','isValid','getColumns','startMonitor','editInterval','DASHBOARDS.NOTAVAILABLE','api.intFreshsalesAccount.update','prefix','toISOString','There\x20is\x20a\x20call\x20that\x20hasn\x27t\x20been\x20disposed\x20yet.','app.fax.realtime.queues','STAFF.NOTIFICATIONS.PERMISSIONS_ENABLED_ALL_SUCCESS_MESSAGE','fontSize_sizes','TOOLS.NEW_TAG','faxInteractionTags:save','addNewTrigger','users/:id/whatsapp_accounts','Italian\x20(Italy)','teal-bg','SquareProjects','Internal','MAX','screen/recordings/describe','voice/extensions/:id','savedAsDraft','motion.customTheme','out-left-aligned','AgentteamaddController','exportSelectedWhatsappAccounts','erlangCalls','chooseFromList','whatsappStatus','deleteVtigerConfiguration','adminOnly','TOOLS.NEW_CANNEDANSWER','Afrikaans','saveCloudProvider','Vertical\x20Navigation','createdAt,updatedAt,id,name,enableUncompleteSave,sendUnpauseOnSubmit,description,formData','integrations/salesforce/accounts/:id/clone','SYSTEM:GET_LISTS','/smtps','createOrEditIntervalInterval','sound@get','\x27very\x27','SSML','removeTeams','SugarcrmAccountController\x20as\x20vm','reschedule','gotoUserProfiles','+10:30','exportSelectedMailAccountInteractions','src/js/modules/quick-panel/quick-panel.html/quick-panel.html','integrations/zoho/configurations/:id/fields','data:text/json;charset=utf-8,','delete\x20CustomDashboards','Europe/Warsaw','all','secret','light-blue','arrayrole','Reset\x20List','realm','addCondition','app.sms.smsAccounts.edit','smsQueue:save','app.sms.realtime','collapsing','src/js/modules/main/apps/mail/views/mailAccounts/edit/agentadd/agentadd.html/agentadd.html','ChineseTraditional','AgentGeneralBotController','Cancel','register','/api/chat/websites/:id/avatar','Asia/Ho_Chi_Minh','api.cannedAnswer.delete','blue-grey-A200-fg','ChatWebsite\x20properly\x20created','/fax','Kinyarwanda','queue.name','openchannelInteraction@get','api.chatWebsite.update','draft','European\x20Dutch\x20Female','startPredictive','hoursS','License\x20update\x20failed!','QUEUE_NAME','report_agent','UNIX_TIMESTAMP\x20(','api.squareOdbc.save','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20mohSounds?','gosub','Playback','UserMailDashboardGeneralController\x20as\x20vm','monitors','voice/prefixes/:id/users','The\x20list\x20is\x20empty','sendReport','api.intDynamics365Account.delete','ms-scroll','InternalRouteActionsController','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20chatQueues?','api.downloadMessage.get','getFinals','Amharic\x20(Ethiopia)','InboundRoute\x20properly\x20created','motion2.realtime.abandoned.voice.abandonedCalls:','Supported\x20extension:\x20','$mdTheming','\x27zh-CN\x27','msNavigationHorizontalNode','WHATSAPP.WHATSAPPACCOUNTS','dashboardItem','onSaveFaxQueueChannel','integrations/freshdesk/configurations/:id/tags','deleteSelectedOpenchannelQueues','zoho','template@get','\x27switch\x27','delete\x20cloudProvider','whatsapp/messages/:id/status','/voiceQueues','icon-text-to-speech','headerWhiteLabel','app.sms.smsQueues','endRangeValue','TelephonesController','EditWhatsappAccountAppgotoifDialogController','getHours','sms/interactions/:id/tags','Jscripty\x20Answers','STARTS_WITH','saveFreshsalesAccount','copyReport','Campaign','TOOLBAR.JAPANESE','preload','/*\x20Content\x20hack\x20because\x20they\x20wont\x20fix\x20*/\x0a/*\x20https://github.com/angular/material/pull/8067\x20*/\x0a[md-theme=\x22@themeName\x22]\x20md-content.md-hue-1,\x0amd-content.md-@themeName-theme.md-hue-1\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue1Contrast1;\x0a\x20\x20\x20\x20background-color:\x20@backgroundHue1Color;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20md-content.md-hue-2,\x0amd-content.md-@themeName-theme.md-hue-2\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue2Contrast1;\x0a\x20\x20\x20\x20background-color:\x20@backgroundHue2Color;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20md-content.md-hue-3,\x0a\x20md-content.md-@themeName-theme.md-hue-3\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue3Contrast1;\x0a\x20\x20\x20\x20background-color:\x20@backgroundHue3Color;\x0a}\x0a\x0a/*\x20Text\x20Colors\x20*/\x0a[md-theme=\x22@themeName\x22]\x20a\x20{\x0a\x20\x20\x20\x20color:\x20@accentDefaultColor;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundDefaultContrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundDefaultContrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundDefaultContrast4;\x0a}\x0a\x0a/*\x20Primary\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg\x20{\x0a\x20\x20\x20\x20background-color:\x20@primaryDefaultColor;\x0a\x20\x20\x20\x20color:\x20@primaryDefaultContrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@primaryDefaultContrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@primaryDefaultContrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@primaryDefaultContrast4;\x0a}\x0a\x0a/*\x20Primary,\x20Hue-1\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-1\x20{\x0a\x20\x20\x20\x20background-color:\x20@primaryHue1Color;\x0a\x20\x20\x20\x20color:\x20@primaryHue1Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-1\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-1\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue1Contrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-1\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-1\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue1Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-1\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-1\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue1Contrast4;\x0a}\x0a\x0a/*\x20Primary,\x20Hue-2\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-2\x20{\x0a\x20\x20\x20\x20background-color:\x20@primaryHue2Color;\x0a\x20\x20\x20\x20color:\x20@primaryHue2Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-2\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-2\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue2Contrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-2\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-2\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue2Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-2\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-2\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue2Contrast4;\x0a}\x0a\x0a/*\x20Primary,\x20Hue-3\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-3\x20{\x0a\x20\x20\x20\x20background-color:\x20@primaryHue3Color;\x0a\x20\x20\x20\x20color:\x20@primaryHue3Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-3\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-3\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue3Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-3\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-3\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue3Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-3\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-bg.md-hue-3\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue3Contrast4;\x0a}\x0a\x0a/*\x20Primary\x20foreground\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-fg\x20{\x0a\x20\x20\x20\x20color:\x20@primaryDefaultColor\x20!important;\x0a}\x0a\x0a/*\x20Primary\x20foreground,\x20Hue-1\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-fg.md-hue-1\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue1Color\x20!important;\x0a}\x0a\x0a/*\x20Primary\x20foreground,\x20Hue-2\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-fg.md-hue-2\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue2Color\x20!important;\x0a}\x0a\x0a/*\x20Primary\x20foreground,\x20Hue-3\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-primary-fg.md-hue-3\x20{\x0a\x20\x20\x20\x20color:\x20@primaryHue3Color\x20!important;\x0a}\x0a\x0a/*\x20Accent\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg\x20{\x0a\x20\x20\x20\x20background-color:\x20@accentDefaultColor;\x0a\x20\x20\x20\x20color:\x20@accentDefaultContrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@accentDefaultContrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@accentDefaultContrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@accentDefaultContrast4;\x0a}\x0a\x0a/*\x20Accent,\x20Hue-1\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-1\x20{\x0a\x20\x20\x20\x20background-color:\x20@accentHue1Color;\x0a\x20\x20\x20\x20color:\x20@accentHue1Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-1\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-1\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue1Contrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-1\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-1\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue1Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-1\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-1\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue1Contrast4;\x0a}\x0a\x0a/*\x20Accent,\x20Hue-2\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-2\x20{\x0a\x20\x20\x20\x20background-color:\x20@accentHue2Color;\x0a\x20\x20\x20\x20color:\x20@accentHue2Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-2\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-2\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue2Contrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-2\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-2\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue2Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-2\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-2\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue2Contrast4;\x0a}\x0a\x0a/*\x20Accent,\x20Hue-3\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-3\x20{\x0a\x20\x20\x20\x20background-color:\x20@accentHue3Color;\x0a\x20\x20\x20\x20color:\x20@accentHue3Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-3\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-3\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue3Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-3\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-3\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue3Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-3\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-bg.md-hue-3\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue3Contrast4;\x0a}\x0a\x0a/*\x20Accent\x20foreground\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-fg\x20{\x0a\x20\x20\x20\x20color:\x20@accentDefaultColor\x20!important;\x0a}\x0a\x0a/*\x20Accent\x20foreground,\x20Hue-1\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-fg.md-hue-1\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue1Color\x20!important;\x0a}\x0a\x0a/*\x20Accent\x20foreground,\x20Hue-2\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-fg.md-hue-2\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue2Color\x20!important;\x0a}\x0a\x0a/*\x20Accent\x20foreground,\x20Hue-3\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-accent-fg.md-hue-3\x20{\x0a\x20\x20\x20\x20color:\x20@accentHue3Color\x20!important;\x0a}\x0a\x0a/*\x20Warn\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg\x20{\x0a\x20\x20\x20\x20background-color:\x20@warnDefaultColor;\x0a\x20\x20\x20\x20color:\x20@warnDefaultContrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@warnDefaultContrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@warnDefaultContrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@warnDefaultContrast4;\x0a}\x0a\x0a/*\x20Warn,\x20Hue-1\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-1\x20{\x0a\x20\x20\x20\x20background-color:\x20@warnHue1Color;\x0a\x20\x20\x20\x20color:\x20@warnHue1Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-1\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-1\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue1Contrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-1\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-1\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue1Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-1\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-1\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue1Contrast4;\x0a}\x0a\x0a/*\x20Warn,\x20Hue-2\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-2\x20{\x0a\x20\x20\x20\x20background-color:\x20@warnHue2Color;\x0a\x20\x20\x20\x20color:\x20@warnHue2Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-2\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-2\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue2Contrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-2\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-2\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue2Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-2\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-2\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue2Contrast4;\x0a}\x0a\x0a/*\x20Warn,\x20Hue-3\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-3\x20{\x0a\x20\x20\x20\x20background-color:\x20@warnHue3Color;\x0a\x20\x20\x20\x20color:\x20@warnHue3Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-3\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-3\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue3Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-3\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-3\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue3Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-3\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-bg.md-hue-3\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue3Contrast4;\x0a}\x0a\x0a/*\x20Warn\x20foreground\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-fg\x20{\x0a\x20\x20\x20\x20color:\x20@warnDefaultColor\x20!important;\x0a}\x0a\x0a/*\x20Warn\x20foreground,\x20Hue-1\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-fg.md-hue-1\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue1Color\x20!important;\x0a}\x0a\x0a/*\x20Warn\x20foreground,\x20Hue-2\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-fg.md-hue-2\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue2Color\x20!important;\x0a}\x0a\x0a/*\x20Warn\x20foreground,\x20Hue-3\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-warn-fg.md-hue-3\x20{\x0a\x20\x20\x20\x20color:\x20@warnHue3Color\x20!important;\x0a}\x0a\x0a/*\x20Background\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg\x20{\x0a\x20\x20\x20\x20background-color:\x20@backgroundDefaultColor;\x0a\x20\x20\x20\x20color:\x20@backgroundDefaultContrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundDefaultContrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundDefaultContrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundDefaultContrast4;\x0a}\x0a\x0a/*\x20Background,\x20Hue-1\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-1\x20{\x0a\x20\x20\x20\x20background-color:\x20@backgroundHue1Color;\x0a\x20\x20\x20\x20color:\x20@backgroundHue1Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-1\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-1\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue1Contrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-1\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-1\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue1Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-1\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-1\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue1Contrast4;\x0a}\x0a\x0a/*\x20Background,\x20Hue-2\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-2\x20{\x0a\x20\x20\x20\x20background-color:\x20@backgroundHue2Color;\x0a\x20\x20\x20\x20color:\x20@backgroundHue2Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-2\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-2\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue2Contrast2;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-2\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-2\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue2Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-2\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-2\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue2Contrast4;\x0a}\x0a\x0a/*\x20Background,\x20Hue-3\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-3\x20{\x0a\x20\x20\x20\x20background-color:\x20@backgroundHue3Color;\x0a\x20\x20\x20\x20color:\x20@backgroundHue3Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-3\x20.secondary-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-3\x20.icon\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue3Contrast1;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-3\x20.hint-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-3\x20.disabled-text\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue3Contrast3;\x0a}\x0a\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-3\x20.fade-text,\x0a[md-theme=\x22@themeName\x22]\x20.md-background-bg.md-hue-3\x20.divider\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue3Contrast4;\x0a}\x0a\x0a/*\x20Background\x20foreground\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-background-fg\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundDefaultColor\x20!important;\x0a}\x0a\x0a/*\x20Background\x20foreground,\x20Hue-1\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-background-fg.md-hue-1\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue1Color\x20!important;\x0a}\x0a\x0a/*\x20Background\x20foreground,\x20Hue-2\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-background-fg.md-hue-2\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue2Color\x20!important;\x0a}\x0a\x0a/*\x20Background\x20foreground,\x20Hue-3\x20*/\x0a[md-theme=\x22@themeName\x22]\x20.md-background-fg.md-hue-3\x20{\x0a\x20\x20\x20\x20color:\x20@backgroundHue3Color\x20!important;\x0a}','Giorgio','createOrEditTelephone','selectAllFaxAccounts','added','cmHopperHistory','nameField','msScroll','src/js/modules/main/apps/motiondialer/views/ivrCampaigns/edit/clone/clone.html/clone.html','#chat-group-dialog','TOOLBAR.CHINESESIMPLIFIED','pages','stringify','Filiz','UserSmsDashboardGeneralController\x20as\x20vm','hasModulePermissions','onInteractionSave','settings/:id/gdpr','getColorByChannel','addNewItem','America/Indiana/Vincennes','SYSTEM:DELETEmailQueue','Tag\x20properly\x20created!','faxAccounts','getMusicOnHolds','LoadingIndicatorService','state','replyTemplate','msNavigation::clearActive','cmList','rpc/campaigns','secondDisposition','app.tools.pauses','\x2727\x27','America/Juneau','chatWebsites','OpenchannelCannedAnswer\x20properly\x20created','FreshsalesAccountConfigurationsController','loggedInDb','SmsAccountController','minutes','Delete\x20MailAccount','app.marketplace.plugins.edit','Subject','api.whatsappQueue.delete','newsAlertOnClose','newWhatsappQueue','red-300-fg\x20icon-phone-locked','app.motiondialer.queueCampaigns','deselectUsers','saveChatWebsite','Trunk\x20updated!','America/Tijuana','exportSelectedListCustomFields','Mandarin\x20Chinese','mouseenter\x20mouseleave','SYSTEM:RESETLIST','has','onRemoveUserOpenchannelQueue','INTEGRATIONS.EDIT_DYNAMICS365ACCOUNT','$mdMedia','api.squareProject.save','collapse','getAbandonedCalls','NoAnswer','q:\x20Don\x27t\x20play\x20a\x20beep\x20when\x20beginning\x20to\x20spy\x20on\x20a\x20channel,\x20or\x20speak\x20the\x20selected\x20channel\x20name.','app.openchannel.openchannelQueues.edit','createdAt,updatedAt,id,save_name,converted_format,name,audio,description','STAFF.QUEUEADD_AGENT_','Projects','IvrCampaigncloneController','Type','random','getItems','src/js/modules/main/apps/contactmanager/views/companies/companies.html/companies.html','user@get','European\x20Turkish\x20Female','xorBy','changePasswordForm','MsTimerController','createdAt,updatedAt,id,name,key,email,ListId,active,cservice,Imap.service,Imap.host,Imap.port,Imap.tls,Imap.authentication,Imap.user,Imap.password,Imap.mailbox,Imap.connTimeout,Imap.authTimeout,Smtp.service,Smtp.host,Smtp.port,Smtp.secure,Smtp.authentication,Smtp.user,Smtp.pass,cauthentication,cuser,cpassword,fontFamily,fontSize,template,markAsUnread,waitForTheAssignedAgent,description,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','app.tools.cannedAnswers','api.intItem.update','src/js/modules/main/apps/chat/views/chatWebsites/edit/agentadd/agentadd.html/agentadd.html','The\x20context\x20will\x20be\x20deleted.','app.contactmanager.contacts.edit','EditOpenchannelAccountAppdialogflowDialogController','IS\x20NOT\x20NULL','Days','ms-search-bar-expanded','saveGeneral','+09:30','token','TriggerController\x20as\x20vm','initDeviceInProgress','intVtigerConfiguration','selectedServicenowAccounts','folded','getUserProfiles','VOICE.EDIT_OUTBOUNDROUTE','trigger','selectedProjects','smsInteraction:save','whatsappQueue','_id','Websites','outgoing','arrayminrate','src/js/modules/core/layouts/content-only.html/content-only.html','saveChatWebsiteApp','createTag','$[${LEN(${CDR(prefix)})}\x20>\x200]?Goto(','beepall','DASHBOARDS.SELECT_QUEUE','JSCRIPTY.NO','\x27random\x27','openProject','plugins','CreateOrEditSalesforceAccountItemDialogController','openchannel/accounts/:id/canned_answers','\x27number\x27','/chatWebsites','flippable','api.dashboard.update','Square\x20ODBC\x20properly\x20tested','Process\x20stopped!','mdColorPicker','No\x20\x27%s\x27\x20process\x20found','rgba(','UserProfile\x20properly\x20cloned','zoho.eu','intDynamics365Account','SYSTEM:DELETEvoiceExtension','isStepCurrent','deleteSelectedTelephones','icon-phone-missed','Arabic\x20(Saudi\x20Arabia)','AgentController','DASHBOARDS.NOT_ASSIGNED','ngAria','setting','createOrEditChatQueue','selectedTelephones','endDate','US\x20East\x20(N.\x20Virginia)','getDate','\x27GP\x27','src/js/modules/main/apps/settings/views/networks/networks.html/networks.html','muted','onRemoveWhatsappQueueChannel','Checkboxes','wss','AgentHomeOpenchannelController','mailQueue:save','selectAllTemplates','AgentPermissionsController','deletevoicePrefix','pause_id','createOrEditVtigerConfiguration','getVoiceRecordings','comedia','SoundsController','localizationMap','src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/dialogflow/dialog.html/dialog.html','apps.voice.contexts','Round\x20Robin','ERROR\x20REMOVE\x20TAB','conditions/describe','OutboundRoute\x20updated!','The\x20mailCannedAnswer\x20will\x20be\x20deleted.','saveIvrCampaign','arraycservice','src','detectBrowser','foreignKey','This\x20Year','initialize','TOOLS.CANNEDANSWERS','Busy','Frisian','mycontacts','trigger:browser:url','msMaterialColorPicker','motion2.home.voice:','messages','app.chat.realtime.agents','webrtc::call','src/js/modules/main/apps/integrations/views/freshsalesAccounts/edit/item/dialog.html/dialog.html','SYSTEM:GETintDynamics365Account','ServicenowConfiguration\x20properly\x20created','whatsappAccounts','CreateOrEditOpenchannelQueueDialogController','Phonebar','CreateOrEditServicenowAccountDialogController','chat/interactions/:id/messages','voice/contexts/:id/clone','placeholders','INTEGRATIONS.NEW_ZENDESKCONFIGURATION','apiResolver.resolve\x20requires\x20correct\x20action\x20parameter\x20(ResourceName@methodName)','angularMaterialFormBuilder','smtps','SYSTEM:DELETEinterval','flipped','Maxim','Do\x20not\x20Disturb','sms_queue_waiting_interaction:remove','The\x20chatCannedAnswer\x20will\x20be\x20deleted.','Metrics','voiceMusicOnHold@get','selectedChanSpies','PausesController','removed','exportSelectedMusicOnHoldMohSounds','MusicOnHold\x20properly\x20deleted!','createOrEditSubject','direction','faxMessage:save','pound','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20salesforceAccounts?','INTEGRATIONS.EDIT_SERVICENOWACCOUNT','apps.settings.license','getQueueCampaignHopperBlacks','ChatProactiveAction\x20properly\x20saved!','\x27minutes\x27','selectAllOpenchannelQueues','openchannelQueueReport','voiceQueueReport:update','#tab-container','voice/dials/reports/describe','Motion\x20WebRTC\x20Bar\x200.2.0','fax/interactions/:id/clone','Metric\x20properly\x20deleted!','CreateOrEditSmsCannedAnswerDialogController','showLastMessage','images','Least\x20Recent','mail.mailAccounts','yAxes','selectAllLists','ABANDONED','app.dashboards.general.fax','FreshsalesConfiguration\x20properly\x20created','integrations/zoho/configurations/:id/subjects','saveOpenchannelAccountApp','MailAccounts','arrayallow','outboundQueues','Report\x20properly\x20saved!','getWhatsappQueues','deleteSelectedChatWebsiteOfflineMessages','checkPause','^msWidget','getVoiceQueuesReport','api.cannedAnswer.save','/generals','Delete\x20ChatProactiveAction','api.intZohoConfiguration.update','\x27tr\x27','ca-ES','chatWebsite','pow','OpenchannelAccount\x20properly\x20deleted!','createdAt,updatedAt,id,alias,type,values,required,clickToAction,actionType','onSubmit','id,name,fullname','gotoServicenowAccounts','NONAME','contact:import:','isHidden','/motiondialer','deselectDispositions','SugarCRM','chatTransferReport','CDR(type)=internal','src/js/modules/main/apps/settings/views/license/license.html/license.html','api.schedule.save','deleteFaxQueue','STAFF.EDIT_TELEPHONE','aws_bot_name','controls','WHATSAPP.REALTIME','ap-northeast-2','templateUrl','extractedReport','FaxQueueController','The\x20mailQueue\x20will\x20be\x20deleted.','integrations/servicenow/accounts/:id/clone','SYSTEM:GETwhatsappQueue','integrations/sugarcrm/accounts/:id','msSplashScreen','id,firstName,lastName,phone,email','\x27W\x27','$on','subStatuses','MarketplacePluginController\x20as\x20vm','onSaveUserChatQueue','Delete\x20Team','dateOfBirth','deleteInternalRouteApp','getCompanies','showLoadingIndicator','selectedVoiceRecordings','true','openchannelCannedAnswer','originalObject','Tajik','Error\x20creating\x20tag!','selectedFreshdeskAccounts','AgentsFaxRealtimeController\x20as\x20vm','Whatsapp','Fax\x20Messages','Atlantic/Reykjavik','chunk','treeCustomEvents','invalid','apps.motiondialer.ivrCampaigns','_options','One\x20Time','Asia/Yerevan','zh-TW','SYSTEM:DELETEchatQueue','apps.home.plugin_','deleteSelectedGlobalCustomFields','VOICE.NEW_VOICEMAIL','api.plugin.delete','src/js/modules/main/apps/integrations/views/freshdeskAccounts/create/dialog.html/dialog.html','newVoiceQueue','Delete\x20GlobalCustomField','savePause','SalesforceAccountController','InternalRoutes','PDF','deleteMailAccountMailCannedAnswer','intVtigerAccount','FaxQueueId','gotoOpenchannelAccounts','triggers/:id/clone','cmHopper','FreshsalesAccount\x20properly\x20deleted!','/intervals','Months','selectedTemplateName','ProjectId','Smtp\x20properly\x20deleted!','saveServicenowAccount','FreshsalesAccountsController\x20as\x20vm','EditInboundAppcustomDialogController','IntervalIntervalsController','List','createdAt,updatedAt,id,service,name,email,Smtp.service,Smtp.host,Smtp.port,Smtp.secure,Smtp.authentication,Smtp.user,Smtp.pass,description','MxGraphEditXMLController','format','trigger:jscripty','dark','variable','TOOLS.NOTIFICATIONS.CONDITION_DELETE_TITLE','TOOLS.EDIT_TAG','htmlContent','MOTIONDIALER.NEW_HOPPER','#ms-shortcut-add-menu','voice/transfers/reports/:id/clone','\x27yahoo\x27','Indian/Chagos','app.tools.variables','Start','deleteConfirm','PREVIOUS\x20CONTACTS\x20NOT\x20AVAILABLE','../../../../../../../assets/images/avatars/customer.png','EditFaxAccountAppnoopDialogController','src/js/modules/main/apps/whatsapp/views/realtime/queues/view.html/view.html','onEnded\x20->\x20session,\x20data','FreshsalesConfiguration\x20properly\x20deleted!','usenglishmale','addNewMailCannedAnswer','ZendeskConfiguration\x20deleted!','intSugarcrmAccount','createOrEditVoiceQueue','/cannedAnswers','selectReport','getZohoAccounts','\x27wss\x27','wss://','msSearchBar','deselectDynamics365Accounts','ODBC','src/js/modules/main/apps/openchannel/views/openchannelQueues/edit/view.html/view.html','INTEGRATIONS.NEW_SALESFORCEACCOUNT','aws_text_type','api.cmCompany.delete','TOOLS.NOTIFICATIONS.CONDITIONS_DELETE_MESSAGE','toggleSidenav','voice/calls/reports/:id','_interactions:save','Australia/Perth','Justin\x20(English,\x20US,\x20Male)','rpc/agents/:id/notify','DASHBOARDS.CLOSED','home.fax','\x27SI\x27','\x27users\x27','date','whatsapp/queues/:id/teams','#78a0dc','upperFirst','cm/contacts/create_many','baseUrl','id,name,level,ParentId','AgentHomeDashboardMultiChannelSmsController','saveItem','chatCannedAnswer\x20#','app.staff.agents.edit','user:update','clearAll','en-GH','delete\x20deskAccount','TOOLS.NOTIFICATIONS.TRIGGERS_DELETE_TITLE','ms-widget-front','onRemoveUserMailQueue','newOpenchannelAccount','app.analytics.reports','VOICE.OUTBOUNDROUTES','shift','addNewReport','HANGUPCAUSE_27','setText','ringing','instant','addNewSquareRecording','$setPristine','mail/reports/queue/:id/clone','arrayheader_shape','config','ANSWERED','selectedZendeskAccounts','voiceQueue@get','delete\x20Networks','trunk_id','deselectMailQueues','WebRTC\x20Popup','analyticCustomReport@get','getVoicemailMessages','src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/hangup/dialog.html/dialog.html','getMetrics','GeneralsController','project','selectAllUserProfiles','listSelected','ngAnimate','exportSelectedReports','XCALLY-MOTION-PROGRESS=1','whatsappInteractions','app.voice.voiceQueues','migrations/:id','Attachment\x20is\x20mandatory','form','selectedCustomDashboards','isAfter','$mdThemingProvider','showMailInteraction','None','excludeFrom','endTimeAttr','\x20has\x20been\x20modified.\x20Closing\x20will\x20lose\x20all\x20changes!','api.network.update','FORGOTPASSWORD.LINNK_SENT_MESSAGE','createOrEditFreshsalesConfiguration','DASHBOARDS.THIS_MONTH','verifySmtp','integrations/:id/clone','The\x20team\x20will\x20be\x20deleted.','onUpdateVoiceQueueReport','escapeToClose','ms-search-bar','phoneBarAutoAnswerDelay','phoneBarPrefixRequired','getOpenchannelQueues','defaultQueues','square/reports/describe','createOrEditSalesforceAccount','develop','ChatProactiveAction\x20properly\x20deleted!','deselectChatQueues','selectedWhatsappAccountWhatsappCannedAnswers','includeAll','faxQueue:remove','showFooter','deleteAgent','hasSpeakers','FaxRealtimeController','href','ivrCampaignHoppers','salesforceAccount','integrations/dynamics365/configurations/:id/fields','deleteSelectedReports','MsNavigationController\x20as\x20vm','selectedWhatsappAccountApps','cmContact','apps.openchannel.realtime','VoicePrefixes','2020-11-13T10:58:01.719Z','motion.language','permissionsmanagedialog','savescreenRecording','use','/dashboards/general','trunk:save','sounds/:id','DASHBOARDS.','blacklistadddialog','chatWebsiteApp','scriptPath','simple','Spanish\x20(Panama)','Chinese\x20(Simplified)','editSmsAccountApp','userProfile/sections/:id/clone','updateInfo','currentStepInvalid','src/js/modules/main/apps/contactmanager/views/contacts/edit/view.html/view.html','down','integrations/dynamics365/fields/:id','smsStatus','selectAllSounds','AbandonedCallsMotionDialerRealtimeController','dashboard:remove','faxStatus','Africa/Nairobi','whoami','icecandidate','cm/companies/:id/clone','data1','selectedIntervalIntervals','Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20intervals?','selectAllSugarcrmAccounts','newTrunk','Subject\x20has\x20been\x20deleted!','onChangeReportType','soundPlayer','saveCompany','openchannel/accounts/:id/notify','\x27openchannel_queues\x27','+06:00','onRemoveOpenchannelQueueChannel','app.dashboards.general','\x20has\x20been\x20uninstalled!','saveList','The\x20zendeskConfiguration\x20will\x20be\x20deleted.','GET_TRUNK','src/js/modules/core/directives/ms-navigation/templates/vertical.html/vertical.html','arrayqualify','/api/chat/interactions/','conditions','src/js/modules/main/apps/voice/views/outboundroutes/edit/apps/custom/dialog.html/dialog.html','Invalid\x20number\x20of\x20arguments\x20supplied\x20in\x20the\x20color\x20array:\x20','Delete\x20IvrCampaign','DASHBOARDS.CANCEL','predictiveIntervalTotalCalls','\x27chat_offline_messages\x27','\x27timeout\x27','GoSub','FaxAccount','SYSTEM:DELETEuserProfile','Delete\x20conditions','joinAt','deleteDescriptionConfirm','addAction','Europe/Athens','warn','hold','RECALLME','SchedulesController','cloneQueueCampaign','DASHBOARDS.RESCHEDULE','smsQueue@get','mail/accounts/:id','deleteGlobalCustomField','plugins/:id','si-LK','msNavigationService','layoutMode','TOOLBAR.SWEDISH','\x2722\x27','dateTime','app.tools.triggers','arrayactionType','VOICE.VOICERECORDINGS','trunks/:id','websocket','selectedColor','Japanese\x20(Japan)','ERROR\x20OPEN\x20INTERACTION','src/js/modules/main/apps/dashboards/views/general/agent/interaction/transfer/dialog.html/dialog.html','deselectAiTools','getMembers','createOrEditQueueCampaignHopper','selectedPauses','MusicOnHolds','integrations/freshsales/accounts/:id/fields'];(function(_0x361a4c,_0x598e59){const _0x4e0aa3=function(_0x8683ef){while(--_0x8683ef){_0x361a4c['push'](_0x361a4c['shift']());}};_0x4e0aa3(++_0x598e59);}(a0_0x598e,0xbe));const a0_0x4e0a=function(_0x361a4c,_0x598e59){_0x361a4c=_0x361a4c-0x0;let _0x4e0aa3=a0_0x598e[_0x361a4c];return _0x4e0aa3;};const _0x26a114=a0_0x4e0a;(self['webpackChunkmotion_client']=self[_0x26a114('0x13e0')]||[])[_0x26a114('0x1fd0')]([[0x8f],{0x2069:(_0x8683ef,_0x3da661,_0x180212)=>{const _0x189033=_0x26a114;'use strict';var _0x902221=_0x180212(0x304);_0x37e3fb[_0x189033('0x14be')]=['$httpProvider'];function _0x37e3fb(_0x2fb0a1){const _0x10dd1a=_0x189033;_0x2fb0a1[_0x10dd1a('0x132b')][_0x10dd1a('0x1fd0')](_0x10dd1a('0x249f'));}const _0x91a8a7=_0x37e3fb;_0x4520a1[_0x189033('0x14be')]=['$transitions'];function _0x4520a1(_0x1803a5){const _0x1e219c=_0x189033,_0x30bde7={'to':function(_0x575f33){const _0x400abd=a0_0x4e0a;return _0x575f33[_0x400abd('0x159e')]===!![];}},_0x485551={'to':function(_0x2881c4){const _0x50c3d8=a0_0x4e0a;return _0x2881c4[_0x50c3d8('0x60a')]!==_0x50c3d8('0x8a0');}},_0xd3273e={'to':function(_0x2690eb){const _0x57688d=a0_0x4e0a;return _0x2690eb[_0x57688d('0x14cc')];}},_0x31b0bc={'to':function(_0x381a05){const _0x4c4c84=a0_0x4e0a;return _0x381a05['parent'][_0x4c4c84('0x60a')]==='app.dashboards.general';}},_0x5e1023=function(_0x4a178e){const _0x47f830=a0_0x4e0a,_0xeedb64=_0x4a178e[_0x47f830('0xfc0')]()['get'](_0x47f830('0xba1')),_0x5377df=_0x4a178e[_0x47f830('0x1298')]['stateService'];return!_0xeedb64[_0x47f830('0x1088')]()?_0x5377df['target'](_0x47f830('0x8a0'),undefined,{'reload':!![]}):_0xeedb64[_0x47f830('0xb28')]()[_0x47f830('0x130a')](function(){const _0xe487d4=_0x47f830;return _0x5377df[_0xe487d4('0x568')]('app.login',undefined,{'reload':!![]});});},_0x5d0402=function(_0x1748e2){const _0x20dc5a=a0_0x4e0a,_0x291501=_0x1748e2['injector']()['get'](_0x20dc5a('0xba1')),_0x1e03d9=_0x1748e2['router'][_0x20dc5a('0x6b9')],_0x3bc760=_0x1748e2['$to']();if(_0x291501['hasRole'](_0x20dc5a('0x2327'))&&_0x3bc760[_0x20dc5a('0x60a')]!=_0x20dc5a('0x279d'))return _0x1e03d9['target'](_0x20dc5a('0x279d'),{'redirect':![]},{'reload':!![]});},_0x1424d9=function(_0x4cd218){const _0x5e052f=a0_0x4e0a,_0x449e88=_0x4cd218[_0x5e052f('0xfc0')]()[_0x5e052f('0x1e6e')](_0x5e052f('0xba1')),_0x86e55c=_0x4cd218[_0x5e052f('0x1298')]['stateService'],_0x500596=_0x4cd218[_0x5e052f('0x1448')]();if(_0x449e88[_0x5e052f('0xca1')](_0x5e052f('0xc96'))){if(!_0x449e88[_0x5e052f('0x5e3')](_0x500596['permissionId']))return _0x86e55c[_0x5e052f('0x568')]('app.dashboards.general',{'redirect':![]},{'reload':!![]});else{const _0x12067d=_0x4cd218[_0x5e052f('0x7f2')]()['id']?Number(_0x4cd218['params']()['id']):undefined;if(_0x12067d)return _0x449e88['hasResourcePermission'](_0x500596[_0x5e052f('0x14cc')],_0x12067d)['catch'](function(){const _0x105191=_0x5e052f;return _0x86e55c[_0x105191('0x568')](_0x500596[_0x105191('0x2361')][_0x105191('0x60a')],{'redirect':![]},{'reload':!![]});});}}},_0x3d829f=function(_0x4c8a5d){const _0x1f5e43=a0_0x4e0a,_0x2176a6=_0x4c8a5d[_0x1f5e43('0xfc0')]()[_0x1f5e43('0x1e6e')](_0x1f5e43('0xba1')),_0x5da79c=_0x4c8a5d['router'][_0x1f5e43('0x6b9')];if(_0x2176a6['hasRole']('user')&&!_0x2176a6[_0x1f5e43('0x5e3')](0x64))return _0x5da79c[_0x1f5e43('0x568')](_0x1f5e43('0x279d'),{'redirect':![]},{'reload':!![]});};_0x1803a5[_0x1e219c('0x21f0')](_0x30bde7,_0x5e1023),_0x1803a5[_0x1e219c('0x38a')](_0x485551,_0x5d0402),_0x1803a5[_0x1e219c('0x1059')](_0xd3273e,_0x1424d9),_0x1803a5[_0x1e219c('0x1059')](_0x31b0bc,_0x3d829f);}const _0x5a7078=_0x4520a1;var _0x2bc590=_0x180212(0x1956),_0x2e3ca0=_0x180212['n'](_0x2bc590),_0xf3df26=_0x180212(0x17d),_0x1aaf93=_0x180212['n'](_0xf3df26);const _0x1c0b02=_0x180212['p']+_0x189033('0x4bb');_0x5df21d[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x17e4'),'$q','api',_0x189033('0x2063'),_0x189033('0x16ea')];function _0x5df21d(_0x5ec489,_0x2d3d37,_0x46f8ec,_0x2ae32f,_0x8c1ac9,_0x69ed25){let _0x866df2;const _0x305d83={'getToken':_0x24ffac,'getCurrentUser':_0x5e4f17,'getPermissions':_0x15fb2b,'hasChildrenPermissions':_0x347f78,'hasModulePermissions':_0x4d7bef,'hasModulesPermissions':_0x1609cb,'hasRole':_0x303b10,'hasPermission':_0x128ab9,'hasResourcePermission':_0x4607d2,'hasSectionPermissions':_0x56254a,'hasSectionsPermissions':_0xaa3ba7,'isAgent':_0x1e492e,'isAdmin':_0x15a06d,'isLoggedIn':_0x4ed488,'isTelephone':_0x58c346,'isUser':_0x1b2f64,'login':_0x9a5d9a,'logout':_0x274202,'parseCrudPermissions':_0x48d66d,'queueLogin':_0x3976d9,'reloadPermissions':_0x47c7c0,'removeCookies':_0x5e9dc0,'retrieveUser':_0x2d84ae,'setCurrentUser':_0x12864a,'getAuthenticationType':_0x14c396,'loginSSO':_0x5ec1d9};return _0x305d83;function _0x24ffac(){const _0x314375=a0_0x4e0a;return _0x2d3d37['get'](_0x314375('0x555'));}function _0x5e4f17(){return _0x866df2;}function _0x12864a(_0x41c8aa){_0x866df2=_0x2e3ca0()['merge'](_0x866df2,_0x41c8aa);}function _0x3976d9(_0x2aaaa7){return _0x46f8ec(function(_0x5543e2,_0x29fdf6){const _0x1932c6=a0_0x4e0a;_0x2ae32f[_0x1932c6('0xc96')][_0x1932c6('0x125')]({'id':_0x866df2['id'],'device':_0x1932c6('0x1eee'),'intrf':_0x2aaaa7})[_0x1932c6('0xe53')][_0x1932c6('0x683')](function(_0x47f4b6){_0x5543e2(_0x47f4b6);})['catch'](function(_0x5805f0){_0x29fdf6(_0x5805f0);});});}function _0xe0385c(){return _0x46f8ec(function(_0x35173b,_0x1c6d55){const _0x59df0f=a0_0x4e0a;_0x2ae32f[_0x59df0f('0xc96')][_0x59df0f('0x1999')]({'id':_0x866df2['id'],'device':_0x59df0f('0x1eee')})[_0x59df0f('0xe53')][_0x59df0f('0x683')](function(){_0x35173b();})[_0x59df0f('0x130a')](function(_0x49f395){_0x1c6d55(_0x49f395);});});}function _0x2e8015(_0x3abf1d){return _0x46f8ec(function(_0x1f47e1,_0x59b171){const _0x17e60b=a0_0x4e0a,_0x53692a={'online':_0x3abf1d,'lastLoginAt':_0x3abf1d?_0x1aaf93()()['format'](_0x17e60b('0x865')):undefined};_0x2ae32f[_0x17e60b('0xc96')][_0x17e60b('0x2480')]({'id':_0x866df2['id']},_0x53692a)[_0x17e60b('0xe53')][_0x17e60b('0x683')](function(_0x8f95fc){_0x1f47e1(_0x8f95fc);})[_0x17e60b('0x130a')](function(_0x139931){_0x59b171(_0x139931);});});}function _0x9a5d9a(_0x7b8f4f){return _0x46f8ec(function(_0x9a167b,_0x1bfd04){const _0x5b6130=a0_0x4e0a;_0x2ae32f[_0x5b6130('0x69f')][_0x5b6130('0x1f37')](_0x7b8f4f)['$promise'][_0x5b6130('0x683')](function(_0x5eeba7){const _0x3f7410=_0x5b6130;return _0x2d3d37[_0x3f7410('0x137e')](_0x3f7410('0x555'),_0x5eeba7[_0x3f7410('0x25da')]),_0x2ae32f[_0x3f7410('0xc96')][_0x3f7410('0x1e6e')]({'id':_0x5eeba7['id']})[_0x3f7410('0xe53')];})[_0x5b6130('0x683')](function(_0x3a8f62){const _0x2c1276=_0x5b6130;_0x866df2=_0x3a8f62,_0x866df2['lastLoginAt']=_0x1aaf93()()[_0x2c1276('0x26dd')]('YYYY-MM-DD\x20HH:mm:ss'),_0x2701b3(_0x2c1276('0x1b4d'));})[_0x5b6130('0x683')](function(){const _0x2091ec=_0x5b6130;if(_0x1e492e()&&_0x866df2[_0x2091ec('0xf8e')]===0x1&&_0x866df2[_0x2091ec('0x1ac7')])return _0x5ec489[_0x2091ec('0x1d4')]({'controller':_0x2091ec('0x5b5'),'controllerAs':'vm','templateUrl':_0x1c0b02,'parent':angular['element'](_0x69ed25['body']),'clickOutsideToClose':![],'resolve':{'telephones':[_0x2091ec('0x4b1'),function(_0x1058e7){const _0x95a88=_0x2091ec;return _0x1058e7[_0x95a88('0xed7')]('user@get',{'fields':_0x95a88('0x1d45'),'role':'telephone','nolimit':!![]});}]}});})[_0x5b6130('0x683')](function(_0x400166){const _0x390069=_0x5b6130;if(_0x1e492e()&&_0x866df2[_0x390069('0xf8e')]!==0x0)return _0x3976d9(_0x400166);else{if(_0x15a06d()||_0x1b2f64())return _0x2e8015(!![]);else return;}})[_0x5b6130('0x683')](function(_0x5bb60e){const _0x98c4c6=_0x5b6130;_0x866df2=_0x2e3ca0()[_0x98c4c6('0x196a')](_0x866df2,_0x5bb60e),_0x9a167b();})[_0x5b6130('0x130a')](function(_0x3c0b34){_0x1bfd04(_0x3c0b34);});});}function _0x5e9dc0(){const _0x3fdbfa=a0_0x4e0a;_0x2d3d37[_0x3fdbfa('0x3ec')](_0x3fdbfa('0x555')),_0x866df2&&(_0x8c1ac9[_0x3fdbfa('0x120e')][_0x3fdbfa('0x26d')]('motion.user:'+_0x866df2['id']),_0x8c1ac9['localStorage'][_0x3fdbfa('0x26d')](_0x3fdbfa('0x2354')),_0x866df2=null);}function _0x274202(_0x3b425e){return _0x46f8ec(function(_0x45e95e,_0x2e83d7){const _0x4c290b=a0_0x4e0a;_0x3b425e?(_0x5e9dc0(),_0x45e95e()):_0x46f8ec[_0x4c290b('0xed7')]()['then'](function(){const _0x389834=_0x4c290b;if(_0x1e492e()&&_0x866df2[_0x389834('0xf8e')]!==0x0)return _0xe0385c();else{if(_0x15a06d()||_0x1b2f64())return _0x2e8015(![]);else return;}})[_0x4c290b('0x683')](function(){_0x5e9dc0(),_0x45e95e();})['catch'](function(_0x2bd200){_0x2e83d7(_0x2bd200);});});}function _0x4ed488(){return _0x24ffac()?!![]:![];}function _0x1e492e(){const _0x5ed595=a0_0x4e0a;return _0x866df2[_0x5ed595('0xecb')]===_0x5ed595('0x2327');}function _0x15a06d(){const _0x44cece=a0_0x4e0a;return _0x866df2[_0x44cece('0xecb')]===_0x44cece('0x20c2');}function _0x1b2f64(){const _0xef6a3f=a0_0x4e0a;return _0x866df2[_0xef6a3f('0xecb')]===_0xef6a3f('0xc96');}function _0x58c346(){const _0xbc73b9=a0_0x4e0a;return _0x866df2['role']===_0xbc73b9('0x24d3');}function _0x2d84ae(){return _0x46f8ec(function(_0x48cfe2,_0x236d86){const _0x11a110=a0_0x4e0a;_0x2ae32f[_0x11a110('0xc96')][_0x11a110('0x278d')]()['$promise'][_0x11a110('0x683')](function(_0x123447){const _0x41f28d=_0x11a110;return _0x123447[_0x41f28d('0xecb')]===_0x41f28d('0xc96')?_0x15fb2b(_0x123447[_0x41f28d('0x2f')])[_0x41f28d('0x683')](function(_0x574642){return _0x123447['permissions']=_0x574642,_0x123447;}):_0x123447;})[_0x11a110('0x683')](function(_0x28f6ff){_0x866df2=_0x28f6ff,_0x48cfe2(_0x866df2);})[_0x11a110('0x130a')](function(_0x557db5){_0x236d86(_0x557db5);});});}function _0x303b10(_0x43c62c){const _0xc8e361=a0_0x4e0a;return _0x866df2?_0x866df2[_0xc8e361('0xecb')]===_0x43c62c:![];}function _0x128ab9(_0x35e718){const _0x15d306=a0_0x4e0a;return _0x866df2?_0x2e3ca0()[_0x15d306('0x2292')](_0x866df2[_0x15d306('0x924')],_0x35e718):![];}function _0x15fb2b(_0x431e7d){let _0x2b6fb8=[];return _0x46f8ec(function(_0x36375a,_0x564295){const _0x11db0c=a0_0x4e0a;return!_0x431e7d&&_0x36375a(_0x2b6fb8),_0x2ae32f[_0x11db0c('0x2a')][_0x11db0c('0x2225')]({'id':_0x431e7d})['$promise'][_0x11db0c('0x683')](function(_0x2a9deb){const _0x4268db=_0x11db0c;for(let _0x125628=0x0;_0x125628<_0x2a9deb[_0x4268db('0x1564')];_0x125628++){const _0x4749bb=_0x2a9deb[_0x125628];_0x2b6fb8[_0x4268db('0x1fd0')](_0x4749bb[_0x4268db('0x21c0')]),_0x4749bb[_0x4268db('0x31')]&&(_0x2b6fb8=_0x2e3ca0()[_0x4268db('0x746')](_0x2b6fb8,_0x4749bb[_0x4268db('0x31')]));}return _0x2b6fb8;})['then'](function(_0x12cc9e){_0x36375a(_0x12cc9e);})[_0x11db0c('0x130a')](function(_0x57ac10){const _0x486f76=_0x11db0c;_0x564295(_0x486f76('0x249c'),_0x57ac10);});});}function _0x347f78(_0x2250f1){const _0x1b1f20=a0_0x4e0a;if(!_0x2250f1)return![];return _0x2e3ca0()[_0x1b1f20('0x7a2')](_0x2250f1,function(_0xce4cae){return _0x128ab9(_0xce4cae);});}function _0x47c7c0(){return _0x46f8ec(function(_0xb8cf06,_0x4593a1){const _0x4b90aa=a0_0x4e0a;_0x15fb2b(_0x866df2[_0x4b90aa('0x2f')])[_0x4b90aa('0x683')](function(_0x164bbd){const _0x5323b7=_0x4b90aa;_0x866df2[_0x5323b7('0x924')]=_0x164bbd,_0xb8cf06();})[_0x4b90aa('0x130a')](function(_0x4e136e){_0x4593a1(_0x4e136e);});});}function _0x48d66d(_0x3b0e6c){const _0x34633c=a0_0x4e0a;return _0x15a06d()?{'readOnly':![],'canEdit':!![],'canDelete':!![]}:!_0x3b0e6c?{'readOnly':!![],'canEdit':![],'canDelete':![]}:{'readOnly':_0x2e3ca0()['includes'](_0x3b0e6c,'r')&&_0x3b0e6c[_0x34633c('0x1564')]===0x1?!![]:![],'canEdit':_0x2e3ca0()[_0x34633c('0x2292')](_0x3b0e6c,'e')?!![]:![],'canDelete':_0x2e3ca0()[_0x34633c('0x2292')](_0x3b0e6c,'d')?!![]:![]};}function _0x4607d2(_0x38862b,_0x581710){return _0x46f8ec(function(_0x13e4a7,_0x5d9d75){const _0x14ccd2=a0_0x4e0a;return _0x2ae32f[_0x14ccd2('0x22df')][_0x14ccd2('0x1e6e')]({'userProfileId':_0x866df2[_0x14ccd2('0x2f')],'sectionId':_0x38862b})[_0x14ccd2('0xe53')]['then'](function(_0x53877c){const _0x564529=_0x14ccd2,_0x4df5bc=_0x53877c['rows'][0x0];if(_0x4df5bc[_0x564529('0x170')])_0x13e4a7();else return _0x2ae32f['userProfileResource'][_0x564529('0x1e6e')]({'sectionId':_0x4df5bc['id'],'nolimit':!![]})[_0x564529('0xe53')][_0x564529('0x683')](function(_0x122798){const _0x472657=_0x564529,_0x35f416=_0x122798[_0x472657('0xf5d')];_0x2e3ca0()[_0x472657('0x7a2')](_0x35f416,['resourceId',_0x581710])?_0x13e4a7():_0x5d9d75();});})[_0x14ccd2('0x130a')](function(_0x3cce83){const _0x161ec2=_0x14ccd2;_0x5d9d75(_0x161ec2('0x249c'),_0x3cce83);});});}function _0x56254a(_0xb21179){return _0x46f8ec(function(_0x10f1a9,_0x48d66b){const _0x3755ab=a0_0x4e0a,_0x36c50c={};return _0x47c7c0()[_0x3755ab('0x683')](function(){const _0x2127f6=_0x3755ab;_0x2e3ca0()[_0x2127f6('0x2292')](_0x866df2[_0x2127f6('0x924')],_0xb21179)&&(_0x36c50c[_0xb21179]=!![]),_0x10f1a9(_0x36c50c);})[_0x3755ab('0x130a')](function(_0x2b19ba){_0x48d66b(_0x2b19ba);});});}function _0xaa3ba7(_0x117833){return _0x46f8ec(function(_0x13baa8,_0x3ec85b){const _0xa7e753=a0_0x4e0a,_0x5880a8={};if(_0x15a06d())_0x117833[_0xa7e753('0x1299')](function(_0x4dde57){_0x5880a8[_0x4dde57]=!![];}),_0x13baa8(_0x5880a8);else return _0x47c7c0()[_0xa7e753('0x683')](function(){const _0x5406df=_0xa7e753;_0x117833[_0x5406df('0x1299')](function(_0x13f537){const _0x4dd753=_0x5406df;_0x2e3ca0()['includes'](_0x866df2[_0x4dd753('0x924')],_0x13f537)&&(_0x5880a8[_0x13f537]=!![]);}),_0x13baa8(_0x5880a8);})[_0xa7e753('0x130a')](function(_0x3cd18a){_0x3ec85b(_0x3cd18a);});});}function _0x4d7bef(_0x100537){return _0x46f8ec(function(_0x25e485,_0x1ebf85){const _0x3b23a3=a0_0x4e0a;_0x15a06d()?_0x25e485(!![]):_0x2ae32f[_0x3b23a3('0x22df')]['get']({'userProfileId':_0x866df2[_0x3b23a3('0x2f')]})[_0x3b23a3('0xe53')][_0x3b23a3('0x683')](function(_0x4c9be2){const _0x5ecff8=_0x3b23a3,_0x1fa19a=_0x4c9be2&&_0x4c9be2[_0x5ecff8('0xf5d')]?_0x4c9be2[_0x5ecff8('0xf5d')]:[];if(!_0x2e3ca0()['isEmpty'](_0x1fa19a)){const _0x339d15=_0x2e3ca0()[_0x5ecff8('0x25')](_0x1fa19a,function(_0x5c2e59){const _0x2364f5=_0x5ecff8;return _0x5c2e59[_0x2364f5('0x1333')];});_0x25e485(_0x2e3ca0()[_0x5ecff8('0x7a2')](_0x339d15,[_0x5ecff8('0x1b32'),_0x100537]));}else _0x25e485(![]);})[_0x3b23a3('0x130a')](function(_0x29b88e){_0x1ebf85(_0x29b88e);});});}function _0x1609cb(_0x27732b){return _0x46f8ec(function(_0x44f3d5,_0x265712){const _0x4c0b2a=a0_0x4e0a,_0xfbf7d3={};_0x15a06d()?(_0x27732b[_0x4c0b2a('0x1299')](function(_0x2330ac){_0xfbf7d3[_0x2330ac]=!![];}),_0x44f3d5(_0xfbf7d3)):_0x2ae32f[_0x4c0b2a('0x22df')][_0x4c0b2a('0x1e6e')]({'userProfileId':_0x866df2[_0x4c0b2a('0x2f')]})[_0x4c0b2a('0xe53')]['then'](function(_0x1fcd61){const _0xd57d0e=_0x4c0b2a,_0x36405b=_0x1fcd61&&_0x1fcd61[_0xd57d0e('0xf5d')]?_0x1fcd61[_0xd57d0e('0xf5d')]:[];if(!_0x2e3ca0()[_0xd57d0e('0x173f')](_0x36405b)){const _0x52f7c1=_0x2e3ca0()(_0x36405b)[_0xd57d0e('0x25')](function(_0x25aad1){const _0x215553=_0xd57d0e;return _0x25aad1['enabled']&&_0x2e3ca0()[_0x215553('0x2292')](_0x27732b,_0x25aad1[_0x215553('0x1b32')]);})[_0xd57d0e('0xea6')](function(_0xe433b3){const _0x269ea5=_0xd57d0e;return _0xe433b3[_0x269ea5('0x1b32')];})[_0xd57d0e('0x386')](function(_0x236057){const _0x2feba0=_0xd57d0e;return _0x236057[_0x2feba0('0x1b32')];})[_0xd57d0e('0x1c6b')]();_0x52f7c1[_0xd57d0e('0x1299')](function(_0x2b5ec9){_0xfbf7d3[_0x2b5ec9]=!![];}),_0x44f3d5(_0xfbf7d3);}else _0x44f3d5({});})[_0x4c0b2a('0x130a')](function(_0x2f1d9f){_0x265712(_0x2f1d9f);});});}function _0x14c396(){const _0x10ea5e=a0_0x4e0a;return _0x8c1ac9[_0x10ea5e('0x120e')][_0x10ea5e('0x2354')]||'NONE';}function _0x2701b3(_0x429997){const _0x2f113e=a0_0x4e0a;_0x8c1ac9[_0x2f113e('0x120e')][_0x2f113e('0x2354')]=_0x429997;}function _0x5ec1d9(_0x45999c){const _0x93c2c6=a0_0x4e0a;return _0x2701b3(_0x93c2c6('0x1dff')),_0x93c2c6('0x1ba3')+_0x45999c;}}const _0x130acd=_0x5df21d;_0x561fe1[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x723')];function _0x561fe1(_0x40c5ef,_0x3104a2){const _0x432ce6=_0x189033,_0x1a3071=this;function _0x175f57(_0x41e4c5){_0x40c5ef['hide'](_0x41e4c5);}_0x1a3071[_0x432ce6('0x723')]=_0x3104a2,_0x1a3071['closeDialog']=_0x175f57,_0x3104a2[_0x432ce6('0x50d')]&&(_0x1a3071[_0x432ce6('0x60a')]=_0x3104a2[_0x432ce6('0xf5d')][0x0][_0x432ce6('0x60a')]);}const _0x43331f=_0x561fe1;_0x4c27e0[_0x189033('0x14be')]=['$rootScope','$q',_0x189033('0x17e4'),'$injector',_0x189033('0x102')];function _0x4c27e0(_0x38cf68,_0x39e9bd,_0x5eba71,_0x4447ed,_0x19eceb){let _0x1ee487;return{'request':function(_0x3f6c8b){const _0x50a549=a0_0x4e0a,_0x4b2bc7=_0x5eba71[_0x50a549('0x1e6e')]('motion.token');return _0x3f6c8b[_0x50a549('0xb7d')]=_0x3f6c8b[_0x50a549('0xb7d')]||{},(![]||_0x19eceb[_0x50a549('0x1356')](_0x3f6c8b[_0x50a549('0x1284')]))&&_0x4b2bc7&&(_0x3f6c8b[_0x50a549('0xb7d')][_0x50a549('0x2156')]=_0x50a549('0x189e')+_0x4b2bc7),_0x3f6c8b;},'responseError':function(_0x3741a){const _0x22a15a=a0_0x4e0a;switch(_0x3741a[_0x22a15a('0x13ee')]){case 0x191:_0x5eba71[_0x22a15a('0x3ec')](_0x22a15a('0x555')),(_0x1ee487||(_0x1ee487=_0x4447ed[_0x22a15a('0x1e6e')]('$state')))['go'](_0x22a15a('0x8a0'));break;case 0x194:break;default:break;}return _0x39e9bd[_0x22a15a('0xfae')](_0x3741a);}};}const _0x4d193f=_0x4c27e0;_0x151f4e[_0x189033('0x14be')]=[_0x189033('0x2063')];function _0x151f4e(_0x2e7cf9){const _0x344af4={'safeCb':function(_0x505e13){const _0x45ec4e=a0_0x4e0a;return angular[_0x45ec4e('0x93f')](_0x505e13)?_0x505e13:angular[_0x45ec4e('0x1126')];},'urlParse':function(_0x58b5aa){const _0x141eaa=a0_0x4e0a,_0x53a762=document['createElement']('a');return _0x53a762[_0x141eaa('0x2767')]=_0x58b5aa,_0x53a762['host']===''&&(_0x53a762[_0x141eaa('0x2767')]=_0x53a762[_0x141eaa('0x2767')]),_0x53a762;},'isSameOrigin':function(_0x2f117d,_0x1f658f){const _0x1f846a=a0_0x4e0a;return _0x2f117d=_0x344af4[_0x1f846a('0x287e')](_0x2f117d),_0x1f658f=_0x1f658f&&[][_0x1f846a('0x746')](_0x1f658f)||[],_0x1f658f=_0x1f658f['map'](_0x344af4[_0x1f846a('0x287e')]),_0x1f658f['push'](_0x2e7cf9['location']),_0x1f658f=_0x1f658f['filter'](function(_0x4c2dd7){const _0x1d0df7=_0x1f846a,_0x5b92ed=_0x2f117d[_0x1d0df7('0x1fa8')]===_0x4c2dd7[_0x1d0df7('0x1fa8')],_0x26b2c8=_0x2f117d[_0x1d0df7('0x173e')]===_0x4c2dd7[_0x1d0df7('0x173e')],_0x5be288=_0x2f117d['port']===_0x4c2dd7[_0x1d0df7('0x4a2')]||_0x4c2dd7[_0x1d0df7('0x4a2')]===''&&(_0x2f117d['port']==='80'||_0x2f117d[_0x1d0df7('0x4a2')]===_0x1d0df7('0x173d'));return _0x5b92ed&&_0x26b2c8&&_0x5be288;}),_0x1f658f[_0x1f846a('0x1564')]>=0x1;}};return _0x344af4;}const _0x1305d9=_0x151f4e;;angular[_0x189033('0x1e26')](_0x189033('0x2177'),[])[_0x189033('0x272d')](_0x91a8a7)[_0x189033('0x11a0')](_0x5a7078)[_0x189033('0x1f97')]('Auth',_0x130acd)[_0x189033('0x1da3')](_0x189033('0x5b5'),_0x43331f)['factory']('authInterceptor',_0x4d193f)['factory']('Util',_0x1305d9);var _0x2c7e0a=_0x180212(0xca2),_0x2cd32e=_0x180212(0x1e94),_0x3e2383=_0x180212(0x1e80),_0x53c4e2=_0x180212(0x11ee),_0xf2b6ca=_0x180212(0x36e),_0xb1c959=_0x180212(0x1bdb),_0x923ec8=_0x180212(0x1c17),_0x323232=_0x180212(0x813),_0x10f6ab=_0x180212(0xdff),_0x1fd618=_0x180212(0x251),_0x4d1ab6=_0x180212(0xdf),_0x305ff2=_0x180212(0x1299),_0x45f444=_0x180212(0x177),_0x491681=_0x180212(0x573);function _0x49b17e(){const _0x23339b=_0x189033;let _0x274e52={'disableCustomScrollbars':![],'disableMdInkRippleOnMobile':!![],'disableCustomScrollbarsOnMobile':!![]};function _0x4fa8d9(_0x14a78d){const _0x1255a8=a0_0x4e0a;_0x274e52=angular[_0x1255a8('0x618')]({},_0x274e52,_0x14a78d);}function _0x4ab4db(_0x2f9eb0){if(angular['isUndefined'](_0x274e52[_0x2f9eb0]))return![];return _0x274e52[_0x2f9eb0];}function _0x14324f(_0x59612a,_0x5c4e95){_0x274e52[_0x59612a]=_0x5c4e95;}this[_0x23339b('0x1862')]=function(){const _0x2906d2={'getConfig':_0x4ab4db,'setConfig':_0x14324f};return _0x2906d2;},this['config']=_0x4fa8d9;}const _0x4caaf1=_0x49b17e;_0x547682[_0x189033('0x14be')]=['$ariaProvider','$logProvider',_0x189033('0xd5d'),_0x189033('0x18dd')];function _0x547682(_0x23fa08,_0x12ae94,_0x3e1d62,_0x5d2c35){const _0x1d8438=_0x189033;_0x12ae94[_0x1d8438('0x2436')](!![]),_0x23fa08[_0x1d8438('0x272d')]({'tabindex':![]}),_0x5d2c35[_0x1d8438('0x272d')]({'disableCustomScrollbars':![],'disableCustomScrollbarsOnMobile':!![],'disableMdInkRippleOnMobile':!![]}),_0x3e1d62[_0x1d8438('0x272d')]({'wheelPropagation':!![]});}const _0x5b355d=_0x547682;_0x81b082['$inject']=[_0x189033('0x1cc2'),'motionGenerator',_0x189033('0x59')];function _0x81b082(_0x128bb1,_0x1a5740,_0x145486){const _0x2896e3=_0x189033;_0x1a5740[_0x2896e3('0x4e1')]();if(_0x145486['getConfig']('disableMdInkRippleOnMobile')&&_0x128bb1[_0x2896e3('0xe57')]()){const _0x5e9ef0=angular[_0x2896e3('0x1fcc')]('body');_0x5e9ef0[_0x2896e3('0x244e')](_0x2896e3('0x3a1'),!![]);}_0x128bb1[_0x2896e3('0xe57')]()&&angular[_0x2896e3('0x1fcc')]('html')[_0x2896e3('0x81e')](_0x2896e3('0x141f'));const _0xe2cac=_0x128bb1[_0x2896e3('0x262b')]();if(_0xe2cac){const _0xc64207=_0xe2cac[_0x2896e3('0x47d')]+'\x20'+_0xe2cac['version']+'\x20'+_0xe2cac['os'];angular[_0x2896e3('0x1fcc')](_0x2896e3('0x84'))[_0x2896e3('0x81e')](_0xc64207);}}const _0x5dc10b=_0x81b082;_0x488120[_0x189033('0x14be')]=[_0x189033('0x2063'),'$mdDialog','Auth',_0x189033('0x17f8'),_0x189033('0x189a'),_0x189033('0x1bf2')];function _0x488120(_0x20606e,_0x5c8dc6,_0x18b566,_0x2b9529,_0x1b836a,_0x28694b){const _0x4aa988=_0x189033,_0xab31dc=this;_0xab31dc[_0x4aa988('0x11ed')]=_0x18b566['getCurrentUser'](),_0xab31dc[_0x4aa988('0x1a7e')]={'matchType':'$and','conditions':[],'fields':_0x1b836a},_0xab31dc[_0x4aa988('0x22c0')]=_0x2b9529,_0xab31dc[_0x4aa988('0x1dd2')]=_0x48d327,_0xab31dc[_0x4aa988('0xf7')]=_0x551f5e,_0xab31dc[_0x4aa988('0x1d1e')]=_0x4e6848,_0xab31dc[_0x4aa988('0xc7')]=_0xe117,_0xab31dc[_0x4aa988('0x12b0')]=_0x1603f0;function _0x48d327(){const _0x1af4eb=_0x4aa988;if(_0x28694b){const _0x393477=_0x559f4d();typeof _0x393477['advancedSearch']!==_0x1af4eb('0x1867')&&(_0xab31dc['searchOptions']=_0x2e3ca0()['merge'](_0xab31dc[_0x1af4eb('0x1a7e')],_0x393477[_0x1af4eb('0x19c9')]));}}function _0x551f5e(){const _0x409ca1=_0x4aa988,_0x339d55=_0x2e3ca0()[_0x409ca1('0x25')](_0xab31dc[_0x409ca1('0x1a7e')]['conditions'],[_0x409ca1('0x120b'),![]]);let _0x5ee127='['+_0xab31dc[_0x409ca1('0x1a7e')]['matchType']+']';const _0x17744f=[];let _0x2f17aa='';_0x2e3ca0()(_0x339d55)[_0x409ca1('0x600')](_0x409ca1('0x60a'))[_0x409ca1('0x1299')](function(_0x2d9106){const _0x48a2db=_0x409ca1,_0xe47cab=_0x2d9106[0x0],_0x54bb5b=_0x2d9106[_0x48a2db('0x1564')]>0x1?!![]:![],_0x366963=_0xe47cab[_0x48a2db('0x23a2')]['column'];if(_0x54bb5b){const _0x2d52b0=_0x2e3ca0()(_0x2d9106)[_0x48a2db('0x600')](function(_0x51f8b6){return _0x51f8b6['query']['operator'];})[_0x48a2db('0x1cc9')](function(_0x219ce5){const _0x43b489=_0x48a2db;return _0x2e3ca0()[_0x43b489('0x7cf')](_0x219ce5)['map'](function(_0x31f570){const _0x2fd18d=_0x43b489;return _0x31f570[_0x2fd18d('0x23a2')]['value'];})['flattenDeep']()[_0x43b489('0x1c6b')]();})[_0x48a2db('0x1c6b')](),_0x4d349c=[];_0x2e3ca0()[_0x48a2db('0x55e')](_0x2d52b0)[_0x48a2db('0x1299')](function(_0x5eea82){const _0x2dbdd6=_0x48a2db,_0x3fef4d=_0x2d52b0[_0x5eea82];let _0x2a2647=_0x5eea82;_0x2e3ca0()[_0x2dbdd6('0x2292')]([_0x2dbdd6('0x564'),_0x2dbdd6('0x1e4c'),_0x2dbdd6('0x1479')],_0x5eea82)?_0x2a2647+='['+_0x3fef4d+']':_0x3fef4d[_0x2dbdd6('0x1299')](function(_0x1af045){_0x2a2647+='['+_0x1af045+']';}),_0x4d349c[_0x2dbdd6('0x1fd0')](_0x2a2647);}),_0x2f17aa+=_0x366963+':='+_0x4d349c[_0x48a2db('0x1630')](':=');}else _0x2f17aa=_0x366963+':='+_0xe47cab[_0x48a2db('0x23a2')]['operator']+'['+_0xe47cab[_0x48a2db('0x23a2')][_0x48a2db('0x1c6b')]+']';_0x17744f[_0x48a2db('0x1fd0')](_0x2f17aa);}),_0x5ee127+=_0x17744f['join']('||'),_0x3aefa6(),_0x5c8dc6[_0x409ca1('0x1715')](_0x5ee127);}function _0x4e6848(){const _0x22fd90=_0x4aa988;_0xab31dc[_0x22fd90('0x1a7e')][_0x22fd90('0x27a5')]=[],_0x1082e6();}function _0xe117(){const _0x2419ca=_0x4aa988;_0x3aefa6(),_0x5c8dc6[_0x2419ca('0x1715')]();}function _0x1603f0(){const _0x1a476a=_0x4aa988;_0x5c8dc6[_0x1a476a('0x1715')](![]);}function _0x559f4d(){const _0xa8e47e=_0x4aa988,_0x357060=_0x20606e['localStorage']['getItem'](_0xa8e47e('0x24d8')+_0x28694b+':'+_0xab31dc['currentUser']['id']);return _0x357060?JSON[_0xa8e47e('0x1f34')](_0x357060):{};}function _0x2f94e8(_0x5189da){const _0x1627fe=_0x4aa988;_0x20606e['localStorage'][_0x1627fe('0x15d')](_0x1627fe('0x24d8')+_0x28694b+':'+_0xab31dc[_0x1627fe('0x11ed')]['id'],JSON['stringify'](_0x5189da));}function _0x3aefa6(){const _0x1fa0d9=_0x4aa988;if(_0x28694b){const _0x196fdc=_0x559f4d();_0x196fdc[_0x1fa0d9('0x19c9')]=_0x2e3ca0()['omit'](_0xab31dc['searchOptions'],_0x1fa0d9('0x189a')),_0x2f94e8(_0x196fdc);}}function _0x1082e6(){const _0x29b38b=_0x4aa988;if(_0x28694b){const _0x51d51b=_0x559f4d();delete _0x51d51b[_0x29b38b('0x19c9')];if(_0x51d51b[_0x29b38b('0x23a2')])delete _0x51d51b[_0x29b38b('0x23a2')]['search'];_0x2f94e8(_0x51d51b);}}}const _0x4d8714=_0x488120;_0xa541eb[_0x189033('0x14be')]=[_0x189033('0x2f9')];function _0xa541eb(_0x39a498){return{'restrict':'A','link':function(_0x339b6b,_0x58615c,_0x57b434){const _0x23aa36=a0_0x4e0a;_0x339b6b[_0x23aa36('0x186d')](_0x57b434['focusOn'],function(_0x3c9787){_0x39a498(function(){const _0x190744=a0_0x4e0a;_0x3c9787?_0x58615c[0x0][_0x190744('0x119c')]():_0x58615c[0x0][_0x190744('0x18e2')]();});});}};}const _0x5ab932=_0xa541eb;var _0x679fc7=_0x180212(0x1433),_0xb843ab=_0x180212['n'](_0x679fc7);_0x48e08d[_0x189033('0x14be')]=['$timeout','$q','$interpolate'];function _0x48e08d(_0x446ac2,_0x38a132,_0x3fe722){return{'restrict':'E','compile':function(_0x125fe4,_0x52a327){const _0x4bfb49=a0_0x4e0a;let _0x3c05d8;return!_0x52a327[_0x4bfb49('0x1245')]&&(_0x3c05d8=_0x125fe4[_0x4bfb49('0x84')](),_0x125fe4[_0x4bfb49('0xb18')]()),function(_0x31ebf9,_0x3161cc,_0x12138b){const _0x19644d=_0x4bfb49;_0x12138b[_0x19644d('0x1245')]&&(_0x3c05d8=_0x31ebf9[_0x19644d('0x1a5a')](_0x12138b[_0x19644d('0x1245')]));const _0x33a3c1=_0x31ebf9['$eval'](_0x12138b[_0x19644d('0x79f')]);_0x38a132[_0x19644d('0x15ba')](_0x3c05d8)[_0x19644d('0x683')](function(_0x16663c){const _0x25c75d=_0x19644d;if(_0x16663c){_0x33a3c1&&(_0x16663c=_0x3fe722(_0x16663c)(_0x31ebf9));const _0x1fd534=angular[_0x25c75d('0x1fcc')]('
');_0x3161cc[_0x25c75d('0x22d6')](_0x1fd534),_0x446ac2(function(){_0x1263f8(_0x16663c,_0x1fd534);},0x22,![]);}});function _0x1263f8(_0x5b7d8d,_0x1ce7d7){const _0xbb8dbe=_0x19644d,_0x4442ba=_0x1ce7d7['find'](_0xbb8dbe('0x1245'));let _0x371f3a=_0x5b7d8d[_0xbb8dbe('0x1fc5')]('\x0a');_0x371f3a=_0x371f3a['filter'](function(_0x2fbe12){const _0x4dcb9a=_0xbb8dbe;return _0x2fbe12[_0x4dcb9a('0x12ae')]()[_0x4dcb9a('0x1564')];});const _0x2ad7f4=_0x371f3a[0x0][_0xbb8dbe('0xbb9')](/^\s*/)[0x0],_0x5207c8=new RegExp('^'+_0x2ad7f4);_0x371f3a=_0x371f3a[_0xbb8dbe('0x386')](function(_0x14209a){const _0x2b8a67=_0xbb8dbe;return _0x14209a[_0x2b8a67('0x1725')](_0x5207c8,'')[_0x2b8a67('0x1725')](/\s+$/,'');});const _0x5c4e54=_0xb843ab()[_0xbb8dbe('0x15e6')](_0x12138b['language']||_0x12138b['lang'],_0x371f3a['join']('\x0a'),!![]);_0x5c4e54['value']=_0x5c4e54[_0xbb8dbe('0x1c6b')][_0xbb8dbe('0x1725')](/=""<\/span>/gi,'')[_0xbb8dbe('0x1725')](_0xbb8dbe('0x1827'),'')[_0xbb8dbe('0x1725')](_0xbb8dbe('0x10e2'),''),_0x4442ba['append'](_0x5c4e54[_0xbb8dbe('0x1c6b')])[_0xbb8dbe('0x81e')](_0xbb8dbe('0x15e6'));}};}};}const _0x248533=_0x48e08d,_0x546dc3=_0x180212['p']+'src/js/modules/core/directives/ms-advanced-search/ms-advanced-search.html/ms-advanced-search.html';_0x468e66[_0x189033('0x14be')]=['$translate','$q',_0x189033('0x56b'),_0x189033('0x1d70')];function _0x333992(){return{'restrict':'E','scope':{'options':'=','clearFilter':'&'},'controller':_0x468e66,'controllerAs':'vm','bindToController':!![],'templateUrl':_0x546dc3};}function _0x468e66(_0x3e5ad7,_0x5a1905,_0x5b15c2,_0x482d80){const _0x48a943=_0x189033,_0x1a5b08=this;_0x1a5b08['availableOperators']=[{'type':_0x48a943('0x393'),'symbol':'=','translate':'EQUALS','excludeFrom':[_0x48a943('0xf6c')]},{'type':'$ne','symbol':'≠','translate':'IS_NOT_EQUAL','excludeFrom':[_0x48a943('0xf6c')]},{'type':_0x48a943('0x1e4c'),'symbol':'∈','translate':'IS_AMONG','applyTo':[_0x48a943('0xf6c')]},{'type':_0x48a943('0x1479'),'symbol':'∉','translate':_0x48a943('0xc37'),'applyTo':[_0x48a943('0xf6c')]},{'type':_0x48a943('0xe55'),'symbol':'⊃','translate':'CONTAINS','applyTo':[_0x48a943('0x1bcd')]},{'type':_0x48a943('0xd0'),'symbol':_0x48a943('0x2223'),'translate':_0x48a943('0x2578'),'applyTo':[_0x48a943('0x1bcd')]},{'type':_0x48a943('0x5bc'),'symbol':_0x48a943('0xdac'),'translate':'ENDS_WITH','applyTo':[_0x48a943('0x1bcd')]},{'type':'$lt','symbol':'<','translate':_0x48a943('0x1179'),'applyTo':[_0x48a943('0x270e'),_0x48a943('0x121f')]},{'type':'$gt','symbol':'>','translate':_0x48a943('0x18f9'),'applyTo':[_0x48a943('0x270e'),_0x48a943('0x121f')]},{'type':_0x48a943('0x27ee'),'symbol':'≤','translate':_0x48a943('0x24c7'),'applyTo':[_0x48a943('0x270e'),_0x48a943('0x121f')]},{'type':'$gte','symbol':'≥','translate':_0x48a943('0x20bf'),'applyTo':[_0x48a943('0x270e'),_0x48a943('0x121f')]},{'type':_0x48a943('0x564'),'symbol':'≬','translate':'IS_BETWEEN','applyTo':[_0x48a943('0x270e'),'number']}],_0x1a5b08['operators']=_0x1a5b08[_0x48a943('0x1f69')],_0x1a5b08[_0x48a943('0x2532')]=_0x21c7bc,_0x1a5b08['editCondition']=_0x2852d2,_0x1a5b08[_0x48a943('0x1f0b')]=_0x3af5f6,_0x1a5b08[_0x48a943('0x2349')]=_0x252613,_0x1a5b08[_0x48a943('0x51f')]=_0x431932,_0x1a5b08[_0x48a943('0x61e')]=_0x560872,_0x1a5b08[_0x48a943('0x1e81')]=_0x12754a,_0x1a5b08[_0x48a943('0x995')]=_0x503f06,_0x1a5b08[_0x48a943('0x219d')]=_0x579d0b,_0x1a5b08['onValueChange']=_0x3c4670,_0x1a5b08[_0x48a943('0x103a')]=_0x1f50c7,_0x1a5b08[_0x48a943('0x1d57')]=_0x452095;function _0x503f06(){const _0x208466=_0x48a943;_0x1a5b08[_0x208466('0x1c6b')]=undefined,_0x1a5b08[_0x208466('0x2572')]=undefined,_0x1a5b08[_0x208466('0x282c')]=undefined,_0x1a5b08[_0x208466('0x13d3')]=![],_0x160948(),_0x1a5b08[_0x208466('0x1c64')]=_0x1a5b08[_0x208466('0x1f69')][_0x208466('0x1564')]===0x1?!![]:![];if(!_0x1a5b08[_0x208466('0x1c64')])_0x1a5b08[_0x208466('0x7c7')]=undefined;}function _0x579d0b(_0x143d9e){const _0x1e42e1=_0x48a943;_0x1a5b08[_0x1e42e1('0x1ea0')]=!![],_0x1a5b08['selectedOperator']&&(_0x143d9e?_0x143d9e[_0x1e42e1('0x161a')]?_0x2e3ca0()['difference'](_0x1a5b08[_0x1e42e1('0x7c7')]['applyTo'],_0x143d9e['applyTo'])[_0x1e42e1('0x1564')]>0x0&&(_0x1a5b08[_0x1e42e1('0x1c6b')]=null):_0x1a5b08[_0x1e42e1('0x7c7')][_0x1e42e1('0x161a')]&&(_0x1a5b08['value']=null):_0x1a5b08['value']=null,_0x1a5b08[_0x1e42e1('0x7c7')][_0x1e42e1('0xcf0')]!='between'&&(_0x1a5b08['endRangeValue']=null),_0x1a5b08[_0x1e42e1('0x176b')]['options']&&!_0x2e3ca0()['isEmpty'](_0x1a5b08[_0x1e42e1('0x176b')][_0x1e42e1('0x158e')][_0x1e42e1('0xf16')])&&(_0x1a5b08['selectedOperator']['isExtra']=_0x2e3ca0()[_0x1e42e1('0x7a2')](_0x1a5b08['selectedField'][_0x1e42e1('0x158e')][_0x1e42e1('0xf16')],function(_0x41f63b){const _0x326b8f=_0x1e42e1;return _0x41f63b===_0x1a5b08[_0x326b8f('0x7c7')][_0x326b8f('0xcf0')];}))),_0x856f54();}function _0x3c4670(){const _0x2b3c42=_0x48a943;if(_0x1a5b08['selectedOperator']&&_0x1a5b08[_0x2b3c42('0x7c7')][_0x2b3c42('0xcf0')]===_0x2b3c42('0x564')){if(_0x1a5b08[_0x2b3c42('0x176b')]['type']===_0x2b3c42('0x121f'))_0x1f50c7();else _0x1a5b08[_0x2b3c42('0x176b')][_0x2b3c42('0xcf0')]===_0x2b3c42('0x270e')&&(_0x1a5b08[_0x2b3c42('0x1d85')]=_0x1aaf93()(_0x1a5b08[_0x2b3c42('0x1c6b')])[_0x2b3c42('0x23c6')](0x1,_0x2b3c42('0x1efa')),_0x856f54());}else _0x856f54();}function _0x160948(){const _0x38a1ef=_0x48a943,_0x2a3630=_0x1a5b08['selectedField']['options']&&!_0x2e3ca0()[_0x38a1ef('0x173f')](_0x1a5b08[_0x38a1ef('0x176b')][_0x38a1ef('0x158e')][_0x38a1ef('0xf16')]),_0x2cc5d5=_0x1a5b08['selectedField'][_0x38a1ef('0x158e')]&&!_0x2e3ca0()[_0x38a1ef('0x173f')](_0x1a5b08['selectedField'][_0x38a1ef('0x158e')][_0x38a1ef('0x2818')]);_0x1a5b08[_0x38a1ef('0x1f69')]=_0x2e3ca0()[_0x38a1ef('0x25')](_0x1a5b08[_0x38a1ef('0x10e5')],function(_0x219fe1){const _0x4987e6=_0x38a1ef,_0xe6ec6=!_0x219fe1[_0x4987e6('0x161a')]||_0x2e3ca0()[_0x4987e6('0x2292')](_0x219fe1[_0x4987e6('0x161a')],_0x1a5b08[_0x4987e6('0x176b')][_0x4987e6('0xcf0')]);_0x219fe1['isExtra']=_0x2a3630&&_0x2e3ca0()[_0x4987e6('0x7a2')](_0x1a5b08[_0x4987e6('0x176b')][_0x4987e6('0x158e')][_0x4987e6('0xf16')],function(_0x583feb){return _0x583feb===_0x219fe1['type'];});const _0x58d4b0=_0x2e3ca0()[_0x4987e6('0x2292')](_0x219fe1[_0x4987e6('0x274a')],_0x1a5b08[_0x4987e6('0x176b')]['type'])||_0x2cc5d5&&_0x2e3ca0()[_0x4987e6('0x2292')](_0x1a5b08['selectedField'][_0x4987e6('0x158e')][_0x4987e6('0x2818')],_0x219fe1['type']);if((_0xe6ec6||_0x219fe1[_0x4987e6('0x1a43')])&&!_0x58d4b0)return _0x219fe1;});}function _0x12754a(){const _0x38c369=_0x48a943,_0x5c3d9e=angular['copy'](_0x1a5b08[_0x38c369('0x176b')][_0x38c369('0x158e')]['route']);if(_0x1a5b08[_0x38c369('0x176b')]['type']===_0x38c369('0xeb'))for(let _0x5c7e1b=0x0;_0x5c7e1bNumber(_0x1a5b08[_0x71659('0x1c6b')])?!![]:![]:_0x1a5b08['isValidRange']=!![];else _0x1a5b08['selectedField'][_0x71659('0xcf0')]===_0x71659('0x270e')&&(_0x1a5b08[_0x71659('0xf94')]=_0x1aaf93()(_0x1a5b08['endRangeValue'])[_0x71659('0x1315')](0x1,_0x71659('0x1efa')),_0x1a5b08[_0x71659('0x1ea0')]=!![]);_0x856f54();}function _0x21c7bc(){const _0x3e5476=_0x48a943,_0x27d6e5=_0x38b1eb();_0x1a5b08['options'][_0x3e5476('0x27a5')]['push'](_0x27d6e5),_0x5b5295();}function _0x2852d2(_0x5d2e8a){const _0x11aa6d=_0x48a943;_0x1a5b08[_0x11aa6d('0x1ff6')]=_0x5d2e8a,_0x1a5b08[_0x11aa6d('0x1ff6')][_0x11aa6d('0xd8e')]='md-amber-200-bg',_0x1a5b08[_0x11aa6d('0x176b')]=_0x2e3ca0()[_0x11aa6d('0x1c07')](_0x1a5b08[_0x11aa6d('0x158e')][_0x11aa6d('0x189a')],[_0x11aa6d('0x60a'),_0x1a5b08[_0x11aa6d('0x1ff6')][_0x11aa6d('0x60a')]]),_0x160948(),_0x1a5b08[_0x11aa6d('0x7c7')]=_0x2e3ca0()['find'](_0x1a5b08[_0x11aa6d('0x1f69')],['type',_0x1a5b08[_0x11aa6d('0x1ff6')][_0x11aa6d('0x23a2')]['operator']]),_0x1a5b08[_0x11aa6d('0x176b')][_0x11aa6d('0xcf0')]===_0x11aa6d('0x270e')&&typeof _0x1a5b08[_0x11aa6d('0x1ff6')]['value']===_0x11aa6d('0xc06')?(_0x1a5b08['value']=new Date(_0x1a5b08[_0x11aa6d('0x1ff6')][_0x11aa6d('0x1c6b')]),_0x1a5b08[_0x11aa6d('0x1d85')]=_0x1aaf93()(_0x1a5b08[_0x11aa6d('0x1c6b')])[_0x11aa6d('0x23c6')](0x1,_0x11aa6d('0x1efa')),_0x1a5b08[_0x11aa6d('0x2572')]=_0x1a5b08['pendingCondition'][_0x11aa6d('0x1d80')]?new Date(_0x1a5b08['pendingCondition'][_0x11aa6d('0x1d80')]):undefined):(_0x1a5b08[_0x11aa6d('0x1c6b')]=_0x1a5b08[_0x11aa6d('0x1ff6')]['value'],_0x1a5b08[_0x11aa6d('0x2572')]=_0x1a5b08[_0x11aa6d('0x1ff6')]['endValue']),_0x1a5b08[_0x11aa6d('0x1ea0')]=!![],_0x1a5b08[_0x11aa6d('0x13d3')]=!![];}function _0x3af5f6(){const _0x1e9981=_0x48a943,_0x24c09d=_0x38b1eb(),_0x43b9c7=_0x2e3ca0()[_0x1e9981('0x1ce4')](_0x1a5b08[_0x1e9981('0x158e')][_0x1e9981('0x27a5')],_0x1e9981('0xd8e'));_0x1a5b08[_0x1e9981('0x158e')][_0x1e9981('0x27a5')]['splice'](_0x43b9c7,0x1,_0x24c09d),_0x5b5295(),_0x1a5b08[_0x1e9981('0x1ff6')][_0x1e9981('0xd8e')]=null,_0x1a5b08[_0x1e9981('0x1ff6')]=undefined;}function _0x252613(){const _0x744099=_0x48a943;_0x1a5b08[_0x744099('0x1ff6')][_0x744099('0xd8e')]=null,_0x1a5b08[_0x744099('0x1ff6')]=undefined;}function _0x431932(_0x491fdd){const _0x3f8deb=_0x48a943;_0x491fdd[_0x3f8deb('0xd8e')]=_0x491fdd[_0x3f8deb('0x120b')]?undefined:_0x3f8deb('0x19a0'),_0x491fdd['disabled']=!_0x491fdd['disabled'];}function _0x560872(){const _0x36ba96=_0x48a943;if(_0x2e3ca0()[_0x36ba96('0x173f')](_0x1a5b08[_0x36ba96('0x158e')]['conditions']))_0x1a5b08[_0x36ba96('0x1528')]();}function _0x452095(){const _0x30adb6=_0x48a943;_0x1a5b08[_0x30adb6('0x1ff6')]?_0x3af5f6():_0x21c7bc();}function _0x38b1eb(){const _0x45600c=_0x48a943;return{'name':_0x1a5b08[_0x45600c('0x176b')][_0x45600c('0x60a')],'operator':_0x3e5ad7[_0x45600c('0x2728')](_0x45600c('0x2779')+_0x1a5b08[_0x45600c('0x7c7')][_0x45600c('0x14ab')]),'value':_0x1a5b08[_0x45600c('0x1c6b')],'endValue':_0x1a5b08[_0x45600c('0x2572')],'displayValue':_0x5d9e93(_0x1a5b08['value']),'displayEndValue':_0x5d9e93(_0x1a5b08[_0x45600c('0x2572')]),'query':{'column':_0x1a5b08[_0x45600c('0x176b')][_0x45600c('0x2008')],'operator':_0x1a5b08[_0x45600c('0x7c7')]['type'],'value':_0x26c8ad()},'disabled':![]};}function _0x5d9e93(_0x77cec0){const _0x570713=_0x48a943;let _0x104274;if(!_0x77cec0)return undefined;switch(_0x1a5b08['selectedField'][_0x570713('0xcf0')]){case _0x570713('0x270e'):_0x104274=_0x1aaf93()(_0x77cec0)[_0x570713('0x26dd')](_0x570713('0x2d'));break;case _0x570713('0xf6c'):{const _0x23eb54=_0x2e3ca0()[_0x570713('0x386')](_0x77cec0,function(_0x196ef3){const _0x2c37ae=_0x570713;return _0x196ef3[_0x2c37ae('0x60a')];});_0x104274=_0x1a5b08['selectedOperator'][_0x570713('0xcf0')]==='$eq'?_0x23eb54['join']('\x20or\x20'):_0x23eb54['join']('\x20and\x20');}break;case _0x570713('0xb31'):_0x104274=_0x77cec0[_0x570713('0x60a')];break;case _0x570713('0xeb'):_0x104274=_0x1a5b08[_0x570713('0x7c7')][_0x570713('0x1a43')]?_0x77cec0:_0x77cec0[_0x570713('0x792')];break;default:_0x104274=_0x77cec0;break;}return _0x104274;}function _0x26c8ad(){const _0x125eb6=_0x48a943,_0x38bd34=_0x1a5b08[_0x125eb6('0x1c6b')],_0x532469=_0x1a5b08[_0x125eb6('0x2572')];let _0x1cb0c0;switch(_0x1a5b08[_0x125eb6('0x176b')]['type']){case _0x125eb6('0x270e'):{const _0x57449e=_0x1aaf93()(_0x38bd34)[_0x125eb6('0xb11')](0x0,!![])[_0x125eb6('0x26dd')](_0x125eb6('0x2d'));if(_0x1a5b08[_0x125eb6('0x7c7')][_0x125eb6('0xcf0')]===_0x125eb6('0x564')){const _0x409508=_0x1aaf93()(_0x532469)[_0x125eb6('0xb11')](0x0,!![])[_0x125eb6('0x26dd')]('YYYY-MM-DD');_0x1cb0c0=[_0x57449e,_0x409508];}else _0x1cb0c0=_0x57449e;}break;case _0x125eb6('0x121f'):_0x1cb0c0=_0x1a5b08['selectedOperator'][_0x125eb6('0xcf0')]===_0x125eb6('0x564')?[_0x38bd34,_0x532469]:_0x38bd34;break;case'multiselect':{const _0x13882b=_0x1a5b08[_0x125eb6('0x176b')][_0x125eb6('0x158e')][_0x125eb6('0x2013')]||'id';_0x1cb0c0=_0x2e3ca0()[_0x125eb6('0x386')](_0x38bd34,_0x13882b);}break;case _0x125eb6('0xb31'):_0x1cb0c0=_0x38bd34['id'];break;case _0x125eb6('0xeb'):_0x1cb0c0=_0x1a5b08[_0x125eb6('0x7c7')][_0x125eb6('0x1a43')]?_0x38bd34:_0x38bd34['id'];break;default:_0x1cb0c0=_0x38bd34;break;}return _0x1cb0c0;}function _0x5b5295(){const _0x3d6ea4=_0x48a943;_0x1a5b08[_0x3d6ea4('0x1c6b')]=null,_0x1a5b08['endRangeValue']=null,_0x1a5b08[_0x3d6ea4('0x1d85')]=null,_0x1a5b08[_0x3d6ea4('0xf94')]=null,_0x1a5b08[_0x3d6ea4('0x13d3')]=![];}}const _0x541a86=_0x333992;function _0x2619ae(){const _0x3110ea=_0x189033;return{'restrict':'E','scope':{'templatePath':_0x3110ea('0xa2f'),'card':_0x3110ea('0xa11'),'vm':_0x3110ea('0xa14')},'template':_0x3110ea('0x1b6a'),'compile':function(_0x50dc2e){const _0x196c68=_0x3110ea;return _0x50dc2e[_0x196c68('0x81e')]('ms-card'),function _0x517354(_0x191f5f,_0x123401){function _0x1b37e9(){const _0x29c93e=a0_0x4e0a;_0x191f5f[_0x29c93e('0x1b45')](_0x29c93e('0x14f0'),_0x123401);}_0x191f5f['cardTemplateLoaded']=_0x1b37e9;};}};}const _0x4acef8=_0x2619ae;;function _0x26954e(){return{'restrict':'A','link':function(_0x1b8f78,_0x3f6395,_0x2da700){const _0x123411=a0_0x4e0a;_0x2da700['$observe'](_0x123411('0x661'),function(_0x44769d){const _0xc8973d=_0x123411,_0x2dbbc8=_0x3f6395[_0xc8973d('0x2361')]()[_0xc8973d('0x2361')]();!_0x2dbbc8[_0xc8973d('0x1633')]('md-background-bg\x20md-hue-3')&&_0x2dbbc8['addClass'](_0xc8973d('0x2304'));if(!_0x2e3ca0()[_0xc8973d('0x173f')](_0x44769d))_0x2dbbc8[_0xc8973d('0x81e')](_0x44769d);else{const _0x443d10=_0x2dbbc8[0x0]['className'][_0xc8973d('0x1fc5')]('\x20'),_0x283e8e=_0x443d10[_0xc8973d('0x824')]('md-hue-3');_0x443d10[_0xc8973d('0x1564')]=_0x283e8e+0x1,_0x2dbbc8[0x0]['className']=_0x443d10[_0xc8973d('0x1630')]('\x20');}});}};}const _0x4b058a=_0x26954e,_0xc7e11b=_0x180212['p']+_0x189033('0x478'),_0x445657=_0x180212['p']+_0x189033('0x8ad');;function _0x5eddeb(){const _0x1f3457=_0x189033;return{'restrict':'E','scope':{'type':'=','disabled':'=','target':'=','prefix':'=','license':'='},'controller':['$scope',_0x1f3457('0x1b'),_0x1f3457('0x20a3'),'$translate',_0x1f3457('0x16ea'),_0x1f3457('0x1e48'),_0x1f3457('0xba1'),'toasty',_0x1f3457('0x56b'),function(_0x23272a,_0x459b0c,_0x21dd26,_0x4a9d87,_0x1f2dbd,_0xb53905,_0x417472,_0x594ab6,_0x1f6341){const _0xef14e6=_0x1f3457;_0x23272a[_0xef14e6('0x11ed')]=_0x417472['getCurrentUser'](),_0x23272a[_0xef14e6('0x1c39')]=function(){const _0x20dc21=_0xef14e6;return _0x23272a[_0x20dc21('0x568')]&&_0x23272a[_0x20dc21('0x568')]['indexOf']('@')<0x0&&_0x23272a[_0x20dc21('0x568')]!=_0x23272a['currentUser']['internal']&&_0x23272a[_0x20dc21('0x568')]!=_0x23272a['currentUser'][_0x20dc21('0x60a')]&&(_0x23272a[_0x20dc21('0x11ed')]['showWebBar']==0x0&&_0x23272a[_0x20dc21('0x11ed')]['phoneBarRemoteControl']||_0x23272a['currentUser']['showWebBar']==0x2&&_0x23272a[_0x20dc21('0xace')][_0x20dc21('0xd04')])&&!_0x23272a[_0x20dc21('0x120b')];};function _0x1182eb(_0x24e5b9){const _0x31136d=_0xef14e6;return _0x1f6341[_0x31136d('0xc96')][_0x31136d('0xa64')]({'id':_0x23272a[_0x31136d('0x11ed')]['id']})['$promise'][_0x31136d('0x683')](function(_0x4c6641){const _0x316c93=_0x31136d;if(_0x4c6641[_0x316c93('0x50d')])return _0xb53905[_0x316c93('0x1d4')]({'controller':_0x316c93('0x15fb'),'controllerAs':'vm','templateUrl':_0x445657,'parent':angular[_0x316c93('0x1fcc')](_0x1f2dbd[_0x316c93('0x18e5')]),'clickOutsideToClose':!![],'locals':{'prefixes':_0x4c6641,'required':_0x23272a[_0x316c93('0x11ed')][_0x316c93('0x2758')]}});})['then'](function(_0x5dd46e){const _0x53ff21=_0x31136d;if(!_0x23272a[_0x53ff21('0x11ed')]['phoneBarPrefixRequired']){if(_0x5dd46e&&_0x5dd46e!==-0x1)_0x2f78c9(_0x5dd46e+_0x24e5b9);else!_0x5dd46e&&_0x2f78c9(_0x24e5b9);}else _0x5dd46e&&_0x5dd46e!==-0x1&&_0x2f78c9(_0x5dd46e+_0x24e5b9);});}function _0x2f78c9(_0x156338){const _0x599eac=_0xef14e6;switch(_0x23272a[_0x599eac('0x11ed')][_0x599eac('0xf8e')]){case 0x0:return _0x36e92e(_0x599eac('0x712')+(_0x23272a[_0x599eac('0x11ed')][_0x599eac('0x1e01')]||'9888')+'/api/originate/'+_0x3b5571(_0x156338));case 0x2:return _0x459b0c[_0x599eac('0x5ed')]('webrtc::call',{'target':_0x3b5571(_0x156338)});default:break;}}_0x23272a[_0xef14e6('0x164f')]=function(_0x3788f3){const _0x4a4a31=_0xef14e6;return _0x23272a[_0x4a4a31('0x11ed')][_0x4a4a31('0xf8e')]!==0x2?_0x1182eb(_0x3788f3):_0x2f78c9(_0x3788f3);},_0x23272a[_0xef14e6('0x1011')]=function(_0x469fed){const _0x2777da=_0xef14e6;switch(_0x23272a[_0x2777da('0x11ed')][_0x2777da('0xf8e')]){case 0x0:return _0x36e92e(_0x2777da('0x712')+(_0x23272a[_0x2777da('0x11ed')]['phoneBarRemoteControlPort']||'9888')+'/api/transfer?number='+_0x3b5571(_0x469fed));case 0x2:_0x459b0c[_0x2777da('0x5ed')](_0x2777da('0x2424'),{'target':_0x3b5571(_0x469fed)});break;default:break;}};function _0x3b5571(_0x4be884){const _0x17728b=_0xef14e6;return!_0x2e3ca0()['isNil'](_0x4be884)?_0x4be884[_0x17728b('0x1725')](/[^\w.+#*-]+/g,''):'';}function _0x36e92e(_0x5db16f){const _0xd6f8e3=_0xef14e6;return _0x21dd26[_0xd6f8e3('0x1e6e')](_0x5db16f)['success'](function(){const _0x257725=_0xd6f8e3;_0x594ab6[_0x257725('0x53')]({'title':'Successful\x20call','msg':_0x257725('0x20fc')});})[_0xd6f8e3('0x52a')](function(){const _0x4591d8=_0xd6f8e3;_0x594ab6[_0x4591d8('0x52a')]({'title':_0x4591d8('0x1035'),'msg':_0x4a9d87['instant'](_0x4591d8('0x697'))});});}}],'templateUrl':_0xc7e11b};}const _0x49351f=_0x5eddeb;_0x423f11[_0x189033('0x14be')]=[_0x189033('0x21dc')];function _0x52b50f(){const _0x4d7cbf=_0x189033;_0x4ce278[_0x4d7cbf('0x14be')]=['configuration'];const _0xbe26d0=this;let _0x207bc7={'formatter':function(_0x35a113){if(!_0x35a113)return'';return _0x35a113===''?_0x35a113:new Date(_0x35a113);},'parser':function(_0x43809a){const _0x2216fc=_0x4d7cbf;if(!_0x43809a)return'';return _0x1aaf93()(_0x43809a)['add'](_0x1aaf93()(_0x43809a)[_0x2216fc('0xb11')](),'m')[_0x2216fc('0xc70')]();}};function _0x4ce278(_0x22fe37){_0x207bc7=angular['extend']({},_0x207bc7,_0x22fe37);}_0xbe26d0[_0x4d7cbf('0x272d')]=_0x4ce278,_0xbe26d0[_0x4d7cbf('0x1862')]=function(){return _0x207bc7;};}function _0x423f11(_0x3d8899){const _0x1da6d7=_0x189033;return{'require':_0x1da6d7('0x1f60'),'priority':0x1,'link':function(_0x3827f1,_0x2cfab5,_0xbffd2a,_0x443144){const _0x40cc4a=_0x1da6d7;_0x443144[_0x40cc4a('0x13a5')]['push'](_0x3d8899[_0x40cc4a('0x1810')]),_0x443144['$parsers'][_0x40cc4a('0x1fd0')](_0x3d8899[_0x40cc4a('0x2343')]);}};}_0x3ff82d['$inject']=[_0x189033('0x56b')];function _0x3ff82d(_0x28bb34){return{'restrict':'E','scope':{'id':'=','model':'=','element':'=','title':'=','path':'='},'replace':!![],'link':function(_0x11071e,_0x3b8e07){const _0x5c9054=a0_0x4e0a;let _0x3505c5=![];const _0x2e53b5={};_0x2e53b5['id']=_0x11071e['id'];!_0x2e3ca0()['isNil'](_0x11071e[_0x5c9054('0x210f')])&&(_0x2e53b5['path']=_0x11071e['path']);const _0x310437=document[_0x5c9054('0x1ffa')](_0x11071e[_0x5c9054('0x1fcc')]);_0x310437[_0x5c9054('0x130f')](_0x5c9054('0x257d'),'none'),_0x310437[_0x5c9054('0x130f')](_0x5c9054('0x2695'),'true'),_0x11071e[_0x5c9054('0x1fcc')]===_0x5c9054('0x9b5')&&_0x310437['setAttribute'](_0x5c9054('0xd8e'),'width:\x20265px;'),_0x11071e[_0x5c9054('0x1fcc')]===_0x5c9054('0x12a3')&&_0x310437[_0x5c9054('0x130f')](_0x5c9054('0xd8e'),_0x5c9054('0x1b6e')),_0x310437[_0x5c9054('0x130f')](_0x5c9054('0xf28'),_0x11071e['title']),_0x310437[_0x5c9054('0x130f')]('src','\x20'),_0x310437[_0x5c9054('0x2211')]=function(_0x355094){const _0x2b01de=_0x5c9054;!_0x3505c5&&(_0x3505c5=!![],_0x355094[_0x2b01de('0x1706')](),_0x28bb34[_0x11071e[_0x2b01de('0x2437')]]['download'](_0x2e53b5)['$promise'][_0x2b01de('0x683')](function(_0x1b3bd4){const _0x191420=_0x2b01de,_0x2c164e=[_0x1b3bd4[_0x191420('0x1fb3')]],_0x4bee2e=new Blob(_0x2c164e,{'type':_0x1b3bd4[_0x191420('0xcf0')]});_0x310437[_0x191420('0x130f')](_0x191420('0xcf0'),_0x1b3bd4[_0x191420('0xcf0')]),_0x310437[_0x191420('0x130f')](_0x191420('0x262a'),URL[_0x191420('0x2820')](_0x4bee2e)),_0x310437['play']();})[_0x2b01de('0x130a')](function(_0x1797bd){const _0x15401a=_0x2b01de;console[_0x15401a('0x52a')](_0x1797bd);}));},_0x3b8e07[_0x5c9054('0x22d6')](_0x310437);}};}const _0x53a581=_0x3ff82d,_0x4f4502=_0x180212['p']+'src/js/modules/core/directives/ms-dual-multiselect/ms-dual-multiselect.html/ms-dual-multiselect.html';;function _0x3ed140(){const _0x4f5224=_0x189033;return{'restrict':'E','scope':{'options':'='},'controller':[_0x4f5224('0x7a5'),function(_0x441a0f){const _0x48e03f=_0x4f5224;_0x441a0f['canTransfer']=function(_0x406dc0,_0x10b074,_0x214c98){const _0x358533=a0_0x4e0a;if(_0x10b074[_0x358533('0x50e')])return;else{if(typeof _0x406dc0['isValid']!=='undefined'&&_0x406dc0[_0x358533('0x24f4')])return _0x214c98?_0x441a0f[_0x358533('0x1011')](_0x10b074[_0x358533('0x1378')],_0x10b074[_0x358533('0x1996')],_0x10b074['selectedItems'][_0x358533('0x824')](_0x406dc0),_0x214c98):_0x441a0f['transfer'](_0x10b074[_0x358533('0x1996')],_0x10b074['selectedItems'],_0x10b074['items'][_0x358533('0x824')](_0x406dc0),_0x214c98);}},_0x441a0f[_0x48e03f('0x1011')]=function(_0x4455a2,_0x4ccf31,_0x20b76e,_0x33de34){const _0x19cc94=_0x48e03f;let _0xad0e80=[];if(_0x20b76e>=0x0)_0xad0e80[_0x19cc94('0x1fd0')](_0x4455a2[_0x20b76e]),_0x4ccf31[_0x19cc94('0x1fd0')](_0x4455a2[_0x20b76e]),_0x4455a2[_0x19cc94('0x2040')](_0x20b76e,0x1);else{for(let _0x2ec0b4=0x0;_0x2ec0b4<_0x4455a2[_0x19cc94('0x1564')];_0x2ec0b4++){typeof _0x4455a2[_0x2ec0b4][_0x19cc94('0x24f4')]!==_0x19cc94('0x1867')&&_0x4455a2[_0x2ec0b4][_0x19cc94('0x24f4')]&&_0x4ccf31['push'](_0x4455a2[_0x2ec0b4]);}for(let _0x35d091=_0x4455a2['length']-0x1;_0x35d091>=0x0;_0x35d091--){_0x4455a2[_0x35d091][_0x19cc94('0x24f4')]&&_0x4455a2[_0x19cc94('0x2040')](_0x35d091,0x1);}_0xad0e80=_0x4ccf31;}_0x441a0f[_0x19cc94('0x158e')][_0x19cc94('0x9fe')]&&_0x441a0f[_0x19cc94('0x158e')][_0x19cc94('0x9fe')](_0xad0e80,_0x33de34);},_0x441a0f['getLine']=function(_0x109cd9,_0x28eb8b){const _0x273696=_0x48e03f;let _0x2c69a5='';if(_0x2e3ca0()[_0x273696('0x8f2')](_0x28eb8b))return _0x2c69a5;if(_0x2e3ca0()[_0x273696('0x94b')](_0x28eb8b)){for(let _0x2e4c6b=0x0;_0x2e4c6b<_0x28eb8b['length'];_0x2e4c6b++){_0x2c69a5+='\x20'+(_0x109cd9[_0x28eb8b[_0x2e4c6b]]?_0x109cd9[_0x28eb8b[_0x2e4c6b]]:'');}return _0x2c69a5;}else return _0x109cd9[_0x28eb8b]?_0x109cd9[_0x28eb8b]:'';};}],'templateUrl':_0x4f4502};}const _0x175a28=_0x3ed140;_0x318d0e['$inject']=[_0x189033('0x1d08')];function _0x318d0e(_0x3397c1){const _0x3f10a1=_0x189033;return{'restrict':'E','replace':!![],'scope':{'onReply':'&','ngModel':'=','ctrlMethods':'=','pickerPosition':'=','search':'=','recentEmojis':'=','placeholder':'='},'template':_0x3f10a1('0x236'),'link':function(_0xc06547,_0x3ce759){const _0x1197b8=_0x3f10a1,_0x2580b1=_0x3ce759[_0x1197b8('0x244')]({'pickerPosition':_0xc06547['pickerPosition'],'search':_0xc06547['search'],'recentEmojis':_0xc06547[_0x1197b8('0x1831')],'placeholder':_0x3397c1[_0x1197b8('0x2728')](_0xc06547[_0x1197b8('0x156b')]||'Type\x20a\x20message'),'attributes':{'spellcheck':!![]},'events':{'keypress':function(_0x26bc1c,_0x1cc0f3){const _0x3520bb=_0x1197b8;_0xc06547[_0x3520bb('0x1f60')]=this[_0x3520bb('0x131f')](),_0xc06547[_0x3520bb('0x9b2')]({'event':_0x1cc0f3,'body':this[_0x3520bb('0x131f')]()});},'emojibtn_click':function(){const _0x38054b=_0x1197b8;_0xc06547[_0x38054b('0x1f60')]=this[_0x38054b('0x131f')]();}}});_0xc06547[_0x1197b8('0x1f60')]&&_0x2580b1[0x0]['emojioneArea']['setText'](_0xc06547[_0x1197b8('0x1f60')]),_0xc06547[_0x1197b8('0x1e8d')]=_0xc06547['ctrlMethods']||{},_0xc06547['internalControl'][_0x1197b8('0x2726')]=function(_0x1309f5){const _0x3ec224=_0x1197b8;_0x2580b1[0x0][_0x3ec224('0x244')][_0x3ec224('0x2726')](_0x1309f5);},_0xc06547['internalControl'][_0x1197b8('0x131f')]=function(){const _0x2709d4=_0x1197b8;return _0x2580b1[0x0][_0x2709d4('0x244')][_0x2709d4('0x131f')]();},_0xc06547[_0x1197b8('0x186d')](_0x1197b8('0x1f60'),function(_0x47c539){const _0xbfabb2=_0x1197b8;!_0x47c539&&_0x2580b1[0x0][_0xbfabb2('0x244')][_0xbfabb2('0x2726')]('');});}};}const _0x48f43c=_0x318d0e,_0x4216df=_0x180212['p']+'src/js/modules/core/directives/ms-font-family/ms-font-family.html/ms-font-family.html';;function _0x43820b(){return{'restrict':'E','scope':{'ngModel':'='},'controller':['$scope',function(_0x3b98bd){const _0x1911cd=a0_0x4e0a;_0x3b98bd[_0x1911cd('0xad0')]=[{'option':_0x1911cd('0x1754'),'value':_0x1911cd('0x22a4')},{'option':_0x1911cd('0x13ad'),'value':_0x1911cd('0x2f0')},{'option':_0x1911cd('0xdcb'),'value':_0x1911cd('0xb70')},{'option':_0x1911cd('0x424'),'value':_0x1911cd('0x1ca9')},{'option':_0x1911cd('0x1429'),'value':_0x1911cd('0x1e1a')},{'option':'Georgia','value':'Georgia,serif'},{'option':'Lucida\x20Sans\x20Unicode','value':_0x1911cd('0x1beb')},{'option':_0x1911cd('0xe73'),'value':_0x1911cd('0x185a')},{'option':_0x1911cd('0x21b2'),'value':_0x1911cd('0x1b9b')},{'option':'Trebuchet\x20MS','value':_0x1911cd('0xe97')},{'option':_0x1911cd('0x1da7'),'value':_0x1911cd('0x23c0')}];}],'templateUrl':_0x4216df};}const _0x703ba8=_0x43820b;function _0x44187c(){const _0x244779=_0x189033,_0x122ac7=this;_0x122ac7[_0x244779('0x22db')]=[],_0x122ac7[_0x244779('0x36d')]=0x0,_0x122ac7[_0x244779('0x8c6')]=_0x3f117b,_0x122ac7[_0x244779('0x308')]=_0x23223d,_0x122ac7[_0x244779('0x2375')]=_0x26ad0e,_0x122ac7[_0x244779('0xdb7')]=_0x162e6a,_0x122ac7[_0x244779('0x1fc2')]=_0x3f6103,_0x122ac7['totalSteps']=_0x4d916f,_0x122ac7[_0x244779('0xf47')]=_0x2054c7,_0x122ac7[_0x244779('0x2453')]=_0x10f1ae,_0x122ac7[_0x244779('0x2783')]=_0x4ef6e1,_0x122ac7[_0x244779('0x13e4')]=_0x1fa7d1,_0x122ac7['formsIncomplete']=_0x5d72be,_0x122ac7[_0x244779('0xbba')]=_0x48eac2;function _0x3f117b(_0x24c2fe){const _0xbad26c=_0x244779;_0x122ac7[_0xbad26c('0x22db')][_0xbad26c('0x1fd0')](_0x24c2fe);}function _0x23223d(){const _0x396d28=_0x244779;if(_0x2054c7())return;_0x122ac7[_0x396d28('0x36d')]--;}function _0x26ad0e(){if(_0x10f1ae())return;_0x122ac7['selectedIndex']++;}function _0x162e6a(){const _0x1b64fb=_0x244779;_0x122ac7[_0x1b64fb('0x36d')]=0x0;}function _0x3f6103(){const _0x1b992f=_0x244779;_0x122ac7[_0x1b992f('0x36d')]=_0x4d916f()-0x1;}function _0x4d916f(){const _0x4232b4=_0x244779;return _0x122ac7[_0x4232b4('0x22db')]['length'];}function _0x2054c7(){const _0x5eb7eb=_0x244779;return _0x122ac7[_0x5eb7eb('0x36d')]===0x0;}function _0x10f1ae(){const _0x4171e1=_0x244779;return _0x122ac7[_0x4171e1('0x36d')]===_0x4d916f()-0x1;}function _0x4ef6e1(){const _0x3ae59b=_0x244779;return angular[_0x3ae59b('0x127')](_0x122ac7[_0x3ae59b('0x22db')][_0x122ac7[_0x3ae59b('0x36d')]])&&_0x122ac7[_0x3ae59b('0x22db')][_0x122ac7[_0x3ae59b('0x36d')]][_0x3ae59b('0x1f89')];}function _0x1fa7d1(){const _0x113bea=_0x244779;return _0x122ac7[_0x113bea('0x36d')]>0x0&&angular[_0x113bea('0x127')](_0x122ac7['forms'][_0x122ac7['selectedIndex']-0x1])&&_0x122ac7[_0x113bea('0x22db')][_0x122ac7[_0x113bea('0x36d')]-0x1][_0x113bea('0x1f89')];}function _0x5d72be(){const _0x447766=_0x244779;for(let _0x64ce1a=0x0;_0x64ce1a<_0x122ac7[_0x447766('0x22db')][_0x447766('0x1564')];_0x64ce1a++){if(_0x122ac7[_0x447766('0x22db')][_0x64ce1a][_0x447766('0x1f89')])return!![];}return![];}function _0x48eac2(){const _0x1763b8=_0x244779;_0x122ac7['selectedIndex']=0x0;for(let _0x2d00eb=0x0;_0x2d00eb<_0x122ac7[_0x1763b8('0x22db')][_0x1763b8('0x1564')];_0x2d00eb++){_0x122ac7[_0x1763b8('0x22db')][_0x2d00eb][_0x1763b8('0x272a')](),_0x122ac7[_0x1763b8('0x22db')][_0x2d00eb][_0x1763b8('0x2256')]();}}}function _0x59d601(){const _0x1184b4=_0x189033;return{'restrict':'E','scope':!![],'controller':_0x1184b4('0x2372'),'compile':function(_0x34f368){const _0x489eb7=_0x1184b4;return _0x34f368[_0x489eb7('0x81e')](_0x489eb7('0x163a')),function _0x568c7e(){};}};}function _0x4b977c(){const _0x3c67de=_0x189033;return{'restrict':'A','require':[_0x3c67de('0x2744'),_0x3c67de('0x2015')],'compile':function(_0x24a8f3){const _0x231731=_0x3c67de;return _0x24a8f3[_0x231731('0x81e')](_0x231731('0x2132')),function _0x49d742(_0x40ac74,_0x53173b,_0x264a76,_0x234a87){const _0x436aea=_0x231731,_0x46e33e=_0x234a87[0x0],_0x108fb5=_0x234a87[0x1];_0x108fb5[_0x436aea('0x8c6')](_0x46e33e);};}};}const _0x5b36fb=_0x180212['p']+_0x189033('0x956');_0x3b1a1c[_0x189033('0x14be')]=[_0x189033('0x16ea')];function _0x3b1a1c(_0xbb60c2){return{'restrict':'E','scope':{'onClose':'&'},'transclude':!![],'templateUrl':_0x5b36fb,'link':function(_0x44b6b0,_0x2a2b87){const _0x236ffd=a0_0x4e0a,_0x3261ed=_0xbb60c2[_0x236ffd('0x1c07')](_0x236ffd('0x19fd')),_0x339bec=_0x236ffd('0x19fd');_0x3261ed[_0x236ffd('0x81e')](_0x339bec);function _0x574812(){const _0x21f904=_0x236ffd;_0x3261ed[_0x21f904('0x12a4')](_0x339bec),_0x2a2b87[_0x21f904('0x3ec')](),_0x44b6b0[_0x21f904('0xa12')]&&_0x44b6b0[_0x21f904('0xa12')](),_0x44b6b0[_0x21f904('0x4b8')]();}_0x44b6b0[_0x236ffd('0x593')]=_0x574812;}};}const _0x261d5a=_0x3b1a1c;_0x4fc358[_0x189033('0x14be')]=['$timeout'],_0x1ca43b[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x25ba'),'$timeout'];function _0x1ca43b(_0x34c2f8,_0x29c63a,_0x1cefb0,_0x159f05){const _0x42750f=_0x189033,_0x197510=this,_0x2a052b={'columnCount':0x5,'respectItemOrder':![],'reLayoutDebounce':0x190,'responsive':{'md':0x3,'sm':0x2,'xs':0x1}};let _0xe2c674=!![];_0x197510[_0x42750f('0x158e')]=null,_0x197510[_0x42750f('0x286a')]=[],_0x197510[_0x42750f('0x234b')]='',_0x197510[_0x42750f('0x14c')]='',_0x197510['items']=[],_0x197510[_0x42750f('0xd62')]=_0x2cc36b,_0x197510['initialize']=_0x3f87a5,_0x197510[_0x42750f('0x908')]=_0x18ded9;function _0x3f87a5(){const _0x2edb17=_0x42750f;_0x197510[_0x2edb17('0x158e')]=!_0x197510[_0x2edb17('0x158e')]?_0x2a052b:angular['extend'](_0x2a052b,_0x197510[_0x2edb17('0x158e')]),_0x40a6ca();}_0x34c2f8[_0x42750f('0x26a2')](_0x42750f('0x1934'),function(){_0x2cc36b();});function _0x18ded9(_0x51933b,_0x270522){const _0x2d01fd=_0x42750f;if(typeof imagesLoaded!==_0x2d01fd('0x1867')){const _0x3b6a2c=_0x29c63a['imagesLoaded'](_0x51933b);_0x3b6a2c['on'](_0x2d01fd('0x20b5'),function(){_0x270522();});}else _0x270522();}function _0x40a6ca(){const _0x9f6032=_0x42750f;_0x34c2f8[_0x9f6032('0x186d')](function(){return _0x197510['container']['width']();},function(_0x502725,_0x53d378){_0x502725!==_0x53d378&&_0x2cc36b();});}function _0x2cc36b(){const _0x4bf00a=_0x42750f;_0xe2c674&&_0x159f05[_0x4bf00a('0x19fb')](_0xe2c674);_0xe2c674=_0x159f05(function(){const _0xd20fd8=_0x4bf00a;_0x420c89(),_0x34c2f8[_0xd20fd8('0x5ed')](_0xd20fd8('0xff9'));},_0x197510[_0x4bf00a('0x158e')][_0x4bf00a('0x2026')]);function _0x420c89(){const _0xdf64fa=_0x4bf00a;_0x197510[_0xdf64fa('0x234b')]=_0x197510[_0xdf64fa('0x286a')][0x0][_0xdf64fa('0xdce')](),_0x5198f3(),_0x34c2f8[_0xdf64fa('0x5ed')](_0xdf64fa('0x1017')),_0x197510[_0xdf64fa('0x1996')]=_0x197510[_0xdf64fa('0x286a')][_0xdf64fa('0x1c07')](_0xdf64fa('0x225'));const _0x3494d5=Array[_0xdf64fa('0x1dd8')](null,new Array(_0x197510[_0xdf64fa('0x13b6')]))[_0xdf64fa('0x386')](function(){return 0x0;});for(let _0x28929d=0x0;_0x28929d<_0x197510[_0xdf64fa('0x1996')][_0xdf64fa('0x1564')];_0x28929d++){let _0x3bae9a=_0x197510['items'][_0x28929d],_0x288fdb,_0x46a767;_0x3bae9a=angular[_0xdf64fa('0x1fcc')](_0x3bae9a);_0x3bae9a['scope']()&&_0x3bae9a[_0xdf64fa('0x2090')]()[_0xdf64fa('0x5ed')]('msMasonryItem:startReLayout');_0x3bae9a[_0xdf64fa('0x1e78')]({'width':_0x197510[_0xdf64fa('0x14c')]});_0x197510['options'][_0xdf64fa('0x8b3')]?(_0x288fdb=_0x28929d%_0x197510['columnCount'],_0x46a767=_0x3494d5[_0x288fdb]):(_0x46a767=Math[_0xdf64fa('0x225c')][_0xdf64fa('0x1dd8')](Math,_0x3494d5),_0x288fdb=_0x3494d5[_0xdf64fa('0x824')](_0x46a767));_0x3494d5[_0x288fdb]=_0x46a767+_0x3bae9a[0x0][_0xdf64fa('0xdce')]()[_0xdf64fa('0xf')];const _0x37798b=Math['round'](_0x288fdb*_0x197510[_0xdf64fa('0x14c')]),_0x583e18=_0x46a767;_0x3bae9a[_0xdf64fa('0x1e78')]({'transform':_0xdf64fa('0x1a2a')+_0x37798b+_0xdf64fa('0x1e2f')+_0x583e18+'px,0px)'}),_0x3bae9a['addClass'](_0xdf64fa('0x1e0e')),_0x3bae9a['scope']()&&_0x3bae9a[_0xdf64fa('0x2090')]()[_0xdf64fa('0x5ed')](_0xdf64fa('0xb67'));}}}function _0x5198f3(){const _0xcff0c7=_0x42750f;_0x197510[_0xcff0c7('0x13b6')]=_0x197510[_0xcff0c7('0x158e')][_0xcff0c7('0x13b6')];if(_0x1cefb0(_0xcff0c7('0x13ac')))_0x197510[_0xcff0c7('0x13b6')]=_0x197510[_0xcff0c7('0x158e')]['columnCount'];else{if(_0x1cefb0('md'))_0x197510[_0xcff0c7('0x13b6')]=_0x197510['columnCount']>_0x197510[_0xcff0c7('0x158e')][_0xcff0c7('0x342')]['md']?_0x197510[_0xcff0c7('0x158e')][_0xcff0c7('0x342')]['md']:_0x197510[_0xcff0c7('0x13b6')];else _0x1cefb0('sm')?_0x197510[_0xcff0c7('0x13b6')]=_0x197510['columnCount']>_0x197510['options']['responsive']['sm']?_0x197510[_0xcff0c7('0x158e')][_0xcff0c7('0x342')]['sm']:_0x197510[_0xcff0c7('0x13b6')]:_0x197510['columnCount']=_0x197510[_0xcff0c7('0x158e')][_0xcff0c7('0x342')]['xs'];}_0x197510[_0xcff0c7('0x14c')]=_0x197510[_0xcff0c7('0x234b')]['width']/_0x197510[_0xcff0c7('0x13b6')];}}function _0x4fc358(_0x1dc126){const _0x4d0407=_0x189033;return{'restrict':_0x4d0407('0x1636'),'controller':_0x4d0407('0xcc9'),'compile':_0x1023e3};function _0x1023e3(_0x5d28b2,_0x230b9e){return{'pre':function _0x3b6b66(_0x1c1c15,_0x1d0c2e,_0x5d3ea5,_0x42e060){const _0x315c85=a0_0x4e0a;_0x42e060['options']=angular[_0x315c85('0x1cb2')](_0x230b9e['options']||'{}'),_0x42e060['container']=_0x5d28b2;},'post':function _0x4ca79f(_0x552c83,_0x1fae24,_0x399a6a,_0x1b06f0){_0x1dc126(function(){const _0x43180d=a0_0x4e0a;_0x1b06f0[_0x43180d('0x262e')]();});}};}}function _0x2ccc51(){const _0x59508d=_0x189033;return{'restrict':_0x59508d('0x1636'),'require':'^msMasonry','priority':0x1,'link':_0x3772c0};function _0x3772c0(_0x3234be,_0x3e195b,_0x1f8aff,_0x1cefc0){const _0x102350=_0x59508d;_0x1cefc0[_0x102350('0x908')](_0x3e195b,function(){_0x1cefc0['reLayout']();}),_0x3234be['$on'](_0x102350('0xb67'),function(){_0x3234be['$watch'](function(){const _0x5914aa=a0_0x4e0a;return _0x3e195b[_0x5914aa('0xf')]();},function(_0x11029a,_0x3a8a3a){const _0x2a270c=a0_0x4e0a;_0x11029a!==_0x3a8a3a&&_0x1cefc0[_0x2a270c('0xd62')]();});}),_0x3e195b['on']('$destroy',function(){const _0x30e986=_0x102350;_0x1cefc0[_0x30e986('0xd62')]();});}}const _0xb382af=_0x180212['p']+_0x189033('0xb68');_0x478fcc['$inject']=[_0x189033('0x7a5'),'$mdColorPalette',_0x189033('0xbbc'),_0x189033('0x214e')];function _0x478fcc(_0x2abd50,_0x23923b,_0x4bf8bd,_0x2bf488){const _0x3324ee=_0x189033,_0x8ab48f=this;_0x8ab48f['palettes']=_0x23923b,_0x8ab48f[_0x3324ee('0x113c')]=![],_0x8ab48f[_0x3324ee('0xb05')]=![],_0x2abd50[_0x3324ee('0x1c7d')]={},_0x8ab48f[_0x3324ee('0xfcb')]=_0x8f4f20,_0x8ab48f[_0x3324ee('0xd2c')]=_0x375cec,_0x8ab48f[_0x3324ee('0x1cf7')]=_0x5b3bbe,_0x2abd50[_0x3324ee('0x186d')](_0x3324ee('0x1f60'),_0x5f3c4c);function _0x8f4f20(_0xbfb60a,_0x39a064){const _0x426641=_0x3324ee;_0x8ab48f[_0x426641('0x113c')]=_0xbfb60a,_0x8ab48f[_0x426641('0xb05')]=_0x39a064;}function _0x375cec(_0x102224,_0xadaa4c){const _0x283d85=_0x3324ee;_0x3d98e0(_0x102224,_0xadaa4c),_0x53f8bb(),_0x4bf8bd[_0x283d85('0x1715')]();}function _0x5b3bbe(){const _0x6546d4=_0x3324ee;_0x8ab48f[_0x6546d4('0x27ca')]={'palette':'','hue':'','class':''},_0x8f4f20(![],![]),_0x53f8bb();}function _0x5f3c4c(){const _0x431e34=_0x3324ee;if(!_0x8ab48f['modelCtrl'][_0x431e34('0x954')]||_0x8ab48f[_0x431e34('0x1868')][_0x431e34('0x954')]===''){_0x5b3bbe();return;}let _0x453e9b,_0xe5b7c7;if(_0x8ab48f['msModelType']===_0x431e34('0x1364')){const _0x36ce36=_0x8ab48f[_0x431e34('0x1868')][_0x431e34('0x954')][_0x431e34('0x1fc5')]('-');_0x36ce36[_0x431e34('0x1564')]>=0x5?(_0x453e9b=_0x36ce36[0x1]+'-'+_0x36ce36[0x2],_0xe5b7c7=_0x36ce36[0x3]):(_0x453e9b=_0x36ce36[0x1],_0xe5b7c7=_0x36ce36[0x2]);}else _0x8ab48f[_0x431e34('0x13ba')]===_0x431e34('0xb3d')&&(_0x453e9b=_0x8ab48f[_0x431e34('0x1868')][_0x431e34('0x954')][_0x431e34('0x27ff')],_0xe5b7c7=_0x8ab48f[_0x431e34('0x1868')][_0x431e34('0x954')][_0x431e34('0x937')]||0x1f4);_0x3d98e0(_0x453e9b,_0xe5b7c7);}function _0x3d98e0(_0x51cb4e,_0x1724fe){const _0x1939e6=_0x3324ee;_0x8ab48f[_0x1939e6('0x27ca')]={'palette':_0x51cb4e,'hue':_0x1724fe,'class':_0x1939e6('0x25b')+_0x51cb4e+'-'+_0x1724fe+_0x1939e6('0xa38'),'bgColorValue':_0x2bf488[_0x1939e6('0x4da')](_0x8ab48f[_0x1939e6('0x1651')][_0x51cb4e][_0x1724fe]['value']),'fgColorValue':_0x2bf488[_0x1939e6('0x4da')](_0x8ab48f['palettes'][_0x51cb4e][_0x1724fe]['contrast'])},_0x8ab48f[_0x1939e6('0x13ba')]===_0x1939e6('0xb3d')&&!angular[_0x1939e6('0xa18')](_0x8ab48f[_0x1939e6('0x27ca')],_0x8ab48f[_0x1939e6('0x1868')][_0x1939e6('0x954')])&&_0x53f8bb(),_0x8f4f20(_0x51cb4e,_0x8ab48f['palettes'][_0x51cb4e]),_0x2abd50[_0x1939e6('0x1c7d')]=_0x8ab48f[_0x1939e6('0x27ca')];}function _0x53f8bb(){const _0x177e8b=_0x3324ee;if(_0x8ab48f[_0x177e8b('0x13ba')]==='class')_0x8ab48f[_0x177e8b('0x1868')][_0x177e8b('0x22ae')](_0x8ab48f[_0x177e8b('0x27ca')][_0x177e8b('0x1364')]);else _0x8ab48f['msModelType']===_0x177e8b('0xb3d')&&_0x8ab48f[_0x177e8b('0x1868')][_0x177e8b('0x22ae')](_0x8ab48f['selectedColor']);}}function _0x381c35(){const _0x5ae357=_0x189033;return{'require':[_0x5ae357('0x2634'),'ngModel'],'restrict':'E','scope':{'ngModel':'=','msModelType':'@?'},'controller':'msMaterialColorPickerController\x20as\x20vm','transclude':!![],'templateUrl':_0xb382af,'link':function(_0x474f17,_0x3325be,_0x1ed2bd,_0x55e2b4,_0xb4a7e1){const _0x164163=_0x5ae357,_0x358b79=_0x55e2b4[0x0];_0x358b79[_0x164163('0x1868')]=_0x55e2b4[0x1],_0x358b79[_0x164163('0x13ba')]=_0x474f17[_0x164163('0x13ba')]||_0x164163('0x1364'),_0xb4a7e1(_0x474f17,function(_0x40ecf7){const _0x9965f3=_0x164163;_0x40ecf7=_0x40ecf7['filter'](function(_0x2f0e1d,_0x233359){return _0x233359['nodeType']===0x1?!![]:![];}),_0x40ecf7['length']&&_0x3325be[_0x9965f3('0x1c07')](_0x9965f3('0x680'))['replaceWith'](_0x40ecf7);});}};}_0x1518e3['$inject']=[_0x189033('0x1b'),'$q',_0x189033('0x133'),'$state'],_0x111391[_0x189033('0x14be')]=['$rootScope','$mdComponentRegistry',_0x189033('0x5e4')],_0x8d177b[_0x189033('0x14be')]=[_0x189033('0x16ea'),_0x189033('0x1b'),_0x189033('0x5e4')];function _0x2193f9(){let _0x380a62={};const _0x3ee3c1={'setFoldable':_0x479101,'isNavFoldedOpen':_0x346785,'toggleFold':_0x342904,'openFolded':_0x472709,'closeFolded':_0x2653a1};return _0x3ee3c1;function _0x479101(_0x2eb5bb,_0x13f7b4){_0x380a62={'scope':_0x2eb5bb,'element':_0x13f7b4};}function _0x346785(){const _0x34d1c4=a0_0x4e0a;return _0x380a62[_0x34d1c4('0x2090')][_0x34d1c4('0x90a')]();}function _0x342904(){const _0x9b3e24=a0_0x4e0a;_0x380a62[_0x9b3e24('0x2090')][_0x9b3e24('0x218e')]();}function _0x472709(){const _0x3bb253=a0_0x4e0a;_0x380a62[_0x3bb253('0x2090')]['openFolded']();}function _0x2653a1(){const _0x32d283=a0_0x4e0a;_0x380a62[_0x32d283('0x2090')]['closeFolded']();}}function _0x8d177b(_0x4d5468,_0x266267,_0x5ca5ce){return{'restrict':'A','link':function(_0x6648d6,_0x17e21d,_0x3d76c0){const _0x4a77f5=a0_0x4e0a;let _0x100a7d=_0x3d76c0[_0x4a77f5('0x1baa')]===_0x4a77f5('0x26ac'),_0x284b52=![];const _0xb2ed1e=angular['element'](_0x4d5468[0x0][_0x4a77f5('0x18e5')]),_0x17a2fe=angular[_0x4a77f5('0x1fcc')](_0x4a77f5('0x23a3')),_0x40f4ef=angular[_0x4a77f5('0x1fcc')](_0x4a77f5('0x4f3')),_0xedfdf5=_0x17e21d[_0x4a77f5('0x2361')]();_0x5ca5ce[_0x4a77f5('0x1be1')](_0x6648d6,_0x17e21d,_0x100a7d);_0x100a7d?_0x31e460():_0xc4724d();function _0x310539(){return _0x284b52;}function _0x3fd050(){_0x100a7d=!_0x100a7d,_0x100a7d?_0x31e460():_0xc4724d();}function _0x31e460(){const _0xacba33=_0x4a77f5;_0xb2ed1e[_0xacba33('0x81e')]('ms-nav-folded'),_0x266267[_0xacba33('0x5ed')]('msNav::forceCollapse'),_0x17e21d[_0xacba33('0x5ee')](0x0),_0xedfdf5[_0xacba33('0x22d6')](_0x17a2fe),_0x17a2fe['on'](_0xacba33('0x130d'),function(_0x3e4713){_0x17a89d(_0x3e4713),_0x284b52=!![];});}function _0x17a89d(_0x519dd7){const _0x3866ca=_0x4a77f5;angular[_0x3866ca('0x127')](_0x519dd7)&&_0x519dd7[_0x3866ca('0x1706')](),_0xb2ed1e[_0x3866ca('0x81e')](_0x3866ca('0x1584')),_0x266267[_0x3866ca('0x5ed')](_0x3866ca('0x574')),_0xedfdf5[_0x3866ca('0x1c07')](_0x17a2fe)[_0x3866ca('0x3ec')](),_0xedfdf5[_0x3866ca('0x2361')]()[_0x3866ca('0x22d6')](_0x40f4ef),_0x40f4ef['on'](_0x3866ca('0x130d'),function(_0x2e37d5){_0x44bb93(_0x2e37d5),_0x284b52=![];});}function _0x44bb93(_0x1cbf1f){const _0x5c3aee=_0x4a77f5;angular[_0x5c3aee('0x127')](_0x1cbf1f)&&_0x1cbf1f[_0x5c3aee('0x1706')](),_0x266267[_0x5c3aee('0x5ed')]('msNav::forceCollapse'),_0x17e21d['scrollTop'](0x0),_0xb2ed1e[_0x5c3aee('0x12a4')](_0x5c3aee('0x1584')),_0xedfdf5['parent']()[_0x5c3aee('0x1c07')](_0x40f4ef)[_0x5c3aee('0x3ec')](),_0xedfdf5[_0x5c3aee('0x22d6')](_0x17a2fe),_0x17a2fe['on']('mouseenter\x20touchstart',function(_0x764d7f){_0x17a89d(_0x764d7f),_0x284b52=!![];});}function _0xc4724d(){const _0x152372=_0x4a77f5;_0xb2ed1e[_0x152372('0x12a4')](_0x152372('0x695')),_0x266267[_0x152372('0x5ed')](_0x152372('0x574')),_0x17e21d[_0x152372('0x2422')](_0x152372('0x25b5'));}_0x6648d6[_0x4a77f5('0x218e')]=_0x3fd050,_0x6648d6[_0x4a77f5('0x1e20')]=_0x17a89d,_0x6648d6[_0x4a77f5('0xbbe')]=_0x44bb93,_0x6648d6[_0x4a77f5('0x90a')]=_0x310539,_0x6648d6[_0x4a77f5('0x26a2')](_0x4a77f5('0x4b8'),function(){const _0x1d4358=_0x4a77f5;_0x17a2fe['off']('mouseenter\x20touchstart'),_0x40f4ef['off'](_0x1d4358('0x130d')),_0x17e21d[_0x1d4358('0x2422')](_0x1d4358('0x25b5'));});}};}function _0x33fa24(){const _0x45a030=_0x189033,_0x38cd3b=this;let _0xb32b30=![];const _0xd0af1a=[];let _0x37ea81=[];_0x38cd3b['isDisabled']=_0x5bb1ff,_0x38cd3b[_0x45a030('0x810')]=_0x2544aa,_0x38cd3b['disable']=_0x4423f8,_0x38cd3b[_0x45a030('0x1f8b')]=_0x45dea4,_0x38cd3b[_0x45a030('0x2047')]=_0x332180,_0x38cd3b[_0x45a030('0xd7')]=_0x1e5802,_0x38cd3b['clearLockedItems']=_0x36d708;function _0x5bb1ff(){return _0xb32b30;}function _0x4423f8(){_0xb32b30=!![];}function _0x2544aa(){_0xb32b30=![];}function _0x45dea4(_0xb8339e,_0x29b8f1){_0xd0af1a['push']({'element':_0xb8339e,'scope':_0x29b8f1});}function _0x332180(){return _0x37ea81;}function _0x1e5802(_0x102990,_0x1b4d9d){const _0x22e3e1=_0x45a030;_0x37ea81[_0x22e3e1('0x1fd0')]({'element':_0x102990,'scope':_0x1b4d9d});}function _0x36d708(){_0x37ea81=[];}}function _0x111391(_0x3321fd,_0x3cd868,_0x6b5fc4){const _0x217a37=_0x189033;return{'restrict':'E','scope':{},'controller':_0x217a37('0x744'),'compile':function(_0x55ffda){const _0x2ae489=_0x217a37;return _0x55ffda[_0x2ae489('0x81e')](_0x2ae489('0xc4')),function _0x3fa2ed(_0x59d341){const _0x34f87f=_0x2ae489;_0x3321fd['$broadcast']('msNav::expandMatchingToggles');const _0x4d80c7=_0x3321fd[_0x34f87f('0x26a2')](_0x34f87f('0x1514'),function(){const _0x353cee=_0x34f87f;_0x3321fd['$broadcast'](_0x353cee('0x574')),_0x3cd868[_0x353cee('0x15ba')]('navigation')[_0x353cee('0x683')](function(_0x482bd4){const _0x744595=_0x353cee;_0x482bd4[_0x744595('0x12b0')](),_0x6b5fc4['isNavFoldedOpen']()&&_0x6b5fc4['closeFolded']();});});_0x59d341[_0x34f87f('0x26a2')](_0x34f87f('0x4b8'),function(){_0x4d80c7();});};}};}function _0xd86209(){return{'restrict':'A','compile':function(_0x6a84ab){const _0x1ad78e=a0_0x4e0a;return _0x6a84ab['addClass'](_0x1ad78e('0x1ab')),function _0x4da486(){};}};}function _0x227dff(){return{'restrict':'AE','compile':function(_0x5042df){return _0x5042df['addClass']('ms-nav-button'),function _0x506f29(){};}};}function _0x1518e3(_0x505bca,_0x5e4938,_0x205f84,_0x5b9f27){const _0x954db2=_0x189033;return{'restrict':'A','require':_0x954db2('0x1860'),'scope':!![],'compile':function(_0x17cc37,_0x4a0e34){const _0x4c7491=_0x954db2;return _0x17cc37[_0x4c7491('0x81e')](_0x4c7491('0x818')),angular['isUndefined'](_0x4a0e34[_0x4c7491('0x1f9c')])&&(_0x4a0e34[_0x4c7491('0x1f9c')]=!![]),_0x17cc37[_0x4c7491('0x244e')]('collapsed',_0x4a0e34['collapsed']),function _0x54def6(_0x46f5f1,_0x1a6d1f,_0x5675b0,_0x347e05){const _0x3db22c=_0x4c7491,_0xc88c4e={'expanded':_0x3db22c('0x986'),'expandAnimation':'expand-animation','collapseAnimation':_0x3db22c('0x2187')},_0x5c8a1a=_0x1a6d1f['find']('a'),_0x5606e0=[],_0x498508=/\(.*\)/g;angular[_0x3db22c('0x1299')](_0x5c8a1a,function(_0x637596){const _0x1a04bc=_0x3db22c;let _0x19f41b=angular[_0x1a04bc('0x1fcc')](_0x637596)[_0x1a04bc('0x244e')]('ui-sref');if(angular[_0x1a04bc('0x105d')](_0x19f41b))return;_0x19f41b=_0x19f41b[_0x1a04bc('0x1725')](_0x498508,''),_0x5606e0[_0x1a04bc('0x1fd0')](_0x19f41b);}),_0x347e05['setToggleItem'](_0x1a6d1f,_0x46f5f1),_0x1a6d1f['children']('.ms-nav-button')['on'](_0x3db22c('0x1d42'),_0x2b67e9);function _0x2b67e9(){const _0xbeafef=_0x3db22c;if(_0x347e05[_0xbeafef('0x14b1')]())return;_0x347e05[_0xbeafef('0x287')](),_0x39b01f()?(_0x347e05[_0xbeafef('0x2403')](),_0x46f5f1[_0xbeafef('0x1b45')]('msNav::pushToLockedList'),_0x505bca[_0xbeafef('0x5ed')]('msNav::collapse'),_0x33c15f()['then'](function(){const _0x4d5b91=_0xbeafef;_0x347e05[_0x4d5b91('0x810')]();})):_0x46f5f1[_0xbeafef('0x5ed')](_0xbeafef('0x19be'));}_0x46f5f1[_0x3db22c('0x26a2')](_0x3db22c('0x4b8'),function(){const _0x62f6a6=_0x3db22c;_0x1a6d1f[_0x62f6a6('0x62')](_0x62f6a6('0xfd4'))['off'](_0x62f6a6('0x1d42'));}),_0x46f5f1[_0x3db22c('0x26a2')]('msNav::collapse',function(){const _0x6d7d97=_0x3db22c,_0x35bae0=_0x347e05['getLockedItems']();let _0x26e5c4=![];angular[_0x6d7d97('0x1299')](_0x35bae0,function(_0x5626de){const _0x47384a=_0x6d7d97;angular[_0x47384a('0xa18')](_0x5626de['scope'],_0x46f5f1)&&(_0x26e5c4=!![]);});if(_0x26e5c4)return;_0x2234fb()['then'](function(){const _0x802248=_0x6d7d97;_0x347e05[_0x802248('0x810')]();});}),_0x46f5f1[_0x3db22c('0x26a2')](_0x3db22c('0x19be'),function(){const _0x1479d7=_0x3db22c;_0x2234fb()[_0x1479d7('0x683')](function(){_0x347e05['enable']();});}),_0x46f5f1['$on'](_0x3db22c('0x574'),function(){const _0x2f654b=_0x3db22c,_0x22327f=_0x5b9f27[_0x2f654b('0xb24')][_0x2f654b('0x60a')];let _0x403273=![];angular[_0x2f654b('0x1299')](_0x5606e0,function(_0x23014c){_0x22327f===_0x23014c&&(_0x403273=!![]);}),_0x403273?_0x33c15f():_0x2234fb();}),_0x46f5f1[_0x3db22c('0x26a2')]('msNav::pushToLockedList',function(){_0x347e05['setLockedItem'](_0x1a6d1f,_0x46f5f1);});function _0x39b01f(){const _0x3222de=_0x3db22c;return _0x1a6d1f[_0x3222de('0x244e')](_0x3222de('0x1f9c'))===_0x3222de('0x26ac');}function _0x5a6481(){return!_0x39b01f();}function _0x33c15f(){const _0x7a3c9c=_0x3db22c,_0x48d7ad=_0x5e4938[_0x7a3c9c('0x448')]();if(_0x5a6481())return _0x48d7ad[_0x7a3c9c('0xfae')]({'error':!![]}),_0x48d7ad[_0x7a3c9c('0x1883')];_0x1a6d1f[_0x7a3c9c('0x244e')](_0x7a3c9c('0x1f9c'),![]);const _0xf31e4c=angular['element'](_0x1a6d1f[_0x7a3c9c('0x1c07')](_0x7a3c9c('0x1d81'))[0x0]);_0xf31e4c[_0x7a3c9c('0x1e78')]({'position':_0x7a3c9c('0x2138'),'visibility':'hidden','display':'block','height':_0x7a3c9c('0x8c5')});const _0x3093e8=_0xf31e4c[0x0]['offsetHeight'];return _0xf31e4c['css']({'position':'','visibility':'','display':'','height':''}),_0x46f5f1['$evalAsync'](function(){const _0x34c708=_0x7a3c9c;_0x205f84[_0x34c708('0x1219')](_0xf31e4c,{'display':_0x34c708('0x3cd'),'height':_0x34c708('0x907')},{'height':_0x3093e8+'px'},_0xc88c4e[_0x34c708('0x2860')])[_0x34c708('0x683')](function(){const _0x5ab2f3=_0x34c708;_0xf31e4c['addClass'](_0xc88c4e['expanded']),_0xf31e4c[_0x5ab2f3('0x1e78')]({'height':''}),_0x48d7ad['resolve']({'success':!![]});});}),_0x48d7ad[_0x7a3c9c('0x1883')];}function _0x2234fb(){const _0x914ad7=_0x3db22c,_0x56f9be=_0x5e4938[_0x914ad7('0x448')]();if(_0x39b01f())return _0x56f9be[_0x914ad7('0xfae')]({'error':!![]}),_0x56f9be[_0x914ad7('0x1883')];_0x1a6d1f[_0x914ad7('0x244e')]('collapsed',!![]);const _0x25eec3=angular['element'](_0x1a6d1f[_0x914ad7('0x1c07')](_0x914ad7('0x1d81'))[0x0]),_0x475428=_0x25eec3[0x0][_0x914ad7('0x1eef')];return _0x46f5f1[_0x914ad7('0x1ed5')](function(){const _0x11c537=_0x914ad7;_0x205f84['animate'](_0x25eec3,{'height':_0x475428+'px'},{'height':'0px'},_0xc88c4e['collapseAnimation'])[_0x11c537('0x683')](function(){const _0x519e09=_0x11c537;_0x25eec3[_0x519e09('0x12a4')](_0xc88c4e['expanded']),_0x25eec3[_0x519e09('0x1e78')]({'display':'','height':''}),_0x56f9be[_0x519e09('0xed7')]({'success':!![]});});}),_0x56f9be[_0x914ad7('0x1883')];}};}};}const _0x405a14=_0x180212['p']+_0x189033('0x443'),_0x16272c=_0x180212['p']+_0x189033('0x27a2');_0x94496d[_0x189033('0x14be')]=[_0x189033('0x25ba')],_0x39243c['$inject']=[_0x189033('0x7a5'),'$element',_0x189033('0x1b'),_0x189033('0x938'),_0x189033('0x27c0')],_0x193a83[_0x189033('0x14be')]=[_0x189033('0x27c0')],_0x35e728[_0x189033('0x14be')]=['$scope','$element','$rootScope','$animate',_0x189033('0x938'),_0x189033('0x27c0')],_0x4d2f0f['$inject']=[_0x189033('0x1b'),_0x189033('0x2f9'),'$mdSidenav',_0x189033('0x27c0')],_0x12674b[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x27c0')];function _0x11c88f(){const _0x455a33=_0x189033,_0x21196e=angular[_0x455a33('0xfc0')](['ng'])['get'](_0x455a33('0x24a8'));let _0xeb0b09=[];const _0x54907e=this;_0x54907e[_0x455a33('0x2716')]=_0x8283e7,_0x54907e[_0x455a33('0x6b8')]=_0x1b5bc4,_0x54907e['sortByWeight']=_0x35007e;function _0x8283e7(_0x5661bd,_0x1252d1){const _0x51e881=_0x455a33;if(!angular['isString'](_0x5661bd)){_0x21196e[_0x51e881('0x52a')](_0x51e881('0x222f'));return;}const _0x469f43=_0x5661bd['split']('.'),_0x56baff=_0x469f43[_0x469f43[_0x51e881('0x1564')]-0x1],_0x2217cf=_0x5b338e(_0x469f43);let _0x242de3=![];for(let _0x103d20=0x0;_0x103d20<_0x2217cf[_0x51e881('0x1564')];_0x103d20++){if(_0x2217cf[_0x103d20][_0x51e881('0x25e6')]===_0x56baff){_0x242de3=_0x2217cf[_0x103d20];break;}}_0x242de3?(angular['extend'](_0x242de3,_0x1252d1),_0x242de3['uisref']=_0x196c6e(_0x242de3)):(_0x1252d1[_0x51e881('0x62')]=[],(angular[_0x51e881('0x105d')](_0x1252d1[_0x51e881('0x1df8')])||!angular[_0x51e881('0x52d')](_0x1252d1['weight']))&&(_0x1252d1[_0x51e881('0x1df8')]=0x1),_0x1252d1['_id']=_0x56baff,_0x1252d1['_path']=_0x5661bd,_0x1252d1[_0x51e881('0x171')]=_0x196c6e(_0x1252d1),_0x2217cf[_0x51e881('0x1fd0')](_0x1252d1));}function _0x1b5bc4(_0x48c9d9){const _0x44c19a=_0x455a33;if(!angular[_0x44c19a('0xc1c')](_0x48c9d9)){_0x21196e[_0x44c19a('0x52a')](_0x44c19a('0x222f'));return;}let _0x33c880=_0xeb0b09;const _0x4f6fe2=_0x48c9d9[_0x44c19a('0x1fc5')]('.');for(let _0x485e32=0x0;_0x485e32<_0x4f6fe2[_0x44c19a('0x1564')];_0x485e32++){const _0x3a1934=_0x4f6fe2[_0x485e32];for(let _0x458ae9=0x0;_0x458ae9<_0x33c880[_0x44c19a('0x1564')];_0x458ae9++){if(_0x33c880[_0x458ae9][_0x44c19a('0x25e6')]===_0x3a1934){if(_0x33c880[_0x458ae9]['_path']===_0x48c9d9)return _0x33c880[_0x44c19a('0x2040')](_0x458ae9,0x1),!![];_0x33c880=_0x33c880[_0x458ae9][_0x44c19a('0x62')];break;}}}return![];}function _0x35007e(_0x46424f){const _0x4cc08c=_0x455a33;!_0x46424f&&(_0x46424f=_0xeb0b09,_0x46424f[_0x4cc08c('0x671')](_0x37e4e1));for(let _0x42ff4a=0x0;_0x42ff4a<_0x46424f[_0x4cc08c('0x1564')];_0x42ff4a++){const _0x5ab7ad=_0x46424f[_0x42ff4a][_0x4cc08c('0x62')];_0x5ab7ad[_0x4cc08c('0x1564')]>0x1&&_0x5ab7ad[_0x4cc08c('0x671')](_0x37e4e1),_0x5ab7ad[_0x4cc08c('0x1564')]>0x0&&_0x35007e(_0x5ab7ad);}}function _0x5b338e(_0x313a87){const _0xee0f0e=_0x455a33;let _0x1cdbd3=_0xeb0b09;if(_0x313a87[_0xee0f0e('0x1564')]===0x1)return _0x1cdbd3;_0x313a87[_0xee0f0e('0x1d')]();for(let _0x4c83a7=0x0;_0x4c83a7<_0x313a87[_0xee0f0e('0x1564')];_0x4c83a7++){const _0x362572=_0x313a87[_0x4c83a7];let _0x4d5a8f=!![];for(let _0x1798e8=0x0;_0x1798e8<_0x1cdbd3[_0xee0f0e('0x1564')];_0x1798e8++){if(_0x1cdbd3[_0x1798e8]['_id']===_0x362572){_0x1cdbd3=_0x1cdbd3[_0x1798e8][_0xee0f0e('0x62')],_0x4d5a8f=![];break;}}if(_0x4d5a8f){const _0x803db5={'_id':_0x362572,'_path':_0x313a87[_0xee0f0e('0x1630')]('.'),'title':_0x362572,'weight':0x1,'children':[]};_0x1cdbd3['push'](_0x803db5),_0x1cdbd3=_0x803db5[_0xee0f0e('0x62')];}}return _0x1cdbd3;}function _0x37e4e1(_0x17eea5,_0x1b24e3){const _0x3dd49a=_0x455a33;return parseInt(_0x17eea5['weight'])-parseInt(_0x1b24e3[_0x3dd49a('0x1df8')]);}function _0x196c6e(_0x15a752){const _0x5f5c30=_0x455a33;let _0x3b6acf='';return angular[_0x5f5c30('0x127')](_0x15a752[_0x5f5c30('0x2598')])&&(_0x3b6acf=_0x15a752[_0x5f5c30('0x2598')],angular[_0x5f5c30('0x127')](_0x15a752[_0x5f5c30('0x230a')])&&angular[_0x5f5c30('0x20b6')](_0x15a752[_0x5f5c30('0x230a')])&&(_0x3b6acf=_0x3b6acf+'('+angular[_0x5f5c30('0x1bf7')](_0x15a752[_0x5f5c30('0x230a')])+')')),_0x3b6acf;}this[_0x455a33('0x1862')]=function(){let _0x4acb33=null,_0x40505e=null,_0x432832=null,_0x5bc244=null;const _0x6e5fa5={'saveItem':_0x8283e7,'deleteItem':_0x1b5bc4,'sort':_0x35007e,'clearNavigation':_0x234f6c,'setActiveItem':_0x1b7bde,'getActiveItem':_0x429e2b,'getNavigation':_0x31ad1e,'getFlatNavigation':_0x4b0090,'setNavigationScope':_0x566d30,'setFolded':_0x490581,'getFolded':_0x17282f,'setFoldedOpen':_0x3bfb3e,'getFoldedOpen':_0x50905e,'toggleFolded':_0x3676ce};return _0x6e5fa5;function _0x234f6c(){const _0x5e6475=a0_0x4e0a;_0xeb0b09=[],_0x40505e&&(_0x40505e['vm'][_0x5e6475('0x21ad')]=_0xeb0b09);}function _0x1b7bde(_0x3f2df2,_0x1e9623){_0x4acb33={'node':_0x3f2df2,'scope':_0x1e9623};}function _0x429e2b(){return _0x4acb33;}function _0x31ad1e(_0x51e3d7){const _0x3c8a9e=a0_0x4e0a;if(_0x51e3d7){for(let _0x1e03e9=0x0;_0x1e03e9<_0xeb0b09[_0x3c8a9e('0x1564')];_0x1e03e9++){if(_0xeb0b09[_0x1e03e9][_0x3c8a9e('0x25e6')]===_0x51e3d7)return[_0xeb0b09[_0x1e03e9]];}return null;}return _0xeb0b09;}function _0x4b0090(_0x283f45){const _0x171143=_0x31ad1e(_0x283f45);return _0x440611(_0x171143);}function _0x566d30(_0x4ad52c){_0x40505e=_0x4ad52c;}function _0x490581(_0x23ff3f){_0x432832=_0x23ff3f;}function _0x17282f(){return _0x432832;}function _0x3bfb3e(_0x2861db){_0x5bc244=_0x2861db;}function _0x50905e(){return _0x5bc244;}function _0x3676ce(){const _0x2ec914=a0_0x4e0a;_0x40505e[_0x2ec914('0x20a8')]();}function _0x440611(_0x36442b){const _0x1fdf7b=a0_0x4e0a;let _0x2046b7=[];for(let _0x31e269=0x0;_0x31e269<_0x36442b['length'];_0x31e269++){const _0x16b072=angular['copy'](_0x36442b[_0x31e269]);_0x16b072[_0x1fdf7b('0x62')]=[],_0x2046b7[_0x1fdf7b('0x1fd0')](_0x16b072),_0x36442b[_0x31e269]['children'][_0x1fdf7b('0x1564')]>0x0&&(_0x2046b7=_0x2046b7[_0x1fdf7b('0x746')](_0x440611(_0x36442b[_0x31e269][_0x1fdf7b('0x62')])));}return _0x2046b7;}};}function _0x12674b(_0x212c97,_0x31edae){const _0x1e6446=_0x189033,_0x3bddf2=this;_0x212c97[_0x1e6446('0x1c7e')]?_0x3bddf2[_0x1e6446('0x21ad')]=_0x31edae[_0x1e6446('0x2bc')](_0x212c97['root']):_0x3bddf2['navigation']=_0x31edae['getNavigation']();_0x3bddf2[_0x1e6446('0xa83')]=_0x4b2078,_0x55ca31();function _0x55ca31(){_0x31edae['sort']();}function _0x4b2078(){const _0x31d2e8=_0x1e6446;angular['element']('body')[_0x31d2e8('0x7b8')](_0x31d2e8('0x193c'));}}function _0x4d2f0f(_0x221c7c,_0xd7f5e9,_0x36e200,_0x2efb16){return{'restrict':'E','scope':{'folded':'=','root':'@'},'controller':'MsNavigationController\x20as\x20vm','templateUrl':_0x16272c,'transclude':!![],'compile':function(_0x3c1f7d){const _0x3d71c0=a0_0x4e0a;return _0x3c1f7d[_0x3d71c0('0x81e')](_0x3d71c0('0x1403')),function _0x236fa9(_0x22088a,_0x211331){const _0x1f910a=_0x3d71c0,_0x38a90c=angular[_0x1f910a('0x1fcc')](_0x1f910a('0x18e5')),_0x309ae8=angular[_0x1f910a('0x1fcc')](_0x1f910a('0xd1b')),_0x3af01d=angular[_0x1f910a('0x1fcc')](_0x1f910a('0xa8a')),_0xf74026=_0x36e200(_0x1f910a('0x21ad'));_0x2efb16['setNavigationScope'](_0x22088a),_0x5a36c2();function _0x5a36c2(){const _0x343022=_0x1f910a;_0x2efb16[_0x343022('0x7d')]()===null&&_0x2efb16['setFolded'](_0x22088a[_0x343022('0x25df')]),_0x2efb16[_0x343022('0x7d')]()&&(_0xd7f5e9(function(){const _0x5a9148=_0x343022;_0x221c7c['$broadcast'](_0x5a9148('0x315'));}),_0x38a90c[_0x343022('0x81e')](_0x343022('0x6d3')),_0x526439());}_0x22088a[_0x1f910a('0x186d')](function(){return _0xf74026['isLockedOpen']();},function(_0x562bd2,_0x1f3a5c){const _0x379a0a=_0x1f910a;if(angular[_0x379a0a('0x105d')](_0x562bd2)||angular[_0x379a0a('0xa18')](_0x562bd2,_0x1f3a5c))return;const _0x2a6a24=_0x2efb16['getFolded']();if(_0x2a6a24){if(_0x562bd2)_0x221c7c[_0x379a0a('0x5ed')]('msNavigation::collapse');else{const _0xe6da39=_0x2efb16['getActiveItem']();_0xe6da39&&_0xe6da39[_0x379a0a('0x2090')][_0x379a0a('0x1b45')](_0x379a0a('0xf3e'));}}}),_0x22088a['$watch'](_0x1f910a('0x25df'),function(_0x2f5d4f,_0x47147c){const _0x582c15=_0x1f910a;if(angular[_0x582c15('0x105d')](_0x2f5d4f)||angular[_0x582c15('0xa18')](_0x2f5d4f,_0x47147c))return;_0x3547b0(_0x2f5d4f);});function _0x3547b0(_0x202011){const _0x5bf100=_0x1f910a;_0x2efb16[_0x5bf100('0x848')](_0x202011);if(_0x202011)_0x221c7c[_0x5bf100('0x5ed')](_0x5bf100('0x315')),_0x38a90c[_0x5bf100('0x81e')]('ms-navigation-folded'),_0x526439();else{const _0x5a9c2f=_0x2efb16[_0x5bf100('0x1ce8')]();_0x5a9c2f&&_0x5a9c2f[_0x5bf100('0x2090')][_0x5bf100('0x1b45')](_0x5bf100('0xf3e')),_0x38a90c[_0x5bf100('0x12a4')](_0x5bf100('0x8c7')),_0x4567a8();}}function _0x526439(){const _0x6f746f=_0x1f910a;_0x211331[_0x6f746f('0x2361')]()[_0x6f746f('0x22d6')](_0x309ae8),_0xd7f5e9(function(){const _0x216bb7=_0x6f746f;_0x309ae8['on'](_0x216bb7('0x130d'),_0x1ad701);});}function _0x99682f(){const _0x1ea8b6=_0x1f910a;_0x38a90c[_0x1ea8b6('0x1c07')](_0x1ea8b6('0xdbe'))[_0x1ea8b6('0x22d6')](_0x3af01d),_0x3af01d['on']('mouseenter\x20touchstart',_0x12b3ca);}function _0x4567a8(){const _0x504653=_0x1f910a;_0x3af01d[_0x504653('0x3ec')]();}function _0x1ad701(_0x361dfb){const _0x3fcecd=_0x1f910a;_0x361dfb&&_0x361dfb[_0x3fcecd('0x1706')]();_0x2efb16['setFoldedOpen'](!![]);const _0x15e4bb=_0x2efb16[_0x3fcecd('0x1ce8')]();_0x15e4bb&&_0x15e4bb[_0x3fcecd('0x2090')][_0x3fcecd('0x1b45')](_0x3fcecd('0xf3e')),_0x38a90c[_0x3fcecd('0x81e')](_0x3fcecd('0x3c7')),_0x309ae8[_0x3fcecd('0x3ec')](),_0x99682f();}function _0x12b3ca(_0x25d265){const _0x55d3f2=_0x1f910a;_0x25d265&&_0x25d265[_0x55d3f2('0x1706')](),_0x2efb16[_0x55d3f2('0x121a')](![]),_0x221c7c[_0x55d3f2('0x5ed')]('msNavigation::collapse'),_0x38a90c['removeClass'](_0x55d3f2('0x3c7')),_0x3af01d['remove'](),_0x526439();}_0x22088a['toggleFolded']=function(){const _0x5d1e7f=_0x1f910a,_0x3134b6=_0x2efb16[_0x5d1e7f('0x7d')]();_0x3547b0(!_0x3134b6);},_0x22088a[_0x1f910a('0x26a2')](_0x1f910a('0x1b20'),function(){const _0x2b24f1=_0x1f910a;_0xf74026[_0x2b24f1('0x12b0')]();}),_0x22088a[_0x1f910a('0x26a2')](_0x1f910a('0x4b8'),function(){const _0x1fe4ab=_0x1f910a;_0x3af01d[_0x1fe4ab('0x2422')]('mouseenter\x20touchstart'),_0x309ae8['off'](_0x1fe4ab('0x130d'));});};}};}function _0x35e728(_0x26328c,_0x25bf77,_0x19d9b2,_0x598980,_0x52e0fb,_0xb05392){const _0x3c79e7=_0x189033,_0x23e466=this;_0x23e466['element']=_0x25bf77,_0x23e466['node']=_0x26328c[_0x3c79e7('0x759')],_0x23e466[_0x3c79e7('0x1367')]=undefined,_0x23e466['collapsed']=undefined,_0x23e466[_0x3c79e7('0xc9c')]=undefined,_0x23e466[_0x3c79e7('0x980')]=undefined,_0x23e466[_0x3c79e7('0xba8')]=_0x3c79e7('0x12af'),_0x23e466[_0x3c79e7('0xc94')]=_0x20a90b,_0x23e466['collapse']=_0x457beb,_0x23e466[_0x3c79e7('0xf55')]=_0x24e5cd,_0x23e466[_0x3c79e7('0x203b')]=_0x4d26a2,_0x23e466[_0x3c79e7('0x268a')]=_0x42f67b,_0x35cdc3();function _0x35cdc3(){const _0x2eb876=_0x3c79e7;_0x23e466[_0x2eb876('0x1367')]=_0x23e466[_0x2eb876('0x759')][_0x2eb876('0x62')]['length']>0x0,_0x23e466[_0x2eb876('0x980')]=!!(angular[_0x2eb876('0x127')](_0x23e466[_0x2eb876('0x759')][_0x2eb876('0x980')])&&_0x23e466[_0x2eb876('0x759')][_0x2eb876('0x980')]===!![]);!_0x23e466[_0x2eb876('0x1367')]||_0x23e466['group']?_0x23e466['collapsable']=![]:_0x23e466[_0x2eb876('0xc9c')]=!!(angular[_0x2eb876('0x105d')](_0x23e466['node'][_0x2eb876('0xc9c')])||typeof _0x23e466['node'][_0x2eb876('0xc9c')]!=='boolean'||_0x23e466['node'][_0x2eb876('0xc9c')]===!![]);!_0x23e466['collapsable']?_0x23e466[_0x2eb876('0x1f9c')]=![]:_0x23e466[_0x2eb876('0x1f9c')]=!!(angular[_0x2eb876('0x105d')](_0x23e466[_0x2eb876('0x759')][_0x2eb876('0x1f9c')])||typeof _0x23e466[_0x2eb876('0x759')][_0x2eb876('0x1f9c')]!=='boolean'||_0x23e466[_0x2eb876('0x759')][_0x2eb876('0x1f9c')]===!![]);if(_0x23e466[_0x2eb876('0x759')][_0x2eb876('0x2598')]===_0x52e0fb['current'][_0x2eb876('0x60a')]||_0x52e0fb[_0x2eb876('0x2292')](_0x23e466[_0x2eb876('0x759')]['state'])){if(angular[_0x2eb876('0x127')](_0x23e466[_0x2eb876('0x759')][_0x2eb876('0x230a')])&&angular[_0x2eb876('0x127')](_0x52e0fb['params'])&&!angular['equals'](_0x23e466[_0x2eb876('0x759')][_0x2eb876('0x230a')],_0x52e0fb[_0x2eb876('0x7f2')]))return;_0x26328c[_0x2eb876('0x1b45')](_0x2eb876('0xf3e')),_0xb05392['setActiveItem'](_0x23e466[_0x2eb876('0x759')],_0x26328c);}_0x26328c[_0x2eb876('0x26a2')](_0x2eb876('0xf3e'),function(){const _0x21ff26=_0x2eb876;_0x23e466[_0x21ff26('0xc9c')]&&_0x23e466[_0x21ff26('0x1f9c')]&&_0x26328c[_0x21ff26('0x1ed5')](function(){_0x23e466['collapsed']=![];});}),_0x26328c[_0x2eb876('0x26a2')](_0x2eb876('0x315'),function(_0x3166cb,_0x5548dd){const _0x1caa19=_0x2eb876;if(_0x23e466[_0x1caa19('0x1f9c')]||!_0x23e466[_0x1caa19('0xc9c')])return;if(angular[_0x1caa19('0x105d')](_0x5548dd))_0x23e466[_0x1caa19('0x25bc')]();else{const _0x3ed163=_0x5548dd['split']('.');let _0x207e80=[];const _0x1e780a=_0xb05392[_0x1caa19('0x1ce8')]();_0x1e780a&&(_0x207e80=_0x1e780a[_0x1caa19('0x759')][_0x1caa19('0xc3e')][_0x1caa19('0x1fc5')]('.'));if(_0x3ed163[_0x1caa19('0x824')](_0x23e466[_0x1caa19('0x759')][_0x1caa19('0x25e6')])>-0x1)return;if(_0x207e80[_0x1caa19('0x824')](_0x23e466['node'][_0x1caa19('0x25e6')])>-0x1)return;_0x23e466[_0x1caa19('0x25bc')]();}}),_0x26328c[_0x2eb876('0x26a2')](_0x2eb876('0x1514'),function(){const _0x928ca2=_0x2eb876;if(_0x23e466[_0x928ca2('0x759')][_0x928ca2('0x2598')]===_0x52e0fb[_0x928ca2('0xb24')][_0x928ca2('0x60a')]){if(angular[_0x928ca2('0x127')](_0x23e466[_0x928ca2('0x759')][_0x928ca2('0x230a')])&&angular[_0x928ca2('0x127')](_0x52e0fb[_0x928ca2('0x7f2')])&&!angular['equals'](_0x23e466[_0x928ca2('0x759')][_0x928ca2('0x230a')],_0x52e0fb[_0x928ca2('0x7f2')]))return;_0xb05392[_0x928ca2('0x20c3')](_0x23e466[_0x928ca2('0x759')],_0x26328c),_0x19d9b2[_0x928ca2('0x5ed')](_0x928ca2('0x315'),_0x23e466[_0x928ca2('0x759')][_0x928ca2('0xc3e')]);}if(_0x52e0fb[_0x928ca2('0x2292')](_0x23e466[_0x928ca2('0x759')][_0x928ca2('0x2598')])){if(angular['isDefined'](_0x23e466[_0x928ca2('0x759')][_0x928ca2('0x230a')])&&angular[_0x928ca2('0x127')](_0x52e0fb[_0x928ca2('0x7f2')])&&!angular[_0x928ca2('0xa18')](_0x23e466[_0x928ca2('0x759')][_0x928ca2('0x230a')],_0x52e0fb[_0x928ca2('0x7f2')]))return;_0x26328c[_0x928ca2('0x1b45')](_0x928ca2('0xf3e'));}});}function _0x20a90b(){const _0x1d4e0e=_0x3c79e7;_0x23e466['collapsed']?_0x23e466[_0x1d4e0e('0xf55')]():_0x23e466[_0x1d4e0e('0x25bc')]();}function _0x457beb(){const _0x254a51=_0x3c79e7,_0x44b045=_0x23e466[_0x254a51('0x1fcc')][_0x254a51('0x62')]('ul'),_0x909a67=_0x44b045[0x0][_0x254a51('0x1eef')];_0x26328c[_0x254a51('0x1ed5')](function(){const _0x483b71=_0x254a51;_0x23e466[_0x483b71('0x1f9c')]=!![],_0x23e466[_0x483b71('0x1fcc')]['addClass'](_0x483b71('0x2536')),_0x598980['animate'](_0x44b045,{'display':_0x483b71('0x3cd'),'height':_0x909a67+'px'},{'height':_0x483b71('0x907')},_0x23e466['animateHeightClass'])[_0x483b71('0x683')](function(){const _0x2b2d94=_0x483b71;_0x44b045[_0x2b2d94('0x1e78')]({'display':'','height':''}),_0x23e466[_0x2b2d94('0x1fcc')][_0x2b2d94('0x12a4')](_0x2b2d94('0x2536'));}),_0x26328c[_0x483b71('0x5ed')]('msNavigation::collapse');});}function _0x24e5cd(){const _0x407e96=_0x3c79e7,_0x1c690c=_0x23e466['element'][_0x407e96('0x62')]('ul');_0x1c690c[_0x407e96('0x1e78')]({'position':'absolute','visibility':'hidden','display':_0x407e96('0x3cd'),'height':_0x407e96('0x8c5')});const _0x23ecf7=_0x1c690c[0x0]['offsetHeight'];_0x1c690c['css']({'position':'','visibility':'','display':'','height':''}),_0x26328c[_0x407e96('0x1ed5')](function(){const _0x43b782=_0x407e96;_0x23e466['collapsed']=![],_0x23e466['element'][_0x43b782('0x81e')]('expanding'),_0x598980[_0x43b782('0x1219')](_0x1c690c,{'display':_0x43b782('0x3cd'),'height':_0x43b782('0x907')},{'height':_0x23ecf7+'px'},_0x23e466[_0x43b782('0xba8')])[_0x43b782('0x683')](function(){const _0x718eee=_0x43b782;_0x1c690c[_0x718eee('0x1e78')]({'height':''}),_0x23e466['element'][_0x718eee('0x12a4')]('expanding');}),_0x19d9b2[_0x43b782('0x5ed')](_0x43b782('0x315'),_0x23e466[_0x43b782('0x759')][_0x43b782('0xc3e')]);});}function _0x4d26a2(){const _0x246b7c=_0x3c79e7;return _0x23e466[_0x246b7c('0x759')][_0x246b7c('0x1364')];}function _0x42f67b(){const _0x2f34b8=_0x3c79e7;if(angular['isDefined'](_0x23e466['node'][_0x2f34b8('0x1fb4')])&&angular[_0x2f34b8('0x93f')](_0x23e466[_0x2f34b8('0x759')][_0x2f34b8('0x1fb4')]))return _0x23e466['node']['hidden']();return![];}}function _0x175145(){const _0x5a3bdd=_0x189033;return{'restrict':'A','bindToController':{'node':_0x5a3bdd('0x2258')},'controller':_0x5a3bdd('0x12f0'),'compile':function(_0x17d1c3){const _0xa9f6e8=_0x5a3bdd;return _0x17d1c3[_0xa9f6e8('0x81e')](_0xa9f6e8('0x135b')),function _0x5901e7(_0x4bd38b,_0x5a0d33,_0x5a62d9,_0x124dbb){const _0x24e9dc=_0xa9f6e8;_0x5a0d33[_0x24e9dc('0x81e')](_0x124dbb[_0x24e9dc('0x203b')]()),_0x124dbb[_0x24e9dc('0x980')]&&_0x5a0d33['addClass'](_0x24e9dc('0x980'));};}};}function _0x51c6aa(){return{'restrict':'A','require':'^msNavigationNode','compile':function(_0x1a8b70){const _0x2b3900=a0_0x4e0a;return _0x1a8b70['addClass'](_0x2b3900('0x1334')),function _0x38fe70(_0x429acd,_0x22e11b,_0x4564ff,_0x2d86f0){const _0x204a9c=_0x2b3900;_0x2d86f0[_0x204a9c('0xc9c')]&&_0x22e11b['on'](_0x204a9c('0x1d42'),_0x2d86f0[_0x204a9c('0xc94')]),_0x429acd[_0x204a9c('0x26a2')](_0x204a9c('0x4b8'),function(){const _0x356033=_0x204a9c;_0x22e11b[_0x356033('0x2422')](_0x356033('0x1d42'));});};}};}function _0x193a83(_0x23625f){const _0x497a96=_0x189033;return{'restrict':'E','scope':{'root':'@'},'controller':_0x497a96('0x276c'),'templateUrl':_0x405a14,'transclude':!![],'compile':function(_0x41fc94){const _0x3abb38=_0x497a96;return _0x41fc94['addClass'](_0x3abb38('0xa96')),function _0x15c325(_0x53dad4){const _0xb76bca=_0x3abb38;_0x23625f[_0xb76bca('0x3e1')](_0x53dad4);};}};}function _0x39243c(_0x417292,_0x596d5d,_0xfecef8,_0x3be7b8,_0x1b0bed){const _0x3e9ea5=_0x189033,_0x1f594f=this;_0x1f594f[_0x3e9ea5('0x1fcc')]=_0x596d5d,_0x1f594f['node']=_0x417292[_0x3e9ea5('0x759')],_0x1f594f['hasChildren']=undefined,_0x1f594f[_0x3e9ea5('0x980')]=undefined,_0x1f594f[_0x3e9ea5('0x203b')]=_0x559c46,_0x1e4698();function _0x1e4698(){const _0x496bce=_0x3e9ea5;_0x1f594f['isActive']=![],_0x1f594f[_0x496bce('0x1367')]=_0x1f594f['node'][_0x496bce('0x62')][_0x496bce('0x1564')]>0x0,_0x1f594f[_0x496bce('0x980')]=!!(angular[_0x496bce('0x127')](_0x1f594f[_0x496bce('0x759')][_0x496bce('0x980')])&&_0x1f594f[_0x496bce('0x759')][_0x496bce('0x980')]===!![]);if(_0x1f594f[_0x496bce('0x759')][_0x496bce('0x2598')]===_0x3be7b8[_0x496bce('0xb24')][_0x496bce('0x60a')]||_0x3be7b8['includes'](_0x1f594f[_0x496bce('0x759')][_0x496bce('0x2598')])){if(angular['isDefined'](_0x1f594f[_0x496bce('0x759')]['stateParams'])&&angular[_0x496bce('0x127')](_0x3be7b8[_0x496bce('0x7f2')])&&!angular[_0x496bce('0xa18')](_0x1f594f[_0x496bce('0x759')][_0x496bce('0x230a')],_0x3be7b8['params']))return;_0x417292[_0x496bce('0x1b45')](_0x496bce('0xf3e')),_0x1b0bed['setActiveItem'](_0x1f594f[_0x496bce('0x759')],_0x417292);}_0x417292[_0x496bce('0x26a2')](_0x496bce('0xf3e'),function(){const _0x4590a3=_0x496bce;_0x1f594f[_0x4590a3('0x1367')]&&_0x417292[_0x4590a3('0x1ed5')](function(){const _0x4208e4=_0x4590a3;_0x1f594f[_0x4208e4('0x16cd')]=!![];});}),_0x417292[_0x496bce('0x26a2')](_0x496bce('0x259a'),function(){const _0xac6496=_0x496bce;if(!_0x1f594f['hasChildren'])return;let _0x5bb873=[];const _0x47102e=_0x1b0bed[_0xac6496('0x1ce8')]();_0x47102e&&(_0x5bb873=_0x47102e[_0xac6496('0x759')]['_path'][_0xac6496('0x1fc5')]('.')),_0x5bb873[_0xac6496('0x824')](_0x1f594f[_0xac6496('0x759')][_0xac6496('0x25e6')])>-0x1?_0x417292[_0xac6496('0x1ed5')](function(){_0x1f594f['isActive']=!![];}):_0x417292['$evalAsync'](function(){const _0x5b7228=_0xac6496;_0x1f594f[_0x5b7228('0x16cd')]=![];});}),_0x417292[_0x496bce('0x26a2')](_0x496bce('0x1514'),function(){const _0xbe1c14=_0x496bce;if(_0x1f594f['node'][_0xbe1c14('0x2598')]===_0x3be7b8['current'][_0xbe1c14('0x60a')]||_0x3be7b8[_0xbe1c14('0x2292')](_0x1f594f['node']['state'])){if(angular[_0xbe1c14('0x127')](_0x1f594f[_0xbe1c14('0x759')][_0xbe1c14('0x230a')])&&angular['isDefined'](_0x3be7b8[_0xbe1c14('0x7f2')])&&!angular[_0xbe1c14('0xa18')](_0x1f594f[_0xbe1c14('0x759')]['stateParams'],_0x3be7b8['params']))return;_0x1b0bed[_0xbe1c14('0x20c3')](_0x1f594f[_0xbe1c14('0x759')],_0x417292),_0xfecef8[_0xbe1c14('0x5ed')](_0xbe1c14('0x259a'));}});}function _0x559c46(){const _0x38ade4=_0x3e9ea5;return _0x1f594f['node'][_0x38ade4('0x1364')];}}function _0x11040f(){const _0x458e93=_0x189033;return{'restrict':'A','bindToController':{'node':_0x458e93('0x1e4e')},'controller':_0x458e93('0x21c2'),'compile':function(_0x113f1f){const _0x269712=_0x458e93;return _0x113f1f[_0x269712('0x81e')](_0x269712('0x18aa')),function _0x1b6b82(_0x2471f2,_0x4c379d,_0x4cca55,_0x41efde){const _0x8e246b=_0x269712;_0x4c379d[_0x8e246b('0x81e')](_0x41efde[_0x8e246b('0x203b')]()),_0x41efde[_0x8e246b('0x980')]&&_0x4c379d[_0x8e246b('0x81e')](_0x8e246b('0x980'));};}};}function _0x94496d(_0x2024d2){const _0x2fc70f=_0x189033;return{'restrict':'A','require':_0x2fc70f('0x1b90'),'compile':function(_0x4fa99f){const _0x396b75=_0x2fc70f;return _0x4fa99f[_0x396b75('0x81e')](_0x396b75('0x1e1c')),function _0x57162d(_0x54557a,_0x32df1c,_0x5d0967,_0x4c278d){const _0x461ac4=_0x396b75;_0x32df1c['on'](_0x461ac4('0x1d42'),_0x116829);function _0x116829(){const _0x13a2b9=_0x461ac4;if(!_0x4c278d[_0x13a2b9('0x1367')]||_0x2024d2(_0x13a2b9('0x13ac')))return;_0x32df1c[_0x13a2b9('0x7b8')]('expanded');}_0x54557a[_0x461ac4('0x26a2')](_0x461ac4('0x4b8'),function(){const _0x47eda0=_0x461ac4;_0x32df1c[_0x47eda0('0x2422')](_0x47eda0('0x1d42'));});};}};}const _0x24023a=_0x180212['p']+_0x189033('0xdb'),_0x4c9c5e=_0x180212['p']+_0x189033('0x481'),_0x5c6605=_0x180212['p']+'src/js/modules/core/directives/ms-phonebar/settings/settings.html/settings.html',_0x3180b5=_0x180212['p']+'src/js/modules/core/directives/ms-phonebar/ms-phonebar.html/ms-phonebar.html';var _0x56b634=_0x180212(0x175b),_0x40acba=_0x180212['n'](_0x56b634),_0x255f6e=_0x180212(0x26ba),_0x2d0c15=_0x180212['n'](_0x255f6e);_0x23bff7[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$document',_0x189033('0x2f9'),_0x189033('0x1b27'),_0x189033('0x1e48'),'$mdToast','$window',_0x189033('0x1d08'),_0x189033('0x20a3'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x1d41'),_0x189033('0xba1'),_0x189033('0x1556')];function _0x23bff7(_0x37071d,_0x32b328,_0x1d7365,_0x44a12b,_0x13c8d7,_0x7fc7b,_0x166821,_0x53cec9,_0x453c18,_0x1b4571,_0x59fbc4,_0x45cb54,_0x1e2185,_0x4f8a6c){const _0x55312f=_0x189033,_0x83c397=this,_0x5b47e8=window['jabra'];_0x83c397[_0x55312f('0x2713')]=_0x59fbc4[_0x55312f('0x2713')],_0x83c397[_0x55312f('0x1f4a')]=_0x37071d[_0x55312f('0x1cd5')]['vm'][_0x55312f('0x1f4a')];const _0x21b674=[_0x55312f('0x1eac'),'speakerId',_0x55312f('0x1dd6'),'ringingVolume','speakerVolume',_0x55312f('0xd13'),_0x55312f('0x13eb'),_0x55312f('0x1e34'),'microphoneMute'],_0x2e43f8=_0x83c397[_0x55312f('0x1f4a')]&&JSON[_0x55312f('0x1f34')](_0x166821[_0x55312f('0x120e')][_0x55312f('0x1b28')](_0x55312f('0x2ae')+_0x83c397[_0x55312f('0x1f4a')]['id']))||{'webrtc':{'ringingVolume':0.5,'speakerVolume':0.5,'microphoneVolume':0x1,'ringingMute':![],'speakerMute':![],'microphoneMute':![]}};_0x44a12b(function(){},0x3e7),_0x83c397[_0x55312f('0x2655')]=_0x55312f('0x20b1'),_0x83c397[_0x55312f('0xad9')]=_0x55312f('0x654'),_0x83c397[_0x55312f('0x568')]='',_0x83c397['showDialpad']=![],_0x83c397['soundPlayer']=document[_0x55312f('0x1ffa')](_0x55312f('0x9b5')),_0x83c397[_0x55312f('0x20eb')]=document[_0x55312f('0x1759')](_0x83c397[_0x55312f('0x1f4a')]['remotePlayerId']),_0x83c397[_0x55312f('0x2797')][_0x55312f('0x2a4')]=0x1,_0x83c397[_0x55312f('0x1731')]={'mediaConstraints':{'audio':!![],'video':![]},'pcConfig':{'iceServers':[]}},_0x83c397[_0x55312f('0x2be')]=[],_0x83c397['calls']=[],_0x83c397['callbackQueue']=[],_0x83c397[_0x55312f('0x155a')]=![],_0x83c397[_0x55312f('0x1dc0')]=![],_0x83c397[_0x55312f('0x20a')]=[],_0x83c397['ua']=new(_0x40acba())['UA']({'sockets':[new(_0x40acba())[(_0x55312f('0x78a'))](_0x55312f('0x26fb')+_0x83c397[_0x55312f('0x1f4a')]['host']+_0x55312f('0x7aa'))],'uri':new(_0x40acba())[(_0x55312f('0xecc'))](_0x55312f('0x54c'),_0x83c397[_0x55312f('0x1f4a')][_0x55312f('0x60a')],_0x83c397[_0x55312f('0x1f4a')][_0x55312f('0x19ac')],0x13c4,null,null)['toString'](),'authorization_user':_0x83c397[_0x55312f('0x1f4a')][_0x55312f('0x60a')],'ha1':_0x83c397['conf']['ha1'],'realm':_0x83c397[_0x55312f('0x1f4a')][_0x55312f('0x2531')],'user_agent':_0x83c397['conf']['ua'],'session_timers_refresh_method':_0x55312f('0x1724'),'register_expires':_0x83c397[_0x55312f('0x1f4a')]['phoneBarExpires']||0x3c,'register':!![]}),_0x83c397['conf']=_0x2e3ca0()[_0x55312f('0xf22')](_0x2e43f8[_0x55312f('0xd04')],_0x83c397[_0x55312f('0x1f4a')]),_0x83c397[_0x55312f('0x25dc')]=![],_0x83c397[_0x55312f('0x2021')]=![],_0x83c397[_0x55312f('0x1a81')]=![],_0x83c397[_0x55312f('0x42f')]=null,_0x83c397[_0x55312f('0x1f83')]=![],_0x83c397[_0x55312f('0x1f6d')]=![],_0x83c397[_0x55312f('0x12')]=![];function _0x11e16e(){const _0x35ad50=_0x55312f;_0x33efaf(![]),navigator['mediaDevices'][_0x35ad50('0xff6')]=function(){const _0x5f407f=_0x35ad50;!_0x83c397['initDeviceInProgress']&&(_0x83c397[_0x5f407f('0x25dc')]=!![],_0x5b47e8&&_0x83c397[_0x5f407f('0x1a81')]?_0x5b47e8[_0x5f407f('0x10c8')]()[_0x5f407f('0x683')](function(){const _0x4e72c2=_0x5f407f;_0x83c397[_0x4e72c2('0x1a81')]=![],_0x83c397['isJabraEnabled']=![],_0x33efaf(!![]);})['catch'](function(_0x576991){const _0x4c1244=_0x5f407f;console[_0x4c1244('0x52a')](_0x4c1244('0x10bd'),_0x576991);}):_0x33efaf(!![]));};const _0xf6ce60=[_0x59fbc4[_0x35ad50('0x18f6')][_0x35ad50('0x1e6e')]({'type':_0x35ad50('0x83e'),'nolimit':!![]})[_0x35ad50('0xe53')],_0x59fbc4[_0x35ad50('0x18f6')][_0x35ad50('0x1e6e')]({'type':_0x35ad50('0x1d22'),'nolimit':!![]})['$promise']];Promise['all'](_0xf6ce60)[_0x35ad50('0x683')](function(_0x10dfd0){const _0x7467b6=_0x35ad50,_0x37a7e3=_0x10dfd0[0x0]['rows'],_0x642d14=_0x10dfd0[0x1][_0x7467b6('0xf5d')],_0x3e8b4e=[],_0x6e48c7=[];_0x642d14[_0x7467b6('0x1299')](function(_0x1f17b5){const _0xe4f000=_0x7467b6;_0x6e48c7[_0xe4f000('0x1fd0')](_0xe4f000('0x21db')+_0x1f17b5['value']);}),_0x3e8b4e[_0x7467b6('0x1fd0')]({'urls':_0x6e48c7}),_0x37a7e3[_0x7467b6('0x1299')](function(_0x555559){const _0x230011=_0x7467b6,_0x3e484b={'urls':_0x230011('0x48')+_0x555559[_0x230011('0x1c6b')]};_0x555559['username']&&(_0x3e484b['username']=_0x555559[_0x230011('0x1733')]),_0x555559[_0x230011('0x1e96')]&&(_0x3e484b[_0x230011('0x5d2')]=_0x555559['password']),_0x3e8b4e[_0x230011('0x1fd0')](_0x3e484b);}),_0x83c397['sessionConf'][_0x7467b6('0x1d3')]={'iceServers':_0x3e8b4e};}),this['ua']['on'](_0x35ad50('0xc1f'),_0x178a4e['bind'](this)),this['ua']['on'](_0x35ad50('0x4fb'),_0x8e6b6b['bind'](this)),this['ua']['on'](_0x35ad50('0x2116'),_0x1966f0[_0x35ad50('0xb86')](this)),_0x4f8a6c['on'](_0x35ad50('0x19aa'),_0x129388[_0x35ad50('0xb86')](this)),_0x4f8a6c['on'](_0x35ad50('0x140'),_0x1c33c3[_0x35ad50('0xb86')](this)),_0x4f8a6c['on'](_0x35ad50('0x2b3'),_0x458255['bind'](this)),_0x4f8a6c['on'](_0x35ad50('0x1e3e'),_0x2fe495[_0x35ad50('0xb86')](this)),_0x4f8a6c['on'](_0x35ad50('0x10f8'),_0x305840[_0x35ad50('0xb86')](this)),_0x4f8a6c['on']('webbar:transfer',_0x19f5f8[_0x35ad50('0xb86')](this));}function _0x33efaf(_0x47744f){const _0xfb7910=_0x55312f;let _0x46c5b1,_0x2535d8,_0x4de399;return _0x83c397[_0xfb7910('0x25dc')]=!![],navigator[_0xfb7910('0x2230')][_0xfb7910('0x1b1e')]({'audio':!![]})[_0xfb7910('0x683')](function(_0x57696c){const _0x1e8ada=_0xfb7910;return _0x57696c['getTracks']()[_0x1e8ada('0x1299')](function(_0x366a8e){const _0x1a5fd6=_0x1e8ada;_0x366a8e[_0x1a5fd6('0x19cc')]();}),navigator[_0x1e8ada('0x2230')][_0x1e8ada('0x186c')]();})[_0xfb7910('0x683')](function(_0x590352){const _0x359f67=_0xfb7910,_0x5491a8=_0x2e3ca0()['filter'](_0x590352,function(_0x198e36){const _0x30348f=a0_0x4e0a;return _0x198e36['kind']===_0x30348f('0x1bd7')&&_0x198e36[_0x30348f('0x1e16')]!==_0x30348f('0x9cb')&&_0x198e36[_0x30348f('0x1e16')]!==_0x30348f('0xf4c');});if(_0x5491a8['length']>0x0){const _0x41441a=_0x2e3ca0()[_0x359f67('0x1c07')](_0x590352,function(_0xf0c8ba){const _0x56fd8e=_0x359f67;return _0xf0c8ba['deviceId']===_0x56fd8e('0x9cb')&&_0xf0c8ba[_0x56fd8e('0x17c')]===_0x56fd8e('0x1bd7');});_0x4de399=_0x2e3ca0()['find'](_0x5491a8,function(_0x361fcf){const _0x1b949a=_0x359f67;return _0x361fcf['groupId']===_0x41441a[_0x1b949a('0x2460')];});if(_0x83c397[_0x359f67('0x1f4a')]['microphoneId']&&!_0x47744f){const _0x4ac6a6=_0x2e3ca0()[_0x359f67('0x1c07')](_0x5491a8,function(_0xb85ee9){const _0x374028=_0x359f67;return _0xb85ee9[_0x374028('0x1e16')]===_0x83c397[_0x374028('0x1f4a')][_0x374028('0x1dd6')];});_0x4ac6a6&&(_0x4de399=_0x4ac6a6);}_0x83c397[_0x359f67('0x1f4a')][_0x359f67('0x1dd6')]=_0x4de399[_0x359f67('0x1e16')];}else _0x1b4571['warning']({'title':_0x53cec9['instant'](_0x359f67('0x238f')),'msg':_0x53cec9[_0x359f67('0x2728')]('TOOLBAR.WEBRTC_MICROPHONE_NOT_AVAILABLE'),'clickToClose':!![],'showClose':!![],'shake':![],'timeout':![],'position':_0x359f67('0x235b')});_0x83c397['conf'][_0x359f67('0x1dd6')]?_0x83c397[_0x359f67('0x1731')][_0x359f67('0x7ff')][_0x359f67('0x9b5')]={'deviceId':_0x83c397[_0x359f67('0x1f4a')]['microphoneId']}:_0x83c397[_0x359f67('0x1731')][_0x359f67('0x7ff')][_0x359f67('0x9b5')]=!![];_0xc36c2f(_0x359f67('0x3fa'),![]);const _0x5129f6=_0x2e3ca0()[_0x359f67('0x25')](_0x590352,function(_0x1d33b2){const _0x3e1218=_0x359f67;return _0x1d33b2[_0x3e1218('0x17c')]===_0x3e1218('0x1388')&&_0x1d33b2[_0x3e1218('0x1e16')]!=='default'&&_0x1d33b2[_0x3e1218('0x1e16')]!=='communications';});if(_0x5129f6[_0x359f67('0x1564')]>0x0){const _0xe61ce8=_0x2e3ca0()[_0x359f67('0x1c07')](_0x590352,function(_0x42c076){const _0x1a314a=_0x359f67;return _0x42c076[_0x1a314a('0x1e16')]==='default'&&_0x42c076[_0x1a314a('0x17c')]===_0x1a314a('0x1388');});_0x46c5b1=_0x2e3ca0()[_0x359f67('0x1c07')](_0x5129f6,function(_0x28c01f){const _0x2fe7e6=_0x359f67;return _0x28c01f[_0x2fe7e6('0x2460')]===_0xe61ce8[_0x2fe7e6('0x2460')];}),_0x2535d8=_0x46c5b1;if(_0x83c397[_0x359f67('0x1f4a')][_0x359f67('0x902')]&&!_0x47744f){const _0x17d608=_0x2e3ca0()[_0x359f67('0x1c07')](_0x5129f6,function(_0x286713){const _0x536eef=_0x359f67;return _0x286713[_0x536eef('0x1e16')]===_0x83c397[_0x536eef('0x1f4a')][_0x536eef('0x902')];});_0x17d608&&(_0x2535d8=_0x17d608);}_0x83c397['conf']['speakerId']=_0x2535d8[_0x359f67('0x1e16')];if(_0x83c397[_0x359f67('0x1f4a')][_0x359f67('0x1eac')]&&!_0x47744f){const _0x364f54=_0x2e3ca0()['find'](_0x5129f6,function(_0x499f4e){const _0x33bf3a=_0x359f67;return _0x499f4e[_0x33bf3a('0x1e16')]===_0x83c397[_0x33bf3a('0x1f4a')][_0x33bf3a('0x1eac')];});_0x364f54&&(_0x46c5b1=_0x364f54);}_0x83c397[_0x359f67('0x1f4a')][_0x359f67('0x1eac')]=_0x46c5b1[_0x359f67('0x1e16')];}else _0x1b4571[_0x359f67('0xd33')]({'title':_0x53cec9[_0x359f67('0x2728')](_0x359f67('0x238f')),'msg':_0x53cec9['instant'](_0x359f67('0x12d9')),'clickToClose':!![],'showClose':!![],'shake':![],'timeout':![],'position':_0x359f67('0x235b')});return _0xc36c2f('speaker',![]);})['then'](function(){const _0x527bd8=_0xfb7910;return _0xc36c2f(_0x527bd8('0x2727'),![]);})[_0xfb7910('0x683')](function(){const _0x5b4a9a=_0xfb7910;if(_0x5b47e8)return _0x5b47e8['init']()[_0x5b4a9a('0x683')](function(){const _0x18e2f5=_0x5b4a9a;return _0x83c397[_0x18e2f5('0x1a81')]=!![],_0x5b47e8[_0x18e2f5('0xc85')]();})[_0x5b4a9a('0x683')](function(){const _0x18800b=_0x5b4a9a;return _0x5b47e8[_0x18800b('0x1c53')]();})[_0x5b4a9a('0x683')](function(_0x1a319b){const _0x595bde=_0x5b4a9a;_0x4de399&&_0x2535d8&&_0x46c5b1&&_0x1a319b&&(_0x2e3ca0()[_0x595bde('0x2292')]([_0x4de399[_0x595bde('0x2460')],_0x2535d8[_0x595bde('0x2460')],_0x46c5b1[_0x595bde('0x2460')]],_0x1a319b[_0x595bde('0x1254')][_0x595bde('0x24ca')])&&(console[_0x595bde('0x1b2b')]('Jabra\x20library\x20correctly\x20initialized\x20and\x20device\x20correctly\x20installed'),_0x83c397[_0x595bde('0x2021')]=!![],_0x5b47e8[_0x595bde('0x1ecd')](),_0x5b47e8[_0x595bde('0x1032')]('acceptcall',_0x2261ef[_0x595bde('0xb86')](this)),_0x5b47e8[_0x595bde('0x1032')](_0x595bde('0x165c'),_0x3cbb06[_0x595bde('0xb86')](this)),_0x5b47e8[_0x595bde('0x1032')]('unmute',_0x366efa['bind'](this)),_0x5b47e8[_0x595bde('0x1032')](_0x595bde('0x23f6'),_0x192b1d[_0x595bde('0xb86')](this)),_0x5b47e8[_0x595bde('0x1032')]('endcall',_0x557fd2[_0x595bde('0xb86')](this))));})[_0x5b4a9a('0x130a')](function(_0x4e2ec0){const _0x5d197a=_0x5b4a9a;console['warn'](_0x5d197a('0x1f2a'),_0x4e2ec0);});})[_0xfb7910('0x130a')](function(_0x1d0704){const _0x4f980a=_0xfb7910;console['error'](_0x4f980a('0x2302'),_0x1d0704),_0x1d0704[_0x4f980a('0x60a')]===_0x4f980a('0x2348')&&_0x1b4571['warning']({'title':_0x53cec9[_0x4f980a('0x2728')](_0x4f980a('0x238f')),'msg':_0x53cec9[_0x4f980a('0x2728')]('TOOLBAR.WEBRTC_AUDIO_DEVICES_NOT_AVAILABLE'),'clickToClose':!![],'showClose':!![],'shake':![],'timeout':![],'position':_0x4f980a('0x235b')});})['finally'](function(){const _0x7f574a=_0xfb7910;_0x83c397['initDeviceInProgress']=![],_0x3766a2(),_0x2d0c15()['load'](_0x4aa411[_0x7f574a('0xb86')](this));});}function _0x2261ef(_0x108933){const _0x1351f3=_0x55312f,_0x3ef031=_0x2e3ca0()['last'](_0x83c397[_0x1351f3('0x2be')]);_0x3ef031?_0x3ef031[_0x1351f3('0x2655')]==='incoming'&&_0x3ef031['isInProgress']()?_0x83c397[_0x1351f3('0x1767')](_0x3ef031):console['error'](_0x1351f3('0x1f10'),_0x108933):console[_0x1351f3('0x52a')]('Unable\x20to\x20answer\x20the\x20call',_0x108933);}function _0x3cbb06(){const _0x2d7aea=_0x55312f;_0x83c397['conf'][_0x2d7aea('0x16e9')]=!![],_0xc36c2f(_0x2d7aea('0x3fa'),!![]);}function _0x366efa(){const _0x3a5137=_0x55312f;_0x83c397['conf'][_0x3a5137('0x16e9')]=![],_0xc36c2f(_0x3a5137('0x3fa'),!![]);}function _0x192b1d(){const _0x5cbbed=_0x55312f;_0x83c397['jabraSession']['localHold']?_0x83c397[_0x5cbbed('0x641')](_0x83c397[_0x5cbbed('0x42f')]):_0x83c397['hold'](_0x83c397[_0x5cbbed('0x42f')]);}function _0x557fd2(){const _0x2d0fac=_0x55312f;_0x48e330()[_0x2d0fac('0x683')](function(_0x151ed4){const _0x3a970d=_0x2d0fac;_0x151ed4!==null&&_0x83c397[_0x3a970d('0x1a66')](_0x151ed4);});}function _0x3766a2(){const _0x452d32=_0x55312f;_0x2e43f8[_0x452d32('0xd04')]=_0x2e3ca0()[_0x452d32('0x24d0')](_0x83c397['conf'],_0x21b674),_0x166821[_0x452d32('0x120e')]['setItem'](_0x452d32('0x2ae')+_0x83c397[_0x452d32('0x1f4a')]['id'],JSON[_0x452d32('0x258a')](_0x2e43f8));}function _0x178a4e(){const _0x44436a=_0x55312f;this[_0x44436a('0xc1f')]=!![];}function _0x8e6b6b(){this['registered']=![];}function _0x4aa411(){const _0x53b18b=_0x55312f;_0x83c397[_0x53b18b('0x1f4a')][_0x53b18b('0x23e0')]=_0x2d0c15()[_0x53b18b('0x23e0')],_0x83c397[_0x53b18b('0x1f4a')]['hasSpeakers']=_0x2d0c15()[_0x53b18b('0x47d')]['name']===_0x53b18b('0x123')||_0x2d0c15()[_0x53b18b('0x47d')][_0x53b18b('0x60a')]===_0x53b18b('0x25f')||_0x2d0c15()['browser'][_0x53b18b('0x60a')]===_0x53b18b('0x1344')?_0x2d0c15()[_0x53b18b('0x2765')]:!![],_0x83c397[_0x53b18b('0x1f4a')][_0x53b18b('0x992')]=_0x2d0c15()['isWebRTCSupported'],_0x83c397[_0x53b18b('0x1f4a')][_0x53b18b('0x1b2c')]=_0x2d0c15()['osName'],_0x83c397[_0x53b18b('0x1f4a')][_0x53b18b('0xc14')]=_0x2d0c15()[_0x53b18b('0xc14')],_0x83c397[_0x53b18b('0x1f4a')][_0x53b18b('0x1a84')]=_0x2d0c15()[_0x53b18b('0x47d')][_0x53b18b('0x60a')],_0x83c397[_0x53b18b('0x1f4a')][_0x53b18b('0x4a9')]=_0x2d0c15()['browser'][_0x53b18b('0x729')];if(_0x4e7a99())!_0x83c397['register']&&_0x83c397['ua'][_0x53b18b('0x1ccd')]();else!_0x83c397[_0x53b18b('0x1f4a')][_0x53b18b('0xace')]&&_0x1b4571[_0x53b18b('0xd33')]({'title':_0x53cec9[_0x53b18b('0x2728')]('TOOLBAR.WARNING'),'msg':_0x53cec9[_0x53b18b('0x2728')]('TOOLBAR.WEBRTC_LICENSE_NOT_ENABELD'),'clickToClose':!![],'showClose':!![],'shake':![],'timeout':![],'position':_0x53b18b('0x235b')});}function _0x4e7a99(){const _0x1dedd3=_0x55312f;return _0x83c397[_0x1dedd3('0x1f4a')][_0x1dedd3('0xace')]&&_0x83c397[_0x1dedd3('0x1f4a')][_0x1dedd3('0x992')]&&_0x83c397['conf'][_0x1dedd3('0x23e0')]&&_0x83c397[_0x1dedd3('0x1f4a')][_0x1dedd3('0x2765')]&&_0x83c397[_0x1dedd3('0x1f4a')]['protocol']==='https'&&_0x44c7f9();}function _0x44c7f9(){const _0x2142ea=_0x55312f;return _0x83c397['conf'][_0x2142ea('0x1a84')][_0x2142ea('0x93a')]()==='chrome'||_0x83c397[_0x2142ea('0x1f4a')]['browserName'][_0x2142ea('0x93a')]()===_0x2142ea('0x1336')||_0x83c397['conf'][_0x2142ea('0x1a84')][_0x2142ea('0x93a')]()===_0x2142ea('0x7a1');}function _0x1966f0(_0x50a9f0){const _0xe8f156=_0x55312f;console[_0xe8f156('0x598')](_0xe8f156('0xc72'),_0x50a9f0);const _0x58d174=_0x50a9f0[_0xe8f156('0xd18')];let _0x4bf206=!![],_0x823b7d='',_0x4a24d4=0x0,_0x3cf20a;switch(_0x50a9f0['originator']){case _0xe8f156('0x1f37'):{_0x58d174[_0xe8f156('0x25e8')]=!![],_0x58d174[_0xe8f156('0x60a')]=_0x50a9f0['request'][_0xe8f156('0xe0a')]['user'],_0x58d174[_0xe8f156('0xc96')]=_0x50a9f0[_0xe8f156('0x19ba')][_0xe8f156('0xe0a')]['user'],_0x2529a9(_0x58d174['user'],![]);const _0x32adf2=_0xe8f156('0x12db');_0x3cf20a=_0x22b934(_0x50a9f0[_0xe8f156('0x19ba')][_0xe8f156('0x1c3b')],_0x32adf2),_0x83c397['isJabraEnabled']&&(_0x83c397[_0xe8f156('0x42f')]&&_0x5b47e8[_0xe8f156('0x210c')](),_0x83c397[_0xe8f156('0x42f')]=_0x58d174,_0x5b47e8[_0xe8f156('0x18af')]());}break;case'remote':{const _0x3c2601=_0x1e2185[_0xe8f156('0x20b2')]();if(_0x3c2601['voicePause']&&_0x3c2601[_0xe8f156('0xe9d')]||_0x83c397[_0xe8f156('0x12')])_0x4bf206=![];else{_0x58d174[_0xe8f156('0x24bb')]=!![],_0x58d174[_0xe8f156('0x60a')]=_0x50a9f0[_0xe8f156('0x19ba')][_0xe8f156('0x705')]['display_name'],_0x58d174[_0xe8f156('0xc96')]=_0x50a9f0[_0xe8f156('0x19ba')][_0xe8f156('0x705')]['uri']['user'],_0x823b7d=_0x50a9f0[_0xe8f156('0x19ba')]['getHeader'](_0xe8f156('0x145d'))||'',_0x4a24d4=_0x50a9f0['request'][_0xe8f156('0x1b10')](_0xe8f156('0x1edc'))||0x0,_0x2a503d(_0x50a9f0[_0xe8f156('0xd18')]),_0x2529a9(_0x50a9f0[_0xe8f156('0xd18')]['user'],!![]);_0x83c397[_0xe8f156('0x2021')]&&_0x5b47e8[_0xe8f156('0x1ff4')]();_0x83c397[_0xe8f156('0x1f4a')][_0xe8f156('0xe72')]&&_0x1d7365(function(){const _0x2c317e=_0xe8f156;_0x58d174[_0x2c317e('0x89c')]()&&(_0x58d174[_0x2c317e('0xe72')]=!![],_0x3e19e1(_0x58d174));},_0x83c397[_0xe8f156('0x1f4a')][_0xe8f156('0x17e5')]?_0x83c397['conf']['autoAnswerDelay']*0x3e8:0x0);console[_0xe8f156('0x598')](_0xe8f156('0xc74'),_0x823b7d),console['debug'](_0xe8f156('0x1cd9'),_0x4a24d4);if(_0x823b7d['toLowerCase']()==_0xe8f156('0x8c5')){const _0x2739a2=_0x4a24d4==0x0?0x1f4:_0x4a24d4*0x3e8;console[_0xe8f156('0x598')](_0xe8f156('0x196b')+_0x2739a2+_0xe8f156('0x1024')),_0x1d7365(function(){const _0x2d6583=_0xe8f156;_0x58d174[_0x2d6583('0x89c')]()&&(_0x58d174[_0x2d6583('0xe72')]=!![],_0x3e19e1(_0x58d174));},_0x2739a2);}}break;}default:}_0x4bf206?(_0x58d174[_0xe8f156('0x153d')]=_0x50a9f0[_0xe8f156('0x19ba')][_0xe8f156('0x153d')],_0x3cf20a&&(_0x83c397['callbackQueue'][_0x58d174[_0xe8f156('0x153d')]]=_0x3cf20a,_0x6bb02a(_0x3cf20a,{'call_id':_0x58d174[_0xe8f156('0x153d')]})[_0xe8f156('0x683')](function(){const _0x465b92=_0xe8f156;console[_0x465b92('0x1b2b')]('callbackurl:\x22'+_0x3cf20a+_0x465b92('0x1d04'));})[_0xe8f156('0x130a')](function(_0x1c7a8e){const _0x47f572=_0xe8f156;console[_0x47f572('0x1b2b')](_0x47f572('0x1042')+_0x3cf20a+_0x47f572('0xcc5'),_0x1c7a8e);})),_0x58d174['connection']&&(_0x58d174[_0xe8f156('0x22b7')][_0xe8f156('0x7e')]=_0x1d8c25[_0xe8f156('0xb86')](this)),_0x58d174['iceCandidateTimeout']=null,_0x58d174['on']('progress',_0x45b2a9['bind'](this,_0x58d174)),_0x58d174['on']('confirmed',_0x4f74ff['bind'](this,_0x58d174)),_0x58d174['on']('hold',_0x4cc4f9[_0xe8f156('0xb86')](this,_0x58d174)),_0x58d174['on'](_0xe8f156('0x641'),_0x1d972d[_0xe8f156('0xb86')](this,_0x58d174)),_0x58d174['on'](_0xe8f156('0x2479'),_0x3043cd[_0xe8f156('0xb86')](this,_0x58d174)),_0x58d174['on'](_0xe8f156('0x1fb'),_0x17a18b[_0xe8f156('0xb86')](this,_0x58d174)),_0x58d174['on'](_0xe8f156('0x278e'),_0x11d371[_0xe8f156('0xb86')](this,_0x58d174)),_0x83c397[_0xe8f156('0x2be')][_0xe8f156('0x1fd0')](_0x58d174),_0x1d7365(function(){const _0x1a671a=_0xe8f156;_0x37071d[_0x1a671a('0x2b0')](),console[_0x1a671a('0x598')](_0x1a671a('0xa54'),_0x83c397['sessions']);})):_0x17154c(_0x58d174,0x1e6);}function _0x2529a9(_0x4ebb8b,_0x58370d,_0x10a972){const _0x7f5906=_0x55312f;console[_0x7f5906('0x598')](_0x7f5906('0x9c3'),_0x4ebb8b,_0x58370d,_0x10a972),_0x83c397[_0x7f5906('0x394')][_0x7f5906('0x1167')]({'target':_0x4ebb8b,'fullname':_0x10a972||_0x4ebb8b,'inbound':_0x58370d,'time':_0x1aaf93()()[_0x7f5906('0x26dd')]('HH:mm')}),_0x83c397[_0x7f5906('0x394')][_0x7f5906('0x1564')]>0x32&&_0x83c397[_0x7f5906('0x394')][_0x7f5906('0x1d')]();}function _0x2a503d(_0x17c20a){const _0x3c5d45=_0x55312f;console['debug']('getNotification\x20->\x20session',_0x17c20a);const _0xb4ea8a=_0x17c20a[_0x3c5d45('0x60a')]?_0x17c20a[_0x3c5d45('0x60a')]+'\x20<'+_0x17c20a['user']+'>':_0x17c20a[_0x3c5d45('0xc96')];_0x45cb54['create']('Incoming\x20call\x20from:\x20',_0xb4ea8a,null,function(){_0x3e19e1(_0x17c20a);},function(){_0x17154c(_0x17c20a);})[_0x3c5d45('0x683')](function(_0xe698d2){_0x17c20a['notification']=_0xe698d2;})[_0x3c5d45('0x130a')](function(_0x908082){const _0x3bd525=_0x3c5d45;console['error'](_0x3bd525('0x935'),_0x908082);});}function _0x3e19e1(_0x30919e){const _0xe5b3a3=_0x55312f;console[_0xe5b3a3('0x598')]('answer\x20->\x20session',_0x30919e),_0x83c397['conf']['microphoneId']?_0x83c397[_0xe5b3a3('0x1731')]['mediaConstraints'][_0xe5b3a3('0x9b5')]={'deviceId':_0x83c397['conf'][_0xe5b3a3('0x1dd6')]}:_0x83c397[_0xe5b3a3('0x1731')][_0xe5b3a3('0x7ff')]['audio']=!![],_0x30919e['answer'](_0x83c397[_0xe5b3a3('0x1731')]),_0x83c397[_0xe5b3a3('0x2021')]&&(_0x5b47e8[_0xe5b3a3('0x18af')](),_0x83c397[_0xe5b3a3('0x42f')]=_0x30919e);}function _0x17154c(_0x34a2ad,_0x3bff34){const _0x461c0d=_0x55312f;console[_0x461c0d('0x598')](_0x461c0d('0x1ffe'),_0x34a2ad);const _0x3a2bb2={};if(_0x3bff34)_0x3a2bb2[_0x461c0d('0x12b7')]=_0x3bff34;else!_0x34a2ad['isEstablished']()&&(_0x3a2bb2[_0x461c0d('0x12b7')]=0x25b);_0x34a2ad[_0x461c0d('0x1a66')](_0x3a2bb2);if(_0x83c397[_0x461c0d('0x2021')]){if(_0x83c397[_0x461c0d('0x2be')][_0x461c0d('0x1564')]===0x0)_0x34a2ad[_0x461c0d('0x1a42')]&&_0x5b47e8['resume'](),_0x5b47e8[_0x461c0d('0x1ecd')](),_0x83c397[_0x461c0d('0x42f')]=null;else{const _0x26e9c7=_0x2e3ca0()[_0x461c0d('0xc0f')](_0x83c397[_0x461c0d('0x2be')]);_0x26e9c7[_0x461c0d('0x1a42')]?(_0x5b47e8[_0x461c0d('0x1ecd')](),_0x5b47e8[_0x461c0d('0x27b6')](),_0x83c397[_0x461c0d('0x42f')]=_0x26e9c7):_0x5b47e8['offHook']();}}}function _0x45b2a9(_0x553b9b,_0xba1f4){const _0x502cd7=_0x55312f;console[_0x502cd7('0x598')](_0x502cd7('0x122d'),_0x553b9b,_0xba1f4);let _0x11e9ab=![];switch(_0xba1f4[_0x502cd7('0x1742')]){case _0x502cd7('0x1f37'):!this['conf']['ringingMute']&&(this['soundPlayer'][_0x502cd7('0x130f')](_0x502cd7('0x262a'),_0x502cd7('0xcd8')),_0x11e9ab=!![]);break;case'remote':this['putOtherCallsOnHold'](_0x553b9b),this[_0x502cd7('0x2797')][_0x502cd7('0x130f')]('src',_0x502cd7('0x2468')),_0x11e9ab=!![];break;}_0x83c397[_0x502cd7('0x12')]&&(_0x83c397[_0x502cd7('0x12')]=![]),_0x11e9ab&&(this[_0x502cd7('0x2797')][_0x502cd7('0x2159')]=_0x502cd7('0x2159'),this['soundPlayer']['play']()[_0x502cd7('0x130a')](function(_0xe6ec2a){const _0x52b953=_0x502cd7;console[_0x52b953('0x1b2b')](_0xe6ec2a[_0x52b953('0x8c2')]);})),_0x5bfd0a(_0x553b9b)[_0x502cd7('0x683')](function(){const _0x4d55a8=_0x502cd7,_0x145262=_0x83c397[_0x4d55a8('0x61a')][_0x553b9b[_0x4d55a8('0x153d')]];_0x145262&&_0x6bb02a(_0x145262,{'uniqueid':_0x553b9b[_0x4d55a8('0x573')],'call_id':_0x553b9b[_0x4d55a8('0x153d')],'number_called':_0x553b9b[_0x4d55a8('0xc96')]})[_0x4d55a8('0x683')](function(){const _0x51490c=_0x4d55a8;console[_0x51490c('0x1b2b')]('callbackurl:\x22'+_0x145262+_0x51490c('0x1d04'));})[_0x4d55a8('0x130a')](function(_0x185f3b){const _0x32771d=_0x4d55a8;console['log'](_0x32771d('0x1042')+_0x145262+_0x32771d('0xcc5'),_0x185f3b);})['finally'](function(){const _0x38b572=_0x4d55a8;delete _0x83c397[_0x38b572('0x61a')][_0x553b9b[_0x38b572('0x153d')]];});})['catch'](function(_0x12da5a){const _0x2caeec=_0x502cd7;console[_0x2caeec('0x52a')](_0x2caeec('0x1f85'),_0x12da5a);});}function _0x5bfd0a(_0x1d1ec3){const _0x18de1e=_0x55312f;return console[_0x18de1e('0x598')](_0x18de1e('0x1f52'),_0x1d1ec3),_0x59fbc4[_0x18de1e('0x1b1b')][_0x18de1e('0xe34')]()[_0x18de1e('0xe53')]['then'](function(_0x1bfa82){const _0x1b4fcc=_0x18de1e,_0x4641b6=_0x2e3ca0()['find'](_0x1bfa82[_0x1b4fcc('0xf5d')],function(_0x563ef9){const _0x3dcd8b=_0x1b4fcc;if(_0x563ef9[_0x3dcd8b('0x1966')]===_0x1d1ec3[_0x3dcd8b('0x153d')])return _0x563ef9;if(_0x563ef9['sipcalluniqueid']===_0x1d1ec3[_0x3dcd8b('0x153d')])return _0x563ef9;return null;});_0x4641b6&&(_0x1d1ec3[_0x1b4fcc('0x42e')]=_0x4641b6[_0x1b4fcc('0x42e')],_0x1d1ec3[_0x1b4fcc('0x573')]=_0x4641b6['uniqueid'],_0x1d1ec3['monitors']=_0x4641b6[_0x1b4fcc('0x2553')]);return;});}function _0x4f74ff(_0x4f1365,_0x1c438b){const _0x35424a=_0x55312f;console['debug'](_0x35424a('0x2b9'),_0x4f1365,_0x1c438b);const _0x1e200b=document[_0x35424a('0x1759')](_0x35424a('0x65d')+_0x4f1365['id'][_0x35424a('0x1f9e')](0x0,0x20));_0x1e200b&&$(_0x1e200b)[_0x35424a('0x2090')]()['$broadcast'](_0x35424a('0x1ddf')),_0x4f1365['confirmed']=!![],_0x1c438b['originator']===_0x35424a('0x710')&&_0x4f1365[_0x35424a('0x22b7')]&&(_0x4f1365[_0x35424a('0x22b7')]['onaddstream']=_0x1d8c25[_0x35424a('0xb86')](this),_0x2e3ca0()[_0x35424a('0xd39')](_0x4f1365['connection'][_0x35424a('0x20d2')]())&&(this['remotePlayer'][_0x35424a('0x18c')]=_0x2e3ca0()[_0x35424a('0xd39')](_0x4f1365[_0x35424a('0x22b7')]['getRemoteStreams']()),this[_0x35424a('0x20eb')][_0x35424a('0x10fa')]())),this[_0x35424a('0x2797')][_0x35424a('0xa4')](),this['soundPlayer'][_0x35424a('0x2159')]=null,this[_0x35424a('0xb3b')](_0x4f1365),_0x4f1365[_0x35424a('0xe72')]&&(this[_0x35424a('0x2797')]['setAttribute'](_0x35424a('0x262a'),_0x35424a('0xc7c')),this[_0x35424a('0x2797')]['play']()[_0x35424a('0x130a')](function(_0x315bce){const _0x5d996f=_0x35424a;console['log'](_0x5d996f('0x1ecb'),_0x315bce);})),_0x83c397[_0x35424a('0x155a')]=_0x83c397[_0x35424a('0x2be')][_0x35424a('0x1564')]==0x2,_0x5bfd0a(_0x4f1365)[_0x35424a('0x130a')](function(_0xb735aa){const _0x2a849e=_0x35424a;console[_0x2a849e('0x52a')](_0x2a849e('0x1f85'),_0xb735aa);});}function _0x1d8c25(_0x10ebe9){const _0x495511=_0x55312f;console['debug'](_0x495511('0x928'),_0x10ebe9),this[_0x495511('0x20eb')]['srcObject']=_0x10ebe9[_0x495511('0xb47')],this[_0x495511('0x20eb')][_0x495511('0x10fa')]();}function _0x4cc4f9(_0x85e9be,_0x5ba897){const _0x1b989f=_0x55312f;console[_0x1b989f('0x598')](_0x1b989f('0x1bdc'),_0x85e9be,_0x5ba897),_0x5ba897[_0x1b989f('0x1742')]===_0x1b989f('0x1f37')&&(_0x85e9be[_0x1b989f('0x1a42')]=!![]);}function _0x1d972d(_0x492654,_0x21632e){const _0x4e25af=_0x55312f;console['debug'](_0x4e25af('0x2858'),_0x492654,_0x21632e),_0x21632e['originator']===_0x4e25af('0x1f37')&&(_0x492654[_0x4e25af('0x1a42')]=![]);}function _0x3043cd(_0x50a974,_0x22b54f){const _0x35fb71=_0x55312f;console[_0x35fb71('0x598')](_0x35fb71('0x26f0'),_0x50a974,_0x22b54f);_0x83c397[_0x35fb71('0x1dc0')]&&(_0x2e3ca0()['includes'](_0x83c397[_0x35fb71('0x20a')],_0x50a974['id'])&&(_0x2bd20b(),_0x83c397['buttonClicked']=!![]));_0x2e3ca0()[_0x35fb71('0x3ec')](this[_0x35fb71('0x2be')],{'id':_0x50a974['id']});_0x83c397['sessions'][_0x35fb71('0x1564')]!==0x2&&(_0x83c397[_0x35fb71('0x155a')]=![]);if(_0x83c397[_0x35fb71('0x2021')]){if(_0x83c397[_0x35fb71('0x2be')][_0x35fb71('0x1564')]===0x0)_0x50a974['localHold']&&_0x5b47e8[_0x35fb71('0x210c')](),_0x5b47e8[_0x35fb71('0x1ecd')](),_0x83c397[_0x35fb71('0x42f')]=null;else{const _0x44ce6d=_0x2e3ca0()[_0x35fb71('0xc0f')](_0x83c397[_0x35fb71('0x2be')]);_0x44ce6d[_0x35fb71('0x1a42')]?(_0x5b47e8[_0x35fb71('0x1ecd')](),_0x5b47e8[_0x35fb71('0x27b6')](),_0x83c397['jabraSession']=_0x44ce6d):_0x5b47e8['offHook']();}}}function _0x2bd20b(){const _0x3dcd37=_0x55312f;_0x83c397[_0x3dcd37('0x155a')]=![],_0x83c397[_0x3dcd37('0x1dc0')]=![],_0x83c397[_0x3dcd37('0x13d7')]=[];}function _0x17a18b(_0x5cc503,_0x3967d2){const _0x4118cc=_0x55312f;console[_0x4118cc('0x598')](_0x4118cc('0x1998'),_0x5cc503,_0x3967d2),this[_0x4118cc('0x2797')][_0x4118cc('0xa4')](),this['soundPlayer'][_0x4118cc('0x2159')]=null;_0x5cc503[_0x4118cc('0x1290')]&&_0x5cc503['notification']['close']();_0x83c397[_0x4118cc('0x1dc0')]&&(_0x2e3ca0()[_0x4118cc('0x2292')](_0x83c397['currentConferenceSessions'],_0x5cc503['id'])&&_0x2bd20b());_0x83c397[_0x4118cc('0x12')]&&(_0x83c397[_0x4118cc('0x12')]=![]);_0x2e3ca0()['remove'](this[_0x4118cc('0x2be')],{'id':_0x5cc503['id']});_0x83c397[_0x4118cc('0x2be')]['length']!==0x2&&(_0x83c397[_0x4118cc('0x155a')]=![]);if(_0x83c397[_0x4118cc('0x2021')]){if(_0x83c397[_0x4118cc('0x2be')]['length']===0x0)_0x5cc503['localHold']&&_0x5b47e8['resume'](),_0x5b47e8['onHook'](),_0x83c397[_0x4118cc('0x42f')]=null;else{const _0x53b1f=_0x2e3ca0()['last'](_0x83c397[_0x4118cc('0x2be')]);_0x53b1f[_0x4118cc('0x1a42')]?(_0x5b47e8[_0x4118cc('0x1ecd')](),_0x5b47e8['hold'](),_0x83c397['jabraSession']=_0x53b1f):_0x5b47e8[_0x4118cc('0x18af')]();}}}function _0x11d371(_0x203a85,_0x506888){const _0x430ff7=_0x55312f;console[_0x430ff7('0x598')](_0x430ff7('0x1e30'),_0x203a85,_0x506888),_0x203a85['iceCandidateTimeout']!==null&&clearTimeout(_0x203a85['iceCandidateTimeout']),_0x203a85[_0x430ff7('0x1995')]=setTimeout(_0x506888[_0x430ff7('0x330')],0x1*0x3e8);}function _0x2744fc(){const _0x414f19=_0x55312f;_0x83c397[_0x414f19('0x139')]=![];}function _0x43bd1f(_0x4ed191,_0xc0549a){const _0x5e0711=_0x55312f;let _0x34d23f=_0x4ed191;!_0x83c397[_0x5e0711('0x568')]&&(_0x83c397[_0x5e0711('0x568')]='');_0xc0549a&&(_0x83c397[_0x5e0711('0x568')]+=_0x4ed191,_0x37071d[_0x5e0711('0x5ed')](_0x5e0711('0x1227'),'ms-target-wrap',_0x83c397[_0x5e0711('0x568')]));switch(_0x4ed191){case'*':_0x34d23f=_0x5e0711('0x1f58');break;case'#':_0x34d23f=_0x5e0711('0x2657');break;default:}_0x83c397[_0x5e0711('0x1f4a')][_0x5e0711('0xaf0')]&&(_0x83c397[_0x5e0711('0x2797')][_0x5e0711('0x130f')]('src',_0x5e0711('0xe6b')+_0x34d23f+'.ogg'),_0x83c397[_0x5e0711('0x2797')]['play']()[_0x5e0711('0x130a')](function(_0x105b4d){const _0x37bc89=_0x5e0711;console[_0x37bc89('0x1b2b')](_0x105b4d[_0x37bc89('0x8c2')]);}));for(let _0x5a1a68=0x0;_0x5a1a68<_0x83c397[_0x5e0711('0x2be')][_0x5e0711('0x1564')];_0x5a1a68+=0x1){_0x83c397[_0x5e0711('0x2be')][_0x5a1a68][_0x5e0711('0x1d7')]()&&!_0x83c397['sessions'][_0x5a1a68]['isOnHold']()[_0x5e0711('0x1f37')]&&_0x83c397[_0x5e0711('0x2be')][_0x5a1a68][_0x5e0711('0x135')](_0x4ed191);}}function _0xc36c2f(_0x26b941,_0x154524){const _0x1b5a23=_0x55312f;switch(_0x26b941){case'ringing':_0x83c397['soundPlayer'][_0x1b5a23('0x2612')]=_0x83c397[_0x1b5a23('0x1f4a')][_0x1b5a23('0x13eb')];_0x83c397[_0x1b5a23('0x1f4a')][_0x1b5a23('0x1eac')]&&_0x83c397[_0x1b5a23('0x2797')][_0x1b5a23('0xe7f')](_0x83c397[_0x1b5a23('0x1f4a')][_0x1b5a23('0x1eac')])[_0x1b5a23('0x683')](function(){const _0x4eb0a2=_0x1b5a23;_0x83c397['soundPlayer']['volume']=_0x83c397[_0x4eb0a2('0x1f4a')][_0x4eb0a2('0x184f')];})['then'](function(){_0x154524&&_0x3766a2();})[_0x1b5a23('0x130a')](function(_0x533284){const _0x1be5dd=_0x1b5a23;console[_0x1be5dd('0x2289')](_0x533284[_0x1be5dd('0x8c2')],_0x83c397[_0x1be5dd('0x1f4a')]['ringingId']);});break;case'speaker':_0x83c397['remotePlayer'][_0x1b5a23('0x2612')]=_0x83c397[_0x1b5a23('0x1f4a')][_0x1b5a23('0x1e34')];_0x83c397[_0x1b5a23('0x1f4a')][_0x1b5a23('0x902')]&&_0x83c397[_0x1b5a23('0x20eb')][_0x1b5a23('0xe7f')](_0x83c397[_0x1b5a23('0x1f4a')][_0x1b5a23('0x902')])[_0x1b5a23('0x683')](function(){const _0x4a17cf=_0x1b5a23;_0x83c397[_0x4a17cf('0x20eb')][_0x4a17cf('0x2a4')]=_0x83c397[_0x4a17cf('0x1f4a')][_0x4a17cf('0x86')];})[_0x1b5a23('0x683')](function(){_0x154524&&_0x3766a2();})['catch'](function(_0x36bfda){const _0x16a1ba=_0x1b5a23;console[_0x16a1ba('0x2289')](_0x36bfda['message'],_0x83c397[_0x16a1ba('0x1f4a')]['speakerId']);});break;case _0x1b5a23('0x3fa'):for(let _0x22ed5c=0x0;_0x22ed5c<_0x83c397[_0x1b5a23('0x2be')][_0x1b5a23('0x1564')];_0x22ed5c+=0x1){_0x83c397[_0x1b5a23('0x1f4a')][_0x1b5a23('0x16e9')]?_0x83c397['sessions'][_0x22ed5c][_0x1b5a23('0x165c')]():_0x83c397[_0x1b5a23('0x2be')][_0x22ed5c][_0x1b5a23('0x91')]();}_0x5b47e8&&_0x83c397[_0x1b5a23('0x2021')]&&(_0x83c397[_0x1b5a23('0x1f4a')][_0x1b5a23('0x16e9')]?_0x5b47e8['mute']():_0x5b47e8[_0x1b5a23('0x91')]());_0x154524&&_0x3766a2();break;default:console[_0x1b5a23('0x1b2b')]('unknown\x20device');}}function _0x461c39(_0x3737ec){const _0x52a8c8=_0x55312f;if(!_0x3737ec)_0x4fb750();else/^(\w|\.|\+|#|\*|\(|\)|\s|-)*$/['test'](_0x3737ec)?(_0x83c397[_0x52a8c8('0x568')]=_0x3737ec,_0x37071d['$broadcast']('angucomplete-alt:changeInput',_0x52a8c8('0x245d'),_0x83c397[_0x52a8c8('0x568')])):_0x83c397['target']?_0x37071d[_0x52a8c8('0x5ed')](_0x52a8c8('0x1227'),'ms-target-wrap',_0x83c397['target']):_0x4fb750();}function _0x4fb750(){const _0x30da01=_0x55312f;_0x83c397[_0x30da01('0x568')]='',document[_0x30da01('0x1759')]('ms-target')['blur'](),document[_0x30da01('0x1759')](_0x30da01('0x19c8'))['value']='',_0x37071d['$broadcast'](_0x30da01('0x1826'),_0x30da01('0x245d'));}function _0x87abb7(_0x11ec0c){const _0x1964bc=_0x55312f;_0x11ec0c&&(_0x83c397[_0x1964bc('0x568')]=_0x11ec0c[_0x1964bc('0x26ae')]['target'],_0x83c397['call'](),_0x4fb750());}function _0x1b129f(){const _0x2c5724=_0x55312f;if(_0x83c397[_0x2c5724('0x568')]&&_0x83c397['target']!==_0x83c397[_0x2c5724('0x1f4a')]['name']&&_0x83c397[_0x2c5724('0x568')]!==_0x83c397['conf'][_0x2c5724('0x1d43')]){_0x83c397[_0x2c5724('0x1f4a')][_0x2c5724('0x1dd6')]?_0x83c397[_0x2c5724('0x1731')][_0x2c5724('0x7ff')][_0x2c5724('0x9b5')]={'deviceId':_0x83c397[_0x2c5724('0x1f4a')]['microphoneId']}:_0x83c397[_0x2c5724('0x1731')]['mediaConstraints'][_0x2c5724('0x9b5')]=!![];let _0x30afd3=_0x83c397[_0x2c5724('0x568')]['replace'](/ /g,'');return _0x30afd3=_0x30afd3[_0x2c5724('0x1725')](/\(/g,''),_0x30afd3=_0x30afd3[_0x2c5724('0x1725')](/\)/g,''),_0xe31655(_0x30afd3)[_0x2c5724('0x683')](function(_0x3845a6){const _0x47f46b=_0x2c5724;_0x3845a6&&_0x83c397['ua']['call'](_0x3845a6,_0x83c397[_0x47f46b('0x1731')]);})['then'](function(){_0x4fb750();});}}function _0xe31655(_0xf85434){const _0x7b9bda=_0x55312f;return _0x59fbc4['user'][_0x7b9bda('0xa64')]({'id':_0x83c397[_0x7b9bda('0x1f4a')]['id']})['$promise'][_0x7b9bda('0x683')](function(_0x17e2be){const _0x2795e7=_0x7b9bda;if(_0x17e2be[_0x2795e7('0x50d')])return _0x13c8d7[_0x2795e7('0x1d4')]({'controller':_0x2795e7('0x15fb'),'controllerAs':'vm','templateUrl':_0x445657,'parent':angular[_0x2795e7('0x1fcc')](_0x32b328['body']),'clickOutsideToClose':!![],'locals':{'prefixes':_0x17e2be,'required':_0x83c397[_0x2795e7('0x1f4a')][_0x2795e7('0x2758')]}});})[_0x7b9bda('0x683')](function(_0x3025af){const _0x30f206=_0x7b9bda;if(!_0x83c397[_0x30f206('0x1f4a')]['phoneBarPrefixRequired']){if(_0x3025af&&_0x3025af!==-0x1)return _0x3025af+_0xf85434;else{if(!_0x3025af)return _0xf85434;}}else{if(_0x3025af&&_0x3025af!==-0x1)return _0x3025af+_0xf85434;}});}function _0x2ca925(_0x193309){const _0x4b6b59=_0x55312f;switch(_0x193309[_0x4b6b59('0x1d46')][_0x4b6b59('0x93a')]()){case'0':case'1':case'2':case'3':case'4':case'5':case'6':case'7':case'8':case'9':case'*':case'#':_0x83c397[_0x4b6b59('0xcf0')](_0x193309[_0x4b6b59('0x1d46')]);break;case _0x4b6b59('0xe30'):_0x83c397[_0x4b6b59('0x164f')]();break;default:}}function _0x1dd378(){const _0x201c17=_0x55312f;_0x83c397[_0x201c17('0x139')]=!_0x83c397[_0x201c17('0x139')];}_0x32b328[_0x55312f('0xb86')](_0x55312f('0x6b7'),function(_0x3f7c98){const _0x1efbc0=_0x55312f;switch(_0x3f7c98[_0x1efbc0('0x1618')]){case 0x1b:_0x1d7365(function(){_0x83c397['showDialpad']=![];});break;default:}});function _0x5f2a3d(){const _0x169366=_0x55312f;_0x83c397['isInConference']=!![],_0x83c397[_0x169366('0x155a')]=![],_0x83c397[_0x169366('0x20a')][_0x169366('0x1fd0')](_0x83c397[_0x169366('0x2be')][0x0]['id']),_0x83c397[_0x169366('0x20a')][_0x169366('0x1fd0')](_0x83c397[_0x169366('0x2be')][0x1]['id']);const _0x5ddff5=_0x83c397[_0x169366('0x2be')][0x0][_0x169366('0x22b7')]['getSenders']()[0x0],_0x16c5ef=_0x83c397[_0x169366('0x2be')][0x0][_0x169366('0x22b7')][_0x169366('0x988')]()[0x0];_0x16c5ef['track']['addEventListener']('unmute',function(){setTimeout(function(){_0x1a29f7();},0x3e8);},![]);const _0xb94632=_0x83c397[_0x169366('0x2be')][0x1][_0x169366('0x22b7')][_0x169366('0x1722')]()[0x0],_0x1df058=_0x83c397[_0x169366('0x2be')][0x1][_0x169366('0x22b7')][_0x169366('0x988')]()[0x0];_0x1df058[_0x169366('0x731')][_0x169366('0x1032')](_0x169366('0x91'),function(){setTimeout(function(){_0x1a29f7();},0x3e8);},![]),_0x83c397[_0x169366('0x2be')][0x0][_0x169366('0x641')]({'useUpdate':![]}),_0x83c397[_0x169366('0x2be')][0x1][_0x169366('0x641')]({'useUpdate':![]}),_0x16c5ef[_0x169366('0x731')][_0x169366('0x1333')]=!![],_0x1df058[_0x169366('0x731')][_0x169366('0x1333')]=!![];const _0x5558cc=new MediaStream(),_0x2dfdab=new AudioContext();let _0x5d57a1=_0x2dfdab[_0x169366('0x543')](),_0x5a0210=_0x2dfdab['createMediaStreamSource'](new MediaStream([_0x1df058['track']]));_0x5a0210['connect'](_0x5d57a1),_0x5a0210=_0x2dfdab[_0x169366('0x12eb')](new MediaStream([_0x5ddff5[_0x169366('0x731')]])),_0x5a0210[_0x169366('0x12ac')](_0x5d57a1),_0x5ddff5['replaceTrack'](_0x5d57a1[_0x169366('0xb47')][_0x169366('0x19a')]()[0x0])[_0x169366('0x683')](function(){}),_0x5d57a1=_0x2dfdab['createMediaStreamDestination'](),_0x5a0210=_0x2dfdab[_0x169366('0x12eb')](new MediaStream([_0x16c5ef[_0x169366('0x731')]])),_0x5a0210[_0x169366('0x12ac')](_0x5d57a1),_0x5a0210=_0x2dfdab[_0x169366('0x12eb')](new MediaStream([_0xb94632['track']])),_0x5a0210['connect'](_0x5d57a1),_0xb94632[_0x169366('0x9c6')](_0x5d57a1['stream'][_0x169366('0x19a')]()[0x0])[_0x169366('0x683')](function(){const _0x208856=_0x169366;_0x5558cc[_0x208856('0x318')](_0x16c5ef[_0x208856('0x731')]),_0x5558cc[_0x208856('0x318')](_0x1df058[_0x208856('0x731')]);const _0x33807a=document[_0x208856('0x1759')](_0x208856('0x9ac'));_0x33807a[_0x208856('0x18c')]=_0x5558cc;const _0x5e1445=_0x33807a[_0x208856('0x10fa')]();_0x5e1445!==undefined&&_0x5e1445['then'](function(){})[_0x208856('0x130a')](function(_0x3cdf32){const _0x4e80c8=_0x208856;console[_0x4e80c8('0x1b2b')](_0x3cdf32);});});}function _0x1a29f7(){const _0x1cc1b1=_0x55312f;if(_0x83c397['isInConference']){const _0x527b79=_0x83c397[_0x1cc1b1('0x2be')][0x0][_0x1cc1b1('0x22b7')][_0x1cc1b1('0x988')]()[0x0],_0x20c8cb=_0x83c397[_0x1cc1b1('0x2be')][0x1]['connection'][_0x1cc1b1('0x988')]()[0x0],_0x217d05=new MediaStream();_0x217d05[_0x1cc1b1('0x318')](_0x527b79[_0x1cc1b1('0x731')]),_0x217d05[_0x1cc1b1('0x318')](_0x20c8cb[_0x1cc1b1('0x731')]);const _0x5afb80=document['getElementById']('remote-audio');_0x5afb80[_0x1cc1b1('0x18c')]=_0x217d05;const _0x15e743=_0x5afb80[_0x1cc1b1('0x10fa')]();_0x15e743!==undefined&&_0x15e743[_0x1cc1b1('0x683')](function(){})['catch'](function(_0x230635){const _0xfcacde=_0x1cc1b1;console[_0xfcacde('0x1b2b')](_0x230635);});}}function _0x593edc(_0x26936b){const _0x42e41b=_0x55312f;console[_0x42e41b('0x598')](_0x42e41b('0x930'),_0x26936b),_0x83c397[_0x42e41b('0x641')](_0x26936b);}function _0x3382a4(_0xd97d81){const _0x26f21d=_0x55312f;console[_0x26f21d('0x598')](_0x26f21d('0x2852'),_0xd97d81),_0xd97d81[_0x26f21d('0x641')]({'useUpdate':![]}),_0x83c397[_0x26f21d('0xb3b')](_0xd97d81),_0x83c397[_0x26f21d('0x2021')]&&(_0x5b47e8[_0x26f21d('0x18af')](),_0x5b47e8['resume']());}function _0x46ae5b(_0x10788e){const _0x3ebce0=_0x55312f;console[_0x3ebce0('0x598')](_0x3ebce0('0xcdf'),_0x10788e),_0x13c8d7[_0x3ebce0('0x1d4')]({'controller':'RecordDialogController','controllerAs':'vm','templateUrl':_0x24023a,'parent':angular[_0x3ebce0('0x1fcc')](_0x32b328[_0x3ebce0('0x18e5')]),'clickOutsideToClose':!![],'locals':{'session':_0x10788e,'sessions':_0x83c397[_0x3ebce0('0x2be')]}});}function _0x12ffe3(_0x16a958){const _0x4086b3=_0x55312f;console[_0x4086b3('0x598')](_0x4086b3('0xbc8'),_0x16a958),_0x16a958[_0x4086b3('0x27b6')]({'useUpdate':![]}),_0x83c397[_0x4086b3('0x2021')]&&(_0x5b47e8[_0x4086b3('0x27b6')](),_0x5b47e8[_0x4086b3('0x1ecd')]());}function _0xc9abfd(_0x34f78e){const _0x359662=_0x55312f;console[_0x359662('0x598')](_0x359662('0x30e'),_0x34f78e);const _0x39a56b=_0x13c8d7[_0x359662('0xa84')]()[_0x359662('0xf28')](_0x359662('0x1166'))[_0x359662('0x1525')](_0x359662('0xc6e'))[_0x359662('0x156b')]('Target')[_0x359662('0x1040')]('Target')['ok'](_0x359662('0x1166'))[_0x359662('0x19fb')](_0x359662('0x253a'));_0x13c8d7[_0x359662('0x1d4')](_0x39a56b)[_0x359662('0x683')](function(_0x1c82a2){return _0xe31655(_0x1c82a2);})[_0x359662('0x683')](function(_0x5e4aa5){const _0x13f5e5=_0x359662;_0x34f78e[_0x13f5e5('0x27ec')](_0x5e4aa5,{'eventHandlers':{'requestSucceeded':_0x3fba4f(_0x34f78e,_0x13f5e5('0x8ca'),_0x13f5e5('0x10e4'),0xbb8),'requestFailed':_0x3fba4f(_0x34f78e,_0x13f5e5('0x1d92'),_0x13f5e5('0x10e4'),0xbb8)}});});}function _0x3fba4f(_0x5425dd,_0x24f243,_0x45f3d7,_0x4dc062){return console['debug']('onReferCallback\x20->\x20session,\x20textContent,\x20position,\x20delay',_0x5425dd,_0x24f243,_0x45f3d7,_0x4dc062),function(){const _0x3e9e7e=a0_0x4e0a;_0x7fc7b[_0x3e9e7e('0x1d4')](_0x7fc7b[_0x3e9e7e('0x277d')]()['textContent'](_0x24f243)[_0x3e9e7e('0x1233')](_0x45f3d7)[_0x3e9e7e('0x2490')](_0x4dc062)),_0x17154c(_0x5425dd);};}function _0x39e59f(_0x22f87d){const _0x1f09fb=_0x55312f;console[_0x1f09fb('0x598')](_0x1f09fb('0x165f'),_0x22f87d),_0x13c8d7[_0x1f09fb('0x1d4')]({'controller':_0x1f09fb('0x1436'),'controllerAs':'vm','templateUrl':_0x4c9c5e,'parent':angular[_0x1f09fb('0x1fcc')](_0x32b328['body']),'clickOutsideToClose':!![],'locals':{'session':_0x22f87d,'sessions':_0x2e3ca0()[_0x1f09fb('0xfae')](_0x83c397[_0x1f09fb('0x2be')],{'id':_0x22f87d['id']}),'isJabraEnabled':_0x83c397[_0x1f09fb('0x2021')]}});}function _0x12ba89(_0x5b57e1){const _0x18b9e5=_0x55312f;console[_0x18b9e5('0x598')](_0x18b9e5('0x169d'),_0x5b57e1);if(_0x83c397[_0x18b9e5('0x2be')]['length']>0x1)for(let _0x41097c=0x0;_0x41097c<_0x83c397['sessions'][_0x18b9e5('0x1564')];_0x41097c+=0x1){_0x83c397[_0x18b9e5('0x2be')][_0x41097c]['id']!==_0x5b57e1['id']&&!_0x83c397[_0x18b9e5('0x2be')][_0x41097c][_0x18b9e5('0xdda')]()[_0x18b9e5('0x710')]&&_0x83c397['sessions'][_0x41097c][_0x18b9e5('0x27b6')]({'useUpdate':![]});}}function _0x4c8480(_0xd9dbc){const _0x18c0d1=_0x55312f;_0x13c8d7[_0x18c0d1('0x1d4')]({'controller':_0x18c0d1('0x12a0'),'controllerAs':'vm','templateUrl':_0x5c6605,'parent':angular['element'](_0x32b328[_0x18c0d1('0x18e5')]),'targetEvent':_0xd9dbc,'clickOutsideToClose':!![],'resolve':{'devices':function(){const _0x101eff=_0x18c0d1;return navigator['mediaDevices'][_0x101eff('0x186c')]();}},'locals':{'conf':_0x83c397[_0x18c0d1('0x1f4a')]}})[_0x18c0d1('0x683')](function(_0x304a41){const _0x44b4b9=_0x18c0d1;_0x304a41&&(_0x83c397[_0x44b4b9('0x1f4a')]=_0x304a41,!_0x83c397[_0x44b4b9('0x25dc')]&&(_0x83c397[_0x44b4b9('0x25dc')]=!![],_0x5b47e8&&_0x83c397['isJabraInitialized']?_0x5b47e8[_0x44b4b9('0x10c8')]()[_0x44b4b9('0x683')](function(){const _0x86dcf5=_0x44b4b9;_0x83c397[_0x86dcf5('0x1a81')]=![],_0x83c397[_0x86dcf5('0x2021')]=![],_0x33efaf(![]);})[_0x44b4b9('0x130a')](function(_0x37633d){const _0x58cd1e=_0x44b4b9;console[_0x58cd1e('0x52a')](_0x58cd1e('0x10bd'),_0x37633d);}):_0x33efaf(![])));});}function _0xaa1cc6(){const _0x46d940=_0x55312f;_0x83c397['ua'][_0x46d940('0x19cc')](),_0x5b47e8&&_0x83c397['isJabraInitialized']&&_0x5b47e8[_0x46d940('0x10c8')](),navigator[_0x46d940('0x2230')][_0x46d940('0xff6')]=function(){};}function _0x1cfc98(_0x339571,_0x10eafc){const _0xaf61e7=_0x55312f;console[_0xaf61e7('0x598')]('onRemoteCall\x20->\x20evt,\x20data',_0x339571,_0x10eafc),_0x10eafc[_0xaf61e7('0x568')]&&(_0x83c397[_0xaf61e7('0x568')]=_0x10eafc[_0xaf61e7('0x568')],_0x83c397['call']());}function _0xd4a933(_0x46715a,_0x2319cf){const _0x39108e=_0x55312f;console[_0x39108e('0x598')](_0x39108e('0x111f'),_0x46715a,_0x2319cf);if(_0x2319cf['target'])for(let _0x112ce4=0x0;_0x112ce4<_0x83c397[_0x39108e('0x2be')][_0x39108e('0x1564')];_0x112ce4+=0x1){if(_0x83c397[_0x39108e('0x2be')][_0x112ce4][_0x39108e('0x1d7')]()&&!_0x83c397[_0x39108e('0x2be')][_0x112ce4][_0x39108e('0xdda')]()[_0x39108e('0x1f37')])return _0xe31655(_0x2319cf[_0x39108e('0x568')])[_0x39108e('0x683')](function(_0x2b2fbb){const _0x29dc8b=_0x39108e;_0x2b2fbb&&_0x83c397[_0x29dc8b('0x2be')][_0x112ce4][_0x29dc8b('0x27ec')](_0x2b2fbb,{'eventHandlers':{'requestSucceeded':_0x3fba4f(_0x83c397[_0x29dc8b('0x2be')][_0x112ce4],_0x29dc8b('0x8ca'),_0x29dc8b('0x10e4'),0xbb8),'requestFailed':_0x3fba4f(_0x83c397['sessions'][_0x112ce4],_0x29dc8b('0x1d92'),_0x29dc8b('0x10e4'),0xbb8)}});});}}function _0x48e330(){return new Promise(function(_0x47004b){const _0x172e66=a0_0x4e0a;let _0x1c87f1=null;for(let _0xe32ecb=0x0;_0xe32ecb<_0x83c397[_0x172e66('0x2be')][_0x172e66('0x1564')];_0xe32ecb++){!_0x2e3ca0()[_0x172e66('0x25b7')](_0x83c397[_0x172e66('0x2be')][_0xe32ecb],_0x172e66('0x1a42'))?_0x1c87f1=_0x83c397['sessions'][_0xe32ecb]:!_0x83c397[_0x172e66('0x2be')][_0xe32ecb][_0x172e66('0x1a42')]&&(_0x1c87f1=_0x83c397[_0x172e66('0x2be')][_0xe32ecb]);}_0x47004b(_0x1c87f1);});}function _0x129388(_0x547dca){const _0x5f1f81=_0x55312f;console[_0x5f1f81('0x598')](_0x5f1f81('0x85a'),_0x547dca);const _0x2fdc5c=_0x547dca[_0x5f1f81('0x186')],_0xb78b7=_0x547dca['callerId'],_0x41f809=_0x547dca['callbackUrl'];_0x83c397[_0x5f1f81('0x1f4a')][_0x5f1f81('0x1dd6')]?_0x83c397[_0x5f1f81('0x1731')][_0x5f1f81('0x7ff')]['audio']={'deviceId':_0x83c397[_0x5f1f81('0x1f4a')][_0x5f1f81('0x1dd6')]}:_0x83c397[_0x5f1f81('0x1731')][_0x5f1f81('0x7ff')][_0x5f1f81('0x9b5')]=!![];let _0x25340d=_0x2fdc5c[_0x5f1f81('0x1725')](/ /g,'');_0x25340d=_0x25340d[_0x5f1f81('0x1725')](/\(/g,''),_0x25340d=_0x25340d[_0x5f1f81('0x1725')](/\)/g,'');if(_0x25340d){const _0x410c22=angular[_0x5f1f81('0x1a86')](_0x83c397[_0x5f1f81('0x1731')]);_0x410c22[_0x5f1f81('0x1c3b')]=[],_0xb78b7&&_0x410c22[_0x5f1f81('0x1c3b')][_0x5f1f81('0x1fd0')](_0x5f1f81('0x1717')+_0xb78b7),_0x41f809&&_0x410c22[_0x5f1f81('0x1c3b')][_0x5f1f81('0x1fd0')](_0x5f1f81('0xc46')+_0x41f809),_0x83c397[_0x5f1f81('0x12')]=!![],_0x83c397['ua'][_0x5f1f81('0x164f')](_0x25340d,_0x410c22);}}function _0x1c33c3(_0x17150d){const _0x2f2ff6=_0x55312f;console[_0x2f2ff6('0x598')]('hangupHook\x20->\x20payload',_0x17150d);let _0x3196d3=_0x83c397[_0x2f2ff6('0x2be')];if(_0x17150d[_0x2f2ff6('0x127a')]){_0x3196d3=[];const _0x4e4285=_0x17150d[_0x2f2ff6('0x127a')];_0x3196d3[_0x2f2ff6('0x1fd0')](_0x25325a(_0x17150d[_0x2f2ff6('0x127a')]));if(_0x3196d3[_0x2f2ff6('0x1564')]==0x0){console[_0x2f2ff6('0x27b5')](_0x2f2ff6('0x19e2')+_0x4e4285+_0x2f2ff6('0xaf1'));return;}}for(let _0x586cd1=0x0;_0x586cd1<_0x3196d3['length'];_0x586cd1++){const _0x1a1745=_0x3196d3[_0x586cd1];console[_0x2f2ff6('0x1b2b')](_0x2f2ff6('0x1f8c'),_0x1a1745),_0x83c397[_0x2f2ff6('0x1a66')](_0x1a1745);}}function _0x458255(_0x14a821){const _0x5eae6b=_0x55312f;console[_0x5eae6b('0x598')](_0x5eae6b('0x864'),_0x14a821);let _0x255dbe=_0x120906();if(_0x14a821[_0x5eae6b('0x127a')]){const _0xc92b84=_0x14a821[_0x5eae6b('0x127a')],_0x236287=_0x25325a(_0x14a821[_0x5eae6b('0x127a')]);if(!_0x236287){console[_0x5eae6b('0x27b5')](_0x5eae6b('0x19e2')+_0xc92b84+_0x5eae6b('0xaf1'));return;}_0x255dbe=[_0x236287];}for(let _0x54dc0f=0x0;_0x54dc0f<_0x255dbe['length'];_0x54dc0f++){const _0x3a5956=_0x255dbe[_0x54dc0f];_0x83c397[_0x5eae6b('0x1767')](_0x3a5956);}}function _0x120906(){const _0x3d9817=_0x55312f,_0xbe81c0=_0x2e3ca0()['find'](_0x83c397[_0x3d9817('0x2be')],function(_0x2efc8f){const _0x473b47=_0x3d9817;return _0x2efc8f[_0x473b47('0x24bb')]&&!_0x2efc8f[_0x473b47('0xd1f')];});return _0xbe81c0;}function _0x2fe495(_0x477f0f){const _0x1b855e=_0x55312f;console[_0x1b855e('0x598')](_0x1b855e('0xe35'),_0x477f0f);let _0x54b1f3=_0x83c397[_0x1b855e('0x2be')];if(_0x477f0f[_0x1b855e('0x127a')]){_0x54b1f3=[],_0x54b1f3[_0x1b855e('0x1fd0')](_0x25325a(_0x477f0f[_0x1b855e('0x127a')]));const _0x428963=_0x477f0f[_0x1b855e('0x127a')];if(_0x54b1f3[_0x1b855e('0x1564')]==0x0){console['warn'](_0x1b855e('0x19e2')+_0x428963+_0x1b855e('0xaf1'));return;}}for(let _0x2a4f49=0x0;_0x2a4f49<_0x54b1f3[_0x1b855e('0x1564')];_0x2a4f49++){const _0x86f53c=_0x54b1f3[_0x2a4f49];_0x83c397[_0x1b855e('0x27b6')](_0x86f53c);}}function _0x305840(_0x28c009){const _0x3799e3=_0x55312f;console['debug'](_0x3799e3('0xe35'),_0x28c009);if(!_0x28c009['sessionId']){console['error'](_0x3799e3('0x118b'));return;}const _0x492550=_0x25325a(_0x28c009[_0x3799e3('0x127a')]);if(!_0x492550){const _0x1f1a5e=_0x28c009[_0x3799e3('0x127a')];console[_0x3799e3('0x27b5')](_0x3799e3('0x19e2')+_0x1f1a5e+'\x20not\x20found');return;}_0x83c397[_0x3799e3('0x641')](_0x492550);}function _0x19f5f8(_0x3e1750){const _0x4b23ca=_0x55312f;console[_0x4b23ca('0x598')](_0x4b23ca('0xf6f'),_0x3e1750);if(!_0x3e1750[_0x4b23ca('0x127a')]){console[_0x4b23ca('0x52a')](_0x4b23ca('0x118b'));return;}if(!_0x3e1750['transferNumber']){console[_0x4b23ca('0x52a')]('transferNumber\x20required');return;}const _0x2dbd07=_0x25325a(_0x3e1750[_0x4b23ca('0x127a')]);if(!_0x2dbd07){const _0xff111a=_0x3e1750[_0x4b23ca('0x127a')];console['warn'](_0x4b23ca('0x19e2')+_0xff111a+_0x4b23ca('0xaf1'));return;}_0x2dbd07[_0x4b23ca('0x27ec')](_0x3e1750[_0x4b23ca('0xfac')],{'eventHandlers':{'requestSucceeded':_0x3fba4f(_0x2dbd07,_0x4b23ca('0x8ca'),_0x4b23ca('0x10e4'),0xbb8),'requestFailed':_0x3fba4f(_0x2dbd07,'requestFailed',_0x4b23ca('0x10e4'),0xbb8)}});}function _0x25325a(_0x2800d1){const _0x4c9d6f=_0x55312f;console[_0x4c9d6f('0x598')](_0x4c9d6f('0x2383'),_0x2800d1,_0x83c397['sessions']);const _0x3aaf68=_0x2e3ca0()[_0x4c9d6f('0x1c07')](_0x83c397['sessions'],function(_0x27b955){const _0x3e83d7=_0x4c9d6f;return _0x27b955[_0x3e83d7('0x153d')]==_0x2800d1;});return _0x3aaf68;}function _0x6bb02a(_0x5c3902,_0x470d67){const _0xc4205f=_0x55312f;return console[_0xc4205f('0x598')](_0xc4205f('0xd14'),_0x5c3902,_0x470d67),_0x453c18({'url':_0x5c3902,'method':_0xc4205f('0x2270'),'params':_0x470d67});}function _0x22b934(_0x257637,_0x282feb,_0x41035b){const _0x187ac8=_0x55312f,_0x1ccf6b=_0x2e3ca0()['find'](_0x257637,function(_0x19c723){const _0x1c6af8=a0_0x4e0a;return _0x2e3ca0()[_0x1c6af8('0x18ad')](_0x19c723,_0x282feb);});if(_0x1ccf6b)return _0x2e3ca0()[_0x187ac8('0x12ae')](_0x1ccf6b['replace'](_0x282feb,'')[_0x187ac8('0x1725')](_0x41035b||':',''));return![];}_0x83c397[_0x55312f('0x3a8')]=_0x11e16e[_0x55312f('0xb86')](this),_0x83c397[_0x55312f('0xcf0')]=_0x43bd1f,_0x83c397[_0x55312f('0x164f')]=_0x1b129f,_0x83c397[_0x55312f('0x27b6')]=_0x12ffe3,_0x83c397[_0x55312f('0x27ec')]=_0xc9abfd,_0x83c397[_0x55312f('0x9a')]=_0x46ae5b,_0x83c397[_0x55312f('0x641')]=_0x3382a4,_0x83c397['answer']=_0x3e19e1,_0x83c397[_0x55312f('0x1a66')]=_0x17154c,_0x83c397[_0x55312f('0x837')]=_0x593edc,_0x83c397[_0x55312f('0x1f93')]=_0x2ca925,_0x83c397['toggleDialpad']=_0x1dd378,_0x83c397[_0x55312f('0x192a')]=_0x39e59f,_0x83c397[_0x55312f('0xdf1')]=_0x2744fc,_0x83c397['initDevice']=_0xc36c2f,_0x83c397[_0x55312f('0xb3b')]=_0x12ba89,_0x83c397[_0x55312f('0x1090')]=_0x461c39,_0x83c397['targetSelected']=_0x87abb7,_0x83c397[_0x55312f('0xa5b')]=_0x5f2a3d,_0x83c397[_0x55312f('0x30a')]=_0x1a29f7,_0x37071d[_0x55312f('0x26a2')](_0x55312f('0xba'),_0x4c8480),_0x37071d[_0x55312f('0x26a2')](_0x55312f('0x1ff7'),_0xaa1cc6),_0x37071d[_0x55312f('0x26a2')](_0x55312f('0x2638'),_0x1cfc98),_0x37071d[_0x55312f('0x26a2')](_0x55312f('0x2424'),_0xd4a933),_0x37071d[_0x55312f('0x26a2')]('$destroy',function(){const _0x2de557=_0x55312f;console['debug'](_0x2de557('0x2849')),_0x4f8a6c[_0x2de557('0x1b9e')](_0x2de557('0x19aa')),_0x4f8a6c[_0x2de557('0x1b9e')](_0x2de557('0x140')),_0x4f8a6c['removeAllListeners'](_0x2de557('0x2b3')),_0x4f8a6c['removeAllListeners']('webbar:hold'),_0x4f8a6c[_0x2de557('0x1b9e')](_0x2de557('0x10f8')),_0x4f8a6c[_0x2de557('0x1b9e')]('webbar:transfer');});}function _0x2ca283(){const _0x3e37eb=_0x189033;return{'restrict':'E','scope':{'conf':'='},'require':'msPhonebar','controller':_0x3e37eb('0x1272'),'controllerAs':'vm_pb','bindToController':!![],'templateUrl':_0x3180b5};}_0x4ecc1b['$inject']=[_0x189033('0x1e48'),_0x189033('0x1656'),'required'];function _0x4ecc1b(_0x2cfdcb,_0x478b51,_0x40f6ce){const _0x5264f8=_0x189033,_0x5a64ef=this;function _0x11efb3(){const _0x3fed49=a0_0x4e0a;_0x2cfdcb['hide'](_0x5a64ef[_0x3fed49('0x24fa')]);}function _0x18c773(_0x263173){const _0x363bb2=a0_0x4e0a;_0x2cfdcb[_0x363bb2('0x1715')](_0x263173);}_0x5a64ef[_0x5264f8('0x1656')]=_0x478b51,_0x5a64ef['required']=_0x40f6ce,_0x5a64ef[_0x5264f8('0xf82')]=_0x18c773,_0x5a64ef['call']=_0x11efb3;}const _0x4dd772=_0x4ecc1b;_0x212024['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x56b'),_0x189033('0x2be'),_0x189033('0xd18')],_0x322a9f[_0x189033('0x14be')]=[_0x189033('0x2f9')];function _0x322a9f(_0x590fd9){const _0x134aa8=_0x189033;return{'restrict':'C','controller':[_0x134aa8('0x7a5'),_0x134aa8('0x1222'),function(_0x125038,_0x4fa4a4){function _0x49e5e5(){const _0x2b66a4=a0_0x4e0a;_0x4fa4a4[_0x2b66a4('0x1e78')](_0x2b66a4('0x1fe8'),_0x2b66a4('0x1a9b')),_0x590fd9(_0x15d847,0x3e8);}function _0x15d847(){const _0x205941=a0_0x4e0a;_0x4fa4a4['css'](_0x205941('0x1fe8'),_0x205941('0x925')),_0x590fd9(_0x49e5e5,0x3e8);}_0x49e5e5();}],'replace':!![]};}function _0x212024(_0x35a97f,_0x793b65,_0x15719e,_0x1e395d,_0x416fff){const _0xce0efd=_0x189033,_0x553bc5=this;_0x553bc5[_0xce0efd('0xf28')]=_0xce0efd('0x764'),_0x553bc5['sessions']=_0x1e395d,_0x553bc5[_0xce0efd('0xd18')]=_0x416fff,_0x553bc5[_0xce0efd('0xf82')]=_0x35a5a3,_0x553bc5[_0xce0efd('0xc7d')]=_0x1a7c2b,_0x553bc5[_0xce0efd('0x19cc')]=_0x39c044,_0x553bc5['start']=_0x583da9;function _0x3e682e(){function _0x1fe318(){const _0x430633=a0_0x4e0a;return Math[_0x430633('0x16c9')]((0x1+Math[_0x430633('0x25c6')]())*0x10000)[_0x430633('0x1ff0')](0x10)[_0x430633('0x1735')](0x1);}return _0x1fe318()+_0x1fe318()+'-'+_0x1fe318()+'-'+_0x1fe318()+'-'+_0x1fe318()+'-'+_0x1fe318()+_0x1fe318()+_0x1fe318();}function _0x583da9(_0x4207eb,_0x186ce0){const _0x1b36d0=_0xce0efd;console[_0x1b36d0('0x1b2b')](_0x1b36d0('0x24f6'));const _0x4aef4a=_0x793b65[_0x1b36d0('0x448')](),_0x4ed0a6=_0x186ce0||_0x4207eb[_0x1b36d0('0x1917')][_0x1b36d0('0x1725')](/^.*[\\/]/,''),_0xb39b05=_0x4ed0a6['split']('.')[0x0];return _0x15719e[_0x1b36d0('0x1b1b')][_0x1b36d0('0x24f6')]({'uniqueid':_0x553bc5[_0x1b36d0('0xd18')][_0x1b36d0('0x573')],'filename':_0xb39b05,'format':_0x1b36d0('0x1d2a')})[_0x1b36d0('0xe53')]['then'](function(_0x234cd5){const _0x3eb3f1=_0x1b36d0;_0x4207eb[_0x3eb3f1('0x1917')]=_0xb39b05+_0x3eb3f1('0x138a'),_0x4207eb['mixmonitorid']=_0x234cd5[_0x3eb3f1('0x10e3')],_0x4207eb['status']=_0x3eb3f1('0x27fb'),_0x553bc5[_0x3eb3f1('0xd18')][_0x3eb3f1('0x42e')]=!![],_0x4aef4a[_0x3eb3f1('0xed7')](_0x4207eb);})[_0x1b36d0('0x130a')](function(_0x391b26){_0x4aef4a['reject'](_0x391b26);}),_0x4aef4a[_0x1b36d0('0x1883')];}function _0x39c044(_0x29a49b){const _0x21cb45=_0xce0efd;return console[_0x21cb45('0x1b2b')](_0x21cb45('0x1d4b')),_0x15719e[_0x21cb45('0x1b1b')][_0x21cb45('0x1d4b')]({'uniqueid':_0x553bc5[_0x21cb45('0xd18')][_0x21cb45('0x573')],'mixmonitorid':_0x29a49b[_0x21cb45('0x10e3')]})['$promise'][_0x21cb45('0x683')](function(){const _0x5268ab=_0x21cb45;_0x29a49b[_0x5268ab('0x13ee')]=_0x5268ab('0xa4'),_0x553bc5[_0x5268ab('0xd18')][_0x5268ab('0x42e')]=_0x2e3ca0()[_0x5268ab('0x2292')](_0x553bc5[_0x5268ab('0xd18')][_0x5268ab('0x2553')],{'status':_0x5268ab('0x27fb')});})[_0x21cb45('0x130a')](function(_0x188f27){console['error'](_0x188f27);});}function _0x1a7c2b(){const _0x5a3d4f=_0xce0efd,_0x488882=_0x35a97f['prompt']({'skipHide':!![]})[_0x5a3d4f('0xf28')](_0x5a3d4f('0x1ac5'))['textContent'](_0x5a3d4f('0x382'))[_0x5a3d4f('0x156b')]('File\x20name')[_0x5a3d4f('0x1040')](_0x5a3d4f('0x587'))['initialValue'](_0x3e682e())['ok'](_0x5a3d4f('0x26ea'))[_0x5a3d4f('0x19fb')]('Cancel');_0x35a97f['show'](_0x488882)['then'](function(_0x116c6d){return _0x583da9({},_0x116c6d);})['then'](function(_0x32838d){const _0x94e699=_0x5a3d4f;_0x553bc5['session'][_0x94e699('0x2553')][_0x94e699('0x1fd0')](_0x32838d);});}function _0x35a5a3(){_0x35a97f['hide']();}}_0x4447b7['$inject']=[_0x189033('0x1e48'),_0x189033('0xb33'),_0x189033('0x2be'),_0x189033('0xd18'),'isJabraEnabled'];function _0x4447b7(_0x2f88a9,_0x3a9ee7,_0x284742,_0x406d2e,_0x43ae12){const _0x145891=_0x189033,_0x4a6e1c=this,_0x5bc188=window['jabra'];_0x4a6e1c[_0x145891('0xf28')]=_0x145891('0x1c8f'),_0x4a6e1c[_0x145891('0x2be')]=_0x284742,_0x4a6e1c[_0x145891('0xd18')]=_0x406d2e,_0x4a6e1c[_0x145891('0x2021')]=_0x43ae12,_0x4a6e1c[_0x145891('0x1156')]=null;_0x284742['length']&&(_0x4a6e1c[_0x145891('0x568')]=_0x284742[0x0]['user']);_0x4a6e1c[_0x145891('0xf82')]=_0x2f42c8,_0x4a6e1c[_0x145891('0x1011')]=_0x34696e;function _0x34696e(){const _0x26df39=_0x145891;let _0x3206db,_0x39968f;const _0x5e9484=_0x2e3ca0()[_0x26df39('0x1c07')](_0x284742,function(_0x16a532){const _0x548d9f=_0x26df39;if(_0x16a532['user']===_0x4a6e1c[_0x548d9f('0x568')])return _0x16a532;});_0x5e9484[_0x26df39('0x25e8')]?(_0x3206db=_0x5e9484,_0x39968f=_0x4a6e1c['session']):(_0x3206db=_0x4a6e1c[_0x26df39('0xd18')],_0x39968f=_0x5e9484),_0x39968f[_0x26df39('0x27ec')](_0x3206db[_0x26df39('0xc96')],{'replaces':_0x3206db,'eventHandlers':{'requestSucceeded':_0x358b87(_0x406d2e,_0x26df39('0x8ca'),_0x26df39('0x10e4'),0xbb8,_0x4a6e1c[_0x26df39('0x2021')]),'requestFailed':_0x358b87(_0x406d2e,_0x26df39('0x1d92'),_0x26df39('0x10e4'),0xbb8,_0x4a6e1c[_0x26df39('0x2021')])}});}function _0x358b87(_0x5e8152,_0x449309,_0x4d6e41,_0x4f3af4,_0x2acc70){const _0x267ff9=_0x145891;return console['debug'](_0x267ff9('0x1080'),_0x5e8152,_0x449309,_0x4d6e41,_0x4f3af4),function(){const _0x8b8f45=_0x267ff9;_0x3a9ee7[_0x8b8f45('0x1d4')](_0x3a9ee7[_0x8b8f45('0x277d')]()[_0x8b8f45('0x1525')](_0x449309)[_0x8b8f45('0x1233')](_0x4d6e41)[_0x8b8f45('0x2490')](_0x4f3af4)),_0x5e8152[_0x8b8f45('0x1a66')](),_0x5bc188&&_0x2acc70&&_0x5bc188[_0x8b8f45('0x1ecd')](),_0x2f42c8();};}function _0x2f42c8(_0x3a8112){const _0x265402=_0x145891;_0x2f88a9[_0x265402('0x1715')](_0x3a8112);}}const _0x195e0b=_0x4447b7;_0x1607bc[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x1f4a'),_0x189033('0x1357')];function _0x1607bc(_0x58b1d4,_0x4dcf7d,_0x1c780c){const _0x447520=_0x189033,_0x5815fd=this;_0x2e3ca0()['remove'](_0x1c780c,function(_0xe240a0){const _0x23d97a=a0_0x4e0a;return _0xe240a0[_0x23d97a('0x17c')]===_0x23d97a('0x1bd7')&&(_0xe240a0[_0x23d97a('0x1e16')]===_0x23d97a('0x9cb')||_0xe240a0[_0x23d97a('0x1e16')]===_0x23d97a('0xf4c'))||_0xe240a0[_0x23d97a('0x17c')]===_0x23d97a('0x1388')&&(_0xe240a0[_0x23d97a('0x1e16')]===_0x23d97a('0x9cb')||_0xe240a0[_0x23d97a('0x1e16')]==='communications');}),_0x4dcf7d[_0x447520('0x1eac')]=_0xc7593e(_0x1c780c,_0x447520('0x1388'),'ringingId'),_0x4dcf7d[_0x447520('0x902')]=_0xc7593e(_0x1c780c,_0x447520('0x1388'),_0x447520('0x902')),_0x4dcf7d[_0x447520('0x1dd6')]=_0xc7593e(_0x1c780c,_0x447520('0x1bd7'),'microphoneId'),_0x4dcf7d[_0x447520('0x184f')]=_0x4dcf7d[_0x447520('0x184f')]||0.5,_0x4dcf7d[_0x447520('0x86')]=_0x4dcf7d[_0x447520('0x86')]||0.5,_0x4dcf7d[_0x447520('0xd13')]=_0x4dcf7d[_0x447520('0xd13')]||0x1,_0x4dcf7d['ringingMute']=_0x4dcf7d['ringingMute']||![],_0x4dcf7d[_0x447520('0x1e34')]=_0x4dcf7d[_0x447520('0x1e34')]||![],_0x4dcf7d['microphoneMute']=_0x4dcf7d[_0x447520('0x16e9')]||![],_0x5815fd[_0x447520('0x1f4a')]=angular['copy'](_0x4dcf7d),_0x5815fd[_0x447520('0x1357')]=_0x1c780c,_0x5815fd[_0x447520('0x24b1')]=_0x46e395,_0x5815fd[_0x447520('0xf82')]=_0x4bd69e,_0x5815fd[_0x447520('0x946')]=_0xe05b41;function _0xe05b41(){const _0xeae814=_0x447520;return _0x5815fd[_0xeae814('0x1f4a')]['browserName']['toLowerCase']()===_0xeae814('0x1412')||_0x5815fd[_0xeae814('0x1f4a')][_0xeae814('0x1a84')][_0xeae814('0x93a')]()===_0xeae814('0x1336')||_0x5815fd['conf'][_0xeae814('0x1a84')][_0xeae814('0x93a')]()===_0xeae814('0x7a1');}function _0xc7593e(_0x5a419f,_0x21cc1e,_0x53a48a){const _0xbc9c1a=_0x447520;let _0x27c2b1;if(!_0x4dcf7d[_0x53a48a])_0x27c2b1=_0x2e3ca0()[_0xbc9c1a('0x1c07')](_0x5a419f,function(_0x449ce2){return _0x449ce2['kind']===_0x21cc1e;}),_0x27c2b1&&(_0x4dcf7d[_0x53a48a]=_0x27c2b1[_0xbc9c1a('0x1e16')]);else{_0x27c2b1=_0x2e3ca0()[_0xbc9c1a('0x1c07')](_0x5a419f,function(_0x186689){const _0x24d16f=_0xbc9c1a;return _0x186689[_0x24d16f('0x1e16')]===_0x4dcf7d[_0x53a48a];});if(_0x27c2b1)return _0x27c2b1['deviceId'];const _0x295880=_0x2e3ca0()['findIndex'](_0x5a419f,function(_0x4a243a){const _0x460760=_0xbc9c1a;return _0x4a243a[_0x460760('0x17c')]===_0x21cc1e;});if(_0x295880>=0x0)return _0x5a419f[_0x295880][_0xbc9c1a('0x1e16')];}return _0x4dcf7d[_0x53a48a]||null;}function _0x46e395(){const _0x50d8da=_0x447520;_0x58b1d4[_0x50d8da('0x1715')](_0x5815fd[_0x50d8da('0x1f4a')]);}function _0x4bd69e(){const _0x2d2772=_0x447520;_0x58b1d4[_0x2d2772('0x1715')]();}}const _0x4162ca=_0x1607bc,_0x168595=_0x180212['p']+_0x189033('0xa1f');_0x26ebff[_0x189033('0x14be')]=[_0x189033('0x241e'),_0x189033('0x1521')],_0x1841dd['$inject']=[_0x189033('0x14de'),_0x189033('0x691')];function _0x8d5cbd(){return{'restrict':'E','scope':{'query':'=','filters':'=','search':'&'},'controller':_0x1841dd,'controllerAs':'vm','bindToController':!![],'templateUrl':_0x168595};}function _0x1841dd(_0x2aa507,_0xd71449){const _0x561ad6=_0x189033,_0x9e7e26=this;_0x9e7e26[_0x561ad6('0x1372')]={},_0x9e7e26[_0x561ad6('0x2642')]={},_0x9e7e26[_0x561ad6('0x2620')]=_0x2aa507[_0x561ad6('0x2620')],_0x9e7e26['onMultiselectInit']=_0x54d50e,_0x9e7e26['onDateRangeInit']=_0x349fa8,_0x9e7e26[_0x561ad6('0x1cf3')]=_0x337dd0,_0x9e7e26[_0x561ad6('0x66e')]=_0x2952fd,_0x9e7e26[_0x561ad6('0x1fa0')]=_0x13f51a,_0x9e7e26[_0x561ad6('0x180a')]=_0x28e531,_0x9e7e26[_0x561ad6('0x18d2')]=_0x4ccda4;function _0x54d50e(_0xdaf3a0){_0x1621df(_0xdaf3a0);}function _0x349fa8(_0x1fe728){const _0x2e2ef0=_0x561ad6,_0xf451d=_0x1fe728['key'];_0x9e7e26[_0x2e2ef0('0x23a2')][_0xf451d]?_0x9e7e26['pickerModels'][_0xf451d]=_0x2aa507['setSelectedDate'](_0x9e7e26[_0x2e2ef0('0x23a2')][_0xf451d]):_0x9e7e26[_0x2e2ef0('0x1372')][_0xf451d]={'dateStart':null};}function _0x337dd0(_0x5184e0){const _0x7ef805=_0x561ad6;_0x1621df(_0x5184e0),_0x9e7e26[_0x7ef805('0x19a4')]();}function _0x2952fd(_0xc9ef80){const _0x4fc518=_0x561ad6,_0x2b7c31=_0xc9ef80['key'];_0x9e7e26[_0x4fc518('0x1372')][_0x2b7c31][_0x4fc518('0x1830')]?_0x9e7e26[_0x4fc518('0x23a2')][_0x2b7c31]={'$gte':_0x1aaf93()(_0x9e7e26[_0x4fc518('0x1372')][_0x2b7c31]['dateStart'])[_0x4fc518('0xb11')](0x0,!![])[_0x4fc518('0x26dd')](),'$lte':_0x1aaf93()(_0x9e7e26['pickerModels'][_0x2b7c31][_0x4fc518('0x13f3')])[_0x4fc518('0xb11')](0x0,!![])[_0x4fc518('0x23c6')](0x17,_0x4fc518('0x624'))[_0x4fc518('0x23c6')](0x3b,'minutes')[_0x4fc518('0x23c6')](0x3b,_0x4fc518('0x1b53'))[_0x4fc518('0x26dd')]()}:_0x9e7e26['query'][_0x2b7c31]=undefined,_0x9e7e26[_0x4fc518('0x19a4')]();}function _0x13f51a(_0x29989c){const _0x1b17a5=_0x561ad6,_0x5c63f6=_0x29989c['key'];_0x9e7e26[_0x1b17a5('0x1372')][_0x5c63f6]={'dateStart':null},delete _0x9e7e26['query'][_0x5c63f6],_0x9e7e26[_0x1b17a5('0x19a4')]();}function _0x4ccda4(_0x5c144e){const _0xe77ac=_0x561ad6,_0x14ac5c=_0x5c144e[_0xe77ac('0x1d46')],_0x5b492e=_0x5c144e[_0xe77ac('0xee7')]||'id';_0x9e7e26[_0xe77ac('0x23a2')][_0x14ac5c]=_0x2e3ca0()[_0xe77ac('0x386')](_0x5c144e[_0xe77ac('0x158e')],_0x5b492e),_0x1621df(_0x5c144e),_0x9e7e26[_0xe77ac('0x19a4')]();}function _0x28e531(_0x26fb0d){const _0x57aea9=_0x561ad6,_0x288aec=_0x26fb0d[_0x57aea9('0x1d46')],_0x3d77dc=_0x26fb0d[_0x57aea9('0xee7')]||'id';_0x9e7e26[_0x57aea9('0x23a2')][_0x288aec]=_0x26fb0d[_0x57aea9('0x271a')]===![]?[_0x2e3ca0()[_0x57aea9('0xd39')](_0x26fb0d[_0x57aea9('0x158e')])[_0x3d77dc]]:[],_0x1621df(_0x26fb0d),_0x9e7e26['search']();}function _0x1621df(_0x46d187){const _0xbe69da=_0x561ad6,_0x112b19=_0x46d187['key'],_0x48e68b={'param':_0x9e7e26[_0xbe69da('0x23a2')][_0x112b19],'resources':_0x46d187[_0xbe69da('0x158e')],'placeholder':_0x46d187[_0xbe69da('0x156b')],'ngValue':_0x46d187[_0xbe69da('0xee7')]};_0xd71449[_0xbe69da('0x1c76')](_0x48e68b)['then'](function(_0x3b522d){_0x9e7e26['placeholders'][_0x112b19]=_0x3b522d;});}}function _0x26ebff(_0x4b46e6,_0x312bd6){const _0x5bb047={'localizationMap':_0x312bd6,'setSelectedDate':_0x2b0737};function _0x2b0737(_0x516bab){const _0x3009d7=a0_0x4e0a,_0x521e74=new Date(_0x1aaf93()[_0x3009d7('0x9f1')](_0x516bab['$gte'])[_0x3009d7('0x26dd')](_0x3009d7('0x2d'))),_0x5a19a7=new Date(_0x1aaf93()[_0x3009d7('0x9f1')](_0x516bab[_0x3009d7('0x27ee')])[_0x3009d7('0x26dd')](_0x3009d7('0x2d'))),_0x5d4ced={'dateStart':new Date(_0x521e74['getFullYear'](),_0x521e74[_0x3009d7('0x110')](),_0x521e74[_0x3009d7('0x260f')]()),'dateEnd':new Date(_0x5a19a7['getFullYear'](),_0x5a19a7['getMonth'](),_0x5a19a7[_0x3009d7('0x260f')]())};return _0x5d4ced[_0x3009d7('0x26d3')]=_0x5c703e(_0x5d4ced),_0x5d4ced;}function _0x5c703e(_0x451095){const _0xfb46d8=a0_0x4e0a;if(_0x1aaf93()(_0x451095['dateStart'])[_0xfb46d8('0x1616')](_0x451095[_0xfb46d8('0x13f3')])){if(_0x32d99c(_0x451095))return _0x5bb047[_0xfb46d8('0x2620')][_0xfb46d8('0x5d5')];else return _0x3d7395(_0x451095)?_0x5bb047[_0xfb46d8('0x2620')][_0xfb46d8('0x178f')]:_0x4b46e6(_0xfb46d8('0x270e'))(_0x451095[_0xfb46d8('0x1830')],'dd\x20MMM\x20yyyy');}else{if(_0x16999a(_0x451095))return _0x5bb047[_0xfb46d8('0x2620')][_0xfb46d8('0x1be0')];else{if(_0x201a60(_0x451095))return _0x5bb047[_0xfb46d8('0x2620')][_0xfb46d8('0xaaa')];else{if(_0x24a8fd(_0x451095))return _0x5bb047['localizationMap'][_0xfb46d8('0x1153')];else{if(_0x3d358d(_0x451095))return _0x5bb047[_0xfb46d8('0x2620')][_0xfb46d8('0xc22')];else{if(_0x5d4e22(_0x451095))return _0x5bb047[_0xfb46d8('0x2620')][_0xfb46d8('0x262d')];else return _0x325308(_0x451095)?_0x5bb047[_0xfb46d8('0x2620')][_0xfb46d8('0x13a')]:_0x4b46e6(_0xfb46d8('0x270e'))(_0x451095[_0xfb46d8('0x1830')],'dd'+(_0x451095[_0xfb46d8('0x1830')][_0xfb46d8('0x110')]()!==_0x451095[_0xfb46d8('0x13f3')][_0xfb46d8('0x110')]()||_0x451095[_0xfb46d8('0x1830')][_0xfb46d8('0x6f7')]()!==_0x451095[_0xfb46d8('0x13f3')][_0xfb46d8('0x6f7')]()?_0xfb46d8('0x239c'):'')+(_0x451095[_0xfb46d8('0x1830')]['getFullYear']()!==_0x451095['dateEnd'][_0xfb46d8('0x6f7')]()?_0xfb46d8('0x157a'):''))+'\x20-\x20'+_0x4b46e6(_0xfb46d8('0x270e'))(_0x451095[_0xfb46d8('0x13f3')],_0xfb46d8('0x1b0a'));}}}}}}function _0x32d99c(_0x48c90e){const _0x2cb0a7=a0_0x4e0a;return _0x1aaf93()()[_0x2cb0a7('0x1627')](_0x2cb0a7('0x1efa'))[_0x2cb0a7('0x1616')](_0x48c90e[_0x2cb0a7('0x1830')]);}function _0x3d7395(_0x301468){const _0x1cd062=a0_0x4e0a;return _0x1aaf93()()[_0x1cd062('0x1315')](0x1,_0x1cd062('0x1044'))[_0x1cd062('0x1627')](_0x1cd062('0x1efa'))[_0x1cd062('0x1616')](_0x301468['dateStart']);}function _0x16999a(_0xc72b0f){const _0x446584=a0_0x4e0a;return _0x1aaf93()()[_0x446584('0x1627')](_0x446584('0xd16'))[_0x446584('0x1616')](_0xc72b0f[_0x446584('0x1830')],_0x446584('0x1efa'))&&_0x1aaf93()()['endOf'](_0x446584('0xd16'))[_0x446584('0x1616')](_0xc72b0f[_0x446584('0x13f3')],_0x446584('0x1efa'));}function _0x201a60(_0x22f116){const _0x1f3f47=a0_0x4e0a;return _0x1aaf93()()[_0x1f3f47('0x1315')](0x1,_0x1f3f47('0x14ea'))[_0x1f3f47('0x1627')](_0x1f3f47('0xd16'))['isSame'](_0x22f116[_0x1f3f47('0x1830')],_0x1f3f47('0x1efa'))&&_0x1aaf93()()['subtract'](0x1,'weeks')['endOf'](_0x1f3f47('0xd16'))[_0x1f3f47('0x1616')](_0x22f116[_0x1f3f47('0x13f3')],_0x1f3f47('0x1efa'));}function _0x24a8fd(_0x1fa1a2){const _0x3d339c=a0_0x4e0a;return _0x1aaf93()()[_0x3d339c('0x1627')]('month')['isSame'](_0x1fa1a2['dateStart'],_0x3d339c('0x1efa'))&&_0x1aaf93()()[_0x3d339c('0x3b3')](_0x3d339c('0x55b'))[_0x3d339c('0x1616')](_0x1fa1a2[_0x3d339c('0x13f3')],_0x3d339c('0x1efa'));}function _0x3d358d(_0x4619d9){const _0xdfce15=a0_0x4e0a;return _0x1aaf93()()[_0xdfce15('0x1315')](0x1,_0xdfce15('0x1bf'))[_0xdfce15('0x1627')](_0xdfce15('0x55b'))[_0xdfce15('0x1616')](_0x4619d9[_0xdfce15('0x1830')],_0xdfce15('0x1efa'))&&_0x1aaf93()()[_0xdfce15('0x1315')](0x1,'months')[_0xdfce15('0x3b3')]('month')[_0xdfce15('0x1616')](_0x4619d9[_0xdfce15('0x13f3')],_0xdfce15('0x1efa'));}function _0x5d4e22(_0x19283e){const _0x26a1bd=a0_0x4e0a;return _0x1aaf93()()[_0x26a1bd('0x1627')](_0x26a1bd('0x3a4'))[_0x26a1bd('0x1616')](_0x19283e[_0x26a1bd('0x1830')],_0x26a1bd('0x1efa'))&&_0x1aaf93()()[_0x26a1bd('0x3b3')](_0x26a1bd('0x3a4'))[_0x26a1bd('0x1616')](_0x19283e['dateEnd'],_0x26a1bd('0x1efa'));}function _0x325308(_0x2da315){const _0xe260b4=a0_0x4e0a;return _0x1aaf93()()[_0xe260b4('0x1315')](0x1,_0xe260b4('0x1fc3'))[_0xe260b4('0x1627')](_0xe260b4('0x3a4'))[_0xe260b4('0x1616')](_0x2da315['dateStart'],_0xe260b4('0x1efa'))&&_0x1aaf93()()[_0xe260b4('0x1315')](0x1,'years')[_0xe260b4('0x3b3')](_0xe260b4('0x3a4'))[_0xe260b4('0x1616')](_0x2da315['dateEnd'],'day');}return _0x5bb047;}function _0x2f3da1(){return{'restrict':'A','scope':{'msRandomClass':'='},'link':function(_0x279801,_0x25ac6e){const _0x258fe6=a0_0x4e0a,_0x16e62e=_0x279801[_0x258fe6('0x1947')][Math[_0x258fe6('0x16c9')](Math['random']()*_0x279801[_0x258fe6('0x1947')][_0x258fe6('0x1564')])];_0x25ac6e[_0x258fe6('0x81e')](_0x16e62e);}};}const _0x2c4ccc=_0x2f3da1;_0x3a7e48[_0x189033('0x14be')]=[_0x189033('0x56b')];function _0x3a7e48(_0x110cea){return{'restrict':'E','scope':{'id':'=','model':'=','download':'='},'replace':!![],'link':function(_0x1bd52b,_0x7ea15d){const _0x5573b7=a0_0x4e0a;let _0x3aa9bf=![];const _0x1b1785=document[_0x5573b7('0x1ffa')]('audio');!_0x1bd52b[_0x5573b7('0x18e8')]&&_0x1b1785[_0x5573b7('0x130f')](_0x5573b7('0x55d'),'nodownload'),_0x1b1785[_0x5573b7('0x130f')]('preload',_0x5573b7('0x925')),_0x1b1785['setAttribute']('controls',''),_0x1b1785[_0x5573b7('0x130f')]('style',_0x5573b7('0x2231')),_0x1b1785[_0x5573b7('0x130f')](_0x5573b7('0x262a'),'\x20'),_0x1b1785[_0x5573b7('0x2211')]=function(_0x5d6f04){const _0x59adc8=_0x5573b7;!_0x3aa9bf&&(_0x3aa9bf=!![],_0x5d6f04[_0x59adc8('0x1706')](),_0x110cea[_0x1bd52b[_0x59adc8('0x2437')]||_0x59adc8('0x52f')][_0x59adc8('0x18e8')]({'id':_0x1bd52b['id']})['$promise'][_0x59adc8('0x683')](function(_0x3a26ee){const _0x7c4820=_0x59adc8,_0x29acd4=[_0x3a26ee[_0x7c4820('0x1fb3')]],_0x54ae0b=new Blob(_0x29acd4,{'type':_0x3a26ee['type']});_0x1b1785[_0x7c4820('0x130f')](_0x7c4820('0xcf0'),_0x3a26ee[_0x7c4820('0xcf0')]),_0x1b1785[_0x7c4820('0x130f')](_0x7c4820('0x262a'),URL['createObjectURL'](_0x54ae0b)),_0x1b1785[_0x7c4820('0x10fa')]();})[_0x59adc8('0x130a')](function(_0x38c702){const _0x4dbe3c=_0x59adc8;console[_0x4dbe3c('0x52a')](_0x38c702);}));},_0x7ea15d[_0x5573b7('0x22d6')](_0x1b1785);}};}const _0x480f64=_0x3a7e48;function _0x588958(){return{'restrict':'A','link':function(_0x2a65e5,_0x423003){const _0x2b841c=a0_0x4e0a,_0x586f67=angular['element'](_0x2b841c('0x1f9d'));_0x423003[_0x2b841c('0x1d37')](_0x586f67),_0x586f67[_0x2b841c('0x22d6')](_0x423003);}};}const _0x349479=_0x588958;var _0x644bc6=_0x180212(0x1703),_0x242b3f=_0x180212['n'](_0x644bc6);_0x44b2e7[_0x189033('0x14be')]=[_0x189033('0x2f9'),_0x189033('0x2077'),'msUtils',_0x189033('0x59')];function _0x41c240(){const _0x54078a=_0x189033;let _0x3a33e8={'wheelSpeed':0x1,'wheelPropagation':![],'swipePropagation':!![],'minScrollbarLength':null,'maxScrollbarLength':null,'useBothWheelAxes':![],'useKeyboard':!![],'suppressScrollX':![],'suppressScrollY':![],'scrollXMarginOffset':0x0,'scrollYMarginOffset':0x0,'stopPropagationOnClick':!![]};this[_0x54078a('0x1862')]=function(){function _0x3f1d37(){return _0x3a33e8;}const _0x656727={'getConfig':_0x3f1d37};return _0x656727;};function _0x461428(_0x137385){_0x3a33e8=angular['extend']({},_0x3a33e8,_0x137385);}this['config']=_0x461428;}function _0x44b2e7(_0x485110,_0x2411f6,_0x2941a7,_0x1aa9d2){return{'restrict':'AE','compile':function(_0x6bba41){const _0x4ad616=a0_0x4e0a;if(_0x1aa9d2[_0x4ad616('0x1f6e')](_0x4ad616('0x1ed9')))return;if(_0x1aa9d2[_0x4ad616('0x1f6e')]('disableCustomScrollbarsOnMobile')&&_0x2941a7['isMobile']())return;return _0x6bba41[_0x4ad616('0x81e')](_0x4ad616('0x2558')),function _0x527773(_0x5e384a,_0x25ecf8,_0x1cc4e6){const _0x3ede69=_0x4ad616;let _0x41a528={};_0x1cc4e6[_0x3ede69('0x2585')]&&(_0x41a528=_0x5e384a['$eval'](_0x1cc4e6['msScroll']));_0x41a528=angular['extend']({},_0x2411f6[_0x3ede69('0x1f6e')](),_0x41a528),_0x242b3f()[_0x3ede69('0x262e')](_0x25ecf8[0x0],_0x41a528);function _0x11b0be(){const _0x49e079=_0x3ede69;_0x242b3f()[_0x49e079('0x2480')](_0x25ecf8[0x0]);}_0x25ecf8['on'](_0x3ede69('0x1229'),_0x11b0be),_0x5e384a[_0x3ede69('0x186d')](function(){const _0x21c628=_0x3ede69;return _0x25ecf8[_0x21c628('0x245f')]('scrollHeight');},function(_0x2f913e,_0x16df0f){const _0x46c1c4=_0x3ede69;if(angular[_0x46c1c4('0x105d')](_0x2f913e)||angular[_0x46c1c4('0xa18')](_0x2f913e,_0x16df0f))return;_0x11b0be();}),_0x5e384a[_0x3ede69('0x186d')](function(){const _0x5426ab=_0x3ede69;return _0x25ecf8[_0x5426ab('0x245f')](_0x5426ab('0xe3c'));},function(_0xe8ac61,_0x4ba161){const _0x129433=_0x3ede69;if(angular['isUndefined'](_0xe8ac61)||angular[_0x129433('0xa18')](_0xe8ac61,_0x4ba161))return;_0x11b0be();}),_0x5e384a[_0x3ede69('0x26a2')](_0x3ede69('0x4b8'),function(){const _0x2f8e3e=_0x3ede69;_0x25ecf8[_0x2f8e3e('0x2422')](_0x2f8e3e('0x1229')),_0x242b3f()[_0x2f8e3e('0x1b44')](_0x25ecf8[0x0]);});};}};}const _0x3c73a4=_0x180212['p']+'src/js/modules/core/directives/ms-search-bar/ms-search-bar.html/ms-search-bar.html';_0x3f0ab3[_0x189033('0x14be')]=[_0x189033('0x16ea')],_0x2dc548[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$element',_0x189033('0x2f9')];function _0x2dc548(_0x1657fd,_0x53f2aa,_0x3cbf0b){const _0x33da7a=_0x189033,_0x5c289f=this;_0x5c289f[_0x33da7a('0x1f9c')]=!![],_0x5c289f[_0x33da7a('0x23a2')]=undefined,_0x5c289f[_0x33da7a('0x1c7f')]={'debounce':_0x5c289f['debounce']||0x0};const _0x33b58f=_0x5c289f['collapseOnBlur']&&_0x5c289f[_0x33da7a('0x64f')]==_0x33da7a('0x26ac')?!![]:![];_0x5c289f[_0x33da7a('0x11fa')]=![],_0x5c289f[_0x33da7a('0x546')]=null,_0x5c289f['selectedResultIndex']=0x0,_0x5c289f[_0x33da7a('0xaeb')]=![],_0x5c289f[_0x33da7a('0x1dd2')]=_0x5bb4aa,_0x5c289f['populateResults']=_0x2b9298,_0x5c289f[_0x33da7a('0xf55')]=_0x389062,_0x5c289f[_0x33da7a('0x25bc')]=_0xbfe597,_0x5c289f[_0x33da7a('0xa6f')]=_0x15d865,_0x5c289f[_0x33da7a('0xf7f')]=_0x248526,_0x5c289f['handleKeydown']=_0x3c4116,_0x5c289f[_0x33da7a('0x1e8c')]=_0x2bd629,_0x5c289f[_0x33da7a('0xb9b')]=_0x2b3e73,_0x5c289f['handleResultClick']=_0x34f732,_0x5c289f[_0x33da7a('0x235d')]=_0x4758e1;function _0x5bb4aa(){const _0x2f742f=_0x33da7a;_0x1657fd[_0x2f742f('0x186d')](_0x2f742f('0xa24'),function(_0x1fabda,_0x19a3ac){const _0x2e4d12=_0x2f742f;if(angular['isUndefined'](_0x1fabda))return;if(angular[_0x2e4d12('0xa18')](_0x1fabda,_0x19a3ac))return;if(_0x5c289f['collapsed']){if(_0x1fabda)_0x1657fd[_0x2e4d12('0xf55')]();else return;}const _0x1afb86=_0x1657fd[_0x2e4d12('0x1cd5')]['$eval'](_0x5c289f['onSearch'],{'query':_0x1fabda}),_0x1f8801=angular[_0x2e4d12('0x94b')](_0x1afb86),_0x4fbb76=_0x1afb86&&!!_0x1afb86[_0x2e4d12('0x683')];_0x1f8801&&_0x5c289f['populateResults'](_0x1afb86),_0x4fbb76&&(_0x5c289f['resultsLoading']=!![],_0x1afb86[_0x2e4d12('0x683')](function(_0x5135de){_0x5c289f['populateResults'](_0x5135de);},function(){_0x5c289f['populateResults']([]);})[_0x2e4d12('0x2874')](function(){const _0xe9eae4=_0x2e4d12;_0x5c289f[_0xe9eae4('0x11fa')]=![];}));});}function _0x2b9298(_0x561c2e){const _0xa151c8=_0x33da7a;if(_0x5c289f[_0xa151c8('0x1f9c')])return;const _0x19f7cb=angular[_0xa151c8('0x94b')](_0x561c2e),_0x334f67=_0x561c2e===null;if(!_0x19f7cb&&!_0x334f67)return;_0x5c289f[_0xa151c8('0x15cb')]=0x0,_0x5c289f['results']=_0x561c2e;}function _0x389062(){const _0x5bc9d7=_0x33da7a;_0x5c289f[_0x5bc9d7('0x1f9c')]=![],_0x1657fd[_0x5bc9d7('0xf55')](),_0x5c289f[_0x5bc9d7('0x13fb')]&&angular['isFunction'](_0x5c289f[_0x5bc9d7('0x13fb')])&&_0x5c289f[_0x5bc9d7('0x13fb')]();}function _0xbfe597(){const _0x274893=_0x33da7a;_0x5c289f['query']='',_0x5c289f[_0x274893('0x192e')](null),_0x5c289f['collapsed']=!![],_0x1657fd[_0x274893('0x25bc')](),_0x5c289f[_0x274893('0x11a7')]&&angular[_0x274893('0x93f')](_0x5c289f[_0x274893('0x11a7')])&&_0x5c289f['onCollapse']();}function _0x15d865(){const _0x49dcf2=_0x33da7a;if(!_0x33b58f)return;_0x5c289f[_0x49dcf2('0x25bc')]();}function _0x248526(_0x3970b6){const _0x12e529=_0x33da7a;_0x3970b6[_0x12e529('0x1706')]();}function _0x3c4116(_0x32d60d){const _0x31b704=_0x33da7a,_0x3e013e=_0x32d60d[_0x31b704('0x1618')],_0x4818f7=[0x1b,0x26,0x28];_0x4818f7[_0x31b704('0x824')](_0x3e013e)>-0x1&&_0x32d60d[_0x31b704('0x1706')]();switch(_0x3e013e){case 0xd:if(!_0x5c289f[_0x31b704('0x546')])return;_0x5c289f['handleResultClick'](_0x5c289f[_0x31b704('0x546')][_0x5c289f['selectedResultIndex']]);break;case 0x1b:_0x5c289f[_0x31b704('0x25bc')]();break;case 0x26:_0x5c289f['selectedResultIndex']-0x1>=0x0&&(_0x5c289f[_0x31b704('0x15cb')]--,_0x5c289f[_0x31b704('0x235d')]());break;case 0x28:if(!_0x5c289f[_0x31b704('0x546')])return;_0x5c289f[_0x31b704('0x15cb')]+0x1<_0x5c289f['results'][_0x31b704('0x1564')]&&(_0x5c289f[_0x31b704('0x15cb')]++,_0x5c289f[_0x31b704('0x235d')]());break;default:break;}}function _0x2bd629(_0xf4a12c){const _0x291a49=_0x33da7a;if(_0x5c289f[_0x291a49('0xaeb')])return;_0x5c289f[_0x291a49('0x15cb')]=_0xf4a12c;}function _0x2b3e73(){const _0x4792e5=_0x33da7a;_0x5c289f[_0x4792e5('0xaeb')]=!![],_0x3cbf0b[_0x4792e5('0x19fb')](_0x5c289f[_0x4792e5('0xa63')]),_0x5c289f[_0x4792e5('0xa63')]=_0x3cbf0b(function(){const _0x429903=_0x4792e5;_0x5c289f[_0x429903('0xaeb')]=![];},0xfa);}function _0x34f732(_0x1f4e96){const _0x5c56c3=_0x33da7a;_0x5c289f[_0x5c56c3('0x44c')]&&_0x5c289f[_0x5c56c3('0x44c')]({'item':_0x1f4e96}),_0x5c289f[_0x5c56c3('0x25bc')]();}function _0x4758e1(){const _0x53747e=_0x33da7a,_0x577bef=_0x53f2aa[_0x53747e('0x1c07')](_0x53747e('0x1600')),_0x5bea40=angular[_0x53747e('0x1fcc')](_0x577bef[_0x53747e('0x1c07')](_0x53747e('0x16dd'))[_0x5c289f['selectedResultIndex']]);if(_0x577bef&&_0x5bea40){const _0x353227=_0x5bea40[_0x53747e('0x1233')]()[_0x53747e('0x16d7')]-0x8,_0x1180b3=_0x5bea40['position']()[_0x53747e('0x16d7')]+_0x5bea40[_0x53747e('0x66f')]()+0x8;_0x5c289f[_0x53747e('0xb9b')](),_0x577bef[_0x53747e('0x5ee')]()>_0x353227&&_0x577bef[_0x53747e('0x5ee')](_0x353227),_0x1180b3>_0x577bef[_0x53747e('0xf')]()+_0x577bef[_0x53747e('0x5ee')]()&&_0x577bef[_0x53747e('0x5ee')](_0x1180b3-_0x577bef[_0x53747e('0xf')]());}}}function _0x3f0ab3(_0xd8f494){const _0x40ffc1=_0x189033;return{'restrict':'E','scope':{},'require':'msSearchBar','controller':_0x40ffc1('0x2886'),'bindToController':{'query':'=?','debounce':'=?','direction':'@','iconColor':'@','onSearch':'@','onResultClick':'&?','onExpand':'&?','onCollapse':'&?','collapseOnBlur':'@'},'templateUrl':_0x3c73a4,'compile':function(_0x565078){const _0x340f45=_0x40ffc1;return _0x565078['addClass'](_0x340f45('0x2756')),function _0x32f0f2(_0x472e7,_0x3a5534){const _0x213b05=_0x340f45,_0x2eddb8=_0xd8f494[_0x213b05('0x1c07')](_0x213b05('0x18e5'));function _0x33be83(){const _0x1a00c0=_0x213b05;_0x3a5534[_0x1a00c0('0x81e')]('expanded');if(_0x472e7['vm'][_0x1a00c0('0x2655')]===_0x1a00c0('0x2785')){_0x3a5534['addClass'](_0x1a00c0('0x2785'));const _0x489edf=_0x3a5534[_0x1a00c0('0x16ad')](_0x1a00c0('0x17b7'));if(_0x489edf)_0x489edf[_0x1a00c0('0x81e')](_0x1a00c0('0x14ac'));}_0x2eddb8[_0x1a00c0('0x81e')](_0x1a00c0('0x25d7'));}function _0x21a013(){const _0x52e4d3=_0x213b05;_0x3a5534[_0x52e4d3('0x12a4')](_0x52e4d3('0x986'));if(_0x472e7['vm'][_0x52e4d3('0x2655')]===_0x52e4d3('0x2785')){_0x3a5534['removeClass']('down');const _0x56548a=_0x3a5534[_0x52e4d3('0x16ad')](_0x52e4d3('0x17b7'));if(_0x56548a)_0x56548a[_0x52e4d3('0x12a4')](_0x52e4d3('0x14ac'));}_0x2eddb8[_0x52e4d3('0x12a4')]('ms-search-bar-expanded');}_0x472e7[_0x213b05('0x25bc')]=_0x21a013,_0x472e7[_0x213b05('0xf55')]=_0x33be83;};}};}const _0x14e82a=_0x180212['p']+'src/js/modules/core/directives/ms-shortcuts/ms-shortcuts.html/ms-shortcuts.html';_0x4d9ba9[_0x189033('0x14be')]=['$scope',_0x189033('0x17e4'),_0x189033('0x16ea'),'$timeout','$q',_0x189033('0x27c0')];function _0x4d9ba9(_0x240569,_0x4fc9e9,_0x12b4d5,_0x15744d,_0x453660,_0xe0e177){const _0x649ab2=_0x189033,_0x1540ca=this;_0x1540ca['query']='',_0x1540ca[_0x649ab2('0x1c7f')]={'debounce':0x12c},_0x1540ca['resultsLoading']=![],_0x1540ca[_0x649ab2('0x15cb')]=0x0,_0x1540ca[_0x649ab2('0xaeb')]=![],_0x1540ca[_0x649ab2('0xda5')]=![],_0x1540ca[_0x649ab2('0x546')]=null,_0x1540ca['shortcuts']=[],_0x1540ca[_0x649ab2('0xe48')]={'ghostClass':_0x649ab2('0x215a'),'forceFallback':!![],'fallbackClass':_0x649ab2('0x1e7f'),'onSort':function(){const _0x7a2cf4=_0x649ab2;_0x1540ca[_0x7a2cf4('0xad6')]();}};function _0x1d136d(){const _0x1be9c7=_0x649ab2;_0x1540ca[_0x1be9c7('0xc10')]()[_0x1be9c7('0x683')](function(_0x404569){const _0x56eb3a=_0x1be9c7;_0x1540ca[_0x56eb3a('0x38c')]=_0x404569,_0x1540ca[_0x56eb3a('0x38c')][_0x56eb3a('0x1564')]>0x0&&(_0x1540ca[_0x56eb3a('0x546')]=_0x404569);}),_0x240569['$watch'](_0x1be9c7('0xaa6'),function(_0x3d363a,_0x583748){const _0x2a6174=_0x1be9c7;if(angular[_0x2a6174('0x105d')](_0x3d363a))return;if(angular[_0x2a6174('0xa18')](_0x3d363a,_0x583748))return;_0x1540ca[_0x2a6174('0x11fa')]=!![],_0x1540ca['populateResults']()['then'](function(_0x370268){_0x1540ca['results']=_0x370268;},function(){const _0x2f120d=_0x2a6174;_0x1540ca[_0x2f120d('0x546')]=[];})['finally'](function(){const _0x17fcc4=_0x2a6174;_0x1540ca[_0x17fcc4('0x11fa')]=![];});});}function _0x562c43(){const _0x5615fb=_0x649ab2;let _0x25359e=[];const _0x1c3aa0=_0xe0e177['getFlatNavigation'](),_0x1f6524=_0x453660[_0x5615fb('0x448')]();for(let _0x2d9470=0x0;_0x2d9470<_0x1c3aa0[_0x5615fb('0x1564')];_0x2d9470++){_0x1c3aa0[_0x2d9470]['uisref']&&_0x25359e['push'](_0x1c3aa0[_0x2d9470]);}if(_0x1540ca[_0x5615fb('0x23a2')]){_0x25359e=_0x25359e[_0x5615fb('0x25')](function(_0x5e9d40){const _0x46e135=_0x5615fb;if(_0x5e9d40[_0x46e135('0xf28')][_0x46e135('0x93a')]()[_0x46e135('0x2292')](_0x1540ca['query']['toLowerCase']()))return!![];});for(let _0x31d428=0x0;_0x31d428<_0x25359e['length'];_0x31d428++){_0x25359e[_0x31d428][_0x5615fb('0x200b')]=![];for(let _0x541e7f=0x0;_0x541e7f<_0x1540ca['shortcuts'][_0x5615fb('0x1564')];_0x541e7f++){if(_0x1540ca[_0x5615fb('0x38c')][_0x541e7f]['_id']===_0x25359e[_0x31d428][_0x5615fb('0x25e6')]){_0x25359e[_0x31d428][_0x5615fb('0x200b')]=!![];break;}}}}else _0x1540ca['shortcuts'][_0x5615fb('0x1564')]>0x0&&(_0x25359e=_0x1540ca[_0x5615fb('0x38c')]);return _0x1540ca[_0x5615fb('0x15cb')]=0x0,_0x15744d(function(){const _0x28f572=_0x5615fb;_0x1f6524[_0x28f572('0xed7')](_0x25359e);},0xfa),_0x1f6524[_0x5615fb('0x1883')];}function _0x103a86(){const _0x58a338=_0x649ab2,_0x50e27a=_0x453660['defer']();let _0x1a79e4=angular[_0x58a338('0x1cb2')](_0x4fc9e9[_0x58a338('0x1e6e')](_0x58a338('0x1750')));return angular['isUndefined'](_0x1a79e4)&&(_0x1a79e4=[{'title':_0x58a338('0x1bc0'),'icon':_0x58a338('0x27d'),'state':_0x58a338('0x1550'),'weight':0x5,'children':[],'uisref':'app.staff.agents','hasShortcut':!![]},{'title':_0x58a338('0x104e'),'icon':'icon-cog','state':'app.settings.license','weight':0xa,'children':[],'uisref':'app.settings.license','hasShortcut':!![]}],_0x4fc9e9['put']('motion.shortcuts',angular[_0x58a338('0x1bf7')](_0x1a79e4))),_0x50e27a[_0x58a338('0xed7')](_0x1a79e4),_0x50e27a[_0x58a338('0x1883')];}function _0x1ac5bd(){const _0x18f59e=_0x649ab2,_0x27e55f=_0x453660[_0x18f59e('0x448')]();return _0x4fc9e9['put'](_0x18f59e('0x1750'),angular[_0x18f59e('0x1bf7')](_0x1540ca['shortcuts'])),_0x15744d(function(){const _0x44dbf9=_0x18f59e;_0x27e55f[_0x44dbf9('0xed7')]({'success':!![]});},0xfa),_0x27e55f[_0x18f59e('0x1883')];}function _0x121aee(_0x13bc11){const _0xb71813=_0x649ab2;_0x13bc11['hasShortcut']=!![],_0x1540ca[_0xb71813('0x38c')][_0xb71813('0x1fd0')](_0x13bc11),_0x1540ca[_0xb71813('0xad6')]();}function _0x4ec957(_0xc6aefa){const _0x397530=_0x649ab2;_0xc6aefa[_0x397530('0x200b')]=![];for(let _0x308abb=0x0;_0x308abb<_0x1540ca[_0x397530('0x38c')]['length'];_0x308abb++){_0x1540ca[_0x397530('0x38c')][_0x308abb][_0x397530('0x25e6')]===_0xc6aefa['_id']&&(_0x1540ca[_0x397530('0x38c')][_0x397530('0x2040')](_0x308abb,0x1),!_0x1540ca['query']&&(_0x1540ca['shortcuts'][_0x397530('0x1564')]===0x0?_0x1540ca[_0x397530('0x546')]=null:_0x308abb>=_0x1540ca[_0x397530('0x38c')]['length']&&(_0x1540ca[_0x397530('0x15cb')]=_0x1540ca['shortcuts'][_0x397530('0x1564')]-0x1)));}_0x1540ca[_0x397530('0xad6')]();}function _0x15f1c8(_0x151108){const _0x26f684=_0x649ab2;_0x151108[_0x26f684('0x200b')]?_0x1540ca[_0x26f684('0x1a76')](_0x151108):_0x1540ca['addShortcut'](_0x151108);}function _0x3d2347(_0x28c3f1){const _0x7562a6=_0x649ab2;_0x28c3f1[_0x7562a6('0x1706')]();}function _0x182f4(_0x2be014){const _0x5c8540=_0x649ab2,_0x1b2579=_0x2be014[_0x5c8540('0x1618')],_0x5e1336=[0x26,0x28];_0x5e1336[_0x5c8540('0x824')](_0x1b2579)>-0x1&&_0x2be014[_0x5c8540('0x1706')]();switch(_0x1b2579){case 0xd:_0x1540ca['handleResultClick'](_0x1540ca[_0x5c8540('0x546')][_0x1540ca[_0x5c8540('0x15cb')]]);break;case 0x26:_0x1540ca[_0x5c8540('0x15cb')]-0x1>=0x0&&(_0x1540ca[_0x5c8540('0x15cb')]--,_0x1540ca[_0x5c8540('0x235d')]());break;case 0x28:_0x1540ca[_0x5c8540('0x15cb')]+0x1<_0x1540ca['results'][_0x5c8540('0x1564')]&&(_0x1540ca[_0x5c8540('0x15cb')]++,_0x1540ca[_0x5c8540('0x235d')]());break;default:break;}}function _0xd2dab1(_0x310250){const _0x109ee6=_0x649ab2;if(_0x1540ca['ignoreMouseEvents'])return;_0x1540ca[_0x109ee6('0x15cb')]=_0x310250;}function _0x1cfa07(){const _0x28ccce=_0x649ab2;_0x1540ca['ignoreMouseEvents']=!![],_0x15744d[_0x28ccce('0x19fb')](_0x1540ca[_0x28ccce('0xa63')]),_0x1540ca['mouseEventIgnoreTimeout']=_0x15744d(function(){const _0x5f09bb=_0x28ccce;_0x1540ca[_0x5f09bb('0xaeb')]=![];},0xfa);}function _0x27824e(){const _0x269277=_0x649ab2,_0x3c6f91=_0x12b4d5[_0x269277('0x1c07')](_0x269277('0x26e5'))['find'](_0x269277('0x469')),_0x55f1f7=angular[_0x269277('0x1fcc')](_0x3c6f91[_0x269277('0x1c07')](_0x269277('0x16dd'))[_0x1540ca['selectedResultIndex']]);if(_0x3c6f91&&_0x55f1f7){const _0xb786dc=_0x55f1f7[_0x269277('0x1233')]()['top']-0x8,_0x4d0c5c=_0x55f1f7[_0x269277('0x1233')]()[_0x269277('0x16d7')]+_0x55f1f7[_0x269277('0x66f')]()+0x8;_0x1540ca[_0x269277('0xb9b')](),_0x3c6f91[_0x269277('0x5ee')]()>_0xb786dc&&_0x3c6f91[_0x269277('0x5ee')](_0xb786dc),_0x4d0c5c>_0x3c6f91[_0x269277('0xf')]()+_0x3c6f91[_0x269277('0x5ee')]()&&_0x3c6f91['scrollTop'](_0x4d0c5c-_0x3c6f91[_0x269277('0xf')]());}}function _0x3bbcc5(){const _0x2f79f5=_0x649ab2;_0x1540ca[_0x2f79f5('0xda5')]=!_0x1540ca[_0x2f79f5('0xda5')];}_0x1540ca['populateResults']=_0x562c43,_0x1540ca[_0x649ab2('0xc10')]=_0x103a86,_0x1540ca[_0x649ab2('0xad6')]=_0x1ac5bd,_0x1540ca[_0x649ab2('0x86a')]=_0x121aee,_0x1540ca[_0x649ab2('0x1a76')]=_0x4ec957,_0x1540ca[_0x649ab2('0xb3a')]=_0x15f1c8,_0x1540ca['absorbEvent']=_0x3d2347,_0x1540ca['handleKeydown']=_0x182f4,_0x1540ca[_0x649ab2('0x1e8c')]=_0xd2dab1,_0x1540ca['temporarilyIgnoreMouseEvents']=_0x1cfa07,_0x1540ca[_0x649ab2('0x235d')]=_0x27824e,_0x1540ca[_0x649ab2('0xa4d')]=_0x3bbcc5,_0x1d136d();}function _0x46a3a9(){const _0x149996=_0x189033;return{'restrict':'E','scope':{},'require':_0x149996('0x47a'),'controller':'MsShortcutsController\x20as\x20MsShortcuts','bindToController':{},'templateUrl':_0x14e82a,'compile':function(_0x19350c){const _0x51e329=_0x149996;return _0x19350c[_0x51e329('0x81e')](_0x51e329('0x169b')),function _0x607ffd(){};}};}function _0x3a601d(){return{'restrict':'A','require':'^mdSidenav','link':function(_0x1801bb,_0x25c456,_0x47dc46,_0x3e95bb){const _0x3c63d3=a0_0x4e0a;_0x1801bb[_0x3c63d3('0x186d')](function(){const _0xa2d3c9=_0x3c63d3;return _0x3e95bb[_0xa2d3c9('0x15')]()&&!_0x3e95bb['isLockedOpen']();},function(_0x354cd2){const _0x4bede3=_0x3c63d3;if(angular[_0x4bede3('0x105d')](_0x354cd2))return;_0x25c456[_0x4bede3('0x2361')]()[_0x4bede3('0x7b8')](_0x4bede3('0xf62'),_0x354cd2),angular[_0x4bede3('0x1fcc')]('html')['toggleClass']('sidenav-open',_0x354cd2);});}};}const _0x29127c=_0x3a601d;_0x50ba92['$inject']=[_0x189033('0x133')];function _0x50ba92(_0x40732b){return{'restrict':'E','link':function(_0x4b98cf,_0x57ee22){const _0x5a65a8=a0_0x4e0a,_0x5400d4=_0x4b98cf[_0x5a65a8('0x26a2')](_0x5a65a8('0x2208'),function(){const _0xd20ee0=_0x5a65a8;_0x40732b[_0xd20ee0('0x37a')](_0x57ee22)[_0xd20ee0('0x683')](function(){_0x5400d4(),_0x4b98cf=null,_0x57ee22=null;});});}};}const _0x2a67a6=_0x50ba92,_0x28b7e6=_0x180212['p']+_0x189033('0x765'),_0x2b92b2=_0x180212['p']+_0x189033('0xe78'),_0x3a095a=_0x180212['p']+_0x189033('0x94d');_0x5db1a1[_0x189033('0x14be')]=['$timeout'],_0x48c014[_0x189033('0x14be')]=[_0x189033('0x2f9')];function _0x48c014(_0x12c002){const _0x3825dc=_0x189033,_0x40a913=this;_0x40a913[_0x3825dc('0x3e6')]=undefined,_0x40a913['orientation']=_0x3825dc('0x10a6'),_0x40a913[_0x3825dc('0x243e')]=[],_0x40a913['currentStep']=undefined,_0x40a913[_0x3825dc('0x648')]=0x1;function _0x11959c(_0x458e83){const _0x2cd4f5=_0x3825dc;return!(angular[_0x2cd4f5('0x105d')](_0x458e83)||_0x458e83<0x1||_0x458e83>_0x40a913['steps'][_0x2cd4f5('0x1564')]);}function _0x110490(_0x3d1692){const _0x28269e=_0x3825dc;_0x40a913[_0x28269e('0x1216')]=_0x3d1692||_0x28269e('0x10a6');}function _0x23590a(_0x2d3c98){const _0x59b84b=_0x3825dc;_0x40a913[_0x59b84b('0x3e6')]=_0x2d3c98;}function _0x94c770(){const _0x250f65=_0x3825dc;_0x40a913[_0x250f65('0x1e21')](0x1);}function _0x5946bc(_0x374b8b){const _0x4b3b34=_0x3825dc;if(!_0x11959c(_0x374b8b))return null;return!!_0x40a913[_0x4b3b34('0x243e')][_0x374b8b-0x1][_0x4b3b34('0x2090')][_0x4b3b34('0x400')];}function _0x20a413(_0x3e15f7,_0x3ae0c7,_0x9f4edc){const _0x2a469d=_0x3825dc,_0x449178={'element':_0x3e15f7,'scope':_0x3ae0c7,'form':_0x9f4edc,'stepNumber':_0x3ae0c7[_0x2a469d('0x35a')]||_0x40a913[_0x2a469d('0x243e')][_0x2a469d('0x1564')]+0x1,'stepTitle':_0x3ae0c7['stepTitle'],'stepTitleTranslate':_0x3ae0c7[_0x2a469d('0x1f0d')]};return _0x40a913['steps'][_0x2a469d('0x1fd0')](_0x449178),_0x40a913['steps'][_0x2a469d('0x671')](function(_0x16b204,_0x51873e){const _0x5a58b4=_0x2a469d;return _0x16b204[_0x5a58b4('0x167f')]-_0x51873e['stepNumber'];}),_0x449178;}function _0x2c31b1(){const _0x336f73=_0x3825dc;_0x40a913[_0x336f73('0x1e21')](_0x40a913['currentStepNumber']);}function _0x2cd8c6(){_0x12c002(function(){const _0x4dd3f4=a0_0x4e0a;for(let _0x546675=0x0;_0x546675<_0x40a913[_0x4dd3f4('0x243e')][_0x4dd3f4('0x1564')];_0x546675++){_0x40a913[_0x4dd3f4('0x243e')][_0x546675]['form'][_0x4dd3f4('0x272a')](),_0x40a913['steps'][_0x546675][_0x4dd3f4('0x2744')][_0x4dd3f4('0x2256')]();}_0x40a913[_0x4dd3f4('0x3e6')]['$setPristine'](),_0x40a913[_0x4dd3f4('0x3e6')][_0x4dd3f4('0x2256')](),_0x94c770();});}function _0x136094(_0x391a01){const _0x3ca985=_0x3825dc;if(!_0x11959c(_0x391a01))return;_0x40a913[_0x3ca985('0x648')]=_0x391a01;if(_0x40a913[_0x3ca985('0x1216')]===_0x3ca985('0x10a6')){for(let _0xe4e494=0x0;_0xe4e494<_0x40a913[_0x3ca985('0x243e')][_0x3ca985('0x1564')];_0xe4e494++){_0x40a913[_0x3ca985('0x243e')][_0xe4e494][_0x3ca985('0x1fcc')][_0x3ca985('0x1715')]();}_0x40a913[_0x3ca985('0x243e')][_0x40a913[_0x3ca985('0x648')]-0x1][_0x3ca985('0x1fcc')][_0x3ca985('0x1d4')]();}else{if(_0x40a913[_0x3ca985('0x1216')]==='vertical'){for(let _0x3c99b7=0x0;_0x3c99b7<_0x40a913[_0x3ca985('0x243e')][_0x3ca985('0x1564')];_0x3c99b7++){_0x40a913[_0x3ca985('0x243e')][_0x3c99b7][_0x3ca985('0x1fcc')][_0x3ca985('0x1c07')]('.ms-stepper-step-content')[_0x3ca985('0x1715')]();}_0x40a913[_0x3ca985('0x243e')][_0x40a913[_0x3ca985('0x648')]-0x1]['element']['find']('.ms-stepper-step-content')[_0x3ca985('0x1d4')]();}}}function _0x279371(_0x52b39e){const _0x3225a5=_0x3825dc;if(_0x5946bc(_0x52b39e))return;_0x40a913[_0x3225a5('0x1e21')](_0x52b39e);}function _0x4eaca5(){let _0x792f39=_0x40a913['currentStepNumber']-0x1;for(let _0x1a4953=_0x792f39;_0x1a4953>=0x1;_0x1a4953--){if(!_0x5946bc(_0x1a4953)){_0x792f39=_0x1a4953;break;}}_0x40a913['setCurrentStep'](_0x792f39);}function _0x74b01f(){const _0x577e50=_0x3825dc;let _0x24cfd6=_0x40a913[_0x577e50('0x648')]+0x1;for(let _0x142079=_0x24cfd6;_0x142079<=_0x40a913[_0x577e50('0x243e')][_0x577e50('0x1564')];_0x142079++){if(!_0x5946bc(_0x142079)){_0x24cfd6=_0x142079;break;}}_0x40a913[_0x577e50('0x1e21')](_0x24cfd6);}function _0x3236ed(){const _0x30b72b=_0x3825dc;_0x40a913[_0x30b72b('0x1e21')](_0x40a913[_0x30b72b('0x243e')][_0x30b72b('0x1564')]);}function _0x196e59(){const _0x48b16d=_0x3825dc;return _0x40a913[_0x48b16d('0x648')]===0x1;}function _0x4b0c7a(){const _0x2043c8=_0x3825dc;return _0x40a913[_0x2043c8('0x648')]===_0x40a913[_0x2043c8('0x243e')][_0x2043c8('0x1564')];}function _0x5e5bef(_0x5099c7){const _0x379a69=_0x3825dc;if(!_0x11959c(_0x5099c7))return null;return _0x40a913[_0x379a69('0x648')]===_0x5099c7;}function _0x4a8322(_0x3f9048){const _0x5af8bd=_0x3825dc;if(!_0x11959c(_0x3f9048))return null;return _0x40a913[_0x5af8bd('0x243e')][_0x3f9048-0x1][_0x5af8bd('0x2090')][_0x5af8bd('0x1dae')];}function _0x3d72de(_0x35f8cf){const _0xaa24b=_0x3825dc;if(!_0x11959c(_0x35f8cf))return null;if(_0x4a8322(_0x35f8cf))return!![];return _0x40a913[_0xaa24b('0x243e')][_0x35f8cf-0x1]['form'][_0xaa24b('0x3c8')];}function _0x46fe47(_0x3fae72){if(!_0x11959c(_0x3fae72))return null;let _0x57b215=![];for(let _0x215a46=0x1;_0x215a46<_0x3fae72;_0x215a46++){if(!_0x3d72de(_0x215a46)){_0x57b215=!![];break;}}return _0x57b215;}function _0x38128b(_0x96bcf6){return!_0x5946bc(_0x96bcf6['stepNumber']);}function _0x4b1e5b(){const _0x3e0bb5=_0x3825dc;return _0x40a913['mainForm'][_0x3e0bb5('0x3c8')];}_0x40a913[_0x3825dc('0x20aa')]=_0x110490,_0x40a913[_0x3825dc('0x174f')]=_0x23590a,_0x40a913[_0x3825dc('0x235f')]=_0x20a413,_0x40a913[_0x3825dc('0x30f')]=_0x2c31b1,_0x40a913[_0x3825dc('0xbba')]=_0x2cd8c6,_0x40a913[_0x3825dc('0x1e21')]=_0x136094,_0x40a913[_0x3825dc('0x769')]=_0x279371,_0x40a913[_0x3825dc('0x16d6')]=_0x4eaca5,_0x40a913[_0x3825dc('0x169a')]=_0x74b01f,_0x40a913[_0x3825dc('0x2164')]=_0x94c770,_0x40a913[_0x3825dc('0x482')]=_0x3236ed,_0x40a913[_0x3825dc('0xf47')]=_0x196e59,_0x40a913['isLastStep']=_0x4b0c7a,_0x40a913[_0x3825dc('0x2603')]=_0x5e5bef,_0x40a913[_0x3825dc('0xa4a')]=_0x46fe47,_0x40a913[_0x3825dc('0x1dc2')]=_0x4a8322,_0x40a913['isStepHidden']=_0x5946bc,_0x40a913[_0x3825dc('0x1a8b')]=_0x38128b,_0x40a913[_0x3825dc('0x219f')]=_0x3d72de,_0x40a913[_0x3825dc('0x21f')]=_0x11959c,_0x40a913[_0x3825dc('0x95c')]=_0x4b1e5b;}function _0x3e3b09(){const _0xdbdef3=_0x189033;return{'restrict':'A','scope':{},'require':[_0xdbdef3('0x2744'),_0xdbdef3('0x468')],'priority':0x3e9,'controller':_0xdbdef3('0xab9'),'bindToController':{'model':_0xdbdef3('0xa11')},'transclude':!![],'templateUrl':_0x28b7e6,'compile':function(_0x501c6d){return _0x501c6d['addClass']('ms-stepper'),function _0x1683e5(_0x147a54,_0x3ca933,_0x3a25f1,_0x2c96b5){const _0x1d2aab=a0_0x4e0a,_0x2cd228=_0x2c96b5[0x0],_0x142c44=_0x2c96b5[0x1];_0x142c44[_0x1d2aab('0x20aa')]('horizontal'),_0x142c44[_0x1d2aab('0x174f')](_0x2cd228),_0x142c44[_0x1d2aab('0x30f')]();};}};}function _0x3e5895(){const _0x269c09=_0x189033;return{'restrict':'E','require':[_0x269c09('0x2744'),_0x269c09('0x1dbb')],'priority':0x3e8,'scope':{'step':'=?','stepTitle':'=?','stepTitleTranslate':'=?','optionalStep':'=?','hideStep':'=?'},'compile':function(_0x260fa4){const _0xad41b0=_0x269c09;return _0x260fa4[_0xad41b0('0x81e')](_0xad41b0('0x1772')),function _0x23459f(_0x515d5c,_0x26ef78,_0x9c4da,_0x374253){const _0x4c8a80=_0xad41b0,_0x3b6c67=_0x374253[0x0],_0x1898f2=_0x374253[0x1];_0x515d5c[_0x4c8a80('0x1dae')]=angular['isDefined'](_0x9c4da['optionalStep']),_0x1898f2['registerStep'](_0x26ef78,_0x515d5c,_0x3b6c67),_0x26ef78[_0x4c8a80('0x1715')]();};}};}function _0x5db1a1(_0x1179cb){const _0x1e9bd8=_0x189033;return{'restrict':'A','scope':{},'require':[_0x1e9bd8('0x2744'),_0x1e9bd8('0x126')],'priority':0x3e9,'controller':'MsStepperController\x20as\x20MsStepper','bindToController':{'model':_0x1e9bd8('0xa11')},'transclude':!![],'templateUrl':_0x2b92b2,'compile':function(_0x298dc4){const _0x1bfb84=_0x1e9bd8;return _0x298dc4['addClass'](_0x1bfb84('0xdc0')),function _0x3ceff4(_0x3c2cb8,_0x23f25e,_0x2ec0e4,_0x47519a){const _0x4a6c42=_0x47519a[0x0],_0x4a9aac=_0x47519a[0x1];_0x1179cb(function(){const _0xfd446a=a0_0x4e0a;_0x4a9aac[_0xfd446a('0x20aa')]('vertical'),_0x4a9aac['registerMainForm'](_0x4a6c42),_0x4a9aac[_0xfd446a('0x30f')]();});};}};}function _0x1f3ead(){const _0x3b8209=_0x189033;return{'restrict':'E','require':[_0x3b8209('0x2744'),_0x3b8209('0x1ebb')],'priority':0x3e8,'scope':{'step':'=?','stepTitle':'=?','stepTitleTranslate':'=?','optionalStep':'=?','hideStep':'=?'},'transclude':!![],'templateUrl':-_0x3a095a,'compile':function(_0x329caa){const _0x4dc0c4=_0x3b8209;return _0x329caa[_0x4dc0c4('0x81e')](_0x4dc0c4('0x1772')),function _0x2451ae(_0x102151,_0x5c620a,_0x2b6693,_0x580cae){const _0x37baf3=_0x4dc0c4,_0x53fd48=_0x580cae[0x0],_0x1e6062=_0x580cae[0x1];_0x102151[_0x37baf3('0x1dae')]=angular['isDefined'](_0x2b6693[_0x37baf3('0x1dae')]),_0x102151['stepInfo']=_0x1e6062[_0x37baf3('0x235f')](_0x5c620a,_0x102151,_0x53fd48),_0x102151['MsStepper']=_0x1e6062,_0x5c620a[_0x37baf3('0x1c07')]('.ms-stepper-step-content')[_0x37baf3('0x1715')]();};}};}const _0x54b1ff=_0x180212['p']+_0x189033('0x85d');;function _0x12898f(){const _0x10afdb=_0x189033,_0x1275e9=this;_0x1275e9[_0x10afdb('0x19e3')]=_0x37fcea,_0x1275e9['canScroll']=_0x4f6d0d;function _0x37fcea(_0x2ce972){const _0x1a0f83=_0x10afdb;_0x2ce972=='left'?$(_0x1a0f83('0x2661'))[_0x1a0f83('0x19cc')]()[_0x1a0f83('0x1219')]({'scrollLeft':_0x1a0f83('0x1c5b')},0x3e8):$(_0x1a0f83('0x2661'))[_0x1a0f83('0x19cc')]()[_0x1a0f83('0x1219')]({'scrollLeft':'+=400'},0x3e8);}function _0x4f6d0d(_0x3a2fbf){const _0x6346cd=_0x10afdb;switch(_0x83cee7()){case _0x6346cd('0x16fd'):return!![];case _0x6346cd('0xc0e'):return _0x3a2fbf==_0x6346cd('0xc0e')?!![]:![];case _0x6346cd('0x20b1'):return _0x3a2fbf==_0x6346cd('0x20b1')?!![]:![];case _0x6346cd('0x925'):return![];default:return![];}}function _0x83cee7(){const _0x431db1=_0x10afdb,_0x145e00=document[_0x431db1('0x1759')](_0x431db1('0x2342')),_0x356b13=document[_0x431db1('0x1759')](_0x431db1('0x16a'));if(_0x356b13[_0x431db1('0xe3c')]>_0x145e00[_0x431db1('0xe3c')]&&_0x145e00[_0x431db1('0x117d')]==0x0&&_0x356b13[_0x431db1('0x117d')]==0x0)return _0x431db1('0x20b1');else{if(_0x356b13[_0x431db1('0xe3c')]>_0x145e00[_0x431db1('0xe3c')]&&_0x356b13[_0x431db1('0x117d')]>_0x145e00['scrollLeft']&&_0x145e00[_0x431db1('0xe3c')]+_0x356b13[_0x431db1('0x117d')]>=_0x356b13[_0x431db1('0xe3c')])return _0x431db1('0xc0e');else return _0x356b13[_0x431db1('0xe3c')]>_0x145e00['scrollWidth']&&_0x356b13[_0x431db1('0x117d')]>_0x145e00['scrollLeft']&&_0x145e00[_0x431db1('0xe3c')]+_0x356b13[_0x431db1('0x117d')]<_0x356b13[_0x431db1('0xe3c')]?_0x431db1('0x16fd'):_0x431db1('0x925');}}}function _0x2e0d2d(){const _0x4b5463=_0x189033;return{'restrict':'E','scope':{},'transclude':!![],'controller':_0x4b5463('0x2848'),'controllerAs':'vm','bindToController':!![],'templateUrl':_0x54b1ff,'compile':function(_0x368085){const _0x17e74a=_0x4b5463;return _0x368085['addClass'](_0x17e74a('0x17b')),function _0x17ad6e(){};}};}_0x48e709['$inject']=[_0x189033('0x2f9'),'$q'];function _0x565ba8(){const _0x1b6424=_0x189033,_0x486c9c=this;_0x486c9c['scrollEl']=undefined,_0x486c9c[_0x1b6424('0x22e7')]=_0x1a6694,_0x486c9c['getScrollEl']=_0x3a1a90;function _0x1a6694(_0x14519a){const _0x8a0ba8=_0x1b6424;_0x486c9c[_0x8a0ba8('0x7da')]=_0x14519a;}function _0x3a1a90(){const _0x540a07=_0x1b6424;return _0x486c9c[_0x540a07('0x7da')];}}function _0x51cfd9(){const _0x2d4449=_0x189033;return{'scope':{'msTimeline':'=?','loadMore':'&?msTimelineLoadMore'},'controller':_0x2d4449('0x665'),'compile':function(_0x5b7326){const _0x4c846d=_0x2d4449;return _0x5b7326['addClass'](_0x4c846d('0x1053')),function _0x446dd4(_0x3df547,_0x2156dd,_0x51fa7e,_0x200006){const _0xf046d6=_0x4c846d,_0x3271d2=angular[_0xf046d6('0x1fcc')](_0xf046d6('0x15e2'));_0x2156dd[_0xf046d6('0x22d6')](_0x3271d2);let _0x5ae189={'scrollEl':_0xf046d6('0x197d')};_0x5ae189=angular[_0xf046d6('0x618')](_0x5ae189,_0x3df547['msTimeline'],{});const _0x244142=angular[_0xf046d6('0x1fcc')](_0x5ae189[_0xf046d6('0x7da')]);_0x200006[_0xf046d6('0x22e7')](_0x244142);const _0xf71db=0x90;_0x521bbe();function _0x3fcbe7(){const _0xe42cec=_0xf046d6;_0x244142[_0xe42cec('0x5ee')]()+_0x244142[_0xe42cec('0xf')]()+_0xf71db>_0x3271d2[_0xe42cec('0x1233')]()[_0xe42cec('0x16d7')]&&(_0x3271d2['addClass'](_0xe42cec('0x1d4')),_0x51fb83(),_0x3df547[_0xe42cec('0x1b1c')]()[_0xe42cec('0x683')](function(){const _0x5efa85=_0xe42cec;_0x3271d2[_0x5efa85('0x12a4')](_0x5efa85('0x1d4')),_0x521bbe();},function(){const _0xfc8159=_0xe42cec;_0x3271d2[_0xfc8159('0x3ec')]();}));}function _0x521bbe(){const _0x3bc195=_0xf046d6;_0x244142['on'](_0x3bc195('0x5c9'),_0x3fcbe7);}function _0x51fb83(){const _0xa6c6c0=_0xf046d6;_0x244142[_0xa6c6c0('0x2422')](_0xa6c6c0('0x5c9'),_0x3fcbe7);}_0x3df547[_0xf046d6('0x26a2')]('$destroy',function(){_0x51fb83();});};}};}function _0x48e709(_0x560f4d,_0x5249b0){const _0x4b0074=_0x189033;return{'scope':!![],'require':_0x4b0074('0xa40'),'compile':function(_0x24e80e){const _0x377c7a=_0x4b0074;return _0x24e80e[_0x377c7a('0x81e')](_0x377c7a('0xfab'))[_0x377c7a('0x81e')](_0x377c7a('0x1fb4')),function _0x150bd9(_0x4ab62d,_0x42bc6d,_0x7d089e,_0x9afe2){const _0x37c0a8=_0x377c7a,_0x1e3ed3=0x48;let _0x5cd99b=![],_0x15dfaf=![];const _0x4a5b9e=_0x9afe2[_0x37c0a8('0x229f')]();_0x156257();function _0x156257(){const _0x4a5885=_0x37c0a8;_0x42bc6d[_0x4a5885('0x1c07')]('ms-card')?_0x4ab62d[_0x4a5885('0x26a2')](_0x4a5885('0x14f0'),function(_0x2b40d4,_0x5e2624){const _0x38ae57=_0x4a5885,_0x3a7497=angular['element'](_0x5e2624[0x0]);_0x245711(_0x3a7497)[_0x38ae57('0x683')](function(){_0x560f4d(function(){_0x5cd99b=!![];});});}):_0x245711(_0x42bc6d)[_0x4a5885('0x683')](function(){_0x560f4d(function(){_0x5cd99b=!![];});}),_0x4a5b9e['on'](_0x4a5885('0x5c9'),_0x12eaf0),_0x12eaf0();}const _0x2f41ed=_0x4ab62d[_0x37c0a8('0x186d')](function(){return _0x5cd99b&&_0x15dfaf;},function(_0x19ccd3,_0x5aebeb){const _0x428cc5=_0x37c0a8;if(angular[_0x428cc5('0xa18')](_0x19ccd3,_0x5aebeb))return;_0x19ccd3&&(_0x42bc6d[_0x428cc5('0x12a4')](_0x428cc5('0x1fb4'))[_0x428cc5('0x81e')](_0x428cc5('0x1219')),_0x2f41ed());},!![]);function _0x245711(_0x257ddb){const _0x4e80e5=_0x37c0a8,_0x4886b6=_0x5249b0['defer'](),_0x266994=_0x257ddb[_0x4e80e5('0x1c07')]('img');return _0x266994[_0x4e80e5('0x1564')]>0x0?_0x266994['on'](_0x4e80e5('0x182c'),function(){const _0xd0d5dc=_0x4e80e5;_0x4886b6[_0xd0d5dc('0xed7')](_0xd0d5dc('0xe7a'));}):_0x4886b6[_0x4e80e5('0xed7')](_0x4e80e5('0x1ac6')),_0x4886b6[_0x4e80e5('0x1883')];}function _0x12eaf0(){const _0x332944=_0x37c0a8;_0x4a5b9e['scrollTop']()+_0x4a5b9e[_0x332944('0xf')]()>_0x42bc6d['position']()['top']+_0x1e3ed3&&(_0x560f4d(function(){_0x15dfaf=!![];}),_0x4a5b9e[_0x332944('0x2422')](_0x332944('0x5c9'),_0x12eaf0));}};}};}_0x44dfcf[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x16ea'),_0x189033('0x2f9'),'$interval',_0x189033('0x2063'),_0x189033('0x1d08'),_0x189033('0x113d'),_0x189033('0x1222'),'$compile'];function _0x44dfcf(_0x508eaa,_0xb5d70,_0xe64683,_0x2258ba,_0x2564ff,_0x3390b3,_0x5ca484,_0x2ce58a,_0x22c901){const _0x315ed7=_0x189033;typeof String[_0x315ed7('0x891')][_0x315ed7('0x12ae')]!=='function'&&(String['prototype'][_0x315ed7('0x12ae')]=function(){return this['replace'](/^\s+|\s+$/g,'');});_0x508eaa[_0x315ed7('0x1bc3')]=_0x5ca484[_0x315ed7('0x1bc3')]||_0x5ca484['autostart'];_0x2ce58a['html']()[_0x315ed7('0x12ae')]()[_0x315ed7('0x1564')]===0x0?_0x2ce58a[_0x315ed7('0x22d6')](_0x22c901('{{millis}}')(_0x508eaa)):_0x2ce58a[_0x315ed7('0x22d6')](_0x22c901(_0x2ce58a[_0x315ed7('0x16ab')]())(_0x508eaa));_0x508eaa[_0x315ed7('0x115c')]=_0x508eaa[_0x315ed7('0xe28')]||0x3e8,_0x508eaa['startTime']=null,_0x508eaa[_0x315ed7('0x107e')]=null,_0x508eaa[_0x315ed7('0x1fb2')]=null,_0x508eaa[_0x315ed7('0x5ac')]=_0x508eaa[_0x315ed7('0x2165')]&&parseInt(_0x508eaa[_0x315ed7('0x2165')],0xa)>=0x0?parseInt(_0x508eaa['countdownAttr'],0xa):undefined,_0x508eaa[_0x315ed7('0x1342')]=![],_0x508eaa[_0x315ed7('0x186d')](_0x315ed7('0x466'),function(_0x101215,_0x4ce6ec){const _0x820dee=_0x315ed7;_0x101215!==_0x4ce6ec&&_0x508eaa['isRunning']&&_0x508eaa[_0x820dee('0x1ccd')]();}),_0x508eaa['$on'](_0x315ed7('0x1ddf'),function(){const _0x3e0cb8=_0x315ed7;_0x508eaa[_0x3e0cb8('0x1ccd')]();}),_0x508eaa[_0x315ed7('0x26a2')]('timer-resume',function(){const _0x3b7cd5=_0x315ed7;_0x508eaa[_0x3b7cd5('0x210c')]();}),_0x508eaa[_0x315ed7('0x26a2')](_0x315ed7('0xfb6'),function(){const _0x37d9bc=_0x315ed7;_0x508eaa[_0x37d9bc('0x19cc')]();}),_0x508eaa[_0x315ed7('0x26a2')](_0x315ed7('0x19e1'),function(){const _0x51f9c7=_0x315ed7;_0x508eaa[_0x51f9c7('0x1045')]();}),_0x508eaa['$on']('timer-set-countdown',function(_0x5b417f,_0x5695eb){const _0x1f0a3a=_0x315ed7;_0x508eaa[_0x1f0a3a('0x5ac')]=_0x5695eb;});function _0x2944e9(){const _0x45b661=_0x315ed7;_0x508eaa[_0x45b661('0x1fb2')]&&clearTimeout(_0x508eaa[_0x45b661('0x1fb2')]);}_0x508eaa['start']=function(){const _0x5981e9=_0x315ed7,_0x4d547d=_0x1aaf93()(),_0x33dc48=_0x508eaa['startTimeAttr']?_0x1aaf93()(_0x508eaa[_0x5981e9('0x466')]):null;!_0x33dc48||_0x33dc48>_0x4d547d?_0x508eaa['startTime']=_0x4d547d:_0x508eaa[_0x5981e9('0xd3b')]=_0x33dc48;const _0x20a822=_0x508eaa[_0x5981e9('0x274b')]?_0x1aaf93()(_0x508eaa[_0x5981e9('0x274b')]):null;!_0x20a822||_0x20a822<_0x4d547d?_0x508eaa[_0x5981e9('0x107e')]=null:_0x508eaa['endTime']=_0x20a822,!_0x508eaa[_0x5981e9('0x5ac')]&&(_0x508eaa[_0x5981e9('0x5ac')]=_0x508eaa[_0x5981e9('0x2165')]&&parseInt(_0x508eaa['countdownAttr'],0xa)>0x0?parseInt(_0x508eaa[_0x5981e9('0x6c1')],0xa):undefined),_0x2944e9(),_0x321801(),_0x508eaa[_0x5981e9('0x1342')]=!![];},_0x2ce58a[0x0][_0x315ed7('0x1ccd')]=_0x508eaa[_0x315ed7('0x1ccd')],_0x508eaa['resume']=function(){const _0x828fa3=_0x315ed7;_0x2944e9(),_0x508eaa[_0x828fa3('0x2165')]&&(_0x508eaa[_0x828fa3('0x5ac')]+=0x1),_0x508eaa[_0x828fa3('0xd3b')]=_0x1aaf93()()[_0x828fa3('0x2357')](_0x1aaf93()(_0x508eaa['stoppedTime'])[_0x828fa3('0x2357')](_0x1aaf93()(_0x508eaa[_0x828fa3('0xd3b')]))),_0x321801(),_0x508eaa['isRunning']=!![];},_0x2ce58a[0x0][_0x315ed7('0x210c')]=_0x508eaa[_0x315ed7('0x210c')],_0x508eaa['stop']=function(){const _0xf64041=_0x315ed7;_0x508eaa[_0xf64041('0x1045')](),_0x508eaa[_0xf64041('0x1b45')](_0xf64041('0x200c'),{'timeoutId':_0x508eaa[_0xf64041('0x1fb2')],'millis':_0x508eaa[_0xf64041('0x1d0e')],'seconds':_0x508eaa[_0xf64041('0x1b53')],'minutes':_0x508eaa['minutes'],'hours':_0x508eaa['hours'],'days':_0x508eaa[_0xf64041('0x1044')]});},_0x508eaa[_0x315ed7('0xa4')]=_0x508eaa[_0x315ed7('0x19cc')],_0x2ce58a[0x0][_0x315ed7('0x19cc')]=_0x508eaa[_0x315ed7('0x19cc')],_0x2ce58a[0x0][_0x315ed7('0xa4')]=_0x508eaa[_0x315ed7('0x19cc')],_0x508eaa[_0x315ed7('0x1045')]=function(){const _0x15ed62=_0x315ed7;_0x508eaa['stoppedTime']=_0x1aaf93()(),_0x2944e9(),_0x508eaa[_0x15ed62('0x1fb2')]=null,_0x508eaa[_0x15ed62('0x1342')]=![];},_0x2ce58a[0x0][_0x315ed7('0x1045')]=_0x508eaa[_0x315ed7('0x1045')],_0x2ce58a[_0x315ed7('0xb86')](_0x315ed7('0x4b8'),function(){const _0xae1133=_0x315ed7;_0x2944e9(),_0x508eaa[_0xae1133('0x1342')]=![];});function _0x32a306(){const _0x278e0e=_0x315ed7;_0x5ca484[_0x278e0e('0xd3b')]!==undefined&&(_0x508eaa[_0x278e0e('0x1d0e')]=_0x1aaf93()()[_0x278e0e('0x2357')](_0x1aaf93()(_0x508eaa[_0x278e0e('0xd3b')])));if(!_0x508eaa[_0x278e0e('0x202b')]||_0x508eaa[_0x278e0e('0x202b')]==='day')_0x508eaa[_0x278e0e('0x1b53')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0x3e8%0x3c),_0x508eaa['minutes']=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0xea60%0x3c),_0x508eaa[_0x278e0e('0x624')]=Math[_0x278e0e('0x16c9')](_0x508eaa['millis']/0x36ee80%0x18),_0x508eaa['days']=Math['floor'](_0x508eaa[_0x278e0e('0x1d0e')]/0x36ee80/0x18),_0x508eaa[_0x278e0e('0x1bf')]=0x0,_0x508eaa[_0x278e0e('0x1fc3')]=0x0;else{if(_0x508eaa[_0x278e0e('0x202b')]===_0x278e0e('0x1f7b'))_0x508eaa[_0x278e0e('0x1b53')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0x3e8),_0x508eaa['minutes']=0x0,_0x508eaa[_0x278e0e('0x624')]=0x0,_0x508eaa[_0x278e0e('0x1044')]=0x0,_0x508eaa[_0x278e0e('0x1bf')]=0x0,_0x508eaa[_0x278e0e('0x1fc3')]=0x0;else{if(_0x508eaa[_0x278e0e('0x202b')]===_0x278e0e('0x65c'))_0x508eaa[_0x278e0e('0x1b53')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0x3e8%0x3c),_0x508eaa['minutes']=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0xea60),_0x508eaa['hours']=0x0,_0x508eaa[_0x278e0e('0x1044')]=0x0,_0x508eaa[_0x278e0e('0x1bf')]=0x0,_0x508eaa[_0x278e0e('0x1fc3')]=0x0;else{if(_0x508eaa['maxTimeUnit']===_0x278e0e('0x10d1'))_0x508eaa[_0x278e0e('0x1b53')]=Math[_0x278e0e('0x16c9')](_0x508eaa['millis']/0x3e8%0x3c),_0x508eaa[_0x278e0e('0x25a6')]=Math['floor'](_0x508eaa[_0x278e0e('0x1d0e')]/0xea60%0x3c),_0x508eaa[_0x278e0e('0x624')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0x36ee80),_0x508eaa['days']=0x0,_0x508eaa['months']=0x0,_0x508eaa[_0x278e0e('0x1fc3')]=0x0;else{if(_0x508eaa[_0x278e0e('0x202b')]===_0x278e0e('0x55b'))_0x508eaa[_0x278e0e('0x1b53')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0x3e8%0x3c),_0x508eaa[_0x278e0e('0x25a6')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0xea60%0x3c),_0x508eaa[_0x278e0e('0x624')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0x36ee80%0x18),_0x508eaa[_0x278e0e('0x1044')]=Math[_0x278e0e('0x16c9')](_0x508eaa['millis']/0x36ee80/0x18%0x1e),_0x508eaa[_0x278e0e('0x1bf')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0x36ee80/0x18/0x1e),_0x508eaa[_0x278e0e('0x1fc3')]=0x0;else _0x508eaa[_0x278e0e('0x202b')]===_0x278e0e('0x3a4')&&(_0x508eaa['seconds']=Math['floor'](_0x508eaa['millis']/0x3e8%0x3c),_0x508eaa['minutes']=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0xea60%0x3c),_0x508eaa[_0x278e0e('0x624')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0x36ee80%0x18),_0x508eaa['days']=Math['floor'](_0x508eaa[_0x278e0e('0x1d0e')]/0x36ee80/0x18%0x1e),_0x508eaa[_0x278e0e('0x1bf')]=Math['floor'](_0x508eaa['millis']/0x36ee80/0x18/0x1e%0xc),_0x508eaa[_0x278e0e('0x1fc3')]=Math[_0x278e0e('0x16c9')](_0x508eaa[_0x278e0e('0x1d0e')]/0x36ee80/0x18/0x16d));}}}}_0x508eaa[_0x278e0e('0x1f24')]=_0x508eaa[_0x278e0e('0x1b53')]===0x1||_0x508eaa[_0x278e0e('0x1b53')]===0x0?'':'s',_0x508eaa[_0x278e0e('0x1c0c')]=_0x508eaa['minutes']===0x1||_0x508eaa[_0x278e0e('0x25a6')]===0x0?'':'s',_0x508eaa[_0x278e0e('0x2549')]=_0x508eaa[_0x278e0e('0x624')]===0x1||_0x508eaa[_0x278e0e('0x624')]===0x0?'':'s',_0x508eaa[_0x278e0e('0x13de')]=_0x508eaa[_0x278e0e('0x1044')]===0x1||_0x508eaa['days']===0x0?'':'s',_0x508eaa[_0x278e0e('0xe0f')]=_0x508eaa[_0x278e0e('0x1bf')]===0x1||_0x508eaa[_0x278e0e('0x1bf')]===0x0?'':'s',_0x508eaa[_0x278e0e('0x185e')]=_0x508eaa[_0x278e0e('0x1fc3')]===0x1||_0x508eaa['years']===0x0?'':'s',_0x508eaa[_0x278e0e('0x21e7')]=_0x508eaa[_0x278e0e('0x1b53')]<0xa?'0'+_0x508eaa[_0x278e0e('0x1b53')]:_0x508eaa[_0x278e0e('0x1b53')],_0x508eaa[_0x278e0e('0x10e8')]=_0x508eaa[_0x278e0e('0x25a6')]<0xa?'0'+_0x508eaa['minutes']:_0x508eaa[_0x278e0e('0x25a6')],_0x508eaa['hhours']=_0x508eaa[_0x278e0e('0x624')]<0xa?'0'+_0x508eaa[_0x278e0e('0x624')]:_0x508eaa[_0x278e0e('0x624')],_0x508eaa[_0x278e0e('0x4d9')]=_0x508eaa[_0x278e0e('0x1044')]<0xa?'0'+_0x508eaa[_0x278e0e('0x1044')]:_0x508eaa[_0x278e0e('0x1044')],_0x508eaa[_0x278e0e('0x22f5')]=_0x508eaa[_0x278e0e('0x1bf')]<0xa?'0'+_0x508eaa[_0x278e0e('0x1bf')]:_0x508eaa[_0x278e0e('0x1bf')],_0x508eaa['yyears']=_0x508eaa['years']<0xa?'0'+_0x508eaa[_0x278e0e('0x1fc3')]:_0x508eaa[_0x278e0e('0x1fc3')];}const _0x321801=function(){const _0x1a8f45=_0x315ed7;_0x508eaa[_0x1a8f45('0x1d0e')]=_0x1aaf93()()[_0x1a8f45('0x2357')](_0x508eaa[_0x1a8f45('0xd3b')]);let _0x2d48f3=_0x508eaa[_0x1a8f45('0x1d0e')]%0x3e8;_0x508eaa['endTimeAttr']&&(_0x508eaa[_0x1a8f45('0x1d0e')]=_0x1aaf93()(_0x508eaa[_0x1a8f45('0x107e')])['diff'](_0x1aaf93()()),_0x2d48f3=_0x508eaa['interval']-_0x508eaa[_0x1a8f45('0x1d0e')]%0x3e8);_0x508eaa['countdownAttr']&&(_0x508eaa[_0x1a8f45('0x1d0e')]=_0x508eaa['countdown']*0x3e8);if(_0x508eaa[_0x1a8f45('0x1d0e')]<0x0){_0x508eaa['stop'](),_0x508eaa[_0x1a8f45('0x1d0e')]=0x0,_0x32a306();_0x508eaa[_0x1a8f45('0x20b4')]&&_0x508eaa[_0x1a8f45('0x1a5a')](_0x508eaa[_0x1a8f45('0x20b4')]);return;}_0x32a306(),_0x508eaa['timeoutId']=setTimeout(function(){const _0x4dbbca=_0x1a8f45;_0x321801(),_0x508eaa[_0x4dbbca('0x31a')]();},_0x508eaa[_0x1a8f45('0x115c')]-_0x2d48f3),_0x508eaa['$emit'](_0x1a8f45('0x1381'),{'timeoutId':_0x508eaa[_0x1a8f45('0x1fb2')],'millis':_0x508eaa[_0x1a8f45('0x1d0e')]});if(_0x508eaa[_0x1a8f45('0x5ac')]>0x0)_0x508eaa[_0x1a8f45('0x5ac')]--;else _0x508eaa[_0x1a8f45('0x5ac')]<=0x0&&(_0x508eaa[_0x1a8f45('0x19cc')](),_0x508eaa[_0x1a8f45('0x20b4')]&&_0x508eaa['$eval'](_0x508eaa[_0x1a8f45('0x20b4')]));};(_0x508eaa[_0x315ed7('0x1bc3')]===undefined||_0x508eaa[_0x315ed7('0x1bc3')]===!![])&&_0x508eaa[_0x315ed7('0x1ccd')]();}function _0x56f896(){const _0x8d08df=_0x189033;return{'restrict':'EA','replace':![],'scope':{'intervalAttr':_0x8d08df('0x1f15'),'startTimeAttr':'=startTime','endTimeAttr':_0x8d08df('0xa4b'),'countdownAttr':'=countdown','autoStart':_0x8d08df('0xe14'),'maxTimeUnit':'='},'controller':_0x8d08df('0x25cd')};}const _0x79dcaa=_0x180212['p']+'src/js/modules/core/directives/ms-timezone/ms-timezone.html/ms-timezone.html';;function _0x4bd4ea(){const _0x359990=_0x189033;return{'restrict':'E','scope':{'ngModel':'='},'controller':[_0x359990('0x7a5'),function(_0x21ab1e){const _0x3840e4=_0x359990;_0x21ab1e[_0x3840e4('0x2356')]=[{'name':_0x3840e4('0x22f8'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['AD']},{'name':_0x3840e4('0x99b'),'utcOffset':0xf0,'offsetStr':_0x3840e4('0x447'),'countries':['AE','OM']},{'name':_0x3840e4('0x3b0'),'utcOffset':0x10e,'offsetStr':'+04:30','countries':['AF']},{'name':_0x3840e4('0x839'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['AL']},{'name':_0x3840e4('0x26bc'),'utcOffset':0xf0,'offsetStr':_0x3840e4('0x447'),'countries':['AM']},{'name':'Antarctica/Rothera','utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AQ']},{'name':_0x3840e4('0x19d1'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AQ']},{'name':'Antarctica/Mawson','utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['AQ']},{'name':_0x3840e4('0x1cbf'),'utcOffset':0x1a4,'offsetStr':_0x3840e4('0x15ac'),'countries':['AQ']},{'name':_0x3840e4('0x1c2c'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['AQ']},{'name':_0x3840e4('0x16ba'),'utcOffset':0x168,'offsetStr':_0x3840e4('0x279b'),'countries':['AQ']},{'name':_0x3840e4('0x14b2'),'utcOffset':0x258,'offsetStr':_0x3840e4('0xa4e'),'countries':['AQ']},{'name':_0x3840e4('0x2ca'),'utcOffset':0xb4,'offsetStr':_0x3840e4('0x1dea'),'countries':['AQ']},{'name':_0x3840e4('0x1fc'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['AQ']},{'name':'America/Argentina/Buenos_Aires','utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':_0x3840e4('0x9c1'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':_0x3840e4('0x10ad'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':'America/Argentina/Jujuy','utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':'America/Argentina/Tucuman','utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':_0x3840e4('0x52'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['AR']},{'name':_0x3840e4('0x351'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['AR']},{'name':_0x3840e4('0x2242'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':_0x3840e4('0x63b'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':_0x3840e4('0x1f3c'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':_0x3840e4('0x1acf'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':_0x3840e4('0xe08'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['AR']},{'name':_0x3840e4('0x1a05'),'utcOffset':-0x294,'offsetStr':_0x3840e4('0xd3f'),'countries':['AS','UM']},{'name':_0x3840e4('0xc9d'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['AT']},{'name':_0x3840e4('0x22b1'),'utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['AU']},{'name':_0x3840e4('0x22c7'),'utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['AU']},{'name':_0x3840e4('0x1b8b'),'utcOffset':0x294,'offsetStr':'+11:00','countries':['AU']},{'name':_0x3840e4('0x19ce'),'utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['AU']},{'name':'Australia/Melbourne','utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['AU']},{'name':_0x3840e4('0x2450'),'utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['AU']},{'name':_0x3840e4('0x2809'),'utcOffset':0x276,'offsetStr':_0x3840e4('0x2525'),'countries':['AU']},{'name':_0x3840e4('0x2857'),'utcOffset':0x258,'offsetStr':_0x3840e4('0xa4e'),'countries':['AU']},{'name':_0x3840e4('0x195c'),'utcOffset':0x258,'offsetStr':'+10:00','countries':['AU']},{'name':_0x3840e4('0x1354'),'utcOffset':0x276,'offsetStr':'+10:30','countries':['AU']},{'name':_0x3840e4('0x874'),'utcOffset':0x23a,'offsetStr':_0x3840e4('0x25d9'),'countries':['AU']},{'name':_0x3840e4('0x2707'),'utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['AU']},{'name':_0x3840e4('0x1498'),'utcOffset':0x20d,'offsetStr':'+08:45','countries':['AU']},{'name':'Asia/Baku','utcOffset':0xf0,'offsetStr':'+04:00','countries':['AZ']},{'name':_0x3840e4('0x1f30'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['BB']},{'name':'Asia/Dhaka','utcOffset':0x168,'offsetStr':_0x3840e4('0x279b'),'countries':['BD']},{'name':'Europe/Brussels','utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['BE']},{'name':_0x3840e4('0x1bc'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['BG']},{'name':_0x3840e4('0x2111'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['BM']},{'name':_0x3840e4('0xaff'),'utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['BN']},{'name':_0x3840e4('0x8c3'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['BO']},{'name':'America/Noronha','utcOffset':-0x78,'offsetStr':_0x3840e4('0xc9f'),'countries':['BR']},{'name':_0x3840e4('0x8cf'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['BR']},{'name':'America/Fortaleza','utcOffset':-0xb4,'offsetStr':'-03:00','countries':['BR']},{'name':'America/Recife','utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['BR']},{'name':_0x3840e4('0x20af'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['BR']},{'name':_0x3840e4('0x18b9'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['BR']},{'name':_0x3840e4('0x1215'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['BR']},{'name':'America/Sao_Paulo','utcOffset':-0x78,'offsetStr':_0x3840e4('0xc9f'),'countries':['BR']},{'name':_0x3840e4('0x29f'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['BR']},{'name':'America/Cuiaba','utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['BR']},{'name':_0x3840e4('0x1282'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['BR']},{'name':_0x3840e4('0x2828'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['BR']},{'name':_0x3840e4('0x16d3'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['BR']},{'name':_0x3840e4('0x268'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['BR']},{'name':_0x3840e4('0xb32'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['BR']},{'name':'America/Rio_Branco','utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['BR']},{'name':_0x3840e4('0x71'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['BS']},{'name':_0x3840e4('0x1af6'),'utcOffset':0x168,'offsetStr':'+06:00','countries':['BT']},{'name':'Europe/Minsk','utcOffset':0xb4,'offsetStr':_0x3840e4('0x1dea'),'countries':['BY']},{'name':_0x3840e4('0x415'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['BZ']},{'name':_0x3840e4('0x2300'),'utcOffset':-0xd2,'offsetStr':_0x3840e4('0x13f'),'countries':['CA']},{'name':'America/Halifax','utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['CA']},{'name':_0x3840e4('0x179'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['CA']},{'name':_0x3840e4('0x2887'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['CA']},{'name':'America/Goose_Bay','utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['CA']},{'name':_0x3840e4('0x23e4'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['CA']},{'name':_0x3840e4('0x24b4'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['CA']},{'name':_0x3840e4('0x145c'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['CA']},{'name':'America/Thunder_Bay','utcOffset':-0x12c,'offsetStr':'-05:00','countries':['CA']},{'name':_0x3840e4('0x19bb'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['CA']},{'name':'America/Pangnirtung','utcOffset':-0x12c,'offsetStr':'-05:00','countries':['CA']},{'name':'America/Resolute','utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['CA']},{'name':_0x3840e4('0x1644'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['CA']},{'name':_0x3840e4('0x9ad'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['CA']},{'name':_0x3840e4('0x1b26'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['CA']},{'name':_0x3840e4('0x282e'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['CA']},{'name':_0x3840e4('0x1fc7'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['CA']},{'name':_0x3840e4('0x12c5'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['CA']},{'name':_0x3840e4('0x61'),'utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['CA']},{'name':_0x3840e4('0xfea'),'utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['CA']},{'name':_0x3840e4('0x39e'),'utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['CA']},{'name':_0x3840e4('0x1568'),'utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['CA']},{'name':'America/Creston','utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['CA']},{'name':_0x3840e4('0x675'),'utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['CA']},{'name':_0x3840e4('0x1a92'),'utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['CA']},{'name':'America/Vancouver','utcOffset':-0x1e0,'offsetStr':_0x3840e4('0x246e'),'countries':['CA']},{'name':_0x3840e4('0x1af0'),'utcOffset':-0x1e0,'offsetStr':_0x3840e4('0x246e'),'countries':['CA']},{'name':_0x3840e4('0x2087'),'utcOffset':-0x1e0,'offsetStr':_0x3840e4('0x246e'),'countries':['CA']},{'name':_0x3840e4('0x2aa'),'utcOffset':0x186,'offsetStr':'+06:30','countries':['CC']},{'name':'Europe/Zurich','utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['CH','DE','LI']},{'name':_0x3840e4('0xbce'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['CI','BF','GM','GN','ML','MR','SH','SL','SN','ST','TG']},{'name':_0x3840e4('0xf04'),'utcOffset':-0x258,'offsetStr':_0x3840e4('0x80a'),'countries':['CK']},{'name':_0x3840e4('0xfb1'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['CL']},{'name':'Pacific/Easter','utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['CL']},{'name':_0x3840e4('0x350'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['CN']},{'name':'Asia/Urumqi','utcOffset':0x168,'offsetStr':_0x3840e4('0x279b'),'countries':['CN']},{'name':_0x3840e4('0xc8e'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['CO']},{'name':_0x3840e4('0x71c'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['CR']},{'name':_0x3840e4('0x49d'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['CU']},{'name':_0x3840e4('0x24e0'),'utcOffset':-0x3c,'offsetStr':_0x3840e4('0xec8'),'countries':['CV']},{'name':_0x3840e4('0x1cec'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['CW','AW','BQ','SX']},{'name':_0x3840e4('0x1e0'),'utcOffset':0x1a4,'offsetStr':'+07:00','countries':['CX']},{'name':_0x3840e4('0x1898'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['CY']},{'name':_0x3840e4('0x142'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['CZ','SK']},{'name':'Europe/Berlin','utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['DE']},{'name':_0x3840e4('0x643'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['DK']},{'name':'America/Santo_Domingo','utcOffset':-0xf0,'offsetStr':'-04:00','countries':['DO']},{'name':_0x3840e4('0x1fbf'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['DZ']},{'name':'America/Guayaquil','utcOffset':-0x12c,'offsetStr':'-05:00','countries':['EC']},{'name':_0x3840e4('0x1198'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['EC']},{'name':_0x3840e4('0x23c3'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['EE']},{'name':_0x3840e4('0x249a'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['EG']},{'name':'Africa/El_Aaiun','utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['EH']},{'name':_0x3840e4('0x5ad'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['ES']},{'name':_0x3840e4('0x905'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['ES']},{'name':_0x3840e4('0x183f'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['ES']},{'name':_0x3840e4('0x2272'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['FI','AX']},{'name':_0x3840e4('0x13ea'),'utcOffset':0x2d0,'offsetStr':'+12:00','countries':['FJ']},{'name':_0x3840e4('0x1e89'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['FK']},{'name':_0x3840e4('0x2045'),'utcOffset':0x258,'offsetStr':_0x3840e4('0xa4e'),'countries':['FM']},{'name':'Pacific/Pohnpei','utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['FM']},{'name':_0x3840e4('0x1f1f'),'utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['FM']},{'name':'Atlantic/Faroe','utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['FO']},{'name':_0x3840e4('0x1f2e'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['FR']},{'name':_0x3840e4('0x1afe'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['GB','GG','IM','JE']},{'name':_0x3840e4('0x51e'),'utcOffset':0xf0,'offsetStr':_0x3840e4('0x447'),'countries':['GE']},{'name':_0x3840e4('0x2474'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['GF']},{'name':_0x3840e4('0x15c0'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['GH']},{'name':_0x3840e4('0x10de'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['GI']},{'name':_0x3840e4('0x18a2'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['GL']},{'name':_0x3840e4('0x2033'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['GL']},{'name':_0x3840e4('0x19e8'),'utcOffset':-0x3c,'offsetStr':_0x3840e4('0xec8'),'countries':['GL']},{'name':_0x3840e4('0xa80'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['GL']},{'name':_0x3840e4('0x27b4'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['GR']},{'name':_0x3840e4('0x904'),'utcOffset':-0x78,'offsetStr':_0x3840e4('0xc9f'),'countries':['GS']},{'name':'America/Guatemala','utcOffset':-0x168,'offsetStr':'-06:00','countries':['GT']},{'name':_0x3840e4('0x2a1'),'utcOffset':0x258,'offsetStr':'+10:00','countries':['GU','MP']},{'name':'Africa/Bissau','utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['GW']},{'name':_0x3840e4('0x1cf'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['GY']},{'name':_0x3840e4('0x1e72'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['HK']},{'name':_0x3840e4('0x1771'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['HN']},{'name':_0x3840e4('0x1a25'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['HT']},{'name':_0x3840e4('0x1df4'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['HU']},{'name':_0x3840e4('0x50f'),'utcOffset':0x1a4,'offsetStr':_0x3840e4('0x15ac'),'countries':['ID']},{'name':_0x3840e4('0x1f7e'),'utcOffset':0x1a4,'offsetStr':_0x3840e4('0x15ac'),'countries':['ID']},{'name':_0x3840e4('0xc0a'),'utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['ID']},{'name':_0x3840e4('0x175c'),'utcOffset':0x21c,'offsetStr':_0x3840e4('0x1377'),'countries':['ID']},{'name':_0x3840e4('0x1dab'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['IE']},{'name':_0x3840e4('0x1eb5'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['IL']},{'name':_0x3840e4('0x154'),'utcOffset':0x14a,'offsetStr':_0x3840e4('0xe2e'),'countries':['IN']},{'name':_0x3840e4('0x26e8'),'utcOffset':0x168,'offsetStr':_0x3840e4('0x279b'),'countries':['IO']},{'name':_0x3840e4('0x1607'),'utcOffset':0xb4,'offsetStr':_0x3840e4('0x1dea'),'countries':['IQ']},{'name':_0x3840e4('0x1b3c'),'utcOffset':0xd2,'offsetStr':_0x3840e4('0x9f2'),'countries':['IR']},{'name':_0x3840e4('0x26b5'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['IS']},{'name':_0x3840e4('0x345'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['IT','SM','VA']},{'name':_0x3840e4('0x1acd'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['JM']},{'name':_0x3840e4('0xd0c'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['JO']},{'name':_0x3840e4('0x2341'),'utcOffset':0x21c,'offsetStr':'+09:00','countries':['JP']},{'name':_0x3840e4('0x278c'),'utcOffset':0xb4,'offsetStr':'+03:00','countries':['KE','DJ','ER','ET','KM','MG','SO','TZ','UG','YT']},{'name':_0x3840e4('0x1d69'),'utcOffset':0x168,'offsetStr':'+06:00','countries':['KG']},{'name':_0x3840e4('0x6c2'),'utcOffset':0x2d0,'offsetStr':_0x3840e4('0x1d8b'),'countries':['KI']},{'name':_0x3840e4('0xc5c'),'utcOffset':0x30c,'offsetStr':'+13:00','countries':['KI']},{'name':'Pacific/Kiritimati','utcOffset':0x348,'offsetStr':_0x3840e4('0x1837'),'countries':['KI']},{'name':_0x3840e4('0x40a'),'utcOffset':0x1fe,'offsetStr':_0x3840e4('0xacb'),'countries':['KP']},{'name':_0x3840e4('0xc39'),'utcOffset':0x21c,'offsetStr':_0x3840e4('0x1377'),'countries':['KR']},{'name':_0x3840e4('0x952'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['KY']},{'name':_0x3840e4('0xe5e'),'utcOffset':0x168,'offsetStr':'+06:00','countries':['KZ']},{'name':'Asia/Qyzylorda','utcOffset':0x168,'offsetStr':'+06:00','countries':['KZ']},{'name':_0x3840e4('0x1be'),'utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['KZ']},{'name':_0x3840e4('0x1d48'),'utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['KZ']},{'name':_0x3840e4('0x1f7a'),'utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['KZ']},{'name':_0x3840e4('0x8f1'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['LB']},{'name':'Asia/Colombo','utcOffset':0x14a,'offsetStr':_0x3840e4('0xe2e'),'countries':['LK']},{'name':_0x3840e4('0xcb9'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['LR']},{'name':_0x3840e4('0x18a1'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['LT']},{'name':_0x3840e4('0x1e38'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['LU']},{'name':_0x3840e4('0x1100'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['LV']},{'name':_0x3840e4('0x303'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['LY']},{'name':_0x3840e4('0x31e'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['MA']},{'name':_0x3840e4('0x2364'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['MC']},{'name':_0x3840e4('0xee5'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['MD']},{'name':_0x3840e4('0x240a'),'utcOffset':0x2d0,'offsetStr':_0x3840e4('0x1d8b'),'countries':['MH']},{'name':_0x3840e4('0x1f86'),'utcOffset':0x2d0,'offsetStr':'+12:00','countries':['MH']},{'name':'Asia/Rangoon','utcOffset':0x186,'offsetStr':_0x3840e4('0x2344'),'countries':['MM']},{'name':'Asia/Ulaanbaatar','utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['MN']},{'name':_0x3840e4('0x14f'),'utcOffset':0x1a4,'offsetStr':'+07:00','countries':['MN']},{'name':_0x3840e4('0xa44'),'utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['MN']},{'name':_0x3840e4('0x29'),'utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['MO']},{'name':_0x3840e4('0x136f'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['MQ']},{'name':_0x3840e4('0x65a'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['MT']},{'name':_0x3840e4('0x49e'),'utcOffset':0xf0,'offsetStr':_0x3840e4('0x447'),'countries':['MU']},{'name':_0x3840e4('0xe92'),'utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['MV']},{'name':_0x3840e4('0x1a1f'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['MX']},{'name':_0x3840e4('0x146d'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['MX']},{'name':_0x3840e4('0x92'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['MX']},{'name':'America/Monterrey','utcOffset':-0x168,'offsetStr':'-06:00','countries':['MX']},{'name':_0x3840e4('0x1c33'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['MX']},{'name':'America/Mazatlan','utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['MX']},{'name':_0x3840e4('0x3a9'),'utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['MX']},{'name':_0x3840e4('0x901'),'utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['MX']},{'name':_0x3840e4('0x10dd'),'utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['MX']},{'name':_0x3840e4('0x25b2'),'utcOffset':-0x1e0,'offsetStr':_0x3840e4('0x246e'),'countries':['MX']},{'name':_0x3840e4('0x16ae'),'utcOffset':-0x1e0,'offsetStr':_0x3840e4('0x246e'),'countries':['MX']},{'name':_0x3840e4('0x7f0'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['MX']},{'name':'Asia/Kuala_Lumpur','utcOffset':0x1e0,'offsetStr':'+08:00','countries':['MY']},{'name':_0x3840e4('0x851'),'utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['MY']},{'name':_0x3840e4('0x171d'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['MZ','BI','BW','CD','MW','RW','ZM','ZW']},{'name':_0x3840e4('0x1b2f'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['NA']},{'name':_0x3840e4('0x12d5'),'utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['NC']},{'name':_0x3840e4('0x105f'),'utcOffset':0x294,'offsetStr':'+11:00','countries':['NF']},{'name':'Africa/Lagos','utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['NG','AO','BJ','CD','CF','CG','CM','GA','GQ','NE']},{'name':_0x3840e4('0x696'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['NI']},{'name':_0x3840e4('0xc2e'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['NL']},{'name':_0x3840e4('0x138b'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['NO','SJ']},{'name':'Asia/Kathmandu','utcOffset':0x159,'offsetStr':'+05:45','countries':['NP']},{'name':'Pacific/Nauru','utcOffset':0x2d0,'offsetStr':_0x3840e4('0x1d8b'),'countries':['NR']},{'name':_0x3840e4('0x14d6'),'utcOffset':-0x294,'offsetStr':'-11:00','countries':['NU']},{'name':_0x3840e4('0x116f'),'utcOffset':0x30c,'offsetStr':'+13:00','countries':['NZ','AQ']},{'name':_0x3840e4('0x1f56'),'utcOffset':0x339,'offsetStr':_0x3840e4('0x1239'),'countries':['NZ']},{'name':'America/Panama','utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['PA']},{'name':_0x3840e4('0x1020'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['PE']},{'name':_0x3840e4('0x2491'),'utcOffset':-0x258,'offsetStr':_0x3840e4('0x80a'),'countries':['PF']},{'name':'Pacific/Marquesas','utcOffset':-0x23a,'offsetStr':_0x3840e4('0xb48'),'countries':['PF']},{'name':_0x3840e4('0x15c2'),'utcOffset':-0x21c,'offsetStr':_0x3840e4('0x12ff'),'countries':['PF']},{'name':_0x3840e4('0x94'),'utcOffset':0x258,'offsetStr':_0x3840e4('0xa4e'),'countries':['PG']},{'name':_0x3840e4('0x123a'),'utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['PG']},{'name':'Asia/Manila','utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['PH']},{'name':_0x3840e4('0x12bb'),'utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['PK']},{'name':_0x3840e4('0x252b'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['PL']},{'name':_0x3840e4('0x6d6'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['PM']},{'name':_0x3840e4('0x1da9'),'utcOffset':-0x1e0,'offsetStr':_0x3840e4('0x246e'),'countries':['PN']},{'name':_0x3840e4('0x92d'),'utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['PR']},{'name':_0x3840e4('0x207d'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['PS']},{'name':'Asia/Hebron','utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['PS']},{'name':_0x3840e4('0x1932'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['PT']},{'name':_0x3840e4('0x18d4'),'utcOffset':0x0,'offsetStr':_0x3840e4('0x23f1'),'countries':['PT']},{'name':_0x3840e4('0x24a'),'utcOffset':-0x3c,'offsetStr':'-01:00','countries':['PT']},{'name':_0x3840e4('0x763'),'utcOffset':0x21c,'offsetStr':'+09:00','countries':['PW']},{'name':'America/Asuncion','utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['PY']},{'name':'Asia/Qatar','utcOffset':0xb4,'offsetStr':_0x3840e4('0x1dea'),'countries':['QA','BH']},{'name':'Indian/Reunion','utcOffset':0xf0,'offsetStr':_0x3840e4('0x447'),'countries':['RE','TF']},{'name':_0x3840e4('0x67c'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['RO']},{'name':_0x3840e4('0x13d5'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['RS','BA','HR','ME','MK','SI']},{'name':_0x3840e4('0x2439'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['RU']},{'name':_0x3840e4('0x100b'),'utcOffset':0xb4,'offsetStr':'+03:00','countries':['RU']},{'name':_0x3840e4('0xa7e'),'utcOffset':0xb4,'offsetStr':_0x3840e4('0x1dea'),'countries':['RU']},{'name':_0x3840e4('0xc00'),'utcOffset':0xb4,'offsetStr':_0x3840e4('0x1dea'),'countries':['RU']},{'name':_0x3840e4('0xf88'),'utcOffset':0xf0,'offsetStr':_0x3840e4('0x447'),'countries':['RU']},{'name':_0x3840e4('0x1fad'),'utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['RU']},{'name':_0x3840e4('0x2405'),'utcOffset':0x168,'offsetStr':_0x3840e4('0x279b'),'countries':['RU']},{'name':_0x3840e4('0xad'),'utcOffset':0x168,'offsetStr':_0x3840e4('0x279b'),'countries':['RU']},{'name':_0x3840e4('0x1fe3'),'utcOffset':0x1a4,'offsetStr':'+07:00','countries':['RU']},{'name':_0x3840e4('0x1e1e'),'utcOffset':0x1a4,'offsetStr':_0x3840e4('0x15ac'),'countries':['RU']},{'name':_0x3840e4('0x580'),'utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['RU']},{'name':_0x3840e4('0x45f'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['RU']},{'name':'Asia/Yakutsk','utcOffset':0x21c,'offsetStr':_0x3840e4('0x1377'),'countries':['RU']},{'name':_0x3840e4('0x1ed7'),'utcOffset':0x21c,'offsetStr':_0x3840e4('0x1377'),'countries':['RU']},{'name':_0x3840e4('0x1891'),'utcOffset':0x258,'offsetStr':_0x3840e4('0xa4e'),'countries':['RU']},{'name':'Asia/Sakhalin','utcOffset':0x258,'offsetStr':'+10:00','countries':['RU']},{'name':_0x3840e4('0x15ea'),'utcOffset':0x258,'offsetStr':_0x3840e4('0xa4e'),'countries':['RU']},{'name':_0x3840e4('0xca4'),'utcOffset':0x258,'offsetStr':_0x3840e4('0xa4e'),'countries':['RU']},{'name':'Asia/Srednekolymsk','utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['RU']},{'name':'Asia/Kamchatka','utcOffset':0x2d0,'offsetStr':_0x3840e4('0x1d8b'),'countries':['RU']},{'name':_0x3840e4('0xedf'),'utcOffset':0x2d0,'offsetStr':'+12:00','countries':['RU']},{'name':'Asia/Riyadh','utcOffset':0xb4,'offsetStr':_0x3840e4('0x1dea'),'countries':['SA','KW','YE']},{'name':_0x3840e4('0x367'),'utcOffset':0x294,'offsetStr':_0x3840e4('0xeab'),'countries':['SB']},{'name':_0x3840e4('0x11f5'),'utcOffset':0xf0,'offsetStr':_0x3840e4('0x447'),'countries':['SC']},{'name':_0x3840e4('0x1dba'),'utcOffset':0xb4,'offsetStr':_0x3840e4('0x1dea'),'countries':['SD','SS']},{'name':_0x3840e4('0x15fc'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['SE']},{'name':_0x3840e4('0xa20'),'utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['SG']},{'name':_0x3840e4('0x10d0'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['SR']},{'name':'America/El_Salvador','utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['SV']},{'name':_0x3840e4('0x20a2'),'utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['SY']},{'name':_0x3840e4('0xcc'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['TC']},{'name':_0x3840e4('0x4e6'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['TD']},{'name':'Indian/Kerguelen','utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['TF']},{'name':'Asia/Bangkok','utcOffset':0x1a4,'offsetStr':_0x3840e4('0x15ac'),'countries':['TH','KH','LA','VN']},{'name':_0x3840e4('0x1857'),'utcOffset':0x12c,'offsetStr':'+05:00','countries':['TJ']},{'name':'Pacific/Fakaofo','utcOffset':0x30c,'offsetStr':_0x3840e4('0x376'),'countries':['TK']},{'name':_0x3840e4('0x1779'),'utcOffset':0x21c,'offsetStr':_0x3840e4('0x1377'),'countries':['TL']},{'name':_0x3840e4('0x201d'),'utcOffset':0x12c,'offsetStr':'+05:00','countries':['TM']},{'name':_0x3840e4('0x138f'),'utcOffset':0x3c,'offsetStr':_0x3840e4('0x19ed'),'countries':['TN']},{'name':_0x3840e4('0xd6c'),'utcOffset':0x30c,'offsetStr':'+13:00','countries':['TO']},{'name':'Europe/Istanbul','utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['TR']},{'name':'America/Port_of_Spain','utcOffset':-0xf0,'offsetStr':_0x3840e4('0xb84'),'countries':['TT','AG','AI','BL','DM','GD','GP','KN','LC','MF','MS','VC','VG','VI']},{'name':_0x3840e4('0x611'),'utcOffset':0x2d0,'offsetStr':'+12:00','countries':['TV']},{'name':'Asia/Taipei','utcOffset':0x1e0,'offsetStr':_0x3840e4('0x1b16'),'countries':['TW']},{'name':_0x3840e4('0x1696'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['UA']},{'name':_0x3840e4('0x20df'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['UA']},{'name':'Europe/Zaporozhye','utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['UA']},{'name':'Pacific/Wake','utcOffset':0x2d0,'offsetStr':_0x3840e4('0x1d8b'),'countries':['UM']},{'name':'America/New_York','utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['US']},{'name':_0x3840e4('0x2817'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},{'name':'America/Kentucky/Louisville','utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['US']},{'name':_0x3840e4('0x41b'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['US']},{'name':_0x3840e4('0x706'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['US']},{'name':_0x3840e4('0x2592'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['US']},{'name':_0x3840e4('0x95b'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['US']},{'name':_0x3840e4('0x3a'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['US']},{'name':_0x3840e4('0x168c'),'utcOffset':-0x12c,'offsetStr':_0x3840e4('0x23f0'),'countries':['US']},{'name':_0x3840e4('0xb62'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},{'name':'America/Chicago','utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['US']},{'name':'America/Indiana/Tell_City','utcOffset':-0x168,'offsetStr':'-06:00','countries':['US']},{'name':_0x3840e4('0x284a'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['US']},{'name':'America/Menominee','utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['US']},{'name':_0x3840e4('0x1739'),'utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['US']},{'name':'America/North_Dakota/New_Salem','utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['US']},{'name':'America/North_Dakota/Beulah','utcOffset':-0x168,'offsetStr':_0x3840e4('0x1f96'),'countries':['US']},{'name':'America/Denver','utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['US']},{'name':_0x3840e4('0x20be'),'utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['US']},{'name':_0x3840e4('0xd9'),'utcOffset':-0x1a4,'offsetStr':_0x3840e4('0x1dde'),'countries':['US']},{'name':_0x3840e4('0x1f04'),'utcOffset':-0x1e0,'offsetStr':'-08:00','countries':['US']},{'name':'America/Metlakatla','utcOffset':-0x1e0,'offsetStr':_0x3840e4('0x246e'),'countries':['US']},{'name':'America/Anchorage','utcOffset':-0x21c,'offsetStr':_0x3840e4('0x12ff'),'countries':['US']},{'name':_0x3840e4('0x25a0'),'utcOffset':-0x21c,'offsetStr':_0x3840e4('0x12ff'),'countries':['US']},{'name':_0x3840e4('0x22eb'),'utcOffset':-0x21c,'offsetStr':_0x3840e4('0x12ff'),'countries':['US']},{'name':_0x3840e4('0xece'),'utcOffset':-0x21c,'offsetStr':_0x3840e4('0x12ff'),'countries':['US']},{'name':_0x3840e4('0x106b'),'utcOffset':-0x21c,'offsetStr':'-09:00','countries':['US']},{'name':'America/Adak','utcOffset':-0x258,'offsetStr':_0x3840e4('0x80a'),'countries':['US']},{'name':'Pacific/Honolulu','utcOffset':-0x258,'offsetStr':_0x3840e4('0x80a'),'countries':['US','UM']},{'name':_0x3840e4('0x166d'),'utcOffset':-0xb4,'offsetStr':_0x3840e4('0xd63'),'countries':['UY']},{'name':_0x3840e4('0xf9c'),'utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['UZ']},{'name':_0x3840e4('0x473'),'utcOffset':0x12c,'offsetStr':_0x3840e4('0x209a'),'countries':['UZ']},{'name':_0x3840e4('0x17dc'),'utcOffset':-0x10e,'offsetStr':_0x3840e4('0x1c4b'),'countries':['VE']},{'name':_0x3840e4('0x253d'),'utcOffset':0x1a4,'offsetStr':_0x3840e4('0x15ac'),'countries':['VN']},{'name':_0x3840e4('0x25e'),'utcOffset':0x294,'offsetStr':'+11:00','countries':['VU']},{'name':_0x3840e4('0x1536'),'utcOffset':0x2d0,'offsetStr':_0x3840e4('0x1d8b'),'countries':['WF']},{'name':'Pacific/Apia','utcOffset':0x348,'offsetStr':_0x3840e4('0x1837'),'countries':['WS']},{'name':'Africa/Johannesburg','utcOffset':0x78,'offsetStr':_0x3840e4('0x827'),'countries':['ZA','LS','SZ']}];}],'templateUrl':_0x79dcaa};}const _0x178363=_0x4bd4ea;;function _0x1880e3(){const _0x3a33b7=_0x189033,_0x438e0b=this;_0x438e0b[_0x3a33b7('0x25')]=[],_0x438e0b['filtered']=![],_0x438e0b[_0x3a33b7('0x2269')]=0x14;function _0x344fe3(_0x3702a3){const _0x5b0b5e=_0x3a33b7;let _0x346722=0x0;if(_0x3702a3){_0x438e0b[_0x5b0b5e('0x2269')]=_0x3702a3[_0x5b0b5e('0x1221')][0x2]&&_0x3702a3[_0x5b0b5e('0x1221')][0x2]['value']?parseInt(_0x3702a3['attrs'][0x2]['value'])-parseInt(_0x3702a3[_0x5b0b5e('0x1221')][0x2][_0x5b0b5e('0x1c6b')])%0x2:0x14;_0x3702a3[_0x5b0b5e('0x1221')][0x1]['value']&&_0x3702a3['attrs'][0x1][_0x5b0b5e('0x1c6b')]['length']?(_0x438e0b[_0x5b0b5e('0x17a4')]=!![],_0x438e0b[_0x5b0b5e('0x25')]=_0x2e3ca0()[_0x5b0b5e('0xcef')](_0x3702a3[_0x5b0b5e('0x1890')],_0x3702a3['attrs'][0x1][_0x5b0b5e('0x1c6b')])):(_0x438e0b['filtered']=![],_0x438e0b['filter']=_0x3702a3[_0x5b0b5e('0x1890')]);for(let _0x10665c=0x0;_0x10665c<_0x3702a3[_0x5b0b5e('0x426')][_0x5b0b5e('0xf5d')][_0x5b0b5e('0x1564')];_0x10665c+=0x1){_0x2e3ca0()[_0x5b0b5e('0x2292')](_0x438e0b['filter'],_0x3702a3['voiceQueues'][_0x5b0b5e('0xf5d')][_0x10665c]['id'])&&(_0x346722+=_0x3702a3[_0x5b0b5e('0x426')]['rows'][_0x10665c][_0x3702a3['attrs'][0x0]['value']]?parseInt(_0x3702a3[_0x5b0b5e('0x426')][_0x5b0b5e('0xf5d')][_0x10665c][_0x3702a3[_0x5b0b5e('0x1221')][0x0][_0x5b0b5e('0x1c6b')]]):0x0);}}return _0x346722;}_0x438e0b[_0x3a33b7('0x214f')]=_0x344fe3;}const _0x2c3031=_0x1880e3;_0x246431[_0x189033('0x14be')]=['$translate'];function _0x246431(_0x34a804){const _0x1956a0=_0x189033,_0x5860f8=this;_0x5860f8['filter']=[],_0x5860f8[_0x1956a0('0x17a4')]=![],_0x5860f8[_0x1956a0('0x1594')]=[],_0x5860f8[_0x1956a0('0x10a9')]={'labels':[_0x1956a0('0x254b')],'series':['TOTAL'],'data':[[0x32]],'options':{'responsive':!![],'legend':{'display':!![],'fontColor':'#2196f3'},'scales':{'xAxes':[{'gridLines':{'display':!![]},'ticks':{'fontColor':_0x1956a0('0x1019'),'stepSize':0x1,'beginAtZero':!![]}}],'yAxes':[{'gridLines':{'display':![]},'ticks':{'fontColor':_0x1956a0('0x1019')}}]}}};function _0x8402ac(_0x1b1f51){const _0x2b5c36=_0x1956a0;_0x5860f8[_0x2b5c36('0x1594')]=_0x2e3ca0()[_0x2b5c36('0x386')](_0x2e3ca0()[_0x2b5c36('0x25')](_0x1b1f51[_0x2b5c36('0x1221')],function(_0x25faca){const _0x33897f=_0x2b5c36;return _0x25faca[_0x33897f('0x60a')]&&_0x25faca[_0x33897f('0x60a')]['indexOf'](_0x33897f('0x2bb'))>=0x0&&_0x25faca[_0x33897f('0x1c6b')]&&_0x25faca[_0x33897f('0x1c6b')]!==_0x33897f('0x13c');}),_0x2b5c36('0x1c6b'));_0x1b1f51[_0x2b5c36('0x1221')][0x3][_0x2b5c36('0x1c6b')]&&_0x1b1f51['attrs'][0x3][_0x2b5c36('0x1c6b')][_0x2b5c36('0x1564')]?(_0x5860f8[_0x2b5c36('0x17a4')]=!![],_0x5860f8[_0x2b5c36('0x25')]=_0x2e3ca0()[_0x2b5c36('0xcef')](_0x1b1f51[_0x2b5c36('0x1890')],_0x1b1f51[_0x2b5c36('0x1221')][0x3][_0x2b5c36('0x1c6b')])):(_0x5860f8[_0x2b5c36('0x17a4')]=![],_0x5860f8[_0x2b5c36('0x25')]=_0x1b1f51['voiceQueuesSelected']);if(_0x5860f8[_0x2b5c36('0x10a9')][_0x2b5c36('0x2089')][_0x2b5c36('0x1564')]>_0x5860f8[_0x2b5c36('0x1594')]['length']){const _0x4a73ae=_0x5860f8['multiBarChart'][_0x2b5c36('0x2089')][_0x2b5c36('0x1564')]-_0x5860f8['properties'][_0x2b5c36('0x1564')];_0x5860f8['multiBarChart']['series'][_0x2b5c36('0x2040')](0x0,_0x4a73ae),_0x5860f8['multiBarChart'][_0x2b5c36('0x5a5')][_0x2b5c36('0x2040')](0x0,_0x4a73ae);}for(let _0x487f2a=0x0;_0x487f2a<_0x5860f8[_0x2b5c36('0x1594')][_0x2b5c36('0x1564')];_0x487f2a+=0x1){_0x5860f8[_0x2b5c36('0x10a9')][_0x2b5c36('0x2089')][_0x487f2a]=_0x34a804[_0x2b5c36('0x2728')](_0x2b5c36('0x219a')+_0x5860f8['properties'][_0x487f2a][_0x2b5c36('0x80')]());_0x2e3ca0()[_0x2b5c36('0x8f2')](_0x5860f8[_0x2b5c36('0x10a9')]['data'][_0x487f2a])&&(_0x5860f8[_0x2b5c36('0x10a9')][_0x2b5c36('0x5a5')][_0x487f2a]=[]);if(_0x5860f8['multiBarChart'][_0x2b5c36('0x18e1')][_0x2b5c36('0x1564')]>_0x5860f8[_0x2b5c36('0x25')][_0x2b5c36('0x1564')]){const _0x4def80=_0x5860f8['multiBarChart']['labels'][_0x2b5c36('0x1564')]-_0x5860f8[_0x2b5c36('0x25')][_0x2b5c36('0x1564')];_0x5860f8[_0x2b5c36('0x10a9')]['labels'][_0x2b5c36('0x2040')](0x0,_0x4def80),_0x5860f8['multiBarChart'][_0x2b5c36('0x5a5')][_0x487f2a][_0x2b5c36('0x2040')](0x0,_0x4def80);}for(let _0x275d1d=0x0,_0x474a8c=0x0;_0x275d1d<_0x1b1f51['voiceQueues'][_0x2b5c36('0xf5d')][_0x2b5c36('0x1564')];_0x275d1d+=0x1){_0x2e3ca0()[_0x2b5c36('0x2292')](_0x5860f8[_0x2b5c36('0x25')],_0x1b1f51[_0x2b5c36('0x426')][_0x2b5c36('0xf5d')][_0x275d1d]['id'])&&(_0x5860f8[_0x2b5c36('0x10a9')]['labels'][_0x474a8c]=_0x1b1f51['voiceQueues'][_0x2b5c36('0xf5d')][_0x275d1d][_0x2b5c36('0x60a')],_0x5860f8[_0x2b5c36('0x10a9')][_0x2b5c36('0x5a5')][_0x487f2a][_0x474a8c]=_0x1b1f51['voiceQueues'][_0x2b5c36('0xf5d')][_0x275d1d][_0x5860f8['properties'][_0x487f2a]]?parseInt(_0x1b1f51[_0x2b5c36('0x426')][_0x2b5c36('0xf5d')][_0x275d1d][_0x5860f8['properties'][_0x487f2a]]):0x0,_0x474a8c+=0x1);}}}function _0x2421d9(_0x581271){const _0x3e496a=_0x1956a0;_0x5860f8['multiBarChart'][_0x3e496a('0x158e')]['legend'][_0x3e496a('0x1d54')]=_0x581271[_0x3e496a('0x17c9')];for(let _0x5837c0=0x0;_0x5837c0<_0x5860f8[_0x3e496a('0x10a9')]['options'][_0x3e496a('0xc47')]['xAxes'][_0x3e496a('0x1564')];_0x5837c0+=0x1){_0x5860f8['multiBarChart'][_0x3e496a('0x158e')][_0x3e496a('0xc47')]['xAxes'][_0x5837c0]['ticks'][_0x3e496a('0x1d54')]=_0x581271['foreground'];}for(let _0xa8e07b=0x0;_0xa8e07b<_0x5860f8[_0x3e496a('0x10a9')][_0x3e496a('0x158e')]['scales'][_0x3e496a('0x266b')][_0x3e496a('0x1564')];_0xa8e07b+=0x1){_0x5860f8[_0x3e496a('0x10a9')]['options'][_0x3e496a('0xc47')][_0x3e496a('0x266b')][_0xa8e07b]['ticks']['fontColor']=_0x581271['foreground'];}}function _0x3d5e84(_0x1d9cb3){const _0x558628=_0x1956a0;_0x1d9cb3&&(_0x1d9cb3[_0x558628('0x1221')]&&_0x8402ac(_0x1d9cb3),_0x1d9cb3[_0x558628('0x17c9')]&&_0x2421d9(_0x1d9cb3));}_0x5860f8[_0x1956a0('0x19ea')]=_0x3d5e84;}const _0x1ab446=_0x246431;_0xb073da[_0x189033('0x14be')]=['$translate'];function _0xb073da(_0xc5b8){const _0x184e8d=_0x189033,_0x54783a=this;_0x54783a[_0x184e8d('0x25')]=[],_0x54783a[_0x184e8d('0x17a4')]=![],_0x54783a[_0x184e8d('0x1594')]=[],_0x54783a['pieChart']={'labels':[_0x184e8d('0x272e')],'data':[0x1e],'options':{'responsive':!![],'legend':{'display':!![]}}};function _0x304f68(_0x68531c){const _0xb4b10e=_0x184e8d;_0x54783a['properties']=_0x2e3ca0()[_0xb4b10e('0x386')](_0x2e3ca0()['filter'](_0x68531c['attrs'],function(_0x49fdf5){const _0x14c7a9=_0xb4b10e;return _0x49fdf5[_0x14c7a9('0x60a')]&&_0x49fdf5[_0x14c7a9('0x60a')][_0x14c7a9('0x824')](_0x14c7a9('0x2bb'))>=0x0&&_0x49fdf5[_0x14c7a9('0x1c6b')]&&_0x49fdf5[_0x14c7a9('0x1c6b')]!==_0x14c7a9('0x13c');}),_0xb4b10e('0x1c6b'));_0x68531c['attrs'][0x3][_0xb4b10e('0x1c6b')]&&_0x68531c['attrs'][0x3][_0xb4b10e('0x1c6b')]['length']?(_0x54783a[_0xb4b10e('0x17a4')]=!![],_0x54783a[_0xb4b10e('0x25')]=_0x2e3ca0()['intersection'](_0x68531c['voiceQueuesSelected'],_0x68531c[_0xb4b10e('0x1221')][0x3]['value'])):(_0x54783a[_0xb4b10e('0x17a4')]=![],_0x54783a[_0xb4b10e('0x25')]=_0x68531c[_0xb4b10e('0x1890')]);if(_0x54783a[_0xb4b10e('0x22f1')][_0xb4b10e('0x18e1')][_0xb4b10e('0x1564')]>_0x54783a['properties'][_0xb4b10e('0x1564')]){const _0x1b5eb4=_0x54783a['pieChart']['labels'][_0xb4b10e('0x1564')]-_0x54783a[_0xb4b10e('0x1594')][_0xb4b10e('0x1564')];_0x54783a[_0xb4b10e('0x22f1')]['labels']['splice'](0x0,_0x1b5eb4),_0x54783a['pieChart']['data'][_0xb4b10e('0x2040')](0x0,_0x1b5eb4);}for(let _0x2649f5=0x0,_0x183aaa=0x0;_0x2649f5<_0x54783a[_0xb4b10e('0x1594')]['length'];_0x2649f5+=0x1){_0x54783a[_0xb4b10e('0x22f1')][_0xb4b10e('0x18e1')][_0x2649f5]=_0xc5b8[_0xb4b10e('0x2728')](_0xb4b10e('0x219a')+_0x54783a[_0xb4b10e('0x1594')][_0x2649f5][_0xb4b10e('0x80')]());for(let _0x5ec373=0x0;_0x5ec373<_0x68531c[_0xb4b10e('0x426')]['rows'][_0xb4b10e('0x1564')];_0x5ec373+=0x1){_0x2e3ca0()[_0xb4b10e('0x2292')](_0x54783a[_0xb4b10e('0x25')],_0x68531c[_0xb4b10e('0x426')][_0xb4b10e('0xf5d')][_0x5ec373]['id'])&&(_0x183aaa+=_0x68531c[_0xb4b10e('0x426')][_0xb4b10e('0xf5d')][_0x5ec373][_0x54783a[_0xb4b10e('0x1594')][_0x2649f5]]?parseInt(_0x68531c[_0xb4b10e('0x426')][_0xb4b10e('0xf5d')][_0x5ec373][_0x54783a['properties'][_0x2649f5]]):0x0);}_0x54783a[_0xb4b10e('0x22f1')][_0xb4b10e('0x5a5')][_0x2649f5]=_0x183aaa,_0x183aaa=0x0;}}function _0x53c4d6(_0x565668){const _0x4b9a3c=_0x184e8d;_0x54783a[_0x4b9a3c('0x22f1')]['options']['legend'][_0x4b9a3c('0x1d54')]=_0x565668[_0x4b9a3c('0x17c9')];}function _0x1c6b12(_0x4e15e3){const _0x44bb00=_0x184e8d;_0x4e15e3&&(_0x4e15e3['attrs']&&_0x304f68(_0x4e15e3),_0x4e15e3[_0x44bb00('0x17c9')]&&_0x53c4d6(_0x4e15e3));}_0x54783a['getPieChart']=_0x1c6b12;}const _0x1d4a76=_0xb073da;_0x47da25[_0x189033('0x14be')]=['$scope',_0x189033('0x2f9'),_0x189033('0x1b27'),'api'];function _0x47da25(_0x13c625,_0x42597d,_0x27e9d0,_0x1c3424){const _0x39c750=_0x189033,_0x117d0c=this;_0x117d0c['countDown']=0x0,_0x117d0c[_0x39c750('0x7b2')]=0x0,_0x117d0c[_0x39c750('0xf28')]='',_0x117d0c[_0x39c750('0x1a7f')]=[],_0x117d0c[_0x39c750('0x546')]={'rows':[],'count':0x0},_0x117d0c[_0x39c750('0x23a2')]={'limit':0xa,'page':0x1,'startDate':_0x1aaf93()()[_0x39c750('0x1627')](_0x39c750('0x1efa'))[_0x39c750('0x26dd')](_0x39c750('0x865')),'endDate':_0x1aaf93()()[_0x39c750('0x3b3')]('day')[_0x39c750('0x26dd')]('YYYY-MM-DD\x20HH:mm:ss'),'output':_0x39c750('0x1eee')},_0x117d0c[_0x39c750('0x1dd2')]=_0x5bbd4e,_0x117d0c['getResults']=_0x39f398,_0x117d0c[_0x39c750('0x1849')]=_0x36b9bb;function _0x5bbd4e(_0x1962ea){const _0x43c2c9=_0x39c750;_0x1962ea&&(_0x1962ea[_0x43c2c9('0x1221')]&&(_0x1962ea[_0x43c2c9('0x1221')][0x0]&&_0x1962ea[_0x43c2c9('0x1221')][0x0][_0x43c2c9('0x1c6b')]&&(_0x117d0c[_0x43c2c9('0x23a2')]['id']=_0x1962ea[_0x43c2c9('0x1221')][0x0][_0x43c2c9('0x1c6b')],_0x1c3424[_0x43c2c9('0x2871')][_0x43c2c9('0x1e6e')]({'fields':'field,alias','nolimit':!![],'DefaultReportId':_0x1962ea['attrs'][0x0][_0x43c2c9('0xcf0')]===_0x43c2c9('0x9cb')?_0x1962ea[_0x43c2c9('0x1221')][0x0]['value']:undefined,'CustomReportId':_0x1962ea[_0x43c2c9('0x1221')][0x0][_0x43c2c9('0xcf0')]==='custom'?_0x1962ea['attrs'][0x0][_0x43c2c9('0x1c6b')]:undefined})['$promise'][_0x43c2c9('0x683')](function(_0x152e78){const _0x6ebf56=_0x43c2c9;_0x152e78&&_0x152e78[_0x6ebf56('0xf5d')]&&(_0x117d0c[_0x6ebf56('0x1a7f')]=_0x152e78['rows']);switch(_0x1962ea['attrs'][0x0][_0x6ebf56('0xcf0')]){case'default':_0x117d0c['reportRoute']=_0x6ebf56('0x20ec');break;case _0x6ebf56('0xbf0'):_0x117d0c[_0x6ebf56('0x20f6')]=_0x6ebf56('0x197f');break;}return _0x1c3424[_0x117d0c[_0x6ebf56('0x20f6')]][_0x6ebf56('0x1e6e')]({'id':_0x1962ea[_0x6ebf56('0x1221')][0x0][_0x6ebf56('0x1c6b')],'fields':_0x6ebf56('0xa10')})[_0x6ebf56('0xe53')];})[_0x43c2c9('0x683')](function(_0x106011){const _0x2a5604=_0x43c2c9;_0x106011&&_0x106011['name']&&(_0x117d0c[_0x2a5604('0xf28')]=_0x106011[_0x2a5604('0x60a')]),_0x39f398();})[_0x43c2c9('0x130a')](function(_0x81709c){const _0x3ac114=_0x43c2c9;console[_0x3ac114('0x1b2b')](_0x81709c);})),_0x1962ea[_0x43c2c9('0x1221')][0x1]&&_0x1962ea['attrs'][0x1][_0x43c2c9('0x1c6b')]&&(_0x117d0c[_0x43c2c9('0x7b2')]=parseInt(_0x1962ea[_0x43c2c9('0x1221')][0x1][_0x43c2c9('0x1c6b')]),!_0x2e3ca0()[_0x43c2c9('0xebf')](_0x117d0c['refresh'])&&_0x117d0c['refresh']>0x0?(_0x117d0c[_0x43c2c9('0x24b9')]=parseInt(_0x1962ea[_0x43c2c9('0x1221')][0x1]['value']),_0x117d0c[_0x43c2c9('0x115c')]=_0x27e9d0(function(){const _0x2a3f93=_0x43c2c9;_0x117d0c[_0x2a3f93('0x24b9')]-=0x1;},0x3e8,0x0),_0x117d0c[_0x43c2c9('0x1668')]=_0x42597d(function(){const _0x377dd3=_0x43c2c9;_0x117d0c[_0x377dd3('0x115c')]&&_0x27e9d0[_0x377dd3('0x19fb')](_0x117d0c['interval']),_0x5bbd4e(_0x1962ea);},_0x117d0c[_0x43c2c9('0x7b2')]*0x3e8)):(_0x117d0c[_0x43c2c9('0x115c')]&&_0x27e9d0[_0x43c2c9('0x19fb')](_0x117d0c[_0x43c2c9('0x115c')]),_0x117d0c[_0x43c2c9('0x1668')]&&_0x42597d['cancel'](_0x117d0c[_0x43c2c9('0x1668')])))));}function _0xf0c08f(_0x181b73){const _0x34aeda=_0x39c750;_0x117d0c[_0x34aeda('0x546')]=_0x181b73||{'count':0x0,'rows':[]};}function _0x39f398(){const _0x482d53=_0x39c750;_0x117d0c[_0x482d53('0x23a2')][_0x482d53('0x1cc8')]=(_0x117d0c[_0x482d53('0x23a2')][_0x482d53('0xdf8')]-0x1)*_0x117d0c[_0x482d53('0x23a2')][_0x482d53('0x6f0')],_0x117d0c[_0x482d53('0x1883')]=_0x1c3424[_0x117d0c[_0x482d53('0x20f6')]][_0x482d53('0x11a0')](_0x117d0c[_0x482d53('0x23a2')],_0xf0c08f)[_0x482d53('0xe53')];}function _0x36b9bb(_0x57a611,_0x1701f4){const _0x2e4901=_0x39c750;return _0x1aaf93()(_0x1701f4,_0x2e4901('0x1b7e'),!![])[_0x2e4901('0x24f4')]()&&(_0x1701f4=_0x1aaf93()(_0x1701f4,'')[_0x2e4901('0x26dd')](_0x2e4901('0x865'))),_0x1701f4;}_0x13c625[_0x39c750('0x26a2')](_0x39c750('0x4b8'),function(){const _0x50d328=_0x39c750;_0x117d0c[_0x50d328('0x115c')]&&_0x27e9d0[_0x50d328('0x19fb')](_0x117d0c[_0x50d328('0x115c')]),_0x117d0c['timeout']&&_0x42597d['cancel'](_0x117d0c[_0x50d328('0x1668')]);});}const _0x9acb2f=_0x47da25,_0x1df1df=_0x180212['p']+_0x189033('0x3d3');_0x2be006[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x204d')];function _0x2be006(_0x39b85f,_0x299301){const _0x4354b5=this;function _0x51de8d(_0x14b81f){return _0x299301['trustAsResourceUrl'](_0x14b81f);}_0x4354b5['getTrustedURL']=_0x51de8d;}function _0x3e8302(){const _0x15e6c2=_0x189033;return{'restrict':'E','scope':{'config':'=?','onEdit':'&?','onDelete':'&?'},'require':'msWidgetEngine','controller':_0x15e6c2('0x21da'),'controllerAs':'vm','bindToController':!![],'templateUrl':_0x1df1df};}_0x5d245c[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1222')];function _0x5d245c(_0x42b182,_0x5d93b9){const _0x281005=_0x189033,_0x3a01f8=this;_0x3a01f8[_0x281005('0x2648')]=![];function _0x574419(){const _0x3be2d0=_0x281005;return angular['isDefined'](_0x42b182[_0x3be2d0('0x25f8')])&&_0x42b182['flippable']===!![];}function _0x461c2a(){const _0x1c5ddf=_0x281005;if(!_0x574419())return;_0x3a01f8[_0x1c5ddf('0x2648')]=!_0x3a01f8[_0x1c5ddf('0x2648')],_0x5d93b9['toggleClass'](_0x1c5ddf('0x2648'),_0x3a01f8[_0x1c5ddf('0x2648')]);}_0x3a01f8[_0x281005('0x239')]=_0x461c2a;}function _0x58e6b4(){const _0x46c14e=_0x189033;return{'restrict':'E','scope':{'flippable':'=?'},'controller':_0x46c14e('0x2f3'),'transclude':!![],'compile':function(_0x4ce785){const _0x5a17b0=_0x46c14e;return _0x4ce785[_0x5a17b0('0x81e')]('ms-widget'),function _0x346ca0(_0x46724d,_0x434da0,_0x4126cf,_0x457dd3,_0x4a6218){_0x4a6218(function(_0x230209){const _0x4cb214=a0_0x4e0a;_0x434da0[_0x4cb214('0xb18')](),_0x434da0[_0x4cb214('0x22d6')](_0x230209);});};}};}function _0x26f6ac(){const _0x3f72dd=_0x189033;return{'restrict':'E','require':_0x3f72dd('0x2679'),'transclude':!![],'compile':function(_0x48e979){const _0x26b3de=_0x3f72dd;return _0x48e979['addClass'](_0x26b3de('0x271e')),function _0x1f08eb(_0x4d1f91,_0x37c4d9,_0x5789d7,_0x4d4557,_0x37a0d5){const _0x25ea5c=_0x26b3de;_0x37a0d5(function(_0x1bad6f){const _0x43c2e7=a0_0x4e0a;_0x37c4d9[_0x43c2e7('0xb18')](),_0x37c4d9[_0x43c2e7('0x22d6')](_0x1bad6f);}),_0x4d1f91[_0x25ea5c('0x1f70')]=_0x4d4557[_0x25ea5c('0x239')];};}};}function _0x7cb41a(){const _0x55190d=_0x189033;return{'restrict':'E','require':_0x55190d('0x2679'),'transclude':!![],'compile':function(_0x1abcac){const _0xe65eeb=_0x55190d;return _0x1abcac[_0xe65eeb('0x81e')](_0xe65eeb('0x5cb')),function _0x3c46bc(_0x27ce18,_0x2859af,_0x3e2965,_0x4c4609,_0x1ec989){const _0x47c80e=_0xe65eeb;_0x1ec989(function(_0x45c116){const _0x33cab0=a0_0x4e0a;_0x2859af[_0x33cab0('0xb18')](),_0x2859af[_0x33cab0('0x22d6')](_0x45c116);}),_0x27ce18['flipWidget']=_0x4c4609[_0x47c80e('0x239')];};}};};const _0x1ee543=[['focusOn',_0x5ab932,_0x189033('0x18ea')],[_0x189033('0x2185'),_0x248533,_0x189033('0x18ea')],[_0x189033('0x1669'),_0x541a86,_0x189033('0x18ea')],['msCard',_0x4acef8,'directive'],[_0x189033('0x661'),_0x4b058a,'directive'],[_0x189033('0xea5'),_0x49351f,_0x189033('0x18ea')],[_0x189033('0x21dc'),_0x52b50f,'provider'],[_0x189033('0x1df3'),_0x423f11,_0x189033('0x18ea')],[_0x189033('0x63f'),_0x53a581,_0x189033('0x18ea')],['msDualMultiselect',_0x175a28,'directive'],[_0x189033('0x12b2'),_0x48f43c,_0x189033('0x18ea')],[_0x189033('0x10b3'),_0x703ba8,_0x189033('0x18ea')],['MsFormWizardController',_0x44187c,_0x189033('0x1da3')],[_0x189033('0x1d53'),_0x59d601,'directive'],[_0x189033('0xb44'),_0x4b977c,_0x189033('0x18ea')],[_0x189033('0x1391'),_0x261d5a,'directive'],[_0x189033('0xcc9'),_0x1ca43b,_0x189033('0x1da3')],['msMasonry',_0x4fc358,_0x189033('0x18ea')],[_0x189033('0xbf1'),_0x2ccc51,_0x189033('0x18ea')],['msMaterialColorPickerController',_0x478fcc,_0x189033('0x1da3')],[_0x189033('0x2634'),_0x381c35,_0x189033('0x18ea')],[_0x189033('0x5e4'),_0x2193f9,_0x189033('0x1f97')],[_0x189033('0x1baa'),_0x8d177b,_0x189033('0x18ea')],[_0x189033('0x744'),_0x33fa24,_0x189033('0x1da3')],['msNav',_0x111391,_0x189033('0x18ea')],[_0x189033('0x2051'),_0xd86209,_0x189033('0x18ea')],[_0x189033('0x198e'),_0x227dff,'directive'],[_0x189033('0x16c1'),_0x1518e3,_0x189033('0x18ea')],[_0x189033('0x27c0'),_0x11c88f,_0x189033('0x22fe')],[_0x189033('0xfe4'),_0x12674b,_0x189033('0x1da3')],[_0x189033('0xe17'),_0x4d2f0f,_0x189033('0x18ea')],[_0x189033('0xb6e'),_0x35e728,_0x189033('0x1da3')],['msNavigationNode',_0x175145,'directive'],[_0x189033('0x1b22'),_0x51c6aa,'directive'],[_0x189033('0x130'),_0x193a83,_0x189033('0x18ea')],['MsNavigationHorizontalNodeController',_0x39243c,_0x189033('0x1da3')],[_0x189033('0x2563'),_0x11040f,'directive'],[_0x189033('0x1c9e'),_0x94496d,_0x189033('0x18ea')],['MsPhonebarController',_0x23bff7,_0x189033('0x1da3')],[_0x189033('0x231f'),_0x2ca283,_0x189033('0x18ea')],[_0x189033('0x15fb'),_0x4dd772,_0x189033('0x1da3')],[_0x189033('0x1287'),_0x322a9f,'directive'],[_0x189033('0x160d'),_0x212024,_0x189033('0x1da3')],[_0x189033('0x1436'),_0x195e0b,_0x189033('0x1da3')],[_0x189033('0x12a0'),_0x4162ca,'controller'],['msQuickFilter',_0x8d5cbd,_0x189033('0x18ea')],[_0x189033('0x14de'),_0x26ebff,_0x189033('0x1f97')],[_0x189033('0x1947'),_0x2c4ccc,_0x189033('0x18ea')],[_0x189033('0x14e'),_0x480f64,'directive'],[_0x189033('0x226c'),_0x349479,_0x189033('0x18ea')],[_0x189033('0x2077'),_0x41c240,_0x189033('0x22fe')],[_0x189033('0x2585'),_0x44b2e7,_0x189033('0x18ea')],[_0x189033('0x1add'),_0x2dc548,'controller'],[_0x189033('0x26fc'),_0x3f0ab3,_0x189033('0x18ea')],[_0x189033('0x246b'),_0x4d9ba9,_0x189033('0x1da3')],['msShortcuts',_0x46a3a9,_0x189033('0x18ea')],[_0x189033('0x21e5'),_0x29127c,_0x189033('0x18ea')],[_0x189033('0x269f'),_0x2a67a6,_0x189033('0x18ea')],[_0x189033('0x2454'),_0x48c014,'controller'],[_0x189033('0x468'),_0x3e3b09,_0x189033('0x18ea')],[_0x189033('0x11aa'),_0x3e5895,'directive'],['msVerticalStepper',_0x5db1a1,_0x189033('0x18ea')],['msVerticalStepperStep',_0x1f3ead,_0x189033('0x18ea')],['MsTabScrollController',_0x12898f,_0x189033('0x1da3')],[_0x189033('0x16d1'),_0x2e0d2d,_0x189033('0x18ea')],[_0x189033('0x665'),_0x565ba8,_0x189033('0x1da3')],[_0x189033('0x23e5'),_0x51cfd9,_0x189033('0x18ea')],[_0x189033('0xfeb'),_0x48e709,'directive'],[_0x189033('0x25cd'),_0x44dfcf,'controller'],[_0x189033('0x1c77'),_0x56f896,'directive'],['msTimezone',_0x178363,_0x189033('0x18ea')],[_0x189033('0x12b1'),_0x2c3031,'controller'],[_0x189033('0x1718'),_0x1ab446,_0x189033('0x1da3')],['MsWidgetEnginePieChartController',_0x1d4a76,_0x189033('0x1da3')],['MsWidgetEngineWebReportController',_0x9acb2f,_0x189033('0x1da3')],['MsWidgetEngineController',_0x2be006,_0x189033('0x1da3')],[_0x189033('0x191d'),_0x3e8302,_0x189033('0x18ea')],[_0x189033('0x2f3'),_0x5d245c,'controller'],['msWidget',_0x58e6b4,_0x189033('0x18ea')],[_0x189033('0x188c'),_0x26f6ac,'directive'],['msWidgetBack',_0x7cb41a,_0x189033('0x18ea')]],_0x4bd6d3=_0x1ee543;_0x1de9ce['$inject']=['$q','$translate'];function _0x1de9ce(_0x521a3f,_0x2a73da){function _0x5e2382(_0x323f53){let _0x31d9fd;return _0x521a3f(function(_0x474e7c){const _0xe59fad=a0_0x4e0a;try{if(_0x2e3ca0()['isEmpty'](_0x323f53[_0xe59fad('0x15d6')]))_0x31d9fd=_0x2a73da['instant'](_0xe59fad('0xfd6'));else{if(_0x2e3ca0()[_0xe59fad('0x173f')](_0x323f53[_0xe59fad('0x2108')]))_0x31d9fd=_0x323f53[_0xe59fad('0x156b')]?_0x2a73da[_0xe59fad('0x2728')](_0x323f53[_0xe59fad('0x156b')]):_0x2a73da[_0xe59fad('0x2728')]('DASHBOARDS.CHOOSE');else{if(_0x323f53[_0xe59fad('0x2108')][_0xe59fad('0x1564')]===_0x323f53[_0xe59fad('0x15d6')]['length'])_0x31d9fd=_0x2a73da[_0xe59fad('0x2728')](_0xe59fad('0x475'));else{const _0x26face=_0x323f53[_0xe59fad('0xee7')]||'id';_0x31d9fd=_0x2e3ca0()(_0x323f53[_0xe59fad('0x15d6')])[_0xe59fad('0x25')](function(_0x5978eb){const _0x3781f2=_0xe59fad;return _0x2e3ca0()['includes'](_0x323f53[_0x3781f2('0x2108')],_0x5978eb[_0x26face]);})['map'](_0xe59fad('0x60a'))[_0xe59fad('0x1c6b')]()['join'](',\x20');}}}_0x474e7c(_0x31d9fd);}catch(_0x2ba5ca){console['log'](_0xe59fad('0x22f4'),_0x2ba5ca),_0x474e7c(null);}});}const _0x1af6f6={'setPlaceholder':_0x5e2382};return _0x1af6f6;}const _0x2a49f3=_0x1de9ce;;function _0x2234a7(){return function(_0x26e46c){const _0x1c0a61=a0_0x4e0a,_0x34ba3b=Date[_0x1c0a61('0x1be9')]()-new Date(_0x26e46c);if(_0x34ba3b<0x3c*0x3c*0x3e8)return _0x1aaf93()(_0x26e46c)['fromNow']();else{if(_0x34ba3b<0x3c*0x3c*0x18*0x3e8)return _0x1aaf93()(_0x26e46c)[_0x1c0a61('0x26dd')](_0x1c0a61('0x3ed'));else return _0x34ba3b<0x3c*0x3c*0x18*0x7*0x3e8?_0x1aaf93()(_0x26e46c)[_0x1c0a61('0x26dd')](_0x1c0a61('0xd2')):_0x1aaf93()(_0x26e46c)['calendar']();}};}const _0x1f318f=_0x2234a7;_0x478ff7[_0x189033('0x14be')]=[_0x189033('0x204d')];function _0x478ff7(_0x5dee6b){return function(_0x15e2be){const _0x5e4a25=a0_0x4e0a;return _0x5dee6b[_0x5e4a25('0xa1')](_0x15e2be);};}function _0x170911(){return function(_0x32a168){const _0x49288d=a0_0x4e0a;return String(_0x32a168)[_0x49288d('0x1725')](/<[^>]+>/gm,'');};}function _0x389ba9(){return function(_0x43c8e0){const _0x35accf=a0_0x4e0a;return!_0x43c8e0?'':_0x43c8e0[_0x35accf('0x1725')](/ /g,'');};}function _0x4807fb(){return function(_0x588b78){const _0x4912da=a0_0x4e0a;if(!_0x588b78)return;if(_0x588b78[_0x4912da('0xcf0')]==='directive')return _0x588b78[_0x4912da('0x60a')][_0x4912da('0x1725')](/([A-Z])/g,function(_0x39f8cd){const _0x3b68eb=_0x4912da;return'-'+_0x39f8cd[_0x3b68eb('0x93a')]();});return _0x588b78[_0x4912da('0xfc9')]||_0x588b78['name'];};};function _0x4ef96d(){return function(_0x391def){const _0x97ab0d=a0_0x4e0a;if(!_0x391def)return'';return _0x2e3ca0()[_0x97ab0d('0x21ab')](_0x391def);};}const _0x34b9a2=_0x4ef96d;function _0x25173b(){return function(_0xabf8f5,_0x5a5639){const _0x5c141a=a0_0x4e0a;if(_0xabf8f5[_0x5c141a('0x1564')]===0x0||!_0x5a5639)return _0xabf8f5;if(_0x5a5639['length']===0x0)return[];const _0x500865=[];for(let _0x59a939=0x0;_0x59a939<_0xabf8f5[_0x5c141a('0x1564')];_0x59a939++){const _0xcb7304=_0xabf8f5[_0x59a939];let _0x34b380=![];for(let _0x3c327e=0x0;_0x3c327e<_0x5a5639['length'];_0x3c327e++){const _0x2c2b87=_0x5a5639[_0x3c327e];if(_0xcb7304['id']===_0x2c2b87){_0x34b380=!![];break;}}_0x34b380&&_0x500865['push'](_0xcb7304);}return _0x500865;};}const _0x31585e=_0x25173b;function _0x306443(){return function(_0x5cf688,_0x262e8f,_0x395a09){const _0x90a5f8=a0_0x4e0a;if(_0x5cf688[_0x90a5f8('0x1564')]===0x0||!_0x395a09||_0x395a09[_0x90a5f8('0x1564')]===0x0)return _0x5cf688;const _0x336a5a=[];for(let _0x33c6ae=0x0;_0x33c6ae<_0x5cf688['length'];_0x33c6ae++){const _0x17cbc5=_0x5cf688[_0x33c6ae];let _0x285f78=![];for(let _0x9504d2=0x0;_0x9504d2<_0x395a09[_0x90a5f8('0x1564')];_0x9504d2++){const _0x11ecde=_0x395a09[_0x9504d2];if(_0x17cbc5[_0x262e8f]['indexOf'](_0x11ecde)>-0x1){_0x285f78=!![];break;}}_0x285f78&&_0x336a5a[_0x90a5f8('0x1fd0')](_0x17cbc5);}return _0x336a5a;};}const _0x11dba6=_0x306443;;function _0x7ef4ef(){return function(_0x5a2cd2){if(!_0x5a2cd2)return'';return _0x2e3ca0()['snakeCase'](_0x5a2cd2);};}const _0x5165e5=_0x7ef4ef;;function _0x288ed6(){return function(_0x27e6a8){const _0x55ec4e=a0_0x4e0a;if(!_0x27e6a8)return'';return _0x2e3ca0()[_0x55ec4e('0x1e03')](_0x27e6a8);};}const _0x4c83c2=_0x288ed6;function _0x831367(){return function(_0x2cb5ae,_0x5c00b8){const _0x5e5a00=a0_0x4e0a;if(_0x2cb5ae[_0x5e5a00('0x1564')]===0x0||_0x5c00b8[_0x5e5a00('0x1564')]===0x0)return _0x2cb5ae;const _0x27a51c=[];return _0x2cb5ae[_0x5e5a00('0x1299')](function(_0x320977){const _0x26ff38=_0x5e5a00,_0xddbaf4=_0x5c00b8['every'](function(_0x4b4175){const _0x38e539=a0_0x4e0a;let _0x249fb5=![];return _0x320977[_0x38e539('0x1ce6')][_0x38e539('0x1299')](function(_0x6ae71){const _0x25857f=_0x38e539;if(_0x6ae71[_0x25857f('0x60a')]===_0x4b4175[_0x25857f('0x60a')]){_0x249fb5=!![];return;}}),_0x249fb5;});_0xddbaf4&&_0x27a51c[_0x26ff38('0x1fd0')](_0x320977);}),_0x27a51c;};}function _0x3b246e(){return function(_0x16ab67,_0x474816){const _0x337de5=a0_0x4e0a;if(_0x16ab67[_0x337de5('0x1564')]===0x0||_0x474816[_0x337de5('0x1564')]===0x0)return;if(_0x16ab67[_0x337de5('0x1564')]<_0x474816[_0x337de5('0x1564')])return[];const _0xddaa38=[],_0x3bcaa1=_0x474816['every'](function(_0x3e536a){const _0x365239=_0x337de5;let _0x323de2=![];return _0x16ab67[_0x365239('0x1299')](function(_0x6d0a9c){const _0x1f13e1=_0x365239;if(_0x6d0a9c[_0x1f13e1('0x60a')]===_0x3e536a['name']){_0x323de2=!![];return;}}),_0x323de2;});return _0x3bcaa1&&_0xddaa38['push'](_0x16ab67),_0xddaa38;};};class _0x2184d5{constructor(_0x3b4951,_0x799e48,_0x31ab70,_0xd99631){const _0x5d0005=_0x189033;this['id']=Math[_0x5d0005('0x25c6')]()['toString'](0x24)['substring'](0x2,0xf)+Math[_0x5d0005('0x25c6')]()[_0x5d0005('0x1ff0')](0x24)['substring'](0x2,0xf),this[_0x5d0005('0xf28')]=_0x3b4951,this[_0x5d0005('0x18e5')]=_0x799e48,this[_0x5d0005('0xd84')]=_0x31ab70,this[_0x5d0005('0xfae')]=_0xd99631,this[_0x5d0005('0x12b0')]=_0x123bc9;}}function _0x53b707(){const _0x1b3763=_0x189033;return!(window[_0x1b3763('0x12e1')][_0x1b3763('0x1fb4')]||window[_0x1b3763('0x12e1')][_0x1b3763('0x145f')]||window['document'][_0x1b3763('0x13c8')]);}function _0x5925ad(){const _0x52ef7e=_0x189033;return/Chrome/['test'](navigator[_0x52ef7e('0x1b00')])&&/Google Inc/[_0x52ef7e('0x237c')](navigator['vendor']);}function _0x123bc9(){const _0x1b9a99=_0x189033,_0x520eb9=this;navigator[_0x1b9a99('0x1d61')][_0x1b9a99('0x330')][_0x1b9a99('0x683')](function(_0x48a3cb){const _0x214bf8=_0x1b9a99;_0x48a3cb[_0x214bf8('0xad2')]()[_0x214bf8('0x683')](function(_0x5cf1e1){const _0x3d512b=_0x214bf8,_0x3dff12=_0x2e3ca0()[_0x3d512b('0x1c07')](_0x5cf1e1,function(_0x42a207){const _0x5e7624=_0x3d512b;return _0x42a207[_0x5e7624('0x5a5')]['id']===_0x520eb9['id'];});_0x3dff12&&_0x3dff12[_0x3d512b('0x12b0')]();});});}function _0x5a1be3(){return{'$get':[_0x41150a]};function _0x41150a(){const _0x2795f2=a0_0x4e0a,_0x552bf4=[];let _0x128840,_0x605b9b;return _0x2795f2('0x1d61')in navigator&&_0x5925ad()?navigator[_0x2795f2('0x1d61')][_0x2795f2('0x253b')](_0x2795f2('0xc12'))[_0x2795f2('0x683')](function(_0x3ac34e){const _0xdba664=_0x2795f2;_0x128840=_0x3ac34e,_0x128840['update']();if(_0x128840[_0xdba664('0x1bc8')])_0x605b9b=_0x128840[_0xdba664('0x1bc8')];else{if(_0x128840['waiting'])_0x605b9b=_0x128840['waiting'];else _0x128840['active']&&(_0x605b9b=_0x128840[_0xdba664('0x357')]);}})[_0x2795f2('0x130a')](function(_0x1d7043){console['error']('Service\x20worker\x20registration\x20failed',_0x1d7043);}):console[_0x2795f2('0x52a')](_0x2795f2('0x1f18')),navigator[_0x2795f2('0x1d61')][_0x2795f2('0x1032')](_0x2795f2('0x8c2'),function(_0x27e09a){const _0xce4e9b=_0x2795f2;if(_0x27e09a[_0xce4e9b('0xa22')]!==_0x605b9b)return;const _0x378e35=_0x2e3ca0()[_0xce4e9b('0x1c07')](_0x552bf4,{'id':_0x27e09a[_0xce4e9b('0x5a5')]['id']});if(_0x378e35)switch(_0x27e09a[_0xce4e9b('0x5a5')][_0xce4e9b('0x1f0e')]){case _0xce4e9b('0xd84'):_0x378e35[_0xce4e9b('0xd84')]&&_0x378e35['accept']();break;case'reject':_0x378e35['reject']&&_0x378e35[_0xce4e9b('0xfae')]();break;default:}}),{'create':function(_0xa2fc47,_0x3ea021,_0x30df07,_0x532735,_0x1d1cb0){return new Promise(function(_0xcf9c21,_0x127624){const _0xbd9ba0=a0_0x4e0a;let _0x3c29ef;_0x5925ad()&&!_0x53b707()?(_0x3c29ef=new _0x2184d5(_0xa2fc47||_0xbd9ba0('0x11b5'),_0x3ea021||_0xbd9ba0('0x8fb'),_0x532735,_0x1d1cb0),_0x552bf4[_0xbd9ba0('0x1fd0')](_0x3c29ef),_0x3c29ef?window[_0xbd9ba0('0x365')][_0xbd9ba0('0xb8e')]()[_0xbd9ba0('0x683')](function(_0x1438df){const _0x2e008a=_0xbd9ba0;if(_0x1438df===_0x2e008a('0x146f'))return _0x128840[_0x2e008a('0x6e5')](_0x3c29ef['title'],{'body':_0x3c29ef[_0x2e008a('0x18e5')],'requireInteraction':!![],'icon':_0x30df07||_0x2e008a('0xdd2'),'data':{'id':_0x3c29ef['id']},'actions':[{'action':'accept','title':_0x2e008a('0xda8')},{'action':'reject','title':_0x2e008a('0x13bc')}]});})['then'](function(){_0xcf9c21(_0x3c29ef);})['catch'](function(_0x2a3230){_0x127624(_0x2a3230);}):_0x127624(new Error(_0xbd9ba0('0x217')))):_0xcf9c21();});}};}}const _0x399e97=_0x5a1be3;_0x14165f[_0x189033('0x14be')]=['$q',_0x189033('0x24a8'),_0x189033('0x56b')];function _0x14165f(_0x93db4f,_0x1d803b,_0x322601){const _0x1d3601={'resolve':_0x291add};return _0x1d3601;function _0x291add(_0x307f22,_0x3a096c){const _0x1a6243=a0_0x4e0a,_0x5db3d1=_0x307f22[_0x1a6243('0x1fc5')]('@'),_0x3c551b=_0x5db3d1[0x0],_0x2edcba=_0x5db3d1[0x1],_0x57bbf2=_0x3a096c||{};if(!_0x3c551b||!_0x2edcba)return _0x1d803b['error'](_0x1a6243('0x2644')),![];const _0x3e008f=_0x93db4f['defer'](),_0x596141=_0x5e5918(_0x3c551b);return!_0x596141?(_0x1d803b['error']('Resource\x20\x22'+_0x3c551b+_0x1a6243('0x1c45')),_0x3e008f[_0x1a6243('0xfae')](_0x1a6243('0x20d7')+_0x3c551b+_0x1a6243('0x1c45'))):_0x596141[_0x2edcba](_0x57bbf2,function(_0x50947e){const _0x4c06dd=_0x1a6243;_0x3e008f[_0x4c06dd('0xed7')](_0x50947e);},function(_0x51d8e7){const _0x307bfb=_0x1a6243;_0x3e008f[_0x307bfb('0xfae')](_0x51d8e7);}),_0x3e008f[_0x1a6243('0x1883')];}function _0x5e5918(_0x506147){const _0x27f464=a0_0x4e0a,_0x1c4006=_0x506147[_0x27f464('0x1fc5')]('.');let _0x3a618c=_0x322601;for(let _0x180cb3=0x0;_0x180cb3<_0x1c4006[_0x27f464('0x1564')];_0x180cb3++){if(angular[_0x27f464('0x105d')](_0x3a618c[_0x1c4006[_0x180cb3]])){_0x1d803b[_0x27f464('0x52a')](_0x27f464('0x17d2')+_0x1c4006[_0x180cb3]+_0x27f464('0x2283')),_0x3a618c=![];break;}_0x3a618c=_0x3a618c[_0x1c4006[_0x180cb3]];}if(!_0x3a618c)return![];return _0x3a618c;}}const _0x5a38ec=_0x14165f;_0x392a5f[_0x189033('0x14be')]=[_0x189033('0x1b')];function _0x392a5f(_0x4a42de){function _0x2ea96f(){_0x4a42de['loadingProgress']=!![];}function _0x46bacd(){const _0x23d420=a0_0x4e0a;_0x4a42de[_0x23d420('0xf72')]=![];}const _0x17fd2={'showLoadingIndicator':_0x2ea96f,'hideLoadingIndicator':_0x46bacd};return _0x17fd2;}const _0xc40a0f=_0x392a5f;function _0x43c32c(){const _0x119c62=_0x189033,_0xf5de8d=this,_0x3fbde4=angular[_0x119c62('0xfc0')](['ng'])[_0x119c62('0x1e6e')](_0x119c62('0x24a8'));let _0x566d09='';const _0xf2d2e4=[];_0xf5de8d[_0x119c62('0x1e29')]=_0x4cbf92,_0xf5de8d[_0x119c62('0x1fab')]=_0x3200f4,_0xf5de8d['getApiObject']=_0x4a13cf,_0xf5de8d['register']=_0x126f14;function _0x4cbf92(_0x51ba3b){_0x566d09=_0x51ba3b;}function _0x3200f4(){return _0x566d09;}function _0x4a13cf(){return _0xf2d2e4;}function _0x126f14(_0x16fdf0,_0x516ef1){const _0x4727a6=_0x119c62;if(!angular[_0x4727a6('0xc1c')](_0x16fdf0)){_0x3fbde4[_0x4727a6('0x52a')](_0x4727a6('0x27e7'));return;}if(!angular['isArray'](_0x516ef1)){_0x3fbde4[_0x4727a6('0x52a')](_0x4727a6('0x2882'));return;}_0xf2d2e4[_0x16fdf0]={'url':_0x566d09+(_0x516ef1[0x0]||''),'paramDefaults':_0x516ef1[0x1]||[],'actions':_0x516ef1[0x2]||[],'options':_0x516ef1[0x3]||{}};}this[_0x119c62('0x1862')]=function(_0x6425e7,_0x5f00b5,_0x45a0af,_0x16207d){const _0x2a38c7={'setBaseUrl':_0x4cbf92,'getBaseUrl':_0x3200f4,'register':_0x126f14,'resolve':_0x59cd81,'request':_0x4ce02b};return _0x2a38c7;function _0x59cd81(_0x3989e2,_0x55434f){const _0x2c6884=a0_0x4e0a;_0x16207d[_0x2c6884('0x5ed')](_0x2c6884('0xc17'));const _0x4d5098=_0x3989e2['split']('@'),_0x5120fc=_0x4d5098[0x0],_0x27de51=_0x4d5098[0x1],_0x3d3fad=_0x55434f||{};if(!_0x5120fc||!_0x27de51)return _0x6425e7['error'](_0x2c6884('0x947')),![];const _0x373436=_0x5f00b5['defer'](),_0x416669=_0xf2d2e4[_0x5120fc];if(!_0x416669)_0x6425e7['error']('Resource\x20\x22'+_0x5120fc+'\x22\x20is\x20not\x20defined\x20in\x20the\x20api\x20service!'),_0x373436['reject'](_0x2c6884('0x20d7')+_0x5120fc+'\x22\x20is\x20not\x20defined\x20in\x20the\x20api\x20service!');else{const _0x787ac2=_0x45a0af(_0x416669['url'],_0x416669[_0x2c6884('0x1e59')],_0x416669['actions'],_0x416669[_0x2c6884('0x158e')]);_0x787ac2[_0x27de51](_0x3d3fad,function(_0x1f05f2){const _0x330672=_0x2c6884;_0x373436[_0x330672('0xed7')](_0x1f05f2),_0x16207d['$broadcast'](_0x330672('0x2811'));},function(_0x4b0ccf){const _0x2c78f6=_0x2c6884;_0x373436[_0x2c78f6('0xfae')](_0x4b0ccf),_0x16207d[_0x2c78f6('0x5ed')](_0x2c78f6('0x7bb'));});}return _0x373436[_0x2c6884('0x1883')];}function _0x4ce02b(_0x4bef57,_0x2cb9e8,_0x24d7a1,_0x558381){const _0x2be246=a0_0x4e0a;_0x16207d[_0x2be246('0x5ed')](_0x2be246('0x5e8'));const _0x466f83=_0x4bef57['split']('@'),_0x5cf161=_0x466f83[0x0],_0xba47c5=_0x466f83[0x1],_0x3eea61=_0x2cb9e8||{};if(!_0x5cf161||!_0xba47c5)return _0x6425e7[_0x2be246('0x52a')]('msApi.resolve\x20requires\x20correct\x20action\x20parameter\x20(resourceName@methodName)'),![];const _0x3b0da7=_0x5f00b5[_0x2be246('0x448')](),_0x24a83c=_0xf2d2e4[_0x5cf161];if(!_0x24a83c)_0x6425e7[_0x2be246('0x52a')]('Resource\x20\x22'+_0x5cf161+'\x22\x20is\x20not\x20defined\x20in\x20the\x20api\x20service!'),_0x3b0da7[_0x2be246('0xfae')]('Resource\x20\x22'+_0x5cf161+_0x2be246('0x1c45'));else{const _0x3b8f96=_0x45a0af(_0x24a83c[_0x2be246('0x1284')],_0x24a83c[_0x2be246('0x1e59')],_0x24a83c['actions'],_0x24a83c[_0x2be246('0x158e')]);_0x3b8f96[_0xba47c5](_0x3eea61,function(_0x323ed5){const _0x67e6fd=_0x2be246;_0x16207d[_0x67e6fd('0x5ed')](_0x67e6fd('0x1c48')),_0x3b0da7[_0x67e6fd('0xed7')](_0x323ed5),angular[_0x67e6fd('0x127')](_0x24d7a1)&&angular[_0x67e6fd('0x93f')](_0x24d7a1)&&_0x24d7a1(_0x323ed5);},function(_0x2c89a3){const _0x3a1aeb=_0x2be246;_0x16207d[_0x3a1aeb('0x5ed')](_0x3a1aeb('0x211d')),_0x3b0da7['reject'](_0x2c89a3),angular[_0x3a1aeb('0x127')](_0x558381)&&angular['isFunction'](_0x558381)&&_0x558381(_0x2c89a3);});}return _0x3b0da7[_0x2be246('0x1883')];}};}const _0x57e289=_0x43c32c;var _0x95b3f0=_0x180212(0x985),_0x5d7238=_0x180212['n'](_0x95b3f0);_0x44fcd0['$inject']=[_0x189033('0x2063')];function _0x44fcd0(_0x1ced67){const _0x233eca=_0x189033,_0x146bee=new(_0x5d7238())(_0x1ced67[_0x233eca('0x8fc')][_0x233eca('0x1b00')]);let _0x28dcb4=null;const _0x5f5648={'exists':_0x51f9e1,'detectBrowser':_0xf1f9fd,'guidGenerator':_0x208ad2,'isMobile':_0x515dac,'toggleInArray':_0x213333,'firstLastDayMonth':_0x376ace};return _0x5f5648;function _0x51f9e1(_0x277ffa,_0x3cdef3){const _0x5788f5=_0x233eca;return _0x3cdef3[_0x5788f5('0x824')](_0x277ffa)>-0x1;}function _0xf1f9fd(){const _0xd07d51=_0x233eca;if(_0x28dcb4)return _0x28dcb4;const _0x3d9086=[{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0x1b00')],'subString':_0xd07d51('0x25f'),'versionSearch':'Edge','identity':_0xd07d51('0x25f')},{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0x1b00')],'subString':_0xd07d51('0x123'),'identity':'Chrome'},{'string':_0x1ced67[_0xd07d51('0x8fc')]['userAgent'],'subString':_0xd07d51('0x1b57'),'versionSearch':_0xd07d51('0x15bf'),'identity':_0xd07d51('0x1b57')},{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0xd4e')],'subString':'Apple','versionSearch':_0xd07d51('0x42d'),'identity':_0xd07d51('0x54')},{'prop':_0x1ced67[_0xd07d51('0x1336')],'identity':_0xd07d51('0x1344')},{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0xd4e')],'subString':_0xd07d51('0xd5b'),'identity':_0xd07d51('0xd5b')},{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0xd4e')],'subString':_0xd07d51('0x155e'),'identity':'Konqueror'},{'string':_0x1ced67['navigator']['userAgent'],'subString':'Firefox','identity':_0xd07d51('0x1b65')},{'string':_0x1ced67['navigator']['vendor'],'subString':_0xd07d51('0xbda'),'identity':'Camino'},{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0x1b00')],'subString':_0xd07d51('0xd12'),'identity':_0xd07d51('0xd12')},{'string':_0x1ced67[_0xd07d51('0x8fc')]['userAgent'],'subString':_0xd07d51('0x11c2'),'identity':_0xd07d51('0x1d4e'),'versionSearch':_0xd07d51('0x11c2')},{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0x1b00')],'subString':_0xd07d51('0x799'),'identity':_0xd07d51('0x1d4e'),'versionSearch':'rv'},{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0x1b00')],'subString':_0xd07d51('0x1527'),'identity':_0xd07d51('0x21eb'),'versionSearch':'rv'},{'string':_0x1ced67['navigator'][_0xd07d51('0x1b00')],'subString':'Mozilla','identity':_0xd07d51('0xd12'),'versionSearch':_0xd07d51('0x21eb')}],_0x543cf9=[{'string':_0x1ced67['navigator'][_0xd07d51('0x1d5')],'subString':'Win','identity':_0xd07d51('0x1116')},{'string':_0x1ced67[_0xd07d51('0x8fc')]['platform'],'subString':'Mac','identity':'Mac'},{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0x1d5')],'subString':_0xd07d51('0x176a'),'identity':_0xd07d51('0x176a')},{'string':_0x1ced67['navigator'][_0xd07d51('0x1d5')],'subString':_0xd07d51('0x14e2'),'identity':_0xd07d51('0x14e2')},{'string':_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0x1d5')],'subString':_0xd07d51('0x8a9'),'identity':_0xd07d51('0x8a9')},{'string':_0x1ced67[_0xd07d51('0x8fc')]['platform'],'subString':_0xd07d51('0x1f7d'),'identity':_0xd07d51('0x1f7d')},{'string':_0x1ced67[_0xd07d51('0x8fc')]['platform'],'subString':_0xd07d51('0x2058'),'identity':_0xd07d51('0x2058')}];let _0x398409='';function _0x3c79d1(_0x304af3){const _0x2856d4=_0xd07d51;for(let _0x3bc120=0x0;_0x3bc120<_0x304af3[_0x2856d4('0x1564')];_0x3bc120++){const _0xc074a9=_0x304af3[_0x3bc120][_0x2856d4('0xc06')],_0x4202c3=_0x304af3[_0x3bc120][_0x2856d4('0x245f')];_0x398409=_0x304af3[_0x3bc120]['versionSearch']||_0x304af3[_0x3bc120][_0x2856d4('0x1970')];if(_0xc074a9){if(_0xc074a9[_0x2856d4('0x824')](_0x304af3[_0x3bc120][_0x2856d4('0x2841')])!==-0x1)return _0x304af3[_0x3bc120][_0x2856d4('0x1970')];}else{if(_0x4202c3)return _0x304af3[_0x3bc120]['identity'];}}}function _0x38d7fc(_0x165995){const _0x42c1d7=_0xd07d51,_0x37153f=_0x165995[_0x42c1d7('0x824')](_0x398409);if(_0x37153f===-0x1)return;return parseInt(_0x165995['substring'](_0x37153f+_0x398409[_0x42c1d7('0x1564')]+0x1));}let _0x44ef89=_0x3c79d1(_0x3d9086)||_0xd07d51('0x1920'),_0x16f707=_0x38d7fc(_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0x1b00')])||_0x38d7fc(_0x1ced67[_0xd07d51('0x8fc')][_0xd07d51('0x160b')])||_0xd07d51('0x17e6'),_0x412b62=_0x3c79d1(_0x543cf9)||_0xd07d51('0x56e');return _0x44ef89=_0x44ef89[_0xd07d51('0x93a')](),_0x16f707=_0x44ef89+'-'+_0x16f707,_0x412b62=_0x412b62[_0xd07d51('0x93a')](),_0x28dcb4={'browser':_0x44ef89,'version':_0x16f707,'os':_0x412b62},_0x28dcb4;}function _0x208ad2(){const _0x521d49=function(){const _0x1972bf=a0_0x4e0a;return((0x1+Math[_0x1972bf('0x25c6')]())*0x10000||0x0)[_0x1972bf('0x1ff0')](0x10)[_0x1972bf('0x1735')](0x1);};return _0x521d49()+_0x521d49()+_0x521d49()+_0x521d49()+_0x521d49()+_0x521d49();}function _0x515dac(){const _0x445a90=_0x233eca;return _0x146bee[_0x445a90('0x200f')]();}function _0x213333(_0x4211a2,_0x53301f){const _0x5cc2b1=_0x233eca;_0x53301f[_0x5cc2b1('0x824')](_0x4211a2)===-0x1?_0x53301f[_0x5cc2b1('0x1fd0')](_0x4211a2):_0x53301f['splice'](_0x53301f[_0x5cc2b1('0x824')](_0x4211a2),0x1);}function _0x376ace(){const _0x12a7fc=_0x233eca;return{'$gte':_0x1aaf93()()[_0x12a7fc('0x1627')](_0x12a7fc('0x55b'))[_0x12a7fc('0xb11')](0x0,!![])[_0x12a7fc('0x26dd')](),'$lte':_0x1aaf93()()[_0x12a7fc('0x3b3')](_0x12a7fc('0x55b'))['utcOffset'](0x0,!![])[_0x12a7fc('0x26dd')]()};}}const _0x2a38e4=_0x44fcd0,_0x17e36e=_0x180212['p']+_0x189033('0xdf0');_0x5eda11[_0x189033('0x14be')]=[_0x189033('0x110c')],_0x12f633[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x1d7c')];function _0x12f633(_0x2f2ee6,_0x4df460){const _0x2d0ef0=_0x189033,_0x39903d=this;_0x39903d[_0x2d0ef0('0xdb5')]=_0x4df460['themes'],_0x39903d[_0x2d0ef0('0x1c16')]=[{'label':_0x2d0ef0('0xf99'),'value':_0x2d0ef0('0x797')},{'label':_0x2d0ef0('0x4ca'),'value':_0x2d0ef0('0x122c')}],_0x39903d[_0x2d0ef0('0x1ce5')]=[{'label':_0x2d0ef0('0x2518'),'value':_0x2d0ef0('0x1d2'),'figure':_0x2d0ef0('0xc97')},{'label':_0x2d0ef0('0xf21'),'value':_0x2d0ef0('0xafa'),'figure':_0x2d0ef0('0x1db6')},{'label':'Vertical\x20Navigation\x20with\x20Fullwidth\x20Toolbar\x202','value':_0x2d0ef0('0xc24'),'figure':_0x2d0ef0('0x205d')},{'label':_0x2d0ef0('0xcbe'),'value':_0x2d0ef0('0x22d9'),'figure':_0x2d0ef0('0x32')},{'label':_0x2d0ef0('0x1a8f'),'value':_0x2d0ef0('0xaf'),'figure':_0x2d0ef0('0x1e71')},{'label':_0x2d0ef0('0x1fa4'),'value':_0x2d0ef0('0x2429'),'figure':_0x2d0ef0('0xb59')}],_0x39903d[_0x2d0ef0('0x27c1')]=_0x2d0ef0('0x122c'),_0x39903d['layoutStyle']=_0x2f2ee6[_0x2d0ef0('0x1e6e')](_0x2d0ef0('0x2367'))||_0x2d0ef0('0x1d2'),_0x39903d[_0x2d0ef0('0xd86')]=_0x4fd74d,_0x39903d['getActiveTheme']=_0x5d0d92,_0x39903d[_0x2d0ef0('0xc49')]=_0x5cdcb0,_0x39903d[_0x2d0ef0('0xc4b')]=_0x2e1a2c;function _0x4fd74d(_0x91c6e9){_0x4df460['setActiveTheme'](_0x91c6e9);}function _0x5d0d92(){const _0x1ad746=_0x2d0ef0;return _0x4df460['themes'][_0x1ad746('0x357')];}function _0x5cdcb0(){const _0x3297b3=_0x2d0ef0,_0x29478c=angular['element'](_0x3297b3('0x18e5'));_0x29478c[_0x3297b3('0x7b8')]('boxed',_0x39903d[_0x3297b3('0x27c1')]===_0x3297b3('0x797'));}function _0x2e1a2c(){const _0x14a29e=_0x2d0ef0;_0x2f2ee6[_0x14a29e('0x137e')](_0x14a29e('0x2367'),_0x39903d[_0x14a29e('0x1086')]),location[_0x14a29e('0x40')]();}}function _0x5eda11(_0x463e30){const _0x1946dc=_0x189033;return{'restrict':'E','scope':{},'controller':_0x1946dc('0xc7f'),'templateUrl':_0x17e36e,'compile':function(_0x26ab7f){const _0x5b9cc0=_0x1946dc;return _0x26ab7f[_0x5b9cc0('0x81e')](_0x5b9cc0('0x12d4')),function _0x22d305(_0x5e4fcc){function _0x38d129(){const _0x13bf9b=a0_0x4e0a;_0x463e30(_0x13bf9b('0x504'))[_0x13bf9b('0x1b9a')]();}_0x5e4fcc['toggleOptionsSidenav']=_0x38d129;};}};}_0x58d69f['$inject']=[_0x189033('0x17e4'),_0x189033('0x24a8'),'motionTheming'];function _0x58d69f(_0x286e3a,_0xf0272,_0x516708){const _0x119afe={},_0x22a2c8={'generate':_0x4d801f,'rgba':_0x30d746};return _0x22a2c8;function _0x4d801f(){const _0x35c959=a0_0x4e0a,_0x4d8835=angular['copy'](_0x516708['getRegisteredThemes']()),_0x257ea8=angular[_0x35c959('0x1a86')](_0x516708[_0x35c959('0x1752')]());angular[_0x35c959('0x1299')](_0x4d8835,function(_0x80aa69){const _0x8bf438=_0x35c959;_0x119afe[_0x80aa69[_0x8bf438('0x60a')]]={},angular[_0x8bf438('0x1299')](_0x80aa69['colors'],function(_0x2c156c,_0x5fc52c){const _0x31bbda=_0x8bf438;_0x119afe[_0x80aa69[_0x31bbda('0x60a')]][_0x5fc52c]={'name':_0x2c156c[_0x31bbda('0x60a')],'levels':{'default':{'color':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c[_0x31bbda('0x5d')]['default']][_0x31bbda('0x1c6b')]),'contrast1':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c[_0x31bbda('0x5d')][_0x31bbda('0x9cb')]][_0x31bbda('0xcd3')],0x1),'contrast2':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c[_0x31bbda('0x5d')]['default']]['contrast'],0x2),'contrast3':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c['hues']['default']][_0x31bbda('0xcd3')],0x3),'contrast4':_0x30d746(_0x257ea8[_0x2c156c['name']][_0x2c156c[_0x31bbda('0x5d')][_0x31bbda('0x9cb')]]['contrast'],0x4)},'hue1':{'color':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c[_0x31bbda('0x5d')]['hue-1']][_0x31bbda('0x1c6b')]),'contrast1':_0x30d746(_0x257ea8[_0x2c156c['name']][_0x2c156c[_0x31bbda('0x5d')][_0x31bbda('0xd4c')]]['contrast'],0x1),'contrast2':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c['hues'][_0x31bbda('0xd4c')]][_0x31bbda('0xcd3')],0x2),'contrast3':_0x30d746(_0x257ea8[_0x2c156c['name']][_0x2c156c[_0x31bbda('0x5d')][_0x31bbda('0xd4c')]][_0x31bbda('0xcd3')],0x3),'contrast4':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c['hues'][_0x31bbda('0xd4c')]][_0x31bbda('0xcd3')],0x4)},'hue2':{'color':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c[_0x31bbda('0x5d')]['hue-2']]['value']),'contrast1':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c[_0x31bbda('0x5d')]['hue-2']][_0x31bbda('0xcd3')],0x1),'contrast2':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c['hues']['hue-2']][_0x31bbda('0xcd3')],0x2),'contrast3':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c[_0x31bbda('0x5d')][_0x31bbda('0x14dd')]]['contrast'],0x3),'contrast4':_0x30d746(_0x257ea8[_0x2c156c['name']][_0x2c156c[_0x31bbda('0x5d')][_0x31bbda('0x14dd')]][_0x31bbda('0xcd3')],0x4)},'hue3':{'color':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c['hues'][_0x31bbda('0x100d')]][_0x31bbda('0x1c6b')]),'contrast1':_0x30d746(_0x257ea8[_0x2c156c['name']][_0x2c156c[_0x31bbda('0x5d')][_0x31bbda('0x100d')]][_0x31bbda('0xcd3')],0x1),'contrast2':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c['hues'][_0x31bbda('0x100d')]]['contrast'],0x2),'contrast3':_0x30d746(_0x257ea8[_0x2c156c[_0x31bbda('0x60a')]][_0x2c156c[_0x31bbda('0x5d')][_0x31bbda('0x100d')]]['contrast'],0x3),'contrast4':_0x30d746(_0x257ea8[_0x2c156c['name']][_0x2c156c['hues']['hue-3']][_0x31bbda('0xcd3')],0x4)}}};});}),_0x18070c(_0x119afe);let _0x26b1b4={};angular[_0x35c959('0x1299')](_0x119afe,function(_0x5ea87d,_0x2fb63f){_0x26b1b4={},_0x26b1b4['@themeName']=_0x2fb63f,angular['forEach'](_0x5ea87d,function(_0x17b52f,_0x8c5689){const _0x27f03=a0_0x4e0a;angular[_0x27f03('0x1299')](_0x17b52f[_0x27f03('0x1d01')],function(_0x63b33d,_0x2bf18e){angular['forEach'](_0x63b33d,function(_0x1332a5,_0xea03ce){_0x26b1b4['@'+_0x8c5689+_0x5b08db(_0x2bf18e)+_0x5b08db(_0xea03ce)]=_0x1332a5;});});}),_0x517894(_0x26b1b4);});}function _0x18070c(_0x28581b){const _0x34b2ee=a0_0x4e0a,_0x3c7e54=angular[_0x34b2ee('0x1a86')](_0x28581b);angular[_0x34b2ee('0x1299')](_0x3c7e54,function(_0x1d44a1){const _0x3066cd=_0x34b2ee;angular[_0x3066cd('0x1299')](_0x1d44a1,function(_0x353549,_0x5c96e2){const _0xe8e264=_0x3066cd;_0x1d44a1[_0x5c96e2]=_0x353549['levels'],_0x1d44a1[_0x5c96e2][_0xe8e264('0x17f8')]=_0x353549[_0xe8e264('0x1d01')][_0xe8e264('0x9cb')]['color'],_0x1d44a1[_0x5c96e2]['contrast1']=_0x353549[_0xe8e264('0x1d01')][_0xe8e264('0x9cb')][_0xe8e264('0x1abd')],_0x1d44a1[_0x5c96e2][_0xe8e264('0x1f0c')]=_0x353549['levels'][_0xe8e264('0x9cb')][_0xe8e264('0x1f0c')],_0x1d44a1[_0x5c96e2][_0xe8e264('0x43c')]=_0x353549[_0xe8e264('0x1d01')]['default'][_0xe8e264('0x43c')],_0x1d44a1[_0x5c96e2]['contrast4']=_0x353549['levels'][_0xe8e264('0x9cb')][_0xe8e264('0x8a6')],delete _0x1d44a1[_0x5c96e2][_0xe8e264('0x9cb')];});}),_0x516708[_0x34b2ee('0x1e46')](_0x3c7e54);const _0x5691e1=_0x286e3a[_0x34b2ee('0x1e6e')](_0x34b2ee('0xa86'));_0x5691e1?_0x516708['setActiveTheme'](_0x5691e1):_0x516708[_0x34b2ee('0xd86')](_0x34b2ee('0x9cb'));}function _0x517894(_0x40496b){const _0x50fcfb=a0_0x4e0a,_0x1bff78=_0x50fcfb('0x257e'),_0x34a0b8=new RegExp(Object['keys'](_0x40496b)[_0x50fcfb('0x1630')]('|'),'gi'),_0x96f8a6=_0x1bff78[_0x50fcfb('0x1725')](_0x34a0b8,function(_0x3f97d0){return _0x40496b[_0x3f97d0];}),_0x219e81=angular[_0x50fcfb('0x1fcc')](_0x50fcfb('0xd39')),_0x250b07=angular['element'](_0x50fcfb('0x10da'));_0x250b07[_0x50fcfb('0x84')](_0x96f8a6),_0x219e81[_0x50fcfb('0x22d6')](_0x250b07);}function _0x30d746(_0x164fcf,_0x27004f){const _0x6b39a5=a0_0x4e0a,_0x4edce3=_0x27004f||![];_0x164fcf[_0x6b39a5('0x1564')]===0x4&&_0x164fcf[0x0]===0xff&&_0x164fcf[0x1]===0xff&&_0x164fcf[0x2]===0xff&&_0x164fcf['splice'](0x3,0x4);_0x4edce3&&(_0x164fcf=_0x84112a(_0x164fcf,_0x4edce3));if(_0x164fcf[_0x6b39a5('0x1564')]===0x3)return _0x6b39a5('0x940')+_0x164fcf['join'](',')+')';else{if(_0x164fcf['length']===0x4)return _0x6b39a5('0x25fe')+_0x164fcf['join'](',')+')';else _0xf0272['error'](_0x6b39a5('0x27a7')+_0x164fcf[_0x6b39a5('0x1564')]+'\x0a'+_0x6b39a5('0x108'));}}function _0x84112a(_0x447d98,_0x2de1ef){const _0x113a04=a0_0x4e0a,_0x3e31b2={'white':{0x1:'1',0x2:_0x113a04('0x1c3d'),0x3:_0x113a04('0x1ccc'),0x4:_0x113a04('0x13fe')},'black':{0x1:'0.87',0x2:_0x113a04('0x59b'),0x3:_0x113a04('0x115e'),0x4:_0x113a04('0x13fe')}};if(_0x447d98[0x0]===0xff&&_0x447d98[0x1]===0xff&&_0x447d98[0x2]===0xff)_0x447d98[0x3]=_0x3e31b2[_0x113a04('0x30')][_0x2de1ef];else _0x447d98[0x0]===0x0&&_0x447d98[0x1]===0x0&&_0x447d98[0x2]===0x0&&(_0x447d98[0x3]=_0x3e31b2[_0x113a04('0xeca')][_0x2de1ef]);return _0x447d98;}function _0x5b08db(_0x3db2f4){const _0x1e1b67=a0_0x4e0a;return _0x3db2f4['charAt'](0x0)[_0x1e1b67('0x80')]()+_0x3db2f4[_0x1e1b67('0x12c8')](0x1);}}const _0xc0ff65=_0x58d69f,_0x309d1a=[{'name':_0x189033('0x1a88'),'options':{0x32:_0x189033('0x57f'),0x64:'#c2d4ef',0xc8:'#9ab8e5',0x12c:_0x189033('0x2710'),0x190:_0x189033('0x24da'),0x1f4:_0x189033('0x17c6'),0x258:_0x189033('0x2861'),0x2bc:_0x189033('0x1b51'),0x320:_0x189033('0x341'),0x384:_0x189033('0xa16'),'A100':_0x189033('0x2246'),'A200':'#9ab8e5','A400':_0x189033('0x24da'),'A700':_0x189033('0x1b51'),'contrastDefaultColor':_0x189033('0x1ed2'),'contrastDarkColors':_0x189033('0x222'),'contrastStrongLightColors':'300\x20400'}},{'name':_0x189033('0x302'),'options':{0x32:_0x189033('0x17f3'),0x64:'#c5c6cb',0xc8:_0x189033('0x2212'),0x12c:'#7d818c',0x190:_0x189033('0x1b72'),0x1f4:_0x189033('0xd58'),0x258:_0x189033('0x809'),0x2bc:_0x189033('0x250'),0x320:'#262933',0x384:_0x189033('0x1c4e'),'A100':_0x189033('0x139a'),'A200':_0x189033('0x2212'),'A400':_0x189033('0x1b72'),'A700':'#2d323e','contrastDefaultColor':_0x189033('0x1ed2'),'contrastDarkColors':_0x189033('0x222'),'contrastStrongLightColors':_0x189033('0x397')}}],_0x18c7cd=_0x309d1a,_0x42a9cf={'default':{'primary':{'name':'motion-paleblue','hues':{'default':_0x189033('0x11c3'),'hue-1':'500','hue-2':_0x189033('0x563'),'hue-3':_0x189033('0x11e9')}},'accent':{'name':_0x189033('0x252e'),'hues':{'default':_0x189033('0x563'),'hue-1':_0x189033('0x11e9'),'hue-2':'700','hue-3':'A100'}},'warn':{'name':'red'},'background':{'name':_0x189033('0x1199'),'hues':{'default':_0x189033('0x151'),'hue-1':_0x189033('0x151'),'hue-2':_0x189033('0x3a5'),'hue-3':_0x189033('0x169')}}},'pinkTheme':{'primary':{'name':_0x189033('0x24eb'),'hues':{'default':_0x189033('0x14f7'),'hue-1':_0x189033('0x563'),'hue-2':'400','hue-3':_0x189033('0x151')}},'accent':{'name':_0x189033('0xbb2'),'hues':{'default':_0x189033('0x11e9'),'hue-1':_0x189033('0x169'),'hue-2':_0x189033('0x563'),'hue-3':_0x189033('0x151')}},'warn':{'name':_0x189033('0x1913')},'background':{'name':_0x189033('0x1199'),'hues':{'default':_0x189033('0x151'),'hue-1':_0x189033('0x151'),'hue-2':_0x189033('0x3a5'),'hue-3':_0x189033('0x169')}}},'tealTheme':{'primary':{'name':_0x189033('0x1a88'),'hues':{'default':_0x189033('0x8aa'),'hue-1':_0x189033('0x563'),'hue-2':'500','hue-3':_0x189033('0x151')}},'accent':{'name':'teal','hues':{'default':_0x189033('0x108a'),'hue-1':'400','hue-2':_0x189033('0x563'),'hue-3':_0x189033('0x151')}},'warn':{'name':_0x189033('0x110b')},'background':{'name':'grey','hues':{'default':_0x189033('0x151'),'hue-1':_0x189033('0x151'),'hue-2':_0x189033('0x3a5'),'hue-3':_0x189033('0x169')}}}},_0x146199=_0x42a9cf;_0x3940ed[_0x189033('0x14be')]=[_0x189033('0x2747'),_0x189033('0x2433'),_0x189033('0xb27')];function _0x3940ed(_0x32f014,_0x272999,_0x3b4068){const _0x1674d7=_0x189033;let _0x3a579a;angular[_0x1674d7('0xfc0')]([_0x1674d7('0x1d78')])[_0x1674d7('0x85')]([_0x1674d7('0x17e4'),function(_0x3b5c38){_0x3a579a=_0x3b5c38;}]);const _0x5a55a6=_0x3a579a[_0x1674d7('0x1626')](_0x1674d7('0x250c'));_0x5a55a6&&(_0x3b4068['custom']=_0x5a55a6),_0x32f014['alwaysWatchTheme'](!![]),angular[_0x1674d7('0x1299')](_0x272999,function(_0x50aad5){const _0x3e8bf3=_0x1674d7;_0x32f014['definePalette'](_0x50aad5[_0x3e8bf3('0x60a')],_0x50aad5[_0x3e8bf3('0x158e')]);}),angular[_0x1674d7('0x1299')](_0x3b4068,function(_0x5b8772,_0x506231){const _0x57028b=_0x1674d7;_0x32f014[_0x57028b('0x204b')](_0x506231)[_0x57028b('0xc5e')](_0x5b8772[_0x57028b('0x2472')]['name'],_0x5b8772[_0x57028b('0x2472')][_0x57028b('0x5d')])[_0x57028b('0xa9e')](_0x5b8772['accent'][_0x57028b('0x60a')],_0x5b8772['accent']['hues'])[_0x57028b('0x1f13')](_0x5b8772[_0x57028b('0x27b5')][_0x57028b('0x60a')],_0x5b8772[_0x57028b('0x27b5')]['hues'])[_0x57028b('0xce7')](_0x5b8772[_0x57028b('0x211b')][_0x57028b('0x60a')],_0x5b8772[_0x57028b('0x211b')][_0x57028b('0x5d')]);});}const _0x167502=_0x3940ed;_0x1bd1c8[_0x189033('0x14be')]=[_0x189033('0x17e4'),'$log',_0x189033('0x2561')];function _0x1bd1c8(_0xacd80,_0x516e9b,_0x5fad92){const _0x5f4170={'getRegisteredPalettes':_0x4be21d,'getRegisteredThemes':_0x34b02f,'setActiveTheme':_0xdbaf65,'setThemesList':_0x1fda43,'themes':{'list':{},'active':{'name':'','theme':{}}}};return _0x5f4170;function _0x4be21d(){const _0x5e3872=a0_0x4e0a;return _0x5fad92[_0x5e3872('0x1375')];}function _0x34b02f(){const _0x5dd8a7=a0_0x4e0a;return _0x5fad92[_0x5dd8a7('0x7d9')];}function _0xdbaf65(_0x3393db){const _0x12f770=a0_0x4e0a;if(angular[_0x12f770('0x105d')](_0x5f4170['themes']['list'][_0x3393db])){if(angular['isUndefined'](_0x5f4170[_0x12f770('0xdb5')][_0x12f770('0x2335')][_0x12f770('0x9cb')])){_0x516e9b['error'](_0x12f770('0x2866'));return;}_0x516e9b[_0x12f770('0x27b5')](_0x12f770('0x1a53')+_0x3393db+_0x12f770('0xb8f')),_0x5f4170[_0x12f770('0xdb5')][_0x12f770('0x357')][_0x12f770('0x60a')]=_0x12f770('0x9cb'),_0x5f4170[_0x12f770('0xdb5')][_0x12f770('0x357')][_0x12f770('0x204b')]=_0x5f4170[_0x12f770('0xdb5')][_0x12f770('0x2335')][_0x12f770('0x9cb')],_0xacd80['put'](_0x12f770('0xa86'),_0x5f4170[_0x12f770('0xdb5')][_0x12f770('0x357')]['name']);return;}_0x5f4170[_0x12f770('0xdb5')]['active'][_0x12f770('0x60a')]=_0x3393db,_0x5f4170[_0x12f770('0xdb5')][_0x12f770('0x357')]['theme']=_0x5f4170[_0x12f770('0xdb5')][_0x12f770('0x2335')][_0x3393db],_0xacd80[_0x12f770('0x137e')]('motion.selectedTheme',_0x3393db);}function _0x1fda43(_0x1a5515){const _0x230744=a0_0x4e0a;_0x5f4170[_0x230744('0xdb5')]['list']=_0x1a5515;}}const _0x17e940=_0x1bd1c8;;let _0x4f6410=angular[_0x189033('0x1e26')]('app.core',['ngAnimate','ngAria',_0x189033('0x1d78'),_0x189033('0xf86'),'ngResource',_0x189033('0x24af'),_0x189033('0x16b2'),_0x189033('0xc61'),'ui.router',_0x189033('0x3db'),_0x189033('0x78b'),'ds.clock',_0x189033('0x153c')])['provider'](_0x189033('0x59'),_0x4caaf1)[_0x189033('0x272d')](_0x5b355d)[_0x189033('0x11a0')](_0x5dc10b)['controller'](_0x189033('0x714'),_0x4d8714);_0x4f6410=_0x4bd6d3['reduce']((_0x5ebdb2,[_0x1c5558,_0x21af78,_0x185341])=>{const _0x2d616e=_0x189033;switch(_0x185341){case _0x2d616e('0x18ea'):_0x5ebdb2[_0x2d616e('0x18ea')](_0x1c5558,_0x21af78);break;case _0x2d616e('0x22fe'):_0x5ebdb2[_0x2d616e('0x22fe')](_0x1c5558,_0x21af78);break;case _0x2d616e('0x1da3'):_0x5ebdb2[_0x2d616e('0x1da3')](_0x1c5558,_0x21af78);break;case _0x2d616e('0x1f97'):_0x5ebdb2['factory'](_0x1c5558,_0x21af78);break;default:break;}return _0x5ebdb2;},_0x4f6410),_0x4f6410[_0x189033('0x1f97')](_0x189033('0x691'),_0x2a49f3)[_0x189033('0x25')](_0x189033('0x11b1'),_0x1f318f)[_0x189033('0x25')](_0x189033('0x152f'),_0x478ff7)[_0x189033('0x25')]('htmlToPlaintext',_0x170911)['filter'](_0x189033('0x10ba'),_0x389ba9)[_0x189033('0x25')]('humanizeDoc',_0x4807fb)[_0x189033('0x25')](_0x189033('0x21ab'),_0x34b9a2)[_0x189033('0x25')]('filterByIds',_0x31585e)[_0x189033('0x25')](_0x189033('0x8f4'),_0x11dba6)[_0x189033('0x25')](_0x189033('0xb5d'),_0x5165e5)[_0x189033('0x25')](_0x189033('0x1103'),_0x4c83c2)[_0x189033('0x25')]('filterByTags',_0x831367)[_0x189033('0x25')](_0x189033('0x9c0'),_0x3b246e)['provider'](_0x189033('0x1d41'),_0x399e97)[_0x189033('0x1f97')](_0x189033('0x4b1'),_0x5a38ec)[_0x189033('0x1f97')](_0x189033('0x2597'),_0xc40a0f)[_0x189033('0x22fe')](_0x189033('0x23dd'),_0x57e289)['factory']('msUtils',_0x2a38e4)[_0x189033('0x1da3')]('MsThemeOptionsController',_0x12f633)[_0x189033('0x18ea')](_0x189033('0x1965'),_0x5eda11)[_0x189033('0x1f97')]('motionGenerator',_0xc0ff65)[_0x189033('0xea')](_0x189033('0x2433'),_0x18c7cd)[_0x189033('0xea')]('motionThemes',_0x146199)['config'](_0x167502)[_0x189033('0x8c0')](_0x189033('0x1d7c'),_0x17e940),_0x59f728['$inject']=[_0x189033('0x7a5'),_0x189033('0x17e4'),_0x189033('0x260a'),_0x189033('0x1556'),'msNavigationService',_0x189033('0xba1'),_0x189033('0x56b')];function _0x59f728(_0xcad679,_0x1354fe,_0x3483d7,_0x49e9c8,_0x2cfd98,_0x54c3f8,_0x544ffc){const _0x27553f=_0x189033,_0x2abcbb=this;_0x2abcbb[_0x27553f('0x719')]=angular[_0x27553f('0x1fcc')](_0x27553f('0x18e5')),_0x2abcbb[_0x27553f('0x11b4')]={'suppressScrollX':!![]},_0x2abcbb[_0x27553f('0x260a')]=_0x3483d7,_0x2abcbb[_0x27553f('0x2713')]=_0x544ffc[_0x27553f('0x2713')],_0x2abcbb[_0x27553f('0x3a8')]=_0x474a3a,_0x2abcbb[_0x27553f('0x1643')]=_0x208ad4,_0x2abcbb[_0x27553f('0x20c0')]=_0x86cdfc,_0x49e9c8['on']('dashboard:save',_0x1975df),_0x49e9c8['on'](_0x27553f('0xe1a'),_0x1975df),_0x49e9c8['on'](_0x27553f('0x278a'),_0x3e161c),_0x49e9c8['on'](_0x27553f('0x2c4'),_0xe2cf78),_0x49e9c8['on'](_0x27553f('0xfb3'),_0xe2cf78),_0x49e9c8['on']('plugin:remove',_0xcaa84c);function _0x474a3a(){const _0x55baf5=_0x27553f;_0x2abcbb['folded']=_0x1354fe[_0x55baf5('0x1e6e')](_0x55baf5('0xcb4'))===_0x55baf5('0x26ac')||![];}function _0x208ad4(){const _0x453975=_0x27553f;_0x2abcbb[_0x453975('0x25df')]=!_0x2abcbb[_0x453975('0x25df')],_0x1354fe[_0x453975('0x137e')](_0x453975('0xcb4'),_0x2abcbb[_0x453975('0x25df')]);}function _0x86cdfc(){const _0x41a679=_0x27553f;return _0x2abcbb['setting'][_0x41a679('0x496')]?'xCALLY\x20Motion':_0x2abcbb[_0x41a679('0x260a')][_0x41a679('0x2570')];}function _0x1975df(_0x8c7c5){const _0x421c6d=_0x27553f;if(_0x8c7c5&&_0x8c7c5['id']){const _0x1dc16b=0x1869f+_0x8c7c5['id'];_0x2cfd98[_0x421c6d('0x2716')](_0x421c6d('0x1abc')+_0x1dc16b,{'id':_0x1dc16b,'title':_0x8c7c5[_0x421c6d('0x60a')]||_0x421c6d('0x2688'),'state':'app.dashboards.custom','stateParams':_0x8c7c5,'weight':0x2,'hidden':function(){const _0x351c47=_0x421c6d;return _0x54c3f8['hasRole'](_0x351c47('0x2327'))||!_0x54c3f8['hasPermission'](_0x1dc16b)&&!_0x54c3f8[_0x351c47('0xca1')](_0x351c47('0x20c2'));}});}}function _0x3e161c(_0x522a8a){const _0x23b090=_0x27553f;if(_0x522a8a&&_0x522a8a['id']){const _0x25e60c=0x1869f+_0x522a8a['id'];_0x2cfd98['deleteItem'](_0x23b090('0x1abc')+_0x25e60c);}}function _0xe2cf78(_0x319cfe){const _0x5d37ae=_0x27553f;if(_0x319cfe&&_0x319cfe['id']&&_0x319cfe['sidebar']!='never'){if(_0x319cfe[_0x5d37ae('0x357')]){if(_0x319cfe[_0x5d37ae('0x12f')]==_0x5d37ae('0x10af')||_0x319cfe[_0x5d37ae('0x12f')]==_0x5d37ae('0x2514')){_0x2cfd98[_0x5d37ae('0x2716')]('apps.plugins',{'id':0x76c,'title':_0x5d37ae('0x145b'),'translate':_0x5d37ae('0xd8f'),'icon':_0x5d37ae('0x7ee'),'weight':0x11,'hidden':function(){const _0x1522e2=_0x5d37ae;return _0x54c3f8['hasRole']('agent')||!_0x54c3f8[_0x1522e2('0x5e3')](0x76c)&&!_0x54c3f8['hasRole'](_0x1522e2('0x20c2'));}});const _0x17bdf2=0x15b38+_0x319cfe['id'];_0x2cfd98[_0x5d37ae('0x2716')](_0x5d37ae('0x497')+_0x17bdf2,{'id':_0x17bdf2,'title':_0x319cfe[_0x5d37ae('0x60a')]||_0x5d37ae('0x2688'),'state':_0x5d37ae('0x2394'),'stateParams':_0x319cfe,'weight':0x2,'hidden':function(){const _0x569ad4=_0x5d37ae;return _0x54c3f8[_0x569ad4('0xca1')](_0x569ad4('0x2327'))||!_0x54c3f8[_0x569ad4('0x5e3')](_0x17bdf2)&&!_0x54c3f8[_0x569ad4('0xca1')]('admin');}}),_0x2cfd98[_0x5d37ae('0x671')]();}}else{const _0x8e225d=0x15b38+_0x319cfe['id'];_0x5623ff(0x76c,_0x8e225d)&&(_0x319cfe[_0x5d37ae('0x12f')]==_0x5d37ae('0x10af')||_0x319cfe['sidebar']==_0x5d37ae('0x2514'))&&(_0x2cfd98[_0x5d37ae('0x6b8')]('apps.plugins.plugin_'+_0x8e225d),!_0x2ab101(0x76c)&&_0x2cfd98['saveItem'](_0x5d37ae('0x1fca'),{'id':0x76c,'title':'Plugins','translate':_0x5d37ae('0xd8f'),'icon':_0x5d37ae('0x7ee'),'weight':0x11,'hidden':function(){return!![];}}));}}}function _0xcaa84c(_0x531106){const _0x155b86=_0x27553f;if(_0x531106&&_0x531106['id']&&_0x531106[_0x155b86('0x12f')]!=_0x155b86('0x649')){const _0x391ef7=0x15b38+_0x531106['id'];(_0x531106[_0x155b86('0x12f')]==_0x155b86('0x10af')||_0x531106[_0x155b86('0x12f')]==_0x155b86('0x2514'))&&(_0x2cfd98[_0x155b86('0x6b8')](_0x155b86('0x497')+_0x391ef7),!_0x2ab101(0x76c)&&_0x2cfd98[_0x155b86('0x2716')](_0x155b86('0x1fca'),{'id':0x76c,'title':_0x155b86('0x145b'),'translate':_0x155b86('0xd8f'),'icon':'icon-apps','weight':0x11,'hidden':function(){return!![];}}));}}function _0x2ab101(_0x47a80d){const _0x215b5d=_0x27553f,_0x4c66e3=_0x2cfd98[_0x215b5d('0x2bc')](),_0x2604d3=_0x2e3ca0()[_0x215b5d('0x1c07')](_0x4c66e3[0x0]['children'],{'id':_0x47a80d});return _0x2604d3&&_0x2604d3[_0x215b5d('0x62')][_0x215b5d('0x1564')]>0x0?!![]:![];}function _0x5623ff(_0xbd65d7,_0x38ce0e){const _0x436b29=_0x27553f,_0x531dd6=_0x2cfd98[_0x436b29('0x2bc')](),_0x42a1a2=_0x2e3ca0()['find'](_0x531dd6[0x0][_0x436b29('0x62')],{'id':_0xbd65d7});if(!_0x42a1a2)return![];return _0x2e3ca0()[_0x436b29('0x7a2')](_0x42a1a2[_0x436b29('0x62')],{'id':_0x38ce0e});}_0xcad679[_0x27553f('0x26a2')](_0x27553f('0x1514'),function(){const _0x1a4d3d=_0x27553f;_0x2abcbb[_0x1a4d3d('0x719')][_0x1a4d3d('0x12a4')](_0x1a4d3d('0x193c'));});}const _0x2fa0bb=_0x59f728;;function _0x462015(){}angular['module'](_0x189033('0x6e2'),[])['config'](_0x462015)[_0x189033('0x1da3')]('NavigationController',_0x2fa0bb),_0x555e97[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1e48'),_0x189033('0xb33'),_0x189033('0x56b'),'user','setting',_0x189033('0x1302')];function _0x555e97(_0xc788ef,_0x17d07c,_0x316c22,_0x4ae0fc,_0x17115a,_0x1ffe75,_0x4fa9ad){const _0x3a3cad=_0x189033,_0x449e84=this;_0x449e84['errors']=[],_0x449e84['user']=_0x17115a,_0x449e84[_0x3a3cad('0x260a')]=_0x1ffe75,_0x449e84[_0x3a3cad('0x1302')]=_0x4fa9ad,_0x449e84[_0x3a3cad('0x19b2')]=_0x449e84[_0x3a3cad('0x260a')][_0x3a3cad('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x449e84[_0x3a3cad('0x1808')]=_0x2bbed3,_0x449e84[_0x3a3cad('0xf82')]=_0x2dcf4c,_0xc788ef[_0x3a3cad('0x186d')]('vm.password',function(_0x3899a7){const _0x1aa3f0=_0x3a3cad;!_0x2e3ca0()[_0x1aa3f0('0x8f2')](_0x449e84[_0x1aa3f0('0x17fb')])&&(_0x3899a7===_0x449e84[_0x1aa3f0('0x17fb')]?_0xc788ef[_0x1aa3f0('0x25cc')][_0x1aa3f0('0x1e96')][_0x1aa3f0('0x1c25')](_0x1aa3f0('0x20b9'),![]):_0xc788ef[_0x1aa3f0('0x25cc')]['password'][_0x1aa3f0('0x1c25')]('oldPasswordMatch',!![]));});function _0x2bbed3(){const _0x3f53db=_0x3a3cad;_0x449e84[_0x3f53db('0x17f')]=[],_0x4ae0fc[_0x3f53db('0xc96')]['changePassword']({'id':_0x449e84[_0x3f53db('0xc96')]['id']},{'oldPassword':_0x449e84[_0x3f53db('0x17fb')],'newPassword':_0x449e84['password']})[_0x3f53db('0xe53')]['then'](function(){const _0x36f291=_0x3f53db;_0x316c22[_0x36f291('0x1d4')](_0x316c22[_0x36f291('0x277d')]()[_0x36f291('0x1525')](_0x36f291('0xc02'))[_0x36f291('0x1233')](_0x36f291('0x10e4'))[_0x36f291('0x2490')](0x1388)),_0x2dcf4c();})[_0x3f53db('0x130a')](function(_0x1a60e2){const _0x448eb6=_0x3f53db;console[_0x448eb6('0x52a')](_0x1a60e2),_0x449e84[_0x448eb6('0x17f')]=_0x1a60e2['data'][_0x448eb6('0x17f')]&&_0x1a60e2['data']['errors'][_0x448eb6('0x1564')]?_0x1a60e2[_0x448eb6('0x5a5')]['errors']:[{'message':_0x1a60e2['data'][_0x448eb6('0x8c2')]||'Authorization\x20error','type':_0x448eb6('0x21c8')}];});}function _0x2dcf4c(){const _0x294267=_0x3a3cad;_0x17d07c[_0x294267('0x1715')]();}}const _0x125da4=_0x555e97;_0x35959f['$inject']=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'toasty',_0x189033('0x56b'),'preview',_0x189033('0xc4d')];function _0x35959f(_0x4f5d34,_0x2db0be,_0x521163,_0x266cdd,_0x5c4e41,_0x407f90,_0x280ba5,_0x3d4fdb){const _0x42da90=_0x189033,_0x161447=this;_0x161447[_0x42da90('0x575')]=_0x3d4fdb&&_0x3d4fdb['rows']?_0x2e3ca0()[_0x42da90('0x1cc9')](_0x2e3ca0()[_0x42da90('0x24db')](_0x3d4fdb['rows'],function(_0x34cfae){const _0x4925b0=_0x42da90;return _0x4925b0('0x1469')+_0x34cfae['id'];}),'name'):{},_0x161447[_0x42da90('0x17f')]=[],_0x161447[_0x42da90('0x1895')]=[],_0x161447[_0x42da90('0x5f9')]=_0x280ba5,_0x161447[_0x42da90('0x1a95')]=![],_0x161447['disable']=![],_0x161447[_0x42da90('0xf02')]=![],_0x161447[_0x42da90('0x1895')][_0x42da90('0x1fd0')](_0x161447[_0x42da90('0x5f9')]['id']),_0x161447[_0x42da90('0x288c')]=_0x380261,_0x161447[_0x42da90('0xf82')]=_0x1d4f11,_0x161447[_0x42da90('0xe59')]=_0x29da6e,_0x161447[_0x42da90('0x12a9')]=_0x26d895,_0x161447[_0x42da90('0x183')]=_0x1b709d,_0x161447[_0x42da90('0x1a0c')]=_0x394b50,_0x161447[_0x42da90('0x91f')]=_0x96ef53,_0x161447[_0x42da90('0x8f2')]=_0x22e9a2;function _0x22e9a2(_0x3e21d5){const _0x1b2846=_0x42da90;return _0x2e3ca0()[_0x1b2846('0x8f2')](_0x3e21d5);}function _0x394b50(_0x3e26ea){const _0x48e63=_0x42da90;return _0x2e3ca0()[_0x48e63('0x18ad')](_0x3e26ea,_0x48e63('0x1469'));}function _0x96ef53(_0x56d85a){const _0x36ac87=_0x42da90;return _0x2e3ca0()['includes'](['Company','CompanyId','ListId',_0x36ac87('0x10c5'),_0x36ac87('0x1a4'),_0x36ac87('0x1125'),'id',_0x36ac87('0xe1e'),_0x36ac87('0x1ff9'),'tags','updatedAt',_0x36ac87('0xf8a'),'twitter',_0x36ac87('0xaf4'),_0x36ac87('0x18d7'),_0x36ac87('0xff'),_0x36ac87('0x1824'),'line',_0x36ac87('0x2068')],_0x56d85a);}function _0x380261(){const _0x409783=_0x42da90;_0x161447[_0x409783('0x1a95')]=!![],_0x161447['disable']=!![],_0x2e3ca0()[_0x409783('0x173f')](_0x161447[_0x409783('0x5f9')])?(_0x5c4e41[_0x409783('0x52a')]({'title':'Message','msg':_0x409783('0x120f')}),_0x161447[_0x409783('0x287')]=![],_0x161447[_0x409783('0x1895')]=[],_0x1d4f11(!![])):_0x407f90['rpc'][_0x409783('0x1931')]({'id':_0x161447[_0x409783('0x5f9')]['id']})['$promise'][_0x409783('0x683')](function(){_0x1d4f11(!![]);})[_0x409783('0x130a')](function(_0x3b4b42){const _0x3c4726=_0x409783;_0x5c4e41[_0x3c4726('0x52a')]({'title':_0x3c4726('0x205e'),'msg':_0x3b4b42['data']}),_0x1d4f11(!![]);})[_0x409783('0x2874')](function(){const _0x102a74=_0x409783;_0x161447[_0x102a74('0x287')]=![],_0x161447['hopperIds']=[];});}function _0x1d4f11(_0x1f5f5b){const _0xeb4834=_0x42da90;_0x2e3ca0()[_0xeb4834('0x8f2')](_0x1f5f5b)&&_0x407f90[_0xeb4834('0x26cf')]['update']({'id':_0x161447['preview']['id'],'UserId':null}),_0x266cdd[_0xeb4834('0x1715')]();}_0x4f5d34[_0x42da90('0x26a2')](_0x42da90('0x4b8'),function(){const _0x51e8b3=_0x42da90;!_0x161447['originated']&&_0x407f90[_0x51e8b3('0x26cf')]['update']({'id':_0x161447[_0x51e8b3('0x5f9')]['id'],'UserId':null});});function _0x29da6e(){const _0x3ff664=_0x42da90;return _0x161447[_0x3ff664('0xf02')]=!![],_0x407f90[_0x3ff664('0x26cf')]['getPreview']({'hopperIds':_0x161447[_0x3ff664('0x1895')],'direction':_0x3ff664('0xdf7')})[_0x3ff664('0xe53')][_0x3ff664('0x683')](function(_0x25fdc4){const _0x133d75=_0x3ff664;_0x161447[_0x133d75('0xf02')]=![],!_0x2e3ca0()[_0x133d75('0x8f2')](_0x25fdc4)&&!_0x2e3ca0()[_0x133d75('0x8f2')](_0x25fdc4['Queue'])&&_0x25fdc4[_0x133d75('0x1fa')][_0x133d75('0x1455')]?(!_0x161447['originated']&&_0x407f90[_0x133d75('0x26cf')][_0x133d75('0x2480')]({'id':_0x161447[_0x133d75('0x5f9')]['id'],'UserId':null}),_0x161447[_0x133d75('0x5f9')]=_0x25fdc4,_0x161447[_0x133d75('0x1895')][_0x133d75('0x1fd0')](_0x161447[_0x133d75('0x5f9')]['id'])):(_0x161447['hopperIds']=[],_0x266cdd[_0x133d75('0x1715')](),_0x5c4e41[_0x133d75('0x2289')]({'title':_0x133d75('0x17bf'),'msg':'CAMPAIGN\x20NOT\x20ACTIVE'}));})['catch'](function(_0x5edde6){const _0x3923fc=_0x3ff664;_0x161447[_0x3923fc('0xf02')]=![],_0x161447['hopperIds']=[];if(_0x5edde6[_0x3923fc('0x13ee')]===0x194)_0x161447[_0x3923fc('0x183')]();else{if(_0x5edde6[_0x3923fc('0x5a5')]&&_0x5edde6['data']['errors']&&_0x5edde6[_0x3923fc('0x5a5')][_0x3923fc('0x17f')][_0x3923fc('0x1564')]){_0x266cdd['hide']();for(let _0x13a8ba=0x0;_0x13a8ba<_0x5edde6[_0x3923fc('0x5a5')][_0x3923fc('0x17f')][_0x3923fc('0x1564')];_0x13a8ba+=0x1){_0x5c4e41['error']({'title':_0x5edde6['data'][_0x3923fc('0x17f')][_0x13a8ba][_0x3923fc('0xcf0')],'msg':_0x5edde6[_0x3923fc('0x5a5')][_0x3923fc('0x17f')][_0x13a8ba][_0x3923fc('0x8c2')]});}}else _0x266cdd[_0x3923fc('0x1715')](),_0x5c4e41[_0x3923fc('0x52a')]({'title':_0x5edde6[_0x3923fc('0x13ee')]?_0x3923fc('0x2168')+_0x5edde6[_0x3923fc('0x13ee')]+'\x20-\x20'+_0x5edde6['statusText']:_0x3923fc('0x1542'),'msg':_0x5edde6[_0x3923fc('0x5a5')]?JSON['stringify'](_0x5edde6[_0x3923fc('0x5a5')]['message']):_0x5edde6[_0x3923fc('0x1ff0')]()});}});}function _0x26d895(){const _0x4eaddc=_0x42da90;_0x161447[_0x4eaddc('0xf02')]=!![];if(_0x161447[_0x4eaddc('0x1895')][_0x4eaddc('0x1564')]>0x1){const _0x5ac775=_0x2e3ca0()[_0x4eaddc('0x13db')](_0x161447[_0x4eaddc('0x1895')],_0x161447[_0x4eaddc('0x5f9')]['id']);return _0x407f90[_0x4eaddc('0x26cf')]['getPreview']({'hopperIds':_0x5ac775,'direction':_0x4eaddc('0x1ff3')})[_0x4eaddc('0xe53')][_0x4eaddc('0x683')](function(_0xebf0d){const _0x92738d=_0x4eaddc;_0x161447['disableGetContact']=![],!_0x2e3ca0()['isNil'](_0xebf0d)&&!_0x2e3ca0()[_0x92738d('0x8f2')](_0xebf0d[_0x92738d('0x1fa')])&&_0xebf0d['Queue']['dialActive']?(_0x2e3ca0()['remove'](_0x161447['hopperIds'],function(_0x148f63){const _0x379316=_0x92738d;return _0x148f63==_0x161447[_0x379316('0x5f9')]['id'];}),!_0x161447[_0x92738d('0x1a95')]&&_0x407f90[_0x92738d('0x26cf')][_0x92738d('0x2480')]({'id':_0x161447[_0x92738d('0x5f9')]['id'],'UserId':null}),_0x161447[_0x92738d('0x5f9')]=_0xebf0d):(_0x161447[_0x92738d('0x1895')]=[],_0x266cdd[_0x92738d('0x1715')](),_0x5c4e41[_0x92738d('0x2289')]({'title':_0x92738d('0x17bf'),'msg':_0x92738d('0x923')}));})[_0x4eaddc('0x130a')](function(_0xb7c8ef){const _0x1b2072=_0x4eaddc;if(_0xb7c8ef['status']===0x194)_0x161447['hopperIds']=[_0x161447[_0x1b2072('0x5f9')]['id']],_0x5c4e41[_0x1b2072('0x2289')]({'title':'PREVIEW','msg':_0x1b2072('0x26ec')});else{if(_0xb7c8ef[_0x1b2072('0x5a5')]&&_0xb7c8ef[_0x1b2072('0x5a5')][_0x1b2072('0x17f')]&&_0xb7c8ef['data'][_0x1b2072('0x17f')][_0x1b2072('0x1564')]){_0x161447['hopperIds']=[],_0x266cdd[_0x1b2072('0x1715')]();for(let _0x28e75a=0x0;_0x28e75a<_0xb7c8ef['data'][_0x1b2072('0x17f')][_0x1b2072('0x1564')];_0x28e75a+=0x1){_0x5c4e41[_0x1b2072('0x52a')]({'title':_0xb7c8ef[_0x1b2072('0x5a5')][_0x1b2072('0x17f')][_0x28e75a][_0x1b2072('0xcf0')],'msg':_0xb7c8ef[_0x1b2072('0x5a5')][_0x1b2072('0x17f')][_0x28e75a][_0x1b2072('0x8c2')]});}}else _0x161447['hopperIds']=[],_0x266cdd[_0x1b2072('0x1715')](),_0x5c4e41[_0x1b2072('0x52a')]({'title':_0xb7c8ef['status']?_0x1b2072('0x2168')+_0xb7c8ef[_0x1b2072('0x13ee')]+_0x1b2072('0xbf6')+_0xb7c8ef[_0x1b2072('0x24a9')]:'api\x20preview','msg':_0xb7c8ef[_0x1b2072('0x5a5')]?JSON['stringify'](_0xb7c8ef['data']['message']):_0xb7c8ef[_0x1b2072('0x1ff0')]()});}});}}function _0x1b709d(){const _0xa91baf=_0x42da90;return _0x161447[_0xa91baf('0xf02')]=!![],_0x5c4e41[_0xa91baf('0x2289')]({'title':_0xa91baf('0x17bf'),'msg':_0xa91baf('0x2086')}),_0x407f90[_0xa91baf('0x26cf')][_0xa91baf('0x2880')]({'hopperIds':[_0x161447[_0xa91baf('0x5f9')]['id']],'direction':_0xa91baf('0xdf7')})[_0xa91baf('0xe53')][_0xa91baf('0x683')](function(_0x2c06de){const _0x2e9d69=_0xa91baf;!_0x2e3ca0()[_0x2e9d69('0x8f2')](_0x2c06de)&&!_0x2e3ca0()['isNil'](_0x2c06de[_0x2e9d69('0x1fa')])&&_0x2c06de[_0x2e9d69('0x1fa')][_0x2e9d69('0x1455')]?(!_0x161447[_0x2e9d69('0x1a95')]&&_0x407f90[_0x2e9d69('0x26cf')][_0x2e9d69('0x2480')]({'id':_0x161447['preview']['id'],'UserId':null}),_0x161447['preview']=_0x2c06de,_0x161447['hopperIds'][_0x2e9d69('0x1fd0')](_0x161447[_0x2e9d69('0x5f9')]['id'])):(_0x266cdd[_0x2e9d69('0x1715')](),_0x5c4e41[_0x2e9d69('0x2289')]({'title':_0x2e9d69('0x17bf'),'msg':_0x2e9d69('0x923')}));})[_0xa91baf('0x130a')](function(_0x3a357f){const _0x2c6430=_0xa91baf;_0x266cdd[_0x2c6430('0x1715')]();if(_0x3a357f['status']===0x194)_0x5c4e41[_0x2c6430('0x2289')]({'title':_0x2c6430('0x17bf'),'msg':_0x2c6430('0x1c59')});else{if(_0x3a357f[_0x2c6430('0x5a5')]&&_0x3a357f[_0x2c6430('0x5a5')]['errors']&&_0x3a357f['data']['errors'][_0x2c6430('0x1564')])for(let _0x3b6574=0x0;_0x3b6574<_0x3a357f[_0x2c6430('0x5a5')][_0x2c6430('0x17f')][_0x2c6430('0x1564')];_0x3b6574+=0x1){_0x5c4e41['error']({'title':_0x3a357f[_0x2c6430('0x5a5')][_0x2c6430('0x17f')][_0x3b6574][_0x2c6430('0xcf0')],'msg':_0x3a357f[_0x2c6430('0x5a5')][_0x2c6430('0x17f')][_0x3b6574]['message']});}else _0x5c4e41['error']({'title':_0x3a357f[_0x2c6430('0x13ee')]?_0x2c6430('0x2168')+_0x3a357f[_0x2c6430('0x13ee')]+'\x20-\x20'+_0x3a357f['statusText']:_0x2c6430('0x1542'),'msg':_0x3a357f[_0x2c6430('0x5a5')]?JSON[_0x2c6430('0x258a')](_0x3a357f[_0x2c6430('0x5a5')][_0x2c6430('0x8c2')]):_0x3a357f[_0x2c6430('0x1ff0')]()});}})[_0xa91baf('0x2874')](function(){const _0x428653=_0xa91baf;_0x161447[_0x428653('0xf02')]=![];});}}const _0x2e6b06=_0x35959f,_0x4230ef=_0x180212['p']+'src/js/modules/toolbar/preview/dialog.html/dialog.html',_0x87bfef=_0x180212['p']+'src/js/modules/toolbar/changepassword/changepassword.html/changepassword.html';_0x224d9d[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1b'),'$q',_0x189033('0x938'),_0x189033('0x2f9'),'$location',_0x189033('0x110c'),_0x189033('0x1d08'),'$mdToast','$window','$mdDialog','$document',_0x189033('0x17e4'),'toasty','msNavigationService',_0x189033('0xba1'),_0x189033('0x1556'),'api',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1b27')];function _0x224d9d(_0x11c74f,_0x14520d,_0x4fde63,_0x5be1df,_0x568f84,_0x375be9,_0x236a4d,_0x4069a0,_0x583701,_0x2918ad,_0x586cec,_0x2edb34,_0x5f02d5,_0xa04340,_0x4e6d3c,_0x19728a,_0x29c455,_0x4d503d,_0x309fe9,_0x5c8367,_0x143d65){const _0x423168=_0x189033,_0x37959f=this;_0x37959f[_0x423168('0x426')]={},_0x37959f[_0x423168('0x416')]=!![],_0x37959f[_0x423168('0x2713')]=_0x4d503d[_0x423168('0x2713')];let _0x5ab3ff;_0x14520d['global']={'search':''},_0x37959f[_0x423168('0x22ab')]=[],_0x37959f[_0x423168('0xace')]=_0x309fe9,_0x37959f['currentUser']=_0x19728a['getCurrentUser'](),_0x37959f[_0x423168('0x1b29')]=0x0,_0x37959f[_0x423168('0x123f')]=0x0,_0x37959f[_0x423168('0x1743')]=0x0;_0x37959f[_0x423168('0x11ed')][_0x423168('0xecb')]===_0x423168('0x2327')&&(_0x5ab3ff=_0x143d65(_0x47717c,0x3a97));_0x37959f[_0x423168('0x260a')]=_0x5c8367,_0x37959f[_0x423168('0x719')]=angular['element'](_0x423168('0x18e5')),_0x37959f[_0x423168('0x1f4a')]={'realm':'asterisk','host':_0x375be9[_0x423168('0x19ac')](),'protocol':_0x375be9[_0x423168('0x173e')](),'remotePlayerId':_0x423168('0x9ac'),'ua':_0x423168('0x2663'),'license':_0x37959f[_0x423168('0xace')]['webrtc'],'phoneBarExpires':_0x37959f['currentUser'][_0x423168('0x2129')],'phoneBarPrefixRequired':_0x37959f[_0x423168('0x11ed')][_0x423168('0x2758')]},_0x37959f[_0x423168('0x23a2')]={'id':_0x19728a['getCurrentUser']()['id'],'fields':_0x423168('0xdb1'),'channel':'voice','nolimit':!![]},_0x37959f[_0x423168('0x156a')]=[{'title':_0x423168('0x2e4'),'icon':_0x423168('0x1240'),'color':_0x423168('0x160f')},{'title':_0x423168('0x338'),'icon':'icon-clock','color':_0x423168('0xc4f')},{'title':_0x423168('0x264a'),'icon':_0x423168('0x27f5'),'color':_0x423168('0x182')},{'title':_0x423168('0x7a8'),'icon':_0x423168('0x1d16'),'color':_0x423168('0xe94')},{'title':_0x423168('0x143d'),'icon':'icon-checkbox-blank-circle-outline','color':_0x423168('0x292')}],_0x37959f['languages']={'ar':{'title':_0x423168('0x205a'),'translation':_0x423168('0x2850'),'code':'ar','flag':'ar'},'da':{'title':'Danish','translation':'TOOLBAR.DANISH','code':'da','flag':'da'},'de':{'title':_0x423168('0x118e'),'translation':'TOOLBAR.GERMAN','code':'de','flag':'de'},'en':{'title':_0x423168('0xf48'),'translation':_0x423168('0x1f61'),'code':'en','flag':'us'},'es':{'title':'Spanish','translation':'TOOLBAR.SPANISH','code':'es','flag':'es'},'fa':{'title':_0x423168('0x6c3'),'translation':'TOOLBAR.PERSIAN','code':'fa','flag':'fa'},'fi':{'title':'Finnish','translation':'TOOLBAR.FINNISH','code':'fi','flag':'fi'},'fr':{'title':_0x423168('0x51a'),'translation':_0x423168('0xcd0'),'code':'fr','flag':'fr'},'he':{'title':'Hebrew','translation':_0x423168('0xd35'),'code':'he','flag':'he'},'hi':{'title':_0x423168('0x81c'),'translation':_0x423168('0xa62'),'code':'hi','flag':'hi'},'id':{'title':_0x423168('0x9ec'),'translation':'TOOLBAR.INDONESIAN','code':'id','flag':'id'},'it':{'title':_0x423168('0x2217'),'translation':_0x423168('0xd6'),'code':'it','flag':'it'},'ja':{'title':_0x423168('0x1abb'),'translation':_0x423168('0x257c'),'code':'ja','flag':'ja'},'ko':{'title':_0x423168('0x233a'),'translation':'TOOLBAR.KOREAN','code':'ko','flag':'ko'},'lv':{'title':'Latvian','translation':'TOOLBAR.LATVIAN','code':'lv','flag':'lv'},'nl':{'title':_0x423168('0xe03'),'translation':_0x423168('0x1f81'),'code':'nl','flag':'nl'},'no':{'title':_0x423168('0x1e53'),'translation':'TOOLBAR.NORWEGIAN','code':'no','flag':'no'},'pl':{'title':_0x423168('0x10a7'),'translation':_0x423168('0x2863'),'code':'pl','flag':'pl'},'pt-BR':{'title':_0x423168('0x35d'),'translation':'TOOLBAR.BRAZILIAN','code':_0x423168('0x56c'),'flag':_0x423168('0x56c')},'pt-PT':{'title':_0x423168('0x323'),'translation':'TOOLBAR.PORTUGUESE','code':_0x423168('0xa21'),'flag':_0x423168('0xa21')},'ru':{'title':_0x423168('0x103e'),'translation':_0x423168('0x22fd'),'code':'ru','flag':'ru'},'sv':{'title':'Swedish','translation':_0x423168('0x27c2'),'code':'sv','flag':'sv'},'tr':{'title':_0x423168('0x17b0'),'translation':_0x423168('0x158d'),'code':'tr','flag':'tr'},'zh-CN':{'title':'ChineseSimplified','translation':_0x423168('0x2588'),'code':_0x423168('0x175d'),'flag':_0x423168('0x175d')},'zh-TW':{'title':_0x423168('0x2538'),'translation':_0x423168('0x1056'),'code':_0x423168('0x26bd'),'flag':_0x423168('0x26bd')}};const _0x3bfea9=['ar','fa','he'];_0x37959f[_0x423168('0x2704')]=_0x576316,_0x37959f['logout']=_0x1336b4,_0x37959f[_0x423168('0xa50')]=_0x4d4ab7,_0x37959f[_0x423168('0x2824')]=_0x2aa36a,_0x37959f[_0x423168('0xa83')]=_0x2f8b8e,_0x37959f[_0x423168('0x1643')]=_0x2c98cb,_0x37959f[_0x423168('0x19a4')]=_0x46b591,_0x37959f[_0x423168('0x9f4')]=_0x484808,_0x37959f[_0x423168('0x10ca')]=_0x34eb1e,_0x37959f[_0x423168('0x2193')]=_0x9184ef,_0x37959f['isAgent']=_0x47b360,_0x37959f[_0x423168('0x19de')]=_0x353a04,_0x37959f[_0x423168('0x1ac4')]=_0x36b354,_0x37959f[_0x423168('0xa4')]=_0x2f4307,_0x37959f[_0x423168('0x1778')]=_0x3bd799,_0x37959f[_0x423168('0x5f9')]=_0x40bcec,_0x37959f[_0x423168('0x20c0')]=_0x2f7506,_0x37959f[_0x423168('0x12ca')]=_0x55c30d,_0x37959f[_0x423168('0x24b8')]=_0x9938,_0x37959f[_0x423168('0x15da')]=_0x56e72c,_0x37959f['onUserVoiceQueue']=_0x541170,_0x37959f[_0x423168('0x5a')]=_0x462029,_0x4e96d3(),_0x5fafdb(),_0x5ee9e6();function _0x4e96d3(){const _0x1e1113=_0x423168;_0x37959f['user']=_0x19728a[_0x1e1113('0x20b2')](),_0x37959f[_0x1e1113('0x1f4a')][_0x1e1113('0x709')]=_0x37959f['user'][_0x1e1113('0x1f4e')],_0x37959f['conf']['id']=_0x37959f[_0x1e1113('0xc96')]['id'],_0x37959f[_0x1e1113('0x1f4a')]['name']=_0x37959f[_0x1e1113('0xc96')][_0x1e1113('0x60a')],_0x37959f[_0x1e1113('0x1f4a')][_0x1e1113('0x11bc')]=_0x37959f[_0x1e1113('0xc96')][_0x1e1113('0x11bc')],_0x37959f[_0x1e1113('0x1f4a')][_0x1e1113('0x1d43')]=_0x37959f[_0x1e1113('0xc96')][_0x1e1113('0x1d43')],_0x37959f[_0x1e1113('0x1f4a')]['recording']=_0x37959f[_0x1e1113('0xc96')][_0x1e1113('0x2329')],_0x37959f[_0x1e1113('0x1f4a')]['autoAnswer']=_0x37959f['user']['phoneBarAutoAnswer'],_0x37959f[_0x1e1113('0x1f4a')][_0x1e1113('0x27eb')]=_0x37959f['user'][_0x1e1113('0xe13')],_0x37959f[_0x1e1113('0x1f4a')][_0x1e1113('0xaf0')]=_0x37959f[_0x1e1113('0xc96')]['phoneBarEnableDtmfTone'],_0x37959f['conf'][_0x1e1113('0x17e5')]=_0x37959f[_0x1e1113('0xc96')][_0x1e1113('0x2757')],_0x37959f['userStatus']=_0x37959f[_0x1e1113('0x156a')][0x0];const _0x3e5de9=_0x5f02d5[_0x1e1113('0x1e6e')](_0x1e1113('0x2772'));_0x3e5de9&&typeof _0x37959f[_0x1e1113('0xb95')][_0x3e5de9]!==_0x1e1113('0x1867')?_0x37959f[_0x1e1113('0x64e')]=_0x37959f[_0x1e1113('0xb95')][_0x3e5de9]:_0x37959f[_0x1e1113('0x64e')]=_0x37959f[_0x1e1113('0xb95')][_0x4069a0['preferredLanguage']()];_0x4d503d[_0x1e1113('0xa4')][_0x1e1113('0x1e6e')]({'fields':_0x1e1113('0x60a'),'nolimit':!![]})[_0x1e1113('0xe53')]['then'](function(_0x298322){const _0x133086=_0x1e1113;_0x37959f[_0x133086('0x22ab')]=_0x298322[_0x133086('0xf5d')]?_0x298322['rows']:[];})[_0x1e1113('0x130a')](function(_0x163c5e){const _0x15a2f0=_0x1e1113;_0xa04340[_0x15a2f0('0x52a')]({'title':_0x163c5e[_0x15a2f0('0x13ee')]?_0x15a2f0('0x2168')+_0x163c5e[_0x15a2f0('0x13ee')]+_0x15a2f0('0xbf6')+_0x163c5e[_0x15a2f0('0x24a9')]:_0x15a2f0('0x192d'),'msg':_0x163c5e[_0x15a2f0('0x13ee')]?JSON[_0x15a2f0('0x258a')](_0x163c5e[_0x15a2f0('0x5a5')]):_0x163c5e[_0x15a2f0('0x1ff0')]()});});if(_0x19728a[_0x1e1113('0x1c42')]()==_0x1e1113('0x1b4d')){if(_0x37959f['setting'][_0x1e1113('0x1cc3')]){if(!_0x37959f[_0x1e1113('0xc96')][_0x1e1113('0x733')])_0x9184ef(null,!![]);else{const _0x54f2cd=_0x1aaf93()(_0x37959f[_0x1e1113('0xc96')][_0x1e1113('0x733')])['add'](_0x37959f[_0x1e1113('0x260a')][_0x1e1113('0xe0b')]||0x5a,_0x1e1113('0x1efa'));if(_0x1aaf93()()['isAfter'](_0x54f2cd))_0x9184ef(null,!![]);else _0x1aaf93()()[_0x1e1113('0x23c6')](0xf,_0x1e1113('0x1efa'))[_0x1e1113('0x2746')](_0x54f2cd)&&_0xa04340[_0x1e1113('0xd33')]({'title':_0x4069a0['instant'](_0x1e1113('0x238f'))+'!','msg':_0x4069a0[_0x1e1113('0x2728')](_0x1e1113('0x1211'))+':\x20'+Math[_0x1e1113('0x15c3')](_0x54f2cd[_0x1e1113('0x2357')](_0x1aaf93()(),_0x1e1113('0x1044'),!![])),'timeout':0x4e20});}}}}function _0x5ee9e6(){const _0x58b77c=_0x423168;_0x29c455[_0x58b77c('0x12ac')](),_0x29c455['on'](_0x58b77c('0x2719'),_0x37959f[_0x58b77c('0x19de')]),_0x29c455['on'](_0x58b77c('0xfa5'),_0x37959f[_0x58b77c('0x1ac4')]),_0x29c455['on'](_0x58b77c('0x1812'),_0x37959f[_0x58b77c('0x24b8')]),_0x29c455['on'](_0x58b77c('0x221f'),_0x37959f['onInternalMessageUpdate']),_0x29c455['on'](_0x58b77c('0x217c'),_0x37959f[_0x58b77c('0x1366')]),_0x29c455['on'](_0x58b77c('0x240f'),_0x37959f[_0x58b77c('0x5a')]),_0x29c455['on'](_0x58b77c('0x56f'),_0x37959f[_0x58b77c('0x1366')]),_0x29c455['on'](_0x58b77c('0xfb0'),_0x37959f[_0x58b77c('0x5a')]),_0x29c455['on'](_0x58b77c('0x779'),_0x37959f['onVoiceQueue']),_0x29c455['on'](_0x58b77c('0x44d'),_0x47d8f3),_0x29c455['on'](_0x58b77c('0xbf9'),_0x228607);}function _0x6b8b2b(){const _0x1a53ff=_0x423168;_0x29c455[_0x1a53ff('0x1b9e')](_0x1a53ff('0xfa5')),_0x29c455[_0x1a53ff('0x1b9e')](_0x1a53ff('0x2719')),_0x29c455[_0x1a53ff('0x1b9e')](_0x1a53ff('0x1812')),_0x29c455[_0x1a53ff('0x1b9e')](_0x1a53ff('0x221f')),_0x29c455[_0x1a53ff('0x1b9e')]('userVoiceQueue:save'),_0x29c455[_0x1a53ff('0x1b9e')](_0x1a53ff('0x240f')),_0x29c455[_0x1a53ff('0x1b9e')]('userVoiceQueue:remove'),_0x29c455[_0x1a53ff('0x1b9e')](_0x1a53ff('0xfb0')),_0x29c455[_0x1a53ff('0x1b9e')]('voiceQueue:update'),_0x29c455[_0x1a53ff('0x1b9e')]('user:forcelogout'),_0x29c455['removeAllListeners'](_0x1a53ff('0xbf9')),_0x29c455[_0x1a53ff('0x1346')]();}function _0x13f342(_0xe7ee49){const _0x2a2895=_0x423168;_0x37959f['voiceQueues']=_0xe7ee49?_0x2e3ca0()[_0x2a2895('0x24db')](_0xe7ee49['rows']?_0xe7ee49[_0x2a2895('0xf5d')]:[],'id'):{};}function _0x5fafdb(){const _0x3a3c4e=_0x423168;_0x37959f['promise']=_0x4d503d[_0x3a3c4e('0xc96')][_0x3a3c4e('0x4c9')](_0x37959f[_0x3a3c4e('0x23a2')],_0x13f342)['$promise'];}function _0x462029(){_0x5fafdb();}function _0x541170(_0xbf0730){const _0x164727=_0x423168;_0x2e3ca0()[_0x164727('0xc77')](_0xbf0730['UserId'])===_0x19728a['getCurrentUser']()['id']&&_0x5fafdb();}function _0x2f4307(_0x5f47ab){const _0x341e20=_0x423168;return _0x4d503d['user'][_0x341e20('0xa4')]({'id':_0x37959f['user']['id'],'type':_0x5f47ab||_0x341e20('0x55')})['$promise'][_0x341e20('0x130a')](function(_0xa87d5d){const _0x478b82=_0x341e20;_0xa04340[_0x478b82('0x52a')]({'title':_0xa87d5d['status']?_0x478b82('0x2168')+_0xa87d5d[_0x478b82('0x13ee')]+'\x20-\x20'+_0xa87d5d['statusText']:_0x478b82('0x2f6'),'msg':_0xa87d5d['status']?JSON[_0x478b82('0x258a')](_0xa87d5d[_0x478b82('0x5a5')]):_0xa87d5d['toString']()});});}function _0x3bd799(){const _0xf9e6cd=_0x423168;return _0x4d503d[_0xf9e6cd('0xc96')][_0xf9e6cd('0x1778')]({'id':_0x37959f['user']['id']})[_0xf9e6cd('0xe53')][_0xf9e6cd('0x130a')](function(_0x30f879){const _0x411644=_0xf9e6cd;_0xa04340[_0x411644('0x52a')]({'title':_0x30f879[_0x411644('0x13ee')]?'API:'+_0x30f879['status']+'\x20-\x20'+_0x30f879[_0x411644('0x24a9')]:_0x411644('0x1066'),'msg':_0x30f879[_0x411644('0x13ee')]?JSON['stringify'](_0x30f879[_0x411644('0x5a5')]):_0x30f879[_0x411644('0x1ff0')]()});});}function _0x40bcec(_0xa7e486){const _0xe4ebe9=_0x423168;return _0x37959f[_0xe4ebe9('0x287')]=!![],_0x4d503d[_0xe4ebe9('0x26cf')][_0xe4ebe9('0x2880')]()[_0xe4ebe9('0xe53')]['then'](function(_0x4656f8){const _0x129eb6=_0xe4ebe9;!_0x2e3ca0()[_0x129eb6('0x8f2')](_0x4656f8)&&!_0x2e3ca0()['isNil'](_0x4656f8['Queue'])&&_0x4656f8['Queue']['dialActive']?_0x586cec[_0x129eb6('0x1d4')]({'controller':'PreviewDialogController','controllerAs':'vm','templateUrl':_0x4230ef,'parent':angular[_0x129eb6('0x1fcc')](_0x2edb34[_0x129eb6('0x18e5')]),'targetEvent':_0xa7e486,'clickOutsideToClose':!![],'locals':{'preview':_0x4656f8},'resolve':{'customFields':[_0x129eb6('0x4b1'),function(_0x39111b){const _0x4788d1=_0x129eb6;return _0x39111b[_0x4788d1('0xed7')](_0x4788d1('0x1ca0'),{'nolimit':!![]});}]}}):_0xa04340['info']({'title':'PREVIEW','msg':_0x129eb6('0x923')});})[_0xe4ebe9('0x130a')](function(_0x791441){const _0x339bf0=_0xe4ebe9;if(_0x791441[_0x339bf0('0x13ee')]===0x194)_0xa04340[_0x339bf0('0x2289')]({'title':'PREVIEW','msg':_0x339bf0('0x761')});else{if(_0x791441[_0x339bf0('0x5a5')]&&_0x791441[_0x339bf0('0x5a5')][_0x339bf0('0x17f')]&&_0x791441[_0x339bf0('0x5a5')]['errors'][_0x339bf0('0x1564')]){_0x37959f[_0x339bf0('0x17f')]=_0x791441[_0x339bf0('0x5a5')][_0x339bf0('0x17f')]||[{'message':_0x791441[_0x339bf0('0x1ff0')](),'type':_0x339bf0('0x1bc4')}];for(let _0x40e992=0x0;_0x40e992<_0x791441[_0x339bf0('0x5a5')][_0x339bf0('0x17f')][_0x339bf0('0x1564')];_0x40e992+=0x1){_0xa04340[_0x339bf0('0x52a')]({'title':_0x791441[_0x339bf0('0x5a5')][_0x339bf0('0x17f')][_0x40e992][_0x339bf0('0xcf0')],'msg':_0x791441[_0x339bf0('0x5a5')][_0x339bf0('0x17f')][_0x40e992][_0x339bf0('0x8c2')]});}}else _0xa04340[_0x339bf0('0x52a')]({'title':_0x791441[_0x339bf0('0x13ee')]?_0x339bf0('0x2168')+_0x791441[_0x339bf0('0x13ee')]+_0x339bf0('0xbf6')+_0x791441[_0x339bf0('0x24a9')]:'api.openchannelMessage.accept','msg':_0x791441[_0x339bf0('0x5a5')]?JSON[_0x339bf0('0x258a')](_0x791441[_0x339bf0('0x5a5')][_0x339bf0('0x8c2')]):_0x791441['toString']()});}})[_0xe4ebe9('0x2874')](function(){const _0xd5a985=_0xe4ebe9;_0x37959f[_0xd5a985('0x287')]=![];});}function _0x576316(_0x3d873a){const _0x13123f=_0x423168;_0x236a4d(_0x3d873a)[_0x13123f('0x1b9a')]();}function _0x55c30d(){const _0x3c9b13=_0x423168;return _0x37959f['currentUser'][_0x3c9b13('0xecb')]==='admin'||_0x37959f['currentUser'][_0x3c9b13('0xecb')]===_0x3c9b13('0xc96')||_0x37959f[_0x3c9b13('0x11ed')]['role']===_0x3c9b13('0x2327')&&_0x37959f[_0x3c9b13('0x11ed')][_0x3c9b13('0xf8e')]!==0x0;}_0x4d503d[_0x423168('0x1a73')][_0x423168('0x1e6e')]({'fields':_0x423168('0x1fe1'),'ToId':_0x37959f['currentUser']['id'],'read':![],'nolimit':!![]})['$promise'][_0x423168('0x683')](function(_0x3af4cf){const _0x17a8ef=_0x423168;_0x37959f[_0x17a8ef('0x1b29')]=_0x3af4cf['rows']['length'];});function _0x9938(_0x4073aa){const _0xd58ade=_0x423168;_0x4073aa[_0xd58ade('0x20e6')]===_0x37959f['currentUser']['id']&&!_0x4073aa[_0xd58ade('0x1691')]&&(_0x37959f[_0xd58ade('0x1b29')]+=0x1),_0x4073aa['ToId']===_0x37959f[_0xd58ade('0x11ed')]['id']&&_0x4073aa[_0xd58ade('0x1fe1')]!==_0x37959f[_0xd58ade('0x11ed')]['id']&&!_0x4073aa[_0xd58ade('0x20db')]&&_0x4073aa['ChatGroupId']&&_0x37959f[_0xd58ade('0x123f')]++;}function _0x56e72c(_0x75f17f){const _0x4c72ea=_0x423168;_0x75f17f[_0x4c72ea('0x20e6')]===_0x37959f[_0x4c72ea('0x11ed')]['id']&&_0x75f17f[_0x4c72ea('0x20db')]&&_0x37959f[_0x4c72ea('0x1b29')]>0x0&&!_0x75f17f[_0x4c72ea('0x1691')]&&(_0x37959f['unreadTotalMessages']-=0x1),_0x75f17f['ToId']===_0x37959f[_0x4c72ea('0x11ed')]['id']&&_0x75f17f[_0x4c72ea('0x20db')]&&_0x75f17f['ChatGroupId']&&_0x37959f[_0x4c72ea('0x123f')]>0x0&&_0x37959f['unreadTotalGroupMessages']--;}function _0x2aa36a(_0xf6abea){const _0x4ce2e3=_0x423168;_0x37959f[_0x4ce2e3('0x1fb6')]=_0xf6abea;}function _0x1336b4(_0x38b68b){const _0x20bfc0=_0x423168;return _0x6b8b2b(),_0x19728a[_0x20bfc0('0x1999')](_0x38b68b)[_0x20bfc0('0x683')](function(){const _0x48c9fb=_0x20bfc0;return _0x14520d[_0x48c9fb('0x5ed')](_0x48c9fb('0x1ff7')),_0x5be1df['go'](_0x48c9fb('0x8a0'));})[_0x20bfc0('0x130a')](function(_0x388326){const _0x15549a=_0x20bfc0;console[_0x15549a('0x52a')](_0x388326);});}function _0x4d4ab7(_0x479569){const _0x3b5e8d=_0x423168;if(typeof _0x37959f[_0x3b5e8d('0xb95')][_0x479569[_0x3b5e8d('0x1245')]]==_0x3b5e8d('0x1867')){const _0x2c5543=_0x3b5e8d('0xf52');_0x583701['show']({'template':''+_0x2c5543+_0x3b5e8d('0xbcf'),'hideDelay':0x1b58,'position':_0x3b5e8d('0x10e4'),'parent':_0x3b5e8d('0x197d')});return;}_0x37959f[_0x3b5e8d('0x64e')]=_0x479569,_0x5f02d5[_0x3b5e8d('0x137e')](_0x3b5e8d('0x2772'),_0x479569[_0x3b5e8d('0x1245')]),_0x4069a0[_0x3b5e8d('0x2775')](_0x479569[_0x3b5e8d('0x1245')]),_0x5be1df[_0x3b5e8d('0xb24')][_0x3b5e8d('0x60a')]===_0x3b5e8d('0x1c81')&&_0x2918ad[_0x3b5e8d('0x1224')]['reload'](),_0x3bfea9[_0x3b5e8d('0x824')](_0x479569[_0x3b5e8d('0x1245')])>=0x0?_0xa04340[_0x3b5e8d('0x2289')]({'title':_0x4069a0['instant'](_0x3b5e8d('0x1c37')),'msg':_0x4069a0[_0x3b5e8d('0x2728')]('TOOLBAR.CHANGE_LANGUAGE_MESSAGE')}):_0x11c74f[_0x3b5e8d('0x1cd5')][_0x3b5e8d('0x1cd5')]['vm']['direction']='ltr';}function _0x2f8b8e(){_0x37959f['bodyEl']['toggleClass']('ms-navigation-horizontal-mobile-menu-active');}function _0x2c98cb(){const _0x57c820=_0x423168;_0x4e6d3c[_0x57c820('0x20a8')]();}function _0x46b591(_0x24dbf3){const _0x11eb1f=_0x423168;let _0x1808b4=[];const _0x4e5678=_0x4e6d3c[_0x11eb1f('0x14bd')](),_0x540ad8=_0x4fde63[_0x11eb1f('0x448')]();for(let _0x18743d=0x0;_0x18743d<_0x4e5678[_0x11eb1f('0x1564')];_0x18743d++){_0x4e5678[_0x18743d][_0x11eb1f('0x171')]&&_0x1808b4[_0x11eb1f('0x1fd0')](_0x4e5678[_0x18743d]);}return _0x24dbf3&&(_0x1808b4=_0x1808b4[_0x11eb1f('0x25')](function(_0x198731){const _0x56ff44=_0x11eb1f;if(_0x198731[_0x56ff44('0xf28')][_0x56ff44('0x93a')]()[_0x56ff44('0x2292')](_0x24dbf3[_0x56ff44('0x93a')]()))return!![];})),_0x568f84(function(){const _0x1c8d3=_0x11eb1f;_0x540ad8[_0x1c8d3('0xed7')](_0x1808b4);},0x3e8),_0x540ad8[_0x11eb1f('0x1883')];}function _0x484808(_0x1a8eb9){const _0x23701a=_0x423168;_0x1a8eb9[_0x23701a('0x171')]&&(_0x1a8eb9[_0x23701a('0x230a')]?_0x5be1df['go'](_0x1a8eb9[_0x23701a('0x2598')],_0x1a8eb9['stateParams']):_0x5be1df['go'](_0x1a8eb9[_0x23701a('0x2598')]));}function _0x34eb1e(){const _0x1c4d2e=_0x423168;_0x14520d[_0x1c4d2e('0x5ed')]('webrtc::settings');}function _0x9184ef(_0x229052,_0x3c002a){const _0x2b7e16=_0x423168;_0x586cec[_0x2b7e16('0x1d4')]({'controller':_0x2b7e16('0x14d2'),'controllerAs':'vm','templateUrl':_0x87bfef,'parent':angular['element'](_0x2edb34[_0x2b7e16('0x18e5')]),'targetEvent':_0x229052,'clickOutsideToClose':_0x3c002a?![]:!![],'escapeToClose':_0x3c002a?![]:!![],'locals':{'user':_0x37959f['user'],'setting':_0x5c8367,'reset':_0x3c002a}});}function _0x47b360(){const _0x5e4ac9=_0x423168;return _0x19728a[_0x5e4ac9('0x20b2')]()&&_0x19728a[_0x5e4ac9('0xca1')]('agent');}function _0x353a04(_0x2c5234){const _0x3b90d9=_0x423168;if(_0x2c5234['id']===_0x37959f[_0x3b90d9('0xc96')]['id']){if(_0x2c5234[_0x3b90d9('0xecb')]===_0x3b90d9('0x2327')&&_0x2e3ca0()[_0x3b90d9('0x2406')](_0x2c5234[_0x3b90d9('0x2309')])&&!_0x2c5234[_0x3b90d9('0x2309')]){if(_0x37959f['user'][_0x3b90d9('0xf8e')]!==0x0){_0x6b8b2b();const _0x5ddfd5=_0x586cec[_0x3b90d9('0x1c6f')]()[_0x3b90d9('0xf28')](_0x4069a0[_0x3b90d9('0x2728')]('TOOLBAR.WARNING')+'!')[_0x3b90d9('0x1525')](_0x4069a0[_0x3b90d9('0x2728')]('TOOLBAR.SOMEONE_LOGGED_YOU_OUT'))[_0x3b90d9('0x1040')](_0x4069a0[_0x3b90d9('0x2728')](_0x3b90d9('0x238f'))+'!')['ok'](_0x4069a0[_0x3b90d9('0x2728')](_0x3b90d9('0x1182')))[_0x3b90d9('0x19fb')](_0x3b90d9('0x1401'));_0x586cec[_0x3b90d9('0x1d4')](_0x5ddfd5)[_0x3b90d9('0x683')](function(){const _0x5900c3=_0x3b90d9;return _0x19728a['queueLogin']()[_0x5900c3('0x683')](function(){const _0x211406=_0x5900c3;_0x5ee9e6(),_0x2e3ca0()[_0x211406('0xf22')](_0x37959f[_0x211406('0xc96')],_0x2c5234),_0x19728a[_0x211406('0x283b')](_0x37959f[_0x211406('0xc96')]);});})[_0x3b90d9('0x130a')](function(){_0x1336b4(!![]);});}else _0x1336b4(!![]);}else _0x2e3ca0()[_0x3b90d9('0xf22')](_0x37959f[_0x3b90d9('0xc96')],_0x2c5234),_0x19728a[_0x3b90d9('0x283b')](_0x37959f[_0x3b90d9('0xc96')]);}}function _0x36b354(_0xe31cd6){const _0x59d3cf=_0x423168;_0x37959f[_0x59d3cf('0x11ed')]['showWebBar']===0x2&&_0x37959f[_0x59d3cf('0x11ed')]['role']===_0x59d3cf('0x2327')&&_0x37959f[_0x59d3cf('0x11ed')][_0x59d3cf('0x60a')]===_0xe31cd6[_0x59d3cf('0x754')]&&_0xa04340['info']({'title':_0x59d3cf('0x2734'),'msg':_0x59d3cf('0x23ab')+_0xe31cd6['calleridnum']+_0x59d3cf('0xd07')+_0xe31cd6[_0x59d3cf('0x660')]+_0x59d3cf('0x223a')+(_0xe31cd6[_0x59d3cf('0x220b')]&&_0xe31cd6[_0x59d3cf('0x220b')][_0x59d3cf('0x1246')]?_0xe31cd6['variables'][_0x59d3cf('0x1246')]:_0x59d3cf('0x2347'))+_0x59d3cf('0xd66'),'showClose':!![],'timeout':0x2710,'html':!![]});}function _0x2f7506(){const _0x5d040e=_0x423168;return _0x37959f[_0x5d040e('0x260a')][_0x5d040e('0x496')]?_0x5d040e('0x1d1f'):_0x37959f[_0x5d040e('0x260a')][_0x5d040e('0x2570')];}function _0x47717c(){const _0x3f5179=_0x423168;_0x2e3ca0()['some'](_0x37959f[_0x3f5179('0x426')],{'dialMethod':'preview','dialActive':!![]})&&_0x37959f[_0x3f5179('0xace')]['dialer']&&_0x37959f[_0x3f5179('0x416')]?(_0x37959f[_0x3f5179('0x416')]=![],_0x4d503d[_0x3f5179('0x26cf')]['getOpenContacts']()[_0x3f5179('0xe53')][_0x3f5179('0x683')](function(_0x22c12d){const _0x282867=_0x3f5179;_0x22c12d&&_0x2e3ca0()[_0x282867('0x52d')](_0x22c12d[_0x282867('0x6d5')])&&(_0x37959f[_0x282867('0x6d5')]=_0x22c12d[_0x282867('0x6d5')]);})['finally'](function(){const _0x39eb8c=_0x3f5179;_0x37959f[_0x39eb8c('0x416')]=!![];})):_0x37959f['contacts']=0x0;}function _0xadc867(){const _0x154165=_0x423168;_0x5ab3ff&&(_0x143d65[_0x154165('0x19fb')](_0x5ab3ff),_0x5ab3ff=null);}function _0x47d8f3(_0x5bf830){const _0x2e085d=_0x423168;console['debug'](_0x2e085d('0x2865'),_0x5bf830);if(_0x37959f[_0x2e085d('0xc96')][_0x2e085d('0xf8e')]!==0x0)return _0x6b8b2b(),_0x19728a[_0x2e085d('0x1999')](!![])[_0x2e085d('0x683')](function(){const _0x4d4c82=_0x2e085d;_0x14520d[_0x4d4c82('0x5ed')](_0x4d4c82('0x1ff7')),_0x586cec['show'](_0x586cec['alert']()[_0x4d4c82('0x2361')](angular['element'](_0x2edb34[_0x4d4c82('0x18e5')]))[_0x4d4c82('0x188f')](![])[_0x4d4c82('0x2755')](![])['title'](_0x4069a0[_0x4d4c82('0x2728')](_0x4d4c82('0x238f')))['textContent'](_0x4069a0[_0x4d4c82('0x2728')](_0x4d4c82('0x638'),{'ip':_0x5bf830['ip']}))['ok']('OK'))[_0x4d4c82('0x683')](function(){const _0x377f35=_0x4d4c82;return _0x5be1df['go'](_0x377f35('0x8a0'));});})[_0x2e085d('0x130a')](function(_0x52d583){const _0x299c67=_0x2e085d;console[_0x299c67('0x52a')](_0x52d583);});}function _0x228607(_0x4432d3){const _0x20ce3b=_0x423168,_0x39bc8a=_0x4432d3;if(_0x37959f['currentUser']['id']===_0x39bc8a['recipient']){const _0x46f8ef=_0x4069a0[_0x20ce3b('0x2728')](_0x20ce3b('0x1ed4'),{'sender':_0x39bc8a['sender']}),_0x178ffc=_0x39bc8a[_0x20ce3b('0xd6b')]?_0x4069a0[_0x20ce3b('0x2728')](_0x20ce3b('0xaa5'),{'recipient':_0x39bc8a[_0x20ce3b('0xd6b')]}):null;_0xa04340[_0x20ce3b('0xa36')]({'title':_0x178ffc?_0x46f8ef+'\x20'+_0x178ffc:_0x46f8ef,'msg':_0x39bc8a[_0x20ce3b('0xa6a')],'clickToClose':![],'timeout':![],'sound':_0x39bc8a[_0x20ce3b('0x246a')],'html':!![]});}}_0x11c74f[_0x423168('0x26a2')](_0x423168('0x4b8'),function(){const _0x2aba68=_0x423168;_0x29c455['removeAllListeners']('user:called'),_0x29c455['removeAllListeners'](_0x2aba68('0x2719')),_0x29c455[_0x2aba68('0x1b9e')](_0x2aba68('0x1812')),_0x29c455[_0x2aba68('0x1b9e')](_0x2aba68('0x221f')),_0x29c455[_0x2aba68('0x1b9e')](_0x2aba68('0x217c')),_0x29c455[_0x2aba68('0x1b9e')](_0x2aba68('0x240f')),_0x29c455['removeAllListeners'](_0x2aba68('0x56f')),_0x29c455[_0x2aba68('0x1b9e')]('voiceQueue:remove'),_0x29c455['removeAllListeners'](_0x2aba68('0x779')),_0x29c455[_0x2aba68('0x1b9e')](_0x2aba68('0x44d')),_0x29c455[_0x2aba68('0x1b9e')](_0x2aba68('0xbf9')),_0xadc867();});}const _0x2baf43=_0x224d9d;_0x40cfa7[_0x189033('0x14be')]=[_0x189033('0x19ee')];function _0x40cfa7(_0x3a53c4){const _0x52e30a=_0x189033;_0x3a53c4[_0x52e30a('0x7d2')](_0x52e30a('0x1461'));}angular[_0x189033('0x1e26')](_0x189033('0x21e4'),[])[_0x189033('0x272d')](_0x40cfa7)['controller'](_0x189033('0x14d2'),_0x125da4)[_0x189033('0x1da3')](_0x189033('0xe56'),_0x2e6b06)['controller']('ToolbarController',_0x2baf43),_0x4f5c2f[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1d08'),'$q',_0x189033('0xba1'),_0x189033('0x1556'),'api',_0x189033('0x1c90'),_0x189033('0xace')];function _0x4f5c2f(_0x32a0b6,_0x251f84,_0x4404f9,_0x1d612e,_0x597754,_0x5a4f23,_0xbdd607,_0x85f4c2){const _0x411538=_0x189033,_0x334550=this;_0x334550[_0x411538('0x270e')]=_0x1aaf93()()[_0x411538('0x26dd')](),_0x334550[_0x411538('0x11ed')]=_0x1d612e[_0x411538('0x20b2')](),_0x334550[_0x411538('0xace')]=_0x85f4c2,_0x334550[_0x411538('0x1b29')]=0x0,_0x334550[_0x411538('0x123f')]=0x0,_0x334550['userIsNotPhonebar']=_0x4a3a36,_0x334550[_0x411538('0x186a')]=_0x20f97e,_0x334550['onMessageUpdate']=_0x3dcf3d,_0x597754['on'](_0x411538('0x1812'),_0x334550[_0x411538('0x186a')]),_0x597754['on']('chatInternalMessage:update',_0x334550['onMessageUpdate']),_0x5a4f23[_0x411538('0x1a73')][_0x411538('0x1e6e')]({'fields':_0x411538('0x1fe1'),'ToId':_0x334550[_0x411538('0x11ed')]['id'],'read':![],'nolimit':!![],'ChatGroupId':'null'})['$promise'][_0x411538('0x683')](function(_0x463fa8){const _0x173127=_0x411538;return _0x463fa8&&_0x463fa8[_0x173127('0x50d')]&&(_0x334550['unreadTotalMessages']=_0x463fa8[_0x173127('0x50d')]),_0x5a4f23[_0x173127('0xc96')][_0x173127('0xb6b')]({'id':_0x334550['currentUser']['id']})[_0x173127('0xe53')];})[_0x411538('0x683')](function(_0x378577){const _0x400ee4=_0x411538,_0x31ae93=[],_0x30cc2a=_0x378577[_0x400ee4('0xf5d')];for(let _0x507222=0x0;_0x507222<_0x30cc2a[_0x400ee4('0x1564')];_0x507222++){_0x31ae93[_0x400ee4('0x1fd0')](_0x5a4f23[_0x400ee4('0x1278')]['getUnread']({'id':_0x30cc2a[_0x507222]['id']})['$promise']);}return _0x4404f9['all'](_0x31ae93);})['then'](function(_0x30fb9b){const _0xf681c=_0x411538;for(let _0x34f806=0x0;_0x34f806<_0x30fb9b[_0xf681c('0x1564')];_0x34f806++){_0x334550[_0xf681c('0x123f')]+=_0x30fb9b[_0x34f806][_0xf681c('0x50d')];}})['catch'](function(_0x517beb){const _0xcd296a=_0x411538;console[_0xcd296a('0x52a')](_0x517beb);});function _0x18ee2f(_0x504cd8){const _0x51d634=_0x411538,_0x266a1a={'autoClose':!![],'duration':0xa,'showOnPageHidden':!![],'icon':'api/users/'+_0x504cd8[_0x51d634('0x1fe1')]+_0x51d634('0x9f3'),'body':_0x504cd8[_0x51d634('0x18e5')]||'','focusOnclick':!![],'closeOnClick':!![]};_0xbdd607[_0x51d634('0x1d4')](_0x251f84['instant'](_0x51d634('0xafb')),_0x266a1a);}function _0x123c3c(_0x5a7ea7){const _0x52c6ab=_0x411538;_0xbdd607[_0x52c6ab('0x38e')]()?_0xbdd607[_0x52c6ab('0xb8e')]()[_0x52c6ab('0x683')](function(){_0x18ee2f(_0x5a7ea7);},function(_0x5e7584){const _0x7e1b68=_0x52c6ab;console[_0x7e1b68('0x52a')](_0x7e1b68('0xdbf'),_0x5e7584);}):console[_0x52c6ab('0x52a')](_0x52c6ab('0x304'));}function _0x4a3a36(){const _0x56ba5f=_0x411538;return _0x334550['currentUser']['role']===_0x56ba5f('0x20c2')||_0x334550[_0x56ba5f('0x11ed')][_0x56ba5f('0xecb')]===_0x56ba5f('0xc96')||_0x334550[_0x56ba5f('0x11ed')]['role']===_0x56ba5f('0x2327')&&_0x334550[_0x56ba5f('0x11ed')][_0x56ba5f('0xf8e')]!==0x0;}function _0x20f97e(_0x151d05){const _0x5b6385=_0x411538;_0x151d05[_0x5b6385('0x20e6')]===_0x334550[_0x5b6385('0x11ed')]['id']&&_0x151d05[_0x5b6385('0x1fe1')]!==_0x334550[_0x5b6385('0x11ed')]['id']&&!_0x151d05[_0x5b6385('0x20db')]&&_0x151d05[_0x5b6385('0x1691')]&&(_0x334550[_0x5b6385('0x123f')]++,_0x123c3c(_0x151d05)),_0x151d05[_0x5b6385('0x20e6')]===_0x334550[_0x5b6385('0x11ed')]['id']&&!_0x151d05[_0x5b6385('0x1691')]&&(_0x334550['unreadTotalMessages']+=0x1,_0x123c3c(_0x151d05));}function _0x3dcf3d(_0x41a937){const _0x1fe70f=_0x411538;_0x41a937[_0x1fe70f('0x20e6')]===_0x334550[_0x1fe70f('0x11ed')]['id']&&_0x41a937[_0x1fe70f('0x20db')]&&_0x334550[_0x1fe70f('0x1b29')]>0x0&&!_0x41a937[_0x1fe70f('0x1691')]&&(_0x334550[_0x1fe70f('0x1b29')]-=0x1),_0x41a937[_0x1fe70f('0x20e6')]==_0x334550[_0x1fe70f('0x11ed')]['id']&&_0x41a937['FromId']!==_0x334550[_0x1fe70f('0x11ed')]['id']&&_0x41a937[_0x1fe70f('0x1691')]&&_0x41a937[_0x1fe70f('0x20db')]&&(_0x334550[_0x1fe70f('0x123f')]>0x0&&_0x334550[_0x1fe70f('0x123f')]--);}_0x32a0b6['$on'](_0x411538('0x4b8'),function(){const _0x464e7c=_0x411538;_0x597754['removeAllListeners'](_0x464e7c('0x1812')),_0x597754['removeAllListeners'](_0x464e7c('0x221f'));});}const _0x4823d5=_0x4f5c2f;_0x5948da[_0x189033('0x14be')]=['$scope',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x2f9'),_0x189033('0xba1'),'socket',_0x189033('0x110c'),'$q',_0x189033('0x1b27'),_0x189033('0x1d08'),_0x189033('0x1b'),'$http'];function _0x5948da(_0x282181,_0x3605a6,_0x4020a7,_0x501a36,_0x49afd9,_0x4fa13b,_0x364c64,_0x30d0da,_0x3f769c,_0x482c49,_0x3848de,_0x2b337e){const _0x47a185=_0x189033,_0xfd2299=this;_0xfd2299[_0x47a185('0x11ed')]=_0x49afd9[_0x47a185('0x20b2')](),_0xfd2299[_0x47a185('0xc96')]=undefined,_0xfd2299[_0x47a185('0x3bf')]={'count':0x0,'rows':[]},_0xfd2299[_0x47a185('0x2416')]=_0x1aaf93()(0x0)[_0x47a185('0x26dd')](_0x47a185('0x865')),_0xfd2299['unreadMessage']={},_0xfd2299[_0x47a185('0xae5')]='',_0xfd2299[_0x47a185('0x120b')]=![],_0xfd2299[_0x47a185('0x12f3')]=_0x2cc892,_0xfd2299['toggleChat']=_0x4a5ed1,_0xfd2299[_0x47a185('0xb9d')]=_0x557315,_0xfd2299[_0x47a185('0x186a')]=_0x1c7f4a,_0xfd2299['onMessageUpdate']=_0x406d3d,_0xfd2299[_0x47a185('0x19de')]=_0x28186c,_0xfd2299[_0x47a185('0x84a')]=_0x4de4d4,_0xfd2299[_0x47a185('0x164f')]=_0x52e8d2,_0xfd2299[_0x47a185('0x1011')]=_0x47d0fa,_0x4fa13b['on'](_0x47a185('0x1812'),_0xfd2299[_0x47a185('0x186a')]),_0x4fa13b['on'](_0x47a185('0x221f'),_0xfd2299[_0x47a185('0x766')]),_0x4fa13b['on'](_0x47a185('0x2719'),_0xfd2299['onUserUpdate']),_0x364c64(_0x47a185('0x1eed'))[_0x47a185('0xa12')](function(){const _0x5632e7=_0x47a185;_0xfd2299[_0x5632e7('0xc96')]=undefined;}),_0x4020a7['chatInternalMessage'][_0x47a185('0x1e6e')]({'fields':_0x47a185('0x1fe1'),'ToId':_0xfd2299[_0x47a185('0x11ed')]['id'],'read':![],'nolimit':!![],'ChatGroupId':'null'})['$promise'][_0x47a185('0x683')](function(_0x19d8c3){const _0x128d0b=_0x47a185;_0xfd2299['unreadMessage']=_0x2e3ca0()['countBy'](_0x19d8c3[_0x128d0b('0xf5d')],_0x128d0b('0x1fe1'));})[_0x47a185('0x130a')](function(){}),_0x4020a7[_0x47a185('0x1a73')][_0x47a185('0x16dc')]()[_0x47a185('0xe53')][_0x47a185('0x683')](function(_0x3faae9){const _0x31fdee=_0x47a185;_0xfd2299[_0x31fdee('0x3bf')]=_0x3faae9;})[_0x47a185('0x130a')](function(_0x3b08ac){console['error'](_0x3b08ac);});function _0x2cc892(_0x286d3c){const _0x3ea97a=_0x47a185;_0xfd2299[_0x3ea97a('0xace')]=_0x286d3c;}function _0x1c7f4a(_0x556173){const _0x478e1e=_0x47a185;if(_0x556173[_0x478e1e('0x20e6')]===_0xfd2299['currentUser']['id']&&!_0x556173['ChatGroupId']){_0xfd2299['user']&&_0xfd2299[_0x478e1e('0xc96')]['id']===_0x556173[_0x478e1e('0x1fe1')]?(_0xfd2299[_0x478e1e('0xc96')][_0x478e1e('0x2636')][_0x478e1e('0xf5d')][_0x478e1e('0x1fd0')](_0x556173),_0x565830(0x0),_0x4020a7[_0x478e1e('0x1a73')]['update']({'id':_0x556173['id'],'read':!![]})):_0xfd2299[_0x478e1e('0x15d2')][_0x556173[_0x478e1e('0x1fe1')]]=_0xfd2299[_0x478e1e('0x15d2')][_0x556173['FromId']]?_0xfd2299[_0x478e1e('0x15d2')][_0x556173[_0x478e1e('0x1fe1')]]+0x1:0x1;const _0x464b79=_0x2e3ca0()['find'](_0xfd2299[_0x478e1e('0x3bf')]['rows'],{'id':_0x556173[_0x478e1e('0x1fe1')]});_0x464b79&&(_0x464b79[_0x478e1e('0x46')]=_0x556173[_0x478e1e('0x1a4')],_0x464b79['lastMessage']=_0x556173);}}function _0x406d3d(_0x298178){const _0x10a523=_0x47a185;if((_0x298178[_0x10a523('0x1fe1')]===_0xfd2299[_0x10a523('0x11ed')]['id']||_0x298178['ToId']===_0xfd2299['currentUser']['id'])&&!_0x298178[_0x10a523('0x1691')]){if(_0xfd2299[_0x10a523('0xc96')]){const _0x4c6986=_0x2e3ca0()[_0x10a523('0x1c07')](_0xfd2299[_0x10a523('0xc96')]['messages']['rows'],{'id':_0x298178['id']});_0x4c6986&&_0x2e3ca0()[_0x10a523('0xf22')](_0x4c6986,_0x298178);}const _0x9381d9=_0x2e3ca0()[_0x10a523('0x1c07')](_0xfd2299['users']['rows'],{'id':_0xfd2299['currentUser']['id']===_0x298178[_0x10a523('0x1fe1')]?_0x298178[_0x10a523('0x20e6')]:_0x298178[_0x10a523('0x1fe1')]});_0x9381d9&&_0x9381d9[_0x10a523('0x88f')]&&_0x2e3ca0()[_0x10a523('0xf22')](_0x9381d9[_0x10a523('0x88f')],_0x298178),_0x298178[_0x10a523('0x20e6')]===_0xfd2299[_0x10a523('0x11ed')]['id']&&(_0x298178['read']&&_0xfd2299['unreadMessage'][_0x298178['FromId']]>0x0&&(_0xfd2299['unreadMessage'][_0x298178[_0x10a523('0x1fe1')]]-=0x1));}}function _0x28186c(_0x5ce304){const _0x389dc5=_0x47a185,_0x5245be=_0x2e3ca0()[_0x389dc5('0x1c07')](_0xfd2299[_0x389dc5('0x3bf')][_0x389dc5('0xf5d')],{'id':_0x5ce304['id']});_0x5245be&&(!_0x2e3ca0()[_0x389dc5('0x8f2')](_0x5ce304[_0x389dc5('0x2309')])&&_0x5245be[_0x389dc5('0x2309')]!==_0x5ce304[_0x389dc5('0x2309')]&&(_0x5245be[_0x389dc5('0x2309')]=_0x5ce304[_0x389dc5('0x2309')]),!_0x2e3ca0()[_0x389dc5('0x8f2')](_0x5ce304[_0x389dc5('0x1617')])&&_0x5245be[_0x389dc5('0x1617')]!==_0x5ce304[_0x389dc5('0x1617')]&&(_0x5245be[_0x389dc5('0x1617')]=_0x5ce304[_0x389dc5('0x1617')]));}function _0x4a5ed1(_0x467c91){const _0x241220=_0x47a185;if(_0x467c91){if(!_0x467c91[_0x241220('0x1617')]&&_0x467c91[_0x241220('0xecb')]===_0x241220('0x2327')){_0x3605a6[_0x241220('0xd33')]({'title':_0x482c49['instant'](_0x241220('0x1bd5')),'msg':_0x482c49[_0x241220('0x2728')](_0x241220('0x14a5'))}),_0xfd2299[_0x241220('0xc96')]=undefined;return;}_0xfd2299[_0x241220('0xc96')]=_0x467c91,_0xfd2299['replyMessage']='',_0x4020a7[_0x241220('0x1a73')][_0x241220('0x1e6e')]({'sort':_0x241220('0x1a4'),'FromId':_0xfd2299[_0x241220('0x11ed')]['id']+','+_0x467c91['id'],'ToId':_0xfd2299[_0x241220('0x11ed')]['id']+','+_0x467c91['id'],'ChatGroupId':_0x241220('0x13c')})[_0x241220('0xe53')]['then'](function(_0x305fde){const _0x121ae1=_0x241220;if(_0x305fde&&_0x305fde[_0x121ae1('0xf5d')]){_0xfd2299[_0x121ae1('0xc96')][_0x121ae1('0x2636')]=_0x305fde;for(let _0x278cc0=0x0;_0x278cc0<_0xfd2299[_0x121ae1('0xc96')][_0x121ae1('0x2636')][_0x121ae1('0xf5d')][_0x121ae1('0x1564')];_0x278cc0+=0x1){_0xfd2299[_0x121ae1('0xc96')]['messages'][_0x121ae1('0xf5d')][_0x278cc0][_0x121ae1('0x20db')]===![]&&_0xfd2299[_0x121ae1('0xc96')]['messages']['rows'][_0x278cc0]['ToId']===_0xfd2299[_0x121ae1('0x11ed')]['id']&&_0x4020a7['chatInternalMessage'][_0x121ae1('0x2480')]({'id':_0xfd2299['user'][_0x121ae1('0x2636')][_0x121ae1('0xf5d')][_0x278cc0]['id'],'read':!![]});}}})[_0x241220('0x2874')](function(){_0x565830(0x0);});}else _0xfd2299[_0x241220('0xc96')]=undefined;}function _0x557315(){const _0x52f594=_0x47a185;_0xfd2299[_0x52f594('0x120b')]=!![];if(_0xfd2299[_0x52f594('0xae5')]===''){_0xfd2299['disabled']=![];return;}const _0x33a667={'FromId':_0xfd2299[_0x52f594('0x11ed')]['id'],'ToId':_0xfd2299[_0x52f594('0xc96')]['id'],'body':_0xfd2299[_0x52f594('0xae5')],'read':![]};_0xfd2299[_0x52f594('0xae5')]='',_0x4020a7[_0x52f594('0x1a73')]['save'](_0x33a667)['$promise'][_0x52f594('0x683')](function(_0x10bff5){const _0x13c877=_0x52f594;_0xfd2299[_0x13c877('0xc96')]['messages']['rows'][_0x13c877('0x1fd0')](_0x10bff5),_0xfd2299['user'][_0x13c877('0x46')]=_0x10bff5[_0x13c877('0x1a4')],_0xfd2299['user'][_0x13c877('0x88f')]=_0x10bff5,_0x565830(0x190);})[_0x52f594('0x130a')](function(){})[_0x52f594('0x2874')](function(){const _0x579fd5=_0x52f594;_0xfd2299[_0x579fd5('0x120b')]=![];});}function _0x565830(_0x1ecf88){const _0xbad39f=_0x47a185,_0x57c7bd=angular['element'](_0xbad39f('0x1058'));_0x501a36(function(){const _0x42159c=_0xbad39f;_0x57c7bd['animate']({'scrollTop':_0x57c7bd[0x0][_0x42159c('0x1a99')]},_0x1ecf88);},0x0);}function _0x55691d(_0x3d4134){const _0x18ed78=_0x47a185;return!_0x2e3ca0()[_0x18ed78('0x8f2')](_0x3d4134)?_0x3d4134[_0x18ed78('0x1725')](/[^\w.+#*-]+/g,''):'';}function _0x4de4d4(_0x2399dd){const _0x41d73f=_0x47a185;_0x3848de[_0x41d73f('0x5ed')](_0x41d73f('0x2638'),{'target':_0x55691d(_0x2399dd)});}function _0x52e8d2(_0x2dc4db){const _0x2f25e7=_0x47a185;return _0x15e36e(_0x2f25e7('0x712')+(_0xfd2299[_0x2f25e7('0xc96')]['phoneBarRemoteControlPort']||_0x2f25e7('0x10a5'))+_0x2f25e7('0x229c')+_0x55691d(_0x2dc4db));}function _0x47d0fa(_0x389d70){const _0x8d92a3=_0x47a185;return _0x15e36e(_0x8d92a3('0x712')+(_0xfd2299[_0x8d92a3('0xc96')][_0x8d92a3('0x1e01')]||_0x8d92a3('0x10a5'))+_0x8d92a3('0x157')+_0x55691d(_0x389d70));}function _0x15e36e(_0x106e65){const _0x48ff45=_0x47a185;return _0x2b337e[_0x48ff45('0x1e6e')](_0x106e65)[_0x48ff45('0x53')](function(){const _0x69cbc3=_0x48ff45;_0x3605a6['success']({'title':_0x69cbc3('0x1c62'),'msg':'Call\x20properly\x20handled!'});})[_0x48ff45('0x52a')](function(){const _0x5f0fea=_0x48ff45;_0x3605a6['error']({'title':_0x5f0fea('0x1035'),'msg':_0x482c49['instant'](_0x5f0fea('0x697'))});});}_0x282181[_0x47a185('0x26a2')]('$destroy',function(){const _0x290341=_0x47a185;_0x4fa13b[_0x290341('0x1b9e')](_0x290341('0x1812')),_0x4fa13b[_0x290341('0x1b9e')]('chatInternalMessage:update'),_0x4fa13b[_0x290341('0x1b9e')](_0x290341('0x2719'));});}const _0x5a6b66=_0x5948da;_0x953c60[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x980'),'members'];function _0x953c60(_0x4f5a72,_0x2030cd,_0xe53f33,_0x58a149,_0x464314,_0x2707f0,_0x5da2b8,_0x1292f4,_0x510276){const _0x488771=_0x189033,_0x34a4a6=this;_0x34a4a6[_0x488771('0x17f')]=[],_0x34a4a6['title']=_0x488771('0x8b1'),_0x34a4a6[_0x488771('0x980')]=angular['copy'](_0x1292f4),_0x34a4a6[_0x488771('0x11ed')]=_0x5da2b8[_0x488771('0x20b2')](),_0x34a4a6[_0x488771('0x702')]=_0x510276,_0x34a4a6[_0x488771('0x206d')]=!![];!_0x34a4a6[_0x488771('0x980')]&&(_0x34a4a6[_0x488771('0x980')]={'write':!![],'members':[]},_0x34a4a6['title']=_0x488771('0x159f'));_0x34a4a6[_0x488771('0x2449')]=_0x5131b7,_0x34a4a6[_0x488771('0xf82')]=_0x4b9f08,_0x34a4a6[_0x488771('0x6d7')]=_0x528934;function _0x61565b(_0x3f4fc1){const _0x3244f8=_0x488771,_0x1a1beb=_0x3f4fc1[_0x3244f8('0x93a')]();return function _0x253b2a(_0xb861b5){const _0x19d95c=_0x3244f8,_0x39b2da=_0xb861b5[_0x19d95c('0x60a')][_0x19d95c('0x93a')]();return _0x39b2da[_0x19d95c('0x824')](_0x1a1beb)!=-0x1;};}function _0x528934(_0x281ce8){const _0x3839b1=_0x488771;return _0x281ce8?_0x34a4a6[_0x3839b1('0x702')][_0x3839b1('0xf5d')][_0x3839b1('0x25')](_0x61565b(_0x281ce8)):[];}function _0x5131b7(){const _0x1b6cf7=_0x488771;let _0x5bd4dd;return _0x34a4a6['errors']=[],_0x2707f0[_0x1b6cf7('0x1278')][_0x1b6cf7('0xb0a')]({'name':_0x34a4a6[_0x1b6cf7('0x980')][_0x1b6cf7('0x60a')],'write':_0x34a4a6[_0x1b6cf7('0x980')][_0x1b6cf7('0x18f2')]})['$promise']['then'](function(_0x97c7eb){const _0x2c813e=_0x1b6cf7,_0x4e5181=_0x2e3ca0()[_0x2c813e('0x386')](_0x34a4a6[_0x2c813e('0x980')][_0x2c813e('0x702')],'id');return _0x4e5181['unshift'](_0x34a4a6['currentUser']['id']),_0x5bd4dd=_0x97c7eb,_0x2707f0[_0x2c813e('0x1278')][_0x2c813e('0xc98')]({'id':_0x5bd4dd['id'],'ids':_0x4e5181})[_0x2c813e('0xe53')];})[_0x1b6cf7('0x683')](function(){const _0x426e0c=_0x1b6cf7;_0x464314['success']({'title':'Group\x20properly\x20saved!','msg':_0x5bd4dd['name']+_0x426e0c('0xf59')}),_0x4b9f08(_0x5bd4dd);})[_0x1b6cf7('0x130a')](function(_0x3dd3ca){const _0x17690b=_0x1b6cf7;_0x464314[_0x17690b('0x52a')]({'title':_0x3dd3ca[_0x17690b('0x13ee')]?'API:'+_0x3dd3ca['status']+_0x17690b('0xbf6')+_0x3dd3ca[_0x17690b('0x24a9')]:_0x17690b('0x189f'),'msg':_0x3dd3ca[_0x17690b('0x5a5')]?JSON[_0x17690b('0x258a')](_0x3dd3ca['data'][_0x17690b('0x8c2')]):_0x3dd3ca['toString']()});});}function _0x4b9f08(_0x35952b){const _0x26526e=_0x488771;_0x58a149[_0x26526e('0x1715')](_0x35952b);}}const _0x1ca98d=_0x953c60,_0x13dee4=_0x180212['p']+_0x189033('0x181c'),_0x2f9282=_0x180212['p']+'src/js/modules/quick-panel/tabs/groups/info/dialog.html/dialog.html';_0x27cea9['$inject']=[_0x189033('0x7a5'),'$document','$timeout',_0x189033('0x1e48'),_0x189033('0x110c'),'$q',_0x189033('0xba1'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70')];function _0x27cea9(_0xbc4057,_0x297556,_0x41078d,_0x439baf,_0x11c8ca,_0x4e7f2b,_0x121d80,_0x412c91,_0x338b75,_0x429ec5){const _0x593e66=_0x189033,_0x5d0dc4=this;_0x5d0dc4[_0x593e66('0x11ed')]=_0x121d80['getCurrentUser'](),_0x5d0dc4[_0x593e66('0x13b1')]={},_0x5d0dc4['groups']={},_0x5d0dc4[_0x593e66('0x1a83')],_0x5d0dc4[_0x593e66('0x980')],_0x5d0dc4[_0x593e66('0x12f3')]=_0xc08dfd,_0x5d0dc4[_0x593e66('0x1c34')]=_0x3b1aa9,_0x5d0dc4[_0x593e66('0x27fd')]=_0x55975c,_0x5d0dc4[_0x593e66('0xe96')]=_0x4bf2b0,_0x5d0dc4[_0x593e66('0x19c0')]=_0x1f7676,_0x5d0dc4[_0x593e66('0x427')]=_0x3e9c76,_0x5d0dc4['toggleChat']=_0x553eba,_0x5d0dc4[_0x593e66('0xb9d')]=_0x5cf153,_0x338b75['on']('chatInternalMessage:save',_0x1e5742),_0x338b75['on'](_0x593e66('0x221f'),_0x5b57f2),_0x338b75['on'](_0x593e66('0xc6d'),_0x34d2ae),_0x11c8ca(_0x593e66('0x1eed'))[_0x593e66('0xa12')](_0x3b1aa9);function _0x34d2ae(_0x50d31f){const _0x2a956a=_0x593e66;_0x5d0dc4[_0x2a956a('0xb9a')][_0x50d31f['id']]&&delete _0x5d0dc4[_0x2a956a('0xb9a')][_0x50d31f['id']];}function _0x5b57f2(_0x41ccdb){const _0x3604de=_0x593e66;_0x41ccdb['ToId']==_0x5d0dc4[_0x3604de('0x11ed')]['id']&&_0x41ccdb[_0x3604de('0x1fe1')]!==_0x5d0dc4[_0x3604de('0x11ed')]['id']&&_0x41ccdb[_0x3604de('0x1691')]&&_0x41ccdb['read']&&(_0x5d0dc4[_0x3604de('0xb9a')][_0x41ccdb['ChatGroupId']][_0x3604de('0x13b1')]>0x0&&_0x5d0dc4[_0x3604de('0xb9a')][_0x41ccdb[_0x3604de('0x1691')]][_0x3604de('0x13b1')]--,_0x5d0dc4[_0x3604de('0x980')][_0x3604de('0x2636')][_0x41ccdb['id']]&&(_0x5d0dc4[_0x3604de('0x980')][_0x3604de('0x2636')][_0x41ccdb['id']][_0x3604de('0x20db')]=!![]));}function _0x1e5742(_0x21cbc0){const _0x1ae1d0=_0x593e66;if(!_0x5d0dc4['group']&&_0x21cbc0['ToId']===_0x5d0dc4[_0x1ae1d0('0x11ed')]['id']&&_0x21cbc0['FromId']!==_0x5d0dc4[_0x1ae1d0('0x11ed')]['id']&&!_0x21cbc0['read']&&_0x21cbc0[_0x1ae1d0('0x1691')]){const _0x48f5ac=_0x5d0dc4[_0x1ae1d0('0xb9a')][_0x21cbc0['ChatGroupId']];if(_0x48f5ac)!_0x48f5ac[_0x1ae1d0('0x13b1')]&&(_0x48f5ac[_0x1ae1d0('0x13b1')]=0x0),_0x48f5ac['unreadGroupMessages']++;else return _0x412c91[_0x1ae1d0('0x1278')][_0x1ae1d0('0x1e6e')]({'id':_0x21cbc0[_0x1ae1d0('0x1691')]})[_0x1ae1d0('0xe53')][_0x1ae1d0('0x683')](function(_0x1eea99){const _0x284ecb=_0x1ae1d0;_0x1eea99[_0x284ecb('0x13b1')]=0x1,_0x5d0dc4['groups'][_0x1eea99['id']]=_0x1eea99;});}_0x5d0dc4[_0x1ae1d0('0x980')]&&_0x21cbc0[_0x1ae1d0('0x1691')]===_0x5d0dc4[_0x1ae1d0('0x980')]['id']&&_0x21cbc0[_0x1ae1d0('0x20e6')]===_0x5d0dc4[_0x1ae1d0('0x11ed')]['id']&&_0x412c91[_0x1ae1d0('0x1a73')]['update']({'id':_0x21cbc0['id'],'read':!![]})[_0x1ae1d0('0xe53')][_0x1ae1d0('0x683')](function(){_0x22010b(_0x21cbc0);});}function _0xc08dfd(_0x4e3f92){const _0x4f8e18=_0x593e66;return _0x5d0dc4[_0x4f8e18('0xace')]=_0x4e3f92,_0x412c91[_0x4f8e18('0xc96')][_0x4f8e18('0xb6b')]({'id':_0x5d0dc4['currentUser']['id']})[_0x4f8e18('0xe53')][_0x4f8e18('0x683')](function(_0x4fc164){const _0xfeb6a=_0x4f8e18,_0x4df151=[];for(let _0x2095cc=0x0;_0x2095cc<_0x4fc164[_0xfeb6a('0xf5d')][_0xfeb6a('0x1564')];_0x2095cc++){_0x4fc164[_0xfeb6a('0xf5d')][_0x2095cc][_0xfeb6a('0x13b1')]=0x0,_0x5d0dc4[_0xfeb6a('0xb9a')][_0x4fc164[_0xfeb6a('0xf5d')][_0x2095cc]['id']]=_0x4fc164[_0xfeb6a('0xf5d')][_0x2095cc],_0x4df151[_0xfeb6a('0x1fd0')](_0x412c91[_0xfeb6a('0x1278')][_0xfeb6a('0x1c9f')]({'id':_0x4fc164[_0xfeb6a('0xf5d')][_0x2095cc]['id']})['$promise']);}return _0x4e7f2b[_0xfeb6a('0x252c')](_0x4df151);})[_0x4f8e18('0x683')](function(_0x456751){const _0x1d338c=_0x4f8e18;for(let _0x3b4c8c=0x0;_0x3b4c8c<_0x456751['length'];_0x3b4c8c++){_0x5d0dc4[_0x1d338c('0xb9a')][_0x456751[_0x3b4c8c]['id']][_0x1d338c('0x13b1')]+=_0x456751[_0x3b4c8c][_0x1d338c('0x50d')];}})['catch'](function(_0x14eac9){console['error'](_0x14eac9);});}function _0x1f7676(){const _0x3ae41f=_0x593e66;return _0x2e3ca0()['values'](_0x5d0dc4[_0x3ae41f('0xb9a')]);}function _0x3e9c76(_0x403a3f,_0x5e20a8){const _0x5d1489=_0x593e66;_0x439baf[_0x5d1489('0x1d4')]({'controller':'ShowMessageInfoDialogController','controllerAs':'vm','templateUrl':_0x2f9282,'parent':angular[_0x5d1489('0x1fcc')](_0x297556[_0x5d1489('0x18e5')]),'targetEvent':_0x403a3f,'clickOutsideToClose':!![],'locals':{'message':_0x5e20a8},'resolve':{'data':function(){const _0x35deec=_0x5d1489,_0x8e5cb0={'messages':[]};return _0x412c91[_0x35deec('0x1a73')][_0x35deec('0x1e6e')]({'ChatInternalMessageId':_0x5e20a8['id']})[_0x35deec('0xe53')]['then'](function(_0x2090d6){const _0x17def2=_0x35deec,_0x810d9e=[];_0x8e5cb0[_0x17def2('0x2636')]=_0x2090d6[_0x17def2('0xf5d')],_0x8e5cb0[_0x17def2('0x2636')]['unshift'](_0x5e20a8);for(let _0x29314b=0x0;_0x29314b<_0x8e5cb0[_0x17def2('0x2636')][_0x17def2('0x1564')];_0x29314b++){_0x810d9e[_0x17def2('0x1fd0')](_0x412c91['user']['get']({'id':_0x8e5cb0[_0x17def2('0x2636')][_0x29314b][_0x17def2('0x20e6')],'fields':_0x17def2('0x7d0')})[_0x17def2('0xe53')]);}return _0x4e7f2b['all'](_0x810d9e);})[_0x35deec('0x683')](function(_0x38292b){const _0x1d83e7=_0x35deec;return _0x8e5cb0[_0x1d83e7('0x3bf')]=_0x38292b,_0x8e5cb0;})[_0x35deec('0x130a')](function(_0x308cab){const _0x4bf34b=_0x35deec;_0x308cab&&console[_0x4bf34b('0x52a')](_0x308cab);});}}})[_0x5d1489('0x683')](function(){})[_0x5d1489('0x130a')](function(_0x4c5cb9){const _0x375425=_0x5d1489;_0x4c5cb9&&console[_0x375425('0x52a')](_0x4c5cb9[_0x375425('0x8c2')]);});}function _0x5cf153(){const _0x56103b=_0x593e66;if(!_0x5d0dc4[_0x56103b('0xae5')])return;const _0x44b170={'id':_0x5d0dc4[_0x56103b('0x980')]['id'],'FromId':_0x5d0dc4[_0x56103b('0x11ed')]['id'],'ToId':_0x5d0dc4[_0x56103b('0x11ed')]['id'],'body':_0x5d0dc4[_0x56103b('0xae5')],'read':!![]},_0x334b52=[];_0x5d0dc4[_0x56103b('0xae5')]='',_0x412c91['chatGroup'][_0x56103b('0xe31')](_0x44b170)[_0x56103b('0xe53')]['then'](function(_0x597d84){const _0x5ba423=_0x56103b;_0x44b170[_0x5ba423('0x20db')]=![],_0x44b170[_0x5ba423('0x2325')]=_0x597d84['id'];for(let _0x8e3b3c=0x0;_0x8e3b3c<_0x5d0dc4[_0x5ba423('0x980')][_0x5ba423('0x702')][_0x5ba423('0x1564')];_0x8e3b3c++){_0x5d0dc4[_0x5ba423('0x980')]['members'][_0x8e3b3c]['id']!==_0x5d0dc4[_0x5ba423('0x11ed')]['id']&&(_0x44b170[_0x5ba423('0x20e6')]=_0x5d0dc4[_0x5ba423('0x980')][_0x5ba423('0x702')][_0x8e3b3c]['id'],_0x334b52[_0x5ba423('0x1fd0')](_0x412c91[_0x5ba423('0x1278')][_0x5ba423('0xe31')](angular['copy'](_0x44b170))[_0x5ba423('0xe53')]));}return _0x4e7f2b['all'](_0x334b52);})['catch'](function(_0x4de12b){const _0x18ccf5=_0x56103b;console[_0x18ccf5('0x1b2b')](_0x4de12b);});}function _0x22010b(_0xc14be2){const _0x141a44=_0x593e66;_0x5d0dc4[_0x141a44('0x980')]['messages'][_0xc14be2['id']]=_0xc14be2,_0x38d65b(0x190);}function _0x3b1aa9(){const _0x2f49e3=_0x593e66;delete _0x5d0dc4[_0x2f49e3('0x980')];}function _0x38d65b(_0x2629b9){const _0x43a234=_0x593e66,_0x40279a=angular[_0x43a234('0x1fcc')](_0x43a234('0x2587'));_0x41078d(function(){const _0x2ebf02=_0x43a234;_0x40279a[_0x2ebf02('0x1219')]({'scrollTop':_0x40279a[0x0]['scrollHeight']},_0x2629b9);},0x0);}function _0x553eba(_0x311918){const _0xcff2dc=_0x593e66;_0x5d0dc4[_0xcff2dc('0x980')]={'id':_0x311918['id'],'write':_0x311918[_0xcff2dc('0x18f2')],'messages':{}},_0x412c91[_0xcff2dc('0x1278')][_0xcff2dc('0x27cf')]({'id':_0x311918['id'],'fields':_0xcff2dc('0x2686')})[_0xcff2dc('0xe53')][_0xcff2dc('0x683')](function(_0x27f82f){const _0x55b063=_0xcff2dc;return _0x5d0dc4[_0x55b063('0x980')]['membersByKeys']=_0x2e3ca0()[_0x55b063('0x24db')](_0x27f82f[_0x55b063('0xf5d')],'id'),_0x5d0dc4['group']['members']=_0x2e3ca0()[_0x55b063('0x461')](_0x27f82f[_0x55b063('0xf5d')],[{'id':_0x5d0dc4[_0x55b063('0x11ed')]['id']}],'id'),_0x5d0dc4[_0x55b063('0x1a83')]=_0x2e3ca0()[_0x55b063('0x386')](_0x5d0dc4[_0x55b063('0x980')]['members'],'fullname')[_0x55b063('0x1630')](',\x20'),_0x412c91['chatGroup']['getMessages']({'id':_0x311918['id'],'nolimit':!![]})[_0x55b063('0xe53')];})[_0xcff2dc('0x683')](function(_0x4f8b75){const _0x2d9f27=_0xcff2dc,_0x91e9a=[];let _0x36e18d;for(let _0x3fc7eb=0x0;_0x3fc7eb<_0x4f8b75[_0x2d9f27('0x50d')];_0x3fc7eb++){_0x4f8b75[_0x2d9f27('0xf5d')][_0x3fc7eb][_0x2d9f27('0x20e6')]===_0x5d0dc4[_0x2d9f27('0x11ed')]['id']&&(_0x36e18d=_0x4f8b75['rows'][_0x3fc7eb],_0x5d0dc4[_0x2d9f27('0x980')]['messages'][_0x36e18d['id']]=_0x36e18d,_0x4f8b75['rows'][_0x3fc7eb][_0x2d9f27('0x20e6')]==_0x5d0dc4[_0x2d9f27('0x11ed')]['id']&&_0x4f8b75[_0x2d9f27('0xf5d')][_0x3fc7eb][_0x2d9f27('0x1fe1')]!==_0x5d0dc4[_0x2d9f27('0x11ed')]['id']&&!_0x36e18d['read']&&_0x91e9a[_0x2d9f27('0x1fd0')](_0x412c91[_0x2d9f27('0x1a73')][_0x2d9f27('0x2480')]({'id':_0x36e18d['id'],'read':!![]})));}return _0x4e7f2b[_0x2d9f27('0x252c')](_0x91e9a);})[_0xcff2dc('0x683')](function(){_0x38d65b(0x190);})[_0xcff2dc('0x130a')](function(_0x42243d){const _0x273eeb=_0xcff2dc;console[_0x273eeb('0x52a')](_0x42243d[_0x273eeb('0x8c2')]);});}function _0x4bf2b0(_0x588498,_0x25b864){const _0x4f9c78=_0x593e66,_0x5ad49f=_0x439baf['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20group?')[_0x4f9c78('0x26e3')]('Group\x20'+_0x588498[_0x4f9c78('0x60a')]+_0x4f9c78('0x20f1')+_0x4f9c78('0x1ee7'))[_0x4f9c78('0x1040')](_0x4f9c78('0x2355'))['targetEvent'](_0x25b864)['ok']('OK')[_0x4f9c78('0x19fb')](_0x4f9c78('0x16b8'));_0x439baf['show'](_0x5ad49f)[_0x4f9c78('0x683')](function(){const _0xdc8e1c=_0x4f9c78;return _0x412c91[_0xdc8e1c('0x1278')][_0xdc8e1c('0xd7e')]({'id':_0x588498['id']})[_0xdc8e1c('0xe53')];})[_0x4f9c78('0x683')](function(){const _0x5ca00c=_0x4f9c78;delete _0x5d0dc4[_0x5ca00c('0xb9a')][_0x588498['id']],_0x429ec5[_0x5ca00c('0x53')]({'title':'Group\x20properly\x20deleted!','msg':_0x588498[_0x5ca00c('0x60a')]+_0x5ca00c('0x194d')});})['catch'](function(_0xe676bc){const _0x425da9=_0x4f9c78;_0xe676bc&&_0x429ec5[_0x425da9('0x52a')]({'title':_0xe676bc[_0x425da9('0x13ee')]?_0x425da9('0x2168')+_0xe676bc[_0x425da9('0x13ee')]+_0x425da9('0xbf6')+_0xe676bc[_0x425da9('0x24a9')]:_0x425da9('0x1208'),'msg':_0xe676bc['data']?JSON['stringify'](_0xe676bc[_0x425da9('0x5a5')][_0x425da9('0x8c2')]):_0xe676bc['toString']()});});}function _0x55975c(_0x391639,_0x59ac84){const _0x282312=_0x593e66;_0x439baf[_0x282312('0x1d4')]({'controller':_0x282312('0x1baf'),'controllerAs':'vm','templateUrl':_0x13dee4,'parent':angular['element'](_0x297556[_0x282312('0x18e5')]),'targetEvent':_0x59ac84,'clickOutsideToClose':!![],'locals':{'group':_0x391639,'me':_0x5d0dc4[_0x282312('0x11ed')],'license':null,'setting':null},'resolve':{'members':function(){const _0x1b2bd9=_0x282312;return _0x121d80[_0x1b2bd9('0xca1')](_0x1b2bd9('0x20c2'))?_0x412c91[_0x1b2bd9('0xc96')]['get']({'role':_0x1b2bd9('0x2327')})[_0x1b2bd9('0xe53')]:_0x412c91[_0x1b2bd9('0x2a')]['getResources']({'id':_0x121d80[_0x1b2bd9('0x20b2')]()[_0x1b2bd9('0x2f')],'section':'Agents','role':_0x1b2bd9('0x2327')})['$promise'];}}})[_0x282312('0x683')](function(_0x483093){const _0x51e681=_0x282312;_0x483093&&(_0x5d0dc4[_0x51e681('0xb9a')][_0x483093['id']]=_0x483093);})[_0x282312('0x130a')](function(_0x5bfba8){const _0x170417=_0x282312;_0x5bfba8&&console[_0x170417('0x52a')](_0x5bfba8[_0x170417('0x8c2')]);});}_0xbc4057[_0x593e66('0x26a2')](_0x593e66('0x4b8'),function(){const _0x202cc2=_0x593e66;_0x338b75[_0x202cc2('0x1b9e')](_0x202cc2('0x1812')),_0x338b75[_0x202cc2('0x1b9e')](_0x202cc2('0x221f')),_0x338b75[_0x202cc2('0x1b9e')]('chatGroup:remove');});}const _0x51bb12=_0x27cea9;_0x3b77b5[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x5a5')];function _0x3b77b5(_0x2784a4,_0x4513c,_0x5e371b,_0x24d871,_0x22b667,_0x44b224,_0x20ca92,_0x5218b7){const _0x3bd833=_0x189033,_0x14fc1e=this;_0x14fc1e[_0x3bd833('0x5a5')]=_0x5218b7,_0x14fc1e[_0x3bd833('0xf28')]=_0x3bd833('0x2833');function _0xdbbf21(){const _0x19449d=_0x3bd833;_0x24d871[_0x19449d('0x1715')]();}_0x14fc1e[_0x3bd833('0xf82')]=_0xdbbf21;}const _0x5311fa=_0x3b77b5;_0x5cd646['$inject']=[_0x189033('0x19ee')];function _0x5cd646(_0x213fec){const _0x54ced8=_0x189033;_0x213fec[_0x54ced8('0x7d2')](_0x54ced8('0x2494'));}angular[_0x189033('0x1e26')](_0x189033('0x3eb'),[])[_0x189033('0x272d')](_0x5cd646)['controller'](_0x189033('0x11b8'),_0x4823d5)[_0x189033('0x1da3')](_0x189033('0x1201'),_0x5a6b66)[_0x189033('0x1da3')](_0x189033('0x1baf'),_0x1ca98d)[_0x189033('0x1da3')](_0x189033('0x9a6'),_0x51bb12)[_0x189033('0x1da3')](_0x189033('0x3e9'),_0x5311fa),_0x1c9275[_0x189033('0x14be')]=[_0x189033('0xba1'),'$cookies'];function _0x1c9275(_0x535dd,_0x5a9b32){const _0x588dd1=_0x189033,_0x48b2c3=this;function _0x5696a5(){const _0x537d30=a0_0x4e0a;_0x5a9b32[_0x537d30('0x137e')]('motion.newsAlertHide:'+_0x48b2c3['currentUser']['id'],!![]);}_0x48b2c3[_0x588dd1('0x11ed')]=_0x535dd[_0x588dd1('0x20b2')](),_0x48b2c3[_0x588dd1('0x526')]=_0x5a9b32[_0x588dd1('0x1e6e')]('motion.newsAlertHide:'+_0x48b2c3[_0x588dd1('0x11ed')]['id'])||![],_0x48b2c3[_0x588dd1('0x25ab')]=_0x5696a5;}const _0x299a17=_0x1c9275;_0x4159b2['$inject']=[_0x189033('0x19ee')];function _0x4159b2(_0x3ddb78){const _0x3beb33=_0x189033;_0x3ddb78[_0x3beb33('0x7d2')](_0x3beb33('0xf11'));}angular[_0x189033('0x1e26')](_0x189033('0x2285'),[])[_0x189033('0x272d')](_0x4159b2)['controller']('HeaderController',_0x299a17),_0x5946c4[_0x189033('0x14be')]=[_0x189033('0xba1'),_0x189033('0x17e4')];function _0x5946c4(_0x26b72d,_0x46f63b){const _0x2b9b6d=_0x189033,_0xe17f34=this;function _0xb131ca(){const _0x14489a=a0_0x4e0a;_0x46f63b[_0x14489a('0x137e')](_0x14489a('0x1838')+_0xe17f34[_0x14489a('0x11ed')]['id'],!![]);}_0xe17f34[_0x2b9b6d('0x11ed')]=_0x26b72d[_0x2b9b6d('0x20b2')](),_0xe17f34['cookieAlertHide']=_0x46f63b['get'](_0x2b9b6d('0x1838')+_0xe17f34[_0x2b9b6d('0x11ed')]['id'])||![],_0xe17f34['cookieAlertOnClose']=_0xb131ca;}const _0x31a527=_0x5946c4;_0x5cab3d[_0x189033('0x14be')]=[_0x189033('0x19ee')];function _0x5cab3d(_0x4c2f6a){const _0x15773c=_0x189033;_0x4c2f6a[_0x15773c('0x7d2')](_0x15773c('0x146a'));}angular[_0x189033('0x1e26')]('app.footer',[])['config'](_0x5cab3d)[_0x189033('0x1da3')]('FooterController',_0x31a527);var _0x5925f3=_0x180212(0x1cbe),_0x1e155a=_0x180212(0x2303),_0x5c7101=_0x180212(0xde6),_0x429809=_0x180212(0x321),_0x2af824=_0x180212(0x1c92),_0x2c8591=_0x180212(0x2361),_0x4899f5=_0x180212(0xdd5),_0x12f1fa=_0x180212(0x9d6),_0xfd4352=_0x180212(0x20aa),_0x5a8958=_0x180212(0x1ac1),_0x1a25b2=_0x180212(0x15c3),_0x37fb62=_0x180212(0x154a),_0x31a4ac=_0x180212(0x2154),_0x51b63c=_0x180212(0x23a1),_0x2fb4f9=_0x180212(0xa7c),_0x3169b3=_0x180212(0x1eaf),_0x258091=_0x180212(0x444),_0x2ad6c0=_0x180212(0x1c4),_0xbccf34=_0x180212(0x121a),_0x1927f1=_0x180212(0x1be),_0x5731df=_0x180212(0xd3e);const _0x1cc0d3=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/user/voice/user.general.voice.html/user.general.voice.html',_0x67e056=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/user/dialer/user.general.dialer.html/user.general.dialer.html',_0xd6adbd=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/user/chat/user.general.chat.html/user.general.chat.html',_0x46c540=_0x180212['p']+_0x189033('0x49f'),_0x1f439b=_0x180212['p']+_0x189033('0x1eb'),_0x486b5f=_0x180212['p']+_0x189033('0xd4d'),_0x2741b6=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/user/fax/user.general.fax.html/user.general.fax.html',_0x222efc=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/user/whatsapp/user.general.whatsapp.html/user.general.whatsapp.html';_0x2a25b0['$inject']=[_0x189033('0x7a5'),_0x189033('0x1556'),_0x189033('0x1e8f'),'chatWebsites'];function _0x2a25b0(_0x7d71d5,_0x205192,_0x309b75,_0x152e41){const _0x2b93ee=_0x189033,_0x4c47b1=this,_0x3fd3b5=[];_0x4c47b1[_0x2b93ee('0x272d')]={'format':'hh:mm:ss','unit':'seconds','trim':![]},_0x4c47b1[_0x2b93ee('0x1535')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x2b93ee('0x172f'),'avgTalkTime':_0x2b93ee('0x172f'),'answerRate':0x0,'abandonRate':0x0},_0x4c47b1[_0x2b93ee('0x25a1')]=_0x152e41?_0x2e3ca0()['keyBy'](_0x152e41[_0x2b93ee('0xf5d')]?_0x152e41[_0x2b93ee('0xf5d')]:[],'id'):{},_0x4c47b1[_0x2b93ee('0x436')]=_0x5a5169,_0x4c47b1['onUpdateChatInteraction']=_0x46fce6,_0x205192['on']('chatInteraction:save',_0x4c47b1[_0x2b93ee('0x436')]),_0x205192['on'](_0x2b93ee('0x1efd'),_0x4c47b1['onUpdateChatInteraction']),_0x5ba608();function _0x2f9e9e(_0x44ba5e,_0x2a9a97){const _0x2db2ff=_0x2b93ee;!_0x44ba5e[_0x2db2ff('0xd8a')]&&!_0x44ba5e['UserId']&&_0x2a9a97&&(_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x1386')]+=0x1);!_0x44ba5e[_0x2db2ff('0xd8a')]&&_0x44ba5e['UserId']&&!_0x2e3ca0()[_0x2db2ff('0x2292')](_0x3fd3b5,_0x44ba5e['id'])&&(_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x7a4')]+=0x1,_0x3fd3b5['push'](_0x44ba5e['id']),!_0x2a9a97&&_0x4c47b1['inbound']['waiting']&&(_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x1386')]-=0x1));if(_0x44ba5e[_0x2db2ff('0xd8a')]&&_0x44ba5e[_0x2db2ff('0x43f')]===_0x2db2ff('0x15aa'))_0x4c47b1['inbound'][_0x2db2ff('0x15aa')]+=0x1,!_0x2a9a97&&_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x1386')]&&(_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x1386')]-=0x1);else{if(_0x44ba5e[_0x2db2ff('0xd8a')]&&!_0x44ba5e['UserId']&&_0x44ba5e[_0x2db2ff('0x43f')])_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x2278')]+=0x1,!_0x2a9a97&&_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x1386')]&&(_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x1386')]-=0x1);else _0x44ba5e[_0x2db2ff('0xd8a')]&&_0x44ba5e[_0x2db2ff('0x10c5')]&&(_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x1f19')]+=_0x1aaf93()(_0x44ba5e[_0x2db2ff('0x1a19')])[_0x2db2ff('0x2357')](_0x1aaf93()(_0x44ba5e[_0x2db2ff('0x1f5b')]),_0x4c47b1['config'][_0x2db2ff('0x211a')]),_0x4c47b1['inbound'][_0x2db2ff('0x1033')]+=_0x1aaf93()(_0x44ba5e[_0x2db2ff('0x1f5b')])[_0x2db2ff('0x2357')](_0x1aaf93()(_0x44ba5e[_0x2db2ff('0x1a4')]),_0x4c47b1[_0x2db2ff('0x272d')]['unit']),_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x1e47')]+=0x1,!_0x2a9a97&&_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x7a4')]&&(_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x7a4')]-=0x1));}_0x2a9a97&&(_0x4c47b1[_0x2db2ff('0x1535')][_0x2db2ff('0x2263')]+=0x1);}function _0x45932c(){const _0x4c22ee=_0x2b93ee;_0x4c47b1[_0x4c22ee('0x1535')][_0x4c22ee('0x1efb')]=Math[_0x4c22ee('0x1758')]((_0x4c47b1['inbound'][_0x4c22ee('0x15aa')]+_0x4c47b1['inbound'][_0x4c22ee('0x2278')])/(_0x4c47b1[_0x4c22ee('0x1535')]['total']-_0x4c47b1['inbound']['talking']-_0x4c47b1[_0x4c22ee('0x1535')][_0x4c22ee('0x1386')])*0x64,-0x2),_0x4c47b1[_0x4c22ee('0x1535')]['answerRate']=Math[_0x4c22ee('0x1758')](_0x4c47b1['inbound'][_0x4c22ee('0x1e47')]/(_0x4c47b1[_0x4c22ee('0x1535')][_0x4c22ee('0x2263')]-_0x4c47b1['inbound'][_0x4c22ee('0x7a4')]-_0x4c47b1[_0x4c22ee('0x1535')]['waiting'])*0x64,-0x2),_0x4c47b1['inbound'][_0x4c22ee('0x1330')]=_0x1aaf93()['duration'](Math['round'](_0x4c47b1[_0x4c22ee('0x1535')]['sumHoldTime']/_0x4c47b1[_0x4c22ee('0x1535')][_0x4c22ee('0x1e47')]),_0x4c47b1['config'][_0x4c22ee('0x211a')])[_0x4c22ee('0x26dd')](_0x4c47b1[_0x4c22ee('0x272d')][_0x4c22ee('0x26dd')],_0x4c47b1[_0x4c22ee('0x272d')]),_0x4c47b1[_0x4c22ee('0x1535')][_0x4c22ee('0x177a')]=_0x1aaf93()[_0x4c22ee('0xe60')](Math['round'](_0x4c47b1[_0x4c22ee('0x1535')]['sumBillable']/_0x4c47b1[_0x4c22ee('0x1535')]['answered']),_0x4c47b1[_0x4c22ee('0x272d')][_0x4c22ee('0x211a')])[_0x4c22ee('0x26dd')](_0x4c47b1[_0x4c22ee('0x272d')]['format'],_0x4c47b1[_0x4c22ee('0x272d')]);}function _0x5ba608(){const _0x4d17eb=_0x2b93ee;if(Object[_0x4d17eb('0x55e')](_0x4c47b1[_0x4d17eb('0x25a1')])[_0x4d17eb('0x1564')]>0x0)for(let _0x56853c=0x0;_0x56853c<_0x309b75[_0x4d17eb('0xf5d')][_0x4d17eb('0x1564')];_0x56853c+=0x1){if(_0x4ad255(_0x309b75['rows'][_0x56853c])){const _0x3dd9ab=_0x309b75[_0x4d17eb('0xf5d')][_0x56853c];_0x2f9e9e(_0x3dd9ab,!![]),_0x45932c();}}}function _0x4ad255(_0x28ebcc){const _0x2ebdb3=_0x2b93ee;if(_0x2e3ca0()['some'](_0x4c47b1[_0x2ebdb3('0x25a1')],{'id':_0x2e3ca0()['toNumber'](_0x28ebcc[_0x2ebdb3('0x15a5')])}))return!![];return![];}function _0xcfa1c0(_0x1262a1){const _0x4a5dc2=_0x2b93ee,_0x415d4f=_0x1aaf93()()[_0x4a5dc2('0xb11')](0x0,!![])[_0x4a5dc2('0x1627')](_0x4a5dc2('0x1efa')),_0x460fcc=_0x1aaf93()()[_0x4a5dc2('0xb11')](0x0,!![])[_0x4a5dc2('0x3b3')]('day');return _0x1aaf93()(_0x1262a1)[_0x4a5dc2('0xb11')](0x0,!![])[_0x4a5dc2('0x17ad')](_0x415d4f,_0x460fcc);}function _0x5a5169(_0x620370){_0x4ad255(_0x620370)&&_0xcfa1c0(_0x620370['createdAt'])&&(_0x2f9e9e(_0x620370,!![]),_0x45932c());}function _0x46fce6(_0x47cff6){const _0x4b8968=_0x2b93ee;_0x4ad255(_0x47cff6)&&_0xcfa1c0(_0x47cff6[_0x4b8968('0x1a4')])&&(_0x2f9e9e(_0x47cff6,![]),_0x45932c());}_0x7d71d5[_0x2b93ee('0x26a2')](_0x2b93ee('0x4b8'),function(){const _0x244b0f=_0x2b93ee;_0x205192[_0x244b0f('0x1b9e')](_0x244b0f('0x445')),_0x205192[_0x244b0f('0x1b9e')]('chatInteraction:update');});}const _0x35b9f6=_0x2a25b0;_0x22aac3[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1b27'),_0x189033('0x1556'),'outboundQueues','rpcQueues','initializeRealtimeQueue','initializeRealtimeCampaign','rpcCampaigns'];function _0x22aac3(_0x3183a7,_0x69095e,_0x51a2df,_0x27736c,_0x4f88dd,_0x17bd2f,_0x1be54e,_0x3ac080){const _0x190f07=_0x189033,_0x331d1e=this;_0x331d1e[_0x190f07('0x2674')]=_0x27736c?_0x2e3ca0()['keyBy'](_0x27736c[_0x190f07('0xf5d')]?_0x27736c['rows']:[],'id'):{},_0x331d1e[_0x190f07('0x1a10')]=_0x4f88dd?_0x2e3ca0()['keyBy'](_0x4f88dd['rows']?_0x4f88dd[_0x190f07('0xf5d')]:[],'id'):{},_0x331d1e[_0x190f07('0x4fc')]=_0x3ac080?_0x2e3ca0()[_0x190f07('0x24db')](_0x3ac080[_0x190f07('0xf5d')]?_0x3ac080[_0x190f07('0xf5d')]:[],'id'):{},_0x331d1e[_0x190f07('0x715')]={'originated':0x0,'limitCalls':0x0},_0x331d1e['inbound']={'waiting':0x0,'talking':0x0,'pTalking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x190f07('0x172f'),'avgTalkTime':_0x190f07('0x172f'),'answerRate':0x0,'abandonRate':0x0,'outboundDropCallsDayCallersExit':0x0,'outboundDropCallsDayTimeout':0x0},_0x331d1e[_0x190f07('0x69a')]=_0x4cec61,_0x331d1e[_0x190f07('0x1c11')]=_0xf047a3,_0x51a2df[_0x190f07('0x5a3')](_0x190f07('0x1df'),_0x331d1e['onSaveQueue']),_0x331d1e[_0x190f07('0x115c')]=_0x69095e(function(){_0x46e1c9(),_0x255c5c();},0x3e7),_0x51a2df[_0x190f07('0x5a3')](_0x190f07('0x2410'),_0x331d1e[_0x190f07('0x1c11')]),_0x46e1c9(),_0x255c5c();function _0x46e1c9(){const _0x2dc6b7=_0x190f07;_0x17bd2f({'queues':_0x331d1e['outboundQueues'],'rpcQueues':_0x331d1e['rpcQueues']})[_0x2dc6b7('0x683')](function(_0x537d7d){_0x331d1e['inbound']=_0x537d7d;});}function _0x255c5c(){const _0x18a4a9=_0x190f07;_0x1be54e({'rpcCampaigns':_0x331d1e['rpcCampaigns']})[_0x18a4a9('0x683')](function(_0x2e3d79){const _0xb57ff=_0x18a4a9;_0x331d1e[_0xb57ff('0x715')]=_0x2e3d79;});}function _0x4cec61(_0x4cf135){const _0x24139c=_0x190f07;_0x331d1e[_0x24139c('0x2674')][_0x4cf135['id']]&&(_0x331d1e[_0x24139c('0x1a10')][_0x4cf135['id']]&&(_0x331d1e[_0x24139c('0x1a10')][_0x4cf135['id']]=_0x4cf135));}function _0xf047a3(_0x5dcba5){const _0x4291b0=_0x190f07;_0x331d1e[_0x4291b0('0x4fc')][_0x5dcba5['id']]&&(_0x331d1e[_0x4291b0('0x4fc')][_0x5dcba5['id']]=_0x5dcba5);}_0x3183a7['$on'](_0x190f07('0x4b8'),function(){const _0x2941e4=_0x190f07;_0x51a2df[_0x2941e4('0x1b9e')](_0x2941e4('0x1df')),_0x51a2df[_0x2941e4('0x1b9e')]('campaign:save'),_0x331d1e[_0x2941e4('0x115c')]&&_0x69095e[_0x2941e4('0x19fb')](_0x331d1e[_0x2941e4('0x115c')]);});}const _0x56e529=_0x22aac3;_0x5382ba[_0x189033('0x14be')]=[_0x189033('0x7a5'),'socket',_0x189033('0xe4d'),'faxAccounts'];function _0x5382ba(_0x47230a,_0x5d6c89,_0x1992e5,_0x1d42e9){const _0x37cc0a=_0x189033,_0x5ea9a8=this,_0x4fab00=[];_0x5ea9a8['config']={'format':_0x37cc0a('0x1836'),'unit':_0x37cc0a('0x1b53'),'trim':![]},_0x5ea9a8[_0x37cc0a('0x1535')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x37cc0a('0x172f'),'avgTalkTime':_0x37cc0a('0x172f'),'answerRate':0x0,'abandonRate':0x0},_0x5ea9a8[_0x37cc0a('0x2595')]=_0x1d42e9?_0x2e3ca0()['keyBy'](_0x1d42e9[_0x37cc0a('0xf5d')]?_0x1d42e9[_0x37cc0a('0xf5d')]:[],'id'):{},_0x5ea9a8[_0x37cc0a('0x1b0')]=_0x32cb53,_0x5ea9a8[_0x37cc0a('0x1cb5')]=_0x3e4d08,_0x5d6c89['on'](_0x37cc0a('0x1081'),_0x5ea9a8['onSaveFaxInteraction']),_0x5d6c89['on']('faxInteraction:update',_0x5ea9a8[_0x37cc0a('0x1cb5')]),_0x413bba();function _0x5ea4c3(_0x1e52a8,_0x199108){const _0x58630b=_0x37cc0a;!_0x1e52a8[_0x58630b('0xd8a')]&&!_0x1e52a8['UserId']&&_0x199108&&(_0x5ea9a8[_0x58630b('0x1535')]['waiting']+=0x1),!_0x1e52a8[_0x58630b('0xd8a')]&&_0x1e52a8[_0x58630b('0x10c5')]&&!_0x2e3ca0()[_0x58630b('0x2292')](_0x4fab00,_0x1e52a8['id'])&&(_0x5ea9a8['inbound']['talking']+=0x1,_0x4fab00[_0x58630b('0x1fd0')](_0x1e52a8['id']),!_0x199108&&_0x5ea9a8[_0x58630b('0x1535')][_0x58630b('0x1386')]&&(_0x5ea9a8['inbound'][_0x58630b('0x1386')]-=0x1)),_0x1e52a8['closed']&&_0x1e52a8[_0x58630b('0x10c5')]&&(_0x5ea9a8['inbound']['sumBillable']+=_0x1aaf93()(_0x1e52a8[_0x58630b('0x1a19')])[_0x58630b('0x2357')](_0x1aaf93()(_0x1e52a8[_0x58630b('0x1f5b')]),_0x5ea9a8[_0x58630b('0x272d')][_0x58630b('0x211a')]),_0x5ea9a8[_0x58630b('0x1535')]['sumHoldTime']+=_0x1aaf93()(_0x1e52a8[_0x58630b('0x1f5b')])[_0x58630b('0x2357')](_0x1aaf93()(_0x1e52a8['createdAt']),_0x5ea9a8['config'][_0x58630b('0x211a')]),_0x5ea9a8[_0x58630b('0x1535')][_0x58630b('0x1e47')]+=0x1,!_0x199108&&_0x5ea9a8[_0x58630b('0x1535')]['talking']&&(_0x5ea9a8[_0x58630b('0x1535')][_0x58630b('0x7a4')]-=0x1)),_0x1e52a8[_0x58630b('0xd8a')]&&!_0x1e52a8[_0x58630b('0x10c5')]&&(_0x5ea9a8[_0x58630b('0x1535')][_0x58630b('0x2278')]+=0x1,!_0x199108&&_0x5ea9a8[_0x58630b('0x1535')]['waiting']&&(_0x5ea9a8['inbound']['waiting']-=0x1)),_0x199108&&(_0x5ea9a8[_0x58630b('0x1535')][_0x58630b('0x2263')]+=0x1);}function _0x573ffc(){const _0x15044b=_0x37cc0a;_0x5ea9a8[_0x15044b('0x1535')]['abandonRate']=Math[_0x15044b('0x1758')]((_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x15aa')]+_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x2278')])/(_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x2263')]-_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x7a4')]-_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x1386')])*0x64,-0x2),_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x2320')]=Math[_0x15044b('0x1758')](_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x1e47')]/(_0x5ea9a8['inbound']['total']-_0x5ea9a8[_0x15044b('0x1535')]['talking']-_0x5ea9a8[_0x15044b('0x1535')]['waiting'])*0x64,-0x2),_0x5ea9a8['inbound'][_0x15044b('0x1330')]=_0x1aaf93()[_0x15044b('0xe60')](Math[_0x15044b('0x1758')](_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x1033')]/_0x5ea9a8['inbound']['answered']),_0x5ea9a8[_0x15044b('0x272d')][_0x15044b('0x211a')])['format'](_0x5ea9a8[_0x15044b('0x272d')][_0x15044b('0x26dd')],_0x5ea9a8['config']),_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x177a')]=_0x1aaf93()[_0x15044b('0xe60')](Math[_0x15044b('0x1758')](_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x1f19')]/_0x5ea9a8[_0x15044b('0x1535')][_0x15044b('0x1e47')]),_0x5ea9a8[_0x15044b('0x272d')][_0x15044b('0x211a')])['format'](_0x5ea9a8[_0x15044b('0x272d')]['format'],_0x5ea9a8[_0x15044b('0x272d')]);}function _0x413bba(){const _0x675475=_0x37cc0a;if(Object[_0x675475('0x55e')](_0x5ea9a8[_0x675475('0x2595')])['length']>0x0)for(let _0xb7de88=0x0;_0xb7de88<_0x1992e5[_0x675475('0xf5d')][_0x675475('0x1564')];_0xb7de88+=0x1){if(_0x20c078(_0x1992e5[_0x675475('0xf5d')][_0xb7de88])){const _0x41ce0c=_0x1992e5[_0x675475('0xf5d')][_0xb7de88];_0x5ea4c3(_0x41ce0c,!![]),_0x573ffc();}}}function _0x20c078(_0x2701f5){const _0x37c67d=_0x37cc0a;if(_0x2e3ca0()[_0x37c67d('0x7a2')](_0x5ea9a8[_0x37c67d('0x2595')],{'id':_0x2e3ca0()[_0x37c67d('0xea3')](_0x2701f5[_0x37c67d('0xe22')])}))return!![];return![];}function _0x4e050e(_0xc5fb89){const _0x245cd7=_0x37cc0a,_0x4adb2e=_0x1aaf93()()[_0x245cd7('0xb11')](0x0,!![])[_0x245cd7('0x1627')]('day'),_0x3bd920=_0x1aaf93()()['utcOffset'](0x0,!![])['endOf'](_0x245cd7('0x1efa'));return _0x1aaf93()(_0xc5fb89)[_0x245cd7('0xb11')](0x0,!![])[_0x245cd7('0x17ad')](_0x4adb2e,_0x3bd920);}function _0x32cb53(_0x3947f9){const _0x2f79cd=_0x37cc0a;_0x20c078(_0x3947f9)&&_0x4e050e(_0x3947f9[_0x2f79cd('0x1a4')])&&(_0x5ea4c3(_0x3947f9,!![]),_0x573ffc());}function _0x3e4d08(_0x1cac04){const _0x54161e=_0x37cc0a;_0x20c078(_0x1cac04)&&_0x4e050e(_0x1cac04[_0x54161e('0x1a4')])&&(_0x5ea4c3(_0x1cac04,![]),_0x573ffc());}_0x47230a[_0x37cc0a('0x26a2')](_0x37cc0a('0x4b8'),function(){const _0x137a46=_0x37cc0a;_0x5d6c89[_0x137a46('0x1b9e')](_0x137a46('0x1081')),_0x5d6c89['removeAllListeners'](_0x137a46('0x22e6'));});}const _0x32a0bc=_0x5382ba;_0x69aa84[_0x189033('0x14be')]=['$scope','socket',_0x189033('0xe2'),_0x189033('0x1093')];function _0x69aa84(_0x18926c,_0x392300,_0xfff6df,_0x10c920){const _0x4e9be8=_0x189033,_0x3ac45e=this,_0x17351b=[];_0x3ac45e['config']={'format':_0x4e9be8('0x1836'),'unit':_0x4e9be8('0x1b53'),'trim':![]},_0x3ac45e[_0x4e9be8('0x1535')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':'00:00:00','avgTalkTime':_0x4e9be8('0x172f'),'answerRate':0x0,'abandonRate':0x0},_0x3ac45e[_0x4e9be8('0x1093')]=_0x10c920?_0x2e3ca0()['keyBy'](_0x10c920[_0x4e9be8('0xf5d')]?_0x10c920[_0x4e9be8('0xf5d')]:[],'id'):{},_0x3ac45e[_0x4e9be8('0xf7b')]=_0x1d4de9,_0x3ac45e[_0x4e9be8('0x18e')]=_0x4d2007,_0x392300['on'](_0x4e9be8('0xc43'),_0x3ac45e[_0x4e9be8('0xf7b')]),_0x392300['on']('mailInteraction:update',_0x3ac45e[_0x4e9be8('0x18e')]),_0x39950e();function _0x9eec3a(_0x454b8d,_0x49af8c){const _0x5f1bc5=_0x4e9be8;!_0x454b8d['closed']&&!_0x454b8d[_0x5f1bc5('0x10c5')]&&_0x49af8c&&(_0x3ac45e[_0x5f1bc5('0x1535')][_0x5f1bc5('0x1386')]+=0x1),!_0x454b8d['closed']&&_0x454b8d[_0x5f1bc5('0x10c5')]&&!_0x2e3ca0()[_0x5f1bc5('0x2292')](_0x17351b,_0x454b8d['id'])&&(_0x3ac45e[_0x5f1bc5('0x1535')]['talking']+=0x1,_0x17351b[_0x5f1bc5('0x1fd0')](_0x454b8d['id']),!_0x49af8c&&_0x3ac45e[_0x5f1bc5('0x1535')][_0x5f1bc5('0x1386')]&&(_0x3ac45e['inbound'][_0x5f1bc5('0x1386')]-=0x1)),_0x454b8d['closed']&&_0x454b8d[_0x5f1bc5('0x10c5')]&&(_0x3ac45e[_0x5f1bc5('0x1535')][_0x5f1bc5('0x1f19')]+=_0x1aaf93()(_0x454b8d['closedAt'])[_0x5f1bc5('0x2357')](_0x1aaf93()(_0x454b8d['read1stAt']),_0x3ac45e[_0x5f1bc5('0x272d')]['unit']),_0x3ac45e[_0x5f1bc5('0x1535')][_0x5f1bc5('0x1033')]+=_0x1aaf93()(_0x454b8d['read1stAt'])[_0x5f1bc5('0x2357')](_0x1aaf93()(_0x454b8d[_0x5f1bc5('0x1a4')]),_0x3ac45e[_0x5f1bc5('0x272d')][_0x5f1bc5('0x211a')]),_0x3ac45e[_0x5f1bc5('0x1535')][_0x5f1bc5('0x1e47')]+=0x1,!_0x49af8c&&_0x3ac45e[_0x5f1bc5('0x1535')][_0x5f1bc5('0x7a4')]&&(_0x3ac45e[_0x5f1bc5('0x1535')]['talking']-=0x1)),_0x454b8d['closed']&&!_0x454b8d[_0x5f1bc5('0x10c5')]&&(_0x3ac45e['inbound'][_0x5f1bc5('0x2278')]+=0x1,!_0x49af8c&&_0x3ac45e[_0x5f1bc5('0x1535')][_0x5f1bc5('0x1386')]&&(_0x3ac45e[_0x5f1bc5('0x1535')][_0x5f1bc5('0x1386')]-=0x1)),_0x49af8c&&(_0x3ac45e[_0x5f1bc5('0x1535')][_0x5f1bc5('0x2263')]+=0x1);}function _0x95eb62(){const _0x43336a=_0x4e9be8;_0x3ac45e['inbound'][_0x43336a('0x1efb')]=Math[_0x43336a('0x1758')]((_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x15aa')]+_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x2278')])/(_0x3ac45e[_0x43336a('0x1535')]['total']-_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x7a4')]-_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x1386')])*0x64,-0x2),_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x2320')]=Math['round'](_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x1e47')]/(_0x3ac45e['inbound']['total']-_0x3ac45e['inbound'][_0x43336a('0x7a4')]-_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x1386')])*0x64,-0x2),_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x1330')]=_0x1aaf93()[_0x43336a('0xe60')](Math[_0x43336a('0x1758')](_0x3ac45e['inbound'][_0x43336a('0x1033')]/_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x1e47')]),_0x3ac45e[_0x43336a('0x272d')][_0x43336a('0x211a')])['format'](_0x3ac45e[_0x43336a('0x272d')][_0x43336a('0x26dd')],_0x3ac45e[_0x43336a('0x272d')]),_0x3ac45e[_0x43336a('0x1535')]['avgTalkTime']=_0x1aaf93()[_0x43336a('0xe60')](Math['round'](_0x3ac45e['inbound'][_0x43336a('0x1f19')]/_0x3ac45e[_0x43336a('0x1535')][_0x43336a('0x1e47')]),_0x3ac45e[_0x43336a('0x272d')][_0x43336a('0x211a')])[_0x43336a('0x26dd')](_0x3ac45e[_0x43336a('0x272d')][_0x43336a('0x26dd')],_0x3ac45e[_0x43336a('0x272d')]);}function _0x39950e(){const _0x5a2abb=_0x4e9be8;if(Object[_0x5a2abb('0x55e')](_0x3ac45e[_0x5a2abb('0x1093')])[_0x5a2abb('0x1564')]>0x0)for(let _0x2edb4b=0x0;_0x2edb4b<_0xfff6df[_0x5a2abb('0xf5d')][_0x5a2abb('0x1564')];_0x2edb4b+=0x1){if(_0x35e277(_0xfff6df[_0x5a2abb('0xf5d')][_0x2edb4b])){const _0x314ce8=_0xfff6df[_0x5a2abb('0xf5d')][_0x2edb4b];_0x9eec3a(_0x314ce8,!![]),_0x95eb62();}}}function _0x35e277(_0xa7526f){const _0x312ef5=_0x4e9be8;if(_0x2e3ca0()[_0x312ef5('0x7a2')](_0x3ac45e[_0x312ef5('0x1093')],{'id':_0x2e3ca0()[_0x312ef5('0xea3')](_0xa7526f[_0x312ef5('0x1cd')])}))return!![];return![];}function _0x4257e8(_0x39f3d0){const _0x4fd308=_0x4e9be8,_0x1013fe=_0x1aaf93()()['utcOffset'](0x0,!![])[_0x4fd308('0x1627')](_0x4fd308('0x1efa')),_0x4eb93a=_0x1aaf93()()['utcOffset'](0x0,!![])[_0x4fd308('0x3b3')](_0x4fd308('0x1efa'));return _0x1aaf93()(_0x39f3d0)['utcOffset'](0x0,!![])[_0x4fd308('0x17ad')](_0x1013fe,_0x4eb93a);}function _0x1d4de9(_0x1ea813){const _0x16cf25=_0x4e9be8;_0x35e277(_0x1ea813)&&_0x4257e8(_0x1ea813[_0x16cf25('0x1a4')])&&(_0x9eec3a(_0x1ea813,!![]),_0x95eb62());}function _0x4d2007(_0x70ef6b){const _0x4c64dc=_0x4e9be8;_0x35e277(_0x70ef6b)&&_0x4257e8(_0x70ef6b[_0x4c64dc('0x1a4')])&&(_0x9eec3a(_0x70ef6b,![]),_0x95eb62());}_0x18926c[_0x4e9be8('0x26a2')](_0x4e9be8('0x4b8'),function(){const _0x563218=_0x4e9be8;_0x392300[_0x563218('0x1b9e')](_0x563218('0xc43')),_0x392300[_0x563218('0x1b9e')](_0x563218('0xc75'));});}const _0x4f82fd=_0x69aa84;_0x21863f[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1556'),_0x189033('0x13f9'),'openchannelAccounts'];function _0x21863f(_0x52b705,_0x58d0c4,_0x3cd25e,_0x3c7b31){const _0xc0f3ec=_0x189033,_0x2811d2=this,_0x14a9bb=[];_0x2811d2[_0xc0f3ec('0x272d')]={'format':_0xc0f3ec('0x1836'),'unit':_0xc0f3ec('0x1b53'),'trim':![]},_0x2811d2[_0xc0f3ec('0x1535')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0xc0f3ec('0x172f'),'avgTalkTime':_0xc0f3ec('0x172f'),'answerRate':0x0,'abandonRate':0x0},_0x2811d2[_0xc0f3ec('0x1952')]=_0x3c7b31?_0x2e3ca0()[_0xc0f3ec('0x24db')](_0x3c7b31[_0xc0f3ec('0xf5d')]?_0x3c7b31['rows']:[],'id'):{},_0x2811d2[_0xc0f3ec('0x899')]=_0x460539,_0x2811d2[_0xc0f3ec('0x6e4')]=_0x43c31a,_0x58d0c4['on'](_0xc0f3ec('0x14dc'),_0x2811d2[_0xc0f3ec('0x899')]),_0x58d0c4['on'](_0xc0f3ec('0x775'),_0x2811d2['onUpdateOpenchannelInteraction']),_0x1c06b6();function _0x36b592(_0x52e052,_0x12664d){const _0x8be790=_0xc0f3ec;!_0x52e052[_0x8be790('0xd8a')]&&!_0x52e052[_0x8be790('0x10c5')]&&_0x12664d&&(_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x1386')]+=0x1),!_0x52e052[_0x8be790('0xd8a')]&&_0x52e052[_0x8be790('0x10c5')]&&!_0x2e3ca0()[_0x8be790('0x2292')](_0x14a9bb,_0x52e052['id'])&&(_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x7a4')]+=0x1,_0x14a9bb[_0x8be790('0x1fd0')](_0x52e052['id']),!_0x12664d&&_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x1386')]&&(_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x1386')]-=0x1)),_0x52e052[_0x8be790('0xd8a')]&&_0x52e052[_0x8be790('0x10c5')]&&(_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x1f19')]+=_0x1aaf93()(_0x52e052[_0x8be790('0x1a19')])[_0x8be790('0x2357')](_0x1aaf93()(_0x52e052[_0x8be790('0x1f5b')]),_0x2811d2[_0x8be790('0x272d')]['unit']),_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x1033')]+=_0x1aaf93()(_0x52e052[_0x8be790('0x1f5b')])['diff'](_0x1aaf93()(_0x52e052[_0x8be790('0x1a4')]),_0x2811d2[_0x8be790('0x272d')][_0x8be790('0x211a')]),_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x1e47')]+=0x1,!_0x12664d&&_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x7a4')]&&(_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x7a4')]-=0x1)),_0x52e052['closed']&&!_0x52e052[_0x8be790('0x10c5')]&&(_0x2811d2['inbound'][_0x8be790('0x2278')]+=0x1,!_0x12664d&&_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x1386')]&&(_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x1386')]-=0x1)),_0x12664d&&(_0x2811d2[_0x8be790('0x1535')][_0x8be790('0x2263')]+=0x1);}function _0x3e5b3e(){const _0x22b2d0=_0xc0f3ec;_0x2811d2['inbound']['abandonRate']=Math[_0x22b2d0('0x1758')]((_0x2811d2[_0x22b2d0('0x1535')]['abandoned']+_0x2811d2[_0x22b2d0('0x1535')]['unmanaged'])/(_0x2811d2[_0x22b2d0('0x1535')][_0x22b2d0('0x2263')]-_0x2811d2[_0x22b2d0('0x1535')][_0x22b2d0('0x7a4')]-_0x2811d2[_0x22b2d0('0x1535')][_0x22b2d0('0x1386')])*0x64,-0x2),_0x2811d2['inbound'][_0x22b2d0('0x2320')]=Math['round'](_0x2811d2['inbound']['answered']/(_0x2811d2[_0x22b2d0('0x1535')][_0x22b2d0('0x2263')]-_0x2811d2[_0x22b2d0('0x1535')]['talking']-_0x2811d2[_0x22b2d0('0x1535')]['waiting'])*0x64,-0x2),_0x2811d2[_0x22b2d0('0x1535')]['avgHoldTime']=_0x1aaf93()[_0x22b2d0('0xe60')](Math[_0x22b2d0('0x1758')](_0x2811d2[_0x22b2d0('0x1535')][_0x22b2d0('0x1033')]/_0x2811d2[_0x22b2d0('0x1535')][_0x22b2d0('0x1e47')]),_0x2811d2[_0x22b2d0('0x272d')][_0x22b2d0('0x211a')])[_0x22b2d0('0x26dd')](_0x2811d2['config'][_0x22b2d0('0x26dd')],_0x2811d2['config']),_0x2811d2[_0x22b2d0('0x1535')][_0x22b2d0('0x177a')]=_0x1aaf93()['duration'](Math[_0x22b2d0('0x1758')](_0x2811d2['inbound'][_0x22b2d0('0x1f19')]/_0x2811d2['inbound'][_0x22b2d0('0x1e47')]),_0x2811d2[_0x22b2d0('0x272d')][_0x22b2d0('0x211a')])[_0x22b2d0('0x26dd')](_0x2811d2['config']['format'],_0x2811d2[_0x22b2d0('0x272d')]);}function _0x1c06b6(){const _0x231ca4=_0xc0f3ec;if(Object['keys'](_0x2811d2[_0x231ca4('0x1952')])[_0x231ca4('0x1564')]>0x0)for(let _0x7550a7=0x0;_0x7550a7<_0x3cd25e['rows'][_0x231ca4('0x1564')];_0x7550a7+=0x1){if(_0x2e99a0(_0x3cd25e['rows'][_0x7550a7])){const _0x5cdd79=_0x3cd25e[_0x231ca4('0xf5d')][_0x7550a7];_0x36b592(_0x5cdd79,!![]),_0x3e5b3e();}}}function _0x2e99a0(_0x58e4a3){const _0xe48e26=_0xc0f3ec;if(_0x2e3ca0()['some'](_0x2811d2[_0xe48e26('0x1952')],{'id':_0x2e3ca0()[_0xe48e26('0xea3')](_0x58e4a3[_0xe48e26('0x1061')])}))return!![];return![];}function _0x43b16b(_0x326746){const _0x501c7a=_0xc0f3ec,_0x3e4513=_0x1aaf93()()['utcOffset'](0x0,!![])[_0x501c7a('0x1627')](_0x501c7a('0x1efa')),_0x50d769=_0x1aaf93()()['utcOffset'](0x0,!![])['endOf'](_0x501c7a('0x1efa'));return _0x1aaf93()(_0x326746)['utcOffset'](0x0,!![])['isBetween'](_0x3e4513,_0x50d769);}function _0x460539(_0x1e7aa2){_0x2e99a0(_0x1e7aa2)&&_0x43b16b(_0x1e7aa2['createdAt'])&&(_0x36b592(_0x1e7aa2,!![]),_0x3e5b3e());}function _0x43c31a(_0x29310e){const _0x13da61=_0xc0f3ec;_0x2e99a0(_0x29310e)&&_0x43b16b(_0x29310e[_0x13da61('0x1a4')])&&(_0x36b592(_0x29310e,![]),_0x3e5b3e());}_0x52b705[_0xc0f3ec('0x26a2')]('$destroy',function(){const _0xcbf26f=_0xc0f3ec;_0x58d0c4[_0xcbf26f('0x1b9e')](_0xcbf26f('0x14dc')),_0x58d0c4['removeAllListeners'](_0xcbf26f('0x775'));});}const _0x101d15=_0x21863f;_0x4fc036[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1556'),'smsInteractions',_0x189033('0x197c')];function _0x4fc036(_0x25ff09,_0x1db30e,_0x30eec3,_0x98e138){const _0x393b7e=_0x189033,_0x1cc250=this,_0x25709f=[];_0x1cc250['config']={'format':_0x393b7e('0x1836'),'unit':_0x393b7e('0x1b53'),'trim':![]},_0x1cc250[_0x393b7e('0x1535')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':_0x393b7e('0x172f'),'avgTalkTime':_0x393b7e('0x172f'),'answerRate':0x0,'abandonRate':0x0},_0x1cc250['smsAccounts']=_0x98e138?_0x2e3ca0()[_0x393b7e('0x24db')](_0x98e138['rows']?_0x98e138[_0x393b7e('0xf5d')]:[],'id'):{},_0x1cc250['onSaveSmsInteraction']=_0x1dd6fe,_0x1cc250[_0x393b7e('0x7a0')]=_0x4401b0,_0x1db30e['on'](_0x393b7e('0x25e4'),_0x1cc250[_0x393b7e('0xba4')]),_0x1db30e['on'](_0x393b7e('0x4ae'),_0x1cc250[_0x393b7e('0x7a0')]),_0x4a54bd();function _0x6b74ca(_0x21cf28,_0x2dbd5f){const _0x29fcf2=_0x393b7e;!_0x21cf28[_0x29fcf2('0xd8a')]&&!_0x21cf28[_0x29fcf2('0x10c5')]&&_0x2dbd5f&&(_0x1cc250[_0x29fcf2('0x1535')][_0x29fcf2('0x1386')]+=0x1),!_0x21cf28[_0x29fcf2('0xd8a')]&&_0x21cf28['UserId']&&!_0x2e3ca0()[_0x29fcf2('0x2292')](_0x25709f,_0x21cf28['id'])&&(_0x1cc250[_0x29fcf2('0x1535')][_0x29fcf2('0x7a4')]+=0x1,_0x25709f[_0x29fcf2('0x1fd0')](_0x21cf28['id']),!_0x2dbd5f&&_0x1cc250['inbound'][_0x29fcf2('0x1386')]&&(_0x1cc250['inbound']['waiting']-=0x1)),_0x21cf28[_0x29fcf2('0xd8a')]&&_0x21cf28['UserId']&&(_0x1cc250['inbound'][_0x29fcf2('0x1f19')]+=_0x1aaf93()(_0x21cf28[_0x29fcf2('0x1a19')])['diff'](_0x1aaf93()(_0x21cf28[_0x29fcf2('0x1f5b')]),_0x1cc250[_0x29fcf2('0x272d')][_0x29fcf2('0x211a')]),_0x1cc250['inbound'][_0x29fcf2('0x1033')]+=_0x1aaf93()(_0x21cf28[_0x29fcf2('0x1f5b')])[_0x29fcf2('0x2357')](_0x1aaf93()(_0x21cf28['createdAt']),_0x1cc250[_0x29fcf2('0x272d')][_0x29fcf2('0x211a')]),_0x1cc250[_0x29fcf2('0x1535')][_0x29fcf2('0x1e47')]+=0x1,!_0x2dbd5f&&_0x1cc250['inbound'][_0x29fcf2('0x7a4')]&&(_0x1cc250['inbound']['talking']-=0x1)),_0x21cf28[_0x29fcf2('0xd8a')]&&!_0x21cf28[_0x29fcf2('0x10c5')]&&(_0x1cc250[_0x29fcf2('0x1535')][_0x29fcf2('0x2278')]+=0x1,!_0x2dbd5f&&_0x1cc250[_0x29fcf2('0x1535')][_0x29fcf2('0x1386')]&&(_0x1cc250['inbound'][_0x29fcf2('0x1386')]-=0x1)),_0x2dbd5f&&(_0x1cc250[_0x29fcf2('0x1535')][_0x29fcf2('0x2263')]+=0x1);}function _0x446a4c(){const _0x56fd0a=_0x393b7e;_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x1efb')]=Math[_0x56fd0a('0x1758')]((_0x1cc250['inbound'][_0x56fd0a('0x15aa')]+_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x2278')])/(_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x2263')]-_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x7a4')]-_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x1386')])*0x64,-0x2),_0x1cc250['inbound'][_0x56fd0a('0x2320')]=Math[_0x56fd0a('0x1758')](_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x1e47')]/(_0x1cc250[_0x56fd0a('0x1535')]['total']-_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x7a4')]-_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x1386')])*0x64,-0x2),_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x1330')]=_0x1aaf93()[_0x56fd0a('0xe60')](Math[_0x56fd0a('0x1758')](_0x1cc250[_0x56fd0a('0x1535')]['sumHoldTime']/_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x1e47')]),_0x1cc250['config'][_0x56fd0a('0x211a')])['format'](_0x1cc250['config']['format'],_0x1cc250[_0x56fd0a('0x272d')]),_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x177a')]=_0x1aaf93()['duration'](Math[_0x56fd0a('0x1758')](_0x1cc250[_0x56fd0a('0x1535')][_0x56fd0a('0x1f19')]/_0x1cc250['inbound']['answered']),_0x1cc250['config'][_0x56fd0a('0x211a')])[_0x56fd0a('0x26dd')](_0x1cc250[_0x56fd0a('0x272d')][_0x56fd0a('0x26dd')],_0x1cc250[_0x56fd0a('0x272d')]);}function _0x4a54bd(){const _0x41abf6=_0x393b7e;if(Object[_0x41abf6('0x55e')](_0x1cc250[_0x41abf6('0x197c')])['length']>0x0)for(let _0x5e3d4c=0x0;_0x5e3d4c<_0x30eec3[_0x41abf6('0xf5d')]['length'];_0x5e3d4c+=0x1){if(_0x3455d5(_0x30eec3[_0x41abf6('0xf5d')][_0x5e3d4c])){const _0x14bf06=_0x30eec3[_0x41abf6('0xf5d')][_0x5e3d4c];_0x6b74ca(_0x14bf06,!![]),_0x446a4c();}}}function _0x3455d5(_0x24b64d){const _0x37b162=_0x393b7e;if(_0x2e3ca0()[_0x37b162('0x7a2')](_0x1cc250[_0x37b162('0x197c')],{'id':_0x2e3ca0()[_0x37b162('0xea3')](_0x24b64d[_0x37b162('0x1f4f')])}))return!![];return![];}function _0x2b3b59(_0x36dddc){const _0x3bc63f=_0x393b7e,_0x60a8ad=_0x1aaf93()()[_0x3bc63f('0xb11')](0x0,!![])[_0x3bc63f('0x1627')](_0x3bc63f('0x1efa')),_0x3b9e5d=_0x1aaf93()()[_0x3bc63f('0xb11')](0x0,!![])[_0x3bc63f('0x3b3')](_0x3bc63f('0x1efa'));return _0x1aaf93()(_0x36dddc)[_0x3bc63f('0xb11')](0x0,!![])[_0x3bc63f('0x17ad')](_0x60a8ad,_0x3b9e5d);}function _0x1dd6fe(_0x483393){_0x3455d5(_0x483393)&&_0x2b3b59(_0x483393['createdAt'])&&(_0x6b74ca(_0x483393,!![]),_0x446a4c());}function _0x4401b0(_0x4df7c4){_0x3455d5(_0x4df7c4)&&_0x2b3b59(_0x4df7c4['createdAt'])&&(_0x6b74ca(_0x4df7c4,![]),_0x446a4c());}_0x25ff09['$on']('$destroy',function(){const _0x176de5=_0x393b7e;_0x1db30e[_0x176de5('0x1b9e')](_0x176de5('0x25e4')),_0x1db30e[_0x176de5('0x1b9e')](_0x176de5('0x4ae'));});}const _0x1ee2cf=_0x4fc036;_0x4db37f['$inject']=[_0x189033('0x938'),_0x189033('0xba1'),_0x189033('0xace')],_0x428aa8[_0x189033('0x14be')]=['$q'],_0x1385e9[_0x189033('0x14be')]=['$q'];function _0x1385e9(_0x1b413b){const _0x43d582=[],_0x212b73=function(){const _0x387ac8=a0_0x4e0a,_0x4da268=_0x43d582[0x0],_0x55d249={'waiting':0x0,'talking':0x0,'pTalking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':'00:00:00','avgTalkTime':_0x387ac8('0x172f'),'answerRate':0x0,'abandonRate':0x0,'originated':0x0,'outboundDropCallsDayCallersExit':0x0,'outboundDropCallsDayTimeout':0x0};_0x2e3ca0()[_0x387ac8('0x15d0')](_0x4da268['queues'],function(_0x4161b0,_0xcefc6a){const _0x511353=_0x387ac8;_0x4da268['rpcQueues'][_0xcefc6a]&&(_0x55d249[_0x511353('0x1386')]+=_0x4da268['rpcQueues'][_0xcefc6a][_0x511353('0x1386')]||0x0,_0x55d249[_0x511353('0x7a4')]+=(_0x4da268[_0x511353('0x1a10')][_0xcefc6a][_0x511353('0x7a4')]||0x0)+(_0x4da268[_0x511353('0x1a10')][_0xcefc6a][_0x511353('0x17f2')]||0x0),_0x55d249[_0x511353('0x1e47')]+=_0x4da268[_0x511353('0x1a10')][_0xcefc6a][_0x511353('0x1e47')]||0x0,_0x55d249[_0x511353('0x15aa')]+=_0x4da268[_0x511353('0x1a10')][_0xcefc6a][_0x511353('0x15aa')]||0x0,_0x55d249['sumHoldTime']+=_0x4da268[_0x511353('0x1a10')][_0xcefc6a][_0x511353('0x1033')]||0x0,_0x55d249['sumBillable']+=_0x4da268[_0x511353('0x1a10')][_0xcefc6a][_0x511353('0x1f19')]||0x0,_0x55d249[_0x511353('0x2263')]+=_0x4da268[_0x511353('0x1a10')][_0xcefc6a][_0x511353('0x2263')]||0x0,_0x55d249['originated']+=_0x4da268[_0x511353('0x1a10')][_0xcefc6a][_0x511353('0x1a95')]||0x0,_0x55d249[_0x511353('0x237b')]+=_0x4da268[_0x511353('0x1a10')][_0xcefc6a]['outboundDropCallsDayCallersExit']||0x0,_0x55d249['outboundDropCallsDayTimeout']+=_0x4da268[_0x511353('0x1a10')][_0xcefc6a][_0x511353('0xf14')]||0x0);});const _0x2b24a3=_0x55d249['total']-_0x55d249[_0x387ac8('0x1e47')]-_0x55d249[_0x387ac8('0x15aa')];_0x55d249['unmanaged']=_0x2b24a3>0x0?_0x2b24a3:0x0,_0x55d249[_0x387ac8('0x1330')]=Math[_0x387ac8('0x1758')](_0x55d249[_0x387ac8('0x2263')]>0x0?_0x55d249[_0x387ac8('0x1033')]/_0x55d249[_0x387ac8('0x2263')]:0x0),_0x55d249['avgHoldTime']=new Date(_0x55d249[_0x387ac8('0x1330')]*0x3e8)['toISOString']()[_0x387ac8('0x1f9e')](0xb,0x8),_0x55d249[_0x387ac8('0x177a')]=Math[_0x387ac8('0x1758')](_0x55d249[_0x387ac8('0x1e47')]>0x0?_0x55d249[_0x387ac8('0x1f19')]/_0x55d249[_0x387ac8('0x1e47')]:0x0),_0x55d249[_0x387ac8('0x177a')]=new Date(_0x55d249[_0x387ac8('0x177a')]*0x3e8)[_0x387ac8('0x24fb')]()[_0x387ac8('0x1f9e')](0xb,0x8),_0x55d249[_0x387ac8('0x2320')]=Math[_0x387ac8('0x1758')]((_0x55d249['total']>0x0?_0x55d249[_0x387ac8('0x1e47')]/_0x55d249[_0x387ac8('0x2263')]*0x64:0x0)*Math[_0x387ac8('0x2682')](0xa,0x1))/Math['pow'](0xa,0x1),_0x55d249[_0x387ac8('0x1efb')]=Math['round']((_0x55d249['total']>0x0?_0x55d249[_0x387ac8('0x15aa')]/_0x55d249[_0x387ac8('0x2263')]*0x64:0x0)*Math[_0x387ac8('0x2682')](0xa,0x1))/Math[_0x387ac8('0x2682')](0xa,0x1),_0x55d249[_0x387ac8('0x5db')]=Math['round']((_0x55d249[_0x387ac8('0x2263')]>0x0?_0x55d249[_0x387ac8('0xf14')]/_0x55d249['total']*0x64:0x0)*Math[_0x387ac8('0x2682')](0xa,0x1))/Math[_0x387ac8('0x2682')](0xa,0x1),_0x55d249['outboundAbandonRate']=Math['round']((_0x55d249[_0x387ac8('0x2263')]>0x0?_0x55d249[_0x387ac8('0x237b')]/_0x55d249[_0x387ac8('0x2263')]*0x64:0x0)*Math[_0x387ac8('0x2682')](0xa,0x1))/Math[_0x387ac8('0x2682')](0xa,0x1),_0x55d249[_0x387ac8('0x1c01')]=0x64-_0x55d249[_0x387ac8('0x5db')]-_0x55d249['outboundAbandonRate']>0x0&&(_0x55d249[_0x387ac8('0x2263')]||0x0>0x0)?0x64-_0x55d249[_0x387ac8('0x5db')]-_0x55d249['outboundAbandonRate']:0x0,_0x43d582['shift'](),_0x4da268[_0x387ac8('0x448')][_0x387ac8('0xed7')](_0x55d249),_0x43d582[_0x387ac8('0x1564')]>0x0&&_0x212b73();};return function(_0x1b046a){const _0x5f38df=a0_0x4e0a,_0x3ed334=_0x1b413b[_0x5f38df('0x448')]();return _0x43d582['push']({'queues':_0x1b046a[_0x5f38df('0x2da')],'rpcQueues':_0x1b046a[_0x5f38df('0x1a10')],'defer':_0x3ed334}),_0x43d582[_0x5f38df('0x1564')]===0x1&&_0x212b73(),_0x3ed334['promise'];};}function _0x428aa8(_0x1f5ef4){const _0x14dc44=[],_0x14c4a5=function(){const _0x25535a=a0_0x4e0a,_0x2756df=_0x14dc44[0x0],_0x4678f0={'originated':0x0,'limitCalls':0x0};_0x2e3ca0()[_0x25535a('0x15d0')](_0x2756df['rpcCampaigns'],function(_0x432c2e,_0x117674){const _0x66ece1=_0x25535a;_0x2756df['rpcCampaigns'][_0x117674]&&(_0x4678f0[_0x66ece1('0x1a95')]+=_0x2756df[_0x66ece1('0x4fc')][_0x117674][_0x66ece1('0x1a95')]||0x0,_0x4678f0[_0x66ece1('0x1de0')]+=_0x2756df[_0x66ece1('0x4fc')][_0x117674][_0x66ece1('0x1de0')]||0x0);}),_0x14dc44['shift'](),_0x2756df[_0x25535a('0x448')][_0x25535a('0xed7')](_0x4678f0),_0x14dc44[_0x25535a('0x1564')]>0x0&&_0x14c4a5();};return function(_0xfc81eb){const _0x2ac346=a0_0x4e0a,_0x394665=_0x1f5ef4['defer']();return _0x14dc44['push']({'rpcCampaigns':_0xfc81eb[_0x2ac346('0x4fc')],'defer':_0x394665}),_0x14dc44['length']===0x1&&_0x14c4a5(),_0x394665[_0x2ac346('0x1883')];};}function _0x58c0c5(){return function(_0x4c77c3){const _0x3c9e66=a0_0x4e0a;return new Date(_0x4c77c3*0x3e8)['toISOString']()[_0x3c9e66('0x1f9e')](0xb,0x8);};}function _0x4db37f(_0x2104c3,_0x25774f,_0x103844){const _0x36cb1c=_0x189033,_0x454885=this;_0x454885[_0x36cb1c('0xace')]=_0x103844,_0x454885[_0x36cb1c('0x1dd2')]=_0x49f5b8;function _0x49f5b8(){const _0x5a0d5a=_0x36cb1c;_0x454885[_0x5a0d5a('0x24f3')]=_0x25774f[_0x5a0d5a('0xca1')](_0x5a0d5a('0xc96'))?_0x25774f[_0x5a0d5a('0x5e3')](0x65):!![];if(_0x454885[_0x5a0d5a('0x24f3')]){const _0x4fe2d6=_0x2104c3[_0x5a0d5a('0xb24')][_0x5a0d5a('0x60a')];switch(_0x4fe2d6){case'app.dashboards.general':_0x210437();break;case _0x5a0d5a('0x13ed'):_0x454885[_0x5a0d5a('0x517')]=0x0;break;case _0x5a0d5a('0x285e'):_0x454885['selectedTab']=0x1;break;case _0x5a0d5a('0xb9c'):_0x454885[_0x5a0d5a('0x517')]=0x2;break;case _0x5a0d5a('0xabb'):_0x454885[_0x5a0d5a('0x517')]=0x3;break;case _0x5a0d5a('0x129d'):_0x454885[_0x5a0d5a('0x517')]=0x4;break;case _0x5a0d5a('0xaf3'):_0x454885[_0x5a0d5a('0x517')]=0x5;break;case _0x5a0d5a('0x266e'):_0x454885['selectedTab']=0x6;break;case _0x5a0d5a('0xdc'):_0x454885[_0x5a0d5a('0x517')]=0x7;break;}}}function _0x210437(){const _0x4f1441=_0x36cb1c,_0xaeb71=[];_0x454885[_0x4f1441('0xace')][_0x4f1441('0xcf2')]&&_0xaeb71['push'](_0x4f1441('0x13ed')),_0x454885[_0x4f1441('0xace')][_0x4f1441('0x228a')]&&_0xaeb71['push'](_0x4f1441('0x285e')),_0x454885['license'][_0x4f1441('0x24e')]&&_0xaeb71[_0x4f1441('0x1fd0')](_0x4f1441('0xb9c')),_0x454885[_0x4f1441('0xace')][_0x4f1441('0x129f')]&&_0xaeb71['push'](_0x4f1441('0xabb')),_0x454885[_0x4f1441('0xace')][_0x4f1441('0xf9d')]&&_0xaeb71[_0x4f1441('0x1fd0')](_0x4f1441('0x129d')),_0x454885[_0x4f1441('0xace')][_0x4f1441('0x1261')]&&_0xaeb71[_0x4f1441('0x1fd0')]('app.dashboards.general.openchannel'),_0x454885[_0x4f1441('0xace')][_0x4f1441('0x23e9')]&&_0xaeb71[_0x4f1441('0x1fd0')](_0x4f1441('0x266e')),_0x454885[_0x4f1441('0xace')][_0x4f1441('0x16e7')]&&_0xaeb71[_0x4f1441('0x1fd0')](_0x4f1441('0xdc'));if(_0xaeb71['length']>0x0)_0x2104c3['go'](_0x2e3ca0()[_0x4f1441('0x2f5')](_0xaeb71));}}_0x17b35c['$inject']=[_0x189033('0x7a5'),_0x189033('0x1556'),_0x189033('0x9b3'),_0x189033('0x1a10'),'outbound','initializeRealtimeQueue'];function _0x17b35c(_0x13afc2,_0x13a151,_0x330483,_0x5d74d9,_0x5e6586,_0x514846){const _0x146c8c=_0x189033,_0x1cba39=this;_0x1cba39['inboundQueues']=_0x330483?_0x2e3ca0()[_0x146c8c('0x24db')](_0x330483['rows']?_0x330483[_0x146c8c('0xf5d')]:[],'id'):{},_0x1cba39[_0x146c8c('0x1a10')]=_0x5d74d9?_0x2e3ca0()['keyBy'](_0x5d74d9['rows']?_0x5d74d9[_0x146c8c('0xf5d')]:[],'id'):{},_0x1cba39[_0x146c8c('0x1535')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':'00:00:00','avgTalkTime':_0x146c8c('0x172f'),'answerRate':0x0,'abandonRate':0x0},_0x1cba39[_0x146c8c('0x17cd')]=_0x5e6586||{'answered':0x0,'sumBillable':0x0,'sumDuration':0x0,'sumHoldTime':0x0,'total':0x0},_0x1cba39[_0x146c8c('0x69a')]=_0x4b7246,_0x1cba39[_0x146c8c('0x5b3')]=_0x5abd9e,_0x13a151['on'](_0x146c8c('0x1df'),_0x1cba39[_0x146c8c('0x69a')]),_0x13a151['on']('voice_outbound:save',_0x1cba39['onSaveOutbound']),_0x31abeb();function _0x31abeb(){const _0x4251ec=_0x146c8c;_0x514846({'queues':_0x1cba39[_0x4251ec('0x9b3')],'rpcQueues':_0x1cba39['rpcQueues']})[_0x4251ec('0x683')](function(_0x44b099){_0x1cba39['inbound']=_0x44b099;});}function _0x4b7246(_0x4330c7){const _0x484ab1=_0x146c8c;_0x1cba39[_0x484ab1('0x9b3')][_0x4330c7['id']]&&(_0x1cba39[_0x484ab1('0x1a10')][_0x4330c7['id']]&&(_0x1cba39['rpcQueues'][_0x4330c7['id']]=_0x4330c7,_0x31abeb()));}function _0x5abd9e(_0x245b55){_0x1cba39['outbound']=_0x245b55;}_0x13afc2[_0x146c8c('0x26a2')](_0x146c8c('0x4b8'),function(){const _0x2e0a23=_0x146c8c;_0x13a151[_0x2e0a23('0x1b9e')](_0x2e0a23('0x1df')),_0x13a151[_0x2e0a23('0x1b9e')]('voice_outbound:save');});}const _0x4b19ce=_0x17b35c;_0x31955f[_0x189033('0x14be')]=['$scope',_0x189033('0x1556'),_0x189033('0x2740'),_0x189033('0x263c')];function _0x31955f(_0x7875b6,_0x16efc5,_0x465cac,_0x54e1a2){const _0x1ff15b=_0x189033,_0x557d41=this,_0x358767=[];_0x557d41[_0x1ff15b('0x272d')]={'format':_0x1ff15b('0x1836'),'unit':_0x1ff15b('0x1b53'),'trim':![]},_0x557d41[_0x1ff15b('0x1535')]={'waiting':0x0,'talking':0x0,'answered':0x0,'abandoned':0x0,'unmanaged':0x0,'sumHoldTime':0x0,'sumBillable':0x0,'total':0x0,'avgHoldTime':'00:00:00','avgTalkTime':'00:00:00','answerRate':0x0,'abandonRate':0x0},_0x557d41['whatsappAccounts']=_0x54e1a2?_0x2e3ca0()[_0x1ff15b('0x24db')](_0x54e1a2['rows']?_0x54e1a2[_0x1ff15b('0xf5d')]:[],'id'):{},_0x557d41[_0x1ff15b('0x1850')]=_0x57e468,_0x557d41['onUpdateWhatsappInteraction']=_0x1142af,_0x16efc5['on'](_0x1ff15b('0x42b'),_0x557d41[_0x1ff15b('0x1850')]),_0x16efc5['on']('whatsappInteraction:update',_0x557d41['onUpdateWhatsappInteraction']),_0x5547bd();function _0x4ed60b(_0x65a700,_0x501288){const _0x52325a=_0x1ff15b;!_0x65a700[_0x52325a('0xd8a')]&&!_0x65a700[_0x52325a('0x10c5')]&&_0x501288&&(_0x557d41[_0x52325a('0x1535')]['waiting']+=0x1),!_0x65a700[_0x52325a('0xd8a')]&&_0x65a700[_0x52325a('0x10c5')]&&!_0x2e3ca0()['includes'](_0x358767,_0x65a700['id'])&&(_0x557d41[_0x52325a('0x1535')][_0x52325a('0x7a4')]+=0x1,_0x358767['push'](_0x65a700['id']),!_0x501288&&_0x557d41[_0x52325a('0x1535')][_0x52325a('0x1386')]&&(_0x557d41[_0x52325a('0x1535')][_0x52325a('0x1386')]-=0x1)),_0x65a700[_0x52325a('0xd8a')]&&_0x65a700[_0x52325a('0x10c5')]&&(_0x557d41[_0x52325a('0x1535')][_0x52325a('0x1f19')]+=_0x1aaf93()(_0x65a700['closedAt'])[_0x52325a('0x2357')](_0x1aaf93()(_0x65a700[_0x52325a('0x1f5b')]),_0x557d41['config'][_0x52325a('0x211a')]),_0x557d41[_0x52325a('0x1535')][_0x52325a('0x1033')]+=_0x1aaf93()(_0x65a700[_0x52325a('0x1f5b')])[_0x52325a('0x2357')](_0x1aaf93()(_0x65a700['createdAt']),_0x557d41[_0x52325a('0x272d')][_0x52325a('0x211a')]),_0x557d41[_0x52325a('0x1535')]['answered']+=0x1,!_0x501288&&_0x557d41[_0x52325a('0x1535')]['talking']&&(_0x557d41[_0x52325a('0x1535')][_0x52325a('0x7a4')]-=0x1)),_0x65a700[_0x52325a('0xd8a')]&&!_0x65a700['UserId']&&(_0x557d41[_0x52325a('0x1535')][_0x52325a('0x2278')]+=0x1,!_0x501288&&_0x557d41[_0x52325a('0x1535')][_0x52325a('0x1386')]&&(_0x557d41[_0x52325a('0x1535')][_0x52325a('0x1386')]-=0x1)),_0x501288&&(_0x557d41[_0x52325a('0x1535')][_0x52325a('0x2263')]+=0x1);}function _0x574533(){const _0x5d12b1=_0x1ff15b;_0x557d41['inbound'][_0x5d12b1('0x1efb')]=Math[_0x5d12b1('0x1758')]((_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x15aa')]+_0x557d41['inbound'][_0x5d12b1('0x2278')])/(_0x557d41['inbound'][_0x5d12b1('0x2263')]-_0x557d41['inbound']['talking']-_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x1386')])*0x64,-0x2),_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x2320')]=Math[_0x5d12b1('0x1758')](_0x557d41[_0x5d12b1('0x1535')]['answered']/(_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x2263')]-_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x7a4')]-_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x1386')])*0x64,-0x2),_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x1330')]=_0x1aaf93()[_0x5d12b1('0xe60')](Math[_0x5d12b1('0x1758')](_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x1033')]/_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x1e47')]),_0x557d41[_0x5d12b1('0x272d')][_0x5d12b1('0x211a')])[_0x5d12b1('0x26dd')](_0x557d41[_0x5d12b1('0x272d')][_0x5d12b1('0x26dd')],_0x557d41[_0x5d12b1('0x272d')]),_0x557d41[_0x5d12b1('0x1535')]['avgTalkTime']=_0x1aaf93()[_0x5d12b1('0xe60')](Math[_0x5d12b1('0x1758')](_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x1f19')]/_0x557d41[_0x5d12b1('0x1535')][_0x5d12b1('0x1e47')]),_0x557d41['config']['unit'])[_0x5d12b1('0x26dd')](_0x557d41['config'][_0x5d12b1('0x26dd')],_0x557d41[_0x5d12b1('0x272d')]);}function _0x5547bd(){const _0x1a27bf=_0x1ff15b;if(Object[_0x1a27bf('0x55e')](_0x557d41['whatsappAccounts'])[_0x1a27bf('0x1564')]>0x0)for(let _0x10be3d=0x0;_0x10be3d<_0x465cac[_0x1a27bf('0xf5d')][_0x1a27bf('0x1564')];_0x10be3d+=0x1){if(_0x3796dd(_0x465cac[_0x1a27bf('0xf5d')][_0x10be3d])){const _0x100b7e=_0x465cac[_0x1a27bf('0xf5d')][_0x10be3d];_0x4ed60b(_0x100b7e,!![]),_0x574533();}}}function _0x3796dd(_0x4f9507){const _0x16f366=_0x1ff15b;if(_0x2e3ca0()[_0x16f366('0x7a2')](_0x557d41['whatsappAccounts'],{'id':_0x2e3ca0()[_0x16f366('0xea3')](_0x4f9507[_0x16f366('0x1c35')])}))return!![];return![];}function _0x3831e1(_0x5a89ac){const _0x3b6350=_0x1ff15b,_0x458c95=_0x1aaf93()()[_0x3b6350('0xb11')](0x0,!![])[_0x3b6350('0x1627')](_0x3b6350('0x1efa')),_0x3b54cd=_0x1aaf93()()[_0x3b6350('0xb11')](0x0,!![])[_0x3b6350('0x3b3')]('day');return _0x1aaf93()(_0x5a89ac)[_0x3b6350('0xb11')](0x0,!![])['isBetween'](_0x458c95,_0x3b54cd);}function _0x57e468(_0x4cc25a){_0x3796dd(_0x4cc25a)&&_0x3831e1(_0x4cc25a['createdAt'])&&(_0x4ed60b(_0x4cc25a,!![]),_0x574533());}function _0x1142af(_0x42b310){const _0x3164eb=_0x1ff15b;_0x3796dd(_0x42b310)&&_0x3831e1(_0x42b310[_0x3164eb('0x1a4')])&&(_0x4ed60b(_0x42b310,![]),_0x574533());}_0x7875b6[_0x1ff15b('0x26a2')]('$destroy',function(){const _0xd9d77b=_0x1ff15b;_0x16efc5[_0xd9d77b('0x1b9e')](_0xd9d77b('0x42b')),_0x16efc5['removeAllListeners'](_0xd9d77b('0x20b'));});}const _0x3fea96=_0x31955f;_0x212fea[_0x189033('0x14be')]=['$stateProvider'];function _0x212fea(_0x5e5a71){const _0x4deb9c=_0x189033;_0x5e5a71[_0x4deb9c('0x2598')](_0x4deb9c('0x13ed'),{'url':'/voice','data':{'selectedTab':0x0},'views':{'voice':{'templateUrl':_0x1cc0d3,'controller':_0x4deb9c('0xc2c')}},'resolve':{'rpcQueues':[_0x4deb9c('0x4b1'),function(_0x579266){const _0x1ce7fe=_0x4deb9c;return _0x579266['resolve'](_0x1ce7fe('0x1406'));}],'inboundQueues':[_0x4deb9c('0x4b1'),_0x4deb9c('0xba1'),function(_0x268d62,_0x308de1){const _0x1c6907=_0x4deb9c;return _0x308de1[_0x1c6907('0xca1')]('admin')?_0x268d62[_0x1c6907('0xed7')]('voiceQueue@get',{'fields':_0x1c6907('0xa10'),'type':_0x1c6907('0x1535'),'nolimit':!![]}):_0x268d62['resolve'](_0x1c6907('0x191b'),{'id':_0x308de1[_0x1c6907('0x20b2')]()[_0x1c6907('0x2f')],'section':'VoiceQueues','fields':_0x1c6907('0xa10'),'type':_0x1c6907('0x1535'),'channel':_0x1c6907('0xcf2'),'nolimit':!![]});}],'outbound':['apiResolver',function(_0x900f9d){const _0x528f0a=_0x4deb9c;return _0x900f9d['resolve'](_0x528f0a('0x23c5'));}]},'authenticate':!![],'bodyClass':_0x4deb9c('0x1cd3')})['state'](_0x4deb9c('0x285e'),{'url':_0x4deb9c('0x247c'),'data':{'selectedTab':0x1},'views':{'dialer':{'templateUrl':_0x67e056,'controller':_0x4deb9c('0x2219')}},'resolve':{'rpcQueues':[_0x4deb9c('0x4b1'),function(_0x25b7b5){return _0x25b7b5['resolve']('rpc@getVoiceQueues');}],'outboundQueues':[_0x4deb9c('0x4b1'),_0x4deb9c('0xba1'),function(_0x4d62a0,_0x5dd825){const _0x4a05a7=_0x4deb9c;return _0x5dd825[_0x4a05a7('0xca1')]('admin')?_0x4d62a0[_0x4a05a7('0xed7')](_0x4a05a7('0x2730'),{'fields':_0x4a05a7('0xa10'),'type':'outbound','nolimit':!![]}):_0x4d62a0['resolve']('userProfile@getResources',{'id':_0x5dd825['getCurrentUser']()[_0x4a05a7('0x2f')],'section':_0x4a05a7('0x1a4c'),'fields':_0x4a05a7('0xa10'),'type':_0x4a05a7('0x17cd'),'channel':_0x4a05a7('0xcf2'),'nolimit':!![]});}],'rpcCampaigns':['apiResolver',function(_0x3e7b00){const _0x58a2cc=_0x4deb9c;return _0x3e7b00[_0x58a2cc('0xed7')](_0x58a2cc('0x1508'));}]},'authenticate':!![],'bodyClass':_0x4deb9c('0x1cd3')})[_0x4deb9c('0x2598')](_0x4deb9c('0xb9c'),{'url':_0x4deb9c('0x13ca'),'data':{'selectedTab':0x2},'views':{'chat':{'templateUrl':_0xd6adbd,'controller':'UserChatDashboardGeneralController\x20as\x20vm'}},'resolve':{'chatInteractions':['apiResolver',function(_0x26e3c4){const _0xa5de3f=_0x4deb9c;return _0x26e3c4['resolve'](_0xa5de3f('0x38b'),{'createdAt':{'$gte':_0x1aaf93()()['startOf']('day')['utcOffset'](0x0,!![])[_0xa5de3f('0x26dd')](),'$lte':_0x1aaf93()()[_0xa5de3f('0x3b3')](_0xa5de3f('0x1efa'))[_0xa5de3f('0xb11')](0x0,!![])[_0xa5de3f('0x26dd')]()},'nolimit':!![]});}],'chatWebsites':['apiResolver',_0x4deb9c('0xba1'),function(_0x117274,_0x285ec9){const _0x57576f=_0x4deb9c;return _0x285ec9[_0x57576f('0xca1')]('admin')?_0x117274[_0x57576f('0xed7')](_0x57576f('0x5af'),{'fields':_0x57576f('0x1003'),'sort':_0x57576f('0xc36'),'limit':0xa,'offset':0x0}):_0x117274[_0x57576f('0xed7')](_0x57576f('0x191b'),{'id':_0x285ec9[_0x57576f('0x20b2')]()['userProfileId'],'section':'ChatWebsites','fields':'createdAt,updatedAt,id,token,agentIdentifier,customerAlias,messageFontSize,name,key,address,remote,ListId,fidelity,timeout,agentAlias,closingQuestion,formSubmitSuccessMessage,formSubmitFailureMessage,color,color_focus,color_button,textColor,backgroundColor,fontSize,header_shape,showAgentAvatar,showCustomerAvatar,alignment,verticalAlignment,messagesAlignment,defaultTitle,animation,defaultWhiteLabel,whiteLabel,defaultLogo,conditionAgreement,autoclose,enableUnmanagedNote,unmanagedMessage,skipUnmanaged,sendUnmanaged,enableCustomerWriting,waitingTitle,waitingMessage,closingMessage,noteTitle,placeholderMessage,skipMessageButton,enableRating,ratingType,ratingStarsNumber,enableFeedback,forwardTranscript,forwardTranscriptMessage,closingMessageButton,download_transcript,enableCustomerAttachment,systemAlias,enquiry_enable,enquiry_forwarding,enquiry_forwarding_address,name_title,username_placeholder,email_title,email_placeholder,header_online,hideWhenOffline,header_offline,start_chat_button,offline_chat_button,offlineMessageSubject,offlineMessageBody,header_offline,offline_message,message_title,enquiry_message_placeholder,enquiry_button,rating_message,rating_send,rating_skip,acceptMethod,acceptUrl,rejectMethod,rejectUrl,closeMethod,closeUrl,onlineForm,offlineForm,mapKey,mapKeyOffline,forwardTranscript,forwardOffline,forwardOfflineAddress,IntervalId,timezone,waitForTheAssignedAgent,description,notificationSound,notificationShake,notificationTemplate','sort':'-updatedAt','limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':'dashboards'})[_0x4deb9c('0x2598')]('app.dashboards.general.mail',{'url':'/mail','data':{'selectedTab':0x3},'views':{'mail':{'templateUrl':_0x46c540,'controller':_0x4deb9c('0x2552')}},'resolve':{'mailInteractions':[_0x4deb9c('0x4b1'),function(_0x1e9792){const _0x48a7d8=_0x4deb9c;return _0x1e9792[_0x48a7d8('0xed7')]('mailInteraction@get',{'createdAt':{'$gte':_0x1aaf93()()[_0x48a7d8('0x1627')](_0x48a7d8('0x1efa'))[_0x48a7d8('0xb11')](0x0,!![])[_0x48a7d8('0x26dd')](),'$lte':_0x1aaf93()()[_0x48a7d8('0x3b3')](_0x48a7d8('0x1efa'))[_0x48a7d8('0xb11')](0x0,!![])[_0x48a7d8('0x26dd')]()},'nolimit':!![]});}],'mailAccounts':['apiResolver','Auth',function(_0x531a57,_0x422600){const _0x573aaa=_0x4deb9c;return _0x422600[_0x573aaa('0xca1')](_0x573aaa('0x20c2'))?_0x531a57[_0x573aaa('0xed7')](_0x573aaa('0x2a9'),{'fields':_0x573aaa('0x25ce'),'sort':_0x573aaa('0xc36'),'limit':0xa,'offset':0x0}):_0x531a57[_0x573aaa('0xed7')]('userProfile@getResources',{'id':_0x422600[_0x573aaa('0x20b2')]()[_0x573aaa('0x2f')],'section':'MailAccounts','fields':_0x573aaa('0x25ce'),'sort':_0x573aaa('0xc36'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':_0x4deb9c('0x1cd3')})['state'](_0x4deb9c('0x129d'),{'url':_0x4deb9c('0x307'),'data':{'selectedTab':0x4},'views':{'sms':{'templateUrl':_0x1f439b,'controller':_0x4deb9c('0x258c')}},'resolve':{'smsInteractions':[_0x4deb9c('0x4b1'),function(_0x312f23){const _0x5d0be9=_0x4deb9c;return _0x312f23['resolve']('smsInteraction@get',{'createdAt':{'$gte':_0x1aaf93()()[_0x5d0be9('0x1627')]('day')[_0x5d0be9('0xb11')](0x0,!![])[_0x5d0be9('0x26dd')](),'$lte':_0x1aaf93()()['endOf'](_0x5d0be9('0x1efa'))[_0x5d0be9('0xb11')](0x0,!![])[_0x5d0be9('0x26dd')]()},'nolimit':!![]});}],'smsAccounts':[_0x4deb9c('0x4b1'),'Auth',function(_0x343960,_0x43e64f){const _0x54bbad=_0x4deb9c;return _0x43e64f[_0x54bbad('0xca1')](_0x54bbad('0x20c2'))?_0x343960[_0x54bbad('0xed7')](_0x54bbad('0xf29'),{'fields':_0x54bbad('0x1f73'),'sort':_0x54bbad('0xc36'),'limit':0xa,'offset':0x0}):_0x343960[_0x54bbad('0xed7')]('userProfile@getResources',{'id':_0x43e64f[_0x54bbad('0x20b2')]()[_0x54bbad('0x2f')],'section':_0x54bbad('0x334'),'fields':'createdAt,updatedAt,id,name,key,token,remote,ListId,phone,type,accountSid,authId,authToken,smsMethod,username,password,senderString,deliveryReport,waitForTheAssignedAgent,description,receiveUrl,deliveryReportUrl,notificationSound,notificationShake,notificationTemplate','sort':_0x54bbad('0xc36'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':'dashboards'})['state'](_0x4deb9c('0xaf3'),{'url':_0x4deb9c('0x17d4'),'data':{'selectedTab':0x5},'views':{'openchannel':{'templateUrl':_0x486b5f,'controller':_0x4deb9c('0x19dd')}},'resolve':{'openchannelInteractions':['apiResolver',function(_0x47592c){const _0x2322a7=_0x4deb9c;return _0x47592c[_0x2322a7('0xed7')](_0x2322a7('0x2544'),{'createdAt':{'$gte':_0x1aaf93()()[_0x2322a7('0x1627')](_0x2322a7('0x1efa'))[_0x2322a7('0xb11')](0x0,!![])[_0x2322a7('0x26dd')](),'$lte':_0x1aaf93()()[_0x2322a7('0x3b3')](_0x2322a7('0x1efa'))[_0x2322a7('0xb11')](0x0,!![])[_0x2322a7('0x26dd')]()},'nolimit':!![]});}],'openchannelAccounts':['apiResolver',_0x4deb9c('0xba1'),function(_0x2b1c51,_0x477c61){const _0x2230f4=_0x4deb9c;return _0x477c61[_0x2230f4('0xca1')](_0x2230f4('0x20c2'))?_0x2b1c51[_0x2230f4('0xed7')](_0x2230f4('0x2497'),{'fields':'createdAt,updatedAt,id,name,key,token,replyUri,ListId,waitForTheAssignedAgent,mapKey,description,receiveUri,notificationSound,notificationShake,notificationTemplate','sort':'-updatedAt','nolimit':!![]}):_0x2b1c51[_0x2230f4('0xed7')](_0x2230f4('0x191b'),{'id':_0x477c61[_0x2230f4('0x20b2')]()[_0x2230f4('0x2f')],'section':_0x2230f4('0x1e08'),'fields':_0x2230f4('0x898'),'sort':_0x2230f4('0xc36'),'nolimit':!![]});}]},'authenticate':!![],'bodyClass':_0x4deb9c('0x1cd3')})[_0x4deb9c('0x2598')](_0x4deb9c('0x266e'),{'url':_0x4deb9c('0x2541'),'data':{'selectedTab':0x6},'views':{'fax':{'templateUrl':_0x2741b6,'controller':_0x4deb9c('0xa92')}},'resolve':{'faxInteractions':['apiResolver',function(_0x1dcdc1){const _0x5c108f=_0x4deb9c;return _0x1dcdc1[_0x5c108f('0xed7')](_0x5c108f('0xac7'),{'createdAt':{'$gte':_0x1aaf93()()[_0x5c108f('0x1627')](_0x5c108f('0x1efa'))['utcOffset'](0x0,!![])[_0x5c108f('0x26dd')](),'$lte':_0x1aaf93()()['endOf'](_0x5c108f('0x1efa'))['utcOffset'](0x0,!![])[_0x5c108f('0x26dd')]()},'nolimit':!![]});}],'faxAccounts':[_0x4deb9c('0x4b1'),_0x4deb9c('0xba1'),function(_0x47b894,_0x3ab0ff){const _0x4bc55e=_0x4deb9c;return _0x3ab0ff[_0x4bc55e('0xca1')](_0x4bc55e('0x20c2'))?_0x47b894['resolve'](_0x4bc55e('0x2076'),{'fields':'createdAt,updatedAt,id,name,key,headerinfo,TrunkId,localstationid,ListId,waitForTheAssignedAgent,description,ecm,minrate,maxrate,modem,gateway,faxdetect,t38timeout,tech,acceptMethod,acceptUrl,rejectMethod,rejectUrl,closeMethod,closeUrl,notificationSound,notificationShake,notificationTemplate','sort':_0x4bc55e('0xc36'),'limit':0xa,'offset':0x0}):_0x47b894['resolve'](_0x4bc55e('0x191b'),{'id':_0x3ab0ff[_0x4bc55e('0x20b2')]()[_0x4bc55e('0x2f')],'section':_0x4bc55e('0x13af'),'fields':_0x4bc55e('0xcfe'),'sort':_0x4bc55e('0xc36'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':_0x4deb9c('0x1cd3')})[_0x4deb9c('0x2598')]('app.dashboards.general.whatsapp',{'url':_0x4deb9c('0x1be6'),'data':{'selectedTab':0x7},'views':{'whatsapp':{'templateUrl':_0x222efc,'controller':_0x4deb9c('0x96f')}},'resolve':{'whatsappInteractions':[_0x4deb9c('0x4b1'),function(_0x7557f9){const _0x5622a2=_0x4deb9c;return _0x7557f9[_0x5622a2('0xed7')]('whatsappInteraction@get',{'createdAt':{'$gte':_0x1aaf93()()[_0x5622a2('0x1627')](_0x5622a2('0x1efa'))[_0x5622a2('0xb11')](0x0,!![])['format'](),'$lte':_0x1aaf93()()[_0x5622a2('0x3b3')](_0x5622a2('0x1efa'))[_0x5622a2('0xb11')](0x0,!![])['format']()},'nolimit':!![]});}],'whatsappAccounts':[_0x4deb9c('0x4b1'),_0x4deb9c('0xba1'),function(_0x878326,_0x25205e){const _0x184a69=_0x4deb9c;return _0x25205e[_0x184a69('0xca1')]('admin')?_0x878326[_0x184a69('0xed7')]('whatsappAccount@get',{'fields':_0x184a69('0x1d96'),'sort':_0x184a69('0xc36'),'limit':0xa,'offset':0x0}):_0x878326[_0x184a69('0xed7')](_0x184a69('0x191b'),{'id':_0x25205e[_0x184a69('0x20b2')]()[_0x184a69('0x2f')],'section':'WhatsappAccounts','fields':_0x184a69('0x1d96'),'sort':_0x184a69('0xc36'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'bodyClass':_0x4deb9c('0x1cd3')});}angular['module'](_0x189033('0x125f'),[])['config'](_0x212fea)[_0x189033('0x1da3')](_0x189033('0x74'),_0x35b9f6)['controller'](_0x189033('0x1dac'),_0x56e529)['controller']('UserFaxDashboardGeneralController',_0x32a0bc)[_0x189033('0x1da3')](_0x189033('0x1c1b'),_0x4f82fd)[_0x189033('0x1da3')](_0x189033('0x410'),_0x101d15)[_0x189033('0x1da3')](_0x189033('0xa2e'),_0x1ee2cf)[_0x189033('0x25')]('secToTime',_0x58c0c5)[_0x189033('0x1f97')]('initializeRealtimeQueue',_0x1385e9)[_0x189033('0x1f97')]('initializeRealtimeCampaign',_0x428aa8)[_0x189033('0x1da3')](_0x189033('0x20a0'),_0x4db37f)[_0x189033('0x1da3')](_0x189033('0x248c'),_0x4b19ce)[_0x189033('0x1da3')]('UserWhatsappDashboardGeneralController',_0x3fea96);const _0xf23f9e=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/agent/interaction/dispose/dialog.html/dialog.html',_0x5f1760=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/agent/contact/selection/dialog.html/dialog.html';var _0x37ff4d=_0x180212(0x1d2),_0x19c0ff=_0x180212['n'](_0x37ff4d);_0x28efab[_0x189033('0x14be')]=[_0x189033('0x1b'),_0x189033('0x1d08'),'$window',_0x189033('0xba1')],_0x14a4b2['$inject']=[_0x189033('0x7a5'),_0x189033('0x2f9'),'$mdDialog',_0x189033('0x2063'),_0x189033('0x1d08'),_0x189033('0x16ea'),_0x189033('0xba1'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x1b83'),_0x189033('0x1ab5'),'globalCompanies',_0x189033('0x22d5'),'license',_0x189033('0x260a'),'desktopNotification','msUtils'];function _0x14a4b2(_0x31b1a3,_0x2ed410,_0x47ea76,_0x4e2d76,_0x4392f3,_0x514487,_0x30496f,_0x57809a,_0x10c636,_0x295f51,_0x334fc3,_0x3dfc59,_0x18c22e,_0x41576a,_0x8dcb6a,_0x4299b6,_0x3faeaa,_0x2bcc75){const _0x348544=_0x189033,_0x1c106a=this;_0x1c106a[_0x348544('0xace')]=_0x8dcb6a,_0x1c106a[_0x348544('0x260a')]=_0x4299b6,_0x1c106a[_0x348544('0x262b')]=_0x2bcc75[_0x348544('0x262b')](),_0x1c106a[_0x348544('0xc96')]=_0x30496f[_0x348544('0x20b2')](),_0x1c106a[_0x348544('0x19a9')]=0x0,_0x1c106a[_0x348544('0x1313')]={},_0x1c106a['tabs']={},_0x1c106a[_0x348544('0x1e12')]={},_0x1c106a['globalUserLists']=_0x334fc3||{'count':0x0,'rows':[]},_0x1c106a[_0x348544('0x1ab5')]=_0x3dfc59||{'count':0x0,'rows':[]},_0x1c106a[_0x348544('0x1ea7')]=_0x18c22e||{'count':0x0,'rows':[]},_0x1c106a[_0x348544('0x22d5')]=_0x41576a||{'count':0x0,'rows':[]},_0x1c106a['onClickTab']=_0x2a8d3f,_0x1c106a[_0x348544('0x19d5')]=_0x3b590b,_0x1c106a[_0x348544('0x64b')]=_0x1f1972,_0x1c106a['addContactTab']=_0x3e1311,_0x1c106a[_0x348544('0x297')]=_0x3d4615,_0x1c106a[_0x348544('0xf77')]=_0x4739d1,_0x1c106a['removeTab']=_0x4e1169,_0x1c106a['updateLocalStorage']=_0x1a036a,_0x1c106a['closeTab']=_0x28a7b3,_0x10c636['on'](_0x348544('0x672'),_0x41cb45),_0x10c636['on'](_0x348544('0x26de'),_0x5c4677),_0x10c636['on']('trigger:bot',_0xb473eb),_0x10c636['on']('trigger:browser:url',_0x1a2487),_0x10c636['on']('trigger:browser:popup',_0xd8f67f),_0x10c636['on']('notification:save',_0x4c80dd),_0x10c636['on']('notification:remove',_0x37de75),_0x10c636['on'](_0x348544('0xea9'),_0x1ff785),_0x10c636['on'](_0x348544('0x1fc8'),_0x1ff785),_0x36d798();function _0x36d798(){const _0x2db04c=_0x348544;let _0x5bd37c=_0x4e2d76[_0x2db04c('0x120e')][_0x2db04c('0x1b28')](_0x2db04c('0x2ae')+_0x1c106a['user']['id']);if(_0x5bd37c)try{_0x5bd37c=JSON[_0x2db04c('0x1f34')](_0x5bd37c),_0x1c106a['tabs']=_0x5bd37c['tabs']?_0x5bd37c['tabs']:{},_0x1c106a[_0x2db04c('0x19a9')]=_0x5bd37c[_0x2db04c('0x19a9')]?_0x5bd37c['currentTab']:0x0,_0x3d136c(_0x1c106a[_0x2db04c('0x1a9')][_0x1c106a[_0x2db04c('0x19a9')]]);}catch(_0x4802de){console[_0x2db04c('0x52a')](_0x4802de);}}function _0x1a036a(_0x113d0a){const _0x135904=_0x348544,_0x483f86={};for(const _0x107fd2 in _0x1c106a['tabs']){typeof _0x1c106a[_0x135904('0x1a9')][_0x107fd2]!==_0x135904('0x1867')&&(_0x483f86[_0x107fd2]=_0x2e3ca0()['pick'](_0x1c106a['tabs'][_0x107fd2],[_0x135904('0xcf0'),_0x135904('0xf28'),_0x135904('0xdd6'),'icon',_0x135904('0x17f8'),_0x135904('0x9ca'),'id',_0x135904('0x118c'),_0x135904('0x1d68')]),!_0x2e3ca0()[_0x135904('0x8f2')](_0x1c106a[_0x135904('0x1a9')][_0x107fd2]['contact'])&&(_0x483f86[_0x107fd2][_0x135904('0xd06')]=_0x2e3ca0()[_0x135904('0x24d0')](_0x1c106a['tabs'][_0x107fd2][_0x135904('0xd06')],['id','ListId'])),!_0x2e3ca0()[_0x135904('0x8f2')](_0x1c106a['tabs'][_0x107fd2][_0x135904('0x394')])&&(_0x483f86[_0x107fd2]['calls']=_0x1c106a[_0x135904('0x1a9')][_0x107fd2]['calls']),_0x1c106a[_0x135904('0x1a9')][_0x107fd2]['interaction']&&(_0x483f86[_0x107fd2]['interaction']=_0x2e3ca0()['pick'](_0x1c106a['tabs'][_0x107fd2]['interaction'],['id',_0x135904('0x1061'),_0x135904('0x1cd'),_0x135904('0x15a5'),'FaxAccountId','SmsAccountId',_0x135904('0x1c35'),_0x135904('0xd8a'),_0x135904('0x2546')])));}let _0x5be783=JSON['parse'](_0x4e2d76[_0x135904('0x120e')][_0x135904('0x1b28')]('motion2.user:'+_0x1c106a[_0x135904('0xc96')]['id']));_0x5be783?(_0x5be783[_0x135904('0x1a9')]=_0x483f86,_0x5be783['currentTab']=_0x1c106a[_0x135904('0x19a9')]):_0x5be783={'tabs':_0x483f86,'currentTab':_0x1c106a[_0x135904('0x19a9')]},_0x4e2d76[_0x135904('0x120e')]['setItem']('motion2.user:'+_0x1c106a[_0x135904('0xc96')]['id'],JSON[_0x135904('0x258a')](_0x5be783)),_0x113d0a&&_0x3d136c(_0x113d0a);}function _0x3d136c(_0x3e13b8){const _0x57b512=_0x348544;if(_0x2e3ca0()[_0x57b512('0x8f2')](_0x3e13b8)||_0x3e13b8&&_0x3e13b8[_0x57b512('0xcf0')]===_0x57b512('0xa98')){const _0x15557a={'id':_0x1c106a[_0x57b512('0xc96')]['id'],'online':!![],'capacity':{'mail':0x0,'fax':0x0,'sms':0x0,'whatsapp':0x0,'openchannel':0x0,'chat':0x0},'interaction':{'mail':[],'fax':[],'sms':[],'whatsapp':[],'openchannel':[],'chat':[]}};for(const _0xf9b240 in _0x1c106a[_0x57b512('0x1a9')]){typeof _0x1c106a[_0x57b512('0x1a9')][_0xf9b240]!==_0x57b512('0x1867')&&(typeof _0x15557a[_0x57b512('0x12e')][_0x1c106a[_0x57b512('0x1a9')][_0xf9b240][_0x57b512('0xdd6')]]!==_0x57b512('0x1867')&&_0x1c106a[_0x57b512('0x1a9')][_0xf9b240]['interaction']&&!_0x1c106a['tabs'][_0xf9b240][_0x57b512('0xa98')][_0x57b512('0xd8a')]&&(_0x15557a[_0x57b512('0x12e')][_0x1c106a[_0x57b512('0x1a9')][_0xf9b240][_0x57b512('0xdd6')]]+=0x1,_0x15557a[_0x57b512('0xa98')][_0x1c106a[_0x57b512('0x1a9')][_0xf9b240][_0x57b512('0xdd6')]][_0x57b512('0x1fd0')](_0x1c106a[_0x57b512('0x1a9')][_0xf9b240]['interaction']['id'])));}if(!_0x2e3ca0()[_0x57b512('0x493')](_0x1c106a[_0x57b512('0x1e12')],_0x15557a[_0x57b512('0x12e')]))return _0x1c106a[_0x57b512('0x1e12')]=_0x15557a[_0x57b512('0x12e')],_0x57809a[_0x57b512('0x1b1b')][_0x57b512('0xba2')](_0x15557a);}}function _0x28a7b3(_0x3eb6e3){const _0x20e61c=_0x348544;let _0x182fac=![];const _0x4dddcb=_0x47ea76[_0x20e61c('0x1c6f')]()[_0x20e61c('0xf28')](_0x3eb6e3[_0x20e61c('0xcf0')]===_0x20e61c('0xa98')?_0x20e61c('0x112a'):_0x20e61c('0xbcd')+_0x3eb6e3[_0x20e61c('0xcf0')]+'?')[_0x20e61c('0x1525')](_0x3eb6e3[_0x20e61c('0xcf0')]===_0x20e61c('0xa98')?'':_0x20e61c('0x3fc')+_0x3eb6e3[_0x20e61c('0xcf0')]+_0x20e61c('0x274c'))[_0x20e61c('0x1040')]('Close\x20Contact')['ok'](_0x3eb6e3[_0x20e61c('0xcf0')]===_0x20e61c('0xa98')?_0x20e61c('0x13f7'):'OK')[_0x20e61c('0x19fb')](_0x3eb6e3[_0x20e61c('0xcf0')]===_0x20e61c('0xa98')?'NO':_0x20e61c('0x16b8'));if(_0x3eb6e3[_0x20e61c('0x118c')]){let _0x2e763b=![];_0x2e3ca0()[_0x20e61c('0x1299')](_0x3eb6e3['calls'],function(_0x2041bd){_0x2041bd['mandatoryDisposition']&&(_0x2e763b=!![]);});if(_0x3eb6e3[_0x20e61c('0xcf0')]==='contact'&&_0x3eb6e3['calls'][_0x20e61c('0x1564')]>0x0){let _0x3cdac3=undefined;if(_0x2e763b)_0x3cdac3=_0x47ea76[_0x20e61c('0x2430')]()[_0x20e61c('0xf28')]('Warning')[_0x20e61c('0x1525')](_0x20e61c('0x24fc'))['ok']('OK'),_0x47ea76[_0x20e61c('0x1d4')](_0x3cdac3)[_0x20e61c('0x2874')](function(){_0x3cdac3=undefined;});else return _0x4dddcb[_0x20e61c('0x26ba')][_0x20e61c('0x1525')]=_0x20e61c('0x24fc'),_0x47ea76['show'](_0x4dddcb)['then'](function(){_0x4e1169(_0x3eb6e3);});}else _0x4e1169(_0x3eb6e3);}else{const _0x319d7b=_0x1c106a[_0x20e61c('0xc96')][_0x20e61c('0x1431')]||_0x1c106a['user'][_0x20e61c('0x1938')]||_0x1c106a[_0x20e61c('0xc96')][_0x20e61c('0x774')]||_0x1c106a[_0x20e61c('0xc96')][_0x20e61c('0x1a11')]||_0x1c106a[_0x20e61c('0xc96')][_0x20e61c('0x716')];return _0x182fac=![],_0x3eb6e3[_0x20e61c('0xcf0')]===_0x20e61c('0xa98')&&(_0x182fac=_0x3eb6e3['interaction'][_0x20e61c('0xa78')][_0x20e61c('0x989')]),_0x47ea76[_0x20e61c('0x1d4')](_0x4dddcb)[_0x20e61c('0x683')](function(){const _0x45daac=_0x20e61c;_0x3eb6e3[_0x45daac('0xcf0')]===_0x45daac('0xa98')&&_0x47ea76[_0x45daac('0x1d4')]({'controller':_0x45daac('0x14a7'),'controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular[_0x45daac('0x1fcc')](_0x514487[_0x45daac('0x18e5')]),'onRemoving':function(){const _0x37138b=_0x45daac;_0x1c106a[_0x37138b('0xc96')]&&_0x182fac&&!_0x319d7b&&_0x57809a[_0x37138b('0xc96')][_0x37138b('0x1778')]({'id':_0x1c106a[_0x37138b('0xc96')]['id']})['$promise'][_0x37138b('0x130a')](function(_0x4ce4b2){console['error'](_0x4ce4b2);});},'clickOutsideToClose':!_0x182fac,'escapeToClose':!_0x182fac,'locals':{'user':_0x1c106a[_0x45daac('0xc96')],'channel':_0x3eb6e3[_0x45daac('0xdd6')],'interaction':_0x3eb6e3[_0x45daac('0xa98')]}}),_0x4e1169(_0x3eb6e3);})[_0x20e61c('0x130a')](function(){const _0x40d2f0=_0x20e61c;_0x3eb6e3[_0x40d2f0('0xcf0')]===_0x40d2f0('0xa98')&&_0x4e1169(_0x3eb6e3);});}}function _0x59ce39(_0x4adbd4){const _0x42a31b=_0x348544;if(_0x4adbd4[_0x42a31b('0xdd6')]&&_0x4adbd4[_0x42a31b('0xa98')])return _0x57809a[_0x42a31b('0xc96')]['remove'+_0x2e3ca0()[_0x42a31b('0x2711')](_0x4adbd4['channel'])+'Interactions']({'id':_0x1c106a[_0x42a31b('0xc96')]['id'],'ids':[_0x4adbd4['interaction']['id']]})[_0x42a31b('0xe53')][_0x42a31b('0x130a')](function(_0x2f43ba){const _0xb5f2ae=_0x42a31b;console[_0xb5f2ae('0x52a')](_0x2f43ba);});}function _0x4e1169(_0x1460b2){const _0x4e3926=_0x348544;if(_0x1c106a[_0x4e3926('0x1a9')][_0x1460b2['id']]){_0x59ce39(_0x1c106a[_0x4e3926('0x1a9')][_0x1460b2['id']]),delete _0x1c106a['tabs'][_0x1460b2['id']],_0x1c106a[_0x4e3926('0x19a9')]=0x0,_0x1a036a(_0x1460b2);if(_0x1460b2['type']==='interaction')return _0x57809a[_0x1460b2[_0x4e3926('0xdd6')]+'Interaction'][_0x4e3926('0x1e6e')]({'id':_0x1460b2[_0x4e3926('0xa98')]['id']})[_0x4e3926('0xe53')]['then'](function(_0x2a9a95){const _0x4c92ca=_0x4e3926;return _0x57809a[_0x4c92ca('0xc96')]['remove'+_0x2e3ca0()[_0x4c92ca('0x2711')](_0x1460b2[_0x4c92ca('0xdd6')])+_0x4c92ca('0x142d')]({'id':_0x1c106a[_0x4c92ca('0xc96')]['id'],'ids':[_0x2a9a95['id']]})[_0x4c92ca('0xe53')];})[_0x4e3926('0x130a')](function(_0x196b0f){const _0x5f0aaa=_0x4e3926;console[_0x5f0aaa('0x52a')](_0x196b0f);});}}function _0x4739d1(_0x5bb753){const _0x416ffa=_0x348544;_0x5bb753['id']=_0x2e3ca0()['random'](0x2540be400),_0x5bb753['openedAt']=new Date(),_0x5bb753[_0x416ffa('0x118c')]=![],_0x5bb753[_0x416ffa('0x1d68')]=0x0,_0x1c106a[_0x416ffa('0x1a9')][_0x5bb753['id']]=_0x5bb753,_0x1c106a[_0x416ffa('0x19a9')]=_0x5bb753['id'],_0x1a036a(_0x5bb753);}function _0x3b590b(_0x4c24ec){return _0x4c24ec===_0x1c106a['currentTab'];}function _0x2a8d3f(_0x387d9e){const _0x2ec634=_0x348544;_0x1c106a[_0x2ec634('0x19a9')]=_0x387d9e,_0x1a036a(_0x1c106a[_0x2ec634('0x1a9')][_0x387d9e]);}function _0x1f1972(_0x13e9d9){const _0x39dd89=_0x348544;return _0x2e3ca0()[_0x39dd89('0x1c07')](_0x1c106a[_0x39dd89('0x1a9')],function(_0x2dca3f){const _0x541147=_0x39dd89;return _0x2dca3f[_0x541147('0xcf0')]===_0x541147('0xa98')&&_0x2dca3f[_0x541147('0xa98')]&&_0x2dca3f['interaction']['id']==_0x13e9d9[_0x541147('0xae2')]&&_0x2dca3f[_0x541147('0xdd6')]==_0x13e9d9['channel'];});}function _0x198c94(_0xe69030){const _0x20ad74=_0x348544;let _0x49dba0='';if(_0xe69030){if(_0xe69030[_0x20ad74('0xeef')]||_0xe69030[_0x20ad74('0x510')])_0xe69030[_0x20ad74('0xeef')]&&(_0x49dba0+=_0xe69030[_0x20ad74('0xeef')]+'\x20'),_0xe69030[_0x20ad74('0x510')]&&(_0x49dba0+=_0xe69030[_0x20ad74('0x510')]);else _0xe69030[_0x20ad74('0xd31')]&&(_0x49dba0=_0xe69030['phone']);}return _0x49dba0;}function _0x272897(_0x2261fd){const _0x14b564=_0x348544;switch(_0x2261fd){case _0x14b564('0x24e'):return _0x14b564('0xa46');case _0x14b564('0x129f'):return _0x14b564('0x2420');case _0x14b564('0x1285'):return _0x14b564('0x1a87');case'openchannel':return'icon-google-earth';case _0x14b564('0x23e9'):return _0x14b564('0x8e9');case _0x14b564('0x16e7'):return _0x14b564('0x1b55');default:return _0x14b564('0xa46');}}function _0x860c62(_0x2986aa){const _0x52da14=_0x348544;switch(_0x2986aa){case _0x52da14('0x24e'):return _0x52da14('0xb1e');case _0x52da14('0x129f'):return _0x52da14('0x2f8');case _0x52da14('0x1285'):return _0x52da14('0xf85');case _0x52da14('0x1261'):return'amber-A200';case'fax':return _0x52da14('0x1a47');case _0x52da14('0x16e7'):return'lime-A700';default:return _0x52da14('0x1199');}}function _0x3e1311(_0x48587c,_0x2db5f3){const _0x382307=_0x348544,_0x2bbee1={'type':_0x382307('0xd06'),'title':_0x48587c?_0x198c94(_0x48587c):_0x4392f3[_0x382307('0x2728')](_0x382307('0x1cf4')),'icon':_0x382307('0x20cd'),'color':_0x382307('0x22b'),'contact':_0x48587c,'calls':_0x2db5f3?[_0x2db5f3]:[],'autoCreate':_0x2db5f3?_0x2db5f3[_0x382307('0x9ca')]:0x0};if(_0x2db5f3){if(_0x2db5f3[_0x382307('0x1408')]&&_0x2db5f3['xmd-cdrtype']===_0x382307('0x228a'))_0x2db5f3[_0x382307('0x1355')]=_0x2db5f3[_0x382307('0x113f')]?_0x1aaf93()(_0x2db5f3[_0x382307('0x113f')],_0x382307('0x865'))[_0x382307('0xc70')]():new Date();else{if(_0x2db5f3[_0x382307('0x573')]){const _0x42bebc=_0x2db5f3[_0x382307('0x573')][_0x382307('0x1fc5')]('.')[0x0];_0x2db5f3[_0x382307('0x1355')]=_0x42bebc?new Date(parseInt(_0x42bebc)*0x3e8):new Date();}}(_0x2db5f3[_0x382307('0xf63')]||_0x2db5f3['endtime'])&&_0x271e2f(_0x2db5f3);}if(_0x48587c){const _0x9dea0c=_0x2e3ca0()[_0x382307('0x1c07')](_0x1c106a[_0x382307('0x1a9')],function(_0x168333){const _0x1ca774=_0x382307;if(_0x168333[_0x1ca774('0xd06')]&&_0x168333[_0x1ca774('0xd06')]['id'])return _0x168333[_0x1ca774('0xcf0')]===_0x1ca774('0xd06')&&_0x168333[_0x1ca774('0xd06')]&&_0x168333[_0x1ca774('0xd06')]['id']==_0x48587c['id'];return _0x168333[_0x1ca774('0xcf0')]===_0x1ca774('0xd06')&&_0x168333[_0x1ca774('0xd06')]&&_0x168333[_0x1ca774('0xd06')][_0x1ca774('0xd31')]==_0x48587c[_0x1ca774('0xd31')];});if(_0x9dea0c){if(_0x2db5f3)return _0x57809a[_0x382307('0x337')][_0x382307('0x1e6e')]({'uniqueid':_0x2db5f3[_0x382307('0x573')]})['$promise'][_0x382307('0x683')](function(_0x341d3f){const _0x104ac9=_0x382307;_0x341d3f&&_0x341d3f[_0x104ac9('0xf5d')]['length']>0x0&&(_0x2db5f3[_0x104ac9('0x562')]=_0x2e3ca0()[_0x104ac9('0x2f5')](_0x341d3f[_0x104ac9('0xf5d')])['endtime']);if(_0x9dea0c[_0x104ac9('0x394')]){const _0x451f83=_0x2e3ca0()['find'](_0x9dea0c['calls'],function(_0x3c91f7){const _0x53f916=_0x104ac9;return _0x3c91f7[_0x53f916('0x573')]===_0x2db5f3['uniqueid'];});!_0x451f83&&_0x9dea0c[_0x104ac9('0x394')]['push'](_0x2db5f3);}else _0x9dea0c[_0x104ac9('0x394')]=[_0x2db5f3];_0x1c106a[_0x104ac9('0x19a9')]=_0x9dea0c['id'];});}else{if(_0x48587c[_0x382307('0x1e4f')])return _0x57809a[_0x382307('0x43f')][_0x382307('0x1e6e')]({'ListId':_0x48587c[_0x382307('0x1e4f')]})['$promise'][_0x382307('0x683')](function(_0x43095f){const _0x3182d5=_0x382307;return _0x2bbee1[_0x3182d5('0x191e')]=_0x43095f,_0x57809a['cmList'][_0x3182d5('0xcb')]({'id':_0x48587c['ListId']})[_0x3182d5('0xe53')];})['then'](function(_0x47e2ea){const _0x82b37b=_0x382307;_0x2bbee1[_0x82b37b('0xc4d')]=_0x47e2ea;})[_0x382307('0x130a')](_0x163716())[_0x382307('0x2874')](function(){_0x4739d1(_0x2bbee1);});else _0x4739d1(_0x2bbee1);}}else _0x4739d1(_0x2bbee1);}function _0x3d4615(_0x573e13,_0xbaad42){const _0x692a6b=_0x348544;let _0x5e5b73=_0x2e3ca0()[_0x692a6b('0x1c07')](_0x1c106a[_0x692a6b('0x1a9')],function(_0x5a989a){const _0x37e0c1=_0x692a6b;return _0x5a989a['type']===_0x37e0c1('0xa98')&&_0x5a989a[_0x37e0c1('0xa98')]&&_0x5a989a[_0x37e0c1('0xa98')]['id']===_0xbaad42['id']&&_0x5a989a[_0x37e0c1('0xdd6')]===_0x573e13;});_0x5e5b73?(_0x5e5b73[_0x692a6b('0x31f')]=_0xbaad42[_0x692a6b('0x31f')]||![],_0x1c106a[_0x692a6b('0x19a9')]=_0x5e5b73['id']):(_0x5e5b73={'type':_0x692a6b('0xa98'),'title':_0x573e13?_0x573e13[_0x692a6b('0x80')]():'openchannel','icon':_0x272897(_0x573e13),'color':_0x860c62(_0x573e13),'channel':_0x573e13,'interaction':_0xbaad42,'isDraft':_0xbaad42[_0x692a6b('0x31f')]||![]},_0x4739d1(_0x5e5b73));}function _0x20a3da(_0xf92d8d){const _0x50fcae=_0x348544,_0x58992b={'autoClose':!![],'duration':0xa,'showOnPageHidden':!![],'icon':_0x50fcae('0x26ed'),'body':_0xf92d8d['queue']?_0x50fcae('0x1a4f')+_0xf92d8d[_0x50fcae('0x660')]:'','focusOnclick':!![],'closeOnClick':!![]};_0x3faeaa[_0x50fcae('0x1d4')](_0xf92d8d[_0x50fcae('0xf28')],_0x58992b);}function _0x580a61(_0x4869b8){const _0x503180=_0x348544;_0x3faeaa['isSupported']()?_0x3faeaa[_0x503180('0xb8e')]()[_0x503180('0x683')](function(){_0x20a3da(_0x4869b8);},function(_0x8dc2e){const _0x52c2cd=_0x503180;console[_0x52c2cd('0x52a')](_0x52c2cd('0xdbf'),_0x8dc2e);}):console[_0x503180('0x52a')]('Browser\x20notifications\x20are\x20not\x20supported\x20by\x20the\x20browser.\x20Normal\x20notifications\x20will\x20be\x20used.');}function _0x4c80dd(_0x2add7a){const _0x4210a2=_0x348544;if(_0x2add7a&&_0x2add7a[_0x4210a2('0x573')]){_0x580a61(_0x2add7a);const _0x20fe51=_0x1f1972(_0x2add7a);if(_0x20fe51){if(_0x57809a[_0x2add7a[_0x4210a2('0xdd6')]+_0x4210a2('0x205e')])return _0x1c106a[_0x4210a2('0x19a9')]!==_0x20fe51['id']&&(_0x20fe51[_0x4210a2('0x1d68')]+=0x1),_0x57809a[_0x2add7a[_0x4210a2('0xdd6')]+_0x4210a2('0x205e')][_0x4210a2('0xd84')]({'id':_0x2add7a['id'],'UserId':_0x1c106a[_0x4210a2('0xc96')]['id']})[_0x4210a2('0xe53')][_0x4210a2('0x130a')](_0x163716());}else _0x295f51['wait']({'title':_0x2add7a[_0x4210a2('0xf28')],'msg':_0x2add7a['msg']||'','showClose':![],'clickToClose':![],'timeout':![],'sound':_0x2add7a[_0x4210a2('0x1638')],'html':!![],'shake':_0x2add7a[_0x4210a2('0x1370')]||![],'onAdd':function(){const _0x51d2d3=_0x4210a2;_0x1c106a[_0x51d2d3('0x1313')][_0x2add7a[_0x51d2d3('0x573')]]=this['id'];},'onAccept':function(){const _0x59d993=_0x4210a2;_0x37de75(_0x2add7a);if(_0x57809a[_0x2add7a[_0x59d993('0xdd6')]+'Message'])return _0x57809a[_0x2add7a[_0x59d993('0xdd6')]+_0x59d993('0x205e')][_0x59d993('0xd84')]({'id':_0x2add7a['id'],'UserId':_0x1c106a['user']['id'],'manual':!![]})[_0x59d993('0xe53')][_0x59d993('0x683')](function(_0x37e1af){const _0x2a24d0=_0x59d993;_0x3d4615(_0x37e1af[_0x2a24d0('0xdd6')],_0x37e1af['interaction']),_0x295f51[_0x2a24d0('0x53')]({'title':'Message\x20properly\x20accepted!','msg':_0x2a24d0('0x8af')});})[_0x59d993('0x130a')](_0x163716());},'onReject':function(){const _0x13dff1=_0x4210a2;_0x37de75(_0x2add7a);if(_0x57809a[_0x2add7a['channel']+'Message'])return _0x57809a[_0x2add7a['channel']+_0x13dff1('0x205e')][_0x13dff1('0xfae')]({'id':_0x2add7a['id'],'UserId':_0x1c106a[_0x13dff1('0xc96')]['id']})[_0x13dff1('0xe53')]['then'](function(){const _0x3f7e2a=_0x13dff1;_0x295f51[_0x3f7e2a('0x53')]({'title':_0x3f7e2a('0x1439'),'msg':_0x3f7e2a('0x1051')});})[_0x13dff1('0x130a')](_0x163716());}});}}function _0x37de75(_0x4379b8){const _0xc6aa72=_0x348544;_0x4379b8&&_0x4379b8[_0xc6aa72('0x573')]&&(_0x1c106a[_0xc6aa72('0x1313')][_0x4379b8['uniqueid']]&&(_0x295f51[_0xc6aa72('0x1045')](_0x1c106a[_0xc6aa72('0x1313')][_0x4379b8[_0xc6aa72('0x573')]]),delete _0x1c106a['notifications'][_0x4379b8['uniqueid']]));}function _0x41cb45(_0x534569){const _0x4c6d2d=_0x348544;if(!_0x534569[_0x4c6d2d('0x6d5')]){_0x3e1311(_0x534569[_0x4c6d2d('0xd06')],_0x534569[_0x4c6d2d('0x11ab')]);return;}_0x47ea76['show']({'controller':'ContactSelectionController','controllerAs':'vm','templateUrl':_0x5f1760,'parent':angular[_0x4c6d2d('0x1fcc')](_0x514487['body']),'locals':{'contacts':_0x534569[_0x4c6d2d('0x6d5')],'callNumber':_0x534569['evt'][_0x4c6d2d('0x4f8')]?_0x534569[_0x4c6d2d('0x11ab')][_0x4c6d2d('0x4ea')]:_0x534569[_0x4c6d2d('0x11ab')][_0x4c6d2d('0x11a5')]}})[_0x4c6d2d('0x683')](function(_0x570939){const _0x92d4db=_0x4c6d2d;_0x3e1311(_0x570939,_0x534569[_0x92d4db('0x11ab')]);});}function _0x5c4677(_0x2a495b){const _0x1c695a=_0x348544;return _0x57809a[_0x1c695a('0xa8b')][_0x1c695a('0x1e6e')]({'id':_0x2a495b[_0x1c695a('0x26d4')]})['$promise'][_0x1c695a('0x683')](function(_0x5d9f46){const _0x59abc0=_0x1c695a;if(_0x5d9f46){if(_0x2e3ca0()[_0x59abc0('0x105d')](_0x2a495b[_0x59abc0('0x7de')])){try{_0x5d9f46[_0x59abc0('0x4f5')]=_0x19c0ff()[_0x59abc0('0x977')](_0x5d9f46[_0x59abc0('0x4f5')],_0x2e3ca0()[_0x59abc0('0xf22')](_0x2a495b,{'user':_0x1c106a[_0x59abc0('0xc96')]}));}catch(_0x319189){console[_0x59abc0('0x52a')](_0x319189);}_0x4739d1({'type':_0x59abc0('0x18e6'),'title':_0x5d9f46[_0x59abc0('0x60a')],'icon':_0x59abc0('0xf7d'),'color':_0x59abc0('0x1199'),'project':_0x5d9f46,'call':_0x2a495b});}else return _0x57809a[_0x59abc0('0x276e')][_0x59abc0('0x1e6e')]({'id':_0x2a495b[_0x59abc0('0x7de')]})[_0x59abc0('0xe53')]['then'](function(_0x59c7c6){const _0x4c2f12=_0x59abc0;try{_0x5d9f46[_0x4c2f12('0x4f5')]=_0x19c0ff()['render'](_0x5d9f46['formData'],_0x2e3ca0()[_0x4c2f12('0xf22')](_0x2a495b,{'user':_0x1c106a[_0x4c2f12('0xc96')],'contact':_0x59c7c6}));}catch(_0x164a70){console['error'](_0x164a70);}_0x4739d1({'type':_0x4c2f12('0x18e6'),'title':_0x5d9f46[_0x4c2f12('0x60a')],'icon':_0x4c2f12('0xf7d'),'color':_0x4c2f12('0x1199'),'project':_0x5d9f46,'call':_0x2a495b,'contact':_0x59c7c6});})[_0x59abc0('0x130a')](_0x163716());}})['catch'](_0x163716());}function _0x1a2487(_0x522e27){const _0x31c818=_0x348544;if(_0x522e27&&_0x522e27[_0x31c818('0x933')]){_0x522e27[_0x31c818('0x933')]=_0x2e3ca0()[_0x31c818('0x1725')](_0x522e27['uri'],_0x31c818('0x1b70'),''),_0x522e27['uri']=_0x2e3ca0()[_0x31c818('0x1725')](_0x522e27[_0x31c818('0x933')],_0x31c818('0x3a3'),'');if(_0x522e27[_0x31c818('0x5ff')])switch(_0x522e27[_0x31c818('0x5ff')]){case'0':_0x4e2d76['open'](_0x522e27[_0x31c818('0x933')]);break;case'1':_0x4e2d76[_0x31c818('0x1614')](_0x522e27['uri'],'_blank','width='+(_0x522e27[_0x31c818('0x1ad8')]||_0x31c818('0x14f7'))+_0x31c818('0x58c')+_0x522e27['windowHeight']||0x0);break;case'2':{const _0x4283cc={'type':_0x31c818('0x3fd'),'title':_0x522e27[_0x31c818('0x933')],'icon':_0x31c818('0x13f1'),'color':_0x31c818('0x1913'),'src':_0x522e27[_0x31c818('0x933')]};_0x4739d1(_0x4283cc);}break;default:_0x4e2d76['open'](_0x522e27[_0x31c818('0x933')]);}else _0x4e2d76[_0x31c818('0x1614')](_0x522e27[_0x31c818('0x933')]);}}function _0xd8f67f(_0x1607a1){const _0x3b4e2a=_0x348544;_0x1607a1&&_0x1607a1[_0x3b4e2a('0x84')]&&_0x4739d1({'type':'popup','title':_0x1607a1[_0x3b4e2a('0x11a5')]||_0x3b4e2a('0x1d21'),'icon':'icon-tablet','color':_0x3b4e2a('0x1199'),'html':_0x1607a1['html']});}function _0xb473eb(_0x526bf2){const _0x57c922=_0x348544,_0x5b0cec=_0x526bf2[_0x57c922('0x554')]&&_0x526bf2[_0x57c922('0x554')]!==_0x57c922('0x2005')?_0x526bf2[_0x57c922('0x554')]:_0x526bf2[_0x57c922('0x11a5')],_0x5dff16=_0x526bf2[_0x57c922('0x11a5')];return _0x57809a[_0x57c922('0x1f1b')][_0x57c922('0x1e6e')]({'fields':'id','limit':0x1,'offset':0x0,'uniqueid':_0x526bf2[_0x57c922('0x573')]})[_0x57c922('0xe53')]['then'](function(_0x1b654b){const _0x4a3462=_0x57c922;_0x1b654b[_0x4a3462('0x50d')]&&_0x4739d1({'type':_0x4a3462('0x1534'),'title':_0x5b0cec+'\x20<'+_0x5dff16+'>','icon':_0x4a3462('0x1b07'),'color':_0x4a3462('0xbb2'),'data':{'uniqueid':_0x526bf2[_0x4a3462('0x573')]}});});}function _0x1ff785(_0x44c521){const _0x557b57=_0x348544;console[_0x557b57('0x598')](_0x557b57('0x36c'),_0x44c521);for(const _0x4ed46f in _0x1c106a[_0x557b57('0x1a9')]){if(typeof _0x1c106a[_0x557b57('0x1a9')][_0x4ed46f]!==_0x557b57('0x1867')){const _0x16215d=_0x1c106a['tabs'][_0x4ed46f];if(_0x16215d[_0x557b57('0x394')]){console['debug'](_0x557b57('0x363'),_0x4ed46f,_0x16215d,_0x16215d[_0x557b57('0x394')]);const _0x4cadd0=_0x2e3ca0()['findIndex'](_0x16215d[_0x557b57('0x394')],function(_0x27cb49){const _0x593a86=_0x557b57;return _0x27cb49[_0x593a86('0x573')]===_0x44c521[_0x593a86('0x573')];});_0x4cadd0>=0x0&&!_0x16215d[_0x557b57('0x394')][_0x4cadd0]['disposedAt']?(console['debug'](_0x557b57('0x267'),_0x44c521[_0x557b57('0x573')]),_0x271e2f(_0x16215d[_0x557b57('0x394')][_0x4cadd0])):console['debug'](_0x557b57('0x1ce7'),_0x44c521[_0x557b57('0x573')]),_0x1c106a[_0x557b57('0xd06')]&&_0x1c106a[_0x557b57('0xd06')]['id']&&_0x2ed410(_0x4af7b3(_0x44c521[_0x557b57('0x573')],_0x1c106a[_0x557b57('0xd06')]['id'],_0x16215d),0x3e8);}}}_0x1a036a();}function _0x4af7b3(_0x36017f,_0x5444ca,_0x8dbeb2){return function(){const _0x365ce5=a0_0x4e0a,_0x5e79d1=_0x2e3ca0()[_0x365ce5('0x1c07')](_0x8dbeb2[_0x365ce5('0x394')],function(_0x1334d5){const _0x5ae7c0=_0x365ce5;return _0x1334d5[_0x5ae7c0('0x573')]===_0x36017f;});if(_0x5e79d1)return _0x57809a['voiceCallReport'][_0x365ce5('0x2480')]({'id':_0x36017f,'ContactId':_0x5444ca})[_0x365ce5('0xe53')][_0x365ce5('0x130a')](function(_0x3876c3){const _0x15a067=_0x365ce5;console[_0x15a067('0x52a')](_0x3876c3);});};}function _0x271e2f(_0x380cab){const _0x319c94=_0x348544;_0x380cab[_0x319c94('0x562')]=new Date();}function _0x163716(){return function(_0x22e49a){const _0x5b81c4=a0_0x4e0a;if(_0x22e49a[_0x5b81c4('0x13ee')]===0x194)_0x295f51[_0x5b81c4('0xd33')]({'title':_0x4392f3[_0x5b81c4('0x2728')](_0x5b81c4('0x870')),'msg':_0x4392f3[_0x5b81c4('0x2728')]('DASHBOARDS.ACCEPT_ELSEWHERE')});else{if(_0x22e49a[_0x5b81c4('0x5a5')]&&_0x22e49a[_0x5b81c4('0x5a5')][_0x5b81c4('0x17f')]&&_0x22e49a[_0x5b81c4('0x5a5')]['errors']['length']){_0x1c106a['errors']=_0x22e49a[_0x5b81c4('0x5a5')]['errors']||[{'message':_0x22e49a['toString'](),'type':_0x5b81c4('0x1bc4')}];for(let _0x94ad38=0x0;_0x94ad38<_0x22e49a['data']['errors']['length'];_0x94ad38+=0x1){_0x295f51['error']({'title':_0x22e49a[_0x5b81c4('0x5a5')]['errors'][_0x94ad38][_0x5b81c4('0xcf0')],'msg':_0x22e49a[_0x5b81c4('0x5a5')][_0x5b81c4('0x17f')][_0x94ad38][_0x5b81c4('0x8c2')]});}}else _0x295f51[_0x5b81c4('0x52a')]({'title':_0x22e49a['status']?_0x5b81c4('0x2168')+_0x22e49a[_0x5b81c4('0x13ee')]+_0x5b81c4('0xbf6')+_0x22e49a[_0x5b81c4('0x24a9')]:'api.openchannelMessage.accept','msg':_0x22e49a[_0x5b81c4('0x5a5')]?JSON[_0x5b81c4('0x258a')](_0x22e49a['data']['message']):_0x22e49a['toString']()});}};}_0x31b1a3['$on'](_0x348544('0x4b8'),function(){const _0x8b1efa=_0x348544;for(const _0x4b4c23 in _0x1c106a[_0x8b1efa('0x1313')]){typeof _0x1c106a[_0x8b1efa('0x1313')][_0x4b4c23]!==_0x8b1efa('0x1867')&&_0x37de75({'uniqueid':_0x4b4c23});}_0x10c636[_0x8b1efa('0x1b9e')](_0x8b1efa('0x672')),_0x10c636[_0x8b1efa('0x1b9e')](_0x8b1efa('0x26de')),_0x10c636[_0x8b1efa('0x1b9e')](_0x8b1efa('0x2633')),_0x10c636['removeAllListeners'](_0x8b1efa('0x3bb')),_0x10c636[_0x8b1efa('0x1b9e')]('notification:save'),_0x10c636['removeAllListeners'](_0x8b1efa('0x1bfa')),_0x10c636[_0x8b1efa('0x1b9e')]('voice_queue_channel:remove'),_0x10c636[_0x8b1efa('0x1b9e')]('voice_outbound_channel:remove');});}function _0x28efab(_0x54ed7d,_0x1d092d,_0x2b5f96,_0x49899a){const _0x24ae5a=_0x189033,_0x34d1f7={};let _0x2aa979={},_0x23e930={},_0x5d8dca={};_0x34d1f7[_0x24ae5a('0x12f3')]=function(){const _0x14c49e=_0x24ae5a;_0x34d1f7[_0x14c49e('0xe9c')]=_0x23eac1();},_0x34d1f7[_0x24ae5a('0x22f2')]=function(_0x38508c){const _0x4bee4c=_0x24ae5a;return _0x34d1f7[_0x4bee4c('0xe9c')]=_0x23eac1(),_0x2e3ca0()[_0x4bee4c('0x1c07')](_0x2e3ca0()[_0x4bee4c('0x17a0')](_0x34d1f7['drafts']),function(_0x50adab){const _0x4d8ddf=_0x4bee4c;return _0x50adab[_0x4d8ddf('0xa98')]&&_0x50adab['interaction']['id']===_0x38508c;});},_0x34d1f7['removeByInteraction']=function(_0x1459ed){const _0x438f94=_0x24ae5a;_0x34d1f7[_0x438f94('0xe9c')]=_0x23eac1();const _0x5861b5=_0x2e3ca0()['find'](_0x2e3ca0()[_0x438f94('0x17a0')](_0x34d1f7[_0x438f94('0xe9c')]),function(_0x243e97){const _0x23a7b0=_0x438f94;return _0x243e97[_0x23a7b0('0xa98')]&&_0x243e97[_0x23a7b0('0xa98')]['id']===_0x1459ed;});_0x5861b5&&(delete _0x34d1f7[_0x438f94('0xe9c')][_0x5861b5['id']],_0x8dbb88());},_0x34d1f7['add']=function(_0x217f80){const _0x13bd63=_0x24ae5a;_0x34d1f7[_0x13bd63('0xe9c')]=_0x23eac1();let _0x89f1ad=_0x1d092d[_0x13bd63('0x2728')](_0x13bd63('0xd3d'));if(_0x217f80['contact'])_0x89f1ad=_0x217f80['contact'][_0x13bd63('0xeef')]||_0x217f80[_0x13bd63('0xd06')]['email'];else!_0x2e3ca0()[_0x13bd63('0x173f')](_0x217f80[_0x13bd63('0x8c2')][_0x13bd63('0x1e66')])&&(_0x89f1ad=_0x217f80['message']['subject']);const _0xcfcb33={'type':'draft','title':_0x217f80['account'][_0x13bd63('0x1d46')]+_0x13bd63('0xbf6')+_0x89f1ad,'channel':_0x217f80[_0x13bd63('0xdd6')],'content':_0x217f80[_0x13bd63('0x8c2')],'account':_0x217f80['account'],'interaction':_0x217f80['interaction'],'id':_0x2e3ca0()['random'](0x2540be400),'openedAt':new Date(),'saved':![]};_0x34d1f7[_0x13bd63('0xe9c')][_0xcfcb33['id']]=_0xcfcb33,_0x8dbb88();},_0x34d1f7[_0x24ae5a('0x2480')]=function(_0x36b35f){const _0x7125fa=_0x24ae5a;_0x34d1f7[_0x7125fa('0xe9c')]=_0x23eac1();const _0x461513=_0x34d1f7[_0x7125fa('0xe9c')][_0x36b35f['id']];_0x461513&&(_0x461513['content']=_0x36b35f['message'],_0x34d1f7[_0x7125fa('0xe9c')][_0x36b35f['id']]=_0x461513,_0x8dbb88());},_0x34d1f7[_0x24ae5a('0x1614')]=function(_0x47da22){const _0x4ce4fc=_0x24ae5a;_0x34d1f7[_0x4ce4fc('0xe9c')]=_0x23eac1();const _0x53f5b8=_0x34d1f7['drafts'][_0x47da22];_0x53f5b8&&_0x54ed7d[_0x4ce4fc('0x5ed')](_0x4ce4fc('0x1614')+_0x2e3ca0()[_0x4ce4fc('0x1e03')](_0x23e930)+_0x4ce4fc('0xb37'),_0x53f5b8);},_0x34d1f7['remove']=function(_0x3e2c0a){const _0x2c72d7=_0x24ae5a;_0x34d1f7[_0x2c72d7('0xe9c')]=_0x23eac1(),_0x34d1f7[_0x2c72d7('0xe9c')][_0x3e2c0a]&&(delete _0x34d1f7[_0x2c72d7('0xe9c')][_0x3e2c0a],_0x8dbb88());};function _0x23eac1(){const _0x22a108=_0x24ae5a;_0x2aa979=_0x49899a[_0x22a108('0x20b2')]();const _0x4083f6=_0x2b5f96[_0x22a108('0x120e')]['getItem'](_0x22a108('0x547')+_0x2aa979['id']);_0x4083f6?_0x23e930=JSON['parse'](_0x4083f6)[_0x22a108('0xc5')]:_0x23e930=_0x22a108('0x1a6');_0x5d8dca=_0x2b5f96[_0x22a108('0x120e')][_0x22a108('0x1b28')](_0x22a108('0x209')+_0x23e930+':'+_0x2aa979['id']);if(_0x5d8dca){const _0x2f4ff7=JSON[_0x22a108('0x1f34')](_0x5d8dca);!_0x2f4ff7[_0x22a108('0xe9c')]&&(_0x2f4ff7['drafts']={}),_0x5d8dca=_0x2f4ff7;}else _0x5d8dca={'drafts':{}};return _0x5d8dca['drafts'];}function _0x8dbb88(){const _0xe2a97=_0x24ae5a;_0x2e3ca0()[_0xe2a97('0x173f')](_0x34d1f7[_0xe2a97('0xe9c')])?delete _0x5d8dca[_0xe2a97('0xe9c')]:_0x5d8dca['drafts']=_0x34d1f7['drafts'],_0x2b5f96[_0xe2a97('0x120e')][_0xe2a97('0x15d')]('motion2.home.'+_0x23e930+':'+_0x2aa979['id'],JSON[_0xe2a97('0x258a')](_0x5d8dca));}return _0x34d1f7;}function _0x12ac4c(){const _0x426141=_0x189033,_0xa0aff={'autoClose':!![],'duration':0x5,'showOnPageHidden':![]};return{'config':_0x41e04c,'$get':['$q','$timeout','$window',_0x426141('0x1c8d'),_0x30bbde]};function _0x41e04c(_0x42821e){const _0x2f5414=_0x426141;for(const _0x2a31b1 in _0x42821e){typeof _0xa0aff[_0x2a31b1]!==_0x2f5414('0x1867')&&typeof _0x42821e[_0x2a31b1]!=='undefined'&&(_0xa0aff[_0x2a31b1]=_0x42821e[_0x2a31b1]);}}function _0x30bbde(_0x9af6c8,_0x176146,_0x1a7e95,_0x6040a7){const _0x14c6a3=_0x426141,_0x5bdef7=_0x1a7e95[_0x14c6a3('0x365')]||_0x1a7e95[_0x14c6a3('0x1c7c')]||_0x1a7e95[_0x14c6a3('0x508')],_0x267c2f={'isSupported':_0x3c1124,'currentPermission':_0x3d6ca6,'requestPermission':_0x56490a,'show':_0x767e5a,'permissions':{'default':_0x6040a7[_0x14c6a3('0x209e')],'granted':_0x6040a7[_0x14c6a3('0xf74')],'denied':_0x6040a7[_0x14c6a3('0x5b1')]}};return _0x267c2f;function _0x3c1124(){const _0x4e20a2=_0x14c6a3;return!(typeof _0x5bdef7===_0x4e20a2('0x1867'));}function _0x3d6ca6(){const _0x24f9aa=_0x14c6a3;return(_0x5bdef7||{})[_0x24f9aa('0xea0')];}function _0x56490a(){const _0x1062d8=_0x14c6a3;if(!_0x3c1124())return _0x9af6c8[_0x1062d8('0xfae')](_0x1062d8('0xe04'));const _0x563988=_0x9af6c8[_0x1062d8('0x448')]();return Promise['resolve'](_0x5bdef7[_0x1062d8('0xb8e')])==_0x5bdef7['requestPermission']?_0x5bdef7['requestPermission']()['then'](function(_0x5260aa){const _0x2f9f61=_0x1062d8;_0x6040a7[_0x2f9f61('0xf74')]===_0x5260aa?_0x563988['resolve'](_0x5260aa):_0x563988['reject'](_0x5260aa);}):_0x5bdef7[_0x1062d8('0xb8e')](function(_0x211c3d){const _0x54083f=_0x1062d8;_0x6040a7[_0x54083f('0xf74')]===_0x211c3d?_0x563988[_0x54083f('0xed7')](_0x211c3d):_0x563988[_0x54083f('0xfae')](_0x211c3d);}),_0x563988['promise'];}function _0x767e5a(_0x30c163,_0x127421){const _0x2999d5=_0x14c6a3;_0x127421=_0x127421||{};if(!_0x3c1124()||!_0x4b9995(_0x30c163,_0x127421)||_0x185cfd(_0x127421[_0x2999d5('0x1fec')])||_0x3d6ca6()!==_0x6040a7[_0x2999d5('0xf74')])return;const _0x598fc0=new _0x5bdef7(_0x30c163,_0x127421),_0x4bbac0=_0x127421[_0x2999d5('0xe60')]||_0xa0aff['duration'],_0x19d6d3=_0x127421[_0x2999d5('0xbf2')]===undefined?_0xa0aff['autoClose']:_0x127421[_0x2999d5('0xbf2')];_0x598fc0['onclick']=function(){const _0x58d493=_0x2999d5;_0x127421[_0x58d493('0x126b')]&&_0x127421[_0x58d493('0x126b')](),_0x127421['focusOnclick']&&window['focus'](),_0x127421['closeOnClick']&&_0x598fc0[_0x58d493('0x12b0')]();};if(_0x19d6d3)_0x454477(_0x598fc0,_0x4bbac0);return _0x598fc0;}function _0x4b9995(_0x12b8c1,_0x5638f1){const _0x4bea88=_0x14c6a3,_0x2a8626=angular[_0x4bea88('0xc1c')](_0x12b8c1),_0x3f371e=!_0x5638f1['onClick']||angular[_0x4bea88('0x93f')](_0x5638f1['onClick']);return _0x2a8626&&_0x3f371e;}function _0x185cfd(_0x52b63f){const _0x332d19=_0x14c6a3;if(!_0x52b63f&&!_0xa0aff[_0x332d19('0x1fec')])return;return!(window[_0x332d19('0x12e1')][_0x332d19('0x1fb4')]||window['document'][_0x332d19('0x145f')]||window['document'][_0x332d19('0x13c8')]);}function _0x454477(_0x21b741,_0x26975f){const _0x54dd7f=_0x14c6a3,_0x485034=_0x26975f*0x3e8;_0x176146(_0x21b741[_0x54dd7f('0x12b0')][_0x54dd7f('0xb86')](_0x21b741),_0x485034,![]);}}}function _0x1d4a34(){const _0x4edb33=_0x189033,_0x4e3e28=angular[_0x4edb33('0xfc0')](['ng'])[_0x4edb33('0x1e6e')](_0x4edb33('0x24a8')),_0x149e62=[],_0x57a393=this;_0x57a393['saveItem']=_0x52f7c0,_0x57a393[_0x4edb33('0x6b8')]=_0x38e903;function _0x52f7c0(_0x3fae08,_0x1a5d3a){const _0x511be6=_0x4edb33;if(!angular[_0x511be6('0xc1c')](_0x3fae08)){_0x4e3e28['error'](_0x511be6('0x222f'));return;}const _0x1a1140=_0x3fae08['split']('.'),_0x44b23a=_0x1a1140[_0x1a1140[_0x511be6('0x1564')]-0x1],_0x519282=_0x369375(_0x1a1140);let _0x2254cd=![];for(let _0xc655b2=0x0;_0xc655b2<_0x519282['length'];_0xc655b2++){if(_0x519282[_0xc655b2][_0x511be6('0x25e6')]===_0x44b23a){_0x2254cd=_0x519282[_0xc655b2];break;}}_0x2254cd?(angular[_0x511be6('0x618')](_0x2254cd,_0x1a5d3a),_0x2254cd[_0x511be6('0x171')]=_0x4bfc2b(_0x2254cd)):(_0x1a5d3a[_0x511be6('0x62')]=[],(angular['isUndefined'](_0x1a5d3a[_0x511be6('0x1df8')])||!angular[_0x511be6('0x52d')](_0x1a5d3a[_0x511be6('0x1df8')]))&&(_0x1a5d3a[_0x511be6('0x1df8')]=0x1),_0x1a5d3a['_id']=_0x44b23a,_0x1a5d3a[_0x511be6('0xc3e')]=_0x3fae08,_0x1a5d3a[_0x511be6('0x171')]=_0x4bfc2b(_0x1a5d3a),_0x519282['push'](_0x1a5d3a));}function _0x38e903(_0x36208b){const _0x285d00=_0x4edb33;if(!angular[_0x285d00('0xc1c')](_0x36208b)){_0x4e3e28['error'](_0x285d00('0x222f'));return;}let _0x4c9237=_0x149e62;const _0x1d256b=_0x36208b['split']('.');for(let _0x2acaf3=0x0;_0x2acaf3<_0x1d256b[_0x285d00('0x1564')];_0x2acaf3++){const _0xd46ee6=_0x1d256b[_0x2acaf3];for(let _0x4c1751=0x0;_0x4c1751<_0x4c9237[_0x285d00('0x1564')];_0x4c1751++){if(_0x4c9237[_0x4c1751][_0x285d00('0x25e6')]===_0xd46ee6){if(_0x4c9237[_0x4c1751][_0x285d00('0xc3e')]===_0x36208b)return _0x4c9237[_0x285d00('0x2040')](_0x4c1751,0x1),!![];_0x4c9237=_0x4c9237[_0x4c1751][_0x285d00('0x62')];break;}}}return![];}function _0x369375(_0x52e4b4){const _0x3e1677=_0x4edb33;let _0x3ce736=_0x149e62;if(_0x52e4b4[_0x3e1677('0x1564')]===0x1)return _0x3ce736;_0x52e4b4[_0x3e1677('0x1d')]();for(let _0x1edf31=0x0;_0x1edf31<_0x52e4b4[_0x3e1677('0x1564')];_0x1edf31++){const _0x105aa3=_0x52e4b4[_0x1edf31];let _0x144a08=!![];for(let _0x500c99=0x0;_0x500c99<_0x3ce736['length'];_0x500c99++){if(_0x3ce736[_0x500c99][_0x3e1677('0x25e6')]===_0x105aa3){_0x3ce736=_0x3ce736[_0x500c99][_0x3e1677('0x62')],_0x144a08=![];break;}}if(_0x144a08){const _0x4d2549={'_id':_0x105aa3,'_path':_0x52e4b4[_0x3e1677('0x1630')]('.'),'title':_0x105aa3,'weight':0x1,'children':[]};_0x3ce736['push'](_0x4d2549),_0x3ce736=_0x4d2549[_0x3e1677('0x62')];}}return _0x3ce736;}function _0x4bfc2b(_0x5b5711){const _0x16d1dd=_0x4edb33;let _0x48601e='';return angular[_0x16d1dd('0x127')](_0x5b5711[_0x16d1dd('0x2598')])&&(_0x48601e=_0x5b5711[_0x16d1dd('0x2598')],angular['isDefined'](_0x5b5711[_0x16d1dd('0x230a')])&&angular[_0x16d1dd('0x20b6')](_0x5b5711[_0x16d1dd('0x230a')])&&(_0x48601e=_0x48601e+'('+angular[_0x16d1dd('0x1bf7')](_0x5b5711[_0x16d1dd('0x230a')])+')')),_0x48601e;}this[_0x4edb33('0x1862')]=function(){const _0x403d47={'saveItem':_0x52f7c0,'getNavigation':_0x65634e};return _0x403d47;function _0x65634e(_0x46502e){const _0x214040=a0_0x4e0a;if(_0x46502e){for(let _0x3cb551=0x0;_0x3cb551<_0x149e62['length'];_0x3cb551++){if(_0x149e62[_0x3cb551][_0x214040('0x25e6')]===_0x46502e)return[_0x149e62[_0x3cb551]];}return null;}return _0x149e62;}};}const _0x3a97da={'DEFAULT':_0x189033('0x9cb'),'GRANTED':_0x189033('0x146f'),'DENIED':_0x189033('0x24bc')};_0x223c60['$inject']=[_0x189033('0x56b')];function _0x223c60(_0xa7338d){const _0x4a127c=_0x189033,_0x29e6b5=this;_0x29e6b5[_0x4a127c('0x260a')]={},_0x29e6b5[_0x4a127c('0x2636')]={'count':0x0,'rows':[]},_0x29e6b5[_0x4a127c('0x15c9')]=![];function _0x50f38c(_0x51ca5d,_0xd60400){const _0x4e63c5=_0x4a127c;_0x29e6b5[_0x4e63c5('0x260a')]=_0xd60400,_0x29e6b5[_0x4e63c5('0x1904')]=_0x51ca5d,_0x29e6b5[_0x4e63c5('0x1904')][_0x4e63c5('0x118c')]=!![];if(_0x29e6b5[_0x4e63c5('0x1904')]&&_0x29e6b5['tab'][_0x4e63c5('0x5a5')]&&_0x29e6b5[_0x4e63c5('0x1904')][_0x4e63c5('0x5a5')][_0x4e63c5('0x573')])return _0xa7338d[_0x4e63c5('0x1f1b')]['get']({'uniqueid':_0x29e6b5[_0x4e63c5('0x1904')]['data'][_0x4e63c5('0x573')]})[_0x4e63c5('0xe53')][_0x4e63c5('0x683')](function(_0x1a115f){const _0x52a02c=_0x4e63c5;_0x29e6b5[_0x52a02c('0x2636')]=_0x1a115f;})[_0x4e63c5('0x2874')](function(){const _0x3621a3=_0x4e63c5;_0x29e6b5[_0x3621a3('0x15c9')]=!![];});else _0x29e6b5[_0x4e63c5('0x15c9')]=!![];}function _0x25f09f(_0x15c280){const _0x33e038=_0x4a127c;switch(_0x29e6b5[_0x33e038('0x260a')][_0x33e038('0x19d7')]){case'left':if(_0x15c280[_0x33e038('0x2655')]=='in')return _0x15c280['direction'];return'out-left-aligned';case _0x33e038('0x20b1'):if(_0x15c280[_0x33e038('0x2655')]=='in')return _0x33e038('0x1f74');return _0x15c280[_0x33e038('0x2655')];default:return _0x15c280[_0x33e038('0x2655')];}}_0x29e6b5[_0x4a127c('0x12f3')]=_0x50f38c,_0x29e6b5[_0x4a127c('0x2fb')]=_0x25f09f;}const _0x19479b=_0x223c60,_0x24dbc7=_0x180212['p']+_0x189033('0x768'),_0x7650f=_0x180212['p']+_0x189033('0xef5'),_0x8be7e1=_0x180212['p']+_0x189033('0x1ae6'),_0x354ecd=_0x180212['p']+_0x189033('0x247e'),_0x1e7ae7=_0x180212['p']+_0x189033('0xfb7'),_0x2b4eb6=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/agent/interaction/composeOpenchannel/dialog.html/dialog.html',_0x382523=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/agent/interaction/composeSms/dialog.html/dialog.html',_0x4cefce=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/agent/interaction/composeWhatsapp/dialog.html/dialog.html';_0x9a5a2c[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),_0x189033('0x7a5'),'$q','api',_0x189033('0x1d70'),_0x189033('0xba1'),'$translate',_0x189033('0x1cc2')];const _0x504560={'fax':_0x354ecd,'mail':_0x1e7ae7,'openchannel':_0x2b4eb6,'sms':_0x382523,'whatsapp':_0x4cefce};function _0x9a5a2c(_0x515333,_0x12ed40,_0x29513e,_0x2c6dfd,_0x127a42,_0x12eda1,_0x346481,_0x27ef41,_0x21edce,_0x2605b7){const _0x5ac571=_0x189033,_0x250877=this;_0x250877['user']=_0x27ef41['getCurrentUser'](),_0x250877[_0x5ac571('0x262b')]=_0x2605b7[_0x5ac571('0x262b')](),_0x250877[_0x5ac571('0x18b')]=[],_0x250877[_0x5ac571('0x1067')]={'fields':'id,phone,scheduledat','sort':_0x5ac571('0xc36'),'limit':0xa,'page':0x1},_0x250877[_0x5ac571('0x721')]={'fields':_0x5ac571('0x2fa'),'sort':_0x5ac571('0xc36'),'limit':0xa,'page':0x1},_0x250877['queryHistory']={'fields':_0x5ac571('0x233f'),'sort':_0x5ac571('0xc36'),'limit':0xa,'page':0x1},_0x250877[_0x5ac571('0x1c63')]={'rows':[],'count':0x0},_0x250877[_0x5ac571('0x157d')]={'rows':[],'count':0x0},_0x250877[_0x5ac571('0x1f3f')]={'rows':[],'count':0x0},_0x250877[_0x5ac571('0xe5f')]=new Date(_0x1aaf93()()[_0x5ac571('0x1627')](_0x5ac571('0x55b'))[_0x5ac571('0x1315')](0x1,'seconds')[_0x5ac571('0xb11')](0x0,!![])['format']()),_0x250877[_0x5ac571('0x1686')]=new Date(_0x1aaf93()()['endOf'](_0x5ac571('0x55b'))[_0x5ac571('0x1315')](0x1,_0x5ac571('0x1efa'))[_0x5ac571('0xb11')](0x0,!![])[_0x5ac571('0x26dd')]()),_0x250877[_0x5ac571('0x1c03')]=_0x24a7aa,_0x250877[_0x5ac571('0x206f')]=_0x2361b0,_0x250877['getCustomFields']=_0x22bb98,_0x250877[_0x5ac571('0x164f')]=_0x2c6dfd[_0x5ac571('0x1cd5')]['vm'][_0x5ac571('0x164f')],_0x250877[_0x5ac571('0x46b')]=_0xd0294f,_0x250877[_0x5ac571('0x1453')]=_0x198164,_0x250877['mergeContact']=_0xf022cb,_0x250877[_0x5ac571('0x16b3')]=_0x454e60,_0x250877[_0x5ac571('0x6d8')]=_0x423ab6,_0x250877[_0x5ac571('0x21f7')]=_0x46eb4a,_0x250877[_0x5ac571('0x255c')]=_0x42f00a,_0x250877['getHistories']=_0x214d70,_0x250877['getJscriptyProjects']=_0x14c544,_0x250877[_0x5ac571('0x2872')]=_0x3f5c98,_0x250877[_0x5ac571('0x2842')]=_0x129993,_0x250877[_0x5ac571('0xf1e')]=_0x53e535,_0x250877['getWhatsappAccounts']=_0x2af6a5,_0x250877['getOpenchannelAccounts']=_0x5c6ef6,_0x250877[_0x5ac571('0x24ee')]=_0x54f961,_0x250877[_0x5ac571('0x16c3')]=_0x42a612,_0x250877[_0x5ac571('0xfc')]=_0x343f4f,_0x250877['init']=_0x57b8ea,_0x250877[_0x5ac571('0x5e3')]=_0x56bc9e,_0x250877['openInteraction']=_0x348841,_0x250877[_0x5ac571('0x14d4')]=_0x508178,_0x250877[_0x5ac571('0xf71')]=_0x525542,_0x250877[_0x5ac571('0x2800')]();function _0x525542(_0x1a667d){const _0x5f09c0=_0x5ac571;if(_0x1a667d[_0x5f09c0('0xe22')])return _0x2e3ca0()[_0x5f09c0('0x2292')](_0x2e3ca0()[_0x5f09c0('0x386')](_0x250877[_0x5f09c0('0x2595')]?_0x250877[_0x5f09c0('0x2595')][_0x5f09c0('0xf5d')]:[],'id'),_0x1a667d['FaxAccountId']);else{if(_0x1a667d['OpenchannelAccountId'])return _0x2e3ca0()[_0x5f09c0('0x2292')](_0x2e3ca0()[_0x5f09c0('0x386')](_0x250877[_0x5f09c0('0x1952')]?_0x250877[_0x5f09c0('0x1952')][_0x5f09c0('0xf5d')]:[],'id'),_0x1a667d['OpenchannelAccountId']);else{if(_0x1a667d['SmsAccountId'])return _0x2e3ca0()['includes'](_0x2e3ca0()[_0x5f09c0('0x386')](_0x250877[_0x5f09c0('0x197c')]?_0x250877[_0x5f09c0('0x197c')][_0x5f09c0('0xf5d')]:[],'id'),_0x1a667d[_0x5f09c0('0x1f4f')]);else{if(_0x1a667d['WhatsappAccountId'])return _0x2e3ca0()[_0x5f09c0('0x2292')](_0x2e3ca0()[_0x5f09c0('0x386')](_0x250877['whatsappAccounts']?_0x250877[_0x5f09c0('0x263c')][_0x5f09c0('0xf5d')]:[],'id'),_0x1a667d['WhatsappAccountId']);else{if(_0x1a667d[_0x5f09c0('0x1cd')])return _0x2e3ca0()[_0x5f09c0('0x2292')](_0x2e3ca0()[_0x5f09c0('0x386')](_0x250877['mailAccounts']?_0x250877[_0x5f09c0('0x1093')][_0x5f09c0('0xf5d')]:[],'id'),_0x1a667d[_0x5f09c0('0x1cd')]);else{if(_0x1a667d[_0x5f09c0('0x15a5')])return _0x2e3ca0()[_0x5f09c0('0x2292')](_0x2e3ca0()[_0x5f09c0('0x386')](_0x250877['chatAccounts']?_0x250877['chatAccounts']['rows']:[],'id'),_0x1a667d[_0x5f09c0('0x15a5')]);else{if(_0x1a667d[_0x5f09c0('0x1297')])return!![];}}}}}}return![];}function _0x348841(_0x3153a,_0x26a008){const _0x3a38e3=_0x5ac571;try{if(_0x26a008[_0x3a38e3('0x1cd')])return _0x2c6dfd[_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')]['vm'][_0x3a38e3('0x297')](_0x3a38e3('0x129f'),_0x26a008);else{if(_0x26a008[_0x3a38e3('0x15a5')])return _0x2c6dfd[_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')]['vm'][_0x3a38e3('0x297')](_0x3a38e3('0x24e'),_0x26a008);else{if(_0x26a008[_0x3a38e3('0x1f4f')])return _0x2c6dfd[_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')]['vm'][_0x3a38e3('0x297')](_0x3a38e3('0x1285'),_0x26a008);else{if(_0x26a008['WhatsappAccountId'])return _0x2c6dfd['$parent']['$parent'][_0x3a38e3('0x1cd5')]['vm']['addInteractionTab'](_0x3a38e3('0x16e7'),_0x26a008);else{if(_0x26a008[_0x3a38e3('0x1061')])return _0x2c6dfd[_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')]['vm'][_0x3a38e3('0x297')]('openchannel',_0x26a008);else{if(_0x26a008[_0x3a38e3('0xe22')])return _0x2c6dfd[_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')][_0x3a38e3('0x1cd5')]['vm']['addInteractionTab']('fax',_0x26a008);}}}}}}catch(_0x349f6f){_0x346481[_0x3a38e3('0x52a')]({'title':_0x3a38e3('0x27cc'),'msg':'Customer\x20Journey\x20can\x27t\x20open\x20the\x20interaction'});}}function _0x150432(_0x4bcf6f){const _0x2e780d=_0x5ac571;if(!_0x4bcf6f[_0x2e780d('0x43f')])return'('+_0x21edce[_0x2e780d('0x2728')]('DASHBOARDS.NO_DISPOSITION_SET')+')';const _0x41c2e3=_0x2e3ca0()[_0x2e780d('0x1043')]([_0x4bcf6f['disposition'],_0x4bcf6f[_0x2e780d('0x259d')],_0x4bcf6f['thirdDisposition']]);return'('+_0x41c2e3[_0x2e780d('0x1630')]('\x20-\x20')+')';}function _0x293d11(_0x3c6e5a){const _0x1bcd92=_0x5ac571;_0x3c6e5a&&_0x3c6e5a[_0x1bcd92('0x50d')]&&_0x3c6e5a[_0x1bcd92('0xf5d')][_0x1bcd92('0x1564')]&&(_0x250877[_0x1bcd92('0x18b')]=_0x2e3ca0()[_0x1bcd92('0x746')](_0x250877[_0x1bcd92('0x18b')],_0x3c6e5a['rows']),_0x250877[_0x1bcd92('0x18b')][_0x1bcd92('0x1299')](function(_0x2500ee){_0x2500ee['dispositionsValues']=_0x150432(_0x2500ee);}));}function _0x1a061d(_0x38d0e1){const _0x359d61=_0x5ac571,_0x19e4dd=[_0x359d61('0x129f'),_0x359d61('0x24e'),'sms','openchannel',_0x359d61('0x23e9'),_0x359d61('0x16e7')];if(_0x38d0e1&&_0x38d0e1['id']){for(let _0x5912d6=0x0;_0x5912d6<_0x19e4dd['length'];_0x5912d6++){_0x12eda1[_0x19e4dd[_0x5912d6]+'Interaction'][_0x359d61('0x1e6e')]({'ContactId':_0x38d0e1['id'],'journey':!![],'includeAll':!![]})[_0x359d61('0xe53')]['then'](_0x293d11);}_0x12eda1[_0x359d61('0x337')][_0x359d61('0x1e6e')]({'ContactId':_0x38d0e1['id'],'includeAll':!![]})[_0x359d61('0xe53')]['then'](_0x293d11)[_0x359d61('0x130a')](function(_0x15ab2a){console['error'](_0x15ab2a);});}}function _0x4c607d(_0x43d945){const _0x53eb63=_0x5ac571;switch(_0x43d945){case _0x53eb63('0x24e'):return _0x53eb63('0xb1e');case _0x53eb63('0x129f'):return'teal';case _0x53eb63('0x1285'):return _0x53eb63('0xf85');case _0x53eb63('0x1261'):return _0x53eb63('0xe71');case'fax':return _0x53eb63('0x1a47');case _0x53eb63('0x16e7'):return'lime-A700';default:return _0x53eb63('0x1841');}}function _0x508178(_0xf3cc5){const _0x8bc8a8=_0x5ac571;let _0x5e7e36='';if(_0xf3cc5['FaxAccountId'])_0x5e7e36=_0x8bc8a8('0x23e9');else{if(_0xf3cc5[_0x8bc8a8('0x1061')])_0x5e7e36=_0x8bc8a8('0x1261');else{if(_0xf3cc5[_0x8bc8a8('0x1f4f')])_0x5e7e36=_0x8bc8a8('0x1285');else{if(_0xf3cc5['WhatsappAccountId'])_0x5e7e36=_0x8bc8a8('0x16e7');else{if(_0xf3cc5[_0x8bc8a8('0x1cd')])_0x5e7e36=_0x8bc8a8('0x129f');else{if(_0xf3cc5[_0x8bc8a8('0x15a5')])_0x5e7e36=_0x8bc8a8('0x24e');else _0xf3cc5['amaflags']&&(_0x5e7e36='voice');}}}}}return _0x4c607d(_0x5e7e36);}function _0x57b8ea(_0x404874,_0x23d804){const _0xc6bba2=_0x5ac571;return _0x250877[_0xc6bba2('0x1904')]=_0x404874,_0x2c6dfd[_0xc6bba2('0x2340')]([_0xc6bba2('0x1523'),_0xc6bba2('0x1d31')],function(_0x48ee3a){const _0x1173b4=_0xc6bba2;_0x250877[_0x1173b4('0x1904')][_0x1173b4('0x118c')]=_0x48ee3a[0x0]&&_0x48ee3a[0x1];}),_0x250877[_0xc6bba2('0xace')]=_0x23d804,_0x250877[_0xc6bba2('0xd06')]=_0x250877[_0xc6bba2('0x1904')][_0xc6bba2('0xd06')],_0x250877['newContact']=![],_0x250877['currentTab']=0x0,_0x12eda1['user'][_0xc6bba2('0x1e6e')]({'fields':'id,fullname','nolimit':!![]})[_0xc6bba2('0xe53')][_0xc6bba2('0x683')](function(_0x33abe3){const _0x3fd357=_0xc6bba2;_0x250877[_0x3fd357('0x3bf')]=_0x33abe3||{'count':0x0,'rows':[]},_0x250877[_0x3fd357('0xd7d')]=_0x2e3ca0()[_0x3fd357('0x1cc9')](_0x2e3ca0()[_0x3fd357('0x24db')](_0x250877[_0x3fd357('0x3bf')][_0x3fd357('0xf5d')],'id'),_0x3fd357('0x11bc'));return;})['then'](function(){const _0x1041d2=_0xc6bba2,_0x5b49e1=[];for(let _0x283f9f=0x0;_0x283f9f<_0x250877['tab'][_0x1041d2('0x394')]['length'];_0x283f9f++){const _0x16f8a0=_0x250877[_0x1041d2('0x1904')][_0x1041d2('0x394')][_0x283f9f];_0x5b49e1[_0x1041d2('0x1fd0')](_0x12eda1[_0x1041d2('0x337')][_0x1041d2('0x1e6e')]({'uniqueid':_0x16f8a0['uniqueid']})[_0x1041d2('0xe53')][_0x1041d2('0x683')](function(_0x1cfd36){const _0x531fe5=_0x1041d2;_0x1cfd36&&_0x1cfd36[_0x531fe5('0xf5d')]['length']>0x0&&(_0x16f8a0['disposedAt']=_0x2e3ca0()[_0x531fe5('0x2f5')](_0x1cfd36[_0x531fe5('0xf5d')])[_0x531fe5('0x84d')]);return;}));}return _0x127a42[_0x1041d2('0x252c')](_0x5b49e1);})[_0xc6bba2('0x683')](function(){const _0x15a3f1=_0xc6bba2;if(_0x250877[_0x15a3f1('0xd06')]&&_0x250877['contact']['id']){const _0x4f0f1e={'id':_0x250877['contact']['id'],'ListId':_0x250877[_0x15a3f1('0xd06')]['ListId'],'limit':0x1,'offset':0x0,'sort':'-updatedAt'};return _0x12eda1[_0x15a3f1('0x276e')]['get'](_0x4f0f1e)[_0x15a3f1('0xe53')][_0x15a3f1('0x683')](function(_0x5e33f0){const _0x2deed0=_0x15a3f1;return _0x250877[_0x2deed0('0xd06')]=_0x5e33f0,_0x250877['tab'][_0x2deed0('0xd06')]=_0x5e33f0,_0x12eda1[_0x2deed0('0xc96')][_0x2deed0('0xc1')]({'id':_0x250877[_0x2deed0('0xc96')]['id'],'ids':[_0x250877[_0x2deed0('0xd06')]['id']]});})[_0x15a3f1('0x683')](function(){const _0x1595aa=_0x15a3f1;if(_0x250877['contact'][_0x1595aa('0x1e4f')])return _0x12eda1[_0x1595aa('0x43f')][_0x1595aa('0x1e6e')]({'ListId':_0x250877['contact'][_0x1595aa('0x1e4f')]})[_0x1595aa('0xe53')][_0x1595aa('0x683')](function(_0x5d3d4a){const _0x11bdfd=_0x1595aa;return _0x250877[_0x11bdfd('0x1904')][_0x11bdfd('0x191e')]=_0x5d3d4a,_0x12eda1[_0x11bdfd('0x259b')][_0x11bdfd('0xcb')]({'id':_0x250877['contact'][_0x11bdfd('0x1e4f')]})['$promise'];})['then'](function(_0x1ccc5f){const _0x51b11f=_0x1595aa;_0x250877[_0x51b11f('0x1904')][_0x51b11f('0xc4d')]=_0x1ccc5f;return;});return;})['then'](function(){const _0x2e9991=_0x15a3f1;try{_0x250877['tab'][_0x2e9991('0xc38')]=_0x2c6dfd[_0x2e9991('0x1cd5')][_0x2e9991('0x1cd5')][_0x2e9991('0x1cd5')]['vm'][_0x2e9991('0x1b83')],_0x250877[_0x2e9991('0x1904')][_0x2e9991('0xe01')]=_0x2c6dfd['$parent'][_0x2e9991('0x1cd5')][_0x2e9991('0x1cd5')]['vm'][_0x2e9991('0x1ab5')],_0x250877[_0x2e9991('0x1904')][_0x2e9991('0x1191')]=_0x2c6dfd[_0x2e9991('0x1cd5')]['$parent'][_0x2e9991('0x1cd5')]['vm'][_0x2e9991('0x1ea7')],_0x250877[_0x2e9991('0x1904')][_0x2e9991('0x1ce6')]=_0x2c6dfd[_0x2e9991('0x1cd5')]['$parent'][_0x2e9991('0x1cd5')]['vm'][_0x2e9991('0x22d5')],_0x250877[_0x2e9991('0x1904')][_0x2e9991('0x9ca')]=0x0,_0x250877[_0x2e9991('0xd06')]['ListId']&&(_0x250877['tab'][_0x2e9991('0xc38')][_0x2e9991('0xf5d')]=_0x2e3ca0()[_0x2e9991('0x41c')](_0x250877[_0x2e9991('0x1904')][_0x2e9991('0xc38')][_0x2e9991('0xf5d')],_0x2e3ca0()[_0x2e9991('0x25')](_0x250877[_0x2e9991('0x1904')][_0x2e9991('0xe01')][_0x2e9991('0xf5d')],{'id':_0x250877[_0x2e9991('0xd06')][_0x2e9991('0x1e4f')]}),'id'),_0x250877[_0x2e9991('0x2335')]=_0x2e3ca0()[_0x2e9991('0x1c07')](_0x250877[_0x2e9991('0x1904')]['userLists']['rows'],{'id':_0x250877['contact'][_0x2e9991('0x1e4f')]}));}catch(_0x2272b0){}_0x250877[_0x2e9991('0x21f7')](),_0x250877[_0x2e9991('0x255c')](),_0x250877[_0x2e9991('0x20a4')](),_0x250877[_0x2e9991('0x2872')](),_0x250877['getFaxAccounts'](),_0x250877['getSmsAccounts'](),_0x250877['getWhatsappAccounts'](),_0x250877[_0x2e9991('0x24e3')](),_0x250877[_0x2e9991('0x24ee')](),_0x250877[_0x2e9991('0x16c3')]();return;})[_0x15a3f1('0x683')](function(){const _0x5c82d4=_0x15a3f1;return _0x12eda1[_0x5c82d4('0x276e')]['getTags']({'id':_0x250877['contact']['id']})[_0x5c82d4('0xe53')]['then'](function(_0x293900){const _0x2ab7c6=_0x5c82d4;_0x250877[_0x2ab7c6('0x1904')]['Tags']=_0x2e3ca0()[_0x2ab7c6('0x386')](_0x293900[_0x2ab7c6('0xf5d')],'id');return;});});}else{_0x250877[_0x15a3f1('0x2337')]=!![];if(_0x404874['autoCreate'])return console[_0x15a3f1('0x1b2b')](_0x15a3f1('0x9ca')),_0x250877[_0x15a3f1('0x1c03')]();return;}})[_0xc6bba2('0x683')](_0x1a061d(_0x250877['contact']));}function _0x343f4f(_0x2225a2,_0x230915,_0x2647e5,_0x9669cf){const _0x22480a=_0x5ac571,_0x1e6334=_0x230915['toLowerCase']();_0x515333[_0x22480a('0x1d4')]({'controller':'Compose'+_0x230915+_0x22480a('0xe2d'),'controllerAs':'vm','templateUrl':_0x504560[_0x1e6334],'parent':angular[_0x22480a('0x1fcc')](_0x12ed40[_0x22480a('0x18e5')]),'clickOutsideToClose':![],'locals':{'account':_0x2647e5,'message':{'to':_0x1e6334==_0x22480a('0x129f')?_0x9669cf:_0x9669cf[_0x22480a('0x1fc5')](',')},'type':'new','interaction':{'Contact':_0x250877[_0x22480a('0xd06')]}},'fullscreen':!![]})[_0x22480a('0x683')](function(_0x5b8b29){const _0x422d8a=_0x22480a;return _0x12eda1[_0x1e6334+'Account'][_0x422d8a('0x1503')]({'id':_0x2647e5['id']},_0x5b8b29)[_0x422d8a('0xe53')][_0x422d8a('0x683')](function(_0x373408){const _0xf45e1a=_0x422d8a;if(_0x230915===_0xf45e1a('0x24f1')){const _0x5a5f47=_0x373408;if(_0x5a5f47&&_0x5a5f47[_0xf45e1a('0xc51')]&&_0x5a5f47['Messages']['length']){if(_0x5b8b29[_0xf45e1a('0x1b46')]&&_0x5b8b29[_0xf45e1a('0x1b46')][_0xf45e1a('0x1564')])for(let _0x48b709=0x0;_0x48b709<_0x5b8b29[_0xf45e1a('0x1b46')]['length'];_0x48b709+=0x1){_0x12eda1['attachment']['update']({'id':_0x5b8b29['attachments'][_0x48b709]['id']},{'MailMessageId':_0x2e3ca0()[_0xf45e1a('0xd39')](_0x5a5f47[_0xf45e1a('0xc51')])['id']});}_0x346481[_0xf45e1a('0x53')]({'title':_0xf45e1a('0xb96'),'msg':_0xf45e1a('0x21a1')});if(_0x5a5f47[_0xf45e1a('0xd8a')]){_0x5a5f47['disposition']=null;const _0x88700c=!_0x2647e5[_0xf45e1a('0x989')],_0x5e86da=_0x250877[_0xf45e1a('0xc96')][_0xf45e1a('0x1431')]||_0x250877[_0xf45e1a('0xc96')][_0xf45e1a('0x1938')]||_0x250877[_0xf45e1a('0xc96')][_0xf45e1a('0x774')]||_0x250877[_0xf45e1a('0xc96')][_0xf45e1a('0x1a11')]||_0x250877[_0xf45e1a('0xc96')]['faxPause'];_0x515333[_0xf45e1a('0x1d4')]({'controller':_0xf45e1a('0x14a7'),'controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular[_0xf45e1a('0x1fcc')](_0x12ed40[_0xf45e1a('0x18e5')]),'onRemoving':function(){const _0x5ee2c7=_0xf45e1a;_0x250877[_0x5ee2c7('0xc96')]&&_0x2647e5[_0x5ee2c7('0x989')]&&!_0x5e86da&&_0x12eda1['user'][_0x5ee2c7('0x1778')]({'id':_0x250877['user']['id']})[_0x5ee2c7('0xe53')]['catch'](function(_0x847449){const _0x348c61=_0x5ee2c7;console[_0x348c61('0x52a')](_0x847449);});},'clickOutsideToClose':_0x88700c,'escapeToClose':_0x88700c,'locals':{'user':_0x250877[_0xf45e1a('0xc96')],'channel':_0xf45e1a('0x129f'),'interaction':_0x5a5f47}});}else _0x2c6dfd[_0xf45e1a('0x1cd5')]['vm'][_0xf45e1a('0x297')](_0xf45e1a('0x129f'),_0x5a5f47);}}else _0x346481[_0xf45e1a('0x53')]({'title':_0xf45e1a('0xb96'),'msg':_0xf45e1a('0x21a1')}),_0x2c6dfd[_0xf45e1a('0x1cd5')]['vm'][_0xf45e1a('0x297')](_0x1e6334,_0x373408);})[_0x422d8a('0x130a')](function(_0x34c7e9){const _0x103644=_0x422d8a;if(_0x34c7e9[_0x103644('0x5a5')]&&_0x34c7e9[_0x103644('0x5a5')][_0x103644('0x17f')]&&_0x34c7e9[_0x103644('0x5a5')][_0x103644('0x17f')][_0x103644('0x1564')])for(let _0x3b80e2=0x0;_0x3b80e2<_0x34c7e9[_0x103644('0x5a5')][_0x103644('0x17f')][_0x103644('0x1564')];_0x3b80e2+=0x1){_0x346481[_0x103644('0x52a')]({'title':_0x34c7e9['data'][_0x103644('0x17f')][_0x3b80e2][_0x103644('0xcf0')],'msg':_0x34c7e9['data']['errors'][_0x3b80e2][_0x103644('0x8c2')]});}else _0x1e6334===_0x103644('0x23e9')?_0x346481['error']({'title':'FAX:SEND','msg':_0x34c7e9['data']?JSON[_0x103644('0x258a')](_0x34c7e9[_0x103644('0x5a5')]):_0x34c7e9[_0x103644('0x8c2')]||_0x34c7e9['toString']()}):_0x346481[_0x103644('0x52a')]({'title':_0x34c7e9['status']?_0x103644('0x2168')+_0x34c7e9[_0x103644('0x13ee')]+_0x103644('0xbf6')+_0x34c7e9[_0x103644('0x24a9')]:_0x230915['toUpperCase']()+_0x103644('0x7c5'),'msg':_0x34c7e9['data']?JSON[_0x103644('0x258a')](_0x34c7e9[_0x103644('0x5a5')][_0x103644('0x8c2')]):_0x34c7e9[_0x103644('0x8c2')]||_0x34c7e9[_0x103644('0x1ff0')]()});});});}function _0x24a7aa(){const _0x1e9557=_0x5ac571;_0x250877[_0x1e9557('0x17f')]=[],_0x12eda1[_0x1e9557('0x276e')][_0x1e9557('0xb0a')](_0x250877[_0x1e9557('0xd06')])[_0x1e9557('0xe53')][_0x1e9557('0x683')](function(_0x43bf2e){const _0x58820b=_0x1e9557;return _0x250877[_0x58820b('0xd06')]['id']=_0x43bf2e['id'],_0x250877[_0x58820b('0x2337')]=![],_0x250877['tab']['title']=_0x43bf2e[_0x58820b('0xeef')]||_0x43bf2e[_0x58820b('0xd31')],_0x250877[_0x58820b('0x1904')][_0x58820b('0xd06')]=_0x250877[_0x58820b('0xd06')],_0x12eda1['user'][_0x58820b('0xc1')]({'id':_0x27ef41[_0x58820b('0x20b2')]()['id'],'ids':[_0x43bf2e['id']]});})[_0x1e9557('0x683')](function(){const _0x5ccfb5=_0x1e9557;_0x250877['detailForm']['$pristine']=!![],_0x250877[_0x5ccfb5('0xe7b')][_0x5ccfb5('0xb0')]=!![],_0x346481['success']({'title':_0x5ccfb5('0x174a'),'msg':_0x250877[_0x5ccfb5('0xd06')][_0x5ccfb5('0xeef')]?_0x250877[_0x5ccfb5('0xd06')][_0x5ccfb5('0xeef')]+_0x5ccfb5('0x14b5'):''});})[_0x1e9557('0x683')](function(){const _0x5d2e72=_0x1e9557;return _0x12eda1[_0x5d2e72('0x276e')][_0x5d2e72('0x167d')]({'id':_0x250877[_0x5d2e72('0xd06')]['id'],'ids':_0x250877['tab'][_0x5d2e72('0x198f')]})[_0x5d2e72('0xe53')];})[_0x1e9557('0x130a')](function(_0x27e08f){const _0x29cc64=_0x1e9557;if(_0x27e08f[_0x29cc64('0x5a5')]&&_0x27e08f[_0x29cc64('0x5a5')][_0x29cc64('0x17f')]&&_0x27e08f[_0x29cc64('0x5a5')][_0x29cc64('0x17f')]['length']){_0x250877[_0x29cc64('0x17f')]=_0x27e08f['data'][_0x29cc64('0x17f')]||[{'message':_0x27e08f[_0x29cc64('0x1ff0')](),'type':_0x29cc64('0xafc')}];for(let _0x553119=0x0;_0x553119<_0x27e08f['data'][_0x29cc64('0x17f')][_0x29cc64('0x1564')];_0x553119+=0x1){_0x346481['error']({'title':_0x27e08f[_0x29cc64('0x5a5')][_0x29cc64('0x17f')][_0x553119]['type'],'msg':_0x27e08f[_0x29cc64('0x5a5')][_0x29cc64('0x17f')][_0x553119]['message']});}}else _0x346481[_0x29cc64('0x52a')]({'title':_0x27e08f[_0x29cc64('0x13ee')]?_0x29cc64('0x2168')+_0x27e08f[_0x29cc64('0x13ee')]+_0x29cc64('0xbf6')+_0x27e08f['statusText']:_0x29cc64('0xafc'),'msg':_0x27e08f['data']?JSON[_0x29cc64('0x258a')](_0x27e08f['data'][_0x29cc64('0x8c2')]):_0x27e08f['toString']()});});}function _0x2361b0(){const _0xb8ecf=_0x5ac571;_0x250877[_0xb8ecf('0x17f')]=[],_0x12eda1['cmContact'][_0xb8ecf('0x2480')]({'id':_0x250877['contact']['id']},_0x250877[_0xb8ecf('0xd06')])[_0xb8ecf('0xe53')][_0xb8ecf('0x683')](function(_0x51049c){const _0x4b6d1e=_0xb8ecf;return _0x250877[_0x4b6d1e('0x1904')][_0x4b6d1e('0xf28')]=_0x51049c['firstName']||_0x51049c[_0x4b6d1e('0xd31')],_0x250877[_0x4b6d1e('0x1904')]['contact']=_0x250877['contact'],_0x2c6dfd[_0x4b6d1e('0x1cd5')]['vm'][_0x4b6d1e('0x1c14')](),_0x12eda1[_0x4b6d1e('0xc96')][_0x4b6d1e('0xc1')]({'id':_0x27ef41[_0x4b6d1e('0x20b2')]()['id'],'ids':[_0x51049c['id']]});})[_0xb8ecf('0x683')](function(){const _0x13b5c5=_0xb8ecf;return _0x12eda1['cmContact'][_0x13b5c5('0x167d')]({'id':_0x250877[_0x13b5c5('0xd06')]['id'],'ids':_0x250877[_0x13b5c5('0x1904')][_0x13b5c5('0x198f')]})[_0x13b5c5('0xe53')];})[_0xb8ecf('0x683')](function(){const _0x3a80eb=_0xb8ecf;_0x250877[_0x3a80eb('0x1eb9')]['$pristine']=!![],_0x250877[_0x3a80eb('0xe7b')][_0x3a80eb('0xb0')]=!![],_0x346481[_0x3a80eb('0x53')]({'title':_0x3a80eb('0x1ef5'),'msg':_0x250877[_0x3a80eb('0xd06')]['name']?_0x250877['contact'][_0x3a80eb('0x60a')]+_0x3a80eb('0x96c'):''});})[_0xb8ecf('0x130a')](function(_0x4798c8){const _0x2c943e=_0xb8ecf;if(_0x4798c8[_0x2c943e('0x5a5')]&&_0x4798c8[_0x2c943e('0x5a5')]['errors']&&_0x4798c8[_0x2c943e('0x5a5')][_0x2c943e('0x17f')][_0x2c943e('0x1564')]){_0x250877[_0x2c943e('0x17f')]=_0x4798c8[_0x2c943e('0x5a5')]['errors']||[{'message':_0x4798c8[_0x2c943e('0x1ff0')](),'type':'api.contact.save'}];for(let _0x5d7d21=0x0;_0x5d7d21<_0x4798c8[_0x2c943e('0x5a5')][_0x2c943e('0x17f')]['length'];_0x5d7d21+=0x1){_0x346481[_0x2c943e('0x52a')]({'title':_0x4798c8[_0x2c943e('0x5a5')]['errors'][_0x5d7d21]['type'],'msg':_0x4798c8[_0x2c943e('0x5a5')][_0x2c943e('0x17f')][_0x5d7d21][_0x2c943e('0x8c2')]});}}else _0x346481[_0x2c943e('0x52a')]({'title':_0x4798c8['status']?_0x2c943e('0x2168')+_0x4798c8['status']+_0x2c943e('0xbf6')+_0x4798c8[_0x2c943e('0x24a9')]:_0x2c943e('0xafc'),'msg':_0x4798c8[_0x2c943e('0x5a5')]?JSON[_0x2c943e('0x258a')](_0x4798c8[_0x2c943e('0x5a5')][_0x2c943e('0x8c2')]):_0x4798c8[_0x2c943e('0x1ff0')]()});});}_0x2c6dfd[_0x5ac571('0x186d')]('currentTab',function(){const _0xeca024=_0x5ac571;_0x250877[_0xeca024('0x19a9')]===0x1&&(_0x250877['getHoppers'](),_0x250877['getFinals'](),_0x250877[_0xeca024('0x20a4')]());});let _0x19d0a4=!![],_0x430a3c=0x1;_0x2c6dfd[_0x5ac571('0x186d')](_0x5ac571('0x1382'),function(_0x52ac3c,_0x51414c){const _0x43fe54=_0x5ac571;_0x19d0a4?_0x29513e(function(){_0x19d0a4=![];}):(!_0x51414c&&(_0x430a3c=_0x250877[_0x43fe54('0x1067')][_0x43fe54('0xdf8')]),_0x52ac3c!==_0x51414c&&(_0x250877[_0x43fe54('0x1067')][_0x43fe54('0xdf8')]=0x1),!_0x52ac3c&&(_0x250877[_0x43fe54('0x1067')][_0x43fe54('0xdf8')]=_0x430a3c),_0x250877[_0x43fe54('0x21f7')]());}),_0x2c6dfd[_0x5ac571('0x186d')](_0x5ac571('0x487'),function(_0x20e907,_0x382b56){const _0x321ae9=_0x5ac571;_0x19d0a4?_0x29513e(function(){_0x19d0a4=![];}):(!_0x382b56&&(_0x430a3c=_0x250877['queryFinal'][_0x321ae9('0xdf8')]),_0x20e907!==_0x382b56&&(_0x250877['queryFinal'][_0x321ae9('0xdf8')]=0x1),!_0x20e907&&(_0x250877[_0x321ae9('0x721')]['page']=_0x430a3c),_0x250877[_0x321ae9('0x255c')]());}),_0x2c6dfd['$watch'](_0x5ac571('0x1252'),function(_0x905155,_0x50ba2e){const _0x2fbdb6=_0x5ac571;_0x19d0a4?_0x29513e(function(){_0x19d0a4=![];}):(!_0x50ba2e&&(_0x430a3c=_0x250877[_0x2fbdb6('0x23cd')]['page']),_0x905155!==_0x50ba2e&&(_0x250877[_0x2fbdb6('0x23cd')]['page']=0x1),!_0x905155&&(_0x250877[_0x2fbdb6('0x23cd')][_0x2fbdb6('0xdf8')]=_0x430a3c),_0x250877[_0x2fbdb6('0x20a4')]());});function _0x50bcfd(_0x38a09c){return function(_0x3cc049){_0x250877[_0x38a09c]=_0x3cc049||{'count':0x0,'rows':[]};};}function _0x46eb4a(){const _0x2163b1=_0x5ac571;_0x250877[_0x2163b1('0xd06')]&&_0x250877[_0x2163b1('0xd06')]['id']&&(_0x250877['queryHopper']['ContactId']=_0x250877[_0x2163b1('0xd06')]['id'],_0x250877[_0x2163b1('0x1067')][_0x2163b1('0x1cc8')]=(_0x250877[_0x2163b1('0x1067')][_0x2163b1('0xdf8')]-0x1)*_0x250877['queryHopper'][_0x2163b1('0x6f0')],_0x250877[_0x2163b1('0x1883')]=_0x12eda1[_0x2163b1('0x26cf')]['get'](_0x250877[_0x2163b1('0x1067')],_0x50bcfd(_0x2163b1('0x1c63')))[_0x2163b1('0xe53')]);}function _0x42f00a(){const _0x306906=_0x5ac571;_0x250877[_0x306906('0xd06')]&&_0x250877[_0x306906('0xd06')]['id']&&(_0x250877[_0x306906('0x721')][_0x306906('0x670')]=_0x250877[_0x306906('0xd06')]['id'],_0x250877[_0x306906('0x721')][_0x306906('0x1cc8')]=(_0x250877[_0x306906('0x721')][_0x306906('0xdf8')]-0x1)*_0x250877[_0x306906('0x721')][_0x306906('0x6f0')],_0x250877[_0x306906('0x1883')]=_0x12eda1[_0x306906('0x163f')]['get'](_0x250877['queryFinal'],_0x50bcfd(_0x306906('0x157d')))[_0x306906('0xe53')]);}function _0x214d70(){const _0x28bb26=_0x5ac571;_0x250877['contact']&&_0x250877[_0x28bb26('0xd06')]['id']&&(_0x250877[_0x28bb26('0x23cd')]['ContactId']=_0x250877['contact']['id'],_0x250877['queryHistory']['offset']=(_0x250877['queryHistory'][_0x28bb26('0xdf8')]-0x1)*_0x250877[_0x28bb26('0x23cd')][_0x28bb26('0x6f0')],_0x250877[_0x28bb26('0x1883')]=_0x12eda1[_0x28bb26('0x2583')][_0x28bb26('0x1e6e')](_0x250877['queryHistory'],_0x50bcfd(_0x28bb26('0x1f3f')))[_0x28bb26('0xe53')]);}function _0x14c544(){const _0x2a7544=_0x5ac571;_0x12eda1[_0x2a7544('0xa8b')]['get']({'fields':_0x2a7544('0x10f0'),'sort':'-updatedAt','nolimit':!![]})['$promise'][_0x2a7544('0x683')](function(_0x4a0eb0){_0x250877['jscriptyProjects']=_0x4a0eb0||{'count':0x0,'rows':[]};})['catch'](function(_0x22fd2d){const _0x42579d=_0x2a7544;if(_0x22fd2d[_0x42579d('0x5a5')]&&_0x22fd2d[_0x42579d('0x5a5')][_0x42579d('0x17f')]&&_0x22fd2d[_0x42579d('0x5a5')][_0x42579d('0x17f')]['length']){_0x250877[_0x42579d('0x17f')]=_0x22fd2d['data']['errors']||[{'message':_0x22fd2d[_0x42579d('0x1ff0')](),'type':'api.jscripty.account'}];for(let _0x37fd53=0x0;_0x37fd53<_0x22fd2d['data']['errors']['length'];_0x37fd53+=0x1){_0x346481[_0x42579d('0x52a')]({'title':_0x22fd2d[_0x42579d('0x5a5')][_0x42579d('0x17f')][_0x37fd53][_0x42579d('0xcf0')],'msg':_0x22fd2d['data'][_0x42579d('0x17f')][_0x37fd53][_0x42579d('0x8c2')]});}}else _0x346481[_0x42579d('0x52a')]({'title':_0x22fd2d['status']?_0x42579d('0x2168')+_0x22fd2d[_0x42579d('0x13ee')]+_0x42579d('0xbf6')+_0x22fd2d['statusText']:'api.jscripty.account','msg':_0x22fd2d[_0x42579d('0x5a5')]?JSON[_0x42579d('0x258a')](_0x22fd2d[_0x42579d('0x5a5')][_0x42579d('0x8c2')]):_0x22fd2d[_0x42579d('0x1ff0')]()});});}function _0x3f5c98(){const _0x3f7e48=_0x5ac571;_0x12eda1['user']['getMailAccounts']({'id':_0x250877[_0x3f7e48('0xc96')]['id'],'nolimit':!![]})[_0x3f7e48('0xe53')]['then'](function(_0x512adf){const _0x41666b=_0x3f7e48;_0x250877[_0x41666b('0x1093')]=_0x512adf||{'count':0x0,'rows':[]};})[_0x3f7e48('0x130a')](function(_0x24ed40){const _0x53c43f=_0x3f7e48;if(_0x24ed40[_0x53c43f('0x5a5')]&&_0x24ed40[_0x53c43f('0x5a5')]['errors']&&_0x24ed40[_0x53c43f('0x5a5')][_0x53c43f('0x17f')][_0x53c43f('0x1564')]){_0x250877[_0x53c43f('0x17f')]=_0x24ed40[_0x53c43f('0x5a5')][_0x53c43f('0x17f')]||[{'message':_0x24ed40['toString'](),'type':_0x53c43f('0x1a3b')}];for(let _0xa8f970=0x0;_0xa8f970<_0x24ed40[_0x53c43f('0x5a5')][_0x53c43f('0x17f')]['length'];_0xa8f970+=0x1){_0x346481['error']({'title':_0x24ed40[_0x53c43f('0x5a5')]['errors'][_0xa8f970][_0x53c43f('0xcf0')],'msg':_0x24ed40[_0x53c43f('0x5a5')]['errors'][_0xa8f970]['message']});}}else _0x346481[_0x53c43f('0x52a')]({'title':_0x24ed40[_0x53c43f('0x13ee')]?_0x53c43f('0x2168')+_0x24ed40[_0x53c43f('0x13ee')]+_0x53c43f('0xbf6')+_0x24ed40['statusText']:_0x53c43f('0x1a3b'),'msg':_0x24ed40[_0x53c43f('0x5a5')]?JSON['stringify'](_0x24ed40['data'][_0x53c43f('0x8c2')]):_0x24ed40[_0x53c43f('0x1ff0')]()});});}function _0x129993(){const _0x34b4cc=_0x5ac571;_0x12eda1[_0x34b4cc('0xc96')][_0x34b4cc('0x2842')]({'id':_0x250877[_0x34b4cc('0xc96')]['id'],'nolimit':!![]})['$promise'][_0x34b4cc('0x683')](function(_0x3ee277){const _0x13619c=_0x34b4cc;_0x250877[_0x13619c('0x2595')]=_0x3ee277||{'count':0x0,'rows':[]};})[_0x34b4cc('0x130a')](function(_0x41df79){const _0x1eb9ac=_0x34b4cc;if(_0x41df79[_0x1eb9ac('0x5a5')]&&_0x41df79[_0x1eb9ac('0x5a5')][_0x1eb9ac('0x17f')]&&_0x41df79[_0x1eb9ac('0x5a5')][_0x1eb9ac('0x17f')]['length']){_0x250877[_0x1eb9ac('0x17f')]=_0x41df79[_0x1eb9ac('0x5a5')][_0x1eb9ac('0x17f')]||[{'message':_0x41df79[_0x1eb9ac('0x1ff0')](),'type':_0x1eb9ac('0x188e')}];for(let _0x24dc97=0x0;_0x24dc97<_0x41df79[_0x1eb9ac('0x5a5')]['errors']['length'];_0x24dc97+=0x1){_0x346481[_0x1eb9ac('0x52a')]({'title':_0x41df79['data']['errors'][_0x24dc97][_0x1eb9ac('0xcf0')],'msg':_0x41df79[_0x1eb9ac('0x5a5')][_0x1eb9ac('0x17f')][_0x24dc97][_0x1eb9ac('0x8c2')]});}}else _0x346481[_0x1eb9ac('0x52a')]({'title':_0x41df79[_0x1eb9ac('0x13ee')]?_0x1eb9ac('0x2168')+_0x41df79['status']+_0x1eb9ac('0xbf6')+_0x41df79[_0x1eb9ac('0x24a9')]:_0x1eb9ac('0x188e'),'msg':_0x41df79[_0x1eb9ac('0x5a5')]?JSON[_0x1eb9ac('0x258a')](_0x41df79[_0x1eb9ac('0x5a5')][_0x1eb9ac('0x8c2')]):_0x41df79['toString']()});});}function _0x53e535(){const _0x42d10e=_0x5ac571;_0x12eda1['user'][_0x42d10e('0xf1e')]({'id':_0x250877[_0x42d10e('0xc96')]['id'],'nolimit':!![]})['$promise']['then'](function(_0x445994){const _0x37cf78=_0x42d10e;_0x250877[_0x37cf78('0x197c')]=_0x445994||{'count':0x0,'rows':[]};})[_0x42d10e('0x130a')](function(_0x1d1f55){const _0x22e996=_0x42d10e;if(_0x1d1f55[_0x22e996('0x5a5')]&&_0x1d1f55[_0x22e996('0x5a5')][_0x22e996('0x17f')]&&_0x1d1f55[_0x22e996('0x5a5')][_0x22e996('0x17f')][_0x22e996('0x1564')]){_0x250877['errors']=_0x1d1f55[_0x22e996('0x5a5')]['errors']||[{'message':_0x1d1f55[_0x22e996('0x1ff0')](),'type':_0x22e996('0x116a')}];for(let _0xed747e=0x0;_0xed747e<_0x1d1f55[_0x22e996('0x5a5')][_0x22e996('0x17f')]['length'];_0xed747e+=0x1){_0x346481['error']({'title':_0x1d1f55[_0x22e996('0x5a5')][_0x22e996('0x17f')][_0xed747e][_0x22e996('0xcf0')],'msg':_0x1d1f55['data'][_0x22e996('0x17f')][_0xed747e]['message']});}}else _0x346481['error']({'title':_0x1d1f55['status']?_0x22e996('0x2168')+_0x1d1f55['status']+_0x22e996('0xbf6')+_0x1d1f55[_0x22e996('0x24a9')]:_0x22e996('0x116a'),'msg':_0x1d1f55['data']?JSON[_0x22e996('0x258a')](_0x1d1f55[_0x22e996('0x5a5')][_0x22e996('0x8c2')]):_0x1d1f55[_0x22e996('0x1ff0')]()});});}function _0x2af6a5(){const _0x5b749d=_0x5ac571;_0x12eda1[_0x5b749d('0xc96')][_0x5b749d('0x1fb9')]({'id':_0x250877[_0x5b749d('0xc96')]['id'],'nolimit':!![]})[_0x5b749d('0xe53')][_0x5b749d('0x683')](function(_0x5e703d){const _0x2af2db=_0x5b749d;_0x250877[_0x2af2db('0x263c')]=_0x5e703d||{'count':0x0,'rows':[]};})[_0x5b749d('0x130a')](function(_0x14ff63){const _0x3d8dea=_0x5b749d;if(_0x14ff63[_0x3d8dea('0x5a5')]&&_0x14ff63[_0x3d8dea('0x5a5')][_0x3d8dea('0x17f')]&&_0x14ff63[_0x3d8dea('0x5a5')][_0x3d8dea('0x17f')]['length']){_0x250877[_0x3d8dea('0x17f')]=_0x14ff63['data'][_0x3d8dea('0x17f')]||[{'message':_0x14ff63[_0x3d8dea('0x1ff0')](),'type':_0x3d8dea('0x653')}];for(let _0x4ff982=0x0;_0x4ff982<_0x14ff63[_0x3d8dea('0x5a5')][_0x3d8dea('0x17f')][_0x3d8dea('0x1564')];_0x4ff982+=0x1){_0x346481[_0x3d8dea('0x52a')]({'title':_0x14ff63['data'][_0x3d8dea('0x17f')][_0x4ff982][_0x3d8dea('0xcf0')],'msg':_0x14ff63[_0x3d8dea('0x5a5')][_0x3d8dea('0x17f')][_0x4ff982][_0x3d8dea('0x8c2')]});}}else _0x346481[_0x3d8dea('0x52a')]({'title':_0x14ff63[_0x3d8dea('0x13ee')]?_0x3d8dea('0x2168')+_0x14ff63[_0x3d8dea('0x13ee')]+_0x3d8dea('0xbf6')+_0x14ff63[_0x3d8dea('0x24a9')]:_0x3d8dea('0x653'),'msg':_0x14ff63[_0x3d8dea('0x5a5')]?JSON[_0x3d8dea('0x258a')](_0x14ff63['data'][_0x3d8dea('0x8c2')]):_0x14ff63['toString']()});});}function _0x5c6ef6(){const _0x2381ad=_0x5ac571;_0x12eda1['user']['getOpenchannelAccounts']({'id':_0x250877[_0x2381ad('0xc96')]['id'],'nolimit':!![]})[_0x2381ad('0xe53')]['then'](function(_0x412910){const _0x21cfaa=_0x2381ad;_0x250877[_0x21cfaa('0x1952')]=_0x412910||{'count':0x0,'rows':[]};})[_0x2381ad('0x130a')](function(_0x2097ae){const _0x9883a6=_0x2381ad;if(_0x2097ae[_0x9883a6('0x5a5')]&&_0x2097ae[_0x9883a6('0x5a5')][_0x9883a6('0x17f')]&&_0x2097ae['data'][_0x9883a6('0x17f')]['length']){_0x250877[_0x9883a6('0x17f')]=_0x2097ae[_0x9883a6('0x5a5')][_0x9883a6('0x17f')]||[{'message':_0x2097ae['toString'](),'type':_0x9883a6('0x2ab')}];for(let _0x5b34c8=0x0;_0x5b34c8<_0x2097ae[_0x9883a6('0x5a5')][_0x9883a6('0x17f')]['length'];_0x5b34c8+=0x1){_0x346481['error']({'title':_0x2097ae[_0x9883a6('0x5a5')][_0x9883a6('0x17f')][_0x5b34c8][_0x9883a6('0xcf0')],'msg':_0x2097ae[_0x9883a6('0x5a5')][_0x9883a6('0x17f')][_0x5b34c8][_0x9883a6('0x8c2')]});}}else _0x346481[_0x9883a6('0x52a')]({'title':_0x2097ae[_0x9883a6('0x13ee')]?'API:'+_0x2097ae['status']+'\x20-\x20'+_0x2097ae[_0x9883a6('0x24a9')]:_0x9883a6('0x2ab'),'msg':_0x2097ae[_0x9883a6('0x5a5')]?JSON[_0x9883a6('0x258a')](_0x2097ae['data']['message']):_0x2097ae[_0x9883a6('0x1ff0')]()});});}function _0x54f961(){const _0x18c47c=_0x5ac571;_0x12eda1[_0x18c47c('0xc96')][_0x18c47c('0x24ee')]({'id':_0x250877[_0x18c47c('0xc96')]['id'],'nolimit':!![]})['$promise'][_0x18c47c('0x683')](function(_0x1d20bf){const _0xd731b1=_0x18c47c;_0x250877[_0xd731b1('0x11e2')]=_0x1d20bf||{'count':0x0,'rows':[]};})[_0x18c47c('0x130a')](function(_0x6a2204){const _0x186beb=_0x18c47c;if(_0x6a2204['data']&&_0x6a2204[_0x186beb('0x5a5')][_0x186beb('0x17f')]&&_0x6a2204['data'][_0x186beb('0x17f')][_0x186beb('0x1564')]){_0x250877[_0x186beb('0x17f')]=_0x6a2204[_0x186beb('0x5a5')][_0x186beb('0x17f')]||[{'message':_0x6a2204[_0x186beb('0x1ff0')](),'type':_0x186beb('0xb7c')}];for(let _0x1fa7ee=0x0;_0x1fa7ee<_0x6a2204[_0x186beb('0x5a5')][_0x186beb('0x17f')][_0x186beb('0x1564')];_0x1fa7ee+=0x1){_0x346481[_0x186beb('0x52a')]({'title':_0x6a2204[_0x186beb('0x5a5')][_0x186beb('0x17f')][_0x1fa7ee][_0x186beb('0xcf0')],'msg':_0x6a2204[_0x186beb('0x5a5')][_0x186beb('0x17f')][_0x1fa7ee][_0x186beb('0x8c2')]});}}else _0x346481[_0x186beb('0x52a')]({'title':_0x6a2204[_0x186beb('0x13ee')]?_0x186beb('0x2168')+_0x6a2204[_0x186beb('0x13ee')]+_0x186beb('0xbf6')+_0x6a2204[_0x186beb('0x24a9')]:_0x186beb('0xb7c'),'msg':_0x6a2204[_0x186beb('0x5a5')]?JSON['stringify'](_0x6a2204[_0x186beb('0x5a5')][_0x186beb('0x8c2')]):_0x6a2204['toString']()});});}function _0x42a612(){const _0x4c01ba=_0x5ac571;_0x12eda1['user'][_0x4c01ba('0x16c3')]({'id':_0x250877[_0x4c01ba('0xc96')]['id'],'nolimit':!![]})[_0x4c01ba('0xe53')]['then'](function(_0x21282b){_0x250877['lists']=_0x21282b||{'count':0x0,'rows':[]};})['catch'](function(_0x383d63){const _0x3f41a3=_0x4c01ba;if(_0x383d63['data']&&_0x383d63[_0x3f41a3('0x5a5')][_0x3f41a3('0x17f')]&&_0x383d63['data'][_0x3f41a3('0x17f')][_0x3f41a3('0x1564')]){_0x250877[_0x3f41a3('0x17f')]=_0x383d63[_0x3f41a3('0x5a5')]['errors']||[{'message':_0x383d63[_0x3f41a3('0x1ff0')](),'type':'api.cm.lists'}];for(let _0xfc8d69=0x0;_0xfc8d69<_0x383d63[_0x3f41a3('0x5a5')][_0x3f41a3('0x17f')][_0x3f41a3('0x1564')];_0xfc8d69+=0x1){_0x346481['error']({'title':_0x383d63['data'][_0x3f41a3('0x17f')][_0xfc8d69]['type'],'msg':_0x383d63[_0x3f41a3('0x5a5')][_0x3f41a3('0x17f')][_0xfc8d69][_0x3f41a3('0x8c2')]});}}else _0x346481['error']({'title':_0x383d63[_0x3f41a3('0x13ee')]?_0x3f41a3('0x2168')+_0x383d63['status']+_0x3f41a3('0xbf6')+_0x383d63[_0x3f41a3('0x24a9')]:'api.cm.lists','msg':_0x383d63['data']?JSON['stringify'](_0x383d63['data'][_0x3f41a3('0x8c2')]):_0x383d63['toString']()});});}function _0x198164(_0x45e952){const _0x3e3b22=_0x5ac571;_0x515333['show']({'controller':'DuplicateContactDialogController','controllerAs':'vm','templateUrl':_0x24dbc7,'parent':angular['element'](_0x12ed40[_0x3e3b22('0x18e5')]),'targetEvent':_0x45e952,'clickOutsideToClose':!![],'resolve':{'contact':[_0x3e3b22('0x4b1'),function(_0x1b6dc6){const _0x49b99f=_0x3e3b22;return _0x1b6dc6[_0x49b99f('0xed7')](_0x49b99f('0x23ec'),{'id':_0x250877[_0x49b99f('0xd06')]['id']});}],'lists':[_0x3e3b22('0x4b1'),function(_0x41b447){const _0xbfce62=_0x3e3b22;return _0x41b447['resolve'](_0xbfce62('0x2001'),{'id':_0x27ef41[_0xbfce62('0x20b2')]()['id'],'fields':_0xbfce62('0xa10')});}]},'locals':{'contacts':[]}});}function _0xf022cb(_0x163ba8){const _0x31bcc5=_0x5ac571;_0x515333[_0x31bcc5('0x1d4')]({'controller':'MergeContactDialogController','controllerAs':'vm','templateUrl':_0x7650f,'parent':angular[_0x31bcc5('0x1fcc')](_0x12ed40[_0x31bcc5('0x18e5')]),'targetEvent':_0x163ba8,'clickOutsideToClose':!![],'resolve':{'contact':[_0x31bcc5('0x4b1'),function(_0x491328){const _0x553ee5=_0x31bcc5;return _0x491328[_0x553ee5('0xed7')](_0x553ee5('0x23ec'),{'id':_0x250877[_0x553ee5('0xd06')]['id']});}],'lists':['apiResolver',function(_0x556e68){const _0x1a0e93=_0x31bcc5;return _0x556e68[_0x1a0e93('0xed7')]('user@getLists',{'id':_0x27ef41[_0x1a0e93('0x20b2')]()['id'],'fields':_0x1a0e93('0xa10')});}]},'locals':{'contacts':[]}})[_0x31bcc5('0x683')](function(_0x3c598f){const _0x7da6b9=_0x31bcc5;if(_0x3c598f){for(const _0x5b29cb in _0x2c6dfd['$parent']['$parent'][_0x7da6b9('0x1cd5')]['vm']['tabs']){if(typeof _0x2c6dfd['$parent'][_0x7da6b9('0x1cd5')][_0x7da6b9('0x1cd5')]['vm'][_0x7da6b9('0x1a9')][_0x5b29cb]!==_0x7da6b9('0x1867')){const _0x1d0b7a=_0x2c6dfd[_0x7da6b9('0x1cd5')][_0x7da6b9('0x1cd5')][_0x7da6b9('0x1cd5')]['vm'][_0x7da6b9('0x1a9')][_0x5b29cb];_0x1d0b7a&&_0x1d0b7a[_0x7da6b9('0xd06')]&&(_0x3c598f['from']&&_0x3c598f[_0x7da6b9('0x705')]['id']&&_0x3c598f[_0x7da6b9('0x705')]['id']===_0x1d0b7a[_0x7da6b9('0xd06')]['id']&&_0x2c6dfd['$parent']['$parent'][_0x7da6b9('0x1cd5')]['vm'][_0x7da6b9('0x1cb8')](_0x1d0b7a),_0x3c598f['to']&&_0x3c598f['to']['id']&&_0x3c598f['to']['id']===_0x1d0b7a[_0x7da6b9('0xd06')]['id']&&_0x2c6dfd[_0x7da6b9('0x1cd5')][_0x7da6b9('0x1cd5')][_0x7da6b9('0x1cd5')]['vm']['removeTab'](_0x1d0b7a));}}_0x3c598f[_0x7da6b9('0x1476')]&&_0x2c6dfd['$parent'][_0x7da6b9('0x1cd5')][_0x7da6b9('0x1cd5')]['vm'][_0x7da6b9('0x15e')](_0x3c598f[_0x7da6b9('0x1476')]);}});}function _0xd0294f(_0x55142c,_0x5975e6){const _0x37d062=_0x5ac571,_0x3b89c9=_0x250877['user']['voicePause']||_0x250877[_0x37d062('0xc96')][_0x37d062('0x1938')]||_0x250877['user']['mailPause']||_0x250877['user']['openchannelPause']||_0x250877[_0x37d062('0xc96')]['faxPause'],_0x2c08c1=_0x5975e6['mandatoryDisposition'];if(_0x250877[_0x37d062('0x2337')]){_0x346481[_0x37d062('0x52a')]({'title':_0x37d062('0x190d'),'msg':'Please\x20save\x20the\x20contact\x20before\x20disposing!'});return;}_0x515333[_0x37d062('0x1d4')]({'controller':_0x37d062('0x179a'),'controllerAs':'vm','templateUrl':_0x8be7e1,'parent':angular[_0x37d062('0x1fcc')](_0x12ed40[_0x37d062('0x18e5')]),'targetEvent':_0x5975e6,'clickOutsideToClose':!_0x5975e6['mandatoryDisposition'],'escapeToClose':!_0x5975e6[_0x37d062('0x989')],'resolve':{'globalDispositions':[_0x37d062('0x4b1'),function(_0x44aba5){const _0x152e4a=_0x37d062;return _0x44aba5[_0x152e4a('0xed7')]('disposition@get',{'MailAccountId':_0x152e4a('0x13c'),'FaxAccountId':_0x152e4a('0x13c'),'SmsAccountId':_0x152e4a('0x13c'),'WhatsappAccountId':_0x152e4a('0x13c'),'OpenchannelAccountId':_0x152e4a('0x13c'),'ChatWebsiteId':'null','ListId':_0x152e4a('0x13c')});}]},'onRemoving':function(){const _0x12b882=_0x37d062;_0x250877[_0x12b882('0xc96')]&&_0x2c08c1&&!_0x3b89c9&&_0x12eda1[_0x12b882('0xc96')][_0x12b882('0x1778')]({'id':_0x250877[_0x12b882('0xc96')]['id']})['$promise'][_0x12b882('0x130a')](function(_0x354ef3){const _0x23b68e=_0x12b882;console[_0x23b68e('0x52a')](_0x354ef3);});},'locals':{'dispositions':_0x250877[_0x37d062('0x1904')]['dispositions'],'contact':_0x250877[_0x37d062('0xd06')],'call':_0x5975e6}})[_0x37d062('0x683')](function(_0x30598d){const _0x485bed=_0x37d062;if(_0x30598d){if(_0x30598d===_0x485bed('0x15ef'))_0x346481[_0x485bed('0x53')]({'title':_0x21edce[_0x485bed('0x2728')](_0x485bed('0x1df0')),'msg':_0x21edce[_0x485bed('0x2728')](_0x485bed('0x2ee'))+'\x20'+_0x30598d});else{if(_0x30598d===_0x485bed('0x27b7')||_0x30598d===_0x485bed('0x2029')){}else _0x346481[_0x485bed('0x53')]({'title':_0x21edce[_0x485bed('0x2728')]('DASHBOARDS.INFO'),'msg':_0x21edce['instant'](_0x485bed('0x13d2'))});}}for(const _0x8dbf2c in _0x2c6dfd['$parent'][_0x485bed('0x1cd5')]['$parent']['vm'][_0x485bed('0x1a9')]){if(typeof _0x2c6dfd['$parent'][_0x485bed('0x1cd5')]['$parent']['vm'][_0x485bed('0x1a9')][_0x8dbf2c]!==_0x485bed('0x1867')){const _0x55d848=_0x2c6dfd[_0x485bed('0x1cd5')]['$parent'][_0x485bed('0x1cd5')]['vm'][_0x485bed('0x1a9')][_0x8dbf2c];_0x2e3ca0()[_0x485bed('0x3ec')](_0x55d848[_0x485bed('0x394')],function(_0x194a7d){const _0x40759c=_0x485bed;return _0x194a7d[_0x40759c('0x573')]===_0x5975e6['uniqueid'];});}}_0x2c6dfd['$parent']['vm']['updateLocalStorage']();});}function _0x22bb98(_0x5ebb23){const _0x5ad454=_0x5ac571;return _0x12eda1[_0x5ad454('0x259b')][_0x5ad454('0xcb')]({'id':_0x5ebb23})['$promise'][_0x5ad454('0x683')](function(_0x379060){const _0x4dffec=_0x5ad454;_0x250877[_0x4dffec('0x1904')][_0x4dffec('0xc4d')]=_0x379060;})['catch'](function(_0x2dc593){const _0xa414cb=_0x5ad454;_0x346481[_0xa414cb('0x52a')]({'title':_0x2dc593['status']?_0xa414cb('0x2168')+_0x2dc593[_0xa414cb('0x13ee')]+_0xa414cb('0xbf6')+_0x2dc593[_0xa414cb('0x24a9')]:'LIST:GETCustomFields','msg':_0x2dc593[_0xa414cb('0x5a5')]?JSON[_0xa414cb('0x258a')](_0x2dc593[_0xa414cb('0x5a5')]):_0x2dc593[_0xa414cb('0x1ff0')]()});});}function _0x454e60(_0x541e90){return _0x541e90===null?undefined:new Date(_0x541e90);}function _0x423ab6(_0x331d41){const _0x5a0916=_0x5ac571;try{_0x331d41[_0x5a0916('0x4f5')]=_0x19c0ff()[_0x5a0916('0x977')](_0x331d41[_0x5a0916('0x4f5')],{'contact':_0x250877[_0x5a0916('0xd06')],'user':_0x250877[_0x5a0916('0xc96')]});}catch(_0x10e658){console[_0x5a0916('0x52a')](_0x10e658);}try{_0x2c6dfd['$parent'][_0x5a0916('0x1cd5')][_0x5a0916('0x1cd5')]['vm']['addTab']({'type':'jscripty','title':_0x331d41['name'],'icon':_0x5a0916('0xf7d'),'color':_0x5a0916('0x1199'),'project':_0x331d41,'contact':_0x250877[_0x5a0916('0xd06')]});}catch(_0x506c55){_0x346481[_0x5a0916('0x52a')]({'title':_0x5a0916('0xdef'),'msg':_0x5a0916('0x17a7')+JSON[_0x5a0916('0x258a')](_0x506c55)});}}function _0x56bc9e(_0x4803fc){const _0x5df08d=_0x5ac571;return _0x27ef41[_0x5df08d('0x5e3')](_0x4803fc);}_0x2c6dfd[_0x5ac571('0x26a2')](_0x5ac571('0x4b8'),function(){});}const _0x2b96df=_0x9a5a2c;_0x3112ab[_0x189033('0x14be')]=['$mdDialog','$q','toasty',_0x189033('0x56b'),_0x189033('0x191e'),_0x189033('0x12f6'),'call',_0x189033('0xd06'),_0x189033('0xba1'),_0x189033('0x1d08')];function _0x3112ab(_0x7259a4,_0x5a542c,_0xc07622,_0x50f2b7,_0x21c72a,_0x2de73e,_0x13c82b,_0x95dab7,_0x19e5b3,_0x13514e){const _0xdb5b9b=_0x189033,_0x5e48ef=this;_0x5e48ef['isReschedule']=![],_0x5e48ef[_0xdb5b9b('0x202f')]=![],_0x5e48ef[_0xdb5b9b('0x1bd9')]=undefined,_0x5e48ef['queueCampaigns']={'count':0x0,'rows':[]},_0x5e48ef['dispositions']=_0x21c72a[_0xdb5b9b('0xf5d')],_0x5e48ef[_0xdb5b9b('0x12f6')]=_0x2de73e['rows'],_0x5e48ef['contact']=_0x95dab7,_0x5e48ef[_0xdb5b9b('0x164f')]=_0x13c82b,_0x5e48ef[_0xdb5b9b('0x2203')]=_0x5e48ef['call'][_0xdb5b9b('0x2203')]||undefined,_0x5e48ef[_0xdb5b9b('0x1f87')]=![],_0x5e48ef[_0xdb5b9b('0x4d0')]=![],_0x5e48ef['hopper']={'minDate':new Date(),'dateTime':new Date()};_0x5e48ef[_0xdb5b9b('0x164f')]&&_0x5e48ef[_0xdb5b9b('0x164f')][_0xdb5b9b('0x220b')]&&_0x5e48ef[_0xdb5b9b('0x164f')][_0xdb5b9b('0x220b')][_0xdb5b9b('0x20fa')]?(_0x5e48ef[_0xdb5b9b('0x1f87')]=!![],_0x50f2b7[_0xdb5b9b('0x204c')][_0xdb5b9b('0x1582')]({'id':_0x5e48ef[_0xdb5b9b('0x164f')]['variables'][_0xdb5b9b('0x20fa')]})[_0xdb5b9b('0xe53')]['then'](function(_0x3c81fa){const _0xdebe1f=_0xdb5b9b;_0x3c81fa&&_0x3c81fa[_0xdebe1f('0xf5d')]&&_0x3c81fa[_0xdebe1f('0xf5d')]['length']>0x0&&(_0x5e48ef[_0xdebe1f('0x4d0')]=!![]);})[_0xdb5b9b('0x130a')](function(_0x433cac){const _0x21630d=_0xdb5b9b;_0xc07622[_0x21630d('0x52a')]({'title':_0x433cac[_0x21630d('0x13ee')]?_0x21630d('0x2168')+_0x433cac[_0x21630d('0x13ee')]+_0x21630d('0xbf6')+_0x433cac[_0x21630d('0x24a9')]:_0x21630d('0x1abe'),'msg':_0x433cac[_0x21630d('0x5a5')]?JSON[_0x21630d('0x258a')](_0x433cac[_0x21630d('0x5a5')]):_0x433cac[_0x21630d('0x1ff0')]()});})):_0x50f2b7[_0xdb5b9b('0xc96')]['getQueues']({'id':_0x19e5b3[_0xdb5b9b('0x20b2')]()['id'],'fields':_0xdb5b9b('0x1fe9'),'channel':_0xdb5b9b('0xcf2'),'type':_0xdb5b9b('0x17cd'),'nolimit':!![]})['$promise'][_0xdb5b9b('0x683')](function(_0x1a0de6){const _0x4d4022=_0xdb5b9b;_0x5e48ef[_0x4d4022('0x2022')]=_0x1a0de6||{'count':0x0,'rows':[]};})[_0xdb5b9b('0x130a')](function(_0x24f669){const _0x5de4c8=_0xdb5b9b;console[_0x5de4c8('0x52a')](_0x24f669);});_0x5e48ef[_0xdb5b9b('0xab3')]=_0x2892a6,_0x5e48ef[_0xdb5b9b('0x2224')]=_0x312b20,_0x5e48ef[_0xdb5b9b('0x15c6')]=_0x1c47c7,_0x5e48ef['closeDialog']=_0x23799,_0x5e48ef[_0xdb5b9b('0x1679')]=_0x43a2a5;function _0x2892a6(_0x22b66d){const _0x530633=_0xdb5b9b,_0x182709=_0x2e3ca0()[_0x530633('0x41c')](_0x5e48ef[_0x530633('0x191e')],_0x5e48ef[_0x530633('0x12f6')],'id');switch(_0x22b66d){case _0x530633('0x2f5'):_0x5e48ef[_0x530633('0x1ede')]=_0x5e48ef[_0x530633('0xb82')],_0x5e48ef[_0x530633('0x58')]=_0x2e3ca0()[_0x530633('0x7a2')](_0x182709,[_0x530633('0x1b62'),_0x5e48ef[_0x530633('0xb82')]['id']]),_0x5e48ef[_0x530633('0xc5d')]=undefined,_0x5e48ef[_0x530633('0xde1')]=undefined,_0x5e48ef[_0x530633('0x4cf')]=![];break;case _0x530633('0x1f7b'):_0x5e48ef[_0x530633('0x1ede')]=_0x5e48ef[_0x530633('0xc5d')],_0x5e48ef[_0x530633('0x4cf')]=_0x2e3ca0()[_0x530633('0x7a2')](_0x182709,[_0x530633('0x1b62'),_0x5e48ef[_0x530633('0xc5d')]['id']]);break;case _0x530633('0x1d77'):_0x5e48ef[_0x530633('0x1ede')]=_0x5e48ef[_0x530633('0xde1')];break;}}function _0x312b20(_0x481818){const _0x453df4=_0xdb5b9b;if(_0x481818===_0x453df4('0x1f7b'))_0x5e48ef[_0x453df4('0xc5d')]=undefined,_0x5e48ef[_0x453df4('0xde1')]=undefined,_0x5e48ef['selectedDisposition']=_0x5e48ef[_0x453df4('0xb82')];else _0x481818==='third'&&(_0x5e48ef[_0x453df4('0xde1')]=undefined,_0x5e48ef['selectedDisposition']=_0x5e48ef[_0x453df4('0xc5d')]);}function _0x568fe7(){const _0x189777=_0xdb5b9b,_0x483771=_0x5e48ef[_0x189777('0x1ede')]?_0x5e48ef[_0x189777('0x1ede')][_0x189777('0x60a')][_0x189777('0x93a')]():undefined;return{'id':_0x5e48ef['call'][_0x189777('0x573')],'disposition':_0x5e48ef[_0x189777('0xb82')]?_0x5e48ef['firstLevelDisposition']['name']:null,'secondDisposition':_0x5e48ef[_0x189777('0xc5d')]?_0x5e48ef[_0x189777('0xc5d')]['name']:null,'thirdDisposition':_0x5e48ef[_0x189777('0xde1')]?_0x5e48ef[_0x189777('0xde1')][_0x189777('0x60a')]:null,'dispositionat':_0x1aaf93()(),'amd':_0x483771===_0x189777('0x1ed1'),'fax':_0x483771===_0x189777('0x23e9'),'blacklist':_0x483771===_0x189777('0x185c'),'recallme':_0x483771===_0x189777('0x202f'),'UserId':_0x483771===_0x189777('0x202f')?_0x19e5b3[_0x189777('0x20b2')]()['id']:null,'OwnerId':_0x19e5b3[_0x189777('0x20b2')]()['id']};}function _0x51d7d2(){const _0x34f9a0=_0xdb5b9b;return _0x50f2b7[_0x34f9a0('0x337')]['update']({'id':_0x5e48ef[_0x34f9a0('0x164f')][_0x34f9a0('0x573')],'userDisposition':_0x5e48ef[_0x34f9a0('0xb82')]?_0x5e48ef[_0x34f9a0('0xb82')]['name']:null,'userSecondDisposition':_0x5e48ef[_0x34f9a0('0xc5d')]?_0x5e48ef['secondLevelDisposition'][_0x34f9a0('0x60a')]:null,'userThirdDisposition':_0x5e48ef[_0x34f9a0('0xde1')]?_0x5e48ef[_0x34f9a0('0xde1')][_0x34f9a0('0x60a')]:null,'note':_0x5e48ef[_0x34f9a0('0x2203')],'UserId':_0x19e5b3[_0x34f9a0('0x20b2')]()['id'],'ContactId':_0x5e48ef[_0x34f9a0('0xd06')]['id']})[_0x34f9a0('0xe53')]['catch'](function(_0x31e669){const _0x132788=_0x34f9a0;_0xc07622[_0x132788('0x52a')]({'title':_0x31e669[_0x132788('0x13ee')]?'API:'+_0x31e669[_0x132788('0x13ee')]+_0x132788('0xbf6')+_0x31e669[_0x132788('0x24a9')]:_0x132788('0x316'),'msg':_0x31e669['data']?JSON[_0x132788('0x258a')](_0x31e669['data']):_0x31e669[_0x132788('0x1ff0')]()});});}function _0xbbf0dd(){const _0xf742c4=_0xdb5b9b;return _0x50f2b7[_0xf742c4('0x52f')]['get']({'uniqueid':_0x5e48ef['call'][_0xf742c4('0x573')]})['$promise'][_0xf742c4('0x683')](function(_0x10a39a){const _0x5816a1=_0xf742c4;if(_0x10a39a)for(let _0x4bd432=0x0;_0x4bd432<_0x10a39a[_0x5816a1('0xf5d')]['length'];_0x4bd432+=0x1){_0x50f2b7['voiceRecording']['update']({'id':_0x10a39a[_0x5816a1('0xf5d')][_0x4bd432]['id'],'userDisposition':_0x5e48ef[_0x5816a1('0xb82')]?_0x5e48ef[_0x5816a1('0xb82')][_0x5816a1('0x60a')]:null,'userSecondDisposition':_0x5e48ef[_0x5816a1('0xc5d')]?_0x5e48ef[_0x5816a1('0xc5d')][_0x5816a1('0x60a')]:null,'userThirdDisposition':_0x5e48ef[_0x5816a1('0xde1')]?_0x5e48ef[_0x5816a1('0xde1')][_0x5816a1('0x60a')]:null})[_0x5816a1('0xe53')][_0x5816a1('0x130a')](function(_0x573876){const _0x17b324=_0x5816a1;_0xc07622['error']({'title':_0x573876[_0x17b324('0x13ee')]?_0x17b324('0x2168')+_0x573876['status']+'\x20-\x20'+_0x573876['statusText']:'SYSTEM:UPDATEVOICERECORDING','msg':_0x573876[_0x17b324('0x5a5')]?JSON[_0x17b324('0x258a')](_0x573876[_0x17b324('0x5a5')]):_0x573876['toString']()});});}})[_0xf742c4('0x130a')](function(_0x5b34db){const _0x4aa929=_0xf742c4;_0xc07622[_0x4aa929('0x52a')]({'title':_0x5b34db[_0x4aa929('0x13ee')]?_0x4aa929('0x2168')+_0x5b34db['status']+_0x4aa929('0xbf6')+_0x5b34db['statusText']:'SYSTEM:UPDATEVOICERECORDING','msg':_0x5b34db[_0x4aa929('0x5a5')]?JSON['stringify'](_0x5b34db[_0x4aa929('0x5a5')]):_0x5b34db[_0x4aa929('0x1ff0')]()});});}function _0x59480b(){const _0x16f6d2=_0xdb5b9b;return _0x50f2b7[_0x16f6d2('0x163f')][_0x16f6d2('0x2480')](_0x568fe7())['$promise'][_0x16f6d2('0x130a')](function(_0x43a169){const _0x42afbf=_0x16f6d2;_0xc07622[_0x42afbf('0x52a')]({'title':_0x43a169[_0x42afbf('0x13ee')]?_0x42afbf('0x2168')+_0x43a169[_0x42afbf('0x13ee')]+_0x42afbf('0xbf6')+_0x43a169[_0x42afbf('0x24a9')]:'SYSTEM:UPDATECMHOPPERFINAL','msg':_0x43a169[_0x42afbf('0x5a5')]?JSON[_0x42afbf('0x258a')](_0x43a169[_0x42afbf('0x5a5')]):_0x43a169[_0x42afbf('0x1ff0')]()});});}function _0x1ceac8(){const _0x128ef0=_0xdb5b9b;return _0x50f2b7['cmHopperHistory'][_0x128ef0('0x2480')](_0x568fe7())[_0x128ef0('0xe53')]['catch'](function(_0x2d361a){const _0x53a479=_0x128ef0;_0xc07622[_0x53a479('0x52a')]({'title':_0x2d361a[_0x53a479('0x13ee')]?_0x53a479('0x2168')+_0x2d361a[_0x53a479('0x13ee')]+_0x53a479('0xbf6')+_0x2d361a[_0x53a479('0x24a9')]:_0x53a479('0xe47'),'msg':_0x2d361a[_0x53a479('0x5a5')]?JSON[_0x53a479('0x258a')](_0x2d361a['data']):_0x2d361a['toString']()});});}function _0x37ebad(_0x4da37b){const _0x263a83=_0xdb5b9b;if(_0x4da37b)return _0x50f2b7[_0x263a83('0x204c')]['getBlackLists']({'id':_0x4da37b,'type':_0x263a83('0x17cd'),'fields':'id'})[_0x263a83('0xe53')][_0x263a83('0x683')](function(_0xa51ce1){const _0x335516=_0x263a83,_0x6cbc79=[];if(_0xa51ce1&&_0xa51ce1[_0x335516('0x50d')]>0x0){for(let _0x11802b=0x0;_0x11802b<_0xa51ce1['rows'][_0x335516('0x1564')];_0x11802b+=0x1){const _0x8a6f60=angular[_0x335516('0x1a86')](_0x5e48ef[_0x335516('0xd06')]);delete _0x8a6f60['id'],_0x8a6f60[_0x335516('0x1e4f')]=_0xa51ce1['rows'][_0x11802b]['id'],_0x6cbc79['push'](_0x50f2b7[_0x335516('0x276e')][_0x335516('0xb0a')](_0x8a6f60)[_0x335516('0xe53')]);}return _0x5a542c[_0x335516('0x252c')](_0x6cbc79);}_0xc07622[_0x335516('0x53')]({'title':_0x13514e[_0x335516('0x2728')](_0x335516('0x1df0')),'msg':_0x13514e['instant'](_0x335516('0x24f8'))+'\x20'+_0x5e48ef[_0x335516('0x1ede')]}),_0x5e48ef['selectedDisposition']=undefined;return;})[_0x263a83('0x683')](function(_0x4140aa){const _0x1792ec=_0x263a83;_0x4140aa&&_0x7259a4[_0x1792ec('0x1715')](_0x5e48ef[_0x1792ec('0x1ede')]?_0x5e48ef[_0x1792ec('0x1ede')]['name'][_0x1792ec('0x80')]():'');})[_0x263a83('0x130a')](function(_0x229512){const _0x27e866=_0x263a83;_0xc07622[_0x27e866('0x52a')]({'title':_0x229512[_0x27e866('0x13ee')]?_0x27e866('0x2168')+_0x229512['status']+_0x27e866('0xbf6')+_0x229512[_0x27e866('0x24a9')]:_0x27e866('0x24a2'),'msg':_0x229512[_0x27e866('0x5a5')]?JSON[_0x27e866('0x258a')](_0x229512['data']):_0x229512['toString']()}),_0x7259a4[_0x27e866('0x1715')](_0x5e48ef[_0x27e866('0x1ede')]?_0x5e48ef[_0x27e866('0x1ede')][_0x27e866('0x60a')][_0x27e866('0x80')]():'');});}function _0x1c47c7(_0x2a4844){const _0x16be1f=_0xdb5b9b;_0x5e48ef['selectedDisposition']=_0x2e3ca0()[_0x16be1f('0x8f2')](_0x2a4844)?_0x5e48ef[_0x16be1f('0x1ede')]:{'name':_0x2a4844};_0x2a4844&&(_0x5e48ef[_0x16be1f('0xb82')]=_0x5e48ef[_0x16be1f('0x1ede')]);_0x5e48ef['call'][_0x16be1f('0x2203')]=_0x5e48ef[_0x16be1f('0x2203')],_0x51d7d2(),_0xbbf0dd();_0x5e48ef[_0x16be1f('0x1f87')]&&(_0x59480b(),_0x1ceac8());if(!_0x2e3ca0()[_0x16be1f('0x8f2')](_0x5e48ef[_0x16be1f('0x1ede')]))switch(_0x5e48ef[_0x16be1f('0x1ede')][_0x16be1f('0x60a')]['toLowerCase']()){case'blacklist':_0x5e48ef[_0x16be1f('0x164f')]&&_0x5e48ef[_0x16be1f('0x164f')][_0x16be1f('0x220b')]&&_0x5e48ef[_0x16be1f('0x164f')][_0x16be1f('0x220b')][_0x16be1f('0x20fa')]&&_0x37ebad(_0x5e48ef[_0x16be1f('0x164f')][_0x16be1f('0x220b')]['xmd-voicequeueid']);break;case _0x16be1f('0x2523'):_0x5e48ef['isReschedule']=!![],_0x5e48ef[_0x16be1f('0x202f')]=![];break;case _0x16be1f('0x202f'):_0x5e48ef[_0x16be1f('0xf69')]=!![],_0x5e48ef[_0x16be1f('0x202f')]=!![];break;default:_0x7259a4[_0x16be1f('0x1715')](_0x5e48ef['selectedDisposition']?_0x5e48ef[_0x16be1f('0x1ede')][_0x16be1f('0x60a')]['toUpperCase']():'');}else _0x7259a4[_0x16be1f('0x1715')](_0x5e48ef['selectedDisposition']?_0x5e48ef['selectedDisposition']['name']['toUpperCase']():'');}function _0x23799(){const _0x18b42f=_0xdb5b9b;_0x7259a4[_0x18b42f('0x19fb')]();}function _0x43a2a5(){const _0x3c38f9=_0xdb5b9b;return _0x5e48ef['disable']=!![],_0x50f2b7[_0x3c38f9('0x26cf')][_0x3c38f9('0xb0a')]({'phone':_0x5e48ef[_0x3c38f9('0xd06')]['phone'],'UserId':_0x5e48ef[_0x3c38f9('0x202f')]?_0x19e5b3[_0x3c38f9('0x20b2')]()['id']:null,'ContactId':_0x5e48ef['contact']['id'],'ListId':_0x5e48ef[_0x3c38f9('0xd06')][_0x3c38f9('0x1e4f')],'VoiceQueueId':_0x5e48ef['dialerCall']?Number(_0x5e48ef[_0x3c38f9('0x164f')][_0x3c38f9('0x20fa')]):_0x5e48ef[_0x3c38f9('0x1bd9')]?_0x5e48ef[_0x3c38f9('0x1bd9')]['id']:null,'scheduledat':_0x1aaf93()(_0x5e48ef[_0x3c38f9('0x1da2')][_0x3c38f9('0x27c4')])['format'](_0x3c38f9('0x865')),'priority':0x3,'recallme':_0x5e48ef[_0x3c38f9('0x202f')],'OwnerId':_0x19e5b3[_0x3c38f9('0x20b2')]()['id']})[_0x3c38f9('0xe53')][_0x3c38f9('0x683')](function(){const _0x454d01=_0x3c38f9;_0x5e48ef[_0x454d01('0x1f87')]&&_0x50f2b7['cmHopperFinal'][_0x454d01('0x2480')]({'id':_0x5e48ef[_0x454d01('0x164f')]['uniqueid'],'rescheduled':!![],'rescheduledat':_0x1aaf93()(_0x5e48ef['hopper'][_0x454d01('0x27c4')])[_0x454d01('0x26dd')](_0x454d01('0x865')),'recallme':_0x5e48ef[_0x454d01('0x202f')]})[_0x454d01('0xe53')][_0x454d01('0x130a')](function(_0x510fc7){const _0x329136=_0x454d01;console[_0x329136('0x1b2b')](_0x510fc7);});})[_0x3c38f9('0x683')](function(){const _0x1f7f69=_0x3c38f9;_0xc07622[_0x1f7f69('0x53')]({'title':_0x13514e[_0x1f7f69('0x2728')](_0x1f7f69('0x1df0')),'msg':_0x13514e[_0x1f7f69('0x2728')](_0x1f7f69('0x2ee'))+'\x20'+(_0x5e48ef['recallme']?_0x13514e['instant'](_0x1f7f69('0x71e')):_0x13514e[_0x1f7f69('0x2728')](_0x1f7f69('0x27ba')))});})[_0x3c38f9('0x130a')](function(){const _0x24458d=_0x3c38f9;_0x7259a4[_0x24458d('0x1715')](_0x5e48ef[_0x24458d('0x1ede')]?_0x5e48ef[_0x24458d('0x1ede')][_0x24458d('0x60a')][_0x24458d('0x80')]():'');})['finally'](function(){const _0x66589f=_0x3c38f9;_0x5e48ef[_0x66589f('0x287')]=![],_0x7259a4[_0x66589f('0x1715')](_0x5e48ef['selectedDisposition']?_0x5e48ef[_0x66589f('0x1ede')][_0x66589f('0x60a')]['toUpperCase']():'');});}}const _0x1c887c=_0x3112ab;_0x4d26b6[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x2f9'),'toasty',_0x189033('0x56b'),'contact','call',_0x189033('0xba1'),_0x189033('0x202f'),_0x189033('0x1d08')];function _0x4d26b6(_0x54f70f,_0x12045c,_0x128ee5,_0x5b3768,_0x4d4710,_0x4b1abf,_0x18c074,_0x5d07e2,_0x428bdc,_0x513d4f,_0x294e48,_0x482958){const _0x23a273=_0x189033,_0x3495b9=this;_0x3495b9[_0x23a273('0x164f')]=_0x428bdc,_0x3495b9['contact']=_0x5d07e2,_0x3495b9[_0x23a273('0x1da2')]={'minDate':new Date(),'dateTime':new Date()};function _0x1e09c4(){const _0x3b8662=_0x23a273;return _0x3495b9['disable']=!![],_0x18c074[_0x3b8662('0x26cf')][_0x3b8662('0xb0a')]({'phone':_0x3495b9[_0x3b8662('0xd06')][_0x3b8662('0xd31')],'UserId':_0x294e48?_0x513d4f[_0x3b8662('0x20b2')]()['id']:null,'ContactId':_0x3495b9[_0x3b8662('0xd06')]['id'],'ListId':_0x3495b9[_0x3b8662('0xd06')]['ListId'],'VoiceQueueId':Number(_0x3495b9['call'][_0x3b8662('0x20fa')]),'scheduledat':_0x1aaf93()(_0x3495b9[_0x3b8662('0x1da2')][_0x3b8662('0x27c4')])[_0x3b8662('0x26dd')](_0x3b8662('0x865')),'priority':0x3,'recallme':_0x294e48,'OwnerId':_0x513d4f[_0x3b8662('0x20b2')]()['id']})['$promise']['then'](function(){const _0x588030=_0x3b8662;_0x18c074['cmHopperFinal'][_0x588030('0x2480')]({'id':_0x3495b9[_0x588030('0x164f')][_0x588030('0x573')],'rescheduled':!![],'rescheduledat':_0x1aaf93()(_0x3495b9[_0x588030('0x1da2')][_0x588030('0x27c4')])[_0x588030('0x26dd')]('YYYY-MM-DD\x20HH:mm:ss'),'recallme':_0x294e48})['$promise'];})[_0x3b8662('0x683')](function(){const _0x20ab2c=_0x3b8662;_0x4b1abf[_0x20ab2c('0x53')]({'title':_0x482958['instant'](_0x20ab2c('0x1df0')),'msg':_0x482958['instant'](_0x20ab2c('0x2ee'))+'\x20'+(_0x294e48?_0x482958[_0x20ab2c('0x2728')]('DASHBOARDS.RECALLME'):_0x482958['instant'](_0x20ab2c('0x27ba')))}),_0x5b3768['hide']();})[_0x3b8662('0x130a')](function(_0x4437e7){const _0x542294=_0x3b8662;_0x5b3768[_0x542294('0x19fb')](_0x4437e7);})[_0x3b8662('0x2874')](function(){const _0x57fbfe=_0x3b8662;_0x3495b9[_0x57fbfe('0x287')]=![];});}function _0x32c08b(){_0x5b3768['cancel']();}_0x3495b9['closeDialog']=_0x32c08b,_0x3495b9[_0x23a273('0xbd4')]=_0x1e09c4;}const _0x451a85=_0x4d26b6;_0x352b1a[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x1d08'),_0x189033('0x56b'),'contacts','callNumber',_0x189033('0x1d70')];function _0x352b1a(_0x2ebc58,_0x3555fd,_0x128c66,_0x39d385,_0x3631be,_0x44bd38){const _0x129ca4=_0x189033,_0x382b0c=this;_0x382b0c[_0x129ca4('0x186')]=_0x3631be,_0x382b0c[_0x129ca4('0xdf8')]=0x1;function _0x788ec1(){const _0x38bfae=_0x129ca4;_0x128c66['cmList']['get']({'fields':_0x38bfae('0xa10'),'nolimit':!![]})['$promise'][_0x38bfae('0x683')](function(_0x33adf5){const _0x2b5ce4=_0x38bfae;_0x382b0c[_0x2b5ce4('0xe01')]=_0x2e3ca0()[_0x2b5ce4('0x7cf')](_0x33adf5['rows'])[_0x2b5ce4('0x24db')]('id')[_0x2b5ce4('0x1cc9')]('name')[_0x2b5ce4('0x1c6b')](),_0x128c66[_0x2b5ce4('0xf57')][_0x2b5ce4('0x1e6e')]({'fields':_0x2b5ce4('0x199'),'nolimit':!![]})['$promise'][_0x2b5ce4('0x683')](function(_0x42fdc8){const _0x15a151=_0x2b5ce4;_0x382b0c[_0x15a151('0xc4d')]=_0x42fdc8[_0x15a151('0xf5d')],_0x382b0c[_0x15a151('0x6d5')]=_0x2e3ca0()[_0x15a151('0x386')](_0x39d385,function(_0x27758f){const _0x3a8810=_0x15a151;return Object[_0x3a8810('0x55e')](_0x27758f)['forEach'](function(_0x5d69ba){const _0xa02f7=_0x3a8810;if(Number(_0x27758f[_0x5d69ba])===Number(_0x382b0c['callNumber'])){if(_0x5d69ba[_0xa02f7('0x18ad')](_0xa02f7('0x1469'))){const _0x3103f9=_0x2e3ca0()[_0xa02f7('0x1c07')](_0x382b0c['customFields'],['id',Number(_0x2e3ca0()[_0xa02f7('0x1fe0')](_0x5d69ba,_0xa02f7('0x1469')))]);_0x27758f[_0xa02f7('0xf89')]=_0x3103f9?_0x3103f9[_0xa02f7('0x64a')]:_0x3555fd[_0xa02f7('0x2728')](_0xa02f7('0x215e'));}else _0x27758f['matchingField']=_0x5d69ba;}}),_0x27758f;});});})[_0x38bfae('0x683')](function(){const _0x92a656=_0x38bfae;_0x382b0c[_0x92a656('0x1351')]=_0x2e3ca0()[_0x92a656('0x26b6')](_0x39d385,0x4);})[_0x38bfae('0x130a')](function(_0x49a4d8){const _0x4222b9=_0x38bfae;_0x44bd38[_0x4222b9('0x52a')]({'title':_0x49a4d8['status']?_0x4222b9('0x2168')+_0x49a4d8[_0x4222b9('0x13ee')]+_0x4222b9('0xbf6')+_0x49a4d8[_0x4222b9('0x24a9')]:'api.cmList.get','msg':_0x49a4d8[_0x4222b9('0x5a5')]?JSON['stringify'](_0x49a4d8['data']['message']):_0x49a4d8[_0x4222b9('0x1ff0')]()});});}function _0x16dd6c(){const _0x3e2082=_0x129ca4;_0x2ebc58[_0x3e2082('0x1715')](_0x382b0c[_0x3e2082('0x3f2')]);}_0x382b0c[_0x129ca4('0x1dd2')]=_0x788ec1,_0x382b0c[_0x129ca4('0x2244')]=_0x16dd6c;}const _0x2124a0=_0x352b1a;_0x142749[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1b27')];function _0x142749(_0x4c2608,_0x2b69e1){const _0x1c6776=_0x189033;let _0x21bfc1=_0x2b69e1(function(){},0x3e7);_0x4c2608[_0x1c6776('0x26a2')](_0x1c6776('0x4b8'),function(){const _0x4aced5=_0x1c6776;_0x21bfc1&&(_0x2b69e1[_0x4aced5('0x19fb')](_0x21bfc1),_0x21bfc1=null);});}const _0x1ab2ff=_0x142749;_0x154a44[_0x189033('0x14be')]=['$scope',_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),'$window',_0x189033('0x1d08'),_0x189033('0x56b'),_0x189033('0xba1'),'socket'];function _0x154a44(_0xf4859c,_0x2e43f9,_0x5858fb,_0x550376,_0x4b0cb8,_0x1111eb,_0x37161b,_0x185e7b,_0x21ab2f){const _0x214295=_0x189033,_0x3d2ed1=this;_0x3d2ed1[_0x214295('0x12c2')]=![],_0x3d2ed1[_0x214295('0x7b2')]=!![],_0x3d2ed1[_0x214295('0x287')]=[],_0x3d2ed1[_0x214295('0x191e')]={'count':0x0,'rows':[]},_0x3d2ed1['currentUser']=_0x185e7b['getCurrentUser'](),_0x3d2ed1[_0x214295('0x2da')]={},_0x3d2ed1[_0x214295('0x37b')]={'count':0x0,'rows':[]},_0x3d2ed1[_0x214295('0x23a2')]={'fields':'id,type,calleridnum,calleridname,queue,queuecallerabandonAt,queuecallerexitAt,queuecallerexitreason,assigned,lastAssignedTo,updatedAt,disposition,secondDisposition,thirdDisposition','type':_0x214295('0x17cd'),'queuecallerexitreason':_0x214295('0x498')+','+'ABANDONED','sort':'-updatedAt','limit':0xa,'page':0x1},_0x3d2ed1[_0x214295('0x25bd')]=_0x19c6db,_0x3d2ed1[_0x214295('0x1897')]=_0x45e22e,_0x3d2ed1[_0x214295('0x1dd2')]=_0xd50aae,_0x3d2ed1[_0x214295('0x137b')]=_0xc003c8,_0x3d2ed1[_0x214295('0x1160')]=_0x484920,_0x3d2ed1[_0x214295('0x164f')]=_0xf4859c[_0x214295('0x1cd5')][_0x214295('0x1cd5')]['$parent'][_0x214295('0x1cd5')]['vm'][_0x214295('0x164f')],_0x3d2ed1[_0x214295('0x1011')]=_0xf4859c[_0x214295('0x1cd5')][_0x214295('0x1cd5')]['$parent'][_0x214295('0x1cd5')]['vm'][_0x214295('0x1011')],_0x3d2ed1[_0x214295('0x84a')]=_0xf4859c[_0x214295('0x1cd5')][_0x214295('0x1cd5')][_0x214295('0x1cd5')][_0x214295('0x1cd5')]['vm'][_0x214295('0x84a')],_0x3d2ed1['webtransfer']=_0xf4859c['$parent'][_0x214295('0x1cd5')][_0x214295('0x1cd5')][_0x214295('0x1cd5')]['vm'][_0x214295('0x131b')],_0x3d2ed1[_0x214295('0xb65')]=_0x285075,_0x3d2ed1[_0x214295('0x229d')]=_0x51ef26,_0x21ab2f[_0x214295('0x5a3')](_0x214295('0x187'),_0x531481),_0x21ab2f[_0x214295('0x5a3')](_0x214295('0x2660'),_0xa2ca1c),_0xd50aae();function _0xd50aae(){const _0x215d1f=_0x214295;return _0x37161b[_0x215d1f('0x43f')]['get']({'MailAccountId':'null','FaxAccountId':_0x215d1f('0x13c'),'SmsAccountId':_0x215d1f('0x13c'),'WhatsappAccountId':_0x215d1f('0x13c'),'OpenchannelAccountId':_0x215d1f('0x13c'),'ChatWebsiteId':_0x215d1f('0x13c')})[_0x215d1f('0xe53')][_0x215d1f('0x683')](function(_0x59dce2){const _0x46c1e3=_0x215d1f;return _0x3d2ed1[_0x46c1e3('0x191e')]=_0x59dce2?_0x59dce2[_0x46c1e3('0xf5d')]:[],_0x37161b[_0x46c1e3('0xc96')][_0x46c1e3('0x4c9')]({'id':_0x185e7b[_0x46c1e3('0x20b2')]()['id'],'fields':_0x46c1e3('0xa10'),'channel':_0x46c1e3('0xcf2'),'type':'outbound','nolimit':!![]})[_0x46c1e3('0xe53')];})[_0x215d1f('0x683')](function(_0x1e9ec9){const _0x580d4a=_0x215d1f;_0x3d2ed1[_0x580d4a('0x2da')]=_0x1e9ec9||{'count':0x0,'rows':[]},_0x3d2ed1[_0x580d4a('0xc9a')]=_0x2e3ca0()[_0x580d4a('0x1cc9')](_0x2e3ca0()['keyBy'](_0x3d2ed1[_0x580d4a('0x2da')][_0x580d4a('0xf5d')],_0x580d4a('0x60a')),'name'),_0x3d2ed1[_0x580d4a('0x275a')]=_0x3d2ed1[_0x580d4a('0x2da')]['rows']?_0x2e3ca0()[_0x580d4a('0x386')](_0x3d2ed1[_0x580d4a('0x2da')][_0x580d4a('0xf5d')],_0x580d4a('0x60a'))[_0x580d4a('0x1630')](','):undefined;})['then'](function(){const _0xd5ab8b=_0x215d1f;_0x3d2ed1[_0xd5ab8b('0xc71')]=_0x11132a();})['catch'](function(_0xed2e0b){const _0x58b2cc=_0x215d1f;console[_0x58b2cc('0x1b2b')](_0xed2e0b);})['finally'](function(){const _0x4c6c63=_0x215d1f;let _0x9a56b5=_0x4b0cb8[_0x4c6c63('0x120e')][_0x4c6c63('0x1b28')]('motion2.home.abandoned.bull.calls:'+_0x3d2ed1[_0x4c6c63('0x11ed')]['id']);if(_0x9a56b5)_0x9a56b5=JSON[_0x4c6c63('0x1f34')](_0x9a56b5),_0x9a56b5['query']&&(_0x3d2ed1['query']=_0x2e3ca0()[_0x4c6c63('0xf22')](_0x9a56b5[_0x4c6c63('0x23a2')],_0x2e3ca0()[_0x4c6c63('0x8b5')](_0x3d2ed1[_0x4c6c63('0x23a2')],[_0x4c6c63('0x671'),_0x4c6c63('0x6f0'),_0x4c6c63('0xdf8')])),_0x3d2ed1['query']=_0x2e3ca0()['omit'](_0x3d2ed1[_0x4c6c63('0x23a2')],_0x4c6c63('0x25')));else{const _0x27848d={'$gte':_0x1aaf93()()[_0x4c6c63('0x1627')](_0x4c6c63('0x55b'))['utcOffset'](0x0,!![])[_0x4c6c63('0x26dd')](),'$lte':_0x1aaf93()()[_0x4c6c63('0x3b3')]('month')[_0x4c6c63('0xb11')](0x0,!![])[_0x4c6c63('0x26dd')]()};_0x3d2ed1[_0x4c6c63('0x23a2')][_0x4c6c63('0x1a4')]=_0x27848d;}_0x3d2ed1[_0x4c6c63('0x1b8f')]=_0x3d2ed1[_0x4c6c63('0x23a2')][_0x4c6c63('0x25')]?!![]:![],_0x3d2ed1[_0x4c6c63('0x25bd')]();});}function _0x11132a(){const _0x4e1f4f=_0x214295;return[{'name':_0x4e1f4f('0x10c1'),'key':_0x4e1f4f('0x1a4'),'type':_0x4e1f4f('0x270e'),'label':_0x4e1f4f('0x1006')},{'name':'Agent','key':'UserId','type':'select','label':_0x4e1f4f('0x21fb'),'customOptions':[{'value':_0x3d2ed1[_0x4e1f4f('0x11ed')]['id'],'translate':'DASHBOARDS.ME'},{'value':_0x4e1f4f('0x5eb'),'translate':'DASHBOARDS.NOT_ASSIGNED'},{'value':undefined,'translate':_0x4e1f4f('0x475')}]},{'name':_0x4e1f4f('0x257b'),'key':_0x4e1f4f('0x660'),'type':_0x4e1f4f('0xf6c'),'label':_0x4e1f4f('0x1fd6'),'options':_0x3d2ed1['queues'][_0x4e1f4f('0xf5d')],'ngValue':'name','clearAll':![]}];}function _0x19c6db(){const _0x10c294=_0x214295;_0x3d2ed1[_0x10c294('0x23a2')]['queue']=_0x3d2ed1[_0x10c294('0x23a2')][_0x10c294('0x660')]||_0x3d2ed1[_0x10c294('0x275a')][_0x10c294('0x1fc5')](','),_0x3d2ed1[_0x10c294('0x23a2')]['offset']=(_0x3d2ed1[_0x10c294('0x23a2')][_0x10c294('0xdf8')]-0x1)*_0x3d2ed1['query'][_0x10c294('0x6f0')];const _0x55e89b={'query':_0x3d2ed1[_0x10c294('0x23a2')]};_0x4b0cb8[_0x10c294('0x120e')][_0x10c294('0x15d')]('motion2.home.abandoned.bull.calls:'+_0x3d2ed1[_0x10c294('0x11ed')]['id'],JSON[_0x10c294('0x258a')](_0x55e89b)),_0x3d2ed1[_0x10c294('0x1883')]=_0x37161b['voiceQueueReport'][_0x10c294('0x267a')](_0x3d2ed1[_0x10c294('0x23a2')],_0x4405dd)[_0x10c294('0xe53')];}function _0x4405dd(_0x2cc934){const _0x3a369a=_0x214295;_0x3d2ed1[_0x3a369a('0x37b')]=_0x2cc934||{'count':0x0,'rows':[]},_0x3d2ed1[_0x3a369a('0x7b2')]=!![];}function _0x484920(_0x5c303b){const _0x8c4936=_0x214295;_0x5858fb[_0x8c4936('0x1d4')]({'controller':_0x8c4936('0x233c'),'controllerAs':'vm','templateUrl':_0x8c4936('0x9dc'),'parent':angular[_0x8c4936('0x1fcc')](_0x550376[_0x8c4936('0x18e5')]),'targetEvent':_0x5c303b,'resolve':{'globalDispositions':[_0x8c4936('0x4b1'),function(_0x33fdda){const _0x276111=_0x8c4936;return _0x33fdda[_0x276111('0xed7')](_0x276111('0xfaa'),{'MailAccountId':'null','FaxAccountId':_0x276111('0x13c'),'SmsAccountId':_0x276111('0x13c'),'WhatsappAccountId':_0x276111('0x13c'),'OpenchannelAccountId':_0x276111('0x13c'),'ChatWebsiteId':_0x276111('0x13c'),'ListId':_0x276111('0x13c')});}]},'locals':{'dispositions':_0x3d2ed1[_0x8c4936('0x191e')],'call':_0x5c303b}})[_0x8c4936('0x683')](function(_0x542f9b){const _0x221426=_0x8c4936;if(_0x542f9b){_0x3d2ed1[_0x221426('0x287')][_0x5c303b['id']]=!![];const _0x5c2e42={'id':_0x5c303b['id'],'lastAssignedTo':_0x5c303b[_0x221426('0x1f2')]?_0x3d2ed1[_0x221426('0x11ed')][_0x221426('0x60a')]:null,'assigned':_0x5c303b[_0x221426('0x1f2')],'disposition':_0x542f9b['firstLevel']||null,'secondDisposition':_0x542f9b[_0x221426('0x53b')]||null,'thirdDisposition':_0x542f9b[_0x221426('0x176')]||null};_0x37161b[_0x221426('0x243')][_0x221426('0x2480')](_0x5c2e42)[_0x221426('0xe53')][_0x221426('0x130a')](function(_0x2f0943){const _0x3f2d87=_0x221426;console[_0x3f2d87('0x1b2b')](_0x2f0943);})['finally'](function(){_0x3d2ed1['disable'][_0x5c303b['id']]=![];});}});}function _0x285075(){const _0x42d672=_0x214295;_0x3d2ed1[_0x42d672('0x23a2')]['filter']=undefined,_0x3d2ed1['isSearchBarVisible']=![];}function _0x51ef26(){const _0x3d282e=_0x214295;_0x3d2ed1[_0x3d282e('0x1b8f')]=!![];}let _0x2ebffb=!![],_0x23d0e1=0x1;_0xf4859c['$watch'](_0x214295('0x1f20'),function(_0x357b31,_0x47bf0){const _0x5a1de9=_0x214295;_0x2ebffb?_0x2e43f9(function(){_0x2ebffb=![];}):(!_0x47bf0&&(_0x23d0e1=_0x3d2ed1[_0x5a1de9('0x23a2')]['page']),_0x357b31!==_0x47bf0&&(_0x3d2ed1[_0x5a1de9('0x23a2')][_0x5a1de9('0xdf8')]=0x1),!_0x357b31&&(_0x3d2ed1['query'][_0x5a1de9('0xdf8')]=_0x23d0e1),_0x3d2ed1[_0x5a1de9('0x25bd')]());});function _0x45e22e(){const _0x33ddf5=_0x214295;_0x3d2ed1['showTooltip']=![],_0x3d2ed1[_0x33ddf5('0x25bd')]();}function _0xc003c8(_0xd3d607){const _0x2933c6=_0x214295;_0xd3d607&&(_0x3d2ed1[_0x2933c6('0x287')][_0xd3d607['id']]=!![],_0x37161b[_0x2933c6('0x243')][_0x2933c6('0x2480')]({'id':_0xd3d607['id'],'lastAssignedTo':_0xd3d607['assigned']?_0x3d2ed1[_0x2933c6('0x11ed')]['name']:null,'assigned':_0xd3d607[_0x2933c6('0x1f2')]})[_0x2933c6('0xe53')][_0x2933c6('0x130a')](function(_0x57fe37){const _0x15669f=_0x2933c6;console[_0x15669f('0x1b2b')](_0x57fe37);})['finally'](function(){_0x3d2ed1['disable'][_0xd3d607['id']]=![];}));}function _0x531481(_0x1de692){const _0x2981f5=_0x214295;_0x3d2ed1[_0x2981f5('0xc9a')]&&_0x1de692[_0x2981f5('0xcf0')]===_0x2981f5('0x17cd')&&_0x3d2ed1['queuesMap'][_0x1de692[_0x2981f5('0x660')]]&&(_0x3d2ed1['showTooltip']=!![]);}function _0xa2ca1c(_0x8351f9){const _0x47b85e=_0x214295;if(_0x8351f9){const _0x128715=_0x2e3ca0()[_0x47b85e('0x1ce4')](_0x3d2ed1[_0x47b85e('0x37b')][_0x47b85e('0xf5d')],['id',_0x8351f9['id']]);_0x128715>=0x0&&_0x2e3ca0()[_0x47b85e('0xf22')](_0x3d2ed1['abandonedCalls'][_0x47b85e('0xf5d')][_0x128715],_0x8351f9);}}_0xf4859c[_0x214295('0x26a2')](_0x214295('0x4b8'),function(){const _0x1154d4=_0x214295;_0x21ab2f[_0x1154d4('0x1b9e')]('voiceQueueReport:save'),_0x21ab2f[_0x1154d4('0x1b9e')](_0x1154d4('0x2660'));});}const _0x514e21=_0x154a44;_0x124b1b[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x191e'),'globalDispositions',_0x189033('0x164f')];function _0x124b1b(_0x4ae923,_0x10aa98,_0x1f8558,_0x987332){const _0x201af7=_0x189033,_0x56c368=this;_0x56c368[_0x201af7('0x191e')]=_0x10aa98[_0x201af7('0xf5d')],_0x56c368[_0x201af7('0x12f6')]=_0x1f8558[_0x201af7('0xf5d')],_0x56c368['call']=_0x987332,_0x56c368[_0x201af7('0x2203')]=_0x56c368[_0x201af7('0x164f')][_0x201af7('0x2203')]||undefined,_0x56c368['onDispositionChange']=_0x2053a7,_0x56c368[_0x201af7('0x2224')]=_0x22da6b,_0x56c368[_0x201af7('0x15c6')]=_0x547a1c,_0x56c368[_0x201af7('0xf82')]=_0x2f65ad;function _0x2053a7(_0x5571a1){const _0x5a875e=_0x201af7,_0x26a64f=_0x2e3ca0()[_0x5a875e('0x41c')](_0x56c368['dispositions'],_0x56c368[_0x5a875e('0x12f6')],'id');switch(_0x5571a1){case'first':_0x56c368[_0x5a875e('0x1ede')]=_0x56c368['firstLevelDisposition'],_0x56c368[_0x5a875e('0x58')]=_0x2e3ca0()[_0x5a875e('0x7a2')](_0x26a64f,[_0x5a875e('0x1b62'),_0x56c368['firstLevelDisposition']['id']]),_0x56c368['secondLevelDisposition']=undefined,_0x56c368[_0x5a875e('0xde1')]=undefined,_0x56c368[_0x5a875e('0x4cf')]=![];break;case _0x5a875e('0x1f7b'):_0x56c368[_0x5a875e('0x1ede')]=_0x56c368['secondLevelDisposition'],_0x56c368[_0x5a875e('0x4cf')]=_0x2e3ca0()['some'](_0x26a64f,['ParentId',_0x56c368[_0x5a875e('0xc5d')]['id']]);break;case _0x5a875e('0x1d77'):_0x56c368[_0x5a875e('0x1ede')]=_0x56c368[_0x5a875e('0xde1')];break;}}function _0x22da6b(_0xebaf54){const _0x537036=_0x201af7;if(_0xebaf54==='second')_0x56c368[_0x537036('0xc5d')]=undefined,_0x56c368[_0x537036('0xde1')]=undefined,_0x56c368['selectedDisposition']=_0x56c368['firstLevelDisposition'];else _0xebaf54===_0x537036('0x1d77')&&(_0x56c368['thirdLevelDisposition']=undefined,_0x56c368[_0x537036('0x1ede')]=_0x56c368['secondLevelDisposition']);}function _0x547a1c(){const _0x91eca9=_0x201af7;_0x56c368[_0x91eca9('0x164f')][_0x91eca9('0x2203')]=_0x56c368['note'];const _0x59433d={'firstLevel':_0x56c368[_0x91eca9('0xb82')]?_0x56c368[_0x91eca9('0xb82')][_0x91eca9('0x60a')]:undefined,'secondLevel':_0x56c368['secondLevelDisposition']?_0x56c368[_0x91eca9('0xc5d')][_0x91eca9('0x60a')]:undefined,'thirdLevel':_0x56c368['thirdLevelDisposition']?_0x56c368[_0x91eca9('0xde1')][_0x91eca9('0x60a')]:undefined};_0x4ae923['hide'](_0x59433d);}function _0x2f65ad(){const _0x128644=_0x201af7;_0x4ae923[_0x128644('0x19fb')]();}}const _0x123094=_0x124b1b;_0x177042[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2063'),'$translate',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1556')];function _0x177042(_0x50fd83,_0x19bd40,_0x46adfd,_0x3fe4f4,_0x40a87a,_0xa669d5,_0x3fb21b,_0x46363f,_0x29a87d){const _0x12f5a8=_0x189033,_0x5b42ed=this;_0x5b42ed[_0x12f5a8('0x12c2')]=![],_0x5b42ed[_0x12f5a8('0x7b2')]=!![],_0x5b42ed['disable']=[],_0x5b42ed[_0x12f5a8('0x191e')]={'count':0x0,'rows':[]},_0x5b42ed[_0x12f5a8('0x11ed')]=_0x46363f[_0x12f5a8('0x20b2')](),_0x5b42ed['queues']={},_0x5b42ed[_0x12f5a8('0x37b')]={'count':0x0,'rows':[]},_0x5b42ed[_0x12f5a8('0x23a2')]={'fields':_0x12f5a8('0xa3c'),'type':_0x12f5a8('0x1535'),'queuecallerexitreason':_0x12f5a8('0x498')+','+_0x12f5a8('0x266d'),'sort':_0x12f5a8('0xc36'),'limit':0xa,'page':0x1},_0x5b42ed[_0x12f5a8('0x25bd')]=_0x5b9939,_0x5b42ed[_0x12f5a8('0x1897')]=_0x11bfa1,_0x5b42ed[_0x12f5a8('0x1dd2')]=_0x508e8a,_0x5b42ed['reserved']=_0xc7d225,_0x5b42ed[_0x12f5a8('0x1160')]=_0x14bc90,_0x5b42ed[_0x12f5a8('0x164f')]=_0x50fd83[_0x12f5a8('0x1cd5')]['$parent']['$parent'][_0x12f5a8('0x1cd5')]['vm'][_0x12f5a8('0x164f')],_0x5b42ed['transfer']=_0x50fd83['$parent'][_0x12f5a8('0x1cd5')][_0x12f5a8('0x1cd5')]['$parent']['vm'][_0x12f5a8('0x1011')],_0x5b42ed[_0x12f5a8('0x84a')]=_0x50fd83[_0x12f5a8('0x1cd5')][_0x12f5a8('0x1cd5')][_0x12f5a8('0x1cd5')][_0x12f5a8('0x1cd5')]['vm'][_0x12f5a8('0x84a')],_0x5b42ed[_0x12f5a8('0x131b')]=_0x50fd83[_0x12f5a8('0x1cd5')][_0x12f5a8('0x1cd5')]['$parent'][_0x12f5a8('0x1cd5')]['vm'][_0x12f5a8('0x131b')],_0x5b42ed[_0x12f5a8('0xb65')]=_0x268e13,_0x5b42ed[_0x12f5a8('0x229d')]=_0x66905a,_0x29a87d[_0x12f5a8('0x5a3')](_0x12f5a8('0x187'),_0x3496e2),_0x29a87d[_0x12f5a8('0x5a3')]('voiceQueueReport:update',_0x5cc993),_0x508e8a();function _0x508e8a(){const _0x5312d3=_0x12f5a8;return _0x3fb21b[_0x5312d3('0x43f')]['get']({'MailAccountId':_0x5312d3('0x13c'),'FaxAccountId':_0x5312d3('0x13c'),'SmsAccountId':_0x5312d3('0x13c'),'WhatsappAccountId':_0x5312d3('0x13c'),'OpenchannelAccountId':_0x5312d3('0x13c'),'ChatWebsiteId':_0x5312d3('0x13c')})['$promise']['then'](function(_0x5efffa){const _0x143d2d=_0x5312d3;return _0x5b42ed['dispositions']=_0x5efffa?_0x5efffa[_0x143d2d('0xf5d')]:[],_0x3fb21b[_0x143d2d('0xc96')][_0x143d2d('0x4c9')]({'id':_0x46363f[_0x143d2d('0x20b2')]()['id'],'fields':'id,name','channel':_0x143d2d('0xcf2'),'type':_0x143d2d('0x1535'),'nolimit':!![]})['$promise'];})[_0x5312d3('0x683')](function(_0x30990f){const _0x10a2a8=_0x5312d3;_0x5b42ed[_0x10a2a8('0x2da')]=_0x30990f||{'count':0x0,'rows':[]},_0x5b42ed[_0x10a2a8('0xc9a')]=_0x2e3ca0()['mapValues'](_0x2e3ca0()[_0x10a2a8('0x24db')](_0x5b42ed[_0x10a2a8('0x2da')][_0x10a2a8('0xf5d')],'name'),_0x10a2a8('0x60a')),_0x5b42ed[_0x10a2a8('0x275a')]=_0x5b42ed['queues'][_0x10a2a8('0xf5d')]?_0x2e3ca0()[_0x10a2a8('0x386')](_0x5b42ed[_0x10a2a8('0x2da')][_0x10a2a8('0xf5d')],'name')['join'](','):undefined;})['then'](function(){_0x5b42ed['quickFilters']=_0x983e68();})[_0x5312d3('0x130a')](function(_0x319161){const _0x5377d8=_0x5312d3;console[_0x5377d8('0x1b2b')](_0x319161);})[_0x5312d3('0x2874')](function(){const _0x3dd999=_0x5312d3;let _0x2253a3=_0x40a87a['localStorage']['getItem'](_0x3dd999('0x4ac')+_0x5b42ed[_0x3dd999('0x11ed')]['id']);if(_0x2253a3)_0x2253a3=JSON[_0x3dd999('0x1f34')](_0x2253a3),_0x2253a3[_0x3dd999('0x23a2')]&&(_0x5b42ed[_0x3dd999('0x23a2')]=_0x2e3ca0()[_0x3dd999('0xf22')](_0x2253a3['query'],_0x2e3ca0()[_0x3dd999('0x8b5')](_0x5b42ed[_0x3dd999('0x23a2')],['sort',_0x3dd999('0x6f0'),_0x3dd999('0xdf8')])),_0x5b42ed['query']=_0x2e3ca0()[_0x3dd999('0x8b5')](_0x5b42ed['query'],_0x3dd999('0x25')));else{const _0x563bdf={'$gte':_0x1aaf93()()[_0x3dd999('0x1627')](_0x3dd999('0x55b'))[_0x3dd999('0xb11')](0x0,!![])['format'](),'$lte':_0x1aaf93()()[_0x3dd999('0x3b3')](_0x3dd999('0x55b'))[_0x3dd999('0xb11')](0x0,!![])['format']()};_0x5b42ed[_0x3dd999('0x23a2')][_0x3dd999('0x1a4')]=_0x563bdf;}_0x5b42ed['isSearchBarVisible']=_0x5b42ed[_0x3dd999('0x23a2')]['filter']?!![]:![],_0x5b42ed['getAbandonedCalls']();});}function _0x983e68(){const _0x302c25=_0x12f5a8;return[{'name':_0x302c25('0x10c1'),'key':_0x302c25('0x1a4'),'type':_0x302c25('0x270e'),'label':_0x302c25('0x1006')},{'name':_0x302c25('0x62c'),'key':_0x302c25('0x10c5'),'type':'select','label':_0x302c25('0x21fb'),'customOptions':[{'value':_0x5b42ed['currentUser']['id'],'translate':'DASHBOARDS.ME'},{'value':_0x302c25('0x5eb'),'translate':_0x302c25('0x2608')},{'value':undefined,'translate':'DASHBOARDS.ALL'}]},{'name':_0x302c25('0x257b'),'key':_0x302c25('0x660'),'type':_0x302c25('0xf6c'),'label':_0x302c25('0x25ef'),'options':_0x5b42ed[_0x302c25('0x2da')][_0x302c25('0xf5d')],'ngValue':_0x302c25('0x60a'),'clearAll':![]}];}function _0x5b9939(){const _0x330e4d=_0x12f5a8;_0x5b42ed[_0x330e4d('0x23a2')]['queue']=_0x5b42ed[_0x330e4d('0x23a2')][_0x330e4d('0x660')]||_0x5b42ed[_0x330e4d('0x275a')][_0x330e4d('0x1fc5')](','),_0x5b42ed[_0x330e4d('0x23a2')]['offset']=(_0x5b42ed[_0x330e4d('0x23a2')][_0x330e4d('0xdf8')]-0x1)*_0x5b42ed[_0x330e4d('0x23a2')][_0x330e4d('0x6f0')];const _0x3e50d6={'query':_0x5b42ed[_0x330e4d('0x23a2')]};_0x40a87a[_0x330e4d('0x120e')][_0x330e4d('0x15d')](_0x330e4d('0x4ac')+_0x5b42ed[_0x330e4d('0x11ed')]['id'],JSON[_0x330e4d('0x258a')](_0x3e50d6)),_0x5b42ed[_0x330e4d('0x1883')]=_0x3fb21b['voiceQueueReport'][_0x330e4d('0x267a')](_0x5b42ed[_0x330e4d('0x23a2')],_0x349c00)[_0x330e4d('0xe53')];}function _0x349c00(_0x4f0a1e){const _0x2a090a=_0x12f5a8;_0x5b42ed[_0x2a090a('0x37b')]=_0x4f0a1e||{'count':0x0,'rows':[]},_0x5b42ed[_0x2a090a('0x7b2')]=!![];}function _0x14bc90(_0x58c570){const _0x46289b=_0x12f5a8;_0x46adfd['show']({'controller':_0x46289b('0x233c'),'controllerAs':'vm','templateUrl':_0x46289b('0x9dc'),'parent':angular[_0x46289b('0x1fcc')](_0x3fe4f4['body']),'targetEvent':_0x58c570,'resolve':{'globalDispositions':[_0x46289b('0x4b1'),function(_0x7a799d){const _0x26e78d=_0x46289b;return _0x7a799d[_0x26e78d('0xed7')](_0x26e78d('0xfaa'),{'MailAccountId':_0x26e78d('0x13c'),'FaxAccountId':_0x26e78d('0x13c'),'SmsAccountId':_0x26e78d('0x13c'),'WhatsappAccountId':_0x26e78d('0x13c'),'OpenchannelAccountId':'null','ChatWebsiteId':'null','ListId':_0x26e78d('0x13c')});}]},'locals':{'dispositions':_0x5b42ed[_0x46289b('0x191e')],'call':_0x58c570}})[_0x46289b('0x683')](function(_0x581659){const _0x1228a7=_0x46289b;if(_0x581659){_0x5b42ed[_0x1228a7('0x287')][_0x58c570['id']]=!![];const _0x3ba023={'id':_0x58c570['id'],'lastAssignedTo':_0x58c570[_0x1228a7('0x1f2')]?_0x5b42ed[_0x1228a7('0x11ed')][_0x1228a7('0x60a')]:null,'assigned':_0x58c570[_0x1228a7('0x1f2')],'disposition':_0x581659[_0x1228a7('0xdc8')]||null,'secondDisposition':_0x581659[_0x1228a7('0x53b')]||null,'thirdDisposition':_0x581659[_0x1228a7('0x176')]||null};_0x3fb21b[_0x1228a7('0x243')][_0x1228a7('0x2480')](_0x3ba023)[_0x1228a7('0xe53')][_0x1228a7('0x130a')](function(_0xe9e962){const _0xe07516=_0x1228a7;console[_0xe07516('0x1b2b')](_0xe9e962);})[_0x1228a7('0x2874')](function(){const _0x287c4e=_0x1228a7;_0x5b42ed[_0x287c4e('0x287')][_0x58c570['id']]=![];});}});}function _0x268e13(){const _0x2f2fa7=_0x12f5a8;_0x5b42ed[_0x2f2fa7('0x23a2')]['filter']=undefined,_0x5b42ed[_0x2f2fa7('0x1b8f')]=![];}function _0x66905a(){const _0x180355=_0x12f5a8;_0x5b42ed[_0x180355('0x1b8f')]=!![];}let _0x1836e3=!![],_0x312bfa=0x1;_0x50fd83['$watch'](_0x12f5a8('0x5d0'),function(_0x241049,_0x50616a){const _0x1ba460=_0x12f5a8;_0x1836e3?_0x19bd40(function(){_0x1836e3=![];}):(!_0x50616a&&(_0x312bfa=_0x5b42ed['query'][_0x1ba460('0xdf8')]),_0x241049!==_0x50616a&&(_0x5b42ed['query']['page']=0x1),!_0x241049&&(_0x5b42ed[_0x1ba460('0x23a2')]['page']=_0x312bfa),_0x5b42ed[_0x1ba460('0x25bd')]());});function _0x11bfa1(){const _0x58babe=_0x12f5a8;_0x5b42ed[_0x58babe('0x12c2')]=![],_0x5b42ed[_0x58babe('0x25bd')]();}function _0xc7d225(_0x36a3ca){const _0x21fb77=_0x12f5a8;_0x36a3ca&&(_0x5b42ed[_0x21fb77('0x287')][_0x36a3ca['id']]=!![],_0x3fb21b[_0x21fb77('0x243')][_0x21fb77('0x2480')]({'id':_0x36a3ca['id'],'lastAssignedTo':_0x36a3ca[_0x21fb77('0x1f2')]?_0x5b42ed[_0x21fb77('0x11ed')][_0x21fb77('0x60a')]:null,'assigned':_0x36a3ca[_0x21fb77('0x1f2')]})['$promise']['catch'](function(_0xd6c8fa){console['log'](_0xd6c8fa);})['finally'](function(){_0x5b42ed['disable'][_0x36a3ca['id']]=![];}));}function _0x3496e2(_0x17b28b){const _0x9b2be6=_0x12f5a8;_0x5b42ed[_0x9b2be6('0xc9a')]&&_0x17b28b['type']===_0x9b2be6('0x1535')&&_0x5b42ed['queuesMap'][_0x17b28b[_0x9b2be6('0x660')]]&&(_0x5b42ed[_0x9b2be6('0x12c2')]=!![]);}function _0x5cc993(_0x1a212e){const _0x13b6f0=_0x12f5a8;if(_0x1a212e){const _0x6dc934=_0x2e3ca0()[_0x13b6f0('0x1ce4')](_0x5b42ed[_0x13b6f0('0x37b')][_0x13b6f0('0xf5d')],['id',_0x1a212e['id']]);_0x6dc934>=0x0&&_0x2e3ca0()[_0x13b6f0('0xf22')](_0x5b42ed[_0x13b6f0('0x37b')][_0x13b6f0('0xf5d')][_0x6dc934],_0x1a212e);}}_0x50fd83[_0x12f5a8('0x26a2')]('$destroy',function(){const _0x50991d=_0x12f5a8;_0x29a87d[_0x50991d('0x1b9e')]('voiceQueueReport:save'),_0x29a87d[_0x50991d('0x1b9e')](_0x50991d('0x2660'));});}const _0x49e7f9=_0x177042;_0x10493e['$inject']=['$scope',_0x189033('0x2063'),_0x189033('0xba1'),'msNavigationAgentService',_0x189033('0x1777')];function _0x10493e(_0x1c63da,_0xbcc546,_0x4bbb15,_0x1a5789,_0x5b6eeb){const _0x54ecdc=_0x189033,_0x517e08=this;_0x517e08['user']=_0x4bbb15[_0x54ecdc('0x20b2')](),_0x517e08[_0x54ecdc('0xace')]={},_0x517e08[_0x54ecdc('0x1cd1')]={},_0x517e08['setting']={},_0x517e08[_0x54ecdc('0x12f')]=_0x54ecdc('0x1a6'),_0x517e08[_0x54ecdc('0x1777')]=_0x5b6eeb,_0x517e08[_0x54ecdc('0x21ad')]=_0x1a5789['getNavigation'](),_0x517e08[_0x54ecdc('0x15e')]=_0x1c63da['$parent']['vm']['addContactTab'],_0x517e08['addInteractionTab']=_0x1c63da['$parent']['vm'][_0x54ecdc('0x297')],_0x517e08[_0x54ecdc('0x12f3')]=_0x1e67f1,_0x517e08['changeSidebarTab']=_0x512ee9,_0x517e08[_0x54ecdc('0x5e3')]=_0x52abd0;function _0x1e67f1(_0x54c2d7,_0x71f29e){const _0x2f0b85=_0x54ecdc;_0x517e08[_0x2f0b85('0xace')]=_0x54c2d7,_0x517e08[_0x2f0b85('0x260a')]=_0x71f29e;let _0x56537f=_0xbcc546['localStorage'][_0x2f0b85('0x1b28')](_0x2f0b85('0x547')+_0x517e08[_0x2f0b85('0xc96')]['id']);if(_0x56537f){try{_0x56537f=JSON[_0x2f0b85('0x1f34')](_0x56537f),_0x517e08[_0x2f0b85('0x12f')]=_0x56537f[_0x2f0b85('0xc5')]?_0x56537f[_0x2f0b85('0xc5')]:'dashboard';}catch(_0x205145){console[_0x2f0b85('0x52a')](_0x205145),_0x517e08[_0x2f0b85('0x12f')]=_0x2f0b85('0x1a6');}_0x517e08[_0x2f0b85('0x12f')]===_0x2f0b85('0x129f')&&_0x517e08[_0x2f0b85('0x1777')][_0x2f0b85('0x12f3')]();}}function _0x52abd0(_0x3ac1d0){return _0x4bbb15['hasPermission'](_0x3ac1d0);}function _0x512ee9(_0x49b146){const _0x1af5fe=_0x54ecdc;_0x517e08[_0x1af5fe('0x12f')]=_0x49b146[_0x1af5fe('0x1a0f')],_0x517e08[_0x1af5fe('0x12f')]===_0x1af5fe('0x1cd1')&&(_0x517e08[_0x1af5fe('0x1cd1')]=_0x49b146[_0x1af5fe('0x230a')],_0x517e08[_0x1af5fe('0x1b98')]=_0x49b146['id'],_0x1c63da[_0x1af5fe('0x5ed')]('pluginUpdated',{'plugin':_0x517e08[_0x1af5fe('0x1cd1')]})),_0xbcc546[_0x1af5fe('0x120e')][_0x1af5fe('0x15d')](_0x1af5fe('0x547')+_0x517e08[_0x1af5fe('0xc96')]['id'],JSON['stringify']({'currentSidebarTab':_0x49b146['view']}));}_0x1c63da[_0x54ecdc('0x186d')](_0x54ecdc('0x1649'),function(_0x49859d){const _0x5b8a07=_0x54ecdc;_0x49859d===_0x5b8a07('0x129f')?_0x517e08[_0x5b8a07('0x1777')][_0x5b8a07('0x12f3')]():_0x517e08[_0x5b8a07('0x1777')]['drafts']={};});}const _0x4c42cd=_0x10493e,_0x3fe59f=_0x180212['p']+'src/js/modules/core/dialogs/advanced-search/dialog.html/dialog.html';_0x583efd[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2063'),_0x189033('0x1d08'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1556'),_0x189033('0x1d70')];function _0x583efd(_0x421f81,_0xb68b09,_0x4e5ed4,_0x3c3f23,_0x2381aa,_0x50687b,_0x15536f,_0x52e24d,_0x2a087c,_0x387be6){const _0x53c924=_0x189033,_0x5eff02=this;_0x5eff02[_0x53c924('0xc96')]=_0x52e24d[_0x53c924('0x20b2')](),_0x5eff02[_0x53c924('0xace')]={},_0x5eff02[_0x53c924('0x260a')]={},_0x5eff02['tags']={'count':0x0,'rows':[]},_0x5eff02[_0x53c924('0x1e8f')]={'count':0x0,'rows':[]},_0x5eff02[_0x53c924('0x23a2')]={'includeAll':!![],'sort':_0x53c924('0xc36'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x5eff02[_0x53c924('0x19c9')]={'fields':[{'name':'Id','column':'id','type':_0x53c924('0x121f')},{'name':_0x53c924('0x1309'),'column':_0x53c924('0x1309'),'type':_0x53c924('0xeb'),'options':{'searchFields':['firstName',_0x53c924('0x510'),_0x53c924('0x1c92')],'route':{'model':_0x53c924('0x276e'),'action':_0x53c924('0x1e6e'),'params':{'fields':'id,firstName,lastName,email','Contact':_0x53c924('0xfd'),'nolimit':!![]}},'extraOperators':['$substring'],'excludedOperators':[_0x53c924('0x17ee')]}},{'name':_0x53c924('0x1765'),'column':_0x53c924('0x18e5'),'type':_0x53c924('0x1bcd'),'options':{'excludedOperators':[_0x53c924('0x393'),'$ne']}},{'name':'Status','column':_0x53c924('0xd8a'),'type':_0x53c924('0xb31'),'values':[{'id':0x0,'translate':_0x53c924('0x10b1')},{'id':0x1,'translate':_0x53c924('0x270a')}],'options':{'excludedOperators':['$ne']}},{'name':_0x53c924('0x2378'),'column':'customerIp','type':'text','options':{'excludedOperators':['$eq',_0x53c924('0x17ee'),_0x53c924('0xd0'),_0x53c924('0x5bc')]}},{'name':'Agent','column':_0x53c924('0x1dad'),'type':_0x53c924('0xeb'),'options':{'table':'i','route':{'model':_0x53c924('0xc96'),'action':_0x53c924('0x1e6e'),'params':{'role':'agent','fields':_0x53c924('0x2686'),'nolimit':!![]}},'searchFields':[_0x53c924('0x11bc'),_0x53c924('0x60a')],'extraOperators':[_0x53c924('0xe55')],'excludedOperators':[_0x53c924('0x17ee')]}},{'name':_0x53c924('0xe4c'),'column':_0x53c924('0x15a5'),'type':'multiselect','options':{'route':{'model':'user','action':_0x53c924('0x24ee'),'params':{'id':_0x5eff02[_0x53c924('0xc96')]['id'],'nolimit':!![]}}}},{'name':_0x53c924('0x198f'),'column':'Tag','type':_0x53c924('0xf6c'),'options':{'route':{'model':'tag','action':_0x53c924('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x53c924('0x1479')]}},{'name':'Start\x20Date','column':_0x53c924('0x1a4'),'type':_0x53c924('0x270e'),'options':{'excludedOperators':['$ne']}},{'name':_0x53c924('0x1bb6'),'column':_0x53c924('0x122e'),'type':_0x53c924('0xb31'),'values':[{'id':0x1,'translate':_0x53c924('0x38f')},{'id':0x0,'translate':_0x53c924('0x2226')}],'options':{'excludedOperators':[_0x53c924('0x17ee')]}}]},_0x5eff02[_0x53c924('0xd10')]=_0x53c924('0xb1e'),_0x5eff02['onInit']=_0xf7eb59,_0x5eff02['success']=_0x458f7b,_0x5eff02[_0x53c924('0x8d0')]=_0x24e607,_0x5eff02['showChatInteraction']=_0x4fb1ff,_0x5eff02[_0x53c924('0x1d65')]=_0x437c17,_0x5eff02['disposeInteraction']=_0x58e79a,_0x5eff02['getContactLabel']=_0x5942f5,_0x5eff02[_0x53c924('0x2084')]=_0x3fbfc2,_0x5eff02[_0x53c924('0xad8')]=_0x43d9ab,_0x5eff02[_0x53c924('0xb65')]=_0x578751,_0x5eff02[_0x53c924('0x229d')]=_0x323143,_0x5eff02[_0x53c924('0x2121')]=_0x1cab4a;function _0xf7eb59(_0x581e8a,_0x2aa093){const _0x56432c=_0x53c924;return _0x5eff02[_0x56432c('0xace')]=_0x581e8a,_0x5eff02[_0x56432c('0x260a')]=_0x2aa093,_0x15536f[_0x56432c('0xc96')][_0x56432c('0x1e6e')+_0x2e3ca0()[_0x56432c('0x2711')]('ChatWebsites')]({'id':_0x5eff02[_0x56432c('0xc96')]['id'],'nolimit':!![]})[_0x56432c('0xe53')]['then'](function(_0x456a28){const _0x5c3fb4=_0x56432c;return _0x5eff02[_0x5c3fb4('0x11e2')]=_0x456a28||{'count':0x0,'rows':[]},_0x15536f[_0x5c3fb4('0x270')]['get']()[_0x5c3fb4('0xe53')];})[_0x56432c('0x683')](function(_0x2b6f1d){_0x5eff02['tags']=_0x2b6f1d||{'count':0x0,'rows':[]};})[_0x56432c('0x683')](function(){const _0x1f9551=_0x56432c;_0x5eff02[_0x1f9551('0xc71')]=_0x207b94();})['catch'](function(_0x3f4e64){const _0x5e4e3c=_0x56432c;console[_0x5e4e3c('0x52a')](_0x3f4e64);})[_0x56432c('0x2874')](function(){const _0x2f5c64=_0x56432c;let _0x4003cc=_0x2381aa[_0x2f5c64('0x120e')][_0x2f5c64('0x1b28')](_0x2f5c64('0x88a')+_0x5eff02[_0x2f5c64('0xc96')]['id']);if(_0x4003cc)try{_0x4003cc=JSON[_0x2f5c64('0x1f34')](_0x4003cc);if(_0x4003cc[_0x2f5c64('0x23a2')]){_0x5eff02[_0x2f5c64('0x23a2')]=_0x2e3ca0()[_0x2f5c64('0xf22')](_0x5eff02[_0x2f5c64('0x23a2')],_0x4003cc[_0x2f5c64('0x23a2')]);if(_0x2e3ca0()[_0x2f5c64('0x173f')](_0x5eff02[_0x2f5c64('0x11e2')][_0x2f5c64('0xf5d')]))_0x5eff02['query']['ChatWebsiteId']=[];else _0x2e3ca0()[_0x2f5c64('0x173f')](_0x5eff02[_0x2f5c64('0x23a2')][_0x2f5c64('0x15a5')])&&(_0x5eff02[_0x2f5c64('0x23a2')][_0x2f5c64('0x15a5')]=_0x2e3ca0()(_0x5eff02['chatAccounts'][_0x2f5c64('0xf5d')])[_0x2f5c64('0x386')]('id')[_0x2f5c64('0x22c8')]()[_0x2f5c64('0x1c6b')]());_0x5eff02[_0x2f5c64('0x23a2')][_0x2f5c64('0x671')]&&_0x5eff02[_0x2f5c64('0x23a2')][_0x2f5c64('0x671')][_0x2f5c64('0x824')](_0x2f5c64('0x88f'))>=0x0&&(_0x5eff02[_0x2f5c64('0x23a2')]=_0x2e3ca0()[_0x2f5c64('0x8b5')](_0x5eff02[_0x2f5c64('0x23a2')],_0x2f5c64('0x671'))),_0x5eff02[_0x2f5c64('0x23a2')][_0x2f5c64('0x2761')]=!![],_0x5eff02['isSearchBarVisible']=_0x5eff02[_0x2f5c64('0x23a2')][_0x2f5c64('0x25')]?!![]:![];}}catch(_0x3362bc){console[_0x2f5c64('0x52a')](_0x3362bc);}else{const _0xf7d135={'$gte':_0x1aaf93()()[_0x2f5c64('0x1627')]('month')['utcOffset'](0x0,!![])[_0x2f5c64('0x26dd')](),'$lte':_0x1aaf93()()[_0x2f5c64('0x3b3')]('month')[_0x2f5c64('0xb11')](0x0,!![])[_0x2f5c64('0x26dd')]()},_0x408ef6={'ChatWebsiteId':_0x2e3ca0()[_0x2f5c64('0x386')](_0x5eff02[_0x2f5c64('0x11e2')][_0x2f5c64('0xf5d')],'id'),'createdAt':_0xf7d135};_0x5eff02[_0x2f5c64('0x23a2')]=_0x2e3ca0()[_0x2f5c64('0xf22')](_0x5eff02['query'],_0x408ef6);}_0x2a087c['on'](_0x2f5c64('0x445'),_0x576cb2),_0x2a087c['on'](_0x2f5c64('0x1efd'),_0x576cb2),_0x2a087c['on'](_0x2f5c64('0x6f9'),_0x553e27),_0x2a087c['on'](_0x2f5c64('0x1f1d'),_0x451269),_0x2a087c['on'](_0x2f5c64('0x1121'),_0x451269),_0x2a087c['on']('user_has_chat_interactions:save',_0x38de9f),_0x2a087c['on'](_0x2f5c64('0xc34'),_0x1c8e85),_0x24e607(_0x5eff02[_0x2f5c64('0x23a2')][_0x2f5c64('0xdf8')]);});}function _0x207b94(){const _0x2a3df8=_0x53c924;return[{'name':_0x2a3df8('0x10c1'),'key':_0x2a3df8('0x1a4'),'type':_0x2a3df8('0x270e'),'label':_0x2a3df8('0x1006')},{'name':_0x2a3df8('0xc51'),'key':_0x2a3df8('0x20db'),'type':'select','label':_0x2a3df8('0x1866'),'customOptions':[{'value':0x0,'translate':_0x2a3df8('0x2226')},{'value':0x1,'translate':_0x2a3df8('0x38f')},{'value':null,'translate':_0x2a3df8('0x475')}]},{'name':_0x2a3df8('0x1d9d'),'key':'closed','type':'select','label':'DASHBOARDS.SELECT_STATUS','customOptions':[{'value':0x0,'translate':_0x2a3df8('0x10b1')},{'value':0x1,'translate':'DASHBOARDS.CLOSED'},{'value':null,'translate':'DASHBOARDS.ALL'}]},{'name':_0x2a3df8('0xe4c'),'key':_0x2a3df8('0x15a5'),'type':_0x2a3df8('0xf6c'),'label':_0x2a3df8('0x1202'),'options':_0x5eff02[_0x2a3df8('0x11e2')]['rows'],'clearAll':![]},{'name':_0x2a3df8('0x62c'),'key':'UserId','type':'select','label':_0x2a3df8('0x21fb'),'customOptions':[{'value':_0x5eff02[_0x2a3df8('0xc96')]['id'],'translate':_0x2a3df8('0x96a')},{'value':_0x2a3df8('0x13c'),'translate':_0x2a3df8('0x2608')},{'value':undefined,'translate':'DASHBOARDS.ALL'}]},{'name':_0x2a3df8('0x1e'),'key':_0x2a3df8('0x270'),'type':_0x2a3df8('0xf6c'),'label':_0x2a3df8('0x2264'),'options':_0x5eff02[_0x2a3df8('0x1ce6')][_0x2a3df8('0xf5d')],'placeholder':'DASHBOARDS.TAGS'}];}function _0x458f7b(_0x4854be){const _0x30889a=_0x53c924;_0x5eff02[_0x30889a('0xab2')]=![],_0x5eff02[_0x30889a('0x1e8f')]=_0x4854be||{'count':0x0,'rows':[]};for(let _0xc1a3b0=0x0;_0xc1a3b0<_0x5eff02[_0x30889a('0x1e8f')]['rows'][_0x30889a('0x1564')];_0xc1a3b0+=0x1){_0x5942f5(_0x5eff02[_0x30889a('0x1e8f')][_0x30889a('0xf5d')][_0xc1a3b0]);}}function _0x24e607(_0x85a01f){const _0x181eb4=_0x53c924;_0x5eff02[_0x181eb4('0xab2')]=!![];!_0x85a01f&&(_0x5eff02[_0x181eb4('0x23a2')]['page']=0x1);_0x5eff02[_0x181eb4('0x23a2')]['offset']=(_0x5eff02[_0x181eb4('0x23a2')][_0x181eb4('0xdf8')]-0x1)*_0x5eff02[_0x181eb4('0x23a2')][_0x181eb4('0x6f0')];let _0x1828b1=_0x2381aa[_0x181eb4('0x120e')][_0x181eb4('0x1b28')](_0x181eb4('0x88a')+_0x5eff02['user']['id']);_0x1828b1=_0x1828b1?JSON[_0x181eb4('0x1f34')](_0x1828b1):{},_0x1828b1[_0x181eb4('0x23a2')]=_0x5eff02[_0x181eb4('0x23a2')],_0x2381aa[_0x181eb4('0x120e')]['setItem'](_0x181eb4('0x88a')+_0x5eff02[_0x181eb4('0xc96')]['id'],JSON['stringify'](_0x1828b1)),_0x5eff02['promise']=_0x15536f['chatInteraction'][_0x181eb4('0x1e6e')](_0x5eff02[_0x181eb4('0x23a2')],_0x458f7b)[_0x181eb4('0xe53')];}function _0x4fb1ff(_0xb1b6dd,_0x9750d6){const _0x257de1=_0x53c924;_0x421f81[_0x257de1('0x1cd5')]['vm'][_0x257de1('0x297')](_0x257de1('0x24e'),_0x9750d6);}function _0x437c17(_0x2b35bc,_0x32e5a0,_0x3ee904){const _0x1efed9=_0x53c924;_0x15536f[_0x1efed9('0x1809')][_0x1efed9('0x18e8')]({'id':_0x32e5a0['id'],'attachments':_0x3ee904})['$promise']['then'](function(_0x3580ca){const _0x140e95=_0x1efed9,_0x9ec6a2=[_0x3580ca[_0x140e95('0x1fb3')]],_0x4a01f8=_0x140e95('0x599')+_0x32e5a0['id']+'.zip',_0x3403c9=new Blob(_0x9ec6a2,{'type':_0x3580ca[_0x140e95('0xcf0')]}),_0x5844b9=window[_0x140e95('0x12e1')][_0x140e95('0x1ffa')]('a');_0x5844b9['setAttribute'](_0x140e95('0x2767'),URL['createObjectURL'](_0x3403c9)),_0x5844b9['setAttribute'](_0x140e95('0x18e8'),_0x4a01f8),document['body'][_0x140e95('0x1e43')](_0x5844b9),_0x5844b9[_0x140e95('0x1d42')]();})[_0x1efed9('0x130a')](function(_0x4adf00){const _0x12f54b=_0x1efed9;if(_0x4adf00[_0x12f54b('0x5a5')]&&_0x4adf00[_0x12f54b('0x5a5')][_0x12f54b('0x17f')]&&_0x4adf00[_0x12f54b('0x5a5')][_0x12f54b('0x17f')][_0x12f54b('0x1564')])for(let _0x385416=0x0;_0x385416<_0x4adf00[_0x12f54b('0x5a5')][_0x12f54b('0x17f')]['length'];_0x385416+=0x1){_0x387be6[_0x12f54b('0x52a')]({'title':_0x4adf00[_0x12f54b('0x5a5')][_0x12f54b('0x17f')][_0x385416]['type'],'msg':_0x4adf00[_0x12f54b('0x5a5')]['errors'][_0x385416][_0x12f54b('0x8c2')]});}else _0x387be6['error']({'title':_0x4adf00[_0x12f54b('0x13ee')]?_0x12f54b('0x2168')+_0x4adf00[_0x12f54b('0x13ee')]+_0x12f54b('0xbf6')+_0x4adf00[_0x12f54b('0x24a9')]:_0x12f54b('0x1d65'),'msg':_0x4adf00[_0x12f54b('0x5a5')]?JSON[_0x12f54b('0x258a')](_0x4adf00[_0x12f54b('0x5a5')][_0x12f54b('0x8c2')]):_0x4adf00[_0x12f54b('0x1ff0')]()});});}function _0x58e79a(_0x9fc046,_0x2ac728){const _0x4ff0f6=_0x53c924,_0x58bf76=_0x5eff02[_0x4ff0f6('0xc96')]['voicePause']||_0x5eff02[_0x4ff0f6('0xc96')]['chatPause']||_0x5eff02['user']['mailPause']||_0x5eff02[_0x4ff0f6('0xc96')][_0x4ff0f6('0x1a11')]||_0x5eff02['user'][_0x4ff0f6('0x716')],_0x2fa5c0=!_0x2ac728[_0x4ff0f6('0xa78')]['mandatoryDisposition'];_0x4e5ed4[_0x4ff0f6('0x1d4')]({'controller':_0x4ff0f6('0x14a7'),'controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular[_0x4ff0f6('0x1fcc')](_0x3c3f23['body']),'clickOutsideToClose':_0x2fa5c0,'escapeToClose':_0x2fa5c0,'onRemoving':function(){const _0x247572=_0x4ff0f6;_0x5eff02[_0x247572('0xc96')]&&_0x2ac728['Account'][_0x247572('0x989')]&&!_0x58bf76&&_0x15536f[_0x247572('0xc96')]['unpause']({'id':_0x5eff02[_0x247572('0xc96')]['id']})['$promise'][_0x247572('0x130a')](function(_0x34de3d){const _0x4e6740=_0x247572;console[_0x4e6740('0x52a')](_0x34de3d);});},'locals':{'user':_0x5eff02[_0x4ff0f6('0xc96')],'channel':_0x4ff0f6('0x24e'),'interaction':_0x2ac728}});}function _0x5942f5(_0x3deab6){const _0xd43161=_0x53c924;_0x3deab6[_0xd43161('0x1309')]?_0x3deab6[_0xd43161('0x12b3')]=(_0x3deab6[_0xd43161('0x1309')][_0xd43161('0xeef')]||'')+'\x20'+(_0x3deab6[_0xd43161('0x1309')]['lastName']||''):_0x3deab6[_0xd43161('0x12b3')]=_0x50687b[_0xd43161('0x2728')](_0xd43161('0x215e'));}function _0x3fbfc2(_0x520424){const _0x584eae=_0x53c924;if(_0x520424[_0x584eae('0x10c5')])return _0x520424[_0x584eae('0x10c5')]===_0x5eff02[_0x584eae('0xc96')]['id']?_0x50687b[_0x584eae('0x2728')](_0x584eae('0x96a')):_0x520424[_0x584eae('0x2464')][_0x584eae('0x11bc')]+'\x20<'+_0x520424[_0x584eae('0x2464')][_0x584eae('0x1d43')]+'>';return _0x50687b[_0x584eae('0x2728')](_0x584eae('0x2608'));}function _0x43d9ab(_0xaba32b){const _0x3fbafe=_0x53c924;if(_0xaba32b[_0x3fbafe('0xa78')])return _0xaba32b['Account'][_0x3fbafe('0x1d46')];return _0x50687b[_0x3fbafe('0x2728')](_0x3fbafe('0x215e'));}function _0x38de9f(_0x5daa78){const _0x10f8b2=_0x53c924;let _0xf4cacb;const _0x319b53=_0x2e3ca0()[_0x10f8b2('0x1c07')](_0x5eff02[_0x10f8b2('0x1e8f')][_0x10f8b2('0xf5d')],{'id':_0x5daa78[_0x10f8b2('0x2806')]});_0x319b53&&_0x319b53[_0x10f8b2('0x2139')]&&(_0xf4cacb=_0x2e3ca0()[_0x10f8b2('0x1c07')](_0x319b53['Users'],{'id':_0x5daa78[_0x10f8b2('0x10c5')]}),!_0xf4cacb&&_0x319b53['Users'][_0x10f8b2('0x1fd0')]({'id':_0x5daa78[_0x10f8b2('0x10c5')]}));}function _0x1c8e85(_0x5d0bea){const _0x16a8f0=_0x53c924,_0x5795c4=_0x2e3ca0()[_0x16a8f0('0x1c07')](_0x5eff02[_0x16a8f0('0x1e8f')]['rows'],{'id':_0x5d0bea[_0x16a8f0('0x2806')]});_0x5795c4&&_0x5795c4[_0x16a8f0('0x2139')]&&_0x2e3ca0()['remove'](_0x5795c4['Users'],{'id':_0x5d0bea[_0x16a8f0('0x10c5')]});}function _0x576cb2(_0x366946){const _0x3e3957=_0x53c924;if(_0x366946){const _0x36b5bb=_0x2e3ca0()[_0x3e3957('0x1c07')](_0x5eff02[_0x3e3957('0x1e8f')]['rows'],{'id':_0x366946['id']});if(_0x36b5bb){_0x36b5bb[_0x3e3957('0x2139')]=[];_0x366946[_0x3e3957('0xd8a')]&&(_0x36b5bb[_0x3e3957('0x122e')]=0x0);if(_0x5eff02[_0x3e3957('0x23a2')][_0x3e3957('0x671')]){const _0x1b4856=_0x2e3ca0()['startsWith'](_0x5eff02[_0x3e3957('0x23a2')][_0x3e3957('0x671')],'-')?_0x3e3957('0x1f5a'):'asc';_0x5eff02[_0x3e3957('0x1e8f')][_0x3e3957('0xf5d')]=_0x2e3ca0()['orderBy'](_0x5eff02['chatInteractions']['rows'],_0x2e3ca0()[_0x3e3957('0x1fe0')](_0x5eff02[_0x3e3957('0x23a2')][_0x3e3957('0x671')],'-'),_0x1b4856);}_0x2e3ca0()['merge'](_0x36b5bb,_0x2e3ca0()['pick'](_0x366946,_0x2e3ca0()[_0x3e3957('0x55e')](_0x36b5bb)));}else _0x24e607(_0x5eff02[_0x3e3957('0x23a2')][_0x3e3957('0xdf8')]);}}function _0x553e27(_0x2664ef){const _0x32dfe9=_0x53c924;if(_0x2664ef){const _0x27690e=_0x2e3ca0()[_0x32dfe9('0x1c07')](_0x5eff02['chatInteractions'][_0x32dfe9('0xf5d')],{'id':_0x2664ef['id']});_0x27690e&&(_0x27690e[_0x32dfe9('0x198f')]=_0x2664ef['tags']||[],_0x2e3ca0()[_0x32dfe9('0xf22')](_0x27690e,_0x2e3ca0()[_0x32dfe9('0x24d0')](_0x2664ef,_0x2e3ca0()[_0x32dfe9('0x55e')](_0x27690e))));}}function _0x451269(_0x2fe8d5){const _0x126a06=_0x53c924;if(_0x2fe8d5&&!_0x2fe8d5[_0x126a06('0x252d')]){const _0x136058=_0x2e3ca0()[_0x126a06('0x1c07')](_0x5eff02['chatInteractions']['rows'],{'id':_0x2fe8d5[_0x126a06('0x2806')]});if(_0x136058){const _0x58d95a=_0x2e3ca0()[_0x126a06('0x1c07')](_0x136058[_0x126a06('0xc51')],{'id':_0x2fe8d5['id']});_0x58d95a?_0x2e3ca0()['merge'](_0x58d95a,_0x2e3ca0()[_0x126a06('0x24d0')](_0x2fe8d5,_0x2e3ca0()[_0x126a06('0x55e')](_0x58d95a))):(_0x2e3ca0()[_0x126a06('0x8f2')](_0x136058[_0x126a06('0xc51')])&&(_0x136058[_0x126a06('0xc51')]={'count':0x0}),!_0x2fe8d5['read']&&(_0x136058[_0x126a06('0xc51')][_0x126a06('0x50d')]+=0x1));}}}function _0x578751(){_0x5eff02['isSearchBarVisible']=![];}function _0x323143(){const _0x3e5ea2=_0x53c924;_0x5eff02[_0x3e5ea2('0x1b8f')]=!![];}function _0x1cab4a(){const _0x456277=_0x53c924;_0x5eff02[_0x456277('0x1b8f')]=![],_0x4e5ed4[_0x456277('0x1d4')]({'controller':_0x456277('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x456277('0x1fcc')](_0x3c3f23[_0x456277('0x18e5')]),'clickOutsideToClose':![],'locals':{'color':_0x5eff02[_0x456277('0xd10')],'fields':_0x5eff02[_0x456277('0x19c9')]['fields'],'storagePath':'home.chat'},'fullscreen':!![]})[_0x456277('0x683')](function(_0x508be9){const _0x11ed53=_0x456277;_0x5eff02[_0x11ed53('0x23a2')][_0x11ed53('0x19a4')]=_0x508be9===![]?undefined:_0x508be9;if(_0x5eff02[_0x11ed53('0x23a2')][_0x11ed53('0x19a4')]||_0x508be9===![])_0x24e607();})[_0x456277('0x130a')](function(_0x2181fa){const _0x65e9fa=_0x456277;_0x387be6['error']({'title':_0x65e9fa('0x1119'),'msg':_0x2181fa[_0x65e9fa('0x5a5')]?JSON[_0x65e9fa('0x258a')](_0x2181fa['data'][_0x65e9fa('0x8c2')]):_0x2181fa['toString']()});});}let _0x92697=!![],_0x916709=0x1;_0x421f81[_0x53c924('0x186d')](_0x53c924('0x1e1d'),function(_0x2612d3,_0x4a7cdc){const _0x16ae13=_0x53c924;_0x92697?_0xb68b09(function(){_0x92697=![];}):(!_0x4a7cdc&&(_0x916709=_0x5eff02['query']['page']),_0x2612d3!==_0x4a7cdc&&(_0x5eff02[_0x16ae13('0x23a2')][_0x16ae13('0xdf8')]=0x1),!_0x2612d3&&(_0x5eff02['query']['page']=_0x916709),_0x24e607(_0x5eff02[_0x16ae13('0x23a2')][_0x16ae13('0xdf8')]));}),_0x421f81[_0x53c924('0x26a2')]('$destroy',function(){const _0x322d9d=_0x53c924;_0x2a087c['removeAllListeners']('chatMessage:save'),_0x2a087c['removeAllListeners']('chatMessage:update'),_0x2a087c[_0x322d9d('0x1b9e')]('chatInteraction:save'),_0x2a087c[_0x322d9d('0x1b9e')](_0x322d9d('0x6f9')),_0x2a087c[_0x322d9d('0x1b9e')](_0x322d9d('0x1efd')),_0x2a087c[_0x322d9d('0x1b9e')](_0x322d9d('0xdca')),_0x2a087c[_0x322d9d('0x1b9e')]('user_has_chat_interactions:remove');});}const _0x58f845=_0x583efd;_0x59531e[_0x189033('0x14be')]=[_0x189033('0x16ea'),'$scope','$timeout',_0x189033('0x1e48'),_0x189033('0x2063'),_0x189033('0xba1'),'api','toasty'];function _0x59531e(_0x17ba45,_0x3cfad1,_0x3d4c39,_0xaa8cc,_0x16444e,_0x37c860,_0x582e0b,_0x4bdd9e){const _0xf83b6c=_0x189033,_0x3fcfa1=this;_0x3fcfa1['currentUser']=_0x37c860[_0xf83b6c('0x20b2')](),_0x3fcfa1['lists']={},_0x3fcfa1[_0xf83b6c('0x6d5')]={'count':0x0,'rows':[]},_0x3fcfa1[_0xf83b6c('0x1ce6')]={'count':0x0,'rows':[]},_0x3fcfa1[_0xf83b6c('0x23a2')]={'includeAll':!![],'sort':_0xf83b6c('0xc36'),'limit':0xa,'page':0x1},_0x3fcfa1[_0xf83b6c('0x19c9')]={'fields':[]},_0x3fcfa1[_0xf83b6c('0xd10')]=_0xf83b6c('0x22b'),_0x3fcfa1[_0xf83b6c('0x16cb')]=_0x130f6f,_0x3fcfa1[_0xf83b6c('0x985')]=_0x397b92,_0x3fcfa1['mergeContact']=_0x562a06,_0x3fcfa1[_0xf83b6c('0x1453')]=_0x3e40cd,_0x3fcfa1[_0xf83b6c('0x18e3')]=_0xe93f59,_0x3fcfa1[_0xf83b6c('0x164f')]=_0x3cfad1[_0xf83b6c('0x1cd5')]['vm'][_0xf83b6c('0x164f')],_0x3fcfa1['onInit']=_0x16e47a,_0x3fcfa1[_0xf83b6c('0xb65')]=_0x114e99,_0x3fcfa1[_0xf83b6c('0x229d')]=_0x1623be,_0x3fcfa1[_0xf83b6c('0x2121')]=_0x25e42d;function _0x16e47a(){const _0x5b60a8=_0xf83b6c;_0x582e0b[_0x5b60a8('0xc96')][_0x5b60a8('0x16c3')]({'id':_0x3fcfa1['currentUser']['id'],'fields':_0x5b60a8('0x97b'),'sort':_0x5b60a8('0x60a'),'nolimit':!![]})[_0x5b60a8('0xe53')]['then'](function(_0x1ca817){const _0x5d53d2=_0x5b60a8;return _0x3fcfa1[_0x5d53d2('0xe01')]=_0x1ca817||{'count':0x0,'rows':[]},_0x3fcfa1[_0x5d53d2('0x74e')]=_0x2e3ca0()['keyBy'](_0x3fcfa1['lists'][_0x5d53d2('0xf5d')],'id'),_0x582e0b['tag']['get']()[_0x5d53d2('0xe53')];})[_0x5b60a8('0x683')](function(_0xaeb530){_0x3fcfa1['tags']=_0xaeb530||{'count':0x0,'rows':[]};})[_0x5b60a8('0x683')](function(){_0x3fcfa1['quickFilters']=_0x299442();})['catch'](function(_0x26b6ad){const _0x1c08ea=_0x5b60a8;console[_0x1c08ea('0x52a')](_0x26b6ad);})[_0x5b60a8('0x2874')](function(){const _0x254c0b=_0x5b60a8;let _0x52a96f=_0x16444e['localStorage'][_0x254c0b('0x1b28')](_0x254c0b('0x1c02')+_0x3fcfa1[_0x254c0b('0x11ed')]['id']);if(_0x52a96f)try{_0x52a96f=JSON[_0x254c0b('0x1f34')](_0x52a96f);if(_0x52a96f[_0x254c0b('0x23a2')]){_0x3fcfa1[_0x254c0b('0x23a2')]=_0x2e3ca0()[_0x254c0b('0xf22')](_0x3fcfa1[_0x254c0b('0x23a2')],_0x52a96f[_0x254c0b('0x23a2')]);if(_0x2e3ca0()[_0x254c0b('0x173f')](_0x3fcfa1['lists']['rows']))_0x3fcfa1['query']['ListId']=[];else _0x2e3ca0()[_0x254c0b('0x173f')](_0x3fcfa1['query'][_0x254c0b('0x1e4f')])&&(_0x3fcfa1['query'][_0x254c0b('0x1e4f')]=_0x2e3ca0()(_0x3fcfa1[_0x254c0b('0xe01')][_0x254c0b('0xf5d')])[_0x254c0b('0x386')]('id')['take']()[_0x254c0b('0x1c6b')]());}}catch(_0x250d63){console[_0x254c0b('0x1b2b')](_0x250d63);}else _0x3fcfa1[_0x254c0b('0x23a2')][_0x254c0b('0x1e4f')]=_0x2e3ca0()[_0x254c0b('0x386')](_0x3fcfa1['lists'][_0x254c0b('0xf5d')],'id');_0x3fcfa1['isSearchBarVisible']=_0x3fcfa1[_0x254c0b('0x23a2')][_0x254c0b('0x25')]?!![]:![],_0x130f6f();});}function _0x299442(){const _0x5cb67a=_0xf83b6c;return[{'name':'List','key':_0x5cb67a('0x1e4f'),'type':_0x5cb67a('0xf6c'),'label':'CONTACTMANAGER.SELECT_LIST','options':_0x3fcfa1['lists'][_0x5cb67a('0xf5d')],'clearAll':![]},{'name':'Tag','key':_0x5cb67a('0x270'),'type':'multiselect','label':_0x5cb67a('0x2264'),'options':_0x3fcfa1['tags'][_0x5cb67a('0xf5d')],'placeholder':_0x5cb67a('0x7cb')}];}function _0x25140b(_0x892d64){const _0x51c7c1=_0xf83b6c;_0x3fcfa1[_0x51c7c1('0xab2')]=![],_0x3fcfa1[_0x51c7c1('0x6d5')]=_0x892d64||{'count':0x0,'rows':[]};}function _0x130f6f(_0x4db611){const _0x3a2f46=_0xf83b6c;_0x3fcfa1['searchInProgress']=!![],_0x2bbef7();!_0x4db611&&(_0x3fcfa1[_0x3a2f46('0x23a2')][_0x3a2f46('0xdf8')]=0x1);_0x3fcfa1[_0x3a2f46('0x23a2')]['offset']=(_0x3fcfa1[_0x3a2f46('0x23a2')][_0x3a2f46('0xdf8')]-0x1)*_0x3fcfa1['query'][_0x3a2f46('0x6f0')];let _0x5eb196=_0x16444e[_0x3a2f46('0x120e')][_0x3a2f46('0x1b28')](_0x3a2f46('0x1c02')+_0x3fcfa1['currentUser']['id']);_0x5eb196=_0x5eb196?JSON[_0x3a2f46('0x1f34')](_0x5eb196):{},_0x5eb196[_0x3a2f46('0x23a2')]=_0x3fcfa1[_0x3a2f46('0x23a2')],_0x16444e['localStorage'][_0x3a2f46('0x15d')](_0x3a2f46('0x1c02')+_0x3fcfa1[_0x3a2f46('0x11ed')]['id'],JSON[_0x3a2f46('0x258a')](_0x5eb196)),_0x3fcfa1['promise']=_0x582e0b['cmContact'][_0x3a2f46('0x1e6e')](_0x3fcfa1['query'],_0x25140b)[_0x3a2f46('0xe53')];}function _0xe93f59(_0x403168){const _0x1f94d7=_0xf83b6c;return _0x582e0b[_0x1f94d7('0x276e')]['get']({'id':_0x403168})[_0x1f94d7('0xe53')][_0x1f94d7('0x683')](function(_0x2997e2){const _0x165344=_0x1f94d7;_0x3cfad1[_0x165344('0x1cd5')]['vm'][_0x165344('0x15e')](_0x2997e2);});}function _0x397b92(){_0x130f6f();}function _0x3e40cd(_0x2fd816,_0x481925){const _0x3f3001=_0xf83b6c;_0xaa8cc[_0x3f3001('0x1d4')]({'controller':_0x3f3001('0x1757'),'controllerAs':'vm','templateUrl':_0x24dbc7,'parent':angular[_0x3f3001('0x1fcc')](_0x17ba45['body']),'targetEvent':_0x2fd816,'clickOutsideToClose':!![],'resolve':{'contact':['apiResolver',function(_0x3104be){const _0x8097c9=_0x3f3001;return _0x3104be['resolve'](_0x8097c9('0x23ec'),{'id':_0x481925['id']});}],'lists':[_0x3f3001('0x4b1'),function(_0x51c033){const _0x1941e9=_0x3f3001;return _0x51c033[_0x1941e9('0xed7')](_0x1941e9('0x2001'),{'id':_0x3fcfa1[_0x1941e9('0x11ed')]['id'],'fields':_0x1941e9('0xa10')});}]},'locals':{'contacts':_0x3fcfa1[_0x3f3001('0x6d5')][_0x3f3001('0xf5d')]}});}function _0x562a06(_0x421e76,_0x45fb1d){const _0x22fbc4=_0xf83b6c;_0xaa8cc[_0x22fbc4('0x1d4')]({'controller':_0x22fbc4('0x264'),'controllerAs':'vm','templateUrl':_0x7650f,'parent':angular[_0x22fbc4('0x1fcc')](_0x17ba45[_0x22fbc4('0x18e5')]),'targetEvent':_0x421e76,'clickOutsideToClose':!![],'resolve':{'contact':[_0x22fbc4('0x4b1'),function(_0x19d264){const _0x43946f=_0x22fbc4;return _0x19d264[_0x43946f('0xed7')]('cmContact@get',{'id':_0x45fb1d['id']});}],'lists':[_0x22fbc4('0x4b1'),function(_0x2fd390){const _0x47cf29=_0x22fbc4;return _0x2fd390[_0x47cf29('0xed7')](_0x47cf29('0x2001'),{'id':_0x3fcfa1[_0x47cf29('0x11ed')]['id'],'fields':_0x47cf29('0xa10')});}]},'locals':{'contacts':_0x3fcfa1[_0x22fbc4('0x6d5')][_0x22fbc4('0xf5d')]}});}function _0x114e99(){_0x3fcfa1['isSearchBarVisible']=![];}function _0x1623be(){const _0x688aa6=_0xf83b6c;_0x3fcfa1[_0x688aa6('0x1b8f')]=!![];}function _0x2bbef7(){const _0x1261f8=_0xf83b6c;return _0x582e0b[_0x1261f8('0x276e')][_0x1261f8('0x2267')]({'id':_0x3fcfa1[_0x1261f8('0x23a2')][_0x1261f8('0x1e4f')]})['$promise'][_0x1261f8('0x683')](function(_0x211678){const _0x500b8b=_0x1261f8;return _0x2e3ca0()(_0x211678[_0x500b8b('0x24e1')]())['omit'](_0x500b8b('0x10c5'))[_0x500b8b('0x17a0')]()[_0x500b8b('0x386')](function(_0x4bc750){return _0xb4d557(_0x4bc750);})[_0x500b8b('0x1c6b')]();})[_0x1261f8('0x683')](function(_0x4efda5){const _0x35ad14=_0x1261f8;_0x3fcfa1[_0x35ad14('0x19c9')][_0x35ad14('0x189a')]=_0x4efda5;const _0x13c842={'name':_0x35ad14('0x198f'),'column':_0x35ad14('0x1e'),'type':_0x35ad14('0xf6c'),'options':{'route':{'model':_0x35ad14('0x270'),'action':_0x35ad14('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x35ad14('0x1479')]}};let _0x2c4992=_0x2e3ca0()['findIndex'](_0x4efda5,function(_0x24fa44){const _0x1beebd=_0x35ad14;return _0x2e3ca0()['startsWith'](_0x24fa44[_0x1beebd('0x2008')],_0x1beebd('0x1469'));})||_0x4efda5['length']-0x1;if(_0x2c4992<0x0)_0x2c4992=_0x4efda5['length'];_0x3fcfa1['advancedSearch'][_0x35ad14('0x189a')]['splice'](_0x2c4992,0x0,_0x13c842);})['catch'](function(_0x17a628){const _0x2466a9=_0x1261f8;_0x4bdd9e[_0x2466a9('0x52a')]({'title':_0x17a628[_0x2466a9('0x13ee')]?_0x2466a9('0x2168')+_0x17a628[_0x2466a9('0x13ee')]+_0x2466a9('0xbf6')+_0x17a628['statusText']:_0x2466a9('0x17e9'),'msg':_0x17a628[_0x2466a9('0x5a5')]?JSON[_0x2466a9('0x258a')](_0x17a628[_0x2466a9('0x5a5')][_0x2466a9('0x8c2')]):_0x17a628[_0x2466a9('0x1ff0')]()});});}function _0xb4d557(_0xd44534){const _0x2bd4fc=_0xf83b6c,_0x2fdeb0={'name':_0x2e3ca0()[_0x2bd4fc('0x1e03')](_0xd44534[_0x2bd4fc('0x162d')]),'column':_0xd44534[_0x2bd4fc('0xa99')],'options':{}};if(_0xd44534[_0x2bd4fc('0xbf0')])switch(_0xd44534[_0x2bd4fc('0xbf0')][_0x2bd4fc('0xcf0')]){case _0x2bd4fc('0x1bcd'):_0x2fdeb0[_0x2bd4fc('0xcf0')]=_0x2bd4fc('0x1bcd');break;case'select':_0x2fdeb0[_0x2bd4fc('0xcf0')]=_0x2bd4fc('0xf6c'),_0x2fdeb0[_0x2bd4fc('0x17a0')]=_0x2e3ca0()['map'](JSON[_0x2bd4fc('0x1f34')](_0xd44534['custom']['values']),function(_0x4ea29a,_0x394c8a){const _0x1ab95c=_0x2bd4fc;return{'id':_0x394c8a,'name':_0x4ea29a[_0x1ab95c('0x1c6b')],'value':_0x4ea29a[_0x1ab95c('0x1c6b')]};}),_0x2fdeb0[_0x2bd4fc('0x158e')][_0x2bd4fc('0x2013')]='name';break;case _0x2bd4fc('0x2d0'):_0x2fdeb0[_0x2bd4fc('0xcf0')]=_0x2bd4fc('0xb31'),_0x2fdeb0[_0x2bd4fc('0x17a0')]=[{'id':0x1,'translate':_0x2bd4fc('0x1a96')},{'id':0x0,'translate':_0x2bd4fc('0x240b')}],_0x2fdeb0[_0x2bd4fc('0x158e')][_0x2bd4fc('0x2818')]=['$ne'];break;case _0x2bd4fc('0x121f'):_0x2fdeb0[_0x2bd4fc('0xcf0')]='number';break;case _0x2bd4fc('0x13a8'):_0x2fdeb0[_0x2bd4fc('0xcf0')]=_0x2bd4fc('0x270e');break;}else switch(_0xd44534['columnName']){case _0x2bd4fc('0x26a7'):_0x2fdeb0[_0x2bd4fc('0xcf0')]=_0x2bd4fc('0x270e');break;case'CompanyId':_0x2fdeb0['name']=_0x2bd4fc('0x1c9'),_0x2fdeb0[_0x2bd4fc('0xcf0')]=_0x2bd4fc('0xeb'),_0x2fdeb0[_0x2bd4fc('0x158e')][_0x2bd4fc('0x20ed')]={'model':_0x2bd4fc('0x27db'),'action':'get','params':{'fields':_0x2bd4fc('0xa10'),'nolimit':!![]}},_0x2fdeb0[_0x2bd4fc('0x158e')][_0x2bd4fc('0x177c')]=[_0x2bd4fc('0x60a')],_0x2fdeb0[_0x2bd4fc('0x158e')][_0x2bd4fc('0x2818')]=[_0x2bd4fc('0x17ee')];break;case _0x2bd4fc('0x1e4f'):_0x2fdeb0[_0x2bd4fc('0x60a')]=_0x2bd4fc('0x26da'),_0x2fdeb0['type']=_0x2bd4fc('0xeb'),_0x2fdeb0['options']['route']={'model':_0x2bd4fc('0xc96'),'action':_0x2bd4fc('0x16c3'),'params':{'id':_0x3fcfa1['currentUser']['id'],'fields':'id,name','nolimit':!![]}},_0x2fdeb0[_0x2bd4fc('0x158e')][_0x2bd4fc('0x177c')]=[_0x2bd4fc('0x60a')],_0x2fdeb0[_0x2bd4fc('0x158e')]['excludedOperators']=[_0x2bd4fc('0x17ee')];break;default:if(_0x2e3ca0()[_0x2bd4fc('0x2292')](_0xd44534['type']['toLowerCase'](),_0x2bd4fc('0x1d17')))_0x2fdeb0[_0x2bd4fc('0xcf0')]=_0x2bd4fc('0x121f');else _0x2e3ca0()[_0x2bd4fc('0x2292')](_0xd44534[_0x2bd4fc('0xcf0')][_0x2bd4fc('0x93a')](),_0x2bd4fc('0x270e'))?_0x2fdeb0[_0x2bd4fc('0xcf0')]=_0x2bd4fc('0x270e'):_0x2fdeb0[_0x2bd4fc('0xcf0')]=_0x2bd4fc('0x1bcd');break;}return _0x2fdeb0;}function _0x25e42d(){const _0x1b3cc2=_0xf83b6c;_0x3fcfa1['isSearchBarVisible']=![],_0xaa8cc[_0x1b3cc2('0x1d4')]({'controller':_0x1b3cc2('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x1b3cc2('0x1fcc')](_0x17ba45['body']),'clickOutsideToClose':![],'locals':{'color':_0x3fcfa1['sectionColor'],'fields':_0x3fcfa1[_0x1b3cc2('0x19c9')]['fields'],'storagePath':_0x1b3cc2('0x19a7')},'fullscreen':!![]})[_0x1b3cc2('0x683')](function(_0x401c0a){_0x3fcfa1['query']['search']=_0x401c0a===![]?undefined:_0x401c0a;if(_0x3fcfa1['query']['search']||_0x401c0a===![])_0x130f6f();})[_0x1b3cc2('0x130a')](function(_0x38131a){const _0x34ba78=_0x1b3cc2;_0x4bdd9e[_0x34ba78('0x52a')]({'title':'ERROR','msg':_0x38131a['data']?JSON[_0x34ba78('0x258a')](_0x38131a[_0x34ba78('0x5a5')][_0x34ba78('0x8c2')]):_0x38131a['toString']()});});}let _0x5695af=!![],_0x473827=0x1;_0x3cfad1['$watch']('vm.query.filter',function(_0x41c664,_0x111e66){const _0x48ecb5=_0xf83b6c;_0x5695af?_0x3d4c39(function(){_0x5695af=![];}):(!_0x111e66&&(_0x473827=_0x3fcfa1[_0x48ecb5('0x23a2')]['page']),_0x41c664!==_0x111e66&&(_0x3fcfa1[_0x48ecb5('0x23a2')][_0x48ecb5('0xdf8')]=0x1),!_0x41c664&&(_0x3fcfa1[_0x48ecb5('0x23a2')][_0x48ecb5('0xdf8')]=_0x473827),_0x130f6f());});}const _0x4cd57c=_0x59531e;_0x141fd7[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$interval'];function _0x141fd7(_0x18098b,_0x3ebfeb){const _0x514058=_0x189033;let _0x1ef161=_0x3ebfeb(function(){},0x3e7);_0x18098b[_0x514058('0x26a2')](_0x514058('0x4b8'),function(){const _0x4139f9=_0x514058;_0x1ef161&&(_0x3ebfeb[_0x4139f9('0x19fb')](_0x1ef161),_0x1ef161=null);});}const _0x37bb7b=_0x141fd7;_0x11e012[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$document',_0x189033('0x2063'),_0x189033('0x1d08'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1556')];function _0x11e012(_0x2ac6f9,_0x34cde7,_0x3940bd,_0x556bda,_0x2c561a,_0x3c6577,_0x45d505,_0x3aa4f5,_0xcb73aa){const _0x1f9297=_0x189033,_0x5117fc=this,_0x47e867=[_0x1f9297('0xcf0'),_0x1f9297('0x1386'),_0x1f9297('0x1091'),_0x1f9297('0x1455')];_0x5117fc[_0x1f9297('0x426')]={},_0x5117fc[_0x1f9297('0x10b2')]=0x0,_0x5117fc['rpcVoiceQueues']={},_0x5117fc[_0x1f9297('0x1713')]={},_0x5117fc[_0x1f9297('0x203c')]={},_0x5117fc[_0x1f9297('0xb98')]={},_0x5117fc[_0x1f9297('0x1ea3')]=[],_0x5117fc[_0x1f9297('0x182c')]=!![],_0x5117fc[_0x1f9297('0x23a2')]={'id':_0x3aa4f5[_0x1f9297('0x20b2')]()['id'],'fields':_0x1f9297('0xdb1'),'channel':_0x1f9297('0xcf2'),'type':_0x1f9297('0x17cd'),'limit':0xa,'page':0x1},_0x5117fc[_0x1f9297('0xcd9')]={'limit':0xa,'page':0x1},_0x5117fc[_0x1f9297('0x53')]=_0x192f46,_0x5117fc[_0x1f9297('0x1713')]=_0x31b586,_0x5117fc['getSize']=_0x121082,_0x5117fc['onSaveQueue']=_0x4bdb75,_0x5117fc['onSaveChannel']=_0xa5489f,_0x5117fc[_0x1f9297('0x1366')]=_0x3af86d,_0x5117fc[_0x1f9297('0x1c6')]=_0x41307c,_0x5117fc[_0x1f9297('0x1054')]=_0x4721d0,_0x5117fc['onRemoveVoiceQueue']=_0x36027d,_0xcb73aa['onWithoutApply']('voice_queue:save',_0x5117fc['onSaveQueue']),_0xcb73aa[_0x1f9297('0x5a3')]('voice_queue_channel:save',_0x5117fc['onSaveChannel']),_0xcb73aa[_0x1f9297('0x5a3')]('userVoiceQueue:save',_0x5117fc[_0x1f9297('0x1366')]),_0xcb73aa[_0x1f9297('0x5a3')](_0x1f9297('0x56f'),_0x5117fc[_0x1f9297('0x1366')]),_0xcb73aa[_0x1f9297('0x5a3')](_0x1f9297('0x240f'),_0x5117fc[_0x1f9297('0x1c6')]),_0xcb73aa[_0x1f9297('0x5a3')](_0x1f9297('0xfb0'),_0x5117fc['onRemoveVoiceQueue']),_0xcb73aa[_0x1f9297('0x5a3')]('voiceQueue:update',_0x5117fc[_0x1f9297('0x1054')]),_0x45d505[_0x1f9297('0x1b1b')][_0x1f9297('0x1713')]()[_0x1f9297('0xe53')][_0x1f9297('0x683')](function(_0x235350){const _0x307a7a=_0x1f9297;return _0x5117fc['rpcVoiceQueues']=_0x235350?_0x2e3ca0()['keyBy'](_0x235350['rows']?_0x235350[_0x307a7a('0xf5d')]:[],'id'):{},_0x45d505[_0x307a7a('0x1b1b')]['getVoiceQueuesChannels']()[_0x307a7a('0xe53')];})[_0x1f9297('0x683')](function(_0x4fda2a){const _0xbafb39=_0x1f9297;_0x5117fc[_0xbafb39('0x203c')]=_0x4fda2a?_0x2e3ca0()[_0xbafb39('0x24db')](_0x4fda2a[_0xbafb39('0xf5d')]?_0x2e3ca0()[_0xbafb39('0x25')](_0x4fda2a[_0xbafb39('0xf5d')],{'type':'outbound','queuecallerleaveAt':null}):[],_0xbafb39('0x573')):{};})[_0x1f9297('0x130a')](function(_0xfb36f0){const _0x16b3a6=_0x1f9297;console[_0x16b3a6('0x52a')](_0xfb36f0);})['finally'](function(){const _0x5e4c81=_0x1f9297;_0x2e3ca0()[_0x5e4c81('0xf22')](_0x5117fc[_0x5e4c81('0x203c')],_0x5117fc[_0x5e4c81('0xb98')]);for(let _0x43a06e=0x0;_0x43a06e<_0x5117fc['deleteVoiceQueuesChannels']['length'];_0x43a06e+=0x1){delete _0x5117fc[_0x5e4c81('0x203c')][_0x5117fc['deleteVoiceQueuesChannels'][_0x43a06e]];}_0x5117fc[_0x5e4c81('0x182c')]=![],_0x5117fc['addVoiceQueuesChannels']={},_0x5117fc[_0x5e4c81('0x1ea3')]=[],_0x5117fc[_0x5e4c81('0x1713')]();});function _0x192f46(_0x1938e8){const _0x59d1eb=_0x1f9297;_0x5117fc[_0x59d1eb('0x10b2')]=_0x1938e8[_0x59d1eb('0x50d')]?_0x1938e8[_0x59d1eb('0x50d')]:0x0,_0x5117fc['voiceQueues']=_0x1938e8?_0x2e3ca0()[_0x59d1eb('0x24db')](_0x1938e8[_0x59d1eb('0xf5d')]?_0x1938e8['rows']:[],'id'):{},_0x1253cf();}function _0x31b586(){const _0x156e0b=_0x1f9297;_0x5117fc[_0x156e0b('0x23a2')][_0x156e0b('0x1cc8')]=(_0x5117fc[_0x156e0b('0x23a2')][_0x156e0b('0xdf8')]-0x1)*_0x5117fc[_0x156e0b('0x23a2')]['limit'],_0x5117fc['promise']=_0x45d505[_0x156e0b('0xc96')][_0x156e0b('0x4c9')](_0x5117fc['query'],_0x192f46)['$promise'];}let _0x3757ef=!![],_0x739ea2=0x1;_0x2ac6f9[_0x1f9297('0x186d')]('vm_dc.query.filter',function(_0x37e571,_0x52c590){const _0x9fa9d3=_0x1f9297;_0x3757ef?_0x34cde7(function(){_0x3757ef=![];}):(!_0x52c590&&(_0x739ea2=_0x5117fc[_0x9fa9d3('0x23a2')][_0x9fa9d3('0xdf8')]),_0x37e571!==_0x52c590&&(_0x5117fc[_0x9fa9d3('0x23a2')][_0x9fa9d3('0xdf8')]=0x1),!_0x37e571&&(_0x5117fc['query'][_0x9fa9d3('0xdf8')]=_0x739ea2),_0x5117fc['getVoiceQueues']());});function _0x121082(_0x1a7056){return _0x2e3ca0()['size'](_0x1a7056);}function _0x1253cf(){const _0x2466d8=_0x1f9297;_0x2e3ca0()[_0x2466d8('0x15d0')](_0x5117fc[_0x2466d8('0x426')],function(_0x58c45f,_0x393512){const _0x4d0e9b=_0x2466d8;_0x5117fc[_0x4d0e9b('0x12cf')][_0x393512]&&(_0x5117fc[_0x4d0e9b('0x426')][_0x393512][_0x4d0e9b('0x1386')]=_0x5117fc[_0x4d0e9b('0x12cf')][_0x393512]['waiting']||0x0);});}function _0x4bdb75(_0x479d07){const _0xf7d4f4=_0x1f9297;_0x5117fc['voiceQueues'][_0x479d07['id']]&&(_0x5117fc[_0xf7d4f4('0x12cf')][_0x479d07['id']]&&(_0x5117fc[_0xf7d4f4('0x12cf')][_0x479d07['id']]=_0x479d07,_0x2e3ca0()[_0xf7d4f4('0xf22')](_0x5117fc[_0xf7d4f4('0x426')][_0x479d07['id']],_0x2e3ca0()['pick'](_0x479d07,_0x47e867))));}function _0xa5489f(_0x9955dc){const _0x1987b6=_0x1f9297;_0x9955dc[_0x1987b6('0xcf0')]===_0x1987b6('0x17cd')&&(_0x9955dc[_0x1987b6('0x2324')]?(delete _0x5117fc[_0x1987b6('0x203c')][_0x9955dc[_0x1987b6('0x573')]],_0x5117fc[_0x1987b6('0x182c')]&&_0x5117fc[_0x1987b6('0x1ea3')][_0x1987b6('0x1fd0')](_0x9955dc[_0x1987b6('0x573')])):(_0x5117fc[_0x1987b6('0x203c')][_0x9955dc['uniqueid']]=_0x9955dc,_0x5117fc[_0x1987b6('0x182c')]&&(_0x5117fc[_0x1987b6('0xb98')][_0x9955dc['uniqueid']]=_0x9955dc)));}function _0x41307c(_0x41e0e1){const _0x3190e8=_0x1f9297;!_0x2e3ca0()['isNil'](_0x41e0e1)&&(_0x5117fc[_0x3190e8('0x12cf')][_0x41e0e1['id']]=_0x2e3ca0()[_0x3190e8('0x24d0')](_0x41e0e1,_0x47e867));}function _0x4721d0(_0x870199){const _0x5112a8=_0x1f9297;!_0x2e3ca0()['isNil'](_0x870199)&&(_0x5117fc[_0x5112a8('0x12cf')][_0x870199['id']]&&_0x2e3ca0()[_0x5112a8('0xf22')](_0x5117fc[_0x5112a8('0x12cf')][_0x870199['id']],_0x2e3ca0()['pick'](_0x870199,_0x47e867)),_0x5117fc[_0x5112a8('0x426')][_0x870199['id']]&&_0x2e3ca0()[_0x5112a8('0xf22')](_0x5117fc['voiceQueues'][_0x870199['id']],_0x2e3ca0()[_0x5112a8('0x24d0')](_0x870199,_0x47e867)));}function _0x36027d(_0x436f66){const _0x4b8ada=_0x1f9297;!_0x2e3ca0()[_0x4b8ada('0x8f2')](_0x436f66)&&(delete _0x5117fc['rpcVoiceQueues'][_0x436f66['id']],delete _0x5117fc[_0x4b8ada('0x426')][_0x436f66['id']]);}function _0x3af86d(_0xc8e4b2){const _0x2bff32=_0x1f9297;_0x2e3ca0()[_0x2bff32('0xc77')](_0xc8e4b2[_0x2bff32('0x10c5')])===_0x3aa4f5[_0x2bff32('0x20b2')]()['id']&&_0x5117fc[_0x2bff32('0x1713')]();}_0x2ac6f9['$on']('$destroy',function(){const _0x2a653a=_0x1f9297;_0xcb73aa[_0x2a653a('0x1b9e')](_0x2a653a('0x1df')),_0xcb73aa['removeAllListeners'](_0x2a653a('0x99f')),_0xcb73aa[_0x2a653a('0x1b9e')](_0x2a653a('0x217c')),_0xcb73aa[_0x2a653a('0x1b9e')](_0x2a653a('0x56f')),_0xcb73aa[_0x2a653a('0x1b9e')](_0x2a653a('0x240f')),_0xcb73aa[_0x2a653a('0x1b9e')](_0x2a653a('0x779')),_0xcb73aa[_0x2a653a('0x1b9e')]('voiceQueue:remove');});}const _0x2db99e=_0x11e012;_0x1bcb25['$inject']=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2063'),_0x189033('0x1d08'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1556')];function _0x1bcb25(_0x51c1b8,_0x40af5d,_0x3244bb,_0x4b75ec,_0x321f59,_0x58cace,_0x58149c,_0x319f11,_0x35e550){const _0x120382=_0x189033,_0x36a60f=this,_0x263a9a=['id',_0x120382('0x60a'),'mapAgentsId',_0x120382('0x1386')];let _0x597855=!![];_0x36a60f[_0x120382('0x1253')]={},_0x36a60f[_0x120382('0x86e')]=0x0,_0x36a60f[_0x120382('0x140e')]={},_0x36a60f['paginatedInteractions']=[],_0x36a60f[_0x120382('0x8b8')]=[],_0x36a60f['rpcChatQueuesWaitingInteractions']={},_0x36a60f['query']={'id':_0x319f11['getCurrentUser']()['id'],'channel':'chat','fields':'id,name,mapAgentsId,waiting','limit':0xa,'page':0x1},_0x36a60f[_0x120382('0xcd9')]={'limit':0xa,'page':0x1},_0x36a60f[_0x120382('0x53')]=_0x2f7b84,_0x36a60f['getChatQueues']=_0x9aebce,_0x36a60f['getSize']=_0x5636af,_0x36a60f['getColorByChannel']=_0x4849cf,_0x36a60f['paginate']=_0x29f4fd,_0x36a60f[_0x120382('0x69a')]=_0x5c442a,_0x36a60f[_0x120382('0x2879')]=_0x581ae6,_0x36a60f[_0x120382('0xceb')]=_0x50cb10,_0x36a60f[_0x120382('0x13a0')]=_0x53fa44,_0x36a60f[_0x120382('0x26a5')]=_0x4e91e5,_0x36a60f[_0x120382('0x103d')]=_0x50020d,_0x36a60f[_0x120382('0xe5')]=_0x537259,_0x36a60f[_0x120382('0x210a')]=_0xcbe1e1,_0x35e550[_0x120382('0x5a3')]('chat_queue:save',_0x36a60f[_0x120382('0x69a')]),_0x35e550[_0x120382('0x5a3')]('chatQueue:save',_0x36a60f['onSaveChatQueue']),_0x35e550['onWithoutApply'](_0x120382('0x1a0b'),_0x36a60f['onUpdateChatQueue']),_0x35e550[_0x120382('0x5a3')](_0x120382('0x169c'),_0x36a60f[_0x120382('0x13a0')]),_0x35e550[_0x120382('0x5a3')](_0x120382('0x8db'),_0x36a60f[_0x120382('0x26a5')]),_0x35e550['onWithoutApply'](_0x120382('0xba7'),_0x36a60f[_0x120382('0x103d')]),_0x35e550[_0x120382('0x5a3')]('chat_queue_waiting_interaction:save',_0x36a60f[_0x120382('0xe5')]),_0x35e550[_0x120382('0x5a3')](_0x120382('0x371'),_0x36a60f[_0x120382('0x210a')]),_0x58149c[_0x120382('0x1b1b')][_0x120382('0xb2d')]()[_0x120382('0xe53')][_0x120382('0x683')](function(_0x18056f){const _0x425996=_0x120382;_0x36a60f[_0x425996('0x140e')]=_0x18056f?_0x2e3ca0()[_0x425996('0x24db')](_0x18056f['rows']?_0x18056f[_0x425996('0xf5d')]:[],'id'):{};})[_0x120382('0x683')](function(){const _0x40b4de=_0x120382;return _0x58149c[_0x40b4de('0xc96')][_0x40b4de('0x4c9')]({'id':_0x319f11[_0x40b4de('0x20b2')]()['id'],'channel':'chat'})[_0x40b4de('0xe53')];})[_0x120382('0x683')](function(_0x5c5d2f){const _0x2ce626=_0x120382;return _0x36a60f[_0x2ce626('0x9da')]=_0x5c5d2f[_0x2ce626('0xf5d')],_0x58149c['rpc']['getChatQueuesWaitingInteractions']()[_0x2ce626('0xe53')];})['then'](function(_0x32e972){const _0x2a7bbd=_0x120382,_0x146703=_0x2e3ca0()[_0x2a7bbd('0x25')](_0x32e972[_0x2a7bbd('0xf5d')],function(_0x1a56e4){const _0x25c175=_0x2a7bbd;return _0x2e3ca0()[_0x25c175('0x2292')](_0x36a60f['myQueues'],{'id':_0x1a56e4[_0x25c175('0xbe8')]});});_0x32e972[_0x2a7bbd('0xf5d')]=_0x146703,_0x32e972[_0x2a7bbd('0x50d')]=_0x146703[_0x2a7bbd('0x1564')],_0x2e3ca0()[_0x2a7bbd('0xf22')](_0x36a60f[_0x2a7bbd('0x373')],_0x32e972?_0x2e3ca0()[_0x2a7bbd('0x24db')](_0x32e972[_0x2a7bbd('0xf5d')]?_0x32e972[_0x2a7bbd('0xf5d')]:[],'id'):{});})['catch'](function(_0x13c023){const _0x22bed2=_0x120382;console[_0x22bed2('0x52a')](_0x13c023);})[_0x120382('0x2874')](function(){const _0x2e886f=_0x120382;for(let _0x1c1e9b=0x0;_0x1c1e9b<_0x36a60f[_0x2e886f('0x8b8')][_0x2e886f('0x1564')];_0x1c1e9b+=0x1){delete _0x36a60f[_0x2e886f('0x373')][_0x36a60f[_0x2e886f('0x8b8')][_0x1c1e9b]];}_0x597855=![],_0x36a60f['deleteChatQueuesWaitingInteractions']=[],_0x9aebce(),_0x29f4fd();});function _0x29f4fd(){const _0x152443=_0x120382,_0x5a6ec8=(_0x36a60f[_0x152443('0xcd9')]['page']-0x1)*_0x36a60f[_0x152443('0xcd9')][_0x152443('0x6f0')];_0x36a60f[_0x152443('0x1ea')]=_0x2e3ca0()[_0x152443('0x2ef')](_0x36a60f[_0x152443('0x373')],[_0x152443('0x27b1')],[_0x152443('0x1f5a')]),_0x36a60f[_0x152443('0x1768')]=_0x2e3ca0()[_0x152443('0x16b7')](_0x36a60f[_0x152443('0x1ea')],_0x5a6ec8)[_0x152443('0x12c8')](0x0,_0x36a60f[_0x152443('0xcd9')][_0x152443('0x6f0')]);}function _0x2f7b84(_0x2191d6){const _0x6a5af0=_0x120382;_0x36a60f[_0x6a5af0('0x86e')]=_0x2191d6[_0x6a5af0('0x50d')]?_0x2191d6[_0x6a5af0('0x50d')]:0x0,_0x36a60f[_0x6a5af0('0x1253')]=_0x2191d6?_0x2e3ca0()[_0x6a5af0('0x24db')](_0x2191d6[_0x6a5af0('0xf5d')]?_0x2191d6[_0x6a5af0('0xf5d')]:[],'id'):{},_0x39210d();}function _0x9aebce(){const _0x206562=_0x120382;_0x36a60f[_0x206562('0x23a2')][_0x206562('0x1cc8')]=(_0x36a60f[_0x206562('0x23a2')]['page']-0x1)*_0x36a60f['query'][_0x206562('0x6f0')],_0x36a60f[_0x206562('0x1883')]=_0x58149c[_0x206562('0xc96')][_0x206562('0x4c9')](_0x36a60f['query'],_0x2f7b84)['$promise'];}let _0x31789d=!![],_0xfd183f=0x1;_0x51c1b8[_0x120382('0x186d')](_0x120382('0x229'),function(_0x67003b,_0x13bb67){const _0x2ac5a5=_0x120382;_0x31789d?_0x40af5d(function(){_0x31789d=![];}):(!_0x13bb67&&(_0xfd183f=_0x36a60f[_0x2ac5a5('0x23a2')][_0x2ac5a5('0xdf8')]),_0x67003b!==_0x13bb67&&(_0x36a60f[_0x2ac5a5('0x23a2')][_0x2ac5a5('0xdf8')]=0x1),!_0x67003b&&(_0x36a60f['query'][_0x2ac5a5('0xdf8')]=_0xfd183f),_0x36a60f['getChatQueues']());});function _0x5636af(_0x59be89){return _0x2e3ca0()['size'](_0x59be89);}function _0x39210d(){const _0x147188=_0x120382;_0x2e3ca0()['forIn'](_0x36a60f[_0x147188('0x1253')],function(_0xc81585,_0x4489b1){const _0x12013b=_0x147188;_0x36a60f['rpcChatQueues'][_0x4489b1]&&(_0x36a60f[_0x12013b('0x1253')][_0x4489b1][_0x12013b('0x1386')]=_0x36a60f[_0x12013b('0x140e')][_0x4489b1][_0x12013b('0x1386')]||0x0);});}function _0x5c442a(_0x5870c1){const _0x137cec=_0x120382;_0x36a60f['chatQueues'][_0x5870c1['id']]&&(_0x36a60f[_0x137cec('0x140e')][_0x5870c1['id']]&&(_0x2e3ca0()[_0x137cec('0xf22')](_0x36a60f[_0x137cec('0x140e')][_0x5870c1['id']],_0x2e3ca0()[_0x137cec('0x24d0')](_0x5870c1,_0x263a9a)),_0x2e3ca0()[_0x137cec('0xf22')](_0x36a60f[_0x137cec('0x1253')][_0x5870c1['id']],_0x2e3ca0()['pick'](_0x5870c1,_0x263a9a))));}function _0x581ae6(_0x3606e4){const _0x5e8e00=_0x120382;!_0x2e3ca0()[_0x5e8e00('0x8f2')](_0x3606e4)&&(_0x36a60f[_0x5e8e00('0x140e')][_0x3606e4['id']]=_0x2e3ca0()['pick'](_0x3606e4,_0x263a9a));}function _0x50cb10(_0x194972){const _0x7cb9d8=_0x120382;!_0x2e3ca0()[_0x7cb9d8('0x8f2')](_0x194972)&&(_0x36a60f[_0x7cb9d8('0x140e')][_0x194972['id']]&&_0x2e3ca0()[_0x7cb9d8('0xf22')](_0x36a60f['rpcChatQueues'][_0x194972['id']],_0x2e3ca0()[_0x7cb9d8('0x24d0')](_0x194972,_0x263a9a)),_0x36a60f[_0x7cb9d8('0x1253')][_0x194972['id']]&&_0x2e3ca0()[_0x7cb9d8('0xf22')](_0x36a60f[_0x7cb9d8('0x1253')][_0x194972['id']],_0x2e3ca0()[_0x7cb9d8('0x24d0')](_0x194972,_0x263a9a)));}function _0x53fa44(_0x14dc7e){const _0x1c3116=_0x120382;!_0x2e3ca0()[_0x1c3116('0x8f2')](_0x14dc7e)&&(delete _0x36a60f[_0x1c3116('0x140e')][_0x14dc7e['id']],delete _0x36a60f[_0x1c3116('0x1253')][_0x14dc7e['id']]);}function _0x4e91e5(_0x29d904){const _0xf8fde5=_0x120382;_0x2e3ca0()[_0xf8fde5('0xc77')](_0x29d904['UserId'])===_0x319f11[_0xf8fde5('0x20b2')]()['id']&&_0x36a60f[_0xf8fde5('0xb2d')]();}function _0x50020d(_0x5f44e6){const _0xd624ed=_0x120382;_0x2e3ca0()[_0xd624ed('0xc77')](_0x5f44e6[_0xd624ed('0x10c5')])===_0x319f11['getCurrentUser']()['id']&&_0x36a60f[_0xd624ed('0xb2d')]();}function _0x537259(_0x737a7){const _0x461a33=_0x120382;_0x36a60f[_0x461a33('0x1253')][_0x737a7[_0x461a33('0xbe8')]]&&(_0x36a60f[_0x461a33('0x373')][_0x737a7['id']]=_0x737a7,_0x29f4fd());}function _0xcbe1e1(_0x20eca0){const _0x3b9cd8=_0x120382;delete _0x36a60f['rpcChatQueuesWaitingInteractions'][_0x20eca0['id']],_0x597855&&_0x36a60f[_0x3b9cd8('0x8b8')][_0x3b9cd8('0x1fd0')](_0x20eca0['id']),_0x29f4fd();}function _0x4849cf(_0x33b9c7){const _0x2a9ebe=_0x120382;switch(_0x33b9c7){case'chat':return'green-A700-bg';case _0x2a9ebe('0x129f'):return'teal-bg';case _0x2a9ebe('0x1285'):return _0x2a9ebe('0x2456');case _0x2a9ebe('0x16e7'):return'lime-A700-bg';case _0x2a9ebe('0x1261'):return _0x2a9ebe('0x1730');case _0x2a9ebe('0x23e9'):return _0x2a9ebe('0x1fcd');default:return _0x2a9ebe('0x1b0e');}}_0x51c1b8[_0x120382('0x26a2')](_0x120382('0x4b8'),function(){const _0x385c56=_0x120382;_0x35e550[_0x385c56('0x1b9e')]('chat_queue:save'),_0x35e550['removeAllListeners'](_0x385c56('0x9e6')),_0x35e550['removeAllListeners'](_0x385c56('0x1a0b')),_0x35e550[_0x385c56('0x1b9e')](_0x385c56('0x169c')),_0x35e550[_0x385c56('0x1b9e')]('userChatQueue:save'),_0x35e550['removeAllListeners'](_0x385c56('0xba7')),_0x35e550[_0x385c56('0x1b9e')](_0x385c56('0xb30')),_0x35e550[_0x385c56('0x1b9e')](_0x385c56('0x371'));});}const _0x5b4601=_0x1bcb25;_0x433c5a['$inject']=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$window','$translate','api',_0x189033('0xba1'),'socket'];function _0x433c5a(_0x5e9167,_0x52bce6,_0x5dfef5,_0x21b9bf,_0xd49a2e,_0x50e068,_0x4d477a,_0x158bbd,_0x28298e){const _0x35ad8e=_0x189033,_0x508440=this,_0x1c9ca2=['id','name',_0x35ad8e('0xe11'),'waiting'];let _0x301c71=!![];_0x508440[_0x35ad8e('0xec3')]={},_0x508440[_0x35ad8e('0x1131')]=0x0,_0x508440['rpcFaxQueues']={},_0x508440[_0x35ad8e('0x1ea')]=[],_0x508440[_0x35ad8e('0x606')]=[],_0x508440[_0x35ad8e('0xfba')]={},_0x508440[_0x35ad8e('0x23a2')]={'id':_0x158bbd['getCurrentUser']()['id'],'channel':_0x35ad8e('0x23e9'),'fields':_0x35ad8e('0x1ae7'),'limit':0xa,'page':0x1},_0x508440[_0x35ad8e('0xcd9')]={'limit':0xa,'page':0x1},_0x508440[_0x35ad8e('0x53')]=_0x20f5aa,_0x508440[_0x35ad8e('0x693')]=_0x473d9e,_0x508440[_0x35ad8e('0x2487')]=_0x368e29,_0x508440[_0x35ad8e('0x2590')]=_0x3c5877,_0x508440[_0x35ad8e('0x18d1')]=_0x10dab7,_0x508440[_0x35ad8e('0x69a')]=_0x681e48,_0x508440[_0x35ad8e('0x32b')]=_0x9e1487,_0x508440[_0x35ad8e('0x1d10')]=_0x135978,_0x508440[_0x35ad8e('0x1b3f')]=_0x5b1d40,_0x508440[_0x35ad8e('0x1699')]=_0x2a17ec,_0x508440['onRemoveUserFaxQueue']=_0x231e96,_0x508440[_0x35ad8e('0x2566')]=_0xf209ca,_0x508440['onRemoveFaxQueueChannel']=_0x3dc1c5,_0x28298e[_0x35ad8e('0x5a3')](_0x35ad8e('0x2314'),_0x508440[_0x35ad8e('0x69a')]),_0x28298e['onWithoutApply'](_0x35ad8e('0x1f9f'),_0x508440[_0x35ad8e('0x32b')]),_0x28298e['onWithoutApply'](_0x35ad8e('0x1155'),_0x508440[_0x35ad8e('0x1d10')]),_0x28298e[_0x35ad8e('0x5a3')](_0x35ad8e('0x2762'),_0x508440[_0x35ad8e('0x1b3f')]),_0x28298e['onWithoutApply'](_0x35ad8e('0x1495'),_0x508440[_0x35ad8e('0x1699')]),_0x28298e['onWithoutApply'](_0x35ad8e('0xcf4'),_0x508440[_0x35ad8e('0x1a')]),_0x28298e[_0x35ad8e('0x5a3')](_0x35ad8e('0xb85'),_0x508440[_0x35ad8e('0x2566')]),_0x28298e[_0x35ad8e('0x5a3')](_0x35ad8e('0x90c'),_0x508440[_0x35ad8e('0xf67')]),_0x4d477a['rpc'][_0x35ad8e('0x693')]()[_0x35ad8e('0xe53')]['then'](function(_0x369dbc){const _0x63646c=_0x35ad8e;_0x508440[_0x63646c('0xcc2')]=_0x369dbc?_0x2e3ca0()['keyBy'](_0x369dbc[_0x63646c('0xf5d')]?_0x369dbc['rows']:[],'id'):{};})[_0x35ad8e('0x683')](function(){const _0x11fd1d=_0x35ad8e;return _0x4d477a[_0x11fd1d('0xc96')][_0x11fd1d('0x4c9')]({'id':_0x158bbd[_0x11fd1d('0x20b2')]()['id'],'channel':_0x11fd1d('0x23e9')})[_0x11fd1d('0xe53')];})['then'](function(_0x2f4e30){const _0x48c678=_0x35ad8e;return _0x508440[_0x48c678('0x9da')]=_0x2f4e30[_0x48c678('0xf5d')],_0x4d477a[_0x48c678('0x1b1b')][_0x48c678('0x4e')]()[_0x48c678('0xe53')];})[_0x35ad8e('0x683')](function(_0x26fc5a){const _0x5705eb=_0x35ad8e,_0x2a6752=_0x2e3ca0()[_0x5705eb('0x25')](_0x26fc5a['rows'],function(_0xfed6f8){const _0xa5e8f5=_0x5705eb;return _0x2e3ca0()[_0xa5e8f5('0x2292')](_0x508440[_0xa5e8f5('0x9da')],{'id':_0xfed6f8[_0xa5e8f5('0xbe8')]});});_0x26fc5a[_0x5705eb('0xf5d')]=_0x2a6752,_0x26fc5a[_0x5705eb('0x50d')]=_0x2a6752[_0x5705eb('0x1564')],_0x2e3ca0()[_0x5705eb('0xf22')](_0x508440['rpcFaxQueuesWaitingInteractions'],_0x26fc5a?_0x2e3ca0()['keyBy'](_0x26fc5a[_0x5705eb('0xf5d')]?_0x26fc5a['rows']:[],'id'):{});})[_0x35ad8e('0x130a')](function(_0x4f9b66){const _0x5df3ab=_0x35ad8e;console[_0x5df3ab('0x52a')](_0x4f9b66);})[_0x35ad8e('0x2874')](function(){const _0x5bdb0b=_0x35ad8e;for(let _0x20155d=0x0;_0x20155d<_0x508440[_0x5bdb0b('0x606')][_0x5bdb0b('0x1564')];_0x20155d+=0x1){delete _0x508440[_0x5bdb0b('0xfba')][_0x508440[_0x5bdb0b('0x606')][_0x20155d]];}_0x301c71=![],_0x508440[_0x5bdb0b('0x606')]=[],_0x473d9e(),_0x10dab7();});function _0x10dab7(){const _0x4b6842=_0x35ad8e,_0x1f8a8c=(_0x508440[_0x4b6842('0xcd9')][_0x4b6842('0xdf8')]-0x1)*_0x508440[_0x4b6842('0xcd9')]['limit'];_0x508440[_0x4b6842('0x1ea')]=_0x2e3ca0()[_0x4b6842('0x2ef')](_0x508440[_0x4b6842('0xfba')],[_0x4b6842('0x27b1')],[_0x4b6842('0x1f5a')]),_0x508440[_0x4b6842('0x1768')]=_0x2e3ca0()[_0x4b6842('0x16b7')](_0x508440[_0x4b6842('0x1ea')],_0x1f8a8c)[_0x4b6842('0x12c8')](0x0,_0x508440['queryChannels'][_0x4b6842('0x6f0')]);}function _0x20f5aa(_0x52cf2d){const _0x8ba4f1=_0x35ad8e;_0x508440[_0x8ba4f1('0x1131')]=_0x52cf2d[_0x8ba4f1('0x50d')]?_0x52cf2d['count']:0x0,_0x508440[_0x8ba4f1('0xec3')]=_0x52cf2d?_0x2e3ca0()[_0x8ba4f1('0x24db')](_0x52cf2d[_0x8ba4f1('0xf5d')]?_0x52cf2d[_0x8ba4f1('0xf5d')]:[],'id'):{},_0x54c5a0();}function _0x473d9e(){const _0x3a0dc8=_0x35ad8e;_0x508440[_0x3a0dc8('0x23a2')][_0x3a0dc8('0x1cc8')]=(_0x508440[_0x3a0dc8('0x23a2')][_0x3a0dc8('0xdf8')]-0x1)*_0x508440[_0x3a0dc8('0x23a2')]['limit'],_0x508440[_0x3a0dc8('0x1883')]=_0x4d477a[_0x3a0dc8('0xc96')][_0x3a0dc8('0x4c9')](_0x508440[_0x3a0dc8('0x23a2')],_0x20f5aa)[_0x3a0dc8('0xe53')];}let _0x541c39=!![],_0x7a054f=0x1;_0x5e9167[_0x35ad8e('0x186d')](_0x35ad8e('0x229'),function(_0x1e3f4e,_0x1cd6d1){const _0x31c984=_0x35ad8e;_0x541c39?_0x52bce6(function(){_0x541c39=![];}):(!_0x1cd6d1&&(_0x7a054f=_0x508440[_0x31c984('0x23a2')][_0x31c984('0xdf8')]),_0x1e3f4e!==_0x1cd6d1&&(_0x508440['query'][_0x31c984('0xdf8')]=0x1),!_0x1e3f4e&&(_0x508440[_0x31c984('0x23a2')][_0x31c984('0xdf8')]=_0x7a054f),_0x508440[_0x31c984('0x693')]());});function _0x368e29(_0x382b37){return _0x2e3ca0()['size'](_0x382b37);}function _0x54c5a0(){const _0x4b8ad0=_0x35ad8e;_0x2e3ca0()[_0x4b8ad0('0x15d0')](_0x508440[_0x4b8ad0('0xec3')],function(_0x4a5e9a,_0x25a161){const _0x42a7a6=_0x4b8ad0;_0x508440[_0x42a7a6('0xcc2')][_0x25a161]&&(_0x508440[_0x42a7a6('0xec3')][_0x25a161][_0x42a7a6('0x1386')]=_0x508440[_0x42a7a6('0xcc2')][_0x25a161]['waiting']||0x0);});}function _0x681e48(_0x1533bc){const _0x4860ce=_0x35ad8e;_0x508440['faxQueues'][_0x1533bc['id']]&&(_0x508440[_0x4860ce('0xcc2')][_0x1533bc['id']]&&(_0x2e3ca0()[_0x4860ce('0xf22')](_0x508440[_0x4860ce('0xcc2')][_0x1533bc['id']],_0x2e3ca0()[_0x4860ce('0x24d0')](_0x1533bc,_0x1c9ca2)),_0x2e3ca0()[_0x4860ce('0xf22')](_0x508440[_0x4860ce('0xec3')][_0x1533bc['id']],_0x2e3ca0()[_0x4860ce('0x24d0')](_0x1533bc,_0x1c9ca2))));}function _0x9e1487(_0xf8f023){const _0xcb4472=_0x35ad8e;!_0x2e3ca0()['isNil'](_0xf8f023)&&(_0x508440[_0xcb4472('0xcc2')][_0xf8f023['id']]=_0x2e3ca0()['pick'](_0xf8f023,_0x1c9ca2));}function _0x135978(_0x3a348d){const _0x23729a=_0x35ad8e;!_0x2e3ca0()['isNil'](_0x3a348d)&&(_0x508440[_0x23729a('0xcc2')][_0x3a348d['id']]&&_0x2e3ca0()[_0x23729a('0xf22')](_0x508440[_0x23729a('0xcc2')][_0x3a348d['id']],_0x2e3ca0()[_0x23729a('0x24d0')](_0x3a348d,_0x1c9ca2)),_0x508440[_0x23729a('0xec3')][_0x3a348d['id']]&&_0x2e3ca0()['merge'](_0x508440['faxQueues'][_0x3a348d['id']],_0x2e3ca0()[_0x23729a('0x24d0')](_0x3a348d,_0x1c9ca2)));}function _0x5b1d40(_0x2d943f){const _0x5aaf49=_0x35ad8e;!_0x2e3ca0()[_0x5aaf49('0x8f2')](_0x2d943f)&&(delete _0x508440[_0x5aaf49('0xcc2')][_0x2d943f['id']],delete _0x508440[_0x5aaf49('0xec3')][_0x2d943f['id']]);}function _0x2a17ec(_0x3497cb){const _0x4171ed=_0x35ad8e;_0x2e3ca0()[_0x4171ed('0xc77')](_0x3497cb[_0x4171ed('0x10c5')])===_0x158bbd[_0x4171ed('0x20b2')]()['id']&&_0x508440[_0x4171ed('0x693')]();}function _0x231e96(_0x41455b){const _0x44989e=_0x35ad8e;_0x2e3ca0()[_0x44989e('0xc77')](_0x41455b['UserId'])===_0x158bbd[_0x44989e('0x20b2')]()['id']&&_0x508440[_0x44989e('0x693')]();}function _0xf209ca(_0x15fe97){const _0x575155=_0x35ad8e;_0x508440[_0x575155('0xec3')][_0x15fe97[_0x575155('0xbe8')]]&&(_0x508440[_0x575155('0xfba')][_0x15fe97['id']]=_0x15fe97,_0x10dab7());}function _0x3dc1c5(_0x56b535){const _0x1f5727=_0x35ad8e;delete _0x508440['rpcFaxQueuesWaitingInteractions'][_0x56b535['id']],_0x301c71&&_0x508440[_0x1f5727('0x606')]['push'](_0x56b535['id']),_0x10dab7();}function _0x3c5877(_0x5aceac){const _0x35cda1=_0x35ad8e;switch(_0x5aceac){case _0x35cda1('0x24e'):return'green-A700-bg';case _0x35cda1('0x129f'):return _0x35cda1('0x2505');case _0x35cda1('0x1285'):return'orange-bg';case _0x35cda1('0x16e7'):return _0x35cda1('0xa52');case'openchannel':return'amber-A200-bg';case'fax':return _0x35cda1('0x1fcd');default:return _0x35cda1('0x1b0e');}}_0x5e9167[_0x35ad8e('0x26a2')]('$destroy',function(){const _0x3350c0=_0x35ad8e;_0x28298e[_0x3350c0('0x1b9e')](_0x3350c0('0x2314')),_0x28298e[_0x3350c0('0x1b9e')](_0x3350c0('0x1f9f')),_0x28298e['removeAllListeners']('faxQueue:update'),_0x28298e['removeAllListeners'](_0x3350c0('0x2762')),_0x28298e[_0x3350c0('0x1b9e')](_0x3350c0('0x1495')),_0x28298e[_0x3350c0('0x1b9e')]('userFaxQueue:remove'),_0x28298e[_0x3350c0('0x1b9e')]('fax_queue_waiting_interaction:save'),_0x28298e['removeAllListeners'](_0x3350c0('0x90c'));});}const _0x427e5c=_0x433c5a;_0x30f986[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$document',_0x189033('0x2063'),_0x189033('0x1d08'),'api',_0x189033('0xba1'),_0x189033('0x1556')];function _0x30f986(_0x50f435,_0x463db6,_0x5c7a4e,_0x268b22,_0x5b1d5b,_0x3511fc,_0x5567f9,_0x3bbac5,_0x306041){const _0x3acc0e=_0x189033,_0x10358b=this,_0x45a1d1=['id',_0x3acc0e('0x60a'),'mapAgentsId',_0x3acc0e('0x1386')];let _0x12399d=!![];_0x10358b[_0x3acc0e('0xc05')]={},_0x10358b[_0x3acc0e('0x11d9')]=0x0,_0x10358b['rpcMailQueues']={},_0x10358b[_0x3acc0e('0x1ea')]=[],_0x10358b['deleteMailQueuesWaitingInteractions']=[],_0x10358b[_0x3acc0e('0x1311')]={},_0x10358b[_0x3acc0e('0x23a2')]={'id':_0x3bbac5[_0x3acc0e('0x20b2')]()['id'],'channel':_0x3acc0e('0x129f'),'fields':_0x3acc0e('0x1ae7'),'limit':0xa,'page':0x1},_0x10358b[_0x3acc0e('0xcd9')]={'limit':0xa,'page':0x1},_0x10358b[_0x3acc0e('0x53')]=_0x31134f,_0x10358b[_0x3acc0e('0x4b7')]=_0x7ad815,_0x10358b[_0x3acc0e('0x2487')]=_0x5316f9,_0x10358b[_0x3acc0e('0x2590')]=_0x1aaac0,_0x10358b[_0x3acc0e('0x18d1')]=_0x12c4b9,_0x10358b[_0x3acc0e('0x69a')]=_0x6d1ada,_0x10358b[_0x3acc0e('0x1bb0')]=_0x5dd68b,_0x10358b[_0x3acc0e('0x7e9')]=_0x1a5f35,_0x10358b[_0x3acc0e('0x1136')]=_0x39e7ce,_0x10358b['onSaveUserMailQueue']=_0x4bc3bb,_0x10358b[_0x3acc0e('0x271f')]=_0x5cef26,_0x10358b[_0x3acc0e('0x1b91')]=_0xe53e7a,_0x10358b[_0x3acc0e('0x1500')]=_0x183fde,_0x306041['onWithoutApply'](_0x3acc0e('0xd92'),_0x10358b['onSaveQueue']),_0x306041[_0x3acc0e('0x5a3')](_0x3acc0e('0x2617'),_0x10358b['onSaveMailQueue']),_0x306041[_0x3acc0e('0x5a3')](_0x3acc0e('0x20f3'),_0x10358b[_0x3acc0e('0x7e9')]),_0x306041[_0x3acc0e('0x5a3')]('mailQueue:remove',_0x10358b[_0x3acc0e('0x1136')]),_0x306041[_0x3acc0e('0x5a3')](_0x3acc0e('0x1eaf'),_0x10358b[_0x3acc0e('0xe99')]),_0x306041[_0x3acc0e('0x5a3')](_0x3acc0e('0x165'),_0x10358b[_0x3acc0e('0x271f')]),_0x306041[_0x3acc0e('0x5a3')](_0x3acc0e('0x21cc'),_0x10358b[_0x3acc0e('0x1b91')]),_0x306041[_0x3acc0e('0x5a3')]('mail_queue_waiting_interaction:remove',_0x10358b[_0x3acc0e('0x1500')]),_0x5567f9[_0x3acc0e('0x1b1b')][_0x3acc0e('0x4b7')]()['$promise']['then'](function(_0x43d628){const _0x4760a1=_0x3acc0e;_0x10358b[_0x4760a1('0x17c3')]=_0x43d628?_0x2e3ca0()[_0x4760a1('0x24db')](_0x43d628[_0x4760a1('0xf5d')]?_0x43d628['rows']:[],'id'):{};})[_0x3acc0e('0x683')](function(){const _0x20ba36=_0x3acc0e;return _0x5567f9[_0x20ba36('0xc96')][_0x20ba36('0x4c9')]({'id':_0x3bbac5[_0x20ba36('0x20b2')]()['id'],'channel':_0x20ba36('0x129f')})['$promise'];})[_0x3acc0e('0x683')](function(_0x289894){const _0x561934=_0x3acc0e;return _0x10358b[_0x561934('0x9da')]=_0x289894[_0x561934('0xf5d')],_0x5567f9[_0x561934('0x1b1b')]['getMailQueuesWaitingInteractions']()[_0x561934('0xe53')];})[_0x3acc0e('0x683')](function(_0x5cc88c){const _0xe70617=_0x3acc0e,_0x27bef6=_0x2e3ca0()[_0xe70617('0x25')](_0x5cc88c[_0xe70617('0xf5d')],function(_0x56213e){const _0x11ce6d=_0xe70617;return _0x2e3ca0()[_0x11ce6d('0x2292')](_0x10358b[_0x11ce6d('0x9da')],{'id':_0x56213e[_0x11ce6d('0xbe8')]});});_0x5cc88c[_0xe70617('0xf5d')]=_0x27bef6,_0x5cc88c[_0xe70617('0x50d')]=_0x27bef6['length'],_0x2e3ca0()['merge'](_0x10358b[_0xe70617('0x1311')],_0x5cc88c?_0x2e3ca0()[_0xe70617('0x24db')](_0x5cc88c[_0xe70617('0xf5d')]?_0x5cc88c[_0xe70617('0xf5d')]:[],'id'):{});})['catch'](function(_0x502a72){const _0x583ff6=_0x3acc0e;console[_0x583ff6('0x52a')](_0x502a72);})[_0x3acc0e('0x2874')](function(){const _0x30554d=_0x3acc0e;for(let _0x432de2=0x0;_0x432de2<_0x10358b['deleteMailQueuesWaitingInteractions'][_0x30554d('0x1564')];_0x432de2+=0x1){delete _0x10358b['rpcMailQueuesWaitingInteractions'][_0x10358b['deleteMailQueuesWaitingInteractions'][_0x432de2]];}_0x12399d=![],_0x10358b['deleteMailQueuesWaitingInteractions']=[],_0x7ad815(),_0x12c4b9();});function _0x12c4b9(){const _0x62a6bb=_0x3acc0e,_0x291a83=(_0x10358b[_0x62a6bb('0xcd9')]['page']-0x1)*_0x10358b[_0x62a6bb('0xcd9')][_0x62a6bb('0x6f0')];_0x10358b[_0x62a6bb('0x1ea')]=_0x2e3ca0()[_0x62a6bb('0x2ef')](_0x10358b[_0x62a6bb('0x1311')],[_0x62a6bb('0x27b1')],[_0x62a6bb('0x1f5a')]),_0x10358b[_0x62a6bb('0x1768')]=_0x2e3ca0()[_0x62a6bb('0x16b7')](_0x10358b[_0x62a6bb('0x1ea')],_0x291a83)['slice'](0x0,_0x10358b[_0x62a6bb('0xcd9')]['limit']);}function _0x31134f(_0x3c1cfd){const _0x2255b0=_0x3acc0e;_0x10358b['mailQueuesTotal']=_0x3c1cfd[_0x2255b0('0x50d')]?_0x3c1cfd[_0x2255b0('0x50d')]:0x0,_0x10358b['mailQueues']=_0x3c1cfd?_0x2e3ca0()['keyBy'](_0x3c1cfd['rows']?_0x3c1cfd['rows']:[],'id'):{},_0x2c4fd6();}function _0x7ad815(){const _0x4f5d6a=_0x3acc0e;_0x10358b[_0x4f5d6a('0x23a2')][_0x4f5d6a('0x1cc8')]=(_0x10358b[_0x4f5d6a('0x23a2')][_0x4f5d6a('0xdf8')]-0x1)*_0x10358b[_0x4f5d6a('0x23a2')][_0x4f5d6a('0x6f0')],_0x10358b[_0x4f5d6a('0x1883')]=_0x5567f9[_0x4f5d6a('0xc96')][_0x4f5d6a('0x4c9')](_0x10358b[_0x4f5d6a('0x23a2')],_0x31134f)[_0x4f5d6a('0xe53')];}let _0x330a81=!![],_0x419cfc=0x1;_0x50f435['$watch'](_0x3acc0e('0x229'),function(_0x49817f,_0x42d9f5){const _0x457c91=_0x3acc0e;_0x330a81?_0x463db6(function(){_0x330a81=![];}):(!_0x42d9f5&&(_0x419cfc=_0x10358b['query']['page']),_0x49817f!==_0x42d9f5&&(_0x10358b[_0x457c91('0x23a2')][_0x457c91('0xdf8')]=0x1),!_0x49817f&&(_0x10358b[_0x457c91('0x23a2')][_0x457c91('0xdf8')]=_0x419cfc),_0x10358b['getMailQueues']());});function _0x5316f9(_0x48ebe9){return _0x2e3ca0()['size'](_0x48ebe9);}function _0x2c4fd6(){const _0x30aefd=_0x3acc0e;_0x2e3ca0()[_0x30aefd('0x15d0')](_0x10358b['mailQueues'],function(_0x14da4e,_0x43802a){const _0x2b0895=_0x30aefd;_0x10358b['rpcMailQueues'][_0x43802a]&&(_0x10358b[_0x2b0895('0xc05')][_0x43802a][_0x2b0895('0x1386')]=_0x10358b['rpcMailQueues'][_0x43802a]['waiting']||0x0);});}function _0x6d1ada(_0x46629e){const _0x3c0841=_0x3acc0e;_0x10358b['mailQueues'][_0x46629e['id']]&&(_0x10358b[_0x3c0841('0x17c3')][_0x46629e['id']]&&(_0x2e3ca0()[_0x3c0841('0xf22')](_0x10358b[_0x3c0841('0x17c3')][_0x46629e['id']],_0x2e3ca0()['pick'](_0x46629e,_0x45a1d1)),_0x2e3ca0()[_0x3c0841('0xf22')](_0x10358b[_0x3c0841('0xc05')][_0x46629e['id']],_0x2e3ca0()[_0x3c0841('0x24d0')](_0x46629e,_0x45a1d1))));}function _0x5dd68b(_0x3556af){const _0x6293ae=_0x3acc0e;!_0x2e3ca0()['isNil'](_0x3556af)&&(_0x10358b[_0x6293ae('0x17c3')][_0x3556af['id']]=_0x2e3ca0()['pick'](_0x3556af,_0x45a1d1));}function _0x1a5f35(_0x51045e){const _0x353b92=_0x3acc0e;!_0x2e3ca0()[_0x353b92('0x8f2')](_0x51045e)&&(_0x10358b[_0x353b92('0x17c3')][_0x51045e['id']]&&_0x2e3ca0()[_0x353b92('0xf22')](_0x10358b[_0x353b92('0x17c3')][_0x51045e['id']],_0x2e3ca0()[_0x353b92('0x24d0')](_0x51045e,_0x45a1d1)),_0x10358b['mailQueues'][_0x51045e['id']]&&_0x2e3ca0()[_0x353b92('0xf22')](_0x10358b[_0x353b92('0xc05')][_0x51045e['id']],_0x2e3ca0()[_0x353b92('0x24d0')](_0x51045e,_0x45a1d1)));}function _0x39e7ce(_0x1f653f){const _0x15470c=_0x3acc0e;!_0x2e3ca0()['isNil'](_0x1f653f)&&(delete _0x10358b[_0x15470c('0x17c3')][_0x1f653f['id']],delete _0x10358b[_0x15470c('0xc05')][_0x1f653f['id']]);}function _0x4bc3bb(_0x292603){const _0x3b14ef=_0x3acc0e;_0x2e3ca0()['toInteger'](_0x292603[_0x3b14ef('0x10c5')])===_0x3bbac5[_0x3b14ef('0x20b2')]()['id']&&_0x10358b[_0x3b14ef('0x4b7')]();}function _0x5cef26(_0x115e64){const _0x2fed06=_0x3acc0e;_0x2e3ca0()[_0x2fed06('0xc77')](_0x115e64[_0x2fed06('0x10c5')])===_0x3bbac5[_0x2fed06('0x20b2')]()['id']&&_0x10358b['getMailQueues']();}function _0xe53e7a(_0x11511e){const _0x3369e1=_0x3acc0e;_0x10358b[_0x3369e1('0xc05')][_0x11511e['queue_id']]&&(_0x10358b[_0x3369e1('0x1311')][_0x11511e['id']]=_0x11511e,_0x12c4b9());}function _0x183fde(_0x5301e9){const _0x1e10f9=_0x3acc0e;delete _0x10358b[_0x1e10f9('0x1311')][_0x5301e9['id']],_0x12399d&&_0x10358b['deleteMailQueuesWaitingInteractions'][_0x1e10f9('0x1fd0')](_0x5301e9['id']),_0x12c4b9();}function _0x1aaac0(_0x5bbbcf){const _0x1778d8=_0x3acc0e;switch(_0x5bbbcf){case _0x1778d8('0x24e'):return _0x1778d8('0xb3c');case _0x1778d8('0x129f'):return _0x1778d8('0x2505');case'sms':return _0x1778d8('0x2456');case _0x1778d8('0x16e7'):return _0x1778d8('0xa52');case _0x1778d8('0x1261'):return _0x1778d8('0x1730');case _0x1778d8('0x23e9'):return'blue-grey-A200-bg';default:return _0x1778d8('0x1b0e');}}_0x50f435[_0x3acc0e('0x26a2')](_0x3acc0e('0x4b8'),function(){const _0x20913b=_0x3acc0e;_0x306041[_0x20913b('0x1b9e')](_0x20913b('0xd92')),_0x306041[_0x20913b('0x1b9e')](_0x20913b('0x2617')),_0x306041['removeAllListeners'](_0x20913b('0x20f3')),_0x306041[_0x20913b('0x1b9e')](_0x20913b('0x621')),_0x306041[_0x20913b('0x1b9e')](_0x20913b('0x1eaf')),_0x306041[_0x20913b('0x1b9e')](_0x20913b('0x165')),_0x306041[_0x20913b('0x1b9e')](_0x20913b('0x21cc')),_0x306041[_0x20913b('0x1b9e')](_0x20913b('0x144d'));});}const _0x4ebea2=_0x30f986;_0x410fe1[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$document','$window',_0x189033('0x1d08'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1556')];function _0x410fe1(_0x331c0d,_0x3413f6,_0xa038a2,_0x145520,_0xe007af,_0x40adbf,_0xf05f80,_0x211dee,_0x548422){const _0x341cc3=_0x189033,_0x4fdab4=this,_0x5da671=['id',_0x341cc3('0x60a'),_0x341cc3('0xe11'),'waiting'];let _0xdba996=!![];_0x4fdab4[_0x341cc3('0xae')]={},_0x4fdab4[_0x341cc3('0x19a6')]=0x0,_0x4fdab4[_0x341cc3('0x1376')]={},_0x4fdab4[_0x341cc3('0x1ea')]=[],_0x4fdab4[_0x341cc3('0x1dcd')]=[],_0x4fdab4[_0x341cc3('0x2082')]={},_0x4fdab4[_0x341cc3('0x23a2')]={'id':_0x211dee['getCurrentUser']()['id'],'channel':_0x341cc3('0x1261'),'fields':_0x341cc3('0x1ae7'),'limit':0xa,'page':0x1},_0x4fdab4[_0x341cc3('0xcd9')]={'limit':0xa,'page':0x1},_0x4fdab4['success']=_0x42134e,_0x4fdab4[_0x341cc3('0x2759')]=_0x6499b4,_0x4fdab4['getSize']=_0x3ea215,_0x4fdab4['getColorByChannel']=_0x26b9d7,_0x4fdab4[_0x341cc3('0x18d1')]=_0x2b179a,_0x4fdab4[_0x341cc3('0x69a')]=_0x5943a0,_0x4fdab4[_0x341cc3('0xe36')]=_0xe2271,_0x4fdab4['onUpdateOpenchannelQueue']=_0x1ee423,_0x4fdab4[_0x341cc3('0xa05')]=_0x4ddce0,_0x4fdab4[_0x341cc3('0x9f')]=_0x4c075d,_0x4fdab4[_0x341cc3('0x25b8')]=_0x4966d6,_0x4fdab4[_0x341cc3('0x18c6')]=_0x39437e,_0x4fdab4['onRemoveOpenchannelQueueChannel']=_0x1a0371,_0x548422[_0x341cc3('0x5a3')]('openchannel_queue:save',_0x4fdab4['onSaveQueue']),_0x548422[_0x341cc3('0x5a3')]('openchannelQueue:save',_0x4fdab4[_0x341cc3('0xe36')]),_0x548422[_0x341cc3('0x5a3')]('openchannelQueue:update',_0x4fdab4[_0x341cc3('0x23fa')]),_0x548422[_0x341cc3('0x5a3')](_0x341cc3('0x402'),_0x4fdab4[_0x341cc3('0xa05')]),_0x548422[_0x341cc3('0x5a3')](_0x341cc3('0x206'),_0x4fdab4[_0x341cc3('0x9f')]),_0x548422[_0x341cc3('0x5a3')](_0x341cc3('0x6fd'),_0x4fdab4[_0x341cc3('0x25b8')]),_0x548422['onWithoutApply'](_0x341cc3('0x343'),_0x4fdab4['onSaveOpenchannelQueueChannel']),_0x548422['onWithoutApply'](_0x341cc3('0x2877'),_0x4fdab4[_0x341cc3('0x279c')]),_0xf05f80[_0x341cc3('0x1b1b')][_0x341cc3('0x2759')]()[_0x341cc3('0xe53')][_0x341cc3('0x683')](function(_0x56d43e){const _0xaf14e2=_0x341cc3;_0x4fdab4['rpcOpenchannelQueues']=_0x56d43e?_0x2e3ca0()['keyBy'](_0x56d43e[_0xaf14e2('0xf5d')]?_0x56d43e[_0xaf14e2('0xf5d')]:[],'id'):{};})['then'](function(){const _0x9bc906=_0x341cc3;return _0xf05f80['user'][_0x9bc906('0x4c9')]({'id':_0x211dee[_0x9bc906('0x20b2')]()['id'],'channel':_0x9bc906('0x1261')})[_0x9bc906('0xe53')];})['then'](function(_0x48576d){const _0x29c4d9=_0x341cc3;return _0x4fdab4[_0x29c4d9('0x9da')]=_0x48576d[_0x29c4d9('0xf5d')],_0xf05f80[_0x29c4d9('0x1b1b')][_0x29c4d9('0x1ac')]()[_0x29c4d9('0xe53')];})[_0x341cc3('0x683')](function(_0x528706){const _0x4ca1d5=_0x341cc3,_0x4a7fde=_0x2e3ca0()['filter'](_0x528706['rows'],function(_0x485fe6){const _0x2cc0f9=a0_0x4e0a;return _0x2e3ca0()[_0x2cc0f9('0x2292')](_0x4fdab4[_0x2cc0f9('0x9da')],{'id':_0x485fe6[_0x2cc0f9('0xbe8')]});});_0x528706[_0x4ca1d5('0xf5d')]=_0x4a7fde,_0x528706[_0x4ca1d5('0x50d')]=_0x4a7fde['length'],_0x2e3ca0()['merge'](_0x4fdab4['rpcOpenchannelQueuesWaitingInteractions'],_0x528706?_0x2e3ca0()[_0x4ca1d5('0x24db')](_0x528706['rows']?_0x528706[_0x4ca1d5('0xf5d')]:[],'id'):{});})['catch'](function(_0x3279f1){const _0x59a7ed=_0x341cc3;console[_0x59a7ed('0x52a')](_0x3279f1);})['finally'](function(){const _0x597bf6=_0x341cc3;for(let _0x549c12=0x0;_0x549c12<_0x4fdab4['deleteOpenchannelQueuesWaitingInteractions'][_0x597bf6('0x1564')];_0x549c12+=0x1){delete _0x4fdab4[_0x597bf6('0x2082')][_0x4fdab4[_0x597bf6('0x1dcd')][_0x549c12]];}_0xdba996=![],_0x4fdab4['deleteOpenchannelQueuesWaitingInteractions']=[],_0x6499b4(),_0x2b179a();});function _0x2b179a(){const _0x287b1e=_0x341cc3,_0x5b5608=(_0x4fdab4[_0x287b1e('0xcd9')]['page']-0x1)*_0x4fdab4[_0x287b1e('0xcd9')]['limit'];_0x4fdab4[_0x287b1e('0x1ea')]=_0x2e3ca0()[_0x287b1e('0x2ef')](_0x4fdab4[_0x287b1e('0x2082')],[_0x287b1e('0x27b1')],[_0x287b1e('0x1f5a')]),_0x4fdab4[_0x287b1e('0x1768')]=_0x2e3ca0()[_0x287b1e('0x16b7')](_0x4fdab4[_0x287b1e('0x1ea')],_0x5b5608)[_0x287b1e('0x12c8')](0x0,_0x4fdab4[_0x287b1e('0xcd9')][_0x287b1e('0x6f0')]);}function _0x42134e(_0xbb9ce1){const _0x38c068=_0x341cc3;_0x4fdab4[_0x38c068('0x19a6')]=_0xbb9ce1[_0x38c068('0x50d')]?_0xbb9ce1['count']:0x0,_0x4fdab4[_0x38c068('0xae')]=_0xbb9ce1?_0x2e3ca0()[_0x38c068('0x24db')](_0xbb9ce1[_0x38c068('0xf5d')]?_0xbb9ce1[_0x38c068('0xf5d')]:[],'id'):{},_0x3826e3();}function _0x6499b4(){const _0x3f38e9=_0x341cc3;_0x4fdab4[_0x3f38e9('0x23a2')][_0x3f38e9('0x1cc8')]=(_0x4fdab4[_0x3f38e9('0x23a2')]['page']-0x1)*_0x4fdab4['query'][_0x3f38e9('0x6f0')],_0x4fdab4[_0x3f38e9('0x1883')]=_0xf05f80['user'][_0x3f38e9('0x4c9')](_0x4fdab4[_0x3f38e9('0x23a2')],_0x42134e)['$promise'];}let _0x1396d9=!![],_0x5e81ab=0x1;_0x331c0d[_0x341cc3('0x186d')]('vm_dc.query.filter',function(_0x20fb34,_0x50f471){const _0x131f36=_0x341cc3;_0x1396d9?_0x3413f6(function(){_0x1396d9=![];}):(!_0x50f471&&(_0x5e81ab=_0x4fdab4[_0x131f36('0x23a2')][_0x131f36('0xdf8')]),_0x20fb34!==_0x50f471&&(_0x4fdab4[_0x131f36('0x23a2')][_0x131f36('0xdf8')]=0x1),!_0x20fb34&&(_0x4fdab4[_0x131f36('0x23a2')][_0x131f36('0xdf8')]=_0x5e81ab),_0x4fdab4[_0x131f36('0x2759')]());});function _0x3ea215(_0x1e0c6e){const _0x296ed9=_0x341cc3;return _0x2e3ca0()[_0x296ed9('0x1a41')](_0x1e0c6e);}function _0x3826e3(){const _0x334714=_0x341cc3;_0x2e3ca0()[_0x334714('0x15d0')](_0x4fdab4[_0x334714('0xae')],function(_0x1277ac,_0x1a4332){const _0x5c39f9=_0x334714;_0x4fdab4[_0x5c39f9('0x1376')][_0x1a4332]&&(_0x4fdab4[_0x5c39f9('0xae')][_0x1a4332][_0x5c39f9('0x1386')]=_0x4fdab4[_0x5c39f9('0x1376')][_0x1a4332]['waiting']||0x0);});}function _0x5943a0(_0x4efc6c){const _0x4d17ec=_0x341cc3;_0x4fdab4[_0x4d17ec('0xae')][_0x4efc6c['id']]&&(_0x4fdab4['rpcOpenchannelQueues'][_0x4efc6c['id']]&&(_0x2e3ca0()[_0x4d17ec('0xf22')](_0x4fdab4[_0x4d17ec('0x1376')][_0x4efc6c['id']],_0x2e3ca0()[_0x4d17ec('0x24d0')](_0x4efc6c,_0x5da671)),_0x2e3ca0()['merge'](_0x4fdab4[_0x4d17ec('0xae')][_0x4efc6c['id']],_0x2e3ca0()[_0x4d17ec('0x24d0')](_0x4efc6c,_0x5da671))));}function _0xe2271(_0x4963f6){const _0x221028=_0x341cc3;!_0x2e3ca0()[_0x221028('0x8f2')](_0x4963f6)&&(_0x4fdab4[_0x221028('0x1376')][_0x4963f6['id']]=_0x2e3ca0()['pick'](_0x4963f6,_0x5da671));}function _0x1ee423(_0x3af11e){const _0x5e0af2=_0x341cc3;!_0x2e3ca0()[_0x5e0af2('0x8f2')](_0x3af11e)&&(_0x4fdab4[_0x5e0af2('0x1376')][_0x3af11e['id']]&&_0x2e3ca0()[_0x5e0af2('0xf22')](_0x4fdab4[_0x5e0af2('0x1376')][_0x3af11e['id']],_0x2e3ca0()[_0x5e0af2('0x24d0')](_0x3af11e,_0x5da671)),_0x4fdab4[_0x5e0af2('0xae')][_0x3af11e['id']]&&_0x2e3ca0()[_0x5e0af2('0xf22')](_0x4fdab4[_0x5e0af2('0xae')][_0x3af11e['id']],_0x2e3ca0()[_0x5e0af2('0x24d0')](_0x3af11e,_0x5da671)));}function _0x4ddce0(_0x3a875b){const _0x4e7226=_0x341cc3;!_0x2e3ca0()[_0x4e7226('0x8f2')](_0x3a875b)&&(delete _0x4fdab4['rpcOpenchannelQueues'][_0x3a875b['id']],delete _0x4fdab4[_0x4e7226('0xae')][_0x3a875b['id']]);}function _0x4c075d(_0x27ccb7){const _0x38f6cf=_0x341cc3;_0x2e3ca0()['toInteger'](_0x27ccb7[_0x38f6cf('0x10c5')])===_0x211dee[_0x38f6cf('0x20b2')]()['id']&&_0x4fdab4[_0x38f6cf('0x2759')]();}function _0x4966d6(_0x3cc19d){const _0x86bae4=_0x341cc3;_0x2e3ca0()['toInteger'](_0x3cc19d['UserId'])===_0x211dee[_0x86bae4('0x20b2')]()['id']&&_0x4fdab4[_0x86bae4('0x2759')]();}function _0x39437e(_0x190a4d){const _0x46f75a=_0x341cc3;_0x4fdab4[_0x46f75a('0xae')][_0x190a4d[_0x46f75a('0xbe8')]]&&(_0x4fdab4[_0x46f75a('0x2082')][_0x190a4d['id']]=_0x190a4d,_0x2b179a());}function _0x1a0371(_0x15c3fc){const _0x57ed02=_0x341cc3;delete _0x4fdab4['rpcOpenchannelQueuesWaitingInteractions'][_0x15c3fc['id']],_0xdba996&&_0x4fdab4[_0x57ed02('0x1dcd')][_0x57ed02('0x1fd0')](_0x15c3fc['id']),_0x2b179a();}function _0x26b9d7(_0x350b84){const _0x5c2c46=_0x341cc3;switch(_0x350b84){case _0x5c2c46('0x24e'):return _0x5c2c46('0xb3c');case _0x5c2c46('0x129f'):return _0x5c2c46('0x2505');case _0x5c2c46('0x1285'):return _0x5c2c46('0x2456');case _0x5c2c46('0x16e7'):return _0x5c2c46('0xa52');case'openchannel':return _0x5c2c46('0x1730');case _0x5c2c46('0x23e9'):return'blue-grey-A200-bg';default:return'white-bg';}}_0x331c0d['$on'](_0x341cc3('0x4b8'),function(){const _0x289f6f=_0x341cc3;_0x548422[_0x289f6f('0x1b9e')](_0x289f6f('0x503')),_0x548422[_0x289f6f('0x1b9e')](_0x289f6f('0x6be')),_0x548422['removeAllListeners'](_0x289f6f('0x7ad')),_0x548422['removeAllListeners'](_0x289f6f('0x402')),_0x548422[_0x289f6f('0x1b9e')](_0x289f6f('0x206')),_0x548422['removeAllListeners']('userOpenchannelQueue:remove'),_0x548422[_0x289f6f('0x1b9e')](_0x289f6f('0x343')),_0x548422[_0x289f6f('0x1b9e')](_0x289f6f('0x2877'));});}const _0x59f289=_0x410fe1;_0x46fec5[_0x189033('0x14be')]=['$scope',_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2063'),_0x189033('0x1d08'),'api',_0x189033('0xba1'),_0x189033('0x1556')];function _0x46fec5(_0x286046,_0x48ef60,_0x5b8b0a,_0x154df9,_0x398f2f,_0x3ee2a8,_0x2ffd6f,_0x13059e,_0x4ab4dc){const _0x2e490f=_0x189033,_0x5aa363=this,_0x24e525=['id',_0x2e490f('0x60a'),_0x2e490f('0xe11'),_0x2e490f('0x1386')];let _0xf308f0=!![];_0x5aa363['smsQueues']={},_0x5aa363[_0x2e490f('0x8c')]=0x0,_0x5aa363[_0x2e490f('0x1a7a')]={},_0x5aa363[_0x2e490f('0x1ea')]=[],_0x5aa363[_0x2e490f('0xd76')]=[],_0x5aa363['rpcSmsQueuesWaitingInteractions']={},_0x5aa363[_0x2e490f('0x23a2')]={'id':_0x13059e[_0x2e490f('0x20b2')]()['id'],'channel':_0x2e490f('0x1285'),'fields':_0x2e490f('0x1ae7'),'limit':0xa,'page':0x1},_0x5aa363['queryChannels']={'limit':0xa,'page':0x1},_0x5aa363['success']=_0x21604b,_0x5aa363[_0x2e490f('0x286f')]=_0x45e017,_0x5aa363['getSize']=_0x161ddd,_0x5aa363[_0x2e490f('0x2590')]=_0x5881f7,_0x5aa363[_0x2e490f('0x18d1')]=_0x1a15af,_0x5aa363['onSaveQueue']=_0x2f0777,_0x5aa363[_0x2e490f('0xe90')]=_0x18d12c,_0x5aa363['onUpdateSmsQueue']=_0x939d15,_0x5aa363[_0x2e490f('0x108d')]=_0x58e1b0,_0x5aa363[_0x2e490f('0x6ec')]=_0x5192ec,_0x5aa363['onRemoveUserSmsQueue']=_0x32fbd7,_0x5aa363[_0x2e490f('0x1e4b')]=_0x44aabb,_0x5aa363[_0x2e490f('0x1e9')]=_0xe351ca,_0x4ab4dc[_0x2e490f('0x5a3')](_0x2e490f('0xde9'),_0x5aa363['onSaveQueue']),_0x4ab4dc['onWithoutApply'](_0x2e490f('0x2534'),_0x5aa363[_0x2e490f('0xe90')]),_0x4ab4dc[_0x2e490f('0x5a3')](_0x2e490f('0x10d3'),_0x5aa363[_0x2e490f('0x91a')]),_0x4ab4dc[_0x2e490f('0x5a3')](_0x2e490f('0x21b8'),_0x5aa363[_0x2e490f('0x108d')]),_0x4ab4dc[_0x2e490f('0x5a3')]('userSmsQueue:save',_0x5aa363[_0x2e490f('0x6ec')]),_0x4ab4dc['onWithoutApply'](_0x2e490f('0x4e7'),_0x5aa363['onRemoveUserSmsQueue']),_0x4ab4dc['onWithoutApply'](_0x2e490f('0x970'),_0x5aa363[_0x2e490f('0x1e4b')]),_0x4ab4dc['onWithoutApply'](_0x2e490f('0x264b'),_0x5aa363[_0x2e490f('0x1e9')]),_0x2ffd6f[_0x2e490f('0x1b1b')][_0x2e490f('0x286f')]()[_0x2e490f('0xe53')]['then'](function(_0x1770de){const _0x27c954=_0x2e490f;_0x5aa363[_0x27c954('0x1a7a')]=_0x1770de?_0x2e3ca0()[_0x27c954('0x24db')](_0x1770de[_0x27c954('0xf5d')]?_0x1770de[_0x27c954('0xf5d')]:[],'id'):{};})[_0x2e490f('0x683')](function(){const _0xeb487d=_0x2e490f;return _0x2ffd6f[_0xeb487d('0xc96')]['getQueues']({'id':_0x13059e[_0xeb487d('0x20b2')]()['id'],'channel':'sms'})['$promise'];})[_0x2e490f('0x683')](function(_0x38bd77){const _0x48f4f3=_0x2e490f;return _0x5aa363[_0x48f4f3('0x9da')]=_0x38bd77[_0x48f4f3('0xf5d')],_0x2ffd6f[_0x48f4f3('0x1b1b')][_0x48f4f3('0x251')]()['$promise'];})[_0x2e490f('0x683')](function(_0x39c63b){const _0x5ef85f=_0x2e490f,_0x17225c=_0x2e3ca0()[_0x5ef85f('0x25')](_0x39c63b[_0x5ef85f('0xf5d')],function(_0x3a4a95){const _0xe9c872=_0x5ef85f;return _0x2e3ca0()[_0xe9c872('0x2292')](_0x5aa363[_0xe9c872('0x9da')],{'id':_0x3a4a95[_0xe9c872('0xbe8')]});});_0x39c63b[_0x5ef85f('0xf5d')]=_0x17225c,_0x39c63b[_0x5ef85f('0x50d')]=_0x17225c[_0x5ef85f('0x1564')],_0x2e3ca0()[_0x5ef85f('0xf22')](_0x5aa363[_0x5ef85f('0x7eb')],_0x39c63b?_0x2e3ca0()[_0x5ef85f('0x24db')](_0x39c63b[_0x5ef85f('0xf5d')]?_0x39c63b[_0x5ef85f('0xf5d')]:[],'id'):{});})[_0x2e490f('0x130a')](function(_0x2d7677){const _0x144ac3=_0x2e490f;console[_0x144ac3('0x52a')](_0x2d7677);})[_0x2e490f('0x2874')](function(){const _0x209170=_0x2e490f;for(let _0x173af8=0x0;_0x173af8<_0x5aa363[_0x209170('0xd76')][_0x209170('0x1564')];_0x173af8+=0x1){delete _0x5aa363[_0x209170('0x7eb')][_0x5aa363['deleteSmsQueuesWaitingInteractions'][_0x173af8]];}_0xf308f0=![],_0x5aa363['deleteSmsQueuesWaitingInteractions']=[],_0x45e017(),_0x1a15af();});function _0x1a15af(){const _0x2f5300=_0x2e490f,_0x27fd26=(_0x5aa363['queryChannels']['page']-0x1)*_0x5aa363['queryChannels'][_0x2f5300('0x6f0')];_0x5aa363[_0x2f5300('0x1ea')]=_0x2e3ca0()[_0x2f5300('0x2ef')](_0x5aa363[_0x2f5300('0x7eb')],[_0x2f5300('0x27b1')],[_0x2f5300('0x1f5a')]),_0x5aa363[_0x2f5300('0x1768')]=_0x2e3ca0()[_0x2f5300('0x16b7')](_0x5aa363['paginatedInteractions'],_0x27fd26)[_0x2f5300('0x12c8')](0x0,_0x5aa363['queryChannels'][_0x2f5300('0x6f0')]);}function _0x21604b(_0x197e63){const _0x326366=_0x2e490f;_0x5aa363[_0x326366('0x8c')]=_0x197e63['count']?_0x197e63['count']:0x0,_0x5aa363[_0x326366('0xdf3')]=_0x197e63?_0x2e3ca0()[_0x326366('0x24db')](_0x197e63[_0x326366('0xf5d')]?_0x197e63[_0x326366('0xf5d')]:[],'id'):{},_0x3eae56();}function _0x45e017(){const _0xe20ae0=_0x2e490f;_0x5aa363[_0xe20ae0('0x23a2')]['offset']=(_0x5aa363[_0xe20ae0('0x23a2')][_0xe20ae0('0xdf8')]-0x1)*_0x5aa363['query'][_0xe20ae0('0x6f0')],_0x5aa363[_0xe20ae0('0x1883')]=_0x2ffd6f[_0xe20ae0('0xc96')]['getQueues'](_0x5aa363[_0xe20ae0('0x23a2')],_0x21604b)['$promise'];}let _0x36233b=!![],_0x64368a=0x1;_0x286046[_0x2e490f('0x186d')](_0x2e490f('0x229'),function(_0x3f40f2,_0x7c58a6){const _0x5ccc38=_0x2e490f;_0x36233b?_0x48ef60(function(){_0x36233b=![];}):(!_0x7c58a6&&(_0x64368a=_0x5aa363[_0x5ccc38('0x23a2')][_0x5ccc38('0xdf8')]),_0x3f40f2!==_0x7c58a6&&(_0x5aa363[_0x5ccc38('0x23a2')][_0x5ccc38('0xdf8')]=0x1),!_0x3f40f2&&(_0x5aa363[_0x5ccc38('0x23a2')][_0x5ccc38('0xdf8')]=_0x64368a),_0x5aa363[_0x5ccc38('0x286f')]());});function _0x161ddd(_0x1137e6){const _0x253d8a=_0x2e490f;return _0x2e3ca0()[_0x253d8a('0x1a41')](_0x1137e6);}function _0x3eae56(){_0x2e3ca0()['forIn'](_0x5aa363['smsQueues'],function(_0x299d60,_0x55435e){const _0x34994e=a0_0x4e0a;_0x5aa363[_0x34994e('0x1a7a')][_0x55435e]&&(_0x5aa363[_0x34994e('0xdf3')][_0x55435e]['waiting']=_0x5aa363[_0x34994e('0x1a7a')][_0x55435e]['waiting']||0x0);});}function _0x2f0777(_0x3d8350){const _0x1c409f=_0x2e490f;_0x5aa363['smsQueues'][_0x3d8350['id']]&&(_0x5aa363[_0x1c409f('0x1a7a')][_0x3d8350['id']]&&(_0x2e3ca0()[_0x1c409f('0xf22')](_0x5aa363['rpcSmsQueues'][_0x3d8350['id']],_0x2e3ca0()[_0x1c409f('0x24d0')](_0x3d8350,_0x24e525)),_0x2e3ca0()[_0x1c409f('0xf22')](_0x5aa363[_0x1c409f('0xdf3')][_0x3d8350['id']],_0x2e3ca0()['pick'](_0x3d8350,_0x24e525))));}function _0x18d12c(_0x4a72c2){const _0x39c23b=_0x2e490f;!_0x2e3ca0()[_0x39c23b('0x8f2')](_0x4a72c2)&&(_0x5aa363[_0x39c23b('0x1a7a')][_0x4a72c2['id']]=_0x2e3ca0()[_0x39c23b('0x24d0')](_0x4a72c2,_0x24e525));}function _0x939d15(_0x1ae4ae){const _0x482f30=_0x2e490f;!_0x2e3ca0()[_0x482f30('0x8f2')](_0x1ae4ae)&&(_0x5aa363[_0x482f30('0x1a7a')][_0x1ae4ae['id']]&&_0x2e3ca0()[_0x482f30('0xf22')](_0x5aa363[_0x482f30('0x1a7a')][_0x1ae4ae['id']],_0x2e3ca0()[_0x482f30('0x24d0')](_0x1ae4ae,_0x24e525)),_0x5aa363[_0x482f30('0xdf3')][_0x1ae4ae['id']]&&_0x2e3ca0()[_0x482f30('0xf22')](_0x5aa363[_0x482f30('0xdf3')][_0x1ae4ae['id']],_0x2e3ca0()[_0x482f30('0x24d0')](_0x1ae4ae,_0x24e525)));}function _0x58e1b0(_0x1a5dd9){const _0x4532b5=_0x2e490f;!_0x2e3ca0()[_0x4532b5('0x8f2')](_0x1a5dd9)&&(delete _0x5aa363['rpcSmsQueues'][_0x1a5dd9['id']],delete _0x5aa363['smsQueues'][_0x1a5dd9['id']]);}function _0x5192ec(_0xcb01e7){const _0x3bc081=_0x2e490f;_0x2e3ca0()['toInteger'](_0xcb01e7[_0x3bc081('0x10c5')])===_0x13059e[_0x3bc081('0x20b2')]()['id']&&_0x5aa363[_0x3bc081('0x286f')]();}function _0x32fbd7(_0x5972d9){const _0x219531=_0x2e490f;_0x2e3ca0()[_0x219531('0xc77')](_0x5972d9['UserId'])===_0x13059e[_0x219531('0x20b2')]()['id']&&_0x5aa363[_0x219531('0x286f')]();}function _0x44aabb(_0x5efbbd){const _0x28d936=_0x2e490f;_0x5aa363[_0x28d936('0xdf3')][_0x5efbbd[_0x28d936('0xbe8')]]&&(_0x5aa363[_0x28d936('0x7eb')][_0x5efbbd['id']]=_0x5efbbd,_0x1a15af());}function _0xe351ca(_0x4f6539){const _0x5aeef3=_0x2e490f;delete _0x5aa363['rpcSmsQueuesWaitingInteractions'][_0x4f6539['id']],_0xf308f0&&_0x5aa363[_0x5aeef3('0xd76')][_0x5aeef3('0x1fd0')](_0x4f6539['id']),_0x1a15af();}function _0x5881f7(_0xe9452){const _0x5d4267=_0x2e490f;switch(_0xe9452){case _0x5d4267('0x24e'):return _0x5d4267('0xb3c');case _0x5d4267('0x129f'):return _0x5d4267('0x2505');case _0x5d4267('0x1285'):return _0x5d4267('0x2456');case _0x5d4267('0x16e7'):return _0x5d4267('0xa52');case'openchannel':return _0x5d4267('0x1730');case _0x5d4267('0x23e9'):return'blue-grey-A200-bg';default:return'white-bg';}}_0x286046[_0x2e490f('0x26a2')](_0x2e490f('0x4b8'),function(){const _0x55c51a=_0x2e490f;_0x4ab4dc[_0x55c51a('0x1b9e')](_0x55c51a('0xde9')),_0x4ab4dc[_0x55c51a('0x1b9e')]('smsQueue:save'),_0x4ab4dc['removeAllListeners']('smsQueue:update'),_0x4ab4dc[_0x55c51a('0x1b9e')](_0x55c51a('0x21b8')),_0x4ab4dc[_0x55c51a('0x1b9e')]('userSmsQueue:save'),_0x4ab4dc[_0x55c51a('0x1b9e')](_0x55c51a('0x4e7')),_0x4ab4dc[_0x55c51a('0x1b9e')](_0x55c51a('0x970')),_0x4ab4dc['removeAllListeners'](_0x55c51a('0x264b'));});}const _0xdca5be=_0x46fec5;_0x53cbda[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2063'),_0x189033('0x1d08'),'api',_0x189033('0xba1'),_0x189033('0x1556')];function _0x53cbda(_0x42b765,_0x325d22,_0x45875f,_0x1c5a3b,_0x43d68a,_0x367fa1,_0x41f6d7,_0xf34450,_0x1f4181){const _0x14d056=_0x189033,_0x23c98a=this,_0x469046=['type',_0x14d056('0x1386'),_0x14d056('0x1091'),'dialActive'];_0x23c98a[_0x14d056('0x426')]={},_0x23c98a[_0x14d056('0x10b2')]=0x0,_0x23c98a['rpcVoiceQueues']={},_0x23c98a[_0x14d056('0x1713')]={},_0x23c98a['rpcVoiceQueuesChannels']={},_0x23c98a[_0x14d056('0xb98')]={},_0x23c98a[_0x14d056('0x1ea3')]=[],_0x23c98a[_0x14d056('0x182c')]=!![],_0x23c98a[_0x14d056('0x23a2')]={'id':_0xf34450[_0x14d056('0x20b2')]()['id'],'fields':_0x14d056('0xdb1'),'channel':_0x14d056('0xcf2'),'type':_0x14d056('0x1535'),'limit':0xa,'page':0x1},_0x23c98a[_0x14d056('0xcd9')]={'limit':0xa,'page':0x1},_0x23c98a[_0x14d056('0x53')]=_0x2a020e,_0x23c98a[_0x14d056('0x1713')]=_0x5459bd,_0x23c98a['getSize']=_0x410ee7,_0x23c98a[_0x14d056('0x69a')]=_0x3f2968,_0x23c98a['onSaveChannel']=_0x61ac75,_0x23c98a[_0x14d056('0x1366')]=_0x3db528,_0x23c98a['onSaveVoiceQueue']=_0x310b50,_0x23c98a['onUpdateVoiceQueue']=_0x1313e4,_0x23c98a['onRemoveVoiceQueue']=_0x50de5a,_0x1f4181['onWithoutApply']('voice_queue:save',_0x23c98a[_0x14d056('0x69a')]),_0x1f4181[_0x14d056('0x5a3')](_0x14d056('0x99f'),_0x23c98a[_0x14d056('0x740')]),_0x1f4181[_0x14d056('0x5a3')](_0x14d056('0x217c'),_0x23c98a[_0x14d056('0x1366')]),_0x1f4181[_0x14d056('0x5a3')](_0x14d056('0x56f'),_0x23c98a[_0x14d056('0x1366')]),_0x1f4181[_0x14d056('0x5a3')](_0x14d056('0x240f'),_0x23c98a['onSaveVoiceQueue']),_0x1f4181['onWithoutApply'](_0x14d056('0xfb0'),_0x23c98a[_0x14d056('0x186e')]),_0x1f4181['onWithoutApply']('voiceQueue:update',_0x23c98a[_0x14d056('0x1054')]),_0x41f6d7['user'][_0x14d056('0x4c9')](_0x23c98a[_0x14d056('0x23a2')])[_0x14d056('0xe53')][_0x14d056('0x683')](function(_0x4f8a0d){const _0x242922=_0x14d056;return _0x23c98a[_0x242922('0x9da')]=_0x4f8a0d,_0x41f6d7[_0x242922('0x1b1b')]['getVoiceQueues']()['$promise'];})[_0x14d056('0x683')](function(_0x2dda97){const _0x13eca3=_0x14d056,_0x21a8df=_0x2dda97[_0x13eca3('0xf5d')],_0x3f7ecc=_0x2e3ca0()['keyBy'](_0x21a8df,'id');for(let _0x356dfa=0x0;_0x356dfa<_0x23c98a[_0x13eca3('0x9da')][_0x13eca3('0x50d')];_0x356dfa++){const _0x25bf6f=_0x23c98a[_0x13eca3('0x9da')][_0x13eca3('0xf5d')][_0x356dfa];_0x23c98a[_0x13eca3('0x12cf')][_0x25bf6f['id']]=_0x3f7ecc[_0x25bf6f['id']];}return _0x41f6d7[_0x13eca3('0x1b1b')][_0x13eca3('0x623')]()[_0x13eca3('0xe53')];})['then'](function(_0x3c20f0){const _0x195223=_0x14d056;_0x23c98a[_0x195223('0x203c')]=_0x3c20f0?_0x2e3ca0()[_0x195223('0x24db')](_0x3c20f0[_0x195223('0xf5d')]?_0x2e3ca0()[_0x195223('0x25')](_0x3c20f0[_0x195223('0xf5d')],function(_0x2d695d){const _0x13dd48=_0x195223;if(_0x2d695d[_0x13dd48('0xcf0')]===_0x13dd48('0x1535')&&!_0x2d695d[_0x13dd48('0x2324')]&&_0x2e3ca0()[_0x13dd48('0x1c07')](_0x23c98a[_0x13dd48('0x9da')]['rows'],{'name':_0x2d695d['queue']}))return!![];return![];}):[],_0x195223('0x573')):{};})[_0x14d056('0x130a')](function(_0x1975d9){console['error'](_0x1975d9);})[_0x14d056('0x2874')](function(){const _0x2afbad=_0x14d056;_0x2e3ca0()[_0x2afbad('0xf22')](_0x23c98a['rpcVoiceQueuesChannels'],_0x23c98a['addVoiceQueuesChannels']);for(let _0x28646d=0x0;_0x28646d<_0x23c98a[_0x2afbad('0x1ea3')][_0x2afbad('0x1564')];_0x28646d+=0x1){delete _0x23c98a[_0x2afbad('0x203c')][_0x23c98a[_0x2afbad('0x1ea3')][_0x28646d]];}_0x23c98a[_0x2afbad('0x182c')]=![],_0x23c98a[_0x2afbad('0xb98')]={},_0x23c98a[_0x2afbad('0x1ea3')]=[],_0x23c98a['getVoiceQueues']();});function _0x2a020e(_0x53a860){const _0x6d8a07=_0x14d056;_0x23c98a['voiceQueuesTotal']=_0x53a860[_0x6d8a07('0x50d')]?_0x53a860[_0x6d8a07('0x50d')]:0x0,_0x23c98a[_0x6d8a07('0x426')]=_0x53a860?_0x2e3ca0()[_0x6d8a07('0x24db')](_0x53a860[_0x6d8a07('0xf5d')]?_0x53a860['rows']:[],'id'):{},_0x178fa7();}function _0x5459bd(){const _0xa5bc6=_0x14d056;_0x23c98a['query'][_0xa5bc6('0x1cc8')]=(_0x23c98a[_0xa5bc6('0x23a2')][_0xa5bc6('0xdf8')]-0x1)*_0x23c98a[_0xa5bc6('0x23a2')][_0xa5bc6('0x6f0')],_0x23c98a[_0xa5bc6('0x1883')]=_0x41f6d7['user'][_0xa5bc6('0x4c9')](_0x23c98a[_0xa5bc6('0x23a2')],_0x2a020e)[_0xa5bc6('0xe53')];}let _0x1fd832=!![],_0x1e8985=0x1;_0x42b765[_0x14d056('0x186d')]('vm_dc.query.filter',function(_0x182546,_0x30acff){const _0xe6fa5f=_0x14d056;_0x1fd832?_0x325d22(function(){_0x1fd832=![];}):(!_0x30acff&&(_0x1e8985=_0x23c98a['query']['page']),_0x182546!==_0x30acff&&(_0x23c98a[_0xe6fa5f('0x23a2')][_0xe6fa5f('0xdf8')]=0x1),!_0x182546&&(_0x23c98a[_0xe6fa5f('0x23a2')][_0xe6fa5f('0xdf8')]=_0x1e8985),_0x23c98a[_0xe6fa5f('0x1713')]());});function _0x410ee7(_0x3017b4){return _0x2e3ca0()['size'](_0x3017b4);}function _0x178fa7(){const _0x52bfa1=_0x14d056;_0x2e3ca0()[_0x52bfa1('0x15d0')](_0x23c98a[_0x52bfa1('0x426')],function(_0x3c7e33,_0x2c4330){const _0x41c8c9=_0x52bfa1;_0x23c98a['rpcVoiceQueues'][_0x2c4330]&&(_0x23c98a[_0x41c8c9('0x426')][_0x2c4330][_0x41c8c9('0x1386')]=_0x23c98a[_0x41c8c9('0x12cf')][_0x2c4330][_0x41c8c9('0x1386')]||0x0);});}function _0x3f2968(_0x1de6f2){const _0x2b9887=_0x14d056;_0x23c98a['voiceQueues'][_0x1de6f2['id']]&&(_0x23c98a[_0x2b9887('0x12cf')][_0x1de6f2['id']]&&(_0x23c98a['rpcVoiceQueues'][_0x1de6f2['id']]=_0x1de6f2,_0x2e3ca0()[_0x2b9887('0xf22')](_0x23c98a[_0x2b9887('0x426')][_0x1de6f2['id']],_0x2e3ca0()['pick'](_0x1de6f2,_0x469046))));}function _0x61ac75(_0xe37bf0){const _0x3eea17=_0x14d056;_0xe37bf0[_0x3eea17('0xcf0')]===_0x3eea17('0x1535')&&(_0xe37bf0['queuecallerleaveAt']?(delete _0x23c98a[_0x3eea17('0x203c')][_0xe37bf0[_0x3eea17('0x573')]],_0x23c98a[_0x3eea17('0x182c')]&&_0x23c98a[_0x3eea17('0x1ea3')][_0x3eea17('0x1fd0')](_0xe37bf0[_0x3eea17('0x573')])):(_0x23c98a['rpcVoiceQueuesChannels'][_0xe37bf0[_0x3eea17('0x573')]]=_0xe37bf0,_0x23c98a['load']&&(_0x23c98a[_0x3eea17('0xb98')][_0xe37bf0[_0x3eea17('0x573')]]=_0xe37bf0)));}function _0x310b50(_0x23a37a){const _0x5ad4fa=_0x14d056;!_0x2e3ca0()[_0x5ad4fa('0x8f2')](_0x23a37a)&&(_0x23c98a[_0x5ad4fa('0x12cf')][_0x23a37a['id']]=_0x2e3ca0()[_0x5ad4fa('0x24d0')](_0x23a37a,_0x469046));}function _0x1313e4(_0x3c3b31){const _0x557ebc=_0x14d056;!_0x2e3ca0()[_0x557ebc('0x8f2')](_0x3c3b31)&&(_0x23c98a['rpcVoiceQueues'][_0x3c3b31['id']]&&_0x2e3ca0()[_0x557ebc('0xf22')](_0x23c98a[_0x557ebc('0x12cf')][_0x3c3b31['id']],_0x2e3ca0()[_0x557ebc('0x24d0')](_0x3c3b31,_0x469046)),_0x23c98a['voiceQueues'][_0x3c3b31['id']]&&_0x2e3ca0()[_0x557ebc('0xf22')](_0x23c98a['voiceQueues'][_0x3c3b31['id']],_0x2e3ca0()[_0x557ebc('0x24d0')](_0x3c3b31,_0x469046)));}function _0x50de5a(_0x163d90){const _0x114ef5=_0x14d056;!_0x2e3ca0()['isNil'](_0x163d90)&&(delete _0x23c98a[_0x114ef5('0x12cf')][_0x163d90['id']],delete _0x23c98a[_0x114ef5('0x426')][_0x163d90['id']]);}function _0x3db528(_0x4f058b){const _0x2740dc=_0x14d056;_0x2e3ca0()['toInteger'](_0x4f058b[_0x2740dc('0x10c5')])===_0xf34450[_0x2740dc('0x20b2')]()['id']&&_0x23c98a['getVoiceQueues']();}_0x42b765[_0x14d056('0x26a2')]('$destroy',function(){const _0x57736b=_0x14d056;_0x1f4181['removeAllListeners']('voice_queue:save'),_0x1f4181[_0x57736b('0x1b9e')](_0x57736b('0x99f')),_0x1f4181[_0x57736b('0x1b9e')](_0x57736b('0x217c')),_0x1f4181[_0x57736b('0x1b9e')]('userVoiceQueue:remove'),_0x1f4181[_0x57736b('0x1b9e')](_0x57736b('0x240f')),_0x1f4181[_0x57736b('0x1b9e')](_0x57736b('0x779')),_0x1f4181[_0x57736b('0x1b9e')](_0x57736b('0xfb0'));});}const _0x516397=_0x53cbda;_0x1676d2[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$document',_0x189033('0x2063'),_0x189033('0x1d08'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1556')];function _0x1676d2(_0x10ef92,_0x7f443a,_0x41f028,_0x595906,_0x5a2693,_0x4cbf43,_0x556eb6,_0x2feffe,_0x5d262b){const _0x426f66=_0x189033,_0x385f25=this,_0x46c906=['id',_0x426f66('0x60a'),'mapAgentsId',_0x426f66('0x1386')];let _0x2c0d95=!![];_0x385f25[_0x426f66('0xa4f')]={},_0x385f25[_0x426f66('0x1cfc')]=0x0,_0x385f25[_0x426f66('0x119')]={},_0x385f25['paginatedInteractions']=[],_0x385f25[_0x426f66('0x1d2b')]=[],_0x385f25[_0x426f66('0x4b6')]={},_0x385f25[_0x426f66('0x23a2')]={'id':_0x2feffe['getCurrentUser']()['id'],'channel':_0x426f66('0x16e7'),'fields':_0x426f66('0x1ae7'),'limit':0xa,'page':0x1},_0x385f25[_0x426f66('0xcd9')]={'limit':0xa,'page':0x1},_0x385f25[_0x426f66('0x53')]=_0x31001a,_0x385f25[_0x426f66('0x2676')]=_0x1c6862,_0x385f25[_0x426f66('0x2487')]=_0x58779d,_0x385f25[_0x426f66('0x2590')]=_0x5e7d4b,_0x385f25[_0x426f66('0x18d1')]=_0x32d49a,_0x385f25[_0x426f66('0x69a')]=_0x3d9f71,_0x385f25[_0x426f66('0x127f')]=_0x4fc073,_0x385f25[_0x426f66('0x18ca')]=_0x3c95e5,_0x385f25['onRemoveWhatsappQueue']=_0x3f22d8,_0x385f25[_0x426f66('0x12d0')]=_0x558c46,_0x385f25[_0x426f66('0x148b')]=_0x3c1861,_0x385f25[_0x426f66('0x9df')]=_0x246b42,_0x385f25['onRemoveWhatsappQueueChannel']=_0x3f1b3f,_0x5d262b[_0x426f66('0x5a3')](_0x426f66('0x971'),_0x385f25[_0x426f66('0x69a')]),_0x5d262b[_0x426f66('0x5a3')](_0x426f66('0x1d05'),_0x385f25[_0x426f66('0x127f')]),_0x5d262b[_0x426f66('0x5a3')](_0x426f66('0x7e8'),_0x385f25['onUpdateWhatsappQueue']),_0x5d262b['onWithoutApply']('whatsappQueue:remove',_0x385f25[_0x426f66('0x1c8a')]),_0x5d262b['onWithoutApply'](_0x426f66('0xcbf'),_0x385f25[_0x426f66('0x12d0')]),_0x5d262b[_0x426f66('0x5a3')](_0x426f66('0x15b'),_0x385f25[_0x426f66('0x148b')]),_0x5d262b['onWithoutApply'](_0x426f66('0x8a2'),_0x385f25[_0x426f66('0x9df')]),_0x5d262b[_0x426f66('0x5a3')]('whatsapp_queue_waiting_interaction:remove',_0x385f25[_0x426f66('0x2613')]),_0x556eb6[_0x426f66('0x1b1b')]['getWhatsappQueues']()[_0x426f66('0xe53')]['then'](function(_0x215f8f){const _0xcda767=_0x426f66;_0x385f25[_0xcda767('0x119')]=_0x215f8f?_0x2e3ca0()[_0xcda767('0x24db')](_0x215f8f[_0xcda767('0xf5d')]?_0x215f8f['rows']:[],'id'):{};})['then'](function(){const _0x534505=_0x426f66;return _0x556eb6[_0x534505('0xc96')][_0x534505('0x4c9')]({'id':_0x2feffe[_0x534505('0x20b2')]()['id'],'channel':_0x534505('0x16e7')})['$promise'];})[_0x426f66('0x683')](function(_0x1325fe){const _0x15dd70=_0x426f66;return _0x385f25[_0x15dd70('0x9da')]=_0x1325fe[_0x15dd70('0xf5d')],_0x556eb6[_0x15dd70('0x1b1b')][_0x15dd70('0x1775')]()[_0x15dd70('0xe53')];})[_0x426f66('0x683')](function(_0x61aaa3){const _0x5459db=_0x426f66,_0x580554=_0x2e3ca0()[_0x5459db('0x25')](_0x61aaa3['rows'],function(_0x4bd5ee){const _0xa49131=_0x5459db;return _0x2e3ca0()['includes'](_0x385f25[_0xa49131('0x9da')],{'id':_0x4bd5ee[_0xa49131('0xbe8')]});});_0x61aaa3[_0x5459db('0xf5d')]=_0x580554,_0x61aaa3[_0x5459db('0x50d')]=_0x580554[_0x5459db('0x1564')],_0x2e3ca0()[_0x5459db('0xf22')](_0x385f25[_0x5459db('0x4b6')],_0x61aaa3?_0x2e3ca0()['keyBy'](_0x61aaa3[_0x5459db('0xf5d')]?_0x61aaa3[_0x5459db('0xf5d')]:[],'id'):{});})[_0x426f66('0x130a')](function(_0x1f6cc3){const _0x1d5577=_0x426f66;console[_0x1d5577('0x52a')](_0x1f6cc3);})[_0x426f66('0x2874')](function(){const _0x5305b7=_0x426f66;for(let _0x4872be=0x0;_0x4872be<_0x385f25[_0x5305b7('0x1d2b')]['length'];_0x4872be+=0x1){delete _0x385f25[_0x5305b7('0x4b6')][_0x385f25[_0x5305b7('0x1d2b')][_0x4872be]];}_0x2c0d95=![],_0x385f25[_0x5305b7('0x1d2b')]=[],_0x1c6862(),_0x32d49a();});function _0x32d49a(){const _0x2d37e5=_0x426f66,_0x58b2c0=(_0x385f25['queryChannels']['page']-0x1)*_0x385f25[_0x2d37e5('0xcd9')]['limit'];_0x385f25[_0x2d37e5('0x1ea')]=_0x2e3ca0()['orderBy'](_0x385f25[_0x2d37e5('0x4b6')],['joinAt'],[_0x2d37e5('0x1f5a')]),_0x385f25[_0x2d37e5('0x1768')]=_0x2e3ca0()[_0x2d37e5('0x16b7')](_0x385f25[_0x2d37e5('0x1ea')],_0x58b2c0)[_0x2d37e5('0x12c8')](0x0,_0x385f25[_0x2d37e5('0xcd9')][_0x2d37e5('0x6f0')]);}function _0x31001a(_0x4a9aa6){const _0x127b32=_0x426f66;_0x385f25[_0x127b32('0x1cfc')]=_0x4a9aa6[_0x127b32('0x50d')]?_0x4a9aa6['count']:0x0,_0x385f25[_0x127b32('0xa4f')]=_0x4a9aa6?_0x2e3ca0()[_0x127b32('0x24db')](_0x4a9aa6['rows']?_0x4a9aa6['rows']:[],'id'):{},_0x45ade7();}function _0x1c6862(){const _0xfa6d7e=_0x426f66;_0x385f25[_0xfa6d7e('0x23a2')]['offset']=(_0x385f25[_0xfa6d7e('0x23a2')][_0xfa6d7e('0xdf8')]-0x1)*_0x385f25[_0xfa6d7e('0x23a2')][_0xfa6d7e('0x6f0')],_0x385f25[_0xfa6d7e('0x1883')]=_0x556eb6[_0xfa6d7e('0xc96')]['getQueues'](_0x385f25[_0xfa6d7e('0x23a2')],_0x31001a)[_0xfa6d7e('0xe53')];}let _0x14259b=!![],_0x47d8f0=0x1;_0x10ef92[_0x426f66('0x186d')](_0x426f66('0x229'),function(_0x39bb80,_0x9d7c90){const _0x3d63d8=_0x426f66;_0x14259b?_0x7f443a(function(){_0x14259b=![];}):(!_0x9d7c90&&(_0x47d8f0=_0x385f25[_0x3d63d8('0x23a2')][_0x3d63d8('0xdf8')]),_0x39bb80!==_0x9d7c90&&(_0x385f25[_0x3d63d8('0x23a2')][_0x3d63d8('0xdf8')]=0x1),!_0x39bb80&&(_0x385f25[_0x3d63d8('0x23a2')][_0x3d63d8('0xdf8')]=_0x47d8f0),_0x385f25[_0x3d63d8('0x2676')]());});function _0x58779d(_0x15dc64){const _0x370bc5=_0x426f66;return _0x2e3ca0()[_0x370bc5('0x1a41')](_0x15dc64);}function _0x45ade7(){const _0x39207f=_0x426f66;_0x2e3ca0()['forIn'](_0x385f25[_0x39207f('0xa4f')],function(_0x1a0c92,_0x3eaf20){const _0x2b5f5c=_0x39207f;_0x385f25['rpcWhatsappQueues'][_0x3eaf20]&&(_0x385f25[_0x2b5f5c('0xa4f')][_0x3eaf20][_0x2b5f5c('0x1386')]=_0x385f25['rpcWhatsappQueues'][_0x3eaf20][_0x2b5f5c('0x1386')]||0x0);});}function _0x3d9f71(_0x43750d){const _0x4300b6=_0x426f66;_0x385f25[_0x4300b6('0xa4f')][_0x43750d['id']]&&(_0x385f25[_0x4300b6('0x119')][_0x43750d['id']]&&(_0x2e3ca0()['merge'](_0x385f25[_0x4300b6('0x119')][_0x43750d['id']],_0x2e3ca0()[_0x4300b6('0x24d0')](_0x43750d,_0x46c906)),_0x2e3ca0()[_0x4300b6('0xf22')](_0x385f25[_0x4300b6('0xa4f')][_0x43750d['id']],_0x2e3ca0()[_0x4300b6('0x24d0')](_0x43750d,_0x46c906))));}function _0x4fc073(_0xb7f56f){const _0x2690bf=_0x426f66;!_0x2e3ca0()['isNil'](_0xb7f56f)&&(_0x385f25[_0x2690bf('0x119')][_0xb7f56f['id']]=_0x2e3ca0()[_0x2690bf('0x24d0')](_0xb7f56f,_0x46c906));}function _0x3c95e5(_0x13e0ea){const _0x2e55cf=_0x426f66;!_0x2e3ca0()[_0x2e55cf('0x8f2')](_0x13e0ea)&&(_0x385f25[_0x2e55cf('0x119')][_0x13e0ea['id']]&&_0x2e3ca0()['merge'](_0x385f25['rpcWhatsappQueues'][_0x13e0ea['id']],_0x2e3ca0()[_0x2e55cf('0x24d0')](_0x13e0ea,_0x46c906)),_0x385f25[_0x2e55cf('0xa4f')][_0x13e0ea['id']]&&_0x2e3ca0()[_0x2e55cf('0xf22')](_0x385f25[_0x2e55cf('0xa4f')][_0x13e0ea['id']],_0x2e3ca0()[_0x2e55cf('0x24d0')](_0x13e0ea,_0x46c906)));}function _0x3f22d8(_0x4ffbaf){const _0x4ea1a2=_0x426f66;!_0x2e3ca0()[_0x4ea1a2('0x8f2')](_0x4ffbaf)&&(delete _0x385f25[_0x4ea1a2('0x119')][_0x4ffbaf['id']],delete _0x385f25[_0x4ea1a2('0xa4f')][_0x4ffbaf['id']]);}function _0x558c46(_0x292942){const _0x429aa2=_0x426f66;_0x2e3ca0()[_0x429aa2('0xc77')](_0x292942['UserId'])===_0x2feffe[_0x429aa2('0x20b2')]()['id']&&_0x385f25[_0x429aa2('0x2676')]();}function _0x3c1861(_0xafe3d3){const _0x2b3f2e=_0x426f66;_0x2e3ca0()[_0x2b3f2e('0xc77')](_0xafe3d3['UserId'])===_0x2feffe[_0x2b3f2e('0x20b2')]()['id']&&_0x385f25[_0x2b3f2e('0x2676')]();}function _0x246b42(_0x43d550){const _0x25c046=_0x426f66;_0x385f25['whatsappQueues'][_0x43d550[_0x25c046('0xbe8')]]&&(_0x385f25['rpcWhatsappQueuesWaitingInteractions'][_0x43d550['id']]=_0x43d550,_0x32d49a());}function _0x3f1b3f(_0x3b3351){const _0xc90974=_0x426f66;delete _0x385f25['rpcWhatsappQueuesWaitingInteractions'][_0x3b3351['id']],_0x2c0d95&&_0x385f25['deleteWhatsappQueuesWaitingInteractions'][_0xc90974('0x1fd0')](_0x3b3351['id']),_0x32d49a();}function _0x5e7d4b(_0x3cd8f3){const _0x3804e9=_0x426f66;switch(_0x3cd8f3){case _0x3804e9('0x24e'):return _0x3804e9('0xb3c');case _0x3804e9('0x129f'):return _0x3804e9('0x2505');case _0x3804e9('0x1285'):return _0x3804e9('0x2456');case _0x3804e9('0x16e7'):return'lime-A700-bg';case _0x3804e9('0x1261'):return _0x3804e9('0x1730');case _0x3804e9('0x23e9'):return'blue-grey-A200-bg';default:return _0x3804e9('0x1b0e');}}_0x10ef92['$on'](_0x426f66('0x4b8'),function(){const _0x548fed=_0x426f66;_0x5d262b[_0x548fed('0x1b9e')](_0x548fed('0x971')),_0x5d262b[_0x548fed('0x1b9e')]('whatsappQueue:save'),_0x5d262b['removeAllListeners'](_0x548fed('0x7e8')),_0x5d262b[_0x548fed('0x1b9e')](_0x548fed('0x1993')),_0x5d262b[_0x548fed('0x1b9e')](_0x548fed('0xcbf')),_0x5d262b['removeAllListeners'](_0x548fed('0x15b')),_0x5d262b['removeAllListeners']('whatsapp_queue_waiting_interaction:save'),_0x5d262b['removeAllListeners']('whatsapp_queue_waiting_interaction:remove');});}const _0x863307=_0x1676d2;_0x9d4905['$inject']=[_0x189033('0x7a5'),'$timeout',_0x189033('0x1e48'),'$document',_0x189033('0x2063'),'$translate',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x1777')];function _0x9d4905(_0x217ec8,_0x18d366,_0x495cdc,_0x4b6584,_0x4c307c,_0x59736c,_0xb32491,_0x4080dd,_0x293e45,_0x14d385,_0x3e808c){const _0xb39e63=_0x189033,_0x3f5fa7=this;_0x3f5fa7[_0xb39e63('0xc96')]=_0x4080dd[_0xb39e63('0x20b2')](),_0x3f5fa7[_0xb39e63('0xace')]={},_0x3f5fa7[_0xb39e63('0x260a')]={},_0x3f5fa7[_0xb39e63('0x1ce6')]={'count':0x0,'rows':[]},_0x3f5fa7[_0xb39e63('0xe4d')]={'count':0x0,'rows':[]},_0x3f5fa7[_0xb39e63('0x23a2')]={'includeAll':!![],'sort':_0xb39e63('0xc36'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x3f5fa7['advancedSearch']={'fields':[{'name':'Id','column':'id','type':_0xb39e63('0x121f')},{'name':_0xb39e63('0x1309'),'column':_0xb39e63('0x1309'),'type':'autocomplete','options':{'searchFields':['firstName',_0xb39e63('0x510'),_0xb39e63('0x1c92')],'route':{'model':'cmContact','action':_0xb39e63('0x1e6e'),'params':{'fields':'id,firstName,lastName,email','Contact':_0xb39e63('0xfd'),'nolimit':!![]}},'extraOperators':[_0xb39e63('0xe55')],'excludedOperators':[_0xb39e63('0x17ee')]}},{'name':_0xb39e63('0x1765'),'column':_0xb39e63('0x18e5'),'type':_0xb39e63('0x1bcd'),'options':{'excludedOperators':[_0xb39e63('0x393'),'$ne']}},{'name':'Status','column':_0xb39e63('0xd8a'),'type':'select','values':[{'id':0x0,'translate':_0xb39e63('0x10b1')},{'id':0x1,'translate':_0xb39e63('0x270a')}],'options':{'excludedOperators':[_0xb39e63('0x17ee')]}},{'name':_0xb39e63('0x62c'),'column':'User','type':_0xb39e63('0xeb'),'options':{'table':'i','route':{'model':_0xb39e63('0xc96'),'action':_0xb39e63('0x1e6e'),'params':{'role':_0xb39e63('0x2327'),'fields':_0xb39e63('0x2686'),'nolimit':!![]}},'searchFields':['fullname',_0xb39e63('0x60a')],'extraOperators':[_0xb39e63('0xe55')],'excludedOperators':[_0xb39e63('0x17ee')]}},{'name':_0xb39e63('0xa78'),'column':_0xb39e63('0xe22'),'type':'multiselect','options':{'route':{'model':_0xb39e63('0xc96'),'action':_0xb39e63('0x2842'),'params':{'id':_0x3f5fa7['user']['id'],'nolimit':!![]}}}},{'name':_0xb39e63('0x198f'),'column':'Tag','type':_0xb39e63('0xf6c'),'options':{'route':{'model':'tag','action':_0xb39e63('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0xb39e63('0x1479')]}},{'name':_0xb39e63('0x10c1'),'column':_0xb39e63('0x1a4'),'type':_0xb39e63('0x270e'),'options':{'excludedOperators':[_0xb39e63('0x17ee')]}},{'name':_0xb39e63('0x1bb6'),'column':'unreadMessages','type':_0xb39e63('0xb31'),'values':[{'id':0x1,'translate':'DASHBOARDS.READ'},{'id':0x0,'translate':'DASHBOARDS.UNREAD'}],'options':{'excludedOperators':['$ne']}}]},_0x3f5fa7[_0xb39e63('0xd10')]=_0xb39e63('0x24eb'),_0x3f5fa7[_0xb39e63('0x1dd2')]=_0xd07e0d,_0x3f5fa7[_0xb39e63('0x53')]=_0x2672ef,_0x3f5fa7[_0xb39e63('0x14ce')]=_0x4141f0,_0x3f5fa7[_0xb39e63('0xd53')]=_0x4038ed,_0x3f5fa7[_0xb39e63('0x23bb')]=_0x3cc033,_0x3f5fa7[_0xb39e63('0x14b7')]=_0x2b0d00,_0x3f5fa7[_0xb39e63('0x1dd3')]=_0x3495a4,_0x3f5fa7[_0xb39e63('0x2084')]=_0x32a7a2,_0x3f5fa7[_0xb39e63('0xb12')]=_0xfeb0b5,_0x3f5fa7[_0xb39e63('0x239f')]=_0x20ae21,_0x3f5fa7[_0xb39e63('0xb65')]=_0xbe5604,_0x3f5fa7['onSearchBarExpand']=_0x160d88,_0x3f5fa7[_0xb39e63('0x2121')]=_0x9ecb03;function _0xd07e0d(_0x527da7,_0x4f14c1){const _0x2cf6d5=_0xb39e63;return _0x3f5fa7[_0x2cf6d5('0xace')]=_0x527da7,_0x3f5fa7[_0x2cf6d5('0x260a')]=_0x4f14c1,_0xb32491[_0x2cf6d5('0xc96')][_0x2cf6d5('0x1e6e')+_0x2e3ca0()['upperFirst'](_0x2cf6d5('0x2595'))]({'id':_0x3f5fa7[_0x2cf6d5('0xc96')]['id'],'nolimit':!![]})['$promise'][_0x2cf6d5('0x683')](function(_0xa3e18c){const _0x634fa=_0x2cf6d5;return _0x3f5fa7[_0x634fa('0x2595')]=_0xa3e18c||{'count':0x0,'rows':[]},_0xb32491[_0x634fa('0x270')][_0x634fa('0x1e6e')]()['$promise'];})[_0x2cf6d5('0x683')](function(_0x5139c0){_0x3f5fa7['tags']=_0x5139c0||{'count':0x0,'rows':[]};})[_0x2cf6d5('0x683')](function(){_0x3f5fa7['quickFilters']=_0x117843();})[_0x2cf6d5('0x130a')](function(_0x138a26){const _0x245755=_0x2cf6d5;console[_0x245755('0x52a')](_0x138a26);})[_0x2cf6d5('0x2874')](function(){const _0x7ea8f2=_0x2cf6d5;let _0x3acbec=_0x4c307c[_0x7ea8f2('0x120e')][_0x7ea8f2('0x1b28')]('motion2.home.fax:'+_0x3f5fa7[_0x7ea8f2('0xc96')]['id']);if(_0x3acbec)try{_0x3acbec=JSON[_0x7ea8f2('0x1f34')](_0x3acbec);if(_0x3acbec['query']){_0x3f5fa7[_0x7ea8f2('0x23a2')]=_0x2e3ca0()['merge'](_0x3f5fa7[_0x7ea8f2('0x23a2')],_0x3acbec[_0x7ea8f2('0x23a2')]);if(_0x2e3ca0()[_0x7ea8f2('0x173f')](_0x3f5fa7['faxAccounts']['rows']))_0x3f5fa7[_0x7ea8f2('0x23a2')]['FaxAccountId']=[];else _0x2e3ca0()[_0x7ea8f2('0x173f')](_0x3f5fa7['query'][_0x7ea8f2('0xe22')])&&(_0x3f5fa7[_0x7ea8f2('0x23a2')][_0x7ea8f2('0xe22')]=_0x2e3ca0()(_0x3f5fa7['faxAccounts'][_0x7ea8f2('0xf5d')])[_0x7ea8f2('0x386')]('id')[_0x7ea8f2('0x22c8')]()[_0x7ea8f2('0x1c6b')]());_0x3f5fa7[_0x7ea8f2('0x23a2')]['sort']&&_0x3f5fa7['query']['sort'][_0x7ea8f2('0x824')]('lastMessage')>=0x0&&(_0x3f5fa7[_0x7ea8f2('0x23a2')]=_0x2e3ca0()[_0x7ea8f2('0x8b5')](_0x3f5fa7[_0x7ea8f2('0x23a2')],_0x7ea8f2('0x671'))),_0x3f5fa7[_0x7ea8f2('0x23a2')][_0x7ea8f2('0x2761')]=!![],_0x3f5fa7[_0x7ea8f2('0x1b8f')]=_0x3f5fa7[_0x7ea8f2('0x23a2')][_0x7ea8f2('0x25')]?!![]:![];}}catch(_0x1897d6){console[_0x7ea8f2('0x52a')](_0x1897d6);}else{const _0x3fce43={'$gte':_0x1aaf93()()[_0x7ea8f2('0x1627')](_0x7ea8f2('0x55b'))[_0x7ea8f2('0xb11')](0x0,!![])[_0x7ea8f2('0x26dd')](),'$lte':_0x1aaf93()()['endOf'](_0x7ea8f2('0x55b'))[_0x7ea8f2('0xb11')](0x0,!![])[_0x7ea8f2('0x26dd')]()},_0x8e3c5f={'FaxAccountId':_0x2e3ca0()[_0x7ea8f2('0x386')](_0x3f5fa7[_0x7ea8f2('0x2595')][_0x7ea8f2('0xf5d')],'id'),'createdAt':_0x3fce43};_0x3f5fa7[_0x7ea8f2('0x23a2')]=_0x2e3ca0()[_0x7ea8f2('0xf22')](_0x3f5fa7['query'],_0x8e3c5f);}_0x293e45['on'](_0x7ea8f2('0x1081'),_0x52256c),_0x293e45['on'](_0x7ea8f2('0x22e6'),_0x52256c),_0x293e45['on'](_0x7ea8f2('0x2501'),_0x2f4f62),_0x293e45['on']('faxMessage:save',_0x41298),_0x293e45['on'](_0x7ea8f2('0xf37'),_0x41298),_0x293e45['on'](_0x7ea8f2('0x172b'),_0xd5062d),_0x293e45['on'](_0x7ea8f2('0x6f'),_0x3ddc67),_0x4141f0(_0x3f5fa7[_0x7ea8f2('0x23a2')][_0x7ea8f2('0xdf8')]);});}function _0x117843(){const _0x431ac0=_0xb39e63;return[{'name':_0x431ac0('0x10c1'),'key':_0x431ac0('0x1a4'),'type':_0x431ac0('0x270e'),'label':_0x431ac0('0x1006')},{'name':_0x431ac0('0xc51'),'key':_0x431ac0('0x20db'),'type':'select','label':_0x431ac0('0x1866'),'customOptions':[{'value':0x0,'translate':_0x431ac0('0x2226')},{'value':0x1,'translate':_0x431ac0('0x38f')},{'value':null,'translate':'DASHBOARDS.ALL'}]},{'name':'Status','key':_0x431ac0('0xd8a'),'type':_0x431ac0('0xb31'),'label':_0x431ac0('0x1b77'),'customOptions':[{'value':0x0,'translate':_0x431ac0('0x10b1')},{'value':0x1,'translate':'DASHBOARDS.CLOSED'},{'value':null,'translate':'DASHBOARDS.ALL'}]},{'name':'Account','key':_0x431ac0('0xe22'),'type':'multiselect','label':_0x431ac0('0x1202'),'options':_0x3f5fa7[_0x431ac0('0x2595')][_0x431ac0('0xf5d')],'clearAll':![]},{'name':_0x431ac0('0x62c'),'key':_0x431ac0('0x10c5'),'type':_0x431ac0('0xb31'),'label':_0x431ac0('0x21fb'),'customOptions':[{'value':_0x3f5fa7[_0x431ac0('0xc96')]['id'],'translate':_0x431ac0('0x96a')},{'value':_0x431ac0('0x13c'),'translate':'DASHBOARDS.NOT_ASSIGNED'},{'value':undefined,'translate':_0x431ac0('0x475')}]},{'name':_0x431ac0('0x1e'),'key':_0x431ac0('0x270'),'type':_0x431ac0('0xf6c'),'label':_0x431ac0('0x2264'),'options':_0x3f5fa7[_0x431ac0('0x1ce6')][_0x431ac0('0xf5d')],'placeholder':_0x431ac0('0x7cb')}];}function _0x2672ef(_0x5932bf){const _0xb7b054=_0xb39e63;_0x3f5fa7[_0xb7b054('0xab2')]=![],_0x3f5fa7[_0xb7b054('0xe4d')]=_0x5932bf||{'count':0x0,'rows':[]};for(let _0x208257=0x0;_0x208257<_0x3f5fa7[_0xb7b054('0xe4d')][_0xb7b054('0xf5d')]['length'];_0x208257+=0x1){_0x3495a4(_0x3f5fa7[_0xb7b054('0xe4d')][_0xb7b054('0xf5d')][_0x208257]);}}function _0x4141f0(_0x5920e5){const _0x5c51aa=_0xb39e63;_0x3f5fa7[_0x5c51aa('0xab2')]=!![];!_0x5920e5&&(_0x3f5fa7['query']['page']=0x1);_0x3f5fa7[_0x5c51aa('0x23a2')][_0x5c51aa('0x1cc8')]=(_0x3f5fa7[_0x5c51aa('0x23a2')]['page']-0x1)*_0x3f5fa7[_0x5c51aa('0x23a2')]['limit'];let _0x4fce63=_0x4c307c[_0x5c51aa('0x120e')][_0x5c51aa('0x1b28')](_0x5c51aa('0x1300')+_0x3f5fa7[_0x5c51aa('0xc96')]['id']);_0x4fce63=_0x4fce63?JSON['parse'](_0x4fce63):{},_0x4fce63[_0x5c51aa('0x23a2')]=_0x3f5fa7[_0x5c51aa('0x23a2')],_0x4c307c[_0x5c51aa('0x120e')][_0x5c51aa('0x15d')](_0x5c51aa('0x1300')+_0x3f5fa7[_0x5c51aa('0xc96')]['id'],JSON['stringify'](_0x4fce63)),_0x3f5fa7[_0x5c51aa('0x1883')]=_0xb32491[_0x5c51aa('0x1352')][_0x5c51aa('0x1e6e')](_0x3f5fa7['query'],_0x2672ef)[_0x5c51aa('0xe53')];}function _0x4038ed(_0x187c36,_0x170bf6){const _0x12aedf=_0xb39e63;_0x217ec8[_0x12aedf('0x1cd5')]['vm'][_0x12aedf('0x297')]('fax',_0x170bf6);}function _0x3cc033(_0xfd55e4,_0x738681,_0xe3d986){const _0x682025=_0xb39e63;_0xb32491['faxInteraction'][_0x682025('0x18e8')]({'id':_0x738681['id'],'attachments':_0xe3d986})[_0x682025('0xe53')][_0x682025('0x683')](function(_0x2e0a39){const _0x15d405=_0x682025,_0x46e8c5=[_0x2e0a39[_0x15d405('0x1fb3')]],_0x58645c=_0x15d405('0x2148')+_0x738681['id']+'.zip',_0x2f7cb3=new Blob(_0x46e8c5,{'type':_0x2e0a39[_0x15d405('0xcf0')]}),_0xc52750=window[_0x15d405('0x12e1')]['createElement']('a');_0xc52750[_0x15d405('0x130f')](_0x15d405('0x2767'),URL['createObjectURL'](_0x2f7cb3)),_0xc52750[_0x15d405('0x130f')](_0x15d405('0x18e8'),_0x58645c),document['body'][_0x15d405('0x1e43')](_0xc52750),_0xc52750['click']();})[_0x682025('0x130a')](function(_0x5bc1db){const _0x11a95e=_0x682025;if(_0x5bc1db['data']&&_0x5bc1db[_0x11a95e('0x5a5')][_0x11a95e('0x17f')]&&_0x5bc1db['data'][_0x11a95e('0x17f')]['length'])for(let _0x10c65b=0x0;_0x10c65b<_0x5bc1db['data'][_0x11a95e('0x17f')][_0x11a95e('0x1564')];_0x10c65b+=0x1){_0x14d385['error']({'title':_0x5bc1db['data'][_0x11a95e('0x17f')][_0x10c65b]['type'],'msg':_0x5bc1db[_0x11a95e('0x5a5')][_0x11a95e('0x17f')][_0x10c65b][_0x11a95e('0x8c2')]});}else _0x14d385[_0x11a95e('0x52a')]({'title':_0x5bc1db[_0x11a95e('0x13ee')]?_0x11a95e('0x2168')+_0x5bc1db[_0x11a95e('0x13ee')]+_0x11a95e('0xbf6')+_0x5bc1db[_0x11a95e('0x24a9')]:_0x11a95e('0x23bb'),'msg':_0x5bc1db['data']?JSON['stringify'](_0x5bc1db[_0x11a95e('0x5a5')][_0x11a95e('0x8c2')]):_0x5bc1db[_0x11a95e('0x1ff0')]()});});}function _0x2b0d00(_0xd94f8d,_0x3b1af5){const _0xb794db=_0xb39e63,_0x193b48=_0x3f5fa7[_0xb794db('0xc96')][_0xb794db('0x1431')]||_0x3f5fa7['user'][_0xb794db('0x1938')]||_0x3f5fa7[_0xb794db('0xc96')]['mailPause']||_0x3f5fa7[_0xb794db('0xc96')][_0xb794db('0x1a11')]||_0x3f5fa7['user'][_0xb794db('0x716')],_0x249608=!_0x3b1af5['Account'][_0xb794db('0x989')];_0x495cdc['show']({'controller':'DisposeInteractionDialogController','controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular[_0xb794db('0x1fcc')](_0x4b6584[_0xb794db('0x18e5')]),'clickOutsideToClose':_0x249608,'escapeToClose':_0x249608,'onRemoving':function(){const _0x45bc2c=_0xb794db;_0x3f5fa7[_0x45bc2c('0xc96')]&&_0x3b1af5[_0x45bc2c('0xa78')]['mandatoryDisposition']&&!_0x193b48&&_0xb32491[_0x45bc2c('0xc96')]['unpause']({'id':_0x3f5fa7[_0x45bc2c('0xc96')]['id']})['$promise'][_0x45bc2c('0x130a')](function(_0x1175a8){const _0x35d3bb=_0x45bc2c;console[_0x35d3bb('0x52a')](_0x1175a8);});},'locals':{'user':_0x3f5fa7[_0xb794db('0xc96')],'channel':_0xb794db('0x23e9'),'interaction':_0x3b1af5}});}function _0x3495a4(_0x38eb87){const _0x253079=_0xb39e63;_0x38eb87[_0x253079('0x1309')]?(_0x38eb87[_0x253079('0x12b3')]=(_0x38eb87[_0x253079('0x1309')][_0x253079('0xeef')]||'')+'\x20'+(_0x38eb87[_0x253079('0x1309')][_0x253079('0x510')]||''),_0x38eb87['contactInfo']=_0x38eb87[_0x253079('0x1309')][_0x253079('0x23e9')]):_0x38eb87['contactName']=_0x59736c[_0x253079('0x2728')](_0x253079('0x215e'));}function _0x32a7a2(_0x4de50b){const _0x14dac0=_0xb39e63;if(_0x4de50b[_0x14dac0('0x10c5')])return _0x4de50b[_0x14dac0('0x10c5')]===_0x3f5fa7[_0x14dac0('0xc96')]['id']?_0x59736c[_0x14dac0('0x2728')](_0x14dac0('0x96a')):_0x4de50b['Owner']['fullname']+'\x20<'+_0x4de50b[_0x14dac0('0x2464')][_0x14dac0('0x1d43')]+'>';return _0x59736c[_0x14dac0('0x2728')](_0x14dac0('0x2608'));}function _0xfeb0b5(_0x1c170a){const _0x58d3a9=_0xb39e63;if(_0x1c170a['Account'])return _0x1c170a['Account'][_0x58d3a9('0x1d46')];return _0x59736c[_0x58d3a9('0x2728')](_0x58d3a9('0x215e'));}function _0x20ae21(_0x16f56a,_0x1b7f9b){const _0x22eccd=_0xb39e63;_0x495cdc[_0x22eccd('0x1d4')]({'controller':_0x22eccd('0x10c2'),'controllerAs':'vm','templateUrl':_0x354ecd,'parent':angular[_0x22eccd('0x1fcc')](_0x4b6584[_0x22eccd('0x18e5')]),'clickOutsideToClose':![],'locals':{'account':_0x1b7f9b,'message':{},'type':'new','interaction':{}},'fullscreen':!![]})[_0x22eccd('0x683')](function(_0x2e2d40){const _0x2db4ec=_0x22eccd;if(_0x2e2d40){if(_0x2e2d40['message']&&_0x2e2d40['message'][_0x2db4ec('0x250b')]){const _0x192daa={'channel':_0x2db4ec('0x23e9'),'account':_0x1b7f9b,'message':_0x2e2d40[_0x2db4ec('0x8c2')],'contact':_0x2e2d40['contact']};_0x3e808c[_0x2db4ec('0x23c6')](_0x192daa);}else{const _0x32cc0b=_0x2e2d40;return _0xb32491[_0x2db4ec('0x244a')][_0x2db4ec('0x1503')]({'id':_0x1b7f9b['id']},_0x32cc0b)['$promise']['then'](function(_0x3cfaee){const _0xe40626=_0x2db4ec;_0x14d385['success']({'title':'Message\x20properly\x20sent!','msg':_0xe40626('0x21a1')}),_0x217ec8[_0xe40626('0x1cd5')]['vm'][_0xe40626('0x297')](_0xe40626('0x23e9'),_0x3cfaee);})['catch'](function(_0x30a412){const _0x30925c=_0x2db4ec;if(_0x30a412['data']&&_0x30a412[_0x30925c('0x5a5')][_0x30925c('0x17f')]&&_0x30a412['data'][_0x30925c('0x17f')][_0x30925c('0x1564')])for(let _0x5c437d=0x0;_0x5c437d<_0x30a412[_0x30925c('0x5a5')][_0x30925c('0x17f')][_0x30925c('0x1564')];_0x5c437d++){_0x14d385[_0x30925c('0x52a')]({'title':_0x30a412[_0x30925c('0x5a5')][_0x30925c('0x17f')][_0x5c437d][_0x30925c('0xcf0')],'msg':_0x30a412[_0x30925c('0x5a5')][_0x30925c('0x17f')][_0x5c437d][_0x30925c('0x8c2')]});}else _0x14d385['error']({'title':_0x30925c('0x1e95'),'msg':_0x30a412[_0x30925c('0x5a5')]?JSON['stringify'](_0x30a412['data']):_0x30a412['message']||_0x30a412[_0x30925c('0x1ff0')]()});});}}});}function _0xd5062d(_0x65b65e){const _0x5c4dce=_0xb39e63;let _0x1ef6d5;const _0x31e37e=_0x2e3ca0()[_0x5c4dce('0x1c07')](_0x3f5fa7[_0x5c4dce('0xe4d')][_0x5c4dce('0xf5d')],{'id':_0x65b65e[_0x5c4dce('0x5b6')]});_0x31e37e&&_0x31e37e[_0x5c4dce('0x2139')]&&(_0x1ef6d5=_0x2e3ca0()[_0x5c4dce('0x1c07')](_0x31e37e['Users'],{'id':_0x65b65e['UserId']}),!_0x1ef6d5&&_0x31e37e['Users'][_0x5c4dce('0x1fd0')]({'id':_0x65b65e[_0x5c4dce('0x10c5')]}));}function _0x3ddc67(_0x3a908a){const _0x4d2cae=_0xb39e63,_0x538be7=_0x2e3ca0()[_0x4d2cae('0x1c07')](_0x3f5fa7[_0x4d2cae('0xe4d')][_0x4d2cae('0xf5d')],{'id':_0x3a908a['FaxInteractionId']});_0x538be7&&_0x538be7[_0x4d2cae('0x2139')]&&_0x2e3ca0()[_0x4d2cae('0x3ec')](_0x538be7[_0x4d2cae('0x2139')],{'id':_0x3a908a[_0x4d2cae('0x10c5')]});}function _0x52256c(_0xa9b2f0){const _0x516816=_0xb39e63;if(_0xa9b2f0){const _0x1e259b=_0x2e3ca0()['find'](_0x3f5fa7[_0x516816('0xe4d')][_0x516816('0xf5d')],{'id':_0xa9b2f0['id']});if(_0x1e259b){_0x1e259b['Users']=[];_0xa9b2f0['closed']&&(_0x1e259b['unreadMessages']=0x0);if(_0x3f5fa7['query'][_0x516816('0x671')]){const _0x436a8d=_0x2e3ca0()[_0x516816('0x18ad')](_0x3f5fa7[_0x516816('0x23a2')][_0x516816('0x671')],'-')?_0x516816('0x1f5a'):_0x516816('0xe38');_0x3f5fa7['faxInteractions'][_0x516816('0xf5d')]=_0x2e3ca0()[_0x516816('0x2ef')](_0x3f5fa7[_0x516816('0xe4d')][_0x516816('0xf5d')],_0x2e3ca0()[_0x516816('0x1fe0')](_0x3f5fa7[_0x516816('0x23a2')][_0x516816('0x671')],'-'),_0x436a8d);}_0x2e3ca0()[_0x516816('0xf22')](_0x1e259b,_0x2e3ca0()[_0x516816('0x24d0')](_0xa9b2f0,_0x2e3ca0()[_0x516816('0x55e')](_0x1e259b)));}else _0x4141f0(_0x3f5fa7[_0x516816('0x23a2')][_0x516816('0xdf8')]);}}function _0x2f4f62(_0x346577){const _0x1c884d=_0xb39e63;if(_0x346577){const _0x35a914=_0x2e3ca0()['find'](_0x3f5fa7['faxInteractions'][_0x1c884d('0xf5d')],{'id':_0x346577['id']});_0x35a914&&(_0x35a914['Tags']=_0x346577[_0x1c884d('0x1ce6')]||[],_0x2e3ca0()[_0x1c884d('0xf22')](_0x35a914,_0x2e3ca0()['pick'](_0x346577,_0x2e3ca0()[_0x1c884d('0x55e')](_0x35a914))));}}function _0x41298(_0x4080c8){const _0x1dfb06=_0xb39e63;if(_0x4080c8&&!_0x4080c8[_0x1dfb06('0x252d')]){const _0x51f8cc=_0x2e3ca0()[_0x1dfb06('0x1c07')](_0x3f5fa7[_0x1dfb06('0xe4d')][_0x1dfb06('0xf5d')],{'id':_0x4080c8[_0x1dfb06('0x5b6')]});if(_0x51f8cc){const _0x5a232e=_0x2e3ca0()[_0x1dfb06('0x1c07')](_0x51f8cc['Messages'],{'id':_0x4080c8['id']});_0x5a232e?_0x2e3ca0()['merge'](_0x5a232e,_0x2e3ca0()[_0x1dfb06('0x24d0')](_0x4080c8,_0x2e3ca0()[_0x1dfb06('0x55e')](_0x5a232e))):(_0x2e3ca0()['isNil'](_0x51f8cc[_0x1dfb06('0xc51')])&&(_0x51f8cc['Messages']={'count':0x0}),!_0x4080c8['read']&&(_0x51f8cc[_0x1dfb06('0xc51')][_0x1dfb06('0x50d')]+=0x1));}}}function _0xbe5604(){const _0x1c48f4=_0xb39e63;_0x3f5fa7[_0x1c48f4('0x1b8f')]=![];}function _0x160d88(){const _0x2dd410=_0xb39e63;_0x3f5fa7[_0x2dd410('0x1b8f')]=!![];}function _0x9ecb03(){const _0x406486=_0xb39e63;_0x3f5fa7[_0x406486('0x1b8f')]=![],_0x495cdc[_0x406486('0x1d4')]({'controller':_0x406486('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x406486('0x1fcc')](_0x4b6584[_0x406486('0x18e5')]),'clickOutsideToClose':![],'locals':{'color':_0x3f5fa7[_0x406486('0xd10')],'fields':_0x3f5fa7[_0x406486('0x19c9')][_0x406486('0x189a')],'storagePath':_0x406486('0x270b')},'fullscreen':!![]})['then'](function(_0x22673c){const _0x36f069=_0x406486;_0x3f5fa7[_0x36f069('0x23a2')][_0x36f069('0x19a4')]=_0x22673c===![]?undefined:_0x22673c;if(_0x3f5fa7['query'][_0x36f069('0x19a4')]||_0x22673c===![])_0x4141f0();})[_0x406486('0x130a')](function(_0x438bfb){const _0x4df048=_0x406486;_0x14d385['error']({'title':_0x4df048('0x1119'),'msg':_0x438bfb[_0x4df048('0x5a5')]?JSON[_0x4df048('0x258a')](_0x438bfb[_0x4df048('0x5a5')][_0x4df048('0x8c2')]):_0x438bfb[_0x4df048('0x1ff0')]()});});}let _0x320000=!![],_0x3e52ba=0x1;_0x217ec8[_0xb39e63('0x186d')]('vm.query.filter',function(_0x1f50ff,_0x272f5f){const _0x3ba257=_0xb39e63;_0x320000?_0x18d366(function(){_0x320000=![];}):(!_0x272f5f&&(_0x3e52ba=_0x3f5fa7[_0x3ba257('0x23a2')][_0x3ba257('0xdf8')]),_0x1f50ff!==_0x272f5f&&(_0x3f5fa7[_0x3ba257('0x23a2')][_0x3ba257('0xdf8')]=0x1),!_0x1f50ff&&(_0x3f5fa7[_0x3ba257('0x23a2')][_0x3ba257('0xdf8')]=_0x3e52ba),_0x4141f0(_0x3f5fa7[_0x3ba257('0x23a2')][_0x3ba257('0xdf8')]));}),_0x217ec8['$on'](_0xb39e63('0x4b8'),function(){const _0x5cbf9c=_0xb39e63;_0x293e45[_0x5cbf9c('0x1b9e')](_0x5cbf9c('0x2656')),_0x293e45['removeAllListeners'](_0x5cbf9c('0xf37')),_0x293e45[_0x5cbf9c('0x1b9e')](_0x5cbf9c('0x1081')),_0x293e45[_0x5cbf9c('0x1b9e')](_0x5cbf9c('0x2501')),_0x293e45['removeAllListeners'](_0x5cbf9c('0x22e6')),_0x293e45[_0x5cbf9c('0x1b9e')]('user_has_fax_interactions:save'),_0x293e45[_0x5cbf9c('0x1b9e')](_0x5cbf9c('0x6f'));});}const _0x2e21b5=_0x9d4905;_0x2a9a31[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2063'),_0x189033('0x1d08'),'api',_0x189033('0xba1'),'socket',_0x189033('0x1d70'),'draftManager'];function _0x2a9a31(_0x13ac0e,_0x49d566,_0x5abb08,_0x3dda1e,_0x5cf4cc,_0x5e59d1,_0x5e93d1,_0x2bdb86,_0x48d6ce,_0x4a97a9,_0x429d7e){const _0x420e8b=_0x189033,_0xc006c5=this;_0xc006c5[_0x420e8b('0xc96')]=_0x2bdb86[_0x420e8b('0x20b2')](),_0xc006c5[_0x420e8b('0xace')]={},_0xc006c5[_0x420e8b('0x260a')]={},_0xc006c5[_0x420e8b('0x1ce6')]={'count':0x0,'rows':[]},_0xc006c5['mailInteractions']={'count':0x0,'rows':[]},_0xc006c5[_0x420e8b('0x23a2')]={'includeAll':!![],'sort':_0x420e8b('0xc36'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0xc006c5[_0x420e8b('0x19c9')]={'fields':[{'name':'Id','column':'id','type':_0x420e8b('0x121f')},{'name':_0x420e8b('0x1309'),'column':'Contact','type':'autocomplete','options':{'searchFields':[_0x420e8b('0xeef'),_0x420e8b('0x510'),_0x420e8b('0x1c92')],'route':{'model':_0x420e8b('0x276e'),'action':_0x420e8b('0x1e6e'),'params':{'fields':_0x420e8b('0x8ff'),'Contact':_0x420e8b('0xfd'),'nolimit':!![]}},'extraOperators':[_0x420e8b('0xe55')],'excludedOperators':[_0x420e8b('0x17ee')]}},{'name':_0x420e8b('0x25a9'),'column':_0x420e8b('0x1e66'),'type':_0x420e8b('0x1bcd'),'options':{'excludedOperators':[_0x420e8b('0x393'),'$ne']}},{'name':'Body','column':_0x420e8b('0x183b'),'type':_0x420e8b('0x1bcd'),'options':{'excludedOperators':[_0x420e8b('0x393'),'$ne']}},{'name':_0x420e8b('0x1d9d'),'column':_0x420e8b('0xd8a'),'type':_0x420e8b('0xb31'),'values':[{'id':0x0,'translate':_0x420e8b('0x10b1')},{'id':0x1,'translate':_0x420e8b('0x270a')}],'options':{'excludedOperators':[_0x420e8b('0x17ee')]}},{'name':_0x420e8b('0x1d02'),'column':'substatus','type':_0x420e8b('0xf6c'),'options':{'field':'name','route':{'model':_0x420e8b('0x1577'),'action':_0x420e8b('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x420e8b('0x1479')]}},{'name':_0x420e8b('0x62c'),'column':_0x420e8b('0x1dad'),'type':'autocomplete','options':{'table':'i','route':{'model':_0x420e8b('0xc96'),'action':_0x420e8b('0x1e6e'),'params':{'role':'agent','fields':_0x420e8b('0x2686'),'nolimit':!![]}},'searchFields':[_0x420e8b('0x11bc'),'name'],'extraOperators':[_0x420e8b('0xe55')],'excludedOperators':[_0x420e8b('0x17ee')]}},{'name':_0x420e8b('0xa78'),'column':'MailAccountId','type':_0x420e8b('0xf6c'),'options':{'route':{'model':_0x420e8b('0xc96'),'action':_0x420e8b('0x2872'),'params':{'id':_0xc006c5['user']['id'],'nolimit':!![]}}}},{'name':_0x420e8b('0x198f'),'column':_0x420e8b('0x1e'),'type':'multiselect','options':{'route':{'model':_0x420e8b('0x270'),'action':_0x420e8b('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x420e8b('0x1479')]}},{'name':_0x420e8b('0x10c1'),'column':_0x420e8b('0x1a4'),'type':_0x420e8b('0x270e'),'options':{'excludedOperators':[_0x420e8b('0x17ee')]}},{'name':_0x420e8b('0x1bb6'),'column':_0x420e8b('0x122e'),'type':_0x420e8b('0xb31'),'values':[{'id':0x1,'translate':_0x420e8b('0x38f')},{'id':0x0,'translate':_0x420e8b('0x2226')}],'options':{'excludedOperators':[_0x420e8b('0x17ee')]}}]},_0xc006c5[_0x420e8b('0xd10')]=_0x420e8b('0x2f8'),_0xc006c5[_0x420e8b('0x1dd2')]=_0x40e35b,_0xc006c5[_0x420e8b('0x53')]=_0x37d826,_0xc006c5['getMailInteractions']=_0x52f31f,_0xc006c5[_0x420e8b('0x2748')]=_0x5ed1fe,_0xc006c5[_0x420e8b('0x1fdb')]=_0x513187,_0xc006c5[_0x420e8b('0x14b7')]=_0x528ed8,_0xc006c5[_0x420e8b('0x1dd3')]=_0x1ecd51,_0xc006c5[_0x420e8b('0x2084')]=_0x2bfbb5,_0xc006c5[_0x420e8b('0xffc')]=_0x130f54,_0xc006c5[_0x420e8b('0x5e5')]=_0x2c3a3b,_0xc006c5[_0x420e8b('0xb65')]=_0x4e09d,_0xc006c5['onSearchBarExpand']=_0x130792,_0xc006c5['openAdvancedSearch']=_0x8d890e,_0x13ac0e['$on'](_0x420e8b('0xb25'),_0x576eff);function _0x40e35b(_0x20365a,_0x26d668){const _0x1257f4=_0x420e8b;return _0xc006c5[_0x1257f4('0xace')]=_0x20365a,_0xc006c5[_0x1257f4('0x260a')]=_0x26d668,_0x5e93d1['user'][_0x1257f4('0x1e6e')+_0x2e3ca0()[_0x1257f4('0x2711')]('mailAccounts')]({'id':_0xc006c5[_0x1257f4('0xc96')]['id'],'nolimit':!![]})[_0x1257f4('0xe53')][_0x1257f4('0x683')](function(_0x55b0a4){const _0x4894dc=_0x1257f4;return _0xc006c5[_0x4894dc('0x1093')]=_0x55b0a4||{'count':0x0,'rows':[]},_0x5e93d1[_0x4894dc('0x270')][_0x4894dc('0x1e6e')]()[_0x4894dc('0xe53')];})[_0x1257f4('0x683')](function(_0x2b6ea6){_0xc006c5['tags']=_0x2b6ea6||{'count':0x0,'rows':[]};})[_0x1257f4('0x683')](function(){const _0x1f3441=_0x1257f4;return _0x5e93d1[_0x1f3441('0x1577')][_0x1f3441('0x1e6e')]({'nolimit':!![]})[_0x1f3441('0xe53')];})[_0x1257f4('0x683')](function(_0x2c2844){const _0x498fc1=_0x1257f4;_0xc006c5[_0x498fc1('0x26a3')]=_0x2c2844||{'count':0x0,'rows':[]};})[_0x1257f4('0x683')](function(){const _0x592dd2=_0x1257f4;_0xc006c5[_0x592dd2('0xc71')]=_0x32d00b();})[_0x1257f4('0x130a')](function(_0x261921){const _0x36be55=_0x1257f4;console[_0x36be55('0x52a')](_0x261921);})[_0x1257f4('0x2874')](function(){const _0x227c34=_0x1257f4;let _0x1c2915=_0x5cf4cc[_0x227c34('0x120e')][_0x227c34('0x1b28')](_0x227c34('0x1949')+_0xc006c5[_0x227c34('0xc96')]['id']);if(_0x1c2915)try{_0x1c2915=JSON['parse'](_0x1c2915);if(_0x1c2915['query']){_0xc006c5[_0x227c34('0x23a2')]=_0x2e3ca0()[_0x227c34('0xf22')](_0xc006c5[_0x227c34('0x23a2')],_0x1c2915[_0x227c34('0x23a2')]);if(_0x2e3ca0()[_0x227c34('0x173f')](_0xc006c5[_0x227c34('0x1093')]['rows']))_0xc006c5[_0x227c34('0x23a2')]['MailAccountId']=[];else _0x2e3ca0()[_0x227c34('0x173f')](_0xc006c5[_0x227c34('0x23a2')][_0x227c34('0x1cd')])&&(_0xc006c5[_0x227c34('0x23a2')]['MailAccountId']=_0x2e3ca0()(_0xc006c5[_0x227c34('0x1093')]['rows'])['map']('id')['take']()[_0x227c34('0x1c6b')]());_0xc006c5[_0x227c34('0x23a2')][_0x227c34('0x671')]&&_0xc006c5[_0x227c34('0x23a2')]['sort'][_0x227c34('0x824')]('lastMessage')>=0x0&&(_0xc006c5[_0x227c34('0x23a2')]=_0x2e3ca0()[_0x227c34('0x8b5')](_0xc006c5['query'],_0x227c34('0x671'))),_0xc006c5[_0x227c34('0x23a2')][_0x227c34('0x2761')]=!![],_0xc006c5[_0x227c34('0x1b8f')]=_0xc006c5[_0x227c34('0x23a2')]['filter']?!![]:![];}}catch(_0x751793){console['error'](_0x751793);}else{const _0x52374a={'$gte':_0x1aaf93()()[_0x227c34('0x1627')](_0x227c34('0x55b'))['utcOffset'](0x0,!![])[_0x227c34('0x26dd')](),'$lte':_0x1aaf93()()[_0x227c34('0x3b3')](_0x227c34('0x55b'))[_0x227c34('0xb11')](0x0,!![])[_0x227c34('0x26dd')]()},_0x1b9295={'MailAccountId':_0x2e3ca0()['map'](_0xc006c5[_0x227c34('0x1093')][_0x227c34('0xf5d')],'id'),'createdAt':_0x52374a};_0xc006c5[_0x227c34('0x23a2')]=_0x2e3ca0()[_0x227c34('0xf22')](_0xc006c5[_0x227c34('0x23a2')],_0x1b9295);}_0x48d6ce['on'](_0x227c34('0xc43'),_0x316038),_0x48d6ce['on'](_0x227c34('0xc75'),_0x316038),_0x48d6ce['on'](_0x227c34('0x895'),_0x542859),_0x48d6ce['on'](_0x227c34('0x143f'),_0x1e71ac),_0x48d6ce['on']('mailMessage:update',_0x1e71ac),_0x48d6ce['on'](_0x227c34('0x1c95'),_0x94a39),_0x48d6ce['on'](_0x227c34('0x2301'),_0x523675),_0x52f31f(_0xc006c5[_0x227c34('0x23a2')][_0x227c34('0xdf8')]);});}function _0x32d00b(){const _0x112ee3=_0x420e8b;return[{'name':'Start\x20Date','key':_0x112ee3('0x1a4'),'type':_0x112ee3('0x270e'),'label':_0x112ee3('0x1006')},{'name':_0x112ee3('0xc51'),'key':'read','type':_0x112ee3('0xb31'),'label':_0x112ee3('0x1866'),'customOptions':[{'value':0x0,'translate':_0x112ee3('0x2226')},{'value':0x1,'translate':_0x112ee3('0x38f')},{'value':null,'translate':_0x112ee3('0x475')}]},{'name':'Status','key':'closed','type':_0x112ee3('0xb31'),'label':_0x112ee3('0x1b77'),'customOptions':[{'value':0x0,'translate':_0x112ee3('0x10b1')},{'value':0x1,'translate':'DASHBOARDS.CLOSED'},{'value':null,'translate':_0x112ee3('0x475')}]},{'name':_0x112ee3('0x1d02'),'key':_0x112ee3('0x231b'),'type':_0x112ee3('0xb31'),'label':_0x112ee3('0x2af'),'options':_0xc006c5[_0x112ee3('0x26a3')]['rows'],'customOptions':[{'value':_0x112ee3('0x13c'),'translate':_0x112ee3('0xfd6')},{'value':undefined,'translate':_0x112ee3('0x475')}],'ngValue':_0x112ee3('0x60a'),'ngIf':_0x112ee3('0xb01')},{'name':_0x112ee3('0xa78'),'key':_0x112ee3('0x1cd'),'type':_0x112ee3('0xf6c'),'label':_0x112ee3('0x1202'),'options':_0xc006c5[_0x112ee3('0x1093')][_0x112ee3('0xf5d')],'clearAll':![]},{'name':_0x112ee3('0x62c'),'key':_0x112ee3('0x10c5'),'type':_0x112ee3('0xb31'),'label':_0x112ee3('0x21fb'),'customOptions':[{'value':_0xc006c5[_0x112ee3('0xc96')]['id'],'translate':_0x112ee3('0x96a')},{'value':_0x112ee3('0x13c'),'translate':_0x112ee3('0x2608')},{'value':undefined,'translate':_0x112ee3('0x475')}]},{'name':_0x112ee3('0x1e'),'key':_0x112ee3('0x270'),'type':_0x112ee3('0xf6c'),'label':'DASHBOARDS.SELECT_TAG','options':_0xc006c5[_0x112ee3('0x1ce6')][_0x112ee3('0xf5d')],'placeholder':'DASHBOARDS.TAGS'}];}function _0x37d826(_0xe5a432){const _0x2b9794=_0x420e8b;_0xc006c5[_0x2b9794('0xab2')]=![],_0xc006c5[_0x2b9794('0xe2')]=_0xe5a432||{'count':0x0,'rows':[]};for(let _0x5483f6=0x0;_0x5483f6<_0xc006c5[_0x2b9794('0xe2')][_0x2b9794('0xf5d')]['length'];_0x5483f6+=0x1){_0x1ecd51(_0xc006c5[_0x2b9794('0xe2')]['rows'][_0x5483f6]);}}function _0x52f31f(_0x157888){const _0x30cd5f=_0x420e8b;_0xc006c5[_0x30cd5f('0xab2')]=!![];!_0x157888&&(_0xc006c5[_0x30cd5f('0x23a2')][_0x30cd5f('0xdf8')]=0x1);_0xc006c5[_0x30cd5f('0x23a2')][_0x30cd5f('0x1cc8')]=(_0xc006c5[_0x30cd5f('0x23a2')][_0x30cd5f('0xdf8')]-0x1)*_0xc006c5[_0x30cd5f('0x23a2')]['limit'];let _0x5429d9=_0x5cf4cc['localStorage'][_0x30cd5f('0x1b28')](_0x30cd5f('0x1949')+_0xc006c5[_0x30cd5f('0xc96')]['id']);_0x5429d9=_0x5429d9?JSON['parse'](_0x5429d9):{},_0x5429d9['query']=_0xc006c5[_0x30cd5f('0x23a2')],_0x5cf4cc[_0x30cd5f('0x120e')][_0x30cd5f('0x15d')](_0x30cd5f('0x1949')+_0xc006c5['user']['id'],JSON['stringify'](_0x5429d9)),_0xc006c5[_0x30cd5f('0x1883')]=_0x5e93d1['mailInteraction']['get'](_0xc006c5['query'],_0x37d826)[_0x30cd5f('0xe53')];}function _0x5ed1fe(_0x311a9a,_0x1e5792){const _0x173d80=_0x420e8b;_0x13ac0e[_0x173d80('0x1cd5')]['vm']['addInteractionTab']('mail',_0x1e5792);}function _0x513187(_0x553d8d,_0x3a1eac,_0x1220e1){const _0x4abf8d=_0x420e8b;_0x5e93d1[_0x4abf8d('0x95a')]['download']({'id':_0x3a1eac['id'],'attachments':_0x1220e1})[_0x4abf8d('0xe53')]['then'](function(_0x7ea464){const _0xe82d56=_0x4abf8d,_0x14698e=[_0x7ea464[_0xe82d56('0x1fb3')]],_0x1118af=_0xe82d56('0x14')+_0x3a1eac['id']+_0xe82d56('0x18ff'),_0x14a4c5=new Blob(_0x14698e,{'type':_0x7ea464[_0xe82d56('0xcf0')]}),_0x4e406a=window[_0xe82d56('0x12e1')][_0xe82d56('0x1ffa')]('a');_0x4e406a['setAttribute'](_0xe82d56('0x2767'),URL['createObjectURL'](_0x14a4c5)),_0x4e406a[_0xe82d56('0x130f')]('download',_0x1118af),document[_0xe82d56('0x18e5')][_0xe82d56('0x1e43')](_0x4e406a),_0x4e406a[_0xe82d56('0x1d42')]();})[_0x4abf8d('0x130a')](function(_0x4ecd0f){const _0x10b754=_0x4abf8d;if(_0x4ecd0f['data']&&_0x4ecd0f[_0x10b754('0x5a5')][_0x10b754('0x17f')]&&_0x4ecd0f[_0x10b754('0x5a5')][_0x10b754('0x17f')][_0x10b754('0x1564')])for(let _0x29902f=0x0;_0x29902f<_0x4ecd0f[_0x10b754('0x5a5')][_0x10b754('0x17f')][_0x10b754('0x1564')];_0x29902f+=0x1){_0x4a97a9[_0x10b754('0x52a')]({'title':_0x4ecd0f[_0x10b754('0x5a5')]['errors'][_0x29902f][_0x10b754('0xcf0')],'msg':_0x4ecd0f[_0x10b754('0x5a5')][_0x10b754('0x17f')][_0x29902f][_0x10b754('0x8c2')]});}else _0x4a97a9[_0x10b754('0x52a')]({'title':_0x4ecd0f['status']?_0x10b754('0x2168')+_0x4ecd0f[_0x10b754('0x13ee')]+_0x10b754('0xbf6')+_0x4ecd0f[_0x10b754('0x24a9')]:'downloadMailInteraction','msg':_0x4ecd0f[_0x10b754('0x5a5')]?JSON[_0x10b754('0x258a')](_0x4ecd0f[_0x10b754('0x5a5')][_0x10b754('0x8c2')]):_0x4ecd0f[_0x10b754('0x1ff0')]()});});}function _0x528ed8(_0x3c2ec4,_0x439d3b){const _0x2871c7=_0x420e8b,_0x25662d=_0xc006c5[_0x2871c7('0xc96')]['voicePause']||_0xc006c5[_0x2871c7('0xc96')]['chatPause']||_0xc006c5[_0x2871c7('0xc96')][_0x2871c7('0x774')]||_0xc006c5[_0x2871c7('0xc96')][_0x2871c7('0x1a11')]||_0xc006c5[_0x2871c7('0xc96')][_0x2871c7('0x716')],_0x4f258c=!_0x439d3b[_0x2871c7('0xa78')]['mandatoryDisposition'];_0x5abb08['show']({'controller':_0x2871c7('0x14a7'),'controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular['element'](_0x3dda1e[_0x2871c7('0x18e5')]),'clickOutsideToClose':_0x4f258c,'escapeToClose':_0x4f258c,'onRemoving':function(){const _0x34d253=_0x2871c7;_0xc006c5[_0x34d253('0xc96')]&&_0x439d3b[_0x34d253('0xa78')]['mandatoryDisposition']&&!_0x25662d&&_0x5e93d1['user'][_0x34d253('0x1778')]({'id':_0xc006c5['user']['id']})[_0x34d253('0xe53')]['catch'](function(_0x519407){const _0x3b28ba=_0x34d253;console[_0x3b28ba('0x52a')](_0x519407);});},'locals':{'user':_0xc006c5[_0x2871c7('0xc96')],'channel':'mail','interaction':_0x439d3b}});}function _0x1ecd51(_0x196d0c){const _0x1ed04d=_0x420e8b;if(!_0x2e3ca0()[_0x1ed04d('0x173f')](_0x196d0c['to'])&&_0x196d0c[_0x1ed04d('0xa78')]&&!_0x2e3ca0()[_0x1ed04d('0x2292')](_0x196d0c['to'],_0x196d0c[_0x1ed04d('0xa78')][_0x1ed04d('0x1c92')]))_0x196d0c[_0x1ed04d('0x12b3')]=_0x196d0c['to']['split']('\x20<')[0x0],_0x196d0c[_0x1ed04d('0x22f9')]=_0x196d0c['to'][_0x1ed04d('0x1fc5')]('<')['pop']()[_0x1ed04d('0x1fc5')]('>')[0x0];else _0x196d0c[_0x1ed04d('0x1309')]?(_0x196d0c[_0x1ed04d('0x12b3')]=(_0x196d0c[_0x1ed04d('0x1309')][_0x1ed04d('0xeef')]||'')+'\x20'+(_0x196d0c['Contact'][_0x1ed04d('0x510')]||''),_0x196d0c['contactInfo']=_0x196d0c['Contact'][_0x1ed04d('0x1c92')]||''):_0x196d0c[_0x1ed04d('0x12b3')]=_0x5e59d1['instant'](_0x1ed04d('0x215e'));}function _0x2bfbb5(_0x13c1db){const _0x8e0801=_0x420e8b;if(_0x13c1db['UserId'])return _0x13c1db[_0x8e0801('0x10c5')]===_0xc006c5[_0x8e0801('0xc96')]['id']?_0x5e59d1[_0x8e0801('0x2728')](_0x8e0801('0x96a')):_0x13c1db[_0x8e0801('0x2464')][_0x8e0801('0x11bc')]+'\x20<'+_0x13c1db['Owner'][_0x8e0801('0x1d43')]+'>';return _0x5e59d1['instant'](_0x8e0801('0x2608'));}function _0x130f54(_0x2dafc4){const _0x51c079=_0x420e8b;if(_0x2dafc4[_0x51c079('0xa78')])return _0x2dafc4[_0x51c079('0xa78')][_0x51c079('0x1d46')];return _0x5e59d1[_0x51c079('0x2728')]('DASHBOARDS.UNKNOWN');}function _0x576eff(_0x3ef26c,_0x2c4f4e){const _0x11e635=_0x420e8b;_0x2c4f4e[_0x11e635('0xa98')]?(_0x2c4f4e['interaction'][_0x11e635('0x31f')]=!![],_0x5ed1fe(null,_0x2c4f4e[_0x11e635('0xa98')])):_0x5abb08['show']({'controller':_0x11e635('0xebc'),'controllerAs':'vm','templateUrl':_0x1e7ae7,'parent':angular[_0x11e635('0x1fcc')](_0x3dda1e[_0x11e635('0x18e5')]),'clickOutsideToClose':![],'locals':{'account':_0x2c4f4e['account'],'message':_0x2c4f4e['content'],'type':_0x11e635('0x2546'),'interaction':{}},'fullscreen':!![]})['then'](function(_0x12eaae){const _0x12cfc2=_0x11e635;if(_0x12eaae){if(_0x12eaae[_0x12cfc2('0x8c2')]&&_0x12eaae[_0x12cfc2('0x8c2')][_0x12cfc2('0x250b')]){const _0x3a88a4={'id':_0x2c4f4e['id'],'channel':_0x12cfc2('0x129f'),'account':_0x12eaae[_0x12cfc2('0x1d2f')],'message':_0x12eaae[_0x12cfc2('0x8c2')]};_0x429d7e['update'](_0x3a88a4);}else{const _0x2f5511=_0x12eaae;return _0x5e93d1['mailAccount']['send']({'id':_0x2c4f4e[_0x12cfc2('0x1d2f')]['id']},_0x2f5511)[_0x12cfc2('0xe53')][_0x12cfc2('0x683')](function(_0x297363){const _0x4e957d=_0x12cfc2;_0x429d7e[_0x4e957d('0x3ec')](_0x2c4f4e['id']);if(_0x297363&&_0x297363[_0x4e957d('0xc51')]&&_0x297363[_0x4e957d('0xc51')][_0x4e957d('0x1564')]){if(_0x2f5511[_0x4e957d('0x1b46')]&&_0x2f5511[_0x4e957d('0x1b46')][_0x4e957d('0x1564')])for(let _0x2e224c=0x0;_0x2e224c<_0x2f5511[_0x4e957d('0x1b46')][_0x4e957d('0x1564')];_0x2e224c+=0x1){_0x5e93d1[_0x4e957d('0x34')][_0x4e957d('0x2480')]({'id':_0x2f5511[_0x4e957d('0x1b46')][_0x2e224c]['id']},{'MailMessageId':_0x2e3ca0()[_0x4e957d('0xd39')](_0x297363['Messages'])['id']});}_0x4a97a9['success']({'title':_0x4e957d('0xb96'),'msg':_0x4e957d('0x21a1')});if(_0x297363[_0x4e957d('0xd8a')]){_0x297363[_0x4e957d('0x43f')]=null;const _0x56b9b2=!_0x2c4f4e['account'][_0x4e957d('0x989')],_0x1d9d68=_0xc006c5['user']['voicePause']||_0xc006c5['user']['chatPause']||_0xc006c5[_0x4e957d('0xc96')][_0x4e957d('0x774')]||_0xc006c5['user'][_0x4e957d('0x1a11')]||_0xc006c5[_0x4e957d('0xc96')][_0x4e957d('0x716')];_0x5abb08[_0x4e957d('0x1d4')]({'controller':_0x4e957d('0x14a7'),'controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular['element'](_0x3dda1e['body']),'onRemoving':function(){const _0x34b143=_0x4e957d;_0xc006c5['user']&&_0x2c4f4e[_0x34b143('0x1d2f')][_0x34b143('0x989')]&&!_0x1d9d68&&_0x5e93d1[_0x34b143('0xc96')][_0x34b143('0x1778')]({'id':_0xc006c5[_0x34b143('0xc96')]['id']})[_0x34b143('0xe53')][_0x34b143('0x130a')](function(_0x2b6466){const _0x10017b=_0x34b143;console[_0x10017b('0x52a')](_0x2b6466);});},'clickOutsideToClose':_0x56b9b2,'escapeToClose':_0x56b9b2,'locals':{'user':_0xc006c5[_0x4e957d('0xc96')],'channel':'mail','interaction':_0x297363}});}else _0x13ac0e[_0x4e957d('0x1cd5')]['vm']['addInteractionTab'](_0x4e957d('0x129f'),_0x297363);}})[_0x12cfc2('0x130a')](function(_0x210bc8){const _0x131351=_0x12cfc2;if(_0x210bc8[_0x131351('0x5a5')]&&_0x210bc8[_0x131351('0x5a5')][_0x131351('0x17f')]&&_0x210bc8[_0x131351('0x5a5')]['errors']['length'])for(let _0x155976=0x0;_0x155976<_0x210bc8[_0x131351('0x5a5')]['errors'][_0x131351('0x1564')];_0x155976++){_0x4a97a9['error']({'title':_0x210bc8[_0x131351('0x5a5')][_0x131351('0x17f')][_0x155976]['type'],'msg':_0x210bc8[_0x131351('0x5a5')]['errors'][_0x155976][_0x131351('0x8c2')]});}else _0x4a97a9[_0x131351('0x52a')]({'title':_0x210bc8['status']?'API:'+_0x210bc8[_0x131351('0x13ee')]+_0x131351('0xbf6')+_0x210bc8[_0x131351('0x24a9')]:_0x131351('0x259'),'msg':_0x210bc8[_0x131351('0x5a5')]?JSON[_0x131351('0x258a')](_0x210bc8['data'][_0x131351('0x8c2')]):_0x210bc8['message']||_0x210bc8[_0x131351('0x1ff0')]()});});}}});}function _0x2c3a3b(_0x15b6d6,_0x698af2){const _0x340b35=_0x420e8b;_0x5abb08[_0x340b35('0x1d4')]({'controller':_0x340b35('0xebc'),'controllerAs':'vm','templateUrl':_0x1e7ae7,'parent':angular[_0x340b35('0x1fcc')](_0x3dda1e[_0x340b35('0x18e5')]),'clickOutsideToClose':![],'locals':{'account':_0x698af2,'message':{},'type':_0x340b35('0x1476'),'interaction':{}},'fullscreen':!![]})['then'](function(_0x3daac2){const _0x4fcf8e=_0x340b35;if(_0x3daac2){if(_0x3daac2[_0x4fcf8e('0x8c2')]&&_0x3daac2[_0x4fcf8e('0x8c2')][_0x4fcf8e('0x250b')]){const _0x47f986={'channel':'mail','account':_0x698af2,'message':_0x3daac2['message'],'contact':_0x3daac2[_0x4fcf8e('0xd06')]};_0x429d7e['add'](_0x47f986);}else{const _0x1f220c=_0x3daac2;return _0x5e93d1[_0x4fcf8e('0xb87')]['send']({'id':_0x698af2['id']},_0x1f220c)[_0x4fcf8e('0xe53')][_0x4fcf8e('0x683')](function(_0x4312b){const _0xf366cb=_0x4fcf8e;if(_0x4312b&&_0x4312b[_0xf366cb('0xc51')]&&_0x4312b['Messages'][_0xf366cb('0x1564')]){if(_0x1f220c[_0xf366cb('0x1b46')]&&_0x1f220c[_0xf366cb('0x1b46')][_0xf366cb('0x1564')])for(let _0x2da5bc=0x0;_0x2da5bc<_0x1f220c['attachments'][_0xf366cb('0x1564')];_0x2da5bc+=0x1){_0x5e93d1[_0xf366cb('0x34')][_0xf366cb('0x2480')]({'id':_0x1f220c[_0xf366cb('0x1b46')][_0x2da5bc]['id']},{'MailMessageId':_0x2e3ca0()[_0xf366cb('0xd39')](_0x4312b[_0xf366cb('0xc51')])['id']});}_0x4a97a9[_0xf366cb('0x53')]({'title':_0xf366cb('0xb96'),'msg':_0xf366cb('0x21a1')});if(_0x4312b[_0xf366cb('0xd8a')]){_0x4312b['disposition']=null;const _0x5088db=!_0x698af2[_0xf366cb('0x989')],_0x474fb0=_0xc006c5[_0xf366cb('0xc96')][_0xf366cb('0x1431')]||_0xc006c5[_0xf366cb('0xc96')][_0xf366cb('0x1938')]||_0xc006c5[_0xf366cb('0xc96')]['mailPause']||_0xc006c5[_0xf366cb('0xc96')][_0xf366cb('0x1a11')]||_0xc006c5['user']['faxPause'];_0x5abb08[_0xf366cb('0x1d4')]({'controller':_0xf366cb('0x14a7'),'controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular['element'](_0x3dda1e['body']),'onRemoving':function(){const _0x43e3b5=_0xf366cb;_0xc006c5[_0x43e3b5('0xc96')]&&_0x698af2[_0x43e3b5('0x989')]&&!_0x474fb0&&_0x5e93d1[_0x43e3b5('0xc96')][_0x43e3b5('0x1778')]({'id':_0xc006c5[_0x43e3b5('0xc96')]['id']})['$promise'][_0x43e3b5('0x130a')](function(_0x742435){console['error'](_0x742435);});},'clickOutsideToClose':_0x5088db,'escapeToClose':_0x5088db,'locals':{'user':_0xc006c5[_0xf366cb('0xc96')],'channel':_0xf366cb('0x129f'),'interaction':_0x4312b}});}else _0x13ac0e[_0xf366cb('0x1cd5')]['vm'][_0xf366cb('0x297')](_0xf366cb('0x129f'),_0x4312b);}})[_0x4fcf8e('0x130a')](function(_0x365f0e){const _0x1624b9=_0x4fcf8e;if(_0x365f0e[_0x1624b9('0x5a5')]&&_0x365f0e[_0x1624b9('0x5a5')][_0x1624b9('0x17f')]&&_0x365f0e[_0x1624b9('0x5a5')][_0x1624b9('0x17f')][_0x1624b9('0x1564')])for(let _0x22379f=0x0;_0x22379f<_0x365f0e['data']['errors'][_0x1624b9('0x1564')];_0x22379f++){_0x4a97a9[_0x1624b9('0x52a')]({'title':_0x365f0e[_0x1624b9('0x5a5')][_0x1624b9('0x17f')][_0x22379f][_0x1624b9('0xcf0')],'msg':_0x365f0e['data']['errors'][_0x22379f]['message']});}else _0x4a97a9[_0x1624b9('0x52a')]({'title':_0x365f0e[_0x1624b9('0x13ee')]?_0x1624b9('0x2168')+_0x365f0e[_0x1624b9('0x13ee')]+_0x1624b9('0xbf6')+_0x365f0e[_0x1624b9('0x24a9')]:'MAILACCOUNT:SEND','msg':_0x365f0e[_0x1624b9('0x5a5')]?JSON[_0x1624b9('0x258a')](_0x365f0e[_0x1624b9('0x5a5')][_0x1624b9('0x8c2')]):_0x365f0e['message']||_0x365f0e[_0x1624b9('0x1ff0')]()});});}}});}function _0x94a39(_0x252ca4){const _0x8b68de=_0x420e8b;let _0x13a3c7;const _0x15fc05=_0x2e3ca0()[_0x8b68de('0x1c07')](_0xc006c5[_0x8b68de('0xe2')][_0x8b68de('0xf5d')],{'id':_0x252ca4[_0x8b68de('0x7ce')]});_0x15fc05&&_0x15fc05['Users']&&(_0x13a3c7=_0x2e3ca0()[_0x8b68de('0x1c07')](_0x15fc05['Users'],{'id':_0x252ca4[_0x8b68de('0x10c5')]}),!_0x13a3c7&&_0x15fc05['Users']['push']({'id':_0x252ca4[_0x8b68de('0x10c5')]}));}function _0x523675(_0x38106c){const _0x5f7dc7=_0x420e8b,_0x72f1c2=_0x2e3ca0()['find'](_0xc006c5['mailInteractions']['rows'],{'id':_0x38106c[_0x5f7dc7('0x7ce')]});_0x72f1c2&&_0x72f1c2[_0x5f7dc7('0x2139')]&&_0x2e3ca0()[_0x5f7dc7('0x3ec')](_0x72f1c2['Users'],{'id':_0x38106c[_0x5f7dc7('0x10c5')]});}function _0x316038(_0x18ff80){const _0x234ab7=_0x420e8b;if(_0x18ff80){const _0x15f47b=_0x2e3ca0()['find'](_0xc006c5[_0x234ab7('0xe2')][_0x234ab7('0xf5d')],{'id':_0x18ff80['id']});if(_0x15f47b){_0x15f47b[_0x234ab7('0x2139')]=[];_0x18ff80[_0x234ab7('0xd8a')]&&(_0x15f47b[_0x234ab7('0x122e')]=0x0);if(_0xc006c5[_0x234ab7('0x23a2')]['sort']){const _0x420a22=_0x2e3ca0()['startsWith'](_0xc006c5[_0x234ab7('0x23a2')][_0x234ab7('0x671')],'-')?'desc':_0x234ab7('0xe38');_0xc006c5['mailInteractions'][_0x234ab7('0xf5d')]=_0x2e3ca0()['orderBy'](_0xc006c5[_0x234ab7('0xe2')][_0x234ab7('0xf5d')],_0x2e3ca0()[_0x234ab7('0x1fe0')](_0xc006c5[_0x234ab7('0x23a2')][_0x234ab7('0x671')],'-'),_0x420a22);}_0x2e3ca0()[_0x234ab7('0xf22')](_0x15f47b,_0x2e3ca0()[_0x234ab7('0x24d0')](_0x18ff80,_0x2e3ca0()[_0x234ab7('0x55e')](_0x15f47b)));}else _0x52f31f(_0xc006c5['query'][_0x234ab7('0xdf8')]);}}function _0x542859(_0x52c91a){const _0x17d045=_0x420e8b;if(_0x52c91a){const _0x4318a6=_0x2e3ca0()[_0x17d045('0x1c07')](_0xc006c5[_0x17d045('0xe2')][_0x17d045('0xf5d')],{'id':_0x52c91a['id']});_0x4318a6&&(_0x4318a6[_0x17d045('0x198f')]=_0x52c91a[_0x17d045('0x1ce6')]||[],_0x2e3ca0()[_0x17d045('0xf22')](_0x4318a6,_0x2e3ca0()['pick'](_0x52c91a,_0x2e3ca0()[_0x17d045('0x55e')](_0x4318a6))));}}function _0x1e71ac(_0x77624){const _0x5168a0=_0x420e8b;if(_0x77624&&!_0x77624[_0x5168a0('0x252d')]){const _0x130a3a=_0x2e3ca0()[_0x5168a0('0x1c07')](_0xc006c5[_0x5168a0('0xe2')][_0x5168a0('0xf5d')],{'id':_0x77624[_0x5168a0('0x7ce')]});if(_0x130a3a){const _0x3f2847=_0x2e3ca0()[_0x5168a0('0x1c07')](_0x130a3a['Messages'],{'id':_0x77624['id']});_0x3f2847?_0x2e3ca0()['merge'](_0x3f2847,_0x2e3ca0()[_0x5168a0('0x24d0')](_0x77624,_0x2e3ca0()[_0x5168a0('0x55e')](_0x3f2847))):(_0x2e3ca0()[_0x5168a0('0x8f2')](_0x130a3a[_0x5168a0('0xc51')])&&(_0x130a3a[_0x5168a0('0xc51')]={'count':0x0}),!_0x77624[_0x5168a0('0x20db')]&&(_0x130a3a['Messages'][_0x5168a0('0x50d')]+=0x1));}}}function _0x4e09d(){const _0x326f70=_0x420e8b;_0xc006c5[_0x326f70('0x1b8f')]=![];}function _0x130792(){const _0x56559d=_0x420e8b;_0xc006c5[_0x56559d('0x1b8f')]=!![];}function _0x8d890e(){const _0x2ffd8b=_0x420e8b;_0xc006c5[_0x2ffd8b('0x1b8f')]=![],_0x5abb08[_0x2ffd8b('0x1d4')]({'controller':'AdvancedSearchController','controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x2ffd8b('0x1fcc')](_0x3dda1e[_0x2ffd8b('0x18e5')]),'clickOutsideToClose':![],'locals':{'color':_0xc006c5[_0x2ffd8b('0xd10')],'fields':_0xc006c5['advancedSearch'][_0x2ffd8b('0x189a')],'storagePath':'home.mail'},'fullscreen':!![]})[_0x2ffd8b('0x683')](function(_0x59fb68){const _0x4831ec=_0x2ffd8b;_0xc006c5[_0x4831ec('0x23a2')][_0x4831ec('0x19a4')]=_0x59fb68===![]?undefined:_0x59fb68;if(_0xc006c5[_0x4831ec('0x23a2')]['search']||_0x59fb68===![])_0x52f31f();})[_0x2ffd8b('0x130a')](function(_0x5a6e20){const _0x70013c=_0x2ffd8b;_0x4a97a9[_0x70013c('0x52a')]({'title':'ERROR','msg':_0x5a6e20[_0x70013c('0x5a5')]?JSON[_0x70013c('0x258a')](_0x5a6e20[_0x70013c('0x5a5')]['message']):_0x5a6e20[_0x70013c('0x1ff0')]()});});}let _0x352a8d=!![],_0x2b3b42=0x1;_0x13ac0e['$watch']('vm.query.filter',function(_0x5ecd26,_0x27b284){const _0x692af=_0x420e8b;_0x352a8d?_0x49d566(function(){_0x352a8d=![];}):(!_0x27b284&&(_0x2b3b42=_0xc006c5[_0x692af('0x23a2')][_0x692af('0xdf8')]),_0x5ecd26!==_0x27b284&&(_0xc006c5[_0x692af('0x23a2')]['page']=0x1),!_0x5ecd26&&(_0xc006c5['query'][_0x692af('0xdf8')]=_0x2b3b42),_0x52f31f(_0xc006c5['query'][_0x692af('0xdf8')]));}),_0x13ac0e[_0x420e8b('0x26a2')](_0x420e8b('0x4b8'),function(){const _0x2f5b79=_0x420e8b;_0x48d6ce[_0x2f5b79('0x1b9e')]('mailMessage:save'),_0x48d6ce[_0x2f5b79('0x1b9e')](_0x2f5b79('0xc4c')),_0x48d6ce[_0x2f5b79('0x1b9e')]('mailInteraction:save'),_0x48d6ce[_0x2f5b79('0x1b9e')](_0x2f5b79('0x895')),_0x48d6ce[_0x2f5b79('0x1b9e')](_0x2f5b79('0xc75')),_0x48d6ce[_0x2f5b79('0x1b9e')](_0x2f5b79('0x1c95')),_0x48d6ce[_0x2f5b79('0x1b9e')](_0x2f5b79('0x2301'));});}const _0x3442cf=_0x2a9a31;_0x18d9ef[_0x189033('0x14be')]=[_0x189033('0x16ea'),_0x189033('0x7a5'),'$timeout',_0x189033('0x1e48'),_0x189033('0xba1'),_0x189033('0x56b'),'$window',_0x189033('0x1d70')];function _0x18d9ef(_0x148e75,_0x3bcd17,_0x5de7b1,_0x2e0391,_0x2d384c,_0x3df819,_0x5301bb,_0x302619){const _0x202258=_0x189033,_0xa93b54=this;_0xa93b54[_0x202258('0x11ed')]=_0x2d384c['getCurrentUser'](),_0xa93b54[_0x202258('0xe01')]={},_0xa93b54[_0x202258('0x6d5')]={'count':0x0,'rows':[]},_0xa93b54['tags']={'count':0x0,'rows':[]},_0xa93b54[_0x202258('0x23a2')]={'includeAll':!![],'id':_0xa93b54[_0x202258('0x11ed')]['id'],'sort':_0x202258('0xc36'),'limit':0xa,'page':0x1},_0xa93b54[_0x202258('0x19c9')]={'fields':[]},_0xa93b54['sectionColor']='red',_0xa93b54[_0x202258('0x16cb')]=_0xc1551c,_0xa93b54[_0x202258('0x985')]=_0x22f761,_0xa93b54[_0x202258('0x54e')]=_0x422505,_0xa93b54[_0x202258('0x1453')]=_0x413c6f,_0xa93b54[_0x202258('0x18e3')]=_0x49148e,_0xa93b54[_0x202258('0x164f')]=_0x3bcd17[_0x202258('0x1cd5')]['vm'][_0x202258('0x164f')],_0xa93b54[_0x202258('0x1dd2')]=_0x597141,_0xa93b54['onSearchBarCollapse']=_0x1a122d,_0xa93b54[_0x202258('0x229d')]=_0x18bda9,_0xa93b54[_0x202258('0x2121')]=_0xe975d7;function _0x597141(){const _0x59071f=_0x202258;_0x3df819['cmList'][_0x59071f('0x1e6e')]({'fields':'id,name,dialPrefix','sort':_0x59071f('0x60a'),'nolimit':!![]})[_0x59071f('0xe53')][_0x59071f('0x683')](function(_0xca0510){const _0x56f367=_0x59071f;return _0xa93b54[_0x56f367('0xe01')]=_0xca0510||{'count':0x0,'rows':[]},_0xa93b54[_0x56f367('0x74e')]=_0x2e3ca0()[_0x56f367('0x24db')](_0xa93b54[_0x56f367('0xe01')][_0x56f367('0xf5d')],'id'),_0x3df819[_0x56f367('0x270')]['get']()[_0x56f367('0xe53')];})[_0x59071f('0x683')](function(_0x2976b2){const _0x9397d5=_0x59071f;_0xa93b54[_0x9397d5('0x1ce6')]=_0x2976b2||{'count':0x0,'rows':[]};})[_0x59071f('0x683')](function(){_0xa93b54['quickFilters']=_0x1c5705();})[_0x59071f('0x130a')](function(_0x4b447e){const _0x5a4c21=_0x59071f;console[_0x5a4c21('0x52a')](_0x4b447e);})[_0x59071f('0x2874')](function(){const _0x1d0c6f=_0x59071f;let _0x141730=_0x5301bb[_0x1d0c6f('0x120e')][_0x1d0c6f('0x1b28')](_0x1d0c6f('0x2397')+_0xa93b54[_0x1d0c6f('0x11ed')]['id']);if(_0x141730)try{_0x141730=JSON[_0x1d0c6f('0x1f34')](_0x141730);if(_0x141730[_0x1d0c6f('0x23a2')]){_0xa93b54[_0x1d0c6f('0x23a2')]=_0x2e3ca0()['merge'](_0xa93b54[_0x1d0c6f('0x23a2')],_0x141730[_0x1d0c6f('0x23a2')]);if(_0x2e3ca0()[_0x1d0c6f('0x173f')](_0xa93b54[_0x1d0c6f('0xe01')][_0x1d0c6f('0xf5d')]))_0xa93b54[_0x1d0c6f('0x23a2')][_0x1d0c6f('0x1e4f')]=[];else _0x2e3ca0()[_0x1d0c6f('0x173f')](_0xa93b54[_0x1d0c6f('0x23a2')][_0x1d0c6f('0x1e4f')])&&(_0xa93b54[_0x1d0c6f('0x23a2')][_0x1d0c6f('0x1e4f')]=_0x2e3ca0()(_0xa93b54[_0x1d0c6f('0xe01')]['rows'])[_0x1d0c6f('0x386')]('id')[_0x1d0c6f('0x22c8')]()[_0x1d0c6f('0x1c6b')]());}}catch(_0x198574){console[_0x1d0c6f('0x52a')](_0x198574);}else _0xa93b54[_0x1d0c6f('0x23a2')][_0x1d0c6f('0x1e4f')]=_0x2e3ca0()[_0x1d0c6f('0x386')](_0xa93b54[_0x1d0c6f('0xe01')][_0x1d0c6f('0xf5d')],'id');_0xa93b54[_0x1d0c6f('0x1b8f')]=_0xa93b54[_0x1d0c6f('0x23a2')][_0x1d0c6f('0x25')]?!![]:![],_0xc1551c();});}function _0x1c5705(){const _0x1e8424=_0x202258;return[{'name':_0x1e8424('0x26da'),'key':'ListId','type':_0x1e8424('0xf6c'),'label':'CONTACTMANAGER.SELECT_LIST','options':_0xa93b54[_0x1e8424('0xe01')]['rows'],'clearAll':![]},{'name':_0x1e8424('0x1e'),'key':_0x1e8424('0x270'),'type':_0x1e8424('0xf6c'),'label':_0x1e8424('0x2264'),'options':_0xa93b54['tags'][_0x1e8424('0xf5d')],'placeholder':_0x1e8424('0x7cb')}];}function _0x2a8ec0(_0x35ce42){_0xa93b54['searchInProgress']=![],_0xa93b54['contacts']=_0x35ce42||{'count':0x0,'rows':[]};}function _0xc1551c(_0x1d03ae){const _0x2c2e51=_0x202258;_0xa93b54['searchInProgress']=!![],_0x3f9e36();!_0x1d03ae&&(_0xa93b54[_0x2c2e51('0x23a2')][_0x2c2e51('0xdf8')]=0x1);_0xa93b54['query'][_0x2c2e51('0x1cc8')]=(_0xa93b54[_0x2c2e51('0x23a2')][_0x2c2e51('0xdf8')]-0x1)*_0xa93b54['query'][_0x2c2e51('0x6f0')];let _0x327943=_0x5301bb['localStorage'][_0x2c2e51('0x1b28')]('motion2.home.mycontacts:'+_0xa93b54[_0x2c2e51('0x11ed')]['id']);_0x327943=_0x327943?JSON[_0x2c2e51('0x1f34')](_0x327943):{},_0x327943[_0x2c2e51('0x23a2')]=_0xa93b54['query'],_0x5301bb[_0x2c2e51('0x120e')][_0x2c2e51('0x15d')](_0x2c2e51('0x2397')+_0xa93b54[_0x2c2e51('0x11ed')]['id'],JSON[_0x2c2e51('0x258a')](_0x327943));if(_0xa93b54['query']['search'])_0xa93b54[_0x2c2e51('0x142e')]=_0x2e3ca0()['omit'](_0xa93b54['query'],'id');_0xa93b54[_0x2c2e51('0x1883')]=_0xa93b54[_0x2c2e51('0x23a2')][_0x2c2e51('0x19a4')]?_0x3df819[_0x2c2e51('0x276e')][_0x2c2e51('0x1e6e')](_0xa93b54[_0x2c2e51('0x142e')],_0x2a8ec0)[_0x2c2e51('0xe53')]:_0x3df819[_0x2c2e51('0xc96')][_0x2c2e51('0x16cb')](_0xa93b54[_0x2c2e51('0x23a2')],_0x2a8ec0)[_0x2c2e51('0xe53')];}function _0x49148e(_0x277bf8,_0xd9456d){_0x3bcd17['$parent']['vm']['addContactTab'](_0xd9456d);}function _0x22f761(){_0xc1551c();}function _0x413c6f(_0x54a3e1,_0x49e633){const _0x5446c7=_0x202258;_0x2e0391[_0x5446c7('0x1d4')]({'controller':_0x5446c7('0x1757'),'controllerAs':'vm','templateUrl':_0x24dbc7,'parent':angular[_0x5446c7('0x1fcc')](_0x148e75['body']),'targetEvent':_0x54a3e1,'clickOutsideToClose':!![],'resolve':{'contact':[_0x5446c7('0x4b1'),function(_0x55d20e){const _0x200cd6=_0x5446c7;return _0x55d20e[_0x200cd6('0xed7')](_0x200cd6('0x23ec'),{'id':_0x49e633['id']});}],'lists':['apiResolver',function(_0x521e44){const _0x4f5cdc=_0x5446c7;return _0x521e44[_0x4f5cdc('0xed7')](_0x4f5cdc('0x2001'),{'id':_0xa93b54['currentUser']['id'],'fields':_0x4f5cdc('0xa10')});}]},'locals':{'contacts':_0xa93b54[_0x5446c7('0x6d5')][_0x5446c7('0xf5d')]}});}function _0x422505(_0x14a69c,_0x5eede8){const _0x4fe25d=_0x202258;_0x2e0391[_0x4fe25d('0x1d4')]({'controller':_0x4fe25d('0x264'),'controllerAs':'vm','templateUrl':_0x7650f,'parent':angular['element'](_0x148e75['body']),'targetEvent':_0x14a69c,'clickOutsideToClose':!![],'resolve':{'contact':[_0x4fe25d('0x4b1'),function(_0x3fef03){const _0x5e0f15=_0x4fe25d;return _0x3fef03['resolve'](_0x5e0f15('0x23ec'),{'id':_0x5eede8['id']});}],'lists':['apiResolver',function(_0x1f4424){const _0x4aa30b=_0x4fe25d;return _0x1f4424[_0x4aa30b('0xed7')](_0x4aa30b('0x2001'),{'id':_0xa93b54[_0x4aa30b('0x11ed')]['id'],'fields':_0x4aa30b('0xa10')});}]},'locals':{'contacts':_0xa93b54[_0x4fe25d('0x6d5')][_0x4fe25d('0xf5d')]}});}function _0x1a122d(){const _0x2885f7=_0x202258;_0xa93b54[_0x2885f7('0x1b8f')]=![];}function _0x18bda9(){const _0x4195bb=_0x202258;_0xa93b54[_0x4195bb('0x1b8f')]=!![];}function _0x3f9e36(){const _0x59fcf7=_0x202258;return _0x3df819[_0x59fcf7('0x276e')]['describe']({'id':_0xa93b54[_0x59fcf7('0x23a2')][_0x59fcf7('0x1e4f')]})[_0x59fcf7('0xe53')][_0x59fcf7('0x683')](function(_0x4230fd){const _0x32fbe7=_0x59fcf7;return _0x2e3ca0()(_0x4230fd[_0x32fbe7('0x24e1')]())['omit'](_0x32fbe7('0x10c5'))[_0x32fbe7('0x17a0')]()[_0x32fbe7('0x386')](function(_0x4479a5){return _0x1bda44(_0x4479a5);})[_0x32fbe7('0x1c6b')]();})[_0x59fcf7('0x683')](function(_0x31da74){const _0x363be5=_0x59fcf7;_0xa93b54['advancedSearch'][_0x363be5('0x189a')]=_0x31da74;const _0x42fa82={'name':_0x363be5('0x198f'),'column':'Tag','type':_0x363be5('0xf6c'),'options':{'route':{'model':_0x363be5('0x270'),'action':_0x363be5('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x363be5('0x1479')]}};let _0x4b50e8=_0x2e3ca0()[_0x363be5('0x1ce4')](_0x31da74,function(_0x1b3235){const _0x34427d=_0x363be5;return _0x2e3ca0()[_0x34427d('0x18ad')](_0x1b3235[_0x34427d('0x2008')],_0x34427d('0x1469'));})||_0x31da74['length']-0x1;if(_0x4b50e8<0x0)_0x4b50e8=_0x31da74['length'];_0xa93b54['advancedSearch'][_0x363be5('0x189a')][_0x363be5('0x2040')](_0x4b50e8,0x0,_0x42fa82);})[_0x59fcf7('0x130a')](function(_0x492025){const _0x2d9853=_0x59fcf7;_0x302619[_0x2d9853('0x52a')]({'title':_0x492025['status']?_0x2d9853('0x2168')+_0x492025['status']+_0x2d9853('0xbf6')+_0x492025[_0x2d9853('0x24a9')]:'DESCRIBE_CM_CONTACTS','msg':_0x492025[_0x2d9853('0x5a5')]?JSON['stringify'](_0x492025[_0x2d9853('0x5a5')][_0x2d9853('0x8c2')]):_0x492025[_0x2d9853('0x1ff0')]()});});}function _0x1bda44(_0xc72592){const _0x5769d9=_0x202258,_0x196c39={'name':_0x2e3ca0()[_0x5769d9('0x1e03')](_0xc72592[_0x5769d9('0x162d')]),'column':_0xc72592[_0x5769d9('0xa99')],'options':{}};if(_0xc72592[_0x5769d9('0xbf0')])switch(_0xc72592[_0x5769d9('0xbf0')][_0x5769d9('0xcf0')]){case _0x5769d9('0x1bcd'):_0x196c39[_0x5769d9('0xcf0')]=_0x5769d9('0x1bcd');break;case'select':_0x196c39[_0x5769d9('0xcf0')]=_0x5769d9('0xf6c'),_0x196c39[_0x5769d9('0x17a0')]=_0x2e3ca0()[_0x5769d9('0x386')](JSON[_0x5769d9('0x1f34')](_0xc72592['custom']['values']),function(_0x1e6ac3,_0x2c92a4){const _0x5f2644=_0x5769d9;return{'id':_0x2c92a4,'name':_0x1e6ac3[_0x5f2644('0x1c6b')],'value':_0x1e6ac3[_0x5f2644('0x1c6b')]};}),_0x196c39['options']['field']=_0x5769d9('0x60a');break;case'switch':_0x196c39['type']=_0x5769d9('0xb31'),_0x196c39['values']=[{'id':0x1,'translate':_0x5769d9('0x1a96')},{'id':0x0,'translate':_0x5769d9('0x240b')}],_0x196c39[_0x5769d9('0x158e')][_0x5769d9('0x2818')]=['$ne'];break;case _0x5769d9('0x121f'):_0x196c39['type']='number';break;case _0x5769d9('0x13a8'):_0x196c39[_0x5769d9('0xcf0')]=_0x5769d9('0x270e');break;}else switch(_0xc72592[_0x5769d9('0xa99')]){case _0x5769d9('0x26a7'):_0x196c39[_0x5769d9('0xcf0')]='date';break;case _0x5769d9('0x2883'):_0x196c39['name']=_0x5769d9('0x1c9'),_0x196c39[_0x5769d9('0xcf0')]=_0x5769d9('0xeb'),_0x196c39['options'][_0x5769d9('0x20ed')]={'model':_0x5769d9('0x27db'),'action':'get','params':{'fields':_0x5769d9('0xa10'),'nolimit':!![]}},_0x196c39['options'][_0x5769d9('0x177c')]=[_0x5769d9('0x60a')],_0x196c39[_0x5769d9('0x158e')][_0x5769d9('0x2818')]=[_0x5769d9('0x17ee')];break;case'ListId':_0x196c39[_0x5769d9('0x60a')]='List',_0x196c39['type']=_0x5769d9('0xeb'),_0x196c39[_0x5769d9('0x158e')]['route']={'model':_0x5769d9('0xc96'),'action':_0x5769d9('0x16c3'),'params':{'id':_0xa93b54['currentUser']['id'],'fields':'id,name','nolimit':!![]}},_0x196c39[_0x5769d9('0x158e')]['searchFields']=[_0x5769d9('0x60a')],_0x196c39['options']['excludedOperators']=[_0x5769d9('0x17ee')];break;default:if(_0x2e3ca0()[_0x5769d9('0x2292')](_0xc72592['type'][_0x5769d9('0x93a')](),_0x5769d9('0x1d17')))_0x196c39['type']='number';else _0x2e3ca0()[_0x5769d9('0x2292')](_0xc72592['type']['toLowerCase'](),'date')?_0x196c39['type']=_0x5769d9('0x270e'):_0x196c39['type']=_0x5769d9('0x1bcd');break;}return _0x196c39;}function _0xe975d7(){const _0x104aff=_0x202258;_0xa93b54[_0x104aff('0x1b8f')]=![],_0x2e0391[_0x104aff('0x1d4')]({'controller':'AdvancedSearchController','controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x104aff('0x1fcc')](_0x148e75['body']),'clickOutsideToClose':![],'locals':{'color':_0xa93b54[_0x104aff('0xd10')],'fields':_0xa93b54[_0x104aff('0x19c9')][_0x104aff('0x189a')],'storagePath':_0x104aff('0x1f75')},'fullscreen':!![]})[_0x104aff('0x683')](function(_0x236891){const _0x2cdcad=_0x104aff;_0xa93b54[_0x2cdcad('0x23a2')]['search']=_0x236891===![]?undefined:_0x236891;if(_0x236891===![])_0xc1551c();else _0xa93b54['query'][_0x2cdcad('0x19a4')]&&(_0xa93b54[_0x2cdcad('0x23a2')][_0x2cdcad('0x19a4')]+=_0x2cdcad('0x1fe5')+_0xa93b54[_0x2cdcad('0x11ed')]['id']+']',_0xc1551c());})['catch'](function(_0x96c6e1){const _0x23cafb=_0x104aff;_0x302619[_0x23cafb('0x52a')]({'title':_0x23cafb('0x1119'),'msg':_0x96c6e1[_0x23cafb('0x5a5')]?JSON['stringify'](_0x96c6e1[_0x23cafb('0x5a5')]['message']):_0x96c6e1[_0x23cafb('0x1ff0')]()});});}let _0x54572b=!![],_0x3ca78a=0x1;_0x3bcd17[_0x202258('0x186d')](_0x202258('0x1e1d'),function(_0x5843bf,_0x6689b){const _0x33fdff=_0x202258;_0x54572b?_0x5de7b1(function(){_0x54572b=![];}):(!_0x6689b&&(_0x3ca78a=_0xa93b54[_0x33fdff('0x23a2')][_0x33fdff('0xdf8')]),_0x5843bf!==_0x6689b&&(_0xa93b54['query'][_0x33fdff('0xdf8')]=0x1),!_0x5843bf&&(_0xa93b54[_0x33fdff('0x23a2')][_0x33fdff('0xdf8')]=_0x3ca78a),_0xc1551c());});}const _0x15ab48=_0x18d9ef;_0x323e5a['$inject']=['$scope',_0x189033('0x2f9'),_0x189033('0x1e48'),'$document',_0x189033('0x2063'),'$translate',_0x189033('0x56b'),'Auth',_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x1777')];function _0x323e5a(_0x4e676a,_0x5e2a7b,_0x1b69b5,_0x1446c0,_0x59837c,_0x1e5394,_0x12908c,_0x3ff7bb,_0xc362ae,_0x232dbb,_0x26bbcb){const _0x3f1dba=_0x189033,_0x150d92=this;_0x150d92[_0x3f1dba('0xc96')]=_0x3ff7bb['getCurrentUser'](),_0x150d92[_0x3f1dba('0xace')]={},_0x150d92[_0x3f1dba('0x260a')]={},_0x150d92[_0x3f1dba('0x1ce6')]={'count':0x0,'rows':[]},_0x150d92['openchannelInteractions']={'count':0x0,'rows':[]},_0x150d92[_0x3f1dba('0x23a2')]={'includeAll':!![],'sort':_0x3f1dba('0xc36'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x150d92['advancedSearch']={'fields':[{'name':'Id','column':'id','type':_0x3f1dba('0x121f')},{'name':'Contact','column':_0x3f1dba('0x1309'),'type':_0x3f1dba('0xeb'),'options':{'searchFields':[_0x3f1dba('0xeef'),_0x3f1dba('0x510'),'email'],'route':{'model':_0x3f1dba('0x276e'),'action':_0x3f1dba('0x1e6e'),'params':{'fields':_0x3f1dba('0x8ff'),'Contact':'@autocomplete','nolimit':!![]}},'extraOperators':['$substring'],'excludedOperators':[_0x3f1dba('0x17ee')]}},{'name':_0x3f1dba('0x1765'),'column':_0x3f1dba('0x18e5'),'type':'text','options':{'excludedOperators':[_0x3f1dba('0x393'),_0x3f1dba('0x17ee')]}},{'name':'Status','column':_0x3f1dba('0xd8a'),'type':'select','values':[{'id':0x0,'translate':'DASHBOARDS.OPENED'},{'id':0x1,'translate':_0x3f1dba('0x270a')}],'options':{'excludedOperators':['$ne']}},{'name':_0x3f1dba('0x62c'),'column':_0x3f1dba('0x1dad'),'type':'autocomplete','options':{'table':'i','route':{'model':'user','action':'get','params':{'role':'agent','fields':'id,name,fullname','nolimit':!![]}},'searchFields':['fullname','name'],'extraOperators':[_0x3f1dba('0xe55')],'excludedOperators':[_0x3f1dba('0x17ee')]}},{'name':_0x3f1dba('0xa78'),'column':'OpenchannelAccountId','type':_0x3f1dba('0xf6c'),'options':{'route':{'model':_0x3f1dba('0xc96'),'action':'getOpenchannelAccounts','params':{'id':_0x150d92[_0x3f1dba('0xc96')]['id'],'nolimit':!![]}}}},{'name':_0x3f1dba('0x198f'),'column':_0x3f1dba('0x1e'),'type':_0x3f1dba('0xf6c'),'options':{'route':{'model':'tag','action':_0x3f1dba('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x3f1dba('0x1479')]}},{'name':_0x3f1dba('0x10c1'),'column':_0x3f1dba('0x1a4'),'type':_0x3f1dba('0x270e'),'options':{'excludedOperators':[_0x3f1dba('0x17ee')]}},{'name':'Read','column':_0x3f1dba('0x122e'),'type':'select','values':[{'id':0x1,'translate':'DASHBOARDS.READ'},{'id':0x0,'translate':_0x3f1dba('0x2226')}],'options':{'excludedOperators':[_0x3f1dba('0x17ee')]}}]},_0x150d92[_0x3f1dba('0xd10')]='amber',_0x150d92[_0x3f1dba('0x1dd2')]=_0x276092,_0x150d92[_0x3f1dba('0x53')]=_0x239fcf,_0x150d92[_0x3f1dba('0x1710')]=_0x16414c,_0x150d92[_0x3f1dba('0x1648')]=_0x4cfa8f,_0x150d92['downloadOpenchannelInteraction']=_0x209978,_0x150d92[_0x3f1dba('0x14b7')]=_0x211b48,_0x150d92[_0x3f1dba('0x1dd3')]=_0x1ca474,_0x150d92[_0x3f1dba('0x2084')]=_0x31946f,_0x150d92[_0x3f1dba('0x141e')]=_0x4d2745,_0x150d92['composeOpenchannelInteraction']=_0x5bc738,_0x150d92[_0x3f1dba('0xb65')]=_0x2497d6,_0x150d92[_0x3f1dba('0x229d')]=_0xf1002d,_0x150d92[_0x3f1dba('0x2121')]=_0x247f61;function _0x276092(_0x488dc8,_0x34cdc6){const _0x132ae3=_0x3f1dba;return _0x150d92['license']=_0x488dc8,_0x150d92[_0x132ae3('0x260a')]=_0x34cdc6,_0x12908c[_0x132ae3('0xc96')][_0x132ae3('0x1e6e')+_0x2e3ca0()[_0x132ae3('0x2711')](_0x132ae3('0x1952'))]({'id':_0x150d92['user']['id'],'nolimit':!![]})[_0x132ae3('0xe53')][_0x132ae3('0x683')](function(_0x54999a){const _0x5efe80=_0x132ae3;return _0x150d92['openchannelAccounts']=_0x54999a||{'count':0x0,'rows':[]},_0x12908c[_0x5efe80('0x270')]['get']()['$promise'];})[_0x132ae3('0x683')](function(_0x191423){_0x150d92['tags']=_0x191423||{'count':0x0,'rows':[]};})['then'](function(){_0x150d92['quickFilters']=_0xc61600();})[_0x132ae3('0x130a')](function(_0x4ad270){const _0x29bab8=_0x132ae3;console[_0x29bab8('0x52a')](_0x4ad270);})['finally'](function(){const _0x71e9ac=_0x132ae3;let _0x415616=_0x59837c[_0x71e9ac('0x120e')][_0x71e9ac('0x1b28')](_0x71e9ac('0x246')+_0x150d92[_0x71e9ac('0xc96')]['id']);if(_0x415616)try{_0x415616=JSON[_0x71e9ac('0x1f34')](_0x415616);if(_0x415616['query']){_0x150d92['query']=_0x2e3ca0()[_0x71e9ac('0xf22')](_0x150d92[_0x71e9ac('0x23a2')],_0x415616['query']);if(_0x2e3ca0()['isEmpty'](_0x150d92['openchannelAccounts'][_0x71e9ac('0xf5d')]))_0x150d92[_0x71e9ac('0x23a2')][_0x71e9ac('0x1061')]=[];else _0x2e3ca0()[_0x71e9ac('0x173f')](_0x150d92[_0x71e9ac('0x23a2')]['OpenchannelAccountId'])&&(_0x150d92['query'][_0x71e9ac('0x1061')]=_0x2e3ca0()(_0x150d92['openchannelAccounts'][_0x71e9ac('0xf5d')])[_0x71e9ac('0x386')]('id')[_0x71e9ac('0x22c8')]()['value']());_0x150d92[_0x71e9ac('0x23a2')]['sort']&&_0x150d92[_0x71e9ac('0x23a2')][_0x71e9ac('0x671')]['indexOf']('lastMessage')>=0x0&&(_0x150d92[_0x71e9ac('0x23a2')]=_0x2e3ca0()['omit'](_0x150d92[_0x71e9ac('0x23a2')],_0x71e9ac('0x671'))),_0x150d92[_0x71e9ac('0x23a2')][_0x71e9ac('0x2761')]=!![],_0x150d92['isSearchBarVisible']=_0x150d92['query'][_0x71e9ac('0x25')]?!![]:![];}}catch(_0x4210e1){console[_0x71e9ac('0x52a')](_0x4210e1);}else{const _0x5237eb={'$gte':_0x1aaf93()()['startOf']('month')[_0x71e9ac('0xb11')](0x0,!![])[_0x71e9ac('0x26dd')](),'$lte':_0x1aaf93()()[_0x71e9ac('0x3b3')](_0x71e9ac('0x55b'))[_0x71e9ac('0xb11')](0x0,!![])[_0x71e9ac('0x26dd')]()},_0x62c859={'OpenchannelAccountId':_0x2e3ca0()[_0x71e9ac('0x386')](_0x150d92[_0x71e9ac('0x1952')][_0x71e9ac('0xf5d')],'id'),'createdAt':_0x5237eb};_0x150d92[_0x71e9ac('0x23a2')]=_0x2e3ca0()[_0x71e9ac('0xf22')](_0x150d92[_0x71e9ac('0x23a2')],_0x62c859);}_0xc362ae['on'](_0x71e9ac('0x14dc'),_0x238fff),_0xc362ae['on'](_0x71e9ac('0x775'),_0x238fff),_0xc362ae['on'](_0x71e9ac('0x175'),_0x595b9f),_0xc362ae['on'](_0x71e9ac('0x642'),_0x32bb42),_0xc362ae['on'](_0x71e9ac('0x1318'),_0x32bb42),_0xc362ae['on']('user_has_openchannel_interactions:save',_0x511c7c),_0xc362ae['on'](_0x71e9ac('0x1e90'),_0x41c18c),_0x16414c(_0x150d92[_0x71e9ac('0x23a2')][_0x71e9ac('0xdf8')]);});}function _0xc61600(){const _0x1a4067=_0x3f1dba;return[{'name':_0x1a4067('0x10c1'),'key':_0x1a4067('0x1a4'),'type':'date','label':'DASHBOARDS.SELECT_DATE'},{'name':_0x1a4067('0xc51'),'key':_0x1a4067('0x20db'),'type':'select','label':'DASHBOARDS.SELECT_READ_UNREAD','customOptions':[{'value':0x0,'translate':_0x1a4067('0x2226')},{'value':0x1,'translate':_0x1a4067('0x38f')},{'value':null,'translate':'DASHBOARDS.ALL'}]},{'name':'Status','key':_0x1a4067('0xd8a'),'type':_0x1a4067('0xb31'),'label':'DASHBOARDS.SELECT_STATUS','customOptions':[{'value':0x0,'translate':'DASHBOARDS.OPENED'},{'value':0x1,'translate':_0x1a4067('0x270a')},{'value':null,'translate':_0x1a4067('0x475')}]},{'name':'Account','key':_0x1a4067('0x1061'),'type':_0x1a4067('0xf6c'),'label':_0x1a4067('0x1202'),'options':_0x150d92[_0x1a4067('0x1952')][_0x1a4067('0xf5d')],'clearAll':![]},{'name':_0x1a4067('0x62c'),'key':_0x1a4067('0x10c5'),'type':'select','label':'DASHBOARDS.SELECT_AGENT','customOptions':[{'value':_0x150d92[_0x1a4067('0xc96')]['id'],'translate':_0x1a4067('0x96a')},{'value':_0x1a4067('0x13c'),'translate':_0x1a4067('0x2608')},{'value':undefined,'translate':_0x1a4067('0x475')}]},{'name':'Tag','key':_0x1a4067('0x270'),'type':_0x1a4067('0xf6c'),'label':_0x1a4067('0x2264'),'options':_0x150d92[_0x1a4067('0x1ce6')]['rows'],'placeholder':_0x1a4067('0x7cb')}];}function _0x239fcf(_0x1556c6){const _0x27c3b2=_0x3f1dba;_0x150d92['searchInProgress']=![],_0x150d92['openchannelInteractions']=_0x1556c6||{'count':0x0,'rows':[]};for(let _0x55c34d=0x0;_0x55c34d<_0x150d92['openchannelInteractions'][_0x27c3b2('0xf5d')][_0x27c3b2('0x1564')];_0x55c34d+=0x1){_0x1ca474(_0x150d92[_0x27c3b2('0x13f9')][_0x27c3b2('0xf5d')][_0x55c34d]);}}function _0x16414c(_0x4c5d21){const _0x3d325f=_0x3f1dba;_0x150d92['searchInProgress']=!![];!_0x4c5d21&&(_0x150d92[_0x3d325f('0x23a2')][_0x3d325f('0xdf8')]=0x1);_0x150d92[_0x3d325f('0x23a2')]['offset']=(_0x150d92[_0x3d325f('0x23a2')][_0x3d325f('0xdf8')]-0x1)*_0x150d92[_0x3d325f('0x23a2')][_0x3d325f('0x6f0')];let _0x1d273d=_0x59837c['localStorage'][_0x3d325f('0x1b28')](_0x3d325f('0x246')+_0x150d92[_0x3d325f('0xc96')]['id']);_0x1d273d=_0x1d273d?JSON[_0x3d325f('0x1f34')](_0x1d273d):{},_0x1d273d[_0x3d325f('0x23a2')]=_0x150d92[_0x3d325f('0x23a2')],_0x59837c['localStorage'][_0x3d325f('0x15d')](_0x3d325f('0x246')+_0x150d92['user']['id'],JSON[_0x3d325f('0x258a')](_0x1d273d)),_0x150d92[_0x3d325f('0x1883')]=_0x12908c['openchannelInteraction'][_0x3d325f('0x1e6e')](_0x150d92['query'],_0x239fcf)[_0x3d325f('0xe53')];}function _0x4cfa8f(_0x5ea49a,_0xeecad3){const _0x35442b=_0x3f1dba;_0x4e676a[_0x35442b('0x1cd5')]['vm']['addInteractionTab'](_0x35442b('0x1261'),_0xeecad3);}function _0x209978(_0x2b1698,_0x43d20b,_0x5cc619){const _0x44f2a7=_0x3f1dba;_0x12908c[_0x44f2a7('0x17ff')][_0x44f2a7('0x18e8')]({'id':_0x43d20b['id'],'attachments':_0x5cc619})[_0x44f2a7('0xe53')][_0x44f2a7('0x683')](function(_0x353acb){const _0x58b41e=_0x44f2a7,_0xe08b77=[_0x353acb[_0x58b41e('0x1fb3')]],_0xc0d7b8=_0x58b41e('0xcf5')+_0x43d20b['id']+'.zip',_0x574bfe=new Blob(_0xe08b77,{'type':_0x353acb['type']}),_0x268123=window['document'][_0x58b41e('0x1ffa')]('a');_0x268123['setAttribute'](_0x58b41e('0x2767'),URL['createObjectURL'](_0x574bfe)),_0x268123[_0x58b41e('0x130f')](_0x58b41e('0x18e8'),_0xc0d7b8),document[_0x58b41e('0x18e5')][_0x58b41e('0x1e43')](_0x268123),_0x268123['click']();})['catch'](function(_0x109ae7){const _0x4460bf=_0x44f2a7;if(_0x109ae7[_0x4460bf('0x5a5')]&&_0x109ae7['data'][_0x4460bf('0x17f')]&&_0x109ae7[_0x4460bf('0x5a5')][_0x4460bf('0x17f')][_0x4460bf('0x1564')])for(let _0x5f3ef8=0x0;_0x5f3ef8<_0x109ae7[_0x4460bf('0x5a5')][_0x4460bf('0x17f')]['length'];_0x5f3ef8+=0x1){_0x232dbb[_0x4460bf('0x52a')]({'title':_0x109ae7[_0x4460bf('0x5a5')][_0x4460bf('0x17f')][_0x5f3ef8]['type'],'msg':_0x109ae7[_0x4460bf('0x5a5')][_0x4460bf('0x17f')][_0x5f3ef8][_0x4460bf('0x8c2')]});}else _0x232dbb[_0x4460bf('0x52a')]({'title':_0x109ae7[_0x4460bf('0x13ee')]?_0x4460bf('0x2168')+_0x109ae7['status']+_0x4460bf('0xbf6')+_0x109ae7[_0x4460bf('0x24a9')]:_0x4460bf('0x16f8'),'msg':_0x109ae7[_0x4460bf('0x5a5')]?JSON[_0x4460bf('0x258a')](_0x109ae7[_0x4460bf('0x5a5')][_0x4460bf('0x8c2')]):_0x109ae7['toString']()});});}function _0x211b48(_0xe25312,_0x28463a){const _0x2cdeb3=_0x3f1dba,_0x30dcd7=_0x150d92[_0x2cdeb3('0xc96')][_0x2cdeb3('0x1431')]||_0x150d92[_0x2cdeb3('0xc96')]['chatPause']||_0x150d92[_0x2cdeb3('0xc96')][_0x2cdeb3('0x774')]||_0x150d92['user'][_0x2cdeb3('0x1a11')]||_0x150d92['user'][_0x2cdeb3('0x716')],_0x486f27=!_0x28463a[_0x2cdeb3('0xa78')][_0x2cdeb3('0x989')];_0x1b69b5[_0x2cdeb3('0x1d4')]({'controller':'DisposeInteractionDialogController','controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular[_0x2cdeb3('0x1fcc')](_0x1446c0[_0x2cdeb3('0x18e5')]),'clickOutsideToClose':_0x486f27,'escapeToClose':_0x486f27,'onRemoving':function(){const _0x182082=_0x2cdeb3;_0x150d92[_0x182082('0xc96')]&&_0x28463a[_0x182082('0xa78')][_0x182082('0x989')]&&!_0x30dcd7&&_0x12908c[_0x182082('0xc96')][_0x182082('0x1778')]({'id':_0x150d92[_0x182082('0xc96')]['id']})[_0x182082('0xe53')]['catch'](function(_0x5d0d46){const _0x39bdce=_0x182082;console[_0x39bdce('0x52a')](_0x5d0d46);});},'locals':{'user':_0x150d92[_0x2cdeb3('0xc96')],'channel':'openchannel','interaction':_0x28463a}});}function _0x1ca474(_0xda0ea8){const _0x40cabd=_0x3f1dba;if(_0xda0ea8['from'])_0xda0ea8[_0x40cabd('0x12b3')]=_0xda0ea8['from'];else _0xda0ea8[_0x40cabd('0x1309')]?_0xda0ea8['contactName']=(_0xda0ea8['Contact'][_0x40cabd('0xeef')]||'')+'\x20'+(_0xda0ea8[_0x40cabd('0x1309')][_0x40cabd('0x510')]||''):_0xda0ea8[_0x40cabd('0x12b3')]=_0x1e5394[_0x40cabd('0x2728')](_0x40cabd('0x215e'));}function _0x31946f(_0x5d5bc2){const _0x2004c7=_0x3f1dba;if(_0x5d5bc2['UserId'])return _0x5d5bc2[_0x2004c7('0x10c5')]===_0x150d92[_0x2004c7('0xc96')]['id']?_0x1e5394[_0x2004c7('0x2728')](_0x2004c7('0x96a')):_0x5d5bc2[_0x2004c7('0x2464')][_0x2004c7('0x11bc')]+'\x20<'+_0x5d5bc2[_0x2004c7('0x2464')]['internal']+'>';return _0x1e5394[_0x2004c7('0x2728')](_0x2004c7('0x2608'));}function _0x4d2745(_0x5e0f61){const _0x186d81=_0x3f1dba;if(_0x5e0f61['Account'])return _0x5e0f61[_0x186d81('0xa78')][_0x186d81('0x1d46')];return _0x1e5394[_0x186d81('0x2728')]('DASHBOARDS.UNKNOWN');}function _0x5bc738(_0x37adf8,_0x435154){const _0x50af37=_0x3f1dba;_0x1b69b5[_0x50af37('0x1d4')]({'controller':_0x50af37('0xe4e'),'controllerAs':'vm','templateUrl':_0x2b4eb6,'parent':angular[_0x50af37('0x1fcc')](_0x1446c0[_0x50af37('0x18e5')]),'clickOutsideToClose':![],'locals':{'account':_0x435154,'message':{},'type':'new','interaction':{}},'fullscreen':!![]})[_0x50af37('0x683')](function(_0x53fda4){const _0x598e89=_0x50af37;if(_0x53fda4){if(_0x53fda4[_0x598e89('0x8c2')]&&_0x53fda4[_0x598e89('0x8c2')][_0x598e89('0x250b')]){const _0x13ad8a={'channel':_0x598e89('0x1261'),'account':_0x435154,'message':_0x53fda4['message'],'contact':_0x53fda4[_0x598e89('0xd06')]};_0x26bbcb[_0x598e89('0x23c6')](_0x13ad8a);}else{const _0x28fcf7=_0x53fda4;return _0x12908c[_0x598e89('0x1963')]['send']({'id':_0x435154['id']},_0x28fcf7)[_0x598e89('0xe53')]['then'](function(_0x3fa08b){const _0x36e2e2=_0x598e89;_0x232dbb['success']({'title':_0x36e2e2('0xb96'),'msg':_0x36e2e2('0x21a1')}),_0x4e676a['$parent']['vm'][_0x36e2e2('0x297')](_0x36e2e2('0x1261'),_0x3fa08b);})[_0x598e89('0x130a')](function(_0x266f97){const _0x587806=_0x598e89;if(_0x266f97['data']&&_0x266f97[_0x587806('0x5a5')]['errors']&&_0x266f97[_0x587806('0x5a5')][_0x587806('0x17f')]['length'])for(let _0x2bf6ed=0x0;_0x2bf6ed<_0x266f97['data']['errors'][_0x587806('0x1564')];_0x2bf6ed++){_0x232dbb[_0x587806('0x52a')]({'title':_0x266f97['data'][_0x587806('0x17f')][_0x2bf6ed]['type'],'msg':_0x266f97[_0x587806('0x5a5')][_0x587806('0x17f')][_0x2bf6ed][_0x587806('0x8c2')]});}else _0x232dbb[_0x587806('0x52a')]({'title':_0x266f97[_0x587806('0x13ee')]?_0x587806('0x2168')+_0x266f97[_0x587806('0x13ee')]+_0x587806('0xbf6')+_0x266f97[_0x587806('0x24a9')]:_0x587806('0x13d8'),'msg':_0x266f97[_0x587806('0x5a5')]?JSON[_0x587806('0x258a')](_0x266f97['data'][_0x587806('0x8c2')]):_0x266f97[_0x587806('0x8c2')]||_0x266f97[_0x587806('0x1ff0')]()});});}}});}function _0x511c7c(_0x20122d){const _0x501356=_0x3f1dba;let _0x506901;const _0x5cebc2=_0x2e3ca0()[_0x501356('0x1c07')](_0x150d92['openchannelInteractions'][_0x501356('0xf5d')],{'id':_0x20122d['OpenchannelInteractionId']});_0x5cebc2&&_0x5cebc2['Users']&&(_0x506901=_0x2e3ca0()[_0x501356('0x1c07')](_0x5cebc2['Users'],{'id':_0x20122d[_0x501356('0x10c5')]}),!_0x506901&&_0x5cebc2['Users']['push']({'id':_0x20122d[_0x501356('0x10c5')]}));}function _0x41c18c(_0x37fb86){const _0x2da179=_0x3f1dba,_0x52b475=_0x2e3ca0()['find'](_0x150d92[_0x2da179('0x13f9')][_0x2da179('0xf5d')],{'id':_0x37fb86[_0x2da179('0x1623')]});_0x52b475&&_0x52b475[_0x2da179('0x2139')]&&_0x2e3ca0()[_0x2da179('0x3ec')](_0x52b475[_0x2da179('0x2139')],{'id':_0x37fb86[_0x2da179('0x10c5')]});}function _0x238fff(_0x4acbe8){const _0x1b15a0=_0x3f1dba;if(_0x4acbe8){const _0xf0d4a5=_0x2e3ca0()[_0x1b15a0('0x1c07')](_0x150d92[_0x1b15a0('0x13f9')][_0x1b15a0('0xf5d')],{'id':_0x4acbe8['id']});if(_0xf0d4a5){_0xf0d4a5[_0x1b15a0('0x2139')]=[];_0x4acbe8[_0x1b15a0('0xd8a')]&&(_0xf0d4a5[_0x1b15a0('0x122e')]=0x0);if(_0x150d92[_0x1b15a0('0x23a2')]['sort']){const _0x327ba7=_0x2e3ca0()[_0x1b15a0('0x18ad')](_0x150d92['query'][_0x1b15a0('0x671')],'-')?_0x1b15a0('0x1f5a'):_0x1b15a0('0xe38');_0x150d92[_0x1b15a0('0x13f9')][_0x1b15a0('0xf5d')]=_0x2e3ca0()['orderBy'](_0x150d92[_0x1b15a0('0x13f9')][_0x1b15a0('0xf5d')],_0x2e3ca0()['trimStart'](_0x150d92[_0x1b15a0('0x23a2')][_0x1b15a0('0x671')],'-'),_0x327ba7);}_0x2e3ca0()[_0x1b15a0('0xf22')](_0xf0d4a5,_0x2e3ca0()[_0x1b15a0('0x24d0')](_0x4acbe8,_0x2e3ca0()[_0x1b15a0('0x55e')](_0xf0d4a5)));}else _0x16414c(_0x150d92[_0x1b15a0('0x23a2')][_0x1b15a0('0xdf8')]);}}function _0x595b9f(_0x407971){const _0x2598d5=_0x3f1dba;if(_0x407971){const _0x1f7089=_0x2e3ca0()[_0x2598d5('0x1c07')](_0x150d92[_0x2598d5('0x13f9')][_0x2598d5('0xf5d')],{'id':_0x407971['id']});_0x1f7089&&(_0x1f7089['Tags']=_0x407971[_0x2598d5('0x1ce6')]||[],_0x2e3ca0()[_0x2598d5('0xf22')](_0x1f7089,_0x2e3ca0()['pick'](_0x407971,_0x2e3ca0()[_0x2598d5('0x55e')](_0x1f7089))));}}function _0x32bb42(_0x38865b){const _0x5713f1=_0x3f1dba;if(_0x38865b&&!_0x38865b[_0x5713f1('0x252d')]){const _0x1d02f5=_0x2e3ca0()[_0x5713f1('0x1c07')](_0x150d92[_0x5713f1('0x13f9')][_0x5713f1('0xf5d')],{'id':_0x38865b[_0x5713f1('0x1623')]});if(_0x1d02f5){const _0x1ef5f6=_0x2e3ca0()[_0x5713f1('0x1c07')](_0x1d02f5['Messages'],{'id':_0x38865b['id']});_0x1ef5f6?_0x2e3ca0()[_0x5713f1('0xf22')](_0x1ef5f6,_0x2e3ca0()[_0x5713f1('0x24d0')](_0x38865b,_0x2e3ca0()['keys'](_0x1ef5f6))):(_0x2e3ca0()[_0x5713f1('0x8f2')](_0x1d02f5[_0x5713f1('0xc51')])&&(_0x1d02f5[_0x5713f1('0xc51')]={'count':0x0}),!_0x38865b[_0x5713f1('0x20db')]&&(_0x1d02f5[_0x5713f1('0xc51')][_0x5713f1('0x50d')]+=0x1));}}}function _0x2497d6(){const _0x17dcdb=_0x3f1dba;_0x150d92[_0x17dcdb('0x1b8f')]=![];}function _0xf1002d(){_0x150d92['isSearchBarVisible']=!![];}function _0x247f61(){const _0x25d9a5=_0x3f1dba;_0x150d92[_0x25d9a5('0x1b8f')]=![],_0x1b69b5[_0x25d9a5('0x1d4')]({'controller':_0x25d9a5('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x25d9a5('0x1fcc')](_0x1446c0[_0x25d9a5('0x18e5')]),'clickOutsideToClose':![],'locals':{'color':_0x150d92[_0x25d9a5('0xd10')],'fields':_0x150d92[_0x25d9a5('0x19c9')][_0x25d9a5('0x189a')],'storagePath':_0x25d9a5('0x1ca4')},'fullscreen':!![]})[_0x25d9a5('0x683')](function(_0x442a07){const _0x1321b6=_0x25d9a5;_0x150d92['query'][_0x1321b6('0x19a4')]=_0x442a07===![]?undefined:_0x442a07;if(_0x150d92[_0x1321b6('0x23a2')][_0x1321b6('0x19a4')]||_0x442a07===![])_0x16414c();})[_0x25d9a5('0x130a')](function(_0x3eca97){const _0xc444f9=_0x25d9a5;_0x232dbb[_0xc444f9('0x52a')]({'title':_0xc444f9('0x1119'),'msg':_0x3eca97[_0xc444f9('0x5a5')]?JSON[_0xc444f9('0x258a')](_0x3eca97[_0xc444f9('0x5a5')][_0xc444f9('0x8c2')]):_0x3eca97[_0xc444f9('0x1ff0')]()});});}let _0x402f24=!![],_0x1cd616=0x1;_0x4e676a['$watch'](_0x3f1dba('0x1e1d'),function(_0x5c78b7,_0x410d44){const _0x3f5252=_0x3f1dba;_0x402f24?_0x5e2a7b(function(){_0x402f24=![];}):(!_0x410d44&&(_0x1cd616=_0x150d92['query'][_0x3f5252('0xdf8')]),_0x5c78b7!==_0x410d44&&(_0x150d92[_0x3f5252('0x23a2')]['page']=0x1),!_0x5c78b7&&(_0x150d92[_0x3f5252('0x23a2')][_0x3f5252('0xdf8')]=_0x1cd616),_0x16414c(_0x150d92[_0x3f5252('0x23a2')][_0x3f5252('0xdf8')]));}),_0x4e676a['$on']('$destroy',function(){const _0x1f0b50=_0x3f1dba;_0xc362ae[_0x1f0b50('0x1b9e')](_0x1f0b50('0x642')),_0xc362ae[_0x1f0b50('0x1b9e')](_0x1f0b50('0x1318')),_0xc362ae['removeAllListeners'](_0x1f0b50('0x14dc')),_0xc362ae[_0x1f0b50('0x1b9e')]('openchannelInteractionTags:save'),_0xc362ae[_0x1f0b50('0x1b9e')]('openchannelInteraction:update'),_0xc362ae[_0x1f0b50('0x1b9e')]('user_has_openchannel_interactions:save'),_0xc362ae[_0x1f0b50('0x1b9e')]('user_has_openchannel_interactions:remove');});}const _0x2d5e81=_0x323e5a;_0x4e901f[_0x189033('0x14be')]=['$document',_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x8ea'),_0x189033('0x204d'),'Auth'];function _0x4e901f(_0xc09d93,_0x16a691,_0x206910,_0xeb0a28,_0x239cad,_0x1923a7,_0x1b48c0){const _0x7283c9=_0x189033,_0x322a87=this;_0x322a87['currentUser']=_0x1b48c0[_0x7283c9('0x20b2')](),_0x322a87['plugin']={};function _0x2d3bf7(_0x1ce620,_0x12b806,_0x529144){const _0xe6d150=_0x7283c9;_0x322a87[_0xe6d150('0xace')]=_0x1ce620,_0x322a87['setting']=_0x12b806,_0x322a87[_0xe6d150('0x1cd1')]=_0x529144;}function _0x1a4468(){const _0xa0b2af=_0x7283c9;return _0x1923a7[_0xa0b2af('0x1854')](_0x322a87[_0xa0b2af('0x1cd1')]['agentUrl']);}_0x16a691[_0x7283c9('0x26a2')]('pluginUpdated',function(_0x1e09f0,_0x442121){const _0x40d609=_0x7283c9;_0x322a87[_0x40d609('0x1cd1')]=_0x442121['plugin'];}),_0x322a87[_0x7283c9('0x1dd2')]=_0x2d3bf7,_0x322a87[_0x7283c9('0x2276')]=_0x1a4468,_0x2d3bf7();}const _0x515533=_0x4e901f;_0x1a3818[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x2f9'),'api','toasty','Auth'];function _0x1a3818(_0x504017,_0x2dd9f4,_0x491ab0,_0x228c9c,_0x353550,_0x559731){const _0x3e8fbb=_0x189033,_0x382ec7=this;_0x382ec7[_0x3e8fbb('0x11ed')]=_0x559731[_0x3e8fbb('0x20b2')](),_0x382ec7['voiceRecordings']={},_0x382ec7['table']='voiceRecordings',_0x382ec7[_0x3e8fbb('0x23a2')]={'UserId':_0x382ec7[_0x3e8fbb('0x11ed')]['id'],'fields':_0x3e8fbb('0x2844'),'sort':_0x3e8fbb('0xc36'),'limit':0xa,'page':0x1,'type':null},_0x382ec7[_0x3e8fbb('0xfda')]=_0x380592,_0x382ec7[_0x3e8fbb('0x2030')]=_0x181867,_0x382ec7['success']=_0x2e077c,_0x382ec7[_0x3e8fbb('0x261d')]=_0xb7b908,_0x382ec7[_0x3e8fbb('0x1dd2')]=_0x20436f,_0x382ec7[_0x3e8fbb('0xb65')]=_0xb45e35,_0x382ec7[_0x3e8fbb('0x229d')]=_0x307fc1;function _0x20436f(){const _0x271209=_0x3e8fbb;_0x382ec7[_0x271209('0xc71')]=_0x1d0f53();let _0x5c036f=_0x2dd9f4[_0x271209('0x120e')][_0x271209('0x1b28')]('motion2.home.recordings:'+_0x382ec7['currentUser']['id']);if(_0x5c036f)try{_0x5c036f=JSON[_0x271209('0x1f34')](_0x5c036f),_0x5c036f[_0x271209('0x23a2')]&&(_0x382ec7[_0x271209('0x23a2')]=_0x2e3ca0()[_0x271209('0x8b5')](_0x5c036f['query'],[_0x271209('0x25'),'id']),_0x382ec7[_0x271209('0x23a2')][_0x271209('0x189a')]=_0x271209('0x1fa3'),_0x382ec7[_0x271209('0x23a2')][_0x271209('0x10c5')]=_0x382ec7[_0x271209('0x11ed')]['id']);}catch(_0x5eb0c3){console[_0x271209('0x52a')](_0x5eb0c3);}else{const _0x315e1a={'$gte':_0x1aaf93()()[_0x271209('0x1627')](_0x271209('0x55b'))[_0x271209('0xb11')](0x0,!![])['format'](),'$lte':_0x1aaf93()()[_0x271209('0x3b3')](_0x271209('0x55b'))[_0x271209('0xb11')](0x0,!![])['format']()};_0x382ec7[_0x271209('0x23a2')]['createdAt']=_0x315e1a;}_0x382ec7[_0x271209('0x1b8f')]=_0x382ec7['query'][_0x271209('0x25')]?!![]:![],_0x382ec7[_0x271209('0x261d')]();}function _0x380592(_0x2b6ec5){const _0x12b102=_0x3e8fbb;return _0x228c9c[_0x12b102('0x52f')]['download']({'id':_0x2b6ec5['id'],'exists':!![]})[_0x12b102('0xe53')][_0x12b102('0x683')](function(_0x24e830){const _0x3f7fa2=_0x12b102,_0x18c415=[_0x24e830[_0x3f7fa2('0x1fb3')]],_0x1a79d9=new Blob(_0x18c415,{'type':_0x24e830[_0x3f7fa2('0xcf0')]}),_0x1670f0=window[_0x3f7fa2('0x12e1')][_0x3f7fa2('0x1ffa')]('a');_0x1670f0[_0x3f7fa2('0x130f')](_0x3f7fa2('0x2767'),URL[_0x3f7fa2('0x2820')](_0x1a79d9)),_0x1670f0[_0x3f7fa2('0x130f')]('download',_0x2b6ec5[_0x3f7fa2('0x573')]+_0x2b6ec5[_0x3f7fa2('0x26dd')]),_0x1670f0['click']();})['catch'](function(_0x509011){const _0x2287ae=_0x12b102;_0x353550[_0x2287ae('0x52a')]({'title':_0x509011['status']?'API:'+_0x509011[_0x2287ae('0x13ee')]+_0x2287ae('0xbf6')+_0x509011['statusText']:_0x2287ae('0x100c'),'msg':_0x509011[_0x2287ae('0x5a5')]?JSON[_0x2287ae('0x258a')](_0x509011['data']):_0x509011[_0x2287ae('0x1ff0')]()});});}function _0x181867(_0x4d3f19){const _0x531ae8=_0x3e8fbb;return _0x228c9c[_0x531ae8('0x52f')][_0x531ae8('0xd2b')]({'id':_0x4d3f19['id']})['$promise'][_0x531ae8('0x683')](function(_0x59c43a){const _0x11bbdb=_0x531ae8,_0x1a9df8=[_0x59c43a[_0x11bbdb('0x1fb3')]];let _0x535686=_0x11bbdb('0x18e8');const _0x520776=new Blob(_0x1a9df8,{'type':_0x59c43a[_0x11bbdb('0xcf0')]});_0x535686=_0x4d3f19['uniqueid'];const _0x311a88=window[_0x11bbdb('0x12e1')][_0x11bbdb('0x1ffa')]('a');_0x311a88[_0x11bbdb('0x130f')]('href',URL['createObjectURL'](_0x520776)),_0x311a88[_0x11bbdb('0x130f')](_0x11bbdb('0x18e8'),_0x535686),document['body'][_0x11bbdb('0x1e43')](_0x311a88),_0x311a88[_0x11bbdb('0x1d42')]();})['catch'](function(_0x5eb48d){const _0x35675f=_0x531ae8;_0x353550[_0x35675f('0x52a')]({'title':_0x5eb48d[_0x35675f('0x13ee')]?_0x35675f('0x2168')+_0x5eb48d[_0x35675f('0x13ee')]+'\x20-\x20'+_0x5eb48d['statusText']:_0x35675f('0x100c'),'msg':_0x5eb48d[_0x35675f('0x5a5')]?JSON[_0x35675f('0x258a')](_0x5eb48d['data']):_0x5eb48d[_0x35675f('0x1ff0')]()});});}function _0x1d0f53(){const _0x3aafff=_0x3e8fbb;return[{'name':_0x3aafff('0x10c1'),'key':_0x3aafff('0x1a4'),'type':_0x3aafff('0x270e'),'label':_0x3aafff('0x1006')},{'name':_0x3aafff('0x25c5'),'key':_0x3aafff('0xcf0'),'type':_0x3aafff('0xb31'),'label':_0x3aafff('0x4b4'),'customOptions':[{'value':'internal','translate':_0x3aafff('0x19ab')},{'value':_0x3aafff('0x1535'),'translate':_0x3aafff('0x16e3')},{'value':_0x3aafff('0x17cd'),'translate':_0x3aafff('0x2d8')},{'value':_0x3aafff('0x228a'),'translate':_0x3aafff('0x196c')},{'value':null,'translate':_0x3aafff('0xac0')}]}];}function _0x2e077c(_0x5088f9){const _0x113a27=_0x3e8fbb;_0x382ec7['searchInProgress']=![],_0x382ec7[_0x113a27('0x3ac')]=_0x5088f9||{'count':0x0,'rows':[]};}function _0xb7b908(){const _0x374bfd=_0x3e8fbb;_0x382ec7[_0x374bfd('0xab2')]=!![],_0x382ec7[_0x374bfd('0x23a2')]['offset']=(_0x382ec7['query']['page']-0x1)*_0x382ec7['query']['limit'];const _0x535dec={'query':_0x382ec7[_0x374bfd('0x23a2')]};_0x2dd9f4[_0x374bfd('0x120e')][_0x374bfd('0x15d')]('motion2.home.recordings:'+_0x382ec7['currentUser']['id'],JSON[_0x374bfd('0x258a')](_0x535dec)),_0x382ec7[_0x374bfd('0x1883')]=_0x228c9c[_0x374bfd('0x52f')][_0x374bfd('0x1e6e')](_0x382ec7[_0x374bfd('0x23a2')],_0x2e077c)['$promise'];}function _0xb45e35(){const _0x186827=_0x3e8fbb;_0x382ec7['query'][_0x186827('0x25')]=undefined,_0x382ec7['isSearchBarVisible']=![];}function _0x307fc1(){const _0x2ca664=_0x3e8fbb;_0x382ec7[_0x2ca664('0x1b8f')]=!![];}let _0x421a0a=!![],_0x277c50=0x1;_0x504017[_0x3e8fbb('0x186d')](_0x3e8fbb('0x1e1d'),function(_0x4cecd0,_0x37d68d){const _0x2f29aa=_0x3e8fbb;_0x421a0a?_0x491ab0(function(){_0x421a0a=![];}):(!_0x37d68d&&(_0x277c50=_0x382ec7[_0x2f29aa('0x23a2')][_0x2f29aa('0xdf8')]),_0x4cecd0!==_0x37d68d&&(_0x382ec7[_0x2f29aa('0x23a2')][_0x2f29aa('0xdf8')]=0x1),!_0x4cecd0&&(_0x382ec7[_0x2f29aa('0x23a2')][_0x2f29aa('0xdf8')]=_0x277c50),_0x382ec7[_0x2f29aa('0x261d')]());});}const _0x378a82=_0x1a3818,_0x46751f=_0x180212['p']+_0x189033('0xe2f');_0x2563a6[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),'toasty',_0x189033('0x56b'),_0x189033('0xba1')];function _0x2563a6(_0x89258f,_0x73c2b7,_0x33293d,_0x4054ed,_0x176d51,_0x419bfc,_0x3f957a,_0x56cfb4){const _0x1ccfea=_0x189033,_0x2f3ff4=this;_0x2f3ff4['currentUser']=_0x56cfb4[_0x1ccfea('0x20b2')](),_0x2f3ff4[_0x1ccfea('0x813')]=[_0x1ccfea('0x31c'),_0x1ccfea('0x23fe'),_0x1ccfea('0x13e'),_0x1ccfea('0x1526'),_0x1ccfea('0x786')],_0x2f3ff4[_0x1ccfea('0x1134')]={'readOnly':![],'canEdit':!![],'canDelete':!![]},_0x2f3ff4[_0x1ccfea('0xf95')]={},_0x2f3ff4[_0x1ccfea('0x23a2')]={'id':_0x2f3ff4[_0x1ccfea('0x11ed')]['id'],'fields':_0x1ccfea('0x24c6'),'sort':_0x1ccfea('0x1ff9'),'limit':0xa,'page':0x1},_0x2f3ff4[_0x1ccfea('0x2022')]={'rows':[],'count':0x0},_0x2f3ff4[_0x1ccfea('0x53')]=_0x17f6ed,_0x2f3ff4[_0x1ccfea('0x1cb0')]=_0x40f942,_0x2f3ff4[_0x1ccfea('0x1dd2')]=_0x2e905b,_0x2f3ff4['isDateBeforeToday']=_0xee2bc,_0x2f3ff4[_0x1ccfea('0x27d0')]=_0x292598,_0x2f3ff4[_0x1ccfea('0x26eb')]=_0x3db07a;function _0x2e905b(){const _0x43c854=_0x1ccfea;_0x3f957a[_0x43c854('0xc96')][_0x43c854('0x4c9')]({'id':_0x56cfb4[_0x43c854('0x20b2')]()['id'],'fields':_0x43c854('0xa10'),'channel':_0x43c854('0xcf2'),'type':_0x43c854('0x17cd'),'nolimit':!![]})[_0x43c854('0xe53')]['then'](function(_0x2897ba){const _0x57a05f=_0x43c854;_0x2f3ff4[_0x57a05f('0x2022')]=_0x2897ba||{'count':0x0,'rows':[]};})[_0x43c854('0x683')](function(){const _0x1ff854=_0x43c854;_0x2f3ff4[_0x1ff854('0xc71')]=_0x297e4c();})[_0x43c854('0x130a')](function(_0x2ed0b3){const _0x20aac0=_0x43c854;console[_0x20aac0('0x52a')](_0x2ed0b3);})[_0x43c854('0x2874')](function(){const _0xeaec33=_0x43c854;let _0x2e6bc5=_0x73c2b7['localStorage'][_0xeaec33('0x1b28')](_0xeaec33('0x2475')+_0x2f3ff4[_0xeaec33('0x11ed')]['id']);if(_0x2e6bc5)try{_0x2e6bc5=JSON[_0xeaec33('0x1f34')](_0x2e6bc5),_0x2e6bc5[_0xeaec33('0x23a2')]&&(_0x2f3ff4[_0xeaec33('0x23a2')]=_0x2e3ca0()[_0xeaec33('0x8b5')](_0x2e6bc5[_0xeaec33('0x23a2')],[_0xeaec33('0x25')]));}catch(_0x57360a){console['error'](_0x57360a);}else{const _0x4aa91c={'$gte':_0x1aaf93()()[_0xeaec33('0x1627')](_0xeaec33('0x55b'))[_0xeaec33('0xb11')](0x0,!![])[_0xeaec33('0x26dd')](),'$lte':_0x1aaf93()()['endOf'](_0xeaec33('0x55b'))[_0xeaec33('0xb11')](0x0,!![])['format']()};_0x2f3ff4[_0xeaec33('0x23a2')]['createdAt']=_0x4aa91c;}_0x2f3ff4[_0xeaec33('0x1cb0')]();});}function _0x17f6ed(_0x102901){_0x2f3ff4['searchInProgress']=![],_0x2f3ff4['scheduledCalls']=_0x102901||{'count':0x0,'rows':[]};}function _0x297e4c(){const _0x52368a=_0x1ccfea;return[{'name':'Start\x20Date','key':_0x52368a('0x1a4'),'type':_0x52368a('0x270e'),'label':_0x52368a('0x1006')},{'name':'Campaigns','key':_0x52368a('0x19ec'),'type':'multiselect','label':'MOTIONDIALER.SELECT_CAMPAIGN','options':_0x2f3ff4[_0x52368a('0x2022')][_0x52368a('0xf5d')]}];}function _0x40f942(){const _0x2058b3=_0x1ccfea;_0x2f3ff4[_0x2058b3('0xab2')]=!![],_0x2f3ff4[_0x2058b3('0x23a2')]['id']=_0x2f3ff4[_0x2058b3('0x11ed')]['id'],_0x2f3ff4['query'][_0x2058b3('0x2761')]=!![],_0x2f3ff4['query'][_0x2058b3('0x1cc8')]=(_0x2f3ff4[_0x2058b3('0x23a2')]['page']-0x1)*_0x2f3ff4[_0x2058b3('0x23a2')][_0x2058b3('0x6f0')];const _0x381b41={'query':_0x2f3ff4[_0x2058b3('0x23a2')]};_0x73c2b7['localStorage']['setItem'](_0x2058b3('0x2475')+_0x2f3ff4[_0x2058b3('0x11ed')]['id'],JSON[_0x2058b3('0x258a')](_0x381b41)),_0x2f3ff4[_0x2058b3('0x1883')]=_0x3f957a[_0x2058b3('0xc96')][_0x2058b3('0x1cb0')](_0x2f3ff4[_0x2058b3('0x23a2')],_0x17f6ed)[_0x2058b3('0xe53')];}function _0x292598(_0x38f82a,_0x11a471){const _0x5c96aa=_0x1ccfea;_0x4054ed[_0x5c96aa('0x1d4')]({'controller':_0x5c96aa('0x17f9'),'controllerAs':'vm','templateUrl':_0x46751f,'parent':angular[_0x5c96aa('0x1fcc')](_0x176d51[_0x5c96aa('0x18e5')]),'targetEvent':_0x38f82a,'clickOutsideToClose':!![],'locals':{'queueCampaign':null,'hopper':_0x11a471,'hoppers':_0x2f3ff4['scheduledCalls'][_0x5c96aa('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x2f3ff4[_0x5c96aa('0x1134')]}});}function _0x41ee8b(_0x4a2745){const _0x131d35=_0x1ccfea;_0x3f957a[_0x131d35('0x26cf')][_0x131d35('0xd7e')]({'id':_0x4a2745['id']})[_0x131d35('0xe53')][_0x131d35('0x683')](function(){const _0x36227f=_0x131d35;_0x2e3ca0()[_0x36227f('0x3ec')](_0x2f3ff4[_0x36227f('0xf95')][_0x36227f('0xf5d')],{'id':_0x4a2745['id']}),_0x2f3ff4[_0x36227f('0xf95')][_0x36227f('0x50d')]-=0x1,!_0x2f3ff4['scheduledCalls'][_0x36227f('0xf5d')]['length']&&_0x2f3ff4['getScheduledCalls'](),_0x419bfc[_0x36227f('0x53')]({'title':'Scheduled\x20call\x20deleted!','msg':_0x4a2745[_0x36227f('0x60a')]?'Scheduled\x20call\x20has\x20been\x20deleted!':''});})['catch'](function(_0x33a9ba){const _0x2802d2=_0x131d35;if(_0x33a9ba[_0x2802d2('0x5a5')]&&_0x33a9ba[_0x2802d2('0x5a5')][_0x2802d2('0x17f')]&&_0x33a9ba[_0x2802d2('0x5a5')]['errors'][_0x2802d2('0x1564')]){_0x2f3ff4[_0x2802d2('0x17f')]=_0x33a9ba[_0x2802d2('0x5a5')]['errors']||[{'message':_0x33a9ba[_0x2802d2('0x1ff0')](),'type':_0x2802d2('0x1b59')}];for(let _0x7bfea2=0x0;_0x7bfea2<_0x33a9ba['data'][_0x2802d2('0x17f')][_0x2802d2('0x1564')];_0x7bfea2++){_0x419bfc[_0x2802d2('0x52a')]({'title':_0x33a9ba[_0x2802d2('0x5a5')]['errors'][_0x7bfea2]['type'],'msg':_0x33a9ba[_0x2802d2('0x5a5')]['errors'][_0x7bfea2]['message']});}}else _0x419bfc[_0x2802d2('0x52a')]({'title':_0x33a9ba[_0x2802d2('0x13ee')]?_0x2802d2('0x2168')+_0x33a9ba[_0x2802d2('0x13ee')]+_0x2802d2('0xbf6')+_0x33a9ba[_0x2802d2('0x24a9')]:_0x2802d2('0x1b59'),'msg':_0x33a9ba[_0x2802d2('0x5a5')]?JSON[_0x2802d2('0x258a')](_0x33a9ba['data'][_0x2802d2('0x8c2')]):_0x33a9ba[_0x2802d2('0x8c2')]||_0x33a9ba[_0x2802d2('0x1ff0')]()});});}function _0x3db07a(_0xa9f9a9,_0x58e44a){const _0x2b3253=_0x1ccfea,_0x5e5a02=_0x4054ed[_0x2b3253('0x1c6f')]()[_0x2b3253('0xf28')](_0x2b3253('0x14a0'))[_0x2b3253('0x26e3')](_0x2b3253('0x1d34')+_0x2b3253('0x1ee7'))[_0x2b3253('0x1040')]('delete\x20scheduled\x20call')[_0x2b3253('0xe42')](_0x58e44a)['ok']('OK')[_0x2b3253('0x19fb')](_0x2b3253('0x16b8'));_0x4054ed[_0x2b3253('0x1d4')](_0x5e5a02)[_0x2b3253('0x683')](function(){_0x41ee8b(_0xa9f9a9);},function(){const _0x402453=_0x2b3253;console[_0x402453('0x1b2b')](_0x402453('0x16b8'));});}function _0xee2bc(_0x1598e9){return _0x1aaf93()(_0x1598e9)['isBefore'](_0x1aaf93()());}let _0x9b1221=!![],_0x5e9bff=0x1;_0x89258f['$watch'](_0x1ccfea('0x1e1d'),function(_0x57a62b,_0x2f5dce){const _0xeb1173=_0x1ccfea;_0x9b1221?_0x33293d(function(){_0x9b1221=![];}):(!_0x2f5dce&&(_0x5e9bff=_0x2f3ff4[_0xeb1173('0x23a2')][_0xeb1173('0xdf8')]),_0x57a62b!==_0x2f5dce&&(_0x2f3ff4[_0xeb1173('0x23a2')]['page']=0x1),!_0x57a62b&&(_0x2f3ff4[_0xeb1173('0x23a2')][_0xeb1173('0xdf8')]=_0x5e9bff),_0x2f3ff4['getScheduledCalls']());});}const _0x1e83ca=_0x2563a6;_0xcacac5['$inject']=[_0x189033('0x7a5'),_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2063'),_0x189033('0x1d08'),_0x189033('0x56b'),'Auth',_0x189033('0x1556'),_0x189033('0x1d70'),'draftManager'];function _0xcacac5(_0x10e148,_0x10d47b,_0x1bcd62,_0x288c82,_0x56c55f,_0x3d9473,_0x4eb785,_0x360e3e,_0x412d76,_0x2ce0c1,_0x4fa8d7){const _0x48cfbf=_0x189033,_0x46cf05=this;_0x46cf05[_0x48cfbf('0xc96')]=_0x360e3e[_0x48cfbf('0x20b2')](),_0x46cf05['license']={},_0x46cf05[_0x48cfbf('0x260a')]={},_0x46cf05['tags']={'count':0x0,'rows':[]},_0x46cf05['smsInteractions']={'count':0x0,'rows':[]},_0x46cf05[_0x48cfbf('0x23a2')]={'includeAll':!![],'sort':_0x48cfbf('0xc36'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x46cf05[_0x48cfbf('0x19c9')]={'fields':[{'name':'Id','column':'id','type':_0x48cfbf('0x121f')},{'name':'Contact','column':_0x48cfbf('0x1309'),'type':_0x48cfbf('0xeb'),'options':{'searchFields':['firstName',_0x48cfbf('0x510'),_0x48cfbf('0x1c92')],'route':{'model':_0x48cfbf('0x276e'),'action':_0x48cfbf('0x1e6e'),'params':{'fields':_0x48cfbf('0x8ff'),'Contact':_0x48cfbf('0xfd'),'nolimit':!![]}},'extraOperators':[_0x48cfbf('0xe55')],'excludedOperators':[_0x48cfbf('0x17ee')]}},{'name':'Body','column':_0x48cfbf('0x18e5'),'type':_0x48cfbf('0x1bcd'),'options':{'excludedOperators':[_0x48cfbf('0x393'),_0x48cfbf('0x17ee')]}},{'name':_0x48cfbf('0x1d9d'),'column':_0x48cfbf('0xd8a'),'type':_0x48cfbf('0xb31'),'values':[{'id':0x0,'translate':_0x48cfbf('0x10b1')},{'id':0x1,'translate':_0x48cfbf('0x270a')}],'options':{'excludedOperators':['$ne']}},{'name':_0x48cfbf('0x62c'),'column':_0x48cfbf('0x1dad'),'type':'autocomplete','options':{'table':'i','route':{'model':_0x48cfbf('0xc96'),'action':'get','params':{'role':_0x48cfbf('0x2327'),'fields':_0x48cfbf('0x2686'),'nolimit':!![]}},'searchFields':[_0x48cfbf('0x11bc'),_0x48cfbf('0x60a')],'extraOperators':[_0x48cfbf('0xe55')],'excludedOperators':[_0x48cfbf('0x17ee')]}},{'name':'Account','column':_0x48cfbf('0x1f4f'),'type':_0x48cfbf('0xf6c'),'options':{'route':{'model':_0x48cfbf('0xc96'),'action':'getSmsAccounts','params':{'id':_0x46cf05['user']['id'],'nolimit':!![]}}}},{'name':'Tags','column':'Tag','type':_0x48cfbf('0xf6c'),'options':{'route':{'model':_0x48cfbf('0x270'),'action':_0x48cfbf('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x48cfbf('0x1479')]}},{'name':_0x48cfbf('0x10c1'),'column':_0x48cfbf('0x1a4'),'type':_0x48cfbf('0x270e'),'options':{'excludedOperators':[_0x48cfbf('0x17ee')]}},{'name':'Read','column':_0x48cfbf('0x122e'),'type':_0x48cfbf('0xb31'),'values':[{'id':0x1,'translate':_0x48cfbf('0x38f')},{'id':0x0,'translate':'DASHBOARDS.UNREAD'}],'options':{'excludedOperators':[_0x48cfbf('0x17ee')]}}]},_0x46cf05[_0x48cfbf('0xd10')]=_0x48cfbf('0xf85'),_0x46cf05[_0x48cfbf('0x1dd2')]=_0x2711db,_0x46cf05['success']=_0x3d83a7,_0x46cf05[_0x48cfbf('0xdfe')]=_0x276a74,_0x46cf05[_0x48cfbf('0x19d0')]=_0xb90462,_0x46cf05[_0x48cfbf('0x92b')]=_0x5ed56c,_0x46cf05['disposeInteraction']=_0x166816,_0x46cf05[_0x48cfbf('0x1dd3')]=_0x50af8a,_0x46cf05[_0x48cfbf('0x2084')]=_0x38951a,_0x46cf05[_0x48cfbf('0x457')]=_0x1d9a23,_0x46cf05[_0x48cfbf('0x77f')]=_0x126780,_0x46cf05[_0x48cfbf('0xb65')]=_0x4e3166,_0x46cf05['onSearchBarExpand']=_0x533c9f,_0x46cf05[_0x48cfbf('0x2121')]=_0x2b6d9e;function _0x2711db(_0x4c7fa3,_0x4ad8e6){const _0x173d19=_0x48cfbf;return _0x46cf05[_0x173d19('0xace')]=_0x4c7fa3,_0x46cf05[_0x173d19('0x260a')]=_0x4ad8e6,_0x4eb785[_0x173d19('0xc96')][_0x173d19('0x1e6e')+_0x2e3ca0()[_0x173d19('0x2711')](_0x173d19('0x197c'))]({'id':_0x46cf05['user']['id'],'nolimit':!![]})[_0x173d19('0xe53')][_0x173d19('0x683')](function(_0x3852d7){const _0x97a1c1=_0x173d19;return _0x46cf05[_0x97a1c1('0x197c')]=_0x3852d7||{'count':0x0,'rows':[]},_0x4eb785['tag']['get']()[_0x97a1c1('0xe53')];})[_0x173d19('0x683')](function(_0x4383e4){_0x46cf05['tags']=_0x4383e4||{'count':0x0,'rows':[]};})[_0x173d19('0x683')](function(){const _0x27489e=_0x173d19;_0x46cf05[_0x27489e('0xc71')]=_0x5366eb();})['catch'](function(_0x5d3a51){const _0x3a2cbd=_0x173d19;console[_0x3a2cbd('0x52a')](_0x5d3a51);})[_0x173d19('0x2874')](function(){const _0x4f96ff=_0x173d19;let _0x1ef698=_0x56c55f[_0x4f96ff('0x120e')]['getItem'](_0x4f96ff('0x1a07')+_0x46cf05[_0x4f96ff('0xc96')]['id']);if(_0x1ef698)try{_0x1ef698=JSON[_0x4f96ff('0x1f34')](_0x1ef698);if(_0x1ef698[_0x4f96ff('0x23a2')]){_0x46cf05[_0x4f96ff('0x23a2')]=_0x2e3ca0()[_0x4f96ff('0xf22')](_0x46cf05[_0x4f96ff('0x23a2')],_0x1ef698[_0x4f96ff('0x23a2')]);if(_0x2e3ca0()[_0x4f96ff('0x173f')](_0x46cf05['smsAccounts']['rows']))_0x46cf05[_0x4f96ff('0x23a2')][_0x4f96ff('0x1f4f')]=[];else _0x2e3ca0()[_0x4f96ff('0x173f')](_0x46cf05[_0x4f96ff('0x23a2')]['SmsAccountId'])&&(_0x46cf05[_0x4f96ff('0x23a2')][_0x4f96ff('0x1f4f')]=_0x2e3ca0()(_0x46cf05[_0x4f96ff('0x197c')][_0x4f96ff('0xf5d')])[_0x4f96ff('0x386')]('id')[_0x4f96ff('0x22c8')]()['value']());_0x46cf05[_0x4f96ff('0x23a2')][_0x4f96ff('0x671')]&&_0x46cf05[_0x4f96ff('0x23a2')][_0x4f96ff('0x671')][_0x4f96ff('0x824')](_0x4f96ff('0x88f'))>=0x0&&(_0x46cf05[_0x4f96ff('0x23a2')]=_0x2e3ca0()['omit'](_0x46cf05[_0x4f96ff('0x23a2')],'sort')),_0x46cf05[_0x4f96ff('0x23a2')][_0x4f96ff('0x2761')]=!![],_0x46cf05['isSearchBarVisible']=_0x46cf05[_0x4f96ff('0x23a2')]['filter']?!![]:![];}}catch(_0x7073c6){console[_0x4f96ff('0x52a')](_0x7073c6);}else{const _0x5504b2={'$gte':_0x1aaf93()()[_0x4f96ff('0x1627')](_0x4f96ff('0x55b'))['utcOffset'](0x0,!![])[_0x4f96ff('0x26dd')](),'$lte':_0x1aaf93()()[_0x4f96ff('0x3b3')](_0x4f96ff('0x55b'))[_0x4f96ff('0xb11')](0x0,!![])['format']()},_0x3554ae={'SmsAccountId':_0x2e3ca0()[_0x4f96ff('0x386')](_0x46cf05[_0x4f96ff('0x197c')][_0x4f96ff('0xf5d')],'id'),'createdAt':_0x5504b2};_0x46cf05[_0x4f96ff('0x23a2')]=_0x2e3ca0()[_0x4f96ff('0xf22')](_0x46cf05[_0x4f96ff('0x23a2')],_0x3554ae);}_0x412d76['on'](_0x4f96ff('0x25e4'),_0x2e8b1e),_0x412d76['on']('smsInteraction:update',_0x2e8b1e),_0x412d76['on'](_0x4f96ff('0x27da'),_0x595046),_0x412d76['on'](_0x4f96ff('0x1446'),_0x5c0504),_0x412d76['on']('smsMessage:update',_0x5c0504),_0x412d76['on'](_0x4f96ff('0x21c5'),_0xe6f9d9),_0x412d76['on'](_0x4f96ff('0x14ff'),_0x111a01),_0x276a74(_0x46cf05[_0x4f96ff('0x23a2')][_0x4f96ff('0xdf8')]);});}function _0x5366eb(){const _0x47c20f=_0x48cfbf;return[{'name':_0x47c20f('0x10c1'),'key':_0x47c20f('0x1a4'),'type':_0x47c20f('0x270e'),'label':_0x47c20f('0x1006')},{'name':'Messages','key':'read','type':_0x47c20f('0xb31'),'label':'DASHBOARDS.SELECT_READ_UNREAD','customOptions':[{'value':0x0,'translate':_0x47c20f('0x2226')},{'value':0x1,'translate':_0x47c20f('0x38f')},{'value':null,'translate':_0x47c20f('0x475')}]},{'name':_0x47c20f('0x1d9d'),'key':_0x47c20f('0xd8a'),'type':_0x47c20f('0xb31'),'label':_0x47c20f('0x1b77'),'customOptions':[{'value':0x0,'translate':_0x47c20f('0x10b1')},{'value':0x1,'translate':_0x47c20f('0x270a')},{'value':null,'translate':_0x47c20f('0x475')}]},{'name':_0x47c20f('0xa78'),'key':_0x47c20f('0x1f4f'),'type':_0x47c20f('0xf6c'),'label':_0x47c20f('0x1202'),'options':_0x46cf05['smsAccounts'][_0x47c20f('0xf5d')],'clearAll':![]},{'name':_0x47c20f('0x62c'),'key':'UserId','type':'select','label':_0x47c20f('0x21fb'),'customOptions':[{'value':_0x46cf05['user']['id'],'translate':'DASHBOARDS.ME'},{'value':_0x47c20f('0x13c'),'translate':_0x47c20f('0x2608')},{'value':undefined,'translate':_0x47c20f('0x475')}]},{'name':_0x47c20f('0x1e'),'key':_0x47c20f('0x270'),'type':_0x47c20f('0xf6c'),'label':'DASHBOARDS.SELECT_TAG','options':_0x46cf05[_0x47c20f('0x1ce6')][_0x47c20f('0xf5d')],'placeholder':_0x47c20f('0x7cb')}];}function _0x3d83a7(_0x476dd5){const _0x5a7ce6=_0x48cfbf;_0x46cf05[_0x5a7ce6('0xab2')]=![],_0x46cf05[_0x5a7ce6('0x1184')]=_0x476dd5||{'count':0x0,'rows':[]};for(let _0x1ced31=0x0;_0x1ced31<_0x46cf05[_0x5a7ce6('0x1184')][_0x5a7ce6('0xf5d')]['length'];_0x1ced31+=0x1){_0x50af8a(_0x46cf05['smsInteractions'][_0x5a7ce6('0xf5d')][_0x1ced31]);}}function _0x276a74(_0x5dc6f6){const _0x67941d=_0x48cfbf;_0x46cf05[_0x67941d('0xab2')]=!![];!_0x5dc6f6&&(_0x46cf05[_0x67941d('0x23a2')][_0x67941d('0xdf8')]=0x1);_0x46cf05[_0x67941d('0x23a2')][_0x67941d('0x1cc8')]=(_0x46cf05['query'][_0x67941d('0xdf8')]-0x1)*_0x46cf05[_0x67941d('0x23a2')][_0x67941d('0x6f0')];let _0x5dc89e=_0x56c55f['localStorage'][_0x67941d('0x1b28')](_0x67941d('0x1a07')+_0x46cf05[_0x67941d('0xc96')]['id']);_0x5dc89e=_0x5dc89e?JSON[_0x67941d('0x1f34')](_0x5dc89e):{},_0x5dc89e[_0x67941d('0x23a2')]=_0x46cf05[_0x67941d('0x23a2')],_0x56c55f[_0x67941d('0x120e')][_0x67941d('0x15d')]('motion2.home.sms:'+_0x46cf05[_0x67941d('0xc96')]['id'],JSON[_0x67941d('0x258a')](_0x5dc89e)),_0x46cf05['promise']=_0x4eb785[_0x67941d('0x22d8')][_0x67941d('0x1e6e')](_0x46cf05['query'],_0x3d83a7)[_0x67941d('0xe53')];}function _0xb90462(_0x443de6,_0xec3f88){const _0x57832e=_0x48cfbf;_0x10e148['$parent']['vm'][_0x57832e('0x297')](_0x57832e('0x1285'),_0xec3f88);}function _0x5ed56c(_0x1644ec,_0x21ff8,_0x4270e1){const _0x3b6a5a=_0x48cfbf;_0x4eb785[_0x3b6a5a('0x22d8')][_0x3b6a5a('0x18e8')]({'id':_0x21ff8['id'],'attachments':_0x4270e1})[_0x3b6a5a('0xe53')]['then'](function(_0x119f5d){const _0x5619ab=_0x3b6a5a,_0xc3797a=[_0x119f5d[_0x5619ab('0x1fb3')]],_0x24e8e7=_0x5619ab('0x13dc')+_0x21ff8['id']+_0x5619ab('0x18ff'),_0x2e0a0e=new Blob(_0xc3797a,{'type':_0x119f5d[_0x5619ab('0xcf0')]}),_0x282e90=window['document'][_0x5619ab('0x1ffa')]('a');_0x282e90[_0x5619ab('0x130f')](_0x5619ab('0x2767'),URL[_0x5619ab('0x2820')](_0x2e0a0e)),_0x282e90['setAttribute'](_0x5619ab('0x18e8'),_0x24e8e7),document[_0x5619ab('0x18e5')][_0x5619ab('0x1e43')](_0x282e90),_0x282e90['click']();})[_0x3b6a5a('0x130a')](function(_0x3f87c9){const _0x557c42=_0x3b6a5a;if(_0x3f87c9[_0x557c42('0x5a5')]&&_0x3f87c9[_0x557c42('0x5a5')][_0x557c42('0x17f')]&&_0x3f87c9[_0x557c42('0x5a5')][_0x557c42('0x17f')][_0x557c42('0x1564')])for(let _0x45f892=0x0;_0x45f892<_0x3f87c9[_0x557c42('0x5a5')][_0x557c42('0x17f')]['length'];_0x45f892+=0x1){_0x2ce0c1[_0x557c42('0x52a')]({'title':_0x3f87c9[_0x557c42('0x5a5')][_0x557c42('0x17f')][_0x45f892]['type'],'msg':_0x3f87c9['data'][_0x557c42('0x17f')][_0x45f892][_0x557c42('0x8c2')]});}else _0x2ce0c1['error']({'title':_0x3f87c9['status']?'API:'+_0x3f87c9[_0x557c42('0x13ee')]+'\x20-\x20'+_0x3f87c9[_0x557c42('0x24a9')]:_0x557c42('0x92b'),'msg':_0x3f87c9[_0x557c42('0x5a5')]?JSON[_0x557c42('0x258a')](_0x3f87c9['data']['message']):_0x3f87c9[_0x557c42('0x1ff0')]()});});}function _0x166816(_0x2fa118,_0x2d1110){const _0xb9ec21=_0x48cfbf,_0x1b8fc0=_0x46cf05['user'][_0xb9ec21('0x1431')]||_0x46cf05[_0xb9ec21('0xc96')][_0xb9ec21('0x1938')]||_0x46cf05[_0xb9ec21('0xc96')][_0xb9ec21('0x774')]||_0x46cf05['user'][_0xb9ec21('0x1a11')]||_0x46cf05[_0xb9ec21('0xc96')][_0xb9ec21('0x716')],_0x2bf873=!_0x2d1110[_0xb9ec21('0xa78')][_0xb9ec21('0x989')];_0x1bcd62[_0xb9ec21('0x1d4')]({'controller':_0xb9ec21('0x14a7'),'controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular['element'](_0x288c82[_0xb9ec21('0x18e5')]),'clickOutsideToClose':_0x2bf873,'escapeToClose':_0x2bf873,'onRemoving':function(){const _0x4cfa4b=_0xb9ec21;_0x46cf05['user']&&_0x2d1110['Account'][_0x4cfa4b('0x989')]&&!_0x1b8fc0&&_0x4eb785[_0x4cfa4b('0xc96')][_0x4cfa4b('0x1778')]({'id':_0x46cf05[_0x4cfa4b('0xc96')]['id']})[_0x4cfa4b('0xe53')][_0x4cfa4b('0x130a')](function(_0x3ebdcd){const _0x10830e=_0x4cfa4b;console[_0x10830e('0x52a')](_0x3ebdcd);});},'locals':{'user':_0x46cf05[_0xb9ec21('0xc96')],'channel':_0xb9ec21('0x1285'),'interaction':_0x2d1110}});}function _0x50af8a(_0x425291){const _0x2b5909=_0x48cfbf;_0x425291['Contact']?(_0x425291['contactName']=(_0x425291[_0x2b5909('0x1309')][_0x2b5909('0xeef')]||'')+'\x20'+(_0x425291[_0x2b5909('0x1309')][_0x2b5909('0x510')]||''),_0x425291[_0x2b5909('0x22f9')]=_0x425291[_0x2b5909('0x1309')][_0x2b5909('0x200f')]):_0x425291[_0x2b5909('0x12b3')]=_0x3d9473[_0x2b5909('0x2728')]('DASHBOARDS.UNKNOWN');}function _0x38951a(_0x50e4f2){const _0x151e79=_0x48cfbf;if(_0x50e4f2['UserId'])return _0x50e4f2[_0x151e79('0x10c5')]===_0x46cf05[_0x151e79('0xc96')]['id']?_0x3d9473[_0x151e79('0x2728')](_0x151e79('0x96a')):_0x50e4f2[_0x151e79('0x2464')]['fullname']+'\x20<'+_0x50e4f2['Owner'][_0x151e79('0x1d43')]+'>';return _0x3d9473[_0x151e79('0x2728')](_0x151e79('0x2608'));}function _0x1d9a23(_0x325282){const _0x38a4dc=_0x48cfbf;if(_0x325282['Account'])return _0x325282[_0x38a4dc('0xa78')][_0x38a4dc('0x1d46')];return _0x3d9473['instant'](_0x38a4dc('0x215e'));}function _0x126780(_0x681ecd,_0x4d81a0){const _0x1e5cb7=_0x48cfbf;_0x1bcd62[_0x1e5cb7('0x1d4')]({'controller':_0x1e5cb7('0x569'),'controllerAs':'vm','templateUrl':_0x382523,'parent':angular[_0x1e5cb7('0x1fcc')](_0x288c82[_0x1e5cb7('0x18e5')]),'clickOutsideToClose':![],'locals':{'account':_0x4d81a0,'message':{},'type':_0x1e5cb7('0x1476'),'interaction':{}},'fullscreen':!![]})[_0x1e5cb7('0x683')](function(_0x1c0cf5){const _0x13ed3b=_0x1e5cb7;if(_0x1c0cf5){if(_0x1c0cf5[_0x13ed3b('0x8c2')]&&_0x1c0cf5['message'][_0x13ed3b('0x250b')]){const _0x211a1d={'channel':'sms','account':_0x4d81a0,'message':_0x1c0cf5[_0x13ed3b('0x8c2')],'contact':_0x1c0cf5[_0x13ed3b('0xd06')]};_0x4fa8d7[_0x13ed3b('0x23c6')](_0x211a1d);}else{const _0x4fced3=_0x1c0cf5;return _0x4eb785[_0x13ed3b('0xa0e')][_0x13ed3b('0x1503')]({'id':_0x4d81a0['id']},_0x4fced3)[_0x13ed3b('0xe53')][_0x13ed3b('0x683')](function(_0x1a8bf7){const _0x101c8d=_0x13ed3b;_0x2ce0c1[_0x101c8d('0x53')]({'title':_0x101c8d('0xb96'),'msg':_0x101c8d('0x21a1')}),_0x10e148['$parent']['vm'][_0x101c8d('0x297')](_0x101c8d('0x1285'),_0x1a8bf7);})[_0x13ed3b('0x130a')](function(_0x3343f6){const _0x5fc5d5=_0x13ed3b;if(_0x3343f6[_0x5fc5d5('0x5a5')]&&_0x3343f6[_0x5fc5d5('0x5a5')][_0x5fc5d5('0x17f')]&&_0x3343f6[_0x5fc5d5('0x5a5')][_0x5fc5d5('0x17f')]['length'])for(let _0x42fbab=0x0;_0x42fbab<_0x3343f6[_0x5fc5d5('0x5a5')][_0x5fc5d5('0x17f')][_0x5fc5d5('0x1564')];_0x42fbab++){_0x2ce0c1[_0x5fc5d5('0x52a')]({'title':_0x3343f6[_0x5fc5d5('0x5a5')]['errors'][_0x42fbab][_0x5fc5d5('0xcf0')],'msg':_0x3343f6[_0x5fc5d5('0x5a5')]['errors'][_0x42fbab][_0x5fc5d5('0x8c2')]});}else _0x2ce0c1[_0x5fc5d5('0x52a')]({'title':_0x3343f6[_0x5fc5d5('0x13ee')]?'API:'+_0x3343f6[_0x5fc5d5('0x13ee')]+_0x5fc5d5('0xbf6')+_0x3343f6['statusText']:_0x5fc5d5('0x183c'),'msg':_0x3343f6[_0x5fc5d5('0x5a5')]?JSON[_0x5fc5d5('0x258a')](_0x3343f6['data'][_0x5fc5d5('0x8c2')]):_0x3343f6[_0x5fc5d5('0x8c2')]||_0x3343f6[_0x5fc5d5('0x1ff0')]()});});}}});}function _0xe6f9d9(_0x12cf5e){const _0x52db87=_0x48cfbf;let _0x4acd8a;const _0x412ae7=_0x2e3ca0()[_0x52db87('0x1c07')](_0x46cf05['smsInteractions'][_0x52db87('0xf5d')],{'id':_0x12cf5e['SmsInteractionId']});_0x412ae7&&_0x412ae7['Users']&&(_0x4acd8a=_0x2e3ca0()[_0x52db87('0x1c07')](_0x412ae7['Users'],{'id':_0x12cf5e[_0x52db87('0x10c5')]}),!_0x4acd8a&&_0x412ae7[_0x52db87('0x2139')][_0x52db87('0x1fd0')]({'id':_0x12cf5e[_0x52db87('0x10c5')]}));}function _0x111a01(_0x5eef7c){const _0x5d2e0e=_0x48cfbf,_0x1dad91=_0x2e3ca0()[_0x5d2e0e('0x1c07')](_0x46cf05['smsInteractions'][_0x5d2e0e('0xf5d')],{'id':_0x5eef7c[_0x5d2e0e('0x2b2')]});_0x1dad91&&_0x1dad91['Users']&&_0x2e3ca0()[_0x5d2e0e('0x3ec')](_0x1dad91[_0x5d2e0e('0x2139')],{'id':_0x5eef7c[_0x5d2e0e('0x10c5')]});}function _0x2e8b1e(_0x285e99){const _0x222a77=_0x48cfbf;if(_0x285e99){const _0x15c3da=_0x2e3ca0()[_0x222a77('0x1c07')](_0x46cf05[_0x222a77('0x1184')]['rows'],{'id':_0x285e99['id']});if(_0x15c3da){_0x15c3da[_0x222a77('0x2139')]=[];_0x285e99[_0x222a77('0xd8a')]&&(_0x15c3da['unreadMessages']=0x0);if(_0x46cf05['query']['sort']){const _0x5c3f6c=_0x2e3ca0()['startsWith'](_0x46cf05[_0x222a77('0x23a2')][_0x222a77('0x671')],'-')?_0x222a77('0x1f5a'):_0x222a77('0xe38');_0x46cf05[_0x222a77('0x1184')][_0x222a77('0xf5d')]=_0x2e3ca0()['orderBy'](_0x46cf05['smsInteractions'][_0x222a77('0xf5d')],_0x2e3ca0()['trimStart'](_0x46cf05[_0x222a77('0x23a2')]['sort'],'-'),_0x5c3f6c);}_0x2e3ca0()['merge'](_0x15c3da,_0x2e3ca0()[_0x222a77('0x24d0')](_0x285e99,_0x2e3ca0()['keys'](_0x15c3da)));}else _0x276a74(_0x46cf05[_0x222a77('0x23a2')]['page']);}}function _0x595046(_0x152f96){const _0x414c4f=_0x48cfbf;if(_0x152f96){const _0x3bdcc4=_0x2e3ca0()[_0x414c4f('0x1c07')](_0x46cf05[_0x414c4f('0x1184')][_0x414c4f('0xf5d')],{'id':_0x152f96['id']});_0x3bdcc4&&(_0x3bdcc4[_0x414c4f('0x198f')]=_0x152f96[_0x414c4f('0x1ce6')]||[],_0x2e3ca0()[_0x414c4f('0xf22')](_0x3bdcc4,_0x2e3ca0()[_0x414c4f('0x24d0')](_0x152f96,_0x2e3ca0()[_0x414c4f('0x55e')](_0x3bdcc4))));}}function _0x5c0504(_0x25e70d){const _0x23b893=_0x48cfbf;if(_0x25e70d&&!_0x25e70d[_0x23b893('0x252d')]){const _0x5d057f=_0x2e3ca0()[_0x23b893('0x1c07')](_0x46cf05[_0x23b893('0x1184')][_0x23b893('0xf5d')],{'id':_0x25e70d[_0x23b893('0x2b2')]});if(_0x5d057f){const _0x58325d=_0x2e3ca0()['find'](_0x5d057f[_0x23b893('0xc51')],{'id':_0x25e70d['id']});_0x58325d?_0x2e3ca0()[_0x23b893('0xf22')](_0x58325d,_0x2e3ca0()['pick'](_0x25e70d,_0x2e3ca0()[_0x23b893('0x55e')](_0x58325d))):(_0x2e3ca0()['isNil'](_0x5d057f[_0x23b893('0xc51')])&&(_0x5d057f[_0x23b893('0xc51')]={'count':0x0}),!_0x25e70d[_0x23b893('0x20db')]&&(_0x5d057f[_0x23b893('0xc51')][_0x23b893('0x50d')]+=0x1));}}}function _0x4e3166(){_0x46cf05['isSearchBarVisible']=![];}function _0x533c9f(){_0x46cf05['isSearchBarVisible']=!![];}function _0x2b6d9e(){const _0x38d80f=_0x48cfbf;_0x46cf05[_0x38d80f('0x1b8f')]=![],_0x1bcd62[_0x38d80f('0x1d4')]({'controller':_0x38d80f('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x38d80f('0x1fcc')](_0x288c82[_0x38d80f('0x18e5')]),'clickOutsideToClose':![],'locals':{'color':_0x46cf05[_0x38d80f('0xd10')],'fields':_0x46cf05[_0x38d80f('0x19c9')][_0x38d80f('0x189a')],'storagePath':_0x38d80f('0x1d63')},'fullscreen':!![]})[_0x38d80f('0x683')](function(_0x4204ca){const _0x5577d1=_0x38d80f;_0x46cf05[_0x5577d1('0x23a2')]['search']=_0x4204ca===![]?undefined:_0x4204ca;if(_0x46cf05[_0x5577d1('0x23a2')]['search']||_0x4204ca===![])_0x276a74();})[_0x38d80f('0x130a')](function(_0x54888d){const _0x1cf115=_0x38d80f;_0x2ce0c1[_0x1cf115('0x52a')]({'title':'ERROR','msg':_0x54888d[_0x1cf115('0x5a5')]?JSON['stringify'](_0x54888d[_0x1cf115('0x5a5')]['message']):_0x54888d['toString']()});});}let _0x4ff34c=!![],_0x1d0a45=0x1;_0x10e148['$watch'](_0x48cfbf('0x1e1d'),function(_0x5b3b7e,_0x44282f){const _0x1d077e=_0x48cfbf;_0x4ff34c?_0x10d47b(function(){_0x4ff34c=![];}):(!_0x44282f&&(_0x1d0a45=_0x46cf05[_0x1d077e('0x23a2')][_0x1d077e('0xdf8')]),_0x5b3b7e!==_0x44282f&&(_0x46cf05[_0x1d077e('0x23a2')][_0x1d077e('0xdf8')]=0x1),!_0x5b3b7e&&(_0x46cf05[_0x1d077e('0x23a2')][_0x1d077e('0xdf8')]=_0x1d0a45),_0x276a74(_0x46cf05['query'][_0x1d077e('0xdf8')]));}),_0x10e148[_0x48cfbf('0x26a2')]('$destroy',function(){const _0x54cb56=_0x48cfbf;_0x412d76[_0x54cb56('0x1b9e')](_0x54cb56('0x1446')),_0x412d76['removeAllListeners'](_0x54cb56('0x2070')),_0x412d76[_0x54cb56('0x1b9e')]('smsInteraction:save'),_0x412d76[_0x54cb56('0x1b9e')](_0x54cb56('0x27da')),_0x412d76[_0x54cb56('0x1b9e')]('smsInteraction:update'),_0x412d76['removeAllListeners']('user_has_sms_interactions:save'),_0x412d76[_0x54cb56('0x1b9e')](_0x54cb56('0x14ff'));});}const _0x3ee58b=_0xcacac5,_0x272275=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/agent/home/voice/details/dialog.html/dialog.html';_0x13eccd[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x2063'),_0x189033('0x7a5'),_0x189033('0x2f9')];function _0x13eccd(_0x11e4bc,_0x3abbea,_0x46dc47,_0x3c9435,_0x1d8944,_0xd0a098,_0x40b726,_0x4831d8){const _0x44f84f=_0x189033,_0xade245=this;_0xade245['currentUser']=_0x1d8944[_0x44f84f('0x20b2')](),_0xade245[_0x44f84f('0x27')]={},_0xade245[_0x44f84f('0x5c4')]=_0x44f84f('0x27'),_0xade245[_0x44f84f('0x23a2')]={'UserId':_0xade245[_0x44f84f('0x11ed')]['id'],'fields':_0x44f84f('0x2227'),'sort':_0x44f84f('0xc36'),'limit':0xa,'page':0x1,'type':null},_0xade245[_0x44f84f('0x53')]=_0x3ff2b9,_0xade245[_0x44f84f('0x22c2')]=_0x3e4d95,_0xade245[_0x44f84f('0x1dd2')]=_0x4ca1e5,_0xade245[_0x44f84f('0x197e')]=_0x1d485e,_0xade245['onSearchBarCollapse']=_0x213c48,_0xade245[_0x44f84f('0x229d')]=_0x522806;function _0x4ca1e5(){const _0x4dee1c=_0x44f84f;return _0x46dc47['tag'][_0x4dee1c('0x1e6e')]()[_0x4dee1c('0xe53')][_0x4dee1c('0x683')](function(_0x2e116c){const _0x4c1ae5=_0x4dee1c;_0xade245[_0x4c1ae5('0x1ce6')]=_0x2e116c||{'count':0x0,'rows':[]};})[_0x4dee1c('0x683')](function(){const _0x564a9b=_0x4dee1c;_0xade245[_0x564a9b('0xc71')]=_0x29bc74();})['catch'](function(_0x165d4c){const _0x5a063d=_0x4dee1c;_0x3c9435[_0x5a063d('0x52a')]({'title':_0x5a063d('0x14d7'),'msg':_0x165d4c[_0x5a063d('0x5a5')]?JSON[_0x5a063d('0x258a')](_0x165d4c[_0x5a063d('0x5a5')]['message']):_0x165d4c[_0x5a063d('0x8c2')]||_0x165d4c[_0x5a063d('0x1ff0')]()}),_0xade245[_0x5a063d('0x1ce6')]={'count':0x0,'rows':[]};})[_0x4dee1c('0x2874')](function(){const _0x40afa3=_0x4dee1c;let _0x53f79a=_0xd0a098['localStorage']['getItem'](_0x40afa3('0x2635')+_0xade245[_0x40afa3('0x11ed')]['id']);if(_0x53f79a)try{_0x53f79a=JSON[_0x40afa3('0x1f34')](_0x53f79a),_0x53f79a[_0x40afa3('0x23a2')]&&(_0xade245[_0x40afa3('0x23a2')]=_0x2e3ca0()[_0x40afa3('0x8b5')](_0x53f79a[_0x40afa3('0x23a2')],_0x40afa3('0x25')));}catch(_0x435144){console[_0x40afa3('0x52a')](_0x435144);}else{const _0x50b5b2={'$gte':_0x1aaf93()()['startOf'](_0x40afa3('0x55b'))[_0x40afa3('0xb11')](0x0,!![])[_0x40afa3('0x26dd')](),'$lte':_0x1aaf93()()[_0x40afa3('0x3b3')]('month')[_0x40afa3('0xb11')](0x0,!![])[_0x40afa3('0x26dd')]()};_0xade245[_0x40afa3('0x23a2')][_0x40afa3('0x1a4')]=_0x50b5b2;}_0x3e4d95();});}function _0x29bc74(){const _0x3a1ff4=_0x44f84f;return[{'name':_0x3a1ff4('0x10c1'),'key':_0x3a1ff4('0x1a4'),'type':_0x3a1ff4('0x270e'),'label':_0x3a1ff4('0x1006')},{'name':'Type','key':_0x3a1ff4('0xcf0'),'type':_0x3a1ff4('0xb31'),'label':_0x3a1ff4('0x4b4'),'customOptions':[{'value':_0x3a1ff4('0x1d43'),'translate':_0x3a1ff4('0x19ab')},{'value':_0x3a1ff4('0x1535'),'translate':_0x3a1ff4('0x16e3')},{'value':_0x3a1ff4('0x17cd'),'translate':_0x3a1ff4('0x2d8')},{'value':_0x3a1ff4('0x228a'),'translate':_0x3a1ff4('0x196c')},{'value':null,'translate':'VOICE.ALL'}]}];}function _0x3ff2b9(_0x1d6779){const _0x45e4d0=_0x44f84f;_0xade245[_0x45e4d0('0xab2')]=![],_0xade245[_0x45e4d0('0x27')]=_0x1d6779||{'count':0x0,'rows':[]};}function _0x3e4d95(){const _0x5e4729=_0x44f84f;_0xade245[_0x5e4729('0xab2')]=!![],_0xade245[_0x5e4729('0x23a2')][_0x5e4729('0x1cc8')]=(_0xade245[_0x5e4729('0x23a2')]['page']-0x1)*_0xade245[_0x5e4729('0x23a2')]['limit'];const _0x44d449={'query':_0xade245['query']};_0xd0a098['localStorage'][_0x5e4729('0x15d')]('motion2.home.voice:'+_0xade245[_0x5e4729('0x11ed')]['id'],JSON[_0x5e4729('0x258a')](_0x44d449)),_0xade245['promise']=_0x46dc47[_0x5e4729('0x337')][_0x5e4729('0x1e6e')](_0xade245[_0x5e4729('0x23a2')],_0x3ff2b9)[_0x5e4729('0xe53')];}function _0x1d485e(_0x40a56a){const _0x5e7492=_0x44f84f;_0x11e4bc[_0x5e7492('0x1d4')]({'controller':_0x5e7492('0x50'),'controllerAs':'vm','templateUrl':_0x272275,'parent':angular[_0x5e7492('0x1fcc')](_0x3abbea[_0x5e7492('0x18e5')]),'clickOutsideToClose':!![],'locals':{'call':_0x40a56a}});}function _0x213c48(){const _0x3032f9=_0x44f84f;_0xade245[_0x3032f9('0x23a2')]['filter']=undefined,_0xade245['isSearchBarVisible']=![];}function _0x522806(){_0xade245['isSearchBarVisible']=!![];}let _0x5c75af=!![],_0xa93af8=0x1;_0x40b726['$watch'](_0x44f84f('0x1e1d'),function(_0x32be43,_0xbd53d){const _0x4caced=_0x44f84f;_0x5c75af?_0x4831d8(function(){_0x5c75af=![];}):(!_0xbd53d&&(_0xa93af8=_0xade245[_0x4caced('0x23a2')]['page']),_0x32be43!==_0xbd53d&&(_0xade245['query'][_0x4caced('0xdf8')]=0x1),!_0x32be43&&(_0xade245['query'][_0x4caced('0xdf8')]=_0xa93af8),_0xade245['getVoiceCalls']());});}const _0x35a88a=_0x13eccd;_0x43e263[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x164f')];function _0x43e263(_0x13a9ac,_0x1f74c0){const _0x2c4e6d=_0x189033,_0x3845e2=this;_0x3845e2[_0x2c4e6d('0x164f')]=_0x1f74c0;function _0x1117eb(){const _0x100db1=_0x2c4e6d;_0x13a9ac[_0x100db1('0x1715')]();}_0x3845e2[_0x2c4e6d('0xf82')]=_0x1117eb;}const _0x37a84f=_0x43e263;_0x256e89[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2063'),_0x189033('0x1d08'),'api',_0x189033('0xba1'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x1777')];function _0x256e89(_0x2a5304,_0x3a070d,_0x31dbf0,_0x41007e,_0x21711c,_0x214a7c,_0x18bb3d,_0x213e87,_0x516fc4,_0x462756,_0x390aa0){const _0x2ee8a8=_0x189033,_0x3e5a5f=this;_0x3e5a5f['user']=_0x213e87['getCurrentUser'](),_0x3e5a5f[_0x2ee8a8('0xace')]={},_0x3e5a5f['setting']={},_0x3e5a5f['tags']={'count':0x0,'rows':[]},_0x3e5a5f[_0x2ee8a8('0x2740')]={'count':0x0,'rows':[]},_0x3e5a5f[_0x2ee8a8('0x23a2')]={'includeAll':!![],'sort':_0x2ee8a8('0xc36'),'limit':0xa,'page':0x1,'read':null,'closed':null},_0x3e5a5f[_0x2ee8a8('0x19c9')]={'fields':[{'name':'Id','column':'id','type':_0x2ee8a8('0x121f')},{'name':_0x2ee8a8('0x1309'),'column':_0x2ee8a8('0x1309'),'type':_0x2ee8a8('0xeb'),'options':{'searchFields':[_0x2ee8a8('0xeef'),_0x2ee8a8('0x510'),_0x2ee8a8('0x1c92')],'route':{'model':_0x2ee8a8('0x276e'),'action':_0x2ee8a8('0x1e6e'),'params':{'fields':'id,firstName,lastName,email','Contact':_0x2ee8a8('0xfd'),'nolimit':!![]}},'extraOperators':[_0x2ee8a8('0xe55')],'excludedOperators':[_0x2ee8a8('0x17ee')]}},{'name':_0x2ee8a8('0x1765'),'column':_0x2ee8a8('0x18e5'),'type':_0x2ee8a8('0x1bcd'),'options':{'excludedOperators':[_0x2ee8a8('0x393'),'$ne']}},{'name':_0x2ee8a8('0x1d9d'),'column':'closed','type':'select','values':[{'id':0x0,'translate':_0x2ee8a8('0x10b1')},{'id':0x1,'translate':_0x2ee8a8('0x270a')}],'options':{'excludedOperators':['$ne']}},{'name':_0x2ee8a8('0x62c'),'column':_0x2ee8a8('0x1dad'),'type':_0x2ee8a8('0xeb'),'options':{'table':'i','route':{'model':_0x2ee8a8('0xc96'),'action':_0x2ee8a8('0x1e6e'),'params':{'role':_0x2ee8a8('0x2327'),'fields':'id,name,fullname','nolimit':!![]}},'searchFields':[_0x2ee8a8('0x11bc'),_0x2ee8a8('0x60a')],'extraOperators':[_0x2ee8a8('0xe55')],'excludedOperators':[_0x2ee8a8('0x17ee')]}},{'name':_0x2ee8a8('0xa78'),'column':_0x2ee8a8('0x1c35'),'type':_0x2ee8a8('0xf6c'),'options':{'route':{'model':_0x2ee8a8('0xc96'),'action':_0x2ee8a8('0x1fb9'),'params':{'id':_0x3e5a5f[_0x2ee8a8('0xc96')]['id'],'nolimit':!![]}}}},{'name':_0x2ee8a8('0x198f'),'column':_0x2ee8a8('0x1e'),'type':_0x2ee8a8('0xf6c'),'options':{'route':{'model':_0x2ee8a8('0x270'),'action':_0x2ee8a8('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':['$notIn']}},{'name':'Start\x20Date','column':'createdAt','type':_0x2ee8a8('0x270e'),'options':{'excludedOperators':[_0x2ee8a8('0x17ee')]}},{'name':_0x2ee8a8('0x1bb6'),'column':_0x2ee8a8('0x122e'),'type':_0x2ee8a8('0xb31'),'values':[{'id':0x1,'translate':'DASHBOARDS.READ'},{'id':0x0,'translate':_0x2ee8a8('0x2226')}],'options':{'excludedOperators':['$ne']}}]},_0x3e5a5f[_0x2ee8a8('0xd10')]='lime-A700',_0x3e5a5f[_0x2ee8a8('0x1dd2')]=_0x26101b,_0x3e5a5f[_0x2ee8a8('0x53')]=_0x186077,_0x3e5a5f['getWhatsappInteractions']=_0xf23773,_0x3e5a5f[_0x2ee8a8('0x18c2')]=_0x24e693,_0x3e5a5f[_0x2ee8a8('0x3cb')]=_0x6c3dc9,_0x3e5a5f['disposeInteraction']=_0x3a9204,_0x3e5a5f[_0x2ee8a8('0x1dd3')]=_0x1e28fa,_0x3e5a5f[_0x2ee8a8('0x2084')]=_0xe8b8f0,_0x3e5a5f['getWhatsappAccountLabel']=_0x445ed1,_0x3e5a5f['composeWhatsappInteraction']=_0x13d541,_0x3e5a5f[_0x2ee8a8('0xb65')]=_0x32b2d1,_0x3e5a5f[_0x2ee8a8('0x229d')]=_0x23bdc5,_0x3e5a5f[_0x2ee8a8('0x2121')]=_0x134898;function _0x26101b(_0x1b79cb,_0x51bc1f){const _0x207d02=_0x2ee8a8;return _0x3e5a5f[_0x207d02('0xace')]=_0x1b79cb,_0x3e5a5f[_0x207d02('0x260a')]=_0x51bc1f,_0x18bb3d[_0x207d02('0xc96')][_0x207d02('0x1e6e')+_0x2e3ca0()[_0x207d02('0x2711')]('whatsappAccounts')]({'id':_0x3e5a5f['user']['id'],'nolimit':!![]})[_0x207d02('0xe53')]['then'](function(_0x4be7fe){const _0x3b3184=_0x207d02;return _0x3e5a5f['whatsappAccounts']=_0x4be7fe||{'count':0x0,'rows':[]},_0x18bb3d[_0x3b3184('0x270')][_0x3b3184('0x1e6e')]()[_0x3b3184('0xe53')];})['then'](function(_0x9d9a2f){_0x3e5a5f['tags']=_0x9d9a2f||{'count':0x0,'rows':[]};})[_0x207d02('0x683')](function(){const _0x2266df=_0x207d02;_0x3e5a5f[_0x2266df('0xc71')]=_0x5c2763();})[_0x207d02('0x130a')](function(_0x310269){const _0x17ca15=_0x207d02;console[_0x17ca15('0x52a')](_0x310269);})[_0x207d02('0x2874')](function(){const _0x46d4bd=_0x207d02;let _0x5856d7=_0x21711c[_0x46d4bd('0x120e')][_0x46d4bd('0x1b28')]('motion2.home.whatsapp:'+_0x3e5a5f[_0x46d4bd('0xc96')]['id']);if(_0x5856d7)try{_0x5856d7=JSON[_0x46d4bd('0x1f34')](_0x5856d7);if(_0x5856d7[_0x46d4bd('0x23a2')]){_0x3e5a5f['query']=_0x2e3ca0()['merge'](_0x3e5a5f[_0x46d4bd('0x23a2')],_0x5856d7[_0x46d4bd('0x23a2')]);if(_0x2e3ca0()[_0x46d4bd('0x173f')](_0x3e5a5f[_0x46d4bd('0x263c')][_0x46d4bd('0xf5d')]))_0x3e5a5f['query'][_0x46d4bd('0x1c35')]=[];else _0x2e3ca0()[_0x46d4bd('0x173f')](_0x3e5a5f[_0x46d4bd('0x23a2')]['WhatsappAccountId'])&&(_0x3e5a5f[_0x46d4bd('0x23a2')][_0x46d4bd('0x1c35')]=_0x2e3ca0()(_0x3e5a5f[_0x46d4bd('0x263c')]['rows'])['map']('id')[_0x46d4bd('0x22c8')]()[_0x46d4bd('0x1c6b')]());_0x3e5a5f[_0x46d4bd('0x23a2')][_0x46d4bd('0x671')]&&_0x3e5a5f[_0x46d4bd('0x23a2')][_0x46d4bd('0x671')]['indexOf'](_0x46d4bd('0x88f'))>=0x0&&(_0x3e5a5f[_0x46d4bd('0x23a2')]=_0x2e3ca0()[_0x46d4bd('0x8b5')](_0x3e5a5f[_0x46d4bd('0x23a2')],'sort')),_0x3e5a5f[_0x46d4bd('0x23a2')][_0x46d4bd('0x2761')]=!![],_0x3e5a5f[_0x46d4bd('0x1b8f')]=_0x3e5a5f[_0x46d4bd('0x23a2')][_0x46d4bd('0x25')]?!![]:![];}}catch(_0x35c266){console[_0x46d4bd('0x52a')](_0x35c266);}else{const _0x27bbfe={'$gte':_0x1aaf93()()[_0x46d4bd('0x1627')]('month')['utcOffset'](0x0,!![])[_0x46d4bd('0x26dd')](),'$lte':_0x1aaf93()()[_0x46d4bd('0x3b3')](_0x46d4bd('0x55b'))['utcOffset'](0x0,!![])[_0x46d4bd('0x26dd')]()},_0x567df4={'WhatsappAccountId':_0x2e3ca0()[_0x46d4bd('0x386')](_0x3e5a5f[_0x46d4bd('0x263c')]['rows'],'id'),'createdAt':_0x27bbfe};_0x3e5a5f[_0x46d4bd('0x23a2')]=_0x2e3ca0()[_0x46d4bd('0xf22')](_0x3e5a5f[_0x46d4bd('0x23a2')],_0x567df4);}_0x516fc4['on'](_0x46d4bd('0x42b'),_0x5a044c),_0x516fc4['on'](_0x46d4bd('0x20b'),_0x5a044c),_0x516fc4['on'](_0x46d4bd('0x116c'),_0x49b576),_0x516fc4['on'](_0x46d4bd('0x22a7'),_0xc427c2),_0x516fc4['on'](_0x46d4bd('0x16b'),_0xc427c2),_0x516fc4['on'](_0x46d4bd('0xfaf'),_0x28a029),_0x516fc4['on'](_0x46d4bd('0x2049'),_0x3eca01),_0xf23773(_0x3e5a5f[_0x46d4bd('0x23a2')]['page']);});}function _0x5c2763(){const _0x116e2e=_0x2ee8a8;return[{'name':_0x116e2e('0x10c1'),'key':_0x116e2e('0x1a4'),'type':_0x116e2e('0x270e'),'label':'DASHBOARDS.SELECT_DATE'},{'name':_0x116e2e('0xc51'),'key':_0x116e2e('0x20db'),'type':_0x116e2e('0xb31'),'label':_0x116e2e('0x1866'),'customOptions':[{'value':0x0,'translate':_0x116e2e('0x2226')},{'value':0x1,'translate':'DASHBOARDS.READ'},{'value':null,'translate':_0x116e2e('0x475')}]},{'name':'Status','key':_0x116e2e('0xd8a'),'type':'select','label':_0x116e2e('0x1b77'),'customOptions':[{'value':0x0,'translate':_0x116e2e('0x10b1')},{'value':0x1,'translate':_0x116e2e('0x270a')},{'value':null,'translate':_0x116e2e('0x475')}]},{'name':_0x116e2e('0xa78'),'key':_0x116e2e('0x1c35'),'type':'multiselect','label':_0x116e2e('0x1202'),'options':_0x3e5a5f[_0x116e2e('0x263c')][_0x116e2e('0xf5d')],'clearAll':![]},{'name':'Agent','key':'UserId','type':_0x116e2e('0xb31'),'label':_0x116e2e('0x21fb'),'customOptions':[{'value':_0x3e5a5f[_0x116e2e('0xc96')]['id'],'translate':'DASHBOARDS.ME'},{'value':_0x116e2e('0x13c'),'translate':'DASHBOARDS.NOT_ASSIGNED'},{'value':undefined,'translate':_0x116e2e('0x475')}]},{'name':'Tag','key':_0x116e2e('0x270'),'type':'multiselect','label':'DASHBOARDS.SELECT_TAG','options':_0x3e5a5f[_0x116e2e('0x1ce6')][_0x116e2e('0xf5d')],'placeholder':_0x116e2e('0x7cb')}];}function _0x186077(_0x27ef84){const _0x479d2d=_0x2ee8a8;_0x3e5a5f[_0x479d2d('0xab2')]=![],_0x3e5a5f[_0x479d2d('0x2740')]=_0x27ef84||{'count':0x0,'rows':[]};for(let _0x160dc3=0x0;_0x160dc3<_0x3e5a5f[_0x479d2d('0x2740')][_0x479d2d('0xf5d')][_0x479d2d('0x1564')];_0x160dc3+=0x1){_0x1e28fa(_0x3e5a5f[_0x479d2d('0x2740')][_0x479d2d('0xf5d')][_0x160dc3]);}}function _0xf23773(_0x1389d3){const _0x33ecf9=_0x2ee8a8;_0x3e5a5f[_0x33ecf9('0xab2')]=!![];!_0x1389d3&&(_0x3e5a5f[_0x33ecf9('0x23a2')][_0x33ecf9('0xdf8')]=0x1);_0x3e5a5f[_0x33ecf9('0x23a2')][_0x33ecf9('0x1cc8')]=(_0x3e5a5f[_0x33ecf9('0x23a2')][_0x33ecf9('0xdf8')]-0x1)*_0x3e5a5f[_0x33ecf9('0x23a2')][_0x33ecf9('0x6f0')];let _0x40edef=_0x21711c['localStorage'][_0x33ecf9('0x1b28')]('motion2.home.whatsapp:'+_0x3e5a5f['user']['id']);_0x40edef=_0x40edef?JSON[_0x33ecf9('0x1f34')](_0x40edef):{},_0x40edef['query']=_0x3e5a5f[_0x33ecf9('0x23a2')],_0x21711c['localStorage'][_0x33ecf9('0x15d')](_0x33ecf9('0x1884')+_0x3e5a5f[_0x33ecf9('0xc96')]['id'],JSON[_0x33ecf9('0x258a')](_0x40edef)),_0x3e5a5f[_0x33ecf9('0x1883')]=_0x18bb3d[_0x33ecf9('0x1db7')][_0x33ecf9('0x1e6e')](_0x3e5a5f[_0x33ecf9('0x23a2')],_0x186077)[_0x33ecf9('0xe53')];}function _0x24e693(_0x160137,_0x51b1d6){const _0x331183=_0x2ee8a8;_0x2a5304[_0x331183('0x1cd5')]['vm'][_0x331183('0x297')](_0x331183('0x16e7'),_0x51b1d6);}function _0x6c3dc9(_0x1cda12,_0x391492,_0x56f336){const _0x280227=_0x2ee8a8;_0x18bb3d[_0x280227('0x1db7')][_0x280227('0x18e8')]({'id':_0x391492['id'],'attachments':_0x56f336})['$promise']['then'](function(_0x3549e8){const _0xfb646a=_0x280227,_0x3bef8e=[_0x3549e8['buffer']],_0x232128='whatsapp-interaction'+_0x391492['id']+_0xfb646a('0x18ff'),_0x2033d4=new Blob(_0x3bef8e,{'type':_0x3549e8[_0xfb646a('0xcf0')]}),_0x2a4755=window[_0xfb646a('0x12e1')][_0xfb646a('0x1ffa')]('a');_0x2a4755[_0xfb646a('0x130f')]('href',URL[_0xfb646a('0x2820')](_0x2033d4)),_0x2a4755[_0xfb646a('0x130f')]('download',_0x232128),document[_0xfb646a('0x18e5')][_0xfb646a('0x1e43')](_0x2a4755),_0x2a4755[_0xfb646a('0x1d42')]();})[_0x280227('0x130a')](function(_0x42387b){const _0x4434fe=_0x280227;if(_0x42387b[_0x4434fe('0x5a5')]&&_0x42387b['data'][_0x4434fe('0x17f')]&&_0x42387b[_0x4434fe('0x5a5')]['errors'][_0x4434fe('0x1564')])for(let _0x4cb9df=0x0;_0x4cb9df<_0x42387b['data']['errors']['length'];_0x4cb9df+=0x1){_0x462756[_0x4434fe('0x52a')]({'title':_0x42387b[_0x4434fe('0x5a5')][_0x4434fe('0x17f')][_0x4cb9df]['type'],'msg':_0x42387b[_0x4434fe('0x5a5')][_0x4434fe('0x17f')][_0x4cb9df][_0x4434fe('0x8c2')]});}else _0x462756['error']({'title':_0x42387b[_0x4434fe('0x13ee')]?_0x4434fe('0x2168')+_0x42387b[_0x4434fe('0x13ee')]+_0x4434fe('0xbf6')+_0x42387b['statusText']:_0x4434fe('0x3cb'),'msg':_0x42387b['data']?JSON['stringify'](_0x42387b['data'][_0x4434fe('0x8c2')]):_0x42387b[_0x4434fe('0x1ff0')]()});});}function _0x3a9204(_0x103198,_0x105279){const _0x7ba31a=_0x2ee8a8,_0x410cba=_0x3e5a5f[_0x7ba31a('0xc96')][_0x7ba31a('0x1431')]||_0x3e5a5f[_0x7ba31a('0xc96')][_0x7ba31a('0x1938')]||_0x3e5a5f[_0x7ba31a('0xc96')][_0x7ba31a('0x774')]||_0x3e5a5f[_0x7ba31a('0xc96')][_0x7ba31a('0x1a11')]||_0x3e5a5f[_0x7ba31a('0xc96')]['faxPause'],_0x5a186b=!_0x105279[_0x7ba31a('0xa78')][_0x7ba31a('0x989')];_0x31dbf0['show']({'controller':_0x7ba31a('0x14a7'),'controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular['element'](_0x41007e[_0x7ba31a('0x18e5')]),'clickOutsideToClose':_0x5a186b,'escapeToClose':_0x5a186b,'onRemoving':function(){const _0x3f1652=_0x7ba31a;_0x3e5a5f[_0x3f1652('0xc96')]&&_0x105279[_0x3f1652('0xa78')][_0x3f1652('0x989')]&&!_0x410cba&&_0x18bb3d[_0x3f1652('0xc96')][_0x3f1652('0x1778')]({'id':_0x3e5a5f['user']['id']})[_0x3f1652('0xe53')]['catch'](function(_0x475434){console['error'](_0x475434);});},'locals':{'user':_0x3e5a5f['user'],'channel':'whatsapp','interaction':_0x105279}});}function _0x1e28fa(_0x4e042c){const _0x4656ef=_0x2ee8a8;_0x4e042c[_0x4656ef('0x1309')]?(_0x4e042c[_0x4656ef('0x12b3')]=(_0x4e042c[_0x4656ef('0x1309')][_0x4656ef('0xeef')]||'')+'\x20'+(_0x4e042c[_0x4656ef('0x1309')][_0x4656ef('0x510')]||''),_0x4e042c['contactInfo']=_0x4e042c['Contact']['mobile']):_0x4e042c['contactName']=_0x214a7c[_0x4656ef('0x2728')](_0x4656ef('0x215e'));}function _0xe8b8f0(_0x901004){const _0x30591d=_0x2ee8a8;if(_0x901004['UserId'])return _0x901004[_0x30591d('0x10c5')]===_0x3e5a5f['user']['id']?_0x214a7c['instant'](_0x30591d('0x96a')):_0x901004['Owner'][_0x30591d('0x11bc')]+'\x20<'+_0x901004[_0x30591d('0x2464')][_0x30591d('0x1d43')]+'>';return _0x214a7c['instant']('DASHBOARDS.NOT_ASSIGNED');}function _0x445ed1(_0x5e62c1){const _0x45370d=_0x2ee8a8;if(_0x5e62c1[_0x45370d('0xa78')])return _0x5e62c1[_0x45370d('0xa78')][_0x45370d('0x1d46')];return _0x214a7c[_0x45370d('0x2728')]('DASHBOARDS.UNKNOWN');}function _0x13d541(_0xf201a1,_0x3e2afe){const _0x12256f=_0x2ee8a8;_0x31dbf0['show']({'controller':_0x12256f('0x1dec'),'controllerAs':'vm','templateUrl':_0x4cefce,'parent':angular[_0x12256f('0x1fcc')](_0x41007e[_0x12256f('0x18e5')]),'clickOutsideToClose':![],'locals':{'account':_0x3e2afe,'message':{},'type':_0x12256f('0x1476'),'interaction':{}},'fullscreen':!![]})[_0x12256f('0x683')](function(_0x1d7d3a){const _0x34681f=_0x12256f;if(_0x1d7d3a){if(_0x1d7d3a[_0x34681f('0x8c2')]&&_0x1d7d3a['message'][_0x34681f('0x250b')]){const _0x2887c6={'channel':'whatsapp','account':_0x3e2afe,'message':_0x1d7d3a[_0x34681f('0x8c2')],'contact':_0x1d7d3a['contact']};_0x390aa0['add'](_0x2887c6);}else{const _0xc3ea1d=_0x1d7d3a;return _0x18bb3d['whatsappAccount']['send']({'id':_0x3e2afe['id']},_0xc3ea1d)['$promise'][_0x34681f('0x683')](function(_0x27b82c){const _0x3ccf65=_0x34681f;_0x462756[_0x3ccf65('0x53')]({'title':_0x3ccf65('0xb96'),'msg':_0x3ccf65('0x21a1')}),_0x2a5304[_0x3ccf65('0x1cd5')]['vm'][_0x3ccf65('0x297')](_0x3ccf65('0x16e7'),_0x27b82c);})[_0x34681f('0x130a')](function(_0x2a8aca){const _0x7ddd04=_0x34681f;if(_0x2a8aca[_0x7ddd04('0x5a5')]&&_0x2a8aca[_0x7ddd04('0x5a5')][_0x7ddd04('0x17f')]&&_0x2a8aca[_0x7ddd04('0x5a5')][_0x7ddd04('0x17f')]['length'])for(let _0x260075=0x0;_0x260075<_0x2a8aca[_0x7ddd04('0x5a5')]['errors'][_0x7ddd04('0x1564')];_0x260075++){_0x462756['error']({'title':_0x2a8aca[_0x7ddd04('0x5a5')][_0x7ddd04('0x17f')][_0x260075][_0x7ddd04('0xcf0')],'msg':_0x2a8aca[_0x7ddd04('0x5a5')][_0x7ddd04('0x17f')][_0x260075][_0x7ddd04('0x8c2')]});}else _0x462756[_0x7ddd04('0x52a')]({'title':_0x2a8aca[_0x7ddd04('0x13ee')]?_0x7ddd04('0x2168')+_0x2a8aca[_0x7ddd04('0x13ee')]+_0x7ddd04('0xbf6')+_0x2a8aca['statusText']:'WHATSAPPACCOUNT:SEND','msg':_0x2a8aca['data']?JSON[_0x7ddd04('0x258a')](_0x2a8aca['data']['message']):_0x2a8aca['message']||_0x2a8aca[_0x7ddd04('0x1ff0')]()});});}}});}function _0x28a029(_0x5991f7){const _0x27e242=_0x2ee8a8;let _0x2228ec;const _0x5af0eb=_0x2e3ca0()['find'](_0x3e5a5f[_0x27e242('0x2740')][_0x27e242('0xf5d')],{'id':_0x5991f7[_0x27e242('0x28b')]});_0x5af0eb&&_0x5af0eb[_0x27e242('0x2139')]&&(_0x2228ec=_0x2e3ca0()[_0x27e242('0x1c07')](_0x5af0eb[_0x27e242('0x2139')],{'id':_0x5991f7['UserId']}),!_0x2228ec&&_0x5af0eb['Users'][_0x27e242('0x1fd0')]({'id':_0x5991f7['UserId']}));}function _0x3eca01(_0x5c1daf){const _0x4371a3=_0x2ee8a8,_0x3fa8f3=_0x2e3ca0()['find'](_0x3e5a5f[_0x4371a3('0x2740')][_0x4371a3('0xf5d')],{'id':_0x5c1daf[_0x4371a3('0x28b')]});_0x3fa8f3&&_0x3fa8f3[_0x4371a3('0x2139')]&&_0x2e3ca0()[_0x4371a3('0x3ec')](_0x3fa8f3[_0x4371a3('0x2139')],{'id':_0x5c1daf[_0x4371a3('0x10c5')]});}function _0x5a044c(_0x77dd8a){const _0x36ef56=_0x2ee8a8;if(_0x77dd8a){const _0x2f1313=_0x2e3ca0()[_0x36ef56('0x1c07')](_0x3e5a5f[_0x36ef56('0x2740')][_0x36ef56('0xf5d')],{'id':_0x77dd8a['id']});if(_0x2f1313){_0x2f1313['Users']=[];_0x77dd8a[_0x36ef56('0xd8a')]&&(_0x2f1313[_0x36ef56('0x122e')]=0x0);if(_0x3e5a5f[_0x36ef56('0x23a2')][_0x36ef56('0x671')]){const _0x1089e3=_0x2e3ca0()['startsWith'](_0x3e5a5f[_0x36ef56('0x23a2')]['sort'],'-')?'desc':_0x36ef56('0xe38');_0x3e5a5f[_0x36ef56('0x2740')]['rows']=_0x2e3ca0()['orderBy'](_0x3e5a5f[_0x36ef56('0x2740')][_0x36ef56('0xf5d')],_0x2e3ca0()[_0x36ef56('0x1fe0')](_0x3e5a5f['query'][_0x36ef56('0x671')],'-'),_0x1089e3);}_0x2e3ca0()[_0x36ef56('0xf22')](_0x2f1313,_0x2e3ca0()['pick'](_0x77dd8a,_0x2e3ca0()['keys'](_0x2f1313)));}else _0xf23773(_0x3e5a5f[_0x36ef56('0x23a2')][_0x36ef56('0xdf8')]);}}function _0x49b576(_0x47008b){const _0x598fa9=_0x2ee8a8;if(_0x47008b){const _0x4e0bbd=_0x2e3ca0()['find'](_0x3e5a5f[_0x598fa9('0x2740')][_0x598fa9('0xf5d')],{'id':_0x47008b['id']});_0x4e0bbd&&(_0x4e0bbd['Tags']=_0x47008b[_0x598fa9('0x1ce6')]||[],_0x2e3ca0()[_0x598fa9('0xf22')](_0x4e0bbd,_0x2e3ca0()[_0x598fa9('0x24d0')](_0x47008b,_0x2e3ca0()[_0x598fa9('0x55e')](_0x4e0bbd))));}}function _0xc427c2(_0x24b428){const _0x5d81e6=_0x2ee8a8;if(_0x24b428&&!_0x24b428[_0x5d81e6('0x252d')]){const _0x3353e7=_0x2e3ca0()[_0x5d81e6('0x1c07')](_0x3e5a5f[_0x5d81e6('0x2740')][_0x5d81e6('0xf5d')],{'id':_0x24b428[_0x5d81e6('0x28b')]});if(_0x3353e7){const _0x289063=_0x2e3ca0()[_0x5d81e6('0x1c07')](_0x3353e7[_0x5d81e6('0xc51')],{'id':_0x24b428['id']});_0x289063?_0x2e3ca0()[_0x5d81e6('0xf22')](_0x289063,_0x2e3ca0()[_0x5d81e6('0x24d0')](_0x24b428,_0x2e3ca0()[_0x5d81e6('0x55e')](_0x289063))):(_0x2e3ca0()[_0x5d81e6('0x8f2')](_0x3353e7['Messages'])&&(_0x3353e7[_0x5d81e6('0xc51')]={'count':0x0}),!_0x24b428['read']&&(_0x3353e7['Messages'][_0x5d81e6('0x50d')]+=0x1));}}}function _0x32b2d1(){const _0x3b5f94=_0x2ee8a8;_0x3e5a5f[_0x3b5f94('0x1b8f')]=![];}function _0x23bdc5(){const _0x3eb6f7=_0x2ee8a8;_0x3e5a5f[_0x3eb6f7('0x1b8f')]=!![];}function _0x134898(){const _0x450dc5=_0x2ee8a8;_0x3e5a5f[_0x450dc5('0x1b8f')]=![],_0x31dbf0[_0x450dc5('0x1d4')]({'controller':_0x450dc5('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x450dc5('0x1fcc')](_0x41007e['body']),'clickOutsideToClose':![],'locals':{'color':_0x3e5a5f[_0x450dc5('0xd10')],'fields':_0x3e5a5f[_0x450dc5('0x19c9')][_0x450dc5('0x189a')],'storagePath':_0x450dc5('0x1782')},'fullscreen':!![]})[_0x450dc5('0x683')](function(_0x36d606){const _0x2f66ec=_0x450dc5;_0x3e5a5f[_0x2f66ec('0x23a2')][_0x2f66ec('0x19a4')]=_0x36d606===![]?undefined:_0x36d606;if(_0x3e5a5f['query'][_0x2f66ec('0x19a4')]||_0x36d606===![])_0xf23773();})['catch'](function(_0x280880){const _0x15507e=_0x450dc5;_0x462756['error']({'title':'ERROR','msg':_0x280880['data']?JSON[_0x15507e('0x258a')](_0x280880[_0x15507e('0x5a5')][_0x15507e('0x8c2')]):_0x280880['toString']()});});}let _0x566253=!![],_0x1a7292=0x1;_0x2a5304[_0x2ee8a8('0x186d')](_0x2ee8a8('0x1e1d'),function(_0x250660,_0x387510){const _0x3a286a=_0x2ee8a8;_0x566253?_0x3a070d(function(){_0x566253=![];}):(!_0x387510&&(_0x1a7292=_0x3e5a5f[_0x3a286a('0x23a2')][_0x3a286a('0xdf8')]),_0x250660!==_0x387510&&(_0x3e5a5f[_0x3a286a('0x23a2')][_0x3a286a('0xdf8')]=0x1),!_0x250660&&(_0x3e5a5f[_0x3a286a('0x23a2')][_0x3a286a('0xdf8')]=_0x1a7292),_0xf23773(_0x3e5a5f[_0x3a286a('0x23a2')][_0x3a286a('0xdf8')]));}),_0x2a5304[_0x2ee8a8('0x26a2')](_0x2ee8a8('0x4b8'),function(){const _0xb6468c=_0x2ee8a8;_0x516fc4[_0xb6468c('0x1b9e')](_0xb6468c('0x22a7')),_0x516fc4[_0xb6468c('0x1b9e')](_0xb6468c('0x16b')),_0x516fc4[_0xb6468c('0x1b9e')](_0xb6468c('0x42b')),_0x516fc4[_0xb6468c('0x1b9e')](_0xb6468c('0x116c')),_0x516fc4[_0xb6468c('0x1b9e')](_0xb6468c('0x20b')),_0x516fc4[_0xb6468c('0x1b9e')]('user_has_whatsapp_interactions:save'),_0x516fc4['removeAllListeners'](_0xb6468c('0x2049'));});}const _0x59d1ea=_0x256e89;_0x432044[_0x189033('0x14be')]=['$scope',_0x189033('0x204d')];function _0x432044(_0x46091b,_0x311e6b){const _0x37c20e=_0x189033,_0x170a77=this;_0x170a77[_0x37c20e('0x260a')]={},_0x170a77[_0x37c20e('0x2636')]={'count':0x0,'rows':[]},_0x170a77[_0x37c20e('0x15c9')]=![];function _0x1b054f(_0x30fa6f,_0xeb7335){const _0x4b8643=_0x37c20e;_0x170a77[_0x4b8643('0x260a')]=_0xeb7335,_0x170a77[_0x4b8643('0x1904')]=_0x30fa6f,_0x170a77[_0x4b8643('0x1904')][_0x4b8643('0x118c')]=!![];}function _0x3c7bab(){return _0x311e6b['trustAsResourceUrl'](_0x170a77['tab']['src']);}_0x170a77[_0x37c20e('0x12f3')]=_0x1b054f,_0x170a77[_0x37c20e('0x2276')]=_0x3c7bab;}const _0x397a88=_0x432044,_0xb83f7a=_0x180212['p']+_0x189033('0x1c51'),_0x242cfc=_0x180212['p']+_0x189033('0x27cd');_0x4202f8[_0x189033('0x14be')]=[_0x189033('0x204d')],_0x2944e3['$inject']=['$cookies',_0x189033('0x2f9'),_0x189033('0x16ea'),_0x189033('0x7a5'),_0x189033('0x1e48'),'$q',_0x189033('0xb8d'),_0x189033('0x1d08'),'api',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x1556'),'msUtils','draftManager'];function _0x2944e3(_0x5d062c,_0x7ccb5e,_0x588794,_0x5021f4,_0x5e83cf,_0x2a20da,_0x41c4a5,_0x3a9ba7,_0x349545,_0x119769,_0x45c6f1,_0x32e50a,_0x1a760,_0x2c570a){const _0x19a11d=_0x189033,_0x1e97a9=this,_0x1f1c1b=0x19,_0x2b1975=_0x1f1c1b*0x400*0x400;_0x1e97a9[_0x19a11d('0x2763')]=![],_0x1e97a9['showInteraction']=![],_0x1e97a9['user']=_0x45c6f1[_0x19a11d('0x20b2')](),_0x1e97a9[_0x19a11d('0x262b')]=_0x1a760[_0x19a11d('0x262b')](),_0x1e97a9[_0x19a11d('0x18b')]=[],_0x1e97a9['acceptedMessages']=[],_0x1e97a9[_0x19a11d('0xbd7')]=['mail',_0x19a11d('0x24e'),_0x19a11d('0x1285'),_0x19a11d('0x1261'),_0x19a11d('0x23e9'),_0x19a11d('0x16e7')],_0x1e97a9[_0x19a11d('0x8f')]={'target':'api/attachments','singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x2b1975,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x1e97a9['ngFlow']={'flow':{}},_0x1e97a9['selectedMailShowDetails']={},_0x1e97a9[_0x19a11d('0x171e')]={},_0x1e97a9[_0x19a11d('0x260a')]={},_0x1e97a9[_0x19a11d('0x1ee5')]={},_0x1e97a9['embedOptions']={'fontSmiley':!![],'sanitizeHtml':!![],'emoji':!![],'link':!![],'linkTarget':_0x19a11d('0x18b3')},_0x1e97a9[_0x19a11d('0xe5f')]=new Date(_0x1aaf93()()[_0x19a11d('0x1627')](_0x19a11d('0x55b'))['subtract'](0x1,_0x19a11d('0x1b53'))['utcOffset'](0x0,!![])[_0x19a11d('0x26dd')]()),_0x1e97a9[_0x19a11d('0x1686')]=new Date(_0x1aaf93()()[_0x19a11d('0x3b3')](_0x19a11d('0x55b'))[_0x19a11d('0x1315')](0x1,_0x19a11d('0x1efa'))['utcOffset'](0x0,!![])['format']()),_0x1e97a9[_0x19a11d('0x12f3')]=_0x3daa7b,_0x1e97a9[_0x19a11d('0x9d2')]=_0x2a916d,_0x1e97a9[_0x19a11d('0x18e3')]=_0x22c98c,_0x1e97a9['openInteraction']=_0x5c5cc3,_0x1e97a9[_0x19a11d('0x14b7')]=_0x4a8e51,_0x1e97a9['tagInteraction']=_0x4f7316,_0x1e97a9[_0x19a11d('0x5e5')]=_0x12fb7e,_0x1e97a9['composeFaxInteraction']=_0x53f107,_0x1e97a9[_0x19a11d('0x77f')]=_0x5e6c84,_0x1e97a9[_0x19a11d('0x12ab')]=_0xaf212,_0x1e97a9[_0x19a11d('0x1e17')]=_0x18561e,_0x1e97a9[_0x19a11d('0x113')]=_0x18fd00,_0x1e97a9['downloadInteraction']=_0x9bbe,_0x1e97a9[_0x19a11d('0x10d6')]=_0x24366a,_0x1e97a9[_0x19a11d('0x129b')]=_0x25713d,_0x1e97a9[_0x19a11d('0x2872')]=_0x4c9ba6,_0x1e97a9[_0x19a11d('0x2842')]=_0x55be46,_0x1e97a9['getSmsAccounts']=_0x2424df,_0x1e97a9[_0x19a11d('0x1fb9')]=_0x5e69d5,_0x1e97a9[_0x19a11d('0x24e3')]=_0x40313c,_0x1e97a9[_0x19a11d('0x24ee')]=_0x396a63,_0x1e97a9['getLists']=_0x4dcc72,_0x1e97a9['reply']=_0x236cac,_0x1e97a9[_0x19a11d('0xa03')]=_0x349e21,_0x1e97a9['fileAdded']=_0x1e5956,_0x1e97a9[_0x19a11d('0x1152')]=_0x2c7055,_0x1e97a9[_0x19a11d('0x186a')]=_0x214fff,_0x1e97a9[_0x19a11d('0x258e')]=_0x221cbb,_0x1e97a9[_0x19a11d('0x1361')]=_0xec3c2a,_0x1e97a9[_0x19a11d('0x5a2')]=_0x23f46f,_0x1e97a9[_0x19a11d('0x1132')]=_0x208396,_0x1e97a9[_0x19a11d('0x2590')]=_0x5dd113,_0x1e97a9[_0x19a11d('0x14d4')]=_0x30e3d1,_0x1e97a9[_0x19a11d('0x2fb')]=_0x318585,_0x1e97a9[_0x19a11d('0x1ec')]=![],_0x1e97a9[_0x19a11d('0x2220')]=_0x29b313,_0x1e97a9[_0x19a11d('0x22aa')]=_0x2b4a3a,_0x1e97a9['markAsUnread']=_0x1d1c72,_0x1e97a9[_0x19a11d('0xf71')]=_0xa70edf,_0x1e97a9[_0x19a11d('0x794')]=_0x5a85ee,_0x1e97a9['getAttachment']=_0x42e1fd,_0x1e97a9['htmlToPlaintext']=_0xe9f559,_0x1e97a9[_0x19a11d('0xd5')]=_0x574ebf,_0x1e97a9[_0x19a11d('0xbea')]=_0x5e3a64,_0x1e97a9[_0x19a11d('0x27e1')]=_0x436104,_0x1e97a9[_0x19a11d('0x1c87')]={'scrollEl':_0x19a11d('0x1789')};function _0x396a63(){const _0x530755=_0x19a11d;_0x349545['user'][_0x530755('0x24ee')]({'id':_0x1e97a9['user']['id'],'nolimit':!![]})['$promise'][_0x530755('0x683')](function(_0x5d2fe2){const _0x5000cf=_0x530755;_0x1e97a9[_0x5000cf('0x11e2')]=_0x5d2fe2||{'count':0x0,'rows':[]};});}function _0x4dcc72(){const _0x178973=_0x19a11d;_0x349545[_0x178973('0xc96')]['getLists']({'id':_0x1e97a9[_0x178973('0xc96')]['id'],'nolimit':!![]})[_0x178973('0xe53')][_0x178973('0x683')](function(_0x1d5fec){_0x1e97a9['voiceAccounts']=_0x1d5fec||{'count':0x0,'rows':[]};});}function _0x40313c(){const _0x2f64c7=_0x19a11d;_0x349545[_0x2f64c7('0xc96')][_0x2f64c7('0x24e3')]({'id':_0x1e97a9[_0x2f64c7('0xc96')]['id'],'nolimit':!![]})[_0x2f64c7('0xe53')]['then'](function(_0x12aba1){const _0x103947=_0x2f64c7;_0x1e97a9[_0x103947('0x1952')]=_0x12aba1||{'count':0x0,'rows':[]};})[_0x2f64c7('0x130a')](function(_0x6c374f){const _0x44429f=_0x2f64c7;if(_0x6c374f[_0x44429f('0x5a5')]&&_0x6c374f[_0x44429f('0x5a5')][_0x44429f('0x17f')]&&_0x6c374f['data'][_0x44429f('0x17f')]['length']){_0x1e97a9[_0x44429f('0x17f')]=_0x6c374f['data'][_0x44429f('0x17f')]||[{'message':_0x6c374f[_0x44429f('0x1ff0')](),'type':_0x44429f('0x1a3b')}];for(let _0x34beab=0x0;_0x34beab<_0x6c374f[_0x44429f('0x5a5')][_0x44429f('0x17f')][_0x44429f('0x1564')];_0x34beab+=0x1){_0x119769['error']({'title':_0x6c374f['data'][_0x44429f('0x17f')][_0x34beab]['type'],'msg':_0x6c374f[_0x44429f('0x5a5')][_0x44429f('0x17f')][_0x34beab][_0x44429f('0x8c2')]});}}else _0x119769[_0x44429f('0x52a')]({'title':_0x6c374f[_0x44429f('0x13ee')]?_0x44429f('0x2168')+_0x6c374f[_0x44429f('0x13ee')]+'\x20-\x20'+_0x6c374f['statusText']:_0x44429f('0x1a3b'),'msg':_0x6c374f[_0x44429f('0x5a5')]?JSON[_0x44429f('0x258a')](_0x6c374f[_0x44429f('0x5a5')][_0x44429f('0x8c2')]):_0x6c374f['toString']()});});}function _0x4c9ba6(){const _0x505485=_0x19a11d;_0x349545[_0x505485('0xc96')][_0x505485('0x2872')]({'id':_0x1e97a9['user']['id'],'nolimit':!![]})[_0x505485('0xe53')][_0x505485('0x683')](function(_0x112485){const _0x3a283c=_0x505485;_0x1e97a9[_0x3a283c('0x1093')]=_0x112485||{'count':0x0,'rows':[]};});}function _0x55be46(){const _0x413153=_0x19a11d;_0x349545['user'][_0x413153('0x2842')]({'id':_0x1e97a9['user']['id'],'nolimit':!![]})[_0x413153('0xe53')][_0x413153('0x683')](function(_0x596dae){const _0x29b1db=_0x413153;_0x1e97a9[_0x29b1db('0x2595')]=_0x596dae||{'count':0x0,'rows':[]};});}function _0x2424df(){const _0x13ad71=_0x19a11d;_0x349545['user'][_0x13ad71('0xf1e')]({'id':_0x1e97a9[_0x13ad71('0xc96')]['id'],'nolimit':!![]})['$promise'][_0x13ad71('0x683')](function(_0x2ce61b){const _0x2ac5dd=_0x13ad71;_0x1e97a9[_0x2ac5dd('0x197c')]=_0x2ce61b||{'count':0x0,'rows':[]};});}function _0x5e69d5(){const _0x2c236e=_0x19a11d;_0x349545[_0x2c236e('0xc96')][_0x2c236e('0x1fb9')]({'id':_0x1e97a9['user']['id'],'nolimit':!![]})[_0x2c236e('0xe53')]['then'](function(_0x4b1efc){_0x1e97a9['whatsappAccounts']=_0x4b1efc||{'count':0x0,'rows':[]};});}function _0x436104(){const _0x514402=_0x19a11d,_0x5eeecd=_0x2a20da[_0x514402('0x448')]();if(_0x1e97a9[_0x514402('0x18c4')])return _0x1e97a9[_0x514402('0x18c4')][_0x514402('0x1cc8')]=_0x1e97a9[_0x514402('0x2636')]['rows'][_0x514402('0x1564')],_0x349545[_0x1e97a9['tab'][_0x514402('0xdd6')]+'Interaction']['getMessages'](_0x1e97a9[_0x514402('0x18c4')])[_0x514402('0xe53')]['then'](function(_0x4dc74f){const _0x26d4e7=_0x514402;for(let _0x3edda7=0x0;_0x3edda7<_0x4dc74f[_0x26d4e7('0xf5d')][_0x26d4e7('0x1564')];_0x3edda7+=0x1){_0x1e97a9[_0x26d4e7('0x2636')][_0x26d4e7('0xf5d')][_0x26d4e7('0x1fd0')](_0x4dc74f[_0x26d4e7('0xf5d')][_0x3edda7]),!_0x1e97a9[_0x26d4e7('0xa98')]['closed']&&_0x4dc74f[_0x26d4e7('0xf5d')][_0x3edda7][_0x26d4e7('0x2655')]==='in'&&!_0x4dc74f[_0x26d4e7('0xf5d')][_0x3edda7][_0x26d4e7('0x20db')]&&(_0x349545[_0x1e97a9[_0x26d4e7('0x1904')]['channel']+_0x26d4e7('0x205e')][_0x26d4e7('0xd84')]({'id':_0x4dc74f[_0x26d4e7('0xf5d')][_0x3edda7]['id'],'UserId':_0x1e97a9['user']['id']}),_0x1e97a9['acceptedMessages'][_0x26d4e7('0x1fd0')](_0x4dc74f[_0x26d4e7('0xf5d')][_0x3edda7]['id']));}return _0x5eeecd['resolve'](_0x4dc74f);})[_0x514402('0x130a')](function(_0x5b027a){const _0x2e404a=_0x514402;return _0x5eeecd[_0x2e404a('0xfae')](_0x5b027a);});return _0x5eeecd[_0x514402('0xfae')]();}function _0x3daa7b(_0x38dbfc,_0x5e4601){const _0x222f04=_0x19a11d;_0x1e97a9[_0x222f04('0x1904')]=_0x38dbfc,_0x1e97a9['tab'][_0x222f04('0x118c')]=!![],_0x1e97a9[_0x222f04('0x1904')]['badges']=0x0,_0x1e97a9[_0x222f04('0x260a')]=_0x5e4601||{},_0x1e97a9[_0x222f04('0x1904')]&&_0x1e97a9[_0x222f04('0x1904')][_0x222f04('0xdd6')]&&_0x1e97a9[_0x222f04('0x1904')][_0x222f04('0xa98')]&&(_0x1e97a9[_0x222f04('0xa98')]=_0x1e97a9['tab']['interaction'],_0x349545[_0x1e97a9[_0x222f04('0x1904')][_0x222f04('0xdd6')]+_0x222f04('0x1896')]['get']({'id':_0x1e97a9[_0x222f04('0x1904')]['interaction']['id'],'includeAll':!![]})[_0x222f04('0xe53')][_0x222f04('0x683')](function(_0x561615){const _0x44bcc9=_0x222f04;return _0x561615&&(_0x1e97a9['interaction']=_0x561615,_0x1e97a9['tab']['interaction']=_0x561615),_0x1e97a9['tab']['saved']=_0x1e97a9[_0x44bcc9('0xa98')][_0x44bcc9('0xd8a')],_0x1e97a9[_0x44bcc9('0x18c4')]={'id':_0x1e97a9[_0x44bcc9('0xa98')]['id'],'includeAll':!![]},_0x1e97a9['tab'][_0x44bcc9('0xdd6')]===_0x44bcc9('0x129f')?(_0x1e97a9[_0x44bcc9('0x18c4')][_0x44bcc9('0x671')]=_0x44bcc9('0x24aa'),_0x1e97a9['queryMessage'][_0x44bcc9('0x1cc8')]=0x0,_0x1e97a9[_0x44bcc9('0x18c4')]['limit']=0x3):(_0x1e97a9['queryMessage']['sort']='id',_0x1e97a9[_0x44bcc9('0x18c4')][_0x44bcc9('0x2088')]=!![]),_0x349545[_0x1e97a9[_0x44bcc9('0x1904')][_0x44bcc9('0xdd6')]+_0x44bcc9('0x1896')]['getMessages'](_0x1e97a9['queryMessage'])[_0x44bcc9('0xe53')];})[_0x222f04('0x683')](function(_0xf9059){const _0x532ec2=_0x222f04;return _0x1e97a9[_0x532ec2('0x2636')]=_0xf9059||{'count':0x0,'rows':[]},_0x349545[_0x1e97a9['tab'][_0x532ec2('0xdd6')]==='chat'?_0x532ec2('0x2681'):_0x1e97a9['tab'][_0x532ec2('0xdd6')]+_0x532ec2('0xa78')][_0x532ec2('0x1e6e')]({'id':_0x1e97a9[_0x532ec2('0xa98')][_0x1e97a9[_0x532ec2('0x1904')][_0x532ec2('0xdd6')]===_0x532ec2('0x24e')?'ChatWebsiteId':_0x2e3ca0()[_0x532ec2('0x21ab')](_0x1e97a9[_0x532ec2('0x1904')][_0x532ec2('0xdd6')])+_0x532ec2('0x2df')]})[_0x532ec2('0xe53')];})[_0x222f04('0x683')](function(_0x2d7ba6){const _0x3c3662=_0x222f04;_0x1e97a9[_0x3c3662('0x1d2f')]=_0x2d7ba6,_0x1e97a9[_0x3c3662('0x1904')][_0x3c3662('0xf28')]=_0x1e97a9['account']['key']||_0x1e97a9[_0x3c3662('0x1d2f')][_0x3c3662('0x60a')];if(_0x1e97a9[_0x3c3662('0xa98')][_0x3c3662('0x670')])return _0x349545['cmContact'][_0x3c3662('0x1e6e')]({'id':_0x1e97a9['interaction'][_0x3c3662('0x670')]})[_0x3c3662('0xe53')];})['then'](function(_0x11b372){const _0xbdc36e=_0x222f04;return _0x11b372&&(_0x1e97a9[_0xbdc36e('0xd06')]=_0x11b372),_0x1e97a9['showInteraction']=!![],_0x1e97a9['contact']?(_0x1c11a7(_0x1e97a9[_0xbdc36e('0xd06')]),_0x1e97a9[_0xbdc36e('0x1904')][_0xbdc36e('0xf28')]+=_0xbdc36e('0xbf6')+_0x1e97a9[_0xbdc36e('0xd06')][_0xbdc36e('0xeef')]):_0x1e97a9[_0xbdc36e('0x1904')]['title']+=_0xbdc36e('0xbf6')+_0x3a9ba7[_0xbdc36e('0x2728')](_0x1e97a9[_0xbdc36e('0x1904')][_0xbdc36e('0xdd6')][_0xbdc36e('0x80')]()+_0xbdc36e('0x75a')),_0x349545[_0xbdc36e('0xc96')]['get']({'fields':_0xbdc36e('0x226f'),'nolimit':!![]})[_0xbdc36e('0xe53')];})[_0x222f04('0x683')](function(_0x54dabf){const _0x247568=_0x222f04;_0x1e97a9[_0x247568('0x3bf')]=_0x54dabf||{'count':0x0,'rows':[]},_0x1e97a9['usersMap']=_0x2e3ca0()[_0x247568('0x1cc9')](_0x2e3ca0()[_0x247568('0x24db')](_0x1e97a9[_0x247568('0x3bf')][_0x247568('0xf5d')],'id'),'fullname');})[_0x222f04('0x683')](function(){const _0x399be7=_0x222f04;if(_0x1e97a9['tab']['channel']&&_0x1e97a9[_0x399be7('0xa98')])return _0x349545[_0x399be7('0xc96')]['add'+_0x2e3ca0()[_0x399be7('0x2711')](_0x1e97a9['tab'][_0x399be7('0xdd6')])+'Interactions']({'id':_0x1e97a9[_0x399be7('0xc96')]['id'],'ids':[_0x1e97a9[_0x399be7('0xa98')]['id']]});})['then'](function(){const _0x37352d=_0x222f04;return _0x349545[_0x37352d('0x1577')][_0x37352d('0x1e6e')]({'sort':_0x37352d('0x60a'),'nolimit':!![]})[_0x37352d('0xe53')];})[_0x222f04('0x683')](function(_0x2bf689){const _0x483883=_0x222f04;_0x1e97a9[_0x483883('0x26a3')]=_0x2bf689||{'count':0x0,'rows':[]};})[_0x222f04('0x683')](function(){const _0x2c0a55=_0x222f04;return _0x1e97a9[_0x2c0a55('0x2872')]();})['then'](function(){return _0x1e97a9['getFaxAccounts']();})[_0x222f04('0x683')](function(){const _0x549871=_0x222f04;return _0x1e97a9[_0x549871('0xf1e')]();})['then'](function(){return _0x1e97a9['getWhatsappAccounts']();})[_0x222f04('0x683')](function(){const _0x2c361b=_0x222f04;return _0x1e97a9[_0x2c361b('0x24e3')]();})[_0x222f04('0x683')](function(){return _0x1e97a9['getChatWebsites']();})[_0x222f04('0x683')](function(){return _0x1e97a9['getLists']();})[_0x222f04('0x130a')](function(){const _0x5b802e=_0x222f04;_0x1e97a9[_0x5b802e('0x15c9')]=!![];})['finally'](function(){const _0x345aad=_0x222f04;_0x298d14(),_0x1f6f0f(),_0x32e50a['on'](_0x1e97a9[_0x345aad('0x1904')][_0x345aad('0xdd6')]+_0x345aad('0x133a'),_0x1e97a9[_0x345aad('0x186a')]),_0x32e50a['on'](_0x1e97a9['tab'][_0x345aad('0xdd6')]+_0x345aad('0x463'),_0x1e97a9[_0x345aad('0x186a')]),_0x32e50a['on'](_0x1e97a9['tab'][_0x345aad('0xdd6')]+'Interaction:save',_0x1e97a9['onInteractionSave']),_0x32e50a['on'](_0x1e97a9['tab'][_0x345aad('0xdd6')]+'Interaction:update',_0x1e97a9[_0x345aad('0x258e')]),_0x32e50a['on'](_0x345aad('0x2239')+_0x1e97a9[_0x345aad('0x1904')][_0x345aad('0xdd6')]+'_interactions:save',_0x1e97a9[_0x345aad('0xd5')]),_0x32e50a['on'](_0x345aad('0x2239')+_0x1e97a9[_0x345aad('0x1904')]['channel']+'_interactions:remove',_0x1e97a9[_0x345aad('0xbea')]),_0x1e97a9[_0x345aad('0x1904')]['areaText']=_0x1e97a9[_0x345aad('0x1904')][_0x345aad('0x336')]?_0x1e97a9[_0x345aad('0x1904')]['areaText']:'',_0x1e97a9[_0x345aad('0x2763')]=!![],_0x1e97a9[_0x345aad('0x1904')][_0x345aad('0xdd6')]===_0x345aad('0x129f')&&(_0x1e97a9[_0x345aad('0x2546')]=_0x2c570a[_0x345aad('0x22f2')](_0x1e97a9[_0x345aad('0x1904')]['interaction']['id']),_0x1e97a9[_0x345aad('0x1904')][_0x345aad('0x31f')]&&(_0x1e97a9['tab'][_0x345aad('0xa98')][_0x345aad('0xd8a')]?(_0x2c570a[_0x345aad('0x19d')](_0x1e97a9[_0x345aad('0x1904')][_0x345aad('0xa98')]['id']),_0x1e97a9[_0x345aad('0x2546')]=null):_0x24366a()));}));}function _0xa70edf(_0x63a900){const _0xa49e1a=_0x19a11d;if(_0x63a900[_0xa49e1a('0xe22')])return _0x2e3ca0()[_0xa49e1a('0x2292')](_0x2e3ca0()['map'](_0x1e97a9[_0xa49e1a('0x2595')]?_0x1e97a9['faxAccounts'][_0xa49e1a('0xf5d')]:[],'id'),_0x63a900[_0xa49e1a('0xe22')]);else{if(_0x63a900[_0xa49e1a('0x1061')])return _0x2e3ca0()[_0xa49e1a('0x2292')](_0x2e3ca0()[_0xa49e1a('0x386')](_0x1e97a9[_0xa49e1a('0x1952')]?_0x1e97a9['openchannelAccounts'][_0xa49e1a('0xf5d')]:[],'id'),_0x63a900[_0xa49e1a('0x1061')]);else{if(_0x63a900[_0xa49e1a('0x1f4f')])return _0x2e3ca0()[_0xa49e1a('0x2292')](_0x2e3ca0()[_0xa49e1a('0x386')](_0x1e97a9['smsAccounts']?_0x1e97a9['smsAccounts']['rows']:[],'id'),_0x63a900['SmsAccountId']);else{if(_0x63a900[_0xa49e1a('0x1c35')])return _0x2e3ca0()[_0xa49e1a('0x2292')](_0x2e3ca0()[_0xa49e1a('0x386')](_0x1e97a9[_0xa49e1a('0x263c')]?_0x1e97a9['whatsappAccounts']['rows']:[],'id'),_0x63a900[_0xa49e1a('0x1c35')]);else{if(_0x63a900[_0xa49e1a('0x1cd')])return _0x2e3ca0()[_0xa49e1a('0x2292')](_0x2e3ca0()[_0xa49e1a('0x386')](_0x1e97a9[_0xa49e1a('0x1093')]?_0x1e97a9[_0xa49e1a('0x1093')][_0xa49e1a('0xf5d')]:[],'id'),_0x63a900[_0xa49e1a('0x1cd')]);else{if(_0x63a900[_0xa49e1a('0x15a5')])return _0x2e3ca0()[_0xa49e1a('0x2292')](_0x2e3ca0()[_0xa49e1a('0x386')](_0x1e97a9[_0xa49e1a('0x11e2')]?_0x1e97a9[_0xa49e1a('0x11e2')]['rows']:[],'id'),_0x63a900[_0xa49e1a('0x15a5')]);else{if(_0x63a900['amaflags'])return!![];}}}}}}return![];}function _0x574ebf(_0x97dc9b){const _0x2e1f2b=_0x19a11d;let _0x3d65f3;_0x1e97a9[_0x2e1f2b('0xa98')]['id']==_0x97dc9b[_0x2e3ca0()['upperFirst'](_0x1e97a9[_0x2e1f2b('0x1904')][_0x2e1f2b('0xdd6')])+_0x2e1f2b('0x1603')]&&(_0x1e97a9[_0x2e1f2b('0xa98')][_0x2e1f2b('0x2139')]&&(_0x3d65f3=_0x2e3ca0()[_0x2e1f2b('0x1c07')](_0x1e97a9[_0x2e1f2b('0xa98')][_0x2e1f2b('0x2139')],{'id':_0x97dc9b['UserId']})),!_0x3d65f3&&_0x1e97a9[_0x2e1f2b('0xa98')][_0x2e1f2b('0x2139')][_0x2e1f2b('0x1fd0')]({'id':_0x97dc9b['UserId']}));}function _0x5e3a64(_0x3d3a4c){const _0x2bc394=_0x19a11d;_0x1e97a9[_0x2bc394('0xa98')]['id']==_0x3d3a4c[_0x2e3ca0()['upperFirst'](_0x1e97a9[_0x2bc394('0x1904')][_0x2bc394('0xdd6')])+_0x2bc394('0x1603')]&&(_0x1e97a9[_0x2bc394('0xa98')][_0x2bc394('0x2139')]&&_0x2e3ca0()['remove'](_0x1e97a9[_0x2bc394('0xa98')][_0x2bc394('0x2139')],{'id':_0x3d3a4c[_0x2bc394('0x10c5')]}));}function _0x23f46f(_0x595ad7){const _0x5d6dc6=_0x19a11d;if(_0x595ad7){try{_0x2e3ca0()['templateSettings']['interpolate']=/{{([\s\S]+?)}}/g;const _0x1b063=_0x2e3ca0()[_0x5d6dc6('0x1cc6')](_0x595ad7[_0x5d6dc6('0x1c6b')]),_0x212b8f={'user':_0x1e97a9[_0x5d6dc6('0xc96')],'account':_0x1e97a9[_0x5d6dc6('0x1d2f')],'interaction':_0x1e97a9[_0x5d6dc6('0xa98')],'contact':_0x1e97a9['interaction']&&_0x1e97a9[_0x5d6dc6('0xa98')][_0x5d6dc6('0x1309')]?_0x1e97a9[_0x5d6dc6('0xa98')]['Contact']:{}};_0x1e97a9['tab'][_0x5d6dc6('0x336')]+='\x20'+_0x1b063(_0x212b8f),_0x1e97a9[_0x5d6dc6('0x1ee5')]['setText'](_0x1e97a9[_0x5d6dc6('0x1904')][_0x5d6dc6('0x336')]);}catch(_0x248ffa){_0x1e97a9['tab']['areaText']+='\x20'+_0x595ad7['value'],_0x1e97a9[_0x5d6dc6('0x1ee5')]['setText'](_0x1e97a9[_0x5d6dc6('0x1904')][_0x5d6dc6('0x336')]);}_0x1e97a9[_0x5d6dc6('0x2261')]=null,_0x1e97a9['changeDisplayCannedAnswerInputValue']();}}function _0xec3c2a(_0x4cc500){const _0xf3a973=_0x19a11d,_0xd50f89=_0x2a20da[_0xf3a973('0x448')]();let _0x1e2a44=[];const _0x3c6bba={},_0x20017b=_0x1e97a9[_0xf3a973('0x1904')][_0xf3a973('0xdd6')]==='chat'?'ChatWebsiteId':_0x2e3ca0()[_0xf3a973('0x21ab')](_0x1e97a9[_0xf3a973('0x1904')]['channel'])+'AccountId';return _0x3c6bba[_0xf3a973('0x25')]=_0x4cc500,_0x3c6bba[_0x20017b]=_0x1e97a9[_0xf3a973('0x1d2f')]['id'],_0x349545[_0xf3a973('0x136c')]['get'](_0x3c6bba)['$promise'][_0xf3a973('0x683')](function(_0x596963){const _0x37651f=_0xf3a973;return _0x1e2a44=_0x2e3ca0()['concat'](_0x1e2a44,_0x596963[_0x37651f('0xf5d')]),_0x349545[_0x37651f('0x136c')][_0x37651f('0x1e6e')]({'filter':_0x4cc500})[_0x37651f('0xe53')];})['then'](function(_0x2891e2){const _0x45cb5b=_0xf3a973;_0x1e2a44=_0x2e3ca0()['concat'](_0x1e2a44,_0x2e3ca0()['filter'](_0x2891e2['rows'],function(_0x396da){const _0x3fb59f=a0_0x4e0a;return!_0x396da[_0x3fb59f('0x1cd')]&&!_0x396da[_0x3fb59f('0xe22')]&&!_0x396da['SmsAccountId']&&!_0x396da[_0x3fb59f('0x1c35')]&&!_0x396da[_0x3fb59f('0x1061')]&&!_0x396da['ChatWebsiteId'];})),_0xd50f89[_0x45cb5b('0xed7')](_0x1e2a44);})[_0xf3a973('0x130a')](function(_0x3216d7){const _0x4e33de=_0xf3a973;_0xd50f89[_0x4e33de('0xfae')](_0x3216d7);}),_0xd50f89[_0xf3a973('0x1883')];}function _0x22c98c(_0x2ac0e9,_0x3cdc10){const _0x598c00=_0x19a11d;try{_0x1e97a9[_0x598c00('0x1904')]&&!_0x1e97a9[_0x598c00('0x1904')]['spy']&&_0x5021f4[_0x598c00('0x1cd5')][_0x598c00('0x1cd5')][_0x598c00('0x1cd5')]['vm'][_0x598c00('0x15e')](_0x3cdc10||_0x1e97a9[_0x598c00('0xd06')]);}catch(_0x4c196e){_0x119769[_0x598c00('0x52a')]({'title':_0x598c00('0xf3a'),'msg':_0x598c00('0xa9d')});}}function _0x5c5cc3(_0x15e25e,_0x3c4da4){const _0x249bf2=_0x19a11d;try{if(_0x3c4da4[_0x249bf2('0x1cd')])return _0x5021f4[_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')]['vm'][_0x249bf2('0x297')](_0x249bf2('0x129f'),_0x3c4da4);else{if(_0x3c4da4[_0x249bf2('0x15a5')])return _0x5021f4[_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')]['vm'][_0x249bf2('0x297')](_0x249bf2('0x24e'),_0x3c4da4);else{if(_0x3c4da4[_0x249bf2('0x1f4f')])return _0x5021f4[_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')]['vm'][_0x249bf2('0x297')](_0x249bf2('0x1285'),_0x3c4da4);else{if(_0x3c4da4[_0x249bf2('0x1c35')])return _0x5021f4[_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')]['vm']['addInteractionTab'](_0x249bf2('0x16e7'),_0x3c4da4);else{if(_0x3c4da4[_0x249bf2('0x1061')])return _0x5021f4[_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')]['vm'][_0x249bf2('0x297')](_0x249bf2('0x1261'),_0x3c4da4);else{if(_0x3c4da4[_0x249bf2('0xe22')])return _0x5021f4[_0x249bf2('0x1cd5')][_0x249bf2('0x1cd5')]['$parent']['vm'][_0x249bf2('0x297')]('fax',_0x3c4da4);}}}}}}catch(_0x34a62c){_0x119769[_0x249bf2('0x52a')]({'title':_0x249bf2('0x27cc'),'msg':'Customer\x20Journey\x20can\x27t\x20open\x20the\x20interaction'});}}function _0x4f7316(){const _0x2264a0=_0x19a11d;_0x5e83cf[_0x2264a0('0x1d4')]({'controller':_0x2264a0('0xfdd'),'controllerAs':'vm','templateUrl':_0xb83f7a,'parent':angular[_0x2264a0('0x1fcc')](_0x588794['body']),'clickOutsideToClose':!![],'skipHide':Boolean(_0x1e97a9[_0x2264a0('0x1904')][_0x2264a0('0x34a')]),'resolve':{'tags':['apiResolver',function(_0x15d6f7){const _0x4c795c=_0x2264a0;return _0x15d6f7['resolve'](_0x4c795c('0xb55'),{'sort':_0x4c795c('0x60a'),'nolimit':!![],'fields':_0x4c795c('0x147c')});}]},'locals':{'channel':_0x1e97a9['tab']['channel'],'interaction':_0x1e97a9[_0x2264a0('0x1904')][_0x2264a0('0xa98')]}});}function _0x4a8e51(){const _0x2f9e01=_0x19a11d,_0x88710d=_0x1e97a9[_0x2f9e01('0xc96')][_0x2f9e01('0x1431')]||_0x1e97a9[_0x2f9e01('0xc96')][_0x2f9e01('0x1938')]||_0x1e97a9['user'][_0x2f9e01('0x774')]||_0x1e97a9[_0x2f9e01('0xc96')]['openchannelPause']||_0x1e97a9['user'][_0x2f9e01('0x716')],_0x2575a2=!_0x1e97a9[_0x2f9e01('0x1904')][_0x2f9e01('0xa98')][_0x2f9e01('0xa78')][_0x2f9e01('0x989')];_0x5e83cf[_0x2f9e01('0x1d4')]({'controller':_0x2f9e01('0x14a7'),'controllerAs':'vm','templateUrl':_0xf23f9e,'parent':angular[_0x2f9e01('0x1fcc')](_0x588794[_0x2f9e01('0x18e5')]),'clickOutsideToClose':_0x2575a2,'escapeToClose':_0x2575a2,'onRemoving':function(){const _0x31d94b=_0x2f9e01;_0x1e97a9[_0x31d94b('0xc96')]&&_0x1e97a9[_0x31d94b('0xa98')][_0x31d94b('0xa78')][_0x31d94b('0x989')]&&!_0x88710d&&_0x349545[_0x31d94b('0xc96')][_0x31d94b('0x1778')]({'id':_0x1e97a9['user']['id']})[_0x31d94b('0xe53')][_0x31d94b('0x130a')](function(_0xca9c7a){const _0x542263=_0x31d94b;console[_0x542263('0x52a')](_0xca9c7a);});},'locals':{'user':_0x1e97a9[_0x2f9e01('0xc96')],'channel':_0x1e97a9['tab'][_0x2f9e01('0xdd6')],'interaction':_0x1e97a9[_0x2f9e01('0x1904')]['interaction']}})[_0x2f9e01('0x683')](function(_0x31b46d){const _0x5d936b=_0x2f9e01;_0x1e97a9[_0x5d936b('0x1904')][_0x5d936b('0x118c')]=Boolean(_0x31b46d),_0x31b46d&&_0x5021f4['$parent'][_0x5d936b('0x1cd5')][_0x5d936b('0x1cd5')]['vm']['closeTab'](_0x1e97a9[_0x5d936b('0x1904')]);});}function _0x50b51c(_0x1d94cc,_0x52a1c8){const _0x4c662e=_0x19a11d;_0x1e97a9[_0x4c662e('0x1904')][_0x4c662e('0x8c2')]=_0x52a1c8,_0x5e83cf['show']({'controller':_0x4c662e('0xebc'),'controllerAs':'vm','templateUrl':_0x1e7ae7,'parent':angular[_0x4c662e('0x1fcc')](_0x588794['body']),'clickOutsideToClose':![],'locals':{'account':_0x1e97a9['account'],'message':_0x1e97a9[_0x4c662e('0x1904')][_0x4c662e('0x8c2')],'type':_0x1d94cc,'interaction':_0x1e97a9['interaction']},'fullscreen':!![],'skipHide':Boolean(_0x1e97a9[_0x4c662e('0x1904')][_0x4c662e('0x34a')])})[_0x4c662e('0x683')](function(_0x50e1fb){const _0x53316d=_0x4c662e;if(_0x50e1fb){if(_0x50e1fb[_0x53316d('0x8c2')]&&_0x50e1fb['message'][_0x53316d('0x250b')])_0x1e97a9[_0x53316d('0x2546')]?_0x2c570a[_0x53316d('0x2480')]({'id':_0x1e97a9[_0x53316d('0x2546')]['id'],'channel':_0x53316d('0x129f'),'account':_0x1e97a9[_0x53316d('0x1d2f')],'message':_0x50e1fb[_0x53316d('0x8c2')],'contact':_0x1e97a9[_0x53316d('0xd06')],'interaction':_0x1e97a9[_0x53316d('0xa98')]}):_0x2c570a['add']({'channel':_0x53316d('0x129f'),'account':_0x1e97a9[_0x53316d('0x1d2f')],'message':_0x50e1fb['message'],'contact':_0x1e97a9['contact'],'interaction':_0x1e97a9['interaction']}),_0x1e97a9[_0x53316d('0x2546')]=_0x2c570a[_0x53316d('0x22f2')](_0x1e97a9[_0x53316d('0x1904')]['interaction']['id']);else{const _0x11b9ff=_0x50e1fb;_0x11b9ff&&_0x5c8ed9(_0x11b9ff),_0x11b9ff[_0x53316d('0x1896')]&&_0x1e97a9[_0x53316d('0xa98')]&&_0x1e97a9[_0x53316d('0xa98')]['id']&&(_0x11b9ff['Interaction']['id']=_0x1e97a9[_0x53316d('0xa98')]['id'],_0x349545[_0x53316d('0x95a')][_0x53316d('0x2480')](_0x11b9ff['Interaction'])['$promise'][_0x53316d('0x683')](function(_0x150e60){const _0x2908d3=_0x53316d;if(_0x150e60&&_0x150e60['closed'])_0x1e97a9[_0x2908d3('0x1904')][_0x2908d3('0x118c')]=!![],_0x1e97a9['interaction'][_0x2908d3('0xd8a')]=!![],_0x4a8e51();else _0x11b9ff[_0x2908d3('0x1896')][_0x2908d3('0x231b')]!==null&&(_0x1e97a9[_0x2908d3('0x1904')][_0x2908d3('0x118c')]=!![],_0x1e97a9[_0x2908d3('0x1904')][_0x2908d3('0xa98')]['substatus']=_0x11b9ff['Interaction'][_0x2908d3('0x231b')],_0x5021f4[_0x2908d3('0x1cd5')][_0x2908d3('0x1cd5')][_0x2908d3('0x1cd5')]['vm'][_0x2908d3('0x2107')](_0x1e97a9[_0x2908d3('0x1904')]));})['catch'](function(_0x17a079){const _0x413fef=_0x53316d;console[_0x413fef('0x52a')](_0x17a079);}));}}})[_0x4c662e('0x2874')](function(){const _0xa43f6c=_0x4c662e;_0x1e97a9[_0xa43f6c('0x1904')][_0xa43f6c('0x31f')]=![];});}function _0x12fb7e(_0x279611,_0x235d44){const _0x1c406e=_0x19a11d;if(_0x235d44['inReplyTo']){const _0x1faa89=_0x2e3ca0()['find'](_0x1e97a9[_0x1c406e('0x2636')]['rows'],{'messageId':_0x235d44[_0x1c406e('0x20ea')]});if(_0x1faa89)_0x50b51c(_0x279611,_0x1faa89);else return _0x349545[_0x1c406e('0xc8b')][_0x1c406e('0x1e6e')]({'messageId':_0x235d44[_0x1c406e('0x20ea')]})['$promise'][_0x1c406e('0x683')](function(_0x51f629){const _0x297e83=_0x1c406e;_0x50b51c(_0x279611,_0x51f629&&_0x51f629[_0x297e83('0x50d')]?_0x51f629[_0x297e83('0xf5d')][0x0]:undefined);})[_0x1c406e('0x130a')](function(_0x48e530){const _0x28671f=_0x1c406e;console[_0x28671f('0x52a')](_0x48e530),_0x50b51c(_0x279611,undefined);});}else _0x50b51c(_0x279611,_0x235d44);}function _0x53f107(_0xa9e0bd){const _0x3f9cee=_0x19a11d,_0x3aed97={'to':[]};_0x3aed97['to'][_0x3f9cee('0x1fd0')](_0x1e97a9[_0x3f9cee('0xd06')][_0x3f9cee('0x23e9')]),_0x5e83cf[_0x3f9cee('0x1d4')]({'controller':'ComposeFaxInteractionDialogController','controllerAs':'vm','templateUrl':_0x354ecd,'parent':angular[_0x3f9cee('0x1fcc')](_0x588794['body']),'clickOutsideToClose':![],'locals':{'account':_0x1e97a9[_0x3f9cee('0x1d2f')],'message':_0x3aed97,'type':_0xa9e0bd},'fullscreen':!![]})[_0x3f9cee('0x683')](function(_0x3c6e36){const _0x5ae057=_0x3f9cee;return _0x349545[_0x5ae057('0x244a')][_0x5ae057('0x1503')]({'id':_0x1e97a9[_0x5ae057('0x1d2f')]['id']},_0x3c6e36)['$promise'][_0x5ae057('0x683')](function(_0xdbfae7){const _0x19d362=_0x5ae057;_0x119769[_0x19d362('0x53')]({'title':_0x19d362('0xb96'),'msg':_0x19d362('0x21a1')}),_0x5021f4[_0x19d362('0x1cd5')]['vm'][_0x19d362('0x297')](_0x19d362('0x23e9'),_0xdbfae7);})[_0x5ae057('0x130a')](function(_0x1ecab4){const _0x297026=_0x5ae057;if(_0x1ecab4[_0x297026('0x5a5')]&&_0x1ecab4[_0x297026('0x5a5')][_0x297026('0x17f')]&&_0x1ecab4[_0x297026('0x5a5')][_0x297026('0x17f')][_0x297026('0x1564')])for(let _0x432b62=0x0;_0x432b62<_0x1ecab4[_0x297026('0x5a5')]['errors'][_0x297026('0x1564')];_0x432b62++){_0x119769['error']({'title':_0x1ecab4['data']['errors'][_0x432b62][_0x297026('0xcf0')],'msg':_0x1ecab4[_0x297026('0x5a5')]['errors'][_0x432b62]['message']});}else _0x119769[_0x297026('0x52a')]({'title':_0x297026('0x1e95'),'msg':_0x1ecab4[_0x297026('0x5a5')]?JSON['stringify'](_0x1ecab4['data']):_0x1ecab4[_0x297026('0x8c2')]||_0x1ecab4['toString']()});});});}function _0x5e6c84(_0x4ce9dc,_0xe86e92){const _0x1b9a66=_0x19a11d;_0x5e83cf[_0x1b9a66('0x1d4')]({'controller':_0x1b9a66('0x569'),'controllerAs':'vm','templateUrl':_0x382523,'parent':angular[_0x1b9a66('0x1fcc')](_0x588794[_0x1b9a66('0x18e5')]),'clickOutsideToClose':![],'locals':{'account':_0x1e97a9[_0x1b9a66('0x1d2f')],'message':_0xe86e92,'type':_0x4ce9dc},'fullscreen':!![],'skipHide':Boolean(_0x1e97a9[_0x1b9a66('0x1904')][_0x1b9a66('0x34a')])})[_0x1b9a66('0x683')](function(_0xb582ee){_0xb582ee&&_0x5c8ed9(_0xb582ee);});}function _0xaf212(_0x40b109,_0x510b4a){const _0x5b7d55=_0x19a11d;_0x5e83cf['show']({'controller':'ComposeWhatsappInteractionDialogController','controllerAs':'vm','templateUrl':_0x4cefce,'parent':angular[_0x5b7d55('0x1fcc')](_0x588794['body']),'clickOutsideToClose':![],'locals':{'account':_0x1e97a9[_0x5b7d55('0x1d2f')],'message':_0x510b4a,'type':_0x40b109},'fullscreen':!![],'skipHide':Boolean(_0x1e97a9[_0x5b7d55('0x1904')]['spy'])})[_0x5b7d55('0x683')](function(_0x21b27d){_0x21b27d&&_0x5c8ed9(_0x21b27d);});}function _0x18561e(){const _0x5c036d=_0x19a11d;if(_0x1e97a9[_0x5c036d('0xa98')]){const _0x482d30=_0x2e3ca0()[_0x5c036d('0x18c9')](_0x1e97a9['messages'][_0x5c036d('0xf5d')],function(_0x432279){const _0x18c6f5=_0x5c036d;return _0x432279[_0x18c6f5('0x2655')]==='in';});_0x482d30?_0x5e83cf[_0x5c036d('0x1d4')]({'controller':_0x5c036d('0x808'),'controllerAs':'vm','templateUrl':_0x242cfc,'parent':angular[_0x5c036d('0x1fcc')](_0x588794[_0x5c036d('0x18e5')]),'clickOutsideToClose':![],'locals':{'account':_0x1e97a9[_0x5c036d('0x1d2f')],'interaction':_0x1e97a9[_0x5c036d('0xa98')],'message':_0x482d30,'channel':_0x1e97a9[_0x5c036d('0x1904')][_0x5c036d('0xdd6')]}})[_0x5c036d('0x683')](function(_0x20c0de){const _0x7565b6=_0x5c036d;_0x1e97a9['tab']['saved']=Boolean(_0x20c0de),_0x20c0de&&_0x5021f4[_0x7565b6('0x1cd5')]['$parent'][_0x7565b6('0x1cd5')]['vm']['closeTab'](_0x1e97a9['tab']);}):_0x119769[_0x5c036d('0x52a')]({'title':_0x5c036d('0xb58'),'msg':'Message\x20not\x20found!'});}}function _0xa1bbc2(_0x46f94a){const _0x48915e=_0x19a11d,_0xd74a25={},_0x4f98d9=_0x1e97a9[_0x48915e('0x1904')]['channel']===_0x48915e('0x24e')?_0x48915e('0x15a5'):_0x2e3ca0()[_0x48915e('0x21ab')](_0x1e97a9['tab']['channel'])+_0x48915e('0x2df');return _0xd74a25[_0x4f98d9]=_0x1e97a9[_0x48915e('0xa98')][_0x4f98d9]['toString'](),_0xd74a25[_0x2e3ca0()[_0x48915e('0x21ab')](_0x1e97a9['tab'][_0x48915e('0xdd6')])+_0x48915e('0x1603')]=_0x1e97a9[_0x48915e('0xa98')]['id'],(_0x1e97a9[_0x48915e('0x1904')][_0x48915e('0xdd6')]===_0x48915e('0x1285')||_0x1e97a9[_0x48915e('0x1904')][_0x48915e('0xdd6')]===_0x48915e('0x16e7'))&&(_0xd74a25[_0x48915e('0xd31')]=_0x1e97a9[_0x48915e('0xa98')][_0x48915e('0xd31')]),_0x46f94a&&(_0xd74a25[_0x48915e('0x10c5')]=_0x1e97a9[_0x48915e('0xc96')]['id'],_0xd74a25['ContactId']=_0x1e97a9['interaction'][_0x48915e('0x670')],_0xd74a25['body']=_0x46f94a),_0xd74a25;}function _0x1e5956(_0x5e19de){const _0x3fd143=_0x19a11d;if(_0x5e19de[_0x3fd143('0x1a41')]>_0x2b1975)return _0x119769['error']({'title':_0x3fd143('0x19a2'),'msg':_0x3fd143('0x1622')+_0x1f1c1b+'MB'}),![];return!![];}function _0x2c7055(_0x572fe2,_0x385104){const _0x351a41=_0x19a11d,_0x2f53c6=JSON[_0x351a41('0x1f34')](_0x385104);let _0x5586a8=_0x2f53c6[_0x351a41('0x60a')];_0x1e97a9[_0x351a41('0x1904')][_0x351a41('0xdd6')]===_0x351a41('0x24e')&&(_0x5586a8=']+>/gm,''):'';}function _0x24366a(_0x327614){const _0x2f8de0=_0x19a11d;switch(_0x1e97a9[_0x2f8de0('0x1904')][_0x2f8de0('0xdd6')]){case _0x2f8de0('0x129f'):_0x1e97a9[_0x2f8de0('0x2546')][_0x2f8de0('0xa6a')]['originalMessage']=_0x327614?_0x2e3ca0()[_0x2f8de0('0x1c07')](_0x1e97a9[_0x2f8de0('0xa98')][_0x2f8de0('0xc51')],['id',_0x327614]):_0x1e97a9[_0x2f8de0('0xa98')][_0x2f8de0('0xc51')][_0x1e97a9[_0x2f8de0('0xa98')][_0x2f8de0('0xc51')][_0x2f8de0('0x1564')]-0x1],_0x50b51c(_0x1e97a9[_0x2f8de0('0x2546')][_0x2f8de0('0xcf0')],_0x1e97a9['draft'][_0x2f8de0('0xa6a')]);break;case _0x2f8de0('0x23e9'):break;case _0x2f8de0('0x1261'):break;case _0x2f8de0('0x1285'):break;case _0x2f8de0('0x16e7'):break;}}_0x5021f4['$on'](_0x19a11d('0x4b8'),function(){const _0x4a4bfd=_0x19a11d;_0x32e50a[_0x4a4bfd('0x1b9e')](_0x1e97a9[_0x4a4bfd('0x1904')][_0x4a4bfd('0xdd6')]+_0x4a4bfd('0x133a')),_0x32e50a[_0x4a4bfd('0x1b9e')](_0x1e97a9[_0x4a4bfd('0x1904')][_0x4a4bfd('0xdd6')]+'Message:update'),_0x32e50a[_0x4a4bfd('0x1b9e')](_0x1e97a9['tab']['channel']+_0x4a4bfd('0x619')),_0x32e50a['removeAllListeners'](_0x1e97a9[_0x4a4bfd('0x1904')][_0x4a4bfd('0xdd6')]+'Interaction:update'),_0x32e50a[_0x4a4bfd('0x1b9e')](_0x4a4bfd('0x2239')+_0x1e97a9['tab'][_0x4a4bfd('0xdd6')]+_0x4a4bfd('0x2706')),_0x32e50a['removeAllListeners'](_0x4a4bfd('0x2239')+_0x1e97a9[_0x4a4bfd('0x1904')][_0x4a4bfd('0xdd6')]+_0x4a4bfd('0x1ca1'));});function _0x25713d(_0x2916c6){const _0x25fb1b=_0x19a11d,_0x54cb2c={'id':_0x2916c6['id']};return _0x349545[_0x25fb1b('0x1809')]['createVidaooSession'](_0x54cb2c)[_0x25fb1b('0xe53')][_0x25fb1b('0x683')](function(){const _0x4ad881=_0x25fb1b;_0x119769[_0x4ad881('0x53')]({'title':_0x4ad881('0x168d'),'msg':_0x4ad881('0x771')});})['catch'](function(){const _0x9170b6=_0x25fb1b;_0x119769[_0x9170b6('0x52a')]({'title':_0x9170b6('0x168d'),'msg':'Unable\x20to\x20create\x20session!'});});}}function _0x4202f8(_0x3299b6){const _0x167662=_0x189033;return{'scope':{'ngBindHtmlUnsafe':'='},'template':_0x167662('0x10c6'),'link':function(_0xc61158){const _0x366332=_0x167662;function _0x3699c2(){const _0x3bc0b7=a0_0x4e0a,_0xfd9b4e=_0x3bc0b7('0x2467')+Math[_0x3bc0b7('0x16c9')](Math[_0x3bc0b7('0x25c6')]()*0x270f+0x1);return _0x3bc0b7('0x218a')+_0xfd9b4e+_0x3bc0b7('0x213b')+_0xfd9b4e+_0x3bc0b7('0x2251');}_0xc61158[_0x366332('0x2e')]=function(){const _0x43ed18=_0x366332,_0x27a32d=_0x2e3ca0()[_0x43ed18('0x1725')](_0xc61158[_0x43ed18('0x2197')],_0x43ed18('0x194c'),_0x3699c2());_0xc61158['trustedHtml']=_0x3299b6['trustAsHtml'](_0x27a32d);},_0xc61158[_0x366332('0x186d')]('ngBindHtmlUnsafe',function(_0x353ee8){const _0x42a028=_0x366332;_0xc61158[_0x42a028('0x2e')](_0x353ee8);});}};}function _0x8b64a1(){return function(_0xf84b1,_0x51b7,_0x56b88b,_0x493cf0){const _0x1b1cba=a0_0x4e0a,_0x8bebe6=[];for(let _0x3c78a6=0x0;_0x3c78a6<_0xf84b1[_0x1b1cba('0x1564')];_0x3c78a6+=0x1){let _0x20682d=!![];switch(_0x51b7){case'voice':_0x20682d=Boolean(_0xf84b1[_0x3c78a6][_0x1b1cba('0x573')]);break;case'chat':_0x20682d=Boolean(_0xf84b1[_0x3c78a6][_0x1b1cba('0x15a5')]);break;case _0x1b1cba('0x129f'):_0x20682d=Boolean(_0xf84b1[_0x3c78a6][_0x1b1cba('0x1cd')]);break;case _0x1b1cba('0x1285'):_0x20682d=Boolean(_0xf84b1[_0x3c78a6]['SmsAccountId']);break;case'whatsapp':_0x20682d=Boolean(_0xf84b1[_0x3c78a6][_0x1b1cba('0x1c35')]);break;case _0x1b1cba('0x23e9'):_0x20682d=Boolean(_0xf84b1[_0x3c78a6][_0x1b1cba('0xe22')]);break;case'openchannel':_0x20682d=Boolean(_0xf84b1[_0x3c78a6][_0x1b1cba('0x1061')]);break;default:_0x20682d=!![];break;}_0x20682d&&(_0x56b88b&&_0x493cf0&&(_0x20682d=_0x1aaf93()(_0xf84b1[_0x3c78a6][_0x1b1cba('0x1a4')])[_0x1b1cba('0x17ad')](_0x1aaf93()(_0x56b88b)[_0x1b1cba('0xb11')](0x0,!![]),_0x1aaf93()(_0x493cf0)[_0x1b1cba('0xb11')](0x0,!![])['add'](0x17,_0x1b1cba('0x624'))[_0x1b1cba('0x23c6')](0x3b,_0x1b1cba('0x25a6'))[_0x1b1cba('0x23c6')](0x3b,_0x1b1cba('0x1b53'))))),_0x20682d&&_0x8bebe6[_0x1b1cba('0x1fd0')](_0xf84b1[_0x3c78a6]);}return _0x8bebe6;};}function _0x3b627c(){const _0xd790dc=_0x189033;return{'watchEmbedData':![],'sanitizeHtml':![],'fontSmiley':![],'emoji':!![],'link':!![],'linkTarget':_0xd790dc('0x18b3'),'pdf':{'embed':!![]},'image':{'embed':!![]},'audio':{'embed':!![]},'basicVideo':![],'gdevAuth':'xxxxxxxx','video':{'embed':![],'width':null,'height':null,'ytTheme':_0xd790dc('0x26df'),'details':![],'thumbnailQuality':_0xd790dc('0xc59'),'autoPlay':!![]},'twitchtvEmbed':!![],'dailymotionEmbed':!![],'tedEmbed':!![],'dotsubEmbed':!![],'liveleakEmbed':!![],'ustreamEmbed':!![],'soundCloudEmbed':!![],'soundCloudOptions':{'height':0xa0,'themeColor':'f50000','autoPlay':![],'hideRelated':![],'showComments':!![],'showUser':!![],'showReposts':![],'visual':![],'download':![]},'spotifyEmbed':!![],'tweetEmbed':!![],'tweetOptions':{'maxWidth':0x226,'hideMedia':![],'hideThread':![],'align':_0xd790dc('0x925'),'lang':'en'},'code':{'highlight':!![],'lineNumbers':![]},'codepenEmbed':!![],'codepenHeight':0x12c,'jsfiddleEmbed':!![],'jsfiddleHeight':0x12c,'jsbinEmbed':!![],'jsbinHeight':0x12c,'plunkerEmbed':!![],'githubgistEmbed':!![],'ideoneEmbed':!![],'ideoneHeight':0x12c};}const _0x234375=_0x3b627c;_0x39a51c[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x2063'),_0x189033('0x1e48'),_0x189033('0x1f45'),_0x189033('0x1d2f'),_0x189033('0x8c2'),_0x189033('0xcf0'),'api','toasty'];function _0x39a51c(_0x56644a,_0x782334,_0x4bd99a,_0x40cd2e,_0x1b0cae,_0x10140c,_0x42b70f,_0x45ec3b,_0x825aac){const _0xf1df9e=_0x189033,_0x10c864=this,_0x12ae2e=0x19,_0x256445=_0x12ae2e*0x400*0x400;_0x10c864[_0xf1df9e('0x7fe')]=[_0x40cd2e[_0xf1df9e('0x8')]['ENTER'],_0x40cd2e[_0xf1df9e('0x8')][_0xf1df9e('0x1ff1')],_0x40cd2e[_0xf1df9e('0x8')][_0xf1df9e('0xed')]],_0x10c864[_0xf1df9e('0x8c2')]={'from':_0x1b0cae['localstationid'],'to':_0x2e3ca0()[_0xf1df9e('0x8f2')](_0x10140c['to'])||_0x2e3ca0()[_0xf1df9e('0x173f')](_0x10140c['to'])?[]:_0x10140c['to'],'attachments':[]},_0x10c864[_0xf1df9e('0x8f')]={'target':'api/attachments','singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x256445,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x10c864[_0xf1df9e('0x1fa6')]={'flow':{}},_0x10c864[_0xf1df9e('0x1503')]=_0x2910ad,_0x10c864[_0xf1df9e('0xa03')]=_0x229f29,_0x10c864[_0xf1df9e('0x1152')]=_0x44682c,_0x10c864[_0xf1df9e('0x1aad')]=_0x34be3e,_0x10c864[_0xf1df9e('0x183e')]=_0x6b0a6f,_0x10c864[_0xf1df9e('0x16a1')]=_0x171236,_0x10c864[_0xf1df9e('0x19af')]=_0x501a98,_0x10c864[_0xf1df9e('0xf82')]=_0x1d6d27;function _0x140f70(){const _0x381675=_0xf1df9e;_0x4bd99a[_0x381675('0x1715')]({'from':_0x10c864[_0x381675('0x8c2')][_0x381675('0x705')],'to':_0x10c864[_0x381675('0x8c2')]['to'],'attach':_0x10c864[_0x381675('0x8c2')][_0x381675('0x1b46')]['length'],'attachments':_0x10c864[_0x381675('0x8c2')]['attachments']});}function _0x2910ad(){const _0x5d676b=_0xf1df9e;_0x10c864[_0x5d676b('0x8c2')]['attachments'][_0x5d676b('0x1564')]===0x1?_0x10c864['message']['to'][_0x5d676b('0x1564')]?(_0x10140c[_0x5d676b('0x2546')]=undefined,_0x140f70()):_0x825aac[_0x5d676b('0x52a')](_0x5d676b('0x17c7')):_0x825aac[_0x5d676b('0x52a')](_0x5d676b('0x2743'));}function _0x229f29(){const _0x12e01b=_0xf1df9e;_0x10c864[_0x12e01b('0x1fa6')][_0x12e01b('0x190a')][_0x12e01b('0x2810')]['headers']={'X-Requested-With':_0x12e01b('0xbfd'),'Authorization':_0x12e01b('0x189e')+_0x56644a[_0x12e01b('0x1e6e')](_0x12e01b('0x555'))},_0x10c864[_0x12e01b('0x1fa6')]['flow'][_0x12e01b('0xa03')]();}function _0x34be3e(_0x24f588){const _0x517d62=_0xf1df9e,_0x554402=[_0x517d62('0x2f1'),'tif'];if(!_0x2e3ca0()[_0x517d62('0x2292')](_0x554402,_0x24f588[_0x517d62('0x1197')]()))return _0x825aac[_0x517d62('0x52a')]({'title':'Invalid\x20extension:\x20'+_0x24f588['getExtension'](),'msg':_0x517d62('0xd17')+_0x554402[_0x517d62('0x1630')]()}),![];if(_0x24f588[_0x517d62('0x1a41')]>_0x256445)return _0x825aac[_0x517d62('0x52a')]({'title':_0x517d62('0x19a2'),'msg':_0x517d62('0x1622')+_0x12ae2e+'MB'}),![];return!![];}function _0x44682c(_0x264cb7,_0x1fe737){const _0x444420=_0xf1df9e;try{_0x1fe737=JSON[_0x444420('0x1f34')](_0x1fe737),_0x1fe737[_0x444420('0x1a41')]=_0x264cb7[_0x444420('0x1a41')],_0x10c864['message'][_0x444420('0x1b46')][_0x444420('0x1fd0')](_0x1fe737);}catch(_0x1672fc){console[_0x444420('0x52a')](_0x1672fc);}}function _0x6b0a6f(_0x4d5ef1){const _0xd95341=_0xf1df9e;let _0xeb695c='';return _0x4d5ef1['firstName']&&_0x4d5ef1[_0xd95341('0xeef')]!==_0x4d5ef1[_0xd95341('0x23e9')]&&(_0xeb695c+=_0x4d5ef1[_0xd95341('0xeef')]+'\x20'),_0x4d5ef1[_0xd95341('0x510')]&&_0x4d5ef1[_0xd95341('0x510')]!==_0x4d5ef1[_0xd95341('0x23e9')]&&(_0xeb695c+=_0x4d5ef1[_0xd95341('0x510')]+'\x20'),_0xeb695c+='<'+_0x4d5ef1[_0xd95341('0x23e9')]+'>';}function _0x501a98(_0x16b673){const _0x207176=_0xf1df9e,_0x5b69a2=_0x16b673;if(_0x2e3ca0()[_0x207176('0x20b6')](_0x16b673))return _0x16b673[_0x207176('0x23e9')];if(_0x51587d(_0x5b69a2))return _0x5b69a2;return _0x825aac[_0x207176('0x52a')](_0x207176('0x19f2')+_0x5b69a2+_0x207176('0x15be')),null;}function _0x51587d(_0x4e2fa8){const _0x14cff0=/[&/\\#,()$~%.'":;*?<>{}\s\\|a-zA-Z\pS!òàùè…_§°çéì-]/;return!_0x14cff0['test'](_0x4e2fa8);}function _0x171236(_0x106ab2){const _0x20af08=_0xf1df9e;return _0x1b0cae&&_0x1b0cae[_0x20af08('0x1e4f')]?_0x45ec3b[_0x20af08('0x276e')][_0x20af08('0x1e6e')]({'ListId':_0x1b0cae[_0x20af08('0x1e4f')],'nolimit':!![],'filter':_0x106ab2,'fields':_0x20af08('0x2287')})[_0x20af08('0xe53')][_0x20af08('0x683')](function(_0xb5c35){return _0xb5c35['rows'];}):[];}function _0x1d6d27(){const _0x2265d2=_0xf1df9e;_0x10140c[_0x2265d2('0x2546')]=_0x10c864[_0x2265d2('0x8c2')],_0x4bd99a['cancel']();}}const _0x5da36b=_0x39a51c;_0x3dfec2['$inject']=[_0x189033('0x17e4'),'$window',_0x189033('0x1e48'),'$mdConstant',_0x189033('0x1d08'),_0x189033('0x1d2f'),_0x189033('0x8c2'),_0x189033('0xcf0'),'api',_0x189033('0x1d70'),'$q',_0x189033('0xba1'),_0x189033('0xa98'),_0x189033('0x1777')];function _0x3dfec2(_0x6361a,_0x10e2b0,_0x24a368,_0x53aa57,_0x2a2c20,_0x11ab11,_0x31a254,_0x2bfe96,_0x5aa4b0,_0x275651,_0x26bae0,_0x3d5562,_0x488254,_0x4ffc98){const _0x4d1b39=_0x189033,_0x22e7e9=this,_0x134aef=0x19,_0x35de4b=_0x134aef*0x400*0x400;_0x22e7e9[_0x4d1b39('0x11ed')]=_0x3d5562['getCurrentUser'](),_0x22e7e9[_0x4d1b39('0x252d')]=_0x2bfe96===_0x4d1b39('0x2203')?!![]:![],_0x22e7e9[_0x4d1b39('0x1ae9')]=!![],_0x22e7e9[_0x4d1b39('0x98a')]=!![],_0x22e7e9[_0x4d1b39('0x2751')]=!![],_0x22e7e9[_0x4d1b39('0x17f')]=[],_0x22e7e9[_0x4d1b39('0x7fe')]=[_0x53aa57[_0x4d1b39('0x8')]['ENTER'],_0x53aa57['KEY_CODE'][_0x4d1b39('0x1ff1')],_0x53aa57['KEY_CODE']['TAB']],_0x22e7e9[_0x4d1b39('0x1361')]=_0x3db8bc,_0x22e7e9[_0x4d1b39('0x5a2')]=_0x30370a,_0x22e7e9[_0x4d1b39('0x1ddc')]=_0x622e09,_0x2e3ca0()[_0x4d1b39('0x726')][_0x4d1b39('0x14fd')]=/{{([\s\S]+?)}}/g,_0x22e7e9[_0x4d1b39('0xf4f')]=_0x2e3ca0()[_0x4d1b39('0x1cc6')](_0x4d1b39('0x21e1')),_0x22e7e9['replyTemplate']=_0x2e3ca0()[_0x4d1b39('0x1cc6')](_0x4d1b39('0x1e6c')),_0x22e7e9[_0x4d1b39('0x1e56')]=_0x2e3ca0()['template'](_0x4d1b39('0x1a3f')),_0x22e7e9['message']={'from':_0x22e7e9['fromTemplate']({'name':_0x11ab11['name'],'email':_0x11ab11[_0x4d1b39('0x1c92')]||_0x11ab11['Smtp'][_0x4d1b39('0xc96')]}),'to':[],'cc':[],'bcc':[],'body':_0x1babcb(),'type':_0x2bfe96,'attachments':[],'showLastMessage':!![]},_0x22e7e9['draft']=null,_0x22e7e9['ckeditor']={'skin':_0x4d1b39('0x692'),'startupFocus':!![],'language':'en','allowedContent':!![],'extraPlugins':_0x4d1b39('0x1dbd'),'toolbarGroups':[{'name':_0x4d1b39('0x97e'),'groups':[_0x4d1b39('0x97e')]},{'name':_0x4d1b39('0x14c1'),'groups':[_0x4d1b39('0x1f91')]},{'name':_0x4d1b39('0x240'),'groups':[_0x4d1b39('0x240')]},{'name':_0x4d1b39('0x11f9'),'groups':[_0x4d1b39('0x11f9')]},{'name':'paragraph','groups':[_0x4d1b39('0x2335'),_0x4d1b39('0x734'),_0x4d1b39('0xe67')]}],'autoGrow_onStartup':!![],'autoGrow_minHeight':_0x22e7e9[_0x4d1b39('0x252d')]?0xa0:0x12c,'autoGrow_maxHeight':_0x10e2b0['innerHeight']-0x190,'autocorrect_enabled':!![],'disableNativeSpellChecker':![],'enterMode':window['CKEDITOR'][_0x4d1b39('0x2126')],'font_defaultLabel':_0x11ab11[_0x4d1b39('0x7a7')]?_0x11ab11[_0x4d1b39('0x7a7')][_0x4d1b39('0x1fc5')](',')[0x0]:_0x4d1b39('0x1754'),'fontSize_defaultLabel':_0x11ab11[_0x4d1b39('0x2269')]||'12','removePlugins':_0x4d1b39('0x8ef')};const _0x214ecd=[];for(let _0x3640f5=0x8;_0x3640f5<=0x48;_0x3640f5++){_0x214ecd[_0x4d1b39('0x1fd0')](_0x3640f5+'/'+_0x3640f5+'pt');}_0x22e7e9['ckeditor'][_0x4d1b39('0x24ff')]=_0x214ecd[_0x4d1b39('0x1630')](';'),_0x22e7e9[_0x4d1b39('0x8f')]={'target':_0x4d1b39('0x428'),'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x35de4b,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x22e7e9[_0x4d1b39('0x1fa6')]={'flow':{}},_0x22e7e9[_0x4d1b39('0xb9d')]=_0x57319a,_0x22e7e9[_0x4d1b39('0x1909')]=_0x596f15,_0x22e7e9['forward']=_0x1498da,_0x22e7e9[_0x4d1b39('0x19f')]=_0x5a98ec,_0x22e7e9[_0x4d1b39('0x1503')]=_0x2de8cb,_0x22e7e9['note']=_0x4e5558,_0x22e7e9[_0x4d1b39('0x1e9a')]=_0x36e3ef,_0x22e7e9[_0x4d1b39('0xa03')]=_0x5b34ee,_0x22e7e9[_0x4d1b39('0x1152')]=_0x246fb8,_0x22e7e9[_0x4d1b39('0x102c')]=_0x244a4c,_0x22e7e9[_0x4d1b39('0x1aad')]=_0x438911,_0x22e7e9[_0x4d1b39('0x183e')]=_0x370294,_0x22e7e9[_0x4d1b39('0x16a1')]=_0x10225b,_0x22e7e9[_0x4d1b39('0x19af')]=_0x48eadd,_0x22e7e9['saveDraft']=_0x61b62d,_0x22e7e9['closeDialog']=_0x43bd44,_0x22e7e9[_0x4d1b39('0x2d3')]=_0x4892a0;switch(_0x2bfe96){case'reply':_0x22e7e9[_0x4d1b39('0xb9d')](![]);break;case _0x4d1b39('0x1766'):_0x22e7e9[_0x4d1b39('0xb9d')](!![]);break;case _0x4d1b39('0xcc3'):_0x22e7e9[_0x4d1b39('0xcc3')]();break;case'draft':_0x22e7e9['editDraft']();break;case _0x4d1b39('0x1476'):_0x22e7e9[_0x4d1b39('0x1909')]();break;case'note':_0x22e7e9[_0x4d1b39('0x2203')]();break;}_0x5aa4b0[_0x4d1b39('0x1577')][_0x4d1b39('0x1e6e')]({'nolimit':!![]})[_0x4d1b39('0xe53')][_0x4d1b39('0x683')](function(_0x525839){const _0xb5153b=_0x4d1b39;_0x22e7e9[_0xb5153b('0x26a3')]=_0x525839||{'count':0x0,'rows':[]};})[_0x4d1b39('0x130a')](function(_0x4a8045){const _0x44ff94=_0x4d1b39;console[_0x44ff94('0x52a')](_0x4a8045);});!_0x22e7e9[_0x4d1b39('0x252d')]&&_0x50c133();function _0x57319a(_0x2c0fab){const _0x3295da=_0x4d1b39;angular[_0x3295da('0x127')](_0x31a254)&&(_0x22e7e9['message'][_0x3295da('0xcf0')]=_0x3295da('0xb9d'),_0x22e7e9[_0x3295da('0x8c2')]['to']=_0x31a254[_0x3295da('0x2655')]==='in'?_0x31a254[_0x3295da('0x705')]['split'](','):_0x31a254['to'][_0x3295da('0x1fc5')](','),_0x22e7e9[_0x3295da('0x8c2')][_0x3295da('0x1e66')]=_0x2e3ca0()[_0x3295da('0x18ad')](_0x31a254[_0x3295da('0x1e66')],_0x3295da('0x843'))?_0x31a254[_0x3295da('0x1e66')]:'Re:\x20'+_0x31a254[_0x3295da('0x1e66')],_0x22e7e9[_0x3295da('0x8c2')][_0x3295da('0x20ea')]=_0x31a254[_0x3295da('0x2421')],_0x22e7e9['message'][_0x3295da('0x18e5')]=_0x1babcb(),_0x22e7e9[_0x3295da('0x8c2')][_0x3295da('0x1b46')]=[],_0x2c0fab&&_0x31a254['cc']&&(_0x22e7e9[_0x3295da('0x1ae9')]=![],_0x22e7e9['message']['cc']=_0x31a254['cc'][_0x3295da('0x1fc5')](',')),_0x22e7e9['message']['showLastMessage']=![]);}function _0x596f15(){const _0x308935=_0x4d1b39;angular[_0x308935('0x127')](_0x31a254)&&(_0x22e7e9[_0x308935('0x8c2')][_0x308935('0xcf0')]=_0x308935('0x1476'),_0x22e7e9[_0x308935('0x8c2')]['to']=_0x31a254['to']?_0x31a254['to'][_0x308935('0x1fc5')](','):[]);}function _0x5a98ec(){const _0xb9f83d=_0x4d1b39;_0x22e7e9['isDraft']=!![],angular['isDefined'](_0x31a254)&&(_0x31a254[_0xb9f83d('0x250b')]=![],_0x22e7e9[_0xb9f83d('0x8c2')]=angular[_0xb9f83d('0x1a86')](_0x31a254),!_0x2e3ca0()[_0xb9f83d('0x173f')](_0x22e7e9[_0xb9f83d('0x8c2')]['cc'])&&(_0x22e7e9[_0xb9f83d('0x1ae9')]=![]),!_0x2e3ca0()[_0xb9f83d('0x173f')](_0x22e7e9[_0xb9f83d('0x8c2')]['bcc'])&&(_0x22e7e9[_0xb9f83d('0x98a')]=![]));}function _0x1498da(){const _0x36fbac=_0x4d1b39;if(angular['isDefined'](_0x31a254)){_0x22e7e9[_0x36fbac('0x8c2')]['type']=_0x36fbac('0xcc3'),_0x22e7e9[_0x36fbac('0x8c2')][_0x36fbac('0x1e66')]=_0x2e3ca0()[_0x36fbac('0x18ad')](_0x31a254[_0x36fbac('0x1e66')],'Fwd:')?_0x31a254[_0x36fbac('0x1e66')]:'Fwd:\x20'+_0x31a254[_0x36fbac('0x1e66')],_0x22e7e9[_0x36fbac('0x8c2')][_0x36fbac('0x18e5')]=_0x1babcb();if(_0x31a254[_0x36fbac('0x502')]&&_0x31a254[_0x36fbac('0x502')][_0x36fbac('0x1564')])for(let _0x3bae9c=0x0;_0x3bae9c<_0x31a254[_0x36fbac('0x502')]['length'];_0x3bae9c++){_0x22e7e9['message']['attachments'][_0x36fbac('0x1fd0')](_0x31a254[_0x36fbac('0x502')][_0x3bae9c]);}_0x22e7e9['message']['showLastMessage']=![];}}function _0x4e5558(){const _0x8a8b7e=_0x4d1b39;_0x22e7e9[_0x8a8b7e('0xcf0')]=_0x8a8b7e('0x2203'),_0x22e7e9[_0x8a8b7e('0x252d')]=!![],_0x22e7e9['message'][_0x8a8b7e('0x18e5')]=_0x8a8b7e('0x1291')+_0x11ab11[_0x8a8b7e('0x7a7')]+_0x8a8b7e('0x849')+_0x11ab11['fontSize']+_0x8a8b7e('0x1aca');}function _0x1fb8ef(_0x252d8c,_0xceb380){const _0x1841f8=_0x4d1b39,_0x5c9f14={'from':_0x22e7e9[_0x1841f8('0x8c2')][_0x1841f8('0x705')],'to':_0x22e7e9['message']['to']['join'](','),'cc':_0x22e7e9[_0x1841f8('0x8c2')]['cc']['join'](','),'bcc':_0x22e7e9[_0x1841f8('0x8c2')]['bcc'][_0x1841f8('0x1630')](','),'subject':_0x22e7e9[_0x1841f8('0x8c2')]['subject'],'body':_0x22e7e9[_0x1841f8('0x8c2')]['showLastMessage']?_0x22e7e9[_0x1841f8('0x8c2')][_0x1841f8('0x18e5')]:_0x22e7e9[_0x1841f8('0x8c2')][_0x1841f8('0x18e5')]+_0x535220(_0x22e7e9[_0x1841f8('0x8c2')][_0x1841f8('0xcf0')]),'inReplyTo':_0x22e7e9[_0x1841f8('0x8c2')][_0x1841f8('0x20ea')],'attach':_0x22e7e9[_0x1841f8('0x8c2')]['attachments'][_0x1841f8('0x1564')],'attachments':_0x22e7e9[_0x1841f8('0x8c2')][_0x1841f8('0x1b46')],'Interaction':{'lastMsgDirection':'out','lastMsgBody':_0x22e7e9['message'][_0x1841f8('0x18e5')],'substatus':_0xceb380},'isDraft':_0x22e7e9[_0x1841f8('0x31f')]};_0x5c9f14[_0x1841f8('0x84')]=''+_0x2e3ca0()['replace'](_0x5c9f14[_0x1841f8('0x18e5')],'',_0x252d8c&&(_0x5c9f14[_0x1841f8('0x1896')][_0x1841f8('0xd8a')]=!![]),_0x24a368[_0x1841f8('0x1715')](_0x5c9f14);}function _0x2de8cb(_0x2f13ae,_0x457245,_0x5f2b7e){const _0x225a37=_0x4d1b39;if(_0x22e7e9[_0x225a37('0x8c2')]['to']&&_0x22e7e9[_0x225a37('0x8c2')][_0x225a37('0x18e5')]){if(_0x22e7e9[_0x225a37('0x8c2')]['to'][_0x225a37('0x1564')]){if(_0x2e3ca0()[_0x225a37('0x173f')](_0x22e7e9[_0x225a37('0x8c2')]['subject'])){const _0x4663c4=_0x24a368[_0x225a37('0x1c6f')]({'skipHide':!![]})['title'](_0x225a37('0x128f'))[_0x225a37('0x1525')](_0x225a37('0x12cc'))[_0x225a37('0x1040')](_0x225a37('0x128f'))[_0x225a37('0xe42')](_0x2f13ae)['ok']('Send\x20Anyway')[_0x225a37('0x19fb')](_0x225a37('0x253a'));_0x24a368[_0x225a37('0x1d4')](_0x4663c4)['then'](function(){_0x1fb8ef(_0x457245,_0x5f2b7e);});}else _0x1fb8ef(_0x457245,_0x5f2b7e);}else _0x275651[_0x225a37('0x52a')](_0x225a37('0x17c7'));}}function _0x36e3ef(){const _0x2b7992=_0x4d1b39;_0x22e7e9[_0x2b7992('0x8c2')][_0x2b7992('0x18e5')]&&_0x24a368[_0x2b7992('0x1715')]({'secret':!![],'body':_0x22e7e9[_0x2b7992('0x8c2')][_0x2b7992('0x18e5')],'attach':_0x22e7e9[_0x2b7992('0x8c2')]['attachments'][_0x2b7992('0x1564')],'attachments':_0x22e7e9['message']['attachments']});}function _0x30370a(_0x223179){const _0xd5c76f=_0x4d1b39;if(_0x223179&&_0x223179['value']&&_0x22e7e9[_0xd5c76f('0x3c9')])try{const _0x29cdea=_0x2e3ca0()[_0xd5c76f('0x1cc6')](_0x223179[_0xd5c76f('0x1c6b')]),_0x1aa913={'user':_0x22e7e9[_0xd5c76f('0x11ed')],'account':_0x11ab11,'interaction':_0x488254,'contact':_0x488254&&_0x488254[_0xd5c76f('0x1309')]?_0x488254['Contact']:{}};_0x22e7e9['ckEditorInstance']['insertHtml'](_0x29cdea(_0x1aa913));}catch(_0x4a03b4){console[_0xd5c76f('0x52a')](_0x4a03b4),_0x22e7e9['ckEditorInstance'][_0xd5c76f('0x2e9')](_0x223179['value']);}document['getElementById'](_0xd5c76f('0x1070'))['focus'](),_0x22e7e9[_0xd5c76f('0x2261')]=null;}function _0x3db8bc(_0x17afd2){const _0x3dac5f=_0x4d1b39,_0x116193=_0x26bae0['defer']();let _0xa6deb7=[];return _0x5aa4b0[_0x3dac5f('0x136c')][_0x3dac5f('0x1e6e')]({'filter':_0x17afd2,'MailAccountId':_0x11ab11['id']})[_0x3dac5f('0xe53')][_0x3dac5f('0x683')](function(_0x6e24c2){const _0x2843a1=_0x3dac5f;return _0xa6deb7=_0x2e3ca0()[_0x2843a1('0x746')](_0xa6deb7,_0x6e24c2[_0x2843a1('0xf5d')]),_0x5aa4b0[_0x2843a1('0x136c')][_0x2843a1('0x1e6e')]({'filter':_0x17afd2})[_0x2843a1('0xe53')];})[_0x3dac5f('0x683')](function(_0x266c5b){const _0x25063b=_0x3dac5f;_0xa6deb7=_0x2e3ca0()[_0x25063b('0x746')](_0xa6deb7,_0x2e3ca0()[_0x25063b('0x25')](_0x266c5b[_0x25063b('0xf5d')],function(_0x3a12b2){const _0x4059e4=_0x25063b;return!_0x3a12b2[_0x4059e4('0x1cd')]&&!_0x3a12b2[_0x4059e4('0xe22')]&&!_0x3a12b2[_0x4059e4('0x1f4f')]&&!_0x3a12b2[_0x4059e4('0x1c35')]&&!_0x3a12b2[_0x4059e4('0x1061')]&&!_0x3a12b2[_0x4059e4('0x15a5')];})),_0x116193[_0x25063b('0xed7')](_0xa6deb7);})['catch'](function(_0xbb61a4){_0x116193['reject'](_0xbb61a4);}),_0x116193[_0x3dac5f('0x1883')];}function _0x622e09(){const _0x20b7fc=_0x4d1b39;try{_0x22e7e9[_0x20b7fc('0x3c9')]=window[_0x20b7fc('0x1a2')]['instances'][_0x20b7fc('0x1070')];}catch(_0x1709cb){console[_0x20b7fc('0x52a')]('Unable\x20to\x20get\x20Html\x20Editor\x20instance',_0x1709cb);}}function _0x50c133(){const _0x30ae42=_0x4d1b39;return _0x5aa4b0['mailAccount']['verifySmtp']({'id':_0x11ab11['id']})[_0x30ae42('0xe53')][_0x30ae42('0x130a')](function(_0x3fc420){const _0x1f624b=_0x30ae42;_0x22e7e9['verifySmtp']=![],_0x22e7e9[_0x1f624b('0x17f')]['push']({'message':_0x3fc420[_0x1f624b('0x5a5')],'type':_0x3fc420[_0x1f624b('0x13ee')]}),_0x22e7e9[_0x1f624b('0x17f')]['push']({'message':_0x1f624b('0x197'),'type':_0x1f624b('0x108a')});});}function _0x438911(_0x342082){const _0x426b7d=_0x4d1b39;if(_0x342082[_0x426b7d('0x1a41')]>_0x35de4b)return _0x275651[_0x426b7d('0x52a')]({'title':_0x426b7d('0x19a2'),'msg':_0x426b7d('0x1622')+_0x134aef+'MB'}),![];return!![];}function _0x5b34ee(){const _0x1612b7=_0x4d1b39;_0x22e7e9[_0x1612b7('0x1fa6')][_0x1612b7('0x190a')]['opts'][_0x1612b7('0xb7d')]={'X-Requested-With':_0x1612b7('0xbfd'),'Authorization':_0x1612b7('0x189e')+_0x6361a[_0x1612b7('0x1e6e')](_0x1612b7('0x555'))},_0x22e7e9[_0x1612b7('0x1fa6')][_0x1612b7('0x190a')]['upload']();}function _0x246fb8(_0x7077a8,_0xe1ec45){const _0x5b334a=_0x4d1b39;try{_0xe1ec45=JSON['parse'](_0xe1ec45),_0xe1ec45[_0x5b334a('0x1a41')]=_0x7077a8[_0x5b334a('0x1a41')],_0x22e7e9[_0x5b334a('0x8c2')][_0x5b334a('0x1b46')][_0x5b334a('0x1fd0')](_0xe1ec45);}catch(_0x5da3b6){console[_0x5b334a('0x52a')](_0x5da3b6);}}function _0x244a4c(_0x466320){const _0x397e1c=_0x4d1b39;_0x22e7e9['message'][_0x397e1c('0x1b46')]=_0x2e3ca0()[_0x397e1c('0xfae')](_0x22e7e9[_0x397e1c('0x8c2')][_0x397e1c('0x1b46')],{'id':_0x466320['id']}),!_0x466320[_0x397e1c('0x1ee9')]&&_0x5aa4b0[_0x397e1c('0x34')][_0x397e1c('0xd7e')]({'id':_0x466320['id']})[_0x397e1c('0xe53')]['catch'](function(_0x5642cf){const _0x150f38=_0x397e1c;_0x275651[_0x150f38('0x52a')]({'title':_0x5642cf[_0x150f38('0x13ee')]?_0x150f38('0x2168')+_0x5642cf[_0x150f38('0x13ee')]+'\x20-\x20'+_0x5642cf[_0x150f38('0x24a9')]:_0x150f38('0x22ce'),'msg':_0x5642cf[_0x150f38('0x5a5')]?JSON[_0x150f38('0x258a')](_0x5642cf[_0x150f38('0x5a5')]['message']):_0x5642cf['toString']()});});}function _0x370294(_0x47479b){const _0x4f253f=_0x4d1b39;let _0x2173ae='';return _0x47479b[_0x4f253f('0xeef')]&&_0x47479b['firstName']!==_0x47479b[_0x4f253f('0x1c92')]&&(_0x2173ae+=_0x47479b[_0x4f253f('0xeef')]+'\x20'),_0x47479b[_0x4f253f('0x510')]&&_0x47479b[_0x4f253f('0x510')]!==_0x47479b[_0x4f253f('0x1c92')]&&(_0x2173ae+=_0x47479b[_0x4f253f('0x510')]+'\x20'),_0x2173ae+='<'+_0x47479b[_0x4f253f('0x1c92')]+'>';}function _0x48eadd(_0x140ea7,_0x232f90){const _0x32383c=_0x4d1b39;if(_0x2e3ca0()[_0x32383c('0x20b6')](_0x140ea7))return _0x22e7e9['contact']=_0x140ea7,_0x140ea7[_0x32383c('0x1c92')];if(_0x2e3ca0()['isString'](_0x140ea7)){if(_0x12dd86(_0x140ea7))return _0x22e7e9[_0x32383c('0xd06')]={'email':_0x140ea7},_0x140ea7;else{const _0x48fec5=_0x140ea7['split'](',');for(let _0x289c42=0x0;_0x289c42<_0x48fec5[_0x32383c('0x1564')];_0x289c42+=0x1){_0x12dd86(_0x48fec5[_0x289c42])?_0x2e3ca0()[_0x32383c('0x94b')](_0x232f90)&&_0x2e3ca0()[_0x32383c('0x824')](_0x232f90,_0x48fec5[_0x289c42])<0x0&&_0x232f90[_0x32383c('0x1fd0')](_0x48fec5[_0x289c42]):_0x275651[_0x32383c('0x52a')](_0x32383c('0x1eb2')+_0x48fec5[_0x289c42]+'\x20is\x20not\x20valid');}return _0x22e7e9[_0x32383c('0xd06')]={'email':_0x140ea7['split'](',')[0x0]},null;}}return _0x275651['error']('Email\x20field\x20is\x20not\x20valid'),null;}function _0x10225b(_0x2f06ab){const _0x1313cf=_0x4d1b39;return _0x11ab11&&_0x11ab11['ListId']?_0x5aa4b0['cmContact']['get']({'ListId':_0x11ab11['ListId'],'nolimit':!![],'filter':_0x2f06ab,'fields':'firstName,lastName,email'})[_0x1313cf('0xe53')][_0x1313cf('0x683')](function(_0x3aa82a){const _0x1aa2b3=_0x1313cf;return _0x3aa82a[_0x1aa2b3('0xf5d')];}):[];}function _0x61b62d(){const _0x179e28=_0x4d1b39;_0x22e7e9['message']['savedAsDraft']=!![],_0x22e7e9['draft']=_0x4ffc98['getByInteraction'](_0x488254['id']);const _0x19ec59={'account':_0x11ab11,'message':_0x22e7e9[_0x179e28('0x8c2')],'contact':_0x22e7e9[_0x179e28('0xd06')],'interaction':_0x488254};if(_0x22e7e9[_0x179e28('0x2546')]&&!_0x22e7e9['isDraft']){const _0x4f321b=_0x24a368['confirm']({'skipHide':!![]})[_0x179e28('0xf28')](_0x2a2c20['instant']('DASHBOARDS.DRAFT_SAVE_WARNING_TITLE'))[_0x179e28('0xa6a')](_0x2a2c20['instant'](_0x179e28('0x435')))[_0x179e28('0x1040')]('Save\x20draft')['ok'](_0x2a2c20['instant']('DASHBOARDS.OVERWRITE'))['cancel'](_0x2a2c20[_0x179e28('0x2728')](_0x179e28('0x27a9')));_0x24a368[_0x179e28('0x1d4')](_0x4f321b)[_0x179e28('0x683')](function(){const _0x47975c=_0x179e28;_0x24a368[_0x47975c('0x1715')](_0x19ec59);});}else _0x24a368[_0x179e28('0x1715')](_0x19ec59);}function _0x43bd44(){const _0x1446f7=_0x4d1b39;_0x24a368[_0x1446f7('0x19fb')]();}function _0x12dd86(_0x5cc68f){const _0x1aacef=_0x4d1b39,_0x3842e1=/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;return _0x3842e1[_0x1aacef('0x237c')](_0x5cc68f);}function _0x57a8d8(_0x506386){const _0x48bbe5=/]*>([^]*)<\/body/m,_0x44946a=_0x506386['match'](_0x48bbe5);if(_0x44946a)return _0x44946a[0x1];return _0x506386;}function _0x4ac353(){const _0x1f16fc=_0x4d1b39;if(_0x2e3ca0()[_0x1f16fc('0x8f2')](_0x11ab11[_0x1f16fc('0x1cc6')]))return'';try{const _0x5dff7c=_0x2e3ca0()[_0x1f16fc('0x1cc6')](_0x11ab11[_0x1f16fc('0x1cc6')]),_0x28b3f2={'user':_0x22e7e9[_0x1f16fc('0x11ed')],'account':_0x11ab11,'interaction':_0x488254,'contact':_0x488254&&_0x488254['Contact']?_0x488254[_0x1f16fc('0x1309')]:{}};return _0x5dff7c(_0x28b3f2);}catch(_0x3ae759){return console['error'](_0x3ae759),'';}}function _0x1babcb(){const _0x4ace5d=_0x4d1b39;return _0x4ace5d('0x1291')+_0x11ab11['fontFamily']+_0x4ace5d('0x849')+_0x11ab11[_0x4ace5d('0x2269')]+'pt\x22>'+_0x4ac353()+'
';}function _0x535220(_0x2bdae5){const _0x22f626=_0x4d1b39;let _0x11b9d0=_0x22f626('0x1ad5');switch(_0x2bdae5){case _0x22f626('0xb9d'):case _0x22f626('0x1766'):_0x11b9d0+=_0x22e7e9[_0x22f626('0x2599')]({'date':_0x1aaf93()(_0x31a254[_0x22f626('0x1a4')])[_0x22f626('0x26dd')](_0x22f626('0x198a'))||'','time':_0x1aaf93()(_0x31a254[_0x22f626('0x1a4')])[_0x22f626('0x26dd')](_0x22f626('0x3ed'))||'','from':_0x2e3ca0()['escape'](_0x31a254['from'])||''});break;case _0x22f626('0xcc3'):_0x11b9d0+=_0x22e7e9[_0x22f626('0x1e56')]({'date':_0x1aaf93()(_0x31a254['createdAt'])[_0x22f626('0x26dd')](_0x22f626('0x198a'))||'','time':_0x1aaf93()(_0x31a254['createdAt'])['format'](_0x22f626('0x3ed'))||'','from':_0x2e3ca0()[_0x22f626('0x141d')](_0x31a254[_0x22f626('0x705')])||'','to':_0x2e3ca0()[_0x22f626('0x141d')](_0x31a254['to'])||'','subject':_0x2e3ca0()['escape'](_0x31a254[_0x22f626('0x1e66')])||''});break;}const _0x4341df=_0x22e7e9['message'][_0x22f626('0x2667')]&&_0x31a254[_0x22f626('0x9fc')]?_0x31a254[_0x22f626('0x9fc')][_0x22f626('0x18e5')]:_0x31a254[_0x22f626('0x18e5')];return _0x11b9d0+=_0x22f626('0xde0'),_0x11b9d0+=_0x57a8d8(_0x4341df?_0x2e3ca0()[_0x22f626('0x1725')](_0x4341df,_0x22f626('0x194c'),_0x22f626('0x666')):''),_0x11b9d0+='',_0x2bdae5?_0x11b9d0:'';}function _0x4892a0(){const _0x241939=_0x4d1b39;_0x22e7e9['message'][_0x241939('0x18e5')]+=_0x535220(_0x22e7e9[_0x241939('0x8c2')][_0x241939('0xcf0')]);}}const _0x1d196e=_0x3dfec2;_0x229691['$inject']=[_0x189033('0x17e4'),'$timeout',_0x189033('0x2063'),_0x189033('0x1e48'),_0x189033('0x1f45'),'account',_0x189033('0x8c2'),'type',_0x189033('0x56b'),_0x189033('0x1d70'),'$q',_0x189033('0x1d08'),_0x189033('0xba1')];function _0x229691(_0x52b900,_0x3c3df2,_0x281a6b,_0x247848,_0xde0fbd,_0x40b28b,_0x3399fa,_0xd7a37,_0x14b14d,_0x4b0dc7,_0x56f14c,_0x4d3334,_0x10530e){const _0x10e364=_0x189033,_0x6f1dae=this;_0x6f1dae[_0x10e364('0x11ed')]=_0x10530e[_0x10e364('0x20b2')](),_0x6f1dae[_0x10e364('0x17f')]=[],_0x6f1dae['separatorKeys']=[_0xde0fbd[_0x10e364('0x8')][_0x10e364('0x172d')],_0xde0fbd[_0x10e364('0x8')]['COMMA'],_0xde0fbd[_0x10e364('0x8')][_0x10e364('0xed')]],_0x6f1dae[_0x10e364('0x1361')]=_0x51c578,_0x6f1dae[_0x10e364('0x5a2')]=_0x1499e4,_0x6f1dae[_0x10e364('0x2203')]=_0x3eee7,_0x6f1dae[_0x10e364('0x1e9a')]=_0x2c6117,_0x6f1dae[_0x10e364('0x1ee5')]={},_0x6f1dae[_0x10e364('0x8c2')]={'from':_0x40b28b['phone'],'to':_0x2e3ca0()[_0x10e364('0x8f2')](_0x3399fa['to'])||_0x2e3ca0()[_0x10e364('0x173f')](_0x3399fa['to'])?[]:_0x3399fa['to'],'body':''},_0x6f1dae['send']=_0x104762,_0x6f1dae['getContact']=_0x23c8b9,_0x6f1dae['closeDialog']=_0xf2266e,_0x6f1dae[_0x10e364('0x16a1')]=_0x55ad57,_0x6f1dae['transformContact']=_0xe0dd1a;switch(_0xd7a37){case _0x10e364('0x2203'):_0x6f1dae['note']();break;}function _0x4402ca(_0x32212d){const _0x38920a=_0x10e364;_0x247848[_0x38920a('0x1715')]({'to':_0x6f1dae['message']['to']['join'](','),'body':_0x32212d});}function _0x104762(){const _0x1c328d=_0x10e364;_0x6f1dae[_0x1c328d('0x8c2')]['to']&&_0x6f1dae[_0x1c328d('0x8c2')][_0x1c328d('0x18e5')]&&(_0x6f1dae[_0x1c328d('0x8c2')]['to'][_0x1c328d('0x1564')]?_0x4402ca(_0x6f1dae['message'][_0x1c328d('0x18e5')]):_0x4b0dc7[_0x1c328d('0x52a')]('To\x20is\x20mandatory'));}function _0x1499e4(_0x1facae){const _0x836d1c=_0x10e364;if(_0x1facae){try{_0x2e3ca0()['templateSettings'][_0x836d1c('0x14fd')]=/{{([\s\S]+?)}}/g;const _0x164134=_0x2e3ca0()[_0x836d1c('0x1cc6')](_0x1facae[_0x836d1c('0x1c6b')]),_0x5032f2={'user':_0x6f1dae[_0x836d1c('0x11ed')],'account':_0x40b28b};_0x6f1dae[_0x836d1c('0x8c2')][_0x836d1c('0x18e5')]+='\x20'+_0x164134(_0x5032f2),_0x6f1dae['ctrlMethods'][_0x836d1c('0x2726')](_0x6f1dae['message'][_0x836d1c('0x18e5')]);}catch(_0x41938e){_0x6f1dae[_0x836d1c('0x8c2')][_0x836d1c('0x18e5')]+='\x20'+_0x1facae[_0x836d1c('0x1c6b')],_0x6f1dae[_0x836d1c('0x1ee5')][_0x836d1c('0x2726')](_0x6f1dae[_0x836d1c('0x8c2')][_0x836d1c('0x18e5')]);}_0x6f1dae[_0x836d1c('0x2261')]=null;}}function _0x51c578(_0x4c9dce){const _0x25fa95=_0x10e364,_0x51eec6=_0x56f14c[_0x25fa95('0x448')]();let _0x5a4893=[];return _0x14b14d[_0x25fa95('0x136c')][_0x25fa95('0x1e6e')]({'filter':_0x4c9dce,'OpenchannelAccountId':_0x40b28b['id']})['$promise'][_0x25fa95('0x683')](function(_0x931587){const _0x114228=_0x25fa95;return _0x5a4893=_0x2e3ca0()[_0x114228('0x746')](_0x5a4893,_0x931587[_0x114228('0xf5d')]),_0x14b14d[_0x114228('0x136c')][_0x114228('0x1e6e')]({'filter':_0x4c9dce})[_0x114228('0xe53')];})[_0x25fa95('0x683')](function(_0x427295){const _0x25dae2=_0x25fa95;_0x5a4893=_0x2e3ca0()[_0x25dae2('0x746')](_0x5a4893,_0x2e3ca0()[_0x25dae2('0x25')](_0x427295[_0x25dae2('0xf5d')],function(_0xfe6043){const _0x38b004=_0x25dae2;return!_0xfe6043[_0x38b004('0x1cd')]&&!_0xfe6043[_0x38b004('0xe22')]&&!_0xfe6043[_0x38b004('0x1f4f')]&&!_0xfe6043[_0x38b004('0x1c35')]&&!_0xfe6043[_0x38b004('0x1061')]&&!_0xfe6043[_0x38b004('0x15a5')];})),_0x51eec6[_0x25dae2('0xed7')](_0x5a4893);})[_0x25fa95('0x130a')](function(_0x43afd1){const _0x375e93=_0x25fa95;_0x51eec6[_0x375e93('0xfae')](_0x43afd1);}),_0x51eec6[_0x25fa95('0x1883')];}function _0x23c8b9(_0x4f36f2){const _0x57cfe7=_0x10e364;let _0x281331='';return _0x4f36f2[_0x57cfe7('0xeef')]&&_0x4f36f2[_0x57cfe7('0xeef')]!==_0x4f36f2[_0x40b28b[_0x57cfe7('0x1d6f')]]&&(_0x281331+=_0x4f36f2[_0x57cfe7('0xeef')]+'\x20'),_0x4f36f2['lastName']&&_0x4f36f2[_0x57cfe7('0x510')]!==_0x4f36f2[_0x40b28b[_0x57cfe7('0x1d6f')]]&&(_0x281331+=_0x4f36f2[_0x57cfe7('0x510')]+'\x20'),_0x281331+='<'+_0x4f36f2[_0x40b28b['mapKey']]+'>';}function _0xe0dd1a(_0x8def6d){const _0x5b8701=_0x10e364,_0x1ee05c=_0x8def6d;if(_0x2e3ca0()[_0x5b8701('0x20b6')](_0x1ee05c))return _0x8def6d[_0x40b28b['mapKey']];return _0x1ee05c;}function _0x55ad57(_0x246d97){const _0x12bf8a=_0x10e364;if(_0x40b28b&&_0x40b28b[_0x12bf8a('0x1e4f')]){let _0x10d4dd=_0x12bf8a('0xc82');return _0x40b28b[_0x12bf8a('0x1d6f')]&&(_0x10d4dd+=','+_0x40b28b[_0x12bf8a('0x1d6f')]),_0x14b14d[_0x12bf8a('0x276e')][_0x12bf8a('0x1e6e')]({'ListId':_0x40b28b[_0x12bf8a('0x1e4f')],'nolimit':!![],'filter':_0x246d97,'fields':_0x10d4dd})[_0x12bf8a('0xe53')][_0x12bf8a('0x683')](function(_0xf02373){const _0x12a210=_0x12bf8a;return _0xf02373[_0x12a210('0xf5d')];});}return[];}function _0xf2266e(){const _0xc566eb=_0x10e364;_0x247848[_0xc566eb('0x19fb')]();}function _0x3eee7(){const _0x5171a6=_0x10e364;_0x6f1dae[_0x5171a6('0x252d')]=!![];}function _0x2c6117(){const _0x266c0a=_0x10e364;_0x6f1dae[_0x266c0a('0x8c2')]['body']&&_0x247848[_0x266c0a('0x1715')]({'secret':!![],'body':_0x6f1dae[_0x266c0a('0x8c2')][_0x266c0a('0x18e5')]});}}const _0x123003=_0x229691;_0x4cfda4[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x2f9'),'$window',_0x189033('0x1e48'),_0x189033('0x1f45'),_0x189033('0x1d2f'),_0x189033('0x8c2'),_0x189033('0xcf0'),_0x189033('0x56b'),_0x189033('0x1d70'),'$q',_0x189033('0x1d08'),_0x189033('0xba1')];function _0x4cfda4(_0x15b4b3,_0xd55a7a,_0x2573e1,_0x5d8ef8,_0x57df6c,_0x3ab3c4,_0x27873a,_0x1d6bbd,_0x1f882e,_0x4e9e0d,_0x20efaa,_0x3fd46c,_0x5f5b6e){const _0x31dc1f=_0x189033,_0x41e6ac=this;_0x41e6ac[_0x31dc1f('0x11ed')]=_0x5f5b6e[_0x31dc1f('0x20b2')](),_0x41e6ac[_0x31dc1f('0x17f')]=[],_0x41e6ac[_0x31dc1f('0x7fe')]=[_0x57df6c[_0x31dc1f('0x8')]['ENTER'],_0x57df6c['KEY_CODE'][_0x31dc1f('0x1ff1')],_0x57df6c[_0x31dc1f('0x8')]['TAB']],_0x41e6ac[_0x31dc1f('0x1361')]=_0x546464,_0x41e6ac[_0x31dc1f('0x5a2')]=_0x435a5b,_0x41e6ac['note']=_0x5ba71c,_0x41e6ac[_0x31dc1f('0x1e9a')]=_0x51a1ac,_0x41e6ac[_0x31dc1f('0x1ee5')]={},_0x41e6ac[_0x31dc1f('0x8c2')]={'from':_0x3ab3c4[_0x31dc1f('0xd31')],'to':_0x2e3ca0()[_0x31dc1f('0x8f2')](_0x27873a['to'])||_0x2e3ca0()[_0x31dc1f('0x173f')](_0x27873a['to'])?[]:_0x27873a['to'],'body':''},_0x41e6ac['send']=_0x4c43eb,_0x41e6ac[_0x31dc1f('0x183e')]=_0x3f75a8,_0x41e6ac[_0x31dc1f('0xf82')]=_0x562aa0,_0x41e6ac[_0x31dc1f('0x16a1')]=_0x276caf,_0x41e6ac['transformContact']=_0x50b686;switch(_0x1d6bbd){case _0x31dc1f('0x2203'):_0x41e6ac['note']();break;}function _0xff3564(_0x179448){const _0x371cee=_0x31dc1f;_0x5d8ef8['hide']({'to':_0x41e6ac[_0x371cee('0x8c2')]['to']['join'](','),'body':_0x179448});}function _0x4c43eb(){const _0x5eb0f7=_0x31dc1f;_0x41e6ac[_0x5eb0f7('0x8c2')]['to']&&_0x41e6ac[_0x5eb0f7('0x8c2')]['body']&&(_0x41e6ac[_0x5eb0f7('0x8c2')]['to'][_0x5eb0f7('0x1564')]?_0xff3564(_0x41e6ac[_0x5eb0f7('0x8c2')][_0x5eb0f7('0x18e5')]):_0x4e9e0d[_0x5eb0f7('0x52a')](_0x5eb0f7('0x17c7')));}function _0x435a5b(_0x33817e){const _0x4bddc9=_0x31dc1f;if(_0x33817e){try{_0x2e3ca0()['templateSettings'][_0x4bddc9('0x14fd')]=/{{([\s\S]+?)}}/g;const _0x5b763d=_0x2e3ca0()[_0x4bddc9('0x1cc6')](_0x33817e[_0x4bddc9('0x1c6b')]),_0x351c83={'user':_0x41e6ac['currentUser'],'account':_0x3ab3c4};_0x41e6ac[_0x4bddc9('0x8c2')][_0x4bddc9('0x18e5')]+='\x20'+_0x5b763d(_0x351c83),_0x41e6ac['ctrlMethods'][_0x4bddc9('0x2726')](_0x41e6ac[_0x4bddc9('0x8c2')][_0x4bddc9('0x18e5')]);}catch(_0x1246d2){_0x41e6ac[_0x4bddc9('0x8c2')][_0x4bddc9('0x18e5')]+='\x20'+_0x33817e['value'],_0x41e6ac[_0x4bddc9('0x1ee5')][_0x4bddc9('0x2726')](_0x41e6ac[_0x4bddc9('0x8c2')][_0x4bddc9('0x18e5')]);}_0x41e6ac[_0x4bddc9('0x2261')]=null;}}function _0x546464(_0x9c5cf){const _0x4e89ab=_0x31dc1f,_0x37f767=_0x20efaa[_0x4e89ab('0x448')]();let _0x4d7b61=[];return _0x1f882e['cannedAnswer'][_0x4e89ab('0x1e6e')]({'filter':_0x9c5cf,'SmsAccountId':_0x3ab3c4['id']})[_0x4e89ab('0xe53')][_0x4e89ab('0x683')](function(_0x4e128b){const _0x1cf8dc=_0x4e89ab;return _0x4d7b61=_0x2e3ca0()[_0x1cf8dc('0x746')](_0x4d7b61,_0x4e128b[_0x1cf8dc('0xf5d')]),_0x1f882e['cannedAnswer'][_0x1cf8dc('0x1e6e')]({'filter':_0x9c5cf})['$promise'];})['then'](function(_0x420893){const _0x18a63d=_0x4e89ab;_0x4d7b61=_0x2e3ca0()[_0x18a63d('0x746')](_0x4d7b61,_0x2e3ca0()['filter'](_0x420893['rows'],function(_0x16158b){const _0x15f43b=_0x18a63d;return!_0x16158b[_0x15f43b('0x1cd')]&&!_0x16158b[_0x15f43b('0xe22')]&&!_0x16158b[_0x15f43b('0x1f4f')]&&!_0x16158b[_0x15f43b('0x1061')]&&!_0x16158b[_0x15f43b('0x15a5')];})),_0x37f767['resolve'](_0x4d7b61);})[_0x4e89ab('0x130a')](function(_0x480687){const _0xd24d12=_0x4e89ab;_0x37f767[_0xd24d12('0xfae')](_0x480687);}),_0x37f767[_0x4e89ab('0x1883')];}function _0x3f75a8(_0x3522bd){const _0x6ac276=_0x31dc1f;let _0x28d492='';return _0x3522bd[_0x6ac276('0xeef')]&&_0x3522bd[_0x6ac276('0xeef')]!==_0x3522bd[_0x6ac276('0x200f')]&&(_0x28d492+=_0x3522bd[_0x6ac276('0xeef')]+'\x20'),_0x3522bd[_0x6ac276('0x510')]&&_0x3522bd['lastName']!==_0x3522bd[_0x6ac276('0x200f')]&&(_0x28d492+=_0x3522bd['lastName']+'\x20'),_0x28d492+='<'+_0x3522bd[_0x6ac276('0x200f')]+'>';}function _0x50b686(_0x23a765){const _0x3a9bb4=_0x31dc1f,_0x489046=_0x23a765;if(_0x2e3ca0()[_0x3a9bb4('0x20b6')](_0x489046))return _0x23a765[_0x3a9bb4('0x200f')];if(_0x3cb674(_0x489046))return _0x489046;return _0x4e9e0d[_0x3a9bb4('0x52a')](_0x3a9bb4('0x1425')+_0x489046+'\x20is\x20not\x20valid'),null;}function _0x276caf(_0x325d72){const _0x1d6f7d=_0x31dc1f;if(_0x3ab3c4&&_0x3ab3c4[_0x1d6f7d('0x1e4f')])return _0x1f882e[_0x1d6f7d('0x276e')][_0x1d6f7d('0x1e6e')]({'ListId':_0x3ab3c4[_0x1d6f7d('0x1e4f')],'nolimit':!![],'filter':_0x325d72,'fields':_0x1d6f7d('0x166a')})['$promise'][_0x1d6f7d('0x683')](function(_0x19cb1f){const _0x49dc08=_0x1d6f7d;return _0x19cb1f[_0x49dc08('0xf5d')];});return[];}function _0x562aa0(){const _0x3ed4f2=_0x31dc1f;_0x5d8ef8[_0x3ed4f2('0x19fb')]();}function _0x3cb674(_0x2f5164){const _0x9d62aa=_0x31dc1f,_0x582926=/^(\+|\d)[0-9]{7,16}$/;return _0x582926[_0x9d62aa('0x237c')](_0x2f5164);}function _0x5ba71c(){const _0x5a421e=_0x31dc1f;_0x41e6ac[_0x5a421e('0x252d')]=!![];}function _0x51a1ac(){const _0xb45058=_0x31dc1f;_0x41e6ac['message'][_0xb45058('0x18e5')]&&_0x5d8ef8['hide']({'secret':!![],'body':_0x41e6ac['message']['body']});}}const _0x13e37f=_0x4cfda4;_0x57fcab[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x2f9'),_0x189033('0x2063'),'$mdDialog',_0x189033('0x1f45'),_0x189033('0x1d2f'),_0x189033('0x8c2'),'type',_0x189033('0x56b'),_0x189033('0x1d70'),'$q',_0x189033('0x1d08'),'Auth'];function _0x57fcab(_0xc58157,_0x46dc1a,_0x41897d,_0x50d3f0,_0x4e8738,_0x185da8,_0x1e9152,_0x17faa2,_0x3210fc,_0x286dce,_0x353247,_0x257866,_0x4eacf6){const _0x579f16=_0x189033,_0x2bd980=this;_0x2bd980['currentUser']=_0x4eacf6[_0x579f16('0x20b2')](),_0x2bd980[_0x579f16('0x17f')]=[],_0x2bd980[_0x579f16('0x7fe')]=[_0x4e8738[_0x579f16('0x8')]['ENTER'],_0x4e8738[_0x579f16('0x8')]['COMMA'],_0x4e8738[_0x579f16('0x8')]['TAB']],_0x2bd980['searchTextChange']=_0x254937,_0x2bd980[_0x579f16('0x5a2')]=_0x4aa9f3,_0x2bd980[_0x579f16('0x2203')]=_0x3199a8,_0x2bd980[_0x579f16('0x1e9a')]=_0x379046,_0x2bd980[_0x579f16('0x1ee5')]={},_0x2bd980['message']={'from':_0x185da8[_0x579f16('0xd31')],'to':_0x2e3ca0()['isNil'](_0x1e9152['to'])||_0x2e3ca0()[_0x579f16('0x173f')](_0x1e9152['to'])?[]:_0x1e9152['to'],'body':''},_0x2bd980[_0x579f16('0x1503')]=_0x1d5397,_0x2bd980['getContact']=_0xa1bd,_0x2bd980[_0x579f16('0xf82')]=_0x1191c4,_0x2bd980['contactSearch']=_0x599769,_0x2bd980[_0x579f16('0x19af')]=_0x1c8552;switch(_0x17faa2){case _0x579f16('0x2203'):_0x2bd980['note']();break;}function _0x2c53da(_0x24cdc3){const _0x3c1d5d=_0x579f16;_0x50d3f0[_0x3c1d5d('0x1715')]({'to':_0x2bd980[_0x3c1d5d('0x8c2')]['to'][_0x3c1d5d('0x1630')](','),'body':_0x24cdc3});}function _0x1d5397(){const _0x21fbf7=_0x579f16;_0x2bd980[_0x21fbf7('0x8c2')]['to']&&_0x2bd980[_0x21fbf7('0x8c2')]['body']&&(_0x2bd980['message']['to'][_0x21fbf7('0x1564')]?_0x2c53da(_0x2bd980[_0x21fbf7('0x8c2')][_0x21fbf7('0x18e5')]):_0x286dce[_0x21fbf7('0x52a')](_0x21fbf7('0x17c7')));}function _0x4aa9f3(_0x27175b){const _0x30f0bb=_0x579f16;if(_0x27175b){try{_0x2e3ca0()['templateSettings'][_0x30f0bb('0x14fd')]=/{{([\s\S]+?)}}/g;const _0x107674=_0x2e3ca0()['template'](_0x27175b['value']),_0x437120={'user':_0x2bd980[_0x30f0bb('0x11ed')],'account':_0x185da8};_0x2bd980[_0x30f0bb('0x8c2')]['body']+='\x20'+_0x107674(_0x437120),_0x2bd980['ctrlMethods'][_0x30f0bb('0x2726')](_0x2bd980[_0x30f0bb('0x8c2')][_0x30f0bb('0x18e5')]);}catch(_0x7e3f6e){_0x2bd980[_0x30f0bb('0x8c2')][_0x30f0bb('0x18e5')]+='\x20'+_0x27175b[_0x30f0bb('0x1c6b')],_0x2bd980[_0x30f0bb('0x1ee5')][_0x30f0bb('0x2726')](_0x2bd980[_0x30f0bb('0x8c2')]['body']);}_0x2bd980[_0x30f0bb('0x2261')]=null;}}function _0x254937(_0xf7a79e){const _0x219d5f=_0x579f16,_0xc11d16=_0x353247[_0x219d5f('0x448')]();let _0x294ea7=[];return _0x3210fc[_0x219d5f('0x136c')][_0x219d5f('0x1e6e')]({'filter':_0xf7a79e,'WhatsappAccountId':_0x185da8['id']})[_0x219d5f('0xe53')]['then'](function(_0x22bb26){const _0x48f6b5=_0x219d5f;return _0x294ea7=_0x2e3ca0()[_0x48f6b5('0x746')](_0x294ea7,_0x22bb26[_0x48f6b5('0xf5d')]),_0x3210fc[_0x48f6b5('0x136c')][_0x48f6b5('0x1e6e')]({'filter':_0xf7a79e})[_0x48f6b5('0xe53')];})[_0x219d5f('0x683')](function(_0x8668ab){const _0x13a3a7=_0x219d5f;_0x294ea7=_0x2e3ca0()[_0x13a3a7('0x746')](_0x294ea7,_0x2e3ca0()[_0x13a3a7('0x25')](_0x8668ab[_0x13a3a7('0xf5d')],function(_0x392ff2){const _0x58940b=_0x13a3a7;return!_0x392ff2[_0x58940b('0x1cd')]&&!_0x392ff2['FaxAccountId']&&!_0x392ff2[_0x58940b('0x1c35')]&&!_0x392ff2[_0x58940b('0x1061')]&&!_0x392ff2[_0x58940b('0x15a5')];})),_0xc11d16[_0x13a3a7('0xed7')](_0x294ea7);})[_0x219d5f('0x130a')](function(_0x21f240){const _0xc7caf6=_0x219d5f;_0xc11d16[_0xc7caf6('0xfae')](_0x21f240);}),_0xc11d16['promise'];}function _0xa1bd(_0xd18dd9){const _0x49d9e8=_0x579f16;let _0x39e4ea='';return _0xd18dd9[_0x49d9e8('0xeef')]&&_0xd18dd9[_0x49d9e8('0xeef')]!==_0xd18dd9['mobile']&&(_0x39e4ea+=_0xd18dd9['firstName']+'\x20'),_0xd18dd9[_0x49d9e8('0x510')]&&_0xd18dd9['lastName']!==_0xd18dd9[_0x49d9e8('0x200f')]&&(_0x39e4ea+=_0xd18dd9[_0x49d9e8('0x510')]+'\x20'),_0x39e4ea+='<'+_0xd18dd9[_0x49d9e8('0x200f')]+'>';}function _0x1c8552(_0x5ba8c4){const _0x2fe8a0=_0x579f16,_0x422308=_0x5ba8c4;if(_0x2e3ca0()[_0x2fe8a0('0x20b6')](_0x422308))return _0x5ba8c4[_0x2fe8a0('0x200f')];if(_0x316bb9(_0x422308))return _0x422308;return _0x286dce['error'](_0x2fe8a0('0x1425')+_0x422308+_0x2fe8a0('0x15be')),null;}function _0x599769(_0x582a7e){const _0xfb363b=_0x579f16;if(_0x185da8&&_0x185da8[_0xfb363b('0x1e4f')])return _0x3210fc['cmContact'][_0xfb363b('0x1e6e')]({'ListId':_0x185da8[_0xfb363b('0x1e4f')],'nolimit':!![],'filter':_0x582a7e,'fields':'firstName,lastName,mobile'})[_0xfb363b('0xe53')][_0xfb363b('0x683')](function(_0x2e2623){const _0x10dfa0=_0xfb363b;return _0x2e2623[_0x10dfa0('0xf5d')];});return[];}function _0x1191c4(){const _0x1adc66=_0x579f16;_0x50d3f0[_0x1adc66('0x19fb')]();}function _0x316bb9(_0xdfbca2){const _0x48ab09=_0x579f16,_0x4c6770=/^(\+|\d)[0-9]{7,16}$/;return _0x4c6770[_0x48ab09('0x237c')](_0xdfbca2);}function _0x3199a8(){_0x2bd980['secret']=!![];}function _0x379046(){const _0x435937=_0x579f16;_0x2bd980['message'][_0x435937('0x18e5')]&&_0x50d3f0[_0x435937('0x1715')]({'secret':!![],'body':_0x2bd980[_0x435937('0x8c2')][_0x435937('0x18e5')]});}}const _0x557773=_0x57fcab;_0x53d7a4[_0x189033('0x14be')]=['$mdDialog',_0x189033('0x1d70'),'api',_0x189033('0xa98'),_0x189033('0xdd6'),_0x189033('0xc96'),_0x189033('0x1777')];function _0x53d7a4(_0x443d72,_0x1bfc9a,_0x280b86,_0x2d6cd5,_0xe72b6d,_0x5920a9,_0x45a878){const _0x285052=_0x189033,_0x302ddd=this;_0x302ddd['errors']=[],_0x302ddd['dispositions']=[],_0x302ddd[_0x285052('0xa98')]=angular['copy'](_0x2d6cd5);!_0x302ddd[_0x285052('0xa98')][_0x285052('0x43f')]&&(_0x302ddd[_0x285052('0xa98')][_0x285052('0x43f')]=null);_0x302ddd[_0x285052('0xdd6')]=_0xe72b6d,_0x302ddd[_0x285052('0x6d1')]=_0x302ddd[_0x285052('0xdd6')]+_0x285052('0x1896'),_0x302ddd[_0x285052('0x571')]=_0x302ddd['channel']+(_0x302ddd[_0x285052('0xdd6')]===_0x285052('0x24e')?_0x285052('0xe4c'):_0x285052('0xa78')),_0x302ddd['accountProperty']=_0x2e3ca0()[_0x285052('0x21ab')](_0x302ddd['channel'])+(_0x302ddd[_0x285052('0xdd6')]===_0x285052('0x24e')?_0x285052('0xe4c'):'Account')+'Id',_0x302ddd[_0x285052('0xb82')]=null,_0x302ddd['mandatoryDisposition']=![],_0x302ddd['mandatoryDispositionPause']='',_0x302ddd['wasUserInPause']=_0x5920a9[_0x285052('0x1431')]||_0x5920a9[_0x285052('0x1938')]||_0x5920a9[_0x285052('0x774')]||_0x5920a9['openchannelPause']||_0x5920a9[_0x285052('0x716')],_0x302ddd['onDispositionChange']=_0x1a9354,_0x302ddd['clearDispositionSelection']=_0x59248c,_0x302ddd[_0x285052('0x15c6')]=_0x24b58f,_0x302ddd[_0x285052('0xf82')]=_0x3f728f;function _0x358275(){const _0x4fb0ab=_0x285052;let _0x5420cc=[];const _0x402c01={'fields':_0x4fb0ab('0x2714'),'sort':'name','nolimit':!![]};_0x402c01[_0x302ddd['accountProperty']]=_0x2d6cd5[_0x302ddd[_0x4fb0ab('0x1d4c')]],_0x280b86[_0x302ddd['apiAccountRoute']]['get']({'id':_0x2d6cd5[_0x302ddd[_0x4fb0ab('0x1d4c')]]})[_0x4fb0ab('0xe53')]['then'](function(_0x260fe6){const _0x14e252=_0x4fb0ab;return _0x302ddd[_0x14e252('0x989')]=_0x260fe6[_0x14e252('0x989')],_0x302ddd['mandatoryDisposition']&&(_0x302ddd[_0x14e252('0x1ae5')]=_0x260fe6['mandatoryDispositionPause'][_0x14e252('0x60a')]),_0x280b86[_0x14e252('0x43f')][_0x14e252('0x1e6e')](_0x402c01)[_0x14e252('0xe53')];})[_0x4fb0ab('0x683')](function(_0x4bd6f3){const _0x5bc8b7=_0x4fb0ab;return _0x4bd6f3[_0x5bc8b7('0xf5d')]['length']&&(_0x5420cc=_0x2e3ca0()[_0x5bc8b7('0x746')](_0x5420cc,_0x4bd6f3[_0x5bc8b7('0xf5d')])),_0x280b86[_0x5bc8b7('0x43f')][_0x5bc8b7('0x1e6e')]({'MailAccountId':_0x5bc8b7('0x13c'),'FaxAccountId':_0x5bc8b7('0x13c'),'SmsAccountId':_0x5bc8b7('0x13c'),'WhatsappAccountId':'null','OpenchannelAccountId':_0x5bc8b7('0x13c'),'ChatWebsiteId':'null','ListId':_0x5bc8b7('0x13c')})[_0x5bc8b7('0xe53')];})[_0x4fb0ab('0x683')](function(_0x2efaa9){const _0x1fb982=_0x4fb0ab;_0x2efaa9['rows'][_0x1fb982('0x1564')]&&(_0x5420cc=_0x2e3ca0()[_0x1fb982('0x746')](_0x5420cc,_0x2efaa9[_0x1fb982('0xf5d')]));})[_0x4fb0ab('0x130a')](function(_0x2491de){console['error'](_0x2491de);})[_0x4fb0ab('0x2874')](function(){const _0x40e6a1=_0x4fb0ab;_0x302ddd[_0x40e6a1('0x191e')]=_0x2e3ca0()['orderBy'](_0x5420cc,[_0x40e6a1('0x60a')],[_0x40e6a1('0xe38')]),_0x1c5419();});}function _0x1c5419(){const _0x5220b8=_0x285052;_0x302ddd[_0x5220b8('0x989')]&&!_0x302ddd[_0x5220b8('0xa94')]&&_0x280b86[_0x5220b8('0xc96')][_0x5220b8('0xa4')]({'id':_0x5920a9['id'],'type':_0x302ddd[_0x5220b8('0x1ae5')]||_0x5220b8('0x55')})[_0x5220b8('0xe53')][_0x5220b8('0x683')](function(){})[_0x5220b8('0x130a')](function(_0x2e5887){const _0x1caca3=_0x5220b8;console[_0x1caca3('0x52a')](_0x2e5887);});}function _0x1a9354(_0x1cbd6d){const _0x59d770=_0x285052;if(_0x1cbd6d==='first'){_0x302ddd[_0x59d770('0x58')]=_0x302ddd[_0x59d770('0xb82')]?_0x2e3ca0()['some'](_0x302ddd['dispositions'],['ParentId',_0x302ddd[_0x59d770('0xb82')]['id']]):![];if(!_0x302ddd[_0x59d770('0xb82')])_0x302ddd[_0x59d770('0xc5d')]=undefined;}else _0x1cbd6d===_0x59d770('0x1f7b')&&(_0x302ddd[_0x59d770('0x4cf')]=_0x2e3ca0()[_0x59d770('0x7a2')](_0x302ddd[_0x59d770('0x191e')],[_0x59d770('0x1b62'),_0x302ddd[_0x59d770('0xc5d')]['id']]));}function _0x59248c(_0x1ed32c){const _0x3b593f=_0x285052;if(_0x1ed32c===_0x3b593f('0x1f7b'))_0x302ddd[_0x3b593f('0xc5d')]=undefined,_0x302ddd[_0x3b593f('0xde1')]=undefined;else _0x1ed32c===_0x3b593f('0x1d77')&&(_0x302ddd[_0x3b593f('0xde1')]=undefined);}function _0x24b58f(){const _0x270434=_0x285052;_0x302ddd[_0x270434('0x17f')]=[],_0x302ddd[_0x270434('0xa98')]['UserId']=_0x5920a9['id'],_0x302ddd[_0x270434('0xa98')][_0x270434('0xd8a')]=!![],_0x302ddd[_0x270434('0xa98')][_0x270434('0x1c21')]='agent',_0x302ddd['interaction'][_0x270434('0x43f')]=_0x302ddd[_0x270434('0xb82')]?_0x302ddd[_0x270434('0xb82')][_0x270434('0x60a')]:null,_0x302ddd[_0x270434('0xa98')][_0x270434('0x259d')]=_0x302ddd[_0x270434('0xc5d')]?_0x302ddd['secondLevelDisposition'][_0x270434('0x60a')]:undefined,_0x302ddd['interaction'][_0x270434('0x2481')]=_0x302ddd[_0x270434('0xde1')]?_0x302ddd[_0x270434('0xde1')][_0x270434('0x60a')]:undefined,_0x280b86[_0x302ddd[_0x270434('0x6d1')]]?_0x280b86[_0x302ddd[_0x270434('0x6d1')]][_0x270434('0x2480')](_0x2e3ca0()[_0x270434('0x24d0')](_0x302ddd[_0x270434('0xa98')],[_0x270434('0x1cd'),'FaxAccountId',_0x270434('0x1f4f'),_0x270434('0x1c35'),_0x270434('0x15a5'),_0x270434('0x1061'),_0x270434('0xd8a'),_0x270434('0x1c21'),_0x270434('0x43f'),_0x270434('0x259d'),_0x270434('0x2481'),'id',_0x270434('0x2203'),'UserId']))[_0x270434('0xe53')][_0x270434('0x683')](function(_0x16ad63){const _0x453889=_0x270434;_0x302ddd[_0x453889('0xa98')]=_0x16ad63,_0x302ddd[_0x453889('0xdd6')]===_0x453889('0x129f')&&_0x45a878[_0x453889('0x19d')](_0x302ddd['interaction']['id']),_0x1bfc9a[_0x453889('0x53')]({'title':_0x453889('0x2191'),'msg':_0x453889('0xeb3')});})['then'](function(){_0x3f728f(!![]);})[_0x270434('0x130a')](function(_0x45bf51){const _0x29b7b3=_0x270434;if(_0x45bf51[_0x29b7b3('0x5a5')]&&_0x45bf51[_0x29b7b3('0x5a5')]['errors']&&_0x45bf51[_0x29b7b3('0x5a5')][_0x29b7b3('0x17f')]['length']){_0x302ddd['errors']=_0x45bf51['data'][_0x29b7b3('0x17f')]||[{'message':_0x45bf51['toString'](),'type':'api.variable.update'}];for(let _0x384e2a=0x0;_0x384e2a<_0x45bf51['data'][_0x29b7b3('0x17f')][_0x29b7b3('0x1564')];_0x384e2a++){_0x1bfc9a[_0x29b7b3('0x52a')]({'title':_0x45bf51['data'][_0x29b7b3('0x17f')][_0x384e2a]['type'],'msg':_0x45bf51['data'][_0x29b7b3('0x17f')][_0x384e2a]['message']});}}else _0x1bfc9a['error']({'title':_0x45bf51[_0x29b7b3('0x13ee')]?_0x29b7b3('0x2168')+_0x45bf51[_0x29b7b3('0x13ee')]+_0x29b7b3('0xbf6')+_0x45bf51[_0x29b7b3('0x24a9')]:_0x29b7b3('0x4b'),'msg':_0x45bf51[_0x29b7b3('0x5a5')]?JSON['stringify'](_0x45bf51['data'][_0x29b7b3('0x8c2')]):_0x45bf51['toString']()});}):_0x3f728f(![]);}function _0x3f728f(_0x9a25d4){const _0x30d295=_0x285052;_0x443d72[_0x30d295('0x1715')](_0x9a25d4);}_0x358275();}const _0x2ab591=_0x53d7a4;_0x3fc011['$inject']=['$mdDialog',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xa98'),'channel',_0x189033('0x1ce6')];function _0x3fc011(_0xf33135,_0x30e886,_0x5bc7f3,_0x22adc5,_0x394315,_0x111a44){const _0x3492bb=_0x189033,_0x4d1202=this;_0x4d1202[_0x3492bb('0x17f')]=[],_0x4d1202[_0x3492bb('0x1ce6')]=_0x111a44,_0x4d1202[_0x3492bb('0xa98')]=angular[_0x3492bb('0x1a86')](_0x22adc5),_0x4d1202[_0x3492bb('0xa98')][_0x3492bb('0x198f')]=_0x2e3ca0()['map'](_0x4d1202[_0x3492bb('0xa98')][_0x3492bb('0x198f')],function(_0xc8db3b){const _0x8ffb42=_0x3492bb;return{'id':_0xc8db3b['id'],'name':_0xc8db3b[_0x8ffb42('0x60a')],'color':_0xc8db3b['color']};}),_0x4d1202[_0x3492bb('0xdd6')]=_0x394315,_0x4d1202[_0x3492bb('0x15a')]=!![],_0x4d1202[_0x3492bb('0x51c')]=_0x5927bd,_0x4d1202['closeDialog']=_0x471a85,_0x4d1202[_0x3492bb('0x6d1')]=_0x4d1202[_0x3492bb('0xdd6')]+_0x3492bb('0x1896');function _0x5927bd(){const _0x4bab40=_0x3492bb;_0x4d1202[_0x4bab40('0x17f')]=[];if(_0x5bc7f3[_0x4d1202[_0x4bab40('0x6d1')]])return _0x5bc7f3[_0x4d1202[_0x4bab40('0x6d1')]]['addTags']({'id':_0x4d1202[_0x4bab40('0xa98')]['id'],'ids':_0x2e3ca0()[_0x4bab40('0x386')](_0x4d1202['interaction'][_0x4bab40('0x198f')],'id')})[_0x4bab40('0xe53')][_0x4bab40('0x683')](function(){const _0x5623ce=_0x4bab40;_0x30e886[_0x5623ce('0x53')]({'title':'Interaction\x20properly\x20tagged!','msg':_0x5623ce('0x200e')}),_0x22adc5[_0x5623ce('0x198f')]=_0x4d1202['interaction']['Tags'],_0x471a85(!![]);})[_0x4bab40('0x130a')](function(_0x1ddf20){const _0x2730bb=_0x4bab40;if(_0x1ddf20[_0x2730bb('0x5a5')]&&_0x1ddf20[_0x2730bb('0x5a5')][_0x2730bb('0x17f')]&&_0x1ddf20[_0x2730bb('0x5a5')]['errors'][_0x2730bb('0x1564')])for(let _0x2b5748=0x0;_0x2b5748<_0x1ddf20[_0x2730bb('0x5a5')][_0x2730bb('0x17f')][_0x2730bb('0x1564')];_0x2b5748+=0x1){_0x30e886[_0x2730bb('0x52a')]({'title':_0x1ddf20[_0x2730bb('0x5a5')][_0x2730bb('0x17f')][_0x2b5748][_0x2730bb('0xcf0')],'msg':_0x1ddf20['data'][_0x2730bb('0x17f')][_0x2b5748][_0x2730bb('0x8c2')]});}else _0x30e886['error']({'title':_0x1ddf20[_0x2730bb('0x13ee')]?_0x2730bb('0x2168')+_0x1ddf20[_0x2730bb('0x13ee')]+_0x2730bb('0xbf6')+_0x1ddf20['statusText']:'api.variable.update','msg':_0x1ddf20[_0x2730bb('0x5a5')]?JSON[_0x2730bb('0x258a')](_0x1ddf20[_0x2730bb('0x5a5')][_0x2730bb('0x8c2')]):_0x1ddf20[_0x2730bb('0x1ff0')]()});});else _0x471a85(![]);}function _0x471a85(_0x25caf5){_0xf33135['hide'](_0x25caf5);}}const _0x115689=_0x3fc011;_0x1ac9cb[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x2f9'),'Auth',_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xdd6'),'message',_0x189033('0x1d2f')];function _0x1ac9cb(_0xd516d,_0x26f44e,_0x1f06e1,_0xb9accc,_0x1ea073,_0x4af895,_0x1fab33,_0x2d2cff){const _0x784cc0=_0x189033,_0x3c4e0=this;_0x3c4e0[_0x784cc0('0x11ed')]=_0x1f06e1['getCurrentUser'](),_0x3c4e0['channel']=_0x4af895[_0x784cc0('0x93a')](),_0x3c4e0[_0x784cc0('0x8c2')]=_0x1fab33,_0x3c4e0[_0x784cc0('0x1d2f')]=_0x2d2cff,_0x3c4e0[_0x784cc0('0x1011')]={'id':0x0,'type':_0x784cc0('0x660')},_0x3c4e0[_0x784cc0('0x2da')]={'count':0x0,'rows':[]},_0x3c4e0[_0x784cc0('0x756')]=_0x3c4e0[_0x784cc0('0x2da')],_0x3c4e0['queueMethod']=_0x3c4e0[_0x784cc0('0xdd6')]+_0x784cc0('0x1fa'),_0x3c4e0['queueNotifyMethod']=_0x3c4e0[_0x784cc0('0xdd6')]+_0x784cc0('0x19b'),_0x3c4e0[_0x784cc0('0x1122')]=_0x3c6a4c,_0x3c4e0[_0x784cc0('0xf82')]=_0x48758a,_0x3c4e0[_0x784cc0('0x12f3')]=_0x27c6b4,_0x3c4e0[_0x784cc0('0x12f3')]();function _0x27c6b4(){const _0x84398c=_0x784cc0;return _0xb9accc[_0x84398c('0xc96')][_0x84398c('0x1e6e')]({'fields':_0x84398c('0xa10'),'role':_0x84398c('0x2327'),'sort':_0x84398c('0x60a'),'nolimit':!![]})[_0x84398c('0xe53')]['then'](function(_0xae6515){const _0x1776cf=_0x84398c;return _0x3c4e0['agents']=_0xae6515||{'count':0x0,'rows':[]},_0xb9accc[_0x3c4e0[_0x1776cf('0x10f6')]]['get']({'fields':'id,name','sort':_0x1776cf('0x60a'),'nolimit':!![]})[_0x1776cf('0xe53')];})[_0x84398c('0x683')](function(_0x30cc7f){const _0x438dc7=_0x84398c;_0x3c4e0[_0x438dc7('0x2da')]=_0x30cc7f||{'count':0x0,'rows':[]};})[_0x84398c('0x130a')](function(_0x254df9){const _0x10ad30=_0x84398c;console[_0x10ad30('0x52a')](_0x254df9);});}function _0x48758a(_0x140a7f){const _0x38a558=_0x784cc0;_0xd516d[_0x38a558('0x1715')](_0x140a7f);}function _0x3c6a4c(){_0x48758a(!![]),_0x26f44e(function(){const _0x419e23=a0_0x4e0a;return _0xb9accc[_0x419e23('0x1b1b')][_0x3c4e0[_0x419e23('0x1011')]['type']===_0x419e23('0x2327')?_0x419e23('0x1d7d'):_0x3c4e0[_0x419e23('0x8fd')]]({'id':_0x3c4e0[_0x419e23('0x1011')]['id'],'messageId':_0x3c4e0[_0x419e23('0x8c2')]['id'],'channel':_0x3c4e0[_0x419e23('0xdd6')]})[_0x419e23('0xe53')][_0x419e23('0x683')](function(){const _0x3928c9=_0x419e23;_0x1ea073['success']({'title':_0x3928c9('0x949'),'msg':'Transfer\x20'+_0x3c4e0[_0x3928c9('0x1011')][_0x3928c9('0xcf0')]+_0x3928c9('0x27d9')});})['catch'](function(_0x4c6612){const _0x23add7=_0x419e23;if(_0x4c6612[_0x23add7('0x5a5')]&&_0x4c6612[_0x23add7('0x5a5')][_0x23add7('0x17f')]&&_0x4c6612['data'][_0x23add7('0x17f')][_0x23add7('0x1564')]){_0x3c4e0[_0x23add7('0x17f')]=_0x4c6612['data'][_0x23add7('0x17f')]||[{'message':_0x4c6612[_0x23add7('0x1ff0')](),'type':_0x23add7('0x1daf')}];for(let _0x57a90d=0x0;_0x57a90d<_0x4c6612[_0x23add7('0x5a5')][_0x23add7('0x17f')][_0x23add7('0x1564')];_0x57a90d++){_0x1ea073['error']({'title':_0x4c6612[_0x23add7('0x5a5')][_0x23add7('0x17f')][_0x57a90d][_0x23add7('0xcf0')],'msg':_0x4c6612[_0x23add7('0x5a5')]['errors'][_0x57a90d][_0x23add7('0x8c2')]});}}else _0x1ea073[_0x23add7('0x52a')]({'title':_0x4c6612[_0x23add7('0x13ee')]?_0x23add7('0x2168')+_0x4c6612[_0x23add7('0x13ee')]+_0x23add7('0xbf6')+_0x4c6612[_0x23add7('0x24a9')]:_0x23add7('0x1daf'),'msg':_0x4c6612[_0x23add7('0x5a5')]?JSON[_0x23add7('0x258a')](_0x4c6612[_0x23add7('0x5a5')][_0x23add7('0x8c2')]):_0x4c6612[_0x23add7('0x1ff0')]()});});},0x1388);}}const _0x446fe5=_0x1ac9cb;_0x2706d0['$inject']=['$scope','$q',_0x189033('0x1e48'),'mwFormResponseUtils',_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x1d08'),_0x189033('0x1b'),_0x189033('0x2f9'),_0x189033('0x1cc2')];function _0x2706d0(_0x517054,_0x5c894b,_0x2f70d1,_0xbf4e2c,_0x4405b0,_0x3d95a7,_0x324613,_0xf71852,_0x1da842,_0x2400fa,_0x55b0d9){const _0x1c36fe=_0x189033,_0x2989dd=this;_0x2989dd['formViewer']={},_0x2989dd['showResetButton']=!![],_0x2989dd[_0x1c36fe('0x1128')]=![],_0x2989dd[_0x1c36fe('0x262b')]=_0x55b0d9[_0x1c36fe('0x262b')](),_0x2989dd[_0x1c36fe('0x2685')]=_0x179a9c,_0x2989dd['openContact']=_0x7bb482,_0x2989dd[_0x1c36fe('0x703')]=_0x2972ee,_0x2989dd[_0x1c36fe('0x3a0')]=_0x9c4164,_0x2989dd[_0x1c36fe('0x19d9')]=_0x3cf12f,_0x2989dd[_0x1c36fe('0x1d0')]=_0x500d52,_0x2989dd[_0x1c36fe('0x17b9')]=_0x2c36d2,_0x2989dd['init']=_0x305ac0,_0x2989dd[_0x1c36fe('0x1fd2')]=function(_0x47402a){const _0x40528a=_0x1c36fe;if(_0x2989dd[_0x40528a('0x991')][_0x40528a('0x1302')]){const _0x2c252e=_0x2f70d1['confirm']()[_0x40528a('0xf28')](_0xf71852[_0x40528a('0x2728')]('JSCRIPTY.DO_YOU_WANT_TO_RESET_SESSION'))[_0x40528a('0xa6a')](_0xf71852['instant']('JSCRIPTY.ALL_SURVEY_DATA_WILL_BE_LOST'))[_0x40528a('0x1525')]('')[_0x40528a('0x1040')](_0x40528a('0x2c5'))['targetEvent'](_0x47402a)['ok'](_0xf71852[_0x40528a('0x2728')]('JSCRIPTY.YES'))[_0x40528a('0x19fb')](_0xf71852['instant'](_0x40528a('0x25f0')));_0x2f70d1[_0x40528a('0x1d4')](_0x2c252e)[_0x40528a('0x683')](function(){const _0x3f17f8=_0x40528a;_0x2989dd[_0x3f17f8('0x1128')]=![],_0x2989dd[_0x3f17f8('0x273a')]['currentPage']=undefined,_0x4e072b(),_0x2989dd[_0x3f17f8('0x991')][_0x3f17f8('0x1302')]();});}};function _0x4e072b(){const _0x20f9d2=_0x1c36fe;try{_0x517054['$parent'][_0x20f9d2('0x1cd5')][_0x20f9d2('0x1cd5')]['vm'][_0x20f9d2('0x1c14')]();}catch(_0x5708){_0x3d95a7['error']({'title':_0x20f9d2('0xf70'),'msg':_0x20f9d2('0x1ec9')});}}function _0x305ac0(_0x3d3187){const _0x1b6dbf=_0x1c36fe;_0x2989dd[_0x1b6dbf('0x1904')]=_0x3d3187;if(_0x2989dd['tab']){_0x2989dd[_0x1b6dbf('0x164f')]=_0x2989dd[_0x1b6dbf('0x1904')][_0x1b6dbf('0x164f')],_0x2989dd[_0x1b6dbf('0x1141')]=_0x2989dd[_0x1b6dbf('0x1904')][_0x1b6dbf('0x1991')],_0x2989dd[_0x1b6dbf('0xd06')]=_0x2989dd[_0x1b6dbf('0x1904')]['contact'],_0x2989dd['project']=_0x2989dd[_0x1b6dbf('0x1904')][_0x1b6dbf('0x273a')];if(_0x2989dd[_0x1b6dbf('0x273a')]){if(_0x2e3ca0()['isObjectLike'](_0x2989dd[_0x1b6dbf('0x273a')]['formData'])){}else _0x2989dd['isJsonString'](_0x2989dd[_0x1b6dbf('0x273a')][_0x1b6dbf('0x4f5')])?_0x2989dd['project']['formData']=JSON[_0x1b6dbf('0x1f34')](_0x2989dd[_0x1b6dbf('0x273a')][_0x1b6dbf('0x4f5')]):_0x2989dd[_0x1b6dbf('0x273a')][_0x1b6dbf('0x4f5')]=undefined;_0x2989dd[_0x1b6dbf('0x273a')][_0x1b6dbf('0x15de')]=_0x2989dd[_0x1b6dbf('0x273a')][_0x1b6dbf('0x15de')]||{},_0x2989dd['project'][_0x1b6dbf('0xa9')]!==undefined&&_0x2400fa(function(){const _0x1938ec=_0x1b6dbf;_0x1da842[_0x1938ec('0x5ed')](_0x1938ec('0x86d'),{'page':_0x2989dd[_0x1938ec('0x273a')]['currentPage']});}),_0x517054['$on'](_0x1b6dbf('0x1ee2'),function(_0x3bbc89,_0x99db58){const _0x6a2e16=_0x1b6dbf;if(_0x99db58['currentPage']){_0x2989dd[_0x6a2e16('0x273a')]['currentPage']=_0x99db58[_0x6a2e16('0xa9')]['number']-0x1,_0x4e072b();_0x2989dd[_0x6a2e16('0x273a')][_0x6a2e16('0x4bd')]&&(_0x99db58[_0x6a2e16('0xa9')][_0x6a2e16('0x121f')]>=0x1&&_0x99db58[_0x6a2e16('0xa9')][_0x6a2e16('0x121f')]<_0x2989dd[_0x6a2e16('0x273a')][_0x6a2e16('0x4f5')][_0x6a2e16('0x2589')]['length']?_0x2989dd['showIncompleteSubmitButton']=!![]:_0x2989dd['showIncompleteSubmitButton']=![]);if(_0x2989dd['project'][_0x6a2e16('0x4f5')]&&_0x2989dd['project']['formData'][_0x6a2e16('0x2589')])for(let _0x515940=0x0,_0x51587c=_0x2989dd['project'][_0x6a2e16('0x4f5')][_0x6a2e16('0x2589')][_0x6a2e16('0x1564')];_0x515940<_0x51587c;_0x515940++){if(_0x99db58['currentPage']['number']<_0x515940+0x1&&_0x2989dd[_0x6a2e16('0x273a')][_0x6a2e16('0x4f5')][_0x6a2e16('0x2589')][_0x515940][_0x6a2e16('0x1700')])for(let _0x56edb0=0x0,_0x4fbd3c=_0x2989dd['project'][_0x6a2e16('0x4f5')][_0x6a2e16('0x2589')][_0x515940][_0x6a2e16('0x1700')][_0x6a2e16('0x1564')];_0x56edb0<_0x4fbd3c;_0x56edb0++){_0x2989dd[_0x6a2e16('0x273a')]['formData'][_0x6a2e16('0x2589')][_0x515940]['elements'][_0x56edb0][_0x6a2e16('0xcf0')]===_0x6a2e16('0x1612')&&_0x2989dd[_0x6a2e16('0x273a')]['formData'][_0x6a2e16('0x2589')][_0x515940][_0x6a2e16('0x1700')][_0x56edb0][_0x6a2e16('0x1612')]&&delete _0x2989dd[_0x6a2e16('0x273a')][_0x6a2e16('0x15de')][_0x2989dd['project']['formData'][_0x6a2e16('0x2589')][_0x515940][_0x6a2e16('0x1700')][_0x56edb0][_0x6a2e16('0x1612')]['id']];}}}});}}}function _0x2972ee(_0x59f466){const _0x70ccb3=_0x1c36fe;if(_0x2e3ca0()[_0x70ccb3('0x8f2')](_0x59f466))return![];try{JSON[_0x70ccb3('0x1f34')](_0x59f466);}catch(_0x41677c){return![];}return!![];}function _0x7bb482(_0x12618f,_0x1be2c0){const _0x57c5da=_0x1c36fe;try{_0x517054[_0x57c5da('0x1cd5')][_0x57c5da('0x1cd5')][_0x57c5da('0x1cd5')]['vm'][_0x57c5da('0x15e')](_0x1be2c0);}catch(_0x25dcf4){_0x3d95a7[_0x57c5da('0x52a')]({'title':_0x57c5da('0xf3a'),'msg':_0x57c5da('0x1075')});}}function _0x3efa37(_0x43935e){const _0x3c3f67=_0x1c36fe,_0x599dd1=_0x5c894b[_0x3c3f67('0x448')]();return _0x2989dd[_0x3c3f67('0x273a')][_0x3c3f67('0x17da')]?_0x4405b0[_0x3c3f67('0xc96')][_0x3c3f67('0x1778')]({'id':_0x43935e['id']})['$promise'][_0x3c3f67('0x683')](function(){_0x599dd1['resolve']();})[_0x3c3f67('0x130a')](function(){const _0xabff57=_0x3c3f67;console[_0xabff57('0x1b2b')](_0xabff57('0xd7a')),_0x599dd1[_0xabff57('0xed7')]();}):_0x599dd1[_0x3c3f67('0xed7')](),_0x599dd1[_0x3c3f67('0x1883')];}function _0x323f10(_0x8522dd,_0x7d0e43){const _0x5853ef=_0x1c36fe,_0x360019=[],_0x15ea17=[],_0x2e5342=_0x324613[_0x5853ef('0x20b2')]();_0x3efa37(_0x2e5342)[_0x5853ef('0x683')](function(){const _0xc774f1=_0x5853ef;return _0x4405b0[_0xc774f1('0x1038')][_0xc774f1('0xb0a')]({'starttime':_0x2989dd[_0xc774f1('0x1141')],'membername':_0x2989dd[_0xc774f1('0x164f')]&&_0x2989dd[_0xc774f1('0x164f')][_0xc774f1('0x754')]?_0x2989dd[_0xc774f1('0x164f')][_0xc774f1('0x754')]:_0x2e5342[_0xc774f1('0x60a')],'calleridname':_0x2989dd[_0xc774f1('0x164f')]&&_0x2989dd[_0xc774f1('0x164f')][_0xc774f1('0x554')]?_0x2989dd['call'][_0xc774f1('0x554')]:undefined,'calleridnum':_0x2989dd[_0xc774f1('0x164f')]&&_0x2989dd[_0xc774f1('0x164f')][_0xc774f1('0x11a5')]?_0x2989dd[_0xc774f1('0x164f')]['calleridnum']:undefined,'queue':_0x2989dd[_0xc774f1('0x164f')]&&_0x2989dd['call'][_0xc774f1('0x660')]?_0x2989dd['call']['queue']:undefined,'uniqueid':_0x2989dd[_0xc774f1('0x164f')]&&_0x2989dd['call'][_0xc774f1('0x573')]?_0x2989dd[_0xc774f1('0x164f')][_0xc774f1('0x573')]:undefined,'VoiceQueueId':_0x2989dd['call']&&_0x2989dd[_0xc774f1('0x164f')][_0xc774f1('0x20fa')]?_0x2989dd[_0xc774f1('0x164f')]['xmd-voicequeueid']:undefined,'ProjectId':_0x2989dd[_0xc774f1('0x273a')]&&_0x2989dd[_0xc774f1('0x273a')]['id']?_0x2989dd[_0xc774f1('0x273a')]['id']:undefined,'projectname':_0x2989dd[_0xc774f1('0x273a')]&&_0x2989dd['project'][_0xc774f1('0x60a')]?_0x2989dd[_0xc774f1('0x273a')][_0xc774f1('0x60a')]:undefined,'ContactId':_0x2989dd[_0xc774f1('0xd06')]&&_0x2989dd[_0xc774f1('0xd06')]['id']?_0x2989dd['contact']['id']:undefined,'completed':_0x7d0e43})[_0xc774f1('0xe53')];})[_0x5853ef('0x683')](function(_0x4cbbb7){const _0x55a567=_0x5853ef;if(_0x4cbbb7){const _0x2289fd=_0x2989dd[_0x55a567('0x1d0')](),_0x8d5cc1=_0x2989dd['getResponseSheetRow'](),_0x37abac=_0x2989dd[_0x55a567('0x17b9')]();for(let _0x130ff4=0x0;_0x130ff4<_0x2289fd[_0x55a567('0x1564')];_0x130ff4+=0x1){if(!_0x2e3ca0()[_0x55a567('0x173f')](String(_0x8d5cc1[_0x130ff4]))){try{_0x360019['push'](_0x4405b0[_0x55a567('0x1015')][_0x55a567('0xb0a')]({'question':_0x2289fd[_0x130ff4],'answer':_0x37abac[_0x130ff4]['type']===_0x55a567('0x270e')?_0x1aaf93()(String(_0x8d5cc1[_0x130ff4]))[_0x55a567('0x26dd')](_0x55a567('0x2d')):_0x37abac[_0x130ff4]['type']===_0x55a567('0x147a')?_0x1aaf93()(String(_0x8d5cc1[_0x130ff4]))[_0x55a567('0x26dd')](_0x55a567('0x3ed')):String(_0x8d5cc1[_0x130ff4]),'questionId':_0x37abac[_0x130ff4]['id'],'membername':_0x2989dd[_0x55a567('0x164f')]&&_0x2989dd[_0x55a567('0x164f')]['membername']?_0x2989dd[_0x55a567('0x164f')][_0x55a567('0x754')]:_0x2e5342[_0x55a567('0x60a')],'calleridname':_0x2989dd[_0x55a567('0x164f')]&&_0x2989dd[_0x55a567('0x164f')]['calleridname']?_0x2989dd[_0x55a567('0x164f')]['calleridname']:undefined,'calleridnum':_0x2989dd[_0x55a567('0x164f')]&&_0x2989dd['call']['calleridnum']?_0x2989dd[_0x55a567('0x164f')][_0x55a567('0x11a5')]:undefined,'queue':_0x2989dd[_0x55a567('0x164f')]&&_0x2989dd['call'][_0x55a567('0x660')]?_0x2989dd[_0x55a567('0x164f')]['queue']:undefined,'uniqueid':_0x2989dd['call']&&_0x2989dd[_0x55a567('0x164f')][_0x55a567('0x573')]?_0x2989dd['call']['uniqueid']:undefined,'SessionId':_0x4cbbb7['id'],'ProjectId':_0x2989dd[_0x55a567('0x273a')]['id'],'projectname':_0x2989dd[_0x55a567('0x273a')][_0x55a567('0x60a')]}));}catch(_0x2d05c6){console[_0x55a567('0x52a')](_0x55a567('0x4a'),_0x2d05c6);}const _0x287208=String(_0x8d5cc1[_0x130ff4])['split'](';');for(let _0x59e03f=0x0;_0x59e03f<_0x287208['length'];_0x59e03f+=0x1){const _0x150355=_0x287208[_0x59e03f][_0x55a567('0x12ae')]();try{_0x15ea17[_0x55a567('0x1fd0')](_0x4405b0[_0x55a567('0x1c08')]['save']({'question':_0x2289fd[_0x130ff4],'questionId':_0x37abac[_0x130ff4]['id'],'answer':_0x37abac[_0x130ff4]['type']===_0x55a567('0x270e')?_0x1aaf93()(_0x150355)['format'](_0x55a567('0x2d')):_0x37abac[_0x130ff4]['type']===_0x55a567('0x147a')?_0x1aaf93()(_0x150355)[_0x55a567('0x26dd')](_0x55a567('0x3ed')):_0x150355,'membername':_0x2989dd[_0x55a567('0x164f')]&&_0x2989dd['call'][_0x55a567('0x754')]?_0x2989dd['call'][_0x55a567('0x754')]:_0x2e5342[_0x55a567('0x60a')],'calleridname':_0x2989dd[_0x55a567('0x164f')]&&_0x2989dd['call'][_0x55a567('0x554')]?_0x2989dd[_0x55a567('0x164f')][_0x55a567('0x554')]:undefined,'calleridnum':_0x2989dd['call']&&_0x2989dd[_0x55a567('0x164f')][_0x55a567('0x11a5')]?_0x2989dd[_0x55a567('0x164f')][_0x55a567('0x11a5')]:undefined,'queue':_0x2989dd['call']&&_0x2989dd[_0x55a567('0x164f')]['queue']?_0x2989dd[_0x55a567('0x164f')][_0x55a567('0x660')]:undefined,'uniqueid':_0x2989dd[_0x55a567('0x164f')]&&_0x2989dd[_0x55a567('0x164f')][_0x55a567('0x573')]?_0x2989dd['call']['uniqueid']:undefined,'SessionId':_0x4cbbb7['id'],'ProjectId':_0x2989dd[_0x55a567('0x273a')]['id'],'projectname':_0x2989dd['project'][_0x55a567('0x60a')]}));}catch(_0x5c833e){console[_0x55a567('0x52a')]('Unable\x20to\x20convert\x20answer',_0x5c833e);}}}}}return _0x5c894b['all'](_0x360019)[_0x55a567('0x683')](function(){const _0x3cbcfc=_0x55a567;return _0x5c894b[_0x3cbcfc('0x252c')](_0x15ea17)[_0x3cbcfc('0x683')](function(){return _0x4cbbb7;});});})[_0x5853ef('0x683')](function(_0x42d7da){const _0x1b0042=_0x5853ef;_0x42d7da?_0x8522dd[_0x1b0042('0xed7')](!![]):_0x8522dd[_0x1b0042('0xfae')]();})[_0x5853ef('0x130a')](function(_0x53f977){const _0x5d8fab=_0x5853ef;if(_0x53f977['data']&&_0x53f977[_0x5d8fab('0x5a5')][_0x5d8fab('0x17f')]&&_0x53f977['data'][_0x5d8fab('0x17f')][_0x5d8fab('0x1564')]){_0x2989dd[_0x5d8fab('0x17f')]=_0x53f977[_0x5d8fab('0x5a5')]['errors']||[{'message':_0x53f977[_0x5d8fab('0x1ff0')](),'type':'api.contact.save'}];for(let _0x59833f=0x0;_0x59833f<_0x53f977[_0x5d8fab('0x5a5')]['errors'][_0x5d8fab('0x1564')];_0x59833f+=0x1){_0x3d95a7['error']({'title':_0x53f977[_0x5d8fab('0x5a5')][_0x5d8fab('0x17f')][_0x59833f][_0x5d8fab('0xcf0')],'msg':_0x53f977[_0x5d8fab('0x5a5')]['errors'][_0x59833f][_0x5d8fab('0x8c2')]});}}else _0x3d95a7[_0x5d8fab('0x52a')]({'title':_0x53f977[_0x5d8fab('0x13ee')]?'API:'+_0x53f977[_0x5d8fab('0x13ee')]+_0x5d8fab('0xbf6')+_0x53f977[_0x5d8fab('0x24a9')]:_0x5d8fab('0xafc'),'msg':_0x53f977[_0x5d8fab('0x5a5')]?JSON[_0x5d8fab('0x258a')](_0x53f977[_0x5d8fab('0x5a5')][_0x5d8fab('0x8c2')]):_0x53f977['toString']()});_0x8522dd[_0x5d8fab('0xfae')]();});}function _0x521637(_0x52ea36){const _0xfb8da8=_0x1c36fe;try{_0x517054[_0xfb8da8('0x1cd5')][_0xfb8da8('0x1cd5')][_0xfb8da8('0x1cd5')]['vm'][_0xfb8da8('0x1cb8')](_0x52ea36);}catch(_0x8e42ce){_0x3d95a7[_0xfb8da8('0x52a')]({'title':_0xfb8da8('0x2624'),'msg':_0xfb8da8('0x21a0')});}}function _0x179a9c(_0x3a9523,_0x4c5fc4){const _0x1d03ff=_0x1c36fe,_0x582b0a=_0x5c894b[_0x1d03ff('0x448')]();if(_0x4c5fc4){const _0x24c0fe=_0x2f70d1['confirm']()[_0x1d03ff('0xf28')](_0x1d03ff('0x1585'))['textContent']('')[_0x1d03ff('0x1040')](_0x1d03ff('0x2c5'))[_0x1d03ff('0xe42')](_0x3a9523)['ok'](_0x1d03ff('0x13f7'))[_0x1d03ff('0x19fb')]('NO');_0x2f70d1[_0x1d03ff('0x1d4')](_0x24c0fe)[_0x1d03ff('0x683')](function(){_0x323f10(_0x582b0a,![]);},function(){_0x582b0a['resolve']();});}else _0x323f10(_0x582b0a,!![]);return _0x582b0a[_0x1d03ff('0x1883')][_0x1d03ff('0x683')](function(_0x1bd9a8){const _0x3d96cd=_0x1d03ff;_0x1bd9a8&&(_0x3d95a7[_0x3d96cd('0x53')]({'title':_0x3d96cd('0x1463'),'msg':_0x3d96cd('0x512')}),_0x521637(_0x2989dd['tab']));})[_0x1d03ff('0x130a')](function(){const _0x57dc59=_0x1d03ff;_0x3d95a7[_0x57dc59('0x52a')]({'title':_0x57dc59('0xa3b'),'msg':_0x57dc59('0x16ed')});});}function _0x9c4164(){const _0x3749d4=_0x1c36fe;return _0xbf4e2c[_0x3749d4('0x3a0')](_0x2989dd[_0x3749d4('0x273a')]['formData'],_0x2989dd[_0x3749d4('0x273a')][_0x3749d4('0x15de')],![]);}function _0x3cf12f(){const _0x2debf8=_0x1c36fe;return _0xbf4e2c[_0x2debf8('0x19d9')](_0x2989dd[_0x2debf8('0x273a')]['formData'],_0x2989dd[_0x2debf8('0x273a')]['responseData']);}function _0x500d52(){const _0x1dd53c=_0x1c36fe;return _0xbf4e2c[_0x1dd53c('0x1d0')](_0x2989dd[_0x1dd53c('0x273a')][_0x1dd53c('0x4f5')],![]);}function _0x2c36d2(){const _0x1f669e=_0x1c36fe;return _0xbf4e2c[_0x1f669e('0x17b9')](_0x2989dd[_0x1f669e('0x273a')][_0x1f669e('0x4f5')],_0x2989dd[_0x1f669e('0x273a')][_0x1f669e('0x15de')]);}}const _0x50b786=_0x2706d0;_0x8f12fc[_0x189033('0x14be')]=[_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1290'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x8f12fc(_0x1e1f86,_0x2304f0,_0x3e2886,_0x578f41,_0x58df93){const _0x554236=_0x189033,_0xa65947=this;_0xa65947['notification']=_0x3e2886,_0xa65947[_0x554236('0xc96')]=_0x58df93[_0x554236('0x20b2')]();function _0x226b4a(){return function(_0x31bd5f){const _0x5eab48=a0_0x4e0a;if(_0x31bd5f[_0x5eab48('0x13ee')]===0x194)_0x2304f0[_0x5eab48('0x2289')]({'title':_0x1e1f86[_0x5eab48('0x2728')](_0x5eab48('0x870')),'msg':_0x1e1f86[_0x5eab48('0x2728')](_0x5eab48('0xf12'))});else{if(_0x31bd5f[_0x5eab48('0x5a5')]&&_0x31bd5f[_0x5eab48('0x5a5')][_0x5eab48('0x17f')]&&_0x31bd5f[_0x5eab48('0x5a5')][_0x5eab48('0x17f')][_0x5eab48('0x1564')]){_0xa65947['errors']=_0x31bd5f[_0x5eab48('0x5a5')][_0x5eab48('0x17f')]||[{'message':_0x31bd5f['toString'](),'type':_0x5eab48('0x1bc4')}];for(let _0x5eb6d6=0x0;_0x5eb6d6<_0x31bd5f[_0x5eab48('0x5a5')][_0x5eab48('0x17f')][_0x5eab48('0x1564')];_0x5eb6d6+=0x1){_0x2304f0[_0x5eab48('0x52a')]({'title':_0x31bd5f[_0x5eab48('0x5a5')]['errors'][_0x5eb6d6][_0x5eab48('0xcf0')],'msg':_0x31bd5f[_0x5eab48('0x5a5')]['errors'][_0x5eb6d6][_0x5eab48('0x8c2')]});}}else _0x2304f0[_0x5eab48('0x52a')]({'title':_0x31bd5f[_0x5eab48('0x13ee')]?_0x5eab48('0x2168')+_0x31bd5f[_0x5eab48('0x13ee')]+'\x20-\x20'+_0x31bd5f[_0x5eab48('0x24a9')]:'api.openchannelMessage.accept','msg':_0x31bd5f[_0x5eab48('0x5a5')]?JSON['stringify'](_0x31bd5f[_0x5eab48('0x5a5')][_0x5eab48('0x8c2')]):_0x31bd5f[_0x5eab48('0x1ff0')]()});}};}function _0x307141(){const _0x4e3801=_0x554236;if(_0x578f41[_0xa65947[_0x4e3801('0x1290')][_0x4e3801('0xdd6')]+_0x4e3801('0x205e')])return _0x578f41[_0xa65947[_0x4e3801('0x1290')][_0x4e3801('0xdd6')]+_0x4e3801('0x205e')][_0x4e3801('0xd84')]({'id':_0xa65947['notification']['id'],'UserId':_0xa65947[_0x4e3801('0xc96')]['id'],'manual':!![]})[_0x4e3801('0xe53')][_0x4e3801('0x683')](function(){const _0x58d228=_0x4e3801;_0x2304f0[_0x58d228('0x53')]({'title':_0x58d228('0x739'),'msg':_0x58d228('0x8af')});})[_0x4e3801('0x130a')](_0x226b4a());else _0x2304f0['error']({'title':_0x4e3801('0x1697'),'msg':_0x4e3801('0x673')+_0xa65947[_0x4e3801('0x1290')][_0x4e3801('0xdd6')]+_0x4e3801('0x205e')});}function _0x27c90e(){const _0x35fe9e=_0x554236;if(_0x578f41[_0xa65947[_0x35fe9e('0x1290')][_0x35fe9e('0xdd6')]+'Message'])return _0x578f41[_0xa65947[_0x35fe9e('0x1290')][_0x35fe9e('0xdd6')]+_0x35fe9e('0x205e')][_0x35fe9e('0xfae')]({'id':_0xa65947['notification']['id'],'UserId':_0xa65947[_0x35fe9e('0xc96')]['id']})[_0x35fe9e('0xe53')][_0x35fe9e('0x683')](function(){const _0x3cf211=_0x35fe9e;_0x2304f0[_0x3cf211('0x53')]({'title':'Message\x20properly\x20rejected!','msg':_0x3cf211('0x1051')});})[_0x35fe9e('0x130a')](_0x226b4a());else _0x2304f0[_0x35fe9e('0x52a')]({'title':_0x35fe9e('0x1697'),'msg':_0x35fe9e('0x1795')+_0xa65947[_0x35fe9e('0x1290')]['channel']+_0x35fe9e('0x205e')});}_0xa65947['accept']=_0x307141,_0xa65947['reject']=_0x27c90e;}const _0x361889=_0x8f12fc;function _0x2d571d(){const _0x2f7470=_0x189033,_0x275895=this;function _0x3be43c(_0x5c5455){const _0x3219f2=a0_0x4e0a;_0x275895[_0x3219f2('0x1904')]=_0x5c5455,_0x275895['tab']&&(_0x275895[_0x3219f2('0x1904')][_0x3219f2('0x118c')]=!![],_0x275895[_0x3219f2('0x84')]=_0x275895[_0x3219f2('0x1904')][_0x3219f2('0x84')]);}_0x275895[_0x2f7470('0x12f3')]=_0x3be43c;}const _0x11ea21=_0x2d571d,_0x49369a=_0x180212['p']+_0x189033('0x4cc'),_0xfbc8e2=_0x180212['p']+_0x189033('0x235');_0x2206f7[_0x189033('0x14be')]=[_0x189033('0x1398')];function _0x2206f7(_0x1c0872){const _0x43d061=_0x189033;_0x1c0872[_0x43d061('0x2598')](_0x43d061('0x279d'),{'url':_0x43d061('0x1f14'),'views':{'content@app':{'templateProvider':[_0x43d061('0x8ea'),_0x43d061('0x1893'),_0x43d061('0xba1'),function(_0x3468b7,_0x295b8c,_0x57cbd1){const _0x48e699=_0x43d061;return _0x57cbd1['isAgent']()?_0x295b8c[_0x48e699('0x1e6b')](_0xfbc8e2,_0x3468b7):_0x295b8c[_0x48e699('0x1e6b')](_0x49369a,_0x3468b7);}],'controllerProvider':[_0x43d061('0xba1'),function(_0x54698c){const _0x4fee63=_0x43d061;return _0x54698c[_0x4fee63('0x50c')]()?'AgentDashboardGeneralController\x20as\x20vm':'UserDashboardGeneralController\x20as\x20vm';}]}},'resolve':{'globalUserLists':[_0x43d061('0x4b1'),_0x43d061('0xba1'),function(_0x419a38,_0x1a9948){const _0x569269=_0x43d061;return _0x419a38[_0x569269('0xed7')]('user@getLists',{'id':_0x1a9948[_0x569269('0x20b2')]()['id'],'sort':_0x569269('0x60a'),'nolimit':!![]});}],'globalLists':[_0x43d061('0x4b1'),function(_0x53c27a){const _0x32a845=_0x43d061;return _0x53c27a['resolve'](_0x32a845('0xa7b'),{'sort':_0x32a845('0x60a'),'nolimit':!![]});}],'globalTags':[_0x43d061('0x4b1'),function(_0x4aa9d7){const _0x1014aa=_0x43d061;return _0x4aa9d7[_0x1014aa('0xed7')](_0x1014aa('0xb55'),{'sort':_0x1014aa('0x60a'),'nolimit':!![]});}],'globalCompanies':['apiResolver',function(_0x3b27bb){const _0x291653=_0x43d061;return _0x3b27bb[_0x291653('0xed7')](_0x291653('0xdd0'),{'sort':_0x291653('0x60a'),'nolimit':!![]});}]},'authenticate':!![],'bodyClass':_0x43d061('0x1cd3')});}angular[_0x189033('0x1e26')](_0x189033('0x279d'),[_0x189033('0x669'),_0x189033('0x125f')])[_0x189033('0x272d')](_0x2206f7)[_0x189033('0x1da3')](_0x189033('0x23ac'),_0x14a4b2)['factory'](_0x189033('0x1777'),_0x28efab)['provider'](_0x189033('0x1c90'),_0x12ac4c)[_0x189033('0x22fe')](_0x189033('0x2066'),_0x1d4a34)['constant'](_0x189033('0x1c8d'),_0x3a97da)[_0x189033('0x1da3')](_0x189033('0x2539'),_0x19479b)['controller'](_0x189033('0x1501'),_0x2b96df)[_0x189033('0x1da3')](_0x189033('0x179a'),_0x1c887c)[_0x189033('0x1da3')](_0x189033('0x168f'),_0x451a85)['controller']('ContactSelectionController',_0x2124a0)[_0x189033('0x1da3')](_0x189033('0x14e3'),_0x1ab2ff)[_0x189033('0x1da3')](_0x189033('0x1072'),_0x514e21)[_0x189033('0x1da3')]('DisposeAbandonedCallDialogController',_0x123094)[_0x189033('0x1da3')](_0x189033('0xf3f'),_0x49e7f9)['controller'](_0x189033('0x5d4'),_0x4c42cd)['controller'](_0x189033('0x2017'),_0x58f845)[_0x189033('0x1da3')](_0x189033('0x8b6'),_0x4cd57c)[_0x189033('0x1da3')](_0x189033('0x7e3'),_0x37bb7b)['controller'](_0x189033('0x13e9'),_0x2db99e)['controller'](_0x189033('0x1c8b'),_0x5b4601)[_0x189033('0x1da3')](_0x189033('0x3'),_0x427e5c)[_0x189033('0x1da3')](_0x189033('0x1244'),_0x4ebea2)[_0x189033('0x1da3')]('AgentHomeDashboardMultiChannelOpenchannelController',_0x59f289)[_0x189033('0x1da3')](_0x189033('0x2715'),_0xdca5be)[_0x189033('0x1da3')](_0x189033('0x227a'),_0x516397)['controller'](_0x189033('0x1445'),_0x863307)['controller'](_0x189033('0x802'),_0x2e21b5)['controller'](_0x189033('0x1324'),_0x3442cf)['controller']('AgentHomeMyContactsController',_0x15ab48)['controller'](_0x189033('0x2616'),_0x2d5e81)['controller'](_0x189033('0x4d4'),_0x515533)[_0x189033('0x1da3')]('AgentHomeRecordingsController',_0x378a82)[_0x189033('0x1da3')](_0x189033('0x1149'),_0x1e83ca)[_0x189033('0x1da3')](_0x189033('0x141'),_0x3ee58b)[_0x189033('0x1da3')](_0x189033('0x1e76'),_0x35a88a)[_0x189033('0x1da3')]('AgentHomeVoiceDetailsController',_0x37a84f)[_0x189033('0x1da3')](_0x189033('0x60d'),_0x59d1ea)[_0x189033('0x1da3')](_0x189033('0x224e'),_0x397a88)[_0x189033('0x18ea')]('ngBindHtmlUnsafe',_0x4202f8)[_0x189033('0x25')](_0x189033('0x232a'),_0x8b64a1)['controller'](_0x189033('0x13ab'),_0x2944e3)[_0x189033('0x1f97')](_0x189033('0x1cb6'),_0x234375)[_0x189033('0x1da3')](_0x189033('0x10c2'),_0x5da36b)['controller']('ComposeMailInteractionDialogController',_0x1d196e)[_0x189033('0x1da3')](_0x189033('0xe4e'),_0x123003)['controller'](_0x189033('0x569'),_0x13e37f)[_0x189033('0x1da3')](_0x189033('0x1dec'),_0x557773)[_0x189033('0x1da3')](_0x189033('0x14a7'),_0x2ab591)['controller'](_0x189033('0xfdd'),_0x115689)['controller'](_0x189033('0x808'),_0x446fe5)['controller'](_0x189033('0x1068'),_0x50b786)[_0x189033('0x1da3')](_0x189033('0x20e'),_0x361889)['controller'](_0x189033('0x453'),_0x11ea21);const _0x26a28c=_0x180212['p']+_0x189033('0x1e19');_0x4d9a1b['$inject']=[_0x189033('0x938'),_0x189033('0x1b27'),_0x189033('0x7a5'),'api',_0x189033('0x1556'),_0x189033('0xba1'),'voiceQueues',_0x189033('0x2a'),_0x189033('0x22df')];function _0x4d9a1b(_0x373f1b,_0x59c480,_0x54e915,_0x52c1fc,_0x597315,_0x1d07f1,_0x161ee4,_0x3477d3,_0x577da5){const _0x53616b=_0x189033,_0x555990=this;_0x555990[_0x53616b('0x11ed')]=_0x1d07f1[_0x53616b('0x20b2')](),_0x555990['userProfile']=_0x3477d3,_0x555990['userProfileSection']=_0x577da5&&_0x577da5['count']==0x1?_0x577da5['rows'][0x0]:null,_0x555990[_0x53616b('0x1134')]=_0x1d07f1[_0x53616b('0x142a')](_0x555990[_0x53616b('0x22df')]?_0x555990[_0x53616b('0x22df')][_0x53616b('0x1134')]:null),_0x555990[_0x53616b('0x22a5')]={},_0x555990[_0x53616b('0x426')]=_0x161ee4&&_0x161ee4[_0x53616b('0x50d')]?_0x161ee4:{'count':0x0,'rows':[]},_0x555990[_0x53616b('0x1890')]=_0x161ee4&&_0x161ee4[_0x53616b('0x50d')]?_0x2e3ca0()['map'](_0x161ee4[_0x53616b('0xf5d')],'id'):[],_0x555990[_0x53616b('0x115c')]=_0x59c480(function(){},0x3e8),_0x555990['onChangeVoiceQueues']=_0x42736c,_0x555990[_0x53616b('0x13c2')]=_0x2786fe,_0x597315[_0x53616b('0x5a3')](_0x53616b('0x1df'),_0x290202),_0x52c1fc[_0x53616b('0x1a6')]['get']({'id':_0x373f1b[_0x53616b('0x7f2')]['id']})[_0x53616b('0xe53')][_0x53616b('0x683')](function(_0x3ce414){const _0x75f0c=_0x53616b;if(_0x3ce414)return _0x555990['customDashboard']=_0x3ce414,_0x555990[_0x75f0c('0x22a5')][_0x75f0c('0x1ef8')]=[],_0x555990['customDashboard'][_0x75f0c('0x5f9')]=!![],_0x555990[_0x75f0c('0x22a5')][_0x75f0c('0x199f')]={'enabled':![]},_0x555990['customDashboard'][_0x75f0c('0x174c')]={'enabled':![]},_0x52c1fc['dashboard'][_0x75f0c('0x25c7')]({'id':_0x555990['customDashboard']['id']})['$promise'];})[_0x53616b('0x683')](function(_0x1aee55){const _0x4c6b74=_0x53616b;if(_0x1aee55&&_0x1aee55[_0x4c6b74('0x50d')]&&_0x1aee55[_0x4c6b74('0xf5d')])for(let _0x5461d8=0x0;_0x5461d8<_0x1aee55['rows'][_0x4c6b74('0x1564')];_0x5461d8+=0x1){_0x1aee55['rows'][_0x5461d8][_0x4c6b74('0x2698')]=_0x4c6b74('0x1b3a')+_0x1aee55[_0x4c6b74('0xf5d')][_0x5461d8][_0x4c6b74('0xcf0')]+'/ms-widget-engine.'+_0x1aee55[_0x4c6b74('0xf5d')][_0x5461d8][_0x4c6b74('0xcf0')]+_0x4c6b74('0x1f6'),_0x1aee55['rows'][_0x5461d8][_0x4c6b74('0x426')]=_0x555990[_0x4c6b74('0x426')],_0x1aee55[_0x4c6b74('0xf5d')][_0x5461d8]['voiceQueuesSelected']=_0x555990[_0x4c6b74('0x1890')],_0x555990[_0x4c6b74('0x22a5')]['widgets'][_0x4c6b74('0x1fd0')](_0x1aee55[_0x4c6b74('0xf5d')][_0x5461d8]);}})['catch'](function(){const _0xc892f4=_0x53616b;_0x555990[_0xc892f4('0x22a5')]=undefined;});function _0x290202(_0x369e45){const _0x3502e4=_0x53616b,_0x132684=_0x2e3ca0()[_0x3502e4('0x1c07')](_0x555990[_0x3502e4('0x426')][_0x3502e4('0xf5d')],{'id':_0x369e45['id']});_0x132684&&_0x2e3ca0()[_0x3502e4('0xf22')](_0x132684,_0x2e3ca0()[_0x3502e4('0x24d0')](_0x369e45,_0x2e3ca0()['keys'](_0x132684)));}function _0x42736c(){const _0x3a0aad=_0x53616b;for(let _0x976100=0x0;_0x976100<_0x555990[_0x3a0aad('0x22a5')]['widgets']['length'];_0x976100+=0x1){_0x555990[_0x3a0aad('0x22a5')][_0x3a0aad('0x1ef8')][_0x976100][_0x3a0aad('0x1890')]=_0x555990[_0x3a0aad('0x1890')];}}function _0x2786fe(){const _0x116d16=_0x53616b;_0x373f1b['go'](_0x116d16('0x1d33'),{'id':_0x555990[_0x116d16('0x22a5')]['id'],'tab':0x1});}_0x54e915[_0x53616b('0x26a2')](_0x53616b('0x4b8'),function(){const _0x472c60=_0x53616b;_0x597315[_0x472c60('0x1b9e')](_0x472c60('0x1df')),_0x555990[_0x472c60('0x115c')]&&_0x59c480['cancel'](_0x555990[_0x472c60('0x115c')]);});}const _0x145ebe=_0x4d9a1b;_0x1fd3d6['$inject']=['$stateProvider'];function _0x1fd3d6(_0x1e5e01){const _0x2c2ddc=_0x189033;_0x1e5e01[_0x2c2ddc('0x2598')](_0x2c2ddc('0x1273'),{'url':'/custom/:id','views':{'content@app':{'templateUrl':_0x26a28c,'controller':'DashboardCustomController\x20as\x20vm'}},'resolve':{'voiceQueues':[_0x2c2ddc('0x4b1'),_0x2c2ddc('0xba1'),function(_0x9c99fe,_0x4d745b){const _0x45daec=_0x2c2ddc;let _0x21b493;const _0x388840=_0x4d745b[_0x45daec('0xca1')](_0x45daec('0x20c2'))?_0x9c99fe[_0x45daec('0xed7')]('voiceQueue@get',{'fields':_0x45daec('0xa10'),'nolimit':!![]}):_0x9c99fe[_0x45daec('0xed7')](_0x45daec('0x191b'),{'id':_0x4d745b[_0x45daec('0x20b2')]()[_0x45daec('0x2f')],'section':_0x45daec('0x88d'),'mergeResources':!![],'fields':_0x45daec('0xa10'),'channel':_0x45daec('0xcf2'),'nolimit':!![]});return _0x388840['then'](function(_0x4371a1){return _0x21b493=_0x4371a1,_0x9c99fe['resolve']('rpc@getVoiceQueues');})[_0x45daec('0x683')](function(_0x5784c6){const _0x3af51b=_0x45daec;if(_0x5784c6)for(let _0x512c8d=0x0,_0xcf931d;_0x512c8d<_0x5784c6[_0x3af51b('0xf5d')][_0x3af51b('0x1564')];_0x512c8d+=0x1){_0xcf931d=_0x2e3ca0()[_0x3af51b('0x1c07')](_0x21b493[_0x3af51b('0xf5d')],{'id':_0x5784c6[_0x3af51b('0xf5d')][_0x512c8d]['id']}),_0xcf931d&&_0x2e3ca0()[_0x3af51b('0xf22')](_0xcf931d,_0x2e3ca0()[_0x3af51b('0x24d0')](_0x5784c6[_0x3af51b('0xf5d')][_0x512c8d],['waiting',_0x3af51b('0x2263'),_0x3af51b('0x7a4'),_0x3af51b('0x1e47'),_0x3af51b('0x2278'),_0x3af51b('0x15aa')]));}return _0x21b493;});}],'userProfile':['apiResolver',_0x2c2ddc('0xba1'),function(_0x5450ad,_0xb9b8a5){const _0x50b162=_0x2c2ddc;return _0x5450ad[_0x50b162('0xed7')](_0x50b162('0x1464'),{'fields':_0x50b162('0x16f'),'id':_0xb9b8a5[_0x50b162('0x20b2')]()[_0x50b162('0x2f')]});}],'userProfileSection':[_0x2c2ddc('0x4b1'),'Auth',function(_0x1d9690,_0x322b2d){const _0x549717=_0x2c2ddc;return _0x1d9690['resolve'](_0x549717('0x360'),{'fields':_0x549717('0x1f47'),'userProfileId':_0x322b2d[_0x549717('0x20b2')]()['userProfileId'],'sectionId':0x64});}]},'authenticate':!![],'bodyClass':'dashboards'});}angular[_0x189033('0x1e26')](_0x189033('0x1273'),[])['config'](_0x1fd3d6)[_0x189033('0x1da3')](_0x189033('0x8d9'),_0x145ebe),_0x15725b['$inject']=[_0x189033('0x1398'),'$translatePartialLoaderProvider'];function _0x15725b(_0x50f200,_0x36d447){const _0x2b4067=_0x189033;_0x50f200[_0x2b4067('0x2598')](_0x2b4067('0x1803'),{'abstract':!![],'url':_0x2b4067('0x1881')}),_0x36d447[_0x2b4067('0x7d2')](_0x2b4067('0x1180'));}angular[_0x189033('0x1e26')](_0x189033('0x1803'),['ngCsv','ngPassword',_0x189033('0x2290'),'flow',_0x189033('0x25fc'),'ckeditor','ng-sortable',_0x189033('0x2609'),_0x189033('0x273d'),_0x189033('0x76'),_0x189033('0x516'),_0x189033('0x7fa'),'mwFormUtils',_0x189033('0x3b5'),_0x189033('0x153a'),_0x189033('0x1447'),_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da'),_0x189033('0x279d'),_0x189033('0x1273')])[_0x189033('0x272d')](_0x15725b);const _0x31c120=_0x180212['p']+_0x189033('0x920'),_0x2f4050=_0x180212['p']+_0x189033('0xcaa');_0xd928d6['$inject']=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x756'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),'Auth','license','setting'];function _0xd928d6(_0x2ae008,_0x9a8bd0,_0xd80f91,_0x53ba97,_0x3d5b58,_0x58f784,_0x5d269f,_0x199299,_0x2d98a6,_0x5b4d95,_0x523237,_0x366ad0,_0x196f28,_0x3c2e71,_0x18b455,_0x5bc263,_0x510101){const _0x1df425=_0x189033,_0x58a3b1=this;_0x58a3b1[_0x1df425('0xace')]=_0x5bc263,_0x58a3b1['setting']=_0x510101,_0x58a3b1[_0x1df425('0x11ed')]=_0x18b455[_0x1df425('0x20b2')](),_0x58a3b1[_0x1df425('0x756')]=_0x2d98a6||{'count':0x0,'rows':[]},_0x58a3b1[_0x1df425('0x2a')]=_0x5b4d95,_0x58a3b1[_0x1df425('0x22df')]=_0x523237&&_0x523237['count']==0x1?_0x523237['rows'][0x0]:null,_0x58a3b1[_0x1df425('0x1134')]=_0x18b455[_0x1df425('0x142a')](_0x58a3b1[_0x1df425('0x22df')]?_0x58a3b1[_0x1df425('0x22df')]['crudPermissions']:null),_0x58a3b1['table']='agents',_0x58a3b1[_0x1df425('0x247')]='',_0x58a3b1[_0x1df425('0x1ce2')]=null,_0x58a3b1['selectedAgents']=[],_0x58a3b1[_0x1df425('0x23a2')]={'fields':_0x1df425('0xf3b'),'role':_0x1df425('0x2327'),'sort':_0x1df425('0xc36'),'limit':0xa,'page':0x1},_0x58a3b1[_0x1df425('0x28c')]=_0x2e3ca0()[_0x1df425('0x24db')]([{'option':_0x1df425('0x263e'),'value':'0'},{'option':'External','value':'1'},{'option':_0x1df425('0x246d'),'value':'2'}],function(_0x1e170e){const _0x30fe06=_0x1df425;return _0x2e3ca0()[_0x30fe06('0x1725')](_0x1e170e[_0x30fe06('0x1c6b')],new RegExp('\x27','g'),'');}),_0x58a3b1[_0x1df425('0xfb8')]=_0x2e3ca0()[_0x1df425('0x24db')]([{'option':_0x1df425('0x41d'),'value':_0x1df425('0x1c7')},{'option':'tcp','value':_0x1df425('0xf6')},{'option':'ws','value':_0x1df425('0x117e'),'ngIf':'vm.agent.showWebBar\x20==\x201'},{'option':_0x1df425('0x2615'),'value':_0x1df425('0x26fa'),'ngIf':'vm.agent.showWebBar\x20==\x201'},{'option':_0x1df425('0x171f'),'value':_0x1df425('0x9ee'),'ngIf':_0x1df425('0x44f')}],function(_0x4f1185){const _0x324a6b=_0x1df425;return _0x2e3ca0()[_0x324a6b('0x1725')](_0x4f1185[_0x324a6b('0x1c6b')],new RegExp('\x27','g'),'');}),_0x58a3b1[_0x1df425('0x14c3')]=_0x2e3ca0()['keyBy']([{'option':_0x1df425('0x1025'),'value':'\x27force_rport\x27'},{'option':'comedia','value':'\x27comedia\x27'},{'option':'yes','value':_0x1df425('0x2036')},{'option':'no','value':_0x1df425('0x23ca')},{'option':'never','value':_0x1df425('0xd77')},{'option':_0x1df425('0x20ed'),'value':_0x1df425('0x23a6')}],function(_0x330ea3){const _0x35996f=_0x1df425;return _0x2e3ca0()[_0x35996f('0x1725')](_0x330ea3['value'],new RegExp('\x27','g'),'');}),_0x58a3b1['arraytype']=_0x2e3ca0()[_0x1df425('0x24db')]([{'option':_0x1df425('0x214d'),'value':_0x1df425('0x4e9')},{'option':_0x1df425('0x1dad'),'value':'\x27user\x27'},{'option':_0x1df425('0x2245'),'value':_0x1df425('0xca')}],function(_0x5258b9){const _0x296758=_0x1df425;return _0x2e3ca0()[_0x296758('0x1725')](_0x5258b9[_0x296758('0x1c6b')],new RegExp('\x27','g'),'');}),_0x58a3b1[_0x1df425('0x2673')]=_0x2e3ca0()[_0x1df425('0x24db')]([{'option':_0x1df425('0x5f4'),'value':_0x1df425('0x576')},{'option':_0x1df425('0xdf6'),'value':'\x27alaw\x27'},{'option':'gsm','value':_0x1df425('0x1755')},{'option':'g722','value':_0x1df425('0x226b')},{'option':_0x1df425('0x14bf'),'value':'\x27g729\x27'},{'option':'opus','value':_0x1df425('0x2873')},{'option':_0x1df425('0x6e6'),'value':_0x1df425('0x483')}],function(_0x39e6e8){const _0x36eac6=_0x1df425;return _0x2e3ca0()[_0x36eac6('0x1725')](_0x39e6e8[_0x36eac6('0x1c6b')],new RegExp('\x27','g'),'');}),_0x58a3b1['arrayvideosupport']=_0x2e3ca0()[_0x1df425('0x24db')]([{'option':'Yes','value':_0x1df425('0x2036')},{'option':'No','value':_0x1df425('0x23ca')},{'option':_0x1df425('0x1023'),'value':'\x27always\x27'}],function(_0x3bafea){const _0x54ed70=_0x1df425;return _0x2e3ca0()[_0x54ed70('0x1725')](_0x3bafea['value'],new RegExp('\x27','g'),'');}),_0x58a3b1[_0x1df425('0x147')]=_0x2e3ca0()[_0x1df425('0x24db')]([{'option':_0x1df425('0x3f9'),'value':'\x27\x27'},{'option':_0x1df425('0x1d2a'),'value':'\x27wav\x27'},{'option':_0x1df425('0x178'),'value':_0x1df425('0xa45')},{'option':_0x1df425('0x1ac0'),'value':_0x1df425('0x1755')}],function(_0x4eb36e){const _0x4874de=_0x1df425;return _0x2e3ca0()[_0x4874de('0x1725')](_0x4eb36e[_0x4874de('0x1c6b')],new RegExp('\x27','g'),'');}),_0x58a3b1[_0x1df425('0xc63')]=_0x387188,_0x58a3b1[_0x1df425('0xe0e')]=_0x591a07,_0x58a3b1['deleteconfirm']=_0x1b613d,_0x58a3b1[_0x1df425('0x53')]=_0xfdb71c,_0x58a3b1['getAgents']=_0x3dc2e8,_0x58a3b1[_0x1df425('0x14e8')]=_0x2ee2e3,_0x58a3b1[_0x1df425('0x2764')]=_0x81920e,_0x58a3b1[_0x1df425('0x101b')]=_0x4ef1d0,_0x58a3b1[_0x1df425('0x4a6')]=_0x1cbd76,_0x58a3b1[_0x1df425('0x909')]=_0x34aec2,_0x58a3b1[_0x1df425('0x1e31')]=_0x56f518;function _0x387188(_0x3a1b7d){const _0x1aa9f7=_0x1df425;_0xd80f91['go']('app.staff.agents.edit',{'id':_0x3a1b7d['id'],'agent':_0x3a1b7d,'crudPermissions':_0x58a3b1[_0x1aa9f7('0x1134')]});}function _0x591a07(_0x3ac288,_0x5857f9){const _0x3f2a0c=_0x1df425;_0x3d5b58[_0x3f2a0c('0x1d4')]({'controller':_0x3f2a0c('0x250e'),'controllerAs':'vm','templateUrl':_0x31c120,'parent':angular[_0x3f2a0c('0x1fcc')](_0x58f784[_0x3f2a0c('0x18e5')]),'targetEvent':_0x5857f9,'clickOutsideToClose':!![],'locals':{'agent':_0x3ac288,'agents':_0x58a3b1[_0x3f2a0c('0x756')]?_0x58a3b1['agents'][_0x3f2a0c('0xf5d')]:[],'crudPermissions':_0x58a3b1['crudPermissions']}});}function _0x1b613d(_0x10c765,_0x5eeb79){const _0x151840=_0x1df425,_0x760c79=_0x3d5b58[_0x151840('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()['startCase'](_0x151840('0x2327'))+'?')[_0x151840('0x26e3')](_0x151840('0xed5')+(_0x10c765[_0x151840('0x60a')]||'agent')+''+_0x151840('0x1ee7'))[_0x151840('0x1040')](_0x151840('0x518'))[_0x151840('0xe42')](_0x5eeb79)['ok']('OK')[_0x151840('0x19fb')](_0x151840('0x16b8'));_0x3d5b58[_0x151840('0x1d4')](_0x760c79)[_0x151840('0x683')](function(){_0x81920e(_0x10c765);},function(){const _0x1ad304=_0x151840;console[_0x1ad304('0x1b2b')](_0x1ad304('0x16b8'));});}let _0x462fcf=!![],_0x396bc6=0x1;_0x2ae008[_0x1df425('0x186d')](_0x1df425('0x1e1d'),function(_0x5059aa,_0xa8f7be){const _0x7a08ac=_0x1df425;_0x462fcf?_0x5d269f(function(){_0x462fcf=![];}):(!_0xa8f7be&&(_0x396bc6=_0x58a3b1[_0x7a08ac('0x23a2')][_0x7a08ac('0xdf8')]),_0x5059aa!==_0xa8f7be&&(_0x58a3b1[_0x7a08ac('0x23a2')][_0x7a08ac('0xdf8')]=0x1),!_0x5059aa&&(_0x58a3b1[_0x7a08ac('0x23a2')][_0x7a08ac('0xdf8')]=_0x396bc6),_0x58a3b1['getAgents']());});function _0xfdb71c(_0x4266b1){const _0x395b56=_0x1df425;_0x58a3b1[_0x395b56('0x756')]=_0x4266b1||{'count':0x0,'rows':[]};}function _0x3dc2e8(){const _0x28acd5=_0x1df425;_0x58a3b1['query'][_0x28acd5('0x1cc8')]=(_0x58a3b1[_0x28acd5('0x23a2')][_0x28acd5('0xdf8')]-0x1)*_0x58a3b1[_0x28acd5('0x23a2')]['limit'],_0x18b455[_0x28acd5('0xca1')]('admin')?_0x58a3b1['promise']=_0x366ad0[_0x28acd5('0xc96')][_0x28acd5('0x1e6e')](_0x58a3b1['query'],_0xfdb71c)[_0x28acd5('0xe53')]:(_0x58a3b1[_0x28acd5('0x23a2')]['id']=_0x58a3b1['userProfile']['id'],_0x58a3b1['query'][_0x28acd5('0x1aa')]=_0x28acd5('0x1bc0'),_0x58a3b1['promise']=_0x366ad0['userProfile']['getResources'](_0x58a3b1[_0x28acd5('0x23a2')],_0xfdb71c)[_0x28acd5('0xe53')]);}function _0x2ee2e3(_0x27a232,_0x1b7d45){const _0xc54a57=_0x1df425;_0x3d5b58['show']({'controller':_0xc54a57('0x1289'),'controllerAs':'vm','templateUrl':_0x2f4050,'parent':angular['element'](_0x58f784[_0xc54a57('0x18e5')]),'targetEvent':_0x27a232,'clickOutsideToClose':!![],'locals':{'agent':_0x1b7d45,'agents':_0x58a3b1[_0xc54a57('0x756')][_0xc54a57('0xf5d')],'license':_0x58a3b1[_0xc54a57('0xace')],'setting':_0x58a3b1[_0xc54a57('0x260a')],'crudPermissions':_0x58a3b1['crudPermissions']}});}function _0x81920e(_0x12fdad){const _0x4fcf7b=_0x1df425;_0x366ad0[_0x4fcf7b('0xc96')][_0x4fcf7b('0xd7e')]({'id':_0x12fdad['id']})[_0x4fcf7b('0xe53')][_0x4fcf7b('0x683')](function(){const _0x295927=_0x4fcf7b;_0x2e3ca0()[_0x295927('0x3ec')](_0x58a3b1['agents'][_0x295927('0xf5d')],{'id':_0x12fdad['id']}),_0x58a3b1['agents'][_0x295927('0x50d')]-=0x1,!_0x58a3b1['agents']['rows']['length']&&_0x58a3b1[_0x295927('0x8e7')](),_0x3c2e71[_0x295927('0x53')]({'title':_0x2e3ca0()[_0x295927('0x1e03')](_0x295927('0x62c'))+_0x295927('0xbfc'),'msg':_0x12fdad[_0x295927('0x60a')]?_0x12fdad[_0x295927('0x60a')]+_0x295927('0x194d'):''});})[_0x4fcf7b('0x130a')](function(_0x59e13e){const _0x5d3d2d=_0x4fcf7b;if(_0x59e13e[_0x5d3d2d('0x5a5')]&&_0x59e13e[_0x5d3d2d('0x5a5')][_0x5d3d2d('0x17f')]&&_0x59e13e['data'][_0x5d3d2d('0x17f')]['length']){_0x58a3b1['errors']=_0x59e13e[_0x5d3d2d('0x5a5')][_0x5d3d2d('0x17f')]||[{'message':_0x59e13e['toString'](),'type':_0x5d3d2d('0x2484')}];for(let _0x3001a2=0x0;_0x3001a2<_0x59e13e[_0x5d3d2d('0x5a5')][_0x5d3d2d('0x17f')][_0x5d3d2d('0x1564')];_0x3001a2++){_0x3c2e71[_0x5d3d2d('0x52a')]({'title':_0x59e13e[_0x5d3d2d('0x5a5')][_0x5d3d2d('0x17f')][_0x3001a2][_0x5d3d2d('0xcf0')],'msg':_0x59e13e[_0x5d3d2d('0x5a5')][_0x5d3d2d('0x17f')][_0x3001a2]['message']});}}else _0x3c2e71[_0x5d3d2d('0x52a')]({'title':_0x59e13e[_0x5d3d2d('0x13ee')]?_0x5d3d2d('0x2168')+_0x59e13e[_0x5d3d2d('0x13ee')]+_0x5d3d2d('0xbf6')+_0x59e13e[_0x5d3d2d('0x24a9')]:_0x5d3d2d('0x2484'),'msg':_0x59e13e[_0x5d3d2d('0x5a5')]?JSON[_0x5d3d2d('0x258a')](_0x59e13e[_0x5d3d2d('0x5a5')][_0x5d3d2d('0x8c2')]):_0x59e13e['message']||_0x59e13e['toString']()});});}function _0x4ef1d0(){const _0x13c9d7=_0x1df425,_0x5e602b=angular[_0x13c9d7('0x1a86')](_0x58a3b1[_0x13c9d7('0x1317')]);return _0x58a3b1[_0x13c9d7('0x1317')]=[],_0x5e602b;}function _0x1cbd76(_0x38d0ef){const _0x54055b=_0x1df425,_0x16ffea=_0x3d5b58['confirm']()[_0x54055b('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20agents?')[_0x54055b('0x26e3')](_0x54055b('0xed5')+_0x58a3b1[_0x54055b('0x1317')][_0x54055b('0x1564')]+_0x54055b('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x54055b('0xa32'))[_0x54055b('0xe42')](_0x38d0ef)['ok']('OK')[_0x54055b('0x19fb')](_0x54055b('0x16b8'));_0x3d5b58[_0x54055b('0x1d4')](_0x16ffea)['then'](function(){const _0x52530f=_0x54055b;_0x58a3b1['selectedAgents'][_0x52530f('0x1299')](function(_0x572ce7){_0x81920e(_0x572ce7);}),_0x58a3b1[_0x52530f('0x1317')]=[];});}function _0x34aec2(){_0x58a3b1['selectedAgents']=[];}function _0x56f518(){const _0x127494=_0x1df425;_0x58a3b1[_0x127494('0x1317')]=_0x58a3b1[_0x127494('0x756')][_0x127494('0xf5d')];}}const _0x2b7a7c=_0xd928d6;_0x968c1b['$inject']=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x756'),'agent','api',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x968c1b(_0x3b7935,_0x36b197,_0x2940e9,_0x2a61f1,_0x19931a,_0x4825a8,_0x4e1df6,_0x42a4bf,_0x545236,_0xd0a3af,_0x2ce8dd,_0x2f1d5f,_0x1131cb,_0x15a42f){const _0x95331e=_0x189033,_0x2ec506=this;_0x2ec506['currentUser']=_0x2ce8dd['getCurrentUser'](),_0x2ec506['errors']=[],_0x2ec506[_0x95331e('0x260a')]=_0x1131cb,_0x2ec506[_0x95331e('0xace')]=_0x2f1d5f,_0x2ec506[_0x95331e('0x1134')]=_0x15a42f,_0x2ec506['hasModulePermissions']={},_0x2ec506['passwordPattern']=_0x2ec506['setting']&&_0x2ec506[_0x95331e('0x260a')][_0x95331e('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2ec506[_0x95331e('0xf28')]=_0x95331e('0xd9d'),_0x2ec506[_0x95331e('0x2327')]=angular[_0x95331e('0x1a86')](_0x545236),_0x2ec506[_0x95331e('0x756')]=_0x42a4bf,_0x2ec506['newAgent']=![];!_0x2ec506['agent']&&(_0x2ec506[_0x95331e('0x2327')]={'role':_0x95331e('0x2327'),'showWebBar':'0','autointernal':!![],'type':'friend','context':_0x95331e('0x1365'),'phoneBarRemoteControl':!![],'phoneBarRemoteControlPort':0x26a0,'allowmessenger':!![]},_0x2ec506[_0x95331e('0xf28')]=_0x95331e('0x139f'),_0x2ec506[_0x95331e('0x1fa5')]=!![]);_0x2ec506[_0x95331e('0x1839')]=_0x2011d4,_0x2ec506[_0x95331e('0x1c57')]=_0x184bbc,_0x2ec506[_0x95331e('0x2764')]=_0xca5977,_0x2ec506[_0x95331e('0x16b3')]=_0x3fcd42,_0x2ec506[_0x95331e('0xf82')]=_0x2d3cbc;function _0x2011d4(){const _0x1f2a4c=_0x95331e;_0x2ec506['errors']=[],_0xd0a3af[_0x1f2a4c('0xc96')][_0x1f2a4c('0xb0a')](_0x2ec506[_0x1f2a4c('0x2327')])[_0x1f2a4c('0xe53')]['then'](function(_0x405c1a){const _0x3f1b58=_0x1f2a4c;_0x2ec506[_0x3f1b58('0x756')][_0x3f1b58('0x1167')](_0x405c1a['toJSON']()),_0x4e1df6[_0x3f1b58('0x53')]({'title':_0x3f1b58('0xc08'),'msg':_0x2ec506['agent'][_0x3f1b58('0x60a')]?_0x2ec506[_0x3f1b58('0x2327')][_0x3f1b58('0x60a')]+'\x20has\x20been\x20created!':''}),_0x2d3cbc(_0x405c1a);})[_0x1f2a4c('0x130a')](function(_0x5909d8){const _0x1e684b=_0x1f2a4c;if(_0x5909d8[_0x1e684b('0x5a5')]&&_0x5909d8['data']['errors']&&_0x5909d8[_0x1e684b('0x5a5')]['errors'][_0x1e684b('0x1564')]){_0x2ec506['errors']=_0x5909d8[_0x1e684b('0x5a5')][_0x1e684b('0x17f')]||[{'message':_0x5909d8[_0x1e684b('0x1ff0')](),'type':'api.user.save'}];for(let _0x523871=0x0;_0x523871<_0x5909d8[_0x1e684b('0x5a5')][_0x1e684b('0x17f')]['length'];_0x523871+=0x1){_0x4e1df6[_0x1e684b('0x52a')]({'title':_0x5909d8[_0x1e684b('0x5a5')][_0x1e684b('0x17f')][_0x523871][_0x1e684b('0xcf0')],'msg':_0x5909d8[_0x1e684b('0x5a5')]['errors'][_0x523871]['message']});}}else _0x4e1df6['error']({'title':_0x5909d8['status']?_0x1e684b('0x2168')+_0x5909d8[_0x1e684b('0x13ee')]+_0x1e684b('0xbf6')+_0x5909d8['statusText']:'api.user.save','msg':_0x5909d8[_0x1e684b('0x5a5')]?JSON[_0x1e684b('0x258a')](_0x5909d8[_0x1e684b('0x5a5')][_0x1e684b('0x8c2')]):_0x5909d8[_0x1e684b('0x1ff0')]()});});}function _0x184bbc(){const _0x1b828d=_0x95331e;_0x2ec506['errors']=[],_0xd0a3af[_0x1b828d('0xc96')][_0x1b828d('0x2480')]({'id':_0x2ec506['agent']['id']},_0x2ec506[_0x1b828d('0x2327')])[_0x1b828d('0xe53')][_0x1b828d('0x683')](function(_0x3fa39e){const _0x3f0f4a=_0x1b828d,_0x5bfd25=_0x2e3ca0()[_0x3f0f4a('0x1c07')](_0x2ec506['agents'],{'id':_0x3fa39e['id']});_0x5bfd25&&_0x2e3ca0()[_0x3f0f4a('0xf22')](_0x5bfd25,_0x2e3ca0()['pick'](_0x3fa39e[_0x3f0f4a('0x24e1')](),_0x2e3ca0()['keys'](_0x5bfd25))),_0x4e1df6['success']({'title':_0x3f0f4a('0x12b4'),'msg':_0x2ec506[_0x3f0f4a('0x2327')]['name']?_0x2ec506[_0x3f0f4a('0x2327')][_0x3f0f4a('0x60a')]+_0x3f0f4a('0xf59'):''}),_0x2d3cbc(_0x3fa39e);})[_0x1b828d('0x130a')](function(_0x3c6902){const _0x1b532d=_0x1b828d;if(_0x3c6902[_0x1b532d('0x5a5')]&&_0x3c6902[_0x1b532d('0x5a5')][_0x1b532d('0x17f')]&&_0x3c6902[_0x1b532d('0x5a5')][_0x1b532d('0x17f')][_0x1b532d('0x1564')]){_0x2ec506['errors']=_0x3c6902[_0x1b532d('0x5a5')][_0x1b532d('0x17f')]||[{'message':_0x3c6902[_0x1b532d('0x1ff0')](),'type':_0x1b532d('0x162b')}];for(let _0x5e7f0d=0x0;_0x5e7f0d<_0x3c6902['data'][_0x1b532d('0x17f')][_0x1b532d('0x1564')];_0x5e7f0d++){_0x4e1df6[_0x1b532d('0x52a')]({'title':_0x3c6902[_0x1b532d('0x5a5')][_0x1b532d('0x17f')][_0x5e7f0d]['type'],'msg':_0x3c6902[_0x1b532d('0x5a5')][_0x1b532d('0x17f')][_0x5e7f0d][_0x1b532d('0x8c2')]});}}else _0x4e1df6[_0x1b532d('0x52a')]({'title':_0x3c6902[_0x1b532d('0x13ee')]?'API:'+_0x3c6902[_0x1b532d('0x13ee')]+_0x1b532d('0xbf6')+_0x3c6902[_0x1b532d('0x24a9')]:_0x1b532d('0x162b'),'msg':_0x3c6902[_0x1b532d('0x5a5')]?JSON[_0x1b532d('0x258a')](_0x3c6902['data'][_0x1b532d('0x8c2')]):_0x3c6902[_0x1b532d('0x1ff0')]()});});}function _0xca5977(_0x51f521){const _0x41b85a=_0x95331e;_0x2ec506[_0x41b85a('0x17f')]=[];const _0x3a5a71=_0x2a61f1[_0x41b85a('0x1c6f')]()[_0x41b85a('0xf28')]('Are\x20you\x20sure?')[_0x41b85a('0xa6a')]('The\x20agent\x20will\x20be\x20deleted.')[_0x41b85a('0x1040')](_0x41b85a('0x1bd8'))['ok']('Delete')[_0x41b85a('0x19fb')]('Cancel')[_0x41b85a('0xe42')](_0x51f521);_0x2a61f1[_0x41b85a('0x1d4')](_0x3a5a71)[_0x41b85a('0x683')](function(){const _0x3f04b1=_0x41b85a;_0xd0a3af[_0x3f04b1('0xc96')][_0x3f04b1('0xd7e')]({'id':_0x2ec506[_0x3f04b1('0x2327')]['id']})['$promise'][_0x3f04b1('0x683')](function(){const _0x38fb94=_0x3f04b1;_0x2e3ca0()[_0x38fb94('0x3ec')](_0x2ec506['agents'],{'id':_0x2ec506[_0x38fb94('0x2327')]['id']}),_0x4e1df6[_0x38fb94('0x53')]({'title':_0x38fb94('0x685'),'msg':(_0x2ec506[_0x38fb94('0x2327')][_0x38fb94('0x60a')]||'agent')+_0x38fb94('0x194d')}),_0x2d3cbc(_0x2ec506[_0x38fb94('0x2327')]);})[_0x3f04b1('0x130a')](function(_0x508b36){const _0x445bc9=_0x3f04b1;if(_0x508b36['data']&&_0x508b36[_0x445bc9('0x5a5')][_0x445bc9('0x17f')]&&_0x508b36[_0x445bc9('0x5a5')][_0x445bc9('0x17f')][_0x445bc9('0x1564')]){_0x2ec506['errors']=_0x508b36['data'][_0x445bc9('0x17f')]||[{'message':_0x508b36['toString'](),'type':_0x445bc9('0x11d0')}];for(let _0x1cd7c6=0x0;_0x1cd7c6<_0x508b36['data']['errors']['length'];_0x1cd7c6++){_0x4e1df6[_0x445bc9('0x52a')]({'title':_0x508b36['data']['errors'][_0x1cd7c6][_0x445bc9('0xcf0')],'msg':_0x508b36[_0x445bc9('0x5a5')][_0x445bc9('0x17f')][_0x1cd7c6][_0x445bc9('0x8c2')]});}}else _0x4e1df6[_0x445bc9('0x52a')]({'title':_0x508b36[_0x445bc9('0x13ee')]?_0x445bc9('0x2168')+_0x508b36[_0x445bc9('0x13ee')]+_0x445bc9('0xbf6')+_0x508b36[_0x445bc9('0x24a9')]:'api.user.delete','msg':_0x508b36[_0x445bc9('0x5a5')]?JSON[_0x445bc9('0x258a')](_0x508b36['data'][_0x445bc9('0x8c2')]):_0x508b36['message']||_0x508b36[_0x445bc9('0x1ff0')]()});});},function(){});}function _0x3fcd42(_0x53d728){return _0x53d728===null?undefined:new Date(_0x53d728);}function _0x2d3cbc(_0x29108){const _0x1cdab7=_0x95331e;_0x2a61f1[_0x1cdab7('0x1715')](_0x29108);}}const _0x2f6477=_0x968c1b;_0x249a4e[_0x189033('0x14be')]=['$cookies','toasty'];function _0x249a4e(_0x102f82,_0x53b187){const _0x47c427=_0x189033,_0x3805bf=this,_0x42940b=0x8,_0x36888e=_0x42940b*0x400*0x400;_0x3805bf[_0x47c427('0x2327')]={},_0x3805bf[_0x47c427('0x1134')],_0x3805bf[_0x47c427('0x8f')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x36888e,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x3805bf[_0x47c427('0x1fa6')]={'flow':{}},_0x3805bf[_0x47c427('0xfbe')]=![],_0x3805bf[_0x47c427('0x1aad')]=_0x485eae,_0x3805bf[_0x47c427('0xa03')]=_0x411a9e,_0x3805bf['fileSuccess']=_0x38aa70,_0x3805bf[_0x47c427('0x12f3')]=_0x571b19;function _0x571b19(_0x1b09b3,_0x2afe94){const _0x20e1f5=_0x47c427;_0x3805bf['agent']=angular[_0x20e1f5('0x1a86')](_0x1b09b3),_0x3805bf[_0x20e1f5('0x1134')]=typeof _0x2afe94!==_0x20e1f5('0x1867')?_0x2afe94:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3805bf['ngFlowOptions'][_0x20e1f5('0x568')]=_0x20e1f5('0xce')+_0x3805bf['agent']['id']+_0x20e1f5('0x9f3'),_0x3805bf[_0x20e1f5('0x2327')][_0x20e1f5('0x2668')]=[];}function _0x485eae(_0x1274b3){const _0xc1d687=_0x47c427,_0x48ee9c=[_0xc1d687('0x21ec'),_0xc1d687('0x159c')];if(!_0x2e3ca0()[_0xc1d687('0x2292')](_0x48ee9c,_0x1274b3[_0xc1d687('0x1197')]()))return _0x53b187[_0xc1d687('0x52a')]({'title':_0xc1d687('0xa00')+_0x1274b3[_0xc1d687('0x1197')](),'msg':_0xc1d687('0x2560')+_0x48ee9c[_0xc1d687('0x1630')]()}),![];if(_0x1274b3['size']>_0x36888e)return _0x53b187[_0xc1d687('0x52a')]({'title':_0xc1d687('0x19a2'),'msg':_0xc1d687('0x1622')+_0x42940b+'MB'}),![];const _0x3dfbd3={'id':_0x1274b3['uniqueIdentifier'],'file':_0x1274b3,'type':_0xc1d687('0x132')};return _0x3805bf[_0xc1d687('0x2327')]['images']['unshift'](_0x3dfbd3),!![];}function _0x411a9e(){const _0x30e9ce=_0x47c427;_0x3805bf[_0x30e9ce('0x1fa6')][_0x30e9ce('0x190a')]['opts'][_0x30e9ce('0xb7d')]={'X-Requested-With':_0x30e9ce('0xbfd'),'Authorization':_0x30e9ce('0x189e')+_0x102f82[_0x30e9ce('0x1e6e')](_0x30e9ce('0x555'))},_0x3805bf[_0x30e9ce('0x1fa6')]['flow'][_0x30e9ce('0xa03')]();}function _0x38aa70(_0x1db17b){const _0x4cb520=_0x47c427;angular[_0x4cb520('0x1299')](_0x3805bf['agent']['images'],function(_0x46b1cb){const _0x4a402e=_0x4cb520;if(_0x46b1cb['id']===_0x1db17b[_0x4a402e('0x2379')]){const _0x2e206f=new FileReader();_0x2e206f[_0x4a402e('0x23e1')](_0x46b1cb['file'][_0x4a402e('0x21dd')]),_0x2e206f[_0x4a402e('0x43b')]=function(_0x3ce8e3){const _0x4fd1a7=_0x4a402e;_0x46b1cb[_0x4fd1a7('0x1284')]=_0x3ce8e3[_0x4fd1a7('0x568')][_0x4fd1a7('0x7c9')];},_0x46b1cb[_0x4a402e('0xcf0')]=_0x4a402e('0x1110');}});}}const _0x2d94f9=_0x249a4e;_0x531415['$inject']=['$scope',_0x189033('0x1e48'),_0x189033('0x1d70'),'api',_0x189033('0x2327'),'setting',_0x189033('0xba1')];function _0x531415(_0x5d804d,_0x6d9dbc,_0x1ff870,_0x478eb1,_0x4cdcf5,_0x24934d,_0x1c5d41){const _0x334d98=_0x189033,_0x19d52d=this;_0x19d52d['currentUser']=_0x1c5d41[_0x334d98('0x20b2')](),_0x19d52d[_0x334d98('0x17f')]=[],_0x19d52d[_0x334d98('0x260a')]=_0x24934d,_0x19d52d['passwordPattern']=_0x19d52d[_0x334d98('0x260a')][_0x334d98('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x19d52d[_0x334d98('0x2327')]=_0x4cdcf5,_0x19d52d['password']='',_0x19d52d[_0x334d98('0x17fb')]='',_0x19d52d[_0x334d98('0x1808')]=_0xf9e941,_0x19d52d[_0x334d98('0xf82')]=_0x52cd1f,_0x5d804d[_0x334d98('0x186d')](_0x334d98('0x1567'),function(_0x1231fd){const _0x3706c0=_0x334d98;!_0x2e3ca0()[_0x3706c0('0x8f2')](_0x19d52d[_0x3706c0('0x17fb')])&&(_0x1231fd===_0x19d52d[_0x3706c0('0x17fb')]?_0x5d804d[_0x3706c0('0x288a')]['password']['$setValidity'](_0x3706c0('0x20b9'),![]):_0x5d804d[_0x3706c0('0x288a')]['password']['$setValidity'](_0x3706c0('0x20b9'),!![]));});function _0xf9e941(){const _0x23ab06=_0x334d98;_0x19d52d[_0x23ab06('0x17f')]=[];const _0x37dbe={'id':_0x19d52d[_0x23ab06('0x2327')]['id'],'newPassword':_0x19d52d['password']};_0x19d52d['currentUser']['id']==_0x19d52d[_0x23ab06('0x2327')]['id']&&(_0x37dbe[_0x23ab06('0x17fb')]=_0x19d52d[_0x23ab06('0x17fb')]),_0x478eb1[_0x23ab06('0xc96')]['changePassword'](_0x37dbe)[_0x23ab06('0xe53')][_0x23ab06('0x683')](function(){const _0x26f9d4=_0x23ab06;_0x1ff870[_0x26f9d4('0x53')]({'title':_0x26f9d4('0x866')}),_0x52cd1f();})[_0x23ab06('0x130a')](function(_0x15fa47){const _0x4406d6=_0x23ab06;_0x1ff870[_0x4406d6('0x52a')]({'title':_0x15fa47[_0x4406d6('0x13ee')]?_0x4406d6('0x2168')+_0x15fa47[_0x4406d6('0x13ee')]+_0x4406d6('0xbf6')+_0x15fa47[_0x4406d6('0x24a9')]:'api.agent.save','msg':_0x15fa47[_0x4406d6('0x5a5')]?JSON[_0x4406d6('0x258a')](_0x15fa47[_0x4406d6('0x5a5')][_0x4406d6('0x8c2')]):_0x15fa47[_0x4406d6('0x1ff0')]()}),_0x19d52d[_0x4406d6('0x17f')]=_0x15fa47['data'][_0x4406d6('0x17f')]||[{'message':_0x15fa47[_0x4406d6('0x1ff0')](),'type':_0x4406d6('0x1753')}];});}function _0x52cd1f(){const _0x9a6312=_0x334d98;_0x6d9dbc[_0x9a6312('0x1715')]();}}const _0x427d38=_0x531415;_0x435f88[_0x189033('0x14be')]=['$document',_0x189033('0x1e48'),_0x189033('0x56b'),_0x189033('0x2066'),_0x189033('0x1d70')];function _0x435f88(_0x1bcacb,_0x487357,_0x900ee5,_0x1f7cc3,_0x3d20d1){const _0x4c07d4=_0x189033,_0x973bce=this;_0x973bce[_0x4c07d4('0x2327')]={},_0x973bce[_0x4c07d4('0x21ad')]=_0x1f7cc3['getNavigation'](),_0x973bce[_0x4c07d4('0x1134')],_0x973bce[_0x4c07d4('0x12f3')]=_0x58f854,_0x973bce[_0x4c07d4('0xaef')]=_0x157542;function _0x58f854(_0x3aa29c,_0x76ddb8){const _0x129d56=_0x4c07d4;_0x973bce[_0x129d56('0x2327')]=_0x3aa29c,_0x973bce[_0x129d56('0x1134')]=typeof _0x76ddb8!==_0x129d56('0x1867')?_0x76ddb8:{'readOnly':!![],'canEdit':![],'canDelete':![]};}function _0x157542(_0x2973ef,_0x4ecc41){const _0x4cb24a=_0x4c07d4,_0x31325f=_0x4ecc41||_0x2973ef;if(_0x31325f[_0x4cb24a('0x1333')]){if(_0x4ecc41)_0x4ecc41[_0x4cb24a('0x1333')]=!![],_0x973bce[_0x4cb24a('0x2327')]['permissions']['push'](_0x4ecc41['id']);else for(let _0x4ff88b=0x0;_0x4ff88b<_0x2973ef['children'][_0x4cb24a('0x1564')];_0x4ff88b++){_0x2973ef[_0x4cb24a('0x62')][_0x4ff88b][_0x4cb24a('0x1333')]=!![],_0x973bce[_0x4cb24a('0x2327')][_0x4cb24a('0x924')]['push'](_0x2973ef[_0x4cb24a('0x62')][_0x4ff88b]['id']);}_0x2973ef[_0x4cb24a('0x1333')]=!![],_0x973bce['agent'][_0x4cb24a('0x924')][_0x4cb24a('0x1fd0')](_0x2973ef['id']);}else{if(_0x4ecc41)_0x4ecc41['enabled']=![],_0x2e3ca0()[_0x4cb24a('0x3ec')](_0x973bce[_0x4cb24a('0x2327')][_0x4cb24a('0x924')],function(_0x5a6e3b){return _0x4ecc41['id']===_0x5a6e3b;}),_0x2e3ca0()['filter'](_0x2973ef['children'],{'enabled':![]})['length']===_0x2973ef[_0x4cb24a('0x62')][_0x4cb24a('0x1564')]&&(_0x2973ef[_0x4cb24a('0x1333')]=![],_0x2e3ca0()[_0x4cb24a('0x3ec')](_0x973bce[_0x4cb24a('0x2327')][_0x4cb24a('0x924')],function(_0x12ef14){return _0x2973ef['id']===_0x12ef14;}));else{_0x2973ef[_0x4cb24a('0x1333')]=![],_0x2e3ca0()[_0x4cb24a('0x3ec')](_0x973bce[_0x4cb24a('0x2327')][_0x4cb24a('0x924')],function(_0x21b4dc){return _0x2973ef['id']===_0x21b4dc;});for(let _0x49640b=0x0;_0x49640b<_0x2973ef[_0x4cb24a('0x62')][_0x4cb24a('0x1564')];_0x49640b++){_0x2973ef[_0x4cb24a('0x62')][_0x49640b]['enabled']=![],_0x2e3ca0()[_0x4cb24a('0x3ec')](_0x973bce['agent'][_0x4cb24a('0x924')],function(_0x1b5cf5){const _0x39a7fb=_0x4cb24a;return _0x2973ef[_0x39a7fb('0x62')][_0x49640b]['id']===_0x1b5cf5;});}}}return _0x900ee5[_0x4cb24a('0xc96')][_0x4cb24a('0x2480')]({'id':_0x973bce[_0x4cb24a('0x2327')]['id'],'permissions':_0x2e3ca0()[_0x4cb24a('0xbf7')](_0x973bce[_0x4cb24a('0x2327')][_0x4cb24a('0x924')])})['$promise']['then'](function(){const _0x459bcf=_0x4cb24a;_0x3d20d1[_0x459bcf('0x53')]({'title':_0x459bcf('0x1209'),'msg':_0x973bce[_0x459bcf('0x2327')][_0x459bcf('0x60a')]?_0x973bce['agent'][_0x459bcf('0x60a')]+_0x459bcf('0x96c'):''});})[_0x4cb24a('0x130a')](function(_0x1301ef){const _0x251716=_0x4cb24a;console[_0x251716('0x52a')](_0x1301ef);});}}const _0x3509a5=_0x435f88;_0x18b4a6[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'api',_0x189033('0x2327'),'channel',_0x189033('0x2655'),_0x189033('0x1d08'),'Auth',_0x189033('0x1134')];function _0x18b4a6(_0x966b5f,_0x56f530,_0x407528,_0x1acf7e,_0x44999b,_0x1f19e0,_0x259319,_0x1c8258,_0x4067de,_0x20ec8e){const _0x3b0ee0=_0x189033,_0x10e889=this;_0x10e889[_0x3b0ee0('0x11ed')]=_0x4067de[_0x3b0ee0('0x20b2')](),_0x10e889[_0x3b0ee0('0x2327')]=_0x44999b,_0x10e889[_0x3b0ee0('0x1134')]=_0x20ec8e,_0x10e889[_0x3b0ee0('0x1e2a')]=0x0,_0x10e889['channel']=_0x1f19e0,_0x10e889[_0x3b0ee0('0x2655')]=_0x259319,_0x10e889[_0x3b0ee0('0x213')]=_0x10e889[_0x3b0ee0('0xdd6')]+_0x3b0ee0('0x1fa'),_0x10e889[_0x3b0ee0('0xf28')]=_0x1c8258[_0x3b0ee0('0x2728')](_0x3b0ee0('0x25c2')+_0x10e889[_0x3b0ee0('0xdd6')]['toUpperCase']()+'_'+_0x10e889['direction'][_0x3b0ee0('0x80')]()),_0x10e889[_0x3b0ee0('0x1996')]=[],_0x10e889[_0x3b0ee0('0x1c47')]=[],_0x10e889['selectedItems']=[],_0x10e889[_0x3b0ee0('0x125e')]=[],_0x10e889[_0x3b0ee0('0x23a7')]=[],_0x10e889[_0x3b0ee0('0x2106')]=![],_0x10e889[_0x3b0ee0('0x169f')]={'readOnly':!_0x10e889['crudPermissions'][_0x3b0ee0('0x1978')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x3b0ee0('0x60a'),'line1':_0x3b0ee0('0x60a'),'line2':_0x3b0ee0('0xcf0'),'line3':_0x10e889[_0x3b0ee0('0xdd6')]==='voice'?_0x3b0ee0('0x1e2a'):'','labelAll':_0x1c8258[_0x3b0ee0('0x2728')](_0x3b0ee0('0x120')+_0x10e889[_0x3b0ee0('0xdd6')]['toUpperCase']()+'_'+_0x10e889[_0x3b0ee0('0x2655')][_0x3b0ee0('0x80')]()),'labelSelected':_0x1c8258[_0x3b0ee0('0x2728')]('STAFF.SELECTED_QUEUES_'+_0x10e889['channel']['toUpperCase']()+'_'+_0x10e889[_0x3b0ee0('0x2655')][_0x3b0ee0('0x80')]()),'transferCallback':function(_0x38e2ae,_0x1d4cf6){const _0x3e539b=_0x3b0ee0;_0x1d4cf6?_0x38e2ae[_0x3e539b('0x1299')](function(_0x1cce71){_0x1cce71['penalty']=undefined;}):_0x38e2ae[_0x3e539b('0x1299')](function(_0x57af0a){const _0x35921a=_0x3e539b;_0x57af0a[_0x35921a('0x1e2a')]=_0x35921a('0x23d0')+_0x10e889[_0x35921a('0x1e2a')];});const _0x1001c5=_0x2e3ca0()['xorWith'](_0x10e889[_0x3e539b('0x23a7')],_0x10e889['selectedItems'],function(_0x44c723,_0x365739){const _0x223e62=_0x3e539b;return _0x44c723['id']===_0x365739['id']&&_0x44c723[_0x223e62('0x1e2a')]===_0x365739[_0x223e62('0x1e2a')];});_0x10e889[_0x3e539b('0x2106')]=_0x2e3ca0()[_0x3e539b('0x173f')](_0x1001c5)?![]:!![];}},_0x10e889[_0x3b0ee0('0x1dd2')]=_0x3d9396,_0x10e889['saveQueues']=_0x1188fa,_0x10e889[_0x3b0ee0('0xf82')]=_0x49f24d;function _0x3d9396(){const _0x44f95d=_0x3b0ee0;return _0x4067de[_0x44f95d('0xca1')]('admin')?_0x14048c()[_0x44f95d('0x130a')](function(_0x4fe884){const _0x690db6=_0x44f95d;_0x407528['error']({'title':_0x4fe884[_0x690db6('0x13ee')]?_0x690db6('0x2168')+_0x4fe884['status']+_0x690db6('0xbf6')+_0x4fe884[_0x690db6('0x24a9')]:_0x690db6('0x22dc'),'msg':_0x4fe884[_0x690db6('0x13ee')]?JSON[_0x690db6('0x258a')](_0x4fe884[_0x690db6('0x5a5')]):_0x4fe884[_0x690db6('0x1ff0')]()});}):_0x1858af()[_0x44f95d('0x683')](function(_0x53ceb4){const _0x4a8ccd=_0x44f95d;return _0x10e889[_0x4a8ccd('0x1aa')]=_0x53ceb4,_0x14048c();})[_0x44f95d('0x130a')](function(_0x844ccb){const _0x527150=_0x44f95d;_0x407528[_0x527150('0x52a')]({'title':_0x844ccb[_0x527150('0x13ee')]?'API:'+_0x844ccb[_0x527150('0x13ee')]+_0x527150('0xbf6')+_0x844ccb[_0x527150('0x24a9')]:_0x527150('0x22dc'),'msg':_0x844ccb[_0x527150('0x13ee')]?JSON[_0x527150('0x258a')](_0x844ccb[_0x527150('0x5a5')]):_0x844ccb[_0x527150('0x1ff0')]()});});}function _0x1858af(){return _0x56f530(function(_0x514f5c,_0x1a5cbb){const _0x1479cf=a0_0x4e0a;let _0x391322;switch(_0x10e889[_0x1479cf('0xdd6')]){case _0x1479cf('0xcf2'):switch(_0x10e889[_0x1479cf('0x2655')]){case'inbound':_0x391322=_0x1479cf('0x88d');break;case _0x1479cf('0x17cd'):_0x391322=_0x1479cf('0x1a4c');break;}break;case _0x1479cf('0x24e'):_0x391322=_0x1479cf('0x507');break;case _0x1479cf('0x129f'):_0x391322=_0x1479cf('0x97d');break;case _0x1479cf('0x1285'):_0x391322=_0x1479cf('0xd0d');break;case _0x1479cf('0x1261'):_0x391322='OpenchannelQueues';break;case _0x1479cf('0x23e9'):_0x391322='FaxQueues';break;}_0x1acf7e[_0x1479cf('0x22df')][_0x1479cf('0x1e6e')]({'userProfileId':_0x10e889['currentUser'][_0x1479cf('0x2f')],'name':_0x391322})['$promise'][_0x1479cf('0x683')](function(_0x27f695){const _0x31102e=_0x1479cf,_0x1e89d1=_0x27f695&&_0x27f695[_0x31102e('0xf5d')]?_0x27f695[_0x31102e('0xf5d')][0x0]:null;_0x514f5c(_0x1e89d1);})[_0x1479cf('0x130a')](function(_0x2837f1){_0x1a5cbb(_0x2837f1);});});}function _0x14048c(){return _0x56f530(function(_0x3762b1,_0x5b3bee){const _0x4ab125=a0_0x4e0a;return _0x594d0d()[_0x4ab125('0x683')](function(_0x56c2fb){const _0x23e89c=_0x4ab125;return _0x10e889[_0x23e89c('0x1996')]=_0x56c2fb[_0x23e89c('0xf5d')]?_0x56c2fb[_0x23e89c('0xf5d')]:[],_0x4067de[_0x23e89c('0xca1')]('admin')?_0x56c2fb:_0x10e889['section']?_0x10e889[_0x23e89c('0x1aa')][_0x23e89c('0x170')]?_0x56c2fb:_0x245c5a():null;})[_0x4ab125('0x683')](function(_0x29bcd7){const _0x4bdadc=_0x4ab125,_0x27ed38=_0x29bcd7&&_0x29bcd7[_0x4bdadc('0xf5d')]?_0x29bcd7[_0x4bdadc('0xf5d')]:[];return _0x10e889[_0x4bdadc('0x1c47')]=_0x2e3ca0()[_0x4bdadc('0x386')](_0x27ed38,function(_0xc6b7b9){const _0x3dcf62=_0x4bdadc;return _0x2e3ca0()['find'](_0x10e889['items'],{'id':_0x4067de[_0x3dcf62('0xca1')](_0x3dcf62('0x20c2'))||_0x10e889[_0x3dcf62('0x1aa')][_0x3dcf62('0x170')]?_0xc6b7b9['id']:_0xc6b7b9[_0x3dcf62('0x832')]});}),_0x10e889[_0x4bdadc('0x125e')]=angular[_0x4bdadc('0x1a86')](_0x10e889[_0x4bdadc('0x1c47')]),_0x10e889['items'][_0x4bdadc('0x1299')](function(_0x4ab211){const _0x52b409=_0x4bdadc,_0x3ff098=_0x2e3ca0()[_0x52b409('0x1c07')](_0x10e889[_0x52b409('0x1c47')],{'id':_0x4ab211['id']});_0x4067de[_0x52b409('0xca1')](_0x52b409('0x20c2'))?_0x4ab211[_0x52b409('0x24f4')]=!![]:_0x4ab211[_0x52b409('0x24f4')]=typeof _0x3ff098!==_0x52b409('0x1867')?!![]:![];}),_0x549b4f();})[_0x4ab125('0x683')](function(_0x344692){const _0x40f369=_0x4ab125,_0x316fd3=_0x344692&&_0x344692[_0x40f369('0xf5d')]?_0x344692[_0x40f369('0xf5d')]:[];_0x10e889[_0x40f369('0x1378')]=_0x2e3ca0()[_0x40f369('0x386')](_0x316fd3,function(_0x34c496){const _0x389ae7=_0x40f369,_0x30c55d=_0x2e3ca0()[_0x389ae7('0x1c07')](_0x10e889[_0x389ae7('0x1996')],{'id':_0x34c496['id']});return _0x10e889['channel']===_0x389ae7('0xcf2')&&(_0x30c55d[_0x389ae7('0x1e2a')]=typeof _0x30c55d!==_0x389ae7('0x1867')&&typeof _0x34c496[_0x389ae7('0x1901')]!==_0x389ae7('0x1867')?_0x389ae7('0x23d0')+_0x34c496['UserVoiceQueue'][_0x389ae7('0x1e2a')]:_0x389ae7('0x23d0')+0x0),_0x30c55d;}),_0x10e889[_0x40f369('0x23a7')]=angular['copy'](_0x10e889[_0x40f369('0x1378')]),_0x10e889['dualMultiselectOptions'][_0x40f369('0x1378')]=_0x10e889['selectedItems'],_0x10e889['dualMultiselectOptions']['items']=_0x2e3ca0()['differenceBy'](_0x10e889[_0x40f369('0x1c47')],_0x10e889['dualMultiselectOptions'][_0x40f369('0x1378')],'id'),_0x3762b1();})[_0x4ab125('0x130a')](function(_0x55afcd){_0x5b3bee(_0x55afcd);});});}function _0x245c5a(){return _0x56f530(function(_0x50fab1,_0x52a5c1){const _0x4b1727=a0_0x4e0a;return _0x1acf7e[_0x4b1727('0xcf7')][_0x4b1727('0x1e6e')]({'sectionId':_0x10e889[_0x4b1727('0x1aa')]['id'],'nolimit':!![]})[_0x4b1727('0xe53')]['then'](function(_0x4e360c){_0x50fab1(_0x4e360c);})[_0x4b1727('0x130a')](function(_0x44fdbe){_0x52a5c1(_0x44fdbe);});});}function _0x549b4f(){return _0x56f530(function(_0x421d11,_0x1d5511){const _0x316994=a0_0x4e0a;return _0x1acf7e['user'][_0x316994('0x4c9')]({'id':_0x10e889[_0x316994('0x2327')]['id'],'fields':_0x316994('0x1f06'),'nolimit':!![],'type':_0x10e889[_0x316994('0x2655')],'channel':_0x10e889[_0x316994('0xdd6')]})[_0x316994('0xe53')][_0x316994('0x683')](function(_0x2b9793){_0x421d11(_0x2b9793);})[_0x316994('0x130a')](function(_0x3f44c0){_0x1d5511(_0x3f44c0);});});}function _0x594d0d(){return _0x56f530(function(_0x5a1849,_0x39bf1a){const _0x3194de=a0_0x4e0a;return _0x1acf7e[_0x10e889[_0x3194de('0x213')]][_0x3194de('0x1e6e')]({'fields':_0x3194de('0x5fb'),'channel':_0x10e889[_0x3194de('0xdd6')]===_0x3194de('0x5d9')?_0x3194de('0xcf2'):_0x10e889[_0x3194de('0xdd6')],'type':_0x10e889[_0x3194de('0x2655')],'nolimit':!![]})[_0x3194de('0xe53')][_0x3194de('0x683')](function(_0x1de401){_0x5a1849(_0x1de401);})['catch'](function(_0xedd5ee){_0x39bf1a(_0xedd5ee);});});}function _0x599503(_0x50cfcc){return _0x56f530(function(_0x5a773a,_0x1be79c){const _0x5693ee=a0_0x4e0a;if(_0x2e3ca0()[_0x5693ee('0x173f')](_0x50cfcc))_0x5a773a();else{if(_0x10e889['channel']===_0x5693ee('0xcf2')){const _0x227321=[],_0x865811=_0x2e3ca0()[_0x5693ee('0x600')](_0x50cfcc,_0x5693ee('0x1e2a'));for(let _0x42d493=0x0;_0x42d493':'',_0x33307f;}),_0x5ea42a[_0x1a6459('0x23a7')]=angular['copy'](_0x5ea42a[_0x1a6459('0x1378')]),_0x5ea42a[_0x1a6459('0x169f')][_0x1a6459('0x1378')]=_0x5ea42a[_0x1a6459('0x1378')],_0x5ea42a['dualMultiselectOptions'][_0x1a6459('0x1996')]=_0x2e3ca0()[_0x1a6459('0x461')](_0x5ea42a[_0x1a6459('0x1c47')],_0x5ea42a[_0x1a6459('0x169f')]['selectedItems'],'id'),_0x1c1b81();})[_0x8d77b6('0x130a')](function(_0x3f5f3f){_0x5623a8(_0x3f5f3f);});});}function _0x38f928(){return _0x5d327b(function(_0x2cb768,_0x127a24){const _0x543513=a0_0x4e0a;return _0x2ff7b7[_0x543513('0xcf7')][_0x543513('0x1e6e')]({'sectionId':_0x5ea42a[_0x543513('0x1aa')]['id'],'nolimit':!![]})[_0x543513('0xe53')][_0x543513('0x683')](function(_0x430c5c){_0x2cb768(_0x430c5c);})['catch'](function(_0x5e1fe1){_0x127a24(_0x5e1fe1);});});}function _0x5c51c1(){return _0x5d327b(function(_0xe97f4b,_0x3ee1fc){const _0x199e01=a0_0x4e0a;return _0x2ff7b7[_0x199e01('0xd88')][_0x199e01('0x8e7')]({'id':_0x5ea42a[_0x199e01('0xd88')]['id'],'fields':_0x199e01('0x72b'),'nolimit':!![],'role':_0x199e01('0x2327')})[_0x199e01('0xe53')]['then'](function(_0x3f0894){_0xe97f4b(_0x3f0894);})[_0x199e01('0x130a')](function(_0x323a06){_0x3ee1fc(_0x323a06);});});}function _0x2dce72(){return _0x5d327b(function(_0x3b8d3a,_0x547e04){const _0x52654e=a0_0x4e0a;return _0x2ff7b7[_0x52654e('0xc96')][_0x52654e('0x1e6e')]({'fields':_0x52654e('0x72b'),'nolimit':!![],'role':_0x52654e('0x2327')})[_0x52654e('0xe53')][_0x52654e('0x683')](function(_0x25c47b){_0x3b8d3a(_0x25c47b);})[_0x52654e('0x130a')](function(_0x7b3b95){_0x547e04(_0x7b3b95);});});}function _0x4780c2(_0x44b333){return _0x5d327b(function(_0x43c0bb,_0x1d2b23){const _0xc1e509=a0_0x4e0a;_0x2e3ca0()[_0xc1e509('0x173f')](_0x44b333)?_0x43c0bb():_0x2ff7b7[_0xc1e509('0xd88')]['addAgents']({'id':_0x5ea42a[_0xc1e509('0xd88')]['id'],'ids':_0x2e3ca0()[_0xc1e509('0x386')](_0x44b333,'id')})[_0xc1e509('0xe53')]['then'](function(){_0x43c0bb();})['catch'](function(_0x15ed1e){_0x1d2b23(_0x15ed1e);});});}function _0x3ac3d0(_0x4ce719){return _0x5d327b(function(_0x161ebe,_0x36b58b){const _0x26c1aa=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0x4ce719)?_0x161ebe():_0x2ff7b7[_0x26c1aa('0xd88')][_0x26c1aa('0xf9')]({'id':_0x5ea42a[_0x26c1aa('0xd88')]['id'],'ids':_0x2e3ca0()[_0x26c1aa('0x386')](_0x4ce719,'id')})[_0x26c1aa('0xe53')][_0x26c1aa('0x683')](function(){_0x161ebe();})[_0x26c1aa('0x130a')](function(_0xf032c0){_0x36b58b(_0xf032c0);});});}function _0x524e20(){const _0x2f6e63=_0x20249c,_0x1e18bd=_0x2e3ca0()['differenceBy'](_0x5ea42a[_0x2f6e63('0x23a7')],_0x5ea42a[_0x2f6e63('0x1378')],'id'),_0x557051=_0x2e3ca0()[_0x2f6e63('0x461')](_0x5ea42a[_0x2f6e63('0x1378')],_0x5ea42a[_0x2f6e63('0x23a7')],'id');return _0x3ac3d0(_0x1e18bd)[_0x2f6e63('0x683')](function(){return _0x4780c2(_0x557051);})['then'](function(){const _0x2090e1=_0x2f6e63;_0x5ea42a[_0x2090e1('0x2106')]=![],_0x5ea42a[_0x2090e1('0x125e')]=angular[_0x2090e1('0x1a86')](_0x5ea42a[_0x2090e1('0x1c47')]),_0x5ea42a[_0x2090e1('0x23a7')]=angular[_0x2090e1('0x1a86')](_0x5ea42a['selectedItems']),_0x23bf0c[_0x2090e1('0x53')]({'title':_0x2090e1('0xd28'),'msg':_0x2090e1('0x89d')});})[_0x2f6e63('0x130a')](function(_0x296379){const _0x2e2e0f=_0x2f6e63;_0x23bf0c[_0x2e2e0f('0x52a')]({'title':_0x296379[_0x2e2e0f('0x13ee')]?_0x2e2e0f('0x2168')+_0x296379['status']+_0x2e2e0f('0xbf6')+_0x296379['statusText']:_0x2e2e0f('0x1b71'),'msg':_0x296379[_0x2e2e0f('0x13ee')]?JSON[_0x2e2e0f('0x258a')](_0x296379[_0x2e2e0f('0x5a5')]):_0x296379[_0x2e2e0f('0x1ff0')]()});});}function _0x3ab6f1(){_0x402b52['hide']();}}const _0x36d148=_0x576659,_0x5a1ba2=_0x180212['p']+_0x189033('0x16a3'),_0x49ed4c=_0x180212['p']+_0x189033('0xf2e');_0x49828a[_0x189033('0x14be')]=['$scope',_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0xff'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),'Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x49828a(_0x165cbf,_0x1a6143,_0x450813,_0x1223ec,_0x20ea38,_0x3d78ba,_0x639d7,_0x423e3b,_0x16a9aa,_0x5e93c0,_0x74db69,_0x257a6d,_0x30f653,_0x35db5f,_0x2ae287,_0x1ef967,_0x325d29){const _0x26de0e=_0x189033,_0x27102d=this;_0x27102d[_0x26de0e('0xace')]=_0x1ef967,_0x27102d[_0x26de0e('0x260a')]=_0x325d29,_0x27102d[_0x26de0e('0x11ed')]=_0x2ae287['getCurrentUser'](),_0x27102d[_0x26de0e('0xff')]=_0x16a9aa||{'count':0x0,'rows':[]},_0x27102d[_0x26de0e('0x2a')]=_0x5e93c0,_0x27102d[_0x26de0e('0x22df')]=_0x74db69&&_0x74db69[_0x26de0e('0x50d')]==0x1?_0x74db69[_0x26de0e('0xf5d')][0x0]:null,_0x27102d[_0x26de0e('0x1134')]=_0x2ae287[_0x26de0e('0x142a')](_0x27102d['userProfileSection']?_0x27102d[_0x26de0e('0x22df')][_0x26de0e('0x1134')]:null),_0x27102d[_0x26de0e('0x5c4')]=_0x26de0e('0xff'),_0x27102d[_0x26de0e('0x247')]='',_0x27102d[_0x26de0e('0x1ce2')]=null,_0x27102d[_0x26de0e('0x11b')]=[],_0x27102d[_0x26de0e('0x23a2')]={'fields':_0x26de0e('0x120a'),'sort':_0x26de0e('0xc36'),'limit':0xa,'page':0x1},_0x27102d[_0x26de0e('0x1249')]=_0x8fcc05,_0x27102d['agentadddialog']=_0x3972af,_0x27102d[_0x26de0e('0x194f')]=_0x46b946,_0x27102d['success']=_0x30b584,_0x27102d[_0x26de0e('0xf90')]=_0x1e5cd9,_0x27102d[_0x26de0e('0xedd')]=_0x160e0d,_0x27102d[_0x26de0e('0xcaf')]=_0x1daae1,_0x27102d[_0x26de0e('0x9f7')]=_0x355541,_0x27102d[_0x26de0e('0x12d1')]=_0x17289b,_0x27102d[_0x26de0e('0x1c2e')]=_0x373093,_0x27102d['selectAllTeams']=_0xa37725;function _0x8fcc05(_0x1a1272,_0x374ed5){const _0x21525c=_0x26de0e;_0x20ea38[_0x21525c('0x1d4')]({'controller':_0x21525c('0xce8'),'controllerAs':'vm','templateUrl':_0x5a1ba2,'parent':angular[_0x21525c('0x1fcc')](_0x3d78ba[_0x21525c('0x18e5')]),'targetEvent':_0x374ed5,'clickOutsideToClose':!![],'locals':{'team':_0x1a1272,'teams':_0x27102d[_0x21525c('0xff')][_0x21525c('0xf5d')],'license':_0x27102d[_0x21525c('0xace')],'setting':null,'crudPermissions':_0x27102d[_0x21525c('0x1134')]}});}function _0x3972af(_0x358fe5,_0x14d44e){const _0x2a9daf=_0x26de0e;_0x20ea38[_0x2a9daf('0x1d4')]({'controller':_0x2a9daf('0x11a4'),'controllerAs':'vm','templateUrl':_0x49ed4c,'parent':angular[_0x2a9daf('0x1fcc')](_0x3d78ba['body']),'targetEvent':_0x14d44e,'clickOutsideToClose':!![],'locals':{'team':_0x358fe5,'teams':_0x27102d[_0x2a9daf('0xff')]?_0x27102d[_0x2a9daf('0xff')][_0x2a9daf('0xf5d')]:[],'crudPermissions':_0x27102d[_0x2a9daf('0x1134')],'realtime':![]}});}function _0x46b946(_0x3f3745,_0x3b9a56){const _0x1da4f1=_0x26de0e,_0x5346a4=_0x20ea38[_0x1da4f1('0x1c6f')]()[_0x1da4f1('0xf28')](_0x1da4f1('0x1b01')+_0x2e3ca0()[_0x1da4f1('0x1e03')](_0x1da4f1('0xd88'))+'?')[_0x1da4f1('0x26e3')](_0x1da4f1('0xed5')+(_0x3f3745[_0x1da4f1('0x60a')]||'team')+_0x1da4f1('0x20f1')+_0x1da4f1('0x1ee7'))[_0x1da4f1('0x1040')](_0x1da4f1('0xa30'))['targetEvent'](_0x3b9a56)['ok']('OK')['cancel'](_0x1da4f1('0x16b8'));_0x20ea38['show'](_0x5346a4)[_0x1da4f1('0x683')](function(){_0x1daae1(_0x3f3745);},function(){const _0x11852c=_0x1da4f1;console[_0x11852c('0x1b2b')](_0x11852c('0x16b8'));});}let _0x61af=!![],_0x22e402=0x1;_0x165cbf[_0x26de0e('0x186d')]('vm.query.filter',function(_0x27dcb8,_0x5dcbea){const _0x1e4f66=_0x26de0e;_0x61af?_0x639d7(function(){_0x61af=![];}):(!_0x5dcbea&&(_0x22e402=_0x27102d['query'][_0x1e4f66('0xdf8')]),_0x27dcb8!==_0x5dcbea&&(_0x27102d[_0x1e4f66('0x23a2')][_0x1e4f66('0xdf8')]=0x1),!_0x27dcb8&&(_0x27102d['query']['page']=_0x22e402),_0x27102d[_0x1e4f66('0xf90')]());});function _0x30b584(_0x325fe7){const _0x4b9b9c=_0x26de0e;_0x27102d[_0x4b9b9c('0xff')]=_0x325fe7||{'count':0x0,'rows':[]};}function _0x1e5cd9(){const _0x581729=_0x26de0e;_0x27102d[_0x581729('0x23a2')]['offset']=(_0x27102d[_0x581729('0x23a2')][_0x581729('0xdf8')]-0x1)*_0x27102d['query']['limit'],_0x2ae287[_0x581729('0xca1')]('admin')?_0x27102d[_0x581729('0x1883')]=_0x257a6d[_0x581729('0xd88')][_0x581729('0x1e6e')](_0x27102d[_0x581729('0x23a2')],_0x30b584)['$promise']:(_0x27102d[_0x581729('0x23a2')]['id']=_0x27102d['userProfile']['id'],_0x27102d[_0x581729('0x23a2')][_0x581729('0x1aa')]='Teams',_0x27102d['promise']=_0x257a6d[_0x581729('0x2a')]['getResources'](_0x27102d[_0x581729('0x23a2')],_0x30b584)['$promise']);}function _0x160e0d(_0xe19f4,_0x4426e5){const _0x3f94ff=_0x26de0e;_0x20ea38[_0x3f94ff('0x1d4')]({'controller':'CreateOrEditTeamDialogController','controllerAs':'vm','templateUrl':_0x5a1ba2,'parent':angular[_0x3f94ff('0x1fcc')](_0x3d78ba[_0x3f94ff('0x18e5')]),'targetEvent':_0xe19f4,'clickOutsideToClose':!![],'locals':{'team':_0x4426e5,'teams':_0x27102d[_0x3f94ff('0xff')][_0x3f94ff('0xf5d')],'license':_0x27102d[_0x3f94ff('0xace')],'setting':_0x27102d[_0x3f94ff('0x260a')],'crudPermissions':_0x27102d[_0x3f94ff('0x1134')]}});}function _0x1daae1(_0x25fdb6){const _0x435312=_0x26de0e;_0x257a6d[_0x435312('0xd88')][_0x435312('0xd7e')]({'id':_0x25fdb6['id']})['$promise'][_0x435312('0x683')](function(){const _0x220104=_0x435312;_0x2e3ca0()['remove'](_0x27102d[_0x220104('0xff')][_0x220104('0xf5d')],{'id':_0x25fdb6['id']}),_0x27102d[_0x220104('0xff')][_0x220104('0x50d')]-=0x1,!_0x27102d[_0x220104('0xff')]['rows'][_0x220104('0x1564')]&&_0x27102d['getTeams'](),_0x35db5f[_0x220104('0x53')]({'title':_0x2e3ca0()[_0x220104('0x1e03')]('Team')+'\x20deleted!','msg':_0x25fdb6[_0x220104('0x60a')]?_0x25fdb6[_0x220104('0x60a')]+_0x220104('0x194d'):''});})[_0x435312('0x130a')](function(_0x4ff4f8){const _0xe07b2b=_0x435312;if(_0x4ff4f8['data']&&_0x4ff4f8[_0xe07b2b('0x5a5')][_0xe07b2b('0x17f')]&&_0x4ff4f8[_0xe07b2b('0x5a5')][_0xe07b2b('0x17f')][_0xe07b2b('0x1564')]){_0x27102d['errors']=_0x4ff4f8[_0xe07b2b('0x5a5')]['errors']||[{'message':_0x4ff4f8[_0xe07b2b('0x1ff0')](),'type':_0xe07b2b('0x3de')}];for(let _0x2b44d0=0x0;_0x2b44d0<_0x4ff4f8[_0xe07b2b('0x5a5')][_0xe07b2b('0x17f')][_0xe07b2b('0x1564')];_0x2b44d0++){_0x35db5f[_0xe07b2b('0x52a')]({'title':_0x4ff4f8[_0xe07b2b('0x5a5')][_0xe07b2b('0x17f')][_0x2b44d0][_0xe07b2b('0xcf0')],'msg':_0x4ff4f8[_0xe07b2b('0x5a5')][_0xe07b2b('0x17f')][_0x2b44d0]['message']});}}else _0x35db5f[_0xe07b2b('0x52a')]({'title':_0x4ff4f8[_0xe07b2b('0x13ee')]?_0xe07b2b('0x2168')+_0x4ff4f8[_0xe07b2b('0x13ee')]+'\x20-\x20'+_0x4ff4f8[_0xe07b2b('0x24a9')]:_0xe07b2b('0x3de'),'msg':_0x4ff4f8['data']?JSON[_0xe07b2b('0x258a')](_0x4ff4f8[_0xe07b2b('0x5a5')][_0xe07b2b('0x8c2')]):_0x4ff4f8[_0xe07b2b('0x8c2')]||_0x4ff4f8['toString']()});});}function _0x355541(){const _0x444d1f=_0x26de0e,_0x4c921a=angular['copy'](_0x27102d[_0x444d1f('0x11b')]);return _0x27102d['selectedTeams']=[],_0x4c921a;}function _0x17289b(_0x3e151f){const _0x2a82a2=_0x26de0e,_0x3b055c=_0x20ea38[_0x2a82a2('0x1c6f')]()[_0x2a82a2('0xf28')](_0x2a82a2('0x1c8e'))[_0x2a82a2('0x26e3')](_0x2a82a2('0xed5')+_0x27102d['selectedTeams'][_0x2a82a2('0x1564')]+_0x2a82a2('0x93c')+_0x2a82a2('0x1ee7'))[_0x2a82a2('0x1040')](_0x2a82a2('0xfc7'))['targetEvent'](_0x3e151f)['ok']('OK')[_0x2a82a2('0x19fb')]('CANCEL');_0x20ea38[_0x2a82a2('0x1d4')](_0x3b055c)[_0x2a82a2('0x683')](function(){const _0x137ba5=_0x2a82a2;_0x27102d[_0x137ba5('0x11b')][_0x137ba5('0x1299')](function(_0x333aed){_0x1daae1(_0x333aed);}),_0x27102d[_0x137ba5('0x11b')]=[];});}function _0x373093(){const _0x521105=_0x26de0e;_0x27102d[_0x521105('0x11b')]=[];}function _0xa37725(){const _0x2e5a2f=_0x26de0e;_0x27102d[_0x2e5a2f('0x11b')]=_0x27102d[_0x2e5a2f('0xff')][_0x2e5a2f('0xf5d')];}}const _0x493f82=_0x49828a;_0x49d94a[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location','$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x723'),_0x189033('0x24d3'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x49d94a(_0x3ca117,_0x6ade15,_0x507a52,_0x7da146,_0x98265f,_0x44ecb9,_0x46609b,_0x4e4b92,_0xad653d,_0x54620c,_0x9898bf,_0x493234,_0x334dae,_0x42333a){const _0x5972f=_0x189033,_0x1cf6f1=this;_0x1cf6f1['currentUser']=_0x9898bf[_0x5972f('0x20b2')](),_0x1cf6f1[_0x5972f('0x17f')]=[],_0x1cf6f1[_0x5972f('0x260a')]=_0x334dae,_0x1cf6f1['license']=_0x493234,_0x1cf6f1['crudPermissions']=_0x42333a,_0x1cf6f1[_0x5972f('0x258d')]={},_0x1cf6f1[_0x5972f('0x19b2')]=_0x1cf6f1[_0x5972f('0x260a')]&&_0x1cf6f1[_0x5972f('0x260a')][_0x5972f('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1cf6f1[_0x5972f('0xf28')]=_0x5972f('0x2693'),_0x1cf6f1[_0x5972f('0x24d3')]=angular[_0x5972f('0x1a86')](_0xad653d),_0x1cf6f1[_0x5972f('0x723')]=_0x4e4b92,_0x1cf6f1[_0x5972f('0x1c0e')]=![];!_0x1cf6f1[_0x5972f('0x24d3')]&&(_0x1cf6f1['telephone']={'role':'telephone','autointernal':!![],'context':_0x5972f('0x1365')},_0x1cf6f1[_0x5972f('0xf28')]=_0x5972f('0x181d'),_0x1cf6f1[_0x5972f('0x1c0e')]=!![]);_0x1cf6f1[_0x5972f('0x1ada')]=_0x57da7c,_0x1cf6f1[_0x5972f('0xe4f')]=_0x1e40dc,_0x1cf6f1['deleteTelephone']=_0x40320b,_0x1cf6f1[_0x5972f('0x16b3')]=_0x5ab9f9,_0x1cf6f1[_0x5972f('0xf82')]=_0x359ad2;function _0x57da7c(){const _0x36487b=_0x5972f;_0x1cf6f1[_0x36487b('0x17f')]=[],_0x54620c[_0x36487b('0xc96')][_0x36487b('0xb0a')](_0x1cf6f1['telephone'])[_0x36487b('0xe53')][_0x36487b('0x683')](function(_0x22d6bd){const _0x41b2cf=_0x36487b;_0x1cf6f1['telephones']['unshift'](_0x22d6bd[_0x41b2cf('0x24e1')]()),_0x46609b[_0x41b2cf('0x53')]({'title':'Telephone\x20properly\x20created','msg':_0x1cf6f1[_0x41b2cf('0x24d3')][_0x41b2cf('0x60a')]?_0x1cf6f1[_0x41b2cf('0x24d3')][_0x41b2cf('0x60a')]+'\x20has\x20been\x20created!':''}),_0x359ad2(_0x22d6bd);})['catch'](function(_0x16ec76){const _0x571b88=_0x36487b;if(_0x16ec76[_0x571b88('0x5a5')]&&_0x16ec76['data'][_0x571b88('0x17f')]&&_0x16ec76[_0x571b88('0x5a5')][_0x571b88('0x17f')][_0x571b88('0x1564')]){_0x1cf6f1[_0x571b88('0x17f')]=_0x16ec76[_0x571b88('0x5a5')][_0x571b88('0x17f')]||[{'message':_0x16ec76[_0x571b88('0x1ff0')](),'type':_0x571b88('0x7b5')}];for(let _0x48cee8=0x0;_0x48cee8<_0x16ec76[_0x571b88('0x5a5')][_0x571b88('0x17f')][_0x571b88('0x1564')];_0x48cee8+=0x1){_0x46609b[_0x571b88('0x52a')]({'title':_0x16ec76[_0x571b88('0x5a5')][_0x571b88('0x17f')][_0x48cee8][_0x571b88('0xcf0')],'msg':_0x16ec76[_0x571b88('0x5a5')]['errors'][_0x48cee8][_0x571b88('0x8c2')]});}}else _0x46609b[_0x571b88('0x52a')]({'title':_0x16ec76[_0x571b88('0x13ee')]?'API:'+_0x16ec76[_0x571b88('0x13ee')]+_0x571b88('0xbf6')+_0x16ec76[_0x571b88('0x24a9')]:_0x571b88('0x7b5'),'msg':_0x16ec76[_0x571b88('0x5a5')]?JSON['stringify'](_0x16ec76[_0x571b88('0x5a5')][_0x571b88('0x8c2')]):_0x16ec76['toString']()});});}function _0x1e40dc(){const _0x2843ad=_0x5972f;_0x1cf6f1['errors']=[],_0x54620c[_0x2843ad('0xc96')][_0x2843ad('0x2480')]({'id':_0x1cf6f1['telephone']['id']},_0x1cf6f1[_0x2843ad('0x24d3')])[_0x2843ad('0xe53')]['then'](function(_0x59c55b){const _0x3a388b=_0x2843ad,_0x5c90e5=_0x2e3ca0()[_0x3a388b('0x1c07')](_0x1cf6f1[_0x3a388b('0x723')],{'id':_0x59c55b['id']});_0x5c90e5&&_0x2e3ca0()[_0x3a388b('0xf22')](_0x5c90e5,_0x2e3ca0()['pick'](_0x59c55b[_0x3a388b('0x24e1')](),_0x2e3ca0()[_0x3a388b('0x55e')](_0x5c90e5))),_0x46609b['success']({'title':'Telephone\x20properly\x20saved!','msg':_0x1cf6f1[_0x3a388b('0x24d3')]['name']?_0x1cf6f1[_0x3a388b('0x24d3')][_0x3a388b('0x60a')]+_0x3a388b('0xf59'):''}),_0x359ad2(_0x59c55b);})[_0x2843ad('0x130a')](function(_0x3333cd){const _0x4ab5a9=_0x2843ad;if(_0x3333cd['data']&&_0x3333cd[_0x4ab5a9('0x5a5')]['errors']&&_0x3333cd[_0x4ab5a9('0x5a5')][_0x4ab5a9('0x17f')][_0x4ab5a9('0x1564')]){_0x1cf6f1[_0x4ab5a9('0x17f')]=_0x3333cd['data']['errors']||[{'message':_0x3333cd['toString'](),'type':_0x4ab5a9('0x162b')}];for(let _0x23c72e=0x0;_0x23c72e<_0x3333cd[_0x4ab5a9('0x5a5')]['errors']['length'];_0x23c72e++){_0x46609b['error']({'title':_0x3333cd[_0x4ab5a9('0x5a5')][_0x4ab5a9('0x17f')][_0x23c72e]['type'],'msg':_0x3333cd['data']['errors'][_0x23c72e][_0x4ab5a9('0x8c2')]});}}else _0x46609b[_0x4ab5a9('0x52a')]({'title':_0x3333cd[_0x4ab5a9('0x13ee')]?_0x4ab5a9('0x2168')+_0x3333cd[_0x4ab5a9('0x13ee')]+_0x4ab5a9('0xbf6')+_0x3333cd[_0x4ab5a9('0x24a9')]:_0x4ab5a9('0x162b'),'msg':_0x3333cd[_0x4ab5a9('0x5a5')]?JSON[_0x4ab5a9('0x258a')](_0x3333cd[_0x4ab5a9('0x5a5')][_0x4ab5a9('0x8c2')]):_0x3333cd[_0x4ab5a9('0x1ff0')]()});});}function _0x40320b(_0x327513){const _0x15da96=_0x5972f;_0x1cf6f1['errors']=[];const _0xd5c165=_0x7da146[_0x15da96('0x1c6f')]()['title']('Are\x20you\x20sure?')['content'](_0x15da96('0x17be'))['ariaLabel'](_0x15da96('0x1dd7'))['ok'](_0x15da96('0x2307'))[_0x15da96('0x19fb')](_0x15da96('0x253a'))[_0x15da96('0xe42')](_0x327513);_0x7da146[_0x15da96('0x1d4')](_0xd5c165)[_0x15da96('0x683')](function(){const _0x12cb77=_0x15da96;_0x54620c['user'][_0x12cb77('0xd7e')]({'id':_0x1cf6f1[_0x12cb77('0x24d3')]['id']})[_0x12cb77('0xe53')][_0x12cb77('0x683')](function(){const _0x23d6b8=_0x12cb77;_0x2e3ca0()['remove'](_0x1cf6f1[_0x23d6b8('0x723')],{'id':_0x1cf6f1['telephone']['id']}),_0x46609b[_0x23d6b8('0x53')]({'title':_0x23d6b8('0x96b'),'msg':(_0x1cf6f1[_0x23d6b8('0x24d3')][_0x23d6b8('0x60a')]||'telephone')+_0x23d6b8('0x194d')}),_0x359ad2(_0x1cf6f1[_0x23d6b8('0x24d3')]);})[_0x12cb77('0x130a')](function(_0x5d8271){const _0x1f21bd=_0x12cb77;if(_0x5d8271[_0x1f21bd('0x5a5')]&&_0x5d8271[_0x1f21bd('0x5a5')][_0x1f21bd('0x17f')]&&_0x5d8271['data'][_0x1f21bd('0x17f')][_0x1f21bd('0x1564')]){_0x1cf6f1[_0x1f21bd('0x17f')]=_0x5d8271[_0x1f21bd('0x5a5')]['errors']||[{'message':_0x5d8271[_0x1f21bd('0x1ff0')](),'type':'api.user.delete'}];for(let _0x35db15=0x0;_0x35db15<_0x5d8271['data']['errors'][_0x1f21bd('0x1564')];_0x35db15++){_0x46609b['error']({'title':_0x5d8271[_0x1f21bd('0x5a5')][_0x1f21bd('0x17f')][_0x35db15][_0x1f21bd('0xcf0')],'msg':_0x5d8271[_0x1f21bd('0x5a5')][_0x1f21bd('0x17f')][_0x35db15][_0x1f21bd('0x8c2')]});}}else _0x46609b[_0x1f21bd('0x52a')]({'title':_0x5d8271[_0x1f21bd('0x13ee')]?_0x1f21bd('0x2168')+_0x5d8271[_0x1f21bd('0x13ee')]+_0x1f21bd('0xbf6')+_0x5d8271[_0x1f21bd('0x24a9')]:'api.user.delete','msg':_0x5d8271[_0x1f21bd('0x5a5')]?JSON['stringify'](_0x5d8271['data'][_0x1f21bd('0x8c2')]):_0x5d8271[_0x1f21bd('0x8c2')]||_0x5d8271[_0x1f21bd('0x1ff0')]()});});},function(){});}function _0x5ab9f9(_0x1fb23d){return _0x1fb23d===null?undefined:new Date(_0x1fb23d);}function _0x359ad2(_0xd6e965){_0x7da146['hide'](_0xd6e965);}}const _0x53b450=_0x49d94a;_0x23b7ad['$inject']=[_0x189033('0x7a5'),_0x189033('0x1e48'),'toasty',_0x189033('0x56b'),_0x189033('0x24d3'),_0x189033('0x260a'),_0x189033('0xba1')];function _0x23b7ad(_0x3c8b47,_0xc7f881,_0x44dfb0,_0x2d9493,_0x2343e1,_0x3b7319,_0x416f28){const _0xcf2e8d=_0x189033,_0x3ed7fc=this;_0x3ed7fc[_0xcf2e8d('0x11ed')]=_0x416f28[_0xcf2e8d('0x20b2')](),_0x3ed7fc[_0xcf2e8d('0x17f')]=[],_0x3ed7fc['setting']=_0x3b7319,_0x3ed7fc[_0xcf2e8d('0x19b2')]=_0x3ed7fc[_0xcf2e8d('0x260a')][_0xcf2e8d('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3ed7fc[_0xcf2e8d('0x24d3')]=_0x2343e1,_0x3ed7fc[_0xcf2e8d('0x1e96')]='',_0x3ed7fc[_0xcf2e8d('0x17fb')]='',_0x3ed7fc[_0xcf2e8d('0x1808')]=_0x6ae9c2,_0x3ed7fc[_0xcf2e8d('0xf82')]=_0x42db74,_0x3c8b47[_0xcf2e8d('0x186d')](_0xcf2e8d('0x1567'),function(_0x2aef0d){const _0x4d87e8=_0xcf2e8d;!_0x2e3ca0()['isNil'](_0x3ed7fc[_0x4d87e8('0x17fb')])&&(_0x2aef0d===_0x3ed7fc[_0x4d87e8('0x17fb')]?_0x3c8b47['telephoneForm'][_0x4d87e8('0x1e96')][_0x4d87e8('0x1c25')](_0x4d87e8('0x20b9'),![]):_0x3c8b47[_0x4d87e8('0x1670')][_0x4d87e8('0x1e96')][_0x4d87e8('0x1c25')](_0x4d87e8('0x20b9'),!![]));});function _0x6ae9c2(){const _0x5d7f2d=_0xcf2e8d;_0x3ed7fc[_0x5d7f2d('0x17f')]=[];const _0x599f9f={'id':_0x3ed7fc[_0x5d7f2d('0x24d3')]['id'],'newPassword':_0x3ed7fc[_0x5d7f2d('0x1e96')]};_0x3ed7fc['currentUser']['id']==_0x3ed7fc[_0x5d7f2d('0x24d3')]['id']&&(_0x599f9f[_0x5d7f2d('0x17fb')]=_0x3ed7fc[_0x5d7f2d('0x17fb')]),_0x2d9493[_0x5d7f2d('0xc96')][_0x5d7f2d('0x2193')](_0x599f9f)[_0x5d7f2d('0xe53')][_0x5d7f2d('0x683')](function(){const _0x1bd371=_0x5d7f2d;_0x44dfb0['success']({'title':_0x1bd371('0x5bd')}),_0x42db74();})[_0x5d7f2d('0x130a')](function(_0x453d32){const _0x40e88d=_0x5d7f2d;_0x44dfb0['error']({'title':_0x453d32['status']?'API:'+_0x453d32[_0x40e88d('0x13ee')]+_0x40e88d('0xbf6')+_0x453d32['statusText']:_0x40e88d('0x1214'),'msg':_0x453d32['data']?JSON[_0x40e88d('0x258a')](_0x453d32['data'][_0x40e88d('0x8c2')]):_0x453d32[_0x40e88d('0x1ff0')]()}),_0x3ed7fc[_0x40e88d('0x17f')]=_0x453d32[_0x40e88d('0x5a5')][_0x40e88d('0x17f')]||[{'message':_0x453d32[_0x40e88d('0x1ff0')](),'type':_0x40e88d('0x3c1')}];});}function _0x42db74(){const _0x3ab1e9=_0xcf2e8d;_0xc7f881[_0x3ab1e9('0x1715')]();}}const _0x44d10c=_0x23b7ad,_0x3cdd96=_0x180212['p']+'src/js/modules/main/apps/staff/views/telephones/edit/changepassword/changepassword.html/changepassword.html';_0x1eedd9[_0x189033('0x14be')]=['$state','$location','$mdDialog','$document','$translate','license','setting','api',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x24d3'),_0x189033('0x22df')];function _0x1eedd9(_0xee9b9f,_0x14e9b8,_0x32cfea,_0x3d37b0,_0x3517c5,_0x43d6f8,_0x2e652f,_0x3345ba,_0x58c84b,_0x3ac39f,_0x56c133,_0x10bae3){const _0x3e7dbb=_0x189033,_0xf7f5e8=this;_0xf7f5e8[_0x3e7dbb('0x11ed')]=_0x3ac39f[_0x3e7dbb('0x20b2')](),_0xf7f5e8[_0x3e7dbb('0xace')]=_0x43d6f8,_0xf7f5e8[_0x3e7dbb('0x260a')]=_0x2e652f,_0xf7f5e8['passwordPattern']=_0xf7f5e8['setting'][_0x3e7dbb('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xf7f5e8[_0x3e7dbb('0x1224')]=_0x14e9b8[_0x3e7dbb('0x173e')]()+_0x3e7dbb('0x20de')+_0x14e9b8[_0x3e7dbb('0x19ac')](),_0xf7f5e8['telephone']=_0x56c133||_0xee9b9f[_0x3e7dbb('0x7f2')][_0x3e7dbb('0x24d3')]||{},_0xf7f5e8[_0x3e7dbb('0x22df')]=_0x10bae3&&_0x10bae3['count']==0x1?_0x10bae3[_0x3e7dbb('0xf5d')][0x0]:null,_0xf7f5e8[_0x3e7dbb('0x1134')]=_0x3ac39f['parseCrudPermissions'](_0xf7f5e8[_0x3e7dbb('0x22df')]?_0xf7f5e8[_0x3e7dbb('0x22df')][_0x3e7dbb('0x1134')]:null),_0xf7f5e8[_0x3e7dbb('0x258d')]={},_0xf7f5e8['selectedTab']=_0xee9b9f['params'][_0x3e7dbb('0x1904')]||0x0,_0xf7f5e8['changepassworddialog']=_0x202240,_0xf7f5e8[_0x3e7dbb('0x2430')]=_0x58c84b['info'],_0xf7f5e8['gotoTelephones']=_0x20c9bb,_0xf7f5e8[_0x3e7dbb('0xe4f')]=_0x555256,_0x3ac39f[_0x3e7dbb('0xca1')]('admin')?_0x3345ba[_0x3e7dbb('0x1e4d')][_0x3e7dbb('0x1e6e')]({'fields':_0x3e7dbb('0xa10'),'sort':'name'})[_0x3e7dbb('0xe53')][_0x3e7dbb('0x683')](function(_0x32647d){const _0x291dd2=_0x3e7dbb;_0xf7f5e8[_0x291dd2('0x1693')]=_0x32647d['rows']||[];})['catch'](function(_0x4413b7){const _0x58ff8a=_0x3e7dbb;_0x58c84b[_0x58ff8a('0x52a')]({'title':_0x4413b7[_0x58ff8a('0x13ee')]?_0x58ff8a('0x2168')+_0x4413b7[_0x58ff8a('0x13ee')]+_0x58ff8a('0xbf6')+_0x4413b7[_0x58ff8a('0x24a9')]:_0x58ff8a('0x1379'),'msg':_0x4413b7[_0x58ff8a('0x5a5')]?JSON['stringify'](_0x4413b7['data']):_0x4413b7['toString']()});}):_0x3345ba['voiceContext']['get']({'fields':_0x3e7dbb('0xa10'),'sort':_0x3e7dbb('0x60a')})[_0x3e7dbb('0xe53')]['then'](function(_0x51a294){const _0x423dee=_0x3e7dbb;_0xf7f5e8[_0x423dee('0x1693')]=_0x51a294[_0x423dee('0xf5d')]||[];})[_0x3e7dbb('0x683')](function(){const _0x5f4543=_0x3e7dbb;return _0x3345ba[_0x5f4543('0x22df')][_0x5f4543('0x1e6e')]({'userProfileId':_0xf7f5e8[_0x5f4543('0x11ed')][_0x5f4543('0x2f')],'sectionId':0x195})[_0x5f4543('0xe53')];})[_0x3e7dbb('0x683')](function(_0x1a1d94){const _0x56b4be=_0x3e7dbb,_0x2e6298=_0x1a1d94&&_0x1a1d94['rows']?_0x1a1d94[_0x56b4be('0xf5d')][0x0]:null;if(!_0x2e6298)return _0x3345ba[_0x56b4be('0x1e4d')]['get']({'fields':_0x56b4be('0xa10'),'sort':_0x56b4be('0x60a'),'defaultEntry':0x1})[_0x56b4be('0xe53')][_0x56b4be('0x683')](function(_0x57ddde){const _0xb70eb4=_0x56b4be;_0xf7f5e8['contexts']=_0x57ddde[_0xb70eb4('0xf5d')]||[];});else{if(!_0x2e6298[_0x56b4be('0x170')])return _0x3345ba['userProfileResource'][_0x56b4be('0x1e6e')]({'sectionId':_0x2e6298['id']})[_0x56b4be('0xe53')][_0x56b4be('0x683')](function(_0x1ec1b7){const _0x133351=_0x56b4be,_0x4fc244=_0x2e3ca0()[_0x133351('0x386')](_0x1ec1b7[_0x133351('0xf5d')],function(_0x53f157){const _0xa1f95=_0x133351;return _0x2e3ca0()['find'](_0xf7f5e8[_0xa1f95('0x1693')],{'id':_0x53f157['resourceId']});});let _0x2b271d=null;_0xf7f5e8[_0x133351('0x24d3')]&&(_0x2b271d=_0x2e3ca0()[_0x133351('0x1c07')](_0xf7f5e8['contexts'],{'name':_0xf7f5e8[_0x133351('0x24d3')][_0x133351('0x22d3')]}));if(_0x2b271d&&!_0x2e3ca0()[_0x133351('0x7a2')](_0x4fc244,['id',_0x2b271d['id']])){const _0x5a1990=_0x2e3ca0()[_0x133351('0x1c07')](_0xf7f5e8[_0x133351('0x1693')],{'id':_0x2b271d['id']});_0x5a1990[_0x133351('0x319')]=![],_0x4fc244['push'](_0x5a1990);}_0xf7f5e8['contexts']=_0x4fc244;});}})['catch'](function(_0x23ce96){const _0x4f6690=_0x3e7dbb;_0x58c84b[_0x4f6690('0x52a')]({'title':_0x23ce96[_0x4f6690('0x13ee')]?'API:'+_0x23ce96[_0x4f6690('0x13ee')]+_0x4f6690('0xbf6')+_0x23ce96[_0x4f6690('0x24a9')]:_0x4f6690('0x1a60'),'msg':_0x23ce96[_0x4f6690('0x5a5')]?JSON[_0x4f6690('0x258a')](_0x23ce96[_0x4f6690('0x5a5')]):_0x23ce96[_0x4f6690('0x1ff0')]()});});function _0x202240(_0x206027,_0x26aee9){const _0x43fb13=_0x3e7dbb;_0x32cfea[_0x43fb13('0x1d4')]({'controller':_0x43fb13('0x1146'),'controllerAs':'vm','templateUrl':_0x3cdd96,'parent':angular[_0x43fb13('0x1fcc')](_0x3d37b0[_0x43fb13('0x18e5')]),'targetEvent':_0x26aee9,'clickOutsideToClose':!![],'locals':{'telephone':_0x206027,'setting':_0x2e652f,'telephones':_0xf7f5e8['telephones']?_0xf7f5e8[_0x43fb13('0x723')][_0x43fb13('0xf5d')]:[],'crudPermissions':_0xf7f5e8[_0x43fb13('0x1134')]}});}function _0x20c9bb(){const _0x40a571=_0x3e7dbb;_0xee9b9f['go'](_0x40a571('0x1bde'),{},{'reload':_0x40a571('0x1bde')});}function _0x555256(){const _0xd00cb9=_0x3e7dbb;_0x3345ba['user'][_0xd00cb9('0x2480')]({'id':_0xf7f5e8[_0xd00cb9('0x24d3')]['id']},_0xf7f5e8[_0xd00cb9('0x24d3')])[_0xd00cb9('0xe53')][_0xd00cb9('0x683')](function(){const _0xe2771d=_0xd00cb9;_0x58c84b[_0xe2771d('0x53')]({'title':'Telephone\x20updated!','msg':_0xf7f5e8['telephone']['name']?_0xf7f5e8['telephone'][_0xe2771d('0x60a')]+_0xe2771d('0x96c'):''});})[_0xd00cb9('0x130a')](function(_0x399614){const _0x2965c3=_0xd00cb9;_0x58c84b['error']({'title':_0x399614['status']?_0x2965c3('0x2168')+_0x399614[_0x2965c3('0x13ee')]+_0x2965c3('0xbf6')+_0x399614['statusText']:_0x2965c3('0x23a4'),'msg':_0x399614[_0x2965c3('0x5a5')]?JSON[_0x2965c3('0x258a')](_0x399614['data']):_0x399614[_0x2965c3('0x1ff0')]()});});}}const _0x4817a9=_0x1eedd9,_0x4d80b2=_0x180212['p']+_0x189033('0x81f');_0x127949[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x723'),'userProfile',_0x189033('0x22df'),'api',_0x189033('0x1cc2'),'toasty',_0x189033('0xba1'),'license',_0x189033('0x260a')];function _0x127949(_0x421d52,_0x176376,_0x3390da,_0x216837,_0x12151b,_0x2ad2a3,_0x321687,_0x42ab44,_0x2ecf3f,_0x1dea97,_0x5e3c43,_0x271716,_0x4a5e8b,_0x510ebb,_0x218dbd,_0x220a08,_0x227c37){const _0x43db6d=_0x189033,_0x426542=this;_0x426542[_0x43db6d('0xace')]=_0x220a08,_0x426542[_0x43db6d('0x260a')]=_0x227c37,_0x426542[_0x43db6d('0x11ed')]=_0x218dbd[_0x43db6d('0x20b2')](),_0x426542[_0x43db6d('0x723')]=_0x2ecf3f||{'count':0x0,'rows':[]},_0x426542['userProfile']=_0x1dea97,_0x426542[_0x43db6d('0x22df')]=_0x5e3c43&&_0x5e3c43[_0x43db6d('0x50d')]==0x1?_0x5e3c43[_0x43db6d('0xf5d')][0x0]:null,_0x426542[_0x43db6d('0x1134')]=_0x218dbd[_0x43db6d('0x142a')](_0x426542[_0x43db6d('0x22df')]?_0x426542['userProfileSection'][_0x43db6d('0x1134')]:null),_0x426542[_0x43db6d('0x5c4')]='telephones',_0x426542[_0x43db6d('0x247')]='',_0x426542[_0x43db6d('0x1ce2')]=null,_0x426542['selectedTelephones']=[],_0x426542[_0x43db6d('0x23a2')]={'fields':_0x43db6d('0x2007'),'role':_0x43db6d('0x24d3'),'sort':_0x43db6d('0xc36'),'limit':0xa,'page':0x1},_0x426542[_0x43db6d('0xfb8')]=_0x2e3ca0()[_0x43db6d('0x24db')]([{'option':'udp','value':_0x43db6d('0x1c7')},{'option':_0x43db6d('0x1621'),'value':_0x43db6d('0xf6')},{'option':'ws','value':_0x43db6d('0x117e')},{'option':_0x43db6d('0x2615'),'value':_0x43db6d('0x26fa')},{'option':_0x43db6d('0x171f'),'value':_0x43db6d('0x9ee')}],function(_0x92a0f2){const _0x2382f4=_0x43db6d;return _0x2e3ca0()[_0x2382f4('0x1725')](_0x92a0f2[_0x2382f4('0x1c6b')],new RegExp('\x27','g'),'');}),_0x426542['arraynat']=_0x2e3ca0()[_0x43db6d('0x24db')]([{'option':'force_rport','value':_0x43db6d('0x20b7')},{'option':'comedia','value':'\x27comedia\x27'},{'option':_0x43db6d('0x7cd'),'value':_0x43db6d('0x2036')},{'option':'no','value':_0x43db6d('0x23ca')},{'option':'never','value':_0x43db6d('0xd77')},{'option':'route','value':_0x43db6d('0x23a6')}],function(_0x37fffe){const _0x38e0fa=_0x43db6d;return _0x2e3ca0()[_0x38e0fa('0x1725')](_0x37fffe[_0x38e0fa('0x1c6b')],new RegExp('\x27','g'),'');}),_0x426542[_0x43db6d('0x2673')]=_0x2e3ca0()[_0x43db6d('0x24db')]([{'option':_0x43db6d('0x5f4'),'value':'\x27ulaw\x27'},{'option':'alaw','value':'\x27alaw\x27'},{'option':_0x43db6d('0x1ac0'),'value':_0x43db6d('0x1755')},{'option':'g722','value':_0x43db6d('0x226b')},{'option':_0x43db6d('0x14bf'),'value':_0x43db6d('0x12a6')},{'option':'opus','value':_0x43db6d('0x2873')},{'option':_0x43db6d('0x6e6'),'value':'\x27h264\x27'}],function(_0x413d53){const _0x5afd25=_0x43db6d;return _0x2e3ca0()['replace'](_0x413d53[_0x5afd25('0x1c6b')],new RegExp('\x27','g'),'');}),_0x426542['arrayvideosupport']=_0x2e3ca0()[_0x43db6d('0x24db')]([{'option':'Yes','value':_0x43db6d('0x2036')},{'option':'No','value':_0x43db6d('0x23ca')},{'option':'Always','value':_0x43db6d('0x6c7')}],function(_0x37ed66){const _0x2b2a13=_0x43db6d;return _0x2e3ca0()['replace'](_0x37ed66[_0x2b2a13('0x1c6b')],new RegExp('\x27','g'),'');}),_0x426542[_0x43db6d('0x1d94')]=_0x2e3ca0()['keyBy']([{'option':_0x43db6d('0x7cd'),'value':_0x43db6d('0x2036')},{'option':'no','value':_0x43db6d('0x23ca')}],function(_0x39b651){const _0xa74bb8=_0x43db6d;return _0x2e3ca0()[_0xa74bb8('0x1725')](_0x39b651[_0xa74bb8('0x1c6b')],new RegExp('\x27','g'),'');}),_0x426542['editstate']=_0x5ee008,_0x426542[_0x43db6d('0x194f')]=_0x1cb993,_0x426542[_0x43db6d('0x53')]=_0x1139d7,_0x426542[_0x43db6d('0x16c')]=_0x4a6776,_0x426542[_0x43db6d('0x2580')]=_0x14a9fe,_0x426542[_0x43db6d('0x9bf')]=_0x9bd55f,_0x426542[_0x43db6d('0x911')]=_0x4be6f8,_0x426542[_0x43db6d('0x2604')]=_0x5ea731,_0x426542['deselectTelephones']=_0x16189e,_0x426542[_0x43db6d('0x168a')]=_0x1a7271;function _0x5ee008(_0x396720){const _0x2e21a0=_0x43db6d;_0x3390da['go'](_0x2e21a0('0x4a3'),{'id':_0x396720['id'],'telephone':_0x396720,'crudPermissions':_0x426542[_0x2e21a0('0x1134')]});}function _0x1cb993(_0x5f3a52,_0x2dc66e){const _0xf1e947=_0x43db6d,_0x12a710=_0x12151b[_0xf1e947('0x1c6f')]()[_0xf1e947('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0xf1e947('0x1e03')]('telephone')+'?')['htmlContent'](_0xf1e947('0xed5')+(_0x5f3a52[_0xf1e947('0x60a')]||_0xf1e947('0x24d3'))+_0xf1e947('0x20f1')+_0xf1e947('0x1ee7'))[_0xf1e947('0x1040')](_0xf1e947('0x1be4'))[_0xf1e947('0xe42')](_0x2dc66e)['ok']('OK')[_0xf1e947('0x19fb')](_0xf1e947('0x16b8'));_0x12151b[_0xf1e947('0x1d4')](_0x12a710)[_0xf1e947('0x683')](function(){_0x9bd55f(_0x5f3a52);},function(){const _0x2db974=_0xf1e947;console[_0x2db974('0x1b2b')](_0x2db974('0x16b8'));});}let _0x332200=!![],_0x58e7a6=0x1;_0x421d52[_0x43db6d('0x186d')]('vm.query.filter',function(_0x4be8ee,_0x1f4f82){const _0x3eb36b=_0x43db6d;_0x332200?_0x321687(function(){_0x332200=![];}):(!_0x1f4f82&&(_0x58e7a6=_0x426542[_0x3eb36b('0x23a2')]['page']),_0x4be8ee!==_0x1f4f82&&(_0x426542[_0x3eb36b('0x23a2')][_0x3eb36b('0xdf8')]=0x1),!_0x4be8ee&&(_0x426542[_0x3eb36b('0x23a2')][_0x3eb36b('0xdf8')]=_0x58e7a6),_0x426542[_0x3eb36b('0x16c')]());});function _0x1139d7(_0x59b1a9){const _0xdb3de0=_0x43db6d;_0x426542[_0xdb3de0('0x723')]=_0x59b1a9||{'count':0x0,'rows':[]};}function _0x4a6776(){const _0x12634c=_0x43db6d;_0x426542[_0x12634c('0x23a2')]['offset']=(_0x426542[_0x12634c('0x23a2')][_0x12634c('0xdf8')]-0x1)*_0x426542['query'][_0x12634c('0x6f0')],_0x218dbd[_0x12634c('0xca1')]('admin')?_0x426542[_0x12634c('0x1883')]=_0x271716[_0x12634c('0xc96')][_0x12634c('0x1e6e')](_0x426542[_0x12634c('0x23a2')],_0x1139d7)['$promise']:(_0x426542[_0x12634c('0x23a2')]['id']=_0x426542[_0x12634c('0x2a')]['id'],_0x426542[_0x12634c('0x23a2')][_0x12634c('0x1aa')]='Telephones',_0x426542[_0x12634c('0x1883')]=_0x271716['userProfile'][_0x12634c('0x241d')](_0x426542[_0x12634c('0x23a2')],_0x1139d7)[_0x12634c('0xe53')]);}function _0x14a9fe(_0x2ebd15,_0xed083){const _0x2d22ef=_0x43db6d;_0x12151b[_0x2d22ef('0x1d4')]({'controller':_0x2d22ef('0x1ab9'),'controllerAs':'vm','templateUrl':_0x4d80b2,'parent':angular[_0x2d22ef('0x1fcc')](_0x2ad2a3[_0x2d22ef('0x18e5')]),'targetEvent':_0x2ebd15,'clickOutsideToClose':!![],'locals':{'telephone':_0xed083,'telephones':_0x426542[_0x2d22ef('0x723')][_0x2d22ef('0xf5d')],'license':_0x426542[_0x2d22ef('0xace')],'setting':_0x426542['setting'],'crudPermissions':_0x426542['crudPermissions']}});}function _0x9bd55f(_0x105f53){const _0x3d37f3=_0x43db6d;_0x271716[_0x3d37f3('0xc96')][_0x3d37f3('0xd7e')]({'id':_0x105f53['id']})[_0x3d37f3('0xe53')]['then'](function(){const _0x543f92=_0x3d37f3;_0x2e3ca0()['remove'](_0x426542[_0x543f92('0x723')][_0x543f92('0xf5d')],{'id':_0x105f53['id']}),_0x426542[_0x543f92('0x723')]['count']-=0x1,!_0x426542[_0x543f92('0x723')][_0x543f92('0xf5d')][_0x543f92('0x1564')]&&_0x426542[_0x543f92('0x16c')](),_0x510ebb[_0x543f92('0x53')]({'title':_0x2e3ca0()[_0x543f92('0x1e03')](_0x543f92('0x12bf'))+_0x543f92('0xbfc'),'msg':_0x105f53[_0x543f92('0x60a')]?_0x105f53['name']+_0x543f92('0x194d'):''});})[_0x3d37f3('0x130a')](function(_0x724790){const _0x362c3b=_0x3d37f3;if(_0x724790[_0x362c3b('0x5a5')]&&_0x724790[_0x362c3b('0x5a5')][_0x362c3b('0x17f')]&&_0x724790[_0x362c3b('0x5a5')][_0x362c3b('0x17f')]['length']){_0x426542[_0x362c3b('0x17f')]=_0x724790['data'][_0x362c3b('0x17f')]||[{'message':_0x724790[_0x362c3b('0x1ff0')](),'type':'SYSTEM:DELETEuser'}];for(let _0x5118d3=0x0;_0x5118d3<_0x724790[_0x362c3b('0x5a5')][_0x362c3b('0x17f')][_0x362c3b('0x1564')];_0x5118d3++){_0x510ebb['error']({'title':_0x724790[_0x362c3b('0x5a5')]['errors'][_0x5118d3][_0x362c3b('0xcf0')],'msg':_0x724790[_0x362c3b('0x5a5')][_0x362c3b('0x17f')][_0x5118d3]['message']});}}else _0x510ebb['error']({'title':_0x724790['status']?_0x362c3b('0x2168')+_0x724790[_0x362c3b('0x13ee')]+_0x362c3b('0xbf6')+_0x724790[_0x362c3b('0x24a9')]:'SYSTEM:DELETEuser','msg':_0x724790[_0x362c3b('0x5a5')]?JSON[_0x362c3b('0x258a')](_0x724790['data'][_0x362c3b('0x8c2')]):_0x724790['message']||_0x724790[_0x362c3b('0x1ff0')]()});});}function _0x4be6f8(){const _0x25386e=_0x43db6d,_0x426c90=angular[_0x25386e('0x1a86')](_0x426542['selectedTelephones']);return _0x426542['selectedTelephones']=[],_0x426c90;}function _0x5ea731(_0x195d9a){const _0x3fdbc9=_0x43db6d,_0x31ee49=_0x12151b['confirm']()[_0x3fdbc9('0xf28')](_0x3fdbc9('0xc84'))['htmlContent'](''+_0x426542[_0x3fdbc9('0x260c')][_0x3fdbc9('0x1564')]+_0x3fdbc9('0x93c')+_0x3fdbc9('0x1ee7'))[_0x3fdbc9('0x1040')]('delete\x20Telephones')[_0x3fdbc9('0xe42')](_0x195d9a)['ok']('OK')['cancel']('CANCEL');_0x12151b['show'](_0x31ee49)[_0x3fdbc9('0x683')](function(){const _0x3d1af9=_0x3fdbc9;_0x426542['selectedTelephones'][_0x3d1af9('0x1299')](function(_0x141e73){_0x9bd55f(_0x141e73);}),_0x426542[_0x3d1af9('0x260c')]=[];});}function _0x16189e(){const _0x1a34cc=_0x43db6d;_0x426542[_0x1a34cc('0x260c')]=[];}function _0x1a7271(){const _0x28f1b1=_0x43db6d;_0x426542['selectedTelephones']=_0x426542[_0x28f1b1('0x723')][_0x28f1b1('0xf5d')];}}const _0x5e8f1b=_0x127949;_0x357233['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x134e'),'userProfile',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x357233(_0x128798,_0x54840d,_0x121d13,_0x3a7025,_0x536ba5,_0xe39179,_0x5d450b,_0x32cf67,_0x251d20,_0x4c2c44,_0x45e24c,_0x5dae4d,_0x4e2a0f,_0x4db935){const _0x6a22e3=_0x189033,_0x3b0512=this;_0x3b0512['currentUser']=_0x45e24c['getCurrentUser'](),_0x3b0512['errors']=[],_0x3b0512[_0x6a22e3('0x260a')]=_0x4e2a0f,_0x3b0512[_0x6a22e3('0xace')]=_0x5dae4d,_0x3b0512[_0x6a22e3('0x1134')]=_0x4db935,_0x3b0512['hasModulePermissions']={},_0x3b0512[_0x6a22e3('0x19b2')]=_0x3b0512[_0x6a22e3('0x260a')]&&_0x3b0512[_0x6a22e3('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3b0512[_0x6a22e3('0xf28')]=_0x6a22e3('0x1af7'),_0x3b0512[_0x6a22e3('0x2a')]=angular[_0x6a22e3('0x1a86')](_0x251d20),_0x3b0512[_0x6a22e3('0x134e')]=_0x32cf67,_0x3b0512[_0x6a22e3('0x762')]=![];!_0x3b0512['userProfile']&&(_0x3b0512['userProfile']={'crudPermissions':['r']},_0x3b0512[_0x6a22e3('0xf28')]='STAFF.NEW_USERPROFILE',_0x3b0512['newUserProfile']=!![]);_0x3b0512[_0x6a22e3('0x4c0')]=_0x523fdc,_0x3b0512[_0x6a22e3('0x1d40')]=_0x30fc76,_0x3b0512[_0x6a22e3('0x13fa')]=_0x525c52,_0x3b0512['getDateFromString']=_0x4a4257,_0x3b0512[_0x6a22e3('0xf82')]=_0x21dc4e;function _0x523fdc(){const _0x591ed4=_0x6a22e3;_0x3b0512[_0x591ed4('0x17f')]=[],_0x4c2c44[_0x591ed4('0x2a')][_0x591ed4('0xb0a')](_0x3b0512[_0x591ed4('0x2a')])[_0x591ed4('0xe53')][_0x591ed4('0x683')](function(_0x23b4b9){const _0x2bb449=_0x591ed4;_0x2ee252(_0x23b4b9),_0x3b0512['userProfiles'][_0x2bb449('0x1167')](_0x23b4b9[_0x2bb449('0x24e1')]()),_0x5d450b[_0x2bb449('0x53')]({'title':'UserProfile\x20properly\x20created','msg':_0x3b0512['userProfile'][_0x2bb449('0x60a')]?_0x3b0512[_0x2bb449('0x2a')][_0x2bb449('0x60a')]+_0x2bb449('0x14b5'):''}),_0x21dc4e(_0x23b4b9);})['catch'](function(_0x18ace4){const _0x41089d=_0x591ed4;if(_0x18ace4['data']&&_0x18ace4[_0x41089d('0x5a5')]['errors']&&_0x18ace4['data'][_0x41089d('0x17f')]['length']){_0x3b0512[_0x41089d('0x17f')]=_0x18ace4[_0x41089d('0x5a5')][_0x41089d('0x17f')]||[{'message':_0x18ace4[_0x41089d('0x1ff0')](),'type':_0x41089d('0x213f')}];for(let _0x119e14=0x0;_0x119e14<_0x18ace4[_0x41089d('0x5a5')][_0x41089d('0x17f')]['length'];_0x119e14+=0x1){_0x5d450b[_0x41089d('0x52a')]({'title':_0x18ace4[_0x41089d('0x5a5')][_0x41089d('0x17f')][_0x119e14][_0x41089d('0xcf0')],'msg':_0x18ace4[_0x41089d('0x5a5')][_0x41089d('0x17f')][_0x119e14][_0x41089d('0x8c2')]});}}else _0x5d450b[_0x41089d('0x52a')]({'title':_0x18ace4[_0x41089d('0x13ee')]?'API:'+_0x18ace4[_0x41089d('0x13ee')]+_0x41089d('0xbf6')+_0x18ace4[_0x41089d('0x24a9')]:_0x41089d('0x213f'),'msg':_0x18ace4['data']?JSON['stringify'](_0x18ace4[_0x41089d('0x5a5')]['message']):_0x18ace4[_0x41089d('0x1ff0')]()});});}function _0x30fc76(){const _0x25298d=_0x6a22e3;_0x3b0512[_0x25298d('0x17f')]=[],_0x4c2c44[_0x25298d('0x2a')][_0x25298d('0x2480')]({'id':_0x3b0512[_0x25298d('0x2a')]['id']},_0x3b0512[_0x25298d('0x2a')])[_0x25298d('0xe53')][_0x25298d('0x683')](function(_0x49dfaf){const _0x318d76=_0x25298d,_0x1516b4=_0x2e3ca0()['find'](_0x3b0512[_0x318d76('0x134e')],{'id':_0x49dfaf['id']});_0x1516b4&&_0x2e3ca0()[_0x318d76('0xf22')](_0x1516b4,_0x2e3ca0()[_0x318d76('0x24d0')](_0x49dfaf[_0x318d76('0x24e1')](),_0x2e3ca0()[_0x318d76('0x55e')](_0x1516b4))),_0x5d450b[_0x318d76('0x53')]({'title':_0x318d76('0x6c6'),'msg':_0x3b0512[_0x318d76('0x2a')]['name']?_0x3b0512[_0x318d76('0x2a')][_0x318d76('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x21dc4e(_0x49dfaf);})[_0x25298d('0x130a')](function(_0x5b8933){const _0x4f3018=_0x25298d;if(_0x5b8933[_0x4f3018('0x5a5')]&&_0x5b8933[_0x4f3018('0x5a5')][_0x4f3018('0x17f')]&&_0x5b8933[_0x4f3018('0x5a5')]['errors'][_0x4f3018('0x1564')]){_0x3b0512[_0x4f3018('0x17f')]=_0x5b8933[_0x4f3018('0x5a5')]['errors']||[{'message':_0x5b8933[_0x4f3018('0x1ff0')](),'type':_0x4f3018('0x35b')}];for(let _0x23d62a=0x0;_0x23d62a<_0x5b8933[_0x4f3018('0x5a5')][_0x4f3018('0x17f')][_0x4f3018('0x1564')];_0x23d62a++){_0x5d450b[_0x4f3018('0x52a')]({'title':_0x5b8933[_0x4f3018('0x5a5')][_0x4f3018('0x17f')][_0x23d62a][_0x4f3018('0xcf0')],'msg':_0x5b8933[_0x4f3018('0x5a5')][_0x4f3018('0x17f')][_0x23d62a][_0x4f3018('0x8c2')]});}}else _0x5d450b['error']({'title':_0x5b8933[_0x4f3018('0x13ee')]?_0x4f3018('0x2168')+_0x5b8933[_0x4f3018('0x13ee')]+_0x4f3018('0xbf6')+_0x5b8933[_0x4f3018('0x24a9')]:_0x4f3018('0x35b'),'msg':_0x5b8933[_0x4f3018('0x5a5')]?JSON[_0x4f3018('0x258a')](_0x5b8933[_0x4f3018('0x5a5')]['message']):_0x5b8933[_0x4f3018('0x1ff0')]()});});}function _0x525c52(_0x5afaf6){const _0x119099=_0x6a22e3;_0x3b0512['errors']=[];const _0x29ea48=_0x3a7025[_0x119099('0x1c6f')]()['title'](_0x119099('0x4d'))[_0x119099('0xa6a')]('The\x20userProfile\x20will\x20be\x20deleted.')[_0x119099('0x1040')](_0x119099('0x2380'))['ok'](_0x119099('0x2307'))[_0x119099('0x19fb')]('Cancel')[_0x119099('0xe42')](_0x5afaf6);_0x3a7025['show'](_0x29ea48)[_0x119099('0x683')](function(){const _0x1dac56=_0x119099;_0x4c2c44[_0x1dac56('0x2a')][_0x1dac56('0xd7e')]({'id':_0x3b0512[_0x1dac56('0x2a')]['id']})[_0x1dac56('0xe53')][_0x1dac56('0x683')](function(){const _0x1e1d04=_0x1dac56;_0x2e3ca0()[_0x1e1d04('0x3ec')](_0x3b0512[_0x1e1d04('0x134e')],{'id':_0x3b0512[_0x1e1d04('0x2a')]['id']}),_0x5d450b['success']({'title':_0x1e1d04('0x8b7'),'msg':(_0x3b0512['userProfile'][_0x1e1d04('0x60a')]||_0x1e1d04('0x2a'))+_0x1e1d04('0x194d')}),_0x21dc4e(_0x3b0512[_0x1e1d04('0x2a')]);})[_0x1dac56('0x130a')](function(_0x2eb313){const _0x495831=_0x1dac56;if(_0x2eb313[_0x495831('0x5a5')]&&_0x2eb313[_0x495831('0x5a5')][_0x495831('0x17f')]&&_0x2eb313[_0x495831('0x5a5')][_0x495831('0x17f')]['length']){_0x3b0512['errors']=_0x2eb313[_0x495831('0x5a5')][_0x495831('0x17f')]||[{'message':_0x2eb313[_0x495831('0x1ff0')](),'type':'api.userProfile.delete'}];for(let _0x2ff055=0x0;_0x2ff055<_0x2eb313[_0x495831('0x5a5')][_0x495831('0x17f')][_0x495831('0x1564')];_0x2ff055++){_0x5d450b[_0x495831('0x52a')]({'title':_0x2eb313[_0x495831('0x5a5')]['errors'][_0x2ff055][_0x495831('0xcf0')],'msg':_0x2eb313[_0x495831('0x5a5')][_0x495831('0x17f')][_0x2ff055]['message']});}}else _0x5d450b[_0x495831('0x52a')]({'title':_0x2eb313[_0x495831('0x13ee')]?'API:'+_0x2eb313[_0x495831('0x13ee')]+_0x495831('0xbf6')+_0x2eb313['statusText']:_0x495831('0x1fc6'),'msg':_0x2eb313[_0x495831('0x5a5')]?JSON[_0x495831('0x258a')](_0x2eb313[_0x495831('0x5a5')][_0x495831('0x8c2')]):_0x2eb313[_0x495831('0x8c2')]||_0x2eb313[_0x495831('0x1ff0')]()});});},function(){});}function _0x2ee252(_0x88fcae){const _0x1396a5=_0x6a22e3,_0x1d268d=[];_0x88fcae['crudPermissions'][_0x1396a5('0x1299')](function(_0x32449f){const _0x23c348=_0x1396a5;let _0xcb2659;switch(_0x32449f){case'r':_0xcb2659=_0x23c348('0x1a85');break;case'e':_0xcb2659=_0x23c348('0x1ad9');break;case'd':_0xcb2659='DELETE_PERMISSION';break;}_0x1d268d[_0x23c348('0x1fd0')](_0xe39179['instant'](_0x23c348('0x8c8')+_0xcb2659));}),_0x88fcae['selectedcrudPermissions']=_0x1d268d[_0x1396a5('0x1630')](',\x20');}function _0x4a4257(_0x5109e2){return _0x5109e2===null?undefined:new Date(_0x5109e2);}function _0x21dc4e(_0x399887){_0x3a7025['hide'](_0x399887);}}const _0x250a4c=_0x357233;_0xe86947[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x938'),_0x189033('0x1d70'),'api','userProfile',_0x189033('0x134e'),'$translate'];function _0xe86947(_0x1bafd2,_0x4da0b1,_0x5bae7b,_0x4d2b36,_0x2aaf21,_0x3fda6f,_0x131aeb){const _0x2eca01=_0x189033,_0x332419=this;_0x332419[_0x2eca01('0x762')]=!![],_0x332419[_0x2eca01('0x2a')]=angular[_0x2eca01('0x1a86')](_0x2aaf21),_0x332419['userProfiles']=_0x3fda6f,_0x332419[_0x2eca01('0xf28')]=_0x131aeb[_0x2eca01('0x2728')](_0x2eca01('0xfe3'));_0x2aaf21&&_0x2aaf21[_0x2eca01('0x60a')]&&(_0x332419['title']+=':\x20'+_0x2aaf21[_0x2eca01('0x60a')]);_0x332419['cloneUserProfile']=_0x1b8a63,_0x332419[_0x2eca01('0xf82')]=_0x45c9b0;function _0x1b8a63(){const _0x307de7=_0x2eca01;return _0x4d2b36[_0x307de7('0x2a')][_0x307de7('0x147f')]({'id':_0x2aaf21['id']},_0x332419[_0x307de7('0x2a')])[_0x307de7('0xe53')][_0x307de7('0x683')](function(_0x1afe26){const _0x5d6604=_0x307de7;_0x25e9af(_0x1afe26),_0x332419[_0x5d6604('0x134e')][_0x5d6604('0x1167')](_0x1afe26['toJSON']()),_0x5bae7b[_0x5d6604('0x53')]({'title':_0x5d6604('0x25ff'),'msg':_0x332419[_0x5d6604('0x2a')][_0x5d6604('0x60a')]?_0x332419[_0x5d6604('0x2a')][_0x5d6604('0x60a')]+_0x5d6604('0x640'):''}),_0x4da0b1['go'](_0x5d6604('0xf6b'),{'id':_0x1afe26['id']}),_0x45c9b0(_0x1afe26);})['catch'](function(_0x5a41eb){const _0xfe3018=_0x307de7;if(_0x5a41eb[_0xfe3018('0x5a5')]&&_0x5a41eb[_0xfe3018('0x5a5')][_0xfe3018('0x17f')]&&_0x5a41eb[_0xfe3018('0x5a5')]['errors'][_0xfe3018('0x1564')]){_0x332419[_0xfe3018('0x17f')]=_0x5a41eb['data'][_0xfe3018('0x17f')]||[{'message':_0x5a41eb[_0xfe3018('0x1ff0')](),'type':_0xfe3018('0x1d25')}];for(let _0x2e54ea=0x0;_0x2e54ea<_0x5a41eb[_0xfe3018('0x5a5')][_0xfe3018('0x17f')][_0xfe3018('0x1564')];_0x2e54ea+=0x1){_0x5bae7b['error']({'title':_0x5a41eb[_0xfe3018('0x5a5')][_0xfe3018('0x17f')][_0x2e54ea]['type'],'msg':_0x5a41eb['data'][_0xfe3018('0x17f')][_0x2e54ea][_0xfe3018('0x8c2')]});}}else _0x5bae7b[_0xfe3018('0x52a')]({'title':_0x5a41eb[_0xfe3018('0x13ee')]?_0xfe3018('0x2168')+_0x5a41eb[_0xfe3018('0x13ee')]+'\x20-\x20'+_0x5a41eb[_0xfe3018('0x24a9')]:_0xfe3018('0x1d25'),'msg':_0x5a41eb[_0xfe3018('0x5a5')]?JSON[_0xfe3018('0x258a')](_0x5a41eb[_0xfe3018('0x5a5')][_0xfe3018('0x8c2')]):_0x5a41eb['toString']()});});}function _0x25e9af(_0x1669ef){const _0x17050a=_0x2eca01,_0x4ca033=[];_0x1669ef[_0x17050a('0x1134')][_0x17050a('0x1299')](function(_0x3d5f35){const _0xac53b2=_0x17050a;let _0x322f52;switch(_0x3d5f35){case'r':_0x322f52=_0xac53b2('0x1a85');break;case'e':_0x322f52=_0xac53b2('0x1ad9');break;case'd':_0x322f52='DELETE_PERMISSION';break;}_0x4ca033[_0xac53b2('0x1fd0')](_0x131aeb[_0xac53b2('0x2728')](_0xac53b2('0x8c8')+_0x322f52));}),_0x1669ef[_0x17050a('0x16f5')]=_0x4ca033[_0x17050a('0x1630')](',\x20');}function _0x45c9b0(_0x4197a5){const _0x2fe613=_0x2eca01;_0x1bafd2[_0x2fe613('0x1715')](_0x4197a5);}}const _0x10b7a8=_0xe86947,_0x433c2f=_0x180212['p']+_0x189033('0x772');_0x582ce2[_0x189033('0x14be')]=['$document','$mdDialog','$translate','$q',_0x189033('0x56b'),'msNavigationService',_0x189033('0xba1'),_0x189033('0x1d70')];function _0x582ce2(_0x4f8aa6,_0xbb0b8e,_0x17494d,_0x37ff7c,_0x1860cc,_0x1589de,_0x1d5fc2,_0x64e4d4){const _0x1b568b=_0x189033,_0x365572=this;_0x365572[_0x1b568b('0x2a')]={},_0x365572[_0x1b568b('0xace')]={},_0x365572[_0x1b568b('0x21ad')]=_0x1589de[_0x1b568b('0x2bc')](),_0x365572[_0x1b568b('0x12bc')]=_0x365572[_0x1b568b('0x21ad')][0x0][_0x1b568b('0x62')],_0x365572[_0x1b568b('0x1c13')]=[{'id':0x0,'name':_0x1b568b('0x218f'),'color':_0x1b568b('0xb3c'),'info':_0x1b568b('0x12ec'),'tag':_0x1b568b('0x15f7')},{'id':0x1,'name':_0x1b568b('0x629'),'color':_0x1b568b('0x413'),'info':'Some\x20resources\x20enabled','tag':_0x1b568b('0x996')},{'id':0x2,'name':_0x1b568b('0x216a'),'color':_0x1b568b('0x21e'),'info':_0x1b568b('0x218c'),'tag':'disabled'},{'id':0x3,'name':_0x1b568b('0x279'),'color':_0x1b568b('0x1ec8'),'info':_0x1b568b('0xbc2'),'tag':_0x1b568b('0x1175')},{'id':0x4,'name':_0x1b568b('0x969'),'color':_0x1b568b('0x1316'),'info':_0x1b568b('0x1974'),'tag':_0x1b568b('0xdd4')}],_0x365572['dashboardSections']=[{'title':_0x1b568b('0x17ab'),'translate':_0x1b568b('0x151f'),'id':0x64}],_0x365572[_0x1b568b('0x12f3')]=_0x56e6fe,_0x365572[_0x1b568b('0x163c')]=_0x336ad1,_0x365572['manageResources']=_0x5df198,_0x365572[_0x1b568b('0x11d6')]=_0x1e509f;function _0x56e6fe(_0x575642,_0x33286d){const _0x372183=_0x1b568b;_0x365572[_0x372183('0x2a')]=_0x575642,_0x365572[_0x372183('0xace')]=_0x33286d;}function _0x336ad1(_0x5780b7){const _0x1618b0=_0x1b568b,_0x26a38b=typeof _0x5780b7[_0x1618b0('0x924')]!==_0x1618b0('0x1867')&&!_0x5780b7['permissions'][_0x1618b0('0x645')]?!![]:![],_0x2d42e0=_0x5780b7[_0x1618b0('0xf28')]===_0x1618b0('0x1926')?_0x1618b0('0x17a'):_0x5780b7['title'];if(_0x5780b7[_0x1618b0('0x13ee')]['name']!=='Fully\x20Enabled'){const _0x34e989=[];if(!_0x26a38b){const _0x1c41b2=_0xbb0b8e['confirm']({'skipHide':!![]})[_0x1618b0('0xf28')](_0x1618b0('0x128f'))['textContent'](_0x17494d['instant'](_0x1618b0('0x1af8'),{'sectionName':_0x17494d[_0x1618b0('0x2728')](_0x5780b7['translate'])}))['ariaLabel'](_0x1618b0('0x128f'))['ok'](_0x17494d[_0x1618b0('0x2728')](_0x1618b0('0x1213')))[_0x1618b0('0x19fb')](_0x17494d[_0x1618b0('0x2728')](_0x1618b0('0x23bf')));_0xbb0b8e[_0x1618b0('0x1d4')](_0x1c41b2)[_0x1618b0('0x683')](function(){const _0x36fb12=_0x1618b0;switch(_0x2d42e0){case _0x36fb12('0x17ab'):_0x2e3ca0()[_0x36fb12('0x386')](_0x365572[_0x36fb12('0x1aa2')],function(_0x381e44){const _0x2d3fa0=_0x36fb12;_0x34e989[_0x2d3fa0('0x1fd0')]({'category':_0x2d42e0,'sectionId':_0x381e44['id'],'name':_0x381e44[_0x2d3fa0('0xf28')],'enabled':!![],'autoAssociation':!![],'crudPermissions':_0x2e3ca0()[_0x2d3fa0('0x386')](_0x365572['userProfile'][_0x2d3fa0('0x1134')])[_0x2d3fa0('0x1630')]('')});});break;default:_0x2e3ca0()['map'](_0x5780b7['children'],function(_0x538ded){const _0x5ed0d8=_0x36fb12,_0x4f75be=typeof _0x538ded[_0x5ed0d8('0x924')]!=_0x5ed0d8('0x1867')&&_0x538ded[_0x5ed0d8('0x924')][_0x5ed0d8('0x1fb4')]?!![]:![];if(!_0x4f75be){let _0x5e850f=_0x538ded[_0x5ed0d8('0xf28')];switch(_0x2d42e0){case'CallySquare':_0x5e850f=_0x5e850f==='Projects'?_0x5ed0d8('0x2506'):_0x5e850f;break;}_0x34e989[_0x5ed0d8('0x1fd0')]({'category':_0x2d42e0,'sectionId':_0x538ded['id'],'name':_0x5e850f,'enabled':!![],'autoAssociation':!![],'crudPermissions':_0x2e3ca0()[_0x5ed0d8('0x386')](_0x365572['userProfile'][_0x5ed0d8('0x1134')])[_0x5ed0d8('0x1630')]('')});}});break;}return _0x1860cc[_0x36fb12('0x2a')][_0x36fb12('0x2804')]({'id':_0x365572[_0x36fb12('0x2a')]['id']},_0x34e989)[_0x36fb12('0xe53')][_0x36fb12('0x683')](function(){const _0x3a53ad=_0x36fb12;_0x5780b7['status']=_0x35eec2(_0x5780b7,_0x3a53ad('0x15f7')),_0x64e4d4[_0x3a53ad('0x53')]({'title':_0x17494d['instant'](_0x3a53ad('0xc7b'),{'sectionName':_0x17494d[_0x3a53ad('0x2728')](_0x5780b7['translate']),'userProfileName':_0x365572['userProfile']['name']}),'msg':_0x17494d[_0x3a53ad('0x2728')](_0x3a53ad('0x24fe'),{'sectionName':_0x17494d[_0x3a53ad('0x2728')](_0x5780b7['translate']),'userProfileName':_0x365572['userProfile'][_0x3a53ad('0x60a')]})});});})[_0x1618b0('0x130a')](function(_0x447167){const _0x1e07a1=_0x1618b0;_0x447167?_0x64e4d4[_0x1e07a1('0x52a')]({'title':_0x447167['status']?_0x1e07a1('0x2168')+_0x447167[_0x1e07a1('0x13ee')]+_0x1e07a1('0xbf6')+_0x447167[_0x1e07a1('0x24a9')]:_0x1e07a1('0x1828'),'msg':_0x447167[_0x1e07a1('0x13ee')]?JSON['stringify'](_0x447167['data']):_0x447167['toString']()}):_0x5780b7['status']=_0x35eec2(_0x5780b7,_0x5780b7[_0x1e07a1('0x13ee')][_0x1e07a1('0x270')]);});}else return _0x34e989['push']({'category':_0x2d42e0,'sectionId':_0x5780b7['id'],'name':_0x2d42e0,'enabled':!![],'crudPermissions':_0x1618b0('0x22b')}),_0x1860cc[_0x1618b0('0x2a')][_0x1618b0('0x2804')]({'id':_0x365572[_0x1618b0('0x2a')]['id']},_0x34e989)[_0x1618b0('0xe53')][_0x1618b0('0x683')](function(){const _0x1b050b=_0x1618b0;_0x5780b7[_0x1b050b('0x13ee')]=_0x35eec2(_0x5780b7,'full'),_0x64e4d4[_0x1b050b('0x53')]({'title':_0x17494d['instant'](_0x1b050b('0xc7b'),{'sectionName':_0x17494d[_0x1b050b('0x2728')](_0x5780b7[_0x1b050b('0x14ab')]),'userProfileName':_0x365572['userProfile']['name']}),'msg':_0x17494d[_0x1b050b('0x2728')](_0x1b050b('0x102f'),{'sectionName':_0x17494d[_0x1b050b('0x2728')](_0x5780b7[_0x1b050b('0x14ab')]),'userProfileName':_0x365572[_0x1b050b('0x2a')]['name']})});})[_0x1618b0('0x130a')](function(_0x5acc24){const _0x87afba=_0x1618b0;_0x64e4d4['error']({'title':_0x5acc24[_0x87afba('0x13ee')]?'API:'+_0x5acc24[_0x87afba('0x13ee')]+_0x87afba('0xbf6')+_0x5acc24[_0x87afba('0x24a9')]:_0x87afba('0x1828'),'msg':_0x5acc24[_0x87afba('0x13ee')]?JSON[_0x87afba('0x258a')](_0x5acc24['data']):_0x5acc24[_0x87afba('0x1ff0')]()});});}else{if(_0x5780b7[_0x1618b0('0x13ee')][_0x1618b0('0x60a')]===_0x1618b0('0x218f')){_0x5780b7[_0x1618b0('0x13ee')]=_0x35eec2(_0x5780b7,_0x1618b0('0x120b'));let _0xef0043=[];switch(_0x2d42e0){case _0x1618b0('0x1fc9'):case _0x1618b0('0x151e'):_0xef0043=[_0x5780b7['id']];break;case _0x1618b0('0x17ab'):_0xef0043=_0x2e3ca0()[_0x1618b0('0x386')](_0x365572[_0x1618b0('0x1aa2')],function(_0x51ca89){return _0x51ca89['id'];});break;default:_0xef0043=_0x2e3ca0()[_0x1618b0('0x386')](_0x5780b7[_0x1618b0('0x62')],function(_0x2f56cc){return _0x2f56cc['id'];});break;}return _0x1860cc[_0x1618b0('0x2a')][_0x1618b0('0x557')]({'id':_0x365572[_0x1618b0('0x2a')]['id'],'ids':_0xef0043})['$promise'][_0x1618b0('0x683')](function(){const _0x507779=_0x1618b0;_0x64e4d4[_0x507779('0x53')]({'title':_0x17494d[_0x507779('0x2728')](_0x507779('0x1ad7'),{'sectionName':_0x17494d[_0x507779('0x2728')](_0x5780b7[_0x507779('0x14ab')]),'userProfileName':_0x365572['userProfile'][_0x507779('0x60a')]}),'msg':_0x17494d[_0x507779('0x2728')](_0x507779('0x202a'),{'sectionName':_0x17494d[_0x507779('0x2728')](_0x5780b7[_0x507779('0x14ab')]),'userProfileName':_0x365572[_0x507779('0x2a')][_0x507779('0x60a')]})});})[_0x1618b0('0x130a')](function(_0x19e86e){const _0x4d4e32=_0x1618b0;_0x64e4d4[_0x4d4e32('0x52a')]({'title':_0x19e86e[_0x4d4e32('0x13ee')]?'API:'+_0x19e86e[_0x4d4e32('0x13ee')]+'\x20-\x20'+_0x19e86e[_0x4d4e32('0x24a9')]:_0x4d4e32('0x1b88'),'msg':_0x19e86e['status']?JSON[_0x4d4e32('0x258a')](_0x19e86e[_0x4d4e32('0x5a5')]):_0x19e86e[_0x4d4e32('0x1ff0')]()});});}}}function _0x5df198(_0x4e2294,_0x485056){const _0x595402=_0x1b568b,_0x41241c=_0xbb0b8e[_0x595402('0x1d4')]({'controller':_0x595402('0x1547'),'controllerAs':'vm','templateUrl':_0x433c2f,'parent':angular[_0x595402('0x1fcc')](_0x4f8aa6[_0x595402('0x18e5')]),'targetEvent':_0x485056,'clickOutsideToClose':![],'locals':{'userProfile':_0x365572[_0x595402('0x2a')],'userProfiles':[],'section':_0x4e2294}});_0x41241c[_0x595402('0x683')](function(){_0x1e509f(_0x4e2294);});}function _0x35eec2(_0x2dc626,_0x6b32e4){const _0x2460db=_0x1b568b;_0x2dc626[_0x2460db('0x2266')]=_0x5042dd(_0x6b32e4);switch(_0x6b32e4){case _0x2460db('0x15f7'):return _0x2e3ca0()['find'](_0x365572[_0x2460db('0x1c13')],[_0x2460db('0x270'),'full']);case _0x2460db('0x996'):return _0x2e3ca0()['find'](_0x365572[_0x2460db('0x1c13')],[_0x2460db('0x270'),'partial']);case'disabled':return _0x2e3ca0()['find'](_0x365572[_0x2460db('0x1c13')],[_0x2460db('0x270'),_0x2460db('0x120b')]);case _0x2460db('0x1175'):return _0x2e3ca0()[_0x2460db('0x1c07')](_0x365572[_0x2460db('0x1c13')],['tag',_0x2460db('0x1175')]);case'unknown':return _0x2e3ca0()[_0x2460db('0x1c07')](_0x365572[_0x2460db('0x1c13')],[_0x2460db('0x270'),_0x2460db('0xdd4')]);default:return _0x2e3ca0()[_0x2460db('0x1c07')](_0x365572[_0x2460db('0x1c13')],[_0x2460db('0x270'),_0x2460db('0xdd4')]);}}function _0x2fa06f(_0x5443b5){return _0x37ff7c(function(_0x1cfae5,_0x4d147b){const _0x346010=a0_0x4e0a,_0x59efd7=typeof _0x5443b5[_0x346010('0xdd6')]!=='undefined'&&_0x2e3ca0()[_0x346010('0x2292')](_0x5443b5[_0x346010('0x20ed')],_0x346010('0x1fa'));_0x59efd7?_0x1f2454(_0x5443b5)[_0x346010('0x683')](function(_0x43b4cd){_0x1cfae5(_0x43b4cd);})[_0x346010('0x130a')](function(_0x234938){_0x4d147b(_0x234938);}):_0x30cc48(_0x5443b5)[_0x346010('0x683')](function(_0x872e9b){_0x1cfae5(_0x872e9b);})[_0x346010('0x130a')](function(_0x413cb1){_0x4d147b(_0x413cb1);});});}function _0x1f2454(_0x29f30b){return _0x37ff7c(function(_0x491983,_0x3a7d54){const _0x271c98=a0_0x4e0a,_0x75f9bb=typeof _0x29f30b[_0x271c98('0xdd6')]!==_0x271c98('0x1867')&&_0x29f30b['channel']==='bull'?_0x271c98('0x17cd'):'inbound';return _0x1860cc[_0x29f30b[_0x271c98('0x20ed')]][_0x271c98('0x1e6e')]({'fields':_0x271c98('0x5fb'),'channel':_0x29f30b[_0x271c98('0xdd6')]===_0x271c98('0x5d9')?_0x271c98('0xcf2'):_0x29f30b['channel'],'type':_0x75f9bb,'nolimit':!![]})[_0x271c98('0xe53')][_0x271c98('0x683')](function(_0x121f67){_0x491983(_0x121f67);})[_0x271c98('0x130a')](function(_0x57c5a4){_0x3a7d54(_0x57c5a4);});});}function _0x30cc48(_0x931089){return _0x37ff7c(function(_0xbcb675,_0x231344){const _0x18a4d0=a0_0x4e0a;let _0x6246c8,_0x1a875c,_0x4a5c83=![],_0x213cac=![];switch(_0x931089[_0x18a4d0('0x20ed')]){case _0x18a4d0('0x14cb'):switch(_0x931089[_0x18a4d0('0xf28')]){case _0x18a4d0('0x1b63'):_0x6246c8=_0x18a4d0('0x1535');break;case _0x18a4d0('0x2e3'):_0x6246c8=_0x18a4d0('0x17cd');break;case'InternalRoutes':_0x6246c8=_0x18a4d0('0x1d43');break;}break;case _0x18a4d0('0x115c'):_0x4a5c83=!![];break;case'disposition':_0x213cac=!![];break;case'user':switch(_0x931089[_0x18a4d0('0xf28')]){case _0x18a4d0('0x1bc0'):_0x1a875c=_0x18a4d0('0x2327');break;case _0x18a4d0('0x193e'):_0x1a875c=_0x18a4d0('0x24d3');break;case _0x18a4d0('0x2139'):_0x1a875c=_0x18a4d0('0xc96');break;}break;}if(_0x931089[_0x18a4d0('0xf28')]===_0x18a4d0('0x1172')){if(_0x931089[_0x18a4d0('0x750')])switch(_0x931089[_0x18a4d0('0x750')]){case'default':_0x931089['route']=_0x18a4d0('0x20ec');break;case _0x18a4d0('0xbf0'):_0x931089[_0x18a4d0('0x20ed')]=_0x18a4d0('0x197f');break;}else return _0x1860cc[_0x18a4d0('0x20ec')][_0x18a4d0('0x1e6e')]({'nolimit':!![]})[_0x18a4d0('0xe53')][_0x18a4d0('0x683')](function(_0x2bcba6){const _0x474d0c=_0x18a4d0;_0x1860cc[_0x474d0c('0x197f')][_0x474d0c('0x1e6e')]({'nolimit':!![]})[_0x474d0c('0xe53')][_0x474d0c('0x683')](function(_0x4b7d5c){const _0x5b85f3=_0x474d0c,_0x20d2af=_0x2e3ca0()['union'](_0x2bcba6[_0x5b85f3('0xf5d')],_0x4b7d5c[_0x5b85f3('0xf5d')]);_0xbcb675({'count':_0x20d2af[_0x5b85f3('0x1564')],'rows':_0x20d2af[_0x5b85f3('0xf5d')]});});})[_0x18a4d0('0x130a')](function(_0x437f39){_0x231344(_0x437f39);});}return _0x1860cc[_0x931089[_0x18a4d0('0x20ed')]][_0x18a4d0('0x1e6e')]({'role':_0x1a875c?_0x1a875c:undefined,'type':_0x6246c8?_0x6246c8:undefined,'VoiceExtensionId':_0x6246c8?_0x18a4d0('0x13c'):undefined,'IntervalId':_0x4a5c83?_0x18a4d0('0x13c'):undefined,'MailAccountId':_0x213cac?_0x18a4d0('0x13c'):undefined,'FaxAccountId':_0x213cac?_0x18a4d0('0x13c'):undefined,'SmsAccountId':_0x213cac?'null':undefined,'OpenchannelAccountId':_0x213cac?'null':undefined,'ChatWebsiteId':_0x213cac?_0x18a4d0('0x13c'):undefined,'WhatsappAccountId':_0x213cac?_0x18a4d0('0x13c'):undefined,'ListId':_0x213cac?_0x18a4d0('0x13c'):undefined,'nolimit':!![]})[_0x18a4d0('0xe53')]['then'](function(_0x3a1476){_0xbcb675(_0x3a1476);})[_0x18a4d0('0x130a')](function(_0x281d71){_0x231344(_0x281d71);});});}function _0x50f9cf(_0x175f37,_0x108d38){return _0x37ff7c(function(_0x134222,_0x243645){const _0x30d629=a0_0x4e0a;_0x1860cc[_0x30d629('0xcf7')][_0x30d629('0x1e6e')]({'sectionId':_0x108d38})[_0x30d629('0xe53')][_0x30d629('0x683')](function(_0x552f3c){const _0xa74788=_0x30d629;return _0x2fa06f(_0x175f37)[_0xa74788('0x683')](function(_0x25af67){const _0x1c016c=_0xa74788;return _0x2e3ca0()[_0x1c016c('0x461')](_0x552f3c[_0x1c016c('0xf5d')],_0x25af67['rows'],'id');});})[_0x30d629('0x683')](function(_0x2a5611){const _0x407708=_0x30d629;_0x2e3ca0()[_0x407708('0x173f')](_0x2a5611)?_0x134222():_0x243645();})['catch'](function(_0x3a7496){_0x243645(_0x3a7496);});});}function _0x38da74(_0x39da55,_0xbe3c66,_0x2a4f40){const _0x153ba7=_0x1b568b,_0x4b26ef=_0x39da55&&_0x39da55['length']>0x0?_0x39da55[0x0]:null;if(!_0x4b26ef)return _0x2a4f40;const _0x2b3ad5=_0x2e3ca0()[_0x153ba7('0x1c07')](_0xbe3c66,['sectionId',_0x4b26ef['id']]);if(_0x2b3ad5)return _0xbe3c66=_0x2e3ca0()[_0x153ba7('0x3ec')](_0xbe3c66,['sectionId',_0x4b26ef['id']]),_0x50f9cf(_0x4b26ef,_0x2b3ad5['id'])[_0x153ba7('0x683')](function(){const _0x304981=_0x153ba7;return _0x2a4f40=_0x304981('0x15f7'),_0x38da74(_0x39da55[_0x304981('0x2723')](),_0xbe3c66,_0x2a4f40);})['catch'](function(_0x27a7ed){return _0x37ff7c['reject'](_0x27a7ed);});}function _0x1e509f(_0x14cf4b){const _0x195a6a=_0x1b568b,_0x1a4b1f=_0x14cf4b['title']===_0x195a6a('0x1926')?_0x195a6a('0x17a'):_0x14cf4b[_0x195a6a('0xf28')];if(!_0x365572[_0x195a6a('0xace')]){_0x14cf4b['status']=_0x35eec2(_0x14cf4b,_0x195a6a('0xdd4'));return;}typeof _0x14cf4b[_0x195a6a('0x924')]!==_0x195a6a('0x1867')&&!_0x14cf4b['permissions']['association']?_0x1860cc[_0x195a6a('0x22df')][_0x195a6a('0x1e6e')]({'userProfileId':_0x365572['userProfile']['id'],'sectionId':_0x14cf4b['id']})[_0x195a6a('0xe53')]['then'](function(_0x272441){const _0x4ddc03=_0x195a6a,_0x4f19f3=_0x272441&&_0x272441[_0x4ddc03('0xf5d')][_0x4ddc03('0x1564')]===0x1?_0x272441['rows'][0x0]:null,_0x5f2ae9=_0x4f19f3?_0x4ddc03('0x15f7'):_0x4ddc03('0x120b');_0x14cf4b['status']=_0x35eec2(_0x14cf4b,_0x5f2ae9);}):typeof _0x14cf4b[_0x195a6a('0xace')]!==_0x195a6a('0x1867')&&!_0x365572[_0x195a6a('0xace')][_0x14cf4b[_0x195a6a('0xace')]]?_0x14cf4b[_0x195a6a('0x13ee')]=_0x35eec2(_0x14cf4b,'unlicensed'):_0x1860cc[_0x195a6a('0x22df')]['get']({'userProfileId':_0x365572[_0x195a6a('0x2a')]['id'],'category':_0x1a4b1f})[_0x195a6a('0xe53')][_0x195a6a('0x683')](function(_0x35731c){const _0x53c770=_0x195a6a,_0xec2758=_0x35731c&&_0x35731c[_0x53c770('0xf5d')]&&_0x35731c[_0x53c770('0xf5d')][_0x53c770('0x1564')]>0x0?_0x35731c[_0x53c770('0xf5d')]:[];if(_0x14cf4b['title']===_0x53c770('0x17ab'))return _0x2e3ca0()['isEmpty'](_0xec2758)?'disabled':_0xec2758[0x0][_0x53c770('0x170')]?'full':_0x1860cc[_0x53c770('0xcf7')][_0x53c770('0x1e6e')]({'sectionId':_0xec2758[0x0]['id'],'resourceId':0x65})[_0x53c770('0xe53')][_0x53c770('0x683')](function(_0x1ae302){const _0x118398=_0x53c770,_0x3d5e89=_0x1ae302&&_0x1ae302[_0x118398('0xf5d')]?_0x1ae302[_0x118398('0xf5d')][0x0]:null;return _0x3d5e89?_0x118398('0x15f7'):'partial';});else{const _0x3c9675=_0x2e3ca0()['filter'](_0x14cf4b['children'],function(_0x7da83e){const _0x46bde7=_0x53c770;return typeof _0x7da83e[_0x46bde7('0x924')]!==_0x46bde7('0x1867')&&_0x7da83e['permissions']['hidden']?undefined:_0x7da83e;});if(_0xec2758['length']===_0x3c9675['length']){if(_0x2e3ca0()[_0x53c770('0x161')](_0xec2758,[_0x53c770('0x170'),!![]]))return _0x53c770('0x15f7');else{const _0x2a0534=_0x2e3ca0()['filter'](_0x3c9675,function(_0x2bb95a){const _0x21e7f5=_0x53c770;return typeof _0x2bb95a['permissions']!==_0x21e7f5('0x1867')&&!_0x2bb95a[_0x21e7f5('0x924')][_0x21e7f5('0x645')]?undefined:_0x2bb95a;});return _0x38da74(_0x2a0534,_0xec2758,_0x53c770('0x996'));}}else return _0xec2758['length']===0x0?_0x53c770('0x120b'):_0x53c770('0x996');}})[_0x195a6a('0x683')](function(_0x39f13e){_0x14cf4b['status']=_0x35eec2(_0x14cf4b,_0x39f13e);})[_0x195a6a('0x130a')](function(_0x57b0bd){const _0x52afe7=_0x195a6a,_0xa8661a=_0x57b0bd?_0x52afe7('0xdd4'):_0x52afe7('0x996');_0x14cf4b[_0x52afe7('0x13ee')]=_0x35eec2(_0x14cf4b,_0xa8661a),_0x57b0bd&&_0x64e4d4[_0x52afe7('0x52a')]({'title':_0x57b0bd[_0x52afe7('0x13ee')]?_0x52afe7('0x2168')+_0x57b0bd[_0x52afe7('0x13ee')]+'\x20-\x20'+_0x57b0bd[_0x52afe7('0x24a9')]:_0x52afe7('0x230c')+_0x1a4b1f[_0x52afe7('0x80')]()+')','msg':_0x57b0bd[_0x52afe7('0x13ee')]?JSON[_0x52afe7('0x258a')](_0x57b0bd[_0x52afe7('0x5a5')]):_0x57b0bd[_0x52afe7('0x1ff0')]()});});}function _0x5042dd(_0x2e1603){const _0x3d66a9=_0x1b568b;return _0x2e1603===_0x3d66a9('0x15f7')?!![]:![];}}const _0x343a01=_0x582ce2;_0x23b950[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x2a'),_0x189033('0x134e'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1aa')];function _0x23b950(_0x30335b,_0x307e0a,_0x460481,_0x2c888f,_0x1affdc,_0x5a9d33,_0x36cf77,_0x43d16b,_0x1075f7,_0x21e652){const _0x38414e=_0x189033,_0x19383b=this;_0x19383b[_0x38414e('0x2a')]=_0x5a9d33,_0x19383b[_0x38414e('0x1e2a')]=0x0,_0x19383b[_0x38414e('0x1aa')]=angular[_0x38414e('0x1a86')](_0x21e652),_0x19383b['title']=_0x43d16b[_0x38414e('0x2728')](_0x38414e('0xf44'),{'sectionName':_0x43d16b[_0x38414e('0x2728')](_0x19383b[_0x38414e('0x1aa')][_0x38414e('0x14ab')])}),_0x19383b[_0x38414e('0x1996')]=[],_0x19383b[_0x38414e('0x1378')]=[],_0x19383b[_0x38414e('0x31')]=_0x2e3ca0()['filter'](_0x19383b[_0x38414e('0x1aa')][_0x38414e('0x62')],function(_0x521a97){const _0x4b3e08=_0x38414e;return typeof _0x521a97['permissions']!=_0x4b3e08('0x1867')&&_0x521a97[_0x4b3e08('0x924')][_0x4b3e08('0x1fb4')]?undefined:_0x521a97;}),_0x19383b[_0x38414e('0x1aa2')]=[{'title':_0x38414e('0x17ab'),'translate':'DASHBOARDS.DASHBOARDS','id':0x64}],_0x19383b[_0x38414e('0x1fdc')]=[];_0x19383b[_0x38414e('0x1aa')]['title']===_0x38414e('0x17ab')&&(_0x19383b[_0x38414e('0x1fdc')]=_0x19383b[_0x38414e('0x31')],_0x19383b[_0x38414e('0x31')]=_0x19383b[_0x38414e('0x1aa2')]);_0x19383b[_0x38414e('0x1a22')]=null,_0x19383b[_0x38414e('0x185f')]=null,_0x19383b[_0x38414e('0x1abf')]=[],_0x19383b[_0x38414e('0xf82')]=_0x5de8be,_0x19383b['onChangeSection']=_0x17ef52,_0x19383b[_0x38414e('0x398')]=_0x52d492,_0x19383b[_0x38414e('0x1a0e')]=_0x1851ed,_0x19383b[_0x38414e('0x2796')]=_0xf8003d,_0x19383b['setPermission']=_0x216d87,_0x19383b[_0x38414e('0x1d87')]=_0x1461a4,_0x19383b['dualMultiselectOptions']={'readOnly':![],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x38414e('0x60a'),'line1':_0x38414e('0x60a'),'line2':'','line3':'','line4':_0x38414e('0x1f5f'),'labelAll':_0x43d16b[_0x38414e('0x2728')](_0x38414e('0x22e')),'labelSelected':_0x43d16b[_0x38414e('0x2728')]('STAFF.PERMISSIONS_SELECTED_RESOURCES'),'labelSearch':_0x43d16b[_0x38414e('0x2728')]('STAFF.PERMISSIONS_PLACEHOLDER_SEARCH'),'transferCallback':function(_0x46d1cd,_0xd7b498){const _0x131b1c=_0x38414e;_0xeda437(!![]),_0xd7b498?(_0x19383b[_0x131b1c('0x1a22')][_0x131b1c('0x1378')]=_0x2e3ca0()['pullAllBy'](_0x19383b[_0x131b1c('0x1a22')][_0x131b1c('0x1378')],_0x46d1cd,'id'),_0x19383b['selectedSection'][_0x131b1c('0x170')]=![]):_0x19383b[_0x131b1c('0x1a22')]['selectedItems']=_0x2e3ca0()['unionBy'](_0x19383b[_0x131b1c('0x1a22')][_0x131b1c('0x1378')],_0x46d1cd,'id'),_0x19383b[_0x131b1c('0x1a22')][_0x131b1c('0xf28')]==='Reports'&&_0x36e3e5();}};function _0xbb3165(){return _0x460481(function(_0x134fb7,_0x15c962){const _0x4de579=a0_0x4e0a,_0x3808dd=typeof _0x19383b['selectedSection'][_0x4de579('0xdd6')]!=='undefined'&&_0x19383b[_0x4de579('0x1a22')][_0x4de579('0xdd6')]==='bull'?_0x4de579('0x17cd'):_0x4de579('0x1535');return _0x1affdc[_0x19383b[_0x4de579('0x1a22')][_0x4de579('0x20ed')]]['get']({'fields':_0x4de579('0x5fb'),'channel':_0x19383b[_0x4de579('0x1a22')][_0x4de579('0xdd6')]===_0x4de579('0x5d9')?_0x4de579('0xcf2'):_0x19383b[_0x4de579('0x1a22')][_0x4de579('0xdd6')],'type':_0x3808dd,'nolimit':!![]})[_0x4de579('0xe53')][_0x4de579('0x683')](function(_0x498a27){_0x134fb7(_0x498a27);})['catch'](function(_0x45eae1){_0x15c962(_0x45eae1);});});}function _0x150679(){return _0x460481(function(_0x3921fc,_0x27bfd2){const _0x2ca56a=a0_0x4e0a;let _0x5762c8,_0x43aee4,_0x80690f=![],_0x13979d=![];if(_0x19383b[_0x2ca56a('0x1a22')]['route']===_0x2ca56a('0x14cb'))switch(_0x19383b['selectedSection'][_0x2ca56a('0xf28')]){case _0x2ca56a('0x1b63'):_0x5762c8=_0x2ca56a('0x1535');break;case'OutboundRoutes':_0x5762c8=_0x2ca56a('0x17cd');break;case _0x2ca56a('0x26c8'):_0x5762c8=_0x2ca56a('0x1d43');break;}if(_0x19383b[_0x2ca56a('0x1a22')][_0x2ca56a('0x20ed')]===_0x2ca56a('0xc96'))switch(_0x19383b[_0x2ca56a('0x1a22')][_0x2ca56a('0xf28')]){case'Agents':_0x43aee4='agent';break;case'Telephones':_0x43aee4='telephone';break;case _0x2ca56a('0x2139'):_0x43aee4=_0x2ca56a('0xc96');break;}_0x19383b[_0x2ca56a('0x1a22')]['route']===_0x2ca56a('0x115c')&&(_0x80690f=!![]);_0x19383b[_0x2ca56a('0x1a22')][_0x2ca56a('0x20ed')]==='disposition'&&(_0x13979d=!![]);_0x19383b[_0x2ca56a('0x1a22')][_0x2ca56a('0xf28')]==='Reports'&&(_0x19383b[_0x2ca56a('0x1a22')][_0x2ca56a('0x20ed')]=_0x19383b[_0x2ca56a('0x1a22')][_0x2ca56a('0x750')]===_0x2ca56a('0x9cb')?_0x2ca56a('0x20ec'):'analyticCustomReport');if(_0x19383b[_0x2ca56a('0x1a22')][_0x2ca56a('0xf28')]==='Dashboards')_0x3921fc({'count':0x1,'rows':[{'id':0x65,'name':_0x43d16b[_0x2ca56a('0x2728')](_0x2ca56a('0x13bb'))}]});else return _0x1affdc[_0x19383b[_0x2ca56a('0x1a22')][_0x2ca56a('0x20ed')]]['get']({'role':_0x43aee4?_0x43aee4:undefined,'type':_0x5762c8?_0x5762c8:undefined,'VoiceExtensionId':_0x5762c8?_0x2ca56a('0x13c'):undefined,'IntervalId':_0x80690f?'null':undefined,'MailAccountId':_0x13979d?'null':undefined,'FaxAccountId':_0x13979d?_0x2ca56a('0x13c'):undefined,'SmsAccountId':_0x13979d?_0x2ca56a('0x13c'):undefined,'OpenchannelAccountId':_0x13979d?'null':undefined,'ChatWebsiteId':_0x13979d?_0x2ca56a('0x13c'):undefined,'WhatsappAccountId':_0x13979d?'null':undefined,'ListId':_0x13979d?'null':undefined,'nolimit':!![]})[_0x2ca56a('0xe53')][_0x2ca56a('0x683')](function(_0x6cd42b){_0x3921fc(_0x6cd42b);})[_0x2ca56a('0x130a')](function(_0x2598fe){_0x27bfd2(_0x2598fe);});});}function _0xf220c4(){const _0x17c3b9=_0x38414e,_0x3028c2=typeof _0x19383b[_0x17c3b9('0x1a22')]['pending']!=_0x17c3b9('0x1867')?_0x19383b['selectedSection'][_0x17c3b9('0xd71')]:![];return _0x460481(function(_0xed089d,_0xb9666e){const _0x58d796=_0x17c3b9;_0x1affdc[_0x58d796('0x22df')][_0x58d796('0x1e6e')]({'userProfileId':_0x19383b[_0x58d796('0x2a')]['id'],'sectionId':_0x19383b[_0x58d796('0x1a22')]['id']})[_0x58d796('0xe53')][_0x58d796('0x683')](function(_0x3845b7){const _0x97b2c5=_0x58d796,_0x1f0b53=_0x3845b7&&_0x3845b7['rows']?_0x3845b7[_0x97b2c5('0xf5d')][0x0]:null;!_0x3028c2&&(_0x19383b[_0x97b2c5('0x1a22')]['enabled']=_0x1f0b53?!!_0x1f0b53[_0x97b2c5('0x1333')]:![],_0x19383b[_0x97b2c5('0x1a22')][_0x97b2c5('0x170')]=_0x1f0b53?!!_0x1f0b53[_0x97b2c5('0x170')]:![],_0x19383b[_0x97b2c5('0x1a22')][_0x97b2c5('0x1134')]=_0x1f0b53?_0x3023b5(_0x1f0b53[_0x97b2c5('0x1134')]):_0x3023b5(_0x19383b[_0x97b2c5('0x2a')][_0x97b2c5('0x1134')])),_0xed089d(_0x1f0b53);})[_0x58d796('0x130a')](function(_0x28db13){_0xb9666e(_0x28db13);});});}function _0x1af3f3(){return _0x460481(function(_0x1a5d1f,_0x5b33ce){const _0x59e954=a0_0x4e0a;!_0x19383b[_0x59e954('0x185f')]?_0x1a5d1f(null):_0x1affdc[_0x59e954('0xcf7')][_0x59e954('0x1e6e')]({'sectionId':_0x19383b[_0x59e954('0x185f')]['id'],'nolimit':!![]})[_0x59e954('0xe53')][_0x59e954('0x683')](function(_0x26d073){_0x1a5d1f(_0x26d073);})[_0x59e954('0x130a')](function(_0x54853f){_0x5b33ce(_0x54853f);});});}function _0x389af6(){return _0x460481(function(_0x496e05,_0x49c428){const _0x3684b0=a0_0x4e0a,_0x4f715d=typeof _0x19383b[_0x3684b0('0x1a22')][_0x3684b0('0xdd6')]!==_0x3684b0('0x1867')&&_0x2e3ca0()[_0x3684b0('0x2292')](_0x19383b[_0x3684b0('0x1a22')]['route'],_0x3684b0('0x1fa'));_0x4f715d?_0xbb3165()[_0x3684b0('0x683')](function(_0x4c3ae4){_0x496e05(_0x4c3ae4);})[_0x3684b0('0x130a')](function(_0x462f4e){_0x49c428(_0x462f4e);}):_0x150679()['then'](function(_0x54494c){_0x496e05(_0x54494c);})[_0x3684b0('0x130a')](function(_0x3cf55c){_0x49c428(_0x3cf55c);});});}function _0x48a24c(){const _0x10af1c=_0x38414e,_0x442001=typeof _0x19383b[_0x10af1c('0x1a22')]['pending']!=_0x10af1c('0x1867')?_0x19383b[_0x10af1c('0x1a22')][_0x10af1c('0xd71')]:![];let _0x2296d9=[];return _0x1af3f3()[_0x10af1c('0x683')](function(_0x1297ca){const _0x269d6e=_0x10af1c;return _0x2296d9=_0x1297ca&&_0x1297ca['rows']?_0x1297ca['rows']:[],_0x19383b[_0x269d6e('0x1a22')][_0x269d6e('0xf28')]===_0x269d6e('0x1172')&&(_0x19383b[_0x269d6e('0x1f1e')]=!_0x19383b['associatedReports']?_0x2296d9:_0x19383b[_0x269d6e('0x1f1e')],_0x2296d9=_0xea1103(_0x19383b[_0x269d6e('0x1f1e')])),typeof _0x19383b[_0x269d6e('0x1a22')][_0x269d6e('0x924')]!==_0x269d6e('0x1867')&&!_0x19383b[_0x269d6e('0x1a22')]['permissions']['association']?{'rows':[]}:_0x389af6();})['then'](function(_0x4b4d02){const _0x40ad16=_0x10af1c;_0x19383b['items']=_0x4b4d02[_0x40ad16('0xf5d')]?_0x2e3ca0()[_0x40ad16('0x386')](_0x4b4d02[_0x40ad16('0xf5d')],function(_0x38279e){const _0x6e0f80=_0x40ad16;return _0x19383b[_0x6e0f80('0x1a22')][_0x6e0f80('0xf28')]==='Reports'&&(_0x38279e[_0x6e0f80('0x1f5f')]=_0x2ce273(_0x38279e[_0x6e0f80('0x2361')])[_0x6e0f80('0x1725')]('\x20','_')),_0x38279e[_0x6e0f80('0x24f4')]=!![],_0x38279e;}):[];!_0x442001&&(_0x19383b[_0x40ad16('0x1a22')][_0x40ad16('0x1378')]=_0x2e3ca0()['map'](_0x2296d9,function(_0x39a430){const _0x2dc024=_0x40ad16;return _0x2e3ca0()[_0x2dc024('0x1c07')](_0x19383b[_0x2dc024('0x1996')],{'id':_0x39a430[_0x2dc024('0x832')]});}));const _0x4d9b48=_0x2e3ca0()[_0x40ad16('0x461')](_0x19383b[_0x40ad16('0x1a22')][_0x40ad16('0x1378')],_0x19383b[_0x40ad16('0x1996')],'id');!_0x2e3ca0()[_0x40ad16('0x173f')](_0x4d9b48)&&(_0x19383b[_0x40ad16('0x1a22')][_0x40ad16('0x1378')]=_0x2e3ca0()['pullAllBy'](_0x19383b[_0x40ad16('0x1a22')]['selectedItems'],_0x4d9b48,'id'));let _0x130ddd;switch(_0x19383b['selectedSection'][_0x40ad16('0xf28')]){case'Contexts':_0x19383b[_0x40ad16('0x1a22')][_0x40ad16('0x1378')]=_0x2e3ca0()['filter'](_0x19383b[_0x40ad16('0x1996')],function(_0x3231bf){const _0x579033=_0x40ad16;if(_0x3231bf[_0x579033('0xfce')])return _0x3231bf[_0x579033('0x24f4')]=![],_0x3231bf;else{const _0x42b76a=_0x2e3ca0()[_0x579033('0x1c07')](_0x2296d9,{'resourceId':_0x3231bf['id']});if(typeof _0x42b76a!==_0x579033('0x1867'))return _0x3231bf[_0x579033('0x24f4')]=!![],_0x3231bf;}});break;case _0x40ad16('0x27d2'):_0x19383b[_0x40ad16('0x1a22')]['selectedItems']=_0x2e3ca0()[_0x40ad16('0x25')](_0x19383b[_0x40ad16('0x1996')],function(_0x233dc9){const _0x15f979=_0x40ad16;if(_0x233dc9['defaultEntry'])return _0x233dc9[_0x15f979('0x24f4')]=![],_0x233dc9;else{const _0x5a7f78=_0x2e3ca0()[_0x15f979('0x1c07')](_0x2296d9,{'resourceId':_0x233dc9['id']});if(typeof _0x5a7f78!==_0x15f979('0x1867'))return _0x233dc9[_0x15f979('0x24f4')]=!![],_0x233dc9;}});break;case'Reports':_0x130ddd=_0x5e0224(_0x19383b[_0x40ad16('0x1abf')]),_0x19383b[_0x40ad16('0x1a22')][_0x40ad16('0x1378')]=_0x3d4b18(_0x19383b['selectedSection'][_0x40ad16('0x1378')]),_0x19383b[_0x40ad16('0x1a22')]['selectedItems']=_0x2e3ca0()[_0x40ad16('0x41c')](_0x19383b[_0x40ad16('0x1a22')][_0x40ad16('0x1378')],_0x130ddd,'id');break;}_0x19383b[_0x40ad16('0x169f')][_0x40ad16('0x1378')]=_0x19383b[_0x40ad16('0x1a22')][_0x40ad16('0x1378')],_0x19383b[_0x40ad16('0x169f')]['items']=_0x2e3ca0()['differenceBy'](_0x19383b['items'],_0x19383b[_0x40ad16('0x169f')][_0x40ad16('0x1378')],'id');})[_0x10af1c('0x130a')](function(_0xfc3c60){const _0x2a9486=_0x10af1c;_0x2c888f[_0x2a9486('0x52a')]({'title':_0xfc3c60['status']?'API:'+_0xfc3c60[_0x2a9486('0x13ee')]+_0x2a9486('0xbf6')+_0xfc3c60[_0x2a9486('0x24a9')]:_0x2a9486('0x3d4')+_0x19383b[_0x2a9486('0x1a22')][_0x2a9486('0xf28')][_0x2a9486('0x80')](),'msg':_0xfc3c60[_0x2a9486('0x13ee')]?JSON['stringify'](_0xfc3c60[_0x2a9486('0x5a5')]):_0xfc3c60[_0x2a9486('0x1ff0')]()});});}function _0x17ef52(){const _0x4c9458=_0x38414e;return _0xf220c4()[_0x4c9458('0x683')](function(_0x5c6426){const _0x1bb5ca=_0x4c9458;_0x19383b['loadedSection']=_0x5c6426;if(_0x19383b['selectedSection']['title']===_0x1bb5ca('0x1172'))return _0x364275()[_0x1bb5ca('0x683')](function(){const _0x23e42b=_0x1bb5ca;if(!_0x19383b[_0x23e42b('0x1a22')][_0x23e42b('0x750')])return _0x1af3f3()['then'](function(_0x20fc32){const _0x4f520a=_0x23e42b;_0x19383b[_0x4f520a('0x1abf')]=_0x20fc32?_0x2e3ca0()['map'](_0x20fc32[_0x4f520a('0xf5d')],function(_0x2b7036){const _0x139619=_0x4f520a;return{'id':_0x2b7036[_0x139619('0x832')],'name':_0x2b7036[_0x139619('0x60a')],'type':_0x2b7036['type']};}):[];});})[_0x1bb5ca('0x130a')](function(_0x5e715d){const _0x5b937a=_0x1bb5ca;_0x2c888f[_0x5b937a('0x52a')]({'title':_0x5e715d['status']?_0x5b937a('0x2168')+_0x5e715d[_0x5b937a('0x13ee')]+_0x5b937a('0xbf6')+_0x5e715d[_0x5b937a('0x24a9')]:_0x5b937a('0xf50'),'msg':_0x5e715d[_0x5b937a('0x5a5')]?JSON[_0x5b937a('0x258a')](_0x5e715d[_0x5b937a('0x5a5')]):_0x5e715d[_0x5b937a('0x1ff0')]()});});else _0x48a24c();})[_0x4c9458('0x130a')](function(_0x165313){const _0x41e68b=_0x4c9458;_0x2c888f[_0x41e68b('0x52a')]({'title':_0x165313['status']?'API:'+_0x165313['status']+'\x20-\x20'+_0x165313[_0x41e68b('0x24a9')]:'SYSTEM:GET'+_0x19383b[_0x41e68b('0x1a22')][_0x41e68b('0xf28')][_0x41e68b('0x80')](),'msg':_0x165313[_0x41e68b('0x13ee')]?JSON[_0x41e68b('0x258a')](_0x165313[_0x41e68b('0x5a5')]):_0x165313[_0x41e68b('0x1ff0')]()});});}function _0x3023b5(_0x3464ba){const _0x3c93f0=_0x38414e;return _0x3464ba&&(_0x19383b[_0x3c93f0('0x1a22')][_0x3c93f0('0x14d')]=_0x2e3ca0()[_0x3c93f0('0x2292')](_0x3464ba,'e')?!![]:![],_0x19383b[_0x3c93f0('0x1a22')][_0x3c93f0('0xe00')]=_0x2e3ca0()[_0x3c93f0('0x2292')](_0x3464ba,'d')?!![]:![]),_0x1f4a2c();}function _0x1f4a2c(){const _0x3b53a7=_0x38414e,_0x2e2075=['r'];if(_0x19383b[_0x3b53a7('0x1a22')][_0x3b53a7('0x14d')])_0x2e2075[_0x3b53a7('0x1fd0')]('e');else{const _0x45688d=_0x2e3ca0()[_0x3b53a7('0x824')](_0x2e2075,['e']);_0x45688d>0x0&&_0x19383b[_0x3b53a7('0x1a22')][_0x3b53a7('0x1134')][_0x3b53a7('0x1725')]('e','');}if(_0x19383b[_0x3b53a7('0x1a22')][_0x3b53a7('0xe00')])_0x2e2075[_0x3b53a7('0x1fd0')]('d');else{const _0x34378c=_0x2e3ca0()[_0x3b53a7('0x824')](_0x2e2075,['d']);_0x34378c>0x0&&_0x19383b[_0x3b53a7('0x1a22')][_0x3b53a7('0x1134')][_0x3b53a7('0x1725')]('d','');}return _0x2e2075;}function _0x52d492(){const _0x318a44=_0x38414e;_0x19383b[_0x318a44('0x1a22')][_0x318a44('0x1333')]=!_0x19383b['selectedSection']['enabled'],_0xeda437(!![]);}function _0x1851ed(){const _0x4b5838=_0x38414e;if(!_0x19383b[_0x4b5838('0x1a22')][_0x4b5838('0x170')]){const _0x5d80d6=[];for(let _0x41f60e=0x0;_0x41f60e<_0x19383b[_0x4b5838('0x169f')][_0x4b5838('0x1996')][_0x4b5838('0x1564')];_0x41f60e++){_0x5d80d6['push'](_0x19383b[_0x4b5838('0x169f')][_0x4b5838('0x1996')][_0x41f60e]),_0x19383b['dualMultiselectOptions'][_0x4b5838('0x1378')][_0x4b5838('0x1fd0')](_0x19383b['dualMultiselectOptions'][_0x4b5838('0x1996')][_0x41f60e]);}_0x19383b[_0x4b5838('0x169f')]['items']=[],_0x19383b['dualMultiselectOptions']['transferCallback'](_0x5d80d6,![]);}_0xeda437(!![]);}function _0xf8003d(){const _0x3cd370=_0x38414e;_0x19383b['treeStructure']=_0x2d2ea6(),_0x19383b[_0x3cd370('0x1a22')][_0x3cd370('0x1378')]&&(_0x19383b[_0x3cd370('0x1abf')]=_0x3d4b18(_0x19383b[_0x3cd370('0x1abf')]),_0x36e3e5()),_0x48a24c();}function _0x216d87(_0x5176d8){const _0x999513=_0x38414e;if(_0x5176d8===_0x999513('0x1319'))_0x19383b[_0x999513('0x1a22')][_0x999513('0x14d')]=!_0x19383b[_0x999513('0x1a22')][_0x999513('0x14d')];else _0x5176d8===_0x999513('0xd7e')&&(_0x19383b['selectedSection'][_0x999513('0xe00')]=!_0x19383b[_0x999513('0x1a22')][_0x999513('0xe00')]);_0x19383b[_0x999513('0x1a22')][_0x999513('0x1134')]=_0x3023b5(),_0xeda437(!![]);}function _0x1461a4(){const _0x938421=_0x38414e,_0x23086e=_0x19383b[_0x938421('0x1aa')][_0x938421('0xf28')]==='Marketplace'?_0x938421('0x17a'):_0x19383b['section'][_0x938421('0xf28')],_0x39073d=_0x2e3ca0()(_0x19383b[_0x938421('0x31')])[_0x938421('0x25')]({'pending':!![]})[_0x938421('0x386')](function(_0x515efa){const _0xc80c23=_0x938421,_0x34d6ea=_0x23086e===_0xc80c23('0x4ef')&&_0x515efa[_0xc80c23('0xf28')]===_0xc80c23('0x25c3')?_0xc80c23('0x2506'):_0x515efa[_0xc80c23('0xf28')],_0x57e457=_0x34d6ea===_0xc80c23('0x1172')?_0x19383b[_0xc80c23('0x1abf')]:_0x515efa['selectedItems'];return _0x23086e==='Integrations'&&(_0x515efa[_0xc80c23('0x170')]=!![]),{'category':_0x23086e,'sectionId':_0x515efa['id'],'name':_0x34d6ea,'enabled':_0x515efa[_0xc80c23('0x1333')],'autoAssociation':_0x515efa[_0xc80c23('0x170')],'crudPermissions':_0x2e3ca0()[_0xc80c23('0x386')](_0x515efa[_0xc80c23('0x1134')])['join'](''),'Resources':_0x2e3ca0()[_0xc80c23('0x386')](_0x57e457,function(_0x363578){const _0x5b769c=_0xc80c23;return{'name':_0x363578[_0x5b769c('0x60a')],'resourceId':_0x363578['id'],'type':_0x3acb5c(_0x34d6ea,_0x363578)};})};})['value']();return _0x1affdc['userProfile'][_0x938421('0x2804')]({'id':_0x19383b[_0x938421('0x2a')]['id']},_0x39073d)[_0x938421('0xe53')]['then'](function(){const _0x2b8a29=_0x938421;_0x19383b[_0x2b8a29('0x31')]['forEach'](function(_0x44789b){const _0x4d57a4=_0x2b8a29;_0x44789b[_0x4d57a4('0xd71')]=undefined;}),_0x19383b[_0x2b8a29('0x1f1e')]=null,_0x49c3e6(),_0x19383b['selectedSection'][_0x2b8a29('0xf28')]===_0x2b8a29('0x1172')&&!_0x19383b['selectedSection'][_0x2b8a29('0x750')]&&_0x30335b['userProfileForm'][_0x2b8a29('0x272a')](),_0x2c888f[_0x2b8a29('0x53')]({'title':_0x43d16b[_0x2b8a29('0x2728')](_0x2b8a29('0x2499'),{'sectionName':_0x43d16b[_0x2b8a29('0x2728')](_0x23086e[_0x2b8a29('0x14ab')])}),'msg':_0x43d16b[_0x2b8a29('0x2728')](_0x2b8a29('0xf9b'))});})[_0x938421('0x683')](function(){return _0xf220c4()['then'](function(_0x2baae8){const _0x4580df=a0_0x4e0a;_0x19383b[_0x4580df('0x185f')]=_0x2baae8;});})[_0x938421('0x130a')](function(_0x175e82){const _0x318aa3=_0x938421;_0x2c888f['error']({'title':_0x175e82[_0x318aa3('0x13ee')]?'API:'+_0x175e82[_0x318aa3('0x13ee')]+_0x318aa3('0xbf6')+_0x175e82['statusText']:_0x318aa3('0x1828'),'msg':_0x175e82[_0x318aa3('0x13ee')]?JSON[_0x318aa3('0x258a')](_0x175e82[_0x318aa3('0x5a5')]):_0x175e82[_0x318aa3('0x1ff0')]()});});}function _0xeda437(_0x339b8d){const _0x7bdf81=_0x38414e,_0x13fe4a=_0x2e3ca0()[_0x7bdf81('0x1ce4')](_0x19383b[_0x7bdf81('0x31')],function(_0x1953d0){const _0x35c9db=_0x7bdf81;return _0x1953d0['id']==_0x19383b[_0x35c9db('0x1a22')]['id'];});_0x19383b[_0x7bdf81('0x31')][_0x13fe4a][_0x7bdf81('0xd71')]=_0x339b8d,_0x49c3e6();}function _0x49c3e6(){const _0x216e68=_0x38414e;return _0x19383b['pendingChanges']=_0x2e3ca0()['some'](_0x19383b[_0x216e68('0x31')],[_0x216e68('0xd71'),!![]]);}function _0x2d2ea6(){const _0x7fc529=_0x38414e;let _0x3ded30={};return _0x19383b[_0x7fc529('0x1a22')]['reportType']===_0x7fc529('0x9cb')?_0x3ded30=_0x19383b[_0x7fc529('0x1c99')][0x0]?angular[_0x7fc529('0x1cb2')](_0x19383b[_0x7fc529('0x1c99')][0x0]['tree']):[]:_0x3ded30=_0x19383b[_0x7fc529('0x1c99')][0x1]?angular[_0x7fc529('0x1cb2')](_0x19383b[_0x7fc529('0x1c99')][0x1][_0x7fc529('0x2eb')]):[],_0x3ded30;}function _0x364275(){return _0x460481(function(_0x22790e,_0x1a5410){const _0x2a8310=a0_0x4e0a;_0x1affdc[_0x2a8310('0x1aaf')]['get']({})[_0x2a8310('0xe53')]['then'](function(_0x18f9da){const _0xec4f83=_0x2a8310;_0x19383b['treeReports']=_0x18f9da[_0xec4f83('0xf5d')]||[],_0x22790e(_0x19383b[_0xec4f83('0x1c99')]);})[_0x2a8310('0x130a')](function(_0x4dd64c){_0x1a5410(_0x4dd64c);});});}function _0x2ce273(_0x2e6836){const _0x470325=_0x38414e;let _0x335b80=_0x19383b[_0x470325('0x58e')][0x0][_0x470325('0x1bcd')];return _0x335b80=_0x20cdcd(_0x335b80,_0x2e6836,_0x19383b['treeStructure'][0x0]),_0x335b80;}function _0x20cdcd(_0x2e4295,_0x5f3255,_0x212484){const _0x27be19=_0x38414e;if(_0x212484&&!_0x2e3ca0()['isEmpty'](_0x212484[_0x27be19('0x62')]))_0x212484=_0x2e3ca0()[_0x27be19('0x1c07')](_0x212484[_0x27be19('0x62')],function(_0x4eb031){return _0x2e3ca0()['includes'](_0x5f3255,_0x4eb031['id'])?_0x4eb031:undefined;}),_0x2e4295+=_0x212484?'/'+_0x212484[_0x27be19('0x1bcd')]:'';else return _0x2e4295;return _0x20cdcd(_0x2e4295,_0x5f3255,_0x212484);}function _0xea1103(_0x528cc1){const _0xa12e9d=_0x38414e;return _0x2e3ca0()[_0xa12e9d('0x25')](_0x528cc1,{'type':_0x19383b['selectedSection'][_0xa12e9d('0x750')]==='default'?_0xa12e9d('0xbbb'):_0xa12e9d('0x1a3c')});}function _0x5e0224(_0x215467){const _0x3ee94c=_0x38414e;return _0x2e3ca0()[_0x3ee94c('0x25')](_0x215467,function(_0x37815e){const _0x46796e=_0x3ee94c;return _0x2e3ca0()[_0x46796e('0x18ad')](_0x37815e[_0x46796e('0x2361')],_0x19383b['selectedSection']['reportType']===_0x46796e('0x9cb')?_0x46796e('0xe83'):_0x46796e('0xbf0'));});}function _0x3d4b18(_0x87c07){const _0x487044=_0x38414e;return _0x2e3ca0()[_0x487044('0x3ec')](_0x87c07,function(_0x1eafef){const _0x21a7d4=_0x487044;return _0x2e3ca0()[_0x21a7d4('0x18ad')](_0x1eafef[_0x21a7d4('0x2361')],_0x19383b['selectedSection'][_0x21a7d4('0x750')]===_0x21a7d4('0x9cb')?_0x21a7d4('0xe83'):_0x21a7d4('0xbf0'));});}function _0x36e3e5(){const _0x593d0f=_0x38414e;_0x2e3ca0()['isEmpty'](_0x19383b[_0x593d0f('0x1a22')][_0x593d0f('0x1378')])?_0x19383b[_0x593d0f('0x1abf')]=_0x2e3ca0()[_0x593d0f('0x3ec')](_0x19383b['allReportsSelected'],function(_0x499da4){const _0x24daae=_0x593d0f;return _0x499da4[_0x24daae('0xcf0')]===(_0x19383b['selectedSection'][_0x24daae('0x750')]===_0x24daae('0x9cb')?'CustomReports':_0x24daae('0xbbb'));}):_0x19383b[_0x593d0f('0x1a22')][_0x593d0f('0x1378')][_0x593d0f('0x1299')](function(_0x27df01){const _0x5aae7f=_0x593d0f,_0x2c1910=_0x2e3ca0()['some'](_0x19383b[_0x5aae7f('0x1abf')],{'id':_0x27df01['id'],'parent':_0x27df01[_0x5aae7f('0x2361')]});!_0x2c1910&&_0x19383b[_0x5aae7f('0x1abf')]['push'](_0x27df01);});}function _0x3acb5c(_0x2884a3,_0x1ac6d5){const _0x117ee7=_0x38414e;if(_0x2884a3==='Reports'){if(_0x1ac6d5['parent']){const _0x231484=_0x2e3ca0()['startsWith'](_0x1ac6d5['parent'],'motion')?_0x117ee7('0x1b74'):'Custom';return _0x231484+_0x2884a3;}else return _0x1ac6d5['type'];}return _0x2884a3;}function _0x5de8be(_0x2b8462){const _0x2eace8=_0x38414e;if(_0x19383b[_0x2eace8('0x2106')]){const _0xf2e540=_0x307e0a['confirm']({'skipHide':!![]})[_0x2eace8('0xf28')](_0x2eace8('0x128f'))[_0x2eace8('0x1525')](_0x43d16b[_0x2eace8('0x2728')](_0x2eace8('0x6cd')))[_0x2eace8('0x1040')](_0x2eace8('0x128f'))[_0x2eace8('0xe42')](_0x2b8462)['ok'](_0x43d16b[_0x2eace8('0x2728')](_0x2eace8('0x850')))[_0x2eace8('0x19fb')](_0x43d16b[_0x2eace8('0x2728')](_0x2eace8('0x23bf')));_0x307e0a[_0x2eace8('0x1d4')](_0xf2e540)[_0x2eace8('0x683')](function(){const _0x959ffc=_0x2eace8;_0x307e0a[_0x959ffc('0x1715')]();});}else _0x307e0a['hide']();}}const _0x2b925e=_0x23b950,_0x4b35b1=_0x180212['p']+'src/js/modules/main/apps/staff/views/userProfiles/edit/clone/clone.html/clone.html';_0x492f91[_0x189033('0x14be')]=['$state',_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),'license',_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),'Auth',_0x189033('0x2a'),'userProfileSection'];function _0x492f91(_0x365263,_0x1249e2,_0x293712,_0x598da1,_0x2d0471,_0x430c49,_0x37fabc,_0x398c34,_0x15d06f,_0x474ce4,_0x328602,_0x47ecda){const _0x315f50=_0x189033,_0x4bf07f=this;_0x4bf07f[_0x315f50('0x11ed')]=_0x474ce4[_0x315f50('0x20b2')](),_0x4bf07f['license']=_0x430c49,_0x4bf07f['setting']=_0x37fabc,_0x4bf07f['passwordPattern']=_0x4bf07f[_0x315f50('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4bf07f[_0x315f50('0x1224')]=_0x1249e2[_0x315f50('0x173e')]()+_0x315f50('0x20de')+_0x1249e2['host'](),_0x4bf07f[_0x315f50('0x2a')]=_0x328602||_0x365263[_0x315f50('0x7f2')]['userProfile']||{},_0x4bf07f[_0x315f50('0x22df')]=_0x47ecda&&_0x47ecda[_0x315f50('0x50d')]==0x1?_0x47ecda[_0x315f50('0xf5d')][0x0]:null,_0x4bf07f[_0x315f50('0x1134')]=_0x474ce4[_0x315f50('0x142a')](_0x4bf07f['userProfileSection']?_0x4bf07f[_0x315f50('0x22df')][_0x315f50('0x1134')]:null),_0x4bf07f[_0x315f50('0x258d')]={},_0x4bf07f['selectedTab']=_0x365263[_0x315f50('0x7f2')][_0x315f50('0x1904')]||0x0,_0x4bf07f[_0x315f50('0x2773')]=_0x57b5d9,_0x4bf07f[_0x315f50('0x163d')]=_0x47e12d,_0x4bf07f['alert']=_0x15d06f[_0x315f50('0x2289')],_0x4bf07f[_0x315f50('0x2524')]=_0x38954d,_0x4bf07f['saveUserProfile']=_0x30ed50;function _0x57b5d9(_0x41f273,_0x2caf6b){const _0x1eebf1=_0x315f50;_0x293712['show']({'controller':_0x1eebf1('0x1547'),'controllerAs':'vm','templateUrl':_0x433c2f,'parent':angular[_0x1eebf1('0x1fcc')](_0x598da1[_0x1eebf1('0x18e5')]),'targetEvent':_0x2caf6b,'clickOutsideToClose':!![],'locals':{'userProfile':_0x41f273,'userProfiles':_0x4bf07f['userProfiles']?_0x4bf07f['userProfiles'][_0x1eebf1('0xf5d')]:[],'crudPermissions':_0x4bf07f['crudPermissions']}});}function _0x47e12d(_0x50c0d1,_0x554a64){const _0x30e237=_0x315f50;_0x293712['show']({'controller':_0x30e237('0x22f6'),'controllerAs':'vm','templateUrl':_0x4b35b1,'parent':angular[_0x30e237('0x1fcc')](_0x598da1['body']),'targetEvent':_0x554a64,'clickOutsideToClose':!![],'locals':{'userProfile':_0x50c0d1,'userProfiles':_0x4bf07f[_0x30e237('0x134e')]?_0x4bf07f[_0x30e237('0x134e')][_0x30e237('0xf5d')]:[],'crudPermissions':_0x4bf07f[_0x30e237('0x1134')]}});}function _0x38954d(){const _0x212c55=_0x315f50;_0x365263['go'](_0x212c55('0x1d5d'),{},{'reload':'app.staff.userProfiles'});}function _0x30ed50(){const _0x2bf1ed=_0x315f50;_0x398c34['userProfile']['update']({'id':_0x4bf07f[_0x2bf1ed('0x2a')]['id']},_0x4bf07f[_0x2bf1ed('0x2a')])[_0x2bf1ed('0xe53')][_0x2bf1ed('0x683')](function(){const _0x523848=_0x2bf1ed;_0x15d06f[_0x523848('0x53')]({'title':_0x523848('0x347'),'msg':_0x4bf07f['userProfile']['name']?_0x4bf07f['userProfile'][_0x523848('0x60a')]+_0x523848('0x96c'):''});})['catch'](function(_0x503c81){const _0x8fca4a=_0x2bf1ed;_0x15d06f[_0x8fca4a('0x52a')]({'title':_0x503c81['status']?'API:'+_0x503c81['status']+_0x8fca4a('0xbf6')+_0x503c81[_0x8fca4a('0x24a9')]:'SYSTEM:GETuserProfile','msg':_0x503c81[_0x8fca4a('0x5a5')]?JSON[_0x8fca4a('0x258a')](_0x503c81[_0x8fca4a('0x5a5')]):_0x503c81[_0x8fca4a('0x1ff0')]()});});}}const _0x40f7c8=_0x492f91,_0x2e3c7a=_0x180212['p']+'src/js/modules/main/apps/staff/views/userProfiles/create/dialog.html/dialog.html';_0x52cea0['$inject']=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout','$translate',_0x189033('0x134e'),_0x189033('0x2a'),_0x189033('0x22df'),'api',_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x52cea0(_0x361021,_0x2965fc,_0x3ce215,_0x4cbfa8,_0x5d1696,_0x847c42,_0xe31ceb,_0x4d904f,_0x323d22,_0x319bc8,_0xc3f3a2,_0x5b0573,_0x55173b,_0x728331,_0x457817,_0xfcee80,_0x4cac94){const _0x1db6e8=_0x189033,_0x4322a0=this;_0x4322a0[_0x1db6e8('0xace')]=_0xfcee80,_0x4322a0[_0x1db6e8('0x260a')]=_0x4cac94,_0x4322a0[_0x1db6e8('0x11ed')]=_0x457817[_0x1db6e8('0x20b2')](),_0x4322a0[_0x1db6e8('0x134e')]=_0x323d22||{'count':0x0,'rows':[]},_0x4322a0[_0x1db6e8('0x2a')]=_0x319bc8,_0x4322a0['userProfileSection']=_0xc3f3a2&&_0xc3f3a2[_0x1db6e8('0x50d')]==0x1?_0xc3f3a2[_0x1db6e8('0xf5d')][0x0]:null,_0x4322a0[_0x1db6e8('0x1134')]=_0x457817[_0x1db6e8('0x142a')](_0x4322a0['userProfileSection']?_0x4322a0['userProfileSection'][_0x1db6e8('0x1134')]:null),_0x4322a0[_0x1db6e8('0x5c4')]=_0x1db6e8('0x134e'),_0x4322a0[_0x1db6e8('0x247')]='',_0x4322a0[_0x1db6e8('0x1ce2')]=null,_0x4322a0['selectedUserProfiles']=[],_0x4322a0[_0x1db6e8('0x23a2')]={'fields':_0x1db6e8('0x15b4'),'sort':_0x1db6e8('0xc36'),'limit':0xa,'page':0x1},_0x4322a0[_0x1db6e8('0x12b')]=_0x2e3ca0()['keyBy']([{'option':_0x1db6e8('0x11c6'),'value':'\x27r\x27','disabled':!![]},{'option':_0x1db6e8('0x23a8'),'value':_0x1db6e8('0x1feb')},{'option':_0x1db6e8('0x1226'),'value':'\x27d\x27'}],function(_0x5ab4bc){const _0x522d09=_0x1db6e8;return _0x2e3ca0()[_0x522d09('0x1725')](_0x5ab4bc[_0x522d09('0x1c6b')],new RegExp('\x27','g'),'');});_0x4322a0['userProfiles']&&_0x4322a0[_0x1db6e8('0x134e')][_0x1db6e8('0x50d')]>0x0&&_0x4322a0['userProfiles'][_0x1db6e8('0xf5d')]['forEach'](function(_0x4c87ef){const _0x30e0a2=_0x1db6e8,_0x577432=[];_0x4c87ef[_0x30e0a2('0x1134')][_0x30e0a2('0x1299')](function(_0x4c0d80){const _0x4cf6d3=_0x30e0a2;_0x577432['push'](_0x4322a0[_0x4cf6d3('0x12b')][_0x4c0d80]['option']);});const _0x533a5c=[];_0x577432[_0x30e0a2('0x1299')](function(_0x65ce3){const _0x220391=_0x30e0a2;_0x533a5c['push'](_0x4d904f[_0x220391('0x2728')]('STAFF.'+_0x65ce3['toUpperCase']()));}),_0x4c87ef[_0x30e0a2('0x16f5')]=_0x533a5c[_0x30e0a2('0x1630')](',\x20');});_0x4322a0[_0x1db6e8('0xc63')]=_0xa541d1,_0x4322a0[_0x1db6e8('0x163d')]=_0x31ae4c,_0x4322a0[_0x1db6e8('0x194f')]=_0x4e4b4e,_0x4322a0[_0x1db6e8('0x53')]=_0x1eecc3,_0x4322a0[_0x1db6e8('0x25e0')]=_0x209b86,_0x4322a0[_0x1db6e8('0x3f8')]=_0xcb4626,_0x4322a0[_0x1db6e8('0x13fa')]=_0x980b41,_0x4322a0[_0x1db6e8('0x1161')]=_0x10dc86,_0x4322a0[_0x1db6e8('0x23dc')]=_0x3c4f6d,_0x4322a0['deselectUserProfiles']=_0x40965e,_0x4322a0[_0x1db6e8('0x273b')]=_0x430098;function _0xa541d1(_0x47e545){const _0x369a7d=_0x1db6e8;_0x3ce215['go']('app.staff.userProfiles.edit',{'id':_0x47e545['id'],'userProfile':_0x47e545,'crudPermissions':_0x4322a0[_0x369a7d('0x1134')]});}function _0x31ae4c(_0xe65731,_0x545c8e){const _0x5edd73=_0x1db6e8;_0x5d1696[_0x5edd73('0x1d4')]({'controller':_0x5edd73('0x22f6'),'controllerAs':'vm','templateUrl':_0x4b35b1,'parent':angular['element'](_0x847c42[_0x5edd73('0x18e5')]),'targetEvent':_0x545c8e,'clickOutsideToClose':!![],'locals':{'userProfile':_0xe65731,'userProfiles':_0x4322a0[_0x5edd73('0x134e')]?_0x4322a0[_0x5edd73('0x134e')]['rows']:[],'crudPermissions':_0x4322a0['crudPermissions']}});}function _0x4e4b4e(_0x5433fc,_0x48e102){const _0x1e3d21=_0x1db6e8,_0x469702=_0x5d1696[_0x1e3d21('0x1c6f')]()[_0x1e3d21('0xf28')](_0x1e3d21('0x1b01')+_0x2e3ca0()[_0x1e3d21('0x1e03')](_0x1e3d21('0x2a'))+'?')[_0x1e3d21('0x26e3')](_0x1e3d21('0xed5')+(_0x5433fc[_0x1e3d21('0x60a')]||_0x1e3d21('0x2a'))+_0x1e3d21('0x20f1')+'\x20will\x20be\x20deleted.')[_0x1e3d21('0x1040')]('delete\x20userProfile')[_0x1e3d21('0xe42')](_0x48e102)['ok']('OK')[_0x1e3d21('0x19fb')](_0x1e3d21('0x16b8'));_0x5d1696['show'](_0x469702)['then'](function(){_0x980b41(_0x5433fc);},function(){const _0x52d7ff=_0x1e3d21;console[_0x52d7ff('0x1b2b')]('CANCEL');});}let _0x132f8c=!![],_0x305155=0x1;_0x361021[_0x1db6e8('0x186d')](_0x1db6e8('0x1e1d'),function(_0x580751,_0x25f7e6){const _0x4f3a20=_0x1db6e8;_0x132f8c?_0xe31ceb(function(){_0x132f8c=![];}):(!_0x25f7e6&&(_0x305155=_0x4322a0['query'][_0x4f3a20('0xdf8')]),_0x580751!==_0x25f7e6&&(_0x4322a0[_0x4f3a20('0x23a2')][_0x4f3a20('0xdf8')]=0x1),!_0x580751&&(_0x4322a0[_0x4f3a20('0x23a2')][_0x4f3a20('0xdf8')]=_0x305155),_0x4322a0[_0x4f3a20('0x25e0')]());});function _0x1eecc3(_0x5da53a){_0x4322a0['userProfiles']=_0x5da53a||{'count':0x0,'rows':[]};}function _0x209b86(){const _0x2fff91=_0x1db6e8;_0x4322a0[_0x2fff91('0x23a2')][_0x2fff91('0x1cc8')]=(_0x4322a0[_0x2fff91('0x23a2')]['page']-0x1)*_0x4322a0[_0x2fff91('0x23a2')]['limit'],_0x457817[_0x2fff91('0xca1')]('admin')?_0x4322a0['promise']=_0x5b0573[_0x2fff91('0x2a')][_0x2fff91('0x1e6e')](_0x4322a0['query'],_0x1eecc3)[_0x2fff91('0xe53')]:(_0x4322a0['query']['id']=_0x4322a0[_0x2fff91('0x2a')]['id'],_0x4322a0[_0x2fff91('0x23a2')][_0x2fff91('0x1aa')]=_0x2fff91('0x1e39'),_0x4322a0[_0x2fff91('0x1883')]=_0x5b0573[_0x2fff91('0x2a')][_0x2fff91('0x241d')](_0x4322a0[_0x2fff91('0x23a2')],_0x1eecc3)[_0x2fff91('0xe53')]);}function _0xcb4626(_0x1bae2d,_0x3fd021){const _0x640950=_0x1db6e8;_0x5d1696[_0x640950('0x1d4')]({'controller':_0x640950('0x18be'),'controllerAs':'vm','templateUrl':_0x2e3c7a,'parent':angular[_0x640950('0x1fcc')](_0x847c42[_0x640950('0x18e5')]),'targetEvent':_0x1bae2d,'clickOutsideToClose':!![],'locals':{'userProfile':_0x3fd021,'userProfiles':_0x4322a0[_0x640950('0x134e')][_0x640950('0xf5d')],'license':_0x4322a0[_0x640950('0xace')],'setting':_0x4322a0[_0x640950('0x260a')],'crudPermissions':_0x4322a0['crudPermissions']}});}function _0x980b41(_0x1ce468){const _0x38f089=_0x1db6e8;_0x5b0573[_0x38f089('0x2a')]['delete']({'id':_0x1ce468['id']})[_0x38f089('0xe53')][_0x38f089('0x683')](function(){const _0x350297=_0x38f089;_0x2e3ca0()[_0x350297('0x3ec')](_0x4322a0[_0x350297('0x134e')]['rows'],{'id':_0x1ce468['id']}),_0x4322a0[_0x350297('0x134e')][_0x350297('0x50d')]-=0x1,!_0x4322a0[_0x350297('0x134e')][_0x350297('0xf5d')]['length']&&_0x4322a0[_0x350297('0x25e0')](),_0x728331[_0x350297('0x53')]({'title':_0x2e3ca0()[_0x350297('0x1e03')](_0x350297('0x1b4a'))+'\x20deleted!','msg':_0x1ce468['name']?_0x1ce468[_0x350297('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0x38f089('0x130a')](function(_0xe3ca08){const _0x2e5520=_0x38f089;if(_0xe3ca08[_0x2e5520('0x5a5')]&&_0xe3ca08[_0x2e5520('0x5a5')][_0x2e5520('0x17f')]&&_0xe3ca08[_0x2e5520('0x5a5')][_0x2e5520('0x17f')][_0x2e5520('0x1564')]){_0x4322a0[_0x2e5520('0x17f')]=_0xe3ca08['data'][_0x2e5520('0x17f')]||[{'message':_0xe3ca08[_0x2e5520('0x1ff0')](),'type':_0x2e5520('0x27af')}];for(let _0x4b4433=0x0;_0x4b4433<_0xe3ca08[_0x2e5520('0x5a5')]['errors'][_0x2e5520('0x1564')];_0x4b4433++){_0x728331[_0x2e5520('0x52a')]({'title':_0xe3ca08[_0x2e5520('0x5a5')]['errors'][_0x4b4433]['type'],'msg':_0xe3ca08[_0x2e5520('0x5a5')][_0x2e5520('0x17f')][_0x4b4433][_0x2e5520('0x8c2')]});}}else _0x728331[_0x2e5520('0x52a')]({'title':_0xe3ca08[_0x2e5520('0x13ee')]?_0x2e5520('0x2168')+_0xe3ca08['status']+_0x2e5520('0xbf6')+_0xe3ca08[_0x2e5520('0x24a9')]:'SYSTEM:DELETEuserProfile','msg':_0xe3ca08['data']?JSON[_0x2e5520('0x258a')](_0xe3ca08[_0x2e5520('0x5a5')][_0x2e5520('0x8c2')]):_0xe3ca08[_0x2e5520('0x8c2')]||_0xe3ca08['toString']()});});}function _0x10dc86(){const _0x19db31=_0x1db6e8,_0x97dda5=angular['copy'](_0x4322a0[_0x19db31('0x1d8f')]);return _0x4322a0[_0x19db31('0x1d8f')]=[],_0x97dda5;}function _0x3c4f6d(_0x4bb306){const _0x4b5959=_0x1db6e8,_0x408391=_0x5d1696[_0x4b5959('0x1c6f')]()[_0x4b5959('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20userProfiles?')[_0x4b5959('0x26e3')](_0x4b5959('0xed5')+_0x4322a0[_0x4b5959('0x1d8f')][_0x4b5959('0x1564')]+'\x20selected'+_0x4b5959('0x1ee7'))[_0x4b5959('0x1040')]('delete\x20UserProfiles')[_0x4b5959('0xe42')](_0x4bb306)['ok']('OK')[_0x4b5959('0x19fb')](_0x4b5959('0x16b8'));_0x5d1696['show'](_0x408391)[_0x4b5959('0x683')](function(){const _0x4ce3b1=_0x4b5959;_0x4322a0[_0x4ce3b1('0x1d8f')][_0x4ce3b1('0x1299')](function(_0x1b05b4){_0x980b41(_0x1b05b4);}),_0x4322a0[_0x4ce3b1('0x1d8f')]=[];});}function _0x40965e(){const _0x697038=_0x1db6e8;_0x4322a0[_0x697038('0x1d8f')]=[];}function _0x430098(){const _0x3e9b73=_0x1db6e8;_0x4322a0[_0x3e9b73('0x1d8f')]=_0x4322a0['userProfiles'][_0x3e9b73('0xf5d')];}}const _0x928f34=_0x52cea0;_0x17f6d0['$inject']=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x3bf'),_0x189033('0xc96'),'api',_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x17f6d0(_0x50e05e,_0x133520,_0x5f4698,_0x135c8f,_0x31b5dd,_0xce32fe,_0x518be1,_0x1abca8,_0xf45aa1,_0xd03209,_0x160114,_0x178ac2,_0x4e681c,_0xfc362d){const _0x446ed9=_0x189033,_0x1b88ad=this;_0x1b88ad['currentUser']=_0x160114[_0x446ed9('0x20b2')](),_0x1b88ad['errors']=[],_0x1b88ad[_0x446ed9('0x260a')]=_0x4e681c,_0x1b88ad[_0x446ed9('0xace')]=_0x178ac2,_0x1b88ad['crudPermissions']=_0xfc362d,_0x1b88ad[_0x446ed9('0x258d')]={},_0x1b88ad[_0x446ed9('0x19b2')]=_0x1b88ad[_0x446ed9('0x260a')]&&_0x1b88ad[_0x446ed9('0x260a')][_0x446ed9('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1b88ad['title']=_0x446ed9('0x107'),_0x1b88ad[_0x446ed9('0xc96')]=angular[_0x446ed9('0x1a86')](_0xf45aa1),_0x1b88ad[_0x446ed9('0x3bf')]=_0x1abca8,_0x1b88ad[_0x446ed9('0x23b6')]=![];!_0x1b88ad[_0x446ed9('0xc96')]&&(_0x1b88ad[_0x446ed9('0xc96')]={'role':'user','autointernal':!![],'context':_0x446ed9('0x1365')},_0x1b88ad[_0x446ed9('0xf28')]=_0x446ed9('0x9d0'),_0x1b88ad['newUser']=!![]);_0x1b88ad[_0x446ed9('0x134c')]=_0x27be7b,_0x1b88ad[_0x446ed9('0x11d5')]=_0x481f5a,_0x1b88ad['deleteUser']=_0x4fb2c7,_0x1b88ad[_0x446ed9('0x16b3')]=_0x453692,_0x1b88ad[_0x446ed9('0xf82')]=_0x5ec7fb,_0xd03209[_0x446ed9('0x2a')][_0x446ed9('0x1e6e')]({'fields':'id,name','sort':_0x446ed9('0x60a')})[_0x446ed9('0xe53')]['then'](function(_0x3d213f){const _0x21d3f3=_0x446ed9;_0x1b88ad[_0x21d3f3('0x134e')]=_0x3d213f['rows']||[];})[_0x446ed9('0x130a')](function(_0x494e3c){const _0x138007=_0x446ed9;_0x518be1[_0x138007('0x52a')]({'title':_0x494e3c[_0x138007('0x13ee')]?_0x138007('0x2168')+_0x494e3c[_0x138007('0x13ee')]+'\x20-\x20'+_0x494e3c[_0x138007('0x24a9')]:_0x138007('0x172c'),'msg':_0x494e3c[_0x138007('0x5a5')]?JSON['stringify'](_0x494e3c[_0x138007('0x5a5')]):_0x494e3c[_0x138007('0x1ff0')]()});});function _0x27be7b(){const _0x574337=_0x446ed9;_0x1b88ad[_0x574337('0x17f')]=[],_0xd03209[_0x574337('0xc96')][_0x574337('0xb0a')](_0x1b88ad[_0x574337('0xc96')])[_0x574337('0xe53')][_0x574337('0x683')](function(_0x2f58bd){const _0x6d3835=_0x574337;_0x1b88ad[_0x6d3835('0x3bf')][_0x6d3835('0x1167')](_0x2f58bd[_0x6d3835('0x24e1')]()),_0x518be1[_0x6d3835('0x53')]({'title':_0x6d3835('0x2204'),'msg':_0x1b88ad[_0x6d3835('0xc96')]['name']?_0x1b88ad[_0x6d3835('0xc96')]['name']+_0x6d3835('0x14b5'):''}),_0x5ec7fb(_0x2f58bd);})[_0x574337('0x130a')](function(_0x3ba59f){const _0x297ee7=_0x574337;if(_0x3ba59f[_0x297ee7('0x5a5')]&&_0x3ba59f[_0x297ee7('0x5a5')][_0x297ee7('0x17f')]&&_0x3ba59f['data'][_0x297ee7('0x17f')]['length']){_0x1b88ad[_0x297ee7('0x17f')]=_0x3ba59f['data'][_0x297ee7('0x17f')]||[{'message':_0x3ba59f[_0x297ee7('0x1ff0')](),'type':_0x297ee7('0x7b5')}];for(let _0x5b9d4e=0x0;_0x5b9d4e<_0x3ba59f[_0x297ee7('0x5a5')][_0x297ee7('0x17f')][_0x297ee7('0x1564')];_0x5b9d4e+=0x1){_0x518be1[_0x297ee7('0x52a')]({'title':_0x3ba59f['data']['errors'][_0x5b9d4e][_0x297ee7('0xcf0')],'msg':_0x3ba59f['data']['errors'][_0x5b9d4e][_0x297ee7('0x8c2')]});}}else _0x518be1[_0x297ee7('0x52a')]({'title':_0x3ba59f[_0x297ee7('0x13ee')]?'API:'+_0x3ba59f['status']+_0x297ee7('0xbf6')+_0x3ba59f[_0x297ee7('0x24a9')]:_0x297ee7('0x7b5'),'msg':_0x3ba59f[_0x297ee7('0x5a5')]?JSON['stringify'](_0x3ba59f[_0x297ee7('0x5a5')]['message']):_0x3ba59f[_0x297ee7('0x1ff0')]()});});}function _0x481f5a(){const _0x253c90=_0x446ed9;_0x1b88ad['errors']=[],_0xd03209[_0x253c90('0xc96')]['update']({'id':_0x1b88ad[_0x253c90('0xc96')]['id']},_0x1b88ad['user'])[_0x253c90('0xe53')][_0x253c90('0x683')](function(_0x47778d){const _0x14b18f=_0x253c90,_0x198b01=_0x2e3ca0()[_0x14b18f('0x1c07')](_0x1b88ad['users'],{'id':_0x47778d['id']});_0x198b01&&_0x2e3ca0()[_0x14b18f('0xf22')](_0x198b01,_0x2e3ca0()[_0x14b18f('0x24d0')](_0x47778d[_0x14b18f('0x24e1')](),_0x2e3ca0()['keys'](_0x198b01))),_0x518be1[_0x14b18f('0x53')]({'title':_0x14b18f('0x1438'),'msg':_0x1b88ad[_0x14b18f('0xc96')][_0x14b18f('0x60a')]?_0x1b88ad[_0x14b18f('0xc96')][_0x14b18f('0x60a')]+_0x14b18f('0xf59'):''}),_0x5ec7fb(_0x47778d);})[_0x253c90('0x130a')](function(_0x26c586){const _0x47ad13=_0x253c90;if(_0x26c586[_0x47ad13('0x5a5')]&&_0x26c586[_0x47ad13('0x5a5')][_0x47ad13('0x17f')]&&_0x26c586[_0x47ad13('0x5a5')][_0x47ad13('0x17f')]['length']){_0x1b88ad['errors']=_0x26c586[_0x47ad13('0x5a5')][_0x47ad13('0x17f')]||[{'message':_0x26c586[_0x47ad13('0x1ff0')](),'type':_0x47ad13('0x162b')}];for(let _0x21a392=0x0;_0x21a392<_0x26c586[_0x47ad13('0x5a5')][_0x47ad13('0x17f')][_0x47ad13('0x1564')];_0x21a392++){_0x518be1[_0x47ad13('0x52a')]({'title':_0x26c586[_0x47ad13('0x5a5')][_0x47ad13('0x17f')][_0x21a392][_0x47ad13('0xcf0')],'msg':_0x26c586[_0x47ad13('0x5a5')][_0x47ad13('0x17f')][_0x21a392][_0x47ad13('0x8c2')]});}}else _0x518be1[_0x47ad13('0x52a')]({'title':_0x26c586[_0x47ad13('0x13ee')]?_0x47ad13('0x2168')+_0x26c586[_0x47ad13('0x13ee')]+'\x20-\x20'+_0x26c586[_0x47ad13('0x24a9')]:'api.user.update','msg':_0x26c586['data']?JSON[_0x47ad13('0x258a')](_0x26c586[_0x47ad13('0x5a5')][_0x47ad13('0x8c2')]):_0x26c586[_0x47ad13('0x1ff0')]()});});}function _0x4fb2c7(_0x3f9b62){const _0x6debc9=_0x446ed9,_0x365cee=_0x160114['getCurrentUser']();if(_0x365cee['id']===_0x1b88ad[_0x6debc9('0xc96')]['id'])return _0x518be1['error']({'title':_0x6debc9('0x1a6e'),'msg':_0x6debc9('0x2273')});_0x1b88ad[_0x6debc9('0x17f')]=[];const _0x1630f9=_0x135c8f[_0x6debc9('0x1c6f')]()[_0x6debc9('0xf28')](_0x6debc9('0x4d'))[_0x6debc9('0xa6a')](_0x6debc9('0x1c40'))[_0x6debc9('0x1040')](_0x6debc9('0x69'))['ok'](_0x6debc9('0x2307'))[_0x6debc9('0x19fb')](_0x6debc9('0x253a'))['targetEvent'](_0x3f9b62);_0x135c8f[_0x6debc9('0x1d4')](_0x1630f9)[_0x6debc9('0x683')](function(){const _0x44686b=_0x6debc9;_0xd03209[_0x44686b('0xc96')][_0x44686b('0xd7e')]({'id':_0x1b88ad['user']['id']})[_0x44686b('0xe53')]['then'](function(){const _0x51bf90=_0x44686b;_0x2e3ca0()[_0x51bf90('0x3ec')](_0x1b88ad[_0x51bf90('0x3bf')],{'id':_0x1b88ad[_0x51bf90('0xc96')]['id']}),_0x518be1[_0x51bf90('0x53')]({'title':_0x51bf90('0x7fb'),'msg':(_0x1b88ad[_0x51bf90('0xc96')][_0x51bf90('0x60a')]||'user')+'\x20has\x20been\x20deleted!'}),_0x5ec7fb(_0x1b88ad['user']);})[_0x44686b('0x130a')](function(_0x436292){const _0x193056=_0x44686b;if(_0x436292[_0x193056('0x5a5')]&&_0x436292[_0x193056('0x5a5')][_0x193056('0x17f')]&&_0x436292[_0x193056('0x5a5')]['errors'][_0x193056('0x1564')]){_0x1b88ad[_0x193056('0x17f')]=_0x436292['data'][_0x193056('0x17f')]||[{'message':_0x436292[_0x193056('0x1ff0')](),'type':_0x193056('0x11d0')}];for(let _0x1e51b7=0x0;_0x1e51b7<_0x436292[_0x193056('0x5a5')][_0x193056('0x17f')][_0x193056('0x1564')];_0x1e51b7++){_0x518be1[_0x193056('0x52a')]({'title':_0x436292[_0x193056('0x5a5')][_0x193056('0x17f')][_0x1e51b7]['type'],'msg':_0x436292[_0x193056('0x5a5')][_0x193056('0x17f')][_0x1e51b7][_0x193056('0x8c2')]});}}else _0x518be1[_0x193056('0x52a')]({'title':_0x436292[_0x193056('0x13ee')]?_0x193056('0x2168')+_0x436292[_0x193056('0x13ee')]+'\x20-\x20'+_0x436292[_0x193056('0x24a9')]:_0x193056('0x11d0'),'msg':_0x436292[_0x193056('0x5a5')]?JSON[_0x193056('0x258a')](_0x436292['data'][_0x193056('0x8c2')]):_0x436292[_0x193056('0x8c2')]||_0x436292['toString']()});});},function(){});}function _0x453692(_0x13f59f){return _0x13f59f===null?undefined:new Date(_0x13f59f);}function _0x5ec7fb(_0x5287cd){const _0x5bea6c=_0x446ed9;_0x135c8f[_0x5bea6c('0x1715')](_0x5287cd);}}const _0x3e3368=_0x17f6d0;_0xd253ac[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x1d70'),'api','user',_0x189033('0xba1')];function _0xd253ac(_0x2a9739,_0x456f0c,_0xf3816b,_0xd74269,_0x2412d7){const _0x2f5077=_0x189033,_0x423a81=this;_0x423a81[_0x2f5077('0x11ed')]=_0x2412d7[_0x2f5077('0x20b2')](),_0x423a81[_0x2f5077('0x17f')]=[],_0x423a81['user']=_0xd74269,_0x423a81[_0x2f5077('0xb8b')]=_0x14c960,_0x423a81[_0x2f5077('0xf64')]=_0xc5879e,_0x423a81['closeDialog']=_0x2f1947;function _0x14c960(){const _0x390bd0=_0x2f5077;_0x423a81[_0x390bd0('0x17f')]=[],_0xf3816b[_0x390bd0('0xc96')][_0x390bd0('0x1fcb')]({'id':_0x423a81['user']['id']})[_0x390bd0('0xe53')]['then'](function(_0x5a17e9){const _0x27c844=_0x390bd0;_0x423a81[_0x27c844('0xc96')]['apiKey']=_0x5a17e9[_0x27c844('0x235e')]||_0x27c844('0xfa2'),_0x456f0c[_0x27c844('0x53')]({'title':_0x27c844('0x82f')}),_0x2f1947();})[_0x390bd0('0x130a')](function(_0xf2399a){const _0x552a9f=_0x390bd0;_0x456f0c[_0x552a9f('0x52a')]({'title':_0xf2399a[_0x552a9f('0x13ee')]?_0x552a9f('0x2168')+_0xf2399a[_0x552a9f('0x13ee')]+_0x552a9f('0xbf6')+_0xf2399a[_0x552a9f('0x24a9')]:_0x552a9f('0x1fae'),'msg':_0xf2399a[_0x552a9f('0x5a5')]?JSON[_0x552a9f('0x258a')](_0xf2399a[_0x552a9f('0x5a5')][_0x552a9f('0x8c2')]):_0xf2399a[_0x552a9f('0x1ff0')]()}),_0x423a81['errors']=_0xf2399a['data'][_0x552a9f('0x17f')]||[{'message':_0xf2399a[_0x552a9f('0x1ff0')](),'type':_0x552a9f('0x1fae')}];});}function _0xc5879e(){const _0x4f0e65=_0x2f5077;_0x423a81['errors']=[],_0xf3816b['user'][_0x4f0e65('0xf64')]({'id':_0x423a81['user']['id']})[_0x4f0e65('0xe53')][_0x4f0e65('0x683')](function(){const _0x1cb85b=_0x4f0e65;_0x423a81[_0x1cb85b('0xc96')][_0x1cb85b('0x1af9')]=_0x1cb85b('0xfa2'),_0x456f0c[_0x1cb85b('0x53')]({'title':_0x1cb85b('0x1c56')}),_0x2f1947();})[_0x4f0e65('0x130a')](function(_0x7ec5bc){const _0x160b5=_0x4f0e65;_0x456f0c[_0x160b5('0x52a')]({'title':_0x7ec5bc[_0x160b5('0x13ee')]?'API:'+_0x7ec5bc[_0x160b5('0x13ee')]+_0x160b5('0xbf6')+_0x7ec5bc[_0x160b5('0x24a9')]:_0x160b5('0x104d'),'msg':_0x7ec5bc[_0x160b5('0x5a5')]?JSON['stringify'](_0x7ec5bc[_0x160b5('0x5a5')][_0x160b5('0x8c2')]):_0x7ec5bc['toString']()}),_0x423a81['errors']=_0x7ec5bc[_0x160b5('0x5a5')][_0x160b5('0x17f')]||[{'message':_0x7ec5bc[_0x160b5('0x1ff0')](),'type':'api.user.removeApiKey'}];});}function _0x2f1947(){const _0x43c134=_0x2f5077;_0x2a9739[_0x43c134('0x1715')]();}}const _0x594b44=_0xd253ac;_0x28351c[_0x189033('0x14be')]=['$cookies','toasty'];function _0x28351c(_0x3f32b1,_0x2aa2af){const _0x40681a=_0x189033,_0x204ab1=this,_0x2ac5a6=0x8,_0xc4a41f=_0x2ac5a6*0x400*0x400;_0x204ab1['user']={},_0x204ab1[_0x40681a('0x1134')],_0x204ab1[_0x40681a('0x8f')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0xc4a41f,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x204ab1[_0x40681a('0x1fa6')]={'flow':{}},_0x204ab1[_0x40681a('0xfbe')]=![],_0x204ab1[_0x40681a('0x1aad')]=_0x355f85,_0x204ab1['upload']=_0x6026e5,_0x204ab1[_0x40681a('0x1152')]=_0x3acb14,_0x204ab1[_0x40681a('0x12f3')]=_0x3da1e8;function _0x3da1e8(_0x8f4083,_0x155d42){const _0x248bd4=_0x40681a;_0x204ab1['user']=angular[_0x248bd4('0x1a86')](_0x8f4083),_0x204ab1[_0x248bd4('0x1134')]=typeof _0x155d42!==_0x248bd4('0x1867')?_0x155d42:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x204ab1[_0x248bd4('0x8f')][_0x248bd4('0x568')]=_0x248bd4('0xce')+_0x204ab1[_0x248bd4('0xc96')]['id']+_0x248bd4('0x9f3'),_0x204ab1[_0x248bd4('0xc96')][_0x248bd4('0x2668')]=[];}function _0x355f85(_0x12bf5d){const _0x460265=_0x40681a,_0x491abd=[_0x460265('0x21ec'),_0x460265('0x159c')];if(!_0x2e3ca0()['includes'](_0x491abd,_0x12bf5d[_0x460265('0x1197')]()))return _0x2aa2af[_0x460265('0x52a')]({'title':_0x460265('0xa00')+_0x12bf5d['getExtension'](),'msg':_0x460265('0x2560')+_0x491abd['join']()}),![];if(_0x12bf5d[_0x460265('0x1a41')]>_0xc4a41f)return _0x2aa2af[_0x460265('0x52a')]({'title':_0x460265('0x19a2'),'msg':_0x460265('0x1622')+_0x2ac5a6+'MB'}),![];const _0x311816={'id':_0x12bf5d['uniqueIdentifier'],'file':_0x12bf5d,'type':_0x460265('0x132')};return _0x204ab1[_0x460265('0xc96')]['images'][_0x460265('0x1167')](_0x311816),!![];}function _0x6026e5(){const _0x21b958=_0x40681a;_0x204ab1[_0x21b958('0x1fa6')][_0x21b958('0x190a')][_0x21b958('0x2810')][_0x21b958('0xb7d')]={'X-Requested-With':_0x21b958('0xbfd'),'Authorization':_0x21b958('0x189e')+_0x3f32b1[_0x21b958('0x1e6e')](_0x21b958('0x555'))},_0x204ab1[_0x21b958('0x1fa6')]['flow']['upload']();}function _0x3acb14(_0x571c3f){const _0x2f7b97=_0x40681a;angular[_0x2f7b97('0x1299')](_0x204ab1[_0x2f7b97('0xc96')]['images'],function(_0x3d7bb6){const _0x36b0ea=_0x2f7b97;if(_0x3d7bb6['id']===_0x571c3f['uniqueIdentifier']){const _0x346d1f=new FileReader();_0x346d1f[_0x36b0ea('0x23e1')](_0x3d7bb6[_0x36b0ea('0x21dd')]['file']),_0x346d1f[_0x36b0ea('0x43b')]=function(_0xd99276){const _0x25d455=_0x36b0ea;_0x3d7bb6[_0x25d455('0x1284')]=_0xd99276['target'][_0x25d455('0x7c9')];},_0x3d7bb6[_0x36b0ea('0xcf0')]='image';}});}}const _0x343078=_0x28351c;_0x53b16c[_0x189033('0x14be')]=['$scope',_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x56b'),'user',_0x189033('0x260a'),'Auth'];function _0x53b16c(_0x4615db,_0x2a0cb6,_0x1159a8,_0x33c7c6,_0x5ce417,_0x949a5e,_0x12e5fc){const _0x145c0a=_0x189033,_0x465158=this;_0x465158[_0x145c0a('0x11ed')]=_0x12e5fc[_0x145c0a('0x20b2')](),_0x465158['errors']=[],_0x465158['setting']=_0x949a5e,_0x465158[_0x145c0a('0x19b2')]=_0x465158['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x465158['user']=_0x5ce417,_0x465158[_0x145c0a('0x1e96')]='',_0x465158[_0x145c0a('0x17fb')]='',_0x465158['savePassword']=_0x5b56d7,_0x465158['closeDialog']=_0x507b03,_0x4615db['$watch']('vm.password',function(_0x5a6de0){const _0x26fe0e=_0x145c0a;!_0x2e3ca0()[_0x26fe0e('0x8f2')](_0x465158[_0x26fe0e('0x17fb')])&&(_0x5a6de0===_0x465158[_0x26fe0e('0x17fb')]?_0x4615db['userForm']['password'][_0x26fe0e('0x1c25')]('oldPasswordMatch',![]):_0x4615db[_0x26fe0e('0x17b8')][_0x26fe0e('0x1e96')][_0x26fe0e('0x1c25')](_0x26fe0e('0x20b9'),!![]));});function _0x5b56d7(){const _0x4e01ad=_0x145c0a;_0x465158[_0x4e01ad('0x17f')]=[];const _0x9bfdfc={'id':_0x465158['user']['id'],'newPassword':_0x465158[_0x4e01ad('0x1e96')]};_0x465158[_0x4e01ad('0x11ed')]['id']==_0x465158[_0x4e01ad('0xc96')]['id']&&(_0x9bfdfc[_0x4e01ad('0x17fb')]=_0x465158['oldPassword']),_0x33c7c6[_0x4e01ad('0xc96')][_0x4e01ad('0x2193')](_0x9bfdfc)[_0x4e01ad('0xe53')]['then'](function(){const _0x1d95a4=_0x4e01ad;_0x1159a8[_0x1d95a4('0x53')]({'title':_0x1d95a4('0x6ee')}),_0x507b03();})[_0x4e01ad('0x130a')](function(_0x3d763e){const _0x5498cd=_0x4e01ad;_0x1159a8['error']({'title':_0x3d763e['status']?_0x5498cd('0x2168')+_0x3d763e[_0x5498cd('0x13ee')]+_0x5498cd('0xbf6')+_0x3d763e['statusText']:_0x5498cd('0x7b5'),'msg':_0x3d763e['data']?JSON[_0x5498cd('0x258a')](_0x3d763e[_0x5498cd('0x5a5')][_0x5498cd('0x8c2')]):_0x3d763e['toString']()}),_0x465158[_0x5498cd('0x17f')]=_0x3d763e['data'][_0x5498cd('0x17f')]||[{'message':_0x3d763e['toString'](),'type':'api.user.changePassword'}];});}function _0x507b03(){const _0x592311=_0x145c0a;_0x2a0cb6[_0x592311('0x1715')]();}}const _0x3eb755=_0x53b16c,_0x411f67=_0x180212['p']+'src/js/modules/main/apps/staff/views/users/edit/apikeymanager/apikeymanager.html/apikeymanager.html',_0x2fc38c=_0x180212['p']+_0x189033('0x15f2');_0x3149dd['$inject']=['$state','$location',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),'Auth','user',_0x189033('0x22df')];function _0x3149dd(_0xa37e7b,_0x36b8ad,_0x2c478f,_0x55e95b,_0x552dd0,_0x2f2b3f,_0x2d20e5,_0x51d229,_0x202b2d,_0x143af7,_0x2a9d28,_0x210e52){const _0x9fd21f=_0x189033,_0xb97977=this;_0xb97977[_0x9fd21f('0x11ed')]=_0x143af7[_0x9fd21f('0x20b2')](),_0xb97977[_0x9fd21f('0xace')]=_0x2f2b3f,_0xb97977[_0x9fd21f('0x260a')]=_0x2d20e5,_0xb97977[_0x9fd21f('0x19b2')]=_0xb97977['setting'][_0x9fd21f('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xb97977[_0x9fd21f('0x1224')]=_0x36b8ad[_0x9fd21f('0x173e')]()+'://'+_0x36b8ad[_0x9fd21f('0x19ac')](),_0xb97977[_0x9fd21f('0xc96')]=_0x2a9d28||_0xa37e7b[_0x9fd21f('0x7f2')]['user']||{},_0xb97977[_0x9fd21f('0x22df')]=_0x210e52&&_0x210e52[_0x9fd21f('0x50d')]==0x1?_0x210e52[_0x9fd21f('0xf5d')][0x0]:null,_0xb97977[_0x9fd21f('0x1134')]=_0x143af7[_0x9fd21f('0x142a')](_0xb97977[_0x9fd21f('0x22df')]?_0xb97977[_0x9fd21f('0x22df')][_0x9fd21f('0x1134')]:null),_0xb97977['hasModulePermissions']={},_0xb97977[_0x9fd21f('0x517')]=_0xa37e7b['params']['tab']||0x0,_0xb97977[_0x9fd21f('0xfe')]=_0x59045b,_0xb97977[_0x9fd21f('0xfc6')]=_0x4e4705,_0xb97977[_0x9fd21f('0x2430')]=_0x202b2d['info'],_0xb97977['gotoUsers']=_0x2402a6,_0xb97977['saveUser']=_0x52e45e,_0x51d229[_0x9fd21f('0x1e4d')]['get']({'fields':'id,name','sort':'name'})[_0x9fd21f('0xe53')]['then'](function(_0x3f9a57){const _0x2659d8=_0x9fd21f;_0xb97977[_0x2659d8('0x1693')]=_0x3f9a57['rows']||[];})[_0x9fd21f('0x130a')](function(_0x2f1050){const _0x26b27e=_0x9fd21f;_0x202b2d[_0x26b27e('0x52a')]({'title':_0x2f1050[_0x26b27e('0x13ee')]?_0x26b27e('0x2168')+_0x2f1050[_0x26b27e('0x13ee')]+_0x26b27e('0xbf6')+_0x2f1050[_0x26b27e('0x24a9')]:_0x26b27e('0x1379'),'msg':_0x2f1050[_0x26b27e('0x5a5')]?JSON[_0x26b27e('0x258a')](_0x2f1050[_0x26b27e('0x5a5')]):_0x2f1050[_0x26b27e('0x1ff0')]()});}),_0x51d229[_0x9fd21f('0x2a')][_0x9fd21f('0x1e6e')]({'fields':_0x9fd21f('0xa10'),'sort':_0x9fd21f('0x60a')})[_0x9fd21f('0xe53')][_0x9fd21f('0x683')](function(_0x3752ef){const _0x55ee59=_0x9fd21f;_0xb97977[_0x55ee59('0x134e')]=_0x3752ef[_0x55ee59('0xf5d')]||[];})[_0x9fd21f('0x130a')](function(_0x2d49a2){const _0x2f91c3=_0x9fd21f;_0x202b2d[_0x2f91c3('0x52a')]({'title':_0x2d49a2[_0x2f91c3('0x13ee')]?_0x2f91c3('0x2168')+_0x2d49a2[_0x2f91c3('0x13ee')]+_0x2f91c3('0xbf6')+_0x2d49a2['statusText']:'SYSTEM:GET_USERPROFILES','msg':_0x2d49a2[_0x2f91c3('0x5a5')]?JSON['stringify'](_0x2d49a2['data']):_0x2d49a2['toString']()});}),_0x51d229[_0x9fd21f('0xc96')][_0x9fd21f('0x60b')]({'id':_0xb97977[_0x9fd21f('0xc96')]['id']})[_0x9fd21f('0xe53')][_0x9fd21f('0x683')](function(_0x4a0ed1){const _0x35c569=_0x9fd21f;_0xb97977[_0x35c569('0xc96')]['apiKey']=_0x4a0ed1[_0x35c569('0x235e')]?_0x4a0ed1[_0x35c569('0x235e')]:_0x35c569('0xfa2');})[_0x9fd21f('0x130a')](function(_0x488b17){const _0x1b3929=_0x9fd21f;_0x202b2d[_0x1b3929('0x52a')]({'title':_0x488b17[_0x1b3929('0x13ee')]?'API:'+_0x488b17[_0x1b3929('0x13ee')]+_0x1b3929('0xbf6')+_0x488b17['statusText']:'SYSTEM:GET_APIKEY','msg':_0x488b17[_0x1b3929('0x5a5')]?JSON[_0x1b3929('0x258a')](_0x488b17['data']):_0x488b17[_0x1b3929('0x1ff0')]()});});function _0x59045b(_0x9af7cc,_0x1aa104){const _0xacfc10=_0x9fd21f;_0x2c478f[_0xacfc10('0x1d4')]({'controller':'UserapikeymanagerController','controllerAs':'vm','templateUrl':_0x411f67,'parent':angular[_0xacfc10('0x1fcc')](_0x55e95b[_0xacfc10('0x18e5')]),'targetEvent':_0x1aa104,'clickOutsideToClose':!![],'locals':{'user':_0x9af7cc,'users':_0xb97977['users']?_0xb97977[_0xacfc10('0x3bf')][_0xacfc10('0xf5d')]:[],'crudPermissions':_0xb97977[_0xacfc10('0x1134')]}});}function _0x4e4705(_0xc67b45,_0x1b6af4){const _0x20cba1=_0x9fd21f;_0x2c478f[_0x20cba1('0x1d4')]({'controller':_0x20cba1('0xdc6'),'controllerAs':'vm','templateUrl':_0x2fc38c,'parent':angular[_0x20cba1('0x1fcc')](_0x55e95b[_0x20cba1('0x18e5')]),'targetEvent':_0x1b6af4,'clickOutsideToClose':!![],'locals':{'user':_0xc67b45,'setting':_0x2d20e5,'users':_0xb97977[_0x20cba1('0x3bf')]?_0xb97977[_0x20cba1('0x3bf')][_0x20cba1('0xf5d')]:[],'crudPermissions':_0xb97977[_0x20cba1('0x1134')]}});}function _0x2402a6(){const _0x5e7b28=_0x9fd21f;_0xa37e7b['go'](_0x5e7b28('0x1e7e'),{},{'reload':'app.staff.users'});}function _0x52e45e(){const _0x386bdc=_0x9fd21f;_0xb97977[_0x386bdc('0xc96')]=_0x2e3ca0()[_0x386bdc('0x8b5')](_0xb97977[_0x386bdc('0xc96')],'userpic'),_0x51d229[_0x386bdc('0xc96')][_0x386bdc('0x2480')]({'id':_0xb97977[_0x386bdc('0xc96')]['id']},_0xb97977[_0x386bdc('0xc96')])['$promise'][_0x386bdc('0x683')](function(){const _0x2e6914=_0x386bdc;_0x202b2d[_0x2e6914('0x53')]({'title':_0x2e6914('0x1cac'),'msg':_0xb97977[_0x2e6914('0xc96')][_0x2e6914('0x60a')]?_0xb97977[_0x2e6914('0xc96')]['name']+_0x2e6914('0x96c'):''});})[_0x386bdc('0x130a')](function(_0x53ac72){const _0x1aecdf=_0x386bdc;_0x202b2d[_0x1aecdf('0x52a')]({'title':_0x53ac72['status']?_0x1aecdf('0x2168')+_0x53ac72[_0x1aecdf('0x13ee')]+_0x1aecdf('0xbf6')+_0x53ac72[_0x1aecdf('0x24a9')]:_0x1aecdf('0x23a4'),'msg':_0x53ac72[_0x1aecdf('0x5a5')]?JSON[_0x1aecdf('0x258a')](_0x53ac72[_0x1aecdf('0x5a5')]):_0x53ac72[_0x1aecdf('0x1ff0')]()});});}}const _0x156341=_0x3149dd,_0x18b990=_0x180212['p']+_0x189033('0xfc8');_0x54eaa8[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),'$translate',_0x189033('0x3bf'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),'Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x54eaa8(_0x4b1b7d,_0x59d864,_0x32b21e,_0x32cce1,_0x10f5c2,_0xbf2e9b,_0x348901,_0x2b0d48,_0x430c4c,_0x42ffcd,_0x59ec27,_0x3c3c13,_0x4bce02,_0x548eb5,_0x1673f9,_0x546543,_0x2687e8){const _0x3e7b71=_0x189033,_0x2301c8=this;_0x2301c8[_0x3e7b71('0xace')]=_0x546543,_0x2301c8[_0x3e7b71('0x260a')]=_0x2687e8,_0x2301c8[_0x3e7b71('0x11ed')]=_0x1673f9[_0x3e7b71('0x20b2')](),_0x2301c8[_0x3e7b71('0x3bf')]=_0x430c4c||{'count':0x0,'rows':[]},_0x2301c8[_0x3e7b71('0x2a')]=_0x42ffcd,_0x2301c8['userProfileSection']=_0x59ec27&&_0x59ec27[_0x3e7b71('0x50d')]==0x1?_0x59ec27['rows'][0x0]:null,_0x2301c8[_0x3e7b71('0x1134')]=_0x1673f9[_0x3e7b71('0x142a')](_0x2301c8[_0x3e7b71('0x22df')]?_0x2301c8['userProfileSection'][_0x3e7b71('0x1134')]:null),_0x2301c8['table']='users',_0x2301c8[_0x3e7b71('0x247')]='',_0x2301c8['listOrderAsc']=null,_0x2301c8[_0x3e7b71('0x2140')]=[],_0x2301c8[_0x3e7b71('0x23a2')]={'fields':_0x3e7b71('0x231a'),'role':'admin,user','sort':_0x3e7b71('0xc36'),'limit':0xa,'page':0x1},_0x2301c8[_0x3e7b71('0x252f')]=_0x2e3ca0()[_0x3e7b71('0x24db')]([{'option':_0x3e7b71('0x1ec5'),'value':_0x3e7b71('0x751')},{'option':_0x3e7b71('0x1dad'),'value':_0x3e7b71('0x158f')}],function(_0x58b058){const _0x2153b7=_0x3e7b71;return _0x2e3ca0()[_0x2153b7('0x1725')](_0x58b058[_0x2153b7('0x1c6b')],new RegExp('\x27','g'),'');}),_0x2301c8[_0x3e7b71('0xfb8')]=_0x2e3ca0()[_0x3e7b71('0x24db')]([{'option':_0x3e7b71('0x41d'),'value':_0x3e7b71('0x1c7')},{'option':_0x3e7b71('0x1621'),'value':_0x3e7b71('0xf6')},{'option':'ws','value':_0x3e7b71('0x117e')},{'option':_0x3e7b71('0x2615'),'value':_0x3e7b71('0x26fa')},{'option':_0x3e7b71('0x171f'),'value':_0x3e7b71('0x9ee')}],function(_0x905de6){const _0x4d72ae=_0x3e7b71;return _0x2e3ca0()[_0x4d72ae('0x1725')](_0x905de6[_0x4d72ae('0x1c6b')],new RegExp('\x27','g'),'');}),_0x2301c8['arraynat']=_0x2e3ca0()[_0x3e7b71('0x24db')]([{'option':_0x3e7b71('0x1025'),'value':_0x3e7b71('0x20b7')},{'option':_0x3e7b71('0x261e'),'value':_0x3e7b71('0xe1')},{'option':'yes','value':'\x27yes\x27'},{'option':'no','value':_0x3e7b71('0x23ca')},{'option':_0x3e7b71('0x649'),'value':_0x3e7b71('0xd77')},{'option':_0x3e7b71('0x20ed'),'value':'\x27route\x27'}],function(_0xc1f035){const _0x25de9d=_0x3e7b71;return _0x2e3ca0()[_0x25de9d('0x1725')](_0xc1f035[_0x25de9d('0x1c6b')],new RegExp('\x27','g'),'');}),_0x2301c8[_0x3e7b71('0x2673')]=_0x2e3ca0()[_0x3e7b71('0x24db')]([{'option':'ulaw','value':_0x3e7b71('0x576')},{'option':_0x3e7b71('0xdf6'),'value':'\x27alaw\x27'},{'option':_0x3e7b71('0x1ac0'),'value':_0x3e7b71('0x1755')},{'option':'g722','value':_0x3e7b71('0x226b')},{'option':_0x3e7b71('0x14bf'),'value':'\x27g729\x27'},{'option':_0x3e7b71('0xed4'),'value':_0x3e7b71('0x2873')},{'option':'h264','value':_0x3e7b71('0x483')}],function(_0x166cb2){const _0x412dc8=_0x3e7b71;return _0x2e3ca0()['replace'](_0x166cb2[_0x412dc8('0x1c6b')],new RegExp('\x27','g'),'');}),_0x2301c8[_0x3e7b71('0x10df')]=_0x2e3ca0()[_0x3e7b71('0x24db')]([{'option':_0x3e7b71('0xe76'),'value':'\x27yes\x27'},{'option':'No','value':_0x3e7b71('0x23ca')},{'option':_0x3e7b71('0x1023'),'value':_0x3e7b71('0x6c7')}],function(_0x17573a){return _0x2e3ca0()['replace'](_0x17573a['value'],new RegExp('\x27','g'),'');}),_0x2301c8[_0x3e7b71('0xc63')]=_0x25ee4b,_0x2301c8[_0x3e7b71('0x194f')]=_0x3ae83d,_0x2301c8[_0x3e7b71('0x53')]=_0x1ff6cb,_0x2301c8[_0x3e7b71('0x16dc')]=_0x33f1f3,_0x2301c8['createOrEditUser']=_0x33d007,_0x2301c8[_0x3e7b71('0x387')]=_0x512561,_0x2301c8[_0x3e7b71('0x5f')]=_0x15bda5,_0x2301c8[_0x3e7b71('0xf4d')]=_0x44eaaa,_0x2301c8[_0x3e7b71('0x25af')]=_0x1a1c7d,_0x2301c8[_0x3e7b71('0x5aa')]=_0x4125eb,_0x3c3c13['userProfile'][_0x3e7b71('0x1e6e')]({'fields':_0x3e7b71('0xa10'),'sort':'name'})[_0x3e7b71('0xe53')]['then'](function(_0x264a03){const _0x1a7b71=_0x3e7b71;_0x2301c8[_0x1a7b71('0x134e')]=_0x264a03[_0x1a7b71('0xf5d')]||[];})[_0x3e7b71('0x130a')](function(_0x3f0ea6){const _0x50cf76=_0x3e7b71;_0x548eb5[_0x50cf76('0x52a')]({'title':_0x3f0ea6[_0x50cf76('0x13ee')]?'API:'+_0x3f0ea6['status']+_0x50cf76('0xbf6')+_0x3f0ea6[_0x50cf76('0x24a9')]:_0x50cf76('0x172c'),'msg':_0x3f0ea6[_0x50cf76('0x5a5')]?JSON[_0x50cf76('0x258a')](_0x3f0ea6[_0x50cf76('0x5a5')]):_0x3f0ea6[_0x50cf76('0x1ff0')]()});});function _0x25ee4b(_0x519d77){const _0x156c76=_0x3e7b71;_0x32b21e['go'](_0x156c76('0x1e5e'),{'id':_0x519d77['id'],'user':_0x519d77,'crudPermissions':_0x2301c8[_0x156c76('0x1134')]});}function _0x3ae83d(_0x22f00a,_0x30f62d){const _0x572f45=_0x3e7b71,_0x2f8ff7=_0x10f5c2[_0x572f45('0x1c6f')]()[_0x572f45('0xf28')](_0x572f45('0x1b01')+_0x2e3ca0()[_0x572f45('0x1e03')](_0x572f45('0xc96'))+'?')['htmlContent'](_0x572f45('0xed5')+(_0x22f00a['name']||_0x572f45('0xc96'))+_0x572f45('0x20f1')+_0x572f45('0x1ee7'))[_0x572f45('0x1040')](_0x572f45('0x644'))[_0x572f45('0xe42')](_0x30f62d)['ok']('OK')[_0x572f45('0x19fb')](_0x572f45('0x16b8'));_0x10f5c2[_0x572f45('0x1d4')](_0x2f8ff7)['then'](function(){_0x512561(_0x22f00a);},function(){const _0x42bd4d=_0x572f45;console['log'](_0x42bd4d('0x16b8'));});}let _0x1986ac=!![],_0x37a476=0x1;_0x4b1b7d['$watch'](_0x3e7b71('0x1e1d'),function(_0x50466b,_0x378fd6){const _0x593ffa=_0x3e7b71;_0x1986ac?_0x348901(function(){_0x1986ac=![];}):(!_0x378fd6&&(_0x37a476=_0x2301c8['query'][_0x593ffa('0xdf8')]),_0x50466b!==_0x378fd6&&(_0x2301c8[_0x593ffa('0x23a2')][_0x593ffa('0xdf8')]=0x1),!_0x50466b&&(_0x2301c8['query']['page']=_0x37a476),_0x2301c8[_0x593ffa('0x16dc')]());});function _0x1ff6cb(_0x172fcc){const _0x3de9f3=_0x3e7b71;_0x2301c8[_0x3de9f3('0x3bf')]=_0x172fcc||{'count':0x0,'rows':[]};}function _0x33f1f3(){const _0x536f9b=_0x3e7b71;_0x2301c8[_0x536f9b('0x23a2')][_0x536f9b('0x1cc8')]=(_0x2301c8[_0x536f9b('0x23a2')][_0x536f9b('0xdf8')]-0x1)*_0x2301c8['query'][_0x536f9b('0x6f0')],_0x1673f9[_0x536f9b('0xca1')]('admin')?_0x2301c8['promise']=_0x3c3c13[_0x536f9b('0xc96')][_0x536f9b('0x1e6e')](_0x2301c8[_0x536f9b('0x23a2')],_0x1ff6cb)[_0x536f9b('0xe53')]:(_0x2301c8[_0x536f9b('0x23a2')]['id']=_0x2301c8[_0x536f9b('0x2a')]['id'],_0x2301c8[_0x536f9b('0x23a2')]['section']=_0x536f9b('0x2139'),_0x2301c8['promise']=_0x3c3c13[_0x536f9b('0x2a')]['getResources'](_0x2301c8[_0x536f9b('0x23a2')],_0x1ff6cb)['$promise']);}function _0x33d007(_0x135ccd,_0x278e17){const _0x4ed882=_0x3e7b71;_0x10f5c2['show']({'controller':_0x4ed882('0x14e6'),'controllerAs':'vm','templateUrl':_0x18b990,'parent':angular['element'](_0xbf2e9b['body']),'targetEvent':_0x135ccd,'clickOutsideToClose':!![],'locals':{'user':_0x278e17,'users':_0x2301c8[_0x4ed882('0x3bf')][_0x4ed882('0xf5d')],'license':_0x2301c8[_0x4ed882('0xace')],'setting':_0x2301c8[_0x4ed882('0x260a')],'crudPermissions':_0x2301c8[_0x4ed882('0x1134')]}});}function _0x512561(_0x46906f){const _0x2a3af8=_0x3e7b71;_0x3c3c13[_0x2a3af8('0xc96')][_0x2a3af8('0xd7e')]({'id':_0x46906f['id']})[_0x2a3af8('0xe53')][_0x2a3af8('0x683')](function(){const _0x4c452e=_0x2a3af8;_0x2e3ca0()[_0x4c452e('0x3ec')](_0x2301c8[_0x4c452e('0x3bf')][_0x4c452e('0xf5d')],{'id':_0x46906f['id']}),_0x2301c8['users'][_0x4c452e('0x50d')]-=0x1,!_0x2301c8['users']['rows'][_0x4c452e('0x1564')]&&_0x2301c8['getUsers'](),_0x548eb5[_0x4c452e('0x53')]({'title':_0x2e3ca0()[_0x4c452e('0x1e03')]('User')+_0x4c452e('0xbfc'),'msg':_0x46906f[_0x4c452e('0x60a')]?_0x46906f['name']+_0x4c452e('0x194d'):''});})[_0x2a3af8('0x130a')](function(_0x5f2165){const _0x300363=_0x2a3af8;if(_0x5f2165['data']&&_0x5f2165[_0x300363('0x5a5')][_0x300363('0x17f')]&&_0x5f2165['data'][_0x300363('0x17f')][_0x300363('0x1564')]){_0x2301c8[_0x300363('0x17f')]=_0x5f2165[_0x300363('0x5a5')][_0x300363('0x17f')]||[{'message':_0x5f2165[_0x300363('0x1ff0')](),'type':_0x300363('0x2484')}];for(let _0x3ca5ca=0x0;_0x3ca5ca<_0x5f2165[_0x300363('0x5a5')][_0x300363('0x17f')]['length'];_0x3ca5ca++){_0x548eb5[_0x300363('0x52a')]({'title':_0x5f2165[_0x300363('0x5a5')][_0x300363('0x17f')][_0x3ca5ca][_0x300363('0xcf0')],'msg':_0x5f2165['data'][_0x300363('0x17f')][_0x3ca5ca][_0x300363('0x8c2')]});}}else _0x548eb5['error']({'title':_0x5f2165[_0x300363('0x13ee')]?_0x300363('0x2168')+_0x5f2165[_0x300363('0x13ee')]+_0x300363('0xbf6')+_0x5f2165[_0x300363('0x24a9')]:'SYSTEM:DELETEuser','msg':_0x5f2165[_0x300363('0x5a5')]?JSON[_0x300363('0x258a')](_0x5f2165[_0x300363('0x5a5')]['message']):_0x5f2165[_0x300363('0x8c2')]||_0x5f2165[_0x300363('0x1ff0')]()});});}function _0x15bda5(){const _0x564081=_0x3e7b71,_0x4e648a=angular[_0x564081('0x1a86')](_0x2301c8[_0x564081('0x2140')]);return _0x2301c8[_0x564081('0x2140')]=[],_0x4e648a;}function _0x44eaaa(_0x338904){const _0x1eb650=_0x3e7b71,_0x4ca7fc=_0x10f5c2[_0x1eb650('0x1c6f')]()[_0x1eb650('0xf28')](_0x1eb650('0x1262'))[_0x1eb650('0x26e3')](_0x1eb650('0xed5')+_0x2301c8[_0x1eb650('0x2140')][_0x1eb650('0x1564')]+_0x1eb650('0x93c')+_0x1eb650('0x1ee7'))[_0x1eb650('0x1040')](_0x1eb650('0x70f'))['targetEvent'](_0x338904)['ok']('OK')[_0x1eb650('0x19fb')]('CANCEL');_0x10f5c2[_0x1eb650('0x1d4')](_0x4ca7fc)[_0x1eb650('0x683')](function(){const _0x1b2b2d=_0x1eb650;_0x2301c8[_0x1b2b2d('0x2140')][_0x1b2b2d('0x1299')](function(_0x3f71cd){_0x512561(_0x3f71cd);}),_0x2301c8[_0x1b2b2d('0x2140')]=[];});}function _0x1a1c7d(){_0x2301c8['selectedUsers']=[];}function _0x4125eb(){const _0x13a346=_0x3e7b71;_0x2301c8[_0x13a346('0x2140')]=_0x2301c8[_0x13a346('0x3bf')][_0x13a346('0xf5d')];}}const _0xe8bcad=_0x54eaa8,_0x1e6bff=_0x180212['p']+_0x189033('0x829'),_0x4fbe5d=_0x180212['p']+_0x189033('0x5e9'),_0x512796=_0x180212['p']+_0x189033('0x7cc'),_0x99eb9=_0x180212['p']+_0x189033('0xb6a'),_0x59a9b8=_0x180212['p']+_0x189033('0x138'),_0x492758=_0x180212['p']+_0x189033('0xa85'),_0x384a60=_0x180212['p']+_0x189033('0x76e'),_0xe8b6a7=_0x180212['p']+_0x189033('0x1328'),_0xeba0bf=_0x180212['p']+_0x189033('0x1858');_0x1bf6ce[_0x189033('0x14be')]=['$stateProvider',_0x189033('0x19ee')];function _0x1bf6ce(_0x527683,_0x2d36a7){const _0x246489=_0x189033;_0x527683[_0x246489('0x2598')](_0x246489('0x1918'),{'abstract':!![],'url':'/staff'})[_0x246489('0x2598')]('app.staff.users',{'url':_0x246489('0x2'),'views':{'content@app':{'templateUrl':_0x1e6bff,'controller':_0x246489('0xe9')}},'resolve':{'users':[_0x246489('0x4b1'),function(_0x562d2d){const _0x1f4b34=_0x246489;return _0x562d2d['resolve'](_0x1f4b34('0x25c9'),{'fields':_0x1f4b34('0x231a'),'role':_0x1f4b34('0x1b84'),'sort':_0x1f4b34('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x246489('0x4b1'),_0x246489('0xba1'),function(_0x449340,_0x40a5d9){const _0x13884e=_0x246489;return _0x40a5d9['hasRole'](_0x13884e('0x20c2'))?null:_0x449340[_0x13884e('0xed7')](_0x13884e('0x1464'),{'fields':_0x13884e('0x16f'),'id':_0x40a5d9[_0x13884e('0x20b2')]()['userProfileId']});}],'userProfileSection':['apiResolver',_0x246489('0xba1'),function(_0x585de8,_0x2c7a94){const _0x73129e=_0x246489;return _0x2c7a94[_0x73129e('0xca1')]('admin')?null:_0x585de8[_0x73129e('0xed7')](_0x73129e('0x360'),{'fields':_0x73129e('0x1f47'),'userProfileId':_0x2c7a94[_0x73129e('0x20b2')]()['userProfileId'],'sectionId':0xc9});}]},'authenticate':!![],'permissionId':0xc9,'bodyClass':_0x246489('0x1d3e')})[_0x246489('0x2598')](_0x246489('0x1e5e'),{'url':_0x246489('0x1560'),'params':{'user':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x4fbe5d,'controller':_0x246489('0x81d')}},'resolve':{'user':['apiResolver',_0x246489('0x8ea'),function(_0x339366,_0x5c5d5b){const _0x181e54=_0x246489;return _0x339366['resolve'](_0x181e54('0x25c9'),{'fields':'createdAt,updatedAt,role,userProfileId,id,fullname,name,email,phone,mobile,userpic,password,description,autointernal,internal,transport,nat,allow,context,callgroup,pickupgroup,passwordResetAt,apiKey,videosupport,disabled,blocked','id':_0x5c5d5b['id']});}],'userProfileSection':['apiResolver',_0x246489('0xba1'),function(_0x3a3b7e,_0x1eec4c){const _0x47be9a=_0x246489;return _0x3a3b7e[_0x47be9a('0xed7')](_0x47be9a('0x360'),{'fields':_0x47be9a('0x1f47'),'userProfileId':_0x1eec4c[_0x47be9a('0x20b2')]()[_0x47be9a('0x2f')],'sectionId':0xc9});}]},'authenticate':!![],'permissionId':0xc9,'bodyClass':'staff'})[_0x246489('0x2598')]('app.staff.agents',{'url':_0x246489('0xf1a'),'views':{'content@app':{'templateUrl':_0x512796,'controller':_0x246489('0x1559')}},'resolve':{'agents':[_0x246489('0x4b1'),'Auth',function(_0x575e98,_0x24ed81){const _0x2fa9c9=_0x246489;return _0x24ed81['hasRole'](_0x2fa9c9('0x20c2'))?_0x575e98[_0x2fa9c9('0xed7')]('user@get',{'fields':_0x2fa9c9('0xf3b'),'role':_0x2fa9c9('0x2327'),'sort':_0x2fa9c9('0xc36'),'limit':0xa,'offset':0x0}):_0x575e98[_0x2fa9c9('0xed7')](_0x2fa9c9('0x191b'),{'id':_0x24ed81[_0x2fa9c9('0x20b2')]()[_0x2fa9c9('0x2f')],'section':_0x2fa9c9('0x1bc0'),'fields':_0x2fa9c9('0xf3b'),'role':'agent','sort':_0x2fa9c9('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x246489('0x4b1'),_0x246489('0xba1'),function(_0x446d8e,_0x3c719c){const _0x36f515=_0x246489;return _0x3c719c[_0x36f515('0xca1')](_0x36f515('0x20c2'))?null:_0x446d8e[_0x36f515('0xed7')](_0x36f515('0x1464'),{'fields':_0x36f515('0x16f'),'id':_0x3c719c[_0x36f515('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x246489('0x4b1'),_0x246489('0xba1'),function(_0x55df6a,_0x2977d7){const _0x5b2f7d=_0x246489;return _0x2977d7[_0x5b2f7d('0xca1')](_0x5b2f7d('0x20c2'))?null:_0x55df6a['resolve'](_0x5b2f7d('0x360'),{'fields':_0x5b2f7d('0x1f47'),'userProfileId':_0x2977d7['getCurrentUser']()['userProfileId'],'sectionId':0xca});}]},'authenticate':!![],'permissionId':0xca,'bodyClass':'staff'})[_0x246489('0x2598')](_0x246489('0x2718'),{'url':'/:id?tab','params':{'agent':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x99eb9,'controller':_0x246489('0x20a7')}},'resolve':{'agent':[_0x246489('0x4b1'),_0x246489('0x8ea'),function(_0x5c5232,_0x24d6d6){const _0x1a9895=_0x246489;return _0x5c5232['resolve']('user@get',{'fields':_0x1a9895('0xf3b'),'id':_0x24d6d6['id']});}],'userProfileSection':[_0x246489('0x4b1'),'Auth',function(_0x191576,_0x26dd15){const _0x2faad1=_0x246489;return _0x191576['resolve'](_0x2faad1('0x360'),{'fields':_0x2faad1('0x1f47'),'userProfileId':_0x26dd15[_0x2faad1('0x20b2')]()[_0x2faad1('0x2f')],'sectionId':0xca});}]},'authenticate':!![],'permissionId':0xca,'bodyClass':_0x246489('0x1d3e')})[_0x246489('0x2598')](_0x246489('0x1bde'),{'url':_0x246489('0xe52'),'views':{'content@app':{'templateUrl':_0x59a9b8,'controller':_0x246489('0x158c')}},'resolve':{'telephones':[_0x246489('0x4b1'),_0x246489('0xba1'),function(_0x1e5e53,_0x12818f){const _0xd7f884=_0x246489;return _0x12818f['hasRole'](_0xd7f884('0x20c2'))?_0x1e5e53[_0xd7f884('0xed7')](_0xd7f884('0x25c9'),{'fields':'createdAt,updatedAt,id,role,fullname,name,email,password,description,autointernal,internal,voicemail,transport,nat,allow,callerid,context,callgroup,pickupgroup,videosupport,encryption,phone,mobile','role':_0xd7f884('0x24d3'),'sort':_0xd7f884('0xc36'),'limit':0xa,'offset':0x0}):_0x1e5e53[_0xd7f884('0xed7')](_0xd7f884('0x191b'),{'id':_0x12818f[_0xd7f884('0x20b2')]()[_0xd7f884('0x2f')],'section':_0xd7f884('0x193e'),'fields':_0xd7f884('0x2007'),'role':'telephone','sort':_0xd7f884('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver','Auth',function(_0x1b0380,_0x467a87){const _0x24320c=_0x246489;return _0x467a87[_0x24320c('0xca1')]('admin')?null:_0x1b0380[_0x24320c('0xed7')](_0x24320c('0x1464'),{'fields':_0x24320c('0x16f'),'id':_0x467a87[_0x24320c('0x20b2')]()[_0x24320c('0x2f')]});}],'userProfileSection':['apiResolver',_0x246489('0xba1'),function(_0x3e7ce0,_0x3d8b35){const _0x57794b=_0x246489;return _0x3d8b35[_0x57794b('0xca1')](_0x57794b('0x20c2'))?null:_0x3e7ce0['resolve']('userProfileSection@get',{'fields':_0x57794b('0x1f47'),'userProfileId':_0x3d8b35[_0x57794b('0x20b2')]()['userProfileId'],'sectionId':0xcb});}]},'authenticate':!![],'permissionId':0xcb,'bodyClass':_0x246489('0x1d3e')})[_0x246489('0x2598')]('app.staff.telephones.edit',{'url':_0x246489('0x1560'),'params':{'telephone':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x492758,'controller':'TelephoneController\x20as\x20vm'}},'resolve':{'telephone':[_0x246489('0x4b1'),_0x246489('0x8ea'),function(_0x2351c3,_0x4a447a){const _0x23fc9b=_0x246489;return _0x2351c3[_0x23fc9b('0xed7')](_0x23fc9b('0x25c9'),{'fields':_0x23fc9b('0x2007'),'id':_0x4a447a['id']});}],'userProfileSection':['apiResolver',_0x246489('0xba1'),function(_0x4be0dc,_0x370ef0){const _0x3c8a93=_0x246489;return _0x4be0dc[_0x3c8a93('0xed7')](_0x3c8a93('0x360'),{'fields':_0x3c8a93('0x1f47'),'userProfileId':_0x370ef0[_0x3c8a93('0x20b2')]()[_0x3c8a93('0x2f')],'sectionId':0xcb});}]},'authenticate':!![],'permissionId':0xcb,'bodyClass':_0x246489('0x1d3e')})['state'](_0x246489('0x2326'),{'url':_0x246489('0x247d'),'views':{'content@app':{'templateUrl':_0x384a60,'controller':_0x246489('0x112f')}},'resolve':{'teams':['apiResolver',_0x246489('0xba1'),function(_0x3bea3,_0x5e58bd){const _0x4e9f00=_0x246489;return _0x5e58bd[_0x4e9f00('0xca1')](_0x4e9f00('0x20c2'))?_0x3bea3['resolve']('team@get',{'fields':'createdAt,updatedAt,id,name,description','sort':_0x4e9f00('0xc36'),'limit':0xa,'offset':0x0}):_0x3bea3[_0x4e9f00('0xed7')](_0x4e9f00('0x191b'),{'id':_0x5e58bd['getCurrentUser']()[_0x4e9f00('0x2f')],'section':'Teams','fields':_0x4e9f00('0x120a'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x246489('0xba1'),function(_0x56d5c9,_0x5e861c){const _0x54eaed=_0x246489;return _0x5e861c['hasRole']('admin')?null:_0x56d5c9['resolve']('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x5e861c[_0x54eaed('0x20b2')]()[_0x54eaed('0x2f')]});}],'userProfileSection':['apiResolver',_0x246489('0xba1'),function(_0x48ea44,_0x43b637){const _0x28ff90=_0x246489;return _0x43b637['hasRole']('admin')?null:_0x48ea44['resolve']('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x43b637[_0x28ff90('0x20b2')]()[_0x28ff90('0x2f')],'sectionId':0xcc});}]},'authenticate':!![],'permissionId':0xcc,'bodyClass':_0x246489('0x1d3e')})[_0x246489('0x2598')]('app.staff.userProfiles',{'url':_0x246489('0x887'),'views':{'content@app':{'templateUrl':_0xe8b6a7,'controller':_0x246489('0x1f0a')}},'resolve':{'userProfiles':[_0x246489('0x4b1'),function(_0xfeae9c){const _0x2bd84a=_0x246489;return _0xfeae9c[_0x2bd84a('0xed7')](_0x2bd84a('0x1464'),{'fields':_0x2bd84a('0x15b4'),'sort':_0x2bd84a('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x246489('0x4b1'),_0x246489('0xba1'),function(_0x30c598,_0x517b89){const _0x214c1c=_0x246489;return _0x517b89[_0x214c1c('0xca1')](_0x214c1c('0x20c2'))?null:_0x30c598['resolve'](_0x214c1c('0x1464'),{'fields':'id,name,crudPermissions','id':_0x517b89[_0x214c1c('0x20b2')]()[_0x214c1c('0x2f')]});}],'userProfileSection':[_0x246489('0x4b1'),'Auth',function(_0x14c06d,_0x219925){const _0x2ded00=_0x246489;return _0x219925['hasRole'](_0x2ded00('0x20c2'))?null:_0x14c06d[_0x2ded00('0xed7')](_0x2ded00('0x360'),{'fields':_0x2ded00('0x1f47'),'userProfileId':_0x219925[_0x2ded00('0x20b2')]()[_0x2ded00('0x2f')],'sectionId':0xcd});}]},'authenticate':!![],'permissionId':0xcd,'bodyClass':_0x246489('0x1d3e')})[_0x246489('0x2598')](_0x246489('0xf6b'),{'url':'/:id?tab','params':{'userProfile':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0xeba0bf,'controller':_0x246489('0x117c')}},'resolve':{'userProfile':[_0x246489('0x4b1'),_0x246489('0x8ea'),function(_0x2130b4,_0x3ead8b){const _0x15639e=_0x246489;return _0x2130b4[_0x15639e('0xed7')](_0x15639e('0x1464'),{'fields':_0x15639e('0x15b4'),'id':_0x3ead8b['id']});}],'userProfileSection':['apiResolver',_0x246489('0xba1'),function(_0x2c9722,_0x3eb69e){const _0x538906=_0x246489;return _0x2c9722['resolve'](_0x538906('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x3eb69e[_0x538906('0x20b2')]()[_0x538906('0x2f')],'sectionId':0xcd});}]},'authenticate':!![],'permissionId':0xcd,'bodyClass':_0x246489('0x1d3e')}),_0x2d36a7[_0x246489('0x7d2')]('app/main/apps/staff');}angular[_0x189033('0x1e26')]('app.staff',[_0x189033('0x6cf'),'ngPassword','md.data.table','flow',_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),'ngAria',_0x189033('0x273d'),_0x189033('0x76'),_0x189033('0x516'),_0x189033('0x7fa'),_0x189033('0x197b'),'ngclipboard',_0x189033('0x153a'),_0x189033('0x1447'),_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),'angular.filter'])['config'](_0x1bf6ce)[_0x189033('0x1da3')]('AgentsController',_0x2b7a7c)[_0x189033('0x1da3')](_0x189033('0x1289'),_0x2f6477)[_0x189033('0x1da3')](_0x189033('0xd52'),_0x2d94f9)[_0x189033('0x1da3')](_0x189033('0x1d84'),_0x427d38)[_0x189033('0x1da3')](_0x189033('0x2619'),_0x3509a5)[_0x189033('0x1da3')](_0x189033('0x1e85'),_0x1f10c6)[_0x189033('0x1da3')]('AgentteamaddController',_0x53f356)['controller'](_0x189033('0x2607'),_0x1de80d)[_0x189033('0x1da3')](_0x189033('0xce8'),_0x39e58c)[_0x189033('0x1da3')]('TeamagentaddController',_0x36d148)[_0x189033('0x1da3')](_0x189033('0x39'),_0x493f82)['controller'](_0x189033('0x1ab9'),_0x53b450)[_0x189033('0x1da3')]('TelephonechangepasswordController',_0x44d10c)['controller'](_0x189033('0x286e'),_0x4817a9)['controller'](_0x189033('0x2573'),_0x5e8f1b)[_0x189033('0x1da3')]('CreateOrEditUserProfileDialogController',_0x250a4c)[_0x189033('0x1da3')](_0x189033('0x22f6'),_0x10b7a8)[_0x189033('0x1da3')](_0x189033('0x9e9'),_0x343a01)['controller'](_0x189033('0x1547'),_0x2b925e)['controller'](_0x189033('0xcbc'),_0x40f7c8)[_0x189033('0x1da3')](_0x189033('0x1cb3'),_0x928f34)['controller']('CreateOrEditUserDialogController',_0x3e3368)[_0x189033('0x1da3')](_0x189033('0x783'),_0x594b44)[_0x189033('0x1da3')](_0x189033('0x2260'),_0x343078)[_0x189033('0x1da3')]('UserchangepasswordController',_0x3eb755)['controller']('UserController',_0x156341)[_0x189033('0x1da3')](_0x189033('0x220'),_0xe8bcad);const _0xa81c32=_0x180212['p']+_0x189033('0x627'),_0x11956f=_0x180212['p']+'src/js/modules/main/apps/contactmanager/views/contacts/create/dialog.html/dialog.html';_0x57009b[_0x189033('0x14be')]=['$scope',_0x189033('0x16ea'),'$timeout',_0x189033('0x938'),'$stateParams',_0x189033('0x1e48'),'$q',_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x6d5'),'lists',_0x189033('0x74e'),_0x189033('0x1191'),_0x189033('0x1120'),_0x189033('0x1ce6'),'toasty',_0x189033('0xba1'),_0x189033('0xace')];function _0x57009b(_0x445112,_0x533d78,_0x2e1408,_0x20e342,_0x38ee37,_0x561dd,_0x444846,_0xe34858,_0xa3fc85,_0x3143e4,_0x978bcf,_0x1bcdb6,_0x425671,_0x212a1d,_0x27b7c4,_0x359f76,_0x403b07,_0x57ca6a,_0x2c8bb3){const _0x2901e2=_0x189033,_0x49fbc4=this;_0x49fbc4[_0x2901e2('0x11ed')]=_0x57ca6a[_0x2901e2('0x20b2')](),_0x49fbc4[_0x2901e2('0xace')]=_0x2c8bb3,_0x49fbc4['userProfile']=_0xe34858,_0x49fbc4[_0x2901e2('0x22df')]=_0xa3fc85&&_0xa3fc85[_0x2901e2('0x50d')]==0x1?_0xa3fc85[_0x2901e2('0xf5d')][0x0]:null,_0x49fbc4[_0x2901e2('0x1134')]=_0x57ca6a['parseCrudPermissions'](_0x49fbc4[_0x2901e2('0x22df')]?_0x49fbc4[_0x2901e2('0x22df')]['crudPermissions']:null);const _0x48f188=0x3c,_0x36ce96=_0x48f188*0x400*0x400;_0x49fbc4[_0x2901e2('0x8f')]={'target':_0x2901e2('0x2dd'),'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x36ce96,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x49fbc4[_0x2901e2('0x6d5')]=_0x978bcf||{'count':0x0,'rows':[]},_0x49fbc4[_0x2901e2('0x158e')]={'hidden':![],'hover':![],'isOpen':![]},_0x49fbc4[_0x2901e2('0x5c4')]=_0x2901e2('0x8e6'),_0x49fbc4[_0x2901e2('0x1243')]=[],_0x49fbc4[_0x2901e2('0xe01')]=_0x1bcdb6||{'rows':[],'count':0x0},_0x49fbc4[_0x2901e2('0x1191')]=_0x212a1d||{'rows':[],'count':0x0},_0x49fbc4[_0x2901e2('0x1ce6')]=_0x359f76||{'rows':[],'count':0x0},_0x49fbc4[_0x2901e2('0x74e')]=_0x425671,_0x49fbc4[_0x2901e2('0x1120')]=_0x27b7c4,_0x49fbc4['selectedTags']=[],_0x49fbc4[_0x2901e2('0x208a')]=null,_0x49fbc4['selectedCompany']=null,_0x49fbc4[_0x2901e2('0x23a2')]=_0x2e3ca0()[_0x2901e2('0xf22')]({'includeAll':!![],'sort':_0x2901e2('0xc36'),'limit':0xa,'offset':0x0,'page':0x1},_0x38ee37),_0x49fbc4[_0x2901e2('0x1249')]=_0x39bf95,_0x49fbc4['deleteconfirm']=_0x440034,_0x49fbc4['success']=_0x321e44,_0x49fbc4[_0x2901e2('0x16cb')]=_0x2e8098,_0x49fbc4[_0x2901e2('0x1028')]=_0x351f6f,_0x49fbc4[_0x2901e2('0x54e')]=_0x167b78,_0x49fbc4[_0x2901e2('0x1453')]=_0x5151e0,_0x49fbc4[_0x2901e2('0x5')]=_0x45738e,_0x49fbc4[_0x2901e2('0x1d20')]=_0x3d7d01,_0x49fbc4[_0x2901e2('0x1477')]=_0x242b2b,_0x49fbc4[_0x2901e2('0x1164')]=_0x216567,_0x49fbc4['deselectContacts']=_0x1e05ef,_0x49fbc4[_0x2901e2('0xd9b')]=_0x13e7b1,_0x49fbc4[_0x2901e2('0x25ec')]=_0x3b2655,_0x49fbc4[_0x2901e2('0x1694')]=_0x3a4185,_0x49fbc4[_0x2901e2('0x20a6')]=_0x7a37af,_0x49fbc4[_0x2901e2('0x1f4c')]=_0x48c406,_0x49fbc4['hasPermission']=_0x5d2770,_0x49fbc4[_0x2901e2('0x1aad')]=_0x4d6895;_0x20e342['params'][_0x2901e2('0x1e4f')]&&(_0x49fbc4[_0x2901e2('0x208a')]=_0x20e342[_0x2901e2('0x7f2')][_0x2901e2('0x1e4f')]);_0x20e342[_0x2901e2('0x7f2')][_0x2901e2('0x2883')]&&(_0x49fbc4['selectedCompany']=_0x20e342['params'][_0x2901e2('0x2883')]);_0x445112[_0x2901e2('0x186d')](_0x2901e2('0x12ef'),function(_0x5356fc){const _0x2cb7ec=_0x2901e2;_0x5356fc?_0x2e1408(function(){const _0x53ca97=a0_0x4e0a;_0x445112['tooltipVisible']=_0x49fbc4[_0x53ca97('0x158e')]['isOpen'];},0x258):_0x445112['tooltipVisible']=_0x49fbc4[_0x2cb7ec('0x158e')][_0x2cb7ec('0x15')];});function _0x351f6f(){const _0x13a459=_0x2901e2;if(!_0x57ca6a[_0x13a459('0xca1')](_0x13a459('0x20c2'))){const _0x307908=_0x2e3ca0()(_0x49fbc4[_0x13a459('0x6d5')][_0x13a459('0xf5d')])[_0x13a459('0x386')](function(_0x1e7d4d){return{'id':_0x1e7d4d['CompanyId']};})[_0x13a459('0xea6')]('id')[_0x13a459('0x25')](function(_0x2b0ccf){return _0x2b0ccf['id']&&_0x2b0ccf['id']>0x0;})[_0x13a459('0x12e8')](_0x49fbc4[_0x13a459('0x1191')][_0x13a459('0xf5d')],'id')[_0x13a459('0x1c6b')]();if(!_0x2e3ca0()[_0x13a459('0x173f')](_0x307908)){const _0x2b70d9=[];_0x307908[_0x13a459('0x1299')](function(_0x2fcb5e){const _0x3665f7=_0x13a459;_0x2b70d9['push'](_0x3143e4[_0x3665f7('0x27db')][_0x3665f7('0x1e6e')]({'id':_0x2fcb5e['id'],'fields':_0x3665f7('0xa10')})[_0x3665f7('0xe53')]);}),_0x444846['all'](_0x2b70d9)[_0x13a459('0x683')](function(_0x1c2af6){const _0x585a23=_0x13a459;_0x1c2af6[_0x585a23('0x1299')](function(_0x5e5241){const _0x3320de=_0x585a23,_0x24456a=_0x5e5241[_0x3320de('0x24e1')]();_0x24456a['canSelect']=![],_0x49fbc4['companies']['rows'][_0x3320de('0x1fd0')](_0x24456a);const _0x16088d={};_0x16088d[_0x24456a['id']]=_0x24456a[_0x3320de('0x60a')],_0x49fbc4['companiesMap']=_0x2e3ca0()[_0x3320de('0x20d9')](_0x49fbc4[_0x3320de('0x1120')],_0x16088d);});})['catch'](function(_0x3c2b9f){const _0x2d14b9=_0x13a459;_0x403b07['error']({'title':_0x3c2b9f['status']?_0x2d14b9('0x2168')+_0x3c2b9f[_0x2d14b9('0x13ee')]+_0x2d14b9('0xbf6')+_0x3c2b9f[_0x2d14b9('0x24a9')]:_0x2d14b9('0x13c5'),'msg':_0x3c2b9f[_0x2d14b9('0x5a5')]?JSON[_0x2d14b9('0x258a')](_0x3c2b9f[_0x2d14b9('0x5a5')][_0x2d14b9('0x8c2')]):_0x3c2b9f[_0x2d14b9('0x1ff0')]()});});}}}function _0x3a4185(_0x4b560e){const _0x2862c3=_0x2901e2,_0x592e38=_0x561dd[_0x2862c3('0xa84')]()['title'](_0x2862c3('0x1587'))[_0x2862c3('0x156b')]('List\x20name')[_0x2862c3('0x1040')](_0x2862c3('0x1f1'))[_0x2862c3('0xe42')](_0x4b560e)['ok']('Ok')[_0x2862c3('0x19fb')](_0x2862c3('0x253a'));return _0x561dd[_0x2862c3('0x1d4')](_0x592e38)[_0x2862c3('0x683')](function(_0x133bb5){const _0xade4cd=_0x2862c3;if(_0x133bb5)return _0x3143e4[_0xade4cd('0x259b')][_0xade4cd('0xb0a')]({'name':_0x133bb5});else _0x403b07[_0xade4cd('0x52a')]({'title':_0xade4cd('0x321'),'msg':'Invalid\x20list\x20name.'});})[_0x2862c3('0x683')](function(_0x4ad9b9){const _0x3e66b8=_0x2862c3;_0x4ad9b9&&(_0x49fbc4[_0x3e66b8('0xe01')][_0x3e66b8('0xf5d')]['push'](_0x4ad9b9),_0x403b07['success']({'title':_0x3e66b8('0x6e'),'msg':_0x4ad9b9[_0x3e66b8('0x60a')]?_0x4ad9b9['name']+_0x3e66b8('0x14b5'):''}));});}function _0x5d2770(){const _0x3c704a=_0x2901e2;return _0x57ca6a['hasPermission'](0x12f)||_0x57ca6a['hasRole'](_0x3c704a('0x20c2'));}function _0x7a37af(_0x63ed43){const _0x518bcf=_0x2901e2,_0x53284f=_0x561dd[_0x518bcf('0xa84')]()[_0x518bcf('0xf28')](_0x518bcf('0x1912'))[_0x518bcf('0x156b')](_0x518bcf('0x747'))['ariaLabel'](_0x518bcf('0x747'))[_0x518bcf('0xe42')](_0x63ed43)['ok']('Ok')['cancel'](_0x518bcf('0x253a'));return _0x561dd[_0x518bcf('0x1d4')](_0x53284f)[_0x518bcf('0x683')](function(_0x3dc769){const _0x2bdcf0=_0x518bcf;if(_0x3dc769)return _0x3143e4['cmCompany']['save']({'name':_0x3dc769});else _0x403b07[_0x2bdcf0('0x52a')]({'title':_0x2bdcf0('0x3c5'),'msg':_0x2bdcf0('0x10b9')});})[_0x518bcf('0x683')](function(_0x5128e3){const _0xce1e15=_0x518bcf;_0x5128e3&&(_0x49fbc4[_0xce1e15('0x1191')][_0xce1e15('0xf5d')][_0xce1e15('0x1fd0')](_0x5128e3),_0x403b07[_0xce1e15('0x53')]({'title':'Company\x20properly\x20created!','msg':_0x5128e3[_0xce1e15('0x60a')]?_0x5128e3[_0xce1e15('0x60a')]+_0xce1e15('0x14b5'):''}));});}function _0x3b2655(_0x38a137){const _0x5a3d19=_0x2901e2,_0xb9f039=_0x561dd[_0x5a3d19('0xa84')]()[_0x5a3d19('0xf28')](_0x5a3d19('0x1e92'))[_0x5a3d19('0x156b')](_0x5a3d19('0x1bbb'))[_0x5a3d19('0x1040')](_0x5a3d19('0x1bbb'))[_0x5a3d19('0xe42')](_0x38a137)['ok']('Ok')[_0x5a3d19('0x19fb')](_0x5a3d19('0x253a'));return _0x561dd['show'](_0xb9f039)['then'](function(_0x1b5a4d){const _0x389016=_0x5a3d19;if(_0x1b5a4d)return _0x3143e4[_0x389016('0x270')][_0x389016('0xb0a')]({'name':_0x1b5a4d});else _0x403b07['error']({'title':_0x389016('0x26b0'),'msg':_0x389016('0xe61')});})[_0x5a3d19('0x683')](function(_0x39843d){const _0x2f6769=_0x5a3d19;_0x39843d&&(_0x49fbc4[_0x2f6769('0x1ce6')][_0x2f6769('0xf5d')][_0x2f6769('0x1fd0')](_0x39843d),_0x403b07[_0x2f6769('0x53')]({'title':_0x2f6769('0x2594'),'msg':_0x39843d[_0x2f6769('0x270')]?_0x39843d[_0x2f6769('0x60a')]+_0x2f6769('0x14b5'):''}));});}function _0x48c406(_0x29c9ad,_0x5ed006){const _0x203bef=_0x2901e2,_0x3ab4a4=JSON['parse'](_0x5ed006);_0x561dd[_0x203bef('0x1d4')]({'controller':_0x203bef('0x1322'),'controllerAs':'vm','templateUrl':_0xa81c32,'parent':angular[_0x203bef('0x1fcc')](_0x533d78[_0x203bef('0x18e5')]),'clickOutsideToClose':![],'locals':{'lists':_0x1bcdb6,'companies':_0x212a1d,'file':_0x3ab4a4[_0x203bef('0x21dd')],'fields':_0x3ab4a4[_0x203bef('0x189a')],'license':_0x49fbc4['license']}})['then'](function(){const _0x1915f6=_0x203bef;_0x49fbc4[_0x1915f6('0x16cb')]();})[_0x203bef('0x130a')](function(){const _0x233c92=_0x203bef;console[_0x233c92('0x52a')]();});}function _0x39bf95(_0x5f1756){const _0x1b13ea=_0x2901e2;_0x20e342['go']('app.contactmanager.contacts.edit',{'id':_0x5f1756['id'],'crudPermissions':_0x49fbc4[_0x1b13ea('0x1134')]});}function _0x440034(_0x481c35,_0x4ecc4a){const _0x46c6c0=_0x2901e2,_0x58f132=_0x561dd[_0x46c6c0('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20contact?')[_0x46c6c0('0x26e3')](_0x46c6c0('0xed5')+(_0x481c35[_0x46c6c0('0xeef')]||_0x481c35[_0x46c6c0('0x1c92')]||_0x481c35[_0x46c6c0('0xd31')]||_0x46c6c0('0x1309'))+_0x46c6c0('0x20f1')+_0x46c6c0('0x1ee7'))[_0x46c6c0('0x1040')]('delete\x20contact')[_0x46c6c0('0xe42')](_0x4ecc4a)['ok']('OK')[_0x46c6c0('0x19fb')](_0x46c6c0('0x16b8'));_0x561dd[_0x46c6c0('0x1d4')](_0x58f132)[_0x46c6c0('0x683')](function(){_0x3d7d01(_0x481c35);});}function _0x4d6895(_0x5d9d2d){const _0x15efc9=_0x2901e2,_0x40d11d=[_0x15efc9('0x1853')];if(!_0x2e3ca0()[_0x15efc9('0x2292')](_0x40d11d,_0x5d9d2d[_0x15efc9('0x1197')]()))return _0x403b07['error']({'title':_0x15efc9('0xa00')+_0x5d9d2d[_0x15efc9('0x1197')](),'msg':_0x15efc9('0x2560')+_0x40d11d[_0x15efc9('0x1630')]()}),![];if(_0x5d9d2d[_0x15efc9('0x1a41')]>_0x36ce96)return _0x403b07[_0x15efc9('0x52a')]({'title':_0x15efc9('0x19a2'),'msg':_0x15efc9('0x1622')+_0x48f188+'MB'}),![];return!![];}let _0x3e2964=!![],_0x584e6c=0x1;_0x445112[_0x2901e2('0x186d')](_0x2901e2('0x1e1d'),function(_0x1dd9dc,_0x56407c){const _0x538c40=_0x2901e2;_0x3e2964?_0x2e1408(function(){_0x3e2964=![];}):(!_0x56407c&&(_0x584e6c=_0x49fbc4[_0x538c40('0x23a2')][_0x538c40('0xdf8')]),_0x1dd9dc!==_0x56407c&&(_0x49fbc4[_0x538c40('0x23a2')][_0x538c40('0xdf8')]=0x1),!_0x1dd9dc&&(_0x49fbc4[_0x538c40('0x23a2')][_0x538c40('0xdf8')]=_0x584e6c),_0x49fbc4[_0x538c40('0x16cb')]());},!![]),_0x445112[_0x2901e2('0x186d')]('vm.selectedList',function(_0x2e5fdb,_0x2a31b0){const _0x3770f3=_0x2901e2;_0x2e5fdb!==_0x2a31b0&&(_0x49fbc4[_0x3770f3('0x23a2')][_0x3770f3('0x1e4f')]=_0x49fbc4[_0x3770f3('0x208a')]||undefined,_0x49fbc4[_0x3770f3('0x16cb')]());}),_0x445112['$watch'](_0x2901e2('0x1b9f'),function(_0x24e694,_0x5557e2){const _0x549e6a=_0x2901e2;_0x24e694!==_0x5557e2&&(_0x49fbc4[_0x549e6a('0x23a2')][_0x549e6a('0x2883')]=_0x49fbc4[_0x549e6a('0x12d6')]||undefined,_0x49fbc4[_0x549e6a('0x16cb')]());}),_0x445112['$watch'](_0x2901e2('0x1874'),function(_0x131243,_0x62500e){const _0x5eb37a=_0x2901e2;(_0x131243['length']||_0x62500e[_0x5eb37a('0x1564')])&&_0x49fbc4[_0x5eb37a('0x16cb')]();});function _0x321e44(_0x22a3ea){const _0x52e728=_0x2901e2;_0x49fbc4[_0x52e728('0x6d5')]=_0x22a3ea||{'count':0x0,'rows':[]};}function _0x2e8098(){const _0x5b90c2=_0x2901e2;_0x49fbc4[_0x5b90c2('0x23a2')][_0x5b90c2('0x1cc8')]=(_0x49fbc4[_0x5b90c2('0x23a2')]['page']-0x1)*_0x49fbc4[_0x5b90c2('0x23a2')][_0x5b90c2('0x6f0')],_0x57ca6a[_0x5b90c2('0xca1')](_0x5b90c2('0x20c2'))?_0x49fbc4[_0x5b90c2('0x1883')]=_0x3143e4['cmContact'][_0x5b90c2('0x1e6e')](_0x49fbc4[_0x5b90c2('0x23a2')],_0x321e44)[_0x5b90c2('0xe53')]:(_0x49fbc4[_0x5b90c2('0x23a2')]['id']=_0x49fbc4['userProfile']['id'],_0x49fbc4[_0x5b90c2('0x23a2')][_0x5b90c2('0x1e4f')]=!_0x49fbc4[_0x5b90c2('0x23a2')]['ListId']?_0x2e3ca0()['map'](_0x49fbc4[_0x5b90c2('0xe01')][_0x5b90c2('0xf5d')],'id'):_0x49fbc4['query'][_0x5b90c2('0x1e4f')],_0x49fbc4[_0x5b90c2('0x23a2')][_0x5b90c2('0x2883')]=!_0x49fbc4[_0x5b90c2('0x23a2')][_0x5b90c2('0x2883')]?_0x2e3ca0()(_0x49fbc4['companies'][_0x5b90c2('0xf5d')])[_0x5b90c2('0x25')]({'canSelect':undefined})['map']('id')[_0x5b90c2('0x1c6b')]():_0x49fbc4[_0x5b90c2('0x23a2')][_0x5b90c2('0x2883')],_0x49fbc4[_0x5b90c2('0x23a2')]['section']=_0x5b90c2('0xdb2'),_0x49fbc4[_0x5b90c2('0x1883')]=_0x3143e4[_0x5b90c2('0x2a')]['getResources'](_0x49fbc4[_0x5b90c2('0x23a2')],_0x321e44)[_0x5b90c2('0xe53')]);}function _0x45738e(_0x82a1d0,_0x2c4e0c){const _0x1b78f8=_0x2901e2;_0x2c4e0c&&_0x2c4e0c['dateOfBirth']&&(_0x2c4e0c[_0x1b78f8('0x26a7')]=new Date(_0x2c4e0c['dateOfBirth'])),_0x561dd[_0x1b78f8('0x1d4')]({'controller':_0x1b78f8('0x679'),'controllerAs':'vm','templateUrl':_0x11956f,'parent':angular[_0x1b78f8('0x1fcc')](_0x533d78[_0x1b78f8('0x18e5')]),'targetEvent':_0x82a1d0,'clickOutsideToClose':!![],'locals':{'ListId':_0x49fbc4[_0x1b78f8('0x23a2')][_0x1b78f8('0x1e4f')]||_0x20e342[_0x1b78f8('0x7f2')][_0x1b78f8('0x1e4f')],'CompanyId':_0x49fbc4[_0x1b78f8('0x23a2')]['CompanyId']||_0x20e342[_0x1b78f8('0x7f2')][_0x1b78f8('0x2883')],'contact':_0x2c4e0c,'contacts':_0x49fbc4[_0x1b78f8('0x6d5')][_0x1b78f8('0xf5d')],'companies':_0x49fbc4[_0x1b78f8('0x1191')],'lists':_0x49fbc4[_0x1b78f8('0xe01')],'setting':null,'crudPermissions':_0x49fbc4[_0x1b78f8('0x1134')]}});}function _0x5151e0(_0x3762ef,_0x3ce13b){const _0x266db5=_0x2901e2;_0x561dd[_0x266db5('0x1d4')]({'controller':_0x266db5('0x1757'),'controllerAs':'vm','templateUrl':_0x24dbc7,'parent':angular[_0x266db5('0x1fcc')](_0x533d78[_0x266db5('0x18e5')]),'targetEvent':_0x3762ef,'clickOutsideToClose':!![],'resolve':{'contact':[_0x266db5('0x4b1'),function(_0x10685c){const _0x331d7b=_0x266db5;return _0x10685c[_0x331d7b('0xed7')](_0x331d7b('0x23ec'),{'id':_0x3ce13b['id']});}],'lists':[_0x266db5('0x4b1'),_0x266db5('0xba1'),function(_0x5ddf78,_0x5a7ee4){const _0x53dcae=_0x266db5;return _0x5a7ee4[_0x53dcae('0xca1')]('admin')?_0x5ddf78[_0x53dcae('0xed7')](_0x53dcae('0xa7b'),{'fields':_0x53dcae('0xa10'),'nolimit':!![]}):_0x5ddf78[_0x53dcae('0xed7')](_0x53dcae('0x191b'),{'id':_0x5a7ee4[_0x53dcae('0x20b2')]()[_0x53dcae('0x2f')],'section':'Lists','fields':'id,name','nolimit':!![]});}]},'locals':{'contacts':_0x49fbc4[_0x266db5('0x6d5')][_0x266db5('0xf5d')]}});}function _0x167b78(_0x3dcb23,_0xa734c4){const _0x1e7176=_0x2901e2;_0x561dd[_0x1e7176('0x1d4')]({'controller':_0x1e7176('0x264'),'controllerAs':'vm','templateUrl':_0x7650f,'parent':angular['element'](_0x533d78[_0x1e7176('0x18e5')]),'targetEvent':_0x3dcb23,'clickOutsideToClose':!![],'resolve':{'contact':[_0x1e7176('0x4b1'),function(_0x4412f4){const _0x63cd5c=_0x1e7176;return _0x4412f4[_0x63cd5c('0xed7')]('cmContact@get',{'id':_0xa734c4['id']});}],'lists':['apiResolver','Auth',function(_0x4905fa,_0x305b66){const _0xe043f4=_0x1e7176;return _0x305b66['hasRole'](_0xe043f4('0x20c2'))?_0x4905fa[_0xe043f4('0xed7')]('cmList@get',{'fields':_0xe043f4('0xa10'),'nolimit':!![]}):_0x4905fa['resolve'](_0xe043f4('0x191b'),{'id':_0x305b66[_0xe043f4('0x20b2')]()['userProfileId'],'section':_0xe043f4('0x1114'),'fields':_0xe043f4('0xa10'),'nolimit':!![]});}]},'locals':{'contacts':_0x49fbc4[_0x1e7176('0x6d5')][_0x1e7176('0xf5d')]}});}function _0x3d7d01(_0x426939){const _0x976d69=_0x2901e2;_0x3143e4[_0x976d69('0x276e')][_0x976d69('0xd7e')]({'id':_0x426939['id']})[_0x976d69('0xe53')][_0x976d69('0x683')](function(){const _0x4294ef=_0x976d69;_0x2e3ca0()[_0x4294ef('0x3ec')](_0x49fbc4[_0x4294ef('0x6d5')][_0x4294ef('0xf5d')],{'id':_0x426939['id']}),_0x49fbc4[_0x4294ef('0x6d5')][_0x4294ef('0x50d')]-=0x1,!_0x49fbc4[_0x4294ef('0x6d5')]['rows'][_0x4294ef('0x1564')]&&_0x49fbc4[_0x4294ef('0x16cb')](),_0x403b07[_0x4294ef('0x53')]({'title':_0x4294ef('0x54d'),'msg':_0x426939[_0x4294ef('0x60a')]?_0x426939[_0x4294ef('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0x976d69('0x130a')](function(_0x3f9435){const _0x8c6030=_0x976d69;if(_0x3f9435[_0x8c6030('0x5a5')]&&_0x3f9435['data']['errors']&&_0x3f9435[_0x8c6030('0x5a5')][_0x8c6030('0x17f')]['length']){_0x49fbc4[_0x8c6030('0x17f')]=_0x3f9435['data'][_0x8c6030('0x17f')]||[{'message':_0x3f9435[_0x8c6030('0x1ff0')](),'type':_0x8c6030('0x1c65')}];for(let _0x932007=0x0;_0x932007<_0x3f9435[_0x8c6030('0x5a5')][_0x8c6030('0x17f')]['length'];_0x932007++){_0x403b07[_0x8c6030('0x52a')]({'title':_0x3f9435['data'][_0x8c6030('0x17f')][_0x932007]['type'],'msg':_0x3f9435[_0x8c6030('0x5a5')]['errors'][_0x932007][_0x8c6030('0x8c2')]});}}else _0x403b07[_0x8c6030('0x52a')]({'title':_0x3f9435[_0x8c6030('0x13ee')]?_0x8c6030('0x2168')+_0x3f9435[_0x8c6030('0x13ee')]+'\x20-\x20'+_0x3f9435[_0x8c6030('0x24a9')]:_0x8c6030('0x1c65'),'msg':_0x3f9435['data']?JSON[_0x8c6030('0x258a')](_0x3f9435[_0x8c6030('0x5a5')][_0x8c6030('0x8c2')]):_0x3f9435['message']||_0x3f9435['toString']()});});}function _0x242b2b(){const _0x27e58e=_0x2901e2,_0x24309c=angular['copy'](_0x49fbc4['selectedContacts']);return _0x49fbc4[_0x27e58e('0x1243')]=[],_0x24309c;}function _0x216567(_0x467a92){const _0x25a861=_0x2901e2,_0x3e1ead=_0x561dd[_0x25a861('0x1c6f')]()[_0x25a861('0xf28')](_0x25a861('0x1aa0'))[_0x25a861('0x26e3')](_0x25a861('0xed5')+_0x49fbc4[_0x25a861('0x1243')][_0x25a861('0x1564')]+_0x25a861('0x93c')+_0x25a861('0x1ee7'))['ariaLabel'](_0x25a861('0x19fa'))['targetEvent'](_0x467a92)['ok']('OK')[_0x25a861('0x19fb')](_0x25a861('0x16b8'));_0x561dd['show'](_0x3e1ead)[_0x25a861('0x683')](function(){const _0x22e295=_0x25a861;_0x49fbc4[_0x22e295('0x1243')]['forEach'](function(_0x165a39){_0x3d7d01(_0x165a39);}),_0x49fbc4['selectedContacts']=[];});}function _0x1e05ef(){_0x49fbc4['selectedContacts']=[];}function _0x13e7b1(){const _0x277287=_0x2901e2;_0x49fbc4[_0x277287('0x1243')]=_0x49fbc4[_0x277287('0x6d5')][_0x277287('0xf5d')];}}const _0x27017a=_0x57009b;_0x4695a6['$inject']=[_0x189033('0x1e48'),'toasty','contacts',_0x189033('0xe01'),_0x189033('0x1191'),_0x189033('0xd06'),_0x189033('0x1e4f'),_0x189033('0x2883'),_0x189033('0x56b'),_0x189033('0x1134')];function _0x4695a6(_0x925616,_0x437e13,_0x38b75c,_0x2d385c,_0x5dfdd3,_0x1e865e,_0x1f7c9d,_0x54e4f1,_0x11336e,_0x1d90bc){const _0x5e8016=_0x189033,_0x19a696=this;_0x19a696['errors']=[],_0x19a696['title']=_0x5e8016('0x2103'),_0x19a696['crudPermissions']=_0x1d90bc,_0x19a696[_0x5e8016('0xd06')]=angular[_0x5e8016('0x1a86')](_0x1e865e),_0x19a696[_0x5e8016('0x6d5')]=_0x38b75c||{'rows':[],'count':0x0},_0x19a696[_0x5e8016('0xe01')]=_0x2d385c||{'rows':[],'count':0x0},_0x19a696[_0x5e8016('0x1191')]=_0x5dfdd3||{'rows':[],'count':0x0},_0x19a696[_0x5e8016('0xc4d')]={'rows':[],'count':0x0},_0x19a696[_0x5e8016('0x2337')]=![];!_0x19a696['contact']?(_0x19a696['contact']={'ListId':_0x1f7c9d?parseInt(_0x1f7c9d,0xa):undefined,'CompanyId':_0x54e4f1?parseInt(_0x54e4f1,0xa):undefined},_0x19a696[_0x5e8016('0xf28')]=_0x5e8016('0x1f8'),_0x19a696['newContact']=!![]):(delete _0x19a696['contact']['List'],_0x19a696['ListId']=_0x19a696[_0x5e8016('0xd06')][_0x5e8016('0x1e4f')]||undefined);_0x19a696[_0x5e8016('0x1c03')]=_0x280dc3,_0x19a696[_0x5e8016('0x206f')]=_0x51dfd4,_0x19a696[_0x5e8016('0x1d20')]=_0x248582,_0x19a696[_0x5e8016('0xf82')]=_0x5c2cf3,_0x19a696[_0x5e8016('0xcb')]=_0x111805,_0x19a696['getDateFromString']=_0x4ea725;function _0x280dc3(){const _0x211658=_0x5e8016;_0x19a696['errors']=[],_0x11336e[_0x211658('0x276e')][_0x211658('0xb0a')](_0x19a696[_0x211658('0xd06')])[_0x211658('0xe53')][_0x211658('0x683')](function(_0x4755cf){const _0xad0a31=_0x211658;_0x19a696[_0xad0a31('0x6d5')]['unshift'](_0x4755cf),_0x437e13['success']({'title':_0xad0a31('0x174a'),'msg':_0x19a696[_0xad0a31('0xd06')][_0xad0a31('0x60a')]?_0x19a696[_0xad0a31('0xd06')][_0xad0a31('0x60a')]+'\x20has\x20been\x20created!':''}),_0x5c2cf3();})[_0x211658('0x130a')](function(_0x290b93){const _0x55e363=_0x211658;if(_0x290b93[_0x55e363('0x5a5')]&&_0x290b93[_0x55e363('0x5a5')][_0x55e363('0x17f')]&&_0x290b93[_0x55e363('0x5a5')]['errors'][_0x55e363('0x1564')]){_0x19a696[_0x55e363('0x17f')]=_0x290b93[_0x55e363('0x5a5')][_0x55e363('0x17f')]||[{'message':_0x290b93[_0x55e363('0x1ff0')](),'type':'api.user.save'}];for(let _0x395745=0x0;_0x395745<_0x290b93['data'][_0x55e363('0x17f')][_0x55e363('0x1564')];_0x395745++){_0x437e13[_0x55e363('0x52a')]({'title':_0x290b93[_0x55e363('0x5a5')][_0x55e363('0x17f')][_0x395745]['type'],'msg':_0x290b93['data'][_0x55e363('0x17f')][_0x395745]['message']});}}else _0x437e13['error']({'title':_0x290b93[_0x55e363('0x13ee')]?'API:'+_0x290b93['status']+_0x55e363('0xbf6')+_0x290b93[_0x55e363('0x24a9')]:'api.contacts.save','msg':_0x290b93[_0x55e363('0x5a5')]?JSON[_0x55e363('0x258a')](_0x290b93[_0x55e363('0x5a5')][_0x55e363('0x8c2')]):_0x290b93[_0x55e363('0x1ff0')]()});});}function _0x51dfd4(){const _0x289fb9=_0x5e8016;_0x19a696['errors']=[],_0x11336e[_0x289fb9('0x276e')][_0x289fb9('0x2480')]({'id':_0x19a696[_0x289fb9('0xd06')]['id']},_0x19a696['contact'])[_0x289fb9('0xe53')][_0x289fb9('0x683')](function(_0x44b771){const _0x3c9430=_0x289fb9,_0x2387ce=_0x2e3ca0()[_0x3c9430('0x1c07')](_0x19a696['contacts'],{'id':_0x44b771['id']});_0x2387ce&&_0x2e3ca0()[_0x3c9430('0xf22')](_0x2387ce,_0x44b771),_0x437e13[_0x3c9430('0x53')]({'title':'Contact\x20properly\x20saved!','msg':_0x19a696[_0x3c9430('0xd06')]['name']?_0x19a696[_0x3c9430('0xd06')][_0x3c9430('0x60a')]+_0x3c9430('0xf59'):''}),_0x5c2cf3();})[_0x289fb9('0x130a')](function(_0x5c9fe7){const _0x3022f1=_0x289fb9;if(_0x5c9fe7[_0x3022f1('0x5a5')]&&_0x5c9fe7['data']['errors']&&_0x5c9fe7[_0x3022f1('0x5a5')][_0x3022f1('0x17f')][_0x3022f1('0x1564')]){_0x19a696[_0x3022f1('0x17f')]=_0x5c9fe7[_0x3022f1('0x5a5')][_0x3022f1('0x17f')]||[{'message':_0x5c9fe7[_0x3022f1('0x1ff0')](),'type':_0x3022f1('0x3dd')}];for(let _0x1c2575=0x0;_0x1c2575<_0x5c9fe7['data'][_0x3022f1('0x17f')]['length'];_0x1c2575++){_0x437e13['error']({'title':_0x5c9fe7['data'][_0x3022f1('0x17f')][_0x1c2575][_0x3022f1('0xcf0')],'msg':_0x5c9fe7[_0x3022f1('0x5a5')][_0x3022f1('0x17f')][_0x1c2575][_0x3022f1('0x8c2')]});}}else _0x437e13[_0x3022f1('0x52a')]({'title':_0x5c9fe7['status']?'API:'+_0x5c9fe7[_0x3022f1('0x13ee')]+_0x3022f1('0xbf6')+_0x5c9fe7[_0x3022f1('0x24a9')]:_0x3022f1('0x3dd'),'msg':_0x5c9fe7[_0x3022f1('0x5a5')]?JSON['stringify'](_0x5c9fe7[_0x3022f1('0x5a5')][_0x3022f1('0x8c2')]):_0x5c9fe7['toString']()});});}function _0x111805(_0x431194){const _0x1a5ae6=_0x5e8016;if(_0x431194)return _0x11336e[_0x1a5ae6('0x259b')][_0x1a5ae6('0xcb')]({'id':_0x431194})[_0x1a5ae6('0xe53')]['then'](function(_0x507b15){const _0x1f3b5e=_0x1a5ae6;if(_0x507b15){_0x19a696[_0x1f3b5e('0xc4d')]=_0x507b15;const _0x4e8786=_0x2e3ca0()[_0x1f3b5e('0x386')](_0x19a696[_0x1f3b5e('0xc4d')][_0x1f3b5e('0xf5d')],function(_0x4436fc){const _0x4b9fbf=_0x1f3b5e;return _0x4b9fbf('0x1469')+_0x4436fc['id'];});_0x11336e[_0x1f3b5e('0x276e')][_0x1f3b5e('0x1e6e')]({'id':_0x19a696[_0x1f3b5e('0xd06')]['id'],'attributes':_0x4e8786,'raw':!![]})[_0x1f3b5e('0xe53')][_0x1f3b5e('0x683')](function(_0x37cfc7){const _0x5881c8=_0x1f3b5e;_0x19a696[_0x5881c8('0xd06')]=_0x2e3ca0()[_0x5881c8('0xf22')](_0x19a696[_0x5881c8('0xd06')],_0x37cfc7);});}})['catch'](function(_0x5e11bd){console['error'](_0x5e11bd);});else _0x19a696[_0x1a5ae6('0xc4d')]={'rows':[],'count':0x0};}function _0x248582(_0x27ccb4){const _0x530db5=_0x5e8016;_0x19a696['errors']=[];const _0x2deb1d=_0x925616[_0x530db5('0x1c6f')]()[_0x530db5('0xf28')]('Are\x20you\x20sure?')[_0x530db5('0xa6a')](_0x530db5('0x1b61'))[_0x530db5('0x1040')](_0x530db5('0xe9e'))['ok'](_0x530db5('0x2307'))[_0x530db5('0x19fb')](_0x530db5('0x253a'))[_0x530db5('0xe42')](_0x27ccb4);_0x925616['show'](_0x2deb1d)['then'](function(){const _0x1bbf86=_0x530db5;_0x11336e[_0x1bbf86('0x276e')][_0x1bbf86('0xd7e')]({'id':_0x19a696['contact']['id']})[_0x1bbf86('0xe53')]['then'](function(){const _0x4aa9f9=_0x1bbf86;_0x2e3ca0()[_0x4aa9f9('0x3ec')](_0x19a696[_0x4aa9f9('0x6d5')],{'id':_0x19a696['contact']['id']}),_0x437e13['success']({'title':'Contact\x20properly\x20deleted!','msg':_0x19a696['contact'][_0x4aa9f9('0x60a')]?_0x19a696['contact'][_0x4aa9f9('0x60a')]+_0x4aa9f9('0x194d'):''}),_0x5c2cf3();})[_0x1bbf86('0x130a')](function(_0x34b491){const _0x30f2c7=_0x1bbf86;console[_0x30f2c7('0x52a')](_0x34b491),_0x19a696[_0x30f2c7('0x17f')]=_0x34b491[_0x30f2c7('0x5a5')]['errors']||[{'message':_0x34b491[_0x30f2c7('0x1ff0')](),'type':_0x30f2c7('0x1c65')}];});},function(){});}function _0x4ea725(_0x28012f){return _0x28012f===null?undefined:new Date(_0x28012f);}function _0x5c2cf3(){const _0x15decf=_0x5e8016;_0x925616[_0x15decf('0x1715')]();}}const _0x5a2d21=_0x4695a6;_0x3ce17a['$inject']=[_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0xd06'),_0x189033('0x6d5'),_0x189033('0xe01'),_0x189033('0x56b')];function _0x3ce17a(_0x41c2c6,_0xe5fb42,_0x5e43e5,_0x24fd4a,_0x2792d0,_0x10e62e){const _0x427753=_0x189033,_0x58363e=this;_0x58363e[_0x427753('0x17f')]=[],_0x58363e[_0x427753('0xf28')]=_0x427753('0xa2'),_0x58363e[_0x427753('0xd06')]=angular['copy'](_0x5e43e5),_0x58363e['lists']=_0x2792d0||{'rows':[],'count':0x0},_0x58363e[_0x427753('0x1c03')]=_0x2b77de,_0x58363e[_0x427753('0xf82')]=_0x31b6d6;function _0x2b77de(){const _0x536fb7=_0x427753;_0x58363e[_0x536fb7('0x17f')]=[],delete _0x58363e[_0x536fb7('0xd06')]['id'],_0x58363e[_0x536fb7('0xd06')][_0x536fb7('0x1ce6')]&&!_0x58363e[_0x536fb7('0xd06')][_0x536fb7('0x1ce6')][_0x536fb7('0x1564')]&&delete _0x58363e['contact'][_0x536fb7('0x1ce6')],_0x10e62e[_0x536fb7('0x276e')][_0x536fb7('0xb0a')](_0x58363e[_0x536fb7('0xd06')])[_0x536fb7('0xe53')][_0x536fb7('0x683')](function(_0x3c6056){const _0x17b0dd=_0x536fb7;_0x24fd4a['unshift'](_0x3c6056),_0xe5fb42[_0x17b0dd('0x53')]({'title':'Contact\x20properly\x20created','msg':_0x58363e[_0x17b0dd('0xd06')]['name']?_0x58363e[_0x17b0dd('0xd06')]['name']+_0x17b0dd('0x14b5'):''}),_0x31b6d6();})[_0x536fb7('0x130a')](function(_0x39b832){const _0x7aa2de=_0x536fb7;console[_0x7aa2de('0x52a')](_0x39b832),_0x58363e[_0x7aa2de('0x17f')]=_0x39b832['data'][_0x7aa2de('0x17f')]||[{'message':_0x39b832[_0x7aa2de('0x1ff0')](),'type':_0x7aa2de('0xafc')}];});}function _0x31b6d6(){const _0xf9b78b=_0x427753;_0x41c2c6[_0xf9b78b('0x1715')]();}}const _0x294143=_0x3ce17a;_0x24da03[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state','$location',_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x1c63'),_0x189033('0x1da2'),_0x189033('0x56b'),_0x189033('0x1134')];function _0x24da03(_0x1190b0,_0x22488b,_0x4e5178,_0x2a1c16,_0x24f54e,_0x3d1c16,_0x30550e,_0x43467d,_0x7afb87){const _0x43f8c5=_0x189033,_0x2a7540=this;_0x2a7540['errors']=[],_0x2a7540[_0x43f8c5('0xf28')]=_0x43f8c5('0xc88'),_0x2a7540[_0x43f8c5('0x1da2')]=angular[_0x43f8c5('0x1a86')](_0x30550e),_0x2a7540[_0x43f8c5('0x1c63')]=_0x3d1c16,_0x2a7540[_0x43f8c5('0x7b6')]=![],_0x2a7540['crudPermissions']=_0x7afb87;!_0x2a7540[_0x43f8c5('0x1da2')]&&(_0x2a7540[_0x43f8c5('0x1da2')]={},_0x2a7540[_0x43f8c5('0xf28')]=_0x43f8c5('0x123b'),_0x2a7540[_0x43f8c5('0x7b6')]=!![]);_0x2a7540[_0x43f8c5('0xdab')]=_0x1da028,_0x2a7540[_0x43f8c5('0x16b3')]=_0x48f43f,_0x2a7540[_0x43f8c5('0xf82')]=_0x385575;function _0x1da028(){const _0x2b2b1c=_0x43f8c5;_0x2a7540[_0x2b2b1c('0x17f')]=[],_0x43467d[_0x2b2b1c('0x26cf')][_0x2b2b1c('0x2480')]({'id':_0x2a7540[_0x2b2b1c('0x1da2')]['id']},_0x2a7540[_0x2b2b1c('0x1da2')])[_0x2b2b1c('0xe53')]['then'](function(_0x305b81){const _0x297984=_0x2b2b1c,_0x414eb1=_0x2e3ca0()['find'](_0x2a7540[_0x297984('0x1c63')],{'id':_0x305b81['id']});_0x414eb1&&_0x2e3ca0()[_0x297984('0xf22')](_0x414eb1,_0x305b81),_0x24f54e['success']({'title':'Hopper\x20properly\x20saved!','msg':_0x2a7540[_0x297984('0x1da2')]['name']?_0x2a7540['hopper'][_0x297984('0x60a')]+_0x297984('0xf59'):''}),_0x385575(_0x305b81);})['catch'](function(_0x1ee15b){const _0x4222ee=_0x2b2b1c;console[_0x4222ee('0x52a')](_0x1ee15b),_0x2a7540[_0x4222ee('0x17f')]=_0x1ee15b['data'][_0x4222ee('0x17f')]||[{'message':_0x1ee15b[_0x4222ee('0x1ff0')](),'type':_0x4222ee('0x83b')}];});}function _0x48f43f(_0x11a8b0){return _0x11a8b0===null?undefined:new Date(_0x11a8b0);}function _0x385575(_0x4c361a){const _0x4c4f3d=_0x43f8c5;_0x2a1c16[_0x4c4f3d('0x1715')](_0x4c361a);}}const _0x3ec880=_0x24da03,_0x4eeff0=_0x180212['p']+'src/js/modules/main/apps/motiondialer/views/ivrCampaigns/edit/hoppers/dialog.html/dialog.html';_0x346590[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x938'),_0x189033('0x16ea'),_0x189033('0x1e48'),_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xd06'),_0x189033('0x1c63'),'finals',_0x189033('0x1f3f'),_0x189033('0x6d5'),_0x189033('0x1191'),_0x189033('0xe01'),_0x189033('0xc4d'),_0x189033('0x1ce6'),_0x189033('0x867'),_0x189033('0xace'),_0x189033('0xba1'),'userProfileSection'];function _0x346590(_0x4ca66c,_0x5e37e4,_0x5e5fcb,_0x412705,_0x2575a3,_0x5121e0,_0x4c1913,_0x399024,_0x174d6b,_0x2c45fb,_0x230efb,_0x41d23c,_0x3ac35a,_0x17a102,_0x37a639,_0x4c67a6,_0x3ccc38,_0x2fa13c,_0x1459f0,_0x4ea629,_0x26d66b){const _0x416c11=_0x189033,_0x122728=this;_0x122728[_0x416c11('0x11ed')]=_0x4ea629['getCurrentUser'](),_0x122728[_0x416c11('0xace')]=_0x1459f0,_0x122728[_0x416c11('0x18b')]=[],_0x122728[_0x416c11('0xd06')]=_0x174d6b||{},_0x122728[_0x416c11('0x1c63')]=_0x2c45fb||{'rows':[],'count':0x0},_0x122728[_0x416c11('0x157d')]=_0x230efb||{'rows':[],'count':0x0},_0x122728[_0x416c11('0x1f3f')]=_0x41d23c||{'rows':[],'count':0x0},_0x122728[_0x416c11('0x1191')]=_0x17a102||{'rows':[],'count':0x0},_0x122728[_0x416c11('0xe01')]=_0x37a639||{'rows':[],'count':0x0},_0x122728[_0x416c11('0xc4d')]=_0x4c67a6||{'rows':[],'count':0x0},_0x122728[_0x416c11('0x1ce6')]=_0x3ccc38||{'rows':[],'count':0x0},_0x122728[_0x416c11('0x867')]=_0x2fa13c||{'rows':[],'count':0x0},_0x122728[_0x416c11('0x1c87')]={'scrollEl':_0x416c11('0x1789')},_0x122728[_0x416c11('0xe5f')]=new Date(_0x1aaf93()()[_0x416c11('0x1627')](_0x416c11('0x55b'))[_0x416c11('0x1315')](0x1,_0x416c11('0x1b53'))[_0x416c11('0xb11')](0x0,!![])[_0x416c11('0x26dd')]()),_0x122728[_0x416c11('0x1686')]=new Date(_0x1aaf93()()['endOf'](_0x416c11('0x55b'))[_0x416c11('0x1315')](0x1,'day')[_0x416c11('0xb11')](0x0,!![])[_0x416c11('0x26dd')]()),_0x122728['userProfileSection']=_0x26d66b&&_0x26d66b[_0x416c11('0x50d')]==0x1?_0x26d66b['rows'][0x0]:null,_0x122728[_0x416c11('0x1134')]=_0x4ea629[_0x416c11('0x142a')](_0x122728[_0x416c11('0x22df')]?_0x122728['userProfileSection']['crudPermissions']:null),_0x122728[_0x416c11('0x8a4')]=_0x2e3ca0()['keyBy']([{'option':_0x416c11('0x786'),'value':_0x416c11('0x2395')},{'option':_0x416c11('0x1526'),'value':_0x416c11('0xe45')},{'option':_0x416c11('0x13e'),'value':_0x416c11('0x246f')},{'option':'Low','value':_0x416c11('0x1597')},{'option':_0x416c11('0x31c'),'value':_0x416c11('0x1deb')}],function(_0x2843a8){const _0x3f6a4f=_0x416c11;return _0x2e3ca0()[_0x3f6a4f('0x1725')](_0x2843a8[_0x3f6a4f('0x1c6b')],new RegExp('\x27','g'),'');}),_0x122728[_0x416c11('0x1067')]={'fields':_0x416c11('0x2332'),'sort':_0x416c11('0xc36'),'limit':0xa,'page':0x1},_0x122728[_0x416c11('0x721')]={'fields':'id,uniqueid,calleridnum,statedesc,starttime,disposition','sort':'-id','limit':0xa,'page':0x1},_0x122728[_0x416c11('0x23cd')]={'fields':_0x416c11('0xbad'),'sort':_0x416c11('0x24aa'),'limit':0xa,'page':0x1},_0x122728[_0x416c11('0x107d')]={'fields':_0x416c11('0x8c1'),'sort':_0x416c11('0x231c'),'limit':0xa,'page':0x1},_0x122728[_0x416c11('0x517')]=_0x5e5fcb[_0x416c11('0x7f2')]['tab']||0x0,_0x122728[_0x416c11('0x1dd2')]=_0x45b440,_0x122728[_0x416c11('0x1f39')]=_0x1d2cb1,_0x122728[_0x416c11('0x1453')]=_0x14d23c,_0x122728[_0x416c11('0x206f')]=_0x10236a,_0x122728[_0x416c11('0x1f50')]=_0x2711cb,_0x122728[_0x416c11('0x241a')]=_0x560f8d,_0x122728[_0x416c11('0x1685')]=_0x412e76,_0x122728[_0x416c11('0x16b3')]=_0x3a9740,_0x122728[_0x416c11('0x21f7')]=_0x29fb13,_0x122728[_0x416c11('0x255c')]=_0x24d0fd,_0x122728[_0x416c11('0x20a4')]=_0x34ca06,_0x122728[_0x416c11('0x12ce')]=_0x2d0bac,_0x122728[_0x416c11('0x194f')]=_0x18adb7,_0x122728[_0x416c11('0x1bbe')]=_0x4924f6,_0x122728['createOrEditIvrCampaignHopper']=_0x4aa63a,_0x122728[_0x416c11('0x14d4')]=_0x5a7833;let _0x30e94a=!![],_0xa4a820=0x1;_0x4ca66c[_0x416c11('0x186d')](_0x416c11('0x1f2b'),function(_0x8f7fb8,_0x292e6d){const _0x4f2da3=_0x416c11;_0x30e94a?_0x5e37e4(function(){_0x30e94a=![];}):(!_0x292e6d&&(_0xa4a820=_0x122728['queryHopper']['page']),_0x8f7fb8!==_0x292e6d&&(_0x122728[_0x4f2da3('0x1067')][_0x4f2da3('0xdf8')]=0x1),!_0x8f7fb8&&(_0x122728[_0x4f2da3('0x1067')]['page']=_0xa4a820),_0x122728[_0x4f2da3('0x21f7')]());}),_0x4ca66c['$watch'](_0x416c11('0xe46'),function(_0x92803c,_0x2b8ae6){const _0x1631b2=_0x416c11;_0x30e94a?_0x5e37e4(function(){_0x30e94a=![];}):(!_0x2b8ae6&&(_0xa4a820=_0x122728[_0x1631b2('0x721')][_0x1631b2('0xdf8')]),_0x92803c!==_0x2b8ae6&&(_0x122728[_0x1631b2('0x721')][_0x1631b2('0xdf8')]=0x1),!_0x92803c&&(_0x122728[_0x1631b2('0x721')]['page']=_0xa4a820),_0x122728[_0x1631b2('0x255c')]());}),_0x4ca66c[_0x416c11('0x186d')](_0x416c11('0x19dc'),function(_0x4811b5,_0x964a3){const _0x4ada87=_0x416c11;_0x30e94a?_0x5e37e4(function(){_0x30e94a=![];}):(!_0x964a3&&(_0xa4a820=_0x122728[_0x4ada87('0x23cd')][_0x4ada87('0xdf8')]),_0x4811b5!==_0x964a3&&(_0x122728['queryHistory'][_0x4ada87('0xdf8')]=0x1),!_0x4811b5&&(_0x122728['queryHistory'][_0x4ada87('0xdf8')]=_0xa4a820),_0x122728[_0x4ada87('0x20a4')]());});function _0x3eed9b(_0x557de7){const _0x13600c=_0x416c11;switch(_0x557de7){case _0x13600c('0x24e'):return _0x13600c('0xb1e');case'mail':return'teal';case _0x13600c('0x1285'):return'orange';case _0x13600c('0x1261'):return _0x13600c('0xe71');case'fax':return _0x13600c('0x1a47');case _0x13600c('0x16e7'):return _0x13600c('0x522');default:return'blue-A700';}}function _0x5a7833(_0x161485){const _0x213a27=_0x416c11;let _0x520af5='';if(_0x161485[_0x213a27('0xe22')])_0x520af5='fax';else{if(_0x161485[_0x213a27('0x1061')])_0x520af5=_0x213a27('0x1261');else{if(_0x161485['SmsAccountId'])_0x520af5=_0x213a27('0x1285');else{if(_0x161485[_0x213a27('0x1cd')])_0x520af5=_0x213a27('0x129f');else{if(_0x161485[_0x213a27('0x15a5')])_0x520af5='chat';else _0x161485[_0x213a27('0x1297')]&&(_0x520af5='voice');}}}}return _0x3eed9b(_0x520af5);}function _0x5104ee(_0x446982){return function(_0xd7b2e6){_0x122728[_0x446982]=_0xd7b2e6||{'count':0x0,'rows':[]};};}function _0x45b440(){const _0x3cb796=_0x416c11;return!_0x4ea629['hasRole'](_0x3cb796('0x20c2'))&&(_0x1df509(),_0x27a4e1()),_0x399024[_0x3cb796('0xc96')][_0x3cb796('0x1e6e')]({'fields':_0x3cb796('0x226f'),'nolimit':!![]})[_0x3cb796('0xe53')][_0x3cb796('0x683')](function(_0x2bedab){const _0x1ca654=_0x3cb796;_0x122728[_0x1ca654('0x3bf')]=_0x2bedab||{'count':0x0,'rows':[]},_0x122728[_0x1ca654('0xd7d')]=_0x2e3ca0()['mapValues'](_0x2e3ca0()[_0x1ca654('0x24db')](_0x122728[_0x1ca654('0x3bf')][_0x1ca654('0xf5d')],'id'),_0x1ca654('0x11bc')),_0x122728[_0x1ca654('0x198f')]=_0x2e3ca0()['map'](_0x122728[_0x1ca654('0xd06')][_0x1ca654('0x198f')],'id');})[_0x3cb796('0x683')](_0x2c0d01(_0x174d6b));}function _0x1df509(){const _0x2053fa=_0x416c11,_0x10238b=_0x2e3ca0()['some'](_0x122728[_0x2053fa('0x1191')][_0x2053fa('0xf5d')],{'id':_0x122728[_0x2053fa('0xd06')]['CompanyId']});if(!_0x10238b)return _0x399024['cmCompany']['get']({'id':_0x122728[_0x2053fa('0xd06')][_0x2053fa('0x2883')],'fields':_0x2053fa('0xa10')})['$promise'][_0x2053fa('0x683')](function(_0x12a47e){const _0x33aae9=_0x2053fa,_0x1d11c0=_0x12a47e[_0x33aae9('0x24e1')]();_0x1d11c0[_0x33aae9('0x319')]=![],_0x122728[_0x33aae9('0x1191')]['rows'][_0x33aae9('0x1fd0')](_0x1d11c0);})[_0x2053fa('0x130a')](function(_0x4919e6){const _0x6f7756=_0x2053fa;_0x4c1913[_0x6f7756('0x52a')]({'title':_0x4919e6[_0x6f7756('0x13ee')]?'API:'+_0x4919e6['status']+_0x6f7756('0xbf6')+_0x4919e6[_0x6f7756('0x24a9')]:'GET_COMPANY','msg':_0x4919e6[_0x6f7756('0x5a5')]?JSON[_0x6f7756('0x258a')](_0x4919e6[_0x6f7756('0x5a5')]['message']):_0x4919e6[_0x6f7756('0x1ff0')]()});});}function _0x27a4e1(){const _0x8134df=_0x416c11,_0x405651=_0x2e3ca0()['map'](_0x122728['contact']['Tags'],function(_0x4417f6){return{'id':_0x4417f6['id'],'name':_0x4417f6['name']};});if(!_0x2e3ca0()['isEmpty'](_0x405651))for(let _0x49e1a8=0x0;_0x49e1a8<_0x405651[_0x8134df('0x1564')];_0x49e1a8++){!_0x2e3ca0()[_0x8134df('0x7a2')](_0x122728[_0x8134df('0x1ce6')][_0x8134df('0xf5d')],{'id':_0x405651['id']})&&(_0x405651[_0x49e1a8][_0x8134df('0x319')]=![],_0x122728[_0x8134df('0x1ce6')][_0x8134df('0xf5d')][_0x8134df('0x1fd0')](_0x405651[_0x49e1a8]));}}function _0x25076a(_0x4bd1c9){const _0x421620=_0x416c11;if(!_0x4bd1c9[_0x421620('0x43f')])return'('+_0x5121e0[_0x421620('0x2728')](_0x421620('0x591'))+')';const _0x9e3554=_0x2e3ca0()[_0x421620('0x1043')]([_0x4bd1c9[_0x421620('0x43f')],_0x4bd1c9[_0x421620('0x259d')],_0x4bd1c9[_0x421620('0x2481')]]);return'('+_0x9e3554['join'](_0x421620('0xbf6'))+')';}function _0x52ac4d(_0x34bd22){const _0x503672=_0x416c11;_0x34bd22&&_0x34bd22['count']&&_0x34bd22[_0x503672('0xf5d')][_0x503672('0x1564')]&&(_0x122728[_0x503672('0x18b')]=_0x2e3ca0()['concat'](_0x122728[_0x503672('0x18b')],_0x34bd22[_0x503672('0xf5d')]),_0x122728[_0x503672('0x18b')]['forEach'](function(_0x2ffb99){const _0x3f98f4=_0x503672;_0x2ffb99[_0x3f98f4('0x19ff')]=_0x25076a(_0x2ffb99);}));}function _0x2c0d01(_0x2e8982){const _0x2dac68=_0x416c11,_0x51396f=[_0x2dac68('0x129f'),_0x2dac68('0x24e'),'sms',_0x2dac68('0x1261'),_0x2dac68('0x23e9')];if(_0x2e8982&&_0x2e8982['id']){for(let _0x1397ff=0x0;_0x1397ff<_0x51396f[_0x2dac68('0x1564')];_0x1397ff++){_0x399024[_0x51396f[_0x1397ff]+'Interaction']['get']({'ContactId':_0x2e8982['id'],'includeAll':!![]})['$promise'][_0x2dac68('0x683')](_0x52ac4d);}_0x399024[_0x2dac68('0x337')][_0x2dac68('0x1e6e')]({'ContactId':_0x2e8982['id'],'includeAll':!![]})[_0x2dac68('0xe53')][_0x2dac68('0x683')](_0x52ac4d)[_0x2dac68('0x130a')](function(_0x2f268e){const _0x4672a8=_0x2dac68;console[_0x4672a8('0x52a')](_0x2f268e);});}}function _0x4924f6(_0x9abd01,_0x1ebc8){const _0x18040e=_0x416c11;_0x2575a3[_0x18040e('0x1d4')]({'controller':'CreateOrEditHopperVoiceQueueIdDialogController','controllerAs':'vm','templateUrl':_0x46751f,'parent':angular[_0x18040e('0x1fcc')](_0x412705[_0x18040e('0x18e5')]),'targetEvent':_0x9abd01,'clickOutsideToClose':!![],'locals':{'hopper':_0x1ebc8,'hoppers':_0x122728[_0x18040e('0x1c63')][_0x18040e('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x122728[_0x18040e('0x1134')]}});}function _0x4aa63a(_0x1906c9,_0x25e8ba){const _0x1b284a=_0x416c11;_0x2575a3['show']({'controller':'CreateOrEditHopperCampaignIdDialogController','controllerAs':'vm','templateUrl':_0x4eeff0,'parent':angular[_0x1b284a('0x1fcc')](_0x412705[_0x1b284a('0x18e5')]),'targetEvent':_0x1906c9,'clickOutsideToClose':!![],'locals':{'hopper':_0x25e8ba,'hoppers':_0x122728[_0x1b284a('0x1c63')]['rows'],'license':null,'setting':null,'crudPermissions':_0x122728[_0x1b284a('0x1134')]}});}function _0x18adb7(_0x248e8e,_0x4330ad){const _0x321ab7=_0x416c11,_0x3a4590=_0x2575a3[_0x321ab7('0x1c6f')]()[_0x321ab7('0xf28')](_0x321ab7('0x329'))[_0x321ab7('0x26e3')](_0x321ab7('0xed5')+(_0x248e8e[_0x321ab7('0xd31')]||_0x321ab7('0x1da2'))+_0x321ab7('0x20f1')+_0x321ab7('0x1ee7'))[_0x321ab7('0x1040')](_0x321ab7('0x18fa'))[_0x321ab7('0xe42')](_0x4330ad)['ok']('OK')['cancel'](_0x321ab7('0x16b8'));_0x2575a3[_0x321ab7('0x1d4')](_0x3a4590)[_0x321ab7('0x683')](function(){_0x702110(_0x248e8e);},function(){const _0x40e2fc=_0x321ab7;console[_0x40e2fc('0x1b2b')](_0x40e2fc('0x16b8'));});}function _0x702110(_0x29e03c){const _0xbcc0f6=_0x416c11;return _0x399024['cmHopper']['delete']({'id':_0x29e03c['id']})[_0xbcc0f6('0xe53')][_0xbcc0f6('0x683')](function(){const _0x493e3b=_0xbcc0f6;_0x2e3ca0()[_0x493e3b('0x3ec')](_0x122728[_0x493e3b('0x1c63')][_0x493e3b('0xf5d')],{'id':_0x29e03c['id']}),_0x122728[_0x493e3b('0x1c63')][_0x493e3b('0x50d')]--,!_0x122728[_0x493e3b('0x1c63')]['rows'][_0x493e3b('0x1564')]&&_0x122728['getHoppers'](),_0x4c1913[_0x493e3b('0x53')]({'title':'Hopper\x20deleted!','msg':_0x29e03c[_0x493e3b('0xd31')]?_0x29e03c[_0x493e3b('0xd31')]+_0x493e3b('0x194d'):''});})['catch'](function(_0x251497){const _0x57e747=_0xbcc0f6;_0x4c1913[_0x57e747('0x52a')]({'title':_0x251497[_0x57e747('0x13ee')]?_0x57e747('0x2168')+_0x251497[_0x57e747('0x13ee')]+_0x57e747('0xbf6')+_0x251497[_0x57e747('0x24a9')]:'SYSTEM:DELETEhopper','msg':_0x251497[_0x57e747('0x5a5')]?JSON['stringify'](_0x251497[_0x57e747('0x5a5')]):_0x251497['toString']()});});}function _0x29fb13(){const _0x2118a1=_0x416c11;_0x122728[_0x2118a1('0x1067')]['offset']=(_0x122728[_0x2118a1('0x1067')][_0x2118a1('0xdf8')]-0x1)*_0x122728[_0x2118a1('0x1067')][_0x2118a1('0x6f0')],_0x122728['queryHopper']['id']=_0x122728[_0x2118a1('0xd06')]['id'],_0x122728[_0x2118a1('0x1883')]=_0x399024[_0x2118a1('0x276e')][_0x2118a1('0x21f7')](_0x122728['queryHopper'],_0x5104ee('hoppers'))[_0x2118a1('0xe53')];}function _0x24d0fd(){const _0x4ecc91=_0x416c11;_0x122728[_0x4ecc91('0x721')]['offset']=(_0x122728[_0x4ecc91('0x721')]['page']-0x1)*_0x122728[_0x4ecc91('0x721')][_0x4ecc91('0x6f0')],_0x122728[_0x4ecc91('0x721')]['id']=_0x122728[_0x4ecc91('0xd06')]['id'],_0x122728['promise']=_0x399024[_0x4ecc91('0x276e')][_0x4ecc91('0x77b')](_0x122728[_0x4ecc91('0x721')],_0x5104ee(_0x4ecc91('0x157d')))[_0x4ecc91('0xe53')];}function _0x34ca06(){const _0x3d0cef=_0x416c11;_0x122728[_0x3d0cef('0x23cd')][_0x3d0cef('0x1cc8')]=(_0x122728['queryHistory']['page']-0x1)*_0x122728['queryHistory'][_0x3d0cef('0x6f0')],_0x122728[_0x3d0cef('0x23cd')]['id']=_0x122728[_0x3d0cef('0xd06')]['id'],_0x122728[_0x3d0cef('0x1883')]=_0x399024[_0x3d0cef('0x276e')][_0x3d0cef('0x816')](_0x122728['queryHistory'],_0x5104ee(_0x3d0cef('0x1f3f')))['$promise'];}function _0x2d0bac(){const _0x22bd86=_0x416c11;_0x122728[_0x22bd86('0x107d')][_0x22bd86('0x1cc8')]=(_0x122728['queryJscriptySession'][_0x22bd86('0xdf8')]-0x1)*_0x122728[_0x22bd86('0x107d')][_0x22bd86('0x6f0')],_0x122728[_0x22bd86('0x107d')]['id']=_0x122728[_0x22bd86('0xd06')]['id'],_0x122728[_0x22bd86('0x1883')]=_0x399024['cmContact'][_0x22bd86('0x12ce')](_0x122728['queryJscriptySession'],_0x5104ee(_0x22bd86('0x867')))[_0x22bd86('0xe53')];}function _0x560f8d(_0x33453a){const _0x4c349a=_0x416c11;if(_0x122728[_0x4c349a('0xd06')]['ListId']){const _0x1a30de=_0x2575a3[_0x4c349a('0x1c6f')]()[_0x4c349a('0xf28')]('You\x20are\x20selecting\x20the\x20list\x20number:\x20'+_0x122728[_0x4c349a('0xd06')][_0x4c349a('0x1e4f')])[_0x4c349a('0x1525')](_0x4c349a('0x1792')+_0x122728[_0x4c349a('0xd06')][_0x4c349a('0xeef')]||0x0||0x0)[_0x4c349a('0xe42')](_0x33453a)['ok']('Ok')['cancel'](_0x4c349a('0x253a'));return _0x2575a3[_0x4c349a('0x1d4')](_0x1a30de)[_0x4c349a('0x683')](_0x122728['onSelectListSuccess'])[_0x4c349a('0x130a')](function(){const _0x5cb9a8=_0x4c349a;_0x122728['contact'][_0x5cb9a8('0x1e4f')]=null;});}}function _0x412e76(){const _0x59bb5a=_0x416c11;return _0x399024['cmList'][_0x59bb5a('0xcb')]({'id':_0x122728[_0x59bb5a('0xd06')]['ListId']})[_0x59bb5a('0xe53')]['then'](function(_0x5ef457){const _0x44c6b6=_0x59bb5a;_0x122728[_0x44c6b6('0xc4d')]=_0x5ef457||{'rows':[],'count':0x0};})[_0x59bb5a('0x130a')](function(_0x13e70a){console['error'](_0x13e70a);});}function _0x79a842(){const _0x509404=_0x416c11;return _0x399024[_0x509404('0x22df')][_0x509404('0x1e6e')]({'userProfileId':_0x122728[_0x509404('0x11ed')][_0x509404('0x2f')],'sectionId':0x12e})[_0x509404('0xe53')]['then'](function(_0x5a9fb9){const _0x265d71=_0x509404,_0x592c66=_0x5a9fb9[_0x265d71('0xf5d')]?_0x5a9fb9[_0x265d71('0xf5d')][0x0]:null;return _0x4ea629['parseCrudPermissions'](_0x592c66?_0x592c66[_0x265d71('0x1134')]:null);})[_0x509404('0x130a')](function(_0x3db5ee){const _0x3fd900=_0x509404;_0x4c1913[_0x3fd900('0x52a')]({'title':_0x3db5ee[_0x3fd900('0x13ee')]?_0x3fd900('0x2168')+_0x3db5ee['status']+_0x3fd900('0xbf6')+_0x3db5ee[_0x3fd900('0x24a9')]:'API:GET_COMPANY_SECTION','msg':_0x3db5ee[_0x3fd900('0x5a5')]?JSON[_0x3fd900('0x258a')](_0x3db5ee[_0x3fd900('0x5a5')]):_0x3db5ee[_0x3fd900('0x1ff0')]()});});}function _0x2711cb(_0x18e7ee,_0x47c138){const _0x1d2025=_0x416c11,_0x23681e=_0x2e3ca0()['find'](_0x122728[_0x1d2025('0x1191')][_0x1d2025('0xf5d')],{'id':_0x47c138});_0x2575a3['show']({'controller':'CreateOrEditCompanyDialogController','controllerAs':'vm','templateUrl':_0x11956f,'parent':angular[_0x1d2025('0x1fcc')](_0x412705[_0x1d2025('0x18e5')]),'targetEvent':_0x18e7ee,'clickOutsideToClose':!![],'locals':{'companies':[],'license':null,'setting':null,'crudPermissions':_0x23681e[_0x1d2025('0x319')]===![]?{'readOnly':!![],'canEdit':![],'canDelete':![]}:_0x79a842()},'resolve':{'company':['apiResolver',function(_0x1d9e01){const _0x5d9496=_0x1d2025;return _0x1d9e01[_0x5d9496('0xed7')]('cmCompany@get',{'id':_0x47c138});}]}});}function _0x14d23c(_0xfc83dc){const _0x2c8bf0=_0x416c11;_0x2575a3[_0x2c8bf0('0x1d4')]({'controller':_0x2c8bf0('0x1757'),'controllerAs':'vm','templateUrl':_0x24dbc7,'parent':angular[_0x2c8bf0('0x1fcc')](_0x412705[_0x2c8bf0('0x18e5')]),'targetEvent':_0xfc83dc,'clickOutsideToClose':!![],'resolve':{'lists':[_0x2c8bf0('0x4b1'),_0x2c8bf0('0xba1'),function(_0x32af20,_0x591635){const _0x114efa=_0x2c8bf0;return _0x591635[_0x114efa('0xca1')](_0x114efa('0x20c2'))?_0x32af20[_0x114efa('0xed7')](_0x114efa('0xa7b'),{'fields':_0x114efa('0xa10')}):_0x32af20[_0x114efa('0xed7')](_0x114efa('0x191b'),{'id':_0x122728[_0x114efa('0x11ed')][_0x114efa('0x2f')],'section':_0x114efa('0x1114'),'fields':'id,name'});}]},'locals':{'contacts':_0x3ac35a[_0x2c8bf0('0xf5d')],'contact':_0x174d6b}});}function _0x10236a(){const _0x61f3e=_0x416c11;_0x399024[_0x61f3e('0x276e')][_0x61f3e('0x2480')]({'id':_0x122728[_0x61f3e('0xd06')]['id']},_0x122728[_0x61f3e('0xd06')])['$promise'][_0x61f3e('0x683')](function(){const _0x350b48=_0x61f3e;_0x4c1913[_0x350b48('0x53')]({'title':_0x350b48('0x46d'),'msg':_0x122728[_0x350b48('0xd06')][_0x350b48('0x60a')]?_0x122728[_0x350b48('0xd06')]['name']+_0x350b48('0x96c'):''});})['then'](function(){const _0x2b5f8d=_0x61f3e;return _0x399024[_0x2b5f8d('0x276e')]['setTags']({'id':_0x122728['contact']['id'],'ids':_0x122728['Tags']})[_0x2b5f8d('0xe53')];})['catch'](function(_0x70e953){const _0x123c47=_0x61f3e;_0x4c1913[_0x123c47('0x52a')]({'title':_0x70e953[_0x123c47('0x13ee')]?_0x123c47('0x2168')+_0x70e953[_0x123c47('0x13ee')]+_0x123c47('0xbf6')+_0x70e953[_0x123c47('0x24a9')]:'SYSTEM:UPDATEcontact','msg':_0x70e953['data']?JSON[_0x123c47('0x258a')](_0x70e953[_0x123c47('0x5a5')]):_0x70e953[_0x123c47('0x1ff0')]()});});}function _0x3a9740(_0x52d086){return _0x52d086===null?undefined:new Date(_0x52d086);}function _0x1d2cb1(){const _0x17e8fc=_0x416c11;_0x5e5fcb['go'](_0x17e8fc('0x1e45'),{},{'reload':!![],'notify':!![]});}}const _0x1a4f94=_0x346590;_0x5efd3f[_0x189033('0x14be')]=['$cookies',_0x189033('0x1e48'),'$interval','$q',_0x189033('0x2f9'),_0x189033('0xe01'),_0x189033('0x1191'),'toasty',_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x7a5'),_0x189033('0x21dd'),_0x189033('0x189a'),_0x189033('0xace')];function _0x5efd3f(_0x5d3f54,_0x322b6b,_0x4f6ce0,_0x405427,_0x56c0f9,_0x79d89c,_0x2d3866,_0x2d5eec,_0x2728f7,_0x2acca0,_0x59e737,_0x3c0129,_0x12457c,_0x47070d){const _0x235ebc=_0x189033,_0x4365d3=this;_0x4365d3['processing']=![],_0x4365d3[_0x235ebc('0x36b')]=!![],_0x4365d3['license']=_0x47070d,_0x4365d3[_0x235ebc('0x58d')]=0x0,_0x4365d3[_0x235ebc('0x7c9')]={'finish':![],'rows':0x0,'affectedRows':0x0,'failedRows':0x0,'duplicatedRows':0x0,'errors':[]},_0x4365d3['contactFields']=[{'key':_0x235ebc('0xeef'),'required':!![]},{'key':_0x235ebc('0x510'),'required':![]},{'key':_0x235ebc('0xd31'),'required':!![]},{'key':_0x235ebc('0x200f'),'required':![]},{'key':_0x235ebc('0x1c92'),'required':![]},{'key':_0x235ebc('0x26a7'),'required':![]},{'key':_0x235ebc('0x1ef9'),'required':![]},{'key':'city','required':![]},{'key':_0x235ebc('0x13c4'),'required':![]},{'key':_0x235ebc('0x9c4'),'required':![]},{'key':_0x235ebc('0x23e9'),'required':![]}],_0x4365d3[_0x235ebc('0x58a')]=[{'key':_0x235ebc('0x10c5'),'required':![]},{'key':_0x235ebc('0x1ff9'),'required':![]},{'key':_0x235ebc('0xe1e'),'required':![]}],_0x4365d3[_0x235ebc('0x233d')]={},_0x4365d3[_0x235ebc('0x1104')]=[],_0x4365d3['lists']=_0x79d89c||{'rows':[],'count':0x0},_0x4365d3['companies']=_0x2d3866||{'rows':[],'count':0x0},_0x4365d3['customFields']={'rows':[],'count':0x0},_0x4365d3[_0x235ebc('0x189a')]=_0x12457c||[],_0x4365d3[_0x235ebc('0xf82')]=_0x339cf9,_0x4365d3['onChangeList']=_0x5f351f,_0x4365d3[_0x235ebc('0x13a3')]=_0x3d4014,_0x4365d3[_0x235ebc('0xff2')]=_0x38cca9,_0x4365d3['getArrayErrors']=_0x52c8c4,_0x4365d3[_0x235ebc('0x10bc')]=_0x17fbd6;const _0xccf5b2=_0x1aaf93()()['unix']();_0x2acca0['on'](_0x235ebc('0x2689')+_0xccf5b2,_0x3f74e4);function _0x5f351f(){const _0x163ed6=_0x235ebc;return _0x2728f7[_0x163ed6('0x259b')][_0x163ed6('0xcb')]({'id':_0x4365d3['ListId']})[_0x163ed6('0xe53')][_0x163ed6('0x683')](function(_0x2cf65f){const _0x490ee7=_0x163ed6;_0x4365d3[_0x490ee7('0xc4d')]=_0x2cf65f;})[_0x163ed6('0x130a')](function(_0x373b8d){const _0x2279de=_0x163ed6;console[_0x2279de('0x52a')](_0x373b8d);});}function _0x3d4014(){const _0x361734=_0x235ebc;_0x4365d3['processing']=_0x1aaf93()(),_0x2728f7[_0x361734('0x276e')]['import']({'id':_0x3c0129['filename'],'binding':_0x4365d3[_0x361734('0x233d')],'ListId':_0x4365d3[_0x361734('0x1e4f')],'CompanyId':_0x4365d3['CompanyId'],'duplicates':_0x4365d3[_0x361734('0x285d')],'socket_timestamp':_0xccf5b2})[_0x361734('0xe53')]['then'](function(_0x9563c1){const _0x28cfe8=_0x361734;_0x4365d3[_0x28cfe8('0x36b')]=![],_0x9563c1&&_0x9563c1[_0x28cfe8('0x58d')]&&(_0x4365d3[_0x28cfe8('0x58d')]=_0x9563c1[_0x28cfe8('0x58d')]);})[_0x361734('0x130a')](function(){const _0xfa12d4=_0x361734;_0x4365d3[_0xfa12d4('0x131a')]=![],_0x2d5eec[_0xfa12d4('0x52a')]({'title':_0xfa12d4('0xccf'),'msg':_0xfa12d4('0xdad')});});}function _0x3f74e4(_0x1fc367){_0x56c0f9(function(){const _0x222351=a0_0x4e0a;_0x4365d3['result']['rows']=_0x1fc367['rows'];if(_0x1fc367[_0x222351('0x17f')])for(let _0x49d74f=0x0;_0x49d74f<_0x1fc367['errors'][_0x222351('0x1564')];_0x49d74f++){_0x4365d3[_0x222351('0x7c9')][_0x222351('0x17f')][_0x222351('0x1fd0')](_0x1fc367['errors'][_0x49d74f]);}if(_0x1fc367['finish']){_0x4365d3[_0x222351('0x7c9')][_0x222351('0x1ab4')]=!![],_0x4365d3['result'][_0x222351('0x1dbf')]=_0x1fc367[_0x222351('0x1dbf')],_0x4365d3['result']['failedRows']=_0x4365d3[_0x222351('0x7c9')][_0x222351('0x17f')][_0x222351('0x1564')];const _0x556c99=_0x4365d3[_0x222351('0x7c9')]['rows']-_0x4365d3[_0x222351('0x7c9')][_0x222351('0x1dbf')]-_0x4365d3[_0x222351('0x7c9')]['errors'][_0x222351('0x1564')];_0x556c99&&_0x556c99>0x0&&(_0x4365d3[_0x222351('0x285d')][_0x222351('0x1564')]?_0x4365d3['result']['duplicatedRows']=_0x556c99:_0x4365d3[_0x222351('0x7c9')][_0x222351('0x8f3')]+=_0x556c99),_0x4365d3[_0x222351('0x7c9')]['elapsed']=_0x1aaf93()()[_0x222351('0x2357')](_0x4365d3['processing'],_0x222351('0x1b53'));}});}function _0x38cca9(){const _0x5a9fe8=_0x235ebc,_0x2da5dd=_0x12457c;return _0x2da5dd[_0x5a9fe8('0x1fd0')](_0x5a9fe8('0x1ade')),_0x2da5dd;}function _0x52c8c4(){const _0x2a9760=_0x235ebc,_0xde3896=[];for(let _0x75019c=0x0;_0x75019c<_0x4365d3[_0x2a9760('0x7c9')]['errors'][_0x2a9760('0x1564')];_0x75019c+=0x1){const _0x2d4a86=_0x4365d3[_0x2a9760('0x7c9')][_0x2a9760('0x17f')][_0x75019c][_0x2a9760('0x1df7')];_0x2d4a86['contact_import_error']=_0x4365d3[_0x2a9760('0x7c9')][_0x2a9760('0x17f')][_0x75019c][_0x2a9760('0x8c2')],_0xde3896[_0x2a9760('0x1fd0')](_0x2d4a86);}return _0xde3896;}function _0x17fbd6(){const _0xc9eb92=_0x235ebc;_0x4365d3[_0xc9eb92('0x36b')]=!![];if(_0x4365d3[_0xc9eb92('0x58d')])return _0x2728f7[_0xc9eb92('0x24f2')][_0xc9eb92('0x1c5c')]({'pid':_0x4365d3[_0xc9eb92('0x58d')]})[_0xc9eb92('0xe53')][_0xc9eb92('0x683')](function(){const _0x255924=_0xc9eb92;_0x2d5eec[_0x255924('0x53')]({'title':'CSV\x20import\x20process\x20stopped!','msg':_0x255924('0x41')});})[_0xc9eb92('0x130a')](function(){const _0x294c2c=_0xc9eb92;_0x2d5eec[_0x294c2c('0x52a')]({'title':_0x294c2c('0x29c'),'msg':_0x294c2c('0x722')});});}_0x59e737[_0x235ebc('0x26a2')]('$destroy',function(){const _0xacfa2f=_0x235ebc;_0x2acca0[_0xacfa2f('0x1b9e')](_0xacfa2f('0x2689')+_0xccf5b2);});function _0x339cf9(){const _0xc1727c=_0x235ebc;_0x2acca0[_0xc1727c('0x1b9e')](_0xc1727c('0x2689')+_0xccf5b2),_0x322b6b[_0xc1727c('0x1715')]();}}const _0xdb335c=_0x5efd3f;_0x3cd852['$inject']=[_0x189033('0x1e48'),_0x189033('0x7a5'),'toasty','contact','contacts',_0x189033('0xe01'),_0x189033('0x56b')];function _0x3cd852(_0x4288da,_0x2c41fa,_0x22c17d,_0xa9ce23,_0x1161f6,_0x157395,_0x113b5d){const _0x194197=_0x189033,_0x2cdb09=this;_0x2cdb09['errors']=[],_0x2cdb09[_0x194197('0xf28')]=_0x194197('0x14d9'),_0x2cdb09[_0x194197('0xd06')]=angular['copy'](_0xa9ce23),_0x2cdb09['lists']=_0x157395||[],_0x2cdb09[_0x194197('0xfd2')]=function(){const _0x4f4019=_0x194197;_0x2cdb09[_0x4f4019('0xa95')]?_0x113b5d[_0x4f4019('0x276e')][_0x4f4019('0x1e6e')]({'fields':_0x4f4019('0x26a0'),'filter':_0x2cdb09[_0x4f4019('0xa95')],'ListId':_0xa9ce23[_0x4f4019('0x1e4f')]})[_0x4f4019('0xe53')][_0x4f4019('0x683')](function(_0x2fbba9){const _0x1eef7e=_0x4f4019;_0x2cdb09[_0x1eef7e('0x6d5')]=_0x2fbba9['rows'];})[_0x4f4019('0x130a')](function(_0x3827e6){console['error'](_0x3827e6);}):_0x2cdb09['contacts']=[];},_0x2cdb09['showConfirm']=_0x5ef3ba,_0x2cdb09[_0x194197('0xf82')]=_0x2161de;function _0x5ef3ba(_0x492cc2,_0x80a443,_0x5987a8){const _0x1808ed=_0x194197,_0x397ebf=_0x4288da[_0x1808ed('0x1c6f')]({'skipHide':!![]})[_0x1808ed('0xf28')](_0x1808ed('0x652'))[_0x1808ed('0x1525')](_0x1808ed('0x2471')+_0x5987a8['id']+_0x1808ed('0x381')+_0x80a443['id']+'.')[_0x1808ed('0xe42')](_0x492cc2)['ok']('Ok')[_0x1808ed('0x19fb')](_0x1808ed('0x253a'));_0x4288da['show'](_0x397ebf)[_0x1808ed('0x683')](function(){const _0x135b76=_0x1808ed;return _0x113b5d['cmContact'][_0x135b76('0xf22')]({'to':_0x5987a8['id'],'from':_0x80a443['id']})[_0x135b76('0xe53')];})[_0x1808ed('0x683')](function(_0x1cb812){const _0x546591=_0x1808ed;_0x4288da[_0x546591('0x1715')]({'new':_0x1cb812,'to':_0x5987a8,'from':_0x80a443}),_0x2e3ca0()[_0x546591('0x3ec')](_0x1161f6,{'id':_0x5987a8['id']}),_0x2e3ca0()[_0x546591('0x3ec')](_0x1161f6,{'id':_0x80a443['id']}),_0x1161f6[_0x546591('0x1167')](_0x1cb812);})[_0x1808ed('0x683')](function(){const _0x262016=_0x1808ed;_0x22c17d['success']({'title':_0x262016('0x1f76')});})['catch'](function(_0x3c3c3a){const _0x3f318f=_0x1808ed;_0x3c3c3a&&_0x3c3c3a[_0x3f318f('0x13ee')]&&_0x22c17d[_0x3f318f('0x52a')]({'title':_0x3c3c3a['status']?_0x3f318f('0x2168')+_0x3c3c3a['status']+'\x20-\x20'+_0x3c3c3a[_0x3f318f('0x24a9')]:'SYSTEM:MERGE_CONTACT','msg':_0x3c3c3a[_0x3f318f('0x5a5')]?JSON['stringify'](_0x3c3c3a[_0x3f318f('0x5a5')]):_0x3c3c3a[_0x3f318f('0x1ff0')]()});});}function _0x2161de(){const _0x436387=_0x194197;_0x4288da[_0x436387('0x1715')]();}}const _0x9714c=_0x3cd852,_0x3f6128=_0x180212['p']+_0x189033('0xdcc'),_0x21f941=_0x180212['p']+_0x189033('0x2784');_0x308662[_0x189033('0x14be')]=['$stateProvider'];function _0x308662(_0x59dc7c){const _0xa1437c=_0x189033;_0x59dc7c[_0xa1437c('0x2598')]('app.contactmanager.contacts',{'url':'/contacts?ListId&CompanyId','views':{'content@app':{'templateUrl':_0x3f6128,'controller':'ContactsController\x20as\x20vm'}},'resolve':{'contacts':[_0xa1437c('0x4b1'),_0xa1437c('0xba1'),_0xa1437c('0x8ea'),function(_0x5a2027,_0x36df91,_0x774868){const _0x53b4fe=_0xa1437c;return _0x36df91['hasRole'](_0x53b4fe('0x20c2'))?_0x5a2027['resolve']('cmContact@get',_0x2e3ca0()[_0x53b4fe('0xf22')]({'includeAll':!![],'sort':_0x53b4fe('0xc36'),'limit':0xa,'offset':0x0},_0x774868)):_0x5a2027[_0x53b4fe('0xed7')]('userProfile@getResources',_0x2e3ca0()[_0x53b4fe('0xf22')]({'id':_0x36df91[_0x53b4fe('0x20b2')]()[_0x53b4fe('0x2f')],'section':_0x53b4fe('0xdb2'),'includeAll':!![],'sort':_0x53b4fe('0xc36'),'limit':0xa,'offset':0x0},_0x774868));}],'lists':[_0xa1437c('0x4b1'),_0xa1437c('0xba1'),function(_0x279ef9,_0x51467f){const _0x342bd7=_0xa1437c;return _0x51467f[_0x342bd7('0xca1')](_0x342bd7('0x20c2'))?_0x279ef9[_0x342bd7('0xed7')](_0x342bd7('0xa7b'),{'fields':_0x342bd7('0xa10'),'sort':_0x342bd7('0x60a'),'nolimit':!![]}):_0x279ef9[_0x342bd7('0xed7')](_0x342bd7('0x191b'),{'id':_0x51467f[_0x342bd7('0x20b2')]()[_0x342bd7('0x2f')],'section':_0x342bd7('0x1114'),'fields':_0x342bd7('0xa10'),'sort':'-updatedAt','nolimit':!![]});}],'listsMap':[_0xa1437c('0xe01'),function(_0x1fe389){const _0x2b99ab=_0xa1437c,_0x3faee5={};for(let _0x2868d4=0x0;_0x2868d4<_0x1fe389[_0x2b99ab('0xf5d')][_0x2b99ab('0x1564')];_0x2868d4++){_0x3faee5[_0x1fe389[_0x2b99ab('0xf5d')][_0x2868d4]['id']]=_0x1fe389[_0x2b99ab('0xf5d')][_0x2868d4]['name'];}return _0x3faee5;}],'companies':[_0xa1437c('0x4b1'),'Auth',function(_0x4253e8,_0x5968ab){const _0x5296e1=_0xa1437c;return _0x5968ab['hasRole'](_0x5296e1('0x20c2'))?_0x4253e8[_0x5296e1('0xed7')]('cmCompany@get',{'fields':_0x5296e1('0xa10'),'sort':'name','nolimit':!![]}):_0x4253e8['resolve'](_0x5296e1('0x191b'),{'id':_0x5968ab[_0x5296e1('0x20b2')]()['userProfileId'],'section':_0x5296e1('0x2229'),'fields':'id,name','sort':_0x5296e1('0x60a'),'nolimit':!![]});}],'companiesMap':[_0xa1437c('0x1191'),function(_0x345f12){const _0x2eb74c=_0xa1437c,_0xced1a6={};for(let _0x345a7b=0x0;_0x345a7b<_0x345f12[_0x2eb74c('0xf5d')][_0x2eb74c('0x1564')];_0x345a7b++){_0xced1a6[_0x345f12[_0x2eb74c('0xf5d')][_0x345a7b]['id']]=_0x345f12[_0x2eb74c('0xf5d')][_0x345a7b][_0x2eb74c('0x60a')];}return _0xced1a6;}],'tags':['apiResolver',_0xa1437c('0xba1'),function(_0x32f7b6,_0x521859){const _0x1ca7c4=_0xa1437c;return _0x521859[_0x1ca7c4('0xca1')](_0x1ca7c4('0x20c2'))?_0x32f7b6[_0x1ca7c4('0xed7')](_0x1ca7c4('0xb55'),{'fields':_0x1ca7c4('0xa10'),'sort':_0x1ca7c4('0x60a'),'nolimit':!![]}):_0x32f7b6[_0x1ca7c4('0xed7')]('userProfile@getResources',{'id':_0x521859['getCurrentUser']()['userProfileId'],'section':'Tags','fields':_0x1ca7c4('0xa10'),'sort':_0x1ca7c4('0x60a'),'nolimit':!![]});}],'userProfile':['apiResolver',_0xa1437c('0xba1'),function(_0x478ad0,_0x3bafe5){const _0x153ed9=_0xa1437c;return _0x478ad0[_0x153ed9('0xed7')](_0x153ed9('0x1464'),{'fields':'id,name,crudPermissions','id':_0x3bafe5[_0x153ed9('0x20b2')]()[_0x153ed9('0x2f')]});}],'userProfileSection':[_0xa1437c('0x4b1'),_0xa1437c('0xba1'),function(_0x4e4a3b,_0x5c9d26){const _0xc406eb=_0xa1437c;return _0x4e4a3b['resolve'](_0xc406eb('0x360'),{'fields':_0xc406eb('0x1f47'),'userProfileId':_0x5c9d26[_0xc406eb('0x20b2')]()[_0xc406eb('0x2f')],'sectionId':0x12f});}]},'authenticate':!![],'permissionId':0x12f,'bodyClass':_0xa1437c('0x22a2')})['state'](_0xa1437c('0x25d3'),{'url':_0xa1437c('0x1560'),'params':{'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x21f941,'controller':_0xa1437c('0x1b4')}},'resolve':{'contact':['apiResolver',_0xa1437c('0x8ea'),function(_0x44d647,_0x2d90b3){const _0x57cf8e=_0xa1437c;return _0x44d647['resolve'](_0x57cf8e('0x23ec'),{'id':_0x2d90b3['id']})['then'](function(_0x43c361){const _0x2a9d4d=_0x57cf8e;return _0x43c361[_0x2a9d4d('0x26a7')]&&(_0x43c361[_0x2a9d4d('0x26a7')]=new Date(_0x43c361[_0x2a9d4d('0x26a7')])),_0x43c361;})['catch'](function(_0x36134a){const _0x34a1b2=_0x57cf8e;console[_0x34a1b2('0x52a')](_0x36134a);});}],'hoppers':[_0xa1437c('0x4b1'),_0xa1437c('0x8ea'),function(_0x3446aa,_0x2b7d11){const _0xd85bd9=_0xa1437c;return _0x3446aa['resolve']('cmContact@getHoppers',{'id':_0x2b7d11['id'],'fields':_0xd85bd9('0x2332'),'sort':_0xd85bd9('0xc36'),'limit':0xa,'offset':0x0});}],'finals':['apiResolver','$stateParams',function(_0x17f8e1,_0x245c83){const _0x4f0de7=_0xa1437c;return _0x17f8e1['resolve'](_0x4f0de7('0x1510'),{'id':_0x245c83['id'],'fields':_0x4f0de7('0x1cfb'),'sort':_0x4f0de7('0xc36'),'limit':0xa,'offset':0x0});}],'histories':[_0xa1437c('0x4b1'),_0xa1437c('0x8ea'),function(_0xe40bb0,_0x32750f){const _0x26fe84=_0xa1437c;return _0xe40bb0['resolve'](_0x26fe84('0x1368'),{'id':_0x32750f['id'],'fields':_0x26fe84('0xbad'),'sort':_0x26fe84('0xc36'),'limit':0xa,'offset':0x0});}],'jscriptySessions':[_0xa1437c('0x4b1'),'$stateParams',function(_0x20c80e,_0x37731b){const _0x51c3d5=_0xa1437c;return _0x20c80e[_0x51c3d5('0xed7')]('cmContact@getJscriptySessions',{'id':_0x37731b['id'],'fields':_0x51c3d5('0x8c1'),'sort':_0x51c3d5('0x231c'),'limit':0xa,'offset':0x0});}],'companies':[_0xa1437c('0x4b1'),_0xa1437c('0xba1'),function(_0x508f3a,_0x48d28d){const _0x1c25ea=_0xa1437c;return _0x48d28d[_0x1c25ea('0xca1')]('admin')?_0x508f3a['resolve'](_0x1c25ea('0xdd0')):_0x508f3a[_0x1c25ea('0xed7')](_0x1c25ea('0x191b'),{'id':_0x48d28d[_0x1c25ea('0x20b2')]()[_0x1c25ea('0x2f')],'section':_0x1c25ea('0x2229')});}],'lists':['apiResolver',_0xa1437c('0xba1'),function(_0x24a6cb,_0x28249d){const _0x33f748=_0xa1437c;return _0x28249d['hasRole'](_0x33f748('0x20c2'))?_0x24a6cb[_0x33f748('0xed7')](_0x33f748('0xa7b'),{'fields':_0x33f748('0xa10'),'sort':_0x33f748('0xc36'),'nolimit':!![]}):_0x24a6cb[_0x33f748('0xed7')](_0x33f748('0x191b'),{'id':_0x28249d[_0x33f748('0x20b2')]()['userProfileId'],'section':'Lists','fields':_0x33f748('0xa10'),'sort':'-updatedAt','nolimit':!![]});}],'customFields':['apiResolver','contact',function(_0x112a57,_0x1a9fc7){const _0x1b4dfb=_0xa1437c;return _0x1a9fc7[_0x1b4dfb('0x1e4f')]?_0x112a57[_0x1b4dfb('0xed7')](_0x1b4dfb('0x1b97'),{'id':_0x1a9fc7[_0x1b4dfb('0x1e4f')]}):null;}],'tags':[_0xa1437c('0x4b1'),'Auth',function(_0x199a24,_0x13cacc){const _0x162fbc=_0xa1437c;return _0x13cacc['hasRole'](_0x162fbc('0x20c2'))?_0x199a24[_0x162fbc('0xed7')](_0x162fbc('0xb55')):_0x199a24['resolve'](_0x162fbc('0x191b'),{'id':_0x13cacc[_0x162fbc('0x20b2')]()[_0x162fbc('0x2f')],'section':_0x162fbc('0x198f')});}],'userProfileSection':[_0xa1437c('0x4b1'),_0xa1437c('0xba1'),function(_0x168cf8,_0xe89809){const _0x14450b=_0xa1437c;return _0x168cf8[_0x14450b('0xed7')](_0x14450b('0x360'),{'fields':_0x14450b('0x1f47'),'userProfileId':_0xe89809[_0x14450b('0x20b2')]()[_0x14450b('0x2f')],'sectionId':0x12f});}]},'authenticate':!![],'permissionId':0x12f,'bodyClass':_0xa1437c('0x22a2')});}angular[_0x189033('0x1e26')](_0x189033('0x1e45'),[])['config'](_0x308662)[_0x189033('0x1da3')]('ContactsController',_0x27017a)[_0x189033('0x1da3')](_0x189033('0x679'),_0x5a2d21)['controller'](_0x189033('0x1757'),_0x294143)[_0x189033('0x1da3')](_0x189033('0x7f9'),_0x3ec880)['controller'](_0x189033('0x1493'),_0x1a4f94)['controller']('ImportContactsDialogController',_0xdb335c)[_0x189033('0x1da3')](_0x189033('0x264'),_0x9714c);const _0x4ae775=_0x180212['p']+_0x189033('0x1c3e');_0x10ca71['$inject']=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x1191'),_0x189033('0x2a'),_0x189033('0x22df'),'api',_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x10ca71(_0x4305a6,_0x4da822,_0x3aefb0,_0x1f5fe0,_0x338063,_0x112687,_0x785722,_0x5f1f2a,_0x2e806b,_0x5ee48e,_0x596407,_0x5ed6a7,_0x5aa495,_0x1519d9,_0x332998,_0x23cb19,_0x2adcbb){const _0x46c44c=_0x189033,_0x4af9c1=this;_0x4af9c1[_0x46c44c('0xace')]=_0x23cb19,_0x4af9c1[_0x46c44c('0x260a')]=_0x2adcbb,_0x4af9c1[_0x46c44c('0x11ed')]=_0x332998['getCurrentUser'](),_0x4af9c1[_0x46c44c('0x1191')]=_0x2e806b||{'count':0x0,'rows':[]},_0x4af9c1[_0x46c44c('0x2a')]=_0x5ee48e,_0x4af9c1[_0x46c44c('0x22df')]=_0x596407&&_0x596407[_0x46c44c('0x50d')]==0x1?_0x596407[_0x46c44c('0xf5d')][0x0]:null,_0x4af9c1[_0x46c44c('0x1134')]=_0x332998[_0x46c44c('0x142a')](_0x4af9c1[_0x46c44c('0x22df')]?_0x4af9c1['userProfileSection'][_0x46c44c('0x1134')]:null),_0x4af9c1[_0x46c44c('0x5c4')]=_0x46c44c('0x1191'),_0x4af9c1[_0x46c44c('0x247')]='',_0x4af9c1[_0x46c44c('0x1ce2')]=null,_0x4af9c1[_0x46c44c('0x272')]=[],_0x4af9c1[_0x46c44c('0x23a2')]={'fields':_0x46c44c('0x596'),'sort':_0x46c44c('0xc36'),'limit':0xa,'page':0x1},_0x4af9c1['editstate']=_0x1a8e0f,_0x4af9c1[_0x46c44c('0xcf6')]=_0x43200a,_0x4af9c1[_0x46c44c('0x194f')]=_0xe0c523,_0x4af9c1[_0x46c44c('0x53')]=_0x57c3c7,_0x4af9c1[_0x46c44c('0x26a9')]=_0x4c7fa9,_0x4af9c1[_0x46c44c('0x9a5')]=_0x5cf44d,_0x4af9c1[_0x46c44c('0xf36')]=_0xe39ea4,_0x4af9c1[_0x46c44c('0x1973')]=_0x2ad7df,_0x4af9c1[_0x46c44c('0x1ffd')]=_0x55bba2,_0x4af9c1[_0x46c44c('0x2328')]=_0x5d7cde,_0x4af9c1['selectAllCompanies']=_0x2e70af;function _0x1a8e0f(_0x3426a2){_0x3aefb0['go']('app.contactmanager.companies.edit',{'id':_0x3426a2['id'],'company':_0x3426a2,'crudPermissions':_0x4af9c1['crudPermissions']});}function _0x43200a(_0x59a326){const _0x16b5cb=_0x46c44c;if(_0x332998['hasRole'](_0x16b5cb('0x20c2')))_0x3aefb0['go']('app.contactmanager.contacts',{'CompanyId':_0x59a326['id']});else return _0x5ed6a7[_0x16b5cb('0x22df')][_0x16b5cb('0x1e6e')]({'userProfileId':_0x332998[_0x16b5cb('0x20b2')]()[_0x16b5cb('0x2f')],'sectionId':0x12f})[_0x16b5cb('0xe53')][_0x16b5cb('0x683')](function(_0x258371){const _0x2aca3d=_0x16b5cb,_0x46cde3=_0x258371&&_0x258371[_0x2aca3d('0xf5d')]?_0x258371['rows'][0x0]:null;_0x46cde3&&_0x46cde3[_0x2aca3d('0x1333')]?_0x3aefb0['go']('app.contactmanager.contacts',{'CompanyId':_0x59a326['id']}):_0x1519d9['info']({'title':_0x5f1f2a[_0x2aca3d('0x2728')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x5f1f2a[_0x2aca3d('0x2728')](_0x2aca3d('0xdba'))});})[_0x16b5cb('0x130a')](function(_0x2b1549){const _0x23a0c9=_0x16b5cb;_0x1519d9['error']({'title':_0x2b1549[_0x23a0c9('0x13ee')]?_0x23a0c9('0x2168')+_0x2b1549[_0x23a0c9('0x13ee')]+_0x23a0c9('0xbf6')+_0x2b1549[_0x23a0c9('0x24a9')]:_0x23a0c9('0xf2a'),'msg':_0x2b1549['status']?JSON[_0x23a0c9('0x258a')](_0x2b1549[_0x23a0c9('0x5a5')]):_0x2b1549[_0x23a0c9('0x1ff0')]()});});}function _0xe0c523(_0x212555,_0x4ec710){const _0x529f0a=_0x46c44c,_0x17f06e=_0x338063[_0x529f0a('0x1c6f')]()[_0x529f0a('0xf28')](_0x529f0a('0x1b01')+_0x2e3ca0()[_0x529f0a('0x1e03')](_0x529f0a('0x18da'))+'?')[_0x529f0a('0x26e3')](_0x529f0a('0xed5')+(_0x212555[_0x529f0a('0x60a')]||'company')+_0x529f0a('0x20f1')+_0x529f0a('0x1ee7'))['ariaLabel'](_0x529f0a('0x1b4b'))[_0x529f0a('0xe42')](_0x4ec710)['ok']('OK')[_0x529f0a('0x19fb')](_0x529f0a('0x16b8'));_0x338063[_0x529f0a('0x1d4')](_0x17f06e)[_0x529f0a('0x683')](function(){_0xe39ea4(_0x212555);},function(){const _0xf2b8f1=_0x529f0a;console[_0xf2b8f1('0x1b2b')](_0xf2b8f1('0x16b8'));});}let _0x3883b6=!![],_0x5babb4=0x1;_0x4305a6['$watch'](_0x46c44c('0x1e1d'),function(_0x481382,_0x31fc01){const _0x44490a=_0x46c44c;_0x3883b6?_0x785722(function(){_0x3883b6=![];}):(!_0x31fc01&&(_0x5babb4=_0x4af9c1[_0x44490a('0x23a2')]['page']),_0x481382!==_0x31fc01&&(_0x4af9c1[_0x44490a('0x23a2')][_0x44490a('0xdf8')]=0x1),!_0x481382&&(_0x4af9c1[_0x44490a('0x23a2')][_0x44490a('0xdf8')]=_0x5babb4),_0x4af9c1[_0x44490a('0x26a9')]());});function _0x57c3c7(_0x494b0b){const _0x4846d2=_0x46c44c;_0x4af9c1[_0x4846d2('0x1191')]=_0x494b0b||{'count':0x0,'rows':[]};}function _0x4c7fa9(){const _0x283ac5=_0x46c44c;_0x4af9c1['query'][_0x283ac5('0x1cc8')]=(_0x4af9c1[_0x283ac5('0x23a2')]['page']-0x1)*_0x4af9c1['query'][_0x283ac5('0x6f0')],_0x332998['hasRole']('admin')?_0x4af9c1[_0x283ac5('0x1883')]=_0x5ed6a7[_0x283ac5('0x27db')][_0x283ac5('0x1e6e')](_0x4af9c1[_0x283ac5('0x23a2')],_0x57c3c7)[_0x283ac5('0xe53')]:(_0x4af9c1[_0x283ac5('0x23a2')]['id']=_0x4af9c1[_0x283ac5('0x2a')]['id'],_0x4af9c1['query']['section']='Companies',_0x4af9c1[_0x283ac5('0x1883')]=_0x5ed6a7['userProfile'][_0x283ac5('0x241d')](_0x4af9c1[_0x283ac5('0x23a2')],_0x57c3c7)[_0x283ac5('0xe53')]);}function _0x5cf44d(_0x2023d7,_0x371f5d){const _0x439bc8=_0x46c44c;_0x338063[_0x439bc8('0x1d4')]({'controller':_0x439bc8('0x2031'),'controllerAs':'vm','templateUrl':_0x4ae775,'parent':angular['element'](_0x112687[_0x439bc8('0x18e5')]),'targetEvent':_0x2023d7,'clickOutsideToClose':!![],'locals':{'company':_0x371f5d,'companies':_0x4af9c1[_0x439bc8('0x1191')][_0x439bc8('0xf5d')],'license':_0x4af9c1[_0x439bc8('0xace')],'setting':_0x4af9c1[_0x439bc8('0x260a')],'crudPermissions':_0x4af9c1[_0x439bc8('0x1134')]}});}function _0xe39ea4(_0x4a49be){const _0x4088e3=_0x46c44c;_0x5ed6a7['cmCompany']['delete']({'id':_0x4a49be['id']})[_0x4088e3('0xe53')]['then'](function(){const _0xcf11bc=_0x4088e3;_0x2e3ca0()[_0xcf11bc('0x3ec')](_0x4af9c1[_0xcf11bc('0x1191')][_0xcf11bc('0xf5d')],{'id':_0x4a49be['id']}),_0x4af9c1[_0xcf11bc('0x1191')][_0xcf11bc('0x50d')]-=0x1,!_0x4af9c1['companies'][_0xcf11bc('0xf5d')]['length']&&_0x4af9c1[_0xcf11bc('0x26a9')](),_0x1519d9[_0xcf11bc('0x53')]({'title':_0x2e3ca0()[_0xcf11bc('0x1e03')](_0xcf11bc('0x1c9'))+_0xcf11bc('0xbfc'),'msg':_0x4a49be[_0xcf11bc('0x60a')]?_0x4a49be['name']+_0xcf11bc('0x194d'):''});})[_0x4088e3('0x130a')](function(_0x190509){const _0x5bae42=_0x4088e3;if(_0x190509['data']&&_0x190509[_0x5bae42('0x5a5')][_0x5bae42('0x17f')]&&_0x190509['data'][_0x5bae42('0x17f')]['length']){_0x4af9c1[_0x5bae42('0x17f')]=_0x190509['data'][_0x5bae42('0x17f')]||[{'message':_0x190509[_0x5bae42('0x1ff0')](),'type':_0x5bae42('0x438')}];for(let _0x35bb78=0x0;_0x35bb78<_0x190509[_0x5bae42('0x5a5')][_0x5bae42('0x17f')]['length'];_0x35bb78++){_0x1519d9[_0x5bae42('0x52a')]({'title':_0x190509[_0x5bae42('0x5a5')][_0x5bae42('0x17f')][_0x35bb78]['type'],'msg':_0x190509['data'][_0x5bae42('0x17f')][_0x35bb78]['message']});}}else _0x1519d9[_0x5bae42('0x52a')]({'title':_0x190509[_0x5bae42('0x13ee')]?_0x5bae42('0x2168')+_0x190509[_0x5bae42('0x13ee')]+_0x5bae42('0xbf6')+_0x190509[_0x5bae42('0x24a9')]:_0x5bae42('0x438'),'msg':_0x190509[_0x5bae42('0x5a5')]?JSON[_0x5bae42('0x258a')](_0x190509[_0x5bae42('0x5a5')][_0x5bae42('0x8c2')]):_0x190509['message']||_0x190509[_0x5bae42('0x1ff0')]()});});}function _0x2ad7df(){const _0xba41ba=_0x46c44c,_0x4e5015=angular['copy'](_0x4af9c1[_0xba41ba('0x272')]);return _0x4af9c1[_0xba41ba('0x272')]=[],_0x4e5015;}function _0x55bba2(_0x2e8c5f){const _0x321db1=_0x46c44c,_0x323363=_0x338063['confirm']()[_0x321db1('0xf28')](_0x321db1('0x1a8'))[_0x321db1('0x26e3')](_0x321db1('0xed5')+_0x4af9c1[_0x321db1('0x272')][_0x321db1('0x1564')]+_0x321db1('0x93c')+_0x321db1('0x1ee7'))[_0x321db1('0x1040')]('delete\x20Companys')[_0x321db1('0xe42')](_0x2e8c5f)['ok']('OK')[_0x321db1('0x19fb')](_0x321db1('0x16b8'));_0x338063['show'](_0x323363)[_0x321db1('0x683')](function(){const _0x216398=_0x321db1;_0x4af9c1[_0x216398('0x272')]['forEach'](function(_0x559cd4){_0xe39ea4(_0x559cd4);}),_0x4af9c1['selectedCompanies']=[];});}function _0x5d7cde(){const _0x15cce5=_0x46c44c;_0x4af9c1[_0x15cce5('0x272')]=[];}function _0x2e70af(){const _0x52d5d8=_0x46c44c;_0x4af9c1['selectedCompanies']=_0x4af9c1['companies'][_0x52d5d8('0xf5d')];}}const _0x472d25=_0x10ca71;_0x3d4c42[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1191'),_0x189033('0x18da'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x3d4c42(_0x57e5be,_0x147554,_0x27f259,_0x44a774,_0x56b7f2,_0x55a22a,_0x56dd5a,_0x47791e,_0x3d3b90,_0x44ba11,_0x340e16,_0x380f75,_0x3e74da,_0x1fbbf3){const _0x5db9e0=_0x189033,_0x460641=this;_0x460641[_0x5db9e0('0x11ed')]=_0x340e16[_0x5db9e0('0x20b2')](),_0x460641['errors']=[],_0x460641[_0x5db9e0('0x260a')]=_0x3e74da,_0x460641['license']=_0x380f75,_0x460641[_0x5db9e0('0x1134')]=_0x1fbbf3,_0x460641[_0x5db9e0('0x258d')]={},_0x460641[_0x5db9e0('0x19b2')]=_0x460641[_0x5db9e0('0x260a')]&&_0x460641[_0x5db9e0('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x460641[_0x5db9e0('0xf28')]=_0x5db9e0('0x2b6'),_0x460641[_0x5db9e0('0x18da')]=angular[_0x5db9e0('0x1a86')](_0x3d3b90),_0x460641['companies']=_0x47791e,_0x460641[_0x5db9e0('0x1a2f')]=![];!_0x460641[_0x5db9e0('0x18da')]&&(_0x460641[_0x5db9e0('0x18da')]={},_0x460641['title']=_0x5db9e0('0x16e0'),_0x460641[_0x5db9e0('0x1a2f')]=!![]);_0x460641[_0x5db9e0('0xcda')]=_0x38aac8,_0x460641[_0x5db9e0('0x2798')]=_0x4c292c,_0x460641[_0x5db9e0('0xf36')]=_0x148e2e,_0x460641[_0x5db9e0('0x16b3')]=_0x4d2e17,_0x460641[_0x5db9e0('0xf82')]=_0x3b40ce;function _0x38aac8(){const _0x1139f2=_0x5db9e0;_0x460641[_0x1139f2('0x17f')]=[],_0x44ba11[_0x1139f2('0x27db')][_0x1139f2('0xb0a')](_0x460641[_0x1139f2('0x18da')])[_0x1139f2('0xe53')][_0x1139f2('0x683')](function(_0x27a8ea){const _0x13b38f=_0x1139f2;_0x460641[_0x13b38f('0x1191')][_0x13b38f('0x1167')](_0x27a8ea[_0x13b38f('0x24e1')]()),_0x56dd5a[_0x13b38f('0x53')]({'title':_0x13b38f('0x232e'),'msg':_0x460641[_0x13b38f('0x18da')][_0x13b38f('0x60a')]?_0x460641[_0x13b38f('0x18da')][_0x13b38f('0x60a')]+_0x13b38f('0x14b5'):''}),_0x3b40ce(_0x27a8ea);})[_0x1139f2('0x130a')](function(_0x40459e){const _0x5b10e3=_0x1139f2;if(_0x40459e['data']&&_0x40459e[_0x5b10e3('0x5a5')]['errors']&&_0x40459e[_0x5b10e3('0x5a5')][_0x5b10e3('0x17f')]['length']){_0x460641[_0x5b10e3('0x17f')]=_0x40459e[_0x5b10e3('0x5a5')][_0x5b10e3('0x17f')]||[{'message':_0x40459e[_0x5b10e3('0x1ff0')](),'type':_0x5b10e3('0x201c')}];for(let _0x57e34b=0x0;_0x57e34b<_0x40459e['data'][_0x5b10e3('0x17f')][_0x5b10e3('0x1564')];_0x57e34b+=0x1){_0x56dd5a[_0x5b10e3('0x52a')]({'title':_0x40459e[_0x5b10e3('0x5a5')]['errors'][_0x57e34b][_0x5b10e3('0xcf0')],'msg':_0x40459e[_0x5b10e3('0x5a5')][_0x5b10e3('0x17f')][_0x57e34b][_0x5b10e3('0x8c2')]});}}else _0x56dd5a[_0x5b10e3('0x52a')]({'title':_0x40459e[_0x5b10e3('0x13ee')]?_0x5b10e3('0x2168')+_0x40459e[_0x5b10e3('0x13ee')]+'\x20-\x20'+_0x40459e[_0x5b10e3('0x24a9')]:_0x5b10e3('0x201c'),'msg':_0x40459e['data']?JSON['stringify'](_0x40459e[_0x5b10e3('0x5a5')][_0x5b10e3('0x8c2')]):_0x40459e['toString']()});});}function _0x4c292c(){const _0x5c8300=_0x5db9e0;_0x460641[_0x5c8300('0x17f')]=[],_0x44ba11[_0x5c8300('0x27db')][_0x5c8300('0x2480')]({'id':_0x460641[_0x5c8300('0x18da')]['id']},_0x460641[_0x5c8300('0x18da')])['$promise']['then'](function(_0x293fb6){const _0x270af9=_0x5c8300,_0x378baf=_0x2e3ca0()['find'](_0x460641[_0x270af9('0x1191')],{'id':_0x293fb6['id']});_0x378baf&&_0x2e3ca0()[_0x270af9('0xf22')](_0x378baf,_0x2e3ca0()[_0x270af9('0x24d0')](_0x293fb6[_0x270af9('0x24e1')](),_0x2e3ca0()['keys'](_0x378baf))),_0x56dd5a[_0x270af9('0x53')]({'title':_0x270af9('0x283c'),'msg':_0x460641[_0x270af9('0x18da')][_0x270af9('0x60a')]?_0x460641[_0x270af9('0x18da')][_0x270af9('0x60a')]+_0x270af9('0xf59'):''}),_0x3b40ce(_0x293fb6);})['catch'](function(_0x462e1f){const _0x382239=_0x5c8300;if(_0x462e1f[_0x382239('0x5a5')]&&_0x462e1f['data']['errors']&&_0x462e1f[_0x382239('0x5a5')][_0x382239('0x17f')][_0x382239('0x1564')]){_0x460641['errors']=_0x462e1f[_0x382239('0x5a5')]['errors']||[{'message':_0x462e1f[_0x382239('0x1ff0')](),'type':'api.cmCompany.update'}];for(let _0xe36bfe=0x0;_0xe36bfe<_0x462e1f[_0x382239('0x5a5')]['errors'][_0x382239('0x1564')];_0xe36bfe++){_0x56dd5a[_0x382239('0x52a')]({'title':_0x462e1f[_0x382239('0x5a5')]['errors'][_0xe36bfe]['type'],'msg':_0x462e1f[_0x382239('0x5a5')]['errors'][_0xe36bfe][_0x382239('0x8c2')]});}}else _0x56dd5a['error']({'title':_0x462e1f[_0x382239('0x13ee')]?_0x382239('0x2168')+_0x462e1f[_0x382239('0x13ee')]+_0x382239('0xbf6')+_0x462e1f[_0x382239('0x24a9')]:_0x382239('0x1937'),'msg':_0x462e1f['data']?JSON[_0x382239('0x258a')](_0x462e1f['data'][_0x382239('0x8c2')]):_0x462e1f[_0x382239('0x1ff0')]()});});}function _0x148e2e(_0x31f017){const _0x15fa79=_0x5db9e0;_0x460641[_0x15fa79('0x17f')]=[];const _0x5e6cce=_0x44a774[_0x15fa79('0x1c6f')]()[_0x15fa79('0xf28')]('Are\x20you\x20sure?')['content'](_0x15fa79('0x1f55'))[_0x15fa79('0x1040')](_0x15fa79('0x4bc'))['ok']('Delete')[_0x15fa79('0x19fb')](_0x15fa79('0x253a'))['targetEvent'](_0x31f017);_0x44a774[_0x15fa79('0x1d4')](_0x5e6cce)['then'](function(){const _0x59be5b=_0x15fa79;_0x44ba11['cmCompany']['delete']({'id':_0x460641[_0x59be5b('0x18da')]['id']})['$promise'][_0x59be5b('0x683')](function(){const _0x577119=_0x59be5b;_0x2e3ca0()[_0x577119('0x3ec')](_0x460641[_0x577119('0x1191')],{'id':_0x460641[_0x577119('0x18da')]['id']}),_0x56dd5a[_0x577119('0x53')]({'title':'Company\x20properly\x20deleted!','msg':(_0x460641[_0x577119('0x18da')][_0x577119('0x60a')]||_0x577119('0x18da'))+_0x577119('0x194d')}),_0x3b40ce(_0x460641[_0x577119('0x18da')]);})[_0x59be5b('0x130a')](function(_0x356f20){const _0x527e5d=_0x59be5b;if(_0x356f20[_0x527e5d('0x5a5')]&&_0x356f20['data'][_0x527e5d('0x17f')]&&_0x356f20['data']['errors']['length']){_0x460641['errors']=_0x356f20[_0x527e5d('0x5a5')][_0x527e5d('0x17f')]||[{'message':_0x356f20[_0x527e5d('0x1ff0')](),'type':_0x527e5d('0x2702')}];for(let _0x29d3be=0x0;_0x29d3be<_0x356f20[_0x527e5d('0x5a5')][_0x527e5d('0x17f')][_0x527e5d('0x1564')];_0x29d3be++){_0x56dd5a['error']({'title':_0x356f20[_0x527e5d('0x5a5')][_0x527e5d('0x17f')][_0x29d3be][_0x527e5d('0xcf0')],'msg':_0x356f20[_0x527e5d('0x5a5')]['errors'][_0x29d3be][_0x527e5d('0x8c2')]});}}else _0x56dd5a['error']({'title':_0x356f20[_0x527e5d('0x13ee')]?'API:'+_0x356f20['status']+'\x20-\x20'+_0x356f20[_0x527e5d('0x24a9')]:_0x527e5d('0x2702'),'msg':_0x356f20[_0x527e5d('0x5a5')]?JSON[_0x527e5d('0x258a')](_0x356f20[_0x527e5d('0x5a5')]['message']):_0x356f20[_0x527e5d('0x8c2')]||_0x356f20[_0x527e5d('0x1ff0')]()});});},function(){});}function _0x4d2e17(_0x454dc3){return _0x454dc3===null?undefined:new Date(_0x454dc3);}function _0x3b40ce(_0x4cfb20){const _0x297216=_0x5db9e0;_0x44a774[_0x297216('0x1715')](_0x4cfb20);}}const _0x426211=_0x3d4c42;_0x32b27d[_0x189033('0x14be')]=['$state','$location',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),'license',_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),'company',_0x189033('0x22df')];function _0x32b27d(_0x3d9c86,_0x325f41,_0x5d7acc,_0x5d471a,_0x2a015a,_0x1a8e8f,_0x6dab93,_0x34a33d,_0x301c85,_0x585b19,_0x5f3a9a,_0x3e1de2){const _0x2ad07b=_0x189033,_0x3dd858=this;_0x3dd858[_0x2ad07b('0x11ed')]=_0x585b19[_0x2ad07b('0x20b2')](),_0x3dd858[_0x2ad07b('0xace')]=_0x1a8e8f,_0x3dd858[_0x2ad07b('0x260a')]=_0x6dab93,_0x3dd858[_0x2ad07b('0x19b2')]=_0x3dd858[_0x2ad07b('0x260a')][_0x2ad07b('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3dd858['location']=_0x325f41['protocol']()+_0x2ad07b('0x20de')+_0x325f41[_0x2ad07b('0x19ac')](),_0x3dd858[_0x2ad07b('0x18da')]=_0x5f3a9a||_0x3d9c86['params'][_0x2ad07b('0x18da')]||{},_0x3dd858['userProfileSection']=_0x3e1de2&&_0x3e1de2['count']==0x1?_0x3e1de2[_0x2ad07b('0xf5d')][0x0]:null,_0x3dd858[_0x2ad07b('0x1134')]=_0x585b19[_0x2ad07b('0x142a')](_0x3dd858[_0x2ad07b('0x22df')]?_0x3dd858[_0x2ad07b('0x22df')][_0x2ad07b('0x1134')]:null),_0x3dd858[_0x2ad07b('0x258d')]={},_0x3dd858[_0x2ad07b('0x517')]=_0x3d9c86[_0x2ad07b('0x7f2')][_0x2ad07b('0x1904')]||0x0,_0x3dd858[_0x2ad07b('0x1a9f')]=_0xe9799b,_0x3dd858[_0x2ad07b('0x2430')]=_0x301c85[_0x2ad07b('0x2289')],_0x3dd858[_0x2ad07b('0x148f')]=_0x421968,_0x3dd858[_0x2ad07b('0x2798')]=_0x22edd9;function _0xe9799b(_0x2e144e){const _0x5c9466=_0x2ad07b;if(_0x585b19[_0x5c9466('0xca1')](_0x5c9466('0x20c2')))_0x3d9c86['go'](_0x5c9466('0x1e45'),{'CompanyId':_0x2e144e['id']});else return _0x34a33d['userProfileSection'][_0x5c9466('0x1e6e')]({'userProfileId':_0x585b19[_0x5c9466('0x20b2')]()[_0x5c9466('0x2f')],'sectionId':0x12f})[_0x5c9466('0xe53')][_0x5c9466('0x683')](function(_0x20cd5f){const _0x2625ee=_0x5c9466,_0x5ccb8d=_0x20cd5f&&_0x20cd5f[_0x2625ee('0xf5d')]?_0x20cd5f[_0x2625ee('0xf5d')][0x0]:null;_0x5ccb8d&&_0x5ccb8d[_0x2625ee('0x1333')]?_0x3d9c86['go'](_0x2625ee('0x1e45'),{'CompanyId':_0x2e144e['id']}):_0x301c85['info']({'title':_0x2a015a[_0x2625ee('0x2728')](_0x2625ee('0x213e')),'msg':_0x2a015a[_0x2625ee('0x2728')](_0x2625ee('0xdba'))});})[_0x5c9466('0x130a')](function(_0x238105){const _0x2214b8=_0x5c9466;_0x301c85[_0x2214b8('0x52a')]({'title':_0x238105['status']?_0x2214b8('0x2168')+_0x238105[_0x2214b8('0x13ee')]+'\x20-\x20'+_0x238105[_0x2214b8('0x24a9')]:_0x2214b8('0xf2a'),'msg':_0x238105[_0x2214b8('0x13ee')]?JSON[_0x2214b8('0x258a')](_0x238105['data']):_0x238105[_0x2214b8('0x1ff0')]()});});}function _0x421968(){const _0x446d56=_0x2ad07b;_0x3d9c86['go']('app.contactmanager.companies',{},{'reload':_0x446d56('0x863')});}function _0x22edd9(){const _0x5ec634=_0x2ad07b;_0x34a33d[_0x5ec634('0x27db')][_0x5ec634('0x2480')]({'id':_0x3dd858['company']['id']},_0x3dd858[_0x5ec634('0x18da')])['$promise']['then'](function(){const _0x272c53=_0x5ec634;_0x301c85[_0x272c53('0x53')]({'title':_0x272c53('0x15a7'),'msg':_0x3dd858[_0x272c53('0x18da')][_0x272c53('0x60a')]?_0x3dd858[_0x272c53('0x18da')][_0x272c53('0x60a')]+_0x272c53('0x96c'):''});})['catch'](function(_0x16161e){const _0x5a86d7=_0x5ec634;_0x301c85[_0x5a86d7('0x52a')]({'title':_0x16161e['status']?'API:'+_0x16161e['status']+_0x5a86d7('0xbf6')+_0x16161e['statusText']:'SYSTEM:GETcmCompany','msg':_0x16161e[_0x5a86d7('0x5a5')]?JSON[_0x5a86d7('0x258a')](_0x16161e['data']):_0x16161e[_0x5a86d7('0x1ff0')]()});});}}const _0x4b52c9=_0x32b27d;_0x391053['$inject']=['$scope','$state',_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty',_0x189033('0xc99'),'globalCustomField',_0x189033('0x56b'),'Auth','license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x391053(_0xa5c9df,_0x2c6eb6,_0xfc6b1,_0x3ab072,_0x59de37,_0xc754b,_0x47b56c,_0x425c2f,_0x3cfd7d,_0x4335b8,_0x58164a,_0x295c0d,_0x1bbebe,_0x39a22d){const _0x591721=_0x189033,_0x57dd48=this;_0x57dd48[_0x591721('0x11ed')]=_0x58164a[_0x591721('0x20b2')](),_0x57dd48['errors']=[],_0x57dd48[_0x591721('0x260a')]=_0x1bbebe,_0x57dd48[_0x591721('0xace')]=_0x295c0d,_0x57dd48[_0x591721('0x1134')]=_0x39a22d,_0x57dd48[_0x591721('0x258d')]={},_0x57dd48['passwordPattern']=_0x57dd48[_0x591721('0x260a')]&&_0x57dd48[_0x591721('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x57dd48['title']=_0x591721('0x5f7'),_0x57dd48[_0x591721('0xf4')]={'animation':0x320,'sort':!![],'onSort':function(){const _0x437d70=_0x591721;_0xa5c9df[_0x437d70('0x15e8')]['$pristine']=![];}},_0x57dd48[_0x591721('0x1e07')]=_0x3cfd7d,_0x57dd48[_0x591721('0xc99')]=_0x425c2f,_0x57dd48[_0x591721('0xfe7')]=![];!_0x57dd48[_0x591721('0x1e07')]&&(_0x57dd48[_0x591721('0x1e07')]={'type':_0x591721('0x1bcd'),'actionType':_0x591721('0xcf2')},_0x57dd48[_0x591721('0xf28')]=_0x591721('0x14ad'),_0x57dd48[_0x591721('0xfe7')]=!![]);_0xa5c9df['$watch'](_0x591721('0x1ae0'),function(_0x54b705,_0x23c6f6){const _0x458eab=_0x591721;if(_0x54b705!==_0x23c6f6)switch(_0x54b705){case _0x458eab('0x1bcd'):_0x57dd48['globalCustomField'][_0x458eab('0x17a0')]='';break;case _0x458eab('0xb31'):_0x57dd48['globalCustomField'][_0x458eab('0x17a0')]=[];break;default:}}),_0x57dd48['addNewGlobalCustomField']=_0x3a0e3e,_0x57dd48[_0x591721('0x20b0')]=_0x36564c,_0x57dd48[_0x591721('0x27bd')]=_0x476cc5,_0x57dd48[_0x591721('0x16b3')]=_0x2b04bb,_0x57dd48[_0x591721('0x84e')]=_0x4a3a49,_0x57dd48['removeItem']=_0x5748b7,_0x57dd48[_0x591721('0x21b9')]=_0x5a6ef4,_0x57dd48[_0x591721('0xf82')]=_0x5105ca;function _0x4a3a49(_0x127b6d){const _0x4facee=_0x591721;_0x127b6d[_0x4facee('0x1fd0')]({'value':'New\x20Item'}),_0xa5c9df['globalCustomFieldForm'][_0x4facee('0xb0')]=![];}function _0x5748b7(_0x3ee8e4,_0x59bd96){const _0x58b381=_0x591721;_0x3ee8e4[_0x58b381('0x2040')](_0x59bd96,0x1),_0xa5c9df['globalCustomFieldForm'][_0x58b381('0xb0')]=![];}function _0x5a6ef4(_0xad1ff7){const _0x36f6c3=_0x591721,_0x203ee9=_0xad1ff7[_0x36f6c3('0x1564')];for(let _0x123d61=0x0;_0x123d61<_0x203ee9;_0x123d61++){_0xad1ff7[_0x36f6c3('0x2040')](0x0,0x1);}_0xa5c9df[_0x36f6c3('0x15e8')][_0x36f6c3('0xb0')]=![];}function _0x3a0e3e(){const _0xe9c1ec=_0x591721;_0x57dd48['errors']=[],_0x4335b8[_0xe9c1ec('0xf57')][_0xe9c1ec('0xb0a')](_0x57dd48[_0xe9c1ec('0x1e07')])[_0xe9c1ec('0xe53')][_0xe9c1ec('0x683')](function(_0x41cb62){const _0x14b982=_0xe9c1ec;_0x57dd48[_0x14b982('0xc99')]['unshift'](_0x41cb62['toJSON']()),_0x47b56c[_0x14b982('0x53')]({'title':'GlobalCustomField\x20properly\x20created','msg':_0x57dd48[_0x14b982('0x1e07')]['name']?_0x57dd48[_0x14b982('0x1e07')]['name']+_0x14b982('0x14b5'):''}),_0x5105ca(_0x41cb62);})[_0xe9c1ec('0x130a')](function(_0x573a1a){const _0x2b9a88=_0xe9c1ec;if(_0x573a1a['data']&&_0x573a1a[_0x2b9a88('0x5a5')][_0x2b9a88('0x17f')]&&_0x573a1a[_0x2b9a88('0x5a5')][_0x2b9a88('0x17f')][_0x2b9a88('0x1564')]){_0x57dd48[_0x2b9a88('0x17f')]=_0x573a1a[_0x2b9a88('0x5a5')][_0x2b9a88('0x17f')]||[{'message':_0x573a1a[_0x2b9a88('0x1ff0')](),'type':_0x2b9a88('0xf32')}];for(let _0x4dedc6=0x0;_0x4dedc6<_0x573a1a['data'][_0x2b9a88('0x17f')][_0x2b9a88('0x1564')];_0x4dedc6+=0x1){_0x47b56c[_0x2b9a88('0x52a')]({'title':_0x573a1a[_0x2b9a88('0x5a5')][_0x2b9a88('0x17f')][_0x4dedc6]['type'],'msg':_0x573a1a[_0x2b9a88('0x5a5')]['errors'][_0x4dedc6]['message']});}}else _0x47b56c[_0x2b9a88('0x52a')]({'title':_0x573a1a[_0x2b9a88('0x13ee')]?_0x2b9a88('0x2168')+_0x573a1a['status']+'\x20-\x20'+_0x573a1a['statusText']:'api.cmCustomField.save','msg':_0x573a1a[_0x2b9a88('0x5a5')]?JSON[_0x2b9a88('0x258a')](_0x573a1a[_0x2b9a88('0x5a5')]['message']):_0x573a1a[_0x2b9a88('0x1ff0')]()});});}function _0x36564c(){const _0x54e325=_0x591721;_0x57dd48[_0x54e325('0x17f')]=[],_0x4335b8[_0x54e325('0xf57')][_0x54e325('0x2480')]({'id':_0x57dd48[_0x54e325('0x1e07')]['id']},_0x57dd48[_0x54e325('0x1e07')])[_0x54e325('0xe53')][_0x54e325('0x683')](function(_0x25ef2d){const _0x4cb553=_0x54e325,_0x1e4ef7=_0x2e3ca0()[_0x4cb553('0x1c07')](_0x57dd48['globalCustomFields'],{'id':_0x25ef2d['id']});_0x1e4ef7&&_0x2e3ca0()[_0x4cb553('0xf22')](_0x1e4ef7,_0x2e3ca0()['pick'](_0x25ef2d['toJSON'](),_0x2e3ca0()['keys'](_0x1e4ef7))),_0x47b56c[_0x4cb553('0x53')]({'title':_0x4cb553('0x352'),'msg':_0x57dd48[_0x4cb553('0x1e07')]['name']?_0x57dd48[_0x4cb553('0x1e07')][_0x4cb553('0x60a')]+_0x4cb553('0xf59'):''}),_0x5105ca(_0x25ef2d);})[_0x54e325('0x130a')](function(_0x383edf){const _0x54b301=_0x54e325;if(_0x383edf[_0x54b301('0x5a5')]&&_0x383edf['data'][_0x54b301('0x17f')]&&_0x383edf[_0x54b301('0x5a5')][_0x54b301('0x17f')][_0x54b301('0x1564')]){_0x57dd48[_0x54b301('0x17f')]=_0x383edf['data'][_0x54b301('0x17f')]||[{'message':_0x383edf[_0x54b301('0x1ff0')](),'type':_0x54b301('0x21bd')}];for(let _0xcbe504=0x0;_0xcbe504<_0x383edf[_0x54b301('0x5a5')]['errors'][_0x54b301('0x1564')];_0xcbe504++){_0x47b56c[_0x54b301('0x52a')]({'title':_0x383edf[_0x54b301('0x5a5')][_0x54b301('0x17f')][_0xcbe504]['type'],'msg':_0x383edf['data'][_0x54b301('0x17f')][_0xcbe504][_0x54b301('0x8c2')]});}}else _0x47b56c[_0x54b301('0x52a')]({'title':_0x383edf['status']?_0x54b301('0x2168')+_0x383edf['status']+_0x54b301('0xbf6')+_0x383edf[_0x54b301('0x24a9')]:'api.cmCustomField.update','msg':_0x383edf['data']?JSON['stringify'](_0x383edf[_0x54b301('0x5a5')][_0x54b301('0x8c2')]):_0x383edf['toString']()});});}function _0x476cc5(_0x35eb7d){const _0x590269=_0x591721;_0x57dd48[_0x590269('0x17f')]=[];const _0x5f58a6=_0x3ab072[_0x590269('0x1c6f')]()[_0x590269('0xf28')](_0x590269('0x4d'))[_0x590269('0xa6a')](_0x590269('0x1d59'))[_0x590269('0x1040')](_0x590269('0x26c5'))['ok'](_0x590269('0x2307'))[_0x590269('0x19fb')](_0x590269('0x253a'))[_0x590269('0xe42')](_0x35eb7d);_0x3ab072[_0x590269('0x1d4')](_0x5f58a6)[_0x590269('0x683')](function(){const _0x43696b=_0x590269;_0x4335b8['cmCustomField']['delete']({'id':_0x57dd48[_0x43696b('0x1e07')]['id']})[_0x43696b('0xe53')][_0x43696b('0x683')](function(){const _0x42be82=_0x43696b;_0x2e3ca0()[_0x42be82('0x3ec')](_0x57dd48['globalCustomFields'],{'id':_0x57dd48[_0x42be82('0x1e07')]['id']}),_0x47b56c['success']({'title':'GlobalCustomField\x20properly\x20deleted!','msg':(_0x57dd48[_0x42be82('0x1e07')]['name']||'globalCustomField')+_0x42be82('0x194d')}),_0x5105ca(_0x57dd48[_0x42be82('0x1e07')]);})['catch'](function(_0x1c3437){const _0x49626f=_0x43696b;if(_0x1c3437[_0x49626f('0x5a5')]&&_0x1c3437['data'][_0x49626f('0x17f')]&&_0x1c3437['data']['errors'][_0x49626f('0x1564')]){_0x57dd48['errors']=_0x1c3437[_0x49626f('0x5a5')][_0x49626f('0x17f')]||[{'message':_0x1c3437[_0x49626f('0x1ff0')](),'type':_0x49626f('0x4af')}];for(let _0x58a5ca=0x0;_0x58a5ca<_0x1c3437[_0x49626f('0x5a5')]['errors'][_0x49626f('0x1564')];_0x58a5ca++){_0x47b56c['error']({'title':_0x1c3437[_0x49626f('0x5a5')][_0x49626f('0x17f')][_0x58a5ca]['type'],'msg':_0x1c3437['data'][_0x49626f('0x17f')][_0x58a5ca][_0x49626f('0x8c2')]});}}else _0x47b56c['error']({'title':_0x1c3437[_0x49626f('0x13ee')]?_0x49626f('0x2168')+_0x1c3437[_0x49626f('0x13ee')]+_0x49626f('0xbf6')+_0x1c3437[_0x49626f('0x24a9')]:_0x49626f('0x4af'),'msg':_0x1c3437[_0x49626f('0x5a5')]?JSON[_0x49626f('0x258a')](_0x1c3437[_0x49626f('0x5a5')][_0x49626f('0x8c2')]):_0x1c3437[_0x49626f('0x8c2')]||_0x1c3437[_0x49626f('0x1ff0')]()});});},function(){});}function _0x2b04bb(_0x20bfcc){return _0x20bfcc===null?undefined:new Date(_0x20bfcc);}function _0x5105ca(_0x591003){const _0x42f0c5=_0x591721;_0x3ab072[_0x42f0c5('0x1715')](_0x591003);}}const _0xfb6d5c=_0x391053,_0x4f3ed7=_0x180212['p']+_0x189033('0x166b');_0x24f71f[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),'$translate',_0x189033('0xc99'),_0x189033('0x2a'),_0x189033('0x22df'),'api','msUtils',_0x189033('0x1d70'),'Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x24f71f(_0x2d3e69,_0x4332c1,_0x3d7984,_0x2adccd,_0x58d551,_0x9ada59,_0x2e64ea,_0x19b6a8,_0x211e56,_0x376a30,_0x4fe9ce,_0xdf5db3,_0x47b440,_0x3b5522,_0x41438b,_0xcf280e,_0x30bcfe){const _0x325b69=_0x189033,_0x3a5379=this;_0x3a5379[_0x325b69('0xace')]=_0xcf280e,_0x3a5379['setting']=_0x30bcfe,_0x3a5379[_0x325b69('0x11ed')]=_0x41438b[_0x325b69('0x20b2')](),_0x3a5379[_0x325b69('0xc99')]=_0x211e56||{'count':0x0,'rows':[]},_0x3a5379[_0x325b69('0x2a')]=_0x376a30,_0x3a5379[_0x325b69('0x22df')]=_0x4fe9ce&&_0x4fe9ce[_0x325b69('0x50d')]==0x1?_0x4fe9ce[_0x325b69('0xf5d')][0x0]:null,_0x3a5379['crudPermissions']=_0x41438b['parseCrudPermissions'](_0x3a5379[_0x325b69('0x22df')]?_0x3a5379[_0x325b69('0x22df')][_0x325b69('0x1134')]:null),_0x3a5379[_0x325b69('0x5c4')]=_0x325b69('0xc99'),_0x3a5379[_0x325b69('0x247')]='',_0x3a5379[_0x325b69('0x1ce2')]=null,_0x3a5379[_0x325b69('0x21a8')]=[],_0x3a5379[_0x325b69('0x23a2')]={'fields':'createdAt,updatedAt,id,alias,type,values,required,clickToAction,actionType','sort':'-updatedAt','ListId':_0x325b69('0x13c'),'limit':0xa,'page':0x1},_0x3a5379['arraytype']=_0x2e3ca0()[_0x325b69('0x24db')]([{'option':_0x325b69('0x1d8c'),'value':_0x325b69('0x12de')},{'option':_0x325b69('0xaf7'),'value':_0x325b69('0x135e')},{'option':_0x325b69('0x140f'),'value':_0x325b69('0x25f6')},{'option':'Switch','value':_0x325b69('0x256b')},{'option':'Datetime','value':_0x325b69('0x110e')}],function(_0x2e4316){const _0x457b96=_0x325b69;return _0x2e3ca0()[_0x457b96('0x1725')](_0x2e4316[_0x457b96('0x1c6b')],new RegExp('\x27','g'),'');}),_0x3a5379[_0x325b69('0x27c6')]=_0x2e3ca0()[_0x325b69('0x24db')]([{'option':'Voice','value':'\x27voice\x27'}],function(_0x5187f3){const _0x3fd124=_0x325b69;return _0x2e3ca0()['replace'](_0x5187f3[_0x3fd124('0x1c6b')],new RegExp('\x27','g'),'');}),_0x3a5379[_0x325b69('0x1249')]=_0x4f76a7,_0x3a5379['deleteconfirm']=_0x1ff9a4,_0x3a5379[_0x325b69('0x53')]=_0x4737ff,_0x3a5379['getGlobalCustomFields']=_0x33d1e2,_0x3a5379['createOrEditGlobalCustomField']=_0x12aa44,_0x3a5379['deleteGlobalCustomField']=_0x5b1bb3,_0x3a5379[_0x325b69('0x1107')]=_0x50ec38,_0x3a5379[_0x325b69('0x26c0')]=_0x42b18e,_0x3a5379[_0x325b69('0x17f1')]=_0xfc5d52,_0x3a5379[_0x325b69('0x166e')]=_0x281df9;function _0x4f76a7(_0x56236e,_0x2e5f53){const _0x59f1ec=_0x325b69;_0x58d551['show']({'controller':_0x59f1ec('0xba0'),'controllerAs':'vm','templateUrl':_0x4f3ed7,'parent':angular[_0x59f1ec('0x1fcc')](_0x9ada59['body']),'targetEvent':_0x2e5f53,'clickOutsideToClose':!![],'locals':{'globalCustomField':_0x56236e,'globalCustomFields':_0x3a5379['globalCustomFields']['rows'],'license':_0x3a5379[_0x59f1ec('0xace')],'setting':null,'crudPermissions':_0x3a5379[_0x59f1ec('0x1134')]}});}function _0x1ff9a4(_0x53943e,_0x46cd07){const _0x41410d=_0x325b69,_0x184ef9=_0x58d551['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()['startCase']('globalCustomField')+'?')[_0x41410d('0x26e3')](''+(_0x53943e['name']||_0x41410d('0x1e07'))+_0x41410d('0x20f1')+_0x41410d('0x1ee7'))['ariaLabel'](_0x41410d('0x281c'))[_0x41410d('0xe42')](_0x46cd07)['ok']('OK')[_0x41410d('0x19fb')]('CANCEL');_0x58d551[_0x41410d('0x1d4')](_0x184ef9)[_0x41410d('0x683')](function(){_0x5b1bb3(_0x53943e);},function(){const _0x1172d2=_0x41410d;console['log'](_0x1172d2('0x16b8'));});}let _0x2bbdba=!![],_0x1b5b12=0x1;_0x2d3e69[_0x325b69('0x186d')](_0x325b69('0x1e1d'),function(_0x2fd792,_0x724c05){const _0x328312=_0x325b69;_0x2bbdba?_0x2e64ea(function(){_0x2bbdba=![];}):(!_0x724c05&&(_0x1b5b12=_0x3a5379[_0x328312('0x23a2')][_0x328312('0xdf8')]),_0x2fd792!==_0x724c05&&(_0x3a5379[_0x328312('0x23a2')][_0x328312('0xdf8')]=0x1),!_0x2fd792&&(_0x3a5379[_0x328312('0x23a2')][_0x328312('0xdf8')]=_0x1b5b12),_0x3a5379['getGlobalCustomFields']());});function _0x4737ff(_0x1fe97f){const _0x26b3a8=_0x325b69;_0x3a5379[_0x26b3a8('0xc99')]=_0x1fe97f||{'count':0x0,'rows':[]};}function _0x33d1e2(){const _0x3f88e8=_0x325b69;_0x3a5379[_0x3f88e8('0x23a2')][_0x3f88e8('0x1cc8')]=(_0x3a5379[_0x3f88e8('0x23a2')][_0x3f88e8('0xdf8')]-0x1)*_0x3a5379[_0x3f88e8('0x23a2')][_0x3f88e8('0x6f0')],_0x41438b['hasRole'](_0x3f88e8('0x20c2'))?_0x3a5379[_0x3f88e8('0x1883')]=_0xdf5db3[_0x3f88e8('0xf57')]['get'](_0x3a5379[_0x3f88e8('0x23a2')],_0x4737ff)['$promise']:(_0x3a5379['query']['id']=_0x3a5379['userProfile']['id'],_0x3a5379[_0x3f88e8('0x23a2')]['section']=_0x3f88e8('0x2ac'),_0x3a5379[_0x3f88e8('0x1883')]=_0xdf5db3['userProfile'][_0x3f88e8('0x241d')](_0x3a5379['query'],_0x4737ff)[_0x3f88e8('0xe53')]);}function _0x12aa44(_0x42d742,_0x18ff79){const _0x35b68f=_0x325b69;_0x58d551[_0x35b68f('0x1d4')]({'controller':_0x35b68f('0xba0'),'controllerAs':'vm','templateUrl':_0x4f3ed7,'parent':angular['element'](_0x9ada59[_0x35b68f('0x18e5')]),'targetEvent':_0x42d742,'clickOutsideToClose':!![],'locals':{'globalCustomField':_0x18ff79,'globalCustomFields':_0x3a5379[_0x35b68f('0xc99')][_0x35b68f('0xf5d')],'license':_0x3a5379[_0x35b68f('0xace')],'setting':_0x3a5379[_0x35b68f('0x260a')],'crudPermissions':_0x3a5379[_0x35b68f('0x1134')]}});}function _0x5b1bb3(_0x428e2f){const _0xf415f5=_0x325b69;_0xdf5db3['cmCustomField'][_0xf415f5('0xd7e')]({'id':_0x428e2f['id']})[_0xf415f5('0xe53')][_0xf415f5('0x683')](function(){const _0x32e769=_0xf415f5;_0x2e3ca0()[_0x32e769('0x3ec')](_0x3a5379[_0x32e769('0xc99')]['rows'],{'id':_0x428e2f['id']}),_0x3a5379[_0x32e769('0xc99')]['count']-=0x1,!_0x3a5379['globalCustomFields']['rows'][_0x32e769('0x1564')]&&_0x3a5379[_0x32e769('0x14c2')](),_0x3b5522['success']({'title':_0x2e3ca0()[_0x32e769('0x1e03')]('GlobalCustomField')+_0x32e769('0xbfc'),'msg':_0x428e2f['name']?_0x428e2f['name']+_0x32e769('0x194d'):''});})[_0xf415f5('0x130a')](function(_0x6bf9c9){const _0x39ef10=_0xf415f5;if(_0x6bf9c9[_0x39ef10('0x5a5')]&&_0x6bf9c9['data'][_0x39ef10('0x17f')]&&_0x6bf9c9[_0x39ef10('0x5a5')]['errors']['length']){_0x3a5379[_0x39ef10('0x17f')]=_0x6bf9c9[_0x39ef10('0x5a5')][_0x39ef10('0x17f')]||[{'message':_0x6bf9c9[_0x39ef10('0x1ff0')](),'type':_0x39ef10('0x9e5')}];for(let _0x436cbd=0x0;_0x436cbd<_0x6bf9c9[_0x39ef10('0x5a5')]['errors'][_0x39ef10('0x1564')];_0x436cbd++){_0x3b5522[_0x39ef10('0x52a')]({'title':_0x6bf9c9[_0x39ef10('0x5a5')][_0x39ef10('0x17f')][_0x436cbd][_0x39ef10('0xcf0')],'msg':_0x6bf9c9[_0x39ef10('0x5a5')]['errors'][_0x436cbd]['message']});}}else _0x3b5522['error']({'title':_0x6bf9c9['status']?_0x39ef10('0x2168')+_0x6bf9c9[_0x39ef10('0x13ee')]+'\x20-\x20'+_0x6bf9c9[_0x39ef10('0x24a9')]:_0x39ef10('0x9e5'),'msg':_0x6bf9c9[_0x39ef10('0x5a5')]?JSON[_0x39ef10('0x258a')](_0x6bf9c9[_0x39ef10('0x5a5')][_0x39ef10('0x8c2')]):_0x6bf9c9[_0x39ef10('0x8c2')]||_0x6bf9c9[_0x39ef10('0x1ff0')]()});});}function _0x50ec38(){const _0x147ef1=_0x325b69,_0x20753d=angular[_0x147ef1('0x1a86')](_0x3a5379['selectedGlobalCustomFields']);return _0x3a5379[_0x147ef1('0x21a8')]=[],_0x20753d;}function _0x42b18e(_0x4258f9){const _0x1a4180=_0x325b69,_0x26dd27=_0x58d551[_0x1a4180('0x1c6f')]()['title'](_0x1a4180('0x1acc'))[_0x1a4180('0x26e3')](''+_0x3a5379[_0x1a4180('0x21a8')][_0x1a4180('0x1564')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x1a4180('0x1040')](_0x1a4180('0x1d3a'))[_0x1a4180('0xe42')](_0x4258f9)['ok']('OK')[_0x1a4180('0x19fb')]('CANCEL');_0x58d551['show'](_0x26dd27)['then'](function(){const _0x1696be=_0x1a4180;_0x3a5379['selectedGlobalCustomFields'][_0x1696be('0x1299')](function(_0x1033ad){_0x5b1bb3(_0x1033ad);}),_0x3a5379['selectedGlobalCustomFields']=[];});}function _0xfc5d52(){const _0x53f687=_0x325b69;_0x3a5379[_0x53f687('0x21a8')]=[];}function _0x281df9(){const _0x17155b=_0x325b69;_0x3a5379[_0x17155b('0x21a8')]=_0x3a5379['globalCustomFields'][_0x17155b('0xf5d')];}}const _0x2e53fc=_0x24f71f;_0x469a8b['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0xe01'),_0x189033('0x2335'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x469a8b(_0x38b423,_0x4a514a,_0x55261f,_0x175a94,_0x2f73b6,_0x548c3b,_0x232795,_0x2e847b,_0x3dca8c,_0x980d61,_0x45f733,_0x35573e,_0x448a5b,_0x3bac96){const _0x2fc9dc=_0x189033,_0xfb225=this;_0xfb225[_0x2fc9dc('0x11ed')]=_0x45f733[_0x2fc9dc('0x20b2')](),_0xfb225['errors']=[],_0xfb225['setting']=_0x448a5b,_0xfb225['license']=_0x35573e,_0xfb225['crudPermissions']=_0x3bac96,_0xfb225[_0x2fc9dc('0x258d')]={},_0xfb225[_0x2fc9dc('0x19b2')]=_0xfb225[_0x2fc9dc('0x260a')]&&_0xfb225[_0x2fc9dc('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xfb225['title']=_0x2fc9dc('0xfa0'),_0xfb225[_0x2fc9dc('0x2335')]=angular['copy'](_0x3dca8c),_0xfb225[_0x2fc9dc('0xe01')]=_0x2e847b,_0xfb225[_0x2fc9dc('0x18b7')]=![];!_0xfb225[_0x2fc9dc('0x2335')]&&(_0xfb225[_0x2fc9dc('0x2335')]={},_0xfb225[_0x2fc9dc('0xf28')]='CONTACTMANAGER.NEW_LIST',_0xfb225[_0x2fc9dc('0x18b7')]=!![]);_0xfb225[_0x2fc9dc('0x190b')]=_0x4b55ef,_0xfb225[_0x2fc9dc('0x279f')]=_0x3dab7c,_0xfb225[_0x2fc9dc('0x1cbd')]=_0x232882,_0xfb225[_0x2fc9dc('0x16b3')]=_0x573625,_0xfb225['closeDialog']=_0x523b01;function _0x4b55ef(){const _0xe2b513=_0x2fc9dc;_0xfb225[_0xe2b513('0x17f')]=[],_0x980d61['cmList']['save'](_0xfb225['list'])[_0xe2b513('0xe53')][_0xe2b513('0x683')](function(_0x1ef285){const _0x39e79f=_0xe2b513;_0xfb225[_0x39e79f('0xe01')]['unshift'](_0x1ef285[_0x39e79f('0x24e1')]()),_0x232795['success']({'title':_0x39e79f('0x3d9'),'msg':_0xfb225[_0x39e79f('0x2335')][_0x39e79f('0x60a')]?_0xfb225[_0x39e79f('0x2335')][_0x39e79f('0x60a')]+_0x39e79f('0x14b5'):''}),_0x523b01(_0x1ef285);})[_0xe2b513('0x130a')](function(_0x1dbfb4){const _0x1d49c9=_0xe2b513;if(_0x1dbfb4['data']&&_0x1dbfb4[_0x1d49c9('0x5a5')][_0x1d49c9('0x17f')]&&_0x1dbfb4['data'][_0x1d49c9('0x17f')]['length']){_0xfb225[_0x1d49c9('0x17f')]=_0x1dbfb4[_0x1d49c9('0x5a5')]['errors']||[{'message':_0x1dbfb4['toString'](),'type':_0x1d49c9('0x70')}];for(let _0x1352b8=0x0;_0x1352b8<_0x1dbfb4[_0x1d49c9('0x5a5')][_0x1d49c9('0x17f')][_0x1d49c9('0x1564')];_0x1352b8+=0x1){_0x232795[_0x1d49c9('0x52a')]({'title':_0x1dbfb4['data'][_0x1d49c9('0x17f')][_0x1352b8][_0x1d49c9('0xcf0')],'msg':_0x1dbfb4[_0x1d49c9('0x5a5')]['errors'][_0x1352b8][_0x1d49c9('0x8c2')]});}}else _0x232795[_0x1d49c9('0x52a')]({'title':_0x1dbfb4[_0x1d49c9('0x13ee')]?_0x1d49c9('0x2168')+_0x1dbfb4[_0x1d49c9('0x13ee')]+_0x1d49c9('0xbf6')+_0x1dbfb4[_0x1d49c9('0x24a9')]:_0x1d49c9('0x70'),'msg':_0x1dbfb4[_0x1d49c9('0x5a5')]?JSON['stringify'](_0x1dbfb4[_0x1d49c9('0x5a5')]['message']):_0x1dbfb4[_0x1d49c9('0x1ff0')]()});});}function _0x3dab7c(){const _0x2734e8=_0x2fc9dc;_0xfb225[_0x2734e8('0x17f')]=[],_0x980d61['cmList'][_0x2734e8('0x2480')]({'id':_0xfb225[_0x2734e8('0x2335')]['id']},_0xfb225[_0x2734e8('0x2335')])['$promise'][_0x2734e8('0x683')](function(_0x40417a){const _0x48eb35=_0x2734e8,_0x28bb07=_0x2e3ca0()['find'](_0xfb225[_0x48eb35('0xe01')],{'id':_0x40417a['id']});_0x28bb07&&_0x2e3ca0()[_0x48eb35('0xf22')](_0x28bb07,_0x2e3ca0()['pick'](_0x40417a['toJSON'](),_0x2e3ca0()[_0x48eb35('0x55e')](_0x28bb07))),_0x232795[_0x48eb35('0x53')]({'title':_0x48eb35('0x8ed'),'msg':_0xfb225['list'][_0x48eb35('0x60a')]?_0xfb225[_0x48eb35('0x2335')]['name']+'\x20has\x20been\x20saved!':''}),_0x523b01(_0x40417a);})['catch'](function(_0x24c9cf){const _0x16ec27=_0x2734e8;if(_0x24c9cf['data']&&_0x24c9cf[_0x16ec27('0x5a5')][_0x16ec27('0x17f')]&&_0x24c9cf['data'][_0x16ec27('0x17f')]['length']){_0xfb225[_0x16ec27('0x17f')]=_0x24c9cf[_0x16ec27('0x5a5')][_0x16ec27('0x17f')]||[{'message':_0x24c9cf[_0x16ec27('0x1ff0')](),'type':_0x16ec27('0x1864')}];for(let _0x15eb3c=0x0;_0x15eb3c<_0x24c9cf[_0x16ec27('0x5a5')]['errors'][_0x16ec27('0x1564')];_0x15eb3c++){_0x232795[_0x16ec27('0x52a')]({'title':_0x24c9cf[_0x16ec27('0x5a5')][_0x16ec27('0x17f')][_0x15eb3c][_0x16ec27('0xcf0')],'msg':_0x24c9cf[_0x16ec27('0x5a5')][_0x16ec27('0x17f')][_0x15eb3c][_0x16ec27('0x8c2')]});}}else _0x232795['error']({'title':_0x24c9cf[_0x16ec27('0x13ee')]?_0x16ec27('0x2168')+_0x24c9cf['status']+'\x20-\x20'+_0x24c9cf['statusText']:_0x16ec27('0x1864'),'msg':_0x24c9cf[_0x16ec27('0x5a5')]?JSON[_0x16ec27('0x258a')](_0x24c9cf[_0x16ec27('0x5a5')]['message']):_0x24c9cf[_0x16ec27('0x1ff0')]()});});}function _0x232882(_0x6a2e49){const _0x126b0c=_0x2fc9dc;_0xfb225[_0x126b0c('0x17f')]=[];const _0x12e4cd=_0x175a94[_0x126b0c('0x1c6f')]()[_0x126b0c('0xf28')](_0x126b0c('0x4d'))['content']('The\x20list\x20will\x20be\x20deleted.')[_0x126b0c('0x1040')](_0x126b0c('0x1dc3'))['ok'](_0x126b0c('0x2307'))[_0x126b0c('0x19fb')](_0x126b0c('0x253a'))[_0x126b0c('0xe42')](_0x6a2e49);_0x175a94[_0x126b0c('0x1d4')](_0x12e4cd)[_0x126b0c('0x683')](function(){const _0x4eb938=_0x126b0c;_0x980d61[_0x4eb938('0x259b')]['delete']({'id':_0xfb225[_0x4eb938('0x2335')]['id']})['$promise']['then'](function(){const _0x42d313=_0x4eb938;_0x2e3ca0()[_0x42d313('0x3ec')](_0xfb225[_0x42d313('0xe01')],{'id':_0xfb225[_0x42d313('0x2335')]['id']}),_0x232795['success']({'title':_0x42d313('0x23c9'),'msg':(_0xfb225[_0x42d313('0x2335')][_0x42d313('0x60a')]||'list')+'\x20has\x20been\x20deleted!'}),_0x523b01(_0xfb225[_0x42d313('0x2335')]);})['catch'](function(_0x43a2cd){const _0x31e008=_0x4eb938;if(_0x43a2cd[_0x31e008('0x5a5')]&&_0x43a2cd[_0x31e008('0x5a5')]['errors']&&_0x43a2cd[_0x31e008('0x5a5')][_0x31e008('0x17f')]['length']){_0xfb225[_0x31e008('0x17f')]=_0x43a2cd[_0x31e008('0x5a5')][_0x31e008('0x17f')]||[{'message':_0x43a2cd[_0x31e008('0x1ff0')](),'type':'api.cmList.delete'}];for(let _0x3f0d02=0x0;_0x3f0d02<_0x43a2cd['data'][_0x31e008('0x17f')][_0x31e008('0x1564')];_0x3f0d02++){_0x232795[_0x31e008('0x52a')]({'title':_0x43a2cd[_0x31e008('0x5a5')][_0x31e008('0x17f')][_0x3f0d02][_0x31e008('0xcf0')],'msg':_0x43a2cd['data'][_0x31e008('0x17f')][_0x3f0d02][_0x31e008('0x8c2')]});}}else _0x232795['error']({'title':_0x43a2cd['status']?_0x31e008('0x2168')+_0x43a2cd[_0x31e008('0x13ee')]+_0x31e008('0xbf6')+_0x43a2cd[_0x31e008('0x24a9')]:_0x31e008('0x1f46'),'msg':_0x43a2cd[_0x31e008('0x5a5')]?JSON['stringify'](_0x43a2cd[_0x31e008('0x5a5')]['message']):_0x43a2cd[_0x31e008('0x8c2')]||_0x43a2cd['toString']()});});},function(){});}function _0x573625(_0x2051db){return _0x2051db===null?undefined:new Date(_0x2051db);}function _0x523b01(_0x115510){const _0x3ab230=_0x2fc9dc;_0x175a94[_0x3ab230('0x1715')](_0x115510);}}const _0x69030f=_0x469a8b;_0x2ba1e5[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x56b'),_0x189033('0x2335'),_0x189033('0xe01'),_0x189033('0x2c9'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x2ba1e5(_0x3c7440,_0x54497d,_0x111a86,_0x1bc1d9,_0x45f357,_0x3f6e45,_0xd2ebe9,_0x465aec,_0x4f65ec,_0x49f856){const _0x380ebe=_0x189033,_0x2d49ae=this;_0x2d49ae[_0x380ebe('0x11ed')]=_0x4f65ec[_0x380ebe('0x20b2')](),_0x2d49ae[_0x380ebe('0x2335')]=_0x45f357,_0x2d49ae[_0x380ebe('0x1134')]=_0x49f856,_0x2d49ae[_0x380ebe('0x2c9')]=_0xd2ebe9,_0x2d49ae[_0x380ebe('0x1996')]=[],_0x2d49ae['allowedItems']=[],_0x2d49ae['selectedItems']=[],_0x2d49ae[_0x380ebe('0x125e')]=[],_0x2d49ae[_0x380ebe('0x23a7')]=[],_0x2d49ae[_0x380ebe('0x2106')]=![],_0x2d49ae[_0x380ebe('0x1dd2')]=_0x4b1dc,_0x2d49ae['saveAgents']=_0x461b7d,_0x2d49ae[_0x380ebe('0xf82')]=_0x36531f,_0x2d49ae[_0x380ebe('0x169f')]={'readOnly':!_0x2d49ae[_0x380ebe('0x1134')][_0x380ebe('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x380ebe('0x60a'),'line1':_0x380ebe('0x11bc'),'line2':[_0x380ebe('0x60a'),_0x380ebe('0x1d43')],'line3':'','labelAll':_0x465aec[_0x380ebe('0x2728')](_0x380ebe('0xc56')),'labelSelected':_0x465aec[_0x380ebe('0x2728')](_0x380ebe('0x15e9')),'transferCallback':function(){const _0x3de6e7=_0x380ebe,_0x12f89c=_0x2e3ca0()[_0x3de6e7('0x25cb')](_0x2d49ae[_0x3de6e7('0x23a7')],_0x2d49ae[_0x3de6e7('0x1378')],'id');_0x2d49ae[_0x3de6e7('0x2106')]=_0x2e3ca0()[_0x3de6e7('0x173f')](_0x12f89c)?![]:!![];}};function _0x4b1dc(){const _0x2e3678=_0x380ebe;return _0x4f65ec['hasRole'](_0x2e3678('0x20c2'))?_0x1b2a3b()[_0x2e3678('0x130a')](function(_0x46422d){const _0x38f3dd=_0x2e3678;_0x111a86[_0x38f3dd('0x52a')]({'title':_0x46422d['status']?_0x38f3dd('0x2168')+_0x46422d[_0x38f3dd('0x13ee')]+_0x38f3dd('0xbf6')+_0x46422d[_0x38f3dd('0x24a9')]:_0x38f3dd('0x144f'),'msg':_0x46422d[_0x38f3dd('0x13ee')]?JSON[_0x38f3dd('0x258a')](_0x46422d[_0x38f3dd('0x5a5')]):_0x46422d[_0x38f3dd('0x1ff0')]()});}):_0x1fdd3c()[_0x2e3678('0x683')](function(_0x596639){const _0x3a185a=_0x2e3678;return _0x2d49ae[_0x3a185a('0x1aa')]=_0x596639,_0x1b2a3b();})[_0x2e3678('0x130a')](function(_0x5747ec){const _0x2907c0=_0x2e3678;_0x111a86[_0x2907c0('0x52a')]({'title':_0x5747ec['status']?'API:'+_0x5747ec[_0x2907c0('0x13ee')]+_0x2907c0('0xbf6')+_0x5747ec[_0x2907c0('0x24a9')]:'SYSTEM:GET_AGENTS','msg':_0x5747ec[_0x2907c0('0x13ee')]?JSON['stringify'](_0x5747ec[_0x2907c0('0x5a5')]):_0x5747ec['toString']()});});}function _0x1fdd3c(){return _0x54497d(function(_0x4e3a09,_0x4cbae0){const _0x414d29=a0_0x4e0a;_0x1bc1d9[_0x414d29('0x22df')][_0x414d29('0x1e6e')]({'userProfileId':_0x2d49ae[_0x414d29('0x11ed')]['userProfileId'],'name':_0x414d29('0x1bc0')})[_0x414d29('0xe53')][_0x414d29('0x683')](function(_0x438634){const _0x405a67=_0x438634&&_0x438634['rows']?_0x438634['rows'][0x0]:null;_0x4e3a09(_0x405a67);})[_0x414d29('0x130a')](function(_0x4ebc63){_0x4cbae0(_0x4ebc63);});});}function _0x1b2a3b(){return _0x54497d(function(_0x4ef98e,_0x5506e2){const _0x7dec51=a0_0x4e0a;return _0x3af491()[_0x7dec51('0x683')](function(_0x3abd5d){const _0x50c1fb=_0x7dec51;return _0x2d49ae['items']=_0x3abd5d[_0x50c1fb('0xf5d')]?_0x3abd5d['rows']:[],_0x4f65ec[_0x50c1fb('0xca1')](_0x50c1fb('0x20c2'))?_0x3abd5d:_0x2d49ae['section']?_0x2d49ae[_0x50c1fb('0x1aa')]['autoAssociation']?_0x3abd5d:_0x4e76d4():null;})[_0x7dec51('0x683')](function(_0x549e96){const _0x5e2ec3=_0x7dec51,_0x57549c=_0x549e96&&_0x549e96[_0x5e2ec3('0xf5d')]?_0x549e96[_0x5e2ec3('0xf5d')]:[];return _0x2d49ae[_0x5e2ec3('0x1c47')]=_0x2e3ca0()[_0x5e2ec3('0x386')](_0x57549c,function(_0x4fb37b){const _0x2451e8=_0x5e2ec3;return _0x2e3ca0()[_0x2451e8('0x1c07')](_0x2d49ae[_0x2451e8('0x1996')],{'id':_0x4f65ec[_0x2451e8('0xca1')](_0x2451e8('0x20c2'))||_0x2d49ae[_0x2451e8('0x1aa')]['autoAssociation']?_0x4fb37b['id']:_0x4fb37b[_0x2451e8('0x832')]});}),_0x2d49ae[_0x5e2ec3('0x125e')]=angular[_0x5e2ec3('0x1a86')](_0x2d49ae[_0x5e2ec3('0x1c47')]),_0x2d49ae[_0x5e2ec3('0x1996')][_0x5e2ec3('0x1299')](function(_0x620d4){const _0x300da0=_0x5e2ec3,_0xcbb7b1=_0x2e3ca0()['find'](_0x2d49ae[_0x300da0('0x1c47')],{'id':_0x620d4['id']});_0x4f65ec['hasRole']('admin')?_0x620d4[_0x300da0('0x24f4')]=!![]:_0x620d4[_0x300da0('0x24f4')]=typeof _0xcbb7b1!==_0x300da0('0x1867')?!![]:![];}),_0x23ecb0();})[_0x7dec51('0x683')](function(_0x112f25){const _0x2161ab=_0x7dec51,_0x452c2f=_0x112f25&&_0x112f25[_0x2161ab('0xf5d')]?_0x112f25[_0x2161ab('0xf5d')]:[];_0x2d49ae[_0x2161ab('0x1378')]=_0x2e3ca0()['map'](_0x452c2f,function(_0x99045f){const _0x3e3b8d=_0x2161ab,_0x2bf3c5=_0x2e3ca0()[_0x3e3b8d('0x1c07')](_0x2d49ae['items'],{'id':_0x99045f['id']});return _0x2bf3c5[_0x3e3b8d('0x1e2a')]=_0x99045f[_0x3e3b8d('0x36')]?_0x3e3b8d('0x23d0')+_0x99045f[_0x3e3b8d('0x36')][_0x3e3b8d('0x1e2a')]:'',_0x2bf3c5[_0x3e3b8d('0x1d43')]=typeof _0x99045f[_0x3e3b8d('0x1d43')]!=='undefined'?'<'+_0x99045f[_0x3e3b8d('0x1d43')]+'>':'',_0x2bf3c5;}),_0x2d49ae[_0x2161ab('0x23a7')]=angular[_0x2161ab('0x1a86')](_0x2d49ae[_0x2161ab('0x1378')]),_0x2d49ae[_0x2161ab('0x169f')][_0x2161ab('0x1378')]=_0x2d49ae['selectedItems'],_0x2d49ae[_0x2161ab('0x169f')]['items']=_0x2e3ca0()[_0x2161ab('0x461')](_0x2d49ae[_0x2161ab('0x1c47')],_0x2d49ae[_0x2161ab('0x169f')][_0x2161ab('0x1378')],'id'),_0x4ef98e();})[_0x7dec51('0x130a')](function(_0x324e05){_0x5506e2(_0x324e05);});});}function _0x4e76d4(){return _0x54497d(function(_0x360170,_0x4f02db){const _0x575e0c=a0_0x4e0a;return _0x1bc1d9[_0x575e0c('0xcf7')][_0x575e0c('0x1e6e')]({'sectionId':_0x2d49ae[_0x575e0c('0x1aa')]['id'],'nolimit':!![]})[_0x575e0c('0xe53')][_0x575e0c('0x683')](function(_0x1fe0ea){_0x360170(_0x1fe0ea);})[_0x575e0c('0x130a')](function(_0xf3ccbc){_0x4f02db(_0xf3ccbc);});});}function _0x23ecb0(){return _0x54497d(function(_0x278b02,_0x50120c){const _0x56384e=a0_0x4e0a;return _0x1bc1d9['cmList'][_0x56384e('0x8e7')]({'id':_0x2d49ae['list']['id'],'fields':_0x56384e('0x72b'),'nolimit':!![],'role':_0x56384e('0x2327')})[_0x56384e('0xe53')][_0x56384e('0x683')](function(_0x258b4f){_0x278b02(_0x258b4f);})['catch'](function(_0xb70bcd){_0x50120c(_0xb70bcd);});});}function _0x3af491(){return _0x54497d(function(_0x25bcb8,_0x3ec79c){const _0x26d0f7=a0_0x4e0a;return _0x1bc1d9[_0x26d0f7('0xc96')]['get']({'fields':_0x26d0f7('0x72b'),'nolimit':!![],'role':'agent'})[_0x26d0f7('0xe53')][_0x26d0f7('0x683')](function(_0x5b0a86){_0x25bcb8(_0x5b0a86);})['catch'](function(_0x5a120a){_0x3ec79c(_0x5a120a);});});}function _0x27464c(_0x4643fc){return _0x54497d(function(_0x2ef5f6,_0x622164){const _0x363117=a0_0x4e0a;_0x2e3ca0()[_0x363117('0x173f')](_0x4643fc)?_0x2ef5f6():_0x1bc1d9[_0x363117('0x259b')][_0x363117('0x2179')]({'id':_0x2d49ae[_0x363117('0x2335')]['id'],'ids':_0x2e3ca0()[_0x363117('0x386')](_0x4643fc,'id')})[_0x363117('0xe53')]['then'](function(){_0x2ef5f6();})['catch'](function(_0x1c1d57){_0x622164(_0x1c1d57);});});}function _0x94d465(_0x52a9f3){return _0x54497d(function(_0x279edb,_0x271ee){const _0x26f272=a0_0x4e0a;_0x2e3ca0()[_0x26f272('0x173f')](_0x52a9f3)?_0x279edb():_0x1bc1d9['cmList'][_0x26f272('0xf9')]({'id':_0x2d49ae[_0x26f272('0x2335')]['id'],'ids':_0x2e3ca0()[_0x26f272('0x386')](_0x52a9f3,'id')})[_0x26f272('0xe53')][_0x26f272('0x683')](function(){_0x279edb();})[_0x26f272('0x130a')](function(_0x244df3){_0x271ee(_0x244df3);});});}function _0x461b7d(){const _0x19d0c5=_0x380ebe,_0x426534=_0x2e3ca0()[_0x19d0c5('0x461')](_0x2d49ae[_0x19d0c5('0x23a7')],_0x2d49ae[_0x19d0c5('0x1378')],'id'),_0xcb840=_0x2e3ca0()[_0x19d0c5('0x461')](_0x2d49ae[_0x19d0c5('0x1378')],_0x2d49ae['startingSelectedItems'],'id');return _0x94d465(_0x426534)['then'](function(){return _0x27464c(_0xcb840);})['then'](function(){const _0x49775d=_0x19d0c5;_0x2d49ae[_0x49775d('0x2106')]=![],_0x2d49ae[_0x49775d('0x125e')]=angular[_0x49775d('0x1a86')](_0x2d49ae['allowedItems']),_0x2d49ae[_0x49775d('0x23a7')]=angular['copy'](_0x2d49ae[_0x49775d('0x1378')]),_0x111a86[_0x49775d('0x53')]({'title':_0x49775d('0xd28'),'msg':_0x49775d('0x89d')});})['catch'](function(_0x37ee32){const _0x7c3dc8=_0x19d0c5;_0x111a86[_0x7c3dc8('0x52a')]({'title':_0x37ee32[_0x7c3dc8('0x13ee')]?_0x7c3dc8('0x2168')+_0x37ee32[_0x7c3dc8('0x13ee')]+_0x7c3dc8('0xbf6')+_0x37ee32[_0x7c3dc8('0x24a9')]:'SYSTEM:LISTS_ASSOCIATION','msg':_0x37ee32['status']?JSON[_0x7c3dc8('0x258a')](_0x37ee32[_0x7c3dc8('0x5a5')]):_0x37ee32[_0x7c3dc8('0x1ff0')]()});});}function _0x36531f(){_0x3c7440['hide']();}}const _0x2a8c2a=_0x2ba1e5,_0x3f87bf=_0x180212['p']+_0x189033('0x8e8');_0x457bd[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),'$state','$q',_0x189033('0x1d08'),'$timeout',_0x189033('0x1e48'),_0x189033('0x16ea'),'toasty','api',_0x189033('0xba1')];function _0x457bd(_0x28bc0d,_0x2a4de5,_0x59731b,_0xf03d22,_0x1ff0cc,_0x302158,_0x4a2755,_0xdbf045,_0x1aa89a,_0x2c6033,_0x31815a){const _0x2b84fa=_0x189033,_0x2025ae=this;_0x2025ae[_0x2b84fa('0x11ed')]=_0x31815a[_0x2b84fa('0x20b2')](),_0x2025ae['list']={},_0x2025ae[_0x2b84fa('0x1687')]={'count':0x0,'rows':[]},_0x2025ae[_0x2b84fa('0xfc5')]=[],_0x2025ae[_0x2b84fa('0x1134')],_0x2025ae[_0x2b84fa('0x23a2')]={'fields':_0x2b84fa('0x2684'),'limit':0xa,'page':0x1},_0x2025ae[_0x2b84fa('0x10b7')]=_0x2e3ca0()[_0x2b84fa('0x24db')]([{'option':_0x2b84fa('0x1d8c'),'value':_0x2b84fa('0x12de')},{'option':_0x2b84fa('0xaf7'),'value':_0x2b84fa('0x135e')},{'option':_0x2b84fa('0x140f'),'value':'\x27number\x27'},{'option':_0x2b84fa('0x181a'),'value':_0x2b84fa('0x256b')},{'option':_0x2b84fa('0x80e'),'value':'\x27datetime\x27'}],function(_0x3e990f){const _0x54d217=_0x2b84fa;return _0x2e3ca0()[_0x54d217('0x1725')](_0x3e990f[_0x54d217('0x1c6b')],new RegExp('\x27','g'),'');}),_0x2025ae[_0x2b84fa('0x27c6')]=_0x2e3ca0()['keyBy']([{'option':_0x2b84fa('0x378'),'value':_0x2b84fa('0xd4f')}],function(_0x1496e3){const _0xb1cc83=_0x2b84fa;return _0x2e3ca0()[_0xb1cc83('0x1725')](_0x1496e3[_0xb1cc83('0x1c6b')],new RegExp('\x27','g'),'');}),_0x2025ae[_0x2b84fa('0x12f3')]=_0x4b8bce,_0x2025ae[_0x2b84fa('0x26eb')]=_0x4d9536,_0x2025ae[_0x2b84fa('0x53')]=_0x25e8b2,_0x2025ae['getListCustomFields']=_0x2f31f2,_0x2025ae['createOrEditListCustomField']=_0xec5ad3,_0x2025ae[_0x2b84fa('0x25b3')]=_0x24ac5c,_0x2025ae['deleteListCustomField']=_0x1f7591,_0x2025ae[_0x2b84fa('0xce2')]=_0x2521d4;function _0x4b8bce(_0x3bea7b,_0x144162){const _0x2a507e=_0x2b84fa;_0x2025ae['list']=_0x3bea7b,_0x2025ae[_0x2a507e('0x1134')]=typeof _0x144162!==_0x2a507e('0x1867')?_0x144162:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x2025ae['query']['ListId']=_0x2025ae[_0x2a507e('0x2335')]['id'],_0x2025ae[_0x2a507e('0x23a2')]['id']=_0x2025ae['list']['id'],_0x2f31f2();}function _0x4d9536(_0xda538b,_0xeb1715){const _0x1bea83=_0x2b84fa,_0x51d315=_0x4a2755[_0x1bea83('0x1c6f')]()[_0x1bea83('0xf28')](_0x1bea83('0xd5a'))[_0x1bea83('0x26e3')](_0x1bea83('0xed5')+(_0xda538b['name']||_0xda538b['id']&&_0x2e3ca0()[_0x1bea83('0x2711')]('customField\x20#')+_0xda538b['id']||'customField')+_0x1bea83('0x20f1')+_0x1bea83('0x1ee7'))[_0x1bea83('0x1040')](_0x1bea83('0x11c9'))[_0x1bea83('0xe42')](_0xeb1715)['ok']('OK')[_0x1bea83('0x19fb')]('CANCEL');_0x4a2755['show'](_0x51d315)['then'](function(){_0x1f7591(_0xda538b);},function(){const _0x27ad6f=_0x1bea83;console['log'](_0x27ad6f('0x16b8'));});}function _0x25e8b2(_0x563e16){_0x2025ae['listCustomFields']=_0x563e16||{'count':0x0,'rows':[]};}function _0x2f31f2(){const _0x7d55e5=_0x2b84fa;_0x2025ae[_0x7d55e5('0x23a2')]['offset']=(_0x2025ae['query'][_0x7d55e5('0xdf8')]-0x1)*_0x2025ae['query'][_0x7d55e5('0x6f0')],_0x2025ae[_0x7d55e5('0x1883')]=_0x2c6033['cmList']['getCustomFields'](_0x2025ae[_0x7d55e5('0x23a2')],_0x25e8b2)[_0x7d55e5('0xe53')];}function _0xec5ad3(_0x3af6d2,_0x55db95){const _0x4d0218=_0x2b84fa;_0x4a2755[_0x4d0218('0x1d4')]({'controller':_0x4d0218('0x1332'),'controllerAs':'vm','templateUrl':_0x3f87bf,'parent':angular[_0x4d0218('0x1fcc')](_0xdbf045[_0x4d0218('0x18e5')]),'targetEvent':_0x3af6d2,'clickOutsideToClose':!![],'locals':{'list':_0x2025ae['list'],'customField':_0x55db95,'customFields':_0x2025ae['listCustomFields'][_0x4d0218('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x2025ae[_0x4d0218('0x1134')]}});}function _0x1f7591(_0x1ccb04){const _0x554b35=_0x2b84fa;_0x2c6033[_0x554b35('0xf57')][_0x554b35('0xd7e')]({'id':_0x1ccb04['id']})[_0x554b35('0xe53')]['then'](function(){const _0x6229bf=_0x554b35;_0x2e3ca0()[_0x6229bf('0x3ec')](_0x2025ae['listCustomFields'][_0x6229bf('0xf5d')],{'id':_0x1ccb04['id']}),_0x2025ae[_0x6229bf('0x1687')]['count']-=0x1,!_0x2025ae[_0x6229bf('0x1687')][_0x6229bf('0xf5d')][_0x6229bf('0x1564')]&&_0x2f31f2(),_0x1aa89a[_0x6229bf('0x53')]({'title':_0x6229bf('0x16e4'),'msg':_0x1ccb04[_0x6229bf('0x60a')]?_0x1ccb04[_0x6229bf('0x60a')]+_0x6229bf('0x194d'):''});})[_0x554b35('0x130a')](function(_0x438230){const _0x27a5b6=_0x554b35;if(_0x438230[_0x27a5b6('0x5a5')]&&_0x438230[_0x27a5b6('0x5a5')][_0x27a5b6('0x17f')]&&_0x438230['data'][_0x27a5b6('0x17f')][_0x27a5b6('0x1564')]){_0x2025ae['errors']=_0x438230[_0x27a5b6('0x5a5')][_0x27a5b6('0x17f')]||[{'message':_0x438230['toString'](),'type':_0x27a5b6('0x4a8')}];for(let _0x154dc5=0x0;_0x154dc5<_0x438230[_0x27a5b6('0x5a5')]['errors']['length'];_0x154dc5++){_0x1aa89a[_0x27a5b6('0x52a')]({'title':_0x438230[_0x27a5b6('0x5a5')][_0x27a5b6('0x17f')][_0x154dc5][_0x27a5b6('0xcf0')],'msg':_0x438230[_0x27a5b6('0x5a5')][_0x27a5b6('0x17f')][_0x154dc5]['message']});}}else _0x1aa89a[_0x27a5b6('0x52a')]({'title':_0x438230['status']?'API:'+_0x438230[_0x27a5b6('0x13ee')]+_0x27a5b6('0xbf6')+_0x438230[_0x27a5b6('0x24a9')]:_0x27a5b6('0x4a8'),'msg':_0x438230[_0x27a5b6('0x5a5')]?JSON[_0x27a5b6('0x258a')](_0x438230[_0x27a5b6('0x5a5')][_0x27a5b6('0x8c2')]):_0x438230['message']||_0x438230['toString']()});});}function _0x24ac5c(){const _0x553130=_0x2b84fa,_0x50951a=angular[_0x553130('0x1a86')](_0x2025ae[_0x553130('0xfc5')]);return _0x2025ae[_0x553130('0xfc5')]=[],_0x50951a;}function _0x2521d4(_0x67954d){const _0x48759c=_0x2b84fa,_0x22336e=_0x4a2755['confirm']()[_0x48759c('0xf28')](_0x48759c('0x86c'))[_0x48759c('0x26e3')](''+_0x2025ae[_0x48759c('0xfc5')][_0x48759c('0x1564')]+_0x48759c('0x93c')+_0x48759c('0x1ee7'))[_0x48759c('0x1040')](_0x48759c('0xc26'))['targetEvent'](_0x67954d)['ok']('OK')[_0x48759c('0x19fb')](_0x48759c('0x16b8'));_0x4a2755[_0x48759c('0x1d4')](_0x22336e)[_0x48759c('0x683')](function(){const _0x1eeafa=_0x48759c;_0x2025ae[_0x1eeafa('0xfc5')][_0x1eeafa('0x1299')](function(_0x396519){_0x1f7591(_0x396519);}),_0x2025ae[_0x1eeafa('0xfc5')]=[];});}let _0x20e9de=!![],_0x3342bc=0x1;_0x2a4de5[_0x2b84fa('0x186d')](_0x2b84fa('0x229'),function(_0x3e2ea5,_0x9c327e){const _0x21fea3=_0x2b84fa;_0x20e9de?_0x302158(function(){_0x20e9de=![];}):(!_0x9c327e&&(_0x3342bc=_0x2025ae[_0x21fea3('0x23a2')][_0x21fea3('0xdf8')]),_0x3e2ea5!==_0x9c327e&&(_0x2025ae[_0x21fea3('0x23a2')]['page']=0x1),!_0x3e2ea5&&(_0x2025ae[_0x21fea3('0x23a2')]['page']=_0x3342bc),_0x2f31f2());});}const _0x5390d6=_0x457bd;_0x123b11[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0xc4d'),'customField',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x123b11(_0x5c77ec,_0x1605ae,_0x44d03f,_0x5af3b6,_0x40dbf0,_0x954e0b,_0x4a1e31,_0x5568e2,_0x47ac2c,_0x2fd127,_0x2dd792,_0x2c3b5f,_0x2cd4a4,_0x3b2d65){const _0x42a9c4=_0x189033,_0x2c39c0=this;_0x2c39c0['currentUser']=_0x2dd792['getCurrentUser'](),_0x2c39c0[_0x42a9c4('0x17f')]=[],_0x2c39c0['setting']=_0x2cd4a4,_0x2c39c0[_0x42a9c4('0xace')]=_0x2c3b5f,_0x2c39c0[_0x42a9c4('0x1134')]=_0x3b2d65,_0x2c39c0[_0x42a9c4('0x258d')]={},_0x2c39c0[_0x42a9c4('0x19b2')]=_0x2c39c0[_0x42a9c4('0x260a')]&&_0x2c39c0[_0x42a9c4('0x260a')][_0x42a9c4('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2c39c0[_0x42a9c4('0xf28')]=_0x42a9c4('0x1923'),_0x2c39c0[_0x42a9c4('0xf4')]={'animation':0x320,'sort':!![],'onSort':function(){const _0x2a7d0c=_0x42a9c4;_0x5c77ec['customFieldForm'][_0x2a7d0c('0xb0')]=![];}},_0x2c39c0[_0x42a9c4('0x7f8')]=_0x47ac2c,_0x2c39c0['customFields']=_0x5568e2,_0x2c39c0['newCustomField']=![];!_0x2c39c0['customField']&&(_0x2c39c0[_0x42a9c4('0x7f8')]={'type':_0x42a9c4('0x1bcd'),'actionType':_0x42a9c4('0xcf2')},_0x2c39c0['title']=_0x42a9c4('0x9db'),_0x2c39c0[_0x42a9c4('0x3f6')]=!![]);_0x1605ae[_0x42a9c4('0x7f2')]['id']&&(_0x2c39c0['customField'][_0x42a9c4('0x1e4f')]=_0x1605ae[_0x42a9c4('0x7f2')]['id']);_0x5c77ec['$watch'](_0x42a9c4('0x1c74'),function(_0x319e35,_0x5b65db){const _0x1fd904=_0x42a9c4;if(_0x319e35!==_0x5b65db)switch(_0x319e35){case _0x1fd904('0x1bcd'):_0x2c39c0['customField']['values']='';break;case'select':_0x2c39c0['customField'][_0x1fd904('0x17a0')]=[];break;default:}}),_0x2c39c0[_0x42a9c4('0x1e62')]=_0x4e5231,_0x2c39c0[_0x42a9c4('0x1946')]=_0x3c4712,_0x2c39c0[_0x42a9c4('0x2e8')]=_0x4de9a1,_0x2c39c0[_0x42a9c4('0x16b3')]=_0x1936ac,_0x2c39c0['addItem']=_0x4398bb,_0x2c39c0[_0x42a9c4('0x26d')]=_0x241b88,_0x2c39c0[_0x42a9c4('0x21b9')]=_0x51b581,_0x2c39c0[_0x42a9c4('0xf82')]=_0xddc459;function _0x4398bb(_0x14ab4d){const _0x4afbf9=_0x42a9c4;_0x14ab4d[_0x4afbf9('0x1fd0')]({'value':_0x4afbf9('0xd68')}),_0x5c77ec[_0x4afbf9('0x6ae')][_0x4afbf9('0xb0')]=![];}function _0x241b88(_0x130499,_0x22659f){const _0x563eba=_0x42a9c4;_0x130499[_0x563eba('0x2040')](_0x22659f,0x1),_0x5c77ec[_0x563eba('0x6ae')][_0x563eba('0xb0')]=![];}function _0x51b581(_0x6c1faa){const _0xc6f968=_0x42a9c4,_0x2d979b=_0x6c1faa[_0xc6f968('0x1564')];for(let _0x375fd8=0x0;_0x375fd8<_0x2d979b;_0x375fd8++){_0x6c1faa['splice'](0x0,0x1);}_0x5c77ec['customFieldForm'][_0xc6f968('0xb0')]=![];}function _0x4e5231(){const _0x592b1f=_0x42a9c4;_0x2c39c0[_0x592b1f('0x17f')]=[],_0x2fd127['cmList'][_0x592b1f('0x2023')]({'id':_0x1605ae[_0x592b1f('0x7f2')]['id']},_0x2c39c0[_0x592b1f('0x7f8')])['$promise'][_0x592b1f('0x683')](function(_0x1a0ba3){const _0x1eecc0=_0x592b1f;_0x2c39c0[_0x1eecc0('0xc4d')]['unshift'](_0x1a0ba3[_0x1eecc0('0x24e1')]()),_0x4a1e31[_0x1eecc0('0x53')]({'title':_0x1eecc0('0x1a7c'),'msg':_0x2c39c0['customField'][_0x1eecc0('0x60a')]?_0x2c39c0[_0x1eecc0('0x7f8')][_0x1eecc0('0x60a')]+_0x1eecc0('0x14b5'):''}),_0xddc459(_0x1a0ba3);})[_0x592b1f('0x130a')](function(_0x54666f){const _0x34e80a=_0x592b1f;if(_0x54666f['data']&&_0x54666f['data'][_0x34e80a('0x17f')]&&_0x54666f[_0x34e80a('0x5a5')]['errors'][_0x34e80a('0x1564')]){_0x2c39c0[_0x34e80a('0x17f')]=_0x54666f[_0x34e80a('0x5a5')][_0x34e80a('0x17f')]||[{'message':_0x54666f[_0x34e80a('0x1ff0')](),'type':_0x34e80a('0xf32')}];for(let _0x52e8dd=0x0;_0x52e8dd<_0x54666f['data'][_0x34e80a('0x17f')][_0x34e80a('0x1564')];_0x52e8dd+=0x1){_0x4a1e31[_0x34e80a('0x52a')]({'title':_0x54666f[_0x34e80a('0x5a5')][_0x34e80a('0x17f')][_0x52e8dd][_0x34e80a('0xcf0')],'msg':_0x54666f[_0x34e80a('0x5a5')][_0x34e80a('0x17f')][_0x52e8dd][_0x34e80a('0x8c2')]});}}else _0x4a1e31[_0x34e80a('0x52a')]({'title':_0x54666f[_0x34e80a('0x13ee')]?'API:'+_0x54666f[_0x34e80a('0x13ee')]+_0x34e80a('0xbf6')+_0x54666f[_0x34e80a('0x24a9')]:_0x34e80a('0xf32'),'msg':_0x54666f['data']?JSON[_0x34e80a('0x258a')](_0x54666f['data']['message']):_0x54666f[_0x34e80a('0x1ff0')]()});});}function _0x3c4712(){const _0x3b7a5d=_0x42a9c4;_0x2c39c0[_0x3b7a5d('0x17f')]=[],_0x2fd127[_0x3b7a5d('0xf57')][_0x3b7a5d('0x2480')]({'id':_0x2c39c0[_0x3b7a5d('0x7f8')]['id']},_0x2c39c0[_0x3b7a5d('0x7f8')])[_0x3b7a5d('0xe53')][_0x3b7a5d('0x683')](function(_0x3a72a2){const _0x1a3c50=_0x3b7a5d,_0x4fac0e=_0x2e3ca0()[_0x1a3c50('0x1c07')](_0x2c39c0['customFields'],{'id':_0x3a72a2['id']});_0x4fac0e&&_0x2e3ca0()[_0x1a3c50('0xf22')](_0x4fac0e,_0x2e3ca0()[_0x1a3c50('0x24d0')](_0x3a72a2['toJSON'](),_0x2e3ca0()[_0x1a3c50('0x55e')](_0x4fac0e))),_0x4a1e31[_0x1a3c50('0x53')]({'title':_0x1a3c50('0xc09'),'msg':_0x2c39c0['customField'][_0x1a3c50('0x60a')]?_0x2c39c0[_0x1a3c50('0x7f8')][_0x1a3c50('0x60a')]+_0x1a3c50('0xf59'):''}),_0xddc459(_0x3a72a2);})[_0x3b7a5d('0x130a')](function(_0x1ed033){const _0x2c8b9a=_0x3b7a5d;if(_0x1ed033['data']&&_0x1ed033[_0x2c8b9a('0x5a5')]['errors']&&_0x1ed033[_0x2c8b9a('0x5a5')]['errors'][_0x2c8b9a('0x1564')]){_0x2c39c0[_0x2c8b9a('0x17f')]=_0x1ed033[_0x2c8b9a('0x5a5')][_0x2c8b9a('0x17f')]||[{'message':_0x1ed033[_0x2c8b9a('0x1ff0')](),'type':_0x2c8b9a('0x21bd')}];for(let _0x7c30f2=0x0;_0x7c30f2<_0x1ed033['data']['errors'][_0x2c8b9a('0x1564')];_0x7c30f2++){_0x4a1e31[_0x2c8b9a('0x52a')]({'title':_0x1ed033[_0x2c8b9a('0x5a5')][_0x2c8b9a('0x17f')][_0x7c30f2][_0x2c8b9a('0xcf0')],'msg':_0x1ed033[_0x2c8b9a('0x5a5')][_0x2c8b9a('0x17f')][_0x7c30f2][_0x2c8b9a('0x8c2')]});}}else _0x4a1e31[_0x2c8b9a('0x52a')]({'title':_0x1ed033[_0x2c8b9a('0x13ee')]?'API:'+_0x1ed033['status']+_0x2c8b9a('0xbf6')+_0x1ed033[_0x2c8b9a('0x24a9')]:_0x2c8b9a('0x21bd'),'msg':_0x1ed033[_0x2c8b9a('0x5a5')]?JSON[_0x2c8b9a('0x258a')](_0x1ed033[_0x2c8b9a('0x5a5')][_0x2c8b9a('0x8c2')]):_0x1ed033['toString']()});});}function _0x4de9a1(_0x401d14){const _0x1c2506=_0x42a9c4;_0x2c39c0[_0x1c2506('0x17f')]=[];const _0x4b1015=_0x5af3b6['confirm']()[_0x1c2506('0xf28')](_0x1c2506('0x4d'))[_0x1c2506('0xa6a')](_0x1c2506('0xc29'))[_0x1c2506('0x1040')](_0x1c2506('0x6c4'))['ok'](_0x1c2506('0x2307'))[_0x1c2506('0x19fb')](_0x1c2506('0x253a'))[_0x1c2506('0xe42')](_0x401d14);_0x5af3b6[_0x1c2506('0x1d4')](_0x4b1015)['then'](function(){const _0xca279b=_0x1c2506;_0x2fd127['cmCustomField'][_0xca279b('0xd7e')]({'id':_0x2c39c0[_0xca279b('0x7f8')]['id']})[_0xca279b('0xe53')][_0xca279b('0x683')](function(){const _0x5294f4=_0xca279b;_0x2e3ca0()[_0x5294f4('0x3ec')](_0x2c39c0[_0x5294f4('0xc4d')],{'id':_0x2c39c0['customField']['id']}),_0x4a1e31['success']({'title':_0x5294f4('0x10e1'),'msg':(_0x2c39c0[_0x5294f4('0x7f8')]['name']||_0x5294f4('0x7f8'))+'\x20has\x20been\x20deleted!'}),_0xddc459(_0x2c39c0['customField']);})[_0xca279b('0x130a')](function(_0x1faca9){const _0x41711e=_0xca279b;if(_0x1faca9[_0x41711e('0x5a5')]&&_0x1faca9[_0x41711e('0x5a5')][_0x41711e('0x17f')]&&_0x1faca9[_0x41711e('0x5a5')][_0x41711e('0x17f')][_0x41711e('0x1564')]){_0x2c39c0[_0x41711e('0x17f')]=_0x1faca9[_0x41711e('0x5a5')][_0x41711e('0x17f')]||[{'message':_0x1faca9['toString'](),'type':_0x41711e('0x4af')}];for(let _0x45ca39=0x0;_0x45ca39<_0x1faca9[_0x41711e('0x5a5')][_0x41711e('0x17f')]['length'];_0x45ca39++){_0x4a1e31[_0x41711e('0x52a')]({'title':_0x1faca9['data'][_0x41711e('0x17f')][_0x45ca39][_0x41711e('0xcf0')],'msg':_0x1faca9[_0x41711e('0x5a5')][_0x41711e('0x17f')][_0x45ca39][_0x41711e('0x8c2')]});}}else _0x4a1e31[_0x41711e('0x52a')]({'title':_0x1faca9['status']?_0x41711e('0x2168')+_0x1faca9[_0x41711e('0x13ee')]+_0x41711e('0xbf6')+_0x1faca9[_0x41711e('0x24a9')]:_0x41711e('0x4af'),'msg':_0x1faca9[_0x41711e('0x5a5')]?JSON['stringify'](_0x1faca9[_0x41711e('0x5a5')][_0x41711e('0x8c2')]):_0x1faca9[_0x41711e('0x8c2')]||_0x1faca9[_0x41711e('0x1ff0')]()});});},function(){});}function _0x1936ac(_0x35ebb5){return _0x35ebb5===null?undefined:new Date(_0x35ebb5);}function _0xddc459(_0x1f0858){const _0x19fa97=_0x42a9c4;_0x5af3b6[_0x19fa97('0x1715')](_0x1f0858);}}const _0x26d570=_0x123b11,_0x2862e8=_0x180212['p']+_0x189033('0xe39');_0x50c667['$inject']=[_0x189033('0x938'),'$location',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x2335'),'userProfileSection'];function _0x50c667(_0xc93e41,_0x1b6588,_0x28be5d,_0x4e4acc,_0x4110a8,_0x30e09b,_0x9ca81e,_0x195e21,_0x2ad49f,_0x188901,_0x52a00c,_0x46c897){const _0xf5e42e=_0x189033,_0x3c43b3=this;_0x3c43b3[_0xf5e42e('0x11ed')]=_0x188901['getCurrentUser'](),_0x3c43b3[_0xf5e42e('0xace')]=_0x30e09b,_0x3c43b3['setting']=_0x9ca81e,_0x3c43b3[_0xf5e42e('0x19b2')]=_0x3c43b3[_0xf5e42e('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3c43b3[_0xf5e42e('0x1224')]=_0x1b6588[_0xf5e42e('0x173e')]()+_0xf5e42e('0x20de')+_0x1b6588[_0xf5e42e('0x19ac')](),_0x3c43b3[_0xf5e42e('0x2335')]=_0x52a00c||_0xc93e41[_0xf5e42e('0x7f2')][_0xf5e42e('0x2335')]||{},_0x3c43b3['userProfileSection']=_0x46c897&&_0x46c897['count']==0x1?_0x46c897['rows'][0x0]:null,_0x3c43b3['crudPermissions']=_0x188901[_0xf5e42e('0x142a')](_0x3c43b3[_0xf5e42e('0x22df')]?_0x3c43b3['userProfileSection']['crudPermissions']:null),_0x3c43b3['hasModulePermissions']={},_0x3c43b3[_0xf5e42e('0x517')]=_0xc93e41[_0xf5e42e('0x7f2')][_0xf5e42e('0x1904')]||0x0,_0x3c43b3[_0xf5e42e('0x1a9f')]=_0x2c1998,_0x3c43b3['agentadddialog']=_0x96180c,_0x3c43b3[_0xf5e42e('0x2430')]=_0x2ad49f[_0xf5e42e('0x2289')],_0x3c43b3[_0xf5e42e('0x1cf2')]=_0x6355d6,_0x3c43b3[_0xf5e42e('0x279f')]=_0x3085fd;function _0x2c1998(_0x4cd92a){const _0xb06bf7=_0xf5e42e;if(_0x188901[_0xb06bf7('0xca1')]('admin'))_0xc93e41['go']('app.contactmanager.contacts',{'ListId':_0x4cd92a['id']});else return _0x195e21['userProfileSection'][_0xb06bf7('0x1e6e')]({'userProfileId':_0x188901['getCurrentUser']()[_0xb06bf7('0x2f')],'sectionId':0x12f})[_0xb06bf7('0xe53')][_0xb06bf7('0x683')](function(_0x367636){const _0x3053de=_0xb06bf7,_0x5c3545=_0x367636&&_0x367636[_0x3053de('0xf5d')]?_0x367636[_0x3053de('0xf5d')][0x0]:null;_0x5c3545&&_0x5c3545[_0x3053de('0x1333')]?_0xc93e41['go'](_0x3053de('0x1e45'),{'ListId':_0x4cd92a['id']}):_0x2ad49f[_0x3053de('0x2289')]({'title':_0x4110a8['instant'](_0x3053de('0x213e')),'msg':_0x4110a8[_0x3053de('0x2728')](_0x3053de('0xdba'))});})[_0xb06bf7('0x130a')](function(_0x5159b8){const _0x5b20e7=_0xb06bf7;_0x2ad49f[_0x5b20e7('0x52a')]({'title':_0x5159b8['status']?_0x5b20e7('0x2168')+_0x5159b8[_0x5b20e7('0x13ee')]+_0x5b20e7('0xbf6')+_0x5159b8[_0x5b20e7('0x24a9')]:_0x5b20e7('0xf2a'),'msg':_0x5159b8[_0x5b20e7('0x13ee')]?JSON['stringify'](_0x5159b8[_0x5b20e7('0x5a5')]):_0x5159b8[_0x5b20e7('0x1ff0')]()});});}function _0x96180c(_0x383949,_0x4a76b4){const _0xe6c72b=_0xf5e42e;_0x28be5d[_0xe6c72b('0x1d4')]({'controller':_0xe6c72b('0x1b21'),'controllerAs':'vm','templateUrl':_0x2862e8,'parent':angular[_0xe6c72b('0x1fcc')](_0x4e4acc[_0xe6c72b('0x18e5')]),'targetEvent':_0x4a76b4,'clickOutsideToClose':!![],'locals':{'list':_0x383949,'lists':_0x3c43b3['lists']?_0x3c43b3[_0xe6c72b('0xe01')][_0xe6c72b('0xf5d')]:[],'crudPermissions':_0x3c43b3['crudPermissions'],'realtime':![]}});}function _0x6355d6(){const _0x124c30=_0xf5e42e;_0xc93e41['go'](_0x124c30('0x147b'),{},{'reload':_0x124c30('0x147b')});}function _0x3085fd(){const _0x399b67=_0xf5e42e;_0x195e21[_0x399b67('0x259b')][_0x399b67('0x2480')]({'id':_0x3c43b3['list']['id']},_0x3c43b3[_0x399b67('0x2335')])[_0x399b67('0xe53')][_0x399b67('0x683')](function(){const _0xe39c93=_0x399b67;_0x2ad49f[_0xe39c93('0x53')]({'title':_0xe39c93('0x3aa'),'msg':_0x3c43b3['list'][_0xe39c93('0x60a')]?_0x3c43b3[_0xe39c93('0x2335')][_0xe39c93('0x60a')]+_0xe39c93('0x96c'):''});})[_0x399b67('0x130a')](function(_0x2072de){const _0x1e3ea4=_0x399b67;_0x2ad49f[_0x1e3ea4('0x52a')]({'title':_0x2072de['status']?_0x1e3ea4('0x2168')+_0x2072de['status']+_0x1e3ea4('0xbf6')+_0x2072de[_0x1e3ea4('0x24a9')]:_0x1e3ea4('0x4a8'),'msg':_0x2072de[_0x1e3ea4('0x5a5')]?JSON[_0x1e3ea4('0x258a')](_0x2072de[_0x1e3ea4('0x5a5')]):_0x2072de[_0x1e3ea4('0x1ff0')]()});});}}const _0x37d0b3=_0x50c667,_0x32807f=_0x180212['p']+_0x189033('0x2054');_0x3f9b03['$inject']=[_0x189033('0x7a5'),'$window',_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x56b'),'toasty',_0x189033('0xba1')];function _0x3f9b03(_0x58ce58,_0x415eaa,_0x481de8,_0x558c31,_0x219330,_0x44b255,_0x3b3fd1,_0x3d0ca2,_0xe9a58,_0x446e97,_0x58129a){const _0x386b40=_0x189033,_0x38cf0e=this;_0x38cf0e[_0x386b40('0x11ed')]=_0x58129a['getCurrentUser'](),_0x38cf0e[_0x386b40('0x191e')]={'count':0x0,'rows':[]},_0x38cf0e['selectedDispositions']=[],_0x38cf0e[_0x386b40('0x1134')],_0x38cf0e[_0x386b40('0x1d01')]={'first':_0x386b40('0x1fd1'),'second':'2nd','third':'3rd'},_0x38cf0e['query']={'fields':'id,level,name,description,ParentId,createdAt,updatedAt','sort':_0x386b40('0xc36'),'limit':0xa,'page':0x1},_0x38cf0e['init']=_0x41f8a7,_0x38cf0e[_0x386b40('0x26eb')]=_0x26f08e,_0x38cf0e[_0x386b40('0x53')]=_0x961ca5,_0x38cf0e[_0x386b40('0x13d9')]=_0x50e047,_0x38cf0e[_0x386b40('0xe69')]=_0x1ed70c,_0x38cf0e['deleteDisposition']=_0x25df2f,_0x38cf0e[_0x386b40('0x224b')]=_0x31195d,_0x38cf0e['deleteSelectedDispositions']=_0x110093,_0x38cf0e['deselectDispositions']=_0x480e18,_0x38cf0e['selectAllDispositions']=_0x1d99ee;function _0x41f8a7(_0x373ed9,_0x1b77a4){const _0x492451=_0x386b40;_0x38cf0e[_0x492451('0x2335')]=_0x373ed9||{},_0x38cf0e[_0x492451('0x1134')]=typeof _0x1b77a4!=='undefined'?_0x1b77a4:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x38cf0e[_0x492451('0x23a2')][_0x492451('0x1e4f')]=_0x38cf0e[_0x492451('0x2335')]['id'],_0x38cf0e[_0x492451('0x23a2')]['id']=_0x38cf0e['list']['id'],_0x50e047();}function _0x1ed70c(_0x38eaca,_0x8330a8){const _0x152373=_0x386b40;_0x219330['show']({'controller':_0x152373('0x1ecc'),'controllerAs':'vm','templateUrl':_0x32807f,'parent':angular[_0x152373('0x1fcc')](_0x44b255[_0x152373('0x18e5')]),'targetEvent':_0x38eaca,'clickOutsideToClose':!![],'locals':{'disposition':_0x8330a8,'dispositions':_0x38cf0e[_0x152373('0x191e')]['rows'],'model':{'id':_0x38cf0e[_0x152373('0x2335')]['id'],'field':_0x152373('0x1e4f')},'license':null,'setting':null,'crudPermissions':_0x38cf0e[_0x152373('0x1134')]}})[_0x152373('0x683')](function(_0x4c6267){if(_0x4c6267)_0x50e047();});}function _0x26f08e(_0x2a27c0,_0x3965bc){const _0x1bd0f0=_0x386b40,_0x2f2968=_0x2e3ca0()[_0x1bd0f0('0x7a2')](_0x38cf0e[_0x1bd0f0('0x191e')][_0x1bd0f0('0xf5d')],[_0x1bd0f0('0x1b62'),_0x2a27c0['id']]),_0x18960e=_0x219330['confirm']()[_0x1bd0f0('0xf28')](_0x3d0ca2[_0x1bd0f0('0x2728')](_0x1bd0f0('0x15d8')))[_0x1bd0f0('0xa6a')](_0x3d0ca2['instant'](_0x1bd0f0('0x13bf')+(_0x2f2968?'DISPOSITION_DELETE_MESSAGE_CHILDREN':_0x1bd0f0('0x106')),{'name':_0x2a27c0[_0x1bd0f0('0x60a')]}))[_0x1bd0f0('0x1040')](_0x1bd0f0('0x550'))[_0x1bd0f0('0xe42')](_0x3965bc)['ok']('OK')[_0x1bd0f0('0x19fb')](_0x3d0ca2[_0x1bd0f0('0x2728')](_0x1bd0f0('0x9a1')));_0x219330['show'](_0x18960e)['then'](function(){_0x25df2f(_0x2a27c0);});}function _0x961ca5(_0x5d744e){const _0x33dd0e=_0x386b40;_0x38cf0e[_0x33dd0e('0x191e')]=_0x5d744e||{'count':0x0,'rows':[]};}function _0x50e047(){const _0x56a103=_0x386b40;_0x38cf0e[_0x56a103('0x23a2')][_0x56a103('0x1cc8')]=(_0x38cf0e['query']['page']-0x1)*_0x38cf0e['query'][_0x56a103('0x6f0')],_0x38cf0e[_0x56a103('0x1883')]=_0xe9a58[_0x56a103('0x259b')]['getDispositions'](_0x38cf0e[_0x56a103('0x23a2')],_0x961ca5)[_0x56a103('0xe53')];}function _0x25df2f(_0x4614ea){const _0x31a393=_0x386b40;_0xe9a58[_0x31a393('0x43f')]['delete']({'id':_0x4614ea['id']})[_0x31a393('0xe53')][_0x31a393('0x683')](function(){const _0x13556c=_0x31a393;_0x50e047(),_0x446e97['success']({'title':_0x3d0ca2[_0x13556c('0x2728')](_0x13556c('0x210b'))});})[_0x31a393('0x130a')](function(_0x2cd313){const _0x47a3e3=_0x31a393;if(_0x2cd313[_0x47a3e3('0x5a5')]&&_0x2cd313[_0x47a3e3('0x5a5')][_0x47a3e3('0x17f')]&&_0x2cd313[_0x47a3e3('0x5a5')][_0x47a3e3('0x17f')][_0x47a3e3('0x1564')]){_0x38cf0e[_0x47a3e3('0x17f')]=_0x2cd313['data'][_0x47a3e3('0x17f')]||[{'message':_0x2cd313[_0x47a3e3('0x1ff0')](),'type':_0x47a3e3('0x189b')}];for(let _0x4668c3=0x0;_0x4668c3<_0x2cd313[_0x47a3e3('0x5a5')][_0x47a3e3('0x17f')]['length'];_0x4668c3++){_0x446e97[_0x47a3e3('0x52a')]({'title':_0x2cd313['data']['errors'][_0x4668c3][_0x47a3e3('0xcf0')],'msg':_0x2cd313[_0x47a3e3('0x5a5')][_0x47a3e3('0x17f')][_0x4668c3][_0x47a3e3('0x8c2')]});}}else _0x446e97[_0x47a3e3('0x52a')]({'title':_0x2cd313[_0x47a3e3('0x13ee')]?_0x47a3e3('0x2168')+_0x2cd313[_0x47a3e3('0x13ee')]+_0x47a3e3('0xbf6')+_0x2cd313[_0x47a3e3('0x24a9')]:_0x47a3e3('0x189b'),'msg':_0x2cd313[_0x47a3e3('0x5a5')]?JSON[_0x47a3e3('0x258a')](_0x2cd313[_0x47a3e3('0x5a5')]['message']):_0x2cd313[_0x47a3e3('0x8c2')]||_0x2cd313[_0x47a3e3('0x1ff0')]()});});}function _0x31195d(){const _0x3bd386=_0x386b40,_0x29fb28=angular[_0x3bd386('0x1a86')](_0x38cf0e[_0x3bd386('0x17')]);return _0x38cf0e[_0x3bd386('0x17')]=[],_0x29fb28;}function _0x110093(_0x7b0de8){const _0x316f9a=_0x386b40,_0x812279=_0x219330[_0x316f9a('0x1c6f')]()[_0x316f9a('0xf28')](_0x3d0ca2['instant'](_0x316f9a('0xfa')))[_0x316f9a('0xa6a')](_0x3d0ca2[_0x316f9a('0x2728')](_0x316f9a('0x1ebe'),{'total':_0x38cf0e['selectedDispositions'][_0x316f9a('0x1564')]}))[_0x316f9a('0x1040')]('Delete\x20dispositions')[_0x316f9a('0xe42')](_0x7b0de8)['ok']('OK')[_0x316f9a('0x19fb')](_0x3d0ca2['instant']('TOOLS.CANCEL'));_0x219330[_0x316f9a('0x1d4')](_0x812279)[_0x316f9a('0x683')](function(){const _0x5eafd8=_0x316f9a;_0x38cf0e[_0x5eafd8('0x17')][_0x5eafd8('0x1299')](function(_0x966eb1){_0x25df2f(_0x966eb1);}),_0x38cf0e[_0x5eafd8('0x17')]=[];});}function _0x480e18(){_0x38cf0e['selectedDispositions']=[];}function _0x1d99ee(){const _0x454cad=_0x386b40;_0x38cf0e['selectedDispositions']=_0x38cf0e[_0x454cad('0x191e')][_0x454cad('0xf5d')];}let _0x5a3fed=!![],_0x133b14=0x1;_0x58ce58[_0x386b40('0x186d')](_0x386b40('0x229'),function(_0x574a7b,_0x33cea2){const _0x1cc651=_0x386b40;_0x5a3fed?_0x3b3fd1(function(){_0x5a3fed=![];}):(!_0x33cea2&&(_0x133b14=_0x38cf0e['query'][_0x1cc651('0xdf8')]),_0x574a7b!==_0x33cea2&&(_0x38cf0e[_0x1cc651('0x23a2')][_0x1cc651('0xdf8')]=0x1),!_0x574a7b&&(_0x38cf0e[_0x1cc651('0x23a2')][_0x1cc651('0xdf8')]=_0x133b14),_0x50e047());});}const _0x52fe84=_0x3f9b03,_0x5f6b92=_0x180212['p']+_0x189033('0xd97');_0x534a35[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0xe01'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x534a35(_0x28b599,_0xee2d88,_0x5d45b9,_0x5b0a0d,_0x54d827,_0x45df2d,_0x5c253a,_0x5a25bc,_0x6aa033,_0x5cda7b,_0x3c906b,_0x322e1b,_0x3a4b40,_0x455ba4,_0x577c03,_0x1b8f5b,_0x25d154){const _0x1e106c=_0x189033,_0x421641=this;_0x421641['license']=_0x1b8f5b,_0x421641['setting']=_0x25d154,_0x421641['currentUser']=_0x577c03['getCurrentUser'](),_0x421641[_0x1e106c('0xe01')]=_0x6aa033||{'count':0x0,'rows':[]},_0x421641[_0x1e106c('0x2a')]=_0x5cda7b,_0x421641[_0x1e106c('0x22df')]=_0x3c906b&&_0x3c906b[_0x1e106c('0x50d')]==0x1?_0x3c906b[_0x1e106c('0xf5d')][0x0]:null,_0x421641['crudPermissions']=_0x577c03[_0x1e106c('0x142a')](_0x421641[_0x1e106c('0x22df')]?_0x421641[_0x1e106c('0x22df')][_0x1e106c('0x1134')]:null),_0x421641[_0x1e106c('0x5c4')]=_0x1e106c('0xe01'),_0x421641[_0x1e106c('0x247')]='',_0x421641[_0x1e106c('0x1ce2')]=null,_0x421641[_0x1e106c('0x1b2e')]=[],_0x421641[_0x1e106c('0x23a2')]={'fields':_0x1e106c('0x9ff'),'sort':_0x1e106c('0xc36'),'limit':0xa,'page':0x1},_0x421641[_0x1e106c('0xc63')]=_0x5ac00a,_0x421641['gotocontactsgoto']=_0x5d53cc,_0x421641[_0x1e106c('0x6ef')]=_0xd8e171,_0x421641[_0x1e106c('0x2814')]=_0x41d676,_0x421641[_0x1e106c('0x194f')]=_0x198108,_0x421641[_0x1e106c('0x53')]=_0x16d5b0,_0x421641[_0x1e106c('0x16c3')]=_0x44bcc3,_0x421641['createOrEditList']=_0xe5238f,_0x421641[_0x1e106c('0x1cbd')]=_0x445fcc,_0x421641[_0x1e106c('0x3f1')]=_0x4fd84f,_0x421641[_0x1e106c('0x14b0')]=_0x18ccee,_0x421641['deselectLists']=_0x498da5,_0x421641[_0x1e106c('0x266c')]=_0x171e1d;function _0x5ac00a(_0x477d2e){const _0x383618=_0x1e106c;_0x5d45b9['go']('app.contactmanager.lists.edit',{'id':_0x477d2e['id'],'list':_0x477d2e,'crudPermissions':_0x421641[_0x383618('0x1134')]});}function _0x5d53cc(_0x233549){const _0x2f5b76=_0x1e106c;if(_0x577c03['hasRole'](_0x2f5b76('0x20c2')))_0x5d45b9['go']('app.contactmanager.contacts',{'ListId':_0x233549['id']});else return _0x322e1b[_0x2f5b76('0x22df')]['get']({'userProfileId':_0x577c03['getCurrentUser']()[_0x2f5b76('0x2f')],'sectionId':0x12f})[_0x2f5b76('0xe53')][_0x2f5b76('0x683')](function(_0x2c8b46){const _0x71baec=_0x2f5b76,_0x237002=_0x2c8b46&&_0x2c8b46[_0x71baec('0xf5d')]?_0x2c8b46[_0x71baec('0xf5d')][0x0]:null;_0x237002&&_0x237002[_0x71baec('0x1333')]?_0x5d45b9['go']('app.contactmanager.contacts',{'ListId':_0x233549['id']}):_0x455ba4[_0x71baec('0x2289')]({'title':_0x5a25bc[_0x71baec('0x2728')](_0x71baec('0x213e')),'msg':_0x5a25bc['instant'](_0x71baec('0xdba'))});})[_0x2f5b76('0x130a')](function(_0x5c94b6){const _0x5798c4=_0x2f5b76;_0x455ba4[_0x5798c4('0x52a')]({'title':_0x5c94b6[_0x5798c4('0x13ee')]?'API:'+_0x5c94b6[_0x5798c4('0x13ee')]+_0x5798c4('0xbf6')+_0x5c94b6[_0x5798c4('0x24a9')]:'USERPROFILE:GET_SECTION','msg':_0x5c94b6[_0x5798c4('0x13ee')]?JSON[_0x5798c4('0x258a')](_0x5c94b6[_0x5798c4('0x5a5')]):_0x5c94b6[_0x5798c4('0x1ff0')]()});});}function _0xd8e171(_0x36a413){const _0x108b87=_0x1e106c;return _0x322e1b[_0x108b87('0x259b')][_0x108b87('0x1903')]({'id':_0x36a413['id'],'nolimit':!![]})[_0x108b87('0xe53')][_0x108b87('0x683')](function(_0x1a5715){const _0x3f4d24=_0x108b87;if(typeof _0x1a5715[_0x3f4d24('0x1564')]!==_0x3f4d24('0x1867')){const _0x49a380=[_0x1a5715[_0x3f4d24('0x1fb3')]],_0xd7b4e5=new Blob(_0x49a380,{'type':_0x1a5715[_0x3f4d24('0xcf0')]}),_0x11f361=window[_0x3f4d24('0x12e1')][_0x3f4d24('0x1ffa')]('a');_0x11f361[_0x3f4d24('0x130f')]('href',URL[_0x3f4d24('0x2820')](_0xd7b4e5)),_0x11f361[_0x3f4d24('0x130f')](_0x3f4d24('0x18e8'),'exportContacts_'+_0x36a413['id']+_0x3f4d24('0x804')),_0x11f361['click']();}else _0x455ba4[_0x3f4d24('0x2289')]({'title':'EXPORT','msg':_0x3f4d24('0x2555')});})[_0x108b87('0x130a')](function(_0x37c833){const _0xd0a17c=_0x108b87;_0x455ba4[_0xd0a17c('0x52a')]({'title':_0x37c833[_0xd0a17c('0x13ee')]?_0xd0a17c('0x2168')+_0x37c833[_0xd0a17c('0x13ee')]+_0xd0a17c('0xbf6')+_0x37c833[_0xd0a17c('0x24a9')]:'SYSTEM:GETcmList','msg':_0x37c833[_0xd0a17c('0x5a5')]?JSON[_0xd0a17c('0x258a')](_0x37c833[_0xd0a17c('0x5a5')]):_0x37c833[_0xd0a17c('0x1ff0')]()});});}function _0x41d676(_0x23f819,_0x168afa){const _0x208255=_0x1e106c;_0x54d827[_0x208255('0x1d4')]({'controller':_0x208255('0x1b21'),'controllerAs':'vm','templateUrl':_0x2862e8,'parent':angular[_0x208255('0x1fcc')](_0x45df2d[_0x208255('0x18e5')]),'targetEvent':_0x168afa,'clickOutsideToClose':!![],'locals':{'list':_0x23f819,'lists':_0x421641[_0x208255('0xe01')]?_0x421641[_0x208255('0xe01')]['rows']:[],'crudPermissions':_0x421641['crudPermissions'],'realtime':![]}});}function _0x198108(_0x4e6da0,_0x56f3d1){const _0x55150f=_0x1e106c,_0x344f92=_0x54d827[_0x55150f('0x1c6f')]()[_0x55150f('0xf28')](_0x55150f('0x1b01')+_0x2e3ca0()[_0x55150f('0x1e03')](_0x55150f('0x2335'))+'?')[_0x55150f('0x26e3')](''+(_0x4e6da0[_0x55150f('0x60a')]||_0x55150f('0x2335'))+_0x55150f('0x20f1')+'\x20will\x20be\x20deleted.')[_0x55150f('0x1040')](_0x55150f('0x48b'))[_0x55150f('0xe42')](_0x56f3d1)['ok']('OK')[_0x55150f('0x19fb')](_0x55150f('0x16b8'));_0x54d827[_0x55150f('0x1d4')](_0x344f92)[_0x55150f('0x683')](function(){_0x445fcc(_0x4e6da0);},function(){const _0x4931fd=_0x55150f;console[_0x4931fd('0x1b2b')](_0x4931fd('0x16b8'));});}let _0x4d82ab=!![],_0x6a75e1=0x1;_0x28b599[_0x1e106c('0x186d')](_0x1e106c('0x1e1d'),function(_0x24976c,_0xe1669d){const _0x5ce59a=_0x1e106c;_0x4d82ab?_0x5c253a(function(){_0x4d82ab=![];}):(!_0xe1669d&&(_0x6a75e1=_0x421641[_0x5ce59a('0x23a2')]['page']),_0x24976c!==_0xe1669d&&(_0x421641['query'][_0x5ce59a('0xdf8')]=0x1),!_0x24976c&&(_0x421641[_0x5ce59a('0x23a2')]['page']=_0x6a75e1),_0x421641[_0x5ce59a('0x16c3')]());});function _0x16d5b0(_0x2a624d){_0x421641['lists']=_0x2a624d||{'count':0x0,'rows':[]};}function _0x44bcc3(){const _0xf20353=_0x1e106c;_0x421641[_0xf20353('0x23a2')]['offset']=(_0x421641[_0xf20353('0x23a2')][_0xf20353('0xdf8')]-0x1)*_0x421641['query'][_0xf20353('0x6f0')],_0x577c03[_0xf20353('0xca1')](_0xf20353('0x20c2'))?_0x421641[_0xf20353('0x1883')]=_0x322e1b[_0xf20353('0x259b')][_0xf20353('0x1e6e')](_0x421641[_0xf20353('0x23a2')],_0x16d5b0)[_0xf20353('0xe53')]:(_0x421641[_0xf20353('0x23a2')]['id']=_0x421641[_0xf20353('0x2a')]['id'],_0x421641[_0xf20353('0x23a2')][_0xf20353('0x1aa')]=_0xf20353('0x1114'),_0x421641[_0xf20353('0x1883')]=_0x322e1b[_0xf20353('0x2a')][_0xf20353('0x241d')](_0x421641['query'],_0x16d5b0)['$promise']);}function _0xe5238f(_0x3a618f,_0x5a195c){const _0x35e9de=_0x1e106c;_0x54d827[_0x35e9de('0x1d4')]({'controller':_0x35e9de('0x27a'),'controllerAs':'vm','templateUrl':_0x5f6b92,'parent':angular['element'](_0x45df2d[_0x35e9de('0x18e5')]),'targetEvent':_0x3a618f,'clickOutsideToClose':!![],'locals':{'list':_0x5a195c,'lists':_0x421641['lists'][_0x35e9de('0xf5d')],'license':_0x421641[_0x35e9de('0xace')],'setting':_0x421641[_0x35e9de('0x260a')],'crudPermissions':_0x421641[_0x35e9de('0x1134')]}});}function _0x445fcc(_0x4a9848){const _0xf042e8=_0x1e106c;_0x322e1b[_0xf042e8('0x259b')][_0xf042e8('0xd7e')]({'id':_0x4a9848['id']})[_0xf042e8('0xe53')][_0xf042e8('0x683')](function(){const _0x475ecb=_0xf042e8;_0x2e3ca0()[_0x475ecb('0x3ec')](_0x421641[_0x475ecb('0xe01')][_0x475ecb('0xf5d')],{'id':_0x4a9848['id']}),_0x421641[_0x475ecb('0xe01')][_0x475ecb('0x50d')]-=0x1,!_0x421641[_0x475ecb('0xe01')][_0x475ecb('0xf5d')][_0x475ecb('0x1564')]&&_0x421641[_0x475ecb('0x16c3')](),_0x455ba4[_0x475ecb('0x53')]({'title':_0x2e3ca0()[_0x475ecb('0x1e03')]('List')+'\x20deleted!','msg':_0x4a9848[_0x475ecb('0x60a')]?_0x4a9848[_0x475ecb('0x60a')]+_0x475ecb('0x194d'):''});})[_0xf042e8('0x130a')](function(_0x11704e){const _0x34e566=_0xf042e8;if(_0x11704e[_0x34e566('0x5a5')]&&_0x11704e[_0x34e566('0x5a5')]['errors']&&_0x11704e[_0x34e566('0x5a5')][_0x34e566('0x17f')][_0x34e566('0x1564')]){_0x421641[_0x34e566('0x17f')]=_0x11704e[_0x34e566('0x5a5')][_0x34e566('0x17f')]||[{'message':_0x11704e[_0x34e566('0x1ff0')](),'type':_0x34e566('0x1440')}];for(let _0x4a635b=0x0;_0x4a635b<_0x11704e[_0x34e566('0x5a5')][_0x34e566('0x17f')]['length'];_0x4a635b++){_0x455ba4[_0x34e566('0x52a')]({'title':_0x11704e[_0x34e566('0x5a5')][_0x34e566('0x17f')][_0x4a635b][_0x34e566('0xcf0')],'msg':_0x11704e['data']['errors'][_0x4a635b][_0x34e566('0x8c2')]});}}else _0x455ba4['error']({'title':_0x11704e[_0x34e566('0x13ee')]?_0x34e566('0x2168')+_0x11704e['status']+_0x34e566('0xbf6')+_0x11704e[_0x34e566('0x24a9')]:'SYSTEM:DELETEcmList','msg':_0x11704e[_0x34e566('0x5a5')]?JSON[_0x34e566('0x258a')](_0x11704e[_0x34e566('0x5a5')][_0x34e566('0x8c2')]):_0x11704e[_0x34e566('0x8c2')]||_0x11704e[_0x34e566('0x1ff0')]()});});}function _0x4fd84f(){const _0x43ef9=_0x1e106c,_0x48fa38=angular[_0x43ef9('0x1a86')](_0x421641[_0x43ef9('0x1b2e')]);return _0x421641[_0x43ef9('0x1b2e')]=[],_0x48fa38;}function _0x18ccee(_0x1c9bd6){const _0x3e2359=_0x1e106c,_0x34355a=_0x54d827[_0x3e2359('0x1c6f')]()[_0x3e2359('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20lists?')[_0x3e2359('0x26e3')](_0x3e2359('0xed5')+_0x421641['selectedLists'][_0x3e2359('0x1564')]+'\x20selected'+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x3e2359('0x2856'))['targetEvent'](_0x1c9bd6)['ok']('OK')[_0x3e2359('0x19fb')](_0x3e2359('0x16b8'));_0x54d827[_0x3e2359('0x1d4')](_0x34355a)[_0x3e2359('0x683')](function(){const _0x1d7d88=_0x3e2359;_0x421641[_0x1d7d88('0x1b2e')][_0x1d7d88('0x1299')](function(_0x3b187e){_0x445fcc(_0x3b187e);}),_0x421641[_0x1d7d88('0x1b2e')]=[];});}function _0x498da5(){const _0x2b72b2=_0x1e106c;_0x421641[_0x2b72b2('0x1b2e')]=[];}function _0x171e1d(){const _0x1abfbc=_0x1e106c;_0x421641[_0x1abfbc('0x1b2e')]=_0x421641['lists'][_0x1abfbc('0xf5d')];}}const _0x5efd56=_0x534a35,_0x369513=_0x180212['p']+_0x189033('0x19b8'),_0x73ec6e=_0x180212['p']+_0x189033('0x1fa1'),_0x16c8b3=_0x180212['p']+_0x189033('0x25c8'),_0x3e1c5f=_0x180212['p']+_0x189033('0xda4'),_0x29064e=_0x180212['p']+_0x189033('0x234a');_0x2ba7d9[_0x189033('0x14be')]=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x2ba7d9(_0x58d6fc,_0xe833){const _0x29babd=_0x189033;_0x58d6fc[_0x29babd('0x2598')](_0x29babd('0x1f51'),{'abstract':!![],'url':'/contactmanager'})['state']('app.contactmanager.lists',{'url':_0x29babd('0x222c'),'views':{'content@app':{'templateUrl':_0x369513,'controller':'ListsController\x20as\x20vm'}},'resolve':{'lists':['apiResolver','Auth',function(_0x393c38,_0x292e81){const _0x493366=_0x29babd;return _0x292e81[_0x493366('0xca1')](_0x493366('0x20c2'))?_0x393c38['resolve'](_0x493366('0xa7b'),{'fields':_0x493366('0x9ff'),'sort':_0x493366('0xc36'),'limit':0xa,'offset':0x0}):_0x393c38[_0x493366('0xed7')](_0x493366('0x191b'),{'id':_0x292e81[_0x493366('0x20b2')]()[_0x493366('0x2f')],'section':'Lists','fields':_0x493366('0x9ff'),'sort':_0x493366('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x29babd('0x4b1'),'Auth',function(_0x45a71a,_0x4c0e15){const _0x451265=_0x29babd;return _0x4c0e15['hasRole'](_0x451265('0x20c2'))?null:_0x45a71a[_0x451265('0xed7')](_0x451265('0x1464'),{'fields':_0x451265('0x16f'),'id':_0x4c0e15[_0x451265('0x20b2')]()[_0x451265('0x2f')]});}],'userProfileSection':[_0x29babd('0x4b1'),_0x29babd('0xba1'),function(_0x307894,_0x758104){const _0x42dc51=_0x29babd;return _0x758104[_0x42dc51('0xca1')]('admin')?null:_0x307894[_0x42dc51('0xed7')]('userProfileSection@get',{'fields':_0x42dc51('0x1f47'),'userProfileId':_0x758104[_0x42dc51('0x20b2')]()[_0x42dc51('0x2f')],'sectionId':0x12d});}]},'authenticate':!![],'permissionId':0x12d,'bodyClass':_0x29babd('0x22a2')})[_0x29babd('0x2598')](_0x29babd('0x243b'),{'url':_0x29babd('0x1560'),'params':{'list':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x73ec6e,'controller':_0x29babd('0x24ea')}},'resolve':{'list':['apiResolver',_0x29babd('0x8ea'),function(_0x278bfb,_0x2b7354){const _0x51e2f9=_0x29babd;return _0x278bfb[_0x51e2f9('0xed7')](_0x51e2f9('0xa7b'),{'fields':_0x51e2f9('0x9ff'),'id':_0x2b7354['id']});}],'userProfileSection':[_0x29babd('0x4b1'),_0x29babd('0xba1'),function(_0x11ff7a,_0x46197e){const _0x2c97dd=_0x29babd;return _0x11ff7a['resolve'](_0x2c97dd('0x360'),{'fields':_0x2c97dd('0x1f47'),'userProfileId':_0x46197e[_0x2c97dd('0x20b2')]()['userProfileId'],'sectionId':0x12d});}]},'authenticate':!![],'permissionId':0x12d,'bodyClass':_0x29babd('0x22a2')})[_0x29babd('0x2598')](_0x29babd('0x863'),{'url':_0x29babd('0x83f'),'views':{'content@app':{'templateUrl':_0x16c8b3,'controller':_0x29babd('0xb02')}},'resolve':{'companies':[_0x29babd('0x4b1'),'Auth',function(_0x127fc3,_0xfc7196){const _0x40ddca=_0x29babd;return _0xfc7196[_0x40ddca('0xca1')](_0x40ddca('0x20c2'))?_0x127fc3[_0x40ddca('0xed7')](_0x40ddca('0xdd0'),{'fields':_0x40ddca('0x596'),'sort':_0x40ddca('0xc36'),'limit':0xa,'offset':0x0}):_0x127fc3[_0x40ddca('0xed7')](_0x40ddca('0x191b'),{'id':_0xfc7196[_0x40ddca('0x20b2')]()['userProfileId'],'section':_0x40ddca('0x2229'),'fields':_0x40ddca('0x596'),'sort':_0x40ddca('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x29babd('0x4b1'),'Auth',function(_0x3f0fa4,_0x348055){const _0x50490f=_0x29babd;return _0x348055[_0x50490f('0xca1')](_0x50490f('0x20c2'))?null:_0x3f0fa4[_0x50490f('0xed7')](_0x50490f('0x1464'),{'fields':_0x50490f('0x16f'),'id':_0x348055[_0x50490f('0x20b2')]()[_0x50490f('0x2f')]});}],'userProfileSection':[_0x29babd('0x4b1'),_0x29babd('0xba1'),function(_0x4c1d0b,_0x44d463){const _0x5075b0=_0x29babd;return _0x44d463[_0x5075b0('0xca1')]('admin')?null:_0x4c1d0b[_0x5075b0('0xed7')](_0x5075b0('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x44d463[_0x5075b0('0x20b2')]()[_0x5075b0('0x2f')],'sectionId':0x12e});}]},'authenticate':!![],'permissionId':0x12e,'bodyClass':_0x29babd('0x22a2')})[_0x29babd('0x2598')](_0x29babd('0xae0'),{'url':'/:id?tab','params':{'company':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x3e1c5f,'controller':'CompanyController\x20as\x20vm'}},'resolve':{'company':['apiResolver',_0x29babd('0x8ea'),function(_0x35a63e,_0x203dfb){const _0x48202d=_0x29babd;return _0x35a63e['resolve'](_0x48202d('0xdd0'),{'fields':_0x48202d('0x596'),'id':_0x203dfb['id']});}],'userProfileSection':[_0x29babd('0x4b1'),_0x29babd('0xba1'),function(_0x3022e4,_0x47374b){const _0x130b3e=_0x29babd;return _0x3022e4['resolve'](_0x130b3e('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x47374b[_0x130b3e('0x20b2')]()[_0x130b3e('0x2f')],'sectionId':0x12e});}]},'authenticate':!![],'permissionId':0x12e,'bodyClass':_0x29babd('0x22a2')})['state'](_0x29babd('0x16da'),{'url':'/globalCustomFields','views':{'content@app':{'templateUrl':_0x29064e,'controller':'GlobalCustomFieldsController\x20as\x20vm'}},'resolve':{'globalCustomFields':[_0x29babd('0x4b1'),function(_0xf06168){const _0x2e052b=_0x29babd;return _0xf06168[_0x2e052b('0xed7')](_0x2e052b('0x1ca0'),{'fields':_0x2e052b('0x2684'),'sort':_0x2e052b('0xc36'),'ListId':_0x2e052b('0x13c'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x29babd('0xba1'),function(_0x582c05,_0x4be7f8){const _0x50be5a=_0x29babd;return _0x4be7f8[_0x50be5a('0xca1')](_0x50be5a('0x20c2'))?null:_0x582c05[_0x50be5a('0xed7')](_0x50be5a('0x1464'),{'fields':_0x50be5a('0x16f'),'id':_0x4be7f8[_0x50be5a('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x29babd('0x4b1'),_0x29babd('0xba1'),function(_0x342fa6,_0x1e397c){const _0x32a339=_0x29babd;return _0x1e397c[_0x32a339('0xca1')](_0x32a339('0x20c2'))?null:_0x342fa6[_0x32a339('0xed7')](_0x32a339('0x360'),{'fields':_0x32a339('0x1f47'),'userProfileId':_0x1e397c[_0x32a339('0x20b2')]()[_0x32a339('0x2f')],'sectionId':0x130});}]},'authenticate':!![],'permissionId':0x130,'bodyClass':_0x29babd('0x22a2')}),_0xe833[_0x29babd('0x7d2')](_0x29babd('0x8d4'));}angular[_0x189033('0x1e26')]('app.contactmanager',[_0x189033('0x6cf'),_0x189033('0x1ddb'),_0x189033('0x2290'),_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),_0x189033('0x2609'),'ngAnimate','mdPickers',_0x189033('0x516'),_0x189033('0x7fa'),_0x189033('0x197b'),_0x189033('0x3b5'),_0x189033('0x153a'),'ngEmbed',_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),'angular.filter',_0x189033('0x1e45')])[_0x189033('0x272d')](_0x2ba7d9)[_0x189033('0x1da3')]('CompaniesController',_0x472d25)[_0x189033('0x1da3')](_0x189033('0x2031'),_0x426211)['controller'](_0x189033('0x1ad0'),_0x4b52c9)[_0x189033('0x1da3')](_0x189033('0xba0'),_0xfb6d5c)[_0x189033('0x1da3')](_0x189033('0x20c5'),_0x2e53fc)['controller'](_0x189033('0x27a'),_0x69030f)['controller']('ListagentaddController',_0x2a8c2a)[_0x189033('0x1da3')](_0x189033('0x8d8'),_0x5390d6)['controller']('CreateOrEditCustomFieldDialogController',_0x26d570)[_0x189033('0x1da3')](_0x189033('0x12f4'),_0x37d0b3)[_0x189033('0x1da3')](_0x189033('0xb04'),_0x52fe84)[_0x189033('0x1da3')](_0x189033('0x24e7'),_0x5efd56),_0x138cb7[_0x189033('0x14be')]=['$scope',_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2063'),_0x189033('0x1d08'),_0x189033('0x56b'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1'),'socket','toasty',_0x189033('0x756'),_0x189033('0x191e')];function _0x138cb7(_0x2cb40a,_0x580815,_0x2bfaeb,_0xcd2266,_0x2cd3cf,_0x188002,_0x3ad3cb,_0x22664d,_0x1bb6c5,_0x42123f,_0x2aa6f4,_0x56e8b8,_0x444260,_0x17ecb1){const _0x585983=_0x189033,_0x57ab68=this;_0x57ab68[_0x585983('0x11ed')]=_0x42123f[_0x585983('0x20b2')](),_0x57ab68[_0x585983('0x756')]=_0x444260?_0x444260:[],_0x57ab68['dispositions']=_0x17ecb1,_0x57ab68[_0x585983('0x37b')]={'count':0x0,'rows':[]},_0x57ab68[_0x585983('0x12c2')]=![],_0x57ab68['refresh']=!![],_0x57ab68[_0x585983('0x2a')]=_0x22664d,_0x57ab68[_0x585983('0x22df')]=_0x1bb6c5&&_0x1bb6c5['count']==0x1?_0x1bb6c5[_0x585983('0xf5d')][0x0]:null,_0x57ab68[_0x585983('0x1134')]=_0x42123f['parseCrudPermissions'](_0x57ab68['userProfileSection']?_0x57ab68['userProfileSection'][_0x585983('0x1134')]:null),_0x57ab68[_0x585983('0x23a2')]={'fields':'id,type,calleridnum,calleridname,queue,queuecallerabandonAt,queuecallerexitAt,queuecallerexitreason,assigned,lastAssignedTo,updatedAt,disposition,secondDisposition,thirdDisposition','type':_0x585983('0x1535'),'queuecallerexitreason':_0x585983('0x498')+','+_0x585983('0x266d'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x57ab68[_0x585983('0x25bd')]=_0x1e3355,_0x57ab68[_0x585983('0x1897')]=_0xde952b,_0x57ab68['assignTo']=_0x3025c0,_0x57ab68['dispose']=_0x3fc37a,_0x57ab68['onSaveVoiceQueueReport']=_0x5b493e,_0x57ab68[_0x585983('0x2754')]=_0xdff6b0,_0x2aa6f4[_0x585983('0x5a3')](_0x585983('0x187'),_0x57ab68[_0x585983('0x372')]),_0x2aa6f4['on'](_0x585983('0x2660'),_0x57ab68[_0x585983('0x2754')]),_0x48f360();function _0x48f360(){const _0x37f905=_0x585983;let _0x70ef65=_0x2cd3cf[_0x37f905('0x120e')][_0x37f905('0x1b28')]('motion2.realtime.abandoned.voice.abandonedCalls:'+_0x57ab68[_0x37f905('0x11ed')]['id']);if(_0x70ef65)_0x70ef65=JSON[_0x37f905('0x1f34')](_0x70ef65),_0x70ef65&&_0x70ef65['query']&&(_0x57ab68[_0x37f905('0x23a2')]=_0x2e3ca0()[_0x37f905('0xf22')](_0x70ef65[_0x37f905('0x23a2')],_0x2e3ca0()[_0x37f905('0x8b5')](_0x57ab68[_0x37f905('0x23a2')],[_0x37f905('0x671'),'limit',_0x37f905('0xdf8')])),_0x57ab68[_0x37f905('0x23a2')]=_0x2e3ca0()[_0x37f905('0x8b5')](_0x57ab68['query'],_0x37f905('0x25')));else{const _0x5789f2={'$gte':_0x1aaf93()()['startOf'](_0x37f905('0x55b'))['utcOffset'](0x0,!![])['format'](),'$lte':_0x1aaf93()()[_0x37f905('0x3b3')](_0x37f905('0x55b'))[_0x37f905('0xb11')](0x0,!![])['format']()};_0x57ab68[_0x37f905('0x23a2')]['createdAt']=_0x5789f2;}_0x42123f[_0x37f905('0xca1')](_0x37f905('0x20c2'))?_0x3ad3cb[_0x37f905('0xc96')]['getQueues']({'id':_0x42123f[_0x37f905('0x20b2')]()['id'],'fields':_0x37f905('0xa10'),'channel':'voice','type':_0x37f905('0x1535'),'nolimit':!![]})[_0x37f905('0xe53')][_0x37f905('0x683')](function(_0x356248){const _0x3619a5=_0x37f905;_0x57ab68['queues']=_0x356248||{'count':0x0,'rows':[]},_0x57ab68['queuesMap']=_0x2e3ca0()[_0x3619a5('0x1cc9')](_0x2e3ca0()['keyBy'](_0x57ab68[_0x3619a5('0x2da')][_0x3619a5('0xf5d')],_0x3619a5('0x60a')),_0x3619a5('0x60a'));})['catch'](function(_0x41e8eb){console['error'](_0x41e8eb);})[_0x37f905('0x2874')](function(){const _0x55acee=_0x37f905;_0x57ab68[_0x55acee('0xc71')]=_0x5ec57d(),_0x57ab68[_0x55acee('0x25bd')]();}):_0x3ad3cb[_0x37f905('0x2a')]['getResources']({'id':_0x57ab68[_0x37f905('0x11ed')][_0x37f905('0x2f')],'section':_0x37f905('0x88d'),'channel':_0x37f905('0xcf2'),'type':_0x37f905('0x1535'),'sort':_0x37f905('0xc36'),'nolimit':!![]})[_0x37f905('0xe53')][_0x37f905('0x683')](function(_0x49920c){const _0x11a2b3=_0x37f905;_0x57ab68['queues']=_0x49920c||{'count':0x0,'rows':[]},_0x57ab68[_0x11a2b3('0xc9a')]=_0x2e3ca0()[_0x11a2b3('0x1cc9')](_0x2e3ca0()['keyBy'](_0x57ab68[_0x11a2b3('0x2da')][_0x11a2b3('0xf5d')],'name'),'name');})[_0x37f905('0x130a')](function(_0x39ca5e){const _0x2f67f4=_0x37f905;console[_0x2f67f4('0x52a')](_0x39ca5e);})['finally'](function(){const _0xc9a8d4=_0x37f905;_0x57ab68[_0xc9a8d4('0xc71')]=_0x5ec57d(),_0x57ab68['getAbandonedCalls']();});}function _0x5ec57d(){const _0x2f84d0=_0x585983;return[{'name':_0x2f84d0('0x10c1'),'key':_0x2f84d0('0x1a4'),'type':_0x2f84d0('0x270e'),'label':_0x2f84d0('0x1006')},{'name':'Agent','key':_0x2f84d0('0x1825'),'type':'select','label':'DASHBOARDS.SELECT_AGENT','options':_0x57ab68[_0x2f84d0('0x756')][_0x2f84d0('0xf5d')],'customOptions':[{'value':_0x2f84d0('0x5eb'),'translate':_0x2f84d0('0x2608')},{'value':undefined,'translate':'DASHBOARDS.ALL'}]},{'name':_0x2f84d0('0x257b'),'key':_0x2f84d0('0x660'),'type':_0x2f84d0('0xf6c'),'label':'DASHBOARDS.SELECT_CAMPAIGN','options':_0x57ab68[_0x2f84d0('0x2da')][_0x2f84d0('0xf5d')]}];}function _0x1e3355(){const _0xed1a69=_0x585983;_0x57ab68[_0xed1a69('0x7b2')]=![],_0x57ab68['queues']['count']>0x0?(_0x57ab68[_0xed1a69('0x23a2')][_0xed1a69('0x660')]=_0x57ab68[_0xed1a69('0x2da')][_0xed1a69('0x50d')]===0x1?_0x57ab68['queues'][_0xed1a69('0xf5d')][0x0]['name']:_0x57ab68[_0xed1a69('0x23a2')][_0xed1a69('0x660')],_0x57ab68[_0xed1a69('0x23a2')][_0xed1a69('0x1cc8')]=(_0x57ab68[_0xed1a69('0x23a2')]['page']-0x1)*_0x57ab68[_0xed1a69('0x23a2')][_0xed1a69('0x6f0')],_0x2cd3cf[_0xed1a69('0x120e')][_0xed1a69('0x15d')](_0xed1a69('0x255f')+_0x57ab68[_0xed1a69('0x11ed')]['id'],JSON[_0xed1a69('0x258a')]({'query':_0x2e3ca0()[_0xed1a69('0x8b5')](_0x57ab68[_0xed1a69('0x23a2')],_0xed1a69('0x660'))})),_0x57ab68['promise']=_0x3ad3cb[_0xed1a69('0x243')][_0xed1a69('0x267a')](_0x57ab68[_0xed1a69('0x23a2')],_0x3aead6)[_0xed1a69('0xe53')]):_0x3aead6(null);}function _0x3aead6(_0x26a560){const _0x52c108=_0x585983;_0x57ab68[_0x52c108('0x37b')]=_0x26a560||{'count':0x0,'rows':[]},_0x57ab68['refresh']=!![];}function _0xde952b(){const _0x2373e1=_0x585983;_0x57ab68['showTooltip']=![],_0x57ab68[_0x2373e1('0x25bd')]();}function _0x5b493e(_0x540b4e){const _0x17f663=_0x585983,_0x2932e9=_0x17f663('0x1535');_0x540b4e&&_0x57ab68[_0x17f663('0xc9a')]&&_0x57ab68[_0x17f663('0x23a2')]['type']===_0x2932e9&&_0x57ab68[_0x17f663('0xc9a')][_0x540b4e['queue']]&&(_0x57ab68[_0x17f663('0x12c2')]=!![]);}function _0xdff6b0(_0x420413){const _0x38c89b=_0x585983;if(_0x420413){const _0x3f641b=_0x2e3ca0()['findIndex'](_0x57ab68['abandonedCalls']['rows'],['id',_0x420413['id']]);_0x3f641b>=0x0&&_0x2e3ca0()[_0x38c89b('0xf22')](_0x57ab68[_0x38c89b('0x37b')][_0x38c89b('0xf5d')][_0x3f641b],_0x420413);}}function _0x3025c0(_0x340b18,_0x514f83){const _0x4db970=_0x585983;_0x340b18&&_0x3ad3cb['voiceQueueReport']['update']({'id':_0x340b18['id'],'lastAssignedTo':_0x514f83?_0x514f83['name']:null,'assigned':_0x514f83?!![]:![]})[_0x4db970('0xe53')]['catch'](function(_0x31b36d){const _0x124318=_0x4db970;console[_0x124318('0x1b2b')](_0x31b36d);});}function _0x3fc37a(_0x3a6be8){const _0xdc5a81=_0x585983;_0x2bfaeb[_0xdc5a81('0x1d4')]({'controller':_0xdc5a81('0x233c'),'controllerAs':'vm','templateUrl':_0xdc5a81('0x9dc'),'parent':angular[_0xdc5a81('0x1fcc')](_0xcd2266[_0xdc5a81('0x18e5')]),'targetEvent':_0x3a6be8,'resolve':{'globalDispositions':[_0xdc5a81('0x4b1'),function(_0x57f456){const _0x4137ee=_0xdc5a81;return _0x57f456[_0x4137ee('0xed7')]('disposition@get',{'MailAccountId':_0x4137ee('0x13c'),'FaxAccountId':_0x4137ee('0x13c'),'SmsAccountId':'null','WhatsappAccountId':_0x4137ee('0x13c'),'OpenchannelAccountId':_0x4137ee('0x13c'),'ChatWebsiteId':_0x4137ee('0x13c'),'ListId':'null'});}]},'locals':{'dispositions':_0x57ab68[_0xdc5a81('0x191e')],'call':_0x3a6be8}})[_0xdc5a81('0x683')](function(_0x530faa){const _0x34392d=_0xdc5a81;if(_0x530faa){const _0xa731aa={'id':_0x3a6be8['id'],'disposition':_0x530faa[_0x34392d('0xdc8')]||null,'secondDisposition':_0x530faa[_0x34392d('0x53b')]||null,'thirdDisposition':_0x530faa[_0x34392d('0x176')]||null};_0x3ad3cb[_0x34392d('0x243')][_0x34392d('0x2480')](_0xa731aa)[_0x34392d('0xe53')][_0x34392d('0x130a')](function(_0xb11c15){const _0x1a9837=_0x34392d;console[_0x1a9837('0x1b2b')](_0xb11c15);});}});}let _0x34d7fc=!![],_0x508953=0x1;_0x2cb40a[_0x585983('0x186d')](_0x585983('0x1e1d'),function(_0x35b56e,_0x58b627){const _0xaaac71=_0x585983;_0x34d7fc?_0x580815(function(){_0x34d7fc=![];}):(!_0x58b627&&(_0x508953=_0x57ab68[_0xaaac71('0x23a2')][_0xaaac71('0xdf8')]),_0x35b56e!==_0x58b627&&(_0x57ab68[_0xaaac71('0x23a2')][_0xaaac71('0xdf8')]=0x1),!_0x35b56e&&(_0x57ab68[_0xaaac71('0x23a2')][_0xaaac71('0xdf8')]=_0x508953),_0x57ab68[_0xaaac71('0x25bd')]());}),_0x2cb40a['$on'](_0x585983('0x4b8'),function(){const _0x223fc7=_0x585983;_0x2aa6f4[_0x223fc7('0x1b9e')](_0x223fc7('0x187')),_0x2aa6f4['removeAllListeners'](_0x223fc7('0x2660'));});}const _0x388522=_0x138cb7;_0x113c1e[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$q',_0x189033('0x2f9'),'$mdDialog','$document',_0x189033('0x241e'),_0x189033('0x22ab'),_0x189033('0x756'),_0x189033('0x127b'),'api','socket',_0x189033('0x1d70'),_0x189033('0xa72'),_0x189033('0x2a'),_0x189033('0x22df'),'Auth',_0x189033('0xace'),'$interval'];function _0x113c1e(_0x2446ae,_0x10eced,_0x32f7b8,_0x1e113c,_0x416d88,_0x247edb,_0x1292e3,_0x4710ce,_0xe5eb1b,_0x3d81ce,_0x22f086,_0x2e6a9a,_0xe6e368,_0x1c427a,_0x2fc93b,_0x5f5cb0,_0x4043dc,_0x22cc0a){const _0x243392=_0x189033,_0xe9fce6=this,_0x5e22f4=[_0x243392('0xef9'),_0x243392('0x2309'),_0x243392('0x10f'),'lastPauseAt','pauseType',_0x243392('0x8cc'),_0x243392('0x1d43'),_0x243392('0x2050'),'chatPause',_0x243392('0x1a11'),_0x243392('0x774'),'smsPause',_0x243392('0x185d'),_0x243392('0x716'),_0x243392('0x1431'),'chatCapacity',_0x243392('0x218'),'mailCapacity',_0x243392('0x205'),'whatsappCapacity','faxCapacity',_0x243392('0x153b'),_0x243392('0x1f9b'),_0x243392('0x15c1'),'smsCurrentCapacity',_0x243392('0xaba'),'faxCurrentCapacity','chatStatus',_0x243392('0x2a8'),_0x243392('0xb90'),'smsStatus',_0x243392('0x2512'),_0x243392('0x278b'),_0x243392('0x15e0'),_0x243392('0x1a03'),'openchannelStatusTime',_0x243392('0xc07'),_0x243392('0x1a70'),_0x243392('0x17c2'),'faxStatusTime',_0x243392('0x23b4'),_0x243392('0x660'),_0x243392('0x10f5'),_0x243392('0xd70'),_0x243392('0xa31'),'phoneBarEnableAutomaticScreenRecording'],_0x257895=[_0x243392('0x1938'),'openchannelPause',_0x243392('0x774'),_0x243392('0x1b89'),_0x243392('0x185d'),_0x243392('0x716'),_0x243392('0x1431'),_0x243392('0x2309')];_0xe9fce6['currentUser']=_0x5f5cb0[_0x243392('0x20b2')](),_0xe9fce6[_0x243392('0x24d2')]=[_0x243392('0x2727'),'inuse',_0x243392('0x63'),_0x243392('0x1026'),_0x243392('0x79')],_0xe9fce6[_0x243392('0x22ab')]=_0x1292e3||{'count':0x0,'rows':[]},_0xe9fce6[_0x243392('0xace')]=_0x4043dc,_0xe9fce6[_0x243392('0x2a')]=_0x1c427a,_0xe9fce6[_0x243392('0x22df')]=_0x2fc93b&&_0x2fc93b[_0x243392('0x50d')]==0x1?_0x2fc93b[_0x243392('0xf5d')][0x0]:null,_0xe9fce6[_0x243392('0x1134')]=_0x5f5cb0['parseCrudPermissions'](_0xe9fce6['userProfileSection']?_0xe9fce6['userProfileSection']['crudPermissions']:null),_0xe9fce6[_0x243392('0x756')]=_0x4710ce?_0x2e3ca0()['keyBy'](_0x4710ce[_0x243392('0xf5d')]?_0x4710ce['rows']:[],'id'):{},_0xe9fce6[_0x243392('0x127b')]=_0xe5eb1b?_0x2e3ca0()[_0x243392('0x24db')](_0xe5eb1b['rows']?_0xe5eb1b['rows']:[],'id'):{},_0xe9fce6['paginatedAgents']={},_0xe9fce6[_0x243392('0x182c')]=![],_0xe9fce6[_0x243392('0x150d')]=[],_0xe9fce6[_0x243392('0x7c6')]={};for(const _0x54f2b3 in _0xe9fce6['agents']){typeof _0xe9fce6[_0x243392('0x756')][_0x54f2b3]!==_0x243392('0x1867')&&(_0xe9fce6[_0x243392('0x756')][_0x54f2b3][_0x243392('0x12f3')]=!![]);}_0xe9fce6[_0x243392('0x23a2')]={'limit':0xa,'page':0x1,'order':'fullname','globalStatusFilter':'','pauseTypeFilter':''},_0xe9fce6[_0x243392('0x1999')]=_0xdd06d4,_0xe9fce6[_0x243392('0x1880')]=_0x48038f,_0xe9fce6['pause']=_0x300ceb,_0xe9fce6[_0x243392('0x70e')]=_0x4255fa,_0xe9fce6[_0x243392('0x411')]=_0x409a3f,_0xe9fce6['getAgentStatus']=_0x1a7940,_0xe9fce6[_0x243392('0x1bf4')]=_0x5126dc,_0xe9fce6['isPause']=_0x588a63,_0xe9fce6[_0x243392('0x2678')]=_0x51e166,_0xe9fce6['isPartialPause']=_0x21e979,_0xe9fce6[_0x243392('0x2819')]=_0x4fccf6,_0xe9fce6[_0x243392('0x1418')]=_0x574205,_0xe9fce6[_0x243392('0x1dd2')]=_0x26f0a8,_0xe9fce6['onConnect']=_0x43cd8b,_0xe9fce6[_0x243392('0x2250')]=_0x56dcbf,_0xe9fce6[_0x243392('0x1f6c')]=_0xe59573,_0x22f086['on'](_0x243392('0x18f0'),_0xe9fce6[_0x243392('0x2819')]),_0x22f086['on'](_0x243392('0x2719'),_0xe9fce6[_0x243392('0x1418')]),_0x22f086['on'](_0x243392('0x216d'),_0xe9fce6['onConnect']),_0x22f086['on'](_0x243392('0x3b6'),_0xe9fce6[_0x243392('0x2250')]),_0x26f0a8();let _0xad7be2=_0x22cc0a(function(){const _0x6fd659=_0x243392;_0xe9fce6[_0x6fd659('0x182c')]&&(_0xe9fce6['load']=![],_0x26f0a8());},0x3e7);function _0x26f0a8(){const _0x4ac6d1=_0x243392;_0xe9fce6[_0x4ac6d1('0x182c')]=![];const _0x3bf743=_0x10eced['defer']();_0xe9fce6[_0x4ac6d1('0x1883')]=_0x3bf743[_0x4ac6d1('0x1883')],_0xe9fce6[_0x4ac6d1('0xdf9')]=[],_0xe9fce6[_0x4ac6d1('0x150d')]=[],_0x2e3ca0()[_0x4ac6d1('0x15d0')](_0xe9fce6['agents'],function(_0x22d0eb,_0x50e155){const _0xc6ab34=_0x4ac6d1;_0xe9fce6[_0xc6ab34('0x127b')][_0x50e155]&&_0x2e3ca0()[_0xc6ab34('0xf22')](_0x22d0eb,_0x2e3ca0()[_0xc6ab34('0x24d0')](_0x2e3ca0()[_0xc6ab34('0x8b5')](_0xe9fce6[_0xc6ab34('0x127b')][_0x50e155],_0x257895),_0x5e22f4)),_0x5126dc(_0x22d0eb),_0x22d0eb[_0xc6ab34('0x2309')]?(_0xe9fce6[_0xc6ab34('0xdf9')][_0xc6ab34('0x1fd0')](_0x22d0eb),_0xe9fce6[_0xc6ab34('0x7c6')][_0x22d0eb['internal']]=_0x50e155):_0x22d0eb[_0xc6ab34('0x24d')]=_0x2e3ca0()[_0xc6ab34('0xea3')](_0x1aaf93()()[_0xc6ab34('0x26dd')]('x'));});_0xe9fce6[_0x4ac6d1('0x23a2')][_0x4ac6d1('0x1102')]&&_0x2e3ca0()[_0x4ac6d1('0x3ec')](_0xe9fce6[_0x4ac6d1('0xdf9')],function(_0x3b02f5){const _0x334df6=_0x4ac6d1;return _0x3b02f5[_0x334df6('0x12fa')]!==_0xe9fce6[_0x334df6('0x23a2')]['globalStatusFilter'];});_0xe9fce6[_0x4ac6d1('0x23a2')][_0x4ac6d1('0x1606')]&&_0x2e3ca0()[_0x4ac6d1('0x3ec')](_0xe9fce6[_0x4ac6d1('0xdf9')],function(_0x155021){const _0x500a83=_0x4ac6d1;return _0x155021[_0x500a83('0x17fe')]!==_0xe9fce6[_0x500a83('0x23a2')][_0x500a83('0x1606')];});_0xe9fce6['query'][_0x4ac6d1('0x25')]&&_0x2e3ca0()[_0x4ac6d1('0x3ec')](_0xe9fce6['filteredAgents'],function(_0x229b21){const _0x499bb7=_0x4ac6d1;return _0x229b21[_0x499bb7('0x11bc')][_0x499bb7('0x93a')]()[_0x499bb7('0x824')](_0xe9fce6[_0x499bb7('0x23a2')][_0x499bb7('0x25')][_0x499bb7('0x93a')]())<0x0;});_0xe9fce6['filteredAgents']=_0x4034e4(_0xe9fce6[_0x4ac6d1('0xdf9')]);const _0x3a210b=(_0xe9fce6['query'][_0x4ac6d1('0xdf8')]-0x1)*_0xe9fce6[_0x4ac6d1('0x23a2')]['limit'];_0xe9fce6[_0x4ac6d1('0x20d5')]=_0x2e3ca0()[_0x4ac6d1('0x16b7')](_0xe9fce6[_0x4ac6d1('0xdf9')],_0x3a210b)['slice'](0x0,_0xe9fce6[_0x4ac6d1('0x23a2')][_0x4ac6d1('0x6f0')]);for(let _0x2fb889=0x0;_0x2fb889<_0xe9fce6[_0x4ac6d1('0x20d5')][_0x4ac6d1('0x1564')];_0x2fb889+=0x1){_0xe9fce6[_0x4ac6d1('0x150d')][_0x4ac6d1('0x1fd0')](_0xe9fce6[_0x4ac6d1('0x20d5')][_0x2fb889]['id']);}_0x3bf743[_0x4ac6d1('0xed7')](),_0xe9fce6['load']=!![];}function _0x4fccf6(_0x5094a6){const _0x1f90bf=_0x243392;_0xe9fce6[_0x1f90bf('0x756')][_0x5094a6['id']]&&(_0x2e3ca0()[_0x1f90bf('0xf22')](_0xe9fce6[_0x1f90bf('0x756')][_0x5094a6['id']],_0x2e3ca0()['pick'](_0x2e3ca0()[_0x1f90bf('0x8b5')](_0x5094a6,_0x257895),_0x5e22f4)),_0x2e3ca0()['merge'](_0xe9fce6[_0x1f90bf('0x127b')][_0x5094a6['id']],_0x2e3ca0()[_0x1f90bf('0x24d0')](_0x2e3ca0()[_0x1f90bf('0x8b5')](_0x5094a6,_0x257895),_0x5e22f4)),_0x5126dc(_0xe9fce6[_0x1f90bf('0x756')][_0x5094a6['id']]));}function _0x574205(_0x585ff1){const _0x7b36f4=_0x243392;_0xe9fce6['agents'][_0x585ff1['id']]&&(_0x2e3ca0()[_0x7b36f4('0xf22')](_0xe9fce6[_0x7b36f4('0x756')][_0x585ff1['id']],_0x2e3ca0()[_0x7b36f4('0x24d0')](_0x585ff1,_0x5e22f4)),_0x2e3ca0()['merge'](_0xe9fce6[_0x7b36f4('0x127b')][_0x585ff1['id']],_0x2e3ca0()[_0x7b36f4('0x24d0')](_0x585ff1,_0x5e22f4)),_0x585ff1['lastPauseAt']&&(_0xe9fce6[_0x7b36f4('0x756')][_0x585ff1['id']][_0x7b36f4('0x24d')]=_0x585ff1[_0x7b36f4('0x8cc')],_0xe9fce6[_0x7b36f4('0x127b')][_0x585ff1['id']][_0x7b36f4('0x24d')]=_0x585ff1['lastPauseAt']),_0x5126dc(_0xe9fce6[_0x7b36f4('0x756')][_0x585ff1['id']]));}function _0x43cd8b(_0x12c363){const _0x1c1768=_0x243392;_0xe9fce6[_0x1c1768('0x756')][_0xe9fce6[_0x1c1768('0x7c6')][_0x12c363['destaccountcode']]]&&(_0x2e3ca0()[_0x1c1768('0xf22')](_0xe9fce6[_0x1c1768('0x756')][_0xe9fce6[_0x1c1768('0x7c6')][_0x12c363[_0x1c1768('0x1d79')]]],_0x2e3ca0()[_0x1c1768('0x24d0')](_0x12c363,[_0x1c1768('0x660'),'destconnectedlinenum'])),_0x2e3ca0()[_0x1c1768('0xf22')](_0xe9fce6['rpcAgents'][_0xe9fce6[_0x1c1768('0x7c6')][_0x12c363[_0x1c1768('0x1d79')]]],_0x2e3ca0()[_0x1c1768('0x24d0')](_0x12c363,['queue','destconnectedlinenum'])));}function _0x56dcbf(_0x432392){const _0xe3e2f8=_0x243392;_0xe9fce6[_0xe3e2f8('0x756')][_0xe9fce6['agentInternal'][_0x432392[_0xe3e2f8('0x1d79')]]]&&(_0xe9fce6['agents'][_0xe9fce6[_0xe3e2f8('0x7c6')][_0x432392['destaccountcode']]]=_0x2e3ca0()[_0xe3e2f8('0x8b5')](_0xe9fce6['agents'][_0xe9fce6['agentInternal'][_0x432392[_0xe3e2f8('0x1d79')]]],[_0xe3e2f8('0x660'),_0xe3e2f8('0x10f5')]),_0xe9fce6[_0xe3e2f8('0x127b')][_0xe9fce6[_0xe3e2f8('0x7c6')][_0x432392[_0xe3e2f8('0x1d79')]]]=_0x2e3ca0()[_0xe3e2f8('0x8b5')](_0xe9fce6[_0xe3e2f8('0x127b')][_0xe9fce6[_0xe3e2f8('0x7c6')][_0x432392['destaccountcode']]],[_0xe3e2f8('0x660'),_0xe3e2f8('0x10f5')]));}function _0xdd06d4(_0x5e618e){const _0x1c018c=_0x243392;return _0x3d81ce[_0x1c018c('0xc96')][_0x1c018c('0x1999')]({'id':_0x5e618e['id'],'device':_0x1c018c('0x2c9'),'agent_id':_0x5e618e['id'],'agent_name':_0x5e618e[_0x1c018c('0x60a')]})[_0x1c018c('0xe53')][_0x1c018c('0x683')](function(){const _0x325fea=_0x1c018c;_0x2e6a9a['success']({'title':_0x325fea('0x1683'),'msg':_0x5e618e['fullname']+'\x20\x20properly\x20logout'}),_0xe9fce6['agents'][_0x5e618e['id']]&&(_0xe9fce6[_0x325fea('0x756')][_0x5e618e['id']][_0x325fea('0x2309')]=![]),_0xe9fce6[_0x325fea('0x127b')][_0x5e618e['id']]&&(_0xe9fce6[_0x325fea('0x127b')][_0x5e618e['id']][_0x325fea('0x2309')]=![]),_0x26f0a8();})[_0x1c018c('0x130a')](function(_0x2b5c0d){const _0x143422=_0x1c018c;_0x2e6a9a[_0x143422('0x52a')]({'title':_0x2b5c0d[_0x143422('0x13ee')]?_0x143422('0x2168')+_0x2b5c0d[_0x143422('0x13ee')]+_0x143422('0xbf6')+_0x2b5c0d[_0x143422('0x24a9')]:'api.staff.save','msg':_0x2b5c0d[_0x143422('0x5a5')]?JSON[_0x143422('0x258a')](_0x2b5c0d[_0x143422('0x5a5')][_0x143422('0x8c2')]):_0x2b5c0d[_0x143422('0x1ff0')]()});});}function _0x300ceb(_0x4041af,_0x396e19){const _0x4ac099=_0x243392;return _0x3d81ce[_0x4ac099('0xc96')][_0x4ac099('0xa4')]({'id':_0x4041af['id'],'type':_0x396e19})[_0x4ac099('0xe53')][_0x4ac099('0x683')](function(_0x43ad28){const _0x481066=_0x4ac099;_0xe9fce6['agents'][_0x4041af['id']]&&_0x2e3ca0()[_0x481066('0xf22')](_0xe9fce6['agents'][_0x4041af['id']],_0x2e3ca0()[_0x481066('0x24d0')](_0x43ad28,_0x5e22f4)),_0xe9fce6[_0x481066('0x127b')][_0x4041af['id']]&&_0x2e3ca0()[_0x481066('0xf22')](_0xe9fce6[_0x481066('0x127b')][_0x4041af['id']],_0x2e3ca0()[_0x481066('0x24d0')](_0x43ad28,_0x5e22f4)),_0x5126dc(_0xe9fce6[_0x481066('0x756')][_0x4041af['id']]);})['catch'](function(_0x37c212){const _0x2ba871=_0x4ac099;_0x2e6a9a[_0x2ba871('0x52a')]({'title':_0x37c212[_0x2ba871('0x13ee')]?_0x2ba871('0x2168')+_0x37c212[_0x2ba871('0x13ee')]+_0x2ba871('0xbf6')+_0x37c212[_0x2ba871('0x24a9')]:_0x2ba871('0x154f'),'msg':_0x37c212[_0x2ba871('0x5a5')]?JSON[_0x2ba871('0x258a')](_0x37c212['data'][_0x2ba871('0x8c2')]):_0x37c212[_0x2ba871('0x1ff0')]()});});}function _0x4255fa(_0x33f9e9){const _0x127ef5=_0x243392;return _0x3d81ce[_0x127ef5('0xc96')][_0x127ef5('0x1778')]({'id':_0x33f9e9['id']})[_0x127ef5('0xe53')][_0x127ef5('0x683')](function(_0x4a0634){const _0x1f621c=_0x127ef5;_0xe9fce6['agents'][_0x33f9e9['id']]&&_0x2e3ca0()[_0x1f621c('0xf22')](_0xe9fce6[_0x1f621c('0x756')][_0x33f9e9['id']],_0x2e3ca0()[_0x1f621c('0x24d0')](_0x4a0634,_0x5e22f4)),_0xe9fce6[_0x1f621c('0x127b')][_0x33f9e9['id']]&&_0x2e3ca0()[_0x1f621c('0xf22')](_0xe9fce6[_0x1f621c('0x127b')][_0x33f9e9['id']],_0x2e3ca0()[_0x1f621c('0x24d0')](_0x4a0634,_0x5e22f4)),_0x5126dc(_0xe9fce6[_0x1f621c('0x756')][_0x33f9e9['id']]);})['catch'](function(_0x169957){const _0x3dbb92=_0x127ef5;_0x2e6a9a[_0x3dbb92('0x52a')]({'title':_0x169957['status']?_0x3dbb92('0x2168')+_0x169957[_0x3dbb92('0x13ee')]+'\x20-\x20'+_0x169957['statusText']:_0x3dbb92('0x154f'),'msg':_0x169957['data']?JSON[_0x3dbb92('0x258a')](_0x169957[_0x3dbb92('0x5a5')][_0x3dbb92('0x8c2')]):_0x169957[_0x3dbb92('0x1ff0')]()});});}function _0x409a3f(_0x31e9c0){const _0x28671e=_0x243392;_0x1e113c['show'](_0x1e113c[_0x28671e('0x2430')]()['clickOutsideToClose'](!![])['title']('Legend')[_0x28671e('0x26e3')]('
TODO\x20legend\x20status\x20+\x20state
')['ok']('Ok')[_0x28671e('0xe42')](_0x31e9c0));}function _0x48038f(_0x4ab743,_0x2a3ed6){const _0x46e42c=_0x243392;_0x1e113c[_0x46e42c('0x1d4')]({'controller':_0x46e42c('0x1e85'),'controllerAs':'vm','templateUrl':_0xf3687b,'parent':angular['element'](_0x416d88['body']),'targetEvent':_0x2a3ed6,'clickOutsideToClose':!![],'locals':{'agent':_0x4ab743,'agents':[],'channel':_0x46e42c('0xcf2'),'direction':_0x46e42c('0x1535'),'crudPermissions':_0xe9fce6[_0x46e42c('0x1134')]}});}function _0x588a63(_0x21aed4){return _0x21aed4==='pause'||_0x21aed4==='*pause';}function _0x51e166(_0xaa5472){const _0x174fad=_0x243392;return _0xaa5472===_0x174fad('0xa4');}function _0x21e979(_0x2bc263){const _0x295004=_0x243392;return _0x2bc263===_0x295004('0x651');}function _0x14b00c(_0x43ea2d){const _0x9015bc=_0x243392;return _0x43ea2d===_0x9015bc('0x1586')||_0x43ea2d===_0x9015bc('0xdd4')||_0x43ea2d===_0x9015bc('0x19d2')||_0x43ea2d==='ringing'||_0x2e3ca0()[_0x9015bc('0x8f2')](_0x43ea2d);}function _0x1a7940(_0x5da16e,_0x35b5a2){const _0x3e60fb=_0x243392;if(_0x35b5a2===_0x3e60fb('0xcf2')){if(_0x5da16e[_0x35b5a2+'Status']!==_0x3e60fb('0x1586'))return _0x5da16e[_0x35b5a2+_0x3e60fb('0x1d9d')];if(_0x5da16e[_0x35b5a2+'Pause'])return _0x5da16e[_0x35b5a2+'Status']=_0x3e60fb('0xa4'),_0x3e60fb('0xa4');return _0x3e60fb('0x1586');}else{if(_0x5da16e[_0x35b5a2+_0x3e60fb('0x2113')])return _0x5da16e[_0x35b5a2+'Status']=_0x3e60fb('0xa4'),_0x3e60fb('0xa4');return _0x5da16e[_0x35b5a2+_0x3e60fb('0x1d9d')];}}function _0x5126dc(_0x50a5c1){const _0xc3ff65=_0x243392;let _0x2483f0='unknown';if(_0x2e3ca0()[_0xc3ff65('0x161')]([_0x1a7940(_0x50a5c1,_0xc3ff65('0xcf2')),_0x1a7940(_0x50a5c1,_0xc3ff65('0x24e')),_0x1a7940(_0x50a5c1,_0xc3ff65('0x129f')),_0x1a7940(_0x50a5c1,'openchannel'),_0x1a7940(_0x50a5c1,_0xc3ff65('0x1285')),_0x1a7940(_0x50a5c1,_0xc3ff65('0x16e7')),_0x1a7940(_0x50a5c1,'fax')],_0x588a63))_0x2483f0='pause';else{if(_0x2e3ca0()[_0xc3ff65('0x7a2')]([_0x1a7940(_0x50a5c1,'voice'),_0x1a7940(_0x50a5c1,_0xc3ff65('0x24e')),_0x1a7940(_0x50a5c1,_0xc3ff65('0x129f')),_0x1a7940(_0x50a5c1,_0xc3ff65('0x1261')),_0x1a7940(_0x50a5c1,'sms'),_0x1a7940(_0x50a5c1,_0xc3ff65('0x16e7')),_0x1a7940(_0x50a5c1,_0xc3ff65('0x23e9'))],_0x588a63))_0x2483f0='*pause';else _0x2e3ca0()[_0xc3ff65('0x161')]([_0x1a7940(_0x50a5c1,_0xc3ff65('0xcf2')),_0x1a7940(_0x50a5c1,'chat'),_0x1a7940(_0x50a5c1,'mail'),_0x1a7940(_0x50a5c1,_0xc3ff65('0x1261')),_0x1a7940(_0x50a5c1,_0xc3ff65('0x1285')),_0x1a7940(_0x50a5c1,_0xc3ff65('0x16e7')),_0x1a7940(_0x50a5c1,_0xc3ff65('0x23e9'))],_0x14b00c)?_0x2483f0='idle':_0x2483f0=_0xc3ff65('0x63');}_0x50a5c1[_0xc3ff65('0x12fa')]!==_0x2483f0&&(_0x50a5c1['globalStatus']=_0x2483f0,_0x50a5c1[_0xc3ff65('0x12f3')]?(_0x50a5c1[_0xc3ff65('0x12f3')]=![],_0x50a5c1[_0xc3ff65('0x24d')]=_0x588a63(_0x2483f0)?_0x2e3ca0()[_0xc3ff65('0xea3')](_0x1aaf93()(_0x50a5c1[_0xc3ff65('0x8cc')])[_0xc3ff65('0x26dd')]('x')):_0x2e3ca0()[_0xc3ff65('0x69b')]([_0x50a5c1['voiceStatusTime'],_0x50a5c1[_0xc3ff65('0x1a03')],_0x50a5c1[_0xc3ff65('0xc07')],_0x50a5c1[_0xc3ff65('0x1a70')],_0x50a5c1[_0xc3ff65('0x17c2')],_0x50a5c1[_0xc3ff65('0x15db')],_0x50a5c1[_0xc3ff65('0x21d1')]])):_0x50a5c1[_0xc3ff65('0x24d')]=_0x2e3ca0()[_0xc3ff65('0xea3')](_0x1aaf93()()[_0xc3ff65('0x26dd')]('x')));}function _0x4034e4(_0x11372d){const _0x2346d9=_0x243392,_0x1faf95=_0x2e3ca0()['startsWith'](_0xe9fce6[_0x2346d9('0x23a2')][_0x2346d9('0x150d')],'-')?'desc':_0x2346d9('0xe38');return _0x2e3ca0()['orderBy'](_0x11372d,[_0xe9fce6[_0x2346d9('0x23a2')][_0x2346d9('0x150d')][_0x2346d9('0x1725')]('-','')],[_0x1faf95]);}function _0x1453da(){_0xad7be2&&(_0x22cc0a['cancel'](_0xad7be2),_0xad7be2=null);}function _0xe59573(_0x319741,_0x17311d){const _0x4d0b1e=_0x243392;return _0x3d81ce[_0x4d0b1e('0xc96')][_0x4d0b1e('0x2480')]({'id':_0x319741['id']},{'screenrecording':_0x17311d})[_0x4d0b1e('0xe53')][_0x4d0b1e('0x130a')](function(_0x1f0899){const _0x410d8a=_0x4d0b1e;_0x2e6a9a['error']({'title':_0x1f0899[_0x410d8a('0x13ee')]?_0x410d8a('0x2168')+_0x1f0899['status']+_0x410d8a('0xbf6')+_0x1f0899[_0x410d8a('0x24a9')]:_0x410d8a('0x162b'),'msg':_0x1f0899['data']?JSON['stringify'](_0x1f0899[_0x410d8a('0x5a5')]['message']):_0x1f0899['toString']()});});}_0x2446ae[_0x243392('0x26a2')]('$destroy',function(){const _0x15691f=_0x243392;_0x22f086[_0x15691f('0x1b9e')](_0x15691f('0x18f0')),_0x22f086[_0x15691f('0x1b9e')](_0x15691f('0x2719')),_0x22f086[_0x15691f('0x1b9e')](_0x15691f('0x216d')),_0x22f086[_0x15691f('0x1b9e')]('user:agentcomplete'),_0x1453da();});}const _0x2ee005=_0x113c1e;_0x33469c[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$timeout',_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1013'),_0x189033('0xa72')];function _0x33469c(_0x56f69d,_0xa432c0,_0x222ef2,_0x52d733,_0x3775e7,_0x2ab626){const _0x218922=_0x189033,_0x3405ce=this;_0x3405ce['calls']=_0x3775e7||{'rows':[],'count':0x0},_0x3405ce[_0x218922('0x23a2')]={'limit':0xa,'page':0x1},_0x3405ce[_0x218922('0x1c4c')]=_0x2ab626[_0x218922('0x16a2')],_0x52d733['on'](_0x218922('0x114f'),_0x3405ce[_0x218922('0x2819')]),_0x52d733['on']('voice_outbound_channel:remove',_0x3405ce[_0x218922('0x2136')]);function _0x501a09(_0x15831a){const _0x4820f3=_0x218922,_0x55c459=_0x2e3ca0()[_0x4820f3('0x1c07')](_0x3405ce[_0x4820f3('0x394')][_0x4820f3('0xf5d')],{'channel':_0x15831a[_0x4820f3('0xdd6')]});_0x15831a['channelstatedesc']=_0x15831a['dialstatus']?'up':'ring';if(_0x55c459)_0x2e3ca0()['merge'](_0x55c459,_0x15831a);else _0x15831a['channel']&&_0x3405ce[_0x4820f3('0x394')]['rows'][_0x4820f3('0x1fd0')](_0x15831a);}function _0x3fb9b2(_0x3ad640){const _0x451615=_0x218922,_0x3b1652=_0x2e3ca0()[_0x451615('0x1ce4')](_0x3405ce[_0x451615('0x394')]['rows'],{'channel':_0x3ad640[_0x451615('0xdd6')]});_0x3b1652>=0x0&&(_0x3405ce[_0x451615('0x394')][_0x451615('0xf5d')][_0x3b1652]['status']=_0x451615('0x1ba9')),_0xa432c0(function(){const _0x3cf7ed=_0x451615;_0x3405ce[_0x3cf7ed('0x394')][_0x3cf7ed('0xf5d')][_0x3cf7ed('0x2040')](_0x3b1652,0x1);},0x1388);}_0x56f69d[_0x218922('0x26a2')]('$destroy',function(){const _0x135e9e=_0x218922;_0x52d733[_0x135e9e('0x1b9e')](_0x135e9e('0x114f')),_0x52d733[_0x135e9e('0x1b9e')](_0x135e9e('0x1fc8'));}),_0x3405ce[_0x218922('0x2819')]=_0x501a09,_0x3405ce['onRemove']=_0x3fb9b2;}const _0xe33aee=_0x33469c;_0x23b3a0['$inject']=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x756'),_0x189033('0x2da'),_0x189033('0x203c'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0xa72'),_0x189033('0x1d70'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1')];function _0x23b3a0(_0x592aa9,_0x3f252f,_0x1215bb,_0x12976b,_0x1c8b26,_0x411020,_0x4f554c,_0x5b874d,_0x271faf,_0x478abb,_0x576f97,_0x55091b,_0x4c6b4c){const _0x1aaa4d=_0x189033,_0x2ac410=this;_0x2ac410[_0x1aaa4d('0x11ed')]=_0x4c6b4c['getCurrentUser'](),_0x2ac410['agents']=_0x12976b||{'count':0x0,'rows':[]},_0x2ac410[_0x1aaa4d('0x2da')]=_0x1c8b26?_0x2e3ca0()['keyBy'](_0x1c8b26[_0x1aaa4d('0xf5d')]?_0x1c8b26[_0x1aaa4d('0xf5d')]:[],_0x1aaa4d('0x60a')):{},_0x2ac410[_0x1aaa4d('0x2331')]=_0x411020?_0x2e3ca0()[_0x1aaa4d('0x24db')](_0x411020[_0x1aaa4d('0xf5d')]?_0x2e3ca0()[_0x1aaa4d('0x25')](_0x411020['rows'],{'type':_0x1aaa4d('0x1535')}):[],_0x1aaa4d('0x573')):{},_0x2ac410[_0x1aaa4d('0x203c')]={},_0x2ac410[_0x1aaa4d('0x2a')]=_0x576f97,_0x2ac410[_0x1aaa4d('0x22df')]=_0x55091b&&_0x55091b[_0x1aaa4d('0x50d')]==0x1?_0x55091b[_0x1aaa4d('0xf5d')][0x0]:null,_0x2ac410[_0x1aaa4d('0x1134')]=_0x4c6b4c[_0x1aaa4d('0x142a')](_0x2ac410[_0x1aaa4d('0x22df')]?_0x2ac410[_0x1aaa4d('0x22df')][_0x1aaa4d('0x1134')]:null),_0x2ac410[_0x1aaa4d('0xcd9')]={'limit':0xa,'page':0x1},_0x2ac410[_0x1aaa4d('0x2487')]=_0x34f972,_0x2ac410[_0x1aaa4d('0x3a8')]=_0x2675ec,_0x2ac410['onSave']=_0x5d92e7,_0x2ac410['onRemove']=_0x1eda60,_0x2ac410[_0x1aaa4d('0x1ba9')]=_0x3ad1ca,_0x2ac410['redirectToAgent']=_0x1f6ea0,_0x2ac410[_0x1aaa4d('0x18f5')]=_0x43dc77,_0x5b874d['on'](_0x1aaa4d('0x99f'),_0x2ac410['onSave']),_0x5b874d['on']('voice_queue_channel:remove',_0x2ac410[_0x1aaa4d('0x2136')]);function _0x34f972(_0x23e657){return _0x2e3ca0()['size'](_0x23e657);}function _0x2675ec(){const _0x2e5fe7=_0x1aaa4d;_0x2e3ca0()['forIn'](_0x2ac410[_0x2e5fe7('0x2331')],function(_0x357208,_0x4c712d){const _0x1269d4=_0x2e5fe7;_0x2e3ca0()[_0x1269d4('0x1c07')](_0x2ac410[_0x1269d4('0x2da')],{'name':_0x357208[_0x1269d4('0x60a')]})&&(_0x2ac410[_0x1269d4('0x203c')][_0x4c712d]=_0x357208);});}function _0x5d92e7(_0x5b1783){const _0x146a4f=_0x1aaa4d;_0x5b1783[_0x146a4f('0xcf0')]===_0x146a4f('0x1535')&&(_0x2e3ca0()[_0x146a4f('0x1c07')](_0x2ac410[_0x146a4f('0x2da')],{'name':_0x5b1783['name']})&&(_0x2ac410[_0x146a4f('0x203c')][_0x5b1783['uniqueid']]=_0x5b1783));}function _0x1eda60(_0x5f20bd){const _0x19be40=_0x1aaa4d;_0x2ac410[_0x19be40('0x203c')][_0x5f20bd[_0x19be40('0x573')]]&&delete _0x2ac410[_0x19be40('0x203c')][_0x5f20bd[_0x19be40('0x573')]];}function _0x3ad1ca(_0x2af388){const _0x4fccb3=_0x1aaa4d;return _0x4f554c[_0x4fccb3('0x1b1b')][_0x4fccb3('0x22c6')]({'uniqueid':_0x2af388})[_0x4fccb3('0xe53')][_0x4fccb3('0x683')](function(_0x479aa1){const _0x364d6d=_0x4fccb3;_0x478abb['success']({'title':_0x364d6d('0xae4')+_0x2af388+_0x364d6d('0x10a'),'msg':_0x479aa1[_0x364d6d('0x8c2')]||''});})['catch'](function(_0x1881ff){const _0x3b2b1b=_0x4fccb3;_0x478abb['error']({'title':_0x1881ff[_0x3b2b1b('0x13ee')]+_0x3b2b1b('0xbf6')+_0x1881ff[_0x3b2b1b('0x24a9')],'msg':JSON[_0x3b2b1b('0x258a')](_0x1881ff[_0x3b2b1b('0x5a5')])||_0x1881ff[_0x3b2b1b('0x8c2')][_0x3b2b1b('0x1630')]('\x20')});});}function _0x1f6ea0(_0x37ae4a,_0x1ead97,_0x203ee5){const _0x48e89b=_0x1aaa4d;return _0x4f554c[_0x48e89b('0x1b1b')]['getVoiceQueuesChannelRedirect']({'uniqueid':_0x37ae4a,'exten':_0x1ead97,'context':_0x203ee5})[_0x48e89b('0xe53')][_0x48e89b('0x683')](function(_0x257009){const _0x258f8c=_0x48e89b;_0x478abb[_0x258f8c('0x53')]({'title':_0x258f8c('0xae4')+_0x37ae4a+'\x20properly\x20redirect!','msg':_0x257009['message']||''});})[_0x48e89b('0x130a')](function(_0x1adb0d){const _0x27a8a=_0x48e89b;_0x478abb[_0x27a8a('0x52a')]({'title':_0x1adb0d[_0x27a8a('0x13ee')]+_0x27a8a('0xbf6')+_0x1adb0d[_0x27a8a('0x24a9')],'msg':JSON['stringify'](_0x1adb0d[_0x27a8a('0x5a5')])||_0x1adb0d[_0x27a8a('0x8c2')][_0x27a8a('0x1630')]('\x20')});});}function _0x43dc77(_0x29b50c,_0x5caf99){const _0x427632=_0x1aaa4d,_0x2e1d80=_0x1215bb['prompt']()[_0x427632('0xf28')](_0x427632('0x2158'))[_0x427632('0x156b')](_0x427632('0x140f'))['targetEvent'](_0x29b50c)['ok']('Ok')[_0x427632('0x19fb')](_0x427632('0x253a'));return _0x1215bb['show'](_0x2e1d80)[_0x427632('0x683')](function(_0x1448de){const _0x52360d=_0x427632;return _0x4f554c[_0x52360d('0x1b1b')]['getVoiceQueuesChannelRedirect']({'uniqueid':_0x5caf99,'exten':_0x1448de})[_0x52360d('0xe53')];})['then'](function(_0x411d58){const _0x13f7ee=_0x427632;_0x478abb[_0x13f7ee('0x53')]({'title':_0x13f7ee('0xae4')+_0x5caf99+_0x13f7ee('0x2081'),'msg':_0x411d58[_0x13f7ee('0x8c2')]||''});})[_0x427632('0x130a')](function(_0x409db4){const _0xcca87c=_0x427632;_0x478abb[_0xcca87c('0x52a')]({'title':_0x409db4[_0xcca87c('0x13ee')]+_0xcca87c('0xbf6')+_0x409db4[_0xcca87c('0x24a9')],'msg':JSON[_0xcca87c('0x258a')](_0x409db4[_0xcca87c('0x5a5')])||_0x409db4[_0xcca87c('0x8c2')]['join']('\x20')});});}_0x592aa9[_0x1aaa4d('0x26a2')](_0x1aaa4d('0x4b8'),function(){const _0x459c2f=_0x1aaa4d;_0x5b874d[_0x459c2f('0x1b9e')]('voice_queue_channel:save'),_0x5b874d[_0x459c2f('0x1b9e')](_0x459c2f('0xea9'));});}const _0x191135=_0x23b3a0;_0x5d84c3[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1b27'),_0x189033('0x2da'),_0x189033('0x1a10'),'api',_0x189033('0x1556'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1')];function _0x5d84c3(_0xa835f4,_0x3d633d,_0x323e85,_0x21269b,_0x4cdc1b,_0x20a4eb,_0x590d44,_0x1644eb,_0x1ca3d6,_0x1ac091){const _0x3a2b6d=_0x189033,_0xb6e39c=this,_0x389d68=[_0x3a2b6d('0x2263'),_0x3a2b6d('0x1e47'),_0x3a2b6d('0x2278'),'abandoned',_0x3a2b6d('0x1033'),_0x3a2b6d('0x1f'),'sumBillable'];_0xb6e39c[_0x3a2b6d('0x50d')]=_0x21269b[_0x3a2b6d('0x50d')],_0xb6e39c[_0x3a2b6d('0x2da')]=_0x21269b?_0x2e3ca0()['keyBy'](_0x21269b[_0x3a2b6d('0xf5d')]?_0x21269b[_0x3a2b6d('0xf5d')]:[],'id'):{},_0xb6e39c[_0x3a2b6d('0x1a10')]=_0x4cdc1b?_0x2e3ca0()[_0x3a2b6d('0x24db')](_0x4cdc1b[_0x3a2b6d('0xf5d')]?_0x4cdc1b[_0x3a2b6d('0xf5d')]:[],'id'):{},_0xb6e39c[_0x3a2b6d('0x2a')]=_0x1644eb,_0xb6e39c[_0x3a2b6d('0x22df')]=_0x1ca3d6&&_0x1ca3d6[_0x3a2b6d('0x50d')]==0x1?_0x1ca3d6[_0x3a2b6d('0xf5d')][0x0]:null,_0xb6e39c[_0x3a2b6d('0x1134')]=_0x1ac091[_0x3a2b6d('0x142a')](_0xb6e39c['userProfileSection']?_0xb6e39c['userProfileSection'][_0x3a2b6d('0x1134')]:null);_0x1ac091[_0x3a2b6d('0xca1')]('admin')?_0xb6e39c[_0x3a2b6d('0x23a2')]={'type':_0x3a2b6d('0x1535'),'fields':'id,name','sort':'-updatedAt','limit':0xa,'page':0x1}:_0xb6e39c[_0x3a2b6d('0x23a2')]={'id':_0x1ac091[_0x3a2b6d('0x20b2')]()['id'],'channel':_0x3a2b6d('0xcf2'),'type':'inbound','fields':'id,name','sort':_0x3a2b6d('0xc36'),'limit':0xa,'page':0x1};_0xb6e39c[_0x3a2b6d('0x53')]=_0x3e5d64,_0xb6e39c[_0x3a2b6d('0x4c9')]=_0x1afa8d,_0xb6e39c[_0x3a2b6d('0x2819')]=_0x26fced,_0xb6e39c['$onInit']=_0x1c1395,_0x590d44[_0x3a2b6d('0x5a3')](_0x3a2b6d('0x1df'),_0xb6e39c['onSave']),_0xb6e39c[_0x3a2b6d('0x115c')]=_0x323e85(function(){},0x3e7);function _0x1c1395(){_0x2e3ca0()['forIn'](_0xb6e39c['queues'],function(_0x4f3674,_0x40acf3){const _0x2b13b0=a0_0x4e0a;_0xb6e39c['rpcQueues'][_0x40acf3]&&_0x2e3ca0()[_0x2b13b0('0xf22')](_0x4f3674,_0x2e3ca0()['pick'](_0xb6e39c[_0x2b13b0('0x1a10')][_0x40acf3],_0x389d68));});}function _0x26fced(_0x506392){const _0x24b4dc=_0x3a2b6d;_0xb6e39c[_0x24b4dc('0x2da')][_0x506392['id']]&&_0x2e3ca0()['merge'](_0xb6e39c[_0x24b4dc('0x2da')][_0x506392['id']],_0x2e3ca0()['pick'](_0x506392,_0x389d68));}let _0x3931c4=!![],_0x2a34e2=0x1;_0xa835f4['$watch']('vm.query.filter',function(_0x462a17,_0x1ac816){const _0x23a734=_0x3a2b6d;_0x3931c4?_0x3d633d(function(){_0x3931c4=![];}):(!_0x1ac816&&(_0x2a34e2=_0xb6e39c[_0x23a734('0x23a2')]['page']),_0x462a17!==_0x1ac816&&(_0xb6e39c['query']['page']=0x1),!_0x462a17&&(_0xb6e39c['query']['page']=_0x2a34e2),_0xb6e39c['getQueues']());});function _0x3e5d64(_0x419325){const _0x291bdf=_0x3a2b6d;_0xb6e39c[_0x291bdf('0x50d')]=_0x419325[_0x291bdf('0x50d')],_0xb6e39c[_0x291bdf('0x2da')]=_0x419325?_0x2e3ca0()['keyBy'](_0x419325[_0x291bdf('0xf5d')]?_0x419325[_0x291bdf('0xf5d')]:[],'id'):{},_0x1c1395();}function _0x1afa8d(){const _0x2e8d1a=_0x3a2b6d;_0xb6e39c['query'][_0x2e8d1a('0x1cc8')]=(_0xb6e39c['query']['page']-0x1)*_0xb6e39c[_0x2e8d1a('0x23a2')]['limit'],_0x1ac091[_0x2e8d1a('0xca1')](_0x2e8d1a('0x20c2'))?_0xb6e39c[_0x2e8d1a('0x1883')]=_0x20a4eb[_0x2e8d1a('0x204c')][_0x2e8d1a('0x1e6e')](_0xb6e39c[_0x2e8d1a('0x23a2')],_0x3e5d64)[_0x2e8d1a('0xe53')]:(_0xb6e39c[_0x2e8d1a('0x23a2')]['id']=_0xb6e39c['userProfile']['id'],_0xb6e39c[_0x2e8d1a('0x23a2')]['section']=_0x2e8d1a('0x88d'),_0xb6e39c['promise']=_0x20a4eb[_0x2e8d1a('0x2a')][_0x2e8d1a('0x241d')](_0xb6e39c[_0x2e8d1a('0x23a2')],_0x3e5d64)['$promise']);}_0xa835f4[_0x3a2b6d('0x26a2')](_0x3a2b6d('0x4b8'),function(){const _0x425540=_0x3a2b6d;_0x590d44['removeAllListeners'](_0x425540('0x1df')),_0xb6e39c[_0x425540('0x115c')]&&_0x323e85[_0x425540('0x19fb')](_0xb6e39c[_0x425540('0x115c')]);});}const _0x7fce88=_0x5d84c3,_0x44ed12=_0x180212['p']+_0x189033('0x19b9'),_0x5994c8=_0x180212['p']+'src/js/modules/main/apps/voice/views/voiceQueues/edit/agentadd/agentadd.html/agentadd.html';_0x14d753[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$timeout',_0x189033('0x1e48'),'$q','$document',_0x189033('0x1b27'),_0x189033('0x2da'),_0x189033('0x1a10'),'api',_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x2a'),_0x189033('0x22df'),'Auth'];function _0x14d753(_0x255bf4,_0x21bd52,_0x4f0020,_0x5412c7,_0x57c1df,_0xdc5361,_0x54c7b4,_0x2d7ff9,_0xdc6353,_0x46153a,_0x2bc7cf,_0x20cdb0,_0x376978,_0x304d72){const _0x37bf9b=_0x189033,_0x4ce309=this,_0x1d91cf=[_0x37bf9b('0x1506'),_0x37bf9b('0x8bb'),'waiting',_0x37bf9b('0x7a4'),_0x37bf9b('0x17f2'),_0x37bf9b('0x1a95'),_0x37bf9b('0x8c2'),_0x37bf9b('0x1455'),_0x37bf9b('0x1091'),'Trunk','paused'];_0x4ce309['currentUser']=_0x304d72['getCurrentUser'](),_0x4ce309[_0x37bf9b('0x50d')]=_0x54c7b4[_0x37bf9b('0x50d')]?_0x54c7b4[_0x37bf9b('0x50d')]:0x0,_0x4ce309[_0x37bf9b('0x2da')]=_0x54c7b4?_0x2e3ca0()[_0x37bf9b('0x24db')](_0x54c7b4[_0x37bf9b('0xf5d')]?_0x54c7b4[_0x37bf9b('0xf5d')]:[],'id'):{},_0x4ce309['rpcQueues']=_0x2d7ff9?_0x2e3ca0()['keyBy'](_0x2d7ff9[_0x37bf9b('0xf5d')]?_0x2d7ff9['rows']:[],'id'):{},_0x4ce309['userProfile']=_0x20cdb0,_0x4ce309[_0x37bf9b('0x22df')]=_0x376978&&_0x376978[_0x37bf9b('0x50d')]==0x1?_0x376978[_0x37bf9b('0xf5d')][0x0]:null,_0x4ce309['crudPermissions']=_0x304d72[_0x37bf9b('0x142a')](_0x4ce309[_0x37bf9b('0x22df')]?_0x4ce309['userProfileSection'][_0x37bf9b('0x1134')]:null);_0x304d72[_0x37bf9b('0xca1')](_0x37bf9b('0x20c2'))?_0x4ce309[_0x37bf9b('0x23a2')]={'type':_0x37bf9b('0x1535'),'sort':_0x37bf9b('0xc36'),'limit':0xa,'page':0x1}:_0x4ce309['query']={'id':_0x4ce309[_0x37bf9b('0x11ed')]['id'],'channel':'voice','type':_0x37bf9b('0x1535'),'sort':_0x37bf9b('0xc36'),'limit':0xa,'page':0x1};_0x4ce309[_0x37bf9b('0x53')]=_0x29dfcd,_0x4ce309['getQueues']=_0x8f147e,_0x4ce309[_0x37bf9b('0x26f6')]=_0x32ded8,_0x4ce309[_0x37bf9b('0x1a94')]=_0x21e8e4,_0x4ce309['updateQueue']=_0x1a5ab5,_0x4ce309['onSave']=_0x2fc67d,_0x4ce309['onPause']=_0x2eb236,_0x4ce309['onLogin']=_0x57de0a,_0x4ce309[_0x37bf9b('0xb2b')]=_0xede5de,_0x4ce309['$onInit']=_0x59e45b,_0x4ce309['order']=[],_0x2e3ca0()[_0x37bf9b('0x15d0')](_0x4ce309[_0x37bf9b('0x2da')],function(_0x174d75){const _0xd3b1f=_0x37bf9b;_0x4ce309[_0xd3b1f('0x150d')][_0xd3b1f('0x1fd0')](_0x174d75['id']);}),_0x46153a[_0x37bf9b('0x5a3')](_0x37bf9b('0x1df'),_0x4ce309[_0x37bf9b('0x2819')]),_0x4ce309['interval']=_0xdc5361(function(){},0x3e7),_0x46153a['on']('user:update',_0x4ce309[_0x37bf9b('0x4a5')]),_0x46153a['on'](_0x37bf9b('0x56f'),_0x4ce309['onLogout']),_0x46153a['on'](_0x37bf9b('0x217c'),_0x4ce309[_0x37bf9b('0xd8b')]);function _0x59e45b(){const _0xce9f7e=_0x37bf9b,_0x4089f5=[];return _0x2e3ca0()[_0xce9f7e('0x15d0')](_0x4ce309[_0xce9f7e('0x2da')],function(_0x1a32a4,_0x3949d9){const _0x10cfb1=_0xce9f7e;_0x1a32a4[_0x10cfb1('0x1a1d')]=0x0,_0x1a32a4[_0x10cfb1('0x25a4')]=0x0,_0x4ce309[_0x10cfb1('0x2da')][_0x3949d9]['agents']={},_0x4089f5[_0x10cfb1('0x1fd0')](_0xdc6353[_0x10cfb1('0x204c')][_0x10cfb1('0x27cf')]({'id':_0x3949d9})['$promise']),_0x4ce309[_0x10cfb1('0x1a10')][_0x3949d9]&&_0x2e3ca0()[_0x10cfb1('0xf22')](_0x1a32a4,_0x2e3ca0()[_0x10cfb1('0x24d0')](_0x4ce309[_0x10cfb1('0x1a10')][_0x3949d9],_0x1d91cf));}),_0x5412c7[_0xce9f7e('0x252c')](_0x4089f5)[_0xce9f7e('0x683')](function(_0x57725f){const _0xac8e7=_0xce9f7e;for(let _0xcdd212=0x0;_0xcdd212<_0x57725f['length'];_0xcdd212+=0x1){for(let _0x3eca99=0x0;_0x3eca99<_0x57725f[_0xcdd212][_0xac8e7('0xf5d')][_0xac8e7('0x1564')];_0x3eca99++){_0x57725f[_0xcdd212][_0xac8e7('0xf5d')][_0x3eca99][_0xac8e7('0x1a1d')]&&_0x4ce309[_0xac8e7('0x2da')][_0x57725f[_0xcdd212][_0xac8e7('0xf5d')][_0x3eca99]['VoiceQueueId']][_0xac8e7('0x1a1d')]++,_0x4ce309[_0xac8e7('0x2da')][_0x57725f[_0xcdd212][_0xac8e7('0xf5d')][_0x3eca99]['VoiceQueueId']][_0xac8e7('0x25a4')]++,_0x4ce309[_0xac8e7('0x2da')][_0x57725f[_0xcdd212]['rows'][_0x3eca99][_0xac8e7('0x19ec')]][_0xac8e7('0x756')][_0x57725f[_0xcdd212][_0xac8e7('0xf5d')][_0x3eca99][_0xac8e7('0x10c5')]]=_0x57725f[_0xcdd212]['rows'][_0x3eca99][_0xac8e7('0x19ec')];}}})[_0xce9f7e('0x130a')](function(_0x5e0ca2){const _0x5d2696=_0xce9f7e;console[_0x5d2696('0x52a')](_0x5e0ca2);});}function _0x2fc67d(_0x19118e){const _0x3562e6=_0x37bf9b;_0x4ce309[_0x3562e6('0x2da')][_0x19118e['id']]&&_0x2e3ca0()[_0x3562e6('0xf22')](_0x4ce309[_0x3562e6('0x2da')][_0x19118e['id']],_0x2e3ca0()[_0x3562e6('0x24d0')](_0x19118e,_0x1d91cf));}function _0x2eb236(_0x23b6e9){const _0xb6d890=_0x37bf9b;console[_0xb6d890('0x1b2b')](_0xb6d890('0x4a5'),_0x23b6e9);if(_0x23b6e9['voicePause'])_0x2e3ca0()['forIn'](_0x4ce309[_0xb6d890('0x2da')],function(_0x278d76){const _0x4cd529=_0xb6d890;_0x278d76[_0x4cd529('0x756')][_0x23b6e9['id']]&&(_0x278d76[_0x4cd529('0x1a1d')]+=0x1,console[_0x4cd529('0x1b2b')](_0x4cd529('0xa4')));});else!_0x23b6e9[_0xb6d890('0x1431')]&&_0x2e3ca0()['forIn'](_0x4ce309[_0xb6d890('0x2da')],function(_0x3a134b){const _0x35cf5f=_0xb6d890;_0x3a134b['agents'][_0x23b6e9['id']]&&(_0x3a134b[_0x35cf5f('0x1a1d')]>0x0&&(_0x3a134b[_0x35cf5f('0x1a1d')]-=0x1,console[_0x35cf5f('0x1b2b')](_0x35cf5f('0x1778'))));});}function _0x57de0a(_0x35ccfc){const _0x1766db=_0x37bf9b;console[_0x1766db('0x1b2b')](_0x1766db('0x16aa'),_0x35ccfc),_0x4ce309[_0x1766db('0x2da')][_0x35ccfc[_0x1766db('0x19ec')]]&&(_0x4ce309['queues'][_0x35ccfc[_0x1766db('0x19ec')]][_0x1766db('0x25a4')]+=0x1,_0x4ce309['queues'][_0x35ccfc[_0x1766db('0x19ec')]][_0x1766db('0x756')][_0x35ccfc['UserId']]=_0x35ccfc[_0x1766db('0x19ec')]);}function _0xede5de(_0x38be0e){const _0x4d1166=_0x37bf9b;console['log'](_0x4d1166('0xb2b'),_0x38be0e),_0x4ce309[_0x4d1166('0x2da')][_0x38be0e[_0x4d1166('0x19ec')]]&&_0x4ce309['queues'][_0x38be0e[_0x4d1166('0x19ec')]]['loggedInDb']>0x0&&(_0x4ce309[_0x4d1166('0x2da')][_0x38be0e[_0x4d1166('0x19ec')]][_0x4d1166('0x25a4')]-=0x1,delete _0x4ce309[_0x4d1166('0x2da')][_0x38be0e[_0x4d1166('0x19ec')]][_0x4d1166('0x756')][_0x38be0e[_0x4d1166('0x10c5')]]);}let _0x24395e=!![],_0x98568=0x1;_0x255bf4[_0x37bf9b('0x186d')](_0x37bf9b('0x1e1d'),function(_0x20747c,_0x4cf7b0){const _0x1d5928=_0x37bf9b;_0x24395e?_0x21bd52(function(){_0x24395e=![];}):(!_0x4cf7b0&&(_0x98568=_0x4ce309[_0x1d5928('0x23a2')][_0x1d5928('0xdf8')]),_0x20747c!==_0x4cf7b0&&(_0x4ce309[_0x1d5928('0x23a2')][_0x1d5928('0xdf8')]=0x1),!_0x20747c&&(_0x4ce309[_0x1d5928('0x23a2')][_0x1d5928('0xdf8')]=_0x98568),_0x4ce309[_0x1d5928('0x4c9')]());});function _0x29dfcd(_0xf0d901){const _0x55ef33=_0x37bf9b;_0x4ce309['count']=_0xf0d901['count'],_0x4ce309['queues']=_0xf0d901?_0x2e3ca0()[_0x55ef33('0x24db')](_0xf0d901[_0x55ef33('0xf5d')]?_0xf0d901['rows']:[],'id'):{};if(_0xf0d901[_0x55ef33('0xf5d')]){_0x4ce309[_0x55ef33('0x150d')]=[];for(let _0x4ecd24=0x0;_0x4ecd24<_0xf0d901[_0x55ef33('0xf5d')][_0x55ef33('0x1564')];_0x4ecd24++){_0x4ce309['order'][_0x55ef33('0x1fd0')](_0xf0d901[_0x55ef33('0xf5d')][_0x4ecd24]['id']);}}_0x59e45b();}function _0x8f147e(){const _0x2b1a94=_0x37bf9b;_0x4ce309[_0x2b1a94('0x23a2')][_0x2b1a94('0x1cc8')]=(_0x4ce309['query']['page']-0x1)*_0x4ce309[_0x2b1a94('0x23a2')][_0x2b1a94('0x6f0')],_0x304d72['hasRole']('admin')?_0x4ce309[_0x2b1a94('0x1883')]=_0xdc6353[_0x2b1a94('0x204c')]['get'](_0x4ce309[_0x2b1a94('0x23a2')],_0x29dfcd)[_0x2b1a94('0xe53')]:(_0x4ce309[_0x2b1a94('0x23a2')]['id']=_0x4ce309['userProfile']['id'],_0x4ce309[_0x2b1a94('0x23a2')][_0x2b1a94('0x1aa')]=_0x2b1a94('0x88d'),_0x4ce309[_0x2b1a94('0x1883')]=_0xdc6353['userProfile']['getResources'](_0x4ce309[_0x2b1a94('0x23a2')],_0x29dfcd)[_0x2b1a94('0xe53')]);}function _0x32ded8(_0xbd64b9,_0x43f3c4){const _0xd0c7a5=_0x37bf9b;_0x4f0020[_0xd0c7a5('0x1d4')]({'controller':_0xd0c7a5('0x2306'),'controllerAs':'vm','templateUrl':_0x44ed12,'parent':angular['element'](_0x57c1df[_0xd0c7a5('0x18e5')]),'targetEvent':_0xbd64b9,'clickOutsideToClose':!![],'locals':{'voiceQueue':_0x43f3c4,'voiceQueues':_0x2e3ca0()['values'](_0x4ce309[_0xd0c7a5('0x2da')]),'license':null,'setting':null,'crudPermissions':_0x4ce309[_0xd0c7a5('0x1134')]}});}function _0x21e8e4(_0x7a006c,_0x49d7c4){const _0x2c07e8=_0x37bf9b;_0x4f0020[_0x2c07e8('0x1d4')]({'controller':'VoiceQueueagentaddController','controllerAs':'vm','templateUrl':_0x5994c8,'parent':angular[_0x2c07e8('0x1fcc')](_0x57c1df['body']),'targetEvent':_0x7a006c,'clickOutsideToClose':!![],'locals':{'voiceQueue':_0x49d7c4,'voiceQueues':_0x4ce309['queues']?_0x4ce309[_0x2c07e8('0x2da')]['rows']:[],'realtime':!![],'crudPermissions':_0x4ce309[_0x2c07e8('0x1134')]}});}function _0x1a5ab5(_0x4e8a4f){const _0x10f5eb=_0x37bf9b;return _0xdc6353[_0x10f5eb('0x204c')][_0x10f5eb('0x2480')](_0x4e8a4f)[_0x10f5eb('0xe53')][_0x10f5eb('0x683')](function(){const _0x208298=_0x10f5eb;_0x2bc7cf[_0x208298('0x53')]({'title':_0x208298('0x5c7'),'msg':_0x4e8a4f['name']?_0x4e8a4f[_0x208298('0x60a')]+_0x208298('0x96c'):''});})['catch'](function(_0x325b51){const _0x5cfe6b=_0x10f5eb;_0x2bc7cf[_0x5cfe6b('0x52a')]({'title':_0x5cfe6b('0xb4'),'msg':_0x325b51[_0x5cfe6b('0x8c2')]});});}_0x255bf4[_0x37bf9b('0x26a2')](_0x37bf9b('0x4b8'),function(){const _0x35503b=_0x37bf9b;_0x46153a['removeAllListeners'](_0x35503b('0x1df')),_0x4ce309[_0x35503b('0x115c')]&&_0xdc5361[_0x35503b('0x19fb')](_0x4ce309[_0x35503b('0x115c')]),_0x46153a[_0x35503b('0x1b9e')](_0x35503b('0x2719')),_0x46153a[_0x35503b('0x1b9e')](_0x35503b('0x56f')),_0x46153a[_0x35503b('0x1b9e')]('userVoiceQueue:save');});}const _0x366ee8=_0x14d753;function _0x5198ad(){const _0x37c4fc=_0x189033;return{'status':{'registered':_0x37c4fc('0x584'),'unregistered':_0x37c4fc('0x1da'),'lagged':_0x37c4fc('0x1da'),'reachable':_0x37c4fc('0x584'),'unreachable':_0x37c4fc('0x1da'),'unknown':_0x37c4fc('0xcb0')},'state':{'unknown':_0x37c4fc('0x27f9'),'not_inuse':_0x37c4fc('0x280d'),'inuse':'red-300-fg\x20icon-phone-in-talk','busy':_0x37c4fc('0x25ad'),'invalid':'grey-fg\x20icon-phone-hangup','unavailable':'grey-fg\x20icon-phone-hangup','ringing':_0x37c4fc('0x20f0'),'ringinuse':'blue-300-fg\x20icon-phone-incoming','onhold':'blue-300-fg\x20icon-phone-paused'},'channelStatus':{'ring':_0x37c4fc('0x20f0'),'up':_0x37c4fc('0x1133'),'hangup':_0x37c4fc('0x22be')},'channelStatusOut':{'ring':'blue-300-fg\x20icon-phone-outgoing','up':_0x37c4fc('0x1133'),'hangup':'red-300-fg\x20icon-phone-hangup'}};}const _0x4f6c1b=_0x5198ad;_0x5604d4['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),'socket'];function _0x5604d4(_0x46ab32,_0x388535,_0x1aa0f1){const _0x388577=_0x189033,_0x56ce6d=this;_0x1aa0f1[_0x388577('0x1346')](),_0x1aa0f1[_0x388577('0x12ac')](),_0x56ce6d['selectedTab']=0x0;switch(_0x388535[_0x388577('0xb24')][_0x388577('0x60a')]){case'app.voice.realtime.agents':_0x56ce6d['selectedTab']=0x0;break;case'app.voice.realtime.telephones':_0x56ce6d['selectedTab']=0x1;break;case'app.voice.realtime.trunks':_0x56ce6d[_0x388577('0x517')]=0x2;break;case _0x388577('0x1591'):_0x56ce6d['selectedTab']=0x3;break;case'app.voice.realtime.queue_calls':_0x56ce6d['selectedTab']=0x4;break;case'app.voice.realtime.abandonedcalls':_0x56ce6d[_0x388577('0x517')]=0x5;break;case _0x388577('0x19f3'):_0x56ce6d[_0x388577('0x517')]=0x6;break;case'app.voice.realtime.outbound_calls':_0x56ce6d['selectedTab']=0x7;break;default:_0x56ce6d[_0x388577('0x517')]=0x0,_0x388535['go']('app.voice.realtime.agents');}_0x46ab32['$watch'](_0x388577('0x9a4'),function(_0x2cea94,_0x301cd2){const _0x402cf4=_0x388577;if(_0x2cea94!==_0x301cd2)switch(_0x2cea94){case 0x0:_0x388535['go'](_0x402cf4('0x282d'));break;case 0x1:_0x388535['go'](_0x402cf4('0x191c'));break;case 0x2:_0x388535['go']('app.voice.realtime.trunks');break;case 0x3:_0x388535['go']('app.voice.realtime.queues');break;case 0x4:_0x388535['go'](_0x402cf4('0x1875'));break;case 0x5:_0x388535['go'](_0x402cf4('0x46e'));break;case 0x6:_0x388535['go'](_0x402cf4('0x19f3'));break;case 0x7:_0x388535['go'](_0x402cf4('0x1082'));break;default:_0x388535['go']('app.voice.realtime.agents');}});}const _0x57209e=_0x5604d4;_0xce1c80[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x723'),_0x189033('0xab1'),_0x189033('0x56b'),'socket','helperClasses','userProfile',_0x189033('0x22df'),'Auth'];function _0xce1c80(_0x2d4c87,_0x28629d,_0x5077df,_0x3e0cd8,_0x42c4d0,_0x56aa53,_0x17a104,_0x2caf53,_0x187d81,_0x3fc2f2,_0x811e28){const _0x3f6f32=_0x189033,_0x5102a8=this,_0xbcd800=[_0x3f6f32('0x11bc'),_0x3f6f32('0x1d43'),_0x3f6f32('0x2598'),_0x3f6f32('0x13ee')];_0x5102a8['count']=_0x3e0cd8['count'],_0x5102a8['attributes']=[_0x3f6f32('0x11bc'),_0x3f6f32('0x1d43'),_0x3f6f32('0x2598'),_0x3f6f32('0x13ee'),'address'],_0x5102a8[_0x3f6f32('0x723')]=_0x3e0cd8?_0x2e3ca0()[_0x3f6f32('0x24db')](_0x3e0cd8[_0x3f6f32('0xf5d')]?_0x3e0cd8[_0x3f6f32('0xf5d')]:[],'id'):{},_0x5102a8[_0x3f6f32('0xab1')]=_0x42c4d0?_0x2e3ca0()[_0x3f6f32('0x24db')](_0x42c4d0['rows']?_0x42c4d0['rows']:[],'id'):{},_0x5102a8[_0x3f6f32('0x2a')]=_0x187d81,_0x5102a8[_0x3f6f32('0x22df')]=_0x3fc2f2&&_0x3fc2f2['count']==0x1?_0x3fc2f2[_0x3f6f32('0xf5d')][0x0]:null,_0x5102a8['crudPermissions']=_0x811e28[_0x3f6f32('0x142a')](_0x5102a8[_0x3f6f32('0x22df')]?_0x5102a8['userProfileSection'][_0x3f6f32('0x1134')]:null),_0x5102a8[_0x3f6f32('0x23a2')]={'fields':_0x3f6f32('0x3c3'),'role':_0x3f6f32('0x24d3'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x5102a8[_0x3f6f32('0x22e0')]=_0x2caf53[_0x3f6f32('0x13ee')],_0x5102a8['stateClass']=_0x2caf53['state'],_0x5102a8[_0x3f6f32('0x53')]=_0x544092,_0x5102a8[_0x3f6f32('0x3a8')]=_0x5796a5,_0x5102a8[_0x3f6f32('0x411')]=_0x21a115,_0x5102a8[_0x3f6f32('0x16c')]=_0x3f7286,_0x5102a8['onSave']=_0x272f28,_0x17a104['on'](_0x3f6f32('0x1393'),_0x5102a8[_0x3f6f32('0x2819')]);function _0x5796a5(){const _0x12a7be=_0x3f6f32;_0x2e3ca0()[_0x12a7be('0x15d0')](_0x5102a8[_0x12a7be('0x723')],function(_0x323cf8,_0x5c0c3d){const _0x47c9e5=_0x12a7be;_0x5102a8[_0x47c9e5('0xab1')][_0x5c0c3d]&&_0x2e3ca0()['merge'](_0x323cf8,_0x2e3ca0()[_0x47c9e5('0x24d0')](_0x5102a8['rpcTelephones'][_0x5c0c3d],_0xbcd800));});}function _0x21a115(_0x27ab52){const _0xc8ba9b=_0x3f6f32;_0x5077df[_0xc8ba9b('0x1d4')](_0x5077df[_0xc8ba9b('0x2430')]()['clickOutsideToClose'](!![])[_0xc8ba9b('0xf28')](_0xc8ba9b('0x71a'))[_0xc8ba9b('0x26e3')](_0xc8ba9b('0x1f0'))['ok']('Ok')[_0xc8ba9b('0xe42')](_0x27ab52));}function _0x272f28(_0x23ffab){const _0x3a133d=_0x3f6f32;_0x5102a8[_0x3a133d('0x723')][_0x23ffab['id']]&&_0x2e3ca0()[_0x3a133d('0xf22')](_0x5102a8[_0x3a133d('0x723')][_0x23ffab['id']],_0x2e3ca0()[_0x3a133d('0x24d0')](_0x23ffab,_0xbcd800));}let _0x2c1e5d=!![],_0x1ce110=0x1;_0x2d4c87[_0x3f6f32('0x186d')](_0x3f6f32('0x1e1d'),function(_0xac85de,_0x26ec85){const _0x1dcb14=_0x3f6f32;_0x2c1e5d?_0x28629d(function(){_0x2c1e5d=![];}):(!_0x26ec85&&(_0x1ce110=_0x5102a8[_0x1dcb14('0x23a2')][_0x1dcb14('0xdf8')]),_0xac85de!==_0x26ec85&&(_0x5102a8['query']['page']=0x1),!_0xac85de&&(_0x5102a8[_0x1dcb14('0x23a2')]['page']=_0x1ce110),_0x5102a8[_0x1dcb14('0x16c')]());});function _0x544092(_0x1fd50b){const _0x49a93f=_0x3f6f32;_0x5102a8['telephones']=_0x1fd50b?_0x2e3ca0()['keyBy'](_0x1fd50b[_0x49a93f('0xf5d')]?_0x1fd50b[_0x49a93f('0xf5d')]:[],'id'):{},_0x5796a5();}function _0x3f7286(){const _0x57e423=_0x3f6f32;_0x5102a8[_0x57e423('0x23a2')]['offset']=(_0x5102a8[_0x57e423('0x23a2')][_0x57e423('0xdf8')]-0x1)*_0x5102a8[_0x57e423('0x23a2')][_0x57e423('0x6f0')],_0x811e28[_0x57e423('0xca1')](_0x57e423('0x20c2'))?_0x5102a8['promise']=_0x56aa53[_0x57e423('0xc96')]['get'](_0x5102a8[_0x57e423('0x23a2')],_0x544092)[_0x57e423('0xe53')]:(_0x5102a8[_0x57e423('0x23a2')]['id']=_0x5102a8[_0x57e423('0x2a')]['id'],_0x5102a8[_0x57e423('0x23a2')]['section']=_0x57e423('0x193e'),_0x5102a8[_0x57e423('0x1883')]=_0x56aa53['userProfile']['getResources'](_0x5102a8[_0x57e423('0x23a2')],_0x544092)[_0x57e423('0xe53')]);}_0x2d4c87[_0x3f6f32('0x26a2')](_0x3f6f32('0x4b8'),function(){const _0x530049=_0x3f6f32;_0x17a104[_0x530049('0x1b9e')](_0x530049('0x1393'));});}const _0x16cfd5=_0xce1c80;_0x29e4cc[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x20fe'),'rpcTrunks',_0x189033('0x56b'),'socket',_0x189033('0xa72'),_0x189033('0x938'),'userProfile',_0x189033('0x22df'),_0x189033('0xba1')];function _0x29e4cc(_0x5c8d84,_0x31ebd3,_0x69a1a3,_0x5bda60,_0x22e1bc,_0x259245,_0x2def2c,_0x2dcb64,_0x30ef22,_0x30646d,_0xa6ea5f,_0x933af0){const _0x53f23a=_0x189033,_0x1bbbfd=this,_0x997412=[_0x53f23a('0x13ee'),_0x53f23a('0x287d'),'registry','host',_0x53f23a('0x4a2'),_0x53f23a('0x1d43'),_0x53f23a('0x2598'),_0x53f23a('0x13ee')];_0x1bbbfd[_0x53f23a('0x11ed')]=_0x933af0[_0x53f23a('0x20b2')](),_0x1bbbfd[_0x53f23a('0x50d')]=_0x5bda60[_0x53f23a('0x50d')],_0x1bbbfd[_0x53f23a('0x20fe')]=_0x5bda60?_0x5bda60[_0x53f23a('0xf5d')]:[],_0x1bbbfd[_0x53f23a('0x19fc')]=_0x22e1bc?_0x22e1bc[_0x53f23a('0xf5d')]?_0x22e1bc['rows']:[]:[],_0x1bbbfd['query']={'fields':_0x53f23a('0xa10'),'active':!![],'sort':_0x53f23a('0xc36'),'limit':0xa,'page':0x1},_0x1bbbfd[_0x53f23a('0x22e0')]=_0x2dcb64[_0x53f23a('0x13ee')],_0x1bbbfd[_0x53f23a('0x1f80')]=_0x2dcb64['state'],_0x1bbbfd[_0x53f23a('0x2a')]=_0x30646d,_0x1bbbfd[_0x53f23a('0x22df')]=_0xa6ea5f&&_0xa6ea5f[_0x53f23a('0x50d')]==0x1?_0xa6ea5f['rows'][0x0]:null,_0x1bbbfd['crudPermissions']=_0x933af0['parseCrudPermissions'](_0x1bbbfd[_0x53f23a('0x22df')]?_0x1bbbfd[_0x53f23a('0x22df')]['crudPermissions']:null),_0x1bbbfd[_0x53f23a('0x53')]=_0x1e18db,_0x1bbbfd[_0x53f23a('0x3a8')]=_0x54c0bc,_0x1bbbfd[_0x53f23a('0x411')]=_0x36bac8,_0x1bbbfd[_0x53f23a('0x5c5')]=_0x254948,_0x1bbbfd['goToTrunk']=_0x31a96c,_0x1bbbfd[_0x53f23a('0x2819')]=_0x23e8c5,_0x2def2c['on'](_0x53f23a('0x2777'),_0x1bbbfd[_0x53f23a('0x2819')]);function _0x54c0bc(){const _0xeb6913=_0x53f23a;let _0x452e17;for(let _0x23bd0a=0x0;_0x23bd0a<_0x1bbbfd[_0xeb6913('0x20fe')][_0xeb6913('0x1564')];_0x23bd0a+=0x1){_0x452e17=_0x2e3ca0()[_0xeb6913('0x1ce4')](_0x1bbbfd[_0xeb6913('0x19fc')],['id',_0x1bbbfd[_0xeb6913('0x20fe')][_0x23bd0a]['id']]),_0x452e17>=0x0&&_0x2e3ca0()[_0xeb6913('0xf22')](_0x1bbbfd[_0xeb6913('0x20fe')][_0x23bd0a],_0x2e3ca0()[_0xeb6913('0x24d0')](_0x1bbbfd[_0xeb6913('0x19fc')][_0x452e17],_0x997412));}}function _0x36bac8(_0x3d7a83){const _0xcca9f4=_0x53f23a;_0x69a1a3[_0xcca9f4('0x1d4')](_0x69a1a3[_0xcca9f4('0x2430')]()[_0xcca9f4('0x188f')](!![])[_0xcca9f4('0xf28')](_0xcca9f4('0x71a'))['htmlContent']('
TODO\x20legend\x20status\x20+\x20state
')['ok']('Ok')[_0xcca9f4('0xe42')](_0x3d7a83));}function _0x2205f2(_0x51168c,_0x164368,_0x55ec07){const _0x5cdcad=_0x53f23a;_0x164368>=0x0&&_0x2e3ca0()[_0x5cdcad('0xf22')](_0x51168c[_0x164368],_0x2e3ca0()[_0x5cdcad('0x24d0')](_0x55ec07,_0x997412));}function _0x23e8c5(_0x2deedb){const _0x4b9baf=_0x53f23a,_0x436daa=_0x2e3ca0()[_0x4b9baf('0x1ce4')](_0x1bbbfd[_0x4b9baf('0x20fe')],['id',_0x2deedb['id']]),_0x2db1f8=_0x2e3ca0()[_0x4b9baf('0x1ce4')](_0x1bbbfd[_0x4b9baf('0x19fc')],['id',_0x2deedb['id']]);_0x2205f2(_0x1bbbfd[_0x4b9baf('0x20fe')],_0x436daa,_0x2deedb),_0x2205f2(_0x1bbbfd[_0x4b9baf('0x19fc')],_0x2db1f8,_0x2deedb);}let _0x2b3a7e=!![],_0xd712ac=0x1;_0x5c8d84['$watch']('vm.query.filter',function(_0x7be860,_0x3f4443){const _0x33cfc7=_0x53f23a;_0x2b3a7e?_0x31ebd3(function(){_0x2b3a7e=![];}):(!_0x3f4443&&(_0xd712ac=_0x1bbbfd['query'][_0x33cfc7('0xdf8')]),_0x7be860!==_0x3f4443&&(_0x1bbbfd['query'][_0x33cfc7('0xdf8')]=0x1),!_0x7be860&&(_0x1bbbfd['query'][_0x33cfc7('0xdf8')]=_0xd712ac),_0x1bbbfd['getTrunks']());});function _0x1e18db(_0x251742){const _0x3d10f7=_0x53f23a;_0x1bbbfd[_0x3d10f7('0x50d')]=_0x251742['count'],_0x1bbbfd[_0x3d10f7('0x20fe')]=_0x251742?_0x251742[_0x3d10f7('0xf5d')]?_0x251742[_0x3d10f7('0xf5d')]:[]:[],_0x54c0bc();}function _0x254948(){const _0xd1e115=_0x53f23a;_0x1bbbfd['query'][_0xd1e115('0x1cc8')]=(_0x1bbbfd['query'][_0xd1e115('0xdf8')]-0x1)*_0x1bbbfd[_0xd1e115('0x23a2')][_0xd1e115('0x6f0')],_0x933af0[_0xd1e115('0xca1')](_0xd1e115('0x20c2'))?_0x1bbbfd[_0xd1e115('0x1883')]=_0x259245[_0xd1e115('0x1a93')][_0xd1e115('0x1e6e')](_0x1bbbfd[_0xd1e115('0x23a2')],_0x1e18db)[_0xd1e115('0xe53')]:(_0x1bbbfd[_0xd1e115('0x23a2')]['id']=_0x1bbbfd[_0xd1e115('0x2a')]['id'],_0x1bbbfd[_0xd1e115('0x23a2')][_0xd1e115('0x1aa')]=_0xd1e115('0x485'),_0x1bbbfd[_0xd1e115('0x1883')]=_0x259245[_0xd1e115('0x2a')][_0xd1e115('0x241d')](_0x1bbbfd['query'],_0x1e18db)[_0xd1e115('0xe53')]);}_0x5c8d84[_0x53f23a('0x26a2')](_0x53f23a('0x4b8'),function(){const _0x2d8ec7=_0x53f23a;_0x2def2c[_0x2d8ec7('0x1b9e')]('trunk:save');});function _0x31a96c(_0x1fa677,_0x3acb1a){const _0x31b690=_0x53f23a;_0x30ef22['go'](_0x31b690('0xc28'),{'id':_0x3acb1a['id']});}}const _0xf46336=_0x29e4cc,_0x1120fa=_0x180212['p']+_0x189033('0xdc4'),_0x1a9b1a=_0x180212['p']+_0x189033('0x11dd'),_0x544816=_0x180212['p']+_0x189033('0x15eb'),_0x92040b=_0x180212['p']+_0x189033('0x16c5'),_0x19e562=_0x180212['p']+'src/js/modules/main/apps/voice/views/realtime/queues/view.html/view.html',_0x1f6b76=_0x180212['p']+_0x189033('0x1c67'),_0x3871e0=_0x180212['p']+_0x189033('0x4f7'),_0x3fa35c=_0x180212['p']+_0x189033('0x17f6'),_0x1b6799=_0x180212['p']+_0x189033('0xe7e');_0x38d85e[_0x189033('0x14be')]=[_0x189033('0x1398')];function _0x38d85e(_0x2a0935){const _0xfdf345=_0x189033;_0x2a0935[_0xfdf345('0x2598')]('app.voice.realtime',{'url':'/realtime','views':{'content@app':{'templateUrl':_0x1120fa,'controller':_0xfdf345('0x25d')}},'resolve':{'userProfile':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x3a7da2,_0x7d6adf){const _0x2cc21f=_0xfdf345;return _0x7d6adf[_0x2cc21f('0xca1')](_0x2cc21f('0x20c2'))?null:_0x3a7da2[_0x2cc21f('0xed7')](_0x2cc21f('0x1464'),{'fields':_0x2cc21f('0x16f'),'id':_0x7d6adf[_0x2cc21f('0x20b2')]()[_0x2cc21f('0x2f')]});}],'userProfileSection':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x4b0017,_0x49e244){const _0x3447e8=_0xfdf345;return _0x49e244[_0x3447e8('0xca1')]('admin')?null:_0x4b0017['resolve'](_0x3447e8('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x49e244[_0x3447e8('0x20b2')]()['userProfileId'],'sectionId':0x19b});}]},'authenticate':!![],'permissionId':0x19b})['state']('app.voice.realtime.agents',{'url':'/agents','controller':_0xfdf345('0x2839'),'templateUrl':_0x1a9b1a,'resolve':{'pauses':['apiResolver',function(_0x4573fe){const _0x45406d=_0xfdf345;return _0x4573fe[_0x45406d('0xed7')](_0x45406d('0x112'),{'nolimit':!![]});}],'agents':['apiResolver',_0xfdf345('0xba1'),function(_0x46bc34,_0x20adf7){const _0x995ed2=_0xfdf345;return _0x20adf7[_0x995ed2('0xca1')](_0x995ed2('0x20c2'))?_0x46bc34[_0x995ed2('0xed7')](_0x995ed2('0x25c9'),{'fields':_0x995ed2('0x174e'),'role':_0x995ed2('0x2327'),'sort':'fullname','nolimit':!![]}):_0x46bc34[_0x995ed2('0xed7')]('userProfile@getResources',{'id':_0x20adf7['getCurrentUser']()[_0x995ed2('0x2f')],'section':_0x995ed2('0x1bc0'),'fields':_0x995ed2('0x174e'),'role':'agent','sort':_0x995ed2('0x11bc'),'nolimit':!![]});}],'userProfile':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x43515b,_0x570df2){const _0x49dce0=_0xfdf345;return _0x570df2[_0x49dce0('0xca1')](_0x49dce0('0x20c2'))?null:_0x43515b[_0x49dce0('0xed7')](_0x49dce0('0x1464'),{'fields':_0x49dce0('0x16f'),'id':_0x570df2[_0x49dce0('0x20b2')]()[_0x49dce0('0x2f')]});}],'userProfileSection':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x3ba19a,_0x5240b6){const _0x2e2975=_0xfdf345;return _0x5240b6[_0x2e2975('0xca1')](_0x2e2975('0x20c2'))?null:_0x3ba19a[_0x2e2975('0xed7')]('userProfileSection@get',{'fields':_0x2e2975('0x1f47'),'userProfileId':_0x5240b6[_0x2e2975('0x20b2')]()[_0x2e2975('0x2f')],'sectionId':0xca});}],'rpcAgents':[_0xfdf345('0x4b1'),function(_0x3c2881){const _0x390707=_0xfdf345;return _0x3c2881[_0x390707('0xed7')](_0x390707('0x36a'));}]},'authenticate':!![],'permissionId':0x19b})['state'](_0xfdf345('0x191c'),{'url':_0xfdf345('0xe52'),'controller':_0xfdf345('0x2884'),'templateUrl':_0x544816,'resolve':{'telephones':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x1a6e5f,_0x521251){const _0x1fca56=_0xfdf345;return _0x521251[_0x1fca56('0xca1')](_0x1fca56('0x20c2'))?_0x1a6e5f[_0x1fca56('0xed7')](_0x1fca56('0x25c9'),{'fields':_0x1fca56('0x132d'),'role':_0x1fca56('0x24d3'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x1a6e5f[_0x1fca56('0xed7')](_0x1fca56('0x191b'),{'id':_0x521251[_0x1fca56('0x20b2')]()['userProfileId'],'section':_0x1fca56('0x193e'),'fields':'id,fullname,userpic,internal','role':'telephone','sort':_0x1fca56('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0xfdf345('0xba1'),function(_0x4ecb94,_0x47237b){const _0x119f34=_0xfdf345;return _0x47237b[_0x119f34('0xca1')](_0x119f34('0x20c2'))?null:_0x4ecb94['resolve'](_0x119f34('0x1464'),{'fields':_0x119f34('0x16f'),'id':_0x47237b[_0x119f34('0x20b2')]()[_0x119f34('0x2f')]});}],'userProfileSection':['apiResolver',_0xfdf345('0xba1'),function(_0x47cb41,_0x26d1f9){const _0x38fcda=_0xfdf345;return _0x26d1f9[_0x38fcda('0xca1')](_0x38fcda('0x20c2'))?null:_0x47cb41[_0x38fcda('0xed7')](_0x38fcda('0x360'),{'fields':_0x38fcda('0x1f47'),'userProfileId':_0x26d1f9[_0x38fcda('0x20b2')]()[_0x38fcda('0x2f')],'sectionId':0xcb});}],'rpcTelephones':['apiResolver',function(_0x5932d2){const _0x2b99b8=_0xfdf345;return _0x5932d2[_0x2b99b8('0xed7')](_0x2b99b8('0x156c'));}]},'authenticate':!![],'permissionId':0x19b})[_0xfdf345('0x2598')](_0xfdf345('0x19d8'),{'url':'/trunks','controller':_0xfdf345('0x167b'),'templateUrl':_0x92040b,'resolve':{'trunks':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x41586c,_0x47230d){const _0x4f044c=_0xfdf345;return _0x47230d['hasRole'](_0x4f044c('0x20c2'))?_0x41586c[_0x4f044c('0xed7')](_0x4f044c('0x18a8'),{'fields':_0x4f044c('0xa10'),'active':!![],'sort':_0x4f044c('0xc36'),'limit':0xa,'offset':0x0}):_0x41586c[_0x4f044c('0xed7')](_0x4f044c('0x191b'),{'id':_0x47230d['getCurrentUser']()['userProfileId'],'section':'Trunks','fields':'id,name','active':!![],'sort':_0x4f044c('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0xfdf345('0x4b1'),'Auth',function(_0x191db3,_0x2f548d){const _0x45f513=_0xfdf345;return _0x2f548d[_0x45f513('0xca1')](_0x45f513('0x20c2'))?null:_0x191db3['resolve']('userProfile@get',{'fields':_0x45f513('0x16f'),'id':_0x2f548d[_0x45f513('0x20b2')]()[_0x45f513('0x2f')]});}],'userProfileSection':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x3ec9cc,_0x4dd4b0){const _0x413e60=_0xfdf345;return _0x4dd4b0[_0x413e60('0xca1')](_0x413e60('0x20c2'))?null:_0x3ec9cc[_0x413e60('0xed7')](_0x413e60('0x360'),{'fields':_0x413e60('0x1f47'),'userProfileId':_0x4dd4b0[_0x413e60('0x20b2')]()[_0x413e60('0x2f')],'sectionId':0x3f3});}],'rpcTrunks':['apiResolver',function(_0x2de456){const _0x3accbb=_0xfdf345;return _0x2de456[_0x3accbb('0xed7')](_0x3accbb('0x1fa9'));}]},'authenticate':!![],'permissionId':0x19b})[_0xfdf345('0x2598')](_0xfdf345('0x1591'),{'url':_0xfdf345('0x14a4'),'controller':_0xfdf345('0x19c4'),'templateUrl':_0x19e562,'resolve':{'queues':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x26e224,_0xc1668b){const _0x26956a=_0xfdf345;return _0xc1668b[_0x26956a('0xca1')](_0x26956a('0x20c2'))?_0x26e224[_0x26956a('0xed7')](_0x26956a('0x2730'),{'type':_0x26956a('0x1535'),'sort':_0x26956a('0xc36'),'limit':0xa,'offset':0x0}):_0x26e224[_0x26956a('0xed7')]('userProfile@getResources',{'id':_0xc1668b[_0x26956a('0x20b2')]()['userProfileId'],'section':'VoiceQueues','channel':_0x26956a('0xcf2'),'type':_0x26956a('0x1535'),'sort':_0x26956a('0xc36'),'limit':0xa,'page':0x1});}],'userProfile':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x4653f5,_0x183e33){const _0x5607f2=_0xfdf345;return _0x183e33['hasRole'](_0x5607f2('0x20c2'))?null:_0x4653f5[_0x5607f2('0xed7')](_0x5607f2('0x1464'),{'fields':_0x5607f2('0x16f'),'id':_0x183e33['getCurrentUser']()[_0x5607f2('0x2f')]});}],'userProfileSection':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0xc4ef87,_0x4a622a){const _0x3256ac=_0xfdf345;return _0x4a622a[_0x3256ac('0xca1')](_0x3256ac('0x20c2'))?null:_0xc4ef87[_0x3256ac('0xed7')]('userProfileSection@get',{'fields':_0x3256ac('0x1f47'),'userProfileId':_0x4a622a[_0x3256ac('0x20b2')]()[_0x3256ac('0x2f')],'sectionId':0x191});}],'rpcQueues':[_0xfdf345('0x4b1'),function(_0x54a469){const _0xc77c81=_0xfdf345;return _0x54a469['resolve'](_0xc77c81('0x1406'));}]},'authenticate':!![],'permissionId':0x19b})[_0xfdf345('0x2598')](_0xfdf345('0x1875'),{'url':_0xfdf345('0x180c'),'controller':_0xfdf345('0x1e6f'),'templateUrl':_0x1f6b76,'resolve':{'agents':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x49c595,_0x3be2f7){const _0x4b3d53=_0xfdf345;return _0x3be2f7[_0x4b3d53('0xca1')]('admin')?_0x49c595['resolve'](_0x4b3d53('0x25c9'),{'fields':_0x4b3d53('0x545'),'role':_0x4b3d53('0x2327'),'nolimit':!![]}):_0x49c595[_0x4b3d53('0xed7')](_0x4b3d53('0x191b'),{'id':_0x3be2f7['getCurrentUser']()['userProfileId'],'section':_0x4b3d53('0x1bc0'),'fields':_0x4b3d53('0x545'),'role':'agent','nolimit':!![]});}],'queues':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x2dec14,_0x1de525){const _0x42fb71=_0xfdf345;return _0x1de525[_0x42fb71('0xca1')]('admin')?_0x2dec14[_0x42fb71('0xed7')](_0x42fb71('0x2730'),{'type':'inbound','sort':'-updatedAt','nolimit':!![]}):_0x2dec14[_0x42fb71('0xed7')](_0x42fb71('0x191b'),{'id':_0x1de525[_0x42fb71('0x20b2')]()['userProfileId'],'section':_0x42fb71('0x88d'),'channel':_0x42fb71('0xcf2'),'type':_0x42fb71('0x1535'),'sort':_0x42fb71('0xc36'),'nolimit':!![]});}],'userProfile':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x2d9257,_0x106bf9){const _0x2422bb=_0xfdf345;return _0x106bf9[_0x2422bb('0xca1')](_0x2422bb('0x20c2'))?null:_0x2d9257[_0x2422bb('0xed7')](_0x2422bb('0x1464'),{'fields':_0x2422bb('0x16f'),'id':_0x106bf9['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0xfdf345('0x4b1'),'Auth',function(_0x9986d8,_0x15bc25){const _0x4f5f29=_0xfdf345;return _0x15bc25['hasRole'](_0x4f5f29('0x20c2'))?null:_0x9986d8[_0x4f5f29('0xed7')](_0x4f5f29('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x15bc25[_0x4f5f29('0x20b2')]()['userProfileId'],'sectionId':0x191});}],'rpcVoiceQueuesChannels':[_0xfdf345('0x4b1'),function(_0x466043){const _0x5ba0e9=_0xfdf345;return _0x466043[_0x5ba0e9('0xed7')](_0x5ba0e9('0x2489'));}]},'authenticate':!![],'permissionId':0x19b})[_0xfdf345('0x2598')](_0xfdf345('0x46e'),{'url':_0xfdf345('0x801'),'controller':_0xfdf345('0x1b9c'),'templateUrl':_0x3871e0,'resolve':{'agents':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x43f77f,_0x2923e1){const _0x44a2a0=_0xfdf345;return _0x2923e1[_0x44a2a0('0xca1')]('admin')?_0x43f77f[_0x44a2a0('0xed7')](_0x44a2a0('0x25c9'),{'fields':_0x44a2a0('0x545'),'role':_0x44a2a0('0x2327'),'nolimit':!![]}):_0x43f77f['resolve'](_0x44a2a0('0x191b'),{'id':_0x2923e1['getCurrentUser']()[_0x44a2a0('0x2f')],'section':_0x44a2a0('0x1bc0'),'fields':_0x44a2a0('0x545'),'role':'agent','nolimit':!![]});}],'queues':[_0xfdf345('0x4b1'),'Auth',function(_0x555807,_0x1c6ad1){const _0x33d938=_0xfdf345;return _0x1c6ad1[_0x33d938('0xca1')](_0x33d938('0x20c2'))?_0x555807[_0x33d938('0xed7')](_0x33d938('0x2730'),{'type':_0x33d938('0x1535'),'sort':'-updatedAt','nolimit':!![]}):_0x555807['resolve']('userProfile@getResources',{'id':_0x1c6ad1['getCurrentUser']()[_0x33d938('0x2f')],'section':_0x33d938('0x88d'),'channel':_0x33d938('0xcf2'),'type':'inbound','sort':_0x33d938('0xc36'),'nolimit':!![]});}],'dispositions':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x26897,_0x2b9e0b){const _0x36052d=_0xfdf345;return _0x2b9e0b[_0x36052d('0xca1')](_0x36052d('0x20c2'))?_0x26897[_0x36052d('0xed7')]('disposition@get',{'fields':_0x36052d('0x311'),'sort':_0x36052d('0xc36'),'MailAccountId':_0x36052d('0x13c'),'FaxAccountId':'null','SmsAccountId':_0x36052d('0x13c'),'WhatsappAccountId':_0x36052d('0x13c'),'OpenchannelAccountId':'null','ChatWebsiteId':_0x36052d('0x13c'),'ListId':_0x36052d('0x13c'),'nolimit':!![]}):_0x26897[_0x36052d('0xed7')]('userProfile@getResources',{'id':_0x2b9e0b[_0x36052d('0x20b2')]()[_0x36052d('0x2f')],'section':_0x36052d('0xf09'),'fields':'createdAt,updatedAt,id,name','sort':'-updatedAt','MailAccountId':_0x36052d('0x13c'),'FaxAccountId':_0x36052d('0x13c'),'SmsAccountId':_0x36052d('0x13c'),'WhatsappAccountId':_0x36052d('0x13c'),'OpenchannelAccountId':_0x36052d('0x13c'),'ChatWebsiteId':_0x36052d('0x13c'),'ListId':_0x36052d('0x13c'),'nolimit':!![]});}],'userProfile':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x1fbdc8,_0x5d0409){const _0x474d42=_0xfdf345;return _0x5d0409[_0x474d42('0xca1')](_0x474d42('0x20c2'))?null:_0x1fbdc8[_0x474d42('0xed7')](_0x474d42('0x1464'),{'fields':_0x474d42('0x16f'),'id':_0x5d0409[_0x474d42('0x20b2')]()[_0x474d42('0x2f')]});}],'userProfileSection':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x261f30,_0x35db32){const _0x203c99=_0xfdf345;return _0x35db32[_0x203c99('0xca1')](_0x203c99('0x20c2'))?null:_0x261f30[_0x203c99('0xed7')](_0x203c99('0x360'),{'fields':_0x203c99('0x1f47'),'userProfileId':_0x35db32['getCurrentUser']()[_0x203c99('0x2f')],'sectionId':0x191});}]},'authenticate':!![],'permissionId':0x19b})[_0xfdf345('0x2598')](_0xfdf345('0x19f3'),{'url':_0xfdf345('0x233'),'controller':_0xfdf345('0x12c9'),'templateUrl':_0x3fa35c,'resolve':{'queues':[_0xfdf345('0x4b1'),'Auth',function(_0x4afdc3,_0x1d550b){const _0x2d97a6=_0xfdf345;return _0x1d550b[_0x2d97a6('0xca1')]('admin')?_0x4afdc3[_0x2d97a6('0xed7')](_0x2d97a6('0x2730'),{'type':_0x2d97a6('0x1535'),'fields':_0x2d97a6('0xa10'),'sort':_0x2d97a6('0xc36'),'limit':0xa,'offset':0x0}):_0x4afdc3[_0x2d97a6('0xed7')](_0x2d97a6('0x191b'),{'id':_0x1d550b[_0x2d97a6('0x20b2')]()[_0x2d97a6('0x2f')],'section':_0x2d97a6('0x88d'),'channel':_0x2d97a6('0xcf2'),'type':_0x2d97a6('0x1535'),'sort':'-updatedAt','nolimit':!![]});}],'userProfile':['apiResolver',_0xfdf345('0xba1'),function(_0x1ba276,_0x151469){const _0x4977d1=_0xfdf345;return _0x151469[_0x4977d1('0xca1')](_0x4977d1('0x20c2'))?null:_0x1ba276[_0x4977d1('0xed7')](_0x4977d1('0x1464'),{'fields':_0x4977d1('0x16f'),'id':_0x151469[_0x4977d1('0x20b2')]()[_0x4977d1('0x2f')]});}],'userProfileSection':[_0xfdf345('0x4b1'),_0xfdf345('0xba1'),function(_0x5e0063,_0x4ed642){const _0x9de7db=_0xfdf345;return _0x4ed642[_0x9de7db('0xca1')]('admin')?null:_0x5e0063[_0x9de7db('0xed7')](_0x9de7db('0x360'),{'fields':_0x9de7db('0x1f47'),'userProfileId':_0x4ed642[_0x9de7db('0x20b2')]()[_0x9de7db('0x2f')],'sectionId':0x191});}],'rpcQueues':[_0xfdf345('0x4b1'),function(_0x3a856e){const _0x1ba27e=_0xfdf345;return _0x3a856e[_0x1ba27e('0xed7')](_0x1ba27e('0x1406'));}]},'authenticate':!![],'permissionId':0x19b})[_0xfdf345('0x2598')]('app.voice.realtime.outbound_calls',{'url':_0xfdf345('0x4a0'),'controller':_0xfdf345('0x511'),'templateUrl':_0x1b6799,'resolve':{'rpcCalls':[_0xfdf345('0x4b1'),function(_0x3c1811){const _0x52ce78=_0xfdf345;return _0x3c1811['resolve'](_0x52ce78('0x172a'));}]},'authenticate':!![],'permissionId':0x19b});}angular[_0x189033('0x1e26')](_0x189033('0x170b'),[])[_0x189033('0x272d')](_0x38d85e)['controller'](_0x189033('0x1922'),_0x388522)[_0x189033('0x1da3')]('AgentsVoiceRealtimeController',_0x2ee005)[_0x189033('0x1da3')](_0x189033('0x888'),_0xe33aee)[_0x189033('0x1da3')]('QueueCallsVoiceRealtimeController',_0x191135)[_0x189033('0x1da3')](_0x189033('0xbc6'),_0x7fce88)[_0x189033('0x1da3')]('QueuesVoiceRealtimeController',_0x366ee8)[_0x189033('0x1f97')](_0x189033('0xa72'),_0x4f6c1b)[_0x189033('0x1da3')]('VoiceRealtimeController',_0x57209e)[_0x189033('0x1da3')](_0x189033('0xfff'),_0x16cfd5)['controller'](_0x189033('0x37'),_0xf46336);const _0x2ff799=_0x180212['p']+_0x189033('0x288f');_0x352bf2[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$window',_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x229b'),_0x189033('0x2a'),_0x189033('0x22df'),'api',_0x189033('0x1cc2'),'toasty',_0x189033('0xba1'),'license','setting'];function _0x352bf2(_0x3145e0,_0x5ac793,_0x4348cf,_0x379ba2,_0xd49bff,_0x13a822,_0x56398c,_0xe8a52b,_0x2833c1,_0x4d4b79,_0x4935ce,_0x119b1a,_0x2d3f25,_0x356e9a,_0x5e4c52,_0x2f5ec1,_0x42bfe4){const _0x12dad8=_0x189033,_0x1a459d=this;_0x1a459d['license']=_0x2f5ec1,_0x1a459d[_0x12dad8('0x260a')]=_0x42bfe4,_0x1a459d[_0x12dad8('0x11ed')]=_0x5e4c52[_0x12dad8('0x20b2')](),_0x1a459d[_0x12dad8('0x229b')]=_0x2833c1||{'count':0x0,'rows':[]},_0x1a459d[_0x12dad8('0x2a')]=_0x4d4b79,_0x1a459d['userProfileSection']=_0x4935ce&&_0x4935ce[_0x12dad8('0x50d')]==0x1?_0x4935ce['rows'][0x0]:null,_0x1a459d[_0x12dad8('0x1134')]=_0x5e4c52['parseCrudPermissions'](_0x1a459d[_0x12dad8('0x22df')]?_0x1a459d['userProfileSection'][_0x12dad8('0x1134')]:null),_0x1a459d[_0x12dad8('0x5c4')]=_0x12dad8('0x229b'),_0x1a459d[_0x12dad8('0x247')]='',_0x1a459d[_0x12dad8('0x1ce2')]=null,_0x1a459d[_0x12dad8('0x264f')]=[],_0x1a459d[_0x12dad8('0x23a2')]={'fields':'createdAt,updatedAt,id,name,prefix,options,auth,password,record,recordingFormat,description','sort':_0x12dad8('0xc36'),'limit':0xa,'page':0x1},_0x1a459d[_0x12dad8('0xc3f')]=_0x2e3ca0()['keyBy']([{'option':_0x12dad8('0x1665'),'value':'\x27b\x27'},{'option':'B:\x20Instead\x20of\x20whispering\x20on\x20a\x20single\x20channel\x20barge\x20in\x20on\x20both\x20channels\x20involved\x20in\x20the\x20call.','value':_0x12dad8('0x193d')},{'option':'E:\x20Exit\x20when\x20the\x20spied-on\x20channel\x20hangs\x20up.','value':'\x27E\x27'},{'option':_0x12dad8('0xbe6'),'value':'\x27o\x27'},{'option':_0x12dad8('0x25bf'),'value':_0x12dad8('0x1145')},{'option':_0x12dad8('0x2b5'),'value':_0x12dad8('0x8fa')},{'option':'S:\x20Stop\x20when\x20no\x20more\x20channels\x20are\x20left\x20to\x20spy\x20on.','value':_0x12dad8('0xbe3')},{'option':_0x12dad8('0x770'),'value':_0x12dad8('0x2154')},{'option':_0x12dad8('0x1159'),'value':_0x12dad8('0x26a1')}],function(_0x334643){const _0x5a4f0a=_0x12dad8;return _0x2e3ca0()[_0x5a4f0a('0x1725')](_0x334643[_0x5a4f0a('0x1c6b')],new RegExp('\x27','g'),'');}),_0x1a459d[_0x12dad8('0x18e0')]=_0x2e3ca0()[_0x12dad8('0x24db')]([{'option':'wav','value':_0x12dad8('0xfb2')},{'option':_0x12dad8('0x1ac0'),'value':_0x12dad8('0x1755')},{'option':_0x12dad8('0x178'),'value':'\x27WAV\x27'}],function(_0x4e3150){const _0x30c9f8=_0x12dad8;return _0x2e3ca0()[_0x30c9f8('0x1725')](_0x4e3150['value'],new RegExp('\x27','g'),'');}),_0x1a459d[_0x12dad8('0x1249')]=_0x972806,_0x1a459d[_0x12dad8('0x194f')]=_0x5ce3ce,_0x1a459d['success']=_0x1aec91,_0x1a459d[_0x12dad8('0x1d4a')]=_0x4a7683,_0x1a459d['createOrEditchanSpy']=_0x1d310d,_0x1a459d[_0x12dad8('0x434')]=_0xb08aac,_0x1a459d[_0x12dad8('0x791')]=_0x1ef61c,_0x1a459d[_0x12dad8('0xbb4')]=_0x555c22,_0x1a459d['deselectChanSpies']=_0x5d70f8,_0x1a459d[_0x12dad8('0x201a')]=_0x2838c7;function _0x972806(_0x45bbc2,_0x4292e9){const _0x5112ae=_0x12dad8;_0xd49bff[_0x5112ae('0x1d4')]({'controller':_0x5112ae('0x881'),'controllerAs':'vm','templateUrl':_0x2ff799,'parent':angular['element'](_0x13a822[_0x5112ae('0x18e5')]),'targetEvent':_0x4292e9,'clickOutsideToClose':!![],'locals':{'chanSpy':_0x45bbc2,'chanSpies':_0x1a459d['chanSpies'][_0x5112ae('0xf5d')],'license':_0x1a459d['license'],'setting':null,'crudPermissions':_0x1a459d[_0x5112ae('0x1134')]}});}function _0x5ce3ce(_0x5bb45d,_0x4e5272){const _0x55fb69=_0x12dad8,_0x438aa5=_0xd49bff[_0x55fb69('0x1c6f')]()[_0x55fb69('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x55fb69('0x1e03')]('chanSpy')+'?')[_0x55fb69('0x26e3')](''+(_0x5bb45d['name']||_0x55fb69('0x10cf'))+_0x55fb69('0x20f1')+_0x55fb69('0x1ee7'))['ariaLabel']('delete\x20chanSpy')[_0x55fb69('0xe42')](_0x4e5272)['ok']('OK')[_0x55fb69('0x19fb')]('CANCEL');_0xd49bff[_0x55fb69('0x1d4')](_0x438aa5)[_0x55fb69('0x683')](function(){_0xb08aac(_0x5bb45d);},function(){const _0x3564ff=_0x55fb69;console['log'](_0x3564ff('0x16b8'));});}let _0x54f2ca=!![],_0x3229d4=0x1;_0x3145e0['$watch'](_0x12dad8('0x1e1d'),function(_0x31a6b1,_0x434368){const _0x5f15c2=_0x12dad8;_0x54f2ca?_0x56398c(function(){_0x54f2ca=![];}):(!_0x434368&&(_0x3229d4=_0x1a459d[_0x5f15c2('0x23a2')]['page']),_0x31a6b1!==_0x434368&&(_0x1a459d[_0x5f15c2('0x23a2')][_0x5f15c2('0xdf8')]=0x1),!_0x31a6b1&&(_0x1a459d[_0x5f15c2('0x23a2')][_0x5f15c2('0xdf8')]=_0x3229d4),_0x1a459d[_0x5f15c2('0x1d4a')]());});function _0x1aec91(_0x1ce256){const _0x2e6bd6=_0x12dad8;_0x1a459d[_0x2e6bd6('0x229b')]=_0x1ce256||{'count':0x0,'rows':[]};}function _0x4a7683(){const _0x5cac17=_0x12dad8;_0x1a459d[_0x5cac17('0x23a2')][_0x5cac17('0x1cc8')]=(_0x1a459d[_0x5cac17('0x23a2')]['page']-0x1)*_0x1a459d[_0x5cac17('0x23a2')][_0x5cac17('0x6f0')],_0x5e4c52[_0x5cac17('0xca1')](_0x5cac17('0x20c2'))?_0x1a459d[_0x5cac17('0x1883')]=_0x119b1a[_0x5cac17('0x1c5f')][_0x5cac17('0x1e6e')](_0x1a459d[_0x5cac17('0x23a2')],_0x1aec91)[_0x5cac17('0xe53')]:(_0x1a459d[_0x5cac17('0x23a2')]['id']=_0x1a459d[_0x5cac17('0x2a')]['id'],_0x1a459d[_0x5cac17('0x23a2')][_0x5cac17('0x1aa')]=_0x5cac17('0x1a6d'),_0x1a459d[_0x5cac17('0x1883')]=_0x119b1a[_0x5cac17('0x2a')]['getResources'](_0x1a459d['query'],_0x1aec91)[_0x5cac17('0xe53')]);}function _0x1d310d(_0x5b44a6,_0x36dbc3){const _0x4e3a6d=_0x12dad8;_0xd49bff['show']({'controller':'CreateOrEditchanSpyDialogController','controllerAs':'vm','templateUrl':_0x2ff799,'parent':angular[_0x4e3a6d('0x1fcc')](_0x13a822[_0x4e3a6d('0x18e5')]),'targetEvent':_0x5b44a6,'clickOutsideToClose':!![],'locals':{'chanSpy':_0x36dbc3,'chanSpies':_0x1a459d['chanSpies'][_0x4e3a6d('0xf5d')],'license':_0x1a459d[_0x4e3a6d('0xace')],'setting':_0x1a459d[_0x4e3a6d('0x260a')],'crudPermissions':_0x1a459d[_0x4e3a6d('0x1134')]}});}function _0xb08aac(_0x3fd2cf){const _0x2162b1=_0x12dad8;_0x119b1a[_0x2162b1('0x1c5f')][_0x2162b1('0xd7e')]({'id':_0x3fd2cf['id']})[_0x2162b1('0xe53')][_0x2162b1('0x683')](function(){const _0x57545b=_0x2162b1;_0x2e3ca0()[_0x57545b('0x3ec')](_0x1a459d[_0x57545b('0x229b')][_0x57545b('0xf5d')],{'id':_0x3fd2cf['id']}),_0x1a459d[_0x57545b('0x229b')][_0x57545b('0x50d')]-=0x1,!_0x1a459d[_0x57545b('0x229b')]['rows'][_0x57545b('0x1564')]&&_0x1a459d['getChanSpies'](),_0x356e9a['success']({'title':_0x2e3ca0()['startCase']('chanSpy')+_0x57545b('0xbfc'),'msg':_0x3fd2cf['name']?_0x3fd2cf[_0x57545b('0x60a')]+_0x57545b('0x194d'):''});})['catch'](function(_0x52a12a){const _0x1195f3=_0x2162b1;if(_0x52a12a['data']&&_0x52a12a[_0x1195f3('0x5a5')][_0x1195f3('0x17f')]&&_0x52a12a[_0x1195f3('0x5a5')]['errors'][_0x1195f3('0x1564')]){_0x1a459d['errors']=_0x52a12a[_0x1195f3('0x5a5')][_0x1195f3('0x17f')]||[{'message':_0x52a12a[_0x1195f3('0x1ff0')](),'type':_0x1195f3('0x344')}];for(let _0x26a8f4=0x0;_0x26a8f4<_0x52a12a[_0x1195f3('0x5a5')][_0x1195f3('0x17f')]['length'];_0x26a8f4++){_0x356e9a[_0x1195f3('0x52a')]({'title':_0x52a12a[_0x1195f3('0x5a5')][_0x1195f3('0x17f')][_0x26a8f4][_0x1195f3('0xcf0')],'msg':_0x52a12a[_0x1195f3('0x5a5')]['errors'][_0x26a8f4]['message']});}}else _0x356e9a[_0x1195f3('0x52a')]({'title':_0x52a12a[_0x1195f3('0x13ee')]?_0x1195f3('0x2168')+_0x52a12a[_0x1195f3('0x13ee')]+_0x1195f3('0xbf6')+_0x52a12a[_0x1195f3('0x24a9')]:_0x1195f3('0x344'),'msg':_0x52a12a['data']?JSON['stringify'](_0x52a12a[_0x1195f3('0x5a5')][_0x1195f3('0x8c2')]):_0x52a12a[_0x1195f3('0x8c2')]||_0x52a12a['toString']()});});}function _0x1ef61c(){const _0x435f90=_0x12dad8,_0x54bb08=angular[_0x435f90('0x1a86')](_0x1a459d[_0x435f90('0x264f')]);return _0x1a459d[_0x435f90('0x264f')]=[],_0x54bb08;}function _0x555c22(_0x3058da){const _0x446e0b=_0x12dad8,_0x2643d0=_0xd49bff[_0x446e0b('0x1c6f')]()[_0x446e0b('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20chanSpies?')['htmlContent'](_0x446e0b('0xed5')+_0x1a459d[_0x446e0b('0x264f')]['length']+'\x20selected'+_0x446e0b('0x1ee7'))[_0x446e0b('0x1040')]('delete\x20chanSpys')[_0x446e0b('0xe42')](_0x3058da)['ok']('OK')[_0x446e0b('0x19fb')](_0x446e0b('0x16b8'));_0xd49bff[_0x446e0b('0x1d4')](_0x2643d0)['then'](function(){const _0x43974b=_0x446e0b;_0x1a459d['selectedChanSpies'][_0x43974b('0x1299')](function(_0x402354){_0xb08aac(_0x402354);}),_0x1a459d[_0x43974b('0x264f')]=[];});}function _0x5d70f8(){_0x1a459d['selectedChanSpies']=[];}function _0x2838c7(){const _0x49863e=_0x12dad8;_0x1a459d[_0x49863e('0x264f')]=_0x1a459d[_0x49863e('0x229b')][_0x49863e('0xf5d')];}}const _0x3cb613=_0x352bf2;_0x1a3a4a['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),'$location','$mdDialog','$q',_0x189033('0x1d08'),'toasty',_0x189033('0x229b'),'chanSpy',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x1a3a4a(_0x3e253b,_0xb643fe,_0x3ee867,_0x3a4723,_0x2efc27,_0x23a0ea,_0x156fef,_0xea74e0,_0x208358,_0x18ead4,_0x3288b7,_0x2af295,_0x53749d,_0x17c0d8){const _0x1731ea=_0x189033,_0x5e9a6c=this;_0x5e9a6c['currentUser']=_0x3288b7['getCurrentUser'](),_0x5e9a6c[_0x1731ea('0x17f')]=[],_0x5e9a6c[_0x1731ea('0x260a')]=_0x53749d,_0x5e9a6c[_0x1731ea('0xace')]=_0x2af295,_0x5e9a6c[_0x1731ea('0x1134')]=_0x17c0d8,_0x5e9a6c[_0x1731ea('0x258d')]={},_0x5e9a6c[_0x1731ea('0x19b2')]=_0x5e9a6c[_0x1731ea('0x260a')]&&_0x5e9a6c[_0x1731ea('0x260a')][_0x1731ea('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5e9a6c[_0x1731ea('0xf28')]=_0x1731ea('0x27e0'),_0x5e9a6c[_0x1731ea('0x10cf')]=angular[_0x1731ea('0x1a86')](_0x208358),_0x5e9a6c['chanSpies']=_0xea74e0,_0x5e9a6c[_0x1731ea('0x1d15')]=![];!_0x5e9a6c[_0x1731ea('0x10cf')]&&(_0x5e9a6c[_0x1731ea('0x10cf')]={'recordingFormat':_0x1731ea('0x1d2a')},_0x5e9a6c[_0x1731ea('0xf28')]=_0x1731ea('0x1ed8'),_0x5e9a6c[_0x1731ea('0x1d15')]=!![]);_0x5e9a6c[_0x1731ea('0x2498')]=_0x53c057,_0x5e9a6c['savechanSpy']=_0x1a86bb,_0x5e9a6c['deletechanSpy']=_0x34a9c2,_0x5e9a6c['getDateFromString']=_0x50ba0b,_0x5e9a6c[_0x1731ea('0xf82')]=_0x32fd58;function _0x53c057(){const _0x4da722=_0x1731ea;_0x5e9a6c[_0x4da722('0x17f')]=[],_0x18ead4['voiceChanSpy'][_0x4da722('0xb0a')](_0x5e9a6c[_0x4da722('0x10cf')])[_0x4da722('0xe53')][_0x4da722('0x683')](function(_0x1cf559){const _0xabe0cb=_0x4da722;_0x5e9a6c[_0xabe0cb('0x229b')]['unshift'](_0x1cf559[_0xabe0cb('0x24e1')]()),_0x156fef['success']({'title':_0xabe0cb('0x2255'),'msg':_0x5e9a6c[_0xabe0cb('0x10cf')][_0xabe0cb('0x60a')]?_0x5e9a6c[_0xabe0cb('0x10cf')]['name']+'\x20has\x20been\x20created!':''}),_0x32fd58(_0x1cf559);})[_0x4da722('0x130a')](function(_0x397eb9){const _0x89ff57=_0x4da722;if(_0x397eb9[_0x89ff57('0x5a5')]&&_0x397eb9['data'][_0x89ff57('0x17f')]&&_0x397eb9['data']['errors'][_0x89ff57('0x1564')]){_0x5e9a6c[_0x89ff57('0x17f')]=_0x397eb9[_0x89ff57('0x5a5')][_0x89ff57('0x17f')]||[{'message':_0x397eb9[_0x89ff57('0x1ff0')](),'type':_0x89ff57('0x2362')}];for(let _0x5eea29=0x0;_0x5eea29<_0x397eb9[_0x89ff57('0x5a5')]['errors']['length'];_0x5eea29+=0x1){_0x156fef['error']({'title':_0x397eb9['data'][_0x89ff57('0x17f')][_0x5eea29][_0x89ff57('0xcf0')],'msg':_0x397eb9[_0x89ff57('0x5a5')][_0x89ff57('0x17f')][_0x5eea29]['message']});}}else _0x156fef[_0x89ff57('0x52a')]({'title':_0x397eb9['status']?_0x89ff57('0x2168')+_0x397eb9[_0x89ff57('0x13ee')]+_0x89ff57('0xbf6')+_0x397eb9['statusText']:'api.voiceChanSpy.save','msg':_0x397eb9['data']?JSON['stringify'](_0x397eb9[_0x89ff57('0x5a5')][_0x89ff57('0x8c2')]):_0x397eb9['toString']()});});}function _0x1a86bb(){const _0x32cd26=_0x1731ea;_0x5e9a6c[_0x32cd26('0x17f')]=[],_0x18ead4[_0x32cd26('0x1c5f')]['update']({'id':_0x5e9a6c['chanSpy']['id']},_0x5e9a6c[_0x32cd26('0x10cf')])[_0x32cd26('0xe53')]['then'](function(_0x2f27a5){const _0x4fbd8a=_0x32cd26,_0x2b70b6=_0x2e3ca0()[_0x4fbd8a('0x1c07')](_0x5e9a6c[_0x4fbd8a('0x229b')],{'id':_0x2f27a5['id']});_0x2b70b6&&_0x2e3ca0()[_0x4fbd8a('0xf22')](_0x2b70b6,_0x2e3ca0()[_0x4fbd8a('0x24d0')](_0x2f27a5[_0x4fbd8a('0x24e1')](),_0x2e3ca0()[_0x4fbd8a('0x55e')](_0x2b70b6))),_0x156fef['success']({'title':_0x4fbd8a('0x559'),'msg':_0x5e9a6c['chanSpy'][_0x4fbd8a('0x60a')]?_0x5e9a6c[_0x4fbd8a('0x10cf')][_0x4fbd8a('0x60a')]+_0x4fbd8a('0xf59'):''}),_0x32fd58(_0x2f27a5);})[_0x32cd26('0x130a')](function(_0x36806c){const _0x45c457=_0x32cd26;if(_0x36806c[_0x45c457('0x5a5')]&&_0x36806c['data']['errors']&&_0x36806c['data']['errors'][_0x45c457('0x1564')]){_0x5e9a6c[_0x45c457('0x17f')]=_0x36806c[_0x45c457('0x5a5')][_0x45c457('0x17f')]||[{'message':_0x36806c['toString'](),'type':_0x45c457('0xe54')}];for(let _0x4190d9=0x0;_0x4190d9<_0x36806c['data'][_0x45c457('0x17f')][_0x45c457('0x1564')];_0x4190d9++){_0x156fef[_0x45c457('0x52a')]({'title':_0x36806c[_0x45c457('0x5a5')][_0x45c457('0x17f')][_0x4190d9][_0x45c457('0xcf0')],'msg':_0x36806c['data'][_0x45c457('0x17f')][_0x4190d9][_0x45c457('0x8c2')]});}}else _0x156fef[_0x45c457('0x52a')]({'title':_0x36806c[_0x45c457('0x13ee')]?_0x45c457('0x2168')+_0x36806c['status']+_0x45c457('0xbf6')+_0x36806c[_0x45c457('0x24a9')]:'api.voiceChanSpy.update','msg':_0x36806c[_0x45c457('0x5a5')]?JSON[_0x45c457('0x258a')](_0x36806c[_0x45c457('0x5a5')]['message']):_0x36806c[_0x45c457('0x1ff0')]()});});}function _0x34a9c2(_0x28f255){const _0x1b594d=_0x1731ea;_0x5e9a6c['errors']=[];const _0x4910e2=_0x3a4723[_0x1b594d('0x1c6f')]()['title'](_0x1b594d('0x4d'))['content']('The\x20chanSpy\x20will\x20be\x20deleted.')['ariaLabel'](_0x1b594d('0x14eb'))['ok'](_0x1b594d('0x2307'))[_0x1b594d('0x19fb')]('Cancel')['targetEvent'](_0x28f255);_0x3a4723[_0x1b594d('0x1d4')](_0x4910e2)[_0x1b594d('0x683')](function(){const _0x31c2cc=_0x1b594d;_0x18ead4[_0x31c2cc('0x1c5f')][_0x31c2cc('0xd7e')]({'id':_0x5e9a6c['chanSpy']['id']})[_0x31c2cc('0xe53')][_0x31c2cc('0x683')](function(){const _0xb662d0=_0x31c2cc;_0x2e3ca0()[_0xb662d0('0x3ec')](_0x5e9a6c[_0xb662d0('0x229b')],{'id':_0x5e9a6c[_0xb662d0('0x10cf')]['id']}),_0x156fef[_0xb662d0('0x53')]({'title':_0xb662d0('0x1530'),'msg':(_0x5e9a6c['chanSpy'][_0xb662d0('0x60a')]||_0xb662d0('0x10cf'))+_0xb662d0('0x194d')}),_0x32fd58(_0x5e9a6c[_0xb662d0('0x10cf')]);})[_0x31c2cc('0x130a')](function(_0x2d9393){const _0x3616fd=_0x31c2cc;if(_0x2d9393[_0x3616fd('0x5a5')]&&_0x2d9393[_0x3616fd('0x5a5')][_0x3616fd('0x17f')]&&_0x2d9393[_0x3616fd('0x5a5')][_0x3616fd('0x17f')][_0x3616fd('0x1564')]){_0x5e9a6c[_0x3616fd('0x17f')]=_0x2d9393[_0x3616fd('0x5a5')][_0x3616fd('0x17f')]||[{'message':_0x2d9393['toString'](),'type':_0x3616fd('0x22af')}];for(let _0x256c70=0x0;_0x256c70<_0x2d9393[_0x3616fd('0x5a5')][_0x3616fd('0x17f')][_0x3616fd('0x1564')];_0x256c70++){_0x156fef[_0x3616fd('0x52a')]({'title':_0x2d9393[_0x3616fd('0x5a5')][_0x3616fd('0x17f')][_0x256c70][_0x3616fd('0xcf0')],'msg':_0x2d9393[_0x3616fd('0x5a5')][_0x3616fd('0x17f')][_0x256c70][_0x3616fd('0x8c2')]});}}else _0x156fef[_0x3616fd('0x52a')]({'title':_0x2d9393[_0x3616fd('0x13ee')]?_0x3616fd('0x2168')+_0x2d9393[_0x3616fd('0x13ee')]+_0x3616fd('0xbf6')+_0x2d9393['statusText']:_0x3616fd('0x22af'),'msg':_0x2d9393[_0x3616fd('0x5a5')]?JSON[_0x3616fd('0x258a')](_0x2d9393[_0x3616fd('0x5a5')][_0x3616fd('0x8c2')]):_0x2d9393[_0x3616fd('0x8c2')]||_0x2d9393['toString']()});});},function(){});}function _0x50ba0b(_0x41f4ea){return _0x41f4ea===null?undefined:new Date(_0x41f4ea);}function _0x32fd58(_0x3b0661){const _0x5e4302=_0x1731ea;_0x3a4723[_0x5e4302('0x1715')](_0x3b0661);}}const _0x49036e=_0x1a3a4a,_0x47a600=_0x180212['p']+_0x189033('0x140a');_0x2372a1[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),_0x189033('0x1d08'),'contexts','userProfile','userProfileSection','api',_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),'license','setting'];function _0x2372a1(_0x3f3d2a,_0x1f0f8f,_0x1a3f59,_0x504647,_0x26b5b0,_0x52f780,_0x265b67,_0x3d6d48,_0x13215c,_0x32d93a,_0x200924,_0x19815f,_0x30d7d2,_0x2caad2,_0x260218,_0x251436,_0x49f14e){const _0x310be1=_0x189033,_0x255384=this;_0x255384[_0x310be1('0xace')]=_0x251436,_0x255384[_0x310be1('0x260a')]=_0x49f14e,_0x255384[_0x310be1('0x11ed')]=_0x260218[_0x310be1('0x20b2')](),_0x255384[_0x310be1('0x1693')]=_0x13215c||{'count':0x0,'rows':[]},_0x255384[_0x310be1('0x2a')]=_0x32d93a,_0x255384[_0x310be1('0x22df')]=_0x200924&&_0x200924['count']==0x1?_0x200924[_0x310be1('0xf5d')][0x0]:null,_0x255384[_0x310be1('0x1134')]=_0x260218[_0x310be1('0x142a')](_0x255384[_0x310be1('0x22df')]?_0x255384[_0x310be1('0x22df')][_0x310be1('0x1134')]:null),_0x255384['table']=_0x310be1('0x1693'),_0x255384[_0x310be1('0x247')]='',_0x255384[_0x310be1('0x1ce2')]=null,_0x255384[_0x310be1('0x717')]=[],_0x255384['query']={'fields':'createdAt,updatedAt,id,name,description','sort':_0x310be1('0xc36'),'defaultEntry':_0x310be1('0x22bf'),'limit':0xa,'page':0x1},_0x255384[_0x310be1('0x1249')]=_0xca8efb,_0x255384[_0x310be1('0x194f')]=_0x1f48a2,_0x255384[_0x310be1('0x53')]=_0x14b826,_0x255384[_0x310be1('0x8a7')]=_0x34feb3,_0x255384[_0x310be1('0x119f')]=_0x25ba9a,_0x255384['deleteContext']=_0x3369d7,_0x255384['exportSelectedContexts']=_0x1ebd7e,_0x255384[_0x310be1('0xfee')]=_0xbe3355,_0x255384[_0x310be1('0xb4e')]=_0xec162d,_0x255384[_0x310be1('0x10e7')]=_0x2efa3e;function _0xca8efb(_0xad24a6,_0x29e2f2){const _0x50fa90=_0x310be1;_0x26b5b0[_0x50fa90('0x1d4')]({'controller':_0x50fa90('0x14ae'),'controllerAs':'vm','templateUrl':_0x47a600,'parent':angular[_0x50fa90('0x1fcc')](_0x52f780[_0x50fa90('0x18e5')]),'targetEvent':_0x29e2f2,'clickOutsideToClose':!![],'locals':{'context':_0xad24a6,'contexts':_0x255384[_0x50fa90('0x1693')][_0x50fa90('0xf5d')],'license':_0x255384[_0x50fa90('0xace')],'setting':null,'crudPermissions':_0x255384[_0x50fa90('0x1134')]}});}function _0x1f48a2(_0x5b45a3,_0x18abf9){const _0x5420ff=_0x310be1,_0x3dac9a=_0x26b5b0['confirm']()[_0x5420ff('0xf28')](_0x5420ff('0x1b01')+_0x2e3ca0()[_0x5420ff('0x1e03')](_0x5420ff('0x22d3'))+'?')[_0x5420ff('0x26e3')](_0x5420ff('0xed5')+(_0x5b45a3['name']||_0x5420ff('0x22d3'))+_0x5420ff('0x20f1')+_0x5420ff('0x1ee7'))['ariaLabel'](_0x5420ff('0x1bc5'))['targetEvent'](_0x18abf9)['ok']('OK')[_0x5420ff('0x19fb')](_0x5420ff('0x16b8'));_0x26b5b0['show'](_0x3dac9a)[_0x5420ff('0x683')](function(){_0x3369d7(_0x5b45a3);},function(){const _0x3bc5c6=_0x5420ff;console[_0x3bc5c6('0x1b2b')](_0x3bc5c6('0x16b8'));});}let _0x147727=!![],_0x507102=0x1;_0x3f3d2a['$watch'](_0x310be1('0x1e1d'),function(_0x47106b,_0x438445){const _0x43777f=_0x310be1;_0x147727?_0x265b67(function(){_0x147727=![];}):(!_0x438445&&(_0x507102=_0x255384[_0x43777f('0x23a2')]['page']),_0x47106b!==_0x438445&&(_0x255384[_0x43777f('0x23a2')][_0x43777f('0xdf8')]=0x1),!_0x47106b&&(_0x255384['query']['page']=_0x507102),_0x255384[_0x43777f('0x8a7')]());});function _0x14b826(_0x39e2f6){_0x255384['contexts']=_0x39e2f6||{'count':0x0,'rows':[]};}function _0x34feb3(){const _0x90800e=_0x310be1;_0x255384['query'][_0x90800e('0x1cc8')]=(_0x255384['query'][_0x90800e('0xdf8')]-0x1)*_0x255384[_0x90800e('0x23a2')][_0x90800e('0x6f0')],_0x260218['hasRole'](_0x90800e('0x20c2'))?_0x255384[_0x90800e('0x1883')]=_0x19815f[_0x90800e('0x1e4d')][_0x90800e('0x1e6e')](_0x255384[_0x90800e('0x23a2')],_0x14b826)[_0x90800e('0xe53')]:(_0x255384[_0x90800e('0x23a2')]['id']=_0x255384[_0x90800e('0x2a')]['id'],_0x255384['query']['section']=_0x90800e('0x929'),_0x255384[_0x90800e('0x1883')]=_0x19815f[_0x90800e('0x2a')]['getResources'](_0x255384[_0x90800e('0x23a2')],_0x14b826)[_0x90800e('0xe53')]);}function _0x25ba9a(_0x3d39ca,_0x3000b4){const _0xeeb6a3=_0x310be1;_0x26b5b0[_0xeeb6a3('0x1d4')]({'controller':_0xeeb6a3('0x14ae'),'controllerAs':'vm','templateUrl':_0x47a600,'parent':angular[_0xeeb6a3('0x1fcc')](_0x52f780['body']),'targetEvent':_0x3d39ca,'clickOutsideToClose':!![],'locals':{'context':_0x3000b4,'contexts':_0x255384[_0xeeb6a3('0x1693')][_0xeeb6a3('0xf5d')],'license':_0x255384[_0xeeb6a3('0xace')],'setting':_0x255384[_0xeeb6a3('0x260a')],'crudPermissions':_0x255384[_0xeeb6a3('0x1134')]}});}function _0x3369d7(_0xf687f6){const _0x52b366=_0x310be1;_0x19815f[_0x52b366('0x1e4d')][_0x52b366('0xd7e')]({'id':_0xf687f6['id']})[_0x52b366('0xe53')]['then'](function(){const _0x3c7e62=_0x52b366;_0x2e3ca0()[_0x3c7e62('0x3ec')](_0x255384[_0x3c7e62('0x1693')][_0x3c7e62('0xf5d')],{'id':_0xf687f6['id']}),_0x255384[_0x3c7e62('0x1693')][_0x3c7e62('0x50d')]-=0x1,!_0x255384[_0x3c7e62('0x1693')][_0x3c7e62('0xf5d')]['length']&&_0x255384[_0x3c7e62('0x8a7')](),_0x2caad2['success']({'title':_0x2e3ca0()['startCase'](_0x3c7e62('0x265'))+_0x3c7e62('0xbfc'),'msg':_0xf687f6['name']?_0xf687f6[_0x3c7e62('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0x52b366('0x130a')](function(_0x5abbf9){const _0x51f6b6=_0x52b366;if(_0x5abbf9[_0x51f6b6('0x5a5')]&&_0x5abbf9[_0x51f6b6('0x5a5')][_0x51f6b6('0x17f')]&&_0x5abbf9[_0x51f6b6('0x5a5')]['errors'][_0x51f6b6('0x1564')]){_0x255384[_0x51f6b6('0x17f')]=_0x5abbf9[_0x51f6b6('0x5a5')][_0x51f6b6('0x17f')]||[{'message':_0x5abbf9[_0x51f6b6('0x1ff0')](),'type':'SYSTEM:DELETEvoiceContext'}];for(let _0x2344d7=0x0;_0x2344d7<_0x5abbf9[_0x51f6b6('0x5a5')][_0x51f6b6('0x17f')][_0x51f6b6('0x1564')];_0x2344d7++){_0x2caad2['error']({'title':_0x5abbf9[_0x51f6b6('0x5a5')]['errors'][_0x2344d7]['type'],'msg':_0x5abbf9[_0x51f6b6('0x5a5')][_0x51f6b6('0x17f')][_0x2344d7]['message']});}}else _0x2caad2['error']({'title':_0x5abbf9[_0x51f6b6('0x13ee')]?_0x51f6b6('0x2168')+_0x5abbf9[_0x51f6b6('0x13ee')]+'\x20-\x20'+_0x5abbf9[_0x51f6b6('0x24a9')]:_0x51f6b6('0x249b'),'msg':_0x5abbf9[_0x51f6b6('0x5a5')]?JSON[_0x51f6b6('0x258a')](_0x5abbf9[_0x51f6b6('0x5a5')]['message']):_0x5abbf9['message']||_0x5abbf9['toString']()});});}function _0x1ebd7e(){const _0x408035=_0x310be1,_0x3d5d39=angular[_0x408035('0x1a86')](_0x255384[_0x408035('0x717')]);return _0x255384[_0x408035('0x717')]=[],_0x3d5d39;}function _0xbe3355(_0x40a69a){const _0x343baa=_0x310be1,_0x574c61=_0x26b5b0[_0x343baa('0x1c6f')]()[_0x343baa('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20contexts?')[_0x343baa('0x26e3')](''+_0x255384['selectedContexts']['length']+_0x343baa('0x93c')+_0x343baa('0x1ee7'))[_0x343baa('0x1040')](_0x343baa('0xe82'))['targetEvent'](_0x40a69a)['ok']('OK')[_0x343baa('0x19fb')](_0x343baa('0x16b8'));_0x26b5b0['show'](_0x574c61)[_0x343baa('0x683')](function(){const _0x456929=_0x343baa;_0x255384[_0x456929('0x717')][_0x456929('0x1299')](function(_0x2e083d){_0x3369d7(_0x2e083d);}),_0x255384[_0x456929('0x717')]=[];});}function _0xec162d(){const _0x5bf6eb=_0x310be1;_0x255384[_0x5bf6eb('0x717')]=[];}function _0x2efa3e(){const _0x5f504d=_0x310be1;_0x255384['selectedContexts']=_0x255384[_0x5f504d('0x1693')][_0x5f504d('0xf5d')];}}const _0x5965f7=_0x2372a1;_0x5d7152['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x1693'),'context',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x5d7152(_0x4f7d19,_0x2dd248,_0x182b88,_0x550fdd,_0x58fbec,_0x2489d6,_0xfe5b88,_0x30b6e0,_0x47d660,_0xbf5ba8,_0x448dc0,_0x53b123,_0x37863a,_0x4ac3aa){const _0x2d68c2=_0x189033,_0x2fbdcb=this;_0x2fbdcb[_0x2d68c2('0x11ed')]=_0x448dc0[_0x2d68c2('0x20b2')](),_0x2fbdcb[_0x2d68c2('0x17f')]=[],_0x2fbdcb[_0x2d68c2('0x260a')]=_0x37863a,_0x2fbdcb[_0x2d68c2('0xace')]=_0x53b123,_0x2fbdcb[_0x2d68c2('0x1134')]=_0x4ac3aa,_0x2fbdcb[_0x2d68c2('0x258d')]={},_0x2fbdcb['passwordPattern']=_0x2fbdcb[_0x2d68c2('0x260a')]&&_0x2fbdcb[_0x2d68c2('0x260a')][_0x2d68c2('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2fbdcb[_0x2d68c2('0xf28')]='VOICE.EDIT_CONTEXT',_0x2fbdcb[_0x2d68c2('0x22d3')]=angular[_0x2d68c2('0x1a86')](_0x47d660),_0x2fbdcb[_0x2d68c2('0x1693')]=_0x30b6e0,_0x2fbdcb[_0x2d68c2('0x332')]=![];!_0x2fbdcb[_0x2d68c2('0x22d3')]&&(_0x2fbdcb['context']={},_0x2fbdcb[_0x2d68c2('0xf28')]=_0x2d68c2('0x1979'),_0x2fbdcb[_0x2d68c2('0x332')]=!![]);_0x2fbdcb[_0x2d68c2('0x11ea')]=_0x112c37,_0x2fbdcb[_0x2d68c2('0x1c29')]=_0x157a5f,_0x2fbdcb[_0x2d68c2('0x2128')]=_0x19a6c7,_0x2fbdcb[_0x2d68c2('0x16b3')]=_0x2651f4,_0x2fbdcb[_0x2d68c2('0xf82')]=_0x3d9606;function _0x112c37(){const _0x4fa16b=_0x2d68c2;_0x2fbdcb['errors']=[],_0xbf5ba8[_0x4fa16b('0x1e4d')][_0x4fa16b('0xb0a')](_0x2fbdcb[_0x4fa16b('0x22d3')])['$promise'][_0x4fa16b('0x683')](function(_0x65ef6){const _0xdda431=_0x4fa16b;_0x2fbdcb['contexts']['unshift'](_0x65ef6['toJSON']()),_0xfe5b88[_0xdda431('0x53')]({'title':_0xdda431('0x1846'),'msg':_0x2fbdcb[_0xdda431('0x22d3')][_0xdda431('0x60a')]?_0x2fbdcb[_0xdda431('0x22d3')][_0xdda431('0x60a')]+_0xdda431('0x14b5'):''}),_0x3d9606(_0x65ef6);})[_0x4fa16b('0x130a')](function(_0x29104e){const _0x507809=_0x4fa16b;if(_0x29104e['data']&&_0x29104e[_0x507809('0x5a5')][_0x507809('0x17f')]&&_0x29104e[_0x507809('0x5a5')][_0x507809('0x17f')][_0x507809('0x1564')]){_0x2fbdcb['errors']=_0x29104e['data'][_0x507809('0x17f')]||[{'message':_0x29104e[_0x507809('0x1ff0')](),'type':_0x507809('0x2485')}];for(let _0x3ea46a=0x0;_0x3ea46a<_0x29104e['data'][_0x507809('0x17f')][_0x507809('0x1564')];_0x3ea46a+=0x1){_0xfe5b88[_0x507809('0x52a')]({'title':_0x29104e['data'][_0x507809('0x17f')][_0x3ea46a][_0x507809('0xcf0')],'msg':_0x29104e[_0x507809('0x5a5')][_0x507809('0x17f')][_0x3ea46a][_0x507809('0x8c2')]});}}else _0xfe5b88['error']({'title':_0x29104e[_0x507809('0x13ee')]?_0x507809('0x2168')+_0x29104e['status']+'\x20-\x20'+_0x29104e[_0x507809('0x24a9')]:_0x507809('0x2485'),'msg':_0x29104e[_0x507809('0x5a5')]?JSON['stringify'](_0x29104e['data'][_0x507809('0x8c2')]):_0x29104e[_0x507809('0x1ff0')]()});});}function _0x157a5f(){const _0x2ca74f=_0x2d68c2;_0x2fbdcb[_0x2ca74f('0x17f')]=[],_0xbf5ba8['voiceContext'][_0x2ca74f('0x2480')]({'id':_0x2fbdcb[_0x2ca74f('0x22d3')]['id']},_0x2fbdcb['context'])[_0x2ca74f('0xe53')][_0x2ca74f('0x683')](function(_0x3f913d){const _0x2546a0=_0x2ca74f,_0x8dbdee=_0x2e3ca0()[_0x2546a0('0x1c07')](_0x2fbdcb['contexts'],{'id':_0x3f913d['id']});_0x8dbdee&&_0x2e3ca0()[_0x2546a0('0xf22')](_0x8dbdee,_0x2e3ca0()['pick'](_0x3f913d[_0x2546a0('0x24e1')](),_0x2e3ca0()[_0x2546a0('0x55e')](_0x8dbdee))),_0xfe5b88[_0x2546a0('0x53')]({'title':_0x2546a0('0x15f8'),'msg':_0x2fbdcb[_0x2546a0('0x22d3')][_0x2546a0('0x60a')]?_0x2fbdcb[_0x2546a0('0x22d3')]['name']+_0x2546a0('0xf59'):''}),_0x3d9606(_0x3f913d);})[_0x2ca74f('0x130a')](function(_0x53b203){const _0x5d9090=_0x2ca74f;if(_0x53b203['data']&&_0x53b203[_0x5d9090('0x5a5')]['errors']&&_0x53b203[_0x5d9090('0x5a5')][_0x5d9090('0x17f')]['length']){_0x2fbdcb['errors']=_0x53b203[_0x5d9090('0x5a5')][_0x5d9090('0x17f')]||[{'message':_0x53b203['toString'](),'type':'api.voiceContext.update'}];for(let _0x4d8d6a=0x0;_0x4d8d6a<_0x53b203['data']['errors']['length'];_0x4d8d6a++){_0xfe5b88['error']({'title':_0x53b203[_0x5d9090('0x5a5')][_0x5d9090('0x17f')][_0x4d8d6a][_0x5d9090('0xcf0')],'msg':_0x53b203[_0x5d9090('0x5a5')][_0x5d9090('0x17f')][_0x4d8d6a][_0x5d9090('0x8c2')]});}}else _0xfe5b88[_0x5d9090('0x52a')]({'title':_0x53b203[_0x5d9090('0x13ee')]?_0x5d9090('0x2168')+_0x53b203['status']+_0x5d9090('0xbf6')+_0x53b203['statusText']:_0x5d9090('0x108b'),'msg':_0x53b203[_0x5d9090('0x5a5')]?JSON[_0x5d9090('0x258a')](_0x53b203['data'][_0x5d9090('0x8c2')]):_0x53b203[_0x5d9090('0x1ff0')]()});});}function _0x19a6c7(_0x4fa60e){const _0x2f6c50=_0x2d68c2;_0x2fbdcb[_0x2f6c50('0x17f')]=[];const _0x296dec=_0x550fdd['confirm']()[_0x2f6c50('0xf28')](_0x2f6c50('0x4d'))[_0x2f6c50('0xa6a')](_0x2f6c50('0x25d2'))[_0x2f6c50('0x1040')]('Delete\x20Context')['ok'](_0x2f6c50('0x2307'))[_0x2f6c50('0x19fb')](_0x2f6c50('0x253a'))[_0x2f6c50('0xe42')](_0x4fa60e);_0x550fdd['show'](_0x296dec)[_0x2f6c50('0x683')](function(){const _0x2a4954=_0x2f6c50;_0xbf5ba8[_0x2a4954('0x1e4d')][_0x2a4954('0xd7e')]({'id':_0x2fbdcb[_0x2a4954('0x22d3')]['id']})['$promise'][_0x2a4954('0x683')](function(){const _0x35e0ed=_0x2a4954;_0x2e3ca0()[_0x35e0ed('0x3ec')](_0x2fbdcb[_0x35e0ed('0x1693')],{'id':_0x2fbdcb[_0x35e0ed('0x22d3')]['id']}),_0xfe5b88[_0x35e0ed('0x53')]({'title':_0x35e0ed('0x1ef0'),'msg':(_0x2fbdcb[_0x35e0ed('0x22d3')]['name']||_0x35e0ed('0x22d3'))+_0x35e0ed('0x194d')}),_0x3d9606(_0x2fbdcb[_0x35e0ed('0x22d3')]);})[_0x2a4954('0x130a')](function(_0x157732){const _0x443e4d=_0x2a4954;if(_0x157732['data']&&_0x157732[_0x443e4d('0x5a5')][_0x443e4d('0x17f')]&&_0x157732['data']['errors'][_0x443e4d('0x1564')]){_0x2fbdcb[_0x443e4d('0x17f')]=_0x157732[_0x443e4d('0x5a5')]['errors']||[{'message':_0x157732[_0x443e4d('0x1ff0')](),'type':_0x443e4d('0xf5e')}];for(let _0x1165c7=0x0;_0x1165c7<_0x157732[_0x443e4d('0x5a5')][_0x443e4d('0x17f')]['length'];_0x1165c7++){_0xfe5b88['error']({'title':_0x157732['data'][_0x443e4d('0x17f')][_0x1165c7][_0x443e4d('0xcf0')],'msg':_0x157732[_0x443e4d('0x5a5')]['errors'][_0x1165c7][_0x443e4d('0x8c2')]});}}else _0xfe5b88['error']({'title':_0x157732[_0x443e4d('0x13ee')]?_0x443e4d('0x2168')+_0x157732['status']+'\x20-\x20'+_0x157732['statusText']:_0x443e4d('0xf5e'),'msg':_0x157732[_0x443e4d('0x5a5')]?JSON[_0x443e4d('0x258a')](_0x157732[_0x443e4d('0x5a5')][_0x443e4d('0x8c2')]):_0x157732[_0x443e4d('0x8c2')]||_0x157732['toString']()});});},function(){});}function _0x2651f4(_0x34a107){return _0x34a107===null?undefined:new Date(_0x34a107);}function _0x3d9606(_0xacf36d){const _0x63f03b=_0x2d68c2;_0x550fdd[_0x63f03b('0x1715')](_0xacf36d);}}const _0x123221=_0x5d7152;_0x131625[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x1f17'),'inboundroute',_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x131625(_0x5ecf94,_0x55a900,_0x536597,_0x40819c,_0x70a169,_0x3b9428,_0x51747d,_0x455736,_0x3462b7,_0x410e63,_0x50a93f,_0x4db315,_0xaa384e,_0x3d752e){const _0xc7b143=_0x189033,_0x64e9f1=this;_0x64e9f1[_0xc7b143('0x11ed')]=_0x50a93f['getCurrentUser'](),_0x64e9f1[_0xc7b143('0x17f')]=[],_0x64e9f1[_0xc7b143('0x260a')]=_0xaa384e,_0x64e9f1[_0xc7b143('0xace')]=_0x4db315,_0x64e9f1[_0xc7b143('0x1134')]=_0x3d752e,_0x64e9f1[_0xc7b143('0x258d')]={},_0x64e9f1[_0xc7b143('0x19b2')]=_0x64e9f1[_0xc7b143('0x260a')]&&_0x64e9f1[_0xc7b143('0x260a')][_0xc7b143('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x64e9f1[_0xc7b143('0xf28')]=_0xc7b143('0xf08'),_0x64e9f1['inboundroute']=angular[_0xc7b143('0x1a86')](_0x3462b7),_0x64e9f1['inboundroutes']=_0x455736,_0x64e9f1[_0xc7b143('0x23e7')]=![];!_0x64e9f1[_0xc7b143('0xff1')]&&(_0x64e9f1[_0xc7b143('0xff1')]={'appdata':_0xc7b143('0x1f53'),'type':_0xc7b143('0x1535'),'context':'from-voip-provider'},_0x64e9f1[_0xc7b143('0xf28')]=_0xc7b143('0x987'),_0x64e9f1['newInboundRoute']=!![]);_0x64e9f1[_0xc7b143('0xa5')]=_0x566e2d,_0x64e9f1[_0xc7b143('0x39b')]=_0xd0c504,_0x64e9f1[_0xc7b143('0x1981')]=_0x3b3a1d,_0x64e9f1[_0xc7b143('0x16b3')]=_0x4d0084,_0x64e9f1[_0xc7b143('0xf82')]=_0x58efe8,_0x50a93f['hasRole'](_0xc7b143('0x20c2'))?_0x410e63['voiceContext'][_0xc7b143('0x1e6e')]({'fields':_0xc7b143('0xa10'),'sort':_0xc7b143('0x60a'),'nolimit':_0xc7b143('0x26ac')})[_0xc7b143('0xe53')][_0xc7b143('0x683')](function(_0x5e8a92){const _0x5b48cc=_0xc7b143;_0x64e9f1['contexts']=_0x5e8a92[_0x5b48cc('0xf5d')]||[];})[_0xc7b143('0x130a')](function(_0x441d8c){const _0x3b9fba=_0xc7b143;_0x51747d[_0x3b9fba('0x52a')]({'title':_0x441d8c[_0x3b9fba('0x13ee')]?_0x3b9fba('0x2168')+_0x441d8c['status']+'\x20-\x20'+_0x441d8c[_0x3b9fba('0x24a9')]:_0x3b9fba('0x1379'),'msg':_0x441d8c[_0x3b9fba('0x5a5')]?JSON[_0x3b9fba('0x258a')](_0x441d8c[_0x3b9fba('0x5a5')]):_0x441d8c[_0x3b9fba('0x1ff0')]()});}):_0x410e63[_0xc7b143('0x1e4d')][_0xc7b143('0x1e6e')]({'fields':_0xc7b143('0xa10'),'sort':_0xc7b143('0x60a'),'nolimit':_0xc7b143('0x26ac')})[_0xc7b143('0xe53')][_0xc7b143('0x683')](function(_0x47744c){const _0x1a3495=_0xc7b143;_0x64e9f1[_0x1a3495('0x1693')]=_0x47744c['rows']||[];})[_0xc7b143('0x683')](function(){const _0x2ec84b=_0xc7b143;return _0x410e63[_0x2ec84b('0x22df')][_0x2ec84b('0x1e6e')]({'userProfileId':_0x64e9f1[_0x2ec84b('0x11ed')]['userProfileId'],'sectionId':0x195})[_0x2ec84b('0xe53')];})[_0xc7b143('0x683')](function(_0x31eb3f){const _0x2980c8=_0xc7b143,_0x19d6f2=_0x31eb3f&&_0x31eb3f['rows']?_0x31eb3f[_0x2980c8('0xf5d')][0x0]:null;if(!_0x19d6f2)return _0x410e63['voiceContext'][_0x2980c8('0x1e6e')]({'fields':_0x2980c8('0xa10'),'sort':'name','nolimit':_0x2980c8('0x26ac'),'defaultEntry':0x1})[_0x2980c8('0xe53')][_0x2980c8('0x683')](function(_0x96bc0b){const _0x4863b1=_0x2980c8;_0x64e9f1[_0x4863b1('0x1693')]=_0x96bc0b[_0x4863b1('0xf5d')]||[];});else{if(!_0x19d6f2['autoAssociation'])return _0x410e63[_0x2980c8('0xcf7')][_0x2980c8('0x1e6e')]({'sectionId':_0x19d6f2['id']})['$promise'][_0x2980c8('0x683')](function(_0x3854c9){const _0xa40c0e=_0x2980c8,_0x4d86c5=_0x2e3ca0()[_0xa40c0e('0x386')](_0x3854c9[_0xa40c0e('0xf5d')],function(_0x5ae5de){const _0x21b860=_0xa40c0e;return _0x2e3ca0()[_0x21b860('0x1c07')](_0x64e9f1['contexts'],{'id':_0x5ae5de[_0x21b860('0x832')]});});let _0x2a66fd=null;_0x64e9f1[_0xa40c0e('0xff1')]&&(_0x2a66fd=_0x2e3ca0()[_0xa40c0e('0x1c07')](_0x64e9f1['contexts'],{'name':_0x64e9f1['inboundroute']['context']}));if(_0x2a66fd&&!_0x2e3ca0()['some'](_0x4d86c5,['id',_0x2a66fd['id']])){const _0x27796e=_0x2e3ca0()[_0xa40c0e('0x1c07')](_0x64e9f1[_0xa40c0e('0x1693')],{'id':_0x2a66fd['id']});_0x27796e[_0xa40c0e('0x319')]=![],_0x4d86c5['push'](_0x27796e);}_0x64e9f1[_0xa40c0e('0x1693')]=_0x4d86c5;});}})[_0xc7b143('0x130a')](function(_0x22cfb9){const _0x152227=_0xc7b143;_0x51747d[_0x152227('0x52a')]({'title':_0x22cfb9[_0x152227('0x13ee')]?_0x152227('0x2168')+_0x22cfb9[_0x152227('0x13ee')]+_0x152227('0xbf6')+_0x22cfb9['statusText']:'SYSTEM:GETcontexts','msg':_0x22cfb9[_0x152227('0x5a5')]?JSON[_0x152227('0x258a')](_0x22cfb9['data']):_0x22cfb9[_0x152227('0x1ff0')]()});});function _0x566e2d(){const _0x15c7d7=_0xc7b143;_0x64e9f1[_0x15c7d7('0x17f')]=[],_0x410e63[_0x15c7d7('0x14cb')]['save'](_0x64e9f1[_0x15c7d7('0xff1')])['$promise'][_0x15c7d7('0x683')](function(_0x119baf){const _0x3309d9=_0x15c7d7;_0x64e9f1[_0x3309d9('0x1f17')][_0x3309d9('0x1167')](_0x119baf[_0x3309d9('0x24e1')]()),_0x51747d[_0x3309d9('0x53')]({'title':_0x3309d9('0x255e'),'msg':_0x64e9f1[_0x3309d9('0xff1')][_0x3309d9('0x60a')]?_0x64e9f1[_0x3309d9('0xff1')]['name']+'\x20has\x20been\x20created!':''}),_0x58efe8(_0x119baf);})[_0x15c7d7('0x130a')](function(_0x6512ba){const _0x5c1046=_0x15c7d7;if(_0x6512ba[_0x5c1046('0x5a5')]&&_0x6512ba[_0x5c1046('0x5a5')]['errors']&&_0x6512ba['data'][_0x5c1046('0x17f')][_0x5c1046('0x1564')]){_0x64e9f1[_0x5c1046('0x17f')]=_0x6512ba[_0x5c1046('0x5a5')]['errors']||[{'message':_0x6512ba[_0x5c1046('0x1ff0')](),'type':'api.voiceExtension.save'}];for(let _0x3ad058=0x0;_0x3ad058<_0x6512ba['data'][_0x5c1046('0x17f')]['length'];_0x3ad058+=0x1){_0x51747d['error']({'title':_0x6512ba['data'][_0x5c1046('0x17f')][_0x3ad058][_0x5c1046('0xcf0')],'msg':_0x6512ba[_0x5c1046('0x5a5')][_0x5c1046('0x17f')][_0x3ad058][_0x5c1046('0x8c2')]});}}else _0x51747d[_0x5c1046('0x52a')]({'title':_0x6512ba[_0x5c1046('0x13ee')]?_0x5c1046('0x2168')+_0x6512ba[_0x5c1046('0x13ee')]+_0x5c1046('0xbf6')+_0x6512ba[_0x5c1046('0x24a9')]:_0x5c1046('0x13bd'),'msg':_0x6512ba[_0x5c1046('0x5a5')]?JSON['stringify'](_0x6512ba['data']['message']):_0x6512ba['toString']()});});}function _0xd0c504(){const _0x3f1704=_0xc7b143;_0x64e9f1[_0x3f1704('0x17f')]=[],_0x410e63[_0x3f1704('0x14cb')][_0x3f1704('0x2480')]({'id':_0x64e9f1[_0x3f1704('0xff1')]['id']},_0x64e9f1['inboundroute'])[_0x3f1704('0xe53')][_0x3f1704('0x683')](function(_0x18df0c){const _0x286714=_0x3f1704,_0xfe131c=_0x2e3ca0()[_0x286714('0x1c07')](_0x64e9f1[_0x286714('0x1f17')],{'id':_0x18df0c['id']});_0xfe131c&&_0x2e3ca0()['merge'](_0xfe131c,_0x2e3ca0()[_0x286714('0x24d0')](_0x18df0c[_0x286714('0x24e1')](),_0x2e3ca0()[_0x286714('0x55e')](_0xfe131c))),_0x51747d[_0x286714('0x53')]({'title':_0x286714('0x1f31'),'msg':_0x64e9f1['inboundroute']['name']?_0x64e9f1['inboundroute'][_0x286714('0x60a')]+_0x286714('0xf59'):''}),_0x58efe8(_0x18df0c);})[_0x3f1704('0x130a')](function(_0xaa1ea6){const _0x3beb76=_0x3f1704;if(_0xaa1ea6[_0x3beb76('0x5a5')]&&_0xaa1ea6['data']['errors']&&_0xaa1ea6[_0x3beb76('0x5a5')][_0x3beb76('0x17f')]['length']){_0x64e9f1['errors']=_0xaa1ea6[_0x3beb76('0x5a5')]['errors']||[{'message':_0xaa1ea6[_0x3beb76('0x1ff0')](),'type':_0x3beb76('0x27e8')}];for(let _0x4bec94=0x0;_0x4bec94<_0xaa1ea6[_0x3beb76('0x5a5')][_0x3beb76('0x17f')]['length'];_0x4bec94++){_0x51747d[_0x3beb76('0x52a')]({'title':_0xaa1ea6[_0x3beb76('0x5a5')][_0x3beb76('0x17f')][_0x4bec94][_0x3beb76('0xcf0')],'msg':_0xaa1ea6[_0x3beb76('0x5a5')][_0x3beb76('0x17f')][_0x4bec94]['message']});}}else _0x51747d[_0x3beb76('0x52a')]({'title':_0xaa1ea6[_0x3beb76('0x13ee')]?_0x3beb76('0x2168')+_0xaa1ea6[_0x3beb76('0x13ee')]+_0x3beb76('0xbf6')+_0xaa1ea6['statusText']:_0x3beb76('0x27e8'),'msg':_0xaa1ea6['data']?JSON['stringify'](_0xaa1ea6['data'][_0x3beb76('0x8c2')]):_0xaa1ea6[_0x3beb76('0x1ff0')]()});});}function _0x3b3a1d(_0x4962e9){const _0x277e95=_0xc7b143;_0x64e9f1[_0x277e95('0x17f')]=[];const _0x2c5561=_0x40819c['confirm']()[_0x277e95('0xf28')](_0x277e95('0x4d'))['content'](_0x277e95('0x1bf8'))[_0x277e95('0x1040')](_0x277e95('0x226a'))['ok']('Delete')[_0x277e95('0x19fb')]('Cancel')['targetEvent'](_0x4962e9);_0x40819c['show'](_0x2c5561)[_0x277e95('0x683')](function(){const _0x18bd3d=_0x277e95;_0x410e63[_0x18bd3d('0x14cb')][_0x18bd3d('0xd7e')]({'id':_0x64e9f1[_0x18bd3d('0xff1')]['id']})['$promise'][_0x18bd3d('0x683')](function(){const _0x561045=_0x18bd3d;_0x2e3ca0()[_0x561045('0x3ec')](_0x64e9f1[_0x561045('0x1f17')],{'id':_0x64e9f1[_0x561045('0xff1')]['id']}),_0x51747d[_0x561045('0x53')]({'title':'InboundRoute\x20properly\x20deleted!','msg':(_0x64e9f1[_0x561045('0xff1')][_0x561045('0x60a')]||_0x561045('0xff1'))+_0x561045('0x194d')}),_0x58efe8(_0x64e9f1['inboundroute']);})['catch'](function(_0x52e1ad){const _0x3144c0=_0x18bd3d;if(_0x52e1ad[_0x3144c0('0x5a5')]&&_0x52e1ad['data']['errors']&&_0x52e1ad[_0x3144c0('0x5a5')][_0x3144c0('0x17f')][_0x3144c0('0x1564')]){_0x64e9f1[_0x3144c0('0x17f')]=_0x52e1ad['data'][_0x3144c0('0x17f')]||[{'message':_0x52e1ad[_0x3144c0('0x1ff0')](),'type':_0x3144c0('0x17de')}];for(let _0x5defca=0x0;_0x5defca<_0x52e1ad[_0x3144c0('0x5a5')][_0x3144c0('0x17f')][_0x3144c0('0x1564')];_0x5defca++){_0x51747d[_0x3144c0('0x52a')]({'title':_0x52e1ad[_0x3144c0('0x5a5')][_0x3144c0('0x17f')][_0x5defca][_0x3144c0('0xcf0')],'msg':_0x52e1ad[_0x3144c0('0x5a5')][_0x3144c0('0x17f')][_0x5defca][_0x3144c0('0x8c2')]});}}else _0x51747d[_0x3144c0('0x52a')]({'title':_0x52e1ad[_0x3144c0('0x13ee')]?'API:'+_0x52e1ad['status']+_0x3144c0('0xbf6')+_0x52e1ad[_0x3144c0('0x24a9')]:_0x3144c0('0x17de'),'msg':_0x52e1ad['data']?JSON['stringify'](_0x52e1ad['data'][_0x3144c0('0x8c2')]):_0x52e1ad[_0x3144c0('0x8c2')]||_0x52e1ad['toString']()});});},function(){});}function _0x4d0084(_0xcec936){return _0xcec936===null?undefined:new Date(_0xcec936);}function _0x58efe8(_0x5954fb){const _0x3825ba=_0xc7b143;_0x40819c[_0x3825ba('0x1715')](_0x5954fb);}}const _0x5eac23=_0x131625,_0xd2618d=_0x180212['p']+_0x189033('0x9d'),_0x30851d=_0x180212['p']+_0x189033('0x1071'),_0x5c00ad=_0x180212['p']+_0x189033('0x13b0'),_0x379011=_0x180212['p']+_0x189033('0xbb3'),_0x3d4f3e=_0x180212['p']+_0x189033('0x149f'),_0x16f839=_0x180212['p']+_0x189033('0x2737'),_0x1f78a4=_0x180212['p']+_0x189033('0x146b'),_0x1f9f2a=_0x180212['p']+_0x189033('0x1dfe'),_0x2e992f=_0x180212['p']+'src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/playback/dialog.html/dialog.html',_0x352701=_0x180212['p']+'src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/queue/dialog.html/dialog.html',_0x141de3=_0x180212['p']+_0x189033('0x10f3'),_0x1c2f8f=_0x180212['p']+_0x189033('0x92e'),_0x1e109e=_0x180212['p']+'src/js/modules/main/apps/voice/views/inboundroutes/edit/apps/voicemail/dialog.html/dialog.html';_0x1e6259[_0x189033('0x14be')]=['api','$mdDialog',_0x189033('0x16ea'),'toasty',_0x189033('0xba1')];const _0x1a04a6={'agi':_0xd2618d,'custom':_0x30851d,'dial':_0x5c00ad,'externaldial':_0x379011,'goto':_0x3d4f3e,'hangup':_0x16f839,'internaldial':_0x1f78a4,'interval':_0x1f9f2a,'playback':_0x2e992f,'queue':_0x352701,'ringgroup':_0x141de3,'set':_0x1c2f8f,'voicemail':_0x1e109e};function _0x1e6259(_0x4a0d44,_0x22709e,_0x129fdd,_0x316048,_0xb97bfb){const _0x134e60=_0x189033,_0xe8a1d1=this;_0xe8a1d1['currentUser']=_0xb97bfb[_0x134e60('0x20b2')](),_0xe8a1d1[_0x134e60('0xff1')]={},_0xe8a1d1[_0x134e60('0x109a')]={'count':0x0,'rows':[]},_0xe8a1d1['selectedInboundRouteApps']=[],_0xe8a1d1[_0x134e60('0x1134')],_0xe8a1d1[_0x134e60('0x23a2')]={'sort':_0x134e60('0xe1e')},_0xe8a1d1[_0x134e60('0x346')]=_0x2e3ca0()[_0x134e60('0xfae')](_0x2e3ca0()['sortBy']([{'app':_0x134e60('0x22ee'),'appType':_0x134e60('0x115c'),'types':[_0x134e60('0x10af'),'custom',_0x134e60('0x2335')],'fields':[],'isApp':![]},{'app':_0x134e60('0x1fa'),'appType':'queue','context':_0x134e60('0x40e'),'type':_0x134e60('0x1572'),'appdata':_0x134e60('0xf75'),'icon':_0x134e60('0x7ee'),'options':'xX','interval':_0x134e60('0x1b54'),'answer':!![],'isApp':!![],'extraApi':[{'name':_0x134e60('0x11d2'),'field':{'name':_0x134e60('0x1638'),'key':_0x134e60('0x1144'),'prefix':'/var/opt/motion2/server/files/sounds/converted/'},'route':_0x134e60('0x1638'),'filters':{'fields':_0x134e60('0xfa7'),'sort':_0x134e60('0x60a'),'nolimit':!![]},'permissions':{'section':0x3ef}},{'name':_0x134e60('0x2da'),'field':{'name':'queue','key':_0x134e60('0x60a')},'route':_0x134e60('0x204c'),'filters':{'type':_0x134e60('0x1535'),'fields':'id,name,type','sort':_0x134e60('0x60a'),'nolimit':!![]},'permissions':{'section':0x191}}],'fields':[{'title':_0x134e60('0x1fa'),'name':_0x134e60('0x660'),'type':_0x134e60('0x1aae'),'values':_0x134e60('0x2da'),'value':_0x134e60('0x2543'),'option':_0x134e60('0x2543'),'required':!![],'param':0x0},{'title':_0x134e60('0x6d'),'name':_0x134e60('0x158e'),'type':_0x134e60('0x1bcd'),'param':0x1},{'title':_0x134e60('0x1865'),'name':_0x134e60('0x1a0a'),'type':_0x134e60('0x1bcd'),'param':0x2},{'title':'Announce_Overrides','name':_0x134e60('0x1638'),'type':_0x134e60('0x1aae'),'values':_0x134e60('0x11d2'),'value':_0x134e60('0x6a'),'option':_0x134e60('0xb07'),'defaultValues':[{'value':'\x27\x27','option':'None'}],'param':0x3},{'title':_0x134e60('0xa09'),'name':_0x134e60('0x1668'),'type':_0x134e60('0x121f'),'min':0x0,'param':0x4},{'title':'Agi','name':_0x134e60('0x19ae'),'type':_0x134e60('0x1bcd'),'param':0x5},{'title':_0x134e60('0x109e'),'name':'macro','type':'text','param':0x6},{'title':_0x134e60('0x27ad'),'name':'gosub','type':_0x134e60('0x1bcd'),'param':0x7},{'title':_0x134e60('0x183a'),'name':'rule','type':_0x134e60('0x1bcd'),'param':0x8},{'title':_0x134e60('0x2243'),'name':_0x134e60('0x1233'),'type':'number','min':0x0,'param':0x9},{'title':_0x134e60('0x7d6'),'name':_0x134e60('0x1767'),'type':_0x134e60('0x2d0'),'general':!![]}]},{'app':_0x134e60('0x2551'),'appType':_0x134e60('0xab0'),'context':_0x134e60('0x40e'),'type':'Inbound','icon':'icon-apps','interval':_0x134e60('0x1b54'),'answer':!![],'isApp':!![],'extraApi':[{'name':_0x134e60('0x11d2'),'field':{'name':_0x134e60('0x1638'),'key':_0x134e60('0x1144'),'prefix':_0x134e60('0xd4a')},'route':_0x134e60('0x1638'),'filters':{'fields':'id,name,save_name','sort':_0x134e60('0x60a'),'nolimit':!![]},'permissions':{'section':0x3ef}}],'fields':[{'title':'Audio_Files','name':'appdata','type':_0x134e60('0x1aae'),'values':_0x134e60('0x11d2'),'value':_0x134e60('0x57'),'option':_0x134e60('0x6f1'),'required':!![],'param':0x0},{'title':'Options','name':_0x134e60('0x158e'),'type':'text','param':0x1},{'title':_0x134e60('0x7d6'),'name':_0x134e60('0x1767'),'type':_0x134e60('0x2d0'),'general':!![]}]},{'app':_0x134e60('0x7c0'),'appType':_0x134e60('0x401'),'context':'from-voip-provider','type':_0x134e60('0x1572'),'icon':_0x134e60('0x7ee'),'interval':'*,*,*,*','options':'xX','isApp':!![],'fields':[{'title':_0x134e60('0x1ef6'),'name':_0x134e60('0x1e0f'),'type':_0x134e60('0x1bcd'),'required':!![],'param':0x0},{'title':_0x134e60('0xa09'),'name':'timeout','type':_0x134e60('0x121f'),'min':0x0,'param':0x1},{'title':_0x134e60('0x6d'),'name':_0x134e60('0x158e'),'type':_0x134e60('0x1bcd'),'param':0x2},{'title':'Url','name':_0x134e60('0x1284'),'type':_0x134e60('0x1bcd'),'param':0x3}]},{'app':_0x134e60('0x7c0'),'appType':_0x134e60('0x5e0'),'context':'from-voip-provider','type':_0x134e60('0x1572'),'icon':_0x134e60('0x7ee'),'interval':_0x134e60('0x1b54'),'options':'xX','isApp':!![],'extraApi':[{'name':_0x134e60('0x3bf'),'field':{'name':_0x134e60('0xc96'),'key':_0x134e60('0x60a'),'prefix':_0x134e60('0x1073')},'route':_0x134e60('0xc96'),'filters':{'fields':_0x134e60('0xac9'),'sort':_0x134e60('0x60a'),'nolimit':!![]},'permissions':{'sections':[{'id':0xca,'role':_0x134e60('0x2327')},{'id':0xcb,'role':_0x134e60('0x24d3')}]}}],'fields':[{'title':_0x134e60('0x1dad'),'name':_0x134e60('0xc96'),'type':'apiselect','values':_0x134e60('0x3bf'),'value':'\x27SIP/{{user.name}}\x27','option':_0x134e60('0x1f9a'),'required':!![],'param':0x0},{'title':_0x134e60('0xa09'),'name':_0x134e60('0x1668'),'type':_0x134e60('0x121f'),'min':0x0,'param':0x1},{'title':_0x134e60('0x6d'),'name':_0x134e60('0x158e'),'type':_0x134e60('0x1bcd'),'param':0x2},{'title':'Url','name':_0x134e60('0x1284'),'type':_0x134e60('0x1bcd'),'param':0x3}]},{'app':'Dial','appType':'externalDial','context':'from-voip-provider','type':_0x134e60('0x1535'),'icon':_0x134e60('0x7ee'),'interval':'*,*,*,*','options':'xX','isApp':!![],'extraApi':[{'name':_0x134e60('0x20fe'),'field':{'name':_0x134e60('0x1a93'),'key':_0x134e60('0x60a')},'route':_0x134e60('0x1a93'),'filters':{'fields':'id,name','sort':_0x134e60('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f3}}],'fields':[{'title':_0x134e60('0x17c1'),'name':_0x134e60('0x1a93'),'type':_0x134e60('0x1aae'),'values':'trunks','value':_0x134e60('0x1f1c'),'option':_0x134e60('0x1f1c'),'required':!![],'param':0x0},{'title':_0x134e60('0x99c'),'name':_0x134e60('0xd31'),'required':!![],'type':_0x134e60('0x1bcd')},{'title':_0x134e60('0xa09'),'name':'timeout','type':_0x134e60('0x121f'),'min':0x0,'param':0x1},{'title':_0x134e60('0x6d'),'name':_0x134e60('0x158e'),'type':'text','param':0x2},{'title':_0x134e60('0x1865'),'name':_0x134e60('0x1284'),'type':'text','param':0x3}]},{'app':_0x134e60('0x7c0'),'appType':_0x134e60('0x1a2d'),'context':'from-voip-provider','type':_0x134e60('0x1535'),'icon':'icon-apps','interval':_0x134e60('0x1b54'),'options':'xX','isApp':!![],'extraApi':[{'name':_0x134e60('0x3bf'),'field':{'name':_0x134e60('0xbf8'),'key':_0x134e60('0x60a'),'prefix':_0x134e60('0x1073')},'route':'user','filters':{'fields':_0x134e60('0xac9'),'sort':_0x134e60('0x60a'),'nolimit':!![]},'permissions':{'sections':[{'id':0xca,'role':_0x134e60('0x2327')},{'id':0xcb,'role':_0x134e60('0x24d3')}]}}],'fields':[{'title':'User','name':_0x134e60('0xbf8'),'type':_0x134e60('0x1aae'),'multiple':!![],'values':'users','value':_0x134e60('0xb9f'),'option':'multipleUsers.name','required':!![],'param':0x0},{'title':_0x134e60('0xa09'),'name':'timeout','type':_0x134e60('0x121f'),'min':0x0,'param':0x1},{'title':_0x134e60('0x6d'),'name':'options','type':_0x134e60('0x1bcd'),'param':0x2},{'title':_0x134e60('0x1865'),'name':_0x134e60('0x1284'),'type':_0x134e60('0x1bcd'),'param':0x3}]},{'app':'AGI','alias':_0x134e60('0x4ef'),'appType':_0x134e60('0x19ae'),'context':'from-voip-provider','type':_0x134e60('0x1535'),'icon':'icon-apps','interval':_0x134e60('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x134e60('0x1248'),'field':{'name':'project','key':_0x134e60('0x60a'),'prefix':'agi://127.0.0.1/square,'},'route':_0x134e60('0x27ea'),'filters':{'fields':_0x134e60('0xa10'),'sort':_0x134e60('0x60a'),'nolimit':!![]},'permissions':{'section':0x44f}}],'fields':[{'title':_0x134e60('0x283'),'name':_0x134e60('0x273a'),'type':_0x134e60('0x1aae'),'values':_0x134e60('0x1248'),'value':_0x134e60('0x22ef'),'option':'project.name','required':!![],'param':0x0}]},{'app':_0x134e60('0x27fe'),'appType':_0x134e60('0x8be'),'context':'from-voip-provider','type':'Inbound','icon':_0x134e60('0x7ee'),'interval':_0x134e60('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x134e60('0x1693'),'field':{'name':_0x134e60('0x22d3'),'key':_0x134e60('0x60a')},'route':_0x134e60('0x1e4d'),'filters':{'fields':_0x134e60('0xa10'),'sort':'name','nolimit':!![]},'permissions':{'section':0x195}}],'fields':[{'title':'Context','name':'context','type':_0x134e60('0x1aae'),'values':'contexts','value':'context.name','option':_0x134e60('0x6b'),'required':!![],'param':0x0},{'title':_0x134e60('0x2060'),'name':_0x134e60('0xa65'),'type':_0x134e60('0x1bcd'),'required':!![],'param':0x1},{'title':_0x134e60('0x19b4'),'name':_0x134e60('0xe1e'),'type':_0x134e60('0x1bcd'),'required':!![],'param':0x2}]},{'app':_0x134e60('0x1ba9'),'appType':_0x134e60('0x1ba9'),'context':_0x134e60('0x40e'),'type':_0x134e60('0x1572'),'icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x134e60('0x13b'),'name':_0x134e60('0x1407'),'type':_0x134e60('0xb31'),'param':0x0,'values':[{'option':_0x134e60('0x1bfb'),'value':'\x271\x27'},{'option':_0x134e60('0x1c3c'),'value':_0x134e60('0x19c2')},{'option':'HANGUPCAUSE_17','value':_0x134e60('0x22da')},{'option':_0x134e60('0x2149'),'value':'\x2718\x27'},{'option':_0x134e60('0x2446'),'value':_0x134e60('0x10a3')},{'option':_0x134e60('0x1d82'),'value':_0x134e60('0x27c3')},{'option':_0x134e60('0x2725'),'value':_0x134e60('0x259f')},{'option':_0x134e60('0x2870'),'value':_0x134e60('0x1d60')},{'option':_0x134e60('0x1537'),'value':'\x2741\x27'}],'translate':!![],'required':!![],'general':!![]}]},{'app':_0x134e60('0x1faa'),'appType':_0x134e60('0x877'),'context':_0x134e60('0x40e'),'type':_0x134e60('0x1572'),'separator':'=','icon':_0x134e60('0x7ee'),'interval':_0x134e60('0x1b54'),'extraApi':[{'name':_0x134e60('0x220b'),'field':{'name':_0x134e60('0x60a'),'key':'name'},'route':'variable','filters':{'fields':_0x134e60('0xa10'),'sort':_0x134e60('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'isApp':!![],'fields':[{'title':_0x134e60('0xde7'),'name':'name','type':_0x134e60('0x1aae'),'values':'variables','value':_0x134e60('0x1dd5'),'option':_0x134e60('0x1dd5'),'required':!![],'param':0x0},{'title':'Value','name':'value','type':_0x134e60('0x1bcd'),'required':!![],'param':0x1}]},{'app':null,'appType':_0x134e60('0xbf0'),'icon':'icon-apps','type':_0x134e60('0x1572'),'interval':_0x134e60('0x1b54'),'isApp':!![],'fields':[{'title':_0x134e60('0x62f'),'name':_0x134e60('0x1d75'),'type':_0x134e60('0x1bcd'),'required':!![],'param':0x0},{'title':_0x134e60('0xdff'),'name':_0x134e60('0x1407'),'type':'text','param':0x1}]},{'app':_0x134e60('0xacc'),'appType':_0x134e60('0x8ac'),'context':'from-voip-provider','icon':_0x134e60('0x7ee'),'type':_0x134e60('0x1572'),'interval':_0x134e60('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x134e60('0x544'),'field':{'name':_0x134e60('0x1a6b'),'key':_0x134e60('0x10ae'),'suffix':_0x134e60('0x89b')},'route':_0x134e60('0x1a6b'),'filters':{'fields':'id,mailbox','sort':_0x134e60('0x10ae'),'nolimit':!![]},'permissions':{'section':0x196}}],'fields':[{'title':'Mailbox@Context','name':_0x134e60('0x1a6b'),'type':_0x134e60('0x1aae'),'values':_0x134e60('0x544'),'value':_0x134e60('0x2881'),'option':_0x134e60('0xd47'),'required':!![],'param':0x0},{'title':_0x134e60('0x6d'),'name':'options','type':_0x134e60('0x1bcd'),'param':0x1}]}],[_0x134e60('0x1d75')]),{'isApp':![]}),_0xe8a1d1[_0x134e60('0x2335')]={'group':{'name':'opt1','pull':'clone'},'animation':0x64,'sort':![]},_0xe8a1d1[_0x134e60('0x2146')]={'group':{'name':_0x134e60('0x489'),'put':_0x134e60('0x11bf')},'animation':0x64,'onAdd':function(_0x30c511){const _0x101efe=_0x134e60;_0xf77de7(_0x30c511,_0x30c511[_0x101efe('0x1ce1')]);},'onSort':function(){_0x38e970();}},_0xe8a1d1['init']=_0x12a17e,_0xe8a1d1[_0x134e60('0x26eb')]=_0x24fe83,_0xe8a1d1['getInboundRouteApps']=_0x58307d,_0xe8a1d1[_0x134e60('0x1747')]=_0xf77de7,_0xe8a1d1[_0x134e60('0x24f7')]=_0x9e5f2a,_0xe8a1d1[_0x134e60('0x3bd')]=_0x1d1d42,_0xe8a1d1[_0x134e60('0x13ef')]=_0x477523,_0xe8a1d1[_0x134e60('0x13f5')]=_0x38e970,_0xe8a1d1[_0x134e60('0x14a')]=_0x2a2f43;function _0x12a17e(_0x25ca2c,_0x299797){const _0x3a5fd5=_0x134e60;_0xe8a1d1['inboundroute']=_0x25ca2c,_0xe8a1d1[_0x3a5fd5('0x1134')]=typeof _0x299797!=='undefined'?_0x299797:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0xe8a1d1[_0x3a5fd5('0x2146')]['disabled']=!_0xe8a1d1['crudPermissions'][_0x3a5fd5('0x1978')]?!![]:![],_0xe8a1d1[_0x3a5fd5('0x23a2')]['VoiceExtensionId']=_0x25ca2c['id'],_0xe8a1d1[_0x3a5fd5('0x23a2')][_0x3a5fd5('0x12a8')]=!![],_0xe8a1d1['query'][_0x3a5fd5('0x2088')]=!![],_0xe8a1d1['getInboundRouteApps'](),_0xe8a1d1[_0x3a5fd5('0x14a')]();}function _0x24fe83(_0x7e7440,_0x52884e,_0xdb5bdc){const _0x2d7f75=_0x134e60,_0x1d5d60=_0x22709e[_0x2d7f75('0x1c6f')]()[_0x2d7f75('0xf28')](_0x2d7f75('0x421'))[_0x2d7f75('0x26e3')](_0x2d7f75('0xed5')+_0x7e7440[_0x2d7f75('0x1d75')]+_0x2d7f75('0x20f1')+_0x2d7f75('0x1ee7'))[_0x2d7f75('0x1040')](_0x2d7f75('0x1312'))[_0x2d7f75('0xe42')](_0xdb5bdc)['ok']('OK')[_0x2d7f75('0x19fb')](_0x2d7f75('0x16b8'));_0x22709e[_0x2d7f75('0x1d4')](_0x1d5d60)['then'](function(){const _0x1b80dc=_0x2d7f75;_0xe8a1d1[_0x1b80dc('0x109a')][_0x1b80dc('0xf5d')][_0x1b80dc('0x2040')](_0x52884e,0x1),_0x38e970();},function(){console['log']('CANCEL');});}function _0xf77de7(_0x589e63,_0xa19e4){const _0x2a4aff=_0x134e60;if(_0xe8a1d1[_0x2a4aff('0x109a')][_0x2a4aff('0xf5d')][_0x2a4aff('0x1564')]){const _0xfb9017=_0xe8a1d1['inboundrouteApps'][_0x2a4aff('0xf5d')][_0xa19e4]?_0xe8a1d1[_0x2a4aff('0x109a')][_0x2a4aff('0xf5d')][_0xa19e4]:_0xe8a1d1['inboundrouteApps'][_0x2a4aff('0xf5d')][0x0],_0x440be6=(_0xfb9017[_0x2a4aff('0x11f3')]||_0xfb9017[_0x2a4aff('0x1d75')])['toLowerCase']();_0x22709e[_0x2a4aff('0x1d4')]({'controller':_0x2a4aff('0x12e0')+_0x440be6+'DialogController','controllerAs':'vm','templateUrl':_0x1a04a6[_0x440be6],'parent':angular[_0x2a4aff('0x1fcc')](_0x129fdd['body']),'targetEvent':_0x589e63,'clickOutsideToClose':!![],'locals':{'inboundrouteApp':_0xfb9017,'inboundroute':_0xe8a1d1[_0x2a4aff('0xff1')],'crudPermissions':_0xe8a1d1[_0x2a4aff('0x1134')]}})[_0x2a4aff('0x683')](function(_0x4dd56c){const _0x36d299=_0x2a4aff;_0x4dd56c&&(_0x4dd56c['id']?_0xe8a1d1[_0x36d299('0x109a')][_0x36d299('0xf5d')][_0xa19e4]=_0x4dd56c:_0xe8a1d1[_0x36d299('0x109a')][_0x36d299('0xf5d')][_0x36d299('0x2040')](_0xa19e4,0x0,_0x4dd56c),_0x38e970());})[_0x2a4aff('0x130a')](function(_0x1e6f8f){const _0x34ee82=_0x2a4aff;_0x1e6f8f&&_0x316048[_0x34ee82('0x52a')]({'title':_0x1e6f8f[_0x34ee82('0x13ee')]?'API:'+_0x1e6f8f[_0x34ee82('0x13ee')]+'\x20-\x20'+_0x1e6f8f[_0x34ee82('0x24a9')]:_0x34ee82('0xf1b'),'msg':_0x1e6f8f[_0x34ee82('0x5a5')]?JSON[_0x34ee82('0x258a')](_0x1e6f8f[_0x34ee82('0x5a5')]):_0x1e6f8f[_0x34ee82('0x1ff0')]()});});}}function _0x9e5f2a(_0xdc82d,_0x220fc9){const _0x56ff41=_0x134e60;if(_0xe8a1d1[_0x56ff41('0x109a')]['rows'][_0x56ff41('0x1564')]){const _0x58e1ed=_0xe8a1d1[_0x56ff41('0x109a')]['rows'][_0x220fc9]?_0xe8a1d1[_0x56ff41('0x109a')]['rows'][_0x220fc9]:_0xe8a1d1[_0x56ff41('0x109a')][_0x56ff41('0xf5d')][0x0];_0x22709e[_0x56ff41('0x1d4')]({'controller':_0x56ff41('0x2104'),'controllerAs':'vm','templateUrl':_0x1f9f2a,'parent':angular[_0x56ff41('0x1fcc')](_0x129fdd[_0x56ff41('0x18e5')]),'targetEvent':_0xdc82d,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x58e1ed['interval'],'IntervalId':_0x58e1ed[_0x56ff41('0x5ae')],'application':!![]},'intervals':[],'crudPermissions':_0xe8a1d1[_0x56ff41('0x1134')]}})[_0x56ff41('0x683')](function(_0x4fccf9){const _0x449f08=_0x56ff41;_0x4fccf9&&(_0x58e1ed[_0x449f08('0x115c')]=_0x4fccf9[_0x449f08('0x115c')]||'*,*,*,*',_0x58e1ed[_0x449f08('0x5ae')]=_0x4fccf9[_0x449f08('0x5ae')]||null,_0x38e970());});}}function _0x38e970(){const _0x16b4e4=_0x134e60,_0x959123=['queue',_0x16b4e4('0xab0')];let _0x48b92d=0x2,_0x27cd63=[];_0x27cd63[_0x16b4e4('0x1fd0')]({'type':_0x16b4e4('0x1535'),'app':_0x16b4e4('0x1faa'),'appdata':_0x16b4e4('0x18c0'),'context':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x22d3')],'exten':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x1a5b')],'priority':_0x48b92d++,'VoiceExtensionId':_0xe8a1d1[_0x16b4e4('0xff1')]['id']}),_0x27cd63[_0x16b4e4('0x1fd0')]({'type':_0x16b4e4('0x1535'),'app':'Set','appdata':_0x16b4e4('0xccd'),'context':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x22d3')],'exten':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x1a5b')],'priority':_0x48b92d++,'VoiceExtensionId':_0xe8a1d1['inboundroute']['id']}),_0x27cd63['push']({'type':_0x16b4e4('0x1535'),'app':'Set','appdata':_0x16b4e4('0x23d5'),'context':_0xe8a1d1['inboundroute'][_0x16b4e4('0x22d3')],'exten':_0xe8a1d1[_0x16b4e4('0xff1')]['exten'],'priority':_0x48b92d++,'VoiceExtensionId':_0xe8a1d1['inboundroute']['id']}),_0x27cd63[_0x16b4e4('0x1fd0')]({'type':'inbound','app':_0x16b4e4('0x1faa'),'appdata':_0x16b4e4('0x6e3'),'context':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x22d3')],'exten':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x1a5b')],'priority':_0x48b92d++,'VoiceExtensionId':_0xe8a1d1['inboundroute']['id']});for(let _0x341cc9=0x0,_0x3c6ad2=0x0;_0x341cc9<_0xe8a1d1[_0x16b4e4('0x109a')][_0x16b4e4('0xf5d')]['length'];_0x341cc9++,_0x3c6ad2=0x0){const _0x42202f=_0xe8a1d1[_0x16b4e4('0x109a')]['rows'][_0x341cc9],_0x14ae6a=[],_0x59c89a=[];_0x42202f[_0x16b4e4('0xe98')]=_0x42202f[_0x16b4e4('0x115c')]!==_0x16b4e4('0x1b54')?[_0x42202f[_0x16b4e4('0x115c')]]:_0x42202f['IntervalId']?_0x2e3ca0()[_0x16b4e4('0x386')](_0x2e3ca0()[_0x16b4e4('0x25')](_0xe8a1d1[_0x16b4e4('0xe98')][_0x16b4e4('0xf5d')],{'IntervalId':_0x42202f[_0x16b4e4('0x5ae')]}),'interval'):[],_0x42202f[_0x16b4e4('0x22d3')]=_0xe8a1d1[_0x16b4e4('0xff1')]['context'],_0x42202f[_0x16b4e4('0x1a5b')]=_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x1a5b')];_0x42202f[_0x16b4e4('0xcf0')]&&(_0x42202f['type']=_0x42202f[_0x16b4e4('0xcf0')][_0x16b4e4('0x93a')]());typeof _0x42202f[_0x16b4e4('0x1767')]!==_0x16b4e4('0x1867')&&(_0x959123[_0x16b4e4('0x2292')](_0x42202f[_0x16b4e4('0x1d75')][_0x16b4e4('0x93a')]())&&_0x42202f[_0x16b4e4('0x11f3')]!==_0x16b4e4('0xbf0')&&(_0x42202f['answer']?(_0x14ae6a['push']({'type':_0x42202f[_0x16b4e4('0xcf0')]['toLowerCase'](),'app':_0x16b4e4('0x15bb'),'appdata':_0x16b4e4('0x92a'),'context':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x22d3')],'exten':_0xe8a1d1['inboundroute']['exten'],'priority':_0x42202f[_0x16b4e4('0xe98')][_0x16b4e4('0x1564')]+_0x48b92d+_0x3c6ad2++,'VoiceExtensionId':_0xe8a1d1['inboundroute']['id']}),_0x14ae6a['push']({'type':_0x42202f['type'][_0x16b4e4('0x93a')](),'app':_0x16b4e4('0x1faa'),'appdata':'XCALLY-MOTION-ANSWER=1','context':_0xe8a1d1['inboundroute']['context'],'exten':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x1a5b')],'priority':_0x42202f['intervals'][_0x16b4e4('0x1564')]+_0x48b92d+_0x3c6ad2++,'VoiceExtensionId':_0xe8a1d1[_0x16b4e4('0xff1')]['id']})):(_0x14ae6a[_0x16b4e4('0x1fd0')]({'type':_0x42202f[_0x16b4e4('0xcf0')][_0x16b4e4('0x93a')](),'app':_0x16b4e4('0x15bb'),'appdata':_0x16b4e4('0x1e22'),'context':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x22d3')],'exten':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x1a5b')],'priority':_0x42202f[_0x16b4e4('0xe98')][_0x16b4e4('0x1564')]+_0x48b92d+_0x3c6ad2++,'VoiceExtensionId':_0xe8a1d1[_0x16b4e4('0xff1')]['id']}),_0x14ae6a[_0x16b4e4('0x1fd0')]({'type':_0x42202f[_0x16b4e4('0xcf0')][_0x16b4e4('0x93a')](),'app':'Set','appdata':_0x16b4e4('0x273f'),'context':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x22d3')],'exten':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x1a5b')],'priority':_0x42202f[_0x16b4e4('0xe98')][_0x16b4e4('0x1564')]+_0x48b92d+_0x3c6ad2++,'VoiceExtensionId':_0xe8a1d1[_0x16b4e4('0xff1')]['id']}))));for(let _0x4020c4=0x0;_0x4020c4<_0x42202f['intervals'][_0x16b4e4('0x1564')];_0x4020c4++){const _0x40fce2=_0x48b92d+_0x42202f[_0x16b4e4('0xe98')][_0x16b4e4('0x1564')],_0x38fd40=_0x4020c4===_0x42202f[_0x16b4e4('0xe98')][_0x16b4e4('0x1564')]-0x1?_0x48b92d+_0x14ae6a['length']+_0x59c89a[_0x16b4e4('0x1564')]+0x2:_0x48b92d+_0x4020c4+0x1;_0x14ae6a[_0x16b4e4('0x2040')](_0x4020c4,0x0,{'type':'inbound','app':_0x16b4e4('0xeb4'),'appdata':_0x42202f['intervals'][_0x4020c4]+'?'+_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x22d3')]+_0x16b4e4('0xd09')+_0x40fce2+':'+_0xe8a1d1['inboundroute'][_0x16b4e4('0x22d3')]+_0x16b4e4('0xd09')+_0x38fd40,'exten':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x1a5b')],'context':_0xe8a1d1[_0x16b4e4('0xff1')]['context'],'priority':_0x48b92d+_0x4020c4,'VoiceExtensionId':_0xe8a1d1['inboundroute']['id']});}_0x42202f[_0x16b4e4('0xe1e')]=_0x14ae6a[_0x16b4e4('0x1564')]?_0x2e3ca0()[_0x16b4e4('0xc0f')](_0x14ae6a)['priority']+0x1:_0x48b92d,_0x48b92d=(_0x59c89a[_0x16b4e4('0x1564')]?_0x2e3ca0()[_0x16b4e4('0xc0f')](_0x59c89a)[_0x16b4e4('0xe1e')]:_0x42202f[_0x16b4e4('0xe1e')])+0x1,_0x27cd63=_0x2e3ca0()[_0x16b4e4('0x746')](_0x27cd63,_0x14ae6a,[_0x42202f],_0x59c89a);}_0x27cd63['push']({'type':_0x16b4e4('0x1535'),'app':_0x16b4e4('0x614'),'exten':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x1a5b')],'context':_0xe8a1d1[_0x16b4e4('0xff1')][_0x16b4e4('0x22d3')],'priority':_0x48b92d,'VoiceExtensionId':_0xe8a1d1['inboundroute']['id']}),_0x4a0d44['voiceExtension']['addApplications']({'id':_0xe8a1d1['inboundroute']['id']},_0x2e3ca0()[_0x16b4e4('0x742')](_0x27cd63,_0x16b4e4('0xe1e')))[_0x16b4e4('0xe53')][_0x16b4e4('0x683')](function(_0x38f4c5){const _0x2b8ba6=_0x16b4e4;_0xe8a1d1['inboundrouteApps'][_0x2b8ba6('0xf5d')]=_0x38f4c5['rows'];})[_0x16b4e4('0x130a')](function(_0x5c6399){console['error'](_0x5c6399);});}function _0x2c269a(_0x44d87c){const _0x58f422=_0x134e60;_0xe8a1d1[_0x58f422('0x109a')]=_0x44d87c||{'count':0x0,'rows':[]};}function _0x2a2f43(){const _0x410973=_0x134e60;return _0x4a0d44[_0x410973('0x115c')][_0x410973('0x1e6e')]({'fields':_0x410973('0x2072')})[_0x410973('0xe53')][_0x410973('0x683')](function(_0x492e3a){const _0xd9c470=_0x410973;_0xe8a1d1[_0xd9c470('0xe98')]=_0x492e3a;})[_0x410973('0x130a')](function(_0x79a0ba){const _0x21eb41=_0x410973;console[_0x21eb41('0x52a')](_0x79a0ba);});}function _0x58307d(){const _0x3db8a4=_0x134e60;_0xe8a1d1[_0x3db8a4('0x1883')]=_0x4a0d44['voiceExtension'][_0x3db8a4('0x1e6e')](_0xe8a1d1['query'],_0x2c269a)['$promise'];}function _0x1d1d42(_0x4e7dd1){const _0x2c4b88=_0x134e60;_0x2e3ca0()[_0x2c4b88('0x3ec')](_0xe8a1d1['inboundrouteApps'][_0x2c4b88('0xf5d')],{'id':_0x4e7dd1['id']}),_0x38e970(),_0x316048[_0x2c4b88('0x53')]({'title':_0x2c4b88('0x1f71'),'msg':_0x4e7dd1[_0x2c4b88('0x1d75')]?_0x4e7dd1['app']+_0x2c4b88('0x194d'):''});}function _0x477523(_0x2555fd){const _0x497d69=_0x134e60,_0x5d31a6=_0x22709e[_0x497d69('0x1c6f')]()['title'](_0x497d69('0x188'))[_0x497d69('0x26e3')](_0x497d69('0xed5')+_0xe8a1d1[_0x497d69('0x1cca')][_0x497d69('0x1564')]+_0x497d69('0x93c')+_0x497d69('0x1ee7'))['ariaLabel'](_0x497d69('0x1b94'))[_0x497d69('0xe42')](_0x2555fd)['ok']('OK')[_0x497d69('0x19fb')](_0x497d69('0x16b8'));_0x22709e['show'](_0x5d31a6)[_0x497d69('0x683')](function(){const _0x29b1fd=_0x497d69;_0xe8a1d1[_0x29b1fd('0x1cca')][_0x29b1fd('0x1299')](function(_0x513f18){const _0x1dd087=_0x29b1fd;_0x2e3ca0()[_0x1dd087('0x3ec')](_0xe8a1d1[_0x1dd087('0x109a')][_0x1dd087('0xf5d')],{'id':_0x513f18['id']});}),_0xe8a1d1[_0x29b1fd('0x1cca')]=[],_0x38e970();});}}const _0x5d7709=_0x1e6259;_0x43ca34[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x3a7'),'inboundroute',_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x43ca34(_0x359061,_0x36276d,_0x10d71b,_0x2f8919,_0x42505f,_0x231982,_0xc61c39,_0x1aed92){const _0x519aba=_0x189033,_0x34c342=this;_0x34c342[_0x519aba('0x11ed')]=_0xc61c39[_0x519aba('0x20b2')](),_0x34c342['errors']=[],_0x34c342[_0x519aba('0xf28')]=_0x519aba('0x241c')+(_0x2f8919[_0x519aba('0x11f3')]||_0x2f8919[_0x519aba('0x1d75')])['toUpperCase'](),_0x34c342[_0x519aba('0x19ae')]=angular[_0x519aba('0x1a86')](_0x2f8919),_0x34c342[_0x519aba('0x1134')]=_0x1aed92,_0x34c342[_0x519aba('0x258d')]={};if(_0x34c342[_0x519aba('0x19ae')]['appdata'])switch(_0x34c342[_0x519aba('0x19ae')]['appType']?_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x11f3')]['toLowerCase']():_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1d75')][_0x519aba('0x93a')]()){case _0x519aba('0xbf0'):break;case _0x519aba('0x205c'):{const _0x2f2c4d=_0x34c342['agi'][_0x519aba('0x1407')][_0x519aba('0x1fc5')](',');_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1d46')]=_0x2f2c4d[0x0],_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1a1c')]=_0x2f2c4d[0x1],_0x34c342[_0x519aba('0x19ae')]['welcomemessage']=_0x2f2c4d[_0x519aba('0x12c8')](0x2,_0x2f2c4d[_0x519aba('0x1564')])[_0x519aba('0x1630')](',');}break;case'dialogflowv2':{const _0x58c050=_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1407')][_0x519aba('0x1fc5')](',');_0x34c342['agi'][_0x519aba('0x2119')]=_0x58c050[0x0],_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x38')]=_0x58c050[0x1],_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x406')]=_0x58c050[0x2],_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1a1c')]=_0x58c050[0x3],_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x6d9')]=_0x58c050[_0x519aba('0x12c8')](0x4,_0x58c050['length'])[_0x519aba('0x1630')](',');}break;case _0x519aba('0x1db1'):{const _0x246383=_0x34c342[_0x519aba('0x19ae')]['appdata'][_0x519aba('0x1fc5')](',');_0x34c342['agi'][_0x519aba('0x7ae')]=_0x246383[0x0],_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x204a')]=_0x246383[0x1],_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x5ba')]=_0x246383[0x2],_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x11a9')]=_0x246383[0x3],_0x34c342[_0x519aba('0x19ae')]['welcomemessage']=_0x246383['slice'](0x4,_0x246383[_0x519aba('0x1564')])[_0x519aba('0x1630')](',');}break;case _0x519aba('0x2408'):{const _0x31dc19=_0x34c342['agi'][_0x519aba('0x1407')][_0x519aba('0x1fc5')](',');_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x35')]=isNaN(_0x31dc19[0x0])?_0x31dc19[0x0]:parseInt(_0x31dc19[0x0],0xa),_0x34c342['agi']['text']=_0x31dc19['slice'](0x1,_0x31dc19[_0x519aba('0x1564')])[_0x519aba('0x1630')](',');}break;case'message':_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1bcd')]=_0x34c342['agi'][_0x519aba('0x1407')];break;case _0x519aba('0x877'):_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x60a')]=_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1407')][_0x519aba('0x1fc5')]('=')[0x0],_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1c6b')]=_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1407')]['split']('=')[0x1];break;case'agi':_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x273a')]=_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1407')];break;default:{const _0x57a730=_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x1407')][_0x519aba('0x1fc5')](',');_0x34c342['agi'][_0x519aba('0x273a')]=_0x2e3ca0()[_0x519aba('0x173f')](_0x57a730[0x0])?_0x57a730[0x0]:isNaN(_0x57a730[0x0])?_0x57a730[0x0]:parseInt(_0x57a730[0x0],0xa);}break;}else{}_0x34c342[_0x519aba('0x19ae')][_0x519aba('0xcf0')]&&_0x34c342[_0x519aba('0x19ae')][_0x519aba('0xcf0')]['toLowerCase']()===_0x519aba('0x17cd')&&_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x11f3')]['toLowerCase']()===_0x519aba('0x659')&&(_0x34c342[_0x519aba('0x19ae')]['prefix']=_0x34c342[_0x519aba('0x19ae')][_0x519aba('0xd31')]?_0x34c342[_0x519aba('0x19ae')][_0x519aba('0xd31')]['split']('$')[0x0]:undefined,_0x34c342[_0x519aba('0x19ae')]['callerId']=_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x73c')]?_0x519aba('0xac1')+_0x34c342[_0x519aba('0x19ae')][_0x519aba('0x73c')]:undefined);_0x34c342[_0x519aba('0xb')]=_0x19d431,_0x34c342[_0x519aba('0xf82')]=_0x29d106,_0xc61c39[_0x519aba('0xca1')](_0x519aba('0x20c2'))?_0x231982[_0x519aba('0x27ea')][_0x519aba('0x1e6e')]({'fields':'id,name','sort':_0x519aba('0x60a'),'nolimit':_0x519aba('0x26ac')})[_0x519aba('0xe53')][_0x519aba('0x683')](function(_0x4c807d){const _0x1e8044=_0x519aba;_0x34c342[_0x1e8044('0x1248')]=_0x4c807d[_0x1e8044('0xf5d')]||[];})[_0x519aba('0x130a')](function(_0x133333){const _0x4e1970=_0x519aba;_0x10d71b[_0x4e1970('0x52a')]({'title':_0x133333['status']?_0x4e1970('0x2168')+_0x133333[_0x4e1970('0x13ee')]+_0x4e1970('0xbf6')+_0x133333[_0x4e1970('0x24a9')]:_0x4e1970('0xd0e'),'msg':_0x133333[_0x4e1970('0x5a5')]?JSON['stringify'](_0x133333['data']):_0x133333[_0x4e1970('0x1ff0')]()});}):_0x231982['squareProject'][_0x519aba('0x1e6e')]({'fields':'id,name','sort':_0x519aba('0x60a'),'nolimit':'true'})[_0x519aba('0xe53')][_0x519aba('0x683')](function(_0x3f040a){const _0x3b4a5c=_0x519aba;_0x34c342[_0x3b4a5c('0x1248')]=_0x3f040a[_0x3b4a5c('0xf5d')]||[];})[_0x519aba('0x683')](function(){const _0x3918e5=_0x519aba;return _0x231982['userProfileSection'][_0x3918e5('0x1e6e')]({'userProfileId':_0x34c342['currentUser'][_0x3918e5('0x2f')],'sectionId':0x44f})[_0x3918e5('0xe53')];})['then'](function(_0x159d87){const _0x1c5f3e=_0x519aba,_0x4b201f=_0x159d87&&_0x159d87[_0x1c5f3e('0xf5d')]?_0x159d87['rows'][0x0]:null;if(!_0x4b201f){const _0x3c2c5e=[];let _0x3391eb=null;_0x34c342[_0x1c5f3e('0x19ae')]&&(_0x3391eb=_0x2e3ca0()[_0x1c5f3e('0x1c07')](_0x34c342[_0x1c5f3e('0x1248')],{'name':_0x34c342[_0x1c5f3e('0x19ae')][_0x1c5f3e('0x273a')]}));for(let _0x1ee26b=0x0;_0x1ee26b<_0x34c342[_0x1c5f3e('0x1248')]['length'];_0x1ee26b++){_0x3391eb&&_0x34c342[_0x1c5f3e('0x1248')][_0x1ee26b]['id']===_0x3391eb['id']&&(_0x34c342[_0x1c5f3e('0x1248')][_0x1ee26b][_0x1c5f3e('0x319')]=![],_0x3c2c5e['push'](_0x34c342[_0x1c5f3e('0x1248')][_0x1ee26b]));}_0x34c342[_0x1c5f3e('0x1248')]=_0x3c2c5e;}else{if(!_0x4b201f['autoAssociation'])return _0x231982[_0x1c5f3e('0xcf7')]['get']({'sectionId':_0x4b201f['id']})[_0x1c5f3e('0xe53')][_0x1c5f3e('0x683')](function(_0x2fc9f5){const _0x129af0=_0x1c5f3e,_0x423d02=_0x2e3ca0()[_0x129af0('0x386')](_0x2fc9f5['rows'],function(_0x581508){const _0x3a7e07=_0x129af0;return _0x2e3ca0()[_0x3a7e07('0x1c07')](_0x34c342['projects'],{'id':_0x581508[_0x3a7e07('0x832')]});});let _0x442e6c=null;_0x34c342[_0x129af0('0x19ae')]&&(_0x442e6c=_0x2e3ca0()['find'](_0x34c342[_0x129af0('0x1248')],{'name':_0x34c342[_0x129af0('0x19ae')][_0x129af0('0x273a')]}));if(_0x442e6c&&!_0x2e3ca0()[_0x129af0('0x7a2')](_0x423d02,['id',_0x442e6c['id']])){const _0x253ef0=_0x2e3ca0()[_0x129af0('0x1c07')](_0x34c342[_0x129af0('0x1248')],{'id':_0x442e6c['id']});_0x253ef0[_0x129af0('0x319')]=![],_0x423d02[_0x129af0('0x1fd0')](_0x253ef0);}_0x34c342['projects']=_0x423d02;});}})['catch'](function(_0x5986d9){const _0x37cf4f=_0x519aba;_0x10d71b[_0x37cf4f('0x52a')]({'title':_0x5986d9[_0x37cf4f('0x13ee')]?'API:'+_0x5986d9[_0x37cf4f('0x13ee')]+_0x37cf4f('0xbf6')+_0x5986d9[_0x37cf4f('0x24a9')]:_0x37cf4f('0x616'),'msg':_0x5986d9[_0x37cf4f('0x5a5')]?JSON[_0x37cf4f('0x258a')](_0x5986d9[_0x37cf4f('0x5a5')]):_0x5986d9[_0x37cf4f('0x1ff0')]()});});function _0x19d431(){const _0x13065d=_0x519aba;_0x34c342['errors']=[];const _0x463a9f=[];_0x34c342[_0x13065d('0x19ae')][_0x13065d('0xcf0')]&&_0x34c342['agi'][_0x13065d('0xcf0')][_0x13065d('0x93a')]()===_0x13065d('0x17cd')&&_0x34c342['agi'][_0x13065d('0x11f3')]==='outboundDial'&&(_0x34c342[_0x13065d('0x19ae')]['phone']=_0x42505f[_0x13065d('0x145a')]?(_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x24fa')]||'')+_0x13065d('0x249e')+_0x42505f[_0x13065d('0x145a')]+'}':(_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x24fa')]||'')+_0x13065d('0x20cb'),_0x42505f['recordingFormat']!==_0x13065d('0x925')?_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x158e')][_0x13065d('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x158e')]+=_0x13065d('0x1b1')):_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x158e')]=_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x158e')]['replace']('U(xcally-mixmonitor-context)',''));if(_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x11f3')]&&_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x11f3')]==='custom'){}else switch((_0x34c342['agi'][_0x13065d('0x1d75')]||_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x11f3')])[_0x13065d('0x93a')]()){case'set':_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x1407')]=_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x60a')]+'='+_0x34c342[_0x13065d('0x19ae')]['value'];break;case _0x13065d('0xbf0'):break;default:_0x463a9f[0x0]=_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x273a')],_0x34c342[_0x13065d('0x19ae')][_0x13065d('0x1407')]=_0x463a9f[_0x13065d('0x1630')](',');}_0x29d106(_0x34c342[_0x13065d('0x19ae')]);}function _0x29d106(_0x51d428){const _0x310ab1=_0x519aba;_0x359061[_0x310ab1('0x1715')](_0x51d428);}}const _0x2ee738=_0x43ca34;_0x245e93['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x3a7'),'inboundroute',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x245e93(_0x4edc54,_0x1b47c7,_0x25ad64,_0x4e4512,_0x344f4a,_0x2afe25,_0x17b6c6,_0x3b1abb){const _0xc3a89f=_0x189033,_0x23bb7b=this;_0x23bb7b[_0xc3a89f('0x11ed')]=_0x17b6c6['getCurrentUser'](),_0x23bb7b[_0xc3a89f('0x17f')]=[],_0x23bb7b[_0xc3a89f('0xf28')]=_0xc3a89f('0x241c')+(_0x4e4512[_0xc3a89f('0x11f3')]||_0x4e4512[_0xc3a89f('0x1d75')])[_0xc3a89f('0x80')](),_0x23bb7b[_0xc3a89f('0xbf0')]=angular['copy'](_0x4e4512),_0x23bb7b[_0xc3a89f('0x1134')]=_0x3b1abb,_0x23bb7b['hasModulePermissions']={};if(_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1407')])switch(_0x23bb7b['custom'][_0xc3a89f('0x11f3')]?_0x23bb7b['custom']['appType']['toLowerCase']():_0x23bb7b['custom'][_0xc3a89f('0x1d75')][_0xc3a89f('0x93a')]()){case _0xc3a89f('0xbf0'):break;case _0xc3a89f('0x205c'):{const _0x20eb01=_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1407')]['split'](',');_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1d46')]=_0x20eb01[0x0],_0x23bb7b['custom'][_0xc3a89f('0x1a1c')]=_0x20eb01[0x1],_0x23bb7b['custom'][_0xc3a89f('0x6d9')]=_0x20eb01[_0xc3a89f('0x12c8')](0x2,_0x20eb01[_0xc3a89f('0x1564')])[_0xc3a89f('0x1630')](',');}break;case _0xc3a89f('0xd24'):{const _0x35c5a4=_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1407')][_0xc3a89f('0x1fc5')](',');_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x2119')]=_0x35c5a4[0x0],_0x23bb7b[_0xc3a89f('0xbf0')]['clientEmail']=_0x35c5a4[0x1],_0x23bb7b['custom'][_0xc3a89f('0x406')]=_0x35c5a4[0x2],_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1a1c')]=_0x35c5a4[0x3],_0x23bb7b['custom']['welcomemessage']=_0x35c5a4['slice'](0x4,_0x35c5a4[_0xc3a89f('0x1564')])['join'](',');}break;case _0xc3a89f('0x1db1'):{const _0x43bf5e=_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1407')][_0xc3a89f('0x1fc5')](',');_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x7ae')]=_0x43bf5e[0x0],_0x23bb7b[_0xc3a89f('0xbf0')]['secretaccesskey']=_0x43bf5e[0x1],_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x5ba')]=_0x43bf5e[0x2],_0x23bb7b[_0xc3a89f('0xbf0')]['botname']=_0x43bf5e[0x3],_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x6d9')]=_0x43bf5e[_0xc3a89f('0x12c8')](0x4,_0x43bf5e[_0xc3a89f('0x1564')])['join'](',');}break;case _0xc3a89f('0x2408'):{const _0x4fe0c4=_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1407')][_0xc3a89f('0x1fc5')](',');_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x35')]=isNaN(_0x4fe0c4[0x0])?_0x4fe0c4[0x0]:parseInt(_0x4fe0c4[0x0],0xa),_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1bcd')]=_0x4fe0c4[_0xc3a89f('0x12c8')](0x1,_0x4fe0c4[_0xc3a89f('0x1564')])['join'](',');}break;case _0xc3a89f('0x8c2'):_0x23bb7b['custom'][_0xc3a89f('0x1bcd')]=_0x23bb7b['custom']['appdata'];break;case'set':_0x23bb7b[_0xc3a89f('0xbf0')]['name']=_0x23bb7b['custom']['appdata'][_0xc3a89f('0x1fc5')]('=')[0x0],_0x23bb7b[_0xc3a89f('0xbf0')]['value']=_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1407')][_0xc3a89f('0x1fc5')]('=')[0x1];break;case _0xc3a89f('0x19ae'):_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x273a')]=_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1407')];break;default:{const _0x22d597=_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1407')][_0xc3a89f('0x1fc5')](',');_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0x1d75')]=_0x2e3ca0()[_0xc3a89f('0x173f')](_0x22d597[0x0])?_0x22d597[0x0]:isNaN(_0x22d597[0x0])?_0x22d597[0x0]:parseInt(_0x22d597[0x0],0xa),_0x23bb7b[_0xc3a89f('0xbf0')]['appdata']=_0x2e3ca0()[_0xc3a89f('0x173f')](_0x22d597[0x1])?_0x22d597[0x1]:isNaN(_0x22d597[0x1])?_0x22d597[0x1]:parseInt(_0x22d597[0x1],0xa);}break;}else{}_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0xcf0')]&&_0x23bb7b[_0xc3a89f('0xbf0')]['type'][_0xc3a89f('0x93a')]()===_0xc3a89f('0x17cd')&&_0x23bb7b['custom']['appType'][_0xc3a89f('0x93a')]()===_0xc3a89f('0x659')&&(_0x23bb7b['custom']['prefix']=_0x23bb7b[_0xc3a89f('0xbf0')][_0xc3a89f('0xd31')]?_0x23bb7b['custom']['phone'][_0xc3a89f('0x1fc5')]('$')[0x0]:undefined,_0x23bb7b['custom'][_0xc3a89f('0xabd')]=_0x23bb7b[_0xc3a89f('0xbf0')]['callerID']?_0xc3a89f('0xac1')+_0x23bb7b['custom'][_0xc3a89f('0x73c')]:undefined);_0x23bb7b[_0xc3a89f('0xb')]=_0x49f551,_0x23bb7b['closeDialog']=_0x217606;function _0x49f551(){const _0x535c2f=_0xc3a89f;_0x23bb7b[_0x535c2f('0x17f')]=[];const _0x2e7715=[];_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0xcf0')]&&_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0xcf0')][_0x535c2f('0x93a')]()===_0x535c2f('0x17cd')&&_0x23bb7b[_0x535c2f('0xbf0')]['appType']===_0x535c2f('0x4d2')&&(_0x23bb7b['custom'][_0x535c2f('0xd31')]=_0x344f4a['cutdigits']?(_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x24fa')]||'')+_0x535c2f('0x249e')+_0x344f4a[_0x535c2f('0x145a')]+'}':(_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x24fa')]||'')+_0x535c2f('0x20cb'),_0x344f4a[_0x535c2f('0x75b')]!==_0x535c2f('0x925')?_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x158e')]['indexOf'](_0x535c2f('0x1b1'))<0x0&&(_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x158e')]+='U(xcally-mixmonitor-context)'):_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x158e')]=_0x23bb7b[_0x535c2f('0xbf0')]['options'][_0x535c2f('0x1725')](_0x535c2f('0x1b1'),''));if(_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x11f3')]&&_0x23bb7b[_0x535c2f('0xbf0')]['appType']===_0x535c2f('0xbf0')){}else switch((_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x1d75')]||_0x23bb7b[_0x535c2f('0xbf0')]['appType'])[_0x535c2f('0x93a')]()){case _0x535c2f('0x877'):_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x1407')]=_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x60a')]+'='+_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x1c6b')];break;case _0x535c2f('0xbf0'):break;default:_0x2e7715[0x0]=_0x23bb7b['custom'][_0x535c2f('0x1d75')],_0x2e7715[0x1]=_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x1407')],_0x23bb7b[_0x535c2f('0xbf0')][_0x535c2f('0x1407')]=_0x2e7715['join'](',');}_0x217606(_0x23bb7b[_0x535c2f('0xbf0')]);}function _0x217606(_0x33ccc9){const _0x121b86=_0xc3a89f;_0x4edc54[_0x121b86('0x1715')](_0x33ccc9);}}const _0x1e9721=_0x245e93;_0x12319c[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x3a7'),_0x189033('0xff1'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x12319c(_0xc817c4,_0x1ca64b,_0x47d6d4,_0x812621,_0x1f802c,_0x154b79,_0x5eb5f6,_0x39a316){const _0x3830cd=_0x189033,_0x1f61af=this;_0x1f61af['currentUser']=_0x5eb5f6['getCurrentUser'](),_0x1f61af[_0x3830cd('0x17f')]=[],_0x1f61af[_0x3830cd('0xf28')]=_0x3830cd('0x241c')+(_0x812621[_0x3830cd('0x11f3')]||_0x812621[_0x3830cd('0x1d75')])['toUpperCase'](),_0x1f61af[_0x3830cd('0x401')]=angular['copy'](_0x812621),_0x1f61af[_0x3830cd('0x1134')]=_0x39a316,_0x1f61af[_0x3830cd('0x258d')]={};if(_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1407')])switch(_0x1f61af['dial']['appType']?_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x11f3')][_0x3830cd('0x93a')]():_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1d75')][_0x3830cd('0x93a')]()){case _0x3830cd('0xbf0'):break;case _0x3830cd('0x205c'):{const _0x49a68b=_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1407')]['split'](',');_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1d46')]=_0x49a68b[0x0],_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1a1c')]=_0x49a68b[0x1],_0x1f61af['dial'][_0x3830cd('0x6d9')]=_0x49a68b[_0x3830cd('0x12c8')](0x2,_0x49a68b[_0x3830cd('0x1564')])[_0x3830cd('0x1630')](',');}break;case'dialogflowv2':{const _0xf7a586=_0x1f61af['dial'][_0x3830cd('0x1407')][_0x3830cd('0x1fc5')](',');_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x2119')]=_0xf7a586[0x0],_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x38')]=_0xf7a586[0x1],_0x1f61af[_0x3830cd('0x401')]['privateKey']=_0xf7a586[0x2],_0x1f61af['dial'][_0x3830cd('0x1a1c')]=_0xf7a586[0x3],_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x6d9')]=_0xf7a586['slice'](0x4,_0xf7a586[_0x3830cd('0x1564')])['join'](',');}break;case _0x3830cd('0x1db1'):{const _0x1e42ce=_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1407')][_0x3830cd('0x1fc5')](',');_0x1f61af[_0x3830cd('0x401')]['accesskeyid']=_0x1e42ce[0x0],_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x204a')]=_0x1e42ce[0x1],_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x5ba')]=_0x1e42ce[0x2],_0x1f61af['dial']['botname']=_0x1e42ce[0x3],_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x6d9')]=_0x1e42ce[_0x3830cd('0x12c8')](0x4,_0x1e42ce[_0x3830cd('0x1564')])['join'](',');}break;case _0x3830cd('0x2408'):{const _0x29d8ec=_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1407')][_0x3830cd('0x1fc5')](',');_0x1f61af['dial'][_0x3830cd('0x35')]=isNaN(_0x29d8ec[0x0])?_0x29d8ec[0x0]:parseInt(_0x29d8ec[0x0],0xa),_0x1f61af['dial'][_0x3830cd('0x1bcd')]=_0x29d8ec[_0x3830cd('0x12c8')](0x1,_0x29d8ec['length'])[_0x3830cd('0x1630')](',');}break;case _0x3830cd('0x8c2'):_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1bcd')]=_0x1f61af['dial'][_0x3830cd('0x1407')];break;case _0x3830cd('0x877'):_0x1f61af['dial']['name']=_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1407')][_0x3830cd('0x1fc5')]('=')[0x0],_0x1f61af['dial'][_0x3830cd('0x1c6b')]=_0x1f61af[_0x3830cd('0x401')]['appdata'][_0x3830cd('0x1fc5')]('=')[0x1];break;case _0x3830cd('0x19ae'):_0x1f61af['dial'][_0x3830cd('0x273a')]=_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1407')];break;default:{const _0x3ac76e=_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1407')][_0x3830cd('0x1fc5')](',');_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1e0f')]=_0x2e3ca0()[_0x3830cd('0x173f')](_0x3ac76e[0x0])?_0x3ac76e[0x0]:isNaN(_0x3ac76e[0x0])?_0x3ac76e[0x0]:parseInt(_0x3ac76e[0x0],0xa),_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x1668')]=_0x2e3ca0()[_0x3830cd('0x173f')](_0x3ac76e[0x1])?_0x3ac76e[0x1]:isNaN(_0x3ac76e[0x1])?_0x3ac76e[0x1]:parseInt(_0x3ac76e[0x1],0xa),_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x158e')]=_0x2e3ca0()[_0x3830cd('0x173f')](_0x3ac76e[0x2])?_0x3ac76e[0x2]:isNaN(_0x3ac76e[0x2])?_0x3ac76e[0x2]:parseInt(_0x3ac76e[0x2],0xa),_0x1f61af['dial'][_0x3830cd('0x1284')]=_0x2e3ca0()[_0x3830cd('0x173f')](_0x3ac76e[0x3])?_0x3ac76e[0x3]:isNaN(_0x3ac76e[0x3])?_0x3ac76e[0x3]:parseInt(_0x3ac76e[0x3],0xa);}break;}else{}_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0xcf0')]&&_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0xcf0')]['toLowerCase']()==='outbound'&&_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x11f3')][_0x3830cd('0x93a')]()===_0x3830cd('0x659')&&(_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x24fa')]=_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0xd31')]?_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0xd31')]['split']('$')[0x0]:undefined,_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0xabd')]=_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x73c')]?_0x3830cd('0xac1')+_0x1f61af[_0x3830cd('0x401')][_0x3830cd('0x73c')]:undefined);_0x1f61af[_0x3830cd('0xb')]=_0xd792dc,_0x1f61af[_0x3830cd('0xf82')]=_0x58bccd;function _0xd792dc(){const _0xc5ca01=_0x3830cd;_0x1f61af[_0xc5ca01('0x17f')]=[];const _0x50221c=[];_0x1f61af['dial'][_0xc5ca01('0xcf0')]&&_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0xcf0')]['toLowerCase']()===_0xc5ca01('0x17cd')&&_0x1f61af['dial'][_0xc5ca01('0x11f3')]===_0xc5ca01('0x4d2')&&(_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0xd31')]=_0x1f802c['cutdigits']?(_0x1f61af['dial'][_0xc5ca01('0x24fa')]||'')+_0xc5ca01('0x249e')+_0x1f802c[_0xc5ca01('0x145a')]+'}':(_0x1f61af[_0xc5ca01('0x401')]['prefix']||'')+_0xc5ca01('0x20cb'),_0x1f802c[_0xc5ca01('0x75b')]!=='none'?_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0x158e')][_0xc5ca01('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x1f61af[_0xc5ca01('0x401')]['options']+=_0xc5ca01('0x1b1')):_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0x158e')]=_0x1f61af['dial'][_0xc5ca01('0x158e')][_0xc5ca01('0x1725')]('U(xcally-mixmonitor-context)',''));if(_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0x11f3')]&&_0x1f61af['dial'][_0xc5ca01('0x11f3')]===_0xc5ca01('0xbf0')){}else switch((_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0x1d75')]||_0x1f61af[_0xc5ca01('0x401')]['appType'])['toLowerCase']()){case'set':_0x1f61af['dial'][_0xc5ca01('0x1407')]=_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0x60a')]+'='+_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0x1c6b')];break;case _0xc5ca01('0xbf0'):break;default:_0x50221c[0x0]=_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0x1e0f')],_0x50221c[0x1]=_0x1f61af[_0xc5ca01('0x401')]['timeout'],_0x50221c[0x2]=_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0x158e')],_0x50221c[0x3]=_0x1f61af[_0xc5ca01('0x401')]['url'],_0x1f61af[_0xc5ca01('0x401')][_0xc5ca01('0x1407')]=_0x50221c['join'](',');}_0x58bccd(_0x1f61af[_0xc5ca01('0x401')]);}function _0x58bccd(_0x170464){const _0x55a553=_0x3830cd;_0xc817c4[_0x55a553('0x1715')](_0x170464);}}const _0xa68b82=_0x12319c;_0x58e06e[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x3a7'),_0x189033('0xff1'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x58e06e(_0x113f8b,_0x3da3a1,_0x3a0305,_0x5e3357,_0x30e6b5,_0x3980f1,_0x2a7cfc,_0x30b3a0){const _0xa275c2=_0x189033,_0x1f7964=this;_0x1f7964['currentUser']=_0x2a7cfc[_0xa275c2('0x20b2')](),_0x1f7964[_0xa275c2('0x17f')]=[],_0x1f7964[_0xa275c2('0xf28')]=_0xa275c2('0x241c')+(_0x5e3357[_0xa275c2('0x11f3')]||_0x5e3357[_0xa275c2('0x1d75')])[_0xa275c2('0x80')](),_0x1f7964[_0xa275c2('0x4fe')]=angular[_0xa275c2('0x1a86')](_0x5e3357),_0x1f7964['crudPermissions']=_0x30b3a0,_0x1f7964[_0xa275c2('0x258d')]={};if(_0x1f7964['externaldial'][_0xa275c2('0x1407')])switch(_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x11f3')]?_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x11f3')][_0xa275c2('0x93a')]():_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1d75')]['toLowerCase']()){case _0xa275c2('0xbf0'):break;case _0xa275c2('0x205c'):{const _0x2d04fd=_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1407')][_0xa275c2('0x1fc5')](',');_0x1f7964['externaldial'][_0xa275c2('0x1d46')]=_0x2d04fd[0x0],_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1a1c')]=_0x2d04fd[0x1],_0x1f7964[_0xa275c2('0x4fe')]['welcomemessage']=_0x2d04fd[_0xa275c2('0x12c8')](0x2,_0x2d04fd[_0xa275c2('0x1564')])[_0xa275c2('0x1630')](',');}break;case _0xa275c2('0xd24'):{const _0x4648b7=_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1407')][_0xa275c2('0x1fc5')](',');_0x1f7964[_0xa275c2('0x4fe')]['projectId']=_0x4648b7[0x0],_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x38')]=_0x4648b7[0x1],_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x406')]=_0x4648b7[0x2],_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1a1c')]=_0x4648b7[0x3],_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x6d9')]=_0x4648b7[_0xa275c2('0x12c8')](0x4,_0x4648b7[_0xa275c2('0x1564')])[_0xa275c2('0x1630')](',');}break;case _0xa275c2('0x1db1'):{const _0x2ae053=_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1407')][_0xa275c2('0x1fc5')](',');_0x1f7964[_0xa275c2('0x4fe')]['accesskeyid']=_0x2ae053[0x0],_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x204a')]=_0x2ae053[0x1],_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x5ba')]=_0x2ae053[0x2],_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x11a9')]=_0x2ae053[0x3],_0x1f7964['externaldial']['welcomemessage']=_0x2ae053['slice'](0x4,_0x2ae053[_0xa275c2('0x1564')])[_0xa275c2('0x1630')](',');}break;case _0xa275c2('0x2408'):{const _0x359652=_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1407')][_0xa275c2('0x1fc5')](',');_0x1f7964['externaldial']['times']=isNaN(_0x359652[0x0])?_0x359652[0x0]:parseInt(_0x359652[0x0],0xa),_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1bcd')]=_0x359652[_0xa275c2('0x12c8')](0x1,_0x359652['length'])[_0xa275c2('0x1630')](',');}break;case _0xa275c2('0x8c2'):_0x1f7964['externaldial'][_0xa275c2('0x1bcd')]=_0x1f7964[_0xa275c2('0x4fe')]['appdata'];break;case'set':_0x1f7964[_0xa275c2('0x4fe')]['name']=_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1407')][_0xa275c2('0x1fc5')]('=')[0x0],_0x1f7964[_0xa275c2('0x4fe')]['value']=_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1407')][_0xa275c2('0x1fc5')]('=')[0x1];break;case'agi':_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x273a')]=_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1407')];break;default:{const _0x4bc511=_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1407')][_0xa275c2('0x1fc5')](',');_0x1f7964['externaldial'][_0xa275c2('0x1a93')]=_0x4bc511[0x0][_0xa275c2('0x1fc5')]('/')[0x1],_0x1f7964['externaldial'][_0xa275c2('0xd31')]=_0x4bc511[0x0][_0xa275c2('0x1fc5')]('/')[0x2],_0x1f7964[_0xa275c2('0x4fe')]['timeout']=_0x2e3ca0()[_0xa275c2('0x173f')](_0x4bc511[0x1])?_0x4bc511[0x1]:isNaN(_0x4bc511[0x1])?_0x4bc511[0x1]:parseInt(_0x4bc511[0x1],0xa),_0x1f7964[_0xa275c2('0x4fe')]['options']=_0x2e3ca0()['isEmpty'](_0x4bc511[0x2])?_0x4bc511[0x2]:isNaN(_0x4bc511[0x2])?_0x4bc511[0x2]:parseInt(_0x4bc511[0x2],0xa),_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x1284')]=_0x2e3ca0()['isEmpty'](_0x4bc511[0x3])?_0x4bc511[0x3]:isNaN(_0x4bc511[0x3])?_0x4bc511[0x3]:parseInt(_0x4bc511[0x3],0xa);}break;}else{}_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0xcf0')]&&_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0xcf0')][_0xa275c2('0x93a')]()===_0xa275c2('0x17cd')&&_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x11f3')][_0xa275c2('0x93a')]()===_0xa275c2('0x659')&&(_0x1f7964[_0xa275c2('0x4fe')]['prefix']=_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0xd31')]?_0x1f7964[_0xa275c2('0x4fe')]['phone']['split']('$')[0x0]:undefined,_0x1f7964['externaldial'][_0xa275c2('0xabd')]=_0x1f7964[_0xa275c2('0x4fe')]['callerID']?'CALLERID(all)='+_0x1f7964[_0xa275c2('0x4fe')][_0xa275c2('0x73c')]:undefined);_0x1f7964[_0xa275c2('0xb')]=_0x4db0c4,_0x1f7964['closeDialog']=_0x23cb3f,_0x2a7cfc[_0xa275c2('0xca1')](_0xa275c2('0x20c2'))?_0x3980f1[_0xa275c2('0x1a93')][_0xa275c2('0x1e6e')]({'fields':_0xa275c2('0xa10'),'sort':_0xa275c2('0x60a'),'nolimit':'true'})[_0xa275c2('0xe53')][_0xa275c2('0x683')](function(_0x176708){_0x1f7964['trunks']=_0x176708['rows']||[];})[_0xa275c2('0x130a')](function(_0x3a6258){const _0x9fa19d=_0xa275c2;_0x3a0305[_0x9fa19d('0x52a')]({'title':_0x3a6258['status']?_0x9fa19d('0x2168')+_0x3a6258[_0x9fa19d('0x13ee')]+_0x9fa19d('0xbf6')+_0x3a6258['statusText']:_0x9fa19d('0xfd0'),'msg':_0x3a6258[_0x9fa19d('0x5a5')]?JSON[_0x9fa19d('0x258a')](_0x3a6258[_0x9fa19d('0x5a5')]):_0x3a6258['toString']()});}):_0x3980f1[_0xa275c2('0x1a93')][_0xa275c2('0x1e6e')]({'fields':_0xa275c2('0xa10'),'sort':_0xa275c2('0x60a'),'nolimit':_0xa275c2('0x26ac')})[_0xa275c2('0xe53')][_0xa275c2('0x683')](function(_0xfbd2e8){const _0xf9ec1=_0xa275c2;_0x1f7964[_0xf9ec1('0x20fe')]=_0xfbd2e8[_0xf9ec1('0xf5d')]||[];})[_0xa275c2('0x683')](function(){const _0x39bdde=_0xa275c2;return _0x3980f1['userProfileSection'][_0x39bdde('0x1e6e')]({'userProfileId':_0x1f7964['currentUser'][_0x39bdde('0x2f')],'sectionId':0x3f3})['$promise'];})[_0xa275c2('0x683')](function(_0x31b38e){const _0x2db987=_0xa275c2,_0x3bd7d5=_0x31b38e&&_0x31b38e['rows']?_0x31b38e[_0x2db987('0xf5d')][0x0]:null;if(!_0x3bd7d5){const _0x5e0bdc=[];let _0x41b027=null;_0x1f7964[_0x2db987('0x4fe')]&&(_0x41b027=_0x2e3ca0()[_0x2db987('0x1c07')](_0x1f7964[_0x2db987('0x20fe')],{'name':_0x1f7964[_0x2db987('0x4fe')][_0x2db987('0x1a93')]}));for(let _0x179caa=0x0;_0x179caa<_0x1f7964['trunks'][_0x2db987('0x1564')];_0x179caa++){_0x41b027&&_0x1f7964['trunks'][_0x179caa]['id']===_0x41b027['id']&&(_0x1f7964[_0x2db987('0x20fe')][_0x179caa][_0x2db987('0x319')]=![],_0x5e0bdc[_0x2db987('0x1fd0')](_0x1f7964[_0x2db987('0x20fe')][_0x179caa]));}_0x1f7964[_0x2db987('0x20fe')]=_0x5e0bdc;}else{if(!_0x3bd7d5[_0x2db987('0x170')])return _0x3980f1['userProfileResource'][_0x2db987('0x1e6e')]({'sectionId':_0x3bd7d5['id']})[_0x2db987('0xe53')]['then'](function(_0x613273){const _0xadb19=_0x2db987,_0x2126ea=_0x2e3ca0()[_0xadb19('0x386')](_0x613273[_0xadb19('0xf5d')],function(_0x36525b){const _0x23524d=_0xadb19;return _0x2e3ca0()[_0x23524d('0x1c07')](_0x1f7964[_0x23524d('0x20fe')],{'id':_0x36525b['resourceId']});});let _0x57533d=null;_0x1f7964[_0xadb19('0x4fe')]&&(_0x57533d=_0x2e3ca0()[_0xadb19('0x1c07')](_0x1f7964[_0xadb19('0x20fe')],{'name':_0x1f7964[_0xadb19('0x4fe')]['trunk']}));if(_0x57533d&&!_0x2e3ca0()[_0xadb19('0x7a2')](_0x2126ea,['id',_0x57533d['id']])){const _0x388e52=_0x2e3ca0()['find'](_0x1f7964['trunks'],{'id':_0x57533d['id']});_0x388e52[_0xadb19('0x319')]=![],_0x2126ea[_0xadb19('0x1fd0')](_0x388e52);}_0x1f7964[_0xadb19('0x20fe')]=_0x2126ea;});}})[_0xa275c2('0x130a')](function(_0x434092){const _0x97b2b4=_0xa275c2;_0x3a0305['error']({'title':_0x434092[_0x97b2b4('0x13ee')]?_0x97b2b4('0x2168')+_0x434092[_0x97b2b4('0x13ee')]+_0x97b2b4('0xbf6')+_0x434092[_0x97b2b4('0x24a9')]:_0x97b2b4('0x93'),'msg':_0x434092['data']?JSON['stringify'](_0x434092[_0x97b2b4('0x5a5')]):_0x434092[_0x97b2b4('0x1ff0')]()});});function _0x4db0c4(){const _0x1d9966=_0xa275c2;_0x1f7964[_0x1d9966('0x17f')]=[];const _0x3833c9=[];_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0xcf0')]&&_0x1f7964[_0x1d9966('0x4fe')]['type']['toLowerCase']()===_0x1d9966('0x17cd')&&_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x11f3')]==='outboundDial'&&(_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0xd31')]=_0x30e6b5[_0x1d9966('0x145a')]?(_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x24fa')]||'')+_0x1d9966('0x249e')+_0x30e6b5[_0x1d9966('0x145a')]+'}':(_0x1f7964[_0x1d9966('0x4fe')]['prefix']||'')+_0x1d9966('0x20cb'),_0x30e6b5[_0x1d9966('0x75b')]!==_0x1d9966('0x925')?_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x158e')][_0x1d9966('0x824')](_0x1d9966('0x1b1'))<0x0&&(_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x158e')]+=_0x1d9966('0x1b1')):_0x1f7964[_0x1d9966('0x4fe')]['options']=_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x158e')]['replace'](_0x1d9966('0x1b1'),''));if(_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x11f3')]&&_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x11f3')]===_0x1d9966('0xbf0')){}else switch((_0x1f7964[_0x1d9966('0x4fe')]['app']||_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x11f3')])[_0x1d9966('0x93a')]()){case _0x1d9966('0x877'):_0x1f7964[_0x1d9966('0x4fe')]['appdata']=_0x1f7964['externaldial'][_0x1d9966('0x60a')]+'='+_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x1c6b')];break;case _0x1d9966('0xbf0'):break;default:_0x3833c9[0x0]=[_0x1d9966('0xcec'),_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x1a93')],_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0xd31')]]['join']('/'),_0x3833c9[0x1]=_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x1668')],_0x3833c9[0x2]=_0x1f7964['externaldial'][_0x1d9966('0x158e')],_0x3833c9[0x3]=_0x1f7964[_0x1d9966('0x4fe')][_0x1d9966('0x1284')],_0x1f7964[_0x1d9966('0x4fe')]['appdata']=_0x3833c9['join'](',');}_0x23cb3f(_0x1f7964['externaldial']);}function _0x23cb3f(_0x44d151){const _0x442cb2=_0xa275c2;_0x113f8b[_0x442cb2('0x1715')](_0x44d151);}}const _0x4da5aa=_0x58e06e;_0x1ab9b3['$inject']=[_0x189033('0x1e48'),'$q','toasty','inboundrouteApp',_0x189033('0xff1'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x1ab9b3(_0x55c2ad,_0x4bf51b,_0xb56c12,_0x17ab4f,_0x4bbe0d,_0x1ac15b,_0x4d9108,_0x21e9ea){const _0x535915=_0x189033,_0x2c7b0b=this;_0x2c7b0b[_0x535915('0x11ed')]=_0x4d9108[_0x535915('0x20b2')](),_0x2c7b0b['errors']=[],_0x2c7b0b[_0x535915('0xf28')]='VOICE.EDIT_'+(_0x17ab4f['appType']||_0x17ab4f[_0x535915('0x1d75')])[_0x535915('0x80')](),_0x2c7b0b['goto']=angular[_0x535915('0x1a86')](_0x17ab4f),_0x2c7b0b[_0x535915('0x1134')]=_0x21e9ea,_0x2c7b0b[_0x535915('0x258d')]={};if(_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x1407')])switch(_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x11f3')]?_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x11f3')][_0x535915('0x93a')]():_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x1d75')][_0x535915('0x93a')]()){case _0x535915('0xbf0'):break;case _0x535915('0x205c'):{const _0x4da500=_0x2c7b0b[_0x535915('0x27fe')]['appdata'][_0x535915('0x1fc5')](',');_0x2c7b0b[_0x535915('0x27fe')]['key']=_0x4da500[0x0],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x1a1c')]=_0x4da500[0x1],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x6d9')]=_0x4da500['slice'](0x2,_0x4da500[_0x535915('0x1564')])[_0x535915('0x1630')](',');}break;case'dialogflowv2':{const _0x5949d5=_0x2c7b0b['goto'][_0x535915('0x1407')][_0x535915('0x1fc5')](',');_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x2119')]=_0x5949d5[0x0],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x38')]=_0x5949d5[0x1],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x406')]=_0x5949d5[0x2],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x1a1c')]=_0x5949d5[0x3],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x6d9')]=_0x5949d5[_0x535915('0x12c8')](0x4,_0x5949d5[_0x535915('0x1564')])[_0x535915('0x1630')](',');}break;case _0x535915('0x1db1'):{const _0x1a149b=_0x2c7b0b['goto'][_0x535915('0x1407')][_0x535915('0x1fc5')](',');_0x2c7b0b[_0x535915('0x27fe')]['accesskeyid']=_0x1a149b[0x0],_0x2c7b0b['goto'][_0x535915('0x204a')]=_0x1a149b[0x1],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x5ba')]=_0x1a149b[0x2],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x11a9')]=_0x1a149b[0x3],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x6d9')]=_0x1a149b['slice'](0x4,_0x1a149b[_0x535915('0x1564')])['join'](',');}break;case'autoreply':{const _0x35c6ee=_0x2c7b0b[_0x535915('0x27fe')]['appdata']['split'](',');_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x35')]=isNaN(_0x35c6ee[0x0])?_0x35c6ee[0x0]:parseInt(_0x35c6ee[0x0],0xa),_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x1bcd')]=_0x35c6ee[_0x535915('0x12c8')](0x1,_0x35c6ee['length'])[_0x535915('0x1630')](',');}break;case _0x535915('0x8c2'):_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x1bcd')]=_0x2c7b0b['goto'][_0x535915('0x1407')];break;case _0x535915('0x877'):_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x60a')]=_0x2c7b0b['goto'][_0x535915('0x1407')][_0x535915('0x1fc5')]('=')[0x0],_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x1c6b')]=_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x1407')][_0x535915('0x1fc5')]('=')[0x1];break;case _0x535915('0x19ae'):_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x273a')]=_0x2c7b0b['goto'][_0x535915('0x1407')];break;default:{const _0x523ee5=_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x1407')][_0x535915('0x1fc5')](',');_0x2c7b0b[_0x535915('0x27fe')]['context']=_0x2e3ca0()[_0x535915('0x173f')](_0x523ee5[0x0])?_0x523ee5[0x0]:isNaN(_0x523ee5[0x0])?_0x523ee5[0x0]:parseInt(_0x523ee5[0x0],0xa),_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0xa65')]=_0x2e3ca0()[_0x535915('0x173f')](_0x523ee5[0x1])?_0x523ee5[0x1]:isNaN(_0x523ee5[0x1])?_0x523ee5[0x1]:parseInt(_0x523ee5[0x1],0xa),_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0xe1e')]=_0x2e3ca0()[_0x535915('0x173f')](_0x523ee5[0x2])?_0x523ee5[0x2]:isNaN(_0x523ee5[0x2])?_0x523ee5[0x2]:parseInt(_0x523ee5[0x2],0xa);}break;}else{}_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0xcf0')]&&_0x2c7b0b['goto'][_0x535915('0xcf0')][_0x535915('0x93a')]()==='outbound'&&_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x11f3')]['toLowerCase']()===_0x535915('0x659')&&(_0x2c7b0b['goto']['prefix']=_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0xd31')]?_0x2c7b0b['goto'][_0x535915('0xd31')][_0x535915('0x1fc5')]('$')[0x0]:undefined,_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0xabd')]=_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x73c')]?_0x535915('0xac1')+_0x2c7b0b[_0x535915('0x27fe')][_0x535915('0x73c')]:undefined);_0x2c7b0b[_0x535915('0xb')]=_0x25d288,_0x2c7b0b['closeDialog']=_0x4672d7,_0x4d9108[_0x535915('0xca1')](_0x535915('0x20c2'))?_0x1ac15b[_0x535915('0x1e4d')][_0x535915('0x1e6e')]({'fields':_0x535915('0xa10'),'sort':_0x535915('0x60a'),'nolimit':_0x535915('0x26ac')})[_0x535915('0xe53')][_0x535915('0x683')](function(_0x24b540){const _0x17d974=_0x535915;_0x2c7b0b[_0x17d974('0x1693')]=_0x24b540['rows']||[];})[_0x535915('0x130a')](function(_0x4b94f3){const _0x1eec23=_0x535915;_0xb56c12['error']({'title':_0x4b94f3[_0x1eec23('0x13ee')]?_0x1eec23('0x2168')+_0x4b94f3[_0x1eec23('0x13ee')]+_0x1eec23('0xbf6')+_0x4b94f3[_0x1eec23('0x24a9')]:_0x1eec23('0x1379'),'msg':_0x4b94f3[_0x1eec23('0x5a5')]?JSON[_0x1eec23('0x258a')](_0x4b94f3[_0x1eec23('0x5a5')]):_0x4b94f3[_0x1eec23('0x1ff0')]()});}):_0x1ac15b[_0x535915('0x1e4d')]['get']({'fields':_0x535915('0xa10'),'sort':'name','nolimit':_0x535915('0x26ac')})[_0x535915('0xe53')]['then'](function(_0x5ac9c5){const _0xe4563e=_0x535915;_0x2c7b0b['contexts']=_0x5ac9c5[_0xe4563e('0xf5d')]||[];})[_0x535915('0x683')](function(){const _0x8bc7e5=_0x535915;return _0x1ac15b[_0x8bc7e5('0x22df')][_0x8bc7e5('0x1e6e')]({'userProfileId':_0x2c7b0b[_0x8bc7e5('0x11ed')][_0x8bc7e5('0x2f')],'sectionId':0x195})['$promise'];})[_0x535915('0x683')](function(_0x5e6d40){const _0x9d4c6f=_0x535915,_0x4d2c84=_0x5e6d40&&_0x5e6d40[_0x9d4c6f('0xf5d')]?_0x5e6d40[_0x9d4c6f('0xf5d')][0x0]:null;if(!_0x4d2c84)return _0x1ac15b[_0x9d4c6f('0x1e4d')][_0x9d4c6f('0x1e6e')]({'fields':_0x9d4c6f('0xa10'),'sort':_0x9d4c6f('0x60a'),'nolimit':_0x9d4c6f('0x26ac'),'defaultEntry':0x1})[_0x9d4c6f('0xe53')][_0x9d4c6f('0x683')](function(_0x15bf0d){_0x2c7b0b['contexts']=_0x15bf0d['rows']||[];});else{if(!_0x4d2c84[_0x9d4c6f('0x170')])return _0x1ac15b['userProfileResource']['get']({'sectionId':_0x4d2c84['id']})[_0x9d4c6f('0xe53')][_0x9d4c6f('0x683')](function(_0x1655e8){const _0x348299=_0x9d4c6f,_0x1b7571=_0x2e3ca0()[_0x348299('0x386')](_0x1655e8['rows'],function(_0x139cfe){const _0x157093=_0x348299;return _0x2e3ca0()[_0x157093('0x1c07')](_0x2c7b0b[_0x157093('0x1693')],{'id':_0x139cfe[_0x157093('0x832')]});});let _0x27de19=null;_0x2c7b0b[_0x348299('0x27fe')]&&(_0x27de19=_0x2e3ca0()[_0x348299('0x1c07')](_0x2c7b0b[_0x348299('0x1693')],{'name':_0x2c7b0b[_0x348299('0x27fe')]['context']}));if(_0x27de19&&!_0x2e3ca0()[_0x348299('0x7a2')](_0x1b7571,['id',_0x27de19['id']])){const _0xf1888f=_0x2e3ca0()[_0x348299('0x1c07')](_0x2c7b0b[_0x348299('0x1693')],{'id':_0x27de19['id']});_0xf1888f[_0x348299('0x319')]=![],_0x1b7571[_0x348299('0x1fd0')](_0xf1888f);}_0x2c7b0b[_0x348299('0x1693')]=_0x1b7571;});}})[_0x535915('0x130a')](function(_0x426385){const _0x32c611=_0x535915;_0xb56c12[_0x32c611('0x52a')]({'title':_0x426385[_0x32c611('0x13ee')]?_0x32c611('0x2168')+_0x426385['status']+_0x32c611('0xbf6')+_0x426385[_0x32c611('0x24a9')]:_0x32c611('0x1a60'),'msg':_0x426385['data']?JSON[_0x32c611('0x258a')](_0x426385['data']):_0x426385[_0x32c611('0x1ff0')]()});});function _0x25d288(){const _0x11650f=_0x535915;_0x2c7b0b[_0x11650f('0x17f')]=[];const _0x51287b=[];_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0xcf0')]&&_0x2c7b0b[_0x11650f('0x27fe')]['type'][_0x11650f('0x93a')]()===_0x11650f('0x17cd')&&_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x11f3')]===_0x11650f('0x4d2')&&(_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0xd31')]=_0x4bbe0d[_0x11650f('0x145a')]?(_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x24fa')]||'')+'${EXTEN:'+_0x4bbe0d[_0x11650f('0x145a')]+'}':(_0x2c7b0b['goto']['prefix']||'')+'${EXTEN}',_0x4bbe0d[_0x11650f('0x75b')]!==_0x11650f('0x925')?_0x2c7b0b[_0x11650f('0x27fe')]['options'][_0x11650f('0x824')](_0x11650f('0x1b1'))<0x0&&(_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x158e')]+='U(xcally-mixmonitor-context)'):_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x158e')]=_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x158e')][_0x11650f('0x1725')]('U(xcally-mixmonitor-context)',''));if(_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x11f3')]&&_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x11f3')]===_0x11650f('0xbf0')){}else switch((_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x1d75')]||_0x2c7b0b['goto'][_0x11650f('0x11f3')])[_0x11650f('0x93a')]()){case _0x11650f('0x877'):_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x1407')]=_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0x60a')]+'='+_0x2c7b0b['goto'][_0x11650f('0x1c6b')];break;case _0x11650f('0xbf0'):break;default:_0x51287b[0x0]=_0x2c7b0b[_0x11650f('0x27fe')]['context'],_0x51287b[0x1]=_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0xa65')],_0x51287b[0x2]=_0x2c7b0b[_0x11650f('0x27fe')][_0x11650f('0xe1e')],_0x2c7b0b['goto'][_0x11650f('0x1407')]=_0x51287b[_0x11650f('0x1630')](',');}_0x4672d7(_0x2c7b0b[_0x11650f('0x27fe')]);}function _0x4672d7(_0x4221fc){const _0x27c1df=_0x535915;_0x55c2ad[_0x27c1df('0x1715')](_0x4221fc);}}const _0x23071d=_0x1ab9b3;_0x215385[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x3a7'),_0x189033('0xff1'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x215385(_0x501b10,_0x1ad6ef,_0x3a6ab7,_0x33db4a,_0x59dbf8,_0x2255c5,_0x56d868,_0x9ce2a7){const _0xe1b1a3=_0x189033,_0xd6700d=this;_0xd6700d[_0xe1b1a3('0x11ed')]=_0x56d868[_0xe1b1a3('0x20b2')](),_0xd6700d[_0xe1b1a3('0x17f')]=[],_0xd6700d[_0xe1b1a3('0xf28')]=_0xe1b1a3('0x241c')+(_0x33db4a[_0xe1b1a3('0x11f3')]||_0x33db4a[_0xe1b1a3('0x1d75')])[_0xe1b1a3('0x80')](),_0xd6700d[_0xe1b1a3('0x1ba9')]=angular['copy'](_0x33db4a),_0xd6700d[_0xe1b1a3('0x1134')]=_0x9ce2a7,_0xd6700d[_0xe1b1a3('0x258d')]={};if(_0xd6700d['hangup']['appdata'])switch(_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x11f3')]?_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x11f3')]['toLowerCase']():_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1d75')][_0xe1b1a3('0x93a')]()){case _0xe1b1a3('0xbf0'):break;case'dialogflow':{const _0x31d8f6=_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1407')]['split'](',');_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1d46')]=_0x31d8f6[0x0],_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1a1c')]=_0x31d8f6[0x1],_0xd6700d['hangup'][_0xe1b1a3('0x6d9')]=_0x31d8f6[_0xe1b1a3('0x12c8')](0x2,_0x31d8f6[_0xe1b1a3('0x1564')])[_0xe1b1a3('0x1630')](',');}break;case _0xe1b1a3('0xd24'):{const _0xdd86ad=_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1407')][_0xe1b1a3('0x1fc5')](',');_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x2119')]=_0xdd86ad[0x0],_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x38')]=_0xdd86ad[0x1],_0xd6700d['hangup'][_0xe1b1a3('0x406')]=_0xdd86ad[0x2],_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1a1c')]=_0xdd86ad[0x3],_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x6d9')]=_0xdd86ad['slice'](0x4,_0xdd86ad['length'])[_0xe1b1a3('0x1630')](',');}break;case _0xe1b1a3('0x1db1'):{const _0x208f15=_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1407')][_0xe1b1a3('0x1fc5')](',');_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x7ae')]=_0x208f15[0x0],_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x204a')]=_0x208f15[0x1],_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x5ba')]=_0x208f15[0x2],_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x11a9')]=_0x208f15[0x3],_0xd6700d['hangup']['welcomemessage']=_0x208f15[_0xe1b1a3('0x12c8')](0x4,_0x208f15['length'])[_0xe1b1a3('0x1630')](',');}break;case _0xe1b1a3('0x2408'):{const _0x4250f7=_0xd6700d['hangup'][_0xe1b1a3('0x1407')][_0xe1b1a3('0x1fc5')](',');_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x35')]=isNaN(_0x4250f7[0x0])?_0x4250f7[0x0]:parseInt(_0x4250f7[0x0],0xa),_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1bcd')]=_0x4250f7[_0xe1b1a3('0x12c8')](0x1,_0x4250f7[_0xe1b1a3('0x1564')])[_0xe1b1a3('0x1630')](',');}break;case'message':_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1bcd')]=_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1407')];break;case _0xe1b1a3('0x877'):_0xd6700d['hangup'][_0xe1b1a3('0x60a')]=_0xd6700d[_0xe1b1a3('0x1ba9')]['appdata'][_0xe1b1a3('0x1fc5')]('=')[0x0],_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x1c6b')]=_0xd6700d[_0xe1b1a3('0x1ba9')]['appdata'][_0xe1b1a3('0x1fc5')]('=')[0x1];break;case _0xe1b1a3('0x19ae'):_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x273a')]=_0xd6700d['hangup'][_0xe1b1a3('0x1407')];break;default:{const _0x2087cb=_0xd6700d['hangup'][_0xe1b1a3('0x1407')][_0xe1b1a3('0x1fc5')](',');_0xd6700d[_0xe1b1a3('0x1ba9')]['appdata']=_0x2e3ca0()[_0xe1b1a3('0x173f')](_0x2087cb[0x0])?_0x2087cb[0x0]:isNaN(_0x2087cb[0x0])?_0x2087cb[0x0]:parseInt(_0x2087cb[0x0],0xa);}break;}else{}_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0xcf0')]&&_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0xcf0')]['toLowerCase']()===_0xe1b1a3('0x17cd')&&_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x11f3')][_0xe1b1a3('0x93a')]()===_0xe1b1a3('0x659')&&(_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x24fa')]=_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0xd31')]?_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0xd31')][_0xe1b1a3('0x1fc5')]('$')[0x0]:undefined,_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0xabd')]=_0xd6700d['hangup'][_0xe1b1a3('0x73c')]?_0xe1b1a3('0xac1')+_0xd6700d[_0xe1b1a3('0x1ba9')][_0xe1b1a3('0x73c')]:undefined);_0xd6700d['saveInboundRouteApp']=_0x17f47f,_0xd6700d[_0xe1b1a3('0xf82')]=_0xdc8202;function _0x17f47f(){const _0x357c00=_0xe1b1a3;_0xd6700d[_0x357c00('0x17f')]=[];const _0x1ca3f7=[];_0xd6700d['hangup']['type']&&_0xd6700d['hangup'][_0x357c00('0xcf0')][_0x357c00('0x93a')]()===_0x357c00('0x17cd')&&_0xd6700d[_0x357c00('0x1ba9')][_0x357c00('0x11f3')]===_0x357c00('0x4d2')&&(_0xd6700d['hangup'][_0x357c00('0xd31')]=_0x59dbf8['cutdigits']?(_0xd6700d[_0x357c00('0x1ba9')][_0x357c00('0x24fa')]||'')+'${EXTEN:'+_0x59dbf8['cutdigits']+'}':(_0xd6700d[_0x357c00('0x1ba9')]['prefix']||'')+'${EXTEN}',_0x59dbf8[_0x357c00('0x75b')]!==_0x357c00('0x925')?_0xd6700d[_0x357c00('0x1ba9')][_0x357c00('0x158e')][_0x357c00('0x824')](_0x357c00('0x1b1'))<0x0&&(_0xd6700d['hangup'][_0x357c00('0x158e')]+=_0x357c00('0x1b1')):_0xd6700d[_0x357c00('0x1ba9')][_0x357c00('0x158e')]=_0xd6700d['hangup'][_0x357c00('0x158e')][_0x357c00('0x1725')](_0x357c00('0x1b1'),''));if(_0xd6700d[_0x357c00('0x1ba9')]['appType']&&_0xd6700d[_0x357c00('0x1ba9')][_0x357c00('0x11f3')]===_0x357c00('0xbf0')){}else switch((_0xd6700d[_0x357c00('0x1ba9')][_0x357c00('0x1d75')]||_0xd6700d['hangup'][_0x357c00('0x11f3')])[_0x357c00('0x93a')]()){case _0x357c00('0x877'):_0xd6700d[_0x357c00('0x1ba9')]['appdata']=_0xd6700d[_0x357c00('0x1ba9')][_0x357c00('0x60a')]+'='+_0xd6700d[_0x357c00('0x1ba9')][_0x357c00('0x1c6b')];break;case _0x357c00('0xbf0'):break;default:_0x1ca3f7[0x0]=_0xd6700d[_0x357c00('0x1ba9')][_0x357c00('0x1407')],_0xd6700d['hangup'][_0x357c00('0x1407')]=_0x1ca3f7[_0x357c00('0x1630')](',');}_0xdc8202(_0xd6700d[_0x357c00('0x1ba9')]);}function _0xdc8202(_0x2aaca0){const _0x489403=_0xe1b1a3;_0x501b10[_0x489403('0x1715')](_0x2aaca0);}}const _0x5bfdbd=_0x215385;_0x13d726[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x3a7'),_0x189033('0xff1'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x13d726(_0x393cbf,_0x2eb3a2,_0x2eea3e,_0x51a193,_0x14dbcb,_0x57f5da,_0x49c9c3,_0xf3a488){const _0x28f66f=_0x189033,_0x55fa3d=this;_0x55fa3d['currentUser']=_0x49c9c3[_0x28f66f('0x20b2')](),_0x55fa3d[_0x28f66f('0x17f')]=[],_0x55fa3d[_0x28f66f('0xf28')]='VOICE.EDIT_'+(_0x51a193[_0x28f66f('0x11f3')]||_0x51a193[_0x28f66f('0x1d75')])[_0x28f66f('0x80')](),_0x55fa3d[_0x28f66f('0x2183')]=angular['copy'](_0x51a193),_0x55fa3d[_0x28f66f('0x1134')]=_0xf3a488,_0x55fa3d[_0x28f66f('0x258d')]={};if(_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1407')])switch(_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x11f3')]?_0x55fa3d[_0x28f66f('0x2183')]['appType'][_0x28f66f('0x93a')]():_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1d75')][_0x28f66f('0x93a')]()){case _0x28f66f('0xbf0'):break;case'dialogflow':{const _0x4f8718=_0x55fa3d['internaldial']['appdata'][_0x28f66f('0x1fc5')](',');_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1d46')]=_0x4f8718[0x0],_0x55fa3d[_0x28f66f('0x2183')]['language']=_0x4f8718[0x1],_0x55fa3d[_0x28f66f('0x2183')]['welcomemessage']=_0x4f8718['slice'](0x2,_0x4f8718[_0x28f66f('0x1564')])[_0x28f66f('0x1630')](',');}break;case _0x28f66f('0xd24'):{const _0x3cac9a=_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1407')][_0x28f66f('0x1fc5')](',');_0x55fa3d['internaldial'][_0x28f66f('0x2119')]=_0x3cac9a[0x0],_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x38')]=_0x3cac9a[0x1],_0x55fa3d['internaldial'][_0x28f66f('0x406')]=_0x3cac9a[0x2],_0x55fa3d['internaldial'][_0x28f66f('0x1a1c')]=_0x3cac9a[0x3],_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x6d9')]=_0x3cac9a[_0x28f66f('0x12c8')](0x4,_0x3cac9a['length'])[_0x28f66f('0x1630')](',');}break;case _0x28f66f('0x1db1'):{const _0x236ef6=_0x55fa3d['internaldial']['appdata'][_0x28f66f('0x1fc5')](',');_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x7ae')]=_0x236ef6[0x0],_0x55fa3d['internaldial']['secretaccesskey']=_0x236ef6[0x1],_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x5ba')]=_0x236ef6[0x2],_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x11a9')]=_0x236ef6[0x3],_0x55fa3d['internaldial'][_0x28f66f('0x6d9')]=_0x236ef6[_0x28f66f('0x12c8')](0x4,_0x236ef6[_0x28f66f('0x1564')])[_0x28f66f('0x1630')](',');}break;case _0x28f66f('0x2408'):{const _0x389da4=_0x55fa3d[_0x28f66f('0x2183')]['appdata'][_0x28f66f('0x1fc5')](',');_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x35')]=isNaN(_0x389da4[0x0])?_0x389da4[0x0]:parseInt(_0x389da4[0x0],0xa),_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1bcd')]=_0x389da4[_0x28f66f('0x12c8')](0x1,_0x389da4['length'])[_0x28f66f('0x1630')](',');}break;case'message':_0x55fa3d['internaldial'][_0x28f66f('0x1bcd')]=_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1407')];break;case'set':_0x55fa3d[_0x28f66f('0x2183')]['name']=_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1407')][_0x28f66f('0x1fc5')]('=')[0x0],_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1c6b')]=_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1407')][_0x28f66f('0x1fc5')]('=')[0x1];break;case _0x28f66f('0x19ae'):_0x55fa3d[_0x28f66f('0x2183')]['project']=_0x55fa3d[_0x28f66f('0x2183')]['appdata'];break;default:{const _0x312a6b=_0x55fa3d['internaldial']['appdata'][_0x28f66f('0x1fc5')](',');_0x55fa3d['internaldial'][_0x28f66f('0xc96')]=_0x2e3ca0()[_0x28f66f('0x173f')](_0x312a6b[0x0])?_0x312a6b[0x0]:isNaN(_0x312a6b[0x0])?_0x312a6b[0x0]:parseInt(_0x312a6b[0x0],0xa),_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1668')]=_0x2e3ca0()['isEmpty'](_0x312a6b[0x1])?_0x312a6b[0x1]:isNaN(_0x312a6b[0x1])?_0x312a6b[0x1]:parseInt(_0x312a6b[0x1],0xa),_0x55fa3d[_0x28f66f('0x2183')]['options']=_0x2e3ca0()[_0x28f66f('0x173f')](_0x312a6b[0x2])?_0x312a6b[0x2]:isNaN(_0x312a6b[0x2])?_0x312a6b[0x2]:parseInt(_0x312a6b[0x2],0xa),_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x1284')]=_0x2e3ca0()[_0x28f66f('0x173f')](_0x312a6b[0x3])?_0x312a6b[0x3]:isNaN(_0x312a6b[0x3])?_0x312a6b[0x3]:parseInt(_0x312a6b[0x3],0xa);}break;}else{}_0x55fa3d['internaldial']['type']&&_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0xcf0')][_0x28f66f('0x93a')]()===_0x28f66f('0x17cd')&&_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x11f3')]['toLowerCase']()==='outbounddial'&&(_0x55fa3d[_0x28f66f('0x2183')]['prefix']=_0x55fa3d[_0x28f66f('0x2183')]['phone']?_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0xd31')]['split']('$')[0x0]:undefined,_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0xabd')]=_0x55fa3d['internaldial'][_0x28f66f('0x73c')]?_0x28f66f('0xac1')+_0x55fa3d[_0x28f66f('0x2183')][_0x28f66f('0x73c')]:undefined);_0x55fa3d[_0x28f66f('0xb')]=_0x303ae6,_0x55fa3d[_0x28f66f('0xf82')]=_0x104707;const _0x38b9e0=[{'id':0xca,'role':_0x28f66f('0x2327')},{'id':0xcb,'role':_0x28f66f('0x24d3')}];let _0x5baa3c=null;_0x49c9c3[_0x28f66f('0xca1')](_0x28f66f('0x20c2'))?_0x57f5da[_0x28f66f('0xc96')]['get']({'fields':_0x28f66f('0xac9'),'sort':_0x28f66f('0x60a'),'nolimit':_0x28f66f('0x26ac')})['$promise'][_0x28f66f('0x683')](function(_0x2fa253){const _0xacfd40=_0x28f66f;_0x55fa3d[_0xacfd40('0x3bf')]=_0x2fa253['rows']||[];})['catch'](function(_0x4ab2e5){const _0x5134df=_0x28f66f;_0x2eea3e[_0x5134df('0x52a')]({'title':_0x4ab2e5[_0x5134df('0x13ee')]?'API:'+_0x4ab2e5['status']+_0x5134df('0xbf6')+_0x4ab2e5['statusText']:_0x5134df('0x8eb'),'msg':_0x4ab2e5[_0x5134df('0x5a5')]?JSON[_0x5134df('0x258a')](_0x4ab2e5[_0x5134df('0x5a5')]):_0x4ab2e5['toString']()});}):_0x57f5da[_0x28f66f('0xc96')][_0x28f66f('0x1e6e')]({'fields':'id,name,role','sort':_0x28f66f('0x60a'),'nolimit':_0x28f66f('0x26ac')})[_0x28f66f('0xe53')][_0x28f66f('0x683')](function(_0x221500){const _0x5a2599=_0x28f66f;_0x5baa3c=_0x221500[_0x5a2599('0xf5d')]||[];})[_0x28f66f('0x683')](function(){const _0x2579d7=_0x28f66f,_0x37995a=[];for(let _0x284f26=0x0;_0x284f26<_0x38b9e0[_0x2579d7('0x1564')];_0x284f26++){_0x37995a[_0x2579d7('0x1fd0')](_0x57f5da[_0x2579d7('0x22df')][_0x2579d7('0x1e6e')]({'userProfileId':_0x55fa3d[_0x2579d7('0x11ed')][_0x2579d7('0x2f')],'sectionId':_0x38b9e0[_0x284f26]['id']})[_0x2579d7('0xe53')]);}return _0x2eb3a2[_0x2579d7('0x252c')](_0x37995a);})['then'](function(_0x4e1be2){const _0x1733a6=_0x28f66f,_0x4c73fd=_0x2e3ca0()[_0x1733a6('0x386')](_0x4e1be2,function(_0x24cd88){const _0x1322ef=_0x1733a6;return _0x24cd88&&_0x24cd88[_0x1322ef('0xf5d')]?_0x24cd88[_0x1322ef('0xf5d')][0x0]:null;}),_0x3393e5=[];for(let _0x25afb1=0x0;_0x25afb1<_0x38b9e0[_0x1733a6('0x1564')];_0x25afb1++){const _0x529197=_0x2e3ca0()['find'](_0x4c73fd,['sectionId',_0x38b9e0[_0x25afb1]['id']]);if(_0x529197){if(!_0x529197[_0x1733a6('0x170')])_0x3393e5[_0x1733a6('0x1fd0')](_0x57f5da[_0x1733a6('0xcf7')]['get']({'sectionId':_0x529197['id']})['$promise']);else{const _0x102133=[];_0x5baa3c[_0x1733a6('0x1299')](function(_0x58fba6){const _0x3916b2=_0x1733a6;_0x58fba6[_0x3916b2('0xecb')]===_0x38b9e0[_0x25afb1][_0x3916b2('0xecb')]&&_0x102133[_0x3916b2('0x1fd0')](_0x58fba6);}),_0x3393e5[_0x1733a6('0x1fd0')]({'rows':_0x102133,'count':_0x102133[_0x1733a6('0x1564')]});}}}return _0x2eb3a2[_0x1733a6('0x252c')](_0x3393e5);})['then'](function(_0xf5ac79){const _0x1a0329=_0x28f66f,_0x2cff20=[];let _0x5306f4=null;_0x55fa3d['internaldial']&&(_0x5306f4=_0x2e3ca0()['find'](_0x5baa3c,{'name':_0x55fa3d['internaldial'][_0x1a0329('0xc96')]}));for(let _0x278d17=0x0;_0x278d17<_0xf5ac79['length'];_0x278d17++){const _0x585391=_0xf5ac79[_0x278d17]['rows']||[];_0x585391['forEach'](function(_0x4d0102){const _0x57d2f3=_0x1a0329;_0x2cff20[_0x57d2f3('0x1fd0')](_0x4d0102);});}_0x5306f4&&!_0x2e3ca0()[_0x1a0329('0x7a2')](_0x2cff20,[_0x1a0329('0x832'),_0x5306f4['id']])&&_0x5baa3c[_0x1a0329('0x1299')](function(_0x363435){const _0x1fc00c=_0x1a0329;_0x363435['id']===_0x5306f4['id']&&(_0x363435[_0x1fc00c('0x319')]=![],_0x2cff20['push'](_0x363435));}),_0x55fa3d[_0x1a0329('0x3bf')]=_0x2cff20;})['catch'](function(_0x142bd6){const _0x5e39e2=_0x28f66f;_0x2eea3e[_0x5e39e2('0x52a')]({'title':_0x142bd6[_0x5e39e2('0x13ee')]?_0x5e39e2('0x2168')+_0x142bd6[_0x5e39e2('0x13ee')]+_0x5e39e2('0xbf6')+_0x142bd6[_0x5e39e2('0x24a9')]:_0x5e39e2('0x1511'),'msg':_0x142bd6[_0x5e39e2('0x5a5')]?JSON[_0x5e39e2('0x258a')](_0x142bd6[_0x5e39e2('0x5a5')]):_0x142bd6[_0x5e39e2('0x1ff0')]()});});function _0x303ae6(){const _0x278dfd=_0x28f66f;_0x55fa3d[_0x278dfd('0x17f')]=[];const _0x1e9d9a=[];_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0xcf0')]&&_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0xcf0')][_0x278dfd('0x93a')]()==='outbound'&&_0x55fa3d['internaldial']['appType']===_0x278dfd('0x4d2')&&(_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0xd31')]=_0x14dbcb[_0x278dfd('0x145a')]?(_0x55fa3d['internaldial']['prefix']||'')+'${EXTEN:'+_0x14dbcb['cutdigits']+'}':(_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0x24fa')]||'')+_0x278dfd('0x20cb'),_0x14dbcb[_0x278dfd('0x75b')]!==_0x278dfd('0x925')?_0x55fa3d['internaldial']['options'][_0x278dfd('0x824')](_0x278dfd('0x1b1'))<0x0&&(_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0x158e')]+=_0x278dfd('0x1b1')):_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0x158e')]=_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0x158e')]['replace'](_0x278dfd('0x1b1'),''));if(_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0x11f3')]&&_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0x11f3')]===_0x278dfd('0xbf0')){}else switch((_0x55fa3d[_0x278dfd('0x2183')]['app']||_0x55fa3d['internaldial'][_0x278dfd('0x11f3')])[_0x278dfd('0x93a')]()){case _0x278dfd('0x877'):_0x55fa3d['internaldial'][_0x278dfd('0x1407')]=_0x55fa3d[_0x278dfd('0x2183')]['name']+'='+_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0x1c6b')];break;case _0x278dfd('0xbf0'):break;default:_0x1e9d9a[0x0]=_0x55fa3d['internaldial']['user'],_0x1e9d9a[0x1]=_0x55fa3d[_0x278dfd('0x2183')][_0x278dfd('0x1668')],_0x1e9d9a[0x2]=_0x55fa3d['internaldial'][_0x278dfd('0x158e')],_0x1e9d9a[0x3]=_0x55fa3d['internaldial'][_0x278dfd('0x1284')],_0x55fa3d[_0x278dfd('0x2183')]['appdata']=_0x1e9d9a[_0x278dfd('0x1630')](',');}_0x104707(_0x55fa3d['internaldial']);}function _0x104707(_0x1c01af){const _0x3cd6f7=_0x28f66f;_0x393cbf[_0x3cd6f7('0x1715')](_0x1c01af);}}const _0xbe0890=_0x13d726;_0x897da6['$inject']=[_0x189033('0x938'),'$mdDialog',_0x189033('0xb33'),_0x189033('0x844'),_0x189033('0x115c'),_0x189033('0xe98'),'toasty','api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x897da6(_0x449498,_0x2573f4,_0x426f61,_0x85212,_0x43b587,_0xf6fd86,_0x2594a7,_0x232504,_0x425622,_0x33381c){const _0x189767=_0x189033,_0x4483bb=this;_0x4483bb['currentUser']=_0x425622[_0x189767('0x20b2')](),_0x4483bb[_0x189767('0x17f')]=[],_0x4483bb[_0x189767('0xf28')]=_0x189767('0xc62'),_0x4483bb[_0x189767('0x115c')]=angular[_0x189767('0x1a86')](_0x43b587),_0x4483bb[_0x189767('0xe98')]=_0xf6fd86,_0x4483bb[_0x189767('0x1470')]=![],_0x4483bb[_0x189767('0x1de1')]=['always',_0x189767('0xbf0'),_0x189767('0x2335')],_0x4483bb[_0x189767('0x1134')]=_0x33381c,_0x4483bb[_0x189767('0x167a')]=_0x85212['getDaysOfWeek'](),_0x4483bb['monthNumber']=_0x85212[_0x189767('0x222e')](),_0x4483bb[_0x189767('0x1e32')]=_0x85212[_0x189767('0x1fe4')](),_0x4483bb['daysOfMonth']=_0x85212[_0x189767('0x181b')]();if(!_0x4483bb[_0x189767('0x115c')])_0x4483bb['interval']={'interval':_0x189767('0x1b54')},_0x4483bb['type']=_0x189767('0x10af'),_0x4483bb[_0x189767('0xf28')]=_0x189767('0x1e94'),_0x4483bb[_0x189767('0x1470')]=!![];else{if(_0x4483bb[_0x189767('0x115c')][_0x189767('0x115c')]!=='*,*,*,*'){_0x4483bb[_0x189767('0xcf0')]=_0x189767('0xbf0');const _0x5a0c2a=_0x4483bb['interval'][_0x189767('0x115c')]['split'](','),_0x527f38=_0x5a0c2a[0x0],_0x86137d=_0x5a0c2a[0x1],_0x303ac5=_0x5a0c2a[0x2],_0x5978c6=_0x5a0c2a[0x3];if(_0x527f38!=='*'){const _0x31051f=_0x527f38[_0x189767('0x1fc5')]('-')[0x0],_0x5b790a=_0x527f38[_0x189767('0x1fc5')]('-')[0x1];let _0x4143be;_0x4143be=new Date(),_0x4143be['setHours'](Number(_0x31051f[_0x189767('0x1fc5')](':')[0x0])),_0x4143be[_0x189767('0x1fb7')](Number(_0x31051f[_0x189767('0x1fc5')](':')[0x1])),_0x4483bb[_0x189767('0xc32')]=_0x4143be,_0x4143be=new Date(),_0x4143be['setHours'](Number(_0x5b790a[_0x189767('0x1fc5')](':')[0x0])),_0x4143be[_0x189767('0x1fb7')](Number(_0x5b790a[_0x189767('0x1fc5')](':')[0x1])),_0x4483bb[_0x189767('0xaa0')]=_0x4143be;}_0x86137d!=='*'&&(_0x4483bb['dayOfWeekFrom']=_0x86137d[_0x189767('0x1fc5')]('-')[0x0],_0x4483bb[_0x189767('0x1269')]=_0x86137d[_0x189767('0x1fc5')]('-')[0x1]),_0x303ac5!=='*'&&(_0x4483bb[_0x189767('0xf13')]=_0x303ac5['split']('-')[0x0],_0x4483bb[_0x189767('0xfe5')]=_0x303ac5[_0x189767('0x1fc5')]('-')[0x1]),_0x5978c6!=='*'&&(_0x4483bb['monthFrom']=_0x5978c6[_0x189767('0x1fc5')]('-')[0x0],_0x4483bb[_0x189767('0x1f12')]=_0x5978c6[_0x189767('0x1fc5')]('-')[0x1]);}else _0x4483bb[_0x189767('0xcf0')]=_0x189767('0x10af');}_0x449498[_0x189767('0x7f2')]['id']&&!_0x4483bb[_0x189767('0x115c')][_0x189767('0x121e')]&&(_0x4483bb[_0x189767('0x115c')][_0x189767('0x5ae')]=_0x449498[_0x189767('0x7f2')]['id']);_0x4483bb['interval'][_0x189767('0x5ae')]&&_0x4483bb[_0x189767('0x115c')]['application']&&(_0x4483bb['type']='list');_0x4483bb[_0x189767('0x1a4d')]=_0x5b0e80,_0x4483bb[_0x189767('0x1807')]=_0x297c7d,_0x4483bb[_0x189767('0xf82')]=_0x25eda3;_0x4483bb[_0x189767('0x115c')][_0x189767('0x121e')]&&(_0x425622[_0x189767('0xca1')](_0x189767('0x20c2'))?_0x232504[_0x189767('0x115c')][_0x189767('0x1e6e')]({'fields':_0x189767('0x1e24'),'IntervalId':_0x189767('0x13c'),'nolimit':!![]})[_0x189767('0xe53')][_0x189767('0x683')](function(_0x1095be){const _0x47cda9=_0x189767;_0x4483bb[_0x47cda9('0xe98')]=_0x1095be['rows']||[];})['catch'](function(_0x200dcc){const _0x34763d=_0x189767;_0x2594a7['error']({'title':_0x200dcc[_0x34763d('0x13ee')]?_0x34763d('0x2168')+_0x200dcc[_0x34763d('0x13ee')]+_0x34763d('0xbf6')+_0x200dcc[_0x34763d('0x24a9')]:_0x34763d('0x1e65'),'msg':_0x200dcc[_0x34763d('0x5a5')]?JSON['stringify'](_0x200dcc[_0x34763d('0x5a5')]):_0x200dcc[_0x34763d('0x1ff0')]()});}):_0x232504[_0x189767('0x115c')]['get']({'fields':_0x189767('0x1e24'),'IntervalId':_0x189767('0x13c'),'nolimit':!![]})[_0x189767('0xe53')][_0x189767('0x683')](function(_0x47d5ee){const _0x2761a6=_0x189767;_0x4483bb[_0x2761a6('0xe98')]=_0x47d5ee['rows']||[];})[_0x189767('0x683')](function(){const _0x2a2d62=_0x189767;return _0x232504['userProfileSection'][_0x2a2d62('0x1e6e')]({'userProfileId':_0x4483bb[_0x2a2d62('0x11ed')][_0x2a2d62('0x2f')],'sectionId':0x3ec})[_0x2a2d62('0xe53')];})[_0x189767('0x683')](function(_0x10b0e4){const _0x1a7c8d=_0x189767,_0x5416ad=_0x10b0e4&&_0x10b0e4[_0x1a7c8d('0xf5d')]?_0x10b0e4[_0x1a7c8d('0xf5d')][0x0]:null;if(!_0x5416ad)_0x4483bb[_0x1a7c8d('0xe98')]=[];else{if(!_0x5416ad[_0x1a7c8d('0x170')])return _0x232504[_0x1a7c8d('0xcf7')]['get']({'sectionId':_0x5416ad['id']})[_0x1a7c8d('0xe53')][_0x1a7c8d('0x683')](function(_0xddf675){const _0x412838=_0x1a7c8d,_0x50646e=_0xddf675&&_0xddf675['rows']?_0xddf675['rows']:[],_0x4fcac1=[];let _0xecc24b=null;_0x4483bb[_0x412838('0x115c')]&&(_0xecc24b=_0x2e3ca0()[_0x412838('0x1c07')](_0x4483bb[_0x412838('0xe98')],{'name':_0x4483bb[_0x412838('0x115c')]['IntervalId']})),_0xecc24b&&!_0x2e3ca0()[_0x412838('0x7a2')](_0x50646e,[_0x412838('0x832'),_0xecc24b['id']])&&_0x4483bb[_0x412838('0xe98')][_0x412838('0x1299')](function(_0x10640a){const _0x3016b0=_0x412838;_0x10640a['id']===_0xecc24b['id']&&(_0x10640a['canSelect']=![],_0x4fcac1[_0x3016b0('0x1fd0')](_0x10640a));}),_0x4483bb[_0x412838('0xe98')]=_0x4fcac1;});}})['catch'](function(_0x330a7a){const _0x30eb75=_0x189767;_0x2594a7[_0x30eb75('0x52a')]({'title':_0x330a7a[_0x30eb75('0x13ee')]?_0x30eb75('0x2168')+_0x330a7a['status']+_0x30eb75('0xbf6')+_0x330a7a[_0x30eb75('0x24a9')]:_0x30eb75('0x1e65'),'msg':_0x330a7a[_0x30eb75('0x5a5')]?JSON[_0x30eb75('0x258a')](_0x330a7a[_0x30eb75('0x5a5')]):_0x330a7a[_0x30eb75('0x1ff0')]()});}));function _0x351456(){const _0x3d9ec3=_0x189767;switch(_0x4483bb[_0x3d9ec3('0xcf0')]){case'always':case _0x3d9ec3('0x2335'):return _0x3d9ec3('0x1b54');case _0x3d9ec3('0xbf0'):{const _0x23d16a=[];if(_0x4483bb['timeRangeFrom']!=='*'&&_0x4483bb[_0x3d9ec3('0xc32')]&&_0x4483bb[_0x3d9ec3('0xaa0')]){const _0x3a4f11=(_0x4483bb['timeRangeFrom'][_0x3d9ec3('0x2575')]()<0xa?'0':'')+_0x4483bb[_0x3d9ec3('0xc32')]['getHours']()+':'+((_0x4483bb['timeRangeFrom']['getMinutes']()<0xa?'0':'')+_0x4483bb[_0x3d9ec3('0xc32')][_0x3d9ec3('0x1b5b')]()),_0x55ae82=(_0x4483bb[_0x3d9ec3('0xaa0')][_0x3d9ec3('0x2575')]()<0xa?'0':'')+_0x4483bb[_0x3d9ec3('0xaa0')][_0x3d9ec3('0x2575')]()+':'+((_0x4483bb['timeRangeTo'][_0x3d9ec3('0x1b5b')]()<0xa?'0':'')+_0x4483bb['timeRangeTo'][_0x3d9ec3('0x1b5b')]());_0x23d16a['push'](_0x3a4f11+'-'+_0x55ae82);}else _0x23d16a[_0x3d9ec3('0x1fd0')]('*');return _0x4483bb[_0x3d9ec3('0x232d')]?_0x4483bb[_0x3d9ec3('0x1269')]?_0x23d16a[_0x3d9ec3('0x1fd0')](_0x4483bb['dayOfWeekFrom']+'-'+_0x4483bb[_0x3d9ec3('0x1269')]):_0x23d16a[_0x3d9ec3('0x1fd0')](_0x4483bb[_0x3d9ec3('0x232d')]):_0x23d16a[_0x3d9ec3('0x1fd0')]('*'),_0x4483bb[_0x3d9ec3('0xf13')]?_0x4483bb[_0x3d9ec3('0xfe5')]?_0x23d16a['push'](_0x4483bb[_0x3d9ec3('0xf13')]+'-'+_0x4483bb['monthDayTo']):_0x23d16a[_0x3d9ec3('0x1fd0')](_0x4483bb[_0x3d9ec3('0xf13')]):_0x23d16a[_0x3d9ec3('0x1fd0')]('*'),_0x4483bb['monthFrom']?_0x4483bb[_0x3d9ec3('0x1f12')]?_0x23d16a['push'](_0x4483bb[_0x3d9ec3('0x1690')]+'-'+_0x4483bb[_0x3d9ec3('0x1f12')]):_0x23d16a[_0x3d9ec3('0x1fd0')](_0x4483bb[_0x3d9ec3('0x1690')]):_0x23d16a[_0x3d9ec3('0x1fd0')]('*'),_0x23d16a[_0x3d9ec3('0x1630')]();}}}function _0x5b0e80(){const _0x224e4d=_0x189767;_0x4483bb[_0x224e4d('0x17f')]=[],_0x4483bb[_0x224e4d('0x115c')][_0x224e4d('0x115c')]=_0x351456(),_0x232504[_0x224e4d('0x115c')][_0x224e4d('0xb0a')](_0x4483bb[_0x224e4d('0x115c')])[_0x224e4d('0xe53')][_0x224e4d('0x683')](function(_0x5bcb6b){const _0x1aa5a9=_0x224e4d;_0x4483bb['intervals']['push'](_0x5bcb6b),_0x2594a7[_0x1aa5a9('0x53')]({'title':'Interval\x20properly\x20created','msg':_0x4483bb[_0x1aa5a9('0x115c')][_0x1aa5a9('0x60a')]?_0x4483bb[_0x1aa5a9('0x115c')]['name']+_0x1aa5a9('0x14b5'):''}),_0x25eda3();})[_0x224e4d('0x130a')](function(_0x19261c){const _0x3afd95=_0x224e4d;console[_0x3afd95('0x52a')](_0x19261c),_0x4483bb['errors']=_0x19261c[_0x3afd95('0x5a5')][_0x3afd95('0x17f')]||[{'message':_0x19261c['toString'](),'type':_0x3afd95('0x1d24')}];});}function _0x297c7d(){const _0x4ed7a7=_0x189767;_0x4483bb[_0x4ed7a7('0x17f')]=[],_0x4483bb[_0x4ed7a7('0x115c')][_0x4ed7a7('0x115c')]=_0x351456(),_0x4483bb['interval']['application']?(_0x4483bb[_0x4ed7a7('0xcf0')]!==_0x4ed7a7('0x2335')&&(_0x4483bb[_0x4ed7a7('0x115c')][_0x4ed7a7('0x5ae')]=null),_0x25eda3(_0x4483bb['interval'])):_0x232504[_0x4ed7a7('0x115c')][_0x4ed7a7('0x2480')]({'id':_0x4483bb[_0x4ed7a7('0x115c')]['id']},_0x4483bb[_0x4ed7a7('0x115c')])[_0x4ed7a7('0xe53')][_0x4ed7a7('0x683')](function(_0x26deb8){const _0xd5c399=_0x4ed7a7,_0xf548a0=_0x2e3ca0()[_0xd5c399('0x1c07')](_0x4483bb['intervals'],{'id':_0x26deb8['id']});_0xf548a0&&_0x2e3ca0()['merge'](_0xf548a0,_0x26deb8),_0x2594a7[_0xd5c399('0x53')]({'title':_0xd5c399('0x18c3'),'msg':_0xd5c399('0x224')}),_0x25eda3();})[_0x4ed7a7('0x130a')](function(_0x58be2d){const _0xd69496=_0x4ed7a7;console['error'](_0x58be2d),_0x4483bb[_0xd69496('0x17f')]=_0x58be2d[_0xd69496('0x5a5')][_0xd69496('0x17f')]||[{'message':_0x58be2d[_0xd69496('0x1ff0')](),'type':_0xd69496('0x605')}];});}function _0x25eda3(_0x4572b4){const _0x54d4c6=_0x189767;_0x2573f4[_0x54d4c6('0x1715')](_0x4572b4);}}const _0x3b9d76=_0x897da6;_0x57abc9[_0x189033('0x14be')]=['$mdDialog','$q','toasty','inboundrouteApp','inboundroute','api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x57abc9(_0x5de9f8,_0x5df7db,_0x538813,_0x5b0280,_0x2f0a43,_0x53793d,_0x48a4b3,_0x11f4a3){const _0x52b8b3=_0x189033,_0x1b4350=this;_0x1b4350[_0x52b8b3('0x11ed')]=_0x48a4b3[_0x52b8b3('0x20b2')](),_0x1b4350[_0x52b8b3('0x17f')]=[],_0x1b4350[_0x52b8b3('0xf28')]=_0x52b8b3('0x241c')+(_0x5b0280['appType']||_0x5b0280['app'])[_0x52b8b3('0x80')](),_0x1b4350[_0x52b8b3('0xab0')]=angular[_0x52b8b3('0x1a86')](_0x5b0280),_0x1b4350['crudPermissions']=_0x11f4a3,_0x1b4350[_0x52b8b3('0x258d')]={};if(_0x1b4350['playback'][_0x52b8b3('0x1407')])switch(_0x1b4350[_0x52b8b3('0xab0')]['appType']?_0x1b4350['playback'][_0x52b8b3('0x11f3')][_0x52b8b3('0x93a')]():_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1d75')]['toLowerCase']()){case _0x52b8b3('0xbf0'):break;case _0x52b8b3('0x205c'):{const _0x432239=_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1407')][_0x52b8b3('0x1fc5')](',');_0x1b4350['playback'][_0x52b8b3('0x1d46')]=_0x432239[0x0],_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1a1c')]=_0x432239[0x1],_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x6d9')]=_0x432239[_0x52b8b3('0x12c8')](0x2,_0x432239['length'])['join'](',');}break;case _0x52b8b3('0xd24'):{const _0x17db13=_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1407')][_0x52b8b3('0x1fc5')](',');_0x1b4350[_0x52b8b3('0xab0')]['projectId']=_0x17db13[0x0],_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x38')]=_0x17db13[0x1],_0x1b4350['playback'][_0x52b8b3('0x406')]=_0x17db13[0x2],_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1a1c')]=_0x17db13[0x3],_0x1b4350['playback'][_0x52b8b3('0x6d9')]=_0x17db13[_0x52b8b3('0x12c8')](0x4,_0x17db13[_0x52b8b3('0x1564')])[_0x52b8b3('0x1630')](',');}break;case _0x52b8b3('0x1db1'):{const _0x891497=_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1407')]['split'](',');_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x7ae')]=_0x891497[0x0],_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x204a')]=_0x891497[0x1],_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x5ba')]=_0x891497[0x2],_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x11a9')]=_0x891497[0x3],_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x6d9')]=_0x891497['slice'](0x4,_0x891497[_0x52b8b3('0x1564')])[_0x52b8b3('0x1630')](',');}break;case _0x52b8b3('0x2408'):{const _0x5ae856=_0x1b4350[_0x52b8b3('0xab0')]['appdata'][_0x52b8b3('0x1fc5')](',');_0x1b4350['playback'][_0x52b8b3('0x35')]=isNaN(_0x5ae856[0x0])?_0x5ae856[0x0]:parseInt(_0x5ae856[0x0],0xa),_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1bcd')]=_0x5ae856[_0x52b8b3('0x12c8')](0x1,_0x5ae856['length'])[_0x52b8b3('0x1630')](',');}break;case _0x52b8b3('0x8c2'):_0x1b4350['playback'][_0x52b8b3('0x1bcd')]=_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1407')];break;case _0x52b8b3('0x877'):_0x1b4350[_0x52b8b3('0xab0')]['name']=_0x1b4350[_0x52b8b3('0xab0')]['appdata'][_0x52b8b3('0x1fc5')]('=')[0x0],_0x1b4350['playback'][_0x52b8b3('0x1c6b')]=_0x1b4350[_0x52b8b3('0xab0')]['appdata'][_0x52b8b3('0x1fc5')]('=')[0x1];break;case'agi':_0x1b4350[_0x52b8b3('0xab0')]['project']=_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1407')];break;default:{const _0x45cae5=_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1407')]['split'](',');_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x1407')]=_0x2e3ca0()['isEmpty'](_0x45cae5[0x0])?_0x45cae5[0x0]:isNaN(_0x45cae5[0x0])?_0x45cae5[0x0]:parseInt(_0x45cae5[0x0],0xa),_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x158e')]=_0x2e3ca0()[_0x52b8b3('0x173f')](_0x45cae5[0x1])?_0x45cae5[0x1]:isNaN(_0x45cae5[0x1])?_0x45cae5[0x1]:parseInt(_0x45cae5[0x1],0xa);}break;}else{}_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0xcf0')]&&_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0xcf0')][_0x52b8b3('0x93a')]()===_0x52b8b3('0x17cd')&&_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x11f3')][_0x52b8b3('0x93a')]()===_0x52b8b3('0x659')&&(_0x1b4350['playback']['prefix']=_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0xd31')]?_0x1b4350['playback']['phone'][_0x52b8b3('0x1fc5')]('$')[0x0]:undefined,_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0xabd')]=_0x1b4350['playback'][_0x52b8b3('0x73c')]?_0x52b8b3('0xac1')+_0x1b4350[_0x52b8b3('0xab0')][_0x52b8b3('0x73c')]:undefined);_0x1b4350[_0x52b8b3('0xb')]=_0x38d88b,_0x1b4350['closeDialog']=_0x200cb8,_0x48a4b3[_0x52b8b3('0xca1')](_0x52b8b3('0x20c2'))?_0x53793d['sound']['get']({'fields':_0x52b8b3('0xfa7'),'sort':_0x52b8b3('0x60a'),'nolimit':_0x52b8b3('0x26ac')})[_0x52b8b3('0xe53')][_0x52b8b3('0x683')](function(_0x2d8768){const _0x10dc19=_0x52b8b3;_0x1b4350[_0x10dc19('0x11d2')]=_0x2d8768[_0x10dc19('0xf5d')]||[];})[_0x52b8b3('0x130a')](function(_0xa64bc1){const _0x157784=_0x52b8b3;_0x538813[_0x157784('0x52a')]({'title':_0xa64bc1[_0x157784('0x13ee')]?_0x157784('0x2168')+_0xa64bc1[_0x157784('0x13ee')]+_0x157784('0xbf6')+_0xa64bc1[_0x157784('0x24a9')]:'SYSTEM:GET_SOUNDS','msg':_0xa64bc1['data']?JSON[_0x157784('0x258a')](_0xa64bc1[_0x157784('0x5a5')]):_0xa64bc1[_0x157784('0x1ff0')]()});}):_0x53793d['sound']['get']({'fields':_0x52b8b3('0xfa7'),'sort':_0x52b8b3('0x60a'),'nolimit':_0x52b8b3('0x26ac')})[_0x52b8b3('0xe53')][_0x52b8b3('0x683')](function(_0xcd6fe6){const _0x36b163=_0x52b8b3;_0x1b4350[_0x36b163('0x11d2')]=_0xcd6fe6['rows']||[];})[_0x52b8b3('0x683')](function(){const _0x3c5ec7=_0x52b8b3;return _0x53793d[_0x3c5ec7('0x22df')][_0x3c5ec7('0x1e6e')]({'userProfileId':_0x1b4350[_0x3c5ec7('0x11ed')]['userProfileId'],'sectionId':0x3ef})['$promise'];})[_0x52b8b3('0x683')](function(_0xb6c488){const _0x4c82d8=_0x52b8b3,_0x559657=_0xb6c488&&_0xb6c488[_0x4c82d8('0xf5d')]?_0xb6c488[_0x4c82d8('0xf5d')][0x0]:null;if(!_0x559657){const _0xfa17da=[];let _0x29d364=null;_0x1b4350['playback']&&(_0x29d364=_0x2e3ca0()['find'](_0x1b4350[_0x4c82d8('0x11d2')],{'save_name':_0x1b4350[_0x4c82d8('0xab0')][_0x4c82d8('0x1638')]}));for(let _0x3601c9=0x0;_0x3601c9<_0x1b4350[_0x4c82d8('0x11d2')][_0x4c82d8('0x1564')];_0x3601c9++){_0x29d364&&_0x1b4350[_0x4c82d8('0x11d2')][_0x3601c9]['id']===_0x29d364['id']&&(_0x1b4350[_0x4c82d8('0x11d2')][_0x3601c9]['canSelect']=![],_0xfa17da['push'](_0x1b4350['sounds'][_0x3601c9]));}_0x1b4350['sounds']=_0xfa17da;}else{if(!_0x559657[_0x4c82d8('0x170')])return _0x53793d[_0x4c82d8('0xcf7')][_0x4c82d8('0x1e6e')]({'sectionId':_0x559657['id']})[_0x4c82d8('0xe53')][_0x4c82d8('0x683')](function(_0x164c1a){const _0x431b6f=_0x4c82d8,_0x37de1c=_0x2e3ca0()[_0x431b6f('0x386')](_0x164c1a[_0x431b6f('0xf5d')],function(_0x12e3d7){const _0x5af44c=_0x431b6f;return _0x2e3ca0()[_0x5af44c('0x1c07')](_0x1b4350[_0x5af44c('0x11d2')],{'id':_0x12e3d7[_0x5af44c('0x832')]});});let _0x13c5d0=null;_0x1b4350['playback']&&(_0x13c5d0=_0x2e3ca0()[_0x431b6f('0x1c07')](_0x1b4350[_0x431b6f('0x11d2')],{'save_name':_0x1b4350[_0x431b6f('0xab0')]['sound']}));if(_0x13c5d0&&!_0x2e3ca0()['some'](_0x37de1c,['id',_0x13c5d0['id']])){const _0x5b07f9=_0x2e3ca0()[_0x431b6f('0x1c07')](_0x1b4350['sounds'],{'id':_0x13c5d0['id']});_0x5b07f9[_0x431b6f('0x319')]=![],_0x37de1c['push'](_0x5b07f9);}_0x1b4350['sounds']=_0x37de1c;});}})[_0x52b8b3('0x130a')](function(_0x571bfa){const _0x436d52=_0x52b8b3;_0x538813[_0x436d52('0x52a')]({'title':_0x571bfa[_0x436d52('0x13ee')]?'API:'+_0x571bfa[_0x436d52('0x13ee')]+_0x436d52('0xbf6')+_0x571bfa['statusText']:_0x436d52('0xb97'),'msg':_0x571bfa[_0x436d52('0x5a5')]?JSON[_0x436d52('0x258a')](_0x571bfa[_0x436d52('0x5a5')]):_0x571bfa[_0x436d52('0x1ff0')]()});});function _0x38d88b(){const _0x2fe6e7=_0x52b8b3;_0x1b4350[_0x2fe6e7('0x17f')]=[];const _0x50b5cf=[];_0x1b4350[_0x2fe6e7('0xab0')][_0x2fe6e7('0xcf0')]&&_0x1b4350[_0x2fe6e7('0xab0')][_0x2fe6e7('0xcf0')]['toLowerCase']()===_0x2fe6e7('0x17cd')&&_0x1b4350['playback'][_0x2fe6e7('0x11f3')]===_0x2fe6e7('0x4d2')&&(_0x1b4350[_0x2fe6e7('0xab0')]['phone']=_0x2f0a43[_0x2fe6e7('0x145a')]?(_0x1b4350[_0x2fe6e7('0xab0')][_0x2fe6e7('0x24fa')]||'')+_0x2fe6e7('0x249e')+_0x2f0a43[_0x2fe6e7('0x145a')]+'}':(_0x1b4350['playback'][_0x2fe6e7('0x24fa')]||'')+_0x2fe6e7('0x20cb'),_0x2f0a43[_0x2fe6e7('0x75b')]!==_0x2fe6e7('0x925')?_0x1b4350['playback'][_0x2fe6e7('0x158e')][_0x2fe6e7('0x824')](_0x2fe6e7('0x1b1'))<0x0&&(_0x1b4350['playback']['options']+=_0x2fe6e7('0x1b1')):_0x1b4350['playback'][_0x2fe6e7('0x158e')]=_0x1b4350[_0x2fe6e7('0xab0')]['options'][_0x2fe6e7('0x1725')](_0x2fe6e7('0x1b1'),''));if(_0x1b4350['playback'][_0x2fe6e7('0x11f3')]&&_0x1b4350['playback'][_0x2fe6e7('0x11f3')]===_0x2fe6e7('0xbf0')){}else switch((_0x1b4350[_0x2fe6e7('0xab0')][_0x2fe6e7('0x1d75')]||_0x1b4350[_0x2fe6e7('0xab0')][_0x2fe6e7('0x11f3')])[_0x2fe6e7('0x93a')]()){case'set':_0x1b4350[_0x2fe6e7('0xab0')][_0x2fe6e7('0x1407')]=_0x1b4350['playback'][_0x2fe6e7('0x60a')]+'='+_0x1b4350[_0x2fe6e7('0xab0')][_0x2fe6e7('0x1c6b')];break;case _0x2fe6e7('0xbf0'):break;default:_0x50b5cf[0x0]=_0x1b4350[_0x2fe6e7('0xab0')][_0x2fe6e7('0x1407')],_0x50b5cf[0x1]=_0x1b4350['playback'][_0x2fe6e7('0x158e')],_0x1b4350[_0x2fe6e7('0xab0')][_0x2fe6e7('0x1407')]=_0x50b5cf[_0x2fe6e7('0x1630')](',');}_0x200cb8(_0x1b4350[_0x2fe6e7('0xab0')]);}function _0x200cb8(_0x54eb32){_0x5de9f8['hide'](_0x54eb32);}}const _0x5b19c7=_0x57abc9;_0xb31da4[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x3a7'),_0x189033('0xff1'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0xb31da4(_0x5a4608,_0x117fdf,_0x2fbdf8,_0x1fb0d7,_0x278380,_0x5dd229,_0x18e46e,_0x3ab5a4){const _0x57554a=_0x189033,_0x44a7d5=this;_0x44a7d5[_0x57554a('0x11ed')]=_0x18e46e[_0x57554a('0x20b2')](),_0x44a7d5[_0x57554a('0x17f')]=[],_0x44a7d5[_0x57554a('0xf28')]=_0x57554a('0x241c')+(_0x1fb0d7['appType']||_0x1fb0d7[_0x57554a('0x1d75')])['toUpperCase'](),_0x44a7d5[_0x57554a('0x660')]=angular[_0x57554a('0x1a86')](_0x1fb0d7),_0x44a7d5['crudPermissions']=_0x3ab5a4,_0x44a7d5[_0x57554a('0x258d')]={};if(_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1407')])switch(_0x44a7d5['queue']['appType']?_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x11f3')][_0x57554a('0x93a')]():_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1d75')][_0x57554a('0x93a')]()){case _0x57554a('0xbf0'):break;case _0x57554a('0x205c'):{const _0x5ec73a=_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1407')][_0x57554a('0x1fc5')](',');_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1d46')]=_0x5ec73a[0x0],_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1a1c')]=_0x5ec73a[0x1],_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x6d9')]=_0x5ec73a[_0x57554a('0x12c8')](0x2,_0x5ec73a[_0x57554a('0x1564')])[_0x57554a('0x1630')](',');}break;case _0x57554a('0xd24'):{const _0x20695e=_0x44a7d5[_0x57554a('0x660')]['appdata'][_0x57554a('0x1fc5')](',');_0x44a7d5[_0x57554a('0x660')]['projectId']=_0x20695e[0x0],_0x44a7d5[_0x57554a('0x660')]['clientEmail']=_0x20695e[0x1],_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x406')]=_0x20695e[0x2],_0x44a7d5['queue'][_0x57554a('0x1a1c')]=_0x20695e[0x3],_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x6d9')]=_0x20695e['slice'](0x4,_0x20695e[_0x57554a('0x1564')])[_0x57554a('0x1630')](',');}break;case _0x57554a('0x1db1'):{const _0x52e483=_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1407')][_0x57554a('0x1fc5')](',');_0x44a7d5[_0x57554a('0x660')]['accesskeyid']=_0x52e483[0x0],_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x204a')]=_0x52e483[0x1],_0x44a7d5[_0x57554a('0x660')]['lexregion']=_0x52e483[0x2],_0x44a7d5['queue'][_0x57554a('0x11a9')]=_0x52e483[0x3],_0x44a7d5['queue']['welcomemessage']=_0x52e483['slice'](0x4,_0x52e483[_0x57554a('0x1564')])[_0x57554a('0x1630')](',');}break;case _0x57554a('0x2408'):{const _0x5e6ed7=_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1407')][_0x57554a('0x1fc5')](',');_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x35')]=isNaN(_0x5e6ed7[0x0])?_0x5e6ed7[0x0]:parseInt(_0x5e6ed7[0x0],0xa),_0x44a7d5['queue'][_0x57554a('0x1bcd')]=_0x5e6ed7[_0x57554a('0x12c8')](0x1,_0x5e6ed7[_0x57554a('0x1564')])[_0x57554a('0x1630')](',');}break;case'message':_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1bcd')]=_0x44a7d5['queue']['appdata'];break;case _0x57554a('0x877'):_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x60a')]=_0x44a7d5[_0x57554a('0x660')]['appdata'][_0x57554a('0x1fc5')]('=')[0x0],_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1c6b')]=_0x44a7d5[_0x57554a('0x660')]['appdata']['split']('=')[0x1];break;case _0x57554a('0x19ae'):_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x273a')]=_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1407')];break;default:{const _0x220c3c=_0x44a7d5['queue'][_0x57554a('0x1407')][_0x57554a('0x1fc5')](',');_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x660')]=_0x2e3ca0()['isEmpty'](_0x220c3c[0x0])?_0x220c3c[0x0]:isNaN(_0x220c3c[0x0])?_0x220c3c[0x0]:parseInt(_0x220c3c[0x0],0xa),_0x44a7d5['queue']['options']=_0x2e3ca0()[_0x57554a('0x173f')](_0x220c3c[0x1])?_0x220c3c[0x1]:isNaN(_0x220c3c[0x1])?_0x220c3c[0x1]:parseInt(_0x220c3c[0x1],0xa),_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1a0a')]=_0x2e3ca0()[_0x57554a('0x173f')](_0x220c3c[0x2])?_0x220c3c[0x2]:isNaN(_0x220c3c[0x2])?_0x220c3c[0x2]:parseInt(_0x220c3c[0x2],0xa),_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x1638')]=_0x2e3ca0()['isEmpty'](_0x220c3c[0x3])?_0x220c3c[0x3]:isNaN(_0x220c3c[0x3])?_0x220c3c[0x3]:parseInt(_0x220c3c[0x3],0xa),_0x44a7d5['queue'][_0x57554a('0x1668')]=_0x2e3ca0()[_0x57554a('0x173f')](_0x220c3c[0x4])?_0x220c3c[0x4]:isNaN(_0x220c3c[0x4])?_0x220c3c[0x4]:parseInt(_0x220c3c[0x4],0xa),_0x44a7d5['queue'][_0x57554a('0x19ae')]=_0x2e3ca0()[_0x57554a('0x173f')](_0x220c3c[0x5])?_0x220c3c[0x5]:isNaN(_0x220c3c[0x5])?_0x220c3c[0x5]:parseInt(_0x220c3c[0x5],0xa),_0x44a7d5[_0x57554a('0x660')][_0x57554a('0xda6')]=_0x2e3ca0()[_0x57554a('0x173f')](_0x220c3c[0x6])?_0x220c3c[0x6]:isNaN(_0x220c3c[0x6])?_0x220c3c[0x6]:parseInt(_0x220c3c[0x6],0xa),_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x2550')]=_0x2e3ca0()['isEmpty'](_0x220c3c[0x7])?_0x220c3c[0x7]:isNaN(_0x220c3c[0x7])?_0x220c3c[0x7]:parseInt(_0x220c3c[0x7],0xa),_0x44a7d5[_0x57554a('0x660')]['rule']=_0x2e3ca0()[_0x57554a('0x173f')](_0x220c3c[0x8])?_0x220c3c[0x8]:isNaN(_0x220c3c[0x8])?_0x220c3c[0x8]:parseInt(_0x220c3c[0x8],0xa),_0x44a7d5['queue'][_0x57554a('0x1233')]=_0x2e3ca0()['isEmpty'](_0x220c3c[0x9])?_0x220c3c[0x9]:isNaN(_0x220c3c[0x9])?_0x220c3c[0x9]:parseInt(_0x220c3c[0x9],0xa);}break;}else{}_0x44a7d5[_0x57554a('0x660')][_0x57554a('0xcf0')]&&_0x44a7d5['queue'][_0x57554a('0xcf0')][_0x57554a('0x93a')]()===_0x57554a('0x17cd')&&_0x44a7d5['queue']['appType'][_0x57554a('0x93a')]()===_0x57554a('0x659')&&(_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x24fa')]=_0x44a7d5['queue']['phone']?_0x44a7d5[_0x57554a('0x660')][_0x57554a('0xd31')][_0x57554a('0x1fc5')]('$')[0x0]:undefined,_0x44a7d5['queue'][_0x57554a('0xabd')]=_0x44a7d5[_0x57554a('0x660')][_0x57554a('0x73c')]?_0x57554a('0xac1')+_0x44a7d5['queue'][_0x57554a('0x73c')]:undefined);_0x44a7d5[_0x57554a('0xb')]=_0x488dbb,_0x44a7d5['closeDialog']=_0x416d8e,_0x18e46e[_0x57554a('0xca1')](_0x57554a('0x20c2'))?_0x5dd229[_0x57554a('0x1638')][_0x57554a('0x1e6e')]({'fields':'id,name,save_name','sort':'name','nolimit':'true'})[_0x57554a('0xe53')][_0x57554a('0x683')](function(_0x4a307a){const _0x4df26f=_0x57554a;_0x44a7d5[_0x4df26f('0x11d2')]=_0x4a307a[_0x4df26f('0xf5d')]||[];})[_0x57554a('0x130a')](function(_0x58b3d2){const _0x3902ae=_0x57554a;_0x2fbdf8[_0x3902ae('0x52a')]({'title':_0x58b3d2[_0x3902ae('0x13ee')]?_0x3902ae('0x2168')+_0x58b3d2[_0x3902ae('0x13ee')]+'\x20-\x20'+_0x58b3d2[_0x3902ae('0x24a9')]:'SYSTEM:GET_SOUNDS','msg':_0x58b3d2[_0x3902ae('0x5a5')]?JSON[_0x3902ae('0x258a')](_0x58b3d2[_0x3902ae('0x5a5')]):_0x58b3d2[_0x3902ae('0x1ff0')]()});}):_0x5dd229[_0x57554a('0x1638')]['get']({'fields':_0x57554a('0xfa7'),'sort':_0x57554a('0x60a'),'nolimit':_0x57554a('0x26ac')})['$promise'][_0x57554a('0x683')](function(_0x1b77bb){const _0xa701ed=_0x57554a;_0x44a7d5[_0xa701ed('0x11d2')]=_0x1b77bb[_0xa701ed('0xf5d')]||[];})[_0x57554a('0x683')](function(){const _0x2f5b5c=_0x57554a;return _0x5dd229[_0x2f5b5c('0x22df')][_0x2f5b5c('0x1e6e')]({'userProfileId':_0x44a7d5['currentUser'][_0x2f5b5c('0x2f')],'sectionId':0x3ef})[_0x2f5b5c('0xe53')];})['then'](function(_0x3f0b73){const _0x1afe68=_0x57554a,_0x13e682=_0x3f0b73&&_0x3f0b73['rows']?_0x3f0b73[_0x1afe68('0xf5d')][0x0]:null;if(!_0x13e682){const _0xa514ec=[];let _0x33adc9=null;_0x44a7d5[_0x1afe68('0x660')]&&(_0x33adc9=_0x2e3ca0()['find'](_0x44a7d5['sounds'],{'save_name':_0x44a7d5[_0x1afe68('0x660')]['sound']}));for(let _0x441154=0x0;_0x441154<_0x44a7d5['sounds'][_0x1afe68('0x1564')];_0x441154++){_0x33adc9&&_0x44a7d5['sounds'][_0x441154]['id']===_0x33adc9['id']&&(_0x44a7d5[_0x1afe68('0x11d2')][_0x441154][_0x1afe68('0x319')]=![],_0xa514ec['push'](_0x44a7d5['sounds'][_0x441154]));}_0x44a7d5[_0x1afe68('0x11d2')]=_0xa514ec;}else{if(!_0x13e682[_0x1afe68('0x170')])return _0x5dd229[_0x1afe68('0xcf7')]['get']({'sectionId':_0x13e682['id']})[_0x1afe68('0xe53')][_0x1afe68('0x683')](function(_0x53eb49){const _0x2dbb21=_0x1afe68,_0x4322b4=_0x2e3ca0()[_0x2dbb21('0x386')](_0x53eb49[_0x2dbb21('0xf5d')],function(_0x29b852){const _0x32891f=_0x2dbb21;return _0x2e3ca0()[_0x32891f('0x1c07')](_0x44a7d5[_0x32891f('0x11d2')],{'id':_0x29b852[_0x32891f('0x832')]});});let _0x4a155b=null;_0x44a7d5[_0x2dbb21('0x660')]&&(_0x4a155b=_0x2e3ca0()['find'](_0x44a7d5[_0x2dbb21('0x11d2')],{'save_name':_0x44a7d5['queue'][_0x2dbb21('0x1638')]}));if(_0x4a155b&&!_0x2e3ca0()[_0x2dbb21('0x7a2')](_0x4322b4,['id',_0x4a155b['id']])){const _0xec6dd5=_0x2e3ca0()[_0x2dbb21('0x1c07')](_0x44a7d5[_0x2dbb21('0x11d2')],{'id':_0x4a155b['id']});_0xec6dd5[_0x2dbb21('0x319')]=![],_0x4322b4[_0x2dbb21('0x1fd0')](_0xec6dd5);}_0x44a7d5['sounds']=_0x4322b4;});}})[_0x57554a('0x130a')](function(_0x2139c4){const _0x379d28=_0x57554a;_0x2fbdf8[_0x379d28('0x52a')]({'title':_0x2139c4['status']?'API:'+_0x2139c4[_0x379d28('0x13ee')]+_0x379d28('0xbf6')+_0x2139c4[_0x379d28('0x24a9')]:_0x379d28('0xb97'),'msg':_0x2139c4[_0x379d28('0x5a5')]?JSON[_0x379d28('0x258a')](_0x2139c4['data']):_0x2139c4[_0x379d28('0x1ff0')]()});}),_0x18e46e[_0x57554a('0xca1')](_0x57554a('0x20c2'))?_0x5dd229[_0x57554a('0x204c')][_0x57554a('0x1e6e')]({'type':_0x57554a('0x1535'),'fields':_0x57554a('0x2035'),'sort':_0x57554a('0x60a'),'nolimit':_0x57554a('0x26ac')})['$promise'][_0x57554a('0x683')](function(_0x3f673e){const _0x5b4187=_0x57554a;_0x44a7d5[_0x5b4187('0x2da')]=_0x3f673e[_0x5b4187('0xf5d')]||[];})[_0x57554a('0x130a')](function(_0x2a3f44){const _0xaa9b90=_0x57554a;_0x2fbdf8[_0xaa9b90('0x52a')]({'title':_0x2a3f44['status']?_0xaa9b90('0x2168')+_0x2a3f44[_0xaa9b90('0x13ee')]+_0xaa9b90('0xbf6')+_0x2a3f44[_0xaa9b90('0x24a9')]:_0xaa9b90('0x22dc'),'msg':_0x2a3f44[_0xaa9b90('0x5a5')]?JSON[_0xaa9b90('0x258a')](_0x2a3f44[_0xaa9b90('0x5a5')]):_0x2a3f44[_0xaa9b90('0x1ff0')]()});}):_0x5dd229['voiceQueue'][_0x57554a('0x1e6e')]({'type':'inbound','fields':_0x57554a('0x2035'),'sort':'name','nolimit':_0x57554a('0x26ac')})['$promise'][_0x57554a('0x683')](function(_0x4c5b93){const _0x5583b3=_0x57554a;_0x44a7d5['queues']=_0x4c5b93[_0x5583b3('0xf5d')]||[];})['then'](function(){const _0x1d239a=_0x57554a;return _0x5dd229[_0x1d239a('0x22df')]['get']({'userProfileId':_0x44a7d5[_0x1d239a('0x11ed')][_0x1d239a('0x2f')],'sectionId':0x191})[_0x1d239a('0xe53')];})[_0x57554a('0x683')](function(_0x770b7b){const _0x1d7251=_0x57554a,_0x2b38bb=_0x770b7b&&_0x770b7b['rows']?_0x770b7b[_0x1d7251('0xf5d')][0x0]:null;if(!_0x2b38bb){const _0x32fb84=[];let _0x5e2c25=null;_0x44a7d5[_0x1d7251('0x660')]&&(_0x5e2c25=_0x2e3ca0()['find'](_0x44a7d5['queues'],{'name':_0x44a7d5[_0x1d7251('0x660')][_0x1d7251('0x660')]}));for(let _0x4975e9=0x0;_0x4975e9<_0x44a7d5[_0x1d7251('0x2da')][_0x1d7251('0x1564')];_0x4975e9++){_0x5e2c25&&_0x44a7d5['queues'][_0x4975e9]['id']===_0x5e2c25['id']&&(_0x44a7d5[_0x1d7251('0x2da')][_0x4975e9]['canSelect']=![],_0x32fb84[_0x1d7251('0x1fd0')](_0x44a7d5[_0x1d7251('0x2da')][_0x4975e9]));}_0x44a7d5[_0x1d7251('0x2da')]=_0x32fb84;}else{if(!_0x2b38bb[_0x1d7251('0x170')])return _0x5dd229[_0x1d7251('0xcf7')][_0x1d7251('0x1e6e')]({'sectionId':_0x2b38bb['id']})[_0x1d7251('0xe53')]['then'](function(_0xab4925){const _0x108bce=_0x1d7251,_0x347fa7=_0x2e3ca0()[_0x108bce('0x386')](_0xab4925[_0x108bce('0xf5d')],function(_0x5358e5){const _0xc30123=_0x108bce;return _0x2e3ca0()[_0xc30123('0x1c07')](_0x44a7d5[_0xc30123('0x2da')],{'id':_0x5358e5[_0xc30123('0x832')]});});let _0x4aed92=null;_0x44a7d5[_0x108bce('0x660')]&&(_0x4aed92=_0x2e3ca0()[_0x108bce('0x1c07')](_0x44a7d5[_0x108bce('0x2da')],{'name':_0x44a7d5[_0x108bce('0x660')][_0x108bce('0x660')]}));if(_0x4aed92&&!_0x2e3ca0()[_0x108bce('0x7a2')](_0x347fa7,['id',_0x4aed92['id']])){const _0x150ef3=_0x2e3ca0()[_0x108bce('0x1c07')](_0x44a7d5[_0x108bce('0x2da')],{'id':_0x4aed92['id']});_0x150ef3[_0x108bce('0x319')]=![],_0x347fa7[_0x108bce('0x1fd0')](_0x150ef3);}_0x44a7d5[_0x108bce('0x2da')]=_0x347fa7;});}})['catch'](function(_0x2dce1b){const _0x7bc10b=_0x57554a;_0x2fbdf8[_0x7bc10b('0x52a')]({'title':_0x2dce1b['status']?'API:'+_0x2dce1b[_0x7bc10b('0x13ee')]+_0x7bc10b('0xbf6')+_0x2dce1b['statusText']:_0x7bc10b('0x934'),'msg':_0x2dce1b['data']?JSON[_0x7bc10b('0x258a')](_0x2dce1b[_0x7bc10b('0x5a5')]):_0x2dce1b[_0x7bc10b('0x1ff0')]()});});function _0x488dbb(){const _0x37cc81=_0x57554a;_0x44a7d5[_0x37cc81('0x17f')]=[];const _0x154c02=[];_0x44a7d5['queue'][_0x37cc81('0xcf0')]&&_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0xcf0')][_0x37cc81('0x93a')]()===_0x37cc81('0x17cd')&&_0x44a7d5['queue'][_0x37cc81('0x11f3')]===_0x37cc81('0x4d2')&&(_0x44a7d5['queue'][_0x37cc81('0xd31')]=_0x278380[_0x37cc81('0x145a')]?(_0x44a7d5['queue'][_0x37cc81('0x24fa')]||'')+_0x37cc81('0x249e')+_0x278380[_0x37cc81('0x145a')]+'}':(_0x44a7d5[_0x37cc81('0x660')]['prefix']||'')+_0x37cc81('0x20cb'),_0x278380[_0x37cc81('0x75b')]!=='none'?_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x158e')]['indexOf'](_0x37cc81('0x1b1'))<0x0&&(_0x44a7d5[_0x37cc81('0x660')]['options']+='U(xcally-mixmonitor-context)'):_0x44a7d5['queue']['options']=_0x44a7d5['queue'][_0x37cc81('0x158e')][_0x37cc81('0x1725')](_0x37cc81('0x1b1'),''));if(_0x44a7d5[_0x37cc81('0x660')]['appType']&&_0x44a7d5['queue'][_0x37cc81('0x11f3')]==='custom'){}else switch((_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x1d75')]||_0x44a7d5['queue']['appType'])[_0x37cc81('0x93a')]()){case _0x37cc81('0x877'):_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x1407')]=_0x44a7d5['queue'][_0x37cc81('0x60a')]+'='+_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x1c6b')];break;case'custom':break;default:_0x154c02[0x0]=_0x44a7d5['queue'][_0x37cc81('0x660')],_0x154c02[0x1]=_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x158e')],_0x154c02[0x2]=_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x1a0a')],_0x154c02[0x3]=_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x1638')],_0x154c02[0x4]=_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x1668')],_0x154c02[0x5]=_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x19ae')],_0x154c02[0x6]=_0x44a7d5[_0x37cc81('0x660')]['macro'],_0x154c02[0x7]=_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x2550')],_0x154c02[0x8]=_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x10a8')],_0x154c02[0x9]=_0x44a7d5[_0x37cc81('0x660')][_0x37cc81('0x1233')],_0x44a7d5['queue'][_0x37cc81('0x1407')]=_0x154c02[_0x37cc81('0x1630')](',');}_0x416d8e(_0x44a7d5['queue']);}function _0x416d8e(_0x3bbf09){_0x5a4608['hide'](_0x3bbf09);}}const _0x45583b=_0xb31da4;_0x35fdf6[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x3a7'),_0x189033('0xff1'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x35fdf6(_0x1ad30a,_0xf60472,_0x33ab65,_0x2e2b37,_0x916096,_0x4e7cb6,_0x1b061b,_0x3ebd7a){const _0x56e801=_0x189033,_0x597d74=this;_0x597d74[_0x56e801('0x11ed')]=_0x1b061b['getCurrentUser'](),_0x597d74[_0x56e801('0x17f')]=[],_0x597d74[_0x56e801('0xf28')]=_0x56e801('0x241c')+(_0x2e2b37[_0x56e801('0x11f3')]||_0x2e2b37[_0x56e801('0x1d75')])[_0x56e801('0x80')](),_0x597d74[_0x56e801('0x1aa5')]=angular[_0x56e801('0x1a86')](_0x2e2b37),_0x597d74[_0x56e801('0x1134')]=_0x3ebd7a,_0x597d74[_0x56e801('0x258d')]={};if(_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x1407')])switch(_0x597d74[_0x56e801('0x1aa5')]['appType']?_0x597d74[_0x56e801('0x1aa5')]['appType']['toLowerCase']():_0x597d74[_0x56e801('0x1aa5')]['app'][_0x56e801('0x93a')]()){case _0x56e801('0xbf0'):break;case _0x56e801('0x205c'):{const _0x1c9b7d=_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x1407')][_0x56e801('0x1fc5')](',');_0x597d74['ringgroup']['key']=_0x1c9b7d[0x0],_0x597d74['ringgroup'][_0x56e801('0x1a1c')]=_0x1c9b7d[0x1],_0x597d74[_0x56e801('0x1aa5')]['welcomemessage']=_0x1c9b7d[_0x56e801('0x12c8')](0x2,_0x1c9b7d[_0x56e801('0x1564')])[_0x56e801('0x1630')](',');}break;case'dialogflowv2':{const _0x44b602=_0x597d74['ringgroup']['appdata'][_0x56e801('0x1fc5')](',');_0x597d74['ringgroup'][_0x56e801('0x2119')]=_0x44b602[0x0],_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x38')]=_0x44b602[0x1],_0x597d74['ringgroup'][_0x56e801('0x406')]=_0x44b602[0x2],_0x597d74[_0x56e801('0x1aa5')]['language']=_0x44b602[0x3],_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x6d9')]=_0x44b602[_0x56e801('0x12c8')](0x4,_0x44b602[_0x56e801('0x1564')])['join'](',');}break;case _0x56e801('0x1db1'):{const _0x88cf38=_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x1407')][_0x56e801('0x1fc5')](',');_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x7ae')]=_0x88cf38[0x0],_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x204a')]=_0x88cf38[0x1],_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x5ba')]=_0x88cf38[0x2],_0x597d74['ringgroup'][_0x56e801('0x11a9')]=_0x88cf38[0x3],_0x597d74[_0x56e801('0x1aa5')]['welcomemessage']=_0x88cf38[_0x56e801('0x12c8')](0x4,_0x88cf38[_0x56e801('0x1564')])['join'](',');}break;case _0x56e801('0x2408'):{const _0x1b16ec=_0x597d74['ringgroup']['appdata'][_0x56e801('0x1fc5')](',');_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x35')]=isNaN(_0x1b16ec[0x0])?_0x1b16ec[0x0]:parseInt(_0x1b16ec[0x0],0xa),_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x1bcd')]=_0x1b16ec[_0x56e801('0x12c8')](0x1,_0x1b16ec[_0x56e801('0x1564')])[_0x56e801('0x1630')](',');}break;case _0x56e801('0x8c2'):_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x1bcd')]=_0x597d74[_0x56e801('0x1aa5')]['appdata'];break;case _0x56e801('0x877'):_0x597d74['ringgroup'][_0x56e801('0x60a')]=_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x1407')][_0x56e801('0x1fc5')]('=')[0x0],_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x1c6b')]=_0x597d74[_0x56e801('0x1aa5')]['appdata']['split']('=')[0x1];break;case'agi':_0x597d74['ringgroup'][_0x56e801('0x273a')]=_0x597d74['ringgroup']['appdata'];break;default:{const _0x1ab95a=_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x1407')][_0x56e801('0x1fc5')](',');_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0xbf8')]=_0x1ab95a[0x0]['split']('&'),_0x597d74[_0x56e801('0x1aa5')]['timeout']=_0x2e3ca0()[_0x56e801('0x173f')](_0x1ab95a[0x1])?_0x1ab95a[0x1]:isNaN(_0x1ab95a[0x1])?_0x1ab95a[0x1]:parseInt(_0x1ab95a[0x1],0xa),_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x158e')]=_0x2e3ca0()[_0x56e801('0x173f')](_0x1ab95a[0x2])?_0x1ab95a[0x2]:isNaN(_0x1ab95a[0x2])?_0x1ab95a[0x2]:parseInt(_0x1ab95a[0x2],0xa),_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x1284')]=_0x2e3ca0()['isEmpty'](_0x1ab95a[0x3])?_0x1ab95a[0x3]:isNaN(_0x1ab95a[0x3])?_0x1ab95a[0x3]:parseInt(_0x1ab95a[0x3],0xa);}break;}else{}_0x597d74['ringgroup'][_0x56e801('0xcf0')]&&_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0xcf0')][_0x56e801('0x93a')]()==='outbound'&&_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x11f3')][_0x56e801('0x93a')]()===_0x56e801('0x659')&&(_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x24fa')]=_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0xd31')]?_0x597d74[_0x56e801('0x1aa5')]['phone'][_0x56e801('0x1fc5')]('$')[0x0]:undefined,_0x597d74[_0x56e801('0x1aa5')]['callerId']=_0x597d74[_0x56e801('0x1aa5')][_0x56e801('0x73c')]?_0x56e801('0xac1')+_0x597d74['ringgroup']['callerID']:undefined);_0x597d74['saveInboundRouteApp']=_0x392749,_0x597d74[_0x56e801('0xf82')]=_0x114d87;const _0x55b6df=[{'id':0xca,'role':_0x56e801('0x2327')},{'id':0xcb,'role':_0x56e801('0x24d3')}];let _0x400140=null;_0x1b061b[_0x56e801('0xca1')](_0x56e801('0x20c2'))?_0x4e7cb6[_0x56e801('0xc96')][_0x56e801('0x1e6e')]({'fields':'id,name,role','sort':_0x56e801('0x60a'),'nolimit':_0x56e801('0x26ac')})[_0x56e801('0xe53')][_0x56e801('0x683')](function(_0x1d14b8){const _0x1baeb1=_0x56e801;_0x597d74[_0x1baeb1('0x3bf')]=_0x1d14b8[_0x1baeb1('0xf5d')]||[];})[_0x56e801('0x130a')](function(_0x46bfbb){const _0x5ec584=_0x56e801;_0x33ab65[_0x5ec584('0x52a')]({'title':_0x46bfbb['status']?'API:'+_0x46bfbb[_0x5ec584('0x13ee')]+_0x5ec584('0xbf6')+_0x46bfbb['statusText']:'SYSTEM:GET_USERS','msg':_0x46bfbb[_0x5ec584('0x5a5')]?JSON['stringify'](_0x46bfbb[_0x5ec584('0x5a5')]):_0x46bfbb[_0x5ec584('0x1ff0')]()});}):_0x4e7cb6['user'][_0x56e801('0x1e6e')]({'fields':_0x56e801('0xac9'),'sort':'name','nolimit':_0x56e801('0x26ac')})[_0x56e801('0xe53')][_0x56e801('0x683')](function(_0x286d3e){const _0x1a57e1=_0x56e801;_0x400140=_0x286d3e[_0x1a57e1('0xf5d')]||[];})[_0x56e801('0x683')](function(){const _0x2635c0=_0x56e801,_0xc44e35=[];for(let _0x1a0cbf=0x0;_0x1a0cbf<_0x55b6df[_0x2635c0('0x1564')];_0x1a0cbf++){_0xc44e35[_0x2635c0('0x1fd0')](_0x4e7cb6[_0x2635c0('0x22df')][_0x2635c0('0x1e6e')]({'userProfileId':_0x597d74[_0x2635c0('0x11ed')][_0x2635c0('0x2f')],'sectionId':_0x55b6df[_0x1a0cbf]['id']})['$promise']);}return _0xf60472['all'](_0xc44e35);})['then'](function(_0x5d0100){const _0x153a73=_0x56e801,_0x25b7e4=_0x2e3ca0()[_0x153a73('0x386')](_0x5d0100,function(_0x411c2a){const _0x57884d=_0x153a73;return _0x411c2a&&_0x411c2a[_0x57884d('0xf5d')]?_0x411c2a[_0x57884d('0xf5d')][0x0]:null;}),_0x335d4c=[];for(let _0x348ac3=0x0;_0x348ac3<_0x55b6df[_0x153a73('0x1564')];_0x348ac3++){const _0x3d71d0=_0x2e3ca0()[_0x153a73('0x1c07')](_0x25b7e4,['sectionId',_0x55b6df[_0x348ac3]['id']]);if(_0x3d71d0){if(!_0x3d71d0['autoAssociation'])_0x335d4c[_0x153a73('0x1fd0')](_0x4e7cb6[_0x153a73('0xcf7')][_0x153a73('0x1e6e')]({'sectionId':_0x3d71d0['id']})[_0x153a73('0xe53')]);else{const _0x3f09ca=[];_0x400140[_0x153a73('0x1299')](function(_0x1a83ff){const _0x1e476f=_0x153a73;_0x1a83ff[_0x1e476f('0xecb')]===_0x55b6df[_0x348ac3]['role']&&_0x3f09ca[_0x1e476f('0x1fd0')](_0x1a83ff);}),_0x335d4c['push']({'rows':_0x3f09ca,'count':_0x3f09ca[_0x153a73('0x1564')]});}}}return _0xf60472[_0x153a73('0x252c')](_0x335d4c);})[_0x56e801('0x683')](function(_0x47731d){const _0x40ba01=_0x56e801,_0x463b18=[];let _0xdd69d9=null;_0x597d74[_0x40ba01('0x1aa5')]&&(_0xdd69d9=_0x2e3ca0()[_0x40ba01('0x1c07')](_0x400140,{'name':_0x597d74['ringgroup']['multipleUsers']}));for(let _0x5866c2=0x0;_0x5866c2<_0x47731d[_0x40ba01('0x1564')];_0x5866c2++){const _0xfaea18=_0x47731d[_0x5866c2][_0x40ba01('0xf5d')]||[];_0xfaea18[_0x40ba01('0x1299')](function(_0x3394b4){const _0xf78126=_0x40ba01;_0x463b18[_0xf78126('0x1fd0')](_0x3394b4);});}_0xdd69d9&&!_0x2e3ca0()[_0x40ba01('0x7a2')](_0x463b18,['resourceId',_0xdd69d9['id']])&&_0x400140[_0x40ba01('0x1299')](function(_0x3beb5c){const _0x742a3c=_0x40ba01;_0x3beb5c['id']===_0xdd69d9['id']&&(_0x3beb5c[_0x742a3c('0x319')]=![],_0x463b18[_0x742a3c('0x1fd0')](_0x3beb5c));}),_0x597d74[_0x40ba01('0x3bf')]=_0x463b18;})['catch'](function(_0xf782f8){const _0x3fc24a=_0x56e801;_0x33ab65[_0x3fc24a('0x52a')]({'title':_0xf782f8[_0x3fc24a('0x13ee')]?_0x3fc24a('0x2168')+_0xf782f8[_0x3fc24a('0x13ee')]+_0x3fc24a('0xbf6')+_0xf782f8['statusText']:_0x3fc24a('0x1511'),'msg':_0xf782f8['data']?JSON[_0x3fc24a('0x258a')](_0xf782f8['data']):_0xf782f8[_0x3fc24a('0x1ff0')]()});});function _0x392749(){const _0x59a116=_0x56e801;_0x597d74[_0x59a116('0x17f')]=[];const _0x36795c=[];_0x597d74[_0x59a116('0x1aa5')][_0x59a116('0xcf0')]&&_0x597d74['ringgroup'][_0x59a116('0xcf0')][_0x59a116('0x93a')]()===_0x59a116('0x17cd')&&_0x597d74[_0x59a116('0x1aa5')]['appType']===_0x59a116('0x4d2')&&(_0x597d74[_0x59a116('0x1aa5')]['phone']=_0x916096[_0x59a116('0x145a')]?(_0x597d74['ringgroup']['prefix']||'')+_0x59a116('0x249e')+_0x916096[_0x59a116('0x145a')]+'}':(_0x597d74[_0x59a116('0x1aa5')][_0x59a116('0x24fa')]||'')+'${EXTEN}',_0x916096[_0x59a116('0x75b')]!==_0x59a116('0x925')?_0x597d74[_0x59a116('0x1aa5')][_0x59a116('0x158e')]['indexOf']('U(xcally-mixmonitor-context)')<0x0&&(_0x597d74[_0x59a116('0x1aa5')][_0x59a116('0x158e')]+=_0x59a116('0x1b1')):_0x597d74['ringgroup'][_0x59a116('0x158e')]=_0x597d74[_0x59a116('0x1aa5')][_0x59a116('0x158e')][_0x59a116('0x1725')](_0x59a116('0x1b1'),''));if(_0x597d74[_0x59a116('0x1aa5')][_0x59a116('0x11f3')]&&_0x597d74[_0x59a116('0x1aa5')]['appType']===_0x59a116('0xbf0')){}else switch((_0x597d74['ringgroup'][_0x59a116('0x1d75')]||_0x597d74[_0x59a116('0x1aa5')][_0x59a116('0x11f3')])[_0x59a116('0x93a')]()){case'set':_0x597d74[_0x59a116('0x1aa5')]['appdata']=_0x597d74[_0x59a116('0x1aa5')][_0x59a116('0x60a')]+'='+_0x597d74['ringgroup'][_0x59a116('0x1c6b')];break;case _0x59a116('0xbf0'):break;default:_0x36795c[0x0]=_0x597d74[_0x59a116('0x1aa5')]['multipleUsers'][_0x59a116('0x1630')]('&'),_0x36795c[0x1]=_0x597d74[_0x59a116('0x1aa5')][_0x59a116('0x1668')],_0x36795c[0x2]=_0x597d74['ringgroup'][_0x59a116('0x158e')],_0x36795c[0x3]=_0x597d74['ringgroup'][_0x59a116('0x1284')],_0x597d74['ringgroup'][_0x59a116('0x1407')]=_0x36795c[_0x59a116('0x1630')](',');}_0x114d87(_0x597d74[_0x59a116('0x1aa5')]);}function _0x114d87(_0x28d234){const _0x151929=_0x56e801;_0x1ad30a[_0x151929('0x1715')](_0x28d234);}}const _0x468d4b=_0x35fdf6;_0x8654bf['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x3a7'),_0x189033('0xff1'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x8654bf(_0x5537df,_0x2df494,_0x5ad3bc,_0x3b101c,_0x4916b9,_0x571c03,_0x3eb05b,_0x108694){const _0x167fc5=_0x189033,_0x4e860e=this;_0x4e860e[_0x167fc5('0x11ed')]=_0x3eb05b['getCurrentUser'](),_0x4e860e['errors']=[],_0x4e860e[_0x167fc5('0xf28')]=_0x167fc5('0x241c')+(_0x3b101c[_0x167fc5('0x11f3')]||_0x3b101c[_0x167fc5('0x1d75')])['toUpperCase'](),_0x4e860e[_0x167fc5('0x877')]=angular[_0x167fc5('0x1a86')](_0x3b101c),_0x4e860e[_0x167fc5('0x1134')]=_0x108694,_0x4e860e[_0x167fc5('0x258d')]={};if(_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1407')])switch(_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x11f3')]?_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x11f3')][_0x167fc5('0x93a')]():_0x4e860e['set'][_0x167fc5('0x1d75')]['toLowerCase']()){case _0x167fc5('0xbf0'):break;case _0x167fc5('0x205c'):{const _0x24fd35=_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1407')][_0x167fc5('0x1fc5')](',');_0x4e860e['set'][_0x167fc5('0x1d46')]=_0x24fd35[0x0],_0x4e860e[_0x167fc5('0x877')]['language']=_0x24fd35[0x1],_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x6d9')]=_0x24fd35['slice'](0x2,_0x24fd35[_0x167fc5('0x1564')])[_0x167fc5('0x1630')](',');}break;case'dialogflowv2':{const _0x2203bc=_0x4e860e[_0x167fc5('0x877')]['appdata'][_0x167fc5('0x1fc5')](',');_0x4e860e['set']['projectId']=_0x2203bc[0x0],_0x4e860e[_0x167fc5('0x877')]['clientEmail']=_0x2203bc[0x1],_0x4e860e[_0x167fc5('0x877')]['privateKey']=_0x2203bc[0x2],_0x4e860e[_0x167fc5('0x877')]['language']=_0x2203bc[0x3],_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x6d9')]=_0x2203bc[_0x167fc5('0x12c8')](0x4,_0x2203bc[_0x167fc5('0x1564')])[_0x167fc5('0x1630')](',');}break;case'amazonlex':{const _0x5c9b5a=_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1407')][_0x167fc5('0x1fc5')](',');_0x4e860e['set'][_0x167fc5('0x7ae')]=_0x5c9b5a[0x0],_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x204a')]=_0x5c9b5a[0x1],_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x5ba')]=_0x5c9b5a[0x2],_0x4e860e['set'][_0x167fc5('0x11a9')]=_0x5c9b5a[0x3],_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x6d9')]=_0x5c9b5a[_0x167fc5('0x12c8')](0x4,_0x5c9b5a['length'])['join'](',');}break;case _0x167fc5('0x2408'):{const _0x29f50e=_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1407')]['split'](',');_0x4e860e[_0x167fc5('0x877')]['times']=isNaN(_0x29f50e[0x0])?_0x29f50e[0x0]:parseInt(_0x29f50e[0x0],0xa),_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1bcd')]=_0x29f50e['slice'](0x1,_0x29f50e[_0x167fc5('0x1564')])[_0x167fc5('0x1630')](',');}break;case _0x167fc5('0x8c2'):_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1bcd')]=_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1407')];break;case _0x167fc5('0x877'):_0x4e860e['set'][_0x167fc5('0x60a')]=_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1407')][_0x167fc5('0x1fc5')]('=')[0x0],_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1c6b')]=_0x4e860e[_0x167fc5('0x877')]['appdata'][_0x167fc5('0x1fc5')]('=')[0x1];break;case _0x167fc5('0x19ae'):_0x4e860e['set'][_0x167fc5('0x273a')]=_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1407')];break;default:{const _0x41fee2=_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x1407')][_0x167fc5('0x1fc5')]('=');_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x60a')]=_0x2e3ca0()['isEmpty'](_0x41fee2[0x0])?_0x41fee2[0x0]:isNaN(_0x41fee2[0x0])?_0x41fee2[0x0]:parseInt(_0x41fee2[0x0],0xa),_0x4e860e[_0x167fc5('0x877')]['value']=_0x2e3ca0()['isEmpty'](_0x41fee2[0x1])?_0x41fee2[0x1]:isNaN(_0x41fee2[0x1])?_0x41fee2[0x1]:parseInt(_0x41fee2[0x1],0xa);}break;}else{}_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0xcf0')]&&_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0xcf0')]['toLowerCase']()===_0x167fc5('0x17cd')&&_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x11f3')][_0x167fc5('0x93a')]()===_0x167fc5('0x659')&&(_0x4e860e['set']['prefix']=_0x4e860e['set'][_0x167fc5('0xd31')]?_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0xd31')][_0x167fc5('0x1fc5')]('$')[0x0]:undefined,_0x4e860e[_0x167fc5('0x877')]['callerId']=_0x4e860e[_0x167fc5('0x877')][_0x167fc5('0x73c')]?_0x167fc5('0xac1')+_0x4e860e['set'][_0x167fc5('0x73c')]:undefined);_0x4e860e[_0x167fc5('0xb')]=_0x4da120,_0x4e860e[_0x167fc5('0xf82')]=_0x13ec72,_0x3eb05b[_0x167fc5('0xca1')](_0x167fc5('0x20c2'))?_0x571c03['variable']['get']({'fields':_0x167fc5('0xa10'),'sort':_0x167fc5('0x60a'),'nolimit':_0x167fc5('0x26ac')})['$promise'][_0x167fc5('0x683')](function(_0x51c85d){const _0x2727d4=_0x167fc5;_0x4e860e[_0x2727d4('0x220b')]=_0x51c85d[_0x2727d4('0xf5d')]||[];})['catch'](function(_0xc672f4){const _0x1c7706=_0x167fc5;_0x5ad3bc[_0x1c7706('0x52a')]({'title':_0xc672f4[_0x1c7706('0x13ee')]?_0x1c7706('0x2168')+_0xc672f4['status']+'\x20-\x20'+_0xc672f4[_0x1c7706('0x24a9')]:_0x1c7706('0x9a9'),'msg':_0xc672f4[_0x1c7706('0x5a5')]?JSON['stringify'](_0xc672f4['data']):_0xc672f4[_0x1c7706('0x1ff0')]()});}):_0x571c03[_0x167fc5('0x26e0')]['get']({'fields':_0x167fc5('0xa10'),'sort':_0x167fc5('0x60a'),'nolimit':_0x167fc5('0x26ac')})[_0x167fc5('0xe53')][_0x167fc5('0x683')](function(_0x41f036){const _0x40b438=_0x167fc5;_0x4e860e['variables']=_0x41f036[_0x40b438('0xf5d')]||[];})[_0x167fc5('0x683')](function(){const _0x529d62=_0x167fc5;return _0x571c03['userProfileSection']['get']({'userProfileId':_0x4e860e['currentUser'][_0x529d62('0x2f')],'sectionId':0x3f4})[_0x529d62('0xe53')];})[_0x167fc5('0x683')](function(_0x16dda7){const _0x49f07f=_0x167fc5,_0x4632a0=_0x16dda7&&_0x16dda7[_0x49f07f('0xf5d')]?_0x16dda7[_0x49f07f('0xf5d')][0x0]:null;if(!_0x4632a0){const _0xad435=[];let _0x82719e=null;_0x4e860e[_0x49f07f('0x877')]&&(_0x82719e=_0x2e3ca0()[_0x49f07f('0x1c07')](_0x4e860e[_0x49f07f('0x220b')],{'name':_0x4e860e['set']['name']}));for(let _0x1b296a=0x0;_0x1b296a<_0x4e860e[_0x49f07f('0x220b')]['length'];_0x1b296a++){_0x82719e&&_0x4e860e[_0x49f07f('0x220b')][_0x1b296a]['id']===_0x82719e['id']&&(_0x4e860e[_0x49f07f('0x220b')][_0x1b296a][_0x49f07f('0x319')]=![],_0xad435['push'](_0x4e860e[_0x49f07f('0x220b')][_0x1b296a]));}_0x4e860e[_0x49f07f('0x220b')]=_0xad435;}else{if(!_0x4632a0[_0x49f07f('0x170')])return _0x571c03[_0x49f07f('0xcf7')]['get']({'sectionId':_0x4632a0['id']})['$promise'][_0x49f07f('0x683')](function(_0x473cfe){const _0x868ab2=_0x49f07f,_0x59553d=_0x2e3ca0()['map'](_0x473cfe[_0x868ab2('0xf5d')],function(_0x2794e3){const _0x2daa47=_0x868ab2;return _0x2e3ca0()[_0x2daa47('0x1c07')](_0x4e860e[_0x2daa47('0x220b')],{'id':_0x2794e3[_0x2daa47('0x832')]});});let _0x305980=null;_0x4e860e[_0x868ab2('0x877')]&&(_0x305980=_0x2e3ca0()[_0x868ab2('0x1c07')](_0x4e860e[_0x868ab2('0x220b')],{'name':_0x4e860e['set']['name']}));if(_0x305980&&!_0x2e3ca0()[_0x868ab2('0x7a2')](_0x59553d,['id',_0x305980['id']])){const _0x5d0726=_0x2e3ca0()[_0x868ab2('0x1c07')](_0x4e860e[_0x868ab2('0x220b')],{'id':_0x305980['id']});_0x5d0726[_0x868ab2('0x319')]=![],_0x59553d['push'](_0x5d0726);}_0x4e860e['variables']=_0x59553d;});}})[_0x167fc5('0x130a')](function(_0x27baaa){const _0x24a239=_0x167fc5;_0x5ad3bc['error']({'title':_0x27baaa['status']?_0x24a239('0x2168')+_0x27baaa[_0x24a239('0x13ee')]+_0x24a239('0xbf6')+_0x27baaa[_0x24a239('0x24a9')]:_0x24a239('0x392'),'msg':_0x27baaa[_0x24a239('0x5a5')]?JSON[_0x24a239('0x258a')](_0x27baaa['data']):_0x27baaa['toString']()});});function _0x4da120(){const _0x1d5a37=_0x167fc5;_0x4e860e[_0x1d5a37('0x17f')]=[];const _0x118e38=[];_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0xcf0')]&&_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0xcf0')]['toLowerCase']()===_0x1d5a37('0x17cd')&&_0x4e860e['set'][_0x1d5a37('0x11f3')]===_0x1d5a37('0x4d2')&&(_0x4e860e[_0x1d5a37('0x877')]['phone']=_0x4916b9['cutdigits']?(_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x24fa')]||'')+_0x1d5a37('0x249e')+_0x4916b9[_0x1d5a37('0x145a')]+'}':(_0x4e860e['set']['prefix']||'')+'${EXTEN}',_0x4916b9[_0x1d5a37('0x75b')]!=='none'?_0x4e860e['set'][_0x1d5a37('0x158e')]['indexOf']('U(xcally-mixmonitor-context)')<0x0&&(_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x158e')]+='U(xcally-mixmonitor-context)'):_0x4e860e['set'][_0x1d5a37('0x158e')]=_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x158e')][_0x1d5a37('0x1725')](_0x1d5a37('0x1b1'),''));if(_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x11f3')]&&_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x11f3')]==='custom'){}else switch((_0x4e860e['set'][_0x1d5a37('0x1d75')]||_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x11f3')])['toLowerCase']()){case _0x1d5a37('0x877'):_0x4e860e['set'][_0x1d5a37('0x1407')]=_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x60a')]+'='+_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x1c6b')];break;case _0x1d5a37('0xbf0'):break;default:_0x118e38[0x0]=_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x60a')],_0x118e38[0x1]=_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x1c6b')],_0x4e860e[_0x1d5a37('0x877')][_0x1d5a37('0x1407')]=_0x118e38[_0x1d5a37('0x1630')]('=');}_0x13ec72(_0x4e860e['set']);}function _0x13ec72(_0x3e784a){const _0xa56278=_0x167fc5;_0x5537df[_0xa56278('0x1715')](_0x3e784a);}}const _0x93d3b0=_0x8654bf;_0x2e6144[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x3a7'),_0x189033('0xff1'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x2e6144(_0x1f97a0,_0x1ac72a,_0x38ed52,_0x23b100,_0x2982f4,_0xc89f38,_0x3b8b90,_0x3bbef0){const _0x47d91e=_0x189033,_0x227723=this;_0x227723[_0x47d91e('0x11ed')]=_0x3b8b90[_0x47d91e('0x20b2')](),_0x227723[_0x47d91e('0x17f')]=[],_0x227723[_0x47d91e('0xf28')]=_0x47d91e('0x241c')+(_0x23b100[_0x47d91e('0x11f3')]||_0x23b100[_0x47d91e('0x1d75')])[_0x47d91e('0x80')](),_0x227723[_0x47d91e('0x8ac')]=angular[_0x47d91e('0x1a86')](_0x23b100),_0x227723[_0x47d91e('0x1134')]=_0x3bbef0,_0x227723['hasModulePermissions']={};if(_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x1407')])switch(_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x11f3')]?_0x227723[_0x47d91e('0x8ac')]['appType'][_0x47d91e('0x93a')]():_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x1d75')]['toLowerCase']()){case _0x47d91e('0xbf0'):break;case _0x47d91e('0x205c'):{const _0x267532=_0x227723[_0x47d91e('0x8ac')]['appdata'][_0x47d91e('0x1fc5')](',');_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x1d46')]=_0x267532[0x0],_0x227723[_0x47d91e('0x8ac')]['language']=_0x267532[0x1],_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x6d9')]=_0x267532[_0x47d91e('0x12c8')](0x2,_0x267532[_0x47d91e('0x1564')])[_0x47d91e('0x1630')](',');}break;case'dialogflowv2':{const _0x13d5a2=_0x227723['voicemail'][_0x47d91e('0x1407')]['split'](',');_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x2119')]=_0x13d5a2[0x0],_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x38')]=_0x13d5a2[0x1],_0x227723[_0x47d91e('0x8ac')]['privateKey']=_0x13d5a2[0x2],_0x227723[_0x47d91e('0x8ac')]['language']=_0x13d5a2[0x3],_0x227723['voicemail'][_0x47d91e('0x6d9')]=_0x13d5a2['slice'](0x4,_0x13d5a2['length'])[_0x47d91e('0x1630')](',');}break;case _0x47d91e('0x1db1'):{const _0x92433b=_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x1407')][_0x47d91e('0x1fc5')](',');_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x7ae')]=_0x92433b[0x0],_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x204a')]=_0x92433b[0x1],_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x5ba')]=_0x92433b[0x2],_0x227723['voicemail'][_0x47d91e('0x11a9')]=_0x92433b[0x3],_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x6d9')]=_0x92433b[_0x47d91e('0x12c8')](0x4,_0x92433b[_0x47d91e('0x1564')])[_0x47d91e('0x1630')](',');}break;case'autoreply':{const _0x5e6d59=_0x227723[_0x47d91e('0x8ac')]['appdata'][_0x47d91e('0x1fc5')](',');_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x35')]=isNaN(_0x5e6d59[0x0])?_0x5e6d59[0x0]:parseInt(_0x5e6d59[0x0],0xa),_0x227723['voicemail'][_0x47d91e('0x1bcd')]=_0x5e6d59[_0x47d91e('0x12c8')](0x1,_0x5e6d59[_0x47d91e('0x1564')])[_0x47d91e('0x1630')](',');}break;case'message':_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x1bcd')]=_0x227723['voicemail']['appdata'];break;case _0x47d91e('0x877'):_0x227723['voicemail'][_0x47d91e('0x60a')]=_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x1407')]['split']('=')[0x0],_0x227723[_0x47d91e('0x8ac')]['value']=_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x1407')][_0x47d91e('0x1fc5')]('=')[0x1];break;case _0x47d91e('0x19ae'):_0x227723[_0x47d91e('0x8ac')]['project']=_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x1407')];break;default:{const _0xffa05d=_0x227723[_0x47d91e('0x8ac')]['appdata'][_0x47d91e('0x1fc5')](',');_0x227723['voicemail'][_0x47d91e('0x1a6b')]=_0x2e3ca0()[_0x47d91e('0x173f')](_0xffa05d[0x0])?_0xffa05d[0x0]:isNaN(_0xffa05d[0x0])?_0xffa05d[0x0]:parseInt(_0xffa05d[0x0],0xa),_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x158e')]=_0x2e3ca0()['isEmpty'](_0xffa05d[0x1])?_0xffa05d[0x1]:isNaN(_0xffa05d[0x1])?_0xffa05d[0x1]:parseInt(_0xffa05d[0x1],0xa);}break;}else{}_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0xcf0')]&&_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0xcf0')][_0x47d91e('0x93a')]()===_0x47d91e('0x17cd')&&_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x11f3')][_0x47d91e('0x93a')]()===_0x47d91e('0x659')&&(_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x24fa')]=_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0xd31')]?_0x227723['voicemail'][_0x47d91e('0xd31')][_0x47d91e('0x1fc5')]('$')[0x0]:undefined,_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0xabd')]=_0x227723['voicemail'][_0x47d91e('0x73c')]?_0x47d91e('0xac1')+_0x227723[_0x47d91e('0x8ac')][_0x47d91e('0x73c')]:undefined);_0x227723[_0x47d91e('0xb')]=_0x3a216a,_0x227723[_0x47d91e('0xf82')]=_0x41d957,_0x3b8b90[_0x47d91e('0xca1')](_0x47d91e('0x20c2'))?_0xc89f38[_0x47d91e('0x1a6b')][_0x47d91e('0x1e6e')]({'fields':_0x47d91e('0x24c5'),'sort':_0x47d91e('0x10ae'),'nolimit':'true'})[_0x47d91e('0xe53')]['then'](function(_0x296301){const _0x159e24=_0x47d91e;_0x227723[_0x159e24('0x544')]=_0x296301['rows']||[];})[_0x47d91e('0x130a')](function(_0x1b6f70){const _0x47eba7=_0x47d91e;_0x38ed52[_0x47eba7('0x52a')]({'title':_0x1b6f70[_0x47eba7('0x13ee')]?_0x47eba7('0x2168')+_0x1b6f70[_0x47eba7('0x13ee')]+'\x20-\x20'+_0x1b6f70[_0x47eba7('0x24a9')]:_0x47eba7('0x1631'),'msg':_0x1b6f70[_0x47eba7('0x5a5')]?JSON[_0x47eba7('0x258a')](_0x1b6f70[_0x47eba7('0x5a5')]):_0x1b6f70[_0x47eba7('0x1ff0')]()});}):_0xc89f38['voiceMail'][_0x47d91e('0x1e6e')]({'fields':_0x47d91e('0x24c5'),'sort':'mailbox','nolimit':_0x47d91e('0x26ac')})[_0x47d91e('0xe53')][_0x47d91e('0x683')](function(_0x47a53c){const _0xd59676=_0x47d91e;_0x227723[_0xd59676('0x544')]=_0x47a53c[_0xd59676('0xf5d')]||[];})[_0x47d91e('0x683')](function(){const _0x48ecef=_0x47d91e;return _0xc89f38[_0x48ecef('0x22df')][_0x48ecef('0x1e6e')]({'userProfileId':_0x227723[_0x48ecef('0x11ed')][_0x48ecef('0x2f')],'sectionId':0x196})[_0x48ecef('0xe53')];})[_0x47d91e('0x683')](function(_0x1041f5){const _0x327f3d=_0x47d91e,_0x53cb50=_0x1041f5&&_0x1041f5['rows']?_0x1041f5[_0x327f3d('0xf5d')][0x0]:null;if(!_0x53cb50){const _0x581e30=[];let _0x3afc55=null;_0x227723[_0x327f3d('0x8ac')]&&(_0x3afc55=_0x2e3ca0()[_0x327f3d('0x1c07')](_0x227723['voiceMails'],{'mailbox':_0x227723[_0x327f3d('0x8ac')][_0x327f3d('0x1a6b')]}));for(let _0x1d25c0=0x0;_0x1d25c0<_0x227723['voiceMails']['length'];_0x1d25c0++){_0x3afc55&&_0x227723[_0x327f3d('0x544')][_0x1d25c0]['id']===_0x3afc55['id']&&(_0x227723['voiceMails'][_0x1d25c0]['canSelect']=![],_0x581e30[_0x327f3d('0x1fd0')](_0x227723[_0x327f3d('0x544')][_0x1d25c0]));}_0x227723['voiceMails']=_0x581e30;}else{if(!_0x53cb50[_0x327f3d('0x170')])return _0xc89f38[_0x327f3d('0xcf7')][_0x327f3d('0x1e6e')]({'sectionId':_0x53cb50['id']})[_0x327f3d('0xe53')]['then'](function(_0x4b6d61){const _0x417bd4=_0x327f3d,_0x59c190=_0x2e3ca0()[_0x417bd4('0x386')](_0x4b6d61['rows'],function(_0x551bf6){const _0x3c01bb=_0x417bd4;return _0x2e3ca0()['find'](_0x227723[_0x3c01bb('0x544')],{'id':_0x551bf6[_0x3c01bb('0x832')]});});let _0x42acd1=null;_0x227723[_0x417bd4('0x8ac')]&&(_0x42acd1=_0x2e3ca0()[_0x417bd4('0x1c07')](_0x227723['voiceMails'],{'mailbox':_0x227723[_0x417bd4('0x8ac')][_0x417bd4('0x1a6b')]}));if(_0x42acd1&&!_0x2e3ca0()['some'](_0x59c190,['id',_0x42acd1['id']])){const _0x5ac7a4=_0x2e3ca0()['find'](_0x227723[_0x417bd4('0x544')],{'id':_0x42acd1['id']});_0x5ac7a4[_0x417bd4('0x319')]=![],_0x59c190['push'](_0x5ac7a4);}_0x227723['voiceMails']=_0x59c190;});}})['catch'](function(_0x333b52){const _0x1e495d=_0x47d91e;_0x38ed52[_0x1e495d('0x52a')]({'title':_0x333b52[_0x1e495d('0x13ee')]?'API:'+_0x333b52['status']+_0x1e495d('0xbf6')+_0x333b52['statusText']:_0x1e495d('0x20ee'),'msg':_0x333b52['data']?JSON[_0x1e495d('0x258a')](_0x333b52['data']):_0x333b52[_0x1e495d('0x1ff0')]()});});function _0x3a216a(){const _0x1f2522=_0x47d91e;_0x227723['errors']=[];const _0x285600=[];_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0xcf0')]&&_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0xcf0')]['toLowerCase']()===_0x1f2522('0x17cd')&&_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x11f3')]==='outboundDial'&&(_0x227723['voicemail']['phone']=_0x2982f4[_0x1f2522('0x145a')]?(_0x227723['voicemail'][_0x1f2522('0x24fa')]||'')+_0x1f2522('0x249e')+_0x2982f4[_0x1f2522('0x145a')]+'}':(_0x227723['voicemail'][_0x1f2522('0x24fa')]||'')+_0x1f2522('0x20cb'),_0x2982f4[_0x1f2522('0x75b')]!==_0x1f2522('0x925')?_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x158e')][_0x1f2522('0x824')](_0x1f2522('0x1b1'))<0x0&&(_0x227723[_0x1f2522('0x8ac')]['options']+=_0x1f2522('0x1b1')):_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x158e')]=_0x227723[_0x1f2522('0x8ac')]['options'][_0x1f2522('0x1725')](_0x1f2522('0x1b1'),''));if(_0x227723['voicemail'][_0x1f2522('0x11f3')]&&_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x11f3')]==='custom'){}else switch((_0x227723['voicemail']['app']||_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x11f3')])['toLowerCase']()){case _0x1f2522('0x877'):_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x1407')]=_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x60a')]+'='+_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x1c6b')];break;case'custom':break;default:_0x285600[0x0]=_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x1a6b')],_0x285600[0x1]=_0x227723['voicemail'][_0x1f2522('0x158e')],_0x227723[_0x1f2522('0x8ac')][_0x1f2522('0x1407')]=_0x285600[_0x1f2522('0x1630')](',');}_0x41d957(_0x227723[_0x1f2522('0x8ac')]);}function _0x41d957(_0x5dbd89){const _0x1322f7=_0x47d91e;_0x1f97a0[_0x1322f7('0x1715')](_0x5dbd89);}}const _0x4cb8cd=_0x2e6144;_0x19466a['$inject']=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),'toasty',_0x189033('0xba1'),_0x189033('0xff1'),_0x189033('0x22df')];function _0x19466a(_0x2664c6,_0x59e1ee,_0x35a33e,_0x486b64,_0x4bc9f0,_0x238f17,_0x438275,_0xbdb318,_0x4af1db,_0x48eba9,_0x5eab91,_0x4779c1){const _0x476bbe=_0x189033,_0x5a0453=this;_0x5a0453[_0x476bbe('0x11ed')]=_0x48eba9[_0x476bbe('0x20b2')](),_0x5a0453[_0x476bbe('0xace')]=_0x238f17,_0x5a0453[_0x476bbe('0x260a')]=_0x438275,_0x5a0453[_0x476bbe('0x19b2')]=_0x5a0453[_0x476bbe('0x260a')][_0x476bbe('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5a0453[_0x476bbe('0x1224')]=_0x59e1ee[_0x476bbe('0x173e')]()+'://'+_0x59e1ee['host'](),_0x5a0453[_0x476bbe('0xff1')]=_0x5eab91||_0x2664c6['params'][_0x476bbe('0xff1')]||{},_0x5a0453[_0x476bbe('0x22df')]=_0x4779c1&&_0x4779c1[_0x476bbe('0x50d')]==0x1?_0x4779c1[_0x476bbe('0xf5d')][0x0]:null,_0x5a0453[_0x476bbe('0x1134')]=_0x48eba9[_0x476bbe('0x142a')](_0x5a0453['userProfileSection']?_0x5a0453[_0x476bbe('0x22df')]['crudPermissions']:null),_0x5a0453[_0x476bbe('0x258d')]={},_0x5a0453[_0x476bbe('0x517')]=_0x2664c6['params']['tab']||0x0,_0x5a0453[_0x476bbe('0x2430')]=_0x4af1db[_0x476bbe('0x2289')],_0x5a0453[_0x476bbe('0x1039')]=_0x4cade3,_0x5a0453[_0x476bbe('0x39b')]=_0x23e535,_0x48eba9[_0x476bbe('0xca1')](_0x476bbe('0x20c2'))?_0xbdb318[_0x476bbe('0x1e4d')][_0x476bbe('0x1e6e')]({'fields':_0x476bbe('0xa10'),'sort':_0x476bbe('0x60a'),'nolimit':_0x476bbe('0x26ac')})['$promise']['then'](function(_0x2eec8f){const _0x2444c2=_0x476bbe;_0x5a0453[_0x2444c2('0x1693')]=_0x2eec8f[_0x2444c2('0xf5d')]||[];})[_0x476bbe('0x130a')](function(_0x3e71e4){const _0x5d63f4=_0x476bbe;_0x4af1db[_0x5d63f4('0x52a')]({'title':_0x3e71e4[_0x5d63f4('0x13ee')]?'API:'+_0x3e71e4['status']+_0x5d63f4('0xbf6')+_0x3e71e4[_0x5d63f4('0x24a9')]:'SYSTEM:GET_CONTEXTS','msg':_0x3e71e4[_0x5d63f4('0x5a5')]?JSON[_0x5d63f4('0x258a')](_0x3e71e4[_0x5d63f4('0x5a5')]):_0x3e71e4[_0x5d63f4('0x1ff0')]()});}):_0xbdb318[_0x476bbe('0x1e4d')]['get']({'fields':_0x476bbe('0xa10'),'sort':_0x476bbe('0x60a'),'nolimit':_0x476bbe('0x26ac')})[_0x476bbe('0xe53')][_0x476bbe('0x683')](function(_0x44a83b){const _0x1971a9=_0x476bbe;_0x5a0453[_0x1971a9('0x1693')]=_0x44a83b[_0x1971a9('0xf5d')]||[];})['then'](function(){const _0xdd1725=_0x476bbe;return _0xbdb318[_0xdd1725('0x22df')][_0xdd1725('0x1e6e')]({'userProfileId':_0x5a0453[_0xdd1725('0x11ed')][_0xdd1725('0x2f')],'sectionId':0x195})[_0xdd1725('0xe53')];})[_0x476bbe('0x683')](function(_0x4c8045){const _0x4ad619=_0x476bbe,_0xb4527b=_0x4c8045&&_0x4c8045['rows']?_0x4c8045[_0x4ad619('0xf5d')][0x0]:null;if(!_0xb4527b)return _0xbdb318[_0x4ad619('0x1e4d')]['get']({'fields':'id,name','sort':_0x4ad619('0x60a'),'nolimit':_0x4ad619('0x26ac'),'defaultEntry':0x1})[_0x4ad619('0xe53')][_0x4ad619('0x683')](function(_0x20fca8){const _0x184674=_0x4ad619;_0x5a0453[_0x184674('0x1693')]=_0x20fca8[_0x184674('0xf5d')]||[];});else{if(!_0xb4527b['autoAssociation'])return _0xbdb318[_0x4ad619('0xcf7')][_0x4ad619('0x1e6e')]({'sectionId':_0xb4527b['id']})[_0x4ad619('0xe53')][_0x4ad619('0x683')](function(_0x371c49){const _0xd25ba6=_0x4ad619,_0xa7d2db=_0x2e3ca0()[_0xd25ba6('0x386')](_0x371c49[_0xd25ba6('0xf5d')],function(_0x141f17){const _0x4649f6=_0xd25ba6;return _0x2e3ca0()[_0x4649f6('0x1c07')](_0x5a0453[_0x4649f6('0x1693')],{'id':_0x141f17[_0x4649f6('0x832')]});});let _0xfb7a91=null;_0x5a0453['inboundroute']&&(_0xfb7a91=_0x2e3ca0()['find'](_0x5a0453['contexts'],{'name':_0x5a0453[_0xd25ba6('0xff1')]['context']}));if(_0xfb7a91&&!_0x2e3ca0()[_0xd25ba6('0x7a2')](_0xa7d2db,['id',_0xfb7a91['id']])){const _0x17f082=_0x2e3ca0()[_0xd25ba6('0x1c07')](_0x5a0453[_0xd25ba6('0x1693')],{'id':_0xfb7a91['id']});_0x17f082[_0xd25ba6('0x319')]=![],_0xa7d2db[_0xd25ba6('0x1fd0')](_0x17f082);}_0x5a0453['contexts']=_0xa7d2db;});}})['catch'](function(_0x19257a){const _0x55a93d=_0x476bbe;_0x4af1db[_0x55a93d('0x52a')]({'title':_0x19257a['status']?_0x55a93d('0x2168')+_0x19257a[_0x55a93d('0x13ee')]+_0x55a93d('0xbf6')+_0x19257a[_0x55a93d('0x24a9')]:_0x55a93d('0x1a60'),'msg':_0x19257a[_0x55a93d('0x5a5')]?JSON[_0x55a93d('0x258a')](_0x19257a[_0x55a93d('0x5a5')]):_0x19257a['toString']()});});function _0x4cade3(){_0x2664c6['go']('app.voice.inboundroutes',{},{'reload':'app.voice.inboundroutes'});}function _0x23e535(){const _0x3b7e96=_0x476bbe;_0xbdb318[_0x3b7e96('0x14cb')][_0x3b7e96('0x2480')]({'id':_0x5a0453[_0x3b7e96('0xff1')]['id']},_0x5a0453[_0x3b7e96('0xff1')])[_0x3b7e96('0xe53')][_0x3b7e96('0x683')](function(){const _0x1e1434=_0x3b7e96;_0x4af1db[_0x1e1434('0x53')]({'title':_0x1e1434('0x24b'),'msg':_0x5a0453[_0x1e1434('0xff1')][_0x1e1434('0x60a')]?_0x5a0453['inboundroute']['name']+'\x20has\x20been\x20updated!':''});})['catch'](function(_0x56b639){const _0x109052=_0x3b7e96;_0x4af1db[_0x109052('0x52a')]({'title':_0x56b639[_0x109052('0x13ee')]?_0x109052('0x2168')+_0x56b639[_0x109052('0x13ee')]+_0x109052('0xbf6')+_0x56b639[_0x109052('0x24a9')]:_0x109052('0xb10'),'msg':_0x56b639[_0x109052('0x5a5')]?JSON[_0x109052('0x258a')](_0x56b639['data']):_0x56b639['toString']()});});}}const _0x152bf7=_0x19466a,_0x3cfcd5=_0x180212['p']+'src/js/modules/main/apps/voice/views/inboundroutes/create/dialog.html/dialog.html';_0x1c29f1['$inject']=['$scope',_0x189033('0x2063'),'$state',_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x1f17'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x1c29f1(_0x2bfb3f,_0x2a5151,_0x11f6cb,_0x27ba3c,_0x5bfe0d,_0x3cc03a,_0x483b6b,_0x498701,_0x40143a,_0x1e4c2d,_0x30ae08,_0x30171b,_0x35981e,_0x1f2b88,_0x31c7de,_0xb21b27,_0x2a9f2e){const _0x566f44=_0x189033,_0x1ed21d=this;_0x1ed21d[_0x566f44('0xace')]=_0xb21b27,_0x1ed21d[_0x566f44('0x260a')]=_0x2a9f2e,_0x1ed21d[_0x566f44('0x11ed')]=_0x31c7de[_0x566f44('0x20b2')](),_0x1ed21d[_0x566f44('0x1f17')]=_0x40143a||{'count':0x0,'rows':[]},_0x1ed21d['userProfile']=_0x1e4c2d,_0x1ed21d[_0x566f44('0x22df')]=_0x30ae08&&_0x30ae08[_0x566f44('0x50d')]==0x1?_0x30ae08[_0x566f44('0xf5d')][0x0]:null,_0x1ed21d[_0x566f44('0x1134')]=_0x31c7de[_0x566f44('0x142a')](_0x1ed21d[_0x566f44('0x22df')]?_0x1ed21d[_0x566f44('0x22df')][_0x566f44('0x1134')]:null),_0x1ed21d[_0x566f44('0x5c4')]=_0x566f44('0x1f17'),_0x1ed21d[_0x566f44('0x247')]='',_0x1ed21d[_0x566f44('0x1ce2')]=null,_0x1ed21d[_0x566f44('0x1413')]=[],_0x1ed21d[_0x566f44('0x23a2')]={'fields':'createdAt,updatedAt,id,appdata,type,exten,context,description','type':_0x566f44('0x1535'),'sort':_0x566f44('0xc36'),'VoiceExtensionId':_0x566f44('0x13c'),'limit':0xa,'page':0x1},_0x1ed21d['editstate']=_0x207532,_0x1ed21d[_0x566f44('0x194f')]=_0xda956c,_0x1ed21d[_0x566f44('0x53')]=_0xa94224,_0x1ed21d['getInboundRoutes']=_0x29bd67,_0x1ed21d[_0x566f44('0x132a')]=_0x2d1ed4,_0x1ed21d[_0x566f44('0x1981')]=_0x2ef643,_0x1ed21d[_0x566f44('0x114')]=_0xe69130,_0x1ed21d[_0x566f44('0x1dd9')]=_0x2ba3f4,_0x1ed21d['deselectInboundRoutes']=_0x1b3563,_0x1ed21d[_0x566f44('0x1f8f')]=_0x3a8a84,_0x31c7de[_0x566f44('0xca1')](_0x566f44('0x20c2'))?_0x30171b[_0x566f44('0x1e4d')]['get']({'fields':_0x566f44('0xa10'),'sort':_0x566f44('0x60a'),'nolimit':'true'})['$promise']['then'](function(_0x4612f3){_0x1ed21d['contexts']=_0x4612f3['rows']||[];})[_0x566f44('0x130a')](function(_0x2aa5f1){const _0x50b8c9=_0x566f44;_0x1f2b88[_0x50b8c9('0x52a')]({'title':_0x2aa5f1['status']?_0x50b8c9('0x2168')+_0x2aa5f1[_0x50b8c9('0x13ee')]+_0x50b8c9('0xbf6')+_0x2aa5f1[_0x50b8c9('0x24a9')]:_0x50b8c9('0x1379'),'msg':_0x2aa5f1[_0x50b8c9('0x5a5')]?JSON[_0x50b8c9('0x258a')](_0x2aa5f1[_0x50b8c9('0x5a5')]):_0x2aa5f1['toString']()});}):_0x30171b['voiceContext'][_0x566f44('0x1e6e')]({'fields':_0x566f44('0xa10'),'sort':_0x566f44('0x60a'),'nolimit':_0x566f44('0x26ac')})[_0x566f44('0xe53')]['then'](function(_0x37c58d){const _0x5e4604=_0x566f44;_0x1ed21d[_0x5e4604('0x1693')]=_0x37c58d[_0x5e4604('0xf5d')]||[];})[_0x566f44('0x683')](function(){const _0x5119f6=_0x566f44;return _0x30171b[_0x5119f6('0x22df')][_0x5119f6('0x1e6e')]({'userProfileId':_0x1ed21d[_0x5119f6('0x11ed')][_0x5119f6('0x2f')],'sectionId':0x195})[_0x5119f6('0xe53')];})[_0x566f44('0x683')](function(_0x120430){const _0x4056f8=_0x566f44,_0x189fd7=_0x120430&&_0x120430['rows']?_0x120430[_0x4056f8('0xf5d')][0x0]:null;if(!_0x189fd7)return _0x30171b[_0x4056f8('0x1e4d')][_0x4056f8('0x1e6e')]({'fields':'id,name','sort':_0x4056f8('0x60a'),'nolimit':'true','defaultEntry':0x1})[_0x4056f8('0xe53')][_0x4056f8('0x683')](function(_0x46bdfb){const _0x6799da=_0x4056f8;_0x1ed21d[_0x6799da('0x1693')]=_0x46bdfb[_0x6799da('0xf5d')]||[];});else{if(!_0x189fd7[_0x4056f8('0x170')])return _0x30171b[_0x4056f8('0xcf7')][_0x4056f8('0x1e6e')]({'sectionId':_0x189fd7['id']})[_0x4056f8('0xe53')][_0x4056f8('0x683')](function(_0x4c509f){const _0x5594ee=_0x4056f8,_0x364b14=_0x2e3ca0()[_0x5594ee('0x386')](_0x4c509f[_0x5594ee('0xf5d')],function(_0x194e1b){const _0x4ce66e=_0x5594ee;return _0x2e3ca0()[_0x4ce66e('0x1c07')](_0x1ed21d['contexts'],{'id':_0x194e1b[_0x4ce66e('0x832')]});});let _0x701340=null;_0x1ed21d['inboundroute']&&(_0x701340=_0x2e3ca0()[_0x5594ee('0x1c07')](_0x1ed21d[_0x5594ee('0x1693')],{'name':_0x1ed21d['inboundroute'][_0x5594ee('0x22d3')]}));if(_0x701340&&!_0x2e3ca0()[_0x5594ee('0x7a2')](_0x364b14,['id',_0x701340['id']])){const _0xb23d46=_0x2e3ca0()[_0x5594ee('0x1c07')](_0x1ed21d['contexts'],{'id':_0x701340['id']});_0xb23d46['canSelect']=![],_0x364b14[_0x5594ee('0x1fd0')](_0xb23d46);}_0x1ed21d[_0x5594ee('0x1693')]=_0x364b14;});}})[_0x566f44('0x130a')](function(_0x1bd43b){const _0x3719d9=_0x566f44;_0x1f2b88[_0x3719d9('0x52a')]({'title':_0x1bd43b[_0x3719d9('0x13ee')]?'API:'+_0x1bd43b[_0x3719d9('0x13ee')]+_0x3719d9('0xbf6')+_0x1bd43b[_0x3719d9('0x24a9')]:_0x3719d9('0x1a60'),'msg':_0x1bd43b['data']?JSON[_0x3719d9('0x258a')](_0x1bd43b[_0x3719d9('0x5a5')]):_0x1bd43b[_0x3719d9('0x1ff0')]()});});function _0x207532(_0x441770){const _0x30df8f=_0x566f44;_0x11f6cb['go'](_0x30df8f('0x1225'),{'id':_0x441770['id'],'inboundroute':_0x441770,'crudPermissions':_0x1ed21d[_0x30df8f('0x1134')]});}function _0xda956c(_0x3e21d2,_0x3303ee){const _0x34f68b=_0x566f44,_0x65ec4a=_0x5bfe0d[_0x34f68b('0x1c6f')]()[_0x34f68b('0xf28')](_0x34f68b('0x1b01')+_0x2e3ca0()[_0x34f68b('0x1e03')]('inboundroute')+'?')[_0x34f68b('0x26e3')](_0x34f68b('0xed5')+(_0x3e21d2[_0x34f68b('0x60a')]||_0x34f68b('0xff1'))+_0x34f68b('0x20f1')+_0x34f68b('0x1ee7'))[_0x34f68b('0x1040')](_0x34f68b('0x203f'))['targetEvent'](_0x3303ee)['ok']('OK')['cancel'](_0x34f68b('0x16b8'));_0x5bfe0d[_0x34f68b('0x1d4')](_0x65ec4a)['then'](function(){_0x2ef643(_0x3e21d2);},function(){const _0x12a0ae=_0x34f68b;console[_0x12a0ae('0x1b2b')]('CANCEL');});}let _0x29b65a=!![],_0xfabe18=0x1;_0x2bfb3f[_0x566f44('0x186d')](_0x566f44('0x1e1d'),function(_0x25a78f,_0x575924){const _0x20ff87=_0x566f44;_0x29b65a?_0x483b6b(function(){_0x29b65a=![];}):(!_0x575924&&(_0xfabe18=_0x1ed21d[_0x20ff87('0x23a2')][_0x20ff87('0xdf8')]),_0x25a78f!==_0x575924&&(_0x1ed21d[_0x20ff87('0x23a2')][_0x20ff87('0xdf8')]=0x1),!_0x25a78f&&(_0x1ed21d[_0x20ff87('0x23a2')][_0x20ff87('0xdf8')]=_0xfabe18),_0x1ed21d['getInboundRoutes']());});function _0xa94224(_0x5ceb39){_0x1ed21d['inboundroutes']=_0x5ceb39||{'count':0x0,'rows':[]};}function _0x29bd67(){const _0xe87a40=_0x566f44;_0x1ed21d['query']['offset']=(_0x1ed21d[_0xe87a40('0x23a2')][_0xe87a40('0xdf8')]-0x1)*_0x1ed21d['query'][_0xe87a40('0x6f0')],_0x31c7de[_0xe87a40('0xca1')](_0xe87a40('0x20c2'))?_0x1ed21d[_0xe87a40('0x1883')]=_0x30171b[_0xe87a40('0x14cb')][_0xe87a40('0x1e6e')](_0x1ed21d[_0xe87a40('0x23a2')],_0xa94224)['$promise']:(_0x1ed21d[_0xe87a40('0x23a2')]['id']=_0x1ed21d[_0xe87a40('0x2a')]['id'],_0x1ed21d[_0xe87a40('0x23a2')][_0xe87a40('0x1aa')]='InboundRoutes',_0x1ed21d[_0xe87a40('0x1883')]=_0x30171b[_0xe87a40('0x2a')]['getResources'](_0x1ed21d[_0xe87a40('0x23a2')],_0xa94224)[_0xe87a40('0xe53')]);}function _0x2d1ed4(_0xde9bbc,_0xfa7b37){const _0x1de84c=_0x566f44;_0x5bfe0d[_0x1de84c('0x1d4')]({'controller':_0x1de84c('0xd75'),'controllerAs':'vm','templateUrl':_0x3cfcd5,'parent':angular[_0x1de84c('0x1fcc')](_0x3cc03a[_0x1de84c('0x18e5')]),'targetEvent':_0xde9bbc,'clickOutsideToClose':!![],'locals':{'inboundroute':_0xfa7b37,'inboundroutes':_0x1ed21d[_0x1de84c('0x1f17')][_0x1de84c('0xf5d')],'license':_0x1ed21d['license'],'setting':_0x1ed21d[_0x1de84c('0x260a')],'crudPermissions':_0x1ed21d['crudPermissions']}});}function _0x2ef643(_0x51736a){const _0x22340e=_0x566f44;_0x30171b[_0x22340e('0x14cb')]['delete']({'id':_0x51736a['id']})['$promise']['then'](function(){const _0x8662ac=_0x22340e;_0x2e3ca0()['remove'](_0x1ed21d[_0x8662ac('0x1f17')][_0x8662ac('0xf5d')],{'id':_0x51736a['id']}),_0x1ed21d[_0x8662ac('0x1f17')][_0x8662ac('0x50d')]-=0x1,!_0x1ed21d[_0x8662ac('0x1f17')][_0x8662ac('0xf5d')][_0x8662ac('0x1564')]&&_0x1ed21d['getInboundRoutes'](),_0x1f2b88[_0x8662ac('0x53')]({'title':_0x2e3ca0()[_0x8662ac('0x1e03')]('InboundRoute')+'\x20deleted!','msg':_0x51736a[_0x8662ac('0x60a')]?_0x51736a[_0x8662ac('0x60a')]+_0x8662ac('0x194d'):''});})[_0x22340e('0x130a')](function(_0x1a1ad3){const _0x54cfa3=_0x22340e;if(_0x1a1ad3[_0x54cfa3('0x5a5')]&&_0x1a1ad3['data']['errors']&&_0x1a1ad3[_0x54cfa3('0x5a5')][_0x54cfa3('0x17f')][_0x54cfa3('0x1564')]){_0x1ed21d['errors']=_0x1a1ad3['data'][_0x54cfa3('0x17f')]||[{'message':_0x1a1ad3[_0x54cfa3('0x1ff0')](),'type':'SYSTEM:DELETEvoiceExtension'}];for(let _0x50df7c=0x0;_0x50df7c<_0x1a1ad3['data'][_0x54cfa3('0x17f')][_0x54cfa3('0x1564')];_0x50df7c++){_0x1f2b88[_0x54cfa3('0x52a')]({'title':_0x1a1ad3[_0x54cfa3('0x5a5')][_0x54cfa3('0x17f')][_0x50df7c]['type'],'msg':_0x1a1ad3[_0x54cfa3('0x5a5')][_0x54cfa3('0x17f')][_0x50df7c][_0x54cfa3('0x8c2')]});}}else _0x1f2b88[_0x54cfa3('0x52a')]({'title':_0x1a1ad3['status']?_0x54cfa3('0x2168')+_0x1a1ad3[_0x54cfa3('0x13ee')]+_0x54cfa3('0xbf6')+_0x1a1ad3[_0x54cfa3('0x24a9')]:_0x54cfa3('0x2602'),'msg':_0x1a1ad3['data']?JSON['stringify'](_0x1a1ad3[_0x54cfa3('0x5a5')][_0x54cfa3('0x8c2')]):_0x1a1ad3['message']||_0x1a1ad3[_0x54cfa3('0x1ff0')]()});});}function _0xe69130(){const _0x122117=_0x566f44,_0x3e9dfc=angular[_0x122117('0x1a86')](_0x1ed21d[_0x122117('0x1413')]);return _0x1ed21d['selectedInboundRoutes']=[],_0x3e9dfc;}function _0x2ba3f4(_0x348b39){const _0x44d2c6=_0x566f44,_0x19666f=_0x5bfe0d[_0x44d2c6('0x1c6f')]()['title'](_0x44d2c6('0xdae'))[_0x44d2c6('0x26e3')](''+_0x1ed21d[_0x44d2c6('0x1413')][_0x44d2c6('0x1564')]+_0x44d2c6('0x93c')+_0x44d2c6('0x1ee7'))['ariaLabel'](_0x44d2c6('0xe0c'))[_0x44d2c6('0xe42')](_0x348b39)['ok']('OK')[_0x44d2c6('0x19fb')](_0x44d2c6('0x16b8'));_0x5bfe0d[_0x44d2c6('0x1d4')](_0x19666f)[_0x44d2c6('0x683')](function(){const _0x4ecf9d=_0x44d2c6;_0x1ed21d[_0x4ecf9d('0x1413')][_0x4ecf9d('0x1299')](function(_0x5991b0){_0x2ef643(_0x5991b0);}),_0x1ed21d[_0x4ecf9d('0x1413')]=[];});}function _0x1b3563(){const _0x27118b=_0x566f44;_0x1ed21d[_0x27118b('0x1413')]=[];}function _0x3a8a84(){const _0x4cd32b=_0x566f44;_0x1ed21d[_0x4cd32b('0x1413')]=_0x1ed21d['inboundroutes']['rows'];}}const _0x3bad3b=_0x1c29f1;_0x2c6e71[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q','$translate','toasty',_0x189033('0xffd'),_0x189033('0xc'),_0x189033('0x56b'),_0x189033('0xba1'),'license','setting',_0x189033('0x1134')];function _0x2c6e71(_0x8f206a,_0x5c3f10,_0x26ed90,_0x3fce74,_0x38b77e,_0x20cbb8,_0xae3bb9,_0xb596e5,_0x11be03,_0x1bbeaf,_0x4ed524,_0xb76521,_0x144af4,_0x584237){const _0x128a2a=_0x189033,_0x3ea918=this;_0x3ea918[_0x128a2a('0x11ed')]=_0x4ed524[_0x128a2a('0x20b2')](),_0x3ea918[_0x128a2a('0x17f')]=[],_0x3ea918['setting']=_0x144af4,_0x3ea918['license']=_0xb76521,_0x3ea918['crudPermissions']=_0x584237,_0x3ea918[_0x128a2a('0x258d')]={},_0x3ea918['passwordPattern']=_0x3ea918[_0x128a2a('0x260a')]&&_0x3ea918[_0x128a2a('0x260a')][_0x128a2a('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3ea918[_0x128a2a('0xf28')]=_0x128a2a('0xd7b'),_0x3ea918['internalroute']=angular[_0x128a2a('0x1a86')](_0x11be03),_0x3ea918['internalroutes']=_0xb596e5,_0x3ea918[_0x128a2a('0x384')]=![];!_0x3ea918[_0x128a2a('0xc')]&&(_0x3ea918['internalroute']={'appdata':_0x128a2a('0x1b4f'),'type':_0x128a2a('0x1d43'),'context':'from-sip'},_0x3ea918['title']=_0x128a2a('0xb1d'),_0x3ea918[_0x128a2a('0x384')]=!![]);_0x3ea918[_0x128a2a('0x82e')]=_0x3a1a79,_0x3ea918[_0x128a2a('0xded')]=_0x970f28,_0x3ea918[_0x128a2a('0x958')]=_0x33dded,_0x3ea918[_0x128a2a('0x16b3')]=_0x2e8c04,_0x3ea918['closeDialog']=_0x25e00c,_0x4ed524[_0x128a2a('0xca1')](_0x128a2a('0x20c2'))?_0x1bbeaf['voiceContext']['get']({'fields':_0x128a2a('0xa10'),'sort':'name','nolimit':_0x128a2a('0x26ac')})[_0x128a2a('0xe53')][_0x128a2a('0x683')](function(_0x12e2c5){const _0x438048=_0x128a2a;_0x3ea918[_0x438048('0x1693')]=_0x12e2c5[_0x438048('0xf5d')]||[];})['catch'](function(_0x25407c){const _0x14e191=_0x128a2a;_0xae3bb9[_0x14e191('0x52a')]({'title':_0x25407c[_0x14e191('0x13ee')]?_0x14e191('0x2168')+_0x25407c[_0x14e191('0x13ee')]+_0x14e191('0xbf6')+_0x25407c[_0x14e191('0x24a9')]:_0x14e191('0x1379'),'msg':_0x25407c[_0x14e191('0x5a5')]?JSON[_0x14e191('0x258a')](_0x25407c[_0x14e191('0x5a5')]):_0x25407c['toString']()});}):_0x1bbeaf[_0x128a2a('0x1e4d')]['get']({'fields':_0x128a2a('0xa10'),'sort':_0x128a2a('0x60a'),'nolimit':_0x128a2a('0x26ac')})[_0x128a2a('0xe53')][_0x128a2a('0x683')](function(_0x134441){const _0x4e7b33=_0x128a2a;_0x3ea918[_0x4e7b33('0x1693')]=_0x134441[_0x4e7b33('0xf5d')]||[];})[_0x128a2a('0x683')](function(){const _0x407122=_0x128a2a;return _0x1bbeaf[_0x407122('0x22df')]['get']({'userProfileId':_0x3ea918[_0x407122('0x11ed')][_0x407122('0x2f')],'sectionId':0x195})['$promise'];})[_0x128a2a('0x683')](function(_0x7e072c){const _0x44897d=_0x128a2a,_0x360f9a=_0x7e072c&&_0x7e072c[_0x44897d('0xf5d')]?_0x7e072c[_0x44897d('0xf5d')][0x0]:null;if(!_0x360f9a)return _0x1bbeaf[_0x44897d('0x1e4d')]['get']({'fields':'id,name','sort':_0x44897d('0x60a'),'nolimit':_0x44897d('0x26ac'),'defaultEntry':0x1})['$promise'][_0x44897d('0x683')](function(_0x312398){const _0x4a6d6b=_0x44897d;_0x3ea918[_0x4a6d6b('0x1693')]=_0x312398[_0x4a6d6b('0xf5d')]||[];});else{if(!_0x360f9a[_0x44897d('0x170')])return _0x1bbeaf[_0x44897d('0xcf7')]['get']({'sectionId':_0x360f9a['id']})[_0x44897d('0xe53')]['then'](function(_0x425fdb){const _0x1d97f0=_0x44897d,_0x33fa37=_0x2e3ca0()[_0x1d97f0('0x386')](_0x425fdb[_0x1d97f0('0xf5d')],function(_0x2a62af){const _0xbcb16b=_0x1d97f0;return _0x2e3ca0()[_0xbcb16b('0x1c07')](_0x3ea918[_0xbcb16b('0x1693')],{'id':_0x2a62af[_0xbcb16b('0x832')]});});let _0x1bc34a=null;_0x3ea918[_0x1d97f0('0xc')]&&(_0x1bc34a=_0x2e3ca0()['find'](_0x3ea918[_0x1d97f0('0x1693')],{'name':_0x3ea918[_0x1d97f0('0xc')][_0x1d97f0('0x22d3')]}));if(_0x1bc34a&&!_0x2e3ca0()[_0x1d97f0('0x7a2')](_0x33fa37,['id',_0x1bc34a['id']])){const _0x216644=_0x2e3ca0()['find'](_0x3ea918[_0x1d97f0('0x1693')],{'id':_0x1bc34a['id']});_0x216644[_0x1d97f0('0x319')]=![],_0x33fa37[_0x1d97f0('0x1fd0')](_0x216644);}_0x3ea918['contexts']=_0x33fa37;});}})['catch'](function(_0x1aca60){const _0x4db127=_0x128a2a;_0xae3bb9['error']({'title':_0x1aca60[_0x4db127('0x13ee')]?_0x4db127('0x2168')+_0x1aca60[_0x4db127('0x13ee')]+_0x4db127('0xbf6')+_0x1aca60[_0x4db127('0x24a9')]:_0x4db127('0x1a60'),'msg':_0x1aca60[_0x4db127('0x5a5')]?JSON[_0x4db127('0x258a')](_0x1aca60[_0x4db127('0x5a5')]):_0x1aca60[_0x4db127('0x1ff0')]()});});function _0x3a1a79(){const _0x40e93c=_0x128a2a;_0x3ea918[_0x40e93c('0x17f')]=[],_0x1bbeaf['voiceExtension'][_0x40e93c('0xb0a')](_0x3ea918['internalroute'])[_0x40e93c('0xe53')][_0x40e93c('0x683')](function(_0x336819){const _0x4aa5d6=_0x40e93c;_0x3ea918['internalroutes'][_0x4aa5d6('0x1167')](_0x336819['toJSON']()),_0xae3bb9[_0x4aa5d6('0x53')]({'title':'InternalRoute\x20properly\x20created','msg':_0x3ea918['internalroute'][_0x4aa5d6('0x60a')]?_0x3ea918['internalroute'][_0x4aa5d6('0x60a')]+'\x20has\x20been\x20created!':''}),_0x25e00c(_0x336819);})['catch'](function(_0x44e11a){const _0x18cdff=_0x40e93c;if(_0x44e11a[_0x18cdff('0x5a5')]&&_0x44e11a[_0x18cdff('0x5a5')][_0x18cdff('0x17f')]&&_0x44e11a['data'][_0x18cdff('0x17f')][_0x18cdff('0x1564')]){_0x3ea918[_0x18cdff('0x17f')]=_0x44e11a[_0x18cdff('0x5a5')][_0x18cdff('0x17f')]||[{'message':_0x44e11a[_0x18cdff('0x1ff0')](),'type':_0x18cdff('0x13bd')}];for(let _0x2c82d2=0x0;_0x2c82d2<_0x44e11a[_0x18cdff('0x5a5')][_0x18cdff('0x17f')][_0x18cdff('0x1564')];_0x2c82d2+=0x1){_0xae3bb9[_0x18cdff('0x52a')]({'title':_0x44e11a[_0x18cdff('0x5a5')][_0x18cdff('0x17f')][_0x2c82d2][_0x18cdff('0xcf0')],'msg':_0x44e11a[_0x18cdff('0x5a5')][_0x18cdff('0x17f')][_0x2c82d2][_0x18cdff('0x8c2')]});}}else _0xae3bb9[_0x18cdff('0x52a')]({'title':_0x44e11a[_0x18cdff('0x13ee')]?_0x18cdff('0x2168')+_0x44e11a['status']+_0x18cdff('0xbf6')+_0x44e11a[_0x18cdff('0x24a9')]:_0x18cdff('0x13bd'),'msg':_0x44e11a[_0x18cdff('0x5a5')]?JSON[_0x18cdff('0x258a')](_0x44e11a['data'][_0x18cdff('0x8c2')]):_0x44e11a[_0x18cdff('0x1ff0')]()});});}function _0x970f28(){const _0x1a6707=_0x128a2a;_0x3ea918[_0x1a6707('0x17f')]=[],_0x1bbeaf['voiceExtension'][_0x1a6707('0x2480')]({'id':_0x3ea918[_0x1a6707('0xc')]['id']},_0x3ea918[_0x1a6707('0xc')])[_0x1a6707('0xe53')][_0x1a6707('0x683')](function(_0x551b00){const _0x53ddd5=_0x1a6707,_0x14f1b9=_0x2e3ca0()[_0x53ddd5('0x1c07')](_0x3ea918[_0x53ddd5('0xffd')],{'id':_0x551b00['id']});_0x14f1b9&&_0x2e3ca0()['merge'](_0x14f1b9,_0x2e3ca0()[_0x53ddd5('0x24d0')](_0x551b00['toJSON'](),_0x2e3ca0()['keys'](_0x14f1b9))),_0xae3bb9[_0x53ddd5('0x53')]({'title':'InternalRoute\x20properly\x20saved!','msg':_0x3ea918[_0x53ddd5('0xc')]['name']?_0x3ea918[_0x53ddd5('0xc')][_0x53ddd5('0x60a')]+_0x53ddd5('0xf59'):''}),_0x25e00c(_0x551b00);})['catch'](function(_0x24dadb){const _0x20b710=_0x1a6707;if(_0x24dadb[_0x20b710('0x5a5')]&&_0x24dadb[_0x20b710('0x5a5')][_0x20b710('0x17f')]&&_0x24dadb[_0x20b710('0x5a5')][_0x20b710('0x17f')][_0x20b710('0x1564')]){_0x3ea918['errors']=_0x24dadb[_0x20b710('0x5a5')][_0x20b710('0x17f')]||[{'message':_0x24dadb[_0x20b710('0x1ff0')](),'type':'api.voiceExtension.update'}];for(let _0x518099=0x0;_0x518099<_0x24dadb[_0x20b710('0x5a5')]['errors'][_0x20b710('0x1564')];_0x518099++){_0xae3bb9[_0x20b710('0x52a')]({'title':_0x24dadb[_0x20b710('0x5a5')][_0x20b710('0x17f')][_0x518099][_0x20b710('0xcf0')],'msg':_0x24dadb[_0x20b710('0x5a5')][_0x20b710('0x17f')][_0x518099]['message']});}}else _0xae3bb9['error']({'title':_0x24dadb[_0x20b710('0x13ee')]?'API:'+_0x24dadb[_0x20b710('0x13ee')]+_0x20b710('0xbf6')+_0x24dadb[_0x20b710('0x24a9')]:_0x20b710('0x27e8'),'msg':_0x24dadb['data']?JSON[_0x20b710('0x258a')](_0x24dadb[_0x20b710('0x5a5')]['message']):_0x24dadb[_0x20b710('0x1ff0')]()});});}function _0x33dded(_0x384ff3){const _0x323b63=_0x128a2a;_0x3ea918[_0x323b63('0x17f')]=[];const _0x498b75=_0x3fce74['confirm']()[_0x323b63('0xf28')](_0x323b63('0x4d'))[_0x323b63('0xa6a')](_0x323b63('0x1cbb'))[_0x323b63('0x1040')](_0x323b63('0x217d'))['ok'](_0x323b63('0x2307'))[_0x323b63('0x19fb')](_0x323b63('0x253a'))[_0x323b63('0xe42')](_0x384ff3);_0x3fce74[_0x323b63('0x1d4')](_0x498b75)[_0x323b63('0x683')](function(){const _0x37a918=_0x323b63;_0x1bbeaf[_0x37a918('0x14cb')][_0x37a918('0xd7e')]({'id':_0x3ea918['internalroute']['id']})[_0x37a918('0xe53')][_0x37a918('0x683')](function(){const _0x1f6abf=_0x37a918;_0x2e3ca0()['remove'](_0x3ea918[_0x1f6abf('0xffd')],{'id':_0x3ea918[_0x1f6abf('0xc')]['id']}),_0xae3bb9[_0x1f6abf('0x53')]({'title':'InternalRoute\x20properly\x20deleted!','msg':(_0x3ea918[_0x1f6abf('0xc')]['name']||_0x1f6abf('0xc'))+_0x1f6abf('0x194d')}),_0x25e00c(_0x3ea918[_0x1f6abf('0xc')]);})['catch'](function(_0x49b902){const _0x2c0670=_0x37a918;if(_0x49b902[_0x2c0670('0x5a5')]&&_0x49b902[_0x2c0670('0x5a5')][_0x2c0670('0x17f')]&&_0x49b902[_0x2c0670('0x5a5')][_0x2c0670('0x17f')][_0x2c0670('0x1564')]){_0x3ea918[_0x2c0670('0x17f')]=_0x49b902[_0x2c0670('0x5a5')][_0x2c0670('0x17f')]||[{'message':_0x49b902[_0x2c0670('0x1ff0')](),'type':_0x2c0670('0x17de')}];for(let _0x47a87f=0x0;_0x47a87f<_0x49b902[_0x2c0670('0x5a5')][_0x2c0670('0x17f')][_0x2c0670('0x1564')];_0x47a87f++){_0xae3bb9['error']({'title':_0x49b902[_0x2c0670('0x5a5')][_0x2c0670('0x17f')][_0x47a87f][_0x2c0670('0xcf0')],'msg':_0x49b902['data'][_0x2c0670('0x17f')][_0x47a87f][_0x2c0670('0x8c2')]});}}else _0xae3bb9[_0x2c0670('0x52a')]({'title':_0x49b902[_0x2c0670('0x13ee')]?_0x2c0670('0x2168')+_0x49b902['status']+_0x2c0670('0xbf6')+_0x49b902[_0x2c0670('0x24a9')]:_0x2c0670('0x17de'),'msg':_0x49b902[_0x2c0670('0x5a5')]?JSON[_0x2c0670('0x258a')](_0x49b902['data']['message']):_0x49b902[_0x2c0670('0x8c2')]||_0x49b902['toString']()});});},function(){});}function _0x2e8c04(_0x1648f5){return _0x1648f5===null?undefined:new Date(_0x1648f5);}function _0x25e00c(_0x376fff){_0x3fce74['hide'](_0x376fff);}}const _0x86a16b=_0x2c6e71,_0x20558b=_0x180212['p']+_0x189033('0x19c'),_0x27c063=_0x180212['p']+_0x189033('0x2b4'),_0x20edbe=_0x180212['p']+_0x189033('0x1b3b'),_0x3e4201=_0x180212['p']+_0x189033('0x9a7'),_0x2dbccb=_0x180212['p']+_0x189033('0x1029'),_0x5c274d=_0x180212['p']+_0x189033('0x2075'),_0x3b9d31=_0x180212['p']+'src/js/modules/main/apps/voice/views/internalroutes/edit/apps/internaldial/dialog.html/dialog.html',_0x48b386=_0x180212['p']+_0x189033('0xeec'),_0x57af28=_0x180212['p']+_0x189033('0x18cd'),_0x1deacf=_0x180212['p']+_0x189033('0x2253'),_0x530475=_0x180212['p']+_0x189033('0xf58'),_0x26396b=_0x180212['p']+_0x189033('0x180f'),_0x251c74=_0x180212['p']+'src/js/modules/main/apps/voice/views/internalroutes/edit/apps/voicemail/dialog.html/dialog.html';_0x2f89b6[_0x189033('0x14be')]=[_0x189033('0x56b'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0xba1')];const _0x52cce5={'agi':_0x20558b,'custom':_0x27c063,'dial':_0x20edbe,'externaldial':_0x3e4201,'goto':_0x2dbccb,'hangup':_0x5c274d,'internaldial':_0x3b9d31,'interval':_0x48b386,'playback':_0x57af28,'queue':_0x1deacf,'ringgroup':_0x530475,'set':_0x26396b,'voicemail':_0x251c74};function _0x2f89b6(_0x4eba0b,_0x4f7e5b,_0x2a1b1a,_0x2e6a21,_0x10e4e6){const _0x43b3ee=_0x189033,_0x437cc7=this;_0x437cc7['currentUser']=_0x10e4e6[_0x43b3ee('0x20b2')](),_0x437cc7[_0x43b3ee('0xc')]={},_0x437cc7[_0x43b3ee('0x1f3e')]={'count':0x0,'rows':[]},_0x437cc7[_0x43b3ee('0x1dc9')]=[],_0x437cc7[_0x43b3ee('0x1134')],_0x437cc7[_0x43b3ee('0x23a2')]={'sort':'priority'},_0x437cc7[_0x43b3ee('0x346')]=_0x2e3ca0()[_0x43b3ee('0xfae')](_0x2e3ca0()['sortBy']([{'app':_0x43b3ee('0x22ee'),'appType':_0x43b3ee('0x115c'),'type':_0x43b3ee('0x2507'),'types':['always',_0x43b3ee('0xbf0'),_0x43b3ee('0x2335')],'fields':[],'isApp':![]},{'app':_0x43b3ee('0x1fa'),'appType':_0x43b3ee('0x660'),'context':_0x43b3ee('0x1365'),'type':'Internal','options':'xX','appdata':_0x43b3ee('0xf75'),'icon':_0x43b3ee('0x7ee'),'interval':_0x43b3ee('0x1b54'),'answer':!![],'isApp':!![],'extraApi':[{'name':'sounds','field':{'name':'sound','key':_0x43b3ee('0x1144'),'prefix':_0x43b3ee('0xd4a')},'route':_0x43b3ee('0x1638'),'filters':{'fields':'id,name,save_name','sort':'name','nolimit':!![]},'permissions':{'section':0x3ef}},{'name':_0x43b3ee('0x2da'),'field':{'name':_0x43b3ee('0x660'),'key':_0x43b3ee('0x60a')},'route':_0x43b3ee('0x204c'),'filters':{'type':_0x43b3ee('0x1535'),'fields':_0x43b3ee('0x2035'),'sort':_0x43b3ee('0x60a'),'nolimit':!![]},'permissions':{'section':0x191}}],'fields':[{'title':_0x43b3ee('0x1fa'),'name':_0x43b3ee('0x660'),'type':_0x43b3ee('0x1aae'),'values':_0x43b3ee('0x2da'),'value':_0x43b3ee('0x2543'),'option':_0x43b3ee('0x2543'),'required':!![],'param':0x0},{'title':_0x43b3ee('0x6d'),'name':_0x43b3ee('0x158e'),'type':_0x43b3ee('0x1bcd'),'param':0x1},{'title':_0x43b3ee('0x1865'),'name':_0x43b3ee('0x1a0a'),'type':_0x43b3ee('0x1bcd'),'param':0x2},{'title':_0x43b3ee('0x140b'),'name':_0x43b3ee('0x1638'),'type':_0x43b3ee('0x1aae'),'values':'sounds','value':_0x43b3ee('0x6a'),'option':_0x43b3ee('0xb07'),'defaultValues':[{'value':'\x27\x27','option':'None'}],'param':0x3},{'title':_0x43b3ee('0xa09'),'name':_0x43b3ee('0x1668'),'type':_0x43b3ee('0x121f'),'min':0x0,'param':0x4},{'title':_0x43b3ee('0x14a3'),'name':'agi','type':_0x43b3ee('0x1bcd'),'param':0x5},{'title':_0x43b3ee('0x109e'),'name':_0x43b3ee('0xda6'),'type':_0x43b3ee('0x1bcd'),'param':0x6},{'title':_0x43b3ee('0x27ad'),'name':'gosub','type':_0x43b3ee('0x1bcd'),'param':0x7},{'title':_0x43b3ee('0x183a'),'name':_0x43b3ee('0x10a8'),'type':_0x43b3ee('0x1bcd'),'param':0x8},{'title':_0x43b3ee('0x2243'),'name':_0x43b3ee('0x1233'),'type':_0x43b3ee('0x121f'),'min':0x0,'param':0x9},{'title':_0x43b3ee('0x7d6'),'name':'answer','type':_0x43b3ee('0x2d0'),'general':!![]}]},{'app':_0x43b3ee('0x2551'),'appType':_0x43b3ee('0xab0'),'context':_0x43b3ee('0x1365'),'type':_0x43b3ee('0x2507'),'icon':_0x43b3ee('0x7ee'),'interval':_0x43b3ee('0x1b54'),'answer':!![],'isApp':!![],'extraApi':[{'name':_0x43b3ee('0x11d2'),'field':{'name':_0x43b3ee('0x1407'),'key':_0x43b3ee('0x1144'),'prefix':'/var/opt/motion2/server/files/sounds/converted/'},'route':_0x43b3ee('0x1638'),'filters':{'fields':'id,name,save_name','sort':_0x43b3ee('0x60a'),'nolimit':!![]},'permissions':{'section':0x3ef}}],'fields':[{'title':_0x43b3ee('0x150b'),'name':_0x43b3ee('0x1407'),'type':_0x43b3ee('0x1aae'),'values':'sounds','value':'\x27/var/opt/motion2/server/files/sounds/converted/{{appdata.save_name}}\x27','option':'appdata.name','required':!![],'param':0x0},{'title':_0x43b3ee('0x6d'),'name':_0x43b3ee('0x158e'),'type':'text','param':0x1},{'title':_0x43b3ee('0x7d6'),'name':'answer','type':_0x43b3ee('0x2d0'),'general':!![]}]},{'app':_0x43b3ee('0x7c0'),'appType':'dial','context':_0x43b3ee('0x1365'),'type':_0x43b3ee('0x2507'),'icon':_0x43b3ee('0x7ee'),'options':'xX','interval':_0x43b3ee('0x1b54'),'isApp':!![],'fields':[{'title':_0x43b3ee('0x1ef6'),'name':_0x43b3ee('0x1e0f'),'type':'text','required':!![],'param':0x0},{'title':_0x43b3ee('0xa09'),'name':'timeout','type':'number','min':0x0,'param':0x1},{'title':'Options','name':_0x43b3ee('0x158e'),'type':_0x43b3ee('0x1bcd'),'param':0x2},{'title':_0x43b3ee('0x1865'),'name':_0x43b3ee('0x1284'),'type':_0x43b3ee('0x1bcd'),'param':0x3}]},{'app':_0x43b3ee('0x7c0'),'appType':_0x43b3ee('0x5e0'),'context':_0x43b3ee('0x1365'),'type':_0x43b3ee('0x2507'),'icon':_0x43b3ee('0x7ee'),'options':'xX','interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':_0x43b3ee('0x3bf'),'field':{'name':'user','key':'name','prefix':_0x43b3ee('0x1073')},'route':'user','filters':{'fields':_0x43b3ee('0xac9'),'sort':_0x43b3ee('0x60a'),'nolimit':!![]},'permissions':{'sections':[{'id':0xca,'role':_0x43b3ee('0x2327')},{'id':0xcb,'role':_0x43b3ee('0x24d3')}]}}],'fields':[{'title':_0x43b3ee('0x1dad'),'name':_0x43b3ee('0xc96'),'type':'apiselect','values':_0x43b3ee('0x3bf'),'value':_0x43b3ee('0x14df'),'option':'user.name','required':!![],'param':0x0},{'title':'Timeout','name':_0x43b3ee('0x1668'),'type':'number','min':0x0,'param':0x1},{'title':_0x43b3ee('0x6d'),'name':_0x43b3ee('0x158e'),'type':'text','param':0x2},{'title':'Url','name':_0x43b3ee('0x1284'),'type':_0x43b3ee('0x1bcd'),'param':0x3}]},{'app':_0x43b3ee('0x7c0'),'appType':'externalDial','context':'from-sip','type':'Internal','icon':_0x43b3ee('0x7ee'),'interval':_0x43b3ee('0x1b54'),'options':'xX','isApp':!![],'extraApi':[{'name':_0x43b3ee('0x20fe'),'field':{'name':_0x43b3ee('0x1a93'),'key':_0x43b3ee('0x60a')},'route':_0x43b3ee('0x1a93'),'filters':{'fields':_0x43b3ee('0xa10'),'sort':_0x43b3ee('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f3}}],'fields':[{'title':_0x43b3ee('0x17c1'),'name':_0x43b3ee('0x1a93'),'type':_0x43b3ee('0x1aae'),'values':_0x43b3ee('0x20fe'),'value':_0x43b3ee('0x1f1c'),'option':_0x43b3ee('0x1f1c'),'required':!![],'param':0x0},{'title':_0x43b3ee('0x99c'),'name':_0x43b3ee('0xd31'),'type':_0x43b3ee('0x1bcd')},{'title':_0x43b3ee('0xa09'),'name':_0x43b3ee('0x1668'),'type':_0x43b3ee('0x121f'),'min':0x0,'param':0x1},{'title':_0x43b3ee('0x6d'),'name':_0x43b3ee('0x158e'),'type':_0x43b3ee('0x1bcd'),'param':0x2},{'title':'Url','name':_0x43b3ee('0x1284'),'type':_0x43b3ee('0x1bcd'),'param':0x3}]},{'app':_0x43b3ee('0x7c0'),'appType':_0x43b3ee('0x1a2d'),'context':_0x43b3ee('0x1365'),'type':'Internal','icon':_0x43b3ee('0x7ee'),'interval':'*,*,*,*','options':'xX','isApp':!![],'extraApi':[{'name':_0x43b3ee('0x3bf'),'field':{'name':_0x43b3ee('0xbf8'),'key':_0x43b3ee('0x60a'),'prefix':_0x43b3ee('0x1073')},'route':_0x43b3ee('0xc96'),'filters':{'fields':_0x43b3ee('0xac9'),'sort':_0x43b3ee('0x60a'),'nolimit':!![]},'permissions':{'sections':[{'id':0xca,'role':_0x43b3ee('0x2327')},{'id':0xcb,'role':'telephone'}]}}],'fields':[{'title':'User','name':_0x43b3ee('0xbf8'),'type':_0x43b3ee('0x1aae'),'multiple':!![],'values':_0x43b3ee('0x3bf'),'value':_0x43b3ee('0xb9f'),'option':_0x43b3ee('0x1f29'),'required':!![],'param':0x0},{'title':_0x43b3ee('0xa09'),'name':_0x43b3ee('0x1668'),'type':_0x43b3ee('0x121f'),'min':0x0,'param':0x1},{'title':'Options','name':_0x43b3ee('0x158e'),'type':_0x43b3ee('0x1bcd'),'param':0x2},{'title':'Url','name':_0x43b3ee('0x1284'),'type':_0x43b3ee('0x1bcd'),'param':0x3}]},{'app':'AGI','alias':_0x43b3ee('0x4ef'),'appType':_0x43b3ee('0x19ae'),'context':_0x43b3ee('0x1365'),'type':_0x43b3ee('0x2507'),'icon':_0x43b3ee('0x7ee'),'interval':_0x43b3ee('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x43b3ee('0x1248'),'field':{'name':_0x43b3ee('0x273a'),'key':_0x43b3ee('0x60a'),'prefix':_0x43b3ee('0x1f36')},'route':'squareProject','filters':{'fields':_0x43b3ee('0xa10'),'sort':'name','nolimit':!![]},'permissions':{'section':0x44f}}],'fields':[{'title':_0x43b3ee('0x283'),'name':_0x43b3ee('0x273a'),'type':_0x43b3ee('0x1aae'),'values':_0x43b3ee('0x1248'),'value':_0x43b3ee('0x22ef'),'option':_0x43b3ee('0x8f7'),'required':!![],'param':0x0}]},{'app':'goto','appType':_0x43b3ee('0x8be'),'context':_0x43b3ee('0x1365'),'type':_0x43b3ee('0x2507'),'icon':_0x43b3ee('0x7ee'),'interval':_0x43b3ee('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x43b3ee('0x1693'),'field':{'name':_0x43b3ee('0x22d3'),'key':'name'},'route':_0x43b3ee('0x1e4d'),'filters':{'fields':_0x43b3ee('0xa10'),'sort':'name','nolimit':!![]},'permissions':{'section':0x195}}],'fields':[{'title':_0x43b3ee('0x265'),'name':_0x43b3ee('0x22d3'),'type':_0x43b3ee('0x1aae'),'values':'contexts','value':_0x43b3ee('0x6b'),'option':_0x43b3ee('0x6b'),'required':!![],'param':0x0},{'title':'Extension','name':'extension','type':_0x43b3ee('0x1bcd'),'required':!![],'param':0x1},{'title':'Priority','name':_0x43b3ee('0xe1e'),'type':_0x43b3ee('0x1bcd'),'required':!![],'param':0x2}]},{'app':'hangup','appType':'hangup','context':_0x43b3ee('0x1365'),'type':_0x43b3ee('0x2507'),'icon':_0x43b3ee('0x7ee'),'interval':_0x43b3ee('0x1b54'),'isApp':!![],'fields':[{'title':_0x43b3ee('0x13b'),'name':'appdata','type':_0x43b3ee('0xb31'),'param':0x0,'values':[{'option':_0x43b3ee('0x1bfb'),'value':'\x271\x27'},{'option':_0x43b3ee('0x1c3c'),'value':_0x43b3ee('0x19c2')},{'option':_0x43b3ee('0x892'),'value':_0x43b3ee('0x22da')},{'option':'HANGUPCAUSE_18','value':_0x43b3ee('0x2055')},{'option':_0x43b3ee('0x2446'),'value':_0x43b3ee('0x10a3')},{'option':_0x43b3ee('0x1d82'),'value':'\x2722\x27'},{'option':_0x43b3ee('0x2725'),'value':_0x43b3ee('0x259f')},{'option':_0x43b3ee('0x2870'),'value':'\x2738\x27'},{'option':_0x43b3ee('0x1537'),'value':_0x43b3ee('0x2a5')}],'translate':!![],'required':!![],'general':!![]}]},{'app':_0x43b3ee('0x1faa'),'appType':_0x43b3ee('0x877'),'context':_0x43b3ee('0x1365'),'type':_0x43b3ee('0x2507'),'separator':'=','icon':_0x43b3ee('0x7ee'),'interval':_0x43b3ee('0x1b54'),'extraApi':[{'name':_0x43b3ee('0x220b'),'field':{'name':_0x43b3ee('0x60a'),'key':_0x43b3ee('0x60a')},'route':_0x43b3ee('0x26e0'),'filters':{'fields':_0x43b3ee('0xa10'),'sort':_0x43b3ee('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'isApp':!![],'fields':[{'title':'Variable','name':'name','type':_0x43b3ee('0x1aae'),'values':_0x43b3ee('0x220b'),'value':'name.name','option':_0x43b3ee('0x1dd5'),'required':!![],'param':0x0},{'title':_0x43b3ee('0x75d'),'name':_0x43b3ee('0x1c6b'),'type':_0x43b3ee('0x1bcd'),'required':!![],'param':0x1}]},{'app':null,'appType':_0x43b3ee('0xbf0'),'icon':_0x43b3ee('0x7ee'),'type':_0x43b3ee('0x2507'),'interval':_0x43b3ee('0x1b54'),'isApp':!![],'fields':[{'title':_0x43b3ee('0x62f'),'name':_0x43b3ee('0x1d75'),'type':'text','required':!![],'param':0x0},{'title':_0x43b3ee('0xdff'),'name':_0x43b3ee('0x1407'),'type':_0x43b3ee('0x1bcd'),'param':0x1}]},{'app':_0x43b3ee('0xacc'),'appType':'voicemail','context':_0x43b3ee('0x1365'),'icon':'icon-apps','type':_0x43b3ee('0x2507'),'interval':_0x43b3ee('0x1b54'),'isApp':!![],'extraApi':[{'name':'voiceMails','field':{'name':'voiceMail','key':_0x43b3ee('0x10ae'),'suffix':'@from-voicemail'},'route':_0x43b3ee('0x1a6b'),'filters':{'fields':_0x43b3ee('0x24c5'),'sort':_0x43b3ee('0x10ae'),'nolimit':!![]},'permissions':{'section':0x196}}],'fields':[{'title':_0x43b3ee('0x17ea'),'name':_0x43b3ee('0x1a6b'),'type':_0x43b3ee('0x1aae'),'values':_0x43b3ee('0x544'),'value':_0x43b3ee('0x2881'),'option':_0x43b3ee('0xd47'),'required':!![],'param':0x0},{'title':_0x43b3ee('0x6d'),'name':'options','type':_0x43b3ee('0x1bcd'),'param':0x1}]}],['app']),{'isApp':![]}),_0x437cc7[_0x43b3ee('0x2335')]={'group':{'name':'opt1','pull':'clone'},'animation':0x64,'sort':![]},_0x437cc7[_0x43b3ee('0x2146')]={'group':{'name':_0x43b3ee('0x489'),'put':'opt1'},'animation':0x64,'onAdd':function(_0x139180){const _0xb214bb=_0x43b3ee;_0x266a7f(_0x139180,_0x139180[_0xb214bb('0x1ce1')]);},'onSort':function(){_0x3abe61();}},_0x437cc7[_0x43b3ee('0x12f3')]=_0x1cea24,_0x437cc7[_0x43b3ee('0x26eb')]=_0x2c1b21,_0x437cc7['getInternalRouteApps']=_0x3a015a,_0x437cc7[_0x43b3ee('0x1b06')]=_0x266a7f,_0x437cc7[_0x43b3ee('0x24f7')]=_0x202616,_0x437cc7[_0x43b3ee('0x26a8')]=_0x2d9310,_0x437cc7['deleteSelectedInternalRouteApps']=_0xa4faf6,_0x437cc7[_0x43b3ee('0x13f5')]=_0x3abe61,_0x437cc7[_0x43b3ee('0x14a')]=_0x329fce;function _0x1cea24(_0x5e9288,_0x756ef7){const _0x2cc624=_0x43b3ee;_0x437cc7[_0x2cc624('0xc')]=_0x5e9288,_0x437cc7[_0x2cc624('0x1134')]=typeof _0x756ef7!=='undefined'?_0x756ef7:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x437cc7[_0x2cc624('0x2146')][_0x2cc624('0x120b')]=!_0x437cc7[_0x2cc624('0x1134')][_0x2cc624('0x1978')]?!![]:![],_0x437cc7[_0x2cc624('0x23a2')][_0x2cc624('0x18fd')]=_0x5e9288['id'],_0x437cc7[_0x2cc624('0x23a2')]['isApp']=!![],_0x437cc7[_0x2cc624('0x23a2')][_0x2cc624('0x2088')]=!![],_0x437cc7[_0x2cc624('0xa68')](),_0x437cc7[_0x2cc624('0x14a')]();}function _0x2c1b21(_0x22d231,_0x117125,_0x31bc9a){const _0x83553b=_0x43b3ee,_0x4ff2d3=_0x4f7e5b['confirm']()[_0x83553b('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20application?')[_0x83553b('0x26e3')](''+_0x22d231[_0x83553b('0x1d75')]+''+'\x20will\x20be\x20deleted.')[_0x83553b('0x1040')](_0x83553b('0x1312'))[_0x83553b('0xe42')](_0x31bc9a)['ok']('OK')[_0x83553b('0x19fb')]('CANCEL');_0x4f7e5b[_0x83553b('0x1d4')](_0x4ff2d3)['then'](function(){const _0x3cbbc9=_0x83553b;_0x437cc7['internalrouteApps']['rows'][_0x3cbbc9('0x2040')](_0x117125,0x1),_0x3abe61();},function(){const _0x15ee69=_0x83553b;console[_0x15ee69('0x1b2b')](_0x15ee69('0x16b8'));});}function _0x266a7f(_0x4a98b4,_0x30f184){const _0x56912d=_0x43b3ee;if(_0x437cc7[_0x56912d('0x1f3e')][_0x56912d('0xf5d')][_0x56912d('0x1564')]){const _0x5a9fcc=_0x437cc7[_0x56912d('0x1f3e')][_0x56912d('0xf5d')][_0x30f184]?_0x437cc7[_0x56912d('0x1f3e')]['rows'][_0x30f184]:_0x437cc7[_0x56912d('0x1f3e')][_0x56912d('0xf5d')][0x0],_0x3e514a=(_0x5a9fcc['appType']||_0x5a9fcc[_0x56912d('0x1d75')])[_0x56912d('0x93a')]();_0x4f7e5b[_0x56912d('0x1d4')]({'controller':'EditInternalApp'+_0x3e514a+_0x56912d('0x9e4'),'controllerAs':'vm','templateUrl':_0x52cce5[_0x3e514a],'parent':angular['element'](_0x2a1b1a['body']),'targetEvent':_0x4a98b4,'clickOutsideToClose':!![],'locals':{'internalrouteApp':_0x5a9fcc,'internalroute':_0x437cc7[_0x56912d('0xc')],'crudPermissions':_0x437cc7[_0x56912d('0x1134')]}})[_0x56912d('0x683')](function(_0x28ac4d){const _0xdc87e2=_0x56912d;_0x28ac4d&&(_0x28ac4d['id']?_0x437cc7[_0xdc87e2('0x1f3e')][_0xdc87e2('0xf5d')][_0x30f184]=_0x28ac4d:_0x437cc7[_0xdc87e2('0x1f3e')][_0xdc87e2('0xf5d')][_0xdc87e2('0x2040')](_0x30f184,0x0,_0x28ac4d),_0x3abe61());})['catch'](function(_0x4859d0){const _0x12a189=_0x56912d;_0x4859d0&&_0x2e6a21['error']({'title':_0x4859d0[_0x12a189('0x13ee')]?_0x12a189('0x2168')+_0x4859d0[_0x12a189('0x13ee')]+_0x12a189('0xbf6')+_0x4859d0[_0x12a189('0x24a9')]:'SYSTEM:EDITMODALSHOW','msg':_0x4859d0[_0x12a189('0x5a5')]?JSON['stringify'](_0x4859d0[_0x12a189('0x5a5')]):_0x4859d0['toString']()});});}}function _0x202616(_0x290e8b,_0x15195e){const _0x13a2b8=_0x43b3ee;if(_0x437cc7[_0x13a2b8('0x1f3e')]['rows'][_0x13a2b8('0x1564')]){const _0x327af1=_0x437cc7[_0x13a2b8('0x1f3e')][_0x13a2b8('0xf5d')][_0x15195e]?_0x437cc7['internalrouteApps'][_0x13a2b8('0xf5d')][_0x15195e]:_0x437cc7[_0x13a2b8('0x1f3e')][_0x13a2b8('0xf5d')][0x0];_0x4f7e5b[_0x13a2b8('0x1d4')]({'controller':_0x13a2b8('0xf35'),'controllerAs':'vm','templateUrl':_0x48b386,'parent':angular[_0x13a2b8('0x1fcc')](_0x2a1b1a[_0x13a2b8('0x18e5')]),'targetEvent':_0x290e8b,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x327af1[_0x13a2b8('0x115c')],'IntervalId':_0x327af1['IntervalId'],'application':!![]},'intervals':[],'crudPermissions':_0x437cc7[_0x13a2b8('0x1134')]}})['then'](function(_0x36155a){const _0x2525ad=_0x13a2b8;_0x36155a&&(_0x327af1[_0x2525ad('0x115c')]=_0x36155a['interval']||_0x2525ad('0x1b54'),_0x327af1[_0x2525ad('0x5ae')]=_0x36155a['IntervalId']||null,_0x3abe61());});}}function _0x3abe61(){const _0x75d5b6=_0x43b3ee,_0x25b191=[_0x75d5b6('0x660'),_0x75d5b6('0xab0')];let _0x5026be=0x2,_0x2cc36c=[];_0x2cc36c[_0x75d5b6('0x1fd0')]({'type':_0x75d5b6('0x1d43'),'app':_0x75d5b6('0x1faa'),'appdata':_0x75d5b6('0x268f'),'context':_0x437cc7['internalroute'][_0x75d5b6('0x22d3')],'exten':_0x437cc7['internalroute'][_0x75d5b6('0x1a5b')],'priority':_0x5026be++,'VoiceExtensionId':_0x437cc7[_0x75d5b6('0xc')]['id']}),_0x2cc36c['push']({'type':_0x75d5b6('0x1d43'),'app':_0x75d5b6('0x1faa'),'appdata':_0x75d5b6('0xccd'),'context':_0x437cc7['internalroute']['context'],'exten':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x1a5b')],'priority':_0x5026be++,'VoiceExtensionId':_0x437cc7[_0x75d5b6('0xc')]['id']}),_0x2cc36c[_0x75d5b6('0x1fd0')]({'type':_0x75d5b6('0x1d43'),'app':'Set','appdata':_0x75d5b6('0x23d5'),'context':_0x437cc7[_0x75d5b6('0xc')]['context'],'exten':_0x437cc7['internalroute'][_0x75d5b6('0x1a5b')],'priority':_0x5026be++,'VoiceExtensionId':_0x437cc7[_0x75d5b6('0xc')]['id']}),_0x2cc36c[_0x75d5b6('0x1fd0')]({'type':_0x75d5b6('0x1d43'),'app':'Set','appdata':'MONITOR_OPTIONS=ab','context':_0x437cc7[_0x75d5b6('0xc')]['context'],'exten':_0x437cc7['internalroute'][_0x75d5b6('0x1a5b')],'priority':_0x5026be++,'VoiceExtensionId':_0x437cc7[_0x75d5b6('0xc')]['id']});for(let _0x43cd3f=0x0,_0x566a91=0x0;_0x43cd3f<_0x437cc7['internalrouteApps'][_0x75d5b6('0xf5d')][_0x75d5b6('0x1564')];_0x43cd3f++,_0x566a91=0x0){const _0x203f52=_0x437cc7['internalrouteApps'][_0x75d5b6('0xf5d')][_0x43cd3f],_0x1221ac=[],_0x36f563=[];_0x203f52['intervals']=_0x203f52['interval']!==_0x75d5b6('0x1b54')?[_0x203f52['interval']]:_0x203f52[_0x75d5b6('0x5ae')]?_0x2e3ca0()[_0x75d5b6('0x386')](_0x2e3ca0()[_0x75d5b6('0x25')](_0x437cc7[_0x75d5b6('0xe98')][_0x75d5b6('0xf5d')],{'IntervalId':_0x203f52[_0x75d5b6('0x5ae')]}),'interval'):[],_0x203f52[_0x75d5b6('0x22d3')]=_0x437cc7['internalroute'][_0x75d5b6('0x22d3')],_0x203f52[_0x75d5b6('0x1a5b')]=_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x1a5b')];_0x203f52[_0x75d5b6('0xcf0')]&&(_0x203f52[_0x75d5b6('0xcf0')]=_0x203f52[_0x75d5b6('0xcf0')][_0x75d5b6('0x93a')]());typeof _0x203f52[_0x75d5b6('0x1767')]!==_0x75d5b6('0x1867')&&(_0x25b191[_0x75d5b6('0x2292')](_0x203f52['app'][_0x75d5b6('0x93a')]())&&_0x203f52['appType']!==_0x75d5b6('0xbf0')&&(_0x203f52[_0x75d5b6('0x1767')]?(_0x1221ac[_0x75d5b6('0x1fd0')]({'type':_0x203f52[_0x75d5b6('0xcf0')][_0x75d5b6('0x93a')](),'app':'ExecIf','appdata':'$[${XCALLY-MOTION-ANSWER}=0]?Answer','context':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x22d3')],'exten':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x1a5b')],'priority':_0x203f52[_0x75d5b6('0xe98')][_0x75d5b6('0x1564')]+_0x5026be+_0x566a91++,'VoiceExtensionId':_0x437cc7['internalroute']['id']}),_0x1221ac['push']({'type':_0x203f52[_0x75d5b6('0xcf0')][_0x75d5b6('0x93a')](),'app':_0x75d5b6('0x1faa'),'appdata':_0x75d5b6('0x894'),'context':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x22d3')],'exten':_0x437cc7[_0x75d5b6('0xc')]['exten'],'priority':_0x203f52[_0x75d5b6('0xe98')][_0x75d5b6('0x1564')]+_0x5026be+_0x566a91++,'VoiceExtensionId':_0x437cc7[_0x75d5b6('0xc')]['id']})):(_0x1221ac['push']({'type':_0x203f52[_0x75d5b6('0xcf0')]['toLowerCase'](),'app':'ExecIf','appdata':'$[${XCALLY-MOTION-PROGRESS}=0]?Progress','context':_0x437cc7['internalroute']['context'],'exten':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x1a5b')],'priority':_0x203f52[_0x75d5b6('0xe98')][_0x75d5b6('0x1564')]+_0x5026be+_0x566a91++,'VoiceExtensionId':_0x437cc7[_0x75d5b6('0xc')]['id']}),_0x1221ac[_0x75d5b6('0x1fd0')]({'type':_0x203f52[_0x75d5b6('0xcf0')]['toLowerCase'](),'app':_0x75d5b6('0x1faa'),'appdata':_0x75d5b6('0x273f'),'context':_0x437cc7['internalroute'][_0x75d5b6('0x22d3')],'exten':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x1a5b')],'priority':_0x203f52[_0x75d5b6('0xe98')][_0x75d5b6('0x1564')]+_0x5026be+_0x566a91++,'VoiceExtensionId':_0x437cc7[_0x75d5b6('0xc')]['id']}))));for(let _0x3bc8f5=0x0;_0x3bc8f5<_0x203f52[_0x75d5b6('0xe98')][_0x75d5b6('0x1564')];_0x3bc8f5++){const _0x26e99c=_0x5026be+_0x203f52['intervals'][_0x75d5b6('0x1564')],_0x12e35c=_0x3bc8f5===_0x203f52['intervals'][_0x75d5b6('0x1564')]-0x1?_0x5026be+_0x1221ac[_0x75d5b6('0x1564')]+_0x36f563[_0x75d5b6('0x1564')]+0x2:_0x5026be+_0x3bc8f5+0x1;_0x1221ac[_0x75d5b6('0x2040')](_0x3bc8f5,0x0,{'type':_0x75d5b6('0x1d43'),'app':_0x75d5b6('0xeb4'),'appdata':_0x203f52[_0x75d5b6('0xe98')][_0x3bc8f5]+'?'+_0x437cc7[_0x75d5b6('0xc')]['context']+_0x75d5b6('0xd09')+_0x26e99c+':'+_0x437cc7[_0x75d5b6('0xc')]['context']+_0x75d5b6('0xd09')+_0x12e35c,'exten':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x1a5b')],'context':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x22d3')],'priority':_0x5026be+_0x3bc8f5,'VoiceExtensionId':_0x437cc7[_0x75d5b6('0xc')]['id']});}_0x203f52['priority']=_0x1221ac[_0x75d5b6('0x1564')]?_0x2e3ca0()[_0x75d5b6('0xc0f')](_0x1221ac)[_0x75d5b6('0xe1e')]+0x1:_0x5026be,_0x5026be=(_0x36f563[_0x75d5b6('0x1564')]?_0x2e3ca0()[_0x75d5b6('0xc0f')](_0x36f563)[_0x75d5b6('0xe1e')]:_0x203f52[_0x75d5b6('0xe1e')])+0x1,_0x2cc36c=_0x2e3ca0()[_0x75d5b6('0x746')](_0x2cc36c,_0x1221ac,[_0x203f52],_0x36f563);}_0x2cc36c[_0x75d5b6('0x1fd0')]({'type':_0x75d5b6('0x1d43'),'app':_0x75d5b6('0x614'),'exten':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x1a5b')],'context':_0x437cc7[_0x75d5b6('0xc')][_0x75d5b6('0x22d3')],'priority':_0x5026be,'VoiceExtensionId':_0x437cc7[_0x75d5b6('0xc')]['id']}),_0x4eba0b['voiceExtension'][_0x75d5b6('0x10ef')]({'id':_0x437cc7['internalroute']['id']},_0x2e3ca0()[_0x75d5b6('0x742')](_0x2cc36c,_0x75d5b6('0xe1e')))['$promise'][_0x75d5b6('0x683')](function(_0x414f92){const _0x6e461c=_0x75d5b6;_0x437cc7[_0x6e461c('0x1f3e')][_0x6e461c('0xf5d')]=_0x414f92[_0x6e461c('0xf5d')];})[_0x75d5b6('0x130a')](function(_0x36257e){const _0x58afe5=_0x75d5b6;console[_0x58afe5('0x52a')](_0x36257e);});}function _0x3766df(_0x47c16a){const _0x3aef9b=_0x43b3ee;_0x437cc7[_0x3aef9b('0x1f3e')]=_0x47c16a||{'count':0x0,'rows':[]};}function _0x329fce(){const _0x4274dd=_0x43b3ee;return _0x4eba0b[_0x4274dd('0x115c')][_0x4274dd('0x1e6e')]({'fields':_0x4274dd('0x2072')})[_0x4274dd('0xe53')][_0x4274dd('0x683')](function(_0x142071){_0x437cc7['intervals']=_0x142071;})[_0x4274dd('0x130a')](function(_0x272477){const _0x455ef7=_0x4274dd;console[_0x455ef7('0x52a')](_0x272477);});}function _0x3a015a(){const _0x54047a=_0x43b3ee;_0x437cc7['promise']=_0x4eba0b[_0x54047a('0x14cb')]['get'](_0x437cc7[_0x54047a('0x23a2')],_0x3766df)[_0x54047a('0xe53')];}function _0x2d9310(_0x3c991c){const _0x48b6a5=_0x43b3ee;_0x2e3ca0()['remove'](_0x437cc7[_0x48b6a5('0x1f3e')]['rows'],{'id':_0x3c991c['id']}),_0x3abe61(),_0x2e6a21[_0x48b6a5('0x53')]({'title':'App\x20deleted!','msg':_0x3c991c[_0x48b6a5('0x1d75')]?_0x3c991c[_0x48b6a5('0x1d75')]+_0x48b6a5('0x194d'):''});}function _0xa4faf6(_0x1c9512){const _0x1a8a45=_0x43b3ee,_0x343330=_0x4f7e5b['confirm']()[_0x1a8a45('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20applications?')[_0x1a8a45('0x26e3')](''+_0x437cc7[_0x1a8a45('0x1dc9')][_0x1a8a45('0x1564')]+'\x20selected'+_0x1a8a45('0x1ee7'))[_0x1a8a45('0x1040')]('delete\x20applications')[_0x1a8a45('0xe42')](_0x1c9512)['ok']('OK')[_0x1a8a45('0x19fb')](_0x1a8a45('0x16b8'));_0x4f7e5b['show'](_0x343330)[_0x1a8a45('0x683')](function(){const _0xdbd31d=_0x1a8a45;_0x437cc7[_0xdbd31d('0x1dc9')][_0xdbd31d('0x1299')](function(_0x2ac85d){const _0x42c478=_0xdbd31d;_0x2e3ca0()['remove'](_0x437cc7[_0x42c478('0x1f3e')][_0x42c478('0xf5d')],{'id':_0x2ac85d['id']});}),_0x437cc7[_0xdbd31d('0x1dc9')]=[],_0x3abe61();});}}const _0x1191db=_0x2f89b6;_0x308dbc[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'internalrouteApp',_0x189033('0xc'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x308dbc(_0x37b9bf,_0x4ae3bd,_0x11f24,_0x3cdb08,_0x175941,_0x59b075,_0x1e12cd,_0x1f8bb5){const _0x4c75e7=_0x189033,_0x27904b=this;_0x27904b[_0x4c75e7('0x11ed')]=_0x1e12cd[_0x4c75e7('0x20b2')](),_0x27904b['errors']=[],_0x27904b[_0x4c75e7('0xf28')]=_0x4c75e7('0x241c')+(_0x3cdb08[_0x4c75e7('0x11f3')]||_0x3cdb08['app'])['toUpperCase'](),_0x27904b[_0x4c75e7('0x19ae')]=angular[_0x4c75e7('0x1a86')](_0x3cdb08),_0x27904b[_0x4c75e7('0x1134')]=_0x1f8bb5,_0x27904b['hasModulePermissions']={};if(_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1407')])switch(_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x11f3')]?_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x11f3')]['toLowerCase']():_0x27904b['agi'][_0x4c75e7('0x1d75')]['toLowerCase']()){case _0x4c75e7('0xbf0'):break;case _0x4c75e7('0x205c'):{const _0xa4aa4c=_0x27904b[_0x4c75e7('0x19ae')]['appdata']['split'](',');_0x27904b[_0x4c75e7('0x19ae')]['key']=_0xa4aa4c[0x0],_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1a1c')]=_0xa4aa4c[0x1],_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x6d9')]=_0xa4aa4c[_0x4c75e7('0x12c8')](0x2,_0xa4aa4c[_0x4c75e7('0x1564')])[_0x4c75e7('0x1630')](',');}break;case'dialogflowv2':{const _0x470b54=_0x27904b[_0x4c75e7('0x19ae')]['appdata']['split'](',');_0x27904b[_0x4c75e7('0x19ae')]['projectId']=_0x470b54[0x0],_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x38')]=_0x470b54[0x1],_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x406')]=_0x470b54[0x2],_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1a1c')]=_0x470b54[0x3],_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x6d9')]=_0x470b54[_0x4c75e7('0x12c8')](0x4,_0x470b54[_0x4c75e7('0x1564')])[_0x4c75e7('0x1630')](',');}break;case _0x4c75e7('0x1db1'):{const _0x3c52cc=_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1407')][_0x4c75e7('0x1fc5')](',');_0x27904b[_0x4c75e7('0x19ae')]['accesskeyid']=_0x3c52cc[0x0],_0x27904b['agi']['secretaccesskey']=_0x3c52cc[0x1],_0x27904b['agi'][_0x4c75e7('0x5ba')]=_0x3c52cc[0x2],_0x27904b['agi'][_0x4c75e7('0x11a9')]=_0x3c52cc[0x3],_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x6d9')]=_0x3c52cc[_0x4c75e7('0x12c8')](0x4,_0x3c52cc[_0x4c75e7('0x1564')])[_0x4c75e7('0x1630')](',');}break;case _0x4c75e7('0x2408'):{const _0x383153=_0x27904b['agi']['appdata'][_0x4c75e7('0x1fc5')](',');_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x35')]=isNaN(_0x383153[0x0])?_0x383153[0x0]:parseInt(_0x383153[0x0],0xa),_0x27904b['agi'][_0x4c75e7('0x1bcd')]=_0x383153['slice'](0x1,_0x383153[_0x4c75e7('0x1564')])[_0x4c75e7('0x1630')](',');}break;case _0x4c75e7('0x8c2'):_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1bcd')]=_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1407')];break;case _0x4c75e7('0x877'):_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x60a')]=_0x27904b['agi'][_0x4c75e7('0x1407')][_0x4c75e7('0x1fc5')]('=')[0x0],_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1c6b')]=_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1407')]['split']('=')[0x1];break;case'agi':_0x27904b['agi'][_0x4c75e7('0x273a')]=_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1407')];break;default:{const _0x6b8801=_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x1407')][_0x4c75e7('0x1fc5')](',');_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x273a')]=_0x2e3ca0()[_0x4c75e7('0x173f')](_0x6b8801[0x0])?_0x6b8801[0x0]:isNaN(_0x6b8801[0x0])?_0x6b8801[0x0]:parseInt(_0x6b8801[0x0],0xa);}break;}else{}_0x27904b[_0x4c75e7('0x19ae')]['type']&&_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0xcf0')][_0x4c75e7('0x93a')]()===_0x4c75e7('0x17cd')&&_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x11f3')][_0x4c75e7('0x93a')]()===_0x4c75e7('0x659')&&(_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x24fa')]=_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0xd31')]?_0x27904b['agi'][_0x4c75e7('0xd31')][_0x4c75e7('0x1fc5')]('$')[0x0]:undefined,_0x27904b['agi'][_0x4c75e7('0xabd')]=_0x27904b[_0x4c75e7('0x19ae')][_0x4c75e7('0x73c')]?_0x4c75e7('0xac1')+_0x27904b['agi'][_0x4c75e7('0x73c')]:undefined);_0x27904b[_0x4c75e7('0x79b')]=_0x169a7d,_0x27904b[_0x4c75e7('0xf82')]=_0x2b645e,_0x1e12cd['hasRole'](_0x4c75e7('0x20c2'))?_0x59b075[_0x4c75e7('0x27ea')][_0x4c75e7('0x1e6e')]({'fields':_0x4c75e7('0xa10'),'sort':_0x4c75e7('0x60a'),'nolimit':'true'})[_0x4c75e7('0xe53')][_0x4c75e7('0x683')](function(_0x4c3fa9){const _0x74f105=_0x4c75e7;_0x27904b[_0x74f105('0x1248')]=_0x4c3fa9[_0x74f105('0xf5d')]||[];})[_0x4c75e7('0x130a')](function(_0x3acd94){const _0x50d1fa=_0x4c75e7;_0x11f24[_0x50d1fa('0x52a')]({'title':_0x3acd94[_0x50d1fa('0x13ee')]?_0x50d1fa('0x2168')+_0x3acd94[_0x50d1fa('0x13ee')]+'\x20-\x20'+_0x3acd94[_0x50d1fa('0x24a9')]:_0x50d1fa('0xd0e'),'msg':_0x3acd94[_0x50d1fa('0x5a5')]?JSON[_0x50d1fa('0x258a')](_0x3acd94[_0x50d1fa('0x5a5')]):_0x3acd94[_0x50d1fa('0x1ff0')]()});}):_0x59b075[_0x4c75e7('0x27ea')]['get']({'fields':_0x4c75e7('0xa10'),'sort':_0x4c75e7('0x60a'),'nolimit':_0x4c75e7('0x26ac')})[_0x4c75e7('0xe53')][_0x4c75e7('0x683')](function(_0x5b8da8){_0x27904b['projects']=_0x5b8da8['rows']||[];})[_0x4c75e7('0x683')](function(){const _0x2c24d9=_0x4c75e7;return _0x59b075[_0x2c24d9('0x22df')][_0x2c24d9('0x1e6e')]({'userProfileId':_0x27904b['currentUser'][_0x2c24d9('0x2f')],'sectionId':0x44f})[_0x2c24d9('0xe53')];})['then'](function(_0x53bfcd){const _0x1cdd3d=_0x4c75e7,_0x32fb6b=_0x53bfcd&&_0x53bfcd[_0x1cdd3d('0xf5d')]?_0x53bfcd['rows'][0x0]:null;if(!_0x32fb6b){const _0x27c95e=[];let _0x5c2832=null;_0x27904b[_0x1cdd3d('0x19ae')]&&(_0x5c2832=_0x2e3ca0()[_0x1cdd3d('0x1c07')](_0x27904b[_0x1cdd3d('0x1248')],{'name':_0x27904b[_0x1cdd3d('0x19ae')][_0x1cdd3d('0x273a')]}));for(let _0x19fbd7=0x0;_0x19fbd7<_0x27904b['projects']['length'];_0x19fbd7++){_0x5c2832&&_0x27904b[_0x1cdd3d('0x1248')][_0x19fbd7]['id']===_0x5c2832['id']&&(_0x27904b[_0x1cdd3d('0x1248')][_0x19fbd7]['canSelect']=![],_0x27c95e['push'](_0x27904b['projects'][_0x19fbd7]));}_0x27904b[_0x1cdd3d('0x1248')]=_0x27c95e;}else{if(!_0x32fb6b[_0x1cdd3d('0x170')])return _0x59b075[_0x1cdd3d('0xcf7')]['get']({'sectionId':_0x32fb6b['id']})[_0x1cdd3d('0xe53')]['then'](function(_0xd58f59){const _0x5aab36=_0x1cdd3d,_0x26c810=_0x2e3ca0()['map'](_0xd58f59[_0x5aab36('0xf5d')],function(_0x5491e3){const _0x286412=_0x5aab36;return _0x2e3ca0()[_0x286412('0x1c07')](_0x27904b['projects'],{'id':_0x5491e3[_0x286412('0x832')]});});let _0x12a9cf=null;_0x27904b[_0x5aab36('0x19ae')]&&(_0x12a9cf=_0x2e3ca0()['find'](_0x27904b[_0x5aab36('0x1248')],{'name':_0x27904b[_0x5aab36('0x19ae')][_0x5aab36('0x273a')]}));if(_0x12a9cf&&!_0x2e3ca0()[_0x5aab36('0x7a2')](_0x26c810,['id',_0x12a9cf['id']])){const _0x162f5a=_0x2e3ca0()[_0x5aab36('0x1c07')](_0x27904b[_0x5aab36('0x1248')],{'id':_0x12a9cf['id']});_0x162f5a[_0x5aab36('0x319')]=![],_0x26c810[_0x5aab36('0x1fd0')](_0x162f5a);}_0x27904b[_0x5aab36('0x1248')]=_0x26c810;});}})['catch'](function(_0x5853c7){const _0x33d344=_0x4c75e7;_0x11f24[_0x33d344('0x52a')]({'title':_0x5853c7['status']?'API:'+_0x5853c7[_0x33d344('0x13ee')]+_0x33d344('0xbf6')+_0x5853c7['statusText']:'SYSTEM:GETprojects','msg':_0x5853c7[_0x33d344('0x5a5')]?JSON[_0x33d344('0x258a')](_0x5853c7[_0x33d344('0x5a5')]):_0x5853c7[_0x33d344('0x1ff0')]()});});function _0x169a7d(){const _0x208c0d=_0x4c75e7;_0x27904b[_0x208c0d('0x17f')]=[];const _0x1edfc9=[];_0x27904b[_0x208c0d('0x19ae')][_0x208c0d('0xcf0')]&&_0x27904b['agi']['type'][_0x208c0d('0x93a')]()===_0x208c0d('0x17cd')&&_0x27904b[_0x208c0d('0x19ae')]['appType']===_0x208c0d('0x4d2')&&(_0x27904b['agi'][_0x208c0d('0xd31')]=_0x175941[_0x208c0d('0x145a')]?(_0x27904b['agi'][_0x208c0d('0x24fa')]||'')+_0x208c0d('0x249e')+_0x175941['cutdigits']+'}':(_0x27904b[_0x208c0d('0x19ae')][_0x208c0d('0x24fa')]||'')+'${EXTEN}',_0x175941['recordingFormat']!==_0x208c0d('0x925')?_0x27904b[_0x208c0d('0x19ae')]['options'][_0x208c0d('0x824')](_0x208c0d('0x1b1'))<0x0&&(_0x27904b['agi'][_0x208c0d('0x158e')]+=_0x208c0d('0x1b1')):_0x27904b[_0x208c0d('0x19ae')]['options']=_0x27904b['agi']['options'][_0x208c0d('0x1725')](_0x208c0d('0x1b1'),''));if(_0x27904b['agi'][_0x208c0d('0x11f3')]&&_0x27904b[_0x208c0d('0x19ae')][_0x208c0d('0x11f3')]===_0x208c0d('0xbf0')){}else switch((_0x27904b['agi'][_0x208c0d('0x1d75')]||_0x27904b[_0x208c0d('0x19ae')][_0x208c0d('0x11f3')])['toLowerCase']()){case'set':_0x27904b[_0x208c0d('0x19ae')][_0x208c0d('0x1407')]=_0x27904b[_0x208c0d('0x19ae')][_0x208c0d('0x60a')]+'='+_0x27904b[_0x208c0d('0x19ae')]['value'];break;case _0x208c0d('0xbf0'):break;default:_0x1edfc9[0x0]=_0x27904b['agi']['project'],_0x27904b['agi']['appdata']=_0x1edfc9['join'](',');}_0x2b645e(_0x27904b[_0x208c0d('0x19ae')]);}function _0x2b645e(_0xec67df){const _0x16001a=_0x4c75e7;_0x37b9bf[_0x16001a('0x1715')](_0xec67df);}}const _0x268270=_0x308dbc;_0xfc928b[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty','internalrouteApp',_0x189033('0xc'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0xfc928b(_0x13de28,_0x654ca7,_0x57d1d2,_0x390ed7,_0x1e59cf,_0x582ca0,_0x489cb6,_0xa3e8f){const _0x4506d5=_0x189033,_0x6329ec=this;_0x6329ec[_0x4506d5('0x11ed')]=_0x489cb6[_0x4506d5('0x20b2')](),_0x6329ec[_0x4506d5('0x17f')]=[],_0x6329ec[_0x4506d5('0xf28')]='VOICE.EDIT_'+(_0x390ed7[_0x4506d5('0x11f3')]||_0x390ed7[_0x4506d5('0x1d75')])[_0x4506d5('0x80')](),_0x6329ec[_0x4506d5('0xbf0')]=angular['copy'](_0x390ed7),_0x6329ec['crudPermissions']=_0xa3e8f,_0x6329ec[_0x4506d5('0x258d')]={};if(_0x6329ec[_0x4506d5('0xbf0')]['appdata'])switch(_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x11f3')]?_0x6329ec['custom'][_0x4506d5('0x11f3')][_0x4506d5('0x93a')]():_0x6329ec[_0x4506d5('0xbf0')]['app'][_0x4506d5('0x93a')]()){case _0x4506d5('0xbf0'):break;case _0x4506d5('0x205c'):{const _0x2a0f29=_0x6329ec['custom'][_0x4506d5('0x1407')][_0x4506d5('0x1fc5')](',');_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1d46')]=_0x2a0f29[0x0],_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1a1c')]=_0x2a0f29[0x1],_0x6329ec['custom'][_0x4506d5('0x6d9')]=_0x2a0f29[_0x4506d5('0x12c8')](0x2,_0x2a0f29[_0x4506d5('0x1564')])['join'](',');}break;case _0x4506d5('0xd24'):{const _0x420d0b=_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1407')]['split'](',');_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x2119')]=_0x420d0b[0x0],_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x38')]=_0x420d0b[0x1],_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x406')]=_0x420d0b[0x2],_0x6329ec['custom']['language']=_0x420d0b[0x3],_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x6d9')]=_0x420d0b[_0x4506d5('0x12c8')](0x4,_0x420d0b[_0x4506d5('0x1564')])['join'](',');}break;case _0x4506d5('0x1db1'):{const _0x38cfc3=_0x6329ec['custom']['appdata'][_0x4506d5('0x1fc5')](',');_0x6329ec[_0x4506d5('0xbf0')]['accesskeyid']=_0x38cfc3[0x0],_0x6329ec['custom']['secretaccesskey']=_0x38cfc3[0x1],_0x6329ec[_0x4506d5('0xbf0')]['lexregion']=_0x38cfc3[0x2],_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x11a9')]=_0x38cfc3[0x3],_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x6d9')]=_0x38cfc3[_0x4506d5('0x12c8')](0x4,_0x38cfc3[_0x4506d5('0x1564')])['join'](',');}break;case'autoreply':{const _0x291ddd=_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1407')][_0x4506d5('0x1fc5')](',');_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x35')]=isNaN(_0x291ddd[0x0])?_0x291ddd[0x0]:parseInt(_0x291ddd[0x0],0xa),_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1bcd')]=_0x291ddd[_0x4506d5('0x12c8')](0x1,_0x291ddd[_0x4506d5('0x1564')])[_0x4506d5('0x1630')](',');}break;case _0x4506d5('0x8c2'):_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1bcd')]=_0x6329ec['custom']['appdata'];break;case'set':_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x60a')]=_0x6329ec['custom'][_0x4506d5('0x1407')][_0x4506d5('0x1fc5')]('=')[0x0],_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1c6b')]=_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1407')]['split']('=')[0x1];break;case'agi':_0x6329ec['custom']['project']=_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1407')];break;default:{const _0x342e99=_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1407')][_0x4506d5('0x1fc5')](',');_0x6329ec[_0x4506d5('0xbf0')]['app']=_0x2e3ca0()[_0x4506d5('0x173f')](_0x342e99[0x0])?_0x342e99[0x0]:isNaN(_0x342e99[0x0])?_0x342e99[0x0]:parseInt(_0x342e99[0x0],0xa),_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x1407')]=_0x2e3ca0()[_0x4506d5('0x173f')](_0x342e99[0x1])?_0x342e99[0x1]:isNaN(_0x342e99[0x1])?_0x342e99[0x1]:parseInt(_0x342e99[0x1],0xa);}break;}else{}_0x6329ec['custom'][_0x4506d5('0xcf0')]&&_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0xcf0')][_0x4506d5('0x93a')]()===_0x4506d5('0x17cd')&&_0x6329ec[_0x4506d5('0xbf0')]['appType']['toLowerCase']()===_0x4506d5('0x659')&&(_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0x24fa')]=_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0xd31')]?_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0xd31')]['split']('$')[0x0]:undefined,_0x6329ec[_0x4506d5('0xbf0')][_0x4506d5('0xabd')]=_0x6329ec['custom']['callerID']?_0x4506d5('0xac1')+_0x6329ec['custom']['callerID']:undefined);_0x6329ec[_0x4506d5('0x79b')]=_0x4cd024,_0x6329ec['closeDialog']=_0x2e2b0b;function _0x4cd024(){const _0xcddd25=_0x4506d5;_0x6329ec[_0xcddd25('0x17f')]=[];const _0x4fd90c=[];_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0xcf0')]&&_0x6329ec[_0xcddd25('0xbf0')]['type'][_0xcddd25('0x93a')]()==='outbound'&&_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x11f3')]===_0xcddd25('0x4d2')&&(_0x6329ec['custom'][_0xcddd25('0xd31')]=_0x1e59cf[_0xcddd25('0x145a')]?(_0x6329ec[_0xcddd25('0xbf0')]['prefix']||'')+_0xcddd25('0x249e')+_0x1e59cf[_0xcddd25('0x145a')]+'}':(_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x24fa')]||'')+'${EXTEN}',_0x1e59cf[_0xcddd25('0x75b')]!=='none'?_0x6329ec['custom'][_0xcddd25('0x158e')][_0xcddd25('0x824')](_0xcddd25('0x1b1'))<0x0&&(_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x158e')]+=_0xcddd25('0x1b1')):_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x158e')]=_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x158e')]['replace']('U(xcally-mixmonitor-context)',''));if(_0x6329ec['custom']['appType']&&_0x6329ec['custom'][_0xcddd25('0x11f3')]===_0xcddd25('0xbf0')){}else switch((_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x1d75')]||_0x6329ec[_0xcddd25('0xbf0')]['appType'])[_0xcddd25('0x93a')]()){case'set':_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x1407')]=_0x6329ec['custom'][_0xcddd25('0x60a')]+'='+_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x1c6b')];break;case'custom':break;default:_0x4fd90c[0x0]=_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x1d75')],_0x4fd90c[0x1]=_0x6329ec[_0xcddd25('0xbf0')][_0xcddd25('0x1407')],_0x6329ec[_0xcddd25('0xbf0')]['appdata']=_0x4fd90c[_0xcddd25('0x1630')](',');}_0x2e2b0b(_0x6329ec[_0xcddd25('0xbf0')]);}function _0x2e2b0b(_0x18e71b){const _0x4692da=_0x4506d5;_0x13de28[_0x4692da('0x1715')](_0x18e71b);}}const _0x56b6eb=_0xfc928b;_0xfcd2f9[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'internalrouteApp',_0x189033('0xc'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0xfcd2f9(_0x584d73,_0x4b9dcd,_0x5833e4,_0x35ae77,_0x5b7d0a,_0xa5d108,_0x515747,_0x110f54){const _0x464331=_0x189033,_0x59633e=this;_0x59633e[_0x464331('0x11ed')]=_0x515747[_0x464331('0x20b2')](),_0x59633e['errors']=[],_0x59633e[_0x464331('0xf28')]='VOICE.EDIT_'+(_0x35ae77['appType']||_0x35ae77[_0x464331('0x1d75')])['toUpperCase'](),_0x59633e[_0x464331('0x401')]=angular[_0x464331('0x1a86')](_0x35ae77),_0x59633e[_0x464331('0x1134')]=_0x110f54,_0x59633e[_0x464331('0x258d')]={};if(_0x59633e[_0x464331('0x401')][_0x464331('0x1407')])switch(_0x59633e[_0x464331('0x401')][_0x464331('0x11f3')]?_0x59633e[_0x464331('0x401')]['appType'][_0x464331('0x93a')]():_0x59633e[_0x464331('0x401')][_0x464331('0x1d75')][_0x464331('0x93a')]()){case _0x464331('0xbf0'):break;case'dialogflow':{const _0x51f225=_0x59633e['dial'][_0x464331('0x1407')][_0x464331('0x1fc5')](',');_0x59633e['dial'][_0x464331('0x1d46')]=_0x51f225[0x0],_0x59633e[_0x464331('0x401')][_0x464331('0x1a1c')]=_0x51f225[0x1],_0x59633e[_0x464331('0x401')][_0x464331('0x6d9')]=_0x51f225[_0x464331('0x12c8')](0x2,_0x51f225[_0x464331('0x1564')])['join'](',');}break;case _0x464331('0xd24'):{const _0x3ebb3d=_0x59633e[_0x464331('0x401')][_0x464331('0x1407')][_0x464331('0x1fc5')](',');_0x59633e[_0x464331('0x401')][_0x464331('0x2119')]=_0x3ebb3d[0x0],_0x59633e['dial'][_0x464331('0x38')]=_0x3ebb3d[0x1],_0x59633e[_0x464331('0x401')]['privateKey']=_0x3ebb3d[0x2],_0x59633e[_0x464331('0x401')][_0x464331('0x1a1c')]=_0x3ebb3d[0x3],_0x59633e[_0x464331('0x401')][_0x464331('0x6d9')]=_0x3ebb3d[_0x464331('0x12c8')](0x4,_0x3ebb3d[_0x464331('0x1564')])[_0x464331('0x1630')](',');}break;case _0x464331('0x1db1'):{const _0x3c83d7=_0x59633e[_0x464331('0x401')]['appdata'][_0x464331('0x1fc5')](',');_0x59633e[_0x464331('0x401')]['accesskeyid']=_0x3c83d7[0x0],_0x59633e[_0x464331('0x401')][_0x464331('0x204a')]=_0x3c83d7[0x1],_0x59633e[_0x464331('0x401')][_0x464331('0x5ba')]=_0x3c83d7[0x2],_0x59633e[_0x464331('0x401')]['botname']=_0x3c83d7[0x3],_0x59633e[_0x464331('0x401')][_0x464331('0x6d9')]=_0x3c83d7[_0x464331('0x12c8')](0x4,_0x3c83d7[_0x464331('0x1564')])[_0x464331('0x1630')](',');}break;case _0x464331('0x2408'):{const _0x17fb96=_0x59633e['dial'][_0x464331('0x1407')]['split'](',');_0x59633e['dial'][_0x464331('0x35')]=isNaN(_0x17fb96[0x0])?_0x17fb96[0x0]:parseInt(_0x17fb96[0x0],0xa),_0x59633e[_0x464331('0x401')]['text']=_0x17fb96[_0x464331('0x12c8')](0x1,_0x17fb96[_0x464331('0x1564')])['join'](',');}break;case'message':_0x59633e['dial'][_0x464331('0x1bcd')]=_0x59633e[_0x464331('0x401')][_0x464331('0x1407')];break;case'set':_0x59633e[_0x464331('0x401')][_0x464331('0x60a')]=_0x59633e['dial'][_0x464331('0x1407')]['split']('=')[0x0],_0x59633e[_0x464331('0x401')][_0x464331('0x1c6b')]=_0x59633e[_0x464331('0x401')][_0x464331('0x1407')][_0x464331('0x1fc5')]('=')[0x1];break;case _0x464331('0x19ae'):_0x59633e[_0x464331('0x401')][_0x464331('0x273a')]=_0x59633e[_0x464331('0x401')][_0x464331('0x1407')];break;default:{const _0x5eedeb=_0x59633e[_0x464331('0x401')][_0x464331('0x1407')]['split'](',');_0x59633e[_0x464331('0x401')][_0x464331('0x1e0f')]=_0x2e3ca0()[_0x464331('0x173f')](_0x5eedeb[0x0])?_0x5eedeb[0x0]:isNaN(_0x5eedeb[0x0])?_0x5eedeb[0x0]:parseInt(_0x5eedeb[0x0],0xa),_0x59633e['dial'][_0x464331('0x1668')]=_0x2e3ca0()['isEmpty'](_0x5eedeb[0x1])?_0x5eedeb[0x1]:isNaN(_0x5eedeb[0x1])?_0x5eedeb[0x1]:parseInt(_0x5eedeb[0x1],0xa),_0x59633e[_0x464331('0x401')][_0x464331('0x158e')]=_0x2e3ca0()[_0x464331('0x173f')](_0x5eedeb[0x2])?_0x5eedeb[0x2]:isNaN(_0x5eedeb[0x2])?_0x5eedeb[0x2]:parseInt(_0x5eedeb[0x2],0xa),_0x59633e['dial'][_0x464331('0x1284')]=_0x2e3ca0()[_0x464331('0x173f')](_0x5eedeb[0x3])?_0x5eedeb[0x3]:isNaN(_0x5eedeb[0x3])?_0x5eedeb[0x3]:parseInt(_0x5eedeb[0x3],0xa);}break;}else{}_0x59633e[_0x464331('0x401')]['type']&&_0x59633e[_0x464331('0x401')][_0x464331('0xcf0')][_0x464331('0x93a')]()===_0x464331('0x17cd')&&_0x59633e['dial'][_0x464331('0x11f3')]['toLowerCase']()===_0x464331('0x659')&&(_0x59633e[_0x464331('0x401')][_0x464331('0x24fa')]=_0x59633e[_0x464331('0x401')][_0x464331('0xd31')]?_0x59633e[_0x464331('0x401')][_0x464331('0xd31')]['split']('$')[0x0]:undefined,_0x59633e[_0x464331('0x401')][_0x464331('0xabd')]=_0x59633e[_0x464331('0x401')][_0x464331('0x73c')]?_0x464331('0xac1')+_0x59633e[_0x464331('0x401')][_0x464331('0x73c')]:undefined);_0x59633e[_0x464331('0x79b')]=_0x547908,_0x59633e[_0x464331('0xf82')]=_0x4733ca;function _0x547908(){const _0x541810=_0x464331;_0x59633e[_0x541810('0x17f')]=[];const _0x49ef3c=[];_0x59633e['dial'][_0x541810('0xcf0')]&&_0x59633e['dial']['type'][_0x541810('0x93a')]()==='outbound'&&_0x59633e[_0x541810('0x401')][_0x541810('0x11f3')]===_0x541810('0x4d2')&&(_0x59633e[_0x541810('0x401')]['phone']=_0x5b7d0a[_0x541810('0x145a')]?(_0x59633e[_0x541810('0x401')][_0x541810('0x24fa')]||'')+_0x541810('0x249e')+_0x5b7d0a[_0x541810('0x145a')]+'}':(_0x59633e[_0x541810('0x401')][_0x541810('0x24fa')]||'')+_0x541810('0x20cb'),_0x5b7d0a[_0x541810('0x75b')]!==_0x541810('0x925')?_0x59633e[_0x541810('0x401')][_0x541810('0x158e')][_0x541810('0x824')](_0x541810('0x1b1'))<0x0&&(_0x59633e[_0x541810('0x401')][_0x541810('0x158e')]+=_0x541810('0x1b1')):_0x59633e[_0x541810('0x401')][_0x541810('0x158e')]=_0x59633e[_0x541810('0x401')][_0x541810('0x158e')][_0x541810('0x1725')](_0x541810('0x1b1'),''));if(_0x59633e['dial'][_0x541810('0x11f3')]&&_0x59633e[_0x541810('0x401')]['appType']===_0x541810('0xbf0')){}else switch((_0x59633e[_0x541810('0x401')][_0x541810('0x1d75')]||_0x59633e['dial'][_0x541810('0x11f3')])['toLowerCase']()){case _0x541810('0x877'):_0x59633e[_0x541810('0x401')][_0x541810('0x1407')]=_0x59633e['dial'][_0x541810('0x60a')]+'='+_0x59633e[_0x541810('0x401')][_0x541810('0x1c6b')];break;case _0x541810('0xbf0'):break;default:_0x49ef3c[0x0]=_0x59633e[_0x541810('0x401')][_0x541810('0x1e0f')],_0x49ef3c[0x1]=_0x59633e['dial'][_0x541810('0x1668')],_0x49ef3c[0x2]=_0x59633e[_0x541810('0x401')][_0x541810('0x158e')],_0x49ef3c[0x3]=_0x59633e[_0x541810('0x401')][_0x541810('0x1284')],_0x59633e['dial'][_0x541810('0x1407')]=_0x49ef3c[_0x541810('0x1630')](',');}_0x4733ca(_0x59633e[_0x541810('0x401')]);}function _0x4733ca(_0x59bfa2){const _0x3f70ab=_0x464331;_0x584d73[_0x3f70ab('0x1715')](_0x59bfa2);}}const _0x4b51c4=_0xfcd2f9;_0x4580bb[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0xd15'),_0x189033('0xc'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x4580bb(_0x4532d2,_0x2672b9,_0x5e5374,_0x43cf25,_0x584ce5,_0x1740e0,_0x27ca0e,_0x4ee9f9){const _0x1d0f09=_0x189033,_0x48b4bb=this;_0x48b4bb[_0x1d0f09('0x11ed')]=_0x27ca0e[_0x1d0f09('0x20b2')](),_0x48b4bb[_0x1d0f09('0x17f')]=[],_0x48b4bb['title']=_0x1d0f09('0x241c')+(_0x43cf25[_0x1d0f09('0x11f3')]||_0x43cf25[_0x1d0f09('0x1d75')])[_0x1d0f09('0x80')](),_0x48b4bb[_0x1d0f09('0x4fe')]=angular[_0x1d0f09('0x1a86')](_0x43cf25),_0x48b4bb[_0x1d0f09('0x1134')]=_0x4ee9f9,_0x48b4bb[_0x1d0f09('0x258d')]={};if(_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1407')])switch(_0x48b4bb['externaldial'][_0x1d0f09('0x11f3')]?_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x11f3')][_0x1d0f09('0x93a')]():_0x48b4bb[_0x1d0f09('0x4fe')]['app'][_0x1d0f09('0x93a')]()){case _0x1d0f09('0xbf0'):break;case'dialogflow':{const _0x4c4a81=_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1407')][_0x1d0f09('0x1fc5')](',');_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1d46')]=_0x4c4a81[0x0],_0x48b4bb[_0x1d0f09('0x4fe')]['language']=_0x4c4a81[0x1],_0x48b4bb[_0x1d0f09('0x4fe')]['welcomemessage']=_0x4c4a81[_0x1d0f09('0x12c8')](0x2,_0x4c4a81[_0x1d0f09('0x1564')])[_0x1d0f09('0x1630')](',');}break;case _0x1d0f09('0xd24'):{const _0x15a6e5=_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1407')][_0x1d0f09('0x1fc5')](',');_0x48b4bb['externaldial'][_0x1d0f09('0x2119')]=_0x15a6e5[0x0],_0x48b4bb['externaldial']['clientEmail']=_0x15a6e5[0x1],_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x406')]=_0x15a6e5[0x2],_0x48b4bb[_0x1d0f09('0x4fe')]['language']=_0x15a6e5[0x3],_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x6d9')]=_0x15a6e5[_0x1d0f09('0x12c8')](0x4,_0x15a6e5[_0x1d0f09('0x1564')])[_0x1d0f09('0x1630')](',');}break;case _0x1d0f09('0x1db1'):{const _0x558cd6=_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1407')][_0x1d0f09('0x1fc5')](',');_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x7ae')]=_0x558cd6[0x0],_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x204a')]=_0x558cd6[0x1],_0x48b4bb['externaldial']['lexregion']=_0x558cd6[0x2],_0x48b4bb['externaldial']['botname']=_0x558cd6[0x3],_0x48b4bb[_0x1d0f09('0x4fe')]['welcomemessage']=_0x558cd6[_0x1d0f09('0x12c8')](0x4,_0x558cd6[_0x1d0f09('0x1564')])[_0x1d0f09('0x1630')](',');}break;case _0x1d0f09('0x2408'):{const _0x29b5ba=_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1407')][_0x1d0f09('0x1fc5')](',');_0x48b4bb['externaldial']['times']=isNaN(_0x29b5ba[0x0])?_0x29b5ba[0x0]:parseInt(_0x29b5ba[0x0],0xa),_0x48b4bb['externaldial'][_0x1d0f09('0x1bcd')]=_0x29b5ba[_0x1d0f09('0x12c8')](0x1,_0x29b5ba[_0x1d0f09('0x1564')])['join'](',');}break;case _0x1d0f09('0x8c2'):_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1bcd')]=_0x48b4bb[_0x1d0f09('0x4fe')]['appdata'];break;case _0x1d0f09('0x877'):_0x48b4bb[_0x1d0f09('0x4fe')]['name']=_0x48b4bb[_0x1d0f09('0x4fe')]['appdata'][_0x1d0f09('0x1fc5')]('=')[0x0],_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1c6b')]=_0x48b4bb['externaldial'][_0x1d0f09('0x1407')][_0x1d0f09('0x1fc5')]('=')[0x1];break;case _0x1d0f09('0x19ae'):_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x273a')]=_0x48b4bb['externaldial'][_0x1d0f09('0x1407')];break;default:{const _0x4dfe77=_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1407')][_0x1d0f09('0x1fc5')](',');_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1a93')]=_0x4dfe77[0x0][_0x1d0f09('0x1fc5')]('/')[0x1],_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0xd31')]=_0x4dfe77[0x0][_0x1d0f09('0x1fc5')]('/')[0x2],_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1668')]=_0x2e3ca0()[_0x1d0f09('0x173f')](_0x4dfe77[0x1])?_0x4dfe77[0x1]:isNaN(_0x4dfe77[0x1])?_0x4dfe77[0x1]:parseInt(_0x4dfe77[0x1],0xa),_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x158e')]=_0x2e3ca0()[_0x1d0f09('0x173f')](_0x4dfe77[0x2])?_0x4dfe77[0x2]:isNaN(_0x4dfe77[0x2])?_0x4dfe77[0x2]:parseInt(_0x4dfe77[0x2],0xa),_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x1284')]=_0x2e3ca0()['isEmpty'](_0x4dfe77[0x3])?_0x4dfe77[0x3]:isNaN(_0x4dfe77[0x3])?_0x4dfe77[0x3]:parseInt(_0x4dfe77[0x3],0xa);}break;}else{}_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0xcf0')]&&_0x48b4bb[_0x1d0f09('0x4fe')]['type'][_0x1d0f09('0x93a')]()===_0x1d0f09('0x17cd')&&_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x11f3')][_0x1d0f09('0x93a')]()===_0x1d0f09('0x659')&&(_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x24fa')]=_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0xd31')]?_0x48b4bb[_0x1d0f09('0x4fe')]['phone'][_0x1d0f09('0x1fc5')]('$')[0x0]:undefined,_0x48b4bb['externaldial'][_0x1d0f09('0xabd')]=_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x73c')]?_0x1d0f09('0xac1')+_0x48b4bb[_0x1d0f09('0x4fe')][_0x1d0f09('0x73c')]:undefined);_0x48b4bb[_0x1d0f09('0x79b')]=_0x15b2b9,_0x48b4bb[_0x1d0f09('0xf82')]=_0x16daaa,_0x27ca0e['hasRole'](_0x1d0f09('0x20c2'))?_0x1740e0[_0x1d0f09('0x1a93')][_0x1d0f09('0x1e6e')]({'fields':'id,name','sort':'name','nolimit':'true'})['$promise'][_0x1d0f09('0x683')](function(_0x15f19b){const _0x2e0458=_0x1d0f09;_0x48b4bb['trunks']=_0x15f19b[_0x2e0458('0xf5d')]||[];})[_0x1d0f09('0x130a')](function(_0x30db0f){const _0x5cb23d=_0x1d0f09;_0x5e5374[_0x5cb23d('0x52a')]({'title':_0x30db0f[_0x5cb23d('0x13ee')]?'API:'+_0x30db0f['status']+_0x5cb23d('0xbf6')+_0x30db0f[_0x5cb23d('0x24a9')]:_0x5cb23d('0xfd0'),'msg':_0x30db0f[_0x5cb23d('0x5a5')]?JSON[_0x5cb23d('0x258a')](_0x30db0f[_0x5cb23d('0x5a5')]):_0x30db0f['toString']()});}):_0x1740e0[_0x1d0f09('0x1a93')][_0x1d0f09('0x1e6e')]({'fields':_0x1d0f09('0xa10'),'sort':_0x1d0f09('0x60a'),'nolimit':'true'})[_0x1d0f09('0xe53')]['then'](function(_0x4a7f4f){const _0x457dab=_0x1d0f09;_0x48b4bb[_0x457dab('0x20fe')]=_0x4a7f4f[_0x457dab('0xf5d')]||[];})['then'](function(){const _0x45c1bf=_0x1d0f09;return _0x1740e0[_0x45c1bf('0x22df')][_0x45c1bf('0x1e6e')]({'userProfileId':_0x48b4bb[_0x45c1bf('0x11ed')][_0x45c1bf('0x2f')],'sectionId':0x3f3})[_0x45c1bf('0xe53')];})[_0x1d0f09('0x683')](function(_0x55d616){const _0x599c5e=_0x1d0f09,_0x4783ed=_0x55d616&&_0x55d616[_0x599c5e('0xf5d')]?_0x55d616['rows'][0x0]:null;if(!_0x4783ed){const _0x4717df=[];let _0x3e6d5a=null;_0x48b4bb[_0x599c5e('0x4fe')]&&(_0x3e6d5a=_0x2e3ca0()[_0x599c5e('0x1c07')](_0x48b4bb[_0x599c5e('0x20fe')],{'name':_0x48b4bb[_0x599c5e('0x4fe')][_0x599c5e('0x1a93')]}));for(let _0xf6f7c8=0x0;_0xf6f7c8<_0x48b4bb['trunks'][_0x599c5e('0x1564')];_0xf6f7c8++){_0x3e6d5a&&_0x48b4bb['trunks'][_0xf6f7c8]['id']===_0x3e6d5a['id']&&(_0x48b4bb[_0x599c5e('0x20fe')][_0xf6f7c8][_0x599c5e('0x319')]=![],_0x4717df['push'](_0x48b4bb['trunks'][_0xf6f7c8]));}_0x48b4bb[_0x599c5e('0x20fe')]=_0x4717df;}else{if(!_0x4783ed[_0x599c5e('0x170')])return _0x1740e0[_0x599c5e('0xcf7')][_0x599c5e('0x1e6e')]({'sectionId':_0x4783ed['id']})[_0x599c5e('0xe53')][_0x599c5e('0x683')](function(_0x4ae70d){const _0x37c44a=_0x599c5e,_0x2c0112=_0x2e3ca0()[_0x37c44a('0x386')](_0x4ae70d[_0x37c44a('0xf5d')],function(_0x48ed37){const _0x5ec37a=_0x37c44a;return _0x2e3ca0()[_0x5ec37a('0x1c07')](_0x48b4bb['trunks'],{'id':_0x48ed37['resourceId']});});let _0x46bfa3=null;_0x48b4bb['externaldial']&&(_0x46bfa3=_0x2e3ca0()['find'](_0x48b4bb['trunks'],{'name':_0x48b4bb['externaldial'][_0x37c44a('0x1a93')]}));if(_0x46bfa3&&!_0x2e3ca0()['some'](_0x2c0112,['id',_0x46bfa3['id']])){const _0x3ead4d=_0x2e3ca0()[_0x37c44a('0x1c07')](_0x48b4bb['trunks'],{'id':_0x46bfa3['id']});_0x3ead4d[_0x37c44a('0x319')]=![],_0x2c0112[_0x37c44a('0x1fd0')](_0x3ead4d);}_0x48b4bb[_0x37c44a('0x20fe')]=_0x2c0112;});}})['catch'](function(_0x1445c8){const _0x4248dc=_0x1d0f09;_0x5e5374[_0x4248dc('0x52a')]({'title':_0x1445c8['status']?_0x4248dc('0x2168')+_0x1445c8[_0x4248dc('0x13ee')]+_0x4248dc('0xbf6')+_0x1445c8['statusText']:_0x4248dc('0x93'),'msg':_0x1445c8[_0x4248dc('0x5a5')]?JSON['stringify'](_0x1445c8[_0x4248dc('0x5a5')]):_0x1445c8[_0x4248dc('0x1ff0')]()});});function _0x15b2b9(){const _0x36d34b=_0x1d0f09;_0x48b4bb[_0x36d34b('0x17f')]=[];const _0x2dd583=[];_0x48b4bb[_0x36d34b('0x4fe')]['type']&&_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0xcf0')]['toLowerCase']()===_0x36d34b('0x17cd')&&_0x48b4bb['externaldial'][_0x36d34b('0x11f3')]===_0x36d34b('0x4d2')&&(_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0xd31')]=_0x584ce5['cutdigits']?(_0x48b4bb['externaldial']['prefix']||'')+_0x36d34b('0x249e')+_0x584ce5[_0x36d34b('0x145a')]+'}':(_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x24fa')]||'')+_0x36d34b('0x20cb'),_0x584ce5[_0x36d34b('0x75b')]!=='none'?_0x48b4bb[_0x36d34b('0x4fe')]['options']['indexOf'](_0x36d34b('0x1b1'))<0x0&&(_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x158e')]+=_0x36d34b('0x1b1')):_0x48b4bb['externaldial']['options']=_0x48b4bb[_0x36d34b('0x4fe')]['options'][_0x36d34b('0x1725')]('U(xcally-mixmonitor-context)',''));if(_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x11f3')]&&_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x11f3')]===_0x36d34b('0xbf0')){}else switch((_0x48b4bb[_0x36d34b('0x4fe')]['app']||_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x11f3')])[_0x36d34b('0x93a')]()){case _0x36d34b('0x877'):_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x1407')]=_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x60a')]+'='+_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x1c6b')];break;case'custom':break;default:_0x2dd583[0x0]=['SIP',_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x1a93')],_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0xd31')]][_0x36d34b('0x1630')]('/'),_0x2dd583[0x1]=_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x1668')],_0x2dd583[0x2]=_0x48b4bb[_0x36d34b('0x4fe')]['options'],_0x2dd583[0x3]=_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x1284')],_0x48b4bb[_0x36d34b('0x4fe')][_0x36d34b('0x1407')]=_0x2dd583['join'](',');}_0x16daaa(_0x48b4bb[_0x36d34b('0x4fe')]);}function _0x16daaa(_0x25d16c){_0x4532d2['hide'](_0x25d16c);}}const _0x242bc7=_0x4580bb;_0x2d3f91[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0xd15'),_0x189033('0xc'),'api',_0x189033('0xba1'),'crudPermissions'];function _0x2d3f91(_0x1ef369,_0x474685,_0x25940a,_0x5c97e3,_0x3b016f,_0x351d52,_0x16e37c,_0x409094){const _0x344feb=_0x189033,_0x2fec38=this;_0x2fec38['currentUser']=_0x16e37c['getCurrentUser'](),_0x2fec38[_0x344feb('0x17f')]=[],_0x2fec38[_0x344feb('0xf28')]=_0x344feb('0x241c')+(_0x5c97e3[_0x344feb('0x11f3')]||_0x5c97e3[_0x344feb('0x1d75')])[_0x344feb('0x80')](),_0x2fec38[_0x344feb('0x27fe')]=angular[_0x344feb('0x1a86')](_0x5c97e3),_0x2fec38[_0x344feb('0x1134')]=_0x409094,_0x2fec38['hasModulePermissions']={};if(_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1407')])switch(_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x11f3')]?_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x11f3')][_0x344feb('0x93a')]():_0x2fec38[_0x344feb('0x27fe')]['app']['toLowerCase']()){case'custom':break;case'dialogflow':{const _0x53730c=_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1407')][_0x344feb('0x1fc5')](',');_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1d46')]=_0x53730c[0x0],_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1a1c')]=_0x53730c[0x1],_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x6d9')]=_0x53730c[_0x344feb('0x12c8')](0x2,_0x53730c[_0x344feb('0x1564')])[_0x344feb('0x1630')](',');}break;case'dialogflowv2':{const _0x4e1800=_0x2fec38['goto'][_0x344feb('0x1407')][_0x344feb('0x1fc5')](',');_0x2fec38[_0x344feb('0x27fe')]['projectId']=_0x4e1800[0x0],_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x38')]=_0x4e1800[0x1],_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x406')]=_0x4e1800[0x2],_0x2fec38['goto'][_0x344feb('0x1a1c')]=_0x4e1800[0x3],_0x2fec38['goto'][_0x344feb('0x6d9')]=_0x4e1800[_0x344feb('0x12c8')](0x4,_0x4e1800[_0x344feb('0x1564')])[_0x344feb('0x1630')](',');}break;case'amazonlex':{const _0x23c74d=_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1407')][_0x344feb('0x1fc5')](',');_0x2fec38[_0x344feb('0x27fe')]['accesskeyid']=_0x23c74d[0x0],_0x2fec38['goto'][_0x344feb('0x204a')]=_0x23c74d[0x1],_0x2fec38['goto'][_0x344feb('0x5ba')]=_0x23c74d[0x2],_0x2fec38['goto'][_0x344feb('0x11a9')]=_0x23c74d[0x3],_0x2fec38[_0x344feb('0x27fe')]['welcomemessage']=_0x23c74d[_0x344feb('0x12c8')](0x4,_0x23c74d[_0x344feb('0x1564')])['join'](',');}break;case _0x344feb('0x2408'):{const _0x1df3e6=_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1407')]['split'](',');_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x35')]=isNaN(_0x1df3e6[0x0])?_0x1df3e6[0x0]:parseInt(_0x1df3e6[0x0],0xa),_0x2fec38[_0x344feb('0x27fe')]['text']=_0x1df3e6[_0x344feb('0x12c8')](0x1,_0x1df3e6['length'])[_0x344feb('0x1630')](',');}break;case _0x344feb('0x8c2'):_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1bcd')]=_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1407')];break;case _0x344feb('0x877'):_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x60a')]=_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1407')][_0x344feb('0x1fc5')]('=')[0x0],_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x1c6b')]=_0x2fec38[_0x344feb('0x27fe')]['appdata'][_0x344feb('0x1fc5')]('=')[0x1];break;case _0x344feb('0x19ae'):_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x273a')]=_0x2fec38[_0x344feb('0x27fe')]['appdata'];break;default:{const _0x7a3312=_0x2fec38['goto'][_0x344feb('0x1407')]['split'](',');_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x22d3')]=_0x2e3ca0()['isEmpty'](_0x7a3312[0x0])?_0x7a3312[0x0]:isNaN(_0x7a3312[0x0])?_0x7a3312[0x0]:parseInt(_0x7a3312[0x0],0xa),_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0xa65')]=_0x2e3ca0()[_0x344feb('0x173f')](_0x7a3312[0x1])?_0x7a3312[0x1]:isNaN(_0x7a3312[0x1])?_0x7a3312[0x1]:parseInt(_0x7a3312[0x1],0xa),_0x2fec38['goto'][_0x344feb('0xe1e')]=_0x2e3ca0()['isEmpty'](_0x7a3312[0x2])?_0x7a3312[0x2]:isNaN(_0x7a3312[0x2])?_0x7a3312[0x2]:parseInt(_0x7a3312[0x2],0xa);}break;}else{}_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0xcf0')]&&_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0xcf0')]['toLowerCase']()===_0x344feb('0x17cd')&&_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x11f3')][_0x344feb('0x93a')]()===_0x344feb('0x659')&&(_0x2fec38[_0x344feb('0x27fe')]['prefix']=_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0xd31')]?_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0xd31')][_0x344feb('0x1fc5')]('$')[0x0]:undefined,_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0xabd')]=_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x73c')]?_0x344feb('0xac1')+_0x2fec38[_0x344feb('0x27fe')][_0x344feb('0x73c')]:undefined);_0x2fec38[_0x344feb('0x79b')]=_0x3baeff,_0x2fec38[_0x344feb('0xf82')]=_0x5e0f81,_0x16e37c[_0x344feb('0xca1')](_0x344feb('0x20c2'))?_0x351d52[_0x344feb('0x1e4d')][_0x344feb('0x1e6e')]({'fields':_0x344feb('0xa10'),'sort':_0x344feb('0x60a'),'nolimit':'true'})['$promise'][_0x344feb('0x683')](function(_0x4e9282){_0x2fec38['contexts']=_0x4e9282['rows']||[];})[_0x344feb('0x130a')](function(_0x31eb0d){const _0xe98b1f=_0x344feb;_0x25940a['error']({'title':_0x31eb0d[_0xe98b1f('0x13ee')]?'API:'+_0x31eb0d[_0xe98b1f('0x13ee')]+'\x20-\x20'+_0x31eb0d[_0xe98b1f('0x24a9')]:_0xe98b1f('0x1379'),'msg':_0x31eb0d[_0xe98b1f('0x5a5')]?JSON[_0xe98b1f('0x258a')](_0x31eb0d[_0xe98b1f('0x5a5')]):_0x31eb0d[_0xe98b1f('0x1ff0')]()});}):_0x351d52[_0x344feb('0x1e4d')][_0x344feb('0x1e6e')]({'fields':_0x344feb('0xa10'),'sort':_0x344feb('0x60a'),'nolimit':'true'})[_0x344feb('0xe53')][_0x344feb('0x683')](function(_0x299721){_0x2fec38['contexts']=_0x299721['rows']||[];})['then'](function(){const _0x257abe=_0x344feb;return _0x351d52[_0x257abe('0x22df')][_0x257abe('0x1e6e')]({'userProfileId':_0x2fec38['currentUser'][_0x257abe('0x2f')],'sectionId':0x195})['$promise'];})[_0x344feb('0x683')](function(_0x87b57d){const _0x377588=_0x344feb,_0x2e1d7b=_0x87b57d&&_0x87b57d[_0x377588('0xf5d')]?_0x87b57d[_0x377588('0xf5d')][0x0]:null;if(!_0x2e1d7b)return _0x351d52['voiceContext'][_0x377588('0x1e6e')]({'fields':_0x377588('0xa10'),'sort':'name','nolimit':_0x377588('0x26ac'),'defaultEntry':0x1})[_0x377588('0xe53')]['then'](function(_0x3fd720){_0x2fec38['contexts']=_0x3fd720['rows']||[];});else{if(!_0x2e1d7b[_0x377588('0x170')])return _0x351d52[_0x377588('0xcf7')][_0x377588('0x1e6e')]({'sectionId':_0x2e1d7b['id']})[_0x377588('0xe53')]['then'](function(_0x57e0f0){const _0x27eb24=_0x377588,_0x3b905a=_0x2e3ca0()[_0x27eb24('0x386')](_0x57e0f0[_0x27eb24('0xf5d')],function(_0x199072){const _0x26e32a=_0x27eb24;return _0x2e3ca0()[_0x26e32a('0x1c07')](_0x2fec38['contexts'],{'id':_0x199072[_0x26e32a('0x832')]});});let _0x24b105=null;_0x2fec38['goto']&&(_0x24b105=_0x2e3ca0()[_0x27eb24('0x1c07')](_0x2fec38[_0x27eb24('0x1693')],{'name':_0x2fec38[_0x27eb24('0x27fe')][_0x27eb24('0x22d3')]}));if(_0x24b105&&!_0x2e3ca0()['some'](_0x3b905a,['id',_0x24b105['id']])){const _0xdec7e9=_0x2e3ca0()[_0x27eb24('0x1c07')](_0x2fec38[_0x27eb24('0x1693')],{'id':_0x24b105['id']});_0xdec7e9[_0x27eb24('0x319')]=![],_0x3b905a[_0x27eb24('0x1fd0')](_0xdec7e9);}_0x2fec38[_0x27eb24('0x1693')]=_0x3b905a;});}})['catch'](function(_0x16961e){const _0x5e5c26=_0x344feb;_0x25940a[_0x5e5c26('0x52a')]({'title':_0x16961e[_0x5e5c26('0x13ee')]?'API:'+_0x16961e['status']+'\x20-\x20'+_0x16961e['statusText']:_0x5e5c26('0x1a60'),'msg':_0x16961e[_0x5e5c26('0x5a5')]?JSON[_0x5e5c26('0x258a')](_0x16961e[_0x5e5c26('0x5a5')]):_0x16961e[_0x5e5c26('0x1ff0')]()});});function _0x3baeff(){const _0x3b4410=_0x344feb;_0x2fec38[_0x3b4410('0x17f')]=[];const _0x950fbd=[];_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0xcf0')]&&_0x2fec38[_0x3b4410('0x27fe')]['type'][_0x3b4410('0x93a')]()===_0x3b4410('0x17cd')&&_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x11f3')]===_0x3b4410('0x4d2')&&(_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0xd31')]=_0x3b016f[_0x3b4410('0x145a')]?(_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x24fa')]||'')+_0x3b4410('0x249e')+_0x3b016f['cutdigits']+'}':(_0x2fec38['goto'][_0x3b4410('0x24fa')]||'')+_0x3b4410('0x20cb'),_0x3b016f[_0x3b4410('0x75b')]!==_0x3b4410('0x925')?_0x2fec38['goto']['options'][_0x3b4410('0x824')](_0x3b4410('0x1b1'))<0x0&&(_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x158e')]+=_0x3b4410('0x1b1')):_0x2fec38['goto'][_0x3b4410('0x158e')]=_0x2fec38['goto'][_0x3b4410('0x158e')]['replace'](_0x3b4410('0x1b1'),''));if(_0x2fec38['goto'][_0x3b4410('0x11f3')]&&_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x11f3')]===_0x3b4410('0xbf0')){}else switch((_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x1d75')]||_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x11f3')])['toLowerCase']()){case'set':_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x1407')]=_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x60a')]+'='+_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x1c6b')];break;case'custom':break;default:_0x950fbd[0x0]=_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x22d3')],_0x950fbd[0x1]=_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0xa65')],_0x950fbd[0x2]=_0x2fec38[_0x3b4410('0x27fe')]['priority'],_0x2fec38[_0x3b4410('0x27fe')][_0x3b4410('0x1407')]=_0x950fbd['join'](',');}_0x5e0f81(_0x2fec38['goto']);}function _0x5e0f81(_0x4d5111){const _0x139199=_0x344feb;_0x1ef369[_0x139199('0x1715')](_0x4d5111);}}const _0x588315=_0x2d3f91;_0x5b46d8[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0xd15'),'internalroute','api','Auth','crudPermissions'];function _0x5b46d8(_0x37478b,_0x42a16a,_0x156b76,_0x5bbfed,_0x2b877f,_0x3903ef,_0x47f6dc,_0x53634d){const _0xf81a0f=_0x189033,_0x3e7e57=this;_0x3e7e57[_0xf81a0f('0x11ed')]=_0x47f6dc['getCurrentUser'](),_0x3e7e57[_0xf81a0f('0x17f')]=[],_0x3e7e57['title']='VOICE.EDIT_'+(_0x5bbfed[_0xf81a0f('0x11f3')]||_0x5bbfed['app'])[_0xf81a0f('0x80')](),_0x3e7e57[_0xf81a0f('0x1ba9')]=angular[_0xf81a0f('0x1a86')](_0x5bbfed),_0x3e7e57[_0xf81a0f('0x1134')]=_0x53634d,_0x3e7e57[_0xf81a0f('0x258d')]={};if(_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1407')])switch(_0x3e7e57['hangup'][_0xf81a0f('0x11f3')]?_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x11f3')][_0xf81a0f('0x93a')]():_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1d75')]['toLowerCase']()){case _0xf81a0f('0xbf0'):break;case _0xf81a0f('0x205c'):{const _0x15176f=_0x3e7e57['hangup'][_0xf81a0f('0x1407')]['split'](',');_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1d46')]=_0x15176f[0x0],_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1a1c')]=_0x15176f[0x1],_0x3e7e57[_0xf81a0f('0x1ba9')]['welcomemessage']=_0x15176f['slice'](0x2,_0x15176f[_0xf81a0f('0x1564')])['join'](',');}break;case'dialogflowv2':{const _0x2a4d4a=_0x3e7e57[_0xf81a0f('0x1ba9')]['appdata'][_0xf81a0f('0x1fc5')](',');_0x3e7e57[_0xf81a0f('0x1ba9')]['projectId']=_0x2a4d4a[0x0],_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x38')]=_0x2a4d4a[0x1],_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x406')]=_0x2a4d4a[0x2],_0x3e7e57['hangup'][_0xf81a0f('0x1a1c')]=_0x2a4d4a[0x3],_0x3e7e57['hangup'][_0xf81a0f('0x6d9')]=_0x2a4d4a[_0xf81a0f('0x12c8')](0x4,_0x2a4d4a[_0xf81a0f('0x1564')])[_0xf81a0f('0x1630')](',');}break;case'amazonlex':{const _0x4bc244=_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1407')]['split'](',');_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x7ae')]=_0x4bc244[0x0],_0x3e7e57[_0xf81a0f('0x1ba9')]['secretaccesskey']=_0x4bc244[0x1],_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x5ba')]=_0x4bc244[0x2],_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x11a9')]=_0x4bc244[0x3],_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x6d9')]=_0x4bc244[_0xf81a0f('0x12c8')](0x4,_0x4bc244[_0xf81a0f('0x1564')])[_0xf81a0f('0x1630')](',');}break;case _0xf81a0f('0x2408'):{const _0x3f40d4=_0x3e7e57[_0xf81a0f('0x1ba9')]['appdata'][_0xf81a0f('0x1fc5')](',');_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x35')]=isNaN(_0x3f40d4[0x0])?_0x3f40d4[0x0]:parseInt(_0x3f40d4[0x0],0xa),_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1bcd')]=_0x3f40d4['slice'](0x1,_0x3f40d4['length'])['join'](',');}break;case _0xf81a0f('0x8c2'):_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1bcd')]=_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1407')];break;case _0xf81a0f('0x877'):_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x60a')]=_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1407')]['split']('=')[0x0],_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1c6b')]=_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1407')][_0xf81a0f('0x1fc5')]('=')[0x1];break;case'agi':_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x273a')]=_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1407')];break;default:{const _0x4c5862=_0x3e7e57['hangup'][_0xf81a0f('0x1407')]['split'](',');_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0x1407')]=_0x2e3ca0()[_0xf81a0f('0x173f')](_0x4c5862[0x0])?_0x4c5862[0x0]:isNaN(_0x4c5862[0x0])?_0x4c5862[0x0]:parseInt(_0x4c5862[0x0],0xa);}break;}else{}_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0xcf0')]&&_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0xcf0')][_0xf81a0f('0x93a')]()===_0xf81a0f('0x17cd')&&_0x3e7e57['hangup']['appType'][_0xf81a0f('0x93a')]()===_0xf81a0f('0x659')&&(_0x3e7e57[_0xf81a0f('0x1ba9')]['prefix']=_0x3e7e57[_0xf81a0f('0x1ba9')][_0xf81a0f('0xd31')]?_0x3e7e57['hangup'][_0xf81a0f('0xd31')]['split']('$')[0x0]:undefined,_0x3e7e57['hangup'][_0xf81a0f('0xabd')]=_0x3e7e57[_0xf81a0f('0x1ba9')]['callerID']?_0xf81a0f('0xac1')+_0x3e7e57[_0xf81a0f('0x1ba9')]['callerID']:undefined);_0x3e7e57['saveInternalRouteApp']=_0x36224c,_0x3e7e57[_0xf81a0f('0xf82')]=_0x19e4da;function _0x36224c(){const _0x411637=_0xf81a0f;_0x3e7e57[_0x411637('0x17f')]=[];const _0x20f715=[];_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0xcf0')]&&_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0xcf0')][_0x411637('0x93a')]()===_0x411637('0x17cd')&&_0x3e7e57[_0x411637('0x1ba9')]['appType']===_0x411637('0x4d2')&&(_0x3e7e57[_0x411637('0x1ba9')]['phone']=_0x2b877f['cutdigits']?(_0x3e7e57[_0x411637('0x1ba9')]['prefix']||'')+_0x411637('0x249e')+_0x2b877f['cutdigits']+'}':(_0x3e7e57['hangup'][_0x411637('0x24fa')]||'')+'${EXTEN}',_0x2b877f['recordingFormat']!==_0x411637('0x925')?_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0x158e')][_0x411637('0x824')](_0x411637('0x1b1'))<0x0&&(_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0x158e')]+=_0x411637('0x1b1')):_0x3e7e57['hangup'][_0x411637('0x158e')]=_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0x158e')][_0x411637('0x1725')]('U(xcally-mixmonitor-context)',''));if(_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0x11f3')]&&_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0x11f3')]===_0x411637('0xbf0')){}else switch((_0x3e7e57[_0x411637('0x1ba9')]['app']||_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0x11f3')])[_0x411637('0x93a')]()){case _0x411637('0x877'):_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0x1407')]=_0x3e7e57[_0x411637('0x1ba9')][_0x411637('0x60a')]+'='+_0x3e7e57['hangup'][_0x411637('0x1c6b')];break;case _0x411637('0xbf0'):break;default:_0x20f715[0x0]=_0x3e7e57['hangup'][_0x411637('0x1407')],_0x3e7e57[_0x411637('0x1ba9')]['appdata']=_0x20f715[_0x411637('0x1630')](',');}_0x19e4da(_0x3e7e57[_0x411637('0x1ba9')]);}function _0x19e4da(_0x426666){const _0x180a8f=_0xf81a0f;_0x37478b[_0x180a8f('0x1715')](_0x426666);}}const _0xea4c5f=_0x5b46d8;_0x1f9fb6[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0xd15'),_0x189033('0xc'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x1f9fb6(_0x46319d,_0x55a95a,_0x5eefae,_0x221724,_0x5bc14b,_0x579776,_0x34ee0a,_0x39b6b8){const _0x906205=_0x189033,_0x17e7bf=this;_0x17e7bf[_0x906205('0x11ed')]=_0x34ee0a['getCurrentUser'](),_0x17e7bf[_0x906205('0x17f')]=[],_0x17e7bf['title']=_0x906205('0x241c')+(_0x221724[_0x906205('0x11f3')]||_0x221724['app'])['toUpperCase'](),_0x17e7bf['internaldial']=angular[_0x906205('0x1a86')](_0x221724),_0x17e7bf['crudPermissions']=_0x39b6b8,_0x17e7bf[_0x906205('0x258d')]={};if(_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1407')])switch(_0x17e7bf['internaldial'][_0x906205('0x11f3')]?_0x17e7bf[_0x906205('0x2183')][_0x906205('0x11f3')][_0x906205('0x93a')]():_0x17e7bf['internaldial']['app']['toLowerCase']()){case _0x906205('0xbf0'):break;case _0x906205('0x205c'):{const _0x73c974=_0x17e7bf['internaldial']['appdata'][_0x906205('0x1fc5')](',');_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1d46')]=_0x73c974[0x0],_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1a1c')]=_0x73c974[0x1],_0x17e7bf['internaldial']['welcomemessage']=_0x73c974[_0x906205('0x12c8')](0x2,_0x73c974['length'])['join'](',');}break;case _0x906205('0xd24'):{const _0x1cbbf1=_0x17e7bf['internaldial'][_0x906205('0x1407')]['split'](',');_0x17e7bf['internaldial'][_0x906205('0x2119')]=_0x1cbbf1[0x0],_0x17e7bf[_0x906205('0x2183')]['clientEmail']=_0x1cbbf1[0x1],_0x17e7bf[_0x906205('0x2183')]['privateKey']=_0x1cbbf1[0x2],_0x17e7bf['internaldial']['language']=_0x1cbbf1[0x3],_0x17e7bf['internaldial'][_0x906205('0x6d9')]=_0x1cbbf1[_0x906205('0x12c8')](0x4,_0x1cbbf1[_0x906205('0x1564')])[_0x906205('0x1630')](',');}break;case _0x906205('0x1db1'):{const _0x5af3dc=_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1407')][_0x906205('0x1fc5')](',');_0x17e7bf[_0x906205('0x2183')]['accesskeyid']=_0x5af3dc[0x0],_0x17e7bf[_0x906205('0x2183')][_0x906205('0x204a')]=_0x5af3dc[0x1],_0x17e7bf[_0x906205('0x2183')][_0x906205('0x5ba')]=_0x5af3dc[0x2],_0x17e7bf[_0x906205('0x2183')][_0x906205('0x11a9')]=_0x5af3dc[0x3],_0x17e7bf[_0x906205('0x2183')][_0x906205('0x6d9')]=_0x5af3dc[_0x906205('0x12c8')](0x4,_0x5af3dc['length'])[_0x906205('0x1630')](',');}break;case _0x906205('0x2408'):{const _0x2dad6a=_0x17e7bf[_0x906205('0x2183')]['appdata'][_0x906205('0x1fc5')](',');_0x17e7bf[_0x906205('0x2183')]['times']=isNaN(_0x2dad6a[0x0])?_0x2dad6a[0x0]:parseInt(_0x2dad6a[0x0],0xa),_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1bcd')]=_0x2dad6a['slice'](0x1,_0x2dad6a[_0x906205('0x1564')])[_0x906205('0x1630')](',');}break;case'message':_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1bcd')]=_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1407')];break;case _0x906205('0x877'):_0x17e7bf['internaldial'][_0x906205('0x60a')]=_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1407')]['split']('=')[0x0],_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1c6b')]=_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1407')][_0x906205('0x1fc5')]('=')[0x1];break;case _0x906205('0x19ae'):_0x17e7bf['internaldial']['project']=_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1407')];break;default:{const _0x39cc7e=_0x17e7bf['internaldial']['appdata'][_0x906205('0x1fc5')](',');_0x17e7bf[_0x906205('0x2183')]['user']=_0x2e3ca0()[_0x906205('0x173f')](_0x39cc7e[0x0])?_0x39cc7e[0x0]:isNaN(_0x39cc7e[0x0])?_0x39cc7e[0x0]:parseInt(_0x39cc7e[0x0],0xa),_0x17e7bf[_0x906205('0x2183')][_0x906205('0x1668')]=_0x2e3ca0()['isEmpty'](_0x39cc7e[0x1])?_0x39cc7e[0x1]:isNaN(_0x39cc7e[0x1])?_0x39cc7e[0x1]:parseInt(_0x39cc7e[0x1],0xa),_0x17e7bf[_0x906205('0x2183')][_0x906205('0x158e')]=_0x2e3ca0()[_0x906205('0x173f')](_0x39cc7e[0x2])?_0x39cc7e[0x2]:isNaN(_0x39cc7e[0x2])?_0x39cc7e[0x2]:parseInt(_0x39cc7e[0x2],0xa),_0x17e7bf[_0x906205('0x2183')]['url']=_0x2e3ca0()[_0x906205('0x173f')](_0x39cc7e[0x3])?_0x39cc7e[0x3]:isNaN(_0x39cc7e[0x3])?_0x39cc7e[0x3]:parseInt(_0x39cc7e[0x3],0xa);}break;}else{}_0x17e7bf[_0x906205('0x2183')]['type']&&_0x17e7bf[_0x906205('0x2183')][_0x906205('0xcf0')][_0x906205('0x93a')]()===_0x906205('0x17cd')&&_0x17e7bf[_0x906205('0x2183')][_0x906205('0x11f3')][_0x906205('0x93a')]()===_0x906205('0x659')&&(_0x17e7bf[_0x906205('0x2183')][_0x906205('0x24fa')]=_0x17e7bf[_0x906205('0x2183')][_0x906205('0xd31')]?_0x17e7bf[_0x906205('0x2183')][_0x906205('0xd31')][_0x906205('0x1fc5')]('$')[0x0]:undefined,_0x17e7bf[_0x906205('0x2183')][_0x906205('0xabd')]=_0x17e7bf[_0x906205('0x2183')][_0x906205('0x73c')]?'CALLERID(all)='+_0x17e7bf['internaldial'][_0x906205('0x73c')]:undefined);_0x17e7bf['saveInternalRouteApp']=_0x4ebeb6,_0x17e7bf['closeDialog']=_0xba8347;const _0x529f36=[{'id':0xca,'role':_0x906205('0x2327')},{'id':0xcb,'role':_0x906205('0x24d3')}];let _0xce1483=null;_0x34ee0a[_0x906205('0xca1')]('admin')?_0x579776[_0x906205('0xc96')]['get']({'fields':_0x906205('0xac9'),'sort':_0x906205('0x60a'),'nolimit':_0x906205('0x26ac')})[_0x906205('0xe53')][_0x906205('0x683')](function(_0x4a1c79){const _0x44ccbb=_0x906205;_0x17e7bf[_0x44ccbb('0x3bf')]=_0x4a1c79[_0x44ccbb('0xf5d')]||[];})[_0x906205('0x130a')](function(_0x41bd62){const _0x230a14=_0x906205;_0x5eefae[_0x230a14('0x52a')]({'title':_0x41bd62['status']?_0x230a14('0x2168')+_0x41bd62[_0x230a14('0x13ee')]+'\x20-\x20'+_0x41bd62['statusText']:_0x230a14('0x8eb'),'msg':_0x41bd62[_0x230a14('0x5a5')]?JSON['stringify'](_0x41bd62[_0x230a14('0x5a5')]):_0x41bd62['toString']()});}):_0x579776[_0x906205('0xc96')][_0x906205('0x1e6e')]({'fields':_0x906205('0xac9'),'sort':_0x906205('0x60a'),'nolimit':_0x906205('0x26ac')})[_0x906205('0xe53')]['then'](function(_0x29b4d5){_0xce1483=_0x29b4d5['rows']||[];})['then'](function(){const _0xafcaa8=_0x906205,_0x3d1292=[];for(let _0x406236=0x0;_0x406236<_0x529f36[_0xafcaa8('0x1564')];_0x406236++){_0x3d1292[_0xafcaa8('0x1fd0')](_0x579776[_0xafcaa8('0x22df')][_0xafcaa8('0x1e6e')]({'userProfileId':_0x17e7bf[_0xafcaa8('0x11ed')][_0xafcaa8('0x2f')],'sectionId':_0x529f36[_0x406236]['id']})[_0xafcaa8('0xe53')]);}return _0x55a95a[_0xafcaa8('0x252c')](_0x3d1292);})[_0x906205('0x683')](function(_0x177ec1){const _0x1d9967=_0x906205,_0x28a69b=_0x2e3ca0()[_0x1d9967('0x386')](_0x177ec1,function(_0x4edbe0){const _0x3a4b7b=_0x1d9967;return _0x4edbe0&&_0x4edbe0[_0x3a4b7b('0xf5d')]?_0x4edbe0[_0x3a4b7b('0xf5d')][0x0]:null;}),_0x1fba44=[];for(let _0x501cda=0x0;_0x501cda<_0x529f36[_0x1d9967('0x1564')];_0x501cda++){const _0x869b3d=_0x2e3ca0()[_0x1d9967('0x1c07')](_0x28a69b,['sectionId',_0x529f36[_0x501cda]['id']]);if(_0x869b3d){if(!_0x869b3d[_0x1d9967('0x170')])_0x1fba44[_0x1d9967('0x1fd0')](_0x579776[_0x1d9967('0xcf7')]['get']({'sectionId':_0x869b3d['id']})['$promise']);else{const _0x5699bd=[];_0xce1483[_0x1d9967('0x1299')](function(_0x39339c){const _0x590203=_0x1d9967;_0x39339c[_0x590203('0xecb')]===_0x529f36[_0x501cda]['role']&&_0x5699bd[_0x590203('0x1fd0')](_0x39339c);}),_0x1fba44['push']({'rows':_0x5699bd,'count':_0x5699bd[_0x1d9967('0x1564')]});}}}return _0x55a95a[_0x1d9967('0x252c')](_0x1fba44);})[_0x906205('0x683')](function(_0x2fafc8){const _0x1b37d0=_0x906205,_0x3aa8be=[];let _0x424b33=null;_0x17e7bf[_0x1b37d0('0x2183')]&&(_0x424b33=_0x2e3ca0()[_0x1b37d0('0x1c07')](_0xce1483,{'name':_0x17e7bf[_0x1b37d0('0x2183')][_0x1b37d0('0xc96')]}));for(let _0x4cf2e9=0x0;_0x4cf2e9<_0x2fafc8[_0x1b37d0('0x1564')];_0x4cf2e9++){const _0x4699a8=_0x2fafc8[_0x4cf2e9][_0x1b37d0('0xf5d')]||[];_0x4699a8['forEach'](function(_0x57a960){const _0x2045f6=_0x1b37d0;_0x3aa8be[_0x2045f6('0x1fd0')](_0x57a960);});}_0x424b33&&!_0x2e3ca0()[_0x1b37d0('0x7a2')](_0x3aa8be,[_0x1b37d0('0x832'),_0x424b33['id']])&&_0xce1483[_0x1b37d0('0x1299')](function(_0x5445af){const _0x1fd693=_0x1b37d0;_0x5445af['id']===_0x424b33['id']&&(_0x5445af[_0x1fd693('0x319')]=![],_0x3aa8be[_0x1fd693('0x1fd0')](_0x5445af));}),_0x17e7bf[_0x1b37d0('0x3bf')]=_0x3aa8be;})[_0x906205('0x130a')](function(_0x26421b){const _0x196534=_0x906205;_0x5eefae[_0x196534('0x52a')]({'title':_0x26421b['status']?'API:'+_0x26421b['status']+'\x20-\x20'+_0x26421b[_0x196534('0x24a9')]:_0x196534('0x1511'),'msg':_0x26421b[_0x196534('0x5a5')]?JSON[_0x196534('0x258a')](_0x26421b[_0x196534('0x5a5')]):_0x26421b[_0x196534('0x1ff0')]()});});function _0x4ebeb6(){const _0x5316b6=_0x906205;_0x17e7bf[_0x5316b6('0x17f')]=[];const _0x42ea9f=[];_0x17e7bf[_0x5316b6('0x2183')]['type']&&_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0xcf0')][_0x5316b6('0x93a')]()==='outbound'&&_0x17e7bf['internaldial'][_0x5316b6('0x11f3')]===_0x5316b6('0x4d2')&&(_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0xd31')]=_0x5bc14b[_0x5316b6('0x145a')]?(_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0x24fa')]||'')+'${EXTEN:'+_0x5bc14b[_0x5316b6('0x145a')]+'}':(_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0x24fa')]||'')+_0x5316b6('0x20cb'),_0x5bc14b['recordingFormat']!==_0x5316b6('0x925')?_0x17e7bf['internaldial'][_0x5316b6('0x158e')][_0x5316b6('0x824')](_0x5316b6('0x1b1'))<0x0&&(_0x17e7bf['internaldial'][_0x5316b6('0x158e')]+='U(xcally-mixmonitor-context)'):_0x17e7bf['internaldial']['options']=_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0x158e')][_0x5316b6('0x1725')](_0x5316b6('0x1b1'),''));if(_0x17e7bf[_0x5316b6('0x2183')]['appType']&&_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0x11f3')]===_0x5316b6('0xbf0')){}else switch((_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0x1d75')]||_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0x11f3')])['toLowerCase']()){case'set':_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0x1407')]=_0x17e7bf[_0x5316b6('0x2183')]['name']+'='+_0x17e7bf['internaldial']['value'];break;case'custom':break;default:_0x42ea9f[0x0]=_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0xc96')],_0x42ea9f[0x1]=_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0x1668')],_0x42ea9f[0x2]=_0x17e7bf[_0x5316b6('0x2183')]['options'],_0x42ea9f[0x3]=_0x17e7bf[_0x5316b6('0x2183')]['url'],_0x17e7bf[_0x5316b6('0x2183')][_0x5316b6('0x1407')]=_0x42ea9f[_0x5316b6('0x1630')](',');}_0xba8347(_0x17e7bf[_0x5316b6('0x2183')]);}function _0xba8347(_0x4058e5){const _0x3e4621=_0x906205;_0x46319d[_0x3e4621('0x1715')](_0x4058e5);}}const _0x46e69b=_0x1f9fb6;_0x2b830f[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x1e48'),'$mdToast',_0x189033('0x844'),_0x189033('0x115c'),_0x189033('0xe98'),_0x189033('0x1d70'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x2b830f(_0x3747b4,_0xb6cb47,_0x20e8c7,_0x1662df,_0x5e418,_0x366fc5,_0x599a04,_0x264589,_0x4f873f,_0x3d9bf3){const _0x5e05d8=_0x189033,_0x31a4d6=this;_0x31a4d6['currentUser']=_0x4f873f[_0x5e05d8('0x20b2')](),_0x31a4d6['errors']=[],_0x31a4d6[_0x5e05d8('0xf28')]=_0x5e05d8('0xc62'),_0x31a4d6[_0x5e05d8('0x115c')]=angular[_0x5e05d8('0x1a86')](_0x5e418),_0x31a4d6[_0x5e05d8('0xe98')]=_0x366fc5,_0x31a4d6[_0x5e05d8('0x1470')]=![],_0x31a4d6[_0x5e05d8('0x1de1')]=[_0x5e05d8('0x10af'),_0x5e05d8('0xbf0'),_0x5e05d8('0x2335')],_0x31a4d6[_0x5e05d8('0x1134')]=_0x3d9bf3,_0x31a4d6[_0x5e05d8('0x167a')]=_0x1662df['getDaysOfWeek'](),_0x31a4d6[_0x5e05d8('0x1dfd')]=_0x1662df[_0x5e05d8('0x222e')](),_0x31a4d6[_0x5e05d8('0x1e32')]=_0x1662df['getMonthName'](),_0x31a4d6['daysOfMonth']=_0x1662df[_0x5e05d8('0x181b')]();if(!_0x31a4d6[_0x5e05d8('0x115c')])_0x31a4d6[_0x5e05d8('0x115c')]={'interval':_0x5e05d8('0x1b54')},_0x31a4d6['type']=_0x5e05d8('0x10af'),_0x31a4d6[_0x5e05d8('0xf28')]=_0x5e05d8('0x1e94'),_0x31a4d6[_0x5e05d8('0x1470')]=!![];else{if(_0x31a4d6['interval'][_0x5e05d8('0x115c')]!==_0x5e05d8('0x1b54')){_0x31a4d6[_0x5e05d8('0xcf0')]='custom';const _0x1963fa=_0x31a4d6[_0x5e05d8('0x115c')][_0x5e05d8('0x115c')]['split'](','),_0x1ebc35=_0x1963fa[0x0],_0x6e5922=_0x1963fa[0x1],_0x5e9f8e=_0x1963fa[0x2],_0x4548b2=_0x1963fa[0x3];if(_0x1ebc35!=='*'){const _0x25f930=_0x1ebc35[_0x5e05d8('0x1fc5')]('-')[0x0],_0x551c8d=_0x1ebc35['split']('-')[0x1];let _0x6e6a13;_0x6e6a13=new Date(),_0x6e6a13[_0x5e05d8('0x2813')](Number(_0x25f930[_0x5e05d8('0x1fc5')](':')[0x0])),_0x6e6a13[_0x5e05d8('0x1fb7')](Number(_0x25f930[_0x5e05d8('0x1fc5')](':')[0x1])),_0x31a4d6[_0x5e05d8('0xc32')]=_0x6e6a13,_0x6e6a13=new Date(),_0x6e6a13[_0x5e05d8('0x2813')](Number(_0x551c8d[_0x5e05d8('0x1fc5')](':')[0x0])),_0x6e6a13['setMinutes'](Number(_0x551c8d['split'](':')[0x1])),_0x31a4d6[_0x5e05d8('0xaa0')]=_0x6e6a13;}_0x6e5922!=='*'&&(_0x31a4d6[_0x5e05d8('0x232d')]=_0x6e5922['split']('-')[0x0],_0x31a4d6[_0x5e05d8('0x1269')]=_0x6e5922[_0x5e05d8('0x1fc5')]('-')[0x1]),_0x5e9f8e!=='*'&&(_0x31a4d6[_0x5e05d8('0xf13')]=_0x5e9f8e[_0x5e05d8('0x1fc5')]('-')[0x0],_0x31a4d6[_0x5e05d8('0xfe5')]=_0x5e9f8e[_0x5e05d8('0x1fc5')]('-')[0x1]),_0x4548b2!=='*'&&(_0x31a4d6[_0x5e05d8('0x1690')]=_0x4548b2[_0x5e05d8('0x1fc5')]('-')[0x0],_0x31a4d6[_0x5e05d8('0x1f12')]=_0x4548b2[_0x5e05d8('0x1fc5')]('-')[0x1]);}else _0x31a4d6[_0x5e05d8('0xcf0')]=_0x5e05d8('0x10af');}_0x3747b4[_0x5e05d8('0x7f2')]['id']&&!_0x31a4d6['interval']['application']&&(_0x31a4d6[_0x5e05d8('0x115c')]['IntervalId']=_0x3747b4[_0x5e05d8('0x7f2')]['id']);_0x31a4d6[_0x5e05d8('0x115c')][_0x5e05d8('0x5ae')]&&_0x31a4d6[_0x5e05d8('0x115c')][_0x5e05d8('0x121e')]&&(_0x31a4d6[_0x5e05d8('0xcf0')]=_0x5e05d8('0x2335'));_0x31a4d6[_0x5e05d8('0x1a4d')]=_0x342662,_0x31a4d6['saveInterval']=_0x1ed909,_0x31a4d6[_0x5e05d8('0xf82')]=_0x56ea94;_0x31a4d6[_0x5e05d8('0x115c')][_0x5e05d8('0x121e')]&&(_0x4f873f['hasRole'](_0x5e05d8('0x20c2'))?_0x264589['interval'][_0x5e05d8('0x1e6e')]({'fields':'id,name,interval,IntervalId','IntervalId':'null','nolimit':!![]})[_0x5e05d8('0xe53')][_0x5e05d8('0x683')](function(_0xc9e82e){const _0xdef6d0=_0x5e05d8;_0x31a4d6['intervals']=_0xc9e82e[_0xdef6d0('0xf5d')]||[];})[_0x5e05d8('0x130a')](function(_0x310822){const _0x2bd1c9=_0x5e05d8;_0x599a04['error']({'title':_0x310822[_0x2bd1c9('0x13ee')]?'API:'+_0x310822[_0x2bd1c9('0x13ee')]+_0x2bd1c9('0xbf6')+_0x310822[_0x2bd1c9('0x24a9')]:_0x2bd1c9('0x1e65'),'msg':_0x310822['data']?JSON[_0x2bd1c9('0x258a')](_0x310822[_0x2bd1c9('0x5a5')]):_0x310822['toString']()});}):_0x264589[_0x5e05d8('0x115c')][_0x5e05d8('0x1e6e')]({'fields':_0x5e05d8('0x1e24'),'IntervalId':_0x5e05d8('0x13c'),'nolimit':!![]})['$promise'][_0x5e05d8('0x683')](function(_0x2bcb45){_0x31a4d6['intervals']=_0x2bcb45['rows']||[];})['then'](function(){const _0x52220c=_0x5e05d8;return _0x264589[_0x52220c('0x22df')][_0x52220c('0x1e6e')]({'userProfileId':_0x31a4d6[_0x52220c('0x11ed')][_0x52220c('0x2f')],'sectionId':0x3ec})[_0x52220c('0xe53')];})[_0x5e05d8('0x683')](function(_0x32ba7c){const _0x1ba688=_0x5e05d8,_0x34d61e=_0x32ba7c&&_0x32ba7c['rows']?_0x32ba7c[_0x1ba688('0xf5d')][0x0]:null;if(!_0x34d61e)_0x31a4d6[_0x1ba688('0xe98')]=[];else{if(!_0x34d61e[_0x1ba688('0x170')])return _0x264589['userProfileResource'][_0x1ba688('0x1e6e')]({'sectionId':_0x34d61e['id']})[_0x1ba688('0xe53')][_0x1ba688('0x683')](function(_0x27ecc6){const _0x16f346=_0x1ba688,_0x566c29=_0x27ecc6&&_0x27ecc6[_0x16f346('0xf5d')]?_0x27ecc6[_0x16f346('0xf5d')]:[],_0x35d4f9=[];let _0x413259=null;_0x31a4d6['interval']&&(_0x413259=_0x2e3ca0()[_0x16f346('0x1c07')](_0x31a4d6[_0x16f346('0xe98')],{'name':_0x31a4d6[_0x16f346('0x115c')][_0x16f346('0x5ae')]})),_0x413259&&!_0x2e3ca0()['some'](_0x566c29,[_0x16f346('0x832'),_0x413259['id']])&&_0x31a4d6[_0x16f346('0xe98')][_0x16f346('0x1299')](function(_0xcea7cd){const _0x3b939a=_0x16f346;_0xcea7cd['id']===_0x413259['id']&&(_0xcea7cd[_0x3b939a('0x319')]=![],_0x35d4f9[_0x3b939a('0x1fd0')](_0xcea7cd));}),_0x31a4d6['intervals']=_0x35d4f9;});}})[_0x5e05d8('0x130a')](function(_0x26a660){const _0x65dc18=_0x5e05d8;_0x599a04[_0x65dc18('0x52a')]({'title':_0x26a660[_0x65dc18('0x13ee')]?_0x65dc18('0x2168')+_0x26a660[_0x65dc18('0x13ee')]+_0x65dc18('0xbf6')+_0x26a660[_0x65dc18('0x24a9')]:_0x65dc18('0x1e65'),'msg':_0x26a660[_0x65dc18('0x5a5')]?JSON[_0x65dc18('0x258a')](_0x26a660[_0x65dc18('0x5a5')]):_0x26a660[_0x65dc18('0x1ff0')]()});}));function _0x55d77b(){const _0x50bdd5=_0x5e05d8;switch(_0x31a4d6['type']){case _0x50bdd5('0x10af'):case _0x50bdd5('0x2335'):return'*,*,*,*';case _0x50bdd5('0xbf0'):{const _0x142e13=[];if(_0x31a4d6['timeRangeFrom']!=='*'&&_0x31a4d6[_0x50bdd5('0xc32')]&&_0x31a4d6[_0x50bdd5('0xaa0')]){const _0x4f8d67=(_0x31a4d6[_0x50bdd5('0xc32')]['getHours']()<0xa?'0':'')+_0x31a4d6['timeRangeFrom'][_0x50bdd5('0x2575')]()+':'+((_0x31a4d6['timeRangeFrom'][_0x50bdd5('0x1b5b')]()<0xa?'0':'')+_0x31a4d6['timeRangeFrom']['getMinutes']()),_0x190710=(_0x31a4d6[_0x50bdd5('0xaa0')][_0x50bdd5('0x2575')]()<0xa?'0':'')+_0x31a4d6[_0x50bdd5('0xaa0')]['getHours']()+':'+((_0x31a4d6[_0x50bdd5('0xaa0')][_0x50bdd5('0x1b5b')]()<0xa?'0':'')+_0x31a4d6[_0x50bdd5('0xaa0')][_0x50bdd5('0x1b5b')]());_0x142e13[_0x50bdd5('0x1fd0')](_0x4f8d67+'-'+_0x190710);}else _0x142e13[_0x50bdd5('0x1fd0')]('*');return _0x31a4d6[_0x50bdd5('0x232d')]?_0x31a4d6['dayOfWeekTo']?_0x142e13['push'](_0x31a4d6[_0x50bdd5('0x232d')]+'-'+_0x31a4d6[_0x50bdd5('0x1269')]):_0x142e13[_0x50bdd5('0x1fd0')](_0x31a4d6[_0x50bdd5('0x232d')]):_0x142e13[_0x50bdd5('0x1fd0')]('*'),_0x31a4d6[_0x50bdd5('0xf13')]?_0x31a4d6['monthDayTo']?_0x142e13[_0x50bdd5('0x1fd0')](_0x31a4d6['monthDayFrom']+'-'+_0x31a4d6['monthDayTo']):_0x142e13[_0x50bdd5('0x1fd0')](_0x31a4d6['monthDayFrom']):_0x142e13[_0x50bdd5('0x1fd0')]('*'),_0x31a4d6[_0x50bdd5('0x1690')]?_0x31a4d6['monthTo']?_0x142e13[_0x50bdd5('0x1fd0')](_0x31a4d6['monthFrom']+'-'+_0x31a4d6['monthTo']):_0x142e13['push'](_0x31a4d6[_0x50bdd5('0x1690')]):_0x142e13[_0x50bdd5('0x1fd0')]('*'),_0x142e13['join']();}}}function _0x342662(){const _0x413e65=_0x5e05d8;_0x31a4d6['errors']=[],_0x31a4d6[_0x413e65('0x115c')][_0x413e65('0x115c')]=_0x55d77b(),_0x264589['interval'][_0x413e65('0xb0a')](_0x31a4d6[_0x413e65('0x115c')])[_0x413e65('0xe53')][_0x413e65('0x683')](function(_0x427990){const _0x3d1cf8=_0x413e65;_0x31a4d6['intervals'][_0x3d1cf8('0x1fd0')](_0x427990),_0x599a04['success']({'title':'Interval\x20properly\x20created','msg':_0x31a4d6[_0x3d1cf8('0x115c')][_0x3d1cf8('0x60a')]?_0x31a4d6[_0x3d1cf8('0x115c')]['name']+_0x3d1cf8('0x14b5'):''}),_0x56ea94();})['catch'](function(_0x3fe532){const _0x5b5674=_0x413e65;console[_0x5b5674('0x52a')](_0x3fe532),_0x31a4d6[_0x5b5674('0x17f')]=_0x3fe532[_0x5b5674('0x5a5')][_0x5b5674('0x17f')]||[{'message':_0x3fe532[_0x5b5674('0x1ff0')](),'type':_0x5b5674('0x1d24')}];});}function _0x1ed909(){const _0x224eb2=_0x5e05d8;_0x31a4d6[_0x224eb2('0x17f')]=[],_0x31a4d6[_0x224eb2('0x115c')][_0x224eb2('0x115c')]=_0x55d77b(),_0x31a4d6[_0x224eb2('0x115c')][_0x224eb2('0x121e')]?(_0x31a4d6[_0x224eb2('0xcf0')]!=='list'&&(_0x31a4d6['interval'][_0x224eb2('0x5ae')]=null),_0x56ea94(_0x31a4d6[_0x224eb2('0x115c')])):_0x264589[_0x224eb2('0x115c')][_0x224eb2('0x2480')]({'id':_0x31a4d6['interval']['id']},_0x31a4d6['interval'])['$promise']['then'](function(_0x5d1633){const _0x50c545=_0x224eb2,_0x945292=_0x2e3ca0()[_0x50c545('0x1c07')](_0x31a4d6[_0x50c545('0xe98')],{'id':_0x5d1633['id']});_0x945292&&_0x2e3ca0()[_0x50c545('0xf22')](_0x945292,_0x5d1633),_0x599a04[_0x50c545('0x53')]({'title':_0x50c545('0x18c3'),'msg':_0x50c545('0x224')}),_0x56ea94();})[_0x224eb2('0x130a')](function(_0x22d653){const _0x11a78a=_0x224eb2;console[_0x11a78a('0x52a')](_0x22d653),_0x31a4d6[_0x11a78a('0x17f')]=_0x22d653[_0x11a78a('0x5a5')][_0x11a78a('0x17f')]||[{'message':_0x22d653[_0x11a78a('0x1ff0')](),'type':_0x11a78a('0x605')}];});}function _0x56ea94(_0x11dcad){const _0x532687=_0x5e05d8;_0xb6cb47[_0x532687('0x1715')](_0x11dcad);}}const _0x327cac=_0x2b830f;_0x48c64d[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0xd15'),'internalroute',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x48c64d(_0x20c03c,_0x5404bb,_0x387512,_0x2e3e0e,_0x4a847c,_0x28a053,_0x51a669,_0x5d0f70){const _0xe75d1=_0x189033,_0x4f8d88=this;_0x4f8d88['currentUser']=_0x51a669[_0xe75d1('0x20b2')](),_0x4f8d88['errors']=[],_0x4f8d88['title']=_0xe75d1('0x241c')+(_0x2e3e0e['appType']||_0x2e3e0e[_0xe75d1('0x1d75')])[_0xe75d1('0x80')](),_0x4f8d88[_0xe75d1('0xab0')]=angular[_0xe75d1('0x1a86')](_0x2e3e0e),_0x4f8d88[_0xe75d1('0x1134')]=_0x5d0f70,_0x4f8d88['hasModulePermissions']={};if(_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1407')])switch(_0x4f8d88[_0xe75d1('0xab0')]['appType']?_0x4f8d88[_0xe75d1('0xab0')]['appType'][_0xe75d1('0x93a')]():_0x4f8d88['playback'][_0xe75d1('0x1d75')]['toLowerCase']()){case _0xe75d1('0xbf0'):break;case _0xe75d1('0x205c'):{const _0x331eb8=_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1407')]['split'](',');_0x4f8d88['playback'][_0xe75d1('0x1d46')]=_0x331eb8[0x0],_0x4f8d88[_0xe75d1('0xab0')]['language']=_0x331eb8[0x1],_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x6d9')]=_0x331eb8[_0xe75d1('0x12c8')](0x2,_0x331eb8[_0xe75d1('0x1564')])['join'](',');}break;case'dialogflowv2':{const _0x556eef=_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1407')]['split'](',');_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x2119')]=_0x556eef[0x0],_0x4f8d88['playback']['clientEmail']=_0x556eef[0x1],_0x4f8d88['playback']['privateKey']=_0x556eef[0x2],_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1a1c')]=_0x556eef[0x3],_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x6d9')]=_0x556eef[_0xe75d1('0x12c8')](0x4,_0x556eef[_0xe75d1('0x1564')])[_0xe75d1('0x1630')](',');}break;case _0xe75d1('0x1db1'):{const _0x5859a8=_0x4f8d88[_0xe75d1('0xab0')]['appdata']['split'](',');_0x4f8d88['playback'][_0xe75d1('0x7ae')]=_0x5859a8[0x0],_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x204a')]=_0x5859a8[0x1],_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x5ba')]=_0x5859a8[0x2],_0x4f8d88[_0xe75d1('0xab0')]['botname']=_0x5859a8[0x3],_0x4f8d88[_0xe75d1('0xab0')]['welcomemessage']=_0x5859a8[_0xe75d1('0x12c8')](0x4,_0x5859a8[_0xe75d1('0x1564')])['join'](',');}break;case _0xe75d1('0x2408'):{const _0x2d8b41=_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1407')]['split'](',');_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x35')]=isNaN(_0x2d8b41[0x0])?_0x2d8b41[0x0]:parseInt(_0x2d8b41[0x0],0xa),_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1bcd')]=_0x2d8b41['slice'](0x1,_0x2d8b41[_0xe75d1('0x1564')])['join'](',');}break;case _0xe75d1('0x8c2'):_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1bcd')]=_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1407')];break;case'set':_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x60a')]=_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1407')][_0xe75d1('0x1fc5')]('=')[0x0],_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1c6b')]=_0x4f8d88['playback'][_0xe75d1('0x1407')]['split']('=')[0x1];break;case'agi':_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x273a')]=_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1407')];break;default:{const _0x1060fb=_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x1407')][_0xe75d1('0x1fc5')](',');_0x4f8d88[_0xe75d1('0xab0')]['appdata']=_0x2e3ca0()[_0xe75d1('0x173f')](_0x1060fb[0x0])?_0x1060fb[0x0]:isNaN(_0x1060fb[0x0])?_0x1060fb[0x0]:parseInt(_0x1060fb[0x0],0xa),_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x158e')]=_0x2e3ca0()['isEmpty'](_0x1060fb[0x1])?_0x1060fb[0x1]:isNaN(_0x1060fb[0x1])?_0x1060fb[0x1]:parseInt(_0x1060fb[0x1],0xa);}break;}else{}_0x4f8d88['playback'][_0xe75d1('0xcf0')]&&_0x4f8d88['playback'][_0xe75d1('0xcf0')][_0xe75d1('0x93a')]()===_0xe75d1('0x17cd')&&_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0x11f3')]['toLowerCase']()===_0xe75d1('0x659')&&(_0x4f8d88[_0xe75d1('0xab0')]['prefix']=_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0xd31')]?_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0xd31')][_0xe75d1('0x1fc5')]('$')[0x0]:undefined,_0x4f8d88[_0xe75d1('0xab0')][_0xe75d1('0xabd')]=_0x4f8d88['playback'][_0xe75d1('0x73c')]?'CALLERID(all)='+_0x4f8d88[_0xe75d1('0xab0')]['callerID']:undefined);_0x4f8d88[_0xe75d1('0x79b')]=_0x1b205a,_0x4f8d88[_0xe75d1('0xf82')]=_0xb15cc0,_0x51a669['hasRole'](_0xe75d1('0x20c2'))?_0x28a053[_0xe75d1('0x1638')][_0xe75d1('0x1e6e')]({'fields':_0xe75d1('0xfa7'),'sort':_0xe75d1('0x60a'),'nolimit':_0xe75d1('0x26ac')})[_0xe75d1('0xe53')][_0xe75d1('0x683')](function(_0x275076){const _0x35fa60=_0xe75d1;_0x4f8d88[_0x35fa60('0x11d2')]=_0x275076[_0x35fa60('0xf5d')]||[];})[_0xe75d1('0x130a')](function(_0x28ec34){const _0x13a421=_0xe75d1;_0x387512[_0x13a421('0x52a')]({'title':_0x28ec34['status']?'API:'+_0x28ec34[_0x13a421('0x13ee')]+_0x13a421('0xbf6')+_0x28ec34[_0x13a421('0x24a9')]:_0x13a421('0x162a'),'msg':_0x28ec34['data']?JSON[_0x13a421('0x258a')](_0x28ec34[_0x13a421('0x5a5')]):_0x28ec34[_0x13a421('0x1ff0')]()});}):_0x28a053[_0xe75d1('0x1638')]['get']({'fields':_0xe75d1('0xfa7'),'sort':_0xe75d1('0x60a'),'nolimit':_0xe75d1('0x26ac')})[_0xe75d1('0xe53')][_0xe75d1('0x683')](function(_0x18923f){const _0x19116a=_0xe75d1;_0x4f8d88[_0x19116a('0x11d2')]=_0x18923f[_0x19116a('0xf5d')]||[];})[_0xe75d1('0x683')](function(){const _0xae1a34=_0xe75d1;return _0x28a053['userProfileSection']['get']({'userProfileId':_0x4f8d88[_0xae1a34('0x11ed')]['userProfileId'],'sectionId':0x3ef})[_0xae1a34('0xe53')];})[_0xe75d1('0x683')](function(_0x5223d0){const _0x1bc748=_0xe75d1,_0x4c8aba=_0x5223d0&&_0x5223d0[_0x1bc748('0xf5d')]?_0x5223d0[_0x1bc748('0xf5d')][0x0]:null;if(!_0x4c8aba){const _0xc5ad55=[];let _0x4c2efa=null;_0x4f8d88[_0x1bc748('0xab0')]&&(_0x4c2efa=_0x2e3ca0()[_0x1bc748('0x1c07')](_0x4f8d88[_0x1bc748('0x11d2')],{'save_name':_0x4f8d88[_0x1bc748('0xab0')]['appdata']}));for(let _0x55da08=0x0;_0x55da08<_0x4f8d88['sounds'][_0x1bc748('0x1564')];_0x55da08++){_0x4c2efa&&_0x4f8d88[_0x1bc748('0x11d2')][_0x55da08]['id']===_0x4c2efa['id']&&(_0x4f8d88['sounds'][_0x55da08][_0x1bc748('0x319')]=![],_0xc5ad55['push'](_0x4f8d88[_0x1bc748('0x11d2')][_0x55da08]));}_0x4f8d88['sounds']=_0xc5ad55;}else{if(!_0x4c8aba[_0x1bc748('0x170')])return _0x28a053[_0x1bc748('0xcf7')][_0x1bc748('0x1e6e')]({'sectionId':_0x4c8aba['id']})[_0x1bc748('0xe53')][_0x1bc748('0x683')](function(_0x402a76){const _0x1a4060=_0x1bc748,_0x3e950e=_0x2e3ca0()[_0x1a4060('0x386')](_0x402a76[_0x1a4060('0xf5d')],function(_0x11307e){const _0x1c7b3c=_0x1a4060;return _0x2e3ca0()[_0x1c7b3c('0x1c07')](_0x4f8d88[_0x1c7b3c('0x11d2')],{'id':_0x11307e['resourceId']});});let _0x24315a=null;_0x4f8d88['playback']&&(_0x24315a=_0x2e3ca0()[_0x1a4060('0x1c07')](_0x4f8d88['sounds'],{'save_name':_0x4f8d88[_0x1a4060('0xab0')][_0x1a4060('0x1407')]}));if(_0x24315a&&!_0x2e3ca0()[_0x1a4060('0x7a2')](_0x3e950e,['id',_0x24315a['id']])){const _0x11f397=_0x2e3ca0()[_0x1a4060('0x1c07')](_0x4f8d88[_0x1a4060('0x11d2')],{'id':_0x24315a['id']});_0x11f397[_0x1a4060('0x319')]=![],_0x3e950e['push'](_0x11f397);}_0x4f8d88[_0x1a4060('0x11d2')]=_0x3e950e;});}})['catch'](function(_0x3dbd77){const _0x1b3502=_0xe75d1;_0x387512[_0x1b3502('0x52a')]({'title':_0x3dbd77[_0x1b3502('0x13ee')]?_0x1b3502('0x2168')+_0x3dbd77[_0x1b3502('0x13ee')]+_0x1b3502('0xbf6')+_0x3dbd77[_0x1b3502('0x24a9')]:_0x1b3502('0xb97'),'msg':_0x3dbd77['data']?JSON[_0x1b3502('0x258a')](_0x3dbd77[_0x1b3502('0x5a5')]):_0x3dbd77[_0x1b3502('0x1ff0')]()});});function _0x1b205a(){const _0x4f280b=_0xe75d1;_0x4f8d88[_0x4f280b('0x17f')]=[];const _0x12d583=[];_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0xcf0')]&&_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0xcf0')][_0x4f280b('0x93a')]()===_0x4f280b('0x17cd')&&_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x11f3')]===_0x4f280b('0x4d2')&&(_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0xd31')]=_0x4a847c[_0x4f280b('0x145a')]?(_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x24fa')]||'')+_0x4f280b('0x249e')+_0x4a847c['cutdigits']+'}':(_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x24fa')]||'')+'${EXTEN}',_0x4a847c[_0x4f280b('0x75b')]!=='none'?_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x158e')][_0x4f280b('0x824')](_0x4f280b('0x1b1'))<0x0&&(_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x158e')]+=_0x4f280b('0x1b1')):_0x4f8d88['playback'][_0x4f280b('0x158e')]=_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x158e')][_0x4f280b('0x1725')](_0x4f280b('0x1b1'),''));if(_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x11f3')]&&_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x11f3')]===_0x4f280b('0xbf0')){}else switch((_0x4f8d88[_0x4f280b('0xab0')]['app']||_0x4f8d88[_0x4f280b('0xab0')]['appType'])[_0x4f280b('0x93a')]()){case _0x4f280b('0x877'):_0x4f8d88['playback'][_0x4f280b('0x1407')]=_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x60a')]+'='+_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x1c6b')];break;case _0x4f280b('0xbf0'):break;default:_0x12d583[0x0]=_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x1407')],_0x12d583[0x1]=_0x4f8d88[_0x4f280b('0xab0')][_0x4f280b('0x158e')],_0x4f8d88['playback'][_0x4f280b('0x1407')]=_0x12d583['join'](',');}_0xb15cc0(_0x4f8d88[_0x4f280b('0xab0')]);}function _0xb15cc0(_0xb8e6ef){const _0x2562c8=_0xe75d1;_0x20c03c[_0x2562c8('0x1715')](_0xb8e6ef);}}const _0x4ed990=_0x48c64d;_0xddca16[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'internalrouteApp',_0x189033('0xc'),_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0xddca16(_0x4373df,_0x287b4e,_0x588e87,_0x32e22f,_0x23ad60,_0x4c4742,_0x57b9c6,_0x1b5e39){const _0x4e8bb8=_0x189033,_0x9c75a7=this;_0x9c75a7[_0x4e8bb8('0x11ed')]=_0x57b9c6['getCurrentUser'](),_0x9c75a7['errors']=[],_0x9c75a7[_0x4e8bb8('0xf28')]=_0x4e8bb8('0x241c')+(_0x32e22f[_0x4e8bb8('0x11f3')]||_0x32e22f[_0x4e8bb8('0x1d75')])[_0x4e8bb8('0x80')](),_0x9c75a7[_0x4e8bb8('0x660')]=angular['copy'](_0x32e22f),_0x9c75a7['crudPermissions']=_0x1b5e39,_0x9c75a7[_0x4e8bb8('0x258d')]={};if(_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1407')])switch(_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x11f3')]?_0x9c75a7['queue'][_0x4e8bb8('0x11f3')][_0x4e8bb8('0x93a')]():_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1d75')][_0x4e8bb8('0x93a')]()){case _0x4e8bb8('0xbf0'):break;case _0x4e8bb8('0x205c'):{const _0x5a7cd9=_0x9c75a7[_0x4e8bb8('0x660')]['appdata'][_0x4e8bb8('0x1fc5')](',');_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1d46')]=_0x5a7cd9[0x0],_0x9c75a7[_0x4e8bb8('0x660')]['language']=_0x5a7cd9[0x1],_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x6d9')]=_0x5a7cd9[_0x4e8bb8('0x12c8')](0x2,_0x5a7cd9[_0x4e8bb8('0x1564')])[_0x4e8bb8('0x1630')](',');}break;case _0x4e8bb8('0xd24'):{const _0x5e0cf6=_0x9c75a7['queue']['appdata'][_0x4e8bb8('0x1fc5')](',');_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x2119')]=_0x5e0cf6[0x0],_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x38')]=_0x5e0cf6[0x1],_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x406')]=_0x5e0cf6[0x2],_0x9c75a7['queue'][_0x4e8bb8('0x1a1c')]=_0x5e0cf6[0x3],_0x9c75a7['queue'][_0x4e8bb8('0x6d9')]=_0x5e0cf6['slice'](0x4,_0x5e0cf6[_0x4e8bb8('0x1564')])[_0x4e8bb8('0x1630')](',');}break;case _0x4e8bb8('0x1db1'):{const _0x5996f0=_0x9c75a7[_0x4e8bb8('0x660')]['appdata'][_0x4e8bb8('0x1fc5')](',');_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x7ae')]=_0x5996f0[0x0],_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x204a')]=_0x5996f0[0x1],_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x5ba')]=_0x5996f0[0x2],_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x11a9')]=_0x5996f0[0x3],_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x6d9')]=_0x5996f0[_0x4e8bb8('0x12c8')](0x4,_0x5996f0[_0x4e8bb8('0x1564')])['join'](',');}break;case _0x4e8bb8('0x2408'):{const _0x36f117=_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1407')]['split'](',');_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x35')]=isNaN(_0x36f117[0x0])?_0x36f117[0x0]:parseInt(_0x36f117[0x0],0xa),_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1bcd')]=_0x36f117[_0x4e8bb8('0x12c8')](0x1,_0x36f117[_0x4e8bb8('0x1564')])[_0x4e8bb8('0x1630')](',');}break;case _0x4e8bb8('0x8c2'):_0x9c75a7['queue'][_0x4e8bb8('0x1bcd')]=_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1407')];break;case'set':_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x60a')]=_0x9c75a7[_0x4e8bb8('0x660')]['appdata'][_0x4e8bb8('0x1fc5')]('=')[0x0],_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1c6b')]=_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1407')]['split']('=')[0x1];break;case _0x4e8bb8('0x19ae'):_0x9c75a7[_0x4e8bb8('0x660')]['project']=_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1407')];break;default:{const _0x4ac4a9=_0x9c75a7['queue'][_0x4e8bb8('0x1407')][_0x4e8bb8('0x1fc5')](',');_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x660')]=_0x2e3ca0()[_0x4e8bb8('0x173f')](_0x4ac4a9[0x0])?_0x4ac4a9[0x0]:isNaN(_0x4ac4a9[0x0])?_0x4ac4a9[0x0]:parseInt(_0x4ac4a9[0x0],0xa),_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x158e')]=_0x2e3ca0()[_0x4e8bb8('0x173f')](_0x4ac4a9[0x1])?_0x4ac4a9[0x1]:isNaN(_0x4ac4a9[0x1])?_0x4ac4a9[0x1]:parseInt(_0x4ac4a9[0x1],0xa),_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1a0a')]=_0x2e3ca0()['isEmpty'](_0x4ac4a9[0x2])?_0x4ac4a9[0x2]:isNaN(_0x4ac4a9[0x2])?_0x4ac4a9[0x2]:parseInt(_0x4ac4a9[0x2],0xa),_0x9c75a7[_0x4e8bb8('0x660')]['sound']=_0x2e3ca0()['isEmpty'](_0x4ac4a9[0x3])?_0x4ac4a9[0x3]:isNaN(_0x4ac4a9[0x3])?_0x4ac4a9[0x3]:parseInt(_0x4ac4a9[0x3],0xa),_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1668')]=_0x2e3ca0()[_0x4e8bb8('0x173f')](_0x4ac4a9[0x4])?_0x4ac4a9[0x4]:isNaN(_0x4ac4a9[0x4])?_0x4ac4a9[0x4]:parseInt(_0x4ac4a9[0x4],0xa),_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x19ae')]=_0x2e3ca0()[_0x4e8bb8('0x173f')](_0x4ac4a9[0x5])?_0x4ac4a9[0x5]:isNaN(_0x4ac4a9[0x5])?_0x4ac4a9[0x5]:parseInt(_0x4ac4a9[0x5],0xa),_0x9c75a7[_0x4e8bb8('0x660')]['macro']=_0x2e3ca0()['isEmpty'](_0x4ac4a9[0x6])?_0x4ac4a9[0x6]:isNaN(_0x4ac4a9[0x6])?_0x4ac4a9[0x6]:parseInt(_0x4ac4a9[0x6],0xa),_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x2550')]=_0x2e3ca0()[_0x4e8bb8('0x173f')](_0x4ac4a9[0x7])?_0x4ac4a9[0x7]:isNaN(_0x4ac4a9[0x7])?_0x4ac4a9[0x7]:parseInt(_0x4ac4a9[0x7],0xa),_0x9c75a7['queue']['rule']=_0x2e3ca0()[_0x4e8bb8('0x173f')](_0x4ac4a9[0x8])?_0x4ac4a9[0x8]:isNaN(_0x4ac4a9[0x8])?_0x4ac4a9[0x8]:parseInt(_0x4ac4a9[0x8],0xa),_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x1233')]=_0x2e3ca0()[_0x4e8bb8('0x173f')](_0x4ac4a9[0x9])?_0x4ac4a9[0x9]:isNaN(_0x4ac4a9[0x9])?_0x4ac4a9[0x9]:parseInt(_0x4ac4a9[0x9],0xa);}break;}else{}_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0xcf0')]&&_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0xcf0')]['toLowerCase']()==='outbound'&&_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x11f3')]['toLowerCase']()==='outbounddial'&&(_0x9c75a7['queue'][_0x4e8bb8('0x24fa')]=_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0xd31')]?_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0xd31')][_0x4e8bb8('0x1fc5')]('$')[0x0]:undefined,_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0xabd')]=_0x9c75a7['queue'][_0x4e8bb8('0x73c')]?_0x4e8bb8('0xac1')+_0x9c75a7[_0x4e8bb8('0x660')][_0x4e8bb8('0x73c')]:undefined);_0x9c75a7[_0x4e8bb8('0x79b')]=_0x339e87,_0x9c75a7[_0x4e8bb8('0xf82')]=_0x565519,_0x57b9c6[_0x4e8bb8('0xca1')](_0x4e8bb8('0x20c2'))?_0x4c4742['sound'][_0x4e8bb8('0x1e6e')]({'fields':'id,name,save_name','sort':_0x4e8bb8('0x60a'),'nolimit':'true'})[_0x4e8bb8('0xe53')][_0x4e8bb8('0x683')](function(_0x645134){_0x9c75a7['sounds']=_0x645134['rows']||[];})[_0x4e8bb8('0x130a')](function(_0xfe3eac){const _0xe402b0=_0x4e8bb8;_0x588e87['error']({'title':_0xfe3eac[_0xe402b0('0x13ee')]?'API:'+_0xfe3eac[_0xe402b0('0x13ee')]+_0xe402b0('0xbf6')+_0xfe3eac[_0xe402b0('0x24a9')]:'SYSTEM:GET_SOUNDS','msg':_0xfe3eac['data']?JSON[_0xe402b0('0x258a')](_0xfe3eac[_0xe402b0('0x5a5')]):_0xfe3eac[_0xe402b0('0x1ff0')]()});}):_0x4c4742['sound'][_0x4e8bb8('0x1e6e')]({'fields':_0x4e8bb8('0xfa7'),'sort':_0x4e8bb8('0x60a'),'nolimit':_0x4e8bb8('0x26ac')})[_0x4e8bb8('0xe53')][_0x4e8bb8('0x683')](function(_0x4929b7){const _0x8a8fb9=_0x4e8bb8;_0x9c75a7[_0x8a8fb9('0x11d2')]=_0x4929b7[_0x8a8fb9('0xf5d')]||[];})[_0x4e8bb8('0x683')](function(){const _0x281d83=_0x4e8bb8;return _0x4c4742[_0x281d83('0x22df')][_0x281d83('0x1e6e')]({'userProfileId':_0x9c75a7['currentUser']['userProfileId'],'sectionId':0x3ef})[_0x281d83('0xe53')];})[_0x4e8bb8('0x683')](function(_0x6f3ca3){const _0x527f28=_0x4e8bb8,_0x1efa95=_0x6f3ca3&&_0x6f3ca3[_0x527f28('0xf5d')]?_0x6f3ca3[_0x527f28('0xf5d')][0x0]:null;if(!_0x1efa95){const _0x111fad=[];let _0x17e380=null;_0x9c75a7['queue']&&(_0x17e380=_0x2e3ca0()[_0x527f28('0x1c07')](_0x9c75a7['sounds'],{'save_name':_0x9c75a7[_0x527f28('0x660')][_0x527f28('0x1638')]}));for(let _0x533f49=0x0;_0x533f49<_0x9c75a7['sounds'][_0x527f28('0x1564')];_0x533f49++){_0x17e380&&_0x9c75a7[_0x527f28('0x11d2')][_0x533f49]['id']===_0x17e380['id']&&(_0x9c75a7[_0x527f28('0x11d2')][_0x533f49][_0x527f28('0x319')]=![],_0x111fad['push'](_0x9c75a7['sounds'][_0x533f49]));}_0x9c75a7['sounds']=_0x111fad;}else{if(!_0x1efa95[_0x527f28('0x170')])return _0x4c4742['userProfileResource'][_0x527f28('0x1e6e')]({'sectionId':_0x1efa95['id']})[_0x527f28('0xe53')][_0x527f28('0x683')](function(_0x2c89ad){const _0x4ce22a=_0x527f28,_0x16b0ae=_0x2e3ca0()[_0x4ce22a('0x386')](_0x2c89ad[_0x4ce22a('0xf5d')],function(_0x20150b){const _0x2fb259=_0x4ce22a;return _0x2e3ca0()[_0x2fb259('0x1c07')](_0x9c75a7[_0x2fb259('0x11d2')],{'id':_0x20150b[_0x2fb259('0x832')]});});let _0xef654e=null;_0x9c75a7[_0x4ce22a('0x660')]&&(_0xef654e=_0x2e3ca0()[_0x4ce22a('0x1c07')](_0x9c75a7[_0x4ce22a('0x11d2')],{'save_name':_0x9c75a7['queue'][_0x4ce22a('0x1638')]}));if(_0xef654e&&!_0x2e3ca0()[_0x4ce22a('0x7a2')](_0x16b0ae,['id',_0xef654e['id']])){const _0x5a042f=_0x2e3ca0()[_0x4ce22a('0x1c07')](_0x9c75a7[_0x4ce22a('0x11d2')],{'id':_0xef654e['id']});_0x5a042f[_0x4ce22a('0x319')]=![],_0x16b0ae[_0x4ce22a('0x1fd0')](_0x5a042f);}_0x9c75a7[_0x4ce22a('0x11d2')]=_0x16b0ae;});}})[_0x4e8bb8('0x130a')](function(_0x5b5fb1){const _0x5e2427=_0x4e8bb8;_0x588e87[_0x5e2427('0x52a')]({'title':_0x5b5fb1[_0x5e2427('0x13ee')]?_0x5e2427('0x2168')+_0x5b5fb1[_0x5e2427('0x13ee')]+_0x5e2427('0xbf6')+_0x5b5fb1['statusText']:_0x5e2427('0xb97'),'msg':_0x5b5fb1[_0x5e2427('0x5a5')]?JSON['stringify'](_0x5b5fb1[_0x5e2427('0x5a5')]):_0x5b5fb1[_0x5e2427('0x1ff0')]()});}),_0x57b9c6[_0x4e8bb8('0xca1')]('admin')?_0x4c4742[_0x4e8bb8('0x204c')]['get']({'type':_0x4e8bb8('0x1535'),'fields':_0x4e8bb8('0x2035'),'sort':_0x4e8bb8('0x60a'),'nolimit':_0x4e8bb8('0x26ac')})[_0x4e8bb8('0xe53')][_0x4e8bb8('0x683')](function(_0x2e02bf){const _0x301767=_0x4e8bb8;_0x9c75a7[_0x301767('0x2da')]=_0x2e02bf[_0x301767('0xf5d')]||[];})[_0x4e8bb8('0x130a')](function(_0x494bef){const _0x370046=_0x4e8bb8;_0x588e87[_0x370046('0x52a')]({'title':_0x494bef['status']?_0x370046('0x2168')+_0x494bef[_0x370046('0x13ee')]+'\x20-\x20'+_0x494bef['statusText']:_0x370046('0x22dc'),'msg':_0x494bef[_0x370046('0x5a5')]?JSON[_0x370046('0x258a')](_0x494bef[_0x370046('0x5a5')]):_0x494bef[_0x370046('0x1ff0')]()});}):_0x4c4742['voiceQueue']['get']({'type':'inbound','fields':'id,name,type','sort':_0x4e8bb8('0x60a'),'nolimit':_0x4e8bb8('0x26ac')})[_0x4e8bb8('0xe53')][_0x4e8bb8('0x683')](function(_0x2cb938){const _0x3a1410=_0x4e8bb8;_0x9c75a7[_0x3a1410('0x2da')]=_0x2cb938['rows']||[];})[_0x4e8bb8('0x683')](function(){const _0x5bf406=_0x4e8bb8;return _0x4c4742['userProfileSection'][_0x5bf406('0x1e6e')]({'userProfileId':_0x9c75a7[_0x5bf406('0x11ed')][_0x5bf406('0x2f')],'sectionId':0x191})[_0x5bf406('0xe53')];})[_0x4e8bb8('0x683')](function(_0x6d2efa){const _0x3b9140=_0x4e8bb8,_0x5b4b38=_0x6d2efa&&_0x6d2efa[_0x3b9140('0xf5d')]?_0x6d2efa[_0x3b9140('0xf5d')][0x0]:null;if(!_0x5b4b38){const _0x1974c1=[];let _0xa97b42=null;_0x9c75a7['queue']&&(_0xa97b42=_0x2e3ca0()[_0x3b9140('0x1c07')](_0x9c75a7['queues'],{'name':_0x9c75a7['queue'][_0x3b9140('0x660')]}));for(let _0x184900=0x0;_0x184900<_0x9c75a7['queues'][_0x3b9140('0x1564')];_0x184900++){_0xa97b42&&_0x9c75a7['queues'][_0x184900]['id']===_0xa97b42['id']&&(_0x9c75a7['queues'][_0x184900][_0x3b9140('0x319')]=![],_0x1974c1['push'](_0x9c75a7[_0x3b9140('0x2da')][_0x184900]));}_0x9c75a7['queues']=_0x1974c1;}else{if(!_0x5b4b38[_0x3b9140('0x170')])return _0x4c4742[_0x3b9140('0xcf7')][_0x3b9140('0x1e6e')]({'sectionId':_0x5b4b38['id']})['$promise'][_0x3b9140('0x683')](function(_0x9e72e6){const _0x251dee=_0x3b9140,_0x170c8d=_0x2e3ca0()['map'](_0x9e72e6[_0x251dee('0xf5d')],function(_0x1306ab){const _0x241a0f=_0x251dee;return _0x2e3ca0()[_0x241a0f('0x1c07')](_0x9c75a7[_0x241a0f('0x2da')],{'id':_0x1306ab['resourceId']});});let _0x416cfd=null;_0x9c75a7[_0x251dee('0x660')]&&(_0x416cfd=_0x2e3ca0()[_0x251dee('0x1c07')](_0x9c75a7[_0x251dee('0x2da')],{'name':_0x9c75a7[_0x251dee('0x660')][_0x251dee('0x660')]}));if(_0x416cfd&&!_0x2e3ca0()[_0x251dee('0x7a2')](_0x170c8d,['id',_0x416cfd['id']])){const _0x278f20=_0x2e3ca0()['find'](_0x9c75a7[_0x251dee('0x2da')],{'id':_0x416cfd['id']});_0x278f20[_0x251dee('0x319')]=![],_0x170c8d[_0x251dee('0x1fd0')](_0x278f20);}_0x9c75a7[_0x251dee('0x2da')]=_0x170c8d;});}})['catch'](function(_0x3ca45e){const _0x3982a3=_0x4e8bb8;_0x588e87[_0x3982a3('0x52a')]({'title':_0x3ca45e[_0x3982a3('0x13ee')]?_0x3982a3('0x2168')+_0x3ca45e[_0x3982a3('0x13ee')]+'\x20-\x20'+_0x3ca45e['statusText']:_0x3982a3('0x934'),'msg':_0x3ca45e[_0x3982a3('0x5a5')]?JSON[_0x3982a3('0x258a')](_0x3ca45e[_0x3982a3('0x5a5')]):_0x3ca45e[_0x3982a3('0x1ff0')]()});});function _0x339e87(){const _0xb2a1f2=_0x4e8bb8;_0x9c75a7['errors']=[];const _0x330722=[];_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0xcf0')]&&_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0xcf0')][_0xb2a1f2('0x93a')]()===_0xb2a1f2('0x17cd')&&_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x11f3')]===_0xb2a1f2('0x4d2')&&(_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0xd31')]=_0x23ad60['cutdigits']?(_0x9c75a7[_0xb2a1f2('0x660')]['prefix']||'')+'${EXTEN:'+_0x23ad60[_0xb2a1f2('0x145a')]+'}':(_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x24fa')]||'')+_0xb2a1f2('0x20cb'),_0x23ad60[_0xb2a1f2('0x75b')]!=='none'?_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x158e')][_0xb2a1f2('0x824')](_0xb2a1f2('0x1b1'))<0x0&&(_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x158e')]+='U(xcally-mixmonitor-context)'):_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x158e')]=_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x158e')][_0xb2a1f2('0x1725')](_0xb2a1f2('0x1b1'),''));if(_0x9c75a7[_0xb2a1f2('0x660')]['appType']&&_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x11f3')]===_0xb2a1f2('0xbf0')){}else switch((_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x1d75')]||_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x11f3')])[_0xb2a1f2('0x93a')]()){case _0xb2a1f2('0x877'):_0x9c75a7[_0xb2a1f2('0x660')]['appdata']=_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x60a')]+'='+_0x9c75a7[_0xb2a1f2('0x660')]['value'];break;case _0xb2a1f2('0xbf0'):break;default:_0x330722[0x0]=_0x9c75a7['queue'][_0xb2a1f2('0x660')],_0x330722[0x1]=_0x9c75a7['queue'][_0xb2a1f2('0x158e')],_0x330722[0x2]=_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x1a0a')],_0x330722[0x3]=_0x9c75a7['queue']['sound'],_0x330722[0x4]=_0x9c75a7[_0xb2a1f2('0x660')]['timeout'],_0x330722[0x5]=_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x19ae')],_0x330722[0x6]=_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0xda6')],_0x330722[0x7]=_0x9c75a7['queue']['gosub'],_0x330722[0x8]=_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x10a8')],_0x330722[0x9]=_0x9c75a7[_0xb2a1f2('0x660')][_0xb2a1f2('0x1233')],_0x9c75a7[_0xb2a1f2('0x660')]['appdata']=_0x330722[_0xb2a1f2('0x1630')](',');}_0x565519(_0x9c75a7[_0xb2a1f2('0x660')]);}function _0x565519(_0xca44d8){const _0x82b927=_0x4e8bb8;_0x4373df[_0x82b927('0x1715')](_0xca44d8);}}const _0x48f865=_0xddca16;_0x1bf25b[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0xd15'),'internalroute',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x1bf25b(_0x317ed5,_0x45dfb6,_0x262c18,_0x4e9432,_0x331314,_0x34563f,_0x2b9440,_0x3bba2f){const _0x28db0d=_0x189033,_0x4c1ed2=this;_0x4c1ed2[_0x28db0d('0x11ed')]=_0x2b9440[_0x28db0d('0x20b2')](),_0x4c1ed2[_0x28db0d('0x17f')]=[],_0x4c1ed2[_0x28db0d('0xf28')]=_0x28db0d('0x241c')+(_0x4e9432[_0x28db0d('0x11f3')]||_0x4e9432[_0x28db0d('0x1d75')])[_0x28db0d('0x80')](),_0x4c1ed2[_0x28db0d('0x1aa5')]=angular[_0x28db0d('0x1a86')](_0x4e9432),_0x4c1ed2[_0x28db0d('0x1134')]=_0x3bba2f,_0x4c1ed2[_0x28db0d('0x258d')]={};if(_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1407')])switch(_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x11f3')]?_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x11f3')]['toLowerCase']():_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1d75')][_0x28db0d('0x93a')]()){case _0x28db0d('0xbf0'):break;case _0x28db0d('0x205c'):{const _0x1e9bf3=_0x4c1ed2[_0x28db0d('0x1aa5')]['appdata'][_0x28db0d('0x1fc5')](',');_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1d46')]=_0x1e9bf3[0x0],_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1a1c')]=_0x1e9bf3[0x1],_0x4c1ed2['ringgroup']['welcomemessage']=_0x1e9bf3[_0x28db0d('0x12c8')](0x2,_0x1e9bf3['length'])[_0x28db0d('0x1630')](',');}break;case'dialogflowv2':{const _0x98f8c5=_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1407')][_0x28db0d('0x1fc5')](',');_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x2119')]=_0x98f8c5[0x0],_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x38')]=_0x98f8c5[0x1],_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x406')]=_0x98f8c5[0x2],_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1a1c')]=_0x98f8c5[0x3],_0x4c1ed2[_0x28db0d('0x1aa5')]['welcomemessage']=_0x98f8c5[_0x28db0d('0x12c8')](0x4,_0x98f8c5[_0x28db0d('0x1564')])[_0x28db0d('0x1630')](',');}break;case _0x28db0d('0x1db1'):{const _0x2445d7=_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1407')][_0x28db0d('0x1fc5')](',');_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x7ae')]=_0x2445d7[0x0],_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x204a')]=_0x2445d7[0x1],_0x4c1ed2[_0x28db0d('0x1aa5')]['lexregion']=_0x2445d7[0x2],_0x4c1ed2['ringgroup'][_0x28db0d('0x11a9')]=_0x2445d7[0x3],_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x6d9')]=_0x2445d7[_0x28db0d('0x12c8')](0x4,_0x2445d7[_0x28db0d('0x1564')])[_0x28db0d('0x1630')](',');}break;case'autoreply':{const _0x517803=_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1407')][_0x28db0d('0x1fc5')](',');_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x35')]=isNaN(_0x517803[0x0])?_0x517803[0x0]:parseInt(_0x517803[0x0],0xa),_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1bcd')]=_0x517803['slice'](0x1,_0x517803['length'])[_0x28db0d('0x1630')](',');}break;case _0x28db0d('0x8c2'):_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1bcd')]=_0x4c1ed2['ringgroup'][_0x28db0d('0x1407')];break;case _0x28db0d('0x877'):_0x4c1ed2['ringgroup'][_0x28db0d('0x60a')]=_0x4c1ed2[_0x28db0d('0x1aa5')]['appdata']['split']('=')[0x0],_0x4c1ed2[_0x28db0d('0x1aa5')]['value']=_0x4c1ed2['ringgroup'][_0x28db0d('0x1407')][_0x28db0d('0x1fc5')]('=')[0x1];break;case _0x28db0d('0x19ae'):_0x4c1ed2[_0x28db0d('0x1aa5')]['project']=_0x4c1ed2[_0x28db0d('0x1aa5')]['appdata'];break;default:{const _0x15e322=_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x1407')]['split'](',');_0x4c1ed2['ringgroup'][_0x28db0d('0xbf8')]=_0x15e322[0x0][_0x28db0d('0x1fc5')]('&'),_0x4c1ed2[_0x28db0d('0x1aa5')]['timeout']=_0x2e3ca0()[_0x28db0d('0x173f')](_0x15e322[0x1])?_0x15e322[0x1]:isNaN(_0x15e322[0x1])?_0x15e322[0x1]:parseInt(_0x15e322[0x1],0xa),_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x158e')]=_0x2e3ca0()[_0x28db0d('0x173f')](_0x15e322[0x2])?_0x15e322[0x2]:isNaN(_0x15e322[0x2])?_0x15e322[0x2]:parseInt(_0x15e322[0x2],0xa),_0x4c1ed2[_0x28db0d('0x1aa5')]['url']=_0x2e3ca0()[_0x28db0d('0x173f')](_0x15e322[0x3])?_0x15e322[0x3]:isNaN(_0x15e322[0x3])?_0x15e322[0x3]:parseInt(_0x15e322[0x3],0xa);}break;}else{}_0x4c1ed2['ringgroup'][_0x28db0d('0xcf0')]&&_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0xcf0')][_0x28db0d('0x93a')]()==='outbound'&&_0x4c1ed2['ringgroup']['appType']['toLowerCase']()===_0x28db0d('0x659')&&(_0x4c1ed2[_0x28db0d('0x1aa5')]['prefix']=_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0xd31')]?_0x4c1ed2[_0x28db0d('0x1aa5')]['phone']['split']('$')[0x0]:undefined,_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0xabd')]=_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x73c')]?_0x28db0d('0xac1')+_0x4c1ed2[_0x28db0d('0x1aa5')][_0x28db0d('0x73c')]:undefined);_0x4c1ed2[_0x28db0d('0x79b')]=_0x3d0ad6,_0x4c1ed2[_0x28db0d('0xf82')]=_0x470538;const _0x398a7e=[{'id':0xca,'role':_0x28db0d('0x2327')},{'id':0xcb,'role':_0x28db0d('0x24d3')}];let _0x4c83fc=null;_0x2b9440[_0x28db0d('0xca1')](_0x28db0d('0x20c2'))?_0x34563f[_0x28db0d('0xc96')][_0x28db0d('0x1e6e')]({'fields':_0x28db0d('0xac9'),'sort':_0x28db0d('0x60a'),'nolimit':_0x28db0d('0x26ac')})[_0x28db0d('0xe53')]['then'](function(_0x1b3540){const _0xae6923=_0x28db0d;_0x4c1ed2[_0xae6923('0x3bf')]=_0x1b3540[_0xae6923('0xf5d')]||[];})[_0x28db0d('0x130a')](function(_0x298ab7){const _0x2d07b6=_0x28db0d;_0x262c18['error']({'title':_0x298ab7[_0x2d07b6('0x13ee')]?_0x2d07b6('0x2168')+_0x298ab7[_0x2d07b6('0x13ee')]+_0x2d07b6('0xbf6')+_0x298ab7[_0x2d07b6('0x24a9')]:_0x2d07b6('0x8eb'),'msg':_0x298ab7[_0x2d07b6('0x5a5')]?JSON[_0x2d07b6('0x258a')](_0x298ab7['data']):_0x298ab7[_0x2d07b6('0x1ff0')]()});}):_0x34563f[_0x28db0d('0xc96')][_0x28db0d('0x1e6e')]({'fields':'id,name,role','sort':_0x28db0d('0x60a'),'nolimit':'true'})[_0x28db0d('0xe53')][_0x28db0d('0x683')](function(_0x49ea84){const _0x221e10=_0x28db0d;_0x4c83fc=_0x49ea84[_0x221e10('0xf5d')]||[];})['then'](function(){const _0x5ed74d=_0x28db0d,_0x356431=[];for(let _0x5af259=0x0;_0x5af259<_0x398a7e[_0x5ed74d('0x1564')];_0x5af259++){_0x356431[_0x5ed74d('0x1fd0')](_0x34563f['userProfileSection']['get']({'userProfileId':_0x4c1ed2[_0x5ed74d('0x11ed')]['userProfileId'],'sectionId':_0x398a7e[_0x5af259]['id']})[_0x5ed74d('0xe53')]);}return _0x45dfb6['all'](_0x356431);})['then'](function(_0x4562f9){const _0x4a7e3e=_0x28db0d,_0x79f77=_0x2e3ca0()[_0x4a7e3e('0x386')](_0x4562f9,function(_0x33b551){const _0x35513b=_0x4a7e3e;return _0x33b551&&_0x33b551[_0x35513b('0xf5d')]?_0x33b551[_0x35513b('0xf5d')][0x0]:null;}),_0xf68677=[];for(let _0x34df60=0x0;_0x34df60<_0x398a7e[_0x4a7e3e('0x1564')];_0x34df60++){const _0x8ed8c8=_0x2e3ca0()[_0x4a7e3e('0x1c07')](_0x79f77,['sectionId',_0x398a7e[_0x34df60]['id']]);if(_0x8ed8c8){if(!_0x8ed8c8[_0x4a7e3e('0x170')])_0xf68677[_0x4a7e3e('0x1fd0')](_0x34563f['userProfileResource'][_0x4a7e3e('0x1e6e')]({'sectionId':_0x8ed8c8['id']})[_0x4a7e3e('0xe53')]);else{const _0x4c2e2f=[];_0x4c83fc[_0x4a7e3e('0x1299')](function(_0x3f4a23){const _0x139e36=_0x4a7e3e;_0x3f4a23['role']===_0x398a7e[_0x34df60]['role']&&_0x4c2e2f[_0x139e36('0x1fd0')](_0x3f4a23);}),_0xf68677[_0x4a7e3e('0x1fd0')]({'rows':_0x4c2e2f,'count':_0x4c2e2f[_0x4a7e3e('0x1564')]});}}}return _0x45dfb6['all'](_0xf68677);})[_0x28db0d('0x683')](function(_0x5320f9){const _0x48ec54=_0x28db0d,_0x500ed6=[];let _0x2a542b=null;_0x4c1ed2[_0x48ec54('0x1aa5')]&&(_0x2a542b=_0x2e3ca0()[_0x48ec54('0x1c07')](_0x4c83fc,{'name':_0x4c1ed2[_0x48ec54('0x1aa5')][_0x48ec54('0xbf8')]}));for(let _0x148661=0x0;_0x148661<_0x5320f9[_0x48ec54('0x1564')];_0x148661++){const _0x1a45f0=_0x5320f9[_0x148661]['rows']||[];_0x1a45f0[_0x48ec54('0x1299')](function(_0xe7cc02){const _0x510d63=_0x48ec54;_0x500ed6[_0x510d63('0x1fd0')](_0xe7cc02);});}_0x2a542b&&!_0x2e3ca0()[_0x48ec54('0x7a2')](_0x500ed6,[_0x48ec54('0x832'),_0x2a542b['id']])&&_0x4c83fc[_0x48ec54('0x1299')](function(_0x1bb243){const _0x31d32c=_0x48ec54;_0x1bb243['id']===_0x2a542b['id']&&(_0x1bb243[_0x31d32c('0x319')]=![],_0x500ed6[_0x31d32c('0x1fd0')](_0x1bb243));}),_0x4c1ed2[_0x48ec54('0x3bf')]=_0x500ed6;})[_0x28db0d('0x130a')](function(_0x7247a2){const _0x263338=_0x28db0d;_0x262c18['error']({'title':_0x7247a2[_0x263338('0x13ee')]?_0x263338('0x2168')+_0x7247a2[_0x263338('0x13ee')]+_0x263338('0xbf6')+_0x7247a2[_0x263338('0x24a9')]:_0x263338('0x1511'),'msg':_0x7247a2['data']?JSON[_0x263338('0x258a')](_0x7247a2[_0x263338('0x5a5')]):_0x7247a2['toString']()});});function _0x3d0ad6(){const _0x3477b2=_0x28db0d;_0x4c1ed2['errors']=[];const _0x50b0ae=[];_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0xcf0')]&&_0x4c1ed2['ringgroup']['type']['toLowerCase']()===_0x3477b2('0x17cd')&&_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x11f3')]===_0x3477b2('0x4d2')&&(_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0xd31')]=_0x331314[_0x3477b2('0x145a')]?(_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x24fa')]||'')+_0x3477b2('0x249e')+_0x331314[_0x3477b2('0x145a')]+'}':(_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x24fa')]||'')+_0x3477b2('0x20cb'),_0x331314[_0x3477b2('0x75b')]!=='none'?_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x158e')]['indexOf']('U(xcally-mixmonitor-context)')<0x0&&(_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x158e')]+='U(xcally-mixmonitor-context)'):_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x158e')]=_0x4c1ed2['ringgroup'][_0x3477b2('0x158e')][_0x3477b2('0x1725')](_0x3477b2('0x1b1'),''));if(_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x11f3')]&&_0x4c1ed2['ringgroup']['appType']===_0x3477b2('0xbf0')){}else switch((_0x4c1ed2[_0x3477b2('0x1aa5')]['app']||_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x11f3')])[_0x3477b2('0x93a')]()){case'set':_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x1407')]=_0x4c1ed2[_0x3477b2('0x1aa5')]['name']+'='+_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x1c6b')];break;case _0x3477b2('0xbf0'):break;default:_0x50b0ae[0x0]=_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0xbf8')]['join']('&'),_0x50b0ae[0x1]=_0x4c1ed2['ringgroup'][_0x3477b2('0x1668')],_0x50b0ae[0x2]=_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x158e')],_0x50b0ae[0x3]=_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x1284')],_0x4c1ed2[_0x3477b2('0x1aa5')][_0x3477b2('0x1407')]=_0x50b0ae[_0x3477b2('0x1630')](',');}_0x470538(_0x4c1ed2[_0x3477b2('0x1aa5')]);}function _0x470538(_0x5bfdaa){_0x317ed5['hide'](_0x5bfdaa);}}const _0x56e786=_0x1bf25b;_0x299e14[_0x189033('0x14be')]=['$mdDialog','$q','toasty',_0x189033('0xd15'),_0x189033('0xc'),'api',_0x189033('0xba1'),'crudPermissions'];function _0x299e14(_0x3b3235,_0x20e14c,_0x374da6,_0x162888,_0x45a577,_0x46aa28,_0x44737c,_0x1ce4ed){const _0x33cc8c=_0x189033,_0x1d5a2a=this;_0x1d5a2a[_0x33cc8c('0x11ed')]=_0x44737c[_0x33cc8c('0x20b2')](),_0x1d5a2a['errors']=[],_0x1d5a2a[_0x33cc8c('0xf28')]=_0x33cc8c('0x241c')+(_0x162888[_0x33cc8c('0x11f3')]||_0x162888[_0x33cc8c('0x1d75')])[_0x33cc8c('0x80')](),_0x1d5a2a[_0x33cc8c('0x877')]=angular[_0x33cc8c('0x1a86')](_0x162888),_0x1d5a2a['crudPermissions']=_0x1ce4ed,_0x1d5a2a[_0x33cc8c('0x258d')]={};if(_0x1d5a2a[_0x33cc8c('0x877')]['appdata'])switch(_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x11f3')]?_0x1d5a2a['set'][_0x33cc8c('0x11f3')][_0x33cc8c('0x93a')]():_0x1d5a2a['set'][_0x33cc8c('0x1d75')][_0x33cc8c('0x93a')]()){case _0x33cc8c('0xbf0'):break;case _0x33cc8c('0x205c'):{const _0x55f335=_0x1d5a2a['set'][_0x33cc8c('0x1407')]['split'](',');_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1d46')]=_0x55f335[0x0],_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1a1c')]=_0x55f335[0x1],_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x6d9')]=_0x55f335[_0x33cc8c('0x12c8')](0x2,_0x55f335[_0x33cc8c('0x1564')])[_0x33cc8c('0x1630')](',');}break;case _0x33cc8c('0xd24'):{const _0x26bae2=_0x1d5a2a['set'][_0x33cc8c('0x1407')][_0x33cc8c('0x1fc5')](',');_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x2119')]=_0x26bae2[0x0],_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x38')]=_0x26bae2[0x1],_0x1d5a2a[_0x33cc8c('0x877')]['privateKey']=_0x26bae2[0x2],_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1a1c')]=_0x26bae2[0x3],_0x1d5a2a['set'][_0x33cc8c('0x6d9')]=_0x26bae2['slice'](0x4,_0x26bae2[_0x33cc8c('0x1564')])[_0x33cc8c('0x1630')](',');}break;case _0x33cc8c('0x1db1'):{const _0x4d3343=_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1407')][_0x33cc8c('0x1fc5')](',');_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x7ae')]=_0x4d3343[0x0],_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x204a')]=_0x4d3343[0x1],_0x1d5a2a['set'][_0x33cc8c('0x5ba')]=_0x4d3343[0x2],_0x1d5a2a['set']['botname']=_0x4d3343[0x3],_0x1d5a2a[_0x33cc8c('0x877')]['welcomemessage']=_0x4d3343[_0x33cc8c('0x12c8')](0x4,_0x4d3343[_0x33cc8c('0x1564')])['join'](',');}break;case _0x33cc8c('0x2408'):{const _0xbdf519=_0x1d5a2a[_0x33cc8c('0x877')]['appdata'][_0x33cc8c('0x1fc5')](',');_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x35')]=isNaN(_0xbdf519[0x0])?_0xbdf519[0x0]:parseInt(_0xbdf519[0x0],0xa),_0x1d5a2a['set'][_0x33cc8c('0x1bcd')]=_0xbdf519[_0x33cc8c('0x12c8')](0x1,_0xbdf519[_0x33cc8c('0x1564')])['join'](',');}break;case _0x33cc8c('0x8c2'):_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1bcd')]=_0x1d5a2a[_0x33cc8c('0x877')]['appdata'];break;case'set':_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x60a')]=_0x1d5a2a['set'][_0x33cc8c('0x1407')][_0x33cc8c('0x1fc5')]('=')[0x0],_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1c6b')]=_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1407')][_0x33cc8c('0x1fc5')]('=')[0x1];break;case'agi':_0x1d5a2a['set'][_0x33cc8c('0x273a')]=_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1407')];break;default:{const _0x565f28=_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1407')]['split']('=');_0x1d5a2a[_0x33cc8c('0x877')]['name']=_0x2e3ca0()[_0x33cc8c('0x173f')](_0x565f28[0x0])?_0x565f28[0x0]:isNaN(_0x565f28[0x0])?_0x565f28[0x0]:parseInt(_0x565f28[0x0],0xa),_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x1c6b')]=_0x2e3ca0()['isEmpty'](_0x565f28[0x1])?_0x565f28[0x1]:isNaN(_0x565f28[0x1])?_0x565f28[0x1]:parseInt(_0x565f28[0x1],0xa);}break;}else{}_0x1d5a2a[_0x33cc8c('0x877')]['type']&&_0x1d5a2a['set'][_0x33cc8c('0xcf0')][_0x33cc8c('0x93a')]()===_0x33cc8c('0x17cd')&&_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x11f3')][_0x33cc8c('0x93a')]()===_0x33cc8c('0x659')&&(_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x24fa')]=_0x1d5a2a[_0x33cc8c('0x877')]['phone']?_0x1d5a2a[_0x33cc8c('0x877')]['phone'][_0x33cc8c('0x1fc5')]('$')[0x0]:undefined,_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0xabd')]=_0x1d5a2a[_0x33cc8c('0x877')][_0x33cc8c('0x73c')]?'CALLERID(all)='+_0x1d5a2a[_0x33cc8c('0x877')]['callerID']:undefined);_0x1d5a2a[_0x33cc8c('0x79b')]=_0x3ce19b,_0x1d5a2a[_0x33cc8c('0xf82')]=_0x5a0ffa,_0x44737c[_0x33cc8c('0xca1')](_0x33cc8c('0x20c2'))?_0x46aa28[_0x33cc8c('0x26e0')][_0x33cc8c('0x1e6e')]({'fields':_0x33cc8c('0xa10'),'sort':'name','nolimit':_0x33cc8c('0x26ac')})[_0x33cc8c('0xe53')][_0x33cc8c('0x683')](function(_0x568c48){const _0x25d8d2=_0x33cc8c;_0x1d5a2a[_0x25d8d2('0x220b')]=_0x568c48[_0x25d8d2('0xf5d')]||[];})[_0x33cc8c('0x130a')](function(_0x5c980b){const _0x3c6d08=_0x33cc8c;_0x374da6['error']({'title':_0x5c980b[_0x3c6d08('0x13ee')]?_0x3c6d08('0x2168')+_0x5c980b['status']+_0x3c6d08('0xbf6')+_0x5c980b[_0x3c6d08('0x24a9')]:'SYSTEM:GET_VARIABLES','msg':_0x5c980b[_0x3c6d08('0x5a5')]?JSON[_0x3c6d08('0x258a')](_0x5c980b[_0x3c6d08('0x5a5')]):_0x5c980b[_0x3c6d08('0x1ff0')]()});}):_0x46aa28[_0x33cc8c('0x26e0')][_0x33cc8c('0x1e6e')]({'fields':_0x33cc8c('0xa10'),'sort':_0x33cc8c('0x60a'),'nolimit':_0x33cc8c('0x26ac')})[_0x33cc8c('0xe53')][_0x33cc8c('0x683')](function(_0x503980){const _0x561dfd=_0x33cc8c;_0x1d5a2a['variables']=_0x503980[_0x561dfd('0xf5d')]||[];})[_0x33cc8c('0x683')](function(){const _0x30efda=_0x33cc8c;return _0x46aa28[_0x30efda('0x22df')][_0x30efda('0x1e6e')]({'userProfileId':_0x1d5a2a['currentUser'][_0x30efda('0x2f')],'sectionId':0x3f4})[_0x30efda('0xe53')];})[_0x33cc8c('0x683')](function(_0x2130e0){const _0x36f14b=_0x33cc8c,_0x4f5cf8=_0x2130e0&&_0x2130e0['rows']?_0x2130e0[_0x36f14b('0xf5d')][0x0]:null;if(!_0x4f5cf8){const _0x1837df=[];let _0x4af332=null;_0x1d5a2a[_0x36f14b('0x877')]&&(_0x4af332=_0x2e3ca0()[_0x36f14b('0x1c07')](_0x1d5a2a[_0x36f14b('0x220b')],{'name':_0x1d5a2a['set'][_0x36f14b('0x60a')]}));for(let _0x4c47e3=0x0;_0x4c47e3<_0x1d5a2a[_0x36f14b('0x220b')]['length'];_0x4c47e3++){_0x4af332&&_0x1d5a2a[_0x36f14b('0x220b')][_0x4c47e3]['id']===_0x4af332['id']&&(_0x1d5a2a[_0x36f14b('0x220b')][_0x4c47e3][_0x36f14b('0x319')]=![],_0x1837df['push'](_0x1d5a2a[_0x36f14b('0x220b')][_0x4c47e3]));}_0x1d5a2a['variables']=_0x1837df;}else{if(!_0x4f5cf8['autoAssociation'])return _0x46aa28['userProfileResource'][_0x36f14b('0x1e6e')]({'sectionId':_0x4f5cf8['id']})[_0x36f14b('0xe53')][_0x36f14b('0x683')](function(_0x2c15da){const _0x12ce7d=_0x36f14b,_0x496f23=_0x2e3ca0()['map'](_0x2c15da[_0x12ce7d('0xf5d')],function(_0x4a5aa0){const _0x5ca15d=_0x12ce7d;return _0x2e3ca0()['find'](_0x1d5a2a[_0x5ca15d('0x220b')],{'id':_0x4a5aa0['resourceId']});});let _0x21b251=null;_0x1d5a2a[_0x12ce7d('0x877')]&&(_0x21b251=_0x2e3ca0()[_0x12ce7d('0x1c07')](_0x1d5a2a[_0x12ce7d('0x220b')],{'name':_0x1d5a2a['set']['name']}));if(_0x21b251&&!_0x2e3ca0()[_0x12ce7d('0x7a2')](_0x496f23,['id',_0x21b251['id']])){const _0x57303f=_0x2e3ca0()['find'](_0x1d5a2a[_0x12ce7d('0x220b')],{'id':_0x21b251['id']});_0x57303f[_0x12ce7d('0x319')]=![],_0x496f23[_0x12ce7d('0x1fd0')](_0x57303f);}_0x1d5a2a['variables']=_0x496f23;});}})[_0x33cc8c('0x130a')](function(_0x4b06ac){const _0x3f8a7c=_0x33cc8c;_0x374da6[_0x3f8a7c('0x52a')]({'title':_0x4b06ac[_0x3f8a7c('0x13ee')]?_0x3f8a7c('0x2168')+_0x4b06ac['status']+_0x3f8a7c('0xbf6')+_0x4b06ac['statusText']:'SYSTEM:GETvariables','msg':_0x4b06ac[_0x3f8a7c('0x5a5')]?JSON[_0x3f8a7c('0x258a')](_0x4b06ac[_0x3f8a7c('0x5a5')]):_0x4b06ac['toString']()});});function _0x3ce19b(){const _0x5c2890=_0x33cc8c;_0x1d5a2a[_0x5c2890('0x17f')]=[];const _0x1c0d66=[];_0x1d5a2a['set'][_0x5c2890('0xcf0')]&&_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0xcf0')]['toLowerCase']()===_0x5c2890('0x17cd')&&_0x1d5a2a['set']['appType']===_0x5c2890('0x4d2')&&(_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0xd31')]=_0x45a577[_0x5c2890('0x145a')]?(_0x1d5a2a[_0x5c2890('0x877')]['prefix']||'')+'${EXTEN:'+_0x45a577[_0x5c2890('0x145a')]+'}':(_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0x24fa')]||'')+'${EXTEN}',_0x45a577[_0x5c2890('0x75b')]!==_0x5c2890('0x925')?_0x1d5a2a[_0x5c2890('0x877')]['options'][_0x5c2890('0x824')](_0x5c2890('0x1b1'))<0x0&&(_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0x158e')]+='U(xcally-mixmonitor-context)'):_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0x158e')]=_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0x158e')][_0x5c2890('0x1725')]('U(xcally-mixmonitor-context)',''));if(_0x1d5a2a[_0x5c2890('0x877')]['appType']&&_0x1d5a2a[_0x5c2890('0x877')]['appType']===_0x5c2890('0xbf0')){}else switch((_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0x1d75')]||_0x1d5a2a['set'][_0x5c2890('0x11f3')])[_0x5c2890('0x93a')]()){case _0x5c2890('0x877'):_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0x1407')]=_0x1d5a2a['set'][_0x5c2890('0x60a')]+'='+_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0x1c6b')];break;case _0x5c2890('0xbf0'):break;default:_0x1c0d66[0x0]=_0x1d5a2a['set'][_0x5c2890('0x60a')],_0x1c0d66[0x1]=_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0x1c6b')],_0x1d5a2a[_0x5c2890('0x877')][_0x5c2890('0x1407')]=_0x1c0d66[_0x5c2890('0x1630')]('=');}_0x5a0ffa(_0x1d5a2a['set']);}function _0x5a0ffa(_0x168006){const _0x4df603=_0x33cc8c;_0x3b3235[_0x4df603('0x1715')](_0x168006);}}const _0x1b2580=_0x299e14;_0xc66b86[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0xd15'),'internalroute','api',_0x189033('0xba1'),'crudPermissions'];function _0xc66b86(_0x215a0d,_0x58b922,_0x166173,_0x1ccc78,_0x161888,_0x14d93a,_0x479fcd,_0x2a6d9e){const _0x15770b=_0x189033,_0x21dde6=this;_0x21dde6[_0x15770b('0x11ed')]=_0x479fcd[_0x15770b('0x20b2')](),_0x21dde6['errors']=[],_0x21dde6[_0x15770b('0xf28')]=_0x15770b('0x241c')+(_0x1ccc78['appType']||_0x1ccc78['app'])[_0x15770b('0x80')](),_0x21dde6['voicemail']=angular[_0x15770b('0x1a86')](_0x1ccc78),_0x21dde6['crudPermissions']=_0x2a6d9e,_0x21dde6[_0x15770b('0x258d')]={};if(_0x21dde6[_0x15770b('0x8ac')]['appdata'])switch(_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x11f3')]?_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x11f3')][_0x15770b('0x93a')]():_0x21dde6[_0x15770b('0x8ac')]['app'][_0x15770b('0x93a')]()){case _0x15770b('0xbf0'):break;case _0x15770b('0x205c'):{const _0x3d2858=_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1407')][_0x15770b('0x1fc5')](',');_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1d46')]=_0x3d2858[0x0],_0x21dde6['voicemail'][_0x15770b('0x1a1c')]=_0x3d2858[0x1],_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x6d9')]=_0x3d2858[_0x15770b('0x12c8')](0x2,_0x3d2858[_0x15770b('0x1564')])[_0x15770b('0x1630')](',');}break;case _0x15770b('0xd24'):{const _0x25c997=_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1407')][_0x15770b('0x1fc5')](',');_0x21dde6['voicemail'][_0x15770b('0x2119')]=_0x25c997[0x0],_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x38')]=_0x25c997[0x1],_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x406')]=_0x25c997[0x2],_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1a1c')]=_0x25c997[0x3],_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x6d9')]=_0x25c997['slice'](0x4,_0x25c997['length'])['join'](',');}break;case _0x15770b('0x1db1'):{const _0x326b2b=_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1407')][_0x15770b('0x1fc5')](',');_0x21dde6[_0x15770b('0x8ac')]['accesskeyid']=_0x326b2b[0x0],_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x204a')]=_0x326b2b[0x1],_0x21dde6['voicemail'][_0x15770b('0x5ba')]=_0x326b2b[0x2],_0x21dde6['voicemail'][_0x15770b('0x11a9')]=_0x326b2b[0x3],_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x6d9')]=_0x326b2b[_0x15770b('0x12c8')](0x4,_0x326b2b[_0x15770b('0x1564')])['join'](',');}break;case _0x15770b('0x2408'):{const _0x2f4f1c=_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1407')][_0x15770b('0x1fc5')](',');_0x21dde6['voicemail']['times']=isNaN(_0x2f4f1c[0x0])?_0x2f4f1c[0x0]:parseInt(_0x2f4f1c[0x0],0xa),_0x21dde6['voicemail'][_0x15770b('0x1bcd')]=_0x2f4f1c[_0x15770b('0x12c8')](0x1,_0x2f4f1c[_0x15770b('0x1564')])[_0x15770b('0x1630')](',');}break;case'message':_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1bcd')]=_0x21dde6['voicemail'][_0x15770b('0x1407')];break;case _0x15770b('0x877'):_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x60a')]=_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1407')]['split']('=')[0x0],_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1c6b')]=_0x21dde6['voicemail'][_0x15770b('0x1407')][_0x15770b('0x1fc5')]('=')[0x1];break;case _0x15770b('0x19ae'):_0x21dde6['voicemail'][_0x15770b('0x273a')]=_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1407')];break;default:{const _0x3e70d1=_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1407')][_0x15770b('0x1fc5')](',');_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x1a6b')]=_0x2e3ca0()[_0x15770b('0x173f')](_0x3e70d1[0x0])?_0x3e70d1[0x0]:isNaN(_0x3e70d1[0x0])?_0x3e70d1[0x0]:parseInt(_0x3e70d1[0x0],0xa),_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x158e')]=_0x2e3ca0()['isEmpty'](_0x3e70d1[0x1])?_0x3e70d1[0x1]:isNaN(_0x3e70d1[0x1])?_0x3e70d1[0x1]:parseInt(_0x3e70d1[0x1],0xa);}break;}else{}_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0xcf0')]&&_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0xcf0')]['toLowerCase']()===_0x15770b('0x17cd')&&_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x11f3')][_0x15770b('0x93a')]()===_0x15770b('0x659')&&(_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x24fa')]=_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0xd31')]?_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0xd31')][_0x15770b('0x1fc5')]('$')[0x0]:undefined,_0x21dde6[_0x15770b('0x8ac')]['callerId']=_0x21dde6['voicemail'][_0x15770b('0x73c')]?_0x15770b('0xac1')+_0x21dde6[_0x15770b('0x8ac')][_0x15770b('0x73c')]:undefined);_0x21dde6[_0x15770b('0x79b')]=_0x5f3f30,_0x21dde6[_0x15770b('0xf82')]=_0x6f4dc,_0x479fcd[_0x15770b('0xca1')](_0x15770b('0x20c2'))?_0x14d93a[_0x15770b('0x1a6b')][_0x15770b('0x1e6e')]({'fields':_0x15770b('0x24c5'),'sort':_0x15770b('0x10ae'),'nolimit':_0x15770b('0x26ac')})[_0x15770b('0xe53')][_0x15770b('0x683')](function(_0x1e48bb){const _0x488d14=_0x15770b;_0x21dde6[_0x488d14('0x544')]=_0x1e48bb[_0x488d14('0xf5d')]||[];})[_0x15770b('0x130a')](function(_0x4b551d){const _0x5100df=_0x15770b;_0x166173[_0x5100df('0x52a')]({'title':_0x4b551d[_0x5100df('0x13ee')]?_0x5100df('0x2168')+_0x4b551d[_0x5100df('0x13ee')]+_0x5100df('0xbf6')+_0x4b551d[_0x5100df('0x24a9')]:'SYSTEM:GET_VOICEMAILS','msg':_0x4b551d[_0x5100df('0x5a5')]?JSON[_0x5100df('0x258a')](_0x4b551d[_0x5100df('0x5a5')]):_0x4b551d[_0x5100df('0x1ff0')]()});}):_0x14d93a['voiceMail']['get']({'fields':_0x15770b('0x24c5'),'sort':_0x15770b('0x10ae'),'nolimit':'true'})['$promise']['then'](function(_0x353054){const _0x33392b=_0x15770b;_0x21dde6[_0x33392b('0x544')]=_0x353054['rows']||[];})[_0x15770b('0x683')](function(){const _0x2e052d=_0x15770b;return _0x14d93a['userProfileSection']['get']({'userProfileId':_0x21dde6[_0x2e052d('0x11ed')][_0x2e052d('0x2f')],'sectionId':0x196})[_0x2e052d('0xe53')];})[_0x15770b('0x683')](function(_0x121c3){const _0x13eea1=_0x15770b,_0x42a4ec=_0x121c3&&_0x121c3[_0x13eea1('0xf5d')]?_0x121c3[_0x13eea1('0xf5d')][0x0]:null;if(!_0x42a4ec){const _0x43cc2d=[];let _0x542eba=null;_0x21dde6[_0x13eea1('0x8ac')]&&(_0x542eba=_0x2e3ca0()[_0x13eea1('0x1c07')](_0x21dde6[_0x13eea1('0x544')],{'mailbox':_0x21dde6[_0x13eea1('0x8ac')][_0x13eea1('0x1a6b')]}));for(let _0x47b2a9=0x0;_0x47b2a9<_0x21dde6[_0x13eea1('0x544')][_0x13eea1('0x1564')];_0x47b2a9++){_0x542eba&&_0x21dde6[_0x13eea1('0x544')][_0x47b2a9]['id']===_0x542eba['id']&&(_0x21dde6[_0x13eea1('0x544')][_0x47b2a9][_0x13eea1('0x319')]=![],_0x43cc2d[_0x13eea1('0x1fd0')](_0x21dde6[_0x13eea1('0x544')][_0x47b2a9]));}_0x21dde6[_0x13eea1('0x544')]=_0x43cc2d;}else{if(!_0x42a4ec[_0x13eea1('0x170')])return _0x14d93a[_0x13eea1('0xcf7')][_0x13eea1('0x1e6e')]({'sectionId':_0x42a4ec['id']})[_0x13eea1('0xe53')]['then'](function(_0x3755ef){const _0x5d07b5=_0x13eea1,_0x220e2e=_0x2e3ca0()[_0x5d07b5('0x386')](_0x3755ef['rows'],function(_0x1d6372){const _0xdd8f19=_0x5d07b5;return _0x2e3ca0()[_0xdd8f19('0x1c07')](_0x21dde6[_0xdd8f19('0x544')],{'id':_0x1d6372[_0xdd8f19('0x832')]});});let _0x355a64=null;_0x21dde6[_0x5d07b5('0x8ac')]&&(_0x355a64=_0x2e3ca0()[_0x5d07b5('0x1c07')](_0x21dde6[_0x5d07b5('0x544')],{'mailbox':_0x21dde6['voicemail'][_0x5d07b5('0x1a6b')]}));if(_0x355a64&&!_0x2e3ca0()[_0x5d07b5('0x7a2')](_0x220e2e,['id',_0x355a64['id']])){const _0xbcecbe=_0x2e3ca0()[_0x5d07b5('0x1c07')](_0x21dde6[_0x5d07b5('0x544')],{'id':_0x355a64['id']});_0xbcecbe[_0x5d07b5('0x319')]=![],_0x220e2e[_0x5d07b5('0x1fd0')](_0xbcecbe);}_0x21dde6[_0x5d07b5('0x544')]=_0x220e2e;});}})[_0x15770b('0x130a')](function(_0x319f6b){const _0x206cc4=_0x15770b;_0x166173[_0x206cc4('0x52a')]({'title':_0x319f6b[_0x206cc4('0x13ee')]?_0x206cc4('0x2168')+_0x319f6b['status']+_0x206cc4('0xbf6')+_0x319f6b['statusText']:_0x206cc4('0x20ee'),'msg':_0x319f6b[_0x206cc4('0x5a5')]?JSON[_0x206cc4('0x258a')](_0x319f6b[_0x206cc4('0x5a5')]):_0x319f6b[_0x206cc4('0x1ff0')]()});});function _0x5f3f30(){const _0x24bf88=_0x15770b;_0x21dde6[_0x24bf88('0x17f')]=[];const _0x45ff5b=[];_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0xcf0')]&&_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0xcf0')][_0x24bf88('0x93a')]()===_0x24bf88('0x17cd')&&_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0x11f3')]===_0x24bf88('0x4d2')&&(_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0xd31')]=_0x161888[_0x24bf88('0x145a')]?(_0x21dde6['voicemail'][_0x24bf88('0x24fa')]||'')+_0x24bf88('0x249e')+_0x161888['cutdigits']+'}':(_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0x24fa')]||'')+_0x24bf88('0x20cb'),_0x161888[_0x24bf88('0x75b')]!==_0x24bf88('0x925')?_0x21dde6[_0x24bf88('0x8ac')]['options'][_0x24bf88('0x824')](_0x24bf88('0x1b1'))<0x0&&(_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0x158e')]+=_0x24bf88('0x1b1')):_0x21dde6['voicemail']['options']=_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0x158e')][_0x24bf88('0x1725')](_0x24bf88('0x1b1'),''));if(_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0x11f3')]&&_0x21dde6['voicemail']['appType']==='custom'){}else switch((_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0x1d75')]||_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0x11f3')])[_0x24bf88('0x93a')]()){case'set':_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0x1407')]=_0x21dde6[_0x24bf88('0x8ac')]['name']+'='+_0x21dde6[_0x24bf88('0x8ac')][_0x24bf88('0x1c6b')];break;case _0x24bf88('0xbf0'):break;default:_0x45ff5b[0x0]=_0x21dde6[_0x24bf88('0x8ac')]['voiceMail'],_0x45ff5b[0x1]=_0x21dde6['voicemail']['options'],_0x21dde6[_0x24bf88('0x8ac')]['appdata']=_0x45ff5b[_0x24bf88('0x1630')](',');}_0x6f4dc(_0x21dde6['voicemail']);}function _0x6f4dc(_0x4d11ce){const _0x3ffe8c=_0x15770b;_0x215a0d[_0x3ffe8c('0x1715')](_0x4d11ce);}}const _0x394329=_0xc66b86;_0x7753bf[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xc'),_0x189033('0x22df')];function _0x7753bf(_0x119fac,_0x4871c1,_0x543e0b,_0xd7db6a,_0x1f3514,_0x1a7f9a,_0x3f0773,_0x2fca7c,_0x4e2a60,_0x1e6939,_0x49e305,_0x1ba3bf){const _0x5d97e2=_0x189033,_0x5adc44=this;_0x5adc44[_0x5d97e2('0x11ed')]=_0x1e6939[_0x5d97e2('0x20b2')](),_0x5adc44[_0x5d97e2('0xace')]=_0x1a7f9a,_0x5adc44[_0x5d97e2('0x260a')]=_0x3f0773,_0x5adc44[_0x5d97e2('0x19b2')]=_0x5adc44[_0x5d97e2('0x260a')][_0x5d97e2('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5adc44['location']=_0x4871c1[_0x5d97e2('0x173e')]()+_0x5d97e2('0x20de')+_0x4871c1[_0x5d97e2('0x19ac')](),_0x5adc44[_0x5d97e2('0xc')]=_0x49e305||_0x119fac['params'][_0x5d97e2('0xc')]||{},_0x5adc44[_0x5d97e2('0x22df')]=_0x1ba3bf&&_0x1ba3bf['count']==0x1?_0x1ba3bf[_0x5d97e2('0xf5d')][0x0]:null,_0x5adc44[_0x5d97e2('0x1134')]=_0x1e6939[_0x5d97e2('0x142a')](_0x5adc44['userProfileSection']?_0x5adc44['userProfileSection'][_0x5d97e2('0x1134')]:null),_0x5adc44['hasModulePermissions']={},_0x5adc44[_0x5d97e2('0x517')]=_0x119fac[_0x5d97e2('0x7f2')][_0x5d97e2('0x1904')]||0x0,_0x5adc44[_0x5d97e2('0x2430')]=_0x4e2a60[_0x5d97e2('0x2289')],_0x5adc44[_0x5d97e2('0x749')]=_0x20b3a2,_0x5adc44[_0x5d97e2('0xded')]=_0x10727e,_0x1e6939[_0x5d97e2('0xca1')](_0x5d97e2('0x20c2'))?_0x2fca7c[_0x5d97e2('0x1e4d')][_0x5d97e2('0x1e6e')]({'fields':'id,name','sort':_0x5d97e2('0x60a'),'nolimit':_0x5d97e2('0x26ac')})[_0x5d97e2('0xe53')]['then'](function(_0x46032a){const _0x46568d=_0x5d97e2;_0x5adc44[_0x46568d('0x1693')]=_0x46032a[_0x46568d('0xf5d')]||[];})[_0x5d97e2('0x130a')](function(_0x5c74b8){const _0x595cf5=_0x5d97e2;_0x4e2a60[_0x595cf5('0x52a')]({'title':_0x5c74b8[_0x595cf5('0x13ee')]?_0x595cf5('0x2168')+_0x5c74b8[_0x595cf5('0x13ee')]+_0x595cf5('0xbf6')+_0x5c74b8[_0x595cf5('0x24a9')]:_0x595cf5('0x1379'),'msg':_0x5c74b8[_0x595cf5('0x5a5')]?JSON[_0x595cf5('0x258a')](_0x5c74b8[_0x595cf5('0x5a5')]):_0x5c74b8[_0x595cf5('0x1ff0')]()});}):_0x2fca7c[_0x5d97e2('0x1e4d')][_0x5d97e2('0x1e6e')]({'fields':_0x5d97e2('0xa10'),'sort':'name','nolimit':'true'})[_0x5d97e2('0xe53')]['then'](function(_0xff1485){const _0x1faa77=_0x5d97e2;_0x5adc44[_0x1faa77('0x1693')]=_0xff1485[_0x1faa77('0xf5d')]||[];})[_0x5d97e2('0x683')](function(){const _0x4d24e4=_0x5d97e2;return _0x2fca7c['userProfileSection'][_0x4d24e4('0x1e6e')]({'userProfileId':_0x5adc44[_0x4d24e4('0x11ed')][_0x4d24e4('0x2f')],'sectionId':0x195})[_0x4d24e4('0xe53')];})[_0x5d97e2('0x683')](function(_0x2825b6){const _0x442db5=_0x5d97e2,_0x31cc8f=_0x2825b6&&_0x2825b6[_0x442db5('0xf5d')]?_0x2825b6[_0x442db5('0xf5d')][0x0]:null;if(!_0x31cc8f)return _0x2fca7c[_0x442db5('0x1e4d')][_0x442db5('0x1e6e')]({'fields':_0x442db5('0xa10'),'sort':_0x442db5('0x60a'),'nolimit':'true','defaultEntry':0x1})[_0x442db5('0xe53')][_0x442db5('0x683')](function(_0x2fc309){const _0x4244db=_0x442db5;_0x5adc44[_0x4244db('0x1693')]=_0x2fc309[_0x4244db('0xf5d')]||[];});else{if(!_0x31cc8f[_0x442db5('0x170')])return _0x2fca7c['userProfileResource'][_0x442db5('0x1e6e')]({'sectionId':_0x31cc8f['id']})[_0x442db5('0xe53')][_0x442db5('0x683')](function(_0x47d1cd){const _0x37c8df=_0x442db5,_0x52ba4e=_0x2e3ca0()[_0x37c8df('0x386')](_0x47d1cd['rows'],function(_0x3a5f22){const _0xd9bb83=_0x37c8df;return _0x2e3ca0()[_0xd9bb83('0x1c07')](_0x5adc44[_0xd9bb83('0x1693')],{'id':_0x3a5f22[_0xd9bb83('0x832')]});});let _0x186341=null;_0x5adc44['internalroute']&&(_0x186341=_0x2e3ca0()[_0x37c8df('0x1c07')](_0x5adc44[_0x37c8df('0x1693')],{'name':_0x5adc44['internalroute']['context']}));if(_0x186341&&!_0x2e3ca0()[_0x37c8df('0x7a2')](_0x52ba4e,['id',_0x186341['id']])){const _0x184583=_0x2e3ca0()[_0x37c8df('0x1c07')](_0x5adc44[_0x37c8df('0x1693')],{'id':_0x186341['id']});_0x184583['canSelect']=![],_0x52ba4e[_0x37c8df('0x1fd0')](_0x184583);}_0x5adc44[_0x37c8df('0x1693')]=_0x52ba4e;});}})[_0x5d97e2('0x130a')](function(_0x29c249){const _0x3d6d22=_0x5d97e2;_0x4e2a60[_0x3d6d22('0x52a')]({'title':_0x29c249[_0x3d6d22('0x13ee')]?_0x3d6d22('0x2168')+_0x29c249[_0x3d6d22('0x13ee')]+_0x3d6d22('0xbf6')+_0x29c249[_0x3d6d22('0x24a9')]:_0x3d6d22('0x1a60'),'msg':_0x29c249[_0x3d6d22('0x5a5')]?JSON[_0x3d6d22('0x258a')](_0x29c249[_0x3d6d22('0x5a5')]):_0x29c249['toString']()});});function _0x20b3a2(){_0x119fac['go']('app.voice.internalroutes',{},{'reload':'app.voice.internalroutes'});}function _0x10727e(){const _0x2446ce=_0x5d97e2;_0x2fca7c[_0x2446ce('0x14cb')][_0x2446ce('0x2480')]({'id':_0x5adc44[_0x2446ce('0xc')]['id']},_0x5adc44[_0x2446ce('0xc')])[_0x2446ce('0xe53')][_0x2446ce('0x683')](function(){const _0x13d0d8=_0x2446ce;_0x4e2a60['success']({'title':_0x13d0d8('0x9d5'),'msg':_0x5adc44['internalroute']['name']?_0x5adc44[_0x13d0d8('0xc')]['name']+_0x13d0d8('0x96c'):''});})['catch'](function(_0x28547f){const _0x5e5ac9=_0x2446ce;_0x4e2a60[_0x5e5ac9('0x52a')]({'title':_0x28547f['status']?_0x5e5ac9('0x2168')+_0x28547f['status']+_0x5e5ac9('0xbf6')+_0x28547f['statusText']:_0x5e5ac9('0xb10'),'msg':_0x28547f[_0x5e5ac9('0x5a5')]?JSON['stringify'](_0x28547f['data']):_0x28547f[_0x5e5ac9('0x1ff0')]()});});}}const _0x5e8327=_0x7753bf,_0x1ca3d0=_0x180212['p']+'src/js/modules/main/apps/voice/views/internalroutes/create/dialog.html/dialog.html';_0x207c02[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state','$mdSidenav',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),'internalroutes',_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),'msUtils','toasty',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x207c02(_0x5ac7a9,_0x34f999,_0x402318,_0x52152e,_0x2bebd2,_0xb4aade,_0x2f8966,_0x182c3c,_0x34cb02,_0x37e61a,_0x7418d3,_0x2939a8,_0x218c8e,_0x9d341e,_0x31bed8,_0x402ef7,_0x319872){const _0x248d65=_0x189033,_0x8e5128=this;_0x8e5128[_0x248d65('0xace')]=_0x402ef7,_0x8e5128[_0x248d65('0x260a')]=_0x319872,_0x8e5128[_0x248d65('0x11ed')]=_0x31bed8['getCurrentUser'](),_0x8e5128[_0x248d65('0xffd')]=_0x34cb02||{'count':0x0,'rows':[]},_0x8e5128[_0x248d65('0x2a')]=_0x37e61a,_0x8e5128[_0x248d65('0x22df')]=_0x7418d3&&_0x7418d3[_0x248d65('0x50d')]==0x1?_0x7418d3[_0x248d65('0xf5d')][0x0]:null,_0x8e5128[_0x248d65('0x1134')]=_0x31bed8['parseCrudPermissions'](_0x8e5128[_0x248d65('0x22df')]?_0x8e5128[_0x248d65('0x22df')][_0x248d65('0x1134')]:null),_0x8e5128[_0x248d65('0x5c4')]=_0x248d65('0xffd'),_0x8e5128[_0x248d65('0x247')]='',_0x8e5128[_0x248d65('0x1ce2')]=null,_0x8e5128[_0x248d65('0x1cbc')]=[],_0x8e5128[_0x248d65('0x23a2')]={'fields':_0x248d65('0xb7'),'type':_0x248d65('0x1d43'),'sort':_0x248d65('0xc36'),'VoiceExtensionId':_0x248d65('0x13c'),'limit':0xa,'page':0x1},_0x8e5128[_0x248d65('0xc63')]=_0x4c797b,_0x8e5128[_0x248d65('0x194f')]=_0x157d83,_0x8e5128['success']=_0x37447a,_0x8e5128[_0x248d65('0x193a')]=_0x40ec9b,_0x8e5128[_0x248d65('0x1740')]=_0x2b9e8b,_0x8e5128[_0x248d65('0x958')]=_0x489d24,_0x8e5128[_0x248d65('0x8f5')]=_0x2d7f49,_0x8e5128['deleteSelectedInternalRoutes']=_0x4dfbf3,_0x8e5128[_0x248d65('0x1115')]=_0x3adf93,_0x8e5128[_0x248d65('0x20f2')]=_0x39b41c,_0x31bed8['hasRole'](_0x248d65('0x20c2'))?_0x2939a8[_0x248d65('0x1e4d')][_0x248d65('0x1e6e')]({'fields':_0x248d65('0xa10'),'sort':_0x248d65('0x60a'),'nolimit':'true'})[_0x248d65('0xe53')]['then'](function(_0x4cc4e4){const _0x146233=_0x248d65;_0x8e5128[_0x146233('0x1693')]=_0x4cc4e4[_0x146233('0xf5d')]||[];})[_0x248d65('0x130a')](function(_0x2600ad){const _0x51f0f9=_0x248d65;_0x9d341e[_0x51f0f9('0x52a')]({'title':_0x2600ad[_0x51f0f9('0x13ee')]?_0x51f0f9('0x2168')+_0x2600ad[_0x51f0f9('0x13ee')]+_0x51f0f9('0xbf6')+_0x2600ad['statusText']:_0x51f0f9('0x1379'),'msg':_0x2600ad[_0x51f0f9('0x5a5')]?JSON[_0x51f0f9('0x258a')](_0x2600ad[_0x51f0f9('0x5a5')]):_0x2600ad[_0x51f0f9('0x1ff0')]()});}):_0x2939a8[_0x248d65('0x1e4d')][_0x248d65('0x1e6e')]({'fields':_0x248d65('0xa10'),'sort':'name','nolimit':_0x248d65('0x26ac')})['$promise']['then'](function(_0x3686e1){const _0xcbbed6=_0x248d65;_0x8e5128['contexts']=_0x3686e1[_0xcbbed6('0xf5d')]||[];})[_0x248d65('0x683')](function(){const _0x33a3ea=_0x248d65;return _0x2939a8['userProfileSection'][_0x33a3ea('0x1e6e')]({'userProfileId':_0x8e5128[_0x33a3ea('0x11ed')][_0x33a3ea('0x2f')],'sectionId':0x195})[_0x33a3ea('0xe53')];})[_0x248d65('0x683')](function(_0x1e578b){const _0x98c89f=_0x248d65,_0xc3b98f=_0x1e578b&&_0x1e578b[_0x98c89f('0xf5d')]?_0x1e578b[_0x98c89f('0xf5d')][0x0]:null;if(!_0xc3b98f)return _0x2939a8[_0x98c89f('0x1e4d')]['get']({'fields':_0x98c89f('0xa10'),'sort':_0x98c89f('0x60a'),'nolimit':_0x98c89f('0x26ac'),'defaultEntry':0x1})['$promise'][_0x98c89f('0x683')](function(_0x37abde){const _0x31b453=_0x98c89f;_0x8e5128['contexts']=_0x37abde[_0x31b453('0xf5d')]||[];});else{if(!_0xc3b98f[_0x98c89f('0x170')])return _0x2939a8[_0x98c89f('0xcf7')][_0x98c89f('0x1e6e')]({'sectionId':_0xc3b98f['id']})[_0x98c89f('0xe53')][_0x98c89f('0x683')](function(_0x17db35){const _0x2d72bb=_0x98c89f,_0x3f0e8f=_0x2e3ca0()['map'](_0x17db35['rows'],function(_0x46f443){const _0x335429=a0_0x4e0a;return _0x2e3ca0()[_0x335429('0x1c07')](_0x8e5128['contexts'],{'id':_0x46f443[_0x335429('0x832')]});});let _0x3f1463=null;_0x8e5128[_0x2d72bb('0xc')]&&(_0x3f1463=_0x2e3ca0()[_0x2d72bb('0x1c07')](_0x8e5128[_0x2d72bb('0x1693')],{'name':_0x8e5128['internalroute'][_0x2d72bb('0x22d3')]}));if(_0x3f1463&&!_0x2e3ca0()[_0x2d72bb('0x7a2')](_0x3f0e8f,['id',_0x3f1463['id']])){const _0x45e80c=_0x2e3ca0()[_0x2d72bb('0x1c07')](_0x8e5128['contexts'],{'id':_0x3f1463['id']});_0x45e80c[_0x2d72bb('0x319')]=![],_0x3f0e8f['push'](_0x45e80c);}_0x8e5128[_0x2d72bb('0x1693')]=_0x3f0e8f;});}})[_0x248d65('0x130a')](function(_0x1ab8ba){const _0x42d6b1=_0x248d65;_0x9d341e[_0x42d6b1('0x52a')]({'title':_0x1ab8ba[_0x42d6b1('0x13ee')]?_0x42d6b1('0x2168')+_0x1ab8ba[_0x42d6b1('0x13ee')]+'\x20-\x20'+_0x1ab8ba[_0x42d6b1('0x24a9')]:'SYSTEM:GETcontexts','msg':_0x1ab8ba['data']?JSON['stringify'](_0x1ab8ba[_0x42d6b1('0x5a5')]):_0x1ab8ba[_0x42d6b1('0x1ff0')]()});});function _0x4c797b(_0x2d5e44){const _0x39995d=_0x248d65;_0x402318['go'](_0x39995d('0x1ea2'),{'id':_0x2d5e44['id'],'internalroute':_0x2d5e44,'crudPermissions':_0x8e5128[_0x39995d('0x1134')]});}function _0x157d83(_0x4c3cb0,_0x19484e){const _0x135352=_0x248d65,_0x40be63=_0x2bebd2['confirm']()[_0x135352('0xf28')](_0x135352('0x1b01')+_0x2e3ca0()[_0x135352('0x1e03')](_0x135352('0xc'))+'?')[_0x135352('0x26e3')](''+(_0x4c3cb0[_0x135352('0x60a')]||_0x135352('0xc'))+_0x135352('0x20f1')+_0x135352('0x1ee7'))[_0x135352('0x1040')](_0x135352('0x171a'))[_0x135352('0xe42')](_0x19484e)['ok']('OK')[_0x135352('0x19fb')](_0x135352('0x16b8'));_0x2bebd2[_0x135352('0x1d4')](_0x40be63)[_0x135352('0x683')](function(){_0x489d24(_0x4c3cb0);},function(){const _0x205ae1=_0x135352;console[_0x205ae1('0x1b2b')](_0x205ae1('0x16b8'));});}let _0x1012cc=!![],_0x199fdc=0x1;_0x5ac7a9['$watch']('vm.query.filter',function(_0x1914d1,_0xb4de02){const _0x33fd83=_0x248d65;_0x1012cc?_0x2f8966(function(){_0x1012cc=![];}):(!_0xb4de02&&(_0x199fdc=_0x8e5128[_0x33fd83('0x23a2')]['page']),_0x1914d1!==_0xb4de02&&(_0x8e5128['query'][_0x33fd83('0xdf8')]=0x1),!_0x1914d1&&(_0x8e5128['query']['page']=_0x199fdc),_0x8e5128[_0x33fd83('0x193a')]());});function _0x37447a(_0x290153){_0x8e5128['internalroutes']=_0x290153||{'count':0x0,'rows':[]};}function _0x40ec9b(){const _0x54b946=_0x248d65;_0x8e5128[_0x54b946('0x23a2')][_0x54b946('0x1cc8')]=(_0x8e5128[_0x54b946('0x23a2')][_0x54b946('0xdf8')]-0x1)*_0x8e5128[_0x54b946('0x23a2')][_0x54b946('0x6f0')],_0x31bed8[_0x54b946('0xca1')]('admin')?_0x8e5128['promise']=_0x2939a8[_0x54b946('0x14cb')][_0x54b946('0x1e6e')](_0x8e5128[_0x54b946('0x23a2')],_0x37447a)['$promise']:(_0x8e5128[_0x54b946('0x23a2')]['id']=_0x8e5128['userProfile']['id'],_0x8e5128[_0x54b946('0x23a2')][_0x54b946('0x1aa')]='InternalRoutes',_0x8e5128[_0x54b946('0x1883')]=_0x2939a8['userProfile']['getResources'](_0x8e5128['query'],_0x37447a)['$promise']);}function _0x2b9e8b(_0x48ea24,_0x5d55b2){const _0x2ba6c6=_0x248d65;_0x2bebd2[_0x2ba6c6('0x1d4')]({'controller':_0x2ba6c6('0x6af'),'controllerAs':'vm','templateUrl':_0x1ca3d0,'parent':angular[_0x2ba6c6('0x1fcc')](_0xb4aade[_0x2ba6c6('0x18e5')]),'targetEvent':_0x48ea24,'clickOutsideToClose':!![],'locals':{'internalroute':_0x5d55b2,'internalroutes':_0x8e5128[_0x2ba6c6('0xffd')][_0x2ba6c6('0xf5d')],'license':_0x8e5128['license'],'setting':_0x8e5128[_0x2ba6c6('0x260a')],'crudPermissions':_0x8e5128['crudPermissions']}});}function _0x489d24(_0x20ab92){const _0x4ece35=_0x248d65;_0x2939a8[_0x4ece35('0x14cb')]['delete']({'id':_0x20ab92['id']})[_0x4ece35('0xe53')][_0x4ece35('0x683')](function(){const _0x202687=_0x4ece35;_0x2e3ca0()[_0x202687('0x3ec')](_0x8e5128[_0x202687('0xffd')][_0x202687('0xf5d')],{'id':_0x20ab92['id']}),_0x8e5128[_0x202687('0xffd')][_0x202687('0x50d')]-=0x1,!_0x8e5128[_0x202687('0xffd')][_0x202687('0xf5d')]['length']&&_0x8e5128[_0x202687('0x193a')](),_0x9d341e[_0x202687('0x53')]({'title':_0x2e3ca0()[_0x202687('0x1e03')](_0x202687('0x1e61'))+'\x20deleted!','msg':_0x20ab92[_0x202687('0x60a')]?_0x20ab92[_0x202687('0x60a')]+_0x202687('0x194d'):''});})[_0x4ece35('0x130a')](function(_0xdcc4e5){const _0x19ea26=_0x4ece35;if(_0xdcc4e5[_0x19ea26('0x5a5')]&&_0xdcc4e5[_0x19ea26('0x5a5')][_0x19ea26('0x17f')]&&_0xdcc4e5[_0x19ea26('0x5a5')][_0x19ea26('0x17f')][_0x19ea26('0x1564')]){_0x8e5128[_0x19ea26('0x17f')]=_0xdcc4e5[_0x19ea26('0x5a5')][_0x19ea26('0x17f')]||[{'message':_0xdcc4e5['toString'](),'type':_0x19ea26('0x2602')}];for(let _0x2314a9=0x0;_0x2314a9<_0xdcc4e5['data'][_0x19ea26('0x17f')][_0x19ea26('0x1564')];_0x2314a9++){_0x9d341e[_0x19ea26('0x52a')]({'title':_0xdcc4e5[_0x19ea26('0x5a5')][_0x19ea26('0x17f')][_0x2314a9]['type'],'msg':_0xdcc4e5[_0x19ea26('0x5a5')][_0x19ea26('0x17f')][_0x2314a9]['message']});}}else _0x9d341e[_0x19ea26('0x52a')]({'title':_0xdcc4e5[_0x19ea26('0x13ee')]?_0x19ea26('0x2168')+_0xdcc4e5[_0x19ea26('0x13ee')]+_0x19ea26('0xbf6')+_0xdcc4e5[_0x19ea26('0x24a9')]:_0x19ea26('0x2602'),'msg':_0xdcc4e5[_0x19ea26('0x5a5')]?JSON[_0x19ea26('0x258a')](_0xdcc4e5[_0x19ea26('0x5a5')]['message']):_0xdcc4e5['message']||_0xdcc4e5[_0x19ea26('0x1ff0')]()});});}function _0x2d7f49(){const _0x21c081=_0x248d65,_0x419f03=angular['copy'](_0x8e5128[_0x21c081('0x1cbc')]);return _0x8e5128['selectedInternalRoutes']=[],_0x419f03;}function _0x4dfbf3(_0x2fc640){const _0xfbf00b=_0x248d65,_0x652d6c=_0x2bebd2[_0xfbf00b('0x1c6f')]()[_0xfbf00b('0xf28')](_0xfbf00b('0x27f4'))[_0xfbf00b('0x26e3')](''+_0x8e5128[_0xfbf00b('0x1cbc')][_0xfbf00b('0x1564')]+_0xfbf00b('0x93c')+_0xfbf00b('0x1ee7'))[_0xfbf00b('0x1040')](_0xfbf00b('0x15b0'))[_0xfbf00b('0xe42')](_0x2fc640)['ok']('OK')[_0xfbf00b('0x19fb')]('CANCEL');_0x2bebd2[_0xfbf00b('0x1d4')](_0x652d6c)['then'](function(){const _0x507244=_0xfbf00b;_0x8e5128[_0x507244('0x1cbc')]['forEach'](function(_0x247109){_0x489d24(_0x247109);}),_0x8e5128[_0x507244('0x1cbc')]=[];});}function _0x3adf93(){const _0x1875e0=_0x248d65;_0x8e5128[_0x1875e0('0x1cbc')]=[];}function _0x39b41c(){const _0x563d56=_0x248d65;_0x8e5128[_0x563d56('0x1cbc')]=_0x8e5128[_0x563d56('0xffd')][_0x563d56('0xf5d')];}}const _0x2e1afc=_0x207c02;_0x738d30['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0xd89'),_0x189033('0x1ebc'),'api','Auth',_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x738d30(_0x415e27,_0x2897b1,_0xcad2a0,_0x22055f,_0x703e13,_0x4cc167,_0x7f1467,_0x35336f,_0xc5a3fa,_0x472f8b,_0x1125e1,_0x7a21bb,_0x5dcef2,_0x554794){const _0x150baf=_0x189033,_0x1de75e=this;_0x1de75e[_0x150baf('0x11ed')]=_0x1125e1[_0x150baf('0x20b2')](),_0x1de75e[_0x150baf('0x17f')]=[],_0x1de75e[_0x150baf('0x260a')]=_0x5dcef2,_0x1de75e['license']=_0x7a21bb,_0x1de75e[_0x150baf('0x1134')]=_0x554794,_0x1de75e[_0x150baf('0x258d')]={},_0x1de75e[_0x150baf('0x19b2')]=_0x1de75e['setting']&&_0x1de75e[_0x150baf('0x260a')][_0x150baf('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1de75e[_0x150baf('0xf28')]=_0x150baf('0x1e0b'),_0x1de75e[_0x150baf('0x1ebc')]=angular['copy'](_0xc5a3fa),_0x1de75e[_0x150baf('0xd89')]=_0x35336f,_0x1de75e['newMusicOnHold']=![];!_0x1de75e[_0x150baf('0x1ebc')]&&(_0x1de75e['musiconhold']={'mode':'files'},_0x1de75e[_0x150baf('0xf28')]='VOICE.NEW_MUSICONHOLD',_0x1de75e[_0x150baf('0x7dd')]=!![]);_0x1de75e[_0x150baf('0x1048')]=_0x56bea1,_0x1de75e['saveMusicOnHold']=_0x5560d2,_0x1de75e[_0x150baf('0x1018')]=_0x20b96b,_0x1de75e[_0x150baf('0x16b3')]=_0x5c4308,_0x1de75e[_0x150baf('0xf82')]=_0x1e8b25;function _0x56bea1(){const _0x27231a=_0x150baf;_0x1de75e['errors']=[],_0x472f8b['voiceMusicOnHold'][_0x27231a('0xb0a')](_0x1de75e['musiconhold'])[_0x27231a('0xe53')][_0x27231a('0x683')](function(_0x5b6260){const _0x40866=_0x27231a;_0x1de75e['musiconholds'][_0x40866('0x1167')](_0x5b6260[_0x40866('0x24e1')]()),_0x7f1467[_0x40866('0x53')]({'title':_0x40866('0x1c80'),'msg':_0x1de75e[_0x40866('0x1ebc')][_0x40866('0x60a')]?_0x1de75e[_0x40866('0x1ebc')][_0x40866('0x60a')]+_0x40866('0x14b5'):''}),_0x1e8b25(_0x5b6260);})[_0x27231a('0x130a')](function(_0x1ce68b){const _0x3bf4ed=_0x27231a;if(_0x1ce68b[_0x3bf4ed('0x5a5')]&&_0x1ce68b[_0x3bf4ed('0x5a5')][_0x3bf4ed('0x17f')]&&_0x1ce68b[_0x3bf4ed('0x5a5')][_0x3bf4ed('0x17f')]['length']){_0x1de75e[_0x3bf4ed('0x17f')]=_0x1ce68b['data'][_0x3bf4ed('0x17f')]||[{'message':_0x1ce68b[_0x3bf4ed('0x1ff0')](),'type':_0x3bf4ed('0x98b')}];for(let _0x1c8568=0x0;_0x1c8568<_0x1ce68b['data']['errors']['length'];_0x1c8568+=0x1){_0x7f1467[_0x3bf4ed('0x52a')]({'title':_0x1ce68b[_0x3bf4ed('0x5a5')]['errors'][_0x1c8568]['type'],'msg':_0x1ce68b[_0x3bf4ed('0x5a5')]['errors'][_0x1c8568][_0x3bf4ed('0x8c2')]});}}else _0x7f1467[_0x3bf4ed('0x52a')]({'title':_0x1ce68b['status']?_0x3bf4ed('0x2168')+_0x1ce68b['status']+_0x3bf4ed('0xbf6')+_0x1ce68b[_0x3bf4ed('0x24a9')]:_0x3bf4ed('0x98b'),'msg':_0x1ce68b[_0x3bf4ed('0x5a5')]?JSON[_0x3bf4ed('0x258a')](_0x1ce68b[_0x3bf4ed('0x5a5')][_0x3bf4ed('0x8c2')]):_0x1ce68b[_0x3bf4ed('0x1ff0')]()});});}function _0x5560d2(){const _0x1061e1=_0x150baf;_0x1de75e[_0x1061e1('0x17f')]=[],_0x472f8b[_0x1061e1('0x0')]['update']({'id':_0x1de75e[_0x1061e1('0x1ebc')]['id']},_0x1de75e['musiconhold'])[_0x1061e1('0xe53')]['then'](function(_0x5720f2){const _0x574549=_0x1061e1,_0x38f36c=_0x2e3ca0()[_0x574549('0x1c07')](_0x1de75e[_0x574549('0xd89')],{'id':_0x5720f2['id']});_0x38f36c&&_0x2e3ca0()['merge'](_0x38f36c,_0x2e3ca0()['pick'](_0x5720f2[_0x574549('0x24e1')](),_0x2e3ca0()[_0x574549('0x55e')](_0x38f36c))),_0x7f1467[_0x574549('0x53')]({'title':_0x574549('0x113e'),'msg':_0x1de75e[_0x574549('0x1ebc')][_0x574549('0x60a')]?_0x1de75e[_0x574549('0x1ebc')][_0x574549('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x1e8b25(_0x5720f2);})[_0x1061e1('0x130a')](function(_0x1d957d){const _0x7aa67a=_0x1061e1;if(_0x1d957d['data']&&_0x1d957d[_0x7aa67a('0x5a5')][_0x7aa67a('0x17f')]&&_0x1d957d['data'][_0x7aa67a('0x17f')][_0x7aa67a('0x1564')]){_0x1de75e[_0x7aa67a('0x17f')]=_0x1d957d[_0x7aa67a('0x5a5')][_0x7aa67a('0x17f')]||[{'message':_0x1d957d[_0x7aa67a('0x1ff0')](),'type':_0x7aa67a('0x100f')}];for(let _0x4d52d7=0x0;_0x4d52d7<_0x1d957d['data'][_0x7aa67a('0x17f')][_0x7aa67a('0x1564')];_0x4d52d7++){_0x7f1467['error']({'title':_0x1d957d[_0x7aa67a('0x5a5')][_0x7aa67a('0x17f')][_0x4d52d7][_0x7aa67a('0xcf0')],'msg':_0x1d957d['data'][_0x7aa67a('0x17f')][_0x4d52d7][_0x7aa67a('0x8c2')]});}}else _0x7f1467[_0x7aa67a('0x52a')]({'title':_0x1d957d['status']?_0x7aa67a('0x2168')+_0x1d957d[_0x7aa67a('0x13ee')]+'\x20-\x20'+_0x1d957d[_0x7aa67a('0x24a9')]:_0x7aa67a('0x100f'),'msg':_0x1d957d[_0x7aa67a('0x5a5')]?JSON[_0x7aa67a('0x258a')](_0x1d957d[_0x7aa67a('0x5a5')][_0x7aa67a('0x8c2')]):_0x1d957d[_0x7aa67a('0x1ff0')]()});});}function _0x20b96b(_0x463115){const _0x21858e=_0x150baf;_0x1de75e['errors']=[];const _0x3c6103=_0x22055f[_0x21858e('0x1c6f')]()['title'](_0x21858e('0x4d'))['content']('The\x20musiconhold\x20will\x20be\x20deleted.')[_0x21858e('0x1040')]('Delete\x20MusicOnHold')['ok'](_0x21858e('0x2307'))[_0x21858e('0x19fb')](_0x21858e('0x253a'))[_0x21858e('0xe42')](_0x463115);_0x22055f[_0x21858e('0x1d4')](_0x3c6103)[_0x21858e('0x683')](function(){const _0x71caaf=_0x21858e;_0x472f8b['voiceMusicOnHold'][_0x71caaf('0xd7e')]({'id':_0x1de75e[_0x71caaf('0x1ebc')]['id']})['$promise'][_0x71caaf('0x683')](function(){const _0x32d1cc=_0x71caaf;_0x2e3ca0()['remove'](_0x1de75e[_0x32d1cc('0xd89')],{'id':_0x1de75e[_0x32d1cc('0x1ebc')]['id']}),_0x7f1467[_0x32d1cc('0x53')]({'title':_0x32d1cc('0x2653'),'msg':(_0x1de75e['musiconhold'][_0x32d1cc('0x60a')]||_0x32d1cc('0x1ebc'))+'\x20has\x20been\x20deleted!'}),_0x1e8b25(_0x1de75e[_0x32d1cc('0x1ebc')]);})[_0x71caaf('0x130a')](function(_0x47e5b5){const _0x122be1=_0x71caaf;if(_0x47e5b5[_0x122be1('0x5a5')]&&_0x47e5b5['data'][_0x122be1('0x17f')]&&_0x47e5b5[_0x122be1('0x5a5')]['errors']['length']){_0x1de75e[_0x122be1('0x17f')]=_0x47e5b5[_0x122be1('0x5a5')]['errors']||[{'message':_0x47e5b5['toString'](),'type':_0x122be1('0x2853')}];for(let _0xc8b435=0x0;_0xc8b435<_0x47e5b5[_0x122be1('0x5a5')][_0x122be1('0x17f')][_0x122be1('0x1564')];_0xc8b435++){_0x7f1467['error']({'title':_0x47e5b5[_0x122be1('0x5a5')][_0x122be1('0x17f')][_0xc8b435]['type'],'msg':_0x47e5b5[_0x122be1('0x5a5')][_0x122be1('0x17f')][_0xc8b435]['message']});}}else _0x7f1467['error']({'title':_0x47e5b5[_0x122be1('0x13ee')]?'API:'+_0x47e5b5[_0x122be1('0x13ee')]+_0x122be1('0xbf6')+_0x47e5b5[_0x122be1('0x24a9')]:_0x122be1('0x2853'),'msg':_0x47e5b5[_0x122be1('0x5a5')]?JSON[_0x122be1('0x258a')](_0x47e5b5[_0x122be1('0x5a5')]['message']):_0x47e5b5['message']||_0x47e5b5[_0x122be1('0x1ff0')]()});});},function(){});}function _0x5c4308(_0xea1a73){return _0xea1a73===null?undefined:new Date(_0xea1a73);}function _0x1e8b25(_0xb7c4ea){const _0x53c75a=_0x150baf;_0x22055f[_0x53c75a('0x1715')](_0xb7c4ea);}}const _0x45af5b=_0x738d30,_0x2e796d=_0x180212['p']+_0x189033('0x16a0');_0x3a8fa2[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),'$timeout',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x3a8fa2(_0xc38f53,_0x1b37ac,_0x44b894,_0x291d1f,_0x176a67,_0x30338d,_0x54a86d,_0x2e0ec2,_0x1cf88f,_0xaf1aaa,_0x3e9f58){const _0x3b25ff=_0x189033,_0x496d59=this;_0x496d59[_0x3b25ff('0x11ed')]=_0x3e9f58[_0x3b25ff('0x20b2')](),_0x496d59[_0x3b25ff('0x1ebc')]={},_0x496d59['musiconholdMohSounds']={'count':0x0,'rows':[]},_0x496d59[_0x3b25ff('0x166c')]=[],_0x496d59[_0x3b25ff('0x1134')],_0x496d59[_0x3b25ff('0x23a2')]={'fields':'createdAt,updatedAt,id,save_name,converted_format,audio','limit':0xa,'page':0x1},_0x496d59[_0x3b25ff('0x12f3')]=_0x1c0111,_0x496d59[_0x3b25ff('0x26eb')]=_0xabd03d,_0x496d59['voiceMusicOnHoldDownload']=_0x4c1376,_0x496d59[_0x3b25ff('0x53')]=_0x45d466,_0x496d59[_0x3b25ff('0x1cda')]=_0x543138,_0x496d59[_0x3b25ff('0x8b2')]=_0x2a6b93,_0x496d59[_0x3b25ff('0x2652')]=_0x396c2e,_0x496d59[_0x3b25ff('0x1001')]=_0x2f123a,_0x496d59[_0x3b25ff('0xa28')]=_0x5c779a,_0x3e9f58[_0x3b25ff('0xca1')](_0x3b25ff('0x20c2'))?_0xaf1aaa[_0x3b25ff('0x1638')][_0x3b25ff('0x1e6e')]({'fields':_0x3b25ff('0xa10'),'sort':_0x3b25ff('0x60a')})[_0x3b25ff('0xe53')][_0x3b25ff('0x683')](function(_0x25b798){const _0x5901dd=_0x3b25ff;_0x496d59[_0x5901dd('0x11d2')]=_0x25b798[_0x5901dd('0xf5d')]||[];})[_0x3b25ff('0x130a')](function(_0x4bd22c){const _0x294828=_0x3b25ff;_0x1cf88f['error']({'title':_0x4bd22c[_0x294828('0x13ee')]?_0x294828('0x2168')+_0x4bd22c[_0x294828('0x13ee')]+'\x20-\x20'+_0x4bd22c['statusText']:'SYSTEM:GET_SOUNDS','msg':_0x4bd22c[_0x294828('0x5a5')]?JSON[_0x294828('0x258a')](_0x4bd22c['data']):_0x4bd22c[_0x294828('0x1ff0')]()});}):_0xaf1aaa['sound'][_0x3b25ff('0x1e6e')]({'fields':_0x3b25ff('0xa10'),'sort':_0x3b25ff('0x60a')})[_0x3b25ff('0xe53')]['then'](function(_0x1399f3){const _0x1f190f=_0x3b25ff;_0x496d59['sounds']=_0x1399f3[_0x1f190f('0xf5d')]||[];})[_0x3b25ff('0x683')](function(){const _0x21197d=_0x3b25ff;return _0xaf1aaa['userProfileSection'][_0x21197d('0x1e6e')]({'userProfileId':_0x496d59[_0x21197d('0x11ed')]['userProfileId'],'sectionId':0x3ef})[_0x21197d('0xe53')];})[_0x3b25ff('0x683')](function(_0x52d755){const _0x48eaf0=_0x3b25ff,_0x4f57d9=_0x52d755&&_0x52d755['rows']?_0x52d755[_0x48eaf0('0xf5d')][0x0]:null;if(!_0x4f57d9){const _0x2af2b3=[];let _0x471a6d=null;_0x496d59['musiconhold']&&(_0x471a6d=_0x2e3ca0()[_0x48eaf0('0x1c07')](_0x496d59[_0x48eaf0('0x11d2')],{'id':Number(_0x496d59['musiconhold']['id'])}));for(let _0x5d64ef=0x0;_0x5d64ef<_0x496d59[_0x48eaf0('0x11d2')][_0x48eaf0('0x1564')];_0x5d64ef++){_0x471a6d&&_0x496d59['sounds'][_0x5d64ef]['id']===_0x471a6d['id']&&(_0x496d59['sounds'][_0x5d64ef][_0x48eaf0('0x319')]=![],_0x2af2b3[_0x48eaf0('0x1fd0')](_0x496d59[_0x48eaf0('0x11d2')][_0x5d64ef]));}_0x496d59[_0x48eaf0('0x11d2')]=_0x2af2b3;}else{if(!_0x4f57d9[_0x48eaf0('0x170')])return _0xaf1aaa[_0x48eaf0('0xcf7')][_0x48eaf0('0x1e6e')]({'sectionId':_0x4f57d9['id']})[_0x48eaf0('0xe53')][_0x48eaf0('0x683')](function(_0x31c9f0){const _0x44132c=_0x48eaf0,_0x26e229=_0x2e3ca0()[_0x44132c('0x386')](_0x31c9f0[_0x44132c('0xf5d')],function(_0x4278ea){const _0x23efd0=_0x44132c;return _0x2e3ca0()[_0x23efd0('0x1c07')](_0x496d59['sounds'],{'id':_0x4278ea[_0x23efd0('0x832')]});});let _0x40c0d2=null;_0x496d59[_0x44132c('0x1ebc')]&&(_0x40c0d2=_0x2e3ca0()[_0x44132c('0x1c07')](_0x496d59[_0x44132c('0x11d2')],{'id':Number(_0x496d59[_0x44132c('0x1ebc')]['id'])}));if(_0x40c0d2&&!_0x2e3ca0()[_0x44132c('0x7a2')](_0x26e229,['id',_0x40c0d2['id']])){const _0x4f7943=_0x2e3ca0()[_0x44132c('0x1c07')](_0x496d59[_0x44132c('0x11d2')],{'id':_0x40c0d2['id']});_0x4f7943[_0x44132c('0x319')]=![],_0x26e229[_0x44132c('0x1fd0')](_0x4f7943);}_0x496d59[_0x44132c('0x11d2')]=_0x26e229;});}})['catch'](function(_0x5387af){const _0x5d0d52=_0x3b25ff;_0x1cf88f['error']({'title':_0x5387af['status']?_0x5d0d52('0x2168')+_0x5387af[_0x5d0d52('0x13ee')]+_0x5d0d52('0xbf6')+_0x5387af[_0x5d0d52('0x24a9')]:_0x5d0d52('0xb97'),'msg':_0x5387af[_0x5d0d52('0x5a5')]?JSON[_0x5d0d52('0x258a')](_0x5387af[_0x5d0d52('0x5a5')]):_0x5387af[_0x5d0d52('0x1ff0')]()});});function _0x1c0111(_0x216810,_0x23228d){const _0x1d7b8d=_0x3b25ff;_0x496d59['musiconhold']=_0x216810,_0x496d59[_0x1d7b8d('0x1134')]=typeof _0x23228d!==_0x1d7b8d('0x1867')?_0x23228d:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x496d59[_0x1d7b8d('0x23a2')][_0x1d7b8d('0x1563')]=_0x496d59[_0x1d7b8d('0x1ebc')]['id'],_0x496d59[_0x1d7b8d('0x23a2')]['id']=_0x496d59[_0x1d7b8d('0x1ebc')]['id'],_0x543138();}function _0x4c1376(_0x23d9f1,_0x3f5349,_0x2d1e50){const _0x6655fb=_0x3b25ff;return _0xaf1aaa['sound'][_0x6655fb('0x18e8')]({'id':_0x23d9f1['id'],'exists':!![],'attachments':_0x2d1e50})[_0x6655fb('0xe53')][_0x6655fb('0x683')](function(_0x2e30db){const _0x15118b=_0x6655fb,_0x1b7169=[_0x2e30db['buffer']];let _0x55554f=_0x15118b('0x845')+_0x23d9f1['id'];const _0x4e3991=new Blob(_0x1b7169,{'type':_0x2e30db['type']});_0x55554f=_0x23d9f1['converted_format']?_0x23d9f1[_0x15118b('0x1144')]+'.'+_0x23d9f1[_0x15118b('0xd59')]:_0x23d9f1[_0x15118b('0x1144')];const _0x2786d0=window['document'][_0x15118b('0x1ffa')]('a');_0x2786d0[_0x15118b('0x130f')](_0x15118b('0x2767'),URL[_0x15118b('0x2820')](_0x4e3991)),_0x2786d0[_0x15118b('0x130f')](_0x15118b('0x18e8'),_0x55554f),document[_0x15118b('0x18e5')][_0x15118b('0x1e43')](_0x2786d0),_0x2786d0[_0x15118b('0x1d42')]();})['catch'](function(_0x347656){const _0x18c4ac=_0x6655fb;if(_0x347656[_0x18c4ac('0x5a5')]&&_0x347656[_0x18c4ac('0x5a5')][_0x18c4ac('0x17f')]&&_0x347656[_0x18c4ac('0x5a5')][_0x18c4ac('0x17f')]['length'])for(let _0x238f08=0x0;_0x238f08<_0x347656[_0x18c4ac('0x5a5')][_0x18c4ac('0x17f')][_0x18c4ac('0x1564')];_0x238f08+=0x1){_0x1cf88f[_0x18c4ac('0x52a')]({'title':_0x347656[_0x18c4ac('0x5a5')][_0x18c4ac('0x17f')][_0x238f08][_0x18c4ac('0xcf0')],'msg':_0x347656[_0x18c4ac('0x5a5')][_0x18c4ac('0x17f')][_0x238f08]['message']});}else _0x1cf88f['error']({'title':_0x347656[_0x18c4ac('0x13ee')]?_0x18c4ac('0x2168')+_0x347656['status']+_0x18c4ac('0xbf6')+_0x347656[_0x18c4ac('0x24a9')]:_0x18c4ac('0x98b'),'msg':_0x347656[_0x18c4ac('0x5a5')]?JSON[_0x18c4ac('0x258a')](_0x347656[_0x18c4ac('0x5a5')][_0x18c4ac('0x8c2')]):_0x347656[_0x18c4ac('0x1ff0')]()});});}function _0xabd03d(_0x4cabb5,_0x59944f){const _0x570af1=_0x3b25ff,_0x2d5c43=_0x54a86d['confirm']()[_0x570af1('0xf28')](_0x570af1('0x1f03'))['htmlContent'](_0x570af1('0xed5')+(_0x4cabb5[_0x570af1('0x60a')]||_0x4cabb5['id']&&_0x2e3ca0()['upperFirst'](_0x570af1('0x162f'))+_0x4cabb5['id']||_0x570af1('0x845'))+_0x570af1('0x20f1')+_0x570af1('0x1ee7'))[_0x570af1('0x1040')](_0x570af1('0x914'))[_0x570af1('0xe42')](_0x59944f)['ok']('OK')['cancel']('CANCEL');_0x54a86d[_0x570af1('0x1d4')](_0x2d5c43)[_0x570af1('0x683')](function(){_0x2f123a(_0x4cabb5);},function(){const _0xf050c4=_0x570af1;console['log'](_0xf050c4('0x16b8'));});}function _0x45d466(_0x5d14fe){const _0x5803a5=_0x3b25ff;_0x496d59[_0x5803a5('0x14af')]=_0x5d14fe||{'count':0x0,'rows':[]};}function _0x543138(){const _0x1099db=_0x3b25ff;_0x496d59['query'][_0x1099db('0x1cc8')]=(_0x496d59[_0x1099db('0x23a2')][_0x1099db('0xdf8')]-0x1)*_0x496d59['query']['limit'],_0x496d59[_0x1099db('0x1883')]=_0xaf1aaa[_0x1099db('0x0')][_0x1099db('0xc50')](_0x496d59[_0x1099db('0x23a2')],_0x45d466)[_0x1099db('0xe53')];}function _0x2a6b93(_0x35b4c1,_0x3c1c2f){const _0x4619b7=_0x3b25ff;_0x54a86d[_0x4619b7('0x1d4')]({'controller':'CreateOrEditMohSoundDialogController','controllerAs':'vm','templateUrl':_0x2e796d,'parent':angular[_0x4619b7('0x1fcc')](_0x2e0ec2[_0x4619b7('0x18e5')]),'targetEvent':_0x35b4c1,'clickOutsideToClose':!![],'locals':{'musiconhold':_0x496d59[_0x4619b7('0x1ebc')],'mohSound':_0x3c1c2f,'mohSounds':_0x496d59['musiconholdMohSounds'][_0x4619b7('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x496d59[_0x4619b7('0x1134')]}});}function _0x2f123a(_0x45ba4c){const _0x5b1ff0=_0x3b25ff;_0xaf1aaa[_0x5b1ff0('0x0')][_0x5b1ff0('0x196')]({'id':_0x44b894[_0x5b1ff0('0x7f2')]['id'],'id2':_0x45ba4c['id']})[_0x5b1ff0('0xe53')][_0x5b1ff0('0x683')](function(){const _0x18c888=_0x5b1ff0;_0x2e3ca0()[_0x18c888('0x3ec')](_0x496d59['musiconholdMohSounds'][_0x18c888('0xf5d')],{'id':_0x45ba4c['id']}),_0x496d59[_0x18c888('0x14af')]['count']-=0x1,!_0x496d59['musiconholdMohSounds'][_0x18c888('0xf5d')]['length']&&_0x543138(),_0x1cf88f['success']({'title':_0x18c888('0x1129'),'msg':_0x45ba4c[_0x18c888('0x60a')]?_0x45ba4c[_0x18c888('0x60a')]+_0x18c888('0x194d'):''});})[_0x5b1ff0('0x130a')](function(_0x154c56){const _0x3c71ab=_0x5b1ff0;if(_0x154c56['data']&&_0x154c56[_0x3c71ab('0x5a5')]['errors']&&_0x154c56[_0x3c71ab('0x5a5')]['errors'][_0x3c71ab('0x1564')]){_0x496d59['errors']=_0x154c56['data'][_0x3c71ab('0x17f')]||[{'message':_0x154c56[_0x3c71ab('0x1ff0')](),'type':'SYSTEM:GETvoiceMusicOnHold'}];for(let _0x1d944a=0x0;_0x1d944a<_0x154c56[_0x3c71ab('0x5a5')][_0x3c71ab('0x17f')][_0x3c71ab('0x1564')];_0x1d944a++){_0x1cf88f[_0x3c71ab('0x52a')]({'title':_0x154c56[_0x3c71ab('0x5a5')]['errors'][_0x1d944a][_0x3c71ab('0xcf0')],'msg':_0x154c56['data'][_0x3c71ab('0x17f')][_0x1d944a][_0x3c71ab('0x8c2')]});}}else _0x1cf88f[_0x3c71ab('0x52a')]({'title':_0x154c56[_0x3c71ab('0x13ee')]?_0x3c71ab('0x2168')+_0x154c56[_0x3c71ab('0x13ee')]+'\x20-\x20'+_0x154c56[_0x3c71ab('0x24a9')]:'SYSTEM:GETvoiceMusicOnHold','msg':_0x154c56[_0x3c71ab('0x5a5')]?JSON['stringify'](_0x154c56[_0x3c71ab('0x5a5')][_0x3c71ab('0x8c2')]):_0x154c56['message']||_0x154c56['toString']()});});}function _0x396c2e(){const _0x53a3b9=_0x3b25ff,_0x513193=angular[_0x53a3b9('0x1a86')](_0x496d59[_0x53a3b9('0x166c')]);return _0x496d59['selectedMusicOnHoldMohSounds']=[],_0x513193;}function _0x5c779a(_0xa6920a){const _0x58c4bf=_0x3b25ff,_0x12db04=_0x54a86d[_0x58c4bf('0x1c6f')]()[_0x58c4bf('0xf28')](_0x58c4bf('0x254f'))[_0x58c4bf('0x26e3')](''+_0x496d59[_0x58c4bf('0x166c')][_0x58c4bf('0x1564')]+_0x58c4bf('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x58c4bf('0x13cf'))[_0x58c4bf('0xe42')](_0xa6920a)['ok']('OK')['cancel'](_0x58c4bf('0x16b8'));_0x54a86d[_0x58c4bf('0x1d4')](_0x12db04)['then'](function(){const _0x4cf054=_0x58c4bf;_0x496d59[_0x4cf054('0x166c')]['forEach'](function(_0x11ded5){_0x2f123a(_0x11ded5);}),_0x496d59[_0x4cf054('0x166c')]=[];});}let _0x2ab4b9=!![],_0x42f938=0x1;_0x1b37ac[_0x3b25ff('0x186d')](_0x3b25ff('0x229'),function(_0x3be5af,_0x3d7d67){const _0x417660=_0x3b25ff;_0x2ab4b9?_0x30338d(function(){_0x2ab4b9=![];}):(!_0x3d7d67&&(_0x42f938=_0x496d59[_0x417660('0x23a2')][_0x417660('0xdf8')]),_0x3be5af!==_0x3d7d67&&(_0x496d59[_0x417660('0x23a2')][_0x417660('0xdf8')]=0x1),!_0x3be5af&&(_0x496d59[_0x417660('0x23a2')][_0x417660('0xdf8')]=_0x42f938),_0x543138());});}const _0xe672e9=_0x3a8fa2;_0x578685[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x56d'),_0x189033('0x845'),'api',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x578685(_0x11751a,_0x35ac6c,_0x283cd7,_0x2309b5,_0x8f78e7,_0x20cb61,_0x3413eb,_0x4cf1d4,_0x5134bd,_0x37061b,_0x5c6754,_0xe9113a,_0x2eb05e,_0x55d50e){const _0x1c10ff=_0x189033,_0x4ccaee=this;_0x4ccaee[_0x1c10ff('0x11ed')]=_0x5c6754[_0x1c10ff('0x20b2')](),_0x4ccaee[_0x1c10ff('0x17f')]=[],_0x4ccaee[_0x1c10ff('0x260a')]=_0x2eb05e,_0x4ccaee[_0x1c10ff('0xace')]=_0xe9113a,_0x4ccaee[_0x1c10ff('0x1134')]=_0x55d50e,_0x4ccaee['hasModulePermissions']={},_0x4ccaee[_0x1c10ff('0x19b2')]=_0x4ccaee[_0x1c10ff('0x260a')]&&_0x4ccaee['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4ccaee[_0x1c10ff('0xf28')]='VOICE.EDIT_MOHSOUND',_0x4ccaee[_0x1c10ff('0x845')]=angular[_0x1c10ff('0x1a86')](_0x5134bd),_0x4ccaee[_0x1c10ff('0x56d')]=_0x4cf1d4,_0x4ccaee[_0x1c10ff('0x565')]=![];!_0x4ccaee[_0x1c10ff('0x845')]&&(_0x4ccaee[_0x1c10ff('0x845')]={},_0x4ccaee[_0x1c10ff('0xf28')]=_0x1c10ff('0x1423'),_0x4ccaee['newMohSound']=!![]);_0x35ac6c[_0x1c10ff('0x7f2')]['id']&&(_0x4ccaee[_0x1c10ff('0x845')][_0x1c10ff('0x1563')]=_0x35ac6c[_0x1c10ff('0x7f2')]['id']);_0x4ccaee[_0x1c10ff('0x175a')]=_0x2547a7,_0x4ccaee[_0x1c10ff('0xbef')]=_0x4ae769,_0x4ccaee[_0x1c10ff('0x1e14')]=_0x38fead,_0x4ccaee[_0x1c10ff('0x16b3')]=_0x550cf3,_0x4ccaee[_0x1c10ff('0xf82')]=_0x3a17e9,_0x5c6754[_0x1c10ff('0xca1')]('admin')?_0x37061b[_0x1c10ff('0x1638')][_0x1c10ff('0x1e6e')]({'fields':'id,name','sort':_0x1c10ff('0x60a')})['$promise'][_0x1c10ff('0x683')](function(_0x2c9322){const _0x49d8c7=_0x1c10ff;_0x4ccaee[_0x49d8c7('0x11d2')]=_0x2c9322['rows']||[];})['catch'](function(_0x4531cd){const _0xf8d370=_0x1c10ff;_0x3413eb['error']({'title':_0x4531cd['status']?_0xf8d370('0x2168')+_0x4531cd['status']+_0xf8d370('0xbf6')+_0x4531cd[_0xf8d370('0x24a9')]:_0xf8d370('0x162a'),'msg':_0x4531cd[_0xf8d370('0x5a5')]?JSON['stringify'](_0x4531cd[_0xf8d370('0x5a5')]):_0x4531cd[_0xf8d370('0x1ff0')]()});}):_0x37061b[_0x1c10ff('0x1638')][_0x1c10ff('0x1e6e')]({'fields':_0x1c10ff('0xa10'),'sort':_0x1c10ff('0x60a')})[_0x1c10ff('0xe53')][_0x1c10ff('0x683')](function(_0x23ad78){const _0x52a6e2=_0x1c10ff;_0x4ccaee[_0x52a6e2('0x11d2')]=_0x23ad78[_0x52a6e2('0xf5d')]||[];})[_0x1c10ff('0x683')](function(){const _0x20dcb0=_0x1c10ff;return _0x37061b[_0x20dcb0('0x22df')]['get']({'userProfileId':_0x4ccaee[_0x20dcb0('0x11ed')][_0x20dcb0('0x2f')],'sectionId':0x3ef})[_0x20dcb0('0xe53')];})[_0x1c10ff('0x683')](function(_0x31b149){const _0x56b54a=_0x1c10ff,_0xd551ec=_0x31b149&&_0x31b149['rows']?_0x31b149['rows'][0x0]:null;if(!_0xd551ec){const _0x250e1e=[];let _0x3d8463=null;_0x4ccaee[_0x56b54a('0x845')]&&(_0x3d8463=_0x2e3ca0()['find'](_0x4ccaee[_0x56b54a('0x11d2')],{'id':Number(_0x4ccaee[_0x56b54a('0x845')]['id'])}));for(let _0x116820=0x0;_0x116820<_0x4ccaee[_0x56b54a('0x11d2')][_0x56b54a('0x1564')];_0x116820++){_0x3d8463&&_0x4ccaee[_0x56b54a('0x11d2')][_0x116820]['id']===_0x3d8463['id']&&(_0x4ccaee[_0x56b54a('0x11d2')][_0x116820][_0x56b54a('0x319')]=![],_0x250e1e[_0x56b54a('0x1fd0')](_0x4ccaee[_0x56b54a('0x11d2')][_0x116820]));}_0x4ccaee['sounds']=_0x250e1e;}else{if(!_0xd551ec[_0x56b54a('0x170')])return _0x37061b['userProfileResource'][_0x56b54a('0x1e6e')]({'sectionId':_0xd551ec['id']})[_0x56b54a('0xe53')]['then'](function(_0x3a6f91){const _0x5ce170=_0x56b54a,_0x5012a4=_0x2e3ca0()[_0x5ce170('0x386')](_0x3a6f91[_0x5ce170('0xf5d')],function(_0x299b3e){const _0x4021e6=_0x5ce170;return _0x2e3ca0()[_0x4021e6('0x1c07')](_0x4ccaee[_0x4021e6('0x11d2')],{'id':_0x299b3e[_0x4021e6('0x832')]});});let _0x23f855=null;_0x4ccaee['mohSound']&&(_0x23f855=_0x2e3ca0()[_0x5ce170('0x1c07')](_0x4ccaee[_0x5ce170('0x11d2')],{'id':Number(_0x4ccaee[_0x5ce170('0x845')]['id'])}));if(_0x23f855&&!_0x2e3ca0()[_0x5ce170('0x7a2')](_0x5012a4,['id',_0x23f855['id']])){const _0x4d2355=_0x2e3ca0()[_0x5ce170('0x1c07')](_0x4ccaee['sounds'],{'id':_0x23f855['id']});_0x4d2355[_0x5ce170('0x319')]=![],_0x5012a4['push'](_0x4d2355);}_0x4ccaee[_0x5ce170('0x11d2')]=_0x5012a4;});}})[_0x1c10ff('0x130a')](function(_0x27e4ba){const _0x378ead=_0x1c10ff;_0x3413eb['error']({'title':_0x27e4ba[_0x378ead('0x13ee')]?'API:'+_0x27e4ba[_0x378ead('0x13ee')]+_0x378ead('0xbf6')+_0x27e4ba[_0x378ead('0x24a9')]:_0x378ead('0xb97'),'msg':_0x27e4ba[_0x378ead('0x5a5')]?JSON['stringify'](_0x27e4ba['data']):_0x27e4ba['toString']()});});function _0x2547a7(){const _0x4f8e7d=_0x1c10ff;_0x4ccaee[_0x4f8e7d('0x17f')]=[],_0x37061b[_0x4f8e7d('0x0')][_0x4f8e7d('0x1698')]({'id':_0x35ac6c[_0x4f8e7d('0x7f2')]['id']},_0x4ccaee['mohSound'])['$promise'][_0x4f8e7d('0x683')](function(_0x5e266e){const _0x3ed527=_0x4f8e7d;_0x4ccaee[_0x3ed527('0x56d')]['unshift'](_0x5e266e[_0x3ed527('0x24e1')]()),_0x3413eb[_0x3ed527('0x53')]({'title':'MohSound\x20properly\x20created','msg':_0x4ccaee[_0x3ed527('0x845')]['name']?_0x4ccaee[_0x3ed527('0x845')][_0x3ed527('0x60a')]+_0x3ed527('0x14b5'):''}),_0x3a17e9(_0x5e266e);})['catch'](function(_0x34d184){const _0x3ed763=_0x4f8e7d;if(_0x34d184['data']&&_0x34d184[_0x3ed763('0x5a5')][_0x3ed763('0x17f')]&&_0x34d184[_0x3ed763('0x5a5')][_0x3ed763('0x17f')]['length']){_0x4ccaee['errors']=_0x34d184[_0x3ed763('0x5a5')][_0x3ed763('0x17f')]||[{'message':_0x34d184[_0x3ed763('0x1ff0')](),'type':_0x3ed763('0x98b')}];for(let _0x165610=0x0;_0x165610<_0x34d184['data'][_0x3ed763('0x17f')][_0x3ed763('0x1564')];_0x165610+=0x1){_0x3413eb[_0x3ed763('0x52a')]({'title':_0x34d184[_0x3ed763('0x5a5')][_0x3ed763('0x17f')][_0x165610][_0x3ed763('0xcf0')],'msg':_0x34d184['data'][_0x3ed763('0x17f')][_0x165610][_0x3ed763('0x8c2')]});}}else _0x3413eb['error']({'title':_0x34d184['status']?_0x3ed763('0x2168')+_0x34d184['status']+_0x3ed763('0xbf6')+_0x34d184[_0x3ed763('0x24a9')]:'api.voiceMusicOnHold.save','msg':_0x34d184[_0x3ed763('0x5a5')]?JSON['stringify'](_0x34d184['data']['message']):_0x34d184[_0x3ed763('0x1ff0')]()});});}function _0x4ae769(){const _0x238677=_0x1c10ff;_0x4ccaee[_0x238677('0x17f')]=[],_0x37061b[_0x238677('0x0')][_0x238677('0x2480')]({'id':_0x4ccaee['mohSound']['id']},_0x4ccaee[_0x238677('0x845')])[_0x238677('0xe53')]['then'](function(_0x3e8750){const _0x59fae7=_0x238677,_0x2857a8=_0x2e3ca0()[_0x59fae7('0x1c07')](_0x4ccaee[_0x59fae7('0x56d')],{'id':_0x3e8750['id']});_0x2857a8&&_0x2e3ca0()['merge'](_0x2857a8,_0x2e3ca0()['pick'](_0x3e8750['toJSON'](),_0x2e3ca0()[_0x59fae7('0x55e')](_0x2857a8))),_0x3413eb['success']({'title':'MohSound\x20properly\x20saved!','msg':_0x4ccaee['mohSound'][_0x59fae7('0x60a')]?_0x4ccaee[_0x59fae7('0x845')][_0x59fae7('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x3a17e9(_0x3e8750);})['catch'](function(_0x33715c){const _0x2aab4b=_0x238677;if(_0x33715c[_0x2aab4b('0x5a5')]&&_0x33715c[_0x2aab4b('0x5a5')][_0x2aab4b('0x17f')]&&_0x33715c['data']['errors'][_0x2aab4b('0x1564')]){_0x4ccaee[_0x2aab4b('0x17f')]=_0x33715c[_0x2aab4b('0x5a5')][_0x2aab4b('0x17f')]||[{'message':_0x33715c[_0x2aab4b('0x1ff0')](),'type':_0x2aab4b('0x100f')}];for(let _0x2fa036=0x0;_0x2fa036<_0x33715c['data']['errors'][_0x2aab4b('0x1564')];_0x2fa036++){_0x3413eb['error']({'title':_0x33715c[_0x2aab4b('0x5a5')][_0x2aab4b('0x17f')][_0x2fa036][_0x2aab4b('0xcf0')],'msg':_0x33715c[_0x2aab4b('0x5a5')][_0x2aab4b('0x17f')][_0x2fa036][_0x2aab4b('0x8c2')]});}}else _0x3413eb[_0x2aab4b('0x52a')]({'title':_0x33715c[_0x2aab4b('0x13ee')]?'API:'+_0x33715c[_0x2aab4b('0x13ee')]+_0x2aab4b('0xbf6')+_0x33715c['statusText']:'api.voiceMusicOnHold.update','msg':_0x33715c['data']?JSON[_0x2aab4b('0x258a')](_0x33715c[_0x2aab4b('0x5a5')][_0x2aab4b('0x8c2')]):_0x33715c['toString']()});});}function _0x38fead(_0x1f968d){const _0x36f477=_0x1c10ff;_0x4ccaee['errors']=[];const _0x17e01c=_0x2309b5[_0x36f477('0x1c6f')]()['title'](_0x36f477('0x4d'))[_0x36f477('0xa6a')](_0x36f477('0x301'))[_0x36f477('0x1040')](_0x36f477('0x7be'))['ok'](_0x36f477('0x2307'))[_0x36f477('0x19fb')]('Cancel')[_0x36f477('0xe42')](_0x1f968d);_0x2309b5[_0x36f477('0x1d4')](_0x17e01c)[_0x36f477('0x683')](function(){const _0x497c61=_0x36f477;_0x37061b[_0x497c61('0x0')]['delete']({'id':_0x4ccaee[_0x497c61('0x845')]['id']})['$promise'][_0x497c61('0x683')](function(){const _0x15b431=_0x497c61;_0x2e3ca0()[_0x15b431('0x3ec')](_0x4ccaee['mohSounds'],{'id':_0x4ccaee[_0x15b431('0x845')]['id']}),_0x3413eb['success']({'title':'MohSound\x20properly\x20deleted!','msg':(_0x4ccaee[_0x15b431('0x845')][_0x15b431('0x60a')]||_0x15b431('0x845'))+_0x15b431('0x194d')}),_0x3a17e9(_0x4ccaee[_0x15b431('0x845')]);})[_0x497c61('0x130a')](function(_0x53dd21){const _0x245f59=_0x497c61;if(_0x53dd21['data']&&_0x53dd21[_0x245f59('0x5a5')][_0x245f59('0x17f')]&&_0x53dd21['data'][_0x245f59('0x17f')][_0x245f59('0x1564')]){_0x4ccaee['errors']=_0x53dd21[_0x245f59('0x5a5')][_0x245f59('0x17f')]||[{'message':_0x53dd21[_0x245f59('0x1ff0')](),'type':_0x245f59('0x2853')}];for(let _0x27c89b=0x0;_0x27c89b<_0x53dd21[_0x245f59('0x5a5')][_0x245f59('0x17f')][_0x245f59('0x1564')];_0x27c89b++){_0x3413eb['error']({'title':_0x53dd21[_0x245f59('0x5a5')]['errors'][_0x27c89b][_0x245f59('0xcf0')],'msg':_0x53dd21[_0x245f59('0x5a5')][_0x245f59('0x17f')][_0x27c89b][_0x245f59('0x8c2')]});}}else _0x3413eb[_0x245f59('0x52a')]({'title':_0x53dd21['status']?_0x245f59('0x2168')+_0x53dd21[_0x245f59('0x13ee')]+_0x245f59('0xbf6')+_0x53dd21[_0x245f59('0x24a9')]:_0x245f59('0x2853'),'msg':_0x53dd21[_0x245f59('0x5a5')]?JSON['stringify'](_0x53dd21[_0x245f59('0x5a5')][_0x245f59('0x8c2')]):_0x53dd21[_0x245f59('0x8c2')]||_0x53dd21[_0x245f59('0x1ff0')]()});});},function(){});}function _0x550cf3(_0x50f9fa){return _0x50f9fa===null?undefined:new Date(_0x50f9fa);}function _0x3a17e9(_0x1904bd){const _0x3afd61=_0x1c10ff;_0x2309b5[_0x3afd61('0x1715')](_0x1904bd);}}const _0x394a65=_0x578685;_0x270cb3[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$document',_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x1ebc'),_0x189033('0x22df')];function _0x270cb3(_0x31fccd,_0x24a37c,_0x2c085e,_0x33a2cb,_0x46ea4a,_0x1d38f4,_0x39bc2c,_0x3d8cb3,_0x498d53,_0x1fa583,_0x1318e5,_0x272519){const _0x4ec0a4=_0x189033,_0x1226b6=this;_0x1226b6[_0x4ec0a4('0x11ed')]=_0x1fa583[_0x4ec0a4('0x20b2')](),_0x1226b6[_0x4ec0a4('0xace')]=_0x1d38f4,_0x1226b6[_0x4ec0a4('0x260a')]=_0x39bc2c,_0x1226b6[_0x4ec0a4('0x19b2')]=_0x1226b6['setting'][_0x4ec0a4('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1226b6['location']=_0x24a37c[_0x4ec0a4('0x173e')]()+_0x4ec0a4('0x20de')+_0x24a37c[_0x4ec0a4('0x19ac')](),_0x1226b6[_0x4ec0a4('0x1ebc')]=_0x1318e5||_0x31fccd[_0x4ec0a4('0x7f2')][_0x4ec0a4('0x1ebc')]||{},_0x1226b6[_0x4ec0a4('0x22df')]=_0x272519&&_0x272519[_0x4ec0a4('0x50d')]==0x1?_0x272519[_0x4ec0a4('0xf5d')][0x0]:null,_0x1226b6[_0x4ec0a4('0x1134')]=_0x1fa583['parseCrudPermissions'](_0x1226b6[_0x4ec0a4('0x22df')]?_0x1226b6[_0x4ec0a4('0x22df')][_0x4ec0a4('0x1134')]:null),_0x1226b6[_0x4ec0a4('0x258d')]={},_0x1226b6[_0x4ec0a4('0x517')]=_0x31fccd[_0x4ec0a4('0x7f2')][_0x4ec0a4('0x1904')]||0x0,_0x1226b6[_0x4ec0a4('0x2430')]=_0x498d53['info'],_0x1226b6[_0x4ec0a4('0x106e')]=_0x115e96,_0x1226b6[_0x4ec0a4('0xf38')]=_0x89bb58;function _0x115e96(){const _0x56c66b=_0x4ec0a4;_0x31fccd['go'](_0x56c66b('0x1472'),{},{'reload':'app.voice.musiconholds'});}function _0x89bb58(){const _0x479024=_0x4ec0a4;_0x3d8cb3['voiceMusicOnHold'][_0x479024('0x2480')]({'id':_0x1226b6[_0x479024('0x1ebc')]['id']},_0x1226b6[_0x479024('0x1ebc')])['$promise'][_0x479024('0x683')](function(){const _0x2e2072=_0x479024;_0x498d53['success']({'title':_0x2e2072('0x151d'),'msg':_0x1226b6[_0x2e2072('0x1ebc')][_0x2e2072('0x60a')]?_0x1226b6[_0x2e2072('0x1ebc')][_0x2e2072('0x60a')]+_0x2e2072('0x96c'):''});})[_0x479024('0x130a')](function(_0x197079){const _0x1ea8e6=_0x479024;_0x498d53['error']({'title':_0x197079[_0x1ea8e6('0x13ee')]?_0x1ea8e6('0x2168')+_0x197079[_0x1ea8e6('0x13ee')]+'\x20-\x20'+_0x197079[_0x1ea8e6('0x24a9')]:_0x1ea8e6('0x16d2'),'msg':_0x197079[_0x1ea8e6('0x5a5')]?JSON[_0x1ea8e6('0x258a')](_0x197079[_0x1ea8e6('0x5a5')]):_0x197079['toString']()});});}}const _0x5b9865=_0x270cb3,_0x4879c9=_0x180212['p']+_0x189033('0x6b6');_0x213cf0[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0xd89'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x213cf0(_0x148837,_0x3f9613,_0x20f72e,_0x1a1e5c,_0x47456f,_0x582708,_0x2448ac,_0x29e5fb,_0x514c0c,_0x210ef0,_0x34cb1c,_0xd84ac7,_0x2fd7f9,_0x501649,_0x3eccbf,_0x409549,_0x19359e){const _0x39b00a=_0x189033,_0x6f3c86=this;_0x6f3c86['license']=_0x409549,_0x6f3c86[_0x39b00a('0x260a')]=_0x19359e,_0x6f3c86[_0x39b00a('0x11ed')]=_0x3eccbf['getCurrentUser'](),_0x6f3c86[_0x39b00a('0xd89')]=_0x514c0c||{'count':0x0,'rows':[]},_0x6f3c86[_0x39b00a('0x2a')]=_0x210ef0,_0x6f3c86['userProfileSection']=_0x34cb1c&&_0x34cb1c[_0x39b00a('0x50d')]==0x1?_0x34cb1c[_0x39b00a('0xf5d')][0x0]:null,_0x6f3c86[_0x39b00a('0x1134')]=_0x3eccbf[_0x39b00a('0x142a')](_0x6f3c86[_0x39b00a('0x22df')]?_0x6f3c86[_0x39b00a('0x22df')]['crudPermissions']:null),_0x6f3c86[_0x39b00a('0x5c4')]=_0x39b00a('0xd89'),_0x6f3c86[_0x39b00a('0x247')]='',_0x6f3c86[_0x39b00a('0x1ce2')]=null,_0x6f3c86[_0x39b00a('0x4fd')]=[],_0x6f3c86[_0x39b00a('0x23a2')]={'fields':_0x39b00a('0x11ca'),'defaultEntry':_0x39b00a('0x22bf'),'limit':0xa,'page':0x1},_0x6f3c86[_0x39b00a('0x22dd')]=_0x2e3ca0()[_0x39b00a('0x24db')]([{'option':'Files','value':_0x39b00a('0x458')},{'option':_0x39b00a('0x1fcf'),'value':'\x27custom\x27'}],function(_0x1d6fea){const _0x43465b=_0x39b00a;return _0x2e3ca0()[_0x43465b('0x1725')](_0x1d6fea[_0x43465b('0x1c6b')],new RegExp('\x27','g'),'');}),_0x6f3c86[_0x39b00a('0x12c6')]=_0x2e3ca0()[_0x39b00a('0x24db')]([{'option':_0x39b00a('0x1f8d'),'value':'\x27random\x27'},{'option':_0x39b00a('0xd9e'),'value':_0x39b00a('0x277')}],function(_0xd43d11){const _0x40d0f5=_0x39b00a;return _0x2e3ca0()['replace'](_0xd43d11[_0x40d0f5('0x1c6b')],new RegExp('\x27','g'),'');}),_0x6f3c86[_0x39b00a('0xc63')]=_0x4ee08d,_0x6f3c86[_0x39b00a('0x194f')]=_0x164442,_0x6f3c86['success']=_0x10edb7,_0x6f3c86['getMusicOnHolds']=_0x19ccf8,_0x6f3c86[_0x39b00a('0x186b')]=_0x4862cc,_0x6f3c86[_0x39b00a('0x1018')]=_0x84c945,_0x6f3c86[_0x39b00a('0x811')]=_0x114816,_0x6f3c86[_0x39b00a('0x23ee')]=_0x3d46ed,_0x6f3c86['deselectMusicOnHolds']=_0x1e68a1,_0x6f3c86[_0x39b00a('0x1a5e')]=_0x19ac46;function _0x4ee08d(_0x5a6c4f){const _0xd64d15=_0x39b00a;_0x20f72e['go'](_0xd64d15('0x99e'),{'id':_0x5a6c4f['id'],'musiconhold':_0x5a6c4f,'crudPermissions':_0x6f3c86['crudPermissions']});}function _0x164442(_0x435601,_0x19d540){const _0x2de0db=_0x39b00a,_0x18e344=_0x47456f[_0x2de0db('0x1c6f')]()[_0x2de0db('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()['startCase'](_0x2de0db('0x1ebc'))+'?')['htmlContent'](''+(_0x435601[_0x2de0db('0x60a')]||_0x2de0db('0x1ebc'))+_0x2de0db('0x20f1')+'\x20will\x20be\x20deleted.')[_0x2de0db('0x1040')](_0x2de0db('0x1c72'))[_0x2de0db('0xe42')](_0x19d540)['ok']('OK')[_0x2de0db('0x19fb')](_0x2de0db('0x16b8'));_0x47456f['show'](_0x18e344)[_0x2de0db('0x683')](function(){_0x84c945(_0x435601);},function(){const _0x38892b=_0x2de0db;console[_0x38892b('0x1b2b')](_0x38892b('0x16b8'));});}let _0x5a9b67=!![],_0x3001d0=0x1;_0x148837[_0x39b00a('0x186d')](_0x39b00a('0x1e1d'),function(_0x573121,_0xb11523){const _0x142229=_0x39b00a;_0x5a9b67?_0x2448ac(function(){_0x5a9b67=![];}):(!_0xb11523&&(_0x3001d0=_0x6f3c86[_0x142229('0x23a2')][_0x142229('0xdf8')]),_0x573121!==_0xb11523&&(_0x6f3c86[_0x142229('0x23a2')]['page']=0x1),!_0x573121&&(_0x6f3c86[_0x142229('0x23a2')][_0x142229('0xdf8')]=_0x3001d0),_0x6f3c86[_0x142229('0x2596')]());});function _0x10edb7(_0x45cc22){const _0x19a1b8=_0x39b00a;_0x6f3c86[_0x19a1b8('0xd89')]=_0x45cc22||{'count':0x0,'rows':[]};}function _0x19ccf8(){const _0x4cac67=_0x39b00a;_0x6f3c86[_0x4cac67('0x23a2')][_0x4cac67('0x1cc8')]=(_0x6f3c86['query'][_0x4cac67('0xdf8')]-0x1)*_0x6f3c86[_0x4cac67('0x23a2')][_0x4cac67('0x6f0')],_0x3eccbf[_0x4cac67('0xca1')](_0x4cac67('0x20c2'))?_0x6f3c86[_0x4cac67('0x1883')]=_0xd84ac7[_0x4cac67('0x0')][_0x4cac67('0x1e6e')](_0x6f3c86[_0x4cac67('0x23a2')],_0x10edb7)['$promise']:(_0x6f3c86[_0x4cac67('0x23a2')]['id']=_0x6f3c86[_0x4cac67('0x2a')]['id'],_0x6f3c86[_0x4cac67('0x23a2')][_0x4cac67('0x1aa')]=_0x4cac67('0x27d2'),_0x6f3c86[_0x4cac67('0x1883')]=_0xd84ac7[_0x4cac67('0x2a')][_0x4cac67('0x241d')](_0x6f3c86[_0x4cac67('0x23a2')],_0x10edb7)[_0x4cac67('0xe53')]);}function _0x4862cc(_0x4a8eb0,_0x4fc50a){const _0x17192d=_0x39b00a;_0x47456f['show']({'controller':'CreateOrEditMusicOnHoldDialogController','controllerAs':'vm','templateUrl':_0x4879c9,'parent':angular[_0x17192d('0x1fcc')](_0x582708[_0x17192d('0x18e5')]),'targetEvent':_0x4a8eb0,'clickOutsideToClose':!![],'locals':{'musiconhold':_0x4fc50a,'musiconholds':_0x6f3c86[_0x17192d('0xd89')][_0x17192d('0xf5d')],'license':_0x6f3c86[_0x17192d('0xace')],'setting':_0x6f3c86[_0x17192d('0x260a')],'crudPermissions':_0x6f3c86[_0x17192d('0x1134')]}});}function _0x84c945(_0x11c63b){const _0x37102f=_0x39b00a;_0xd84ac7[_0x37102f('0x0')][_0x37102f('0xd7e')]({'id':_0x11c63b['id']})[_0x37102f('0xe53')]['then'](function(){const _0x4eb131=_0x37102f;_0x2e3ca0()[_0x4eb131('0x3ec')](_0x6f3c86['musiconholds'][_0x4eb131('0xf5d')],{'id':_0x11c63b['id']}),_0x6f3c86[_0x4eb131('0xd89')][_0x4eb131('0x50d')]-=0x1,!_0x6f3c86[_0x4eb131('0xd89')][_0x4eb131('0xf5d')]['length']&&_0x6f3c86['getMusicOnHolds'](),_0x501649[_0x4eb131('0x53')]({'title':_0x2e3ca0()['startCase'](_0x4eb131('0x1c0f'))+_0x4eb131('0xbfc'),'msg':_0x11c63b[_0x4eb131('0x60a')]?_0x11c63b[_0x4eb131('0x60a')]+_0x4eb131('0x194d'):''});})[_0x37102f('0x130a')](function(_0x163a71){const _0x5b2245=_0x37102f;if(_0x163a71[_0x5b2245('0x5a5')]&&_0x163a71[_0x5b2245('0x5a5')][_0x5b2245('0x17f')]&&_0x163a71[_0x5b2245('0x5a5')][_0x5b2245('0x17f')]['length']){_0x6f3c86[_0x5b2245('0x17f')]=_0x163a71[_0x5b2245('0x5a5')][_0x5b2245('0x17f')]||[{'message':_0x163a71[_0x5b2245('0x1ff0')](),'type':_0x5b2245('0x287b')}];for(let _0x369e64=0x0;_0x369e64<_0x163a71[_0x5b2245('0x5a5')][_0x5b2245('0x17f')][_0x5b2245('0x1564')];_0x369e64++){_0x501649[_0x5b2245('0x52a')]({'title':_0x163a71['data']['errors'][_0x369e64][_0x5b2245('0xcf0')],'msg':_0x163a71[_0x5b2245('0x5a5')][_0x5b2245('0x17f')][_0x369e64][_0x5b2245('0x8c2')]});}}else _0x501649[_0x5b2245('0x52a')]({'title':_0x163a71[_0x5b2245('0x13ee')]?_0x5b2245('0x2168')+_0x163a71[_0x5b2245('0x13ee')]+_0x5b2245('0xbf6')+_0x163a71[_0x5b2245('0x24a9')]:'SYSTEM:DELETEvoiceMusicOnHold','msg':_0x163a71[_0x5b2245('0x5a5')]?JSON[_0x5b2245('0x258a')](_0x163a71[_0x5b2245('0x5a5')][_0x5b2245('0x8c2')]):_0x163a71['message']||_0x163a71[_0x5b2245('0x1ff0')]()});});}function _0x114816(){const _0x24279c=_0x39b00a,_0x13015c=angular[_0x24279c('0x1a86')](_0x6f3c86[_0x24279c('0x4fd')]);return _0x6f3c86[_0x24279c('0x4fd')]=[],_0x13015c;}function _0x3d46ed(_0x2c59b5){const _0x59dd93=_0x39b00a,_0x43ee69=_0x47456f[_0x59dd93('0x1c6f')]()[_0x59dd93('0xf28')](_0x59dd93('0x1879'))[_0x59dd93('0x26e3')](_0x59dd93('0xed5')+_0x6f3c86[_0x59dd93('0x4fd')][_0x59dd93('0x1564')]+_0x59dd93('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x59dd93('0x1a1a'))[_0x59dd93('0xe42')](_0x2c59b5)['ok']('OK')[_0x59dd93('0x19fb')](_0x59dd93('0x16b8'));_0x47456f[_0x59dd93('0x1d4')](_0x43ee69)['then'](function(){const _0x30e1e7=_0x59dd93;_0x6f3c86[_0x30e1e7('0x4fd')]['forEach'](function(_0x2fdd2f){_0x84c945(_0x2fdd2f);}),_0x6f3c86[_0x30e1e7('0x4fd')]=[];});}function _0x1e68a1(){const _0x52697e=_0x39b00a;_0x6f3c86[_0x52697e('0x4fd')]=[];}function _0x19ac46(){const _0x5db1b0=_0x39b00a;_0x6f3c86[_0x5db1b0('0x4fd')]=_0x6f3c86['musiconholds'][_0x5db1b0('0xf5d')];}}const _0x68f669=_0x213cf0;_0xb6379e[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1b40'),'outboundroute',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0xb6379e(_0x2a45de,_0x265bbe,_0x1da955,_0x44134a,_0xc847db,_0x202870,_0x1656d5,_0x122926,_0x455599,_0x27131a,_0x4faa58,_0x10545b,_0x3893ff,_0x565f14){const _0xda179d=_0x189033,_0x457bed=this;_0x457bed['currentUser']=_0x4faa58[_0xda179d('0x20b2')](),_0x457bed[_0xda179d('0x17f')]=[],_0x457bed['setting']=_0x3893ff,_0x457bed[_0xda179d('0xace')]=_0x10545b,_0x457bed[_0xda179d('0x1134')]=_0x565f14,_0x457bed[_0xda179d('0x258d')]={},_0x457bed[_0xda179d('0x19b2')]=_0x457bed[_0xda179d('0x260a')]&&_0x457bed[_0xda179d('0x260a')][_0xda179d('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x457bed[_0xda179d('0xf28')]=_0xda179d('0x25e1'),_0x457bed[_0xda179d('0x1f2d')]=angular[_0xda179d('0x1a86')](_0x455599),_0x457bed[_0xda179d('0x1b40')]=_0x122926,_0x457bed[_0xda179d('0x20e0')]=![],_0x457bed['outboundrouteApps']={'count':0x0,'rows':[]},_0x457bed[_0xda179d('0x346')]=_0x2e3ca0()['reject'](_0x2e3ca0()[_0xda179d('0x742')]([{'app':'Interval','appType':'interval','type':_0xda179d('0x127e'),'types':['always',_0xda179d('0xbf0'),_0xda179d('0x2335')],'fields':[],'isApp':![]},{'app':_0xda179d('0x7c0'),'appType':_0xda179d('0x4d2'),'context':_0xda179d('0x1365'),'type':'Outbound','icon':'icon-apps','interval':_0xda179d('0x1b54'),'options':'xX','isApp':!![],'extraApi':[{'name':'trunks','route':_0xda179d('0x1a93'),'filters':{'fields':_0xda179d('0x60a'),'sort':_0xda179d('0x60a')}},{'name':_0xda179d('0x1ce6'),'route':_0xda179d('0x270'),'filters':{'fields':_0xda179d('0x60a'),'sort':_0xda179d('0x60a'),'nolimit':!![]}}],'fields':[{'title':_0xda179d('0x17c1'),'name':'trunk','type':_0xda179d('0x1aae'),'values':_0xda179d('0x20fe'),'value':_0xda179d('0x1f1c'),'option':_0xda179d('0x1f1c'),'required':!![],'param':0x0},{'title':_0xda179d('0xad7'),'name':_0xda179d('0x73c'),'type':'text','ngPattern':_0xda179d('0x216e'),'help':!![]},{'title':_0xda179d('0x21fc'),'name':_0xda179d('0x24fa'),'type':_0xda179d('0x1bcd')},{'title':_0xda179d('0x198f'),'name':_0xda179d('0x270'),'type':_0xda179d('0x1aae'),'values':'tags','value':_0xda179d('0x1402'),'option':_0xda179d('0x1402'),'defaultValues':[{'value':'\x27--\x27','option':_0xda179d('0x2749')}]},{'title':_0xda179d('0xa09'),'name':'timeout','type':_0xda179d('0x121f'),'min':0x0,'param':0x1},{'title':_0xda179d('0x6d'),'name':'options','type':'text','param':0x2},{'title':_0xda179d('0x1865'),'name':'url','type':_0xda179d('0x1bcd'),'param':0x3}]},{'app':null,'type':_0xda179d('0x127e'),'appType':_0xda179d('0xbf0'),'icon':'icon-apps','interval':_0xda179d('0x1b54'),'isApp':!![],'fields':[{'title':_0xda179d('0x62f'),'name':_0xda179d('0x1d75'),'type':_0xda179d('0x1bcd'),'required':!![],'param':0x0},{'title':_0xda179d('0xdff'),'name':_0xda179d('0x1407'),'type':_0xda179d('0x1bcd'),'param':0x1}]}],[_0xda179d('0x1d75')]),{'isApp':![]});!_0x457bed['outboundroute']&&(_0x457bed[_0xda179d('0x1f2d')]={'appdata':_0xda179d('0x10bb'),'type':_0xda179d('0x17cd'),'context':_0xda179d('0x1365'),'recordingFormat':_0xda179d('0x925')},_0x457bed[_0xda179d('0xf28')]='VOICE.NEW_OUTBOUNDROUTE',_0x457bed[_0xda179d('0x20e0')]=!![]);_0x457bed[_0xda179d('0x814')]=_0x4bc6df,_0x457bed[_0xda179d('0xf80')]=_0x122715,_0x457bed[_0xda179d('0x1db4')]=_0x543d62,_0x457bed[_0xda179d('0x16b3')]=_0x151549,_0x457bed[_0xda179d('0x13f5')]=_0x53e661,_0x457bed['closeDialog']=_0x590c8e,_0x4faa58[_0xda179d('0xca1')]('admin')?_0x27131a[_0xda179d('0x1e4d')]['get']({'fields':_0xda179d('0xa10'),'sort':_0xda179d('0x60a'),'nolimit':'true'})['$promise'][_0xda179d('0x683')](function(_0x90fcf3){const _0x4160ba=_0xda179d;_0x457bed[_0x4160ba('0x1693')]=_0x90fcf3[_0x4160ba('0xf5d')]||[];})[_0xda179d('0x130a')](function(_0x375534){const _0x299b40=_0xda179d;_0x1656d5[_0x299b40('0x52a')]({'title':_0x375534[_0x299b40('0x13ee')]?'API:'+_0x375534[_0x299b40('0x13ee')]+'\x20-\x20'+_0x375534[_0x299b40('0x24a9')]:_0x299b40('0x1379'),'msg':_0x375534[_0x299b40('0x5a5')]?JSON[_0x299b40('0x258a')](_0x375534[_0x299b40('0x5a5')]):_0x375534[_0x299b40('0x1ff0')]()});}):_0x27131a[_0xda179d('0x1e4d')][_0xda179d('0x1e6e')]({'fields':_0xda179d('0xa10'),'sort':'name','nolimit':_0xda179d('0x26ac')})[_0xda179d('0xe53')][_0xda179d('0x683')](function(_0x442544){const _0x3d4eb5=_0xda179d;_0x457bed[_0x3d4eb5('0x1693')]=_0x442544[_0x3d4eb5('0xf5d')]||[];})[_0xda179d('0x683')](function(){const _0x516f59=_0xda179d;return _0x27131a['userProfileSection'][_0x516f59('0x1e6e')]({'userProfileId':_0x457bed['currentUser'][_0x516f59('0x2f')],'sectionId':0x195})[_0x516f59('0xe53')];})[_0xda179d('0x683')](function(_0x165572){const _0x4361fe=_0xda179d,_0x52f6be=_0x165572&&_0x165572[_0x4361fe('0xf5d')]?_0x165572[_0x4361fe('0xf5d')][0x0]:null;if(!_0x52f6be)return _0x27131a['voiceContext'][_0x4361fe('0x1e6e')]({'fields':_0x4361fe('0xa10'),'sort':_0x4361fe('0x60a'),'nolimit':_0x4361fe('0x26ac'),'defaultEntry':0x1})['$promise'][_0x4361fe('0x683')](function(_0x3c7311){const _0x341639=_0x4361fe;_0x457bed[_0x341639('0x1693')]=_0x3c7311[_0x341639('0xf5d')]||[];});else{if(!_0x52f6be[_0x4361fe('0x170')])return _0x27131a[_0x4361fe('0xcf7')]['get']({'sectionId':_0x52f6be['id']})[_0x4361fe('0xe53')][_0x4361fe('0x683')](function(_0x17c1ce){const _0x614018=_0x4361fe,_0x5514b7=_0x2e3ca0()[_0x614018('0x386')](_0x17c1ce[_0x614018('0xf5d')],function(_0x369779){const _0x1890be=_0x614018;return _0x2e3ca0()[_0x1890be('0x1c07')](_0x457bed[_0x1890be('0x1693')],{'id':_0x369779[_0x1890be('0x832')]});});let _0x56839d=null;_0x457bed[_0x614018('0x1f2d')]&&(_0x56839d=_0x2e3ca0()[_0x614018('0x1c07')](_0x457bed[_0x614018('0x1693')],{'name':_0x457bed['outboundroute'][_0x614018('0x22d3')]}));if(_0x56839d&&!_0x2e3ca0()[_0x614018('0x7a2')](_0x5514b7,['id',_0x56839d['id']])){const _0xb22ae7=_0x2e3ca0()['find'](_0x457bed[_0x614018('0x1693')],{'id':_0x56839d['id']});_0xb22ae7[_0x614018('0x319')]=![],_0x5514b7['push'](_0xb22ae7);}_0x457bed['contexts']=_0x5514b7;});}})['catch'](function(_0x43404f){const _0x5c1281=_0xda179d;_0x1656d5[_0x5c1281('0x52a')]({'title':_0x43404f[_0x5c1281('0x13ee')]?_0x5c1281('0x2168')+_0x43404f[_0x5c1281('0x13ee')]+'\x20-\x20'+_0x43404f[_0x5c1281('0x24a9')]:'SYSTEM:GETcontexts','msg':_0x43404f['data']?JSON['stringify'](_0x43404f[_0x5c1281('0x5a5')]):_0x43404f[_0x5c1281('0x1ff0')]()});});function _0x4bc6df(){const _0x3f198e=_0xda179d;_0x457bed['errors']=[],_0x27131a[_0x3f198e('0x14cb')][_0x3f198e('0xb0a')](_0x457bed[_0x3f198e('0x1f2d')])[_0x3f198e('0xe53')][_0x3f198e('0x683')](function(_0x3f82e2){const _0x27b76f=_0x3f198e;_0x457bed[_0x27b76f('0x1b40')][_0x27b76f('0x1167')](_0x3f82e2['toJSON']()),_0x1656d5[_0x27b76f('0x53')]({'title':_0x27b76f('0xb7f'),'msg':_0x457bed[_0x27b76f('0x1f2d')][_0x27b76f('0x60a')]?_0x457bed[_0x27b76f('0x1f2d')][_0x27b76f('0x60a')]+_0x27b76f('0x14b5'):''}),_0x590c8e(_0x3f82e2);})['catch'](function(_0x5414b6){const _0x2a592c=_0x3f198e;if(_0x5414b6[_0x2a592c('0x5a5')]&&_0x5414b6[_0x2a592c('0x5a5')]['errors']&&_0x5414b6['data']['errors']['length']){_0x457bed[_0x2a592c('0x17f')]=_0x5414b6['data'][_0x2a592c('0x17f')]||[{'message':_0x5414b6[_0x2a592c('0x1ff0')](),'type':_0x2a592c('0x13bd')}];for(let _0x48ce7e=0x0;_0x48ce7e<_0x5414b6['data'][_0x2a592c('0x17f')][_0x2a592c('0x1564')];_0x48ce7e+=0x1){_0x1656d5[_0x2a592c('0x52a')]({'title':_0x5414b6['data']['errors'][_0x48ce7e][_0x2a592c('0xcf0')],'msg':_0x5414b6['data'][_0x2a592c('0x17f')][_0x48ce7e][_0x2a592c('0x8c2')]});}}else _0x1656d5['error']({'title':_0x5414b6[_0x2a592c('0x13ee')]?_0x2a592c('0x2168')+_0x5414b6[_0x2a592c('0x13ee')]+_0x2a592c('0xbf6')+_0x5414b6[_0x2a592c('0x24a9')]:'api.voiceExtension.save','msg':_0x5414b6['data']?JSON[_0x2a592c('0x258a')](_0x5414b6['data'][_0x2a592c('0x8c2')]):_0x5414b6['toString']()});});}function _0x122715(){const _0xef387e=_0xda179d;_0x457bed[_0xef387e('0x17f')]=[],_0x27131a['voiceExtension'][_0xef387e('0x2480')]({'id':_0x457bed[_0xef387e('0x1f2d')]['id']},_0x457bed[_0xef387e('0x1f2d')])[_0xef387e('0xe53')][_0xef387e('0x683')](function(_0x37f6c5){const _0x161a42=_0xef387e,_0x668fe2=_0x2e3ca0()['find'](_0x457bed[_0x161a42('0x1b40')],{'id':_0x37f6c5['id']});_0x668fe2&&(_0x2e3ca0()[_0x161a42('0xf22')](_0x668fe2,_0x2e3ca0()[_0x161a42('0x24d0')](_0x37f6c5['toJSON'](),_0x2e3ca0()[_0x161a42('0x55e')](_0x668fe2))),_0x27131a['voiceExtension'][_0x161a42('0x1e6e')]({'sort':_0x161a42('0xe1e'),'VoiceExtensionId':_0x668fe2['id'],'isApp':!![],'nolimit':!![]})['$promise']['then'](function(_0x48fcde){_0x457bed['outboundrouteApps']=_0x48fcde,_0x53e661();})),_0x1656d5['success']({'title':_0x161a42('0xa27'),'msg':_0x457bed['outboundroute']['name']?_0x457bed['outboundroute']['name']+'\x20has\x20been\x20saved!':''}),_0x590c8e(_0x37f6c5);})['catch'](function(_0x3f5502){const _0x480d94=_0xef387e;if(_0x3f5502[_0x480d94('0x5a5')]&&_0x3f5502['data']['errors']&&_0x3f5502[_0x480d94('0x5a5')]['errors'][_0x480d94('0x1564')]){_0x457bed[_0x480d94('0x17f')]=_0x3f5502[_0x480d94('0x5a5')]['errors']||[{'message':_0x3f5502['toString'](),'type':'api.voiceExtension.update'}];for(let _0x1f90fa=0x0;_0x1f90fa<_0x3f5502['data'][_0x480d94('0x17f')][_0x480d94('0x1564')];_0x1f90fa++){_0x1656d5[_0x480d94('0x52a')]({'title':_0x3f5502[_0x480d94('0x5a5')]['errors'][_0x1f90fa]['type'],'msg':_0x3f5502[_0x480d94('0x5a5')][_0x480d94('0x17f')][_0x1f90fa][_0x480d94('0x8c2')]});}}else _0x1656d5[_0x480d94('0x52a')]({'title':_0x3f5502[_0x480d94('0x13ee')]?_0x480d94('0x2168')+_0x3f5502[_0x480d94('0x13ee')]+_0x480d94('0xbf6')+_0x3f5502[_0x480d94('0x24a9')]:_0x480d94('0x27e8'),'msg':_0x3f5502[_0x480d94('0x5a5')]?JSON[_0x480d94('0x258a')](_0x3f5502[_0x480d94('0x5a5')][_0x480d94('0x8c2')]):_0x3f5502[_0x480d94('0x1ff0')]()});});}function _0x543d62(_0xf15db4){const _0xd02dd3=_0xda179d;_0x27131a[_0xd02dd3('0x110a')][_0xd02dd3('0x1e6e')]({'VoiceExtensionId':_0x455599['id']})[_0xd02dd3('0xe53')][_0xd02dd3('0x683')](function(_0x1c826b){const _0x4a4f93=_0xd02dd3;if(_0x1c826b&&_0x1c826b[_0x4a4f93('0xf5d')]&&_0x1c826b[_0x4a4f93('0xf5d')][_0x4a4f93('0x1564')]>0x0)return _0x1656d5[_0x4a4f93('0x52a')]({'title':_0x4a4f93('0xcc7'),'msg':_0x4a4f93('0x1108')});else{_0x457bed['errors']=[];const _0x323274=_0x44134a['confirm']()['title'](_0x4a4f93('0x4d'))[_0x4a4f93('0xa6a')]('The\x20outboundroute\x20will\x20be\x20deleted.')[_0x4a4f93('0x1040')]('Delete\x20OutboundRoute')['ok'](_0x4a4f93('0x2307'))[_0x4a4f93('0x19fb')](_0x4a4f93('0x253a'))['targetEvent'](_0xf15db4);_0x44134a[_0x4a4f93('0x1d4')](_0x323274)[_0x4a4f93('0x683')](function(){const _0x1bd269=_0x4a4f93;_0x27131a['voiceExtension'][_0x1bd269('0xd7e')]({'id':_0x457bed[_0x1bd269('0x1f2d')]['id']})['$promise'][_0x1bd269('0x683')](function(){const _0x2d604f=_0x1bd269;_0x2e3ca0()[_0x2d604f('0x3ec')](_0x457bed[_0x2d604f('0x1b40')],{'id':_0x457bed[_0x2d604f('0x1f2d')]['id']}),_0x1656d5[_0x2d604f('0x53')]({'title':'OutboundRoute\x20properly\x20deleted!','msg':(_0x457bed[_0x2d604f('0x1f2d')]['name']||'outboundroute')+_0x2d604f('0x194d')}),_0x590c8e(_0x457bed[_0x2d604f('0x1f2d')]);})['catch'](function(_0x519363){const _0x409ae7=_0x1bd269;if(_0x519363[_0x409ae7('0x5a5')]&&_0x519363[_0x409ae7('0x5a5')][_0x409ae7('0x17f')]&&_0x519363[_0x409ae7('0x5a5')][_0x409ae7('0x17f')][_0x409ae7('0x1564')]){_0x457bed[_0x409ae7('0x17f')]=_0x519363[_0x409ae7('0x5a5')][_0x409ae7('0x17f')]||[{'message':_0x519363['toString'](),'type':_0x409ae7('0x17de')}];for(let _0x20c51c=0x0;_0x20c51c<_0x519363[_0x409ae7('0x5a5')][_0x409ae7('0x17f')][_0x409ae7('0x1564')];_0x20c51c++){_0x1656d5['error']({'title':_0x519363['data'][_0x409ae7('0x17f')][_0x20c51c]['type'],'msg':_0x519363[_0x409ae7('0x5a5')]['errors'][_0x20c51c]['message']});}}else _0x1656d5['error']({'title':_0x519363[_0x409ae7('0x13ee')]?_0x409ae7('0x2168')+_0x519363[_0x409ae7('0x13ee')]+'\x20-\x20'+_0x519363[_0x409ae7('0x24a9')]:_0x409ae7('0x17de'),'msg':_0x519363[_0x409ae7('0x5a5')]?JSON[_0x409ae7('0x258a')](_0x519363['data']['message']):_0x519363['message']||_0x519363[_0x409ae7('0x1ff0')]()});});},function(){});}});}function _0x53e661(){const _0x58c55c=_0xda179d;let _0x34d2e2=0x2,_0x4a1899=[];_0x4a1899[_0x58c55c('0x1fd0')]({'type':'outbound','app':_0x58c55c('0x1faa'),'appdata':_0x58c55c('0x1b7c'),'context':_0x457bed[_0x58c55c('0x1f2d')]['context'],'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'priority':_0x34d2e2++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']}),_0x4a1899[_0x58c55c('0x1fd0')]({'type':'outbound','app':_0x58c55c('0x1faa'),'appdata':_0x58c55c('0x1a2c')+(_0x457bed['outboundroute']['cutdigits']?'${EXTEN:'+_0x457bed['outboundroute'][_0x58c55c('0x145a')]+'}':_0x58c55c('0x20cb')),'context':_0x457bed[_0x58c55c('0x1f2d')]['context'],'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'priority':_0x34d2e2++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']}),_0x4a1899[_0x58c55c('0x1fd0')]({'type':'outbound','app':_0x58c55c('0x1faa'),'appdata':'XCALLY-MOTION-ANSWER=0','context':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')],'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'priority':_0x34d2e2++,'VoiceExtensionId':_0x457bed['outboundroute']['id']}),_0x4a1899['push']({'type':_0x58c55c('0x17cd'),'app':_0x58c55c('0x1faa'),'appdata':'XCALLY-MOTION-PROGRESS=0','context':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')],'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'priority':_0x34d2e2++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']}),_0x4a1899[_0x58c55c('0x1fd0')]({'type':_0x58c55c('0x17cd'),'app':_0x58c55c('0x1faa'),'appdata':_0x58c55c('0x6e3'),'context':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')],'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'priority':_0x34d2e2++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']}),_0x4a1899['push']({'type':'outbound','app':_0x58c55c('0x1faa'),'appdata':_0x58c55c('0xea8')+_0x457bed['outboundroute']['id'],'context':_0x457bed[_0x58c55c('0x1f2d')]['context'],'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'priority':_0x34d2e2++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']});typeof _0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x75b')]!==_0x58c55c('0x1867')&&_0x457bed[_0x58c55c('0x1f2d')]['recordingFormat']!=='none'&&(_0x4a1899[_0x58c55c('0x1fd0')]({'type':'outbound','app':_0x58c55c('0x1faa'),'appdata':_0x58c55c('0x6e8'),'context':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')],'exten':_0x457bed['outboundroute'][_0x58c55c('0x1a5b')],'priority':_0x34d2e2++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']}),_0x4a1899['push']({'type':'outbound','app':'Set','appdata':_0x58c55c('0x4f4')+_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x75b')]||0x0,'context':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')],'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'priority':_0x34d2e2++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']}));for(let _0x5107e5=0x0,_0x3c14e7=0x0;_0x5107e5<_0x457bed['outboundrouteApps'][_0x58c55c('0xf5d')][_0x58c55c('0x1564')];_0x5107e5++,_0x3c14e7=0x0){const _0x439af1=_0x457bed[_0x58c55c('0xe65')][_0x58c55c('0xf5d')][_0x5107e5],_0x11d5d8=[],_0x40d3fc=[];_0x439af1['intervals']=_0x439af1['interval']!=='*,*,*,*'?[_0x439af1['interval']]:_0x439af1['IntervalId']?_0x2e3ca0()[_0x58c55c('0x386')](_0x2e3ca0()['filter'](_0x457bed[_0x58c55c('0xe98')]['rows'],{'IntervalId':_0x439af1[_0x58c55c('0x5ae')]}),_0x58c55c('0x115c')):[],_0x439af1[_0x58c55c('0x22d3')]=_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')],_0x439af1[_0x58c55c('0x1a5b')]=_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')];_0x439af1[_0x58c55c('0xcf0')]&&(_0x439af1[_0x58c55c('0xcf0')]=_0x439af1[_0x58c55c('0xcf0')][_0x58c55c('0x93a')]());typeof _0x439af1[_0x58c55c('0x270')]!==_0x58c55c('0x1867')&&(_0x439af1[_0x58c55c('0x270')]&&_0x439af1[_0x58c55c('0x270')]!=='--'&&_0x11d5d8['push']({'type':_0x439af1[_0x58c55c('0xcf0')]['toLowerCase'](),'app':'Set','appdata':_0x58c55c('0x17bb')+_0x439af1[_0x58c55c('0x270')],'context':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')],'exten':_0x457bed['outboundroute'][_0x58c55c('0x1a5b')],'priority':_0x439af1[_0x58c55c('0xe98')][_0x58c55c('0x1564')]+_0x34d2e2+_0x3c14e7++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']}));_0x439af1['callerID']?_0x11d5d8['push']({'type':_0x439af1[_0x58c55c('0xcf0')]['toLowerCase'](),'app':'ExecIf','appdata':_0x58c55c('0x2274')+_0x439af1[_0x58c55c('0x73c')]+')','context':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')],'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'priority':_0x439af1[_0x58c55c('0xe98')][_0x58c55c('0x1564')]+_0x34d2e2+_0x3c14e7++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']}):_0x11d5d8['push']({'type':_0x439af1[_0x58c55c('0xcf0')][_0x58c55c('0x93a')](),'app':_0x58c55c('0x15bb'),'appdata':'$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):NoOp(No\x20number\x20available)','context':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')],'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'priority':_0x439af1[_0x58c55c('0xe98')][_0x58c55c('0x1564')]+_0x34d2e2+_0x3c14e7++,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']});for(let _0x5a7400=0x0;_0x5a7400<_0x439af1[_0x58c55c('0xe98')][_0x58c55c('0x1564')];_0x5a7400++){const _0x219244=_0x34d2e2+_0x439af1[_0x58c55c('0xe98')]['length'],_0x2d0f6b=_0x5a7400===_0x439af1['intervals']['length']-0x1?_0x34d2e2+_0x11d5d8[_0x58c55c('0x1564')]+_0x40d3fc[_0x58c55c('0x1564')]+0x2:_0x34d2e2+_0x5a7400+0x1;_0x11d5d8[_0x58c55c('0x2040')](_0x5a7400,0x0,{'type':_0x58c55c('0x17cd'),'app':_0x58c55c('0xeb4'),'appdata':_0x439af1[_0x58c55c('0xe98')][_0x5a7400]+'?'+_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')]+_0x58c55c('0xd09')+_0x219244+':'+_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x22d3')]+',${EXTEN},'+_0x2d0f6b,'exten':_0x457bed['outboundroute'][_0x58c55c('0x1a5b')],'context':_0x457bed['outboundroute'][_0x58c55c('0x22d3')],'priority':_0x34d2e2+_0x5a7400,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']});}if(_0x439af1[_0x58c55c('0x11f3')]==='outboundDial'){const _0x42b9a4=_0x2e3ca0()[_0x58c55c('0x1c07')](_0x457bed[_0x58c55c('0x346')],{'appType':'outboundDial'});if(_0x42b9a4&&_0x42b9a4[_0x58c55c('0x189a')]){const _0x587fcc={},_0x2f2464=_0x439af1[_0x58c55c('0x1407')][_0x58c55c('0x1fc5')](','),_0x118dc1=[];for(let _0x46a0ff=0x0,_0x1e0f40=_0x42b9a4[_0x58c55c('0x189a')]['length'];_0x46a0ff<_0x1e0f40;_0x46a0ff++){if(typeof _0x42b9a4['fields'][_0x46a0ff][_0x58c55c('0x2108')]!==_0x58c55c('0x1867'))switch(_0x42b9a4[_0x58c55c('0x189a')][_0x46a0ff][_0x58c55c('0x60a')]){case _0x58c55c('0x1a93'):_0x587fcc[_0x58c55c('0x1a93')]=_0x2f2464[_0x42b9a4[_0x58c55c('0x189a')][_0x46a0ff][_0x58c55c('0x2108')]][_0x58c55c('0x1fc5')]('/')[0x1],_0x587fcc[_0x58c55c('0xd31')]=_0x2f2464[_0x42b9a4[_0x58c55c('0x189a')][_0x46a0ff][_0x58c55c('0x2108')]][_0x58c55c('0x1fc5')]('/')[0x2],_0x587fcc[_0x58c55c('0x24fa')]=_0x587fcc[_0x58c55c('0xd31')]?_0x587fcc[_0x58c55c('0xd31')][_0x58c55c('0x1fc5')]('$')[0x0]:undefined,_0x587fcc[_0x58c55c('0xd31')]=_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x145a')]?(_0x587fcc['prefix']||'')+_0x58c55c('0x249e')+_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x145a')]+'}':(_0x587fcc['prefix']||'')+'${EXTEN}',_0x118dc1[_0x42b9a4['fields'][_0x46a0ff][_0x58c55c('0x2108')]]=[_0x58c55c('0xcec'),_0x587fcc[_0x58c55c('0x1a93')],_0x587fcc['phone']]['join']('/');break;case _0x58c55c('0x158e'):_0x587fcc['options']=_0x2f2464[_0x42b9a4[_0x58c55c('0x189a')][_0x46a0ff][_0x58c55c('0x2108')]];_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x75b')]!=='none'?_0x587fcc[_0x58c55c('0x158e')][_0x58c55c('0x824')](_0x58c55c('0x1b1'))<0x0&&(_0x587fcc[_0x58c55c('0x158e')]+=_0x58c55c('0x1b1')):_0x587fcc[_0x58c55c('0x158e')]=_0x587fcc[_0x58c55c('0x158e')][_0x58c55c('0x1725')]('U(xcally-mixmonitor-context)','');_0x118dc1[_0x42b9a4[_0x58c55c('0x189a')][_0x46a0ff][_0x58c55c('0x2108')]]=_0x587fcc[_0x58c55c('0x158e')];break;default:_0x118dc1[_0x42b9a4[_0x58c55c('0x189a')][_0x46a0ff]['param']]=_0x2f2464[_0x42b9a4['fields'][_0x46a0ff][_0x58c55c('0x2108')]];}}_0x439af1['appdata']=_0x118dc1[_0x58c55c('0x1630')](',');}}_0x439af1[_0x58c55c('0xe1e')]=_0x11d5d8['length']?_0x2e3ca0()[_0x58c55c('0xc0f')](_0x11d5d8)['priority']+0x1:_0x34d2e2,_0x34d2e2=(_0x40d3fc[_0x58c55c('0x1564')]?_0x2e3ca0()[_0x58c55c('0xc0f')](_0x40d3fc)['priority']:_0x439af1[_0x58c55c('0xe1e')])+0x1,_0x4a1899=_0x2e3ca0()[_0x58c55c('0x746')](_0x4a1899,_0x11d5d8,[_0x439af1],_0x40d3fc);}_0x4a1899[_0x58c55c('0x1fd0')]({'type':_0x58c55c('0x17cd'),'app':_0x58c55c('0x614'),'exten':_0x457bed[_0x58c55c('0x1f2d')][_0x58c55c('0x1a5b')],'context':_0x457bed[_0x58c55c('0x1f2d')]['context'],'priority':_0x34d2e2,'VoiceExtensionId':_0x457bed[_0x58c55c('0x1f2d')]['id']}),_0x27131a[_0x58c55c('0x14cb')]['addApplications']({'id':_0x457bed[_0x58c55c('0x1f2d')]['id']},_0x2e3ca0()[_0x58c55c('0x742')](_0x4a1899,_0x58c55c('0xe1e')))['$promise'][_0x58c55c('0x683')](function(_0x1c78f6){const _0xb8d792=_0x58c55c;_0x457bed[_0xb8d792('0xe65')][_0xb8d792('0xf5d')]=_0x1c78f6[_0xb8d792('0xf5d')];})[_0x58c55c('0x130a')](function(_0x5d040d){const _0x2a9f99=_0x58c55c;console[_0x2a9f99('0x52a')](_0x5d040d);});}function _0x151549(_0x116169){return _0x116169===null?undefined:new Date(_0x116169);}function _0x590c8e(_0x9ed4e6){_0x44134a['hide'](_0x9ed4e6);}}const _0xf653c7=_0xb6379e,_0x3c7b0e=_0x180212['p']+_0x189033('0x27a6'),_0x48a216=_0x180212['p']+'src/js/modules/main/apps/voice/views/outboundroutes/edit/apps/interval/dialog.html/dialog.html',_0x389912=_0x180212['p']+_0x189033('0xc5a');_0x3baa75[_0x189033('0x14be')]=[_0x189033('0x56b'),'$mdDialog','$document',_0x189033('0x1d70'),_0x189033('0x1556'),_0x189033('0x7a5'),_0x189033('0xba1')];const _0x209ccf={'custom':_0x3c7b0e,'interval':_0x48a216,'outbounddial':_0x389912};function _0x3baa75(_0x148a3d,_0x3a286c,_0x30fc72,_0x13b0b4,_0x3d27bc,_0x2c029c,_0x261e1b){const _0x54a867=_0x189033,_0x1fe7e2=this;_0x1fe7e2[_0x54a867('0x11ed')]=_0x261e1b[_0x54a867('0x20b2')](),_0x1fe7e2[_0x54a867('0x1f2d')]={},_0x1fe7e2[_0x54a867('0xe65')]={'count':0x0,'rows':[]},_0x1fe7e2[_0x54a867('0x2fd')]=[],_0x1fe7e2['crudPermissions'],_0x1fe7e2['query']={'sort':_0x54a867('0xe1e')},_0x1fe7e2[_0x54a867('0x346')]=_0x2e3ca0()[_0x54a867('0xfae')](_0x2e3ca0()[_0x54a867('0x742')]([{'app':_0x54a867('0x22ee'),'appType':'interval','type':_0x54a867('0x127e'),'types':[_0x54a867('0x10af'),_0x54a867('0xbf0'),_0x54a867('0x2335')],'fields':[],'isApp':![]},{'app':'Dial','appType':'outboundDial','context':_0x54a867('0x1365'),'type':'Outbound','icon':'icon-apps','interval':'*,*,*,*','options':'xX','isApp':!![],'extraApi':[{'name':_0x54a867('0x20fe'),'field':{'name':'trunk','key':'name'},'route':_0x54a867('0x1a93'),'filters':{'fields':_0x54a867('0xa10'),'sort':_0x54a867('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f3}},{'name':'tags','field':{'name':_0x54a867('0x270'),'key':_0x54a867('0x60a')},'route':_0x54a867('0x270'),'filters':{'fields':_0x54a867('0xa10'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x54a867('0x17c1'),'name':'trunk','type':_0x54a867('0x1aae'),'values':_0x54a867('0x20fe'),'value':_0x54a867('0x1f1c'),'option':'trunk.name','required':!![],'param':0x0},{'title':_0x54a867('0xad7'),'name':'callerID','type':_0x54a867('0x1bcd'),'help':!![]},{'title':_0x54a867('0x21fc'),'name':_0x54a867('0x24fa'),'type':'text'},{'title':_0x54a867('0x198f'),'name':_0x54a867('0x270'),'type':_0x54a867('0x1aae'),'values':_0x54a867('0x1ce6'),'value':_0x54a867('0x1402'),'option':'tag.name','defaultValues':[{'value':_0x54a867('0x280f'),'option':_0x54a867('0x2749')}]},{'title':_0x54a867('0xa09'),'name':'timeout','type':_0x54a867('0x121f'),'min':0x0,'param':0x1},{'title':_0x54a867('0x6d'),'name':'options','type':_0x54a867('0x1bcd'),'param':0x2},{'title':_0x54a867('0x1865'),'name':'url','type':'text','param':0x3}]},{'app':null,'type':_0x54a867('0x127e'),'appType':_0x54a867('0xbf0'),'icon':_0x54a867('0x7ee'),'interval':_0x54a867('0x1b54'),'isApp':!![],'fields':[{'title':_0x54a867('0x62f'),'name':_0x54a867('0x1d75'),'type':'text','required':!![],'param':0x0},{'title':_0x54a867('0xdff'),'name':_0x54a867('0x1407'),'type':_0x54a867('0x1bcd'),'param':0x1}]}],[_0x54a867('0x1d75')]),{'isApp':![]}),_0x1fe7e2[_0x54a867('0x2335')]={'group':{'name':_0x54a867('0x11bf'),'pull':'clone'},'animation':0x64,'sort':![]},_0x1fe7e2['applications']={'group':{'name':_0x54a867('0x489'),'put':'opt1'},'animation':0x64,'onAdd':function(_0x240f52){_0x569a3d(_0x240f52,_0x240f52['newIndex']);},'onSort':function(){_0x313d3c();}},_0x1fe7e2['init']=_0x36f261,_0x1fe7e2[_0x54a867('0x26eb')]=_0x379936,_0x1fe7e2[_0x54a867('0x1218')]=_0x5443f,_0x1fe7e2[_0x54a867('0x170c')]=_0x569a3d,_0x1fe7e2[_0x54a867('0x24f7')]=_0x19c954,_0x1fe7e2[_0x54a867('0x8e1')]=_0x332e9d,_0x1fe7e2[_0x54a867('0x132f')]=_0x1b4ce9,_0x1fe7e2[_0x54a867('0x13f5')]=_0x313d3c,_0x1fe7e2[_0x54a867('0x14a')]=_0x1b4077,_0x1fe7e2['onVoiceExtensionUpdate']=_0x37bdbb;function _0x36f261(_0x28049f,_0x46b186){const _0x3d64ad=_0x54a867;_0x1fe7e2[_0x3d64ad('0x1f2d')]=_0x28049f,_0x1fe7e2[_0x3d64ad('0x1134')]=typeof _0x46b186!==_0x3d64ad('0x1867')?_0x46b186:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1fe7e2[_0x3d64ad('0x2146')]['disabled']=!_0x1fe7e2[_0x3d64ad('0x1134')][_0x3d64ad('0x1978')]?!![]:![],_0x3d27bc['on'](_0x3d64ad('0x22b2'),_0x1fe7e2[_0x3d64ad('0xf2f')]),_0x1fe7e2['query']['VoiceExtensionId']=_0x28049f['id'],_0x1fe7e2[_0x3d64ad('0x23a2')]['isApp']=!![],_0x1fe7e2[_0x3d64ad('0x23a2')][_0x3d64ad('0x2088')]=!![],_0x1fe7e2[_0x3d64ad('0x1218')](),_0x1fe7e2[_0x3d64ad('0x14a')]();}function _0x37bdbb(_0x10547f){const _0x3d2798=_0x54a867;_0x10547f[_0x3d2798('0x18fd')]===_0x1fe7e2['outboundroute']['id']&&_0x313d3c(!![]);}function _0x379936(_0x41e6c1,_0x4ca67b,_0x12a897){const _0x178273=_0x54a867,_0x33d5ea=_0x3a286c[_0x178273('0x1c6f')]()[_0x178273('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20application?')[_0x178273('0x26e3')](_0x178273('0xed5')+_0x41e6c1[_0x178273('0x1d75')]+_0x178273('0x20f1')+'\x20will\x20be\x20deleted.')[_0x178273('0x1040')](_0x178273('0x1312'))[_0x178273('0xe42')](_0x12a897)['ok']('OK')[_0x178273('0x19fb')](_0x178273('0x16b8'));_0x3a286c[_0x178273('0x1d4')](_0x33d5ea)[_0x178273('0x683')](function(){const _0xbbda62=_0x178273;_0x1fe7e2[_0xbbda62('0xe65')]['rows']['splice'](_0x4ca67b,0x1),_0x313d3c();},function(){const _0x4c9172=_0x178273;console[_0x4c9172('0x1b2b')]('CANCEL');});}function _0x569a3d(_0x307061,_0x36aa36){const _0x10b8d8=_0x54a867;if(_0x1fe7e2[_0x10b8d8('0xe65')][_0x10b8d8('0xf5d')][_0x10b8d8('0x1564')]){const _0x13002c=_0x1fe7e2['outboundrouteApps'][_0x10b8d8('0xf5d')][_0x36aa36]?_0x1fe7e2[_0x10b8d8('0xe65')][_0x10b8d8('0xf5d')][_0x36aa36]:_0x1fe7e2[_0x10b8d8('0xe65')]['rows'][0x0],_0x5725e4=(_0x13002c[_0x10b8d8('0x11f3')]||_0x13002c[_0x10b8d8('0x1d75')])[_0x10b8d8('0x93a')]();_0x3a286c[_0x10b8d8('0x1d4')]({'controller':_0x10b8d8('0x388')+_0x5725e4+_0x10b8d8('0x9e4'),'controllerAs':'vm','templateUrl':_0x209ccf[_0x5725e4],'parent':angular[_0x10b8d8('0x1fcc')](_0x30fc72[_0x10b8d8('0x18e5')]),'targetEvent':_0x307061,'clickOutsideToClose':!![],'locals':{'outboundrouteApp':_0x13002c,'outboundroute':_0x1fe7e2[_0x10b8d8('0x1f2d')],'crudPermissions':_0x1fe7e2['crudPermissions']}})[_0x10b8d8('0x683')](function(_0x1f0ea1){const _0x4187e8=_0x10b8d8;_0x1f0ea1&&(_0x1f0ea1['id']?_0x1fe7e2[_0x4187e8('0xe65')]['rows'][_0x36aa36]=_0x1f0ea1:_0x1fe7e2['outboundrouteApps'][_0x4187e8('0xf5d')][_0x4187e8('0x2040')](_0x36aa36,0x0,_0x1f0ea1),_0x313d3c());})[_0x10b8d8('0x130a')](function(_0x5c9efd){const _0x1915e1=_0x10b8d8;_0x5c9efd&&_0x13b0b4['error']({'title':_0x5c9efd[_0x1915e1('0x13ee')]?'API:'+_0x5c9efd[_0x1915e1('0x13ee')]+'\x20-\x20'+_0x5c9efd[_0x1915e1('0x24a9')]:_0x1915e1('0xf1b'),'msg':_0x5c9efd[_0x1915e1('0x5a5')]?JSON[_0x1915e1('0x258a')](_0x5c9efd['data']):_0x5c9efd[_0x1915e1('0x1ff0')]()});});}}function _0x19c954(_0x5e61c0,_0x3f1325){const _0x5c2f3c=_0x54a867;if(_0x1fe7e2[_0x5c2f3c('0xe65')][_0x5c2f3c('0xf5d')][_0x5c2f3c('0x1564')]){const _0x3d38e3=_0x1fe7e2[_0x5c2f3c('0xe65')][_0x5c2f3c('0xf5d')][_0x3f1325]?_0x1fe7e2['outboundrouteApps'][_0x5c2f3c('0xf5d')][_0x3f1325]:_0x1fe7e2[_0x5c2f3c('0xe65')]['rows'][0x0];_0x3a286c['show']({'controller':_0x5c2f3c('0x17d6'),'controllerAs':'vm','templateUrl':_0x48a216,'parent':angular['element'](_0x30fc72['body']),'targetEvent':_0x5e61c0,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x3d38e3['interval'],'IntervalId':_0x3d38e3[_0x5c2f3c('0x5ae')],'application':!![]},'intervals':[],'crudPermissions':_0x1fe7e2[_0x5c2f3c('0x1134')]}})['then'](function(_0x40471e){const _0x2b9b68=_0x5c2f3c;_0x40471e&&(_0x3d38e3['interval']=_0x40471e[_0x2b9b68('0x115c')]||_0x2b9b68('0x1b54'),_0x3d38e3[_0x2b9b68('0x5ae')]=_0x40471e[_0x2b9b68('0x5ae')]||null,_0x313d3c());});}}function _0x313d3c(_0x4de744){const _0x29f69d=_0x54a867;let _0x5b9c3c=0x2,_0x442564=[];_0x442564[_0x29f69d('0x1fd0')]({'type':'outbound','app':_0x29f69d('0x1faa'),'appdata':'CDR(type)=outbound','context':_0x1fe7e2['outboundroute'][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')]['exten'],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']}),_0x442564[_0x29f69d('0x1fd0')]({'type':'outbound','app':_0x29f69d('0x1faa'),'appdata':_0x29f69d('0x1a2c')+(_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x145a')]?'${EXTEN:'+_0x1fe7e2['outboundroute']['cutdigits']+'}':_0x29f69d('0x20cb')),'context':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x22d3')],'exten':_0x1fe7e2['outboundroute'][_0x29f69d('0x1a5b')],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2['outboundroute']['id']}),_0x442564['push']({'type':_0x29f69d('0x17cd'),'app':'Set','appdata':_0x29f69d('0x281f')+_0x1fe7e2[_0x29f69d('0x1f2d')]['id'],'context':_0x1fe7e2['outboundroute'][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x1a5b')],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']});const _0x5dba8c=_0x5b9c3c++;_0x442564[_0x29f69d('0x1fd0')]({'type':_0x29f69d('0x17cd'),'app':_0x29f69d('0x15bb'),'appdata':_0x29f69d('0x25ed')+(_0x5dba8c+0x2)+_0x29f69d('0x1189')+(_0x5dba8c+0x1)+')','context':_0x1fe7e2[_0x29f69d('0x1f2d')]['context'],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x1a5b')],'priority':_0x5dba8c,'VoiceExtensionId':_0x1fe7e2['outboundroute']['id']}),_0x442564[_0x29f69d('0x1fd0')]({'type':_0x29f69d('0x17cd'),'app':_0x29f69d('0x1faa'),'appdata':_0x1fe7e2['outboundroute'][_0x29f69d('0x145a')]?'CDR(prefix)=${EXTEN:0:'+_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x145a')]+'}':_0x29f69d('0x2815'),'context':_0x1fe7e2['outboundroute'][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')]['exten'],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']}),_0x442564[_0x29f69d('0x1fd0')]({'type':_0x29f69d('0x17cd'),'app':_0x29f69d('0x1faa'),'appdata':_0x29f69d('0xccd'),'context':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x1a5b')],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']}),_0x442564['push']({'type':'outbound','app':'Set','appdata':_0x29f69d('0x23d5'),'context':_0x1fe7e2[_0x29f69d('0x1f2d')]['context'],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')]['exten'],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']}),_0x442564[_0x29f69d('0x1fd0')]({'type':'outbound','app':_0x29f69d('0x1faa'),'appdata':'MONITOR_OPTIONS=ab','context':_0x1fe7e2[_0x29f69d('0x1f2d')]['context'],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')]['exten'],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2['outboundroute']['id']}),_0x442564[_0x29f69d('0x1fd0')]({'type':_0x29f69d('0x17cd'),'app':_0x29f69d('0x1faa'),'appdata':_0x29f69d('0xea8')+_0x1fe7e2[_0x29f69d('0x1f2d')]['id'],'context':_0x1fe7e2['outboundroute'][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')]['exten'],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2['outboundroute']['id']});typeof _0x1fe7e2['outboundroute'][_0x29f69d('0x75b')]===_0x29f69d('0x1867')&&_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x75b')]!==_0x29f69d('0x925')&&(_0x442564[_0x29f69d('0x1fd0')]({'type':'outbound','app':_0x29f69d('0x1faa'),'appdata':_0x29f69d('0x6e8'),'context':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x1a5b')],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2['outboundroute']['id']}),_0x442564[_0x29f69d('0x1fd0')]({'type':_0x29f69d('0x17cd'),'app':'Set','appdata':_0x29f69d('0x4f4')+_0x1fe7e2['outboundroute']['recordingFormat']||0x0,'context':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')]['exten'],'priority':_0x5b9c3c++,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']}));for(let _0x79739b=0x0,_0x4f2b8b=0x0;_0x79739b<_0x1fe7e2[_0x29f69d('0xe65')][_0x29f69d('0xf5d')][_0x29f69d('0x1564')];_0x79739b++,_0x4f2b8b=0x0){const _0x559068=_0x1fe7e2[_0x29f69d('0xe65')][_0x29f69d('0xf5d')][_0x79739b],_0x344a83=[],_0x527988=[];_0x559068[_0x29f69d('0xe98')]=_0x559068[_0x29f69d('0x115c')]!==_0x29f69d('0x1b54')?[_0x559068['interval']]:_0x559068[_0x29f69d('0x5ae')]?_0x2e3ca0()[_0x29f69d('0x386')](_0x2e3ca0()['filter'](_0x1fe7e2['intervals']['rows'],{'IntervalId':_0x559068[_0x29f69d('0x5ae')]}),_0x29f69d('0x115c')):[],_0x559068[_0x29f69d('0x22d3')]=_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x22d3')],_0x559068[_0x29f69d('0x1a5b')]=_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x1a5b')];_0x559068[_0x29f69d('0xcf0')]&&(_0x559068[_0x29f69d('0xcf0')]=_0x559068[_0x29f69d('0xcf0')]['toLowerCase']());typeof _0x559068[_0x29f69d('0x270')]!==_0x29f69d('0x1867')&&(_0x559068[_0x29f69d('0x270')]&&_0x559068['tag']!=='--'&&_0x344a83[_0x29f69d('0x1fd0')]({'type':_0x559068[_0x29f69d('0xcf0')][_0x29f69d('0x93a')](),'app':_0x29f69d('0x1faa'),'appdata':_0x29f69d('0x17bb')+_0x559068[_0x29f69d('0x270')],'context':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x1a5b')],'priority':_0x559068[_0x29f69d('0xe98')][_0x29f69d('0x1564')]+_0x5b9c3c+_0x4f2b8b++,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']}));_0x559068[_0x29f69d('0x73c')]?_0x344a83[_0x29f69d('0x1fd0')]({'type':_0x559068[_0x29f69d('0xcf0')]['toLowerCase'](),'app':'ExecIf','appdata':_0x29f69d('0x2274')+_0x559068[_0x29f69d('0x73c')]+')','context':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x1a5b')],'priority':_0x559068[_0x29f69d('0xe98')]['length']+_0x5b9c3c+_0x4f2b8b++,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']}):_0x344a83['push']({'type':_0x559068[_0x29f69d('0xcf0')][_0x29f69d('0x93a')](),'app':'ExecIf','appdata':'$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):NoOp(No\x20number\x20available)','context':_0x1fe7e2['outboundroute'][_0x29f69d('0x22d3')],'exten':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x1a5b')],'priority':_0x559068[_0x29f69d('0xe98')]['length']+_0x5b9c3c+_0x4f2b8b++,'VoiceExtensionId':_0x1fe7e2['outboundroute']['id']});for(let _0x80e849=0x0;_0x80e849<_0x559068['intervals'][_0x29f69d('0x1564')];_0x80e849++){const _0x4095bb=_0x5b9c3c+_0x559068[_0x29f69d('0xe98')][_0x29f69d('0x1564')],_0x4764c3=_0x80e849===_0x559068['intervals'][_0x29f69d('0x1564')]-0x1?_0x5b9c3c+_0x344a83[_0x29f69d('0x1564')]+_0x527988[_0x29f69d('0x1564')]+0x2:_0x5b9c3c+_0x80e849+0x1;_0x344a83['splice'](_0x80e849,0x0,{'type':'outbound','app':'GotoIfTime','appdata':_0x559068[_0x29f69d('0xe98')][_0x80e849]+'?'+_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x22d3')]+_0x29f69d('0xd09')+_0x4095bb+':'+_0x1fe7e2[_0x29f69d('0x1f2d')]['context']+',${EXTEN},'+_0x4764c3,'exten':_0x1fe7e2['outboundroute'][_0x29f69d('0x1a5b')],'context':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x22d3')],'priority':_0x5b9c3c+_0x80e849,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']});}if(_0x4de744&&_0x559068[_0x29f69d('0x11f3')]===_0x29f69d('0x4d2')){const _0x47c1a3=_0x2e3ca0()[_0x29f69d('0x1c07')](_0x1fe7e2[_0x29f69d('0x346')],{'appType':_0x29f69d('0x4d2')});if(_0x47c1a3&&_0x47c1a3[_0x29f69d('0x189a')]){const _0x1d7682={},_0x3a3929=_0x559068[_0x29f69d('0x1407')]['split'](','),_0x6133c7=[];for(let _0x11223e=0x0,_0x2c3d10=_0x47c1a3['fields'][_0x29f69d('0x1564')];_0x11223e<_0x2c3d10;_0x11223e++){if(typeof _0x47c1a3['fields'][_0x11223e][_0x29f69d('0x2108')]!==_0x29f69d('0x1867'))switch(_0x47c1a3[_0x29f69d('0x189a')][_0x11223e]['name']){case _0x29f69d('0x1a93'):_0x1d7682[_0x29f69d('0x1a93')]=_0x3a3929[_0x47c1a3['fields'][_0x11223e][_0x29f69d('0x2108')]][_0x29f69d('0x1fc5')]('/')[0x1],_0x1d7682[_0x29f69d('0xd31')]=_0x3a3929[_0x47c1a3['fields'][_0x11223e][_0x29f69d('0x2108')]][_0x29f69d('0x1fc5')]('/')[0x2],_0x1d7682[_0x29f69d('0x24fa')]=_0x1d7682[_0x29f69d('0xd31')]?_0x1d7682[_0x29f69d('0xd31')]['split']('$')[0x0]:undefined,_0x1d7682[_0x29f69d('0xd31')]=_0x1fe7e2[_0x29f69d('0x1f2d')]['cutdigits']?(_0x1d7682[_0x29f69d('0x24fa')]||'')+'${EXTEN:'+_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x145a')]+'}':(_0x1d7682['prefix']||'')+_0x29f69d('0x20cb'),_0x6133c7[_0x47c1a3[_0x29f69d('0x189a')][_0x11223e][_0x29f69d('0x2108')]]=[_0x29f69d('0xcec'),_0x1d7682[_0x29f69d('0x1a93')],_0x1d7682[_0x29f69d('0xd31')]][_0x29f69d('0x1630')]('/');break;case _0x29f69d('0x158e'):_0x1d7682[_0x29f69d('0x158e')]=_0x3a3929[_0x47c1a3[_0x29f69d('0x189a')][_0x11223e][_0x29f69d('0x2108')]];_0x1fe7e2[_0x29f69d('0x1f2d')]['recordingFormat']!==_0x29f69d('0x925')?_0x1d7682[_0x29f69d('0x158e')][_0x29f69d('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x1d7682[_0x29f69d('0x158e')]+=_0x29f69d('0x1b1')):_0x1d7682['options']=_0x1d7682[_0x29f69d('0x158e')][_0x29f69d('0x1725')](_0x29f69d('0x1b1'),'');_0x6133c7[_0x47c1a3[_0x29f69d('0x189a')][_0x11223e][_0x29f69d('0x2108')]]=_0x1d7682[_0x29f69d('0x158e')];break;default:_0x6133c7[_0x47c1a3[_0x29f69d('0x189a')][_0x11223e][_0x29f69d('0x2108')]]=_0x3a3929[_0x47c1a3[_0x29f69d('0x189a')][_0x11223e][_0x29f69d('0x2108')]];}}_0x559068[_0x29f69d('0x1407')]=_0x6133c7[_0x29f69d('0x1630')](',');}}_0x559068[_0x29f69d('0xe1e')]=_0x344a83[_0x29f69d('0x1564')]?_0x2e3ca0()[_0x29f69d('0xc0f')](_0x344a83)['priority']+0x1:_0x5b9c3c,_0x5b9c3c=(_0x527988[_0x29f69d('0x1564')]?_0x2e3ca0()[_0x29f69d('0xc0f')](_0x527988)[_0x29f69d('0xe1e')]:_0x559068[_0x29f69d('0xe1e')])+0x1,_0x442564=_0x2e3ca0()[_0x29f69d('0x746')](_0x442564,_0x344a83,[_0x559068],_0x527988);}_0x442564[_0x29f69d('0x1fd0')]({'type':'outbound','app':_0x29f69d('0x614'),'exten':_0x1fe7e2[_0x29f69d('0x1f2d')][_0x29f69d('0x1a5b')],'context':_0x1fe7e2['outboundroute'][_0x29f69d('0x22d3')],'priority':_0x5b9c3c,'VoiceExtensionId':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']}),_0x148a3d['voiceExtension'][_0x29f69d('0x10ef')]({'id':_0x1fe7e2[_0x29f69d('0x1f2d')]['id']},_0x2e3ca0()[_0x29f69d('0x742')](_0x442564,_0x29f69d('0xe1e')))[_0x29f69d('0xe53')][_0x29f69d('0x683')](function(_0x36873e){const _0x28005b=_0x29f69d;_0x1fe7e2[_0x28005b('0xe65')][_0x28005b('0xf5d')]=_0x36873e[_0x28005b('0xf5d')];})[_0x29f69d('0x130a')](function(_0xc52ad4){const _0x459f34=_0x29f69d;console[_0x459f34('0x52a')](_0xc52ad4);});}function _0x5cc1e7(_0x59dcfe){const _0x28b90d=_0x54a867;_0x1fe7e2[_0x28b90d('0xe65')]=_0x59dcfe||{'count':0x0,'rows':[]};}function _0x1b4077(){const _0x42998b=_0x54a867;return _0x148a3d['interval'][_0x42998b('0x1e6e')]({'fields':'id,interval,IntervalId'})[_0x42998b('0xe53')][_0x42998b('0x683')](function(_0x460f2b){const _0x44a88e=_0x42998b;_0x1fe7e2[_0x44a88e('0xe98')]=_0x460f2b;})[_0x42998b('0x130a')](function(_0x155049){const _0xdafcfc=_0x42998b;console[_0xdafcfc('0x52a')](_0x155049);});}function _0x5443f(){const _0x2d4863=_0x54a867;_0x1fe7e2['promise']=_0x148a3d[_0x2d4863('0x14cb')]['get'](_0x1fe7e2[_0x2d4863('0x23a2')],_0x5cc1e7)[_0x2d4863('0xe53')];}function _0x332e9d(_0x18ffaf){const _0xce4e2c=_0x54a867;_0x2e3ca0()[_0xce4e2c('0x3ec')](_0x1fe7e2[_0xce4e2c('0xe65')][_0xce4e2c('0xf5d')],{'id':_0x18ffaf['id']}),_0x313d3c(),_0x13b0b4[_0xce4e2c('0x53')]({'title':_0xce4e2c('0x1f71'),'msg':_0x18ffaf[_0xce4e2c('0x1d75')]?_0x18ffaf['app']+_0xce4e2c('0x194d'):''});}function _0x1b4ce9(_0x35f352){const _0x1c75d2=_0x54a867,_0x302f90=_0x3a286c['confirm']()[_0x1c75d2('0xf28')](_0x1c75d2('0x188'))[_0x1c75d2('0x26e3')](''+_0x1fe7e2['selectedOutboundRouteApps'][_0x1c75d2('0x1564')]+'\x20selected'+_0x1c75d2('0x1ee7'))['ariaLabel'](_0x1c75d2('0x1b94'))['targetEvent'](_0x35f352)['ok']('OK')[_0x1c75d2('0x19fb')](_0x1c75d2('0x16b8'));_0x3a286c[_0x1c75d2('0x1d4')](_0x302f90)['then'](function(){const _0x20d441=_0x1c75d2;_0x1fe7e2[_0x20d441('0x2fd')]['forEach'](function(_0x576dcc){const _0x526a7c=_0x20d441;_0x2e3ca0()['remove'](_0x1fe7e2[_0x526a7c('0xe65')]['rows'],{'id':_0x576dcc['id']});}),_0x1fe7e2[_0x20d441('0x2fd')]=[],_0x313d3c();});}_0x2c029c[_0x54a867('0x26a2')](_0x54a867('0x4b8'),function(){_0x3d27bc['removeAllListeners']('voiceExtension:update');});}const _0x18e709=_0x3baa75;_0x4834b8['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x1de'),_0x189033('0x1f2d'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x4834b8(_0x4e0fbb,_0x3abf77,_0x1d3991,_0x2a491a,_0x11deac,_0x1138f2,_0x572d52,_0x21dd9e){const _0x11eaf8=_0x189033,_0x1e74fd=this;_0x1e74fd[_0x11eaf8('0x11ed')]=_0x572d52[_0x11eaf8('0x20b2')](),_0x1e74fd['errors']=[],_0x1e74fd[_0x11eaf8('0xf28')]=_0x11eaf8('0x241c')+(_0x2a491a[_0x11eaf8('0x11f3')]||_0x2a491a[_0x11eaf8('0x1d75')])[_0x11eaf8('0x80')](),_0x1e74fd[_0x11eaf8('0xbf0')]=angular[_0x11eaf8('0x1a86')](_0x2a491a),_0x1e74fd[_0x11eaf8('0x1134')]=_0x21dd9e,_0x1e74fd[_0x11eaf8('0x258d')]={};if(_0x1e74fd['custom'][_0x11eaf8('0x1407')])switch(_0x1e74fd['custom']['appType']?_0x1e74fd[_0x11eaf8('0xbf0')]['appType']['toLowerCase']():_0x1e74fd[_0x11eaf8('0xbf0')]['app'][_0x11eaf8('0x93a')]()){case _0x11eaf8('0xbf0'):break;case _0x11eaf8('0x205c'):{const _0x4b24ee=_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x1407')][_0x11eaf8('0x1fc5')](',');_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x1d46')]=_0x4b24ee[0x0],_0x1e74fd[_0x11eaf8('0xbf0')]['language']=_0x4b24ee[0x1],_0x1e74fd['custom'][_0x11eaf8('0x6d9')]=_0x4b24ee['slice'](0x2,_0x4b24ee[_0x11eaf8('0x1564')])[_0x11eaf8('0x1630')](',');}break;case'dialogflowv2':{const _0x5d3fa5=_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x1407')]['split'](',');_0x1e74fd[_0x11eaf8('0xbf0')]['projectId']=_0x5d3fa5[0x0],_0x1e74fd[_0x11eaf8('0xbf0')]['clientEmail']=_0x5d3fa5[0x1],_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x406')]=_0x5d3fa5[0x2],_0x1e74fd['custom'][_0x11eaf8('0x1a1c')]=_0x5d3fa5[0x3],_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x6d9')]=_0x5d3fa5['slice'](0x4,_0x5d3fa5[_0x11eaf8('0x1564')])[_0x11eaf8('0x1630')](',');}break;case _0x11eaf8('0x1db1'):{const _0x1c5a48=_0x1e74fd['custom'][_0x11eaf8('0x1407')][_0x11eaf8('0x1fc5')](',');_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x7ae')]=_0x1c5a48[0x0],_0x1e74fd[_0x11eaf8('0xbf0')]['secretaccesskey']=_0x1c5a48[0x1],_0x1e74fd['custom'][_0x11eaf8('0x5ba')]=_0x1c5a48[0x2],_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x11a9')]=_0x1c5a48[0x3],_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x6d9')]=_0x1c5a48[_0x11eaf8('0x12c8')](0x4,_0x1c5a48[_0x11eaf8('0x1564')])[_0x11eaf8('0x1630')](',');}break;case _0x11eaf8('0x2408'):{const _0x20e4f1=_0x1e74fd[_0x11eaf8('0xbf0')]['appdata'][_0x11eaf8('0x1fc5')](',');_0x1e74fd[_0x11eaf8('0xbf0')]['times']=isNaN(_0x20e4f1[0x0])?_0x20e4f1[0x0]:parseInt(_0x20e4f1[0x0],0xa),_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x1bcd')]=_0x20e4f1[_0x11eaf8('0x12c8')](0x1,_0x20e4f1[_0x11eaf8('0x1564')])['join'](',');}break;case _0x11eaf8('0x8c2'):_0x1e74fd['custom']['text']=_0x1e74fd['custom']['appdata'];break;case _0x11eaf8('0x877'):_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x60a')]=_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x1407')]['split']('=')[0x0],_0x1e74fd['custom'][_0x11eaf8('0x1c6b')]=_0x1e74fd['custom'][_0x11eaf8('0x1407')][_0x11eaf8('0x1fc5')]('=')[0x1];break;case'agi':_0x1e74fd[_0x11eaf8('0xbf0')]['project']=_0x1e74fd[_0x11eaf8('0xbf0')]['appdata'];break;default:{const _0x5d0dca=_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x1407')]['split'](',');_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x1d75')]=_0x2e3ca0()[_0x11eaf8('0x173f')](_0x5d0dca[0x0])?_0x5d0dca[0x0]:isNaN(_0x5d0dca[0x0])?_0x5d0dca[0x0]:parseInt(_0x5d0dca[0x0],0xa),_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x1407')]=_0x2e3ca0()[_0x11eaf8('0x173f')](_0x5d0dca[0x1])?_0x5d0dca[0x1]:isNaN(_0x5d0dca[0x1])?_0x5d0dca[0x1]:parseInt(_0x5d0dca[0x1],0xa);}break;}else{}_0x1e74fd[_0x11eaf8('0xbf0')]['type']&&_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0xcf0')]['toLowerCase']()==='outbound'&&_0x1e74fd['custom'][_0x11eaf8('0x11f3')][_0x11eaf8('0x93a')]()===_0x11eaf8('0x659')&&(_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x24fa')]=_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0xd31')]?_0x1e74fd[_0x11eaf8('0xbf0')]['phone'][_0x11eaf8('0x1fc5')]('$')[0x0]:undefined,_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0xabd')]=_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x73c')]?'CALLERID(all)='+_0x1e74fd[_0x11eaf8('0xbf0')][_0x11eaf8('0x73c')]:undefined);_0x1e74fd[_0x11eaf8('0x1c6c')]=_0x4fb539,_0x1e74fd['closeDialog']=_0x46dbbe;function _0x4fb539(){const _0x41a80c=_0x11eaf8;_0x1e74fd['errors']=[];const _0x3dbc26=[];_0x1e74fd[_0x41a80c('0xbf0')]['type']&&_0x1e74fd['custom'][_0x41a80c('0xcf0')]['toLowerCase']()===_0x41a80c('0x17cd')&&_0x1e74fd['custom'][_0x41a80c('0x11f3')]===_0x41a80c('0x4d2')&&(_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0xd31')]=_0x11deac[_0x41a80c('0x145a')]?(_0x1e74fd['custom'][_0x41a80c('0x24fa')]||'')+'${EXTEN:'+_0x11deac[_0x41a80c('0x145a')]+'}':(_0x1e74fd[_0x41a80c('0xbf0')]['prefix']||'')+_0x41a80c('0x20cb'),_0x11deac[_0x41a80c('0x75b')]!==_0x41a80c('0x925')?_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x158e')][_0x41a80c('0x824')](_0x41a80c('0x1b1'))<0x0&&(_0x1e74fd[_0x41a80c('0xbf0')]['options']+=_0x41a80c('0x1b1')):_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x158e')]=_0x1e74fd['custom']['options'][_0x41a80c('0x1725')](_0x41a80c('0x1b1'),''));if(_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x11f3')]&&_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x11f3')]==='custom'){}else switch((_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x1d75')]||_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x11f3')])[_0x41a80c('0x93a')]()){case _0x41a80c('0x877'):_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x1407')]=_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x60a')]+'='+_0x1e74fd['custom'][_0x41a80c('0x1c6b')];break;case _0x41a80c('0xbf0'):break;default:_0x3dbc26[0x0]=_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x1d75')],_0x3dbc26[0x1]=_0x1e74fd[_0x41a80c('0xbf0')]['appdata'],_0x1e74fd[_0x41a80c('0xbf0')][_0x41a80c('0x1407')]=_0x3dbc26['join'](',');}_0x46dbbe(_0x1e74fd[_0x41a80c('0xbf0')]);}function _0x46dbbe(_0x270bcf){const _0x4f2203=_0x11eaf8;_0x4e0fbb[_0x4f2203('0x1715')](_0x270bcf);}}const _0x3f9c71=_0x4834b8;_0x4d633a[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x1e48'),_0x189033('0xb33'),_0x189033('0x844'),_0x189033('0x115c'),_0x189033('0xe98'),_0x189033('0x1d70'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x4d633a(_0x43af9f,_0x2316d9,_0x2b9eaa,_0x1c02eb,_0x12ef64,_0x45a044,_0x3726a4,_0x33c1da,_0x4f52ca,_0x525159){const _0x4299de=_0x189033,_0x2ae20e=this;_0x2ae20e[_0x4299de('0x11ed')]=_0x4f52ca[_0x4299de('0x20b2')](),_0x2ae20e['errors']=[],_0x2ae20e[_0x4299de('0xf28')]=_0x4299de('0xc62'),_0x2ae20e[_0x4299de('0x115c')]=angular['copy'](_0x12ef64),_0x2ae20e['intervals']=_0x45a044,_0x2ae20e[_0x4299de('0x1470')]=![],_0x2ae20e[_0x4299de('0x1de1')]=[_0x4299de('0x10af'),_0x4299de('0xbf0'),_0x4299de('0x2335')],_0x2ae20e[_0x4299de('0x1134')]=_0x525159,_0x2ae20e[_0x4299de('0x167a')]=_0x1c02eb[_0x4299de('0xe88')](),_0x2ae20e[_0x4299de('0x1dfd')]=_0x1c02eb[_0x4299de('0x222e')](),_0x2ae20e[_0x4299de('0x1e32')]=_0x1c02eb[_0x4299de('0x1fe4')](),_0x2ae20e[_0x4299de('0x13ce')]=_0x1c02eb[_0x4299de('0x181b')]();if(!_0x2ae20e[_0x4299de('0x115c')])_0x2ae20e[_0x4299de('0x115c')]={'interval':_0x4299de('0x1b54')},_0x2ae20e[_0x4299de('0xcf0')]='always',_0x2ae20e[_0x4299de('0xf28')]=_0x4299de('0x1e94'),_0x2ae20e['newInterval']=!![];else{if(_0x2ae20e[_0x4299de('0x115c')][_0x4299de('0x115c')]!==_0x4299de('0x1b54')){_0x2ae20e['type']='custom';const _0x12e453=_0x2ae20e[_0x4299de('0x115c')]['interval'][_0x4299de('0x1fc5')](','),_0x3b6591=_0x12e453[0x0],_0x4bb368=_0x12e453[0x1],_0x434fe9=_0x12e453[0x2],_0x5c376f=_0x12e453[0x3];if(_0x3b6591!=='*'){const _0x312f0f=_0x3b6591[_0x4299de('0x1fc5')]('-')[0x0],_0x10d788=_0x3b6591[_0x4299de('0x1fc5')]('-')[0x1];let _0x459cbb;_0x459cbb=new Date(),_0x459cbb[_0x4299de('0x2813')](Number(_0x312f0f[_0x4299de('0x1fc5')](':')[0x0])),_0x459cbb[_0x4299de('0x1fb7')](Number(_0x312f0f[_0x4299de('0x1fc5')](':')[0x1])),_0x2ae20e[_0x4299de('0xc32')]=_0x459cbb,_0x459cbb=new Date(),_0x459cbb[_0x4299de('0x2813')](Number(_0x10d788[_0x4299de('0x1fc5')](':')[0x0])),_0x459cbb['setMinutes'](Number(_0x10d788[_0x4299de('0x1fc5')](':')[0x1])),_0x2ae20e['timeRangeTo']=_0x459cbb;}_0x4bb368!=='*'&&(_0x2ae20e[_0x4299de('0x232d')]=_0x4bb368[_0x4299de('0x1fc5')]('-')[0x0],_0x2ae20e[_0x4299de('0x1269')]=_0x4bb368[_0x4299de('0x1fc5')]('-')[0x1]),_0x434fe9!=='*'&&(_0x2ae20e[_0x4299de('0xf13')]=_0x434fe9[_0x4299de('0x1fc5')]('-')[0x0],_0x2ae20e['monthDayTo']=_0x434fe9[_0x4299de('0x1fc5')]('-')[0x1]),_0x5c376f!=='*'&&(_0x2ae20e['monthFrom']=_0x5c376f[_0x4299de('0x1fc5')]('-')[0x0],_0x2ae20e['monthTo']=_0x5c376f['split']('-')[0x1]);}else _0x2ae20e['type']='always';}_0x43af9f['params']['id']&&!_0x2ae20e[_0x4299de('0x115c')][_0x4299de('0x121e')]&&(_0x2ae20e[_0x4299de('0x115c')][_0x4299de('0x5ae')]=_0x43af9f[_0x4299de('0x7f2')]['id']);_0x2ae20e['interval'][_0x4299de('0x5ae')]&&_0x2ae20e['interval'][_0x4299de('0x121e')]&&(_0x2ae20e[_0x4299de('0xcf0')]=_0x4299de('0x2335'));_0x2ae20e[_0x4299de('0x1a4d')]=_0x181fc9,_0x2ae20e[_0x4299de('0x1807')]=_0x325348,_0x2ae20e[_0x4299de('0xf82')]=_0x522278;_0x2ae20e[_0x4299de('0x115c')][_0x4299de('0x121e')]&&(_0x4f52ca['hasRole']('admin')?_0x33c1da[_0x4299de('0x115c')][_0x4299de('0x1e6e')]({'fields':_0x4299de('0x1e24'),'IntervalId':_0x4299de('0x13c'),'nolimit':!![]})[_0x4299de('0xe53')]['then'](function(_0x5484d7){const _0xf774fb=_0x4299de;_0x2ae20e['intervals']=_0x5484d7[_0xf774fb('0xf5d')]||[];})[_0x4299de('0x130a')](function(_0x32d258){const _0x498914=_0x4299de;_0x3726a4[_0x498914('0x52a')]({'title':_0x32d258[_0x498914('0x13ee')]?'API:'+_0x32d258[_0x498914('0x13ee')]+_0x498914('0xbf6')+_0x32d258['statusText']:'SYSTEM:GET_INTERVALS','msg':_0x32d258[_0x498914('0x5a5')]?JSON[_0x498914('0x258a')](_0x32d258['data']):_0x32d258[_0x498914('0x1ff0')]()});}):_0x33c1da['interval'][_0x4299de('0x1e6e')]({'fields':_0x4299de('0x1e24'),'IntervalId':'null','nolimit':!![]})['$promise'][_0x4299de('0x683')](function(_0xbf243b){const _0x11d741=_0x4299de;_0x2ae20e['intervals']=_0xbf243b[_0x11d741('0xf5d')]||[];})[_0x4299de('0x683')](function(){const _0x19ea36=_0x4299de;return _0x33c1da[_0x19ea36('0x22df')][_0x19ea36('0x1e6e')]({'userProfileId':_0x2ae20e[_0x19ea36('0x11ed')]['userProfileId'],'sectionId':0x3ec})[_0x19ea36('0xe53')];})[_0x4299de('0x683')](function(_0x53234d){const _0x57e06e=_0x4299de,_0x21ce37=_0x53234d&&_0x53234d['rows']?_0x53234d[_0x57e06e('0xf5d')][0x0]:null;if(!_0x21ce37)_0x2ae20e['intervals']=[];else{if(!_0x21ce37[_0x57e06e('0x170')])return _0x33c1da[_0x57e06e('0xcf7')][_0x57e06e('0x1e6e')]({'sectionId':_0x21ce37['id']})['$promise'][_0x57e06e('0x683')](function(_0xb2397b){const _0x542823=_0x57e06e,_0x2fbb7a=_0xb2397b&&_0xb2397b[_0x542823('0xf5d')]?_0xb2397b[_0x542823('0xf5d')]:[],_0x2ba636=[];let _0x1aea0e=null;_0x2ae20e[_0x542823('0x115c')]&&(_0x1aea0e=_0x2e3ca0()[_0x542823('0x1c07')](_0x2ae20e[_0x542823('0xe98')],{'name':_0x2ae20e[_0x542823('0x115c')][_0x542823('0x5ae')]})),_0x1aea0e&&!_0x2e3ca0()[_0x542823('0x7a2')](_0x2fbb7a,[_0x542823('0x832'),_0x1aea0e['id']])&&_0x2ae20e[_0x542823('0xe98')]['forEach'](function(_0x37e03a){const _0x143cbb=_0x542823;_0x37e03a['id']===_0x1aea0e['id']&&(_0x37e03a[_0x143cbb('0x319')]=![],_0x2ba636['push'](_0x37e03a));}),_0x2ae20e[_0x542823('0xe98')]=_0x2ba636;});}})['catch'](function(_0xf3a520){const _0x5c698d=_0x4299de;_0x3726a4['error']({'title':_0xf3a520[_0x5c698d('0x13ee')]?_0x5c698d('0x2168')+_0xf3a520['status']+_0x5c698d('0xbf6')+_0xf3a520[_0x5c698d('0x24a9')]:_0x5c698d('0x1e65'),'msg':_0xf3a520[_0x5c698d('0x5a5')]?JSON['stringify'](_0xf3a520['data']):_0xf3a520[_0x5c698d('0x1ff0')]()});}));function _0x2d4f7c(){const _0x591310=_0x4299de;switch(_0x2ae20e['type']){case _0x591310('0x10af'):case _0x591310('0x2335'):return _0x591310('0x1b54');case _0x591310('0xbf0'):{const _0x2ccb38=[];if(_0x2ae20e[_0x591310('0xc32')]!=='*'&&_0x2ae20e[_0x591310('0xc32')]&&_0x2ae20e[_0x591310('0xaa0')]){const _0x304162=(_0x2ae20e['timeRangeFrom'][_0x591310('0x2575')]()<0xa?'0':'')+_0x2ae20e['timeRangeFrom']['getHours']()+':'+((_0x2ae20e[_0x591310('0xc32')][_0x591310('0x1b5b')]()<0xa?'0':'')+_0x2ae20e[_0x591310('0xc32')][_0x591310('0x1b5b')]()),_0x5cdcf5=(_0x2ae20e[_0x591310('0xaa0')][_0x591310('0x2575')]()<0xa?'0':'')+_0x2ae20e['timeRangeTo'][_0x591310('0x2575')]()+':'+((_0x2ae20e[_0x591310('0xaa0')][_0x591310('0x1b5b')]()<0xa?'0':'')+_0x2ae20e[_0x591310('0xaa0')][_0x591310('0x1b5b')]());_0x2ccb38['push'](_0x304162+'-'+_0x5cdcf5);}else _0x2ccb38['push']('*');return _0x2ae20e[_0x591310('0x232d')]?_0x2ae20e[_0x591310('0x1269')]?_0x2ccb38[_0x591310('0x1fd0')](_0x2ae20e['dayOfWeekFrom']+'-'+_0x2ae20e[_0x591310('0x1269')]):_0x2ccb38[_0x591310('0x1fd0')](_0x2ae20e[_0x591310('0x232d')]):_0x2ccb38['push']('*'),_0x2ae20e[_0x591310('0xf13')]?_0x2ae20e[_0x591310('0xfe5')]?_0x2ccb38[_0x591310('0x1fd0')](_0x2ae20e['monthDayFrom']+'-'+_0x2ae20e[_0x591310('0xfe5')]):_0x2ccb38[_0x591310('0x1fd0')](_0x2ae20e[_0x591310('0xf13')]):_0x2ccb38[_0x591310('0x1fd0')]('*'),_0x2ae20e[_0x591310('0x1690')]?_0x2ae20e[_0x591310('0x1f12')]?_0x2ccb38[_0x591310('0x1fd0')](_0x2ae20e[_0x591310('0x1690')]+'-'+_0x2ae20e[_0x591310('0x1f12')]):_0x2ccb38[_0x591310('0x1fd0')](_0x2ae20e[_0x591310('0x1690')]):_0x2ccb38[_0x591310('0x1fd0')]('*'),_0x2ccb38[_0x591310('0x1630')]();}}}function _0x181fc9(){const _0x5742f3=_0x4299de;_0x2ae20e[_0x5742f3('0x17f')]=[],_0x2ae20e[_0x5742f3('0x115c')][_0x5742f3('0x115c')]=_0x2d4f7c(),_0x33c1da[_0x5742f3('0x115c')][_0x5742f3('0xb0a')](_0x2ae20e[_0x5742f3('0x115c')])[_0x5742f3('0xe53')][_0x5742f3('0x683')](function(_0x4380ad){const _0x115940=_0x5742f3;_0x2ae20e[_0x115940('0xe98')][_0x115940('0x1fd0')](_0x4380ad),_0x3726a4[_0x115940('0x53')]({'title':_0x115940('0x24b5'),'msg':_0x2ae20e[_0x115940('0x115c')][_0x115940('0x60a')]?_0x2ae20e['interval'][_0x115940('0x60a')]+_0x115940('0x14b5'):''}),_0x522278();})[_0x5742f3('0x130a')](function(_0x25b861){const _0x7637d9=_0x5742f3;console[_0x7637d9('0x52a')](_0x25b861),_0x2ae20e[_0x7637d9('0x17f')]=_0x25b861['data']['errors']||[{'message':_0x25b861['toString'](),'type':_0x7637d9('0x1d24')}];});}function _0x325348(){const _0x385a60=_0x4299de;_0x2ae20e['errors']=[],_0x2ae20e['interval'][_0x385a60('0x115c')]=_0x2d4f7c(),_0x2ae20e[_0x385a60('0x115c')][_0x385a60('0x121e')]?(_0x2ae20e[_0x385a60('0xcf0')]!==_0x385a60('0x2335')&&(_0x2ae20e[_0x385a60('0x115c')][_0x385a60('0x5ae')]=null),_0x522278(_0x2ae20e[_0x385a60('0x115c')])):_0x33c1da['interval'][_0x385a60('0x2480')]({'id':_0x2ae20e['interval']['id']},_0x2ae20e[_0x385a60('0x115c')])['$promise']['then'](function(_0x335167){const _0x2ced36=_0x385a60,_0x55b52d=_0x2e3ca0()[_0x2ced36('0x1c07')](_0x2ae20e[_0x2ced36('0xe98')],{'id':_0x335167['id']});_0x55b52d&&_0x2e3ca0()[_0x2ced36('0xf22')](_0x55b52d,_0x335167),_0x3726a4[_0x2ced36('0x53')]({'title':_0x2ced36('0x18c3'),'msg':_0x2ced36('0x224')}),_0x522278();})[_0x385a60('0x130a')](function(_0x327fb0){const _0x29d93d=_0x385a60;console[_0x29d93d('0x52a')](_0x327fb0),_0x2ae20e[_0x29d93d('0x17f')]=_0x327fb0[_0x29d93d('0x5a5')][_0x29d93d('0x17f')]||[{'message':_0x327fb0[_0x29d93d('0x1ff0')](),'type':_0x29d93d('0x605')}];});}function _0x522278(_0x42b444){const _0x4ba7fd=_0x4299de;_0x2316d9[_0x4ba7fd('0x1715')](_0x42b444);}}const _0x514ac3=_0x4d633a;_0x36494c[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x1de'),'outboundroute',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x36494c(_0x1a778f,_0x1eb515,_0x406221,_0xd402ca,_0x144e64,_0x6da823,_0x42e01c,_0x3750c4){const _0x113417=_0x189033,_0x5e2589=this;_0x5e2589[_0x113417('0x11ed')]=_0x42e01c['getCurrentUser'](),_0x5e2589['errors']=[],_0x5e2589['title']='VOICE.EDIT_'+(_0xd402ca['appType']||_0xd402ca[_0x113417('0x1d75')])[_0x113417('0x80')](),_0x5e2589['outbounddial']=angular['copy'](_0xd402ca),_0x5e2589[_0x113417('0x1134')]=_0x3750c4,_0x5e2589[_0x113417('0x258d')]={};if(_0x5e2589[_0x113417('0x659')]['appdata'])switch(_0x5e2589[_0x113417('0x659')][_0x113417('0x11f3')]?_0x5e2589['outbounddial'][_0x113417('0x11f3')][_0x113417('0x93a')]():_0x5e2589[_0x113417('0x659')]['app']['toLowerCase']()){case _0x113417('0xbf0'):break;case _0x113417('0x205c'):{const _0x4a1820=_0x5e2589[_0x113417('0x659')][_0x113417('0x1407')][_0x113417('0x1fc5')](',');_0x5e2589['outbounddial'][_0x113417('0x1d46')]=_0x4a1820[0x0],_0x5e2589[_0x113417('0x659')][_0x113417('0x1a1c')]=_0x4a1820[0x1],_0x5e2589[_0x113417('0x659')][_0x113417('0x6d9')]=_0x4a1820[_0x113417('0x12c8')](0x2,_0x4a1820[_0x113417('0x1564')])[_0x113417('0x1630')](',');}break;case _0x113417('0xd24'):{const _0x37b98d=_0x5e2589[_0x113417('0x659')][_0x113417('0x1407')][_0x113417('0x1fc5')](',');_0x5e2589[_0x113417('0x659')]['projectId']=_0x37b98d[0x0],_0x5e2589[_0x113417('0x659')]['clientEmail']=_0x37b98d[0x1],_0x5e2589[_0x113417('0x659')][_0x113417('0x406')]=_0x37b98d[0x2],_0x5e2589[_0x113417('0x659')][_0x113417('0x1a1c')]=_0x37b98d[0x3],_0x5e2589[_0x113417('0x659')][_0x113417('0x6d9')]=_0x37b98d[_0x113417('0x12c8')](0x4,_0x37b98d[_0x113417('0x1564')])[_0x113417('0x1630')](',');}break;case'amazonlex':{const _0x5ea7c4=_0x5e2589[_0x113417('0x659')][_0x113417('0x1407')][_0x113417('0x1fc5')](',');_0x5e2589[_0x113417('0x659')][_0x113417('0x7ae')]=_0x5ea7c4[0x0],_0x5e2589[_0x113417('0x659')]['secretaccesskey']=_0x5ea7c4[0x1],_0x5e2589['outbounddial'][_0x113417('0x5ba')]=_0x5ea7c4[0x2],_0x5e2589[_0x113417('0x659')][_0x113417('0x11a9')]=_0x5ea7c4[0x3],_0x5e2589[_0x113417('0x659')]['welcomemessage']=_0x5ea7c4[_0x113417('0x12c8')](0x4,_0x5ea7c4[_0x113417('0x1564')])[_0x113417('0x1630')](',');}break;case _0x113417('0x2408'):{const _0x1127f2=_0x5e2589[_0x113417('0x659')][_0x113417('0x1407')][_0x113417('0x1fc5')](',');_0x5e2589[_0x113417('0x659')][_0x113417('0x35')]=isNaN(_0x1127f2[0x0])?_0x1127f2[0x0]:parseInt(_0x1127f2[0x0],0xa),_0x5e2589[_0x113417('0x659')][_0x113417('0x1bcd')]=_0x1127f2[_0x113417('0x12c8')](0x1,_0x1127f2['length'])[_0x113417('0x1630')](',');}break;case _0x113417('0x8c2'):_0x5e2589[_0x113417('0x659')]['text']=_0x5e2589[_0x113417('0x659')]['appdata'];break;case _0x113417('0x877'):_0x5e2589[_0x113417('0x659')][_0x113417('0x60a')]=_0x5e2589[_0x113417('0x659')][_0x113417('0x1407')][_0x113417('0x1fc5')]('=')[0x0],_0x5e2589[_0x113417('0x659')][_0x113417('0x1c6b')]=_0x5e2589[_0x113417('0x659')]['appdata']['split']('=')[0x1];break;case _0x113417('0x19ae'):_0x5e2589['outbounddial'][_0x113417('0x273a')]=_0x5e2589[_0x113417('0x659')][_0x113417('0x1407')];break;default:{const _0x4ccfd0=_0x5e2589[_0x113417('0x659')][_0x113417('0x1407')][_0x113417('0x1fc5')](',');_0x5e2589[_0x113417('0x659')]['trunk']=_0x4ccfd0[0x0][_0x113417('0x1fc5')]('/')[0x1],_0x5e2589[_0x113417('0x659')]['phone']=_0x4ccfd0[0x0][_0x113417('0x1fc5')]('/')[0x2],_0x5e2589[_0x113417('0x659')][_0x113417('0x1668')]=_0x2e3ca0()['isEmpty'](_0x4ccfd0[0x1])?_0x4ccfd0[0x1]:isNaN(_0x4ccfd0[0x1])?_0x4ccfd0[0x1]:parseInt(_0x4ccfd0[0x1],0xa),_0x5e2589[_0x113417('0x659')][_0x113417('0x158e')]=_0x2e3ca0()[_0x113417('0x173f')](_0x4ccfd0[0x2])?_0x4ccfd0[0x2]:isNaN(_0x4ccfd0[0x2])?_0x4ccfd0[0x2]:parseInt(_0x4ccfd0[0x2],0xa),_0x5e2589[_0x113417('0x659')][_0x113417('0x1284')]=_0x2e3ca0()['isEmpty'](_0x4ccfd0[0x3])?_0x4ccfd0[0x3]:isNaN(_0x4ccfd0[0x3])?_0x4ccfd0[0x3]:parseInt(_0x4ccfd0[0x3],0xa);}break;}else{}_0x5e2589[_0x113417('0x659')]['type']&&_0x5e2589[_0x113417('0x659')][_0x113417('0xcf0')][_0x113417('0x93a')]()===_0x113417('0x17cd')&&_0x5e2589[_0x113417('0x659')][_0x113417('0x11f3')][_0x113417('0x93a')]()===_0x113417('0x659')&&(_0x5e2589[_0x113417('0x659')][_0x113417('0x24fa')]=_0x5e2589[_0x113417('0x659')][_0x113417('0xd31')]?_0x5e2589[_0x113417('0x659')][_0x113417('0xd31')]['split']('$')[0x0]:undefined,_0x5e2589[_0x113417('0x659')]['callerId']=_0x5e2589[_0x113417('0x659')]['callerID']?'CALLERID(all)='+_0x5e2589[_0x113417('0x659')][_0x113417('0x73c')]:undefined);_0x5e2589[_0x113417('0x1c6c')]=_0x5a21c5,_0x5e2589[_0x113417('0xf82')]=_0xe1a83e,_0x42e01c[_0x113417('0xca1')](_0x113417('0x20c2'))?_0x6da823[_0x113417('0x1a93')][_0x113417('0x1e6e')]({'fields':_0x113417('0xa10'),'sort':_0x113417('0x60a'),'nolimit':_0x113417('0x26ac')})[_0x113417('0xe53')][_0x113417('0x683')](function(_0x4dfb58){const _0x254bd6=_0x113417;_0x5e2589[_0x254bd6('0x20fe')]=_0x4dfb58[_0x254bd6('0xf5d')]||[];})[_0x113417('0x130a')](function(_0x51229c){const _0x36d87f=_0x113417;_0x406221[_0x36d87f('0x52a')]({'title':_0x51229c[_0x36d87f('0x13ee')]?_0x36d87f('0x2168')+_0x51229c[_0x36d87f('0x13ee')]+_0x36d87f('0xbf6')+_0x51229c[_0x36d87f('0x24a9')]:_0x36d87f('0xfd0'),'msg':_0x51229c['data']?JSON[_0x36d87f('0x258a')](_0x51229c['data']):_0x51229c[_0x36d87f('0x1ff0')]()});}):_0x6da823[_0x113417('0x1a93')][_0x113417('0x1e6e')]({'fields':_0x113417('0xa10'),'sort':_0x113417('0x60a'),'nolimit':_0x113417('0x26ac')})[_0x113417('0xe53')][_0x113417('0x683')](function(_0x4f05a7){const _0x47beb6=_0x113417;_0x5e2589[_0x47beb6('0x20fe')]=_0x4f05a7[_0x47beb6('0xf5d')]||[];})[_0x113417('0x683')](function(){const _0x388b1a=_0x113417;return _0x6da823[_0x388b1a('0x22df')][_0x388b1a('0x1e6e')]({'userProfileId':_0x5e2589[_0x388b1a('0x11ed')][_0x388b1a('0x2f')],'sectionId':0x3f3})[_0x388b1a('0xe53')];})[_0x113417('0x683')](function(_0x1d80e1){const _0x45c0c6=_0x113417,_0x5cb005=_0x1d80e1&&_0x1d80e1['rows']?_0x1d80e1['rows'][0x0]:null;if(!_0x5cb005){const _0x2a22c7=[];let _0x4cecbe=null;_0x5e2589[_0x45c0c6('0x659')]&&(_0x4cecbe=_0x2e3ca0()[_0x45c0c6('0x1c07')](_0x5e2589[_0x45c0c6('0x20fe')],{'name':_0x5e2589[_0x45c0c6('0x659')][_0x45c0c6('0x1a93')]}));for(let _0x24f1a3=0x0;_0x24f1a3<_0x5e2589['trunks'][_0x45c0c6('0x1564')];_0x24f1a3++){_0x4cecbe&&_0x5e2589[_0x45c0c6('0x20fe')][_0x24f1a3]['id']===_0x4cecbe['id']&&(_0x5e2589['trunks'][_0x24f1a3]['canSelect']=![],_0x2a22c7[_0x45c0c6('0x1fd0')](_0x5e2589[_0x45c0c6('0x20fe')][_0x24f1a3]));}_0x5e2589['trunks']=_0x2a22c7;}else{if(!_0x5cb005[_0x45c0c6('0x170')])return _0x6da823['userProfileResource'][_0x45c0c6('0x1e6e')]({'sectionId':_0x5cb005['id']})[_0x45c0c6('0xe53')][_0x45c0c6('0x683')](function(_0x53621b){const _0x153deb=_0x45c0c6,_0x4e2af1=_0x2e3ca0()[_0x153deb('0x386')](_0x53621b[_0x153deb('0xf5d')],function(_0x232446){const _0x4ea096=_0x153deb;return _0x2e3ca0()[_0x4ea096('0x1c07')](_0x5e2589['trunks'],{'id':_0x232446['resourceId']});});let _0x5c2e66=null;_0x5e2589[_0x153deb('0x659')]&&(_0x5c2e66=_0x2e3ca0()['find'](_0x5e2589[_0x153deb('0x20fe')],{'name':_0x5e2589[_0x153deb('0x659')][_0x153deb('0x1a93')]}));if(_0x5c2e66&&!_0x2e3ca0()[_0x153deb('0x7a2')](_0x4e2af1,['id',_0x5c2e66['id']])){const _0x37080d=_0x2e3ca0()[_0x153deb('0x1c07')](_0x5e2589['trunks'],{'id':_0x5c2e66['id']});_0x37080d[_0x153deb('0x319')]=![],_0x4e2af1[_0x153deb('0x1fd0')](_0x37080d);}_0x5e2589['trunks']=_0x4e2af1;});}})[_0x113417('0x130a')](function(_0x371392){const _0xd059e4=_0x113417;_0x406221['error']({'title':_0x371392[_0xd059e4('0x13ee')]?_0xd059e4('0x2168')+_0x371392[_0xd059e4('0x13ee')]+'\x20-\x20'+_0x371392[_0xd059e4('0x24a9')]:_0xd059e4('0x93'),'msg':_0x371392[_0xd059e4('0x5a5')]?JSON[_0xd059e4('0x258a')](_0x371392[_0xd059e4('0x5a5')]):_0x371392[_0xd059e4('0x1ff0')]()});}),_0x42e01c['hasRole']('admin')?_0x6da823[_0x113417('0x270')][_0x113417('0x1e6e')]({'fields':_0x113417('0xa10'),'sort':_0x113417('0x60a'),'nolimit':_0x113417('0x26ac')})['$promise'][_0x113417('0x683')](function(_0x11a668){const _0x813bbc=_0x113417;_0x5e2589[_0x813bbc('0x1ce6')]=_0x11a668['rows']||[];})['catch'](function(_0x286d80){const _0x4935e3=_0x113417;_0x406221[_0x4935e3('0x52a')]({'title':_0x286d80['status']?_0x4935e3('0x2168')+_0x286d80[_0x4935e3('0x13ee')]+_0x4935e3('0xbf6')+_0x286d80[_0x4935e3('0x24a9')]:_0x4935e3('0x14ef'),'msg':_0x286d80[_0x4935e3('0x5a5')]?JSON[_0x4935e3('0x258a')](_0x286d80[_0x4935e3('0x5a5')]):_0x286d80[_0x4935e3('0x1ff0')]()});}):_0x6da823[_0x113417('0x270')][_0x113417('0x1e6e')]({'fields':_0x113417('0xa10'),'sort':_0x113417('0x60a'),'nolimit':_0x113417('0x26ac')})[_0x113417('0xe53')][_0x113417('0x683')](function(_0x1bb548){const _0x5ea379=_0x113417;_0x5e2589[_0x5ea379('0x1ce6')]=_0x1bb548[_0x5ea379('0xf5d')]||[];})[_0x113417('0x683')](function(){const _0x3cd73c=_0x113417;return _0x6da823[_0x3cd73c('0x22df')][_0x3cd73c('0x1e6e')]({'userProfileId':_0x5e2589[_0x3cd73c('0x11ed')][_0x3cd73c('0x2f')],'sectionId':0x3f0})[_0x3cd73c('0xe53')];})[_0x113417('0x683')](function(_0x3596a6){const _0x1a2252=_0x113417,_0x443a98=_0x3596a6&&_0x3596a6[_0x1a2252('0xf5d')]?_0x3596a6[_0x1a2252('0xf5d')][0x0]:null;if(!_0x443a98){const _0x13726c=[];let _0x355217=null;_0x5e2589[_0x1a2252('0x659')]&&(_0x355217=_0x2e3ca0()['find'](_0x5e2589[_0x1a2252('0x1ce6')],{'name':_0x5e2589[_0x1a2252('0x659')][_0x1a2252('0x270')]}));for(let _0x249939=0x0;_0x249939<_0x5e2589['tags'][_0x1a2252('0x1564')];_0x249939++){_0x355217&&_0x5e2589['tags'][_0x249939]['id']===_0x355217['id']&&(_0x5e2589[_0x1a2252('0x1ce6')][_0x249939]['canSelect']=![],_0x13726c['push'](_0x5e2589[_0x1a2252('0x1ce6')][_0x249939]));}_0x5e2589[_0x1a2252('0x1ce6')]=_0x13726c;}else{if(!_0x443a98[_0x1a2252('0x170')])return _0x6da823[_0x1a2252('0xcf7')][_0x1a2252('0x1e6e')]({'sectionId':_0x443a98['id']})[_0x1a2252('0xe53')][_0x1a2252('0x683')](function(_0x606b71){const _0x4d1a9d=_0x1a2252,_0x7da192=_0x2e3ca0()[_0x4d1a9d('0x386')](_0x606b71['rows'],function(_0x3db2e2){const _0x5a2b23=_0x4d1a9d;return _0x2e3ca0()[_0x5a2b23('0x1c07')](_0x5e2589['tags'],{'id':_0x3db2e2['resourceId']});});let _0x4fb899=null;_0x5e2589['outbounddial']&&(_0x4fb899=_0x2e3ca0()[_0x4d1a9d('0x1c07')](_0x5e2589[_0x4d1a9d('0x1ce6')],{'name':_0x5e2589[_0x4d1a9d('0x659')][_0x4d1a9d('0x270')]}));if(_0x4fb899&&!_0x2e3ca0()[_0x4d1a9d('0x7a2')](_0x7da192,['id',_0x4fb899['id']])){const _0x1b1306=_0x2e3ca0()['find'](_0x5e2589['tags'],{'id':_0x4fb899['id']});_0x1b1306[_0x4d1a9d('0x319')]=![],_0x7da192[_0x4d1a9d('0x1fd0')](_0x1b1306);}_0x5e2589['tags']=_0x7da192;});}})['catch'](function(_0x539bb6){const _0x25c2a2=_0x113417;_0x406221[_0x25c2a2('0x52a')]({'title':_0x539bb6[_0x25c2a2('0x13ee')]?'API:'+_0x539bb6[_0x25c2a2('0x13ee')]+_0x25c2a2('0xbf6')+_0x539bb6[_0x25c2a2('0x24a9')]:_0x25c2a2('0x1118'),'msg':_0x539bb6[_0x25c2a2('0x5a5')]?JSON[_0x25c2a2('0x258a')](_0x539bb6[_0x25c2a2('0x5a5')]):_0x539bb6[_0x25c2a2('0x1ff0')]()});});function _0x5a21c5(){const _0x3676e6=_0x113417;_0x5e2589[_0x3676e6('0x17f')]=[];const _0x4a7055=[];_0x5e2589['outbounddial'][_0x3676e6('0xcf0')]&&_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0xcf0')][_0x3676e6('0x93a')]()===_0x3676e6('0x17cd')&&_0x5e2589[_0x3676e6('0x659')]['appType']===_0x3676e6('0x4d2')&&(_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0xd31')]=_0x144e64[_0x3676e6('0x145a')]?(_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0x24fa')]||'')+_0x3676e6('0x249e')+_0x144e64[_0x3676e6('0x145a')]+'}':(_0x5e2589[_0x3676e6('0x659')]['prefix']||'')+'${EXTEN}',_0x144e64[_0x3676e6('0x75b')]!=='none'?_0x5e2589['outbounddial'][_0x3676e6('0x158e')][_0x3676e6('0x824')](_0x3676e6('0x1b1'))<0x0&&(_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0x158e')]+=_0x3676e6('0x1b1')):_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0x158e')]=_0x5e2589[_0x3676e6('0x659')]['options'][_0x3676e6('0x1725')](_0x3676e6('0x1b1'),''));if(_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0x11f3')]&&_0x5e2589['outbounddial'][_0x3676e6('0x11f3')]===_0x3676e6('0xbf0')){}else switch((_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0x1d75')]||_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0x11f3')])[_0x3676e6('0x93a')]()){case _0x3676e6('0x877'):_0x5e2589['outbounddial'][_0x3676e6('0x1407')]=_0x5e2589[_0x3676e6('0x659')]['name']+'='+_0x5e2589[_0x3676e6('0x659')]['value'];break;case _0x3676e6('0xbf0'):break;default:_0x4a7055[0x0]=[_0x3676e6('0xcec'),_0x5e2589['outbounddial'][_0x3676e6('0x1a93')],_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0xd31')]][_0x3676e6('0x1630')]('/'),_0x4a7055[0x1]=_0x5e2589['outbounddial'][_0x3676e6('0x1668')],_0x4a7055[0x2]=_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0x158e')],_0x4a7055[0x3]=_0x5e2589['outbounddial'][_0x3676e6('0x1284')],_0x5e2589[_0x3676e6('0x659')][_0x3676e6('0x1407')]=_0x4a7055['join'](',');}_0xe1a83e(_0x5e2589['outbounddial']);}function _0xe1a83e(_0x350dd2){const _0x527f0f=_0x113417;_0x1a778f[_0x527f0f('0x1715')](_0x350dd2);}}const _0x1435d8=_0x36494c;_0x36fbd5['$inject']=[_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),'api','toasty',_0x189033('0xba1'),_0x189033('0x1f2d'),_0x189033('0x22df')];function _0x36fbd5(_0x32189c,_0x553c01,_0x1a7887,_0xfe77ac,_0x193129,_0x28335b,_0x5978ad,_0x544439,_0xd63e2f,_0x1601de,_0x2eb0e4,_0x57694b){const _0x5133a2=_0x189033,_0x351f4e=this;_0x351f4e[_0x5133a2('0x11ed')]=_0x1601de[_0x5133a2('0x20b2')](),_0x351f4e[_0x5133a2('0xace')]=_0x28335b,_0x351f4e[_0x5133a2('0x260a')]=_0x5978ad,_0x351f4e[_0x5133a2('0x19b2')]=_0x351f4e['setting'][_0x5133a2('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x351f4e[_0x5133a2('0x1224')]=_0x553c01[_0x5133a2('0x173e')]()+_0x5133a2('0x20de')+_0x553c01[_0x5133a2('0x19ac')](),_0x351f4e[_0x5133a2('0x1f2d')]=_0x2eb0e4||_0x32189c[_0x5133a2('0x7f2')][_0x5133a2('0x1f2d')]||{},_0x351f4e[_0x5133a2('0x22df')]=_0x57694b&&_0x57694b[_0x5133a2('0x50d')]==0x1?_0x57694b[_0x5133a2('0xf5d')][0x0]:null,_0x351f4e[_0x5133a2('0x1134')]=_0x1601de[_0x5133a2('0x142a')](_0x351f4e[_0x5133a2('0x22df')]?_0x351f4e[_0x5133a2('0x22df')][_0x5133a2('0x1134')]:null),_0x351f4e[_0x5133a2('0x258d')]={},_0x351f4e[_0x5133a2('0x517')]=_0x32189c[_0x5133a2('0x7f2')]['tab']||0x0,_0x351f4e[_0x5133a2('0x2430')]=_0xd63e2f[_0x5133a2('0x2289')],_0x351f4e[_0x5133a2('0x200')]=_0x163c23,_0x351f4e['saveOutboundRoute']=_0x13713f,_0x1601de[_0x5133a2('0xca1')](_0x5133a2('0x20c2'))?_0x544439[_0x5133a2('0x1e4d')]['get']({'fields':_0x5133a2('0xa10'),'sort':'name','nolimit':_0x5133a2('0x26ac')})[_0x5133a2('0xe53')][_0x5133a2('0x683')](function(_0x2cd7ae){const _0x222dc0=_0x5133a2;_0x351f4e['contexts']=_0x2cd7ae[_0x222dc0('0xf5d')]||[];})['catch'](function(_0x5a8d18){const _0x735d25=_0x5133a2;_0xd63e2f[_0x735d25('0x52a')]({'title':_0x5a8d18[_0x735d25('0x13ee')]?_0x735d25('0x2168')+_0x5a8d18[_0x735d25('0x13ee')]+_0x735d25('0xbf6')+_0x5a8d18['statusText']:_0x735d25('0x1379'),'msg':_0x5a8d18[_0x735d25('0x5a5')]?JSON[_0x735d25('0x258a')](_0x5a8d18[_0x735d25('0x5a5')]):_0x5a8d18['toString']()});}):_0x544439[_0x5133a2('0x1e4d')][_0x5133a2('0x1e6e')]({'fields':_0x5133a2('0xa10'),'sort':_0x5133a2('0x60a'),'nolimit':_0x5133a2('0x26ac')})['$promise']['then'](function(_0x44ebe7){const _0x591ca1=_0x5133a2;_0x351f4e[_0x591ca1('0x1693')]=_0x44ebe7[_0x591ca1('0xf5d')]||[];})['then'](function(){const _0x4dcb63=_0x5133a2;return _0x544439[_0x4dcb63('0x22df')][_0x4dcb63('0x1e6e')]({'userProfileId':_0x351f4e[_0x4dcb63('0x11ed')][_0x4dcb63('0x2f')],'sectionId':0x195})['$promise'];})[_0x5133a2('0x683')](function(_0xc2ce66){const _0x39820f=_0x5133a2,_0x146dd0=_0xc2ce66&&_0xc2ce66[_0x39820f('0xf5d')]?_0xc2ce66[_0x39820f('0xf5d')][0x0]:null;if(!_0x146dd0)return _0x544439[_0x39820f('0x1e4d')][_0x39820f('0x1e6e')]({'fields':_0x39820f('0xa10'),'sort':'name','nolimit':'true','defaultEntry':0x1})['$promise'][_0x39820f('0x683')](function(_0x276c14){const _0x172ca6=_0x39820f;_0x351f4e['contexts']=_0x276c14[_0x172ca6('0xf5d')]||[];});else{if(!_0x146dd0[_0x39820f('0x170')])return _0x544439[_0x39820f('0xcf7')][_0x39820f('0x1e6e')]({'sectionId':_0x146dd0['id']})[_0x39820f('0xe53')][_0x39820f('0x683')](function(_0x23b5f3){const _0x2113fe=_0x39820f,_0x589329=_0x2e3ca0()[_0x2113fe('0x386')](_0x23b5f3[_0x2113fe('0xf5d')],function(_0x2af3ae){const _0x3b7ef5=_0x2113fe;return _0x2e3ca0()[_0x3b7ef5('0x1c07')](_0x351f4e[_0x3b7ef5('0x1693')],{'id':_0x2af3ae[_0x3b7ef5('0x832')]});});let _0x29283b=null;_0x351f4e[_0x2113fe('0x1f2d')]&&(_0x29283b=_0x2e3ca0()[_0x2113fe('0x1c07')](_0x351f4e[_0x2113fe('0x1693')],{'name':_0x351f4e[_0x2113fe('0x1f2d')][_0x2113fe('0x22d3')]}));if(_0x29283b&&!_0x2e3ca0()[_0x2113fe('0x7a2')](_0x589329,['id',_0x29283b['id']])){const _0x570039=_0x2e3ca0()['find'](_0x351f4e[_0x2113fe('0x1693')],{'id':_0x29283b['id']});_0x570039[_0x2113fe('0x319')]=![],_0x589329[_0x2113fe('0x1fd0')](_0x570039);}_0x351f4e['contexts']=_0x589329;});}})[_0x5133a2('0x130a')](function(_0x4d8ba8){const _0x3b73b8=_0x5133a2;_0xd63e2f[_0x3b73b8('0x52a')]({'title':_0x4d8ba8[_0x3b73b8('0x13ee')]?_0x3b73b8('0x2168')+_0x4d8ba8['status']+'\x20-\x20'+_0x4d8ba8[_0x3b73b8('0x24a9')]:'SYSTEM:GETcontexts','msg':_0x4d8ba8[_0x3b73b8('0x5a5')]?JSON[_0x3b73b8('0x258a')](_0x4d8ba8[_0x3b73b8('0x5a5')]):_0x4d8ba8[_0x3b73b8('0x1ff0')]()});});function _0x163c23(){_0x32189c['go']('app.voice.outboundroutes',{},{'reload':'app.voice.outboundroutes'});}function _0x13713f(){const _0x38d8ea=_0x5133a2;_0x544439[_0x38d8ea('0x14cb')][_0x38d8ea('0x2480')]({'id':_0x351f4e[_0x38d8ea('0x1f2d')]['id']},_0x351f4e['outboundroute'])[_0x38d8ea('0xe53')]['then'](function(){const _0x54b324=_0x38d8ea;_0xd63e2f[_0x54b324('0x53')]({'title':_0x54b324('0x2626'),'msg':_0x351f4e[_0x54b324('0x1f2d')][_0x54b324('0x60a')]?_0x351f4e[_0x54b324('0x1f2d')][_0x54b324('0x60a')]+_0x54b324('0x96c'):''});})['catch'](function(_0x2dac2a){const _0x36f79e=_0x38d8ea;_0xd63e2f[_0x36f79e('0x52a')]({'title':_0x2dac2a[_0x36f79e('0x13ee')]?_0x36f79e('0x2168')+_0x2dac2a['status']+_0x36f79e('0xbf6')+_0x2dac2a['statusText']:_0x36f79e('0xb10'),'msg':_0x2dac2a['data']?JSON['stringify'](_0x2dac2a[_0x36f79e('0x5a5')]):_0x2dac2a[_0x36f79e('0x1ff0')]()});});}}const _0x397329=_0x36fbd5,_0x5ca943=_0x180212['p']+_0x189033('0x1127');_0xd3eecd[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x1b40'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),'msUtils',_0x189033('0x1d70'),'Auth','license',_0x189033('0x260a')];function _0xd3eecd(_0x26f4e6,_0x170bf8,_0x5f554e,_0x6f54a8,_0x413eb0,_0x35d314,_0x3b0f3e,_0x240afb,_0x1d9f0e,_0x5f5e8a,_0x3dac4e,_0x9f20a0,_0x47a0e2,_0x930b0f,_0x37e5c4,_0x2f8423,_0x17f666){const _0x268b90=_0x189033,_0x328294=this;_0x328294['license']=_0x2f8423,_0x328294[_0x268b90('0x260a')]=_0x17f666,_0x328294[_0x268b90('0x11ed')]=_0x37e5c4['getCurrentUser'](),_0x328294[_0x268b90('0x1b40')]=_0x1d9f0e||{'count':0x0,'rows':[]},_0x328294[_0x268b90('0x2a')]=_0x5f5e8a,_0x328294[_0x268b90('0x22df')]=_0x3dac4e&&_0x3dac4e['count']==0x1?_0x3dac4e['rows'][0x0]:null,_0x328294[_0x268b90('0x1134')]=_0x37e5c4[_0x268b90('0x142a')](_0x328294[_0x268b90('0x22df')]?_0x328294[_0x268b90('0x22df')]['crudPermissions']:null),_0x328294[_0x268b90('0x5c4')]='outboundroutes',_0x328294[_0x268b90('0x247')]='',_0x328294['listOrderAsc']=null,_0x328294['selectedOutboundRoutes']=[],_0x328294[_0x268b90('0x23a2')]={'fields':'createdAt,updatedAt,id,appdata,type,exten,context,recordingFormat,cutdigits,description','type':'outbound','sort':_0x268b90('0xc36'),'VoiceExtensionId':'null','limit':0xa,'page':0x1},_0x328294[_0x268b90('0x18e0')]=_0x2e3ca0()['keyBy']([{'option':_0x268b90('0x925'),'value':'\x27none\x27'},{'option':_0x268b90('0x1d2a'),'value':_0x268b90('0xfb2')},{'option':_0x268b90('0x178'),'value':'\x27WAV\x27'},{'option':'gsm','value':_0x268b90('0x1755')}],function(_0x26d8bb){const _0x313bfe=_0x268b90;return _0x2e3ca0()['replace'](_0x26d8bb[_0x313bfe('0x1c6b')],new RegExp('\x27','g'),'');}),_0x328294[_0x268b90('0xc63')]=_0x57a3a0,_0x328294[_0x268b90('0x194f')]=_0x823aa8,_0x328294[_0x268b90('0x53')]=_0x19bc07,_0x328294[_0x268b90('0x21ff')]=_0x1811b2,_0x328294[_0x268b90('0xe77')]=_0x3b4af4,_0x328294[_0x268b90('0x1db4')]=_0x4e7407,_0x328294['exportSelectedOutboundRoutes']=_0x25270d,_0x328294['deleteSelectedOutboundRoutes']=_0x2b6953,_0x328294['deselectOutboundRoutes']=_0x1740ee,_0x328294[_0x268b90('0x1f11')]=_0x26bc7c,_0x37e5c4['hasRole'](_0x268b90('0x20c2'))?_0x9f20a0[_0x268b90('0x1e4d')][_0x268b90('0x1e6e')]({'fields':'id,name','sort':_0x268b90('0x60a'),'nolimit':_0x268b90('0x26ac')})[_0x268b90('0xe53')]['then'](function(_0x5d172f){const _0x205f15=_0x268b90;_0x328294[_0x205f15('0x1693')]=_0x5d172f[_0x205f15('0xf5d')]||[];})['catch'](function(_0x45865f){const _0x46c1c9=_0x268b90;_0x930b0f[_0x46c1c9('0x52a')]({'title':_0x45865f[_0x46c1c9('0x13ee')]?'API:'+_0x45865f[_0x46c1c9('0x13ee')]+_0x46c1c9('0xbf6')+_0x45865f['statusText']:_0x46c1c9('0x1379'),'msg':_0x45865f[_0x46c1c9('0x5a5')]?JSON['stringify'](_0x45865f[_0x46c1c9('0x5a5')]):_0x45865f['toString']()});}):_0x9f20a0[_0x268b90('0x1e4d')][_0x268b90('0x1e6e')]({'fields':_0x268b90('0xa10'),'sort':_0x268b90('0x60a'),'nolimit':_0x268b90('0x26ac')})['$promise'][_0x268b90('0x683')](function(_0x538fc5){const _0x4b9cfb=_0x268b90;_0x328294[_0x4b9cfb('0x1693')]=_0x538fc5['rows']||[];})[_0x268b90('0x683')](function(){const _0x18e3be=_0x268b90;return _0x9f20a0[_0x18e3be('0x22df')][_0x18e3be('0x1e6e')]({'userProfileId':_0x328294[_0x18e3be('0x11ed')]['userProfileId'],'sectionId':0x195})[_0x18e3be('0xe53')];})[_0x268b90('0x683')](function(_0x28fafb){const _0x1ea054=_0x268b90,_0x1f271c=_0x28fafb&&_0x28fafb[_0x1ea054('0xf5d')]?_0x28fafb['rows'][0x0]:null;if(!_0x1f271c)return _0x9f20a0[_0x1ea054('0x1e4d')][_0x1ea054('0x1e6e')]({'fields':_0x1ea054('0xa10'),'sort':_0x1ea054('0x60a'),'nolimit':_0x1ea054('0x26ac'),'defaultEntry':0x1})['$promise'][_0x1ea054('0x683')](function(_0x14da52){const _0x1e3df9=_0x1ea054;_0x328294[_0x1e3df9('0x1693')]=_0x14da52[_0x1e3df9('0xf5d')]||[];});else{if(!_0x1f271c[_0x1ea054('0x170')])return _0x9f20a0['userProfileResource'][_0x1ea054('0x1e6e')]({'sectionId':_0x1f271c['id']})[_0x1ea054('0xe53')][_0x1ea054('0x683')](function(_0x579adc){const _0x9cf105=_0x1ea054,_0x50197a=_0x2e3ca0()['map'](_0x579adc['rows'],function(_0x49ea8b){const _0x1b10a6=a0_0x4e0a;return _0x2e3ca0()[_0x1b10a6('0x1c07')](_0x328294[_0x1b10a6('0x1693')],{'id':_0x49ea8b[_0x1b10a6('0x832')]});});let _0x103986=null;_0x328294[_0x9cf105('0x1f2d')]&&(_0x103986=_0x2e3ca0()[_0x9cf105('0x1c07')](_0x328294['contexts'],{'name':_0x328294[_0x9cf105('0x1f2d')][_0x9cf105('0x22d3')]}));if(_0x103986&&!_0x2e3ca0()[_0x9cf105('0x7a2')](_0x50197a,['id',_0x103986['id']])){const _0x46f216=_0x2e3ca0()[_0x9cf105('0x1c07')](_0x328294[_0x9cf105('0x1693')],{'id':_0x103986['id']});_0x46f216[_0x9cf105('0x319')]=![],_0x50197a[_0x9cf105('0x1fd0')](_0x46f216);}_0x328294[_0x9cf105('0x1693')]=_0x50197a;});}})[_0x268b90('0x130a')](function(_0x4c538b){const _0x5107b5=_0x268b90;_0x930b0f[_0x5107b5('0x52a')]({'title':_0x4c538b[_0x5107b5('0x13ee')]?_0x5107b5('0x2168')+_0x4c538b[_0x5107b5('0x13ee')]+_0x5107b5('0xbf6')+_0x4c538b['statusText']:_0x5107b5('0x1a60'),'msg':_0x4c538b[_0x5107b5('0x5a5')]?JSON[_0x5107b5('0x258a')](_0x4c538b[_0x5107b5('0x5a5')]):_0x4c538b[_0x5107b5('0x1ff0')]()});});function _0x57a3a0(_0x32aa2e){const _0x2ccb08=_0x268b90;_0x5f554e['go'](_0x2ccb08('0x1c94'),{'id':_0x32aa2e['id'],'outboundroute':_0x32aa2e,'crudPermissions':_0x328294[_0x2ccb08('0x1134')]});}function _0x823aa8(_0x5885b5,_0x22d957){const _0x19c719=_0x268b90,_0x120cde=_0x413eb0[_0x19c719('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x19c719('0x1e03')](_0x19c719('0x1f2d'))+'?')[_0x19c719('0x26e3')](_0x19c719('0xed5')+(_0x5885b5[_0x19c719('0x60a')]||_0x19c719('0x1f2d'))+''+_0x19c719('0x1ee7'))['ariaLabel'](_0x19c719('0xde5'))[_0x19c719('0xe42')](_0x22d957)['ok']('OK')['cancel'](_0x19c719('0x16b8'));_0x413eb0[_0x19c719('0x1d4')](_0x120cde)[_0x19c719('0x683')](function(){_0x4e7407(_0x5885b5);},function(){console['log']('CANCEL');});}let _0x447ae6=!![],_0x9c7708=0x1;_0x26f4e6[_0x268b90('0x186d')](_0x268b90('0x1e1d'),function(_0x3a24dd,_0x29e31e){const _0x5873ca=_0x268b90;_0x447ae6?_0x3b0f3e(function(){_0x447ae6=![];}):(!_0x29e31e&&(_0x9c7708=_0x328294[_0x5873ca('0x23a2')]['page']),_0x3a24dd!==_0x29e31e&&(_0x328294[_0x5873ca('0x23a2')]['page']=0x1),!_0x3a24dd&&(_0x328294[_0x5873ca('0x23a2')][_0x5873ca('0xdf8')]=_0x9c7708),_0x328294[_0x5873ca('0x21ff')]());});function _0x19bc07(_0x21bbf5){const _0x431c96=_0x268b90;_0x328294[_0x431c96('0x1b40')]=_0x21bbf5||{'count':0x0,'rows':[]};}function _0x1811b2(){const _0x418a0e=_0x268b90;_0x328294[_0x418a0e('0x23a2')]['offset']=(_0x328294[_0x418a0e('0x23a2')][_0x418a0e('0xdf8')]-0x1)*_0x328294['query']['limit'],_0x37e5c4['hasRole'](_0x418a0e('0x20c2'))?_0x328294[_0x418a0e('0x1883')]=_0x9f20a0[_0x418a0e('0x14cb')]['get'](_0x328294['query'],_0x19bc07)[_0x418a0e('0xe53')]:(_0x328294[_0x418a0e('0x23a2')]['id']=_0x328294['userProfile']['id'],_0x328294[_0x418a0e('0x23a2')][_0x418a0e('0x1aa')]=_0x418a0e('0x2e3'),_0x328294[_0x418a0e('0x1883')]=_0x9f20a0[_0x418a0e('0x2a')][_0x418a0e('0x241d')](_0x328294[_0x418a0e('0x23a2')],_0x19bc07)[_0x418a0e('0xe53')]);}function _0x3b4af4(_0x2dabb8,_0x316231){const _0x52acc1=_0x268b90;_0x413eb0['show']({'controller':_0x52acc1('0xda0'),'controllerAs':'vm','templateUrl':_0x5ca943,'parent':angular['element'](_0x35d314[_0x52acc1('0x18e5')]),'targetEvent':_0x2dabb8,'clickOutsideToClose':!![],'locals':{'outboundroute':_0x316231,'outboundroutes':_0x328294[_0x52acc1('0x1b40')][_0x52acc1('0xf5d')],'license':_0x328294[_0x52acc1('0xace')],'setting':_0x328294['setting'],'crudPermissions':_0x328294['crudPermissions']}});}function _0x4e7407(_0x3c6aff){const _0x5ad7d6=_0x268b90;_0x9f20a0['voicePrefix'][_0x5ad7d6('0x1e6e')]({'VoiceExtensionId':_0x3c6aff['id']})['$promise'][_0x5ad7d6('0x683')](function(_0x596da6){const _0x13f934=_0x5ad7d6;if(_0x596da6&&_0x596da6[_0x13f934('0xf5d')]&&_0x596da6['rows'][_0x13f934('0x1564')]>0x0)return _0x930b0f['error']({'title':_0x13f934('0xcc7'),'msg':'You\x20can\x27t\x20remove\x20an\x20outbound\x20route\x20associated\x20to\x20an\x20out\x20prefix'});else _0x9f20a0['voiceExtension']['delete']({'id':_0x3c6aff['id']})[_0x13f934('0xe53')][_0x13f934('0x683')](function(){const _0x5b60d3=_0x13f934;_0x2e3ca0()[_0x5b60d3('0x3ec')](_0x328294[_0x5b60d3('0x1b40')]['rows'],{'id':_0x3c6aff['id']}),_0x328294[_0x5b60d3('0x1b40')]['count']-=0x1,!_0x328294[_0x5b60d3('0x1b40')][_0x5b60d3('0xf5d')][_0x5b60d3('0x1564')]&&_0x328294[_0x5b60d3('0x21ff')](),_0x930b0f[_0x5b60d3('0x53')]({'title':_0x2e3ca0()[_0x5b60d3('0x1e03')](_0x5b60d3('0x19c3'))+_0x5b60d3('0xbfc'),'msg':_0x3c6aff[_0x5b60d3('0x60a')]?_0x3c6aff['name']+'\x20has\x20been\x20deleted!':''});})[_0x13f934('0x130a')](function(_0xd9f4b){const _0xd99933=_0x13f934;if(_0xd9f4b[_0xd99933('0x5a5')]&&_0xd9f4b[_0xd99933('0x5a5')][_0xd99933('0x17f')]&&_0xd9f4b[_0xd99933('0x5a5')]['errors']['length']){_0x328294[_0xd99933('0x17f')]=_0xd9f4b[_0xd99933('0x5a5')]['errors']||[{'message':_0xd9f4b['toString'](),'type':_0xd99933('0x2602')}];for(let _0x462a11=0x0;_0x462a11<_0xd9f4b[_0xd99933('0x5a5')][_0xd99933('0x17f')]['length'];_0x462a11++){_0x930b0f[_0xd99933('0x52a')]({'title':_0xd9f4b[_0xd99933('0x5a5')][_0xd99933('0x17f')][_0x462a11][_0xd99933('0xcf0')],'msg':_0xd9f4b['data'][_0xd99933('0x17f')][_0x462a11]['message']});}}else _0x930b0f['error']({'title':_0xd9f4b[_0xd99933('0x13ee')]?'API:'+_0xd9f4b['status']+_0xd99933('0xbf6')+_0xd9f4b['statusText']:_0xd99933('0x2602'),'msg':_0xd9f4b[_0xd99933('0x5a5')]?JSON[_0xd99933('0x258a')](_0xd9f4b[_0xd99933('0x5a5')][_0xd99933('0x8c2')]):_0xd9f4b[_0xd99933('0x8c2')]||_0xd9f4b[_0xd99933('0x1ff0')]()});});});}function _0x25270d(){const _0x2f8a9b=_0x268b90,_0x5f2470=angular['copy'](_0x328294[_0x2f8a9b('0x1af4')]);return _0x328294[_0x2f8a9b('0x1af4')]=[],_0x5f2470;}function _0x2b6953(_0x3f48b7){const _0x56071d=_0x268b90,_0x3c667d=_0x413eb0['confirm']()['title'](_0x56071d('0x3ab'))['htmlContent'](_0x56071d('0xed5')+_0x328294[_0x56071d('0x1af4')]['length']+'\x20selected'+_0x56071d('0x1ee7'))[_0x56071d('0x1040')](_0x56071d('0x13b7'))[_0x56071d('0xe42')](_0x3f48b7)['ok']('OK')[_0x56071d('0x19fb')](_0x56071d('0x16b8'));_0x413eb0[_0x56071d('0x1d4')](_0x3c667d)[_0x56071d('0x683')](function(){const _0x37ae95=_0x56071d;_0x328294[_0x37ae95('0x1af4')][_0x37ae95('0x1299')](function(_0x811a23){_0x4e7407(_0x811a23);}),_0x328294[_0x37ae95('0x1af4')]=[];});}function _0x1740ee(){const _0x5c41b2=_0x268b90;_0x328294[_0x5c41b2('0x1af4')]=[];}function _0x26bc7c(){const _0x23a4d2=_0x268b90;_0x328294[_0x23a4d2('0x1af4')]=_0x328294[_0x23a4d2('0x1b40')][_0x23a4d2('0xf5d')];}}const _0x4375f0=_0xd3eecd;_0x1e3d75[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$q',_0x189033('0x1d08'),'toasty',_0x189033('0xb6f'),_0x189033('0x8ac'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x1e3d75(_0x1fcc5d,_0x13e149,_0x436e32,_0x40a192,_0xcc00ae,_0x2ee616,_0x39ec6b,_0x3906c1,_0x30724a,_0x238f3e,_0x28e42c,_0x1b4432,_0x27c0dc,_0x45e0c8){const _0x338af7=_0x189033,_0x452072=this;_0x452072[_0x338af7('0x11ed')]=_0x28e42c[_0x338af7('0x20b2')](),_0x452072[_0x338af7('0x17f')]=[],_0x452072['setting']=_0x27c0dc,_0x452072[_0x338af7('0xace')]=_0x1b4432,_0x452072[_0x338af7('0x1134')]=_0x45e0c8,_0x452072[_0x338af7('0x258d')]={},_0x452072['passwordPattern']=_0x452072[_0x338af7('0x260a')]&&_0x452072[_0x338af7('0x260a')][_0x338af7('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x452072[_0x338af7('0xf28')]=_0x338af7('0x260'),_0x452072['voicemail']=angular[_0x338af7('0x1a86')](_0x30724a),_0x452072[_0x338af7('0xb6f')]=_0x3906c1,_0x452072[_0x338af7('0x1b6b')]=![];!_0x452072[_0x338af7('0x8ac')]&&(_0x452072[_0x338af7('0x8ac')]={'attach':'no'},_0x452072[_0x338af7('0xf28')]=_0x338af7('0x26c1'),_0x452072[_0x338af7('0x1b6b')]=!![]);_0x452072['addNewVoicemail']=_0x4aa35d,_0x452072[_0x338af7('0x282f')]=_0x14a541,_0x452072[_0x338af7('0x281b')]=_0x46fe63,_0x452072[_0x338af7('0x16b3')]=_0x58e39d,_0x452072[_0x338af7('0xf82')]=_0x21e0ce;function _0x4aa35d(){const _0x332c56=_0x338af7;_0x452072[_0x332c56('0x17f')]=[],_0x238f3e[_0x332c56('0x1a6b')]['save'](_0x452072['voicemail'])[_0x332c56('0xe53')][_0x332c56('0x683')](function(_0x3bdba7){const _0x511552=_0x332c56;_0x452072[_0x511552('0xb6f')][_0x511552('0x1167')](_0x3bdba7[_0x511552('0x24e1')]()),_0x39ec6b['success']({'title':_0x511552('0x59d'),'msg':_0x452072[_0x511552('0x8ac')][_0x511552('0x60a')]?_0x452072['voicemail'][_0x511552('0x60a')]+_0x511552('0x14b5'):''}),_0x21e0ce(_0x3bdba7);})['catch'](function(_0x44791e){const _0x3d02f6=_0x332c56;if(_0x44791e[_0x3d02f6('0x5a5')]&&_0x44791e[_0x3d02f6('0x5a5')]['errors']&&_0x44791e[_0x3d02f6('0x5a5')][_0x3d02f6('0x17f')][_0x3d02f6('0x1564')]){_0x452072[_0x3d02f6('0x17f')]=_0x44791e[_0x3d02f6('0x5a5')][_0x3d02f6('0x17f')]||[{'message':_0x44791e[_0x3d02f6('0x1ff0')](),'type':_0x3d02f6('0x56a')}];for(let _0xf1de8e=0x0;_0xf1de8e<_0x44791e[_0x3d02f6('0x5a5')][_0x3d02f6('0x17f')][_0x3d02f6('0x1564')];_0xf1de8e+=0x1){_0x39ec6b[_0x3d02f6('0x52a')]({'title':_0x44791e['data']['errors'][_0xf1de8e][_0x3d02f6('0xcf0')],'msg':_0x44791e[_0x3d02f6('0x5a5')][_0x3d02f6('0x17f')][_0xf1de8e][_0x3d02f6('0x8c2')]});}}else _0x39ec6b[_0x3d02f6('0x52a')]({'title':_0x44791e['status']?'API:'+_0x44791e[_0x3d02f6('0x13ee')]+'\x20-\x20'+_0x44791e[_0x3d02f6('0x24a9')]:'api.voiceMail.save','msg':_0x44791e[_0x3d02f6('0x5a5')]?JSON[_0x3d02f6('0x258a')](_0x44791e[_0x3d02f6('0x5a5')]['message']):_0x44791e[_0x3d02f6('0x1ff0')]()});});}function _0x14a541(){const _0x23527b=_0x338af7;_0x452072[_0x23527b('0x17f')]=[],_0x238f3e['voiceMail'][_0x23527b('0x2480')]({'id':_0x452072[_0x23527b('0x8ac')]['id']},_0x452072[_0x23527b('0x8ac')])[_0x23527b('0xe53')][_0x23527b('0x683')](function(_0x2e095f){const _0x2be46d=_0x23527b,_0xa5fc7f=_0x2e3ca0()[_0x2be46d('0x1c07')](_0x452072['voicemails'],{'id':_0x2e095f['id']});_0xa5fc7f&&_0x2e3ca0()[_0x2be46d('0xf22')](_0xa5fc7f,_0x2e3ca0()[_0x2be46d('0x24d0')](_0x2e095f[_0x2be46d('0x24e1')](),_0x2e3ca0()[_0x2be46d('0x55e')](_0xa5fc7f))),_0x39ec6b['success']({'title':'Voicemail\x20properly\x20saved!','msg':_0x452072[_0x2be46d('0x8ac')][_0x2be46d('0x60a')]?_0x452072['voicemail'][_0x2be46d('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x21e0ce(_0x2e095f);})[_0x23527b('0x130a')](function(_0x128562){const _0x32c9c4=_0x23527b;if(_0x128562[_0x32c9c4('0x5a5')]&&_0x128562[_0x32c9c4('0x5a5')][_0x32c9c4('0x17f')]&&_0x128562[_0x32c9c4('0x5a5')]['errors'][_0x32c9c4('0x1564')]){_0x452072[_0x32c9c4('0x17f')]=_0x128562['data'][_0x32c9c4('0x17f')]||[{'message':_0x128562[_0x32c9c4('0x1ff0')](),'type':_0x32c9c4('0xd3a')}];for(let _0x24abd4=0x0;_0x24abd4<_0x128562[_0x32c9c4('0x5a5')][_0x32c9c4('0x17f')]['length'];_0x24abd4++){_0x39ec6b['error']({'title':_0x128562[_0x32c9c4('0x5a5')][_0x32c9c4('0x17f')][_0x24abd4][_0x32c9c4('0xcf0')],'msg':_0x128562[_0x32c9c4('0x5a5')][_0x32c9c4('0x17f')][_0x24abd4][_0x32c9c4('0x8c2')]});}}else _0x39ec6b[_0x32c9c4('0x52a')]({'title':_0x128562[_0x32c9c4('0x13ee')]?_0x32c9c4('0x2168')+_0x128562['status']+_0x32c9c4('0xbf6')+_0x128562['statusText']:_0x32c9c4('0xd3a'),'msg':_0x128562[_0x32c9c4('0x5a5')]?JSON[_0x32c9c4('0x258a')](_0x128562[_0x32c9c4('0x5a5')][_0x32c9c4('0x8c2')]):_0x128562['toString']()});});}function _0x46fe63(_0x5eac77){const _0x2a0e42=_0x338af7;_0x452072[_0x2a0e42('0x17f')]=[];const _0x3f7b02=_0x40a192[_0x2a0e42('0x1c6f')]()[_0x2a0e42('0xf28')]('Are\x20you\x20sure?')[_0x2a0e42('0xa6a')](_0x2a0e42('0x21d'))[_0x2a0e42('0x1040')](_0x2a0e42('0x2006'))['ok'](_0x2a0e42('0x2307'))[_0x2a0e42('0x19fb')]('Cancel')['targetEvent'](_0x5eac77);_0x40a192['show'](_0x3f7b02)['then'](function(){const _0x1f69fb=_0x2a0e42;_0x238f3e[_0x1f69fb('0x1a6b')]['delete']({'id':_0x452072[_0x1f69fb('0x8ac')]['id']})[_0x1f69fb('0xe53')][_0x1f69fb('0x683')](function(){const _0x143a18=_0x1f69fb;_0x2e3ca0()[_0x143a18('0x3ec')](_0x452072[_0x143a18('0xb6f')],{'id':_0x452072[_0x143a18('0x8ac')]['id']}),_0x39ec6b[_0x143a18('0x53')]({'title':'Voicemail\x20properly\x20deleted!','msg':(_0x452072[_0x143a18('0x8ac')][_0x143a18('0x60a')]||_0x143a18('0x8ac'))+'\x20has\x20been\x20deleted!'}),_0x21e0ce(_0x452072[_0x143a18('0x8ac')]);})[_0x1f69fb('0x130a')](function(_0xd9d73){const _0x16edfa=_0x1f69fb;if(_0xd9d73[_0x16edfa('0x5a5')]&&_0xd9d73[_0x16edfa('0x5a5')][_0x16edfa('0x17f')]&&_0xd9d73[_0x16edfa('0x5a5')][_0x16edfa('0x17f')][_0x16edfa('0x1564')]){_0x452072[_0x16edfa('0x17f')]=_0xd9d73[_0x16edfa('0x5a5')]['errors']||[{'message':_0xd9d73['toString'](),'type':'api.voiceMail.delete'}];for(let _0x31bf99=0x0;_0x31bf99<_0xd9d73['data'][_0x16edfa('0x17f')][_0x16edfa('0x1564')];_0x31bf99++){_0x39ec6b[_0x16edfa('0x52a')]({'title':_0xd9d73[_0x16edfa('0x5a5')]['errors'][_0x31bf99]['type'],'msg':_0xd9d73['data'][_0x16edfa('0x17f')][_0x31bf99]['message']});}}else _0x39ec6b['error']({'title':_0xd9d73[_0x16edfa('0x13ee')]?_0x16edfa('0x2168')+_0xd9d73[_0x16edfa('0x13ee')]+_0x16edfa('0xbf6')+_0xd9d73['statusText']:_0x16edfa('0x1888'),'msg':_0xd9d73['data']?JSON[_0x16edfa('0x258a')](_0xd9d73[_0x16edfa('0x5a5')]['message']):_0xd9d73[_0x16edfa('0x8c2')]||_0xd9d73[_0x16edfa('0x1ff0')]()});});},function(){});}function _0x58e39d(_0x37b77e){return _0x37b77e===null?undefined:new Date(_0x37b77e);}function _0x21e0ce(_0x1c43d3){const _0x217792=_0x338af7;_0x40a192[_0x217792('0x1715')](_0x1c43d3);}}const _0x84fe0=_0x1e3d75;_0x2de9d8[_0x189033('0x14be')]=[_0x189033('0x17e4'),'$scope','$state','$q','$translate',_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x2de9d8(_0x4c1523,_0x3e83a9,_0x3d2272,_0x188192,_0x3a07ad,_0x418bc0,_0x1482f7,_0x1d5859,_0x460c69,_0x4b9d5e,_0x2cb988){const _0x1e630f=_0x189033,_0x46de77=this;_0x46de77[_0x1e630f('0x11ed')]=_0x2cb988[_0x1e630f('0x20b2')](),_0x46de77['voicemail']={},_0x46de77[_0x1e630f('0x212')]={'count':0x0,'rows':[]},_0x46de77['selectedVoicemailMessages']=[],_0x46de77['crudPermissions'],_0x46de77[_0x1e630f('0x23a2')]={'fields':_0x1e630f('0x187d'),'sort':_0x1e630f('0x1ced'),'limit':0xa,'page':0x1},_0x46de77[_0x1e630f('0x12f3')]=_0x301e8e,_0x46de77[_0x1e630f('0x26eb')]=_0x24f004,_0x46de77['voiceMailMessageDownload']=_0x1323a0,_0x46de77[_0x1e630f('0x53')]=_0x13c787,_0x46de77[_0x1e630f('0x2736')]=_0x47623a,_0x46de77[_0x1e630f('0x1bbc')]=_0x28b617,_0x46de77['deleteVoicemailMessage']=_0x19bad3,_0x46de77['deleteSelectedVoicemailMessages']=_0x292b56;function _0x301e8e(_0x436ea5,_0x3c575d){const _0x302e1b=_0x1e630f;_0x46de77[_0x302e1b('0x8ac')]=_0x436ea5,_0x46de77[_0x302e1b('0x1134')]=typeof _0x3c575d!==_0x302e1b('0x1867')?_0x3c575d:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x46de77[_0x302e1b('0x23a2')]['id']=_0x46de77['voicemail']['id'],_0x47623a();}function _0x1323a0(_0x369c1f,_0x578cee,_0x189774){const _0x6eaf64=_0x1e630f;return _0x4b9d5e['voiceMailMessage'][_0x6eaf64('0x18e8')]({'id':_0x369c1f['id'],'exists':!![],'attachments':_0x189774})[_0x6eaf64('0xe53')][_0x6eaf64('0x683')](function(_0x2f0dca){const _0x3f2495=_0x6eaf64,_0x5432d7=[_0x2f0dca[_0x3f2495('0x1fb3')]];let _0x224628=_0x3f2495('0x8c2')+_0x369c1f['id'];const _0x493471=new Blob(_0x5432d7,{'type':_0x2f0dca[_0x3f2495('0xcf0')]});_0x224628=_0x369c1f[_0x3f2495('0xcbb')]+_0x3f2495('0x138a');const _0x84d817=window[_0x3f2495('0x12e1')][_0x3f2495('0x1ffa')]('a');_0x84d817[_0x3f2495('0x130f')](_0x3f2495('0x2767'),URL[_0x3f2495('0x2820')](_0x493471)),_0x84d817[_0x3f2495('0x130f')](_0x3f2495('0x18e8'),_0x224628),document[_0x3f2495('0x18e5')][_0x3f2495('0x1e43')](_0x84d817),_0x84d817[_0x3f2495('0x1d42')]();})[_0x6eaf64('0x130a')](function(_0x436cef){const _0x3d7fd0=_0x6eaf64;if(_0x436cef[_0x3d7fd0('0x5a5')]&&_0x436cef['data'][_0x3d7fd0('0x17f')]&&_0x436cef[_0x3d7fd0('0x5a5')][_0x3d7fd0('0x17f')][_0x3d7fd0('0x1564')])for(let _0x4d0e84=0x0;_0x4d0e84<_0x436cef[_0x3d7fd0('0x5a5')][_0x3d7fd0('0x17f')][_0x3d7fd0('0x1564')];_0x4d0e84+=0x1){_0x460c69[_0x3d7fd0('0x52a')]({'title':_0x436cef[_0x3d7fd0('0x5a5')]['errors'][_0x4d0e84][_0x3d7fd0('0xcf0')],'msg':_0x436cef[_0x3d7fd0('0x5a5')][_0x3d7fd0('0x17f')][_0x4d0e84][_0x3d7fd0('0x8c2')]});}else _0x460c69['error']({'title':_0x436cef['status']?_0x3d7fd0('0x2168')+_0x436cef['status']+_0x3d7fd0('0xbf6')+_0x436cef[_0x3d7fd0('0x24a9')]:'api.voiceMail.save','msg':_0x436cef[_0x3d7fd0('0x5a5')]?JSON[_0x3d7fd0('0x258a')](_0x436cef[_0x3d7fd0('0x5a5')][_0x3d7fd0('0x8c2')]):_0x436cef[_0x3d7fd0('0x1ff0')]()});});}function _0x24f004(_0x1ac0fc,_0x2a03ca){const _0x5eee49=_0x1e630f,_0xcaa3e1=_0x1482f7[_0x5eee49('0x1c6f')]()[_0x5eee49('0xf28')](_0x5eee49('0x87c'))[_0x5eee49('0x26e3')](_0x5eee49('0xed5')+(_0x1ac0fc[_0x5eee49('0x60a')]||_0x1ac0fc['id']&&_0x2e3ca0()[_0x5eee49('0x2711')](_0x5eee49('0x236e'))+_0x1ac0fc['id']||'message')+_0x5eee49('0x20f1')+_0x5eee49('0x1ee7'))[_0x5eee49('0x1040')]('delete\x20message')[_0x5eee49('0xe42')](_0x2a03ca)['ok']('OK')['cancel']('CANCEL');_0x1482f7[_0x5eee49('0x1d4')](_0xcaa3e1)['then'](function(){_0x19bad3(_0x1ac0fc);},function(){const _0x283343=_0x5eee49;console[_0x283343('0x1b2b')](_0x283343('0x16b8'));});}function _0x13c787(_0x3433e5){const _0x22ce62=_0x1e630f;_0x46de77[_0x22ce62('0x212')]=_0x3433e5||{'count':0x0,'rows':[]};}function _0x47623a(){const _0x1d6f74=_0x1e630f;_0x46de77[_0x1d6f74('0x23a2')][_0x1d6f74('0x1cc8')]=(_0x46de77[_0x1d6f74('0x23a2')][_0x1d6f74('0xdf8')]-0x1)*_0x46de77[_0x1d6f74('0x23a2')][_0x1d6f74('0x6f0')],_0x46de77[_0x1d6f74('0x1883')]=_0x4b9d5e[_0x1d6f74('0x1a6b')][_0x1d6f74('0x1cdb')](_0x46de77['query'],_0x13c787)['$promise'];}function _0x19bad3(_0xdae152){const _0x22b7f8=_0x1e630f;_0x4b9d5e[_0x22b7f8('0xed8')]['delete']({'id':_0xdae152['id']})[_0x22b7f8('0xe53')]['then'](function(){const _0x59e09a=_0x22b7f8;_0x2e3ca0()[_0x59e09a('0x3ec')](_0x46de77[_0x59e09a('0x212')][_0x59e09a('0xf5d')],{'id':_0xdae152['id']}),_0x46de77[_0x59e09a('0x212')]['count']-=0x1,!_0x46de77['voicemailMessages'][_0x59e09a('0xf5d')][_0x59e09a('0x1564')]&&_0x47623a(),_0x460c69['success']({'title':_0x59e09a('0x178b'),'msg':_0xdae152['name']?_0xdae152[_0x59e09a('0x60a')]+_0x59e09a('0x194d'):''});})['catch'](function(_0x57a8e9){const _0x14a9c5=_0x22b7f8;if(_0x57a8e9[_0x14a9c5('0x5a5')]&&_0x57a8e9[_0x14a9c5('0x5a5')][_0x14a9c5('0x17f')]&&_0x57a8e9['data']['errors'][_0x14a9c5('0x1564')]){_0x46de77[_0x14a9c5('0x17f')]=_0x57a8e9['data'][_0x14a9c5('0x17f')]||[{'message':_0x57a8e9[_0x14a9c5('0x1ff0')](),'type':_0x14a9c5('0x2334')}];for(let _0x10e021=0x0;_0x10e021<_0x57a8e9[_0x14a9c5('0x5a5')][_0x14a9c5('0x17f')][_0x14a9c5('0x1564')];_0x10e021++){_0x460c69['error']({'title':_0x57a8e9[_0x14a9c5('0x5a5')][_0x14a9c5('0x17f')][_0x10e021]['type'],'msg':_0x57a8e9[_0x14a9c5('0x5a5')]['errors'][_0x10e021][_0x14a9c5('0x8c2')]});}}else _0x460c69[_0x14a9c5('0x52a')]({'title':_0x57a8e9[_0x14a9c5('0x13ee')]?_0x14a9c5('0x2168')+_0x57a8e9['status']+_0x14a9c5('0xbf6')+_0x57a8e9[_0x14a9c5('0x24a9')]:'SYSTEM:GETvoiceMail','msg':_0x57a8e9[_0x14a9c5('0x5a5')]?JSON[_0x14a9c5('0x258a')](_0x57a8e9[_0x14a9c5('0x5a5')][_0x14a9c5('0x8c2')]):_0x57a8e9[_0x14a9c5('0x8c2')]||_0x57a8e9[_0x14a9c5('0x1ff0')]()});});}function _0x28b617(){const _0x538b9b=_0x1e630f,_0x2634f6=angular['copy'](_0x46de77[_0x538b9b('0x2381')]);return _0x46de77[_0x538b9b('0x2381')]=[],_0x2634f6;}function _0x292b56(_0x44f4fc){const _0x619ee5=_0x1e630f,_0x402c7a=_0x1482f7['confirm']()['title'](_0x619ee5('0x1e5d'))[_0x619ee5('0x26e3')](_0x619ee5('0xed5')+_0x46de77[_0x619ee5('0x2381')][_0x619ee5('0x1564')]+_0x619ee5('0x93c')+_0x619ee5('0x1ee7'))[_0x619ee5('0x1040')]('delete\x20messages')['targetEvent'](_0x44f4fc)['ok']('OK')[_0x619ee5('0x19fb')]('CANCEL');_0x1482f7[_0x619ee5('0x1d4')](_0x402c7a)[_0x619ee5('0x683')](function(){const _0x47d36c=_0x619ee5;_0x46de77[_0x47d36c('0x2381')][_0x47d36c('0x1299')](function(_0x5409b5){_0x19bad3(_0x5409b5);}),_0x46de77[_0x47d36c('0x2381')]=[];});}let _0x5e4559=!![],_0xa1c78b=0x1;_0x3e83a9[_0x1e630f('0x186d')](_0x1e630f('0x229'),function(_0x6449c6,_0x5f3fb8){const _0x5e7fbb=_0x1e630f;_0x5e4559?_0x418bc0(function(){_0x5e4559=![];}):(!_0x5f3fb8&&(_0xa1c78b=_0x46de77['query'][_0x5e7fbb('0xdf8')]),_0x6449c6!==_0x5f3fb8&&(_0x46de77['query']['page']=0x1),!_0x6449c6&&(_0x46de77[_0x5e7fbb('0x23a2')][_0x5e7fbb('0xdf8')]=_0xa1c78b),_0x47623a());});}const _0x45bc02=_0x2de9d8;_0x5ed65f[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x8ac'),_0x189033('0x22df')];function _0x5ed65f(_0x1cb1a7,_0x114aaa,_0x35ce63,_0x5c417e,_0x21c1a1,_0x1d5ba3,_0x5585df,_0x3121ba,_0x341edd,_0x17dd91,_0x431044,_0x341bb5){const _0x4a6256=_0x189033,_0x1b1964=this;_0x1b1964['currentUser']=_0x17dd91['getCurrentUser'](),_0x1b1964[_0x4a6256('0xace')]=_0x1d5ba3,_0x1b1964[_0x4a6256('0x260a')]=_0x5585df,_0x1b1964[_0x4a6256('0x19b2')]=_0x1b1964['setting'][_0x4a6256('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1b1964[_0x4a6256('0x1224')]=_0x114aaa[_0x4a6256('0x173e')]()+_0x4a6256('0x20de')+_0x114aaa['host'](),_0x1b1964['voicemail']=_0x431044||_0x1cb1a7[_0x4a6256('0x7f2')][_0x4a6256('0x8ac')]||{},_0x1b1964[_0x4a6256('0x22df')]=_0x341bb5&&_0x341bb5[_0x4a6256('0x50d')]==0x1?_0x341bb5[_0x4a6256('0xf5d')][0x0]:null,_0x1b1964[_0x4a6256('0x1134')]=_0x17dd91[_0x4a6256('0x142a')](_0x1b1964[_0x4a6256('0x22df')]?_0x1b1964[_0x4a6256('0x22df')][_0x4a6256('0x1134')]:null),_0x1b1964['hasModulePermissions']={},_0x1b1964[_0x4a6256('0x517')]=_0x1cb1a7['params']['tab']||0x0,_0x1b1964[_0x4a6256('0x2430')]=_0x341edd[_0x4a6256('0x2289')],_0x1b1964[_0x4a6256('0xcd1')]=_0x47c9e3,_0x1b1964['saveVoicemail']=_0x52c69a,_0x17dd91['hasRole']('admin')?_0x3121ba[_0x4a6256('0x1e4d')][_0x4a6256('0x1e6e')]({'fields':'id,name','sort':_0x4a6256('0x60a')})[_0x4a6256('0xe53')]['then'](function(_0x1f3f6e){const _0x44d3ac=_0x4a6256;_0x1b1964[_0x44d3ac('0x1693')]=_0x1f3f6e[_0x44d3ac('0xf5d')]||[];})[_0x4a6256('0x130a')](function(_0x44ed3a){const _0x382cd1=_0x4a6256;_0x341edd[_0x382cd1('0x52a')]({'title':_0x44ed3a[_0x382cd1('0x13ee')]?_0x382cd1('0x2168')+_0x44ed3a[_0x382cd1('0x13ee')]+_0x382cd1('0xbf6')+_0x44ed3a[_0x382cd1('0x24a9')]:'SYSTEM:GET_CONTEXTS','msg':_0x44ed3a[_0x382cd1('0x5a5')]?JSON[_0x382cd1('0x258a')](_0x44ed3a['data']):_0x44ed3a[_0x382cd1('0x1ff0')]()});}):_0x3121ba[_0x4a6256('0x1e4d')][_0x4a6256('0x1e6e')]({'fields':_0x4a6256('0xa10'),'sort':_0x4a6256('0x60a')})[_0x4a6256('0xe53')][_0x4a6256('0x683')](function(_0x1e5707){const _0x7abb94=_0x4a6256;_0x1b1964[_0x7abb94('0x1693')]=_0x1e5707['rows']||[];})['then'](function(){const _0x16d08b=_0x4a6256;return _0x3121ba['userProfileSection'][_0x16d08b('0x1e6e')]({'userProfileId':_0x1b1964['currentUser'][_0x16d08b('0x2f')],'sectionId':0x195})['$promise'];})[_0x4a6256('0x683')](function(_0x14ac40){const _0x2afde4=_0x4a6256,_0x5cbec0=_0x14ac40&&_0x14ac40['rows']?_0x14ac40[_0x2afde4('0xf5d')][0x0]:null;if(!_0x5cbec0)return _0x3121ba[_0x2afde4('0x1e4d')]['get']({'fields':_0x2afde4('0xa10'),'sort':_0x2afde4('0x60a'),'defaultEntry':0x1})[_0x2afde4('0xe53')]['then'](function(_0x1b6c00){const _0x50a42d=_0x2afde4;_0x1b1964[_0x50a42d('0x1693')]=_0x1b6c00[_0x50a42d('0xf5d')]||[];});else{if(!_0x5cbec0[_0x2afde4('0x170')])return _0x3121ba['userProfileResource'][_0x2afde4('0x1e6e')]({'sectionId':_0x5cbec0['id']})['$promise']['then'](function(_0x270337){const _0x42de12=_0x2afde4,_0x41ace1=_0x2e3ca0()[_0x42de12('0x386')](_0x270337[_0x42de12('0xf5d')],function(_0xbd5eb0){const _0x2038a6=_0x42de12;return _0x2e3ca0()[_0x2038a6('0x1c07')](_0x1b1964[_0x2038a6('0x1693')],{'id':_0xbd5eb0[_0x2038a6('0x832')]});});let _0x3c0081=null;_0x1b1964['voicemail']&&(_0x3c0081=_0x2e3ca0()[_0x42de12('0x1c07')](_0x1b1964[_0x42de12('0x1693')],{'name':_0x1b1964['voicemail'][_0x42de12('0x22d3')]}));if(_0x3c0081&&!_0x2e3ca0()['some'](_0x41ace1,['id',_0x3c0081['id']])){const _0x47ffc5=_0x2e3ca0()[_0x42de12('0x1c07')](_0x1b1964['contexts'],{'id':_0x3c0081['id']});_0x47ffc5[_0x42de12('0x319')]=![],_0x41ace1[_0x42de12('0x1fd0')](_0x47ffc5);}_0x1b1964['contexts']=_0x41ace1;});}})[_0x4a6256('0x130a')](function(_0xc141fc){const _0xbdff50=_0x4a6256;_0x341edd[_0xbdff50('0x52a')]({'title':_0xc141fc[_0xbdff50('0x13ee')]?'API:'+_0xc141fc[_0xbdff50('0x13ee')]+_0xbdff50('0xbf6')+_0xc141fc['statusText']:_0xbdff50('0x1a60'),'msg':_0xc141fc[_0xbdff50('0x5a5')]?JSON[_0xbdff50('0x258a')](_0xc141fc[_0xbdff50('0x5a5')]):_0xc141fc['toString']()});});function _0x47c9e3(){const _0x2acf46=_0x4a6256;_0x1cb1a7['go'](_0x2acf46('0x238a'),{},{'reload':_0x2acf46('0x238a')});}function _0x52c69a(){const _0x329f0f=_0x4a6256;_0x3121ba[_0x329f0f('0x1a6b')]['update']({'id':_0x1b1964[_0x329f0f('0x8ac')]['id']},_0x1b1964[_0x329f0f('0x8ac')])[_0x329f0f('0xe53')][_0x329f0f('0x683')](function(){const _0x4d90cf=_0x329f0f;_0x341edd[_0x4d90cf('0x53')]({'title':_0x4d90cf('0x1467'),'msg':_0x1b1964['voicemail']['name']?_0x1b1964[_0x4d90cf('0x8ac')][_0x4d90cf('0x60a')]+_0x4d90cf('0x96c'):''});})['catch'](function(_0x523bb5){const _0x5e2c15=_0x329f0f;_0x341edd[_0x5e2c15('0x52a')]({'title':_0x523bb5[_0x5e2c15('0x13ee')]?'API:'+_0x523bb5['status']+_0x5e2c15('0xbf6')+_0x523bb5['statusText']:'SYSTEM:GETvoiceMail','msg':_0x523bb5[_0x5e2c15('0x5a5')]?JSON[_0x5e2c15('0x258a')](_0x523bb5['data']):_0x523bb5['toString']()});});}}const _0x3bc2be=_0x5ed65f,_0x7f5f25=_0x180212['p']+_0x189033('0x143b');_0x279d20[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0xb6f'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),'setting'];function _0x279d20(_0xb52fb8,_0x167326,_0x3eddde,_0x33cd79,_0x4e4aca,_0x466883,_0x5179d7,_0xe77171,_0x1a7cfc,_0x55b86a,_0x543222,_0x32ef1b,_0x882c3,_0x5c9b0e,_0x4556e,_0x38b556,_0x4dde75){const _0x380b71=_0x189033,_0x5bb6ec=this;_0x5bb6ec[_0x380b71('0xace')]=_0x38b556,_0x5bb6ec[_0x380b71('0x260a')]=_0x4dde75,_0x5bb6ec[_0x380b71('0x11ed')]=_0x4556e[_0x380b71('0x20b2')](),_0x5bb6ec[_0x380b71('0xb6f')]=_0x1a7cfc||{'count':0x0,'rows':[]},_0x5bb6ec['userProfile']=_0x55b86a,_0x5bb6ec[_0x380b71('0x22df')]=_0x543222&&_0x543222[_0x380b71('0x50d')]==0x1?_0x543222[_0x380b71('0xf5d')][0x0]:null,_0x5bb6ec['crudPermissions']=_0x4556e[_0x380b71('0x142a')](_0x5bb6ec[_0x380b71('0x22df')]?_0x5bb6ec[_0x380b71('0x22df')][_0x380b71('0x1134')]:null),_0x5bb6ec[_0x380b71('0x5c4')]=_0x380b71('0xb6f'),_0x5bb6ec[_0x380b71('0x247')]='',_0x5bb6ec['listOrderAsc']=null,_0x5bb6ec[_0x380b71('0x2d4')]=[],_0x5bb6ec[_0x380b71('0x23a2')]={'fields':_0x380b71('0x10b8'),'sort':_0x380b71('0xc36'),'limit':0xa,'page':0x1},_0x5bb6ec['arrayattach']=_0x2e3ca0()['keyBy']([{'option':_0x380b71('0xe76'),'value':'\x27yes\x27'},{'option':'No','value':_0x380b71('0x23ca')}],function(_0x592d47){const _0x213495=_0x380b71;return _0x2e3ca0()[_0x213495('0x1725')](_0x592d47[_0x213495('0x1c6b')],new RegExp('\x27','g'),'');}),_0x5bb6ec['arrayenvelope']=_0x2e3ca0()['keyBy']([{'option':'Yes','value':_0x380b71('0x2036')},{'option':'No','value':_0x380b71('0x23ca')}],function(_0x5ad6c8){const _0x48f67e=_0x380b71;return _0x2e3ca0()[_0x48f67e('0x1725')](_0x5ad6c8[_0x48f67e('0x1c6b')],new RegExp('\x27','g'),'');}),_0x5bb6ec['arraydelete']=_0x2e3ca0()[_0x380b71('0x24db')]([{'option':_0x380b71('0xe76'),'value':'\x27yes\x27'},{'option':'No','value':_0x380b71('0x23ca')}],function(_0x16c404){return _0x2e3ca0()['replace'](_0x16c404['value'],new RegExp('\x27','g'),'');}),_0x5bb6ec[_0x380b71('0xc63')]=_0x4caa2e,_0x5bb6ec[_0x380b71('0x194f')]=_0x52871d,_0x5bb6ec[_0x380b71('0x53')]=_0x13393d,_0x5bb6ec[_0x380b71('0x1e1')]=_0x392b82,_0x5bb6ec[_0x380b71('0x1574')]=_0x139490,_0x5bb6ec[_0x380b71('0x281b')]=_0x2e3ed9,_0x5bb6ec[_0x380b71('0x1d0b')]=_0x1bc459,_0x5bb6ec['deleteSelectedVoicemails']=_0x6e5a64,_0x5bb6ec[_0x380b71('0x1b6c')]=_0xa5f7cd,_0x5bb6ec['selectAllVoicemails']=_0x2324e8;function _0x4caa2e(_0xf4cb93){const _0x51bfac=_0x380b71;_0x3eddde['go']('app.voice.voicemails.edit',{'id':_0xf4cb93['id'],'voicemail':_0xf4cb93,'crudPermissions':_0x5bb6ec[_0x51bfac('0x1134')]});}function _0x52871d(_0xc6c7cc,_0x2257a3){const _0x14be79=_0x380b71,_0x1bf9e0=_0x4e4aca[_0x14be79('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x14be79('0x1e03')](_0x14be79('0x8ac'))+'?')[_0x14be79('0x26e3')](''+(_0xc6c7cc[_0x14be79('0x60a')]||_0x14be79('0x8ac'))+_0x14be79('0x20f1')+_0x14be79('0x1ee7'))[_0x14be79('0x1040')]('delete\x20voicemail')[_0x14be79('0xe42')](_0x2257a3)['ok']('OK')[_0x14be79('0x19fb')](_0x14be79('0x16b8'));_0x4e4aca[_0x14be79('0x1d4')](_0x1bf9e0)[_0x14be79('0x683')](function(){_0x2e3ed9(_0xc6c7cc);},function(){const _0x4fc247=_0x14be79;console[_0x4fc247('0x1b2b')](_0x4fc247('0x16b8'));});}let _0x37969f=!![],_0x3d89c8=0x1;_0xb52fb8['$watch'](_0x380b71('0x1e1d'),function(_0x509545,_0x548a83){const _0x1472ae=_0x380b71;_0x37969f?_0x5179d7(function(){_0x37969f=![];}):(!_0x548a83&&(_0x3d89c8=_0x5bb6ec[_0x1472ae('0x23a2')][_0x1472ae('0xdf8')]),_0x509545!==_0x548a83&&(_0x5bb6ec[_0x1472ae('0x23a2')]['page']=0x1),!_0x509545&&(_0x5bb6ec[_0x1472ae('0x23a2')]['page']=_0x3d89c8),_0x5bb6ec['getVoicemails']());});function _0x13393d(_0x3ed5ad){const _0x3139a3=_0x380b71;_0x5bb6ec[_0x3139a3('0xb6f')]=_0x3ed5ad||{'count':0x0,'rows':[]};}function _0x392b82(){const _0x1ecf30=_0x380b71;_0x5bb6ec[_0x1ecf30('0x23a2')][_0x1ecf30('0x1cc8')]=(_0x5bb6ec[_0x1ecf30('0x23a2')]['page']-0x1)*_0x5bb6ec[_0x1ecf30('0x23a2')][_0x1ecf30('0x6f0')],_0x4556e[_0x1ecf30('0xca1')](_0x1ecf30('0x20c2'))?_0x5bb6ec['promise']=_0x32ef1b[_0x1ecf30('0x1a6b')]['get'](_0x5bb6ec[_0x1ecf30('0x23a2')],_0x13393d)['$promise']:(_0x5bb6ec[_0x1ecf30('0x23a2')]['id']=_0x5bb6ec[_0x1ecf30('0x2a')]['id'],_0x5bb6ec['query'][_0x1ecf30('0x1aa')]=_0x1ecf30('0x1a4a'),_0x5bb6ec[_0x1ecf30('0x1883')]=_0x32ef1b[_0x1ecf30('0x2a')][_0x1ecf30('0x241d')](_0x5bb6ec[_0x1ecf30('0x23a2')],_0x13393d)['$promise']);}function _0x139490(_0x2ee047,_0x56cf1f){const _0x482ca8=_0x380b71;_0x4e4aca[_0x482ca8('0x1d4')]({'controller':_0x482ca8('0x135a'),'controllerAs':'vm','templateUrl':_0x7f5f25,'parent':angular[_0x482ca8('0x1fcc')](_0x466883[_0x482ca8('0x18e5')]),'targetEvent':_0x2ee047,'clickOutsideToClose':!![],'locals':{'voicemail':_0x56cf1f,'voicemails':_0x5bb6ec[_0x482ca8('0xb6f')][_0x482ca8('0xf5d')],'license':_0x5bb6ec[_0x482ca8('0xace')],'setting':_0x5bb6ec['setting'],'crudPermissions':_0x5bb6ec[_0x482ca8('0x1134')]}});}function _0x2e3ed9(_0x1ee4a5){const _0x15cb23=_0x380b71;_0x32ef1b['voiceMail'][_0x15cb23('0xd7e')]({'id':_0x1ee4a5['id']})[_0x15cb23('0xe53')][_0x15cb23('0x683')](function(){const _0x5b004f=_0x15cb23;_0x2e3ca0()[_0x5b004f('0x3ec')](_0x5bb6ec[_0x5b004f('0xb6f')][_0x5b004f('0xf5d')],{'id':_0x1ee4a5['id']}),_0x5bb6ec[_0x5b004f('0xb6f')]['count']-=0x1,!_0x5bb6ec[_0x5b004f('0xb6f')]['rows']['length']&&_0x5bb6ec['getVoicemails'](),_0x5c9b0e[_0x5b004f('0x53')]({'title':_0x2e3ca0()[_0x5b004f('0x1e03')](_0x5b004f('0xacc'))+_0x5b004f('0xbfc'),'msg':_0x1ee4a5[_0x5b004f('0x60a')]?_0x1ee4a5[_0x5b004f('0x60a')]+_0x5b004f('0x194d'):''});})[_0x15cb23('0x130a')](function(_0x8df7ca){const _0x889a14=_0x15cb23;if(_0x8df7ca[_0x889a14('0x5a5')]&&_0x8df7ca[_0x889a14('0x5a5')]['errors']&&_0x8df7ca[_0x889a14('0x5a5')][_0x889a14('0x17f')][_0x889a14('0x1564')]){_0x5bb6ec[_0x889a14('0x17f')]=_0x8df7ca[_0x889a14('0x5a5')][_0x889a14('0x17f')]||[{'message':_0x8df7ca['toString'](),'type':'SYSTEM:DELETEvoiceMail'}];for(let _0x35173d=0x0;_0x35173d<_0x8df7ca['data'][_0x889a14('0x17f')][_0x889a14('0x1564')];_0x35173d++){_0x5c9b0e['error']({'title':_0x8df7ca['data'][_0x889a14('0x17f')][_0x35173d]['type'],'msg':_0x8df7ca[_0x889a14('0x5a5')]['errors'][_0x35173d][_0x889a14('0x8c2')]});}}else _0x5c9b0e['error']({'title':_0x8df7ca['status']?'API:'+_0x8df7ca[_0x889a14('0x13ee')]+_0x889a14('0xbf6')+_0x8df7ca[_0x889a14('0x24a9')]:_0x889a14('0x16f6'),'msg':_0x8df7ca[_0x889a14('0x5a5')]?JSON[_0x889a14('0x258a')](_0x8df7ca[_0x889a14('0x5a5')][_0x889a14('0x8c2')]):_0x8df7ca[_0x889a14('0x8c2')]||_0x8df7ca[_0x889a14('0x1ff0')]()});});}function _0x1bc459(){const _0x478c74=_0x380b71,_0x27939a=angular['copy'](_0x5bb6ec[_0x478c74('0x2d4')]);return _0x5bb6ec[_0x478c74('0x2d4')]=[],_0x27939a;}function _0x6e5a64(_0x56cc94){const _0x315c86=_0x380b71,_0x2371e1=_0x4e4aca[_0x315c86('0x1c6f')]()[_0x315c86('0xf28')](_0x315c86('0x2315'))[_0x315c86('0x26e3')](_0x315c86('0xed5')+_0x5bb6ec['selectedVoicemails'][_0x315c86('0x1564')]+_0x315c86('0x93c')+_0x315c86('0x1ee7'))['ariaLabel'](_0x315c86('0xc1d'))['targetEvent'](_0x56cc94)['ok']('OK')[_0x315c86('0x19fb')]('CANCEL');_0x4e4aca[_0x315c86('0x1d4')](_0x2371e1)['then'](function(){const _0x1a59f6=_0x315c86;_0x5bb6ec[_0x1a59f6('0x2d4')][_0x1a59f6('0x1299')](function(_0x4a1064){_0x2e3ed9(_0x4a1064);}),_0x5bb6ec[_0x1a59f6('0x2d4')]=[];});}function _0xa5f7cd(){_0x5bb6ec['selectedVoicemails']=[];}function _0x2324e8(){const _0x3fae0a=_0x380b71;_0x5bb6ec[_0x3fae0a('0x2d4')]=_0x5bb6ec[_0x3fae0a('0xb6f')][_0x3fae0a('0xf5d')];}}const _0x5cfc17=_0x279d20;_0x495752['$inject']=['$scope','$state',_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x173'),_0x189033('0x110a'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x495752(_0x3f22b0,_0x12dad4,_0x31dea3,_0x332f44,_0x553237,_0x259e5b,_0x1c52b2,_0x1a8489,_0x41b983,_0x1de90c,_0xafc268,_0x296bc6,_0x206d24,_0x2ca395){const _0x3d3161=_0x189033,_0x18b3fd=this;_0x18b3fd[_0x3d3161('0x11ed')]=_0xafc268[_0x3d3161('0x20b2')](),_0x18b3fd['errors']=[],_0x18b3fd[_0x3d3161('0x260a')]=_0x206d24,_0x18b3fd[_0x3d3161('0xace')]=_0x296bc6,_0x18b3fd[_0x3d3161('0x1134')]=_0x2ca395,_0x18b3fd['hasModulePermissions']={},_0x18b3fd[_0x3d3161('0x19b2')]=_0x18b3fd[_0x3d3161('0x260a')]&&_0x18b3fd['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x18b3fd[_0x3d3161('0xf28')]=_0x3d3161('0x495'),_0x18b3fd[_0x3d3161('0x110a')]=angular[_0x3d3161('0x1a86')](_0x41b983),_0x18b3fd['voicePrefixes']=_0x1a8489,_0x18b3fd[_0x3d3161('0x846')]=![];!_0x18b3fd[_0x3d3161('0x110a')]&&(_0x18b3fd[_0x3d3161('0x110a')]={},_0x18b3fd[_0x3d3161('0xf28')]=_0x3d3161('0x785'),_0x18b3fd[_0x3d3161('0x846')]=!![]);_0x18b3fd[_0x3d3161('0x7fd')]=_0x11838f,_0x18b3fd[_0x3d3161('0x12e9')]=_0xce7ba,_0x18b3fd[_0x3d3161('0x261a')]=_0x28583,_0x18b3fd[_0x3d3161('0x16b3')]=_0x56c0bf,_0x18b3fd[_0x3d3161('0xf82')]=_0x5c1a7b,_0xafc268['hasRole'](_0x3d3161('0x20c2'))?_0x1de90c[_0x3d3161('0x14cb')][_0x3d3161('0x1e6e')]({'fields':_0x3d3161('0x5c6'),'type':_0x3d3161('0x17cd'),'VoiceExtensionId':_0x3d3161('0x13c'),'nolimit':'true'})['$promise'][_0x3d3161('0x683')](function(_0x2c6ad5){const _0x435ce4=_0x3d3161;_0x18b3fd[_0x435ce4('0x871')]=_0x2c6ad5['rows']||[];})[_0x3d3161('0x130a')](function(_0x514589){const _0x1c5c73=_0x3d3161;_0x1c52b2[_0x1c5c73('0x52a')]({'title':_0x514589[_0x1c5c73('0x13ee')]?'API:'+_0x514589['status']+'\x20-\x20'+_0x514589[_0x1c5c73('0x24a9')]:_0x1c5c73('0xaf8'),'msg':_0x514589['data']?JSON[_0x1c5c73('0x258a')](_0x514589[_0x1c5c73('0x5a5')]):_0x514589[_0x1c5c73('0x1ff0')]()});}):_0x1de90c[_0x3d3161('0x14cb')]['get']({'fields':_0x3d3161('0x5c6'),'type':'outbound','VoiceExtensionId':_0x3d3161('0x13c'),'nolimit':'true'})[_0x3d3161('0xe53')][_0x3d3161('0x683')](function(_0x421913){const _0x5e3a47=_0x3d3161;_0x18b3fd[_0x5e3a47('0x871')]=_0x421913[_0x5e3a47('0xf5d')]||[];})[_0x3d3161('0x683')](function(){const _0x89fd1=_0x3d3161;return _0x1de90c[_0x89fd1('0x22df')]['get']({'userProfileId':_0x18b3fd[_0x89fd1('0x11ed')][_0x89fd1('0x2f')],'sectionId':0x193})[_0x89fd1('0xe53')];})['then'](function(_0x1264a9){const _0x2f37c2=_0x3d3161,_0x3de789=_0x1264a9&&_0x1264a9['rows']?_0x1264a9['rows'][0x0]:null;if(!_0x3de789){const _0x46a4f4=[];let _0x3dea7e=null;_0x18b3fd['voicePrefix']&&(_0x3dea7e=_0x2e3ca0()[_0x2f37c2('0x1c07')](_0x18b3fd[_0x2f37c2('0x871')],{'id':Number(_0x18b3fd[_0x2f37c2('0x110a')][_0x2f37c2('0x18fd')])}));for(let _0x25bcde=0x0;_0x25bcde<_0x18b3fd[_0x2f37c2('0x871')][_0x2f37c2('0x1564')];_0x25bcde++){_0x3dea7e&&_0x18b3fd[_0x2f37c2('0x871')][_0x25bcde]['id']===_0x3dea7e['id']&&(_0x18b3fd[_0x2f37c2('0x871')][_0x25bcde][_0x2f37c2('0x319')]=![],_0x46a4f4['push'](_0x18b3fd['outboundRoutes'][_0x25bcde]));}_0x18b3fd[_0x2f37c2('0x871')]=_0x46a4f4;}else{if(!_0x3de789[_0x2f37c2('0x170')])return _0x1de90c[_0x2f37c2('0xcf7')][_0x2f37c2('0x1e6e')]({'sectionId':_0x3de789['id']})['$promise']['then'](function(_0x44b39f){const _0x12d942=_0x2f37c2,_0x53198e=_0x2e3ca0()[_0x12d942('0x386')](_0x44b39f[_0x12d942('0xf5d')],function(_0x397405){const _0x18945a=_0x12d942;return _0x2e3ca0()['find'](_0x18b3fd[_0x18945a('0x871')],{'id':_0x397405[_0x18945a('0x832')]});});let _0x1285a2=null;_0x18b3fd['voicePrefix']&&(_0x1285a2=_0x2e3ca0()[_0x12d942('0x1c07')](_0x18b3fd['outboundRoutes'],{'id':Number(_0x18b3fd[_0x12d942('0x110a')][_0x12d942('0x18fd')])}));if(_0x1285a2&&!_0x2e3ca0()[_0x12d942('0x7a2')](_0x53198e,['id',_0x1285a2['id']])){const _0x22c632=_0x2e3ca0()[_0x12d942('0x1c07')](_0x18b3fd['outboundRoutes'],{'id':_0x1285a2['id']});_0x22c632[_0x12d942('0x319')]=![],_0x53198e[_0x12d942('0x1fd0')](_0x22c632);}_0x18b3fd[_0x12d942('0x871')]=_0x53198e;});}})[_0x3d3161('0x130a')](function(_0x5c6a17){const _0x1f8a95=_0x3d3161;_0x1c52b2[_0x1f8a95('0x52a')]({'title':_0x5c6a17[_0x1f8a95('0x13ee')]?_0x1f8a95('0x2168')+_0x5c6a17[_0x1f8a95('0x13ee')]+'\x20-\x20'+_0x5c6a17[_0x1f8a95('0x24a9')]:_0x1f8a95('0x79d'),'msg':_0x5c6a17[_0x1f8a95('0x5a5')]?JSON[_0x1f8a95('0x258a')](_0x5c6a17['data']):_0x5c6a17[_0x1f8a95('0x1ff0')]()});});function _0x11838f(){const _0x367bcb=_0x3d3161;_0x18b3fd['errors']=[],_0x1de90c[_0x367bcb('0x110a')][_0x367bcb('0xb0a')](_0x18b3fd[_0x367bcb('0x110a')])[_0x367bcb('0xe53')][_0x367bcb('0x683')](function(_0x149eed){const _0x1905c3=_0x367bcb;_0x18b3fd['voicePrefixes']['unshift'](_0x149eed[_0x1905c3('0x24e1')]()),_0x1c52b2[_0x1905c3('0x53')]({'title':_0x1905c3('0x227b'),'msg':_0x18b3fd[_0x1905c3('0x110a')][_0x1905c3('0x60a')]?_0x18b3fd[_0x1905c3('0x110a')]['name']+_0x1905c3('0x14b5'):''}),_0x5c1a7b(_0x149eed);})[_0x367bcb('0x130a')](function(_0x193695){const _0x48abb1=_0x367bcb;if(_0x193695[_0x48abb1('0x5a5')]&&_0x193695[_0x48abb1('0x5a5')][_0x48abb1('0x17f')]&&_0x193695[_0x48abb1('0x5a5')]['errors']['length']){_0x18b3fd[_0x48abb1('0x17f')]=_0x193695[_0x48abb1('0x5a5')][_0x48abb1('0x17f')]||[{'message':_0x193695[_0x48abb1('0x1ff0')](),'type':_0x48abb1('0x701')}];for(let _0xc490e5=0x0;_0xc490e5<_0x193695[_0x48abb1('0x5a5')][_0x48abb1('0x17f')][_0x48abb1('0x1564')];_0xc490e5+=0x1){_0x1c52b2[_0x48abb1('0x52a')]({'title':_0x193695[_0x48abb1('0x5a5')][_0x48abb1('0x17f')][_0xc490e5]['type'],'msg':_0x193695['data'][_0x48abb1('0x17f')][_0xc490e5][_0x48abb1('0x8c2')]});}}else _0x1c52b2[_0x48abb1('0x52a')]({'title':_0x193695[_0x48abb1('0x13ee')]?'API:'+_0x193695['status']+_0x48abb1('0xbf6')+_0x193695[_0x48abb1('0x24a9')]:_0x48abb1('0x701'),'msg':_0x193695['data']?JSON[_0x48abb1('0x258a')](_0x193695[_0x48abb1('0x5a5')][_0x48abb1('0x8c2')]):_0x193695[_0x48abb1('0x1ff0')]()});});}function _0xce7ba(){const _0x362cd1=_0x3d3161;_0x18b3fd['errors']=[],_0x1de90c[_0x362cd1('0x110a')][_0x362cd1('0x2480')]({'id':_0x18b3fd[_0x362cd1('0x110a')]['id']},_0x18b3fd['voicePrefix'])[_0x362cd1('0xe53')]['then'](function(_0x4fbe24){const _0x24b6b7=_0x362cd1,_0x118c48=_0x2e3ca0()[_0x24b6b7('0x1c07')](_0x18b3fd[_0x24b6b7('0x173')],{'id':_0x4fbe24['id']});_0x118c48&&_0x2e3ca0()[_0x24b6b7('0xf22')](_0x118c48,_0x2e3ca0()[_0x24b6b7('0x24d0')](_0x4fbe24[_0x24b6b7('0x24e1')](),_0x2e3ca0()[_0x24b6b7('0x55e')](_0x118c48))),_0x1c52b2[_0x24b6b7('0x53')]({'title':'voicePrefix\x20properly\x20saved!','msg':_0x18b3fd[_0x24b6b7('0x110a')][_0x24b6b7('0x60a')]?_0x18b3fd[_0x24b6b7('0x110a')][_0x24b6b7('0x60a')]+_0x24b6b7('0xf59'):''}),_0x5c1a7b(_0x4fbe24);})['catch'](function(_0xc4f536){const _0xc11057=_0x362cd1;if(_0xc4f536[_0xc11057('0x5a5')]&&_0xc4f536[_0xc11057('0x5a5')][_0xc11057('0x17f')]&&_0xc4f536[_0xc11057('0x5a5')]['errors']['length']){_0x18b3fd[_0xc11057('0x17f')]=_0xc4f536['data'][_0xc11057('0x17f')]||[{'message':_0xc4f536['toString'](),'type':'api.voicePrefix.update'}];for(let _0x450086=0x0;_0x450086<_0xc4f536['data'][_0xc11057('0x17f')]['length'];_0x450086++){_0x1c52b2[_0xc11057('0x52a')]({'title':_0xc4f536[_0xc11057('0x5a5')][_0xc11057('0x17f')][_0x450086][_0xc11057('0xcf0')],'msg':_0xc4f536[_0xc11057('0x5a5')]['errors'][_0x450086][_0xc11057('0x8c2')]});}}else _0x1c52b2['error']({'title':_0xc4f536['status']?_0xc11057('0x2168')+_0xc4f536[_0xc11057('0x13ee')]+'\x20-\x20'+_0xc4f536[_0xc11057('0x24a9')]:'api.voicePrefix.update','msg':_0xc4f536['data']?JSON[_0xc11057('0x258a')](_0xc4f536['data'][_0xc11057('0x8c2')]):_0xc4f536[_0xc11057('0x1ff0')]()});});}function _0x28583(_0x2d6967){const _0x5282f2=_0x3d3161;_0x18b3fd[_0x5282f2('0x17f')]=[];const _0x632e23=_0x332f44[_0x5282f2('0x1c6f')]()[_0x5282f2('0xf28')](_0x5282f2('0x4d'))['content'](_0x5282f2('0xe3f'))[_0x5282f2('0x1040')]('Delete\x20voicePrefix')['ok'](_0x5282f2('0x2307'))[_0x5282f2('0x19fb')]('Cancel')[_0x5282f2('0xe42')](_0x2d6967);_0x332f44[_0x5282f2('0x1d4')](_0x632e23)[_0x5282f2('0x683')](function(){const _0x19e396=_0x5282f2;_0x1de90c[_0x19e396('0x110a')]['delete']({'id':_0x18b3fd[_0x19e396('0x110a')]['id']})[_0x19e396('0xe53')][_0x19e396('0x683')](function(){const _0xd83101=_0x19e396;_0x2e3ca0()[_0xd83101('0x3ec')](_0x18b3fd[_0xd83101('0x173')],{'id':_0x18b3fd['voicePrefix']['id']}),_0x1c52b2[_0xd83101('0x53')]({'title':'voicePrefix\x20properly\x20deleted!','msg':(_0x18b3fd['voicePrefix'][_0xd83101('0x60a')]||_0xd83101('0x110a'))+_0xd83101('0x194d')}),_0x5c1a7b(_0x18b3fd[_0xd83101('0x110a')]);})[_0x19e396('0x130a')](function(_0x160916){const _0x1d6a0d=_0x19e396;if(_0x160916[_0x1d6a0d('0x5a5')]&&_0x160916[_0x1d6a0d('0x5a5')]['errors']&&_0x160916[_0x1d6a0d('0x5a5')][_0x1d6a0d('0x17f')][_0x1d6a0d('0x1564')]){_0x18b3fd[_0x1d6a0d('0x17f')]=_0x160916[_0x1d6a0d('0x5a5')]['errors']||[{'message':_0x160916[_0x1d6a0d('0x1ff0')](),'type':'api.voicePrefix.delete'}];for(let _0x2d77cd=0x0;_0x2d77cd<_0x160916[_0x1d6a0d('0x5a5')][_0x1d6a0d('0x17f')]['length'];_0x2d77cd++){_0x1c52b2[_0x1d6a0d('0x52a')]({'title':_0x160916[_0x1d6a0d('0x5a5')][_0x1d6a0d('0x17f')][_0x2d77cd][_0x1d6a0d('0xcf0')],'msg':_0x160916['data'][_0x1d6a0d('0x17f')][_0x2d77cd][_0x1d6a0d('0x8c2')]});}}else _0x1c52b2[_0x1d6a0d('0x52a')]({'title':_0x160916[_0x1d6a0d('0x13ee')]?_0x1d6a0d('0x2168')+_0x160916['status']+'\x20-\x20'+_0x160916[_0x1d6a0d('0x24a9')]:_0x1d6a0d('0xcf9'),'msg':_0x160916[_0x1d6a0d('0x5a5')]?JSON[_0x1d6a0d('0x258a')](_0x160916[_0x1d6a0d('0x5a5')][_0x1d6a0d('0x8c2')]):_0x160916['message']||_0x160916[_0x1d6a0d('0x1ff0')]()});});},function(){});}function _0x56c0bf(_0x2ee8f7){return _0x2ee8f7===null?undefined:new Date(_0x2ee8f7);}function _0x5c1a7b(_0x1974b8){const _0x105c2a=_0x3d3161;_0x332f44[_0x105c2a('0x1715')](_0x1974b8);}}const _0x124941=_0x495752;_0xf3219f[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),'api',_0x189033('0x110a'),_0x189033('0x173'),'realtime','$translate',_0x189033('0xba1'),_0x189033('0x1134')];function _0xf3219f(_0x170b8e,_0x3273d0,_0x150198,_0x57cd81,_0x5675df,_0x3e6b2e,_0x1045b8,_0x1fab8b,_0x497729,_0x1cb1af){const _0x36a3aa=_0x189033,_0x26dda2=this;_0x26dda2[_0x36a3aa('0x11ed')]=_0x497729[_0x36a3aa('0x20b2')](),_0x26dda2['voicePrefix']=_0x5675df,_0x26dda2['crudPermissions']=_0x1cb1af,_0x26dda2['realtime']=_0x1045b8,_0x26dda2['items']=[],_0x26dda2[_0x36a3aa('0x1c47')]=[],_0x26dda2[_0x36a3aa('0x1378')]=[],_0x26dda2['startingAllowedItems']=[],_0x26dda2[_0x36a3aa('0x23a7')]=[],_0x26dda2[_0x36a3aa('0x2106')]=![],_0x26dda2[_0x36a3aa('0x1dd2')]=_0x2a1352,_0x26dda2['saveAgents']=_0x2ddd71,_0x26dda2[_0x36a3aa('0xf82')]=_0x4cef9d,_0x26dda2[_0x36a3aa('0x169f')]={'readOnly':!_0x26dda2[_0x36a3aa('0x1134')][_0x36a3aa('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x36a3aa('0x60a'),'line1':'fullname','line2':[_0x36a3aa('0x60a'),'internal'],'line3':'','labelAll':_0x1fab8b[_0x36a3aa('0x2728')](_0x36a3aa('0xef3')),'labelSelected':_0x1fab8b['instant'](_0x36a3aa('0x1787')),'transferCallback':function(){const _0x4647e1=_0x36a3aa,_0x5953c4=_0x2e3ca0()[_0x4647e1('0x25cb')](_0x26dda2[_0x4647e1('0x23a7')],_0x26dda2['selectedItems'],'id');_0x26dda2[_0x4647e1('0x2106')]=_0x2e3ca0()[_0x4647e1('0x173f')](_0x5953c4)?![]:!![];}};function _0x2a1352(){const _0x39f3ba=_0x36a3aa;return _0x497729[_0x39f3ba('0xca1')](_0x39f3ba('0x20c2'))?_0x46a13b()[_0x39f3ba('0x130a')](function(_0x4a709d){const _0x464c67=_0x39f3ba;_0x150198['error']({'title':_0x4a709d[_0x464c67('0x13ee')]?_0x464c67('0x2168')+_0x4a709d[_0x464c67('0x13ee')]+_0x464c67('0xbf6')+_0x4a709d[_0x464c67('0x24a9')]:_0x464c67('0x144f'),'msg':_0x4a709d[_0x464c67('0x13ee')]?JSON[_0x464c67('0x258a')](_0x4a709d[_0x464c67('0x5a5')]):_0x4a709d[_0x464c67('0x1ff0')]()});}):_0x34d8ec()[_0x39f3ba('0x683')](function(_0x361377){const _0x1266b3=_0x39f3ba;return _0x26dda2[_0x1266b3('0x1aa')]=_0x361377,_0x46a13b();})[_0x39f3ba('0x130a')](function(_0x3758c7){const _0x14de63=_0x39f3ba;_0x150198[_0x14de63('0x52a')]({'title':_0x3758c7[_0x14de63('0x13ee')]?_0x14de63('0x2168')+_0x3758c7['status']+'\x20-\x20'+_0x3758c7[_0x14de63('0x24a9')]:_0x14de63('0x144f'),'msg':_0x3758c7['status']?JSON[_0x14de63('0x258a')](_0x3758c7[_0x14de63('0x5a5')]):_0x3758c7['toString']()});});}function _0x34d8ec(){return _0x3273d0(function(_0x569c93,_0x103b6f){const _0x21f401=a0_0x4e0a;_0x57cd81['userProfileSection'][_0x21f401('0x1e6e')]({'userProfileId':_0x26dda2[_0x21f401('0x11ed')]['userProfileId'],'name':_0x21f401('0x1bc0')})[_0x21f401('0xe53')][_0x21f401('0x683')](function(_0x1d034f){const _0x28ec28=_0x21f401,_0xdd7729=_0x1d034f&&_0x1d034f['rows']?_0x1d034f[_0x28ec28('0xf5d')][0x0]:null;_0x569c93(_0xdd7729);})[_0x21f401('0x130a')](function(_0x47181e){_0x103b6f(_0x47181e);});});}function _0x46a13b(){return _0x3273d0(function(_0x40d63f,_0x3779f6){const _0x59d95e=a0_0x4e0a;return _0x41540e()['then'](function(_0x5a00ee){const _0x2e75a7=a0_0x4e0a;return _0x26dda2['items']=_0x5a00ee[_0x2e75a7('0xf5d')]?_0x5a00ee[_0x2e75a7('0xf5d')]:[],_0x497729[_0x2e75a7('0xca1')](_0x2e75a7('0x20c2'))?_0x5a00ee:_0x26dda2[_0x2e75a7('0x1aa')]?_0x26dda2[_0x2e75a7('0x1aa')][_0x2e75a7('0x170')]?_0x5a00ee:_0x10d0ec():null;})[_0x59d95e('0x683')](function(_0x89aa4e){const _0x3699d8=_0x59d95e,_0x477bf7=_0x89aa4e&&_0x89aa4e[_0x3699d8('0xf5d')]?_0x89aa4e[_0x3699d8('0xf5d')]:[];return _0x26dda2[_0x3699d8('0x1c47')]=_0x2e3ca0()[_0x3699d8('0x386')](_0x477bf7,function(_0x2361d3){const _0xc56dc8=_0x3699d8;return _0x2e3ca0()['find'](_0x26dda2[_0xc56dc8('0x1996')],{'id':_0x497729[_0xc56dc8('0xca1')]('admin')||_0x26dda2[_0xc56dc8('0x1aa')]['autoAssociation']?_0x2361d3['id']:_0x2361d3[_0xc56dc8('0x832')]});}),_0x26dda2[_0x3699d8('0x125e')]=angular[_0x3699d8('0x1a86')](_0x26dda2[_0x3699d8('0x1c47')]),_0x26dda2[_0x3699d8('0x1996')][_0x3699d8('0x1299')](function(_0x32d356){const _0x1cb428=_0x3699d8,_0x39a956=_0x2e3ca0()['find'](_0x26dda2['allowedItems'],{'id':_0x32d356['id']});_0x497729[_0x1cb428('0xca1')](_0x1cb428('0x20c2'))?_0x32d356[_0x1cb428('0x24f4')]=!![]:_0x32d356[_0x1cb428('0x24f4')]=typeof _0x39a956!==_0x1cb428('0x1867')?!![]:![];}),_0x24fd96();})[_0x59d95e('0x683')](function(_0x1690a5){const _0x49a654=_0x59d95e,_0xffbf5a=_0x1690a5&&_0x1690a5[_0x49a654('0xf5d')]?_0x1690a5[_0x49a654('0xf5d')]:[];_0x26dda2[_0x49a654('0x1378')]=_0x2e3ca0()[_0x49a654('0x386')](_0xffbf5a,function(_0x1ac5cf){const _0x28e70e=_0x49a654,_0x58ff2c=_0x2e3ca0()['find'](_0x26dda2[_0x28e70e('0x1996')],{'id':_0x1ac5cf['id']});return _0x58ff2c[_0x28e70e('0x1e2a')]=_0x1ac5cf[_0x28e70e('0x70b')]?_0x28e70e('0x23d0')+_0x1ac5cf[_0x28e70e('0x70b')][_0x28e70e('0x1e2a')]:'',_0x58ff2c[_0x28e70e('0x1d43')]=typeof _0x1ac5cf[_0x28e70e('0x1d43')]!==_0x28e70e('0x1867')?'<'+_0x1ac5cf[_0x28e70e('0x1d43')]+'>':'',_0x58ff2c;}),_0x26dda2[_0x49a654('0x23a7')]=angular[_0x49a654('0x1a86')](_0x26dda2[_0x49a654('0x1378')]),_0x26dda2[_0x49a654('0x169f')]['selectedItems']=_0x26dda2[_0x49a654('0x1378')],_0x26dda2[_0x49a654('0x169f')]['items']=_0x2e3ca0()[_0x49a654('0x461')](_0x26dda2['allowedItems'],_0x26dda2[_0x49a654('0x169f')][_0x49a654('0x1378')],'id'),_0x40d63f();})['catch'](function(_0x453275){_0x3779f6(_0x453275);});});}function _0x10d0ec(){return _0x3273d0(function(_0x5b521b,_0x196223){const _0x7d5922=a0_0x4e0a;return _0x57cd81['userProfileResource'][_0x7d5922('0x1e6e')]({'sectionId':_0x26dda2['section']['id'],'nolimit':!![]})[_0x7d5922('0xe53')][_0x7d5922('0x683')](function(_0x35f748){_0x5b521b(_0x35f748);})['catch'](function(_0x2880d9){_0x196223(_0x2880d9);});});}function _0x24fd96(){return _0x3273d0(function(_0x448f53,_0x27c195){const _0x4353db=a0_0x4e0a;return _0x57cd81[_0x4353db('0x110a')]['getAgents']({'id':_0x26dda2[_0x4353db('0x110a')]['id'],'fields':_0x4353db('0x72b'),'nolimit':!![],'role':_0x4353db('0x2327')})[_0x4353db('0xe53')][_0x4353db('0x683')](function(_0x2d6d89){_0x448f53(_0x2d6d89);})['catch'](function(_0x104582){_0x27c195(_0x104582);});});}function _0x41540e(){return _0x3273d0(function(_0x183255,_0x54aa04){const _0x3c334c=a0_0x4e0a;return _0x57cd81['user'][_0x3c334c('0x1e6e')]({'fields':_0x3c334c('0x72b'),'nolimit':!![],'role':_0x3c334c('0x2327')})[_0x3c334c('0xe53')][_0x3c334c('0x683')](function(_0x5aeaf6){_0x183255(_0x5aeaf6);})['catch'](function(_0x49053f){_0x54aa04(_0x49053f);});});}function _0x28f5ef(_0xe748b3){return _0x3273d0(function(_0x1170be,_0x44e40c){const _0xadca8e=a0_0x4e0a;_0x2e3ca0()[_0xadca8e('0x173f')](_0xe748b3)?_0x1170be():_0x57cd81['voicePrefix']['addAgents']({'id':_0x26dda2[_0xadca8e('0x110a')]['id'],'ids':_0x2e3ca0()[_0xadca8e('0x386')](_0xe748b3,'id')})[_0xadca8e('0xe53')][_0xadca8e('0x683')](function(){_0x1170be();})['catch'](function(_0x3ba631){_0x44e40c(_0x3ba631);});});}function _0x36f62f(_0x3d8751){return _0x3273d0(function(_0x1f8bd0,_0x4be060){const _0x540214=a0_0x4e0a;_0x2e3ca0()[_0x540214('0x173f')](_0x3d8751)?_0x1f8bd0():_0x57cd81[_0x540214('0x110a')][_0x540214('0xf9')]({'id':_0x26dda2[_0x540214('0x110a')]['id'],'ids':_0x2e3ca0()[_0x540214('0x386')](_0x3d8751,'id')})['$promise']['then'](function(){_0x1f8bd0();})[_0x540214('0x130a')](function(_0x5bc799){_0x4be060(_0x5bc799);});});}function _0x2ddd71(){const _0x49b53d=_0x36a3aa,_0x499716=_0x2e3ca0()['differenceBy'](_0x26dda2['startingSelectedItems'],_0x26dda2[_0x49b53d('0x1378')],'id'),_0x2e08c5=_0x2e3ca0()['differenceBy'](_0x26dda2['selectedItems'],_0x26dda2[_0x49b53d('0x23a7')],'id');return _0x36f62f(_0x499716)[_0x49b53d('0x683')](function(){return _0x28f5ef(_0x2e08c5);})[_0x49b53d('0x683')](function(){const _0x867355=_0x49b53d;_0x26dda2[_0x867355('0x2106')]=![],_0x26dda2['startingAllowedItems']=angular[_0x867355('0x1a86')](_0x26dda2['allowedItems']),_0x26dda2['startingSelectedItems']=angular['copy'](_0x26dda2[_0x867355('0x1378')]),_0x150198[_0x867355('0x53')]({'title':_0x867355('0xd28'),'msg':_0x867355('0x89d')});})['catch'](function(_0x31892e){const _0x1ae19d=_0x49b53d;_0x150198['error']({'title':_0x31892e[_0x1ae19d('0x13ee')]?_0x1ae19d('0x2168')+_0x31892e[_0x1ae19d('0x13ee')]+_0x1ae19d('0xbf6')+_0x31892e[_0x1ae19d('0x24a9')]:_0x1ae19d('0x1b71'),'msg':_0x31892e['status']?JSON[_0x1ae19d('0x258a')](_0x31892e[_0x1ae19d('0x5a5')]):_0x31892e[_0x1ae19d('0x1ff0')]()});});}function _0x4cef9d(){const _0x284f23=_0x36a3aa;_0x170b8e[_0x284f23('0x1715')]();}}const _0x18c34c=_0xf3219f,_0x14561f=_0x180212['p']+_0x189033('0x2057'),_0x3f4cba=_0x180212['p']+_0x189033('0xe0');_0x531f6a['$inject']=['$scope','$window',_0x189033('0x938'),_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),'voicePrefixes',_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),'msUtils',_0x189033('0x1d70'),'Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x531f6a(_0x1408d1,_0x1d0417,_0xf23180,_0x3bd81f,_0x47b52f,_0x4088f2,_0x316f04,_0x3969c5,_0x18585b,_0x4f4e6d,_0x41b00b,_0x243c21,_0x1d35d1,_0x321ce2,_0x4dca80,_0x19d037,_0x475a0b){const _0x187f2d=_0x189033,_0x448fe8=this;_0x448fe8[_0x187f2d('0xace')]=_0x19d037,_0x448fe8['setting']=_0x475a0b,_0x448fe8[_0x187f2d('0x11ed')]=_0x4dca80[_0x187f2d('0x20b2')](),_0x448fe8['voicePrefixes']=_0x18585b||{'count':0x0,'rows':[]},_0x448fe8[_0x187f2d('0x2a')]=_0x4f4e6d,_0x448fe8[_0x187f2d('0x22df')]=_0x41b00b&&_0x41b00b[_0x187f2d('0x50d')]==0x1?_0x41b00b[_0x187f2d('0xf5d')][0x0]:null,_0x448fe8['crudPermissions']=_0x4dca80['parseCrudPermissions'](_0x448fe8[_0x187f2d('0x22df')]?_0x448fe8[_0x187f2d('0x22df')][_0x187f2d('0x1134')]:null),_0x448fe8['table']=_0x187f2d('0x173'),_0x448fe8[_0x187f2d('0x247')]='',_0x448fe8[_0x187f2d('0x1ce2')]=null,_0x448fe8[_0x187f2d('0xa3a')]=[],_0x448fe8['query']={'fields':_0x187f2d('0xe50'),'limit':0xa,'page':0x1},_0x448fe8['editdialog']=_0x4613c3,_0x448fe8['agentadddialog']=_0xd36329,_0x448fe8[_0x187f2d('0x194f')]=_0xc28cf1,_0x448fe8[_0x187f2d('0x53')]=_0x5d1d0a,_0x448fe8['getVoicePrefixes']=_0x3942a3,_0x448fe8[_0x187f2d('0x178d')]=_0x77793b,_0x448fe8[_0x187f2d('0x261a')]=_0x54b743,_0x448fe8['exportSelectedVoicePrefixes']=_0x23e9c8,_0x448fe8[_0x187f2d('0x23d8')]=_0x38110a,_0x448fe8[_0x187f2d('0x273')]=_0xa90533,_0x448fe8[_0x187f2d('0x1aab')]=_0x5bf122,_0x4dca80[_0x187f2d('0xca1')]('admin')?_0x243c21[_0x187f2d('0x14cb')]['get']({'fields':'id,exten','type':'outbound','VoiceExtensionId':_0x187f2d('0x13c'),'nolimit':_0x187f2d('0x26ac')})[_0x187f2d('0xe53')][_0x187f2d('0x683')](function(_0x4e68a3){const _0x531d6c=_0x187f2d;_0x448fe8['outboundRoutes']=_0x4e68a3[_0x531d6c('0xf5d')]||[];})[_0x187f2d('0x130a')](function(_0x10d76c){const _0x22d4ed=_0x187f2d;_0x321ce2[_0x22d4ed('0x52a')]({'title':_0x10d76c[_0x22d4ed('0x13ee')]?'API:'+_0x10d76c[_0x22d4ed('0x13ee')]+_0x22d4ed('0xbf6')+_0x10d76c[_0x22d4ed('0x24a9')]:_0x22d4ed('0xaf8'),'msg':_0x10d76c[_0x22d4ed('0x5a5')]?JSON['stringify'](_0x10d76c['data']):_0x10d76c['toString']()});}):_0x243c21[_0x187f2d('0x14cb')][_0x187f2d('0x1e6e')]({'fields':_0x187f2d('0x5c6'),'type':'outbound','VoiceExtensionId':_0x187f2d('0x13c'),'nolimit':_0x187f2d('0x26ac')})['$promise'][_0x187f2d('0x683')](function(_0x3faaca){const _0x48745a=_0x187f2d;_0x448fe8[_0x48745a('0x871')]=_0x3faaca[_0x48745a('0xf5d')]||[];})[_0x187f2d('0x683')](function(){const _0xf9051f=_0x187f2d;return _0x243c21[_0xf9051f('0x22df')][_0xf9051f('0x1e6e')]({'userProfileId':_0x448fe8[_0xf9051f('0x11ed')]['userProfileId'],'sectionId':0x193})[_0xf9051f('0xe53')];})['then'](function(_0x316b88){const _0x95e973=_0x187f2d,_0x82629c=_0x316b88&&_0x316b88[_0x95e973('0xf5d')]?_0x316b88['rows'][0x0]:null;if(!_0x82629c){const _0xdaf129=[];let _0x195305=null;_0x448fe8[_0x95e973('0x110a')]&&(_0x195305=_0x2e3ca0()['find'](_0x448fe8[_0x95e973('0x871')],{'id':Number(_0x448fe8['voicePrefix'][_0x95e973('0x18fd')])}));for(let _0x389612=0x0;_0x389612<_0x448fe8[_0x95e973('0x871')][_0x95e973('0x1564')];_0x389612++){_0x195305&&_0x448fe8['outboundRoutes'][_0x389612]['id']===_0x195305['id']&&(_0x448fe8[_0x95e973('0x871')][_0x389612][_0x95e973('0x319')]=![],_0xdaf129[_0x95e973('0x1fd0')](_0x448fe8[_0x95e973('0x871')][_0x389612]));}_0x448fe8[_0x95e973('0x871')]=_0xdaf129;}else{if(!_0x82629c['autoAssociation'])return _0x243c21['userProfileResource'][_0x95e973('0x1e6e')]({'sectionId':_0x82629c['id']})[_0x95e973('0xe53')][_0x95e973('0x683')](function(_0x20ba8f){const _0xb48322=_0x95e973,_0x48a718=_0x2e3ca0()[_0xb48322('0x386')](_0x20ba8f[_0xb48322('0xf5d')],function(_0x459c69){const _0x3e696e=_0xb48322;return _0x2e3ca0()[_0x3e696e('0x1c07')](_0x448fe8[_0x3e696e('0x871')],{'id':_0x459c69[_0x3e696e('0x832')]});});let _0x3a1c09=null;_0x448fe8[_0xb48322('0x110a')]&&(_0x3a1c09=_0x2e3ca0()[_0xb48322('0x1c07')](_0x448fe8[_0xb48322('0x871')],{'id':Number(_0x448fe8['voicePrefix'][_0xb48322('0x18fd')])}));if(_0x3a1c09&&!_0x2e3ca0()[_0xb48322('0x7a2')](_0x48a718,['id',_0x3a1c09['id']])){const _0x66936a=_0x2e3ca0()['find'](_0x448fe8[_0xb48322('0x871')],{'id':_0x3a1c09['id']});_0x66936a['canSelect']=![],_0x48a718[_0xb48322('0x1fd0')](_0x66936a);}_0x448fe8[_0xb48322('0x871')]=_0x48a718;});}})[_0x187f2d('0x130a')](function(_0x366b14){const _0x311bff=_0x187f2d;_0x321ce2[_0x311bff('0x52a')]({'title':_0x366b14[_0x311bff('0x13ee')]?'API:'+_0x366b14[_0x311bff('0x13ee')]+_0x311bff('0xbf6')+_0x366b14[_0x311bff('0x24a9')]:_0x311bff('0x79d'),'msg':_0x366b14[_0x311bff('0x5a5')]?JSON[_0x311bff('0x258a')](_0x366b14['data']):_0x366b14[_0x311bff('0x1ff0')]()});});function _0x4613c3(_0x587954,_0x34cd18){const _0x14904f=_0x187f2d;_0x47b52f['show']({'controller':_0x14904f('0x1950'),'controllerAs':'vm','templateUrl':_0x14561f,'parent':angular[_0x14904f('0x1fcc')](_0x4088f2['body']),'targetEvent':_0x34cd18,'clickOutsideToClose':!![],'locals':{'voicePrefix':_0x587954,'voicePrefixes':_0x448fe8['voicePrefixes'][_0x14904f('0xf5d')],'license':_0x448fe8['license'],'setting':null,'crudPermissions':_0x448fe8[_0x14904f('0x1134')]}});}function _0xd36329(_0x414bc4,_0x29ce95){const _0x3f135d=_0x187f2d;_0x47b52f[_0x3f135d('0x1d4')]({'controller':_0x3f135d('0x1473'),'controllerAs':'vm','templateUrl':_0x3f4cba,'parent':angular['element'](_0x4088f2['body']),'targetEvent':_0x29ce95,'clickOutsideToClose':!![],'locals':{'voicePrefix':_0x414bc4,'voicePrefixes':_0x448fe8['voicePrefixes']?_0x448fe8[_0x3f135d('0x173')]['rows']:[],'crudPermissions':_0x448fe8['crudPermissions'],'realtime':![]}});}function _0xc28cf1(_0x28c195,_0x5f0326){const _0x1ead86=_0x187f2d,_0x52e43e=_0x47b52f[_0x1ead86('0x1c6f')]()[_0x1ead86('0xf28')](_0x1ead86('0x1b01')+_0x2e3ca0()[_0x1ead86('0x1e03')](_0x1ead86('0x110a'))+'?')['htmlContent'](_0x1ead86('0xed5')+(_0x28c195[_0x1ead86('0x60a')]||_0x1ead86('0x110a'))+_0x1ead86('0x20f1')+_0x1ead86('0x1ee7'))[_0x1ead86('0x1040')](_0x1ead86('0x2039'))[_0x1ead86('0xe42')](_0x5f0326)['ok']('OK')[_0x1ead86('0x19fb')](_0x1ead86('0x16b8'));_0x47b52f[_0x1ead86('0x1d4')](_0x52e43e)[_0x1ead86('0x683')](function(){_0x54b743(_0x28c195);},function(){const _0x1ab24d=_0x1ead86;console['log'](_0x1ab24d('0x16b8'));});}let _0x1f7431=!![],_0x8250b4=0x1;_0x1408d1[_0x187f2d('0x186d')](_0x187f2d('0x1e1d'),function(_0x9ed3f7,_0x28ca16){const _0x4ecd1c=_0x187f2d;_0x1f7431?_0x316f04(function(){_0x1f7431=![];}):(!_0x28ca16&&(_0x8250b4=_0x448fe8[_0x4ecd1c('0x23a2')][_0x4ecd1c('0xdf8')]),_0x9ed3f7!==_0x28ca16&&(_0x448fe8['query'][_0x4ecd1c('0xdf8')]=0x1),!_0x9ed3f7&&(_0x448fe8[_0x4ecd1c('0x23a2')][_0x4ecd1c('0xdf8')]=_0x8250b4),_0x448fe8[_0x4ecd1c('0xa64')]());});function _0x5d1d0a(_0x509dd2){const _0x4e3ab3=_0x187f2d;_0x448fe8[_0x4e3ab3('0x173')]=_0x509dd2||{'count':0x0,'rows':[]};}function _0x3942a3(){const _0x24fdd8=_0x187f2d;_0x448fe8['query'][_0x24fdd8('0x1cc8')]=(_0x448fe8[_0x24fdd8('0x23a2')][_0x24fdd8('0xdf8')]-0x1)*_0x448fe8[_0x24fdd8('0x23a2')][_0x24fdd8('0x6f0')],_0x4dca80[_0x24fdd8('0xca1')](_0x24fdd8('0x20c2'))?_0x448fe8[_0x24fdd8('0x1883')]=_0x243c21['voicePrefix']['get'](_0x448fe8['query'],_0x5d1d0a)['$promise']:(_0x448fe8['query']['id']=_0x448fe8[_0x24fdd8('0x2a')]['id'],_0x448fe8[_0x24fdd8('0x23a2')][_0x24fdd8('0x1aa')]='VoicePrefixes',_0x448fe8[_0x24fdd8('0x1883')]=_0x243c21[_0x24fdd8('0x2a')][_0x24fdd8('0x241d')](_0x448fe8['query'],_0x5d1d0a)[_0x24fdd8('0xe53')]);}function _0x77793b(_0x3382fc,_0xf4be91){const _0x1e6239=_0x187f2d;_0x47b52f[_0x1e6239('0x1d4')]({'controller':_0x1e6239('0x1950'),'controllerAs':'vm','templateUrl':_0x14561f,'parent':angular[_0x1e6239('0x1fcc')](_0x4088f2[_0x1e6239('0x18e5')]),'targetEvent':_0x3382fc,'clickOutsideToClose':!![],'locals':{'voicePrefix':_0xf4be91,'voicePrefixes':_0x448fe8[_0x1e6239('0x173')][_0x1e6239('0xf5d')],'license':_0x448fe8[_0x1e6239('0xace')],'setting':_0x448fe8[_0x1e6239('0x260a')],'crudPermissions':_0x448fe8[_0x1e6239('0x1134')]}});}function _0x54b743(_0xe8987c){const _0x4f93ff=_0x187f2d;_0x243c21['voicePrefix'][_0x4f93ff('0xd7e')]({'id':_0xe8987c['id']})[_0x4f93ff('0xe53')][_0x4f93ff('0x683')](function(){const _0x34f16f=_0x4f93ff;_0x2e3ca0()[_0x34f16f('0x3ec')](_0x448fe8[_0x34f16f('0x173')][_0x34f16f('0xf5d')],{'id':_0xe8987c['id']}),_0x448fe8['voicePrefixes'][_0x34f16f('0x50d')]-=0x1,!_0x448fe8[_0x34f16f('0x173')]['rows']['length']&&_0x448fe8[_0x34f16f('0xa64')](),_0x321ce2[_0x34f16f('0x53')]({'title':_0x2e3ca0()['startCase'](_0x34f16f('0x110a'))+_0x34f16f('0xbfc'),'msg':_0xe8987c['name']?_0xe8987c['name']+_0x34f16f('0x194d'):''});})[_0x4f93ff('0x130a')](function(_0xf8316c){const _0x5f1686=_0x4f93ff;if(_0xf8316c['data']&&_0xf8316c[_0x5f1686('0x5a5')][_0x5f1686('0x17f')]&&_0xf8316c['data'][_0x5f1686('0x17f')][_0x5f1686('0x1564')]){_0x448fe8[_0x5f1686('0x17f')]=_0xf8316c[_0x5f1686('0x5a5')][_0x5f1686('0x17f')]||[{'message':_0xf8316c[_0x5f1686('0x1ff0')](),'type':_0x5f1686('0x1ea1')}];for(let _0x1c8fe9=0x0;_0x1c8fe9<_0xf8316c[_0x5f1686('0x5a5')][_0x5f1686('0x17f')][_0x5f1686('0x1564')];_0x1c8fe9++){_0x321ce2[_0x5f1686('0x52a')]({'title':_0xf8316c[_0x5f1686('0x5a5')]['errors'][_0x1c8fe9]['type'],'msg':_0xf8316c[_0x5f1686('0x5a5')][_0x5f1686('0x17f')][_0x1c8fe9][_0x5f1686('0x8c2')]});}}else _0x321ce2[_0x5f1686('0x52a')]({'title':_0xf8316c[_0x5f1686('0x13ee')]?_0x5f1686('0x2168')+_0xf8316c[_0x5f1686('0x13ee')]+_0x5f1686('0xbf6')+_0xf8316c[_0x5f1686('0x24a9')]:'SYSTEM:DELETEvoicePrefix','msg':_0xf8316c[_0x5f1686('0x5a5')]?JSON['stringify'](_0xf8316c[_0x5f1686('0x5a5')][_0x5f1686('0x8c2')]):_0xf8316c['message']||_0xf8316c['toString']()});});}function _0x23e9c8(){const _0x4d56e0=_0x187f2d,_0xe7d5e4=angular[_0x4d56e0('0x1a86')](_0x448fe8[_0x4d56e0('0xa3a')]);return _0x448fe8[_0x4d56e0('0xa3a')]=[],_0xe7d5e4;}function _0x38110a(_0x49dd57){const _0x1ba171=_0x187f2d,_0xc0bf3e=_0x47b52f['confirm']()[_0x1ba171('0xf28')](_0x1ba171('0x1165'))[_0x1ba171('0x26e3')](_0x1ba171('0xed5')+_0x448fe8[_0x1ba171('0xa3a')]['length']+_0x1ba171('0x93c')+'\x20will\x20be\x20deleted.')[_0x1ba171('0x1040')]('delete\x20voicePrefixs')['targetEvent'](_0x49dd57)['ok']('OK')['cancel'](_0x1ba171('0x16b8'));_0x47b52f[_0x1ba171('0x1d4')](_0xc0bf3e)[_0x1ba171('0x683')](function(){const _0x5c0b32=_0x1ba171;_0x448fe8['selectedVoicePrefixes'][_0x5c0b32('0x1299')](function(_0x14429f){_0x54b743(_0x14429f);}),_0x448fe8['selectedVoicePrefixes']=[];});}function _0xa90533(){const _0x37263c=_0x187f2d;_0x448fe8[_0x37263c('0xa3a')]=[];}function _0x5bf122(){const _0x31667d=_0x187f2d;_0x448fe8['selectedVoicePrefixes']=_0x448fe8['voicePrefixes'][_0x31667d('0xf5d')];}}const _0x1c0ef2=_0x531f6a;_0xc03c18['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty','voiceQueues',_0x189033('0x204c'),'api','Auth',_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0xc03c18(_0x4374d8,_0x5b4d37,_0x33293e,_0x3a1984,_0x383ce7,_0x5a80b1,_0x1238a7,_0x1140ce,_0x192596,_0x4ea73c,_0x33151b,_0x5f4a25,_0x38415f,_0xaefd4){const _0x5dfdf6=_0x189033,_0x5efe81=this;_0x5efe81['currentUser']=_0x33151b[_0x5dfdf6('0x20b2')](),_0x5efe81[_0x5dfdf6('0x17f')]=[],_0x5efe81[_0x5dfdf6('0x260a')]=_0x38415f,_0x5efe81[_0x5dfdf6('0xace')]=_0x5f4a25,_0x5efe81['crudPermissions']=_0xaefd4,_0x5efe81[_0x5dfdf6('0x258d')]={},_0x5efe81[_0x5dfdf6('0x19b2')]=_0x5efe81[_0x5dfdf6('0x260a')]&&_0x5efe81[_0x5dfdf6('0x260a')][_0x5dfdf6('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5efe81[_0x5dfdf6('0xf28')]=_0x5dfdf6('0x157e'),_0x5efe81['voiceQueue']=angular[_0x5dfdf6('0x1a86')](_0x192596),_0x5efe81[_0x5dfdf6('0x426')]=_0x1140ce,_0x5efe81[_0x5dfdf6('0x26c4')]=![];!_0x5efe81['voiceQueue']&&(_0x5efe81[_0x5dfdf6('0x204c')]={'type':_0x5dfdf6('0x1535'),'strategy':_0x5dfdf6('0x184e'),'timeout':0xf,'retry':0x2,'random_periodic_announce':'no','announce_holdtime':'no','announce_position':'no','reportholdtime':'no','autopause':'no','ringinuse':'no','timeoutrestart':'no','setinterfacevar':'no','setqueuevar':'no','setqueueentryvar':'no'},_0x5efe81['title']=_0x5dfdf6('0x27dd'),_0x5efe81[_0x5dfdf6('0x26c4')]=!![]);_0x5efe81[_0x5dfdf6('0x1a63')]=_0x33785d,_0x5efe81['saveVoiceQueue']=_0x50d1e7,_0x5efe81[_0x5dfdf6('0x1f59')]=_0x7902b0,_0x5efe81['getDateFromString']=_0x56f650,_0x5efe81[_0x5dfdf6('0xf82')]=_0x22f778;function _0x33785d(){const _0x5a569e=_0x5dfdf6;_0x5efe81[_0x5a569e('0x17f')]=[],_0x4ea73c[_0x5a569e('0x204c')][_0x5a569e('0xb0a')](_0x5efe81[_0x5a569e('0x204c')])[_0x5a569e('0xe53')]['then'](function(_0x4ba605){const _0x370529=_0x5a569e;_0x5efe81[_0x370529('0x426')][_0x370529('0x1167')](_0x4ba605['toJSON']()),_0x1238a7[_0x370529('0x53')]({'title':'VoiceQueue\x20properly\x20created','msg':_0x5efe81[_0x370529('0x204c')]['name']?_0x5efe81['voiceQueue']['name']+_0x370529('0x14b5'):''}),_0x22f778(_0x4ba605);})[_0x5a569e('0x130a')](function(_0x112162){const _0x70f446=_0x5a569e;if(_0x112162[_0x70f446('0x5a5')]&&_0x112162['data'][_0x70f446('0x17f')]&&_0x112162['data']['errors'][_0x70f446('0x1564')]){_0x5efe81[_0x70f446('0x17f')]=_0x112162[_0x70f446('0x5a5')][_0x70f446('0x17f')]||[{'message':_0x112162[_0x70f446('0x1ff0')](),'type':'api.voiceQueue.save'}];for(let _0xbc5920=0x0;_0xbc5920<_0x112162['data'][_0x70f446('0x17f')][_0x70f446('0x1564')];_0xbc5920+=0x1){_0x1238a7[_0x70f446('0x52a')]({'title':_0x112162[_0x70f446('0x5a5')][_0x70f446('0x17f')][_0xbc5920][_0x70f446('0xcf0')],'msg':_0x112162[_0x70f446('0x5a5')][_0x70f446('0x17f')][_0xbc5920][_0x70f446('0x8c2')]});}}else _0x1238a7[_0x70f446('0x52a')]({'title':_0x112162['status']?_0x70f446('0x2168')+_0x112162[_0x70f446('0x13ee')]+_0x70f446('0xbf6')+_0x112162[_0x70f446('0x24a9')]:_0x70f446('0x1a5c'),'msg':_0x112162[_0x70f446('0x5a5')]?JSON[_0x70f446('0x258a')](_0x112162[_0x70f446('0x5a5')][_0x70f446('0x8c2')]):_0x112162[_0x70f446('0x1ff0')]()});});}function _0x50d1e7(){const _0x3ebe6a=_0x5dfdf6;_0x5efe81['errors']=[],_0x4ea73c[_0x3ebe6a('0x204c')][_0x3ebe6a('0x2480')]({'id':_0x5efe81[_0x3ebe6a('0x204c')]['id']},_0x5efe81['voiceQueue'])[_0x3ebe6a('0xe53')]['then'](function(_0x58c088){const _0x5ded01=_0x3ebe6a,_0x333d05=_0x2e3ca0()[_0x5ded01('0x1c07')](_0x5efe81[_0x5ded01('0x426')],{'id':_0x58c088['id']});_0x333d05&&_0x2e3ca0()[_0x5ded01('0xf22')](_0x333d05,_0x2e3ca0()[_0x5ded01('0x24d0')](_0x58c088['toJSON'](),_0x2e3ca0()[_0x5ded01('0x55e')](_0x333d05))),_0x1238a7[_0x5ded01('0x53')]({'title':_0x5ded01('0x5f6'),'msg':_0x5efe81[_0x5ded01('0x204c')][_0x5ded01('0x60a')]?_0x5efe81[_0x5ded01('0x204c')][_0x5ded01('0x60a')]+_0x5ded01('0xf59'):''}),_0x22f778(_0x58c088);})[_0x3ebe6a('0x130a')](function(_0x5cdc69){const _0x3952a5=_0x3ebe6a;if(_0x5cdc69[_0x3952a5('0x5a5')]&&_0x5cdc69[_0x3952a5('0x5a5')][_0x3952a5('0x17f')]&&_0x5cdc69[_0x3952a5('0x5a5')][_0x3952a5('0x17f')][_0x3952a5('0x1564')]){_0x5efe81[_0x3952a5('0x17f')]=_0x5cdc69[_0x3952a5('0x5a5')][_0x3952a5('0x17f')]||[{'message':_0x5cdc69['toString'](),'type':_0x3952a5('0x1bf0')}];for(let _0x409dcb=0x0;_0x409dcb<_0x5cdc69[_0x3952a5('0x5a5')][_0x3952a5('0x17f')]['length'];_0x409dcb++){_0x1238a7['error']({'title':_0x5cdc69[_0x3952a5('0x5a5')][_0x3952a5('0x17f')][_0x409dcb][_0x3952a5('0xcf0')],'msg':_0x5cdc69['data'][_0x3952a5('0x17f')][_0x409dcb][_0x3952a5('0x8c2')]});}}else _0x1238a7[_0x3952a5('0x52a')]({'title':_0x5cdc69[_0x3952a5('0x13ee')]?_0x3952a5('0x2168')+_0x5cdc69[_0x3952a5('0x13ee')]+'\x20-\x20'+_0x5cdc69['statusText']:_0x3952a5('0x1bf0'),'msg':_0x5cdc69['data']?JSON['stringify'](_0x5cdc69[_0x3952a5('0x5a5')]['message']):_0x5cdc69[_0x3952a5('0x1ff0')]()});});}function _0x7902b0(_0x3e6def){const _0xf93344=_0x5dfdf6;_0x5efe81[_0xf93344('0x17f')]=[];const _0x2ab71f=_0x3a1984['confirm']()[_0xf93344('0xf28')](_0xf93344('0x4d'))[_0xf93344('0xa6a')](_0xf93344('0x83c'))[_0xf93344('0x1040')]('Delete\x20VoiceQueue')['ok'](_0xf93344('0x2307'))[_0xf93344('0x19fb')]('Cancel')[_0xf93344('0xe42')](_0x3e6def);_0x3a1984[_0xf93344('0x1d4')](_0x2ab71f)[_0xf93344('0x683')](function(){const _0x3e7dba=_0xf93344;_0x4ea73c[_0x3e7dba('0x204c')][_0x3e7dba('0xd7e')]({'id':_0x5efe81[_0x3e7dba('0x204c')]['id']})['$promise']['then'](function(){const _0x5b225e=_0x3e7dba;_0x2e3ca0()[_0x5b225e('0x3ec')](_0x5efe81[_0x5b225e('0x426')],{'id':_0x5efe81[_0x5b225e('0x204c')]['id']}),_0x1238a7[_0x5b225e('0x53')]({'title':_0x5b225e('0xd1e'),'msg':(_0x5efe81[_0x5b225e('0x204c')][_0x5b225e('0x60a')]||_0x5b225e('0x204c'))+_0x5b225e('0x194d')}),_0x22f778(_0x5efe81[_0x5b225e('0x204c')]);})[_0x3e7dba('0x130a')](function(_0x2a5300){const _0x41cde3=_0x3e7dba;if(_0x2a5300[_0x41cde3('0x5a5')]&&_0x2a5300[_0x41cde3('0x5a5')][_0x41cde3('0x17f')]&&_0x2a5300[_0x41cde3('0x5a5')]['errors']['length']){_0x5efe81[_0x41cde3('0x17f')]=_0x2a5300['data'][_0x41cde3('0x17f')]||[{'message':_0x2a5300[_0x41cde3('0x1ff0')](),'type':_0x41cde3('0xd38')}];for(let _0x4b7fd2=0x0;_0x4b7fd2<_0x2a5300[_0x41cde3('0x5a5')]['errors'][_0x41cde3('0x1564')];_0x4b7fd2++){_0x1238a7['error']({'title':_0x2a5300['data'][_0x41cde3('0x17f')][_0x4b7fd2][_0x41cde3('0xcf0')],'msg':_0x2a5300[_0x41cde3('0x5a5')]['errors'][_0x4b7fd2][_0x41cde3('0x8c2')]});}}else _0x1238a7['error']({'title':_0x2a5300[_0x41cde3('0x13ee')]?_0x41cde3('0x2168')+_0x2a5300[_0x41cde3('0x13ee')]+_0x41cde3('0xbf6')+_0x2a5300[_0x41cde3('0x24a9')]:'api.voiceQueue.delete','msg':_0x2a5300[_0x41cde3('0x5a5')]?JSON[_0x41cde3('0x258a')](_0x2a5300[_0x41cde3('0x5a5')][_0x41cde3('0x8c2')]):_0x2a5300[_0x41cde3('0x8c2')]||_0x2a5300[_0x41cde3('0x1ff0')]()});});},function(){});}function _0x56f650(_0x88f040){return _0x88f040===null?undefined:new Date(_0x88f040);}function _0x22f778(_0x3fd081){const _0x16e4cf=_0x5dfdf6;_0x3a1984[_0x16e4cf('0x1715')](_0x3fd081);}}const _0x1bc96f=_0xc03c18;_0x40d866[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x56b'),_0x189033('0x204c'),_0x189033('0x426'),_0x189033('0x2c9'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x40d866(_0x410974,_0x65488e,_0x54bffe,_0x2a7712,_0x302e77,_0x1ddd61,_0x437d42,_0x1c5da5,_0x2d8ce3,_0x503e9c){const _0x594e09=_0x189033,_0x440c59=this;_0x440c59[_0x594e09('0x11ed')]=_0x2d8ce3[_0x594e09('0x20b2')](),_0x440c59[_0x594e09('0x204c')]=_0x302e77,_0x440c59[_0x594e09('0x1134')]=_0x503e9c,_0x440c59['penalty']=0x0,_0x440c59[_0x594e09('0x2c9')]=_0x437d42,_0x440c59['items']=[],_0x440c59[_0x594e09('0x1c47')]=[],_0x440c59[_0x594e09('0x1378')]=[],_0x440c59[_0x594e09('0x125e')]=[],_0x440c59[_0x594e09('0x23a7')]=[],_0x440c59[_0x594e09('0x2106')]=![],_0x440c59[_0x594e09('0x1dd2')]=_0x372ddb,_0x440c59[_0x594e09('0xa5f')]=_0x416eb6,_0x440c59[_0x594e09('0xf82')]=_0x4dd983,_0x440c59[_0x594e09('0x169f')]={'readOnly':!_0x440c59['crudPermissions'][_0x594e09('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x594e09('0x60a'),'line1':_0x594e09('0x11bc'),'line2':[_0x594e09('0x60a'),_0x594e09('0x1d43')],'line3':_0x594e09('0x1e2a'),'labelAll':_0x1c5da5['instant'](_0x594e09('0xef3')),'labelSelected':_0x1c5da5[_0x594e09('0x2728')](_0x594e09('0x1787')),'transferCallback':function(_0xef70b6,_0x4643f4){const _0x5b7294=_0x594e09;_0x4643f4?_0xef70b6[_0x5b7294('0x1299')](function(_0x161f12){const _0x1bf63d=_0x5b7294;_0x161f12[_0x1bf63d('0x1e2a')]=undefined;}):_0xef70b6[_0x5b7294('0x1299')](function(_0x418e37){const _0x56ea92=_0x5b7294;_0x418e37[_0x56ea92('0x1e2a')]='penalty\x20'+_0x440c59[_0x56ea92('0x1e2a')];});const _0x48b68f=_0x2e3ca0()[_0x5b7294('0x162c')](_0x440c59[_0x5b7294('0x23a7')],_0x440c59[_0x5b7294('0x1378')],function(_0x342976,_0x567fd4){const _0x1174a9=_0x5b7294;return _0x342976['id']===_0x567fd4['id']&&_0x342976[_0x1174a9('0x1e2a')]===_0x567fd4['penalty'];});_0x440c59['pendingChanges']=_0x2e3ca0()[_0x5b7294('0x173f')](_0x48b68f)?![]:!![];}};function _0x372ddb(){const _0x14bca0=_0x594e09;return _0x2d8ce3[_0x14bca0('0xca1')](_0x14bca0('0x20c2'))?_0x3dbd33()[_0x14bca0('0x130a')](function(_0x2d08d4){const _0xecb03c=_0x14bca0;_0x54bffe['error']({'title':_0x2d08d4[_0xecb03c('0x13ee')]?_0xecb03c('0x2168')+_0x2d08d4['status']+_0xecb03c('0xbf6')+_0x2d08d4[_0xecb03c('0x24a9')]:_0xecb03c('0x144f'),'msg':_0x2d08d4[_0xecb03c('0x13ee')]?JSON[_0xecb03c('0x258a')](_0x2d08d4[_0xecb03c('0x5a5')]):_0x2d08d4[_0xecb03c('0x1ff0')]()});}):_0x492a99()['then'](function(_0x4386a0){const _0x8f85a3=_0x14bca0;return _0x440c59[_0x8f85a3('0x1aa')]=_0x4386a0,_0x3dbd33();})['catch'](function(_0x462ed5){const _0x405a1b=_0x14bca0;_0x54bffe[_0x405a1b('0x52a')]({'title':_0x462ed5[_0x405a1b('0x13ee')]?_0x405a1b('0x2168')+_0x462ed5[_0x405a1b('0x13ee')]+_0x405a1b('0xbf6')+_0x462ed5[_0x405a1b('0x24a9')]:_0x405a1b('0x144f'),'msg':_0x462ed5[_0x405a1b('0x13ee')]?JSON[_0x405a1b('0x258a')](_0x462ed5[_0x405a1b('0x5a5')]):_0x462ed5[_0x405a1b('0x1ff0')]()});});}function _0x492a99(){return _0x65488e(function(_0x194959,_0x2c018e){const _0x3e8703=a0_0x4e0a;_0x2a7712['userProfileSection']['get']({'userProfileId':_0x440c59['currentUser']['userProfileId'],'name':_0x3e8703('0x1bc0')})[_0x3e8703('0xe53')]['then'](function(_0x24363b){const _0x42f505=_0x3e8703,_0x3c32a4=_0x24363b&&_0x24363b[_0x42f505('0xf5d')]?_0x24363b[_0x42f505('0xf5d')][0x0]:null;_0x194959(_0x3c32a4);})[_0x3e8703('0x130a')](function(_0x5b92e5){_0x2c018e(_0x5b92e5);});});}function _0x3dbd33(){return _0x65488e(function(_0x2d4ba9,_0x52304c){const _0x254486=a0_0x4e0a;return _0x473702()[_0x254486('0x683')](function(_0x43c19f){const _0x2121da=_0x254486;return _0x440c59['items']=_0x43c19f['rows']?_0x43c19f[_0x2121da('0xf5d')]:[],_0x2d8ce3[_0x2121da('0xca1')](_0x2121da('0x20c2'))?_0x43c19f:_0x440c59['section']?_0x440c59[_0x2121da('0x1aa')][_0x2121da('0x170')]?_0x43c19f:_0xfe5d82():null;})['then'](function(_0x45ce89){const _0x1380d2=_0x254486,_0x2472d3=_0x45ce89&&_0x45ce89[_0x1380d2('0xf5d')]?_0x45ce89[_0x1380d2('0xf5d')]:[];return _0x440c59[_0x1380d2('0x1c47')]=_0x2e3ca0()['map'](_0x2472d3,function(_0x502b9d){const _0x198641=_0x1380d2;return _0x2e3ca0()[_0x198641('0x1c07')](_0x440c59[_0x198641('0x1996')],{'id':_0x2d8ce3[_0x198641('0xca1')]('admin')||_0x440c59[_0x198641('0x1aa')][_0x198641('0x170')]?_0x502b9d['id']:_0x502b9d['resourceId']});}),_0x440c59[_0x1380d2('0x125e')]=angular['copy'](_0x440c59[_0x1380d2('0x1c47')]),_0x440c59['items'][_0x1380d2('0x1299')](function(_0x1d8d39){const _0x1e5b1b=_0x1380d2,_0x13f7f5=_0x2e3ca0()[_0x1e5b1b('0x1c07')](_0x440c59[_0x1e5b1b('0x1c47')],{'id':_0x1d8d39['id']});_0x2d8ce3[_0x1e5b1b('0xca1')](_0x1e5b1b('0x20c2'))?_0x1d8d39['isValid']=!![]:_0x1d8d39['isValid']=typeof _0x13f7f5!==_0x1e5b1b('0x1867')?!![]:![];}),_0xc2135f();})[_0x254486('0x683')](function(_0x5591da){const _0x238403=_0x254486,_0x1d657b=_0x5591da&&_0x5591da['rows']?_0x5591da[_0x238403('0xf5d')]:[];_0x440c59['selectedItems']=_0x2e3ca0()[_0x238403('0x386')](_0x1d657b,function(_0x191e0e){const _0x5a952b=_0x238403,_0x2cb5eb=_0x2e3ca0()[_0x5a952b('0x1c07')](_0x440c59[_0x5a952b('0x1996')],{'id':_0x191e0e['id']});return _0x2cb5eb['penalty']=_0x191e0e[_0x5a952b('0x1901')]?_0x5a952b('0x23d0')+_0x191e0e[_0x5a952b('0x1901')][_0x5a952b('0x1e2a')]:'',_0x2cb5eb[_0x5a952b('0x1d43')]=typeof _0x191e0e[_0x5a952b('0x1d43')]!==_0x5a952b('0x1867')?'<'+_0x191e0e['internal']+'>':'',_0x2cb5eb;}),_0x440c59['startingSelectedItems']=angular[_0x238403('0x1a86')](_0x440c59[_0x238403('0x1378')]),_0x440c59[_0x238403('0x169f')][_0x238403('0x1378')]=_0x440c59[_0x238403('0x1378')],_0x440c59['dualMultiselectOptions'][_0x238403('0x1996')]=_0x2e3ca0()[_0x238403('0x461')](_0x440c59[_0x238403('0x1c47')],_0x440c59[_0x238403('0x169f')][_0x238403('0x1378')],'id'),_0x2d4ba9();})[_0x254486('0x130a')](function(_0x3ec3fa){_0x52304c(_0x3ec3fa);});});}function _0xfe5d82(){return _0x65488e(function(_0x614554,_0xbc9e7b){const _0x520e3c=a0_0x4e0a;return _0x2a7712['userProfileResource'][_0x520e3c('0x1e6e')]({'sectionId':_0x440c59[_0x520e3c('0x1aa')]['id'],'nolimit':!![]})[_0x520e3c('0xe53')]['then'](function(_0x53e7a7){_0x614554(_0x53e7a7);})[_0x520e3c('0x130a')](function(_0x3fd4c1){_0xbc9e7b(_0x3fd4c1);});});}function _0xc2135f(){return _0x65488e(function(_0x1f9679,_0x2b228f){const _0x161f95=a0_0x4e0a;return _0x2a7712['voiceQueue'][_0x161f95('0x8e7')]({'id':_0x440c59[_0x161f95('0x204c')]['id'],'fields':_0x161f95('0x72b'),'nolimit':!![],'role':_0x161f95('0x2327')})[_0x161f95('0xe53')]['then'](function(_0x25b115){_0x1f9679(_0x25b115);})[_0x161f95('0x130a')](function(_0x4c834f){_0x2b228f(_0x4c834f);});});}function _0x473702(){return _0x65488e(function(_0x33ba57,_0x400ac6){const _0x180b2=a0_0x4e0a;return _0x2a7712[_0x180b2('0xc96')][_0x180b2('0x1e6e')]({'fields':_0x180b2('0x72b'),'nolimit':!![],'role':_0x180b2('0x2327')})['$promise'][_0x180b2('0x683')](function(_0x288ffd){_0x33ba57(_0x288ffd);})[_0x180b2('0x130a')](function(_0x54d3dc){_0x400ac6(_0x54d3dc);});});}function _0x1d606a(_0x292cd3){return _0x65488e(function(_0x42b645,_0x2df144){const _0x5ce453=a0_0x4e0a;if(_0x2e3ca0()['isEmpty'](_0x292cd3))_0x42b645();else{const _0x23b56e=[],_0x16ca33=_0x2e3ca0()['groupBy'](_0x292cd3,_0x5ce453('0x1e2a'));for(let _0x57da08=0x0;_0x57da08'+(_0xe3fc37['name']||_0x8d0dba('0x204c'))+_0x8d0dba('0x20f1')+'\x20will\x20be\x20deleted.')[_0x8d0dba('0x1040')](_0x8d0dba('0x249d'))[_0x8d0dba('0xe42')](_0x446a0b)['ok']('OK')[_0x8d0dba('0x19fb')](_0x8d0dba('0x16b8'));_0x5d1764[_0x8d0dba('0x1d4')](_0x20ef21)[_0x8d0dba('0x683')](function(){_0x323c22(_0xe3fc37);},function(){const _0x51717a=_0x8d0dba;console[_0x51717a('0x1b2b')](_0x51717a('0x16b8'));});}function _0x12ec57(){const _0x3017a1=_0x927da9;if(_0x4b12bd[_0x3017a1('0xca1')](_0x3017a1('0x20c2')))_0x305acd['go'](_0x3017a1('0x1591'),{});else return _0xd51da2[_0x3017a1('0x22df')][_0x3017a1('0x1e6e')]({'userProfileId':_0x4b12bd[_0x3017a1('0x20b2')]()['userProfileId'],'sectionId':0x19b})[_0x3017a1('0xe53')][_0x3017a1('0x683')](function(_0x423fea){const _0x4f7f94=_0x3017a1,_0x3263aa=_0x423fea&&_0x423fea[_0x4f7f94('0xf5d')]?_0x423fea[_0x4f7f94('0xf5d')][0x0]:null;_0x3263aa&&_0x3263aa['enabled']?_0x305acd['go']('app.voice.realtime.queues',{}):_0x1033f0[_0x4f7f94('0x2289')]({'title':_0x2d49b2[_0x4f7f94('0x2728')](_0x4f7f94('0x213e')),'msg':_0x2d49b2['instant'](_0x4f7f94('0xdba'))});})[_0x3017a1('0x130a')](function(_0x527c00){const _0x242d04=_0x3017a1;_0x1033f0['error']({'title':_0x527c00[_0x242d04('0x13ee')]?'API:'+_0x527c00[_0x242d04('0x13ee')]+_0x242d04('0xbf6')+_0x527c00[_0x242d04('0x24a9')]:'USERPROFILE:GET_SECTION','msg':_0x527c00['status']?JSON[_0x242d04('0x258a')](_0x527c00[_0x242d04('0x5a5')]):_0x527c00[_0x242d04('0x1ff0')]()});});}let _0x4e13bf=!![],_0x2123e4=0x1;_0x24a323[_0x927da9('0x186d')](_0x927da9('0x1e1d'),function(_0x2d066e,_0x10d625){const _0x50b978=_0x927da9;_0x4e13bf?_0x42bb07(function(){_0x4e13bf=![];}):(!_0x10d625&&(_0x2123e4=_0x392a7c[_0x50b978('0x23a2')][_0x50b978('0xdf8')]),_0x2d066e!==_0x10d625&&(_0x392a7c[_0x50b978('0x23a2')][_0x50b978('0xdf8')]=0x1),!_0x2d066e&&(_0x392a7c[_0x50b978('0x23a2')][_0x50b978('0xdf8')]=_0x2123e4),_0x392a7c[_0x50b978('0x1713')]());});function _0x236886(_0x2e3e3c){_0x392a7c['voiceQueues']=_0x2e3e3c||{'count':0x0,'rows':[]};}function _0x69ccb2(){const _0x449113=_0x927da9;_0x392a7c[_0x449113('0x23a2')][_0x449113('0x1cc8')]=(_0x392a7c[_0x449113('0x23a2')][_0x449113('0xdf8')]-0x1)*_0x392a7c[_0x449113('0x23a2')][_0x449113('0x6f0')],_0x4b12bd[_0x449113('0xca1')](_0x449113('0x20c2'))?_0x392a7c[_0x449113('0x1883')]=_0xd51da2[_0x449113('0x204c')]['get'](_0x392a7c[_0x449113('0x23a2')],_0x236886)[_0x449113('0xe53')]:(_0x392a7c[_0x449113('0x23a2')]['id']=_0x392a7c[_0x449113('0x2a')]['id'],_0x392a7c['query'][_0x449113('0x1aa')]=_0x449113('0x88d'),_0x392a7c[_0x449113('0x1883')]=_0xd51da2[_0x449113('0x2a')]['getResources'](_0x392a7c[_0x449113('0x23a2')],_0x236886)[_0x449113('0xe53')]);}function _0x49d6b1(_0x498e35,_0xa32110){const _0x1d7e2a=_0x927da9;_0x5d1764[_0x1d7e2a('0x1d4')]({'controller':_0x1d7e2a('0x2306'),'controllerAs':'vm','templateUrl':_0x44ed12,'parent':angular[_0x1d7e2a('0x1fcc')](_0x1ec5a3[_0x1d7e2a('0x18e5')]),'targetEvent':_0x498e35,'clickOutsideToClose':!![],'locals':{'voiceQueue':_0xa32110,'voiceQueues':_0x392a7c[_0x1d7e2a('0x426')][_0x1d7e2a('0xf5d')],'license':_0x392a7c[_0x1d7e2a('0xace')],'setting':_0x392a7c[_0x1d7e2a('0x260a')],'crudPermissions':_0x392a7c[_0x1d7e2a('0x1134')]}});}function _0x323c22(_0x5fe264){const _0x361b4f=_0x927da9;_0xd51da2[_0x361b4f('0x204c')]['delete']({'id':_0x5fe264['id']})[_0x361b4f('0xe53')][_0x361b4f('0x683')](function(){const _0x4481bc=_0x361b4f;_0x2e3ca0()[_0x4481bc('0x3ec')](_0x392a7c['voiceQueues'][_0x4481bc('0xf5d')],{'id':_0x5fe264['id']}),_0x392a7c[_0x4481bc('0x426')][_0x4481bc('0x50d')]-=0x1,!_0x392a7c[_0x4481bc('0x426')][_0x4481bc('0xf5d')][_0x4481bc('0x1564')]&&_0x392a7c[_0x4481bc('0x1713')](),_0x1033f0['success']({'title':_0x2e3ca0()[_0x4481bc('0x1e03')]('VoiceQueue')+_0x4481bc('0xbfc'),'msg':_0x5fe264['name']?_0x5fe264['name']+_0x4481bc('0x194d'):''});})[_0x361b4f('0x130a')](function(_0x4b5692){const _0x3cb1ee=_0x361b4f;if(_0x4b5692[_0x3cb1ee('0x5a5')]&&_0x4b5692[_0x3cb1ee('0x5a5')][_0x3cb1ee('0x17f')]&&_0x4b5692[_0x3cb1ee('0x5a5')][_0x3cb1ee('0x17f')][_0x3cb1ee('0x1564')]){_0x392a7c[_0x3cb1ee('0x17f')]=_0x4b5692[_0x3cb1ee('0x5a5')][_0x3cb1ee('0x17f')]||[{'message':_0x4b5692[_0x3cb1ee('0x1ff0')](),'type':_0x3cb1ee('0x1674')}];for(let _0x2c34d5=0x0;_0x2c34d5<_0x4b5692[_0x3cb1ee('0x5a5')]['errors'][_0x3cb1ee('0x1564')];_0x2c34d5++){_0x1033f0[_0x3cb1ee('0x52a')]({'title':_0x4b5692[_0x3cb1ee('0x5a5')]['errors'][_0x2c34d5]['type'],'msg':_0x4b5692['data']['errors'][_0x2c34d5]['message']});}}else _0x1033f0[_0x3cb1ee('0x52a')]({'title':_0x4b5692[_0x3cb1ee('0x13ee')]?'API:'+_0x4b5692[_0x3cb1ee('0x13ee')]+'\x20-\x20'+_0x4b5692[_0x3cb1ee('0x24a9')]:'SYSTEM:DELETEvoiceQueue','msg':_0x4b5692[_0x3cb1ee('0x5a5')]?JSON[_0x3cb1ee('0x258a')](_0x4b5692['data'][_0x3cb1ee('0x8c2')]):_0x4b5692[_0x3cb1ee('0x8c2')]||_0x4b5692[_0x3cb1ee('0x1ff0')]()});});}function _0x5d9a9a(){const _0x4cd594=_0x927da9,_0x21fbd4=angular[_0x4cd594('0x1a86')](_0x392a7c[_0x4cd594('0x1ca6')]);return _0x392a7c[_0x4cd594('0x1ca6')]=[],_0x21fbd4;}function _0x50f270(_0x518061){const _0xad1fbc=_0x927da9,_0x557525=_0x5d1764[_0xad1fbc('0x1c6f')]()[_0xad1fbc('0xf28')](_0xad1fbc('0xc21'))[_0xad1fbc('0x26e3')](_0xad1fbc('0xed5')+_0x392a7c[_0xad1fbc('0x1ca6')][_0xad1fbc('0x1564')]+_0xad1fbc('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0xad1fbc('0x281'))[_0xad1fbc('0xe42')](_0x518061)['ok']('OK')[_0xad1fbc('0x19fb')](_0xad1fbc('0x16b8'));_0x5d1764[_0xad1fbc('0x1d4')](_0x557525)[_0xad1fbc('0x683')](function(){const _0x498f13=_0xad1fbc;_0x392a7c[_0x498f13('0x1ca6')]['forEach'](function(_0x348a0a){_0x323c22(_0x348a0a);}),_0x392a7c[_0x498f13('0x1ca6')]=[];});}function _0x1ed404(){const _0x379e83=_0x927da9;_0x392a7c[_0x379e83('0x1ca6')]=[];}function _0x3dfa8b(){const _0x5c4bc6=_0x927da9;_0x392a7c[_0x5c4bc6('0x1ca6')]=_0x392a7c['voiceQueues'][_0x5c4bc6('0xf5d')];}}const _0x1a3fbd=_0xf93cd1;_0x57912c['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x3ac'),_0x189033('0x52f'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x57912c(_0x36eff5,_0x44e7eb,_0x5da9d8,_0x3a05d7,_0x2b28d4,_0x40d1dd,_0x3bff71,_0x5e7ce2,_0x281718,_0x119666,_0x41c551,_0x5dce0a,_0x15a3e8,_0x25c548){const _0x18efc5=_0x189033,_0x562b3f=this;_0x562b3f['currentUser']=_0x41c551[_0x18efc5('0x20b2')](),_0x562b3f[_0x18efc5('0x17f')]=[],_0x562b3f[_0x18efc5('0x260a')]=_0x15a3e8,_0x562b3f[_0x18efc5('0xace')]=_0x5dce0a,_0x562b3f[_0x18efc5('0x1134')]=_0x25c548,_0x562b3f[_0x18efc5('0x258d')]={},_0x562b3f[_0x18efc5('0x19b2')]=_0x562b3f[_0x18efc5('0x260a')]&&_0x562b3f[_0x18efc5('0x260a')][_0x18efc5('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x562b3f[_0x18efc5('0xf28')]=_0x18efc5('0x8dc'),_0x562b3f[_0x18efc5('0x52f')]=angular[_0x18efc5('0x1a86')](_0x281718),_0x562b3f[_0x18efc5('0x3ac')]=_0x5e7ce2,_0x562b3f[_0x18efc5('0x1ea9')]=![];!_0x562b3f[_0x18efc5('0x52f')]&&(_0x562b3f[_0x18efc5('0x52f')]={},_0x562b3f[_0x18efc5('0xf28')]=_0x18efc5('0x1daa'),_0x562b3f[_0x18efc5('0x1ea9')]=!![]);_0x562b3f[_0x18efc5('0x79e')]=_0xc74734,_0x562b3f[_0x18efc5('0x1f79')]=_0x4bae97,_0x562b3f[_0x18efc5('0x2093')]=_0x97df67,_0x562b3f[_0x18efc5('0x16b3')]=_0x3dd09c,_0x562b3f[_0x18efc5('0xf82')]=_0x277ca1;function _0xc74734(){const _0x1adb75=_0x18efc5;_0x562b3f[_0x1adb75('0x17f')]=[],_0x119666[_0x1adb75('0x52f')]['save'](_0x562b3f[_0x1adb75('0x52f')])['$promise'][_0x1adb75('0x683')](function(_0x14fca0){const _0x459184=_0x1adb75;_0x562b3f[_0x459184('0x3ac')]['unshift'](_0x14fca0[_0x459184('0x24e1')]()),_0x3bff71['success']({'title':'VoiceRecording\x20properly\x20created','msg':_0x562b3f[_0x459184('0x52f')][_0x459184('0x60a')]?_0x562b3f[_0x459184('0x52f')][_0x459184('0x60a')]+_0x459184('0x14b5'):''}),_0x277ca1(_0x14fca0);})[_0x1adb75('0x130a')](function(_0x9bd4f0){const _0xcd9d4a=_0x1adb75;if(_0x9bd4f0['data']&&_0x9bd4f0[_0xcd9d4a('0x5a5')][_0xcd9d4a('0x17f')]&&_0x9bd4f0[_0xcd9d4a('0x5a5')][_0xcd9d4a('0x17f')][_0xcd9d4a('0x1564')]){_0x562b3f[_0xcd9d4a('0x17f')]=_0x9bd4f0['data'][_0xcd9d4a('0x17f')]||[{'message':_0x9bd4f0[_0xcd9d4a('0x1ff0')](),'type':_0xcd9d4a('0xa25')}];for(let _0x3de103=0x0;_0x3de103<_0x9bd4f0[_0xcd9d4a('0x5a5')][_0xcd9d4a('0x17f')][_0xcd9d4a('0x1564')];_0x3de103+=0x1){_0x3bff71[_0xcd9d4a('0x52a')]({'title':_0x9bd4f0['data']['errors'][_0x3de103][_0xcd9d4a('0xcf0')],'msg':_0x9bd4f0[_0xcd9d4a('0x5a5')]['errors'][_0x3de103][_0xcd9d4a('0x8c2')]});}}else _0x3bff71[_0xcd9d4a('0x52a')]({'title':_0x9bd4f0[_0xcd9d4a('0x13ee')]?'API:'+_0x9bd4f0[_0xcd9d4a('0x13ee')]+_0xcd9d4a('0xbf6')+_0x9bd4f0[_0xcd9d4a('0x24a9')]:_0xcd9d4a('0xa25'),'msg':_0x9bd4f0['data']?JSON[_0xcd9d4a('0x258a')](_0x9bd4f0[_0xcd9d4a('0x5a5')]['message']):_0x9bd4f0[_0xcd9d4a('0x1ff0')]()});});}function _0x4bae97(){const _0x6b49d2=_0x18efc5;_0x562b3f['errors']=[],_0x119666[_0x6b49d2('0x52f')][_0x6b49d2('0x2480')]({'id':_0x562b3f[_0x6b49d2('0x52f')]['id']},_0x562b3f[_0x6b49d2('0x52f')])[_0x6b49d2('0xe53')]['then'](function(_0x269a13){const _0x3a2d51=_0x6b49d2,_0x586fca=_0x2e3ca0()[_0x3a2d51('0x1c07')](_0x562b3f[_0x3a2d51('0x3ac')],{'id':_0x269a13['id']});_0x586fca&&_0x2e3ca0()[_0x3a2d51('0xf22')](_0x586fca,_0x2e3ca0()[_0x3a2d51('0x24d0')](_0x269a13[_0x3a2d51('0x24e1')](),_0x2e3ca0()[_0x3a2d51('0x55e')](_0x586fca))),_0x3bff71['success']({'title':'VoiceRecording\x20properly\x20saved!','msg':_0x562b3f[_0x3a2d51('0x52f')][_0x3a2d51('0x60a')]?_0x562b3f[_0x3a2d51('0x52f')][_0x3a2d51('0x60a')]+_0x3a2d51('0xf59'):''}),_0x277ca1(_0x269a13);})['catch'](function(_0x5f2af1){const _0x1eb213=_0x6b49d2;if(_0x5f2af1[_0x1eb213('0x5a5')]&&_0x5f2af1['data'][_0x1eb213('0x17f')]&&_0x5f2af1[_0x1eb213('0x5a5')]['errors'][_0x1eb213('0x1564')]){_0x562b3f[_0x1eb213('0x17f')]=_0x5f2af1[_0x1eb213('0x5a5')][_0x1eb213('0x17f')]||[{'message':_0x5f2af1[_0x1eb213('0x1ff0')](),'type':_0x1eb213('0x1d03')}];for(let _0x9c4c35=0x0;_0x9c4c35<_0x5f2af1[_0x1eb213('0x5a5')][_0x1eb213('0x17f')][_0x1eb213('0x1564')];_0x9c4c35++){_0x3bff71[_0x1eb213('0x52a')]({'title':_0x5f2af1[_0x1eb213('0x5a5')][_0x1eb213('0x17f')][_0x9c4c35]['type'],'msg':_0x5f2af1[_0x1eb213('0x5a5')][_0x1eb213('0x17f')][_0x9c4c35][_0x1eb213('0x8c2')]});}}else _0x3bff71[_0x1eb213('0x52a')]({'title':_0x5f2af1[_0x1eb213('0x13ee')]?_0x1eb213('0x2168')+_0x5f2af1['status']+'\x20-\x20'+_0x5f2af1[_0x1eb213('0x24a9')]:_0x1eb213('0x1d03'),'msg':_0x5f2af1[_0x1eb213('0x5a5')]?JSON[_0x1eb213('0x258a')](_0x5f2af1[_0x1eb213('0x5a5')][_0x1eb213('0x8c2')]):_0x5f2af1[_0x1eb213('0x1ff0')]()});});}function _0x97df67(_0x32ed7c){const _0x2c527e=_0x18efc5;_0x562b3f['errors']=[];const _0x50ee03=_0x3a05d7[_0x2c527e('0x1c6f')]()['title']('Are\x20you\x20sure?')['content'](_0x2c527e('0x2404'))[_0x2c527e('0x1040')](_0x2c527e('0x14c9'))['ok']('Delete')[_0x2c527e('0x19fb')]('Cancel')[_0x2c527e('0xe42')](_0x32ed7c);_0x3a05d7[_0x2c527e('0x1d4')](_0x50ee03)['then'](function(){const _0x2fba17=_0x2c527e;_0x119666[_0x2fba17('0x52f')][_0x2fba17('0xd7e')]({'id':_0x562b3f['voiceRecording']['id']})['$promise'][_0x2fba17('0x683')](function(){const _0x12599b=_0x2fba17;_0x2e3ca0()[_0x12599b('0x3ec')](_0x562b3f[_0x12599b('0x3ac')],{'id':_0x562b3f['voiceRecording']['id']}),_0x3bff71[_0x12599b('0x53')]({'title':_0x12599b('0x11cf'),'msg':(_0x562b3f['voiceRecording'][_0x12599b('0x60a')]||'voiceRecording')+'\x20has\x20been\x20deleted!'}),_0x277ca1(_0x562b3f[_0x12599b('0x52f')]);})['catch'](function(_0x2e431a){const _0x47da3e=_0x2fba17;if(_0x2e431a[_0x47da3e('0x5a5')]&&_0x2e431a['data']['errors']&&_0x2e431a[_0x47da3e('0x5a5')][_0x47da3e('0x17f')][_0x47da3e('0x1564')]){_0x562b3f[_0x47da3e('0x17f')]=_0x2e431a[_0x47da3e('0x5a5')][_0x47da3e('0x17f')]||[{'message':_0x2e431a[_0x47da3e('0x1ff0')](),'type':_0x47da3e('0x975')}];for(let _0x1c0ffb=0x0;_0x1c0ffb<_0x2e431a[_0x47da3e('0x5a5')]['errors'][_0x47da3e('0x1564')];_0x1c0ffb++){_0x3bff71['error']({'title':_0x2e431a[_0x47da3e('0x5a5')]['errors'][_0x1c0ffb][_0x47da3e('0xcf0')],'msg':_0x2e431a[_0x47da3e('0x5a5')][_0x47da3e('0x17f')][_0x1c0ffb][_0x47da3e('0x8c2')]});}}else _0x3bff71[_0x47da3e('0x52a')]({'title':_0x2e431a['status']?_0x47da3e('0x2168')+_0x2e431a[_0x47da3e('0x13ee')]+'\x20-\x20'+_0x2e431a[_0x47da3e('0x24a9')]:'api.voiceRecording.delete','msg':_0x2e431a[_0x47da3e('0x5a5')]?JSON[_0x47da3e('0x258a')](_0x2e431a[_0x47da3e('0x5a5')]['message']):_0x2e431a[_0x47da3e('0x8c2')]||_0x2e431a[_0x47da3e('0x1ff0')]()});});},function(){});}function _0x3dd09c(_0x476aba){return _0x476aba===null?undefined:new Date(_0x476aba);}function _0x277ca1(_0x16c437){const _0x437dbd=_0x18efc5;_0x3a05d7[_0x437dbd('0x1715')](_0x16c437);}}const _0x485bac=_0x57912c;function _0x4f3b34(){const _0x142943=_0x189033,_0x484d6a=this;_0x484d6a[_0x142943('0x52f')]={},_0x484d6a[_0x142943('0x12f3')]=_0x40c4bb;function _0x40c4bb(_0x238b33){_0x484d6a['voiceRecording']=_0x238b33;}}const _0x44f6eb=_0x4f3b34;_0xf7e94[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),'api',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x52f'),_0x189033('0x22df')];function _0xf7e94(_0x14e4b7,_0xd2d4ac,_0x58a99c,_0x3266ef,_0x36afd3,_0x4dbc9c,_0x492ac0,_0x2e3d18,_0x1df02e,_0xdf98d7,_0x5adfa2,_0x418148){const _0x42625e=_0x189033,_0x16305d=this;_0x16305d[_0x42625e('0x11ed')]=_0xdf98d7[_0x42625e('0x20b2')](),_0x16305d[_0x42625e('0xace')]=_0x4dbc9c,_0x16305d[_0x42625e('0x260a')]=_0x492ac0,_0x16305d[_0x42625e('0x19b2')]=_0x16305d['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x16305d[_0x42625e('0x1224')]=_0xd2d4ac[_0x42625e('0x173e')]()+_0x42625e('0x20de')+_0xd2d4ac[_0x42625e('0x19ac')](),_0x16305d['voiceRecording']=_0x5adfa2||_0x14e4b7['params'][_0x42625e('0x52f')]||{},_0x16305d[_0x42625e('0x22df')]=_0x418148&&_0x418148[_0x42625e('0x50d')]==0x1?_0x418148['rows'][0x0]:null,_0x16305d[_0x42625e('0x1134')]=_0xdf98d7[_0x42625e('0x142a')](_0x16305d[_0x42625e('0x22df')]?_0x16305d['userProfileSection']['crudPermissions']:null),_0x16305d[_0x42625e('0x258d')]={},_0x16305d['selectedTab']=_0x14e4b7['params'][_0x42625e('0x1904')]||0x0,_0x16305d[_0x42625e('0x2430')]=_0x1df02e[_0x42625e('0x2289')],_0x16305d[_0x42625e('0x133b')]=_0x2e6189,_0x16305d[_0x42625e('0x1f79')]=_0x363c34;function _0x2e6189(){const _0x2a306d=_0x42625e;_0x14e4b7['go'](_0x2a306d('0x124f'),{},{'reload':_0x2a306d('0x124f')});}function _0x363c34(){const _0x59cff8=_0x42625e;_0x2e3d18[_0x59cff8('0x52f')]['update']({'id':_0x16305d[_0x59cff8('0x52f')]['id']},_0x16305d[_0x59cff8('0x52f')])['$promise'][_0x59cff8('0x683')](function(){const _0x2d1830=_0x59cff8;_0x1df02e['success']({'title':_0x2d1830('0x1763'),'msg':_0x16305d[_0x2d1830('0x52f')][_0x2d1830('0x60a')]?_0x16305d['voiceRecording'][_0x2d1830('0x60a')]+_0x2d1830('0x96c'):''});})[_0x59cff8('0x130a')](function(_0x2aefe6){const _0x36e8f6=_0x59cff8;_0x1df02e[_0x36e8f6('0x52a')]({'title':_0x2aefe6[_0x36e8f6('0x13ee')]?_0x36e8f6('0x2168')+_0x2aefe6['status']+_0x36e8f6('0xbf6')+_0x2aefe6[_0x36e8f6('0x24a9')]:_0x36e8f6('0x100c'),'msg':_0x2aefe6[_0x36e8f6('0x5a5')]?JSON['stringify'](_0x2aefe6['data']):_0x2aefe6['toString']()});});}}const _0x170a56=_0xf7e94,_0x4620b1=_0x180212['p']+_0x189033('0x16ca');_0x2b9219[_0x189033('0x14be')]=['$scope',_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x3ac'),_0x189033('0x2a'),'userProfileSection','api','msUtils',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x2b9219(_0x12ebc5,_0x1d0b09,_0x394e5e,_0x3226c1,_0x244d3a,_0x394499,_0x292fe1,_0x40fad6,_0x8d267,_0x332ed6,_0xbbf6d,_0x9043dd,_0x33d696,_0x3a591b,_0x1bfd9e,_0x14a7ff,_0x38937b){const _0x5e3ec1=_0x189033,_0xeb8c8a=this;_0xeb8c8a[_0x5e3ec1('0xace')]=_0x14a7ff,_0xeb8c8a[_0x5e3ec1('0x260a')]=_0x38937b,_0xeb8c8a[_0x5e3ec1('0x11ed')]=_0x1bfd9e[_0x5e3ec1('0x20b2')](),_0xeb8c8a['voiceRecordings']=_0x8d267||{'count':0x0,'rows':[]},_0xeb8c8a[_0x5e3ec1('0x2a')]=_0x332ed6,_0xeb8c8a[_0x5e3ec1('0x22df')]=_0xbbf6d&&_0xbbf6d[_0x5e3ec1('0x50d')]==0x1?_0xbbf6d[_0x5e3ec1('0xf5d')][0x0]:null,_0xeb8c8a[_0x5e3ec1('0x1134')]=_0x1bfd9e['parseCrudPermissions'](_0xeb8c8a[_0x5e3ec1('0x22df')]?_0xeb8c8a[_0x5e3ec1('0x22df')]['crudPermissions']:null),_0xeb8c8a[_0x5e3ec1('0x5c4')]=_0x5e3ec1('0x3ac'),_0xeb8c8a[_0x5e3ec1('0x247')]='',_0xeb8c8a[_0x5e3ec1('0x1ce2')]=null,_0xeb8c8a[_0x5e3ec1('0x26ab')]=[],_0xeb8c8a[_0x5e3ec1('0x23a2')]={'fields':_0x5e3ec1('0x1b08'),'sort':_0x5e3ec1('0xc36'),'createdAt':_0x5e3ec1('0x67f'),'limit':0xa,'page':0x1},_0xeb8c8a['query'][_0x5e3ec1('0x1a4')]=_0x33d696[_0x5e3ec1('0x11c4')](),_0xeb8c8a[_0x5e3ec1('0xc71')]=_0x1020a3();function _0x1020a3(){const _0x43aca6=_0x5e3ec1;return[{'name':'Start\x20Date','key':'createdAt','type':'date','label':_0x43aca6('0x15ff')}];}_0xeb8c8a[_0x5e3ec1('0xc63')]=_0x5c0c32,_0xeb8c8a[_0x5e3ec1('0x2862')]=_0x130c3b,_0xeb8c8a['runtranscribesentimentruntranscribesentiment']=_0xf721d9,_0xeb8c8a['runsentimentruntranscribesentiment']=_0x3ffd92,_0xeb8c8a[_0x5e3ec1('0x247a')]=_0x165fd8,_0xeb8c8a[_0x5e3ec1('0x29d')]=_0x11f8cb,_0xeb8c8a['deleteconfirm']=_0xb63a0b,_0xeb8c8a['success']=_0x37ec65,_0xeb8c8a[_0x5e3ec1('0x261d')]=_0x233754,_0xeb8c8a['createOrEditVoiceRecording']=_0x2a35e7,_0xeb8c8a[_0x5e3ec1('0x2093')]=_0x3c1fa3,_0xeb8c8a['exportSelectedVoiceRecordings']=_0x56d35f,_0xeb8c8a[_0x5e3ec1('0x1a75')]=_0x3e5792,_0xeb8c8a['deselectVoiceRecordings']=_0x48e504,_0xeb8c8a[_0x5e3ec1('0x602')]=_0x984787;function _0x5c0c32(_0x254a4f){const _0x372886=_0x5e3ec1;_0x394e5e['go'](_0x372886('0x1295'),{'id':_0x254a4f['id'],'voiceRecording':_0x254a4f,'crudPermissions':_0xeb8c8a[_0x372886('0x1134')]});}_0xeb8c8a[_0x5e3ec1('0x1cb1')]=_0x1cede6;function _0x130c3b(_0x339a4c){const _0x30f5b4=_0x5e3ec1;return _0x9043dd[_0x30f5b4('0x52f')]['runTranscribe']({'id':_0x339a4c['id'],'runSentiment':![]})[_0x30f5b4('0xe53')][_0x30f5b4('0x683')](function(_0x21eed7){const _0xe96b96=_0x30f5b4;_0x3a591b[_0xe96b96('0x53')]({'title':_0x40fad6[_0xe96b96('0x2728')]('VOICE.RUNTRANSCRIBE_VOICERECORDING'),'msg':_0x40fad6[_0xe96b96('0x2728')](_0xe96b96('0x1746'))+'\x20succeded!'}),_0x339a4c[_0xe96b96('0x27c')]=_0x21eed7['transcribeStatus'];})['catch'](function(_0x259bcd){const _0x42ea2b=_0x30f5b4;_0x3a591b[_0x42ea2b('0x52a')]({'title':_0x40fad6[_0x42ea2b('0x2728')](_0x42ea2b('0x1746')),'msg':_0x259bcd[_0x42ea2b('0x5a5')]?_0x259bcd['data'][_0x42ea2b('0x8c2')]?_0x259bcd[_0x42ea2b('0x5a5')][_0x42ea2b('0x8c2')]:JSON[_0x42ea2b('0x258a')](_0x259bcd[_0x42ea2b('0x5a5')]):_0x259bcd[_0x42ea2b('0x1ff0')]()});});}function _0x1cede6(){const _0x9ac5fd=_0x5e3ec1;_0xeb8c8a[_0x9ac5fd('0x26ab')]['forEach'](function(_0x20eeb1){_0x130c3b(_0x20eeb1);}),_0xeb8c8a['selectedVoiceRecordings']=[];}_0xeb8c8a[_0x5e3ec1('0x178e')]=_0x4b5f0c;function _0xf721d9(_0x32cdc8){const _0x511c41=_0x5e3ec1;return _0x9043dd[_0x511c41('0x52f')][_0x511c41('0x289')]({'id':_0x32cdc8['id'],'runSentiment':!![]})[_0x511c41('0xe53')][_0x511c41('0x683')](function(_0x37173f){const _0x14ec2b=_0x511c41;_0x3a591b[_0x14ec2b('0x53')]({'title':_0x40fad6['instant'](_0x14ec2b('0x29b')),'msg':_0x40fad6['instant'](_0x14ec2b('0x29b'))+'\x20succeded!'}),_0x32cdc8[_0x14ec2b('0x27c')]=_0x37173f[_0x14ec2b('0x27c')];})[_0x511c41('0x130a')](function(_0x49b624){const _0x389599=_0x511c41;_0x3a591b['error']({'title':_0x40fad6['instant'](_0x389599('0x29b')),'msg':_0x49b624[_0x389599('0x5a5')]?_0x49b624['data']['message']?_0x49b624[_0x389599('0x5a5')][_0x389599('0x8c2')]:JSON['stringify'](_0x49b624[_0x389599('0x5a5')]):_0x49b624[_0x389599('0x1ff0')]()});});}function _0x4b5f0c(){const _0x4d8e7f=_0x5e3ec1;_0xeb8c8a[_0x4d8e7f('0x26ab')]['forEach'](function(_0xf838fb){_0xf721d9(_0xf838fb);}),_0xeb8c8a[_0x4d8e7f('0x26ab')]=[];}_0xeb8c8a[_0x5e3ec1('0x1d55')]=_0x5b2f94;function _0x3ffd92(_0x5519e3){const _0x7dce11=_0x5e3ec1;return _0x9043dd['voiceRecording'][_0x7dce11('0x289')]({'id':_0x5519e3['id'],'runSentiment':!![]})[_0x7dce11('0xe53')][_0x7dce11('0x683')](function(){const _0x4e415b=_0x7dce11;_0x3a591b[_0x4e415b('0x53')]({'title':_0x40fad6[_0x4e415b('0x2728')](_0x4e415b('0xe21')),'msg':_0x40fad6['instant'](_0x4e415b('0xe21'))+_0x4e415b('0x331')});})[_0x7dce11('0x130a')](function(_0x265ca8){const _0x3780c1=_0x7dce11;_0x3a591b['error']({'title':_0x40fad6['instant'](_0x3780c1('0xe21')),'msg':_0x265ca8['data']?_0x265ca8['data']['message']?_0x265ca8[_0x3780c1('0x5a5')]['message']:JSON[_0x3780c1('0x258a')](_0x265ca8[_0x3780c1('0x5a5')]):_0x265ca8['toString']()});});}function _0x5b2f94(){const _0x4e21dd=_0x5e3ec1;_0xeb8c8a[_0x4e21dd('0x26ab')][_0x4e21dd('0x1299')](function(_0x4e1f3e){_0x3ffd92(_0x4e1f3e);}),_0xeb8c8a['selectedVoiceRecordings']=[];}function _0x165fd8(_0x22650d){const _0x21e9ff=_0x5e3ec1;let _0x3684c2=![];const _0x5473e4=!_0x2e3ca0()['isNil'](_0x22650d[_0x21e9ff('0x26dd')])?_0x22650d[_0x21e9ff('0x26dd')]:_0x22650d[_0x21e9ff('0x1c6b')][_0x21e9ff('0x1735')](_0x22650d['value'][_0x21e9ff('0xb77')]('.'));return _0x3684c2=_0x5473e4===_0x21e9ff('0xc9')?!![]:![],_0x9043dd[_0x21e9ff('0x52f')][_0x21e9ff('0xd2b')]({'id':_0x22650d['id']})[_0x21e9ff('0xe53')][_0x21e9ff('0x683')](function(_0x5f4e24){const _0xb73abc=_0x21e9ff,_0x30f204=[_0x5f4e24[_0xb73abc('0x1fb3')]];let _0x276589=_0xb73abc('0x18e8');const _0x152e0a=new Blob(_0x30f204,{'type':_0x5f4e24[_0xb73abc('0xcf0')]});_0x276589=_0x22650d[_0xb73abc('0x573')]+_0xb73abc('0x208c');const _0x40eb7c=window[_0xb73abc('0x12e1')][_0xb73abc('0x1ffa')]('a');_0x40eb7c[_0xb73abc('0x130f')](_0xb73abc('0x2767'),URL[_0xb73abc('0x2820')](_0x152e0a)),_0x40eb7c[_0xb73abc('0x130f')]('download',_0x276589),document[_0xb73abc('0x18e5')][_0xb73abc('0x1e43')](_0x40eb7c),_0x40eb7c[_0xb73abc('0x1d42')]();})[_0x21e9ff('0x130a')](function(_0x385245){const _0x4213d0=_0x21e9ff;if(_0x385245['data']&&_0x385245[_0x4213d0('0x5a5')]['errors']&&_0x385245[_0x4213d0('0x5a5')][_0x4213d0('0x17f')][_0x4213d0('0x1564')])for(let _0x47da58=0x0;_0x47da58<_0x385245[_0x4213d0('0x5a5')][_0x4213d0('0x17f')][_0x4213d0('0x1564')];_0x47da58++){_0x3a591b[_0x4213d0('0x52a')]({'title':_0x385245[_0x4213d0('0x5a5')][_0x4213d0('0x17f')][_0x47da58]['type'],'msg':_0x385245[_0x4213d0('0x5a5')][_0x4213d0('0x17f')][_0x47da58]['message']});}else{if(String(_0x385245[_0x4213d0('0x13ee')])===_0x4213d0('0x1bef')&&_0x3684c2===![])_0x3a591b[_0x4213d0('0x2289')]({'title':_0x40fad6[_0x4213d0('0x2728')](_0x4213d0('0x4f0')),'msg':_0x40fad6['instant']('VOICE.WRONG_EXTENSION')});else String(_0x385245['status'])==='404'?_0x3a591b[_0x4213d0('0x2289')]({'title':_0x40fad6[_0x4213d0('0x2728')](_0x4213d0('0x4f0')),'msg':_0x40fad6[_0x4213d0('0x2728')](_0x4213d0('0x1e27'))}):_0x3a591b[_0x4213d0('0x52a')]({'title':_0x385245[_0x4213d0('0x13ee')]?_0x4213d0('0x2168')+_0x385245['status']+_0x4213d0('0xbf6')+_0x385245['statusText']:_0x4213d0('0xa25'),'msg':_0x385245[_0x4213d0('0x5a5')]?JSON[_0x4213d0('0x258a')](_0x385245[_0x4213d0('0x5a5')][_0x4213d0('0x8c2')]):_0x385245[_0x4213d0('0x1ff0')]()});}});}function _0x325bfc(_0x4ea4b5){const _0x42960f=_0x5e3ec1;let _0x483fd7=_0x4ea4b5[_0x42960f('0xb77')]('/')>-0x1?_0x4ea4b5[_0x42960f('0x1735')](_0x4ea4b5['lastIndexOf']('/')+0x1):_0x4ea4b5['lastIndexOf']('\x5c')>-0x1?_0x4ea4b5[_0x42960f('0x1735')](_0x4ea4b5['lastIndexOf']('\x5c')+0x1):_0x4ea4b5;return _0x483fd7=_0x483fd7['substring'](0x0,_0x483fd7[_0x42960f('0xb77')]('.')),_0x483fd7;}function _0x11f8cb(_0x5bcef2){const _0x10254f=_0x5e3ec1;let _0x59bc7c=![];const _0x119bbc=!_0x2e3ca0()['isNil'](_0x5bcef2[_0x10254f('0x26dd')])?_0x5bcef2[_0x10254f('0x26dd')]:_0x5bcef2[_0x10254f('0x1c6b')]['substring'](_0x5bcef2['value']['lastIndexOf']('.'));return _0x59bc7c=_0x119bbc==='.mp4'?!![]:![],_0x9043dd[_0x10254f('0x52f')][_0x10254f('0x18e8')]({'id':_0x5bcef2['id']})[_0x10254f('0xe53')][_0x10254f('0x683')](function(_0x5687c7){const _0x202b42=_0x10254f,_0x24fc7b=[_0x5687c7['buffer']];let _0x4e8685=_0x202b42('0x18e8');const _0x529c87=new Blob(_0x24fc7b,{'type':_0x5687c7[_0x202b42('0xcf0')]});_0x4e8685=_0x325bfc(_0x5bcef2['value'])+_0x5bcef2[_0x202b42('0x26dd')];const _0x685e81=window[_0x202b42('0x12e1')][_0x202b42('0x1ffa')]('a');_0x685e81['setAttribute'](_0x202b42('0x2767'),URL[_0x202b42('0x2820')](_0x529c87)),_0x685e81[_0x202b42('0x130f')](_0x202b42('0x18e8'),_0x4e8685),document[_0x202b42('0x18e5')][_0x202b42('0x1e43')](_0x685e81),_0x685e81['click']();})['catch'](function(_0x1cb66f){const _0x2f3deb=_0x10254f;if(_0x1cb66f['data']&&_0x1cb66f['data'][_0x2f3deb('0x17f')]&&_0x1cb66f[_0x2f3deb('0x5a5')][_0x2f3deb('0x17f')][_0x2f3deb('0x1564')])for(let _0x36cada=0x0;_0x36cada<_0x1cb66f[_0x2f3deb('0x5a5')]['errors'][_0x2f3deb('0x1564')];_0x36cada++){_0x3a591b[_0x2f3deb('0x52a')]({'title':_0x1cb66f[_0x2f3deb('0x5a5')]['errors'][_0x36cada][_0x2f3deb('0xcf0')],'msg':_0x1cb66f[_0x2f3deb('0x5a5')][_0x2f3deb('0x17f')][_0x36cada][_0x2f3deb('0x8c2')]});}else{if(String(_0x1cb66f['status'])==='404'&&_0x59bc7c===![])_0x3a591b[_0x2f3deb('0x2289')]({'title':_0x40fad6[_0x2f3deb('0x2728')](_0x2f3deb('0x4f0')),'msg':_0x40fad6['instant'](_0x2f3deb('0x854'))});else String(_0x1cb66f[_0x2f3deb('0x13ee')])===_0x2f3deb('0x1bef')?_0x3a591b[_0x2f3deb('0x2289')]({'title':_0x40fad6[_0x2f3deb('0x2728')](_0x2f3deb('0x4f0')),'msg':_0x40fad6['instant'](_0x2f3deb('0x1e27'))}):_0x3a591b['error']({'title':_0x1cb66f[_0x2f3deb('0x13ee')]?_0x2f3deb('0x2168')+_0x1cb66f[_0x2f3deb('0x13ee')]+_0x2f3deb('0xbf6')+_0x1cb66f[_0x2f3deb('0x24a9')]:_0x2f3deb('0xa25'),'msg':_0x1cb66f[_0x2f3deb('0x5a5')]?JSON[_0x2f3deb('0x258a')](_0x1cb66f['data']['message']):_0x1cb66f[_0x2f3deb('0x1ff0')]()});}});}function _0xb63a0b(_0x4dd3c9,_0x3381d4){const _0x163d25=_0x5e3ec1,_0x77dfd2=_0x244d3a['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x163d25('0x1e03')]('voiceRecording')+'?')[_0x163d25('0x26e3')](_0x163d25('0xed5')+(_0x4dd3c9['name']||_0x163d25('0x52f'))+_0x163d25('0x20f1')+_0x163d25('0x1ee7'))[_0x163d25('0x1040')](_0x163d25('0x2807'))[_0x163d25('0xe42')](_0x3381d4)['ok']('OK')[_0x163d25('0x19fb')](_0x163d25('0x16b8'));_0x244d3a[_0x163d25('0x1d4')](_0x77dfd2)[_0x163d25('0x683')](function(){_0x3c1fa3(_0x4dd3c9);},function(){const _0x5aa137=_0x163d25;console[_0x5aa137('0x1b2b')](_0x5aa137('0x16b8'));});}let _0x3f655f=!![],_0xbecfe9=0x1;_0x12ebc5['$watch'](_0x5e3ec1('0x1e1d'),function(_0x2ae411,_0x4f21e4){const _0xfc4a58=_0x5e3ec1;_0x3f655f?_0x292fe1(function(){_0x3f655f=![];}):(!_0x4f21e4&&(_0xbecfe9=_0xeb8c8a[_0xfc4a58('0x23a2')][_0xfc4a58('0xdf8')]),_0x2ae411!==_0x4f21e4&&(_0xeb8c8a['query']['page']=0x1),!_0x2ae411&&(_0xeb8c8a[_0xfc4a58('0x23a2')][_0xfc4a58('0xdf8')]=_0xbecfe9),_0xeb8c8a['getVoiceRecordings']());});function _0x37ec65(_0x375bc6){const _0x4df62d=_0x5e3ec1;_0xeb8c8a[_0x4df62d('0x3ac')]=_0x375bc6||{'count':0x0,'rows':[]};}function _0x233754(){const _0xa6e41b=_0x5e3ec1;_0xeb8c8a[_0xa6e41b('0x23a2')]['offset']=(_0xeb8c8a[_0xa6e41b('0x23a2')][_0xa6e41b('0xdf8')]-0x1)*_0xeb8c8a[_0xa6e41b('0x23a2')][_0xa6e41b('0x6f0')],_0x1bfd9e[_0xa6e41b('0xca1')](_0xa6e41b('0x20c2'))?_0xeb8c8a['promise']=_0x9043dd[_0xa6e41b('0x52f')][_0xa6e41b('0x1e6e')](_0xeb8c8a[_0xa6e41b('0x23a2')],_0x37ec65)[_0xa6e41b('0xe53')]:(_0xeb8c8a[_0xa6e41b('0x23a2')]['id']=_0xeb8c8a['userProfile']['id'],_0xeb8c8a[_0xa6e41b('0x23a2')][_0xa6e41b('0x1aa')]='VoiceRecordings',_0xeb8c8a[_0xa6e41b('0x1883')]=_0x9043dd['userProfile'][_0xa6e41b('0x241d')](_0xeb8c8a[_0xa6e41b('0x23a2')],_0x37ec65)['$promise']);}function _0x2a35e7(_0x306663,_0x118e77){const _0x1dfa59=_0x5e3ec1;_0x244d3a[_0x1dfa59('0x1d4')]({'controller':_0x1dfa59('0x1d0d'),'controllerAs':'vm','templateUrl':_0x4620b1,'parent':angular[_0x1dfa59('0x1fcc')](_0x394499[_0x1dfa59('0x18e5')]),'targetEvent':_0x306663,'clickOutsideToClose':!![],'locals':{'voiceRecording':_0x118e77,'voiceRecordings':_0xeb8c8a[_0x1dfa59('0x3ac')][_0x1dfa59('0xf5d')],'license':_0xeb8c8a['license'],'setting':_0xeb8c8a[_0x1dfa59('0x260a')],'crudPermissions':_0xeb8c8a['crudPermissions']}});}function _0x3c1fa3(_0x54d7a9){const _0x196f0c=_0x5e3ec1;_0x9043dd[_0x196f0c('0x52f')][_0x196f0c('0xd7e')]({'id':_0x54d7a9['id']})[_0x196f0c('0xe53')][_0x196f0c('0x683')](function(){const _0x430308=_0x196f0c;_0x2e3ca0()[_0x430308('0x3ec')](_0xeb8c8a[_0x430308('0x3ac')][_0x430308('0xf5d')],{'id':_0x54d7a9['id']}),_0xeb8c8a[_0x430308('0x3ac')][_0x430308('0x50d')]-=0x1,!_0xeb8c8a['voiceRecordings'][_0x430308('0xf5d')][_0x430308('0x1564')]&&_0xeb8c8a[_0x430308('0x261d')](),_0x3a591b[_0x430308('0x53')]({'title':_0x2e3ca0()[_0x430308('0x1e03')](_0x430308('0x2173'))+'\x20deleted!','msg':_0x54d7a9[_0x430308('0x60a')]?_0x54d7a9['name']+'\x20has\x20been\x20deleted!':''});})[_0x196f0c('0x130a')](function(_0x3ddc5d){const _0x78da85=_0x196f0c;if(_0x3ddc5d[_0x78da85('0x5a5')]&&_0x3ddc5d['data'][_0x78da85('0x17f')]&&_0x3ddc5d[_0x78da85('0x5a5')]['errors']['length']){_0xeb8c8a[_0x78da85('0x17f')]=_0x3ddc5d['data'][_0x78da85('0x17f')]||[{'message':_0x3ddc5d[_0x78da85('0x1ff0')](),'type':_0x78da85('0x1a3e')}];for(let _0x31655e=0x0;_0x31655e<_0x3ddc5d[_0x78da85('0x5a5')]['errors'][_0x78da85('0x1564')];_0x31655e++){_0x3a591b[_0x78da85('0x52a')]({'title':_0x3ddc5d[_0x78da85('0x5a5')][_0x78da85('0x17f')][_0x31655e][_0x78da85('0xcf0')],'msg':_0x3ddc5d[_0x78da85('0x5a5')]['errors'][_0x31655e]['message']});}}else _0x3a591b[_0x78da85('0x52a')]({'title':_0x3ddc5d['status']?_0x78da85('0x2168')+_0x3ddc5d[_0x78da85('0x13ee')]+_0x78da85('0xbf6')+_0x3ddc5d[_0x78da85('0x24a9')]:_0x78da85('0x1a3e'),'msg':_0x3ddc5d[_0x78da85('0x5a5')]?JSON[_0x78da85('0x258a')](_0x3ddc5d['data'][_0x78da85('0x8c2')]):_0x3ddc5d['message']||_0x3ddc5d['toString']()});});}function _0x56d35f(){const _0x238979=_0x5e3ec1,_0x4a9051=angular[_0x238979('0x1a86')](_0xeb8c8a[_0x238979('0x26ab')]);return _0xeb8c8a[_0x238979('0x26ab')]=[],_0x4a9051;}function _0x3e5792(_0x296b8b){const _0x4b3487=_0x5e3ec1,_0x3bfeef=_0x244d3a[_0x4b3487('0x1c6f')]()[_0x4b3487('0xf28')](_0x4b3487('0x22c9'))[_0x4b3487('0x26e3')](_0x4b3487('0xed5')+_0xeb8c8a[_0x4b3487('0x26ab')][_0x4b3487('0x1564')]+'\x20selected'+_0x4b3487('0x1ee7'))[_0x4b3487('0x1040')](_0x4b3487('0x13da'))[_0x4b3487('0xe42')](_0x296b8b)['ok']('OK')[_0x4b3487('0x19fb')]('CANCEL');_0x244d3a[_0x4b3487('0x1d4')](_0x3bfeef)[_0x4b3487('0x683')](function(){const _0x3d32f4=_0x4b3487;_0xeb8c8a[_0x3d32f4('0x26ab')][_0x3d32f4('0x1299')](function(_0x28701c){_0x3c1fa3(_0x28701c);}),_0xeb8c8a[_0x3d32f4('0x26ab')]=[];});}function _0x48e504(){const _0x5275b0=_0x5e3ec1;_0xeb8c8a[_0x5275b0('0x26ab')]=[];}function _0x984787(){const _0xce53ba=_0x5e3ec1;_0xeb8c8a[_0xce53ba('0x26ab')]=_0xeb8c8a['voiceRecordings'][_0xce53ba('0xf5d')];}}const _0x39902b=_0x2b9219,_0x23dc4f=_0x180212['p']+_0x189033('0x21a4'),_0x74ad6e=_0x180212['p']+'src/js/modules/main/apps/voice/views/voiceQueues/edit/view.html/view.html',_0x1592df=_0x180212['p']+_0x189033('0x1dbe'),_0x3575c2=_0x180212['p']+_0x189033('0x17ce'),_0x4035c6=_0x180212['p']+_0x189033('0x18ef'),_0x1555e5=_0x180212['p']+_0x189033('0xa89'),_0xcd50b9=_0x180212['p']+'src/js/modules/main/apps/voice/views/internalroutes/internalroutes.html/internalroutes.html',_0xc5b43=_0x180212['p']+_0x189033('0x48a'),_0x490924=_0x180212['p']+_0x189033('0x2418'),_0x1a4517=_0x180212['p']+'src/js/modules/main/apps/voice/views/voicemails/voicemails.html/voicemails.html',_0x5e41e1=_0x180212['p']+'src/js/modules/main/apps/voice/views/voicemails/edit/view.html/view.html',_0x18c20e=_0x180212['p']+_0x189033('0xf1f'),_0x3d5dc2=_0x180212['p']+'src/js/modules/main/apps/voice/views/musiconholds/edit/view.html/view.html',_0x2c0f2b=_0x180212['p']+_0x189033('0x13d1'),_0x4253ba=_0x180212['p']+'src/js/modules/main/apps/voice/views/voiceRecordings/edit/view.html/view.html',_0x5c22a1=_0x180212['p']+_0x189033('0x1b58'),_0x34d06f=_0x180212['p']+_0x189033('0xe6a');_0x2e12f4['$inject']=[_0x189033('0x1398'),'$translatePartialLoaderProvider'];function _0x2e12f4(_0x513496,_0xeebe4d){const _0x127fb8=_0x189033;_0x513496['state']('app.voice',{'abstract':!![],'url':_0x127fb8('0xefd')})['state']('app.voice.voiceQueues',{'url':_0x127fb8('0x256e'),'views':{'content@app':{'templateUrl':_0x23dc4f,'controller':_0x127fb8('0xada')}},'resolve':{'voiceQueues':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x125152,_0x498c5f){const _0x29955b=_0x127fb8;return _0x498c5f['hasRole'](_0x29955b('0x20c2'))?_0x125152[_0x29955b('0xed7')](_0x29955b('0x2730'),{'fields':_0x29955b('0x1d7e'),'type':_0x29955b('0x1535'),'sort':_0x29955b('0xc36'),'channel':_0x29955b('0xcf2'),'limit':0xa,'offset':0x0}):_0x125152[_0x29955b('0xed7')](_0x29955b('0x191b'),{'id':_0x498c5f[_0x29955b('0x20b2')]()[_0x29955b('0x2f')],'section':'VoiceQueues','fields':_0x29955b('0x1d7e'),'type':_0x29955b('0x1535'),'sort':'-updatedAt','channel':_0x29955b('0xcf2'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x127fb8('0xba1'),function(_0x4e677e,_0x3b8fea){const _0x3209c1=_0x127fb8;return _0x3b8fea['hasRole'](_0x3209c1('0x20c2'))?null:_0x4e677e[_0x3209c1('0xed7')](_0x3209c1('0x1464'),{'fields':_0x3209c1('0x16f'),'id':_0x3b8fea[_0x3209c1('0x20b2')]()[_0x3209c1('0x2f')]});}],'userProfileSection':[_0x127fb8('0x4b1'),'Auth',function(_0x1389f5,_0x548349){const _0x114443=_0x127fb8;return _0x548349['hasRole'](_0x114443('0x20c2'))?null:_0x1389f5['resolve']('userProfileSection@get',{'fields':_0x114443('0x1f47'),'userProfileId':_0x548349[_0x114443('0x20b2')]()[_0x114443('0x2f')],'sectionId':0x191});}]},'authenticate':!![],'permissionId':0x191,'bodyClass':_0x127fb8('0xcf2')})['state'](_0x127fb8('0xe5d'),{'url':_0x127fb8('0x1560'),'params':{'voiceQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x74ad6e,'controller':_0x127fb8('0x2067')}},'resolve':{'voiceQueue':[_0x127fb8('0x4b1'),_0x127fb8('0x8ea'),function(_0x368eb7,_0x2b93a6){const _0x50ca68=_0x127fb8;return _0x368eb7['resolve']('voiceQueue@get',{'fields':_0x50ca68('0x1d7e'),'id':_0x2b93a6['id']});}],'userProfileSection':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x176deb,_0x2bc8aa){const _0x2d8b5a=_0x127fb8;return _0x176deb[_0x2d8b5a('0xed7')](_0x2d8b5a('0x360'),{'fields':_0x2d8b5a('0x1f47'),'userProfileId':_0x2bc8aa[_0x2d8b5a('0x20b2')]()[_0x2d8b5a('0x2f')],'sectionId':0x191});}]},'authenticate':!![],'permissionId':0x191,'bodyClass':_0x127fb8('0xcf2')})[_0x127fb8('0x2598')](_0x127fb8('0x2202'),{'url':'/inboundroutes','views':{'content@app':{'templateUrl':_0x1592df,'controller':'InboundRoutesController\x20as\x20vm'}},'resolve':{'inboundroutes':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x39df19,_0x48661){const _0x4cfb1f=_0x127fb8;return _0x48661[_0x4cfb1f('0xca1')](_0x4cfb1f('0x20c2'))?_0x39df19['resolve'](_0x4cfb1f('0x24de'),{'fields':_0x4cfb1f('0xb7'),'type':_0x4cfb1f('0x1535'),'sort':_0x4cfb1f('0xc36'),'VoiceExtensionId':'null','limit':0xa,'offset':0x0}):_0x39df19[_0x4cfb1f('0xed7')](_0x4cfb1f('0x191b'),{'id':_0x48661[_0x4cfb1f('0x20b2')]()[_0x4cfb1f('0x2f')],'section':'InboundRoutes','fields':_0x4cfb1f('0xb7'),'type':_0x4cfb1f('0x1535'),'sort':'-updatedAt','VoiceExtensionId':_0x4cfb1f('0x13c'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x127fb8('0x4b1'),'Auth',function(_0x511271,_0x250a47){const _0xe3d925=_0x127fb8;return _0x250a47[_0xe3d925('0xca1')]('admin')?null:_0x511271[_0xe3d925('0xed7')](_0xe3d925('0x1464'),{'fields':_0xe3d925('0x16f'),'id':_0x250a47['getCurrentUser']()[_0xe3d925('0x2f')]});}],'userProfileSection':[_0x127fb8('0x4b1'),'Auth',function(_0x464bfa,_0x38a5ed){const _0x290492=_0x127fb8;return _0x38a5ed[_0x290492('0xca1')](_0x290492('0x20c2'))?null:_0x464bfa[_0x290492('0xed7')](_0x290492('0x360'),{'fields':_0x290492('0x1f47'),'userProfileId':_0x38a5ed['getCurrentUser']()[_0x290492('0x2f')],'sectionId':0x192});}]},'authenticate':!![],'permissionId':0x192,'bodyClass':_0x127fb8('0xcf2')})['state'](_0x127fb8('0x1225'),{'url':_0x127fb8('0x1560'),'params':{'inboundroute':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x3575c2,'controller':_0x127fb8('0xe84')}},'resolve':{'inboundroute':[_0x127fb8('0x4b1'),_0x127fb8('0x8ea'),function(_0xa6e58f,_0x295f79){const _0x272449=_0x127fb8;return _0xa6e58f[_0x272449('0xed7')](_0x272449('0x24de'),{'fields':'createdAt,updatedAt,id,appdata,type,exten,context,description','id':_0x295f79['id']});}],'userProfileSection':['apiResolver',_0x127fb8('0xba1'),function(_0xb2b3b0,_0x22e677){const _0x2c1810=_0x127fb8;return _0xb2b3b0[_0x2c1810('0xed7')](_0x2c1810('0x360'),{'fields':_0x2c1810('0x1f47'),'userProfileId':_0x22e677[_0x2c1810('0x20b2')]()[_0x2c1810('0x2f')],'sectionId':0x192});}]},'authenticate':!![],'permissionId':0x192,'bodyClass':_0x127fb8('0xcf2')})['state'](_0x127fb8('0x10c7'),{'url':_0x127fb8('0x1383'),'views':{'content@app':{'templateUrl':_0x4035c6,'controller':_0x127fb8('0xa7d')}},'resolve':{'outboundroutes':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x2af0f6,_0x14d018){const _0x35ceb0=_0x127fb8;return _0x14d018[_0x35ceb0('0xca1')](_0x35ceb0('0x20c2'))?_0x2af0f6['resolve'](_0x35ceb0('0x24de'),{'fields':_0x35ceb0('0xc2'),'type':_0x35ceb0('0x17cd'),'sort':_0x35ceb0('0xc36'),'VoiceExtensionId':_0x35ceb0('0x13c'),'limit':0xa,'offset':0x0}):_0x2af0f6[_0x35ceb0('0xed7')]('userProfile@getResources',{'id':_0x14d018[_0x35ceb0('0x20b2')]()[_0x35ceb0('0x2f')],'section':'OutboundRoutes','fields':'createdAt,updatedAt,id,appdata,type,exten,context,recordingFormat,cutdigits,description','type':_0x35ceb0('0x17cd'),'sort':_0x35ceb0('0xc36'),'VoiceExtensionId':_0x35ceb0('0x13c'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x45f02f,_0x4cfd18){const _0x273cea=_0x127fb8;return _0x4cfd18[_0x273cea('0xca1')](_0x273cea('0x20c2'))?null:_0x45f02f[_0x273cea('0xed7')](_0x273cea('0x1464'),{'fields':_0x273cea('0x16f'),'id':_0x4cfd18[_0x273cea('0x20b2')]()[_0x273cea('0x2f')]});}],'userProfileSection':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x2bbd07,_0x5bc415){const _0x1c2b63=_0x127fb8;return _0x5bc415[_0x1c2b63('0xca1')]('admin')?null:_0x2bbd07[_0x1c2b63('0xed7')](_0x1c2b63('0x360'),{'fields':_0x1c2b63('0x1f47'),'userProfileId':_0x5bc415[_0x1c2b63('0x20b2')]()[_0x1c2b63('0x2f')],'sectionId':0x193});}]},'authenticate':!![],'permissionId':0x193,'bodyClass':_0x127fb8('0xcf2')})[_0x127fb8('0x2598')]('app.voice.outboundroutes.edit',{'url':_0x127fb8('0x1560'),'params':{'outboundroute':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x1555e5,'controller':'OutboundRouteController\x20as\x20vm'}},'resolve':{'outboundroute':[_0x127fb8('0x4b1'),_0x127fb8('0x8ea'),function(_0x40bc30,_0xa1d4e1){const _0x273949=_0x127fb8;return _0x40bc30['resolve'](_0x273949('0x24de'),{'fields':'createdAt,updatedAt,id,appdata,type,exten,context,recordingFormat,cutdigits,description','id':_0xa1d4e1['id']});}],'userProfileSection':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x31a901,_0x415a4f){const _0x116d2e=_0x127fb8;return _0x31a901[_0x116d2e('0xed7')](_0x116d2e('0x360'),{'fields':_0x116d2e('0x1f47'),'userProfileId':_0x415a4f[_0x116d2e('0x20b2')]()[_0x116d2e('0x2f')],'sectionId':0x193});}]},'authenticate':!![],'permissionId':0x193,'bodyClass':'voice'})['state'](_0x127fb8('0x1d76'),{'url':_0x127fb8('0x124c'),'views':{'content@app':{'templateUrl':_0xcd50b9,'controller':_0x127fb8('0x1f99')}},'resolve':{'internalroutes':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x584a2a,_0x39647b){const _0x383f8d=_0x127fb8;return _0x39647b['hasRole']('admin')?_0x584a2a['resolve'](_0x383f8d('0x24de'),{'fields':'createdAt,updatedAt,id,appdata,type,exten,context,description','type':_0x383f8d('0x1d43'),'sort':_0x383f8d('0xc36'),'VoiceExtensionId':_0x383f8d('0x13c'),'limit':0xa,'offset':0x0}):_0x584a2a[_0x383f8d('0xed7')](_0x383f8d('0x191b'),{'id':_0x39647b['getCurrentUser']()['userProfileId'],'section':_0x383f8d('0x26c8'),'fields':_0x383f8d('0xb7'),'type':_0x383f8d('0x1d43'),'sort':'-updatedAt','VoiceExtensionId':_0x383f8d('0x13c'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x587eb4,_0x1c4cc8){const _0x117764=_0x127fb8;return _0x1c4cc8[_0x117764('0xca1')](_0x117764('0x20c2'))?null:_0x587eb4[_0x117764('0xed7')]('userProfile@get',{'fields':_0x117764('0x16f'),'id':_0x1c4cc8[_0x117764('0x20b2')]()[_0x117764('0x2f')]});}],'userProfileSection':['apiResolver',_0x127fb8('0xba1'),function(_0x2c94ff,_0x1403af){const _0x22683a=_0x127fb8;return _0x1403af[_0x22683a('0xca1')](_0x22683a('0x20c2'))?null:_0x2c94ff['resolve'](_0x22683a('0x360'),{'fields':_0x22683a('0x1f47'),'userProfileId':_0x1403af[_0x22683a('0x20b2')]()['userProfileId'],'sectionId':0x194});}]},'authenticate':!![],'permissionId':0x194,'bodyClass':'voice'})[_0x127fb8('0x2598')]('app.voice.internalroutes.edit',{'url':_0x127fb8('0x1560'),'params':{'internalroute':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0xc5b43,'controller':_0x127fb8('0x735')}},'resolve':{'internalroute':['apiResolver',_0x127fb8('0x8ea'),function(_0x244ad0,_0x328657){const _0x3f56c6=_0x127fb8;return _0x244ad0[_0x3f56c6('0xed7')](_0x3f56c6('0x24de'),{'fields':_0x3f56c6('0xb7'),'id':_0x328657['id']});}],'userProfileSection':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x2ac0fb,_0x2a7479){const _0x20c584=_0x127fb8;return _0x2ac0fb[_0x20c584('0xed7')](_0x20c584('0x360'),{'fields':_0x20c584('0x1f47'),'userProfileId':_0x2a7479[_0x20c584('0x20b2')]()[_0x20c584('0x2f')],'sectionId':0x194});}]},'authenticate':!![],'permissionId':0x194,'bodyClass':_0x127fb8('0xcf2')})[_0x127fb8('0x2598')]('app.voice.contexts',{'url':_0x127fb8('0x176f'),'views':{'content@app':{'templateUrl':_0x490924,'controller':'ContextsController\x20as\x20vm'}},'resolve':{'contexts':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x17a4f0,_0x54defb){const _0x1e6fc0=_0x127fb8;return _0x54defb[_0x1e6fc0('0xca1')]('admin')?_0x17a4f0[_0x1e6fc0('0xed7')]('voiceContext@get',{'fields':'createdAt,updatedAt,id,name,description','sort':_0x1e6fc0('0xc36'),'defaultEntry':'false','limit':0xa,'offset':0x0}):_0x17a4f0[_0x1e6fc0('0xed7')](_0x1e6fc0('0x191b'),{'id':_0x54defb['getCurrentUser']()[_0x1e6fc0('0x2f')],'section':_0x1e6fc0('0x929'),'fields':_0x1e6fc0('0x120a'),'sort':'-updatedAt','defaultEntry':'false','limit':0xa,'offset':0x0});}],'userProfile':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x2bd0b3,_0x44c6d6){const _0x234a5b=_0x127fb8;return _0x44c6d6[_0x234a5b('0xca1')](_0x234a5b('0x20c2'))?null:_0x2bd0b3['resolve'](_0x234a5b('0x1464'),{'fields':'id,name,crudPermissions','id':_0x44c6d6[_0x234a5b('0x20b2')]()[_0x234a5b('0x2f')]});}],'userProfileSection':['apiResolver','Auth',function(_0x2f3310,_0x5cfccc){const _0x2e9002=_0x127fb8;return _0x5cfccc[_0x2e9002('0xca1')](_0x2e9002('0x20c2'))?null:_0x2f3310[_0x2e9002('0xed7')]('userProfileSection@get',{'fields':_0x2e9002('0x1f47'),'userProfileId':_0x5cfccc[_0x2e9002('0x20b2')]()[_0x2e9002('0x2f')],'sectionId':0x195});}]},'authenticate':!![],'permissionId':0x195,'bodyClass':_0x127fb8('0xcf2')})['state'](_0x127fb8('0x238a'),{'url':'/voicemails','views':{'content@app':{'templateUrl':_0x1a4517,'controller':_0x127fb8('0x1a15')}},'resolve':{'voicemails':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x3f7188,_0x12d1d1){const _0x3186c9=_0x127fb8;return _0x12d1d1['hasRole'](_0x3186c9('0x20c2'))?_0x3f7188[_0x3186c9('0xed7')](_0x3186c9('0xacf'),{'fields':'createdAt,updatedAt,id,customer_id,fullname,email,password,mailbox,context,tz,attach,envelope,delete,emailbody,emailsubject,maxsecs,maxmsg','sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x3f7188['resolve'](_0x3186c9('0x191b'),{'id':_0x12d1d1[_0x3186c9('0x20b2')]()[_0x3186c9('0x2f')],'section':_0x3186c9('0x1a4a'),'fields':_0x3186c9('0x10b8'),'sort':_0x3186c9('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x513310,_0x559b8a){const _0x5e287b=_0x127fb8;return _0x559b8a[_0x5e287b('0xca1')](_0x5e287b('0x20c2'))?null:_0x513310[_0x5e287b('0xed7')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x559b8a[_0x5e287b('0x20b2')]()[_0x5e287b('0x2f')]});}],'userProfileSection':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x3001ff,_0x43cc69){const _0x46994a=_0x127fb8;return _0x43cc69[_0x46994a('0xca1')]('admin')?null:_0x3001ff[_0x46994a('0xed7')](_0x46994a('0x360'),{'fields':_0x46994a('0x1f47'),'userProfileId':_0x43cc69[_0x46994a('0x20b2')]()[_0x46994a('0x2f')],'sectionId':0x196});}]},'authenticate':!![],'permissionId':0x196,'bodyClass':_0x127fb8('0xcf2')})[_0x127fb8('0x2598')]('app.voice.voicemails.edit',{'url':_0x127fb8('0x1560'),'params':{'voicemail':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x5e41e1,'controller':'VoicemailController\x20as\x20vm'}},'resolve':{'voicemail':[_0x127fb8('0x4b1'),_0x127fb8('0x8ea'),function(_0x125b19,_0x2b2091){const _0x214445=_0x127fb8;return _0x125b19[_0x214445('0xed7')](_0x214445('0xacf'),{'fields':_0x214445('0x10b8'),'id':_0x2b2091['id']});}],'userProfileSection':[_0x127fb8('0x4b1'),'Auth',function(_0x2f6321,_0x5aebd2){const _0x41acae=_0x127fb8;return _0x2f6321[_0x41acae('0xed7')]('userProfileSection@get',{'fields':_0x41acae('0x1f47'),'userProfileId':_0x5aebd2[_0x41acae('0x20b2')]()['userProfileId'],'sectionId':0x196});}]},'authenticate':!![],'permissionId':0x196,'bodyClass':_0x127fb8('0xcf2')})[_0x127fb8('0x2598')](_0x127fb8('0x1472'),{'url':_0x127fb8('0x45b'),'views':{'content@app':{'templateUrl':_0x18c20e,'controller':_0x127fb8('0x75f')}},'resolve':{'musiconholds':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x431447,_0x11d8e2){const _0x1c91bc=_0x127fb8;return _0x11d8e2[_0x1c91bc('0xca1')](_0x1c91bc('0x20c2'))?_0x431447[_0x1c91bc('0xed7')](_0x1c91bc('0x264e'),{'fields':_0x1c91bc('0x11ca'),'defaultEntry':_0x1c91bc('0x22bf'),'limit':0xa,'offset':0x0}):_0x431447[_0x1c91bc('0xed7')](_0x1c91bc('0x191b'),{'id':_0x11d8e2['getCurrentUser']()[_0x1c91bc('0x2f')],'section':_0x1c91bc('0x27d2'),'fields':_0x1c91bc('0x11ca'),'defaultEntry':_0x1c91bc('0x22bf'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver','Auth',function(_0x27cbfc,_0x1b3598){const _0x4c78cc=_0x127fb8;return _0x1b3598['hasRole'](_0x4c78cc('0x20c2'))?null:_0x27cbfc['resolve'](_0x4c78cc('0x1464'),{'fields':_0x4c78cc('0x16f'),'id':_0x1b3598['getCurrentUser']()[_0x4c78cc('0x2f')]});}],'userProfileSection':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x2fa1bc,_0x46ce19){const _0x3e89c5=_0x127fb8;return _0x46ce19[_0x3e89c5('0xca1')](_0x3e89c5('0x20c2'))?null:_0x2fa1bc[_0x3e89c5('0xed7')](_0x3e89c5('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x46ce19[_0x3e89c5('0x20b2')]()[_0x3e89c5('0x2f')],'sectionId':0x197});}]},'authenticate':!![],'permissionId':0x197,'bodyClass':_0x127fb8('0xcf2')})[_0x127fb8('0x2598')](_0x127fb8('0x99e'),{'url':_0x127fb8('0x1560'),'params':{'musiconhold':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x3d5dc2,'controller':_0x127fb8('0x2012')}},'resolve':{'musiconhold':['apiResolver',_0x127fb8('0x8ea'),function(_0x5743f4,_0x19dd38){const _0x2725b4=_0x127fb8;return _0x5743f4[_0x2725b4('0xed7')]('voiceMusicOnHold@get',{'fields':_0x2725b4('0x11ca'),'id':_0x19dd38['id']});}],'userProfileSection':['apiResolver','Auth',function(_0x15bfe2,_0x5a8a38){const _0x23501c=_0x127fb8;return _0x15bfe2['resolve'](_0x23501c('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5a8a38[_0x23501c('0x20b2')]()[_0x23501c('0x2f')],'sectionId':0x197});}]},'authenticate':!![],'permissionId':0x197,'bodyClass':_0x127fb8('0xcf2')})[_0x127fb8('0x2598')](_0x127fb8('0x124f'),{'url':_0x127fb8('0x1396'),'views':{'content@app':{'templateUrl':_0x2c0f2b,'controller':'VoiceRecordingsController\x20as\x20vm'}},'resolve':{'voiceRecordings':[_0x127fb8('0x4b1'),'Auth',_0x127fb8('0x1cc2'),function(_0x4ce0cb,_0x31012f,_0x182846){const _0x11edec=_0x127fb8;return _0x31012f[_0x11edec('0xca1')](_0x11edec('0x20c2'))?_0x4ce0cb[_0x11edec('0xed7')](_0x11edec('0x1046'),{'fields':_0x11edec('0x1b08'),'sort':_0x11edec('0xc36'),'createdAt':_0x182846[_0x11edec('0x11c4')](),'limit':0xa,'offset':0x0}):_0x4ce0cb[_0x11edec('0xed7')](_0x11edec('0x191b'),{'id':_0x31012f['getCurrentUser']()['userProfileId'],'section':_0x11edec('0x1b76'),'fields':_0x11edec('0x1b08'),'sort':'-updatedAt','createdAt':_0x182846[_0x11edec('0x11c4')](),'limit':0xa,'offset':0x0});}],'userProfile':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x56d079,_0xcbec2f){const _0x1a3ef0=_0x127fb8;return _0xcbec2f[_0x1a3ef0('0xca1')](_0x1a3ef0('0x20c2'))?null:_0x56d079[_0x1a3ef0('0xed7')](_0x1a3ef0('0x1464'),{'fields':_0x1a3ef0('0x16f'),'id':_0xcbec2f[_0x1a3ef0('0x20b2')]()[_0x1a3ef0('0x2f')]});}],'userProfileSection':[_0x127fb8('0x4b1'),'Auth',function(_0x482d9f,_0x53a998){const _0xfa5a4b=_0x127fb8;return _0x53a998[_0xfa5a4b('0xca1')](_0xfa5a4b('0x20c2'))?null:_0x482d9f['resolve'](_0xfa5a4b('0x360'),{'fields':_0xfa5a4b('0x1f47'),'userProfileId':_0x53a998[_0xfa5a4b('0x20b2')]()[_0xfa5a4b('0x2f')],'sectionId':0x198});}]},'authenticate':!![],'permissionId':0x198,'bodyClass':'voice'})[_0x127fb8('0x2598')](_0x127fb8('0x1295'),{'url':'/:id?tab','params':{'voiceRecording':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x4253ba,'controller':_0x127fb8('0x1fbc')}},'resolve':{'voiceRecording':[_0x127fb8('0x4b1'),_0x127fb8('0x8ea'),function(_0x3f593c,_0x51e65a){const _0x33ad93=_0x127fb8;return _0x3f593c['resolve'](_0x33ad93('0x1046'),{'fields':_0x33ad93('0x1b08'),'id':_0x51e65a['id']});}],'userProfileSection':['apiResolver','Auth',function(_0x188c02,_0x43b34b){const _0x58e4b9=_0x127fb8;return _0x188c02[_0x58e4b9('0xed7')](_0x58e4b9('0x360'),{'fields':_0x58e4b9('0x1f47'),'userProfileId':_0x43b34b[_0x58e4b9('0x20b2')]()[_0x58e4b9('0x2f')],'sectionId':0x198});}]},'authenticate':!![],'permissionId':0x198,'bodyClass':_0x127fb8('0xcf2')})[_0x127fb8('0x2598')]('app.voice.chanSpies',{'url':'/chanSpies','views':{'content@app':{'templateUrl':_0x5c22a1,'controller':'ChanSpiesController\x20as\x20vm'}},'resolve':{'chanSpies':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x40703b,_0x2de226){const _0x3725da=_0x127fb8;return _0x2de226[_0x3725da('0xca1')](_0x3725da('0x20c2'))?_0x40703b['resolve']('voiceChanSpy@get',{'fields':'createdAt,updatedAt,id,name,prefix,options,auth,password,record,recordingFormat,description','sort':_0x3725da('0xc36'),'limit':0xa,'offset':0x0}):_0x40703b[_0x3725da('0xed7')](_0x3725da('0x191b'),{'id':_0x2de226[_0x3725da('0x20b2')]()[_0x3725da('0x2f')],'section':'ChanSpies','fields':_0x3725da('0x18e7'),'sort':_0x3725da('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x5ab320,_0x580538){const _0x4c948a=_0x127fb8;return _0x580538['hasRole'](_0x4c948a('0x20c2'))?null:_0x5ab320[_0x4c948a('0xed7')]('userProfile@get',{'fields':_0x4c948a('0x16f'),'id':_0x580538[_0x4c948a('0x20b2')]()[_0x4c948a('0x2f')]});}],'userProfileSection':[_0x127fb8('0x4b1'),'Auth',function(_0x685f98,_0x3ff833){const _0x746854=_0x127fb8;return _0x3ff833[_0x746854('0xca1')](_0x746854('0x20c2'))?null:_0x685f98['resolve'](_0x746854('0x360'),{'fields':_0x746854('0x1f47'),'userProfileId':_0x3ff833[_0x746854('0x20b2')]()['userProfileId'],'sectionId':0x199});}]},'authenticate':!![],'permissionId':0x199,'bodyClass':_0x127fb8('0xcf2')})[_0x127fb8('0x2598')](_0x127fb8('0x204'),{'url':_0x127fb8('0x16e2'),'views':{'content@app':{'templateUrl':_0x34d06f,'controller':_0x127fb8('0x1942')}},'resolve':{'voicePrefixes':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0xf1151a,_0x583a15){const _0x59321a=_0x127fb8;return _0x583a15[_0x59321a('0xca1')](_0x59321a('0x20c2'))?_0xf1151a[_0x59321a('0xed7')](_0x59321a('0x560'),{'fields':'createdAt,updatedAt,id,name,VoiceExtensionId,callerIdAll,description','limit':0xa,'offset':0x0}):_0xf1151a[_0x59321a('0xed7')](_0x59321a('0x191b'),{'id':_0x583a15[_0x59321a('0x20b2')]()[_0x59321a('0x2f')],'section':_0x59321a('0x2770'),'fields':'createdAt,updatedAt,id,name,VoiceExtensionId,callerIdAll,description','limit':0xa,'offset':0x0});}],'userProfile':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x51fe73,_0x595fc1){const _0x3835fd=_0x127fb8;return _0x595fc1[_0x3835fd('0xca1')](_0x3835fd('0x20c2'))?null:_0x51fe73[_0x3835fd('0xed7')](_0x3835fd('0x1464'),{'fields':'id,name,crudPermissions','id':_0x595fc1[_0x3835fd('0x20b2')]()[_0x3835fd('0x2f')]});}],'userProfileSection':[_0x127fb8('0x4b1'),_0x127fb8('0xba1'),function(_0x3e4c79,_0x140097){const _0x3976ad=_0x127fb8;return _0x140097[_0x3976ad('0xca1')]('admin')?null:_0x3e4c79[_0x3976ad('0xed7')](_0x3976ad('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x140097[_0x3976ad('0x20b2')]()[_0x3976ad('0x2f')],'sectionId':0x19a});}]},'authenticate':!![],'permissionId':0x19a,'bodyClass':_0x127fb8('0xcf2')}),_0xeebe4d['addPart'](_0x127fb8('0x805'));}angular[_0x189033('0x1e26')](_0x189033('0xa'),[_0x189033('0x6cf'),_0x189033('0x1ddb'),'md.data.table','flow',_0x189033('0x25fc'),'ckeditor',_0x189033('0x1d9c'),'ngAria',_0x189033('0x273d'),_0x189033('0x76'),'mwFormBuilder',_0x189033('0x7fa'),_0x189033('0x197b'),_0x189033('0x3b5'),_0x189033('0x153a'),_0x189033('0x1447'),_0x189033('0x2645'),'material.components.expansionPanels','chart.js',_0x189033('0x19da'),_0x189033('0x170b')])[_0x189033('0x272d')](_0x2e12f4)[_0x189033('0x1da3')](_0x189033('0x239a'),_0x3cb613)[_0x189033('0x1da3')](_0x189033('0x881'),_0x49036e)[_0x189033('0x1da3')](_0x189033('0xc92'),_0x5965f7)[_0x189033('0x1da3')](_0x189033('0x14ae'),_0x123221)[_0x189033('0x1da3')](_0x189033('0xd75'),_0x5eac23)[_0x189033('0x1da3')](_0x189033('0x6fc'),_0x5d7709)[_0x189033('0x1da3')]('EditInboundAppagiDialogController',_0x2ee738)[_0x189033('0x1da3')](_0x189033('0x26d8'),_0x1e9721)[_0x189033('0x1da3')]('EditInboundAppdialDialogController',_0xa68b82)['controller']('EditInboundAppexternaldialDialogController',_0x4da5aa)[_0x189033('0x1da3')](_0x189033('0x1986'),_0x23071d)[_0x189033('0x1da3')]('EditInboundApphangupDialogController',_0x5bfdbd)['controller']('EditInboundAppinternaldialDialogController',_0xbe0890)['controller'](_0x189033('0x2104'),_0x3b9d76)[_0x189033('0x1da3')](_0x189033('0xc13'),_0x5b19c7)[_0x189033('0x1da3')]('EditInboundAppqueueDialogController',_0x45583b)['controller'](_0x189033('0x15ae'),_0x468d4b)[_0x189033('0x1da3')]('EditInboundAppsetDialogController',_0x93d3b0)[_0x189033('0x1da3')](_0x189033('0x1063'),_0x4cb8cd)[_0x189033('0x1da3')](_0x189033('0xe7c'),_0x152bf7)['controller'](_0x189033('0x479'),_0x3bad3b)['controller']('CreateOrEditInternalRouteDialogController',_0x86a16b)[_0x189033('0x1da3')](_0x189033('0x2559'),_0x1191db)[_0x189033('0x1da3')](_0x189033('0x1f41'),_0x268270)[_0x189033('0x1da3')](_0x189033('0x3fe'),_0x56b6eb)[_0x189033('0x1da3')](_0x189033('0x7d5'),_0x4b51c4)[_0x189033('0x1da3')](_0x189033('0x14e9'),_0x242bc7)[_0x189033('0x1da3')](_0x189033('0x16c6'),_0x588315)[_0x189033('0x1da3')](_0x189033('0x374'),_0xea4c5f)[_0x189033('0x1da3')](_0x189033('0x524'),_0x46e69b)[_0x189033('0x1da3')](_0x189033('0xf35'),_0x327cac)['controller'](_0x189033('0x1384'),_0x4ed990)['controller'](_0x189033('0x8e5'),_0x48f865)['controller']('EditInternalAppringgroupDialogController',_0x56e786)['controller'](_0x189033('0x1635'),_0x1b2580)['controller']('EditInternalAppvoicemailDialogController',_0x394329)[_0x189033('0x1da3')](_0x189033('0xd1'),_0x5e8327)[_0x189033('0x1da3')](_0x189033('0xd98'),_0x2e1afc)[_0x189033('0x1da3')](_0x189033('0x52e'),_0x45af5b)[_0x189033('0x1da3')](_0x189033('0x2bf'),_0xe672e9)[_0x189033('0x1da3')]('CreateOrEditMohSoundDialogController',_0x394a65)['controller'](_0x189033('0x1f67'),_0x5b9865)[_0x189033('0x1da3')](_0x189033('0x2180'),_0x68f669),angular['module'](_0x189033('0xa'))['controller']('CreateOrEditOutboundRouteDialogController',_0xf653c7)[_0x189033('0x1da3')]('OutboundRouteActionsController',_0x18e709)[_0x189033('0x1da3')](_0x189033('0x179b'),_0x3f9c71)[_0x189033('0x1da3')](_0x189033('0x17d6'),_0x514ac3)[_0x189033('0x1da3')](_0x189033('0x6ed'),_0x1435d8)['controller'](_0x189033('0x244d'),_0x397329)[_0x189033('0x1da3')](_0x189033('0x286d'),_0x4375f0)[_0x189033('0x1da3')](_0x189033('0x135a'),_0x84fe0)['controller']('VoicemailMessagesController',_0x45bc02)[_0x189033('0x1da3')]('VoicemailController',_0x3bc2be)[_0x189033('0x1da3')]('VoicemailsController',_0x5cfc17)[_0x189033('0x1da3')](_0x189033('0x1950'),_0x124941)[_0x189033('0x1da3')]('voicePrefixagentaddController',_0x18c34c)['controller'](_0x189033('0x306'),_0x1c0ef2)[_0x189033('0x1da3')](_0x189033('0x2306'),_0x1bc96f)[_0x189033('0x1da3')](_0x189033('0x1599'),_0x458e72)[_0x189033('0x1da3')]('VoiceQueueteamaddController',_0x3b852c)[_0x189033('0x1da3')](_0x189033('0x1b2a'),_0x32fa8f)[_0x189033('0x1da3')]('VoiceQueuesController',_0x1a3fbd)[_0x189033('0x1da3')](_0x189033('0x1d0d'),_0x485bac)[_0x189033('0x1da3')]('VoiceRecordingSentimentStatisticsController',_0x44f6eb)[_0x189033('0x1da3')](_0x189033('0x1cf1'),_0x170a56)[_0x189033('0x1da3')](_0x189033('0x47c'),_0x39902b);const _0x303764=_0x180212['p']+'src/js/modules/main/apps/chat/views/chatQueues/chatQueues.html/chatQueues.html',_0x2897a7=_0x180212['p']+_0x189033('0x22e3'),_0x4cc511=_0x180212['p']+_0x189033('0x8e3'),_0x53c5fb=_0x180212['p']+_0x189033('0xc80'),_0x4c3976=_0x180212['p']+'src/js/modules/main/apps/chat/views/realtime/realtime.html/realtime.html',_0x2a4839=_0x180212['p']+'src/js/modules/main/apps/chat/views/realtime/agents/view.html/view.html',_0x1bdab8=_0x180212['p']+'src/js/modules/main/apps/chat/views/realtime/queues/view.html/view.html';_0x3267ca[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$q',_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x241e'),'pauses',_0x189033('0x756'),_0x189033('0x127b'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0xa72'),_0x189033('0x2a'),'userProfileSection',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x1b27')];function _0x3267ca(_0x170eb1,_0xd2b84a,_0x48488e,_0x21147a,_0x6db430,_0x1e833e,_0x2a5900,_0x1de5e5,_0x42297d,_0x474674,_0x2619f5,_0x8666d0,_0x1fc24f,_0x156a11,_0xa4ff75,_0x42f0ac,_0x22825e,_0x83e0bd){const _0x339404=_0x189033,_0x4684e3=this,_0x3c3561=[_0x339404('0xef9'),'online',_0x339404('0x10f'),'lastPauseAt',_0x339404('0x17fe'),_0x339404('0x8cc'),_0x339404('0x1d43'),_0x339404('0x2050'),_0x339404('0x1938'),_0x339404('0x1a11'),_0x339404('0x774'),'smsPause','whatsappPause',_0x339404('0x716'),_0x339404('0x1431'),_0x339404('0xd2a'),_0x339404('0x218'),_0x339404('0x2409'),_0x339404('0x205'),_0x339404('0x1484'),_0x339404('0x1079'),_0x339404('0x153b'),'openchannelCurrentCapacity',_0x339404('0x15c1'),_0x339404('0x1902'),_0x339404('0xaba'),_0x339404('0x157f'),_0x339404('0x1487'),_0x339404('0x2a8'),_0x339404('0xb90'),_0x339404('0x2787'),_0x339404('0x2512'),_0x339404('0x278b'),'voiceStatus',_0x339404('0x1a03'),_0x339404('0x15db'),'mailStatusTime','smsStatusTime',_0x339404('0x17c2'),_0x339404('0x21d1'),_0x339404('0x23b4'),'queue',_0x339404('0x10f5'),_0x339404('0xd70'),_0x339404('0xa31'),_0x339404('0x2259')],_0x1939d7=[_0x339404('0x1938'),_0x339404('0x1a11'),_0x339404('0x774'),'smsPause',_0x339404('0x185d'),_0x339404('0x716'),_0x339404('0x1431'),_0x339404('0x2309')];_0x4684e3[_0x339404('0x11ed')]=_0x42f0ac[_0x339404('0x20b2')](),_0x4684e3[_0x339404('0x24d2')]=[_0x339404('0x2727'),'inuse','busy',_0x339404('0x1026'),_0x339404('0x79')],_0x4684e3['pauses']=_0x2a5900||{'count':0x0,'rows':[]},_0x4684e3['license']=_0x22825e,_0x4684e3[_0x339404('0x2a')]=_0x156a11,_0x4684e3[_0x339404('0x22df')]=_0xa4ff75&&_0xa4ff75['count']==0x1?_0xa4ff75[_0x339404('0xf5d')][0x0]:null,_0x4684e3[_0x339404('0x1134')]=_0x42f0ac[_0x339404('0x142a')](_0x4684e3[_0x339404('0x22df')]?_0x4684e3[_0x339404('0x22df')][_0x339404('0x1134')]:null),_0x4684e3['agents']=_0x1de5e5?_0x2e3ca0()[_0x339404('0x24db')](_0x1de5e5[_0x339404('0xf5d')]?_0x1de5e5['rows']:[],'id'):{},_0x4684e3[_0x339404('0x127b')]=_0x42297d?_0x2e3ca0()[_0x339404('0x24db')](_0x42297d[_0x339404('0xf5d')]?_0x42297d[_0x339404('0xf5d')]:[],'id'):{},_0x4684e3[_0x339404('0x20d5')]={},_0x4684e3[_0x339404('0x182c')]=![],_0x4684e3[_0x339404('0x150d')]=[],_0x4684e3['agentInternal']={};for(const _0x5bdb16 in _0x4684e3[_0x339404('0x756')]){typeof _0x4684e3[_0x339404('0x756')][_0x5bdb16]!=='undefined'&&(_0x4684e3[_0x339404('0x756')][_0x5bdb16][_0x339404('0x12f3')]=!![]);}_0x4684e3['query']={'limit':0xa,'page':0x1,'order':_0x339404('0x11bc'),'globalStatusFilter':'','pauseTypeFilter':''},_0x4684e3[_0x339404('0x1999')]=_0x222ca9,_0x4684e3['queueAdd']=_0x4f4766,_0x4684e3[_0x339404('0xa4')]=_0x37a905,_0x4684e3[_0x339404('0x70e')]=_0x1c13e9,_0x4684e3[_0x339404('0x411')]=_0x569dcd,_0x4684e3['getAgentStatus']=_0x454f7b,_0x4684e3[_0x339404('0x1bf4')]=_0x3fb12d,_0x4684e3[_0x339404('0x3ee')]=_0x3c07ca,_0x4684e3[_0x339404('0x2678')]=_0x3b0e71,_0x4684e3[_0x339404('0x1f68')]=_0x2faa12,_0x4684e3[_0x339404('0x2819')]=_0x3fab00,_0x4684e3[_0x339404('0x1418')]=_0x168b9b,_0x4684e3[_0x339404('0x1dd2')]=_0x4d8fb7,_0x4684e3['onConnect']=_0x386ab6,_0x4684e3[_0x339404('0x2250')]=_0x475996,_0x4684e3[_0x339404('0x1f6c')]=_0x14737f,_0x2619f5['on'](_0x339404('0x18f0'),_0x4684e3['onSave']),_0x2619f5['on']('user:update',_0x4684e3[_0x339404('0x1418')]),_0x2619f5['on'](_0x339404('0x216d'),_0x4684e3[_0x339404('0x16b6')]),_0x2619f5['on'](_0x339404('0x3b6'),_0x4684e3[_0x339404('0x2250')]),_0x4d8fb7();let _0x1166fb=_0x83e0bd(function(){const _0x4ad88e=_0x339404;_0x4684e3[_0x4ad88e('0x182c')]&&(_0x4684e3['load']=![],_0x4d8fb7());},0x3e7);function _0x4d8fb7(){const _0x5bd14d=_0x339404;_0x4684e3[_0x5bd14d('0x182c')]=![];const _0x30671e=_0xd2b84a[_0x5bd14d('0x448')]();_0x4684e3[_0x5bd14d('0x1883')]=_0x30671e[_0x5bd14d('0x1883')],_0x4684e3[_0x5bd14d('0xdf9')]=[],_0x4684e3[_0x5bd14d('0x150d')]=[],_0x2e3ca0()['forIn'](_0x4684e3[_0x5bd14d('0x756')],function(_0x355f0c,_0x2b9ce4){const _0x123ce1=_0x5bd14d;_0x4684e3[_0x123ce1('0x127b')][_0x2b9ce4]&&_0x2e3ca0()['merge'](_0x355f0c,_0x2e3ca0()[_0x123ce1('0x24d0')](_0x2e3ca0()['omit'](_0x4684e3[_0x123ce1('0x127b')][_0x2b9ce4],_0x1939d7),_0x3c3561)),_0x3fb12d(_0x355f0c),_0x355f0c[_0x123ce1('0x2309')]?(_0x4684e3[_0x123ce1('0xdf9')]['push'](_0x355f0c),_0x4684e3[_0x123ce1('0x7c6')][_0x355f0c[_0x123ce1('0x1d43')]]=_0x2b9ce4):_0x355f0c['globalStatusTime']=_0x2e3ca0()[_0x123ce1('0xea3')](_0x1aaf93()()[_0x123ce1('0x26dd')]('x'));});_0x4684e3[_0x5bd14d('0x23a2')][_0x5bd14d('0x1102')]&&_0x2e3ca0()[_0x5bd14d('0x3ec')](_0x4684e3[_0x5bd14d('0xdf9')],function(_0x145384){const _0xa8c72=_0x5bd14d;return _0x145384[_0xa8c72('0x12fa')]!==_0x4684e3[_0xa8c72('0x23a2')][_0xa8c72('0x1102')];});_0x4684e3[_0x5bd14d('0x23a2')]['pauseTypeFilter']&&_0x2e3ca0()[_0x5bd14d('0x3ec')](_0x4684e3[_0x5bd14d('0xdf9')],function(_0x5adefc){const _0x33f16a=_0x5bd14d;return _0x5adefc[_0x33f16a('0x17fe')]!==_0x4684e3[_0x33f16a('0x23a2')][_0x33f16a('0x1606')];});_0x4684e3[_0x5bd14d('0x23a2')][_0x5bd14d('0x25')]&&_0x2e3ca0()[_0x5bd14d('0x3ec')](_0x4684e3[_0x5bd14d('0xdf9')],function(_0x3b7ead){const _0x328f07=_0x5bd14d;return _0x3b7ead[_0x328f07('0x11bc')][_0x328f07('0x93a')]()[_0x328f07('0x824')](_0x4684e3['query'][_0x328f07('0x25')]['toLowerCase']())<0x0;});_0x4684e3[_0x5bd14d('0xdf9')]=_0xcfdac1(_0x4684e3[_0x5bd14d('0xdf9')]);const _0x4e9c90=(_0x4684e3['query'][_0x5bd14d('0xdf8')]-0x1)*_0x4684e3[_0x5bd14d('0x23a2')][_0x5bd14d('0x6f0')];_0x4684e3['paginatedAgents']=_0x2e3ca0()[_0x5bd14d('0x16b7')](_0x4684e3['filteredAgents'],_0x4e9c90)['slice'](0x0,_0x4684e3['query'][_0x5bd14d('0x6f0')]);for(let _0x16d1af=0x0;_0x16d1af<_0x4684e3['paginatedAgents']['length'];_0x16d1af+=0x1){_0x4684e3[_0x5bd14d('0x150d')]['push'](_0x4684e3[_0x5bd14d('0x20d5')][_0x16d1af]['id']);}_0x30671e[_0x5bd14d('0xed7')](),_0x4684e3['load']=!![];}function _0x3fab00(_0x422790){const _0x486ca7=_0x339404;_0x4684e3[_0x486ca7('0x756')][_0x422790['id']]&&(_0x2e3ca0()['merge'](_0x4684e3[_0x486ca7('0x756')][_0x422790['id']],_0x2e3ca0()['pick'](_0x2e3ca0()[_0x486ca7('0x8b5')](_0x422790,_0x1939d7),_0x3c3561)),_0x2e3ca0()[_0x486ca7('0xf22')](_0x4684e3[_0x486ca7('0x127b')][_0x422790['id']],_0x2e3ca0()[_0x486ca7('0x24d0')](_0x2e3ca0()[_0x486ca7('0x8b5')](_0x422790,_0x1939d7),_0x3c3561)),_0x3fb12d(_0x4684e3['agents'][_0x422790['id']]));}function _0x168b9b(_0x7c9e8f){const _0x1375cc=_0x339404;_0x4684e3[_0x1375cc('0x756')][_0x7c9e8f['id']]&&(_0x2e3ca0()['merge'](_0x4684e3[_0x1375cc('0x756')][_0x7c9e8f['id']],_0x2e3ca0()['pick'](_0x7c9e8f,_0x3c3561)),_0x2e3ca0()[_0x1375cc('0xf22')](_0x4684e3[_0x1375cc('0x127b')][_0x7c9e8f['id']],_0x2e3ca0()['pick'](_0x7c9e8f,_0x3c3561)),_0x7c9e8f['lastPauseAt']&&(_0x4684e3[_0x1375cc('0x756')][_0x7c9e8f['id']][_0x1375cc('0x24d')]=_0x7c9e8f[_0x1375cc('0x8cc')],_0x4684e3['rpcAgents'][_0x7c9e8f['id']][_0x1375cc('0x24d')]=_0x7c9e8f['lastPauseAt']),_0x3fb12d(_0x4684e3['agents'][_0x7c9e8f['id']]));}function _0x386ab6(_0x1d79ac){const _0xcd9e49=_0x339404;_0x4684e3[_0xcd9e49('0x756')][_0x4684e3[_0xcd9e49('0x7c6')][_0x1d79ac['destaccountcode']]]&&(_0x2e3ca0()['merge'](_0x4684e3[_0xcd9e49('0x756')][_0x4684e3[_0xcd9e49('0x7c6')][_0x1d79ac[_0xcd9e49('0x1d79')]]],_0x2e3ca0()['pick'](_0x1d79ac,[_0xcd9e49('0x660'),_0xcd9e49('0x10f5')])),_0x2e3ca0()['merge'](_0x4684e3[_0xcd9e49('0x127b')][_0x4684e3['agentInternal'][_0x1d79ac[_0xcd9e49('0x1d79')]]],_0x2e3ca0()[_0xcd9e49('0x24d0')](_0x1d79ac,['queue',_0xcd9e49('0x10f5')])));}function _0x475996(_0x52d69c){const _0x3ba9d9=_0x339404;_0x4684e3[_0x3ba9d9('0x756')][_0x4684e3[_0x3ba9d9('0x7c6')][_0x52d69c['destaccountcode']]]&&(_0x4684e3[_0x3ba9d9('0x756')][_0x4684e3[_0x3ba9d9('0x7c6')][_0x52d69c[_0x3ba9d9('0x1d79')]]]=_0x2e3ca0()[_0x3ba9d9('0x8b5')](_0x4684e3['agents'][_0x4684e3[_0x3ba9d9('0x7c6')][_0x52d69c[_0x3ba9d9('0x1d79')]]],[_0x3ba9d9('0x660'),_0x3ba9d9('0x10f5')]),_0x4684e3['rpcAgents'][_0x4684e3[_0x3ba9d9('0x7c6')][_0x52d69c['destaccountcode']]]=_0x2e3ca0()[_0x3ba9d9('0x8b5')](_0x4684e3[_0x3ba9d9('0x127b')][_0x4684e3[_0x3ba9d9('0x7c6')][_0x52d69c[_0x3ba9d9('0x1d79')]]],['queue',_0x3ba9d9('0x10f5')]));}function _0x222ca9(_0x471998){const _0x1a3318=_0x339404;return _0x474674[_0x1a3318('0xc96')][_0x1a3318('0x1999')]({'id':_0x471998['id'],'device':_0x1a3318('0x2c9'),'agent_id':_0x471998['id'],'agent_name':_0x471998[_0x1a3318('0x60a')]})[_0x1a3318('0xe53')][_0x1a3318('0x683')](function(){const _0x24185e=_0x1a3318;_0x8666d0['success']({'title':_0x24185e('0x1683'),'msg':_0x471998[_0x24185e('0x11bc')]+_0x24185e('0x2488')}),_0x4684e3[_0x24185e('0x756')][_0x471998['id']]&&(_0x4684e3[_0x24185e('0x756')][_0x471998['id']][_0x24185e('0x2309')]=![]),_0x4684e3['rpcAgents'][_0x471998['id']]&&(_0x4684e3['rpcAgents'][_0x471998['id']]['online']=![]),_0x4d8fb7();})['catch'](function(_0x584785){const _0x3741b9=_0x1a3318;_0x8666d0['error']({'title':_0x584785[_0x3741b9('0x13ee')]?_0x3741b9('0x2168')+_0x584785[_0x3741b9('0x13ee')]+'\x20-\x20'+_0x584785[_0x3741b9('0x24a9')]:'api.staff.save','msg':_0x584785[_0x3741b9('0x5a5')]?JSON['stringify'](_0x584785['data'][_0x3741b9('0x8c2')]):_0x584785[_0x3741b9('0x1ff0')]()});});}function _0x37a905(_0xa4d8fc,_0x58264d){const _0x257c0c=_0x339404;return _0x474674['user'][_0x257c0c('0xa4')]({'id':_0xa4d8fc['id'],'type':_0x58264d})[_0x257c0c('0xe53')]['then'](function(_0x186920){const _0x558931=_0x257c0c;_0x4684e3[_0x558931('0x756')][_0xa4d8fc['id']]&&_0x2e3ca0()[_0x558931('0xf22')](_0x4684e3['agents'][_0xa4d8fc['id']],_0x2e3ca0()[_0x558931('0x24d0')](_0x186920,_0x3c3561)),_0x4684e3['rpcAgents'][_0xa4d8fc['id']]&&_0x2e3ca0()[_0x558931('0xf22')](_0x4684e3[_0x558931('0x127b')][_0xa4d8fc['id']],_0x2e3ca0()[_0x558931('0x24d0')](_0x186920,_0x3c3561)),_0x3fb12d(_0x4684e3[_0x558931('0x756')][_0xa4d8fc['id']]);})[_0x257c0c('0x130a')](function(_0x194cc8){const _0x2c2748=_0x257c0c;_0x8666d0[_0x2c2748('0x52a')]({'title':_0x194cc8['status']?_0x2c2748('0x2168')+_0x194cc8[_0x2c2748('0x13ee')]+_0x2c2748('0xbf6')+_0x194cc8[_0x2c2748('0x24a9')]:_0x2c2748('0x154f'),'msg':_0x194cc8[_0x2c2748('0x5a5')]?JSON['stringify'](_0x194cc8['data'][_0x2c2748('0x8c2')]):_0x194cc8[_0x2c2748('0x1ff0')]()});});}function _0x1c13e9(_0x30c0f5){const _0x5427cf=_0x339404;return _0x474674[_0x5427cf('0xc96')]['unpause']({'id':_0x30c0f5['id']})[_0x5427cf('0xe53')][_0x5427cf('0x683')](function(_0x4fd3c5){const _0x3b7a75=_0x5427cf;_0x4684e3['agents'][_0x30c0f5['id']]&&_0x2e3ca0()[_0x3b7a75('0xf22')](_0x4684e3['agents'][_0x30c0f5['id']],_0x2e3ca0()[_0x3b7a75('0x24d0')](_0x4fd3c5,_0x3c3561)),_0x4684e3['rpcAgents'][_0x30c0f5['id']]&&_0x2e3ca0()[_0x3b7a75('0xf22')](_0x4684e3[_0x3b7a75('0x127b')][_0x30c0f5['id']],_0x2e3ca0()[_0x3b7a75('0x24d0')](_0x4fd3c5,_0x3c3561)),_0x3fb12d(_0x4684e3['agents'][_0x30c0f5['id']]);})['catch'](function(_0x287cfd){const _0x375c01=_0x5427cf;_0x8666d0[_0x375c01('0x52a')]({'title':_0x287cfd[_0x375c01('0x13ee')]?_0x375c01('0x2168')+_0x287cfd[_0x375c01('0x13ee')]+_0x375c01('0xbf6')+_0x287cfd[_0x375c01('0x24a9')]:_0x375c01('0x154f'),'msg':_0x287cfd[_0x375c01('0x5a5')]?JSON[_0x375c01('0x258a')](_0x287cfd[_0x375c01('0x5a5')]['message']):_0x287cfd['toString']()});});}function _0x569dcd(_0x572cc4){const _0x514f35=_0x339404;_0x21147a[_0x514f35('0x1d4')](_0x21147a['alert']()[_0x514f35('0x188f')](!![])[_0x514f35('0xf28')]('Legend')[_0x514f35('0x26e3')]('
TODO\x20legend\x20status\x20+\x20state
')['ok']('Ok')[_0x514f35('0xe42')](_0x572cc4));}function _0x4f4766(_0x51a7bd,_0x376c39){const _0x4a1d4b=_0x339404;_0x21147a[_0x4a1d4b('0x1d4')]({'controller':_0x4a1d4b('0x1e85'),'controllerAs':'vm','templateUrl':_0xf3687b,'parent':angular[_0x4a1d4b('0x1fcc')](_0x6db430[_0x4a1d4b('0x18e5')]),'targetEvent':_0x376c39,'clickOutsideToClose':!![],'locals':{'agent':_0x51a7bd,'agents':[],'channel':_0x4a1d4b('0x24e'),'direction':'inbound','crudPermissions':_0x4684e3[_0x4a1d4b('0x1134')]}});}function _0x3c07ca(_0x5a001c){const _0x17937d=_0x339404;return _0x5a001c===_0x17937d('0xa4')||_0x5a001c==='*pause';}function _0x3b0e71(_0x3ec392){const _0x5c7ec5=_0x339404;return _0x3ec392===_0x5c7ec5('0xa4');}function _0x2faa12(_0x26ec6b){const _0x3bb8cd=_0x339404;return _0x26ec6b===_0x3bb8cd('0x651');}function _0x5bdae7(_0x4c7c30){const _0x162586=_0x339404;return _0x4c7c30===_0x162586('0x1586')||_0x4c7c30===_0x162586('0xdd4')||_0x4c7c30===_0x162586('0x19d2')||_0x4c7c30===_0x162586('0x2727')||_0x2e3ca0()[_0x162586('0x8f2')](_0x4c7c30);}function _0x454f7b(_0x1f9bc8,_0x4a5bda){const _0x2e0c7d=_0x339404;if(_0x4a5bda===_0x2e0c7d('0xcf2')){if(_0x1f9bc8[_0x4a5bda+_0x2e0c7d('0x1d9d')]!==_0x2e0c7d('0x1586'))return _0x1f9bc8[_0x4a5bda+_0x2e0c7d('0x1d9d')];if(_0x1f9bc8[_0x4a5bda+_0x2e0c7d('0x2113')])return _0x1f9bc8[_0x4a5bda+_0x2e0c7d('0x1d9d')]=_0x2e0c7d('0xa4'),'pause';return _0x2e0c7d('0x1586');}else{if(_0x1f9bc8[_0x4a5bda+_0x2e0c7d('0x2113')])return _0x1f9bc8[_0x4a5bda+_0x2e0c7d('0x1d9d')]=_0x2e0c7d('0xa4'),_0x2e0c7d('0xa4');return _0x1f9bc8[_0x4a5bda+'Status'];}}function _0x3fb12d(_0x223e42){const _0x4aef08=_0x339404;let _0x205603=_0x4aef08('0xdd4');if(_0x2e3ca0()[_0x4aef08('0x161')]([_0x454f7b(_0x223e42,_0x4aef08('0xcf2')),_0x454f7b(_0x223e42,'chat'),_0x454f7b(_0x223e42,_0x4aef08('0x129f')),_0x454f7b(_0x223e42,'openchannel'),_0x454f7b(_0x223e42,_0x4aef08('0x1285')),_0x454f7b(_0x223e42,'whatsapp'),_0x454f7b(_0x223e42,_0x4aef08('0x23e9'))],_0x3c07ca))_0x205603='pause';else{if(_0x2e3ca0()['some']([_0x454f7b(_0x223e42,'voice'),_0x454f7b(_0x223e42,'chat'),_0x454f7b(_0x223e42,_0x4aef08('0x129f')),_0x454f7b(_0x223e42,_0x4aef08('0x1261')),_0x454f7b(_0x223e42,'sms'),_0x454f7b(_0x223e42,'whatsapp'),_0x454f7b(_0x223e42,_0x4aef08('0x23e9'))],_0x3c07ca))_0x205603='*pause';else _0x2e3ca0()['every']([_0x454f7b(_0x223e42,_0x4aef08('0xcf2')),_0x454f7b(_0x223e42,_0x4aef08('0x24e')),_0x454f7b(_0x223e42,_0x4aef08('0x129f')),_0x454f7b(_0x223e42,_0x4aef08('0x1261')),_0x454f7b(_0x223e42,_0x4aef08('0x1285')),_0x454f7b(_0x223e42,_0x4aef08('0x16e7')),_0x454f7b(_0x223e42,'fax')],_0x5bdae7)?_0x205603=_0x4aef08('0x1586'):_0x205603=_0x4aef08('0x63');}_0x223e42['globalStatus']!==_0x205603&&(_0x223e42[_0x4aef08('0x12fa')]=_0x205603,_0x223e42[_0x4aef08('0x12f3')]?(_0x223e42[_0x4aef08('0x12f3')]=![],_0x223e42['globalStatusTime']=_0x3c07ca(_0x205603)?_0x2e3ca0()[_0x4aef08('0xea3')](_0x1aaf93()(_0x223e42[_0x4aef08('0x8cc')])['format']('x')):_0x2e3ca0()[_0x4aef08('0x69b')]([_0x223e42[_0x4aef08('0x23b4')],_0x223e42[_0x4aef08('0x1a03')],_0x223e42['mailStatusTime'],_0x223e42[_0x4aef08('0x1a70')],_0x223e42['whatsappStatusTime'],_0x223e42[_0x4aef08('0x15db')],_0x223e42[_0x4aef08('0x21d1')]])):_0x223e42[_0x4aef08('0x24d')]=_0x2e3ca0()[_0x4aef08('0xea3')](_0x1aaf93()()[_0x4aef08('0x26dd')]('x')));}function _0xcfdac1(_0x55ae7f){const _0x29553c=_0x339404,_0x43eacd=_0x2e3ca0()[_0x29553c('0x18ad')](_0x4684e3[_0x29553c('0x23a2')][_0x29553c('0x150d')],'-')?_0x29553c('0x1f5a'):_0x29553c('0xe38');return _0x2e3ca0()['orderBy'](_0x55ae7f,[_0x4684e3['query'][_0x29553c('0x150d')][_0x29553c('0x1725')]('-','')],[_0x43eacd]);}function _0x4b6683(){_0x1166fb&&(_0x83e0bd['cancel'](_0x1166fb),_0x1166fb=null);}function _0x14737f(_0x154f0b,_0x125258){const _0x2b78ce=_0x339404;return _0x474674['user'][_0x2b78ce('0x2480')]({'id':_0x154f0b['id']},{'screenrecording':_0x125258})['$promise'][_0x2b78ce('0x130a')](function(_0x590752){const _0x2067b1=_0x2b78ce;_0x8666d0[_0x2067b1('0x52a')]({'title':_0x590752[_0x2067b1('0x13ee')]?_0x2067b1('0x2168')+_0x590752[_0x2067b1('0x13ee')]+_0x2067b1('0xbf6')+_0x590752[_0x2067b1('0x24a9')]:_0x2067b1('0x162b'),'msg':_0x590752[_0x2067b1('0x5a5')]?JSON[_0x2067b1('0x258a')](_0x590752[_0x2067b1('0x5a5')][_0x2067b1('0x8c2')]):_0x590752[_0x2067b1('0x1ff0')]()});});}_0x170eb1[_0x339404('0x26a2')](_0x339404('0x4b8'),function(){const _0x8e4a37=_0x339404;_0x2619f5[_0x8e4a37('0x1b9e')](_0x8e4a37('0x18f0')),_0x2619f5[_0x8e4a37('0x1b9e')](_0x8e4a37('0x2719')),_0x2619f5[_0x8e4a37('0x1b9e')](_0x8e4a37('0x216d')),_0x2619f5[_0x8e4a37('0x1b9e')]('user:agentcomplete'),_0x4b6683();});}const _0x52cbd0=_0x3267ca,_0x3b33b7=_0x180212['p']+_0x189033('0x10a0'),_0x54d9f2=_0x180212['p']+_0x189033('0xb5b');_0xbf0435[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$q',_0x189033('0x16ea'),_0x189033('0x1b27'),_0x189033('0x2da'),_0x189033('0x1a10'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x2a'),'userProfileSection',_0x189033('0xba1')];function _0xbf0435(_0x2a0196,_0x132aed,_0x51e954,_0x132293,_0x10d27c,_0x4210b1,_0x2563e8,_0x12682d,_0x1c543f,_0xf72e0d,_0x32f77e,_0x91c6c8,_0x2106e1,_0x2ae8e3){const _0x576739=_0x189033,_0x2605af=this,_0x58769b=[_0x576739('0x1506'),_0x576739('0x8bb'),_0x576739('0x1386'),_0x576739('0x7a4'),_0x576739('0x17f2'),_0x576739('0x1a95'),_0x576739('0x8c2'),'dialActive','dialMethod',_0x576739('0x17c1'),_0x576739('0x1a1d')];_0x2605af[_0x576739('0x11ed')]=_0x2ae8e3[_0x576739('0x20b2')](),_0x2605af['count']=_0x2563e8[_0x576739('0x50d')]?_0x2563e8[_0x576739('0x50d')]:0x0,_0x2605af[_0x576739('0x2da')]=_0x2563e8?_0x2e3ca0()['keyBy'](_0x2563e8['rows']?_0x2563e8[_0x576739('0xf5d')]:[],'id'):{},_0x2605af[_0x576739('0x1a10')]=_0x12682d?_0x2e3ca0()[_0x576739('0x24db')](_0x12682d[_0x576739('0xf5d')]?_0x12682d[_0x576739('0xf5d')]:[],'id'):{},_0x2605af[_0x576739('0x2a')]=_0x91c6c8,_0x2605af['userProfileSection']=_0x2106e1&&_0x2106e1[_0x576739('0x50d')]==0x1?_0x2106e1[_0x576739('0xf5d')][0x0]:null,_0x2605af[_0x576739('0x1134')]=_0x2ae8e3[_0x576739('0x142a')](_0x2605af[_0x576739('0x22df')]?_0x2605af['userProfileSection'][_0x576739('0x1134')]:null);_0x2ae8e3[_0x576739('0xca1')]('admin')?_0x2605af[_0x576739('0x23a2')]={'type':_0x576739('0x1535'),'sort':_0x576739('0xc36'),'limit':0xa,'page':0x1}:_0x2605af[_0x576739('0x23a2')]={'id':_0x2605af[_0x576739('0x11ed')]['id'],'channel':_0x576739('0x24e'),'type':_0x576739('0x1535'),'sort':'-updatedAt','limit':0xa,'page':0x1};_0x2605af['success']=_0x5aff8e,_0x2605af[_0x576739('0x4c9')]=_0x5b5862,_0x2605af[_0x576739('0x260b')]=_0x1cb95f,_0x2605af[_0x576739('0x1a94')]=_0x6b75e3,_0x2605af[_0x576739('0x1f7c')]=_0x4adccf,_0x2605af[_0x576739('0x2819')]=_0x1d7813,_0x2605af[_0x576739('0x3ae')]=_0x2d745c,_0x2605af[_0x576739('0x203e')]=_0x46b5ef,_0x2605af[_0x576739('0x4a5')]=_0x41af2f,_0x2605af[_0x576739('0xd8b')]=_0x27b350,_0x2605af[_0x576739('0xb2b')]=_0x390918,_0x2605af[_0x576739('0x3a8')]=_0x5c8430,_0x2605af['order']=[],_0x2e3ca0()[_0x576739('0x15d0')](_0x2605af['queues'],function(_0x105eee){const _0x431b38=_0x576739;_0x2605af[_0x431b38('0x150d')][_0x431b38('0x1fd0')](_0x105eee['id']);}),_0xf72e0d['on']('chat_queue:save',_0x2605af[_0x576739('0x2819')]),_0xf72e0d['on'](_0x576739('0x8db'),_0x2605af[_0x576739('0x3ae')]),_0xf72e0d['on'](_0x576739('0xba7'),_0x2605af[_0x576739('0x203e')]),_0xf72e0d['on']('user:update',_0x2605af[_0x576739('0x4a5')]),_0xf72e0d['on']('userVoiceQueue:remove',_0x2605af[_0x576739('0xb2b')]),_0xf72e0d['on'](_0x576739('0x217c'),_0x2605af['onLogin']);function _0x5c8430(){const _0x8a0bde=_0x576739,_0x319160=[];return _0x2e3ca0()[_0x8a0bde('0x15d0')](_0x2605af[_0x8a0bde('0x2da')],function(_0x51b768,_0x2443ae){const _0x326b57=_0x8a0bde;_0x51b768[_0x326b57('0x1a1d')]=0x0,_0x51b768['loggedInDb']=0x0,_0x2605af[_0x326b57('0x2da')][_0x2443ae][_0x326b57('0x756')]={},_0x319160[_0x326b57('0x1fd0')](_0x1c543f[_0x326b57('0x1524')][_0x326b57('0x27cf')]({'id':_0x2443ae})[_0x326b57('0xe53')]),_0x2605af[_0x326b57('0x1a10')][_0x2443ae]&&_0x2e3ca0()[_0x326b57('0xf22')](_0x51b768,_0x2e3ca0()['pick'](_0x2605af[_0x326b57('0x1a10')][_0x2443ae],_0x58769b));}),_0x132293['all'](_0x319160)[_0x8a0bde('0x683')](function(_0x135e4f){const _0x365030=_0x8a0bde;for(let _0x4c4a0a=0x0;_0x4c4a0a<_0x135e4f[_0x365030('0x1564')];_0x4c4a0a+=0x1){for(let _0x57eb50=0x0;_0x57eb50<_0x135e4f[_0x4c4a0a]['rows'][_0x365030('0x1564')];_0x57eb50++){_0x135e4f[_0x4c4a0a][_0x365030('0xf5d')][_0x57eb50][_0x365030('0x1a1d')]&&_0x2605af[_0x365030('0x2da')][_0x135e4f[_0x4c4a0a][_0x365030('0xf5d')][_0x57eb50][_0x365030('0x66')]][_0x365030('0x1a1d')]++,_0x2605af[_0x365030('0x2da')][_0x135e4f[_0x4c4a0a]['rows'][_0x57eb50][_0x365030('0x66')]][_0x365030('0x25a4')]++,_0x2605af['queues'][_0x135e4f[_0x4c4a0a][_0x365030('0xf5d')][_0x57eb50][_0x365030('0x66')]][_0x365030('0x756')][_0x135e4f[_0x4c4a0a]['rows'][_0x57eb50]['UserId']]=_0x135e4f[_0x4c4a0a][_0x365030('0xf5d')][_0x57eb50][_0x365030('0x66')];}}})['catch'](function(_0x26ad70){const _0x461ffd=_0x8a0bde;console[_0x461ffd('0x52a')](_0x26ad70);});}function _0x1d7813(_0x5aa520){const _0x26e60a=_0x576739;_0x2605af[_0x26e60a('0x2da')][_0x5aa520['id']]&&_0x2e3ca0()[_0x26e60a('0xf22')](_0x2605af[_0x26e60a('0x2da')][_0x5aa520['id']],_0x2e3ca0()[_0x26e60a('0x24d0')](_0x5aa520,_0x58769b));}function _0x2d745c(_0x16ddca){const _0x219ea2=_0x576739;_0x2605af[_0x219ea2('0x2da')][_0x16ddca[_0x219ea2('0x66')]]&&_0x2605af[_0x219ea2('0x2da')][_0x16ddca[_0x219ea2('0x66')]][_0x219ea2('0x25a4')]++;}function _0x46b5ef(_0x1b514f){const _0x2ff4e3=_0x576739;_0x2605af[_0x2ff4e3('0x2da')][_0x1b514f[_0x2ff4e3('0x66')]]&&_0x2605af[_0x2ff4e3('0x2da')][_0x1b514f['ChatQueueId']][_0x2ff4e3('0x25a4')]--;}function _0x41af2f(_0x237d7f){const _0x410820=_0x576739;console['log'](_0x410820('0x4a5'),_0x237d7f);if(_0x237d7f[_0x410820('0x1431')])_0x2e3ca0()[_0x410820('0x15d0')](_0x2605af[_0x410820('0x2da')],function(_0x3b9c24){const _0x7c42bd=_0x410820;_0x3b9c24[_0x7c42bd('0x756')][_0x237d7f['id']]&&(_0x3b9c24[_0x7c42bd('0x1a1d')]+=0x1,console[_0x7c42bd('0x1b2b')](_0x7c42bd('0xa4')));});else!_0x237d7f[_0x410820('0x1431')]&&_0x2e3ca0()[_0x410820('0x15d0')](_0x2605af[_0x410820('0x2da')],function(_0x4111a1){const _0x1c4e04=_0x410820;_0x4111a1[_0x1c4e04('0x756')][_0x237d7f['id']]&&(_0x4111a1[_0x1c4e04('0x1a1d')]>0x0&&(_0x4111a1[_0x1c4e04('0x1a1d')]-=0x1,console[_0x1c4e04('0x1b2b')](_0x1c4e04('0x1778'))));});}function _0x27b350(_0x203be1){const _0x288140=_0x576739;console[_0x288140('0x1b2b')](_0x288140('0x16aa'),_0x203be1),_0x2605af['queues'][_0x203be1[_0x288140('0x66')]]&&(_0x2605af[_0x288140('0x2da')][_0x203be1[_0x288140('0x66')]][_0x288140('0x25a4')]+=0x1,_0x2605af['queues'][_0x203be1[_0x288140('0x66')]][_0x288140('0x756')][_0x203be1[_0x288140('0x10c5')]]=_0x203be1[_0x288140('0x66')]);}function _0x390918(_0x578136){const _0xa0ae6a=_0x576739;console[_0xa0ae6a('0x1b2b')]('onLogout',_0x578136),_0x2605af['queues'][_0x578136[_0xa0ae6a('0x66')]]&&_0x2605af['queues'][_0x578136[_0xa0ae6a('0x66')]][_0xa0ae6a('0x25a4')]>0x0&&(_0x2605af[_0xa0ae6a('0x2da')][_0x578136['ChatQueueId']][_0xa0ae6a('0x25a4')]-=0x1,delete _0x2605af['queues'][_0x578136[_0xa0ae6a('0x66')]][_0xa0ae6a('0x756')][_0x578136['UserId']]);}let _0xb1df33=!![],_0x5b1c3f=0x1;_0x2a0196[_0x576739('0x186d')](_0x576739('0x1e1d'),function(_0x2fdb84,_0x50aa30){const _0x419a66=_0x576739;_0xb1df33?_0x132aed(function(){_0xb1df33=![];}):(!_0x50aa30&&(_0x5b1c3f=_0x2605af[_0x419a66('0x23a2')][_0x419a66('0xdf8')]),_0x2fdb84!==_0x50aa30&&(_0x2605af[_0x419a66('0x23a2')]['page']=0x1),!_0x2fdb84&&(_0x2605af[_0x419a66('0x23a2')][_0x419a66('0xdf8')]=_0x5b1c3f),_0x2605af['getQueues']());});function _0x5aff8e(_0x45a53f){const _0x1af621=_0x576739;_0x2605af[_0x1af621('0x50d')]=_0x45a53f[_0x1af621('0x50d')],_0x2605af[_0x1af621('0x2da')]=_0x45a53f?_0x2e3ca0()['keyBy'](_0x45a53f['rows']?_0x45a53f[_0x1af621('0xf5d')]:[],'id'):{};if(_0x45a53f[_0x1af621('0xf5d')]){_0x2605af[_0x1af621('0x150d')]=[];for(let _0x298b67=0x0;_0x298b67<_0x45a53f[_0x1af621('0xf5d')]['length'];_0x298b67++){_0x2605af[_0x1af621('0x150d')]['push'](_0x45a53f['rows'][_0x298b67]['id']);}}_0x5c8430();}function _0x5b5862(){const _0x1ec399=_0x576739;_0x2605af[_0x1ec399('0x23a2')][_0x1ec399('0x1cc8')]=(_0x2605af[_0x1ec399('0x23a2')]['page']-0x1)*_0x2605af[_0x1ec399('0x23a2')][_0x1ec399('0x6f0')],_0x2ae8e3[_0x1ec399('0xca1')](_0x1ec399('0x20c2'))?_0x2605af[_0x1ec399('0x1883')]=_0x1c543f[_0x1ec399('0x1524')]['get'](_0x2605af[_0x1ec399('0x23a2')],_0x5aff8e)[_0x1ec399('0xe53')]:(_0x2605af[_0x1ec399('0x23a2')]['id']=_0x2605af[_0x1ec399('0x2a')]['id'],_0x2605af[_0x1ec399('0x23a2')][_0x1ec399('0x1aa')]=_0x1ec399('0x507'),_0x2605af[_0x1ec399('0x1883')]=_0x1c543f[_0x1ec399('0x2a')]['getResources'](_0x2605af[_0x1ec399('0x23a2')],_0x5aff8e)['$promise']);}function _0x1cb95f(_0x14bc71,_0x536a21){const _0x2d9c9a=_0x576739;_0x51e954[_0x2d9c9a('0x1d4')]({'controller':'CreateOrEditChatQueueDialogController','controllerAs':'vm','templateUrl':_0x3b33b7,'parent':angular[_0x2d9c9a('0x1fcc')](_0x10d27c['body']),'targetEvent':_0x14bc71,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x536a21,'chatQueues':_0x2e3ca0()[_0x2d9c9a('0x17a0')](_0x2605af['queues']),'license':null,'setting':null,'crudPermissions':_0x2605af[_0x2d9c9a('0x1134')]}});}function _0x6b75e3(_0x12dea8,_0x59679c){const _0x5dbe92=_0x576739;_0x51e954[_0x5dbe92('0x1d4')]({'controller':_0x5dbe92('0x1062'),'controllerAs':'vm','templateUrl':_0x54d9f2,'parent':angular[_0x5dbe92('0x1fcc')](_0x10d27c[_0x5dbe92('0x18e5')]),'targetEvent':_0x12dea8,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x59679c,'chatQueues':_0x2605af[_0x5dbe92('0x2da')]?_0x2605af[_0x5dbe92('0x2da')][_0x5dbe92('0xf5d')]:[],'realtime':![],'crudPermissions':_0x2605af[_0x5dbe92('0x1134')]}});}function _0x4adccf(_0x270517){const _0x17fe68=_0x576739;return _0x1c543f[_0x17fe68('0x1524')][_0x17fe68('0x2480')](_0x270517)[_0x17fe68('0xe53')][_0x17fe68('0x683')](function(){const _0xeb6c12=_0x17fe68;_0x32f77e[_0xeb6c12('0x53')]({'title':_0xeb6c12('0x5c7'),'msg':_0x270517['name']?_0x270517['name']+_0xeb6c12('0x96c'):''});})['catch'](function(_0x4542b5){const _0x573453=_0x17fe68;_0x32f77e['error']({'title':_0x573453('0xb4'),'msg':_0x4542b5[_0x573453('0x8c2')]});});}_0x2a0196[_0x576739('0x26a2')](_0x576739('0x4b8'),function(){const _0xf21c89=_0x576739;_0xf72e0d[_0xf21c89('0x1b9e')](_0xf21c89('0x1400')),_0xf72e0d[_0xf21c89('0x1b9e')](_0xf21c89('0xba7')),_0xf72e0d[_0xf21c89('0x1b9e')](_0xf21c89('0x8db')),_0xf72e0d[_0xf21c89('0x1b9e')](_0xf21c89('0x2719')),_0xf72e0d[_0xf21c89('0x1b9e')]('userVoiceQueue:remove'),_0xf72e0d[_0xf21c89('0x1b9e')]('userVoiceQueue:save');});}const _0x1b195b=_0xbf0435;function _0x1c19b3(){const _0x1a0059=_0x189033;return{'status':{'registered':_0x1a0059('0x584'),'unregistered':_0x1a0059('0x1da'),'lagged':'red-300-fg\x20icon-close-circle','reachable':_0x1a0059('0x584'),'unreachable':_0x1a0059('0x1da'),'unknown':'grey-fg\x20icon-minus-circle'},'state':{'unknown':'grey-fg\x20icon-phone-hangup','not_inuse':'green-300-fg\x20icon-phone-hangup','inuse':_0x1a0059('0x10c0'),'busy':'red-300-fg\x20icon-phone-locked','invalid':'grey-fg\x20icon-phone-hangup','unavailable':_0x1a0059('0x27f9'),'ringing':_0x1a0059('0x20f0'),'ringinuse':'blue-300-fg\x20icon-phone-incoming','onhold':_0x1a0059('0x1a52')},'channelStatus':{'ring':'blue-300-fg\x20icon-phone-incoming','up':_0x1a0059('0x1133'),'hangup':_0x1a0059('0x22be')},'channelStatusOut':{'ring':_0x1a0059('0x2370'),'up':_0x1a0059('0x1133'),'hangup':_0x1a0059('0x22be')}};}const _0x610238=_0x1c19b3;_0x6b7222[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'socket'];function _0x6b7222(_0xc7207,_0x2ff2bd,_0x556a56){const _0x18c543=_0x189033,_0x33ba08=this;_0x556a56[_0x18c543('0x1346')](),_0x556a56['connect'](),_0x33ba08[_0x18c543('0x517')]=0x0;switch(_0x2ff2bd[_0x18c543('0xb24')]['name']){case _0x18c543('0x2637'):_0x33ba08[_0x18c543('0x517')]=0x0;break;case'app.chat.realtime.queues':_0x33ba08[_0x18c543('0x517')]=0x1;break;default:_0x33ba08['selectedTab']=0x0,_0x2ff2bd['go'](_0x18c543('0x2637'));}_0xc7207['$watch'](_0x18c543('0x9a4'),function(_0x566d01,_0x5b3102){const _0x396d6a=_0x18c543;if(_0x566d01!==_0x5b3102)switch(_0x566d01){case 0x0:_0x2ff2bd['go'](_0x396d6a('0x2637'));break;case 0x1:_0x2ff2bd['go'](_0x396d6a('0x15cf'));break;default:_0x2ff2bd['go'](_0x396d6a('0x2637'));}});}const _0x18b424=_0x6b7222;_0x98457f[_0x189033('0x14be')]=['$stateProvider'];function _0x98457f(_0x58e095){const _0x550640=_0x189033;_0x58e095[_0x550640('0x2598')](_0x550640('0x10ee'),{'url':_0x550640('0xf7c'),'views':{'content@app':{'templateUrl':_0x4c3976,'controller':_0x550640('0x183d')}},'resolve':{'userProfile':[_0x550640('0x4b1'),_0x550640('0xba1'),function(_0x51ef7a,_0x2b6890){const _0xfebcb9=_0x550640;return _0x2b6890[_0xfebcb9('0xca1')](_0xfebcb9('0x20c2'))?null:_0x51ef7a['resolve'](_0xfebcb9('0x1464'),{'fields':_0xfebcb9('0x16f'),'id':_0x2b6890['getCurrentUser']()[_0xfebcb9('0x2f')]});}],'userProfileSection':[_0x550640('0x4b1'),_0x550640('0xba1'),function(_0x436d92,_0x1d1743){const _0x239fe7=_0x550640;return _0x1d1743[_0x239fe7('0xca1')](_0x239fe7('0x20c2'))?null:_0x436d92[_0x239fe7('0xed7')]('userProfileSection@get',{'fields':_0x239fe7('0x1f47'),'userProfileId':_0x1d1743[_0x239fe7('0x20b2')]()['userProfileId'],'sectionId':0x1fe});}]},'authenticate':!![],'permissionId':0x1fe})[_0x550640('0x2598')](_0x550640('0x2637'),{'url':_0x550640('0xf1a'),'controller':'AgentsChatRealtimeController\x20as\x20vm','templateUrl':_0x2a4839,'resolve':{'pauses':[_0x550640('0x4b1'),function(_0x288265){const _0x5ce294=_0x550640;return _0x288265[_0x5ce294('0xed7')](_0x5ce294('0x112'),{'nolimit':!![]});}],'agents':['apiResolver',_0x550640('0xba1'),function(_0xda6052,_0x1cf5b3){const _0x4c12bb=_0x550640;return _0x1cf5b3['hasRole'](_0x4c12bb('0x20c2'))?_0xda6052['resolve'](_0x4c12bb('0x25c9'),{'fields':_0x4c12bb('0x174e'),'role':_0x4c12bb('0x2327'),'sort':_0x4c12bb('0x11bc'),'nolimit':!![]}):_0xda6052[_0x4c12bb('0xed7')](_0x4c12bb('0x191b'),{'id':_0x1cf5b3[_0x4c12bb('0x20b2')]()[_0x4c12bb('0x2f')],'section':_0x4c12bb('0x1bc0'),'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0x4c12bb('0x2327'),'sort':'fullname','nolimit':!![]});}],'userProfile':[_0x550640('0x4b1'),'Auth',function(_0x5720e0,_0x31dc7d){const _0x753da9=_0x550640;return _0x31dc7d[_0x753da9('0xca1')](_0x753da9('0x20c2'))?null:_0x5720e0[_0x753da9('0xed7')](_0x753da9('0x1464'),{'fields':'id,name,crudPermissions','id':_0x31dc7d[_0x753da9('0x20b2')]()[_0x753da9('0x2f')]});}],'userProfileSection':['apiResolver',_0x550640('0xba1'),function(_0x341c40,_0x2497f5){const _0x496884=_0x550640;return _0x2497f5[_0x496884('0xca1')](_0x496884('0x20c2'))?null:_0x341c40[_0x496884('0xed7')](_0x496884('0x360'),{'fields':_0x496884('0x1f47'),'userProfileId':_0x2497f5[_0x496884('0x20b2')]()['userProfileId'],'sectionId':0xca});}],'rpcAgents':[_0x550640('0x4b1'),function(_0xabf01a){const _0x1b0ee3=_0x550640;return _0xabf01a['resolve'](_0x1b0ee3('0x36a'));}]},'authenticate':!![],'permissionId':0x1fe})['state'](_0x550640('0x15cf'),{'url':_0x550640('0x14a4'),'controller':_0x550640('0xc4e'),'templateUrl':_0x1bdab8,'resolve':{'queues':[_0x550640('0x4b1'),_0x550640('0xba1'),function(_0x3bee1c,_0x52f7d3){const _0x3f31af=_0x550640;return _0x52f7d3[_0x3f31af('0xca1')](_0x3f31af('0x20c2'))?_0x3bee1c[_0x3f31af('0xed7')](_0x3f31af('0x974'),{'type':'inbound','sort':_0x3f31af('0xc36'),'limit':0xa,'offset':0x0}):_0x3bee1c['resolve'](_0x3f31af('0x191b'),{'id':_0x52f7d3[_0x3f31af('0x20b2')]()[_0x3f31af('0x2f')],'section':_0x3f31af('0x507'),'channel':'chat','type':_0x3f31af('0x1535'),'sort':_0x3f31af('0xc36'),'limit':0xa,'page':0x1});}],'userProfile':[_0x550640('0x4b1'),_0x550640('0xba1'),function(_0x41e1c0,_0x57bc9a){const _0x56c48f=_0x550640;return _0x57bc9a[_0x56c48f('0xca1')](_0x56c48f('0x20c2'))?null:_0x41e1c0[_0x56c48f('0xed7')](_0x56c48f('0x1464'),{'fields':'id,name,crudPermissions','id':_0x57bc9a[_0x56c48f('0x20b2')]()[_0x56c48f('0x2f')]});}],'userProfileSection':['apiResolver',_0x550640('0xba1'),function(_0x1c88f5,_0xe2bba6){const _0x5254ca=_0x550640;return _0xe2bba6[_0x5254ca('0xca1')](_0x5254ca('0x20c2'))?null:_0x1c88f5['resolve'](_0x5254ca('0x360'),{'fields':_0x5254ca('0x1f47'),'userProfileId':_0xe2bba6['getCurrentUser']()[_0x5254ca('0x2f')],'sectionId':0x1f5});}],'rpcQueues':[_0x550640('0x4b1'),function(_0x271755){const _0x398f38=_0x550640;return _0x271755['resolve'](_0x398f38('0xc41'));}]},'authenticate':!![],'permissionId':0x1fe});}angular[_0x189033('0x1e26')](_0x189033('0x10ee'),[])[_0x189033('0x272d')](_0x98457f)[_0x189033('0x1da3')]('AgentsChatRealtimeController',_0x52cbd0)[_0x189033('0x1da3')]('QueuesChatRealtimeController',_0x1b195b)[_0x189033('0x1f97')](_0x189033('0xa72'),_0x610238)[_0x189033('0x1da3')](_0x189033('0x1eae'),_0x18b424);const _0x34047b=_0x180212['p']+_0x189033('0xde4');_0x2d91d6[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0x1253'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),'toasty',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x2d91d6(_0x4a114e,_0x33ada3,_0x119e0a,_0x71944d,_0x5a32a2,_0xc9f6ae,_0x1b113f,_0x4b4461,_0x245d6e,_0x32b0c9,_0x4b9242,_0x26d27f,_0x8ceb40,_0x47ca65,_0x43a424,_0x2990fe,_0x2a5232){const _0x6d9b08=_0x189033,_0x4add6c=this;_0x4add6c[_0x6d9b08('0xace')]=_0x2990fe,_0x4add6c[_0x6d9b08('0x260a')]=_0x2a5232,_0x4add6c[_0x6d9b08('0x11ed')]=_0x43a424[_0x6d9b08('0x20b2')](),_0x4add6c[_0x6d9b08('0x1253')]=_0x245d6e||{'count':0x0,'rows':[]},_0x4add6c['userProfile']=_0x32b0c9,_0x4add6c[_0x6d9b08('0x22df')]=_0x4b9242&&_0x4b9242[_0x6d9b08('0x50d')]==0x1?_0x4b9242[_0x6d9b08('0xf5d')][0x0]:null,_0x4add6c[_0x6d9b08('0x1134')]=_0x43a424['parseCrudPermissions'](_0x4add6c[_0x6d9b08('0x22df')]?_0x4add6c[_0x6d9b08('0x22df')]['crudPermissions']:null),_0x4add6c[_0x6d9b08('0x5c4')]=_0x6d9b08('0x1253'),_0x4add6c['listOrder']='',_0x4add6c[_0x6d9b08('0x1ce2')]=null,_0x4add6c['selectedChatQueues']=[],_0x4add6c[_0x6d9b08('0x23a2')]={'fields':_0x6d9b08('0x1b67'),'sort':_0x6d9b08('0xc36'),'channel':'chat','limit':0xa,'page':0x1},_0x4add6c[_0x6d9b08('0x21de')]=_0x2e3ca0()[_0x6d9b08('0x24db')]([{'option':_0x6d9b08('0x953'),'value':_0x6d9b08('0x185b')},{'option':'RR\x20Memory','value':_0x6d9b08('0x4ab')}],function(_0x3367f4){const _0x20b9b3=_0x6d9b08;return _0x2e3ca0()['replace'](_0x3367f4[_0x20b9b3('0x1c6b')],new RegExp('\x27','g'),'');}),_0x4add6c['editstate']=_0x28e345,_0x4add6c[_0x6d9b08('0xe0e')]=_0x276601,_0x4add6c[_0x6d9b08('0x2814')]=_0x3da879,_0x4add6c[_0x6d9b08('0x194f')]=_0x34583d,_0x4add6c['gotorealtimegoto']=_0x57faf8,_0x4add6c['success']=_0x555c20,_0x4add6c[_0x6d9b08('0xb2d')]=_0x5d46c6,_0x4add6c[_0x6d9b08('0x260b')]=_0x302f28,_0x4add6c[_0x6d9b08('0x492')]=_0x24cee1,_0x4add6c[_0x6d9b08('0x2248')]=_0x5f465b,_0x4add6c['deleteSelectedChatQueues']=_0x24627d,_0x4add6c[_0x6d9b08('0x275f')]=_0x5e93c9,_0x4add6c[_0x6d9b08('0x1f7f')]=_0x35dbf3;function _0x28e345(_0x32c863){const _0x8440e=_0x6d9b08;_0x119e0a['go'](_0x8440e('0x225f'),{'id':_0x32c863['id'],'chatQueue':_0x32c863,'crudPermissions':_0x4add6c[_0x8440e('0x1134')]});}function _0x276601(_0x21c6e7,_0x192014){const _0x3863d0=_0x6d9b08;_0x5a32a2[_0x3863d0('0x1d4')]({'controller':_0x3863d0('0x885'),'controllerAs':'vm','templateUrl':_0x34047b,'parent':angular['element'](_0xc9f6ae[_0x3863d0('0x18e5')]),'targetEvent':_0x192014,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x21c6e7,'chatQueues':_0x4add6c[_0x3863d0('0x1253')]?_0x4add6c[_0x3863d0('0x1253')][_0x3863d0('0xf5d')]:[],'crudPermissions':_0x4add6c[_0x3863d0('0x1134')]}});}function _0x3da879(_0xcb5bdb,_0x3725ce){const _0x15dbec=_0x6d9b08;_0x5a32a2['show']({'controller':'ChatQueueagentaddController','controllerAs':'vm','templateUrl':_0x54d9f2,'parent':angular[_0x15dbec('0x1fcc')](_0xc9f6ae[_0x15dbec('0x18e5')]),'targetEvent':_0x3725ce,'clickOutsideToClose':!![],'locals':{'chatQueue':_0xcb5bdb,'chatQueues':_0x4add6c['chatQueues']?_0x4add6c[_0x15dbec('0x1253')]['rows']:[],'crudPermissions':_0x4add6c[_0x15dbec('0x1134')],'realtime':![]}});}function _0x34583d(_0x2a4e73,_0x359139){const _0x57652c=_0x6d9b08,_0x3cd815=_0x5a32a2[_0x57652c('0x1c6f')]()[_0x57652c('0xf28')](_0x57652c('0x1b01')+_0x2e3ca0()['startCase'](_0x57652c('0x1524'))+'?')['htmlContent'](_0x57652c('0xed5')+(_0x2a4e73[_0x57652c('0x60a')]||'chatQueue')+_0x57652c('0x20f1')+_0x57652c('0x1ee7'))['ariaLabel']('delete\x20chatQueue')['targetEvent'](_0x359139)['ok']('OK')['cancel'](_0x57652c('0x16b8'));_0x5a32a2[_0x57652c('0x1d4')](_0x3cd815)[_0x57652c('0x683')](function(){_0x24cee1(_0x2a4e73);},function(){const _0x152378=_0x57652c;console[_0x152378('0x1b2b')](_0x152378('0x16b8'));});}function _0x57faf8(){const _0x7ccf9e=_0x6d9b08;if(_0x43a424['hasRole'](_0x7ccf9e('0x20c2')))_0x119e0a['go'](_0x7ccf9e('0x15cf'),{});else return _0x26d27f[_0x7ccf9e('0x22df')][_0x7ccf9e('0x1e6e')]({'userProfileId':_0x43a424[_0x7ccf9e('0x20b2')]()[_0x7ccf9e('0x2f')],'sectionId':0x1fe})[_0x7ccf9e('0xe53')][_0x7ccf9e('0x683')](function(_0x24b88a){const _0x16744d=_0x7ccf9e,_0x45b09e=_0x24b88a&&_0x24b88a['rows']?_0x24b88a[_0x16744d('0xf5d')][0x0]:null;_0x45b09e&&_0x45b09e[_0x16744d('0x1333')]?_0x119e0a['go']('app.chat.realtime.queues',{}):_0x47ca65['info']({'title':_0x4b4461[_0x16744d('0x2728')](_0x16744d('0x213e')),'msg':_0x4b4461[_0x16744d('0x2728')](_0x16744d('0xdba'))});})[_0x7ccf9e('0x130a')](function(_0x112c50){const _0x555f86=_0x7ccf9e;_0x47ca65[_0x555f86('0x52a')]({'title':_0x112c50['status']?'API:'+_0x112c50['status']+_0x555f86('0xbf6')+_0x112c50[_0x555f86('0x24a9')]:'USERPROFILE:GET_SECTION','msg':_0x112c50[_0x555f86('0x13ee')]?JSON[_0x555f86('0x258a')](_0x112c50[_0x555f86('0x5a5')]):_0x112c50[_0x555f86('0x1ff0')]()});});}let _0x476889=!![],_0x283582=0x1;_0x4a114e['$watch'](_0x6d9b08('0x1e1d'),function(_0x26c30e,_0xe10f2){const _0x4a7546=_0x6d9b08;_0x476889?_0x1b113f(function(){_0x476889=![];}):(!_0xe10f2&&(_0x283582=_0x4add6c[_0x4a7546('0x23a2')][_0x4a7546('0xdf8')]),_0x26c30e!==_0xe10f2&&(_0x4add6c[_0x4a7546('0x23a2')]['page']=0x1),!_0x26c30e&&(_0x4add6c[_0x4a7546('0x23a2')][_0x4a7546('0xdf8')]=_0x283582),_0x4add6c[_0x4a7546('0xb2d')]());});function _0x555c20(_0xe787d1){const _0x2e4632=_0x6d9b08;_0x4add6c[_0x2e4632('0x1253')]=_0xe787d1||{'count':0x0,'rows':[]};}function _0x5d46c6(){const _0xa328e6=_0x6d9b08;_0x4add6c[_0xa328e6('0x23a2')][_0xa328e6('0x1cc8')]=(_0x4add6c[_0xa328e6('0x23a2')][_0xa328e6('0xdf8')]-0x1)*_0x4add6c[_0xa328e6('0x23a2')][_0xa328e6('0x6f0')],_0x43a424['hasRole']('admin')?_0x4add6c['promise']=_0x26d27f[_0xa328e6('0x1524')]['get'](_0x4add6c[_0xa328e6('0x23a2')],_0x555c20)[_0xa328e6('0xe53')]:(_0x4add6c['query']['id']=_0x4add6c['userProfile']['id'],_0x4add6c[_0xa328e6('0x23a2')][_0xa328e6('0x1aa')]=_0xa328e6('0x507'),_0x4add6c[_0xa328e6('0x1883')]=_0x26d27f[_0xa328e6('0x2a')][_0xa328e6('0x241d')](_0x4add6c[_0xa328e6('0x23a2')],_0x555c20)[_0xa328e6('0xe53')]);}function _0x302f28(_0x5aa71a,_0x2fb5c6){const _0x3d9886=_0x6d9b08;_0x5a32a2['show']({'controller':_0x3d9886('0xcb6'),'controllerAs':'vm','templateUrl':_0x3b33b7,'parent':angular['element'](_0xc9f6ae[_0x3d9886('0x18e5')]),'targetEvent':_0x5aa71a,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x2fb5c6,'chatQueues':_0x4add6c[_0x3d9886('0x1253')]['rows'],'license':_0x4add6c[_0x3d9886('0xace')],'setting':_0x4add6c[_0x3d9886('0x260a')],'crudPermissions':_0x4add6c[_0x3d9886('0x1134')]}});}function _0x24cee1(_0x412a71){const _0x1994b7=_0x6d9b08;_0x26d27f[_0x1994b7('0x1524')][_0x1994b7('0xd7e')]({'id':_0x412a71['id']})[_0x1994b7('0xe53')][_0x1994b7('0x683')](function(){const _0x274d32=_0x1994b7;_0x2e3ca0()['remove'](_0x4add6c[_0x274d32('0x1253')][_0x274d32('0xf5d')],{'id':_0x412a71['id']}),_0x4add6c[_0x274d32('0x1253')][_0x274d32('0x50d')]-=0x1,!_0x4add6c[_0x274d32('0x1253')][_0x274d32('0xf5d')][_0x274d32('0x1564')]&&_0x4add6c[_0x274d32('0xb2d')](),_0x47ca65[_0x274d32('0x53')]({'title':_0x2e3ca0()[_0x274d32('0x1e03')](_0x274d32('0x19f6'))+_0x274d32('0xbfc'),'msg':_0x412a71[_0x274d32('0x60a')]?_0x412a71[_0x274d32('0x60a')]+_0x274d32('0x194d'):''});})[_0x1994b7('0x130a')](function(_0x56b22f){const _0x43f176=_0x1994b7;if(_0x56b22f['data']&&_0x56b22f[_0x43f176('0x5a5')]['errors']&&_0x56b22f['data'][_0x43f176('0x17f')]['length']){_0x4add6c['errors']=_0x56b22f[_0x43f176('0x5a5')][_0x43f176('0x17f')]||[{'message':_0x56b22f[_0x43f176('0x1ff0')](),'type':_0x43f176('0x26be')}];for(let _0x5cd39a=0x0;_0x5cd39a<_0x56b22f[_0x43f176('0x5a5')][_0x43f176('0x17f')][_0x43f176('0x1564')];_0x5cd39a++){_0x47ca65[_0x43f176('0x52a')]({'title':_0x56b22f[_0x43f176('0x5a5')][_0x43f176('0x17f')][_0x5cd39a]['type'],'msg':_0x56b22f[_0x43f176('0x5a5')][_0x43f176('0x17f')][_0x5cd39a][_0x43f176('0x8c2')]});}}else _0x47ca65[_0x43f176('0x52a')]({'title':_0x56b22f[_0x43f176('0x13ee')]?_0x43f176('0x2168')+_0x56b22f[_0x43f176('0x13ee')]+_0x43f176('0xbf6')+_0x56b22f[_0x43f176('0x24a9')]:_0x43f176('0x26be'),'msg':_0x56b22f[_0x43f176('0x5a5')]?JSON['stringify'](_0x56b22f[_0x43f176('0x5a5')]['message']):_0x56b22f[_0x43f176('0x8c2')]||_0x56b22f[_0x43f176('0x1ff0')]()});});}function _0x5f465b(){const _0x203692=_0x6d9b08,_0x35ecb2=angular[_0x203692('0x1a86')](_0x4add6c['selectedChatQueues']);return _0x4add6c[_0x203692('0x10d')]=[],_0x35ecb2;}function _0x24627d(_0x372376){const _0x361677=_0x6d9b08,_0x164e13=_0x5a32a2[_0x361677('0x1c6f')]()[_0x361677('0xf28')](_0x361677('0x255a'))['htmlContent'](_0x361677('0xed5')+_0x4add6c['selectedChatQueues'][_0x361677('0x1564')]+'\x20selected
'+_0x361677('0x1ee7'))['ariaLabel']('delete\x20ChatQueues')[_0x361677('0xe42')](_0x372376)['ok']('OK')[_0x361677('0x19fb')]('CANCEL');_0x5a32a2[_0x361677('0x1d4')](_0x164e13)[_0x361677('0x683')](function(){const _0x22d243=_0x361677;_0x4add6c[_0x22d243('0x10d')]['forEach'](function(_0x2484b2){_0x24cee1(_0x2484b2);}),_0x4add6c[_0x22d243('0x10d')]=[];});}function _0x5e93c9(){const _0x3250ba=_0x6d9b08;_0x4add6c[_0x3250ba('0x10d')]=[];}function _0x35dbf3(){const _0xa8c7c=_0x6d9b08;_0x4add6c[_0xa8c7c('0x10d')]=_0x4add6c[_0xa8c7c('0x1253')][_0xa8c7c('0xf5d')];}}const _0xdb06d6=_0x2d91d6;_0x42e7f2[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),'$location','$mdDialog','$q','$translate',_0x189033('0x1d70'),_0x189033('0x1253'),_0x189033('0x1524'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x42e7f2(_0x2f5147,_0x3d503d,_0x2e601c,_0xfa8044,_0x4595e2,_0x157f05,_0x4b73c8,_0x4c70fd,_0x2cebcb,_0x59cffb,_0x14c09b,_0x3cd22e,_0x3e910d,_0x3c85d6){const _0x463be9=_0x189033,_0x137032=this;_0x137032['currentUser']=_0x14c09b[_0x463be9('0x20b2')](),_0x137032[_0x463be9('0x17f')]=[],_0x137032[_0x463be9('0x260a')]=_0x3e910d,_0x137032[_0x463be9('0xace')]=_0x3cd22e,_0x137032[_0x463be9('0x1134')]=_0x3c85d6,_0x137032[_0x463be9('0x258d')]={},_0x137032[_0x463be9('0x19b2')]=_0x137032[_0x463be9('0x260a')]&&_0x137032[_0x463be9('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x137032['title']=_0x463be9('0x1652'),_0x137032['chatQueue']=angular[_0x463be9('0x1a86')](_0x2cebcb),_0x137032['chatQueues']=_0x4c70fd,_0x137032[_0x463be9('0xa3')]=![];!_0x137032['chatQueue']&&(_0x137032[_0x463be9('0x1524')]={'strategy':_0x463be9('0x25ee'),'timeout':0xa},_0x137032[_0x463be9('0xf28')]=_0x463be9('0x1956'),_0x137032[_0x463be9('0xa3')]=!![]);_0x137032['addNewChatQueue']=_0x4a55b6,_0x137032[_0x463be9('0x2374')]=_0x372f7f,_0x137032[_0x463be9('0x492')]=_0xe9e81c,_0x137032['getDateFromString']=_0xc8dfb2,_0x137032[_0x463be9('0xf82')]=_0x48232c;function _0x4a55b6(){const _0x5b4cc2=_0x463be9;_0x137032[_0x5b4cc2('0x17f')]=[],_0x59cffb[_0x5b4cc2('0x1524')]['save'](_0x137032[_0x5b4cc2('0x1524')])[_0x5b4cc2('0xe53')]['then'](function(_0x591c4a){const _0x2d0ea6=_0x5b4cc2;_0x137032[_0x2d0ea6('0x1253')][_0x2d0ea6('0x1167')](_0x591c4a['toJSON']()),_0x4b73c8['success']({'title':_0x2d0ea6('0x15ce'),'msg':_0x137032[_0x2d0ea6('0x1524')]['name']?_0x137032['chatQueue'][_0x2d0ea6('0x60a')]+_0x2d0ea6('0x14b5'):''}),_0x48232c(_0x591c4a);})[_0x5b4cc2('0x130a')](function(_0x13f720){const _0x299766=_0x5b4cc2;if(_0x13f720[_0x299766('0x5a5')]&&_0x13f720[_0x299766('0x5a5')][_0x299766('0x17f')]&&_0x13f720['data'][_0x299766('0x17f')][_0x299766('0x1564')]){_0x137032[_0x299766('0x17f')]=_0x13f720[_0x299766('0x5a5')][_0x299766('0x17f')]||[{'message':_0x13f720['toString'](),'type':_0x299766('0x1267')}];for(let _0x5e2105=0x0;_0x5e2105<_0x13f720['data']['errors'][_0x299766('0x1564')];_0x5e2105+=0x1){_0x4b73c8[_0x299766('0x52a')]({'title':_0x13f720[_0x299766('0x5a5')]['errors'][_0x5e2105][_0x299766('0xcf0')],'msg':_0x13f720[_0x299766('0x5a5')][_0x299766('0x17f')][_0x5e2105]['message']});}}else _0x4b73c8[_0x299766('0x52a')]({'title':_0x13f720['status']?_0x299766('0x2168')+_0x13f720[_0x299766('0x13ee')]+'\x20-\x20'+_0x13f720[_0x299766('0x24a9')]:_0x299766('0x1267'),'msg':_0x13f720[_0x299766('0x5a5')]?JSON[_0x299766('0x258a')](_0x13f720['data'][_0x299766('0x8c2')]):_0x13f720[_0x299766('0x1ff0')]()});});}function _0x372f7f(){const _0x5c75ae=_0x463be9;_0x137032[_0x5c75ae('0x17f')]=[],_0x59cffb['chatQueue'][_0x5c75ae('0x2480')]({'id':_0x137032[_0x5c75ae('0x1524')]['id']},_0x137032['chatQueue'])['$promise'][_0x5c75ae('0x683')](function(_0x1aa766){const _0x18893d=_0x5c75ae,_0x187fb7=_0x2e3ca0()[_0x18893d('0x1c07')](_0x137032[_0x18893d('0x1253')],{'id':_0x1aa766['id']});_0x187fb7&&_0x2e3ca0()[_0x18893d('0xf22')](_0x187fb7,_0x2e3ca0()[_0x18893d('0x24d0')](_0x1aa766[_0x18893d('0x24e1')](),_0x2e3ca0()[_0x18893d('0x55e')](_0x187fb7))),_0x4b73c8[_0x18893d('0x53')]({'title':_0x18893d('0x1d51'),'msg':_0x137032['chatQueue']['name']?_0x137032[_0x18893d('0x1524')][_0x18893d('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x48232c(_0x1aa766);})[_0x5c75ae('0x130a')](function(_0x2c58f8){const _0x5560db=_0x5c75ae;if(_0x2c58f8[_0x5560db('0x5a5')]&&_0x2c58f8[_0x5560db('0x5a5')]['errors']&&_0x2c58f8[_0x5560db('0x5a5')][_0x5560db('0x17f')]['length']){_0x137032['errors']=_0x2c58f8[_0x5560db('0x5a5')]['errors']||[{'message':_0x2c58f8['toString'](),'type':'api.chatQueue.update'}];for(let _0xbf277a=0x0;_0xbf277a<_0x2c58f8['data'][_0x5560db('0x17f')][_0x5560db('0x1564')];_0xbf277a++){_0x4b73c8[_0x5560db('0x52a')]({'title':_0x2c58f8[_0x5560db('0x5a5')][_0x5560db('0x17f')][_0xbf277a][_0x5560db('0xcf0')],'msg':_0x2c58f8[_0x5560db('0x5a5')][_0x5560db('0x17f')][_0xbf277a][_0x5560db('0x8c2')]});}}else _0x4b73c8[_0x5560db('0x52a')]({'title':_0x2c58f8[_0x5560db('0x13ee')]?_0x5560db('0x2168')+_0x2c58f8['status']+_0x5560db('0xbf6')+_0x2c58f8[_0x5560db('0x24a9')]:_0x5560db('0x189f'),'msg':_0x2c58f8[_0x5560db('0x5a5')]?JSON[_0x5560db('0x258a')](_0x2c58f8['data'][_0x5560db('0x8c2')]):_0x2c58f8[_0x5560db('0x1ff0')]()});});}function _0xe9e81c(_0x123a2e){const _0x4e1f38=_0x463be9;_0x137032['errors']=[];const _0x21abd8=_0xfa8044['confirm']()[_0x4e1f38('0xf28')](_0x4e1f38('0x4d'))[_0x4e1f38('0xa6a')](_0x4e1f38('0x59a'))[_0x4e1f38('0x1040')](_0x4e1f38('0x90'))['ok']('Delete')[_0x4e1f38('0x19fb')](_0x4e1f38('0x253a'))[_0x4e1f38('0xe42')](_0x123a2e);_0xfa8044[_0x4e1f38('0x1d4')](_0x21abd8)[_0x4e1f38('0x683')](function(){const _0x4de71f=_0x4e1f38;_0x59cffb[_0x4de71f('0x1524')]['delete']({'id':_0x137032['chatQueue']['id']})['$promise']['then'](function(){const _0x394f85=_0x4de71f;_0x2e3ca0()[_0x394f85('0x3ec')](_0x137032[_0x394f85('0x1253')],{'id':_0x137032[_0x394f85('0x1524')]['id']}),_0x4b73c8[_0x394f85('0x53')]({'title':_0x394f85('0x1405'),'msg':(_0x137032[_0x394f85('0x1524')][_0x394f85('0x60a')]||_0x394f85('0x1524'))+_0x394f85('0x194d')}),_0x48232c(_0x137032[_0x394f85('0x1524')]);})[_0x4de71f('0x130a')](function(_0x116bcb){const _0x5496e1=_0x4de71f;if(_0x116bcb['data']&&_0x116bcb[_0x5496e1('0x5a5')][_0x5496e1('0x17f')]&&_0x116bcb[_0x5496e1('0x5a5')]['errors']['length']){_0x137032[_0x5496e1('0x17f')]=_0x116bcb[_0x5496e1('0x5a5')][_0x5496e1('0x17f')]||[{'message':_0x116bcb[_0x5496e1('0x1ff0')](),'type':_0x5496e1('0x224d')}];for(let _0x4d0d5f=0x0;_0x4d0d5f<_0x116bcb[_0x5496e1('0x5a5')][_0x5496e1('0x17f')][_0x5496e1('0x1564')];_0x4d0d5f++){_0x4b73c8[_0x5496e1('0x52a')]({'title':_0x116bcb['data']['errors'][_0x4d0d5f][_0x5496e1('0xcf0')],'msg':_0x116bcb[_0x5496e1('0x5a5')]['errors'][_0x4d0d5f]['message']});}}else _0x4b73c8[_0x5496e1('0x52a')]({'title':_0x116bcb['status']?_0x5496e1('0x2168')+_0x116bcb['status']+_0x5496e1('0xbf6')+_0x116bcb[_0x5496e1('0x24a9')]:_0x5496e1('0x224d'),'msg':_0x116bcb[_0x5496e1('0x5a5')]?JSON[_0x5496e1('0x258a')](_0x116bcb[_0x5496e1('0x5a5')][_0x5496e1('0x8c2')]):_0x116bcb['message']||_0x116bcb[_0x5496e1('0x1ff0')]()});});},function(){});}function _0xc8dfb2(_0x217db9){return _0x217db9===null?undefined:new Date(_0x217db9);}function _0x48232c(_0x793a70){const _0x15f815=_0x463be9;_0xfa8044[_0x15f815('0x1715')](_0x793a70);}}const _0x55024c=_0x42e7f2;_0x3008b6[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x1524'),_0x189033('0x1253'),'realtime',_0x189033('0x1d08'),_0x189033('0xba1'),'crudPermissions'];function _0x3008b6(_0x25efc6,_0x24e94f,_0x26b683,_0x4696b4,_0x27f817,_0x34159a,_0x4c349d,_0x230346,_0x814185,_0x4af90b){const _0x579745=_0x189033,_0x130464=this;_0x130464[_0x579745('0x11ed')]=_0x814185[_0x579745('0x20b2')](),_0x130464[_0x579745('0x1524')]=_0x27f817,_0x130464[_0x579745('0x1134')]=_0x4af90b,_0x130464[_0x579745('0x2c9')]=_0x4c349d,_0x130464['items']=[],_0x130464[_0x579745('0x1c47')]=[],_0x130464[_0x579745('0x1378')]=[],_0x130464[_0x579745('0x125e')]=[],_0x130464[_0x579745('0x23a7')]=[],_0x130464[_0x579745('0x2106')]=![],_0x130464[_0x579745('0x1dd2')]=_0x59c04f,_0x130464['saveAgents']=_0x591aad,_0x130464[_0x579745('0xf82')]=_0x166b30,_0x130464[_0x579745('0x169f')]={'readOnly':!_0x130464['crudPermissions'][_0x579745('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x579745('0x60a'),'line1':_0x579745('0x11bc'),'line2':[_0x579745('0x60a'),_0x579745('0x1d43')],'line3':'','labelAll':_0x230346['instant'](_0x579745('0xb0f')),'labelSelected':_0x230346[_0x579745('0x2728')](_0x579745('0x199c')),'transferCallback':function(){const _0x488bd3=_0x579745,_0x4388a6=_0x2e3ca0()[_0x488bd3('0x25cb')](_0x130464[_0x488bd3('0x23a7')],_0x130464['selectedItems'],'id');_0x130464[_0x488bd3('0x2106')]=_0x2e3ca0()['isEmpty'](_0x4388a6)?![]:!![];}};function _0x59c04f(){const _0x263477=_0x579745;return _0x814185[_0x263477('0xca1')](_0x263477('0x20c2'))?_0xe4f93b()[_0x263477('0x130a')](function(_0x1ec442){const _0x4b3e1b=_0x263477;_0x26b683[_0x4b3e1b('0x52a')]({'title':_0x1ec442[_0x4b3e1b('0x13ee')]?_0x4b3e1b('0x2168')+_0x1ec442['status']+_0x4b3e1b('0xbf6')+_0x1ec442['statusText']:_0x4b3e1b('0x144f'),'msg':_0x1ec442['status']?JSON[_0x4b3e1b('0x258a')](_0x1ec442['data']):_0x1ec442['toString']()});}):_0x4809d8()['then'](function(_0x87a6b5){const _0xbbf4d=_0x263477;return _0x130464[_0xbbf4d('0x1aa')]=_0x87a6b5,_0xe4f93b();})['catch'](function(_0x5a7afc){const _0x30533e=_0x263477;_0x26b683[_0x30533e('0x52a')]({'title':_0x5a7afc[_0x30533e('0x13ee')]?_0x30533e('0x2168')+_0x5a7afc[_0x30533e('0x13ee')]+'\x20-\x20'+_0x5a7afc[_0x30533e('0x24a9')]:_0x30533e('0x144f'),'msg':_0x5a7afc['status']?JSON[_0x30533e('0x258a')](_0x5a7afc['data']):_0x5a7afc[_0x30533e('0x1ff0')]()});});}function _0x4809d8(){return _0x24e94f(function(_0x32fc05,_0x4a6a07){const _0x42790a=a0_0x4e0a;_0x4696b4[_0x42790a('0x22df')][_0x42790a('0x1e6e')]({'userProfileId':_0x130464[_0x42790a('0x11ed')][_0x42790a('0x2f')],'name':_0x42790a('0x1bc0')})[_0x42790a('0xe53')]['then'](function(_0x3e9445){const _0x68884c=_0x42790a,_0x2ab650=_0x3e9445&&_0x3e9445[_0x68884c('0xf5d')]?_0x3e9445[_0x68884c('0xf5d')][0x0]:null;_0x32fc05(_0x2ab650);})[_0x42790a('0x130a')](function(_0x192820){_0x4a6a07(_0x192820);});});}function _0xe4f93b(){return _0x24e94f(function(_0x27d4aa,_0x3fc31f){const _0x4ba775=a0_0x4e0a;return _0x1e854f()[_0x4ba775('0x683')](function(_0x54b00c){const _0x5beace=_0x4ba775;return _0x130464[_0x5beace('0x1996')]=_0x54b00c[_0x5beace('0xf5d')]?_0x54b00c[_0x5beace('0xf5d')]:[],_0x814185['hasRole'](_0x5beace('0x20c2'))?_0x54b00c:_0x130464['section']?_0x130464[_0x5beace('0x1aa')][_0x5beace('0x170')]?_0x54b00c:_0x5251f8():null;})[_0x4ba775('0x683')](function(_0x10d09b){const _0x250e99=_0x4ba775,_0x45bc0b=_0x10d09b&&_0x10d09b[_0x250e99('0xf5d')]?_0x10d09b[_0x250e99('0xf5d')]:[];return _0x130464[_0x250e99('0x1c47')]=_0x2e3ca0()[_0x250e99('0x386')](_0x45bc0b,function(_0x2d36d3){const _0x3126bb=_0x250e99;return _0x2e3ca0()[_0x3126bb('0x1c07')](_0x130464[_0x3126bb('0x1996')],{'id':_0x814185[_0x3126bb('0xca1')](_0x3126bb('0x20c2'))||_0x130464[_0x3126bb('0x1aa')][_0x3126bb('0x170')]?_0x2d36d3['id']:_0x2d36d3[_0x3126bb('0x832')]});}),_0x130464[_0x250e99('0x125e')]=angular[_0x250e99('0x1a86')](_0x130464['allowedItems']),_0x130464[_0x250e99('0x1996')][_0x250e99('0x1299')](function(_0x6091dd){const _0x19043f=_0x250e99,_0x68d05=_0x2e3ca0()[_0x19043f('0x1c07')](_0x130464[_0x19043f('0x1c47')],{'id':_0x6091dd['id']});_0x814185[_0x19043f('0xca1')](_0x19043f('0x20c2'))?_0x6091dd[_0x19043f('0x24f4')]=!![]:_0x6091dd[_0x19043f('0x24f4')]=typeof _0x68d05!==_0x19043f('0x1867')?!![]:![];}),_0x3077d1();})[_0x4ba775('0x683')](function(_0x494963){const _0x3eafe1=_0x4ba775,_0x32a455=_0x494963&&_0x494963[_0x3eafe1('0xf5d')]?_0x494963['rows']:[];_0x130464[_0x3eafe1('0x1378')]=_0x2e3ca0()[_0x3eafe1('0x386')](_0x32a455,function(_0x311a3a){const _0x541bc3=_0x3eafe1,_0x4d7c96=_0x2e3ca0()['find'](_0x130464[_0x541bc3('0x1996')],{'id':_0x311a3a['id']});return _0x4d7c96[_0x541bc3('0x1e2a')]=_0x311a3a[_0x541bc3('0x11c1')]?_0x541bc3('0x23d0')+_0x311a3a[_0x541bc3('0x11c1')][_0x541bc3('0x1e2a')]:'',_0x4d7c96[_0x541bc3('0x1d43')]=typeof _0x311a3a[_0x541bc3('0x1d43')]!==_0x541bc3('0x1867')?'<'+_0x311a3a[_0x541bc3('0x1d43')]+'>':'',_0x4d7c96;}),_0x130464['startingSelectedItems']=angular['copy'](_0x130464[_0x3eafe1('0x1378')]),_0x130464[_0x3eafe1('0x169f')][_0x3eafe1('0x1378')]=_0x130464['selectedItems'],_0x130464[_0x3eafe1('0x169f')][_0x3eafe1('0x1996')]=_0x2e3ca0()['differenceBy'](_0x130464['allowedItems'],_0x130464[_0x3eafe1('0x169f')]['selectedItems'],'id'),_0x27d4aa();})['catch'](function(_0x1139b5){_0x3fc31f(_0x1139b5);});});}function _0x5251f8(){return _0x24e94f(function(_0x1aeb4f,_0x292fd9){const _0x32be61=a0_0x4e0a;return _0x4696b4[_0x32be61('0xcf7')][_0x32be61('0x1e6e')]({'sectionId':_0x130464[_0x32be61('0x1aa')]['id'],'nolimit':!![]})[_0x32be61('0xe53')][_0x32be61('0x683')](function(_0x49aa59){_0x1aeb4f(_0x49aa59);})[_0x32be61('0x130a')](function(_0x4bbda7){_0x292fd9(_0x4bbda7);});});}function _0x3077d1(){return _0x24e94f(function(_0x24fe4e,_0x29f37e){const _0x5dae3b=a0_0x4e0a;return _0x4696b4[_0x5dae3b('0x1524')]['getAgents']({'id':_0x130464[_0x5dae3b('0x1524')]['id'],'fields':'id,name,internal,fullname','nolimit':!![],'role':_0x5dae3b('0x2327')})['$promise'][_0x5dae3b('0x683')](function(_0x467f9f){_0x24fe4e(_0x467f9f);})[_0x5dae3b('0x130a')](function(_0x2616d1){_0x29f37e(_0x2616d1);});});}function _0x1e854f(){return _0x24e94f(function(_0x308853,_0x2c4152){const _0x20da90=a0_0x4e0a;return _0x4696b4[_0x20da90('0xc96')][_0x20da90('0x1e6e')]({'fields':_0x20da90('0x72b'),'nolimit':!![],'role':_0x20da90('0x2327')})[_0x20da90('0xe53')][_0x20da90('0x683')](function(_0x1a635a){_0x308853(_0x1a635a);})['catch'](function(_0x5d9153){_0x2c4152(_0x5d9153);});});}function _0x251c6d(_0x38ea11){return _0x24e94f(function(_0x5473d2,_0x479b40){const _0x6627c0=a0_0x4e0a;_0x2e3ca0()[_0x6627c0('0x173f')](_0x38ea11)?_0x5473d2():_0x4696b4['chatQueue'][_0x6627c0('0x2179')]({'id':_0x130464[_0x6627c0('0x1524')]['id'],'ids':_0x2e3ca0()[_0x6627c0('0x386')](_0x38ea11,'id')})['$promise'][_0x6627c0('0x683')](function(){_0x5473d2();})['catch'](function(_0x36f732){_0x479b40(_0x36f732);});});}function _0x29c9b8(_0x7d0390){return _0x24e94f(function(_0x1139bb,_0x3fb9c8){const _0x1d1cdc=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0x7d0390)?_0x1139bb():_0x4696b4[_0x1d1cdc('0x1524')]['removeAgents']({'id':_0x130464[_0x1d1cdc('0x1524')]['id'],'ids':_0x2e3ca0()[_0x1d1cdc('0x386')](_0x7d0390,'id')})['$promise'][_0x1d1cdc('0x683')](function(){_0x1139bb();})[_0x1d1cdc('0x130a')](function(_0xf2f3e6){_0x3fb9c8(_0xf2f3e6);});});}function _0x591aad(){const _0xde055c=_0x579745,_0x2faa25=_0x2e3ca0()[_0xde055c('0x461')](_0x130464[_0xde055c('0x23a7')],_0x130464[_0xde055c('0x1378')],'id'),_0x127356=_0x2e3ca0()[_0xde055c('0x461')](_0x130464[_0xde055c('0x1378')],_0x130464['startingSelectedItems'],'id');return _0x29c9b8(_0x2faa25)[_0xde055c('0x683')](function(){return _0x251c6d(_0x127356);})[_0xde055c('0x683')](function(){const _0x28b512=_0xde055c;_0x130464[_0x28b512('0x2106')]=![],_0x130464['startingAllowedItems']=angular[_0x28b512('0x1a86')](_0x130464['allowedItems']),_0x130464['startingSelectedItems']=angular[_0x28b512('0x1a86')](_0x130464[_0x28b512('0x1378')]),_0x26b683[_0x28b512('0x53')]({'title':_0x28b512('0xd28'),'msg':_0x28b512('0x89d')});})['catch'](function(_0x4e24f5){const _0x3079f1=_0xde055c;_0x26b683['error']({'title':_0x4e24f5['status']?_0x3079f1('0x2168')+_0x4e24f5[_0x3079f1('0x13ee')]+_0x3079f1('0xbf6')+_0x4e24f5['statusText']:_0x3079f1('0x1b71'),'msg':_0x4e24f5[_0x3079f1('0x13ee')]?JSON['stringify'](_0x4e24f5[_0x3079f1('0x5a5')]):_0x4e24f5['toString']()});});}function _0x166b30(){const _0xf69acb=_0x579745;_0x25efc6[_0xf69acb('0x1715')]();}}const _0x12b88f=_0x3008b6;_0x513619[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x56b'),_0x189033('0x1524'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x513619(_0x490093,_0x2e5db9,_0x4ff6c8,_0x4083fb,_0x5b6a12,_0x25edef,_0x2d2de2,_0x5718fa){const _0x3d36b9=_0x189033,_0x22cf69=this;_0x22cf69['currentUser']=_0x2d2de2['getCurrentUser'](),_0x22cf69[_0x3d36b9('0x1524')]=_0x5b6a12,_0x22cf69[_0x3d36b9('0x1134')]=_0x5718fa,_0x22cf69[_0x3d36b9('0x1996')]=[],_0x22cf69[_0x3d36b9('0x1c47')]=[],_0x22cf69[_0x3d36b9('0x1378')]=[],_0x22cf69['startingAllowedItems']=[],_0x22cf69[_0x3d36b9('0x23a7')]=[],_0x22cf69[_0x3d36b9('0x2106')]=![],_0x22cf69[_0x3d36b9('0x169f')]={'readOnly':!_0x22cf69[_0x3d36b9('0x1134')][_0x3d36b9('0x1978')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x3d36b9('0x60a'),'line2':'','line3':'','labelAll':_0x25edef[_0x3d36b9('0x2728')](_0x3d36b9('0x148e')),'labelSelected':_0x25edef['instant'](_0x3d36b9('0x10b0')),'transferCallback':function(){const _0x4fb90c=_0x3d36b9,_0x53f121=_0x2e3ca0()['xorBy'](_0x22cf69[_0x4fb90c('0x23a7')],_0x22cf69['selectedItems'],'id');_0x22cf69[_0x4fb90c('0x2106')]=_0x2e3ca0()[_0x4fb90c('0x173f')](_0x53f121)?![]:!![];}},_0x22cf69[_0x3d36b9('0x1dd2')]=_0x2dbb31,_0x22cf69[_0x3d36b9('0x1a89')]=_0x321cbf,_0x22cf69[_0x3d36b9('0xf82')]=_0x27c996;function _0x2dbb31(){const _0x582f38=_0x3d36b9;return _0x2d2de2[_0x582f38('0xca1')](_0x582f38('0x20c2'))?_0x23e348()[_0x582f38('0x130a')](function(_0x53dd2c){const _0x2981de=_0x582f38;_0x4ff6c8['error']({'title':_0x53dd2c[_0x2981de('0x13ee')]?_0x2981de('0x2168')+_0x53dd2c[_0x2981de('0x13ee')]+_0x2981de('0xbf6')+_0x53dd2c[_0x2981de('0x24a9')]:'SYSTEM:GET_TEAMS','msg':_0x53dd2c[_0x2981de('0x13ee')]?JSON[_0x2981de('0x258a')](_0x53dd2c[_0x2981de('0x5a5')]):_0x53dd2c['toString']()});}):_0x393291()[_0x582f38('0x683')](function(_0x2207cc){const _0x4ce599=_0x582f38;return _0x22cf69[_0x4ce599('0x1aa')]=_0x2207cc,_0x23e348();})[_0x582f38('0x130a')](function(_0x3f6e73){const _0x125606=_0x582f38;_0x4ff6c8['error']({'title':_0x3f6e73[_0x125606('0x13ee')]?_0x125606('0x2168')+_0x3f6e73[_0x125606('0x13ee')]+'\x20-\x20'+_0x3f6e73[_0x125606('0x24a9')]:_0x125606('0x1820'),'msg':_0x3f6e73[_0x125606('0x13ee')]?JSON[_0x125606('0x258a')](_0x3f6e73[_0x125606('0x5a5')]):_0x3f6e73[_0x125606('0x1ff0')]()});});}function _0x393291(){return _0x2e5db9(function(_0x172000,_0x43884f){const _0x3191ca=a0_0x4e0a;_0x4083fb['userProfileSection']['get']({'userProfileId':_0x22cf69[_0x3191ca('0x11ed')][_0x3191ca('0x2f')],'name':_0x3191ca('0x15bc')})[_0x3191ca('0xe53')]['then'](function(_0x4c9334){const _0x5c6198=_0x3191ca,_0x31143d=_0x4c9334&&_0x4c9334['rows']?_0x4c9334[_0x5c6198('0xf5d')][0x0]:null;_0x172000(_0x31143d);})[_0x3191ca('0x130a')](function(_0x344c0c){_0x43884f(_0x344c0c);});});}function _0x23e348(){return _0x2e5db9(function(_0x35a21b,_0x5c87cc){const _0x31eb34=a0_0x4e0a;return _0x173f8d()['then'](function(_0x3ff51b){const _0x2621e3=a0_0x4e0a;return _0x22cf69[_0x2621e3('0x1996')]=_0x3ff51b[_0x2621e3('0xf5d')]?_0x3ff51b[_0x2621e3('0xf5d')]:[],_0x2d2de2[_0x2621e3('0xca1')](_0x2621e3('0x20c2'))?_0x3ff51b:_0x22cf69['section']?_0x22cf69['section'][_0x2621e3('0x170')]?_0x3ff51b:_0x279894():null;})['then'](function(_0x503c8d){const _0x20322d=a0_0x4e0a,_0x2c5303=_0x503c8d&&_0x503c8d['rows']?_0x503c8d[_0x20322d('0xf5d')]:[];return _0x22cf69[_0x20322d('0x1c47')]=_0x2e3ca0()[_0x20322d('0x386')](_0x2c5303,function(_0x182cea){const _0x2e446a=_0x20322d;return _0x2e3ca0()[_0x2e446a('0x1c07')](_0x22cf69[_0x2e446a('0x1996')],{'id':_0x2d2de2[_0x2e446a('0xca1')](_0x2e446a('0x20c2'))||_0x22cf69['section'][_0x2e446a('0x170')]?_0x182cea['id']:_0x182cea[_0x2e446a('0x832')]});}),_0x22cf69['items'][_0x20322d('0x1299')](function(_0x5183be){const _0x18a4e6=_0x20322d,_0x9a8a13=_0x2e3ca0()[_0x18a4e6('0x1c07')](_0x22cf69['allowedItems'],{'id':_0x5183be['id']});_0x2d2de2['hasRole']('admin')?_0x5183be[_0x18a4e6('0x24f4')]=!![]:_0x5183be['isValid']=typeof _0x9a8a13!==_0x18a4e6('0x1867')?!![]:![];}),_0x81c611();})[_0x31eb34('0x683')](function(_0x3b93de){const _0x2fa117=_0x31eb34,_0x59c14b=_0x3b93de&&_0x3b93de['rows']?_0x3b93de[_0x2fa117('0xf5d')]:[];_0x22cf69[_0x2fa117('0x1378')]=_0x2e3ca0()['map'](_0x59c14b,function(_0x20d75b){const _0x5c2a62=_0x2fa117;return _0x2e3ca0()[_0x5c2a62('0x1c07')](_0x22cf69[_0x5c2a62('0x1996')],{'id':_0x20d75b['id']});}),_0x22cf69[_0x2fa117('0x23a7')]=angular[_0x2fa117('0x1a86')](_0x22cf69[_0x2fa117('0x1378')]),_0x22cf69[_0x2fa117('0x169f')][_0x2fa117('0x1378')]=_0x22cf69['selectedItems'],_0x22cf69[_0x2fa117('0x169f')][_0x2fa117('0x1996')]=_0x2e3ca0()[_0x2fa117('0x461')](_0x22cf69[_0x2fa117('0x1c47')],_0x22cf69['dualMultiselectOptions'][_0x2fa117('0x1378')],'id'),_0x35a21b();})['catch'](function(_0x56c6d7){_0x5c87cc(_0x56c6d7);});});}function _0x279894(){return _0x2e5db9(function(_0x427e4e,_0x2dc08a){const _0x244a29=a0_0x4e0a;return _0x4083fb[_0x244a29('0xcf7')][_0x244a29('0x1e6e')]({'sectionId':_0x22cf69[_0x244a29('0x1aa')]['id'],'nolimit':!![]})[_0x244a29('0xe53')][_0x244a29('0x683')](function(_0x159cd2){_0x427e4e(_0x159cd2);})[_0x244a29('0x130a')](function(_0x393314){_0x2dc08a(_0x393314);});});}function _0x81c611(){return _0x2e5db9(function(_0x1d9442,_0x10e198){const _0x261c1b=a0_0x4e0a;return _0x4083fb['chatQueue'][_0x261c1b('0xf90')]({'id':_0x22cf69[_0x261c1b('0x1524')]['id'],'fields':_0x261c1b('0xa10'),'nolimit':!![]})[_0x261c1b('0xe53')][_0x261c1b('0x683')](function(_0x5eeb16){_0x1d9442(_0x5eeb16);})[_0x261c1b('0x130a')](function(_0x36d02d){_0x10e198(_0x36d02d);});});}function _0x173f8d(){return _0x2e5db9(function(_0x5a1b26,_0x1ad691){const _0x173c4a=a0_0x4e0a;return _0x4083fb['team']['get']({'fields':_0x173c4a('0xa10'),'nolimit':!![]})[_0x173c4a('0xe53')][_0x173c4a('0x683')](function(_0x5377bc){_0x5a1b26(_0x5377bc);})[_0x173c4a('0x130a')](function(_0x5779e5){_0x1ad691(_0x5779e5);});});}function _0x261ca4(_0x24ddc0){return _0x2e5db9(function(_0x5d2f04,_0x41c0c2){const _0x4caaa5=a0_0x4e0a;_0x2e3ca0()[_0x4caaa5('0x173f')](_0x24ddc0)?_0x5d2f04():_0x4083fb['chatQueue'][_0x4caaa5('0x1558')]({'id':_0x22cf69[_0x4caaa5('0x1524')]['id'],'ids':_0x2e3ca0()[_0x4caaa5('0x386')](_0x24ddc0,'id')})[_0x4caaa5('0xe53')]['then'](function(){_0x5d2f04();})[_0x4caaa5('0x130a')](function(_0x5212fc){_0x41c0c2(_0x5212fc);});});}function _0xe230ab(_0x17579d){return _0x2e5db9(function(_0x298f5d,_0x497b67){const _0x30dddf=a0_0x4e0a;_0x2e3ca0()[_0x30dddf('0x173f')](_0x17579d)?_0x298f5d():_0x4083fb[_0x30dddf('0x1524')]['removeTeams']({'id':_0x22cf69[_0x30dddf('0x1524')]['id'],'ids':_0x2e3ca0()[_0x30dddf('0x386')](_0x17579d,'id')})[_0x30dddf('0xe53')][_0x30dddf('0x683')](function(){_0x298f5d();})[_0x30dddf('0x130a')](function(_0x36084b){_0x497b67(_0x36084b);});});}function _0x321cbf(){const _0x238c91=_0x3d36b9,_0x4c5b0c=_0x2e3ca0()[_0x238c91('0x461')](_0x22cf69['startingSelectedItems'],_0x22cf69[_0x238c91('0x1378')],'id'),_0x32880d=_0x2e3ca0()[_0x238c91('0x461')](_0x22cf69['selectedItems'],_0x22cf69[_0x238c91('0x23a7')],'id');return _0xe230ab(_0x4c5b0c)[_0x238c91('0x683')](function(){return _0x261ca4(_0x32880d);})['then'](function(){const _0x3d2b97=_0x238c91;_0x22cf69[_0x3d2b97('0x2106')]=![],_0x22cf69[_0x3d2b97('0x125e')]=angular[_0x3d2b97('0x1a86')](_0x22cf69[_0x3d2b97('0x1c47')]),_0x22cf69[_0x3d2b97('0x23a7')]=angular[_0x3d2b97('0x1a86')](_0x22cf69[_0x3d2b97('0x1378')]),_0x4ff6c8[_0x3d2b97('0x53')]({'title':_0x3d2b97('0xd28'),'msg':_0x3d2b97('0x476')});})['catch'](function(_0xff664b){const _0x1389bd=_0x238c91;_0x4ff6c8[_0x1389bd('0x52a')]({'title':_0xff664b[_0x1389bd('0x13ee')]?'API:'+_0xff664b[_0x1389bd('0x13ee')]+_0x1389bd('0xbf6')+_0xff664b[_0x1389bd('0x24a9')]:_0x1389bd('0x1b71'),'msg':_0xff664b[_0x1389bd('0x13ee')]?JSON[_0x1389bd('0x258a')](_0xff664b['data']):_0xff664b[_0x1389bd('0x1ff0')]()});});}function _0x27c996(){const _0x4fbdb7=_0x3d36b9;_0x490093[_0x4fbdb7('0x1715')]();}}const _0x51f73b=_0x513619;_0x251fb3[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$document',_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),'api','toasty',_0x189033('0xba1'),_0x189033('0x1524'),'userProfileSection'];function _0x251fb3(_0x5a6ce5,_0x474eef,_0x547d6e,_0x2138ed,_0x1722de,_0x5ae1d7,_0x5b9633,_0x26130b,_0x529524,_0x11c3af,_0xc4796f,_0x8219f7){const _0x3da691=_0x189033,_0x20936a=this;_0x20936a[_0x3da691('0x11ed')]=_0x11c3af[_0x3da691('0x20b2')](),_0x20936a[_0x3da691('0xace')]=_0x5ae1d7,_0x20936a[_0x3da691('0x260a')]=_0x5b9633,_0x20936a['passwordPattern']=_0x20936a[_0x3da691('0x260a')][_0x3da691('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x20936a['location']=_0x474eef['protocol']()+'://'+_0x474eef[_0x3da691('0x19ac')](),_0x20936a[_0x3da691('0x1524')]=_0xc4796f||_0x5a6ce5[_0x3da691('0x7f2')][_0x3da691('0x1524')]||{},_0x20936a['userProfileSection']=_0x8219f7&&_0x8219f7[_0x3da691('0x50d')]==0x1?_0x8219f7[_0x3da691('0xf5d')][0x0]:null,_0x20936a['crudPermissions']=_0x11c3af[_0x3da691('0x142a')](_0x20936a[_0x3da691('0x22df')]?_0x20936a[_0x3da691('0x22df')][_0x3da691('0x1134')]:null),_0x20936a[_0x3da691('0x258d')]={},_0x20936a[_0x3da691('0x517')]=_0x5a6ce5['params'][_0x3da691('0x1904')]||0x0,_0x20936a[_0x3da691('0xe0e')]=_0x3f1b13,_0x20936a[_0x3da691('0x2814')]=_0x34c021,_0x20936a[_0x3da691('0x2430')]=_0x529524['info'],_0x20936a['gotoChatQueues']=_0x1088ec,_0x20936a[_0x3da691('0x2374')]=_0x12ae49;function _0x3f1b13(_0x145c29,_0x34c931){const _0x52d44a=_0x3da691;_0x547d6e['show']({'controller':_0x52d44a('0x885'),'controllerAs':'vm','templateUrl':_0x34047b,'parent':angular['element'](_0x2138ed[_0x52d44a('0x18e5')]),'targetEvent':_0x34c931,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x145c29,'chatQueues':_0x20936a[_0x52d44a('0x1253')]?_0x20936a[_0x52d44a('0x1253')]['rows']:[],'crudPermissions':_0x20936a['crudPermissions']}});}function _0x34c021(_0x3f1a4c,_0x435a6b){const _0x1476c4=_0x3da691;_0x547d6e[_0x1476c4('0x1d4')]({'controller':_0x1476c4('0x1062'),'controllerAs':'vm','templateUrl':_0x54d9f2,'parent':angular[_0x1476c4('0x1fcc')](_0x2138ed[_0x1476c4('0x18e5')]),'targetEvent':_0x435a6b,'clickOutsideToClose':!![],'locals':{'chatQueue':_0x3f1a4c,'chatQueues':_0x20936a[_0x1476c4('0x1253')]?_0x20936a[_0x1476c4('0x1253')][_0x1476c4('0xf5d')]:[],'crudPermissions':_0x20936a[_0x1476c4('0x1134')],'realtime':![]}});}function _0x1088ec(){const _0x2a85d4=_0x3da691;_0x5a6ce5['go'](_0x2a85d4('0x23c4'),{},{'reload':_0x2a85d4('0x23c4')});}function _0x12ae49(){const _0x809878=_0x3da691;_0x26130b[_0x809878('0x1524')]['update']({'id':_0x20936a[_0x809878('0x1524')]['id']},_0x20936a[_0x809878('0x1524')])[_0x809878('0xe53')][_0x809878('0x683')](function(){const _0x18e030=_0x809878;_0x529524[_0x18e030('0x53')]({'title':_0x18e030('0x20d1'),'msg':_0x20936a[_0x18e030('0x1524')][_0x18e030('0x60a')]?_0x20936a['chatQueue'][_0x18e030('0x60a')]+'\x20has\x20been\x20updated!':''});})[_0x809878('0x130a')](function(_0x430870){const _0x4a0a9e=_0x809878;_0x529524['error']({'title':_0x430870[_0x4a0a9e('0x13ee')]?_0x4a0a9e('0x2168')+_0x430870[_0x4a0a9e('0x13ee')]+_0x4a0a9e('0xbf6')+_0x430870[_0x4a0a9e('0x24a9')]:'SYSTEM:GETchatQueue','msg':_0x430870[_0x4a0a9e('0x5a5')]?JSON['stringify'](_0x430870[_0x4a0a9e('0x5a5')]):_0x430870[_0x4a0a9e('0x1ff0')]()});});}}const _0x40b128=_0x251fb3,_0x2c9b33=_0x180212['p']+_0x189033('0x25d1'),_0x301dd2=_0x180212['p']+_0x189033('0x8e');_0xa52999[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$window','$state',_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x25a1'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0xa52999(_0x8b6d27,_0x379f01,_0x9b3c27,_0x5beb11,_0x520cf5,_0x32c48f,_0x2304c8,_0x5c370a,_0x2008b3,_0x1c2e9a,_0x4bf25a,_0x1aa940,_0x1f319a,_0x33d170,_0x5e2905,_0x4b50fd,_0x3adee3){const _0x207f6=_0x189033,_0x570320=this;_0x570320['license']=_0x4b50fd,_0x570320[_0x207f6('0x260a')]=_0x3adee3,_0x570320['currentUser']=_0x5e2905['getCurrentUser'](),_0x570320['chatWebsites']=_0x2008b3||{'count':0x0,'rows':[]},_0x570320['userProfile']=_0x1c2e9a,_0x570320[_0x207f6('0x22df')]=_0x4bf25a&&_0x4bf25a[_0x207f6('0x50d')]==0x1?_0x4bf25a[_0x207f6('0xf5d')][0x0]:null,_0x570320[_0x207f6('0x1134')]=_0x5e2905[_0x207f6('0x142a')](_0x570320[_0x207f6('0x22df')]?_0x570320[_0x207f6('0x22df')]['crudPermissions']:null),_0x570320[_0x207f6('0x5c4')]=_0x207f6('0x25a1'),_0x570320['listOrder']='',_0x570320[_0x207f6('0x1ce2')]=null,_0x570320['selectedChatWebsites']=[],_0x570320[_0x207f6('0x23a2')]={'fields':_0x207f6('0x7a'),'sort':_0x207f6('0xc36'),'limit':0xa,'page':0x1},_0x570320['arrayagentIdentifier']=_0x2e3ca0()[_0x207f6('0x24db')]([{'option':'WebsiteAlias','value':_0x207f6('0x1a64')},{'option':_0x207f6('0x1bfd'),'value':_0x207f6('0xfbb')},{'option':_0x207f6('0xfe6'),'value':_0x207f6('0x15c7')}],function(_0x5a2513){const _0x5027e4=_0x207f6;return _0x2e3ca0()[_0x5027e4('0x1725')](_0x5a2513['value'],new RegExp('\x27','g'),'');}),_0x570320[_0x207f6('0x272c')]=_0x2e3ca0()['keyBy']([{'option':_0x207f6('0x27f8'),'value':_0x207f6('0x1af1')},{'option':'Squared','value':_0x207f6('0x1cff')}],function(_0x226707){const _0x1a7428=_0x207f6;return _0x2e3ca0()['replace'](_0x226707[_0x1a7428('0x1c6b')],new RegExp('\x27','g'),'');}),_0x570320['arrayalignment']=_0x2e3ca0()[_0x207f6('0x24db')]([{'option':_0x207f6('0x1601'),'value':'\x27bottom_right\x27'},{'option':_0x207f6('0x20b1'),'value':_0x207f6('0xec4')},{'option':_0x207f6('0xc0e'),'value':'\x27left\x27'}],function(_0x32c323){const _0x24e1b5=_0x207f6;return _0x2e3ca0()['replace'](_0x32c323[_0x24e1b5('0x1c6b')],new RegExp('\x27','g'),'');}),_0x570320['arraymessagesAlignment']=_0x2e3ca0()[_0x207f6('0x24db')]([{'option':_0x207f6('0xc11'),'value':_0x207f6('0x192')},{'option':'centered','value':'\x27centered\x27'}],function(_0x2249dc){const _0x5c0ec5=_0x207f6;return _0x2e3ca0()['replace'](_0x2249dc[_0x5c0ec5('0x1c6b')],new RegExp('\x27','g'),'');}),_0x570320[_0x207f6('0x1ec2')]=_0x2e3ca0()['keyBy']([{'option':_0x207f6('0x5e6'),'value':'\x27star\x27'},{'option':_0x207f6('0x7bc'),'value':_0x207f6('0x18c7')}],function(_0x4acc5a){const _0x483f9d=_0x207f6;return _0x2e3ca0()[_0x483f9d('0x1725')](_0x4acc5a[_0x483f9d('0x1c6b')],new RegExp('\x27','g'),'');}),_0x570320[_0x207f6('0xc63')]=_0x165802,_0x570320[_0x207f6('0xce9')]=_0x3b9886,_0x570320['offlinemessagesgoto']=_0x57bd03,_0x570320[_0x207f6('0x2814')]=_0x3801cc,_0x570320['deleteconfirm']=_0x476bc7,_0x570320[_0x207f6('0x53')]=_0x2de06a,_0x570320[_0x207f6('0x24ee')]=_0x2335b2,_0x570320[_0x207f6('0x21ea')]=_0x2cd2cc,_0x570320[_0x207f6('0x1190')]=_0x334b39,_0x570320[_0x207f6('0x1c38')]=_0x34dc65,_0x570320['deleteSelectedChatWebsites']=_0x2fa87b,_0x570320[_0x207f6('0x1899')]=_0x55f197,_0x570320[_0x207f6('0x20dc')]=_0x2f6ded,_0x5e2905[_0x207f6('0xca1')](_0x207f6('0x20c2'))?_0x1aa940['cmList']['get']({'fields':_0x207f6('0xa10'),'sort':_0x207f6('0x60a')})[_0x207f6('0xe53')]['then'](function(_0x4adbc8){const _0x2e66b2=_0x207f6;_0x570320['lists']=_0x4adbc8[_0x2e66b2('0xf5d')]||[];})[_0x207f6('0x130a')](function(_0x2564b7){const _0x1a35fb=_0x207f6;_0x33d170[_0x1a35fb('0x52a')]({'title':_0x2564b7[_0x1a35fb('0x13ee')]?_0x1a35fb('0x2168')+_0x2564b7['status']+_0x1a35fb('0xbf6')+_0x2564b7[_0x1a35fb('0x24a9')]:_0x1a35fb('0x251b'),'msg':_0x2564b7[_0x1a35fb('0x5a5')]?JSON[_0x1a35fb('0x258a')](_0x2564b7[_0x1a35fb('0x5a5')]):_0x2564b7['toString']()});}):_0x1aa940[_0x207f6('0x259b')][_0x207f6('0x1e6e')]({'fields':'id,name','sort':_0x207f6('0x60a')})[_0x207f6('0xe53')][_0x207f6('0x683')](function(_0x2181ca){const _0x20441c=_0x207f6;_0x570320[_0x20441c('0xe01')]=_0x2181ca[_0x20441c('0xf5d')]||[];})[_0x207f6('0x683')](function(){const _0xb8ff37=_0x207f6;return _0x1aa940['userProfileSection'][_0xb8ff37('0x1e6e')]({'userProfileId':_0x570320[_0xb8ff37('0x11ed')][_0xb8ff37('0x2f')],'sectionId':0x12d})['$promise'];})[_0x207f6('0x683')](function(_0x9508b7){const _0x3b86a3=_0x207f6,_0x562ad0=_0x9508b7&&_0x9508b7['rows']?_0x9508b7['rows'][0x0]:null;if(!_0x562ad0){const _0x254056=[];let _0xa17fb2=null;_0x570320['chatWebsite']&&(_0xa17fb2=_0x2e3ca0()['find'](_0x570320[_0x3b86a3('0xe01')],{'id':Number(_0x570320[_0x3b86a3('0x2681')][_0x3b86a3('0x1e4f')])}));for(let _0x5e9040=0x0;_0x5e9040<_0x570320[_0x3b86a3('0xe01')][_0x3b86a3('0x1564')];_0x5e9040++){_0xa17fb2&&_0x570320[_0x3b86a3('0xe01')][_0x5e9040]['id']===_0xa17fb2['id']&&(_0x570320[_0x3b86a3('0xe01')][_0x5e9040]['canSelect']=![],_0x254056[_0x3b86a3('0x1fd0')](_0x570320[_0x3b86a3('0xe01')][_0x5e9040]));}_0x570320[_0x3b86a3('0xe01')]=_0x254056;}else{if(!_0x562ad0['autoAssociation'])return _0x1aa940['userProfileResource']['get']({'sectionId':_0x562ad0['id']})[_0x3b86a3('0xe53')][_0x3b86a3('0x683')](function(_0x3ecca5){const _0x4c941a=_0x3b86a3,_0x5c9e17=_0x2e3ca0()['map'](_0x3ecca5[_0x4c941a('0xf5d')],function(_0x53fcef){const _0x3efdea=_0x4c941a;return _0x2e3ca0()[_0x3efdea('0x1c07')](_0x570320[_0x3efdea('0xe01')],{'id':_0x53fcef[_0x3efdea('0x832')]});});let _0x14928e=null;_0x570320['chatWebsite']&&(_0x14928e=_0x2e3ca0()[_0x4c941a('0x1c07')](_0x570320[_0x4c941a('0xe01')],{'id':Number(_0x570320['chatWebsite'][_0x4c941a('0x1e4f')])}));if(_0x14928e&&!_0x2e3ca0()['some'](_0x5c9e17,['id',_0x14928e['id']])){const _0x13899e=_0x2e3ca0()[_0x4c941a('0x1c07')](_0x570320[_0x4c941a('0xe01')],{'id':_0x14928e['id']});_0x13899e['canSelect']=![],_0x5c9e17['push'](_0x13899e);}_0x570320['lists']=_0x5c9e17;});}})[_0x207f6('0x130a')](function(_0x324178){const _0x3ebfc0=_0x207f6;_0x33d170[_0x3ebfc0('0x52a')]({'title':_0x324178[_0x3ebfc0('0x13ee')]?_0x3ebfc0('0x2168')+_0x324178['status']+_0x3ebfc0('0xbf6')+_0x324178[_0x3ebfc0('0x24a9')]:_0x3ebfc0('0x11e3'),'msg':_0x324178[_0x3ebfc0('0x5a5')]?JSON[_0x3ebfc0('0x258a')](_0x324178[_0x3ebfc0('0x5a5')]):_0x324178[_0x3ebfc0('0x1ff0')]()});}),_0x5e2905[_0x207f6('0xca1')](_0x207f6('0x20c2'))?_0x1aa940[_0x207f6('0x115c')][_0x207f6('0x1e6e')]({'fields':_0x207f6('0xa10'),'sort':_0x207f6('0x60a'),'IntervalId':_0x207f6('0x13c')})[_0x207f6('0xe53')]['then'](function(_0x43490b){const _0xff0a17=_0x207f6;_0x570320[_0xff0a17('0x115c')]=_0x43490b[_0xff0a17('0xf5d')]||[];})[_0x207f6('0x130a')](function(_0x5f19c4){const _0x50dc71=_0x207f6;_0x33d170['error']({'title':_0x5f19c4[_0x50dc71('0x13ee')]?_0x50dc71('0x2168')+_0x5f19c4[_0x50dc71('0x13ee')]+'\x20-\x20'+_0x5f19c4[_0x50dc71('0x24a9')]:'SYSTEM:GET_INTERVAL','msg':_0x5f19c4[_0x50dc71('0x5a5')]?JSON[_0x50dc71('0x258a')](_0x5f19c4[_0x50dc71('0x5a5')]):_0x5f19c4[_0x50dc71('0x1ff0')]()});}):_0x1aa940['interval'][_0x207f6('0x1e6e')]({'fields':_0x207f6('0xa10'),'sort':_0x207f6('0x60a'),'IntervalId':'null'})[_0x207f6('0xe53')][_0x207f6('0x683')](function(_0x339934){const _0x51c968=_0x207f6;_0x570320[_0x51c968('0x115c')]=_0x339934[_0x51c968('0xf5d')]||[];})[_0x207f6('0x683')](function(){const _0x2e53ab=_0x207f6;return _0x1aa940['userProfileSection'][_0x2e53ab('0x1e6e')]({'userProfileId':_0x570320[_0x2e53ab('0x11ed')][_0x2e53ab('0x2f')],'sectionId':0x3ec})[_0x2e53ab('0xe53')];})['then'](function(_0x115aa3){const _0x45adc0=_0x207f6,_0x299f74=_0x115aa3&&_0x115aa3[_0x45adc0('0xf5d')]?_0x115aa3[_0x45adc0('0xf5d')][0x0]:null;if(!_0x299f74){const _0xefdafa=[];let _0x1b362b=null;_0x570320[_0x45adc0('0x2681')]&&(_0x1b362b=_0x2e3ca0()['find'](_0x570320['interval'],{'id':Number(_0x570320[_0x45adc0('0x2681')][_0x45adc0('0x5ae')])}));for(let _0xd77546=0x0;_0xd77546<_0x570320[_0x45adc0('0x115c')][_0x45adc0('0x1564')];_0xd77546++){_0x1b362b&&_0x570320[_0x45adc0('0x115c')][_0xd77546]['id']===_0x1b362b['id']&&(_0x570320['interval'][_0xd77546][_0x45adc0('0x319')]=![],_0xefdafa['push'](_0x570320[_0x45adc0('0x115c')][_0xd77546]));}_0x570320[_0x45adc0('0x115c')]=_0xefdafa;}else{if(!_0x299f74[_0x45adc0('0x170')])return _0x1aa940[_0x45adc0('0xcf7')][_0x45adc0('0x1e6e')]({'sectionId':_0x299f74['id']})['$promise'][_0x45adc0('0x683')](function(_0x252f64){const _0x2aae66=_0x45adc0,_0x404cc6=_0x2e3ca0()[_0x2aae66('0x386')](_0x252f64[_0x2aae66('0xf5d')],function(_0xb2c7e3){const _0xaf7c22=_0x2aae66;return _0x2e3ca0()[_0xaf7c22('0x1c07')](_0x570320['interval'],{'id':_0xb2c7e3[_0xaf7c22('0x832')]});});let _0xf37e3e=null;_0x570320[_0x2aae66('0x2681')]&&(_0xf37e3e=_0x2e3ca0()[_0x2aae66('0x1c07')](_0x570320[_0x2aae66('0x115c')],{'id':Number(_0x570320[_0x2aae66('0x2681')][_0x2aae66('0x5ae')])}));if(_0xf37e3e&&!_0x2e3ca0()['some'](_0x404cc6,['id',_0xf37e3e['id']])){const _0x1cd5d8=_0x2e3ca0()['find'](_0x570320[_0x2aae66('0x115c')],{'id':_0xf37e3e['id']});_0x1cd5d8[_0x2aae66('0x319')]=![],_0x404cc6[_0x2aae66('0x1fd0')](_0x1cd5d8);}_0x570320[_0x2aae66('0x115c')]=_0x404cc6;});}})[_0x207f6('0x130a')](function(_0x1b70d1){const _0x420f1d=_0x207f6;_0x33d170[_0x420f1d('0x52a')]({'title':_0x1b70d1['status']?_0x420f1d('0x2168')+_0x1b70d1[_0x420f1d('0x13ee')]+'\x20-\x20'+_0x1b70d1[_0x420f1d('0x24a9')]:_0x420f1d('0x203'),'msg':_0x1b70d1[_0x420f1d('0x5a5')]?JSON[_0x420f1d('0x258a')](_0x1b70d1[_0x420f1d('0x5a5')]):_0x1b70d1[_0x420f1d('0x1ff0')]()});});function _0x165802(_0x251acd){const _0x37723e=_0x207f6;_0x9b3c27['go']('app.chat.chatWebsites.edit',{'id':_0x251acd['id'],'chatWebsite':_0x251acd,'crudPermissions':_0x570320[_0x37723e('0x1134')]});}function _0x3b9886(_0x59ad56){const _0x573e4e=_0x207f6;_0x9b3c27['go'](_0x573e4e('0x1ae4'),{'id':_0x59ad56['id'],'tab':0xa});}function _0x57bd03(_0x3c9c9b){const _0x1cd061=_0x207f6;_0x9b3c27['go'](_0x1cd061('0x1ae4'),{'id':_0x3c9c9b['id'],'tab':0xb});}function _0x3801cc(_0x957647,_0x13db13){const _0x2b4368=_0x207f6;_0x520cf5[_0x2b4368('0x1d4')]({'controller':_0x2b4368('0x465'),'controllerAs':'vm','templateUrl':_0x2c9b33,'parent':angular[_0x2b4368('0x1fcc')](_0x32c48f[_0x2b4368('0x18e5')]),'targetEvent':_0x13db13,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x957647,'chatWebsites':_0x570320[_0x2b4368('0x25a1')]?_0x570320[_0x2b4368('0x25a1')]['rows']:[],'crudPermissions':_0x570320[_0x2b4368('0x1134')],'realtime':![]}});}function _0x476bc7(_0x105959,_0x5e0d8e){const _0x573186=_0x207f6,_0x585c36=_0x520cf5[_0x573186('0x1c6f')]()[_0x573186('0xf28')](_0x573186('0x1b01')+_0x2e3ca0()[_0x573186('0x1e03')](_0x573186('0x2681'))+'?')['htmlContent'](''+(_0x105959[_0x573186('0x60a')]||_0x573186('0x2681'))+_0x573186('0x20f1')+_0x573186('0x1ee7'))['ariaLabel'](_0x573186('0x2214'))[_0x573186('0xe42')](_0x5e0d8e)['ok']('OK')['cancel'](_0x573186('0x16b8'));_0x520cf5[_0x573186('0x1d4')](_0x585c36)[_0x573186('0x683')](function(){_0x334b39(_0x105959);},function(){const _0x29b081=_0x573186;console[_0x29b081('0x1b2b')](_0x29b081('0x16b8'));});}let _0x2f2497=!![],_0x2a1b7f=0x1;_0x8b6d27[_0x207f6('0x186d')](_0x207f6('0x1e1d'),function(_0x202d28,_0x19b817){const _0x2b5bfb=_0x207f6;_0x2f2497?_0x2304c8(function(){_0x2f2497=![];}):(!_0x19b817&&(_0x2a1b7f=_0x570320[_0x2b5bfb('0x23a2')][_0x2b5bfb('0xdf8')]),_0x202d28!==_0x19b817&&(_0x570320['query'][_0x2b5bfb('0xdf8')]=0x1),!_0x202d28&&(_0x570320[_0x2b5bfb('0x23a2')][_0x2b5bfb('0xdf8')]=_0x2a1b7f),_0x570320[_0x2b5bfb('0x24ee')]());});function _0x2de06a(_0x2cc34c){const _0x4fe0d1=_0x207f6;_0x570320[_0x4fe0d1('0x25a1')]=_0x2cc34c||{'count':0x0,'rows':[]};}function _0x2335b2(){const _0x15833e=_0x207f6;_0x570320['query'][_0x15833e('0x1cc8')]=(_0x570320[_0x15833e('0x23a2')]['page']-0x1)*_0x570320['query']['limit'],_0x5e2905[_0x15833e('0xca1')](_0x15833e('0x20c2'))?_0x570320[_0x15833e('0x1883')]=_0x1aa940[_0x15833e('0x2681')][_0x15833e('0x1e6e')](_0x570320[_0x15833e('0x23a2')],_0x2de06a)[_0x15833e('0xe53')]:(_0x570320[_0x15833e('0x23a2')]['id']=_0x570320['userProfile']['id'],_0x570320[_0x15833e('0x23a2')]['section']=_0x15833e('0x1a18'),_0x570320[_0x15833e('0x1883')]=_0x1aa940[_0x15833e('0x2a')][_0x15833e('0x241d')](_0x570320[_0x15833e('0x23a2')],_0x2de06a)[_0x15833e('0xe53')]);}function _0x2cd2cc(_0x426ca0,_0x21e766){const _0x23688c=_0x207f6;_0x520cf5[_0x23688c('0x1d4')]({'controller':'CreateOrEditChatWebsiteDialogController','controllerAs':'vm','templateUrl':_0x301dd2,'parent':angular[_0x23688c('0x1fcc')](_0x32c48f[_0x23688c('0x18e5')]),'targetEvent':_0x426ca0,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x21e766,'chatWebsites':_0x570320[_0x23688c('0x25a1')][_0x23688c('0xf5d')],'license':_0x570320[_0x23688c('0xace')],'setting':_0x570320[_0x23688c('0x260a')],'crudPermissions':_0x570320[_0x23688c('0x1134')]}});}function _0x334b39(_0xc4b685){const _0x62f5b0=_0x207f6;_0x1aa940['chatWebsite'][_0x62f5b0('0xd7e')]({'id':_0xc4b685['id']})['$promise'][_0x62f5b0('0x683')](function(){const _0x145c9b=_0x62f5b0;_0x2e3ca0()['remove'](_0x570320[_0x145c9b('0x25a1')][_0x145c9b('0xf5d')],{'id':_0xc4b685['id']}),_0x570320[_0x145c9b('0x25a1')][_0x145c9b('0x50d')]-=0x1,!_0x570320['chatWebsites'][_0x145c9b('0xf5d')][_0x145c9b('0x1564')]&&_0x570320['getChatWebsites'](),_0x33d170[_0x145c9b('0x53')]({'title':_0x2e3ca0()[_0x145c9b('0x1e03')](_0x145c9b('0x840'))+'\x20deleted!','msg':_0xc4b685[_0x145c9b('0x60a')]?_0xc4b685[_0x145c9b('0x60a')]+_0x145c9b('0x194d'):''});})[_0x62f5b0('0x130a')](function(_0x230fa7){const _0x2c77b2=_0x62f5b0;if(_0x230fa7[_0x2c77b2('0x5a5')]&&_0x230fa7[_0x2c77b2('0x5a5')][_0x2c77b2('0x17f')]&&_0x230fa7[_0x2c77b2('0x5a5')][_0x2c77b2('0x17f')]['length']){_0x570320[_0x2c77b2('0x17f')]=_0x230fa7['data'][_0x2c77b2('0x17f')]||[{'message':_0x230fa7[_0x2c77b2('0x1ff0')](),'type':'SYSTEM:DELETEchatWebsite'}];for(let _0x2f37eb=0x0;_0x2f37eb<_0x230fa7[_0x2c77b2('0x5a5')]['errors']['length'];_0x2f37eb++){_0x33d170[_0x2c77b2('0x52a')]({'title':_0x230fa7[_0x2c77b2('0x5a5')][_0x2c77b2('0x17f')][_0x2f37eb][_0x2c77b2('0xcf0')],'msg':_0x230fa7[_0x2c77b2('0x5a5')][_0x2c77b2('0x17f')][_0x2f37eb][_0x2c77b2('0x8c2')]});}}else _0x33d170[_0x2c77b2('0x52a')]({'title':_0x230fa7[_0x2c77b2('0x13ee')]?_0x2c77b2('0x2168')+_0x230fa7[_0x2c77b2('0x13ee')]+'\x20-\x20'+_0x230fa7[_0x2c77b2('0x24a9')]:_0x2c77b2('0x66b'),'msg':_0x230fa7[_0x2c77b2('0x5a5')]?JSON[_0x2c77b2('0x258a')](_0x230fa7['data'][_0x2c77b2('0x8c2')]):_0x230fa7['message']||_0x230fa7['toString']()});});}function _0x34dc65(){const _0x233c32=_0x207f6,_0x4032d3=angular[_0x233c32('0x1a86')](_0x570320[_0x233c32('0x1a01')]);return _0x570320[_0x233c32('0x1a01')]=[],_0x4032d3;}function _0x2fa87b(_0x2c64ec){const _0x45a91a=_0x207f6,_0x41f77e=_0x520cf5[_0x45a91a('0x1c6f')]()[_0x45a91a('0xf28')](_0x45a91a('0x22a9'))['htmlContent'](''+_0x570320['selectedChatWebsites'][_0x45a91a('0x1564')]+_0x45a91a('0x93c')+_0x45a91a('0x1ee7'))[_0x45a91a('0x1040')](_0x45a91a('0x246c'))['targetEvent'](_0x2c64ec)['ok']('OK')[_0x45a91a('0x19fb')](_0x45a91a('0x16b8'));_0x520cf5[_0x45a91a('0x1d4')](_0x41f77e)[_0x45a91a('0x683')](function(){const _0x3989d5=_0x45a91a;_0x570320[_0x3989d5('0x1a01')][_0x3989d5('0x1299')](function(_0x357005){_0x334b39(_0x357005);}),_0x570320[_0x3989d5('0x1a01')]=[];});}function _0x55f197(){const _0x4dc53a=_0x207f6;_0x570320[_0x4dc53a('0x1a01')]=[];}function _0x2f6ded(){const _0xcd8da3=_0x207f6;_0x570320[_0xcd8da3('0x1a01')]=_0x570320['chatWebsites'][_0xcd8da3('0xf5d')];}}const _0x58baa3=_0xa52999;_0x5dcd6a[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty',_0x189033('0x25a1'),_0x189033('0x2681'),_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x5dcd6a(_0x16656e,_0x17c997,_0x5499b7,_0xfe2ea9,_0x416077,_0x4773bd,_0x5b816e,_0x2deddc,_0x5a0ec5,_0x126c04,_0x24f77e,_0x31c11e,_0x2e97a1,_0x323c06){const _0x1808a7=_0x189033,_0x29428d=this;_0x29428d[_0x1808a7('0x11ed')]=_0x24f77e[_0x1808a7('0x20b2')](),_0x29428d[_0x1808a7('0x17f')]=[],_0x29428d['setting']=_0x2e97a1,_0x29428d[_0x1808a7('0xace')]=_0x31c11e,_0x29428d[_0x1808a7('0x1134')]=_0x323c06,_0x29428d[_0x1808a7('0x258d')]={},_0x29428d[_0x1808a7('0x19b2')]=_0x29428d[_0x1808a7('0x260a')]&&_0x29428d['setting'][_0x1808a7('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x29428d[_0x1808a7('0xf28')]=_0x1808a7('0x534'),_0x29428d[_0x1808a7('0x2681')]=angular[_0x1808a7('0x1a86')](_0x5a0ec5),_0x29428d[_0x1808a7('0x25a1')]=_0x2deddc,_0x29428d[_0x1808a7('0x1280')]=![];!_0x29428d[_0x1808a7('0x2681')]&&(_0x29428d[_0x1808a7('0x2681')]={'remote':_0x5499b7[_0x1808a7('0x173e')]()+'://'+_0x5499b7[_0x1808a7('0x19ac')]()+(_0x5499b7[_0x1808a7('0x4a2')]()?':'+_0x5499b7['port']():''),'header_shape':_0x1808a7('0x1e5f'),'alignment':_0x1808a7('0x1601'),'verticalAlignment':0x1e,'messagesAlignment':_0x1808a7('0xc11'),'IntervalId':'null','timezone':_0x1808a7('0x13c'),'waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0x29428d[_0x1808a7('0xf28')]=_0x1808a7('0xb94'),_0x29428d[_0x1808a7('0x1280')]=!![]);_0x17c997[_0x1808a7('0x7f2')]['id']&&(_0x29428d['chatWebsite'][_0x1808a7('0x15a5')]=_0x17c997[_0x1808a7('0x7f2')]['id']);_0x29428d[_0x1808a7('0xeb6')]=_0x58865b,_0x29428d[_0x1808a7('0x25b0')]=_0x22d217,_0x29428d[_0x1808a7('0x1190')]=_0x36ad4c,_0x29428d[_0x1808a7('0x16b3')]=_0x64ddb2,_0x29428d['closeDialog']=_0x32c09d,_0x24f77e['hasRole'](_0x1808a7('0x20c2'))?_0x126c04[_0x1808a7('0x259b')][_0x1808a7('0x1e6e')]({'fields':_0x1808a7('0xa10'),'sort':_0x1808a7('0x60a')})[_0x1808a7('0xe53')]['then'](function(_0x56df57){const _0x25be15=_0x1808a7;_0x29428d[_0x25be15('0xe01')]=_0x56df57[_0x25be15('0xf5d')]||[];})[_0x1808a7('0x130a')](function(_0x406ac3){const _0x45cbbf=_0x1808a7;_0x5b816e[_0x45cbbf('0x52a')]({'title':_0x406ac3[_0x45cbbf('0x13ee')]?_0x45cbbf('0x2168')+_0x406ac3['status']+_0x45cbbf('0xbf6')+_0x406ac3[_0x45cbbf('0x24a9')]:_0x45cbbf('0x251b'),'msg':_0x406ac3[_0x45cbbf('0x5a5')]?JSON[_0x45cbbf('0x258a')](_0x406ac3[_0x45cbbf('0x5a5')]):_0x406ac3[_0x45cbbf('0x1ff0')]()});}):_0x126c04[_0x1808a7('0x259b')][_0x1808a7('0x1e6e')]({'fields':_0x1808a7('0xa10'),'sort':_0x1808a7('0x60a')})[_0x1808a7('0xe53')][_0x1808a7('0x683')](function(_0x333073){const _0x494cfc=_0x1808a7;_0x29428d['lists']=_0x333073[_0x494cfc('0xf5d')]||[];})['then'](function(){const _0x228736=_0x1808a7;return _0x126c04[_0x228736('0x22df')]['get']({'userProfileId':_0x29428d['currentUser'][_0x228736('0x2f')],'sectionId':0x12d})[_0x228736('0xe53')];})[_0x1808a7('0x683')](function(_0x215943){const _0xfd63e4=_0x1808a7,_0x54f8d0=_0x215943&&_0x215943['rows']?_0x215943['rows'][0x0]:null;if(!_0x54f8d0){const _0x3c872e=[];let _0x5d30e6=null;_0x29428d['chatWebsite']&&(_0x5d30e6=_0x2e3ca0()['find'](_0x29428d[_0xfd63e4('0xe01')],{'id':Number(_0x29428d['chatWebsite'][_0xfd63e4('0x1e4f')])}));for(let _0x4e3e81=0x0;_0x4e3e81<_0x29428d[_0xfd63e4('0xe01')][_0xfd63e4('0x1564')];_0x4e3e81++){_0x5d30e6&&_0x29428d[_0xfd63e4('0xe01')][_0x4e3e81]['id']===_0x5d30e6['id']&&(_0x29428d[_0xfd63e4('0xe01')][_0x4e3e81][_0xfd63e4('0x319')]=![],_0x3c872e[_0xfd63e4('0x1fd0')](_0x29428d['lists'][_0x4e3e81]));}_0x29428d[_0xfd63e4('0xe01')]=_0x3c872e;}else{if(!_0x54f8d0[_0xfd63e4('0x170')])return _0x126c04[_0xfd63e4('0xcf7')]['get']({'sectionId':_0x54f8d0['id']})['$promise'][_0xfd63e4('0x683')](function(_0x1cbe10){const _0x5c552a=_0xfd63e4,_0x611c3c=_0x2e3ca0()['map'](_0x1cbe10[_0x5c552a('0xf5d')],function(_0x3bf963){const _0xbae88d=_0x5c552a;return _0x2e3ca0()[_0xbae88d('0x1c07')](_0x29428d[_0xbae88d('0xe01')],{'id':_0x3bf963['resourceId']});});let _0x1e45b0=null;_0x29428d['chatWebsite']&&(_0x1e45b0=_0x2e3ca0()['find'](_0x29428d[_0x5c552a('0xe01')],{'id':Number(_0x29428d[_0x5c552a('0x2681')][_0x5c552a('0x1e4f')])}));if(_0x1e45b0&&!_0x2e3ca0()[_0x5c552a('0x7a2')](_0x611c3c,['id',_0x1e45b0['id']])){const _0xee2900=_0x2e3ca0()[_0x5c552a('0x1c07')](_0x29428d[_0x5c552a('0xe01')],{'id':_0x1e45b0['id']});_0xee2900[_0x5c552a('0x319')]=![],_0x611c3c['push'](_0xee2900);}_0x29428d[_0x5c552a('0xe01')]=_0x611c3c;});}})[_0x1808a7('0x130a')](function(_0x5a2a3a){const _0x5822be=_0x1808a7;_0x5b816e[_0x5822be('0x52a')]({'title':_0x5a2a3a[_0x5822be('0x13ee')]?_0x5822be('0x2168')+_0x5a2a3a['status']+_0x5822be('0xbf6')+_0x5a2a3a[_0x5822be('0x24a9')]:'SYSTEM:GETlists','msg':_0x5a2a3a['data']?JSON['stringify'](_0x5a2a3a[_0x5822be('0x5a5')]):_0x5a2a3a['toString']()});}),_0x24f77e[_0x1808a7('0xca1')]('admin')?_0x126c04[_0x1808a7('0x115c')][_0x1808a7('0x1e6e')]({'fields':'id,name','sort':'name','IntervalId':_0x1808a7('0x13c')})['$promise']['then'](function(_0x154555){const _0x29c7e5=_0x1808a7;_0x29428d[_0x29c7e5('0x115c')]=_0x154555['rows']||[];})[_0x1808a7('0x130a')](function(_0x7200b9){const _0x29f73a=_0x1808a7;_0x5b816e[_0x29f73a('0x52a')]({'title':_0x7200b9['status']?'API:'+_0x7200b9[_0x29f73a('0x13ee')]+_0x29f73a('0xbf6')+_0x7200b9[_0x29f73a('0x24a9')]:'SYSTEM:GET_INTERVAL','msg':_0x7200b9[_0x29f73a('0x5a5')]?JSON['stringify'](_0x7200b9['data']):_0x7200b9[_0x29f73a('0x1ff0')]()});}):_0x126c04[_0x1808a7('0x115c')]['get']({'fields':_0x1808a7('0xa10'),'sort':_0x1808a7('0x60a'),'IntervalId':_0x1808a7('0x13c')})['$promise'][_0x1808a7('0x683')](function(_0x33044b){const _0x3f71bc=_0x1808a7;_0x29428d['interval']=_0x33044b[_0x3f71bc('0xf5d')]||[];})['then'](function(){const _0x377cbb=_0x1808a7;return _0x126c04[_0x377cbb('0x22df')][_0x377cbb('0x1e6e')]({'userProfileId':_0x29428d[_0x377cbb('0x11ed')][_0x377cbb('0x2f')],'sectionId':0x3ec})[_0x377cbb('0xe53')];})[_0x1808a7('0x683')](function(_0x4a6460){const _0x321ce6=_0x1808a7,_0x37eb82=_0x4a6460&&_0x4a6460[_0x321ce6('0xf5d')]?_0x4a6460['rows'][0x0]:null;if(!_0x37eb82){const _0x3f2480=[];let _0x154931=null;_0x29428d[_0x321ce6('0x2681')]&&(_0x154931=_0x2e3ca0()[_0x321ce6('0x1c07')](_0x29428d['interval'],{'id':Number(_0x29428d[_0x321ce6('0x2681')][_0x321ce6('0x5ae')])}));for(let _0x48d45f=0x0;_0x48d45f<_0x29428d[_0x321ce6('0x115c')][_0x321ce6('0x1564')];_0x48d45f++){_0x154931&&_0x29428d['interval'][_0x48d45f]['id']===_0x154931['id']&&(_0x29428d[_0x321ce6('0x115c')][_0x48d45f][_0x321ce6('0x319')]=![],_0x3f2480['push'](_0x29428d[_0x321ce6('0x115c')][_0x48d45f]));}_0x29428d[_0x321ce6('0x115c')]=_0x3f2480;}else{if(!_0x37eb82['autoAssociation'])return _0x126c04[_0x321ce6('0xcf7')]['get']({'sectionId':_0x37eb82['id']})['$promise'][_0x321ce6('0x683')](function(_0x57dfd9){const _0x1eb2db=_0x321ce6,_0x52c65e=_0x2e3ca0()[_0x1eb2db('0x386')](_0x57dfd9[_0x1eb2db('0xf5d')],function(_0x57cd71){const _0x3b58e6=_0x1eb2db;return _0x2e3ca0()['find'](_0x29428d[_0x3b58e6('0x115c')],{'id':_0x57cd71[_0x3b58e6('0x832')]});});let _0x1b3881=null;_0x29428d[_0x1eb2db('0x2681')]&&(_0x1b3881=_0x2e3ca0()['find'](_0x29428d[_0x1eb2db('0x115c')],{'id':Number(_0x29428d['chatWebsite']['IntervalId'])}));if(_0x1b3881&&!_0x2e3ca0()[_0x1eb2db('0x7a2')](_0x52c65e,['id',_0x1b3881['id']])){const _0x4cb991=_0x2e3ca0()[_0x1eb2db('0x1c07')](_0x29428d['interval'],{'id':_0x1b3881['id']});_0x4cb991[_0x1eb2db('0x319')]=![],_0x52c65e[_0x1eb2db('0x1fd0')](_0x4cb991);}_0x29428d['interval']=_0x52c65e;});}})[_0x1808a7('0x130a')](function(_0x23b92c){const _0x3a9760=_0x1808a7;_0x5b816e[_0x3a9760('0x52a')]({'title':_0x23b92c[_0x3a9760('0x13ee')]?'API:'+_0x23b92c[_0x3a9760('0x13ee')]+'\x20-\x20'+_0x23b92c[_0x3a9760('0x24a9')]:_0x3a9760('0x203'),'msg':_0x23b92c['data']?JSON[_0x3a9760('0x258a')](_0x23b92c[_0x3a9760('0x5a5')]):_0x23b92c[_0x3a9760('0x1ff0')]()});});function _0x58865b(){const _0x5f3e15=_0x1808a7;_0x29428d['errors']=[],_0x126c04[_0x5f3e15('0x2681')][_0x5f3e15('0xb0a')](_0x29428d['chatWebsite'])['$promise'][_0x5f3e15('0x683')](function(_0x5e04a5){const _0x325a24=_0x5f3e15;_0x29428d[_0x325a24('0x25a1')]['unshift'](_0x5e04a5[_0x325a24('0x24e1')]()),_0x5b816e['success']({'title':_0x325a24('0x2540'),'msg':_0x29428d[_0x325a24('0x2681')][_0x325a24('0x60a')]?_0x29428d[_0x325a24('0x2681')][_0x325a24('0x60a')]+_0x325a24('0x14b5'):''}),_0x32c09d(_0x5e04a5);})[_0x5f3e15('0x130a')](function(_0x1404c9){const _0x541cb0=_0x5f3e15;if(_0x1404c9[_0x541cb0('0x5a5')]&&_0x1404c9[_0x541cb0('0x5a5')][_0x541cb0('0x17f')]&&_0x1404c9[_0x541cb0('0x5a5')][_0x541cb0('0x17f')]['length']){_0x29428d[_0x541cb0('0x17f')]=_0x1404c9['data'][_0x541cb0('0x17f')]||[{'message':_0x1404c9[_0x541cb0('0x1ff0')](),'type':_0x541cb0('0x17cc')}];for(let _0x2aefb9=0x0;_0x2aefb9<_0x1404c9[_0x541cb0('0x5a5')][_0x541cb0('0x17f')][_0x541cb0('0x1564')];_0x2aefb9+=0x1){_0x5b816e[_0x541cb0('0x52a')]({'title':_0x1404c9[_0x541cb0('0x5a5')][_0x541cb0('0x17f')][_0x2aefb9][_0x541cb0('0xcf0')],'msg':_0x1404c9['data']['errors'][_0x2aefb9]['message']});}}else _0x5b816e[_0x541cb0('0x52a')]({'title':_0x1404c9['status']?_0x541cb0('0x2168')+_0x1404c9[_0x541cb0('0x13ee')]+_0x541cb0('0xbf6')+_0x1404c9[_0x541cb0('0x24a9')]:_0x541cb0('0x17cc'),'msg':_0x1404c9[_0x541cb0('0x5a5')]?JSON[_0x541cb0('0x258a')](_0x1404c9['data'][_0x541cb0('0x8c2')]):_0x1404c9[_0x541cb0('0x1ff0')]()});});}function _0x22d217(){const _0x406d3f=_0x1808a7;_0x29428d['errors']=[],_0x126c04[_0x406d3f('0x2681')][_0x406d3f('0x2480')]({'id':_0x29428d[_0x406d3f('0x2681')]['id']},_0x29428d['chatWebsite'])[_0x406d3f('0xe53')][_0x406d3f('0x683')](function(_0x22b116){const _0x385678=_0x406d3f,_0x564b4c=_0x2e3ca0()['find'](_0x29428d[_0x385678('0x25a1')],{'id':_0x22b116['id']});_0x564b4c&&_0x2e3ca0()[_0x385678('0xf22')](_0x564b4c,_0x2e3ca0()[_0x385678('0x24d0')](_0x22b116[_0x385678('0x24e1')](),_0x2e3ca0()[_0x385678('0x55e')](_0x564b4c))),_0x5b816e[_0x385678('0x53')]({'title':_0x385678('0x5c1'),'msg':_0x29428d[_0x385678('0x2681')][_0x385678('0x60a')]?_0x29428d['chatWebsite'][_0x385678('0x60a')]+_0x385678('0xf59'):''}),_0x32c09d(_0x22b116);})[_0x406d3f('0x130a')](function(_0x1844e5){const _0x56bb6e=_0x406d3f;if(_0x1844e5['data']&&_0x1844e5[_0x56bb6e('0x5a5')][_0x56bb6e('0x17f')]&&_0x1844e5['data'][_0x56bb6e('0x17f')]['length']){_0x29428d[_0x56bb6e('0x17f')]=_0x1844e5['data'][_0x56bb6e('0x17f')]||[{'message':_0x1844e5[_0x56bb6e('0x1ff0')](),'type':_0x56bb6e('0x2545')}];for(let _0x4101af=0x0;_0x4101af<_0x1844e5[_0x56bb6e('0x5a5')][_0x56bb6e('0x17f')][_0x56bb6e('0x1564')];_0x4101af++){_0x5b816e[_0x56bb6e('0x52a')]({'title':_0x1844e5['data'][_0x56bb6e('0x17f')][_0x4101af][_0x56bb6e('0xcf0')],'msg':_0x1844e5[_0x56bb6e('0x5a5')]['errors'][_0x4101af][_0x56bb6e('0x8c2')]});}}else _0x5b816e[_0x56bb6e('0x52a')]({'title':_0x1844e5[_0x56bb6e('0x13ee')]?_0x56bb6e('0x2168')+_0x1844e5[_0x56bb6e('0x13ee')]+_0x56bb6e('0xbf6')+_0x1844e5[_0x56bb6e('0x24a9')]:_0x56bb6e('0x2545'),'msg':_0x1844e5[_0x56bb6e('0x5a5')]?JSON[_0x56bb6e('0x258a')](_0x1844e5[_0x56bb6e('0x5a5')][_0x56bb6e('0x8c2')]):_0x1844e5[_0x56bb6e('0x1ff0')]()});});}function _0x36ad4c(_0x494f96){const _0x3ec9cd=_0x1808a7;_0x29428d[_0x3ec9cd('0x17f')]=[];const _0x53e5a1=_0xfe2ea9[_0x3ec9cd('0x1c6f')]()[_0x3ec9cd('0xf28')](_0x3ec9cd('0x4d'))[_0x3ec9cd('0xa6a')](_0x3ec9cd('0x326'))['ariaLabel'](_0x3ec9cd('0x34e'))['ok'](_0x3ec9cd('0x2307'))[_0x3ec9cd('0x19fb')](_0x3ec9cd('0x253a'))['targetEvent'](_0x494f96);_0xfe2ea9[_0x3ec9cd('0x1d4')](_0x53e5a1)[_0x3ec9cd('0x683')](function(){const _0x484c59=_0x3ec9cd;_0x126c04['chatWebsite'][_0x484c59('0xd7e')]({'id':_0x29428d[_0x484c59('0x2681')]['id']})[_0x484c59('0xe53')][_0x484c59('0x683')](function(){const _0x45ac1e=_0x484c59;_0x2e3ca0()[_0x45ac1e('0x3ec')](_0x29428d[_0x45ac1e('0x25a1')],{'id':_0x29428d['chatWebsite']['id']}),_0x5b816e['success']({'title':_0x45ac1e('0x1eb0'),'msg':(_0x29428d[_0x45ac1e('0x2681')][_0x45ac1e('0x60a')]||_0x45ac1e('0x2681'))+_0x45ac1e('0x194d')}),_0x32c09d(_0x29428d[_0x45ac1e('0x2681')]);})[_0x484c59('0x130a')](function(_0x464a69){const _0x4caf32=_0x484c59;if(_0x464a69[_0x4caf32('0x5a5')]&&_0x464a69['data']['errors']&&_0x464a69[_0x4caf32('0x5a5')][_0x4caf32('0x17f')][_0x4caf32('0x1564')]){_0x29428d[_0x4caf32('0x17f')]=_0x464a69[_0x4caf32('0x5a5')]['errors']||[{'message':_0x464a69[_0x4caf32('0x1ff0')](),'type':_0x4caf32('0x348')}];for(let _0x409776=0x0;_0x409776<_0x464a69[_0x4caf32('0x5a5')][_0x4caf32('0x17f')]['length'];_0x409776++){_0x5b816e[_0x4caf32('0x52a')]({'title':_0x464a69[_0x4caf32('0x5a5')][_0x4caf32('0x17f')][_0x409776][_0x4caf32('0xcf0')],'msg':_0x464a69[_0x4caf32('0x5a5')][_0x4caf32('0x17f')][_0x409776]['message']});}}else _0x5b816e['error']({'title':_0x464a69[_0x4caf32('0x13ee')]?_0x4caf32('0x2168')+_0x464a69[_0x4caf32('0x13ee')]+'\x20-\x20'+_0x464a69[_0x4caf32('0x24a9')]:_0x4caf32('0x348'),'msg':_0x464a69[_0x4caf32('0x5a5')]?JSON['stringify'](_0x464a69[_0x4caf32('0x5a5')][_0x4caf32('0x8c2')]):_0x464a69[_0x4caf32('0x8c2')]||_0x464a69[_0x4caf32('0x1ff0')]()});});},function(){});}function _0x64ddb2(_0x47c1cc){return _0x47c1cc===null?undefined:new Date(_0x47c1cc);}function _0x32c09d(_0x2eea36){_0xfe2ea9['hide'](_0x2eea36);}}const _0x328fdf=_0x5dcd6a,_0x4fa7fd=_0x180212['p']+_0x189033('0x18b1'),_0x56abaf=_0x180212['p']+_0x189033('0x711'),_0x400a00=_0x180212['p']+_0x189033('0x6de'),_0x408ea1=_0x180212['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/close/dialog.html/dialog.html',_0x4cca8f=_0x180212['p']+_0x189033('0x288d'),_0x1e18e3=_0x180212['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/gotoif/dialog.html/dialog.html',_0x394714=_0x180212['p']+_0x189033('0x8da'),_0x429739=_0x180212['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/interval/dialog.html/dialog.html',_0x32de6e=_0x180212['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/noop/dialog.html/dialog.html',_0x5520ab=_0x180212['p']+_0x189033('0x11d3'),_0x5b03c1=_0x180212['p']+'src/js/modules/main/apps/chat/views/chatWebsites/edit/apps/system/dialog.html/dialog.html',_0x3b41e0=_0x180212['p']+_0x189033('0x10c3');_0x201610['$inject']=[_0x189033('0x56b'),_0x189033('0x1e48'),_0x189033('0x16ea'),'toasty',_0x189033('0xba1')];const _0x5720e3={'agent':_0x4fa7fd,'amazonlex':_0x56abaf,'autoreply':_0x400a00,'close':_0x408ea1,'dialogflow':_0x4cca8f,'gotoif':_0x1e18e3,'gotop':_0x394714,'interval':_0x429739,'noop':_0x32de6e,'queue':_0x5520ab,'system':_0x5b03c1,'tag':_0x3b41e0};function _0x201610(_0x486a15,_0x3ba400,_0x34d9b0,_0x1006d0,_0x13a724){const _0x1c4d68=_0x189033,_0x1177fb=this;_0x1177fb[_0x1c4d68('0x11ed')]=_0x13a724[_0x1c4d68('0x20b2')](),_0x1177fb[_0x1c4d68('0x2681')]={},_0x1177fb['chatWebsiteApps']={'count':0x0,'rows':[]},_0x1177fb[_0x1c4d68('0xa74')]=[],_0x1177fb[_0x1c4d68('0x1134')],_0x1177fb[_0x1c4d68('0x23a2')]={'sort':_0x1c4d68('0xe1e')},_0x1177fb[_0x1c4d68('0x346')]=_0x2e3ca0()[_0x1c4d68('0xfae')](_0x2e3ca0()['sortBy']([{'app':_0x1c4d68('0x22ee'),'appType':'interval','types':[_0x1c4d68('0x10af'),'custom',_0x1c4d68('0x2335')],'fields':[],'isApp':![]},{'app':_0x1c4d68('0x1126'),'appType':'noop','type':'noop','icon':_0x1c4d68('0x7ee'),'interval':_0x1c4d68('0x1b54'),'required':!![],'isApp':!![],'fields':[{'title':_0x1c4d68('0x75d'),'name':_0x1c4d68('0x1c6b'),'type':_0x1c4d68('0x1bcd'),'param':0x0}]},{'app':'system','appType':'system','type':_0x1c4d68('0x24f2'),'icon':'icon-apps','interval':_0x1c4d68('0x1b54'),'required':!![],'isApp':!![],'extraApi':[{'name':_0x1c4d68('0x220b'),'field':{'name':'variable','key':_0x1c4d68('0x60a')},'route':'variable','filters':{'fields':_0x1c4d68('0xa10'),'sort':_0x1c4d68('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':_0x1c4d68('0x256'),'name':'command','type':_0x1c4d68('0x1bcd'),'required':!![],'param':0x0},{'title':_0x1c4d68('0xde7'),'name':'variable','type':'apiselect','values':_0x1c4d68('0x220b'),'value':_0x1c4d68('0x2277'),'option':'variable.name','defaultValues':[{'value':'\x27\x27','option':_0x1c4d68('0x2749')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':_0x1c4d68('0x1da0'),'appType':_0x1c4d68('0x1da0'),'type':_0x1c4d68('0x27fe'),'icon':_0x1c4d68('0x7ee'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x1c4d68('0x19b4'),'name':'priority','type':'number','required':!![],'min':0x0,'param':0x0}]},{'app':'gotoif','appType':_0x1c4d68('0xc33'),'type':_0x1c4d68('0xc33'),'icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':'Condition','name':_0x1c4d68('0x168e'),'type':_0x1c4d68('0x1bcd'),'required':!![],'param':0x0},{'title':_0x1c4d68('0x27e5'),'name':_0x1c4d68('0x27e5'),'type':'number','min':0x1,'required':!![],'param':0x1},{'title':_0x1c4d68('0x1813'),'name':_0x1c4d68('0x1813'),'type':_0x1c4d68('0x121f'),'min':0x1,'required':!![],'param':0x2}]},{'app':'queue','appType':_0x1c4d68('0x660'),'foreignKey':'ChatQueueId','type':_0x1c4d68('0x660'),'icon':_0x1c4d68('0x7ee'),'interval':_0x1c4d68('0x1b54'),'isApp':!![],'extraApi':[{'name':'queues','field':{'name':_0x1c4d68('0x660'),'key':_0x1c4d68('0x60a')},'route':_0x1c4d68('0x1524'),'filters':{'fields':_0x1c4d68('0x2035'),'sort':_0x1c4d68('0x60a'),'nolimit':!![]},'permissions':{'section':0x1f5}}],'fields':[{'title':'Queue','name':_0x1c4d68('0x660'),'type':_0x1c4d68('0x1aae'),'values':_0x1c4d68('0x2da'),'value':'queue.name','option':_0x1c4d68('0x2543'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':'Timeout','name':'timeout','type':_0x1c4d68('0x121f'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x12c,'param':0x1}]},{'app':'agent','appType':'agent','type':_0x1c4d68('0x2327'),'foreignKey':_0x1c4d68('0x10c5'),'icon':'icon-apps','interval':_0x1c4d68('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x1c4d68('0x756'),'field':{'name':_0x1c4d68('0x2327'),'key':'name'},'route':'user','filters':{'fields':_0x1c4d68('0xa10'),'role':_0x1c4d68('0x2327'),'sort':_0x1c4d68('0x60a'),'nolimit':!![]},'permissions':{'section':0xca}}],'fields':[{'title':_0x1c4d68('0x62c'),'name':_0x1c4d68('0x2327'),'type':'apiselect','values':_0x1c4d68('0x756'),'value':'agent.name','option':_0x1c4d68('0x1ed0'),'required':!![],'param':0x0},{'title':_0x1c4d68('0xa09'),'name':_0x1c4d68('0x1668'),'type':_0x1c4d68('0x121f'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':'close','appType':_0x1c4d68('0x12b0'),'type':_0x1c4d68('0x12b0'),'icon':_0x1c4d68('0x7ee'),'interval':_0x1c4d68('0x1b54'),'isApp':!![],'fields':[{'title':_0x1c4d68('0x11d4'),'name':'disposition','type':'text','required':!![],'param':0x0}]},{'app':_0x1c4d68('0x2408'),'appType':_0x1c4d68('0x2408'),'type':_0x1c4d68('0x2408'),'icon':_0x1c4d68('0x7ee'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x1c4d68('0x35'),'name':_0x1c4d68('0x35'),'type':'select','defaultValue':'1','values':[{'option':_0x1c4d68('0x26bb'),'value':'1'},{'option':'Always','value':'0'}],'required':!![],'param':0x0},{'title':_0x1c4d68('0x1d8c'),'name':_0x1c4d68('0x1bcd'),'type':_0x1c4d68('0x24be'),'required':!![],'param':0x1}]},{'app':'tag','appType':_0x1c4d68('0x270'),'type':_0x1c4d68('0x270'),'foreignKey':_0x1c4d68('0xb6d'),'icon':_0x1c4d68('0x7ee'),'interval':_0x1c4d68('0x1b54'),'isApp':!![],'extraApi':[{'name':'tags','field':{'name':_0x1c4d68('0x270'),'key':_0x1c4d68('0x60a')},'route':'tag','filters':{'fields':_0x1c4d68('0xa10'),'sort':_0x1c4d68('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x1c4d68('0x1e'),'name':_0x1c4d68('0x270'),'type':_0x1c4d68('0x1aae'),'values':_0x1c4d68('0x1ce6'),'value':_0x1c4d68('0x1402'),'option':_0x1c4d68('0x1402'),'required':!![],'param':0x0}]},{'app':_0x1c4d68('0x205c'),'appType':_0x1c4d68('0x205c'),'type':_0x1c4d68('0x205c'),'icon':'icon-apps','interval':_0x1c4d68('0x1b54'),'isApp':!![],'fields':[{'title':_0x1c4d68('0x429'),'name':_0x1c4d68('0x1d46'),'type':'text','required':!![],'param':0x0},{'title':_0x1c4d68('0x1a1c'),'name':_0x1c4d68('0x1a1c'),'type':_0x1c4d68('0xb31'),'defaultValue':_0x1c4d68('0x1adc'),'values':[{'option':_0x1c4d68('0x17d9'),'value':_0x1c4d68('0x1e18')},{'option':_0x1c4d68('0xf48'),'value':_0x1c4d68('0x1adc')},{'option':'German','value':_0x1c4d68('0x1e33')},{'option':_0x1c4d68('0x2217'),'value':'\x27it\x27'},{'option':'Spanish','value':_0x1c4d68('0xd34')},{'option':_0x1c4d68('0x51a'),'value':_0x1c4d68('0x1869')},{'option':_0x1c4d68('0x9ec'),'value':_0x1c4d68('0x663')},{'option':_0x1c4d68('0x1abb'),'value':_0x1c4d68('0x1505')},{'option':_0x1c4d68('0x4b5'),'value':_0x1c4d68('0x9d3')},{'option':'Dutch','value':'\x27nl\x27'},{'option':_0x1c4d68('0x1e53'),'value':'\x27no\x27'},{'option':_0x1c4d68('0x15d9'),'value':_0x1c4d68('0x432')},{'option':_0x1c4d68('0x521'),'value':_0x1c4d68('0xc58')},{'option':_0x1c4d68('0x103e'),'value':'\x27ru\x27'},{'option':_0x1c4d68('0x1ff5'),'value':'\x27sv\x27'},{'option':_0x1c4d68('0xbc'),'value':'\x27th\x27'},{'option':_0x1c4d68('0x965'),'value':_0x1c4d68('0x2e0')},{'option':_0x1c4d68('0x277f'),'value':'\x27zh-CN\x27'},{'option':_0x1c4d68('0xc60'),'value':_0x1c4d68('0x1802')},{'option':_0x1c4d68('0x700'),'value':'\x27zh-TW\x27'}],'required':!![],'param':0x1},{'title':'welcomemessage','name':'welcomemessage','type':'textarea','maxlength':0xff,'param':0x2,'help':!![]}]},{'app':'dialogflowV2','appType':_0x1c4d68('0xd24'),'type':_0x1c4d68('0xd24'),'icon':_0x1c4d68('0x7ee'),'interval':_0x1c4d68('0x1b54'),'isApp':!![],'fields':[{'title':_0x1c4d68('0x1e7d'),'name':_0x1c4d68('0x2119'),'type':_0x1c4d68('0x1bcd'),'required':!![],'param':0x0},{'title':'ClientEmail','name':_0x1c4d68('0x38'),'type':'text','required':!![],'param':0x1},{'title':'PrivateKey','name':_0x1c4d68('0x406'),'type':_0x1c4d68('0x24be'),'required':!![],'param':0x2},{'title':_0x1c4d68('0x1a1c'),'name':_0x1c4d68('0x1a1c'),'type':_0x1c4d68('0xb31'),'defaultValue':'\x27en\x27','values':[{'value':_0x1c4d68('0x1802'),'option':_0x1c4d68('0x1de6')},{'value':_0x1c4d68('0x2562'),'option':_0x1c4d68('0x277f')},{'value':'\x27zh-TW\x27','option':_0x1c4d68('0x700')},{'value':_0x1c4d68('0x1e18'),'option':_0x1c4d68('0x17d9')},{'value':'\x27nl\x27','option':_0x1c4d68('0xe03')},{'value':_0x1c4d68('0x1adc'),'option':_0x1c4d68('0xf48')},{'value':'\x27en-AU\x27','option':_0x1c4d68('0xbc1')},{'value':_0x1c4d68('0x196e'),'option':_0x1c4d68('0x6fa')},{'value':_0x1c4d68('0x23bd'),'option':_0x1c4d68('0x1e8')},{'value':_0x1c4d68('0x2303'),'option':_0x1c4d68('0xa57')},{'value':_0x1c4d68('0x95d'),'option':'English\x20(US)'},{'value':'\x27fr\x27','option':'French'},{'value':_0x1c4d68('0x8df'),'option':_0x1c4d68('0x842')},{'value':_0x1c4d68('0x2371'),'option':_0x1c4d68('0xcad')},{'value':_0x1c4d68('0x1e33'),'option':_0x1c4d68('0x118e')},{'value':_0x1c4d68('0x1b11'),'option':_0x1c4d68('0x81c')},{'value':_0x1c4d68('0x663'),'option':_0x1c4d68('0x9ec')},{'value':_0x1c4d68('0x1955'),'option':'Italian'},{'value':_0x1c4d68('0x1505'),'option':_0x1c4d68('0x1abb')},{'value':_0x1c4d68('0x9d3'),'option':_0x1c4d68('0x233a')},{'value':'\x27no\x27','option':_0x1c4d68('0x1e53')},{'value':_0x1c4d68('0x24cb'),'option':_0x1c4d68('0x10a7')},{'value':'\x27pt-BR\x27','option':'Portuguese\x20(Brazil)'},{'value':_0x1c4d68('0x64c'),'option':_0x1c4d68('0x1876')},{'value':'\x27ru\x27','option':_0x1c4d68('0x103e')},{'value':_0x1c4d68('0xd34'),'option':_0x1c4d68('0xbe9')},{'value':'\x27es-419\x27','option':_0x1c4d68('0x1e41')},{'value':_0x1c4d68('0x979'),'option':_0x1c4d68('0x208e')},{'value':_0x1c4d68('0x2175'),'option':_0x1c4d68('0x1ff5')},{'value':_0x1c4d68('0x15a8'),'option':_0x1c4d68('0xbc')},{'value':_0x1c4d68('0x267f'),'option':'Turkish'},{'value':_0x1c4d68('0x2e0'),'option':_0x1c4d68('0x965')}],'required':!![],'param':0x3},{'title':_0x1c4d68('0x6d9'),'name':_0x1c4d68('0x6d9'),'type':_0x1c4d68('0x24be'),'maxlength':0xff,'param':0x4,'help':!![]}]},{'app':_0x1c4d68('0x1db1'),'appType':'amazonlex','type':_0x1c4d68('0x1db1'),'icon':_0x1c4d68('0x7ee'),'interval':_0x1c4d68('0x1b54'),'isApp':!![],'fields':[{'title':'accesskeyid','name':_0x1c4d68('0x7ae'),'type':_0x1c4d68('0x1bcd'),'required':!![],'param':0x0},{'title':_0x1c4d68('0x204a'),'name':_0x1c4d68('0x204a'),'type':'text','required':!![],'param':0x1},{'title':_0x1c4d68('0x5ba'),'name':_0x1c4d68('0x5ba'),'type':'select','defaultValue':_0x1c4d68('0x1924'),'values':[{'option':_0x1c4d68('0x260e'),'value':_0x1c4d68('0x1924')},{'option':_0x1c4d68('0xc2b'),'value':_0x1c4d68('0x1488')},{'option':'EU\x20(Ireland)','value':_0x1c4d68('0x17db')},{'option':_0x1c4d68('0x15b6'),'value':'\x27ap-southeast-2\x27'}],'required':!![],'param':0x2},{'title':_0x1c4d68('0x11a9'),'name':_0x1c4d68('0x11a9'),'type':_0x1c4d68('0x1bcd'),'required':!![],'param':0x3},{'title':'welcomemessage','name':_0x1c4d68('0x6d9'),'type':'textarea','maxlength':0xff,'param':0x4,'help':!![]}]}],['app']),{'isApp':![]}),_0x1177fb[_0x1c4d68('0x2335')]={'group':{'name':'opt1','pull':_0x1c4d68('0x147f')},'animation':0x64,'sort':![]},_0x1177fb[_0x1c4d68('0x2146')]={'group':{'name':_0x1c4d68('0x489'),'put':_0x1c4d68('0x11bf')},'animation':0x64,'onAdd':function(_0x12008b){const _0x12f86a=_0x1c4d68;_0x14db10(_0x12008b,_0x12008b[_0x12f86a('0x1ce1')]);},'onSort':function(){_0xc1d5d4();}},_0x1177fb['init']=_0x2ef6b2,_0x1177fb[_0x1c4d68('0x26eb')]=_0x3f9111,_0x1177fb[_0x1c4d68('0x1d44')]=_0x50bb36,_0x1177fb[_0x1c4d68('0x111e')]=_0x14db10,_0x1177fb[_0x1c4d68('0x24f7')]=_0x987284,_0x1177fb[_0x1c4d68('0x18b8')]=_0x2df8c8,_0x1177fb[_0x1c4d68('0x23f8')]=_0x19238c,_0x1177fb[_0x1c4d68('0x13f5')]=_0xc1d5d4,_0x1177fb['getIntervals']=_0x3a686b;function _0x2ef6b2(_0x3137db,_0x240ec8){const _0x29db1d=_0x1c4d68;_0x1177fb[_0x29db1d('0x2681')]=_0x3137db,_0x1177fb[_0x29db1d('0x1134')]=typeof _0x240ec8!==_0x29db1d('0x1867')?_0x240ec8:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1177fb[_0x29db1d('0x2146')][_0x29db1d('0x120b')]=!_0x1177fb[_0x29db1d('0x1134')][_0x29db1d('0x1978')]?!![]:![],_0x1177fb[_0x29db1d('0x23a2')]['id']=_0x3137db['id'],_0x1177fb[_0x29db1d('0x23a2')]['isApp']=!![],_0x1177fb[_0x29db1d('0x23a2')][_0x29db1d('0x2088')]=!![],_0x1177fb[_0x29db1d('0x1d44')](),_0x1177fb['getIntervals']();}function _0x3f9111(_0x374147,_0x1353b8,_0x351f26){const _0xc4e59e=_0x1c4d68,_0x28222b=_0x3ba400[_0xc4e59e('0x1c6f')]()[_0xc4e59e('0xf28')](_0xc4e59e('0x421'))[_0xc4e59e('0x26e3')](_0xc4e59e('0xed5')+_0x374147['app']+_0xc4e59e('0x20f1')+_0xc4e59e('0x1ee7'))[_0xc4e59e('0x1040')]('delete\x20application')[_0xc4e59e('0xe42')](_0x351f26)['ok']('OK')['cancel'](_0xc4e59e('0x16b8'));_0x3ba400[_0xc4e59e('0x1d4')](_0x28222b)['then'](function(){const _0x4d0a3d=_0xc4e59e;_0x1177fb[_0x4d0a3d('0x2144')][_0x4d0a3d('0xf5d')][_0x4d0a3d('0x2040')](_0x1353b8,0x1),_0xc1d5d4();},function(){const _0x3c3a7f=_0xc4e59e;console[_0x3c3a7f('0x1b2b')]('CANCEL');});}function _0x14db10(_0x287900,_0x2ef44b){const _0x270266=_0x1c4d68;if(_0x1177fb['chatWebsiteApps'][_0x270266('0xf5d')][_0x270266('0x1564')]){const _0x320c99=_0x1177fb['chatWebsiteApps']['rows'][_0x2ef44b]?_0x1177fb[_0x270266('0x2144')][_0x270266('0xf5d')][_0x2ef44b]:_0x1177fb[_0x270266('0x2144')][_0x270266('0xf5d')][0x0],_0x4aa9fd=(_0x320c99[_0x270266('0x11f3')]||_0x320c99[_0x270266('0x1d75')])['toLowerCase']();_0x3ba400[_0x270266('0x1d4')]({'controller':'EditChatWebsiteApp'+_0x4aa9fd+'DialogController','controllerAs':'vm','templateUrl':_0x5720e3[_0x4aa9fd],'parent':angular['element'](_0x34d9b0[_0x270266('0x18e5')]),'targetEvent':_0x287900,'clickOutsideToClose':!![],'locals':{'chatWebsiteApp':_0x320c99,'chatWebsite':_0x1177fb[_0x270266('0x2681')],'crudPermissions':_0x1177fb[_0x270266('0x1134')]}})['then'](function(_0x3b4dfb){const _0x5a7151=_0x270266;_0x3b4dfb&&(_0x3b4dfb['id']?_0x1177fb['chatWebsiteApps']['rows'][_0x2ef44b]=_0x3b4dfb:_0x1177fb[_0x5a7151('0x2144')]['rows'][_0x5a7151('0x2040')](_0x2ef44b,0x0,_0x3b4dfb),_0xc1d5d4());})[_0x270266('0x130a')](function(_0x2f6c2b){const _0x5223c4=_0x270266;_0x2f6c2b&&_0x1006d0[_0x5223c4('0x52a')]({'title':_0x2f6c2b['status']?_0x5223c4('0x2168')+_0x2f6c2b[_0x5223c4('0x13ee')]+_0x5223c4('0xbf6')+_0x2f6c2b['statusText']:_0x5223c4('0xf1b'),'msg':_0x2f6c2b[_0x5223c4('0x5a5')]?JSON[_0x5223c4('0x258a')](_0x2f6c2b['data']):_0x2f6c2b['toString']()});});}}function _0x987284(_0x3614e4,_0x278611){const _0x1ec709=_0x1c4d68;if(_0x1177fb[_0x1ec709('0x2144')][_0x1ec709('0xf5d')]['length']){const _0x39227e=_0x1177fb[_0x1ec709('0x2144')][_0x1ec709('0xf5d')][_0x278611]?_0x1177fb['chatWebsiteApps'][_0x1ec709('0xf5d')][_0x278611]:_0x1177fb['chatWebsiteApps']['rows'][0x0];_0x3ba400['show']({'controller':_0x1ec709('0x820'),'controllerAs':'vm','templateUrl':_0x429739,'parent':angular[_0x1ec709('0x1fcc')](_0x34d9b0[_0x1ec709('0x18e5')]),'targetEvent':_0x3614e4,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x39227e[_0x1ec709('0x115c')],'IntervalId':_0x39227e[_0x1ec709('0x5ae')],'application':!![]},'intervals':[],'crudPermissions':_0x1177fb[_0x1ec709('0x1134')]}})[_0x1ec709('0x683')](function(_0x4e2f2f){const _0x18efd8=_0x1ec709;_0x4e2f2f&&(_0x39227e['interval']=_0x4e2f2f[_0x18efd8('0x115c')]||_0x18efd8('0x1b54'),_0x39227e['IntervalId']=_0x4e2f2f['IntervalId']||null,_0xc1d5d4());});}}function _0xc1d5d4(){const _0x3758e6=_0x1c4d68;let _0x37d4ef=0x1,_0x1b06fe=[];for(let _0x2a4575=0x0;_0x2a4575<_0x1177fb[_0x3758e6('0x2144')][_0x3758e6('0xf5d')][_0x3758e6('0x1564')];_0x2a4575++){const _0x12d1cc=_0x1177fb[_0x3758e6('0x2144')][_0x3758e6('0xf5d')][_0x2a4575],_0x3abe8b=[],_0x1a6ab9=[];_0x12d1cc[_0x3758e6('0xe98')]=_0x12d1cc[_0x3758e6('0x115c')]!==_0x3758e6('0x1b54')?[_0x12d1cc[_0x3758e6('0x115c')]]:_0x12d1cc[_0x3758e6('0x5ae')]?_0x2e3ca0()[_0x3758e6('0x386')](_0x2e3ca0()['filter'](_0x1177fb[_0x3758e6('0xe98')][_0x3758e6('0xf5d')],{'IntervalId':_0x12d1cc[_0x3758e6('0x5ae')]}),_0x3758e6('0x115c')):[],_0x12d1cc['context']=_0x1177fb['chatWebsite'][_0x3758e6('0x22d3')],_0x12d1cc['exten']=_0x1177fb['chatWebsite'][_0x3758e6('0x1a5b')],_0x12d1cc[_0x3758e6('0xcf0')]&&(_0x12d1cc['type']=_0x12d1cc[_0x3758e6('0xcf0')]['toLowerCase']()),_0x12d1cc[_0x3758e6('0xe1e')]=_0x3abe8b['length']?_0x2e3ca0()[_0x3758e6('0xc0f')](_0x3abe8b)[_0x3758e6('0xe1e')]+0x1:_0x37d4ef,_0x37d4ef=(_0x1a6ab9[_0x3758e6('0x1564')]?_0x2e3ca0()[_0x3758e6('0xc0f')](_0x1a6ab9)[_0x3758e6('0xe1e')]:_0x12d1cc[_0x3758e6('0xe1e')])+0x1,_0x1b06fe=_0x2e3ca0()[_0x3758e6('0x746')](_0x1b06fe,_0x3abe8b,[_0x12d1cc],_0x1a6ab9);}_0x486a15[_0x3758e6('0x2681')][_0x3758e6('0x10ef')]({'id':_0x1177fb[_0x3758e6('0x2681')]['id']},_0x2e3ca0()[_0x3758e6('0x742')](_0x1b06fe,_0x3758e6('0xe1e')))[_0x3758e6('0xe53')][_0x3758e6('0x683')](function(_0x2f1245){const _0x4123ae=_0x3758e6;_0x1177fb[_0x4123ae('0x2144')]['rows']=_0x2f1245[_0x4123ae('0xf5d')];})[_0x3758e6('0x130a')](function(_0x14b2c7){const _0x2133cd=_0x3758e6;console[_0x2133cd('0x52a')](_0x14b2c7);});}function _0x3d57a9(_0x373b5a){const _0x2f131d=_0x1c4d68;_0x1177fb[_0x2f131d('0x2144')]=_0x373b5a||{'count':0x0,'rows':[]};}function _0x3a686b(){const _0x4008fd=_0x1c4d68;return _0x486a15[_0x4008fd('0x115c')][_0x4008fd('0x1e6e')]({'fields':'id,interval,IntervalId'})[_0x4008fd('0xe53')]['then'](function(_0x5cb929){const _0x4a20e3=_0x4008fd;_0x1177fb[_0x4a20e3('0xe98')]=_0x5cb929;})['catch'](function(_0x524a84){const _0x1bb4bc=_0x4008fd;console[_0x1bb4bc('0x52a')](_0x524a84);});}function _0x50bb36(){const _0x3ade3a=_0x1c4d68;_0x1177fb[_0x3ade3a('0x1883')]=_0x486a15[_0x3ade3a('0x2681')][_0x3ade3a('0x13be')](_0x1177fb[_0x3ade3a('0x23a2')],_0x3d57a9)['$promise'];}function _0x2df8c8(_0x20a370){const _0x112e27=_0x1c4d68;_0x2e3ca0()[_0x112e27('0x3ec')](_0x1177fb[_0x112e27('0x2144')]['rows'],{'id':_0x20a370['id']}),_0xc1d5d4(),_0x1006d0[_0x112e27('0x53')]({'title':'App\x20deleted!','msg':_0x20a370[_0x112e27('0x1d75')]?_0x20a370[_0x112e27('0x1d75')]+_0x112e27('0x194d'):''});}function _0x19238c(_0x266fb0){const _0x5c4b4a=_0x1c4d68,_0x1a265f=_0x3ba400[_0x5c4b4a('0x1c6f')]()[_0x5c4b4a('0xf28')](_0x5c4b4a('0x188'))[_0x5c4b4a('0x26e3')](''+_0x1177fb['selectedChatWebsiteApps'][_0x5c4b4a('0x1564')]+_0x5c4b4a('0x93c')+'\x20will\x20be\x20deleted.')[_0x5c4b4a('0x1040')](_0x5c4b4a('0x1b94'))[_0x5c4b4a('0xe42')](_0x266fb0)['ok']('OK')[_0x5c4b4a('0x19fb')]('CANCEL');_0x3ba400[_0x5c4b4a('0x1d4')](_0x1a265f)[_0x5c4b4a('0x683')](function(){const _0x479618=_0x5c4b4a;_0x1177fb[_0x479618('0xa74')][_0x479618('0x1299')](function(_0x259f78){const _0x25b5b5=_0x479618;_0x2e3ca0()[_0x25b5b5('0x3ec')](_0x1177fb[_0x25b5b5('0x2144')][_0x25b5b5('0xf5d')],{'id':_0x259f78['id']});}),_0x1177fb[_0x479618('0xa74')]=[],_0xc1d5d4();});}}const _0x3f5f3c=_0x201610;_0x47b201[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x2681'),_0x189033('0x25a1'),_0x189033('0x2c9'),'$translate',_0x189033('0xba1'),_0x189033('0x1134')];function _0x47b201(_0xe76780,_0xa8d6d2,_0x369798,_0x1c6048,_0x269b23,_0x112134,_0x593653,_0x3cb2a9,_0x57aec8,_0x86a30b){const _0x27f739=_0x189033,_0x22548d=this;_0x22548d[_0x27f739('0x11ed')]=_0x57aec8['getCurrentUser'](),_0x22548d[_0x27f739('0x2681')]=_0x269b23,_0x22548d[_0x27f739('0x1134')]=_0x86a30b,_0x22548d['realtime']=_0x593653,_0x22548d[_0x27f739('0x1996')]=[],_0x22548d[_0x27f739('0x1c47')]=[],_0x22548d[_0x27f739('0x1378')]=[],_0x22548d[_0x27f739('0x125e')]=[],_0x22548d[_0x27f739('0x23a7')]=[],_0x22548d[_0x27f739('0x2106')]=![],_0x22548d[_0x27f739('0x1dd2')]=_0x2fc375,_0x22548d['saveAgents']=_0xb87d73,_0x22548d[_0x27f739('0xf82')]=_0x3fa479,_0x22548d[_0x27f739('0x169f')]={'readOnly':!_0x22548d[_0x27f739('0x1134')][_0x27f739('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x27f739('0x60a'),'line1':_0x27f739('0x11bc'),'line2':[_0x27f739('0x60a'),'internal'],'line3':'','labelAll':_0x3cb2a9[_0x27f739('0x2728')](_0x27f739('0xb0f')),'labelSelected':_0x3cb2a9['instant'](_0x27f739('0x199c')),'transferCallback':function(){const _0x42ecf7=_0x27f739,_0x8a5596=_0x2e3ca0()[_0x42ecf7('0x25cb')](_0x22548d[_0x42ecf7('0x23a7')],_0x22548d['selectedItems'],'id');_0x22548d[_0x42ecf7('0x2106')]=_0x2e3ca0()[_0x42ecf7('0x173f')](_0x8a5596)?![]:!![];}};function _0x2fc375(){const _0x5afd0b=_0x27f739;return _0x57aec8['hasRole'](_0x5afd0b('0x20c2'))?_0x30e565()[_0x5afd0b('0x130a')](function(_0x4eedb2){const _0x1024b2=_0x5afd0b;_0x369798[_0x1024b2('0x52a')]({'title':_0x4eedb2[_0x1024b2('0x13ee')]?_0x1024b2('0x2168')+_0x4eedb2[_0x1024b2('0x13ee')]+_0x1024b2('0xbf6')+_0x4eedb2[_0x1024b2('0x24a9')]:_0x1024b2('0x144f'),'msg':_0x4eedb2['status']?JSON['stringify'](_0x4eedb2[_0x1024b2('0x5a5')]):_0x4eedb2['toString']()});}):_0x138cc0()[_0x5afd0b('0x683')](function(_0x4c884d){return _0x22548d['section']=_0x4c884d,_0x30e565();})[_0x5afd0b('0x130a')](function(_0x489477){const _0x5839be=_0x5afd0b;_0x369798['error']({'title':_0x489477[_0x5839be('0x13ee')]?_0x5839be('0x2168')+_0x489477[_0x5839be('0x13ee')]+_0x5839be('0xbf6')+_0x489477['statusText']:_0x5839be('0x144f'),'msg':_0x489477[_0x5839be('0x13ee')]?JSON[_0x5839be('0x258a')](_0x489477['data']):_0x489477['toString']()});});}function _0x138cc0(){return _0xa8d6d2(function(_0x1b8239,_0x45228f){const _0x970473=a0_0x4e0a;_0x1c6048[_0x970473('0x22df')]['get']({'userProfileId':_0x22548d['currentUser'][_0x970473('0x2f')],'name':_0x970473('0x1bc0')})['$promise'][_0x970473('0x683')](function(_0x2c2709){const _0x1aca5f=_0x970473,_0x1d959d=_0x2c2709&&_0x2c2709[_0x1aca5f('0xf5d')]?_0x2c2709[_0x1aca5f('0xf5d')][0x0]:null;_0x1b8239(_0x1d959d);})[_0x970473('0x130a')](function(_0xe15541){_0x45228f(_0xe15541);});});}function _0x30e565(){return _0xa8d6d2(function(_0x3b1ffa,_0x1c5a6b){const _0x2f99d7=a0_0x4e0a;return _0x2f7e4d()[_0x2f99d7('0x683')](function(_0x30c20a){const _0x223c8f=_0x2f99d7;return _0x22548d[_0x223c8f('0x1996')]=_0x30c20a[_0x223c8f('0xf5d')]?_0x30c20a['rows']:[],_0x57aec8['hasRole'](_0x223c8f('0x20c2'))?_0x30c20a:_0x22548d[_0x223c8f('0x1aa')]?_0x22548d['section'][_0x223c8f('0x170')]?_0x30c20a:_0x506a91():null;})[_0x2f99d7('0x683')](function(_0x4b5bfd){const _0x5105ab=_0x2f99d7,_0x2ce9ef=_0x4b5bfd&&_0x4b5bfd[_0x5105ab('0xf5d')]?_0x4b5bfd['rows']:[];return _0x22548d[_0x5105ab('0x1c47')]=_0x2e3ca0()['map'](_0x2ce9ef,function(_0x23f177){const _0x169ea5=_0x5105ab;return _0x2e3ca0()[_0x169ea5('0x1c07')](_0x22548d[_0x169ea5('0x1996')],{'id':_0x57aec8[_0x169ea5('0xca1')](_0x169ea5('0x20c2'))||_0x22548d['section']['autoAssociation']?_0x23f177['id']:_0x23f177[_0x169ea5('0x832')]});}),_0x22548d[_0x5105ab('0x125e')]=angular['copy'](_0x22548d[_0x5105ab('0x1c47')]),_0x22548d[_0x5105ab('0x1996')][_0x5105ab('0x1299')](function(_0x2b4ae1){const _0x401a5c=_0x5105ab,_0x39a9b8=_0x2e3ca0()[_0x401a5c('0x1c07')](_0x22548d[_0x401a5c('0x1c47')],{'id':_0x2b4ae1['id']});_0x57aec8[_0x401a5c('0xca1')](_0x401a5c('0x20c2'))?_0x2b4ae1['isValid']=!![]:_0x2b4ae1[_0x401a5c('0x24f4')]=typeof _0x39a9b8!=='undefined'?!![]:![];}),_0xbaccd7();})['then'](function(_0x153960){const _0x3a6283=_0x2f99d7,_0x5cf65e=_0x153960&&_0x153960[_0x3a6283('0xf5d')]?_0x153960[_0x3a6283('0xf5d')]:[];_0x22548d[_0x3a6283('0x1378')]=_0x2e3ca0()[_0x3a6283('0x386')](_0x5cf65e,function(_0x50a4a1){const _0x1be1f1=_0x3a6283,_0x49ef1a=_0x2e3ca0()[_0x1be1f1('0x1c07')](_0x22548d[_0x1be1f1('0x1996')],{'id':_0x50a4a1['id']});return _0x49ef1a[_0x1be1f1('0x1e2a')]=_0x50a4a1['UserChatWebsite']?_0x1be1f1('0x23d0')+_0x50a4a1[_0x1be1f1('0x19db')][_0x1be1f1('0x1e2a')]:'',_0x49ef1a[_0x1be1f1('0x1d43')]=typeof _0x50a4a1[_0x1be1f1('0x1d43')]!==_0x1be1f1('0x1867')?'<'+_0x50a4a1[_0x1be1f1('0x1d43')]+'>':'',_0x49ef1a;}),_0x22548d[_0x3a6283('0x23a7')]=angular[_0x3a6283('0x1a86')](_0x22548d[_0x3a6283('0x1378')]),_0x22548d[_0x3a6283('0x169f')]['selectedItems']=_0x22548d[_0x3a6283('0x1378')],_0x22548d['dualMultiselectOptions'][_0x3a6283('0x1996')]=_0x2e3ca0()[_0x3a6283('0x461')](_0x22548d['allowedItems'],_0x22548d['dualMultiselectOptions'][_0x3a6283('0x1378')],'id'),_0x3b1ffa();})['catch'](function(_0x240e5c){_0x1c5a6b(_0x240e5c);});});}function _0x506a91(){return _0xa8d6d2(function(_0x458245,_0x589991){const _0x4c3198=a0_0x4e0a;return _0x1c6048[_0x4c3198('0xcf7')][_0x4c3198('0x1e6e')]({'sectionId':_0x22548d[_0x4c3198('0x1aa')]['id'],'nolimit':!![]})[_0x4c3198('0xe53')][_0x4c3198('0x683')](function(_0x134642){_0x458245(_0x134642);})[_0x4c3198('0x130a')](function(_0x2ccefd){_0x589991(_0x2ccefd);});});}function _0xbaccd7(){return _0xa8d6d2(function(_0x4cad99,_0x119e7){const _0xedceb3=a0_0x4e0a;return _0x1c6048[_0xedceb3('0x2681')]['getAgents']({'id':_0x22548d[_0xedceb3('0x2681')]['id'],'fields':_0xedceb3('0x72b'),'nolimit':!![],'role':_0xedceb3('0x2327')})['$promise'][_0xedceb3('0x683')](function(_0x46c5f4){_0x4cad99(_0x46c5f4);})[_0xedceb3('0x130a')](function(_0x3834c7){_0x119e7(_0x3834c7);});});}function _0x2f7e4d(){return _0xa8d6d2(function(_0x5b194f,_0x1e7817){const _0x2f8378=a0_0x4e0a;return _0x1c6048[_0x2f8378('0xc96')]['get']({'fields':_0x2f8378('0x72b'),'nolimit':!![],'role':_0x2f8378('0x2327')})[_0x2f8378('0xe53')][_0x2f8378('0x683')](function(_0x3b78cc){_0x5b194f(_0x3b78cc);})[_0x2f8378('0x130a')](function(_0x421bbd){_0x1e7817(_0x421bbd);});});}function _0x58e38d(_0xc35e39){return _0xa8d6d2(function(_0x2726f0,_0x37838c){const _0x527786=a0_0x4e0a;_0x2e3ca0()[_0x527786('0x173f')](_0xc35e39)?_0x2726f0():_0x1c6048[_0x527786('0x2681')][_0x527786('0x2179')]({'id':_0x22548d[_0x527786('0x2681')]['id'],'ids':_0x2e3ca0()['map'](_0xc35e39,'id')})[_0x527786('0xe53')][_0x527786('0x683')](function(){_0x2726f0();})[_0x527786('0x130a')](function(_0x103b6b){_0x37838c(_0x103b6b);});});}function _0x3081f1(_0xdbb791){return _0xa8d6d2(function(_0x5a60e1,_0x44d6ef){const _0x5444e7=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0xdbb791)?_0x5a60e1():_0x1c6048[_0x5444e7('0x2681')][_0x5444e7('0xf9')]({'id':_0x22548d[_0x5444e7('0x2681')]['id'],'ids':_0x2e3ca0()[_0x5444e7('0x386')](_0xdbb791,'id')})['$promise'][_0x5444e7('0x683')](function(){_0x5a60e1();})[_0x5444e7('0x130a')](function(_0x19520a){_0x44d6ef(_0x19520a);});});}function _0xb87d73(){const _0x5151be=_0x27f739,_0x2a91d9=_0x2e3ca0()[_0x5151be('0x461')](_0x22548d[_0x5151be('0x23a7')],_0x22548d[_0x5151be('0x1378')],'id'),_0x171605=_0x2e3ca0()[_0x5151be('0x461')](_0x22548d['selectedItems'],_0x22548d[_0x5151be('0x23a7')],'id');return _0x3081f1(_0x2a91d9)[_0x5151be('0x683')](function(){return _0x58e38d(_0x171605);})[_0x5151be('0x683')](function(){const _0x12c2c5=_0x5151be;_0x22548d[_0x12c2c5('0x2106')]=![],_0x22548d[_0x12c2c5('0x125e')]=angular[_0x12c2c5('0x1a86')](_0x22548d['allowedItems']),_0x22548d[_0x12c2c5('0x23a7')]=angular[_0x12c2c5('0x1a86')](_0x22548d[_0x12c2c5('0x1378')]),_0x369798['success']({'title':'SUCCESS','msg':_0x12c2c5('0x89d')});})[_0x5151be('0x130a')](function(_0x54d7f4){const _0x216cea=_0x5151be;_0x369798[_0x216cea('0x52a')]({'title':_0x54d7f4[_0x216cea('0x13ee')]?_0x216cea('0x2168')+_0x54d7f4[_0x216cea('0x13ee')]+_0x216cea('0xbf6')+_0x54d7f4[_0x216cea('0x24a9')]:_0x216cea('0x1b71'),'msg':_0x54d7f4[_0x216cea('0x13ee')]?JSON[_0x216cea('0x258a')](_0x54d7f4['data']):_0x54d7f4[_0x216cea('0x1ff0')]()});});}function _0x3fa479(){_0xe76780['hide']();}}const _0xbee715=_0x47b201;_0x318fb4['$inject']=[_0x189033('0x17e4'),_0x189033('0x1d70')];function _0x318fb4(_0x5b3e4b,_0x20754a){const _0x36e08a=_0x189033,_0x51150e=this,_0x5a7d85=0x8,_0x64400c=_0x5a7d85*0x400*0x400;_0x51150e[_0x36e08a('0x2681')]={},_0x51150e[_0x36e08a('0x1134')],_0x51150e['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x64400c,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x51150e[_0x36e08a('0x1fa6')]={'flow':{}},_0x51150e[_0x36e08a('0xfbe')]=![],_0x51150e['fileAdded']=_0x75794e,_0x51150e[_0x36e08a('0xa03')]=_0x377917,_0x51150e[_0x36e08a('0x1152')]=_0x3cb64a,_0x51150e[_0x36e08a('0x12f3')]=_0x444738;function _0x444738(_0x332761,_0x37d077){const _0x126a5d=_0x36e08a;_0x51150e[_0x126a5d('0x2681')]=angular[_0x126a5d('0x1a86')](_0x332761),_0x51150e[_0x126a5d('0x1134')]=typeof _0x37d077!==_0x126a5d('0x1867')?_0x37d077:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x51150e[_0x126a5d('0x8f')][_0x126a5d('0x568')]=_0x126a5d('0x253c')['replace'](':id',_0x51150e[_0x126a5d('0x2681')]['id']),_0x51150e['chatWebsite'][_0x126a5d('0x2668')]=[];}function _0x75794e(_0x222fc8){const _0xfa685f=_0x36e08a,_0x1ca77a=[_0xfa685f('0x21ec'),'jpg'];if(!_0x2e3ca0()[_0xfa685f('0x2292')](_0x1ca77a,_0x222fc8[_0xfa685f('0x1197')]()))return _0x20754a['error']({'title':_0xfa685f('0xa00')+_0x222fc8[_0xfa685f('0x1197')](),'msg':_0xfa685f('0x2560')+_0x1ca77a['join']()}),![];if(_0x222fc8[_0xfa685f('0x1a41')]>_0x64400c)return _0x20754a[_0xfa685f('0x52a')]({'title':_0xfa685f('0x19a2'),'msg':_0xfa685f('0x1622')+_0x5a7d85+'MB'}),![];const _0x4dde62={'id':_0x222fc8['uniqueIdentifier'],'file':_0x222fc8,'type':'uploading'};return _0x51150e[_0xfa685f('0x2681')][_0xfa685f('0x2668')][_0xfa685f('0x1167')](_0x4dde62),!![];}function _0x377917(){const _0x14b6b9=_0x36e08a;_0x51150e[_0x14b6b9('0x1fa6')][_0x14b6b9('0x190a')][_0x14b6b9('0x2810')]['headers']={'X-Requested-With':_0x14b6b9('0xbfd'),'Authorization':_0x14b6b9('0x189e')+_0x5b3e4b['get']('motion.token')},_0x51150e[_0x14b6b9('0x1fa6')][_0x14b6b9('0x190a')]['upload']();}function _0x3cb64a(_0x3a6519){const _0x526588=_0x36e08a;angular[_0x526588('0x1299')](_0x51150e[_0x526588('0x2681')]['images'],function(_0x29a6b4){const _0x413924=_0x526588;if(_0x29a6b4['id']===_0x3a6519[_0x413924('0x2379')]){const _0x1c0887=new FileReader();_0x1c0887['readAsDataURL'](_0x29a6b4['file']['file']),_0x1c0887[_0x413924('0x43b')]=function(_0x5b2299){const _0x30e05a=_0x413924;_0x29a6b4[_0x30e05a('0x1284')]=_0x5b2299[_0x30e05a('0x568')][_0x30e05a('0x7c9')];},_0x29a6b4['type']='image';}});}}const _0x281f5a=_0x318fb4;_0x56334a[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'chatWebsiteApp',_0x189033('0x2681'),'api',_0x189033('0xba1'),'crudPermissions'];function _0x56334a(_0x165d07,_0xa3d52d,_0x51b7cc,_0x523f5c,_0x4be7a6,_0x48bac3,_0x3dc234,_0x4e5c7f){const _0x5e9af5=_0x189033,_0x185f34=this;_0x185f34[_0x5e9af5('0x11ed')]=_0x3dc234['getCurrentUser'](),_0x185f34['errors']=[],_0x185f34['title']='CHAT.EDIT_'+(_0x523f5c[_0x5e9af5('0x11f3')]||_0x523f5c[_0x5e9af5('0x1d75')])[_0x5e9af5('0x80')](),_0x185f34[_0x5e9af5('0x2327')]=angular['copy'](_0x523f5c),_0x185f34[_0x5e9af5('0x1134')]=_0x4e5c7f,_0x185f34['hasModulePermissions']={};if(_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1407')])switch(_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x11f3')]?_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x11f3')]['toLowerCase']():_0x185f34['agent'][_0x5e9af5('0x1d75')][_0x5e9af5('0x93a')]()){case _0x5e9af5('0xbf0'):break;case _0x5e9af5('0x205c'):{const _0x2af311=_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1407')]['split'](',');_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1d46')]=_0x2af311[0x0],_0x185f34['agent']['language']=_0x2af311[0x1],_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x6d9')]=_0x2af311['slice'](0x2,_0x2af311[_0x5e9af5('0x1564')])[_0x5e9af5('0x1630')](',');}break;case _0x5e9af5('0xd24'):{const _0x4b163d=_0x185f34['agent'][_0x5e9af5('0x1407')][_0x5e9af5('0x1fc5')](',');_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x2119')]=_0x4b163d[0x0],_0x185f34['agent'][_0x5e9af5('0x38')]=_0x4b163d[0x1],_0x185f34[_0x5e9af5('0x2327')]['privateKey']=_0x4b163d[0x2],_0x185f34['agent'][_0x5e9af5('0x1a1c')]=_0x4b163d[0x3],_0x185f34['agent'][_0x5e9af5('0x6d9')]=_0x4b163d[_0x5e9af5('0x12c8')](0x4,_0x4b163d['length'])[_0x5e9af5('0x1630')](',');}break;case _0x5e9af5('0x1db1'):{const _0x44b9fb=_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1407')][_0x5e9af5('0x1fc5')](',');_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x7ae')]=_0x44b9fb[0x0],_0x185f34[_0x5e9af5('0x2327')]['secretaccesskey']=_0x44b9fb[0x1],_0x185f34[_0x5e9af5('0x2327')]['lexregion']=_0x44b9fb[0x2],_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x11a9')]=_0x44b9fb[0x3],_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x6d9')]=_0x44b9fb[_0x5e9af5('0x12c8')](0x4,_0x44b9fb[_0x5e9af5('0x1564')])[_0x5e9af5('0x1630')](',');}break;case'autoreply':{const _0x2ca306=_0x185f34['agent'][_0x5e9af5('0x1407')][_0x5e9af5('0x1fc5')](',');_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x35')]=isNaN(_0x2ca306[0x0])?_0x2ca306[0x0]:parseInt(_0x2ca306[0x0],0xa),_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1bcd')]=_0x2ca306[_0x5e9af5('0x12c8')](0x1,_0x2ca306['length'])[_0x5e9af5('0x1630')](',');}break;case _0x5e9af5('0x8c2'):_0x185f34['agent'][_0x5e9af5('0x1bcd')]=_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1407')];break;case _0x5e9af5('0x877'):_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x60a')]=_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1407')][_0x5e9af5('0x1fc5')]('=')[0x0],_0x185f34[_0x5e9af5('0x2327')]['value']=_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1407')][_0x5e9af5('0x1fc5')]('=')[0x1];break;case'agi':_0x185f34['agent'][_0x5e9af5('0x273a')]=_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1407')];break;default:{const _0x5d5ead=_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1407')][_0x5e9af5('0x1fc5')](',');_0x185f34[_0x5e9af5('0x2327')]['agent']=_0x2e3ca0()[_0x5e9af5('0x173f')](_0x5d5ead[0x0])?_0x5d5ead[0x0]:isNaN(_0x5d5ead[0x0])?_0x5d5ead[0x0]:parseInt(_0x5d5ead[0x0],0xa),_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x1668')]=_0x2e3ca0()[_0x5e9af5('0x173f')](_0x5d5ead[0x1])?_0x5d5ead[0x1]:isNaN(_0x5d5ead[0x1])?_0x5d5ead[0x1]:parseInt(_0x5d5ead[0x1],0xa);}break;}else _0x185f34[_0x5e9af5('0x2327')]['timeout']=0x1e;_0x185f34['agent'][_0x5e9af5('0xcf0')]&&_0x185f34['agent'][_0x5e9af5('0xcf0')][_0x5e9af5('0x93a')]()===_0x5e9af5('0x17cd')&&_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x11f3')][_0x5e9af5('0x93a')]()==='outbounddial'&&(_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0x24fa')]=_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0xd31')]?_0x185f34[_0x5e9af5('0x2327')]['phone'][_0x5e9af5('0x1fc5')]('$')[0x0]:undefined,_0x185f34[_0x5e9af5('0x2327')][_0x5e9af5('0xabd')]=_0x185f34['agent'][_0x5e9af5('0x73c')]?_0x5e9af5('0xac1')+_0x185f34['agent'][_0x5e9af5('0x73c')]:undefined);_0x185f34['saveChatWebsiteApp']=_0xe28458,_0x185f34[_0x5e9af5('0xf82')]=_0x387920,_0x3dc234[_0x5e9af5('0xca1')](_0x5e9af5('0x20c2'))?_0x48bac3[_0x5e9af5('0xc96')]['get']({'fields':_0x5e9af5('0xa10'),'role':'agent','sort':_0x5e9af5('0x60a'),'nolimit':_0x5e9af5('0x26ac')})[_0x5e9af5('0xe53')]['then'](function(_0x50fb15){const _0x2d2b5c=_0x5e9af5;_0x185f34[_0x2d2b5c('0x756')]=_0x50fb15[_0x2d2b5c('0xf5d')]||[];})['catch'](function(_0x1f9b98){const _0x339ad=_0x5e9af5;_0x51b7cc[_0x339ad('0x52a')]({'title':_0x1f9b98[_0x339ad('0x13ee')]?_0x339ad('0x2168')+_0x1f9b98[_0x339ad('0x13ee')]+_0x339ad('0xbf6')+_0x1f9b98[_0x339ad('0x24a9')]:_0x339ad('0x144f'),'msg':_0x1f9b98[_0x339ad('0x5a5')]?JSON[_0x339ad('0x258a')](_0x1f9b98[_0x339ad('0x5a5')]):_0x1f9b98[_0x339ad('0x1ff0')]()});}):_0x48bac3[_0x5e9af5('0xc96')]['get']({'fields':_0x5e9af5('0xa10'),'role':'agent','sort':'name','nolimit':_0x5e9af5('0x26ac')})[_0x5e9af5('0xe53')][_0x5e9af5('0x683')](function(_0x49a65f){const _0x2fcdd2=_0x5e9af5;_0x185f34[_0x2fcdd2('0x756')]=_0x49a65f[_0x2fcdd2('0xf5d')]||[];})[_0x5e9af5('0x683')](function(){const _0x214ad3=_0x5e9af5;return _0x48bac3[_0x214ad3('0x22df')]['get']({'userProfileId':_0x185f34['currentUser'][_0x214ad3('0x2f')],'sectionId':0xca})['$promise'];})[_0x5e9af5('0x683')](function(_0x56669d){const _0x113342=_0x5e9af5,_0x42b7ea=_0x56669d&&_0x56669d[_0x113342('0xf5d')]?_0x56669d['rows'][0x0]:null;if(!_0x42b7ea){const _0x1903b1=[];let _0x4f1786=null;_0x185f34[_0x113342('0x2327')]&&(_0x4f1786=_0x2e3ca0()[_0x113342('0x1c07')](_0x185f34[_0x113342('0x756')],{'name':_0x185f34[_0x113342('0x2327')][_0x113342('0x2327')]}));for(let _0x29c06f=0x0;_0x29c06f<_0x185f34[_0x113342('0x756')][_0x113342('0x1564')];_0x29c06f++){_0x4f1786&&_0x185f34[_0x113342('0x756')][_0x29c06f]['id']===_0x4f1786['id']&&(_0x185f34[_0x113342('0x756')][_0x29c06f][_0x113342('0x319')]=![],_0x1903b1[_0x113342('0x1fd0')](_0x185f34[_0x113342('0x756')][_0x29c06f]));}_0x185f34[_0x113342('0x756')]=_0x1903b1;}else{if(!_0x42b7ea[_0x113342('0x170')])return _0x48bac3[_0x113342('0xcf7')][_0x113342('0x1e6e')]({'sectionId':_0x42b7ea['id']})['$promise'][_0x113342('0x683')](function(_0x3d298e){const _0x2819db=_0x113342,_0x1b0f6c=_0x2e3ca0()[_0x2819db('0x386')](_0x3d298e[_0x2819db('0xf5d')],function(_0x3b5c77){const _0x5c1c35=_0x2819db;return _0x2e3ca0()[_0x5c1c35('0x1c07')](_0x185f34['agents'],{'id':_0x3b5c77['resourceId']});});let _0x3c525f=null;_0x185f34[_0x2819db('0x2327')]&&(_0x3c525f=_0x2e3ca0()[_0x2819db('0x1c07')](_0x185f34[_0x2819db('0x756')],{'name':_0x185f34[_0x2819db('0x2327')][_0x2819db('0x2327')]}));if(_0x3c525f&&!_0x2e3ca0()[_0x2819db('0x7a2')](_0x1b0f6c,['id',_0x3c525f['id']])){const _0x2135bd=_0x2e3ca0()[_0x2819db('0x1c07')](_0x185f34['agents'],{'id':_0x3c525f['id']});_0x2135bd[_0x2819db('0x319')]=![],_0x1b0f6c['push'](_0x2135bd);}_0x185f34['agents']=_0x1b0f6c;});}})[_0x5e9af5('0x130a')](function(_0x5266a2){const _0x5ccef8=_0x5e9af5;_0x51b7cc[_0x5ccef8('0x52a')]({'title':_0x5266a2['status']?_0x5ccef8('0x2168')+_0x5266a2[_0x5ccef8('0x13ee')]+_0x5ccef8('0xbf6')+_0x5266a2[_0x5ccef8('0x24a9')]:_0x5ccef8('0x391'),'msg':_0x5266a2[_0x5ccef8('0x5a5')]?JSON[_0x5ccef8('0x258a')](_0x5266a2[_0x5ccef8('0x5a5')]):_0x5266a2['toString']()});});function _0xe28458(){const _0x186288=_0x5e9af5;_0x185f34[_0x186288('0x17f')]=[];const _0x3e0a3a=[];_0x185f34['agent']['type']&&_0x185f34[_0x186288('0x2327')][_0x186288('0xcf0')][_0x186288('0x93a')]()===_0x186288('0x17cd')&&_0x185f34[_0x186288('0x2327')]['appType']===_0x186288('0x4d2')&&(_0x185f34[_0x186288('0x2327')][_0x186288('0xd31')]=_0x4be7a6[_0x186288('0x145a')]?(_0x185f34['agent']['prefix']||'')+_0x186288('0x249e')+_0x4be7a6[_0x186288('0x145a')]+'}':(_0x185f34['agent']['prefix']||'')+_0x186288('0x20cb'),_0x4be7a6[_0x186288('0x75b')]!=='none'?_0x185f34['agent']['options'][_0x186288('0x824')](_0x186288('0x1b1'))<0x0&&(_0x185f34[_0x186288('0x2327')]['options']+=_0x186288('0x1b1')):_0x185f34[_0x186288('0x2327')]['options']=_0x185f34['agent'][_0x186288('0x158e')]['replace'](_0x186288('0x1b1'),''));const _0x2937b1=_0x2e3ca0()['find'](_0x185f34[_0x186288('0x756')],{'name':_0x185f34[_0x186288('0x2327')][_0x186288('0x2327')]});_0x2937b1&&(_0x185f34[_0x186288('0x2327')][_0x186288('0x10c5')]=_0x2937b1['id']);if(_0x185f34[_0x186288('0x2327')][_0x186288('0x11f3')]&&_0x185f34['agent']['appType']===_0x186288('0xbf0')){}else switch((_0x185f34[_0x186288('0x2327')]['app']||_0x185f34[_0x186288('0x2327')][_0x186288('0x11f3')])['toLowerCase']()){case _0x186288('0x877'):_0x185f34[_0x186288('0x2327')][_0x186288('0x1407')]=_0x185f34[_0x186288('0x2327')][_0x186288('0x60a')]+'='+_0x185f34[_0x186288('0x2327')]['value'];break;case _0x186288('0xbf0'):break;default:_0x3e0a3a[0x0]=_0x185f34[_0x186288('0x2327')][_0x186288('0x2327')],_0x3e0a3a[0x1]=_0x185f34['agent'][_0x186288('0x1668')],_0x185f34[_0x186288('0x2327')][_0x186288('0x1407')]=_0x3e0a3a['join'](',');}_0x387920(_0x185f34[_0x186288('0x2327')]);}function _0x387920(_0x37b4fd){_0x165d07['hide'](_0x37b4fd);}}const _0xef177a=_0x56334a;_0x195322[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'chatWebsiteApp',_0x189033('0x2681'),_0x189033('0x56b'),'Auth','crudPermissions'];function _0x195322(_0x1e33b0,_0xeaf086,_0x5bf4cb,_0x4edff3,_0x486b46,_0x111d9d,_0x57097b,_0x3ece02){const _0x4d21a5=_0x189033,_0x56233d=this;_0x56233d[_0x4d21a5('0x11ed')]=_0x57097b[_0x4d21a5('0x20b2')](),_0x56233d['errors']=[],_0x56233d['title']=_0x4d21a5('0x1c66')+(_0x4edff3[_0x4d21a5('0x11f3')]||_0x4edff3[_0x4d21a5('0x1d75')])['toUpperCase'](),_0x56233d[_0x4d21a5('0x1db1')]=angular[_0x4d21a5('0x1a86')](_0x4edff3),_0x56233d['crudPermissions']=_0x3ece02,_0x56233d['hasModulePermissions']={};if(_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1407')])switch(_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x11f3')]?_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x11f3')][_0x4d21a5('0x93a')]():_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1d75')][_0x4d21a5('0x93a')]()){case _0x4d21a5('0xbf0'):break;case'dialogflow':{const _0x380546=_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1407')][_0x4d21a5('0x1fc5')](',');_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1d46')]=_0x380546[0x0],_0x56233d['amazonlex'][_0x4d21a5('0x1a1c')]=_0x380546[0x1],_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x6d9')]=_0x380546[_0x4d21a5('0x12c8')](0x2,_0x380546[_0x4d21a5('0x1564')])['join'](',');}break;case'dialogflowv2':{const _0x436d56=_0x56233d[_0x4d21a5('0x1db1')]['appdata']['split'](',');_0x56233d[_0x4d21a5('0x1db1')]['projectId']=_0x436d56[0x0],_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x38')]=_0x436d56[0x1],_0x56233d['amazonlex'][_0x4d21a5('0x406')]=_0x436d56[0x2],_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1a1c')]=_0x436d56[0x3],_0x56233d[_0x4d21a5('0x1db1')]['welcomemessage']=_0x436d56['slice'](0x4,_0x436d56[_0x4d21a5('0x1564')])[_0x4d21a5('0x1630')](',');}break;case'amazonlex':{const _0xeac2ac=_0x56233d['amazonlex'][_0x4d21a5('0x1407')]['split'](',');_0x56233d['amazonlex'][_0x4d21a5('0x7ae')]=_0xeac2ac[0x0],_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x204a')]=_0xeac2ac[0x1],_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x5ba')]=_0xeac2ac[0x2],_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x11a9')]=_0xeac2ac[0x3],_0x56233d['amazonlex']['welcomemessage']=_0xeac2ac[_0x4d21a5('0x12c8')](0x4,_0xeac2ac['length'])[_0x4d21a5('0x1630')](',');}break;case _0x4d21a5('0x2408'):{const _0x2f9695=_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1407')][_0x4d21a5('0x1fc5')](',');_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x35')]=isNaN(_0x2f9695[0x0])?_0x2f9695[0x0]:parseInt(_0x2f9695[0x0],0xa),_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1bcd')]=_0x2f9695[_0x4d21a5('0x12c8')](0x1,_0x2f9695[_0x4d21a5('0x1564')])[_0x4d21a5('0x1630')](',');}break;case _0x4d21a5('0x8c2'):_0x56233d['amazonlex'][_0x4d21a5('0x1bcd')]=_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1407')];break;case'set':_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x60a')]=_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1407')][_0x4d21a5('0x1fc5')]('=')[0x0],_0x56233d[_0x4d21a5('0x1db1')]['value']=_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1407')][_0x4d21a5('0x1fc5')]('=')[0x1];break;case'agi':_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x273a')]=_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1407')];break;default:{const _0x107db3=_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x1407')]['split'](',');_0x56233d[_0x4d21a5('0x1db1')]['accesskeyid']=_0x2e3ca0()['isEmpty'](_0x107db3[0x0])?_0x107db3[0x0]:isNaN(_0x107db3[0x0])?_0x107db3[0x0]:parseInt(_0x107db3[0x0],0xa),_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x204a')]=_0x2e3ca0()[_0x4d21a5('0x173f')](_0x107db3[0x1])?_0x107db3[0x1]:isNaN(_0x107db3[0x1])?_0x107db3[0x1]:parseInt(_0x107db3[0x1],0xa),_0x56233d['amazonlex'][_0x4d21a5('0x5ba')]=_0x2e3ca0()[_0x4d21a5('0x173f')](_0x107db3[0x2])?_0x107db3[0x2]:isNaN(_0x107db3[0x2])?_0x107db3[0x2]:parseInt(_0x107db3[0x2],0xa),_0x56233d[_0x4d21a5('0x1db1')]['botname']=_0x2e3ca0()['isEmpty'](_0x107db3[0x3])?_0x107db3[0x3]:isNaN(_0x107db3[0x3])?_0x107db3[0x3]:parseInt(_0x107db3[0x3],0xa),_0x56233d[_0x4d21a5('0x1db1')]['welcomemessage']=_0x2e3ca0()[_0x4d21a5('0x173f')](_0x107db3[0x4])?_0x107db3[0x4]:isNaN(_0x107db3[0x4])?_0x107db3[0x4]:parseInt(_0x107db3[0x4],0xa);}break;}else _0x56233d['amazonlex'][_0x4d21a5('0x5ba')]='us-east-1';_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0xcf0')]&&_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0xcf0')][_0x4d21a5('0x93a')]()==='outbound'&&_0x56233d['amazonlex'][_0x4d21a5('0x11f3')][_0x4d21a5('0x93a')]()===_0x4d21a5('0x659')&&(_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x24fa')]=_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0xd31')]?_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0xd31')][_0x4d21a5('0x1fc5')]('$')[0x0]:undefined,_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0xabd')]=_0x56233d['amazonlex'][_0x4d21a5('0x73c')]?'CALLERID(all)='+_0x56233d[_0x4d21a5('0x1db1')][_0x4d21a5('0x73c')]:undefined);_0x56233d[_0x4d21a5('0x25eb')]=_0x55a0b1,_0x56233d[_0x4d21a5('0xf82')]=_0x9018;function _0x55a0b1(){const _0x18bbc2=_0x4d21a5;_0x56233d['errors']=[];const _0x2dd56d=[];_0x56233d['amazonlex'][_0x18bbc2('0xcf0')]&&_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0xcf0')]['toLowerCase']()==='outbound'&&_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x11f3')]===_0x18bbc2('0x4d2')&&(_0x56233d['amazonlex'][_0x18bbc2('0xd31')]=_0x486b46[_0x18bbc2('0x145a')]?(_0x56233d[_0x18bbc2('0x1db1')]['prefix']||'')+_0x18bbc2('0x249e')+_0x486b46[_0x18bbc2('0x145a')]+'}':(_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x24fa')]||'')+_0x18bbc2('0x20cb'),_0x486b46[_0x18bbc2('0x75b')]!==_0x18bbc2('0x925')?_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x158e')][_0x18bbc2('0x824')](_0x18bbc2('0x1b1'))<0x0&&(_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x158e')]+=_0x18bbc2('0x1b1')):_0x56233d['amazonlex'][_0x18bbc2('0x158e')]=_0x56233d[_0x18bbc2('0x1db1')]['options'][_0x18bbc2('0x1725')](_0x18bbc2('0x1b1'),''));if(_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x11f3')]&&_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x11f3')]==='custom'){}else switch((_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x1d75')]||_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x11f3')])[_0x18bbc2('0x93a')]()){case _0x18bbc2('0x877'):_0x56233d['amazonlex'][_0x18bbc2('0x1407')]=_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x60a')]+'='+_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x1c6b')];break;case _0x18bbc2('0xbf0'):break;default:_0x2dd56d[0x0]=_0x56233d[_0x18bbc2('0x1db1')]['accesskeyid'],_0x2dd56d[0x1]=_0x56233d['amazonlex'][_0x18bbc2('0x204a')],_0x2dd56d[0x2]=_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x5ba')],_0x2dd56d[0x3]=_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x11a9')],_0x2dd56d[0x4]=_0x56233d[_0x18bbc2('0x1db1')][_0x18bbc2('0x6d9')],_0x56233d[_0x18bbc2('0x1db1')]['appdata']=_0x2dd56d['join'](',');}_0x9018(_0x56233d[_0x18bbc2('0x1db1')]);}function _0x9018(_0x22f86a){const _0x5a1524=_0x4d21a5;_0x1e33b0[_0x5a1524('0x1715')](_0x22f86a);}}const _0xf8092=_0x195322;_0x27edb5[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x277b'),_0x189033('0x2681'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x27edb5(_0x273250,_0x213739,_0x2b582f,_0x23cb8e,_0x54bce8,_0x4f96ce,_0x9a7588,_0x4f05e0){const _0xd5602b=_0x189033,_0x108f50=this;_0x108f50['currentUser']=_0x9a7588[_0xd5602b('0x20b2')](),_0x108f50[_0xd5602b('0x17f')]=[],_0x108f50[_0xd5602b('0xf28')]=_0xd5602b('0x1c66')+(_0x23cb8e[_0xd5602b('0x11f3')]||_0x23cb8e[_0xd5602b('0x1d75')])[_0xd5602b('0x80')](),_0x108f50[_0xd5602b('0x2408')]=angular[_0xd5602b('0x1a86')](_0x23cb8e),_0x108f50['crudPermissions']=_0x4f05e0,_0x108f50[_0xd5602b('0x258d')]={};if(_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1407')])switch(_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x11f3')]?_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x11f3')][_0xd5602b('0x93a')]():_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1d75')]['toLowerCase']()){case'custom':break;case _0xd5602b('0x205c'):{const _0x4f0264=_0x108f50['autoreply'][_0xd5602b('0x1407')][_0xd5602b('0x1fc5')](',');_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1d46')]=_0x4f0264[0x0],_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1a1c')]=_0x4f0264[0x1],_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x6d9')]=_0x4f0264[_0xd5602b('0x12c8')](0x2,_0x4f0264[_0xd5602b('0x1564')])[_0xd5602b('0x1630')](',');}break;case'dialogflowv2':{const _0x4077ef=_0x108f50['autoreply'][_0xd5602b('0x1407')][_0xd5602b('0x1fc5')](',');_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x2119')]=_0x4077ef[0x0],_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x38')]=_0x4077ef[0x1],_0x108f50['autoreply']['privateKey']=_0x4077ef[0x2],_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1a1c')]=_0x4077ef[0x3],_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x6d9')]=_0x4077ef['slice'](0x4,_0x4077ef[_0xd5602b('0x1564')])['join'](',');}break;case _0xd5602b('0x1db1'):{const _0x34763e=_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1407')]['split'](',');_0x108f50[_0xd5602b('0x2408')]['accesskeyid']=_0x34763e[0x0],_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x204a')]=_0x34763e[0x1],_0x108f50['autoreply'][_0xd5602b('0x5ba')]=_0x34763e[0x2],_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x11a9')]=_0x34763e[0x3],_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x6d9')]=_0x34763e[_0xd5602b('0x12c8')](0x4,_0x34763e['length'])[_0xd5602b('0x1630')](',');}break;case _0xd5602b('0x2408'):{const _0x486691=_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1407')][_0xd5602b('0x1fc5')](',');_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x35')]=isNaN(_0x486691[0x0])?_0x486691[0x0]:parseInt(_0x486691[0x0],0xa),_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1bcd')]=_0x486691['slice'](0x1,_0x486691[_0xd5602b('0x1564')])[_0xd5602b('0x1630')](',');}break;case'message':_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1bcd')]=_0x108f50['autoreply'][_0xd5602b('0x1407')];break;case _0xd5602b('0x877'):_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x60a')]=_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1407')][_0xd5602b('0x1fc5')]('=')[0x0],_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1c6b')]=_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1407')]['split']('=')[0x1];break;case'agi':_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x273a')]=_0x108f50[_0xd5602b('0x2408')]['appdata'];break;default:{const _0x5a1353=_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x1407')][_0xd5602b('0x1fc5')](',');_0x108f50['autoreply'][_0xd5602b('0x35')]=_0x2e3ca0()[_0xd5602b('0x173f')](_0x5a1353[0x0])?_0x5a1353[0x0]:isNaN(_0x5a1353[0x0])?_0x5a1353[0x0]:parseInt(_0x5a1353[0x0],0xa),_0x108f50['autoreply'][_0xd5602b('0x1bcd')]=_0x2e3ca0()[_0xd5602b('0x173f')](_0x5a1353[0x1])?_0x5a1353[0x1]:isNaN(_0x5a1353[0x1])?_0x5a1353[0x1]:parseInt(_0x5a1353[0x1],0xa);}break;}else _0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x35')]=0x1;_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0xcf0')]&&_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0xcf0')][_0xd5602b('0x93a')]()===_0xd5602b('0x17cd')&&_0x108f50[_0xd5602b('0x2408')]['appType'][_0xd5602b('0x93a')]()==='outbounddial'&&(_0x108f50['autoreply']['prefix']=_0x108f50['autoreply']['phone']?_0x108f50[_0xd5602b('0x2408')]['phone'][_0xd5602b('0x1fc5')]('$')[0x0]:undefined,_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0xabd')]=_0x108f50[_0xd5602b('0x2408')][_0xd5602b('0x73c')]?'CALLERID(all)='+_0x108f50['autoreply'][_0xd5602b('0x73c')]:undefined);_0x108f50['saveChatWebsiteApp']=_0x5039d1,_0x108f50[_0xd5602b('0xf82')]=_0x3045f0;function _0x5039d1(){const _0x460527=_0xd5602b;_0x108f50[_0x460527('0x17f')]=[];const _0x55428d=[];_0x108f50[_0x460527('0x2408')][_0x460527('0xcf0')]&&_0x108f50[_0x460527('0x2408')]['type']['toLowerCase']()===_0x460527('0x17cd')&&_0x108f50[_0x460527('0x2408')][_0x460527('0x11f3')]==='outboundDial'&&(_0x108f50[_0x460527('0x2408')][_0x460527('0xd31')]=_0x54bce8[_0x460527('0x145a')]?(_0x108f50[_0x460527('0x2408')][_0x460527('0x24fa')]||'')+_0x460527('0x249e')+_0x54bce8[_0x460527('0x145a')]+'}':(_0x108f50[_0x460527('0x2408')][_0x460527('0x24fa')]||'')+'${EXTEN}',_0x54bce8[_0x460527('0x75b')]!=='none'?_0x108f50[_0x460527('0x2408')][_0x460527('0x158e')][_0x460527('0x824')](_0x460527('0x1b1'))<0x0&&(_0x108f50[_0x460527('0x2408')][_0x460527('0x158e')]+='U(xcally-mixmonitor-context)'):_0x108f50[_0x460527('0x2408')][_0x460527('0x158e')]=_0x108f50[_0x460527('0x2408')]['options'][_0x460527('0x1725')](_0x460527('0x1b1'),''));if(_0x108f50[_0x460527('0x2408')][_0x460527('0x11f3')]&&_0x108f50['autoreply'][_0x460527('0x11f3')]===_0x460527('0xbf0')){}else switch((_0x108f50[_0x460527('0x2408')][_0x460527('0x1d75')]||_0x108f50[_0x460527('0x2408')][_0x460527('0x11f3')])[_0x460527('0x93a')]()){case _0x460527('0x877'):_0x108f50[_0x460527('0x2408')][_0x460527('0x1407')]=_0x108f50[_0x460527('0x2408')][_0x460527('0x60a')]+'='+_0x108f50[_0x460527('0x2408')][_0x460527('0x1c6b')];break;case _0x460527('0xbf0'):break;default:_0x55428d[0x0]=_0x108f50[_0x460527('0x2408')][_0x460527('0x35')],_0x55428d[0x1]=_0x108f50[_0x460527('0x2408')]['text'],_0x108f50[_0x460527('0x2408')][_0x460527('0x1407')]=_0x55428d['join'](',');}_0x3045f0(_0x108f50['autoreply']);}function _0x3045f0(_0x4259f8){const _0x5bcd6b=_0xd5602b;_0x273250[_0x5bcd6b('0x1715')](_0x4259f8);}}const _0x403279=_0x27edb5;_0x46ee74['$inject']=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x277b'),_0x189033('0x2681'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x46ee74(_0x47cab4,_0x27f52f,_0x4ca6e6,_0x11602e,_0x48686a,_0x47ee84,_0x46d52c,_0x28c59d){const _0x27ab66=_0x189033,_0x4ec53f=this;_0x4ec53f['currentUser']=_0x46d52c[_0x27ab66('0x20b2')](),_0x4ec53f[_0x27ab66('0x17f')]=[],_0x4ec53f['title']=_0x27ab66('0x1c66')+(_0x11602e[_0x27ab66('0x11f3')]||_0x11602e['app'])[_0x27ab66('0x80')](),_0x4ec53f['close']=angular[_0x27ab66('0x1a86')](_0x11602e),_0x4ec53f['crudPermissions']=_0x28c59d,_0x4ec53f[_0x27ab66('0x258d')]={};if(_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x1407')])switch(_0x4ec53f['close'][_0x27ab66('0x11f3')]?_0x4ec53f['close'][_0x27ab66('0x11f3')][_0x27ab66('0x93a')]():_0x4ec53f[_0x27ab66('0x12b0')]['app'][_0x27ab66('0x93a')]()){case'custom':break;case _0x27ab66('0x205c'):{const _0x149473=_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x1407')][_0x27ab66('0x1fc5')](',');_0x4ec53f[_0x27ab66('0x12b0')]['key']=_0x149473[0x0],_0x4ec53f['close'][_0x27ab66('0x1a1c')]=_0x149473[0x1],_0x4ec53f[_0x27ab66('0x12b0')]['welcomemessage']=_0x149473[_0x27ab66('0x12c8')](0x2,_0x149473[_0x27ab66('0x1564')])[_0x27ab66('0x1630')](',');}break;case _0x27ab66('0xd24'):{const _0xe16297=_0x4ec53f[_0x27ab66('0x12b0')]['appdata'][_0x27ab66('0x1fc5')](',');_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x2119')]=_0xe16297[0x0],_0x4ec53f[_0x27ab66('0x12b0')]['clientEmail']=_0xe16297[0x1],_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x406')]=_0xe16297[0x2],_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x1a1c')]=_0xe16297[0x3],_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x6d9')]=_0xe16297[_0x27ab66('0x12c8')](0x4,_0xe16297[_0x27ab66('0x1564')])[_0x27ab66('0x1630')](',');}break;case'amazonlex':{const _0x8f4aac=_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x1407')][_0x27ab66('0x1fc5')](',');_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x7ae')]=_0x8f4aac[0x0],_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x204a')]=_0x8f4aac[0x1],_0x4ec53f['close'][_0x27ab66('0x5ba')]=_0x8f4aac[0x2],_0x4ec53f[_0x27ab66('0x12b0')]['botname']=_0x8f4aac[0x3],_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x6d9')]=_0x8f4aac['slice'](0x4,_0x8f4aac[_0x27ab66('0x1564')])[_0x27ab66('0x1630')](',');}break;case _0x27ab66('0x2408'):{const _0x3c0359=_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x1407')][_0x27ab66('0x1fc5')](',');_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x35')]=isNaN(_0x3c0359[0x0])?_0x3c0359[0x0]:parseInt(_0x3c0359[0x0],0xa),_0x4ec53f['close']['text']=_0x3c0359['slice'](0x1,_0x3c0359['length'])[_0x27ab66('0x1630')](',');}break;case _0x27ab66('0x8c2'):_0x4ec53f['close'][_0x27ab66('0x1bcd')]=_0x4ec53f[_0x27ab66('0x12b0')]['appdata'];break;case _0x27ab66('0x877'):_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x60a')]=_0x4ec53f['close']['appdata'][_0x27ab66('0x1fc5')]('=')[0x0],_0x4ec53f['close']['value']=_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x1407')][_0x27ab66('0x1fc5')]('=')[0x1];break;case _0x27ab66('0x19ae'):_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x273a')]=_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x1407')];break;default:{const _0x2ee160=_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x1407')][_0x27ab66('0x1fc5')](',');_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x43f')]=_0x2e3ca0()[_0x27ab66('0x173f')](_0x2ee160[0x0])?_0x2ee160[0x0]:isNaN(_0x2ee160[0x0])?_0x2ee160[0x0]:parseInt(_0x2ee160[0x0],0xa);}break;}else{}_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0xcf0')]&&_0x4ec53f['close'][_0x27ab66('0xcf0')][_0x27ab66('0x93a')]()===_0x27ab66('0x17cd')&&_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x11f3')][_0x27ab66('0x93a')]()==='outbounddial'&&(_0x4ec53f['close'][_0x27ab66('0x24fa')]=_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0xd31')]?_0x4ec53f['close'][_0x27ab66('0xd31')][_0x27ab66('0x1fc5')]('$')[0x0]:undefined,_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0xabd')]=_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x73c')]?_0x27ab66('0xac1')+_0x4ec53f[_0x27ab66('0x12b0')][_0x27ab66('0x73c')]:undefined);_0x4ec53f[_0x27ab66('0x25eb')]=_0x21feb3,_0x4ec53f[_0x27ab66('0xf82')]=_0x256bd8;function _0x21feb3(){const _0x2b6318=_0x27ab66;_0x4ec53f[_0x2b6318('0x17f')]=[];const _0x1e049b=[];_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0xcf0')]&&_0x4ec53f['close'][_0x2b6318('0xcf0')]['toLowerCase']()==='outbound'&&_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0x11f3')]===_0x2b6318('0x4d2')&&(_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0xd31')]=_0x48686a[_0x2b6318('0x145a')]?(_0x4ec53f[_0x2b6318('0x12b0')]['prefix']||'')+'${EXTEN:'+_0x48686a[_0x2b6318('0x145a')]+'}':(_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0x24fa')]||'')+_0x2b6318('0x20cb'),_0x48686a['recordingFormat']!=='none'?_0x4ec53f['close'][_0x2b6318('0x158e')][_0x2b6318('0x824')](_0x2b6318('0x1b1'))<0x0&&(_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0x158e')]+=_0x2b6318('0x1b1')):_0x4ec53f['close'][_0x2b6318('0x158e')]=_0x4ec53f['close'][_0x2b6318('0x158e')]['replace']('U(xcally-mixmonitor-context)',''));if(_0x4ec53f['close']['appType']&&_0x4ec53f[_0x2b6318('0x12b0')]['appType']===_0x2b6318('0xbf0')){}else switch((_0x4ec53f[_0x2b6318('0x12b0')]['app']||_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0x11f3')])['toLowerCase']()){case _0x2b6318('0x877'):_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0x1407')]=_0x4ec53f[_0x2b6318('0x12b0')]['name']+'='+_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0x1c6b')];break;case _0x2b6318('0xbf0'):break;default:_0x1e049b[0x0]=_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0x43f')],_0x4ec53f[_0x2b6318('0x12b0')][_0x2b6318('0x1407')]=_0x1e049b[_0x2b6318('0x1630')](',');}_0x256bd8(_0x4ec53f[_0x2b6318('0x12b0')]);}function _0x256bd8(_0x3ebf56){const _0x2e4828=_0x27ab66;_0x47cab4[_0x2e4828('0x1715')](_0x3ebf56);}}const _0x4b796f=_0x46ee74;_0x157b21[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty','chatWebsiteApp','chatWebsite',_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0x157b21(_0x3fde7c,_0x2c928e,_0x26af97,_0x2cc101,_0x55b5f6,_0x2fddf7,_0x1a225b,_0x228ec9){const _0x2293dd=_0x189033,_0x58373c=this;_0x58373c[_0x2293dd('0x11ed')]=_0x1a225b[_0x2293dd('0x20b2')](),_0x58373c[_0x2293dd('0x17f')]=[],_0x58373c['title']=_0x2293dd('0x1c66')+(_0x2cc101[_0x2293dd('0x11f3')]||_0x2cc101[_0x2293dd('0x1d75')])[_0x2293dd('0x80')](),_0x58373c[_0x2293dd('0x205c')]=angular[_0x2293dd('0x1a86')](_0x2cc101),_0x58373c[_0x2293dd('0x1134')]=_0x228ec9,_0x58373c[_0x2293dd('0x258d')]={};if(_0x58373c['dialogflow'][_0x2293dd('0x1407')])switch(_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x11f3')]?_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x11f3')][_0x2293dd('0x93a')]():_0x58373c['dialogflow'][_0x2293dd('0x1d75')][_0x2293dd('0x93a')]()){case'custom':break;case _0x2293dd('0x205c'):{const _0x39dfa=_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x1407')][_0x2293dd('0x1fc5')](',');_0x58373c[_0x2293dd('0x205c')]['key']=_0x39dfa[0x0],_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x1a1c')]=_0x39dfa[0x1],_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x6d9')]=_0x39dfa[_0x2293dd('0x12c8')](0x2,_0x39dfa[_0x2293dd('0x1564')])[_0x2293dd('0x1630')](',');}break;case'dialogflowv2':{const _0x258e10=_0x58373c[_0x2293dd('0x205c')]['appdata'][_0x2293dd('0x1fc5')](',');_0x58373c['dialogflow'][_0x2293dd('0x2119')]=_0x258e10[0x0],_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x38')]=_0x258e10[0x1],_0x58373c['dialogflow'][_0x2293dd('0x406')]=_0x258e10[0x2],_0x58373c[_0x2293dd('0x205c')]['language']=_0x258e10[0x3],_0x58373c['dialogflow'][_0x2293dd('0x6d9')]=_0x258e10[_0x2293dd('0x12c8')](0x4,_0x258e10[_0x2293dd('0x1564')])['join'](',');}break;case _0x2293dd('0x1db1'):{const _0x51d9bc=_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x1407')][_0x2293dd('0x1fc5')](',');_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x7ae')]=_0x51d9bc[0x0],_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x204a')]=_0x51d9bc[0x1],_0x58373c['dialogflow'][_0x2293dd('0x5ba')]=_0x51d9bc[0x2],_0x58373c['dialogflow'][_0x2293dd('0x11a9')]=_0x51d9bc[0x3],_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x6d9')]=_0x51d9bc['slice'](0x4,_0x51d9bc['length'])[_0x2293dd('0x1630')](',');}break;case'autoreply':{const _0x40db16=_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x1407')][_0x2293dd('0x1fc5')](',');_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x35')]=isNaN(_0x40db16[0x0])?_0x40db16[0x0]:parseInt(_0x40db16[0x0],0xa),_0x58373c['dialogflow'][_0x2293dd('0x1bcd')]=_0x40db16[_0x2293dd('0x12c8')](0x1,_0x40db16['length'])[_0x2293dd('0x1630')](',');}break;case _0x2293dd('0x8c2'):_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x1bcd')]=_0x58373c[_0x2293dd('0x205c')]['appdata'];break;case'set':_0x58373c['dialogflow']['name']=_0x58373c['dialogflow'][_0x2293dd('0x1407')][_0x2293dd('0x1fc5')]('=')[0x0],_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x1c6b')]=_0x58373c[_0x2293dd('0x205c')]['appdata'][_0x2293dd('0x1fc5')]('=')[0x1];break;case _0x2293dd('0x19ae'):_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x273a')]=_0x58373c['dialogflow'][_0x2293dd('0x1407')];break;default:{const _0xe18f4f=_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x1407')]['split'](',');_0x58373c['dialogflow'][_0x2293dd('0x1d46')]=_0x2e3ca0()[_0x2293dd('0x173f')](_0xe18f4f[0x0])?_0xe18f4f[0x0]:isNaN(_0xe18f4f[0x0])?_0xe18f4f[0x0]:parseInt(_0xe18f4f[0x0],0xa),_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x1a1c')]=_0x2e3ca0()[_0x2293dd('0x173f')](_0xe18f4f[0x1])?_0xe18f4f[0x1]:isNaN(_0xe18f4f[0x1])?_0xe18f4f[0x1]:parseInt(_0xe18f4f[0x1],0xa),_0x58373c[_0x2293dd('0x205c')]['welcomemessage']=_0x2e3ca0()['isEmpty'](_0xe18f4f[0x2])?_0xe18f4f[0x2]:isNaN(_0xe18f4f[0x2])?_0xe18f4f[0x2]:parseInt(_0xe18f4f[0x2],0xa);}break;}else _0x58373c['dialogflow'][_0x2293dd('0x1a1c')]='en';_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0xcf0')]&&_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0xcf0')]['toLowerCase']()===_0x2293dd('0x17cd')&&_0x58373c['dialogflow']['appType']['toLowerCase']()===_0x2293dd('0x659')&&(_0x58373c['dialogflow'][_0x2293dd('0x24fa')]=_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0xd31')]?_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0xd31')][_0x2293dd('0x1fc5')]('$')[0x0]:undefined,_0x58373c['dialogflow'][_0x2293dd('0xabd')]=_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x73c')]?_0x2293dd('0xac1')+_0x58373c[_0x2293dd('0x205c')][_0x2293dd('0x73c')]:undefined);_0x58373c['saveChatWebsiteApp']=_0xc36b13,_0x58373c[_0x2293dd('0xf82')]=_0xf79ab1;function _0xc36b13(){const _0x11ddb8=_0x2293dd;_0x58373c['errors']=[];const _0x187b1b=[];_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0xcf0')]&&_0x58373c['dialogflow'][_0x11ddb8('0xcf0')][_0x11ddb8('0x93a')]()===_0x11ddb8('0x17cd')&&_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x11f3')]===_0x11ddb8('0x4d2')&&(_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0xd31')]=_0x55b5f6[_0x11ddb8('0x145a')]?(_0x58373c[_0x11ddb8('0x205c')]['prefix']||'')+_0x11ddb8('0x249e')+_0x55b5f6[_0x11ddb8('0x145a')]+'}':(_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x24fa')]||'')+_0x11ddb8('0x20cb'),_0x55b5f6[_0x11ddb8('0x75b')]!=='none'?_0x58373c[_0x11ddb8('0x205c')]['options']['indexOf'](_0x11ddb8('0x1b1'))<0x0&&(_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x158e')]+='U(xcally-mixmonitor-context)'):_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x158e')]=_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x158e')][_0x11ddb8('0x1725')]('U(xcally-mixmonitor-context)',''));if(_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x11f3')]&&_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x11f3')]===_0x11ddb8('0xbf0')){}else switch((_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x1d75')]||_0x58373c[_0x11ddb8('0x205c')]['appType'])[_0x11ddb8('0x93a')]()){case'set':_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x1407')]=_0x58373c['dialogflow'][_0x11ddb8('0x60a')]+'='+_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x1c6b')];break;case _0x11ddb8('0xbf0'):break;default:_0x187b1b[0x0]=_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x1d46')],_0x187b1b[0x1]=_0x58373c['dialogflow'][_0x11ddb8('0x1a1c')],_0x187b1b[0x2]=_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x6d9')],_0x58373c[_0x11ddb8('0x205c')][_0x11ddb8('0x1407')]=_0x187b1b[_0x11ddb8('0x1630')](',');}_0xf79ab1(_0x58373c['dialogflow']);}function _0xf79ab1(_0x4efaec){const _0x37c025=_0x2293dd;_0x3fde7c[_0x37c025('0x1715')](_0x4efaec);}}const _0x27e349=_0x157b21;_0x1ce70b[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'chatWebsiteApp','chatWebsite','api',_0x189033('0xba1'),'crudPermissions'];function _0x1ce70b(_0x2b1e9a,_0x87465b,_0x663c72,_0x235503,_0x4c2c55,_0x3647ca,_0x52f058,_0x59bd26){const _0x2d1d07=_0x189033,_0x3ba1da=this;_0x3ba1da[_0x2d1d07('0x11ed')]=_0x52f058[_0x2d1d07('0x20b2')](),_0x3ba1da['errors']=[],_0x3ba1da[_0x2d1d07('0xf28')]=_0x2d1d07('0x1c66')+(_0x235503['appType']||_0x235503[_0x2d1d07('0x1d75')])[_0x2d1d07('0x80')](),_0x3ba1da[_0x2d1d07('0xc33')]=angular['copy'](_0x235503),_0x3ba1da[_0x2d1d07('0x1134')]=_0x59bd26,_0x3ba1da[_0x2d1d07('0x258d')]={};if(_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x1407')])switch(_0x3ba1da['gotoif']['appType']?_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x11f3')][_0x2d1d07('0x93a')]():_0x3ba1da['gotoif']['app'][_0x2d1d07('0x93a')]()){case _0x2d1d07('0xbf0'):break;case _0x2d1d07('0x205c'):{const _0x4ee575=_0x3ba1da['gotoif'][_0x2d1d07('0x1407')][_0x2d1d07('0x1fc5')](',');_0x3ba1da['gotoif']['key']=_0x4ee575[0x0],_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x1a1c')]=_0x4ee575[0x1],_0x3ba1da['gotoif'][_0x2d1d07('0x6d9')]=_0x4ee575[_0x2d1d07('0x12c8')](0x2,_0x4ee575[_0x2d1d07('0x1564')])[_0x2d1d07('0x1630')](',');}break;case _0x2d1d07('0xd24'):{const _0x5ab0cf=_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x1407')][_0x2d1d07('0x1fc5')](',');_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x2119')]=_0x5ab0cf[0x0],_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x38')]=_0x5ab0cf[0x1],_0x3ba1da['gotoif'][_0x2d1d07('0x406')]=_0x5ab0cf[0x2],_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x1a1c')]=_0x5ab0cf[0x3],_0x3ba1da['gotoif'][_0x2d1d07('0x6d9')]=_0x5ab0cf[_0x2d1d07('0x12c8')](0x4,_0x5ab0cf[_0x2d1d07('0x1564')])['join'](',');}break;case'amazonlex':{const _0x290f19=_0x3ba1da['gotoif'][_0x2d1d07('0x1407')][_0x2d1d07('0x1fc5')](',');_0x3ba1da[_0x2d1d07('0xc33')]['accesskeyid']=_0x290f19[0x0],_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x204a')]=_0x290f19[0x1],_0x3ba1da['gotoif'][_0x2d1d07('0x5ba')]=_0x290f19[0x2],_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x11a9')]=_0x290f19[0x3],_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x6d9')]=_0x290f19[_0x2d1d07('0x12c8')](0x4,_0x290f19['length'])['join'](',');}break;case _0x2d1d07('0x2408'):{const _0x45c1f4=_0x3ba1da['gotoif'][_0x2d1d07('0x1407')][_0x2d1d07('0x1fc5')](',');_0x3ba1da['gotoif']['times']=isNaN(_0x45c1f4[0x0])?_0x45c1f4[0x0]:parseInt(_0x45c1f4[0x0],0xa),_0x3ba1da['gotoif'][_0x2d1d07('0x1bcd')]=_0x45c1f4[_0x2d1d07('0x12c8')](0x1,_0x45c1f4[_0x2d1d07('0x1564')])['join'](',');}break;case _0x2d1d07('0x8c2'):_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x1bcd')]=_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x1407')];break;case _0x2d1d07('0x877'):_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x60a')]=_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x1407')][_0x2d1d07('0x1fc5')]('=')[0x0],_0x3ba1da[_0x2d1d07('0xc33')]['value']=_0x3ba1da['gotoif'][_0x2d1d07('0x1407')][_0x2d1d07('0x1fc5')]('=')[0x1];break;case _0x2d1d07('0x19ae'):_0x3ba1da[_0x2d1d07('0xc33')]['project']=_0x3ba1da[_0x2d1d07('0xc33')]['appdata'];break;default:{const _0x147778=_0x3ba1da['gotoif'][_0x2d1d07('0x1407')][_0x2d1d07('0x1fc5')](',');_0x3ba1da['gotoif'][_0x2d1d07('0x168e')]=_0x2e3ca0()[_0x2d1d07('0x173f')](_0x147778[0x0])?_0x147778[0x0]:isNaN(_0x147778[0x0])?_0x147778[0x0]:parseInt(_0x147778[0x0],0xa),_0x3ba1da[_0x2d1d07('0xc33')]['truepriority']=_0x2e3ca0()[_0x2d1d07('0x173f')](_0x147778[0x1])?_0x147778[0x1]:isNaN(_0x147778[0x1])?_0x147778[0x1]:parseInt(_0x147778[0x1],0xa),_0x3ba1da[_0x2d1d07('0xc33')]['falsepriority']=_0x2e3ca0()[_0x2d1d07('0x173f')](_0x147778[0x2])?_0x147778[0x2]:isNaN(_0x147778[0x2])?_0x147778[0x2]:parseInt(_0x147778[0x2],0xa);}break;}else{}_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0xcf0')]&&_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0xcf0')][_0x2d1d07('0x93a')]()===_0x2d1d07('0x17cd')&&_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x11f3')][_0x2d1d07('0x93a')]()==='outbounddial'&&(_0x3ba1da[_0x2d1d07('0xc33')]['prefix']=_0x3ba1da[_0x2d1d07('0xc33')]['phone']?_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0xd31')][_0x2d1d07('0x1fc5')]('$')[0x0]:undefined,_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0xabd')]=_0x3ba1da[_0x2d1d07('0xc33')][_0x2d1d07('0x73c')]?_0x2d1d07('0xac1')+_0x3ba1da[_0x2d1d07('0xc33')]['callerID']:undefined);_0x3ba1da[_0x2d1d07('0x25eb')]=_0x58ef05,_0x3ba1da[_0x2d1d07('0xf82')]=_0x33f75f;function _0x58ef05(){const _0x49192c=_0x2d1d07;_0x3ba1da[_0x49192c('0x17f')]=[];const _0x3a10ed=[];_0x3ba1da['gotoif']['type']&&_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0xcf0')]['toLowerCase']()===_0x49192c('0x17cd')&&_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x11f3')]==='outboundDial'&&(_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0xd31')]=_0x4c2c55['cutdigits']?(_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x24fa')]||'')+'${EXTEN:'+_0x4c2c55[_0x49192c('0x145a')]+'}':(_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x24fa')]||'')+_0x49192c('0x20cb'),_0x4c2c55['recordingFormat']!=='none'?_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x158e')]['indexOf'](_0x49192c('0x1b1'))<0x0&&(_0x3ba1da[_0x49192c('0xc33')]['options']+='U(xcally-mixmonitor-context)'):_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x158e')]=_0x3ba1da['gotoif']['options'][_0x49192c('0x1725')](_0x49192c('0x1b1'),''));if(_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x11f3')]&&_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x11f3')]===_0x49192c('0xbf0')){}else switch((_0x3ba1da['gotoif'][_0x49192c('0x1d75')]||_0x3ba1da['gotoif']['appType'])[_0x49192c('0x93a')]()){case _0x49192c('0x877'):_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x1407')]=_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x60a')]+'='+_0x3ba1da[_0x49192c('0xc33')]['value'];break;case'custom':break;default:_0x3a10ed[0x0]=_0x3ba1da['gotoif']['condition'],_0x3a10ed[0x1]=_0x3ba1da[_0x49192c('0xc33')]['truepriority'],_0x3a10ed[0x2]=_0x3ba1da[_0x49192c('0xc33')]['falsepriority'],_0x3ba1da[_0x49192c('0xc33')][_0x49192c('0x1407')]=_0x3a10ed[_0x49192c('0x1630')](',');}_0x33f75f(_0x3ba1da[_0x49192c('0xc33')]);}function _0x33f75f(_0x1877a3){const _0x90b838=_0x2d1d07;_0x2b1e9a[_0x90b838('0x1715')](_0x1877a3);}}const _0x633a85=_0x1ce70b;_0xbc4310[_0x189033('0x14be')]=['$mdDialog','$q','toasty',_0x189033('0x277b'),_0x189033('0x2681'),_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0xbc4310(_0x21eb9f,_0x512526,_0x490ca4,_0x577f86,_0x182fc5,_0x5ebcdd,_0x294635,_0x50aa5e){const _0x897b2a=_0x189033,_0x3e43ee=this;_0x3e43ee[_0x897b2a('0x11ed')]=_0x294635[_0x897b2a('0x20b2')](),_0x3e43ee['errors']=[],_0x3e43ee['title']=_0x897b2a('0x1c66')+(_0x577f86[_0x897b2a('0x11f3')]||_0x577f86['app'])['toUpperCase'](),_0x3e43ee[_0x897b2a('0x1da0')]=angular['copy'](_0x577f86),_0x3e43ee[_0x897b2a('0x1134')]=_0x50aa5e,_0x3e43ee[_0x897b2a('0x258d')]={};if(_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1407')])switch(_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x11f3')]?_0x3e43ee['gotop']['appType'][_0x897b2a('0x93a')]():_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1d75')][_0x897b2a('0x93a')]()){case _0x897b2a('0xbf0'):break;case _0x897b2a('0x205c'):{const _0x377d11=_0x3e43ee['gotop']['appdata']['split'](',');_0x3e43ee[_0x897b2a('0x1da0')]['key']=_0x377d11[0x0],_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1a1c')]=_0x377d11[0x1],_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x6d9')]=_0x377d11[_0x897b2a('0x12c8')](0x2,_0x377d11['length'])[_0x897b2a('0x1630')](',');}break;case _0x897b2a('0xd24'):{const _0x1beec8=_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1407')][_0x897b2a('0x1fc5')](',');_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x2119')]=_0x1beec8[0x0],_0x3e43ee['gotop']['clientEmail']=_0x1beec8[0x1],_0x3e43ee['gotop'][_0x897b2a('0x406')]=_0x1beec8[0x2],_0x3e43ee[_0x897b2a('0x1da0')]['language']=_0x1beec8[0x3],_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x6d9')]=_0x1beec8[_0x897b2a('0x12c8')](0x4,_0x1beec8[_0x897b2a('0x1564')])[_0x897b2a('0x1630')](',');}break;case'amazonlex':{const _0x3bd44c=_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1407')][_0x897b2a('0x1fc5')](',');_0x3e43ee['gotop']['accesskeyid']=_0x3bd44c[0x0],_0x3e43ee[_0x897b2a('0x1da0')]['secretaccesskey']=_0x3bd44c[0x1],_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x5ba')]=_0x3bd44c[0x2],_0x3e43ee['gotop'][_0x897b2a('0x11a9')]=_0x3bd44c[0x3],_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x6d9')]=_0x3bd44c[_0x897b2a('0x12c8')](0x4,_0x3bd44c[_0x897b2a('0x1564')])['join'](',');}break;case'autoreply':{const _0x2c2225=_0x3e43ee['gotop']['appdata'][_0x897b2a('0x1fc5')](',');_0x3e43ee['gotop']['times']=isNaN(_0x2c2225[0x0])?_0x2c2225[0x0]:parseInt(_0x2c2225[0x0],0xa),_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1bcd')]=_0x2c2225[_0x897b2a('0x12c8')](0x1,_0x2c2225['length'])[_0x897b2a('0x1630')](',');}break;case'message':_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1bcd')]=_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1407')];break;case'set':_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x60a')]=_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1407')]['split']('=')[0x0],_0x3e43ee[_0x897b2a('0x1da0')]['value']=_0x3e43ee['gotop']['appdata'][_0x897b2a('0x1fc5')]('=')[0x1];break;case _0x897b2a('0x19ae'):_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x273a')]=_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x1407')];break;default:{const _0x1aee34=_0x3e43ee[_0x897b2a('0x1da0')]['appdata'][_0x897b2a('0x1fc5')](',');_0x3e43ee['gotop'][_0x897b2a('0xe1e')]=_0x2e3ca0()[_0x897b2a('0x173f')](_0x1aee34[0x0])?_0x1aee34[0x0]:isNaN(_0x1aee34[0x0])?_0x1aee34[0x0]:parseInt(_0x1aee34[0x0],0xa);}break;}else{}_0x3e43ee[_0x897b2a('0x1da0')]['type']&&_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0xcf0')][_0x897b2a('0x93a')]()===_0x897b2a('0x17cd')&&_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x11f3')][_0x897b2a('0x93a')]()===_0x897b2a('0x659')&&(_0x3e43ee['gotop'][_0x897b2a('0x24fa')]=_0x3e43ee[_0x897b2a('0x1da0')]['phone']?_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0xd31')][_0x897b2a('0x1fc5')]('$')[0x0]:undefined,_0x3e43ee[_0x897b2a('0x1da0')]['callerId']=_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x73c')]?_0x897b2a('0xac1')+_0x3e43ee[_0x897b2a('0x1da0')][_0x897b2a('0x73c')]:undefined);_0x3e43ee[_0x897b2a('0x25eb')]=_0x2ae74e,_0x3e43ee[_0x897b2a('0xf82')]=_0xb53213;function _0x2ae74e(){const _0x4f4b57=_0x897b2a;_0x3e43ee['errors']=[];const _0x5ea25e=[];_0x3e43ee['gotop'][_0x4f4b57('0xcf0')]&&_0x3e43ee['gotop']['type'][_0x4f4b57('0x93a')]()===_0x4f4b57('0x17cd')&&_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x11f3')]===_0x4f4b57('0x4d2')&&(_0x3e43ee['gotop'][_0x4f4b57('0xd31')]=_0x182fc5['cutdigits']?(_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x24fa')]||'')+_0x4f4b57('0x249e')+_0x182fc5[_0x4f4b57('0x145a')]+'}':(_0x3e43ee['gotop'][_0x4f4b57('0x24fa')]||'')+'${EXTEN}',_0x182fc5[_0x4f4b57('0x75b')]!==_0x4f4b57('0x925')?_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x158e')][_0x4f4b57('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x158e')]+=_0x4f4b57('0x1b1')):_0x3e43ee['gotop']['options']=_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x158e')][_0x4f4b57('0x1725')](_0x4f4b57('0x1b1'),''));if(_0x3e43ee['gotop']['appType']&&_0x3e43ee['gotop'][_0x4f4b57('0x11f3')]===_0x4f4b57('0xbf0')){}else switch((_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x1d75')]||_0x3e43ee['gotop'][_0x4f4b57('0x11f3')])[_0x4f4b57('0x93a')]()){case'set':_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x1407')]=_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x60a')]+'='+_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x1c6b')];break;case _0x4f4b57('0xbf0'):break;default:_0x5ea25e[0x0]=_0x3e43ee['gotop'][_0x4f4b57('0xe1e')],_0x3e43ee[_0x4f4b57('0x1da0')][_0x4f4b57('0x1407')]=_0x5ea25e['join'](',');}_0xb53213(_0x3e43ee[_0x4f4b57('0x1da0')]);}function _0xb53213(_0x40a99c){const _0x3ff236=_0x897b2a;_0x21eb9f[_0x3ff236('0x1715')](_0x40a99c);}}const _0x6712a4=_0xbc4310;_0x15963b['$inject']=[_0x189033('0x938'),_0x189033('0x1e48'),_0x189033('0xb33'),_0x189033('0x844'),_0x189033('0x115c'),_0x189033('0xe98'),'toasty',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x15963b(_0x303d0d,_0x548950,_0x5c2451,_0x3bef96,_0x390797,_0x1f08f5,_0x481f7c,_0x5e82a3,_0x2ec3ab,_0x711235){const _0x32775a=_0x189033,_0x4d9b68=this;_0x4d9b68[_0x32775a('0x11ed')]=_0x2ec3ab[_0x32775a('0x20b2')](),_0x4d9b68['errors']=[],_0x4d9b68['title']=_0x32775a('0xc62'),_0x4d9b68['interval']=angular[_0x32775a('0x1a86')](_0x390797),_0x4d9b68['intervals']=_0x1f08f5,_0x4d9b68[_0x32775a('0x1470')]=![],_0x4d9b68[_0x32775a('0x1de1')]=[_0x32775a('0x10af'),_0x32775a('0xbf0'),_0x32775a('0x2335')],_0x4d9b68[_0x32775a('0x1134')]=_0x711235,_0x4d9b68['daysOfWeek']=_0x3bef96[_0x32775a('0xe88')](),_0x4d9b68[_0x32775a('0x1dfd')]=_0x3bef96['getMonthNumber'](),_0x4d9b68['monthName']=_0x3bef96[_0x32775a('0x1fe4')](),_0x4d9b68['daysOfMonth']=_0x3bef96[_0x32775a('0x181b')]();if(!_0x4d9b68[_0x32775a('0x115c')])_0x4d9b68[_0x32775a('0x115c')]={'interval':_0x32775a('0x1b54')},_0x4d9b68[_0x32775a('0xcf0')]='always',_0x4d9b68[_0x32775a('0xf28')]=_0x32775a('0x1e94'),_0x4d9b68[_0x32775a('0x1470')]=!![];else{if(_0x4d9b68[_0x32775a('0x115c')][_0x32775a('0x115c')]!==_0x32775a('0x1b54')){_0x4d9b68[_0x32775a('0xcf0')]=_0x32775a('0xbf0');const _0x5be41a=_0x4d9b68['interval'][_0x32775a('0x115c')]['split'](','),_0x44dd0b=_0x5be41a[0x0],_0x2b622c=_0x5be41a[0x1],_0x2b647f=_0x5be41a[0x2],_0xad98fc=_0x5be41a[0x3];if(_0x44dd0b!=='*'){const _0x5f37c7=_0x44dd0b[_0x32775a('0x1fc5')]('-')[0x0],_0xd465b5=_0x44dd0b['split']('-')[0x1];let _0x1aad44;_0x1aad44=new Date(),_0x1aad44[_0x32775a('0x2813')](Number(_0x5f37c7[_0x32775a('0x1fc5')](':')[0x0])),_0x1aad44[_0x32775a('0x1fb7')](Number(_0x5f37c7[_0x32775a('0x1fc5')](':')[0x1])),_0x4d9b68[_0x32775a('0xc32')]=_0x1aad44,_0x1aad44=new Date(),_0x1aad44[_0x32775a('0x2813')](Number(_0xd465b5['split'](':')[0x0])),_0x1aad44[_0x32775a('0x1fb7')](Number(_0xd465b5[_0x32775a('0x1fc5')](':')[0x1])),_0x4d9b68['timeRangeTo']=_0x1aad44;}_0x2b622c!=='*'&&(_0x4d9b68[_0x32775a('0x232d')]=_0x2b622c['split']('-')[0x0],_0x4d9b68[_0x32775a('0x1269')]=_0x2b622c[_0x32775a('0x1fc5')]('-')[0x1]),_0x2b647f!=='*'&&(_0x4d9b68[_0x32775a('0xf13')]=_0x2b647f[_0x32775a('0x1fc5')]('-')[0x0],_0x4d9b68[_0x32775a('0xfe5')]=_0x2b647f['split']('-')[0x1]),_0xad98fc!=='*'&&(_0x4d9b68[_0x32775a('0x1690')]=_0xad98fc[_0x32775a('0x1fc5')]('-')[0x0],_0x4d9b68[_0x32775a('0x1f12')]=_0xad98fc['split']('-')[0x1]);}else _0x4d9b68['type']='always';}_0x303d0d['params']['id']&&!_0x4d9b68['interval'][_0x32775a('0x121e')]&&(_0x4d9b68[_0x32775a('0x115c')]['IntervalId']=_0x303d0d[_0x32775a('0x7f2')]['id']);_0x4d9b68[_0x32775a('0x115c')][_0x32775a('0x5ae')]&&_0x4d9b68['interval']['application']&&(_0x4d9b68[_0x32775a('0xcf0')]=_0x32775a('0x2335'));_0x4d9b68[_0x32775a('0x1a4d')]=_0x286c84,_0x4d9b68[_0x32775a('0x1807')]=_0x1ceb49,_0x4d9b68[_0x32775a('0xf82')]=_0x50a92a;_0x4d9b68[_0x32775a('0x115c')][_0x32775a('0x121e')]&&(_0x2ec3ab[_0x32775a('0xca1')](_0x32775a('0x20c2'))?_0x5e82a3[_0x32775a('0x115c')][_0x32775a('0x1e6e')]({'fields':_0x32775a('0x1e24'),'IntervalId':'null','nolimit':!![]})[_0x32775a('0xe53')]['then'](function(_0x52f35e){const _0x2c7397=_0x32775a;_0x4d9b68[_0x2c7397('0xe98')]=_0x52f35e['rows']||[];})[_0x32775a('0x130a')](function(_0x16da0f){const _0x523ca9=_0x32775a;_0x481f7c['error']({'title':_0x16da0f[_0x523ca9('0x13ee')]?_0x523ca9('0x2168')+_0x16da0f['status']+_0x523ca9('0xbf6')+_0x16da0f[_0x523ca9('0x24a9')]:_0x523ca9('0x1e65'),'msg':_0x16da0f[_0x523ca9('0x5a5')]?JSON[_0x523ca9('0x258a')](_0x16da0f['data']):_0x16da0f[_0x523ca9('0x1ff0')]()});}):_0x5e82a3[_0x32775a('0x115c')][_0x32775a('0x1e6e')]({'fields':_0x32775a('0x1e24'),'IntervalId':_0x32775a('0x13c'),'nolimit':!![]})[_0x32775a('0xe53')]['then'](function(_0x59c59f){const _0x46b7ee=_0x32775a;_0x4d9b68[_0x46b7ee('0xe98')]=_0x59c59f[_0x46b7ee('0xf5d')]||[];})[_0x32775a('0x683')](function(){const _0x1c1d30=_0x32775a;return _0x5e82a3[_0x1c1d30('0x22df')][_0x1c1d30('0x1e6e')]({'userProfileId':_0x4d9b68[_0x1c1d30('0x11ed')][_0x1c1d30('0x2f')],'sectionId':0x3ec})[_0x1c1d30('0xe53')];})['then'](function(_0x40efa9){const _0x4159b5=_0x32775a,_0x165801=_0x40efa9&&_0x40efa9[_0x4159b5('0xf5d')]?_0x40efa9[_0x4159b5('0xf5d')][0x0]:null;if(!_0x165801)_0x4d9b68[_0x4159b5('0xe98')]=[];else{if(!_0x165801['autoAssociation'])return _0x5e82a3['userProfileResource'][_0x4159b5('0x1e6e')]({'sectionId':_0x165801['id']})[_0x4159b5('0xe53')][_0x4159b5('0x683')](function(_0x487fc1){const _0x5c8f41=_0x4159b5,_0xd414dc=_0x487fc1&&_0x487fc1[_0x5c8f41('0xf5d')]?_0x487fc1[_0x5c8f41('0xf5d')]:[],_0x35fb96=[];let _0x42ab30=null;_0x4d9b68['interval']&&(_0x42ab30=_0x2e3ca0()['find'](_0x4d9b68[_0x5c8f41('0xe98')],{'name':_0x4d9b68[_0x5c8f41('0x115c')][_0x5c8f41('0x5ae')]})),_0x42ab30&&!_0x2e3ca0()[_0x5c8f41('0x7a2')](_0xd414dc,[_0x5c8f41('0x832'),_0x42ab30['id']])&&_0x4d9b68['intervals'][_0x5c8f41('0x1299')](function(_0x3ad926){const _0x3c8801=_0x5c8f41;_0x3ad926['id']===_0x42ab30['id']&&(_0x3ad926[_0x3c8801('0x319')]=![],_0x35fb96['push'](_0x3ad926));}),_0x4d9b68[_0x5c8f41('0xe98')]=_0x35fb96;});}})[_0x32775a('0x130a')](function(_0x18a03c){const _0x5099ef=_0x32775a;_0x481f7c['error']({'title':_0x18a03c['status']?'API:'+_0x18a03c['status']+_0x5099ef('0xbf6')+_0x18a03c[_0x5099ef('0x24a9')]:_0x5099ef('0x1e65'),'msg':_0x18a03c[_0x5099ef('0x5a5')]?JSON[_0x5099ef('0x258a')](_0x18a03c['data']):_0x18a03c[_0x5099ef('0x1ff0')]()});}));function _0x5ac680(){const _0x1980b1=_0x32775a;switch(_0x4d9b68[_0x1980b1('0xcf0')]){case _0x1980b1('0x10af'):case'list':return _0x1980b1('0x1b54');case _0x1980b1('0xbf0'):{const _0xbfaf48=[];if(_0x4d9b68[_0x1980b1('0xc32')]!=='*'&&_0x4d9b68[_0x1980b1('0xc32')]&&_0x4d9b68['timeRangeTo']){const _0xead55d=(_0x4d9b68[_0x1980b1('0xc32')]['getHours']()<0xa?'0':'')+_0x4d9b68[_0x1980b1('0xc32')]['getHours']()+':'+((_0x4d9b68[_0x1980b1('0xc32')][_0x1980b1('0x1b5b')]()<0xa?'0':'')+_0x4d9b68['timeRangeFrom'][_0x1980b1('0x1b5b')]()),_0x4b6f61=(_0x4d9b68[_0x1980b1('0xaa0')][_0x1980b1('0x2575')]()<0xa?'0':'')+_0x4d9b68[_0x1980b1('0xaa0')][_0x1980b1('0x2575')]()+':'+((_0x4d9b68[_0x1980b1('0xaa0')]['getMinutes']()<0xa?'0':'')+_0x4d9b68[_0x1980b1('0xaa0')][_0x1980b1('0x1b5b')]());_0xbfaf48['push'](_0xead55d+'-'+_0x4b6f61);}else _0xbfaf48['push']('*');return _0x4d9b68['dayOfWeekFrom']?_0x4d9b68[_0x1980b1('0x1269')]?_0xbfaf48['push'](_0x4d9b68[_0x1980b1('0x232d')]+'-'+_0x4d9b68[_0x1980b1('0x1269')]):_0xbfaf48[_0x1980b1('0x1fd0')](_0x4d9b68[_0x1980b1('0x232d')]):_0xbfaf48[_0x1980b1('0x1fd0')]('*'),_0x4d9b68[_0x1980b1('0xf13')]?_0x4d9b68[_0x1980b1('0xfe5')]?_0xbfaf48['push'](_0x4d9b68[_0x1980b1('0xf13')]+'-'+_0x4d9b68['monthDayTo']):_0xbfaf48['push'](_0x4d9b68[_0x1980b1('0xf13')]):_0xbfaf48[_0x1980b1('0x1fd0')]('*'),_0x4d9b68[_0x1980b1('0x1690')]?_0x4d9b68[_0x1980b1('0x1f12')]?_0xbfaf48[_0x1980b1('0x1fd0')](_0x4d9b68[_0x1980b1('0x1690')]+'-'+_0x4d9b68[_0x1980b1('0x1f12')]):_0xbfaf48[_0x1980b1('0x1fd0')](_0x4d9b68['monthFrom']):_0xbfaf48[_0x1980b1('0x1fd0')]('*'),_0xbfaf48[_0x1980b1('0x1630')]();}}}function _0x286c84(){const _0x5c4870=_0x32775a;_0x4d9b68[_0x5c4870('0x17f')]=[],_0x4d9b68['interval'][_0x5c4870('0x115c')]=_0x5ac680(),_0x5e82a3[_0x5c4870('0x115c')][_0x5c4870('0xb0a')](_0x4d9b68[_0x5c4870('0x115c')])[_0x5c4870('0xe53')][_0x5c4870('0x683')](function(_0x2907f6){const _0x3cb9a5=_0x5c4870;_0x4d9b68[_0x3cb9a5('0xe98')][_0x3cb9a5('0x1fd0')](_0x2907f6),_0x481f7c[_0x3cb9a5('0x53')]({'title':_0x3cb9a5('0x24b5'),'msg':_0x4d9b68[_0x3cb9a5('0x115c')][_0x3cb9a5('0x60a')]?_0x4d9b68[_0x3cb9a5('0x115c')][_0x3cb9a5('0x60a')]+_0x3cb9a5('0x14b5'):''}),_0x50a92a();})['catch'](function(_0x26dc46){const _0x4195fd=_0x5c4870;console[_0x4195fd('0x52a')](_0x26dc46),_0x4d9b68['errors']=_0x26dc46[_0x4195fd('0x5a5')][_0x4195fd('0x17f')]||[{'message':_0x26dc46[_0x4195fd('0x1ff0')](),'type':_0x4195fd('0x1d24')}];});}function _0x1ceb49(){const _0xc17805=_0x32775a;_0x4d9b68[_0xc17805('0x17f')]=[],_0x4d9b68['interval']['interval']=_0x5ac680(),_0x4d9b68[_0xc17805('0x115c')]['application']?(_0x4d9b68['type']!==_0xc17805('0x2335')&&(_0x4d9b68[_0xc17805('0x115c')][_0xc17805('0x5ae')]=null),_0x50a92a(_0x4d9b68['interval'])):_0x5e82a3[_0xc17805('0x115c')][_0xc17805('0x2480')]({'id':_0x4d9b68[_0xc17805('0x115c')]['id']},_0x4d9b68[_0xc17805('0x115c')])['$promise']['then'](function(_0x4254b9){const _0x2a23d7=_0xc17805,_0x590862=_0x2e3ca0()['find'](_0x4d9b68['intervals'],{'id':_0x4254b9['id']});_0x590862&&_0x2e3ca0()['merge'](_0x590862,_0x4254b9),_0x481f7c[_0x2a23d7('0x53')]({'title':_0x2a23d7('0x18c3'),'msg':_0x2a23d7('0x224')}),_0x50a92a();})[_0xc17805('0x130a')](function(_0x331ace){const _0x5530ff=_0xc17805;console['error'](_0x331ace),_0x4d9b68[_0x5530ff('0x17f')]=_0x331ace['data']['errors']||[{'message':_0x331ace['toString'](),'type':_0x5530ff('0x605')}];});}function _0x50a92a(_0x3b1ea9){const _0x4faaa7=_0x32775a;_0x548950[_0x4faaa7('0x1715')](_0x3b1ea9);}}const _0x54e199=_0x15963b;_0x19c1a8[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x277b'),_0x189033('0x2681'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x19c1a8(_0x342cdc,_0x3c53a7,_0xb08848,_0x57b8c8,_0x3ca4e2,_0x53b5da,_0x27f852,_0x331167){const _0x35c6c5=_0x189033,_0x2d87b3=this;_0x2d87b3[_0x35c6c5('0x11ed')]=_0x27f852[_0x35c6c5('0x20b2')](),_0x2d87b3[_0x35c6c5('0x17f')]=[],_0x2d87b3[_0x35c6c5('0xf28')]='CHAT.EDIT_'+(_0x57b8c8[_0x35c6c5('0x11f3')]||_0x57b8c8[_0x35c6c5('0x1d75')])[_0x35c6c5('0x80')](),_0x2d87b3[_0x35c6c5('0x1126')]=angular['copy'](_0x57b8c8),_0x2d87b3[_0x35c6c5('0x1134')]=_0x331167,_0x2d87b3[_0x35c6c5('0x258d')]={};if(_0x2d87b3[_0x35c6c5('0x1126')]['appdata'])switch(_0x2d87b3[_0x35c6c5('0x1126')]['appType']?_0x2d87b3['noop'][_0x35c6c5('0x11f3')][_0x35c6c5('0x93a')]():_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x1d75')][_0x35c6c5('0x93a')]()){case'custom':break;case _0x35c6c5('0x205c'):{const _0x18baf2=_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x1407')][_0x35c6c5('0x1fc5')](',');_0x2d87b3['noop'][_0x35c6c5('0x1d46')]=_0x18baf2[0x0],_0x2d87b3['noop'][_0x35c6c5('0x1a1c')]=_0x18baf2[0x1],_0x2d87b3[_0x35c6c5('0x1126')]['welcomemessage']=_0x18baf2[_0x35c6c5('0x12c8')](0x2,_0x18baf2[_0x35c6c5('0x1564')])[_0x35c6c5('0x1630')](',');}break;case _0x35c6c5('0xd24'):{const _0x13bcbe=_0x2d87b3['noop'][_0x35c6c5('0x1407')]['split'](',');_0x2d87b3[_0x35c6c5('0x1126')]['projectId']=_0x13bcbe[0x0],_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x38')]=_0x13bcbe[0x1],_0x2d87b3['noop'][_0x35c6c5('0x406')]=_0x13bcbe[0x2],_0x2d87b3[_0x35c6c5('0x1126')]['language']=_0x13bcbe[0x3],_0x2d87b3[_0x35c6c5('0x1126')]['welcomemessage']=_0x13bcbe[_0x35c6c5('0x12c8')](0x4,_0x13bcbe[_0x35c6c5('0x1564')])[_0x35c6c5('0x1630')](',');}break;case'amazonlex':{const _0x93967=_0x2d87b3['noop'][_0x35c6c5('0x1407')][_0x35c6c5('0x1fc5')](',');_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x7ae')]=_0x93967[0x0],_0x2d87b3['noop'][_0x35c6c5('0x204a')]=_0x93967[0x1],_0x2d87b3['noop'][_0x35c6c5('0x5ba')]=_0x93967[0x2],_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x11a9')]=_0x93967[0x3],_0x2d87b3['noop'][_0x35c6c5('0x6d9')]=_0x93967['slice'](0x4,_0x93967['length'])[_0x35c6c5('0x1630')](',');}break;case _0x35c6c5('0x2408'):{const _0x3efe72=_0x2d87b3['noop']['appdata'][_0x35c6c5('0x1fc5')](',');_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x35')]=isNaN(_0x3efe72[0x0])?_0x3efe72[0x0]:parseInt(_0x3efe72[0x0],0xa),_0x2d87b3['noop'][_0x35c6c5('0x1bcd')]=_0x3efe72[_0x35c6c5('0x12c8')](0x1,_0x3efe72[_0x35c6c5('0x1564')])[_0x35c6c5('0x1630')](',');}break;case'message':_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x1bcd')]=_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x1407')];break;case _0x35c6c5('0x877'):_0x2d87b3[_0x35c6c5('0x1126')]['name']=_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x1407')][_0x35c6c5('0x1fc5')]('=')[0x0],_0x2d87b3[_0x35c6c5('0x1126')]['value']=_0x2d87b3['noop']['appdata']['split']('=')[0x1];break;case _0x35c6c5('0x19ae'):_0x2d87b3[_0x35c6c5('0x1126')]['project']=_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x1407')];break;default:{const _0x236e07=_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x1407')][_0x35c6c5('0x1fc5')](',');_0x2d87b3[_0x35c6c5('0x1126')]['value']=_0x2e3ca0()[_0x35c6c5('0x173f')](_0x236e07[0x0])?_0x236e07[0x0]:isNaN(_0x236e07[0x0])?_0x236e07[0x0]:parseInt(_0x236e07[0x0],0xa);}break;}else{}_0x2d87b3['noop'][_0x35c6c5('0xcf0')]&&_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0xcf0')][_0x35c6c5('0x93a')]()===_0x35c6c5('0x17cd')&&_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x11f3')][_0x35c6c5('0x93a')]()===_0x35c6c5('0x659')&&(_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x24fa')]=_0x2d87b3[_0x35c6c5('0x1126')]['phone']?_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0xd31')]['split']('$')[0x0]:undefined,_0x2d87b3['noop'][_0x35c6c5('0xabd')]=_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x73c')]?_0x35c6c5('0xac1')+_0x2d87b3[_0x35c6c5('0x1126')][_0x35c6c5('0x73c')]:undefined);_0x2d87b3[_0x35c6c5('0x25eb')]=_0x29b0a8,_0x2d87b3['closeDialog']=_0x911eae;function _0x29b0a8(){const _0x1e6a49=_0x35c6c5;_0x2d87b3['errors']=[];const _0x190b10=[];_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0xcf0')]&&_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0xcf0')][_0x1e6a49('0x93a')]()==='outbound'&&_0x2d87b3['noop'][_0x1e6a49('0x11f3')]===_0x1e6a49('0x4d2')&&(_0x2d87b3['noop'][_0x1e6a49('0xd31')]=_0x3ca4e2[_0x1e6a49('0x145a')]?(_0x2d87b3['noop'][_0x1e6a49('0x24fa')]||'')+_0x1e6a49('0x249e')+_0x3ca4e2[_0x1e6a49('0x145a')]+'}':(_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x24fa')]||'')+_0x1e6a49('0x20cb'),_0x3ca4e2[_0x1e6a49('0x75b')]!==_0x1e6a49('0x925')?_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x158e')][_0x1e6a49('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x158e')]+=_0x1e6a49('0x1b1')):_0x2d87b3[_0x1e6a49('0x1126')]['options']=_0x2d87b3[_0x1e6a49('0x1126')]['options'][_0x1e6a49('0x1725')](_0x1e6a49('0x1b1'),''));if(_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x11f3')]&&_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x11f3')]==='custom'){}else switch((_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x1d75')]||_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x11f3')])['toLowerCase']()){case _0x1e6a49('0x877'):_0x2d87b3[_0x1e6a49('0x1126')]['appdata']=_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x60a')]+'='+_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x1c6b')];break;case _0x1e6a49('0xbf0'):break;default:_0x190b10[0x0]=_0x2d87b3[_0x1e6a49('0x1126')]['value'],_0x2d87b3[_0x1e6a49('0x1126')][_0x1e6a49('0x1407')]=_0x190b10[_0x1e6a49('0x1630')](',');}_0x911eae(_0x2d87b3[_0x1e6a49('0x1126')]);}function _0x911eae(_0x4bc277){const _0x1219e4=_0x35c6c5;_0x342cdc[_0x1219e4('0x1715')](_0x4bc277);}}const _0x436139=_0x19c1a8;_0x27ca19[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x277b'),'chatWebsite',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x27ca19(_0x575b47,_0x3c2090,_0x36d352,_0x5abb46,_0xdd91e3,_0x38bc07,_0x4e3b54,_0x14fac0){const _0x2af4be=_0x189033,_0x3d496f=this;_0x3d496f['currentUser']=_0x4e3b54[_0x2af4be('0x20b2')](),_0x3d496f[_0x2af4be('0x17f')]=[],_0x3d496f[_0x2af4be('0xf28')]=_0x2af4be('0x1c66')+(_0x5abb46[_0x2af4be('0x11f3')]||_0x5abb46[_0x2af4be('0x1d75')])[_0x2af4be('0x80')](),_0x3d496f[_0x2af4be('0x660')]=angular[_0x2af4be('0x1a86')](_0x5abb46),_0x3d496f['crudPermissions']=_0x14fac0,_0x3d496f['hasModulePermissions']={};if(_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1407')])switch(_0x3d496f['queue'][_0x2af4be('0x11f3')]?_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x11f3')][_0x2af4be('0x93a')]():_0x3d496f['queue'][_0x2af4be('0x1d75')][_0x2af4be('0x93a')]()){case _0x2af4be('0xbf0'):break;case _0x2af4be('0x205c'):{const _0x412c3d=_0x3d496f[_0x2af4be('0x660')]['appdata'][_0x2af4be('0x1fc5')](',');_0x3d496f[_0x2af4be('0x660')]['key']=_0x412c3d[0x0],_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1a1c')]=_0x412c3d[0x1],_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x6d9')]=_0x412c3d[_0x2af4be('0x12c8')](0x2,_0x412c3d[_0x2af4be('0x1564')])['join'](',');}break;case'dialogflowv2':{const _0x273fed=_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1407')][_0x2af4be('0x1fc5')](',');_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x2119')]=_0x273fed[0x0],_0x3d496f[_0x2af4be('0x660')]['clientEmail']=_0x273fed[0x1],_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x406')]=_0x273fed[0x2],_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1a1c')]=_0x273fed[0x3],_0x3d496f['queue'][_0x2af4be('0x6d9')]=_0x273fed[_0x2af4be('0x12c8')](0x4,_0x273fed[_0x2af4be('0x1564')])[_0x2af4be('0x1630')](',');}break;case _0x2af4be('0x1db1'):{const _0xa775d6=_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1407')][_0x2af4be('0x1fc5')](',');_0x3d496f[_0x2af4be('0x660')]['accesskeyid']=_0xa775d6[0x0],_0x3d496f[_0x2af4be('0x660')]['secretaccesskey']=_0xa775d6[0x1],_0x3d496f[_0x2af4be('0x660')]['lexregion']=_0xa775d6[0x2],_0x3d496f['queue'][_0x2af4be('0x11a9')]=_0xa775d6[0x3],_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x6d9')]=_0xa775d6[_0x2af4be('0x12c8')](0x4,_0xa775d6[_0x2af4be('0x1564')])[_0x2af4be('0x1630')](',');}break;case'autoreply':{const _0x4cc580=_0x3d496f[_0x2af4be('0x660')]['appdata']['split'](',');_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x35')]=isNaN(_0x4cc580[0x0])?_0x4cc580[0x0]:parseInt(_0x4cc580[0x0],0xa),_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1bcd')]=_0x4cc580['slice'](0x1,_0x4cc580[_0x2af4be('0x1564')])['join'](',');}break;case _0x2af4be('0x8c2'):_0x3d496f[_0x2af4be('0x660')]['text']=_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1407')];break;case _0x2af4be('0x877'):_0x3d496f[_0x2af4be('0x660')]['name']=_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1407')][_0x2af4be('0x1fc5')]('=')[0x0],_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1c6b')]=_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1407')][_0x2af4be('0x1fc5')]('=')[0x1];break;case _0x2af4be('0x19ae'):_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x273a')]=_0x3d496f[_0x2af4be('0x660')]['appdata'];break;default:{const _0x5f2a10=_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1407')][_0x2af4be('0x1fc5')](',');_0x3d496f[_0x2af4be('0x660')]['queue']=_0x2e3ca0()['isEmpty'](_0x5f2a10[0x0])?_0x5f2a10[0x0]:isNaN(_0x5f2a10[0x0])?_0x5f2a10[0x0]:parseInt(_0x5f2a10[0x0],0xa),_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1668')]=_0x2e3ca0()['isEmpty'](_0x5f2a10[0x1])?_0x5f2a10[0x1]:isNaN(_0x5f2a10[0x1])?_0x5f2a10[0x1]:parseInt(_0x5f2a10[0x1],0xa);}break;}else _0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x660')]=0x12c,_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x1668')]=0x12c;_0x3d496f[_0x2af4be('0x660')]['type']&&_0x3d496f['queue'][_0x2af4be('0xcf0')][_0x2af4be('0x93a')]()==='outbound'&&_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x11f3')]['toLowerCase']()===_0x2af4be('0x659')&&(_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x24fa')]=_0x3d496f['queue'][_0x2af4be('0xd31')]?_0x3d496f['queue'][_0x2af4be('0xd31')][_0x2af4be('0x1fc5')]('$')[0x0]:undefined,_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0xabd')]=_0x3d496f[_0x2af4be('0x660')]['callerID']?_0x2af4be('0xac1')+_0x3d496f[_0x2af4be('0x660')][_0x2af4be('0x73c')]:undefined);_0x3d496f[_0x2af4be('0x25eb')]=_0x27ead1,_0x3d496f[_0x2af4be('0xf82')]=_0x39626f,_0x4e3b54[_0x2af4be('0xca1')](_0x2af4be('0x20c2'))?_0x38bc07[_0x2af4be('0x1524')][_0x2af4be('0x1e6e')]({'fields':_0x2af4be('0x2035'),'sort':'name','nolimit':_0x2af4be('0x26ac')})[_0x2af4be('0xe53')]['then'](function(_0x37d7ac){const _0x1e166b=_0x2af4be;_0x3d496f[_0x1e166b('0x2da')]=_0x37d7ac[_0x1e166b('0xf5d')]||[];})['catch'](function(_0x38502a){const _0x6c360e=_0x2af4be;_0x36d352[_0x6c360e('0x52a')]({'title':_0x38502a[_0x6c360e('0x13ee')]?'API:'+_0x38502a[_0x6c360e('0x13ee')]+_0x6c360e('0xbf6')+_0x38502a[_0x6c360e('0x24a9')]:_0x6c360e('0x22dc'),'msg':_0x38502a[_0x6c360e('0x5a5')]?JSON[_0x6c360e('0x258a')](_0x38502a[_0x6c360e('0x5a5')]):_0x38502a[_0x6c360e('0x1ff0')]()});}):_0x38bc07[_0x2af4be('0x1524')][_0x2af4be('0x1e6e')]({'fields':_0x2af4be('0x2035'),'sort':_0x2af4be('0x60a'),'nolimit':_0x2af4be('0x26ac')})[_0x2af4be('0xe53')][_0x2af4be('0x683')](function(_0x2dc430){const _0x1111a3=_0x2af4be;_0x3d496f[_0x1111a3('0x2da')]=_0x2dc430[_0x1111a3('0xf5d')]||[];})[_0x2af4be('0x683')](function(){const _0x2ebe77=_0x2af4be;return _0x38bc07[_0x2ebe77('0x22df')]['get']({'userProfileId':_0x3d496f[_0x2ebe77('0x11ed')][_0x2ebe77('0x2f')],'sectionId':0x1f5})[_0x2ebe77('0xe53')];})[_0x2af4be('0x683')](function(_0x1e446e){const _0x33c8b5=_0x2af4be,_0x55a2ee=_0x1e446e&&_0x1e446e[_0x33c8b5('0xf5d')]?_0x1e446e[_0x33c8b5('0xf5d')][0x0]:null;if(!_0x55a2ee){const _0x291d06=[];let _0x2d936c=null;_0x3d496f[_0x33c8b5('0x660')]&&(_0x2d936c=_0x2e3ca0()[_0x33c8b5('0x1c07')](_0x3d496f['queues'],{'name':_0x3d496f[_0x33c8b5('0x660')][_0x33c8b5('0x660')]}));for(let _0x5106c2=0x0;_0x5106c2<_0x3d496f[_0x33c8b5('0x2da')]['length'];_0x5106c2++){_0x2d936c&&_0x3d496f[_0x33c8b5('0x2da')][_0x5106c2]['id']===_0x2d936c['id']&&(_0x3d496f['queues'][_0x5106c2][_0x33c8b5('0x319')]=![],_0x291d06['push'](_0x3d496f[_0x33c8b5('0x2da')][_0x5106c2]));}_0x3d496f[_0x33c8b5('0x2da')]=_0x291d06;}else{if(!_0x55a2ee[_0x33c8b5('0x170')])return _0x38bc07['userProfileResource']['get']({'sectionId':_0x55a2ee['id']})[_0x33c8b5('0xe53')][_0x33c8b5('0x683')](function(_0x4fd912){const _0x84e7f3=_0x33c8b5,_0x3fb245=_0x2e3ca0()[_0x84e7f3('0x386')](_0x4fd912[_0x84e7f3('0xf5d')],function(_0x2548c8){const _0x525589=_0x84e7f3;return _0x2e3ca0()[_0x525589('0x1c07')](_0x3d496f[_0x525589('0x2da')],{'id':_0x2548c8['resourceId']});});let _0x21f790=null;_0x3d496f['queue']&&(_0x21f790=_0x2e3ca0()[_0x84e7f3('0x1c07')](_0x3d496f[_0x84e7f3('0x2da')],{'name':_0x3d496f[_0x84e7f3('0x660')][_0x84e7f3('0x660')]}));if(_0x21f790&&!_0x2e3ca0()[_0x84e7f3('0x7a2')](_0x3fb245,['id',_0x21f790['id']])){const _0xa86a45=_0x2e3ca0()['find'](_0x3d496f['queues'],{'id':_0x21f790['id']});_0xa86a45[_0x84e7f3('0x319')]=![],_0x3fb245['push'](_0xa86a45);}_0x3d496f[_0x84e7f3('0x2da')]=_0x3fb245;});}})[_0x2af4be('0x130a')](function(_0x300e31){const _0x291ae9=_0x2af4be;_0x36d352[_0x291ae9('0x52a')]({'title':_0x300e31['status']?_0x291ae9('0x2168')+_0x300e31[_0x291ae9('0x13ee')]+_0x291ae9('0xbf6')+_0x300e31[_0x291ae9('0x24a9')]:_0x291ae9('0x934'),'msg':_0x300e31[_0x291ae9('0x5a5')]?JSON['stringify'](_0x300e31[_0x291ae9('0x5a5')]):_0x300e31[_0x291ae9('0x1ff0')]()});});function _0x27ead1(){const _0xdecfb3=_0x2af4be;_0x3d496f[_0xdecfb3('0x17f')]=[];const _0x212a5f=[];_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0xcf0')]&&_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0xcf0')]['toLowerCase']()==='outbound'&&_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x11f3')]==='outboundDial'&&(_0x3d496f[_0xdecfb3('0x660')]['phone']=_0xdd91e3[_0xdecfb3('0x145a')]?(_0x3d496f['queue']['prefix']||'')+_0xdecfb3('0x249e')+_0xdd91e3[_0xdecfb3('0x145a')]+'}':(_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x24fa')]||'')+_0xdecfb3('0x20cb'),_0xdd91e3[_0xdecfb3('0x75b')]!=='none'?_0x3d496f['queue'][_0xdecfb3('0x158e')]['indexOf'](_0xdecfb3('0x1b1'))<0x0&&(_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x158e')]+=_0xdecfb3('0x1b1')):_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x158e')]=_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x158e')][_0xdecfb3('0x1725')](_0xdecfb3('0x1b1'),''));const _0x3afeca=_0x2e3ca0()[_0xdecfb3('0x1c07')](_0x3d496f[_0xdecfb3('0x2da')],{'name':_0x3d496f['queue'][_0xdecfb3('0x660')]});_0x3afeca&&(_0x3d496f[_0xdecfb3('0x660')][_0x2e3ca0()[_0xdecfb3('0x21ab')](_0xdecfb3('0x24e'))+'QueueId']=_0x3afeca['id']);if(_0x3d496f['queue'][_0xdecfb3('0x11f3')]&&_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x11f3')]===_0xdecfb3('0xbf0')){}else switch((_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x1d75')]||_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x11f3')])[_0xdecfb3('0x93a')]()){case'set':_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x1407')]=_0x3d496f[_0xdecfb3('0x660')]['name']+'='+_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x1c6b')];break;case'custom':break;default:_0x212a5f[0x0]=_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x660')],_0x212a5f[0x1]=_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x1668')],_0x3d496f[_0xdecfb3('0x660')][_0xdecfb3('0x1407')]=_0x212a5f[_0xdecfb3('0x1630')](',');}_0x39626f(_0x3d496f[_0xdecfb3('0x660')]);}function _0x39626f(_0x5dd9d7){_0x575b47['hide'](_0x5dd9d7);}}const _0x3adb53=_0x27ca19;_0x258ffa['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x277b'),'chatWebsite',_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x258ffa(_0x383b0a,_0xac87e1,_0x2baa75,_0x5f14a4,_0x4ea370,_0x448932,_0x3c36f4,_0x4028a2){const _0x2c063f=_0x189033,_0x449a5a=this;_0x449a5a[_0x2c063f('0x11ed')]=_0x3c36f4['getCurrentUser'](),_0x449a5a['errors']=[],_0x449a5a[_0x2c063f('0xf28')]='CHAT.EDIT_'+(_0x5f14a4[_0x2c063f('0x11f3')]||_0x5f14a4[_0x2c063f('0x1d75')])[_0x2c063f('0x80')](),_0x449a5a[_0x2c063f('0x24f2')]=angular['copy'](_0x5f14a4),_0x449a5a[_0x2c063f('0x1134')]=_0x4028a2,_0x449a5a['hasModulePermissions']={};if(_0x449a5a['system'][_0x2c063f('0x1407')])switch(_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x11f3')]?_0x449a5a['system'][_0x2c063f('0x11f3')][_0x2c063f('0x93a')]():_0x449a5a['system'][_0x2c063f('0x1d75')][_0x2c063f('0x93a')]()){case _0x2c063f('0xbf0'):break;case _0x2c063f('0x205c'):{const _0x4fca34=_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x1407')][_0x2c063f('0x1fc5')](',');_0x449a5a['system'][_0x2c063f('0x1d46')]=_0x4fca34[0x0],_0x449a5a[_0x2c063f('0x24f2')]['language']=_0x4fca34[0x1],_0x449a5a[_0x2c063f('0x24f2')]['welcomemessage']=_0x4fca34[_0x2c063f('0x12c8')](0x2,_0x4fca34[_0x2c063f('0x1564')])[_0x2c063f('0x1630')](',');}break;case'dialogflowv2':{const _0x439bcb=_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x1407')][_0x2c063f('0x1fc5')](',');_0x449a5a['system'][_0x2c063f('0x2119')]=_0x439bcb[0x0],_0x449a5a['system'][_0x2c063f('0x38')]=_0x439bcb[0x1],_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x406')]=_0x439bcb[0x2],_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x1a1c')]=_0x439bcb[0x3],_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x6d9')]=_0x439bcb[_0x2c063f('0x12c8')](0x4,_0x439bcb[_0x2c063f('0x1564')])['join'](',');}break;case _0x2c063f('0x1db1'):{const _0xeeb2e1=_0x449a5a[_0x2c063f('0x24f2')]['appdata'][_0x2c063f('0x1fc5')](',');_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x7ae')]=_0xeeb2e1[0x0],_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x204a')]=_0xeeb2e1[0x1],_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x5ba')]=_0xeeb2e1[0x2],_0x449a5a[_0x2c063f('0x24f2')]['botname']=_0xeeb2e1[0x3],_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x6d9')]=_0xeeb2e1[_0x2c063f('0x12c8')](0x4,_0xeeb2e1[_0x2c063f('0x1564')])[_0x2c063f('0x1630')](',');}break;case _0x2c063f('0x2408'):{const _0xbcff30=_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x1407')][_0x2c063f('0x1fc5')](',');_0x449a5a['system'][_0x2c063f('0x35')]=isNaN(_0xbcff30[0x0])?_0xbcff30[0x0]:parseInt(_0xbcff30[0x0],0xa),_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x1bcd')]=_0xbcff30[_0x2c063f('0x12c8')](0x1,_0xbcff30[_0x2c063f('0x1564')])[_0x2c063f('0x1630')](',');}break;case _0x2c063f('0x8c2'):_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x1bcd')]=_0x449a5a['system'][_0x2c063f('0x1407')];break;case _0x2c063f('0x877'):_0x449a5a['system'][_0x2c063f('0x60a')]=_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x1407')]['split']('=')[0x0],_0x449a5a[_0x2c063f('0x24f2')]['value']=_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x1407')]['split']('=')[0x1];break;case _0x2c063f('0x19ae'):_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x273a')]=_0x449a5a[_0x2c063f('0x24f2')]['appdata'];break;default:{const _0x55e54b=_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x1407')][_0x2c063f('0x1fc5')](',');_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x6db')]=_0x2e3ca0()[_0x2c063f('0x173f')](_0x55e54b[0x0])?_0x55e54b[0x0]:isNaN(_0x55e54b[0x0])?_0x55e54b[0x0]:parseInt(_0x55e54b[0x0],0xa),_0x449a5a[_0x2c063f('0x24f2')]['variable']=_0x2e3ca0()[_0x2c063f('0x173f')](_0x55e54b[0x1])?_0x55e54b[0x1]:isNaN(_0x55e54b[0x1])?_0x55e54b[0x1]:parseInt(_0x55e54b[0x1],0xa);}break;}else _0x449a5a['system'][_0x2c063f('0x26e0')]='';_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0xcf0')]&&_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0xcf0')][_0x2c063f('0x93a')]()===_0x2c063f('0x17cd')&&_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x11f3')][_0x2c063f('0x93a')]()==='outbounddial'&&(_0x449a5a['system']['prefix']=_0x449a5a[_0x2c063f('0x24f2')]['phone']?_0x449a5a[_0x2c063f('0x24f2')]['phone'][_0x2c063f('0x1fc5')]('$')[0x0]:undefined,_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0xabd')]=_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x73c')]?_0x2c063f('0xac1')+_0x449a5a[_0x2c063f('0x24f2')][_0x2c063f('0x73c')]:undefined);_0x449a5a[_0x2c063f('0x25eb')]=_0x4ae5b2,_0x449a5a[_0x2c063f('0xf82')]=_0x1f2747,_0x3c36f4[_0x2c063f('0xca1')](_0x2c063f('0x20c2'))?_0x448932[_0x2c063f('0x26e0')][_0x2c063f('0x1e6e')]({'fields':_0x2c063f('0xa10'),'sort':_0x2c063f('0x60a'),'nolimit':_0x2c063f('0x26ac')})[_0x2c063f('0xe53')][_0x2c063f('0x683')](function(_0x228a63){const _0x528601=_0x2c063f;_0x449a5a['variables']=_0x228a63[_0x528601('0xf5d')]||[];})[_0x2c063f('0x130a')](function(_0x2e3efd){const _0x420dba=_0x2c063f;_0x2baa75[_0x420dba('0x52a')]({'title':_0x2e3efd[_0x420dba('0x13ee')]?_0x420dba('0x2168')+_0x2e3efd['status']+_0x420dba('0xbf6')+_0x2e3efd[_0x420dba('0x24a9')]:_0x420dba('0x9a9'),'msg':_0x2e3efd[_0x420dba('0x5a5')]?JSON[_0x420dba('0x258a')](_0x2e3efd[_0x420dba('0x5a5')]):_0x2e3efd[_0x420dba('0x1ff0')]()});}):_0x448932[_0x2c063f('0x26e0')][_0x2c063f('0x1e6e')]({'fields':_0x2c063f('0xa10'),'sort':_0x2c063f('0x60a'),'nolimit':_0x2c063f('0x26ac')})[_0x2c063f('0xe53')][_0x2c063f('0x683')](function(_0x2743e7){const _0x10649b=_0x2c063f;_0x449a5a[_0x10649b('0x220b')]=_0x2743e7[_0x10649b('0xf5d')]||[];})[_0x2c063f('0x683')](function(){const _0x2f9051=_0x2c063f;return _0x448932[_0x2f9051('0x22df')]['get']({'userProfileId':_0x449a5a[_0x2f9051('0x11ed')][_0x2f9051('0x2f')],'sectionId':0x3f4})[_0x2f9051('0xe53')];})[_0x2c063f('0x683')](function(_0x53c323){const _0x5d3081=_0x2c063f,_0x2cc9fc=_0x53c323&&_0x53c323['rows']?_0x53c323['rows'][0x0]:null;if(!_0x2cc9fc){const _0xdd860c=[];let _0x34e5fb=null;_0x449a5a['system']&&(_0x34e5fb=_0x2e3ca0()[_0x5d3081('0x1c07')](_0x449a5a['variables'],{'name':_0x449a5a[_0x5d3081('0x24f2')][_0x5d3081('0x26e0')]}));for(let _0xefd084=0x0;_0xefd084<_0x449a5a[_0x5d3081('0x220b')][_0x5d3081('0x1564')];_0xefd084++){_0x34e5fb&&_0x449a5a[_0x5d3081('0x220b')][_0xefd084]['id']===_0x34e5fb['id']&&(_0x449a5a[_0x5d3081('0x220b')][_0xefd084]['canSelect']=![],_0xdd860c[_0x5d3081('0x1fd0')](_0x449a5a['variables'][_0xefd084]));}_0x449a5a['variables']=_0xdd860c;}else{if(!_0x2cc9fc[_0x5d3081('0x170')])return _0x448932[_0x5d3081('0xcf7')]['get']({'sectionId':_0x2cc9fc['id']})[_0x5d3081('0xe53')]['then'](function(_0x404977){const _0x5c80a1=_0x5d3081,_0x6f9bbc=_0x2e3ca0()[_0x5c80a1('0x386')](_0x404977[_0x5c80a1('0xf5d')],function(_0x2b4749){const _0x42ac5f=_0x5c80a1;return _0x2e3ca0()['find'](_0x449a5a[_0x42ac5f('0x220b')],{'id':_0x2b4749[_0x42ac5f('0x832')]});});let _0x16c6c3=null;_0x449a5a['system']&&(_0x16c6c3=_0x2e3ca0()[_0x5c80a1('0x1c07')](_0x449a5a['variables'],{'name':_0x449a5a[_0x5c80a1('0x24f2')][_0x5c80a1('0x26e0')]}));if(_0x16c6c3&&!_0x2e3ca0()['some'](_0x6f9bbc,['id',_0x16c6c3['id']])){const _0x13089c=_0x2e3ca0()['find'](_0x449a5a[_0x5c80a1('0x220b')],{'id':_0x16c6c3['id']});_0x13089c['canSelect']=![],_0x6f9bbc['push'](_0x13089c);}_0x449a5a[_0x5c80a1('0x220b')]=_0x6f9bbc;});}})['catch'](function(_0x191379){const _0x47b34a=_0x2c063f;_0x2baa75[_0x47b34a('0x52a')]({'title':_0x191379[_0x47b34a('0x13ee')]?_0x47b34a('0x2168')+_0x191379[_0x47b34a('0x13ee')]+_0x47b34a('0xbf6')+_0x191379[_0x47b34a('0x24a9')]:_0x47b34a('0x392'),'msg':_0x191379[_0x47b34a('0x5a5')]?JSON[_0x47b34a('0x258a')](_0x191379[_0x47b34a('0x5a5')]):_0x191379['toString']()});});function _0x4ae5b2(){const _0x2e670e=_0x2c063f;_0x449a5a[_0x2e670e('0x17f')]=[];const _0x1a2639=[];_0x449a5a['system'][_0x2e670e('0xcf0')]&&_0x449a5a[_0x2e670e('0x24f2')][_0x2e670e('0xcf0')][_0x2e670e('0x93a')]()==='outbound'&&_0x449a5a[_0x2e670e('0x24f2')][_0x2e670e('0x11f3')]==='outboundDial'&&(_0x449a5a[_0x2e670e('0x24f2')][_0x2e670e('0xd31')]=_0x4ea370['cutdigits']?(_0x449a5a[_0x2e670e('0x24f2')]['prefix']||'')+_0x2e670e('0x249e')+_0x4ea370[_0x2e670e('0x145a')]+'}':(_0x449a5a[_0x2e670e('0x24f2')]['prefix']||'')+_0x2e670e('0x20cb'),_0x4ea370[_0x2e670e('0x75b')]!=='none'?_0x449a5a['system']['options'][_0x2e670e('0x824')](_0x2e670e('0x1b1'))<0x0&&(_0x449a5a[_0x2e670e('0x24f2')][_0x2e670e('0x158e')]+=_0x2e670e('0x1b1')):_0x449a5a[_0x2e670e('0x24f2')]['options']=_0x449a5a[_0x2e670e('0x24f2')][_0x2e670e('0x158e')]['replace'](_0x2e670e('0x1b1'),''));if(_0x449a5a[_0x2e670e('0x24f2')][_0x2e670e('0x11f3')]&&_0x449a5a['system'][_0x2e670e('0x11f3')]==='custom'){}else switch((_0x449a5a[_0x2e670e('0x24f2')][_0x2e670e('0x1d75')]||_0x449a5a['system'][_0x2e670e('0x11f3')])[_0x2e670e('0x93a')]()){case _0x2e670e('0x877'):_0x449a5a['system'][_0x2e670e('0x1407')]=_0x449a5a[_0x2e670e('0x24f2')]['name']+'='+_0x449a5a[_0x2e670e('0x24f2')]['value'];break;case _0x2e670e('0xbf0'):break;default:_0x1a2639[0x0]=_0x449a5a[_0x2e670e('0x24f2')][_0x2e670e('0x6db')],_0x1a2639[0x1]=_0x449a5a[_0x2e670e('0x24f2')]['variable'],_0x449a5a[_0x2e670e('0x24f2')][_0x2e670e('0x1407')]=_0x1a2639[_0x2e670e('0x1630')](',');}_0x1f2747(_0x449a5a[_0x2e670e('0x24f2')]);}function _0x1f2747(_0xa20265){const _0x128bc0=_0x2c063f;_0x383b0a[_0x128bc0('0x1715')](_0xa20265);}}const _0x5c93e2=_0x258ffa;_0x32332e[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'chatWebsiteApp',_0x189033('0x2681'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x32332e(_0x75dbd2,_0x1e8de6,_0x39c485,_0x3d3443,_0x367fb1,_0xdb1b0f,_0x332970,_0x5d7834){const _0x145270=_0x189033,_0x553c10=this;_0x553c10[_0x145270('0x11ed')]=_0x332970[_0x145270('0x20b2')](),_0x553c10[_0x145270('0x17f')]=[],_0x553c10['title']=_0x145270('0x1c66')+(_0x3d3443['appType']||_0x3d3443[_0x145270('0x1d75')])[_0x145270('0x80')](),_0x553c10[_0x145270('0x270')]=angular[_0x145270('0x1a86')](_0x3d3443),_0x553c10[_0x145270('0x1134')]=_0x5d7834,_0x553c10['hasModulePermissions']={};if(_0x553c10[_0x145270('0x270')][_0x145270('0x1407')])switch(_0x553c10['tag'][_0x145270('0x11f3')]?_0x553c10[_0x145270('0x270')]['appType'][_0x145270('0x93a')]():_0x553c10[_0x145270('0x270')][_0x145270('0x1d75')][_0x145270('0x93a')]()){case _0x145270('0xbf0'):break;case _0x145270('0x205c'):{const _0x3600b2=_0x553c10[_0x145270('0x270')]['appdata']['split'](',');_0x553c10['tag']['key']=_0x3600b2[0x0],_0x553c10[_0x145270('0x270')][_0x145270('0x1a1c')]=_0x3600b2[0x1],_0x553c10[_0x145270('0x270')][_0x145270('0x6d9')]=_0x3600b2[_0x145270('0x12c8')](0x2,_0x3600b2[_0x145270('0x1564')])['join'](',');}break;case _0x145270('0xd24'):{const _0x21f3cc=_0x553c10[_0x145270('0x270')][_0x145270('0x1407')][_0x145270('0x1fc5')](',');_0x553c10[_0x145270('0x270')][_0x145270('0x2119')]=_0x21f3cc[0x0],_0x553c10[_0x145270('0x270')]['clientEmail']=_0x21f3cc[0x1],_0x553c10[_0x145270('0x270')][_0x145270('0x406')]=_0x21f3cc[0x2],_0x553c10[_0x145270('0x270')]['language']=_0x21f3cc[0x3],_0x553c10['tag'][_0x145270('0x6d9')]=_0x21f3cc[_0x145270('0x12c8')](0x4,_0x21f3cc[_0x145270('0x1564')])['join'](',');}break;case _0x145270('0x1db1'):{const _0xcff492=_0x553c10[_0x145270('0x270')][_0x145270('0x1407')]['split'](',');_0x553c10[_0x145270('0x270')][_0x145270('0x7ae')]=_0xcff492[0x0],_0x553c10[_0x145270('0x270')][_0x145270('0x204a')]=_0xcff492[0x1],_0x553c10[_0x145270('0x270')][_0x145270('0x5ba')]=_0xcff492[0x2],_0x553c10['tag'][_0x145270('0x11a9')]=_0xcff492[0x3],_0x553c10[_0x145270('0x270')][_0x145270('0x6d9')]=_0xcff492[_0x145270('0x12c8')](0x4,_0xcff492[_0x145270('0x1564')])[_0x145270('0x1630')](',');}break;case _0x145270('0x2408'):{const _0x42f308=_0x553c10[_0x145270('0x270')]['appdata'][_0x145270('0x1fc5')](',');_0x553c10[_0x145270('0x270')][_0x145270('0x35')]=isNaN(_0x42f308[0x0])?_0x42f308[0x0]:parseInt(_0x42f308[0x0],0xa),_0x553c10[_0x145270('0x270')][_0x145270('0x1bcd')]=_0x42f308['slice'](0x1,_0x42f308[_0x145270('0x1564')])[_0x145270('0x1630')](',');}break;case _0x145270('0x8c2'):_0x553c10['tag'][_0x145270('0x1bcd')]=_0x553c10[_0x145270('0x270')]['appdata'];break;case _0x145270('0x877'):_0x553c10[_0x145270('0x270')][_0x145270('0x60a')]=_0x553c10['tag'][_0x145270('0x1407')][_0x145270('0x1fc5')]('=')[0x0],_0x553c10[_0x145270('0x270')][_0x145270('0x1c6b')]=_0x553c10['tag'][_0x145270('0x1407')][_0x145270('0x1fc5')]('=')[0x1];break;case'agi':_0x553c10[_0x145270('0x270')][_0x145270('0x273a')]=_0x553c10['tag']['appdata'];break;default:{const _0x3a0f11=_0x553c10[_0x145270('0x270')][_0x145270('0x1407')][_0x145270('0x1fc5')](',');_0x553c10[_0x145270('0x270')][_0x145270('0x270')]=_0x2e3ca0()[_0x145270('0x173f')](_0x3a0f11[0x0])?_0x3a0f11[0x0]:isNaN(_0x3a0f11[0x0])?_0x3a0f11[0x0]:parseInt(_0x3a0f11[0x0],0xa);}break;}else{}_0x553c10['tag'][_0x145270('0xcf0')]&&_0x553c10['tag'][_0x145270('0xcf0')][_0x145270('0x93a')]()==='outbound'&&_0x553c10[_0x145270('0x270')]['appType'][_0x145270('0x93a')]()==='outbounddial'&&(_0x553c10['tag'][_0x145270('0x24fa')]=_0x553c10[_0x145270('0x270')]['phone']?_0x553c10['tag'][_0x145270('0xd31')]['split']('$')[0x0]:undefined,_0x553c10[_0x145270('0x270')][_0x145270('0xabd')]=_0x553c10[_0x145270('0x270')][_0x145270('0x73c')]?_0x145270('0xac1')+_0x553c10[_0x145270('0x270')]['callerID']:undefined);_0x553c10[_0x145270('0x25eb')]=_0x2adb3b,_0x553c10['closeDialog']=_0x307ea2,_0x332970[_0x145270('0xca1')](_0x145270('0x20c2'))?_0xdb1b0f[_0x145270('0x270')][_0x145270('0x1e6e')]({'fields':_0x145270('0xa10'),'sort':_0x145270('0x60a'),'nolimit':_0x145270('0x26ac')})[_0x145270('0xe53')][_0x145270('0x683')](function(_0x1e2aed){const _0x254bc2=_0x145270;_0x553c10[_0x254bc2('0x1ce6')]=_0x1e2aed[_0x254bc2('0xf5d')]||[];})[_0x145270('0x130a')](function(_0x504caf){const _0x4e1ec8=_0x145270;_0x39c485['error']({'title':_0x504caf['status']?'API:'+_0x504caf[_0x4e1ec8('0x13ee')]+_0x4e1ec8('0xbf6')+_0x504caf[_0x4e1ec8('0x24a9')]:'SYSTEM:GET_TAGS','msg':_0x504caf[_0x4e1ec8('0x5a5')]?JSON[_0x4e1ec8('0x258a')](_0x504caf[_0x4e1ec8('0x5a5')]):_0x504caf[_0x4e1ec8('0x1ff0')]()});}):_0xdb1b0f[_0x145270('0x270')]['get']({'fields':_0x145270('0xa10'),'sort':_0x145270('0x60a'),'nolimit':_0x145270('0x26ac')})['$promise'][_0x145270('0x683')](function(_0x37dd2b){const _0x534b2e=_0x145270;_0x553c10[_0x534b2e('0x1ce6')]=_0x37dd2b[_0x534b2e('0xf5d')]||[];})['then'](function(){const _0x136b37=_0x145270;return _0xdb1b0f[_0x136b37('0x22df')]['get']({'userProfileId':_0x553c10[_0x136b37('0x11ed')][_0x136b37('0x2f')],'sectionId':0x3f0})['$promise'];})[_0x145270('0x683')](function(_0x44e44a){const _0x1c4618=_0x145270,_0x511137=_0x44e44a&&_0x44e44a[_0x1c4618('0xf5d')]?_0x44e44a[_0x1c4618('0xf5d')][0x0]:null;if(!_0x511137){const _0x3dae3a=[];let _0x4df9ce=null;_0x553c10[_0x1c4618('0x270')]&&(_0x4df9ce=_0x2e3ca0()['find'](_0x553c10['tags'],{'name':_0x553c10[_0x1c4618('0x270')][_0x1c4618('0x270')]}));for(let _0x3e26c3=0x0;_0x3e26c3<_0x553c10['tags'][_0x1c4618('0x1564')];_0x3e26c3++){_0x4df9ce&&_0x553c10[_0x1c4618('0x1ce6')][_0x3e26c3]['id']===_0x4df9ce['id']&&(_0x553c10[_0x1c4618('0x1ce6')][_0x3e26c3]['canSelect']=![],_0x3dae3a['push'](_0x553c10[_0x1c4618('0x1ce6')][_0x3e26c3]));}_0x553c10['tags']=_0x3dae3a;}else{if(!_0x511137['autoAssociation'])return _0xdb1b0f[_0x1c4618('0xcf7')][_0x1c4618('0x1e6e')]({'sectionId':_0x511137['id']})['$promise'][_0x1c4618('0x683')](function(_0xf20c60){const _0x1e9b6f=_0x1c4618,_0x49aff4=_0x2e3ca0()[_0x1e9b6f('0x386')](_0xf20c60[_0x1e9b6f('0xf5d')],function(_0xb8765c){const _0x5bbe33=_0x1e9b6f;return _0x2e3ca0()[_0x5bbe33('0x1c07')](_0x553c10[_0x5bbe33('0x1ce6')],{'id':_0xb8765c[_0x5bbe33('0x832')]});});let _0x2f2c81=null;_0x553c10[_0x1e9b6f('0x270')]&&(_0x2f2c81=_0x2e3ca0()[_0x1e9b6f('0x1c07')](_0x553c10[_0x1e9b6f('0x1ce6')],{'name':_0x553c10[_0x1e9b6f('0x270')][_0x1e9b6f('0x270')]}));if(_0x2f2c81&&!_0x2e3ca0()[_0x1e9b6f('0x7a2')](_0x49aff4,['id',_0x2f2c81['id']])){const _0x392e88=_0x2e3ca0()[_0x1e9b6f('0x1c07')](_0x553c10[_0x1e9b6f('0x1ce6')],{'id':_0x2f2c81['id']});_0x392e88[_0x1e9b6f('0x319')]=![],_0x49aff4['push'](_0x392e88);}_0x553c10[_0x1e9b6f('0x1ce6')]=_0x49aff4;});}})['catch'](function(_0xc72bf7){const _0x373470=_0x145270;_0x39c485[_0x373470('0x52a')]({'title':_0xc72bf7[_0x373470('0x13ee')]?_0x373470('0x2168')+_0xc72bf7[_0x373470('0x13ee')]+_0x373470('0xbf6')+_0xc72bf7[_0x373470('0x24a9')]:'SYSTEM:GETtags','msg':_0xc72bf7[_0x373470('0x5a5')]?JSON[_0x373470('0x258a')](_0xc72bf7['data']):_0xc72bf7['toString']()});});function _0x2adb3b(){const _0x144d20=_0x145270;_0x553c10[_0x144d20('0x17f')]=[];const _0x2b33cc=[];_0x553c10[_0x144d20('0x270')][_0x144d20('0xcf0')]&&_0x553c10['tag'][_0x144d20('0xcf0')][_0x144d20('0x93a')]()===_0x144d20('0x17cd')&&_0x553c10[_0x144d20('0x270')][_0x144d20('0x11f3')]===_0x144d20('0x4d2')&&(_0x553c10['tag']['phone']=_0x367fb1[_0x144d20('0x145a')]?(_0x553c10[_0x144d20('0x270')][_0x144d20('0x24fa')]||'')+_0x144d20('0x249e')+_0x367fb1['cutdigits']+'}':(_0x553c10[_0x144d20('0x270')][_0x144d20('0x24fa')]||'')+_0x144d20('0x20cb'),_0x367fb1[_0x144d20('0x75b')]!==_0x144d20('0x925')?_0x553c10[_0x144d20('0x270')][_0x144d20('0x158e')][_0x144d20('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x553c10[_0x144d20('0x270')][_0x144d20('0x158e')]+='U(xcally-mixmonitor-context)'):_0x553c10[_0x144d20('0x270')][_0x144d20('0x158e')]=_0x553c10[_0x144d20('0x270')]['options'][_0x144d20('0x1725')](_0x144d20('0x1b1'),''));const _0x254a86=_0x2e3ca0()['find'](_0x553c10[_0x144d20('0x1ce6')],{'name':_0x553c10[_0x144d20('0x270')][_0x144d20('0x270')]});_0x254a86&&(_0x553c10[_0x144d20('0x270')][_0x144d20('0xb6d')]=_0x254a86['id']);if(_0x553c10['tag'][_0x144d20('0x11f3')]&&_0x553c10[_0x144d20('0x270')][_0x144d20('0x11f3')]==='custom'){}else switch((_0x553c10['tag']['app']||_0x553c10[_0x144d20('0x270')]['appType'])[_0x144d20('0x93a')]()){case'set':_0x553c10[_0x144d20('0x270')]['appdata']=_0x553c10[_0x144d20('0x270')][_0x144d20('0x60a')]+'='+_0x553c10['tag'][_0x144d20('0x1c6b')];break;case _0x144d20('0xbf0'):break;default:_0x2b33cc[0x0]=_0x553c10['tag']['tag'],_0x553c10['tag'][_0x144d20('0x1407')]=_0x2b33cc['join'](',');}_0x307ea2(_0x553c10[_0x144d20('0x270')]);}function _0x307ea2(_0x1658cd){_0x75dbd2['hide'](_0x1658cd);}}const _0x318c2e=_0x32332e,_0xa71522=_0x180212['p']+_0x189033('0x1a16');_0x4bbd70[_0x189033('0x14be')]=[_0x189033('0x17e4'),'$scope',_0x189033('0x938'),'$q',_0x189033('0x1d08'),'$timeout',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),'Auth'];function _0x4bbd70(_0x1d5c9b,_0x163261,_0x50d248,_0x386d19,_0x520d3b,_0x2887e9,_0x46376b,_0x1e7133,_0x4a1c1c,_0xa5dc26,_0x33ebff){const _0x43f580=_0x189033,_0x3e562c=this;_0x3e562c['currentUser']=_0x33ebff['getCurrentUser'](),_0x3e562c[_0x43f580('0x2681')]={},_0x3e562c['chatWebsiteChatCannedAnswers']={'count':0x0,'rows':[]},_0x3e562c['selectedChatWebsiteChatCannedAnswers']=[],_0x3e562c[_0x43f580('0x1134')],_0x3e562c[_0x43f580('0x23a2')]={'fields':_0x43f580('0x8ee'),'limit':0xa,'page':0x1},_0x3e562c[_0x43f580('0x12f3')]=_0x345cdd,_0x3e562c[_0x43f580('0x26eb')]=_0xdf0587,_0x3e562c[_0x43f580('0x53')]=_0x60fa0e,_0x3e562c[_0x43f580('0x2145')]=_0x56f3c2,_0x3e562c[_0x43f580('0x7a3')]=_0x399b7d,_0x3e562c[_0x43f580('0x12fd')]=_0x1b9ee2,_0x3e562c[_0x43f580('0x262')]=_0x1ec038,_0x3e562c[_0x43f580('0x15ee')]=_0x24ecd0;function _0x345cdd(_0x996906,_0x410a82){const _0x323f21=_0x43f580;_0x3e562c[_0x323f21('0x2681')]=_0x996906,_0x3e562c[_0x323f21('0x1134')]=typeof _0x410a82!==_0x323f21('0x1867')?_0x410a82:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3e562c[_0x323f21('0x23a2')][_0x323f21('0x15a5')]=_0x3e562c['chatWebsite']['id'],_0x3e562c[_0x323f21('0x23a2')]['id']=_0x3e562c[_0x323f21('0x2681')]['id'],_0x56f3c2();}function _0xdf0587(_0x1c5c38,_0x46c21e){const _0x26afd0=_0x43f580,_0x17834b=_0x46376b[_0x26afd0('0x1c6f')]()['title'](_0x26afd0('0x21e2'))[_0x26afd0('0x26e3')](_0x26afd0('0xed5')+(_0x1c5c38[_0x26afd0('0x60a')]||_0x1c5c38['id']&&_0x2e3ca0()[_0x26afd0('0x2711')](_0x26afd0('0x2717'))+_0x1c5c38['id']||_0x26afd0('0x135f'))+_0x26afd0('0x20f1')+_0x26afd0('0x1ee7'))[_0x26afd0('0x1040')](_0x26afd0('0x1a8d'))[_0x26afd0('0xe42')](_0x46c21e)['ok']('OK')[_0x26afd0('0x19fb')](_0x26afd0('0x16b8'));_0x46376b['show'](_0x17834b)['then'](function(){_0x1ec038(_0x1c5c38);},function(){const _0x491eda=_0x26afd0;console[_0x491eda('0x1b2b')](_0x491eda('0x16b8'));});}function _0x60fa0e(_0xd889df){_0x3e562c['chatWebsiteChatCannedAnswers']=_0xd889df||{'count':0x0,'rows':[]};}function _0x56f3c2(){const _0xcaffc2=_0x43f580;_0x3e562c[_0xcaffc2('0x23a2')][_0xcaffc2('0x1cc8')]=(_0x3e562c[_0xcaffc2('0x23a2')][_0xcaffc2('0xdf8')]-0x1)*_0x3e562c[_0xcaffc2('0x23a2')]['limit'],_0x3e562c[_0xcaffc2('0x1883')]=_0xa5dc26[_0xcaffc2('0x2681')][_0xcaffc2('0x87f')](_0x3e562c['query'],_0x60fa0e)[_0xcaffc2('0xe53')];}function _0x399b7d(_0x7bbbd5,_0x575fb7){const _0x13604f=_0x43f580;_0x46376b['show']({'controller':_0x13604f('0x7d3'),'controllerAs':'vm','templateUrl':_0xa71522,'parent':angular[_0x13604f('0x1fcc')](_0x1e7133[_0x13604f('0x18e5')]),'targetEvent':_0x7bbbd5,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x3e562c[_0x13604f('0x2681')],'chatCannedAnswer':_0x575fb7,'chatCannedAnswers':_0x3e562c[_0x13604f('0xb4d')][_0x13604f('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x3e562c[_0x13604f('0x1134')]}});}function _0x1ec038(_0x8d54dd){const _0x55ce42=_0x43f580;_0xa5dc26[_0x55ce42('0x136c')][_0x55ce42('0xd7e')]({'id':_0x8d54dd['id']})[_0x55ce42('0xe53')][_0x55ce42('0x683')](function(){const _0xc4c5e2=_0x55ce42;_0x2e3ca0()['remove'](_0x3e562c[_0xc4c5e2('0xb4d')][_0xc4c5e2('0xf5d')],{'id':_0x8d54dd['id']}),_0x3e562c[_0xc4c5e2('0xb4d')][_0xc4c5e2('0x50d')]-=0x1,!_0x3e562c[_0xc4c5e2('0xb4d')][_0xc4c5e2('0xf5d')][_0xc4c5e2('0x1564')]&&_0x56f3c2(),_0x4a1c1c[_0xc4c5e2('0x53')]({'title':'ChatCannedAnswer\x20deleted!','msg':_0x8d54dd[_0xc4c5e2('0x60a')]?_0x8d54dd['name']+_0xc4c5e2('0x194d'):''});})[_0x55ce42('0x130a')](function(_0x3443e4){const _0x42b2ed=_0x55ce42;if(_0x3443e4['data']&&_0x3443e4[_0x42b2ed('0x5a5')][_0x42b2ed('0x17f')]&&_0x3443e4[_0x42b2ed('0x5a5')][_0x42b2ed('0x17f')][_0x42b2ed('0x1564')]){_0x3e562c[_0x42b2ed('0x17f')]=_0x3443e4[_0x42b2ed('0x5a5')]['errors']||[{'message':_0x3443e4[_0x42b2ed('0x1ff0')](),'type':_0x42b2ed('0xd27')}];for(let _0x67b4a=0x0;_0x67b4a<_0x3443e4[_0x42b2ed('0x5a5')][_0x42b2ed('0x17f')][_0x42b2ed('0x1564')];_0x67b4a++){_0x4a1c1c[_0x42b2ed('0x52a')]({'title':_0x3443e4[_0x42b2ed('0x5a5')][_0x42b2ed('0x17f')][_0x67b4a][_0x42b2ed('0xcf0')],'msg':_0x3443e4[_0x42b2ed('0x5a5')][_0x42b2ed('0x17f')][_0x67b4a]['message']});}}else _0x4a1c1c[_0x42b2ed('0x52a')]({'title':_0x3443e4[_0x42b2ed('0x13ee')]?'API:'+_0x3443e4[_0x42b2ed('0x13ee')]+'\x20-\x20'+_0x3443e4[_0x42b2ed('0x24a9')]:_0x42b2ed('0xd27'),'msg':_0x3443e4['data']?JSON[_0x42b2ed('0x258a')](_0x3443e4[_0x42b2ed('0x5a5')][_0x42b2ed('0x8c2')]):_0x3443e4[_0x42b2ed('0x8c2')]||_0x3443e4[_0x42b2ed('0x1ff0')]()});});}function _0x1b9ee2(){const _0x220364=_0x43f580,_0x59be6=angular[_0x220364('0x1a86')](_0x3e562c[_0x220364('0x7b0')]);return _0x3e562c[_0x220364('0x7b0')]=[],_0x59be6;}function _0x24ecd0(_0xe3352b){const _0x17c076=_0x43f580,_0x2146d0=_0x46376b[_0x17c076('0x1c6f')]()[_0x17c076('0xf28')](_0x17c076('0x796'))['htmlContent'](_0x17c076('0xed5')+_0x3e562c[_0x17c076('0x7b0')][_0x17c076('0x1564')]+_0x17c076('0x93c')+_0x17c076('0x1ee7'))[_0x17c076('0x1040')](_0x17c076('0x1305'))[_0x17c076('0xe42')](_0xe3352b)['ok']('OK')[_0x17c076('0x19fb')](_0x17c076('0x16b8'));_0x46376b[_0x17c076('0x1d4')](_0x2146d0)[_0x17c076('0x683')](function(){const _0xbcb4f9=_0x17c076;_0x3e562c[_0xbcb4f9('0x7b0')]['forEach'](function(_0x440b9e){_0x1ec038(_0x440b9e);}),_0x3e562c[_0xbcb4f9('0x7b0')]=[];});}let _0x45b293=!![],_0x130b61=0x1;_0x163261[_0x43f580('0x186d')]('vm_dc.query.filter',function(_0x2cfe6b,_0x32205a){const _0x519ef7=_0x43f580;_0x45b293?_0x2887e9(function(){_0x45b293=![];}):(!_0x32205a&&(_0x130b61=_0x3e562c[_0x519ef7('0x23a2')]['page']),_0x2cfe6b!==_0x32205a&&(_0x3e562c['query'][_0x519ef7('0xdf8')]=0x1),!_0x2cfe6b&&(_0x3e562c['query'][_0x519ef7('0xdf8')]=_0x130b61),_0x56f3c2());});}const _0x236b2f=_0x4bbd70;_0x126a03[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1882'),_0x189033('0x135f'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x126a03(_0x581a43,_0x3d9fd6,_0x7a51b6,_0x10d5d4,_0x57d865,_0xff9a25,_0x43adaa,_0xd9faed,_0x280802,_0x2b3297,_0x27c9e6,_0x37de61,_0x27693c,_0x2e5819){const _0x381a79=_0x189033,_0xad38da=this;_0xad38da['currentUser']=_0x27c9e6[_0x381a79('0x20b2')](),_0xad38da[_0x381a79('0x17f')]=[],_0xad38da[_0x381a79('0x260a')]=_0x27693c,_0xad38da['license']=_0x37de61,_0xad38da[_0x381a79('0x1134')]=_0x2e5819,_0xad38da[_0x381a79('0x258d')]={},_0xad38da[_0x381a79('0x19b2')]=_0xad38da[_0x381a79('0x260a')]&&_0xad38da['setting'][_0x381a79('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xad38da[_0x381a79('0xf28')]='CHAT.EDIT_CHATCANNEDANSWER',_0xad38da['chatCannedAnswer']=angular[_0x381a79('0x1a86')](_0x280802),_0xad38da[_0x381a79('0x1882')]=_0xd9faed,_0xad38da['newChatCannedAnswer']=![];!_0xad38da[_0x381a79('0x135f')]&&(_0xad38da[_0x381a79('0x135f')]={},_0xad38da[_0x381a79('0xf28')]=_0x381a79('0x1cc7'),_0xad38da['newChatCannedAnswer']=!![]);_0x3d9fd6['params']['id']&&(_0xad38da['chatCannedAnswer']['ChatWebsiteId']=_0x3d9fd6[_0x381a79('0x7f2')]['id']);_0xad38da[_0x381a79('0x2c3')]=_0x1d3a62,_0xad38da['saveChatCannedAnswer']=_0x499ef0,_0xad38da[_0x381a79('0x118f')]=_0x98b957,_0xad38da['getDateFromString']=_0x247eab,_0xad38da[_0x381a79('0xf82')]=_0x590773;function _0x1d3a62(){const _0xb92a49=_0x381a79;_0xad38da['errors']=[],_0x2b3297[_0xb92a49('0x136c')][_0xb92a49('0xb0a')](_0xad38da[_0xb92a49('0x135f')])[_0xb92a49('0xe53')][_0xb92a49('0x683')](function(_0x179b9e){const _0x5638f4=_0xb92a49;_0xad38da[_0x5638f4('0x1882')]['unshift'](_0x179b9e['toJSON']()),_0x43adaa[_0x5638f4('0x53')]({'title':_0x5638f4('0x2330'),'msg':_0xad38da[_0x5638f4('0x135f')][_0x5638f4('0x60a')]?_0xad38da[_0x5638f4('0x135f')]['name']+'\x20has\x20been\x20created!':''}),_0x590773(_0x179b9e);})[_0xb92a49('0x130a')](function(_0xf11c71){const _0x8a624d=_0xb92a49;if(_0xf11c71['data']&&_0xf11c71[_0x8a624d('0x5a5')]['errors']&&_0xf11c71[_0x8a624d('0x5a5')][_0x8a624d('0x17f')][_0x8a624d('0x1564')]){_0xad38da[_0x8a624d('0x17f')]=_0xf11c71['data']['errors']||[{'message':_0xf11c71[_0x8a624d('0x1ff0')](),'type':_0x8a624d('0x267b')}];for(let _0x59b2ff=0x0;_0x59b2ff<_0xf11c71[_0x8a624d('0x5a5')]['errors'][_0x8a624d('0x1564')];_0x59b2ff+=0x1){_0x43adaa[_0x8a624d('0x52a')]({'title':_0xf11c71[_0x8a624d('0x5a5')][_0x8a624d('0x17f')][_0x59b2ff][_0x8a624d('0xcf0')],'msg':_0xf11c71['data'][_0x8a624d('0x17f')][_0x59b2ff]['message']});}}else _0x43adaa[_0x8a624d('0x52a')]({'title':_0xf11c71[_0x8a624d('0x13ee')]?'API:'+_0xf11c71[_0x8a624d('0x13ee')]+'\x20-\x20'+_0xf11c71[_0x8a624d('0x24a9')]:_0x8a624d('0x267b'),'msg':_0xf11c71['data']?JSON[_0x8a624d('0x258a')](_0xf11c71['data'][_0x8a624d('0x8c2')]):_0xf11c71[_0x8a624d('0x1ff0')]()});});}function _0x499ef0(){const _0x1d88cb=_0x381a79;_0xad38da['errors']=[],_0x2b3297[_0x1d88cb('0x136c')]['update']({'id':_0xad38da[_0x1d88cb('0x135f')]['id']},_0xad38da[_0x1d88cb('0x135f')])['$promise'][_0x1d88cb('0x683')](function(_0x4f8dd0){const _0x379b53=_0x1d88cb,_0x3a345b=_0x2e3ca0()[_0x379b53('0x1c07')](_0xad38da[_0x379b53('0x1882')],{'id':_0x4f8dd0['id']});_0x3a345b&&_0x2e3ca0()[_0x379b53('0xf22')](_0x3a345b,_0x2e3ca0()[_0x379b53('0x24d0')](_0x4f8dd0[_0x379b53('0x24e1')](),_0x2e3ca0()['keys'](_0x3a345b))),_0x43adaa[_0x379b53('0x53')]({'title':_0x379b53('0x1ba'),'msg':_0xad38da[_0x379b53('0x135f')]['name']?_0xad38da[_0x379b53('0x135f')]['name']+'\x20has\x20been\x20saved!':''}),_0x590773(_0x4f8dd0);})[_0x1d88cb('0x130a')](function(_0x1c3e27){const _0x10e271=_0x1d88cb;if(_0x1c3e27['data']&&_0x1c3e27[_0x10e271('0x5a5')][_0x10e271('0x17f')]&&_0x1c3e27[_0x10e271('0x5a5')][_0x10e271('0x17f')][_0x10e271('0x1564')]){_0xad38da[_0x10e271('0x17f')]=_0x1c3e27[_0x10e271('0x5a5')][_0x10e271('0x17f')]||[{'message':_0x1c3e27[_0x10e271('0x1ff0')](),'type':_0x10e271('0x1301')}];for(let _0x80c78a=0x0;_0x80c78a<_0x1c3e27[_0x10e271('0x5a5')][_0x10e271('0x17f')][_0x10e271('0x1564')];_0x80c78a++){_0x43adaa[_0x10e271('0x52a')]({'title':_0x1c3e27['data'][_0x10e271('0x17f')][_0x80c78a][_0x10e271('0xcf0')],'msg':_0x1c3e27[_0x10e271('0x5a5')][_0x10e271('0x17f')][_0x80c78a][_0x10e271('0x8c2')]});}}else _0x43adaa[_0x10e271('0x52a')]({'title':_0x1c3e27[_0x10e271('0x13ee')]?_0x10e271('0x2168')+_0x1c3e27[_0x10e271('0x13ee')]+'\x20-\x20'+_0x1c3e27[_0x10e271('0x24a9')]:_0x10e271('0x1301'),'msg':_0x1c3e27[_0x10e271('0x5a5')]?JSON[_0x10e271('0x258a')](_0x1c3e27['data'][_0x10e271('0x8c2')]):_0x1c3e27[_0x10e271('0x1ff0')]()});});}function _0x98b957(_0x51e863){const _0x597c76=_0x381a79;_0xad38da[_0x597c76('0x17f')]=[];const _0x4af3f0=_0x10d5d4['confirm']()[_0x597c76('0xf28')](_0x597c76('0x4d'))['content'](_0x597c76('0x264c'))[_0x597c76('0x1040')](_0x597c76('0x124a'))['ok'](_0x597c76('0x2307'))['cancel'](_0x597c76('0x253a'))[_0x597c76('0xe42')](_0x51e863);_0x10d5d4['show'](_0x4af3f0)[_0x597c76('0x683')](function(){const _0x486556=_0x597c76;_0x2b3297[_0x486556('0x136c')][_0x486556('0xd7e')]({'id':_0xad38da['chatCannedAnswer']['id']})['$promise'][_0x486556('0x683')](function(){const _0xb54498=_0x486556;_0x2e3ca0()[_0xb54498('0x3ec')](_0xad38da['chatCannedAnswers'],{'id':_0xad38da[_0xb54498('0x135f')]['id']}),_0x43adaa[_0xb54498('0x53')]({'title':_0xb54498('0x74d'),'msg':(_0xad38da['chatCannedAnswer'][_0xb54498('0x60a')]||_0xb54498('0x135f'))+_0xb54498('0x194d')}),_0x590773(_0xad38da[_0xb54498('0x135f')]);})[_0x486556('0x130a')](function(_0x2d98ae){const _0x2b428f=_0x486556;if(_0x2d98ae[_0x2b428f('0x5a5')]&&_0x2d98ae[_0x2b428f('0x5a5')][_0x2b428f('0x17f')]&&_0x2d98ae[_0x2b428f('0x5a5')][_0x2b428f('0x17f')][_0x2b428f('0x1564')]){_0xad38da[_0x2b428f('0x17f')]=_0x2d98ae[_0x2b428f('0x5a5')][_0x2b428f('0x17f')]||[{'message':_0x2d98ae[_0x2b428f('0x1ff0')](),'type':_0x2b428f('0x253e')}];for(let _0x2ebd72=0x0;_0x2ebd72<_0x2d98ae[_0x2b428f('0x5a5')][_0x2b428f('0x17f')]['length'];_0x2ebd72++){_0x43adaa[_0x2b428f('0x52a')]({'title':_0x2d98ae[_0x2b428f('0x5a5')][_0x2b428f('0x17f')][_0x2ebd72][_0x2b428f('0xcf0')],'msg':_0x2d98ae[_0x2b428f('0x5a5')][_0x2b428f('0x17f')][_0x2ebd72][_0x2b428f('0x8c2')]});}}else _0x43adaa['error']({'title':_0x2d98ae[_0x2b428f('0x13ee')]?'API:'+_0x2d98ae[_0x2b428f('0x13ee')]+'\x20-\x20'+_0x2d98ae['statusText']:_0x2b428f('0x253e'),'msg':_0x2d98ae[_0x2b428f('0x5a5')]?JSON[_0x2b428f('0x258a')](_0x2d98ae[_0x2b428f('0x5a5')][_0x2b428f('0x8c2')]):_0x2d98ae[_0x2b428f('0x8c2')]||_0x2d98ae[_0x2b428f('0x1ff0')]()});});},function(){});}function _0x247eab(_0x461fa4){return _0x461fa4===null?undefined:new Date(_0x461fa4);}function _0x590773(_0x4ea4ed){_0x10d5d4['hide'](_0x4ea4ed);}}const _0x3ea1f1=_0x126a03;_0xa0f6dd['$inject']=['$scope',_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),'$translate',_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1')];function _0xa0f6dd(_0x15ac72,_0x2dc69d,_0xded184,_0x1fc527,_0xcba496,_0x4d5036,_0x5d6583,_0x8f9b27,_0x3cbce8,_0x466ab7,_0x27c3b3){const _0x51d94c=_0x189033,_0x163e06=this;_0x163e06[_0x51d94c('0x11ed')]=_0x27c3b3[_0x51d94c('0x20b2')](),_0x163e06[_0x51d94c('0x191e')]={'count':0x0,'rows':[]},_0x163e06[_0x51d94c('0x17')]=[],_0x163e06[_0x51d94c('0x1134')],_0x163e06[_0x51d94c('0x1d01')]={'first':_0x51d94c('0x1fd1'),'second':_0x51d94c('0x7c2'),'third':'3rd'},_0x163e06['query']={'fields':_0x51d94c('0xadb'),'sort':_0x51d94c('0xc36'),'limit':0xa,'page':0x1},_0x163e06['init']=_0x5493a4,_0x163e06['deleteConfirm']=_0x4acb1f,_0x163e06['success']=_0x410926,_0x163e06['getDispositions']=_0x482529,_0x163e06[_0x51d94c('0xe69')]=_0x434063,_0x163e06[_0x51d94c('0x207b')]=_0x231df7,_0x163e06[_0x51d94c('0x224b')]=_0x3da1e5,_0x163e06[_0x51d94c('0x238e')]=_0x10f68f,_0x163e06['deselectDispositions']=_0x710bdc,_0x163e06[_0x51d94c('0x1801')]=_0x3dd840;function _0x5493a4(_0x32ab1b,_0x26ee31){const _0x268e5d=_0x51d94c;_0x163e06[_0x268e5d('0x2681')]=_0x32ab1b||{},_0x163e06[_0x268e5d('0x1134')]=typeof _0x26ee31!==_0x268e5d('0x1867')?_0x26ee31:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x163e06[_0x268e5d('0x23a2')][_0x268e5d('0x15a5')]=_0x163e06['chatWebsite']['id'],_0x163e06[_0x268e5d('0x23a2')]['id']=_0x163e06[_0x268e5d('0x2681')]['id'],_0x482529();}function _0x434063(_0x1d4380,_0x7cb60b){const _0x3df2ac=_0x51d94c;_0xcba496[_0x3df2ac('0x1d4')]({'controller':_0x3df2ac('0x1ecc'),'controllerAs':'vm','templateUrl':_0x32807f,'parent':angular[_0x3df2ac('0x1fcc')](_0x4d5036[_0x3df2ac('0x18e5')]),'targetEvent':_0x1d4380,'clickOutsideToClose':!![],'locals':{'disposition':_0x7cb60b,'dispositions':_0x163e06['dispositions']['rows'],'model':{'id':_0x163e06['chatWebsite']['id'],'field':_0x3df2ac('0x15a5')},'license':null,'setting':null,'crudPermissions':_0x163e06[_0x3df2ac('0x1134')]}})[_0x3df2ac('0x683')](function(_0x13da87){if(_0x13da87)_0x482529();});}function _0x4acb1f(_0xb6a391,_0x576f22){const _0x3d6903=_0x51d94c,_0x4a9a4c=_0x2e3ca0()[_0x3d6903('0x7a2')](_0x163e06[_0x3d6903('0x191e')]['rows'],[_0x3d6903('0x1b62'),_0xb6a391['id']]),_0x242089=_0xcba496[_0x3d6903('0x1c6f')]()[_0x3d6903('0xf28')](_0x8f9b27[_0x3d6903('0x2728')](_0x3d6903('0x15d8')))['content'](_0x8f9b27[_0x3d6903('0x2728')]('TOOLS.NOTIFICATIONS.'+(_0x4a9a4c?_0x3d6903('0x2235'):_0x3d6903('0x106')),{'name':_0xb6a391[_0x3d6903('0x60a')]}))['ariaLabel'](_0x3d6903('0x550'))[_0x3d6903('0xe42')](_0x576f22)['ok']('OK')[_0x3d6903('0x19fb')](_0x8f9b27[_0x3d6903('0x2728')](_0x3d6903('0x9a1')));_0xcba496[_0x3d6903('0x1d4')](_0x242089)[_0x3d6903('0x683')](function(){_0x231df7(_0xb6a391);});}function _0x410926(_0x1d72b7){_0x163e06['dispositions']=_0x1d72b7||{'count':0x0,'rows':[]};}function _0x482529(){const _0x4637d2=_0x51d94c;_0x163e06['query'][_0x4637d2('0x1cc8')]=(_0x163e06['query'][_0x4637d2('0xdf8')]-0x1)*_0x163e06[_0x4637d2('0x23a2')][_0x4637d2('0x6f0')],_0x163e06['promise']=_0x3cbce8[_0x4637d2('0x2681')][_0x4637d2('0x13d9')](_0x163e06[_0x4637d2('0x23a2')],_0x410926)[_0x4637d2('0xe53')];}function _0x231df7(_0x279d95){const _0x518a99=_0x51d94c;_0x3cbce8['disposition'][_0x518a99('0xd7e')]({'id':_0x279d95['id']})[_0x518a99('0xe53')]['then'](function(){const _0x312f48=_0x518a99;_0x482529(),_0x466ab7[_0x312f48('0x53')]({'title':_0x8f9b27['instant'](_0x312f48('0x210b'))});})[_0x518a99('0x130a')](function(_0x2beb10){const _0x15ccc9=_0x518a99;if(_0x2beb10[_0x15ccc9('0x5a5')]&&_0x2beb10[_0x15ccc9('0x5a5')]['errors']&&_0x2beb10[_0x15ccc9('0x5a5')][_0x15ccc9('0x17f')][_0x15ccc9('0x1564')]){_0x163e06['errors']=_0x2beb10[_0x15ccc9('0x5a5')][_0x15ccc9('0x17f')]||[{'message':_0x2beb10[_0x15ccc9('0x1ff0')](),'type':_0x15ccc9('0x189b')}];for(let _0x5db59b=0x0;_0x5db59b<_0x2beb10[_0x15ccc9('0x5a5')][_0x15ccc9('0x17f')][_0x15ccc9('0x1564')];_0x5db59b++){_0x466ab7['error']({'title':_0x2beb10[_0x15ccc9('0x5a5')]['errors'][_0x5db59b]['type'],'msg':_0x2beb10[_0x15ccc9('0x5a5')][_0x15ccc9('0x17f')][_0x5db59b]['message']});}}else _0x466ab7[_0x15ccc9('0x52a')]({'title':_0x2beb10['status']?_0x15ccc9('0x2168')+_0x2beb10[_0x15ccc9('0x13ee')]+'\x20-\x20'+_0x2beb10[_0x15ccc9('0x24a9')]:_0x15ccc9('0x189b'),'msg':_0x2beb10['data']?JSON['stringify'](_0x2beb10[_0x15ccc9('0x5a5')][_0x15ccc9('0x8c2')]):_0x2beb10[_0x15ccc9('0x8c2')]||_0x2beb10[_0x15ccc9('0x1ff0')]()});});}function _0x3da1e5(){const _0x3a35b9=_0x51d94c,_0x4544af=angular['copy'](_0x163e06[_0x3a35b9('0x17')]);return _0x163e06[_0x3a35b9('0x17')]=[],_0x4544af;}function _0x10f68f(_0x3c377f){const _0x5beb6c=_0x51d94c,_0x26bc0d=_0xcba496[_0x5beb6c('0x1c6f')]()[_0x5beb6c('0xf28')](_0x8f9b27[_0x5beb6c('0x2728')](_0x5beb6c('0xfa')))[_0x5beb6c('0xa6a')](_0x8f9b27[_0x5beb6c('0x2728')](_0x5beb6c('0x1ebe'),{'total':_0x163e06[_0x5beb6c('0x17')][_0x5beb6c('0x1564')]}))[_0x5beb6c('0x1040')]('Delete\x20dispositions')[_0x5beb6c('0xe42')](_0x3c377f)['ok']('OK')[_0x5beb6c('0x19fb')](_0x8f9b27['instant'](_0x5beb6c('0x9a1')));_0xcba496['show'](_0x26bc0d)[_0x5beb6c('0x683')](function(){const _0x43f8a8=_0x5beb6c;_0x163e06[_0x43f8a8('0x17')][_0x43f8a8('0x1299')](function(_0x39a25a){_0x231df7(_0x39a25a);}),_0x163e06[_0x43f8a8('0x17')]=[];});}function _0x710bdc(){_0x163e06['selectedDispositions']=[];}function _0x3dd840(){const _0x325556=_0x51d94c;_0x163e06[_0x325556('0x17')]=_0x163e06[_0x325556('0x191e')][_0x325556('0xf5d')];}let _0x1b91a6=!![],_0x4de8a6=0x1;_0x15ac72[_0x51d94c('0x186d')](_0x51d94c('0x229'),function(_0x4e63a2,_0x2bd206){const _0x59e57e=_0x51d94c;_0x1b91a6?_0x5d6583(function(){_0x1b91a6=![];}):(!_0x2bd206&&(_0x4de8a6=_0x163e06[_0x59e57e('0x23a2')]['page']),_0x4e63a2!==_0x2bd206&&(_0x163e06[_0x59e57e('0x23a2')][_0x59e57e('0xdf8')]=0x1),!_0x4e63a2&&(_0x163e06[_0x59e57e('0x23a2')][_0x59e57e('0xdf8')]=_0x4de8a6),_0x482529());});}const _0x4f78ea=_0xa0f6dd;_0x3ff931[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x16ea'),'api'];function _0x3ff931(_0x41da7d,_0x2754be,_0x595daa){const _0x1e0859=_0x189033,_0x3e396d=this;_0x3e396d[_0x1e0859('0x2681')]={},_0x3e396d[_0x1e0859('0x1274')]={},_0x3e396d[_0x1e0859('0x143a')]=[{'type':_0x1e0859('0xfc9'),'name':_0x1e0859('0x2101'),'icon':_0x1e0859('0x24d6')},{'type':_0x1e0859('0x2511'),'name':_0x1e0859('0xaf7'),'icon':_0x1e0859('0x2f2')},{'type':_0x1e0859('0x1f1a'),'name':_0x1e0859('0x1b85'),'icon':_0x1e0859('0x3d8')},{'type':_0x1e0859('0x24be'),'name':_0x1e0859('0x21b3'),'icon':_0x1e0859('0xd8')},{'type':_0x1e0859('0xf51'),'name':_0x1e0859('0x54f'),'icon':_0x1e0859('0x24d7')},{'type':_0x1e0859('0x5d3'),'name':_0x1e0859('0x2614'),'icon':_0x1e0859('0x213a')},{'type':_0x1e0859('0x2188'),'name':_0x1e0859('0x78c'),'icon':_0x1e0859('0xac2')}],_0x3e396d[_0x1e0859('0x12f3')]=_0x103871,_0x3e396d['up']=_0x5bd3d4,_0x3e396d[_0x1e0859('0x2785')]=_0x2fea75,_0x3e396d[_0x1e0859('0x23c6')]=_0x1b2b15,_0x3e396d['remove']=_0x2969b1;function _0x103871(_0x380b1d){const _0x24e4dc=_0x1e0859;_0x3e396d[_0x24e4dc('0x189a')]=[],_0x3e396d[_0x24e4dc('0xc4d')]=[],_0x3e396d['uselessFields']=['id',_0x24e4dc('0x1a4'),_0x24e4dc('0x2000'),'ListId','CompanyId','$promise','$resolved'],_0x3e396d[_0x24e4dc('0x2681')]=_0x380b1d,_0x2e3ca0()[_0x24e4dc('0x173f')](_0x3e396d[_0x24e4dc('0x2681')][_0x24e4dc('0x1274')])&&(_0x3e396d['chatWebsite']['offlineForm']={'items':[],'fromKey':null}),_0x595daa[_0x24e4dc('0x259b')][_0x24e4dc('0xcb')]({'id':_0x3e396d['chatWebsite'][_0x24e4dc('0x1e4f')]})['$promise'][_0x24e4dc('0x683')](function(_0x278884){const _0x2705fc=_0x24e4dc;for(let _0x2657e3=0x0;_0x2657e3<_0x278884[_0x2705fc('0xf5d')][_0x2705fc('0x1564')];_0x2657e3++){_0x3e396d[_0x2705fc('0xc4d')][_0x2705fc('0x1fd0')]({'key':'cf_'+_0x278884[_0x2705fc('0xf5d')][_0x2657e3]['id'],'value':_0x278884[_0x2705fc('0xf5d')][_0x2657e3][_0x2705fc('0x64a')]});}return _0x595daa[_0x2705fc('0x276e')][_0x2705fc('0x2267')]()[_0x2705fc('0xe53')];})[_0x24e4dc('0x683')](function(_0x7a0b8f){const _0x38ba73=_0x24e4dc,_0x4291bf=_0x2e3ca0()[_0x38ba73('0x55e')](_0x7a0b8f);for(let _0x3ac88d=0x0;_0x3ac88d<_0x4291bf[_0x38ba73('0x1564')];_0x3ac88d++){!_0x2e3ca0()[_0x38ba73('0x2292')](_0x3e396d[_0x38ba73('0x26f')],_0x4291bf[_0x3ac88d])&&!_0x2e3ca0()[_0x38ba73('0x18ad')](_0x4291bf[_0x3ac88d],'cf_')&&_0x3e396d[_0x38ba73('0x189a')][_0x38ba73('0x1167')]({'key':_0x4291bf[_0x3ac88d],'value':_0x4291bf[_0x3ac88d]});}return _0x595daa['variable'][_0x38ba73('0x1e6e')]()['$promise'];})['then'](function(_0x566e5a){const _0xe7d0e4=_0x24e4dc;_0x3e396d[_0xe7d0e4('0x220b')]=_0x566e5a[_0xe7d0e4('0xf5d')];})[_0x24e4dc('0x130a')](function(_0x679fae){const _0x792dd2=_0x24e4dc;console[_0x792dd2('0x52a')](_0x679fae);});}function _0x5bd3d4(_0x275ada,_0x209fb6){const _0x1712ec=_0x1e0859;if(_0x209fb6!==0x0){const _0x4d4ff5=_0x3e396d[_0x1712ec('0x2681')][_0x1712ec('0x1274')][_0x1712ec('0x1996')][_0x209fb6-0x1];_0x3e396d[_0x1712ec('0x2681')][_0x1712ec('0x1274')][_0x1712ec('0x1996')][_0x209fb6]=_0x4d4ff5,_0x3e396d['chatWebsite'][_0x1712ec('0x1274')][_0x1712ec('0x1996')][_0x209fb6-0x1]=angular['copy'](_0x275ada);if(_0x3e396d['chatWebsite'][_0x1712ec('0x1274')]['fromKey']===_0x209fb6)_0x3e396d['chatWebsite'][_0x1712ec('0x1274')][_0x1712ec('0x727')]--;else _0x3e396d[_0x1712ec('0x2681')][_0x1712ec('0x1274')]['fromKey']===_0x209fb6-0x1&&_0x3e396d[_0x1712ec('0x2681')]['offlineForm'][_0x1712ec('0x727')]++;}}function _0x2fea75(_0x5d4953,_0x538808){const _0x5c96e3=_0x1e0859;if(_0x538808!==_0x3e396d[_0x5c96e3('0x2681')][_0x5c96e3('0x1274')]['items']['length']-0x1){const _0x2efde5=_0x3e396d[_0x5c96e3('0x2681')][_0x5c96e3('0x1274')][_0x5c96e3('0x1996')][_0x538808+0x1];_0x3e396d[_0x5c96e3('0x2681')][_0x5c96e3('0x1274')][_0x5c96e3('0x1996')][_0x538808]=_0x2efde5,_0x3e396d['chatWebsite'][_0x5c96e3('0x1274')][_0x5c96e3('0x1996')][_0x538808+0x1]=angular[_0x5c96e3('0x1a86')](_0x5d4953);if(_0x3e396d[_0x5c96e3('0x2681')][_0x5c96e3('0x1274')][_0x5c96e3('0x727')]===_0x538808)_0x3e396d[_0x5c96e3('0x2681')][_0x5c96e3('0x1274')][_0x5c96e3('0x727')]++;else _0x3e396d[_0x5c96e3('0x2681')]['offlineForm'][_0x5c96e3('0x727')]===_0x538808+0x1&&_0x3e396d[_0x5c96e3('0x2681')][_0x5c96e3('0x1274')][_0x5c96e3('0x727')]--;}}function _0x1b2b15(_0x2e70da){const _0x39f453=_0x1e0859;_0x3e396d['chatWebsite'][_0x39f453('0x1274')]['items'][_0x39f453('0x1fd0')]({'type':_0x2e70da,'cmField':null,'variable':null});}function _0x2969b1(_0x1f39d2){const _0x4e3135=_0x1e0859,_0x5f2589=_0x41da7d[_0x4e3135('0x1c6f')]()[_0x4e3135('0xf28')]('The\x20component\x20will\x20be\x20deleted.')[_0x4e3135('0x1525')](_0x4e3135('0x4d'))['ariaLabel'](_0x4e3135('0x1130'))['ok']('Ok')[_0x4e3135('0x19fb')](_0x4e3135('0x253a'));_0x41da7d[_0x4e3135('0x1d4')](_0x5f2589)[_0x4e3135('0x683')](function(){const _0x679f42=_0x4e3135;_0x3e396d[_0x679f42('0x2681')]['offlineForm'][_0x679f42('0x1996')][_0x679f42('0x2040')](_0x1f39d2,0x1);});}}const _0x36d17e=_0x3ff931;_0x5e8856[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$document','api'];function _0x5e8856(_0x3dea30,_0x30bef1,_0x160179){const _0x59393b=_0x189033,_0x4914d4=this;_0x4914d4['chatWebsite']={},_0x4914d4[_0x59393b('0x77')]={},_0x4914d4[_0x59393b('0x143a')]=[{'type':_0x59393b('0xfc9'),'name':_0x59393b('0x2101'),'icon':_0x59393b('0x24d6')},{'type':_0x59393b('0x2511'),'name':_0x59393b('0xaf7'),'icon':_0x59393b('0x2f2')},{'type':'input','name':_0x59393b('0x1b85'),'icon':'icon-keyboard'},{'type':_0x59393b('0x24be'),'name':_0x59393b('0x21b3'),'icon':'icon-format-text'},{'type':_0x59393b('0xf51'),'name':_0x59393b('0x54f'),'icon':'icon-radiobox-marked'},{'type':'checkboxes','name':_0x59393b('0x2614'),'icon':_0x59393b('0x213a')},{'type':'agreement','name':_0x59393b('0x78c'),'icon':'icon-checkbox-marked-outline'}],_0x4914d4['init']=_0xdb8f95,_0x4914d4['up']=_0x58d30a,_0x4914d4[_0x59393b('0x2785')]=_0x35fb63,_0x4914d4[_0x59393b('0x23c6')]=_0x3f25b5,_0x4914d4[_0x59393b('0x3ec')]=_0x42902d;function _0xdb8f95(_0x359b69){const _0x36eaa6=_0x59393b;_0x4914d4[_0x36eaa6('0x189a')]=[],_0x4914d4[_0x36eaa6('0xc4d')]=[],_0x4914d4['uselessFields']=['id','createdAt',_0x36eaa6('0x2000'),'ListId','CompanyId','$promise',_0x36eaa6('0x1980')],_0x4914d4[_0x36eaa6('0x2681')]=_0x359b69,_0x2e3ca0()[_0x36eaa6('0x173f')](_0x4914d4[_0x36eaa6('0x2681')]['onlineForm'])&&(_0x4914d4[_0x36eaa6('0x2681')][_0x36eaa6('0x77')]={'items':[],'fromKey':null}),_0x160179[_0x36eaa6('0x259b')][_0x36eaa6('0xcb')]({'id':_0x4914d4[_0x36eaa6('0x2681')]['ListId']})[_0x36eaa6('0xe53')][_0x36eaa6('0x683')](function(_0x35560d){const _0x1d5696=_0x36eaa6;for(let _0xc90ab6=0x0;_0xc90ab6<_0x35560d[_0x1d5696('0xf5d')][_0x1d5696('0x1564')];_0xc90ab6++){_0x4914d4[_0x1d5696('0xc4d')][_0x1d5696('0x1fd0')]({'key':_0x1d5696('0x1469')+_0x35560d[_0x1d5696('0xf5d')][_0xc90ab6]['id'],'value':_0x35560d[_0x1d5696('0xf5d')][_0xc90ab6][_0x1d5696('0x64a')]});}return _0x160179[_0x1d5696('0x276e')][_0x1d5696('0x2267')]()[_0x1d5696('0xe53')];})[_0x36eaa6('0x683')](function(_0x5891f9){const _0x2245fc=_0x36eaa6,_0x17d91d=_0x2e3ca0()[_0x2245fc('0x55e')](_0x5891f9);for(let _0x192531=0x0;_0x192531<_0x17d91d[_0x2245fc('0x1564')];_0x192531++){!_0x2e3ca0()['includes'](_0x4914d4['uselessFields'],_0x17d91d[_0x192531])&&!_0x2e3ca0()['startsWith'](_0x17d91d[_0x192531],_0x2245fc('0x1469'))&&_0x4914d4[_0x2245fc('0x189a')][_0x2245fc('0x1167')]({'key':_0x17d91d[_0x192531],'value':_0x17d91d[_0x192531]});}return _0x160179['variable'][_0x2245fc('0x1e6e')]()[_0x2245fc('0xe53')];})['then'](function(_0x99c1e6){const _0x19b440=_0x36eaa6;_0x4914d4['variables']=_0x99c1e6[_0x19b440('0xf5d')];})[_0x36eaa6('0x130a')](function(_0x2948f6){const _0x29ccd9=_0x36eaa6;console[_0x29ccd9('0x52a')](_0x2948f6);});}function _0x58d30a(_0x54f35e,_0x33003a){const _0x42412c=_0x59393b;if(_0x33003a!==0x0){const _0xfc10b=_0x4914d4[_0x42412c('0x2681')][_0x42412c('0x77')][_0x42412c('0x1996')][_0x33003a-0x1];_0x4914d4[_0x42412c('0x2681')]['onlineForm'][_0x42412c('0x1996')][_0x33003a]=_0xfc10b,_0x4914d4['chatWebsite'][_0x42412c('0x77')]['items'][_0x33003a-0x1]=angular['copy'](_0x54f35e);if(_0x4914d4[_0x42412c('0x2681')][_0x42412c('0x77')][_0x42412c('0x727')]===_0x33003a)_0x4914d4[_0x42412c('0x2681')]['onlineForm'][_0x42412c('0x727')]--;else _0x4914d4[_0x42412c('0x2681')]['onlineForm']['fromKey']===_0x33003a-0x1&&_0x4914d4[_0x42412c('0x2681')]['onlineForm'][_0x42412c('0x727')]++;}}function _0x35fb63(_0x442c1d,_0x5330db){const _0x28fc06=_0x59393b;if(_0x5330db!==_0x4914d4[_0x28fc06('0x2681')][_0x28fc06('0x77')][_0x28fc06('0x1996')][_0x28fc06('0x1564')]-0x1){const _0x1358d2=_0x4914d4['chatWebsite']['onlineForm'][_0x28fc06('0x1996')][_0x5330db+0x1];_0x4914d4['chatWebsite'][_0x28fc06('0x77')][_0x28fc06('0x1996')][_0x5330db]=_0x1358d2,_0x4914d4[_0x28fc06('0x2681')][_0x28fc06('0x77')]['items'][_0x5330db+0x1]=angular[_0x28fc06('0x1a86')](_0x442c1d);if(_0x4914d4[_0x28fc06('0x2681')]['onlineForm'][_0x28fc06('0x727')]===_0x5330db)_0x4914d4[_0x28fc06('0x2681')]['onlineForm'][_0x28fc06('0x727')]++;else _0x4914d4['chatWebsite']['onlineForm'][_0x28fc06('0x727')]===_0x5330db+0x1&&_0x4914d4[_0x28fc06('0x2681')]['onlineForm']['fromKey']--;}}function _0x3f25b5(_0x5282fa){const _0x32feab=_0x59393b;_0x4914d4['chatWebsite'][_0x32feab('0x77')]['items'][_0x32feab('0x1fd0')]({'type':_0x5282fa,'cmField':null,'variable':null});}function _0x42902d(_0x4cab64){const _0x5091e1=_0x59393b,_0x3023a5=_0x3dea30[_0x5091e1('0x1c6f')]()[_0x5091e1('0xf28')](_0x5091e1('0x19e'))[_0x5091e1('0x1525')](_0x5091e1('0x4d'))['ariaLabel'](_0x5091e1('0x1130'))['ok']('Ok')[_0x5091e1('0x19fb')]('Cancel');_0x3dea30[_0x5091e1('0x1d4')](_0x3023a5)[_0x5091e1('0x683')](function(){const _0x4facc3=_0x5091e1;_0x4914d4[_0x4facc3('0x2681')][_0x4facc3('0x77')][_0x4facc3('0x727')]===_0x4cab64&&(_0x4914d4[_0x4facc3('0x2681')][_0x4facc3('0x77')][_0x4facc3('0x727')]=null),_0x4914d4['chatWebsite'][_0x4facc3('0x77')]['items'][_0x4facc3('0x2040')](_0x4cab64,0x1),!_0x4914d4['chatWebsite'][_0x4facc3('0x77')]['items']['length']&&(_0x4914d4[_0x4facc3('0x2681')][_0x4facc3('0x77')]['fromKey']=null);});}}const _0x47f3b5=_0x5e8856;_0x9bfd61['$inject']=[_0x189033('0x17e4'),_0x189033('0x1d70')];function _0x9bfd61(_0x28f396,_0x167749){const _0x28cdc1=_0x189033,_0x571817=this,_0x19acf7=0x8,_0x3e65f0=_0x19acf7*0x400*0x400;_0x571817[_0x28cdc1('0x2681')]={},_0x571817[_0x28cdc1('0x1134')],_0x571817[_0x28cdc1('0x8f')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x3e65f0,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x571817[_0x28cdc1('0x1fa6')]={'flow':{}},_0x571817[_0x28cdc1('0xfbe')]=![],_0x571817[_0x28cdc1('0x1aad')]=_0x12db53,_0x571817[_0x28cdc1('0xa03')]=_0x58cfa4,_0x571817[_0x28cdc1('0x1152')]=_0x2ae539,_0x571817['init']=_0x54ebd5;function _0x54ebd5(_0x158005,_0x5d4064){const _0x369c6b=_0x28cdc1;_0x571817[_0x369c6b('0x2681')]=angular['copy'](_0x158005),_0x571817[_0x369c6b('0x1134')]=typeof _0x5d4064!==_0x369c6b('0x1867')?_0x5d4064:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x571817[_0x369c6b('0x8f')][_0x369c6b('0x568')]='/api/chat/websites/:id/customer_avatar'[_0x369c6b('0x1725')](':id',_0x571817[_0x369c6b('0x2681')]['id']),_0x571817[_0x369c6b('0x2681')][_0x369c6b('0x2668')]=[];}function _0x12db53(_0x593c82){const _0x21816a=_0x28cdc1,_0x424aa5=[_0x21816a('0x21ec'),'jpg'];if(!_0x2e3ca0()[_0x21816a('0x2292')](_0x424aa5,_0x593c82[_0x21816a('0x1197')]()))return _0x167749[_0x21816a('0x52a')]({'title':_0x21816a('0xa00')+_0x593c82[_0x21816a('0x1197')](),'msg':_0x21816a('0x2560')+_0x424aa5[_0x21816a('0x1630')]()}),![];if(_0x593c82[_0x21816a('0x1a41')]>_0x3e65f0)return _0x167749[_0x21816a('0x52a')]({'title':_0x21816a('0x19a2'),'msg':'The\x20max\x20allowed\x20size\x20is\x20'+_0x19acf7+'MB'}),![];const _0x2eb906={'id':_0x593c82[_0x21816a('0x2379')],'file':_0x593c82,'type':_0x21816a('0x132')};return _0x571817[_0x21816a('0x2681')][_0x21816a('0x2668')]['unshift'](_0x2eb906),!![];}function _0x58cfa4(){const _0x988b0b=_0x28cdc1;_0x571817[_0x988b0b('0x1fa6')][_0x988b0b('0x190a')][_0x988b0b('0x2810')]['headers']={'X-Requested-With':'XMLHttpRequest','Authorization':_0x988b0b('0x189e')+_0x28f396['get']('motion.token')},_0x571817['ngFlow'][_0x988b0b('0x190a')][_0x988b0b('0xa03')]();}function _0x2ae539(_0x389372){const _0x4daca7=_0x28cdc1;angular[_0x4daca7('0x1299')](_0x571817[_0x4daca7('0x2681')]['images'],function(_0x1c3b27){const _0x3d9c6b=_0x4daca7;if(_0x1c3b27['id']===_0x389372[_0x3d9c6b('0x2379')]){const _0x872a02=new FileReader();_0x872a02['readAsDataURL'](_0x1c3b27[_0x3d9c6b('0x21dd')][_0x3d9c6b('0x21dd')]),_0x872a02[_0x3d9c6b('0x43b')]=function(_0x4146d9){const _0x55e17e=_0x3d9c6b;_0x1c3b27[_0x55e17e('0x1284')]=_0x4146d9[_0x55e17e('0x568')][_0x55e17e('0x7c9')];},_0x1c3b27[_0x3d9c6b('0xcf0')]='image';}});}}const _0x150e09=_0x9bfd61,_0x37aa85=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/agent/interaction/agent.general.interaction.dialog.html/agent.general.interaction.dialog.html';_0x480079[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),'$state','$q',_0x189033('0x1d08'),_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x480079(_0x159b1b,_0x125d37,_0x2212f3,_0x30f308,_0x5cd93a,_0xaec7c4,_0x3f5bc1,_0x2c7dac,_0x35613e,_0x1cc7d7,_0x1d9113){const _0x49768e=_0x189033,_0x4fec71=this;_0x4fec71[_0x49768e('0x11ed')]=_0x1d9113[_0x49768e('0x20b2')](),_0x4fec71[_0x49768e('0x2681')]={},_0x4fec71[_0x49768e('0x1516')]={'count':0x0,'rows':[]},_0x4fec71[_0x49768e('0x123c')]=[],_0x4fec71[_0x49768e('0x1134')],_0x4fec71[_0x49768e('0x23a2')]={'read':'null','closed':_0x49768e('0x13c'),'sort':_0x49768e('0xddd'),'includeAll':_0x49768e('0x26ac'),'limit':0xa,'page':0x1},_0x4fec71[_0x49768e('0x12f3')]=_0x281dba,_0x4fec71['deleteConfirm']=_0x5387b7,_0x4fec71['chatInteractionDownload']=_0x218ed4,_0x4fec71[_0x49768e('0x53')]=_0x282218,_0x4fec71[_0x49768e('0x1097')]=_0x3e87ef,_0x4fec71[_0x49768e('0xf8c')]=_0x94e1e8,_0x4fec71[_0x49768e('0x2121')]=_0x3f704f,_0x4fec71[_0x49768e('0x230d')]=_0x21caac,_0x4fec71[_0x49768e('0x24df')]=_0x398f77,_0x4fec71[_0x49768e('0xdfa')]=_0x275898;function _0x281dba(_0x4eb510,_0x367784){const _0x5a467d=_0x49768e;_0x4fec71[_0x5a467d('0x2681')]=_0x4eb510,_0x4fec71[_0x5a467d('0x1134')]=typeof _0x367784!==_0x5a467d('0x1867')?_0x367784:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4fec71[_0x5a467d('0x23a2')]['ChatWebsiteId']=_0x4fec71['chatWebsite']['id'],_0x4fec71['advancedSearch']={'fields':_0x443b20()},_0x384f0e();}function _0x384f0e(){const _0x59e925=_0x49768e;return _0x1cc7d7[_0x59e925('0x270')][_0x59e925('0x1e6e')]()[_0x59e925('0xe53')][_0x59e925('0x683')](function(_0x5ac6e0){_0x4fec71['tags']=_0x5ac6e0||{'count':0x0,'rows':[]};})[_0x59e925('0x683')](function(){_0x4fec71['quickFilters']=_0x232340();});}function _0x232340(){const _0x21287c=_0x49768e;return[{'name':_0x21287c('0x10c1'),'key':_0x21287c('0x1a4'),'type':'date','label':_0x21287c('0x1006')},{'name':_0x21287c('0xc51'),'key':_0x21287c('0x20db'),'type':_0x21287c('0xb31'),'label':'DASHBOARDS.SELECT_READ_UNREAD','customOptions':[{'value':0x0,'translate':_0x21287c('0x2226')},{'value':0x1,'translate':_0x21287c('0x38f')},{'value':null,'translate':_0x21287c('0x475')}]},{'name':_0x21287c('0x1d9d'),'key':'closed','type':_0x21287c('0xb31'),'label':'DASHBOARDS.SELECT_STATUS','customOptions':[{'value':0x0,'translate':_0x21287c('0x10b1')},{'value':0x1,'translate':_0x21287c('0x270a')},{'value':null,'translate':_0x21287c('0x475')}]},{'name':_0x21287c('0x62c'),'key':_0x21287c('0x10c5'),'type':_0x21287c('0xb31'),'label':'DASHBOARDS.SELECT_AGENT','customOptions':[{'value':_0x21287c('0x13c'),'translate':_0x21287c('0x2608')},{'value':undefined,'translate':_0x21287c('0x475')}]},{'name':_0x21287c('0x1e'),'key':_0x21287c('0x270'),'type':_0x21287c('0xf6c'),'label':'DASHBOARDS.SELECT_TAG','options':_0x4fec71[_0x21287c('0x1ce6')][_0x21287c('0xf5d')],'placeholder':'DASHBOARDS.TAGS'}];}function _0x443b20(){const _0x27f7c2=_0x49768e;return[{'name':'Id','column':'id','type':_0x27f7c2('0x121f')},{'name':_0x27f7c2('0x1309'),'column':'Contact','type':'autocomplete','options':{'searchFields':[_0x27f7c2('0xeef'),_0x27f7c2('0x510'),_0x27f7c2('0x1c92')],'route':{'model':_0x27f7c2('0x276e'),'action':'get','params':{'fields':_0x27f7c2('0x8ff'),'Contact':'@autocomplete','nolimit':!![]}},'extraOperators':[_0x27f7c2('0xe55')],'excludedOperators':[_0x27f7c2('0x17ee')]}},{'name':'Subject','column':_0x27f7c2('0x1e66'),'type':_0x27f7c2('0x1bcd'),'options':{'excludedOperators':[_0x27f7c2('0x393'),'$ne']}},{'name':_0x27f7c2('0x1765'),'column':'plainBody','type':_0x27f7c2('0x1bcd'),'options':{'excludedOperators':[_0x27f7c2('0x393'),'$ne']}},{'name':_0x27f7c2('0x1d9d'),'column':_0x27f7c2('0xd8a'),'type':'select','values':[{'id':0x0,'translate':'DASHBOARDS.OPENED'},{'id':0x1,'translate':_0x27f7c2('0x270a')}],'options':{'excludedOperators':[_0x27f7c2('0x17ee')]}},{'name':_0x27f7c2('0x62c'),'column':_0x27f7c2('0x1dad'),'type':'autocomplete','options':{'table':'i','route':{'model':_0x27f7c2('0xc96'),'action':_0x27f7c2('0x1e6e'),'params':{'role':_0x27f7c2('0x2327'),'fields':_0x27f7c2('0x2686'),'nolimit':!![]}},'searchFields':[_0x27f7c2('0x11bc'),_0x27f7c2('0x60a')],'extraOperators':[_0x27f7c2('0xe55')],'excludedOperators':[_0x27f7c2('0x17ee')]}},{'name':'Tags','column':'Tag','type':_0x27f7c2('0xf6c'),'options':{'route':{'model':_0x27f7c2('0x270'),'action':_0x27f7c2('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x27f7c2('0x1479')]}},{'name':_0x27f7c2('0x10c1'),'column':_0x27f7c2('0x1a4'),'type':_0x27f7c2('0x270e'),'options':{'excludedOperators':[_0x27f7c2('0x17ee')]}},{'name':'Read','column':'unreadMessages','type':_0x27f7c2('0xb31'),'values':[{'id':0x1,'translate':'DASHBOARDS.READ'},{'id':0x0,'translate':_0x27f7c2('0x2226')}],'options':{'excludedOperators':[_0x27f7c2('0x17ee')]}}];}function _0x3f704f(){const _0x46e908=_0x49768e;_0x3f5bc1['show']({'controller':_0x46e908('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular['element'](_0x2c7dac['body']),'clickOutsideToClose':![],'locals':{'fields':_0x4fec71[_0x46e908('0x19c9')]['fields'],'color':undefined,'storagePath':'chat.chatWebsites'},'fullscreen':!![]})[_0x46e908('0x683')](function(_0x47b5b1){const _0x10eb9e=_0x46e908;_0x4fec71[_0x10eb9e('0x23a2')][_0x10eb9e('0x19a4')]=_0x47b5b1===![]?undefined:_0x47b5b1;if(_0x4fec71[_0x10eb9e('0x23a2')]['search'])_0x3e87ef();else _0x47b5b1===![]&&_0x3e87ef();})[_0x46e908('0x130a')](function(_0xe22007){const _0x4a8787=_0x46e908;_0x35613e[_0x4a8787('0x52a')]({'title':_0x4a8787('0x1119'),'msg':_0xe22007[_0x4a8787('0x5a5')]?JSON['stringify'](_0xe22007[_0x4a8787('0x5a5')]['message']):_0xe22007[_0x4a8787('0x1ff0')]()});});}function _0x218ed4(_0x4c1408,_0xb17520,_0xa6fe84){const _0x334ad9=_0x49768e;return _0x1cc7d7[_0x334ad9('0x1809')][_0x334ad9('0x18e8')]({'id':_0x4c1408['id'],'exists':!![],'attachments':_0xa6fe84})[_0x334ad9('0xe53')]['then'](function(_0x321531){const _0x111212=_0x334ad9,_0x316cae=[_0x321531[_0x111212('0x1fb3')]];let _0x5a365d=_0x111212('0xa98')+_0x4c1408['id'];const _0x5b6a82=new Blob(_0x316cae,{'type':_0x321531[_0x111212('0xcf0')]});_0x5a365d=_0x111212('0x599')+_0x4c1408['id']+_0x111212('0x18ff');const _0x51e832=window[_0x111212('0x12e1')][_0x111212('0x1ffa')]('a');_0x51e832[_0x111212('0x130f')](_0x111212('0x2767'),URL[_0x111212('0x2820')](_0x5b6a82)),_0x51e832[_0x111212('0x130f')](_0x111212('0x18e8'),_0x5a365d),document[_0x111212('0x18e5')][_0x111212('0x1e43')](_0x51e832),_0x51e832[_0x111212('0x1d42')]();})[_0x334ad9('0x130a')](function(_0x4e348a){const _0x3674fc=_0x334ad9;if(_0x4e348a[_0x3674fc('0x5a5')]&&_0x4e348a['data'][_0x3674fc('0x17f')]&&_0x4e348a[_0x3674fc('0x5a5')][_0x3674fc('0x17f')]['length'])for(let _0x284792=0x0;_0x284792<_0x4e348a[_0x3674fc('0x5a5')][_0x3674fc('0x17f')][_0x3674fc('0x1564')];_0x284792+=0x1){_0x35613e[_0x3674fc('0x52a')]({'title':_0x4e348a[_0x3674fc('0x5a5')]['errors'][_0x284792][_0x3674fc('0xcf0')],'msg':_0x4e348a['data'][_0x3674fc('0x17f')][_0x284792][_0x3674fc('0x8c2')]});}else _0x35613e['error']({'title':_0x4e348a[_0x3674fc('0x13ee')]?_0x3674fc('0x2168')+_0x4e348a['status']+_0x3674fc('0xbf6')+_0x4e348a[_0x3674fc('0x24a9')]:_0x3674fc('0x17cc'),'msg':_0x4e348a[_0x3674fc('0x5a5')]?JSON[_0x3674fc('0x258a')](_0x4e348a[_0x3674fc('0x5a5')][_0x3674fc('0x8c2')]):_0x4e348a[_0x3674fc('0x1ff0')]()});});}function _0x5387b7(_0x3c1bce,_0xda2f82){const _0x373df7=_0x49768e,_0x255aef=_0x3f5bc1[_0x373df7('0x1c6f')]()[_0x373df7('0xf28')](_0x373df7('0xb1f'))[_0x373df7('0x26e3')](_0x373df7('0xed5')+(_0x3c1bce['name']||_0x3c1bce['id']&&_0x2e3ca0()[_0x373df7('0x2711')](_0x373df7('0x936'))+_0x3c1bce['id']||_0x373df7('0xa98'))+_0x373df7('0x20f1')+_0x373df7('0x1ee7'))['ariaLabel'](_0x373df7('0x19a8'))['targetEvent'](_0xda2f82)['ok']('OK')['cancel'](_0x373df7('0x16b8'));_0x3f5bc1[_0x373df7('0x1d4')](_0x255aef)[_0x373df7('0x683')](function(){_0x398f77(_0x3c1bce);},function(){const _0x27b53a=_0x373df7;console[_0x27b53a('0x1b2b')]('CANCEL');});}function _0x282218(_0x2e3cae){const _0x3f205e=_0x49768e;_0x4fec71[_0x3f205e('0x1516')]=_0x2e3cae||{'count':0x0,'rows':[]};for(let _0x2cd32a=0x0;_0x2cd32a<_0x4fec71[_0x3f205e('0x1516')][_0x3f205e('0xf5d')][_0x3f205e('0x1564')];_0x2cd32a+=0x1){const _0x4fd2f9=_0x4fec71[_0x3f205e('0x1516')][_0x3f205e('0xf5d')][_0x2cd32a];_0x30a85f(_0x4fd2f9),_0x4fd2f9[_0x3f205e('0x2464')][_0x3f205e('0x60a')]=_0x2e4968(_0x4fd2f9);}}function _0x3e87ef(){const _0x4281ef=_0x49768e;_0x4fec71[_0x4281ef('0x23a2')][_0x4281ef('0x1cc8')]=(_0x4fec71[_0x4281ef('0x23a2')][_0x4281ef('0xdf8')]-0x1)*_0x4fec71[_0x4281ef('0x23a2')][_0x4281ef('0x6f0')],_0x4fec71[_0x4281ef('0x1883')]=_0x1cc7d7[_0x4281ef('0x1809')]['get'](_0x4fec71['query'],_0x282218)['$promise'];}function _0x94e1e8(_0xcf796c,_0x3c23ed){const _0xeefc62=_0x49768e;_0x3f5bc1[_0xeefc62('0x1d4')]({'controller':_0xeefc62('0x13ab'),'controllerAs':'vm','templateUrl':_0x37aa85,'parent':angular[_0xeefc62('0x1fcc')](_0x2c7dac[_0xeefc62('0x18e5')]),'targetEvent':_0xcf796c,'clickOutsideToClose':!![],'onShowing':function(_0x250c6e){const _0x3fc8c8=_0xeefc62;_0x250c6e['vm'][_0x3fc8c8('0x12f3')]({'id':0x1,'channel':_0x3fc8c8('0x24e'),'interaction':_0x3c23ed,'spy':!![]},_0x125d37[_0x3fc8c8('0x1cd5')]['vm'][_0x3fc8c8('0x260a')]);}});}function _0x398f77(_0x48e6a6){const _0x394d6c=_0x49768e;_0x1cc7d7[_0x394d6c('0x1809')]['delete']({'id':_0x48e6a6['id']})[_0x394d6c('0xe53')]['then'](function(){const _0x17d942=_0x394d6c;_0x2e3ca0()[_0x17d942('0x3ec')](_0x4fec71[_0x17d942('0x1516')][_0x17d942('0xf5d')],{'id':_0x48e6a6['id']}),_0x4fec71[_0x17d942('0x1516')][_0x17d942('0x50d')]-=0x1,!_0x4fec71['chatWebsiteInteractions']['rows'][_0x17d942('0x1564')]&&_0x3e87ef(),_0x35613e[_0x17d942('0x53')]({'title':_0x17d942('0x1c86'),'msg':_0x48e6a6[_0x17d942('0x60a')]?_0x48e6a6[_0x17d942('0x60a')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x1f5bf9){const _0x1075bf=_0x394d6c;if(_0x1f5bf9[_0x1075bf('0x5a5')]&&_0x1f5bf9[_0x1075bf('0x5a5')][_0x1075bf('0x17f')]&&_0x1f5bf9[_0x1075bf('0x5a5')][_0x1075bf('0x17f')][_0x1075bf('0x1564')]){_0x4fec71[_0x1075bf('0x17f')]=_0x1f5bf9[_0x1075bf('0x5a5')][_0x1075bf('0x17f')]||[{'message':_0x1f5bf9[_0x1075bf('0x1ff0')](),'type':_0x1075bf('0xd27')}];for(let _0x235e22=0x0;_0x235e22<_0x1f5bf9[_0x1075bf('0x5a5')][_0x1075bf('0x17f')][_0x1075bf('0x1564')];_0x235e22++){_0x35613e[_0x1075bf('0x52a')]({'title':_0x1f5bf9[_0x1075bf('0x5a5')]['errors'][_0x235e22]['type'],'msg':_0x1f5bf9['data'][_0x1075bf('0x17f')][_0x235e22]['message']});}}else _0x35613e[_0x1075bf('0x52a')]({'title':_0x1f5bf9[_0x1075bf('0x13ee')]?'API:'+_0x1f5bf9[_0x1075bf('0x13ee')]+_0x1075bf('0xbf6')+_0x1f5bf9[_0x1075bf('0x24a9')]:_0x1075bf('0xd27'),'msg':_0x1f5bf9[_0x1075bf('0x5a5')]?JSON[_0x1075bf('0x258a')](_0x1f5bf9['data'][_0x1075bf('0x8c2')]):_0x1f5bf9[_0x1075bf('0x8c2')]||_0x1f5bf9[_0x1075bf('0x1ff0')]()});});}function _0x21caac(){const _0x12a93b=_0x49768e,_0x522b2b=angular[_0x12a93b('0x1a86')](_0x4fec71['selectedChatWebsiteInteractions']);return _0x4fec71[_0x12a93b('0x123c')]=[],_0x522b2b;}function _0x275898(_0x265476){const _0x5c8ec9=_0x49768e,_0x3c5f4e=_0x3f5bc1['confirm']()[_0x5c8ec9('0xf28')](_0x5c8ec9('0x1cba'))['htmlContent'](_0x5c8ec9('0xed5')+_0x4fec71[_0x5c8ec9('0x123c')][_0x5c8ec9('0x1564')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x5c8ec9('0x1040')](_0x5c8ec9('0xe27'))['targetEvent'](_0x265476)['ok']('OK')[_0x5c8ec9('0x19fb')]('CANCEL');_0x3f5bc1['show'](_0x3c5f4e)[_0x5c8ec9('0x683')](function(){const _0xa093b6=_0x5c8ec9;_0x4fec71[_0xa093b6('0x123c')]['forEach'](function(_0x581a86){_0x398f77(_0x581a86);}),_0x4fec71[_0xa093b6('0x123c')]=[];});}function _0x30a85f(_0x259f49){const _0x4f8b1a=_0x49768e;_0x259f49['Contact']?_0x259f49[_0x4f8b1a('0x12b3')]=(_0x259f49['Contact'][_0x4f8b1a('0xeef')]||'')+'\x20'+(_0x259f49[_0x4f8b1a('0x1309')][_0x4f8b1a('0x510')]||''):_0x259f49['contactName']=_0x5cd93a[_0x4f8b1a('0x2728')]('DASHBOARDS.UNKNOWN');}function _0x2e4968(_0x35360d){const _0x21eacc=_0x49768e;if(_0x35360d[_0x21eacc('0x10c5')])return _0x35360d[_0x21eacc('0x10c5')]===_0x4fec71['currentUser']['id']?_0x5cd93a[_0x21eacc('0x2728')]('DASHBOARDS.ME'):_0x35360d['Owner'][_0x21eacc('0x11bc')]+'\x20<'+_0x35360d[_0x21eacc('0x2464')][_0x21eacc('0x1d43')]+'>';return _0x5cd93a[_0x21eacc('0x2728')]('DASHBOARDS.NOT_ASSIGNED');}let _0x1d0301=!![],_0x3feb01=0x1;_0x125d37[_0x49768e('0x186d')](_0x49768e('0x229'),function(_0x5a0645,_0x12ae35){const _0x595d9d=_0x49768e;_0x1d0301?_0xaec7c4(function(){_0x1d0301=![];}):(!_0x12ae35&&(_0x3feb01=_0x4fec71[_0x595d9d('0x23a2')][_0x595d9d('0xdf8')]),_0x5a0645!==_0x12ae35&&(_0x4fec71[_0x595d9d('0x23a2')][_0x595d9d('0xdf8')]=0x1),!_0x5a0645&&(_0x4fec71[_0x595d9d('0x23a2')][_0x595d9d('0xdf8')]=_0x3feb01),_0x3e87ef());});}const _0x49f7cf=_0x480079;_0x38669a[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x1d70')];function _0x38669a(_0x1e4a0a,_0x2805a8){const _0x3f60aa=_0x189033,_0x1df0ca=this,_0x4c9d91=0x8,_0x3d008f=_0x4c9d91*0x400*0x400;_0x1df0ca['chatWebsite']={},_0x1df0ca[_0x3f60aa('0x1134')],_0x1df0ca['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x3d008f,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x1df0ca[_0x3f60aa('0x1fa6')]={'flow':{}},_0x1df0ca[_0x3f60aa('0xfbe')]=![],_0x1df0ca[_0x3f60aa('0x1aad')]=_0x14ae89,_0x1df0ca[_0x3f60aa('0xa03')]=_0x3a1c67,_0x1df0ca[_0x3f60aa('0x1152')]=_0x3fc56e,_0x1df0ca[_0x3f60aa('0x12f3')]=_0x34afae;function _0x34afae(_0x6a3284,_0x452960){const _0x210be5=_0x3f60aa;_0x1df0ca[_0x210be5('0x2681')]=angular[_0x210be5('0x1a86')](_0x6a3284),_0x1df0ca[_0x210be5('0x1134')]=typeof _0x452960!==_0x210be5('0x1867')?_0x452960:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1df0ca['ngFlowOptions']['target']='/api/chat/websites/:id/logo'['replace'](_0x210be5('0x10f1'),_0x1df0ca['chatWebsite']['id']),_0x1df0ca['chatWebsite'][_0x210be5('0x2668')]=[];}function _0x14ae89(_0x8ccb54){const _0x4c2216=_0x3f60aa,_0x3dfcaf=[_0x4c2216('0x21ec'),_0x4c2216('0x159c')];if(!_0x2e3ca0()[_0x4c2216('0x2292')](_0x3dfcaf,_0x8ccb54[_0x4c2216('0x1197')]()))return _0x2805a8[_0x4c2216('0x52a')]({'title':_0x4c2216('0xa00')+_0x8ccb54['getExtension'](),'msg':_0x4c2216('0x2560')+_0x3dfcaf[_0x4c2216('0x1630')]()}),![];if(_0x8ccb54[_0x4c2216('0x1a41')]>_0x3d008f)return _0x2805a8[_0x4c2216('0x52a')]({'title':_0x4c2216('0x19a2'),'msg':_0x4c2216('0x1622')+_0x4c9d91+'MB'}),![];const _0x38122d={'id':_0x8ccb54[_0x4c2216('0x2379')],'file':_0x8ccb54,'type':_0x4c2216('0x132')};return _0x1df0ca['chatWebsite'][_0x4c2216('0x2668')][_0x4c2216('0x1167')](_0x38122d),!![];}function _0x3a1c67(){const _0xa2157=_0x3f60aa;_0x1df0ca['ngFlow'][_0xa2157('0x190a')][_0xa2157('0x2810')][_0xa2157('0xb7d')]={'X-Requested-With':_0xa2157('0xbfd'),'Authorization':_0xa2157('0x189e')+_0x1e4a0a[_0xa2157('0x1e6e')](_0xa2157('0x555'))},_0x1df0ca[_0xa2157('0x1fa6')][_0xa2157('0x190a')][_0xa2157('0xa03')]();}function _0x3fc56e(_0x21b228){const _0x24aa74=_0x3f60aa;angular[_0x24aa74('0x1299')](_0x1df0ca[_0x24aa74('0x2681')][_0x24aa74('0x2668')],function(_0x15a1bd){const _0x3049bf=_0x24aa74;if(_0x15a1bd['id']===_0x21b228[_0x3049bf('0x2379')]){const _0x5f2b71=new FileReader();_0x5f2b71[_0x3049bf('0x23e1')](_0x15a1bd[_0x3049bf('0x21dd')][_0x3049bf('0x21dd')]),_0x5f2b71[_0x3049bf('0x43b')]=function(_0x115fcf){const _0x2ee477=_0x3049bf;_0x15a1bd[_0x2ee477('0x1284')]=_0x115fcf[_0x2ee477('0x568')][_0x2ee477('0x7c9')];},_0x15a1bd[_0x3049bf('0xcf0')]=_0x3049bf('0x1110');}});}}const _0x2e3637=_0x38669a,_0x494779=_0x180212['p']+_0x189033('0x3af');_0x23d881[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),_0x189033('0x938'),'$q','$translate',_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),'Auth'];function _0x23d881(_0x5035cc,_0x863fc8,_0x55a244,_0x45d77b,_0x816dd5,_0xc9fab7,_0x26dde0,_0x5abdb6,_0x104765,_0x5a87bc,_0x5fb761){const _0x4a8399=_0x189033,_0xac408b=this;_0xac408b[_0x4a8399('0x11ed')]=_0x5fb761[_0x4a8399('0x20b2')](),_0xac408b[_0x4a8399('0x2681')]={},_0xac408b[_0x4a8399('0x6bd')]={'count':0x0,'rows':[]},_0xac408b[_0x4a8399('0x1449')]=[],_0xac408b[_0x4a8399('0x1134')],_0xac408b[_0x4a8399('0x23a2')]={'fields':'createdAt,updatedAt,id,Contact.firstName','sort':'-createdAt','limit':0xa,'page':0x1},_0xac408b[_0x4a8399('0x12f3')]=_0x492e19,_0xac408b['deleteConfirm']=_0x55c964,_0xac408b['success']=_0x3f3474,_0xac408b[_0x4a8399('0x1c0a')]=_0x284b37,_0xac408b[_0x4a8399('0x26b')]=_0x4a5a18,_0xac408b[_0x4a8399('0x2209')]=_0xf094cb,_0xac408b[_0x4a8399('0x1786')]=_0xa500ad,_0xac408b[_0x4a8399('0x43e')]=_0x3f1eda,_0xac408b[_0x4a8399('0x2677')]=_0x420a35;function _0x492e19(_0x38094c,_0x485769){const _0x3f5eea=_0x4a8399;_0xac408b[_0x3f5eea('0x2681')]=_0x38094c,_0xac408b[_0x3f5eea('0x1134')]=typeof _0x485769!==_0x3f5eea('0x1867')?_0x485769:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0xac408b['query']['id']=_0xac408b['chatWebsite']['id'],_0x284b37();}function _0x55c964(_0xcf60a5,_0x36d2be){const _0x3d936d=_0x4a8399,_0x2428b4=_0x26dde0[_0x3d936d('0x1c6f')]()[_0x3d936d('0xf28')](_0x3d936d('0x454'))[_0x3d936d('0x26e3')](_0x3d936d('0xed5')+(_0xcf60a5[_0x3d936d('0x60a')]||_0xcf60a5['id']&&_0x2e3ca0()[_0x3d936d('0x2711')]('offlineMessage\x20#')+_0xcf60a5['id']||_0x3d936d('0x1bb1'))+''+_0x3d936d('0x1ee7'))[_0x3d936d('0x1040')]('delete\x20offlineMessage')['targetEvent'](_0x36d2be)['ok']('OK')[_0x3d936d('0x19fb')](_0x3d936d('0x16b8'));_0x26dde0[_0x3d936d('0x1d4')](_0x2428b4)['then'](function(){_0x3f1eda(_0xcf60a5);},function(){const _0x51c146=_0x3d936d;console['log'](_0x51c146('0x16b8'));});}function _0x3f3474(_0x2fff58){const _0x46e1ea=_0x4a8399;_0xac408b[_0x46e1ea('0x6bd')]=_0x2fff58||{'count':0x0,'rows':[]};}function _0x284b37(){const _0x5222ed=_0x4a8399;_0xac408b[_0x5222ed('0x23a2')][_0x5222ed('0x1cc8')]=(_0xac408b[_0x5222ed('0x23a2')][_0x5222ed('0xdf8')]-0x1)*_0xac408b[_0x5222ed('0x23a2')][_0x5222ed('0x6f0')],_0xac408b[_0x5222ed('0x1883')]=_0x5a87bc[_0x5222ed('0x2681')]['getOfflineMessages'](_0xac408b[_0x5222ed('0x23a2')],_0x3f3474)[_0x5222ed('0xe53')];}function _0x4a5a18(_0xb8803d,_0x4793fa){const _0x4ecb25=_0x4a8399;_0x26dde0['show']({'controller':'CreateOrEditOfflineMessageDialogController','controllerAs':'vm','templateUrl':_0x494779,'parent':angular[_0x4ecb25('0x1fcc')](_0x5abdb6[_0x4ecb25('0x18e5')]),'targetEvent':_0xb8803d,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0xac408b[_0x4ecb25('0x2681')],'offlineMessage':_0x4793fa,'offlineMessages':_0xac408b[_0x4ecb25('0x6bd')][_0x4ecb25('0xf5d')],'license':null,'setting':null,'crudPermissions':_0xac408b[_0x4ecb25('0x1134')]}});}function _0xf094cb(_0x27f8ea,_0x56108b){const _0x30b727=_0x4a8399;_0x26dde0['show']({'controller':_0x30b727('0x1b8e'),'controllerAs':'vm','templateUrl':_0x494779,'parent':angular[_0x30b727('0x1fcc')](_0x5abdb6[_0x30b727('0x18e5')]),'targetEvent':_0x27f8ea,'clickOutsideToClose':!![],'resolve':{'message':[_0x30b727('0x4b1'),function(_0x140422){const _0x13a3c6=_0x30b727;return _0x140422[_0x13a3c6('0xed7')]('chatOfflineMessage@get',{'fields':'id,body','id':_0x56108b['id']});}]}});}function _0x3f1eda(_0x3eb011){const _0x5507b8=_0x4a8399;_0x5a87bc[_0x5507b8('0xc3c')][_0x5507b8('0xd7e')]({'id':_0x3eb011['id']})[_0x5507b8('0xe53')][_0x5507b8('0x683')](function(){const _0x45aff1=_0x5507b8;_0x2e3ca0()['remove'](_0xac408b[_0x45aff1('0x6bd')][_0x45aff1('0xf5d')],{'id':_0x3eb011['id']}),_0xac408b['chatWebsiteOfflineMessages']['count']-=0x1,!_0xac408b['chatWebsiteOfflineMessages'][_0x45aff1('0xf5d')]['length']&&_0x284b37(),_0x104765[_0x45aff1('0x53')]({'title':_0x45aff1('0xda2'),'msg':_0x3eb011[_0x45aff1('0x60a')]?_0x3eb011[_0x45aff1('0x60a')]+_0x45aff1('0x194d'):''});})[_0x5507b8('0x130a')](function(_0x17b982){const _0x179d1c=_0x5507b8;if(_0x17b982[_0x179d1c('0x5a5')]&&_0x17b982[_0x179d1c('0x5a5')][_0x179d1c('0x17f')]&&_0x17b982[_0x179d1c('0x5a5')][_0x179d1c('0x17f')][_0x179d1c('0x1564')]){_0xac408b[_0x179d1c('0x17f')]=_0x17b982[_0x179d1c('0x5a5')]['errors']||[{'message':_0x17b982[_0x179d1c('0x1ff0')](),'type':_0x179d1c('0xd27')}];for(let _0x98dcb8=0x0;_0x98dcb8<_0x17b982[_0x179d1c('0x5a5')][_0x179d1c('0x17f')][_0x179d1c('0x1564')];_0x98dcb8++){_0x104765['error']({'title':_0x17b982['data'][_0x179d1c('0x17f')][_0x98dcb8][_0x179d1c('0xcf0')],'msg':_0x17b982[_0x179d1c('0x5a5')][_0x179d1c('0x17f')][_0x98dcb8][_0x179d1c('0x8c2')]});}}else _0x104765[_0x179d1c('0x52a')]({'title':_0x17b982[_0x179d1c('0x13ee')]?_0x179d1c('0x2168')+_0x17b982['status']+_0x179d1c('0xbf6')+_0x17b982[_0x179d1c('0x24a9')]:_0x179d1c('0xd27'),'msg':_0x17b982[_0x179d1c('0x5a5')]?JSON['stringify'](_0x17b982[_0x179d1c('0x5a5')]['message']):_0x17b982[_0x179d1c('0x8c2')]||_0x17b982[_0x179d1c('0x1ff0')]()});});}function _0xa500ad(){const _0x5e5b31=_0x4a8399,_0x47899f=angular[_0x5e5b31('0x1a86')](_0xac408b[_0x5e5b31('0x1449')]);return _0xac408b[_0x5e5b31('0x1449')]=[],_0x47899f;}function _0x420a35(_0xe11595){const _0x27ddd0=_0x4a8399,_0x520d2b=_0x26dde0['confirm']()['title'](_0x27ddd0('0x1fc0'))[_0x27ddd0('0x26e3')](_0x27ddd0('0xed5')+_0xac408b[_0x27ddd0('0x1449')][_0x27ddd0('0x1564')]+_0x27ddd0('0x93c')+'\x20will\x20be\x20deleted.')[_0x27ddd0('0x1040')]('delete\x20offlineMessages')[_0x27ddd0('0xe42')](_0xe11595)['ok']('OK')['cancel'](_0x27ddd0('0x16b8'));_0x26dde0['show'](_0x520d2b)[_0x27ddd0('0x683')](function(){const _0x393c4b=_0x27ddd0;_0xac408b['selectedChatWebsiteOfflineMessages'][_0x393c4b('0x1299')](function(_0x3b7c66){_0x3f1eda(_0x3b7c66);}),_0xac408b['selectedChatWebsiteOfflineMessages']=[];});}let _0x116d61=!![],_0x6bd704=0x1;_0x863fc8[_0x4a8399('0x186d')](_0x4a8399('0x229'),function(_0x23dedb,_0x2ee559){const _0x5df995=_0x4a8399;_0x116d61?_0xc9fab7(function(){_0x116d61=![];}):(!_0x2ee559&&(_0x6bd704=_0xac408b[_0x5df995('0x23a2')]['page']),_0x23dedb!==_0x2ee559&&(_0xac408b[_0x5df995('0x23a2')][_0x5df995('0xdf8')]=0x1),!_0x23dedb&&(_0xac408b[_0x5df995('0x23a2')][_0x5df995('0xdf8')]=_0x6bd704),_0x284b37());});}const _0x59a958=_0x23d881;_0x37a188[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x8c2')];function _0x37a188(_0x3ed792,_0x15b9d2){const _0x352f57=_0x189033,_0x503838=this;_0x503838[_0x352f57('0xf28')]=_0x352f57('0xe1b'),_0x503838[_0x352f57('0x8c2')]=_0x15b9d2,_0x503838[_0x352f57('0xf82')]=_0x44c03d;function _0x44c03d(_0x21eb63){const _0x424336=_0x352f57;_0x3ed792[_0x424336('0x1715')](_0x21eb63);}}const _0x1c3aa6=_0x37a188,_0x166bcf=_0x180212['p']+_0x189033('0x47e');_0x495bf8['$inject']=['$cookies',_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),'toasty',_0x189033('0x56b'),_0x189033('0xba1')];function _0x495bf8(_0x2fbf26,_0x12b2c8,_0x10e313,_0x4857d4,_0x4b42e2,_0x3d656d,_0x376eac,_0x1b94c5,_0x4c3d1e,_0x17478c,_0x34fe0a){const _0x4d2111=_0x189033,_0x397ddb=this;_0x397ddb[_0x4d2111('0x11ed')]=_0x34fe0a['getCurrentUser'](),_0x397ddb['chatWebsite']={},_0x397ddb['chatWebsiteProactiveActions']={'count':0x0,'rows':[]},_0x397ddb[_0x4d2111('0x220d')]=[],_0x397ddb[_0x4d2111('0x1134')],_0x397ddb[_0x4d2111('0x23a2')]={'fields':'createdAt,updatedAt,id,name,type,selector,timeout','limit':0xa,'page':0x1},_0x397ddb['arraytype']=_0x2e3ca0()[_0x4d2111('0x24db')]([{'option':_0x4d2111('0xa61'),'value':'\x27mouseOver\x27'},{'option':_0x4d2111('0xa09'),'value':_0x4d2111('0x27ac')}],function(_0x5c529a){const _0x16a1e6=_0x4d2111;return _0x2e3ca0()[_0x16a1e6('0x1725')](_0x5c529a['value'],new RegExp('\x27','g'),'');}),_0x397ddb[_0x4d2111('0x12f3')]=_0x49d5cc,_0x397ddb[_0x4d2111('0x26eb')]=_0xfa2807,_0x397ddb[_0x4d2111('0x53')]=_0x43a0a8,_0x397ddb['getChatWebsiteProactiveActions']=_0x45b43b,_0x397ddb[_0x4d2111('0x1451')]=_0x32faea,_0x397ddb[_0x4d2111('0x3e4')]=_0x41dc71,_0x397ddb[_0x4d2111('0x753')]=_0x347e5d,_0x397ddb[_0x4d2111('0x9e7')]=_0x230aed;function _0x49d5cc(_0x1f3143,_0x2662a3){const _0x83d20c=_0x4d2111;_0x397ddb[_0x83d20c('0x2681')]=_0x1f3143,_0x397ddb[_0x83d20c('0x1134')]=typeof _0x2662a3!=='undefined'?_0x2662a3:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x397ddb['query'][_0x83d20c('0x15a5')]=_0x397ddb[_0x83d20c('0x2681')]['id'],_0x397ddb[_0x83d20c('0x23a2')]['id']=_0x397ddb[_0x83d20c('0x2681')]['id'],_0x45b43b();}function _0xfa2807(_0x1ae8e4,_0x16bd43){const _0x27f7bb=_0x4d2111,_0x4c20dc=_0x376eac[_0x27f7bb('0x1c6f')]()[_0x27f7bb('0xf28')](_0x27f7bb('0x963'))[_0x27f7bb('0x26e3')](''+(_0x1ae8e4[_0x27f7bb('0x60a')]||_0x1ae8e4['id']&&_0x2e3ca0()['upperFirst'](_0x27f7bb('0x1c93'))+_0x1ae8e4['id']||'chatProactiveAction')+''+_0x27f7bb('0x1ee7'))['ariaLabel'](_0x27f7bb('0x20ff'))[_0x27f7bb('0xe42')](_0x16bd43)['ok']('OK')[_0x27f7bb('0x19fb')]('CANCEL');_0x376eac[_0x27f7bb('0x1d4')](_0x4c20dc)[_0x27f7bb('0x683')](function(){_0x347e5d(_0x1ae8e4);},function(){const _0x25c31b=_0x27f7bb;console[_0x25c31b('0x1b2b')]('CANCEL');});}function _0x43a0a8(_0x4951d5){const _0x34daf0=_0x4d2111;_0x397ddb[_0x34daf0('0x88b')]=_0x4951d5||{'count':0x0,'rows':[]};}function _0x45b43b(){const _0x1d9b0f=_0x4d2111;_0x397ddb['query'][_0x1d9b0f('0x1cc8')]=(_0x397ddb[_0x1d9b0f('0x23a2')]['page']-0x1)*_0x397ddb[_0x1d9b0f('0x23a2')][_0x1d9b0f('0x6f0')],_0x397ddb[_0x1d9b0f('0x1883')]=_0x17478c[_0x1d9b0f('0x2681')]['getProactiveActions'](_0x397ddb[_0x1d9b0f('0x23a2')],_0x43a0a8)[_0x1d9b0f('0xe53')];}function _0x32faea(_0x281c21,_0x4d23a4){const _0x4fb377=_0x4d2111;_0x376eac[_0x4fb377('0x1d4')]({'controller':'CreateOrEditChatProactiveActionDialogController','controllerAs':'vm','templateUrl':_0x166bcf,'parent':angular[_0x4fb377('0x1fcc')](_0x1b94c5[_0x4fb377('0x18e5')]),'targetEvent':_0x281c21,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x397ddb[_0x4fb377('0x2681')],'chatProactiveAction':_0x4d23a4,'proactive':_0x397ddb[_0x4fb377('0x88b')]['rows'],'license':null,'setting':null,'crudPermissions':_0x397ddb['crudPermissions']}});}function _0x347e5d(_0x511d43){const _0x578cd2=_0x4d2111;_0x17478c['chatProactiveAction']['delete']({'id':_0x511d43['id']})[_0x578cd2('0xe53')][_0x578cd2('0x683')](function(){const _0x138c84=_0x578cd2;_0x2e3ca0()[_0x138c84('0x3ec')](_0x397ddb[_0x138c84('0x88b')][_0x138c84('0xf5d')],{'id':_0x511d43['id']}),_0x397ddb[_0x138c84('0x88b')][_0x138c84('0x50d')]-=0x1,!_0x397ddb[_0x138c84('0x88b')][_0x138c84('0xf5d')][_0x138c84('0x1564')]&&_0x45b43b(),_0x4c3d1e[_0x138c84('0x53')]({'title':_0x138c84('0x1424'),'msg':_0x511d43['name']?_0x511d43[_0x138c84('0x60a')]+_0x138c84('0x194d'):''});})[_0x578cd2('0x130a')](function(_0x4903a5){const _0x53b4f0=_0x578cd2;if(_0x4903a5[_0x53b4f0('0x5a5')]&&_0x4903a5[_0x53b4f0('0x5a5')][_0x53b4f0('0x17f')]&&_0x4903a5[_0x53b4f0('0x5a5')][_0x53b4f0('0x17f')][_0x53b4f0('0x1564')]){_0x397ddb['errors']=_0x4903a5[_0x53b4f0('0x5a5')]['errors']||[{'message':_0x4903a5[_0x53b4f0('0x1ff0')](),'type':_0x53b4f0('0xd27')}];for(let _0x2d1ace=0x0;_0x2d1ace<_0x4903a5['data'][_0x53b4f0('0x17f')][_0x53b4f0('0x1564')];_0x2d1ace++){_0x4c3d1e[_0x53b4f0('0x52a')]({'title':_0x4903a5[_0x53b4f0('0x5a5')]['errors'][_0x2d1ace]['type'],'msg':_0x4903a5['data'][_0x53b4f0('0x17f')][_0x2d1ace][_0x53b4f0('0x8c2')]});}}else _0x4c3d1e[_0x53b4f0('0x52a')]({'title':_0x4903a5[_0x53b4f0('0x13ee')]?_0x53b4f0('0x2168')+_0x4903a5[_0x53b4f0('0x13ee')]+_0x53b4f0('0xbf6')+_0x4903a5['statusText']:'SYSTEM:GETchatWebsite','msg':_0x4903a5[_0x53b4f0('0x5a5')]?JSON[_0x53b4f0('0x258a')](_0x4903a5['data'][_0x53b4f0('0x8c2')]):_0x4903a5[_0x53b4f0('0x8c2')]||_0x4903a5['toString']()});});}function _0x41dc71(){const _0x51ade9=_0x4d2111,_0x3f4e24=angular['copy'](_0x397ddb[_0x51ade9('0x220d')]);return _0x397ddb[_0x51ade9('0x220d')]=[],_0x3f4e24;}function _0x230aed(_0x246ca1){const _0x25583c=_0x4d2111,_0x420458=_0x376eac['confirm']()[_0x25583c('0xf28')](_0x25583c('0x1212'))[_0x25583c('0x26e3')](_0x25583c('0xed5')+_0x397ddb['selectedChatWebsiteProactiveActions']['length']+_0x25583c('0x93c')+_0x25583c('0x1ee7'))[_0x25583c('0x1040')](_0x25583c('0x5d6'))[_0x25583c('0xe42')](_0x246ca1)['ok']('OK')['cancel'](_0x25583c('0x16b8'));_0x376eac[_0x25583c('0x1d4')](_0x420458)[_0x25583c('0x683')](function(){const _0x3ae185=_0x25583c;_0x397ddb['selectedChatWebsiteProactiveActions'][_0x3ae185('0x1299')](function(_0x48e25f){_0x347e5d(_0x48e25f);}),_0x397ddb[_0x3ae185('0x220d')]=[];});}let _0xca91fe=!![],_0x13e0b1=0x1;_0x12b2c8[_0x4d2111('0x186d')](_0x4d2111('0x229'),function(_0x146462,_0x7f3c04){const _0x117371=_0x4d2111;_0xca91fe?_0x3d656d(function(){_0xca91fe=![];}):(!_0x7f3c04&&(_0x13e0b1=_0x397ddb[_0x117371('0x23a2')][_0x117371('0xdf8')]),_0x146462!==_0x7f3c04&&(_0x397ddb[_0x117371('0x23a2')][_0x117371('0xdf8')]=0x1),!_0x146462&&(_0x397ddb[_0x117371('0x23a2')]['page']=_0x13e0b1),_0x45b43b());});}const _0xfa6b70=_0x495bf8;_0xca14de['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x404'),_0x189033('0x2407'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0xca14de(_0x32dca5,_0x64707a,_0x40cfd2,_0x2cf750,_0x3089fe,_0x7ccf48,_0x36affb,_0x435561,_0x3d8cd4,_0x59f605,_0x31668d,_0x1ca8dc,_0x3d9e4b,_0xe4738c){const _0x4e1c85=_0x189033,_0x15b211=this;_0x15b211[_0x4e1c85('0x11ed')]=_0x31668d[_0x4e1c85('0x20b2')](),_0x15b211[_0x4e1c85('0x17f')]=[],_0x15b211[_0x4e1c85('0x260a')]=_0x3d9e4b,_0x15b211['license']=_0x1ca8dc,_0x15b211[_0x4e1c85('0x1134')]=_0xe4738c,_0x15b211[_0x4e1c85('0x258d')]={},_0x15b211[_0x4e1c85('0x19b2')]=_0x15b211[_0x4e1c85('0x260a')]&&_0x15b211[_0x4e1c85('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x15b211['title']=_0x4e1c85('0x58f'),_0x15b211[_0x4e1c85('0x2407')]=angular[_0x4e1c85('0x1a86')](_0x3d8cd4),_0x15b211['proactive']=_0x435561,_0x15b211[_0x4e1c85('0x21bb')]=![];!_0x15b211[_0x4e1c85('0x2407')]&&(_0x15b211[_0x4e1c85('0x2407')]={'type':'mouseOver'},_0x15b211[_0x4e1c85('0xf28')]=_0x4e1c85('0x28f'),_0x15b211[_0x4e1c85('0x21bb')]=!![]);_0x64707a['params']['id']&&(_0x15b211[_0x4e1c85('0x2407')][_0x4e1c85('0x15a5')]=_0x64707a[_0x4e1c85('0x7f2')]['id']);_0x15b211[_0x4e1c85('0x1474')]=_0x4fcd2a,_0x15b211['saveChatProactiveAction']=_0x36b8b1,_0x15b211['deleteChatProactiveAction']=_0x275d13,_0x15b211['getDateFromString']=_0x5b6419,_0x15b211[_0x4e1c85('0xf82')]=_0xefa646;function _0x4fcd2a(){const _0xe00cf0=_0x4e1c85;_0x15b211['errors']=[],_0x59f605['chatProactiveAction'][_0xe00cf0('0xb0a')](_0x15b211[_0xe00cf0('0x2407')])[_0xe00cf0('0xe53')][_0xe00cf0('0x683')](function(_0x263227){const _0x53b404=_0xe00cf0;_0x15b211[_0x53b404('0x404')]['unshift'](_0x263227[_0x53b404('0x24e1')]()),_0x36affb[_0x53b404('0x53')]({'title':_0x53b404('0xb92'),'msg':_0x15b211[_0x53b404('0x2407')][_0x53b404('0x60a')]?_0x15b211['chatProactiveAction'][_0x53b404('0x60a')]+_0x53b404('0x14b5'):''}),_0xefa646(_0x263227);})[_0xe00cf0('0x130a')](function(_0xa37098){const _0x4b3ced=_0xe00cf0;if(_0xa37098[_0x4b3ced('0x5a5')]&&_0xa37098[_0x4b3ced('0x5a5')]['errors']&&_0xa37098[_0x4b3ced('0x5a5')]['errors']['length']){_0x15b211['errors']=_0xa37098[_0x4b3ced('0x5a5')]['errors']||[{'message':_0xa37098[_0x4b3ced('0x1ff0')](),'type':_0x4b3ced('0xe70')}];for(let _0x2fe0f5=0x0;_0x2fe0f5<_0xa37098[_0x4b3ced('0x5a5')]['errors']['length'];_0x2fe0f5+=0x1){_0x36affb[_0x4b3ced('0x52a')]({'title':_0xa37098[_0x4b3ced('0x5a5')][_0x4b3ced('0x17f')][_0x2fe0f5]['type'],'msg':_0xa37098[_0x4b3ced('0x5a5')][_0x4b3ced('0x17f')][_0x2fe0f5][_0x4b3ced('0x8c2')]});}}else _0x36affb[_0x4b3ced('0x52a')]({'title':_0xa37098[_0x4b3ced('0x13ee')]?'API:'+_0xa37098['status']+_0x4b3ced('0xbf6')+_0xa37098[_0x4b3ced('0x24a9')]:_0x4b3ced('0xe70'),'msg':_0xa37098['data']?JSON[_0x4b3ced('0x258a')](_0xa37098[_0x4b3ced('0x5a5')][_0x4b3ced('0x8c2')]):_0xa37098[_0x4b3ced('0x1ff0')]()});});}function _0x36b8b1(){const _0x5bd147=_0x4e1c85;_0x15b211['errors']=[],_0x59f605[_0x5bd147('0x2407')][_0x5bd147('0x2480')]({'id':_0x15b211[_0x5bd147('0x2407')]['id']},_0x15b211[_0x5bd147('0x2407')])[_0x5bd147('0xe53')][_0x5bd147('0x683')](function(_0x221ca9){const _0x229b33=_0x5bd147,_0x22afe8=_0x2e3ca0()[_0x229b33('0x1c07')](_0x15b211[_0x229b33('0x404')],{'id':_0x221ca9['id']});_0x22afe8&&_0x2e3ca0()['merge'](_0x22afe8,_0x2e3ca0()[_0x229b33('0x24d0')](_0x221ca9[_0x229b33('0x24e1')](),_0x2e3ca0()[_0x229b33('0x55e')](_0x22afe8))),_0x36affb[_0x229b33('0x53')]({'title':_0x229b33('0x265c'),'msg':_0x15b211[_0x229b33('0x2407')][_0x229b33('0x60a')]?_0x15b211[_0x229b33('0x2407')][_0x229b33('0x60a')]+_0x229b33('0xf59'):''}),_0xefa646(_0x221ca9);})[_0x5bd147('0x130a')](function(_0x4f4c45){const _0x2d1a92=_0x5bd147;if(_0x4f4c45[_0x2d1a92('0x5a5')]&&_0x4f4c45[_0x2d1a92('0x5a5')][_0x2d1a92('0x17f')]&&_0x4f4c45['data'][_0x2d1a92('0x17f')][_0x2d1a92('0x1564')]){_0x15b211['errors']=_0x4f4c45[_0x2d1a92('0x5a5')][_0x2d1a92('0x17f')]||[{'message':_0x4f4c45[_0x2d1a92('0x1ff0')](),'type':_0x2d1a92('0x1d4d')}];for(let _0x2ffa79=0x0;_0x2ffa79<_0x4f4c45[_0x2d1a92('0x5a5')]['errors'][_0x2d1a92('0x1564')];_0x2ffa79++){_0x36affb[_0x2d1a92('0x52a')]({'title':_0x4f4c45[_0x2d1a92('0x5a5')][_0x2d1a92('0x17f')][_0x2ffa79][_0x2d1a92('0xcf0')],'msg':_0x4f4c45['data'][_0x2d1a92('0x17f')][_0x2ffa79][_0x2d1a92('0x8c2')]});}}else _0x36affb[_0x2d1a92('0x52a')]({'title':_0x4f4c45[_0x2d1a92('0x13ee')]?'API:'+_0x4f4c45[_0x2d1a92('0x13ee')]+_0x2d1a92('0xbf6')+_0x4f4c45[_0x2d1a92('0x24a9')]:_0x2d1a92('0x1d4d'),'msg':_0x4f4c45[_0x2d1a92('0x5a5')]?JSON['stringify'](_0x4f4c45['data'][_0x2d1a92('0x8c2')]):_0x4f4c45[_0x2d1a92('0x1ff0')]()});});}function _0x275d13(_0x22718f){const _0x2b2adb=_0x4e1c85;_0x15b211['errors']=[];const _0x16a133=_0x2cf750['confirm']()[_0x2b2adb('0xf28')](_0x2b2adb('0x4d'))[_0x2b2adb('0xa6a')](_0x2b2adb('0x1a27'))[_0x2b2adb('0x1040')](_0x2b2adb('0x267d'))['ok'](_0x2b2adb('0x2307'))['cancel'](_0x2b2adb('0x253a'))['targetEvent'](_0x22718f);_0x2cf750[_0x2b2adb('0x1d4')](_0x16a133)['then'](function(){const _0x281bf7=_0x2b2adb;_0x59f605[_0x281bf7('0x2407')][_0x281bf7('0xd7e')]({'id':_0x15b211[_0x281bf7('0x2407')]['id']})[_0x281bf7('0xe53')][_0x281bf7('0x683')](function(){const _0x43274b=_0x281bf7;_0x2e3ca0()[_0x43274b('0x3ec')](_0x15b211[_0x43274b('0x404')],{'id':_0x15b211[_0x43274b('0x2407')]['id']}),_0x36affb[_0x43274b('0x53')]({'title':_0x43274b('0x275e'),'msg':(_0x15b211[_0x43274b('0x2407')][_0x43274b('0x60a')]||'chatProactiveAction')+_0x43274b('0x194d')}),_0xefa646(_0x15b211['chatProactiveAction']);})['catch'](function(_0x3776f3){const _0x561c04=_0x281bf7;if(_0x3776f3['data']&&_0x3776f3['data'][_0x561c04('0x17f')]&&_0x3776f3[_0x561c04('0x5a5')][_0x561c04('0x17f')][_0x561c04('0x1564')]){_0x15b211[_0x561c04('0x17f')]=_0x3776f3[_0x561c04('0x5a5')][_0x561c04('0x17f')]||[{'message':_0x3776f3[_0x561c04('0x1ff0')](),'type':_0x561c04('0xbf5')}];for(let _0x6dcad5=0x0;_0x6dcad5<_0x3776f3[_0x561c04('0x5a5')]['errors'][_0x561c04('0x1564')];_0x6dcad5++){_0x36affb['error']({'title':_0x3776f3[_0x561c04('0x5a5')]['errors'][_0x6dcad5]['type'],'msg':_0x3776f3['data'][_0x561c04('0x17f')][_0x6dcad5][_0x561c04('0x8c2')]});}}else _0x36affb['error']({'title':_0x3776f3['status']?_0x561c04('0x2168')+_0x3776f3[_0x561c04('0x13ee')]+_0x561c04('0xbf6')+_0x3776f3[_0x561c04('0x24a9')]:_0x561c04('0xbf5'),'msg':_0x3776f3[_0x561c04('0x5a5')]?JSON[_0x561c04('0x258a')](_0x3776f3[_0x561c04('0x5a5')][_0x561c04('0x8c2')]):_0x3776f3[_0x561c04('0x8c2')]||_0x3776f3['toString']()});});},function(){});}function _0x5b6419(_0x160809){return _0x160809===null?undefined:new Date(_0x160809);}function _0xefa646(_0x80450){const _0x563589=_0x4e1c85;_0x2cf750[_0x563589('0x1715')](_0x80450);}}const _0x1c715a=_0xca14de;_0x3bd50f[_0x189033('0x14be')]=[_0x189033('0x7a5')];function _0x3bd50f(_0x47a12a){const _0x1a67f7=_0x189033,_0x4ccf2b=this;_0x4ccf2b[_0x1a67f7('0x2681')]={},_0x4ccf2b[_0x1a67f7('0x12f3')]=_0x4dbd93,_0x4ccf2b[_0x1a67f7('0x2289')]={};function _0x4dbd93(_0x42e668){const _0x11f4c9=_0x1a67f7;_0x4ccf2b[_0x11f4c9('0x2681')]=_0x42e668,_0x4ccf2b['start']=_0x11f4c9('0x67e'),_0x4ccf2b[_0x11f4c9('0x149e')]=_0x11f4c9('0x2127')+_0x4ccf2b[_0x11f4c9('0x2681')][_0x11f4c9('0x710')]+_0x11f4c9('0x9b7')+_0x4ccf2b[_0x11f4c9('0x2681')]['id']+_0x11f4c9('0xdfd')+_0x4ccf2b[_0x11f4c9('0x2681')][_0x11f4c9('0x25da')]+_0x11f4c9('0x9d6'),_0x4ccf2b['end']='\x0a';}_0x47a12a[_0x1a67f7('0x186d')](_0x1a67f7('0xeaf'),function(){const _0x4b0ff2=_0x1a67f7;_0x4ccf2b[_0x4b0ff2('0x149e')]=_0x4b0ff2('0x2127')+_0x4ccf2b[_0x4b0ff2('0x2681')][_0x4b0ff2('0x710')]+_0x4b0ff2('0x9b7')+_0x4ccf2b[_0x4b0ff2('0x2681')]['id']+'/snippet?token='+_0x4ccf2b[_0x4b0ff2('0x2681')][_0x4b0ff2('0x25da')]+_0x4b0ff2('0x9d6');});}const _0x5a10be=_0x3bd50f;_0x2690ba[_0x189033('0x14be')]=[_0x189033('0x17e4'),'toasty'];function _0x2690ba(_0x21465d,_0xb34e2e){const _0x96a698=_0x189033,_0xd9e95a=this,_0x10282d=0x8,_0x357aa8=_0x10282d*0x400*0x400;_0xd9e95a['chatWebsite']={},_0xd9e95a[_0x96a698('0x1134')],_0xd9e95a[_0x96a698('0x8f')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x357aa8,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0xd9e95a[_0x96a698('0x1fa6')]={'flow':{}},_0xd9e95a[_0x96a698('0xfbe')]=![],_0xd9e95a[_0x96a698('0x1aad')]=_0x2e8c27,_0xd9e95a[_0x96a698('0xa03')]=_0x5a3b41,_0xd9e95a[_0x96a698('0x1152')]=_0x3d914a,_0xd9e95a[_0x96a698('0x12f3')]=_0x488e3c;function _0x488e3c(_0x156edd,_0x4faa2d){const _0x5d6f03=_0x96a698;_0xd9e95a[_0x5d6f03('0x2681')]=angular['copy'](_0x156edd),_0xd9e95a['crudPermissions']=typeof _0x4faa2d!==_0x5d6f03('0x1867')?_0x4faa2d:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0xd9e95a[_0x5d6f03('0x8f')][_0x5d6f03('0x568')]=_0x5d6f03('0x6bf')[_0x5d6f03('0x1725')](_0x5d6f03('0x10f1'),_0xd9e95a['chatWebsite']['id']),_0xd9e95a[_0x5d6f03('0x2681')][_0x5d6f03('0x2668')]=[];}function _0x2e8c27(_0x2051d4){const _0x83ca53=_0x96a698,_0x35734d=[_0x83ca53('0x21ec'),_0x83ca53('0x159c')];if(!_0x2e3ca0()[_0x83ca53('0x2292')](_0x35734d,_0x2051d4[_0x83ca53('0x1197')]()))return _0xb34e2e[_0x83ca53('0x52a')]({'title':_0x83ca53('0xa00')+_0x2051d4[_0x83ca53('0x1197')](),'msg':_0x83ca53('0x2560')+_0x35734d[_0x83ca53('0x1630')]()}),![];if(_0x2051d4[_0x83ca53('0x1a41')]>_0x357aa8)return _0xb34e2e['error']({'title':_0x83ca53('0x19a2'),'msg':'The\x20max\x20allowed\x20size\x20is\x20'+_0x10282d+'MB'}),![];const _0x257eb5={'id':_0x2051d4[_0x83ca53('0x2379')],'file':_0x2051d4,'type':_0x83ca53('0x132')};return _0xd9e95a[_0x83ca53('0x2681')][_0x83ca53('0x2668')][_0x83ca53('0x1167')](_0x257eb5),!![];}function _0x5a3b41(){const _0x59e00a=_0x96a698;_0xd9e95a[_0x59e00a('0x1fa6')]['flow'][_0x59e00a('0x2810')][_0x59e00a('0xb7d')]={'X-Requested-With':'XMLHttpRequest','Authorization':_0x59e00a('0x189e')+_0x21465d[_0x59e00a('0x1e6e')](_0x59e00a('0x555'))},_0xd9e95a['ngFlow'][_0x59e00a('0x190a')][_0x59e00a('0xa03')]();}function _0x3d914a(_0x3b7fa0){const _0x2bead0=_0x96a698;angular[_0x2bead0('0x1299')](_0xd9e95a[_0x2bead0('0x2681')][_0x2bead0('0x2668')],function(_0x50b650){const _0x19deae=_0x2bead0;if(_0x50b650['id']===_0x3b7fa0[_0x19deae('0x2379')]){const _0x230988=new FileReader();_0x230988['readAsDataURL'](_0x50b650[_0x19deae('0x21dd')][_0x19deae('0x21dd')]),_0x230988[_0x19deae('0x43b')]=function(_0x5500a9){const _0x55ca61=_0x19deae;_0x50b650[_0x55ca61('0x1284')]=_0x5500a9[_0x55ca61('0x568')][_0x55ca61('0x7c9')];},_0x50b650[_0x19deae('0xcf0')]='image';}});}}const _0x4c1cab=_0x2690ba;_0x598537[_0x189033('0x14be')]=['$state',_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),'setting',_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),'chatWebsite',_0x189033('0x22df')];function _0x598537(_0x16376c,_0x3dc661,_0x39fe43,_0x44e3fa,_0x1f7023,_0x330e91,_0x4c0a4b,_0x297a7d,_0x18c9e8,_0x46ad12,_0x340fab,_0x171238){const _0x2e1df2=_0x189033,_0x1f64d9=this;_0x1f64d9[_0x2e1df2('0x11ed')]=_0x46ad12['getCurrentUser'](),_0x1f64d9[_0x2e1df2('0xace')]=_0x330e91,_0x1f64d9[_0x2e1df2('0x260a')]=_0x4c0a4b,_0x1f64d9['passwordPattern']=_0x1f64d9[_0x2e1df2('0x260a')][_0x2e1df2('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1f64d9[_0x2e1df2('0x1224')]=_0x3dc661[_0x2e1df2('0x173e')]()+_0x2e1df2('0x20de')+_0x3dc661[_0x2e1df2('0x19ac')](),_0x1f64d9[_0x2e1df2('0x2681')]=_0x340fab||_0x16376c[_0x2e1df2('0x7f2')][_0x2e1df2('0x2681')]||{},_0x1f64d9['userProfileSection']=_0x171238&&_0x171238['count']==0x1?_0x171238[_0x2e1df2('0xf5d')][0x0]:null,_0x1f64d9[_0x2e1df2('0x1134')]=_0x46ad12[_0x2e1df2('0x142a')](_0x1f64d9[_0x2e1df2('0x22df')]?_0x1f64d9[_0x2e1df2('0x22df')]['crudPermissions']:null),_0x1f64d9[_0x2e1df2('0x258d')]={},_0x1f64d9[_0x2e1df2('0x517')]=_0x16376c[_0x2e1df2('0x7f2')]['tab']||0x0,_0x1f64d9['agentadddialog']=_0x5939c9,_0x1f64d9[_0x2e1df2('0x2430')]=_0x18c9e8[_0x2e1df2('0x2289')],_0x1f64d9[_0x2e1df2('0x23f4')]=_0x2e0a4f,_0x1f64d9[_0x2e1df2('0x25b0')]=_0x39d8ab,_0x46ad12[_0x2e1df2('0xca1')](_0x2e1df2('0x20c2'))?_0x297a7d['cmList']['get']({'fields':'id,name','sort':_0x2e1df2('0x60a')})[_0x2e1df2('0xe53')][_0x2e1df2('0x683')](function(_0xa7325d){const _0x56e61e=_0x2e1df2;_0x1f64d9['lists']=_0xa7325d[_0x56e61e('0xf5d')]||[];})[_0x2e1df2('0x130a')](function(_0x8c03bd){const _0x176f44=_0x2e1df2;_0x18c9e8[_0x176f44('0x52a')]({'title':_0x8c03bd['status']?_0x176f44('0x2168')+_0x8c03bd[_0x176f44('0x13ee')]+_0x176f44('0xbf6')+_0x8c03bd[_0x176f44('0x24a9')]:'SYSTEM:GET_LISTS','msg':_0x8c03bd[_0x176f44('0x5a5')]?JSON['stringify'](_0x8c03bd[_0x176f44('0x5a5')]):_0x8c03bd['toString']()});}):_0x297a7d['cmList'][_0x2e1df2('0x1e6e')]({'fields':_0x2e1df2('0xa10'),'sort':'name'})[_0x2e1df2('0xe53')][_0x2e1df2('0x683')](function(_0x1cf70f){const _0x5bbf9a=_0x2e1df2;_0x1f64d9[_0x5bbf9a('0xe01')]=_0x1cf70f[_0x5bbf9a('0xf5d')]||[];})[_0x2e1df2('0x683')](function(){const _0x17eb77=_0x2e1df2;return _0x297a7d[_0x17eb77('0x22df')][_0x17eb77('0x1e6e')]({'userProfileId':_0x1f64d9['currentUser'][_0x17eb77('0x2f')],'sectionId':0x12d})[_0x17eb77('0xe53')];})[_0x2e1df2('0x683')](function(_0x518f1d){const _0x24fad5=_0x2e1df2,_0x39bfec=_0x518f1d&&_0x518f1d['rows']?_0x518f1d[_0x24fad5('0xf5d')][0x0]:null;if(!_0x39bfec){const _0x99f06a=[];let _0x187d2f=null;_0x1f64d9[_0x24fad5('0x2681')]&&(_0x187d2f=_0x2e3ca0()[_0x24fad5('0x1c07')](_0x1f64d9['lists'],{'id':Number(_0x1f64d9['chatWebsite'][_0x24fad5('0x1e4f')])}));for(let _0x42d228=0x0;_0x42d228<_0x1f64d9['lists'][_0x24fad5('0x1564')];_0x42d228++){_0x187d2f&&_0x1f64d9['lists'][_0x42d228]['id']===_0x187d2f['id']&&(_0x1f64d9[_0x24fad5('0xe01')][_0x42d228]['canSelect']=![],_0x99f06a[_0x24fad5('0x1fd0')](_0x1f64d9['lists'][_0x42d228]));}_0x1f64d9[_0x24fad5('0xe01')]=_0x99f06a;}else{if(!_0x39bfec['autoAssociation'])return _0x297a7d['userProfileResource'][_0x24fad5('0x1e6e')]({'sectionId':_0x39bfec['id']})['$promise'][_0x24fad5('0x683')](function(_0x2bf382){const _0x2e9312=_0x24fad5,_0x248914=_0x2e3ca0()['map'](_0x2bf382[_0x2e9312('0xf5d')],function(_0x1e19f0){const _0x19d901=_0x2e9312;return _0x2e3ca0()[_0x19d901('0x1c07')](_0x1f64d9[_0x19d901('0xe01')],{'id':_0x1e19f0[_0x19d901('0x832')]});});let _0x275769=null;_0x1f64d9[_0x2e9312('0x2681')]&&(_0x275769=_0x2e3ca0()[_0x2e9312('0x1c07')](_0x1f64d9[_0x2e9312('0xe01')],{'id':Number(_0x1f64d9[_0x2e9312('0x2681')][_0x2e9312('0x1e4f')])}));if(_0x275769&&!_0x2e3ca0()['some'](_0x248914,['id',_0x275769['id']])){const _0x4cefec=_0x2e3ca0()['find'](_0x1f64d9['lists'],{'id':_0x275769['id']});_0x4cefec[_0x2e9312('0x319')]=![],_0x248914[_0x2e9312('0x1fd0')](_0x4cefec);}_0x1f64d9['lists']=_0x248914;});}})[_0x2e1df2('0x130a')](function(_0x261fa5){const _0x568449=_0x2e1df2;_0x18c9e8[_0x568449('0x52a')]({'title':_0x261fa5[_0x568449('0x13ee')]?'API:'+_0x261fa5['status']+_0x568449('0xbf6')+_0x261fa5['statusText']:'SYSTEM:GETlists','msg':_0x261fa5[_0x568449('0x5a5')]?JSON[_0x568449('0x258a')](_0x261fa5[_0x568449('0x5a5')]):_0x261fa5[_0x568449('0x1ff0')]()});}),_0x46ad12['hasRole'](_0x2e1df2('0x20c2'))?_0x297a7d['interval'][_0x2e1df2('0x1e6e')]({'fields':_0x2e1df2('0xa10'),'sort':'name','IntervalId':_0x2e1df2('0x13c')})[_0x2e1df2('0xe53')][_0x2e1df2('0x683')](function(_0x3a516e){const _0x499585=_0x2e1df2;_0x1f64d9[_0x499585('0x115c')]=_0x3a516e[_0x499585('0xf5d')]||[];})[_0x2e1df2('0x130a')](function(_0x583b52){const _0x248695=_0x2e1df2;_0x18c9e8['error']({'title':_0x583b52[_0x248695('0x13ee')]?_0x248695('0x2168')+_0x583b52[_0x248695('0x13ee')]+_0x248695('0xbf6')+_0x583b52['statusText']:_0x248695('0x27e3'),'msg':_0x583b52[_0x248695('0x5a5')]?JSON[_0x248695('0x258a')](_0x583b52[_0x248695('0x5a5')]):_0x583b52[_0x248695('0x1ff0')]()});}):_0x297a7d[_0x2e1df2('0x115c')][_0x2e1df2('0x1e6e')]({'fields':_0x2e1df2('0xa10'),'sort':_0x2e1df2('0x60a'),'IntervalId':'null'})['$promise'][_0x2e1df2('0x683')](function(_0x53a7f0){const _0x5a3207=_0x2e1df2;_0x1f64d9[_0x5a3207('0x115c')]=_0x53a7f0['rows']||[];})[_0x2e1df2('0x683')](function(){const _0x14acdc=_0x2e1df2;return _0x297a7d[_0x14acdc('0x22df')]['get']({'userProfileId':_0x1f64d9['currentUser'][_0x14acdc('0x2f')],'sectionId':0x3ec})[_0x14acdc('0xe53')];})[_0x2e1df2('0x683')](function(_0x47cecb){const _0x5d62ff=_0x2e1df2,_0x2a1853=_0x47cecb&&_0x47cecb['rows']?_0x47cecb[_0x5d62ff('0xf5d')][0x0]:null;if(!_0x2a1853){const _0x4fd542=[];let _0x1486b9=null;_0x1f64d9[_0x5d62ff('0x2681')]&&(_0x1486b9=_0x2e3ca0()[_0x5d62ff('0x1c07')](_0x1f64d9[_0x5d62ff('0x115c')],{'id':Number(_0x1f64d9[_0x5d62ff('0x2681')][_0x5d62ff('0x5ae')])}));for(let _0x4aa8e0=0x0;_0x4aa8e0<_0x1f64d9[_0x5d62ff('0x115c')][_0x5d62ff('0x1564')];_0x4aa8e0++){_0x1486b9&&_0x1f64d9[_0x5d62ff('0x115c')][_0x4aa8e0]['id']===_0x1486b9['id']&&(_0x1f64d9['interval'][_0x4aa8e0][_0x5d62ff('0x319')]=![],_0x4fd542['push'](_0x1f64d9[_0x5d62ff('0x115c')][_0x4aa8e0]));}_0x1f64d9['interval']=_0x4fd542;}else{if(!_0x2a1853['autoAssociation'])return _0x297a7d['userProfileResource'][_0x5d62ff('0x1e6e')]({'sectionId':_0x2a1853['id']})[_0x5d62ff('0xe53')][_0x5d62ff('0x683')](function(_0xb41afd){const _0x176a62=_0x5d62ff,_0x485c0c=_0x2e3ca0()['map'](_0xb41afd[_0x176a62('0xf5d')],function(_0x188cad){const _0x21acfa=_0x176a62;return _0x2e3ca0()[_0x21acfa('0x1c07')](_0x1f64d9[_0x21acfa('0x115c')],{'id':_0x188cad['resourceId']});});let _0x2eaba9=null;_0x1f64d9[_0x176a62('0x2681')]&&(_0x2eaba9=_0x2e3ca0()[_0x176a62('0x1c07')](_0x1f64d9[_0x176a62('0x115c')],{'id':Number(_0x1f64d9[_0x176a62('0x2681')][_0x176a62('0x5ae')])}));if(_0x2eaba9&&!_0x2e3ca0()[_0x176a62('0x7a2')](_0x485c0c,['id',_0x2eaba9['id']])){const _0x1300a8=_0x2e3ca0()['find'](_0x1f64d9[_0x176a62('0x115c')],{'id':_0x2eaba9['id']});_0x1300a8[_0x176a62('0x319')]=![],_0x485c0c[_0x176a62('0x1fd0')](_0x1300a8);}_0x1f64d9[_0x176a62('0x115c')]=_0x485c0c;});}})[_0x2e1df2('0x130a')](function(_0x465151){const _0x33a138=_0x2e1df2;_0x18c9e8['error']({'title':_0x465151[_0x33a138('0x13ee')]?_0x33a138('0x2168')+_0x465151[_0x33a138('0x13ee')]+'\x20-\x20'+_0x465151['statusText']:'SYSTEM:GETinterval','msg':_0x465151[_0x33a138('0x5a5')]?JSON[_0x33a138('0x258a')](_0x465151[_0x33a138('0x5a5')]):_0x465151[_0x33a138('0x1ff0')]()});}),_0x46ad12[_0x2e1df2('0xca1')]('admin')?_0x297a7d['pause']['get']({'fields':_0x2e1df2('0x1688'),'sort':_0x2e1df2('0x60a'),'nolimit':_0x2e1df2('0x26ac')})['$promise'][_0x2e1df2('0x683')](function(_0x232b41){const _0x40934a=_0x2e1df2;_0x1f64d9[_0x40934a('0x22ab')]=_0x232b41[_0x40934a('0xf5d')]||[];})[_0x2e1df2('0x130a')](function(_0x57497a){const _0x458dc7=_0x2e1df2;_0x18c9e8[_0x458dc7('0x52a')]({'title':_0x57497a[_0x458dc7('0x13ee')]?'API:'+_0x57497a[_0x458dc7('0x13ee')]+_0x458dc7('0xbf6')+_0x57497a[_0x458dc7('0x24a9')]:_0x458dc7('0x4ba'),'msg':_0x57497a['data']?JSON[_0x458dc7('0x258a')](_0x57497a[_0x458dc7('0x5a5')]):_0x57497a[_0x458dc7('0x1ff0')]()});}):_0x297a7d['pause'][_0x2e1df2('0x1e6e')]({'fields':_0x2e1df2('0x1688'),'sort':'name','nolimit':_0x2e1df2('0x26ac')})[_0x2e1df2('0xe53')][_0x2e1df2('0x683')](function(_0x4d686c){const _0x43378b=_0x2e1df2;_0x1f64d9[_0x43378b('0x22ab')]=_0x4d686c[_0x43378b('0xf5d')]||[];})[_0x2e1df2('0x683')](function(){const _0x4cb77e=_0x2e1df2;return _0x297a7d['userProfileSection'][_0x4cb77e('0x1e6e')]({'userProfileId':_0x1f64d9[_0x4cb77e('0x11ed')][_0x4cb77e('0x2f')],'sectionId':0x3ed})[_0x4cb77e('0xe53')];})['then'](function(_0x2e81e6){const _0x7b55f1=_0x2e1df2,_0x197a56=_0x2e81e6&&_0x2e81e6[_0x7b55f1('0xf5d')]?_0x2e81e6['rows'][0x0]:null;if(!_0x197a56)_0x1f64d9[_0x7b55f1('0x22ab')]=[];else{if(!_0x197a56[_0x7b55f1('0x170')])return _0x297a7d[_0x7b55f1('0xcf7')]['get']({'sectionId':_0x197a56['id']})[_0x7b55f1('0xe53')]['then'](function(_0x42dd8b){const _0x30595e=_0x7b55f1,_0x1c0c4a=_0x2e3ca0()['map'](_0x42dd8b[_0x30595e('0xf5d')],function(_0x44f9b5){const _0x4ec0cf=_0x30595e;return _0x2e3ca0()['find'](_0x1f64d9[_0x4ec0cf('0x22ab')],{'id':_0x44f9b5[_0x4ec0cf('0x832')]});});_0x1f64d9['pauses'][_0x30595e('0x1299')](function(_0x45c75b){const _0x7126ae=_0x30595e;!_0x2e3ca0()[_0x7126ae('0x7a2')](_0x1c0c4a,['id',_0x45c75b['id']])&&(_0x45c75b['canSelect']=![]),_0x1c0c4a['push'](_0x45c75b);}),_0x1f64d9['pauses']=_0x1c0c4a;});}})[_0x2e1df2('0x130a')](function(_0x17b27d){const _0x3d80c9=_0x2e1df2;_0x18c9e8[_0x3d80c9('0x52a')]({'title':_0x17b27d[_0x3d80c9('0x13ee')]?'API:'+_0x17b27d[_0x3d80c9('0x13ee')]+_0x3d80c9('0xbf6')+_0x17b27d[_0x3d80c9('0x24a9')]:_0x3d80c9('0xc45'),'msg':_0x17b27d[_0x3d80c9('0x5a5')]?JSON[_0x3d80c9('0x258a')](_0x17b27d[_0x3d80c9('0x5a5')]):_0x17b27d[_0x3d80c9('0x1ff0')]()});});function _0x5939c9(_0x2e4194,_0x325d23){const _0x20f68c=_0x2e1df2;_0x39fe43[_0x20f68c('0x1d4')]({'controller':_0x20f68c('0x465'),'controllerAs':'vm','templateUrl':_0x2c9b33,'parent':angular[_0x20f68c('0x1fcc')](_0x44e3fa[_0x20f68c('0x18e5')]),'targetEvent':_0x325d23,'clickOutsideToClose':!![],'locals':{'chatWebsite':_0x2e4194,'chatWebsites':_0x1f64d9[_0x20f68c('0x25a1')]?_0x1f64d9[_0x20f68c('0x25a1')]['rows']:[],'crudPermissions':_0x1f64d9[_0x20f68c('0x1134')],'realtime':![]}});}function _0x2e0a4f(){const _0x28e970=_0x2e1df2;_0x16376c['go'](_0x28e970('0x1a78'),{},{'reload':'app.chat.chatWebsites'});}function _0x39d8ab(){const _0x3d130f=_0x2e1df2;_0x297a7d[_0x3d130f('0x2681')][_0x3d130f('0x2480')]({'id':_0x1f64d9['chatWebsite']['id']},_0x1f64d9[_0x3d130f('0x2681')])['$promise'][_0x3d130f('0x683')](function(){const _0x289d10=_0x3d130f;_0x18c9e8[_0x289d10('0x53')]({'title':_0x289d10('0x7c'),'msg':_0x1f64d9[_0x289d10('0x2681')][_0x289d10('0x60a')]?_0x1f64d9[_0x289d10('0x2681')][_0x289d10('0x60a')]+'\x20has\x20been\x20updated!':''});})[_0x3d130f('0x130a')](function(_0x213cc7){const _0x4e5491=_0x3d130f;_0x18c9e8[_0x4e5491('0x52a')]({'title':_0x213cc7['status']?_0x4e5491('0x2168')+_0x213cc7['status']+_0x4e5491('0xbf6')+_0x213cc7[_0x4e5491('0x24a9')]:_0x4e5491('0xd27'),'msg':_0x213cc7['data']?JSON[_0x4e5491('0x258a')](_0x213cc7[_0x4e5491('0x5a5')]):_0x213cc7[_0x4e5491('0x1ff0')]()});});}}const _0x2c613e=_0x598537;_0x22b8bd['$inject']=[_0x189033('0x1398'),'$translatePartialLoaderProvider'];function _0x22b8bd(_0xfbd7de,_0x4bcc32){const _0x184e84=_0x189033;_0xfbd7de[_0x184e84('0x2598')](_0x184e84('0xb14'),{'abstract':!![],'url':_0x184e84('0x13ca')})['state'](_0x184e84('0x23c4'),{'url':'/chatQueues','views':{'content@app':{'templateUrl':_0x303764,'controller':_0x184e84('0x5e')}},'resolve':{'chatQueues':[_0x184e84('0x4b1'),'Auth',function(_0x1e9ee8,_0x4061d7){const _0x31044f=_0x184e84;return _0x4061d7[_0x31044f('0xca1')](_0x31044f('0x20c2'))?_0x1e9ee8[_0x31044f('0xed7')]('chatQueue@get',{'fields':_0x31044f('0x1b67'),'sort':_0x31044f('0xc36'),'channel':_0x31044f('0x24e'),'limit':0xa,'offset':0x0}):_0x1e9ee8[_0x31044f('0xed7')](_0x31044f('0x191b'),{'id':_0x4061d7['getCurrentUser']()[_0x31044f('0x2f')],'section':_0x31044f('0x507'),'fields':_0x31044f('0x1b67'),'sort':_0x31044f('0xc36'),'channel':_0x31044f('0x24e'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x184e84('0xba1'),function(_0x57d0ea,_0x5978bb){const _0x337a8a=_0x184e84;return _0x5978bb[_0x337a8a('0xca1')]('admin')?null:_0x57d0ea[_0x337a8a('0xed7')]('userProfile@get',{'fields':_0x337a8a('0x16f'),'id':_0x5978bb[_0x337a8a('0x20b2')]()[_0x337a8a('0x2f')]});}],'userProfileSection':[_0x184e84('0x4b1'),_0x184e84('0xba1'),function(_0x17119b,_0x2f5f5b){const _0x3aee45=_0x184e84;return _0x2f5f5b[_0x3aee45('0xca1')](_0x3aee45('0x20c2'))?null:_0x17119b[_0x3aee45('0xed7')]('userProfileSection@get',{'fields':_0x3aee45('0x1f47'),'userProfileId':_0x2f5f5b[_0x3aee45('0x20b2')]()['userProfileId'],'sectionId':0x1f5});}]},'authenticate':!![],'permissionId':0x1f5,'bodyClass':'chat'})['state'](_0x184e84('0x225f'),{'url':'/:id?tab','params':{'chatQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x2897a7,'controller':_0x184e84('0x2cd')}},'resolve':{'chatQueue':[_0x184e84('0x4b1'),_0x184e84('0x8ea'),function(_0x3dfd77,_0x1cc9ab){const _0x31d51f=_0x184e84;return _0x3dfd77[_0x31d51f('0xed7')](_0x31d51f('0x974'),{'fields':_0x31d51f('0x1b67'),'id':_0x1cc9ab['id']});}],'userProfileSection':[_0x184e84('0x4b1'),_0x184e84('0xba1'),function(_0x112a59,_0x26b194){const _0x3b396f=_0x184e84;return _0x112a59[_0x3b396f('0xed7')](_0x3b396f('0x360'),{'fields':_0x3b396f('0x1f47'),'userProfileId':_0x26b194[_0x3b396f('0x20b2')]()[_0x3b396f('0x2f')],'sectionId':0x1f5});}]},'authenticate':!![],'permissionId':0x1f5,'bodyClass':'chat'})[_0x184e84('0x2598')](_0x184e84('0x1a78'),{'url':_0x184e84('0x25f7'),'views':{'content@app':{'templateUrl':_0x4cc511,'controller':_0x184e84('0x25a')}},'resolve':{'chatWebsites':[_0x184e84('0x4b1'),'Auth',function(_0x413846,_0xfcd6a2){const _0x3060ec=_0x184e84;return _0xfcd6a2[_0x3060ec('0xca1')](_0x3060ec('0x20c2'))?_0x413846[_0x3060ec('0xed7')](_0x3060ec('0x5af'),{'fields':'createdAt,updatedAt,id,token,agentIdentifier,customerAlias,messageFontSize,name,key,address,remote,ListId,fidelity,timeout,agentAlias,closingQuestion,formSubmitSuccessMessage,formSubmitFailureMessage,color,color_focus,color_button,textColor,backgroundColor,fontSize,header_shape,showAgentAvatar,showCustomerAvatar,alignment,verticalAlignment,messagesAlignment,defaultTitle,animation,defaultWhiteLabel,whiteLabel,defaultLogo,conditionAgreement,autoclose,enableUnmanagedNote,unmanagedMessage,skipUnmanaged,sendUnmanaged,enableCustomerWriting,waitingTitle,waitingMessage,closingMessage,noteTitle,placeholderMessage,skipMessageButton,enableRating,ratingType,ratingStarsNumber,enableFeedback,feedbackTitle,forwardTranscript,forwardTranscriptMessage,closingMessageButton,download_transcript,enableCustomerAttachment,enableSendButton,enableCustomerCheckmarks,systemAlias,enquiry_enable,enquiry_forwarding,enquiry_forwarding_address,name_title,username_placeholder,email_title,email_placeholder,header_online,hideWhenOffline,header_offline,start_chat_button,offline_chat_button,offlineMessageSubject,offlineMessageBody,offline_message,message_title,enquiry_message_placeholder,enquiry_button,rating_message,rating_send,rating_skip,onlineForm,offlineForm,mapKey,mapKeyOffline,forwardOffline,forwardOfflineAddress,IntervalId,timezone,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout,vidaooEscalation,vidaooApiKey','sort':_0x3060ec('0xc36'),'limit':0xa,'offset':0x0}):_0x413846['resolve'](_0x3060ec('0x191b'),{'id':_0xfcd6a2[_0x3060ec('0x20b2')]()[_0x3060ec('0x2f')],'section':_0x3060ec('0x1a18'),'fields':'createdAt,updatedAt,id,token,agentIdentifier,customerAlias,messageFontSize,name,key,address,remote,ListId,fidelity,timeout,agentAlias,closingQuestion,formSubmitSuccessMessage,formSubmitFailureMessage,color,color_focus,color_button,textColor,backgroundColor,fontSize,header_shape,showAgentAvatar,showCustomerAvatar,alignment,verticalAlignment,messagesAlignment,defaultTitle,animation,defaultWhiteLabel,whiteLabel,defaultLogo,conditionAgreement,autoclose,enableUnmanagedNote,unmanagedMessage,skipUnmanaged,sendUnmanaged,enableCustomerWriting,waitingTitle,waitingMessage,closingMessage,noteTitle,placeholderMessage,skipMessageButton,enableRating,ratingType,ratingStarsNumber,enableFeedback,feedbackTitle,forwardTranscript,forwardTranscriptMessage,closingMessageButton,download_transcript,enableCustomerAttachment,enableSendButton,enableCustomerCheckmarks,systemAlias,enquiry_enable,enquiry_forwarding,enquiry_forwarding_address,name_title,username_placeholder,email_title,email_placeholder,header_online,hideWhenOffline,header_offline,start_chat_button,offline_chat_button,offlineMessageSubject,offlineMessageBody,offline_message,message_title,enquiry_message_placeholder,enquiry_button,rating_message,rating_send,rating_skip,onlineForm,offlineForm,mapKey,mapKeyOffline,forwardOffline,forwardOfflineAddress,IntervalId,timezone,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout,vidaooEscalation,vidaooApiKey','sort':_0x3060ec('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x184e84('0x4b1'),_0x184e84('0xba1'),function(_0x45e5ad,_0x2a7e49){const _0x5c5bef=_0x184e84;return _0x2a7e49[_0x5c5bef('0xca1')](_0x5c5bef('0x20c2'))?null:_0x45e5ad[_0x5c5bef('0xed7')](_0x5c5bef('0x1464'),{'fields':_0x5c5bef('0x16f'),'id':_0x2a7e49[_0x5c5bef('0x20b2')]()[_0x5c5bef('0x2f')]});}],'userProfileSection':['apiResolver',_0x184e84('0xba1'),function(_0x439136,_0x449d9d){const _0x550ec0=_0x184e84;return _0x449d9d['hasRole']('admin')?null:_0x439136[_0x550ec0('0xed7')](_0x550ec0('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x449d9d[_0x550ec0('0x20b2')]()['userProfileId'],'sectionId':0x1f6});}]},'authenticate':!![],'permissionId':0x1f6,'bodyClass':_0x184e84('0x24e')})['state']('app.chat.chatWebsites.edit',{'url':_0x184e84('0x1560'),'params':{'chatWebsite':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x53c5fb,'controller':_0x184e84('0xb66')}},'resolve':{'chatWebsite':['apiResolver','$stateParams',function(_0x4b5b06,_0x2a6c67){const _0x2498bc=_0x184e84;return _0x4b5b06[_0x2498bc('0xed7')](_0x2498bc('0x5af'),{'fields':'createdAt,updatedAt,id,token,agentIdentifier,customerAlias,messageFontSize,name,key,address,remote,ListId,fidelity,timeout,agentAlias,closingQuestion,formSubmitSuccessMessage,formSubmitFailureMessage,color,color_focus,color_button,textColor,backgroundColor,fontSize,header_shape,showAgentAvatar,showCustomerAvatar,alignment,verticalAlignment,messagesAlignment,defaultTitle,animation,defaultWhiteLabel,whiteLabel,defaultLogo,conditionAgreement,autoclose,enableUnmanagedNote,unmanagedMessage,skipUnmanaged,sendUnmanaged,enableCustomerWriting,waitingTitle,waitingMessage,closingMessage,noteTitle,placeholderMessage,skipMessageButton,enableRating,ratingType,ratingStarsNumber,enableFeedback,feedbackTitle,forwardTranscript,forwardTranscriptMessage,closingMessageButton,download_transcript,enableCustomerAttachment,enableSendButton,enableCustomerCheckmarks,systemAlias,enquiry_enable,enquiry_forwarding,enquiry_forwarding_address,name_title,username_placeholder,email_title,email_placeholder,header_online,hideWhenOffline,header_offline,start_chat_button,offline_chat_button,offlineMessageSubject,offlineMessageBody,offline_message,message_title,enquiry_message_placeholder,enquiry_button,rating_message,rating_send,rating_skip,onlineForm,offlineForm,mapKey,mapKeyOffline,forwardOffline,forwardOfflineAddress,IntervalId,timezone,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout,vidaooEscalation,vidaooApiKey','id':_0x2a6c67['id']});}],'userProfileSection':[_0x184e84('0x4b1'),_0x184e84('0xba1'),function(_0xd1290d,_0x4ac791){const _0x31cd94=_0x184e84;return _0xd1290d['resolve']('userProfileSection@get',{'fields':_0x31cd94('0x1f47'),'userProfileId':_0x4ac791[_0x31cd94('0x20b2')]()[_0x31cd94('0x2f')],'sectionId':0x1f6});}]},'authenticate':!![],'permissionId':0x1f6,'bodyClass':_0x184e84('0x24e')}),_0x4bcc32[_0x184e84('0x7d2')](_0x184e84('0x181f'));}angular[_0x189033('0x1e26')](_0x189033('0xb14'),['ngCsv',_0x189033('0x1ddb'),'md.data.table',_0x189033('0x190a'),'mdColorPicker',_0x189033('0x2835'),'ng-sortable',_0x189033('0x2609'),_0x189033('0x273d'),_0x189033('0x76'),_0x189033('0x516'),'mwFormViewer',_0x189033('0x197b'),_0x189033('0x3b5'),'angular-cron-jobs','ngEmbed',_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),'angular.filter',_0x189033('0x10ee')])['config'](_0x22b8bd)[_0x189033('0x1da3')](_0x189033('0xefb'),_0xdb06d6)[_0x189033('0x1da3')](_0x189033('0xcb6'),_0x55024c)[_0x189033('0x1da3')](_0x189033('0x1062'),_0x12b88f)['controller'](_0x189033('0x885'),_0x51f73b)[_0x189033('0x1da3')](_0x189033('0xe40'),_0x40b128)['controller'](_0x189033('0x4aa'),_0x58baa3)[_0x189033('0x1da3')](_0x189033('0x17d1'),_0x328fdf)['controller'](_0x189033('0x10aa'),_0x3f5f3c)[_0x189033('0x1da3')](_0x189033('0x465'),_0xbee715)[_0x189033('0x1da3')](_0x189033('0x122'),_0x281f5a)[_0x189033('0x1da3')](_0x189033('0x1b86'),_0xef177a)[_0x189033('0x1da3')](_0x189033('0x1c96'),_0xf8092)[_0x189033('0x1da3')](_0x189033('0x1c96'),_0xf8092)[_0x189033('0x1da3')](_0x189033('0x2096'),_0x403279)[_0x189033('0x1da3')]('EditChatWebsiteAppcloseDialogController',_0x4b796f)[_0x189033('0x1da3')](_0x189033('0x283d'),_0x27e349)[_0x189033('0x1da3')](_0x189033('0x24b3'),_0x633a85)['controller'](_0x189033('0x1ac3'),_0x6712a4)[_0x189033('0x1da3')](_0x189033('0x820'),_0x54e199)['controller'](_0x189033('0x1124'),_0x436139)[_0x189033('0x1da3')](_0x189033('0x1275'),_0x3adb53)[_0x189033('0x1da3')](_0x189033('0x11ee'),_0x5c93e2)[_0x189033('0x1da3')]('EditChatWebsiteApptagDialogController',_0x318c2e)[_0x189033('0x1da3')](_0x189033('0x151b'),_0x236b2f)[_0x189033('0x1da3')]('CreateOrEditChatCannedAnswerDialogController',_0x3ea1f1)[_0x189033('0x1da3')](_0x189033('0x125c'),_0x4f78ea)[_0x189033('0x1da3')](_0x189033('0x2d5'),_0x36d17e)['controller'](_0x189033('0xc25'),_0x47f3b5)[_0x189033('0x1da3')](_0x189033('0x174'),_0x150e09)[_0x189033('0x1da3')](_0x189033('0x125a'),_0x49f7cf)[_0x189033('0x1da3')](_0x189033('0x620'),_0x2e3637)['controller']('ChatWebsiteOfflineMessagesController',_0x59a958)[_0x189033('0x1da3')](_0x189033('0x1b8e'),_0x1c3aa6)[_0x189033('0x1da3')]('ChatWebsiteProactiveActionsController',_0xfa6b70)[_0x189033('0x1da3')]('CreateOrEditChatProactiveActionDialogController',_0x1c715a)[_0x189033('0x1da3')](_0x189033('0x15ab'),_0x5a10be)[_0x189033('0x1da3')](_0x189033('0x15d1'),_0x4c1cab)[_0x189033('0x1da3')]('ChatWebsiteController',_0x2c613e);const _0x3ca1e3=_0x180212['p']+'src/js/modules/main/apps/mail/views/realtime/realtime.html/realtime.html',_0xdd0f54=_0x180212['p']+_0x189033('0x12b6'),_0x5e76df=_0x180212['p']+_0x189033('0x9e8'),_0x10562e=_0x180212['p']+_0x189033('0x1d00');_0x43b137['$inject']=[_0x189033('0x7a5'),'$q',_0x189033('0x2f9'),_0x189033('0x1e48'),'$document',_0x189033('0x241e'),'pauses',_0x189033('0x756'),'rpcAgents',_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0xa72'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x1b27')];function _0x43b137(_0x3d091e,_0x468849,_0xae003a,_0x395d5a,_0x3ac0a8,_0x421b77,_0x42bfa9,_0xa59c54,_0xfd7693,_0x5af448,_0xe46079,_0x4ee8a4,_0x2440ec,_0x41d743,_0x3b1ad5,_0x3179b7,_0x3153dd,_0x2334b3){const _0xc767cc=_0x189033,_0x29e42b=this,_0x4c9e62=[_0xc767cc('0xef9'),_0xc767cc('0x2309'),_0xc767cc('0x10f'),_0xc767cc('0x8cc'),_0xc767cc('0x17fe'),_0xc767cc('0x8cc'),_0xc767cc('0x1d43'),_0xc767cc('0x2050'),_0xc767cc('0x1938'),_0xc767cc('0x1a11'),_0xc767cc('0x774'),_0xc767cc('0x1b89'),_0xc767cc('0x185d'),'faxPause',_0xc767cc('0x1431'),_0xc767cc('0xd2a'),_0xc767cc('0x218'),_0xc767cc('0x2409'),_0xc767cc('0x205'),_0xc767cc('0x1484'),'faxCapacity',_0xc767cc('0x153b'),'openchannelCurrentCapacity','mailCurrentCapacity',_0xc767cc('0x1902'),_0xc767cc('0xaba'),_0xc767cc('0x157f'),_0xc767cc('0x1487'),_0xc767cc('0x2a8'),_0xc767cc('0xb90'),'smsStatus',_0xc767cc('0x2512'),_0xc767cc('0x278b'),_0xc767cc('0x15e0'),_0xc767cc('0x1a03'),_0xc767cc('0x15db'),_0xc767cc('0xc07'),_0xc767cc('0x1a70'),_0xc767cc('0x17c2'),_0xc767cc('0x21d1'),_0xc767cc('0x23b4'),_0xc767cc('0x660'),'destconnectedlinenum',_0xc767cc('0xd70'),_0xc767cc('0xa31'),_0xc767cc('0x2259')],_0x38614c=[_0xc767cc('0x1938'),_0xc767cc('0x1a11'),_0xc767cc('0x774'),_0xc767cc('0x1b89'),_0xc767cc('0x185d'),_0xc767cc('0x716'),_0xc767cc('0x1431'),_0xc767cc('0x2309')];_0x29e42b[_0xc767cc('0x11ed')]=_0x3179b7[_0xc767cc('0x20b2')](),_0x29e42b[_0xc767cc('0x24d2')]=[_0xc767cc('0x2727'),_0xc767cc('0x5d7'),'busy',_0xc767cc('0x1026'),'not_inuse'],_0x29e42b[_0xc767cc('0x22ab')]=_0x42bfa9||{'count':0x0,'rows':[]},_0x29e42b[_0xc767cc('0xace')]=_0x3153dd,_0x29e42b[_0xc767cc('0x2a')]=_0x41d743,_0x29e42b['userProfileSection']=_0x3b1ad5&&_0x3b1ad5[_0xc767cc('0x50d')]==0x1?_0x3b1ad5['rows'][0x0]:null,_0x29e42b['crudPermissions']=_0x3179b7[_0xc767cc('0x142a')](_0x29e42b[_0xc767cc('0x22df')]?_0x29e42b[_0xc767cc('0x22df')][_0xc767cc('0x1134')]:null),_0x29e42b[_0xc767cc('0x756')]=_0xa59c54?_0x2e3ca0()[_0xc767cc('0x24db')](_0xa59c54[_0xc767cc('0xf5d')]?_0xa59c54[_0xc767cc('0xf5d')]:[],'id'):{},_0x29e42b[_0xc767cc('0x127b')]=_0xfd7693?_0x2e3ca0()[_0xc767cc('0x24db')](_0xfd7693[_0xc767cc('0xf5d')]?_0xfd7693[_0xc767cc('0xf5d')]:[],'id'):{},_0x29e42b['paginatedAgents']={},_0x29e42b[_0xc767cc('0x182c')]=![],_0x29e42b['order']=[],_0x29e42b['agentInternal']={};for(const _0x2ac832 in _0x29e42b[_0xc767cc('0x756')]){typeof _0x29e42b[_0xc767cc('0x756')][_0x2ac832]!=='undefined'&&(_0x29e42b[_0xc767cc('0x756')][_0x2ac832][_0xc767cc('0x12f3')]=!![]);}_0x29e42b[_0xc767cc('0x23a2')]={'limit':0xa,'page':0x1,'order':_0xc767cc('0x11bc'),'globalStatusFilter':'','pauseTypeFilter':''},_0x29e42b[_0xc767cc('0x1999')]=_0x1dd374,_0x29e42b['queueAdd']=_0x57444b,_0x29e42b[_0xc767cc('0xa4')]=_0x159ce5,_0x29e42b['unPause']=_0x58bed9,_0x29e42b[_0xc767cc('0x411')]=_0x3f3cb6,_0x29e42b[_0xc767cc('0x2d2')]=_0xbf90a1,_0x29e42b[_0xc767cc('0x1bf4')]=_0x1a2dd,_0x29e42b[_0xc767cc('0x3ee')]=_0x235867,_0x29e42b[_0xc767cc('0x2678')]=_0x35d78c,_0x29e42b[_0xc767cc('0x1f68')]=_0x36f927,_0x29e42b[_0xc767cc('0x2819')]=_0xae48aa,_0x29e42b[_0xc767cc('0x1418')]=_0x597ccc,_0x29e42b[_0xc767cc('0x1dd2')]=_0x4f8d48,_0x29e42b[_0xc767cc('0x16b6')]=_0xe8555c,_0x29e42b[_0xc767cc('0x2250')]=_0x161979,_0x29e42b[_0xc767cc('0x1f6c')]=_0xefdcb5,_0xe46079['on']('user:save',_0x29e42b[_0xc767cc('0x2819')]),_0xe46079['on']('user:update',_0x29e42b[_0xc767cc('0x1418')]),_0xe46079['on'](_0xc767cc('0x216d'),_0x29e42b[_0xc767cc('0x16b6')]),_0xe46079['on']('user:agentcomplete',_0x29e42b['onComplete']),_0x4f8d48();let _0x201c0e=_0x2334b3(function(){const _0x557cf0=_0xc767cc;_0x29e42b['load']&&(_0x29e42b[_0x557cf0('0x182c')]=![],_0x4f8d48());},0x3e7);function _0x4f8d48(){const _0x64c105=_0xc767cc;_0x29e42b[_0x64c105('0x182c')]=![];const _0x198d18=_0x468849['defer']();_0x29e42b[_0x64c105('0x1883')]=_0x198d18[_0x64c105('0x1883')],_0x29e42b[_0x64c105('0xdf9')]=[],_0x29e42b[_0x64c105('0x150d')]=[],_0x2e3ca0()['forIn'](_0x29e42b[_0x64c105('0x756')],function(_0x4f755c,_0x45fa3f){const _0xf5a23f=_0x64c105;_0x29e42b[_0xf5a23f('0x127b')][_0x45fa3f]&&_0x2e3ca0()[_0xf5a23f('0xf22')](_0x4f755c,_0x2e3ca0()['pick'](_0x2e3ca0()['omit'](_0x29e42b[_0xf5a23f('0x127b')][_0x45fa3f],_0x38614c),_0x4c9e62)),_0x1a2dd(_0x4f755c),_0x4f755c[_0xf5a23f('0x2309')]?(_0x29e42b['filteredAgents']['push'](_0x4f755c),_0x29e42b['agentInternal'][_0x4f755c[_0xf5a23f('0x1d43')]]=_0x45fa3f):_0x4f755c[_0xf5a23f('0x24d')]=_0x2e3ca0()[_0xf5a23f('0xea3')](_0x1aaf93()()['format']('x'));});_0x29e42b[_0x64c105('0x23a2')][_0x64c105('0x1102')]&&_0x2e3ca0()[_0x64c105('0x3ec')](_0x29e42b[_0x64c105('0xdf9')],function(_0x4cc096){const _0x15ec5f=_0x64c105;return _0x4cc096[_0x15ec5f('0x12fa')]!==_0x29e42b[_0x15ec5f('0x23a2')]['globalStatusFilter'];});_0x29e42b[_0x64c105('0x23a2')]['pauseTypeFilter']&&_0x2e3ca0()[_0x64c105('0x3ec')](_0x29e42b[_0x64c105('0xdf9')],function(_0x5bc37b){const _0x5cdb64=_0x64c105;return _0x5bc37b[_0x5cdb64('0x17fe')]!==_0x29e42b['query'][_0x5cdb64('0x1606')];});_0x29e42b['query']['filter']&&_0x2e3ca0()[_0x64c105('0x3ec')](_0x29e42b[_0x64c105('0xdf9')],function(_0x395d67){const _0x322b5d=_0x64c105;return _0x395d67['fullname'][_0x322b5d('0x93a')]()['indexOf'](_0x29e42b[_0x322b5d('0x23a2')][_0x322b5d('0x25')][_0x322b5d('0x93a')]())<0x0;});_0x29e42b['filteredAgents']=_0x200eb5(_0x29e42b[_0x64c105('0xdf9')]);const _0x20d935=(_0x29e42b[_0x64c105('0x23a2')][_0x64c105('0xdf8')]-0x1)*_0x29e42b['query'][_0x64c105('0x6f0')];_0x29e42b[_0x64c105('0x20d5')]=_0x2e3ca0()[_0x64c105('0x16b7')](_0x29e42b[_0x64c105('0xdf9')],_0x20d935)['slice'](0x0,_0x29e42b[_0x64c105('0x23a2')][_0x64c105('0x6f0')]);for(let _0x1865e0=0x0;_0x1865e0<_0x29e42b[_0x64c105('0x20d5')][_0x64c105('0x1564')];_0x1865e0+=0x1){_0x29e42b['order']['push'](_0x29e42b['paginatedAgents'][_0x1865e0]['id']);}_0x198d18[_0x64c105('0xed7')](),_0x29e42b[_0x64c105('0x182c')]=!![];}function _0xae48aa(_0x22189a){const _0x19de88=_0xc767cc;_0x29e42b['agents'][_0x22189a['id']]&&(_0x2e3ca0()[_0x19de88('0xf22')](_0x29e42b[_0x19de88('0x756')][_0x22189a['id']],_0x2e3ca0()[_0x19de88('0x24d0')](_0x2e3ca0()['omit'](_0x22189a,_0x38614c),_0x4c9e62)),_0x2e3ca0()['merge'](_0x29e42b['rpcAgents'][_0x22189a['id']],_0x2e3ca0()[_0x19de88('0x24d0')](_0x2e3ca0()[_0x19de88('0x8b5')](_0x22189a,_0x38614c),_0x4c9e62)),_0x1a2dd(_0x29e42b[_0x19de88('0x756')][_0x22189a['id']]));}function _0x597ccc(_0x459761){const _0x37e363=_0xc767cc;_0x29e42b[_0x37e363('0x756')][_0x459761['id']]&&(_0x2e3ca0()[_0x37e363('0xf22')](_0x29e42b[_0x37e363('0x756')][_0x459761['id']],_0x2e3ca0()[_0x37e363('0x24d0')](_0x459761,_0x4c9e62)),_0x2e3ca0()[_0x37e363('0xf22')](_0x29e42b[_0x37e363('0x127b')][_0x459761['id']],_0x2e3ca0()[_0x37e363('0x24d0')](_0x459761,_0x4c9e62)),_0x459761['lastPauseAt']&&(_0x29e42b[_0x37e363('0x756')][_0x459761['id']]['globalStatusTime']=_0x459761[_0x37e363('0x8cc')],_0x29e42b[_0x37e363('0x127b')][_0x459761['id']][_0x37e363('0x24d')]=_0x459761['lastPauseAt']),_0x1a2dd(_0x29e42b[_0x37e363('0x756')][_0x459761['id']]));}function _0xe8555c(_0xdbc939){const _0x1c881b=_0xc767cc;_0x29e42b[_0x1c881b('0x756')][_0x29e42b['agentInternal'][_0xdbc939[_0x1c881b('0x1d79')]]]&&(_0x2e3ca0()[_0x1c881b('0xf22')](_0x29e42b[_0x1c881b('0x756')][_0x29e42b[_0x1c881b('0x7c6')][_0xdbc939['destaccountcode']]],_0x2e3ca0()[_0x1c881b('0x24d0')](_0xdbc939,[_0x1c881b('0x660'),'destconnectedlinenum'])),_0x2e3ca0()[_0x1c881b('0xf22')](_0x29e42b[_0x1c881b('0x127b')][_0x29e42b[_0x1c881b('0x7c6')][_0xdbc939[_0x1c881b('0x1d79')]]],_0x2e3ca0()[_0x1c881b('0x24d0')](_0xdbc939,[_0x1c881b('0x660'),_0x1c881b('0x10f5')])));}function _0x161979(_0xebb53){const _0x18fb3d=_0xc767cc;_0x29e42b[_0x18fb3d('0x756')][_0x29e42b[_0x18fb3d('0x7c6')][_0xebb53['destaccountcode']]]&&(_0x29e42b[_0x18fb3d('0x756')][_0x29e42b[_0x18fb3d('0x7c6')][_0xebb53[_0x18fb3d('0x1d79')]]]=_0x2e3ca0()[_0x18fb3d('0x8b5')](_0x29e42b['agents'][_0x29e42b[_0x18fb3d('0x7c6')][_0xebb53[_0x18fb3d('0x1d79')]]],['queue',_0x18fb3d('0x10f5')]),_0x29e42b[_0x18fb3d('0x127b')][_0x29e42b[_0x18fb3d('0x7c6')][_0xebb53['destaccountcode']]]=_0x2e3ca0()[_0x18fb3d('0x8b5')](_0x29e42b[_0x18fb3d('0x127b')][_0x29e42b['agentInternal'][_0xebb53[_0x18fb3d('0x1d79')]]],[_0x18fb3d('0x660'),_0x18fb3d('0x10f5')]));}function _0x1dd374(_0x451d72){const _0x150392=_0xc767cc;return _0x5af448[_0x150392('0xc96')]['logout']({'id':_0x451d72['id'],'device':'realtime','agent_id':_0x451d72['id'],'agent_name':_0x451d72[_0x150392('0x60a')]})[_0x150392('0xe53')][_0x150392('0x683')](function(){const _0x3fbf35=_0x150392;_0x4ee8a4[_0x3fbf35('0x53')]({'title':_0x3fbf35('0x1683'),'msg':_0x451d72[_0x3fbf35('0x11bc')]+'\x20\x20properly\x20logout'}),_0x29e42b[_0x3fbf35('0x756')][_0x451d72['id']]&&(_0x29e42b[_0x3fbf35('0x756')][_0x451d72['id']][_0x3fbf35('0x2309')]=![]),_0x29e42b[_0x3fbf35('0x127b')][_0x451d72['id']]&&(_0x29e42b[_0x3fbf35('0x127b')][_0x451d72['id']][_0x3fbf35('0x2309')]=![]),_0x4f8d48();})[_0x150392('0x130a')](function(_0x37d977){const _0xf7390a=_0x150392;_0x4ee8a4['error']({'title':_0x37d977[_0xf7390a('0x13ee')]?'API:'+_0x37d977[_0xf7390a('0x13ee')]+_0xf7390a('0xbf6')+_0x37d977['statusText']:_0xf7390a('0x154f'),'msg':_0x37d977[_0xf7390a('0x5a5')]?JSON[_0xf7390a('0x258a')](_0x37d977[_0xf7390a('0x5a5')][_0xf7390a('0x8c2')]):_0x37d977['toString']()});});}function _0x159ce5(_0x565f7a,_0x5c46dc){const _0x2e0484=_0xc767cc;return _0x5af448[_0x2e0484('0xc96')]['pause']({'id':_0x565f7a['id'],'type':_0x5c46dc})[_0x2e0484('0xe53')]['then'](function(_0x1aacde){const _0x295ece=_0x2e0484;_0x29e42b[_0x295ece('0x756')][_0x565f7a['id']]&&_0x2e3ca0()[_0x295ece('0xf22')](_0x29e42b['agents'][_0x565f7a['id']],_0x2e3ca0()['pick'](_0x1aacde,_0x4c9e62)),_0x29e42b[_0x295ece('0x127b')][_0x565f7a['id']]&&_0x2e3ca0()['merge'](_0x29e42b[_0x295ece('0x127b')][_0x565f7a['id']],_0x2e3ca0()['pick'](_0x1aacde,_0x4c9e62)),_0x1a2dd(_0x29e42b[_0x295ece('0x756')][_0x565f7a['id']]);})['catch'](function(_0x3ee12b){const _0x3768d8=_0x2e0484;_0x4ee8a4['error']({'title':_0x3ee12b['status']?_0x3768d8('0x2168')+_0x3ee12b[_0x3768d8('0x13ee')]+_0x3768d8('0xbf6')+_0x3ee12b[_0x3768d8('0x24a9')]:_0x3768d8('0x154f'),'msg':_0x3ee12b['data']?JSON['stringify'](_0x3ee12b[_0x3768d8('0x5a5')][_0x3768d8('0x8c2')]):_0x3ee12b[_0x3768d8('0x1ff0')]()});});}function _0x58bed9(_0x407d17){const _0x4940c1=_0xc767cc;return _0x5af448[_0x4940c1('0xc96')][_0x4940c1('0x1778')]({'id':_0x407d17['id']})[_0x4940c1('0xe53')][_0x4940c1('0x683')](function(_0x2d0205){const _0x52441d=_0x4940c1;_0x29e42b['agents'][_0x407d17['id']]&&_0x2e3ca0()[_0x52441d('0xf22')](_0x29e42b[_0x52441d('0x756')][_0x407d17['id']],_0x2e3ca0()[_0x52441d('0x24d0')](_0x2d0205,_0x4c9e62)),_0x29e42b['rpcAgents'][_0x407d17['id']]&&_0x2e3ca0()['merge'](_0x29e42b[_0x52441d('0x127b')][_0x407d17['id']],_0x2e3ca0()['pick'](_0x2d0205,_0x4c9e62)),_0x1a2dd(_0x29e42b[_0x52441d('0x756')][_0x407d17['id']]);})[_0x4940c1('0x130a')](function(_0x16e601){const _0x1609d5=_0x4940c1;_0x4ee8a4[_0x1609d5('0x52a')]({'title':_0x16e601[_0x1609d5('0x13ee')]?'API:'+_0x16e601['status']+'\x20-\x20'+_0x16e601[_0x1609d5('0x24a9')]:'api.staff.save','msg':_0x16e601[_0x1609d5('0x5a5')]?JSON[_0x1609d5('0x258a')](_0x16e601['data'][_0x1609d5('0x8c2')]):_0x16e601[_0x1609d5('0x1ff0')]()});});}function _0x3f3cb6(_0x327163){const _0x396dc9=_0xc767cc;_0x395d5a[_0x396dc9('0x1d4')](_0x395d5a[_0x396dc9('0x2430')]()[_0x396dc9('0x188f')](!![])[_0x396dc9('0xf28')]('Legend')['htmlContent'](_0x396dc9('0x1f0'))['ok']('Ok')[_0x396dc9('0xe42')](_0x327163));}function _0x57444b(_0x1bc036,_0x1406f7){const _0x3150df=_0xc767cc;_0x395d5a[_0x3150df('0x1d4')]({'controller':'AgentqueueaddController','controllerAs':'vm','templateUrl':_0xf3687b,'parent':angular['element'](_0x3ac0a8[_0x3150df('0x18e5')]),'targetEvent':_0x1406f7,'clickOutsideToClose':!![],'locals':{'agent':_0x1bc036,'agents':[],'channel':_0x3150df('0x129f'),'direction':_0x3150df('0x1535'),'crudPermissions':_0x29e42b['crudPermissions']}});}function _0x235867(_0x4c4221){const _0x4e922f=_0xc767cc;return _0x4c4221===_0x4e922f('0xa4')||_0x4c4221===_0x4e922f('0x651');}function _0x35d78c(_0x2192fa){const _0x300bfd=_0xc767cc;return _0x2192fa===_0x300bfd('0xa4');}function _0x36f927(_0x41f586){const _0x30a323=_0xc767cc;return _0x41f586===_0x30a323('0x651');}function _0x422873(_0x241bb1){const _0x17b85f=_0xc767cc;return _0x241bb1===_0x17b85f('0x1586')||_0x241bb1===_0x17b85f('0xdd4')||_0x241bb1==='unavailable'||_0x241bb1===_0x17b85f('0x2727')||_0x2e3ca0()['isNil'](_0x241bb1);}function _0xbf90a1(_0x2b12c8,_0x3f7433){const _0x2126c1=_0xc767cc;if(_0x3f7433===_0x2126c1('0xcf2')){if(_0x2b12c8[_0x3f7433+_0x2126c1('0x1d9d')]!=='idle')return _0x2b12c8[_0x3f7433+_0x2126c1('0x1d9d')];if(_0x2b12c8[_0x3f7433+_0x2126c1('0x2113')])return _0x2b12c8[_0x3f7433+_0x2126c1('0x1d9d')]=_0x2126c1('0xa4'),_0x2126c1('0xa4');return'idle';}else{if(_0x2b12c8[_0x3f7433+_0x2126c1('0x2113')])return _0x2b12c8[_0x3f7433+_0x2126c1('0x1d9d')]=_0x2126c1('0xa4'),'pause';return _0x2b12c8[_0x3f7433+_0x2126c1('0x1d9d')];}}function _0x1a2dd(_0x4bcfe2){const _0x41776c=_0xc767cc;let _0x5810e9=_0x41776c('0xdd4');if(_0x2e3ca0()['every']([_0xbf90a1(_0x4bcfe2,_0x41776c('0xcf2')),_0xbf90a1(_0x4bcfe2,'chat'),_0xbf90a1(_0x4bcfe2,_0x41776c('0x129f')),_0xbf90a1(_0x4bcfe2,_0x41776c('0x1261')),_0xbf90a1(_0x4bcfe2,_0x41776c('0x1285')),_0xbf90a1(_0x4bcfe2,_0x41776c('0x16e7')),_0xbf90a1(_0x4bcfe2,_0x41776c('0x23e9'))],_0x235867))_0x5810e9='pause';else{if(_0x2e3ca0()[_0x41776c('0x7a2')]([_0xbf90a1(_0x4bcfe2,'voice'),_0xbf90a1(_0x4bcfe2,_0x41776c('0x24e')),_0xbf90a1(_0x4bcfe2,_0x41776c('0x129f')),_0xbf90a1(_0x4bcfe2,'openchannel'),_0xbf90a1(_0x4bcfe2,_0x41776c('0x1285')),_0xbf90a1(_0x4bcfe2,_0x41776c('0x16e7')),_0xbf90a1(_0x4bcfe2,'fax')],_0x235867))_0x5810e9=_0x41776c('0x651');else _0x2e3ca0()[_0x41776c('0x161')]([_0xbf90a1(_0x4bcfe2,_0x41776c('0xcf2')),_0xbf90a1(_0x4bcfe2,'chat'),_0xbf90a1(_0x4bcfe2,'mail'),_0xbf90a1(_0x4bcfe2,_0x41776c('0x1261')),_0xbf90a1(_0x4bcfe2,_0x41776c('0x1285')),_0xbf90a1(_0x4bcfe2,'whatsapp'),_0xbf90a1(_0x4bcfe2,_0x41776c('0x23e9'))],_0x422873)?_0x5810e9=_0x41776c('0x1586'):_0x5810e9=_0x41776c('0x63');}_0x4bcfe2['globalStatus']!==_0x5810e9&&(_0x4bcfe2[_0x41776c('0x12fa')]=_0x5810e9,_0x4bcfe2[_0x41776c('0x12f3')]?(_0x4bcfe2[_0x41776c('0x12f3')]=![],_0x4bcfe2[_0x41776c('0x24d')]=_0x235867(_0x5810e9)?_0x2e3ca0()[_0x41776c('0xea3')](_0x1aaf93()(_0x4bcfe2[_0x41776c('0x8cc')])[_0x41776c('0x26dd')]('x')):_0x2e3ca0()[_0x41776c('0x69b')]([_0x4bcfe2[_0x41776c('0x23b4')],_0x4bcfe2['chatStatusTime'],_0x4bcfe2['mailStatusTime'],_0x4bcfe2[_0x41776c('0x1a70')],_0x4bcfe2[_0x41776c('0x17c2')],_0x4bcfe2['openchannelStatusTime'],_0x4bcfe2[_0x41776c('0x21d1')]])):_0x4bcfe2[_0x41776c('0x24d')]=_0x2e3ca0()[_0x41776c('0xea3')](_0x1aaf93()()[_0x41776c('0x26dd')]('x')));}function _0x200eb5(_0x298ee2){const _0x5af6b8=_0xc767cc,_0x3b357c=_0x2e3ca0()[_0x5af6b8('0x18ad')](_0x29e42b[_0x5af6b8('0x23a2')][_0x5af6b8('0x150d')],'-')?'desc':'asc';return _0x2e3ca0()[_0x5af6b8('0x2ef')](_0x298ee2,[_0x29e42b[_0x5af6b8('0x23a2')][_0x5af6b8('0x150d')]['replace']('-','')],[_0x3b357c]);}function _0x313150(){const _0x3396c0=_0xc767cc;_0x201c0e&&(_0x2334b3[_0x3396c0('0x19fb')](_0x201c0e),_0x201c0e=null);}function _0xefdcb5(_0x2ea45d,_0x49e7cc){const _0x18e218=_0xc767cc;return _0x5af448['user']['update']({'id':_0x2ea45d['id']},{'screenrecording':_0x49e7cc})[_0x18e218('0xe53')]['catch'](function(_0x36b95a){const _0x753ed9=_0x18e218;_0x4ee8a4[_0x753ed9('0x52a')]({'title':_0x36b95a['status']?_0x753ed9('0x2168')+_0x36b95a[_0x753ed9('0x13ee')]+_0x753ed9('0xbf6')+_0x36b95a['statusText']:_0x753ed9('0x162b'),'msg':_0x36b95a[_0x753ed9('0x5a5')]?JSON[_0x753ed9('0x258a')](_0x36b95a[_0x753ed9('0x5a5')][_0x753ed9('0x8c2')]):_0x36b95a['toString']()});});}_0x3d091e[_0xc767cc('0x26a2')](_0xc767cc('0x4b8'),function(){const _0x45f959=_0xc767cc;_0xe46079[_0x45f959('0x1b9e')](_0x45f959('0x18f0')),_0xe46079[_0x45f959('0x1b9e')](_0x45f959('0x2719')),_0xe46079[_0x45f959('0x1b9e')](_0x45f959('0x216d')),_0xe46079[_0x45f959('0x1b9e')](_0x45f959('0x3b6')),_0x313150();});}const _0x2914df=_0x43b137,_0x51e294=_0x180212['p']+'src/js/modules/main/apps/mail/views/mailQueues/create/dialog.html/dialog.html',_0x3dcb38=_0x180212['p']+_0x189033('0x9e');_0x5c39db[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$q',_0x189033('0x16ea'),'$interval','queues',_0x189033('0x1a10'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1')];function _0x5c39db(_0x125aa7,_0x4a713a,_0x57e9c7,_0x49b56e,_0x3e53f8,_0x2fb3af,_0x5ccc27,_0x2e463a,_0x318af7,_0x315681,_0x4c11cc,_0x71c269,_0x4919cc,_0x1ff79f){const _0x4dcf09=_0x189033,_0x49bb20=this,_0xe66351=[_0x4dcf09('0x1506'),_0x4dcf09('0x8bb'),_0x4dcf09('0x1386'),_0x4dcf09('0x7a4'),_0x4dcf09('0x17f2'),_0x4dcf09('0x1a95'),_0x4dcf09('0x8c2'),_0x4dcf09('0x1455'),_0x4dcf09('0x1091'),_0x4dcf09('0x17c1'),_0x4dcf09('0x1a1d')];_0x49bb20[_0x4dcf09('0x11ed')]=_0x1ff79f[_0x4dcf09('0x20b2')](),_0x49bb20[_0x4dcf09('0x50d')]=_0x5ccc27[_0x4dcf09('0x50d')]?_0x5ccc27[_0x4dcf09('0x50d')]:0x0,_0x49bb20[_0x4dcf09('0x2da')]=_0x5ccc27?_0x2e3ca0()[_0x4dcf09('0x24db')](_0x5ccc27['rows']?_0x5ccc27['rows']:[],'id'):{},_0x49bb20[_0x4dcf09('0x1a10')]=_0x2e463a?_0x2e3ca0()[_0x4dcf09('0x24db')](_0x2e463a[_0x4dcf09('0xf5d')]?_0x2e463a[_0x4dcf09('0xf5d')]:[],'id'):{},_0x49bb20[_0x4dcf09('0x2a')]=_0x71c269,_0x49bb20[_0x4dcf09('0x22df')]=_0x4919cc&&_0x4919cc[_0x4dcf09('0x50d')]==0x1?_0x4919cc['rows'][0x0]:null,_0x49bb20[_0x4dcf09('0x1134')]=_0x1ff79f[_0x4dcf09('0x142a')](_0x49bb20[_0x4dcf09('0x22df')]?_0x49bb20[_0x4dcf09('0x22df')][_0x4dcf09('0x1134')]:null);_0x1ff79f[_0x4dcf09('0xca1')]('admin')?_0x49bb20[_0x4dcf09('0x23a2')]={'type':_0x4dcf09('0x1535'),'sort':_0x4dcf09('0xc36'),'limit':0xa,'page':0x1}:_0x49bb20[_0x4dcf09('0x23a2')]={'id':_0x49bb20[_0x4dcf09('0x11ed')]['id'],'channel':'mail','type':'inbound','sort':_0x4dcf09('0xc36'),'limit':0xa,'page':0x1};_0x49bb20[_0x4dcf09('0x53')]=_0x4ac4f0,_0x49bb20[_0x4dcf09('0x4c9')]=_0x478a98,_0x49bb20[_0x4dcf09('0xede')]=_0x14fbea,_0x49bb20['agentAdd']=_0x2cf352,_0x49bb20['updateQueue']=_0x5e3d2c,_0x49bb20['onSave']=_0x15937b,_0x49bb20[_0x4dcf09('0x3ae')]=_0x33c0de,_0x49bb20[_0x4dcf09('0x203e')]=_0x4d7e54,_0x49bb20[_0x4dcf09('0x4a5')]=_0x347f93,_0x49bb20[_0x4dcf09('0xd8b')]=_0x505792,_0x49bb20[_0x4dcf09('0xb2b')]=_0x50260b,_0x49bb20['$onInit']=_0x4cc83d,_0x49bb20['order']=[],_0x2e3ca0()[_0x4dcf09('0x15d0')](_0x49bb20[_0x4dcf09('0x2da')],function(_0x410d10){const _0x338332=_0x4dcf09;_0x49bb20[_0x338332('0x150d')][_0x338332('0x1fd0')](_0x410d10['id']);}),_0x315681['on'](_0x4dcf09('0xd92'),_0x49bb20[_0x4dcf09('0x2819')]),_0x315681['on']('userMailQueue:save',_0x49bb20[_0x4dcf09('0x3ae')]),_0x315681['on'](_0x4dcf09('0x165'),_0x49bb20[_0x4dcf09('0x203e')]),_0x315681['on'](_0x4dcf09('0x2719'),_0x49bb20[_0x4dcf09('0x4a5')]),_0x315681['on'](_0x4dcf09('0x56f'),_0x49bb20[_0x4dcf09('0xb2b')]),_0x315681['on']('userVoiceQueue:save',_0x49bb20[_0x4dcf09('0xd8b')]);function _0x4cc83d(){const _0x1e3fc6=_0x4dcf09,_0x41aeaf=[];return _0x2e3ca0()[_0x1e3fc6('0x15d0')](_0x49bb20[_0x1e3fc6('0x2da')],function(_0x19aeb1,_0x446167){const _0x597595=_0x1e3fc6;_0x19aeb1[_0x597595('0x1a1d')]=0x0,_0x19aeb1[_0x597595('0x25a4')]=0x0,_0x49bb20['queues'][_0x446167][_0x597595('0x756')]={},_0x41aeaf[_0x597595('0x1fd0')](_0x318af7[_0x597595('0x2160')][_0x597595('0x27cf')]({'id':_0x446167})[_0x597595('0xe53')]),_0x49bb20[_0x597595('0x1a10')][_0x446167]&&_0x2e3ca0()['merge'](_0x19aeb1,_0x2e3ca0()['pick'](_0x49bb20[_0x597595('0x1a10')][_0x446167],_0xe66351));}),_0x49b56e['all'](_0x41aeaf)[_0x1e3fc6('0x683')](function(_0x5b3de8){const _0x2df968=_0x1e3fc6;for(let _0x37b0b5=0x0;_0x37b0b5<_0x5b3de8[_0x2df968('0x1564')];_0x37b0b5+=0x1){for(let _0x17eb6e=0x0;_0x17eb6e<_0x5b3de8[_0x37b0b5]['rows'][_0x2df968('0x1564')];_0x17eb6e++){_0x5b3de8[_0x37b0b5][_0x2df968('0xf5d')][_0x17eb6e][_0x2df968('0x1a1d')]&&_0x49bb20[_0x2df968('0x2da')][_0x5b3de8[_0x37b0b5][_0x2df968('0xf5d')][_0x17eb6e][_0x2df968('0x27f7')]][_0x2df968('0x1a1d')]++,_0x49bb20[_0x2df968('0x2da')][_0x5b3de8[_0x37b0b5][_0x2df968('0xf5d')][_0x17eb6e]['MailQueueId']][_0x2df968('0x25a4')]++,_0x49bb20['queues'][_0x5b3de8[_0x37b0b5]['rows'][_0x17eb6e]['MailQueueId']][_0x2df968('0x756')][_0x5b3de8[_0x37b0b5]['rows'][_0x17eb6e]['UserId']]=_0x5b3de8[_0x37b0b5][_0x2df968('0xf5d')][_0x17eb6e][_0x2df968('0x27f7')];}}})[_0x1e3fc6('0x130a')](function(_0x305bfe){const _0x3776f2=_0x1e3fc6;console[_0x3776f2('0x52a')](_0x305bfe);});}function _0x15937b(_0x57ac51){const _0x4789b2=_0x4dcf09;_0x49bb20['queues'][_0x57ac51['id']]&&_0x2e3ca0()[_0x4789b2('0xf22')](_0x49bb20[_0x4789b2('0x2da')][_0x57ac51['id']],_0x2e3ca0()[_0x4789b2('0x24d0')](_0x57ac51,_0xe66351));}function _0x33c0de(_0x38a986){const _0x417eb8=_0x4dcf09;_0x49bb20[_0x417eb8('0x2da')][_0x38a986[_0x417eb8('0x27f7')]]&&_0x49bb20[_0x417eb8('0x2da')][_0x38a986[_0x417eb8('0x27f7')]][_0x417eb8('0x25a4')]++;}function _0x4d7e54(_0x42d524){const _0x21593f=_0x4dcf09;_0x49bb20[_0x21593f('0x2da')][_0x42d524[_0x21593f('0x27f7')]]&&_0x49bb20[_0x21593f('0x2da')][_0x42d524[_0x21593f('0x27f7')]][_0x21593f('0x25a4')]--;}function _0x347f93(_0x5bd2fc){const _0x50ae8f=_0x4dcf09;console[_0x50ae8f('0x1b2b')](_0x50ae8f('0x4a5'),_0x5bd2fc);if(_0x5bd2fc[_0x50ae8f('0x1431')])_0x2e3ca0()[_0x50ae8f('0x15d0')](_0x49bb20[_0x50ae8f('0x2da')],function(_0x48f72f){const _0x538e75=_0x50ae8f;_0x48f72f[_0x538e75('0x756')][_0x5bd2fc['id']]&&(_0x48f72f[_0x538e75('0x1a1d')]+=0x1,console[_0x538e75('0x1b2b')](_0x538e75('0xa4')));});else!_0x5bd2fc[_0x50ae8f('0x1431')]&&_0x2e3ca0()[_0x50ae8f('0x15d0')](_0x49bb20[_0x50ae8f('0x2da')],function(_0xaa18ff){const _0x539559=_0x50ae8f;_0xaa18ff[_0x539559('0x756')][_0x5bd2fc['id']]&&(_0xaa18ff[_0x539559('0x1a1d')]>0x0&&(_0xaa18ff[_0x539559('0x1a1d')]-=0x1,console['log'](_0x539559('0x1778'))));});}function _0x505792(_0x234e0c){const _0x3606aa=_0x4dcf09;console[_0x3606aa('0x1b2b')]('onLogged',_0x234e0c),_0x49bb20[_0x3606aa('0x2da')][_0x234e0c[_0x3606aa('0x27f7')]]&&(_0x49bb20[_0x3606aa('0x2da')][_0x234e0c[_0x3606aa('0x27f7')]][_0x3606aa('0x25a4')]+=0x1,_0x49bb20[_0x3606aa('0x2da')][_0x234e0c[_0x3606aa('0x27f7')]]['agents'][_0x234e0c['UserId']]=_0x234e0c[_0x3606aa('0x27f7')]);}function _0x50260b(_0x2cda4d){const _0x24ce2a=_0x4dcf09;console[_0x24ce2a('0x1b2b')](_0x24ce2a('0xb2b'),_0x2cda4d),_0x49bb20[_0x24ce2a('0x2da')][_0x2cda4d[_0x24ce2a('0x27f7')]]&&_0x49bb20[_0x24ce2a('0x2da')][_0x2cda4d['MailQueueId']]['loggedInDb']>0x0&&(_0x49bb20[_0x24ce2a('0x2da')][_0x2cda4d['MailQueueId']][_0x24ce2a('0x25a4')]-=0x1,delete _0x49bb20[_0x24ce2a('0x2da')][_0x2cda4d[_0x24ce2a('0x27f7')]][_0x24ce2a('0x756')][_0x2cda4d[_0x24ce2a('0x10c5')]]);}let _0xd57349=!![],_0x55afe8=0x1;_0x125aa7[_0x4dcf09('0x186d')](_0x4dcf09('0x1e1d'),function(_0x5c9363,_0x43e3ff){const _0x54b4d6=_0x4dcf09;_0xd57349?_0x4a713a(function(){_0xd57349=![];}):(!_0x43e3ff&&(_0x55afe8=_0x49bb20[_0x54b4d6('0x23a2')]['page']),_0x5c9363!==_0x43e3ff&&(_0x49bb20[_0x54b4d6('0x23a2')][_0x54b4d6('0xdf8')]=0x1),!_0x5c9363&&(_0x49bb20[_0x54b4d6('0x23a2')][_0x54b4d6('0xdf8')]=_0x55afe8),_0x49bb20['getQueues']());});function _0x4ac4f0(_0x31a6e5){const _0x133534=_0x4dcf09;_0x49bb20[_0x133534('0x50d')]=_0x31a6e5['count'],_0x49bb20[_0x133534('0x2da')]=_0x31a6e5?_0x2e3ca0()['keyBy'](_0x31a6e5[_0x133534('0xf5d')]?_0x31a6e5[_0x133534('0xf5d')]:[],'id'):{};if(_0x31a6e5[_0x133534('0xf5d')]){_0x49bb20[_0x133534('0x150d')]=[];for(let _0x327c3d=0x0;_0x327c3d<_0x31a6e5[_0x133534('0xf5d')][_0x133534('0x1564')];_0x327c3d++){_0x49bb20[_0x133534('0x150d')][_0x133534('0x1fd0')](_0x31a6e5[_0x133534('0xf5d')][_0x327c3d]['id']);}}_0x4cc83d();}function _0x478a98(){const _0x1a879f=_0x4dcf09;_0x49bb20[_0x1a879f('0x23a2')][_0x1a879f('0x1cc8')]=(_0x49bb20[_0x1a879f('0x23a2')][_0x1a879f('0xdf8')]-0x1)*_0x49bb20[_0x1a879f('0x23a2')][_0x1a879f('0x6f0')],_0x1ff79f['hasRole'](_0x1a879f('0x20c2'))?_0x49bb20['promise']=_0x318af7[_0x1a879f('0x2160')]['get'](_0x49bb20[_0x1a879f('0x23a2')],_0x4ac4f0)[_0x1a879f('0xe53')]:(_0x49bb20['query']['id']=_0x49bb20[_0x1a879f('0x2a')]['id'],_0x49bb20[_0x1a879f('0x23a2')][_0x1a879f('0x1aa')]=_0x1a879f('0x97d'),_0x49bb20['promise']=_0x318af7[_0x1a879f('0x2a')][_0x1a879f('0x241d')](_0x49bb20['query'],_0x4ac4f0)[_0x1a879f('0xe53')]);}function _0x14fbea(_0x3fe0aa,_0x470e7b){const _0x699bc6=_0x4dcf09;_0x57e9c7[_0x699bc6('0x1d4')]({'controller':_0x699bc6('0x1bdb'),'controllerAs':'vm','templateUrl':_0x51e294,'parent':angular['element'](_0x3e53f8[_0x699bc6('0x18e5')]),'targetEvent':_0x3fe0aa,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x470e7b,'mailQueues':_0x2e3ca0()['values'](_0x49bb20[_0x699bc6('0x2da')]),'license':null,'setting':null,'crudPermissions':_0x49bb20[_0x699bc6('0x1134')]}});}function _0x2cf352(_0x3bbf3f,_0x572a65){const _0x589df9=_0x4dcf09;_0x57e9c7[_0x589df9('0x1d4')]({'controller':_0x589df9('0x99a'),'controllerAs':'vm','templateUrl':_0x3dcb38,'parent':angular[_0x589df9('0x1fcc')](_0x3e53f8[_0x589df9('0x18e5')]),'targetEvent':_0x3bbf3f,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x572a65,'mailQueues':_0x49bb20[_0x589df9('0x2da')]?_0x49bb20['queues'][_0x589df9('0xf5d')]:[],'realtime':![],'crudPermissions':_0x49bb20[_0x589df9('0x1134')]}});}function _0x5e3d2c(_0x3dfedf){const _0x1f31b0=_0x4dcf09;return _0x318af7[_0x1f31b0('0x2160')][_0x1f31b0('0x2480')](_0x3dfedf)[_0x1f31b0('0xe53')][_0x1f31b0('0x683')](function(){const _0x11c183=_0x1f31b0;_0x4c11cc[_0x11c183('0x53')]({'title':_0x11c183('0x5c7'),'msg':_0x3dfedf[_0x11c183('0x60a')]?_0x3dfedf[_0x11c183('0x60a')]+_0x11c183('0x96c'):''});})[_0x1f31b0('0x130a')](function(_0x567634){const _0x933a25=_0x1f31b0;_0x4c11cc[_0x933a25('0x52a')]({'title':'Error\x20creating\x20queue!','msg':_0x567634['message']});});}_0x125aa7[_0x4dcf09('0x26a2')](_0x4dcf09('0x4b8'),function(){const _0xfb29dc=_0x4dcf09;_0x315681['removeAllListeners']('mail_queue:save'),_0x315681[_0xfb29dc('0x1b9e')]('userMailQueue:remove'),_0x315681[_0xfb29dc('0x1b9e')](_0xfb29dc('0x1eaf')),_0x315681[_0xfb29dc('0x1b9e')](_0xfb29dc('0x2719')),_0x315681[_0xfb29dc('0x1b9e')](_0xfb29dc('0x56f')),_0x315681[_0xfb29dc('0x1b9e')]('userVoiceQueue:save');});}const _0x2c595b=_0x5c39db;function _0xe877ec(){const _0x4b8646=_0x189033;return{'status':{'registered':_0x4b8646('0x584'),'unregistered':_0x4b8646('0x1da'),'lagged':_0x4b8646('0x1da'),'reachable':_0x4b8646('0x584'),'unreachable':_0x4b8646('0x1da'),'unknown':_0x4b8646('0xcb0')},'state':{'unknown':_0x4b8646('0x27f9'),'not_inuse':_0x4b8646('0x280d'),'inuse':_0x4b8646('0x10c0'),'busy':_0x4b8646('0x25ad'),'invalid':_0x4b8646('0x27f9'),'unavailable':_0x4b8646('0x27f9'),'ringing':_0x4b8646('0x20f0'),'ringinuse':_0x4b8646('0x20f0'),'onhold':_0x4b8646('0x1a52')},'channelStatus':{'ring':_0x4b8646('0x20f0'),'up':'green-300-fg\x20icon-phone-in-talk','hangup':_0x4b8646('0x22be')},'channelStatusOut':{'ring':_0x4b8646('0x2370'),'up':_0x4b8646('0x1133'),'hangup':'red-300-fg\x20icon-phone-hangup'}};}const _0x3af889=_0xe877ec;_0x581e5f[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0x1556')];function _0x581e5f(_0x3b2b64,_0x2d4874,_0x5cc0d2){const _0x537ee4=_0x189033,_0x1784ac=this;_0x5cc0d2[_0x537ee4('0x1346')](),_0x5cc0d2[_0x537ee4('0x12ac')](),_0x1784ac[_0x537ee4('0x517')]=0x0;switch(_0x2d4874[_0x537ee4('0xb24')][_0x537ee4('0x60a')]){case _0x537ee4('0xf91'):_0x1784ac[_0x537ee4('0x517')]=0x0;break;case _0x537ee4('0x462'):_0x1784ac[_0x537ee4('0x517')]=0x1;break;case _0x537ee4('0x1000'):_0x1784ac[_0x537ee4('0x517')]=0x2;break;default:_0x1784ac[_0x537ee4('0x517')]=0x0,_0x2d4874['go'](_0x537ee4('0xf91'));}_0x3b2b64[_0x537ee4('0x186d')]('vm.selectedTab',function(_0x4111d9,_0x2db3cd){const _0x36d9ea=_0x537ee4;if(_0x4111d9!==_0x2db3cd)switch(_0x4111d9){case 0x0:_0x2d4874['go'](_0x36d9ea('0xf91'));break;case 0x1:_0x2d4874['go'](_0x36d9ea('0x462'));break;case 0x2:_0x2d4874['go']('app.mail.realtime.accounts');break;default:_0x2d4874['go'](_0x36d9ea('0xf91'));}});}const _0x5745c0=_0x581e5f;_0x5989ef['$inject']=[_0x189033('0x1398')];function _0x5989ef(_0x2995a1){const _0x393453=_0x189033;_0x2995a1['state']('app.mail.realtime',{'url':_0x393453('0xf7c'),'views':{'content@app':{'templateUrl':_0x3ca1e3,'controller':_0x393453('0xec2')}},'resolve':{'userProfile':[_0x393453('0x4b1'),_0x393453('0xba1'),function(_0x2a06bf,_0x5dab12){const _0x405013=_0x393453;return _0x5dab12[_0x405013('0xca1')](_0x405013('0x20c2'))?null:_0x2a06bf[_0x405013('0xed7')](_0x405013('0x1464'),{'fields':_0x405013('0x16f'),'id':_0x5dab12['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x393453('0x4b1'),_0x393453('0xba1'),function(_0x5c4a31,_0x2d4455){const _0x4a06bd=_0x393453;return _0x2d4455[_0x4a06bd('0xca1')](_0x4a06bd('0x20c2'))?null:_0x5c4a31[_0x4a06bd('0xed7')](_0x4a06bd('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x2d4455[_0x4a06bd('0x20b2')]()[_0x4a06bd('0x2f')],'sectionId':0x262});}]},'authenticate':!![],'permissionId':0x262})['state']('app.mail.realtime.agents',{'url':_0x393453('0xf1a'),'controller':_0x393453('0x1540'),'templateUrl':_0xdd0f54,'resolve':{'pauses':[_0x393453('0x4b1'),function(_0x3c5542){const _0x5a7121=_0x393453;return _0x3c5542[_0x5a7121('0xed7')](_0x5a7121('0x112'),{'nolimit':!![]});}],'agents':[_0x393453('0x4b1'),_0x393453('0xba1'),function(_0x3c6a0e,_0x181616){const _0x30b0c1=_0x393453;return _0x181616[_0x30b0c1('0xca1')](_0x30b0c1('0x20c2'))?_0x3c6a0e[_0x30b0c1('0xed7')](_0x30b0c1('0x25c9'),{'fields':_0x30b0c1('0x174e'),'role':'agent','sort':_0x30b0c1('0x11bc'),'nolimit':!![]}):_0x3c6a0e[_0x30b0c1('0xed7')](_0x30b0c1('0x191b'),{'id':_0x181616[_0x30b0c1('0x20b2')]()['userProfileId'],'section':_0x30b0c1('0x1bc0'),'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':'agent','sort':'fullname','nolimit':!![]});}],'userProfile':['apiResolver',_0x393453('0xba1'),function(_0x5250e6,_0x234055){const _0x38bb10=_0x393453;return _0x234055[_0x38bb10('0xca1')]('admin')?null:_0x5250e6[_0x38bb10('0xed7')](_0x38bb10('0x1464'),{'fields':'id,name,crudPermissions','id':_0x234055['getCurrentUser']()[_0x38bb10('0x2f')]});}],'userProfileSection':[_0x393453('0x4b1'),'Auth',function(_0x17ae41,_0x48bed3){const _0x3be344=_0x393453;return _0x48bed3['hasRole']('admin')?null:_0x17ae41[_0x3be344('0xed7')](_0x3be344('0x360'),{'fields':_0x3be344('0x1f47'),'userProfileId':_0x48bed3[_0x3be344('0x20b2')]()['userProfileId'],'sectionId':0xca});}],'rpcAgents':['apiResolver',function(_0x1751a2){const _0x2f4da0=_0x393453;return _0x1751a2[_0x2f4da0('0xed7')](_0x2f4da0('0x36a'));}]},'authenticate':!![],'permissionId':0x262})[_0x393453('0x2598')](_0x393453('0x462'),{'url':_0x393453('0x14a4'),'controller':_0x393453('0x2162'),'templateUrl':_0x5e76df,'resolve':{'queues':[_0x393453('0x4b1'),_0x393453('0xba1'),function(_0x5401a6,_0x2c35e8){const _0x1d532d=_0x393453;return _0x2c35e8[_0x1d532d('0xca1')](_0x1d532d('0x20c2'))?_0x5401a6[_0x1d532d('0xed7')](_0x1d532d('0x2846'),{'type':_0x1d532d('0x1535'),'sort':_0x1d532d('0xc36'),'limit':0xa,'offset':0x0}):_0x5401a6['resolve']('userProfile@getResources',{'id':_0x2c35e8['getCurrentUser']()[_0x1d532d('0x2f')],'section':_0x1d532d('0x97d'),'channel':'mail','type':_0x1d532d('0x1535'),'sort':'-updatedAt','limit':0xa,'page':0x1});}],'userProfile':[_0x393453('0x4b1'),'Auth',function(_0x3a0c89,_0x1d2031){const _0x3ad500=_0x393453;return _0x1d2031[_0x3ad500('0xca1')](_0x3ad500('0x20c2'))?null:_0x3a0c89['resolve'](_0x3ad500('0x1464'),{'fields':'id,name,crudPermissions','id':_0x1d2031[_0x3ad500('0x20b2')]()[_0x3ad500('0x2f')]});}],'userProfileSection':[_0x393453('0x4b1'),_0x393453('0xba1'),function(_0x1a688e,_0xcb3fc2){const _0x37bbd9=_0x393453;return _0xcb3fc2['hasRole'](_0x37bbd9('0x20c2'))?null:_0x1a688e[_0x37bbd9('0xed7')](_0x37bbd9('0x360'),{'fields':_0x37bbd9('0x1f47'),'userProfileId':_0xcb3fc2['getCurrentUser']()[_0x37bbd9('0x2f')],'sectionId':0x259});}],'rpcQueues':[_0x393453('0x4b1'),function(_0x4fdca0){const _0x5db270=_0x393453;return _0x4fdca0[_0x5db270('0xed7')](_0x5db270('0x1579'));}]},'authenticate':!![],'permissionId':0x262})[_0x393453('0x2598')](_0x393453('0x1000'),{'url':_0x393453('0x1c1'),'controller':_0x393453('0x1553'),'templateUrl':_0x10562e,'resolve':{'mailAccounts':[_0x393453('0x4b1'),'Auth',function(_0x363d33,_0x7f264b){const _0x34b43a=_0x393453;return _0x7f264b[_0x34b43a('0xca1')]('admin')?_0x363d33[_0x34b43a('0xed7')](_0x34b43a('0x2a9'),{'sort':_0x34b43a('0xc36'),'limit':0xa,'offset':0x0}):_0x363d33['resolve'](_0x34b43a('0x191b'),{'id':_0x7f264b['getCurrentUser']()[_0x34b43a('0x2f')],'section':_0x34b43a('0x2672'),'sort':_0x34b43a('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x393453('0x4b1'),'Auth',function(_0x3fd902,_0x581b1b){const _0x394db6=_0x393453;return _0x581b1b['hasRole'](_0x394db6('0x20c2'))?null:_0x3fd902[_0x394db6('0xed7')](_0x394db6('0x1464'),{'fields':'id,name,crudPermissions','id':_0x581b1b['getCurrentUser']()[_0x394db6('0x2f')]});}],'userProfileSection':[_0x393453('0x4b1'),_0x393453('0xba1'),function(_0x32de49,_0x54f8a7){const _0x5d1950=_0x393453;return _0x54f8a7[_0x5d1950('0xca1')](_0x5d1950('0x20c2'))?null:_0x32de49['resolve']('userProfileSection@get',{'fields':_0x5d1950('0x1f47'),'userProfileId':_0x54f8a7[_0x5d1950('0x20b2')]()[_0x5d1950('0x2f')],'sectionId':0x25a});}],'rpcMailAccounts':[_0x393453('0x4b1'),function(_0x4e4e7e){const _0x108f73=_0x393453;return _0x4e4e7e[_0x108f73('0xed7')](_0x108f73('0x234e'));}]},'authenticate':!![],'permissionId':0x262});}angular[_0x189033('0x1e26')]('app.mail.realtime',[])['config'](_0x5989ef)[_0x189033('0x1da3')](_0x189033('0xca6'),_0x2914df)[_0x189033('0x1da3')]('QueuesMailRealtimeController',_0x2c595b)[_0x189033('0x1f97')](_0x189033('0xa72'),_0x3af889)[_0x189033('0x1da3')](_0x189033('0x170e'),_0x5745c0);const _0x494001=_0x180212['p']+_0x189033('0x57a'),_0x39b6c2=_0x180212['p']+'src/js/modules/main/apps/mail/views/mailQueues/edit/view.html/view.html',_0x3aa68e=_0x180212['p']+'src/js/modules/main/apps/mail/views/mailAccounts/mailAccounts.html/mailAccounts.html',_0x374510=_0x180212['p']+_0x189033('0xe8e'),_0x1e7dd8=_0x180212['p']+_0x189033('0x1ef1');_0xed2015[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1093'),_0x189033('0xb87'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0xed2015(_0x4276c7,_0xf9ed89,_0x2395ba,_0x459a57,_0x480b79,_0x233738,_0x952bdb,_0x5976ad,_0x1761c3,_0x1a704e,_0x21e5ca,_0x9fc1cc,_0x416a2e,_0x45e385){const _0x5def64=_0x189033,_0x48e5cd=this;_0x48e5cd['currentUser']=_0x21e5ca[_0x5def64('0x20b2')](),_0x48e5cd[_0x5def64('0x17f')]=[],_0x48e5cd[_0x5def64('0x260a')]=_0x416a2e,_0x48e5cd[_0x5def64('0xace')]=_0x9fc1cc,_0x48e5cd[_0x5def64('0x1134')]=_0x45e385,_0x48e5cd['hasModulePermissions']={},_0x48e5cd['passwordPattern']=_0x48e5cd[_0x5def64('0x260a')]&&_0x48e5cd[_0x5def64('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x48e5cd['title']=_0x5def64('0x5dd'),_0x48e5cd[_0x5def64('0xb87')]=angular[_0x5def64('0x1a86')](_0x1761c3),_0x48e5cd[_0x5def64('0x1093')]=_0x5976ad,_0x48e5cd[_0x5def64('0x208f')]=![];!_0x48e5cd['mailAccount']&&(_0x48e5cd[_0x5def64('0xb87')]={'active':!![],'cservice':_0x5def64('0x13c'),'cauthentication':!![],'fontSize':0xd,'waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0x48e5cd[_0x5def64('0xf28')]=_0x5def64('0x15bd'),_0x48e5cd['newMailAccount']=!![]);_0xf9ed89[_0x5def64('0x7f2')]['id']&&(_0x48e5cd[_0x5def64('0xb87')][_0x5def64('0x1cd')]=_0xf9ed89['params']['id']);_0x48e5cd['addNewMailAccount']=_0x57332f,_0x48e5cd[_0x5def64('0x6b4')]=_0x390012,_0x48e5cd['deleteMailAccount']=_0x5ec1a2,_0x48e5cd[_0x5def64('0x16b3')]=_0x3a7bef,_0x48e5cd[_0x5def64('0xf82')]=_0x206cff,_0x21e5ca[_0x5def64('0xca1')](_0x5def64('0x20c2'))?_0x1a704e[_0x5def64('0x259b')]['get']({'fields':_0x5def64('0xa10'),'sort':'name'})[_0x5def64('0xe53')][_0x5def64('0x683')](function(_0x184db8){const _0x4a8b51=_0x5def64;_0x48e5cd['lists']=_0x184db8[_0x4a8b51('0xf5d')]||[];})['catch'](function(_0x41484e){const _0x5e4a76=_0x5def64;_0x952bdb[_0x5e4a76('0x52a')]({'title':_0x41484e[_0x5e4a76('0x13ee')]?_0x5e4a76('0x2168')+_0x41484e[_0x5e4a76('0x13ee')]+_0x5e4a76('0xbf6')+_0x41484e[_0x5e4a76('0x24a9')]:_0x5e4a76('0x251b'),'msg':_0x41484e['data']?JSON['stringify'](_0x41484e[_0x5e4a76('0x5a5')]):_0x41484e['toString']()});}):_0x1a704e[_0x5def64('0x259b')]['get']({'fields':_0x5def64('0xa10'),'sort':_0x5def64('0x60a')})['$promise'][_0x5def64('0x683')](function(_0x14e8be){const _0x35c982=_0x5def64;_0x48e5cd[_0x35c982('0xe01')]=_0x14e8be['rows']||[];})[_0x5def64('0x683')](function(){const _0xb2e5cd=_0x5def64;return _0x1a704e[_0xb2e5cd('0x22df')][_0xb2e5cd('0x1e6e')]({'userProfileId':_0x48e5cd['currentUser'][_0xb2e5cd('0x2f')],'sectionId':0x12d})[_0xb2e5cd('0xe53')];})[_0x5def64('0x683')](function(_0x502c76){const _0x4e8f6a=_0x5def64,_0x509e46=_0x502c76&&_0x502c76[_0x4e8f6a('0xf5d')]?_0x502c76[_0x4e8f6a('0xf5d')][0x0]:null;if(!_0x509e46){const _0x10230f=[];let _0x319902=null;_0x48e5cd[_0x4e8f6a('0xb87')]&&(_0x319902=_0x2e3ca0()[_0x4e8f6a('0x1c07')](_0x48e5cd[_0x4e8f6a('0xe01')],{'id':Number(_0x48e5cd[_0x4e8f6a('0xb87')]['ListId'])}));for(let _0x35cabd=0x0;_0x35cabd<_0x48e5cd['lists'][_0x4e8f6a('0x1564')];_0x35cabd++){_0x319902&&_0x48e5cd['lists'][_0x35cabd]['id']===_0x319902['id']&&(_0x48e5cd[_0x4e8f6a('0xe01')][_0x35cabd][_0x4e8f6a('0x319')]=![],_0x10230f[_0x4e8f6a('0x1fd0')](_0x48e5cd[_0x4e8f6a('0xe01')][_0x35cabd]));}_0x48e5cd[_0x4e8f6a('0xe01')]=_0x10230f;}else{if(!_0x509e46['autoAssociation'])return _0x1a704e[_0x4e8f6a('0xcf7')][_0x4e8f6a('0x1e6e')]({'sectionId':_0x509e46['id']})[_0x4e8f6a('0xe53')][_0x4e8f6a('0x683')](function(_0x54c726){const _0x40df6b=_0x4e8f6a,_0x42c78a=_0x2e3ca0()[_0x40df6b('0x386')](_0x54c726[_0x40df6b('0xf5d')],function(_0x3ffe0b){const _0x252c93=_0x40df6b;return _0x2e3ca0()[_0x252c93('0x1c07')](_0x48e5cd[_0x252c93('0xe01')],{'id':_0x3ffe0b[_0x252c93('0x832')]});});let _0x34c3ad=null;_0x48e5cd['mailAccount']&&(_0x34c3ad=_0x2e3ca0()[_0x40df6b('0x1c07')](_0x48e5cd[_0x40df6b('0xe01')],{'id':Number(_0x48e5cd[_0x40df6b('0xb87')][_0x40df6b('0x1e4f')])}));if(_0x34c3ad&&!_0x2e3ca0()[_0x40df6b('0x7a2')](_0x42c78a,['id',_0x34c3ad['id']])){const _0x52c970=_0x2e3ca0()[_0x40df6b('0x1c07')](_0x48e5cd[_0x40df6b('0xe01')],{'id':_0x34c3ad['id']});_0x52c970[_0x40df6b('0x319')]=![],_0x42c78a[_0x40df6b('0x1fd0')](_0x52c970);}_0x48e5cd[_0x40df6b('0xe01')]=_0x42c78a;});}})[_0x5def64('0x130a')](function(_0x2bcddb){const _0x4abf3f=_0x5def64;_0x952bdb['error']({'title':_0x2bcddb['status']?_0x4abf3f('0x2168')+_0x2bcddb[_0x4abf3f('0x13ee')]+'\x20-\x20'+_0x2bcddb['statusText']:_0x4abf3f('0x11e3'),'msg':_0x2bcddb[_0x4abf3f('0x5a5')]?JSON[_0x4abf3f('0x258a')](_0x2bcddb[_0x4abf3f('0x5a5')]):_0x2bcddb[_0x4abf3f('0x1ff0')]()});});function _0x57332f(){const _0x560122=_0x5def64;_0x48e5cd[_0x560122('0x17f')]=[],_0x1a704e[_0x560122('0xb87')][_0x560122('0xb0a')](_0x48e5cd[_0x560122('0xb87')])[_0x560122('0xe53')][_0x560122('0x683')](function(_0x5d57e2){const _0x52b816=_0x560122;_0x48e5cd[_0x52b816('0x1093')][_0x52b816('0x1167')](_0x5d57e2[_0x52b816('0x24e1')]()),_0x952bdb[_0x52b816('0x53')]({'title':_0x52b816('0x242e'),'msg':_0x48e5cd[_0x52b816('0xb87')][_0x52b816('0x60a')]?_0x48e5cd[_0x52b816('0xb87')][_0x52b816('0x60a')]+'\x20has\x20been\x20created!':''}),_0x206cff(_0x5d57e2);})[_0x560122('0x130a')](function(_0xbb0ad4){const _0x406476=_0x560122;if(_0xbb0ad4['data']&&_0xbb0ad4['data'][_0x406476('0x17f')]&&_0xbb0ad4[_0x406476('0x5a5')]['errors'][_0x406476('0x1564')]){_0x48e5cd[_0x406476('0x17f')]=_0xbb0ad4[_0x406476('0x5a5')]['errors']||[{'message':_0xbb0ad4[_0x406476('0x1ff0')](),'type':_0x406476('0x2350')}];for(let _0x284f86=0x0;_0x284f86<_0xbb0ad4[_0x406476('0x5a5')]['errors'][_0x406476('0x1564')];_0x284f86+=0x1){_0x952bdb[_0x406476('0x52a')]({'title':_0xbb0ad4['data'][_0x406476('0x17f')][_0x284f86][_0x406476('0xcf0')],'msg':_0xbb0ad4[_0x406476('0x5a5')][_0x406476('0x17f')][_0x284f86]['message']});}}else _0x952bdb[_0x406476('0x52a')]({'title':_0xbb0ad4[_0x406476('0x13ee')]?'API:'+_0xbb0ad4[_0x406476('0x13ee')]+_0x406476('0xbf6')+_0xbb0ad4['statusText']:'api.mailAccount.save','msg':_0xbb0ad4['data']?JSON['stringify'](_0xbb0ad4[_0x406476('0x5a5')][_0x406476('0x8c2')]):_0xbb0ad4['toString']()});});}function _0x390012(){const _0x2eff10=_0x5def64;_0x48e5cd[_0x2eff10('0x17f')]=[],_0x1a704e[_0x2eff10('0xb87')][_0x2eff10('0x2480')]({'id':_0x48e5cd['mailAccount']['id']},_0x48e5cd[_0x2eff10('0xb87')])[_0x2eff10('0xe53')]['then'](function(_0x3d43dd){const _0x113bda=_0x2eff10,_0x579501=_0x2e3ca0()[_0x113bda('0x1c07')](_0x48e5cd[_0x113bda('0x1093')],{'id':_0x3d43dd['id']});_0x579501&&_0x2e3ca0()[_0x113bda('0xf22')](_0x579501,_0x2e3ca0()[_0x113bda('0x24d0')](_0x3d43dd['toJSON'](),_0x2e3ca0()[_0x113bda('0x55e')](_0x579501))),_0x952bdb[_0x113bda('0x53')]({'title':'MailAccount\x20properly\x20saved!','msg':_0x48e5cd['mailAccount'][_0x113bda('0x60a')]?_0x48e5cd[_0x113bda('0xb87')][_0x113bda('0x60a')]+_0x113bda('0xf59'):''}),_0x206cff(_0x3d43dd);})[_0x2eff10('0x130a')](function(_0x2ec32f){const _0x5ad671=_0x2eff10;if(_0x2ec32f[_0x5ad671('0x5a5')]&&_0x2ec32f['data'][_0x5ad671('0x17f')]&&_0x2ec32f['data'][_0x5ad671('0x17f')][_0x5ad671('0x1564')]){_0x48e5cd[_0x5ad671('0x17f')]=_0x2ec32f[_0x5ad671('0x5a5')][_0x5ad671('0x17f')]||[{'message':_0x2ec32f['toString'](),'type':_0x5ad671('0x1afc')}];for(let _0x26d2ae=0x0;_0x26d2ae<_0x2ec32f[_0x5ad671('0x5a5')][_0x5ad671('0x17f')][_0x5ad671('0x1564')];_0x26d2ae++){_0x952bdb[_0x5ad671('0x52a')]({'title':_0x2ec32f['data'][_0x5ad671('0x17f')][_0x26d2ae][_0x5ad671('0xcf0')],'msg':_0x2ec32f[_0x5ad671('0x5a5')][_0x5ad671('0x17f')][_0x26d2ae][_0x5ad671('0x8c2')]});}}else _0x952bdb['error']({'title':_0x2ec32f[_0x5ad671('0x13ee')]?_0x5ad671('0x2168')+_0x2ec32f[_0x5ad671('0x13ee')]+'\x20-\x20'+_0x2ec32f[_0x5ad671('0x24a9')]:'api.mailAccount.update','msg':_0x2ec32f[_0x5ad671('0x5a5')]?JSON[_0x5ad671('0x258a')](_0x2ec32f['data'][_0x5ad671('0x8c2')]):_0x2ec32f[_0x5ad671('0x1ff0')]()});});}function _0x5ec1a2(_0x2ca76b){const _0x176abb=_0x5def64;if(_0x48e5cd[_0x176abb('0xb87')]['service'])return _0x952bdb[_0x176abb('0x52a')]({'title':_0x176abb('0x698'),'msg':_0x176abb('0x63d')});_0x48e5cd[_0x176abb('0x17f')]=[];const _0x13e70e=_0x459a57[_0x176abb('0x1c6f')]()['title'](_0x176abb('0x4d'))[_0x176abb('0xa6a')](_0x176abb('0xeb9'))[_0x176abb('0x1040')](_0x176abb('0x25a7'))['ok'](_0x176abb('0x2307'))[_0x176abb('0x19fb')](_0x176abb('0x253a'))[_0x176abb('0xe42')](_0x2ca76b);_0x459a57[_0x176abb('0x1d4')](_0x13e70e)[_0x176abb('0x683')](function(){const _0x2b2ab9=_0x176abb;_0x1a704e[_0x2b2ab9('0xb87')][_0x2b2ab9('0xd7e')]({'id':_0x48e5cd[_0x2b2ab9('0xb87')]['id']})['$promise'][_0x2b2ab9('0x683')](function(){const _0x547822=_0x2b2ab9;_0x2e3ca0()[_0x547822('0x3ec')](_0x48e5cd['mailAccounts'],{'id':_0x48e5cd[_0x547822('0xb87')]['id']}),_0x952bdb[_0x547822('0x53')]({'title':'MailAccount\x20properly\x20deleted!','msg':(_0x48e5cd[_0x547822('0xb87')]['name']||_0x547822('0xb87'))+'\x20has\x20been\x20deleted!'}),_0x206cff(_0x48e5cd[_0x547822('0xb87')]);})[_0x2b2ab9('0x130a')](function(_0x173d81){const _0x1934a3=_0x2b2ab9;if(_0x173d81['data']&&_0x173d81[_0x1934a3('0x5a5')][_0x1934a3('0x17f')]&&_0x173d81['data'][_0x1934a3('0x17f')][_0x1934a3('0x1564')]){_0x48e5cd[_0x1934a3('0x17f')]=_0x173d81[_0x1934a3('0x5a5')][_0x1934a3('0x17f')]||[{'message':_0x173d81[_0x1934a3('0x1ff0')](),'type':'api.mailAccount.delete'}];for(let _0x39fb1f=0x0;_0x39fb1f<_0x173d81[_0x1934a3('0x5a5')][_0x1934a3('0x17f')][_0x1934a3('0x1564')];_0x39fb1f++){_0x952bdb['error']({'title':_0x173d81[_0x1934a3('0x5a5')][_0x1934a3('0x17f')][_0x39fb1f][_0x1934a3('0xcf0')],'msg':_0x173d81[_0x1934a3('0x5a5')][_0x1934a3('0x17f')][_0x39fb1f][_0x1934a3('0x8c2')]});}}else _0x952bdb[_0x1934a3('0x52a')]({'title':_0x173d81['status']?'API:'+_0x173d81[_0x1934a3('0x13ee')]+'\x20-\x20'+_0x173d81[_0x1934a3('0x24a9')]:_0x1934a3('0xd23'),'msg':_0x173d81['data']?JSON[_0x1934a3('0x258a')](_0x173d81['data']['message']):_0x173d81[_0x1934a3('0x8c2')]||_0x173d81[_0x1934a3('0x1ff0')]()});});},function(){});}function _0x3a7bef(_0xb53c35){return _0xb53c35===null?undefined:new Date(_0xb53c35);}function _0x206cff(_0x2666d7){const _0x4604f7=_0x5def64;_0x459a57[_0x4604f7('0x1715')](_0x2666d7);}}const _0x48735a=_0xed2015,_0x35f8b6=_0x180212['p']+'src/js/modules/main/apps/mail/views/mailAccounts/edit/apps/agent/dialog.html/dialog.html',_0x2b3704=_0x180212['p']+_0x189033('0x1bab'),_0x5ba39b=_0x180212['p']+_0x189033('0x24bf'),_0x44b505=_0x180212['p']+_0x189033('0x2296'),_0x49e3c6=_0x180212['p']+_0x189033('0x1a23'),_0x33f563=_0x180212['p']+_0x189033('0xdf4'),_0x31c6bf=_0x180212['p']+'src/js/modules/main/apps/mail/views/mailAccounts/edit/apps/noop/dialog.html/dialog.html',_0x310b08=_0x180212['p']+_0x189033('0x13a1'),_0x26703d=_0x180212['p']+_0x189033('0xd44'),_0x31e681=_0x180212['p']+_0x189033('0xf8b');_0x1d0eb2['$inject']=[_0x189033('0x56b'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d70'),'Auth'];const _0x5249a3={'agent':_0x35f8b6,'autoreply':_0x2b3704,'close':_0x5ba39b,'gotoif':_0x44b505,'gotop':_0x49e3c6,'interval':_0x33f563,'noop':_0x31c6bf,'queue':_0x310b08,'system':_0x26703d,'tag':_0x31e681};function _0x1d0eb2(_0x235159,_0x2d4351,_0x474a6c,_0x44d3da,_0x5b7aab){const _0x3a0f76=_0x189033,_0x17a0ee=this;_0x17a0ee[_0x3a0f76('0x11ed')]=_0x5b7aab[_0x3a0f76('0x20b2')](),_0x17a0ee['mailAccount']={},_0x17a0ee[_0x3a0f76('0x1552')]={'count':0x0,'rows':[]},_0x17a0ee['selectedMailAccountApps']=[],_0x17a0ee[_0x3a0f76('0x1134')],_0x17a0ee['query']={'sort':_0x3a0f76('0xe1e')},_0x17a0ee[_0x3a0f76('0x346')]=_0x2e3ca0()['reject'](_0x2e3ca0()['sortBy']([{'app':_0x3a0f76('0x22ee'),'appType':'interval','types':[_0x3a0f76('0x10af'),_0x3a0f76('0xbf0'),_0x3a0f76('0x2335')],'fields':[],'isApp':![]},{'app':_0x3a0f76('0x1126'),'appType':_0x3a0f76('0x1126'),'type':_0x3a0f76('0x1126'),'icon':_0x3a0f76('0x7ee'),'interval':'*,*,*,*','required':!![],'isApp':!![],'fields':[{'title':'Value','name':_0x3a0f76('0x1c6b'),'type':_0x3a0f76('0x1bcd'),'param':0x0}]},{'app':_0x3a0f76('0x24f2'),'appType':_0x3a0f76('0x24f2'),'type':_0x3a0f76('0x24f2'),'icon':_0x3a0f76('0x7ee'),'interval':'*,*,*,*','required':!![],'isApp':!![],'extraApi':[{'name':_0x3a0f76('0x220b'),'field':{'name':_0x3a0f76('0x26e0'),'key':_0x3a0f76('0x60a')},'route':_0x3a0f76('0x26e0'),'filters':{'fields':'id,name','sort':_0x3a0f76('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':'Command','name':_0x3a0f76('0x6db'),'type':_0x3a0f76('0x1bcd'),'required':!![],'param':0x0},{'title':'Variable','name':_0x3a0f76('0x26e0'),'type':_0x3a0f76('0x1aae'),'values':_0x3a0f76('0x220b'),'value':_0x3a0f76('0x2277'),'option':_0x3a0f76('0x2277'),'defaultValues':[{'value':'\x27\x27','option':_0x3a0f76('0x2749')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':_0x3a0f76('0x1da0'),'appType':_0x3a0f76('0x1da0'),'type':_0x3a0f76('0x27fe'),'icon':_0x3a0f76('0x7ee'),'interval':_0x3a0f76('0x1b54'),'isApp':!![],'fields':[{'title':'Priority','name':_0x3a0f76('0xe1e'),'type':_0x3a0f76('0x121f'),'required':!![],'min':0x0,'param':0x0}]},{'app':_0x3a0f76('0xc33'),'appType':_0x3a0f76('0xc33'),'type':_0x3a0f76('0xc33'),'icon':_0x3a0f76('0x7ee'),'interval':_0x3a0f76('0x1b54'),'isApp':!![],'fields':[{'title':_0x3a0f76('0xe0d'),'name':_0x3a0f76('0x168e'),'type':_0x3a0f76('0x1bcd'),'required':!![],'param':0x0},{'title':_0x3a0f76('0x27e5'),'name':_0x3a0f76('0x27e5'),'type':_0x3a0f76('0x121f'),'min':0x1,'required':!![],'param':0x1},{'title':_0x3a0f76('0x1813'),'name':_0x3a0f76('0x1813'),'type':'number','min':0x1,'required':!![],'param':0x2}]},{'app':_0x3a0f76('0x660'),'appType':_0x3a0f76('0x660'),'foreignKey':'MailQueueId','type':_0x3a0f76('0x660'),'icon':_0x3a0f76('0x7ee'),'interval':_0x3a0f76('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x3a0f76('0x2da'),'field':{'name':_0x3a0f76('0x660'),'key':_0x3a0f76('0x60a')},'route':_0x3a0f76('0x2160'),'filters':{'fields':_0x3a0f76('0x2035'),'sort':'name','nolimit':!![]},'permissions':{'section':0x259}}],'fields':[{'title':_0x3a0f76('0x1fa'),'name':'queue','type':_0x3a0f76('0x1aae'),'values':_0x3a0f76('0x2da'),'value':'queue.name','option':'queue.name','defaultValue':0x12c,'required':!![],'param':0x0},{'title':_0x3a0f76('0xa09'),'name':_0x3a0f76('0x1668'),'type':_0x3a0f76('0x121f'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x12c,'param':0x1}]},{'app':_0x3a0f76('0x2327'),'appType':_0x3a0f76('0x2327'),'type':'agent','foreignKey':_0x3a0f76('0x10c5'),'icon':_0x3a0f76('0x7ee'),'interval':_0x3a0f76('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x3a0f76('0x756'),'field':{'name':_0x3a0f76('0x2327'),'key':_0x3a0f76('0x60a')},'route':_0x3a0f76('0xc96'),'filters':{'fields':'id,name','sort':_0x3a0f76('0x60a'),'nolimit':!![],'role':_0x3a0f76('0x2327')},'permissions':{'section':0xca}}],'fields':[{'title':_0x3a0f76('0x62c'),'name':'agent','type':_0x3a0f76('0x1aae'),'values':_0x3a0f76('0x756'),'value':_0x3a0f76('0x1ed0'),'option':_0x3a0f76('0x1ed0'),'required':!![],'param':0x0},{'title':_0x3a0f76('0xa09'),'name':'timeout','type':_0x3a0f76('0x121f'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':_0x3a0f76('0x2408'),'appType':_0x3a0f76('0x2408'),'type':'autoreply','icon':_0x3a0f76('0x7ee'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':'times','name':_0x3a0f76('0x35'),'type':_0x3a0f76('0xb31'),'defaultValue':'1','values':[{'option':_0x3a0f76('0x26bb'),'value':'1'},{'option':'Always','value':'0'}],'required':!![],'param':0x0},{'title':_0x3a0f76('0x1d8c'),'name':'text','type':_0x3a0f76('0x84'),'required':!![],'param':0x1}]},{'app':'close','appType':_0x3a0f76('0x12b0'),'type':'close','icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':'Disposition','name':'disposition','type':'text','required':!![],'param':0x0}]},{'app':_0x3a0f76('0x270'),'appType':'tag','type':_0x3a0f76('0x270'),'foreignKey':_0x3a0f76('0xb6d'),'icon':'icon-apps','interval':_0x3a0f76('0x1b54'),'isApp':!![],'extraApi':[{'name':'tags','field':{'name':_0x3a0f76('0x270'),'key':_0x3a0f76('0x60a')},'route':_0x3a0f76('0x270'),'filters':{'fields':_0x3a0f76('0xa10'),'sort':_0x3a0f76('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x3a0f76('0x1e'),'name':_0x3a0f76('0x270'),'type':_0x3a0f76('0x1aae'),'values':'tags','value':'tag.name','option':'tag.name','required':!![],'param':0x0}]}],['app']),{'isApp':![]}),_0x17a0ee[_0x3a0f76('0x2335')]={'group':{'name':_0x3a0f76('0x11bf'),'pull':_0x3a0f76('0x147f')},'animation':0x64,'sort':![]},_0x17a0ee[_0x3a0f76('0x2146')]={'group':{'name':_0x3a0f76('0x489'),'put':_0x3a0f76('0x11bf')},'animation':0x64,'onAdd':function(_0xf749f){const _0x5d9972=_0x3a0f76;_0x160e74(_0xf749f,_0xf749f[_0x5d9972('0x1ce1')]);},'onSort':function(){_0x137b2a();}},_0x17a0ee[_0x3a0f76('0x12f3')]=_0x234828,_0x17a0ee[_0x3a0f76('0x26eb')]=_0x48f4ea,_0x17a0ee['getMailAccountApps']=_0x4f9b85,_0x17a0ee[_0x3a0f76('0xe49')]=_0x160e74,_0x17a0ee['editInterval']=_0x29c713,_0x17a0ee[_0x3a0f76('0x757')]=_0x426f70,_0x17a0ee[_0x3a0f76('0x1005')]=_0x1dcf77,_0x17a0ee[_0x3a0f76('0x13f5')]=_0x137b2a,_0x17a0ee[_0x3a0f76('0x14a')]=_0x4324c5;function _0x234828(_0x2201ff,_0x24791b){const _0x2fc4a1=_0x3a0f76;_0x17a0ee['mailAccount']=_0x2201ff,_0x17a0ee[_0x2fc4a1('0x1134')]=typeof _0x24791b!==_0x2fc4a1('0x1867')?_0x24791b:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x17a0ee['applications']['disabled']=!_0x17a0ee['crudPermissions']['canEdit']?!![]:![],_0x17a0ee[_0x2fc4a1('0x23a2')]['id']=_0x2201ff['id'],_0x17a0ee[_0x2fc4a1('0x23a2')][_0x2fc4a1('0x12a8')]=!![],_0x17a0ee[_0x2fc4a1('0x23a2')][_0x2fc4a1('0x2088')]=!![],_0x17a0ee[_0x2fc4a1('0xff4')](),_0x17a0ee[_0x2fc4a1('0x14a')]();}function _0x48f4ea(_0x1f3047,_0xe7c73,_0x20792c){const _0x26d834=_0x3a0f76,_0x4a23b6=_0x2d4351[_0x26d834('0x1c6f')]()[_0x26d834('0xf28')](_0x26d834('0x421'))['htmlContent'](_0x26d834('0xed5')+_0x1f3047['app']+_0x26d834('0x20f1')+'\x20will\x20be\x20deleted.')[_0x26d834('0x1040')](_0x26d834('0x1312'))[_0x26d834('0xe42')](_0x20792c)['ok']('OK')[_0x26d834('0x19fb')](_0x26d834('0x16b8'));_0x2d4351[_0x26d834('0x1d4')](_0x4a23b6)['then'](function(){const _0xc0805c=_0x26d834;_0x17a0ee[_0xc0805c('0x1552')][_0xc0805c('0xf5d')][_0xc0805c('0x2040')](_0xe7c73,0x1),_0x137b2a();},function(){const _0x37302a=_0x26d834;console['log'](_0x37302a('0x16b8'));});}function _0x160e74(_0x165477,_0x11c27c){const _0x30248a=_0x3a0f76;if(_0x17a0ee[_0x30248a('0x1552')]['rows']['length']){const _0x5a740d=_0x17a0ee['mailAccountApps'][_0x30248a('0xf5d')][_0x11c27c]?_0x17a0ee[_0x30248a('0x1552')][_0x30248a('0xf5d')][_0x11c27c]:_0x17a0ee[_0x30248a('0x1552')][_0x30248a('0xf5d')][0x0],_0x463256=(_0x5a740d[_0x30248a('0x11f3')]||_0x5a740d[_0x30248a('0x1d75')])[_0x30248a('0x93a')]();_0x2d4351[_0x30248a('0x1d4')]({'controller':_0x30248a('0x2414')+_0x463256+_0x30248a('0x9e4'),'controllerAs':'vm','templateUrl':_0x5249a3[_0x463256],'parent':angular[_0x30248a('0x1fcc')](_0x474a6c['body']),'targetEvent':_0x165477,'clickOutsideToClose':!![],'locals':{'mailAccountApp':_0x5a740d,'mailAccount':_0x17a0ee['mailAccount'],'crudPermissions':_0x17a0ee[_0x30248a('0x1134')]}})['then'](function(_0x447f63){const _0x2c4733=_0x30248a;_0x447f63&&(_0x447f63['id']?_0x17a0ee['mailAccountApps'][_0x2c4733('0xf5d')][_0x11c27c]=_0x447f63:_0x17a0ee[_0x2c4733('0x1552')][_0x2c4733('0xf5d')]['splice'](_0x11c27c,0x0,_0x447f63),_0x137b2a());})['catch'](function(_0x43e23b){const _0x4273d3=_0x30248a;_0x43e23b&&_0x44d3da['error']({'title':_0x43e23b[_0x4273d3('0x13ee')]?_0x4273d3('0x2168')+_0x43e23b[_0x4273d3('0x13ee')]+_0x4273d3('0xbf6')+_0x43e23b[_0x4273d3('0x24a9')]:_0x4273d3('0xf1b'),'msg':_0x43e23b['data']?JSON[_0x4273d3('0x258a')](_0x43e23b['data']):_0x43e23b[_0x4273d3('0x1ff0')]()});});}}function _0x29c713(_0x4bde26,_0x39710f){const _0x12b78a=_0x3a0f76;if(_0x17a0ee[_0x12b78a('0x1552')][_0x12b78a('0xf5d')][_0x12b78a('0x1564')]){const _0x59e425=_0x17a0ee['mailAccountApps'][_0x12b78a('0xf5d')][_0x39710f]?_0x17a0ee['mailAccountApps'][_0x12b78a('0xf5d')][_0x39710f]:_0x17a0ee[_0x12b78a('0x1552')]['rows'][0x0];_0x2d4351[_0x12b78a('0x1d4')]({'controller':_0x12b78a('0xb43'),'controllerAs':'vm','templateUrl':_0x33f563,'parent':angular['element'](_0x474a6c[_0x12b78a('0x18e5')]),'targetEvent':_0x4bde26,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x59e425[_0x12b78a('0x115c')],'IntervalId':_0x59e425['IntervalId'],'application':!![]},'intervals':[],'crudPermissions':_0x17a0ee[_0x12b78a('0x1134')]}})['then'](function(_0x2e0d77){const _0x24126d=_0x12b78a;_0x2e0d77&&(_0x59e425[_0x24126d('0x115c')]=_0x2e0d77[_0x24126d('0x115c')]||_0x24126d('0x1b54'),_0x59e425[_0x24126d('0x5ae')]=_0x2e0d77[_0x24126d('0x5ae')]||null,_0x137b2a());});}}function _0x137b2a(){const _0x4aa5c4=_0x3a0f76;let _0x416f34=0x1,_0x1af250=[];for(let _0x17a566=0x0;_0x17a566<_0x17a0ee[_0x4aa5c4('0x1552')][_0x4aa5c4('0xf5d')]['length'];_0x17a566++){const _0x42f9bf=_0x17a0ee[_0x4aa5c4('0x1552')][_0x4aa5c4('0xf5d')][_0x17a566],_0x56c880=[],_0x2155ee=[];_0x42f9bf[_0x4aa5c4('0xe98')]=_0x42f9bf[_0x4aa5c4('0x115c')]!==_0x4aa5c4('0x1b54')?[_0x42f9bf[_0x4aa5c4('0x115c')]]:_0x42f9bf[_0x4aa5c4('0x5ae')]?_0x2e3ca0()[_0x4aa5c4('0x386')](_0x2e3ca0()[_0x4aa5c4('0x25')](_0x17a0ee[_0x4aa5c4('0xe98')][_0x4aa5c4('0xf5d')],{'IntervalId':_0x42f9bf[_0x4aa5c4('0x5ae')]}),_0x4aa5c4('0x115c')):[],_0x42f9bf[_0x4aa5c4('0x22d3')]=_0x17a0ee[_0x4aa5c4('0xb87')]['context'],_0x42f9bf[_0x4aa5c4('0x1a5b')]=_0x17a0ee['mailAccount']['exten'],_0x42f9bf['type']&&(_0x42f9bf[_0x4aa5c4('0xcf0')]=_0x42f9bf[_0x4aa5c4('0xcf0')][_0x4aa5c4('0x93a')]()),_0x42f9bf[_0x4aa5c4('0xe1e')]=_0x56c880[_0x4aa5c4('0x1564')]?_0x2e3ca0()[_0x4aa5c4('0xc0f')](_0x56c880)[_0x4aa5c4('0xe1e')]+0x1:_0x416f34,_0x416f34=(_0x2155ee[_0x4aa5c4('0x1564')]?_0x2e3ca0()['last'](_0x2155ee)[_0x4aa5c4('0xe1e')]:_0x42f9bf[_0x4aa5c4('0xe1e')])+0x1,_0x1af250=_0x2e3ca0()['concat'](_0x1af250,_0x56c880,[_0x42f9bf],_0x2155ee);}_0x235159[_0x4aa5c4('0xb87')]['addApplications']({'id':_0x17a0ee['mailAccount']['id']},_0x2e3ca0()[_0x4aa5c4('0x742')](_0x1af250,_0x4aa5c4('0xe1e')))[_0x4aa5c4('0xe53')]['then'](function(_0x269be0){const _0x60cab6=_0x4aa5c4;_0x17a0ee[_0x60cab6('0x1552')][_0x60cab6('0xf5d')]=_0x269be0[_0x60cab6('0xf5d')];})['catch'](function(_0x242113){const _0x29c895=_0x4aa5c4;console[_0x29c895('0x52a')](_0x242113);});}function _0x5f143e(_0x1fd1ab){const _0x27a5dc=_0x3a0f76;_0x17a0ee[_0x27a5dc('0x1552')]=_0x1fd1ab||{'count':0x0,'rows':[]};}function _0x4324c5(){const _0x42c746=_0x3a0f76;return _0x235159[_0x42c746('0x115c')][_0x42c746('0x1e6e')]({'fields':_0x42c746('0x2072')})[_0x42c746('0xe53')][_0x42c746('0x683')](function(_0x565033){_0x17a0ee['intervals']=_0x565033;})['catch'](function(_0xe3021c){const _0x3eba78=_0x42c746;console[_0x3eba78('0x52a')](_0xe3021c);});}function _0x4f9b85(){const _0x104264=_0x3a0f76;_0x17a0ee[_0x104264('0x1883')]=_0x235159[_0x104264('0xb87')][_0x104264('0x13be')](_0x17a0ee[_0x104264('0x23a2')],_0x5f143e)[_0x104264('0xe53')];}function _0x426f70(_0x6380ca){const _0x30a700=_0x3a0f76;_0x2e3ca0()[_0x30a700('0x3ec')](_0x17a0ee[_0x30a700('0x1552')][_0x30a700('0xf5d')],{'id':_0x6380ca['id']}),_0x137b2a(),_0x44d3da[_0x30a700('0x53')]({'title':'App\x20deleted!','msg':_0x6380ca[_0x30a700('0x1d75')]?_0x6380ca[_0x30a700('0x1d75')]+'\x20has\x20been\x20deleted!':''});}function _0x1dcf77(_0x5ddc7e){const _0x5e559f=_0x3a0f76,_0x2e5180=_0x2d4351['confirm']()['title'](_0x5e559f('0x188'))[_0x5e559f('0x26e3')](''+_0x17a0ee['selectedMailAccountApps']['length']+'\x20selected'+_0x5e559f('0x1ee7'))[_0x5e559f('0x1040')]('delete\x20applications')['targetEvent'](_0x5ddc7e)['ok']('OK')[_0x5e559f('0x19fb')](_0x5e559f('0x16b8'));_0x2d4351[_0x5e559f('0x1d4')](_0x2e5180)['then'](function(){const _0x562983=_0x5e559f;_0x17a0ee[_0x562983('0xf17')][_0x562983('0x1299')](function(_0x46bf08){const _0x1b264c=_0x562983;_0x2e3ca0()[_0x1b264c('0x3ec')](_0x17a0ee[_0x1b264c('0x1552')]['rows'],{'id':_0x46bf08['id']});}),_0x17a0ee[_0x562983('0xf17')]=[],_0x137b2a();});}}const _0xf31dec=_0x1d0eb2;_0x242cbc[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xb87'),_0x189033('0x1093'),_0x189033('0x2c9'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x242cbc(_0x2fed9a,_0x2acbdb,_0xe7f39d,_0x5a9220,_0x25bb9e,_0x30ca47,_0x1545a3,_0x36f25c,_0x51b6bc,_0x56e019){const _0x360b9f=_0x189033,_0x1eccd4=this;_0x1eccd4[_0x360b9f('0x11ed')]=_0x51b6bc[_0x360b9f('0x20b2')](),_0x1eccd4['mailAccount']=_0x25bb9e,_0x1eccd4[_0x360b9f('0x1134')]=_0x56e019,_0x1eccd4['realtime']=_0x1545a3,_0x1eccd4[_0x360b9f('0x1996')]=[],_0x1eccd4[_0x360b9f('0x1c47')]=[],_0x1eccd4[_0x360b9f('0x1378')]=[],_0x1eccd4[_0x360b9f('0x125e')]=[],_0x1eccd4[_0x360b9f('0x23a7')]=[],_0x1eccd4['pendingChanges']=![],_0x1eccd4['onInit']=_0x1fafd6,_0x1eccd4[_0x360b9f('0xa5f')]=_0x2ee865,_0x1eccd4['closeDialog']=_0x2f9810,_0x1eccd4[_0x360b9f('0x169f')]={'readOnly':!_0x1eccd4[_0x360b9f('0x1134')][_0x360b9f('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x360b9f('0x60a'),'line1':_0x360b9f('0x11bc'),'line2':['name',_0x360b9f('0x1d43')],'line3':'','labelAll':_0x36f25c[_0x360b9f('0x2728')](_0x360b9f('0x973')),'labelSelected':_0x36f25c[_0x360b9f('0x2728')](_0x360b9f('0xd0a')),'transferCallback':function(){const _0x174fe3=_0x360b9f,_0x88fd98=_0x2e3ca0()[_0x174fe3('0x25cb')](_0x1eccd4[_0x174fe3('0x23a7')],_0x1eccd4[_0x174fe3('0x1378')],'id');_0x1eccd4['pendingChanges']=_0x2e3ca0()['isEmpty'](_0x88fd98)?![]:!![];}};function _0x1fafd6(){const _0x217182=_0x360b9f;return _0x51b6bc[_0x217182('0xca1')](_0x217182('0x20c2'))?_0xca157()[_0x217182('0x130a')](function(_0x456538){const _0x1aa3e6=_0x217182;_0xe7f39d[_0x1aa3e6('0x52a')]({'title':_0x456538['status']?_0x1aa3e6('0x2168')+_0x456538[_0x1aa3e6('0x13ee')]+_0x1aa3e6('0xbf6')+_0x456538[_0x1aa3e6('0x24a9')]:_0x1aa3e6('0x144f'),'msg':_0x456538[_0x1aa3e6('0x13ee')]?JSON[_0x1aa3e6('0x258a')](_0x456538[_0x1aa3e6('0x5a5')]):_0x456538[_0x1aa3e6('0x1ff0')]()});}):_0x302620()[_0x217182('0x683')](function(_0x52dbea){const _0x3febae=_0x217182;return _0x1eccd4[_0x3febae('0x1aa')]=_0x52dbea,_0xca157();})[_0x217182('0x130a')](function(_0x12fd30){const _0x265cbf=_0x217182;_0xe7f39d[_0x265cbf('0x52a')]({'title':_0x12fd30[_0x265cbf('0x13ee')]?_0x265cbf('0x2168')+_0x12fd30[_0x265cbf('0x13ee')]+_0x265cbf('0xbf6')+_0x12fd30[_0x265cbf('0x24a9')]:_0x265cbf('0x144f'),'msg':_0x12fd30[_0x265cbf('0x13ee')]?JSON[_0x265cbf('0x258a')](_0x12fd30[_0x265cbf('0x5a5')]):_0x12fd30[_0x265cbf('0x1ff0')]()});});}function _0x302620(){return _0x2acbdb(function(_0x3995f7,_0x4692f8){const _0x456e09=a0_0x4e0a;_0x5a9220[_0x456e09('0x22df')]['get']({'userProfileId':_0x1eccd4['currentUser'][_0x456e09('0x2f')],'name':_0x456e09('0x1bc0')})[_0x456e09('0xe53')][_0x456e09('0x683')](function(_0x43621a){const _0x37afe8=_0x456e09,_0x5c9da5=_0x43621a&&_0x43621a[_0x37afe8('0xf5d')]?_0x43621a['rows'][0x0]:null;_0x3995f7(_0x5c9da5);})[_0x456e09('0x130a')](function(_0x567c16){_0x4692f8(_0x567c16);});});}function _0xca157(){return _0x2acbdb(function(_0x59a0e2,_0x40661e){const _0x1c37b2=a0_0x4e0a;return _0x282450()[_0x1c37b2('0x683')](function(_0x2331ab){const _0x42871d=_0x1c37b2;return _0x1eccd4[_0x42871d('0x1996')]=_0x2331ab[_0x42871d('0xf5d')]?_0x2331ab[_0x42871d('0xf5d')]:[],_0x51b6bc[_0x42871d('0xca1')](_0x42871d('0x20c2'))?_0x2331ab:_0x1eccd4['section']?_0x1eccd4[_0x42871d('0x1aa')][_0x42871d('0x170')]?_0x2331ab:_0xdaf9c4():null;})[_0x1c37b2('0x683')](function(_0xa37c6c){const _0x4fb8db=_0x1c37b2,_0x43ea72=_0xa37c6c&&_0xa37c6c[_0x4fb8db('0xf5d')]?_0xa37c6c['rows']:[];return _0x1eccd4['allowedItems']=_0x2e3ca0()[_0x4fb8db('0x386')](_0x43ea72,function(_0x394784){const _0x467386=_0x4fb8db;return _0x2e3ca0()['find'](_0x1eccd4[_0x467386('0x1996')],{'id':_0x51b6bc[_0x467386('0xca1')](_0x467386('0x20c2'))||_0x1eccd4['section'][_0x467386('0x170')]?_0x394784['id']:_0x394784['resourceId']});}),_0x1eccd4[_0x4fb8db('0x125e')]=angular[_0x4fb8db('0x1a86')](_0x1eccd4[_0x4fb8db('0x1c47')]),_0x1eccd4['items'][_0x4fb8db('0x1299')](function(_0x19c61c){const _0x359bbe=_0x4fb8db,_0x167824=_0x2e3ca0()['find'](_0x1eccd4[_0x359bbe('0x1c47')],{'id':_0x19c61c['id']});_0x51b6bc[_0x359bbe('0xca1')]('admin')?_0x19c61c[_0x359bbe('0x24f4')]=!![]:_0x19c61c[_0x359bbe('0x24f4')]=typeof _0x167824!==_0x359bbe('0x1867')?!![]:![];}),_0x2aec66();})[_0x1c37b2('0x683')](function(_0x5763ec){const _0x41d86c=_0x1c37b2,_0x55fc55=_0x5763ec&&_0x5763ec[_0x41d86c('0xf5d')]?_0x5763ec['rows']:[];_0x1eccd4[_0x41d86c('0x1378')]=_0x2e3ca0()[_0x41d86c('0x386')](_0x55fc55,function(_0x4d1ae3){const _0x8da395=_0x41d86c,_0x55b7ff=_0x2e3ca0()[_0x8da395('0x1c07')](_0x1eccd4[_0x8da395('0x1996')],{'id':_0x4d1ae3['id']});return _0x55b7ff[_0x8da395('0x1e2a')]=_0x4d1ae3[_0x8da395('0x240e')]?'penalty\x20'+_0x4d1ae3['UserMailAccount'][_0x8da395('0x1e2a')]:'',_0x55b7ff[_0x8da395('0x1d43')]=typeof _0x4d1ae3[_0x8da395('0x1d43')]!=='undefined'?'<'+_0x4d1ae3[_0x8da395('0x1d43')]+'>':'',_0x55b7ff;}),_0x1eccd4[_0x41d86c('0x23a7')]=angular[_0x41d86c('0x1a86')](_0x1eccd4['selectedItems']),_0x1eccd4[_0x41d86c('0x169f')][_0x41d86c('0x1378')]=_0x1eccd4[_0x41d86c('0x1378')],_0x1eccd4[_0x41d86c('0x169f')][_0x41d86c('0x1996')]=_0x2e3ca0()['differenceBy'](_0x1eccd4[_0x41d86c('0x1c47')],_0x1eccd4['dualMultiselectOptions'][_0x41d86c('0x1378')],'id'),_0x59a0e2();})[_0x1c37b2('0x130a')](function(_0x4630f9){_0x40661e(_0x4630f9);});});}function _0xdaf9c4(){return _0x2acbdb(function(_0x1eca80,_0x2ffaac){const _0x55a6ef=a0_0x4e0a;return _0x5a9220[_0x55a6ef('0xcf7')][_0x55a6ef('0x1e6e')]({'sectionId':_0x1eccd4['section']['id'],'nolimit':!![]})['$promise'][_0x55a6ef('0x683')](function(_0x492077){_0x1eca80(_0x492077);})['catch'](function(_0x3a4334){_0x2ffaac(_0x3a4334);});});}function _0x2aec66(){return _0x2acbdb(function(_0x4215d2,_0x12b3e2){const _0x12e763=a0_0x4e0a;return _0x5a9220[_0x12e763('0xb87')][_0x12e763('0x8e7')]({'id':_0x1eccd4[_0x12e763('0xb87')]['id'],'fields':_0x12e763('0x72b'),'nolimit':!![],'role':_0x12e763('0x2327')})[_0x12e763('0xe53')]['then'](function(_0x3a87ff){_0x4215d2(_0x3a87ff);})['catch'](function(_0xf1eaf){_0x12b3e2(_0xf1eaf);});});}function _0x282450(){return _0x2acbdb(function(_0x8132d9,_0x2c8b0c){const _0x2b246e=a0_0x4e0a;return _0x5a9220['user'][_0x2b246e('0x1e6e')]({'fields':_0x2b246e('0x72b'),'nolimit':!![],'role':'agent'})['$promise'][_0x2b246e('0x683')](function(_0x4d8209){_0x8132d9(_0x4d8209);})['catch'](function(_0x1a4902){_0x2c8b0c(_0x1a4902);});});}function _0x1c858d(_0x30480f){return _0x2acbdb(function(_0x3eae4a,_0x11dc90){const _0x4816d0=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0x30480f)?_0x3eae4a():_0x5a9220[_0x4816d0('0xb87')][_0x4816d0('0x2179')]({'id':_0x1eccd4[_0x4816d0('0xb87')]['id'],'ids':_0x2e3ca0()['map'](_0x30480f,'id')})[_0x4816d0('0xe53')][_0x4816d0('0x683')](function(){_0x3eae4a();})[_0x4816d0('0x130a')](function(_0x65e8bf){_0x11dc90(_0x65e8bf);});});}function _0xfc4e07(_0x38469a){return _0x2acbdb(function(_0x3e9254,_0x2aca47){const _0x50b602=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0x38469a)?_0x3e9254():_0x5a9220[_0x50b602('0xb87')][_0x50b602('0xf9')]({'id':_0x1eccd4['mailAccount']['id'],'ids':_0x2e3ca0()[_0x50b602('0x386')](_0x38469a,'id')})[_0x50b602('0xe53')][_0x50b602('0x683')](function(){_0x3e9254();})[_0x50b602('0x130a')](function(_0x1b64ca){_0x2aca47(_0x1b64ca);});});}function _0x2ee865(){const _0x1b94ef=_0x360b9f,_0x266e91=_0x2e3ca0()[_0x1b94ef('0x461')](_0x1eccd4[_0x1b94ef('0x23a7')],_0x1eccd4[_0x1b94ef('0x1378')],'id'),_0x53e208=_0x2e3ca0()[_0x1b94ef('0x461')](_0x1eccd4[_0x1b94ef('0x1378')],_0x1eccd4['startingSelectedItems'],'id');return _0xfc4e07(_0x266e91)[_0x1b94ef('0x683')](function(){return _0x1c858d(_0x53e208);})[_0x1b94ef('0x683')](function(){const _0x5bc2fd=_0x1b94ef;_0x1eccd4['pendingChanges']=![],_0x1eccd4[_0x5bc2fd('0x125e')]=angular['copy'](_0x1eccd4[_0x5bc2fd('0x1c47')]),_0x1eccd4[_0x5bc2fd('0x23a7')]=angular[_0x5bc2fd('0x1a86')](_0x1eccd4[_0x5bc2fd('0x1378')]),_0xe7f39d[_0x5bc2fd('0x53')]({'title':'SUCCESS','msg':'Agents\x20association\x20has\x20been\x20updated!'});})['catch'](function(_0xdc1dcd){const _0x3ab63c=_0x1b94ef;_0xe7f39d[_0x3ab63c('0x52a')]({'title':_0xdc1dcd[_0x3ab63c('0x13ee')]?_0x3ab63c('0x2168')+_0xdc1dcd[_0x3ab63c('0x13ee')]+_0x3ab63c('0xbf6')+_0xdc1dcd[_0x3ab63c('0x24a9')]:_0x3ab63c('0x1b71'),'msg':_0xdc1dcd[_0x3ab63c('0x13ee')]?JSON[_0x3ab63c('0x258a')](_0xdc1dcd['data']):_0xdc1dcd[_0x3ab63c('0x1ff0')]()});});}function _0x2f9810(){const _0x32535b=_0x360b9f;_0x2fed9a[_0x32535b('0x1715')]();}}const _0xddf1e0=_0x242cbc;_0x5c1057['$inject']=['$mdDialog','$q','toasty',_0x189033('0x1cc0'),_0x189033('0xb87'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x5c1057(_0x5da660,_0x2e3933,_0x29c491,_0x27d103,_0x30655e,_0xcd64fc,_0x476adb,_0x56635d){const _0x1e214e=_0x189033,_0xc86409=this;_0xc86409[_0x1e214e('0x11ed')]=_0x476adb['getCurrentUser'](),_0xc86409[_0x1e214e('0x17f')]=[],_0xc86409[_0x1e214e('0xf28')]=_0x1e214e('0x3df')+(_0x27d103['appType']||_0x27d103[_0x1e214e('0x1d75')])[_0x1e214e('0x80')](),_0xc86409[_0x1e214e('0x2327')]=angular[_0x1e214e('0x1a86')](_0x27d103),_0xc86409[_0x1e214e('0x1134')]=_0x56635d,_0xc86409[_0x1e214e('0x258d')]={};if(_0xc86409[_0x1e214e('0x2327')]['appdata'])switch(_0xc86409[_0x1e214e('0x2327')]['appType']?_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x11f3')][_0x1e214e('0x93a')]():_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1d75')][_0x1e214e('0x93a')]()){case _0x1e214e('0xbf0'):break;case'dialogflow':{const _0x35662b=_0xc86409['agent'][_0x1e214e('0x1407')]['split'](',');_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1d46')]=_0x35662b[0x0],_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1a1c')]=_0x35662b[0x1],_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x6d9')]=_0x35662b['slice'](0x2,_0x35662b[_0x1e214e('0x1564')])['join'](',');}break;case'dialogflowv2':{const _0x1dd487=_0xc86409['agent'][_0x1e214e('0x1407')][_0x1e214e('0x1fc5')](',');_0xc86409['agent'][_0x1e214e('0x2119')]=_0x1dd487[0x0],_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x38')]=_0x1dd487[0x1],_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x406')]=_0x1dd487[0x2],_0xc86409['agent']['language']=_0x1dd487[0x3],_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x6d9')]=_0x1dd487[_0x1e214e('0x12c8')](0x4,_0x1dd487[_0x1e214e('0x1564')])['join'](',');}break;case _0x1e214e('0x1db1'):{const _0x4cbb60=_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1407')][_0x1e214e('0x1fc5')](',');_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x7ae')]=_0x4cbb60[0x0],_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x204a')]=_0x4cbb60[0x1],_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x5ba')]=_0x4cbb60[0x2],_0xc86409[_0x1e214e('0x2327')]['botname']=_0x4cbb60[0x3],_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x6d9')]=_0x4cbb60[_0x1e214e('0x12c8')](0x4,_0x4cbb60[_0x1e214e('0x1564')])[_0x1e214e('0x1630')](',');}break;case _0x1e214e('0x2408'):{const _0x41c736=_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1407')]['split'](',');_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x35')]=isNaN(_0x41c736[0x0])?_0x41c736[0x0]:parseInt(_0x41c736[0x0],0xa),_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1bcd')]=_0x41c736[_0x1e214e('0x12c8')](0x1,_0x41c736[_0x1e214e('0x1564')])[_0x1e214e('0x1630')](',');}break;case _0x1e214e('0x8c2'):_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1bcd')]=_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1407')];break;case'set':_0xc86409['agent'][_0x1e214e('0x60a')]=_0xc86409[_0x1e214e('0x2327')]['appdata'][_0x1e214e('0x1fc5')]('=')[0x0],_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1c6b')]=_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1407')][_0x1e214e('0x1fc5')]('=')[0x1];break;case _0x1e214e('0x19ae'):_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x273a')]=_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1407')];break;default:{const _0x3c9eb3=_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1407')]['split'](',');_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x2327')]=_0x2e3ca0()[_0x1e214e('0x173f')](_0x3c9eb3[0x0])?_0x3c9eb3[0x0]:isNaN(_0x3c9eb3[0x0])?_0x3c9eb3[0x0]:parseInt(_0x3c9eb3[0x0],0xa),_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1668')]=_0x2e3ca0()[_0x1e214e('0x173f')](_0x3c9eb3[0x1])?_0x3c9eb3[0x1]:isNaN(_0x3c9eb3[0x1])?_0x3c9eb3[0x1]:parseInt(_0x3c9eb3[0x1],0xa);}break;}else _0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x1668')]=0x1e;_0xc86409['agent'][_0x1e214e('0xcf0')]&&_0xc86409['agent'][_0x1e214e('0xcf0')][_0x1e214e('0x93a')]()==='outbound'&&_0xc86409[_0x1e214e('0x2327')]['appType']['toLowerCase']()===_0x1e214e('0x659')&&(_0xc86409['agent'][_0x1e214e('0x24fa')]=_0xc86409['agent'][_0x1e214e('0xd31')]?_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0xd31')]['split']('$')[0x0]:undefined,_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0xabd')]=_0xc86409['agent'][_0x1e214e('0x73c')]?_0x1e214e('0xac1')+_0xc86409[_0x1e214e('0x2327')][_0x1e214e('0x73c')]:undefined);_0xc86409[_0x1e214e('0x22a1')]=_0x2df2d1,_0xc86409[_0x1e214e('0xf82')]=_0x3a338d,_0x476adb['hasRole'](_0x1e214e('0x20c2'))?_0xcd64fc[_0x1e214e('0xc96')][_0x1e214e('0x1e6e')]({'fields':'id,name','sort':_0x1e214e('0x60a'),'nolimit':_0x1e214e('0x26ac'),'role':'agent'})[_0x1e214e('0xe53')][_0x1e214e('0x683')](function(_0x2b09c0){const _0xb3f0ad=_0x1e214e;_0xc86409['agents']=_0x2b09c0[_0xb3f0ad('0xf5d')]||[];})[_0x1e214e('0x130a')](function(_0x1d841e){const _0x20c053=_0x1e214e;_0x29c491[_0x20c053('0x52a')]({'title':_0x1d841e[_0x20c053('0x13ee')]?_0x20c053('0x2168')+_0x1d841e[_0x20c053('0x13ee')]+_0x20c053('0xbf6')+_0x1d841e[_0x20c053('0x24a9')]:_0x20c053('0x144f'),'msg':_0x1d841e[_0x20c053('0x5a5')]?JSON['stringify'](_0x1d841e[_0x20c053('0x5a5')]):_0x1d841e['toString']()});}):_0xcd64fc[_0x1e214e('0xc96')][_0x1e214e('0x1e6e')]({'fields':_0x1e214e('0xa10'),'sort':'name','nolimit':'true','role':_0x1e214e('0x2327')})[_0x1e214e('0xe53')][_0x1e214e('0x683')](function(_0x1c6938){const _0x292dd3=_0x1e214e;_0xc86409[_0x292dd3('0x756')]=_0x1c6938['rows']||[];})[_0x1e214e('0x683')](function(){const _0x24b60f=_0x1e214e;return _0xcd64fc[_0x24b60f('0x22df')][_0x24b60f('0x1e6e')]({'userProfileId':_0xc86409[_0x24b60f('0x11ed')][_0x24b60f('0x2f')],'sectionId':0xca})[_0x24b60f('0xe53')];})[_0x1e214e('0x683')](function(_0x521cb0){const _0x255d34=_0x1e214e,_0x209a43=_0x521cb0&&_0x521cb0[_0x255d34('0xf5d')]?_0x521cb0['rows'][0x0]:null;if(!_0x209a43){const _0x547315=[];let _0x4d9b7f=null;_0xc86409[_0x255d34('0x2327')]&&(_0x4d9b7f=_0x2e3ca0()['find'](_0xc86409[_0x255d34('0x756')],{'name':_0xc86409[_0x255d34('0x2327')][_0x255d34('0x2327')]}));for(let _0x22387b=0x0;_0x22387b<_0xc86409[_0x255d34('0x756')]['length'];_0x22387b++){_0x4d9b7f&&_0xc86409[_0x255d34('0x756')][_0x22387b]['id']===_0x4d9b7f['id']&&(_0xc86409['agents'][_0x22387b][_0x255d34('0x319')]=![],_0x547315[_0x255d34('0x1fd0')](_0xc86409[_0x255d34('0x756')][_0x22387b]));}_0xc86409[_0x255d34('0x756')]=_0x547315;}else{if(!_0x209a43[_0x255d34('0x170')])return _0xcd64fc[_0x255d34('0xcf7')][_0x255d34('0x1e6e')]({'sectionId':_0x209a43['id']})['$promise'][_0x255d34('0x683')](function(_0x1d34f1){const _0x5c4bfe=_0x255d34,_0x13e967=_0x2e3ca0()[_0x5c4bfe('0x386')](_0x1d34f1['rows'],function(_0x1f132c){const _0x57d719=_0x5c4bfe;return _0x2e3ca0()['find'](_0xc86409['agents'],{'id':_0x1f132c[_0x57d719('0x832')]});});let _0x3220a6=null;_0xc86409[_0x5c4bfe('0x2327')]&&(_0x3220a6=_0x2e3ca0()[_0x5c4bfe('0x1c07')](_0xc86409[_0x5c4bfe('0x756')],{'name':_0xc86409[_0x5c4bfe('0x2327')][_0x5c4bfe('0x2327')]}));if(_0x3220a6&&!_0x2e3ca0()[_0x5c4bfe('0x7a2')](_0x13e967,['id',_0x3220a6['id']])){const _0x51500e=_0x2e3ca0()['find'](_0xc86409[_0x5c4bfe('0x756')],{'id':_0x3220a6['id']});_0x51500e['canSelect']=![],_0x13e967['push'](_0x51500e);}_0xc86409[_0x5c4bfe('0x756')]=_0x13e967;});}})[_0x1e214e('0x130a')](function(_0x2629e4){const _0x3ffa76=_0x1e214e;_0x29c491[_0x3ffa76('0x52a')]({'title':_0x2629e4[_0x3ffa76('0x13ee')]?_0x3ffa76('0x2168')+_0x2629e4['status']+_0x3ffa76('0xbf6')+_0x2629e4[_0x3ffa76('0x24a9')]:_0x3ffa76('0x391'),'msg':_0x2629e4[_0x3ffa76('0x5a5')]?JSON[_0x3ffa76('0x258a')](_0x2629e4['data']):_0x2629e4[_0x3ffa76('0x1ff0')]()});});function _0x2df2d1(){const _0x2ce481=_0x1e214e;_0xc86409[_0x2ce481('0x17f')]=[];const _0x1ffe56=[];_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0xcf0')]&&_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0xcf0')][_0x2ce481('0x93a')]()==='outbound'&&_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x11f3')]===_0x2ce481('0x4d2')&&(_0xc86409['agent']['phone']=_0x30655e[_0x2ce481('0x145a')]?(_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x24fa')]||'')+_0x2ce481('0x249e')+_0x30655e[_0x2ce481('0x145a')]+'}':(_0xc86409[_0x2ce481('0x2327')]['prefix']||'')+'${EXTEN}',_0x30655e[_0x2ce481('0x75b')]!==_0x2ce481('0x925')?_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x158e')]['indexOf']('U(xcally-mixmonitor-context)')<0x0&&(_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x158e')]+=_0x2ce481('0x1b1')):_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x158e')]=_0xc86409['agent'][_0x2ce481('0x158e')][_0x2ce481('0x1725')](_0x2ce481('0x1b1'),''));const _0x36c6cc=_0x2e3ca0()[_0x2ce481('0x1c07')](_0xc86409[_0x2ce481('0x756')],{'name':_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x2327')]});_0x36c6cc&&(_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x10c5')]=_0x36c6cc['id']);if(_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x11f3')]&&_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x11f3')]===_0x2ce481('0xbf0')){}else switch((_0xc86409['agent'][_0x2ce481('0x1d75')]||_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x11f3')])['toLowerCase']()){case _0x2ce481('0x877'):_0xc86409['agent'][_0x2ce481('0x1407')]=_0xc86409[_0x2ce481('0x2327')]['name']+'='+_0xc86409[_0x2ce481('0x2327')]['value'];break;case _0x2ce481('0xbf0'):break;default:_0x1ffe56[0x0]=_0xc86409[_0x2ce481('0x2327')]['agent'],_0x1ffe56[0x1]=_0xc86409[_0x2ce481('0x2327')][_0x2ce481('0x1668')],_0xc86409['agent']['appdata']=_0x1ffe56['join'](',');}_0x3a338d(_0xc86409[_0x2ce481('0x2327')]);}function _0x3a338d(_0x57ff1e){_0x5da660['hide'](_0x57ff1e);}}const _0x99671a=_0x5c1057;_0x26a000[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x1cc0'),'mailAccount','api',_0x189033('0xba1'),'crudPermissions'];function _0x26a000(_0x4dea39,_0x4dbb14,_0x3335a3,_0x4b2839,_0x556e5f,_0x390a20,_0x256c72,_0x36e8d9){const _0x50d46c=_0x189033,_0xf2dcdc=this;_0xf2dcdc[_0x50d46c('0x11ed')]=_0x256c72[_0x50d46c('0x20b2')](),_0xf2dcdc[_0x50d46c('0x17f')]=[],_0xf2dcdc['title']=_0x50d46c('0x3df')+(_0x4b2839[_0x50d46c('0x11f3')]||_0x4b2839['app'])[_0x50d46c('0x80')](),_0xf2dcdc[_0x50d46c('0x2408')]=angular[_0x50d46c('0x1a86')](_0x4b2839),_0xf2dcdc[_0x50d46c('0x1134')]=_0x36e8d9,_0xf2dcdc[_0x50d46c('0x258d')]={};if(_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x1407')])switch(_0xf2dcdc[_0x50d46c('0x2408')]['appType']?_0xf2dcdc[_0x50d46c('0x2408')]['appType'][_0x50d46c('0x93a')]():_0xf2dcdc[_0x50d46c('0x2408')]['app']['toLowerCase']()){case'custom':break;case _0x50d46c('0x205c'):{const _0x4f77b0=_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x1407')]['split'](',');_0xf2dcdc['autoreply'][_0x50d46c('0x1d46')]=_0x4f77b0[0x0],_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x1a1c')]=_0x4f77b0[0x1],_0xf2dcdc['autoreply']['welcomemessage']=_0x4f77b0['slice'](0x2,_0x4f77b0[_0x50d46c('0x1564')])[_0x50d46c('0x1630')](',');}break;case _0x50d46c('0xd24'):{const _0x5e5a45=_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x1407')]['split'](',');_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x2119')]=_0x5e5a45[0x0],_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x38')]=_0x5e5a45[0x1],_0xf2dcdc['autoreply']['privateKey']=_0x5e5a45[0x2],_0xf2dcdc[_0x50d46c('0x2408')]['language']=_0x5e5a45[0x3],_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x6d9')]=_0x5e5a45[_0x50d46c('0x12c8')](0x4,_0x5e5a45[_0x50d46c('0x1564')])[_0x50d46c('0x1630')](',');}break;case'amazonlex':{const _0x5e78f9=_0xf2dcdc['autoreply'][_0x50d46c('0x1407')][_0x50d46c('0x1fc5')](',');_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x7ae')]=_0x5e78f9[0x0],_0xf2dcdc[_0x50d46c('0x2408')]['secretaccesskey']=_0x5e78f9[0x1],_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x5ba')]=_0x5e78f9[0x2],_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x11a9')]=_0x5e78f9[0x3],_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x6d9')]=_0x5e78f9[_0x50d46c('0x12c8')](0x4,_0x5e78f9[_0x50d46c('0x1564')])[_0x50d46c('0x1630')](',');}break;case _0x50d46c('0x2408'):{const _0x2da162=_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x1407')][_0x50d46c('0x1fc5')](',');_0xf2dcdc['autoreply']['times']=isNaN(_0x2da162[0x0])?_0x2da162[0x0]:parseInt(_0x2da162[0x0],0xa),_0xf2dcdc[_0x50d46c('0x2408')]['text']=_0x2da162['slice'](0x1,_0x2da162[_0x50d46c('0x1564')])[_0x50d46c('0x1630')](',');}break;case'message':_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x1bcd')]=_0xf2dcdc['autoreply'][_0x50d46c('0x1407')];break;case _0x50d46c('0x877'):_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x60a')]=_0xf2dcdc['autoreply'][_0x50d46c('0x1407')]['split']('=')[0x0],_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x1c6b')]=_0xf2dcdc[_0x50d46c('0x2408')]['appdata'][_0x50d46c('0x1fc5')]('=')[0x1];break;case'agi':_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x273a')]=_0xf2dcdc['autoreply']['appdata'];break;default:{const _0x56a24d=_0xf2dcdc['autoreply'][_0x50d46c('0x1407')][_0x50d46c('0x1fc5')](',');_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x35')]=_0x2e3ca0()[_0x50d46c('0x173f')](_0x56a24d[0x0])?_0x56a24d[0x0]:isNaN(_0x56a24d[0x0])?_0x56a24d[0x0]:parseInt(_0x56a24d[0x0],0xa),_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x1bcd')]=_0x2e3ca0()['isEmpty'](_0x56a24d[0x1])?_0x56a24d[0x1]:isNaN(_0x56a24d[0x1])?_0x56a24d[0x1]:parseInt(_0x56a24d[0x1],0xa);}break;}else _0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x35')]=0x1;_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0xcf0')]&&_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0xcf0')]['toLowerCase']()===_0x50d46c('0x17cd')&&_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x11f3')][_0x50d46c('0x93a')]()==='outbounddial'&&(_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x24fa')]=_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0xd31')]?_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0xd31')][_0x50d46c('0x1fc5')]('$')[0x0]:undefined,_0xf2dcdc['autoreply'][_0x50d46c('0xabd')]=_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x73c')]?_0x50d46c('0xac1')+_0xf2dcdc[_0x50d46c('0x2408')][_0x50d46c('0x73c')]:undefined);_0xf2dcdc[_0x50d46c('0x22a1')]=_0x36023e,_0xf2dcdc[_0x50d46c('0xf82')]=_0x4eb3bf;function _0x36023e(){const _0x42b121=_0x50d46c;_0xf2dcdc[_0x42b121('0x17f')]=[];const _0x54d542=[];_0xf2dcdc[_0x42b121('0x2408')]['type']&&_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0xcf0')][_0x42b121('0x93a')]()===_0x42b121('0x17cd')&&_0xf2dcdc['autoreply']['appType']===_0x42b121('0x4d2')&&(_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0xd31')]=_0x556e5f['cutdigits']?(_0xf2dcdc[_0x42b121('0x2408')]['prefix']||'')+_0x42b121('0x249e')+_0x556e5f[_0x42b121('0x145a')]+'}':(_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0x24fa')]||'')+'${EXTEN}',_0x556e5f[_0x42b121('0x75b')]!=='none'?_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0x158e')][_0x42b121('0x824')](_0x42b121('0x1b1'))<0x0&&(_0xf2dcdc[_0x42b121('0x2408')]['options']+=_0x42b121('0x1b1')):_0xf2dcdc['autoreply'][_0x42b121('0x158e')]=_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0x158e')][_0x42b121('0x1725')](_0x42b121('0x1b1'),''));if(_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0x11f3')]&&_0xf2dcdc[_0x42b121('0x2408')]['appType']===_0x42b121('0xbf0')){}else switch((_0xf2dcdc['autoreply'][_0x42b121('0x1d75')]||_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0x11f3')])[_0x42b121('0x93a')]()){case _0x42b121('0x877'):_0xf2dcdc['autoreply'][_0x42b121('0x1407')]=_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0x60a')]+'='+_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0x1c6b')];break;case _0x42b121('0xbf0'):break;default:_0x54d542[0x0]=_0xf2dcdc['autoreply'][_0x42b121('0x35')],_0x54d542[0x1]=_0xf2dcdc[_0x42b121('0x2408')][_0x42b121('0x1bcd')],_0xf2dcdc['autoreply']['appdata']=_0x54d542[_0x42b121('0x1630')](',');}_0x4eb3bf(_0xf2dcdc[_0x42b121('0x2408')]);}function _0x4eb3bf(_0x5bf4b1){const _0x1baa2e=_0x50d46c;_0x4dea39[_0x1baa2e('0x1715')](_0x5bf4b1);}}const _0x1867d4=_0x26a000;_0x4302e6[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x1cc0'),_0x189033('0xb87'),'api','Auth',_0x189033('0x1134')];function _0x4302e6(_0x273021,_0x6e3dd,_0x34d88f,_0x44e899,_0x38bd5f,_0x4549b3,_0x33ba0e,_0xf0555f){const _0x4c6404=_0x189033,_0x19e68e=this;_0x19e68e[_0x4c6404('0x11ed')]=_0x33ba0e[_0x4c6404('0x20b2')](),_0x19e68e['errors']=[],_0x19e68e[_0x4c6404('0xf28')]=_0x4c6404('0x3df')+(_0x44e899[_0x4c6404('0x11f3')]||_0x44e899[_0x4c6404('0x1d75')])[_0x4c6404('0x80')](),_0x19e68e['close']=angular['copy'](_0x44e899),_0x19e68e[_0x4c6404('0x1134')]=_0xf0555f,_0x19e68e[_0x4c6404('0x258d')]={};if(_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1407')])switch(_0x19e68e['close']['appType']?_0x19e68e[_0x4c6404('0x12b0')]['appType'][_0x4c6404('0x93a')]():_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1d75')][_0x4c6404('0x93a')]()){case _0x4c6404('0xbf0'):break;case _0x4c6404('0x205c'):{const _0x4c5706=_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1407')][_0x4c6404('0x1fc5')](',');_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1d46')]=_0x4c5706[0x0],_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1a1c')]=_0x4c5706[0x1],_0x19e68e[_0x4c6404('0x12b0')]['welcomemessage']=_0x4c5706[_0x4c6404('0x12c8')](0x2,_0x4c5706[_0x4c6404('0x1564')])[_0x4c6404('0x1630')](',');}break;case _0x4c6404('0xd24'):{const _0xcbb3ab=_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1407')][_0x4c6404('0x1fc5')](',');_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x2119')]=_0xcbb3ab[0x0],_0x19e68e['close'][_0x4c6404('0x38')]=_0xcbb3ab[0x1],_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x406')]=_0xcbb3ab[0x2],_0x19e68e[_0x4c6404('0x12b0')]['language']=_0xcbb3ab[0x3],_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x6d9')]=_0xcbb3ab['slice'](0x4,_0xcbb3ab[_0x4c6404('0x1564')])[_0x4c6404('0x1630')](',');}break;case _0x4c6404('0x1db1'):{const _0x3c052a=_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1407')][_0x4c6404('0x1fc5')](',');_0x19e68e['close'][_0x4c6404('0x7ae')]=_0x3c052a[0x0],_0x19e68e[_0x4c6404('0x12b0')]['secretaccesskey']=_0x3c052a[0x1],_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x5ba')]=_0x3c052a[0x2],_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x11a9')]=_0x3c052a[0x3],_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x6d9')]=_0x3c052a[_0x4c6404('0x12c8')](0x4,_0x3c052a[_0x4c6404('0x1564')])[_0x4c6404('0x1630')](',');}break;case _0x4c6404('0x2408'):{const _0x2f1a6d=_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1407')][_0x4c6404('0x1fc5')](',');_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x35')]=isNaN(_0x2f1a6d[0x0])?_0x2f1a6d[0x0]:parseInt(_0x2f1a6d[0x0],0xa),_0x19e68e[_0x4c6404('0x12b0')]['text']=_0x2f1a6d['slice'](0x1,_0x2f1a6d[_0x4c6404('0x1564')])[_0x4c6404('0x1630')](',');}break;case _0x4c6404('0x8c2'):_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1bcd')]=_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1407')];break;case _0x4c6404('0x877'):_0x19e68e['close'][_0x4c6404('0x60a')]=_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1407')]['split']('=')[0x0],_0x19e68e['close'][_0x4c6404('0x1c6b')]=_0x19e68e[_0x4c6404('0x12b0')]['appdata'][_0x4c6404('0x1fc5')]('=')[0x1];break;case _0x4c6404('0x19ae'):_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x273a')]=_0x19e68e['close'][_0x4c6404('0x1407')];break;default:{const _0x2388fa=_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x1407')][_0x4c6404('0x1fc5')](',');_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x43f')]=_0x2e3ca0()[_0x4c6404('0x173f')](_0x2388fa[0x0])?_0x2388fa[0x0]:isNaN(_0x2388fa[0x0])?_0x2388fa[0x0]:parseInt(_0x2388fa[0x0],0xa);}break;}else{}_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0xcf0')]&&_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0xcf0')][_0x4c6404('0x93a')]()===_0x4c6404('0x17cd')&&_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x11f3')][_0x4c6404('0x93a')]()===_0x4c6404('0x659')&&(_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x24fa')]=_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0xd31')]?_0x19e68e[_0x4c6404('0x12b0')]['phone'][_0x4c6404('0x1fc5')]('$')[0x0]:undefined,_0x19e68e['close'][_0x4c6404('0xabd')]=_0x19e68e[_0x4c6404('0x12b0')]['callerID']?_0x4c6404('0xac1')+_0x19e68e[_0x4c6404('0x12b0')][_0x4c6404('0x73c')]:undefined);_0x19e68e[_0x4c6404('0x22a1')]=_0x390324,_0x19e68e[_0x4c6404('0xf82')]=_0x390036;function _0x390324(){const _0x142636=_0x4c6404;_0x19e68e[_0x142636('0x17f')]=[];const _0x18ac9c=[];_0x19e68e[_0x142636('0x12b0')][_0x142636('0xcf0')]&&_0x19e68e[_0x142636('0x12b0')][_0x142636('0xcf0')][_0x142636('0x93a')]()==='outbound'&&_0x19e68e[_0x142636('0x12b0')]['appType']===_0x142636('0x4d2')&&(_0x19e68e[_0x142636('0x12b0')][_0x142636('0xd31')]=_0x38bd5f[_0x142636('0x145a')]?(_0x19e68e['close'][_0x142636('0x24fa')]||'')+'${EXTEN:'+_0x38bd5f[_0x142636('0x145a')]+'}':(_0x19e68e[_0x142636('0x12b0')][_0x142636('0x24fa')]||'')+'${EXTEN}',_0x38bd5f[_0x142636('0x75b')]!==_0x142636('0x925')?_0x19e68e[_0x142636('0x12b0')][_0x142636('0x158e')][_0x142636('0x824')](_0x142636('0x1b1'))<0x0&&(_0x19e68e[_0x142636('0x12b0')][_0x142636('0x158e')]+=_0x142636('0x1b1')):_0x19e68e[_0x142636('0x12b0')]['options']=_0x19e68e[_0x142636('0x12b0')]['options'][_0x142636('0x1725')](_0x142636('0x1b1'),''));if(_0x19e68e['close'][_0x142636('0x11f3')]&&_0x19e68e[_0x142636('0x12b0')][_0x142636('0x11f3')]===_0x142636('0xbf0')){}else switch((_0x19e68e[_0x142636('0x12b0')][_0x142636('0x1d75')]||_0x19e68e[_0x142636('0x12b0')][_0x142636('0x11f3')])[_0x142636('0x93a')]()){case _0x142636('0x877'):_0x19e68e['close']['appdata']=_0x19e68e[_0x142636('0x12b0')][_0x142636('0x60a')]+'='+_0x19e68e[_0x142636('0x12b0')][_0x142636('0x1c6b')];break;case _0x142636('0xbf0'):break;default:_0x18ac9c[0x0]=_0x19e68e[_0x142636('0x12b0')][_0x142636('0x43f')],_0x19e68e[_0x142636('0x12b0')][_0x142636('0x1407')]=_0x18ac9c[_0x142636('0x1630')](',');}_0x390036(_0x19e68e[_0x142636('0x12b0')]);}function _0x390036(_0x45d5c5){const _0x4c986c=_0x4c6404;_0x273021[_0x4c986c('0x1715')](_0x45d5c5);}}const _0x31ff71=_0x4302e6;_0x5e3a3c[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x1cc0'),_0x189033('0xb87'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x5e3a3c(_0x23fb5c,_0x427818,_0x4238d8,_0x5ad1df,_0x2fac82,_0x191bc3,_0x55ef62,_0xf37009){const _0x4cbb9b=_0x189033,_0x3076c9=this;_0x3076c9[_0x4cbb9b('0x11ed')]=_0x55ef62[_0x4cbb9b('0x20b2')](),_0x3076c9['errors']=[],_0x3076c9['title']='MAIL.EDIT_'+(_0x5ad1df[_0x4cbb9b('0x11f3')]||_0x5ad1df[_0x4cbb9b('0x1d75')])[_0x4cbb9b('0x80')](),_0x3076c9[_0x4cbb9b('0xc33')]=angular[_0x4cbb9b('0x1a86')](_0x5ad1df),_0x3076c9[_0x4cbb9b('0x1134')]=_0xf37009,_0x3076c9['hasModulePermissions']={};if(_0x3076c9['gotoif']['appdata'])switch(_0x3076c9['gotoif'][_0x4cbb9b('0x11f3')]?_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x11f3')][_0x4cbb9b('0x93a')]():_0x3076c9[_0x4cbb9b('0xc33')]['app'][_0x4cbb9b('0x93a')]()){case _0x4cbb9b('0xbf0'):break;case _0x4cbb9b('0x205c'):{const _0x233bf0=_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x1407')]['split'](',');_0x3076c9[_0x4cbb9b('0xc33')]['key']=_0x233bf0[0x0],_0x3076c9['gotoif'][_0x4cbb9b('0x1a1c')]=_0x233bf0[0x1],_0x3076c9['gotoif'][_0x4cbb9b('0x6d9')]=_0x233bf0[_0x4cbb9b('0x12c8')](0x2,_0x233bf0[_0x4cbb9b('0x1564')])['join'](',');}break;case _0x4cbb9b('0xd24'):{const _0x2bd3ee=_0x3076c9[_0x4cbb9b('0xc33')]['appdata'][_0x4cbb9b('0x1fc5')](',');_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x2119')]=_0x2bd3ee[0x0],_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x38')]=_0x2bd3ee[0x1],_0x3076c9[_0x4cbb9b('0xc33')]['privateKey']=_0x2bd3ee[0x2],_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x1a1c')]=_0x2bd3ee[0x3],_0x3076c9['gotoif']['welcomemessage']=_0x2bd3ee[_0x4cbb9b('0x12c8')](0x4,_0x2bd3ee[_0x4cbb9b('0x1564')])[_0x4cbb9b('0x1630')](',');}break;case _0x4cbb9b('0x1db1'):{const _0x3b2f9a=_0x3076c9[_0x4cbb9b('0xc33')]['appdata'][_0x4cbb9b('0x1fc5')](',');_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x7ae')]=_0x3b2f9a[0x0],_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x204a')]=_0x3b2f9a[0x1],_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x5ba')]=_0x3b2f9a[0x2],_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x11a9')]=_0x3b2f9a[0x3],_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x6d9')]=_0x3b2f9a[_0x4cbb9b('0x12c8')](0x4,_0x3b2f9a[_0x4cbb9b('0x1564')])[_0x4cbb9b('0x1630')](',');}break;case _0x4cbb9b('0x2408'):{const _0x4c6fd0=_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x1407')][_0x4cbb9b('0x1fc5')](',');_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x35')]=isNaN(_0x4c6fd0[0x0])?_0x4c6fd0[0x0]:parseInt(_0x4c6fd0[0x0],0xa),_0x3076c9['gotoif']['text']=_0x4c6fd0[_0x4cbb9b('0x12c8')](0x1,_0x4c6fd0[_0x4cbb9b('0x1564')])[_0x4cbb9b('0x1630')](',');}break;case _0x4cbb9b('0x8c2'):_0x3076c9[_0x4cbb9b('0xc33')]['text']=_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x1407')];break;case _0x4cbb9b('0x877'):_0x3076c9[_0x4cbb9b('0xc33')]['name']=_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x1407')][_0x4cbb9b('0x1fc5')]('=')[0x0],_0x3076c9[_0x4cbb9b('0xc33')]['value']=_0x3076c9['gotoif'][_0x4cbb9b('0x1407')]['split']('=')[0x1];break;case'agi':_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x273a')]=_0x3076c9['gotoif'][_0x4cbb9b('0x1407')];break;default:{const _0x12c803=_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x1407')]['split'](',');_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x168e')]=_0x2e3ca0()[_0x4cbb9b('0x173f')](_0x12c803[0x0])?_0x12c803[0x0]:isNaN(_0x12c803[0x0])?_0x12c803[0x0]:parseInt(_0x12c803[0x0],0xa),_0x3076c9[_0x4cbb9b('0xc33')]['truepriority']=_0x2e3ca0()['isEmpty'](_0x12c803[0x1])?_0x12c803[0x1]:isNaN(_0x12c803[0x1])?_0x12c803[0x1]:parseInt(_0x12c803[0x1],0xa),_0x3076c9[_0x4cbb9b('0xc33')]['falsepriority']=_0x2e3ca0()[_0x4cbb9b('0x173f')](_0x12c803[0x2])?_0x12c803[0x2]:isNaN(_0x12c803[0x2])?_0x12c803[0x2]:parseInt(_0x12c803[0x2],0xa);}break;}else{}_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0xcf0')]&&_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0xcf0')][_0x4cbb9b('0x93a')]()===_0x4cbb9b('0x17cd')&&_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0x11f3')]['toLowerCase']()==='outbounddial'&&(_0x3076c9[_0x4cbb9b('0xc33')]['prefix']=_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0xd31')]?_0x3076c9['gotoif'][_0x4cbb9b('0xd31')][_0x4cbb9b('0x1fc5')]('$')[0x0]:undefined,_0x3076c9[_0x4cbb9b('0xc33')][_0x4cbb9b('0xabd')]=_0x3076c9[_0x4cbb9b('0xc33')]['callerID']?_0x4cbb9b('0xac1')+_0x3076c9[_0x4cbb9b('0xc33')]['callerID']:undefined);_0x3076c9[_0x4cbb9b('0x22a1')]=_0x4a75ab,_0x3076c9[_0x4cbb9b('0xf82')]=_0xd5baf0;function _0x4a75ab(){const _0xa58585=_0x4cbb9b;_0x3076c9['errors']=[];const _0x31c6c8=[];_0x3076c9[_0xa58585('0xc33')][_0xa58585('0xcf0')]&&_0x3076c9[_0xa58585('0xc33')][_0xa58585('0xcf0')][_0xa58585('0x93a')]()===_0xa58585('0x17cd')&&_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x11f3')]===_0xa58585('0x4d2')&&(_0x3076c9['gotoif'][_0xa58585('0xd31')]=_0x2fac82[_0xa58585('0x145a')]?(_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x24fa')]||'')+_0xa58585('0x249e')+_0x2fac82[_0xa58585('0x145a')]+'}':(_0x3076c9[_0xa58585('0xc33')]['prefix']||'')+_0xa58585('0x20cb'),_0x2fac82[_0xa58585('0x75b')]!=='none'?_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x158e')]['indexOf'](_0xa58585('0x1b1'))<0x0&&(_0x3076c9['gotoif'][_0xa58585('0x158e')]+=_0xa58585('0x1b1')):_0x3076c9[_0xa58585('0xc33')]['options']=_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x158e')]['replace'](_0xa58585('0x1b1'),''));if(_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x11f3')]&&_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x11f3')]===_0xa58585('0xbf0')){}else switch((_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x1d75')]||_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x11f3')])[_0xa58585('0x93a')]()){case'set':_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x1407')]=_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x60a')]+'='+_0x3076c9['gotoif'][_0xa58585('0x1c6b')];break;case'custom':break;default:_0x31c6c8[0x0]=_0x3076c9[_0xa58585('0xc33')]['condition'],_0x31c6c8[0x1]=_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x27e5')],_0x31c6c8[0x2]=_0x3076c9['gotoif'][_0xa58585('0x1813')],_0x3076c9[_0xa58585('0xc33')][_0xa58585('0x1407')]=_0x31c6c8[_0xa58585('0x1630')](',');}_0xd5baf0(_0x3076c9[_0xa58585('0xc33')]);}function _0xd5baf0(_0x46b969){_0x23fb5c['hide'](_0x46b969);}}const _0x1857bd=_0x5e3a3c;_0x2fdc92[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x1cc0'),'mailAccount','api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x2fdc92(_0x4c0535,_0x105869,_0xfe727d,_0x2fd8ff,_0x202b12,_0x2e8bfa,_0x553067,_0x3ec109){const _0x41027d=_0x189033,_0x73858a=this;_0x73858a[_0x41027d('0x11ed')]=_0x553067['getCurrentUser'](),_0x73858a[_0x41027d('0x17f')]=[],_0x73858a[_0x41027d('0xf28')]=_0x41027d('0x3df')+(_0x2fd8ff[_0x41027d('0x11f3')]||_0x2fd8ff[_0x41027d('0x1d75')])[_0x41027d('0x80')](),_0x73858a['gotop']=angular[_0x41027d('0x1a86')](_0x2fd8ff),_0x73858a[_0x41027d('0x1134')]=_0x3ec109,_0x73858a[_0x41027d('0x258d')]={};if(_0x73858a['gotop']['appdata'])switch(_0x73858a['gotop']['appType']?_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x11f3')][_0x41027d('0x93a')]():_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1d75')][_0x41027d('0x93a')]()){case _0x41027d('0xbf0'):break;case _0x41027d('0x205c'):{const _0x5e14fd=_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1407')][_0x41027d('0x1fc5')](',');_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1d46')]=_0x5e14fd[0x0],_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1a1c')]=_0x5e14fd[0x1],_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x6d9')]=_0x5e14fd[_0x41027d('0x12c8')](0x2,_0x5e14fd[_0x41027d('0x1564')])[_0x41027d('0x1630')](',');}break;case'dialogflowv2':{const _0x9f7407=_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1407')][_0x41027d('0x1fc5')](',');_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x2119')]=_0x9f7407[0x0],_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x38')]=_0x9f7407[0x1],_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x406')]=_0x9f7407[0x2],_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1a1c')]=_0x9f7407[0x3],_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x6d9')]=_0x9f7407['slice'](0x4,_0x9f7407[_0x41027d('0x1564')])[_0x41027d('0x1630')](',');}break;case'amazonlex':{const _0xc86e85=_0x73858a[_0x41027d('0x1da0')]['appdata'][_0x41027d('0x1fc5')](',');_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x7ae')]=_0xc86e85[0x0],_0x73858a[_0x41027d('0x1da0')]['secretaccesskey']=_0xc86e85[0x1],_0x73858a['gotop']['lexregion']=_0xc86e85[0x2],_0x73858a['gotop']['botname']=_0xc86e85[0x3],_0x73858a['gotop'][_0x41027d('0x6d9')]=_0xc86e85['slice'](0x4,_0xc86e85['length'])[_0x41027d('0x1630')](',');}break;case _0x41027d('0x2408'):{const _0x244998=_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1407')]['split'](',');_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x35')]=isNaN(_0x244998[0x0])?_0x244998[0x0]:parseInt(_0x244998[0x0],0xa),_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1bcd')]=_0x244998[_0x41027d('0x12c8')](0x1,_0x244998['length'])[_0x41027d('0x1630')](',');}break;case _0x41027d('0x8c2'):_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1bcd')]=_0x73858a['gotop']['appdata'];break;case _0x41027d('0x877'):_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x60a')]=_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1407')][_0x41027d('0x1fc5')]('=')[0x0],_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1c6b')]=_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1407')]['split']('=')[0x1];break;case _0x41027d('0x19ae'):_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x273a')]=_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1407')];break;default:{const _0x4a7490=_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x1407')]['split'](',');_0x73858a[_0x41027d('0x1da0')]['priority']=_0x2e3ca0()[_0x41027d('0x173f')](_0x4a7490[0x0])?_0x4a7490[0x0]:isNaN(_0x4a7490[0x0])?_0x4a7490[0x0]:parseInt(_0x4a7490[0x0],0xa);}break;}else{}_0x73858a[_0x41027d('0x1da0')]['type']&&_0x73858a[_0x41027d('0x1da0')][_0x41027d('0xcf0')]['toLowerCase']()==='outbound'&&_0x73858a['gotop']['appType'][_0x41027d('0x93a')]()==='outbounddial'&&(_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x24fa')]=_0x73858a[_0x41027d('0x1da0')][_0x41027d('0xd31')]?_0x73858a[_0x41027d('0x1da0')]['phone']['split']('$')[0x0]:undefined,_0x73858a[_0x41027d('0x1da0')][_0x41027d('0xabd')]=_0x73858a['gotop'][_0x41027d('0x73c')]?_0x41027d('0xac1')+_0x73858a[_0x41027d('0x1da0')][_0x41027d('0x73c')]:undefined);_0x73858a[_0x41027d('0x22a1')]=_0x4d3640,_0x73858a[_0x41027d('0xf82')]=_0x299289;function _0x4d3640(){const _0x25e024=_0x41027d;_0x73858a[_0x25e024('0x17f')]=[];const _0x78caab=[];_0x73858a[_0x25e024('0x1da0')]['type']&&_0x73858a[_0x25e024('0x1da0')][_0x25e024('0xcf0')][_0x25e024('0x93a')]()===_0x25e024('0x17cd')&&_0x73858a[_0x25e024('0x1da0')][_0x25e024('0x11f3')]===_0x25e024('0x4d2')&&(_0x73858a['gotop'][_0x25e024('0xd31')]=_0x202b12[_0x25e024('0x145a')]?(_0x73858a[_0x25e024('0x1da0')]['prefix']||'')+'${EXTEN:'+_0x202b12[_0x25e024('0x145a')]+'}':(_0x73858a[_0x25e024('0x1da0')][_0x25e024('0x24fa')]||'')+_0x25e024('0x20cb'),_0x202b12[_0x25e024('0x75b')]!=='none'?_0x73858a['gotop'][_0x25e024('0x158e')][_0x25e024('0x824')](_0x25e024('0x1b1'))<0x0&&(_0x73858a[_0x25e024('0x1da0')]['options']+=_0x25e024('0x1b1')):_0x73858a[_0x25e024('0x1da0')][_0x25e024('0x158e')]=_0x73858a[_0x25e024('0x1da0')]['options'][_0x25e024('0x1725')](_0x25e024('0x1b1'),''));if(_0x73858a[_0x25e024('0x1da0')]['appType']&&_0x73858a[_0x25e024('0x1da0')]['appType']===_0x25e024('0xbf0')){}else switch((_0x73858a['gotop'][_0x25e024('0x1d75')]||_0x73858a[_0x25e024('0x1da0')][_0x25e024('0x11f3')])[_0x25e024('0x93a')]()){case'set':_0x73858a[_0x25e024('0x1da0')][_0x25e024('0x1407')]=_0x73858a[_0x25e024('0x1da0')][_0x25e024('0x60a')]+'='+_0x73858a['gotop'][_0x25e024('0x1c6b')];break;case _0x25e024('0xbf0'):break;default:_0x78caab[0x0]=_0x73858a[_0x25e024('0x1da0')][_0x25e024('0xe1e')],_0x73858a[_0x25e024('0x1da0')][_0x25e024('0x1407')]=_0x78caab['join'](',');}_0x299289(_0x73858a[_0x25e024('0x1da0')]);}function _0x299289(_0x554a20){const _0x273e38=_0x41027d;_0x4c0535[_0x273e38('0x1715')](_0x554a20);}}const _0x1613ae=_0x2fdc92;_0x1a872d[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x1e48'),_0x189033('0xb33'),_0x189033('0x844'),_0x189033('0x115c'),_0x189033('0xe98'),_0x189033('0x1d70'),'api','Auth',_0x189033('0x1134')];function _0x1a872d(_0x3edb84,_0x596426,_0x240fa4,_0x1849fa,_0x39e2c7,_0x3e0e74,_0x4e6a2f,_0x557942,_0x1ff48b,_0xf42c9c){const _0x15d7fd=_0x189033,_0x1e9934=this;_0x1e9934[_0x15d7fd('0x11ed')]=_0x1ff48b[_0x15d7fd('0x20b2')](),_0x1e9934[_0x15d7fd('0x17f')]=[],_0x1e9934[_0x15d7fd('0xf28')]=_0x15d7fd('0xc62'),_0x1e9934[_0x15d7fd('0x115c')]=angular[_0x15d7fd('0x1a86')](_0x39e2c7),_0x1e9934[_0x15d7fd('0xe98')]=_0x3e0e74,_0x1e9934['newInterval']=![],_0x1e9934['types']=[_0x15d7fd('0x10af'),_0x15d7fd('0xbf0'),_0x15d7fd('0x2335')],_0x1e9934[_0x15d7fd('0x1134')]=_0xf42c9c,_0x1e9934[_0x15d7fd('0x167a')]=_0x1849fa[_0x15d7fd('0xe88')](),_0x1e9934[_0x15d7fd('0x1dfd')]=_0x1849fa[_0x15d7fd('0x222e')](),_0x1e9934[_0x15d7fd('0x1e32')]=_0x1849fa[_0x15d7fd('0x1fe4')](),_0x1e9934[_0x15d7fd('0x13ce')]=_0x1849fa[_0x15d7fd('0x181b')]();if(!_0x1e9934[_0x15d7fd('0x115c')])_0x1e9934[_0x15d7fd('0x115c')]={'interval':_0x15d7fd('0x1b54')},_0x1e9934[_0x15d7fd('0xcf0')]=_0x15d7fd('0x10af'),_0x1e9934[_0x15d7fd('0xf28')]=_0x15d7fd('0x1e94'),_0x1e9934[_0x15d7fd('0x1470')]=!![];else{if(_0x1e9934[_0x15d7fd('0x115c')][_0x15d7fd('0x115c')]!==_0x15d7fd('0x1b54')){_0x1e9934[_0x15d7fd('0xcf0')]=_0x15d7fd('0xbf0');const _0x4209cb=_0x1e9934[_0x15d7fd('0x115c')][_0x15d7fd('0x115c')][_0x15d7fd('0x1fc5')](','),_0xa76a4=_0x4209cb[0x0],_0x56bba1=_0x4209cb[0x1],_0x3b1d8a=_0x4209cb[0x2],_0x10bf37=_0x4209cb[0x3];if(_0xa76a4!=='*'){const _0x4bc368=_0xa76a4[_0x15d7fd('0x1fc5')]('-')[0x0],_0x5235e6=_0xa76a4[_0x15d7fd('0x1fc5')]('-')[0x1];let _0x40273a;_0x40273a=new Date(),_0x40273a['setHours'](Number(_0x4bc368[_0x15d7fd('0x1fc5')](':')[0x0])),_0x40273a[_0x15d7fd('0x1fb7')](Number(_0x4bc368[_0x15d7fd('0x1fc5')](':')[0x1])),_0x1e9934[_0x15d7fd('0xc32')]=_0x40273a,_0x40273a=new Date(),_0x40273a[_0x15d7fd('0x2813')](Number(_0x5235e6['split'](':')[0x0])),_0x40273a[_0x15d7fd('0x1fb7')](Number(_0x5235e6[_0x15d7fd('0x1fc5')](':')[0x1])),_0x1e9934[_0x15d7fd('0xaa0')]=_0x40273a;}_0x56bba1!=='*'&&(_0x1e9934[_0x15d7fd('0x232d')]=_0x56bba1[_0x15d7fd('0x1fc5')]('-')[0x0],_0x1e9934[_0x15d7fd('0x1269')]=_0x56bba1[_0x15d7fd('0x1fc5')]('-')[0x1]),_0x3b1d8a!=='*'&&(_0x1e9934[_0x15d7fd('0xf13')]=_0x3b1d8a[_0x15d7fd('0x1fc5')]('-')[0x0],_0x1e9934[_0x15d7fd('0xfe5')]=_0x3b1d8a['split']('-')[0x1]),_0x10bf37!=='*'&&(_0x1e9934[_0x15d7fd('0x1690')]=_0x10bf37[_0x15d7fd('0x1fc5')]('-')[0x0],_0x1e9934[_0x15d7fd('0x1f12')]=_0x10bf37[_0x15d7fd('0x1fc5')]('-')[0x1]);}else _0x1e9934[_0x15d7fd('0xcf0')]='always';}_0x3edb84['params']['id']&&!_0x1e9934[_0x15d7fd('0x115c')][_0x15d7fd('0x121e')]&&(_0x1e9934[_0x15d7fd('0x115c')][_0x15d7fd('0x5ae')]=_0x3edb84[_0x15d7fd('0x7f2')]['id']);_0x1e9934[_0x15d7fd('0x115c')][_0x15d7fd('0x5ae')]&&_0x1e9934[_0x15d7fd('0x115c')]['application']&&(_0x1e9934[_0x15d7fd('0xcf0')]=_0x15d7fd('0x2335'));_0x1e9934[_0x15d7fd('0x1a4d')]=_0x37781e,_0x1e9934[_0x15d7fd('0x1807')]=_0x5ad7c5,_0x1e9934['closeDialog']=_0xcd6f52;_0x1e9934[_0x15d7fd('0x115c')]['application']&&(_0x1ff48b[_0x15d7fd('0xca1')](_0x15d7fd('0x20c2'))?_0x557942[_0x15d7fd('0x115c')][_0x15d7fd('0x1e6e')]({'fields':_0x15d7fd('0x1e24'),'IntervalId':_0x15d7fd('0x13c'),'nolimit':!![]})['$promise']['then'](function(_0x2c6e3a){const _0x1d152e=_0x15d7fd;_0x1e9934[_0x1d152e('0xe98')]=_0x2c6e3a['rows']||[];})['catch'](function(_0x5097ec){const _0x18eb26=_0x15d7fd;_0x4e6a2f[_0x18eb26('0x52a')]({'title':_0x5097ec[_0x18eb26('0x13ee')]?'API:'+_0x5097ec[_0x18eb26('0x13ee')]+'\x20-\x20'+_0x5097ec[_0x18eb26('0x24a9')]:_0x18eb26('0x1e65'),'msg':_0x5097ec[_0x18eb26('0x5a5')]?JSON['stringify'](_0x5097ec[_0x18eb26('0x5a5')]):_0x5097ec[_0x18eb26('0x1ff0')]()});}):_0x557942[_0x15d7fd('0x115c')]['get']({'fields':'id,name,interval,IntervalId','IntervalId':'null','nolimit':!![]})[_0x15d7fd('0xe53')][_0x15d7fd('0x683')](function(_0x220769){const _0x1be241=_0x15d7fd;_0x1e9934['intervals']=_0x220769[_0x1be241('0xf5d')]||[];})[_0x15d7fd('0x683')](function(){const _0x3e7aa2=_0x15d7fd;return _0x557942[_0x3e7aa2('0x22df')][_0x3e7aa2('0x1e6e')]({'userProfileId':_0x1e9934[_0x3e7aa2('0x11ed')][_0x3e7aa2('0x2f')],'sectionId':0x3ec})[_0x3e7aa2('0xe53')];})['then'](function(_0x237220){const _0x52815b=_0x15d7fd,_0x591ce8=_0x237220&&_0x237220[_0x52815b('0xf5d')]?_0x237220[_0x52815b('0xf5d')][0x0]:null;if(!_0x591ce8)_0x1e9934[_0x52815b('0xe98')]=[];else{if(!_0x591ce8[_0x52815b('0x170')])return _0x557942[_0x52815b('0xcf7')][_0x52815b('0x1e6e')]({'sectionId':_0x591ce8['id']})[_0x52815b('0xe53')]['then'](function(_0x23aa7a){const _0x47a75f=_0x52815b,_0x264292=_0x23aa7a&&_0x23aa7a[_0x47a75f('0xf5d')]?_0x23aa7a[_0x47a75f('0xf5d')]:[],_0x72542c=[];let _0x1fd611=null;_0x1e9934[_0x47a75f('0x115c')]&&(_0x1fd611=_0x2e3ca0()[_0x47a75f('0x1c07')](_0x1e9934[_0x47a75f('0xe98')],{'name':_0x1e9934[_0x47a75f('0x115c')][_0x47a75f('0x5ae')]})),_0x1fd611&&!_0x2e3ca0()['some'](_0x264292,[_0x47a75f('0x832'),_0x1fd611['id']])&&_0x1e9934[_0x47a75f('0xe98')][_0x47a75f('0x1299')](function(_0x281f5d){const _0x14e64c=_0x47a75f;_0x281f5d['id']===_0x1fd611['id']&&(_0x281f5d[_0x14e64c('0x319')]=![],_0x72542c['push'](_0x281f5d));}),_0x1e9934['intervals']=_0x72542c;});}})[_0x15d7fd('0x130a')](function(_0x25bd81){const _0xdaccfa=_0x15d7fd;_0x4e6a2f[_0xdaccfa('0x52a')]({'title':_0x25bd81[_0xdaccfa('0x13ee')]?_0xdaccfa('0x2168')+_0x25bd81['status']+_0xdaccfa('0xbf6')+_0x25bd81['statusText']:_0xdaccfa('0x1e65'),'msg':_0x25bd81[_0xdaccfa('0x5a5')]?JSON[_0xdaccfa('0x258a')](_0x25bd81[_0xdaccfa('0x5a5')]):_0x25bd81[_0xdaccfa('0x1ff0')]()});}));function _0x3d57a5(){const _0x139c6f=_0x15d7fd;switch(_0x1e9934[_0x139c6f('0xcf0')]){case _0x139c6f('0x10af'):case _0x139c6f('0x2335'):return _0x139c6f('0x1b54');case _0x139c6f('0xbf0'):{const _0x4deabe=[];if(_0x1e9934[_0x139c6f('0xc32')]!=='*'&&_0x1e9934['timeRangeFrom']&&_0x1e9934['timeRangeTo']){const _0x3acaba=(_0x1e9934[_0x139c6f('0xc32')][_0x139c6f('0x2575')]()<0xa?'0':'')+_0x1e9934[_0x139c6f('0xc32')][_0x139c6f('0x2575')]()+':'+((_0x1e9934['timeRangeFrom'][_0x139c6f('0x1b5b')]()<0xa?'0':'')+_0x1e9934[_0x139c6f('0xc32')][_0x139c6f('0x1b5b')]()),_0x58b205=(_0x1e9934[_0x139c6f('0xaa0')][_0x139c6f('0x2575')]()<0xa?'0':'')+_0x1e9934[_0x139c6f('0xaa0')][_0x139c6f('0x2575')]()+':'+((_0x1e9934[_0x139c6f('0xaa0')]['getMinutes']()<0xa?'0':'')+_0x1e9934[_0x139c6f('0xaa0')][_0x139c6f('0x1b5b')]());_0x4deabe[_0x139c6f('0x1fd0')](_0x3acaba+'-'+_0x58b205);}else _0x4deabe['push']('*');return _0x1e9934[_0x139c6f('0x232d')]?_0x1e9934['dayOfWeekTo']?_0x4deabe[_0x139c6f('0x1fd0')](_0x1e9934[_0x139c6f('0x232d')]+'-'+_0x1e9934[_0x139c6f('0x1269')]):_0x4deabe[_0x139c6f('0x1fd0')](_0x1e9934[_0x139c6f('0x232d')]):_0x4deabe['push']('*'),_0x1e9934['monthDayFrom']?_0x1e9934['monthDayTo']?_0x4deabe[_0x139c6f('0x1fd0')](_0x1e9934['monthDayFrom']+'-'+_0x1e9934[_0x139c6f('0xfe5')]):_0x4deabe[_0x139c6f('0x1fd0')](_0x1e9934[_0x139c6f('0xf13')]):_0x4deabe['push']('*'),_0x1e9934[_0x139c6f('0x1690')]?_0x1e9934['monthTo']?_0x4deabe[_0x139c6f('0x1fd0')](_0x1e9934[_0x139c6f('0x1690')]+'-'+_0x1e9934[_0x139c6f('0x1f12')]):_0x4deabe[_0x139c6f('0x1fd0')](_0x1e9934[_0x139c6f('0x1690')]):_0x4deabe[_0x139c6f('0x1fd0')]('*'),_0x4deabe[_0x139c6f('0x1630')]();}}}function _0x37781e(){const _0x1cf793=_0x15d7fd;_0x1e9934[_0x1cf793('0x17f')]=[],_0x1e9934[_0x1cf793('0x115c')]['interval']=_0x3d57a5(),_0x557942[_0x1cf793('0x115c')][_0x1cf793('0xb0a')](_0x1e9934[_0x1cf793('0x115c')])[_0x1cf793('0xe53')][_0x1cf793('0x683')](function(_0x43bc1a){const _0x43ed84=_0x1cf793;_0x1e9934['intervals'][_0x43ed84('0x1fd0')](_0x43bc1a),_0x4e6a2f[_0x43ed84('0x53')]({'title':'Interval\x20properly\x20created','msg':_0x1e9934[_0x43ed84('0x115c')][_0x43ed84('0x60a')]?_0x1e9934[_0x43ed84('0x115c')][_0x43ed84('0x60a')]+'\x20has\x20been\x20created!':''}),_0xcd6f52();})[_0x1cf793('0x130a')](function(_0x2a59d0){const _0x4a44cd=_0x1cf793;console[_0x4a44cd('0x52a')](_0x2a59d0),_0x1e9934[_0x4a44cd('0x17f')]=_0x2a59d0[_0x4a44cd('0x5a5')][_0x4a44cd('0x17f')]||[{'message':_0x2a59d0[_0x4a44cd('0x1ff0')](),'type':_0x4a44cd('0x1d24')}];});}function _0x5ad7c5(){const _0x4b99f2=_0x15d7fd;_0x1e9934[_0x4b99f2('0x17f')]=[],_0x1e9934[_0x4b99f2('0x115c')][_0x4b99f2('0x115c')]=_0x3d57a5(),_0x1e9934['interval'][_0x4b99f2('0x121e')]?(_0x1e9934[_0x4b99f2('0xcf0')]!==_0x4b99f2('0x2335')&&(_0x1e9934[_0x4b99f2('0x115c')][_0x4b99f2('0x5ae')]=null),_0xcd6f52(_0x1e9934[_0x4b99f2('0x115c')])):_0x557942['interval'][_0x4b99f2('0x2480')]({'id':_0x1e9934['interval']['id']},_0x1e9934[_0x4b99f2('0x115c')])[_0x4b99f2('0xe53')]['then'](function(_0x272098){const _0x537eeb=_0x4b99f2,_0x28ee7d=_0x2e3ca0()[_0x537eeb('0x1c07')](_0x1e9934[_0x537eeb('0xe98')],{'id':_0x272098['id']});_0x28ee7d&&_0x2e3ca0()[_0x537eeb('0xf22')](_0x28ee7d,_0x272098),_0x4e6a2f[_0x537eeb('0x53')]({'title':'Interval\x20properly\x20saved!','msg':_0x537eeb('0x224')}),_0xcd6f52();})[_0x4b99f2('0x130a')](function(_0x3def06){const _0xe36dec=_0x4b99f2;console[_0xe36dec('0x52a')](_0x3def06),_0x1e9934['errors']=_0x3def06[_0xe36dec('0x5a5')]['errors']||[{'message':_0x3def06[_0xe36dec('0x1ff0')](),'type':_0xe36dec('0x605')}];});}function _0xcd6f52(_0x5d5d4e){const _0xa6399b=_0x15d7fd;_0x596426[_0xa6399b('0x1715')](_0x5d5d4e);}}const _0x5b39e1=_0x1a872d;_0x36bbe4[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x1cc0'),_0x189033('0xb87'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x36bbe4(_0x5f0dbc,_0x52202c,_0x1ad741,_0x16d9d7,_0x4a510e,_0x16e1a0,_0x21af3e,_0x501709){const _0x3dcdf2=_0x189033,_0x1d6c97=this;_0x1d6c97[_0x3dcdf2('0x11ed')]=_0x21af3e[_0x3dcdf2('0x20b2')](),_0x1d6c97[_0x3dcdf2('0x17f')]=[],_0x1d6c97[_0x3dcdf2('0xf28')]=_0x3dcdf2('0x3df')+(_0x16d9d7[_0x3dcdf2('0x11f3')]||_0x16d9d7[_0x3dcdf2('0x1d75')])[_0x3dcdf2('0x80')](),_0x1d6c97['noop']=angular['copy'](_0x16d9d7),_0x1d6c97[_0x3dcdf2('0x1134')]=_0x501709,_0x1d6c97[_0x3dcdf2('0x258d')]={};if(_0x1d6c97[_0x3dcdf2('0x1126')]['appdata'])switch(_0x1d6c97['noop'][_0x3dcdf2('0x11f3')]?_0x1d6c97['noop'][_0x3dcdf2('0x11f3')][_0x3dcdf2('0x93a')]():_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x1d75')][_0x3dcdf2('0x93a')]()){case _0x3dcdf2('0xbf0'):break;case _0x3dcdf2('0x205c'):{const _0x276c6c=_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x1407')][_0x3dcdf2('0x1fc5')](',');_0x1d6c97[_0x3dcdf2('0x1126')]['key']=_0x276c6c[0x0],_0x1d6c97['noop'][_0x3dcdf2('0x1a1c')]=_0x276c6c[0x1],_0x1d6c97['noop'][_0x3dcdf2('0x6d9')]=_0x276c6c[_0x3dcdf2('0x12c8')](0x2,_0x276c6c[_0x3dcdf2('0x1564')])['join'](',');}break;case _0x3dcdf2('0xd24'):{const _0x59f171=_0x1d6c97[_0x3dcdf2('0x1126')]['appdata'][_0x3dcdf2('0x1fc5')](',');_0x1d6c97[_0x3dcdf2('0x1126')]['projectId']=_0x59f171[0x0],_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x38')]=_0x59f171[0x1],_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x406')]=_0x59f171[0x2],_0x1d6c97[_0x3dcdf2('0x1126')]['language']=_0x59f171[0x3],_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x6d9')]=_0x59f171[_0x3dcdf2('0x12c8')](0x4,_0x59f171[_0x3dcdf2('0x1564')])[_0x3dcdf2('0x1630')](',');}break;case _0x3dcdf2('0x1db1'):{const _0x12e234=_0x1d6c97['noop'][_0x3dcdf2('0x1407')][_0x3dcdf2('0x1fc5')](',');_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x7ae')]=_0x12e234[0x0],_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x204a')]=_0x12e234[0x1],_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x5ba')]=_0x12e234[0x2],_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x11a9')]=_0x12e234[0x3],_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x6d9')]=_0x12e234[_0x3dcdf2('0x12c8')](0x4,_0x12e234['length'])[_0x3dcdf2('0x1630')](',');}break;case _0x3dcdf2('0x2408'):{const _0x10ee9b=_0x1d6c97['noop'][_0x3dcdf2('0x1407')][_0x3dcdf2('0x1fc5')](',');_0x1d6c97[_0x3dcdf2('0x1126')]['times']=isNaN(_0x10ee9b[0x0])?_0x10ee9b[0x0]:parseInt(_0x10ee9b[0x0],0xa),_0x1d6c97['noop'][_0x3dcdf2('0x1bcd')]=_0x10ee9b[_0x3dcdf2('0x12c8')](0x1,_0x10ee9b[_0x3dcdf2('0x1564')])[_0x3dcdf2('0x1630')](',');}break;case _0x3dcdf2('0x8c2'):_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x1bcd')]=_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x1407')];break;case _0x3dcdf2('0x877'):_0x1d6c97[_0x3dcdf2('0x1126')]['name']=_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x1407')][_0x3dcdf2('0x1fc5')]('=')[0x0],_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x1c6b')]=_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x1407')][_0x3dcdf2('0x1fc5')]('=')[0x1];break;case _0x3dcdf2('0x19ae'):_0x1d6c97[_0x3dcdf2('0x1126')]['project']=_0x1d6c97['noop'][_0x3dcdf2('0x1407')];break;default:{const _0x4e0af7=_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x1407')][_0x3dcdf2('0x1fc5')](',');_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x1c6b')]=_0x2e3ca0()[_0x3dcdf2('0x173f')](_0x4e0af7[0x0])?_0x4e0af7[0x0]:isNaN(_0x4e0af7[0x0])?_0x4e0af7[0x0]:parseInt(_0x4e0af7[0x0],0xa);}break;}else{}_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0xcf0')]&&_0x1d6c97['noop'][_0x3dcdf2('0xcf0')][_0x3dcdf2('0x93a')]()===_0x3dcdf2('0x17cd')&&_0x1d6c97[_0x3dcdf2('0x1126')]['appType'][_0x3dcdf2('0x93a')]()===_0x3dcdf2('0x659')&&(_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x24fa')]=_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0xd31')]?_0x1d6c97[_0x3dcdf2('0x1126')]['phone'][_0x3dcdf2('0x1fc5')]('$')[0x0]:undefined,_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0xabd')]=_0x1d6c97[_0x3dcdf2('0x1126')][_0x3dcdf2('0x73c')]?_0x3dcdf2('0xac1')+_0x1d6c97[_0x3dcdf2('0x1126')]['callerID']:undefined);_0x1d6c97[_0x3dcdf2('0x22a1')]=_0x3fb194,_0x1d6c97[_0x3dcdf2('0xf82')]=_0x138ca7;function _0x3fb194(){const _0x95b47a=_0x3dcdf2;_0x1d6c97[_0x95b47a('0x17f')]=[];const _0x578b56=[];_0x1d6c97['noop']['type']&&_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0xcf0')][_0x95b47a('0x93a')]()===_0x95b47a('0x17cd')&&_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x11f3')]===_0x95b47a('0x4d2')&&(_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0xd31')]=_0x4a510e[_0x95b47a('0x145a')]?(_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x24fa')]||'')+'${EXTEN:'+_0x4a510e['cutdigits']+'}':(_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x24fa')]||'')+'${EXTEN}',_0x4a510e[_0x95b47a('0x75b')]!==_0x95b47a('0x925')?_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x158e')]['indexOf'](_0x95b47a('0x1b1'))<0x0&&(_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x158e')]+=_0x95b47a('0x1b1')):_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x158e')]=_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x158e')][_0x95b47a('0x1725')]('U(xcally-mixmonitor-context)',''));if(_0x1d6c97[_0x95b47a('0x1126')]['appType']&&_0x1d6c97['noop'][_0x95b47a('0x11f3')]===_0x95b47a('0xbf0')){}else switch((_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x1d75')]||_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x11f3')])['toLowerCase']()){case _0x95b47a('0x877'):_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x1407')]=_0x1d6c97['noop'][_0x95b47a('0x60a')]+'='+_0x1d6c97['noop'][_0x95b47a('0x1c6b')];break;case'custom':break;default:_0x578b56[0x0]=_0x1d6c97['noop']['value'],_0x1d6c97[_0x95b47a('0x1126')][_0x95b47a('0x1407')]=_0x578b56[_0x95b47a('0x1630')](',');}_0x138ca7(_0x1d6c97[_0x95b47a('0x1126')]);}function _0x138ca7(_0x23619a){const _0x1df975=_0x3dcdf2;_0x5f0dbc[_0x1df975('0x1715')](_0x23619a);}}const _0x33eb7f=_0x36bbe4;_0x2cebd1[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'mailAccountApp',_0x189033('0xb87'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x2cebd1(_0x45afa4,_0x538638,_0x6d2475,_0xf48f56,_0x284806,_0x3a5460,_0x566d70,_0x542d80){const _0x4c8bf3=_0x189033,_0xacdce9=this;_0xacdce9[_0x4c8bf3('0x11ed')]=_0x566d70[_0x4c8bf3('0x20b2')](),_0xacdce9[_0x4c8bf3('0x17f')]=[],_0xacdce9[_0x4c8bf3('0xf28')]='MAIL.EDIT_'+(_0xf48f56['appType']||_0xf48f56[_0x4c8bf3('0x1d75')])[_0x4c8bf3('0x80')](),_0xacdce9[_0x4c8bf3('0x660')]=angular[_0x4c8bf3('0x1a86')](_0xf48f56),_0xacdce9['crudPermissions']=_0x542d80,_0xacdce9[_0x4c8bf3('0x258d')]={};if(_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1407')])switch(_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x11f3')]?_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x11f3')][_0x4c8bf3('0x93a')]():_0xacdce9[_0x4c8bf3('0x660')]['app'][_0x4c8bf3('0x93a')]()){case _0x4c8bf3('0xbf0'):break;case'dialogflow':{const _0x3ed1a7=_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1407')][_0x4c8bf3('0x1fc5')](',');_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1d46')]=_0x3ed1a7[0x0],_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1a1c')]=_0x3ed1a7[0x1],_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x6d9')]=_0x3ed1a7[_0x4c8bf3('0x12c8')](0x2,_0x3ed1a7['length'])['join'](',');}break;case _0x4c8bf3('0xd24'):{const _0x5bd407=_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1407')][_0x4c8bf3('0x1fc5')](',');_0xacdce9[_0x4c8bf3('0x660')]['projectId']=_0x5bd407[0x0],_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x38')]=_0x5bd407[0x1],_0xacdce9['queue'][_0x4c8bf3('0x406')]=_0x5bd407[0x2],_0xacdce9[_0x4c8bf3('0x660')]['language']=_0x5bd407[0x3],_0xacdce9['queue'][_0x4c8bf3('0x6d9')]=_0x5bd407['slice'](0x4,_0x5bd407['length'])[_0x4c8bf3('0x1630')](',');}break;case _0x4c8bf3('0x1db1'):{const _0x20879e=_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1407')][_0x4c8bf3('0x1fc5')](',');_0xacdce9[_0x4c8bf3('0x660')]['accesskeyid']=_0x20879e[0x0],_0xacdce9['queue']['secretaccesskey']=_0x20879e[0x1],_0xacdce9['queue']['lexregion']=_0x20879e[0x2],_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x11a9')]=_0x20879e[0x3],_0xacdce9[_0x4c8bf3('0x660')]['welcomemessage']=_0x20879e['slice'](0x4,_0x20879e[_0x4c8bf3('0x1564')])['join'](',');}break;case _0x4c8bf3('0x2408'):{const _0x3d6055=_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1407')][_0x4c8bf3('0x1fc5')](',');_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x35')]=isNaN(_0x3d6055[0x0])?_0x3d6055[0x0]:parseInt(_0x3d6055[0x0],0xa),_0xacdce9[_0x4c8bf3('0x660')]['text']=_0x3d6055[_0x4c8bf3('0x12c8')](0x1,_0x3d6055[_0x4c8bf3('0x1564')])[_0x4c8bf3('0x1630')](',');}break;case _0x4c8bf3('0x8c2'):_0xacdce9['queue'][_0x4c8bf3('0x1bcd')]=_0xacdce9[_0x4c8bf3('0x660')]['appdata'];break;case _0x4c8bf3('0x877'):_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x60a')]=_0xacdce9['queue'][_0x4c8bf3('0x1407')][_0x4c8bf3('0x1fc5')]('=')[0x0],_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1c6b')]=_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1407')][_0x4c8bf3('0x1fc5')]('=')[0x1];break;case _0x4c8bf3('0x19ae'):_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x273a')]=_0xacdce9['queue'][_0x4c8bf3('0x1407')];break;default:{const _0x15134c=_0xacdce9[_0x4c8bf3('0x660')]['appdata']['split'](',');_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x660')]=_0x2e3ca0()[_0x4c8bf3('0x173f')](_0x15134c[0x0])?_0x15134c[0x0]:isNaN(_0x15134c[0x0])?_0x15134c[0x0]:parseInt(_0x15134c[0x0],0xa),_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1668')]=_0x2e3ca0()['isEmpty'](_0x15134c[0x1])?_0x15134c[0x1]:isNaN(_0x15134c[0x1])?_0x15134c[0x1]:parseInt(_0x15134c[0x1],0xa);}break;}else _0xacdce9['queue'][_0x4c8bf3('0x660')]=0x12c,_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x1668')]=0x12c;_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0xcf0')]&&_0xacdce9['queue'][_0x4c8bf3('0xcf0')][_0x4c8bf3('0x93a')]()===_0x4c8bf3('0x17cd')&&_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x11f3')]['toLowerCase']()===_0x4c8bf3('0x659')&&(_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x24fa')]=_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0xd31')]?_0xacdce9['queue'][_0x4c8bf3('0xd31')][_0x4c8bf3('0x1fc5')]('$')[0x0]:undefined,_0xacdce9['queue']['callerId']=_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x73c')]?_0x4c8bf3('0xac1')+_0xacdce9[_0x4c8bf3('0x660')][_0x4c8bf3('0x73c')]:undefined);_0xacdce9[_0x4c8bf3('0x22a1')]=_0x42f67c,_0xacdce9[_0x4c8bf3('0xf82')]=_0x5ab950,_0x566d70['hasRole'](_0x4c8bf3('0x20c2'))?_0x3a5460[_0x4c8bf3('0x2160')][_0x4c8bf3('0x1e6e')]({'fields':_0x4c8bf3('0x2035'),'sort':_0x4c8bf3('0x60a'),'nolimit':'true'})[_0x4c8bf3('0xe53')][_0x4c8bf3('0x683')](function(_0x467093){const _0x169d97=_0x4c8bf3;_0xacdce9[_0x169d97('0x2da')]=_0x467093[_0x169d97('0xf5d')]||[];})[_0x4c8bf3('0x130a')](function(_0x44134b){const _0x1395da=_0x4c8bf3;_0x6d2475['error']({'title':_0x44134b[_0x1395da('0x13ee')]?_0x1395da('0x2168')+_0x44134b[_0x1395da('0x13ee')]+_0x1395da('0xbf6')+_0x44134b['statusText']:'SYSTEM:GET_QUEUES','msg':_0x44134b[_0x1395da('0x5a5')]?JSON[_0x1395da('0x258a')](_0x44134b[_0x1395da('0x5a5')]):_0x44134b['toString']()});}):_0x3a5460[_0x4c8bf3('0x2160')][_0x4c8bf3('0x1e6e')]({'fields':_0x4c8bf3('0x2035'),'sort':_0x4c8bf3('0x60a'),'nolimit':'true'})[_0x4c8bf3('0xe53')][_0x4c8bf3('0x683')](function(_0x3f780f){const _0xfb2077=_0x4c8bf3;_0xacdce9[_0xfb2077('0x2da')]=_0x3f780f[_0xfb2077('0xf5d')]||[];})['then'](function(){const _0xd1a1f0=_0x4c8bf3;return _0x3a5460[_0xd1a1f0('0x22df')][_0xd1a1f0('0x1e6e')]({'userProfileId':_0xacdce9[_0xd1a1f0('0x11ed')][_0xd1a1f0('0x2f')],'sectionId':0x259})[_0xd1a1f0('0xe53')];})['then'](function(_0x565faf){const _0x29900f=_0x4c8bf3,_0x3f85e6=_0x565faf&&_0x565faf['rows']?_0x565faf[_0x29900f('0xf5d')][0x0]:null;if(!_0x3f85e6){const _0x4c1de3=[];let _0x3033ed=null;_0xacdce9[_0x29900f('0x660')]&&(_0x3033ed=_0x2e3ca0()[_0x29900f('0x1c07')](_0xacdce9[_0x29900f('0x2da')],{'name':_0xacdce9[_0x29900f('0x660')]['queue']}));for(let _0x5f9eac=0x0;_0x5f9eac<_0xacdce9[_0x29900f('0x2da')]['length'];_0x5f9eac++){_0x3033ed&&_0xacdce9['queues'][_0x5f9eac]['id']===_0x3033ed['id']&&(_0xacdce9[_0x29900f('0x2da')][_0x5f9eac]['canSelect']=![],_0x4c1de3['push'](_0xacdce9[_0x29900f('0x2da')][_0x5f9eac]));}_0xacdce9[_0x29900f('0x2da')]=_0x4c1de3;}else{if(!_0x3f85e6[_0x29900f('0x170')])return _0x3a5460[_0x29900f('0xcf7')]['get']({'sectionId':_0x3f85e6['id']})[_0x29900f('0xe53')][_0x29900f('0x683')](function(_0x31a622){const _0x11fe74=_0x29900f,_0x3d4f6e=_0x2e3ca0()[_0x11fe74('0x386')](_0x31a622[_0x11fe74('0xf5d')],function(_0x5e3613){const _0x4464a5=_0x11fe74;return _0x2e3ca0()[_0x4464a5('0x1c07')](_0xacdce9[_0x4464a5('0x2da')],{'id':_0x5e3613[_0x4464a5('0x832')]});});let _0x5765e2=null;_0xacdce9[_0x11fe74('0x660')]&&(_0x5765e2=_0x2e3ca0()['find'](_0xacdce9['queues'],{'name':_0xacdce9['queue']['queue']}));if(_0x5765e2&&!_0x2e3ca0()['some'](_0x3d4f6e,['id',_0x5765e2['id']])){const _0x15f42f=_0x2e3ca0()[_0x11fe74('0x1c07')](_0xacdce9['queues'],{'id':_0x5765e2['id']});_0x15f42f[_0x11fe74('0x319')]=![],_0x3d4f6e['push'](_0x15f42f);}_0xacdce9[_0x11fe74('0x2da')]=_0x3d4f6e;});}})[_0x4c8bf3('0x130a')](function(_0xc73e89){const _0x7cb63d=_0x4c8bf3;_0x6d2475[_0x7cb63d('0x52a')]({'title':_0xc73e89[_0x7cb63d('0x13ee')]?_0x7cb63d('0x2168')+_0xc73e89[_0x7cb63d('0x13ee')]+_0x7cb63d('0xbf6')+_0xc73e89['statusText']:_0x7cb63d('0x934'),'msg':_0xc73e89[_0x7cb63d('0x5a5')]?JSON[_0x7cb63d('0x258a')](_0xc73e89[_0x7cb63d('0x5a5')]):_0xc73e89[_0x7cb63d('0x1ff0')]()});});function _0x42f67c(){const _0x154176=_0x4c8bf3;_0xacdce9['errors']=[];const _0x565cdf=[];_0xacdce9[_0x154176('0x660')]['type']&&_0xacdce9[_0x154176('0x660')][_0x154176('0xcf0')][_0x154176('0x93a')]()==='outbound'&&_0xacdce9[_0x154176('0x660')][_0x154176('0x11f3')]===_0x154176('0x4d2')&&(_0xacdce9[_0x154176('0x660')]['phone']=_0x284806[_0x154176('0x145a')]?(_0xacdce9[_0x154176('0x660')]['prefix']||'')+_0x154176('0x249e')+_0x284806['cutdigits']+'}':(_0xacdce9['queue'][_0x154176('0x24fa')]||'')+_0x154176('0x20cb'),_0x284806['recordingFormat']!==_0x154176('0x925')?_0xacdce9[_0x154176('0x660')][_0x154176('0x158e')][_0x154176('0x824')](_0x154176('0x1b1'))<0x0&&(_0xacdce9[_0x154176('0x660')]['options']+=_0x154176('0x1b1')):_0xacdce9[_0x154176('0x660')][_0x154176('0x158e')]=_0xacdce9[_0x154176('0x660')][_0x154176('0x158e')][_0x154176('0x1725')]('U(xcally-mixmonitor-context)',''));const _0x2ba142=_0x2e3ca0()[_0x154176('0x1c07')](_0xacdce9[_0x154176('0x2da')],{'name':_0xacdce9['queue'][_0x154176('0x660')]});_0x2ba142&&(_0xacdce9[_0x154176('0x660')][_0x2e3ca0()[_0x154176('0x21ab')](_0x154176('0x129f'))+_0x154176('0xd4')]=_0x2ba142['id']);if(_0xacdce9['queue'][_0x154176('0x11f3')]&&_0xacdce9[_0x154176('0x660')][_0x154176('0x11f3')]==='custom'){}else switch((_0xacdce9[_0x154176('0x660')][_0x154176('0x1d75')]||_0xacdce9[_0x154176('0x660')][_0x154176('0x11f3')])[_0x154176('0x93a')]()){case _0x154176('0x877'):_0xacdce9[_0x154176('0x660')][_0x154176('0x1407')]=_0xacdce9[_0x154176('0x660')][_0x154176('0x60a')]+'='+_0xacdce9[_0x154176('0x660')][_0x154176('0x1c6b')];break;case _0x154176('0xbf0'):break;default:_0x565cdf[0x0]=_0xacdce9['queue'][_0x154176('0x660')],_0x565cdf[0x1]=_0xacdce9[_0x154176('0x660')]['timeout'],_0xacdce9['queue'][_0x154176('0x1407')]=_0x565cdf[_0x154176('0x1630')](',');}_0x5ab950(_0xacdce9[_0x154176('0x660')]);}function _0x5ab950(_0x19ddba){const _0x130696=_0x4c8bf3;_0x45afa4[_0x130696('0x1715')](_0x19ddba);}}const _0x1efaa7=_0x2cebd1;_0x5a603c[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x1cc0'),_0x189033('0xb87'),_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0x5a603c(_0xba5acf,_0x45990f,_0x344899,_0x559183,_0x27ff18,_0x365dcf,_0x480efd,_0x11b299){const _0x27fe89=_0x189033,_0x4eee78=this;_0x4eee78['currentUser']=_0x480efd['getCurrentUser'](),_0x4eee78[_0x27fe89('0x17f')]=[],_0x4eee78['title']=_0x27fe89('0x3df')+(_0x559183[_0x27fe89('0x11f3')]||_0x559183[_0x27fe89('0x1d75')])[_0x27fe89('0x80')](),_0x4eee78[_0x27fe89('0x24f2')]=angular[_0x27fe89('0x1a86')](_0x559183),_0x4eee78[_0x27fe89('0x1134')]=_0x11b299,_0x4eee78[_0x27fe89('0x258d')]={};if(_0x4eee78[_0x27fe89('0x24f2')]['appdata'])switch(_0x4eee78['system']['appType']?_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x11f3')][_0x27fe89('0x93a')]():_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1d75')][_0x27fe89('0x93a')]()){case _0x27fe89('0xbf0'):break;case _0x27fe89('0x205c'):{const _0x2ad40d=_0x4eee78[_0x27fe89('0x24f2')]['appdata']['split'](',');_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1d46')]=_0x2ad40d[0x0],_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1a1c')]=_0x2ad40d[0x1],_0x4eee78[_0x27fe89('0x24f2')]['welcomemessage']=_0x2ad40d[_0x27fe89('0x12c8')](0x2,_0x2ad40d[_0x27fe89('0x1564')])['join'](',');}break;case _0x27fe89('0xd24'):{const _0x57ea5b=_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1407')][_0x27fe89('0x1fc5')](',');_0x4eee78['system'][_0x27fe89('0x2119')]=_0x57ea5b[0x0],_0x4eee78[_0x27fe89('0x24f2')]['clientEmail']=_0x57ea5b[0x1],_0x4eee78[_0x27fe89('0x24f2')]['privateKey']=_0x57ea5b[0x2],_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1a1c')]=_0x57ea5b[0x3],_0x4eee78[_0x27fe89('0x24f2')]['welcomemessage']=_0x57ea5b[_0x27fe89('0x12c8')](0x4,_0x57ea5b[_0x27fe89('0x1564')])[_0x27fe89('0x1630')](',');}break;case'amazonlex':{const _0x800091=_0x4eee78['system'][_0x27fe89('0x1407')]['split'](',');_0x4eee78['system'][_0x27fe89('0x7ae')]=_0x800091[0x0],_0x4eee78['system'][_0x27fe89('0x204a')]=_0x800091[0x1],_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x5ba')]=_0x800091[0x2],_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x11a9')]=_0x800091[0x3],_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x6d9')]=_0x800091[_0x27fe89('0x12c8')](0x4,_0x800091['length'])[_0x27fe89('0x1630')](',');}break;case _0x27fe89('0x2408'):{const _0x17ab29=_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1407')][_0x27fe89('0x1fc5')](',');_0x4eee78[_0x27fe89('0x24f2')]['times']=isNaN(_0x17ab29[0x0])?_0x17ab29[0x0]:parseInt(_0x17ab29[0x0],0xa),_0x4eee78['system']['text']=_0x17ab29[_0x27fe89('0x12c8')](0x1,_0x17ab29[_0x27fe89('0x1564')])[_0x27fe89('0x1630')](',');}break;case _0x27fe89('0x8c2'):_0x4eee78['system'][_0x27fe89('0x1bcd')]=_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1407')];break;case'set':_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x60a')]=_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1407')][_0x27fe89('0x1fc5')]('=')[0x0],_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1c6b')]=_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x1407')][_0x27fe89('0x1fc5')]('=')[0x1];break;case'agi':_0x4eee78[_0x27fe89('0x24f2')]['project']=_0x4eee78[_0x27fe89('0x24f2')]['appdata'];break;default:{const _0x315d4c=_0x4eee78[_0x27fe89('0x24f2')]['appdata'][_0x27fe89('0x1fc5')](',');_0x4eee78['system'][_0x27fe89('0x6db')]=_0x2e3ca0()[_0x27fe89('0x173f')](_0x315d4c[0x0])?_0x315d4c[0x0]:isNaN(_0x315d4c[0x0])?_0x315d4c[0x0]:parseInt(_0x315d4c[0x0],0xa),_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x26e0')]=_0x2e3ca0()[_0x27fe89('0x173f')](_0x315d4c[0x1])?_0x315d4c[0x1]:isNaN(_0x315d4c[0x1])?_0x315d4c[0x1]:parseInt(_0x315d4c[0x1],0xa);}break;}else _0x4eee78[_0x27fe89('0x24f2')]['variable']='';_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0xcf0')]&&_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0xcf0')][_0x27fe89('0x93a')]()===_0x27fe89('0x17cd')&&_0x4eee78[_0x27fe89('0x24f2')]['appType']['toLowerCase']()===_0x27fe89('0x659')&&(_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x24fa')]=_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0xd31')]?_0x4eee78['system'][_0x27fe89('0xd31')][_0x27fe89('0x1fc5')]('$')[0x0]:undefined,_0x4eee78['system'][_0x27fe89('0xabd')]=_0x4eee78[_0x27fe89('0x24f2')][_0x27fe89('0x73c')]?_0x27fe89('0xac1')+_0x4eee78['system'][_0x27fe89('0x73c')]:undefined);_0x4eee78[_0x27fe89('0x22a1')]=_0x92cf12,_0x4eee78[_0x27fe89('0xf82')]=_0xaae58b,_0x480efd[_0x27fe89('0xca1')]('admin')?_0x365dcf['variable'][_0x27fe89('0x1e6e')]({'fields':'id,name','sort':_0x27fe89('0x60a'),'nolimit':_0x27fe89('0x26ac')})['$promise'][_0x27fe89('0x683')](function(_0x4ed87e){const _0x38b357=_0x27fe89;_0x4eee78[_0x38b357('0x220b')]=_0x4ed87e['rows']||[];})[_0x27fe89('0x130a')](function(_0x3a9278){const _0x5ed66c=_0x27fe89;_0x344899[_0x5ed66c('0x52a')]({'title':_0x3a9278[_0x5ed66c('0x13ee')]?_0x5ed66c('0x2168')+_0x3a9278[_0x5ed66c('0x13ee')]+_0x5ed66c('0xbf6')+_0x3a9278[_0x5ed66c('0x24a9')]:_0x5ed66c('0x9a9'),'msg':_0x3a9278[_0x5ed66c('0x5a5')]?JSON[_0x5ed66c('0x258a')](_0x3a9278[_0x5ed66c('0x5a5')]):_0x3a9278[_0x5ed66c('0x1ff0')]()});}):_0x365dcf[_0x27fe89('0x26e0')][_0x27fe89('0x1e6e')]({'fields':'id,name','sort':_0x27fe89('0x60a'),'nolimit':_0x27fe89('0x26ac')})[_0x27fe89('0xe53')][_0x27fe89('0x683')](function(_0x228fca){const _0xb9c2b6=_0x27fe89;_0x4eee78['variables']=_0x228fca[_0xb9c2b6('0xf5d')]||[];})[_0x27fe89('0x683')](function(){const _0x16870c=_0x27fe89;return _0x365dcf[_0x16870c('0x22df')][_0x16870c('0x1e6e')]({'userProfileId':_0x4eee78[_0x16870c('0x11ed')]['userProfileId'],'sectionId':0x3f4})[_0x16870c('0xe53')];})[_0x27fe89('0x683')](function(_0x48e019){const _0x4bb962=_0x27fe89,_0x8fdfe9=_0x48e019&&_0x48e019['rows']?_0x48e019[_0x4bb962('0xf5d')][0x0]:null;if(!_0x8fdfe9){const _0x42fdd4=[];let _0x352412=null;_0x4eee78[_0x4bb962('0x24f2')]&&(_0x352412=_0x2e3ca0()[_0x4bb962('0x1c07')](_0x4eee78[_0x4bb962('0x220b')],{'name':_0x4eee78['system']['variable']}));for(let _0x2743cc=0x0;_0x2743cc<_0x4eee78[_0x4bb962('0x220b')][_0x4bb962('0x1564')];_0x2743cc++){_0x352412&&_0x4eee78[_0x4bb962('0x220b')][_0x2743cc]['id']===_0x352412['id']&&(_0x4eee78[_0x4bb962('0x220b')][_0x2743cc]['canSelect']=![],_0x42fdd4[_0x4bb962('0x1fd0')](_0x4eee78[_0x4bb962('0x220b')][_0x2743cc]));}_0x4eee78[_0x4bb962('0x220b')]=_0x42fdd4;}else{if(!_0x8fdfe9[_0x4bb962('0x170')])return _0x365dcf[_0x4bb962('0xcf7')]['get']({'sectionId':_0x8fdfe9['id']})[_0x4bb962('0xe53')]['then'](function(_0x1db5f6){const _0x1a548e=_0x4bb962,_0x60c074=_0x2e3ca0()[_0x1a548e('0x386')](_0x1db5f6[_0x1a548e('0xf5d')],function(_0x50112e){const _0x492ece=_0x1a548e;return _0x2e3ca0()[_0x492ece('0x1c07')](_0x4eee78[_0x492ece('0x220b')],{'id':_0x50112e[_0x492ece('0x832')]});});let _0x453009=null;_0x4eee78[_0x1a548e('0x24f2')]&&(_0x453009=_0x2e3ca0()[_0x1a548e('0x1c07')](_0x4eee78[_0x1a548e('0x220b')],{'name':_0x4eee78[_0x1a548e('0x24f2')][_0x1a548e('0x26e0')]}));if(_0x453009&&!_0x2e3ca0()[_0x1a548e('0x7a2')](_0x60c074,['id',_0x453009['id']])){const _0x55e46b=_0x2e3ca0()[_0x1a548e('0x1c07')](_0x4eee78[_0x1a548e('0x220b')],{'id':_0x453009['id']});_0x55e46b[_0x1a548e('0x319')]=![],_0x60c074[_0x1a548e('0x1fd0')](_0x55e46b);}_0x4eee78[_0x1a548e('0x220b')]=_0x60c074;});}})[_0x27fe89('0x130a')](function(_0x489b3d){const _0xea15d2=_0x27fe89;_0x344899['error']({'title':_0x489b3d[_0xea15d2('0x13ee')]?_0xea15d2('0x2168')+_0x489b3d[_0xea15d2('0x13ee')]+_0xea15d2('0xbf6')+_0x489b3d[_0xea15d2('0x24a9')]:_0xea15d2('0x392'),'msg':_0x489b3d[_0xea15d2('0x5a5')]?JSON[_0xea15d2('0x258a')](_0x489b3d[_0xea15d2('0x5a5')]):_0x489b3d[_0xea15d2('0x1ff0')]()});});function _0x92cf12(){const _0x442f12=_0x27fe89;_0x4eee78[_0x442f12('0x17f')]=[];const _0x484025=[];_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0xcf0')]&&_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0xcf0')][_0x442f12('0x93a')]()===_0x442f12('0x17cd')&&_0x4eee78['system']['appType']===_0x442f12('0x4d2')&&(_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0xd31')]=_0x27ff18[_0x442f12('0x145a')]?(_0x4eee78['system'][_0x442f12('0x24fa')]||'')+'${EXTEN:'+_0x27ff18[_0x442f12('0x145a')]+'}':(_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x24fa')]||'')+_0x442f12('0x20cb'),_0x27ff18[_0x442f12('0x75b')]!==_0x442f12('0x925')?_0x4eee78['system'][_0x442f12('0x158e')]['indexOf']('U(xcally-mixmonitor-context)')<0x0&&(_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x158e')]+=_0x442f12('0x1b1')):_0x4eee78['system'][_0x442f12('0x158e')]=_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x158e')][_0x442f12('0x1725')](_0x442f12('0x1b1'),''));if(_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x11f3')]&&_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x11f3')]==='custom'){}else switch((_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x1d75')]||_0x4eee78[_0x442f12('0x24f2')]['appType'])[_0x442f12('0x93a')]()){case _0x442f12('0x877'):_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x1407')]=_0x4eee78['system']['name']+'='+_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x1c6b')];break;case _0x442f12('0xbf0'):break;default:_0x484025[0x0]=_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x6db')],_0x484025[0x1]=_0x4eee78[_0x442f12('0x24f2')][_0x442f12('0x26e0')],_0x4eee78['system'][_0x442f12('0x1407')]=_0x484025['join'](',');}_0xaae58b(_0x4eee78['system']);}function _0xaae58b(_0x1c9cdc){_0xba5acf['hide'](_0x1c9cdc);}}const _0x45a08c=_0x5a603c;_0x2b8767[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x1cc0'),_0x189033('0xb87'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x2b8767(_0x156b4c,_0x4c50a1,_0x430388,_0x1a4dcd,_0x3472da,_0x542bbc,_0x3a8b76,_0x55d975){const _0x590f67=_0x189033,_0x5a51c6=this;_0x5a51c6[_0x590f67('0x11ed')]=_0x3a8b76[_0x590f67('0x20b2')](),_0x5a51c6[_0x590f67('0x17f')]=[],_0x5a51c6[_0x590f67('0xf28')]=_0x590f67('0x3df')+(_0x1a4dcd['appType']||_0x1a4dcd[_0x590f67('0x1d75')])[_0x590f67('0x80')](),_0x5a51c6['tag']=angular[_0x590f67('0x1a86')](_0x1a4dcd),_0x5a51c6[_0x590f67('0x1134')]=_0x55d975,_0x5a51c6[_0x590f67('0x258d')]={};if(_0x5a51c6['tag']['appdata'])switch(_0x5a51c6[_0x590f67('0x270')]['appType']?_0x5a51c6['tag'][_0x590f67('0x11f3')]['toLowerCase']():_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1d75')][_0x590f67('0x93a')]()){case _0x590f67('0xbf0'):break;case _0x590f67('0x205c'):{const _0x579d3d=_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1407')]['split'](',');_0x5a51c6['tag'][_0x590f67('0x1d46')]=_0x579d3d[0x0],_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1a1c')]=_0x579d3d[0x1],_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x6d9')]=_0x579d3d[_0x590f67('0x12c8')](0x2,_0x579d3d[_0x590f67('0x1564')])['join'](',');}break;case _0x590f67('0xd24'):{const _0xf40dcf=_0x5a51c6['tag'][_0x590f67('0x1407')][_0x590f67('0x1fc5')](',');_0x5a51c6[_0x590f67('0x270')]['projectId']=_0xf40dcf[0x0],_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x38')]=_0xf40dcf[0x1],_0x5a51c6[_0x590f67('0x270')]['privateKey']=_0xf40dcf[0x2],_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1a1c')]=_0xf40dcf[0x3],_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x6d9')]=_0xf40dcf[_0x590f67('0x12c8')](0x4,_0xf40dcf[_0x590f67('0x1564')])[_0x590f67('0x1630')](',');}break;case _0x590f67('0x1db1'):{const _0x409a8b=_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1407')][_0x590f67('0x1fc5')](',');_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x7ae')]=_0x409a8b[0x0],_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x204a')]=_0x409a8b[0x1],_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x5ba')]=_0x409a8b[0x2],_0x5a51c6['tag'][_0x590f67('0x11a9')]=_0x409a8b[0x3],_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x6d9')]=_0x409a8b[_0x590f67('0x12c8')](0x4,_0x409a8b['length'])['join'](',');}break;case'autoreply':{const _0x3b85a3=_0x5a51c6[_0x590f67('0x270')]['appdata']['split'](',');_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x35')]=isNaN(_0x3b85a3[0x0])?_0x3b85a3[0x0]:parseInt(_0x3b85a3[0x0],0xa),_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1bcd')]=_0x3b85a3[_0x590f67('0x12c8')](0x1,_0x3b85a3[_0x590f67('0x1564')])[_0x590f67('0x1630')](',');}break;case _0x590f67('0x8c2'):_0x5a51c6['tag']['text']=_0x5a51c6['tag'][_0x590f67('0x1407')];break;case _0x590f67('0x877'):_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x60a')]=_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1407')][_0x590f67('0x1fc5')]('=')[0x0],_0x5a51c6[_0x590f67('0x270')]['value']=_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1407')][_0x590f67('0x1fc5')]('=')[0x1];break;case'agi':_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x273a')]=_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1407')];break;default:{const _0x45eadc=_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x1407')][_0x590f67('0x1fc5')](',');_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x270')]=_0x2e3ca0()[_0x590f67('0x173f')](_0x45eadc[0x0])?_0x45eadc[0x0]:isNaN(_0x45eadc[0x0])?_0x45eadc[0x0]:parseInt(_0x45eadc[0x0],0xa);}break;}else{}_0x5a51c6[_0x590f67('0x270')]['type']&&_0x5a51c6[_0x590f67('0x270')][_0x590f67('0xcf0')][_0x590f67('0x93a')]()==='outbound'&&_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x11f3')][_0x590f67('0x93a')]()==='outbounddial'&&(_0x5a51c6['tag'][_0x590f67('0x24fa')]=_0x5a51c6[_0x590f67('0x270')][_0x590f67('0xd31')]?_0x5a51c6[_0x590f67('0x270')][_0x590f67('0xd31')][_0x590f67('0x1fc5')]('$')[0x0]:undefined,_0x5a51c6[_0x590f67('0x270')][_0x590f67('0xabd')]=_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x73c')]?_0x590f67('0xac1')+_0x5a51c6[_0x590f67('0x270')][_0x590f67('0x73c')]:undefined);_0x5a51c6[_0x590f67('0x22a1')]=_0x374aca,_0x5a51c6[_0x590f67('0xf82')]=_0x817248,_0x3a8b76[_0x590f67('0xca1')](_0x590f67('0x20c2'))?_0x542bbc['tag'][_0x590f67('0x1e6e')]({'fields':_0x590f67('0xa10'),'sort':'name','nolimit':_0x590f67('0x26ac')})[_0x590f67('0xe53')][_0x590f67('0x683')](function(_0x2e156d){const _0x1370b8=_0x590f67;_0x5a51c6['tags']=_0x2e156d[_0x1370b8('0xf5d')]||[];})[_0x590f67('0x130a')](function(_0x4d89a0){const _0x11f4a0=_0x590f67;_0x430388['error']({'title':_0x4d89a0[_0x11f4a0('0x13ee')]?_0x11f4a0('0x2168')+_0x4d89a0[_0x11f4a0('0x13ee')]+'\x20-\x20'+_0x4d89a0[_0x11f4a0('0x24a9')]:_0x11f4a0('0x14ef'),'msg':_0x4d89a0[_0x11f4a0('0x5a5')]?JSON[_0x11f4a0('0x258a')](_0x4d89a0[_0x11f4a0('0x5a5')]):_0x4d89a0[_0x11f4a0('0x1ff0')]()});}):_0x542bbc[_0x590f67('0x270')][_0x590f67('0x1e6e')]({'fields':_0x590f67('0xa10'),'sort':_0x590f67('0x60a'),'nolimit':'true'})[_0x590f67('0xe53')]['then'](function(_0x421041){const _0x2804f7=_0x590f67;_0x5a51c6[_0x2804f7('0x1ce6')]=_0x421041[_0x2804f7('0xf5d')]||[];})[_0x590f67('0x683')](function(){const _0x411a96=_0x590f67;return _0x542bbc[_0x411a96('0x22df')]['get']({'userProfileId':_0x5a51c6[_0x411a96('0x11ed')][_0x411a96('0x2f')],'sectionId':0x3f0})[_0x411a96('0xe53')];})[_0x590f67('0x683')](function(_0x1d2bae){const _0x264be8=_0x590f67,_0x128633=_0x1d2bae&&_0x1d2bae[_0x264be8('0xf5d')]?_0x1d2bae[_0x264be8('0xf5d')][0x0]:null;if(!_0x128633){const _0x24703a=[];let _0x3e1f75=null;_0x5a51c6[_0x264be8('0x270')]&&(_0x3e1f75=_0x2e3ca0()[_0x264be8('0x1c07')](_0x5a51c6['tags'],{'name':_0x5a51c6['tag'][_0x264be8('0x270')]}));for(let _0x21a544=0x0;_0x21a544<_0x5a51c6[_0x264be8('0x1ce6')][_0x264be8('0x1564')];_0x21a544++){_0x3e1f75&&_0x5a51c6[_0x264be8('0x1ce6')][_0x21a544]['id']===_0x3e1f75['id']&&(_0x5a51c6[_0x264be8('0x1ce6')][_0x21a544]['canSelect']=![],_0x24703a[_0x264be8('0x1fd0')](_0x5a51c6[_0x264be8('0x1ce6')][_0x21a544]));}_0x5a51c6['tags']=_0x24703a;}else{if(!_0x128633[_0x264be8('0x170')])return _0x542bbc[_0x264be8('0xcf7')]['get']({'sectionId':_0x128633['id']})['$promise'][_0x264be8('0x683')](function(_0x3f7810){const _0xf460f=_0x264be8,_0x11387c=_0x2e3ca0()['map'](_0x3f7810['rows'],function(_0x5bdfd8){const _0x3188f2=a0_0x4e0a;return _0x2e3ca0()[_0x3188f2('0x1c07')](_0x5a51c6[_0x3188f2('0x1ce6')],{'id':_0x5bdfd8[_0x3188f2('0x832')]});});let _0x5c2cdb=null;_0x5a51c6[_0xf460f('0x270')]&&(_0x5c2cdb=_0x2e3ca0()['find'](_0x5a51c6['tags'],{'name':_0x5a51c6[_0xf460f('0x270')]['tag']}));if(_0x5c2cdb&&!_0x2e3ca0()[_0xf460f('0x7a2')](_0x11387c,['id',_0x5c2cdb['id']])){const _0x3b464f=_0x2e3ca0()[_0xf460f('0x1c07')](_0x5a51c6[_0xf460f('0x1ce6')],{'id':_0x5c2cdb['id']});_0x3b464f[_0xf460f('0x319')]=![],_0x11387c['push'](_0x3b464f);}_0x5a51c6['tags']=_0x11387c;});}})['catch'](function(_0x2b0036){const _0x5c0d48=_0x590f67;_0x430388[_0x5c0d48('0x52a')]({'title':_0x2b0036[_0x5c0d48('0x13ee')]?_0x5c0d48('0x2168')+_0x2b0036[_0x5c0d48('0x13ee')]+_0x5c0d48('0xbf6')+_0x2b0036[_0x5c0d48('0x24a9')]:_0x5c0d48('0x1118'),'msg':_0x2b0036[_0x5c0d48('0x5a5')]?JSON[_0x5c0d48('0x258a')](_0x2b0036[_0x5c0d48('0x5a5')]):_0x2b0036[_0x5c0d48('0x1ff0')]()});});function _0x374aca(){const _0x192f2c=_0x590f67;_0x5a51c6[_0x192f2c('0x17f')]=[];const _0x249854=[];_0x5a51c6['tag']['type']&&_0x5a51c6['tag'][_0x192f2c('0xcf0')]['toLowerCase']()===_0x192f2c('0x17cd')&&_0x5a51c6['tag'][_0x192f2c('0x11f3')]===_0x192f2c('0x4d2')&&(_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0xd31')]=_0x3472da[_0x192f2c('0x145a')]?(_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x24fa')]||'')+_0x192f2c('0x249e')+_0x3472da['cutdigits']+'}':(_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x24fa')]||'')+_0x192f2c('0x20cb'),_0x3472da[_0x192f2c('0x75b')]!==_0x192f2c('0x925')?_0x5a51c6['tag']['options'][_0x192f2c('0x824')](_0x192f2c('0x1b1'))<0x0&&(_0x5a51c6['tag'][_0x192f2c('0x158e')]+=_0x192f2c('0x1b1')):_0x5a51c6['tag'][_0x192f2c('0x158e')]=_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x158e')]['replace'](_0x192f2c('0x1b1'),''));const _0x56cac9=_0x2e3ca0()[_0x192f2c('0x1c07')](_0x5a51c6[_0x192f2c('0x1ce6')],{'name':_0x5a51c6[_0x192f2c('0x270')]['tag']});_0x56cac9&&(_0x5a51c6['tag'][_0x192f2c('0xb6d')]=_0x56cac9['id']);if(_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x11f3')]&&_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x11f3')]===_0x192f2c('0xbf0')){}else switch((_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x1d75')]||_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x11f3')])[_0x192f2c('0x93a')]()){case _0x192f2c('0x877'):_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x1407')]=_0x5a51c6[_0x192f2c('0x270')]['name']+'='+_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x1c6b')];break;case _0x192f2c('0xbf0'):break;default:_0x249854[0x0]=_0x5a51c6['tag'][_0x192f2c('0x270')],_0x5a51c6[_0x192f2c('0x270')][_0x192f2c('0x1407')]=_0x249854[_0x192f2c('0x1630')](',');}_0x817248(_0x5a51c6['tag']);}function _0x817248(_0x7f8841){_0x156b4c['hide'](_0x7f8841);}}const _0x405406=_0x2b8767;_0x1d43fa['$inject']=[_0x189033('0x17e4'),_0x189033('0x7a5'),_0x189033('0x938'),'$q','$translate',_0x189033('0x2f9'),_0x189033('0x1e48'),'$document','toasty','api',_0x189033('0xba1')];function _0x1d43fa(_0x100b33,_0x31e7e6,_0x438283,_0x3fd97d,_0x45fa48,_0x4f3e6e,_0x4d4d39,_0x2aefae,_0x5c8da1,_0x2eb21f,_0x57f561){const _0x451d26=_0x189033,_0x2c3857=this;_0x2c3857['currentUser']=_0x57f561[_0x451d26('0x20b2')](),_0x2c3857[_0x451d26('0xb87')]={},_0x2c3857[_0x451d26('0x257')]={'count':0x0,'rows':[]},_0x2c3857[_0x451d26('0x288e')]=[],_0x2c3857[_0x451d26('0x1134')],_0x2c3857[_0x451d26('0x23a2')]={'read':_0x451d26('0x13c'),'closed':_0x451d26('0x13c'),'sort':_0x451d26('0xddd'),'includeAll':'true','limit':0xa,'page':0x1},_0x2c3857['init']=_0x2ddafe,_0x2c3857[_0x451d26('0x26eb')]=_0x535f92,_0x2c3857['mailInteractionDownload']=_0x253954,_0x2c3857['success']=_0x128b34,_0x2c3857[_0x451d26('0x76d')]=_0x3bc396,_0x2c3857[_0x451d26('0x10bf')]=_0x2b9c5b,_0x2c3857[_0x451d26('0x2121')]=_0x5dbf84,_0x2c3857[_0x451d26('0x2526')]=_0x597890,_0x2c3857['deleteMailAccountInteraction']=_0x24500f,_0x2c3857['deleteSelectedMailAccountInteractions']=_0x40138a;function _0x2ddafe(_0x494c24,_0x3f079e){const _0xe5980d=_0x451d26;_0x2c3857[_0xe5980d('0xb87')]=_0x494c24,_0x2c3857['crudPermissions']=typeof _0x3f079e!==_0xe5980d('0x1867')?_0x3f079e:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x2c3857[_0xe5980d('0x23a2')]['MailAccountId']=_0x2c3857[_0xe5980d('0xb87')]['id'],_0x2c3857[_0xe5980d('0x19c9')]={'fields':_0x322616()},_0xb22896();}function _0xb22896(){const _0x3dce62=_0x451d26;return _0x2eb21f[_0x3dce62('0x270')]['get']()['$promise'][_0x3dce62('0x683')](function(_0xa1bc67){const _0x5c57d4=_0x3dce62;_0x2c3857[_0x5c57d4('0x1ce6')]=_0xa1bc67||{'count':0x0,'rows':[]};})['then'](function(){const _0x4ca30a=_0x3dce62;return _0x2eb21f[_0x4ca30a('0x1577')][_0x4ca30a('0x1e6e')]({'nolimit':!![]})[_0x4ca30a('0xe53')]['then'](function(_0x2edea2){const _0x3ae4a7=_0x4ca30a;_0x2c3857[_0x3ae4a7('0x26a3')]=_0x2edea2||{'count':0x0,'rows':[]};});})['then'](function(){_0x2c3857['quickFilters']=_0x3016b5();});}function _0x3016b5(){const _0x3cc10f=_0x451d26;return[{'name':'Start\x20Date','key':'createdAt','type':_0x3cc10f('0x270e'),'label':_0x3cc10f('0x1006')},{'name':_0x3cc10f('0xc51'),'key':_0x3cc10f('0x20db'),'type':_0x3cc10f('0xb31'),'label':_0x3cc10f('0x1866'),'customOptions':[{'value':0x0,'translate':_0x3cc10f('0x2226')},{'value':0x1,'translate':_0x3cc10f('0x38f')},{'value':null,'translate':'DASHBOARDS.ALL'}]},{'name':_0x3cc10f('0x1d9d'),'key':_0x3cc10f('0xd8a'),'type':'select','label':_0x3cc10f('0x1b77'),'customOptions':[{'value':0x0,'translate':_0x3cc10f('0x10b1')},{'value':0x1,'translate':'DASHBOARDS.CLOSED'},{'value':null,'translate':_0x3cc10f('0x475')}]},{'name':_0x3cc10f('0x1d02'),'key':_0x3cc10f('0x231b'),'type':_0x3cc10f('0xb31'),'label':_0x3cc10f('0x2af'),'options':_0x2c3857[_0x3cc10f('0x26a3')][_0x3cc10f('0xf5d')],'customOptions':[{'value':'null','translate':_0x3cc10f('0xfd6')},{'value':undefined,'translate':'DASHBOARDS.ALL'}],'ngValue':_0x3cc10f('0x60a'),'ngIf':_0x3cc10f('0xb01')},{'name':_0x3cc10f('0x62c'),'key':_0x3cc10f('0x10c5'),'type':_0x3cc10f('0xb31'),'label':_0x3cc10f('0x21fb'),'customOptions':[{'value':_0x3cc10f('0x13c'),'translate':_0x3cc10f('0x2608')},{'value':undefined,'translate':_0x3cc10f('0x475')}]},{'name':_0x3cc10f('0x1e'),'key':'tag','type':'multiselect','label':_0x3cc10f('0x2264'),'options':_0x2c3857[_0x3cc10f('0x1ce6')][_0x3cc10f('0xf5d')],'placeholder':_0x3cc10f('0x7cb')}];}function _0x322616(){const _0x51240e=_0x451d26;return[{'name':'Id','column':'id','type':_0x51240e('0x121f')},{'name':_0x51240e('0x1309'),'column':_0x51240e('0x1309'),'type':_0x51240e('0xeb'),'options':{'searchFields':[_0x51240e('0xeef'),'lastName',_0x51240e('0x1c92')],'route':{'model':'cmContact','action':'get','params':{'fields':'id,firstName,lastName,email','Contact':_0x51240e('0xfd'),'nolimit':!![]}},'extraOperators':['$substring'],'excludedOperators':[_0x51240e('0x17ee')]}},{'name':_0x51240e('0x25a9'),'column':_0x51240e('0x1e66'),'type':_0x51240e('0x1bcd'),'options':{'excludedOperators':[_0x51240e('0x393'),_0x51240e('0x17ee')]}},{'name':_0x51240e('0x1765'),'column':_0x51240e('0x183b'),'type':'text','options':{'excludedOperators':[_0x51240e('0x393'),_0x51240e('0x17ee')]}},{'name':_0x51240e('0x1d9d'),'column':_0x51240e('0xd8a'),'type':_0x51240e('0xb31'),'values':[{'id':0x0,'translate':_0x51240e('0x10b1')},{'id':0x1,'translate':_0x51240e('0x270a')}],'options':{'excludedOperators':['$ne']}},{'name':_0x51240e('0x1d02'),'column':_0x51240e('0x231b'),'type':_0x51240e('0xf6c'),'options':{'field':_0x51240e('0x60a'),'route':{'model':'mailSubstatus','action':_0x51240e('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':['$notIn']}},{'name':_0x51240e('0x62c'),'column':_0x51240e('0x1dad'),'type':'autocomplete','options':{'table':'i','route':{'model':_0x51240e('0xc96'),'action':_0x51240e('0x1e6e'),'params':{'role':_0x51240e('0x2327'),'fields':_0x51240e('0x2686'),'nolimit':!![]}},'searchFields':['fullname','name'],'extraOperators':[_0x51240e('0xe55')],'excludedOperators':['$ne']}},{'name':_0x51240e('0x198f'),'column':_0x51240e('0x1e'),'type':_0x51240e('0xf6c'),'options':{'route':{'model':_0x51240e('0x270'),'action':_0x51240e('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x51240e('0x1479')]}},{'name':_0x51240e('0x10c1'),'column':'createdAt','type':_0x51240e('0x270e'),'options':{'excludedOperators':[_0x51240e('0x17ee')]}},{'name':_0x51240e('0x1bb6'),'column':_0x51240e('0x122e'),'type':_0x51240e('0xb31'),'values':[{'id':0x1,'translate':'DASHBOARDS.READ'},{'id':0x0,'translate':_0x51240e('0x2226')}],'options':{'excludedOperators':['$ne']}}];}function _0x5dbf84(){const _0x4f6d58=_0x451d26;_0x4d4d39[_0x4f6d58('0x1d4')]({'controller':_0x4f6d58('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x4f6d58('0x1fcc')](_0x2aefae[_0x4f6d58('0x18e5')]),'clickOutsideToClose':![],'locals':{'fields':_0x2c3857['advancedSearch'][_0x4f6d58('0x189a')],'color':undefined,'storagePath':_0x4f6d58('0x266a')},'fullscreen':!![]})[_0x4f6d58('0x683')](function(_0x279e48){const _0x1dd071=_0x4f6d58;_0x2c3857['query'][_0x1dd071('0x19a4')]=_0x279e48===![]?undefined:_0x279e48;if(_0x2c3857[_0x1dd071('0x23a2')][_0x1dd071('0x19a4')])_0x2c3857[_0x1dd071('0x23a2')][_0x1dd071('0x19a4')]+=_0x1dd071('0x1940')+_0x2c3857['mailAccount']['id']+']',_0x3bc396();else _0x279e48===![]&&_0x3bc396();})['catch'](function(_0x29cf33){const _0xf12fb3=_0x4f6d58;_0x5c8da1[_0xf12fb3('0x52a')]({'title':_0xf12fb3('0x1119'),'msg':_0x29cf33[_0xf12fb3('0x5a5')]?JSON['stringify'](_0x29cf33[_0xf12fb3('0x5a5')]['message']):_0x29cf33[_0xf12fb3('0x1ff0')]()});});}function _0x253954(_0x894a83,_0x3335a2,_0x127e34){const _0x536bb9=_0x451d26;return _0x2eb21f[_0x536bb9('0x95a')][_0x536bb9('0x18e8')]({'id':_0x894a83['id'],'exists':!![],'attachments':_0x127e34})[_0x536bb9('0xe53')][_0x536bb9('0x683')](function(_0x3ae661){const _0x5d4d46=_0x536bb9,_0x29f3a1=[_0x3ae661[_0x5d4d46('0x1fb3')]];let _0x35e6fa=_0x5d4d46('0xa98')+_0x894a83['id'];const _0x4aecdc=new Blob(_0x29f3a1,{'type':_0x3ae661['type']});_0x35e6fa=_0x5d4d46('0x14')+_0x894a83['id']+_0x5d4d46('0x18ff');const _0x5a9f5a=window['document']['createElement']('a');_0x5a9f5a[_0x5d4d46('0x130f')](_0x5d4d46('0x2767'),URL[_0x5d4d46('0x2820')](_0x4aecdc)),_0x5a9f5a[_0x5d4d46('0x130f')](_0x5d4d46('0x18e8'),_0x35e6fa),document[_0x5d4d46('0x18e5')][_0x5d4d46('0x1e43')](_0x5a9f5a),_0x5a9f5a[_0x5d4d46('0x1d42')]();})['catch'](function(_0x169a65){const _0x4289dd=_0x536bb9;if(_0x169a65[_0x4289dd('0x5a5')]&&_0x169a65[_0x4289dd('0x5a5')][_0x4289dd('0x17f')]&&_0x169a65['data'][_0x4289dd('0x17f')][_0x4289dd('0x1564')])for(let _0x44d167=0x0;_0x44d167<_0x169a65['data'][_0x4289dd('0x17f')][_0x4289dd('0x1564')];_0x44d167+=0x1){_0x5c8da1[_0x4289dd('0x52a')]({'title':_0x169a65[_0x4289dd('0x5a5')]['errors'][_0x44d167][_0x4289dd('0xcf0')],'msg':_0x169a65[_0x4289dd('0x5a5')][_0x4289dd('0x17f')][_0x44d167][_0x4289dd('0x8c2')]});}else _0x5c8da1[_0x4289dd('0x52a')]({'title':_0x169a65['status']?_0x4289dd('0x2168')+_0x169a65[_0x4289dd('0x13ee')]+_0x4289dd('0xbf6')+_0x169a65[_0x4289dd('0x24a9')]:'api.mailAccount.save','msg':_0x169a65[_0x4289dd('0x5a5')]?JSON['stringify'](_0x169a65[_0x4289dd('0x5a5')][_0x4289dd('0x8c2')]):_0x169a65[_0x4289dd('0x1ff0')]()});});}function _0x535f92(_0x7b85f9,_0x1956c0){const _0x30f7bc=_0x451d26,_0x4065b9=_0x4d4d39[_0x30f7bc('0x1c6f')]()['title'](_0x30f7bc('0xb1f'))[_0x30f7bc('0x26e3')](_0x30f7bc('0xed5')+(_0x7b85f9['name']||_0x7b85f9['id']&&_0x2e3ca0()['upperFirst']('interaction\x20#')+_0x7b85f9['id']||_0x30f7bc('0xa98'))+_0x30f7bc('0x20f1')+_0x30f7bc('0x1ee7'))[_0x30f7bc('0x1040')](_0x30f7bc('0x19a8'))[_0x30f7bc('0xe42')](_0x1956c0)['ok']('OK')[_0x30f7bc('0x19fb')](_0x30f7bc('0x16b8'));_0x4d4d39[_0x30f7bc('0x1d4')](_0x4065b9)['then'](function(){_0x24500f(_0x7b85f9);},function(){const _0x532696=_0x30f7bc;console[_0x532696('0x1b2b')](_0x532696('0x16b8'));});}function _0x128b34(_0x394b70){const _0x2d04ae=_0x451d26;_0x2c3857[_0x2d04ae('0x257')]=_0x394b70||{'count':0x0,'rows':[]};for(let _0x5e1a7a=0x0;_0x5e1a7a<_0x2c3857[_0x2d04ae('0x257')][_0x2d04ae('0xf5d')][_0x2d04ae('0x1564')];_0x5e1a7a+=0x1){const _0x4a185d=_0x2c3857['mailAccountInteractions'][_0x2d04ae('0xf5d')][_0x5e1a7a];_0x4521ef(_0x4a185d),_0x4a185d[_0x2d04ae('0x2464')]['name']=_0x29faf6(_0x4a185d);}}function _0x3bc396(){const _0x5a57cc=_0x451d26;_0x2c3857[_0x5a57cc('0x23a2')]['offset']=(_0x2c3857['query'][_0x5a57cc('0xdf8')]-0x1)*_0x2c3857[_0x5a57cc('0x23a2')][_0x5a57cc('0x6f0')],_0x2c3857[_0x5a57cc('0x1883')]=_0x2eb21f[_0x5a57cc('0x95a')][_0x5a57cc('0x1e6e')](_0x2c3857[_0x5a57cc('0x23a2')],_0x128b34)[_0x5a57cc('0xe53')];}function _0x2b9c5b(_0xbd09b6,_0x38f581){const _0x25f430=_0x451d26;_0x4d4d39['show']({'controller':_0x25f430('0x13ab'),'controllerAs':'vm','templateUrl':_0x37aa85,'parent':angular[_0x25f430('0x1fcc')](_0x2aefae[_0x25f430('0x18e5')]),'targetEvent':_0xbd09b6,'clickOutsideToClose':!![],'onShowing':function(_0x18ecdb){const _0x7b87=_0x25f430;_0x18ecdb['vm']['init']({'id':0x1,'channel':_0x7b87('0x129f'),'interaction':_0x38f581,'spy':!![]},_0x31e7e6['$parent']['vm'][_0x7b87('0x260a')]);}});}function _0x24500f(_0x34e936){const _0x2afaa2=_0x451d26;_0x2eb21f[_0x2afaa2('0x95a')][_0x2afaa2('0xd7e')]({'id':_0x34e936['id']})[_0x2afaa2('0xe53')][_0x2afaa2('0x683')](function(){const _0x41be05=_0x2afaa2;_0x2e3ca0()[_0x41be05('0x3ec')](_0x2c3857[_0x41be05('0x257')][_0x41be05('0xf5d')],{'id':_0x34e936['id']}),_0x2c3857[_0x41be05('0x257')][_0x41be05('0x50d')]-=0x1,!_0x2c3857['mailAccountInteractions'][_0x41be05('0xf5d')][_0x41be05('0x1564')]&&_0x3bc396(),_0x5c8da1[_0x41be05('0x53')]({'title':'Interaction\x20deleted!','msg':_0x34e936['name']?_0x34e936[_0x41be05('0x60a')]+_0x41be05('0x194d'):''});})[_0x2afaa2('0x130a')](function(_0x3c4b13){const _0x25174a=_0x2afaa2;if(_0x3c4b13['data']&&_0x3c4b13[_0x25174a('0x5a5')]['errors']&&_0x3c4b13[_0x25174a('0x5a5')][_0x25174a('0x17f')][_0x25174a('0x1564')]){_0x2c3857[_0x25174a('0x17f')]=_0x3c4b13[_0x25174a('0x5a5')][_0x25174a('0x17f')]||[{'message':_0x3c4b13[_0x25174a('0x1ff0')](),'type':_0x25174a('0x160e')}];for(let _0xdd4dcd=0x0;_0xdd4dcd<_0x3c4b13[_0x25174a('0x5a5')][_0x25174a('0x17f')][_0x25174a('0x1564')];_0xdd4dcd++){_0x5c8da1[_0x25174a('0x52a')]({'title':_0x3c4b13[_0x25174a('0x5a5')][_0x25174a('0x17f')][_0xdd4dcd][_0x25174a('0xcf0')],'msg':_0x3c4b13[_0x25174a('0x5a5')]['errors'][_0xdd4dcd][_0x25174a('0x8c2')]});}}else _0x5c8da1[_0x25174a('0x52a')]({'title':_0x3c4b13[_0x25174a('0x13ee')]?_0x25174a('0x2168')+_0x3c4b13[_0x25174a('0x13ee')]+'\x20-\x20'+_0x3c4b13[_0x25174a('0x24a9')]:'SYSTEM:GETmailAccount','msg':_0x3c4b13['data']?JSON[_0x25174a('0x258a')](_0x3c4b13[_0x25174a('0x5a5')][_0x25174a('0x8c2')]):_0x3c4b13[_0x25174a('0x8c2')]||_0x3c4b13[_0x25174a('0x1ff0')]()});});}function _0x597890(){const _0x1f7ff3=_0x451d26,_0x33c263=angular['copy'](_0x2c3857[_0x1f7ff3('0x288e')]);return _0x2c3857[_0x1f7ff3('0x288e')]=[],_0x33c263;}function _0x40138a(_0x5b677c){const _0xa901d9=_0x451d26,_0x28b2d1=_0x4d4d39['confirm']()[_0xa901d9('0xf28')](_0xa901d9('0x1cba'))['htmlContent'](''+_0x2c3857[_0xa901d9('0x288e')]['length']+_0xa901d9('0x93c')+_0xa901d9('0x1ee7'))[_0xa901d9('0x1040')](_0xa901d9('0xe27'))[_0xa901d9('0xe42')](_0x5b677c)['ok']('OK')[_0xa901d9('0x19fb')](_0xa901d9('0x16b8'));_0x4d4d39[_0xa901d9('0x1d4')](_0x28b2d1)[_0xa901d9('0x683')](function(){const _0x4b04d0=_0xa901d9;_0x2c3857[_0x4b04d0('0x288e')][_0x4b04d0('0x1299')](function(_0x54f94a){_0x24500f(_0x54f94a);}),_0x2c3857[_0x4b04d0('0x288e')]=[];});}function _0x4521ef(_0x1077d2){const _0x1b97dd=_0x451d26;if(!_0x2e3ca0()[_0x1b97dd('0x173f')](_0x1077d2['to'])&&!_0x2e3ca0()[_0x1b97dd('0x2292')](_0x1077d2['to'],_0x2c3857[_0x1b97dd('0xb87')][_0x1b97dd('0x1c92')]))_0x1077d2['contactName']=_0x1077d2['to'][_0x1b97dd('0x1fc5')]('\x20<')[0x0],_0x1077d2['contactInfo']=_0x1077d2['to']['split']('<')[_0x1b97dd('0x1d')]()[_0x1b97dd('0x1fc5')]('>')[0x0];else _0x1077d2[_0x1b97dd('0x1309')]?(_0x1077d2['contactName']=(_0x1077d2[_0x1b97dd('0x1309')][_0x1b97dd('0xeef')]||'')+'\x20'+(_0x1077d2[_0x1b97dd('0x1309')][_0x1b97dd('0x510')]||''),_0x1077d2[_0x1b97dd('0x22f9')]=_0x1077d2[_0x1b97dd('0x1309')][_0x1b97dd('0x1c92')]||''):_0x1077d2[_0x1b97dd('0x12b3')]=_0x45fa48[_0x1b97dd('0x2728')](_0x1b97dd('0x682'));}function _0x29faf6(_0x56ce66){const _0x8a28a7=_0x451d26;if(_0x56ce66[_0x8a28a7('0x10c5')])return _0x56ce66[_0x8a28a7('0x10c5')]===_0x2c3857[_0x8a28a7('0x11ed')]['id']?_0x45fa48['instant'](_0x8a28a7('0x96a')):_0x56ce66[_0x8a28a7('0x2464')][_0x8a28a7('0x11bc')]+'\x20<'+_0x56ce66[_0x8a28a7('0x2464')][_0x8a28a7('0x1d43')]+'>';return _0x45fa48[_0x8a28a7('0x2728')](_0x8a28a7('0x2608'));}let _0x5e9129=!![],_0x240f56=0x1;_0x31e7e6[_0x451d26('0x186d')](_0x451d26('0x229'),function(_0x57f17c,_0x59b1d4){const _0x4edb83=_0x451d26;_0x5e9129?_0x4f3e6e(function(){_0x5e9129=![];}):(!_0x59b1d4&&(_0x240f56=_0x2c3857[_0x4edb83('0x23a2')][_0x4edb83('0xdf8')]),_0x57f17c!==_0x59b1d4&&(_0x2c3857[_0x4edb83('0x23a2')][_0x4edb83('0xdf8')]=0x1),!_0x57f17c&&(_0x2c3857[_0x4edb83('0x23a2')]['page']=_0x240f56),_0x3bc396());});}const _0x464d54=_0x1d43fa,_0x17821d=_0x180212['p']+'src/js/modules/main/apps/mail/views/mailAccounts/edit/mailCannedAnswers/dialog.html/dialog.html';_0x166768[_0x189033('0x14be')]=[_0x189033('0x17e4'),'$scope',_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x166768(_0x22dfb8,_0x37c6ad,_0x4fead8,_0x398d08,_0x15f8d3,_0x559d53,_0x4d9255,_0x2ee416,_0x29dfd9,_0x1a8832,_0x37cd08){const _0x4df7d9=_0x189033,_0x289dfb=this;_0x289dfb[_0x4df7d9('0x11ed')]=_0x37cd08[_0x4df7d9('0x20b2')](),_0x289dfb[_0x4df7d9('0xb87')]={},_0x289dfb[_0x4df7d9('0xa8e')]={'count':0x0,'rows':[]},_0x289dfb[_0x4df7d9('0x409')]=[],_0x289dfb[_0x4df7d9('0x1134')],_0x289dfb[_0x4df7d9('0x23a2')]={'fields':_0x4df7d9('0x8ee'),'limit':0xa,'page':0x1},_0x289dfb[_0x4df7d9('0x12f3')]=_0x321b7e,_0x289dfb[_0x4df7d9('0x26eb')]=_0x2f9362,_0x289dfb[_0x4df7d9('0x53')]=_0x5bee79,_0x289dfb[_0x4df7d9('0xcca')]=_0x2ecac6,_0x289dfb['createOrEditMailAccountMailCannedAnswer']=_0x554fd6,_0x289dfb[_0x4df7d9('0x1b7b')]=_0x4159d9,_0x289dfb[_0x4df7d9('0x26ca')]=_0x3ade45,_0x289dfb[_0x4df7d9('0x27ed')]=_0x45ec7c;function _0x321b7e(_0x279ae2,_0x419759){const _0x22d3c8=_0x4df7d9;_0x289dfb[_0x22d3c8('0xb87')]=_0x279ae2,_0x289dfb[_0x22d3c8('0x1134')]=typeof _0x419759!=='undefined'?_0x419759:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x289dfb[_0x22d3c8('0x23a2')][_0x22d3c8('0x1cd')]=_0x289dfb['mailAccount']['id'],_0x289dfb[_0x22d3c8('0x23a2')]['id']=_0x289dfb[_0x22d3c8('0xb87')]['id'],_0x2ecac6();}function _0x2f9362(_0x1d361a,_0x427f46){const _0x4c562e=_0x4df7d9,_0x4829e3=_0x4d9255[_0x4c562e('0x1c6f')]()[_0x4c562e('0xf28')](_0x4c562e('0x1486'))['htmlContent'](_0x4c562e('0xed5')+(_0x1d361a['name']||_0x1d361a['id']&&_0x2e3ca0()[_0x4c562e('0x2711')](_0x4c562e('0x124'))+_0x1d361a['id']||_0x4c562e('0x10b'))+_0x4c562e('0x20f1')+_0x4c562e('0x1ee7'))[_0x4c562e('0x1040')](_0x4c562e('0xa7a'))[_0x4c562e('0xe42')](_0x427f46)['ok']('OK')[_0x4c562e('0x19fb')](_0x4c562e('0x16b8'));_0x4d9255[_0x4c562e('0x1d4')](_0x4829e3)[_0x4c562e('0x683')](function(){_0x3ade45(_0x1d361a);},function(){const _0x2d4fb5=_0x4c562e;console['log'](_0x2d4fb5('0x16b8'));});}function _0x5bee79(_0x39eacf){const _0x220127=_0x4df7d9;_0x289dfb[_0x220127('0xa8e')]=_0x39eacf||{'count':0x0,'rows':[]};}function _0x2ecac6(){const _0x347968=_0x4df7d9;_0x289dfb[_0x347968('0x23a2')][_0x347968('0x1cc8')]=(_0x289dfb[_0x347968('0x23a2')][_0x347968('0xdf8')]-0x1)*_0x289dfb['query'][_0x347968('0x6f0')],_0x289dfb[_0x347968('0x1883')]=_0x1a8832[_0x347968('0xb87')][_0x347968('0x87f')](_0x289dfb['query'],_0x5bee79)[_0x347968('0xe53')];}function _0x554fd6(_0x205402,_0x41a1c9){const _0xfcd5bd=_0x4df7d9;_0x4d9255['show']({'controller':'CreateOrEditMailCannedAnswerDialogController','controllerAs':'vm','templateUrl':_0x17821d,'parent':angular[_0xfcd5bd('0x1fcc')](_0x2ee416[_0xfcd5bd('0x18e5')]),'targetEvent':_0x205402,'clickOutsideToClose':!![],'locals':{'mailAccount':_0x289dfb['mailAccount'],'mailCannedAnswer':_0x41a1c9,'mailCannedAnswers':_0x289dfb['mailAccountMailCannedAnswers'][_0xfcd5bd('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x289dfb[_0xfcd5bd('0x1134')]}});}function _0x3ade45(_0x5bfafd){const _0x279c3b=_0x4df7d9;_0x1a8832[_0x279c3b('0x136c')]['delete']({'id':_0x5bfafd['id']})[_0x279c3b('0xe53')][_0x279c3b('0x683')](function(){const _0x9f8dff=_0x279c3b;_0x2e3ca0()[_0x9f8dff('0x3ec')](_0x289dfb['mailAccountMailCannedAnswers'][_0x9f8dff('0xf5d')],{'id':_0x5bfafd['id']}),_0x289dfb[_0x9f8dff('0xa8e')][_0x9f8dff('0x50d')]-=0x1,!_0x289dfb[_0x9f8dff('0xa8e')]['rows'][_0x9f8dff('0x1564')]&&_0x2ecac6(),_0x29dfd9['success']({'title':_0x9f8dff('0x1347'),'msg':_0x5bfafd[_0x9f8dff('0x60a')]?_0x5bfafd[_0x9f8dff('0x60a')]+_0x9f8dff('0x194d'):''});})['catch'](function(_0x3a5330){const _0x175812=_0x279c3b;if(_0x3a5330[_0x175812('0x5a5')]&&_0x3a5330[_0x175812('0x5a5')][_0x175812('0x17f')]&&_0x3a5330[_0x175812('0x5a5')][_0x175812('0x17f')]['length']){_0x289dfb[_0x175812('0x17f')]=_0x3a5330['data']['errors']||[{'message':_0x3a5330['toString'](),'type':_0x175812('0x160e')}];for(let _0x2031d6=0x0;_0x2031d6<_0x3a5330[_0x175812('0x5a5')][_0x175812('0x17f')][_0x175812('0x1564')];_0x2031d6++){_0x29dfd9[_0x175812('0x52a')]({'title':_0x3a5330['data'][_0x175812('0x17f')][_0x2031d6][_0x175812('0xcf0')],'msg':_0x3a5330['data'][_0x175812('0x17f')][_0x2031d6]['message']});}}else _0x29dfd9[_0x175812('0x52a')]({'title':_0x3a5330[_0x175812('0x13ee')]?_0x175812('0x2168')+_0x3a5330[_0x175812('0x13ee')]+_0x175812('0xbf6')+_0x3a5330['statusText']:'SYSTEM:GETmailAccount','msg':_0x3a5330[_0x175812('0x5a5')]?JSON['stringify'](_0x3a5330[_0x175812('0x5a5')][_0x175812('0x8c2')]):_0x3a5330[_0x175812('0x8c2')]||_0x3a5330['toString']()});});}function _0x4159d9(){const _0x243581=_0x4df7d9,_0x40c749=angular[_0x243581('0x1a86')](_0x289dfb[_0x243581('0x409')]);return _0x289dfb[_0x243581('0x409')]=[],_0x40c749;}function _0x45ec7c(_0x496c70){const _0x156049=_0x4df7d9,_0x19137b=_0x4d9255[_0x156049('0x1c6f')]()[_0x156049('0xf28')](_0x156049('0x359'))[_0x156049('0x26e3')](_0x156049('0xed5')+_0x289dfb['selectedMailAccountMailCannedAnswers'][_0x156049('0x1564')]+_0x156049('0x93c')+_0x156049('0x1ee7'))[_0x156049('0x1040')](_0x156049('0xaa9'))[_0x156049('0xe42')](_0x496c70)['ok']('OK')[_0x156049('0x19fb')]('CANCEL');_0x4d9255[_0x156049('0x1d4')](_0x19137b)[_0x156049('0x683')](function(){const _0x87434a=_0x156049;_0x289dfb[_0x87434a('0x409')][_0x87434a('0x1299')](function(_0x241a70){_0x3ade45(_0x241a70);}),_0x289dfb[_0x87434a('0x409')]=[];});}let _0xc5c1fc=!![],_0x198c7c=0x1;_0x37c6ad['$watch'](_0x4df7d9('0x229'),function(_0x4d578d,_0x208b5c){const _0x3e4a42=_0x4df7d9;_0xc5c1fc?_0x559d53(function(){_0xc5c1fc=![];}):(!_0x208b5c&&(_0x198c7c=_0x289dfb[_0x3e4a42('0x23a2')]['page']),_0x4d578d!==_0x208b5c&&(_0x289dfb[_0x3e4a42('0x23a2')][_0x3e4a42('0xdf8')]=0x1),!_0x4d578d&&(_0x289dfb['query'][_0x3e4a42('0xdf8')]=_0x198c7c),_0x2ecac6());});}const _0x55eefa=_0x166768;_0x535f6e[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x205f'),_0x189033('0x10b'),'api',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x535f6e(_0x3a6b00,_0x2630a0,_0x20f65d,_0x3d84ef,_0x2a9180,_0x300ad2,_0x445db8,_0x35b855,_0x415172,_0x1d82dd,_0x421757,_0x53432a,_0x3ea45a,_0x4bfe32){const _0x4c8b72=_0x189033,_0x259de7=this;_0x259de7[_0x4c8b72('0x11ed')]=_0x421757[_0x4c8b72('0x20b2')](),_0x259de7['errors']=[],_0x259de7[_0x4c8b72('0x260a')]=_0x3ea45a,_0x259de7[_0x4c8b72('0xace')]=_0x53432a,_0x259de7['crudPermissions']=_0x4bfe32,_0x259de7['hasModulePermissions']={},_0x259de7[_0x4c8b72('0x19b2')]=_0x259de7[_0x4c8b72('0x260a')]&&_0x259de7[_0x4c8b72('0x260a')][_0x4c8b72('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x259de7[_0x4c8b72('0xf28')]='MAIL.EDIT_MAILCANNEDANSWER',_0x259de7[_0x4c8b72('0x10b')]=angular['copy'](_0x415172),_0x259de7[_0x4c8b72('0x205f')]=_0x35b855,_0x259de7[_0x4c8b72('0x23cc')]=![];!_0x259de7[_0x4c8b72('0x10b')]&&(_0x259de7[_0x4c8b72('0x10b')]={},_0x259de7[_0x4c8b72('0xf28')]=_0x4c8b72('0x27e6'),_0x259de7[_0x4c8b72('0x23cc')]=!![]);_0x2630a0[_0x4c8b72('0x7f2')]['id']&&(_0x259de7[_0x4c8b72('0x10b')][_0x4c8b72('0x1cd')]=_0x2630a0[_0x4c8b72('0x7f2')]['id']);_0x259de7[_0x4c8b72('0x26f3')]=_0x512a6d,_0x259de7[_0x4c8b72('0x17df')]=_0x4a118b,_0x259de7[_0x4c8b72('0x137')]=_0x5cbeb2,_0x259de7['getDateFromString']=_0x4dca64,_0x259de7[_0x4c8b72('0xf82')]=_0x549bb9;function _0x512a6d(){const _0x14b799=_0x4c8b72;_0x259de7[_0x14b799('0x17f')]=[],_0x1d82dd[_0x14b799('0x136c')]['save'](_0x259de7[_0x14b799('0x10b')])['$promise']['then'](function(_0x3b4319){const _0xe5224a=_0x14b799;_0x259de7['mailCannedAnswers'][_0xe5224a('0x1167')](_0x3b4319[_0xe5224a('0x24e1')]()),_0x445db8[_0xe5224a('0x53')]({'title':_0xe5224a('0x18d5'),'msg':_0x259de7[_0xe5224a('0x10b')][_0xe5224a('0x60a')]?_0x259de7[_0xe5224a('0x10b')][_0xe5224a('0x60a')]+_0xe5224a('0x14b5'):''}),_0x549bb9(_0x3b4319);})[_0x14b799('0x130a')](function(_0x448ee4){const _0x38094b=_0x14b799;if(_0x448ee4[_0x38094b('0x5a5')]&&_0x448ee4['data'][_0x38094b('0x17f')]&&_0x448ee4[_0x38094b('0x5a5')][_0x38094b('0x17f')][_0x38094b('0x1564')]){_0x259de7[_0x38094b('0x17f')]=_0x448ee4['data']['errors']||[{'message':_0x448ee4['toString'](),'type':_0x38094b('0x267b')}];for(let _0x271113=0x0;_0x271113<_0x448ee4[_0x38094b('0x5a5')][_0x38094b('0x17f')]['length'];_0x271113+=0x1){_0x445db8[_0x38094b('0x52a')]({'title':_0x448ee4[_0x38094b('0x5a5')]['errors'][_0x271113][_0x38094b('0xcf0')],'msg':_0x448ee4[_0x38094b('0x5a5')][_0x38094b('0x17f')][_0x271113][_0x38094b('0x8c2')]});}}else _0x445db8[_0x38094b('0x52a')]({'title':_0x448ee4[_0x38094b('0x13ee')]?_0x38094b('0x2168')+_0x448ee4[_0x38094b('0x13ee')]+'\x20-\x20'+_0x448ee4[_0x38094b('0x24a9')]:_0x38094b('0x267b'),'msg':_0x448ee4[_0x38094b('0x5a5')]?JSON[_0x38094b('0x258a')](_0x448ee4[_0x38094b('0x5a5')][_0x38094b('0x8c2')]):_0x448ee4[_0x38094b('0x1ff0')]()});});}function _0x4a118b(){const _0x14d592=_0x4c8b72;_0x259de7[_0x14d592('0x17f')]=[],_0x1d82dd[_0x14d592('0x136c')][_0x14d592('0x2480')]({'id':_0x259de7[_0x14d592('0x10b')]['id']},_0x259de7[_0x14d592('0x10b')])[_0x14d592('0xe53')]['then'](function(_0x18bb14){const _0x378a62=_0x14d592,_0x1e8ff5=_0x2e3ca0()['find'](_0x259de7['mailCannedAnswers'],{'id':_0x18bb14['id']});_0x1e8ff5&&_0x2e3ca0()[_0x378a62('0xf22')](_0x1e8ff5,_0x2e3ca0()[_0x378a62('0x24d0')](_0x18bb14['toJSON'](),_0x2e3ca0()[_0x378a62('0x55e')](_0x1e8ff5))),_0x445db8[_0x378a62('0x53')]({'title':_0x378a62('0x1135'),'msg':_0x259de7[_0x378a62('0x10b')][_0x378a62('0x60a')]?_0x259de7[_0x378a62('0x10b')][_0x378a62('0x60a')]+_0x378a62('0xf59'):''}),_0x549bb9(_0x18bb14);})[_0x14d592('0x130a')](function(_0x190c09){const _0x1b3c23=_0x14d592;if(_0x190c09['data']&&_0x190c09[_0x1b3c23('0x5a5')][_0x1b3c23('0x17f')]&&_0x190c09['data'][_0x1b3c23('0x17f')][_0x1b3c23('0x1564')]){_0x259de7[_0x1b3c23('0x17f')]=_0x190c09[_0x1b3c23('0x5a5')][_0x1b3c23('0x17f')]||[{'message':_0x190c09[_0x1b3c23('0x1ff0')](),'type':_0x1b3c23('0x1301')}];for(let _0x5918d0=0x0;_0x5918d0<_0x190c09[_0x1b3c23('0x5a5')][_0x1b3c23('0x17f')][_0x1b3c23('0x1564')];_0x5918d0++){_0x445db8['error']({'title':_0x190c09[_0x1b3c23('0x5a5')]['errors'][_0x5918d0][_0x1b3c23('0xcf0')],'msg':_0x190c09[_0x1b3c23('0x5a5')][_0x1b3c23('0x17f')][_0x5918d0]['message']});}}else _0x445db8[_0x1b3c23('0x52a')]({'title':_0x190c09[_0x1b3c23('0x13ee')]?_0x1b3c23('0x2168')+_0x190c09[_0x1b3c23('0x13ee')]+'\x20-\x20'+_0x190c09[_0x1b3c23('0x24a9')]:_0x1b3c23('0x1301'),'msg':_0x190c09[_0x1b3c23('0x5a5')]?JSON[_0x1b3c23('0x258a')](_0x190c09['data'][_0x1b3c23('0x8c2')]):_0x190c09[_0x1b3c23('0x1ff0')]()});});}function _0x5cbeb2(_0x2a7c4e){const _0xc5424a=_0x4c8b72;_0x259de7[_0xc5424a('0x17f')]=[];const _0x1334ab=_0x3d84ef[_0xc5424a('0x1c6f')]()[_0xc5424a('0xf28')](_0xc5424a('0x4d'))[_0xc5424a('0xa6a')](_0xc5424a('0x2627'))[_0xc5424a('0x1040')](_0xc5424a('0xc0b'))['ok'](_0xc5424a('0x2307'))['cancel'](_0xc5424a('0x253a'))[_0xc5424a('0xe42')](_0x2a7c4e);_0x3d84ef[_0xc5424a('0x1d4')](_0x1334ab)[_0xc5424a('0x683')](function(){const _0x5d1cde=_0xc5424a;_0x1d82dd[_0x5d1cde('0x136c')][_0x5d1cde('0xd7e')]({'id':_0x259de7[_0x5d1cde('0x10b')]['id']})[_0x5d1cde('0xe53')][_0x5d1cde('0x683')](function(){const _0x48d104=_0x5d1cde;_0x2e3ca0()[_0x48d104('0x3ec')](_0x259de7['mailCannedAnswers'],{'id':_0x259de7['mailCannedAnswer']['id']}),_0x445db8['success']({'title':_0x48d104('0x2181'),'msg':(_0x259de7['mailCannedAnswer'][_0x48d104('0x60a')]||'mailCannedAnswer')+'\x20has\x20been\x20deleted!'}),_0x549bb9(_0x259de7['mailCannedAnswer']);})[_0x5d1cde('0x130a')](function(_0x2e9f9a){const _0x1c23cd=_0x5d1cde;if(_0x2e9f9a[_0x1c23cd('0x5a5')]&&_0x2e9f9a[_0x1c23cd('0x5a5')][_0x1c23cd('0x17f')]&&_0x2e9f9a[_0x1c23cd('0x5a5')][_0x1c23cd('0x17f')][_0x1c23cd('0x1564')]){_0x259de7[_0x1c23cd('0x17f')]=_0x2e9f9a[_0x1c23cd('0x5a5')]['errors']||[{'message':_0x2e9f9a[_0x1c23cd('0x1ff0')](),'type':'api.cannedAnswer.delete'}];for(let _0x135161=0x0;_0x135161<_0x2e9f9a[_0x1c23cd('0x5a5')][_0x1c23cd('0x17f')]['length'];_0x135161++){_0x445db8[_0x1c23cd('0x52a')]({'title':_0x2e9f9a[_0x1c23cd('0x5a5')][_0x1c23cd('0x17f')][_0x135161]['type'],'msg':_0x2e9f9a[_0x1c23cd('0x5a5')]['errors'][_0x135161][_0x1c23cd('0x8c2')]});}}else _0x445db8[_0x1c23cd('0x52a')]({'title':_0x2e9f9a[_0x1c23cd('0x13ee')]?_0x1c23cd('0x2168')+_0x2e9f9a[_0x1c23cd('0x13ee')]+_0x1c23cd('0xbf6')+_0x2e9f9a[_0x1c23cd('0x24a9')]:_0x1c23cd('0x253e'),'msg':_0x2e9f9a[_0x1c23cd('0x5a5')]?JSON[_0x1c23cd('0x258a')](_0x2e9f9a['data'][_0x1c23cd('0x8c2')]):_0x2e9f9a[_0x1c23cd('0x8c2')]||_0x2e9f9a[_0x1c23cd('0x1ff0')]()});});},function(){});}function _0x4dca64(_0x486eba){return _0x486eba===null?undefined:new Date(_0x486eba);}function _0x549bb9(_0x4e7d73){const _0x504c62=_0x4c8b72;_0x3d84ef[_0x504c62('0x1715')](_0x4e7d73);}}const _0x461b38=_0x535f6e;_0x226a07[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),_0x189033('0x1d08'),'api',_0x189033('0x1d70'),'Auth'];function _0x226a07(_0x155933,_0x892327,_0x188667,_0xd6f291,_0x37ed3f,_0x4662ff,_0xeaec42,_0x266b80,_0x2b6c72,_0x11dc14,_0x1c061c){const _0x3f23ef=_0x189033,_0x39de96=this;_0x39de96['currentUser']=_0x1c061c[_0x3f23ef('0x20b2')](),_0x39de96[_0x3f23ef('0x191e')]={'count':0x0,'rows':[]},_0x39de96[_0x3f23ef('0x17')]=[],_0x39de96[_0x3f23ef('0x1134')],_0x39de96[_0x3f23ef('0x1d01')]={'first':'1st','second':'2nd','third':_0x3f23ef('0x10ce')},_0x39de96[_0x3f23ef('0x23a2')]={'fields':'id,level,name,description,ParentId,createdAt,updatedAt','sort':_0x3f23ef('0xc36'),'limit':0xa,'page':0x1},_0x39de96[_0x3f23ef('0x12f3')]=_0x4ca8e2,_0x39de96[_0x3f23ef('0x26eb')]=_0x404a9a,_0x39de96[_0x3f23ef('0x53')]=_0x2afe3a,_0x39de96['getDispositions']=_0x45ad29,_0x39de96[_0x3f23ef('0xe69')]=_0x27c058,_0x39de96[_0x3f23ef('0x207b')]=_0x51c298,_0x39de96[_0x3f23ef('0x224b')]=_0x4411db,_0x39de96[_0x3f23ef('0x238e')]=_0x531038,_0x39de96['deselectDispositions']=_0x41a4c5,_0x39de96[_0x3f23ef('0x1801')]=_0x5923ba;function _0x4ca8e2(_0x38fcd8,_0x5ffb12){const _0x3d8a34=_0x3f23ef;_0x39de96[_0x3d8a34('0xb87')]=_0x38fcd8||{},_0x39de96[_0x3d8a34('0x1134')]=typeof _0x5ffb12!==_0x3d8a34('0x1867')?_0x5ffb12:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x39de96[_0x3d8a34('0x23a2')][_0x3d8a34('0x1cd')]=_0x39de96[_0x3d8a34('0xb87')]['id'],_0x39de96[_0x3d8a34('0x23a2')]['id']=_0x39de96['mailAccount']['id'],_0x45ad29();}function _0x27c058(_0x4fa698,_0x11173c){const _0x43705c=_0x3f23ef;_0x37ed3f[_0x43705c('0x1d4')]({'controller':_0x43705c('0x1ecc'),'controllerAs':'vm','templateUrl':_0x32807f,'parent':angular['element'](_0x4662ff['body']),'targetEvent':_0x4fa698,'clickOutsideToClose':!![],'locals':{'disposition':_0x11173c,'dispositions':_0x39de96[_0x43705c('0x191e')][_0x43705c('0xf5d')],'model':{'id':_0x39de96['mailAccount']['id'],'field':_0x43705c('0x1cd')},'license':null,'setting':null,'crudPermissions':_0x39de96[_0x43705c('0x1134')]}})[_0x43705c('0x683')](function(_0x273190){if(_0x273190)_0x45ad29();});}function _0x404a9a(_0x201cb8,_0x6cf2cc){const _0x90927c=_0x3f23ef,_0x9acda7=_0x2e3ca0()[_0x90927c('0x7a2')](_0x39de96['dispositions'][_0x90927c('0xf5d')],[_0x90927c('0x1b62'),_0x201cb8['id']]),_0x1d96d7=_0x37ed3f['confirm']()[_0x90927c('0xf28')](_0x266b80['instant'](_0x90927c('0x15d8')))[_0x90927c('0xa6a')](_0x266b80[_0x90927c('0x2728')](_0x90927c('0x13bf')+(_0x9acda7?_0x90927c('0x2235'):_0x90927c('0x106')),{'name':_0x201cb8['name']}))[_0x90927c('0x1040')]('Delete\x20disposition')[_0x90927c('0xe42')](_0x6cf2cc)['ok']('OK')[_0x90927c('0x19fb')](_0x266b80[_0x90927c('0x2728')]('TOOLS.CANCEL'));_0x37ed3f['show'](_0x1d96d7)[_0x90927c('0x683')](function(){_0x51c298(_0x201cb8);});}function _0x2afe3a(_0x1caa0b){const _0x148007=_0x3f23ef;_0x39de96[_0x148007('0x191e')]=_0x1caa0b||{'count':0x0,'rows':[]};}function _0x45ad29(){const _0x40fb16=_0x3f23ef;_0x39de96[_0x40fb16('0x23a2')][_0x40fb16('0x1cc8')]=(_0x39de96[_0x40fb16('0x23a2')][_0x40fb16('0xdf8')]-0x1)*_0x39de96[_0x40fb16('0x23a2')][_0x40fb16('0x6f0')],_0x39de96[_0x40fb16('0x1883')]=_0x2b6c72[_0x40fb16('0xb87')]['getDispositions'](_0x39de96[_0x40fb16('0x23a2')],_0x2afe3a)['$promise'];}function _0x51c298(_0x5c757c){const _0x31f549=_0x3f23ef;_0x2b6c72[_0x31f549('0x43f')][_0x31f549('0xd7e')]({'id':_0x5c757c['id']})[_0x31f549('0xe53')]['then'](function(){const _0x473c4a=_0x31f549;_0x45ad29(),_0x11dc14[_0x473c4a('0x53')]({'title':_0x266b80[_0x473c4a('0x2728')](_0x473c4a('0x210b'))});})[_0x31f549('0x130a')](function(_0x1df19d){const _0x47c1f6=_0x31f549;if(_0x1df19d[_0x47c1f6('0x5a5')]&&_0x1df19d[_0x47c1f6('0x5a5')][_0x47c1f6('0x17f')]&&_0x1df19d['data'][_0x47c1f6('0x17f')][_0x47c1f6('0x1564')]){_0x39de96[_0x47c1f6('0x17f')]=_0x1df19d['data'][_0x47c1f6('0x17f')]||[{'message':_0x1df19d['toString'](),'type':'SYSTEM:DELETEdisposition'}];for(let _0x4c7225=0x0;_0x4c7225<_0x1df19d[_0x47c1f6('0x5a5')]['errors'][_0x47c1f6('0x1564')];_0x4c7225++){_0x11dc14['error']({'title':_0x1df19d['data'][_0x47c1f6('0x17f')][_0x4c7225][_0x47c1f6('0xcf0')],'msg':_0x1df19d[_0x47c1f6('0x5a5')][_0x47c1f6('0x17f')][_0x4c7225][_0x47c1f6('0x8c2')]});}}else _0x11dc14[_0x47c1f6('0x52a')]({'title':_0x1df19d[_0x47c1f6('0x13ee')]?_0x47c1f6('0x2168')+_0x1df19d['status']+_0x47c1f6('0xbf6')+_0x1df19d[_0x47c1f6('0x24a9')]:_0x47c1f6('0x189b'),'msg':_0x1df19d[_0x47c1f6('0x5a5')]?JSON[_0x47c1f6('0x258a')](_0x1df19d[_0x47c1f6('0x5a5')]['message']):_0x1df19d['message']||_0x1df19d['toString']()});});}function _0x4411db(){const _0x268c44=_0x3f23ef,_0x21c796=angular[_0x268c44('0x1a86')](_0x39de96['selectedDispositions']);return _0x39de96[_0x268c44('0x17')]=[],_0x21c796;}function _0x531038(_0x38fc6c){const _0x28714b=_0x3f23ef,_0xf9af8a=_0x37ed3f[_0x28714b('0x1c6f')]()['title'](_0x266b80[_0x28714b('0x2728')](_0x28714b('0xfa')))[_0x28714b('0xa6a')](_0x266b80[_0x28714b('0x2728')](_0x28714b('0x1ebe'),{'total':_0x39de96[_0x28714b('0x17')][_0x28714b('0x1564')]}))['ariaLabel'](_0x28714b('0xb49'))[_0x28714b('0xe42')](_0x38fc6c)['ok']('OK')[_0x28714b('0x19fb')](_0x266b80['instant'](_0x28714b('0x9a1')));_0x37ed3f[_0x28714b('0x1d4')](_0xf9af8a)[_0x28714b('0x683')](function(){const _0x2adcdf=_0x28714b;_0x39de96[_0x2adcdf('0x17')][_0x2adcdf('0x1299')](function(_0x3e528b){_0x51c298(_0x3e528b);}),_0x39de96[_0x2adcdf('0x17')]=[];});}function _0x41a4c5(){const _0x209da5=_0x3f23ef;_0x39de96[_0x209da5('0x17')]=[];}function _0x5923ba(){const _0x5f4cfc=_0x3f23ef;_0x39de96['selectedDispositions']=_0x39de96[_0x5f4cfc('0x191e')][_0x5f4cfc('0xf5d')];}let _0x446a00=!![],_0xe6626d=0x1;_0x155933[_0x3f23ef('0x186d')](_0x3f23ef('0x229'),function(_0x46f2c8,_0x14c4a0){const _0x1cfcad=_0x3f23ef;_0x446a00?_0xeaec42(function(){_0x446a00=![];}):(!_0x14c4a0&&(_0xe6626d=_0x39de96['query'][_0x1cfcad('0xdf8')]),_0x46f2c8!==_0x14c4a0&&(_0x39de96[_0x1cfcad('0x23a2')][_0x1cfcad('0xdf8')]=0x1),!_0x46f2c8&&(_0x39de96[_0x1cfcad('0x23a2')][_0x1cfcad('0xdf8')]=_0xe6626d),_0x45ad29());});}const _0xfde873=_0x226a07,_0x5dd3c0=_0x180212['p']+_0x189033('0x2537');_0x499447[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d08'),'license',_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xb87'),_0x189033('0x22df')];function _0x499447(_0xb5c00f,_0x49a8a7,_0x274500,_0x3ae244,_0x3710c0,_0x4aabea,_0x102aee,_0x4f8c89,_0x317b1a,_0x34c4ec,_0x3cc8b8,_0x432daa){const _0x515989=_0x189033,_0x4b60bb=this;_0x4b60bb['currentUser']=_0x34c4ec[_0x515989('0x20b2')](),_0x4b60bb['license']=_0x4aabea,_0x4b60bb[_0x515989('0x260a')]=_0x102aee,_0x4b60bb[_0x515989('0x19b2')]=_0x4b60bb[_0x515989('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4b60bb[_0x515989('0x1224')]=_0x49a8a7['protocol']()+_0x515989('0x20de')+_0x49a8a7[_0x515989('0x19ac')](),_0x4b60bb[_0x515989('0xb87')]=_0x3cc8b8||_0xb5c00f[_0x515989('0x7f2')]['mailAccount']||{},_0x4b60bb['userProfileSection']=_0x432daa&&_0x432daa[_0x515989('0x50d')]==0x1?_0x432daa[_0x515989('0xf5d')][0x0]:null,_0x4b60bb[_0x515989('0x1134')]=_0x34c4ec[_0x515989('0x142a')](_0x4b60bb['userProfileSection']?_0x4b60bb[_0x515989('0x22df')][_0x515989('0x1134')]:null),_0x4b60bb['hasModulePermissions']={},_0x4b60bb[_0x515989('0x517')]=_0xb5c00f[_0x515989('0x7f2')][_0x515989('0x1904')]||0x0,_0x4b60bb[_0x515989('0x1a9f')]=_0x4128c9,_0x4b60bb[_0x515989('0x2814')]=_0x10e49c,_0x4b60bb[_0x515989('0x2430')]=_0x317b1a['info'],_0x4b60bb[_0x515989('0x212a')]=_0x1a0535,_0x4b60bb[_0x515989('0x6b4')]=_0xbf462e,_0x34c4ec[_0x515989('0xca1')](_0x515989('0x20c2'))?_0x4f8c89[_0x515989('0x259b')][_0x515989('0x1e6e')]({'fields':_0x515989('0xa10'),'sort':_0x515989('0x60a')})['$promise']['then'](function(_0x26b692){const _0x2af71c=_0x515989;_0x4b60bb[_0x2af71c('0xe01')]=_0x26b692['rows']||[];})[_0x515989('0x130a')](function(_0x3530c2){const _0x172f28=_0x515989;_0x317b1a['error']({'title':_0x3530c2[_0x172f28('0x13ee')]?'API:'+_0x3530c2[_0x172f28('0x13ee')]+_0x172f28('0xbf6')+_0x3530c2[_0x172f28('0x24a9')]:_0x172f28('0x251b'),'msg':_0x3530c2[_0x172f28('0x5a5')]?JSON['stringify'](_0x3530c2[_0x172f28('0x5a5')]):_0x3530c2[_0x172f28('0x1ff0')]()});}):_0x4f8c89['cmList']['get']({'fields':_0x515989('0xa10'),'sort':_0x515989('0x60a')})['$promise']['then'](function(_0x2a829a){const _0x33b7c1=_0x515989;_0x4b60bb[_0x33b7c1('0xe01')]=_0x2a829a[_0x33b7c1('0xf5d')]||[];})['then'](function(){const _0x38484d=_0x515989;return _0x4f8c89[_0x38484d('0x22df')]['get']({'userProfileId':_0x4b60bb[_0x38484d('0x11ed')]['userProfileId'],'sectionId':0x12d})[_0x38484d('0xe53')];})[_0x515989('0x683')](function(_0x5ef036){const _0x43c04e=_0x515989,_0x5cf354=_0x5ef036&&_0x5ef036[_0x43c04e('0xf5d')]?_0x5ef036[_0x43c04e('0xf5d')][0x0]:null;if(!_0x5cf354){const _0x3f3edc=[];let _0x30a307=null;_0x4b60bb['mailAccount']&&(_0x30a307=_0x2e3ca0()[_0x43c04e('0x1c07')](_0x4b60bb[_0x43c04e('0xe01')],{'id':Number(_0x4b60bb[_0x43c04e('0xb87')][_0x43c04e('0x1e4f')])}));for(let _0x31f902=0x0;_0x31f902<_0x4b60bb[_0x43c04e('0xe01')][_0x43c04e('0x1564')];_0x31f902++){_0x30a307&&_0x4b60bb[_0x43c04e('0xe01')][_0x31f902]['id']===_0x30a307['id']&&(_0x4b60bb[_0x43c04e('0xe01')][_0x31f902]['canSelect']=![],_0x3f3edc['push'](_0x4b60bb['lists'][_0x31f902]));}_0x4b60bb[_0x43c04e('0xe01')]=_0x3f3edc;}else{if(!_0x5cf354[_0x43c04e('0x170')])return _0x4f8c89[_0x43c04e('0xcf7')][_0x43c04e('0x1e6e')]({'sectionId':_0x5cf354['id']})[_0x43c04e('0xe53')][_0x43c04e('0x683')](function(_0x16459b){const _0x424db2=_0x43c04e,_0x767a4=_0x2e3ca0()[_0x424db2('0x386')](_0x16459b['rows'],function(_0x4be3c9){const _0x1620b6=_0x424db2;return _0x2e3ca0()[_0x1620b6('0x1c07')](_0x4b60bb[_0x1620b6('0xe01')],{'id':_0x4be3c9['resourceId']});});let _0x59c73f=null;_0x4b60bb['mailAccount']&&(_0x59c73f=_0x2e3ca0()[_0x424db2('0x1c07')](_0x4b60bb['lists'],{'id':Number(_0x4b60bb[_0x424db2('0xb87')]['ListId'])}));if(_0x59c73f&&!_0x2e3ca0()[_0x424db2('0x7a2')](_0x767a4,['id',_0x59c73f['id']])){const _0x52075a=_0x2e3ca0()[_0x424db2('0x1c07')](_0x4b60bb[_0x424db2('0xe01')],{'id':_0x59c73f['id']});_0x52075a[_0x424db2('0x319')]=![],_0x767a4[_0x424db2('0x1fd0')](_0x52075a);}_0x4b60bb[_0x424db2('0xe01')]=_0x767a4;});}})[_0x515989('0x130a')](function(_0x5c2c30){const _0x405867=_0x515989;_0x317b1a[_0x405867('0x52a')]({'title':_0x5c2c30['status']?_0x405867('0x2168')+_0x5c2c30[_0x405867('0x13ee')]+_0x405867('0xbf6')+_0x5c2c30[_0x405867('0x24a9')]:'SYSTEM:GETlists','msg':_0x5c2c30[_0x405867('0x5a5')]?JSON[_0x405867('0x258a')](_0x5c2c30[_0x405867('0x5a5')]):_0x5c2c30[_0x405867('0x1ff0')]()});}),_0x34c4ec['hasRole'](_0x515989('0x20c2'))?_0x4f8c89[_0x515989('0xa4')][_0x515989('0x1e6e')]({'fields':_0x515989('0x1688'),'sort':'name','nolimit':_0x515989('0x26ac')})[_0x515989('0xe53')][_0x515989('0x683')](function(_0x118d82){const _0x565652=_0x515989;_0x4b60bb[_0x565652('0x22ab')]=_0x118d82['rows']||[];})[_0x515989('0x130a')](function(_0x141884){const _0xcfb53=_0x515989;_0x317b1a[_0xcfb53('0x52a')]({'title':_0x141884[_0xcfb53('0x13ee')]?_0xcfb53('0x2168')+_0x141884[_0xcfb53('0x13ee')]+_0xcfb53('0xbf6')+_0x141884['statusText']:_0xcfb53('0x4ba'),'msg':_0x141884['data']?JSON[_0xcfb53('0x258a')](_0x141884[_0xcfb53('0x5a5')]):_0x141884[_0xcfb53('0x1ff0')]()});}):_0x4f8c89[_0x515989('0xa4')][_0x515989('0x1e6e')]({'fields':'name,id','sort':'name','nolimit':_0x515989('0x26ac')})[_0x515989('0xe53')][_0x515989('0x683')](function(_0x1fa61f){const _0x59f93e=_0x515989;_0x4b60bb[_0x59f93e('0x22ab')]=_0x1fa61f[_0x59f93e('0xf5d')]||[];})[_0x515989('0x683')](function(){const _0x48c17f=_0x515989;return _0x4f8c89['userProfileSection']['get']({'userProfileId':_0x4b60bb[_0x48c17f('0x11ed')][_0x48c17f('0x2f')],'sectionId':0x3ed})[_0x48c17f('0xe53')];})[_0x515989('0x683')](function(_0x134180){const _0x405374=_0x515989,_0x1143ad=_0x134180&&_0x134180[_0x405374('0xf5d')]?_0x134180[_0x405374('0xf5d')][0x0]:null;if(!_0x1143ad)_0x4b60bb['pauses']=[];else{if(!_0x1143ad[_0x405374('0x170')])return _0x4f8c89['userProfileResource'][_0x405374('0x1e6e')]({'sectionId':_0x1143ad['id']})[_0x405374('0xe53')][_0x405374('0x683')](function(_0x334052){const _0x548cce=_0x405374,_0x44d0c2=_0x2e3ca0()[_0x548cce('0x386')](_0x334052['rows'],function(_0x2bb93a){const _0x288b82=_0x548cce;return _0x2e3ca0()['find'](_0x4b60bb[_0x288b82('0x22ab')],{'id':_0x2bb93a[_0x288b82('0x832')]});});_0x4b60bb[_0x548cce('0x22ab')][_0x548cce('0x1299')](function(_0x1d6f82){!_0x2e3ca0()['some'](_0x44d0c2,['id',_0x1d6f82['id']])&&(_0x1d6f82['canSelect']=![]),_0x44d0c2['push'](_0x1d6f82);}),_0x4b60bb['pauses']=_0x44d0c2;});}})[_0x515989('0x130a')](function(_0x584a65){const _0x1339cd=_0x515989;_0x317b1a[_0x1339cd('0x52a')]({'title':_0x584a65[_0x1339cd('0x13ee')]?_0x1339cd('0x2168')+_0x584a65['status']+_0x1339cd('0xbf6')+_0x584a65[_0x1339cd('0x24a9')]:'SYSTEM:GETpauses','msg':_0x584a65['data']?JSON[_0x1339cd('0x258a')](_0x584a65[_0x1339cd('0x5a5')]):_0x584a65[_0x1339cd('0x1ff0')]()});});function _0x4128c9(){const _0x1591ed=_0x515989;if(_0x34c4ec[_0x1591ed('0xca1')](_0x1591ed('0x20c2')))_0xb5c00f['go']('app.mail.realtime.accounts',{});else return _0x4f8c89[_0x1591ed('0x22df')]['get']({'userProfileId':_0x34c4ec['getCurrentUser']()['userProfileId'],'sectionId':0x262})['$promise']['then'](function(_0x1fabd9){const _0xed9f97=_0x1591ed,_0x318d37=_0x1fabd9&&_0x1fabd9[_0xed9f97('0xf5d')]?_0x1fabd9[_0xed9f97('0xf5d')][0x0]:null;_0x318d37&&_0x318d37['enabled']?_0xb5c00f['go'](_0xed9f97('0x1000'),{}):_0x317b1a[_0xed9f97('0x2289')]({'title':_0x3710c0[_0xed9f97('0x2728')](_0xed9f97('0x213e')),'msg':_0x3710c0[_0xed9f97('0x2728')](_0xed9f97('0xdba'))});})[_0x1591ed('0x130a')](function(_0x11257b){const _0x2255f2=_0x1591ed;_0x317b1a[_0x2255f2('0x52a')]({'title':_0x11257b[_0x2255f2('0x13ee')]?_0x2255f2('0x2168')+_0x11257b['status']+_0x2255f2('0xbf6')+_0x11257b['statusText']:_0x2255f2('0xf2a'),'msg':_0x11257b[_0x2255f2('0x13ee')]?JSON[_0x2255f2('0x258a')](_0x11257b[_0x2255f2('0x5a5')]):_0x11257b['toString']()});});}function _0x10e49c(_0x45182f,_0xab2c82){const _0xf1e1e2=_0x515989;_0x274500[_0xf1e1e2('0x1d4')]({'controller':_0xf1e1e2('0x159d'),'controllerAs':'vm','templateUrl':_0x5dd3c0,'parent':angular[_0xf1e1e2('0x1fcc')](_0x3ae244[_0xf1e1e2('0x18e5')]),'targetEvent':_0xab2c82,'clickOutsideToClose':!![],'locals':{'mailAccount':_0x45182f,'mailAccounts':_0x4b60bb[_0xf1e1e2('0x1093')]?_0x4b60bb['mailAccounts'][_0xf1e1e2('0xf5d')]:[],'crudPermissions':_0x4b60bb[_0xf1e1e2('0x1134')],'realtime':![]}});}function _0x1a0535(){const _0x4c2736=_0x515989;_0xb5c00f['go'](_0x4c2736('0x1b93'),{},{'reload':_0x4c2736('0x1b93')});}function _0xbf462e(){const _0x939edc=_0x515989;_0x4f8c89[_0x939edc('0xb87')][_0x939edc('0x2480')]({'id':_0x4b60bb[_0x939edc('0xb87')]['id']},_0x4b60bb[_0x939edc('0xb87')])[_0x939edc('0xe53')][_0x939edc('0x683')](function(){const _0x196465=_0x939edc;_0x317b1a[_0x196465('0x53')]({'title':_0x196465('0x1b73'),'msg':_0x4b60bb[_0x196465('0xb87')]['name']?_0x4b60bb[_0x196465('0xb87')][_0x196465('0x60a')]+_0x196465('0x96c'):''});})[_0x939edc('0x130a')](function(_0x19e4aa){const _0xf6e34d=_0x939edc;_0x317b1a['error']({'title':_0x19e4aa[_0xf6e34d('0x13ee')]?_0xf6e34d('0x2168')+_0x19e4aa[_0xf6e34d('0x13ee')]+_0xf6e34d('0xbf6')+_0x19e4aa[_0xf6e34d('0x24a9')]:_0xf6e34d('0x160e'),'msg':_0x19e4aa[_0xf6e34d('0x5a5')]?JSON[_0xf6e34d('0x258a')](_0x19e4aa[_0xf6e34d('0x5a5')]):_0x19e4aa['toString']()});});}}const _0x1f49c9=_0x499447,_0x22cfef=_0x180212['p']+_0x189033('0x604');_0x4bcd08['$inject']=[_0x189033('0x7a5'),'$window',_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x1093'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),'license','setting'];function _0x4bcd08(_0x5acf17,_0x118f46,_0x27f9b8,_0x4bf8c5,_0x3a36b4,_0x4237b9,_0x293d92,_0x1c71ed,_0x73e2cb,_0x10761a,_0x1939af,_0x51e80d,_0x3ebb6d,_0x2bc714,_0x2a39e1,_0x35bd31,_0x2e1199){const _0x3be683=_0x189033,_0x356801=this;_0x356801['license']=_0x35bd31,_0x356801[_0x3be683('0x260a')]=_0x2e1199,_0x356801[_0x3be683('0x11ed')]=_0x2a39e1['getCurrentUser'](),_0x356801[_0x3be683('0x1093')]=_0x73e2cb||{'count':0x0,'rows':[]},_0x356801[_0x3be683('0x2a')]=_0x10761a,_0x356801[_0x3be683('0x22df')]=_0x1939af&&_0x1939af[_0x3be683('0x50d')]==0x1?_0x1939af['rows'][0x0]:null,_0x356801['crudPermissions']=_0x2a39e1[_0x3be683('0x142a')](_0x356801[_0x3be683('0x22df')]?_0x356801[_0x3be683('0x22df')][_0x3be683('0x1134')]:null),_0x356801[_0x3be683('0x5c4')]='mailAccounts',_0x356801[_0x3be683('0x247')]='',_0x356801[_0x3be683('0x1ce2')]=null,_0x356801[_0x3be683('0x68f')]=[],_0x356801[_0x3be683('0x23a2')]={'fields':_0x3be683('0x7ed'),'sort':_0x3be683('0xc36'),'limit':0xa,'page':0x1},_0x356801[_0x3be683('0x2629')]=_0x2e3ca0()[_0x3be683('0x24db')]([{'option':_0x3be683('0x1fcf'),'value':_0x3be683('0x13c')},{'option':_0x3be683('0x244f'),'value':_0x3be683('0x530')},{'option':'Hotmail','value':_0x3be683('0xf4b')},{'option':'Yahoo','value':'\x27yahoo\x27'},{'option':_0x3be683('0x11ac'),'value':'\x27outlook365\x27'}],function(_0x3af307){const _0x4b9ff3=_0x3be683;return _0x2e3ca0()[_0x4b9ff3('0x1725')](_0x3af307[_0x4b9ff3('0x1c6b')],new RegExp('\x27','g'),'');}),_0x356801['arrayImap.service']=_0x2e3ca0()[_0x3be683('0x24db')]([{'option':'Custom','value':'null'},{'option':_0x3be683('0x244f'),'value':_0x3be683('0x530')},{'option':_0x3be683('0x1c06'),'value':'\x27hotmail\x27'},{'option':_0x3be683('0x1509'),'value':'\x27yahoo\x27'},{'option':'Outlook365','value':'\x27outlook365\x27'}],function(_0x2cea82){const _0x49b19a=_0x3be683;return _0x2e3ca0()[_0x49b19a('0x1725')](_0x2cea82[_0x49b19a('0x1c6b')],new RegExp('\x27','g'),'');}),_0x356801[_0x3be683('0xe74')]=_0x2e3ca0()[_0x3be683('0x24db')]([{'option':_0x3be683('0x1fcf'),'value':'null'},{'option':'Gmail','value':_0x3be683('0x530')},{'option':_0x3be683('0x1c06'),'value':_0x3be683('0xf4b')},{'option':_0x3be683('0x1509'),'value':_0x3be683('0x26e7')},{'option':_0x3be683('0x11ac'),'value':'\x27outlook365\x27'}],function(_0x1eca36){const _0x23732e=_0x3be683;return _0x2e3ca0()[_0x23732e('0x1725')](_0x1eca36[_0x23732e('0x1c6b')],new RegExp('\x27','g'),'');}),_0x356801[_0x3be683('0xc63')]=_0x2bc60c,_0x356801[_0x3be683('0x1711')]=_0x45b307,_0x356801['interactionsgoto']=_0x19dbbf,_0x356801['gotorealtimegoto']=_0x8decb1,_0x356801[_0x3be683('0x2814')]=_0x446514,_0x356801[_0x3be683('0x194f')]=_0xad79e9,_0x356801[_0x3be683('0x53')]=_0xf7340c,_0x356801['getMailAccounts']=_0x2172f1,_0x356801[_0x3be683('0x1415')]=_0x549251,_0x356801[_0x3be683('0xba5')]=_0x5ea328,_0x356801['exportSelectedMailAccounts']=_0x28d846,_0x356801[_0x3be683('0x21c')]=_0x12fc01,_0x356801[_0x3be683('0x1d3d')]=_0x3b5b5a,_0x356801[_0x3be683('0x1d6c')]=_0x3c2864,_0x2a39e1[_0x3be683('0xca1')]('admin')?_0x51e80d[_0x3be683('0x259b')][_0x3be683('0x1e6e')]({'fields':'id,name','sort':_0x3be683('0x60a')})[_0x3be683('0xe53')][_0x3be683('0x683')](function(_0x55b8c6){const _0x395e44=_0x3be683;_0x356801[_0x395e44('0xe01')]=_0x55b8c6[_0x395e44('0xf5d')]||[];})['catch'](function(_0x4876d3){const _0xa83f4b=_0x3be683;_0x2bc714[_0xa83f4b('0x52a')]({'title':_0x4876d3[_0xa83f4b('0x13ee')]?_0xa83f4b('0x2168')+_0x4876d3['status']+_0xa83f4b('0xbf6')+_0x4876d3[_0xa83f4b('0x24a9')]:'SYSTEM:GET_LISTS','msg':_0x4876d3[_0xa83f4b('0x5a5')]?JSON[_0xa83f4b('0x258a')](_0x4876d3['data']):_0x4876d3['toString']()});}):_0x51e80d[_0x3be683('0x259b')][_0x3be683('0x1e6e')]({'fields':_0x3be683('0xa10'),'sort':_0x3be683('0x60a')})['$promise'][_0x3be683('0x683')](function(_0x2640ff){const _0x456a31=_0x3be683;_0x356801[_0x456a31('0xe01')]=_0x2640ff[_0x456a31('0xf5d')]||[];})['then'](function(){const _0x4c1793=_0x3be683;return _0x51e80d[_0x4c1793('0x22df')][_0x4c1793('0x1e6e')]({'userProfileId':_0x356801['currentUser'][_0x4c1793('0x2f')],'sectionId':0x12d})[_0x4c1793('0xe53')];})['then'](function(_0x4b47af){const _0x586f51=_0x3be683,_0x5598ad=_0x4b47af&&_0x4b47af[_0x586f51('0xf5d')]?_0x4b47af[_0x586f51('0xf5d')][0x0]:null;if(!_0x5598ad){const _0x3ab7ed=[];let _0xadf3d6=null;_0x356801['mailAccount']&&(_0xadf3d6=_0x2e3ca0()[_0x586f51('0x1c07')](_0x356801[_0x586f51('0xe01')],{'id':Number(_0x356801[_0x586f51('0xb87')][_0x586f51('0x1e4f')])}));for(let _0x2e581f=0x0;_0x2e581f<_0x356801[_0x586f51('0xe01')][_0x586f51('0x1564')];_0x2e581f++){_0xadf3d6&&_0x356801[_0x586f51('0xe01')][_0x2e581f]['id']===_0xadf3d6['id']&&(_0x356801[_0x586f51('0xe01')][_0x2e581f][_0x586f51('0x319')]=![],_0x3ab7ed[_0x586f51('0x1fd0')](_0x356801[_0x586f51('0xe01')][_0x2e581f]));}_0x356801[_0x586f51('0xe01')]=_0x3ab7ed;}else{if(!_0x5598ad[_0x586f51('0x170')])return _0x51e80d['userProfileResource'][_0x586f51('0x1e6e')]({'sectionId':_0x5598ad['id']})[_0x586f51('0xe53')][_0x586f51('0x683')](function(_0x2aa4ad){const _0x4348b2=_0x586f51,_0x42b0ec=_0x2e3ca0()[_0x4348b2('0x386')](_0x2aa4ad['rows'],function(_0x52fbf3){const _0x598db0=_0x4348b2;return _0x2e3ca0()[_0x598db0('0x1c07')](_0x356801[_0x598db0('0xe01')],{'id':_0x52fbf3[_0x598db0('0x832')]});});let _0x40789a=null;_0x356801[_0x4348b2('0xb87')]&&(_0x40789a=_0x2e3ca0()[_0x4348b2('0x1c07')](_0x356801[_0x4348b2('0xe01')],{'id':Number(_0x356801[_0x4348b2('0xb87')][_0x4348b2('0x1e4f')])}));if(_0x40789a&&!_0x2e3ca0()['some'](_0x42b0ec,['id',_0x40789a['id']])){const _0x199358=_0x2e3ca0()[_0x4348b2('0x1c07')](_0x356801[_0x4348b2('0xe01')],{'id':_0x40789a['id']});_0x199358[_0x4348b2('0x319')]=![],_0x42b0ec[_0x4348b2('0x1fd0')](_0x199358);}_0x356801[_0x4348b2('0xe01')]=_0x42b0ec;});}})[_0x3be683('0x130a')](function(_0x2d82d3){const _0x5d46bf=_0x3be683;_0x2bc714[_0x5d46bf('0x52a')]({'title':_0x2d82d3[_0x5d46bf('0x13ee')]?_0x5d46bf('0x2168')+_0x2d82d3[_0x5d46bf('0x13ee')]+_0x5d46bf('0xbf6')+_0x2d82d3[_0x5d46bf('0x24a9')]:_0x5d46bf('0x11e3'),'msg':_0x2d82d3[_0x5d46bf('0x5a5')]?JSON[_0x5d46bf('0x258a')](_0x2d82d3[_0x5d46bf('0x5a5')]):_0x2d82d3[_0x5d46bf('0x1ff0')]()});});function _0x2bc60c(_0x178e3d){const _0x56d50c=_0x3be683;_0x27f9b8['go']('app.mail.mailAccounts.edit',{'id':_0x178e3d['id'],'mailAccount':_0x178e3d,'crudPermissions':_0x356801[_0x56d50c('0x1134')]});}function _0x45b307(_0x36c10a){const _0x577483=_0x3be683;if(_0x36c10a&&_0x36c10a['id'])return _0x51e80d[_0x577483('0xb87')][_0x577483('0x2751')]({'id':_0x36c10a['id']})[_0x577483('0xe53')]['then'](function(){const _0x7e291f=_0x577483;_0x2bc714[_0x7e291f('0x53')]({'title':_0x7e291f('0xb69'),'msg':_0x7e291f('0x1c6d')});})[_0x577483('0x130a')](function(_0x5a5ab5){const _0x410c9e=_0x577483;_0x2bc714[_0x410c9e('0x52a')]({'title':'Smtp\x20properly\x20verified','msg':_0x5a5ab5[_0x410c9e('0x5a5')]?JSON[_0x410c9e('0x258a')](_0x5a5ab5[_0x410c9e('0x5a5')]):_0x5a5ab5[_0x410c9e('0x1ff0')]()});});else _0x2bc714[_0x577483('0x52a')]({'title':'Smtp\x20properly\x20verified','msg':_0x577483('0x154d')});}function _0x19dbbf(_0x1c7068){_0x27f9b8['go']('app.mail.mailAccounts.edit',{'id':_0x1c7068['id'],'tab':0x7});}function _0x8decb1(){const _0xc9cd86=_0x3be683;if(_0x2a39e1['hasRole'](_0xc9cd86('0x20c2')))_0x27f9b8['go'](_0xc9cd86('0x1000'),{});else return _0x51e80d[_0xc9cd86('0x22df')][_0xc9cd86('0x1e6e')]({'userProfileId':_0x2a39e1[_0xc9cd86('0x20b2')]()['userProfileId'],'sectionId':0x262})['$promise']['then'](function(_0x4e49f8){const _0x470149=_0xc9cd86,_0x54441b=_0x4e49f8&&_0x4e49f8[_0x470149('0xf5d')]?_0x4e49f8[_0x470149('0xf5d')][0x0]:null;_0x54441b&&_0x54441b[_0x470149('0x1333')]?_0x27f9b8['go'](_0x470149('0x1000'),{}):_0x2bc714['info']({'title':_0x1c71ed['instant']('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x1c71ed[_0x470149('0x2728')](_0x470149('0xdba'))});})[_0xc9cd86('0x130a')](function(_0x3a095f){const _0x3ee9eb=_0xc9cd86;_0x2bc714[_0x3ee9eb('0x52a')]({'title':_0x3a095f[_0x3ee9eb('0x13ee')]?_0x3ee9eb('0x2168')+_0x3a095f[_0x3ee9eb('0x13ee')]+_0x3ee9eb('0xbf6')+_0x3a095f[_0x3ee9eb('0x24a9')]:_0x3ee9eb('0xf2a'),'msg':_0x3a095f['status']?JSON['stringify'](_0x3a095f[_0x3ee9eb('0x5a5')]):_0x3a095f[_0x3ee9eb('0x1ff0')]()});});}function _0x446514(_0x58517f,_0x56d8c5){const _0x59f1bf=_0x3be683;_0x3a36b4[_0x59f1bf('0x1d4')]({'controller':_0x59f1bf('0x159d'),'controllerAs':'vm','templateUrl':_0x5dd3c0,'parent':angular['element'](_0x4237b9[_0x59f1bf('0x18e5')]),'targetEvent':_0x56d8c5,'clickOutsideToClose':!![],'locals':{'mailAccount':_0x58517f,'mailAccounts':_0x356801['mailAccounts']?_0x356801[_0x59f1bf('0x1093')][_0x59f1bf('0xf5d')]:[],'crudPermissions':_0x356801[_0x59f1bf('0x1134')],'realtime':![]}});}function _0xad79e9(_0x2d80b6,_0x28ad25){const _0x5ee566=_0x3be683,_0x465ed5=_0x3a36b4[_0x5ee566('0x1c6f')]()[_0x5ee566('0xf28')](_0x5ee566('0x1b01')+_0x2e3ca0()[_0x5ee566('0x1e03')]('mailAccount')+'?')['htmlContent'](_0x5ee566('0xed5')+(_0x2d80b6[_0x5ee566('0x60a')]||_0x5ee566('0xb87'))+_0x5ee566('0x20f1')+_0x5ee566('0x1ee7'))[_0x5ee566('0x1040')](_0x5ee566('0x103'))[_0x5ee566('0xe42')](_0x28ad25)['ok']('OK')[_0x5ee566('0x19fb')]('CANCEL');_0x3a36b4[_0x5ee566('0x1d4')](_0x465ed5)[_0x5ee566('0x683')](function(){_0x5ea328(_0x2d80b6);},function(){const _0x398a05=_0x5ee566;console[_0x398a05('0x1b2b')](_0x398a05('0x16b8'));});}let _0x6e8112=!![],_0x334fda=0x1;_0x5acf17['$watch']('vm.query.filter',function(_0x387913,_0xe55760){const _0x4c8c35=_0x3be683;_0x6e8112?_0x293d92(function(){_0x6e8112=![];}):(!_0xe55760&&(_0x334fda=_0x356801[_0x4c8c35('0x23a2')][_0x4c8c35('0xdf8')]),_0x387913!==_0xe55760&&(_0x356801[_0x4c8c35('0x23a2')]['page']=0x1),!_0x387913&&(_0x356801[_0x4c8c35('0x23a2')][_0x4c8c35('0xdf8')]=_0x334fda),_0x356801['getMailAccounts']());});function _0xf7340c(_0x40c4ce){const _0x4e6183=_0x3be683;_0x356801[_0x4e6183('0x1093')]=_0x40c4ce||{'count':0x0,'rows':[]};}function _0x2172f1(){const _0x12e3c8=_0x3be683;_0x356801[_0x12e3c8('0x23a2')][_0x12e3c8('0x1cc8')]=(_0x356801[_0x12e3c8('0x23a2')]['page']-0x1)*_0x356801[_0x12e3c8('0x23a2')]['limit'],_0x2a39e1[_0x12e3c8('0xca1')](_0x12e3c8('0x20c2'))?_0x356801[_0x12e3c8('0x1883')]=_0x51e80d[_0x12e3c8('0xb87')][_0x12e3c8('0x1e6e')](_0x356801[_0x12e3c8('0x23a2')],_0xf7340c)['$promise']:(_0x356801['query']['id']=_0x356801[_0x12e3c8('0x2a')]['id'],_0x356801['query'][_0x12e3c8('0x1aa')]='MailAccounts',_0x356801[_0x12e3c8('0x1883')]=_0x51e80d[_0x12e3c8('0x2a')][_0x12e3c8('0x241d')](_0x356801['query'],_0xf7340c)[_0x12e3c8('0xe53')]);}function _0x549251(_0x22018f,_0x1209e4){const _0x3aa3d2=_0x3be683;_0x3a36b4[_0x3aa3d2('0x1d4')]({'controller':_0x3aa3d2('0x15c4'),'controllerAs':'vm','templateUrl':_0x22cfef,'parent':angular['element'](_0x4237b9['body']),'targetEvent':_0x22018f,'clickOutsideToClose':!![],'locals':{'mailAccount':_0x1209e4,'mailAccounts':_0x356801[_0x3aa3d2('0x1093')][_0x3aa3d2('0xf5d')],'license':_0x356801[_0x3aa3d2('0xace')],'setting':_0x356801['setting'],'crudPermissions':_0x356801[_0x3aa3d2('0x1134')]}});}function _0x5ea328(_0x281f37){const _0x9afa97=_0x3be683;if(_0x281f37[_0x9afa97('0x8c0')])return _0x2bc714['error']({'title':'Mail\x20Account\x20not\x20deleted!','msg':_0x9afa97('0x63d')});_0x51e80d[_0x9afa97('0xb87')][_0x9afa97('0xd7e')]({'id':_0x281f37['id']})['$promise']['then'](function(){const _0x4a1dea=_0x9afa97;_0x2e3ca0()['remove'](_0x356801[_0x4a1dea('0x1093')][_0x4a1dea('0xf5d')],{'id':_0x281f37['id']}),_0x356801[_0x4a1dea('0x1093')][_0x4a1dea('0x50d')]-=0x1,!_0x356801[_0x4a1dea('0x1093')][_0x4a1dea('0xf5d')][_0x4a1dea('0x1564')]&&_0x356801[_0x4a1dea('0x2872')](),_0x2bc714[_0x4a1dea('0x53')]({'title':_0x2e3ca0()[_0x4a1dea('0x1e03')](_0x4a1dea('0x232c'))+_0x4a1dea('0xbfc'),'msg':_0x281f37[_0x4a1dea('0x60a')]?_0x281f37['name']+_0x4a1dea('0x194d'):''});})[_0x9afa97('0x130a')](function(_0x123fb9){const _0x19a73c=_0x9afa97;if(_0x123fb9['data']&&_0x123fb9[_0x19a73c('0x5a5')][_0x19a73c('0x17f')]&&_0x123fb9[_0x19a73c('0x5a5')][_0x19a73c('0x17f')][_0x19a73c('0x1564')]){_0x356801[_0x19a73c('0x17f')]=_0x123fb9['data'][_0x19a73c('0x17f')]||[{'message':_0x123fb9['toString'](),'type':_0x19a73c('0x22b0')}];for(let _0x43a4d6=0x0;_0x43a4d6<_0x123fb9[_0x19a73c('0x5a5')]['errors'][_0x19a73c('0x1564')];_0x43a4d6++){_0x2bc714[_0x19a73c('0x52a')]({'title':_0x123fb9[_0x19a73c('0x5a5')]['errors'][_0x43a4d6][_0x19a73c('0xcf0')],'msg':_0x123fb9[_0x19a73c('0x5a5')][_0x19a73c('0x17f')][_0x43a4d6][_0x19a73c('0x8c2')]});}}else _0x2bc714[_0x19a73c('0x52a')]({'title':_0x123fb9['status']?_0x19a73c('0x2168')+_0x123fb9[_0x19a73c('0x13ee')]+'\x20-\x20'+_0x123fb9[_0x19a73c('0x24a9')]:'SYSTEM:DELETEmailAccount','msg':_0x123fb9['data']?JSON[_0x19a73c('0x258a')](_0x123fb9['data']['message']):_0x123fb9[_0x19a73c('0x8c2')]||_0x123fb9[_0x19a73c('0x1ff0')]()});});}function _0x28d846(){const _0x6f919d=_0x3be683,_0x688426=angular[_0x6f919d('0x1a86')](_0x356801[_0x6f919d('0x68f')]);return _0x356801[_0x6f919d('0x68f')]=[],_0x688426;}function _0x12fc01(_0xf41e42){const _0x4fcbd6=_0x3be683,_0x34cece=_0x3a36b4['confirm']()[_0x4fcbd6('0xf28')](_0x4fcbd6('0x23f'))[_0x4fcbd6('0x26e3')](_0x4fcbd6('0xed5')+_0x356801[_0x4fcbd6('0x68f')][_0x4fcbd6('0x1564')]+_0x4fcbd6('0x93c')+_0x4fcbd6('0x1ee7'))['ariaLabel'](_0x4fcbd6('0x1df9'))['targetEvent'](_0xf41e42)['ok']('OK')[_0x4fcbd6('0x19fb')](_0x4fcbd6('0x16b8'));_0x3a36b4[_0x4fcbd6('0x1d4')](_0x34cece)[_0x4fcbd6('0x683')](function(){const _0x56c228=_0x4fcbd6;_0x356801[_0x56c228('0x68f')][_0x56c228('0x1299')](function(_0x446bc6){_0x5ea328(_0x446bc6);}),_0x356801[_0x56c228('0x68f')]=[];});}function _0x3b5b5a(){const _0x4c5d48=_0x3be683;_0x356801[_0x4c5d48('0x68f')]=[];}function _0x3c2864(){const _0x51837c=_0x3be683;_0x356801[_0x51837c('0x68f')]=_0x356801[_0x51837c('0x1093')][_0x51837c('0xf5d')];}}const _0x586ee9=_0x4bcd08;_0x2813ee[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0xc05'),_0x189033('0x2160'),_0x189033('0x56b'),'Auth','license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x2813ee(_0x4a3b4a,_0x1fb31c,_0x1793b5,_0x40ee08,_0x24afdc,_0x3ba5d4,_0x20c3d6,_0x15a2f8,_0x56616c,_0xf746ff,_0x3d1b73,_0x1101c9,_0xa70ff2,_0x5324d9){const _0xd2c3f6=_0x189033,_0x3b977e=this;_0x3b977e[_0xd2c3f6('0x11ed')]=_0x3d1b73[_0xd2c3f6('0x20b2')](),_0x3b977e[_0xd2c3f6('0x17f')]=[],_0x3b977e['setting']=_0xa70ff2,_0x3b977e['license']=_0x1101c9,_0x3b977e[_0xd2c3f6('0x1134')]=_0x5324d9,_0x3b977e[_0xd2c3f6('0x258d')]={},_0x3b977e[_0xd2c3f6('0x19b2')]=_0x3b977e[_0xd2c3f6('0x260a')]&&_0x3b977e['setting'][_0xd2c3f6('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3b977e[_0xd2c3f6('0xf28')]=_0xd2c3f6('0x5dc'),_0x3b977e['mailQueue']=angular['copy'](_0x56616c),_0x3b977e['mailQueues']=_0x15a2f8,_0x3b977e[_0xd2c3f6('0xb83')]=![];!_0x3b977e[_0xd2c3f6('0x2160')]&&(_0x3b977e[_0xd2c3f6('0x2160')]={'strategy':_0xd2c3f6('0x25ee'),'timeout':0xa},_0x3b977e[_0xd2c3f6('0xf28')]='MAIL.NEW_MAILQUEUE',_0x3b977e[_0xd2c3f6('0xb83')]=!![]);_0x3b977e[_0xd2c3f6('0x10f9')]=_0x1c0e5c,_0x3b977e[_0xd2c3f6('0x43')]=_0x4a58c6,_0x3b977e['deleteMailQueue']=_0x3aff98,_0x3b977e[_0xd2c3f6('0x16b3')]=_0x2b89d8,_0x3b977e[_0xd2c3f6('0xf82')]=_0x2c2c55;function _0x1c0e5c(){const _0x4121f5=_0xd2c3f6;_0x3b977e['errors']=[],_0xf746ff['mailQueue'][_0x4121f5('0xb0a')](_0x3b977e[_0x4121f5('0x2160')])[_0x4121f5('0xe53')]['then'](function(_0xafac77){const _0xb7e3ae=_0x4121f5;_0x3b977e[_0xb7e3ae('0xc05')]['unshift'](_0xafac77[_0xb7e3ae('0x24e1')]()),_0x20c3d6[_0xb7e3ae('0x53')]({'title':_0xb7e3ae('0x1b5f'),'msg':_0x3b977e[_0xb7e3ae('0x2160')][_0xb7e3ae('0x60a')]?_0x3b977e['mailQueue'][_0xb7e3ae('0x60a')]+_0xb7e3ae('0x14b5'):''}),_0x2c2c55(_0xafac77);})[_0x4121f5('0x130a')](function(_0x9b19b3){const _0x1a4b12=_0x4121f5;if(_0x9b19b3['data']&&_0x9b19b3['data'][_0x1a4b12('0x17f')]&&_0x9b19b3[_0x1a4b12('0x5a5')]['errors'][_0x1a4b12('0x1564')]){_0x3b977e[_0x1a4b12('0x17f')]=_0x9b19b3[_0x1a4b12('0x5a5')][_0x1a4b12('0x17f')]||[{'message':_0x9b19b3[_0x1a4b12('0x1ff0')](),'type':'api.mailQueue.save'}];for(let _0x53c765=0x0;_0x53c765<_0x9b19b3[_0x1a4b12('0x5a5')]['errors'][_0x1a4b12('0x1564')];_0x53c765+=0x1){_0x20c3d6[_0x1a4b12('0x52a')]({'title':_0x9b19b3[_0x1a4b12('0x5a5')][_0x1a4b12('0x17f')][_0x53c765]['type'],'msg':_0x9b19b3[_0x1a4b12('0x5a5')][_0x1a4b12('0x17f')][_0x53c765][_0x1a4b12('0x8c2')]});}}else _0x20c3d6[_0x1a4b12('0x52a')]({'title':_0x9b19b3[_0x1a4b12('0x13ee')]?'API:'+_0x9b19b3[_0x1a4b12('0x13ee')]+_0x1a4b12('0xbf6')+_0x9b19b3['statusText']:_0x1a4b12('0x21f1'),'msg':_0x9b19b3[_0x1a4b12('0x5a5')]?JSON[_0x1a4b12('0x258a')](_0x9b19b3['data'][_0x1a4b12('0x8c2')]):_0x9b19b3[_0x1a4b12('0x1ff0')]()});});}function _0x4a58c6(){const _0xa3e203=_0xd2c3f6;_0x3b977e[_0xa3e203('0x17f')]=[],_0xf746ff[_0xa3e203('0x2160')][_0xa3e203('0x2480')]({'id':_0x3b977e[_0xa3e203('0x2160')]['id']},_0x3b977e[_0xa3e203('0x2160')])[_0xa3e203('0xe53')][_0xa3e203('0x683')](function(_0x312925){const _0xc3d6b6=_0xa3e203,_0x15f01a=_0x2e3ca0()[_0xc3d6b6('0x1c07')](_0x3b977e[_0xc3d6b6('0xc05')],{'id':_0x312925['id']});_0x15f01a&&_0x2e3ca0()[_0xc3d6b6('0xf22')](_0x15f01a,_0x2e3ca0()['pick'](_0x312925[_0xc3d6b6('0x24e1')](),_0x2e3ca0()[_0xc3d6b6('0x55e')](_0x15f01a))),_0x20c3d6['success']({'title':_0xc3d6b6('0xdc3'),'msg':_0x3b977e[_0xc3d6b6('0x2160')][_0xc3d6b6('0x60a')]?_0x3b977e['mailQueue'][_0xc3d6b6('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x2c2c55(_0x312925);})[_0xa3e203('0x130a')](function(_0x235f3d){const _0x428b02=_0xa3e203;if(_0x235f3d[_0x428b02('0x5a5')]&&_0x235f3d[_0x428b02('0x5a5')]['errors']&&_0x235f3d[_0x428b02('0x5a5')]['errors'][_0x428b02('0x1564')]){_0x3b977e['errors']=_0x235f3d[_0x428b02('0x5a5')][_0x428b02('0x17f')]||[{'message':_0x235f3d['toString'](),'type':_0x428b02('0x1e97')}];for(let _0x57a16a=0x0;_0x57a16a<_0x235f3d[_0x428b02('0x5a5')][_0x428b02('0x17f')][_0x428b02('0x1564')];_0x57a16a++){_0x20c3d6[_0x428b02('0x52a')]({'title':_0x235f3d[_0x428b02('0x5a5')][_0x428b02('0x17f')][_0x57a16a][_0x428b02('0xcf0')],'msg':_0x235f3d['data'][_0x428b02('0x17f')][_0x57a16a][_0x428b02('0x8c2')]});}}else _0x20c3d6[_0x428b02('0x52a')]({'title':_0x235f3d['status']?_0x428b02('0x2168')+_0x235f3d[_0x428b02('0x13ee')]+_0x428b02('0xbf6')+_0x235f3d[_0x428b02('0x24a9')]:_0x428b02('0x1e97'),'msg':_0x235f3d[_0x428b02('0x5a5')]?JSON[_0x428b02('0x258a')](_0x235f3d['data']['message']):_0x235f3d['toString']()});});}function _0x3aff98(_0x87aee3){const _0x5089fb=_0xd2c3f6;_0x3b977e[_0x5089fb('0x17f')]=[];const _0x1ef0bd=_0x40ee08['confirm']()[_0x5089fb('0xf28')]('Are\x20you\x20sure?')['content'](_0x5089fb('0x269b'))['ariaLabel'](_0x5089fb('0x128c'))['ok'](_0x5089fb('0x2307'))['cancel'](_0x5089fb('0x253a'))[_0x5089fb('0xe42')](_0x87aee3);_0x40ee08[_0x5089fb('0x1d4')](_0x1ef0bd)[_0x5089fb('0x683')](function(){const _0x7c1596=_0x5089fb;_0xf746ff[_0x7c1596('0x2160')][_0x7c1596('0xd7e')]({'id':_0x3b977e[_0x7c1596('0x2160')]['id']})[_0x7c1596('0xe53')][_0x7c1596('0x683')](function(){const _0x25c1d9=_0x7c1596;_0x2e3ca0()['remove'](_0x3b977e[_0x25c1d9('0xc05')],{'id':_0x3b977e[_0x25c1d9('0x2160')]['id']}),_0x20c3d6['success']({'title':_0x25c1d9('0x607'),'msg':(_0x3b977e[_0x25c1d9('0x2160')][_0x25c1d9('0x60a')]||_0x25c1d9('0x2160'))+_0x25c1d9('0x194d')}),_0x2c2c55(_0x3b977e[_0x25c1d9('0x2160')]);})['catch'](function(_0x40b5f7){const _0x4dafa0=_0x7c1596;if(_0x40b5f7['data']&&_0x40b5f7['data'][_0x4dafa0('0x17f')]&&_0x40b5f7['data']['errors'][_0x4dafa0('0x1564')]){_0x3b977e[_0x4dafa0('0x17f')]=_0x40b5f7[_0x4dafa0('0x5a5')][_0x4dafa0('0x17f')]||[{'message':_0x40b5f7[_0x4dafa0('0x1ff0')](),'type':_0x4dafa0('0x6a5')}];for(let _0x4c6b76=0x0;_0x4c6b76<_0x40b5f7['data']['errors'][_0x4dafa0('0x1564')];_0x4c6b76++){_0x20c3d6[_0x4dafa0('0x52a')]({'title':_0x40b5f7[_0x4dafa0('0x5a5')]['errors'][_0x4c6b76]['type'],'msg':_0x40b5f7[_0x4dafa0('0x5a5')][_0x4dafa0('0x17f')][_0x4c6b76][_0x4dafa0('0x8c2')]});}}else _0x20c3d6[_0x4dafa0('0x52a')]({'title':_0x40b5f7[_0x4dafa0('0x13ee')]?_0x4dafa0('0x2168')+_0x40b5f7['status']+_0x4dafa0('0xbf6')+_0x40b5f7[_0x4dafa0('0x24a9')]:'api.mailQueue.delete','msg':_0x40b5f7[_0x4dafa0('0x5a5')]?JSON['stringify'](_0x40b5f7[_0x4dafa0('0x5a5')][_0x4dafa0('0x8c2')]):_0x40b5f7[_0x4dafa0('0x8c2')]||_0x40b5f7[_0x4dafa0('0x1ff0')]()});});},function(){});}function _0x2b89d8(_0x30b850){return _0x30b850===null?undefined:new Date(_0x30b850);}function _0x2c2c55(_0x38a07e){const _0x4a3e90=_0xd2c3f6;_0x40ee08[_0x4a3e90('0x1715')](_0x38a07e);}}const _0x9a174e=_0x2813ee;_0x743ae0['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x2160'),_0x189033('0xc05'),_0x189033('0x2c9'),_0x189033('0x1d08'),'Auth',_0x189033('0x1134')];function _0x743ae0(_0x5789b0,_0x2c3d4f,_0x25b009,_0x18731a,_0x232fe0,_0x4ccb04,_0x299bec,_0x304a9a,_0x1d989e,_0x33c56e){const _0x40fc7d=_0x189033,_0x584cf4=this;_0x584cf4[_0x40fc7d('0x11ed')]=_0x1d989e[_0x40fc7d('0x20b2')](),_0x584cf4[_0x40fc7d('0x2160')]=_0x232fe0,_0x584cf4['crudPermissions']=_0x33c56e,_0x584cf4[_0x40fc7d('0x2c9')]=_0x299bec,_0x584cf4[_0x40fc7d('0x1996')]=[],_0x584cf4[_0x40fc7d('0x1c47')]=[],_0x584cf4[_0x40fc7d('0x1378')]=[],_0x584cf4['startingAllowedItems']=[],_0x584cf4[_0x40fc7d('0x23a7')]=[],_0x584cf4[_0x40fc7d('0x2106')]=![],_0x584cf4['onInit']=_0x5532ba,_0x584cf4[_0x40fc7d('0xa5f')]=_0x101a12,_0x584cf4[_0x40fc7d('0xf82')]=_0xe30665,_0x584cf4[_0x40fc7d('0x169f')]={'readOnly':!_0x584cf4[_0x40fc7d('0x1134')][_0x40fc7d('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x40fc7d('0x11bc'),'line2':[_0x40fc7d('0x60a'),_0x40fc7d('0x1d43')],'line3':'','labelAll':_0x304a9a['instant']('MAIL.ALL_AGENTS'),'labelSelected':_0x304a9a[_0x40fc7d('0x2728')](_0x40fc7d('0xd0a')),'transferCallback':function(){const _0x226930=_0x40fc7d,_0x4d3839=_0x2e3ca0()[_0x226930('0x25cb')](_0x584cf4[_0x226930('0x23a7')],_0x584cf4[_0x226930('0x1378')],'id');_0x584cf4[_0x226930('0x2106')]=_0x2e3ca0()['isEmpty'](_0x4d3839)?![]:!![];}};function _0x5532ba(){const _0x1295df=_0x40fc7d;return _0x1d989e[_0x1295df('0xca1')]('admin')?_0x1be875()[_0x1295df('0x130a')](function(_0xb278a1){const _0x271e37=_0x1295df;_0x25b009[_0x271e37('0x52a')]({'title':_0xb278a1[_0x271e37('0x13ee')]?_0x271e37('0x2168')+_0xb278a1[_0x271e37('0x13ee')]+_0x271e37('0xbf6')+_0xb278a1[_0x271e37('0x24a9')]:_0x271e37('0x144f'),'msg':_0xb278a1[_0x271e37('0x13ee')]?JSON[_0x271e37('0x258a')](_0xb278a1['data']):_0xb278a1[_0x271e37('0x1ff0')]()});}):_0x3407b9()[_0x1295df('0x683')](function(_0x435fc0){return _0x584cf4['section']=_0x435fc0,_0x1be875();})['catch'](function(_0x412278){const _0x488ab9=_0x1295df;_0x25b009[_0x488ab9('0x52a')]({'title':_0x412278[_0x488ab9('0x13ee')]?_0x488ab9('0x2168')+_0x412278['status']+'\x20-\x20'+_0x412278['statusText']:_0x488ab9('0x144f'),'msg':_0x412278['status']?JSON['stringify'](_0x412278[_0x488ab9('0x5a5')]):_0x412278[_0x488ab9('0x1ff0')]()});});}function _0x3407b9(){return _0x2c3d4f(function(_0x246080,_0x21e454){const _0x243585=a0_0x4e0a;_0x18731a[_0x243585('0x22df')][_0x243585('0x1e6e')]({'userProfileId':_0x584cf4['currentUser'][_0x243585('0x2f')],'name':'Agents'})['$promise'][_0x243585('0x683')](function(_0x2cb34f){const _0x46eb5e=_0x243585,_0x3bd269=_0x2cb34f&&_0x2cb34f[_0x46eb5e('0xf5d')]?_0x2cb34f[_0x46eb5e('0xf5d')][0x0]:null;_0x246080(_0x3bd269);})[_0x243585('0x130a')](function(_0x305a8d){_0x21e454(_0x305a8d);});});}function _0x1be875(){return _0x2c3d4f(function(_0x2d6b82,_0x3d031f){const _0xfe9ae=a0_0x4e0a;return _0x4481ae()[_0xfe9ae('0x683')](function(_0x42a0a3){const _0x8899ad=_0xfe9ae;return _0x584cf4[_0x8899ad('0x1996')]=_0x42a0a3[_0x8899ad('0xf5d')]?_0x42a0a3[_0x8899ad('0xf5d')]:[],_0x1d989e[_0x8899ad('0xca1')](_0x8899ad('0x20c2'))?_0x42a0a3:_0x584cf4['section']?_0x584cf4[_0x8899ad('0x1aa')]['autoAssociation']?_0x42a0a3:_0x27e695():null;})[_0xfe9ae('0x683')](function(_0x22abb8){const _0x4cc346=_0xfe9ae,_0xd5c30d=_0x22abb8&&_0x22abb8['rows']?_0x22abb8['rows']:[];return _0x584cf4['allowedItems']=_0x2e3ca0()[_0x4cc346('0x386')](_0xd5c30d,function(_0x41ae67){const _0x4981ea=_0x4cc346;return _0x2e3ca0()[_0x4981ea('0x1c07')](_0x584cf4[_0x4981ea('0x1996')],{'id':_0x1d989e['hasRole'](_0x4981ea('0x20c2'))||_0x584cf4[_0x4981ea('0x1aa')][_0x4981ea('0x170')]?_0x41ae67['id']:_0x41ae67[_0x4981ea('0x832')]});}),_0x584cf4[_0x4cc346('0x125e')]=angular[_0x4cc346('0x1a86')](_0x584cf4['allowedItems']),_0x584cf4[_0x4cc346('0x1996')]['forEach'](function(_0x34e28a){const _0x662479=_0x4cc346,_0x599910=_0x2e3ca0()[_0x662479('0x1c07')](_0x584cf4[_0x662479('0x1c47')],{'id':_0x34e28a['id']});_0x1d989e['hasRole']('admin')?_0x34e28a[_0x662479('0x24f4')]=!![]:_0x34e28a[_0x662479('0x24f4')]=typeof _0x599910!==_0x662479('0x1867')?!![]:![];}),_0xa83ae5();})['then'](function(_0x18a46a){const _0x3f5064=_0xfe9ae,_0x1d1aa6=_0x18a46a&&_0x18a46a[_0x3f5064('0xf5d')]?_0x18a46a['rows']:[];_0x584cf4[_0x3f5064('0x1378')]=_0x2e3ca0()[_0x3f5064('0x386')](_0x1d1aa6,function(_0x816c73){const _0x3e1f4e=_0x3f5064,_0x3ae88d=_0x2e3ca0()[_0x3e1f4e('0x1c07')](_0x584cf4[_0x3e1f4e('0x1996')],{'id':_0x816c73['id']});return _0x3ae88d[_0x3e1f4e('0x1e2a')]=_0x816c73[_0x3e1f4e('0xdfc')]?_0x3e1f4e('0x23d0')+_0x816c73[_0x3e1f4e('0xdfc')][_0x3e1f4e('0x1e2a')]:'',_0x3ae88d[_0x3e1f4e('0x1d43')]=typeof _0x816c73[_0x3e1f4e('0x1d43')]!==_0x3e1f4e('0x1867')?'<'+_0x816c73[_0x3e1f4e('0x1d43')]+'>':'',_0x3ae88d;}),_0x584cf4[_0x3f5064('0x23a7')]=angular['copy'](_0x584cf4[_0x3f5064('0x1378')]),_0x584cf4[_0x3f5064('0x169f')][_0x3f5064('0x1378')]=_0x584cf4[_0x3f5064('0x1378')],_0x584cf4['dualMultiselectOptions'][_0x3f5064('0x1996')]=_0x2e3ca0()['differenceBy'](_0x584cf4['allowedItems'],_0x584cf4[_0x3f5064('0x169f')][_0x3f5064('0x1378')],'id'),_0x2d6b82();})[_0xfe9ae('0x130a')](function(_0x1df16e){_0x3d031f(_0x1df16e);});});}function _0x27e695(){return _0x2c3d4f(function(_0x4bfcea,_0x9db904){const _0x2dbb13=a0_0x4e0a;return _0x18731a[_0x2dbb13('0xcf7')][_0x2dbb13('0x1e6e')]({'sectionId':_0x584cf4['section']['id'],'nolimit':!![]})[_0x2dbb13('0xe53')][_0x2dbb13('0x683')](function(_0x58fdba){_0x4bfcea(_0x58fdba);})[_0x2dbb13('0x130a')](function(_0x41607b){_0x9db904(_0x41607b);});});}function _0xa83ae5(){return _0x2c3d4f(function(_0x418981,_0x2a45e9){const _0x3d1c51=a0_0x4e0a;return _0x18731a[_0x3d1c51('0x2160')][_0x3d1c51('0x8e7')]({'id':_0x584cf4[_0x3d1c51('0x2160')]['id'],'fields':_0x3d1c51('0x72b'),'nolimit':!![],'role':_0x3d1c51('0x2327')})['$promise'][_0x3d1c51('0x683')](function(_0x168c7d){_0x418981(_0x168c7d);})[_0x3d1c51('0x130a')](function(_0x2b5c4b){_0x2a45e9(_0x2b5c4b);});});}function _0x4481ae(){return _0x2c3d4f(function(_0x352bfd,_0x5d2bfd){const _0x434fa2=a0_0x4e0a;return _0x18731a[_0x434fa2('0xc96')]['get']({'fields':_0x434fa2('0x72b'),'nolimit':!![],'role':'agent'})['$promise'][_0x434fa2('0x683')](function(_0x5c4027){_0x352bfd(_0x5c4027);})['catch'](function(_0x3df76c){_0x5d2bfd(_0x3df76c);});});}function _0x4c5ec7(_0x372217){return _0x2c3d4f(function(_0x3f46ef,_0x9804f){const _0x43f57b=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0x372217)?_0x3f46ef():_0x18731a[_0x43f57b('0x2160')][_0x43f57b('0x2179')]({'id':_0x584cf4[_0x43f57b('0x2160')]['id'],'ids':_0x2e3ca0()[_0x43f57b('0x386')](_0x372217,'id')})[_0x43f57b('0xe53')][_0x43f57b('0x683')](function(){_0x3f46ef();})[_0x43f57b('0x130a')](function(_0x26837d){_0x9804f(_0x26837d);});});}function _0x501873(_0x36cf5d){return _0x2c3d4f(function(_0x29572e,_0x5a1a3f){const _0x5b359d=a0_0x4e0a;_0x2e3ca0()[_0x5b359d('0x173f')](_0x36cf5d)?_0x29572e():_0x18731a[_0x5b359d('0x2160')]['removeAgents']({'id':_0x584cf4[_0x5b359d('0x2160')]['id'],'ids':_0x2e3ca0()['map'](_0x36cf5d,'id')})[_0x5b359d('0xe53')][_0x5b359d('0x683')](function(){_0x29572e();})['catch'](function(_0x219797){_0x5a1a3f(_0x219797);});});}function _0x101a12(){const _0x579226=_0x40fc7d,_0xafecb6=_0x2e3ca0()[_0x579226('0x461')](_0x584cf4['startingSelectedItems'],_0x584cf4[_0x579226('0x1378')],'id'),_0x317d98=_0x2e3ca0()[_0x579226('0x461')](_0x584cf4[_0x579226('0x1378')],_0x584cf4[_0x579226('0x23a7')],'id');return _0x501873(_0xafecb6)[_0x579226('0x683')](function(){return _0x4c5ec7(_0x317d98);})['then'](function(){const _0x2e3735=_0x579226;_0x584cf4[_0x2e3735('0x2106')]=![],_0x584cf4['startingAllowedItems']=angular[_0x2e3735('0x1a86')](_0x584cf4[_0x2e3735('0x1c47')]),_0x584cf4[_0x2e3735('0x23a7')]=angular[_0x2e3735('0x1a86')](_0x584cf4[_0x2e3735('0x1378')]),_0x25b009[_0x2e3735('0x53')]({'title':'SUCCESS','msg':_0x2e3735('0x89d')});})[_0x579226('0x130a')](function(_0x4c3521){const _0x2640d3=_0x579226;_0x25b009[_0x2640d3('0x52a')]({'title':_0x4c3521['status']?'API:'+_0x4c3521[_0x2640d3('0x13ee')]+_0x2640d3('0xbf6')+_0x4c3521['statusText']:_0x2640d3('0x1b71'),'msg':_0x4c3521[_0x2640d3('0x13ee')]?JSON[_0x2640d3('0x258a')](_0x4c3521[_0x2640d3('0x5a5')]):_0x4c3521[_0x2640d3('0x1ff0')]()});});}function _0xe30665(){const _0x5ea8af=_0x40fc7d;_0x5789b0[_0x5ea8af('0x1715')]();}}const _0x865c68=_0x743ae0;_0x166a57[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x56b'),_0x189033('0x2160'),_0x189033('0x1d08'),_0x189033('0xba1'),'crudPermissions'];function _0x166a57(_0x11284c,_0x513a2a,_0x238142,_0x1d6e4e,_0x53936b,_0x34f65b,_0x271512,_0x7ed120){const _0x11a2f7=_0x189033,_0x5cb7ee=this;_0x5cb7ee[_0x11a2f7('0x11ed')]=_0x271512[_0x11a2f7('0x20b2')](),_0x5cb7ee[_0x11a2f7('0x2160')]=_0x53936b,_0x5cb7ee[_0x11a2f7('0x1134')]=_0x7ed120,_0x5cb7ee[_0x11a2f7('0x1996')]=[],_0x5cb7ee[_0x11a2f7('0x1c47')]=[],_0x5cb7ee['selectedItems']=[],_0x5cb7ee[_0x11a2f7('0x125e')]=[],_0x5cb7ee[_0x11a2f7('0x23a7')]=[],_0x5cb7ee[_0x11a2f7('0x2106')]=![],_0x5cb7ee[_0x11a2f7('0x169f')]={'readOnly':!_0x5cb7ee[_0x11a2f7('0x1134')]['canEdit'],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x11a2f7('0x60a'),'line1':_0x11a2f7('0x60a'),'line2':'','line3':'','labelAll':_0x34f65b['instant'](_0x11a2f7('0x144b')),'labelSelected':_0x34f65b[_0x11a2f7('0x2728')](_0x11a2f7('0x1385')),'transferCallback':function(){const _0x1c2f49=_0x11a2f7,_0x56a75e=_0x2e3ca0()[_0x1c2f49('0x25cb')](_0x5cb7ee[_0x1c2f49('0x23a7')],_0x5cb7ee[_0x1c2f49('0x1378')],'id');_0x5cb7ee[_0x1c2f49('0x2106')]=_0x2e3ca0()[_0x1c2f49('0x173f')](_0x56a75e)?![]:!![];}},_0x5cb7ee[_0x11a2f7('0x1dd2')]=_0x56a014,_0x5cb7ee[_0x11a2f7('0x1a89')]=_0x55062f,_0x5cb7ee[_0x11a2f7('0xf82')]=_0x117241;function _0x56a014(){const _0x1e57ef=_0x11a2f7;return _0x271512['hasRole'](_0x1e57ef('0x20c2'))?_0x2d533f()['catch'](function(_0x5a94b6){const _0x3554b6=_0x1e57ef;_0x238142[_0x3554b6('0x52a')]({'title':_0x5a94b6[_0x3554b6('0x13ee')]?'API:'+_0x5a94b6[_0x3554b6('0x13ee')]+_0x3554b6('0xbf6')+_0x5a94b6[_0x3554b6('0x24a9')]:'SYSTEM:GET_TEAMS','msg':_0x5a94b6[_0x3554b6('0x13ee')]?JSON[_0x3554b6('0x258a')](_0x5a94b6[_0x3554b6('0x5a5')]):_0x5a94b6['toString']()});}):_0x1a0b26()['then'](function(_0x358698){const _0x13add7=_0x1e57ef;return _0x5cb7ee[_0x13add7('0x1aa')]=_0x358698,_0x2d533f();})['catch'](function(_0x1cac8b){const _0x1e9aff=_0x1e57ef;_0x238142[_0x1e9aff('0x52a')]({'title':_0x1cac8b['status']?_0x1e9aff('0x2168')+_0x1cac8b['status']+'\x20-\x20'+_0x1cac8b['statusText']:_0x1e9aff('0x1820'),'msg':_0x1cac8b[_0x1e9aff('0x13ee')]?JSON['stringify'](_0x1cac8b[_0x1e9aff('0x5a5')]):_0x1cac8b[_0x1e9aff('0x1ff0')]()});});}function _0x1a0b26(){return _0x513a2a(function(_0x2dcab1,_0x19b4ae){const _0x176aa5=a0_0x4e0a;_0x1d6e4e[_0x176aa5('0x22df')][_0x176aa5('0x1e6e')]({'userProfileId':_0x5cb7ee['currentUser'][_0x176aa5('0x2f')],'name':_0x176aa5('0x15bc')})[_0x176aa5('0xe53')][_0x176aa5('0x683')](function(_0xdcd342){const _0x1e5201=_0x176aa5,_0x2c33c5=_0xdcd342&&_0xdcd342['rows']?_0xdcd342[_0x1e5201('0xf5d')][0x0]:null;_0x2dcab1(_0x2c33c5);})['catch'](function(_0x396c9c){_0x19b4ae(_0x396c9c);});});}function _0x2d533f(){return _0x513a2a(function(_0x3c9e83,_0x4af2ae){const _0x1944cb=a0_0x4e0a;return _0x409e40()[_0x1944cb('0x683')](function(_0x4fbbf5){const _0x32a171=_0x1944cb;return _0x5cb7ee[_0x32a171('0x1996')]=_0x4fbbf5[_0x32a171('0xf5d')]?_0x4fbbf5[_0x32a171('0xf5d')]:[],_0x271512[_0x32a171('0xca1')](_0x32a171('0x20c2'))?_0x4fbbf5:_0x5cb7ee[_0x32a171('0x1aa')]?_0x5cb7ee[_0x32a171('0x1aa')][_0x32a171('0x170')]?_0x4fbbf5:_0xd60897():null;})[_0x1944cb('0x683')](function(_0x2dc139){const _0x2d6f62=_0x1944cb,_0x347b9c=_0x2dc139&&_0x2dc139[_0x2d6f62('0xf5d')]?_0x2dc139[_0x2d6f62('0xf5d')]:[];return _0x5cb7ee['allowedItems']=_0x2e3ca0()[_0x2d6f62('0x386')](_0x347b9c,function(_0x35a75d){const _0x580a58=_0x2d6f62;return _0x2e3ca0()['find'](_0x5cb7ee[_0x580a58('0x1996')],{'id':_0x271512['hasRole'](_0x580a58('0x20c2'))||_0x5cb7ee['section']['autoAssociation']?_0x35a75d['id']:_0x35a75d['resourceId']});}),_0x5cb7ee['items'][_0x2d6f62('0x1299')](function(_0x502cfb){const _0x4c3d84=_0x2d6f62,_0x49084c=_0x2e3ca0()[_0x4c3d84('0x1c07')](_0x5cb7ee[_0x4c3d84('0x1c47')],{'id':_0x502cfb['id']});_0x271512[_0x4c3d84('0xca1')]('admin')?_0x502cfb[_0x4c3d84('0x24f4')]=!![]:_0x502cfb['isValid']=typeof _0x49084c!==_0x4c3d84('0x1867')?!![]:![];}),_0xf235e7();})['then'](function(_0x5f9b65){const _0x4ce7d9=_0x1944cb,_0x318068=_0x5f9b65&&_0x5f9b65[_0x4ce7d9('0xf5d')]?_0x5f9b65[_0x4ce7d9('0xf5d')]:[];_0x5cb7ee[_0x4ce7d9('0x1378')]=_0x2e3ca0()[_0x4ce7d9('0x386')](_0x318068,function(_0x56253b){const _0x57cd7d=_0x4ce7d9;return _0x2e3ca0()[_0x57cd7d('0x1c07')](_0x5cb7ee[_0x57cd7d('0x1996')],{'id':_0x56253b['id']});}),_0x5cb7ee[_0x4ce7d9('0x23a7')]=angular[_0x4ce7d9('0x1a86')](_0x5cb7ee['selectedItems']),_0x5cb7ee[_0x4ce7d9('0x169f')][_0x4ce7d9('0x1378')]=_0x5cb7ee[_0x4ce7d9('0x1378')],_0x5cb7ee[_0x4ce7d9('0x169f')][_0x4ce7d9('0x1996')]=_0x2e3ca0()[_0x4ce7d9('0x461')](_0x5cb7ee['allowedItems'],_0x5cb7ee[_0x4ce7d9('0x169f')][_0x4ce7d9('0x1378')],'id'),_0x3c9e83();})[_0x1944cb('0x130a')](function(_0x9536a7){_0x4af2ae(_0x9536a7);});});}function _0xd60897(){return _0x513a2a(function(_0x5b2a0f,_0x4bb169){const _0x30b6e8=a0_0x4e0a;return _0x1d6e4e['userProfileResource'][_0x30b6e8('0x1e6e')]({'sectionId':_0x5cb7ee[_0x30b6e8('0x1aa')]['id'],'nolimit':!![]})['$promise'][_0x30b6e8('0x683')](function(_0x5a4716){_0x5b2a0f(_0x5a4716);})[_0x30b6e8('0x130a')](function(_0xff746a){_0x4bb169(_0xff746a);});});}function _0xf235e7(){return _0x513a2a(function(_0x23d371,_0xde22d5){const _0x34e885=a0_0x4e0a;return _0x1d6e4e['mailQueue'][_0x34e885('0xf90')]({'id':_0x5cb7ee[_0x34e885('0x2160')]['id'],'fields':_0x34e885('0xa10'),'nolimit':!![]})[_0x34e885('0xe53')][_0x34e885('0x683')](function(_0x37acd6){_0x23d371(_0x37acd6);})[_0x34e885('0x130a')](function(_0x3d6c5d){_0xde22d5(_0x3d6c5d);});});}function _0x409e40(){return _0x513a2a(function(_0x29c1dc,_0x1674a8){const _0x2ae2df=a0_0x4e0a;return _0x1d6e4e[_0x2ae2df('0xd88')][_0x2ae2df('0x1e6e')]({'fields':_0x2ae2df('0xa10'),'nolimit':!![]})['$promise']['then'](function(_0x5b4d2e){_0x29c1dc(_0x5b4d2e);})[_0x2ae2df('0x130a')](function(_0x199f49){_0x1674a8(_0x199f49);});});}function _0xd09471(_0xe3143f){return _0x513a2a(function(_0x206451,_0x344eae){const _0x14fc16=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0xe3143f)?_0x206451():_0x1d6e4e[_0x14fc16('0x2160')]['addTeams']({'id':_0x5cb7ee[_0x14fc16('0x2160')]['id'],'ids':_0x2e3ca0()[_0x14fc16('0x386')](_0xe3143f,'id')})[_0x14fc16('0xe53')][_0x14fc16('0x683')](function(){_0x206451();})['catch'](function(_0x1cd423){_0x344eae(_0x1cd423);});});}function _0x3d3f78(_0xbb73e8){return _0x513a2a(function(_0x5cfc4c,_0x2e1ead){const _0x37e8ce=a0_0x4e0a;_0x2e3ca0()[_0x37e8ce('0x173f')](_0xbb73e8)?_0x5cfc4c():_0x1d6e4e['mailQueue'][_0x37e8ce('0x2521')]({'id':_0x5cb7ee[_0x37e8ce('0x2160')]['id'],'ids':_0x2e3ca0()[_0x37e8ce('0x386')](_0xbb73e8,'id')})[_0x37e8ce('0xe53')]['then'](function(){_0x5cfc4c();})[_0x37e8ce('0x130a')](function(_0x9ec5a7){_0x2e1ead(_0x9ec5a7);});});}function _0x55062f(){const _0x47a85f=_0x11a2f7,_0x5c5070=_0x2e3ca0()[_0x47a85f('0x461')](_0x5cb7ee[_0x47a85f('0x23a7')],_0x5cb7ee[_0x47a85f('0x1378')],'id'),_0xd1f50b=_0x2e3ca0()['differenceBy'](_0x5cb7ee[_0x47a85f('0x1378')],_0x5cb7ee[_0x47a85f('0x23a7')],'id');return _0x3d3f78(_0x5c5070)[_0x47a85f('0x683')](function(){return _0xd09471(_0xd1f50b);})[_0x47a85f('0x683')](function(){const _0x4226a0=_0x47a85f;_0x5cb7ee[_0x4226a0('0x2106')]=![],_0x5cb7ee['startingAllowedItems']=angular[_0x4226a0('0x1a86')](_0x5cb7ee['allowedItems']),_0x5cb7ee[_0x4226a0('0x23a7')]=angular[_0x4226a0('0x1a86')](_0x5cb7ee[_0x4226a0('0x1378')]),_0x238142[_0x4226a0('0x53')]({'title':'SUCCESS','msg':'Teams\x20association\x20has\x20been\x20updated!'});})['catch'](function(_0x16a99d){const _0x2572c4=_0x47a85f;_0x238142[_0x2572c4('0x52a')]({'title':_0x16a99d[_0x2572c4('0x13ee')]?'API:'+_0x16a99d['status']+'\x20-\x20'+_0x16a99d[_0x2572c4('0x24a9')]:_0x2572c4('0x1b71'),'msg':_0x16a99d[_0x2572c4('0x13ee')]?JSON[_0x2572c4('0x258a')](_0x16a99d[_0x2572c4('0x5a5')]):_0x16a99d['toString']()});});}function _0x117241(){const _0x29906f=_0x11a2f7;_0x11284c[_0x29906f('0x1715')]();}}const _0xefbda5=_0x166a57,_0x430071=_0x180212['p']+'src/js/modules/main/apps/mail/views/mailQueues/edit/teamadd/teamadd.html/teamadd.html';_0x8cc69f[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),'setting','api',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x2160'),_0x189033('0x22df')];function _0x8cc69f(_0x48ffda,_0x23d7d5,_0x1c1419,_0x17c639,_0x40d2bb,_0x4f86a6,_0x584ad3,_0x51cc20,_0x1fbc08,_0x2c8fb2,_0x2e152e,_0x232a9f){const _0x2c6791=_0x189033,_0x4dcd3f=this;_0x4dcd3f[_0x2c6791('0x11ed')]=_0x2c8fb2[_0x2c6791('0x20b2')](),_0x4dcd3f[_0x2c6791('0xace')]=_0x4f86a6,_0x4dcd3f['setting']=_0x584ad3,_0x4dcd3f[_0x2c6791('0x19b2')]=_0x4dcd3f[_0x2c6791('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4dcd3f[_0x2c6791('0x1224')]=_0x23d7d5[_0x2c6791('0x173e')]()+'://'+_0x23d7d5[_0x2c6791('0x19ac')](),_0x4dcd3f[_0x2c6791('0x2160')]=_0x2e152e||_0x48ffda[_0x2c6791('0x7f2')][_0x2c6791('0x2160')]||{},_0x4dcd3f['userProfileSection']=_0x232a9f&&_0x232a9f[_0x2c6791('0x50d')]==0x1?_0x232a9f[_0x2c6791('0xf5d')][0x0]:null,_0x4dcd3f[_0x2c6791('0x1134')]=_0x2c8fb2['parseCrudPermissions'](_0x4dcd3f[_0x2c6791('0x22df')]?_0x4dcd3f[_0x2c6791('0x22df')][_0x2c6791('0x1134')]:null),_0x4dcd3f['hasModulePermissions']={},_0x4dcd3f[_0x2c6791('0x517')]=_0x48ffda[_0x2c6791('0x7f2')][_0x2c6791('0x1904')]||0x0,_0x4dcd3f[_0x2c6791('0xe0e')]=_0x480e0b,_0x4dcd3f[_0x2c6791('0x2814')]=_0x1b9f4b,_0x4dcd3f[_0x2c6791('0x2430')]=_0x1fbc08[_0x2c6791('0x2289')],_0x4dcd3f[_0x2c6791('0xd45')]=_0x4ed1c6,_0x4dcd3f[_0x2c6791('0x43')]=_0x562907;function _0x480e0b(_0x14f219,_0x49cd00){const _0x1cf831=_0x2c6791;_0x1c1419[_0x1cf831('0x1d4')]({'controller':_0x1cf831('0x78d'),'controllerAs':'vm','templateUrl':_0x430071,'parent':angular[_0x1cf831('0x1fcc')](_0x17c639[_0x1cf831('0x18e5')]),'targetEvent':_0x49cd00,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x14f219,'mailQueues':_0x4dcd3f['mailQueues']?_0x4dcd3f[_0x1cf831('0xc05')]['rows']:[],'crudPermissions':_0x4dcd3f['crudPermissions']}});}function _0x1b9f4b(_0x1e8cf3,_0x524203){const _0x6fa3ae=_0x2c6791;_0x1c1419['show']({'controller':'MailQueueagentaddController','controllerAs':'vm','templateUrl':_0x3dcb38,'parent':angular[_0x6fa3ae('0x1fcc')](_0x17c639['body']),'targetEvent':_0x524203,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x1e8cf3,'mailQueues':_0x4dcd3f[_0x6fa3ae('0xc05')]?_0x4dcd3f[_0x6fa3ae('0xc05')][_0x6fa3ae('0xf5d')]:[],'crudPermissions':_0x4dcd3f[_0x6fa3ae('0x1134')],'realtime':![]}});}function _0x4ed1c6(){const _0x5e5688=_0x2c6791;_0x48ffda['go'](_0x5e5688('0x2b'),{},{'reload':_0x5e5688('0x2b')});}function _0x562907(){const _0x5c310d=_0x2c6791;_0x51cc20[_0x5c310d('0x2160')][_0x5c310d('0x2480')]({'id':_0x4dcd3f[_0x5c310d('0x2160')]['id']},_0x4dcd3f[_0x5c310d('0x2160')])['$promise']['then'](function(){const _0xce1050=_0x5c310d;_0x1fbc08[_0xce1050('0x53')]({'title':'MailQueue\x20updated!','msg':_0x4dcd3f['mailQueue'][_0xce1050('0x60a')]?_0x4dcd3f[_0xce1050('0x2160')][_0xce1050('0x60a')]+'\x20has\x20been\x20updated!':''});})[_0x5c310d('0x130a')](function(_0x29ee97){const _0x38066b=_0x5c310d;_0x1fbc08[_0x38066b('0x52a')]({'title':_0x29ee97[_0x38066b('0x13ee')]?_0x38066b('0x2168')+_0x29ee97[_0x38066b('0x13ee')]+'\x20-\x20'+_0x29ee97['statusText']:_0x38066b('0x8b4'),'msg':_0x29ee97[_0x38066b('0x5a5')]?JSON[_0x38066b('0x258a')](_0x29ee97['data']):_0x29ee97[_0x38066b('0x1ff0')]()});});}}const _0x2bd6ee=_0x8cc69f;_0x4c4e30['$inject']=['$scope',_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),'$translate',_0x189033('0xc05'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),'toasty',_0x189033('0xba1'),'license','setting'];function _0x4c4e30(_0x1340d2,_0x290fb2,_0x20d804,_0xe8a9d9,_0x50e401,_0x528e62,_0x43e026,_0x578e25,_0x288099,_0x525a50,_0x18c910,_0x10ac12,_0x2a5ce4,_0x45496a,_0x46e636,_0x44b226,_0x21bd14){const _0x2120c6=_0x189033,_0x803ddf=this;_0x803ddf[_0x2120c6('0xace')]=_0x44b226,_0x803ddf[_0x2120c6('0x260a')]=_0x21bd14,_0x803ddf[_0x2120c6('0x11ed')]=_0x46e636['getCurrentUser'](),_0x803ddf[_0x2120c6('0xc05')]=_0x288099||{'count':0x0,'rows':[]},_0x803ddf[_0x2120c6('0x2a')]=_0x525a50,_0x803ddf[_0x2120c6('0x22df')]=_0x18c910&&_0x18c910[_0x2120c6('0x50d')]==0x1?_0x18c910['rows'][0x0]:null,_0x803ddf['crudPermissions']=_0x46e636[_0x2120c6('0x142a')](_0x803ddf[_0x2120c6('0x22df')]?_0x803ddf[_0x2120c6('0x22df')][_0x2120c6('0x1134')]:null),_0x803ddf[_0x2120c6('0x5c4')]=_0x2120c6('0xc05'),_0x803ddf['listOrder']='',_0x803ddf['listOrderAsc']=null,_0x803ddf[_0x2120c6('0x81a')]=[],_0x803ddf[_0x2120c6('0x23a2')]={'fields':_0x2120c6('0x1b67'),'sort':_0x2120c6('0xc36'),'channel':_0x2120c6('0x129f'),'limit':0xa,'page':0x1},_0x803ddf[_0x2120c6('0x21de')]=_0x2e3ca0()[_0x2120c6('0x24db')]([{'option':_0x2120c6('0x953'),'value':'\x27beepall\x27'},{'option':_0x2120c6('0x15cd'),'value':_0x2120c6('0x4ab')}],function(_0x25a4b3){const _0x461d01=_0x2120c6;return _0x2e3ca0()[_0x461d01('0x1725')](_0x25a4b3['value'],new RegExp('\x27','g'),'');}),_0x803ddf[_0x2120c6('0xc63')]=_0x3cd4a6,_0x803ddf['teamadddialog']=_0x391e77,_0x803ddf[_0x2120c6('0x2814')]=_0xb20477,_0x803ddf[_0x2120c6('0x194f')]=_0x5bccd8,_0x803ddf[_0x2120c6('0x213c')]=_0x38d468,_0x803ddf[_0x2120c6('0x53')]=_0x371a4c,_0x803ddf[_0x2120c6('0x4b7')]=_0x11f131,_0x803ddf['createOrEditMailQueue']=_0x5e2c8d,_0x803ddf[_0x2120c6('0x1761')]=_0x4982ae,_0x803ddf[_0x2120c6('0x20d0')]=_0x4c50d4,_0x803ddf[_0x2120c6('0xb1c')]=_0x45dc93,_0x803ddf[_0x2120c6('0x2733')]=_0x114f26,_0x803ddf['selectAllMailQueues']=_0x141541;function _0x3cd4a6(_0xe0ae36){const _0xf59768=_0x2120c6;_0x20d804['go'](_0xf59768('0x1609'),{'id':_0xe0ae36['id'],'mailQueue':_0xe0ae36,'crudPermissions':_0x803ddf[_0xf59768('0x1134')]});}function _0x391e77(_0x276595,_0x2a3f5a){const _0x53bd7a=_0x2120c6;_0x50e401[_0x53bd7a('0x1d4')]({'controller':_0x53bd7a('0x78d'),'controllerAs':'vm','templateUrl':_0x430071,'parent':angular[_0x53bd7a('0x1fcc')](_0x528e62[_0x53bd7a('0x18e5')]),'targetEvent':_0x2a3f5a,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x276595,'mailQueues':_0x803ddf[_0x53bd7a('0xc05')]?_0x803ddf[_0x53bd7a('0xc05')]['rows']:[],'crudPermissions':_0x803ddf[_0x53bd7a('0x1134')]}});}function _0xb20477(_0xa5f305,_0x10794f){const _0x5358c9=_0x2120c6;_0x50e401[_0x5358c9('0x1d4')]({'controller':_0x5358c9('0x99a'),'controllerAs':'vm','templateUrl':_0x3dcb38,'parent':angular[_0x5358c9('0x1fcc')](_0x528e62['body']),'targetEvent':_0x10794f,'clickOutsideToClose':!![],'locals':{'mailQueue':_0xa5f305,'mailQueues':_0x803ddf[_0x5358c9('0xc05')]?_0x803ddf['mailQueues'][_0x5358c9('0xf5d')]:[],'crudPermissions':_0x803ddf['crudPermissions'],'realtime':![]}});}function _0x5bccd8(_0x1fd494,_0x11aab2){const _0x5ea48f=_0x2120c6,_0x5cfcab=_0x50e401[_0x5ea48f('0x1c6f')]()[_0x5ea48f('0xf28')](_0x5ea48f('0x1b01')+_0x2e3ca0()['startCase']('mailQueue')+'?')['htmlContent'](_0x5ea48f('0xed5')+(_0x1fd494[_0x5ea48f('0x60a')]||_0x5ea48f('0x2160'))+_0x5ea48f('0x20f1')+_0x5ea48f('0x1ee7'))[_0x5ea48f('0x1040')](_0x5ea48f('0xdc1'))['targetEvent'](_0x11aab2)['ok']('OK')[_0x5ea48f('0x19fb')](_0x5ea48f('0x16b8'));_0x50e401[_0x5ea48f('0x1d4')](_0x5cfcab)[_0x5ea48f('0x683')](function(){_0x4982ae(_0x1fd494);},function(){const _0x3357b0=_0x5ea48f;console[_0x3357b0('0x1b2b')]('CANCEL');});}function _0x38d468(){const _0x3f5823=_0x2120c6;if(_0x46e636[_0x3f5823('0xca1')](_0x3f5823('0x20c2')))_0x20d804['go'](_0x3f5823('0x462'),{});else return _0x10ac12[_0x3f5823('0x22df')][_0x3f5823('0x1e6e')]({'userProfileId':_0x46e636[_0x3f5823('0x20b2')]()[_0x3f5823('0x2f')],'sectionId':0x262})['$promise'][_0x3f5823('0x683')](function(_0x3828f0){const _0x42eecc=_0x3f5823,_0x53b684=_0x3828f0&&_0x3828f0['rows']?_0x3828f0[_0x42eecc('0xf5d')][0x0]:null;_0x53b684&&_0x53b684[_0x42eecc('0x1333')]?_0x20d804['go'](_0x42eecc('0x462'),{}):_0x45496a[_0x42eecc('0x2289')]({'title':_0x578e25[_0x42eecc('0x2728')](_0x42eecc('0x213e')),'msg':_0x578e25['instant'](_0x42eecc('0xdba'))});})[_0x3f5823('0x130a')](function(_0xe81395){const _0x1d0111=_0x3f5823;_0x45496a['error']({'title':_0xe81395[_0x1d0111('0x13ee')]?_0x1d0111('0x2168')+_0xe81395[_0x1d0111('0x13ee')]+_0x1d0111('0xbf6')+_0xe81395[_0x1d0111('0x24a9')]:'USERPROFILE:GET_SECTION','msg':_0xe81395['status']?JSON['stringify'](_0xe81395[_0x1d0111('0x5a5')]):_0xe81395[_0x1d0111('0x1ff0')]()});});}let _0x14d912=!![],_0xebd4ac=0x1;_0x1340d2[_0x2120c6('0x186d')](_0x2120c6('0x1e1d'),function(_0x19bb16,_0x41501f){const _0x3d11a3=_0x2120c6;_0x14d912?_0x43e026(function(){_0x14d912=![];}):(!_0x41501f&&(_0xebd4ac=_0x803ddf['query'][_0x3d11a3('0xdf8')]),_0x19bb16!==_0x41501f&&(_0x803ddf[_0x3d11a3('0x23a2')][_0x3d11a3('0xdf8')]=0x1),!_0x19bb16&&(_0x803ddf[_0x3d11a3('0x23a2')][_0x3d11a3('0xdf8')]=_0xebd4ac),_0x803ddf[_0x3d11a3('0x4b7')]());});function _0x371a4c(_0x53a6b5){const _0x1dd841=_0x2120c6;_0x803ddf[_0x1dd841('0xc05')]=_0x53a6b5||{'count':0x0,'rows':[]};}function _0x11f131(){const _0x276d4e=_0x2120c6;_0x803ddf[_0x276d4e('0x23a2')]['offset']=(_0x803ddf[_0x276d4e('0x23a2')]['page']-0x1)*_0x803ddf['query'][_0x276d4e('0x6f0')],_0x46e636['hasRole'](_0x276d4e('0x20c2'))?_0x803ddf[_0x276d4e('0x1883')]=_0x10ac12[_0x276d4e('0x2160')][_0x276d4e('0x1e6e')](_0x803ddf[_0x276d4e('0x23a2')],_0x371a4c)[_0x276d4e('0xe53')]:(_0x803ddf[_0x276d4e('0x23a2')]['id']=_0x803ddf[_0x276d4e('0x2a')]['id'],_0x803ddf[_0x276d4e('0x23a2')][_0x276d4e('0x1aa')]='MailQueues',_0x803ddf[_0x276d4e('0x1883')]=_0x10ac12[_0x276d4e('0x2a')]['getResources'](_0x803ddf[_0x276d4e('0x23a2')],_0x371a4c)[_0x276d4e('0xe53')]);}function _0x5e2c8d(_0x27990c,_0x38d4c2){const _0x485574=_0x2120c6;_0x50e401['show']({'controller':_0x485574('0x1bdb'),'controllerAs':'vm','templateUrl':_0x51e294,'parent':angular[_0x485574('0x1fcc')](_0x528e62[_0x485574('0x18e5')]),'targetEvent':_0x27990c,'clickOutsideToClose':!![],'locals':{'mailQueue':_0x38d4c2,'mailQueues':_0x803ddf[_0x485574('0xc05')]['rows'],'license':_0x803ddf[_0x485574('0xace')],'setting':_0x803ddf[_0x485574('0x260a')],'crudPermissions':_0x803ddf[_0x485574('0x1134')]}});}function _0x4982ae(_0x401ef5){const _0x3deb7c=_0x2120c6;_0x10ac12[_0x3deb7c('0x2160')][_0x3deb7c('0xd7e')]({'id':_0x401ef5['id']})[_0x3deb7c('0xe53')]['then'](function(){const _0x53f785=_0x3deb7c;_0x2e3ca0()[_0x53f785('0x3ec')](_0x803ddf[_0x53f785('0xc05')][_0x53f785('0xf5d')],{'id':_0x401ef5['id']}),_0x803ddf[_0x53f785('0xc05')][_0x53f785('0x50d')]-=0x1,!_0x803ddf[_0x53f785('0xc05')][_0x53f785('0xf5d')][_0x53f785('0x1564')]&&_0x803ddf['getMailQueues'](),_0x45496a['success']({'title':_0x2e3ca0()['startCase'](_0x53f785('0xc03'))+_0x53f785('0xbfc'),'msg':_0x401ef5[_0x53f785('0x60a')]?_0x401ef5['name']+_0x53f785('0x194d'):''});})[_0x3deb7c('0x130a')](function(_0x92d1e6){const _0x585e78=_0x3deb7c;if(_0x92d1e6[_0x585e78('0x5a5')]&&_0x92d1e6[_0x585e78('0x5a5')][_0x585e78('0x17f')]&&_0x92d1e6[_0x585e78('0x5a5')][_0x585e78('0x17f')][_0x585e78('0x1564')]){_0x803ddf['errors']=_0x92d1e6[_0x585e78('0x5a5')][_0x585e78('0x17f')]||[{'message':_0x92d1e6[_0x585e78('0x1ff0')](),'type':_0x585e78('0x2593')}];for(let _0x4bf336=0x0;_0x4bf336<_0x92d1e6['data']['errors'][_0x585e78('0x1564')];_0x4bf336++){_0x45496a[_0x585e78('0x52a')]({'title':_0x92d1e6[_0x585e78('0x5a5')][_0x585e78('0x17f')][_0x4bf336][_0x585e78('0xcf0')],'msg':_0x92d1e6[_0x585e78('0x5a5')][_0x585e78('0x17f')][_0x4bf336]['message']});}}else _0x45496a['error']({'title':_0x92d1e6['status']?_0x585e78('0x2168')+_0x92d1e6[_0x585e78('0x13ee')]+'\x20-\x20'+_0x92d1e6[_0x585e78('0x24a9')]:'SYSTEM:DELETEmailQueue','msg':_0x92d1e6['data']?JSON['stringify'](_0x92d1e6[_0x585e78('0x5a5')][_0x585e78('0x8c2')]):_0x92d1e6[_0x585e78('0x8c2')]||_0x92d1e6[_0x585e78('0x1ff0')]()});});}function _0x4c50d4(){const _0x16279e=_0x2120c6,_0x11bf3f=angular[_0x16279e('0x1a86')](_0x803ddf[_0x16279e('0x81a')]);return _0x803ddf['selectedMailQueues']=[],_0x11bf3f;}function _0x45dc93(_0x590e68){const _0xab87a6=_0x2120c6,_0x259365=_0x50e401[_0xab87a6('0x1c6f')]()[_0xab87a6('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20mailQueues?')[_0xab87a6('0x26e3')](_0xab87a6('0xed5')+_0x803ddf[_0xab87a6('0x81a')][_0xab87a6('0x1564')]+_0xab87a6('0x93c')+_0xab87a6('0x1ee7'))[_0xab87a6('0x1040')]('delete\x20MailQueues')[_0xab87a6('0xe42')](_0x590e68)['ok']('OK')['cancel'](_0xab87a6('0x16b8'));_0x50e401[_0xab87a6('0x1d4')](_0x259365)['then'](function(){const _0x3623ed=_0xab87a6;_0x803ddf['selectedMailQueues'][_0x3623ed('0x1299')](function(_0x25bb38){_0x4982ae(_0x25bb38);}),_0x803ddf['selectedMailQueues']=[];});}function _0x114f26(){const _0x3d3d1d=_0x2120c6;_0x803ddf[_0x3d3d1d('0x81a')]=[];}function _0x141541(){const _0x35fb4a=_0x2120c6;_0x803ddf[_0x35fb4a('0x81a')]=_0x803ddf[_0x35fb4a('0xc05')][_0x35fb4a('0xf5d')];}}const _0x538648=_0x4c4e30;_0x504777[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x883'),_0x189033('0x1577'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x504777(_0x103493,_0x3164dc,_0x37aa5f,_0x395b1b,_0x4781d2,_0x153ead,_0x2e7a20,_0x79395f,_0x27f3ea,_0x39e3af,_0x1b8536,_0x31037b,_0x4d1a60,_0x4ec4d3){const _0xaa12b6=_0x189033,_0x47d2cc=this;_0x47d2cc[_0xaa12b6('0x11ed')]=_0x1b8536[_0xaa12b6('0x20b2')](),_0x47d2cc[_0xaa12b6('0x17f')]=[],_0x47d2cc[_0xaa12b6('0x260a')]=_0x4d1a60,_0x47d2cc['license']=_0x31037b,_0x47d2cc[_0xaa12b6('0x1134')]=_0x4ec4d3,_0x47d2cc[_0xaa12b6('0x258d')]={},_0x47d2cc[_0xaa12b6('0x19b2')]=_0x47d2cc[_0xaa12b6('0x260a')]&&_0x47d2cc[_0xaa12b6('0x260a')][_0xaa12b6('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x47d2cc['title']='MAIL.EDIT_MAILSUBSTATUS',_0x47d2cc[_0xaa12b6('0x1577')]=angular['copy'](_0x27f3ea),_0x47d2cc[_0xaa12b6('0x883')]=_0x79395f,_0x47d2cc[_0xaa12b6('0xd5c')]=![];!_0x47d2cc[_0xaa12b6('0x1577')]&&(_0x47d2cc['mailSubstatus']={},_0x47d2cc['title']=_0xaa12b6('0x195'),_0x47d2cc[_0xaa12b6('0xd5c')]=!![]);_0x47d2cc['addNewMailSubstatus']=_0x318d64,_0x47d2cc[_0xaa12b6('0x30d')]=_0x13aea2,_0x47d2cc[_0xaa12b6('0x12cd')]=_0x401600,_0x47d2cc[_0xaa12b6('0x16b3')]=_0x36fefa,_0x47d2cc['closeDialog']=_0x18ba85;function _0x318d64(){const _0x2f8a52=_0xaa12b6;_0x47d2cc[_0x2f8a52('0x17f')]=[],_0x39e3af[_0x2f8a52('0x1577')]['save'](_0x47d2cc[_0x2f8a52('0x1577')])[_0x2f8a52('0xe53')][_0x2f8a52('0x683')](function(_0x2bfa47){const _0x91c3d9=_0x2f8a52;_0x47d2cc[_0x91c3d9('0x883')][_0x91c3d9('0x1167')](_0x2bfa47[_0x91c3d9('0x24e1')]()),_0x2e7a20[_0x91c3d9('0x53')]({'title':_0x91c3d9('0x4a7'),'msg':_0x47d2cc[_0x91c3d9('0x1577')]['name']?_0x47d2cc[_0x91c3d9('0x1577')][_0x91c3d9('0x60a')]+_0x91c3d9('0x14b5'):''}),_0x18ba85(_0x2bfa47);})[_0x2f8a52('0x130a')](function(_0x4278ee){const _0x3a744a=_0x2f8a52;if(_0x4278ee['data']&&_0x4278ee[_0x3a744a('0x5a5')]['errors']&&_0x4278ee[_0x3a744a('0x5a5')][_0x3a744a('0x17f')][_0x3a744a('0x1564')]){_0x47d2cc[_0x3a744a('0x17f')]=_0x4278ee['data'][_0x3a744a('0x17f')]||[{'message':_0x4278ee['toString'](),'type':_0x3a744a('0x14e0')}];for(let _0x1f9b25=0x0;_0x1f9b25<_0x4278ee['data'][_0x3a744a('0x17f')][_0x3a744a('0x1564')];_0x1f9b25+=0x1){_0x2e7a20[_0x3a744a('0x52a')]({'title':_0x4278ee[_0x3a744a('0x5a5')][_0x3a744a('0x17f')][_0x1f9b25][_0x3a744a('0xcf0')],'msg':_0x4278ee[_0x3a744a('0x5a5')][_0x3a744a('0x17f')][_0x1f9b25][_0x3a744a('0x8c2')]});}}else _0x2e7a20[_0x3a744a('0x52a')]({'title':_0x4278ee[_0x3a744a('0x13ee')]?'API:'+_0x4278ee[_0x3a744a('0x13ee')]+_0x3a744a('0xbf6')+_0x4278ee[_0x3a744a('0x24a9')]:_0x3a744a('0x14e0'),'msg':_0x4278ee['data']?JSON[_0x3a744a('0x258a')](_0x4278ee['data'][_0x3a744a('0x8c2')]):_0x4278ee[_0x3a744a('0x1ff0')]()});});}function _0x13aea2(){const _0x7b7663=_0xaa12b6;_0x47d2cc[_0x7b7663('0x17f')]=[],_0x39e3af['mailSubstatus'][_0x7b7663('0x2480')]({'id':_0x47d2cc[_0x7b7663('0x1577')]['id']},_0x47d2cc[_0x7b7663('0x1577')])[_0x7b7663('0xe53')]['then'](function(_0xa92f6){const _0x324eac=_0x7b7663,_0x486698=_0x2e3ca0()[_0x324eac('0x1c07')](_0x47d2cc[_0x324eac('0x883')],{'id':_0xa92f6['id']});_0x486698&&_0x2e3ca0()[_0x324eac('0xf22')](_0x486698,_0x2e3ca0()[_0x324eac('0x24d0')](_0xa92f6[_0x324eac('0x24e1')](),_0x2e3ca0()['keys'](_0x486698))),_0x2e7a20['success']({'title':'MailSubstatus\x20properly\x20saved!','msg':_0x47d2cc[_0x324eac('0x1577')][_0x324eac('0x60a')]?_0x47d2cc['mailSubstatus'][_0x324eac('0x60a')]+_0x324eac('0xf59'):''}),_0x18ba85(_0xa92f6);})[_0x7b7663('0x130a')](function(_0x2ff1ac){const _0x46a338=_0x7b7663;if(_0x2ff1ac[_0x46a338('0x5a5')]&&_0x2ff1ac['data']['errors']&&_0x2ff1ac['data'][_0x46a338('0x17f')][_0x46a338('0x1564')]){_0x47d2cc[_0x46a338('0x17f')]=_0x2ff1ac[_0x46a338('0x5a5')][_0x46a338('0x17f')]||[{'message':_0x2ff1ac[_0x46a338('0x1ff0')](),'type':_0x46a338('0x1d72')}];for(let _0x20c7fa=0x0;_0x20c7fa<_0x2ff1ac[_0x46a338('0x5a5')]['errors'][_0x46a338('0x1564')];_0x20c7fa++){_0x2e7a20[_0x46a338('0x52a')]({'title':_0x2ff1ac[_0x46a338('0x5a5')][_0x46a338('0x17f')][_0x20c7fa][_0x46a338('0xcf0')],'msg':_0x2ff1ac[_0x46a338('0x5a5')]['errors'][_0x20c7fa][_0x46a338('0x8c2')]});}}else _0x2e7a20[_0x46a338('0x52a')]({'title':_0x2ff1ac['status']?_0x46a338('0x2168')+_0x2ff1ac[_0x46a338('0x13ee')]+_0x46a338('0xbf6')+_0x2ff1ac['statusText']:_0x46a338('0x1d72'),'msg':_0x2ff1ac[_0x46a338('0x5a5')]?JSON['stringify'](_0x2ff1ac['data']['message']):_0x2ff1ac[_0x46a338('0x1ff0')]()});});}function _0x401600(_0x514622){const _0xfb1bb1=_0xaa12b6;_0x47d2cc['errors']=[];const _0x5a6d97=_0x395b1b[_0xfb1bb1('0x1c6f')]()[_0xfb1bb1('0xf28')](_0xfb1bb1('0x4d'))[_0xfb1bb1('0xa6a')](_0xfb1bb1('0x223f'))[_0xfb1bb1('0x1040')](_0xfb1bb1('0x34d'))['ok'](_0xfb1bb1('0x2307'))[_0xfb1bb1('0x19fb')](_0xfb1bb1('0x253a'))[_0xfb1bb1('0xe42')](_0x514622);_0x395b1b[_0xfb1bb1('0x1d4')](_0x5a6d97)['then'](function(){const _0x1b1152=_0xfb1bb1;_0x39e3af['mailSubstatus'][_0x1b1152('0xd7e')]({'id':_0x47d2cc['mailSubstatus']['id']})['$promise'][_0x1b1152('0x683')](function(){const _0x4f9611=_0x1b1152;_0x2e3ca0()[_0x4f9611('0x3ec')](_0x47d2cc['mailSubtatuses'],{'id':_0x47d2cc['mailSubstatus']['id']}),_0x2e7a20[_0x4f9611('0x53')]({'title':_0x4f9611('0x1e60'),'msg':(_0x47d2cc['mailSubstatus'][_0x4f9611('0x60a')]||_0x4f9611('0x1577'))+_0x4f9611('0x194d')}),_0x18ba85(_0x47d2cc[_0x4f9611('0x1577')]);})['catch'](function(_0x5e6ec8){const _0x2ca185=_0x1b1152;if(_0x5e6ec8['data']&&_0x5e6ec8[_0x2ca185('0x5a5')][_0x2ca185('0x17f')]&&_0x5e6ec8[_0x2ca185('0x5a5')][_0x2ca185('0x17f')][_0x2ca185('0x1564')]){_0x47d2cc[_0x2ca185('0x17f')]=_0x5e6ec8[_0x2ca185('0x5a5')][_0x2ca185('0x17f')]||[{'message':_0x5e6ec8['toString'](),'type':_0x2ca185('0x17dd')}];for(let _0x4bea4e=0x0;_0x4bea4e<_0x5e6ec8[_0x2ca185('0x5a5')][_0x2ca185('0x17f')][_0x2ca185('0x1564')];_0x4bea4e++){_0x2e7a20[_0x2ca185('0x52a')]({'title':_0x5e6ec8['data'][_0x2ca185('0x17f')][_0x4bea4e][_0x2ca185('0xcf0')],'msg':_0x5e6ec8[_0x2ca185('0x5a5')]['errors'][_0x4bea4e][_0x2ca185('0x8c2')]});}}else _0x2e7a20[_0x2ca185('0x52a')]({'title':_0x5e6ec8[_0x2ca185('0x13ee')]?_0x2ca185('0x2168')+_0x5e6ec8['status']+_0x2ca185('0xbf6')+_0x5e6ec8[_0x2ca185('0x24a9')]:'api.mailSubstatus.delete','msg':_0x5e6ec8[_0x2ca185('0x5a5')]?JSON[_0x2ca185('0x258a')](_0x5e6ec8[_0x2ca185('0x5a5')][_0x2ca185('0x8c2')]):_0x5e6ec8[_0x2ca185('0x8c2')]||_0x5e6ec8[_0x2ca185('0x1ff0')]()});});},function(){});}function _0x36fefa(_0x376a63){return _0x376a63===null?undefined:new Date(_0x376a63);}function _0x18ba85(_0x2edbf9){const _0x20c718=_0xaa12b6;_0x395b1b[_0x20c718('0x1715')](_0x2edbf9);}}const _0x43ef34=_0x504777,_0x1f780e=_0x180212['p']+_0x189033('0x280b');_0x22e551[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$window',_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x883'),_0x189033('0x2a'),_0x189033('0x22df'),'api',_0x189033('0x1cc2'),_0x189033('0x1d70'),'Auth','license',_0x189033('0x260a')];function _0x22e551(_0x154de0,_0x10dfe4,_0x66967,_0x203035,_0x24cb1d,_0x5763b9,_0x46f0dd,_0x323968,_0x1d956c,_0x2d1e47,_0x7a845e,_0x4a0933,_0x2129b7,_0x2b540b,_0x72ca33,_0x4f62ae,_0x386f0f){const _0x4cfc9d=_0x189033,_0x37969a=this;_0x37969a[_0x4cfc9d('0xace')]=_0x4f62ae,_0x37969a['setting']=_0x386f0f,_0x37969a[_0x4cfc9d('0x11ed')]=_0x72ca33['getCurrentUser'](),_0x37969a[_0x4cfc9d('0x883')]=_0x1d956c||{'count':0x0,'rows':[]},_0x37969a['userProfile']=_0x2d1e47,_0x37969a['userProfileSection']=_0x7a845e&&_0x7a845e[_0x4cfc9d('0x50d')]==0x1?_0x7a845e[_0x4cfc9d('0xf5d')][0x0]:null,_0x37969a['crudPermissions']=_0x72ca33[_0x4cfc9d('0x142a')](_0x37969a['userProfileSection']?_0x37969a[_0x4cfc9d('0x22df')][_0x4cfc9d('0x1134')]:null),_0x37969a[_0x4cfc9d('0x5c4')]=_0x4cfc9d('0x883'),_0x37969a[_0x4cfc9d('0x247')]='',_0x37969a[_0x4cfc9d('0x1ce2')]=null,_0x37969a[_0x4cfc9d('0xeb1')]=[],_0x37969a[_0x4cfc9d('0x23a2')]={'fields':_0x4cfc9d('0x120a'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x37969a[_0x4cfc9d('0x1249')]=_0x5b198b,_0x37969a[_0x4cfc9d('0x194f')]=_0x3f2bf9,_0x37969a[_0x4cfc9d('0x53')]=_0x541c54,_0x37969a[_0x4cfc9d('0xbb')]=_0x5c50ba,_0x37969a['createOrEditMailSubstatus']=_0x33ed12,_0x37969a[_0x4cfc9d('0x12cd')]=_0x42e5d0,_0x37969a[_0x4cfc9d('0xcfa')]=_0x3f2183,_0x37969a[_0x4cfc9d('0xb19')]=_0x208802,_0x37969a[_0x4cfc9d('0x8f9')]=_0x537da9,_0x37969a[_0x4cfc9d('0x984')]=_0x4753b0;function _0x5b198b(_0x44497b,_0xc86a62){const _0x4a3186=_0x4cfc9d;_0x24cb1d[_0x4a3186('0x1d4')]({'controller':_0x4a3186('0x1c2f'),'controllerAs':'vm','templateUrl':_0x1f780e,'parent':angular['element'](_0x5763b9[_0x4a3186('0x18e5')]),'targetEvent':_0xc86a62,'clickOutsideToClose':!![],'locals':{'mailSubstatus':_0x44497b,'mailSubtatuses':_0x37969a[_0x4a3186('0x883')][_0x4a3186('0xf5d')],'license':_0x37969a[_0x4a3186('0xace')],'setting':null,'crudPermissions':_0x37969a[_0x4a3186('0x1134')]}});}function _0x3f2bf9(_0x31938d,_0xeda00b){const _0x55b2f5=_0x4cfc9d,_0x5c1f45=_0x24cb1d['confirm']()[_0x55b2f5('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x55b2f5('0x1e03')]('mailSubstatus')+'?')[_0x55b2f5('0x26e3')](_0x55b2f5('0xed5')+(_0x31938d['name']||_0x55b2f5('0x1577'))+_0x55b2f5('0x20f1')+_0x55b2f5('0x1ee7'))[_0x55b2f5('0x1040')](_0x55b2f5('0x1293'))[_0x55b2f5('0xe42')](_0xeda00b)['ok']('OK')[_0x55b2f5('0x19fb')](_0x55b2f5('0x16b8'));_0x24cb1d['show'](_0x5c1f45)['then'](function(){_0x42e5d0(_0x31938d);},function(){const _0x37fe33=_0x55b2f5;console[_0x37fe33('0x1b2b')](_0x37fe33('0x16b8'));});}let _0x4ee39f=!![],_0x1c22f3=0x1;_0x154de0[_0x4cfc9d('0x186d')]('vm.query.filter',function(_0x57bb6c,_0x44f4c9){const _0x210dbd=_0x4cfc9d;_0x4ee39f?_0x46f0dd(function(){_0x4ee39f=![];}):(!_0x44f4c9&&(_0x1c22f3=_0x37969a[_0x210dbd('0x23a2')][_0x210dbd('0xdf8')]),_0x57bb6c!==_0x44f4c9&&(_0x37969a[_0x210dbd('0x23a2')]['page']=0x1),!_0x57bb6c&&(_0x37969a[_0x210dbd('0x23a2')]['page']=_0x1c22f3),_0x37969a[_0x210dbd('0xbb')]());});function _0x541c54(_0x28bf33){const _0x33c14d=_0x4cfc9d;_0x37969a[_0x33c14d('0x883')]=_0x28bf33||{'count':0x0,'rows':[]};}function _0x5c50ba(){const _0x4bd603=_0x4cfc9d;_0x37969a[_0x4bd603('0x23a2')][_0x4bd603('0x1cc8')]=(_0x37969a[_0x4bd603('0x23a2')][_0x4bd603('0xdf8')]-0x1)*_0x37969a['query'][_0x4bd603('0x6f0')],_0x72ca33['hasRole'](_0x4bd603('0x20c2'))?_0x37969a['promise']=_0x4a0933['mailSubstatus'][_0x4bd603('0x1e6e')](_0x37969a[_0x4bd603('0x23a2')],_0x541c54)[_0x4bd603('0xe53')]:(_0x37969a['query']['id']=_0x37969a[_0x4bd603('0x2a')]['id'],_0x37969a[_0x4bd603('0x23a2')][_0x4bd603('0x1aa')]=_0x4bd603('0x233b'),_0x37969a[_0x4bd603('0x1883')]=_0x4a0933['userProfile']['getResources'](_0x37969a['query'],_0x541c54)[_0x4bd603('0xe53')]);}function _0x33ed12(_0x5a0ae4,_0x4d2bd9){const _0x10e6cd=_0x4cfc9d;_0x24cb1d[_0x10e6cd('0x1d4')]({'controller':_0x10e6cd('0x1c2f'),'controllerAs':'vm','templateUrl':_0x1f780e,'parent':angular['element'](_0x5763b9['body']),'targetEvent':_0x5a0ae4,'clickOutsideToClose':!![],'locals':{'mailSubstatus':_0x4d2bd9,'mailSubtatuses':_0x37969a[_0x10e6cd('0x883')][_0x10e6cd('0xf5d')],'license':_0x37969a[_0x10e6cd('0xace')],'setting':_0x37969a[_0x10e6cd('0x260a')],'crudPermissions':_0x37969a[_0x10e6cd('0x1134')]}});}function _0x42e5d0(_0x30f927){const _0x2f98da=_0x4cfc9d;_0x4a0933[_0x2f98da('0x1577')][_0x2f98da('0xd7e')]({'id':_0x30f927['id']})['$promise'][_0x2f98da('0x683')](function(){const _0x31647b=_0x2f98da;_0x2e3ca0()[_0x31647b('0x3ec')](_0x37969a['mailSubtatuses'][_0x31647b('0xf5d')],{'id':_0x30f927['id']}),_0x37969a[_0x31647b('0x883')][_0x31647b('0x50d')]-=0x1,!_0x37969a[_0x31647b('0x883')]['rows']['length']&&_0x37969a[_0x31647b('0xbb')](),_0x2b540b[_0x31647b('0x53')]({'title':_0x2e3ca0()['startCase']('MailSubstatus')+_0x31647b('0xbfc'),'msg':_0x30f927[_0x31647b('0x60a')]?_0x30f927[_0x31647b('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0x2f98da('0x130a')](function(_0x57684f){const _0x14b93b=_0x2f98da;if(_0x57684f[_0x14b93b('0x5a5')]&&_0x57684f[_0x14b93b('0x5a5')][_0x14b93b('0x17f')]&&_0x57684f[_0x14b93b('0x5a5')][_0x14b93b('0x17f')]['length']){_0x37969a[_0x14b93b('0x17f')]=_0x57684f[_0x14b93b('0x5a5')][_0x14b93b('0x17f')]||[{'message':_0x57684f['toString'](),'type':_0x14b93b('0xb5e')}];for(let _0x545970=0x0;_0x545970<_0x57684f[_0x14b93b('0x5a5')][_0x14b93b('0x17f')]['length'];_0x545970++){_0x2b540b[_0x14b93b('0x52a')]({'title':_0x57684f[_0x14b93b('0x5a5')][_0x14b93b('0x17f')][_0x545970][_0x14b93b('0xcf0')],'msg':_0x57684f[_0x14b93b('0x5a5')]['errors'][_0x545970]['message']});}}else _0x2b540b[_0x14b93b('0x52a')]({'title':_0x57684f[_0x14b93b('0x13ee')]?_0x14b93b('0x2168')+_0x57684f['status']+_0x14b93b('0xbf6')+_0x57684f[_0x14b93b('0x24a9')]:'SYSTEM:DELETEmailSubstatus','msg':_0x57684f[_0x14b93b('0x5a5')]?JSON[_0x14b93b('0x258a')](_0x57684f['data'][_0x14b93b('0x8c2')]):_0x57684f[_0x14b93b('0x8c2')]||_0x57684f[_0x14b93b('0x1ff0')]()});});}function _0x3f2183(){const _0x2b2f1a=_0x4cfc9d,_0xf7cd7e=angular[_0x2b2f1a('0x1a86')](_0x37969a[_0x2b2f1a('0xeb1')]);return _0x37969a[_0x2b2f1a('0xeb1')]=[],_0xf7cd7e;}function _0x208802(_0x59fb67){const _0x16352f=_0x4cfc9d,_0x336c67=_0x24cb1d[_0x16352f('0x1c6f')]()[_0x16352f('0xf28')](_0x16352f('0x164a'))[_0x16352f('0x26e3')](_0x16352f('0xed5')+_0x37969a[_0x16352f('0xeb1')][_0x16352f('0x1564')]+'\x20selected'+_0x16352f('0x1ee7'))[_0x16352f('0x1040')](_0x16352f('0x1760'))[_0x16352f('0xe42')](_0x59fb67)['ok']('OK')[_0x16352f('0x19fb')]('CANCEL');_0x24cb1d[_0x16352f('0x1d4')](_0x336c67)[_0x16352f('0x683')](function(){const _0x5ce19e=_0x16352f;_0x37969a[_0x5ce19e('0xeb1')]['forEach'](function(_0x2e3ad2){_0x42e5d0(_0x2e3ad2);}),_0x37969a[_0x5ce19e('0xeb1')]=[];});}function _0x537da9(){const _0x5e0e95=_0x4cfc9d;_0x37969a[_0x5e0e95('0xeb1')]=[];}function _0x4753b0(){const _0xf2f08c=_0x4cfc9d;_0x37969a[_0xf2f08c('0xeb1')]=_0x37969a[_0xf2f08c('0x883')]['rows'];}}const _0xf74477=_0x22e551;_0x26b849[_0x189033('0x14be')]=['$stateProvider',_0x189033('0x19ee')];function _0x26b849(_0x22d46d,_0x213b26){const _0xadf06=_0x189033;_0x22d46d['state'](_0xadf06('0x2427'),{'abstract':!![],'url':_0xadf06('0x1ea6')})['state'](_0xadf06('0x2b'),{'url':_0xadf06('0x12f7'),'views':{'content@app':{'templateUrl':_0x494001,'controller':'MailQueuesController\x20as\x20vm'}},'resolve':{'mailQueues':[_0xadf06('0x4b1'),_0xadf06('0xba1'),function(_0x1ee10e,_0x29e6ec){const _0x1ef72a=_0xadf06;return _0x29e6ec[_0x1ef72a('0xca1')]('admin')?_0x1ee10e[_0x1ef72a('0xed7')](_0x1ef72a('0x2846'),{'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','sort':_0x1ef72a('0xc36'),'channel':_0x1ef72a('0x129f'),'limit':0xa,'offset':0x0}):_0x1ee10e[_0x1ef72a('0xed7')](_0x1ef72a('0x191b'),{'id':_0x29e6ec[_0x1ef72a('0x20b2')]()[_0x1ef72a('0x2f')],'section':_0x1ef72a('0x97d'),'fields':_0x1ef72a('0x1b67'),'sort':'-updatedAt','channel':_0x1ef72a('0x129f'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0xadf06('0xba1'),function(_0x4e9fbe,_0x208b51){const _0x3cde80=_0xadf06;return _0x208b51['hasRole'](_0x3cde80('0x20c2'))?null:_0x4e9fbe[_0x3cde80('0xed7')](_0x3cde80('0x1464'),{'fields':_0x3cde80('0x16f'),'id':_0x208b51[_0x3cde80('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0xadf06('0x4b1'),'Auth',function(_0x6aa7c8,_0x47838a){const _0x57cf58=_0xadf06;return _0x47838a[_0x57cf58('0xca1')](_0x57cf58('0x20c2'))?null:_0x6aa7c8[_0x57cf58('0xed7')](_0x57cf58('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x47838a['getCurrentUser']()['userProfileId'],'sectionId':0x259});}]},'authenticate':!![],'permissionId':0x259,'bodyClass':_0xadf06('0x129f')})['state'](_0xadf06('0x1609'),{'url':_0xadf06('0x1560'),'params':{'mailQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x39b6c2,'controller':_0xadf06('0x819')}},'resolve':{'mailQueue':[_0xadf06('0x4b1'),_0xadf06('0x8ea'),function(_0x55e03b,_0x402ff3){const _0x2a1511=_0xadf06;return _0x55e03b[_0x2a1511('0xed7')](_0x2a1511('0x2846'),{'fields':_0x2a1511('0x1b67'),'id':_0x402ff3['id']});}],'userProfileSection':[_0xadf06('0x4b1'),_0xadf06('0xba1'),function(_0x35663d,_0x4f7716){const _0xd5139f=_0xadf06;return _0x35663d[_0xd5139f('0xed7')]('userProfileSection@get',{'fields':_0xd5139f('0x1f47'),'userProfileId':_0x4f7716[_0xd5139f('0x20b2')]()[_0xd5139f('0x2f')],'sectionId':0x259});}]},'authenticate':!![],'permissionId':0x259,'bodyClass':_0xadf06('0x129f')})['state'](_0xadf06('0x1b93'),{'url':'/mailAccounts','views':{'content@app':{'templateUrl':_0x3aa68e,'controller':_0xadf06('0xdb0')}},'resolve':{'mailAccounts':[_0xadf06('0x4b1'),_0xadf06('0xba1'),function(_0x6f50f0,_0x5a7bc9){const _0x5a734b=_0xadf06;return _0x5a7bc9[_0x5a734b('0xca1')](_0x5a734b('0x20c2'))?_0x6f50f0[_0x5a734b('0xed7')](_0x5a734b('0x2a9'),{'fields':'createdAt,updatedAt,id,name,key,email,ListId,active,cservice,Imap.service,Imap.host,Imap.port,Imap.tls,Imap.authentication,Imap.user,Imap.password,Imap.mailbox,Imap.connTimeout,Imap.authTimeout,Smtp.service,Smtp.host,Smtp.port,Smtp.secure,Smtp.authentication,Smtp.user,Smtp.pass,cauthentication,cuser,cpassword,fontFamily,fontSize,template,markAsUnread,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','sort':_0x5a734b('0xc36'),'limit':0xa,'offset':0x0}):_0x6f50f0['resolve'](_0x5a734b('0x191b'),{'id':_0x5a7bc9[_0x5a734b('0x20b2')]()['userProfileId'],'section':_0x5a734b('0x2672'),'fields':_0x5a734b('0x7ed'),'sort':_0x5a734b('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0xadf06('0x4b1'),_0xadf06('0xba1'),function(_0x3a8784,_0x13a152){const _0x444460=_0xadf06;return _0x13a152[_0x444460('0xca1')]('admin')?null:_0x3a8784[_0x444460('0xed7')]('userProfile@get',{'fields':_0x444460('0x16f'),'id':_0x13a152[_0x444460('0x20b2')]()[_0x444460('0x2f')]});}],'userProfileSection':[_0xadf06('0x4b1'),_0xadf06('0xba1'),function(_0x5e81a8,_0x2425dd){const _0x1f0800=_0xadf06;return _0x2425dd[_0x1f0800('0xca1')](_0x1f0800('0x20c2'))?null:_0x5e81a8['resolve'](_0x1f0800('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x2425dd[_0x1f0800('0x20b2')]()[_0x1f0800('0x2f')],'sectionId':0x25a});}]},'authenticate':!![],'permissionId':0x25a,'bodyClass':_0xadf06('0x129f')})[_0xadf06('0x2598')]('app.mail.mailAccounts.edit',{'url':_0xadf06('0x1560'),'params':{'mailAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x374510,'controller':_0xadf06('0x22e9')}},'resolve':{'mailAccount':[_0xadf06('0x4b1'),'$stateParams',function(_0x20378c,_0x16d876){const _0x15af61=_0xadf06;return _0x20378c[_0x15af61('0xed7')](_0x15af61('0x2a9'),{'fields':_0x15af61('0x7ed'),'id':_0x16d876['id']});}],'userProfileSection':['apiResolver','Auth',function(_0x3e74f7,_0x2752fe){const _0x2cda3b=_0xadf06;return _0x3e74f7[_0x2cda3b('0xed7')](_0x2cda3b('0x360'),{'fields':_0x2cda3b('0x1f47'),'userProfileId':_0x2752fe['getCurrentUser']()[_0x2cda3b('0x2f')],'sectionId':0x25a});}]},'authenticate':!![],'permissionId':0x25a,'bodyClass':_0xadf06('0x129f')})[_0xadf06('0x2598')]('app.mail.mailSubtatuses',{'url':_0xadf06('0x1148'),'views':{'content@app':{'templateUrl':_0x1e7dd8,'controller':_0xadf06('0x2e5')}},'resolve':{'mailSubtatuses':[_0xadf06('0x4b1'),function(_0x4196c1){const _0x358110=_0xadf06;return _0x4196c1['resolve'](_0x358110('0x101f'),{'fields':_0x358110('0x120a'),'sort':_0x358110('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0xadf06('0x4b1'),_0xadf06('0xba1'),function(_0x1044f0,_0x7eb9a9){const _0x4828ad=_0xadf06;return _0x7eb9a9[_0x4828ad('0xca1')]('admin')?null:_0x1044f0[_0x4828ad('0xed7')](_0x4828ad('0x1464'),{'fields':_0x4828ad('0x16f'),'id':_0x7eb9a9[_0x4828ad('0x20b2')]()[_0x4828ad('0x2f')]});}],'userProfileSection':['apiResolver',_0xadf06('0xba1'),function(_0x394042,_0x49299a){const _0x4ca2a0=_0xadf06;return _0x49299a['hasRole'](_0x4ca2a0('0x20c2'))?null:_0x394042[_0x4ca2a0('0xed7')](_0x4ca2a0('0x360'),{'fields':_0x4ca2a0('0x1f47'),'userProfileId':_0x49299a[_0x4ca2a0('0x20b2')]()['userProfileId'],'sectionId':0x25b});}]},'authenticate':!![],'permissionId':0x25b,'bodyClass':'mail'}),_0x213b26[_0xadf06('0x7d2')]('app/main/apps/mail');}angular[_0x189033('0x1e26')](_0x189033('0x2427'),[_0x189033('0x6cf'),'ngPassword','md.data.table','flow',_0x189033('0x25fc'),'ckeditor',_0x189033('0x1d9c'),'ngAria',_0x189033('0x273d'),'mdPickers',_0x189033('0x516'),_0x189033('0x7fa'),_0x189033('0x197b'),_0x189033('0x3b5'),'angular-cron-jobs',_0x189033('0x1447'),_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da'),_0x189033('0x1e83')])[_0x189033('0x272d')](_0x26b849)[_0x189033('0x1da3')](_0x189033('0x15c4'),_0x48735a)['controller'](_0x189033('0xf45'),_0xf31dec)[_0x189033('0x1da3')](_0x189033('0x159d'),_0xddf1e0)['controller']('EditMailAccountAppagentDialogController',_0x99671a)[_0x189033('0x1da3')](_0x189033('0x108c'),_0x1867d4)[_0x189033('0x1da3')](_0x189033('0x1b02'),_0x31ff71)['controller'](_0x189033('0xb60'),_0x1857bd)[_0x189033('0x1da3')]('EditMailAccountAppgotopDialogController',_0x1613ae)[_0x189033('0x1da3')]('EditMailAccountAppintervalDialogController',_0x5b39e1)['controller'](_0x189033('0x18d0'),_0x33eb7f)[_0x189033('0x1da3')](_0x189033('0x758'),_0x1efaa7)[_0x189033('0x1da3')](_0x189033('0x1660'),_0x45a08c)[_0x189033('0x1da3')](_0x189033('0x1576'),_0x405406)['controller'](_0x189033('0xa8c'),_0x464d54)[_0x189033('0x1da3')]('MailAccountMailCannedAnswersController',_0x55eefa)[_0x189033('0x1da3')]('CreateOrEditMailCannedAnswerDialogController',_0x461b38)[_0x189033('0x1da3')]('MailAccountDispositionsController',_0xfde873)[_0x189033('0x1da3')](_0x189033('0x22e1'),_0x1f49c9)[_0x189033('0x1da3')]('MailAccountsController',_0x586ee9)['controller'](_0x189033('0x1bdb'),_0x9a174e)[_0x189033('0x1da3')]('MailQueueagentaddController',_0x865c68)[_0x189033('0x1da3')](_0x189033('0x78d'),_0xefbda5)['controller']('MailQueueController',_0x2bd6ee)[_0x189033('0x1da3')](_0x189033('0x1e79'),_0x538648)[_0x189033('0x1da3')](_0x189033('0x1c2f'),_0x43ef34)[_0x189033('0x1da3')](_0x189033('0x243c'),_0xf74477);const _0x39079f=_0x180212['p']+_0x189033('0xb3'),_0x443778=_0x180212['p']+_0x189033('0xc48'),_0x4589c8=_0x180212['p']+_0x189033('0x1fb1');_0x13c9be[_0x189033('0x14be')]=['$scope','$q',_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x241e'),_0x189033('0x22ab'),'agents',_0x189033('0x127b'),_0x189033('0x56b'),'socket','toasty','helperClasses',_0x189033('0x2a'),'userProfileSection','Auth','license',_0x189033('0x1b27')];function _0x13c9be(_0x5ea489,_0x2a11f9,_0x1b762d,_0x320a7e,_0x4eff17,_0x208a6d,_0x1d185e,_0x582ac9,_0x549630,_0xee027a,_0x429af3,_0x20ddc1,_0x2b09f0,_0x2b05d2,_0x18eaa8,_0x5a5747,_0x23c904,_0x1db82e){const _0x4ddbd5=_0x189033,_0x3b9741=this,_0x102ef0=[_0x4ddbd5('0xef9'),_0x4ddbd5('0x2309'),_0x4ddbd5('0x10f'),_0x4ddbd5('0x8cc'),_0x4ddbd5('0x17fe'),'lastPauseAt',_0x4ddbd5('0x1d43'),_0x4ddbd5('0x2050'),_0x4ddbd5('0x1938'),_0x4ddbd5('0x1a11'),_0x4ddbd5('0x774'),'smsPause',_0x4ddbd5('0x185d'),_0x4ddbd5('0x716'),'voicePause',_0x4ddbd5('0xd2a'),_0x4ddbd5('0x218'),_0x4ddbd5('0x2409'),'smsCapacity',_0x4ddbd5('0x1484'),_0x4ddbd5('0x1079'),_0x4ddbd5('0x153b'),'openchannelCurrentCapacity',_0x4ddbd5('0x15c1'),_0x4ddbd5('0x1902'),_0x4ddbd5('0xaba'),_0x4ddbd5('0x157f'),_0x4ddbd5('0x1487'),_0x4ddbd5('0x2a8'),_0x4ddbd5('0xb90'),_0x4ddbd5('0x2787'),_0x4ddbd5('0x2512'),_0x4ddbd5('0x278b'),_0x4ddbd5('0x15e0'),_0x4ddbd5('0x1a03'),'openchannelStatusTime',_0x4ddbd5('0xc07'),_0x4ddbd5('0x1a70'),_0x4ddbd5('0x17c2'),_0x4ddbd5('0x21d1'),_0x4ddbd5('0x23b4'),'queue',_0x4ddbd5('0x10f5'),_0x4ddbd5('0xd70'),'phoneBarEnableScreenRecordingByAgent',_0x4ddbd5('0x2259')],_0x5e6cc6=[_0x4ddbd5('0x1938'),_0x4ddbd5('0x1a11'),_0x4ddbd5('0x774'),'smsPause','whatsappPause',_0x4ddbd5('0x716'),_0x4ddbd5('0x1431'),_0x4ddbd5('0x2309')];_0x3b9741[_0x4ddbd5('0x11ed')]=_0x5a5747[_0x4ddbd5('0x20b2')](),_0x3b9741[_0x4ddbd5('0x24d2')]=[_0x4ddbd5('0x2727'),_0x4ddbd5('0x5d7'),_0x4ddbd5('0x63'),_0x4ddbd5('0x1026'),'not_inuse'],_0x3b9741['pauses']=_0x1d185e||{'count':0x0,'rows':[]},_0x3b9741['license']=_0x23c904,_0x3b9741['userProfile']=_0x2b05d2,_0x3b9741[_0x4ddbd5('0x22df')]=_0x18eaa8&&_0x18eaa8[_0x4ddbd5('0x50d')]==0x1?_0x18eaa8['rows'][0x0]:null,_0x3b9741[_0x4ddbd5('0x1134')]=_0x5a5747[_0x4ddbd5('0x142a')](_0x3b9741['userProfileSection']?_0x3b9741[_0x4ddbd5('0x22df')]['crudPermissions']:null),_0x3b9741[_0x4ddbd5('0x756')]=_0x582ac9?_0x2e3ca0()[_0x4ddbd5('0x24db')](_0x582ac9[_0x4ddbd5('0xf5d')]?_0x582ac9['rows']:[],'id'):{},_0x3b9741['rpcAgents']=_0x549630?_0x2e3ca0()[_0x4ddbd5('0x24db')](_0x549630['rows']?_0x549630[_0x4ddbd5('0xf5d')]:[],'id'):{},_0x3b9741['paginatedAgents']={},_0x3b9741['load']=![],_0x3b9741['order']=[],_0x3b9741[_0x4ddbd5('0x7c6')]={};for(const _0x2995e6 in _0x3b9741[_0x4ddbd5('0x756')]){typeof _0x3b9741[_0x4ddbd5('0x756')][_0x2995e6]!=='undefined'&&(_0x3b9741['agents'][_0x2995e6][_0x4ddbd5('0x12f3')]=!![]);}_0x3b9741['query']={'limit':0xa,'page':0x1,'order':_0x4ddbd5('0x11bc'),'globalStatusFilter':'','pauseTypeFilter':''},_0x3b9741['logout']=_0x38e5c5,_0x3b9741[_0x4ddbd5('0x1880')]=_0x499aa1,_0x3b9741[_0x4ddbd5('0xa4')]=_0x168885,_0x3b9741[_0x4ddbd5('0x70e')]=_0x1fea7e,_0x3b9741[_0x4ddbd5('0x411')]=_0x4a1775,_0x3b9741[_0x4ddbd5('0x2d2')]=_0x6c3c11,_0x3b9741[_0x4ddbd5('0x1bf4')]=_0x5a3c01,_0x3b9741[_0x4ddbd5('0x3ee')]=_0xde2826,_0x3b9741[_0x4ddbd5('0x2678')]=_0x5b401e,_0x3b9741[_0x4ddbd5('0x1f68')]=_0x8530ad,_0x3b9741['onSave']=_0x2e22bc,_0x3b9741['onUpdate']=_0x18a3b6,_0x3b9741[_0x4ddbd5('0x1dd2')]=_0x625566,_0x3b9741['onConnect']=_0x48be87,_0x3b9741['onComplete']=_0x3e721d,_0x3b9741[_0x4ddbd5('0x1f6c')]=_0x331a74,_0x429af3['on']('user:save',_0x3b9741[_0x4ddbd5('0x2819')]),_0x429af3['on'](_0x4ddbd5('0x2719'),_0x3b9741[_0x4ddbd5('0x1418')]),_0x429af3['on'](_0x4ddbd5('0x216d'),_0x3b9741['onConnect']),_0x429af3['on'](_0x4ddbd5('0x3b6'),_0x3b9741['onComplete']),_0x625566();let _0x1d89e5=_0x1db82e(function(){const _0x5cd728=_0x4ddbd5;_0x3b9741[_0x5cd728('0x182c')]&&(_0x3b9741['load']=![],_0x625566());},0x3e7);function _0x625566(){const _0x10472f=_0x4ddbd5;_0x3b9741[_0x10472f('0x182c')]=![];const _0x455921=_0x2a11f9['defer']();_0x3b9741['promise']=_0x455921[_0x10472f('0x1883')],_0x3b9741[_0x10472f('0xdf9')]=[],_0x3b9741[_0x10472f('0x150d')]=[],_0x2e3ca0()['forIn'](_0x3b9741[_0x10472f('0x756')],function(_0xf3653c,_0x365ed5){const _0x9f3875=_0x10472f;_0x3b9741[_0x9f3875('0x127b')][_0x365ed5]&&_0x2e3ca0()[_0x9f3875('0xf22')](_0xf3653c,_0x2e3ca0()[_0x9f3875('0x24d0')](_0x2e3ca0()[_0x9f3875('0x8b5')](_0x3b9741['rpcAgents'][_0x365ed5],_0x5e6cc6),_0x102ef0)),_0x5a3c01(_0xf3653c),_0xf3653c[_0x9f3875('0x2309')]?(_0x3b9741['filteredAgents'][_0x9f3875('0x1fd0')](_0xf3653c),_0x3b9741['agentInternal'][_0xf3653c[_0x9f3875('0x1d43')]]=_0x365ed5):_0xf3653c['globalStatusTime']=_0x2e3ca0()[_0x9f3875('0xea3')](_0x1aaf93()()['format']('x'));});_0x3b9741[_0x10472f('0x23a2')][_0x10472f('0x1102')]&&_0x2e3ca0()[_0x10472f('0x3ec')](_0x3b9741[_0x10472f('0xdf9')],function(_0x55831f){const _0xdb8678=_0x10472f;return _0x55831f[_0xdb8678('0x12fa')]!==_0x3b9741[_0xdb8678('0x23a2')][_0xdb8678('0x1102')];});_0x3b9741[_0x10472f('0x23a2')]['pauseTypeFilter']&&_0x2e3ca0()['remove'](_0x3b9741[_0x10472f('0xdf9')],function(_0x4a1d72){return _0x4a1d72['pauseType']!==_0x3b9741['query']['pauseTypeFilter'];});_0x3b9741[_0x10472f('0x23a2')][_0x10472f('0x25')]&&_0x2e3ca0()[_0x10472f('0x3ec')](_0x3b9741['filteredAgents'],function(_0x4647fa){const _0x277efd=_0x10472f;return _0x4647fa['fullname'][_0x277efd('0x93a')]()['indexOf'](_0x3b9741[_0x277efd('0x23a2')][_0x277efd('0x25')][_0x277efd('0x93a')]())<0x0;});_0x3b9741[_0x10472f('0xdf9')]=_0x315479(_0x3b9741[_0x10472f('0xdf9')]);const _0x1de4f0=(_0x3b9741[_0x10472f('0x23a2')][_0x10472f('0xdf8')]-0x1)*_0x3b9741['query'][_0x10472f('0x6f0')];_0x3b9741[_0x10472f('0x20d5')]=_0x2e3ca0()[_0x10472f('0x16b7')](_0x3b9741[_0x10472f('0xdf9')],_0x1de4f0)[_0x10472f('0x12c8')](0x0,_0x3b9741[_0x10472f('0x23a2')][_0x10472f('0x6f0')]);for(let _0x359a74=0x0;_0x359a74<_0x3b9741['paginatedAgents'][_0x10472f('0x1564')];_0x359a74+=0x1){_0x3b9741[_0x10472f('0x150d')][_0x10472f('0x1fd0')](_0x3b9741[_0x10472f('0x20d5')][_0x359a74]['id']);}_0x455921['resolve'](),_0x3b9741['load']=!![];}function _0x2e22bc(_0x31be7e){const _0x118d3f=_0x4ddbd5;_0x3b9741[_0x118d3f('0x756')][_0x31be7e['id']]&&(_0x2e3ca0()[_0x118d3f('0xf22')](_0x3b9741[_0x118d3f('0x756')][_0x31be7e['id']],_0x2e3ca0()['pick'](_0x2e3ca0()['omit'](_0x31be7e,_0x5e6cc6),_0x102ef0)),_0x2e3ca0()[_0x118d3f('0xf22')](_0x3b9741[_0x118d3f('0x127b')][_0x31be7e['id']],_0x2e3ca0()['pick'](_0x2e3ca0()[_0x118d3f('0x8b5')](_0x31be7e,_0x5e6cc6),_0x102ef0)),_0x5a3c01(_0x3b9741[_0x118d3f('0x756')][_0x31be7e['id']]));}function _0x18a3b6(_0x3455cf){const _0x59d0e2=_0x4ddbd5;_0x3b9741[_0x59d0e2('0x756')][_0x3455cf['id']]&&(_0x2e3ca0()[_0x59d0e2('0xf22')](_0x3b9741[_0x59d0e2('0x756')][_0x3455cf['id']],_0x2e3ca0()[_0x59d0e2('0x24d0')](_0x3455cf,_0x102ef0)),_0x2e3ca0()[_0x59d0e2('0xf22')](_0x3b9741[_0x59d0e2('0x127b')][_0x3455cf['id']],_0x2e3ca0()[_0x59d0e2('0x24d0')](_0x3455cf,_0x102ef0)),_0x3455cf[_0x59d0e2('0x8cc')]&&(_0x3b9741['agents'][_0x3455cf['id']]['globalStatusTime']=_0x3455cf[_0x59d0e2('0x8cc')],_0x3b9741['rpcAgents'][_0x3455cf['id']][_0x59d0e2('0x24d')]=_0x3455cf[_0x59d0e2('0x8cc')]),_0x5a3c01(_0x3b9741[_0x59d0e2('0x756')][_0x3455cf['id']]));}function _0x48be87(_0x1017f5){const _0x16b28a=_0x4ddbd5;_0x3b9741[_0x16b28a('0x756')][_0x3b9741['agentInternal'][_0x1017f5['destaccountcode']]]&&(_0x2e3ca0()[_0x16b28a('0xf22')](_0x3b9741['agents'][_0x3b9741['agentInternal'][_0x1017f5[_0x16b28a('0x1d79')]]],_0x2e3ca0()[_0x16b28a('0x24d0')](_0x1017f5,[_0x16b28a('0x660'),'destconnectedlinenum'])),_0x2e3ca0()[_0x16b28a('0xf22')](_0x3b9741[_0x16b28a('0x127b')][_0x3b9741[_0x16b28a('0x7c6')][_0x1017f5['destaccountcode']]],_0x2e3ca0()[_0x16b28a('0x24d0')](_0x1017f5,[_0x16b28a('0x660'),_0x16b28a('0x10f5')])));}function _0x3e721d(_0x2d1186){const _0x14c8e0=_0x4ddbd5;_0x3b9741[_0x14c8e0('0x756')][_0x3b9741[_0x14c8e0('0x7c6')][_0x2d1186[_0x14c8e0('0x1d79')]]]&&(_0x3b9741[_0x14c8e0('0x756')][_0x3b9741[_0x14c8e0('0x7c6')][_0x2d1186[_0x14c8e0('0x1d79')]]]=_0x2e3ca0()[_0x14c8e0('0x8b5')](_0x3b9741[_0x14c8e0('0x756')][_0x3b9741['agentInternal'][_0x2d1186[_0x14c8e0('0x1d79')]]],[_0x14c8e0('0x660'),_0x14c8e0('0x10f5')]),_0x3b9741[_0x14c8e0('0x127b')][_0x3b9741[_0x14c8e0('0x7c6')][_0x2d1186[_0x14c8e0('0x1d79')]]]=_0x2e3ca0()[_0x14c8e0('0x8b5')](_0x3b9741[_0x14c8e0('0x127b')][_0x3b9741['agentInternal'][_0x2d1186['destaccountcode']]],['queue',_0x14c8e0('0x10f5')]));}function _0x38e5c5(_0x5640a0){const _0x2afa7d=_0x4ddbd5;return _0xee027a[_0x2afa7d('0xc96')][_0x2afa7d('0x1999')]({'id':_0x5640a0['id'],'device':_0x2afa7d('0x2c9'),'agent_id':_0x5640a0['id'],'agent_name':_0x5640a0[_0x2afa7d('0x60a')]})[_0x2afa7d('0xe53')]['then'](function(){const _0x3ffd46=_0x2afa7d;_0x20ddc1['success']({'title':'Agent\x20logout','msg':_0x5640a0['fullname']+_0x3ffd46('0x2488')}),_0x3b9741['agents'][_0x5640a0['id']]&&(_0x3b9741[_0x3ffd46('0x756')][_0x5640a0['id']][_0x3ffd46('0x2309')]=![]),_0x3b9741[_0x3ffd46('0x127b')][_0x5640a0['id']]&&(_0x3b9741['rpcAgents'][_0x5640a0['id']][_0x3ffd46('0x2309')]=![]),_0x625566();})[_0x2afa7d('0x130a')](function(_0x10b758){const _0x1369ad=_0x2afa7d;_0x20ddc1[_0x1369ad('0x52a')]({'title':_0x10b758['status']?_0x1369ad('0x2168')+_0x10b758[_0x1369ad('0x13ee')]+'\x20-\x20'+_0x10b758[_0x1369ad('0x24a9')]:'api.staff.save','msg':_0x10b758[_0x1369ad('0x5a5')]?JSON[_0x1369ad('0x258a')](_0x10b758[_0x1369ad('0x5a5')][_0x1369ad('0x8c2')]):_0x10b758[_0x1369ad('0x1ff0')]()});});}function _0x168885(_0x42450c,_0x163afd){const _0x4e6476=_0x4ddbd5;return _0xee027a[_0x4e6476('0xc96')]['pause']({'id':_0x42450c['id'],'type':_0x163afd})[_0x4e6476('0xe53')][_0x4e6476('0x683')](function(_0xb52951){const _0x5edc34=_0x4e6476;_0x3b9741[_0x5edc34('0x756')][_0x42450c['id']]&&_0x2e3ca0()[_0x5edc34('0xf22')](_0x3b9741[_0x5edc34('0x756')][_0x42450c['id']],_0x2e3ca0()[_0x5edc34('0x24d0')](_0xb52951,_0x102ef0)),_0x3b9741[_0x5edc34('0x127b')][_0x42450c['id']]&&_0x2e3ca0()[_0x5edc34('0xf22')](_0x3b9741[_0x5edc34('0x127b')][_0x42450c['id']],_0x2e3ca0()[_0x5edc34('0x24d0')](_0xb52951,_0x102ef0)),_0x5a3c01(_0x3b9741['agents'][_0x42450c['id']]);})[_0x4e6476('0x130a')](function(_0x148e10){const _0x30e8b3=_0x4e6476;_0x20ddc1[_0x30e8b3('0x52a')]({'title':_0x148e10[_0x30e8b3('0x13ee')]?'API:'+_0x148e10[_0x30e8b3('0x13ee')]+_0x30e8b3('0xbf6')+_0x148e10[_0x30e8b3('0x24a9')]:'api.staff.save','msg':_0x148e10[_0x30e8b3('0x5a5')]?JSON[_0x30e8b3('0x258a')](_0x148e10[_0x30e8b3('0x5a5')][_0x30e8b3('0x8c2')]):_0x148e10[_0x30e8b3('0x1ff0')]()});});}function _0x1fea7e(_0x358112){const _0x13c709=_0x4ddbd5;return _0xee027a['user'][_0x13c709('0x1778')]({'id':_0x358112['id']})[_0x13c709('0xe53')][_0x13c709('0x683')](function(_0xd78d74){const _0x20e9a2=_0x13c709;_0x3b9741[_0x20e9a2('0x756')][_0x358112['id']]&&_0x2e3ca0()['merge'](_0x3b9741[_0x20e9a2('0x756')][_0x358112['id']],_0x2e3ca0()[_0x20e9a2('0x24d0')](_0xd78d74,_0x102ef0)),_0x3b9741[_0x20e9a2('0x127b')][_0x358112['id']]&&_0x2e3ca0()['merge'](_0x3b9741['rpcAgents'][_0x358112['id']],_0x2e3ca0()[_0x20e9a2('0x24d0')](_0xd78d74,_0x102ef0)),_0x5a3c01(_0x3b9741[_0x20e9a2('0x756')][_0x358112['id']]);})[_0x13c709('0x130a')](function(_0x2f4cd3){const _0x3ac551=_0x13c709;_0x20ddc1[_0x3ac551('0x52a')]({'title':_0x2f4cd3[_0x3ac551('0x13ee')]?_0x3ac551('0x2168')+_0x2f4cd3[_0x3ac551('0x13ee')]+_0x3ac551('0xbf6')+_0x2f4cd3[_0x3ac551('0x24a9')]:_0x3ac551('0x154f'),'msg':_0x2f4cd3[_0x3ac551('0x5a5')]?JSON[_0x3ac551('0x258a')](_0x2f4cd3[_0x3ac551('0x5a5')]['message']):_0x2f4cd3[_0x3ac551('0x1ff0')]()});});}function _0x4a1775(_0xf41792){const _0x9c4338=_0x4ddbd5;_0x320a7e[_0x9c4338('0x1d4')](_0x320a7e[_0x9c4338('0x2430')]()['clickOutsideToClose'](!![])['title'](_0x9c4338('0x71a'))[_0x9c4338('0x26e3')](_0x9c4338('0x1f0'))['ok']('Ok')[_0x9c4338('0xe42')](_0xf41792));}function _0x499aa1(_0x342b6a,_0x6ace87){const _0x3fe550=_0x4ddbd5;_0x320a7e[_0x3fe550('0x1d4')]({'controller':'AgentqueueaddController','controllerAs':'vm','templateUrl':_0xf3687b,'parent':angular[_0x3fe550('0x1fcc')](_0x4eff17['body']),'targetEvent':_0x6ace87,'clickOutsideToClose':!![],'locals':{'agent':_0x342b6a,'agents':[],'channel':'sms','direction':_0x3fe550('0x1535'),'crudPermissions':_0x3b9741[_0x3fe550('0x1134')]}});}function _0xde2826(_0x1f3600){const _0x4cef5c=_0x4ddbd5;return _0x1f3600===_0x4cef5c('0xa4')||_0x1f3600==='*pause';}function _0x5b401e(_0x12d455){const _0x427223=_0x4ddbd5;return _0x12d455===_0x427223('0xa4');}function _0x8530ad(_0x3da402){const _0x595810=_0x4ddbd5;return _0x3da402===_0x595810('0x651');}function _0x3aee36(_0x557e89){const _0x2ac2b8=_0x4ddbd5;return _0x557e89===_0x2ac2b8('0x1586')||_0x557e89===_0x2ac2b8('0xdd4')||_0x557e89===_0x2ac2b8('0x19d2')||_0x557e89===_0x2ac2b8('0x2727')||_0x2e3ca0()[_0x2ac2b8('0x8f2')](_0x557e89);}function _0x6c3c11(_0x3d3a91,_0x244f32){const _0x42bb5a=_0x4ddbd5;if(_0x244f32==='voice'){if(_0x3d3a91[_0x244f32+_0x42bb5a('0x1d9d')]!=='idle')return _0x3d3a91[_0x244f32+'Status'];if(_0x3d3a91[_0x244f32+_0x42bb5a('0x2113')])return _0x3d3a91[_0x244f32+_0x42bb5a('0x1d9d')]=_0x42bb5a('0xa4'),'pause';return _0x42bb5a('0x1586');}else{if(_0x3d3a91[_0x244f32+_0x42bb5a('0x2113')])return _0x3d3a91[_0x244f32+'Status']=_0x42bb5a('0xa4'),_0x42bb5a('0xa4');return _0x3d3a91[_0x244f32+'Status'];}}function _0x5a3c01(_0x581044){const _0x1603a3=_0x4ddbd5;let _0x7e4944=_0x1603a3('0xdd4');if(_0x2e3ca0()[_0x1603a3('0x161')]([_0x6c3c11(_0x581044,_0x1603a3('0xcf2')),_0x6c3c11(_0x581044,_0x1603a3('0x24e')),_0x6c3c11(_0x581044,_0x1603a3('0x129f')),_0x6c3c11(_0x581044,_0x1603a3('0x1261')),_0x6c3c11(_0x581044,_0x1603a3('0x1285')),_0x6c3c11(_0x581044,_0x1603a3('0x16e7')),_0x6c3c11(_0x581044,'fax')],_0xde2826))_0x7e4944=_0x1603a3('0xa4');else{if(_0x2e3ca0()['some']([_0x6c3c11(_0x581044,'voice'),_0x6c3c11(_0x581044,'chat'),_0x6c3c11(_0x581044,_0x1603a3('0x129f')),_0x6c3c11(_0x581044,_0x1603a3('0x1261')),_0x6c3c11(_0x581044,'sms'),_0x6c3c11(_0x581044,_0x1603a3('0x16e7')),_0x6c3c11(_0x581044,_0x1603a3('0x23e9'))],_0xde2826))_0x7e4944='*pause';else _0x2e3ca0()[_0x1603a3('0x161')]([_0x6c3c11(_0x581044,_0x1603a3('0xcf2')),_0x6c3c11(_0x581044,_0x1603a3('0x24e')),_0x6c3c11(_0x581044,_0x1603a3('0x129f')),_0x6c3c11(_0x581044,'openchannel'),_0x6c3c11(_0x581044,_0x1603a3('0x1285')),_0x6c3c11(_0x581044,_0x1603a3('0x16e7')),_0x6c3c11(_0x581044,_0x1603a3('0x23e9'))],_0x3aee36)?_0x7e4944=_0x1603a3('0x1586'):_0x7e4944=_0x1603a3('0x63');}_0x581044[_0x1603a3('0x12fa')]!==_0x7e4944&&(_0x581044[_0x1603a3('0x12fa')]=_0x7e4944,_0x581044['init']?(_0x581044[_0x1603a3('0x12f3')]=![],_0x581044[_0x1603a3('0x24d')]=_0xde2826(_0x7e4944)?_0x2e3ca0()['toNumber'](_0x1aaf93()(_0x581044[_0x1603a3('0x8cc')])[_0x1603a3('0x26dd')]('x')):_0x2e3ca0()[_0x1603a3('0x69b')]([_0x581044[_0x1603a3('0x23b4')],_0x581044['chatStatusTime'],_0x581044['mailStatusTime'],_0x581044[_0x1603a3('0x1a70')],_0x581044[_0x1603a3('0x17c2')],_0x581044[_0x1603a3('0x15db')],_0x581044[_0x1603a3('0x21d1')]])):_0x581044[_0x1603a3('0x24d')]=_0x2e3ca0()[_0x1603a3('0xea3')](_0x1aaf93()()['format']('x')));}function _0x315479(_0x3dff88){const _0x3332b1=_0x4ddbd5,_0x483c41=_0x2e3ca0()[_0x3332b1('0x18ad')](_0x3b9741[_0x3332b1('0x23a2')][_0x3332b1('0x150d')],'-')?_0x3332b1('0x1f5a'):_0x3332b1('0xe38');return _0x2e3ca0()['orderBy'](_0x3dff88,[_0x3b9741['query']['order'][_0x3332b1('0x1725')]('-','')],[_0x483c41]);}function _0x151983(){_0x1d89e5&&(_0x1db82e['cancel'](_0x1d89e5),_0x1d89e5=null);}function _0x331a74(_0x1b50e3,_0x329e6b){const _0x3e6aa0=_0x4ddbd5;return _0xee027a[_0x3e6aa0('0xc96')]['update']({'id':_0x1b50e3['id']},{'screenrecording':_0x329e6b})[_0x3e6aa0('0xe53')][_0x3e6aa0('0x130a')](function(_0x1a67d4){const _0x2bc998=_0x3e6aa0;_0x20ddc1[_0x2bc998('0x52a')]({'title':_0x1a67d4[_0x2bc998('0x13ee')]?_0x2bc998('0x2168')+_0x1a67d4[_0x2bc998('0x13ee')]+_0x2bc998('0xbf6')+_0x1a67d4[_0x2bc998('0x24a9')]:_0x2bc998('0x162b'),'msg':_0x1a67d4['data']?JSON[_0x2bc998('0x258a')](_0x1a67d4['data'][_0x2bc998('0x8c2')]):_0x1a67d4['toString']()});});}_0x5ea489[_0x4ddbd5('0x26a2')](_0x4ddbd5('0x4b8'),function(){const _0x1fd711=_0x4ddbd5;_0x429af3['removeAllListeners'](_0x1fd711('0x18f0')),_0x429af3[_0x1fd711('0x1b9e')](_0x1fd711('0x2719')),_0x429af3[_0x1fd711('0x1b9e')](_0x1fd711('0x216d')),_0x429af3[_0x1fd711('0x1b9e')](_0x1fd711('0x3b6')),_0x151983();});}const _0x232b70=_0x13c9be,_0x246876=_0x180212['p']+_0x189033('0x2010'),_0x547d4d=_0x180212['p']+'src/js/modules/main/apps/sms/views/smsQueues/edit/agentadd/agentadd.html/agentadd.html';_0x9efbc8[_0x189033('0x14be')]=['$scope',_0x189033('0x2f9'),'$mdDialog','$q',_0x189033('0x16ea'),'$interval',_0x189033('0x2da'),'rpcQueues','api',_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x2a'),'userProfileSection',_0x189033('0xba1')];function _0x9efbc8(_0xe6ec8f,_0x4cef0f,_0x523548,_0x5e54fb,_0x313fdb,_0x40f6cf,_0x34fd31,_0x4d228a,_0x2e2f4d,_0x1d5c60,_0x540754,_0x1c916c,_0x1491d6,_0x4d59ca){const _0x4dcd44=_0x189033,_0x1650c1=this,_0x29a38b=[_0x4dcd44('0x1506'),'available',_0x4dcd44('0x1386'),'talking',_0x4dcd44('0x17f2'),_0x4dcd44('0x1a95'),_0x4dcd44('0x8c2'),_0x4dcd44('0x1455'),_0x4dcd44('0x1091'),_0x4dcd44('0x17c1'),'paused'];_0x1650c1[_0x4dcd44('0x11ed')]=_0x4d59ca[_0x4dcd44('0x20b2')](),_0x1650c1[_0x4dcd44('0x50d')]=_0x34fd31[_0x4dcd44('0x50d')]?_0x34fd31[_0x4dcd44('0x50d')]:0x0,_0x1650c1[_0x4dcd44('0x2da')]=_0x34fd31?_0x2e3ca0()[_0x4dcd44('0x24db')](_0x34fd31['rows']?_0x34fd31[_0x4dcd44('0xf5d')]:[],'id'):{},_0x1650c1['rpcQueues']=_0x4d228a?_0x2e3ca0()[_0x4dcd44('0x24db')](_0x4d228a[_0x4dcd44('0xf5d')]?_0x4d228a[_0x4dcd44('0xf5d')]:[],'id'):{},_0x1650c1[_0x4dcd44('0x2a')]=_0x1c916c,_0x1650c1['userProfileSection']=_0x1491d6&&_0x1491d6[_0x4dcd44('0x50d')]==0x1?_0x1491d6[_0x4dcd44('0xf5d')][0x0]:null,_0x1650c1[_0x4dcd44('0x1134')]=_0x4d59ca[_0x4dcd44('0x142a')](_0x1650c1['userProfileSection']?_0x1650c1[_0x4dcd44('0x22df')]['crudPermissions']:null);_0x4d59ca[_0x4dcd44('0xca1')](_0x4dcd44('0x20c2'))?_0x1650c1['query']={'type':_0x4dcd44('0x1535'),'sort':_0x4dcd44('0xc36'),'limit':0xa,'page':0x1}:_0x1650c1['query']={'id':_0x1650c1[_0x4dcd44('0x11ed')]['id'],'channel':_0x4dcd44('0x1285'),'type':_0x4dcd44('0x1535'),'sort':'-updatedAt','limit':0xa,'page':0x1};_0x1650c1[_0x4dcd44('0x53')]=_0x553ac2,_0x1650c1[_0x4dcd44('0x4c9')]=_0x4de8a8,_0x1650c1['createOrEditSmsQueue']=_0x322d3f,_0x1650c1[_0x4dcd44('0x1a94')]=_0x4473e4,_0x1650c1[_0x4dcd44('0x1f7c')]=_0x7006ac,_0x1650c1['onSave']=_0x16de68,_0x1650c1[_0x4dcd44('0x3ae')]=_0xe8a2ef,_0x1650c1[_0x4dcd44('0x203e')]=_0x17965f,_0x1650c1[_0x4dcd44('0x4a5')]=_0x1601f5,_0x1650c1[_0x4dcd44('0xd8b')]=_0x33ecfd,_0x1650c1['onLogout']=_0x4c3ab8,_0x1650c1[_0x4dcd44('0x3a8')]=_0x11d615,_0x1650c1[_0x4dcd44('0x150d')]=[],_0x2e3ca0()[_0x4dcd44('0x15d0')](_0x1650c1[_0x4dcd44('0x2da')],function(_0x1633a4){const _0x1e68a9=_0x4dcd44;_0x1650c1[_0x1e68a9('0x150d')][_0x1e68a9('0x1fd0')](_0x1633a4['id']);}),_0x1d5c60['on']('sms_queue:save',_0x1650c1[_0x4dcd44('0x2819')]),_0x1d5c60['on'](_0x4dcd44('0xd2f'),_0x1650c1[_0x4dcd44('0x3ae')]),_0x1d5c60['on']('userSmsQueue:remove',_0x1650c1[_0x4dcd44('0x203e')]),_0x1d5c60['on'](_0x4dcd44('0x2719'),_0x1650c1[_0x4dcd44('0x4a5')]),_0x1d5c60['on'](_0x4dcd44('0x56f'),_0x1650c1[_0x4dcd44('0xb2b')]),_0x1d5c60['on'](_0x4dcd44('0x217c'),_0x1650c1[_0x4dcd44('0xd8b')]);function _0x11d615(){const _0x3abdab=_0x4dcd44,_0xcb8c75=[];return _0x2e3ca0()['forIn'](_0x1650c1[_0x3abdab('0x2da')],function(_0x1c73b6,_0x48b6fa){const _0x2c0a33=_0x3abdab;_0x1c73b6[_0x2c0a33('0x1a1d')]=0x0,_0x1c73b6['loggedInDb']=0x0,_0x1650c1[_0x2c0a33('0x2da')][_0x48b6fa][_0x2c0a33('0x756')]={},_0xcb8c75[_0x2c0a33('0x1fd0')](_0x2e2f4d['smsQueue'][_0x2c0a33('0x27cf')]({'id':_0x48b6fa})[_0x2c0a33('0xe53')]),_0x1650c1[_0x2c0a33('0x1a10')][_0x48b6fa]&&_0x2e3ca0()[_0x2c0a33('0xf22')](_0x1c73b6,_0x2e3ca0()['pick'](_0x1650c1['rpcQueues'][_0x48b6fa],_0x29a38b));}),_0x5e54fb['all'](_0xcb8c75)[_0x3abdab('0x683')](function(_0x5d1440){const _0x42a1f9=_0x3abdab;for(let _0x33d3ea=0x0;_0x33d3ea<_0x5d1440[_0x42a1f9('0x1564')];_0x33d3ea+=0x1){for(let _0x922690=0x0;_0x922690<_0x5d1440[_0x33d3ea][_0x42a1f9('0xf5d')][_0x42a1f9('0x1564')];_0x922690++){_0x5d1440[_0x33d3ea]['rows'][_0x922690][_0x42a1f9('0x1a1d')]&&_0x1650c1['queues'][_0x5d1440[_0x33d3ea][_0x42a1f9('0xf5d')][_0x922690][_0x42a1f9('0x917')]][_0x42a1f9('0x1a1d')]++,_0x1650c1[_0x42a1f9('0x2da')][_0x5d1440[_0x33d3ea]['rows'][_0x922690]['SmsQueueId']]['loggedInDb']++,_0x1650c1[_0x42a1f9('0x2da')][_0x5d1440[_0x33d3ea][_0x42a1f9('0xf5d')][_0x922690]['SmsQueueId']]['agents'][_0x5d1440[_0x33d3ea][_0x42a1f9('0xf5d')][_0x922690][_0x42a1f9('0x10c5')]]=_0x5d1440[_0x33d3ea]['rows'][_0x922690]['SmsQueueId'];}}})['catch'](function(_0x36c2f6){console['error'](_0x36c2f6);});}function _0x16de68(_0xc2d82d){const _0x1e6e00=_0x4dcd44;_0x1650c1['queues'][_0xc2d82d['id']]&&_0x2e3ca0()[_0x1e6e00('0xf22')](_0x1650c1[_0x1e6e00('0x2da')][_0xc2d82d['id']],_0x2e3ca0()[_0x1e6e00('0x24d0')](_0xc2d82d,_0x29a38b));}function _0xe8a2ef(_0x286d5e){const _0x3c21b5=_0x4dcd44;_0x1650c1[_0x3c21b5('0x2da')][_0x286d5e[_0x3c21b5('0x917')]]&&_0x1650c1[_0x3c21b5('0x2da')][_0x286d5e[_0x3c21b5('0x917')]]['loggedInDb']++;}function _0x17965f(_0x1240f0){const _0x54c67b=_0x4dcd44;_0x1650c1[_0x54c67b('0x2da')][_0x1240f0[_0x54c67b('0x917')]]&&_0x1650c1[_0x54c67b('0x2da')][_0x1240f0[_0x54c67b('0x917')]][_0x54c67b('0x25a4')]--;}function _0x1601f5(_0x1fda11){const _0x3d1e40=_0x4dcd44;console[_0x3d1e40('0x1b2b')](_0x3d1e40('0x4a5'),_0x1fda11);if(_0x1fda11[_0x3d1e40('0x1431')])_0x2e3ca0()['forIn'](_0x1650c1[_0x3d1e40('0x2da')],function(_0x363bab){const _0x557781=_0x3d1e40;_0x363bab[_0x557781('0x756')][_0x1fda11['id']]&&(_0x363bab[_0x557781('0x1a1d')]+=0x1,console[_0x557781('0x1b2b')]('pause'));});else!_0x1fda11['voicePause']&&_0x2e3ca0()[_0x3d1e40('0x15d0')](_0x1650c1[_0x3d1e40('0x2da')],function(_0x3c5214){const _0x20fd18=_0x3d1e40;_0x3c5214[_0x20fd18('0x756')][_0x1fda11['id']]&&(_0x3c5214[_0x20fd18('0x1a1d')]>0x0&&(_0x3c5214[_0x20fd18('0x1a1d')]-=0x1,console[_0x20fd18('0x1b2b')](_0x20fd18('0x1778'))));});}function _0x33ecfd(_0x49e4b3){const _0x44aea5=_0x4dcd44;console[_0x44aea5('0x1b2b')](_0x44aea5('0x16aa'),_0x49e4b3),_0x1650c1[_0x44aea5('0x2da')][_0x49e4b3[_0x44aea5('0x917')]]&&(_0x1650c1[_0x44aea5('0x2da')][_0x49e4b3['SmsQueueId']][_0x44aea5('0x25a4')]+=0x1,_0x1650c1[_0x44aea5('0x2da')][_0x49e4b3[_0x44aea5('0x917')]][_0x44aea5('0x756')][_0x49e4b3[_0x44aea5('0x10c5')]]=_0x49e4b3[_0x44aea5('0x917')]);}function _0x4c3ab8(_0x3e79b0){const _0x523111=_0x4dcd44;console['log'](_0x523111('0xb2b'),_0x3e79b0),_0x1650c1[_0x523111('0x2da')][_0x3e79b0['SmsQueueId']]&&_0x1650c1[_0x523111('0x2da')][_0x3e79b0[_0x523111('0x917')]][_0x523111('0x25a4')]>0x0&&(_0x1650c1[_0x523111('0x2da')][_0x3e79b0[_0x523111('0x917')]][_0x523111('0x25a4')]-=0x1,delete _0x1650c1[_0x523111('0x2da')][_0x3e79b0['SmsQueueId']][_0x523111('0x756')][_0x3e79b0['UserId']]);}let _0xc95c56=!![],_0x493b19=0x1;_0xe6ec8f[_0x4dcd44('0x186d')](_0x4dcd44('0x1e1d'),function(_0x4060fc,_0xdec9d8){const _0x309d02=_0x4dcd44;_0xc95c56?_0x4cef0f(function(){_0xc95c56=![];}):(!_0xdec9d8&&(_0x493b19=_0x1650c1[_0x309d02('0x23a2')]['page']),_0x4060fc!==_0xdec9d8&&(_0x1650c1[_0x309d02('0x23a2')]['page']=0x1),!_0x4060fc&&(_0x1650c1[_0x309d02('0x23a2')][_0x309d02('0xdf8')]=_0x493b19),_0x1650c1['getQueues']());});function _0x553ac2(_0x4c5dd4){const _0x2a9ce3=_0x4dcd44;_0x1650c1['count']=_0x4c5dd4[_0x2a9ce3('0x50d')],_0x1650c1['queues']=_0x4c5dd4?_0x2e3ca0()[_0x2a9ce3('0x24db')](_0x4c5dd4[_0x2a9ce3('0xf5d')]?_0x4c5dd4[_0x2a9ce3('0xf5d')]:[],'id'):{};if(_0x4c5dd4[_0x2a9ce3('0xf5d')]){_0x1650c1[_0x2a9ce3('0x150d')]=[];for(let _0x452b75=0x0;_0x452b75<_0x4c5dd4['rows'][_0x2a9ce3('0x1564')];_0x452b75++){_0x1650c1[_0x2a9ce3('0x150d')]['push'](_0x4c5dd4['rows'][_0x452b75]['id']);}}_0x11d615();}function _0x4de8a8(){const _0x21983d=_0x4dcd44;_0x1650c1[_0x21983d('0x23a2')][_0x21983d('0x1cc8')]=(_0x1650c1[_0x21983d('0x23a2')][_0x21983d('0xdf8')]-0x1)*_0x1650c1[_0x21983d('0x23a2')][_0x21983d('0x6f0')],_0x4d59ca[_0x21983d('0xca1')]('admin')?_0x1650c1[_0x21983d('0x1883')]=_0x2e2f4d[_0x21983d('0x193f')][_0x21983d('0x1e6e')](_0x1650c1['query'],_0x553ac2)[_0x21983d('0xe53')]:(_0x1650c1[_0x21983d('0x23a2')]['id']=_0x1650c1[_0x21983d('0x2a')]['id'],_0x1650c1[_0x21983d('0x23a2')][_0x21983d('0x1aa')]=_0x21983d('0xd0d'),_0x1650c1['promise']=_0x2e2f4d[_0x21983d('0x2a')][_0x21983d('0x241d')](_0x1650c1[_0x21983d('0x23a2')],_0x553ac2)[_0x21983d('0xe53')]);}function _0x322d3f(_0x130a1b,_0x2c9f82){const _0x16f7b4=_0x4dcd44;_0x523548[_0x16f7b4('0x1d4')]({'controller':_0x16f7b4('0x2131'),'controllerAs':'vm','templateUrl':_0x246876,'parent':angular[_0x16f7b4('0x1fcc')](_0x313fdb[_0x16f7b4('0x18e5')]),'targetEvent':_0x130a1b,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x2c9f82,'smsQueues':_0x2e3ca0()[_0x16f7b4('0x17a0')](_0x1650c1[_0x16f7b4('0x2da')]),'license':null,'setting':null,'crudPermissions':_0x1650c1[_0x16f7b4('0x1134')]}});}function _0x4473e4(_0x25b88d,_0x104c7d){const _0x5119d5=_0x4dcd44;_0x523548[_0x5119d5('0x1d4')]({'controller':_0x5119d5('0x15c'),'controllerAs':'vm','templateUrl':_0x547d4d,'parent':angular['element'](_0x313fdb[_0x5119d5('0x18e5')]),'targetEvent':_0x25b88d,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x104c7d,'smsQueues':_0x1650c1['queues']?_0x1650c1[_0x5119d5('0x2da')][_0x5119d5('0xf5d')]:[],'realtime':![],'crudPermissions':_0x1650c1[_0x5119d5('0x1134')]}});}function _0x7006ac(_0x4c6314){const _0x11fab4=_0x4dcd44;return _0x2e2f4d[_0x11fab4('0x193f')][_0x11fab4('0x2480')](_0x4c6314)[_0x11fab4('0xe53')][_0x11fab4('0x683')](function(){const _0x135e13=_0x11fab4;_0x540754['success']({'title':_0x135e13('0x5c7'),'msg':_0x4c6314[_0x135e13('0x60a')]?_0x4c6314[_0x135e13('0x60a')]+_0x135e13('0x96c'):''});})['catch'](function(_0x58c73d){const _0x476c9a=_0x11fab4;_0x540754['error']({'title':_0x476c9a('0xb4'),'msg':_0x58c73d[_0x476c9a('0x8c2')]});});}_0xe6ec8f[_0x4dcd44('0x26a2')](_0x4dcd44('0x4b8'),function(){const _0x1778cf=_0x4dcd44;_0x1d5c60[_0x1778cf('0x1b9e')](_0x1778cf('0xde9')),_0x1d5c60['removeAllListeners'](_0x1778cf('0x4e7')),_0x1d5c60['removeAllListeners'](_0x1778cf('0xd2f')),_0x1d5c60[_0x1778cf('0x1b9e')]('user:update'),_0x1d5c60['removeAllListeners'](_0x1778cf('0x56f')),_0x1d5c60[_0x1778cf('0x1b9e')](_0x1778cf('0x217c'));});}const _0x56724f=_0x9efbc8;function _0x118924(){const _0x6e1500=_0x189033;return{'status':{'registered':_0x6e1500('0x584'),'unregistered':_0x6e1500('0x1da'),'lagged':'red-300-fg\x20icon-close-circle','reachable':_0x6e1500('0x584'),'unreachable':_0x6e1500('0x1da'),'unknown':_0x6e1500('0xcb0')},'state':{'unknown':_0x6e1500('0x27f9'),'not_inuse':_0x6e1500('0x280d'),'inuse':'red-300-fg\x20icon-phone-in-talk','busy':_0x6e1500('0x25ad'),'invalid':_0x6e1500('0x27f9'),'unavailable':_0x6e1500('0x27f9'),'ringing':'blue-300-fg\x20icon-phone-incoming','ringinuse':'blue-300-fg\x20icon-phone-incoming','onhold':_0x6e1500('0x1a52')},'channelStatus':{'ring':'blue-300-fg\x20icon-phone-incoming','up':_0x6e1500('0x1133'),'hangup':'red-300-fg\x20icon-phone-hangup'},'channelStatusOut':{'ring':_0x6e1500('0x2370'),'up':_0x6e1500('0x1133'),'hangup':_0x6e1500('0x22be')}};}const _0x209a86=_0x118924;_0x22da14[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'socket'];function _0x22da14(_0x3be9fe,_0x56d01c,_0x1af363){const _0x41c5e3=_0x189033,_0x1f4549=this;_0x1af363[_0x41c5e3('0x1346')](),_0x1af363['connect'](),_0x1f4549[_0x41c5e3('0x517')]=0x0;switch(_0x56d01c[_0x41c5e3('0xb24')][_0x41c5e3('0x60a')]){case _0x41c5e3('0x1c4d'):_0x1f4549[_0x41c5e3('0x517')]=0x0;break;case'app.sms.realtime.queues':_0x1f4549[_0x41c5e3('0x517')]=0x1;break;default:_0x1f4549[_0x41c5e3('0x517')]=0x0,_0x56d01c['go'](_0x41c5e3('0x1c4d'));}_0x3be9fe['$watch'](_0x41c5e3('0x9a4'),function(_0xbed82d,_0x57cc3d){const _0x2eeb67=_0x41c5e3;if(_0xbed82d!==_0x57cc3d)switch(_0xbed82d){case 0x0:_0x56d01c['go'](_0x2eeb67('0x1c4d'));break;case 0x1:_0x56d01c['go'](_0x2eeb67('0x1'));break;default:_0x56d01c['go'](_0x2eeb67('0x1c4d'));}});}const _0x508d94=_0x22da14;_0x189bbb['$inject']=[_0x189033('0x1398')];function _0x189bbb(_0x31c26c){const _0xbc315e=_0x189033;_0x31c26c['state']('app.sms.realtime',{'url':_0xbc315e('0xf7c'),'views':{'content@app':{'templateUrl':_0x39079f,'controller':'SmsRealtimeController\x20as\x20vm'}},'resolve':{'userProfile':[_0xbc315e('0x4b1'),_0xbc315e('0xba1'),function(_0x403926,_0x567d3e){const _0xf92a82=_0xbc315e;return _0x567d3e[_0xf92a82('0xca1')](_0xf92a82('0x20c2'))?null:_0x403926[_0xf92a82('0xed7')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x567d3e[_0xf92a82('0x20b2')]()['userProfileId']});}],'userProfileSection':['apiResolver',_0xbc315e('0xba1'),function(_0x3119d4,_0x1c7752){const _0x5302b7=_0xbc315e;return _0x1c7752[_0x5302b7('0xca1')](_0x5302b7('0x20c2'))?null:_0x3119d4[_0x5302b7('0xed7')](_0x5302b7('0x360'),{'fields':_0x5302b7('0x1f47'),'userProfileId':_0x1c7752[_0x5302b7('0x20b2')]()[_0x5302b7('0x2f')],'sectionId':0x2c6});}]},'authenticate':!![],'permissionId':0x2c6})['state'](_0xbc315e('0x1c4d'),{'url':_0xbc315e('0xf1a'),'controller':_0xbc315e('0x17a1'),'templateUrl':_0x443778,'resolve':{'pauses':[_0xbc315e('0x4b1'),function(_0x17f66e){const _0x411b2d=_0xbc315e;return _0x17f66e[_0x411b2d('0xed7')]('pause@get',{'nolimit':!![]});}],'agents':[_0xbc315e('0x4b1'),'Auth',function(_0x35c505,_0x207de4){const _0x5be8ec=_0xbc315e;return _0x207de4['hasRole'](_0x5be8ec('0x20c2'))?_0x35c505['resolve'](_0x5be8ec('0x25c9'),{'fields':_0x5be8ec('0x174e'),'role':'agent','sort':_0x5be8ec('0x11bc'),'nolimit':!![]}):_0x35c505['resolve'](_0x5be8ec('0x191b'),{'id':_0x207de4['getCurrentUser']()[_0x5be8ec('0x2f')],'section':_0x5be8ec('0x1bc0'),'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0x5be8ec('0x2327'),'sort':_0x5be8ec('0x11bc'),'nolimit':!![]});}],'userProfile':[_0xbc315e('0x4b1'),'Auth',function(_0x543792,_0x3bd703){const _0x56129c=_0xbc315e;return _0x3bd703[_0x56129c('0xca1')](_0x56129c('0x20c2'))?null:_0x543792['resolve'](_0x56129c('0x1464'),{'fields':_0x56129c('0x16f'),'id':_0x3bd703['getCurrentUser']()[_0x56129c('0x2f')]});}],'userProfileSection':['apiResolver',_0xbc315e('0xba1'),function(_0x483cf6,_0x22433e){const _0x184f8d=_0xbc315e;return _0x22433e[_0x184f8d('0xca1')](_0x184f8d('0x20c2'))?null:_0x483cf6['resolve'](_0x184f8d('0x360'),{'fields':_0x184f8d('0x1f47'),'userProfileId':_0x22433e[_0x184f8d('0x20b2')]()['userProfileId'],'sectionId':0xca});}],'rpcAgents':['apiResolver',function(_0x514267){const _0x36dfb7=_0xbc315e;return _0x514267[_0x36dfb7('0xed7')](_0x36dfb7('0x36a'));}]},'authenticate':!![],'permissionId':0x2c6})[_0xbc315e('0x2598')](_0xbc315e('0x1'),{'url':'/queues','controller':'QueuesSmsRealtimeController\x20as\x20vm','templateUrl':_0x4589c8,'resolve':{'queues':[_0xbc315e('0x4b1'),_0xbc315e('0xba1'),function(_0x393474,_0x1f4ad0){const _0x258974=_0xbc315e;return _0x1f4ad0[_0x258974('0xca1')](_0x258974('0x20c2'))?_0x393474[_0x258974('0xed7')](_0x258974('0x27bb'),{'type':'inbound','sort':_0x258974('0xc36'),'limit':0xa,'offset':0x0}):_0x393474['resolve'](_0x258974('0x191b'),{'id':_0x1f4ad0[_0x258974('0x20b2')]()[_0x258974('0x2f')],'section':_0x258974('0xd0d'),'channel':_0x258974('0x1285'),'type':_0x258974('0x1535'),'sort':'-updatedAt','limit':0xa,'page':0x1});}],'userProfile':[_0xbc315e('0x4b1'),_0xbc315e('0xba1'),function(_0x195cee,_0x3ff8f7){const _0x2bd8b8=_0xbc315e;return _0x3ff8f7['hasRole']('admin')?null:_0x195cee[_0x2bd8b8('0xed7')](_0x2bd8b8('0x1464'),{'fields':_0x2bd8b8('0x16f'),'id':_0x3ff8f7[_0x2bd8b8('0x20b2')]()[_0x2bd8b8('0x2f')]});}],'userProfileSection':[_0xbc315e('0x4b1'),_0xbc315e('0xba1'),function(_0x311375,_0x4b52d1){const _0x4938dd=_0xbc315e;return _0x4b52d1[_0x4938dd('0xca1')]('admin')?null:_0x311375[_0x4938dd('0xed7')](_0x4938dd('0x360'),{'fields':_0x4938dd('0x1f47'),'userProfileId':_0x4b52d1[_0x4938dd('0x20b2')]()[_0x4938dd('0x2f')],'sectionId':0x2bd});}],'rpcQueues':[_0xbc315e('0x4b1'),function(_0x119f14){const _0x14c72c=_0xbc315e;return _0x119f14['resolve'](_0x14c72c('0x42'));}]},'authenticate':!![],'permissionId':0x2c6});}angular[_0x189033('0x1e26')](_0x189033('0x2535'),[])[_0x189033('0x272d')](_0x189bbb)[_0x189033('0x1da3')]('AgentsSmsRealtimeController',_0x232b70)['controller'](_0x189033('0x1f6f'),_0x56724f)[_0x189033('0x1f97')](_0x189033('0xa72'),_0x209a86)[_0x189033('0x1da3')](_0x189033('0x16fa'),_0x508d94);const _0x512e86=_0x180212['p']+_0x189033('0xc66'),_0x2e7b8d=_0x180212['p']+_0x189033('0x1b7'),_0x3b0853=_0x180212['p']+_0x189033('0x212f'),_0x17c8b4=_0x180212['p']+_0x189033('0x18a7');_0x216d94[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state','$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x197c'),_0x189033('0xa0e'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x216d94(_0x4dfb8b,_0x3edc87,_0x35e9e0,_0x448ed6,_0x54e10e,_0x20b28b,_0x3d138f,_0xc690b5,_0x2745d3,_0x505e64,_0x25f611,_0x63c494,_0x216164,_0xca36a4){const _0x26a87a=_0x189033,_0x33a98a=this;_0x33a98a[_0x26a87a('0x11ed')]=_0x25f611[_0x26a87a('0x20b2')](),_0x33a98a[_0x26a87a('0x17f')]=[],_0x33a98a[_0x26a87a('0x260a')]=_0x216164,_0x33a98a[_0x26a87a('0xace')]=_0x63c494,_0x33a98a['crudPermissions']=_0xca36a4,_0x33a98a[_0x26a87a('0x258d')]={},_0x33a98a[_0x26a87a('0x19b2')]=_0x33a98a[_0x26a87a('0x260a')]&&_0x33a98a[_0x26a87a('0x260a')][_0x26a87a('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x33a98a[_0x26a87a('0xf28')]=_0x26a87a('0x74b'),_0x33a98a['smsAccount']=angular['copy'](_0x2745d3),_0x33a98a['smsAccounts']=_0xc690b5,_0x33a98a[_0x26a87a('0x80b')]=![];!_0x33a98a[_0x26a87a('0xa0e')]&&(_0x33a98a[_0x26a87a('0xa0e')]={'remote':_0x35e9e0['protocol']()+_0x26a87a('0x20de')+_0x35e9e0[_0x26a87a('0x19ac')]()+(_0x35e9e0[_0x26a87a('0x4a2')]()?':'+_0x35e9e0[_0x26a87a('0x4a2')]():''),'type':'twilio','waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0x33a98a[_0x26a87a('0xf28')]=_0x26a87a('0x6f5'),_0x33a98a['newSmsAccount']=!![]);_0x3edc87[_0x26a87a('0x7f2')]['id']&&(_0x33a98a[_0x26a87a('0xa0e')][_0x26a87a('0x1f4f')]=_0x3edc87[_0x26a87a('0x7f2')]['id']);_0x33a98a['addNewSmsAccount']=_0x546bfd,_0x33a98a[_0x26a87a('0xed2')]=_0x4ec013,_0x33a98a['deleteSmsAccount']=_0x3504e1,_0x33a98a['getDateFromString']=_0x4006c3,_0x33a98a[_0x26a87a('0xf82')]=_0x980811,_0x25f611[_0x26a87a('0xca1')]('admin')?_0x505e64[_0x26a87a('0x259b')][_0x26a87a('0x1e6e')]({'fields':_0x26a87a('0xa10'),'sort':_0x26a87a('0x60a')})[_0x26a87a('0xe53')][_0x26a87a('0x683')](function(_0x5d0d3b){const _0x19ea33=_0x26a87a;_0x33a98a[_0x19ea33('0xe01')]=_0x5d0d3b[_0x19ea33('0xf5d')]||[];})[_0x26a87a('0x130a')](function(_0x2463b1){const _0x1cd7b9=_0x26a87a;_0x3d138f[_0x1cd7b9('0x52a')]({'title':_0x2463b1[_0x1cd7b9('0x13ee')]?_0x1cd7b9('0x2168')+_0x2463b1[_0x1cd7b9('0x13ee')]+_0x1cd7b9('0xbf6')+_0x2463b1[_0x1cd7b9('0x24a9')]:'SYSTEM:GET_LISTS','msg':_0x2463b1[_0x1cd7b9('0x5a5')]?JSON[_0x1cd7b9('0x258a')](_0x2463b1['data']):_0x2463b1[_0x1cd7b9('0x1ff0')]()});}):_0x505e64[_0x26a87a('0x259b')]['get']({'fields':_0x26a87a('0xa10'),'sort':'name'})[_0x26a87a('0xe53')][_0x26a87a('0x683')](function(_0x109064){const _0x433657=_0x26a87a;_0x33a98a[_0x433657('0xe01')]=_0x109064['rows']||[];})[_0x26a87a('0x683')](function(){const _0x137cc7=_0x26a87a;return _0x505e64[_0x137cc7('0x22df')][_0x137cc7('0x1e6e')]({'userProfileId':_0x33a98a[_0x137cc7('0x11ed')][_0x137cc7('0x2f')],'sectionId':0x12d})[_0x137cc7('0xe53')];})['then'](function(_0x58d6a7){const _0x15d35b=_0x26a87a,_0x66daa=_0x58d6a7&&_0x58d6a7[_0x15d35b('0xf5d')]?_0x58d6a7[_0x15d35b('0xf5d')][0x0]:null;if(!_0x66daa){const _0x34f4cb=[];let _0x3055c1=null;_0x33a98a[_0x15d35b('0xa0e')]&&(_0x3055c1=_0x2e3ca0()[_0x15d35b('0x1c07')](_0x33a98a[_0x15d35b('0xe01')],{'id':Number(_0x33a98a[_0x15d35b('0xa0e')][_0x15d35b('0x1e4f')])}));for(let _0x387e75=0x0;_0x387e75<_0x33a98a[_0x15d35b('0xe01')]['length'];_0x387e75++){_0x3055c1&&_0x33a98a[_0x15d35b('0xe01')][_0x387e75]['id']===_0x3055c1['id']&&(_0x33a98a['lists'][_0x387e75][_0x15d35b('0x319')]=![],_0x34f4cb[_0x15d35b('0x1fd0')](_0x33a98a[_0x15d35b('0xe01')][_0x387e75]));}_0x33a98a[_0x15d35b('0xe01')]=_0x34f4cb;}else{if(!_0x66daa[_0x15d35b('0x170')])return _0x505e64['userProfileResource']['get']({'sectionId':_0x66daa['id']})[_0x15d35b('0xe53')][_0x15d35b('0x683')](function(_0x426692){const _0x562659=_0x15d35b,_0x4d59c7=_0x2e3ca0()[_0x562659('0x386')](_0x426692['rows'],function(_0x394d7e){const _0x3de44f=_0x562659;return _0x2e3ca0()[_0x3de44f('0x1c07')](_0x33a98a[_0x3de44f('0xe01')],{'id':_0x394d7e['resourceId']});});let _0x2e3b32=null;_0x33a98a[_0x562659('0xa0e')]&&(_0x2e3b32=_0x2e3ca0()[_0x562659('0x1c07')](_0x33a98a[_0x562659('0xe01')],{'id':Number(_0x33a98a[_0x562659('0xa0e')][_0x562659('0x1e4f')])}));if(_0x2e3b32&&!_0x2e3ca0()[_0x562659('0x7a2')](_0x4d59c7,['id',_0x2e3b32['id']])){const _0x3c6826=_0x2e3ca0()[_0x562659('0x1c07')](_0x33a98a['lists'],{'id':_0x2e3b32['id']});_0x3c6826[_0x562659('0x319')]=![],_0x4d59c7['push'](_0x3c6826);}_0x33a98a[_0x562659('0xe01')]=_0x4d59c7;});}})[_0x26a87a('0x130a')](function(_0x38a874){const _0x491f3e=_0x26a87a;_0x3d138f[_0x491f3e('0x52a')]({'title':_0x38a874[_0x491f3e('0x13ee')]?_0x491f3e('0x2168')+_0x38a874['status']+_0x491f3e('0xbf6')+_0x38a874['statusText']:_0x491f3e('0x11e3'),'msg':_0x38a874[_0x491f3e('0x5a5')]?JSON[_0x491f3e('0x258a')](_0x38a874[_0x491f3e('0x5a5')]):_0x38a874[_0x491f3e('0x1ff0')]()});});function _0x546bfd(){const _0x31b7be=_0x26a87a;_0x33a98a[_0x31b7be('0x17f')]=[],_0x505e64[_0x31b7be('0xa0e')]['save'](_0x33a98a[_0x31b7be('0xa0e')])[_0x31b7be('0xe53')][_0x31b7be('0x683')](function(_0x532d89){const _0x2496cd=_0x31b7be;_0x33a98a[_0x2496cd('0x197c')]['unshift'](_0x532d89['toJSON']()),_0x3d138f[_0x2496cd('0x53')]({'title':'SmsAccount\x20properly\x20created','msg':_0x33a98a['smsAccount'][_0x2496cd('0x60a')]?_0x33a98a[_0x2496cd('0xa0e')][_0x2496cd('0x60a')]+'\x20has\x20been\x20created!':''}),_0x980811(_0x532d89);})[_0x31b7be('0x130a')](function(_0x1a77cd){const _0x388a2a=_0x31b7be;if(_0x1a77cd['data']&&_0x1a77cd[_0x388a2a('0x5a5')][_0x388a2a('0x17f')]&&_0x1a77cd[_0x388a2a('0x5a5')][_0x388a2a('0x17f')]['length']){_0x33a98a[_0x388a2a('0x17f')]=_0x1a77cd['data']['errors']||[{'message':_0x1a77cd[_0x388a2a('0x1ff0')](),'type':'api.smsAccount.save'}];for(let _0x1481b0=0x0;_0x1481b0<_0x1a77cd[_0x388a2a('0x5a5')]['errors'][_0x388a2a('0x1564')];_0x1481b0+=0x1){_0x3d138f['error']({'title':_0x1a77cd[_0x388a2a('0x5a5')][_0x388a2a('0x17f')][_0x1481b0]['type'],'msg':_0x1a77cd[_0x388a2a('0x5a5')][_0x388a2a('0x17f')][_0x1481b0][_0x388a2a('0x8c2')]});}}else _0x3d138f[_0x388a2a('0x52a')]({'title':_0x1a77cd[_0x388a2a('0x13ee')]?_0x388a2a('0x2168')+_0x1a77cd[_0x388a2a('0x13ee')]+'\x20-\x20'+_0x1a77cd[_0x388a2a('0x24a9')]:_0x388a2a('0x122a'),'msg':_0x1a77cd['data']?JSON[_0x388a2a('0x258a')](_0x1a77cd[_0x388a2a('0x5a5')]['message']):_0x1a77cd[_0x388a2a('0x1ff0')]()});});}function _0x4ec013(){const _0x3eee00=_0x26a87a;_0x33a98a[_0x3eee00('0x17f')]=[],_0x505e64[_0x3eee00('0xa0e')][_0x3eee00('0x2480')]({'id':_0x33a98a[_0x3eee00('0xa0e')]['id']},_0x33a98a[_0x3eee00('0xa0e')])[_0x3eee00('0xe53')][_0x3eee00('0x683')](function(_0xbdc68c){const _0x44e713=_0x3eee00,_0x1fad19=_0x2e3ca0()[_0x44e713('0x1c07')](_0x33a98a[_0x44e713('0x197c')],{'id':_0xbdc68c['id']});_0x1fad19&&_0x2e3ca0()[_0x44e713('0xf22')](_0x1fad19,_0x2e3ca0()['pick'](_0xbdc68c[_0x44e713('0x24e1')](),_0x2e3ca0()[_0x44e713('0x55e')](_0x1fad19))),_0x3d138f['success']({'title':_0x44e713('0xef1'),'msg':_0x33a98a[_0x44e713('0xa0e')][_0x44e713('0x60a')]?_0x33a98a[_0x44e713('0xa0e')][_0x44e713('0x60a')]+_0x44e713('0xf59'):''}),_0x980811(_0xbdc68c);})[_0x3eee00('0x130a')](function(_0x4bcfd1){const _0xe3269f=_0x3eee00;if(_0x4bcfd1[_0xe3269f('0x5a5')]&&_0x4bcfd1[_0xe3269f('0x5a5')][_0xe3269f('0x17f')]&&_0x4bcfd1[_0xe3269f('0x5a5')][_0xe3269f('0x17f')][_0xe3269f('0x1564')]){_0x33a98a[_0xe3269f('0x17f')]=_0x4bcfd1['data'][_0xe3269f('0x17f')]||[{'message':_0x4bcfd1[_0xe3269f('0x1ff0')](),'type':_0xe3269f('0x1798')}];for(let _0x4fb513=0x0;_0x4fb513<_0x4bcfd1[_0xe3269f('0x5a5')][_0xe3269f('0x17f')][_0xe3269f('0x1564')];_0x4fb513++){_0x3d138f['error']({'title':_0x4bcfd1[_0xe3269f('0x5a5')][_0xe3269f('0x17f')][_0x4fb513][_0xe3269f('0xcf0')],'msg':_0x4bcfd1[_0xe3269f('0x5a5')][_0xe3269f('0x17f')][_0x4fb513]['message']});}}else _0x3d138f[_0xe3269f('0x52a')]({'title':_0x4bcfd1[_0xe3269f('0x13ee')]?_0xe3269f('0x2168')+_0x4bcfd1['status']+_0xe3269f('0xbf6')+_0x4bcfd1[_0xe3269f('0x24a9')]:'api.smsAccount.update','msg':_0x4bcfd1[_0xe3269f('0x5a5')]?JSON[_0xe3269f('0x258a')](_0x4bcfd1[_0xe3269f('0x5a5')]['message']):_0x4bcfd1[_0xe3269f('0x1ff0')]()});});}function _0x3504e1(_0x239108){const _0x56bd0b=_0x26a87a;_0x33a98a[_0x56bd0b('0x17f')]=[];const _0x4e1103=_0x448ed6[_0x56bd0b('0x1c6f')]()[_0x56bd0b('0xf28')](_0x56bd0b('0x4d'))[_0x56bd0b('0xa6a')]('The\x20smsAccount\x20will\x20be\x20deleted.')[_0x56bd0b('0x1040')](_0x56bd0b('0xa23'))['ok'](_0x56bd0b('0x2307'))[_0x56bd0b('0x19fb')]('Cancel')[_0x56bd0b('0xe42')](_0x239108);_0x448ed6[_0x56bd0b('0x1d4')](_0x4e1103)[_0x56bd0b('0x683')](function(){const _0x4d2510=_0x56bd0b;_0x505e64[_0x4d2510('0xa0e')]['delete']({'id':_0x33a98a[_0x4d2510('0xa0e')]['id']})[_0x4d2510('0xe53')][_0x4d2510('0x683')](function(){const _0x30fb06=_0x4d2510;_0x2e3ca0()['remove'](_0x33a98a['smsAccounts'],{'id':_0x33a98a[_0x30fb06('0xa0e')]['id']}),_0x3d138f[_0x30fb06('0x53')]({'title':_0x30fb06('0x79c'),'msg':(_0x33a98a['smsAccount'][_0x30fb06('0x60a')]||_0x30fb06('0xa0e'))+'\x20has\x20been\x20deleted!'}),_0x980811(_0x33a98a[_0x30fb06('0xa0e')]);})[_0x4d2510('0x130a')](function(_0xf5f0c4){const _0x170943=_0x4d2510;if(_0xf5f0c4[_0x170943('0x5a5')]&&_0xf5f0c4[_0x170943('0x5a5')][_0x170943('0x17f')]&&_0xf5f0c4[_0x170943('0x5a5')]['errors']['length']){_0x33a98a[_0x170943('0x17f')]=_0xf5f0c4[_0x170943('0x5a5')][_0x170943('0x17f')]||[{'message':_0xf5f0c4[_0x170943('0x1ff0')](),'type':_0x170943('0x9d7')}];for(let _0x246133=0x0;_0x246133<_0xf5f0c4[_0x170943('0x5a5')][_0x170943('0x17f')]['length'];_0x246133++){_0x3d138f[_0x170943('0x52a')]({'title':_0xf5f0c4['data'][_0x170943('0x17f')][_0x246133][_0x170943('0xcf0')],'msg':_0xf5f0c4['data'][_0x170943('0x17f')][_0x246133][_0x170943('0x8c2')]});}}else _0x3d138f[_0x170943('0x52a')]({'title':_0xf5f0c4['status']?_0x170943('0x2168')+_0xf5f0c4['status']+_0x170943('0xbf6')+_0xf5f0c4[_0x170943('0x24a9')]:'api.smsAccount.delete','msg':_0xf5f0c4[_0x170943('0x5a5')]?JSON[_0x170943('0x258a')](_0xf5f0c4[_0x170943('0x5a5')][_0x170943('0x8c2')]):_0xf5f0c4[_0x170943('0x8c2')]||_0xf5f0c4[_0x170943('0x1ff0')]()});});},function(){});}function _0x4006c3(_0x55657a){return _0x55657a===null?undefined:new Date(_0x55657a);}function _0x980811(_0x46a534){_0x448ed6['hide'](_0x46a534);}}const _0x5a2f00=_0x216d94,_0x1bb954=_0x180212['p']+_0x189033('0x20ae'),_0x493605=_0x180212['p']+'src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/amazonlex/dialog.html/dialog.html',_0x20f179=_0x180212['p']+_0x189033('0xf43'),_0x1fc354=_0x180212['p']+'src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/close/dialog.html/dialog.html',_0x1e4a51=_0x180212['p']+_0x189033('0x2621'),_0x8d5913=_0x180212['p']+_0x189033('0x1095'),_0x5220cd=_0x180212['p']+_0x189033('0x23d1'),_0x1d65a7=_0x180212['p']+'src/js/modules/main/apps/sms/views/smsAccounts/edit/apps/interval/dialog.html/dialog.html',_0x12d3f4=_0x180212['p']+_0x189033('0x85f'),_0x4220cf=_0x180212['p']+_0x189033('0x11d1'),_0x597e1f=_0x180212['p']+_0x189033('0x2152'),_0x5ae8a3=_0x180212['p']+_0x189033('0x4c3');_0x5583e2[_0x189033('0x14be')]=[_0x189033('0x56b'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),'Auth'];const _0x2a098e={'agent':_0x1bb954,'amazonlex':_0x493605,'autoreply':_0x20f179,'close':_0x1fc354,'dialogflow':_0x1e4a51,'gotoif':_0x8d5913,'gotop':_0x5220cd,'interval':_0x1d65a7,'noop':_0x12d3f4,'queue':_0x4220cf,'system':_0x597e1f,'tag':_0x5ae8a3};function _0x5583e2(_0x593fdf,_0x5d883c,_0x2fbd02,_0x3ebaaf,_0x3f2a43){const _0xe695fb=_0x189033,_0x11318f=this;_0x11318f['currentUser']=_0x3f2a43[_0xe695fb('0x20b2')](),_0x11318f[_0xe695fb('0xa0e')]={},_0x11318f[_0xe695fb('0xe18')]={'count':0x0,'rows':[]},_0x11318f[_0xe695fb('0x6bc')]=[],_0x11318f['crudPermissions'],_0x11318f[_0xe695fb('0x23a2')]={'sort':_0xe695fb('0xe1e')},_0x11318f[_0xe695fb('0x346')]=_0x2e3ca0()[_0xe695fb('0xfae')](_0x2e3ca0()[_0xe695fb('0x742')]([{'app':_0xe695fb('0x22ee'),'appType':_0xe695fb('0x115c'),'types':[_0xe695fb('0x10af'),_0xe695fb('0xbf0'),'list'],'fields':[],'isApp':![]},{'app':_0xe695fb('0x1126'),'appType':_0xe695fb('0x1126'),'type':_0xe695fb('0x1126'),'icon':'icon-apps','interval':'*,*,*,*','required':!![],'isApp':!![],'fields':[{'title':'Value','name':_0xe695fb('0x1c6b'),'type':'text','param':0x0}]},{'app':_0xe695fb('0x24f2'),'appType':_0xe695fb('0x24f2'),'type':_0xe695fb('0x24f2'),'icon':_0xe695fb('0x7ee'),'interval':_0xe695fb('0x1b54'),'required':!![],'isApp':!![],'extraApi':[{'name':'variables','field':{'name':_0xe695fb('0x26e0'),'key':_0xe695fb('0x60a')},'route':_0xe695fb('0x26e0'),'filters':{'fields':_0xe695fb('0xa10'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':_0xe695fb('0x256'),'name':'command','type':'text','required':!![],'param':0x0},{'title':_0xe695fb('0xde7'),'name':_0xe695fb('0x26e0'),'type':_0xe695fb('0x1aae'),'values':_0xe695fb('0x220b'),'value':_0xe695fb('0x2277'),'option':'variable.name','defaultValues':[{'value':'\x27\x27','option':_0xe695fb('0x2749')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':'gotop','appType':'gotop','type':_0xe695fb('0x27fe'),'icon':_0xe695fb('0x7ee'),'interval':_0xe695fb('0x1b54'),'isApp':!![],'fields':[{'title':'Priority','name':'priority','type':_0xe695fb('0x121f'),'required':!![],'min':0x0,'param':0x0}]},{'app':'gotoif','appType':_0xe695fb('0xc33'),'type':_0xe695fb('0xc33'),'icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0xe695fb('0xe0d'),'name':_0xe695fb('0x168e'),'type':'text','required':!![],'param':0x0},{'title':_0xe695fb('0x27e5'),'name':'truepriority','type':'number','min':0x1,'required':!![],'param':0x1},{'title':'falsepriority','name':_0xe695fb('0x1813'),'type':_0xe695fb('0x121f'),'min':0x1,'required':!![],'param':0x2}]},{'app':_0xe695fb('0x660'),'appType':_0xe695fb('0x660'),'foreignKey':_0xe695fb('0x917'),'type':_0xe695fb('0x660'),'icon':_0xe695fb('0x7ee'),'interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':'queues','field':{'name':_0xe695fb('0x660'),'key':_0xe695fb('0x60a')},'route':_0xe695fb('0x193f'),'filters':{'fields':'id,name,type','sort':'name','nolimit':!![]},'permissions':{'section':0x2bd}}],'fields':[{'title':_0xe695fb('0x1fa'),'name':_0xe695fb('0x660'),'type':_0xe695fb('0x1aae'),'values':_0xe695fb('0x2da'),'value':_0xe695fb('0x2543'),'option':_0xe695fb('0x2543'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':_0xe695fb('0xa09'),'name':_0xe695fb('0x1668'),'type':'number','max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x12c,'param':0x1}]},{'app':'agent','appType':_0xe695fb('0x2327'),'type':_0xe695fb('0x2327'),'foreignKey':_0xe695fb('0x10c5'),'icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'extraApi':[{'name':_0xe695fb('0x756'),'field':{'name':_0xe695fb('0x2327'),'key':_0xe695fb('0x60a')},'route':'user','filters':{'fields':_0xe695fb('0xa10'),'sort':_0xe695fb('0x60a'),'nolimit':!![],'role':_0xe695fb('0x2327')},'permissions':{'section':0xca}}],'fields':[{'title':_0xe695fb('0x62c'),'name':_0xe695fb('0x2327'),'type':_0xe695fb('0x1aae'),'values':'agents','value':'agent.name','option':_0xe695fb('0x1ed0'),'required':!![],'param':0x0},{'title':'Timeout','name':'timeout','type':'number','max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':_0xe695fb('0x2408'),'appType':_0xe695fb('0x2408'),'type':_0xe695fb('0x2408'),'icon':_0xe695fb('0x7ee'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0xe695fb('0x35'),'name':_0xe695fb('0x35'),'type':_0xe695fb('0xb31'),'defaultValue':'1','values':[{'option':'One\x20Time','value':'1'},{'option':_0xe695fb('0x1023'),'value':'0'}],'required':!![],'param':0x0},{'title':'Text','name':_0xe695fb('0x1bcd'),'type':'textarea','required':!![],'param':0x1}]},{'app':'close','appType':_0xe695fb('0x12b0'),'type':_0xe695fb('0x12b0'),'icon':'icon-apps','interval':_0xe695fb('0x1b54'),'isApp':!![],'fields':[{'title':_0xe695fb('0x11d4'),'name':_0xe695fb('0x43f'),'type':'text','required':!![],'param':0x0}]},{'app':_0xe695fb('0x270'),'appType':_0xe695fb('0x270'),'type':_0xe695fb('0x270'),'foreignKey':_0xe695fb('0xb6d'),'icon':_0xe695fb('0x7ee'),'interval':_0xe695fb('0x1b54'),'isApp':!![],'extraApi':[{'name':'tags','field':{'name':_0xe695fb('0x270'),'key':_0xe695fb('0x60a')},'route':_0xe695fb('0x270'),'filters':{'fields':_0xe695fb('0xa10'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0xe695fb('0x1e'),'name':_0xe695fb('0x270'),'type':'apiselect','values':_0xe695fb('0x1ce6'),'value':'tag.name','option':_0xe695fb('0x1402'),'required':!![],'param':0x0}]},{'app':_0xe695fb('0x205c'),'appType':_0xe695fb('0x205c'),'type':'dialogflow','icon':_0xe695fb('0x7ee'),'interval':_0xe695fb('0x1b54'),'isApp':!![],'fields':[{'title':_0xe695fb('0x429'),'name':_0xe695fb('0x1d46'),'type':'text','required':!![],'param':0x0},{'title':_0xe695fb('0x1a1c'),'name':_0xe695fb('0x1a1c'),'type':_0xe695fb('0xb31'),'defaultValue':'\x27en\x27','values':[{'option':_0xe695fb('0x17d9'),'value':_0xe695fb('0x1e18')},{'option':_0xe695fb('0xf48'),'value':_0xe695fb('0x1adc')},{'option':_0xe695fb('0x118e'),'value':_0xe695fb('0x1e33')},{'option':_0xe695fb('0x2217'),'value':_0xe695fb('0x1955')},{'option':_0xe695fb('0xbe9'),'value':'\x27es\x27'},{'option':_0xe695fb('0x51a'),'value':_0xe695fb('0x1869')},{'option':_0xe695fb('0x9ec'),'value':_0xe695fb('0x663')},{'option':_0xe695fb('0x1abb'),'value':_0xe695fb('0x1505')},{'option':'Korean\x20(South\x20Korea)','value':_0xe695fb('0x9d3')},{'option':_0xe695fb('0xe03'),'value':'\x27nl\x27'},{'option':_0xe695fb('0x1e53'),'value':_0xe695fb('0x23ca')},{'option':'Portuguese\x20(European)','value':'\x27pt\x27'},{'option':_0xe695fb('0x521'),'value':_0xe695fb('0xc58')},{'option':_0xe695fb('0x103e'),'value':_0xe695fb('0xb56')},{'option':_0xe695fb('0x1ff5'),'value':'\x27sv\x27'},{'option':'Thai','value':'\x27th\x27'},{'option':'Ukrainian','value':_0xe695fb('0x2e0')},{'option':_0xe695fb('0x277f'),'value':_0xe695fb('0x2562')},{'option':_0xe695fb('0xc60'),'value':_0xe695fb('0x1802')},{'option':_0xe695fb('0x700'),'value':_0xe695fb('0x1dc')}],'required':!![],'param':0x1},{'title':'welcomemessage','name':_0xe695fb('0x6d9'),'type':_0xe695fb('0x24be'),'maxlength':0xff,'required':![],'param':0x2,'help':!![]}]},{'app':_0xe695fb('0x1d62'),'appType':_0xe695fb('0xd24'),'type':_0xe695fb('0xd24'),'icon':_0xe695fb('0x7ee'),'interval':_0xe695fb('0x1b54'),'isApp':!![],'fields':[{'title':_0xe695fb('0x1e7d'),'name':'projectId','type':_0xe695fb('0x1bcd'),'required':!![],'param':0x0},{'title':_0xe695fb('0x97c'),'name':_0xe695fb('0x38'),'type':_0xe695fb('0x1bcd'),'required':!![],'param':0x1},{'title':_0xe695fb('0x216c'),'name':_0xe695fb('0x406'),'type':'textarea','required':!![],'param':0x2},{'title':_0xe695fb('0x1a1c'),'name':_0xe695fb('0x1a1c'),'type':_0xe695fb('0xb31'),'defaultValue':_0xe695fb('0x1adc'),'values':[{'value':_0xe695fb('0x1802'),'option':_0xe695fb('0x1de6')},{'value':_0xe695fb('0x2562'),'option':'Chinese\x20(Simplified)'},{'value':_0xe695fb('0x1dc'),'option':'Chinese\x20(Traditional)'},{'value':'\x27da\x27','option':_0xe695fb('0x17d9')},{'value':_0xe695fb('0x730'),'option':_0xe695fb('0xe03')},{'value':'\x27en\x27','option':_0xe695fb('0xf48')},{'value':_0xe695fb('0x6dd'),'option':_0xe695fb('0xbc1')},{'value':_0xe695fb('0x196e'),'option':_0xe695fb('0x6fa')},{'value':_0xe695fb('0x23bd'),'option':_0xe695fb('0x1e8')},{'value':'\x27en-IN\x27','option':_0xe695fb('0xa57')},{'value':_0xe695fb('0x95d'),'option':_0xe695fb('0x40b')},{'value':_0xe695fb('0x1869'),'option':'French'},{'value':_0xe695fb('0x8df'),'option':_0xe695fb('0x842')},{'value':_0xe695fb('0x2371'),'option':'\x27France\x20(France)'},{'value':_0xe695fb('0x1e33'),'option':_0xe695fb('0x118e')},{'value':_0xe695fb('0x1b11'),'option':_0xe695fb('0x81c')},{'value':_0xe695fb('0x663'),'option':_0xe695fb('0x9ec')},{'value':'\x27it\x27','option':_0xe695fb('0x2217')},{'value':_0xe695fb('0x1505'),'option':_0xe695fb('0x1abb')},{'value':'\x27ko\x27','option':_0xe695fb('0x233a')},{'value':_0xe695fb('0x23ca'),'option':_0xe695fb('0x1e53')},{'value':_0xe695fb('0x24cb'),'option':_0xe695fb('0x10a7')},{'value':_0xe695fb('0x1642'),'option':_0xe695fb('0x15b3')},{'value':_0xe695fb('0x64c'),'option':_0xe695fb('0x1876')},{'value':_0xe695fb('0xb56'),'option':'Russian'},{'value':_0xe695fb('0xd34'),'option':_0xe695fb('0xbe9')},{'value':_0xe695fb('0x2288'),'option':_0xe695fb('0x1e41')},{'value':'\x27es-ES\x27','option':_0xe695fb('0x208e')},{'value':_0xe695fb('0x2175'),'option':_0xe695fb('0x1ff5')},{'value':_0xe695fb('0x15a8'),'option':_0xe695fb('0xbc')},{'value':_0xe695fb('0x267f'),'option':_0xe695fb('0x17b0')},{'value':_0xe695fb('0x2e0'),'option':_0xe695fb('0x965')}],'required':!![],'param':0x3},{'title':_0xe695fb('0x6d9'),'name':_0xe695fb('0x6d9'),'type':_0xe695fb('0x24be'),'maxlength':0xff,'param':0x4,'help':!![]}]},{'app':_0xe695fb('0x1db1'),'appType':'amazonlex','type':_0xe695fb('0x1db1'),'icon':_0xe695fb('0x7ee'),'interval':_0xe695fb('0x1b54'),'isApp':!![],'fields':[{'title':'accesskeyid','name':_0xe695fb('0x7ae'),'type':_0xe695fb('0x1bcd'),'required':!![],'param':0x0},{'title':'secretaccesskey','name':_0xe695fb('0x204a'),'type':_0xe695fb('0x1bcd'),'required':!![],'param':0x1},{'title':'lexregion','name':'lexregion','type':_0xe695fb('0xb31'),'defaultValue':_0xe695fb('0x1924'),'values':[{'option':_0xe695fb('0x260e'),'value':_0xe695fb('0x1924')},{'option':_0xe695fb('0xc2b'),'value':_0xe695fb('0x1488')},{'option':_0xe695fb('0x1e10'),'value':_0xe695fb('0x17db')},{'option':'Asia\x20Pacific\x20(Sydney)','value':_0xe695fb('0xc6')}],'required':!![],'param':0x2},{'title':'botname','name':_0xe695fb('0x11a9'),'type':'text','required':!![],'param':0x3},{'title':_0xe695fb('0x6d9'),'name':'welcomemessage','type':_0xe695fb('0x24be'),'maxlength':0xff,'required':![],'param':0x4,'help':!![]}]}],[_0xe695fb('0x1d75')]),{'isApp':![]}),_0x11318f[_0xe695fb('0x2335')]={'group':{'name':'opt1','pull':'clone'},'animation':0x64,'sort':![]},_0x11318f[_0xe695fb('0x2146')]={'group':{'name':_0xe695fb('0x489'),'put':_0xe695fb('0x11bf')},'animation':0x64,'onAdd':function(_0x16eaf3){_0x12f29f(_0x16eaf3,_0x16eaf3['newIndex']);},'onSort':function(){_0x5090f9();}},_0x11318f[_0xe695fb('0x12f3')]=_0x39ff84,_0x11318f[_0xe695fb('0x26eb')]=_0x127af9,_0x11318f['getSmsAccountApps']=_0x208a72,_0x11318f[_0xe695fb('0x2780')]=_0x12f29f,_0x11318f[_0xe695fb('0x24f7')]=_0x2ec758,_0x11318f[_0xe695fb('0x23ae')]=_0x356121,_0x11318f[_0xe695fb('0x1f77')]=_0x2f9969,_0x11318f[_0xe695fb('0x13f5')]=_0x5090f9,_0x11318f[_0xe695fb('0x14a')]=_0x110fde;function _0x39ff84(_0x43b282,_0x213abc){const _0xc0ec4a=_0xe695fb;_0x11318f[_0xc0ec4a('0xa0e')]=_0x43b282,_0x11318f[_0xc0ec4a('0x1134')]=typeof _0x213abc!==_0xc0ec4a('0x1867')?_0x213abc:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x11318f['applications'][_0xc0ec4a('0x120b')]=!_0x11318f[_0xc0ec4a('0x1134')][_0xc0ec4a('0x1978')]?!![]:![],_0x11318f[_0xc0ec4a('0x23a2')]['id']=_0x43b282['id'],_0x11318f['query']['isApp']=!![],_0x11318f[_0xc0ec4a('0x23a2')][_0xc0ec4a('0x2088')]=!![],_0x11318f[_0xc0ec4a('0x14b9')](),_0x11318f[_0xc0ec4a('0x14a')]();}function _0x127af9(_0x3fb345,_0x48c5d2,_0x3be710){const _0x57a605=_0xe695fb,_0x130d23=_0x5d883c[_0x57a605('0x1c6f')]()[_0x57a605('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20application?')[_0x57a605('0x26e3')](_0x57a605('0xed5')+_0x3fb345['app']+_0x57a605('0x20f1')+'\x20will\x20be\x20deleted.')[_0x57a605('0x1040')]('delete\x20application')[_0x57a605('0xe42')](_0x3be710)['ok']('OK')[_0x57a605('0x19fb')](_0x57a605('0x16b8'));_0x5d883c[_0x57a605('0x1d4')](_0x130d23)[_0x57a605('0x683')](function(){const _0x42319e=_0x57a605;_0x11318f[_0x42319e('0xe18')][_0x42319e('0xf5d')][_0x42319e('0x2040')](_0x48c5d2,0x1),_0x5090f9();},function(){console['log']('CANCEL');});}function _0x12f29f(_0x3b93b0,_0x79269a){const _0x1d0680=_0xe695fb;if(_0x11318f[_0x1d0680('0xe18')][_0x1d0680('0xf5d')]['length']){const _0x6ab938=_0x11318f[_0x1d0680('0xe18')][_0x1d0680('0xf5d')][_0x79269a]?_0x11318f[_0x1d0680('0xe18')][_0x1d0680('0xf5d')][_0x79269a]:_0x11318f['smsAccountApps']['rows'][0x0],_0xe3c8ef=(_0x6ab938[_0x1d0680('0x11f3')]||_0x6ab938[_0x1d0680('0x1d75')])[_0x1d0680('0x93a')]();_0x5d883c[_0x1d0680('0x1d4')]({'controller':_0x1d0680('0x1e5')+_0xe3c8ef+_0x1d0680('0x9e4'),'controllerAs':'vm','templateUrl':_0x2a098e[_0xe3c8ef],'parent':angular[_0x1d0680('0x1fcc')](_0x2fbd02[_0x1d0680('0x18e5')]),'targetEvent':_0x3b93b0,'clickOutsideToClose':!![],'locals':{'smsAccountApp':_0x6ab938,'smsAccount':_0x11318f[_0x1d0680('0xa0e')],'crudPermissions':_0x11318f[_0x1d0680('0x1134')]}})[_0x1d0680('0x683')](function(_0x4ecc31){const _0x19b17d=_0x1d0680;_0x4ecc31&&(_0x4ecc31['id']?_0x11318f[_0x19b17d('0xe18')]['rows'][_0x79269a]=_0x4ecc31:_0x11318f[_0x19b17d('0xe18')][_0x19b17d('0xf5d')][_0x19b17d('0x2040')](_0x79269a,0x0,_0x4ecc31),_0x5090f9());})[_0x1d0680('0x130a')](function(_0x1121ce){const _0x2da8db=_0x1d0680;_0x1121ce&&_0x3ebaaf[_0x2da8db('0x52a')]({'title':_0x1121ce[_0x2da8db('0x13ee')]?_0x2da8db('0x2168')+_0x1121ce['status']+'\x20-\x20'+_0x1121ce['statusText']:_0x2da8db('0xf1b'),'msg':_0x1121ce['data']?JSON[_0x2da8db('0x258a')](_0x1121ce[_0x2da8db('0x5a5')]):_0x1121ce[_0x2da8db('0x1ff0')]()});});}}function _0x2ec758(_0x350a7c,_0x229424){const _0x14983c=_0xe695fb;if(_0x11318f[_0x14983c('0xe18')][_0x14983c('0xf5d')][_0x14983c('0x1564')]){const _0x3b4dbd=_0x11318f[_0x14983c('0xe18')][_0x14983c('0xf5d')][_0x229424]?_0x11318f[_0x14983c('0xe18')][_0x14983c('0xf5d')][_0x229424]:_0x11318f[_0x14983c('0xe18')][_0x14983c('0xf5d')][0x0];_0x5d883c[_0x14983c('0x1d4')]({'controller':_0x14983c('0x23e3'),'controllerAs':'vm','templateUrl':_0x1d65a7,'parent':angular[_0x14983c('0x1fcc')](_0x2fbd02[_0x14983c('0x18e5')]),'targetEvent':_0x350a7c,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x3b4dbd[_0x14983c('0x115c')],'IntervalId':_0x3b4dbd[_0x14983c('0x5ae')],'application':!![]},'intervals':[],'crudPermissions':_0x11318f['crudPermissions']}})[_0x14983c('0x683')](function(_0x4e240c){const _0xdba007=_0x14983c;_0x4e240c&&(_0x3b4dbd[_0xdba007('0x115c')]=_0x4e240c[_0xdba007('0x115c')]||_0xdba007('0x1b54'),_0x3b4dbd[_0xdba007('0x5ae')]=_0x4e240c['IntervalId']||null,_0x5090f9());});}}function _0x5090f9(){const _0x335cc1=_0xe695fb;let _0x2c3fa3=0x1,_0xfa6ee9=[];for(let _0x499d66=0x0;_0x499d66<_0x11318f[_0x335cc1('0xe18')]['rows'][_0x335cc1('0x1564')];_0x499d66++){const _0x20a4f4=_0x11318f[_0x335cc1('0xe18')][_0x335cc1('0xf5d')][_0x499d66],_0x17fd44=[],_0x428ecc=[];_0x20a4f4[_0x335cc1('0xe98')]=_0x20a4f4[_0x335cc1('0x115c')]!==_0x335cc1('0x1b54')?[_0x20a4f4[_0x335cc1('0x115c')]]:_0x20a4f4[_0x335cc1('0x5ae')]?_0x2e3ca0()[_0x335cc1('0x386')](_0x2e3ca0()[_0x335cc1('0x25')](_0x11318f['intervals'][_0x335cc1('0xf5d')],{'IntervalId':_0x20a4f4[_0x335cc1('0x5ae')]}),_0x335cc1('0x115c')):[],_0x20a4f4[_0x335cc1('0x22d3')]=_0x11318f[_0x335cc1('0xa0e')][_0x335cc1('0x22d3')],_0x20a4f4['exten']=_0x11318f[_0x335cc1('0xa0e')][_0x335cc1('0x1a5b')],_0x20a4f4['type']&&(_0x20a4f4[_0x335cc1('0xcf0')]=_0x20a4f4[_0x335cc1('0xcf0')][_0x335cc1('0x93a')]()),_0x20a4f4[_0x335cc1('0xe1e')]=_0x17fd44['length']?_0x2e3ca0()[_0x335cc1('0xc0f')](_0x17fd44)[_0x335cc1('0xe1e')]+0x1:_0x2c3fa3,_0x2c3fa3=(_0x428ecc[_0x335cc1('0x1564')]?_0x2e3ca0()[_0x335cc1('0xc0f')](_0x428ecc)[_0x335cc1('0xe1e')]:_0x20a4f4[_0x335cc1('0xe1e')])+0x1,_0xfa6ee9=_0x2e3ca0()[_0x335cc1('0x746')](_0xfa6ee9,_0x17fd44,[_0x20a4f4],_0x428ecc);}_0x593fdf[_0x335cc1('0xa0e')][_0x335cc1('0x10ef')]({'id':_0x11318f[_0x335cc1('0xa0e')]['id']},_0x2e3ca0()[_0x335cc1('0x742')](_0xfa6ee9,'priority'))[_0x335cc1('0xe53')][_0x335cc1('0x683')](function(_0x149491){const _0x2d2ecd=_0x335cc1;_0x11318f[_0x2d2ecd('0xe18')][_0x2d2ecd('0xf5d')]=_0x149491[_0x2d2ecd('0xf5d')];})['catch'](function(_0x268a94){console['error'](_0x268a94);});}function _0x4eda7b(_0x27fd4b){_0x11318f['smsAccountApps']=_0x27fd4b||{'count':0x0,'rows':[]};}function _0x110fde(){const _0x6034d6=_0xe695fb;return _0x593fdf[_0x6034d6('0x115c')][_0x6034d6('0x1e6e')]({'fields':_0x6034d6('0x2072')})[_0x6034d6('0xe53')][_0x6034d6('0x683')](function(_0x71670b){const _0x3afe4a=_0x6034d6;_0x11318f[_0x3afe4a('0xe98')]=_0x71670b;})[_0x6034d6('0x130a')](function(_0x2959f0){console['error'](_0x2959f0);});}function _0x208a72(){const _0x10ff4e=_0xe695fb;_0x11318f[_0x10ff4e('0x1883')]=_0x593fdf['smsAccount'][_0x10ff4e('0x13be')](_0x11318f[_0x10ff4e('0x23a2')],_0x4eda7b)[_0x10ff4e('0xe53')];}function _0x356121(_0x188959){const _0x1502af=_0xe695fb;_0x2e3ca0()[_0x1502af('0x3ec')](_0x11318f[_0x1502af('0xe18')][_0x1502af('0xf5d')],{'id':_0x188959['id']}),_0x5090f9(),_0x3ebaaf[_0x1502af('0x53')]({'title':'App\x20deleted!','msg':_0x188959[_0x1502af('0x1d75')]?_0x188959[_0x1502af('0x1d75')]+'\x20has\x20been\x20deleted!':''});}function _0x2f9969(_0x31a782){const _0x5dbf28=_0xe695fb,_0x52bfff=_0x5d883c[_0x5dbf28('0x1c6f')]()[_0x5dbf28('0xf28')](_0x5dbf28('0x188'))[_0x5dbf28('0x26e3')](''+_0x11318f[_0x5dbf28('0x6bc')][_0x5dbf28('0x1564')]+_0x5dbf28('0x93c')+_0x5dbf28('0x1ee7'))['ariaLabel']('delete\x20applications')['targetEvent'](_0x31a782)['ok']('OK')[_0x5dbf28('0x19fb')](_0x5dbf28('0x16b8'));_0x5d883c['show'](_0x52bfff)[_0x5dbf28('0x683')](function(){const _0x2c53b6=_0x5dbf28;_0x11318f[_0x2c53b6('0x6bc')][_0x2c53b6('0x1299')](function(_0x51ae11){const _0x2d23dd=_0x2c53b6;_0x2e3ca0()['remove'](_0x11318f[_0x2d23dd('0xe18')]['rows'],{'id':_0x51ae11['id']});}),_0x11318f[_0x2c53b6('0x6bc')]=[],_0x5090f9();});}}const _0x537444=_0x5583e2;_0x2b2b8c['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xa0e'),_0x189033('0x197c'),_0x189033('0x2c9'),'$translate','Auth','crudPermissions'];function _0x2b2b8c(_0x5094a8,_0x486e9f,_0x516e7b,_0x4e355c,_0x4a0630,_0x22ad48,_0x4da41b,_0x141ca8,_0x5375bb,_0x4750f0){const _0x22a959=_0x189033,_0x46bac0=this;_0x46bac0['currentUser']=_0x5375bb['getCurrentUser'](),_0x46bac0[_0x22a959('0xa0e')]=_0x4a0630,_0x46bac0[_0x22a959('0x1134')]=_0x4750f0,_0x46bac0[_0x22a959('0x2c9')]=_0x4da41b,_0x46bac0[_0x22a959('0x1996')]=[],_0x46bac0['allowedItems']=[],_0x46bac0['selectedItems']=[],_0x46bac0[_0x22a959('0x125e')]=[],_0x46bac0[_0x22a959('0x23a7')]=[],_0x46bac0[_0x22a959('0x2106')]=![],_0x46bac0['onInit']=_0x3438d3,_0x46bac0[_0x22a959('0xa5f')]=_0x1ef6f1,_0x46bac0[_0x22a959('0xf82')]=_0x385f00,_0x46bac0[_0x22a959('0x169f')]={'readOnly':!_0x46bac0[_0x22a959('0x1134')][_0x22a959('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x22a959('0x60a'),'line1':_0x22a959('0x11bc'),'line2':[_0x22a959('0x60a'),_0x22a959('0x1d43')],'line3':'','labelAll':_0x141ca8[_0x22a959('0x2728')](_0x22a959('0x2298')),'labelSelected':_0x141ca8[_0x22a959('0x2728')]('SMS.SELECTED_AGENTS'),'transferCallback':function(){const _0x2e7bd9=_0x22a959,_0x2b19d4=_0x2e3ca0()[_0x2e7bd9('0x25cb')](_0x46bac0[_0x2e7bd9('0x23a7')],_0x46bac0['selectedItems'],'id');_0x46bac0[_0x2e7bd9('0x2106')]=_0x2e3ca0()[_0x2e7bd9('0x173f')](_0x2b19d4)?![]:!![];}};function _0x3438d3(){const _0x40ed2c=_0x22a959;return _0x5375bb['hasRole'](_0x40ed2c('0x20c2'))?_0x565921()[_0x40ed2c('0x130a')](function(_0x51a022){const _0x429a2d=_0x40ed2c;_0x516e7b[_0x429a2d('0x52a')]({'title':_0x51a022[_0x429a2d('0x13ee')]?_0x429a2d('0x2168')+_0x51a022[_0x429a2d('0x13ee')]+_0x429a2d('0xbf6')+_0x51a022['statusText']:_0x429a2d('0x144f'),'msg':_0x51a022[_0x429a2d('0x13ee')]?JSON[_0x429a2d('0x258a')](_0x51a022[_0x429a2d('0x5a5')]):_0x51a022[_0x429a2d('0x1ff0')]()});}):_0x3a699f()[_0x40ed2c('0x683')](function(_0x160979){return _0x46bac0['section']=_0x160979,_0x565921();})[_0x40ed2c('0x130a')](function(_0x213789){const _0x1479f5=_0x40ed2c;_0x516e7b[_0x1479f5('0x52a')]({'title':_0x213789['status']?'API:'+_0x213789[_0x1479f5('0x13ee')]+_0x1479f5('0xbf6')+_0x213789['statusText']:_0x1479f5('0x144f'),'msg':_0x213789[_0x1479f5('0x13ee')]?JSON[_0x1479f5('0x258a')](_0x213789['data']):_0x213789['toString']()});});}function _0x3a699f(){return _0x486e9f(function(_0x149be4,_0x2b033a){const _0x584ca3=a0_0x4e0a;_0x4e355c['userProfileSection'][_0x584ca3('0x1e6e')]({'userProfileId':_0x46bac0[_0x584ca3('0x11ed')]['userProfileId'],'name':_0x584ca3('0x1bc0')})[_0x584ca3('0xe53')][_0x584ca3('0x683')](function(_0x32dc87){const _0x128c39=_0x584ca3,_0x82e920=_0x32dc87&&_0x32dc87[_0x128c39('0xf5d')]?_0x32dc87[_0x128c39('0xf5d')][0x0]:null;_0x149be4(_0x82e920);})['catch'](function(_0x9ed18a){_0x2b033a(_0x9ed18a);});});}function _0x565921(){return _0x486e9f(function(_0x531808,_0x6d5dc7){const _0x279994=a0_0x4e0a;return _0xb15dc0()[_0x279994('0x683')](function(_0x558497){const _0x2fb5c1=_0x279994;return _0x46bac0['items']=_0x558497['rows']?_0x558497[_0x2fb5c1('0xf5d')]:[],_0x5375bb[_0x2fb5c1('0xca1')](_0x2fb5c1('0x20c2'))?_0x558497:_0x46bac0[_0x2fb5c1('0x1aa')]?_0x46bac0[_0x2fb5c1('0x1aa')]['autoAssociation']?_0x558497:_0x4b5e13():null;})['then'](function(_0x3bde66){const _0x4a1e1d=_0x279994,_0xd93c0d=_0x3bde66&&_0x3bde66[_0x4a1e1d('0xf5d')]?_0x3bde66[_0x4a1e1d('0xf5d')]:[];return _0x46bac0['allowedItems']=_0x2e3ca0()[_0x4a1e1d('0x386')](_0xd93c0d,function(_0x59f481){const _0x230dc7=_0x4a1e1d;return _0x2e3ca0()[_0x230dc7('0x1c07')](_0x46bac0['items'],{'id':_0x5375bb[_0x230dc7('0xca1')](_0x230dc7('0x20c2'))||_0x46bac0[_0x230dc7('0x1aa')][_0x230dc7('0x170')]?_0x59f481['id']:_0x59f481['resourceId']});}),_0x46bac0[_0x4a1e1d('0x125e')]=angular[_0x4a1e1d('0x1a86')](_0x46bac0['allowedItems']),_0x46bac0['items']['forEach'](function(_0x2faa66){const _0x2b8828=_0x4a1e1d,_0x17de43=_0x2e3ca0()['find'](_0x46bac0[_0x2b8828('0x1c47')],{'id':_0x2faa66['id']});_0x5375bb['hasRole'](_0x2b8828('0x20c2'))?_0x2faa66['isValid']=!![]:_0x2faa66[_0x2b8828('0x24f4')]=typeof _0x17de43!=='undefined'?!![]:![];}),_0x4a28b2();})[_0x279994('0x683')](function(_0x13c7ff){const _0x29cb62=_0x279994,_0x1287fe=_0x13c7ff&&_0x13c7ff[_0x29cb62('0xf5d')]?_0x13c7ff['rows']:[];_0x46bac0[_0x29cb62('0x1378')]=_0x2e3ca0()['map'](_0x1287fe,function(_0xe502c3){const _0x4e053a=_0x29cb62,_0x1e63ac=_0x2e3ca0()[_0x4e053a('0x1c07')](_0x46bac0[_0x4e053a('0x1996')],{'id':_0xe502c3['id']});return _0x1e63ac[_0x4e053a('0x1e2a')]=_0xe502c3[_0x4e053a('0x211')]?_0x4e053a('0x23d0')+_0xe502c3['UserSmsAccount'][_0x4e053a('0x1e2a')]:'',_0x1e63ac[_0x4e053a('0x1d43')]=typeof _0xe502c3[_0x4e053a('0x1d43')]!==_0x4e053a('0x1867')?'<'+_0xe502c3['internal']+'>':'',_0x1e63ac;}),_0x46bac0[_0x29cb62('0x23a7')]=angular[_0x29cb62('0x1a86')](_0x46bac0['selectedItems']),_0x46bac0[_0x29cb62('0x169f')][_0x29cb62('0x1378')]=_0x46bac0[_0x29cb62('0x1378')],_0x46bac0['dualMultiselectOptions'][_0x29cb62('0x1996')]=_0x2e3ca0()[_0x29cb62('0x461')](_0x46bac0[_0x29cb62('0x1c47')],_0x46bac0[_0x29cb62('0x169f')]['selectedItems'],'id'),_0x531808();})[_0x279994('0x130a')](function(_0x5b2ef6){_0x6d5dc7(_0x5b2ef6);});});}function _0x4b5e13(){return _0x486e9f(function(_0x398dc8,_0xefd546){const _0x424123=a0_0x4e0a;return _0x4e355c[_0x424123('0xcf7')]['get']({'sectionId':_0x46bac0[_0x424123('0x1aa')]['id'],'nolimit':!![]})[_0x424123('0xe53')]['then'](function(_0x469b1d){_0x398dc8(_0x469b1d);})[_0x424123('0x130a')](function(_0x27e1d4){_0xefd546(_0x27e1d4);});});}function _0x4a28b2(){return _0x486e9f(function(_0x5c95fe,_0x354389){const _0x1b57ee=a0_0x4e0a;return _0x4e355c[_0x1b57ee('0xa0e')]['getAgents']({'id':_0x46bac0[_0x1b57ee('0xa0e')]['id'],'fields':_0x1b57ee('0x72b'),'nolimit':!![],'role':'agent'})['$promise']['then'](function(_0x315729){_0x5c95fe(_0x315729);})[_0x1b57ee('0x130a')](function(_0x155f9e){_0x354389(_0x155f9e);});});}function _0xb15dc0(){return _0x486e9f(function(_0x4e90e5,_0x3ef477){const _0xca506c=a0_0x4e0a;return _0x4e355c['user']['get']({'fields':_0xca506c('0x72b'),'nolimit':!![],'role':_0xca506c('0x2327')})[_0xca506c('0xe53')][_0xca506c('0x683')](function(_0x38d7ca){_0x4e90e5(_0x38d7ca);})[_0xca506c('0x130a')](function(_0x163fbc){_0x3ef477(_0x163fbc);});});}function _0x87512(_0x541259){return _0x486e9f(function(_0x554f85,_0x574db3){const _0x22d977=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0x541259)?_0x554f85():_0x4e355c[_0x22d977('0xa0e')][_0x22d977('0x2179')]({'id':_0x46bac0['smsAccount']['id'],'ids':_0x2e3ca0()[_0x22d977('0x386')](_0x541259,'id')})[_0x22d977('0xe53')][_0x22d977('0x683')](function(){_0x554f85();})[_0x22d977('0x130a')](function(_0x4e2425){_0x574db3(_0x4e2425);});});}function _0x5ca6e0(_0x2fcb94){return _0x486e9f(function(_0x1b6486,_0x29b716){const _0x46521c=a0_0x4e0a;_0x2e3ca0()[_0x46521c('0x173f')](_0x2fcb94)?_0x1b6486():_0x4e355c['smsAccount'][_0x46521c('0xf9')]({'id':_0x46bac0['smsAccount']['id'],'ids':_0x2e3ca0()[_0x46521c('0x386')](_0x2fcb94,'id')})[_0x46521c('0xe53')][_0x46521c('0x683')](function(){_0x1b6486();})['catch'](function(_0x8f7249){_0x29b716(_0x8f7249);});});}function _0x1ef6f1(){const _0x4c746e=_0x22a959,_0x3b6568=_0x2e3ca0()['differenceBy'](_0x46bac0['startingSelectedItems'],_0x46bac0[_0x4c746e('0x1378')],'id'),_0x25603a=_0x2e3ca0()['differenceBy'](_0x46bac0[_0x4c746e('0x1378')],_0x46bac0[_0x4c746e('0x23a7')],'id');return _0x5ca6e0(_0x3b6568)['then'](function(){return _0x87512(_0x25603a);})[_0x4c746e('0x683')](function(){const _0x1d20f1=_0x4c746e;_0x46bac0['pendingChanges']=![],_0x46bac0['startingAllowedItems']=angular[_0x1d20f1('0x1a86')](_0x46bac0[_0x1d20f1('0x1c47')]),_0x46bac0[_0x1d20f1('0x23a7')]=angular[_0x1d20f1('0x1a86')](_0x46bac0[_0x1d20f1('0x1378')]),_0x516e7b['success']({'title':_0x1d20f1('0xd28'),'msg':'Agents\x20association\x20has\x20been\x20updated!'});})[_0x4c746e('0x130a')](function(_0x3a7c6d){const _0x4d59e9=_0x4c746e;_0x516e7b['error']({'title':_0x3a7c6d[_0x4d59e9('0x13ee')]?_0x4d59e9('0x2168')+_0x3a7c6d[_0x4d59e9('0x13ee')]+_0x4d59e9('0xbf6')+_0x3a7c6d[_0x4d59e9('0x24a9')]:_0x4d59e9('0x1b71'),'msg':_0x3a7c6d['status']?JSON[_0x4d59e9('0x258a')](_0x3a7c6d['data']):_0x3a7c6d[_0x4d59e9('0x1ff0')]()});});}function _0x385f00(){const _0x5a349e=_0x22a959;_0x5094a8[_0x5a349e('0x1715')]();}}const _0x204864=_0x2b2b8c;_0x3aea56['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'smsAccountApp','smsAccount',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x3aea56(_0xba38a6,_0x4c0be8,_0xb3b8f6,_0x3bc46f,_0x361896,_0x4d90ae,_0x2c65ec,_0x5948f0){const _0x152a48=_0x189033,_0x2db797=this;_0x2db797[_0x152a48('0x11ed')]=_0x2c65ec[_0x152a48('0x20b2')](),_0x2db797[_0x152a48('0x17f')]=[],_0x2db797[_0x152a48('0xf28')]='SMS.EDIT_'+(_0x3bc46f[_0x152a48('0x11f3')]||_0x3bc46f['app'])['toUpperCase'](),_0x2db797['agent']=angular['copy'](_0x3bc46f),_0x2db797[_0x152a48('0x1134')]=_0x5948f0,_0x2db797[_0x152a48('0x258d')]={};if(_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1407')])switch(_0x2db797[_0x152a48('0x2327')][_0x152a48('0x11f3')]?_0x2db797[_0x152a48('0x2327')][_0x152a48('0x11f3')]['toLowerCase']():_0x2db797['agent'][_0x152a48('0x1d75')]['toLowerCase']()){case _0x152a48('0xbf0'):break;case'dialogflow':{const _0x136335=_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1407')][_0x152a48('0x1fc5')](',');_0x2db797[_0x152a48('0x2327')]['key']=_0x136335[0x0],_0x2db797['agent']['language']=_0x136335[0x1],_0x2db797[_0x152a48('0x2327')][_0x152a48('0x6d9')]=_0x136335[_0x152a48('0x12c8')](0x2,_0x136335[_0x152a48('0x1564')])[_0x152a48('0x1630')](',');}break;case'dialogflowv2':{const _0x2c4544=_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1407')][_0x152a48('0x1fc5')](',');_0x2db797['agent'][_0x152a48('0x2119')]=_0x2c4544[0x0],_0x2db797['agent'][_0x152a48('0x38')]=_0x2c4544[0x1],_0x2db797['agent'][_0x152a48('0x406')]=_0x2c4544[0x2],_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1a1c')]=_0x2c4544[0x3],_0x2db797[_0x152a48('0x2327')][_0x152a48('0x6d9')]=_0x2c4544[_0x152a48('0x12c8')](0x4,_0x2c4544[_0x152a48('0x1564')])[_0x152a48('0x1630')](',');}break;case _0x152a48('0x1db1'):{const _0x40bfa1=_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1407')][_0x152a48('0x1fc5')](',');_0x2db797[_0x152a48('0x2327')][_0x152a48('0x7ae')]=_0x40bfa1[0x0],_0x2db797[_0x152a48('0x2327')]['secretaccesskey']=_0x40bfa1[0x1],_0x2db797['agent'][_0x152a48('0x5ba')]=_0x40bfa1[0x2],_0x2db797['agent'][_0x152a48('0x11a9')]=_0x40bfa1[0x3],_0x2db797[_0x152a48('0x2327')][_0x152a48('0x6d9')]=_0x40bfa1[_0x152a48('0x12c8')](0x4,_0x40bfa1[_0x152a48('0x1564')])['join'](',');}break;case _0x152a48('0x2408'):{const _0x22a29d=_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1407')][_0x152a48('0x1fc5')](',');_0x2db797[_0x152a48('0x2327')][_0x152a48('0x35')]=isNaN(_0x22a29d[0x0])?_0x22a29d[0x0]:parseInt(_0x22a29d[0x0],0xa),_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1bcd')]=_0x22a29d['slice'](0x1,_0x22a29d[_0x152a48('0x1564')])['join'](',');}break;case _0x152a48('0x8c2'):_0x2db797[_0x152a48('0x2327')]['text']=_0x2db797['agent'][_0x152a48('0x1407')];break;case _0x152a48('0x877'):_0x2db797[_0x152a48('0x2327')][_0x152a48('0x60a')]=_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1407')][_0x152a48('0x1fc5')]('=')[0x0],_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1c6b')]=_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1407')]['split']('=')[0x1];break;case _0x152a48('0x19ae'):_0x2db797[_0x152a48('0x2327')][_0x152a48('0x273a')]=_0x2db797['agent']['appdata'];break;default:{const _0x44b8f4=_0x2db797[_0x152a48('0x2327')][_0x152a48('0x1407')][_0x152a48('0x1fc5')](',');_0x2db797[_0x152a48('0x2327')]['agent']=_0x2e3ca0()[_0x152a48('0x173f')](_0x44b8f4[0x0])?_0x44b8f4[0x0]:isNaN(_0x44b8f4[0x0])?_0x44b8f4[0x0]:parseInt(_0x44b8f4[0x0],0xa),_0x2db797['agent'][_0x152a48('0x1668')]=_0x2e3ca0()['isEmpty'](_0x44b8f4[0x1])?_0x44b8f4[0x1]:isNaN(_0x44b8f4[0x1])?_0x44b8f4[0x1]:parseInt(_0x44b8f4[0x1],0xa);}break;}else _0x2db797[_0x152a48('0x2327')][_0x152a48('0x1668')]=0x1e;_0x2db797[_0x152a48('0x2327')][_0x152a48('0xcf0')]&&_0x2db797[_0x152a48('0x2327')][_0x152a48('0xcf0')]['toLowerCase']()==='outbound'&&_0x2db797[_0x152a48('0x2327')][_0x152a48('0x11f3')]['toLowerCase']()===_0x152a48('0x659')&&(_0x2db797[_0x152a48('0x2327')][_0x152a48('0x24fa')]=_0x2db797[_0x152a48('0x2327')][_0x152a48('0xd31')]?_0x2db797[_0x152a48('0x2327')]['phone']['split']('$')[0x0]:undefined,_0x2db797['agent'][_0x152a48('0xabd')]=_0x2db797['agent'][_0x152a48('0x73c')]?_0x152a48('0xac1')+_0x2db797[_0x152a48('0x2327')][_0x152a48('0x73c')]:undefined);_0x2db797['saveSmsAccountApp']=_0x1e8e92,_0x2db797[_0x152a48('0xf82')]=_0x5352db,_0x2c65ec[_0x152a48('0xca1')](_0x152a48('0x20c2'))?_0x4d90ae[_0x152a48('0xc96')][_0x152a48('0x1e6e')]({'fields':_0x152a48('0xa10'),'sort':_0x152a48('0x60a'),'nolimit':_0x152a48('0x26ac'),'role':_0x152a48('0x2327')})[_0x152a48('0xe53')][_0x152a48('0x683')](function(_0x173f13){const _0xdb8c6e=_0x152a48;_0x2db797[_0xdb8c6e('0x756')]=_0x173f13['rows']||[];})['catch'](function(_0x3a3134){const _0x165752=_0x152a48;_0xb3b8f6[_0x165752('0x52a')]({'title':_0x3a3134[_0x165752('0x13ee')]?_0x165752('0x2168')+_0x3a3134['status']+_0x165752('0xbf6')+_0x3a3134[_0x165752('0x24a9')]:'SYSTEM:GET_AGENTS','msg':_0x3a3134[_0x165752('0x5a5')]?JSON['stringify'](_0x3a3134[_0x165752('0x5a5')]):_0x3a3134[_0x165752('0x1ff0')]()});}):_0x4d90ae[_0x152a48('0xc96')][_0x152a48('0x1e6e')]({'fields':_0x152a48('0xa10'),'sort':_0x152a48('0x60a'),'nolimit':'true','role':'agent'})[_0x152a48('0xe53')][_0x152a48('0x683')](function(_0x4b4c0a){const _0x3b117f=_0x152a48;_0x2db797['agents']=_0x4b4c0a[_0x3b117f('0xf5d')]||[];})[_0x152a48('0x683')](function(){const _0x476621=_0x152a48;return _0x4d90ae['userProfileSection'][_0x476621('0x1e6e')]({'userProfileId':_0x2db797[_0x476621('0x11ed')][_0x476621('0x2f')],'sectionId':0xca})[_0x476621('0xe53')];})['then'](function(_0x3e612e){const _0x4adb30=_0x152a48,_0x2315c2=_0x3e612e&&_0x3e612e['rows']?_0x3e612e[_0x4adb30('0xf5d')][0x0]:null;if(!_0x2315c2){const _0x3dd144=[];let _0x1c1940=null;_0x2db797[_0x4adb30('0x2327')]&&(_0x1c1940=_0x2e3ca0()[_0x4adb30('0x1c07')](_0x2db797['agents'],{'name':_0x2db797[_0x4adb30('0x2327')]['agent']}));for(let _0x46998f=0x0;_0x46998f<_0x2db797['agents']['length'];_0x46998f++){_0x1c1940&&_0x2db797['agents'][_0x46998f]['id']===_0x1c1940['id']&&(_0x2db797[_0x4adb30('0x756')][_0x46998f][_0x4adb30('0x319')]=![],_0x3dd144[_0x4adb30('0x1fd0')](_0x2db797['agents'][_0x46998f]));}_0x2db797[_0x4adb30('0x756')]=_0x3dd144;}else{if(!_0x2315c2[_0x4adb30('0x170')])return _0x4d90ae[_0x4adb30('0xcf7')][_0x4adb30('0x1e6e')]({'sectionId':_0x2315c2['id']})[_0x4adb30('0xe53')][_0x4adb30('0x683')](function(_0x9c1f21){const _0x4faca4=_0x4adb30,_0x4230b1=_0x2e3ca0()[_0x4faca4('0x386')](_0x9c1f21[_0x4faca4('0xf5d')],function(_0xa912bb){const _0x37b14f=_0x4faca4;return _0x2e3ca0()['find'](_0x2db797['agents'],{'id':_0xa912bb[_0x37b14f('0x832')]});});let _0x18d863=null;_0x2db797[_0x4faca4('0x2327')]&&(_0x18d863=_0x2e3ca0()[_0x4faca4('0x1c07')](_0x2db797[_0x4faca4('0x756')],{'name':_0x2db797[_0x4faca4('0x2327')][_0x4faca4('0x2327')]}));if(_0x18d863&&!_0x2e3ca0()['some'](_0x4230b1,['id',_0x18d863['id']])){const _0x2b5db4=_0x2e3ca0()[_0x4faca4('0x1c07')](_0x2db797['agents'],{'id':_0x18d863['id']});_0x2b5db4['canSelect']=![],_0x4230b1['push'](_0x2b5db4);}_0x2db797[_0x4faca4('0x756')]=_0x4230b1;});}})['catch'](function(_0x10cf1a){const _0xadc3c0=_0x152a48;_0xb3b8f6[_0xadc3c0('0x52a')]({'title':_0x10cf1a['status']?_0xadc3c0('0x2168')+_0x10cf1a[_0xadc3c0('0x13ee')]+'\x20-\x20'+_0x10cf1a['statusText']:_0xadc3c0('0x391'),'msg':_0x10cf1a['data']?JSON[_0xadc3c0('0x258a')](_0x10cf1a['data']):_0x10cf1a['toString']()});});function _0x1e8e92(){const _0x1554dd=_0x152a48;_0x2db797['errors']=[];const _0x2f2fdb=[];_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0xcf0')]&&_0x2db797['agent']['type'][_0x1554dd('0x93a')]()===_0x1554dd('0x17cd')&&_0x2db797[_0x1554dd('0x2327')]['appType']===_0x1554dd('0x4d2')&&(_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0xd31')]=_0x361896[_0x1554dd('0x145a')]?(_0x2db797['agent'][_0x1554dd('0x24fa')]||'')+'${EXTEN:'+_0x361896[_0x1554dd('0x145a')]+'}':(_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x24fa')]||'')+_0x1554dd('0x20cb'),_0x361896['recordingFormat']!==_0x1554dd('0x925')?_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x158e')][_0x1554dd('0x824')](_0x1554dd('0x1b1'))<0x0&&(_0x2db797['agent'][_0x1554dd('0x158e')]+=_0x1554dd('0x1b1')):_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x158e')]=_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x158e')][_0x1554dd('0x1725')](_0x1554dd('0x1b1'),''));const _0x512922=_0x2e3ca0()['find'](_0x2db797[_0x1554dd('0x756')],{'name':_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x2327')]});_0x512922&&(_0x2db797['agent'][_0x1554dd('0x10c5')]=_0x512922['id']);if(_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x11f3')]&&_0x2db797['agent'][_0x1554dd('0x11f3')]==='custom'){}else switch((_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x1d75')]||_0x2db797['agent'][_0x1554dd('0x11f3')])[_0x1554dd('0x93a')]()){case _0x1554dd('0x877'):_0x2db797['agent'][_0x1554dd('0x1407')]=_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x60a')]+'='+_0x2db797['agent'][_0x1554dd('0x1c6b')];break;case _0x1554dd('0xbf0'):break;default:_0x2f2fdb[0x0]=_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x2327')],_0x2f2fdb[0x1]=_0x2db797[_0x1554dd('0x2327')]['timeout'],_0x2db797[_0x1554dd('0x2327')][_0x1554dd('0x1407')]=_0x2f2fdb[_0x1554dd('0x1630')](',');}_0x5352db(_0x2db797[_0x1554dd('0x2327')]);}function _0x5352db(_0x28bc4e){const _0x1b0c7a=_0x152a48;_0xba38a6[_0x1b0c7a('0x1715')](_0x28bc4e);}}const _0x3b3fe2=_0x3aea56;_0x5c4bec['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x12dc'),'smsAccount',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x5c4bec(_0x4ddd48,_0x138905,_0x2fed0e,_0x3c463c,_0x42fb52,_0xce443f,_0x26e7ec,_0x173565){const _0x1dc437=_0x189033,_0x289093=this;_0x289093[_0x1dc437('0x11ed')]=_0x26e7ec[_0x1dc437('0x20b2')](),_0x289093[_0x1dc437('0x17f')]=[],_0x289093[_0x1dc437('0xf28')]='SMS.EDIT_'+(_0x3c463c[_0x1dc437('0x11f3')]||_0x3c463c[_0x1dc437('0x1d75')])[_0x1dc437('0x80')](),_0x289093[_0x1dc437('0x1db1')]=angular[_0x1dc437('0x1a86')](_0x3c463c),_0x289093['crudPermissions']=_0x173565,_0x289093[_0x1dc437('0x258d')]={};if(_0x289093[_0x1dc437('0x1db1')]['appdata'])switch(_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x11f3')]?_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x11f3')][_0x1dc437('0x93a')]():_0x289093['amazonlex'][_0x1dc437('0x1d75')][_0x1dc437('0x93a')]()){case _0x1dc437('0xbf0'):break;case _0x1dc437('0x205c'):{const _0x885e6f=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1407')][_0x1dc437('0x1fc5')](',');_0x289093[_0x1dc437('0x1db1')]['key']=_0x885e6f[0x0],_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1a1c')]=_0x885e6f[0x1],_0x289093['amazonlex'][_0x1dc437('0x6d9')]=_0x885e6f[_0x1dc437('0x12c8')](0x2,_0x885e6f['length'])[_0x1dc437('0x1630')](',');}break;case _0x1dc437('0xd24'):{const _0x172968=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1407')]['split'](',');_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x2119')]=_0x172968[0x0],_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x38')]=_0x172968[0x1],_0x289093[_0x1dc437('0x1db1')]['privateKey']=_0x172968[0x2],_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1a1c')]=_0x172968[0x3],_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x6d9')]=_0x172968[_0x1dc437('0x12c8')](0x4,_0x172968[_0x1dc437('0x1564')])['join'](',');}break;case _0x1dc437('0x1db1'):{const _0x480f51=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1407')][_0x1dc437('0x1fc5')](',');_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x7ae')]=_0x480f51[0x0],_0x289093['amazonlex'][_0x1dc437('0x204a')]=_0x480f51[0x1],_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x5ba')]=_0x480f51[0x2],_0x289093[_0x1dc437('0x1db1')]['botname']=_0x480f51[0x3],_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x6d9')]=_0x480f51['slice'](0x4,_0x480f51[_0x1dc437('0x1564')])[_0x1dc437('0x1630')](',');}break;case _0x1dc437('0x2408'):{const _0x6b11d7=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1407')][_0x1dc437('0x1fc5')](',');_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x35')]=isNaN(_0x6b11d7[0x0])?_0x6b11d7[0x0]:parseInt(_0x6b11d7[0x0],0xa),_0x289093['amazonlex'][_0x1dc437('0x1bcd')]=_0x6b11d7[_0x1dc437('0x12c8')](0x1,_0x6b11d7[_0x1dc437('0x1564')])[_0x1dc437('0x1630')](',');}break;case _0x1dc437('0x8c2'):_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1bcd')]=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1407')];break;case _0x1dc437('0x877'):_0x289093['amazonlex'][_0x1dc437('0x60a')]=_0x289093['amazonlex']['appdata'][_0x1dc437('0x1fc5')]('=')[0x0],_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1c6b')]=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1407')][_0x1dc437('0x1fc5')]('=')[0x1];break;case _0x1dc437('0x19ae'):_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x273a')]=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1407')];break;default:{const _0x3318fa=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x1407')][_0x1dc437('0x1fc5')](',');_0x289093[_0x1dc437('0x1db1')]['accesskeyid']=_0x2e3ca0()[_0x1dc437('0x173f')](_0x3318fa[0x0])?_0x3318fa[0x0]:isNaN(_0x3318fa[0x0])?_0x3318fa[0x0]:parseInt(_0x3318fa[0x0],0xa),_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x204a')]=_0x2e3ca0()[_0x1dc437('0x173f')](_0x3318fa[0x1])?_0x3318fa[0x1]:isNaN(_0x3318fa[0x1])?_0x3318fa[0x1]:parseInt(_0x3318fa[0x1],0xa),_0x289093[_0x1dc437('0x1db1')]['lexregion']=_0x2e3ca0()[_0x1dc437('0x173f')](_0x3318fa[0x2])?_0x3318fa[0x2]:isNaN(_0x3318fa[0x2])?_0x3318fa[0x2]:parseInt(_0x3318fa[0x2],0xa),_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x11a9')]=_0x2e3ca0()[_0x1dc437('0x173f')](_0x3318fa[0x3])?_0x3318fa[0x3]:isNaN(_0x3318fa[0x3])?_0x3318fa[0x3]:parseInt(_0x3318fa[0x3],0xa),_0x289093['amazonlex'][_0x1dc437('0x6d9')]=_0x2e3ca0()[_0x1dc437('0x173f')](_0x3318fa[0x4])?_0x3318fa[0x4]:isNaN(_0x3318fa[0x4])?_0x3318fa[0x4]:parseInt(_0x3318fa[0x4],0xa);}break;}else _0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x5ba')]=_0x1dc437('0xfb5');_0x289093['amazonlex'][_0x1dc437('0xcf0')]&&_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0xcf0')]['toLowerCase']()===_0x1dc437('0x17cd')&&_0x289093[_0x1dc437('0x1db1')]['appType'][_0x1dc437('0x93a')]()==='outbounddial'&&(_0x289093['amazonlex']['prefix']=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0xd31')]?_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0xd31')][_0x1dc437('0x1fc5')]('$')[0x0]:undefined,_0x289093['amazonlex'][_0x1dc437('0xabd')]=_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x73c')]?_0x1dc437('0xac1')+_0x289093[_0x1dc437('0x1db1')][_0x1dc437('0x73c')]:undefined);_0x289093[_0x1dc437('0x10cb')]=_0x487dad,_0x289093['closeDialog']=_0x2cede7;function _0x487dad(){const _0x4f3214=_0x1dc437;_0x289093['errors']=[];const _0x5b8c57=[];_0x289093['amazonlex'][_0x4f3214('0xcf0')]&&_0x289093[_0x4f3214('0x1db1')]['type'][_0x4f3214('0x93a')]()===_0x4f3214('0x17cd')&&_0x289093[_0x4f3214('0x1db1')]['appType']===_0x4f3214('0x4d2')&&(_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0xd31')]=_0x42fb52[_0x4f3214('0x145a')]?(_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x24fa')]||'')+_0x4f3214('0x249e')+_0x42fb52['cutdigits']+'}':(_0x289093[_0x4f3214('0x1db1')]['prefix']||'')+_0x4f3214('0x20cb'),_0x42fb52['recordingFormat']!==_0x4f3214('0x925')?_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x158e')][_0x4f3214('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x158e')]+='U(xcally-mixmonitor-context)'):_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x158e')]=_0x289093[_0x4f3214('0x1db1')]['options']['replace'](_0x4f3214('0x1b1'),''));if(_0x289093[_0x4f3214('0x1db1')]['appType']&&_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x11f3')]===_0x4f3214('0xbf0')){}else switch((_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x1d75')]||_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x11f3')])['toLowerCase']()){case'set':_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x1407')]=_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x60a')]+'='+_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x1c6b')];break;case _0x4f3214('0xbf0'):break;default:_0x5b8c57[0x0]=_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x7ae')],_0x5b8c57[0x1]=_0x289093['amazonlex'][_0x4f3214('0x204a')],_0x5b8c57[0x2]=_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x5ba')],_0x5b8c57[0x3]=_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x11a9')],_0x5b8c57[0x4]=_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x6d9')],_0x289093[_0x4f3214('0x1db1')][_0x4f3214('0x1407')]=_0x5b8c57[_0x4f3214('0x1630')](',');}_0x2cede7(_0x289093['amazonlex']);}function _0x2cede7(_0x3cd5d9){const _0x23fb9b=_0x1dc437;_0x4ddd48[_0x23fb9b('0x1715')](_0x3cd5d9);}}const _0x5620e0=_0x5c4bec;_0x231e8d[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x12dc'),_0x189033('0xa0e'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x231e8d(_0x2d8ce0,_0x364b1f,_0x2aa1b5,_0x1b8d61,_0x548053,_0x206c4c,_0x53c6cc,_0x386155){const _0x13f3ad=_0x189033,_0x3c81c7=this;_0x3c81c7[_0x13f3ad('0x11ed')]=_0x53c6cc[_0x13f3ad('0x20b2')](),_0x3c81c7[_0x13f3ad('0x17f')]=[],_0x3c81c7['title']=_0x13f3ad('0x793')+(_0x1b8d61[_0x13f3ad('0x11f3')]||_0x1b8d61[_0x13f3ad('0x1d75')])[_0x13f3ad('0x80')](),_0x3c81c7['autoreply']=angular[_0x13f3ad('0x1a86')](_0x1b8d61),_0x3c81c7[_0x13f3ad('0x1134')]=_0x386155,_0x3c81c7[_0x13f3ad('0x258d')]={};if(_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1407')])switch(_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x11f3')]?_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x11f3')][_0x13f3ad('0x93a')]():_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1d75')][_0x13f3ad('0x93a')]()){case _0x13f3ad('0xbf0'):break;case'dialogflow':{const _0x2bdc52=_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1407')][_0x13f3ad('0x1fc5')](',');_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1d46')]=_0x2bdc52[0x0],_0x3c81c7[_0x13f3ad('0x2408')]['language']=_0x2bdc52[0x1],_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x6d9')]=_0x2bdc52[_0x13f3ad('0x12c8')](0x2,_0x2bdc52[_0x13f3ad('0x1564')])[_0x13f3ad('0x1630')](',');}break;case _0x13f3ad('0xd24'):{const _0x46e5ae=_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1407')][_0x13f3ad('0x1fc5')](',');_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x2119')]=_0x46e5ae[0x0],_0x3c81c7['autoreply'][_0x13f3ad('0x38')]=_0x46e5ae[0x1],_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x406')]=_0x46e5ae[0x2],_0x3c81c7[_0x13f3ad('0x2408')]['language']=_0x46e5ae[0x3],_0x3c81c7[_0x13f3ad('0x2408')]['welcomemessage']=_0x46e5ae['slice'](0x4,_0x46e5ae['length'])['join'](',');}break;case _0x13f3ad('0x1db1'):{const _0xe7af5f=_0x3c81c7['autoreply']['appdata'][_0x13f3ad('0x1fc5')](',');_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x7ae')]=_0xe7af5f[0x0],_0x3c81c7[_0x13f3ad('0x2408')]['secretaccesskey']=_0xe7af5f[0x1],_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x5ba')]=_0xe7af5f[0x2],_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x11a9')]=_0xe7af5f[0x3],_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x6d9')]=_0xe7af5f[_0x13f3ad('0x12c8')](0x4,_0xe7af5f[_0x13f3ad('0x1564')])['join'](',');}break;case _0x13f3ad('0x2408'):{const _0x18366d=_0x3c81c7['autoreply'][_0x13f3ad('0x1407')][_0x13f3ad('0x1fc5')](',');_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x35')]=isNaN(_0x18366d[0x0])?_0x18366d[0x0]:parseInt(_0x18366d[0x0],0xa),_0x3c81c7['autoreply'][_0x13f3ad('0x1bcd')]=_0x18366d[_0x13f3ad('0x12c8')](0x1,_0x18366d[_0x13f3ad('0x1564')])[_0x13f3ad('0x1630')](',');}break;case'message':_0x3c81c7[_0x13f3ad('0x2408')]['text']=_0x3c81c7['autoreply'][_0x13f3ad('0x1407')];break;case _0x13f3ad('0x877'):_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x60a')]=_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1407')][_0x13f3ad('0x1fc5')]('=')[0x0],_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1c6b')]=_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1407')][_0x13f3ad('0x1fc5')]('=')[0x1];break;case _0x13f3ad('0x19ae'):_0x3c81c7['autoreply'][_0x13f3ad('0x273a')]=_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1407')];break;default:{const _0x420c72=_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1407')]['split'](',');_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x35')]=_0x2e3ca0()[_0x13f3ad('0x173f')](_0x420c72[0x0])?_0x420c72[0x0]:isNaN(_0x420c72[0x0])?_0x420c72[0x0]:parseInt(_0x420c72[0x0],0xa),_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x1bcd')]=_0x2e3ca0()[_0x13f3ad('0x173f')](_0x420c72[0x1])?_0x420c72[0x1]:isNaN(_0x420c72[0x1])?_0x420c72[0x1]:parseInt(_0x420c72[0x1],0xa);}}else _0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x35')]=0x1;_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0xcf0')]&&_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0xcf0')][_0x13f3ad('0x93a')]()==='outbound'&&_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x11f3')][_0x13f3ad('0x93a')]()===_0x13f3ad('0x659')&&(_0x3c81c7[_0x13f3ad('0x2408')]['prefix']=_0x3c81c7['autoreply']['phone']?_0x3c81c7['autoreply'][_0x13f3ad('0xd31')][_0x13f3ad('0x1fc5')]('$')[0x0]:undefined,_0x3c81c7['autoreply'][_0x13f3ad('0xabd')]=_0x3c81c7['autoreply'][_0x13f3ad('0x73c')]?'CALLERID(all)='+_0x3c81c7[_0x13f3ad('0x2408')][_0x13f3ad('0x73c')]:undefined);_0x3c81c7['saveSmsAccountApp']=_0x889ef4,_0x3c81c7[_0x13f3ad('0xf82')]=_0x8e251;function _0x889ef4(){const _0x21096c=_0x13f3ad;_0x3c81c7['errors']=[];const _0x3f559a=[];_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0xcf0')]&&_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0xcf0')][_0x21096c('0x93a')]()===_0x21096c('0x17cd')&&_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0x11f3')]===_0x21096c('0x4d2')&&(_0x3c81c7[_0x21096c('0x2408')]['phone']=_0x548053[_0x21096c('0x145a')]?(_0x3c81c7['autoreply'][_0x21096c('0x24fa')]||'')+_0x21096c('0x249e')+_0x548053['cutdigits']+'}':(_0x3c81c7[_0x21096c('0x2408')]['prefix']||'')+_0x21096c('0x20cb'),_0x548053[_0x21096c('0x75b')]!==_0x21096c('0x925')?_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0x158e')]['indexOf'](_0x21096c('0x1b1'))<0x0&&(_0x3c81c7[_0x21096c('0x2408')]['options']+=_0x21096c('0x1b1')):_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0x158e')]=_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0x158e')][_0x21096c('0x1725')]('U(xcally-mixmonitor-context)',''));if(_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0x11f3')]&&_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0x11f3')]===_0x21096c('0xbf0')){}else switch((_0x3c81c7['autoreply'][_0x21096c('0x1d75')]||_0x3c81c7['autoreply'][_0x21096c('0x11f3')])[_0x21096c('0x93a')]()){case _0x21096c('0x877'):_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0x1407')]=_0x3c81c7['autoreply'][_0x21096c('0x60a')]+'='+_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0x1c6b')];break;case'custom':break;default:_0x3f559a[0x0]=_0x3c81c7[_0x21096c('0x2408')][_0x21096c('0x35')],_0x3f559a[0x1]=_0x3c81c7[_0x21096c('0x2408')]['text'],_0x3c81c7['autoreply'][_0x21096c('0x1407')]=_0x3f559a[_0x21096c('0x1630')](',');}_0x8e251(_0x3c81c7['autoreply']);}function _0x8e251(_0x13eb1d){_0x2d8ce0['hide'](_0x13eb1d);}}const _0x10912d=_0x231e8d;_0x366f0e['$inject']=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x12dc'),_0x189033('0xa0e'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x366f0e(_0x234e23,_0x5e32fd,_0x4ec5e8,_0xc669e3,_0x50f144,_0x1b3f61,_0x4ab744,_0x116566){const _0x383c8a=_0x189033,_0xb500b5=this;_0xb500b5['currentUser']=_0x4ab744[_0x383c8a('0x20b2')](),_0xb500b5['errors']=[],_0xb500b5[_0x383c8a('0xf28')]=_0x383c8a('0x793')+(_0xc669e3[_0x383c8a('0x11f3')]||_0xc669e3[_0x383c8a('0x1d75')])['toUpperCase'](),_0xb500b5[_0x383c8a('0x12b0')]=angular['copy'](_0xc669e3),_0xb500b5['crudPermissions']=_0x116566,_0xb500b5['hasModulePermissions']={};if(_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x1407')])switch(_0xb500b5['close'][_0x383c8a('0x11f3')]?_0xb500b5['close'][_0x383c8a('0x11f3')]['toLowerCase']():_0xb500b5[_0x383c8a('0x12b0')]['app'][_0x383c8a('0x93a')]()){case _0x383c8a('0xbf0'):break;case _0x383c8a('0x205c'):{const _0x364abf=_0xb500b5['close'][_0x383c8a('0x1407')][_0x383c8a('0x1fc5')](',');_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x1d46')]=_0x364abf[0x0],_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x1a1c')]=_0x364abf[0x1],_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x6d9')]=_0x364abf[_0x383c8a('0x12c8')](0x2,_0x364abf[_0x383c8a('0x1564')])[_0x383c8a('0x1630')](',');}break;case _0x383c8a('0xd24'):{const _0x47edf5=_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x1407')][_0x383c8a('0x1fc5')](',');_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x2119')]=_0x47edf5[0x0],_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x38')]=_0x47edf5[0x1],_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x406')]=_0x47edf5[0x2],_0xb500b5['close'][_0x383c8a('0x1a1c')]=_0x47edf5[0x3],_0xb500b5[_0x383c8a('0x12b0')]['welcomemessage']=_0x47edf5[_0x383c8a('0x12c8')](0x4,_0x47edf5['length'])[_0x383c8a('0x1630')](',');}break;case _0x383c8a('0x1db1'):{const _0x1ef39f=_0xb500b5['close'][_0x383c8a('0x1407')][_0x383c8a('0x1fc5')](',');_0xb500b5['close'][_0x383c8a('0x7ae')]=_0x1ef39f[0x0],_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x204a')]=_0x1ef39f[0x1],_0xb500b5[_0x383c8a('0x12b0')]['lexregion']=_0x1ef39f[0x2],_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x11a9')]=_0x1ef39f[0x3],_0xb500b5['close'][_0x383c8a('0x6d9')]=_0x1ef39f[_0x383c8a('0x12c8')](0x4,_0x1ef39f[_0x383c8a('0x1564')])['join'](',');}break;case _0x383c8a('0x2408'):{const _0x4aa832=_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x1407')][_0x383c8a('0x1fc5')](',');_0xb500b5['close']['times']=isNaN(_0x4aa832[0x0])?_0x4aa832[0x0]:parseInt(_0x4aa832[0x0],0xa),_0xb500b5['close'][_0x383c8a('0x1bcd')]=_0x4aa832[_0x383c8a('0x12c8')](0x1,_0x4aa832[_0x383c8a('0x1564')])['join'](',');}break;case _0x383c8a('0x8c2'):_0xb500b5['close'][_0x383c8a('0x1bcd')]=_0xb500b5['close'][_0x383c8a('0x1407')];break;case _0x383c8a('0x877'):_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x60a')]=_0xb500b5['close'][_0x383c8a('0x1407')][_0x383c8a('0x1fc5')]('=')[0x0],_0xb500b5[_0x383c8a('0x12b0')]['value']=_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x1407')][_0x383c8a('0x1fc5')]('=')[0x1];break;case'agi':_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x273a')]=_0xb500b5[_0x383c8a('0x12b0')]['appdata'];break;default:{const _0x27b1bf=_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x1407')][_0x383c8a('0x1fc5')](',');_0xb500b5[_0x383c8a('0x12b0')]['disposition']=_0x2e3ca0()['isEmpty'](_0x27b1bf[0x0])?_0x27b1bf[0x0]:isNaN(_0x27b1bf[0x0])?_0x27b1bf[0x0]:parseInt(_0x27b1bf[0x0],0xa);}break;}else{}_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0xcf0')]&&_0xb500b5['close']['type'][_0x383c8a('0x93a')]()==='outbound'&&_0xb500b5[_0x383c8a('0x12b0')]['appType']['toLowerCase']()===_0x383c8a('0x659')&&(_0xb500b5[_0x383c8a('0x12b0')]['prefix']=_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0xd31')]?_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0xd31')][_0x383c8a('0x1fc5')]('$')[0x0]:undefined,_0xb500b5[_0x383c8a('0x12b0')]['callerId']=_0xb500b5['close']['callerID']?'CALLERID(all)='+_0xb500b5[_0x383c8a('0x12b0')][_0x383c8a('0x73c')]:undefined);_0xb500b5[_0x383c8a('0x10cb')]=_0x518092,_0xb500b5[_0x383c8a('0xf82')]=_0x28c436;function _0x518092(){const _0x4737b5=_0x383c8a;_0xb500b5['errors']=[];const _0x16ea50=[];_0xb500b5[_0x4737b5('0x12b0')]['type']&&_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0xcf0')][_0x4737b5('0x93a')]()===_0x4737b5('0x17cd')&&_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0x11f3')]==='outboundDial'&&(_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0xd31')]=_0x50f144[_0x4737b5('0x145a')]?(_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0x24fa')]||'')+'${EXTEN:'+_0x50f144[_0x4737b5('0x145a')]+'}':(_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0x24fa')]||'')+'${EXTEN}',_0x50f144[_0x4737b5('0x75b')]!==_0x4737b5('0x925')?_0xb500b5['close'][_0x4737b5('0x158e')][_0x4737b5('0x824')](_0x4737b5('0x1b1'))<0x0&&(_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0x158e')]+='U(xcally-mixmonitor-context)'):_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0x158e')]=_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0x158e')]['replace'](_0x4737b5('0x1b1'),''));if(_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0x11f3')]&&_0xb500b5['close'][_0x4737b5('0x11f3')]==='custom'){}else switch((_0xb500b5['close'][_0x4737b5('0x1d75')]||_0xb500b5['close'][_0x4737b5('0x11f3')])[_0x4737b5('0x93a')]()){case _0x4737b5('0x877'):_0xb500b5[_0x4737b5('0x12b0')]['appdata']=_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0x60a')]+'='+_0xb500b5[_0x4737b5('0x12b0')]['value'];break;case _0x4737b5('0xbf0'):break;default:_0x16ea50[0x0]=_0xb500b5[_0x4737b5('0x12b0')][_0x4737b5('0x43f')],_0xb500b5['close'][_0x4737b5('0x1407')]=_0x16ea50['join'](',');}_0x28c436(_0xb500b5[_0x4737b5('0x12b0')]);}function _0x28c436(_0x5c13e0){const _0x2eef45=_0x383c8a;_0x234e23[_0x2eef45('0x1715')](_0x5c13e0);}}const _0x25f7f8=_0x366f0e;_0x53be5c[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'smsAccountApp','smsAccount',_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0x53be5c(_0x34c91a,_0x59afe3,_0x4eeb3a,_0x92dc0e,_0x180bd1,_0x4195c5,_0x52ff41,_0x4b4d73){const _0x3c2163=_0x189033,_0x1c74e1=this;_0x1c74e1['currentUser']=_0x52ff41[_0x3c2163('0x20b2')](),_0x1c74e1[_0x3c2163('0x17f')]=[],_0x1c74e1['title']=_0x3c2163('0x793')+(_0x92dc0e['appType']||_0x92dc0e[_0x3c2163('0x1d75')])[_0x3c2163('0x80')](),_0x1c74e1[_0x3c2163('0x205c')]=angular[_0x3c2163('0x1a86')](_0x92dc0e),_0x1c74e1[_0x3c2163('0x1134')]=_0x4b4d73,_0x1c74e1[_0x3c2163('0x258d')]={};if(_0x1c74e1['dialogflow']['appdata'])switch(_0x1c74e1[_0x3c2163('0x205c')]['appType']?_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x11f3')][_0x3c2163('0x93a')]():_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1d75')][_0x3c2163('0x93a')]()){case _0x3c2163('0xbf0'):break;case _0x3c2163('0x205c'):{const _0x14b149=_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1407')][_0x3c2163('0x1fc5')](',');_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1d46')]=_0x14b149[0x0],_0x1c74e1[_0x3c2163('0x205c')]['language']=_0x14b149[0x1],_0x1c74e1['dialogflow'][_0x3c2163('0x6d9')]=_0x14b149[_0x3c2163('0x12c8')](0x2,_0x14b149[_0x3c2163('0x1564')])['join'](',');}break;case _0x3c2163('0xd24'):{const _0x417332=_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1407')]['split'](',');_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x2119')]=_0x417332[0x0],_0x1c74e1['dialogflow'][_0x3c2163('0x38')]=_0x417332[0x1],_0x1c74e1['dialogflow'][_0x3c2163('0x406')]=_0x417332[0x2],_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1a1c')]=_0x417332[0x3],_0x1c74e1['dialogflow'][_0x3c2163('0x6d9')]=_0x417332[_0x3c2163('0x12c8')](0x4,_0x417332['length'])[_0x3c2163('0x1630')](',');}break;case'amazonlex':{const _0x4a5e0f=_0x1c74e1[_0x3c2163('0x205c')]['appdata'][_0x3c2163('0x1fc5')](',');_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x7ae')]=_0x4a5e0f[0x0],_0x1c74e1['dialogflow']['secretaccesskey']=_0x4a5e0f[0x1],_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x5ba')]=_0x4a5e0f[0x2],_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x11a9')]=_0x4a5e0f[0x3],_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x6d9')]=_0x4a5e0f[_0x3c2163('0x12c8')](0x4,_0x4a5e0f['length'])[_0x3c2163('0x1630')](',');}break;case'autoreply':{const _0x23f77d=_0x1c74e1[_0x3c2163('0x205c')]['appdata'][_0x3c2163('0x1fc5')](',');_0x1c74e1[_0x3c2163('0x205c')]['times']=isNaN(_0x23f77d[0x0])?_0x23f77d[0x0]:parseInt(_0x23f77d[0x0],0xa),_0x1c74e1['dialogflow']['text']=_0x23f77d[_0x3c2163('0x12c8')](0x1,_0x23f77d['length'])[_0x3c2163('0x1630')](',');}break;case _0x3c2163('0x8c2'):_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1bcd')]=_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1407')];break;case _0x3c2163('0x877'):_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x60a')]=_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1407')][_0x3c2163('0x1fc5')]('=')[0x0],_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1c6b')]=_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1407')][_0x3c2163('0x1fc5')]('=')[0x1];break;case _0x3c2163('0x19ae'):_0x1c74e1[_0x3c2163('0x205c')]['project']=_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1407')];break;default:{const _0x2efbe8=_0x1c74e1[_0x3c2163('0x205c')]['appdata'][_0x3c2163('0x1fc5')](',');_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1d46')]=_0x2e3ca0()[_0x3c2163('0x173f')](_0x2efbe8[0x0])?_0x2efbe8[0x0]:isNaN(_0x2efbe8[0x0])?_0x2efbe8[0x0]:parseInt(_0x2efbe8[0x0],0xa),_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1a1c')]=_0x2e3ca0()[_0x3c2163('0x173f')](_0x2efbe8[0x1])?_0x2efbe8[0x1]:isNaN(_0x2efbe8[0x1])?_0x2efbe8[0x1]:parseInt(_0x2efbe8[0x1],0xa),_0x1c74e1['dialogflow'][_0x3c2163('0x6d9')]=_0x2e3ca0()[_0x3c2163('0x173f')](_0x2efbe8[0x2])?_0x2efbe8[0x2]:isNaN(_0x2efbe8[0x2])?_0x2efbe8[0x2]:parseInt(_0x2efbe8[0x2],0xa);}break;}else _0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x1a1c')]='en';_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0xcf0')]&&_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0xcf0')][_0x3c2163('0x93a')]()===_0x3c2163('0x17cd')&&_0x1c74e1[_0x3c2163('0x205c')]['appType'][_0x3c2163('0x93a')]()===_0x3c2163('0x659')&&(_0x1c74e1['dialogflow'][_0x3c2163('0x24fa')]=_0x1c74e1[_0x3c2163('0x205c')]['phone']?_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0xd31')][_0x3c2163('0x1fc5')]('$')[0x0]:undefined,_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0xabd')]=_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x73c')]?_0x3c2163('0xac1')+_0x1c74e1[_0x3c2163('0x205c')][_0x3c2163('0x73c')]:undefined);_0x1c74e1[_0x3c2163('0x10cb')]=_0x4aae46,_0x1c74e1['closeDialog']=_0x4ae39c;function _0x4aae46(){const _0x4d2299=_0x3c2163;_0x1c74e1[_0x4d2299('0x17f')]=[];const _0x4a616d=[];_0x1c74e1['dialogflow'][_0x4d2299('0xcf0')]&&_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0xcf0')]['toLowerCase']()===_0x4d2299('0x17cd')&&_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x11f3')]===_0x4d2299('0x4d2')&&(_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0xd31')]=_0x180bd1[_0x4d2299('0x145a')]?(_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x24fa')]||'')+_0x4d2299('0x249e')+_0x180bd1[_0x4d2299('0x145a')]+'}':(_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x24fa')]||'')+'${EXTEN}',_0x180bd1[_0x4d2299('0x75b')]!==_0x4d2299('0x925')?_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x158e')][_0x4d2299('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x1c74e1['dialogflow'][_0x4d2299('0x158e')]+='U(xcally-mixmonitor-context)'):_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x158e')]=_0x1c74e1['dialogflow'][_0x4d2299('0x158e')][_0x4d2299('0x1725')](_0x4d2299('0x1b1'),''));if(_0x1c74e1['dialogflow'][_0x4d2299('0x11f3')]&&_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x11f3')]===_0x4d2299('0xbf0')){}else switch((_0x1c74e1[_0x4d2299('0x205c')]['app']||_0x1c74e1['dialogflow'][_0x4d2299('0x11f3')])[_0x4d2299('0x93a')]()){case _0x4d2299('0x877'):_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x1407')]=_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x60a')]+'='+_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x1c6b')];break;case _0x4d2299('0xbf0'):break;default:_0x4a616d[0x0]=_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x1d46')],_0x4a616d[0x1]=_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x1a1c')],_0x4a616d[0x2]=_0x1c74e1[_0x4d2299('0x205c')]['welcomemessage'],_0x1c74e1[_0x4d2299('0x205c')][_0x4d2299('0x1407')]=_0x4a616d['join'](',');}_0x4ae39c(_0x1c74e1[_0x4d2299('0x205c')]);}function _0x4ae39c(_0x27b7b1){const _0x1481a4=_0x3c2163;_0x34c91a[_0x1481a4('0x1715')](_0x27b7b1);}}const _0xedc54a=_0x53be5c;_0x41eb8f[_0x189033('0x14be')]=['$mdDialog','$q','toasty',_0x189033('0x12dc'),_0x189033('0xa0e'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x41eb8f(_0x45be09,_0x4b9ed3,_0x1df028,_0x2dcd88,_0x3e2755,_0x45c146,_0x43a65e,_0x2084a3){const _0x235345=_0x189033,_0x3ba22a=this;_0x3ba22a[_0x235345('0x11ed')]=_0x43a65e['getCurrentUser'](),_0x3ba22a[_0x235345('0x17f')]=[],_0x3ba22a[_0x235345('0xf28')]=_0x235345('0x793')+(_0x2dcd88[_0x235345('0x11f3')]||_0x2dcd88[_0x235345('0x1d75')])[_0x235345('0x80')](),_0x3ba22a[_0x235345('0xc33')]=angular[_0x235345('0x1a86')](_0x2dcd88),_0x3ba22a[_0x235345('0x1134')]=_0x2084a3,_0x3ba22a['hasModulePermissions']={};if(_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1407')])switch(_0x3ba22a[_0x235345('0xc33')][_0x235345('0x11f3')]?_0x3ba22a[_0x235345('0xc33')][_0x235345('0x11f3')][_0x235345('0x93a')]():_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1d75')][_0x235345('0x93a')]()){case'custom':break;case _0x235345('0x205c'):{const _0x3b5237=_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1407')][_0x235345('0x1fc5')](',');_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1d46')]=_0x3b5237[0x0],_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1a1c')]=_0x3b5237[0x1],_0x3ba22a[_0x235345('0xc33')][_0x235345('0x6d9')]=_0x3b5237[_0x235345('0x12c8')](0x2,_0x3b5237['length'])[_0x235345('0x1630')](',');}break;case _0x235345('0xd24'):{const _0x359b42=_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1407')]['split'](',');_0x3ba22a[_0x235345('0xc33')][_0x235345('0x2119')]=_0x359b42[0x0],_0x3ba22a[_0x235345('0xc33')][_0x235345('0x38')]=_0x359b42[0x1],_0x3ba22a[_0x235345('0xc33')][_0x235345('0x406')]=_0x359b42[0x2],_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1a1c')]=_0x359b42[0x3],_0x3ba22a[_0x235345('0xc33')][_0x235345('0x6d9')]=_0x359b42[_0x235345('0x12c8')](0x4,_0x359b42['length'])[_0x235345('0x1630')](',');}break;case _0x235345('0x1db1'):{const _0x402b89=_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1407')][_0x235345('0x1fc5')](',');_0x3ba22a[_0x235345('0xc33')]['accesskeyid']=_0x402b89[0x0],_0x3ba22a['gotoif'][_0x235345('0x204a')]=_0x402b89[0x1],_0x3ba22a[_0x235345('0xc33')][_0x235345('0x5ba')]=_0x402b89[0x2],_0x3ba22a[_0x235345('0xc33')]['botname']=_0x402b89[0x3],_0x3ba22a['gotoif'][_0x235345('0x6d9')]=_0x402b89['slice'](0x4,_0x402b89[_0x235345('0x1564')])[_0x235345('0x1630')](',');}break;case _0x235345('0x2408'):{const _0xb91c26=_0x3ba22a[_0x235345('0xc33')]['appdata'][_0x235345('0x1fc5')](',');_0x3ba22a[_0x235345('0xc33')][_0x235345('0x35')]=isNaN(_0xb91c26[0x0])?_0xb91c26[0x0]:parseInt(_0xb91c26[0x0],0xa),_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1bcd')]=_0xb91c26[_0x235345('0x12c8')](0x1,_0xb91c26['length'])[_0x235345('0x1630')](',');}break;case _0x235345('0x8c2'):_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1bcd')]=_0x3ba22a['gotoif'][_0x235345('0x1407')];break;case _0x235345('0x877'):_0x3ba22a[_0x235345('0xc33')][_0x235345('0x60a')]=_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1407')]['split']('=')[0x0],_0x3ba22a[_0x235345('0xc33')][_0x235345('0x1c6b')]=_0x3ba22a['gotoif'][_0x235345('0x1407')]['split']('=')[0x1];break;case _0x235345('0x19ae'):_0x3ba22a[_0x235345('0xc33')][_0x235345('0x273a')]=_0x3ba22a['gotoif'][_0x235345('0x1407')];break;default:{const _0x52b378=_0x3ba22a[_0x235345('0xc33')]['appdata']['split'](',');_0x3ba22a['gotoif']['condition']=_0x2e3ca0()['isEmpty'](_0x52b378[0x0])?_0x52b378[0x0]:isNaN(_0x52b378[0x0])?_0x52b378[0x0]:parseInt(_0x52b378[0x0],0xa),_0x3ba22a[_0x235345('0xc33')]['truepriority']=_0x2e3ca0()[_0x235345('0x173f')](_0x52b378[0x1])?_0x52b378[0x1]:isNaN(_0x52b378[0x1])?_0x52b378[0x1]:parseInt(_0x52b378[0x1],0xa),_0x3ba22a[_0x235345('0xc33')]['falsepriority']=_0x2e3ca0()['isEmpty'](_0x52b378[0x2])?_0x52b378[0x2]:isNaN(_0x52b378[0x2])?_0x52b378[0x2]:parseInt(_0x52b378[0x2],0xa);}break;}else{}_0x3ba22a[_0x235345('0xc33')][_0x235345('0xcf0')]&&_0x3ba22a[_0x235345('0xc33')][_0x235345('0xcf0')][_0x235345('0x93a')]()==='outbound'&&_0x3ba22a[_0x235345('0xc33')]['appType'][_0x235345('0x93a')]()==='outbounddial'&&(_0x3ba22a[_0x235345('0xc33')][_0x235345('0x24fa')]=_0x3ba22a[_0x235345('0xc33')][_0x235345('0xd31')]?_0x3ba22a[_0x235345('0xc33')]['phone'][_0x235345('0x1fc5')]('$')[0x0]:undefined,_0x3ba22a[_0x235345('0xc33')][_0x235345('0xabd')]=_0x3ba22a['gotoif'][_0x235345('0x73c')]?_0x235345('0xac1')+_0x3ba22a[_0x235345('0xc33')][_0x235345('0x73c')]:undefined);_0x3ba22a[_0x235345('0x10cb')]=_0x2e1679,_0x3ba22a[_0x235345('0xf82')]=_0x36598a;function _0x2e1679(){const _0x1e472c=_0x235345;_0x3ba22a[_0x1e472c('0x17f')]=[];const _0x177492=[];_0x3ba22a['gotoif']['type']&&_0x3ba22a['gotoif'][_0x1e472c('0xcf0')][_0x1e472c('0x93a')]()===_0x1e472c('0x17cd')&&_0x3ba22a[_0x1e472c('0xc33')]['appType']===_0x1e472c('0x4d2')&&(_0x3ba22a[_0x1e472c('0xc33')]['phone']=_0x3e2755[_0x1e472c('0x145a')]?(_0x3ba22a['gotoif'][_0x1e472c('0x24fa')]||'')+_0x1e472c('0x249e')+_0x3e2755[_0x1e472c('0x145a')]+'}':(_0x3ba22a[_0x1e472c('0xc33')]['prefix']||'')+_0x1e472c('0x20cb'),_0x3e2755['recordingFormat']!=='none'?_0x3ba22a['gotoif'][_0x1e472c('0x158e')]['indexOf'](_0x1e472c('0x1b1'))<0x0&&(_0x3ba22a['gotoif'][_0x1e472c('0x158e')]+=_0x1e472c('0x1b1')):_0x3ba22a['gotoif'][_0x1e472c('0x158e')]=_0x3ba22a[_0x1e472c('0xc33')]['options'][_0x1e472c('0x1725')](_0x1e472c('0x1b1'),''));if(_0x3ba22a[_0x1e472c('0xc33')][_0x1e472c('0x11f3')]&&_0x3ba22a[_0x1e472c('0xc33')][_0x1e472c('0x11f3')]===_0x1e472c('0xbf0')){}else switch((_0x3ba22a[_0x1e472c('0xc33')][_0x1e472c('0x1d75')]||_0x3ba22a[_0x1e472c('0xc33')][_0x1e472c('0x11f3')])['toLowerCase']()){case'set':_0x3ba22a[_0x1e472c('0xc33')][_0x1e472c('0x1407')]=_0x3ba22a['gotoif'][_0x1e472c('0x60a')]+'='+_0x3ba22a[_0x1e472c('0xc33')][_0x1e472c('0x1c6b')];break;case'custom':break;default:_0x177492[0x0]=_0x3ba22a[_0x1e472c('0xc33')][_0x1e472c('0x168e')],_0x177492[0x1]=_0x3ba22a[_0x1e472c('0xc33')][_0x1e472c('0x27e5')],_0x177492[0x2]=_0x3ba22a[_0x1e472c('0xc33')][_0x1e472c('0x1813')],_0x3ba22a[_0x1e472c('0xc33')]['appdata']=_0x177492[_0x1e472c('0x1630')](',');}_0x36598a(_0x3ba22a[_0x1e472c('0xc33')]);}function _0x36598a(_0x5b6026){const _0xb8f547=_0x235345;_0x45be09[_0xb8f547('0x1715')](_0x5b6026);}}const _0x39dd5c=_0x41eb8f;_0x4a2326['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'smsAccountApp',_0x189033('0xa0e'),_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0x4a2326(_0x3ef6b7,_0x5746de,_0x5f3efb,_0x3727de,_0xb6a38f,_0x196230,_0x32db86,_0x3ec7c2){const _0x48b92b=_0x189033,_0x7f3e77=this;_0x7f3e77[_0x48b92b('0x11ed')]=_0x32db86[_0x48b92b('0x20b2')](),_0x7f3e77[_0x48b92b('0x17f')]=[],_0x7f3e77['title']=_0x48b92b('0x793')+(_0x3727de['appType']||_0x3727de['app'])[_0x48b92b('0x80')](),_0x7f3e77['gotop']=angular[_0x48b92b('0x1a86')](_0x3727de),_0x7f3e77[_0x48b92b('0x1134')]=_0x3ec7c2,_0x7f3e77[_0x48b92b('0x258d')]={};if(_0x7f3e77['gotop']['appdata'])switch(_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x11f3')]?_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x11f3')][_0x48b92b('0x93a')]():_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1d75')][_0x48b92b('0x93a')]()){case _0x48b92b('0xbf0'):break;case'dialogflow':{const _0x1a9f88=_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1407')][_0x48b92b('0x1fc5')](',');_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1d46')]=_0x1a9f88[0x0],_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1a1c')]=_0x1a9f88[0x1],_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x6d9')]=_0x1a9f88[_0x48b92b('0x12c8')](0x2,_0x1a9f88['length'])[_0x48b92b('0x1630')](',');}break;case'dialogflowv2':{const _0x15d818=_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1407')]['split'](',');_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x2119')]=_0x15d818[0x0],_0x7f3e77[_0x48b92b('0x1da0')]['clientEmail']=_0x15d818[0x1],_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x406')]=_0x15d818[0x2],_0x7f3e77[_0x48b92b('0x1da0')]['language']=_0x15d818[0x3],_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x6d9')]=_0x15d818[_0x48b92b('0x12c8')](0x4,_0x15d818[_0x48b92b('0x1564')])['join'](',');}break;case'amazonlex':{const _0x222c5f=_0x7f3e77['gotop']['appdata'][_0x48b92b('0x1fc5')](',');_0x7f3e77['gotop']['accesskeyid']=_0x222c5f[0x0],_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x204a')]=_0x222c5f[0x1],_0x7f3e77[_0x48b92b('0x1da0')]['lexregion']=_0x222c5f[0x2],_0x7f3e77['gotop']['botname']=_0x222c5f[0x3],_0x7f3e77['gotop'][_0x48b92b('0x6d9')]=_0x222c5f[_0x48b92b('0x12c8')](0x4,_0x222c5f[_0x48b92b('0x1564')])[_0x48b92b('0x1630')](',');}break;case _0x48b92b('0x2408'):{const _0x54e06f=_0x7f3e77['gotop']['appdata'][_0x48b92b('0x1fc5')](',');_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x35')]=isNaN(_0x54e06f[0x0])?_0x54e06f[0x0]:parseInt(_0x54e06f[0x0],0xa),_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1bcd')]=_0x54e06f[_0x48b92b('0x12c8')](0x1,_0x54e06f[_0x48b92b('0x1564')])['join'](',');}break;case _0x48b92b('0x8c2'):_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1bcd')]=_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1407')];break;case'set':_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x60a')]=_0x7f3e77[_0x48b92b('0x1da0')]['appdata'][_0x48b92b('0x1fc5')]('=')[0x0],_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1c6b')]=_0x7f3e77['gotop'][_0x48b92b('0x1407')][_0x48b92b('0x1fc5')]('=')[0x1];break;case _0x48b92b('0x19ae'):_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x273a')]=_0x7f3e77[_0x48b92b('0x1da0')]['appdata'];break;default:{const _0x4e1bf9=_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x1407')][_0x48b92b('0x1fc5')](',');_0x7f3e77['gotop'][_0x48b92b('0xe1e')]=_0x2e3ca0()['isEmpty'](_0x4e1bf9[0x0])?_0x4e1bf9[0x0]:isNaN(_0x4e1bf9[0x0])?_0x4e1bf9[0x0]:parseInt(_0x4e1bf9[0x0],0xa);}break;}else{}_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0xcf0')]&&_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0xcf0')][_0x48b92b('0x93a')]()===_0x48b92b('0x17cd')&&_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x11f3')][_0x48b92b('0x93a')]()===_0x48b92b('0x659')&&(_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x24fa')]=_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0xd31')]?_0x7f3e77['gotop'][_0x48b92b('0xd31')][_0x48b92b('0x1fc5')]('$')[0x0]:undefined,_0x7f3e77[_0x48b92b('0x1da0')]['callerId']=_0x7f3e77[_0x48b92b('0x1da0')][_0x48b92b('0x73c')]?_0x48b92b('0xac1')+_0x7f3e77['gotop']['callerID']:undefined);_0x7f3e77[_0x48b92b('0x10cb')]=_0x2add8f,_0x7f3e77['closeDialog']=_0x358faf;function _0x2add8f(){const _0x28d85c=_0x48b92b;_0x7f3e77[_0x28d85c('0x17f')]=[];const _0x32eafb=[];_0x7f3e77[_0x28d85c('0x1da0')]['type']&&_0x7f3e77[_0x28d85c('0x1da0')]['type'][_0x28d85c('0x93a')]()===_0x28d85c('0x17cd')&&_0x7f3e77['gotop']['appType']==='outboundDial'&&(_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0xd31')]=_0xb6a38f[_0x28d85c('0x145a')]?(_0x7f3e77['gotop'][_0x28d85c('0x24fa')]||'')+_0x28d85c('0x249e')+_0xb6a38f[_0x28d85c('0x145a')]+'}':(_0x7f3e77[_0x28d85c('0x1da0')]['prefix']||'')+_0x28d85c('0x20cb'),_0xb6a38f[_0x28d85c('0x75b')]!==_0x28d85c('0x925')?_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0x158e')]['indexOf'](_0x28d85c('0x1b1'))<0x0&&(_0x7f3e77[_0x28d85c('0x1da0')]['options']+=_0x28d85c('0x1b1')):_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0x158e')]=_0x7f3e77['gotop'][_0x28d85c('0x158e')][_0x28d85c('0x1725')](_0x28d85c('0x1b1'),''));if(_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0x11f3')]&&_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0x11f3')]===_0x28d85c('0xbf0')){}else switch((_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0x1d75')]||_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0x11f3')])[_0x28d85c('0x93a')]()){case _0x28d85c('0x877'):_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0x1407')]=_0x7f3e77[_0x28d85c('0x1da0')]['name']+'='+_0x7f3e77[_0x28d85c('0x1da0')]['value'];break;case _0x28d85c('0xbf0'):break;default:_0x32eafb[0x0]=_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0xe1e')],_0x7f3e77[_0x28d85c('0x1da0')][_0x28d85c('0x1407')]=_0x32eafb['join'](',');}_0x358faf(_0x7f3e77[_0x28d85c('0x1da0')]);}function _0x358faf(_0x5bbc59){const _0x2a86fc=_0x48b92b;_0x3ef6b7[_0x2a86fc('0x1715')](_0x5bbc59);}}const _0x17f988=_0x4a2326;_0x6cafe5[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x1e48'),_0x189033('0xb33'),_0x189033('0x844'),_0x189033('0x115c'),'intervals',_0x189033('0x1d70'),_0x189033('0x56b'),'Auth','crudPermissions'];function _0x6cafe5(_0x41fa07,_0x31bf58,_0x1f0d57,_0x59beae,_0xecb398,_0x5215b4,_0x2eafae,_0x57bb7f,_0x5f15d8,_0x29dc08){const _0x204ca0=_0x189033,_0x31adf3=this;_0x31adf3[_0x204ca0('0x11ed')]=_0x5f15d8[_0x204ca0('0x20b2')](),_0x31adf3['errors']=[],_0x31adf3[_0x204ca0('0xf28')]=_0x204ca0('0xc62'),_0x31adf3[_0x204ca0('0x115c')]=angular['copy'](_0xecb398),_0x31adf3[_0x204ca0('0xe98')]=_0x5215b4,_0x31adf3[_0x204ca0('0x1470')]=![],_0x31adf3[_0x204ca0('0x1de1')]=[_0x204ca0('0x10af'),_0x204ca0('0xbf0'),'list'],_0x31adf3['crudPermissions']=_0x29dc08,_0x31adf3[_0x204ca0('0x167a')]=_0x59beae[_0x204ca0('0xe88')](),_0x31adf3[_0x204ca0('0x1dfd')]=_0x59beae['getMonthNumber'](),_0x31adf3[_0x204ca0('0x1e32')]=_0x59beae[_0x204ca0('0x1fe4')](),_0x31adf3[_0x204ca0('0x13ce')]=_0x59beae['getDaysOfMonth']();if(!_0x31adf3['interval'])_0x31adf3[_0x204ca0('0x115c')]={'interval':_0x204ca0('0x1b54')},_0x31adf3[_0x204ca0('0xcf0')]=_0x204ca0('0x10af'),_0x31adf3[_0x204ca0('0xf28')]='TOOLS.NEW_INTERVAL',_0x31adf3[_0x204ca0('0x1470')]=!![];else{if(_0x31adf3[_0x204ca0('0x115c')]['interval']!==_0x204ca0('0x1b54')){_0x31adf3[_0x204ca0('0xcf0')]=_0x204ca0('0xbf0');const _0x4d2091=_0x31adf3[_0x204ca0('0x115c')][_0x204ca0('0x115c')]['split'](','),_0x5d1836=_0x4d2091[0x0],_0x37461f=_0x4d2091[0x1],_0x2665b6=_0x4d2091[0x2],_0x1b78f3=_0x4d2091[0x3];if(_0x5d1836!=='*'){const _0xcffca3=_0x5d1836['split']('-')[0x0],_0x2009ba=_0x5d1836['split']('-')[0x1];let _0x355466;_0x355466=new Date(),_0x355466[_0x204ca0('0x2813')](Number(_0xcffca3[_0x204ca0('0x1fc5')](':')[0x0])),_0x355466[_0x204ca0('0x1fb7')](Number(_0xcffca3[_0x204ca0('0x1fc5')](':')[0x1])),_0x31adf3[_0x204ca0('0xc32')]=_0x355466,_0x355466=new Date(),_0x355466[_0x204ca0('0x2813')](Number(_0x2009ba[_0x204ca0('0x1fc5')](':')[0x0])),_0x355466[_0x204ca0('0x1fb7')](Number(_0x2009ba['split'](':')[0x1])),_0x31adf3[_0x204ca0('0xaa0')]=_0x355466;}_0x37461f!=='*'&&(_0x31adf3['dayOfWeekFrom']=_0x37461f[_0x204ca0('0x1fc5')]('-')[0x0],_0x31adf3[_0x204ca0('0x1269')]=_0x37461f[_0x204ca0('0x1fc5')]('-')[0x1]),_0x2665b6!=='*'&&(_0x31adf3[_0x204ca0('0xf13')]=_0x2665b6[_0x204ca0('0x1fc5')]('-')[0x0],_0x31adf3[_0x204ca0('0xfe5')]=_0x2665b6['split']('-')[0x1]),_0x1b78f3!=='*'&&(_0x31adf3[_0x204ca0('0x1690')]=_0x1b78f3[_0x204ca0('0x1fc5')]('-')[0x0],_0x31adf3[_0x204ca0('0x1f12')]=_0x1b78f3[_0x204ca0('0x1fc5')]('-')[0x1]);}else _0x31adf3['type']=_0x204ca0('0x10af');}_0x41fa07[_0x204ca0('0x7f2')]['id']&&!_0x31adf3[_0x204ca0('0x115c')]['application']&&(_0x31adf3[_0x204ca0('0x115c')][_0x204ca0('0x5ae')]=_0x41fa07['params']['id']);_0x31adf3[_0x204ca0('0x115c')]['IntervalId']&&_0x31adf3[_0x204ca0('0x115c')][_0x204ca0('0x121e')]&&(_0x31adf3['type']=_0x204ca0('0x2335'));_0x31adf3['addNewInterval']=_0x4fc23a,_0x31adf3['saveInterval']=_0x4b6119,_0x31adf3[_0x204ca0('0xf82')]=_0x4f24d8;_0x31adf3[_0x204ca0('0x115c')][_0x204ca0('0x121e')]&&(_0x5f15d8[_0x204ca0('0xca1')](_0x204ca0('0x20c2'))?_0x57bb7f[_0x204ca0('0x115c')]['get']({'fields':_0x204ca0('0x1e24'),'IntervalId':_0x204ca0('0x13c'),'nolimit':!![]})[_0x204ca0('0xe53')]['then'](function(_0x12971b){const _0x164096=_0x204ca0;_0x31adf3[_0x164096('0xe98')]=_0x12971b['rows']||[];})[_0x204ca0('0x130a')](function(_0x1aa4da){const _0x48abb5=_0x204ca0;_0x2eafae[_0x48abb5('0x52a')]({'title':_0x1aa4da[_0x48abb5('0x13ee')]?_0x48abb5('0x2168')+_0x1aa4da[_0x48abb5('0x13ee')]+'\x20-\x20'+_0x1aa4da[_0x48abb5('0x24a9')]:_0x48abb5('0x1e65'),'msg':_0x1aa4da[_0x48abb5('0x5a5')]?JSON['stringify'](_0x1aa4da[_0x48abb5('0x5a5')]):_0x1aa4da['toString']()});}):_0x57bb7f[_0x204ca0('0x115c')][_0x204ca0('0x1e6e')]({'fields':'id,name,interval,IntervalId','IntervalId':_0x204ca0('0x13c'),'nolimit':!![]})[_0x204ca0('0xe53')][_0x204ca0('0x683')](function(_0x947733){const _0x607d78=_0x204ca0;_0x31adf3['intervals']=_0x947733[_0x607d78('0xf5d')]||[];})[_0x204ca0('0x683')](function(){const _0x4c3be0=_0x204ca0;return _0x57bb7f[_0x4c3be0('0x22df')][_0x4c3be0('0x1e6e')]({'userProfileId':_0x31adf3[_0x4c3be0('0x11ed')][_0x4c3be0('0x2f')],'sectionId':0x3ec})[_0x4c3be0('0xe53')];})[_0x204ca0('0x683')](function(_0x154b68){const _0x4c69d7=_0x204ca0,_0x57ebfa=_0x154b68&&_0x154b68[_0x4c69d7('0xf5d')]?_0x154b68[_0x4c69d7('0xf5d')][0x0]:null;if(!_0x57ebfa)_0x31adf3[_0x4c69d7('0xe98')]=[];else{if(!_0x57ebfa[_0x4c69d7('0x170')])return _0x57bb7f[_0x4c69d7('0xcf7')][_0x4c69d7('0x1e6e')]({'sectionId':_0x57ebfa['id']})['$promise'][_0x4c69d7('0x683')](function(_0x471e99){const _0x4955f3=_0x4c69d7,_0x337b84=_0x471e99&&_0x471e99[_0x4955f3('0xf5d')]?_0x471e99[_0x4955f3('0xf5d')]:[],_0x57da06=[];let _0x63c248=null;_0x31adf3['interval']&&(_0x63c248=_0x2e3ca0()['find'](_0x31adf3['intervals'],{'name':_0x31adf3['interval'][_0x4955f3('0x5ae')]})),_0x63c248&&!_0x2e3ca0()[_0x4955f3('0x7a2')](_0x337b84,['resourceId',_0x63c248['id']])&&_0x31adf3['intervals'][_0x4955f3('0x1299')](function(_0x3e6f8b){const _0x34684c=_0x4955f3;_0x3e6f8b['id']===_0x63c248['id']&&(_0x3e6f8b['canSelect']=![],_0x57da06[_0x34684c('0x1fd0')](_0x3e6f8b));}),_0x31adf3[_0x4955f3('0xe98')]=_0x57da06;});}})['catch'](function(_0x2d5118){const _0x350c8e=_0x204ca0;_0x2eafae[_0x350c8e('0x52a')]({'title':_0x2d5118[_0x350c8e('0x13ee')]?_0x350c8e('0x2168')+_0x2d5118['status']+_0x350c8e('0xbf6')+_0x2d5118['statusText']:_0x350c8e('0x1e65'),'msg':_0x2d5118['data']?JSON[_0x350c8e('0x258a')](_0x2d5118[_0x350c8e('0x5a5')]):_0x2d5118['toString']()});}));function _0x3336ad(){const _0x5a1d53=_0x204ca0;switch(_0x31adf3[_0x5a1d53('0xcf0')]){case'always':case'list':return _0x5a1d53('0x1b54');case _0x5a1d53('0xbf0'):{const _0x290d59=[];if(_0x31adf3[_0x5a1d53('0xc32')]!=='*'&&_0x31adf3['timeRangeFrom']&&_0x31adf3[_0x5a1d53('0xaa0')]){const _0x4cb43a=(_0x31adf3[_0x5a1d53('0xc32')][_0x5a1d53('0x2575')]()<0xa?'0':'')+_0x31adf3['timeRangeFrom'][_0x5a1d53('0x2575')]()+':'+((_0x31adf3[_0x5a1d53('0xc32')][_0x5a1d53('0x1b5b')]()<0xa?'0':'')+_0x31adf3['timeRangeFrom']['getMinutes']()),_0x2f9f66=(_0x31adf3[_0x5a1d53('0xaa0')]['getHours']()<0xa?'0':'')+_0x31adf3['timeRangeTo'][_0x5a1d53('0x2575')]()+':'+((_0x31adf3['timeRangeTo'][_0x5a1d53('0x1b5b')]()<0xa?'0':'')+_0x31adf3[_0x5a1d53('0xaa0')][_0x5a1d53('0x1b5b')]());_0x290d59[_0x5a1d53('0x1fd0')](_0x4cb43a+'-'+_0x2f9f66);}else _0x290d59[_0x5a1d53('0x1fd0')]('*');return _0x31adf3[_0x5a1d53('0x232d')]?_0x31adf3[_0x5a1d53('0x1269')]?_0x290d59[_0x5a1d53('0x1fd0')](_0x31adf3['dayOfWeekFrom']+'-'+_0x31adf3[_0x5a1d53('0x1269')]):_0x290d59[_0x5a1d53('0x1fd0')](_0x31adf3['dayOfWeekFrom']):_0x290d59[_0x5a1d53('0x1fd0')]('*'),_0x31adf3['monthDayFrom']?_0x31adf3[_0x5a1d53('0xfe5')]?_0x290d59['push'](_0x31adf3['monthDayFrom']+'-'+_0x31adf3['monthDayTo']):_0x290d59['push'](_0x31adf3[_0x5a1d53('0xf13')]):_0x290d59[_0x5a1d53('0x1fd0')]('*'),_0x31adf3['monthFrom']?_0x31adf3[_0x5a1d53('0x1f12')]?_0x290d59[_0x5a1d53('0x1fd0')](_0x31adf3[_0x5a1d53('0x1690')]+'-'+_0x31adf3[_0x5a1d53('0x1f12')]):_0x290d59[_0x5a1d53('0x1fd0')](_0x31adf3[_0x5a1d53('0x1690')]):_0x290d59[_0x5a1d53('0x1fd0')]('*'),_0x290d59[_0x5a1d53('0x1630')]();}}}function _0x4fc23a(){const _0x599cbd=_0x204ca0;_0x31adf3[_0x599cbd('0x17f')]=[],_0x31adf3[_0x599cbd('0x115c')][_0x599cbd('0x115c')]=_0x3336ad(),_0x57bb7f[_0x599cbd('0x115c')][_0x599cbd('0xb0a')](_0x31adf3[_0x599cbd('0x115c')])[_0x599cbd('0xe53')][_0x599cbd('0x683')](function(_0x2773ce){const _0x48f829=_0x599cbd;_0x31adf3['intervals'][_0x48f829('0x1fd0')](_0x2773ce),_0x2eafae[_0x48f829('0x53')]({'title':_0x48f829('0x24b5'),'msg':_0x31adf3[_0x48f829('0x115c')]['name']?_0x31adf3[_0x48f829('0x115c')]['name']+_0x48f829('0x14b5'):''}),_0x4f24d8();})[_0x599cbd('0x130a')](function(_0x536f66){const _0x5aa4ce=_0x599cbd;console[_0x5aa4ce('0x52a')](_0x536f66),_0x31adf3[_0x5aa4ce('0x17f')]=_0x536f66[_0x5aa4ce('0x5a5')][_0x5aa4ce('0x17f')]||[{'message':_0x536f66[_0x5aa4ce('0x1ff0')](),'type':_0x5aa4ce('0x1d24')}];});}function _0x4b6119(){const _0x17a082=_0x204ca0;_0x31adf3['errors']=[],_0x31adf3[_0x17a082('0x115c')][_0x17a082('0x115c')]=_0x3336ad(),_0x31adf3[_0x17a082('0x115c')]['application']?(_0x31adf3['type']!==_0x17a082('0x2335')&&(_0x31adf3[_0x17a082('0x115c')][_0x17a082('0x5ae')]=null),_0x4f24d8(_0x31adf3['interval'])):_0x57bb7f[_0x17a082('0x115c')][_0x17a082('0x2480')]({'id':_0x31adf3[_0x17a082('0x115c')]['id']},_0x31adf3[_0x17a082('0x115c')])[_0x17a082('0xe53')][_0x17a082('0x683')](function(_0x48f590){const _0x2128cd=_0x17a082,_0x1b9c2f=_0x2e3ca0()[_0x2128cd('0x1c07')](_0x31adf3['intervals'],{'id':_0x48f590['id']});_0x1b9c2f&&_0x2e3ca0()[_0x2128cd('0xf22')](_0x1b9c2f,_0x48f590),_0x2eafae[_0x2128cd('0x53')]({'title':_0x2128cd('0x18c3'),'msg':_0x2128cd('0x224')}),_0x4f24d8();})[_0x17a082('0x130a')](function(_0x46d740){const _0xf4cd6f=_0x17a082;console['error'](_0x46d740),_0x31adf3[_0xf4cd6f('0x17f')]=_0x46d740[_0xf4cd6f('0x5a5')][_0xf4cd6f('0x17f')]||[{'message':_0x46d740[_0xf4cd6f('0x1ff0')](),'type':_0xf4cd6f('0x605')}];});}function _0x4f24d8(_0x270a86){const _0xc32b4=_0x204ca0;_0x31bf58[_0xc32b4('0x1715')](_0x270a86);}}const _0x1313af=_0x6cafe5;_0x5d3dd6[_0x189033('0x14be')]=['$mdDialog','$q','toasty',_0x189033('0x12dc'),_0x189033('0xa0e'),_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0x5d3dd6(_0x31d0fa,_0x1234fd,_0x57f68c,_0x191110,_0x503a1c,_0x585778,_0x31d53a,_0x5be2a4){const _0x277e9f=_0x189033,_0x16e1e7=this;_0x16e1e7[_0x277e9f('0x11ed')]=_0x31d53a[_0x277e9f('0x20b2')](),_0x16e1e7[_0x277e9f('0x17f')]=[],_0x16e1e7['title']=_0x277e9f('0x793')+(_0x191110[_0x277e9f('0x11f3')]||_0x191110[_0x277e9f('0x1d75')])[_0x277e9f('0x80')](),_0x16e1e7[_0x277e9f('0x1126')]=angular[_0x277e9f('0x1a86')](_0x191110),_0x16e1e7[_0x277e9f('0x1134')]=_0x5be2a4,_0x16e1e7[_0x277e9f('0x258d')]={};if(_0x16e1e7['noop'][_0x277e9f('0x1407')])switch(_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x11f3')]?_0x16e1e7['noop'][_0x277e9f('0x11f3')]['toLowerCase']():_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x1d75')][_0x277e9f('0x93a')]()){case _0x277e9f('0xbf0'):break;case'dialogflow':{const _0x475e10=_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x1407')]['split'](',');_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x1d46')]=_0x475e10[0x0],_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x1a1c')]=_0x475e10[0x1],_0x16e1e7['noop'][_0x277e9f('0x6d9')]=_0x475e10[_0x277e9f('0x12c8')](0x2,_0x475e10[_0x277e9f('0x1564')])[_0x277e9f('0x1630')](',');}break;case _0x277e9f('0xd24'):{const _0x468807=_0x16e1e7['noop']['appdata'][_0x277e9f('0x1fc5')](',');_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x2119')]=_0x468807[0x0],_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x38')]=_0x468807[0x1],_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x406')]=_0x468807[0x2],_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x1a1c')]=_0x468807[0x3],_0x16e1e7['noop'][_0x277e9f('0x6d9')]=_0x468807[_0x277e9f('0x12c8')](0x4,_0x468807[_0x277e9f('0x1564')])['join'](',');}break;case _0x277e9f('0x1db1'):{const _0x29623d=_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x1407')]['split'](',');_0x16e1e7['noop'][_0x277e9f('0x7ae')]=_0x29623d[0x0],_0x16e1e7['noop'][_0x277e9f('0x204a')]=_0x29623d[0x1],_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x5ba')]=_0x29623d[0x2],_0x16e1e7[_0x277e9f('0x1126')]['botname']=_0x29623d[0x3],_0x16e1e7['noop'][_0x277e9f('0x6d9')]=_0x29623d[_0x277e9f('0x12c8')](0x4,_0x29623d[_0x277e9f('0x1564')])['join'](',');}break;case _0x277e9f('0x2408'):{const _0x3d024c=_0x16e1e7[_0x277e9f('0x1126')]['appdata'][_0x277e9f('0x1fc5')](',');_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x35')]=isNaN(_0x3d024c[0x0])?_0x3d024c[0x0]:parseInt(_0x3d024c[0x0],0xa),_0x16e1e7[_0x277e9f('0x1126')]['text']=_0x3d024c['slice'](0x1,_0x3d024c['length'])[_0x277e9f('0x1630')](',');}break;case'message':_0x16e1e7['noop'][_0x277e9f('0x1bcd')]=_0x16e1e7['noop'][_0x277e9f('0x1407')];break;case _0x277e9f('0x877'):_0x16e1e7['noop'][_0x277e9f('0x60a')]=_0x16e1e7['noop']['appdata'][_0x277e9f('0x1fc5')]('=')[0x0],_0x16e1e7[_0x277e9f('0x1126')]['value']=_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x1407')][_0x277e9f('0x1fc5')]('=')[0x1];break;case _0x277e9f('0x19ae'):_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x273a')]=_0x16e1e7['noop'][_0x277e9f('0x1407')];break;default:{const _0x2731ae=_0x16e1e7['noop'][_0x277e9f('0x1407')][_0x277e9f('0x1fc5')](',');_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x1c6b')]=_0x2e3ca0()['isEmpty'](_0x2731ae[0x0])?_0x2731ae[0x0]:isNaN(_0x2731ae[0x0])?_0x2731ae[0x0]:parseInt(_0x2731ae[0x0],0xa);}break;}else{}_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0xcf0')]&&_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0xcf0')][_0x277e9f('0x93a')]()===_0x277e9f('0x17cd')&&_0x16e1e7['noop'][_0x277e9f('0x11f3')][_0x277e9f('0x93a')]()===_0x277e9f('0x659')&&(_0x16e1e7['noop'][_0x277e9f('0x24fa')]=_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0xd31')]?_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0xd31')][_0x277e9f('0x1fc5')]('$')[0x0]:undefined,_0x16e1e7['noop'][_0x277e9f('0xabd')]=_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x73c')]?_0x277e9f('0xac1')+_0x16e1e7[_0x277e9f('0x1126')][_0x277e9f('0x73c')]:undefined);_0x16e1e7[_0x277e9f('0x10cb')]=_0x65d262,_0x16e1e7[_0x277e9f('0xf82')]=_0x58928d;function _0x65d262(){const _0x4b770b=_0x277e9f;_0x16e1e7[_0x4b770b('0x17f')]=[];const _0x284e61=[];_0x16e1e7['noop'][_0x4b770b('0xcf0')]&&_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0xcf0')][_0x4b770b('0x93a')]()===_0x4b770b('0x17cd')&&_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x11f3')]===_0x4b770b('0x4d2')&&(_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0xd31')]=_0x503a1c[_0x4b770b('0x145a')]?(_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x24fa')]||'')+_0x4b770b('0x249e')+_0x503a1c[_0x4b770b('0x145a')]+'}':(_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x24fa')]||'')+_0x4b770b('0x20cb'),_0x503a1c[_0x4b770b('0x75b')]!==_0x4b770b('0x925')?_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x158e')][_0x4b770b('0x824')](_0x4b770b('0x1b1'))<0x0&&(_0x16e1e7['noop'][_0x4b770b('0x158e')]+=_0x4b770b('0x1b1')):_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x158e')]=_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x158e')][_0x4b770b('0x1725')](_0x4b770b('0x1b1'),''));if(_0x16e1e7['noop'][_0x4b770b('0x11f3')]&&_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x11f3')]===_0x4b770b('0xbf0')){}else switch((_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x1d75')]||_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x11f3')])['toLowerCase']()){case _0x4b770b('0x877'):_0x16e1e7['noop']['appdata']=_0x16e1e7[_0x4b770b('0x1126')]['name']+'='+_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x1c6b')];break;case _0x4b770b('0xbf0'):break;default:_0x284e61[0x0]=_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x1c6b')],_0x16e1e7[_0x4b770b('0x1126')][_0x4b770b('0x1407')]=_0x284e61[_0x4b770b('0x1630')](',');}_0x58928d(_0x16e1e7[_0x4b770b('0x1126')]);}function _0x58928d(_0x142fd7){const _0x47e96b=_0x277e9f;_0x31d0fa[_0x47e96b('0x1715')](_0x142fd7);}}const _0x37c06d=_0x5d3dd6;_0x1ee3fa[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x12dc'),_0x189033('0xa0e'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x1ee3fa(_0x5b8e3b,_0x4490fd,_0x278412,_0x120040,_0x4a5ce4,_0x45d1d1,_0x632c87,_0x2c67dc){const _0x179b16=_0x189033,_0x327ce4=this;_0x327ce4[_0x179b16('0x11ed')]=_0x632c87[_0x179b16('0x20b2')](),_0x327ce4[_0x179b16('0x17f')]=[],_0x327ce4[_0x179b16('0xf28')]=_0x179b16('0x793')+(_0x120040[_0x179b16('0x11f3')]||_0x120040[_0x179b16('0x1d75')])[_0x179b16('0x80')](),_0x327ce4[_0x179b16('0x660')]=angular[_0x179b16('0x1a86')](_0x120040),_0x327ce4[_0x179b16('0x1134')]=_0x2c67dc,_0x327ce4[_0x179b16('0x258d')]={};if(_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1407')])switch(_0x327ce4[_0x179b16('0x660')]['appType']?_0x327ce4[_0x179b16('0x660')][_0x179b16('0x11f3')]['toLowerCase']():_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1d75')][_0x179b16('0x93a')]()){case'custom':break;case _0x179b16('0x205c'):{const _0xe69a17=_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1407')]['split'](',');_0x327ce4['queue'][_0x179b16('0x1d46')]=_0xe69a17[0x0],_0x327ce4['queue'][_0x179b16('0x1a1c')]=_0xe69a17[0x1],_0x327ce4['queue'][_0x179b16('0x6d9')]=_0xe69a17[_0x179b16('0x12c8')](0x2,_0xe69a17['length'])[_0x179b16('0x1630')](',');}break;case _0x179b16('0xd24'):{const _0x2a75bf=_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1407')][_0x179b16('0x1fc5')](',');_0x327ce4[_0x179b16('0x660')][_0x179b16('0x2119')]=_0x2a75bf[0x0],_0x327ce4[_0x179b16('0x660')][_0x179b16('0x38')]=_0x2a75bf[0x1],_0x327ce4[_0x179b16('0x660')][_0x179b16('0x406')]=_0x2a75bf[0x2],_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1a1c')]=_0x2a75bf[0x3],_0x327ce4[_0x179b16('0x660')]['welcomemessage']=_0x2a75bf[_0x179b16('0x12c8')](0x4,_0x2a75bf[_0x179b16('0x1564')])[_0x179b16('0x1630')](',');}break;case _0x179b16('0x1db1'):{const _0x5545f8=_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1407')][_0x179b16('0x1fc5')](',');_0x327ce4[_0x179b16('0x660')][_0x179b16('0x7ae')]=_0x5545f8[0x0],_0x327ce4['queue']['secretaccesskey']=_0x5545f8[0x1],_0x327ce4[_0x179b16('0x660')][_0x179b16('0x5ba')]=_0x5545f8[0x2],_0x327ce4[_0x179b16('0x660')][_0x179b16('0x11a9')]=_0x5545f8[0x3],_0x327ce4[_0x179b16('0x660')]['welcomemessage']=_0x5545f8[_0x179b16('0x12c8')](0x4,_0x5545f8['length'])[_0x179b16('0x1630')](',');}break;case _0x179b16('0x2408'):{const _0x2e2768=_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1407')]['split'](',');_0x327ce4[_0x179b16('0x660')]['times']=isNaN(_0x2e2768[0x0])?_0x2e2768[0x0]:parseInt(_0x2e2768[0x0],0xa),_0x327ce4['queue']['text']=_0x2e2768[_0x179b16('0x12c8')](0x1,_0x2e2768[_0x179b16('0x1564')])[_0x179b16('0x1630')](',');}break;case _0x179b16('0x8c2'):_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1bcd')]=_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1407')];break;case _0x179b16('0x877'):_0x327ce4[_0x179b16('0x660')][_0x179b16('0x60a')]=_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1407')][_0x179b16('0x1fc5')]('=')[0x0],_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1c6b')]=_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1407')][_0x179b16('0x1fc5')]('=')[0x1];break;case _0x179b16('0x19ae'):_0x327ce4['queue'][_0x179b16('0x273a')]=_0x327ce4['queue'][_0x179b16('0x1407')];break;default:{const _0x14b79d=_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1407')][_0x179b16('0x1fc5')](',');_0x327ce4['queue'][_0x179b16('0x660')]=_0x2e3ca0()[_0x179b16('0x173f')](_0x14b79d[0x0])?_0x14b79d[0x0]:isNaN(_0x14b79d[0x0])?_0x14b79d[0x0]:parseInt(_0x14b79d[0x0],0xa),_0x327ce4['queue'][_0x179b16('0x1668')]=_0x2e3ca0()[_0x179b16('0x173f')](_0x14b79d[0x1])?_0x14b79d[0x1]:isNaN(_0x14b79d[0x1])?_0x14b79d[0x1]:parseInt(_0x14b79d[0x1],0xa);}break;}else _0x327ce4[_0x179b16('0x660')][_0x179b16('0x660')]=0x12c,_0x327ce4[_0x179b16('0x660')][_0x179b16('0x1668')]=0x12c;_0x327ce4[_0x179b16('0x660')][_0x179b16('0xcf0')]&&_0x327ce4[_0x179b16('0x660')][_0x179b16('0xcf0')][_0x179b16('0x93a')]()===_0x179b16('0x17cd')&&_0x327ce4['queue'][_0x179b16('0x11f3')]['toLowerCase']()===_0x179b16('0x659')&&(_0x327ce4['queue'][_0x179b16('0x24fa')]=_0x327ce4['queue'][_0x179b16('0xd31')]?_0x327ce4[_0x179b16('0x660')][_0x179b16('0xd31')][_0x179b16('0x1fc5')]('$')[0x0]:undefined,_0x327ce4[_0x179b16('0x660')][_0x179b16('0xabd')]=_0x327ce4[_0x179b16('0x660')][_0x179b16('0x73c')]?_0x179b16('0xac1')+_0x327ce4[_0x179b16('0x660')][_0x179b16('0x73c')]:undefined);_0x327ce4[_0x179b16('0x10cb')]=_0x5670ba,_0x327ce4[_0x179b16('0xf82')]=_0x3b79f3,_0x632c87[_0x179b16('0xca1')](_0x179b16('0x20c2'))?_0x45d1d1[_0x179b16('0x193f')][_0x179b16('0x1e6e')]({'fields':_0x179b16('0x2035'),'sort':'name','nolimit':'true'})[_0x179b16('0xe53')][_0x179b16('0x683')](function(_0x1051e2){_0x327ce4['queues']=_0x1051e2['rows']||[];})['catch'](function(_0x5ce0bd){const _0x35c744=_0x179b16;_0x278412[_0x35c744('0x52a')]({'title':_0x5ce0bd[_0x35c744('0x13ee')]?_0x35c744('0x2168')+_0x5ce0bd[_0x35c744('0x13ee')]+_0x35c744('0xbf6')+_0x5ce0bd[_0x35c744('0x24a9')]:_0x35c744('0x22dc'),'msg':_0x5ce0bd['data']?JSON[_0x35c744('0x258a')](_0x5ce0bd['data']):_0x5ce0bd['toString']()});}):_0x45d1d1[_0x179b16('0x193f')]['get']({'fields':'id,name,type','sort':'name','nolimit':_0x179b16('0x26ac')})['$promise']['then'](function(_0x392674){const _0x2def32=_0x179b16;_0x327ce4['queues']=_0x392674[_0x2def32('0xf5d')]||[];})[_0x179b16('0x683')](function(){const _0x15f8ab=_0x179b16;return _0x45d1d1[_0x15f8ab('0x22df')]['get']({'userProfileId':_0x327ce4[_0x15f8ab('0x11ed')][_0x15f8ab('0x2f')],'sectionId':0x2bd})['$promise'];})[_0x179b16('0x683')](function(_0x41d90d){const _0x21b65b=_0x179b16,_0x547531=_0x41d90d&&_0x41d90d[_0x21b65b('0xf5d')]?_0x41d90d['rows'][0x0]:null;if(!_0x547531){const _0xa29a2a=[];let _0x35c3e5=null;_0x327ce4['queue']&&(_0x35c3e5=_0x2e3ca0()['find'](_0x327ce4[_0x21b65b('0x2da')],{'name':_0x327ce4[_0x21b65b('0x660')][_0x21b65b('0x660')]}));for(let _0x22c4d3=0x0;_0x22c4d3<_0x327ce4[_0x21b65b('0x2da')][_0x21b65b('0x1564')];_0x22c4d3++){_0x35c3e5&&_0x327ce4[_0x21b65b('0x2da')][_0x22c4d3]['id']===_0x35c3e5['id']&&(_0x327ce4[_0x21b65b('0x2da')][_0x22c4d3][_0x21b65b('0x319')]=![],_0xa29a2a['push'](_0x327ce4[_0x21b65b('0x2da')][_0x22c4d3]));}_0x327ce4['queues']=_0xa29a2a;}else{if(!_0x547531[_0x21b65b('0x170')])return _0x45d1d1['userProfileResource'][_0x21b65b('0x1e6e')]({'sectionId':_0x547531['id']})['$promise'][_0x21b65b('0x683')](function(_0x38976b){const _0x3c7b4f=_0x21b65b,_0x950f4d=_0x2e3ca0()[_0x3c7b4f('0x386')](_0x38976b[_0x3c7b4f('0xf5d')],function(_0x1ba493){const _0x2025c8=_0x3c7b4f;return _0x2e3ca0()[_0x2025c8('0x1c07')](_0x327ce4[_0x2025c8('0x2da')],{'id':_0x1ba493[_0x2025c8('0x832')]});});let _0x5695da=null;_0x327ce4[_0x3c7b4f('0x660')]&&(_0x5695da=_0x2e3ca0()[_0x3c7b4f('0x1c07')](_0x327ce4['queues'],{'name':_0x327ce4['queue'][_0x3c7b4f('0x660')]}));if(_0x5695da&&!_0x2e3ca0()['some'](_0x950f4d,['id',_0x5695da['id']])){const _0x37483a=_0x2e3ca0()['find'](_0x327ce4[_0x3c7b4f('0x2da')],{'id':_0x5695da['id']});_0x37483a['canSelect']=![],_0x950f4d[_0x3c7b4f('0x1fd0')](_0x37483a);}_0x327ce4['queues']=_0x950f4d;});}})[_0x179b16('0x130a')](function(_0x46eeae){const _0x17bbff=_0x179b16;_0x278412[_0x17bbff('0x52a')]({'title':_0x46eeae[_0x17bbff('0x13ee')]?'API:'+_0x46eeae[_0x17bbff('0x13ee')]+_0x17bbff('0xbf6')+_0x46eeae[_0x17bbff('0x24a9')]:_0x17bbff('0x934'),'msg':_0x46eeae[_0x17bbff('0x5a5')]?JSON[_0x17bbff('0x258a')](_0x46eeae[_0x17bbff('0x5a5')]):_0x46eeae[_0x17bbff('0x1ff0')]()});});function _0x5670ba(){const _0x1c801a=_0x179b16;_0x327ce4[_0x1c801a('0x17f')]=[];const _0x52e382=[];_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0xcf0')]&&_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0xcf0')][_0x1c801a('0x93a')]()===_0x1c801a('0x17cd')&&_0x327ce4[_0x1c801a('0x660')]['appType']===_0x1c801a('0x4d2')&&(_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0xd31')]=_0x4a5ce4[_0x1c801a('0x145a')]?(_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x24fa')]||'')+_0x1c801a('0x249e')+_0x4a5ce4[_0x1c801a('0x145a')]+'}':(_0x327ce4['queue'][_0x1c801a('0x24fa')]||'')+_0x1c801a('0x20cb'),_0x4a5ce4[_0x1c801a('0x75b')]!==_0x1c801a('0x925')?_0x327ce4[_0x1c801a('0x660')]['options']['indexOf'](_0x1c801a('0x1b1'))<0x0&&(_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x158e')]+='U(xcally-mixmonitor-context)'):_0x327ce4['queue'][_0x1c801a('0x158e')]=_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x158e')][_0x1c801a('0x1725')](_0x1c801a('0x1b1'),''));const _0x2b3e96=_0x2e3ca0()[_0x1c801a('0x1c07')](_0x327ce4[_0x1c801a('0x2da')],{'name':_0x327ce4[_0x1c801a('0x660')]['queue']});_0x2b3e96&&(_0x327ce4[_0x1c801a('0x660')][_0x2e3ca0()[_0x1c801a('0x21ab')](_0x1c801a('0x1285'))+_0x1c801a('0xd4')]=_0x2b3e96['id']);if(_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x11f3')]&&_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x11f3')]===_0x1c801a('0xbf0')){}else switch((_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x1d75')]||_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x11f3')])[_0x1c801a('0x93a')]()){case _0x1c801a('0x877'):_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x1407')]=_0x327ce4['queue'][_0x1c801a('0x60a')]+'='+_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x1c6b')];break;case'custom':break;default:_0x52e382[0x0]=_0x327ce4['queue'][_0x1c801a('0x660')],_0x52e382[0x1]=_0x327ce4[_0x1c801a('0x660')][_0x1c801a('0x1668')],_0x327ce4['queue'][_0x1c801a('0x1407')]=_0x52e382[_0x1c801a('0x1630')](',');}_0x3b79f3(_0x327ce4[_0x1c801a('0x660')]);}function _0x3b79f3(_0x18d03e){const _0x4fbb3f=_0x179b16;_0x5b8e3b[_0x4fbb3f('0x1715')](_0x18d03e);}}const _0xd5c4b4=_0x1ee3fa;_0x4b126b[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'smsAccountApp','smsAccount','api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x4b126b(_0x40f70e,_0x298804,_0x482435,_0x123198,_0x1073f0,_0x2158e1,_0x5007fc,_0x22dfc6){const _0x283069=_0x189033,_0x5ece2a=this;_0x5ece2a[_0x283069('0x11ed')]=_0x5007fc[_0x283069('0x20b2')](),_0x5ece2a[_0x283069('0x17f')]=[],_0x5ece2a['title']=_0x283069('0x793')+(_0x123198['appType']||_0x123198['app'])[_0x283069('0x80')](),_0x5ece2a[_0x283069('0x24f2')]=angular[_0x283069('0x1a86')](_0x123198),_0x5ece2a[_0x283069('0x1134')]=_0x22dfc6,_0x5ece2a[_0x283069('0x258d')]={};if(_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x1407')])switch(_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x11f3')]?_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x11f3')][_0x283069('0x93a')]():_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x1d75')][_0x283069('0x93a')]()){case _0x283069('0xbf0'):break;case'dialogflow':{const _0x181873=_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x1407')][_0x283069('0x1fc5')](',');_0x5ece2a['system'][_0x283069('0x1d46')]=_0x181873[0x0],_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x1a1c')]=_0x181873[0x1],_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x6d9')]=_0x181873[_0x283069('0x12c8')](0x2,_0x181873[_0x283069('0x1564')])[_0x283069('0x1630')](',');}break;case _0x283069('0xd24'):{const _0x8bce09=_0x5ece2a['system']['appdata'][_0x283069('0x1fc5')](',');_0x5ece2a['system'][_0x283069('0x2119')]=_0x8bce09[0x0],_0x5ece2a[_0x283069('0x24f2')]['clientEmail']=_0x8bce09[0x1],_0x5ece2a['system'][_0x283069('0x406')]=_0x8bce09[0x2],_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x1a1c')]=_0x8bce09[0x3],_0x5ece2a['system'][_0x283069('0x6d9')]=_0x8bce09[_0x283069('0x12c8')](0x4,_0x8bce09[_0x283069('0x1564')])['join'](',');}break;case _0x283069('0x1db1'):{const _0x417879=_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x1407')][_0x283069('0x1fc5')](',');_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x7ae')]=_0x417879[0x0],_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x204a')]=_0x417879[0x1],_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x5ba')]=_0x417879[0x2],_0x5ece2a['system'][_0x283069('0x11a9')]=_0x417879[0x3],_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x6d9')]=_0x417879[_0x283069('0x12c8')](0x4,_0x417879[_0x283069('0x1564')])[_0x283069('0x1630')](',');}break;case _0x283069('0x2408'):{const _0x4ea388=_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x1407')]['split'](',');_0x5ece2a[_0x283069('0x24f2')]['times']=isNaN(_0x4ea388[0x0])?_0x4ea388[0x0]:parseInt(_0x4ea388[0x0],0xa),_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x1bcd')]=_0x4ea388[_0x283069('0x12c8')](0x1,_0x4ea388[_0x283069('0x1564')])['join'](',');}break;case'message':_0x5ece2a['system'][_0x283069('0x1bcd')]=_0x5ece2a['system'][_0x283069('0x1407')];break;case _0x283069('0x877'):_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x60a')]=_0x5ece2a[_0x283069('0x24f2')]['appdata'][_0x283069('0x1fc5')]('=')[0x0],_0x5ece2a[_0x283069('0x24f2')]['value']=_0x5ece2a[_0x283069('0x24f2')]['appdata'][_0x283069('0x1fc5')]('=')[0x1];break;case'agi':_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x273a')]=_0x5ece2a['system'][_0x283069('0x1407')];break;default:{const _0x48d937=_0x5ece2a['system']['appdata']['split'](',');_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x6db')]=_0x2e3ca0()[_0x283069('0x173f')](_0x48d937[0x0])?_0x48d937[0x0]:isNaN(_0x48d937[0x0])?_0x48d937[0x0]:parseInt(_0x48d937[0x0],0xa),_0x5ece2a[_0x283069('0x24f2')][_0x283069('0x26e0')]=_0x2e3ca0()['isEmpty'](_0x48d937[0x1])?_0x48d937[0x1]:isNaN(_0x48d937[0x1])?_0x48d937[0x1]:parseInt(_0x48d937[0x1],0xa);}break;}else _0x5ece2a[_0x283069('0x24f2')][_0x283069('0x26e0')]='';_0x5ece2a[_0x283069('0x24f2')][_0x283069('0xcf0')]&&_0x5ece2a['system'][_0x283069('0xcf0')][_0x283069('0x93a')]()==='outbound'&&_0x5ece2a['system'][_0x283069('0x11f3')][_0x283069('0x93a')]()==='outbounddial'&&(_0x5ece2a['system'][_0x283069('0x24fa')]=_0x5ece2a['system']['phone']?_0x5ece2a[_0x283069('0x24f2')][_0x283069('0xd31')][_0x283069('0x1fc5')]('$')[0x0]:undefined,_0x5ece2a[_0x283069('0x24f2')]['callerId']=_0x5ece2a['system'][_0x283069('0x73c')]?_0x283069('0xac1')+_0x5ece2a['system'][_0x283069('0x73c')]:undefined);_0x5ece2a['saveSmsAccountApp']=_0x4d9399,_0x5ece2a[_0x283069('0xf82')]=_0x2b204b,_0x5007fc['hasRole'](_0x283069('0x20c2'))?_0x2158e1[_0x283069('0x26e0')][_0x283069('0x1e6e')]({'fields':_0x283069('0xa10'),'sort':_0x283069('0x60a'),'nolimit':_0x283069('0x26ac')})[_0x283069('0xe53')][_0x283069('0x683')](function(_0x2ec92e){const _0x121579=_0x283069;_0x5ece2a[_0x121579('0x220b')]=_0x2ec92e[_0x121579('0xf5d')]||[];})['catch'](function(_0x4d4895){const _0xa85208=_0x283069;_0x482435[_0xa85208('0x52a')]({'title':_0x4d4895[_0xa85208('0x13ee')]?_0xa85208('0x2168')+_0x4d4895[_0xa85208('0x13ee')]+'\x20-\x20'+_0x4d4895[_0xa85208('0x24a9')]:_0xa85208('0x9a9'),'msg':_0x4d4895['data']?JSON[_0xa85208('0x258a')](_0x4d4895[_0xa85208('0x5a5')]):_0x4d4895['toString']()});}):_0x2158e1['variable'][_0x283069('0x1e6e')]({'fields':_0x283069('0xa10'),'sort':_0x283069('0x60a'),'nolimit':_0x283069('0x26ac')})['$promise'][_0x283069('0x683')](function(_0x29de9a){const _0x394c39=_0x283069;_0x5ece2a[_0x394c39('0x220b')]=_0x29de9a[_0x394c39('0xf5d')]||[];})[_0x283069('0x683')](function(){const _0x56c673=_0x283069;return _0x2158e1[_0x56c673('0x22df')][_0x56c673('0x1e6e')]({'userProfileId':_0x5ece2a[_0x56c673('0x11ed')]['userProfileId'],'sectionId':0x3f4})[_0x56c673('0xe53')];})['then'](function(_0x402935){const _0x199217=_0x283069,_0x37273b=_0x402935&&_0x402935[_0x199217('0xf5d')]?_0x402935[_0x199217('0xf5d')][0x0]:null;if(!_0x37273b){const _0x573c77=[];let _0x3dfbf8=null;_0x5ece2a['system']&&(_0x3dfbf8=_0x2e3ca0()[_0x199217('0x1c07')](_0x5ece2a[_0x199217('0x220b')],{'name':_0x5ece2a[_0x199217('0x24f2')]['variable']}));for(let _0xe5bff=0x0;_0xe5bff<_0x5ece2a[_0x199217('0x220b')]['length'];_0xe5bff++){_0x3dfbf8&&_0x5ece2a['variables'][_0xe5bff]['id']===_0x3dfbf8['id']&&(_0x5ece2a[_0x199217('0x220b')][_0xe5bff]['canSelect']=![],_0x573c77[_0x199217('0x1fd0')](_0x5ece2a[_0x199217('0x220b')][_0xe5bff]));}_0x5ece2a['variables']=_0x573c77;}else{if(!_0x37273b[_0x199217('0x170')])return _0x2158e1[_0x199217('0xcf7')][_0x199217('0x1e6e')]({'sectionId':_0x37273b['id']})[_0x199217('0xe53')][_0x199217('0x683')](function(_0x5d281b){const _0x220840=_0x199217,_0x79c786=_0x2e3ca0()[_0x220840('0x386')](_0x5d281b[_0x220840('0xf5d')],function(_0x4c8645){const _0x22e8d3=_0x220840;return _0x2e3ca0()[_0x22e8d3('0x1c07')](_0x5ece2a[_0x22e8d3('0x220b')],{'id':_0x4c8645['resourceId']});});let _0x2499ae=null;_0x5ece2a[_0x220840('0x24f2')]&&(_0x2499ae=_0x2e3ca0()[_0x220840('0x1c07')](_0x5ece2a[_0x220840('0x220b')],{'name':_0x5ece2a[_0x220840('0x24f2')][_0x220840('0x26e0')]}));if(_0x2499ae&&!_0x2e3ca0()[_0x220840('0x7a2')](_0x79c786,['id',_0x2499ae['id']])){const _0x49c01d=_0x2e3ca0()['find'](_0x5ece2a[_0x220840('0x220b')],{'id':_0x2499ae['id']});_0x49c01d['canSelect']=![],_0x79c786[_0x220840('0x1fd0')](_0x49c01d);}_0x5ece2a[_0x220840('0x220b')]=_0x79c786;});}})[_0x283069('0x130a')](function(_0x191c03){const _0x4e512a=_0x283069;_0x482435[_0x4e512a('0x52a')]({'title':_0x191c03['status']?_0x4e512a('0x2168')+_0x191c03['status']+_0x4e512a('0xbf6')+_0x191c03['statusText']:_0x4e512a('0x392'),'msg':_0x191c03[_0x4e512a('0x5a5')]?JSON['stringify'](_0x191c03[_0x4e512a('0x5a5')]):_0x191c03[_0x4e512a('0x1ff0')]()});});function _0x4d9399(){const _0x4f33e6=_0x283069;_0x5ece2a[_0x4f33e6('0x17f')]=[];const _0x45b564=[];_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0xcf0')]&&_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0xcf0')][_0x4f33e6('0x93a')]()===_0x4f33e6('0x17cd')&&_0x5ece2a[_0x4f33e6('0x24f2')]['appType']===_0x4f33e6('0x4d2')&&(_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0xd31')]=_0x1073f0[_0x4f33e6('0x145a')]?(_0x5ece2a[_0x4f33e6('0x24f2')]['prefix']||'')+_0x4f33e6('0x249e')+_0x1073f0[_0x4f33e6('0x145a')]+'}':(_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x24fa')]||'')+'${EXTEN}',_0x1073f0['recordingFormat']!==_0x4f33e6('0x925')?_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x158e')][_0x4f33e6('0x824')](_0x4f33e6('0x1b1'))<0x0&&(_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x158e')]+=_0x4f33e6('0x1b1')):_0x5ece2a['system']['options']=_0x5ece2a['system'][_0x4f33e6('0x158e')][_0x4f33e6('0x1725')](_0x4f33e6('0x1b1'),''));if(_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x11f3')]&&_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x11f3')]===_0x4f33e6('0xbf0')){}else switch((_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x1d75')]||_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x11f3')])['toLowerCase']()){case'set':_0x5ece2a[_0x4f33e6('0x24f2')]['appdata']=_0x5ece2a[_0x4f33e6('0x24f2')]['name']+'='+_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x1c6b')];break;case _0x4f33e6('0xbf0'):break;default:_0x45b564[0x0]=_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x6db')],_0x45b564[0x1]=_0x5ece2a[_0x4f33e6('0x24f2')][_0x4f33e6('0x26e0')],_0x5ece2a[_0x4f33e6('0x24f2')]['appdata']=_0x45b564['join'](',');}_0x2b204b(_0x5ece2a[_0x4f33e6('0x24f2')]);}function _0x2b204b(_0x3da917){const _0x58a69b=_0x283069;_0x40f70e[_0x58a69b('0x1715')](_0x3da917);}}const _0x9b51b5=_0x4b126b;_0x1b412d['$inject']=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x12dc'),_0x189033('0xa0e'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x1b412d(_0x4f286d,_0x1d41fa,_0x259d00,_0x4f5426,_0x4bbab6,_0x472aab,_0x229b6a,_0x17be21){const _0x56f8f6=_0x189033,_0x5153d6=this;_0x5153d6[_0x56f8f6('0x11ed')]=_0x229b6a[_0x56f8f6('0x20b2')](),_0x5153d6[_0x56f8f6('0x17f')]=[],_0x5153d6[_0x56f8f6('0xf28')]='SMS.EDIT_'+(_0x4f5426['appType']||_0x4f5426['app'])[_0x56f8f6('0x80')](),_0x5153d6[_0x56f8f6('0x270')]=angular[_0x56f8f6('0x1a86')](_0x4f5426),_0x5153d6[_0x56f8f6('0x1134')]=_0x17be21,_0x5153d6[_0x56f8f6('0x258d')]={};if(_0x5153d6[_0x56f8f6('0x270')]['appdata'])switch(_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x11f3')]?_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x11f3')][_0x56f8f6('0x93a')]():_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x1d75')][_0x56f8f6('0x93a')]()){case _0x56f8f6('0xbf0'):break;case _0x56f8f6('0x205c'):{const _0x524135=_0x5153d6[_0x56f8f6('0x270')]['appdata'][_0x56f8f6('0x1fc5')](',');_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x1d46')]=_0x524135[0x0],_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x1a1c')]=_0x524135[0x1],_0x5153d6[_0x56f8f6('0x270')]['welcomemessage']=_0x524135['slice'](0x2,_0x524135[_0x56f8f6('0x1564')])['join'](',');}break;case'dialogflowv2':{const _0x3d0627=_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x1407')]['split'](',');_0x5153d6['tag']['projectId']=_0x3d0627[0x0],_0x5153d6['tag'][_0x56f8f6('0x38')]=_0x3d0627[0x1],_0x5153d6['tag']['privateKey']=_0x3d0627[0x2],_0x5153d6['tag']['language']=_0x3d0627[0x3],_0x5153d6['tag'][_0x56f8f6('0x6d9')]=_0x3d0627[_0x56f8f6('0x12c8')](0x4,_0x3d0627[_0x56f8f6('0x1564')])[_0x56f8f6('0x1630')](',');}break;case _0x56f8f6('0x1db1'):{const _0x1224d4=_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x1407')][_0x56f8f6('0x1fc5')](',');_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x7ae')]=_0x1224d4[0x0],_0x5153d6['tag'][_0x56f8f6('0x204a')]=_0x1224d4[0x1],_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x5ba')]=_0x1224d4[0x2],_0x5153d6['tag'][_0x56f8f6('0x11a9')]=_0x1224d4[0x3],_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x6d9')]=_0x1224d4[_0x56f8f6('0x12c8')](0x4,_0x1224d4[_0x56f8f6('0x1564')])[_0x56f8f6('0x1630')](',');}break;case _0x56f8f6('0x2408'):{const _0x555428=_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x1407')][_0x56f8f6('0x1fc5')](',');_0x5153d6['tag'][_0x56f8f6('0x35')]=isNaN(_0x555428[0x0])?_0x555428[0x0]:parseInt(_0x555428[0x0],0xa),_0x5153d6['tag']['text']=_0x555428[_0x56f8f6('0x12c8')](0x1,_0x555428['length'])[_0x56f8f6('0x1630')](',');}break;case _0x56f8f6('0x8c2'):_0x5153d6[_0x56f8f6('0x270')]['text']=_0x5153d6[_0x56f8f6('0x270')]['appdata'];break;case'set':_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x60a')]=_0x5153d6[_0x56f8f6('0x270')]['appdata'][_0x56f8f6('0x1fc5')]('=')[0x0],_0x5153d6[_0x56f8f6('0x270')]['value']=_0x5153d6['tag'][_0x56f8f6('0x1407')][_0x56f8f6('0x1fc5')]('=')[0x1];break;case'agi':_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x273a')]=_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x1407')];break;default:{const _0x3d3829=_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x1407')][_0x56f8f6('0x1fc5')](',');_0x5153d6['tag']['tag']=_0x2e3ca0()[_0x56f8f6('0x173f')](_0x3d3829[0x0])?_0x3d3829[0x0]:isNaN(_0x3d3829[0x0])?_0x3d3829[0x0]:parseInt(_0x3d3829[0x0],0xa);}break;}else{}_0x5153d6['tag'][_0x56f8f6('0xcf0')]&&_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0xcf0')][_0x56f8f6('0x93a')]()===_0x56f8f6('0x17cd')&&_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x11f3')][_0x56f8f6('0x93a')]()===_0x56f8f6('0x659')&&(_0x5153d6[_0x56f8f6('0x270')]['prefix']=_0x5153d6['tag']['phone']?_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0xd31')][_0x56f8f6('0x1fc5')]('$')[0x0]:undefined,_0x5153d6['tag'][_0x56f8f6('0xabd')]=_0x5153d6[_0x56f8f6('0x270')][_0x56f8f6('0x73c')]?_0x56f8f6('0xac1')+_0x5153d6['tag']['callerID']:undefined);_0x5153d6['saveSmsAccountApp']=_0x4df3dd,_0x5153d6[_0x56f8f6('0xf82')]=_0x4dd61a,_0x229b6a[_0x56f8f6('0xca1')](_0x56f8f6('0x20c2'))?_0x472aab[_0x56f8f6('0x270')][_0x56f8f6('0x1e6e')]({'fields':'id,name','sort':_0x56f8f6('0x60a'),'nolimit':'true'})['$promise'][_0x56f8f6('0x683')](function(_0x2a83f2){const _0x3b52e5=_0x56f8f6;_0x5153d6[_0x3b52e5('0x1ce6')]=_0x2a83f2['rows']||[];})['catch'](function(_0x474975){const _0xa1649d=_0x56f8f6;_0x259d00[_0xa1649d('0x52a')]({'title':_0x474975[_0xa1649d('0x13ee')]?_0xa1649d('0x2168')+_0x474975[_0xa1649d('0x13ee')]+_0xa1649d('0xbf6')+_0x474975[_0xa1649d('0x24a9')]:_0xa1649d('0x14ef'),'msg':_0x474975[_0xa1649d('0x5a5')]?JSON['stringify'](_0x474975[_0xa1649d('0x5a5')]):_0x474975[_0xa1649d('0x1ff0')]()});}):_0x472aab[_0x56f8f6('0x270')][_0x56f8f6('0x1e6e')]({'fields':_0x56f8f6('0xa10'),'sort':'name','nolimit':'true'})[_0x56f8f6('0xe53')][_0x56f8f6('0x683')](function(_0x111d83){_0x5153d6['tags']=_0x111d83['rows']||[];})[_0x56f8f6('0x683')](function(){const _0x34690f=_0x56f8f6;return _0x472aab[_0x34690f('0x22df')]['get']({'userProfileId':_0x5153d6[_0x34690f('0x11ed')]['userProfileId'],'sectionId':0x3f0})['$promise'];})['then'](function(_0x7a3ae7){const _0x2afbab=_0x56f8f6,_0x1dd815=_0x7a3ae7&&_0x7a3ae7[_0x2afbab('0xf5d')]?_0x7a3ae7[_0x2afbab('0xf5d')][0x0]:null;if(!_0x1dd815){const _0x413a22=[];let _0x5c9ce3=null;_0x5153d6[_0x2afbab('0x270')]&&(_0x5c9ce3=_0x2e3ca0()[_0x2afbab('0x1c07')](_0x5153d6[_0x2afbab('0x1ce6')],{'name':_0x5153d6[_0x2afbab('0x270')][_0x2afbab('0x270')]}));for(let _0x308938=0x0;_0x308938<_0x5153d6[_0x2afbab('0x1ce6')][_0x2afbab('0x1564')];_0x308938++){_0x5c9ce3&&_0x5153d6[_0x2afbab('0x1ce6')][_0x308938]['id']===_0x5c9ce3['id']&&(_0x5153d6[_0x2afbab('0x1ce6')][_0x308938][_0x2afbab('0x319')]=![],_0x413a22[_0x2afbab('0x1fd0')](_0x5153d6['tags'][_0x308938]));}_0x5153d6[_0x2afbab('0x1ce6')]=_0x413a22;}else{if(!_0x1dd815[_0x2afbab('0x170')])return _0x472aab['userProfileResource'][_0x2afbab('0x1e6e')]({'sectionId':_0x1dd815['id']})[_0x2afbab('0xe53')]['then'](function(_0xf3b871){const _0xd50743=_0x2afbab,_0x1b7564=_0x2e3ca0()[_0xd50743('0x386')](_0xf3b871[_0xd50743('0xf5d')],function(_0x51dbbb){const _0x1dc92a=_0xd50743;return _0x2e3ca0()[_0x1dc92a('0x1c07')](_0x5153d6[_0x1dc92a('0x1ce6')],{'id':_0x51dbbb[_0x1dc92a('0x832')]});});let _0x4fc121=null;_0x5153d6[_0xd50743('0x270')]&&(_0x4fc121=_0x2e3ca0()[_0xd50743('0x1c07')](_0x5153d6[_0xd50743('0x1ce6')],{'name':_0x5153d6[_0xd50743('0x270')][_0xd50743('0x270')]}));if(_0x4fc121&&!_0x2e3ca0()[_0xd50743('0x7a2')](_0x1b7564,['id',_0x4fc121['id']])){const _0x43b6a2=_0x2e3ca0()[_0xd50743('0x1c07')](_0x5153d6[_0xd50743('0x1ce6')],{'id':_0x4fc121['id']});_0x43b6a2[_0xd50743('0x319')]=![],_0x1b7564[_0xd50743('0x1fd0')](_0x43b6a2);}_0x5153d6[_0xd50743('0x1ce6')]=_0x1b7564;});}})[_0x56f8f6('0x130a')](function(_0x4bee61){const _0x76af66=_0x56f8f6;_0x259d00[_0x76af66('0x52a')]({'title':_0x4bee61[_0x76af66('0x13ee')]?_0x76af66('0x2168')+_0x4bee61[_0x76af66('0x13ee')]+'\x20-\x20'+_0x4bee61[_0x76af66('0x24a9')]:'SYSTEM:GETtags','msg':_0x4bee61[_0x76af66('0x5a5')]?JSON[_0x76af66('0x258a')](_0x4bee61[_0x76af66('0x5a5')]):_0x4bee61[_0x76af66('0x1ff0')]()});});function _0x4df3dd(){const _0x372cb2=_0x56f8f6;_0x5153d6[_0x372cb2('0x17f')]=[];const _0x44b4b3=[];_0x5153d6[_0x372cb2('0x270')]['type']&&_0x5153d6[_0x372cb2('0x270')][_0x372cb2('0xcf0')][_0x372cb2('0x93a')]()===_0x372cb2('0x17cd')&&_0x5153d6['tag'][_0x372cb2('0x11f3')]==='outboundDial'&&(_0x5153d6[_0x372cb2('0x270')]['phone']=_0x4bbab6[_0x372cb2('0x145a')]?(_0x5153d6[_0x372cb2('0x270')][_0x372cb2('0x24fa')]||'')+_0x372cb2('0x249e')+_0x4bbab6['cutdigits']+'}':(_0x5153d6[_0x372cb2('0x270')][_0x372cb2('0x24fa')]||'')+_0x372cb2('0x20cb'),_0x4bbab6[_0x372cb2('0x75b')]!==_0x372cb2('0x925')?_0x5153d6['tag'][_0x372cb2('0x158e')][_0x372cb2('0x824')](_0x372cb2('0x1b1'))<0x0&&(_0x5153d6['tag'][_0x372cb2('0x158e')]+='U(xcally-mixmonitor-context)'):_0x5153d6[_0x372cb2('0x270')][_0x372cb2('0x158e')]=_0x5153d6[_0x372cb2('0x270')][_0x372cb2('0x158e')][_0x372cb2('0x1725')](_0x372cb2('0x1b1'),''));const _0x556332=_0x2e3ca0()[_0x372cb2('0x1c07')](_0x5153d6[_0x372cb2('0x1ce6')],{'name':_0x5153d6[_0x372cb2('0x270')][_0x372cb2('0x270')]});_0x556332&&(_0x5153d6[_0x372cb2('0x270')][_0x372cb2('0xb6d')]=_0x556332['id']);if(_0x5153d6[_0x372cb2('0x270')]['appType']&&_0x5153d6[_0x372cb2('0x270')][_0x372cb2('0x11f3')]===_0x372cb2('0xbf0')){}else switch((_0x5153d6[_0x372cb2('0x270')]['app']||_0x5153d6[_0x372cb2('0x270')]['appType'])[_0x372cb2('0x93a')]()){case _0x372cb2('0x877'):_0x5153d6[_0x372cb2('0x270')][_0x372cb2('0x1407')]=_0x5153d6['tag'][_0x372cb2('0x60a')]+'='+_0x5153d6[_0x372cb2('0x270')]['value'];break;case'custom':break;default:_0x44b4b3[0x0]=_0x5153d6['tag'][_0x372cb2('0x270')],_0x5153d6[_0x372cb2('0x270')]['appdata']=_0x44b4b3['join'](',');}_0x4dd61a(_0x5153d6[_0x372cb2('0x270')]);}function _0x4dd61a(_0x4d83e6){const _0x166e49=_0x56f8f6;_0x4f286d[_0x166e49('0x1715')](_0x4d83e6);}}const _0x3896db=_0x1b412d;_0x570fd6[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x570fd6(_0x2121e9,_0x2a0a04,_0x460887,_0x363136,_0x45a1ae,_0x44efef,_0x5c5041,_0x3fc66f,_0x50ca45,_0x5436b4,_0x4b1cdc){const _0x21b457=_0x189033,_0x293caa=this;_0x293caa['currentUser']=_0x4b1cdc[_0x21b457('0x20b2')](),_0x293caa['smsAccount']={},_0x293caa[_0x21b457('0x1b79')]={'count':0x0,'rows':[]},_0x293caa['selectedSmsAccountInteractions']=[],_0x293caa['crudPermissions'],_0x293caa[_0x21b457('0x23a2')]={'read':_0x21b457('0x13c'),'closed':_0x21b457('0x13c'),'sort':_0x21b457('0xddd'),'includeAll':_0x21b457('0x26ac'),'limit':0xa,'page':0x1},_0x293caa['init']=_0x24d49d,_0x293caa[_0x21b457('0x26eb')]=_0x6b86e7,_0x293caa[_0x21b457('0x98')]=_0xae96b7,_0x293caa[_0x21b457('0x53')]=_0x567b0c,_0x293caa['getSmsAccountInteractions']=_0x4dfb40,_0x293caa[_0x21b457('0x8a8')]=_0x4c45e1,_0x293caa['openAdvancedSearch']=_0x2b41ea,_0x293caa['exportSelectedSmsAccountInteractions']=_0x7c7996,_0x293caa[_0x21b457('0x278')]=_0x1ff463,_0x293caa[_0x21b457('0x1ee6')]=_0x16111c;function _0x24d49d(_0x40d1fa,_0x2e405a){const _0xbc253c=_0x21b457;_0x293caa[_0xbc253c('0xa0e')]=_0x40d1fa,_0x293caa[_0xbc253c('0x1134')]=typeof _0x2e405a!==_0xbc253c('0x1867')?_0x2e405a:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x293caa[_0xbc253c('0x23a2')][_0xbc253c('0x1f4f')]=_0x293caa['smsAccount']['id'],_0x293caa[_0xbc253c('0x19c9')]={'fields':_0x1ba1b4()},_0x836ea9();}function _0x836ea9(){const _0x10e181=_0x21b457;return _0x5436b4[_0x10e181('0x270')][_0x10e181('0x1e6e')]()['$promise']['then'](function(_0x2662c9){const _0x35da45=_0x10e181;_0x293caa[_0x35da45('0x1ce6')]=_0x2662c9||{'count':0x0,'rows':[]};})[_0x10e181('0x683')](function(){const _0x31f52e=_0x10e181;_0x293caa[_0x31f52e('0xc71')]=_0x4ec827();});}function _0x4ec827(){const _0xb0ac81=_0x21b457;return[{'name':'Start\x20Date','key':'createdAt','type':'date','label':_0xb0ac81('0x1006')},{'name':_0xb0ac81('0xc51'),'key':_0xb0ac81('0x20db'),'type':'select','label':_0xb0ac81('0x1866'),'customOptions':[{'value':0x0,'translate':_0xb0ac81('0x2226')},{'value':0x1,'translate':'DASHBOARDS.READ'},{'value':null,'translate':_0xb0ac81('0x475')}]},{'name':_0xb0ac81('0x1d9d'),'key':_0xb0ac81('0xd8a'),'type':_0xb0ac81('0xb31'),'label':_0xb0ac81('0x1b77'),'customOptions':[{'value':0x0,'translate':_0xb0ac81('0x10b1')},{'value':0x1,'translate':_0xb0ac81('0x270a')},{'value':null,'translate':_0xb0ac81('0x475')}]},{'name':_0xb0ac81('0x62c'),'key':'UserId','type':'select','label':_0xb0ac81('0x21fb'),'customOptions':[{'value':_0xb0ac81('0x13c'),'translate':_0xb0ac81('0x2608')},{'value':undefined,'translate':_0xb0ac81('0x475')}]},{'name':_0xb0ac81('0x1e'),'key':_0xb0ac81('0x270'),'type':'multiselect','label':_0xb0ac81('0x2264'),'options':_0x293caa[_0xb0ac81('0x1ce6')]['rows'],'placeholder':_0xb0ac81('0x7cb')}];}function _0x1ba1b4(){const _0x2514e5=_0x21b457;return[{'name':'Id','column':'id','type':_0x2514e5('0x121f')},{'name':_0x2514e5('0x1309'),'column':_0x2514e5('0x1309'),'type':_0x2514e5('0xeb'),'options':{'searchFields':[_0x2514e5('0xeef'),_0x2514e5('0x510'),'email'],'route':{'model':_0x2514e5('0x276e'),'action':_0x2514e5('0x1e6e'),'params':{'fields':'id,firstName,lastName,email','Contact':_0x2514e5('0xfd'),'nolimit':!![]}},'extraOperators':[_0x2514e5('0xe55')],'excludedOperators':[_0x2514e5('0x17ee')]}},{'name':'Subject','column':'subject','type':_0x2514e5('0x1bcd'),'options':{'excludedOperators':[_0x2514e5('0x393'),_0x2514e5('0x17ee')]}},{'name':'Body','column':_0x2514e5('0x183b'),'type':_0x2514e5('0x1bcd'),'options':{'excludedOperators':[_0x2514e5('0x393'),'$ne']}},{'name':_0x2514e5('0x1d9d'),'column':_0x2514e5('0xd8a'),'type':'select','values':[{'id':0x0,'translate':'DASHBOARDS.OPENED'},{'id':0x1,'translate':_0x2514e5('0x270a')}],'options':{'excludedOperators':[_0x2514e5('0x17ee')]}},{'name':'Agent','column':_0x2514e5('0x1dad'),'type':_0x2514e5('0xeb'),'options':{'table':'i','route':{'model':_0x2514e5('0xc96'),'action':'get','params':{'role':_0x2514e5('0x2327'),'fields':_0x2514e5('0x2686'),'nolimit':!![]}},'searchFields':[_0x2514e5('0x11bc'),_0x2514e5('0x60a')],'extraOperators':[_0x2514e5('0xe55')],'excludedOperators':[_0x2514e5('0x17ee')]}},{'name':'Tags','column':_0x2514e5('0x1e'),'type':_0x2514e5('0xf6c'),'options':{'route':{'model':'tag','action':_0x2514e5('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x2514e5('0x1479')]}},{'name':_0x2514e5('0x10c1'),'column':'createdAt','type':_0x2514e5('0x270e'),'options':{'excludedOperators':['$ne']}},{'name':_0x2514e5('0x1bb6'),'column':'unreadMessages','type':'select','values':[{'id':0x1,'translate':_0x2514e5('0x38f')},{'id':0x0,'translate':_0x2514e5('0x2226')}],'options':{'excludedOperators':[_0x2514e5('0x17ee')]}}];}function _0x2b41ea(){const _0x1ed77f=_0x21b457;_0x5c5041[_0x1ed77f('0x1d4')]({'controller':_0x1ed77f('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular['element'](_0x3fc66f[_0x1ed77f('0x18e5')]),'clickOutsideToClose':![],'locals':{'fields':_0x293caa[_0x1ed77f('0x19c9')]['fields'],'color':undefined,'storagePath':_0x1ed77f('0x1968')},'fullscreen':!![]})[_0x1ed77f('0x683')](function(_0x567599){const _0x4e1e8d=_0x1ed77f;_0x293caa[_0x4e1e8d('0x23a2')][_0x4e1e8d('0x19a4')]=_0x567599===![]?undefined:_0x567599;if(_0x293caa[_0x4e1e8d('0x23a2')][_0x4e1e8d('0x19a4')])_0x4dfb40();else _0x567599===![]&&_0x4dfb40();})['catch'](function(_0x4a84e1){const _0x4bb82e=_0x1ed77f;_0x50ca45['error']({'title':'ERROR','msg':_0x4a84e1[_0x4bb82e('0x5a5')]?JSON['stringify'](_0x4a84e1[_0x4bb82e('0x5a5')]['message']):_0x4a84e1[_0x4bb82e('0x1ff0')]()});});}function _0xae96b7(_0x49cba7,_0x1df10b,_0x3392b9){const _0x11e914=_0x21b457;return _0x5436b4[_0x11e914('0x22d8')][_0x11e914('0x18e8')]({'id':_0x49cba7['id'],'exists':!![],'attachments':_0x3392b9})[_0x11e914('0xe53')]['then'](function(_0x6cab08){const _0x26b80b=_0x11e914,_0x39031d=[_0x6cab08[_0x26b80b('0x1fb3')]];let _0x410b80=_0x26b80b('0xa98')+_0x49cba7['id'];const _0x273165=new Blob(_0x39031d,{'type':_0x6cab08[_0x26b80b('0xcf0')]});_0x410b80=_0x26b80b('0x13dc')+_0x49cba7['id']+_0x26b80b('0x18ff');const _0x19f9ac=window['document'][_0x26b80b('0x1ffa')]('a');_0x19f9ac[_0x26b80b('0x130f')](_0x26b80b('0x2767'),URL[_0x26b80b('0x2820')](_0x273165)),_0x19f9ac['setAttribute']('download',_0x410b80),document[_0x26b80b('0x18e5')][_0x26b80b('0x1e43')](_0x19f9ac),_0x19f9ac['click']();})[_0x11e914('0x130a')](function(_0x33ff11){const _0x5a8240=_0x11e914;if(_0x33ff11['data']&&_0x33ff11['data'][_0x5a8240('0x17f')]&&_0x33ff11[_0x5a8240('0x5a5')][_0x5a8240('0x17f')][_0x5a8240('0x1564')])for(let _0x390d80=0x0;_0x390d80<_0x33ff11[_0x5a8240('0x5a5')][_0x5a8240('0x17f')]['length'];_0x390d80+=0x1){_0x50ca45[_0x5a8240('0x52a')]({'title':_0x33ff11['data'][_0x5a8240('0x17f')][_0x390d80]['type'],'msg':_0x33ff11[_0x5a8240('0x5a5')][_0x5a8240('0x17f')][_0x390d80][_0x5a8240('0x8c2')]});}else _0x50ca45[_0x5a8240('0x52a')]({'title':_0x33ff11[_0x5a8240('0x13ee')]?_0x5a8240('0x2168')+_0x33ff11['status']+'\x20-\x20'+_0x33ff11[_0x5a8240('0x24a9')]:'api.smsAccount.save','msg':_0x33ff11['data']?JSON[_0x5a8240('0x258a')](_0x33ff11['data'][_0x5a8240('0x8c2')]):_0x33ff11['toString']()});});}function _0x6b86e7(_0x20f46e,_0x93b3f4){const _0x23ca88=_0x21b457,_0x21221e=_0x5c5041[_0x23ca88('0x1c6f')]()[_0x23ca88('0xf28')](_0x23ca88('0xb1f'))[_0x23ca88('0x26e3')](_0x23ca88('0xed5')+(_0x20f46e[_0x23ca88('0x60a')]||_0x20f46e['id']&&_0x2e3ca0()['upperFirst'](_0x23ca88('0x936'))+_0x20f46e['id']||_0x23ca88('0xa98'))+_0x23ca88('0x20f1')+_0x23ca88('0x1ee7'))[_0x23ca88('0x1040')](_0x23ca88('0x19a8'))['targetEvent'](_0x93b3f4)['ok']('OK')[_0x23ca88('0x19fb')](_0x23ca88('0x16b8'));_0x5c5041[_0x23ca88('0x1d4')](_0x21221e)[_0x23ca88('0x683')](function(){_0x1ff463(_0x20f46e);},function(){const _0x16e643=_0x23ca88;console[_0x16e643('0x1b2b')](_0x16e643('0x16b8'));});}function _0x567b0c(_0x50952a){const _0x198fe6=_0x21b457;_0x293caa[_0x198fe6('0x1b79')]=_0x50952a||{'count':0x0,'rows':[]};for(let _0x5bcc48=0x0;_0x5bcc48<_0x293caa[_0x198fe6('0x1b79')]['rows'][_0x198fe6('0x1564')];_0x5bcc48+=0x1){const _0x556728=_0x293caa[_0x198fe6('0x1b79')]['rows'][_0x5bcc48];_0x1d99f2(_0x556728),_0x556728[_0x198fe6('0x2464')][_0x198fe6('0x60a')]=_0x572f1c(_0x556728);}}function _0x4dfb40(){const _0x362d31=_0x21b457;_0x293caa[_0x362d31('0x23a2')]['offset']=(_0x293caa[_0x362d31('0x23a2')][_0x362d31('0xdf8')]-0x1)*_0x293caa[_0x362d31('0x23a2')]['limit'],_0x293caa[_0x362d31('0x1883')]=_0x5436b4[_0x362d31('0x22d8')][_0x362d31('0x1e6e')](_0x293caa[_0x362d31('0x23a2')],_0x567b0c)[_0x362d31('0xe53')];}function _0x4c45e1(_0x4c476c,_0x34a23d){const _0x2eeeee=_0x21b457;_0x5c5041['show']({'controller':_0x2eeeee('0x13ab'),'controllerAs':'vm','templateUrl':_0x37aa85,'parent':angular[_0x2eeeee('0x1fcc')](_0x3fc66f[_0x2eeeee('0x18e5')]),'targetEvent':_0x4c476c,'clickOutsideToClose':!![],'onShowing':function(_0x544acd){const _0x18f259=_0x2eeeee;_0x544acd['vm'][_0x18f259('0x12f3')]({'id':0x1,'channel':_0x18f259('0x1285'),'interaction':_0x34a23d,'spy':!![]},_0x2a0a04[_0x18f259('0x1cd5')]['vm']['setting']);}});}function _0x1ff463(_0xead900){const _0x3e823f=_0x21b457;_0x5436b4['smsInteraction'][_0x3e823f('0xd7e')]({'id':_0xead900['id']})['$promise'][_0x3e823f('0x683')](function(){const _0x2103f5=_0x3e823f;_0x2e3ca0()[_0x2103f5('0x3ec')](_0x293caa[_0x2103f5('0x1b79')][_0x2103f5('0xf5d')],{'id':_0xead900['id']}),_0x293caa['smsAccountInteractions']['count']-=0x1,!_0x293caa[_0x2103f5('0x1b79')][_0x2103f5('0xf5d')][_0x2103f5('0x1564')]&&_0x4dfb40(),_0x50ca45[_0x2103f5('0x53')]({'title':_0x2103f5('0x1c86'),'msg':_0xead900[_0x2103f5('0x60a')]?_0xead900[_0x2103f5('0x60a')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x14de24){const _0x47a7be=_0x3e823f;if(_0x14de24[_0x47a7be('0x5a5')]&&_0x14de24[_0x47a7be('0x5a5')]['errors']&&_0x14de24[_0x47a7be('0x5a5')]['errors']['length']){_0x293caa[_0x47a7be('0x17f')]=_0x14de24[_0x47a7be('0x5a5')]['errors']||[{'message':_0x14de24[_0x47a7be('0x1ff0')](),'type':_0x47a7be('0x1d89')}];for(let _0x424879=0x0;_0x424879<_0x14de24['data']['errors'][_0x47a7be('0x1564')];_0x424879++){_0x50ca45[_0x47a7be('0x52a')]({'title':_0x14de24[_0x47a7be('0x5a5')][_0x47a7be('0x17f')][_0x424879][_0x47a7be('0xcf0')],'msg':_0x14de24[_0x47a7be('0x5a5')]['errors'][_0x424879][_0x47a7be('0x8c2')]});}}else _0x50ca45['error']({'title':_0x14de24[_0x47a7be('0x13ee')]?'API:'+_0x14de24[_0x47a7be('0x13ee')]+'\x20-\x20'+_0x14de24[_0x47a7be('0x24a9')]:'SYSTEM:GETsmsAccount','msg':_0x14de24[_0x47a7be('0x5a5')]?JSON['stringify'](_0x14de24['data'][_0x47a7be('0x8c2')]):_0x14de24[_0x47a7be('0x8c2')]||_0x14de24['toString']()});});}function _0x7c7996(){const _0x5c22f6=_0x21b457,_0x4f5603=angular[_0x5c22f6('0x1a86')](_0x293caa[_0x5c22f6('0x2299')]);return _0x293caa[_0x5c22f6('0x2299')]=[],_0x4f5603;}function _0x16111c(_0x328b40){const _0x47364a=_0x21b457,_0x3eca24=_0x5c5041[_0x47364a('0x1c6f')]()[_0x47364a('0xf28')](_0x47364a('0x1cba'))[_0x47364a('0x26e3')](''+_0x293caa[_0x47364a('0x2299')][_0x47364a('0x1564')]+_0x47364a('0x93c')+'\x20will\x20be\x20deleted.')[_0x47364a('0x1040')]('delete\x20interactions')[_0x47364a('0xe42')](_0x328b40)['ok']('OK')[_0x47364a('0x19fb')](_0x47364a('0x16b8'));_0x5c5041[_0x47364a('0x1d4')](_0x3eca24)[_0x47364a('0x683')](function(){const _0x3bc4fc=_0x47364a;_0x293caa[_0x3bc4fc('0x2299')][_0x3bc4fc('0x1299')](function(_0x59be57){_0x1ff463(_0x59be57);}),_0x293caa[_0x3bc4fc('0x2299')]=[];});}function _0x1d99f2(_0x46a706){const _0x1a8ab8=_0x21b457;_0x46a706[_0x1a8ab8('0x1309')]?(_0x46a706['contactName']=(_0x46a706[_0x1a8ab8('0x1309')][_0x1a8ab8('0xeef')]||'')+'\x20'+(_0x46a706[_0x1a8ab8('0x1309')][_0x1a8ab8('0x510')]||''),_0x46a706[_0x1a8ab8('0x22f9')]=_0x46a706[_0x1a8ab8('0x1309')]['mobile']):_0x46a706[_0x1a8ab8('0x12b3')]=_0x45a1ae['instant'](_0x1a8ab8('0x215e'));}function _0x572f1c(_0x5b2ef7){const _0x33d5d4=_0x21b457;if(_0x5b2ef7['UserId'])return _0x5b2ef7['UserId']===_0x293caa[_0x33d5d4('0x11ed')]['id']?_0x45a1ae[_0x33d5d4('0x2728')](_0x33d5d4('0x96a')):_0x5b2ef7[_0x33d5d4('0x2464')][_0x33d5d4('0x11bc')]+'\x20<'+_0x5b2ef7[_0x33d5d4('0x2464')][_0x33d5d4('0x1d43')]+'>';return _0x45a1ae[_0x33d5d4('0x2728')](_0x33d5d4('0x2608'));}let _0x1f49e6=!![],_0x301a80=0x1;_0x2a0a04['$watch'](_0x21b457('0x229'),function(_0xe6c882,_0x3cf355){const _0x138d23=_0x21b457;_0x1f49e6?_0x44efef(function(){_0x1f49e6=![];}):(!_0x3cf355&&(_0x301a80=_0x293caa[_0x138d23('0x23a2')][_0x138d23('0xdf8')]),_0xe6c882!==_0x3cf355&&(_0x293caa[_0x138d23('0x23a2')]['page']=0x1),!_0xe6c882&&(_0x293caa[_0x138d23('0x23a2')][_0x138d23('0xdf8')]=_0x301a80),_0x4dfb40());});}const _0x88be68=_0x570fd6,_0x193d3f=_0x180212['p']+_0x189033('0x5a8');_0x45214d[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),'Auth'];function _0x45214d(_0x14312b,_0x2906c7,_0x35b3f1,_0x2d0dc6,_0x5099e4,_0x92a784,_0x20d56c,_0x4166e4,_0x10a047,_0x449b26,_0x970fd5){const _0x4b4084=_0x189033,_0x2337f2=this;_0x2337f2[_0x4b4084('0x11ed')]=_0x970fd5[_0x4b4084('0x20b2')](),_0x2337f2[_0x4b4084('0xa0e')]={},_0x2337f2[_0x4b4084('0x1d36')]={'count':0x0,'rows':[]},_0x2337f2[_0x4b4084('0x116b')]=[],_0x2337f2[_0x4b4084('0x1134')],_0x2337f2['query']={'fields':'createdAt,updatedAt,id,key,value,description','limit':0xa,'page':0x1},_0x2337f2[_0x4b4084('0x12f3')]=_0x2d55e2,_0x2337f2[_0x4b4084('0x26eb')]=_0x13e140,_0x2337f2[_0x4b4084('0x53')]=_0x463a7d,_0x2337f2[_0x4b4084('0x1967')]=_0x1f0841,_0x2337f2['createOrEditSmsAccountSmsCannedAnswer']=_0x44aaaa,_0x2337f2['exportSelectedSmsAccountSmsCannedAnswers']=_0x1bec4d,_0x2337f2[_0x4b4084('0xf0f')]=_0x3aabc5,_0x2337f2[_0x4b4084('0x1d7a')]=_0x2086af;function _0x2d55e2(_0x5490e8,_0x108094){const _0xb7586a=_0x4b4084;_0x2337f2[_0xb7586a('0xa0e')]=_0x5490e8,_0x2337f2[_0xb7586a('0x1134')]=typeof _0x108094!==_0xb7586a('0x1867')?_0x108094:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x2337f2[_0xb7586a('0x23a2')]['SmsAccountId']=_0x2337f2[_0xb7586a('0xa0e')]['id'],_0x2337f2['query']['id']=_0x2337f2['smsAccount']['id'],_0x1f0841();}function _0x13e140(_0x2793a8,_0x511228){const _0x5c538c=_0x4b4084,_0x2aeaac=_0x20d56c['confirm']()['title'](_0x5c538c('0x184c'))[_0x5c538c('0x26e3')](_0x5c538c('0xed5')+(_0x2793a8['name']||_0x2793a8['id']&&_0x2e3ca0()['upperFirst'](_0x5c538c('0x2360'))+_0x2793a8['id']||_0x5c538c('0x1a74'))+_0x5c538c('0x20f1')+'\x20will\x20be\x20deleted.')[_0x5c538c('0x1040')]('delete\x20smsCannedAnswer')[_0x5c538c('0xe42')](_0x511228)['ok']('OK')[_0x5c538c('0x19fb')]('CANCEL');_0x20d56c[_0x5c538c('0x1d4')](_0x2aeaac)[_0x5c538c('0x683')](function(){_0x3aabc5(_0x2793a8);},function(){const _0x546770=_0x5c538c;console[_0x546770('0x1b2b')]('CANCEL');});}function _0x463a7d(_0x35063a){const _0x37a9c8=_0x4b4084;_0x2337f2[_0x37a9c8('0x1d36')]=_0x35063a||{'count':0x0,'rows':[]};}function _0x1f0841(){const _0x5db3aa=_0x4b4084;_0x2337f2[_0x5db3aa('0x23a2')][_0x5db3aa('0x1cc8')]=(_0x2337f2['query'][_0x5db3aa('0xdf8')]-0x1)*_0x2337f2[_0x5db3aa('0x23a2')][_0x5db3aa('0x6f0')],_0x2337f2[_0x5db3aa('0x1883')]=_0x449b26[_0x5db3aa('0xa0e')][_0x5db3aa('0x87f')](_0x2337f2[_0x5db3aa('0x23a2')],_0x463a7d)[_0x5db3aa('0xe53')];}function _0x44aaaa(_0x4abfcb,_0x1650fc){const _0x10572b=_0x4b4084;_0x20d56c[_0x10572b('0x1d4')]({'controller':_0x10572b('0x2666'),'controllerAs':'vm','templateUrl':_0x193d3f,'parent':angular[_0x10572b('0x1fcc')](_0x4166e4['body']),'targetEvent':_0x4abfcb,'clickOutsideToClose':!![],'locals':{'smsAccount':_0x2337f2[_0x10572b('0xa0e')],'smsCannedAnswer':_0x1650fc,'smsCannedAnswers':_0x2337f2[_0x10572b('0x1d36')][_0x10572b('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x2337f2[_0x10572b('0x1134')]}});}function _0x3aabc5(_0x56474d){const _0x1cdd97=_0x4b4084;_0x449b26['cannedAnswer'][_0x1cdd97('0xd7e')]({'id':_0x56474d['id']})['$promise'][_0x1cdd97('0x683')](function(){const _0x70d34b=_0x1cdd97;_0x2e3ca0()[_0x70d34b('0x3ec')](_0x2337f2[_0x70d34b('0x1d36')]['rows'],{'id':_0x56474d['id']}),_0x2337f2[_0x70d34b('0x1d36')][_0x70d34b('0x50d')]-=0x1,!_0x2337f2[_0x70d34b('0x1d36')][_0x70d34b('0xf5d')][_0x70d34b('0x1564')]&&_0x1f0841(),_0x10a047[_0x70d34b('0x53')]({'title':_0x70d34b('0x2a0'),'msg':_0x56474d['name']?_0x56474d['name']+_0x70d34b('0x194d'):''});})['catch'](function(_0x2760b6){const _0x15053b=_0x1cdd97;if(_0x2760b6[_0x15053b('0x5a5')]&&_0x2760b6[_0x15053b('0x5a5')][_0x15053b('0x17f')]&&_0x2760b6['data'][_0x15053b('0x17f')][_0x15053b('0x1564')]){_0x2337f2[_0x15053b('0x17f')]=_0x2760b6[_0x15053b('0x5a5')][_0x15053b('0x17f')]||[{'message':_0x2760b6[_0x15053b('0x1ff0')](),'type':_0x15053b('0x1d89')}];for(let _0x5969d2=0x0;_0x5969d2<_0x2760b6['data'][_0x15053b('0x17f')][_0x15053b('0x1564')];_0x5969d2++){_0x10a047[_0x15053b('0x52a')]({'title':_0x2760b6[_0x15053b('0x5a5')][_0x15053b('0x17f')][_0x5969d2]['type'],'msg':_0x2760b6[_0x15053b('0x5a5')][_0x15053b('0x17f')][_0x5969d2]['message']});}}else _0x10a047['error']({'title':_0x2760b6[_0x15053b('0x13ee')]?'API:'+_0x2760b6[_0x15053b('0x13ee')]+'\x20-\x20'+_0x2760b6[_0x15053b('0x24a9')]:_0x15053b('0x1d89'),'msg':_0x2760b6[_0x15053b('0x5a5')]?JSON[_0x15053b('0x258a')](_0x2760b6[_0x15053b('0x5a5')][_0x15053b('0x8c2')]):_0x2760b6[_0x15053b('0x8c2')]||_0x2760b6['toString']()});});}function _0x1bec4d(){const _0x4c57ce=_0x4b4084,_0x316b10=angular[_0x4c57ce('0x1a86')](_0x2337f2[_0x4c57ce('0x116b')]);return _0x2337f2[_0x4c57ce('0x116b')]=[],_0x316b10;}function _0x2086af(_0x317e3f){const _0x52499f=_0x4b4084,_0x15f301=_0x20d56c[_0x52499f('0x1c6f')]()[_0x52499f('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20smsCannedAnswers?')['htmlContent'](_0x52499f('0xed5')+_0x2337f2[_0x52499f('0x116b')][_0x52499f('0x1564')]+_0x52499f('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x52499f('0xcfb'))['targetEvent'](_0x317e3f)['ok']('OK')[_0x52499f('0x19fb')](_0x52499f('0x16b8'));_0x20d56c[_0x52499f('0x1d4')](_0x15f301)['then'](function(){const _0x736894=_0x52499f;_0x2337f2[_0x736894('0x116b')][_0x736894('0x1299')](function(_0x4b9a10){_0x3aabc5(_0x4b9a10);}),_0x2337f2[_0x736894('0x116b')]=[];});}let _0x314d1c=!![],_0x20aa3e=0x1;_0x2906c7[_0x4b4084('0x186d')]('vm_dc.query.filter',function(_0x528a38,_0x480f92){const _0x41e88d=_0x4b4084;_0x314d1c?_0x92a784(function(){_0x314d1c=![];}):(!_0x480f92&&(_0x20aa3e=_0x2337f2['query'][_0x41e88d('0xdf8')]),_0x528a38!==_0x480f92&&(_0x2337f2[_0x41e88d('0x23a2')][_0x41e88d('0xdf8')]=0x1),!_0x528a38&&(_0x2337f2[_0x41e88d('0x23a2')][_0x41e88d('0xdf8')]=_0x20aa3e),_0x1f0841());});}const _0x1651d9=_0x45214d;_0x170421['$inject']=[_0x189033('0x7a5'),'$state','$location',_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x22e5'),_0x189033('0x1a74'),_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x170421(_0x590245,_0x421e53,_0x162199,_0x3d988c,_0x5c96d0,_0x307b5d,_0x2ac941,_0x5ea91c,_0x2bc515,_0x327c05,_0x3e4f50,_0x43ae9e,_0x2d2c30,_0x5c5a0e){const _0x58e669=_0x189033,_0x1b1c89=this;_0x1b1c89[_0x58e669('0x11ed')]=_0x3e4f50[_0x58e669('0x20b2')](),_0x1b1c89[_0x58e669('0x17f')]=[],_0x1b1c89['setting']=_0x2d2c30,_0x1b1c89[_0x58e669('0xace')]=_0x43ae9e,_0x1b1c89[_0x58e669('0x1134')]=_0x5c5a0e,_0x1b1c89[_0x58e669('0x258d')]={},_0x1b1c89[_0x58e669('0x19b2')]=_0x1b1c89[_0x58e669('0x260a')]&&_0x1b1c89[_0x58e669('0x260a')][_0x58e669('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1b1c89[_0x58e669('0xf28')]='SMS.EDIT_SMSCANNEDANSWER',_0x1b1c89[_0x58e669('0x1a74')]=angular[_0x58e669('0x1a86')](_0x2bc515),_0x1b1c89[_0x58e669('0x22e5')]=_0x5ea91c,_0x1b1c89[_0x58e669('0x21')]=![];!_0x1b1c89[_0x58e669('0x1a74')]&&(_0x1b1c89[_0x58e669('0x1a74')]={},_0x1b1c89[_0x58e669('0xf28')]=_0x58e669('0x82d'),_0x1b1c89[_0x58e669('0x21')]=!![]);_0x421e53[_0x58e669('0x7f2')]['id']&&(_0x1b1c89['smsCannedAnswer']['SmsAccountId']=_0x421e53['params']['id']);_0x1b1c89[_0x58e669('0xa6')]=_0x2a796e,_0x1b1c89['saveSmsCannedAnswer']=_0x710ed0,_0x1b1c89[_0x58e669('0x16bf')]=_0x537f48,_0x1b1c89[_0x58e669('0x16b3')]=_0xf86741,_0x1b1c89[_0x58e669('0xf82')]=_0x505de8;function _0x2a796e(){const _0x3dd51d=_0x58e669;_0x1b1c89['errors']=[],_0x327c05[_0x3dd51d('0x136c')]['save'](_0x1b1c89[_0x3dd51d('0x1a74')])[_0x3dd51d('0xe53')][_0x3dd51d('0x683')](function(_0x1cb0bc){const _0x368619=_0x3dd51d;_0x1b1c89[_0x368619('0x22e5')][_0x368619('0x1167')](_0x1cb0bc[_0x368619('0x24e1')]()),_0x2ac941[_0x368619('0x53')]({'title':_0x368619('0x2448'),'msg':_0x1b1c89[_0x368619('0x1a74')]['name']?_0x1b1c89[_0x368619('0x1a74')][_0x368619('0x60a')]+_0x368619('0x14b5'):''}),_0x505de8(_0x1cb0bc);})[_0x3dd51d('0x130a')](function(_0x5510f8){const _0x3c337b=_0x3dd51d;if(_0x5510f8[_0x3c337b('0x5a5')]&&_0x5510f8[_0x3c337b('0x5a5')]['errors']&&_0x5510f8[_0x3c337b('0x5a5')][_0x3c337b('0x17f')][_0x3c337b('0x1564')]){_0x1b1c89[_0x3c337b('0x17f')]=_0x5510f8[_0x3c337b('0x5a5')]['errors']||[{'message':_0x5510f8[_0x3c337b('0x1ff0')](),'type':_0x3c337b('0x267b')}];for(let _0x3bde8d=0x0;_0x3bde8d<_0x5510f8[_0x3c337b('0x5a5')][_0x3c337b('0x17f')]['length'];_0x3bde8d+=0x1){_0x2ac941[_0x3c337b('0x52a')]({'title':_0x5510f8['data'][_0x3c337b('0x17f')][_0x3bde8d]['type'],'msg':_0x5510f8[_0x3c337b('0x5a5')]['errors'][_0x3bde8d][_0x3c337b('0x8c2')]});}}else _0x2ac941[_0x3c337b('0x52a')]({'title':_0x5510f8[_0x3c337b('0x13ee')]?_0x3c337b('0x2168')+_0x5510f8['status']+'\x20-\x20'+_0x5510f8['statusText']:_0x3c337b('0x267b'),'msg':_0x5510f8[_0x3c337b('0x5a5')]?JSON[_0x3c337b('0x258a')](_0x5510f8[_0x3c337b('0x5a5')][_0x3c337b('0x8c2')]):_0x5510f8[_0x3c337b('0x1ff0')]()});});}function _0x710ed0(){const _0x920b93=_0x58e669;_0x1b1c89['errors']=[],_0x327c05[_0x920b93('0x136c')][_0x920b93('0x2480')]({'id':_0x1b1c89[_0x920b93('0x1a74')]['id']},_0x1b1c89[_0x920b93('0x1a74')])[_0x920b93('0xe53')][_0x920b93('0x683')](function(_0x1a2fe9){const _0x28b6c4=_0x920b93,_0x3013ab=_0x2e3ca0()[_0x28b6c4('0x1c07')](_0x1b1c89[_0x28b6c4('0x22e5')],{'id':_0x1a2fe9['id']});_0x3013ab&&_0x2e3ca0()[_0x28b6c4('0xf22')](_0x3013ab,_0x2e3ca0()['pick'](_0x1a2fe9[_0x28b6c4('0x24e1')](),_0x2e3ca0()[_0x28b6c4('0x55e')](_0x3013ab))),_0x2ac941['success']({'title':'SmsCannedAnswer\x20properly\x20saved!','msg':_0x1b1c89[_0x28b6c4('0x1a74')][_0x28b6c4('0x60a')]?_0x1b1c89['smsCannedAnswer'][_0x28b6c4('0x60a')]+_0x28b6c4('0xf59'):''}),_0x505de8(_0x1a2fe9);})[_0x920b93('0x130a')](function(_0xc8d645){const _0x1e3124=_0x920b93;if(_0xc8d645[_0x1e3124('0x5a5')]&&_0xc8d645[_0x1e3124('0x5a5')]['errors']&&_0xc8d645[_0x1e3124('0x5a5')][_0x1e3124('0x17f')][_0x1e3124('0x1564')]){_0x1b1c89['errors']=_0xc8d645[_0x1e3124('0x5a5')][_0x1e3124('0x17f')]||[{'message':_0xc8d645[_0x1e3124('0x1ff0')](),'type':'api.cannedAnswer.update'}];for(let _0x881e7a=0x0;_0x881e7a<_0xc8d645[_0x1e3124('0x5a5')][_0x1e3124('0x17f')][_0x1e3124('0x1564')];_0x881e7a++){_0x2ac941[_0x1e3124('0x52a')]({'title':_0xc8d645[_0x1e3124('0x5a5')][_0x1e3124('0x17f')][_0x881e7a]['type'],'msg':_0xc8d645[_0x1e3124('0x5a5')][_0x1e3124('0x17f')][_0x881e7a][_0x1e3124('0x8c2')]});}}else _0x2ac941[_0x1e3124('0x52a')]({'title':_0xc8d645[_0x1e3124('0x13ee')]?_0x1e3124('0x2168')+_0xc8d645[_0x1e3124('0x13ee')]+'\x20-\x20'+_0xc8d645[_0x1e3124('0x24a9')]:'api.cannedAnswer.update','msg':_0xc8d645[_0x1e3124('0x5a5')]?JSON[_0x1e3124('0x258a')](_0xc8d645[_0x1e3124('0x5a5')][_0x1e3124('0x8c2')]):_0xc8d645['toString']()});});}function _0x537f48(_0x74159f){const _0x2f0181=_0x58e669;_0x1b1c89[_0x2f0181('0x17f')]=[];const _0x3b3ccb=_0x3d988c['confirm']()[_0x2f0181('0xf28')](_0x2f0181('0x4d'))['content'](_0x2f0181('0xa76'))[_0x2f0181('0x1040')]('Delete\x20SmsCannedAnswer')['ok'](_0x2f0181('0x2307'))[_0x2f0181('0x19fb')]('Cancel')[_0x2f0181('0xe42')](_0x74159f);_0x3d988c[_0x2f0181('0x1d4')](_0x3b3ccb)[_0x2f0181('0x683')](function(){const _0x11a9b1=_0x2f0181;_0x327c05[_0x11a9b1('0x136c')]['delete']({'id':_0x1b1c89[_0x11a9b1('0x1a74')]['id']})[_0x11a9b1('0xe53')][_0x11a9b1('0x683')](function(){const _0x573c92=_0x11a9b1;_0x2e3ca0()[_0x573c92('0x3ec')](_0x1b1c89['smsCannedAnswers'],{'id':_0x1b1c89[_0x573c92('0x1a74')]['id']}),_0x2ac941[_0x573c92('0x53')]({'title':'SmsCannedAnswer\x20properly\x20deleted!','msg':(_0x1b1c89[_0x573c92('0x1a74')][_0x573c92('0x60a')]||_0x573c92('0x1a74'))+'\x20has\x20been\x20deleted!'}),_0x505de8(_0x1b1c89[_0x573c92('0x1a74')]);})[_0x11a9b1('0x130a')](function(_0x57a5be){const _0x3fe17a=_0x11a9b1;if(_0x57a5be['data']&&_0x57a5be['data'][_0x3fe17a('0x17f')]&&_0x57a5be['data'][_0x3fe17a('0x17f')]['length']){_0x1b1c89['errors']=_0x57a5be[_0x3fe17a('0x5a5')]['errors']||[{'message':_0x57a5be['toString'](),'type':_0x3fe17a('0x253e')}];for(let _0x10443b=0x0;_0x10443b<_0x57a5be['data']['errors']['length'];_0x10443b++){_0x2ac941['error']({'title':_0x57a5be[_0x3fe17a('0x5a5')][_0x3fe17a('0x17f')][_0x10443b][_0x3fe17a('0xcf0')],'msg':_0x57a5be[_0x3fe17a('0x5a5')][_0x3fe17a('0x17f')][_0x10443b]['message']});}}else _0x2ac941[_0x3fe17a('0x52a')]({'title':_0x57a5be[_0x3fe17a('0x13ee')]?_0x3fe17a('0x2168')+_0x57a5be[_0x3fe17a('0x13ee')]+_0x3fe17a('0xbf6')+_0x57a5be[_0x3fe17a('0x24a9')]:_0x3fe17a('0x253e'),'msg':_0x57a5be[_0x3fe17a('0x5a5')]?JSON[_0x3fe17a('0x258a')](_0x57a5be[_0x3fe17a('0x5a5')][_0x3fe17a('0x8c2')]):_0x57a5be[_0x3fe17a('0x8c2')]||_0x57a5be[_0x3fe17a('0x1ff0')]()});});},function(){});}function _0xf86741(_0x57c558){return _0x57c558===null?undefined:new Date(_0x57c558);}function _0x505de8(_0x359ff8){const _0x5b4ba6=_0x58e669;_0x3d988c[_0x5b4ba6('0x1715')](_0x359ff8);}}const _0xd62d99=_0x170421;_0x1e7c7e[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),'$mdDialog','$document','$timeout',_0x189033('0x1d08'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1')];function _0x1e7c7e(_0x742f60,_0x2bf26a,_0xfa336c,_0x19c306,_0x410e31,_0x4d3ba0,_0x428df1,_0x55aadd,_0x14d3fa,_0x3daae2,_0x5ad1d5){const _0x415088=_0x189033,_0x3063e0=this;_0x3063e0[_0x415088('0x11ed')]=_0x5ad1d5[_0x415088('0x20b2')](),_0x3063e0[_0x415088('0x191e')]={'count':0x0,'rows':[]},_0x3063e0[_0x415088('0x17')]=[],_0x3063e0[_0x415088('0x1134')],_0x3063e0[_0x415088('0x1d01')]={'first':_0x415088('0x1fd1'),'second':_0x415088('0x7c2'),'third':_0x415088('0x10ce')},_0x3063e0['query']={'fields':_0x415088('0xadb'),'sort':_0x415088('0xc36'),'limit':0xa,'page':0x1},_0x3063e0[_0x415088('0x12f3')]=_0x580d57,_0x3063e0[_0x415088('0x26eb')]=_0x4f7351,_0x3063e0[_0x415088('0x53')]=_0x2f0485,_0x3063e0[_0x415088('0x13d9')]=_0x2375c3,_0x3063e0[_0x415088('0xe69')]=_0x442883,_0x3063e0[_0x415088('0x207b')]=_0x2515cb,_0x3063e0[_0x415088('0x224b')]=_0x1360f7,_0x3063e0[_0x415088('0x238e')]=_0x789466,_0x3063e0[_0x415088('0x268c')]=_0x5e881c,_0x3063e0[_0x415088('0x1801')]=_0x20542f;function _0x580d57(_0x1ca48c,_0x1fe4e8){const _0xb9cc61=_0x415088;_0x3063e0[_0xb9cc61('0xa0e')]=_0x1ca48c||{},_0x3063e0['crudPermissions']=typeof _0x1fe4e8!=='undefined'?_0x1fe4e8:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3063e0['query']['SmsAccountId']=_0x3063e0[_0xb9cc61('0xa0e')]['id'],_0x3063e0[_0xb9cc61('0x23a2')]['id']=_0x3063e0[_0xb9cc61('0xa0e')]['id'],_0x2375c3();}function _0x442883(_0x245f29,_0x411d54){const _0x263cd2=_0x415088;_0x410e31[_0x263cd2('0x1d4')]({'controller':_0x263cd2('0x1ecc'),'controllerAs':'vm','templateUrl':_0x32807f,'parent':angular[_0x263cd2('0x1fcc')](_0x4d3ba0[_0x263cd2('0x18e5')]),'targetEvent':_0x245f29,'clickOutsideToClose':!![],'locals':{'disposition':_0x411d54,'dispositions':_0x3063e0[_0x263cd2('0x191e')][_0x263cd2('0xf5d')],'model':{'id':_0x3063e0[_0x263cd2('0xa0e')]['id'],'field':'SmsAccountId'},'license':null,'setting':null,'crudPermissions':_0x3063e0[_0x263cd2('0x1134')]}})[_0x263cd2('0x683')](function(_0x402dfa){if(_0x402dfa)_0x2375c3();});}function _0x4f7351(_0x1f57c9,_0x2e5d87){const _0x4a6c6e=_0x415088,_0x3a5095=_0x2e3ca0()[_0x4a6c6e('0x7a2')](_0x3063e0[_0x4a6c6e('0x191e')][_0x4a6c6e('0xf5d')],['ParentId',_0x1f57c9['id']]),_0x353ea5=_0x410e31[_0x4a6c6e('0x1c6f')]()[_0x4a6c6e('0xf28')](_0x55aadd[_0x4a6c6e('0x2728')](_0x4a6c6e('0x15d8')))['content'](_0x55aadd[_0x4a6c6e('0x2728')](_0x4a6c6e('0x13bf')+(_0x3a5095?_0x4a6c6e('0x2235'):_0x4a6c6e('0x106')),{'name':_0x1f57c9[_0x4a6c6e('0x60a')]}))[_0x4a6c6e('0x1040')]('Delete\x20disposition')[_0x4a6c6e('0xe42')](_0x2e5d87)['ok']('OK')[_0x4a6c6e('0x19fb')](_0x55aadd[_0x4a6c6e('0x2728')]('TOOLS.CANCEL'));_0x410e31[_0x4a6c6e('0x1d4')](_0x353ea5)[_0x4a6c6e('0x683')](function(){_0x2515cb(_0x1f57c9);});}function _0x2f0485(_0x27e82c){const _0x1cb58d=_0x415088;_0x3063e0[_0x1cb58d('0x191e')]=_0x27e82c||{'count':0x0,'rows':[]};}function _0x2375c3(){const _0x268772=_0x415088;_0x3063e0[_0x268772('0x23a2')]['offset']=(_0x3063e0[_0x268772('0x23a2')][_0x268772('0xdf8')]-0x1)*_0x3063e0[_0x268772('0x23a2')][_0x268772('0x6f0')],_0x3063e0[_0x268772('0x1883')]=_0x14d3fa['smsAccount'][_0x268772('0x13d9')](_0x3063e0['query'],_0x2f0485)[_0x268772('0xe53')];}function _0x2515cb(_0x4d37bf){const _0x282b31=_0x415088;_0x14d3fa[_0x282b31('0x43f')][_0x282b31('0xd7e')]({'id':_0x4d37bf['id']})[_0x282b31('0xe53')][_0x282b31('0x683')](function(){const _0x547fa8=_0x282b31;_0x2375c3(),_0x3daae2[_0x547fa8('0x53')]({'title':_0x55aadd[_0x547fa8('0x2728')](_0x547fa8('0x210b'))});})[_0x282b31('0x130a')](function(_0x23bba6){const _0x357854=_0x282b31;if(_0x23bba6[_0x357854('0x5a5')]&&_0x23bba6[_0x357854('0x5a5')]['errors']&&_0x23bba6[_0x357854('0x5a5')][_0x357854('0x17f')][_0x357854('0x1564')]){_0x3063e0[_0x357854('0x17f')]=_0x23bba6[_0x357854('0x5a5')][_0x357854('0x17f')]||[{'message':_0x23bba6[_0x357854('0x1ff0')](),'type':'SYSTEM:DELETEdisposition'}];for(let _0x49929c=0x0;_0x49929c<_0x23bba6['data'][_0x357854('0x17f')][_0x357854('0x1564')];_0x49929c++){_0x3daae2[_0x357854('0x52a')]({'title':_0x23bba6['data'][_0x357854('0x17f')][_0x49929c][_0x357854('0xcf0')],'msg':_0x23bba6['data'][_0x357854('0x17f')][_0x49929c]['message']});}}else _0x3daae2[_0x357854('0x52a')]({'title':_0x23bba6[_0x357854('0x13ee')]?_0x357854('0x2168')+_0x23bba6['status']+_0x357854('0xbf6')+_0x23bba6['statusText']:'SYSTEM:DELETEdisposition','msg':_0x23bba6[_0x357854('0x5a5')]?JSON[_0x357854('0x258a')](_0x23bba6[_0x357854('0x5a5')][_0x357854('0x8c2')]):_0x23bba6[_0x357854('0x8c2')]||_0x23bba6[_0x357854('0x1ff0')]()});});}function _0x1360f7(){const _0x4308f7=_0x415088,_0x4edd0d=angular[_0x4308f7('0x1a86')](_0x3063e0[_0x4308f7('0x17')]);return _0x3063e0['selectedDispositions']=[],_0x4edd0d;}function _0x789466(_0x1df69f){const _0x11968e=_0x415088,_0x56e432=_0x410e31[_0x11968e('0x1c6f')]()['title'](_0x55aadd[_0x11968e('0x2728')](_0x11968e('0xfa')))[_0x11968e('0xa6a')](_0x55aadd[_0x11968e('0x2728')](_0x11968e('0x1ebe'),{'total':_0x3063e0[_0x11968e('0x17')][_0x11968e('0x1564')]}))['ariaLabel'](_0x11968e('0xb49'))['targetEvent'](_0x1df69f)['ok']('OK')[_0x11968e('0x19fb')](_0x55aadd[_0x11968e('0x2728')]('TOOLS.CANCEL'));_0x410e31[_0x11968e('0x1d4')](_0x56e432)[_0x11968e('0x683')](function(){const _0x702010=_0x11968e;_0x3063e0[_0x702010('0x17')][_0x702010('0x1299')](function(_0x476485){_0x2515cb(_0x476485);}),_0x3063e0[_0x702010('0x17')]=[];});}function _0x5e881c(){const _0x31bbfd=_0x415088;_0x3063e0[_0x31bbfd('0x17')]=[];}function _0x20542f(){const _0x196886=_0x415088;_0x3063e0[_0x196886('0x17')]=_0x3063e0[_0x196886('0x191e')][_0x196886('0xf5d')];}let _0x3e9fce=!![],_0x1e8a97=0x1;_0x742f60[_0x415088('0x186d')]('vm_dc.query.filter',function(_0x56d194,_0x916d4e){const _0x55775c=_0x415088;_0x3e9fce?_0x428df1(function(){_0x3e9fce=![];}):(!_0x916d4e&&(_0x1e8a97=_0x3063e0[_0x55775c('0x23a2')][_0x55775c('0xdf8')]),_0x56d194!==_0x916d4e&&(_0x3063e0[_0x55775c('0x23a2')]['page']=0x1),!_0x56d194&&(_0x3063e0[_0x55775c('0x23a2')][_0x55775c('0xdf8')]=_0x1e8a97),_0x2375c3());});}const _0x3a4037=_0x1e7c7e,_0x28fff8=_0x180212['p']+_0x189033('0x1123');_0x26aa27[_0x189033('0x14be')]=['$state',_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),'smsAccount',_0x189033('0x22df')];function _0x26aa27(_0x24a405,_0x54e4ba,_0x905cf9,_0x33168f,_0x1fb782,_0x12b2b7,_0x5ac58e,_0x42da3b,_0x365f91,_0x183068,_0x20f2e0,_0x551c34){const _0x139815=_0x189033,_0x5b7b0e=this;_0x5b7b0e[_0x139815('0x11ed')]=_0x183068['getCurrentUser'](),_0x5b7b0e[_0x139815('0xace')]=_0x12b2b7,_0x5b7b0e['setting']=_0x5ac58e,_0x5b7b0e[_0x139815('0x19b2')]=_0x5b7b0e[_0x139815('0x260a')][_0x139815('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5b7b0e[_0x139815('0x1224')]=_0x54e4ba[_0x139815('0x173e')]()+_0x139815('0x20de')+_0x54e4ba['host'](),_0x5b7b0e[_0x139815('0xa0e')]=_0x20f2e0||_0x24a405[_0x139815('0x7f2')]['smsAccount']||{},_0x5b7b0e[_0x139815('0x22df')]=_0x551c34&&_0x551c34['count']==0x1?_0x551c34[_0x139815('0xf5d')][0x0]:null,_0x5b7b0e[_0x139815('0x1134')]=_0x183068[_0x139815('0x142a')](_0x5b7b0e[_0x139815('0x22df')]?_0x5b7b0e[_0x139815('0x22df')][_0x139815('0x1134')]:null),_0x5b7b0e[_0x139815('0x258d')]={},_0x5b7b0e['selectedTab']=_0x24a405['params'][_0x139815('0x1904')]||0x0,_0x5b7b0e[_0x139815('0x2814')]=_0xc2eafb,_0x5b7b0e[_0x139815('0x2430')]=_0x365f91[_0x139815('0x2289')],_0x5b7b0e[_0x139815('0x135c')]=_0x2ec251,_0x5b7b0e[_0x139815('0xed2')]=_0xf0eaae,_0x183068['hasRole']('admin')?_0x42da3b[_0x139815('0x259b')][_0x139815('0x1e6e')]({'fields':_0x139815('0xa10'),'sort':_0x139815('0x60a')})[_0x139815('0xe53')][_0x139815('0x683')](function(_0x51ac5e){const _0xa7c767=_0x139815;_0x5b7b0e[_0xa7c767('0xe01')]=_0x51ac5e['rows']||[];})['catch'](function(_0x3efdff){const _0x50d53e=_0x139815;_0x365f91['error']({'title':_0x3efdff[_0x50d53e('0x13ee')]?'API:'+_0x3efdff[_0x50d53e('0x13ee')]+'\x20-\x20'+_0x3efdff[_0x50d53e('0x24a9')]:_0x50d53e('0x251b'),'msg':_0x3efdff[_0x50d53e('0x5a5')]?JSON[_0x50d53e('0x258a')](_0x3efdff[_0x50d53e('0x5a5')]):_0x3efdff[_0x50d53e('0x1ff0')]()});}):_0x42da3b[_0x139815('0x259b')][_0x139815('0x1e6e')]({'fields':'id,name','sort':'name'})[_0x139815('0xe53')]['then'](function(_0x58ed88){const _0x54fc1e=_0x139815;_0x5b7b0e['lists']=_0x58ed88[_0x54fc1e('0xf5d')]||[];})[_0x139815('0x683')](function(){const _0x5dec80=_0x139815;return _0x42da3b[_0x5dec80('0x22df')]['get']({'userProfileId':_0x5b7b0e[_0x5dec80('0x11ed')][_0x5dec80('0x2f')],'sectionId':0x12d})[_0x5dec80('0xe53')];})[_0x139815('0x683')](function(_0x5e43b7){const _0x36da99=_0x139815,_0x4cc4ea=_0x5e43b7&&_0x5e43b7[_0x36da99('0xf5d')]?_0x5e43b7['rows'][0x0]:null;if(!_0x4cc4ea){const _0x1a37b6=[];let _0x38204e=null;_0x5b7b0e[_0x36da99('0xa0e')]&&(_0x38204e=_0x2e3ca0()[_0x36da99('0x1c07')](_0x5b7b0e[_0x36da99('0xe01')],{'id':Number(_0x5b7b0e[_0x36da99('0xa0e')][_0x36da99('0x1e4f')])}));for(let _0x27758c=0x0;_0x27758c<_0x5b7b0e['lists']['length'];_0x27758c++){_0x38204e&&_0x5b7b0e[_0x36da99('0xe01')][_0x27758c]['id']===_0x38204e['id']&&(_0x5b7b0e[_0x36da99('0xe01')][_0x27758c][_0x36da99('0x319')]=![],_0x1a37b6['push'](_0x5b7b0e[_0x36da99('0xe01')][_0x27758c]));}_0x5b7b0e['lists']=_0x1a37b6;}else{if(!_0x4cc4ea[_0x36da99('0x170')])return _0x42da3b[_0x36da99('0xcf7')][_0x36da99('0x1e6e')]({'sectionId':_0x4cc4ea['id']})[_0x36da99('0xe53')]['then'](function(_0x176623){const _0xa97a98=_0x36da99,_0x386981=_0x2e3ca0()[_0xa97a98('0x386')](_0x176623[_0xa97a98('0xf5d')],function(_0x42d070){const _0xff44ef=_0xa97a98;return _0x2e3ca0()[_0xff44ef('0x1c07')](_0x5b7b0e['lists'],{'id':_0x42d070['resourceId']});});let _0x523c2c=null;_0x5b7b0e[_0xa97a98('0xa0e')]&&(_0x523c2c=_0x2e3ca0()[_0xa97a98('0x1c07')](_0x5b7b0e[_0xa97a98('0xe01')],{'id':Number(_0x5b7b0e[_0xa97a98('0xa0e')]['ListId'])}));if(_0x523c2c&&!_0x2e3ca0()[_0xa97a98('0x7a2')](_0x386981,['id',_0x523c2c['id']])){const _0x39ade6=_0x2e3ca0()[_0xa97a98('0x1c07')](_0x5b7b0e[_0xa97a98('0xe01')],{'id':_0x523c2c['id']});_0x39ade6['canSelect']=![],_0x386981[_0xa97a98('0x1fd0')](_0x39ade6);}_0x5b7b0e['lists']=_0x386981;});}})[_0x139815('0x130a')](function(_0xc123c){const _0x10e1f7=_0x139815;_0x365f91[_0x10e1f7('0x52a')]({'title':_0xc123c[_0x10e1f7('0x13ee')]?'API:'+_0xc123c['status']+_0x10e1f7('0xbf6')+_0xc123c[_0x10e1f7('0x24a9')]:_0x10e1f7('0x11e3'),'msg':_0xc123c[_0x10e1f7('0x5a5')]?JSON[_0x10e1f7('0x258a')](_0xc123c[_0x10e1f7('0x5a5')]):_0xc123c[_0x10e1f7('0x1ff0')]()});}),_0x183068[_0x139815('0xca1')](_0x139815('0x20c2'))?_0x42da3b[_0x139815('0xa4')][_0x139815('0x1e6e')]({'fields':'name,id','sort':_0x139815('0x60a'),'nolimit':_0x139815('0x26ac')})[_0x139815('0xe53')][_0x139815('0x683')](function(_0x1cb582){const _0x2ccd9e=_0x139815;_0x5b7b0e[_0x2ccd9e('0x22ab')]=_0x1cb582[_0x2ccd9e('0xf5d')]||[];})[_0x139815('0x130a')](function(_0x22c9e5){const _0xbebf76=_0x139815;_0x365f91[_0xbebf76('0x52a')]({'title':_0x22c9e5[_0xbebf76('0x13ee')]?_0xbebf76('0x2168')+_0x22c9e5['status']+_0xbebf76('0xbf6')+_0x22c9e5[_0xbebf76('0x24a9')]:_0xbebf76('0x4ba'),'msg':_0x22c9e5[_0xbebf76('0x5a5')]?JSON[_0xbebf76('0x258a')](_0x22c9e5['data']):_0x22c9e5[_0xbebf76('0x1ff0')]()});}):_0x42da3b[_0x139815('0xa4')][_0x139815('0x1e6e')]({'fields':_0x139815('0x1688'),'sort':_0x139815('0x60a'),'nolimit':_0x139815('0x26ac')})[_0x139815('0xe53')][_0x139815('0x683')](function(_0xea8b0e){const _0x56e418=_0x139815;_0x5b7b0e[_0x56e418('0x22ab')]=_0xea8b0e[_0x56e418('0xf5d')]||[];})[_0x139815('0x683')](function(){const _0x3448ee=_0x139815;return _0x42da3b[_0x3448ee('0x22df')][_0x3448ee('0x1e6e')]({'userProfileId':_0x5b7b0e[_0x3448ee('0x11ed')]['userProfileId'],'sectionId':0x3ed})[_0x3448ee('0xe53')];})['then'](function(_0x3ab1f4){const _0x1bbdd4=_0x139815,_0x18e5de=_0x3ab1f4&&_0x3ab1f4[_0x1bbdd4('0xf5d')]?_0x3ab1f4[_0x1bbdd4('0xf5d')][0x0]:null;if(!_0x18e5de)_0x5b7b0e[_0x1bbdd4('0x22ab')]=[];else{if(!_0x18e5de[_0x1bbdd4('0x170')])return _0x42da3b[_0x1bbdd4('0xcf7')][_0x1bbdd4('0x1e6e')]({'sectionId':_0x18e5de['id']})['$promise'][_0x1bbdd4('0x683')](function(_0x65a2ca){const _0x1543d7=_0x1bbdd4,_0x1bd6df=_0x2e3ca0()[_0x1543d7('0x386')](_0x65a2ca[_0x1543d7('0xf5d')],function(_0x464abf){const _0x12b0de=_0x1543d7;return _0x2e3ca0()[_0x12b0de('0x1c07')](_0x5b7b0e[_0x12b0de('0x22ab')],{'id':_0x464abf['resourceId']});});_0x5b7b0e['pauses'][_0x1543d7('0x1299')](function(_0x2d61b7){const _0x1c7220=_0x1543d7;!_0x2e3ca0()[_0x1c7220('0x7a2')](_0x1bd6df,['id',_0x2d61b7['id']])&&(_0x2d61b7['canSelect']=![]),_0x1bd6df[_0x1c7220('0x1fd0')](_0x2d61b7);}),_0x5b7b0e[_0x1543d7('0x22ab')]=_0x1bd6df;});}})[_0x139815('0x130a')](function(_0x2f724e){const _0x523517=_0x139815;_0x365f91[_0x523517('0x52a')]({'title':_0x2f724e[_0x523517('0x13ee')]?_0x523517('0x2168')+_0x2f724e['status']+'\x20-\x20'+_0x2f724e[_0x523517('0x24a9')]:_0x523517('0xc45'),'msg':_0x2f724e[_0x523517('0x5a5')]?JSON[_0x523517('0x258a')](_0x2f724e['data']):_0x2f724e['toString']()});});function _0xc2eafb(_0x42e5ab,_0x4bfb70){const _0x3e52ad=_0x139815;_0x905cf9[_0x3e52ad('0x1d4')]({'controller':_0x3e52ad('0x1e06'),'controllerAs':'vm','templateUrl':_0x28fff8,'parent':angular[_0x3e52ad('0x1fcc')](_0x33168f['body']),'targetEvent':_0x4bfb70,'clickOutsideToClose':!![],'locals':{'smsAccount':_0x42e5ab,'smsAccounts':_0x5b7b0e[_0x3e52ad('0x197c')]?_0x5b7b0e[_0x3e52ad('0x197c')]['rows']:[],'crudPermissions':_0x5b7b0e[_0x3e52ad('0x1134')],'realtime':![]}});}function _0x2ec251(){_0x24a405['go']('app.sms.smsAccounts',{},{'reload':'app.sms.smsAccounts'});}function _0xf0eaae(){const _0x3a22f4=_0x139815;_0x42da3b['smsAccount'][_0x3a22f4('0x2480')]({'id':_0x5b7b0e['smsAccount']['id']},_0x5b7b0e[_0x3a22f4('0xa0e')])[_0x3a22f4('0xe53')][_0x3a22f4('0x683')](function(){const _0x310007=_0x3a22f4;_0x365f91['success']({'title':_0x310007('0x104b'),'msg':_0x5b7b0e[_0x310007('0xa0e')][_0x310007('0x60a')]?_0x5b7b0e['smsAccount'][_0x310007('0x60a')]+_0x310007('0x96c'):''});})[_0x3a22f4('0x130a')](function(_0x999a50){const _0x37463e=_0x3a22f4;_0x365f91['error']({'title':_0x999a50[_0x37463e('0x13ee')]?_0x37463e('0x2168')+_0x999a50['status']+_0x37463e('0xbf6')+_0x999a50[_0x37463e('0x24a9')]:_0x37463e('0x1d89'),'msg':_0x999a50[_0x37463e('0x5a5')]?JSON['stringify'](_0x999a50['data']):_0x999a50[_0x37463e('0x1ff0')]()});});}}const _0x38204d=_0x26aa27,_0x30189b=_0x180212['p']+_0x189033('0x16be');_0x1d1df1['$inject']=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0x197c'),'userProfile','userProfileSection',_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),'setting'];function _0x1d1df1(_0x58c769,_0x5f1db7,_0x43c38a,_0x4d13e8,_0x12f383,_0x47b923,_0x260c74,_0x3ecf78,_0x8d34a4,_0x4df41e,_0x3007e3,_0x1e2932,_0xf6da36,_0x4243e9,_0x46d07f,_0x142a08,_0x233d0d){const _0x28028f=_0x189033,_0x520a41=this;_0x520a41[_0x28028f('0xace')]=_0x142a08,_0x520a41[_0x28028f('0x260a')]=_0x233d0d,_0x520a41[_0x28028f('0x11ed')]=_0x46d07f[_0x28028f('0x20b2')](),_0x520a41[_0x28028f('0x197c')]=_0x8d34a4||{'count':0x0,'rows':[]},_0x520a41[_0x28028f('0x2a')]=_0x4df41e,_0x520a41[_0x28028f('0x22df')]=_0x3007e3&&_0x3007e3[_0x28028f('0x50d')]==0x1?_0x3007e3[_0x28028f('0xf5d')][0x0]:null,_0x520a41[_0x28028f('0x1134')]=_0x46d07f[_0x28028f('0x142a')](_0x520a41[_0x28028f('0x22df')]?_0x520a41[_0x28028f('0x22df')][_0x28028f('0x1134')]:null),_0x520a41[_0x28028f('0x5c4')]=_0x28028f('0x197c'),_0x520a41['listOrder']='',_0x520a41[_0x28028f('0x1ce2')]=null,_0x520a41[_0x28028f('0x12f8')]=[],_0x520a41[_0x28028f('0x23a2')]={'fields':_0x28028f('0x1892'),'sort':_0x28028f('0xc36'),'limit':0xa,'page':0x1},_0x520a41['arraytype']=_0x2e3ca0()[_0x28028f('0x24db')]([{'option':_0x28028f('0x20e5'),'value':_0x28028f('0x255')},{'option':'Skebby','value':_0x28028f('0x2282')},{'option':_0x28028f('0x2190'),'value':'\x27connectel\x27'},{'option':_0x28028f('0x1085'),'value':'\x27clicksend\x27'},{'option':'Plivo','value':_0x28028f('0x9ef')},{'option':_0x28028f('0xeee'),'value':_0x28028f('0x1bd4')},{'option':'Clickatell','value':_0x28028f('0xd7f')},{'option':'CSCTelecom','value':_0x28028f('0x223e')},{'option':_0x28028f('0x1a3a'),'value':'\x27intelepeer\x27'}],function(_0x130d0b){const _0x47cc88=_0x28028f;return _0x2e3ca0()[_0x47cc88('0x1725')](_0x130d0b[_0x47cc88('0x1c6b')],new RegExp('\x27','g'),'');}),_0x520a41[_0x28028f('0x3ba')]=_0x2e3ca0()[_0x28028f('0x24db')]([{'option':_0x28028f('0x720'),'value':_0x28028f('0x270c')},{'option':_0x28028f('0x136e'),'value':'\x27TI\x27'},{'option':_0x28028f('0x1dc7'),'value':_0x28028f('0x2610')}],function(_0x40e3ec){const _0x4e6110=_0x28028f;return _0x2e3ca0()[_0x4e6110('0x1725')](_0x40e3ec[_0x4e6110('0x1c6b')],new RegExp('\x27','g'),'');}),_0x520a41[_0x28028f('0xc63')]=_0x47cce4,_0x520a41['interactionsgoto']=_0x497bbf,_0x520a41[_0x28028f('0x2814')]=_0x26d307,_0x520a41[_0x28028f('0x194f')]=_0x474a70,_0x520a41['success']=_0x1be82a,_0x520a41['getSmsAccounts']=_0x513042,_0x520a41[_0x28028f('0xff0')]=_0x212b7f,_0x520a41[_0x28028f('0x49a')]=_0x5c0f6a,_0x520a41[_0x28028f('0x2a7')]=_0x27cb12,_0x520a41[_0x28028f('0xecd')]=_0x4afd21,_0x520a41[_0x28028f('0x24ad')]=_0x292fc7,_0x520a41[_0x28028f('0xbcc')]=_0x4f4aa3,_0x46d07f['hasRole'](_0x28028f('0x20c2'))?_0x1e2932['cmList'][_0x28028f('0x1e6e')]({'fields':_0x28028f('0xa10'),'sort':'name'})[_0x28028f('0xe53')][_0x28028f('0x683')](function(_0x214aae){_0x520a41['lists']=_0x214aae['rows']||[];})[_0x28028f('0x130a')](function(_0x17b979){const _0x3a2418=_0x28028f;_0x4243e9[_0x3a2418('0x52a')]({'title':_0x17b979[_0x3a2418('0x13ee')]?_0x3a2418('0x2168')+_0x17b979[_0x3a2418('0x13ee')]+_0x3a2418('0xbf6')+_0x17b979['statusText']:_0x3a2418('0x251b'),'msg':_0x17b979[_0x3a2418('0x5a5')]?JSON[_0x3a2418('0x258a')](_0x17b979[_0x3a2418('0x5a5')]):_0x17b979[_0x3a2418('0x1ff0')]()});}):_0x1e2932[_0x28028f('0x259b')]['get']({'fields':_0x28028f('0xa10'),'sort':_0x28028f('0x60a')})['$promise'][_0x28028f('0x683')](function(_0x300215){const _0x307b2d=_0x28028f;_0x520a41['lists']=_0x300215[_0x307b2d('0xf5d')]||[];})[_0x28028f('0x683')](function(){const _0x48fdfe=_0x28028f;return _0x1e2932[_0x48fdfe('0x22df')][_0x48fdfe('0x1e6e')]({'userProfileId':_0x520a41['currentUser']['userProfileId'],'sectionId':0x12d})[_0x48fdfe('0xe53')];})['then'](function(_0x351716){const _0x25b561=_0x28028f,_0x67752c=_0x351716&&_0x351716[_0x25b561('0xf5d')]?_0x351716[_0x25b561('0xf5d')][0x0]:null;if(!_0x67752c){const _0xb42496=[];let _0x4e34c1=null;_0x520a41[_0x25b561('0xa0e')]&&(_0x4e34c1=_0x2e3ca0()[_0x25b561('0x1c07')](_0x520a41['lists'],{'id':Number(_0x520a41['smsAccount']['ListId'])}));for(let _0x9da6e=0x0;_0x9da6e<_0x520a41[_0x25b561('0xe01')]['length'];_0x9da6e++){_0x4e34c1&&_0x520a41[_0x25b561('0xe01')][_0x9da6e]['id']===_0x4e34c1['id']&&(_0x520a41[_0x25b561('0xe01')][_0x9da6e]['canSelect']=![],_0xb42496['push'](_0x520a41[_0x25b561('0xe01')][_0x9da6e]));}_0x520a41[_0x25b561('0xe01')]=_0xb42496;}else{if(!_0x67752c[_0x25b561('0x170')])return _0x1e2932[_0x25b561('0xcf7')][_0x25b561('0x1e6e')]({'sectionId':_0x67752c['id']})['$promise']['then'](function(_0x18b513){const _0x5a4113=_0x25b561,_0x338eea=_0x2e3ca0()[_0x5a4113('0x386')](_0x18b513[_0x5a4113('0xf5d')],function(_0x56049c){const _0x164639=_0x5a4113;return _0x2e3ca0()[_0x164639('0x1c07')](_0x520a41[_0x164639('0xe01')],{'id':_0x56049c[_0x164639('0x832')]});});let _0x49f0fc=null;_0x520a41[_0x5a4113('0xa0e')]&&(_0x49f0fc=_0x2e3ca0()[_0x5a4113('0x1c07')](_0x520a41[_0x5a4113('0xe01')],{'id':Number(_0x520a41[_0x5a4113('0xa0e')][_0x5a4113('0x1e4f')])}));if(_0x49f0fc&&!_0x2e3ca0()['some'](_0x338eea,['id',_0x49f0fc['id']])){const _0x457ee4=_0x2e3ca0()[_0x5a4113('0x1c07')](_0x520a41[_0x5a4113('0xe01')],{'id':_0x49f0fc['id']});_0x457ee4['canSelect']=![],_0x338eea['push'](_0x457ee4);}_0x520a41[_0x5a4113('0xe01')]=_0x338eea;});}})[_0x28028f('0x130a')](function(_0x4b754f){const _0x5cafe2=_0x28028f;_0x4243e9[_0x5cafe2('0x52a')]({'title':_0x4b754f['status']?_0x5cafe2('0x2168')+_0x4b754f[_0x5cafe2('0x13ee')]+_0x5cafe2('0xbf6')+_0x4b754f[_0x5cafe2('0x24a9')]:_0x5cafe2('0x11e3'),'msg':_0x4b754f[_0x5cafe2('0x5a5')]?JSON[_0x5cafe2('0x258a')](_0x4b754f[_0x5cafe2('0x5a5')]):_0x4b754f['toString']()});});function _0x47cce4(_0x1b3a99){const _0x4b8352=_0x28028f;_0x43c38a['go'](_0x4b8352('0x2533'),{'id':_0x1b3a99['id'],'smsAccount':_0x1b3a99,'crudPermissions':_0x520a41['crudPermissions']});}function _0x497bbf(_0x3adb91){const _0xbc6f27=_0x28028f;_0x43c38a['go'](_0xbc6f27('0x2533'),{'id':_0x3adb91['id'],'tab':0x5});}function _0x26d307(_0x1a39d9,_0x411949){const _0x5e2791=_0x28028f;_0x12f383[_0x5e2791('0x1d4')]({'controller':_0x5e2791('0x1e06'),'controllerAs':'vm','templateUrl':_0x28fff8,'parent':angular[_0x5e2791('0x1fcc')](_0x47b923['body']),'targetEvent':_0x411949,'clickOutsideToClose':!![],'locals':{'smsAccount':_0x1a39d9,'smsAccounts':_0x520a41[_0x5e2791('0x197c')]?_0x520a41[_0x5e2791('0x197c')][_0x5e2791('0xf5d')]:[],'crudPermissions':_0x520a41['crudPermissions'],'realtime':![]}});}function _0x474a70(_0x2d7a9a,_0x567809){const _0x48708d=_0x28028f,_0x2f65ff=_0x12f383['confirm']()[_0x48708d('0xf28')](_0x48708d('0x1b01')+_0x2e3ca0()[_0x48708d('0x1e03')]('smsAccount')+'?')[_0x48708d('0x26e3')](_0x48708d('0xed5')+(_0x2d7a9a[_0x48708d('0x60a')]||'smsAccount')+_0x48708d('0x20f1')+_0x48708d('0x1ee7'))[_0x48708d('0x1040')](_0x48708d('0x1337'))[_0x48708d('0xe42')](_0x567809)['ok']('OK')['cancel'](_0x48708d('0x16b8'));_0x12f383[_0x48708d('0x1d4')](_0x2f65ff)[_0x48708d('0x683')](function(){_0x5c0f6a(_0x2d7a9a);},function(){console['log']('CANCEL');});}let _0x325eb5=!![],_0x269786=0x1;_0x58c769['$watch']('vm.query.filter',function(_0x1e0cc0,_0x3affca){const _0x3156f1=_0x28028f;_0x325eb5?_0x260c74(function(){_0x325eb5=![];}):(!_0x3affca&&(_0x269786=_0x520a41[_0x3156f1('0x23a2')][_0x3156f1('0xdf8')]),_0x1e0cc0!==_0x3affca&&(_0x520a41[_0x3156f1('0x23a2')][_0x3156f1('0xdf8')]=0x1),!_0x1e0cc0&&(_0x520a41[_0x3156f1('0x23a2')]['page']=_0x269786),_0x520a41[_0x3156f1('0xf1e')]());});function _0x1be82a(_0x586088){_0x520a41['smsAccounts']=_0x586088||{'count':0x0,'rows':[]};}function _0x513042(){const _0x5664f6=_0x28028f;_0x520a41['query']['offset']=(_0x520a41[_0x5664f6('0x23a2')][_0x5664f6('0xdf8')]-0x1)*_0x520a41['query'][_0x5664f6('0x6f0')],_0x46d07f['hasRole'](_0x5664f6('0x20c2'))?_0x520a41['promise']=_0x1e2932[_0x5664f6('0xa0e')][_0x5664f6('0x1e6e')](_0x520a41['query'],_0x1be82a)[_0x5664f6('0xe53')]:(_0x520a41[_0x5664f6('0x23a2')]['id']=_0x520a41[_0x5664f6('0x2a')]['id'],_0x520a41[_0x5664f6('0x23a2')][_0x5664f6('0x1aa')]='SmsAccounts',_0x520a41[_0x5664f6('0x1883')]=_0x1e2932[_0x5664f6('0x2a')][_0x5664f6('0x241d')](_0x520a41[_0x5664f6('0x23a2')],_0x1be82a)[_0x5664f6('0xe53')]);}function _0x212b7f(_0xa53ae4,_0x4fd8f6){const _0x110eaf=_0x28028f;_0x12f383[_0x110eaf('0x1d4')]({'controller':_0x110eaf('0x60e'),'controllerAs':'vm','templateUrl':_0x30189b,'parent':angular['element'](_0x47b923[_0x110eaf('0x18e5')]),'targetEvent':_0xa53ae4,'clickOutsideToClose':!![],'locals':{'smsAccount':_0x4fd8f6,'smsAccounts':_0x520a41[_0x110eaf('0x197c')][_0x110eaf('0xf5d')],'license':_0x520a41['license'],'setting':_0x520a41[_0x110eaf('0x260a')],'crudPermissions':_0x520a41[_0x110eaf('0x1134')]}});}function _0x5c0f6a(_0x17bf5e){const _0x3440f9=_0x28028f;_0x1e2932['smsAccount'][_0x3440f9('0xd7e')]({'id':_0x17bf5e['id']})['$promise'][_0x3440f9('0x683')](function(){const _0x5c5f69=_0x3440f9;_0x2e3ca0()[_0x5c5f69('0x3ec')](_0x520a41[_0x5c5f69('0x197c')]['rows'],{'id':_0x17bf5e['id']}),_0x520a41[_0x5c5f69('0x197c')]['count']-=0x1,!_0x520a41[_0x5c5f69('0x197c')][_0x5c5f69('0xf5d')][_0x5c5f69('0x1564')]&&_0x520a41[_0x5c5f69('0xf1e')](),_0x4243e9[_0x5c5f69('0x53')]({'title':_0x2e3ca0()[_0x5c5f69('0x1e03')](_0x5c5f69('0x1a7'))+_0x5c5f69('0xbfc'),'msg':_0x17bf5e[_0x5c5f69('0x60a')]?_0x17bf5e[_0x5c5f69('0x60a')]+_0x5c5f69('0x194d'):''});})[_0x3440f9('0x130a')](function(_0x33403a){const _0x18e2c7=_0x3440f9;if(_0x33403a[_0x18e2c7('0x5a5')]&&_0x33403a[_0x18e2c7('0x5a5')][_0x18e2c7('0x17f')]&&_0x33403a[_0x18e2c7('0x5a5')][_0x18e2c7('0x17f')][_0x18e2c7('0x1564')]){_0x520a41['errors']=_0x33403a[_0x18e2c7('0x5a5')][_0x18e2c7('0x17f')]||[{'message':_0x33403a[_0x18e2c7('0x1ff0')](),'type':'SYSTEM:DELETEsmsAccount'}];for(let _0x1cabdb=0x0;_0x1cabdb<_0x33403a[_0x18e2c7('0x5a5')][_0x18e2c7('0x17f')][_0x18e2c7('0x1564')];_0x1cabdb++){_0x4243e9[_0x18e2c7('0x52a')]({'title':_0x33403a['data'][_0x18e2c7('0x17f')][_0x1cabdb]['type'],'msg':_0x33403a[_0x18e2c7('0x5a5')]['errors'][_0x1cabdb][_0x18e2c7('0x8c2')]});}}else _0x4243e9['error']({'title':_0x33403a[_0x18e2c7('0x13ee')]?_0x18e2c7('0x2168')+_0x33403a[_0x18e2c7('0x13ee')]+'\x20-\x20'+_0x33403a[_0x18e2c7('0x24a9')]:_0x18e2c7('0x2452'),'msg':_0x33403a[_0x18e2c7('0x5a5')]?JSON[_0x18e2c7('0x258a')](_0x33403a['data'][_0x18e2c7('0x8c2')]):_0x33403a[_0x18e2c7('0x8c2')]||_0x33403a['toString']()});});}function _0x27cb12(){const _0x8f9960=_0x28028f,_0x3c6a78=angular[_0x8f9960('0x1a86')](_0x520a41[_0x8f9960('0x12f8')]);return _0x520a41[_0x8f9960('0x12f8')]=[],_0x3c6a78;}function _0x4afd21(_0x39b113){const _0x3a5ea1=_0x28028f,_0x66c631=_0x12f383[_0x3a5ea1('0x1c6f')]()[_0x3a5ea1('0xf28')](_0x3a5ea1('0xd20'))[_0x3a5ea1('0x26e3')](_0x3a5ea1('0xed5')+_0x520a41['selectedSmsAccounts'][_0x3a5ea1('0x1564')]+_0x3a5ea1('0x93c')+_0x3a5ea1('0x1ee7'))[_0x3a5ea1('0x1040')](_0x3a5ea1('0x1c1d'))[_0x3a5ea1('0xe42')](_0x39b113)['ok']('OK')[_0x3a5ea1('0x19fb')]('CANCEL');_0x12f383['show'](_0x66c631)[_0x3a5ea1('0x683')](function(){const _0x378cb4=_0x3a5ea1;_0x520a41[_0x378cb4('0x12f8')][_0x378cb4('0x1299')](function(_0x3497ac){_0x5c0f6a(_0x3497ac);}),_0x520a41[_0x378cb4('0x12f8')]=[];});}function _0x292fc7(){const _0x1a8b48=_0x28028f;_0x520a41[_0x1a8b48('0x12f8')]=[];}function _0x4f4aa3(){const _0x12b386=_0x28028f;_0x520a41[_0x12b386('0x12f8')]=_0x520a41[_0x12b386('0x197c')]['rows'];}}const _0x549023=_0x1d1df1;_0x47c9b6[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0xdf3'),_0x189033('0x193f'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting','crudPermissions'];function _0x47c9b6(_0x379e7c,_0x1fff9c,_0x3b4a62,_0x28044c,_0x470d87,_0x4f749f,_0x1638da,_0xf5942f,_0x16a69d,_0x456423,_0x1ee7e7,_0x4519d6,_0x58577a,_0x2cde69){const _0x241c1c=_0x189033,_0x587c40=this;_0x587c40['currentUser']=_0x1ee7e7['getCurrentUser'](),_0x587c40['errors']=[],_0x587c40[_0x241c1c('0x260a')]=_0x58577a,_0x587c40['license']=_0x4519d6,_0x587c40['crudPermissions']=_0x2cde69,_0x587c40[_0x241c1c('0x258d')]={},_0x587c40['passwordPattern']=_0x587c40[_0x241c1c('0x260a')]&&_0x587c40['setting'][_0x241c1c('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x587c40[_0x241c1c('0xf28')]='SMS.EDIT_SMSQUEUE',_0x587c40[_0x241c1c('0x193f')]=angular[_0x241c1c('0x1a86')](_0x16a69d),_0x587c40[_0x241c1c('0xdf3')]=_0xf5942f,_0x587c40['newSmsQueue']=![];!_0x587c40[_0x241c1c('0x193f')]&&(_0x587c40[_0x241c1c('0x193f')]={'strategy':'beepall','timeout':0xa},_0x587c40[_0x241c1c('0xf28')]=_0x241c1c('0x119d'),_0x587c40[_0x241c1c('0x872')]=!![]);_0x587c40[_0x241c1c('0x1b8')]=_0xfccd4a,_0x587c40[_0x241c1c('0x63e')]=_0x260926,_0x587c40[_0x241c1c('0x69e')]=_0xd11f2,_0x587c40[_0x241c1c('0x16b3')]=_0x837811,_0x587c40['closeDialog']=_0x3be045;function _0xfccd4a(){const _0xacdc92=_0x241c1c;_0x587c40[_0xacdc92('0x17f')]=[],_0x456423[_0xacdc92('0x193f')]['save'](_0x587c40[_0xacdc92('0x193f')])[_0xacdc92('0xe53')][_0xacdc92('0x683')](function(_0x9f8db6){const _0x4399ab=_0xacdc92;_0x587c40[_0x4399ab('0xdf3')][_0x4399ab('0x1167')](_0x9f8db6['toJSON']()),_0x1638da[_0x4399ab('0x53')]({'title':_0x4399ab('0xdd5'),'msg':_0x587c40[_0x4399ab('0x193f')][_0x4399ab('0x60a')]?_0x587c40[_0x4399ab('0x193f')][_0x4399ab('0x60a')]+'\x20has\x20been\x20created!':''}),_0x3be045(_0x9f8db6);})['catch'](function(_0x50b452){const _0x395dab=_0xacdc92;if(_0x50b452[_0x395dab('0x5a5')]&&_0x50b452['data']['errors']&&_0x50b452[_0x395dab('0x5a5')]['errors'][_0x395dab('0x1564')]){_0x587c40[_0x395dab('0x17f')]=_0x50b452['data'][_0x395dab('0x17f')]||[{'message':_0x50b452[_0x395dab('0x1ff0')](),'type':'api.smsQueue.save'}];for(let _0x11bc8e=0x0;_0x11bc8e<_0x50b452[_0x395dab('0x5a5')]['errors'][_0x395dab('0x1564')];_0x11bc8e+=0x1){_0x1638da[_0x395dab('0x52a')]({'title':_0x50b452[_0x395dab('0x5a5')][_0x395dab('0x17f')][_0x11bc8e]['type'],'msg':_0x50b452['data']['errors'][_0x11bc8e][_0x395dab('0x8c2')]});}}else _0x1638da[_0x395dab('0x52a')]({'title':_0x50b452[_0x395dab('0x13ee')]?'API:'+_0x50b452['status']+'\x20-\x20'+_0x50b452['statusText']:'api.smsQueue.save','msg':_0x50b452[_0x395dab('0x5a5')]?JSON['stringify'](_0x50b452[_0x395dab('0x5a5')][_0x395dab('0x8c2')]):_0x50b452[_0x395dab('0x1ff0')]()});});}function _0x260926(){const _0x29f63c=_0x241c1c;_0x587c40[_0x29f63c('0x17f')]=[],_0x456423['smsQueue']['update']({'id':_0x587c40['smsQueue']['id']},_0x587c40[_0x29f63c('0x193f')])[_0x29f63c('0xe53')][_0x29f63c('0x683')](function(_0x3d00e9){const _0x594bf4=_0x29f63c,_0x43af52=_0x2e3ca0()[_0x594bf4('0x1c07')](_0x587c40[_0x594bf4('0xdf3')],{'id':_0x3d00e9['id']});_0x43af52&&_0x2e3ca0()[_0x594bf4('0xf22')](_0x43af52,_0x2e3ca0()[_0x594bf4('0x24d0')](_0x3d00e9[_0x594bf4('0x24e1')](),_0x2e3ca0()['keys'](_0x43af52))),_0x1638da['success']({'title':_0x594bf4('0x11e4'),'msg':_0x587c40[_0x594bf4('0x193f')][_0x594bf4('0x60a')]?_0x587c40[_0x594bf4('0x193f')][_0x594bf4('0x60a')]+_0x594bf4('0xf59'):''}),_0x3be045(_0x3d00e9);})[_0x29f63c('0x130a')](function(_0x5357ac){const _0x5a9605=_0x29f63c;if(_0x5357ac[_0x5a9605('0x5a5')]&&_0x5357ac[_0x5a9605('0x5a5')][_0x5a9605('0x17f')]&&_0x5357ac[_0x5a9605('0x5a5')][_0x5a9605('0x17f')][_0x5a9605('0x1564')]){_0x587c40[_0x5a9605('0x17f')]=_0x5357ac['data'][_0x5a9605('0x17f')]||[{'message':_0x5357ac[_0x5a9605('0x1ff0')](),'type':_0x5a9605('0xeff')}];for(let _0x16612e=0x0;_0x16612e<_0x5357ac[_0x5a9605('0x5a5')]['errors'][_0x5a9605('0x1564')];_0x16612e++){_0x1638da[_0x5a9605('0x52a')]({'title':_0x5357ac['data'][_0x5a9605('0x17f')][_0x16612e]['type'],'msg':_0x5357ac['data']['errors'][_0x16612e][_0x5a9605('0x8c2')]});}}else _0x1638da['error']({'title':_0x5357ac['status']?_0x5a9605('0x2168')+_0x5357ac[_0x5a9605('0x13ee')]+_0x5a9605('0xbf6')+_0x5357ac['statusText']:_0x5a9605('0xeff'),'msg':_0x5357ac['data']?JSON[_0x5a9605('0x258a')](_0x5357ac[_0x5a9605('0x5a5')][_0x5a9605('0x8c2')]):_0x5357ac['toString']()});});}function _0xd11f2(_0x2fa8e9){const _0x1927bb=_0x241c1c;_0x587c40[_0x1927bb('0x17f')]=[];const _0x2711d7=_0x28044c[_0x1927bb('0x1c6f')]()[_0x1927bb('0xf28')](_0x1927bb('0x4d'))[_0x1927bb('0xa6a')](_0x1927bb('0x1270'))[_0x1927bb('0x1040')](_0x1927bb('0x681'))['ok'](_0x1927bb('0x2307'))[_0x1927bb('0x19fb')]('Cancel')[_0x1927bb('0xe42')](_0x2fa8e9);_0x28044c[_0x1927bb('0x1d4')](_0x2711d7)[_0x1927bb('0x683')](function(){const _0x3f980f=_0x1927bb;_0x456423[_0x3f980f('0x193f')][_0x3f980f('0xd7e')]({'id':_0x587c40[_0x3f980f('0x193f')]['id']})[_0x3f980f('0xe53')][_0x3f980f('0x683')](function(){const _0xd81ea7=_0x3f980f;_0x2e3ca0()[_0xd81ea7('0x3ec')](_0x587c40[_0xd81ea7('0xdf3')],{'id':_0x587c40[_0xd81ea7('0x193f')]['id']}),_0x1638da[_0xd81ea7('0x53')]({'title':_0xd81ea7('0x230b'),'msg':(_0x587c40[_0xd81ea7('0x193f')][_0xd81ea7('0x60a')]||'smsQueue')+'\x20has\x20been\x20deleted!'}),_0x3be045(_0x587c40[_0xd81ea7('0x193f')]);})['catch'](function(_0x4f9bd6){const _0x49a7ea=_0x3f980f;if(_0x4f9bd6[_0x49a7ea('0x5a5')]&&_0x4f9bd6[_0x49a7ea('0x5a5')]['errors']&&_0x4f9bd6[_0x49a7ea('0x5a5')][_0x49a7ea('0x17f')][_0x49a7ea('0x1564')]){_0x587c40[_0x49a7ea('0x17f')]=_0x4f9bd6[_0x49a7ea('0x5a5')][_0x49a7ea('0x17f')]||[{'message':_0x4f9bd6[_0x49a7ea('0x1ff0')](),'type':_0x49a7ea('0x14cd')}];for(let _0x476b14=0x0;_0x476b14<_0x4f9bd6[_0x49a7ea('0x5a5')][_0x49a7ea('0x17f')]['length'];_0x476b14++){_0x1638da['error']({'title':_0x4f9bd6['data'][_0x49a7ea('0x17f')][_0x476b14]['type'],'msg':_0x4f9bd6[_0x49a7ea('0x5a5')][_0x49a7ea('0x17f')][_0x476b14][_0x49a7ea('0x8c2')]});}}else _0x1638da[_0x49a7ea('0x52a')]({'title':_0x4f9bd6['status']?'API:'+_0x4f9bd6[_0x49a7ea('0x13ee')]+_0x49a7ea('0xbf6')+_0x4f9bd6[_0x49a7ea('0x24a9')]:_0x49a7ea('0x14cd'),'msg':_0x4f9bd6[_0x49a7ea('0x5a5')]?JSON['stringify'](_0x4f9bd6[_0x49a7ea('0x5a5')][_0x49a7ea('0x8c2')]):_0x4f9bd6[_0x49a7ea('0x8c2')]||_0x4f9bd6[_0x49a7ea('0x1ff0')]()});});},function(){});}function _0x837811(_0xdf4cbb){return _0xdf4cbb===null?undefined:new Date(_0xdf4cbb);}function _0x3be045(_0x3282dc){_0x28044c['hide'](_0x3282dc);}}const _0x48b3f0=_0x47c9b6;_0x22b89c[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x193f'),_0x189033('0xdf3'),_0x189033('0x2c9'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x22b89c(_0x4073f2,_0x672621,_0x27a39a,_0x2e50b4,_0x333277,_0x42a59a,_0x5d4735,_0x43d76d,_0x363aa0,_0xa4f0dd){const _0x19c6bd=_0x189033,_0x5e997a=this;_0x5e997a['currentUser']=_0x363aa0[_0x19c6bd('0x20b2')](),_0x5e997a['smsQueue']=_0x333277,_0x5e997a[_0x19c6bd('0x1134')]=_0xa4f0dd,_0x5e997a[_0x19c6bd('0x2c9')]=_0x5d4735,_0x5e997a[_0x19c6bd('0x1996')]=[],_0x5e997a[_0x19c6bd('0x1c47')]=[],_0x5e997a[_0x19c6bd('0x1378')]=[],_0x5e997a[_0x19c6bd('0x125e')]=[],_0x5e997a[_0x19c6bd('0x23a7')]=[],_0x5e997a[_0x19c6bd('0x2106')]=![],_0x5e997a[_0x19c6bd('0x1dd2')]=_0x5ece5f,_0x5e997a[_0x19c6bd('0xa5f')]=_0x2d14f3,_0x5e997a[_0x19c6bd('0xf82')]=_0xec9793,_0x5e997a['dualMultiselectOptions']={'readOnly':!_0x5e997a['crudPermissions'][_0x19c6bd('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x19c6bd('0x60a'),'line1':_0x19c6bd('0x11bc'),'line2':[_0x19c6bd('0x60a'),_0x19c6bd('0x1d43')],'line3':'','labelAll':_0x43d76d[_0x19c6bd('0x2728')](_0x19c6bd('0x2298')),'labelSelected':_0x43d76d[_0x19c6bd('0x2728')](_0x19c6bd('0x1cf6')),'transferCallback':function(){const _0x23dc4c=_0x19c6bd,_0x2c6c03=_0x2e3ca0()[_0x23dc4c('0x25cb')](_0x5e997a[_0x23dc4c('0x23a7')],_0x5e997a[_0x23dc4c('0x1378')],'id');_0x5e997a[_0x23dc4c('0x2106')]=_0x2e3ca0()[_0x23dc4c('0x173f')](_0x2c6c03)?![]:!![];}};function _0x5ece5f(){const _0x211f9a=_0x19c6bd;return _0x363aa0[_0x211f9a('0xca1')](_0x211f9a('0x20c2'))?_0x5251e9()['catch'](function(_0x584bc0){const _0x178e10=_0x211f9a;_0x27a39a['error']({'title':_0x584bc0[_0x178e10('0x13ee')]?_0x178e10('0x2168')+_0x584bc0[_0x178e10('0x13ee')]+_0x178e10('0xbf6')+_0x584bc0[_0x178e10('0x24a9')]:_0x178e10('0x144f'),'msg':_0x584bc0[_0x178e10('0x13ee')]?JSON[_0x178e10('0x258a')](_0x584bc0['data']):_0x584bc0[_0x178e10('0x1ff0')]()});}):_0x2e16a0()[_0x211f9a('0x683')](function(_0x3282e2){const _0x14da1e=_0x211f9a;return _0x5e997a[_0x14da1e('0x1aa')]=_0x3282e2,_0x5251e9();})[_0x211f9a('0x130a')](function(_0x4078a1){const _0x23c879=_0x211f9a;_0x27a39a[_0x23c879('0x52a')]({'title':_0x4078a1[_0x23c879('0x13ee')]?_0x23c879('0x2168')+_0x4078a1[_0x23c879('0x13ee')]+_0x23c879('0xbf6')+_0x4078a1['statusText']:_0x23c879('0x144f'),'msg':_0x4078a1[_0x23c879('0x13ee')]?JSON['stringify'](_0x4078a1['data']):_0x4078a1['toString']()});});}function _0x2e16a0(){return _0x672621(function(_0x153b1e,_0x303085){const _0x44b832=a0_0x4e0a;_0x2e50b4[_0x44b832('0x22df')][_0x44b832('0x1e6e')]({'userProfileId':_0x5e997a[_0x44b832('0x11ed')]['userProfileId'],'name':_0x44b832('0x1bc0')})['$promise']['then'](function(_0x5064ff){const _0x39282=_0x44b832,_0x48b512=_0x5064ff&&_0x5064ff['rows']?_0x5064ff[_0x39282('0xf5d')][0x0]:null;_0x153b1e(_0x48b512);})[_0x44b832('0x130a')](function(_0xba2a0a){_0x303085(_0xba2a0a);});});}function _0x5251e9(){return _0x672621(function(_0x5b8b87,_0x653dc0){const _0x3ddcfa=a0_0x4e0a;return _0x10c1de()[_0x3ddcfa('0x683')](function(_0x2cbc9a){const _0x58dabb=_0x3ddcfa;return _0x5e997a[_0x58dabb('0x1996')]=_0x2cbc9a[_0x58dabb('0xf5d')]?_0x2cbc9a[_0x58dabb('0xf5d')]:[],_0x363aa0[_0x58dabb('0xca1')](_0x58dabb('0x20c2'))?_0x2cbc9a:_0x5e997a[_0x58dabb('0x1aa')]?_0x5e997a[_0x58dabb('0x1aa')][_0x58dabb('0x170')]?_0x2cbc9a:_0x4e23e9():null;})['then'](function(_0x2ded6c){const _0x175324=_0x3ddcfa,_0x4cc76d=_0x2ded6c&&_0x2ded6c[_0x175324('0xf5d')]?_0x2ded6c[_0x175324('0xf5d')]:[];return _0x5e997a[_0x175324('0x1c47')]=_0x2e3ca0()[_0x175324('0x386')](_0x4cc76d,function(_0x3723aa){const _0x38ee9c=_0x175324;return _0x2e3ca0()['find'](_0x5e997a['items'],{'id':_0x363aa0[_0x38ee9c('0xca1')](_0x38ee9c('0x20c2'))||_0x5e997a[_0x38ee9c('0x1aa')]['autoAssociation']?_0x3723aa['id']:_0x3723aa[_0x38ee9c('0x832')]});}),_0x5e997a[_0x175324('0x125e')]=angular[_0x175324('0x1a86')](_0x5e997a['allowedItems']),_0x5e997a[_0x175324('0x1996')]['forEach'](function(_0x22dc3a){const _0x244bad=_0x175324,_0x3f5c02=_0x2e3ca0()[_0x244bad('0x1c07')](_0x5e997a[_0x244bad('0x1c47')],{'id':_0x22dc3a['id']});_0x363aa0[_0x244bad('0xca1')](_0x244bad('0x20c2'))?_0x22dc3a[_0x244bad('0x24f4')]=!![]:_0x22dc3a['isValid']=typeof _0x3f5c02!=='undefined'?!![]:![];}),_0x17e8bf();})[_0x3ddcfa('0x683')](function(_0x10866c){const _0x1a9e91=_0x3ddcfa,_0x343564=_0x10866c&&_0x10866c[_0x1a9e91('0xf5d')]?_0x10866c[_0x1a9e91('0xf5d')]:[];_0x5e997a['selectedItems']=_0x2e3ca0()[_0x1a9e91('0x386')](_0x343564,function(_0x13c058){const _0x585ebf=_0x1a9e91,_0x187e47=_0x2e3ca0()[_0x585ebf('0x1c07')](_0x5e997a['items'],{'id':_0x13c058['id']});return _0x187e47[_0x585ebf('0x1e2a')]=_0x13c058['UserSmsQueue']?'penalty\x20'+_0x13c058[_0x585ebf('0xcab')]['penalty']:'',_0x187e47[_0x585ebf('0x1d43')]=typeof _0x13c058[_0x585ebf('0x1d43')]!==_0x585ebf('0x1867')?'<'+_0x13c058[_0x585ebf('0x1d43')]+'>':'',_0x187e47;}),_0x5e997a['startingSelectedItems']=angular[_0x1a9e91('0x1a86')](_0x5e997a[_0x1a9e91('0x1378')]),_0x5e997a[_0x1a9e91('0x169f')][_0x1a9e91('0x1378')]=_0x5e997a[_0x1a9e91('0x1378')],_0x5e997a['dualMultiselectOptions'][_0x1a9e91('0x1996')]=_0x2e3ca0()['differenceBy'](_0x5e997a[_0x1a9e91('0x1c47')],_0x5e997a[_0x1a9e91('0x169f')][_0x1a9e91('0x1378')],'id'),_0x5b8b87();})[_0x3ddcfa('0x130a')](function(_0x594f4b){_0x653dc0(_0x594f4b);});});}function _0x4e23e9(){return _0x672621(function(_0x29cb82,_0x457c52){const _0x4f5e3d=a0_0x4e0a;return _0x2e50b4['userProfileResource'][_0x4f5e3d('0x1e6e')]({'sectionId':_0x5e997a[_0x4f5e3d('0x1aa')]['id'],'nolimit':!![]})[_0x4f5e3d('0xe53')]['then'](function(_0x2cc27a){_0x29cb82(_0x2cc27a);})[_0x4f5e3d('0x130a')](function(_0x35e3d8){_0x457c52(_0x35e3d8);});});}function _0x17e8bf(){return _0x672621(function(_0x40413d,_0x3018cc){const _0x46dfdf=a0_0x4e0a;return _0x2e50b4[_0x46dfdf('0x193f')][_0x46dfdf('0x8e7')]({'id':_0x5e997a[_0x46dfdf('0x193f')]['id'],'fields':_0x46dfdf('0x72b'),'nolimit':!![],'role':_0x46dfdf('0x2327')})['$promise'][_0x46dfdf('0x683')](function(_0x4fa12d){_0x40413d(_0x4fa12d);})['catch'](function(_0x961d2a){_0x3018cc(_0x961d2a);});});}function _0x10c1de(){return _0x672621(function(_0x31e7da,_0x32dd3d){const _0x4013b8=a0_0x4e0a;return _0x2e50b4[_0x4013b8('0xc96')]['get']({'fields':_0x4013b8('0x72b'),'nolimit':!![],'role':'agent'})['$promise']['then'](function(_0x491363){_0x31e7da(_0x491363);})[_0x4013b8('0x130a')](function(_0x39fb08){_0x32dd3d(_0x39fb08);});});}function _0x1afd9(_0x4f81c3){return _0x672621(function(_0x14db87,_0x32a691){const _0x5ea370=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0x4f81c3)?_0x14db87():_0x2e50b4[_0x5ea370('0x193f')][_0x5ea370('0x2179')]({'id':_0x5e997a[_0x5ea370('0x193f')]['id'],'ids':_0x2e3ca0()[_0x5ea370('0x386')](_0x4f81c3,'id')})[_0x5ea370('0xe53')]['then'](function(){_0x14db87();})[_0x5ea370('0x130a')](function(_0x514059){_0x32a691(_0x514059);});});}function _0x873207(_0x8f38c2){return _0x672621(function(_0x2334bb,_0x26fcec){const _0x5a6867=a0_0x4e0a;_0x2e3ca0()[_0x5a6867('0x173f')](_0x8f38c2)?_0x2334bb():_0x2e50b4[_0x5a6867('0x193f')][_0x5a6867('0xf9')]({'id':_0x5e997a['smsQueue']['id'],'ids':_0x2e3ca0()['map'](_0x8f38c2,'id')})[_0x5a6867('0xe53')][_0x5a6867('0x683')](function(){_0x2334bb();})[_0x5a6867('0x130a')](function(_0x367a48){_0x26fcec(_0x367a48);});});}function _0x2d14f3(){const _0x3847ed=_0x19c6bd,_0x5a27b2=_0x2e3ca0()[_0x3847ed('0x461')](_0x5e997a[_0x3847ed('0x23a7')],_0x5e997a[_0x3847ed('0x1378')],'id'),_0xc1039b=_0x2e3ca0()[_0x3847ed('0x461')](_0x5e997a[_0x3847ed('0x1378')],_0x5e997a[_0x3847ed('0x23a7')],'id');return _0x873207(_0x5a27b2)['then'](function(){return _0x1afd9(_0xc1039b);})[_0x3847ed('0x683')](function(){const _0x570f90=_0x3847ed;_0x5e997a['pendingChanges']=![],_0x5e997a[_0x570f90('0x125e')]=angular[_0x570f90('0x1a86')](_0x5e997a[_0x570f90('0x1c47')]),_0x5e997a[_0x570f90('0x23a7')]=angular[_0x570f90('0x1a86')](_0x5e997a['selectedItems']),_0x27a39a[_0x570f90('0x53')]({'title':'SUCCESS','msg':'Agents\x20association\x20has\x20been\x20updated!'});})[_0x3847ed('0x130a')](function(_0x1efc3e){const _0x44a0a4=_0x3847ed;_0x27a39a[_0x44a0a4('0x52a')]({'title':_0x1efc3e[_0x44a0a4('0x13ee')]?_0x44a0a4('0x2168')+_0x1efc3e[_0x44a0a4('0x13ee')]+_0x44a0a4('0xbf6')+_0x1efc3e[_0x44a0a4('0x24a9')]:_0x44a0a4('0x1b71'),'msg':_0x1efc3e[_0x44a0a4('0x13ee')]?JSON[_0x44a0a4('0x258a')](_0x1efc3e[_0x44a0a4('0x5a5')]):_0x1efc3e[_0x44a0a4('0x1ff0')]()});});}function _0xec9793(){const _0x8d6110=_0x19c6bd;_0x4073f2[_0x8d6110('0x1715')]();}}const _0x16ee25=_0x22b89c;_0x21676c[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x193f'),_0x189033('0x1d08'),'Auth',_0x189033('0x1134')];function _0x21676c(_0x3cae2a,_0x1d221c,_0x55d0db,_0x3bddc5,_0x30116c,_0x5b9b17,_0x14d3d2,_0x267ec8){const _0x4b5236=_0x189033,_0x3c3f8b=this;_0x3c3f8b[_0x4b5236('0x11ed')]=_0x14d3d2['getCurrentUser'](),_0x3c3f8b[_0x4b5236('0x193f')]=_0x30116c,_0x3c3f8b[_0x4b5236('0x1134')]=_0x267ec8,_0x3c3f8b[_0x4b5236('0x1996')]=[],_0x3c3f8b['allowedItems']=[],_0x3c3f8b[_0x4b5236('0x1378')]=[],_0x3c3f8b[_0x4b5236('0x125e')]=[],_0x3c3f8b[_0x4b5236('0x23a7')]=[],_0x3c3f8b[_0x4b5236('0x2106')]=![],_0x3c3f8b[_0x4b5236('0x169f')]={'readOnly':!_0x3c3f8b['crudPermissions']['canEdit'],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x4b5236('0x60a'),'line1':_0x4b5236('0x60a'),'line2':'','line3':'','labelAll':_0x5b9b17['instant'](_0x4b5236('0x11d')),'labelSelected':_0x5b9b17['instant']('SMS.SELECTED_TEAMS'),'transferCallback':function(){const _0x226744=_0x4b5236,_0x245498=_0x2e3ca0()[_0x226744('0x25cb')](_0x3c3f8b[_0x226744('0x23a7')],_0x3c3f8b[_0x226744('0x1378')],'id');_0x3c3f8b[_0x226744('0x2106')]=_0x2e3ca0()[_0x226744('0x173f')](_0x245498)?![]:!![];}},_0x3c3f8b[_0x4b5236('0x1dd2')]=_0x305b53,_0x3c3f8b[_0x4b5236('0x1a89')]=_0x231d4f,_0x3c3f8b[_0x4b5236('0xf82')]=_0x1476dd;function _0x305b53(){const _0x2461d6=_0x4b5236;return _0x14d3d2[_0x2461d6('0xca1')]('admin')?_0x4c5e93()['catch'](function(_0x443a5c){const _0x3d533c=_0x2461d6;_0x55d0db[_0x3d533c('0x52a')]({'title':_0x443a5c[_0x3d533c('0x13ee')]?_0x3d533c('0x2168')+_0x443a5c['status']+_0x3d533c('0xbf6')+_0x443a5c['statusText']:_0x3d533c('0x1820'),'msg':_0x443a5c[_0x3d533c('0x13ee')]?JSON[_0x3d533c('0x258a')](_0x443a5c[_0x3d533c('0x5a5')]):_0x443a5c[_0x3d533c('0x1ff0')]()});}):_0x16aac6()[_0x2461d6('0x683')](function(_0x235461){const _0x2fa95d=_0x2461d6;return _0x3c3f8b[_0x2fa95d('0x1aa')]=_0x235461,_0x4c5e93();})['catch'](function(_0x368def){const _0x11c409=_0x2461d6;_0x55d0db[_0x11c409('0x52a')]({'title':_0x368def[_0x11c409('0x13ee')]?_0x11c409('0x2168')+_0x368def[_0x11c409('0x13ee')]+_0x11c409('0xbf6')+_0x368def[_0x11c409('0x24a9')]:_0x11c409('0x1820'),'msg':_0x368def[_0x11c409('0x13ee')]?JSON[_0x11c409('0x258a')](_0x368def[_0x11c409('0x5a5')]):_0x368def[_0x11c409('0x1ff0')]()});});}function _0x16aac6(){return _0x1d221c(function(_0x1d45bc,_0x2704b0){const _0x214a17=a0_0x4e0a;_0x3bddc5[_0x214a17('0x22df')][_0x214a17('0x1e6e')]({'userProfileId':_0x3c3f8b[_0x214a17('0x11ed')][_0x214a17('0x2f')],'name':_0x214a17('0x15bc')})['$promise'][_0x214a17('0x683')](function(_0x135c89){const _0x3e3b93=_0x214a17,_0x50e007=_0x135c89&&_0x135c89[_0x3e3b93('0xf5d')]?_0x135c89[_0x3e3b93('0xf5d')][0x0]:null;_0x1d45bc(_0x50e007);})[_0x214a17('0x130a')](function(_0x573ee6){_0x2704b0(_0x573ee6);});});}function _0x4c5e93(){return _0x1d221c(function(_0x85db45,_0x4eabcb){const _0x11ba17=a0_0x4e0a;return _0x32c160()[_0x11ba17('0x683')](function(_0x3e7d14){const _0x509291=_0x11ba17;return _0x3c3f8b[_0x509291('0x1996')]=_0x3e7d14[_0x509291('0xf5d')]?_0x3e7d14[_0x509291('0xf5d')]:[],_0x14d3d2[_0x509291('0xca1')]('admin')?_0x3e7d14:_0x3c3f8b[_0x509291('0x1aa')]?_0x3c3f8b[_0x509291('0x1aa')][_0x509291('0x170')]?_0x3e7d14:_0x2d1df4():null;})[_0x11ba17('0x683')](function(_0x3666d1){const _0x497d86=_0x11ba17,_0x5030e4=_0x3666d1&&_0x3666d1[_0x497d86('0xf5d')]?_0x3666d1['rows']:[];return _0x3c3f8b['allowedItems']=_0x2e3ca0()[_0x497d86('0x386')](_0x5030e4,function(_0x82be90){const _0x97475e=_0x497d86;return _0x2e3ca0()[_0x97475e('0x1c07')](_0x3c3f8b[_0x97475e('0x1996')],{'id':_0x14d3d2[_0x97475e('0xca1')](_0x97475e('0x20c2'))||_0x3c3f8b[_0x97475e('0x1aa')]['autoAssociation']?_0x82be90['id']:_0x82be90[_0x97475e('0x832')]});}),_0x3c3f8b[_0x497d86('0x1996')][_0x497d86('0x1299')](function(_0x30da89){const _0x5e4a6b=_0x497d86,_0x5ac437=_0x2e3ca0()[_0x5e4a6b('0x1c07')](_0x3c3f8b[_0x5e4a6b('0x1c47')],{'id':_0x30da89['id']});_0x14d3d2[_0x5e4a6b('0xca1')](_0x5e4a6b('0x20c2'))?_0x30da89[_0x5e4a6b('0x24f4')]=!![]:_0x30da89[_0x5e4a6b('0x24f4')]=typeof _0x5ac437!==_0x5e4a6b('0x1867')?!![]:![];}),_0x216554();})[_0x11ba17('0x683')](function(_0x4740f5){const _0x4c6970=_0x11ba17,_0x3fa3be=_0x4740f5&&_0x4740f5['rows']?_0x4740f5['rows']:[];_0x3c3f8b[_0x4c6970('0x1378')]=_0x2e3ca0()['map'](_0x3fa3be,function(_0x451498){const _0x213bbf=_0x4c6970;return _0x2e3ca0()[_0x213bbf('0x1c07')](_0x3c3f8b['items'],{'id':_0x451498['id']});}),_0x3c3f8b['startingSelectedItems']=angular[_0x4c6970('0x1a86')](_0x3c3f8b['selectedItems']),_0x3c3f8b[_0x4c6970('0x169f')]['selectedItems']=_0x3c3f8b[_0x4c6970('0x1378')],_0x3c3f8b[_0x4c6970('0x169f')][_0x4c6970('0x1996')]=_0x2e3ca0()[_0x4c6970('0x461')](_0x3c3f8b[_0x4c6970('0x1c47')],_0x3c3f8b[_0x4c6970('0x169f')][_0x4c6970('0x1378')],'id'),_0x85db45();})[_0x11ba17('0x130a')](function(_0x177e29){_0x4eabcb(_0x177e29);});});}function _0x2d1df4(){return _0x1d221c(function(_0x25b0d3,_0xe5831f){const _0x377cf1=a0_0x4e0a;return _0x3bddc5['userProfileResource']['get']({'sectionId':_0x3c3f8b[_0x377cf1('0x1aa')]['id'],'nolimit':!![]})[_0x377cf1('0xe53')][_0x377cf1('0x683')](function(_0x4a25cc){_0x25b0d3(_0x4a25cc);})[_0x377cf1('0x130a')](function(_0x2c1673){_0xe5831f(_0x2c1673);});});}function _0x216554(){return _0x1d221c(function(_0x3af9e0,_0x43e477){const _0x58a9e3=a0_0x4e0a;return _0x3bddc5[_0x58a9e3('0x193f')][_0x58a9e3('0xf90')]({'id':_0x3c3f8b[_0x58a9e3('0x193f')]['id'],'fields':_0x58a9e3('0xa10'),'nolimit':!![]})[_0x58a9e3('0xe53')][_0x58a9e3('0x683')](function(_0x1fe4e6){_0x3af9e0(_0x1fe4e6);})[_0x58a9e3('0x130a')](function(_0x48209a){_0x43e477(_0x48209a);});});}function _0x32c160(){return _0x1d221c(function(_0x380c70,_0x4fde90){const _0xf46123=a0_0x4e0a;return _0x3bddc5[_0xf46123('0xd88')]['get']({'fields':'id,name','nolimit':!![]})[_0xf46123('0xe53')][_0xf46123('0x683')](function(_0x31f22a){_0x380c70(_0x31f22a);})[_0xf46123('0x130a')](function(_0x2a8592){_0x4fde90(_0x2a8592);});});}function _0x3b1cc0(_0x25ed45){return _0x1d221c(function(_0x15b87f,_0x504458){const _0x5b03ef=a0_0x4e0a;_0x2e3ca0()[_0x5b03ef('0x173f')](_0x25ed45)?_0x15b87f():_0x3bddc5[_0x5b03ef('0x193f')][_0x5b03ef('0x1558')]({'id':_0x3c3f8b[_0x5b03ef('0x193f')]['id'],'ids':_0x2e3ca0()[_0x5b03ef('0x386')](_0x25ed45,'id')})[_0x5b03ef('0xe53')]['then'](function(){_0x15b87f();})[_0x5b03ef('0x130a')](function(_0x55e268){_0x504458(_0x55e268);});});}function _0x9c2f4a(_0x5a10c4){return _0x1d221c(function(_0x348278,_0x44cd9c){const _0x316d49=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0x5a10c4)?_0x348278():_0x3bddc5[_0x316d49('0x193f')]['removeTeams']({'id':_0x3c3f8b[_0x316d49('0x193f')]['id'],'ids':_0x2e3ca0()[_0x316d49('0x386')](_0x5a10c4,'id')})['$promise']['then'](function(){_0x348278();})['catch'](function(_0x5bc714){_0x44cd9c(_0x5bc714);});});}function _0x231d4f(){const _0x4740f0=_0x4b5236,_0x5ad3bb=_0x2e3ca0()[_0x4740f0('0x461')](_0x3c3f8b[_0x4740f0('0x23a7')],_0x3c3f8b[_0x4740f0('0x1378')],'id'),_0x1fe972=_0x2e3ca0()[_0x4740f0('0x461')](_0x3c3f8b[_0x4740f0('0x1378')],_0x3c3f8b[_0x4740f0('0x23a7')],'id');return _0x9c2f4a(_0x5ad3bb)['then'](function(){return _0x3b1cc0(_0x1fe972);})[_0x4740f0('0x683')](function(){const _0x5bb295=_0x4740f0;_0x3c3f8b[_0x5bb295('0x2106')]=![],_0x3c3f8b[_0x5bb295('0x125e')]=angular[_0x5bb295('0x1a86')](_0x3c3f8b[_0x5bb295('0x1c47')]),_0x3c3f8b[_0x5bb295('0x23a7')]=angular[_0x5bb295('0x1a86')](_0x3c3f8b[_0x5bb295('0x1378')]),_0x55d0db['success']({'title':_0x5bb295('0xd28'),'msg':_0x5bb295('0x476')});})[_0x4740f0('0x130a')](function(_0xa32eaa){const _0x585833=_0x4740f0;_0x55d0db[_0x585833('0x52a')]({'title':_0xa32eaa['status']?_0x585833('0x2168')+_0xa32eaa[_0x585833('0x13ee')]+_0x585833('0xbf6')+_0xa32eaa[_0x585833('0x24a9')]:_0x585833('0x1b71'),'msg':_0xa32eaa[_0x585833('0x13ee')]?JSON[_0x585833('0x258a')](_0xa32eaa['data']):_0xa32eaa[_0x585833('0x1ff0')]()});});}function _0x1476dd(){const _0x2d213e=_0x4b5236;_0x3cae2a[_0x2d213e('0x1715')]();}}const _0x5af27c=_0x21676c,_0x2c45ff=_0x180212['p']+_0x189033('0xca2');_0x1063a7[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$document','$translate',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x193f'),'userProfileSection'];function _0x1063a7(_0x2a2f06,_0x4b9d73,_0x31f4f3,_0x3e725a,_0x3f8684,_0x2464bd,_0x5a4cc1,_0xd19b0a,_0x1fc3da,_0x2c639f,_0x4a0c84,_0x151607){const _0x44fa38=_0x189033,_0x56ed90=this;_0x56ed90['currentUser']=_0x2c639f['getCurrentUser'](),_0x56ed90[_0x44fa38('0xace')]=_0x2464bd,_0x56ed90[_0x44fa38('0x260a')]=_0x5a4cc1,_0x56ed90[_0x44fa38('0x19b2')]=_0x56ed90[_0x44fa38('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x56ed90[_0x44fa38('0x1224')]=_0x4b9d73[_0x44fa38('0x173e')]()+_0x44fa38('0x20de')+_0x4b9d73[_0x44fa38('0x19ac')](),_0x56ed90[_0x44fa38('0x193f')]=_0x4a0c84||_0x2a2f06[_0x44fa38('0x7f2')]['smsQueue']||{},_0x56ed90[_0x44fa38('0x22df')]=_0x151607&&_0x151607[_0x44fa38('0x50d')]==0x1?_0x151607[_0x44fa38('0xf5d')][0x0]:null,_0x56ed90['crudPermissions']=_0x2c639f[_0x44fa38('0x142a')](_0x56ed90[_0x44fa38('0x22df')]?_0x56ed90[_0x44fa38('0x22df')][_0x44fa38('0x1134')]:null),_0x56ed90[_0x44fa38('0x258d')]={},_0x56ed90[_0x44fa38('0x517')]=_0x2a2f06[_0x44fa38('0x7f2')][_0x44fa38('0x1904')]||0x0,_0x56ed90['teamadddialog']=_0x454318,_0x56ed90[_0x44fa38('0x2814')]=_0x381297,_0x56ed90[_0x44fa38('0x2430')]=_0x1fc3da[_0x44fa38('0x2289')],_0x56ed90[_0x44fa38('0x218b')]=_0x2bee8f,_0x56ed90[_0x44fa38('0x63e')]=_0x4fc88c;function _0x454318(_0x4457f0,_0x3b4548){const _0x20ea95=_0x44fa38;_0x31f4f3[_0x20ea95('0x1d4')]({'controller':_0x20ea95('0xdd'),'controllerAs':'vm','templateUrl':_0x2c45ff,'parent':angular[_0x20ea95('0x1fcc')](_0x3e725a[_0x20ea95('0x18e5')]),'targetEvent':_0x3b4548,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x4457f0,'smsQueues':_0x56ed90['smsQueues']?_0x56ed90[_0x20ea95('0xdf3')][_0x20ea95('0xf5d')]:[],'crudPermissions':_0x56ed90[_0x20ea95('0x1134')]}});}function _0x381297(_0x482d92,_0x3edc1c){const _0x702d43=_0x44fa38;_0x31f4f3[_0x702d43('0x1d4')]({'controller':_0x702d43('0x15c'),'controllerAs':'vm','templateUrl':_0x547d4d,'parent':angular[_0x702d43('0x1fcc')](_0x3e725a[_0x702d43('0x18e5')]),'targetEvent':_0x3edc1c,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x482d92,'smsQueues':_0x56ed90[_0x702d43('0xdf3')]?_0x56ed90['smsQueues'][_0x702d43('0xf5d')]:[],'crudPermissions':_0x56ed90[_0x702d43('0x1134')],'realtime':![]}});}function _0x2bee8f(){const _0x4b049a=_0x44fa38;_0x2a2f06['go'](_0x4b049a('0x2571'),{},{'reload':_0x4b049a('0x2571')});}function _0x4fc88c(){const _0x2f9ee3=_0x44fa38;_0xd19b0a['smsQueue']['update']({'id':_0x56ed90[_0x2f9ee3('0x193f')]['id']},_0x56ed90[_0x2f9ee3('0x193f')])['$promise'][_0x2f9ee3('0x683')](function(){const _0x55f6e7=_0x2f9ee3;_0x1fc3da['success']({'title':_0x55f6e7('0x1fb5'),'msg':_0x56ed90[_0x55f6e7('0x193f')][_0x55f6e7('0x60a')]?_0x56ed90[_0x55f6e7('0x193f')][_0x55f6e7('0x60a')]+_0x55f6e7('0x96c'):''});})[_0x2f9ee3('0x130a')](function(_0xaa1628){const _0x2854f7=_0x2f9ee3;_0x1fc3da[_0x2854f7('0x52a')]({'title':_0xaa1628['status']?_0x2854f7('0x2168')+_0xaa1628[_0x2854f7('0x13ee')]+_0x2854f7('0xbf6')+_0xaa1628[_0x2854f7('0x24a9')]:'SYSTEM:GETsmsQueue','msg':_0xaa1628[_0x2854f7('0x5a5')]?JSON['stringify'](_0xaa1628[_0x2854f7('0x5a5')]):_0xaa1628['toString']()});});}}const _0xd1b530=_0x1063a7;_0x1d150c[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0xdf3'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),'msUtils',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x1d150c(_0x50d6d6,_0x1f0c8b,_0x570faa,_0x5997a6,_0x40d425,_0x34d8a9,_0x2b63e7,_0x3f0520,_0x24931c,_0x39b951,_0x528016,_0x35d852,_0x2fc679,_0xf51897,_0xb0e9bd,_0x4a996b,_0x319abd){const _0x5d4d92=_0x189033,_0x70daf4=this;_0x70daf4['license']=_0x4a996b,_0x70daf4[_0x5d4d92('0x260a')]=_0x319abd,_0x70daf4[_0x5d4d92('0x11ed')]=_0xb0e9bd[_0x5d4d92('0x20b2')](),_0x70daf4['smsQueues']=_0x24931c||{'count':0x0,'rows':[]},_0x70daf4[_0x5d4d92('0x2a')]=_0x39b951,_0x70daf4[_0x5d4d92('0x22df')]=_0x528016&&_0x528016['count']==0x1?_0x528016['rows'][0x0]:null,_0x70daf4[_0x5d4d92('0x1134')]=_0xb0e9bd[_0x5d4d92('0x142a')](_0x70daf4[_0x5d4d92('0x22df')]?_0x70daf4['userProfileSection']['crudPermissions']:null),_0x70daf4[_0x5d4d92('0x5c4')]=_0x5d4d92('0xdf3'),_0x70daf4[_0x5d4d92('0x247')]='',_0x70daf4[_0x5d4d92('0x1ce2')]=null,_0x70daf4[_0x5d4d92('0x855')]=[],_0x70daf4[_0x5d4d92('0x23a2')]={'fields':_0x5d4d92('0x1b67'),'sort':'-updatedAt','channel':_0x5d4d92('0x1285'),'limit':0xa,'page':0x1},_0x70daf4[_0x5d4d92('0x21de')]=_0x2e3ca0()['keyBy']([{'option':_0x5d4d92('0x953'),'value':_0x5d4d92('0x185b')},{'option':_0x5d4d92('0x15cd'),'value':_0x5d4d92('0x4ab')}],function(_0x31c1d5){const _0x195a85=_0x5d4d92;return _0x2e3ca0()['replace'](_0x31c1d5[_0x195a85('0x1c6b')],new RegExp('\x27','g'),'');}),_0x70daf4[_0x5d4d92('0xc63')]=_0x44620b,_0x70daf4[_0x5d4d92('0xe0e')]=_0x508c21,_0x70daf4[_0x5d4d92('0x2814')]=_0x40a44d,_0x70daf4[_0x5d4d92('0x194f')]=_0x27201c,_0x70daf4[_0x5d4d92('0x213c')]=_0x43e3aa,_0x70daf4['success']=_0x22a9a4,_0x70daf4[_0x5d4d92('0x286f')]=_0x4cded0,_0x70daf4['createOrEditSmsQueue']=_0x3ad3b2,_0x70daf4[_0x5d4d92('0x69e')]=_0x4088ef,_0x70daf4['exportSelectedSmsQueues']=_0x1d3594,_0x70daf4[_0x5d4d92('0xd50')]=_0x23d8a1,_0x70daf4[_0x5d4d92('0x1943')]=_0x1ea795,_0x70daf4[_0x5d4d92('0x23c2')]=_0x2191f3;function _0x44620b(_0x23b49e){const _0x12cac8=_0x5d4d92;_0x570faa['go'](_0x12cac8('0x1b6d'),{'id':_0x23b49e['id'],'smsQueue':_0x23b49e,'crudPermissions':_0x70daf4[_0x12cac8('0x1134')]});}function _0x508c21(_0x85b757,_0x4c595c){const _0x2eae73=_0x5d4d92;_0x40d425[_0x2eae73('0x1d4')]({'controller':_0x2eae73('0xdd'),'controllerAs':'vm','templateUrl':_0x2c45ff,'parent':angular['element'](_0x34d8a9[_0x2eae73('0x18e5')]),'targetEvent':_0x4c595c,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x85b757,'smsQueues':_0x70daf4[_0x2eae73('0xdf3')]?_0x70daf4[_0x2eae73('0xdf3')][_0x2eae73('0xf5d')]:[],'crudPermissions':_0x70daf4[_0x2eae73('0x1134')]}});}function _0x40a44d(_0x55f38d,_0x5a19e7){const _0x19e58a=_0x5d4d92;_0x40d425[_0x19e58a('0x1d4')]({'controller':_0x19e58a('0x15c'),'controllerAs':'vm','templateUrl':_0x547d4d,'parent':angular[_0x19e58a('0x1fcc')](_0x34d8a9['body']),'targetEvent':_0x5a19e7,'clickOutsideToClose':!![],'locals':{'smsQueue':_0x55f38d,'smsQueues':_0x70daf4[_0x19e58a('0xdf3')]?_0x70daf4[_0x19e58a('0xdf3')][_0x19e58a('0xf5d')]:[],'crudPermissions':_0x70daf4[_0x19e58a('0x1134')],'realtime':![]}});}function _0x27201c(_0x4552bd,_0x6f3778){const _0x2ad69d=_0x5d4d92,_0x4b6106=_0x40d425['confirm']()[_0x2ad69d('0xf28')](_0x2ad69d('0x1b01')+_0x2e3ca0()[_0x2ad69d('0x1e03')](_0x2ad69d('0x193f'))+'?')[_0x2ad69d('0x26e3')](_0x2ad69d('0xed5')+(_0x4552bd['name']||'smsQueue')+''+_0x2ad69d('0x1ee7'))[_0x2ad69d('0x1040')]('delete\x20smsQueue')[_0x2ad69d('0xe42')](_0x6f3778)['ok']('OK')[_0x2ad69d('0x19fb')](_0x2ad69d('0x16b8'));_0x40d425['show'](_0x4b6106)['then'](function(){_0x4088ef(_0x4552bd);},function(){const _0x5e1417=_0x2ad69d;console[_0x5e1417('0x1b2b')](_0x5e1417('0x16b8'));});}function _0x43e3aa(){const _0x4a2dd8=_0x5d4d92;if(_0xb0e9bd[_0x4a2dd8('0xca1')](_0x4a2dd8('0x20c2')))_0x570faa['go']('app.sms.realtime.queues',{});else return _0x35d852[_0x4a2dd8('0x22df')][_0x4a2dd8('0x1e6e')]({'userProfileId':_0xb0e9bd['getCurrentUser']()['userProfileId'],'sectionId':0x2c6})[_0x4a2dd8('0xe53')]['then'](function(_0x2eec13){const _0x44bd0d=_0x4a2dd8,_0x5ba073=_0x2eec13&&_0x2eec13['rows']?_0x2eec13[_0x44bd0d('0xf5d')][0x0]:null;_0x5ba073&&_0x5ba073[_0x44bd0d('0x1333')]?_0x570faa['go'](_0x44bd0d('0x1'),{}):_0xf51897[_0x44bd0d('0x2289')]({'title':_0x3f0520[_0x44bd0d('0x2728')](_0x44bd0d('0x213e')),'msg':_0x3f0520[_0x44bd0d('0x2728')](_0x44bd0d('0xdba'))});})[_0x4a2dd8('0x130a')](function(_0x413590){const _0x21ec5c=_0x4a2dd8;_0xf51897[_0x21ec5c('0x52a')]({'title':_0x413590[_0x21ec5c('0x13ee')]?'API:'+_0x413590['status']+'\x20-\x20'+_0x413590['statusText']:_0x21ec5c('0xf2a'),'msg':_0x413590['status']?JSON['stringify'](_0x413590[_0x21ec5c('0x5a5')]):_0x413590[_0x21ec5c('0x1ff0')]()});});}let _0x3ac984=!![],_0x6628e1=0x1;_0x50d6d6[_0x5d4d92('0x186d')](_0x5d4d92('0x1e1d'),function(_0x41f337,_0x4c5efb){const _0x335435=_0x5d4d92;_0x3ac984?_0x2b63e7(function(){_0x3ac984=![];}):(!_0x4c5efb&&(_0x6628e1=_0x70daf4['query']['page']),_0x41f337!==_0x4c5efb&&(_0x70daf4[_0x335435('0x23a2')][_0x335435('0xdf8')]=0x1),!_0x41f337&&(_0x70daf4[_0x335435('0x23a2')]['page']=_0x6628e1),_0x70daf4['getSmsQueues']());});function _0x22a9a4(_0x38ca76){_0x70daf4['smsQueues']=_0x38ca76||{'count':0x0,'rows':[]};}function _0x4cded0(){const _0x152f57=_0x5d4d92;_0x70daf4[_0x152f57('0x23a2')][_0x152f57('0x1cc8')]=(_0x70daf4[_0x152f57('0x23a2')][_0x152f57('0xdf8')]-0x1)*_0x70daf4[_0x152f57('0x23a2')][_0x152f57('0x6f0')],_0xb0e9bd[_0x152f57('0xca1')](_0x152f57('0x20c2'))?_0x70daf4[_0x152f57('0x1883')]=_0x35d852['smsQueue'][_0x152f57('0x1e6e')](_0x70daf4[_0x152f57('0x23a2')],_0x22a9a4)[_0x152f57('0xe53')]:(_0x70daf4[_0x152f57('0x23a2')]['id']=_0x70daf4['userProfile']['id'],_0x70daf4['query']['section']=_0x152f57('0xd0d'),_0x70daf4['promise']=_0x35d852[_0x152f57('0x2a')][_0x152f57('0x241d')](_0x70daf4['query'],_0x22a9a4)[_0x152f57('0xe53')]);}function _0x3ad3b2(_0x2bd635,_0xba62e4){const _0x1e14fa=_0x5d4d92;_0x40d425[_0x1e14fa('0x1d4')]({'controller':_0x1e14fa('0x2131'),'controllerAs':'vm','templateUrl':_0x246876,'parent':angular[_0x1e14fa('0x1fcc')](_0x34d8a9[_0x1e14fa('0x18e5')]),'targetEvent':_0x2bd635,'clickOutsideToClose':!![],'locals':{'smsQueue':_0xba62e4,'smsQueues':_0x70daf4['smsQueues'][_0x1e14fa('0xf5d')],'license':_0x70daf4['license'],'setting':_0x70daf4[_0x1e14fa('0x260a')],'crudPermissions':_0x70daf4[_0x1e14fa('0x1134')]}});}function _0x4088ef(_0x5c97d6){const _0x276fc1=_0x5d4d92;_0x35d852[_0x276fc1('0x193f')][_0x276fc1('0xd7e')]({'id':_0x5c97d6['id']})[_0x276fc1('0xe53')][_0x276fc1('0x683')](function(){const _0x2839c0=_0x276fc1;_0x2e3ca0()[_0x2839c0('0x3ec')](_0x70daf4[_0x2839c0('0xdf3')][_0x2839c0('0xf5d')],{'id':_0x5c97d6['id']}),_0x70daf4[_0x2839c0('0xdf3')][_0x2839c0('0x50d')]-=0x1,!_0x70daf4[_0x2839c0('0xdf3')][_0x2839c0('0xf5d')][_0x2839c0('0x1564')]&&_0x70daf4['getSmsQueues'](),_0xf51897[_0x2839c0('0x53')]({'title':_0x2e3ca0()[_0x2839c0('0x1e03')]('SmsQueue')+_0x2839c0('0xbfc'),'msg':_0x5c97d6[_0x2839c0('0x60a')]?_0x5c97d6[_0x2839c0('0x60a')]+_0x2839c0('0x194d'):''});})[_0x276fc1('0x130a')](function(_0x18fbaf){const _0x593dff=_0x276fc1;if(_0x18fbaf['data']&&_0x18fbaf[_0x593dff('0x5a5')][_0x593dff('0x17f')]&&_0x18fbaf[_0x593dff('0x5a5')][_0x593dff('0x17f')][_0x593dff('0x1564')]){_0x70daf4['errors']=_0x18fbaf[_0x593dff('0x5a5')]['errors']||[{'message':_0x18fbaf[_0x593dff('0x1ff0')](),'type':_0x593dff('0x1fee')}];for(let _0x2b8936=0x0;_0x2b8936<_0x18fbaf['data'][_0x593dff('0x17f')][_0x593dff('0x1564')];_0x2b8936++){_0xf51897[_0x593dff('0x52a')]({'title':_0x18fbaf[_0x593dff('0x5a5')][_0x593dff('0x17f')][_0x2b8936]['type'],'msg':_0x18fbaf[_0x593dff('0x5a5')][_0x593dff('0x17f')][_0x2b8936][_0x593dff('0x8c2')]});}}else _0xf51897[_0x593dff('0x52a')]({'title':_0x18fbaf['status']?_0x593dff('0x2168')+_0x18fbaf['status']+_0x593dff('0xbf6')+_0x18fbaf['statusText']:'SYSTEM:DELETEsmsQueue','msg':_0x18fbaf[_0x593dff('0x5a5')]?JSON[_0x593dff('0x258a')](_0x18fbaf[_0x593dff('0x5a5')][_0x593dff('0x8c2')]):_0x18fbaf[_0x593dff('0x8c2')]||_0x18fbaf[_0x593dff('0x1ff0')]()});});}function _0x1d3594(){const _0x5a7de7=_0x5d4d92,_0x1c2079=angular[_0x5a7de7('0x1a86')](_0x70daf4[_0x5a7de7('0x855')]);return _0x70daf4[_0x5a7de7('0x855')]=[],_0x1c2079;}function _0x23d8a1(_0x159339){const _0x39952a=_0x5d4d92,_0x1750b0=_0x40d425['confirm']()[_0x39952a('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20smsQueues?')[_0x39952a('0x26e3')](_0x39952a('0xed5')+_0x70daf4[_0x39952a('0x855')][_0x39952a('0x1564')]+'\x20selected'+_0x39952a('0x1ee7'))[_0x39952a('0x1040')](_0x39952a('0x1113'))[_0x39952a('0xe42')](_0x159339)['ok']('OK')[_0x39952a('0x19fb')](_0x39952a('0x16b8'));_0x40d425['show'](_0x1750b0)[_0x39952a('0x683')](function(){const _0x194601=_0x39952a;_0x70daf4[_0x194601('0x855')][_0x194601('0x1299')](function(_0x2a52fd){_0x4088ef(_0x2a52fd);}),_0x70daf4[_0x194601('0x855')]=[];});}function _0x1ea795(){_0x70daf4['selectedSmsQueues']=[];}function _0x2191f3(){const _0xb8b1d3=_0x5d4d92;_0x70daf4['selectedSmsQueues']=_0x70daf4[_0xb8b1d3('0xdf3')][_0xb8b1d3('0xf5d')];}}const _0x521da1=_0x1d150c;_0x4f60ce[_0x189033('0x14be')]=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x4f60ce(_0x3c9163,_0x5e0815){const _0x4fc7ae=_0x189033;_0x3c9163['state'](_0x4fc7ae('0x1263'),{'abstract':!![],'url':_0x4fc7ae('0x307')})['state'](_0x4fc7ae('0x2571'),{'url':_0x4fc7ae('0x240c'),'views':{'content@app':{'templateUrl':_0x512e86,'controller':_0x4fc7ae('0x230f')}},'resolve':{'smsQueues':['apiResolver','Auth',function(_0x28d33a,_0x4a3022){const _0x5ae47d=_0x4fc7ae;return _0x4a3022[_0x5ae47d('0xca1')](_0x5ae47d('0x20c2'))?_0x28d33a[_0x5ae47d('0xed7')](_0x5ae47d('0x27bb'),{'fields':_0x5ae47d('0x1b67'),'sort':'-updatedAt','channel':_0x5ae47d('0x1285'),'limit':0xa,'offset':0x0}):_0x28d33a['resolve'](_0x5ae47d('0x191b'),{'id':_0x4a3022[_0x5ae47d('0x20b2')]()[_0x5ae47d('0x2f')],'section':_0x5ae47d('0xd0d'),'fields':_0x5ae47d('0x1b67'),'sort':'-updatedAt','channel':_0x5ae47d('0x1285'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x4fc7ae('0x4b1'),_0x4fc7ae('0xba1'),function(_0x1a9daa,_0x36db7b){const _0x5e9128=_0x4fc7ae;return _0x36db7b[_0x5e9128('0xca1')]('admin')?null:_0x1a9daa['resolve'](_0x5e9128('0x1464'),{'fields':_0x5e9128('0x16f'),'id':_0x36db7b[_0x5e9128('0x20b2')]()[_0x5e9128('0x2f')]});}],'userProfileSection':[_0x4fc7ae('0x4b1'),_0x4fc7ae('0xba1'),function(_0x38f0ef,_0x5c092c){const _0x66986c=_0x4fc7ae;return _0x5c092c[_0x66986c('0xca1')](_0x66986c('0x20c2'))?null:_0x38f0ef[_0x66986c('0xed7')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5c092c[_0x66986c('0x20b2')]()[_0x66986c('0x2f')],'sectionId':0x2bd});}]},'authenticate':!![],'permissionId':0x2bd,'bodyClass':_0x4fc7ae('0x1285')})[_0x4fc7ae('0x2598')](_0x4fc7ae('0x1b6d'),{'url':_0x4fc7ae('0x1560'),'params':{'smsQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x2e7b8d,'controller':_0x4fc7ae('0x1e2d')}},'resolve':{'smsQueue':[_0x4fc7ae('0x4b1'),'$stateParams',function(_0x1d7102,_0x615522){const _0x35a1df=_0x4fc7ae;return _0x1d7102[_0x35a1df('0xed7')](_0x35a1df('0x27bb'),{'fields':_0x35a1df('0x1b67'),'id':_0x615522['id']});}],'userProfileSection':[_0x4fc7ae('0x4b1'),_0x4fc7ae('0xba1'),function(_0x10580c,_0x4406de){const _0x19adb4=_0x4fc7ae;return _0x10580c[_0x19adb4('0xed7')](_0x19adb4('0x360'),{'fields':_0x19adb4('0x1f47'),'userProfileId':_0x4406de[_0x19adb4('0x20b2')]()[_0x19adb4('0x2f')],'sectionId':0x2bd});}]},'authenticate':!![],'permissionId':0x2bd,'bodyClass':'sms'})['state'](_0x4fc7ae('0x16'),{'url':_0x4fc7ae('0xb23'),'views':{'content@app':{'templateUrl':_0x3b0853,'controller':_0x4fc7ae('0x1784')}},'resolve':{'smsAccounts':[_0x4fc7ae('0x4b1'),_0x4fc7ae('0xba1'),function(_0xae4da1,_0x341ef6){const _0x28f62c=_0x4fc7ae;return _0x341ef6[_0x28f62c('0xca1')](_0x28f62c('0x20c2'))?_0xae4da1['resolve'](_0x28f62c('0xf29'),{'fields':_0x28f62c('0x1892'),'sort':_0x28f62c('0xc36'),'limit':0xa,'offset':0x0}):_0xae4da1[_0x28f62c('0xed7')]('userProfile@getResources',{'id':_0x341ef6[_0x28f62c('0x20b2')]()[_0x28f62c('0x2f')],'section':_0x28f62c('0x334'),'fields':_0x28f62c('0x1892'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':[_0x4fc7ae('0x4b1'),'Auth',function(_0x4a6e96,_0x2cfb17){const _0x4a43e0=_0x4fc7ae;return _0x2cfb17[_0x4a43e0('0xca1')](_0x4a43e0('0x20c2'))?null:_0x4a6e96[_0x4a43e0('0xed7')](_0x4a43e0('0x1464'),{'fields':_0x4a43e0('0x16f'),'id':_0x2cfb17[_0x4a43e0('0x20b2')]()[_0x4a43e0('0x2f')]});}],'userProfileSection':['apiResolver','Auth',function(_0x342dd4,_0x4b2758){const _0x14ebf3=_0x4fc7ae;return _0x4b2758[_0x14ebf3('0xca1')](_0x14ebf3('0x20c2'))?null:_0x342dd4[_0x14ebf3('0xed7')]('userProfileSection@get',{'fields':_0x14ebf3('0x1f47'),'userProfileId':_0x4b2758[_0x14ebf3('0x20b2')]()[_0x14ebf3('0x2f')],'sectionId':0x2be});}]},'authenticate':!![],'permissionId':0x2be,'bodyClass':_0x4fc7ae('0x1285')})['state'](_0x4fc7ae('0x2533'),{'url':'/:id?tab','params':{'smsAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x17c8b4,'controller':_0x4fc7ae('0x200a')}},'resolve':{'smsAccount':['apiResolver',_0x4fc7ae('0x8ea'),function(_0xc04035,_0x15f422){const _0x5db3d5=_0x4fc7ae;return _0xc04035[_0x5db3d5('0xed7')](_0x5db3d5('0xf29'),{'fields':_0x5db3d5('0x1892'),'id':_0x15f422['id']});}],'userProfileSection':[_0x4fc7ae('0x4b1'),_0x4fc7ae('0xba1'),function(_0x43e6a6,_0x173c0f){const _0x278b96=_0x4fc7ae;return _0x43e6a6[_0x278b96('0xed7')](_0x278b96('0x360'),{'fields':_0x278b96('0x1f47'),'userProfileId':_0x173c0f[_0x278b96('0x20b2')]()['userProfileId'],'sectionId':0x2be});}]},'authenticate':!![],'permissionId':0x2be,'bodyClass':_0x4fc7ae('0x1285')}),_0x5e0815[_0x4fc7ae('0x7d2')]('app/main/apps/sms');}angular['module'](_0x189033('0x1263'),['ngCsv',_0x189033('0x1ddb'),_0x189033('0x2290'),'flow',_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),_0x189033('0x2609'),'ngAnimate',_0x189033('0x76'),_0x189033('0x516'),_0x189033('0x7fa'),'mwFormUtils',_0x189033('0x3b5'),_0x189033('0x153a'),'ngEmbed',_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da'),'app.sms.realtime'])[_0x189033('0x272d')](_0x4f60ce)[_0x189033('0x1da3')]('CreateOrEditSmsAccountDialogController',_0x5a2f00)[_0x189033('0x1da3')]('SmsAccountActionsController',_0x537444)[_0x189033('0x1da3')]('SmsAccountagentaddController',_0x204864)['controller']('EditSmsAccountAppagentDialogController',_0x3b3fe2)[_0x189033('0x1da3')](_0x189033('0x1e68'),_0x5620e0)[_0x189033('0x1da3')](_0x189033('0x187a'),_0x10912d)[_0x189033('0x1da3')](_0x189033('0x738'),_0x25f7f8)[_0x189033('0x1da3')](_0x189033('0x24f0'),_0xedc54a)[_0x189033('0x1da3')](_0x189033('0x490'),_0x39dd5c)[_0x189033('0x1da3')](_0x189033('0x515'),_0x17f988)['controller']('EditSmsAccountAppintervalDialogController',_0x1313af)['controller']('EditSmsAccountAppnoopDialogController',_0x37c06d)[_0x189033('0x1da3')](_0x189033('0xb64'),_0xd5c4b4)[_0x189033('0x1da3')](_0x189033('0x2c1'),_0x9b51b5)[_0x189033('0x1da3')](_0x189033('0x24d9'),_0x3896db)[_0x189033('0x1da3')]('SmsAccountInteractionsController',_0x88be68)[_0x189033('0x1da3')](_0x189033('0x62e'),_0x1651d9)[_0x189033('0x1da3')](_0x189033('0x2666'),_0xd62d99)[_0x189033('0x1da3')](_0x189033('0x114a'),_0x3a4037)[_0x189033('0x1da3')](_0x189033('0x25a5'),_0x38204d)[_0x189033('0x1da3')](_0x189033('0x1ec0'),_0x549023)['controller'](_0x189033('0x2131'),_0x48b3f0)['controller'](_0x189033('0x15c'),_0x16ee25)[_0x189033('0x1da3')]('SmsQueueteamaddController',_0x5af27c)[_0x189033('0x1da3')](_0x189033('0x2125'),_0xd1b530)[_0x189033('0x1da3')](_0x189033('0x160c'),_0x521da1);const _0x39bb8b=_0x180212['p']+_0x189033('0x125d'),_0x4594c3=_0x180212['p']+'src/js/modules/main/apps/openchannel/views/realtime/agents/view.html/view.html',_0x3b9f80=_0x180212['p']+'src/js/modules/main/apps/openchannel/views/realtime/queues/view.html/view.html';_0x1b254a[_0x189033('0x14be')]=['$scope','$q',_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x241e'),_0x189033('0x22ab'),'agents',_0x189033('0x127b'),'api','socket',_0x189033('0x1d70'),_0x189033('0xa72'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1'),_0x189033('0xace'),'$interval'];function _0x1b254a(_0x22c4f9,_0x334c31,_0x2c8763,_0x3a0365,_0x3185a3,_0x3ee513,_0x583703,_0x2eb790,_0x580683,_0x5b3b78,_0x6dcc34,_0x5a75ed,_0x579314,_0x1d7db3,_0x29ce55,_0x11ed6c,_0x47dcb5,_0x3ac20f){const _0x4d7ba2=_0x189033,_0x581e39=this,_0x4d6995=[_0x4d7ba2('0xef9'),_0x4d7ba2('0x2309'),_0x4d7ba2('0x10f'),'lastPauseAt',_0x4d7ba2('0x17fe'),_0x4d7ba2('0x8cc'),'internal',_0x4d7ba2('0x2050'),_0x4d7ba2('0x1938'),'openchannelPause',_0x4d7ba2('0x774'),_0x4d7ba2('0x1b89'),'whatsappPause',_0x4d7ba2('0x716'),_0x4d7ba2('0x1431'),_0x4d7ba2('0xd2a'),_0x4d7ba2('0x218'),_0x4d7ba2('0x2409'),'smsCapacity',_0x4d7ba2('0x1484'),_0x4d7ba2('0x1079'),_0x4d7ba2('0x153b'),'openchannelCurrentCapacity',_0x4d7ba2('0x15c1'),_0x4d7ba2('0x1902'),_0x4d7ba2('0xaba'),_0x4d7ba2('0x157f'),_0x4d7ba2('0x1487'),_0x4d7ba2('0x2a8'),'mailStatus',_0x4d7ba2('0x2787'),_0x4d7ba2('0x2512'),_0x4d7ba2('0x278b'),_0x4d7ba2('0x15e0'),_0x4d7ba2('0x1a03'),'openchannelStatusTime',_0x4d7ba2('0xc07'),_0x4d7ba2('0x1a70'),_0x4d7ba2('0x17c2'),_0x4d7ba2('0x21d1'),'voiceStatusTime',_0x4d7ba2('0x660'),_0x4d7ba2('0x10f5'),_0x4d7ba2('0xd70'),_0x4d7ba2('0xa31'),_0x4d7ba2('0x2259')],_0x40ada2=['chatPause',_0x4d7ba2('0x1a11'),_0x4d7ba2('0x774'),'smsPause',_0x4d7ba2('0x185d'),_0x4d7ba2('0x716'),'voicePause',_0x4d7ba2('0x2309')];_0x581e39[_0x4d7ba2('0x11ed')]=_0x11ed6c['getCurrentUser'](),_0x581e39[_0x4d7ba2('0x24d2')]=[_0x4d7ba2('0x2727'),_0x4d7ba2('0x5d7'),_0x4d7ba2('0x63'),_0x4d7ba2('0x1026'),_0x4d7ba2('0x79')],_0x581e39[_0x4d7ba2('0x22ab')]=_0x583703||{'count':0x0,'rows':[]},_0x581e39['license']=_0x47dcb5,_0x581e39['userProfile']=_0x1d7db3,_0x581e39[_0x4d7ba2('0x22df')]=_0x29ce55&&_0x29ce55['count']==0x1?_0x29ce55[_0x4d7ba2('0xf5d')][0x0]:null,_0x581e39[_0x4d7ba2('0x1134')]=_0x11ed6c[_0x4d7ba2('0x142a')](_0x581e39[_0x4d7ba2('0x22df')]?_0x581e39[_0x4d7ba2('0x22df')][_0x4d7ba2('0x1134')]:null),_0x581e39[_0x4d7ba2('0x756')]=_0x2eb790?_0x2e3ca0()['keyBy'](_0x2eb790['rows']?_0x2eb790['rows']:[],'id'):{},_0x581e39[_0x4d7ba2('0x127b')]=_0x580683?_0x2e3ca0()[_0x4d7ba2('0x24db')](_0x580683['rows']?_0x580683[_0x4d7ba2('0xf5d')]:[],'id'):{},_0x581e39['paginatedAgents']={},_0x581e39[_0x4d7ba2('0x182c')]=![],_0x581e39[_0x4d7ba2('0x150d')]=[],_0x581e39[_0x4d7ba2('0x7c6')]={};for(const _0x3e9cf0 in _0x581e39[_0x4d7ba2('0x756')]){typeof _0x581e39[_0x4d7ba2('0x756')][_0x3e9cf0]!=='undefined'&&(_0x581e39['agents'][_0x3e9cf0][_0x4d7ba2('0x12f3')]=!![]);}_0x581e39[_0x4d7ba2('0x23a2')]={'limit':0xa,'page':0x1,'order':_0x4d7ba2('0x11bc'),'globalStatusFilter':'','pauseTypeFilter':''},_0x581e39[_0x4d7ba2('0x1999')]=_0x28bd13,_0x581e39[_0x4d7ba2('0x1880')]=_0x4c388e,_0x581e39['pause']=_0x516316,_0x581e39['unPause']=_0x27180f,_0x581e39[_0x4d7ba2('0x411')]=_0x9f1319,_0x581e39[_0x4d7ba2('0x2d2')]=_0x31a8a6,_0x581e39['getAgentGlobalStatus']=_0x143c92,_0x581e39[_0x4d7ba2('0x3ee')]=_0x201bd6,_0x581e39[_0x4d7ba2('0x2678')]=_0x52b241,_0x581e39[_0x4d7ba2('0x1f68')]=_0x307f91,_0x581e39[_0x4d7ba2('0x2819')]=_0x5aa473,_0x581e39[_0x4d7ba2('0x1418')]=_0x236db1,_0x581e39['onInit']=_0x6521b5,_0x581e39['onConnect']=_0x29e954,_0x581e39['onComplete']=_0x38c9ea,_0x581e39[_0x4d7ba2('0x1f6c')]=_0x33fc58,_0x6dcc34['on']('user:save',_0x581e39[_0x4d7ba2('0x2819')]),_0x6dcc34['on'](_0x4d7ba2('0x2719'),_0x581e39['onUpdate']),_0x6dcc34['on'](_0x4d7ba2('0x216d'),_0x581e39[_0x4d7ba2('0x16b6')]),_0x6dcc34['on']('user:agentcomplete',_0x581e39[_0x4d7ba2('0x2250')]),_0x6521b5();let _0x39a4ff=_0x3ac20f(function(){_0x581e39['load']&&(_0x581e39['load']=![],_0x6521b5());},0x3e7);function _0x6521b5(){const _0xb26ad9=_0x4d7ba2;_0x581e39['load']=![];const _0x404616=_0x334c31[_0xb26ad9('0x448')]();_0x581e39[_0xb26ad9('0x1883')]=_0x404616[_0xb26ad9('0x1883')],_0x581e39[_0xb26ad9('0xdf9')]=[],_0x581e39[_0xb26ad9('0x150d')]=[],_0x2e3ca0()[_0xb26ad9('0x15d0')](_0x581e39[_0xb26ad9('0x756')],function(_0x44bb24,_0x1e8c68){const _0x25e6bc=_0xb26ad9;_0x581e39[_0x25e6bc('0x127b')][_0x1e8c68]&&_0x2e3ca0()[_0x25e6bc('0xf22')](_0x44bb24,_0x2e3ca0()[_0x25e6bc('0x24d0')](_0x2e3ca0()['omit'](_0x581e39[_0x25e6bc('0x127b')][_0x1e8c68],_0x40ada2),_0x4d6995)),_0x143c92(_0x44bb24),_0x44bb24[_0x25e6bc('0x2309')]?(_0x581e39['filteredAgents'][_0x25e6bc('0x1fd0')](_0x44bb24),_0x581e39[_0x25e6bc('0x7c6')][_0x44bb24['internal']]=_0x1e8c68):_0x44bb24[_0x25e6bc('0x24d')]=_0x2e3ca0()[_0x25e6bc('0xea3')](_0x1aaf93()()[_0x25e6bc('0x26dd')]('x'));});_0x581e39[_0xb26ad9('0x23a2')][_0xb26ad9('0x1102')]&&_0x2e3ca0()['remove'](_0x581e39[_0xb26ad9('0xdf9')],function(_0x7a8c37){const _0x36f558=_0xb26ad9;return _0x7a8c37[_0x36f558('0x12fa')]!==_0x581e39[_0x36f558('0x23a2')][_0x36f558('0x1102')];});_0x581e39[_0xb26ad9('0x23a2')][_0xb26ad9('0x1606')]&&_0x2e3ca0()[_0xb26ad9('0x3ec')](_0x581e39[_0xb26ad9('0xdf9')],function(_0x1b26e8){const _0x10b8b9=_0xb26ad9;return _0x1b26e8[_0x10b8b9('0x17fe')]!==_0x581e39[_0x10b8b9('0x23a2')][_0x10b8b9('0x1606')];});_0x581e39[_0xb26ad9('0x23a2')][_0xb26ad9('0x25')]&&_0x2e3ca0()[_0xb26ad9('0x3ec')](_0x581e39[_0xb26ad9('0xdf9')],function(_0x15316d){const _0x5a00bd=_0xb26ad9;return _0x15316d[_0x5a00bd('0x11bc')][_0x5a00bd('0x93a')]()[_0x5a00bd('0x824')](_0x581e39['query'][_0x5a00bd('0x25')]['toLowerCase']())<0x0;});_0x581e39[_0xb26ad9('0xdf9')]=_0x1a9255(_0x581e39[_0xb26ad9('0xdf9')]);const _0x3a036e=(_0x581e39[_0xb26ad9('0x23a2')][_0xb26ad9('0xdf8')]-0x1)*_0x581e39[_0xb26ad9('0x23a2')][_0xb26ad9('0x6f0')];_0x581e39[_0xb26ad9('0x20d5')]=_0x2e3ca0()[_0xb26ad9('0x16b7')](_0x581e39[_0xb26ad9('0xdf9')],_0x3a036e)['slice'](0x0,_0x581e39[_0xb26ad9('0x23a2')][_0xb26ad9('0x6f0')]);for(let _0x364679=0x0;_0x364679<_0x581e39[_0xb26ad9('0x20d5')][_0xb26ad9('0x1564')];_0x364679+=0x1){_0x581e39[_0xb26ad9('0x150d')][_0xb26ad9('0x1fd0')](_0x581e39['paginatedAgents'][_0x364679]['id']);}_0x404616[_0xb26ad9('0xed7')](),_0x581e39[_0xb26ad9('0x182c')]=!![];}function _0x5aa473(_0x5bb006){const _0xf40ee5=_0x4d7ba2;_0x581e39['agents'][_0x5bb006['id']]&&(_0x2e3ca0()[_0xf40ee5('0xf22')](_0x581e39[_0xf40ee5('0x756')][_0x5bb006['id']],_0x2e3ca0()[_0xf40ee5('0x24d0')](_0x2e3ca0()[_0xf40ee5('0x8b5')](_0x5bb006,_0x40ada2),_0x4d6995)),_0x2e3ca0()[_0xf40ee5('0xf22')](_0x581e39[_0xf40ee5('0x127b')][_0x5bb006['id']],_0x2e3ca0()[_0xf40ee5('0x24d0')](_0x2e3ca0()[_0xf40ee5('0x8b5')](_0x5bb006,_0x40ada2),_0x4d6995)),_0x143c92(_0x581e39[_0xf40ee5('0x756')][_0x5bb006['id']]));}function _0x236db1(_0x549e4f){const _0x4331b7=_0x4d7ba2;_0x581e39[_0x4331b7('0x756')][_0x549e4f['id']]&&(_0x2e3ca0()[_0x4331b7('0xf22')](_0x581e39[_0x4331b7('0x756')][_0x549e4f['id']],_0x2e3ca0()[_0x4331b7('0x24d0')](_0x549e4f,_0x4d6995)),_0x2e3ca0()[_0x4331b7('0xf22')](_0x581e39['rpcAgents'][_0x549e4f['id']],_0x2e3ca0()[_0x4331b7('0x24d0')](_0x549e4f,_0x4d6995)),_0x549e4f[_0x4331b7('0x8cc')]&&(_0x581e39[_0x4331b7('0x756')][_0x549e4f['id']]['globalStatusTime']=_0x549e4f[_0x4331b7('0x8cc')],_0x581e39[_0x4331b7('0x127b')][_0x549e4f['id']][_0x4331b7('0x24d')]=_0x549e4f[_0x4331b7('0x8cc')]),_0x143c92(_0x581e39[_0x4331b7('0x756')][_0x549e4f['id']]));}function _0x29e954(_0x49cd04){const _0x15febd=_0x4d7ba2;_0x581e39[_0x15febd('0x756')][_0x581e39['agentInternal'][_0x49cd04[_0x15febd('0x1d79')]]]&&(_0x2e3ca0()[_0x15febd('0xf22')](_0x581e39['agents'][_0x581e39[_0x15febd('0x7c6')][_0x49cd04[_0x15febd('0x1d79')]]],_0x2e3ca0()['pick'](_0x49cd04,['queue',_0x15febd('0x10f5')])),_0x2e3ca0()[_0x15febd('0xf22')](_0x581e39[_0x15febd('0x127b')][_0x581e39[_0x15febd('0x7c6')][_0x49cd04[_0x15febd('0x1d79')]]],_0x2e3ca0()[_0x15febd('0x24d0')](_0x49cd04,[_0x15febd('0x660'),_0x15febd('0x10f5')])));}function _0x38c9ea(_0x2cc77a){const _0x1d296b=_0x4d7ba2;_0x581e39[_0x1d296b('0x756')][_0x581e39[_0x1d296b('0x7c6')][_0x2cc77a[_0x1d296b('0x1d79')]]]&&(_0x581e39[_0x1d296b('0x756')][_0x581e39['agentInternal'][_0x2cc77a[_0x1d296b('0x1d79')]]]=_0x2e3ca0()[_0x1d296b('0x8b5')](_0x581e39[_0x1d296b('0x756')][_0x581e39[_0x1d296b('0x7c6')][_0x2cc77a['destaccountcode']]],[_0x1d296b('0x660'),_0x1d296b('0x10f5')]),_0x581e39[_0x1d296b('0x127b')][_0x581e39['agentInternal'][_0x2cc77a[_0x1d296b('0x1d79')]]]=_0x2e3ca0()['omit'](_0x581e39[_0x1d296b('0x127b')][_0x581e39['agentInternal'][_0x2cc77a[_0x1d296b('0x1d79')]]],[_0x1d296b('0x660'),_0x1d296b('0x10f5')]));}function _0x28bd13(_0x5b95c8){const _0x3d5349=_0x4d7ba2;return _0x5b3b78[_0x3d5349('0xc96')]['logout']({'id':_0x5b95c8['id'],'device':_0x3d5349('0x2c9'),'agent_id':_0x5b95c8['id'],'agent_name':_0x5b95c8['name']})[_0x3d5349('0xe53')][_0x3d5349('0x683')](function(){const _0x110db2=_0x3d5349;_0x5a75ed[_0x110db2('0x53')]({'title':_0x110db2('0x1683'),'msg':_0x5b95c8[_0x110db2('0x11bc')]+_0x110db2('0x2488')}),_0x581e39[_0x110db2('0x756')][_0x5b95c8['id']]&&(_0x581e39[_0x110db2('0x756')][_0x5b95c8['id']]['online']=![]),_0x581e39[_0x110db2('0x127b')][_0x5b95c8['id']]&&(_0x581e39['rpcAgents'][_0x5b95c8['id']][_0x110db2('0x2309')]=![]),_0x6521b5();})['catch'](function(_0x46aca8){const _0x1406b5=_0x3d5349;_0x5a75ed['error']({'title':_0x46aca8['status']?_0x1406b5('0x2168')+_0x46aca8[_0x1406b5('0x13ee')]+_0x1406b5('0xbf6')+_0x46aca8[_0x1406b5('0x24a9')]:_0x1406b5('0x154f'),'msg':_0x46aca8[_0x1406b5('0x5a5')]?JSON[_0x1406b5('0x258a')](_0x46aca8[_0x1406b5('0x5a5')]['message']):_0x46aca8[_0x1406b5('0x1ff0')]()});});}function _0x516316(_0x3f0929,_0x18b728){const _0x791a12=_0x4d7ba2;return _0x5b3b78[_0x791a12('0xc96')][_0x791a12('0xa4')]({'id':_0x3f0929['id'],'type':_0x18b728})[_0x791a12('0xe53')][_0x791a12('0x683')](function(_0x2feeef){const _0xb4c848=_0x791a12;_0x581e39[_0xb4c848('0x756')][_0x3f0929['id']]&&_0x2e3ca0()[_0xb4c848('0xf22')](_0x581e39[_0xb4c848('0x756')][_0x3f0929['id']],_0x2e3ca0()['pick'](_0x2feeef,_0x4d6995)),_0x581e39[_0xb4c848('0x127b')][_0x3f0929['id']]&&_0x2e3ca0()[_0xb4c848('0xf22')](_0x581e39[_0xb4c848('0x127b')][_0x3f0929['id']],_0x2e3ca0()[_0xb4c848('0x24d0')](_0x2feeef,_0x4d6995)),_0x143c92(_0x581e39[_0xb4c848('0x756')][_0x3f0929['id']]);})['catch'](function(_0x5e7c17){const _0x4d36e8=_0x791a12;_0x5a75ed['error']({'title':_0x5e7c17['status']?_0x4d36e8('0x2168')+_0x5e7c17[_0x4d36e8('0x13ee')]+'\x20-\x20'+_0x5e7c17[_0x4d36e8('0x24a9')]:'api.staff.save','msg':_0x5e7c17[_0x4d36e8('0x5a5')]?JSON[_0x4d36e8('0x258a')](_0x5e7c17[_0x4d36e8('0x5a5')][_0x4d36e8('0x8c2')]):_0x5e7c17[_0x4d36e8('0x1ff0')]()});});}function _0x27180f(_0x1d5e2f){const _0x2c0af9=_0x4d7ba2;return _0x5b3b78[_0x2c0af9('0xc96')][_0x2c0af9('0x1778')]({'id':_0x1d5e2f['id']})[_0x2c0af9('0xe53')][_0x2c0af9('0x683')](function(_0x4c19d0){const _0x51e9a5=_0x2c0af9;_0x581e39[_0x51e9a5('0x756')][_0x1d5e2f['id']]&&_0x2e3ca0()[_0x51e9a5('0xf22')](_0x581e39['agents'][_0x1d5e2f['id']],_0x2e3ca0()[_0x51e9a5('0x24d0')](_0x4c19d0,_0x4d6995)),_0x581e39[_0x51e9a5('0x127b')][_0x1d5e2f['id']]&&_0x2e3ca0()[_0x51e9a5('0xf22')](_0x581e39[_0x51e9a5('0x127b')][_0x1d5e2f['id']],_0x2e3ca0()[_0x51e9a5('0x24d0')](_0x4c19d0,_0x4d6995)),_0x143c92(_0x581e39[_0x51e9a5('0x756')][_0x1d5e2f['id']]);})[_0x2c0af9('0x130a')](function(_0x158606){const _0x2d79e7=_0x2c0af9;_0x5a75ed[_0x2d79e7('0x52a')]({'title':_0x158606[_0x2d79e7('0x13ee')]?_0x2d79e7('0x2168')+_0x158606[_0x2d79e7('0x13ee')]+'\x20-\x20'+_0x158606[_0x2d79e7('0x24a9')]:_0x2d79e7('0x154f'),'msg':_0x158606[_0x2d79e7('0x5a5')]?JSON['stringify'](_0x158606[_0x2d79e7('0x5a5')]['message']):_0x158606[_0x2d79e7('0x1ff0')]()});});}function _0x9f1319(_0x2fb141){const _0x4ed655=_0x4d7ba2;_0x3a0365[_0x4ed655('0x1d4')](_0x3a0365[_0x4ed655('0x2430')]()[_0x4ed655('0x188f')](!![])[_0x4ed655('0xf28')](_0x4ed655('0x71a'))[_0x4ed655('0x26e3')](_0x4ed655('0x1f0'))['ok']('Ok')['targetEvent'](_0x2fb141));}function _0x4c388e(_0xf4eecf,_0x71997){const _0x35116d=_0x4d7ba2;_0x3a0365[_0x35116d('0x1d4')]({'controller':'AgentqueueaddController','controllerAs':'vm','templateUrl':_0xf3687b,'parent':angular['element'](_0x3185a3[_0x35116d('0x18e5')]),'targetEvent':_0x71997,'clickOutsideToClose':!![],'locals':{'agent':_0xf4eecf,'agents':[],'channel':_0x35116d('0x1261'),'direction':'inbound','crudPermissions':_0x581e39['crudPermissions']}});}function _0x201bd6(_0x367428){const _0x18c0ac=_0x4d7ba2;return _0x367428===_0x18c0ac('0xa4')||_0x367428===_0x18c0ac('0x651');}function _0x52b241(_0xf4ca57){return _0xf4ca57==='pause';}function _0x307f91(_0x4d49e9){const _0x11ae88=_0x4d7ba2;return _0x4d49e9===_0x11ae88('0x651');}function _0x514305(_0x2e6ff8){const _0x1db229=_0x4d7ba2;return _0x2e6ff8==='idle'||_0x2e6ff8===_0x1db229('0xdd4')||_0x2e6ff8===_0x1db229('0x19d2')||_0x2e6ff8===_0x1db229('0x2727')||_0x2e3ca0()[_0x1db229('0x8f2')](_0x2e6ff8);}function _0x31a8a6(_0x72f3e5,_0x923d1e){const _0x2d9ac2=_0x4d7ba2;if(_0x923d1e===_0x2d9ac2('0xcf2')){if(_0x72f3e5[_0x923d1e+_0x2d9ac2('0x1d9d')]!==_0x2d9ac2('0x1586'))return _0x72f3e5[_0x923d1e+_0x2d9ac2('0x1d9d')];if(_0x72f3e5[_0x923d1e+'Pause'])return _0x72f3e5[_0x923d1e+_0x2d9ac2('0x1d9d')]=_0x2d9ac2('0xa4'),'pause';return _0x2d9ac2('0x1586');}else{if(_0x72f3e5[_0x923d1e+_0x2d9ac2('0x2113')])return _0x72f3e5[_0x923d1e+_0x2d9ac2('0x1d9d')]='pause',_0x2d9ac2('0xa4');return _0x72f3e5[_0x923d1e+'Status'];}}function _0x143c92(_0x157e9d){const _0x3aa7b0=_0x4d7ba2;let _0x16a922=_0x3aa7b0('0xdd4');if(_0x2e3ca0()[_0x3aa7b0('0x161')]([_0x31a8a6(_0x157e9d,'voice'),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x24e')),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x129f')),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x1261')),_0x31a8a6(_0x157e9d,'sms'),_0x31a8a6(_0x157e9d,'whatsapp'),_0x31a8a6(_0x157e9d,'fax')],_0x201bd6))_0x16a922='pause';else{if(_0x2e3ca0()['some']([_0x31a8a6(_0x157e9d,_0x3aa7b0('0xcf2')),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x24e')),_0x31a8a6(_0x157e9d,'mail'),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x1261')),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x1285')),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x16e7')),_0x31a8a6(_0x157e9d,'fax')],_0x201bd6))_0x16a922=_0x3aa7b0('0x651');else _0x2e3ca0()[_0x3aa7b0('0x161')]([_0x31a8a6(_0x157e9d,_0x3aa7b0('0xcf2')),_0x31a8a6(_0x157e9d,'chat'),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x129f')),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x1261')),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x1285')),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x16e7')),_0x31a8a6(_0x157e9d,_0x3aa7b0('0x23e9'))],_0x514305)?_0x16a922=_0x3aa7b0('0x1586'):_0x16a922=_0x3aa7b0('0x63');}_0x157e9d['globalStatus']!==_0x16a922&&(_0x157e9d[_0x3aa7b0('0x12fa')]=_0x16a922,_0x157e9d[_0x3aa7b0('0x12f3')]?(_0x157e9d[_0x3aa7b0('0x12f3')]=![],_0x157e9d['globalStatusTime']=_0x201bd6(_0x16a922)?_0x2e3ca0()[_0x3aa7b0('0xea3')](_0x1aaf93()(_0x157e9d[_0x3aa7b0('0x8cc')])[_0x3aa7b0('0x26dd')]('x')):_0x2e3ca0()[_0x3aa7b0('0x69b')]([_0x157e9d[_0x3aa7b0('0x23b4')],_0x157e9d[_0x3aa7b0('0x1a03')],_0x157e9d['mailStatusTime'],_0x157e9d[_0x3aa7b0('0x1a70')],_0x157e9d[_0x3aa7b0('0x17c2')],_0x157e9d[_0x3aa7b0('0x15db')],_0x157e9d[_0x3aa7b0('0x21d1')]])):_0x157e9d['globalStatusTime']=_0x2e3ca0()['toNumber'](_0x1aaf93()()[_0x3aa7b0('0x26dd')]('x')));}function _0x1a9255(_0x14fa33){const _0x8fbf81=_0x4d7ba2,_0x1eaf2b=_0x2e3ca0()[_0x8fbf81('0x18ad')](_0x581e39[_0x8fbf81('0x23a2')][_0x8fbf81('0x150d')],'-')?'desc':_0x8fbf81('0xe38');return _0x2e3ca0()[_0x8fbf81('0x2ef')](_0x14fa33,[_0x581e39['query'][_0x8fbf81('0x150d')][_0x8fbf81('0x1725')]('-','')],[_0x1eaf2b]);}function _0x223b38(){const _0x4867d3=_0x4d7ba2;_0x39a4ff&&(_0x3ac20f[_0x4867d3('0x19fb')](_0x39a4ff),_0x39a4ff=null);}function _0x33fc58(_0x32e6ad,_0x48989b){const _0x37b929=_0x4d7ba2;return _0x5b3b78['user'][_0x37b929('0x2480')]({'id':_0x32e6ad['id']},{'screenrecording':_0x48989b})[_0x37b929('0xe53')][_0x37b929('0x130a')](function(_0x5845b1){const _0x1cc46e=_0x37b929;_0x5a75ed['error']({'title':_0x5845b1[_0x1cc46e('0x13ee')]?_0x1cc46e('0x2168')+_0x5845b1['status']+'\x20-\x20'+_0x5845b1[_0x1cc46e('0x24a9')]:_0x1cc46e('0x162b'),'msg':_0x5845b1['data']?JSON[_0x1cc46e('0x258a')](_0x5845b1[_0x1cc46e('0x5a5')][_0x1cc46e('0x8c2')]):_0x5845b1[_0x1cc46e('0x1ff0')]()});});}_0x22c4f9[_0x4d7ba2('0x26a2')]('$destroy',function(){const _0x1957b0=_0x4d7ba2;_0x6dcc34['removeAllListeners'](_0x1957b0('0x18f0')),_0x6dcc34[_0x1957b0('0x1b9e')](_0x1957b0('0x2719')),_0x6dcc34[_0x1957b0('0x1b9e')]('user:agentconnect'),_0x6dcc34[_0x1957b0('0x1b9e')](_0x1957b0('0x3b6')),_0x223b38();});}const _0x488f56=_0x1b254a,_0x281833=_0x180212['p']+_0x189033('0x19b7'),_0x11f391=_0x180212['p']+_0x189033('0x106f');_0x3fac43[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$q',_0x189033('0x16ea'),'$interval',_0x189033('0x2da'),_0x189033('0x1a10'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1')];function _0x3fac43(_0x42a59f,_0x56812a,_0x12be90,_0x3c862a,_0x47c9f5,_0x303c0d,_0x2cfbe2,_0x5c7d7a,_0x390aae,_0x28c2f7,_0x34f101,_0x11cf7a,_0x26f3de,_0x428927){const _0x84c70a=_0x189033,_0x292f6b=this,_0x5823ac=[_0x84c70a('0x1506'),_0x84c70a('0x8bb'),_0x84c70a('0x1386'),_0x84c70a('0x7a4'),'pTalking','originated',_0x84c70a('0x8c2'),'dialActive',_0x84c70a('0x1091'),_0x84c70a('0x17c1'),'paused'];_0x292f6b['currentUser']=_0x428927['getCurrentUser'](),_0x292f6b['count']=_0x2cfbe2[_0x84c70a('0x50d')]?_0x2cfbe2['count']:0x0,_0x292f6b['queues']=_0x2cfbe2?_0x2e3ca0()[_0x84c70a('0x24db')](_0x2cfbe2[_0x84c70a('0xf5d')]?_0x2cfbe2[_0x84c70a('0xf5d')]:[],'id'):{},_0x292f6b[_0x84c70a('0x1a10')]=_0x5c7d7a?_0x2e3ca0()['keyBy'](_0x5c7d7a[_0x84c70a('0xf5d')]?_0x5c7d7a['rows']:[],'id'):{},_0x292f6b[_0x84c70a('0x2a')]=_0x11cf7a,_0x292f6b[_0x84c70a('0x22df')]=_0x26f3de&&_0x26f3de['count']==0x1?_0x26f3de[_0x84c70a('0xf5d')][0x0]:null,_0x292f6b[_0x84c70a('0x1134')]=_0x428927[_0x84c70a('0x142a')](_0x292f6b[_0x84c70a('0x22df')]?_0x292f6b['userProfileSection'][_0x84c70a('0x1134')]:null);_0x428927[_0x84c70a('0xca1')](_0x84c70a('0x20c2'))?_0x292f6b['query']={'type':'inbound','sort':_0x84c70a('0xc36'),'limit':0xa,'page':0x1}:_0x292f6b[_0x84c70a('0x23a2')]={'id':_0x292f6b[_0x84c70a('0x11ed')]['id'],'channel':_0x84c70a('0x1261'),'type':'inbound','sort':_0x84c70a('0xc36'),'limit':0xa,'page':0x1};_0x292f6b[_0x84c70a('0x53')]=_0x930e7b,_0x292f6b['getQueues']=_0x376fa8,_0x292f6b[_0x84c70a('0x19a1')]=_0x8c6af9,_0x292f6b[_0x84c70a('0x1a94')]=_0x535168,_0x292f6b['updateQueue']=_0x566bcb,_0x292f6b[_0x84c70a('0x2819')]=_0x5ddd6e,_0x292f6b['onSaveMember']=_0x500f95,_0x292f6b[_0x84c70a('0x203e')]=_0x3b48c6,_0x292f6b['onPause']=_0x27e458,_0x292f6b['onLogin']=_0x400971,_0x292f6b[_0x84c70a('0xb2b')]=_0x46f2ca,_0x292f6b[_0x84c70a('0x3a8')]=_0xd676dc,_0x292f6b[_0x84c70a('0x150d')]=[],_0x2e3ca0()['forIn'](_0x292f6b[_0x84c70a('0x2da')],function(_0x111504){_0x292f6b['order']['push'](_0x111504['id']);}),_0x28c2f7['on'](_0x84c70a('0x503'),_0x292f6b[_0x84c70a('0x2819')]),_0x28c2f7['on'](_0x84c70a('0x206'),_0x292f6b[_0x84c70a('0x3ae')]),_0x28c2f7['on'](_0x84c70a('0x6fd'),_0x292f6b[_0x84c70a('0x203e')]),_0x28c2f7['on'](_0x84c70a('0x2719'),_0x292f6b['onPause']),_0x28c2f7['on'](_0x84c70a('0x56f'),_0x292f6b[_0x84c70a('0xb2b')]),_0x28c2f7['on'](_0x84c70a('0x217c'),_0x292f6b[_0x84c70a('0xd8b')]);function _0xd676dc(){const _0x824f69=_0x84c70a,_0x2474d4=[];return _0x2e3ca0()[_0x824f69('0x15d0')](_0x292f6b['queues'],function(_0x141687,_0x17fb13){const _0x32f75a=_0x824f69;_0x141687['paused']=0x0,_0x141687[_0x32f75a('0x25a4')]=0x0,_0x292f6b['queues'][_0x17fb13][_0x32f75a('0x756')]={},_0x2474d4[_0x32f75a('0x1fd0')](_0x390aae['openchannelQueue'][_0x32f75a('0x27cf')]({'id':_0x17fb13})[_0x32f75a('0xe53')]),_0x292f6b[_0x32f75a('0x1a10')][_0x17fb13]&&_0x2e3ca0()['merge'](_0x141687,_0x2e3ca0()[_0x32f75a('0x24d0')](_0x292f6b[_0x32f75a('0x1a10')][_0x17fb13],_0x5823ac));}),_0x3c862a[_0x824f69('0x252c')](_0x2474d4)['then'](function(_0x2d9caf){const _0x58e98b=_0x824f69;for(let _0x4aaae8=0x0;_0x4aaae8<_0x2d9caf[_0x58e98b('0x1564')];_0x4aaae8+=0x1){for(let _0x3fa908=0x0;_0x3fa908<_0x2d9caf[_0x4aaae8][_0x58e98b('0xf5d')][_0x58e98b('0x1564')];_0x3fa908++){_0x2d9caf[_0x4aaae8]['rows'][_0x3fa908][_0x58e98b('0x1a1d')]&&_0x292f6b['queues'][_0x2d9caf[_0x4aaae8][_0x58e98b('0xf5d')][_0x3fa908][_0x58e98b('0xd03')]][_0x58e98b('0x1a1d')]++,_0x292f6b[_0x58e98b('0x2da')][_0x2d9caf[_0x4aaae8][_0x58e98b('0xf5d')][_0x3fa908]['OpenchannelQueueId']][_0x58e98b('0x25a4')]++,_0x292f6b[_0x58e98b('0x2da')][_0x2d9caf[_0x4aaae8][_0x58e98b('0xf5d')][_0x3fa908][_0x58e98b('0xd03')]][_0x58e98b('0x756')][_0x2d9caf[_0x4aaae8][_0x58e98b('0xf5d')][_0x3fa908][_0x58e98b('0x10c5')]]=_0x2d9caf[_0x4aaae8][_0x58e98b('0xf5d')][_0x3fa908][_0x58e98b('0xd03')];}}})[_0x824f69('0x130a')](function(_0x18c4c1){const _0x3b2c11=_0x824f69;console[_0x3b2c11('0x52a')](_0x18c4c1);});}function _0x5ddd6e(_0x5462dd){const _0x59445a=_0x84c70a;_0x292f6b[_0x59445a('0x2da')][_0x5462dd['id']]&&_0x2e3ca0()[_0x59445a('0xf22')](_0x292f6b['queues'][_0x5462dd['id']],_0x2e3ca0()[_0x59445a('0x24d0')](_0x5462dd,_0x5823ac));}function _0x500f95(_0x18b876){const _0x4c7e5a=_0x84c70a;_0x292f6b['queues'][_0x18b876[_0x4c7e5a('0xd03')]]&&_0x292f6b['queues'][_0x18b876[_0x4c7e5a('0xd03')]][_0x4c7e5a('0x25a4')]++;}function _0x3b48c6(_0x4dcb6b){const _0x3f18b8=_0x84c70a;_0x292f6b['queues'][_0x4dcb6b[_0x3f18b8('0xd03')]]&&_0x292f6b['queues'][_0x4dcb6b[_0x3f18b8('0xd03')]][_0x3f18b8('0x25a4')]--;}function _0x27e458(_0x9d2a2c){const _0x461fb0=_0x84c70a;console[_0x461fb0('0x1b2b')](_0x461fb0('0x4a5'),_0x9d2a2c);if(_0x9d2a2c[_0x461fb0('0x1431')])_0x2e3ca0()[_0x461fb0('0x15d0')](_0x292f6b[_0x461fb0('0x2da')],function(_0x5b62f8){_0x5b62f8['agents'][_0x9d2a2c['id']]&&(_0x5b62f8['paused']+=0x1,console['log']('pause'));});else!_0x9d2a2c[_0x461fb0('0x1431')]&&_0x2e3ca0()['forIn'](_0x292f6b[_0x461fb0('0x2da')],function(_0x20f04b){const _0x94474=_0x461fb0;_0x20f04b[_0x94474('0x756')][_0x9d2a2c['id']]&&(_0x20f04b[_0x94474('0x1a1d')]>0x0&&(_0x20f04b[_0x94474('0x1a1d')]-=0x1,console[_0x94474('0x1b2b')](_0x94474('0x1778'))));});}function _0x400971(_0x511812){const _0x459c89=_0x84c70a;console[_0x459c89('0x1b2b')](_0x459c89('0x16aa'),_0x511812),_0x292f6b[_0x459c89('0x2da')][_0x511812[_0x459c89('0xd03')]]&&(_0x292f6b[_0x459c89('0x2da')][_0x511812[_0x459c89('0xd03')]][_0x459c89('0x25a4')]+=0x1,_0x292f6b[_0x459c89('0x2da')][_0x511812['OpenchannelQueueId']][_0x459c89('0x756')][_0x511812[_0x459c89('0x10c5')]]=_0x511812['OpenchannelQueueId']);}function _0x46f2ca(_0x40ad7f){const _0x160bb5=_0x84c70a;console[_0x160bb5('0x1b2b')]('onLogout',_0x40ad7f),_0x292f6b[_0x160bb5('0x2da')][_0x40ad7f[_0x160bb5('0xd03')]]&&_0x292f6b['queues'][_0x40ad7f['OpenchannelQueueId']][_0x160bb5('0x25a4')]>0x0&&(_0x292f6b['queues'][_0x40ad7f[_0x160bb5('0xd03')]][_0x160bb5('0x25a4')]-=0x1,delete _0x292f6b[_0x160bb5('0x2da')][_0x40ad7f[_0x160bb5('0xd03')]][_0x160bb5('0x756')][_0x40ad7f[_0x160bb5('0x10c5')]]);}let _0x557689=!![],_0x4cd759=0x1;_0x42a59f[_0x84c70a('0x186d')]('vm.query.filter',function(_0x2d2346,_0x2fd0a8){const _0x538381=_0x84c70a;_0x557689?_0x56812a(function(){_0x557689=![];}):(!_0x2fd0a8&&(_0x4cd759=_0x292f6b[_0x538381('0x23a2')][_0x538381('0xdf8')]),_0x2d2346!==_0x2fd0a8&&(_0x292f6b['query'][_0x538381('0xdf8')]=0x1),!_0x2d2346&&(_0x292f6b['query'][_0x538381('0xdf8')]=_0x4cd759),_0x292f6b[_0x538381('0x4c9')]());});function _0x930e7b(_0x2c5481){const _0x2b8580=_0x84c70a;_0x292f6b[_0x2b8580('0x50d')]=_0x2c5481['count'],_0x292f6b[_0x2b8580('0x2da')]=_0x2c5481?_0x2e3ca0()[_0x2b8580('0x24db')](_0x2c5481[_0x2b8580('0xf5d')]?_0x2c5481[_0x2b8580('0xf5d')]:[],'id'):{};if(_0x2c5481[_0x2b8580('0xf5d')]){_0x292f6b['order']=[];for(let _0x40e6d7=0x0;_0x40e6d7<_0x2c5481[_0x2b8580('0xf5d')][_0x2b8580('0x1564')];_0x40e6d7++){_0x292f6b[_0x2b8580('0x150d')][_0x2b8580('0x1fd0')](_0x2c5481['rows'][_0x40e6d7]['id']);}}_0xd676dc();}function _0x376fa8(){const _0x736625=_0x84c70a;_0x292f6b[_0x736625('0x23a2')][_0x736625('0x1cc8')]=(_0x292f6b[_0x736625('0x23a2')][_0x736625('0xdf8')]-0x1)*_0x292f6b[_0x736625('0x23a2')]['limit'],_0x428927[_0x736625('0xca1')]('admin')?_0x292f6b['promise']=_0x390aae[_0x736625('0x20a1')][_0x736625('0x1e6e')](_0x292f6b[_0x736625('0x23a2')],_0x930e7b)['$promise']:(_0x292f6b[_0x736625('0x23a2')]['id']=_0x292f6b[_0x736625('0x2a')]['id'],_0x292f6b['query'][_0x736625('0x1aa')]=_0x736625('0x3da'),_0x292f6b['promise']=_0x390aae[_0x736625('0x2a')][_0x736625('0x241d')](_0x292f6b[_0x736625('0x23a2')],_0x930e7b)['$promise']);}function _0x8c6af9(_0x3e1c29,_0x3ebffa){const _0x34a06b=_0x84c70a;_0x12be90[_0x34a06b('0x1d4')]({'controller':_0x34a06b('0x263d'),'controllerAs':'vm','templateUrl':_0x281833,'parent':angular['element'](_0x47c9f5[_0x34a06b('0x18e5')]),'targetEvent':_0x3e1c29,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x3ebffa,'openchannelQueues':_0x2e3ca0()['values'](_0x292f6b[_0x34a06b('0x2da')]),'license':null,'setting':null,'crudPermissions':_0x292f6b[_0x34a06b('0x1134')]}});}function _0x535168(_0x2ea167,_0x5260a0){const _0x253a5f=_0x84c70a;_0x12be90['show']({'controller':_0x253a5f('0x116d'),'controllerAs':'vm','templateUrl':_0x11f391,'parent':angular[_0x253a5f('0x1fcc')](_0x47c9f5[_0x253a5f('0x18e5')]),'targetEvent':_0x2ea167,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x5260a0,'openchannelQueues':_0x292f6b[_0x253a5f('0x2da')]?_0x292f6b[_0x253a5f('0x2da')][_0x253a5f('0xf5d')]:[],'realtime':![],'crudPermissions':_0x292f6b[_0x253a5f('0x1134')]}});}function _0x566bcb(_0x4cb4cc){const _0x5f27b=_0x84c70a;return _0x390aae[_0x5f27b('0x20a1')][_0x5f27b('0x2480')](_0x4cb4cc)[_0x5f27b('0xe53')][_0x5f27b('0x683')](function(){const _0x2cf3fa=_0x5f27b;_0x34f101['success']({'title':_0x2cf3fa('0x5c7'),'msg':_0x4cb4cc[_0x2cf3fa('0x60a')]?_0x4cb4cc['name']+'\x20has\x20been\x20updated!':''});})[_0x5f27b('0x130a')](function(_0x1ae8bd){const _0x414f90=_0x5f27b;_0x34f101[_0x414f90('0x52a')]({'title':_0x414f90('0xb4'),'msg':_0x1ae8bd[_0x414f90('0x8c2')]});});}_0x42a59f[_0x84c70a('0x26a2')](_0x84c70a('0x4b8'),function(){const _0x4b5543=_0x84c70a;_0x28c2f7[_0x4b5543('0x1b9e')]('openchannel_queue:save'),_0x28c2f7['removeAllListeners'](_0x4b5543('0x6fd')),_0x28c2f7['removeAllListeners'](_0x4b5543('0x206')),_0x28c2f7[_0x4b5543('0x1b9e')](_0x4b5543('0x2719')),_0x28c2f7[_0x4b5543('0x1b9e')](_0x4b5543('0x56f')),_0x28c2f7[_0x4b5543('0x1b9e')](_0x4b5543('0x217c'));});}const _0x260f97=_0x3fac43;function _0x4cf3f8(){const _0x1d3728=_0x189033;return{'status':{'registered':_0x1d3728('0x584'),'unregistered':'red-300-fg\x20icon-close-circle','lagged':'red-300-fg\x20icon-close-circle','reachable':'green-300-fg\x20icon-checkbox-marked-circle','unreachable':'red-300-fg\x20icon-close-circle','unknown':_0x1d3728('0xcb0')},'state':{'unknown':_0x1d3728('0x27f9'),'not_inuse':_0x1d3728('0x280d'),'inuse':_0x1d3728('0x10c0'),'busy':_0x1d3728('0x25ad'),'invalid':_0x1d3728('0x27f9'),'unavailable':_0x1d3728('0x27f9'),'ringing':_0x1d3728('0x20f0'),'ringinuse':_0x1d3728('0x20f0'),'onhold':_0x1d3728('0x1a52')},'channelStatus':{'ring':_0x1d3728('0x20f0'),'up':'green-300-fg\x20icon-phone-in-talk','hangup':_0x1d3728('0x22be')},'channelStatusOut':{'ring':'blue-300-fg\x20icon-phone-outgoing','up':_0x1d3728('0x1133'),'hangup':_0x1d3728('0x22be')}};}const _0x19bb7d=_0x4cf3f8;_0x2e24d1[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'socket'];function _0x2e24d1(_0x4e7fdf,_0x4022c5,_0x12f7d9){const _0x5e7b3c=_0x189033,_0x46fd89=this;_0x12f7d9[_0x5e7b3c('0x1346')](),_0x12f7d9[_0x5e7b3c('0x12ac')](),_0x46fd89[_0x5e7b3c('0x517')]=0x0;switch(_0x4022c5['current']['name']){case _0x5e7b3c('0x219c'):_0x46fd89[_0x5e7b3c('0x517')]=0x0;break;case _0x5e7b3c('0x21d8'):_0x46fd89['selectedTab']=0x1;break;default:_0x46fd89[_0x5e7b3c('0x517')]=0x0,_0x4022c5['go'](_0x5e7b3c('0x219c'));}_0x4e7fdf[_0x5e7b3c('0x186d')]('vm.selectedTab',function(_0x1dcf28,_0x20366c){const _0x15fb76=_0x5e7b3c;if(_0x1dcf28!==_0x20366c)switch(_0x1dcf28){case 0x0:_0x4022c5['go']('app.openchannel.realtime.agents');break;case 0x1:_0x4022c5['go'](_0x15fb76('0x21d8'));break;default:_0x4022c5['go'](_0x15fb76('0x219c'));}});}const _0x2eb95c=_0x2e24d1;_0x3c50d8[_0x189033('0x14be')]=[_0x189033('0x1398')];function _0x3c50d8(_0x120d61){const _0x5de76f=_0x189033;_0x120d61[_0x5de76f('0x2598')](_0x5de76f('0x1ab0'),{'url':_0x5de76f('0xf7c'),'views':{'content@app':{'templateUrl':_0x39bb8b,'controller':_0x5de76f('0x7d8')}},'resolve':{'userProfile':['apiResolver',_0x5de76f('0xba1'),function(_0x1e9f98,_0x3d8118){const _0x294d94=_0x5de76f;return _0x3d8118['hasRole'](_0x294d94('0x20c2'))?null:_0x1e9f98[_0x294d94('0xed7')]('userProfile@get',{'fields':_0x294d94('0x16f'),'id':_0x3d8118[_0x294d94('0x20b2')]()[_0x294d94('0x2f')]});}],'userProfileSection':[_0x5de76f('0x4b1'),_0x5de76f('0xba1'),function(_0x58da39,_0x19b01c){const _0x2e86fc=_0x5de76f;return _0x19b01c['hasRole']('admin')?null:_0x58da39['resolve'](_0x2e86fc('0x360'),{'fields':_0x2e86fc('0x1f47'),'userProfileId':_0x19b01c['getCurrentUser']()[_0x2e86fc('0x2f')],'sectionId':0x32a});}]},'authenticate':!![],'permissionId':0x32a})[_0x5de76f('0x2598')]('app.openchannel.realtime.agents',{'url':_0x5de76f('0xf1a'),'controller':_0x5de76f('0xe20'),'templateUrl':_0x4594c3,'resolve':{'pauses':[_0x5de76f('0x4b1'),function(_0x8a5eb0){const _0x24f69a=_0x5de76f;return _0x8a5eb0[_0x24f69a('0xed7')](_0x24f69a('0x112'),{'nolimit':!![]});}],'agents':[_0x5de76f('0x4b1'),'Auth',function(_0x1cfa8f,_0x14e0bc){const _0x1c5d50=_0x5de76f;return _0x14e0bc[_0x1c5d50('0xca1')]('admin')?_0x1cfa8f[_0x1c5d50('0xed7')]('user@get',{'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0x1c5d50('0x2327'),'sort':_0x1c5d50('0x11bc'),'nolimit':!![]}):_0x1cfa8f[_0x1c5d50('0xed7')](_0x1c5d50('0x191b'),{'id':_0x14e0bc['getCurrentUser']()[_0x1c5d50('0x2f')],'section':'Agents','fields':_0x1c5d50('0x174e'),'role':'agent','sort':_0x1c5d50('0x11bc'),'nolimit':!![]});}],'userProfile':['apiResolver',_0x5de76f('0xba1'),function(_0xdefda2,_0x75b6e6){const _0x190373=_0x5de76f;return _0x75b6e6[_0x190373('0xca1')](_0x190373('0x20c2'))?null:_0xdefda2[_0x190373('0xed7')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x75b6e6[_0x190373('0x20b2')]()[_0x190373('0x2f')]});}],'userProfileSection':[_0x5de76f('0x4b1'),'Auth',function(_0x418a1b,_0x5dcd1a){const _0x29b00e=_0x5de76f;return _0x5dcd1a[_0x29b00e('0xca1')](_0x29b00e('0x20c2'))?null:_0x418a1b[_0x29b00e('0xed7')]('userProfileSection@get',{'fields':_0x29b00e('0x1f47'),'userProfileId':_0x5dcd1a[_0x29b00e('0x20b2')]()[_0x29b00e('0x2f')],'sectionId':0xca});}],'rpcAgents':[_0x5de76f('0x4b1'),function(_0x16ef9e){const _0x2d635c=_0x5de76f;return _0x16ef9e[_0x2d635c('0xed7')](_0x2d635c('0x36a'));}]},'authenticate':!![],'permissionId':0x32a})[_0x5de76f('0x2598')](_0x5de76f('0x21d8'),{'url':_0x5de76f('0x14a4'),'controller':'QueuesOpenchannelRealtimeController\x20as\x20vm','templateUrl':_0x3b9f80,'resolve':{'queues':[_0x5de76f('0x4b1'),_0x5de76f('0xba1'),function(_0x214bbe,_0x1cceaf){const _0x26135e=_0x5de76f;return _0x1cceaf[_0x26135e('0xca1')](_0x26135e('0x20c2'))?_0x214bbe[_0x26135e('0xed7')]('openchannelQueue@get',{'type':'inbound','sort':_0x26135e('0xc36'),'limit':0xa,'offset':0x0}):_0x214bbe['resolve']('userProfile@getResources',{'id':_0x1cceaf[_0x26135e('0x20b2')]()['userProfileId'],'section':_0x26135e('0x3da'),'channel':_0x26135e('0x1261'),'type':_0x26135e('0x1535'),'sort':_0x26135e('0xc36'),'limit':0xa,'page':0x1});}],'userProfile':[_0x5de76f('0x4b1'),_0x5de76f('0xba1'),function(_0x279246,_0x400f2f){const _0x158310=_0x5de76f;return _0x400f2f[_0x158310('0xca1')]('admin')?null:_0x279246[_0x158310('0xed7')]('userProfile@get',{'fields':_0x158310('0x16f'),'id':_0x400f2f[_0x158310('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x5de76f('0x4b1'),_0x5de76f('0xba1'),function(_0xa9d9ff,_0x3058ea){const _0x4c8b8c=_0x5de76f;return _0x3058ea['hasRole']('admin')?null:_0xa9d9ff[_0x4c8b8c('0xed7')]('userProfileSection@get',{'fields':_0x4c8b8c('0x1f47'),'userProfileId':_0x3058ea[_0x4c8b8c('0x20b2')]()['userProfileId'],'sectionId':0x321});}],'rpcQueues':[_0x5de76f('0x4b1'),function(_0x3407d0){const _0x3a0eb1=_0x5de76f;return _0x3407d0[_0x3a0eb1('0xed7')]('rpc@getOpenchannelQueues');}]},'authenticate':!![],'permissionId':0x32a});}angular[_0x189033('0x1e26')](_0x189033('0x1ab0'),[])[_0x189033('0x272d')](_0x3c50d8)[_0x189033('0x1da3')](_0x189033('0x3f5'),_0x488f56)[_0x189033('0x1da3')]('QueuesOpenchannelRealtimeController',_0x260f97)['factory'](_0x189033('0xa72'),_0x19bb7d)['controller'](_0x189033('0xe23'),_0x2eb95c);const _0x1c7e48=_0x180212['p']+'src/js/modules/main/apps/openchannel/views/openchannelQueues/openchannelQueues.html/openchannelQueues.html',_0x4ce45a=_0x180212['p']+_0x189033('0x26ff'),_0x1c030d=_0x180212['p']+_0x189033('0x53c'),_0x35d1cf=_0x180212['p']+_0x189033('0x180d');_0x126586[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1952'),_0x189033('0x1963'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x126586(_0x114eef,_0xe3383f,_0x1b66ea,_0x218c39,_0xd33d8,_0x4c2f2b,_0x2c1b1e,_0x17d71f,_0x2bffee,_0x2c308b,_0x492fe0,_0x2964eb,_0x39c0fa,_0x140cf6){const _0x435cd0=_0x189033,_0xef7a2b=this;_0xef7a2b['currentUser']=_0x492fe0[_0x435cd0('0x20b2')](),_0xef7a2b[_0x435cd0('0x17f')]=[],_0xef7a2b[_0x435cd0('0x260a')]=_0x39c0fa,_0xef7a2b[_0x435cd0('0xace')]=_0x2964eb,_0xef7a2b[_0x435cd0('0x1134')]=_0x140cf6,_0xef7a2b[_0x435cd0('0x258d')]={},_0xef7a2b[_0x435cd0('0x19b2')]=_0xef7a2b[_0x435cd0('0x260a')]&&_0xef7a2b['setting'][_0x435cd0('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xef7a2b[_0x435cd0('0xf28')]=_0x435cd0('0x215c'),_0xef7a2b[_0x435cd0('0x1963')]=angular[_0x435cd0('0x1a86')](_0x2bffee),_0xef7a2b[_0x435cd0('0x1952')]=_0x17d71f,_0xef7a2b[_0x435cd0('0x2720')]=![];!_0xef7a2b[_0x435cd0('0x1963')]&&(_0xef7a2b[_0x435cd0('0x1963')]={'waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0xef7a2b[_0x435cd0('0xf28')]='OPENCHANNEL.NEW_OPENCHANNELACCOUNT',_0xef7a2b[_0x435cd0('0x2720')]=!![]);_0xe3383f['params']['id']&&(_0xef7a2b[_0x435cd0('0x1963')][_0x435cd0('0x1061')]=_0xe3383f[_0x435cd0('0x7f2')]['id']);_0xef7a2b['addNewOpenchannelAccount']=_0x3afd6c,_0xef7a2b[_0x435cd0('0x339')]=_0x2dc3e0,_0xef7a2b[_0x435cd0('0x2400')]=_0x322ac9,_0xef7a2b[_0x435cd0('0x16b3')]=_0x1cae08,_0xef7a2b['closeDialog']=_0x4dc3f6,_0x492fe0[_0x435cd0('0xca1')](_0x435cd0('0x20c2'))?_0x2c308b['cmList']['get']({'fields':_0x435cd0('0xa10'),'sort':_0x435cd0('0x60a')})[_0x435cd0('0xe53')][_0x435cd0('0x683')](function(_0x1b7155){const _0x1efe23=_0x435cd0;_0xef7a2b[_0x1efe23('0xe01')]=_0x1b7155[_0x1efe23('0xf5d')]||[];})['catch'](function(_0x431318){const _0x4a3991=_0x435cd0;_0x2c1b1e[_0x4a3991('0x52a')]({'title':_0x431318[_0x4a3991('0x13ee')]?_0x4a3991('0x2168')+_0x431318[_0x4a3991('0x13ee')]+_0x4a3991('0xbf6')+_0x431318[_0x4a3991('0x24a9')]:'SYSTEM:GET_LISTS','msg':_0x431318[_0x4a3991('0x5a5')]?JSON['stringify'](_0x431318[_0x4a3991('0x5a5')]):_0x431318[_0x4a3991('0x1ff0')]()});}):_0x2c308b[_0x435cd0('0x259b')][_0x435cd0('0x1e6e')]({'fields':_0x435cd0('0xa10'),'sort':_0x435cd0('0x60a')})[_0x435cd0('0xe53')][_0x435cd0('0x683')](function(_0x3b6450){const _0x27499d=_0x435cd0;_0xef7a2b[_0x27499d('0xe01')]=_0x3b6450[_0x27499d('0xf5d')]||[];})[_0x435cd0('0x683')](function(){const _0x277f63=_0x435cd0;return _0x2c308b[_0x277f63('0x22df')][_0x277f63('0x1e6e')]({'userProfileId':_0xef7a2b[_0x277f63('0x11ed')][_0x277f63('0x2f')],'sectionId':0x12d})['$promise'];})[_0x435cd0('0x683')](function(_0x5648f1){const _0x48b4d9=_0x435cd0,_0x1eb33d=_0x5648f1&&_0x5648f1[_0x48b4d9('0xf5d')]?_0x5648f1[_0x48b4d9('0xf5d')][0x0]:null;if(!_0x1eb33d){const _0x10b682=[];let _0x459082=null;_0xef7a2b[_0x48b4d9('0x1963')]&&(_0x459082=_0x2e3ca0()[_0x48b4d9('0x1c07')](_0xef7a2b[_0x48b4d9('0xe01')],{'id':Number(_0xef7a2b[_0x48b4d9('0x1963')][_0x48b4d9('0x1e4f')])}));for(let _0x11c3a1=0x0;_0x11c3a1<_0xef7a2b[_0x48b4d9('0xe01')]['length'];_0x11c3a1++){_0x459082&&_0xef7a2b[_0x48b4d9('0xe01')][_0x11c3a1]['id']===_0x459082['id']&&(_0xef7a2b[_0x48b4d9('0xe01')][_0x11c3a1]['canSelect']=![],_0x10b682[_0x48b4d9('0x1fd0')](_0xef7a2b[_0x48b4d9('0xe01')][_0x11c3a1]));}_0xef7a2b[_0x48b4d9('0xe01')]=_0x10b682;}else{if(!_0x1eb33d[_0x48b4d9('0x170')])return _0x2c308b[_0x48b4d9('0xcf7')]['get']({'sectionId':_0x1eb33d['id']})['$promise'][_0x48b4d9('0x683')](function(_0x41fe86){const _0x4ce6fa=_0x48b4d9,_0x558d81=_0x2e3ca0()[_0x4ce6fa('0x386')](_0x41fe86[_0x4ce6fa('0xf5d')],function(_0x489cb1){const _0x31c8c0=_0x4ce6fa;return _0x2e3ca0()['find'](_0xef7a2b[_0x31c8c0('0xe01')],{'id':_0x489cb1['resourceId']});});let _0x975d2d=null;_0xef7a2b[_0x4ce6fa('0x1963')]&&(_0x975d2d=_0x2e3ca0()[_0x4ce6fa('0x1c07')](_0xef7a2b[_0x4ce6fa('0xe01')],{'id':Number(_0xef7a2b['openchannelAccount'][_0x4ce6fa('0x1e4f')])}));if(_0x975d2d&&!_0x2e3ca0()[_0x4ce6fa('0x7a2')](_0x558d81,['id',_0x975d2d['id']])){const _0x26c6ff=_0x2e3ca0()[_0x4ce6fa('0x1c07')](_0xef7a2b[_0x4ce6fa('0xe01')],{'id':_0x975d2d['id']});_0x26c6ff[_0x4ce6fa('0x319')]=![],_0x558d81[_0x4ce6fa('0x1fd0')](_0x26c6ff);}_0xef7a2b[_0x4ce6fa('0xe01')]=_0x558d81;});}})[_0x435cd0('0x130a')](function(_0xabcb0b){const _0x52803c=_0x435cd0;_0x2c1b1e[_0x52803c('0x52a')]({'title':_0xabcb0b['status']?_0x52803c('0x2168')+_0xabcb0b[_0x52803c('0x13ee')]+_0x52803c('0xbf6')+_0xabcb0b[_0x52803c('0x24a9')]:_0x52803c('0x11e3'),'msg':_0xabcb0b[_0x52803c('0x5a5')]?JSON[_0x52803c('0x258a')](_0xabcb0b[_0x52803c('0x5a5')]):_0xabcb0b[_0x52803c('0x1ff0')]()});});function _0x3afd6c(){const _0x388dac=_0x435cd0;_0xef7a2b[_0x388dac('0x17f')]=[],_0x2c308b[_0x388dac('0x1963')][_0x388dac('0xb0a')](_0xef7a2b['openchannelAccount'])['$promise'][_0x388dac('0x683')](function(_0x2daddb){const _0xf569b4=_0x388dac;_0xef7a2b['openchannelAccounts'][_0xf569b4('0x1167')](_0x2daddb[_0xf569b4('0x24e1')]()),_0x2c1b1e[_0xf569b4('0x53')]({'title':_0xf569b4('0x12a'),'msg':_0xef7a2b[_0xf569b4('0x1963')]['name']?_0xef7a2b[_0xf569b4('0x1963')][_0xf569b4('0x60a')]+'\x20has\x20been\x20created!':''}),_0x4dc3f6(_0x2daddb);})[_0x388dac('0x130a')](function(_0x2a317c){const _0x5a5c48=_0x388dac;if(_0x2a317c[_0x5a5c48('0x5a5')]&&_0x2a317c[_0x5a5c48('0x5a5')][_0x5a5c48('0x17f')]&&_0x2a317c[_0x5a5c48('0x5a5')][_0x5a5c48('0x17f')]['length']){_0xef7a2b[_0x5a5c48('0x17f')]=_0x2a317c[_0x5a5c48('0x5a5')][_0x5a5c48('0x17f')]||[{'message':_0x2a317c[_0x5a5c48('0x1ff0')](),'type':_0x5a5c48('0x1c5d')}];for(let _0x42a93d=0x0;_0x42a93d<_0x2a317c[_0x5a5c48('0x5a5')][_0x5a5c48('0x17f')][_0x5a5c48('0x1564')];_0x42a93d+=0x1){_0x2c1b1e[_0x5a5c48('0x52a')]({'title':_0x2a317c['data'][_0x5a5c48('0x17f')][_0x42a93d][_0x5a5c48('0xcf0')],'msg':_0x2a317c['data'][_0x5a5c48('0x17f')][_0x42a93d][_0x5a5c48('0x8c2')]});}}else _0x2c1b1e[_0x5a5c48('0x52a')]({'title':_0x2a317c['status']?_0x5a5c48('0x2168')+_0x2a317c[_0x5a5c48('0x13ee')]+_0x5a5c48('0xbf6')+_0x2a317c[_0x5a5c48('0x24a9')]:_0x5a5c48('0x1c5d'),'msg':_0x2a317c['data']?JSON[_0x5a5c48('0x258a')](_0x2a317c[_0x5a5c48('0x5a5')]['message']):_0x2a317c[_0x5a5c48('0x1ff0')]()});});}function _0x2dc3e0(){const _0x13b61c=_0x435cd0;_0xef7a2b[_0x13b61c('0x17f')]=[],_0x2c308b['openchannelAccount']['update']({'id':_0xef7a2b[_0x13b61c('0x1963')]['id']},_0xef7a2b[_0x13b61c('0x1963')])[_0x13b61c('0xe53')]['then'](function(_0x1c36c9){const _0x1dac9d=_0x13b61c,_0x5becd4=_0x2e3ca0()[_0x1dac9d('0x1c07')](_0xef7a2b[_0x1dac9d('0x1952')],{'id':_0x1c36c9['id']});_0x5becd4&&_0x2e3ca0()['merge'](_0x5becd4,_0x2e3ca0()[_0x1dac9d('0x24d0')](_0x1c36c9[_0x1dac9d('0x24e1')](),_0x2e3ca0()[_0x1dac9d('0x55e')](_0x5becd4))),_0x2c1b1e[_0x1dac9d('0x53')]({'title':_0x1dac9d('0x17e7'),'msg':_0xef7a2b[_0x1dac9d('0x1963')][_0x1dac9d('0x60a')]?_0xef7a2b[_0x1dac9d('0x1963')][_0x1dac9d('0x60a')]+_0x1dac9d('0xf59'):''}),_0x4dc3f6(_0x1c36c9);})['catch'](function(_0x3e470b){const _0x586081=_0x13b61c;if(_0x3e470b['data']&&_0x3e470b[_0x586081('0x5a5')]['errors']&&_0x3e470b[_0x586081('0x5a5')][_0x586081('0x17f')][_0x586081('0x1564')]){_0xef7a2b[_0x586081('0x17f')]=_0x3e470b[_0x586081('0x5a5')][_0x586081('0x17f')]||[{'message':_0x3e470b[_0x586081('0x1ff0')](),'type':_0x586081('0x18a5')}];for(let _0x293afe=0x0;_0x293afe<_0x3e470b[_0x586081('0x5a5')][_0x586081('0x17f')]['length'];_0x293afe++){_0x2c1b1e[_0x586081('0x52a')]({'title':_0x3e470b[_0x586081('0x5a5')][_0x586081('0x17f')][_0x293afe]['type'],'msg':_0x3e470b[_0x586081('0x5a5')][_0x586081('0x17f')][_0x293afe][_0x586081('0x8c2')]});}}else _0x2c1b1e['error']({'title':_0x3e470b[_0x586081('0x13ee')]?_0x586081('0x2168')+_0x3e470b[_0x586081('0x13ee')]+_0x586081('0xbf6')+_0x3e470b[_0x586081('0x24a9')]:_0x586081('0x18a5'),'msg':_0x3e470b[_0x586081('0x5a5')]?JSON[_0x586081('0x258a')](_0x3e470b['data'][_0x586081('0x8c2')]):_0x3e470b[_0x586081('0x1ff0')]()});});}function _0x322ac9(_0x278201){const _0x811689=_0x435cd0;_0xef7a2b[_0x811689('0x17f')]=[];const _0x4d1a0b=_0x218c39[_0x811689('0x1c6f')]()['title'](_0x811689('0x4d'))[_0x811689('0xa6a')]('The\x20openchannelAccount\x20will\x20be\x20deleted.')[_0x811689('0x1040')](_0x811689('0x2073'))['ok']('Delete')[_0x811689('0x19fb')](_0x811689('0x253a'))[_0x811689('0xe42')](_0x278201);_0x218c39[_0x811689('0x1d4')](_0x4d1a0b)[_0x811689('0x683')](function(){const _0x28f31a=_0x811689;_0x2c308b['openchannelAccount']['delete']({'id':_0xef7a2b[_0x28f31a('0x1963')]['id']})[_0x28f31a('0xe53')][_0x28f31a('0x683')](function(){const _0x23f9ab=_0x28f31a;_0x2e3ca0()[_0x23f9ab('0x3ec')](_0xef7a2b[_0x23f9ab('0x1952')],{'id':_0xef7a2b[_0x23f9ab('0x1963')]['id']}),_0x2c1b1e[_0x23f9ab('0x53')]({'title':_0x23f9ab('0x2683'),'msg':(_0xef7a2b[_0x23f9ab('0x1963')][_0x23f9ab('0x60a')]||_0x23f9ab('0x1963'))+_0x23f9ab('0x194d')}),_0x4dc3f6(_0xef7a2b[_0x23f9ab('0x1963')]);})['catch'](function(_0xaa49ba){const _0xd7ea3d=_0x28f31a;if(_0xaa49ba[_0xd7ea3d('0x5a5')]&&_0xaa49ba['data'][_0xd7ea3d('0x17f')]&&_0xaa49ba['data'][_0xd7ea3d('0x17f')][_0xd7ea3d('0x1564')]){_0xef7a2b[_0xd7ea3d('0x17f')]=_0xaa49ba[_0xd7ea3d('0x5a5')][_0xd7ea3d('0x17f')]||[{'message':_0xaa49ba[_0xd7ea3d('0x1ff0')](),'type':_0xd7ea3d('0x7c1')}];for(let _0x1d0d17=0x0;_0x1d0d17<_0xaa49ba[_0xd7ea3d('0x5a5')][_0xd7ea3d('0x17f')][_0xd7ea3d('0x1564')];_0x1d0d17++){_0x2c1b1e[_0xd7ea3d('0x52a')]({'title':_0xaa49ba[_0xd7ea3d('0x5a5')][_0xd7ea3d('0x17f')][_0x1d0d17]['type'],'msg':_0xaa49ba[_0xd7ea3d('0x5a5')]['errors'][_0x1d0d17][_0xd7ea3d('0x8c2')]});}}else _0x2c1b1e['error']({'title':_0xaa49ba[_0xd7ea3d('0x13ee')]?'API:'+_0xaa49ba[_0xd7ea3d('0x13ee')]+_0xd7ea3d('0xbf6')+_0xaa49ba[_0xd7ea3d('0x24a9')]:_0xd7ea3d('0x7c1'),'msg':_0xaa49ba[_0xd7ea3d('0x5a5')]?JSON['stringify'](_0xaa49ba[_0xd7ea3d('0x5a5')]['message']):_0xaa49ba[_0xd7ea3d('0x8c2')]||_0xaa49ba[_0xd7ea3d('0x1ff0')]()});});},function(){});}function _0x1cae08(_0x4c2122){return _0x4c2122===null?undefined:new Date(_0x4c2122);}function _0x4dc3f6(_0x4f2fe1){const _0xdc8eff=_0x435cd0;_0x218c39[_0xdc8eff('0x1715')](_0x4f2fe1);}}const _0x41f723=_0x126586,_0x419022=_0x180212['p']+_0x189033('0x22b3'),_0x401088=_0x180212['p']+_0x189033('0x14a9'),_0x108f7d=_0x180212['p']+_0x189033('0x283a'),_0x2970b0=_0x180212['p']+_0x189033('0x471'),_0x30f1d6=_0x180212['p']+_0x189033('0x212d'),_0x1c7473=_0x180212['p']+_0x189033('0x2064'),_0x4b2dcd=_0x180212['p']+_0x189033('0x1ae3'),_0x4db9d7=_0x180212['p']+_0x189033('0x1b95'),_0x36c28b=_0x180212['p']+'src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/apps/system/dialog.html/dialog.html',_0x21563b=_0x180212['p']+'src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/apps/tag/dialog.html/dialog.html';_0x5821a1[_0x189033('0x14be')]=[_0x189033('0x56b'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0xba1')];const _0x4e967b={'agent':_0x419022,'autoreply':_0x401088,'close':_0x108f7d,'gotoif':_0x2970b0,'gotop':_0x30f1d6,'interval':_0x1c7473,'noop':_0x4b2dcd,'queue':_0x4db9d7,'system':_0x36c28b,'tag':_0x21563b};function _0x5821a1(_0x1cd14a,_0xf0c399,_0x2d64e8,_0x1badcd,_0x856f1){const _0x5241ca=_0x189033,_0x50145e=this;_0x50145e[_0x5241ca('0x11ed')]=_0x856f1[_0x5241ca('0x20b2')](),_0x50145e[_0x5241ca('0x1963')]={},_0x50145e[_0x5241ca('0x11ff')]={'count':0x0,'rows':[]},_0x50145e[_0x5241ca('0x23b')]=[],_0x50145e[_0x5241ca('0x1134')],_0x50145e['query']={'sort':'priority'},_0x50145e[_0x5241ca('0x346')]=_0x2e3ca0()[_0x5241ca('0xfae')](_0x2e3ca0()[_0x5241ca('0x742')]([{'app':_0x5241ca('0x205c'),'appType':_0x5241ca('0x205c'),'type':_0x5241ca('0x205c'),'icon':_0x5241ca('0x7ee'),'interval':_0x5241ca('0x1b54'),'isApp':!![],'fields':[{'title':'Key','name':_0x5241ca('0x1d46'),'type':_0x5241ca('0x1bcd'),'required':!![],'param':0x0},{'title':_0x5241ca('0x1a1c'),'name':_0x5241ca('0x1a1c'),'type':_0x5241ca('0xb31'),'defaultValue':'\x27en\x27','values':[{'option':_0x5241ca('0x17d9'),'value':_0x5241ca('0x1e18')},{'option':_0x5241ca('0xf48'),'value':_0x5241ca('0x1adc')},{'option':'German','value':_0x5241ca('0x1e33')},{'option':'Italian','value':_0x5241ca('0x1955')},{'option':_0x5241ca('0xbe9'),'value':'\x27es\x27'},{'option':_0x5241ca('0x51a'),'value':_0x5241ca('0x1869')},{'option':_0x5241ca('0x9ec'),'value':'\x27id\x27'},{'option':_0x5241ca('0x1abb'),'value':_0x5241ca('0x1505')},{'option':_0x5241ca('0x4b5'),'value':_0x5241ca('0x9d3')},{'option':_0x5241ca('0xe03'),'value':_0x5241ca('0x730')},{'option':_0x5241ca('0x1e53'),'value':_0x5241ca('0x23ca')},{'option':_0x5241ca('0x15d9'),'value':'\x27pt\x27'},{'option':_0x5241ca('0x521'),'value':_0x5241ca('0xc58')},{'option':_0x5241ca('0x103e'),'value':'\x27ru\x27'},{'option':'Swedish','value':'\x27sv\x27'},{'option':_0x5241ca('0xbc'),'value':'\x27th\x27'},{'option':'Ukrainian','value':_0x5241ca('0x2e0')},{'option':'Chinese\x20(Simplified)','value':_0x5241ca('0x2562')},{'option':_0x5241ca('0xc60'),'value':_0x5241ca('0x1802')},{'option':_0x5241ca('0x700'),'value':_0x5241ca('0x1dc')}],'required':!![],'param':0x1},{'title':_0x5241ca('0x6d9'),'name':'welcomemessage','type':'textarea','maxlength':0xff,'required':![],'param':0x2,'help':!![]}]},{'app':_0x5241ca('0x1d62'),'appType':_0x5241ca('0xd24'),'type':_0x5241ca('0xd24'),'icon':_0x5241ca('0x7ee'),'interval':_0x5241ca('0x1b54'),'isApp':!![],'fields':[{'title':_0x5241ca('0x1e7d'),'name':_0x5241ca('0x2119'),'type':_0x5241ca('0x1bcd'),'required':!![],'param':0x0},{'title':_0x5241ca('0x97c'),'name':'clientEmail','type':_0x5241ca('0x1bcd'),'required':!![],'param':0x1},{'title':'PrivateKey','name':_0x5241ca('0x406'),'type':'textarea','required':!![],'param':0x2},{'title':_0x5241ca('0x1a1c'),'name':_0x5241ca('0x1a1c'),'type':'select','defaultValue':_0x5241ca('0x1adc'),'values':[{'value':_0x5241ca('0x1802'),'option':'Chinese\x20(Cantonese)'},{'value':_0x5241ca('0x2562'),'option':_0x5241ca('0x277f')},{'value':_0x5241ca('0x1dc'),'option':'Chinese\x20(Traditional)'},{'value':'\x27da\x27','option':_0x5241ca('0x17d9')},{'value':_0x5241ca('0x730'),'option':_0x5241ca('0xe03')},{'value':_0x5241ca('0x1adc'),'option':_0x5241ca('0xf48')},{'value':_0x5241ca('0x6dd'),'option':_0x5241ca('0xbc1')},{'value':'\x27en-CA\x27','option':'English\x20(Canada)'},{'value':'\x27en-GB\x27','option':_0x5241ca('0x1e8')},{'value':_0x5241ca('0x2303'),'option':_0x5241ca('0xa57')},{'value':_0x5241ca('0x95d'),'option':'English\x20(US)'},{'value':_0x5241ca('0x1869'),'option':_0x5241ca('0x51a')},{'value':_0x5241ca('0x8df'),'option':'French\x20(Canada)'},{'value':_0x5241ca('0x2371'),'option':_0x5241ca('0xcad')},{'value':'\x27de\x27','option':_0x5241ca('0x118e')},{'value':'\x27hi\x27','option':'Hindi'},{'value':'\x27id\x27','option':'Indonesian'},{'value':_0x5241ca('0x1955'),'option':_0x5241ca('0x2217')},{'value':'\x27ja\x27','option':_0x5241ca('0x1abb')},{'value':'\x27ko\x27','option':_0x5241ca('0x233a')},{'value':_0x5241ca('0x23ca'),'option':_0x5241ca('0x1e53')},{'value':_0x5241ca('0x24cb'),'option':_0x5241ca('0x10a7')},{'value':_0x5241ca('0x1642'),'option':_0x5241ca('0x15b3')},{'value':_0x5241ca('0x64c'),'option':_0x5241ca('0x1876')},{'value':_0x5241ca('0xb56'),'option':_0x5241ca('0x103e')},{'value':_0x5241ca('0xd34'),'option':_0x5241ca('0xbe9')},{'value':'\x27es-419\x27','option':_0x5241ca('0x1e41')},{'value':'\x27es-ES\x27','option':_0x5241ca('0x208e')},{'value':'\x27sw\x27','option':_0x5241ca('0x1ff5')},{'value':_0x5241ca('0x15a8'),'option':'Thai'},{'value':'\x27tr\x27','option':_0x5241ca('0x17b0')},{'value':_0x5241ca('0x2e0'),'option':_0x5241ca('0x965')}],'required':!![],'param':0x3},{'title':_0x5241ca('0x6d9'),'name':_0x5241ca('0x6d9'),'type':_0x5241ca('0x24be'),'maxlength':0xff,'param':0x4,'help':!![]}]},{'app':_0x5241ca('0x1db1'),'appType':_0x5241ca('0x1db1'),'type':_0x5241ca('0x1db1'),'icon':'icon-apps','interval':_0x5241ca('0x1b54'),'isApp':!![],'fields':[{'title':_0x5241ca('0x7ae'),'name':_0x5241ca('0x7ae'),'type':_0x5241ca('0x1bcd'),'required':!![],'param':0x0},{'title':_0x5241ca('0x204a'),'name':_0x5241ca('0x204a'),'type':_0x5241ca('0x1bcd'),'required':!![],'param':0x1},{'title':_0x5241ca('0x5ba'),'name':_0x5241ca('0x5ba'),'type':_0x5241ca('0xb31'),'defaultValue':_0x5241ca('0x1924'),'values':[{'option':_0x5241ca('0x260e'),'value':_0x5241ca('0x1924')},{'option':_0x5241ca('0xc2b'),'value':'\x27us-west-2\x27'},{'option':'EU\x20(Ireland)','value':_0x5241ca('0x17db')},{'option':_0x5241ca('0x15b6'),'value':_0x5241ca('0xc6')}],'required':!![],'param':0x2},{'title':_0x5241ca('0x11a9'),'name':_0x5241ca('0x11a9'),'type':_0x5241ca('0x1bcd'),'required':!![],'param':0x3},{'title':'welcomemessage','name':'welcomemessage','type':_0x5241ca('0x24be'),'maxlength':0xff,'required':![],'param':0x4,'help':!![]}]},{'app':'Interval','appType':_0x5241ca('0x115c'),'types':[_0x5241ca('0x10af'),_0x5241ca('0xbf0'),_0x5241ca('0x2335')],'fields':[],'isApp':![]},{'app':_0x5241ca('0x1126'),'appType':_0x5241ca('0x1126'),'type':_0x5241ca('0x1126'),'icon':_0x5241ca('0x7ee'),'interval':'*,*,*,*','required':!![],'isApp':!![],'fields':[{'title':_0x5241ca('0x75d'),'name':_0x5241ca('0x1c6b'),'type':'text','param':0x0}]},{'app':_0x5241ca('0x24f2'),'appType':_0x5241ca('0x24f2'),'type':_0x5241ca('0x24f2'),'icon':_0x5241ca('0x7ee'),'interval':_0x5241ca('0x1b54'),'required':!![],'isApp':!![],'extraApi':[{'name':'variables','field':{'name':_0x5241ca('0x26e0'),'key':'name'},'route':_0x5241ca('0x26e0'),'filters':{'fields':_0x5241ca('0xa10'),'sort':_0x5241ca('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':'Command','name':_0x5241ca('0x6db'),'type':_0x5241ca('0x1bcd'),'required':!![],'param':0x0},{'title':'Variable','name':_0x5241ca('0x26e0'),'type':'apiselect','values':_0x5241ca('0x220b'),'value':_0x5241ca('0x2277'),'option':_0x5241ca('0x2277'),'defaultValues':[{'value':'\x27\x27','option':'None'}],'defaultValue':'\x27\x27','param':0x1}]},{'app':_0x5241ca('0x1da0'),'appType':_0x5241ca('0x1da0'),'type':_0x5241ca('0x27fe'),'icon':'icon-apps','interval':_0x5241ca('0x1b54'),'isApp':!![],'fields':[{'title':'Priority','name':'priority','type':_0x5241ca('0x121f'),'required':!![],'min':0x0,'param':0x0}]},{'app':_0x5241ca('0xc33'),'appType':_0x5241ca('0xc33'),'type':_0x5241ca('0xc33'),'icon':_0x5241ca('0x7ee'),'interval':_0x5241ca('0x1b54'),'isApp':!![],'fields':[{'title':'Condition','name':_0x5241ca('0x168e'),'type':_0x5241ca('0x1bcd'),'required':!![],'param':0x0},{'title':'truepriority','name':_0x5241ca('0x27e5'),'type':_0x5241ca('0x121f'),'min':0x1,'required':!![],'param':0x1},{'title':_0x5241ca('0x1813'),'name':'falsepriority','type':_0x5241ca('0x121f'),'min':0x1,'required':!![],'param':0x2}]},{'app':_0x5241ca('0x660'),'appType':'queue','foreignKey':_0x5241ca('0xd03'),'type':_0x5241ca('0x660'),'icon':_0x5241ca('0x7ee'),'interval':_0x5241ca('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x5241ca('0x2da'),'field':{'name':_0x5241ca('0x660'),'key':_0x5241ca('0x60a')},'route':_0x5241ca('0x20a1'),'filters':{'fields':_0x5241ca('0x2035'),'sort':_0x5241ca('0x60a'),'nolimit':!![]},'permissions':{'section':0x321}}],'fields':[{'title':_0x5241ca('0x1fa'),'name':_0x5241ca('0x660'),'type':_0x5241ca('0x1aae'),'values':_0x5241ca('0x2da'),'value':'queue.name','option':_0x5241ca('0x2543'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':_0x5241ca('0xa09'),'name':_0x5241ca('0x1668'),'type':_0x5241ca('0x121f'),'max':0x20c49b,'min':0x0,'defaultValue':0x12c,'required':!![],'param':0x1}]},{'app':_0x5241ca('0x2327'),'appType':'agent','type':'agent','foreignKey':_0x5241ca('0x10c5'),'icon':_0x5241ca('0x7ee'),'interval':_0x5241ca('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x5241ca('0x756'),'field':{'name':'agent','key':_0x5241ca('0x60a')},'route':_0x5241ca('0xc96'),'filters':{'fields':'id,name','sort':'name','role':_0x5241ca('0x2327'),'nolimit':!![]},'permissions':{'section':0xca}}],'fields':[{'title':_0x5241ca('0x62c'),'name':'agent','type':_0x5241ca('0x1aae'),'values':_0x5241ca('0x756'),'value':_0x5241ca('0x1ed0'),'option':_0x5241ca('0x1ed0'),'required':!![],'param':0x0},{'title':_0x5241ca('0xa09'),'name':_0x5241ca('0x1668'),'type':_0x5241ca('0x121f'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':_0x5241ca('0x2408'),'appType':_0x5241ca('0x2408'),'type':_0x5241ca('0x2408'),'icon':'icon-apps','interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x5241ca('0x35'),'name':'times','type':_0x5241ca('0xb31'),'defaultValue':'1','values':[{'option':'One\x20Time','value':'1'},{'option':'Always','value':'0'}],'required':!![],'param':0x0},{'title':_0x5241ca('0x1d8c'),'name':_0x5241ca('0x1bcd'),'type':_0x5241ca('0x24be'),'required':!![],'param':0x1}]},{'app':'close','appType':_0x5241ca('0x12b0'),'type':_0x5241ca('0x12b0'),'icon':'icon-apps','interval':_0x5241ca('0x1b54'),'isApp':!![],'fields':[{'title':'Disposition','name':_0x5241ca('0x43f'),'type':_0x5241ca('0x1bcd'),'required':!![],'param':0x0}]},{'app':'tag','appType':'tag','type':_0x5241ca('0x270'),'foreignKey':_0x5241ca('0xb6d'),'icon':_0x5241ca('0x7ee'),'interval':_0x5241ca('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x5241ca('0x1ce6'),'field':{'name':_0x5241ca('0x270'),'key':_0x5241ca('0x60a')},'route':_0x5241ca('0x270'),'filters':{'fields':_0x5241ca('0xa10'),'sort':_0x5241ca('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x5241ca('0x1e'),'name':_0x5241ca('0x270'),'type':'apiselect','values':_0x5241ca('0x1ce6'),'value':_0x5241ca('0x1402'),'option':'tag.name','required':!![],'param':0x0}]}],[_0x5241ca('0x1d75')]),{'isApp':![]}),_0x50145e[_0x5241ca('0x2335')]={'group':{'name':_0x5241ca('0x11bf'),'pull':_0x5241ca('0x147f')},'animation':0x64,'sort':![]},_0x50145e[_0x5241ca('0x2146')]={'group':{'name':'opt2','put':_0x5241ca('0x11bf')},'animation':0x64,'onAdd':function(_0x86eafe){const _0x30155f=_0x5241ca;_0x1bfb0a(_0x86eafe,_0x86eafe[_0x30155f('0x1ce1')]);},'onSort':function(){_0xe3612();}},_0x50145e['init']=_0x3e3afb,_0x50145e[_0x5241ca('0x26eb')]=_0x1e78c7,_0x50145e[_0x5241ca('0xd')]=_0x4fb439,_0x50145e[_0x5241ca('0x19f0')]=_0x1bfb0a,_0x50145e[_0x5241ca('0x24f7')]=_0x18b8e9,_0x50145e[_0x5241ca('0x8e0')]=_0x52273c,_0x50145e[_0x5241ca('0x1492')]=_0x3c91ae,_0x50145e['rewriteRouting']=_0xe3612,_0x50145e[_0x5241ca('0x14a')]=_0x3e3bdf;function _0x3e3afb(_0x544e9f,_0x5ac871){const _0x4db3b5=_0x5241ca;_0x50145e[_0x4db3b5('0x1963')]=_0x544e9f,_0x50145e[_0x4db3b5('0x1134')]=typeof _0x5ac871!=='undefined'?_0x5ac871:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x50145e[_0x4db3b5('0x2146')][_0x4db3b5('0x120b')]=!_0x50145e['crudPermissions'][_0x4db3b5('0x1978')]?!![]:![],_0x50145e[_0x4db3b5('0x23a2')]['id']=_0x544e9f['id'],_0x50145e[_0x4db3b5('0x23a2')][_0x4db3b5('0x12a8')]=!![],_0x50145e['query'][_0x4db3b5('0x2088')]=!![],_0x50145e['getOpenchannelAccountApps'](),_0x50145e[_0x4db3b5('0x14a')]();}function _0x1e78c7(_0x291b31,_0x2a7fc9,_0x470a4b){const _0x2cc6d8=_0x5241ca,_0x12f10f=_0xf0c399[_0x2cc6d8('0x1c6f')]()[_0x2cc6d8('0xf28')](_0x2cc6d8('0x421'))[_0x2cc6d8('0x26e3')](_0x2cc6d8('0xed5')+_0x291b31[_0x2cc6d8('0x1d75')]+_0x2cc6d8('0x20f1')+_0x2cc6d8('0x1ee7'))['ariaLabel']('delete\x20application')['targetEvent'](_0x470a4b)['ok']('OK')[_0x2cc6d8('0x19fb')](_0x2cc6d8('0x16b8'));_0xf0c399[_0x2cc6d8('0x1d4')](_0x12f10f)[_0x2cc6d8('0x683')](function(){const _0x5e7bd9=_0x2cc6d8;_0x50145e[_0x5e7bd9('0x11ff')][_0x5e7bd9('0xf5d')][_0x5e7bd9('0x2040')](_0x2a7fc9,0x1),_0xe3612();},function(){console['log']('CANCEL');});}function _0x1bfb0a(_0x3f39b4,_0x3a33ff){const _0x46e62e=_0x5241ca;if(_0x50145e[_0x46e62e('0x11ff')][_0x46e62e('0xf5d')]['length']){const _0x1cdba0=_0x50145e[_0x46e62e('0x11ff')][_0x46e62e('0xf5d')][_0x3a33ff]?_0x50145e[_0x46e62e('0x11ff')][_0x46e62e('0xf5d')][_0x3a33ff]:_0x50145e[_0x46e62e('0x11ff')][_0x46e62e('0xf5d')][0x0],_0x562973=(_0x1cdba0['appType']||_0x1cdba0[_0x46e62e('0x1d75')])['toLowerCase']();_0xf0c399[_0x46e62e('0x1d4')]({'controller':_0x46e62e('0x131')+_0x562973+_0x46e62e('0x9e4'),'controllerAs':'vm','templateUrl':_0x4e967b[_0x562973],'parent':angular[_0x46e62e('0x1fcc')](_0x2d64e8[_0x46e62e('0x18e5')]),'targetEvent':_0x3f39b4,'clickOutsideToClose':!![],'locals':{'openchannelAccountApp':_0x1cdba0,'openchannelAccount':_0x50145e[_0x46e62e('0x1963')],'crudPermissions':_0x50145e['crudPermissions']}})['then'](function(_0x4f4be8){const _0x3877c7=_0x46e62e;_0x4f4be8&&(_0x4f4be8['id']?_0x50145e[_0x3877c7('0x11ff')][_0x3877c7('0xf5d')][_0x3a33ff]=_0x4f4be8:_0x50145e[_0x3877c7('0x11ff')][_0x3877c7('0xf5d')][_0x3877c7('0x2040')](_0x3a33ff,0x0,_0x4f4be8),_0xe3612());})[_0x46e62e('0x130a')](function(_0x2eaaed){const _0x1b6982=_0x46e62e;_0x2eaaed&&_0x1badcd[_0x1b6982('0x52a')]({'title':_0x2eaaed[_0x1b6982('0x13ee')]?_0x1b6982('0x2168')+_0x2eaaed[_0x1b6982('0x13ee')]+_0x1b6982('0xbf6')+_0x2eaaed['statusText']:_0x1b6982('0xf1b'),'msg':_0x2eaaed[_0x1b6982('0x5a5')]?JSON[_0x1b6982('0x258a')](_0x2eaaed[_0x1b6982('0x5a5')]):_0x2eaaed[_0x1b6982('0x1ff0')]()});});}}function _0x18b8e9(_0x3497f4,_0x4d0cb5){const _0x3e3462=_0x5241ca;if(_0x50145e[_0x3e3462('0x11ff')][_0x3e3462('0xf5d')][_0x3e3462('0x1564')]){const _0x5e4c95=_0x50145e[_0x3e3462('0x11ff')][_0x3e3462('0xf5d')][_0x4d0cb5]?_0x50145e[_0x3e3462('0x11ff')][_0x3e3462('0xf5d')][_0x4d0cb5]:_0x50145e[_0x3e3462('0x11ff')][_0x3e3462('0xf5d')][0x0];_0xf0c399['show']({'controller':_0x3e3462('0x18ee'),'controllerAs':'vm','templateUrl':_0x1c7473,'parent':angular[_0x3e3462('0x1fcc')](_0x2d64e8[_0x3e3462('0x18e5')]),'targetEvent':_0x3497f4,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x5e4c95[_0x3e3462('0x115c')],'IntervalId':_0x5e4c95[_0x3e3462('0x5ae')],'application':!![]},'intervals':[],'crudPermissions':_0x50145e[_0x3e3462('0x1134')]}})['then'](function(_0x5a83a7){const _0x3406f6=_0x3e3462;_0x5a83a7&&(_0x5e4c95[_0x3406f6('0x115c')]=_0x5a83a7['interval']||_0x3406f6('0x1b54'),_0x5e4c95['IntervalId']=_0x5a83a7[_0x3406f6('0x5ae')]||null,_0xe3612());});}}function _0xe3612(){const _0x4e1257=_0x5241ca;let _0x32fbd0=0x1,_0x564fbe=[];for(let _0x13b0ab=0x0;_0x13b0ab<_0x50145e['openchannelAccountApps'][_0x4e1257('0xf5d')][_0x4e1257('0x1564')];_0x13b0ab++){const _0x3fe3f3=_0x50145e[_0x4e1257('0x11ff')][_0x4e1257('0xf5d')][_0x13b0ab],_0x2956b8=[],_0x328232=[];_0x3fe3f3[_0x4e1257('0xe98')]=_0x3fe3f3[_0x4e1257('0x115c')]!==_0x4e1257('0x1b54')?[_0x3fe3f3[_0x4e1257('0x115c')]]:_0x3fe3f3['IntervalId']?_0x2e3ca0()[_0x4e1257('0x386')](_0x2e3ca0()[_0x4e1257('0x25')](_0x50145e[_0x4e1257('0xe98')][_0x4e1257('0xf5d')],{'IntervalId':_0x3fe3f3[_0x4e1257('0x5ae')]}),'interval'):[],_0x3fe3f3['context']=_0x50145e[_0x4e1257('0x1963')]['context'],_0x3fe3f3[_0x4e1257('0x1a5b')]=_0x50145e[_0x4e1257('0x1963')][_0x4e1257('0x1a5b')],_0x3fe3f3[_0x4e1257('0xcf0')]&&(_0x3fe3f3[_0x4e1257('0xcf0')]=_0x3fe3f3[_0x4e1257('0xcf0')]['toLowerCase']()),_0x3fe3f3[_0x4e1257('0xe1e')]=_0x2956b8['length']?_0x2e3ca0()[_0x4e1257('0xc0f')](_0x2956b8)[_0x4e1257('0xe1e')]+0x1:_0x32fbd0,_0x32fbd0=(_0x328232[_0x4e1257('0x1564')]?_0x2e3ca0()[_0x4e1257('0xc0f')](_0x328232)[_0x4e1257('0xe1e')]:_0x3fe3f3[_0x4e1257('0xe1e')])+0x1,_0x564fbe=_0x2e3ca0()[_0x4e1257('0x746')](_0x564fbe,_0x2956b8,[_0x3fe3f3],_0x328232);}_0x1cd14a[_0x4e1257('0x1963')]['addApplications']({'id':_0x50145e[_0x4e1257('0x1963')]['id']},_0x2e3ca0()['sortBy'](_0x564fbe,'priority'))[_0x4e1257('0xe53')]['then'](function(_0x27e3d3){const _0x42fa2d=_0x4e1257;_0x50145e['openchannelAccountApps'][_0x42fa2d('0xf5d')]=_0x27e3d3['rows'];})[_0x4e1257('0x130a')](function(_0x376842){const _0x26691d=_0x4e1257;console[_0x26691d('0x52a')](_0x376842);});}function _0x38a8b5(_0x254ebf){_0x50145e['openchannelAccountApps']=_0x254ebf||{'count':0x0,'rows':[]};}function _0x3e3bdf(){const _0x5059fc=_0x5241ca;return _0x1cd14a[_0x5059fc('0x115c')][_0x5059fc('0x1e6e')]({'fields':'id,interval,IntervalId'})['$promise'][_0x5059fc('0x683')](function(_0x12762f){const _0x2d86f1=_0x5059fc;_0x50145e[_0x2d86f1('0xe98')]=_0x12762f;})[_0x5059fc('0x130a')](function(_0x300859){const _0x2d99d8=_0x5059fc;console[_0x2d99d8('0x52a')](_0x300859);});}function _0x4fb439(){const _0x303d04=_0x5241ca;_0x50145e[_0x303d04('0x1883')]=_0x1cd14a[_0x303d04('0x1963')]['getApplications'](_0x50145e[_0x303d04('0x23a2')],_0x38a8b5)[_0x303d04('0xe53')];}function _0x52273c(_0x44d6a1){const _0x1751d6=_0x5241ca;_0x2e3ca0()[_0x1751d6('0x3ec')](_0x50145e[_0x1751d6('0x11ff')][_0x1751d6('0xf5d')],{'id':_0x44d6a1['id']}),_0xe3612(),_0x1badcd['success']({'title':'App\x20deleted!','msg':_0x44d6a1[_0x1751d6('0x1d75')]?_0x44d6a1['app']+_0x1751d6('0x194d'):''});}function _0x3c91ae(_0x4d0e0a){const _0x337a0a=_0x5241ca,_0x19c224=_0xf0c399['confirm']()['title'](_0x337a0a('0x188'))['htmlContent'](_0x337a0a('0xed5')+_0x50145e[_0x337a0a('0x23b')][_0x337a0a('0x1564')]+_0x337a0a('0x93c')+_0x337a0a('0x1ee7'))[_0x337a0a('0x1040')]('delete\x20applications')['targetEvent'](_0x4d0e0a)['ok']('OK')[_0x337a0a('0x19fb')]('CANCEL');_0xf0c399[_0x337a0a('0x1d4')](_0x19c224)['then'](function(){const _0x563fc1=_0x337a0a;_0x50145e['selectedOpenchannelAccountApps'][_0x563fc1('0x1299')](function(_0xb6a0c9){const _0x515b5e=_0x563fc1;_0x2e3ca0()[_0x515b5e('0x3ec')](_0x50145e['openchannelAccountApps'][_0x515b5e('0xf5d')],{'id':_0xb6a0c9['id']});}),_0x50145e[_0x563fc1('0x23b')]=[],_0xe3612();});}}const _0x204bf1=_0x5821a1;_0x10ad2e['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'api',_0x189033('0x1963'),'openchannelAccounts',_0x189033('0x2c9'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x10ad2e(_0x124410,_0x2b5bb1,_0x1a24ac,_0x2eed68,_0x2757d2,_0x10127b,_0x3aa218,_0xdf8c44,_0x3d28cc,_0x51fb22){const _0x3a0926=_0x189033,_0x48664f=this;_0x48664f[_0x3a0926('0x11ed')]=_0x3d28cc['getCurrentUser'](),_0x48664f[_0x3a0926('0x1963')]=_0x2757d2,_0x48664f[_0x3a0926('0x1134')]=_0x51fb22,_0x48664f[_0x3a0926('0x2c9')]=_0x3aa218,_0x48664f[_0x3a0926('0x1996')]=[],_0x48664f[_0x3a0926('0x1c47')]=[],_0x48664f[_0x3a0926('0x1378')]=[],_0x48664f[_0x3a0926('0x125e')]=[],_0x48664f[_0x3a0926('0x23a7')]=[],_0x48664f[_0x3a0926('0x2106')]=![],_0x48664f[_0x3a0926('0x1dd2')]=_0x35caaf,_0x48664f[_0x3a0926('0xa5f')]=_0x7d9b83,_0x48664f[_0x3a0926('0xf82')]=_0xd9300c,_0x48664f['dualMultiselectOptions']={'readOnly':!_0x48664f[_0x3a0926('0x1134')][_0x3a0926('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x3a0926('0x60a'),'line1':_0x3a0926('0x11bc'),'line2':[_0x3a0926('0x60a'),'internal'],'line3':'','labelAll':_0xdf8c44[_0x3a0926('0x2728')](_0x3a0926('0x1db2')),'labelSelected':_0xdf8c44[_0x3a0926('0x2728')](_0x3a0926('0x1cdc')),'transferCallback':function(){const _0x10a9d4=_0x3a0926,_0x19fd7a=_0x2e3ca0()[_0x10a9d4('0x25cb')](_0x48664f[_0x10a9d4('0x23a7')],_0x48664f['selectedItems'],'id');_0x48664f['pendingChanges']=_0x2e3ca0()[_0x10a9d4('0x173f')](_0x19fd7a)?![]:!![];}};function _0x35caaf(){const _0x2f93ac=_0x3a0926;return _0x3d28cc[_0x2f93ac('0xca1')]('admin')?_0x2ab06f()[_0x2f93ac('0x130a')](function(_0x206d4a){const _0x4fc7ec=_0x2f93ac;_0x1a24ac[_0x4fc7ec('0x52a')]({'title':_0x206d4a[_0x4fc7ec('0x13ee')]?_0x4fc7ec('0x2168')+_0x206d4a[_0x4fc7ec('0x13ee')]+_0x4fc7ec('0xbf6')+_0x206d4a[_0x4fc7ec('0x24a9')]:'SYSTEM:GET_AGENTS','msg':_0x206d4a[_0x4fc7ec('0x13ee')]?JSON['stringify'](_0x206d4a['data']):_0x206d4a['toString']()});}):_0x1133bd()[_0x2f93ac('0x683')](function(_0x16a8af){const _0x3e8385=_0x2f93ac;return _0x48664f[_0x3e8385('0x1aa')]=_0x16a8af,_0x2ab06f();})[_0x2f93ac('0x130a')](function(_0x888067){const _0x17360a=_0x2f93ac;_0x1a24ac[_0x17360a('0x52a')]({'title':_0x888067[_0x17360a('0x13ee')]?_0x17360a('0x2168')+_0x888067['status']+_0x17360a('0xbf6')+_0x888067[_0x17360a('0x24a9')]:_0x17360a('0x144f'),'msg':_0x888067[_0x17360a('0x13ee')]?JSON[_0x17360a('0x258a')](_0x888067[_0x17360a('0x5a5')]):_0x888067['toString']()});});}function _0x1133bd(){return _0x2b5bb1(function(_0x52701c,_0x2ae201){const _0x4665ca=a0_0x4e0a;_0x2eed68[_0x4665ca('0x22df')]['get']({'userProfileId':_0x48664f[_0x4665ca('0x11ed')][_0x4665ca('0x2f')],'name':_0x4665ca('0x1bc0')})[_0x4665ca('0xe53')]['then'](function(_0x87bdc3){const _0x15fc66=_0x4665ca,_0x4f9484=_0x87bdc3&&_0x87bdc3[_0x15fc66('0xf5d')]?_0x87bdc3[_0x15fc66('0xf5d')][0x0]:null;_0x52701c(_0x4f9484);})[_0x4665ca('0x130a')](function(_0x432188){_0x2ae201(_0x432188);});});}function _0x2ab06f(){return _0x2b5bb1(function(_0x52f690,_0x5051cb){const _0x5ac2ec=a0_0x4e0a;return _0x1aedea()[_0x5ac2ec('0x683')](function(_0x263c8e){const _0x5d26e7=_0x5ac2ec;return _0x48664f[_0x5d26e7('0x1996')]=_0x263c8e[_0x5d26e7('0xf5d')]?_0x263c8e['rows']:[],_0x3d28cc[_0x5d26e7('0xca1')](_0x5d26e7('0x20c2'))?_0x263c8e:_0x48664f[_0x5d26e7('0x1aa')]?_0x48664f[_0x5d26e7('0x1aa')][_0x5d26e7('0x170')]?_0x263c8e:_0x2fb547():null;})['then'](function(_0x4422ca){const _0x35b6d5=_0x5ac2ec,_0x24d6c3=_0x4422ca&&_0x4422ca[_0x35b6d5('0xf5d')]?_0x4422ca['rows']:[];return _0x48664f[_0x35b6d5('0x1c47')]=_0x2e3ca0()[_0x35b6d5('0x386')](_0x24d6c3,function(_0x5367cc){const _0x11b435=_0x35b6d5;return _0x2e3ca0()[_0x11b435('0x1c07')](_0x48664f[_0x11b435('0x1996')],{'id':_0x3d28cc[_0x11b435('0xca1')](_0x11b435('0x20c2'))||_0x48664f[_0x11b435('0x1aa')][_0x11b435('0x170')]?_0x5367cc['id']:_0x5367cc[_0x11b435('0x832')]});}),_0x48664f[_0x35b6d5('0x125e')]=angular[_0x35b6d5('0x1a86')](_0x48664f[_0x35b6d5('0x1c47')]),_0x48664f['items'][_0x35b6d5('0x1299')](function(_0x52e9b4){const _0x5037cd=_0x35b6d5,_0x231410=_0x2e3ca0()['find'](_0x48664f[_0x5037cd('0x1c47')],{'id':_0x52e9b4['id']});_0x3d28cc[_0x5037cd('0xca1')](_0x5037cd('0x20c2'))?_0x52e9b4[_0x5037cd('0x24f4')]=!![]:_0x52e9b4['isValid']=typeof _0x231410!=='undefined'?!![]:![];}),_0x12e1c9();})[_0x5ac2ec('0x683')](function(_0x37d21f){const _0x4020a6=_0x5ac2ec,_0x127916=_0x37d21f&&_0x37d21f[_0x4020a6('0xf5d')]?_0x37d21f[_0x4020a6('0xf5d')]:[];_0x48664f[_0x4020a6('0x1378')]=_0x2e3ca0()[_0x4020a6('0x386')](_0x127916,function(_0x1a42e1){const _0x49f03f=_0x4020a6,_0x4152d1=_0x2e3ca0()[_0x49f03f('0x1c07')](_0x48664f[_0x49f03f('0x1996')],{'id':_0x1a42e1['id']});return _0x4152d1['penalty']=_0x1a42e1['UserOpenchannelAccount']?_0x49f03f('0x23d0')+_0x1a42e1[_0x49f03f('0xfe9')][_0x49f03f('0x1e2a')]:'',_0x4152d1[_0x49f03f('0x1d43')]=typeof _0x1a42e1[_0x49f03f('0x1d43')]!==_0x49f03f('0x1867')?'<'+_0x1a42e1[_0x49f03f('0x1d43')]+'>':'',_0x4152d1;}),_0x48664f[_0x4020a6('0x23a7')]=angular[_0x4020a6('0x1a86')](_0x48664f[_0x4020a6('0x1378')]),_0x48664f['dualMultiselectOptions'][_0x4020a6('0x1378')]=_0x48664f[_0x4020a6('0x1378')],_0x48664f['dualMultiselectOptions'][_0x4020a6('0x1996')]=_0x2e3ca0()[_0x4020a6('0x461')](_0x48664f[_0x4020a6('0x1c47')],_0x48664f[_0x4020a6('0x169f')][_0x4020a6('0x1378')],'id'),_0x52f690();})[_0x5ac2ec('0x130a')](function(_0x856686){_0x5051cb(_0x856686);});});}function _0x2fb547(){return _0x2b5bb1(function(_0x1c5faf,_0x48ca64){const _0x208401=a0_0x4e0a;return _0x2eed68['userProfileResource']['get']({'sectionId':_0x48664f['section']['id'],'nolimit':!![]})[_0x208401('0xe53')]['then'](function(_0xfd7f63){_0x1c5faf(_0xfd7f63);})['catch'](function(_0x48a52f){_0x48ca64(_0x48a52f);});});}function _0x12e1c9(){return _0x2b5bb1(function(_0x22fc62,_0x2a580f){const _0x16f00d=a0_0x4e0a;return _0x2eed68[_0x16f00d('0x1963')][_0x16f00d('0x8e7')]({'id':_0x48664f[_0x16f00d('0x1963')]['id'],'fields':_0x16f00d('0x72b'),'nolimit':!![],'role':'agent'})[_0x16f00d('0xe53')]['then'](function(_0x55c0eb){_0x22fc62(_0x55c0eb);})[_0x16f00d('0x130a')](function(_0x50ed85){_0x2a580f(_0x50ed85);});});}function _0x1aedea(){return _0x2b5bb1(function(_0x19662d,_0x2c01be){const _0x422542=a0_0x4e0a;return _0x2eed68[_0x422542('0xc96')][_0x422542('0x1e6e')]({'fields':_0x422542('0x72b'),'nolimit':!![],'role':_0x422542('0x2327')})[_0x422542('0xe53')][_0x422542('0x683')](function(_0x410226){_0x19662d(_0x410226);})[_0x422542('0x130a')](function(_0x54dc50){_0x2c01be(_0x54dc50);});});}function _0x2af97d(_0x267b9e){return _0x2b5bb1(function(_0x5b4514,_0x2b3836){const _0x17c364=a0_0x4e0a;_0x2e3ca0()[_0x17c364('0x173f')](_0x267b9e)?_0x5b4514():_0x2eed68['openchannelAccount'][_0x17c364('0x2179')]({'id':_0x48664f['openchannelAccount']['id'],'ids':_0x2e3ca0()['map'](_0x267b9e,'id')})[_0x17c364('0xe53')]['then'](function(){_0x5b4514();})[_0x17c364('0x130a')](function(_0x5a49ec){_0x2b3836(_0x5a49ec);});});}function _0x1316f5(_0x4ffa9b){return _0x2b5bb1(function(_0xafbdbc,_0x1d259e){const _0x1087ec=a0_0x4e0a;_0x2e3ca0()[_0x1087ec('0x173f')](_0x4ffa9b)?_0xafbdbc():_0x2eed68[_0x1087ec('0x1963')][_0x1087ec('0xf9')]({'id':_0x48664f[_0x1087ec('0x1963')]['id'],'ids':_0x2e3ca0()[_0x1087ec('0x386')](_0x4ffa9b,'id')})[_0x1087ec('0xe53')][_0x1087ec('0x683')](function(){_0xafbdbc();})[_0x1087ec('0x130a')](function(_0xeca24c){_0x1d259e(_0xeca24c);});});}function _0x7d9b83(){const _0x44fc24=_0x3a0926,_0x36e228=_0x2e3ca0()['differenceBy'](_0x48664f[_0x44fc24('0x23a7')],_0x48664f[_0x44fc24('0x1378')],'id'),_0x2d4b4e=_0x2e3ca0()[_0x44fc24('0x461')](_0x48664f[_0x44fc24('0x1378')],_0x48664f[_0x44fc24('0x23a7')],'id');return _0x1316f5(_0x36e228)[_0x44fc24('0x683')](function(){return _0x2af97d(_0x2d4b4e);})[_0x44fc24('0x683')](function(){const _0x409293=_0x44fc24;_0x48664f[_0x409293('0x2106')]=![],_0x48664f[_0x409293('0x125e')]=angular[_0x409293('0x1a86')](_0x48664f[_0x409293('0x1c47')]),_0x48664f[_0x409293('0x23a7')]=angular['copy'](_0x48664f[_0x409293('0x1378')]),_0x1a24ac[_0x409293('0x53')]({'title':'SUCCESS','msg':_0x409293('0x89d')});})[_0x44fc24('0x130a')](function(_0x38d23a){const _0x3fd765=_0x44fc24;_0x1a24ac['error']({'title':_0x38d23a[_0x3fd765('0x13ee')]?'API:'+_0x38d23a['status']+'\x20-\x20'+_0x38d23a[_0x3fd765('0x24a9')]:'SYSTEM:LISTS_ASSOCIATION','msg':_0x38d23a[_0x3fd765('0x13ee')]?JSON[_0x3fd765('0x258a')](_0x38d23a['data']):_0x38d23a['toString']()});});}function _0xd9300c(){const _0xc6352e=_0x3a0926;_0x124410[_0xc6352e('0x1715')]();}}const _0x3ff2ab=_0x10ad2e;_0x17e3d7[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty','openchannelAccountApp',_0x189033('0x1963'),'api','Auth','crudPermissions'];function _0x17e3d7(_0x1a3ef6,_0x5e8b60,_0x521710,_0x178e20,_0x3134e3,_0x418bbe,_0x28f471,_0x499348){const _0x447b1a=_0x189033,_0x5e99e1=this;_0x5e99e1[_0x447b1a('0x11ed')]=_0x28f471['getCurrentUser'](),_0x5e99e1[_0x447b1a('0x17f')]=[],_0x5e99e1[_0x447b1a('0xf28')]=_0x447b1a('0x505')+(_0x178e20[_0x447b1a('0x11f3')]||_0x178e20[_0x447b1a('0x1d75')])[_0x447b1a('0x80')](),_0x5e99e1[_0x447b1a('0x2327')]=angular['copy'](_0x178e20),_0x5e99e1['crudPermissions']=_0x499348,_0x5e99e1[_0x447b1a('0x258d')]={};if(_0x5e99e1['agent']['appdata'])switch(_0x5e99e1[_0x447b1a('0x2327')]['appType']?_0x5e99e1['agent'][_0x447b1a('0x11f3')][_0x447b1a('0x93a')]():_0x5e99e1[_0x447b1a('0x2327')]['app'][_0x447b1a('0x93a')]()){case _0x447b1a('0xbf0'):break;case _0x447b1a('0x205c'):{const _0x20fd50=_0x5e99e1[_0x447b1a('0x2327')]['appdata'][_0x447b1a('0x1fc5')](',');_0x5e99e1['agent'][_0x447b1a('0x1d46')]=_0x20fd50[0x0],_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1a1c')]=_0x20fd50[0x1],_0x5e99e1[_0x447b1a('0x2327')]['welcomemessage']=_0x20fd50[_0x447b1a('0x12c8')](0x2,_0x20fd50[_0x447b1a('0x1564')])['join'](',');}break;case _0x447b1a('0xd24'):{const _0x58dc08=_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1407')][_0x447b1a('0x1fc5')](',');_0x5e99e1[_0x447b1a('0x2327')]['projectId']=_0x58dc08[0x0],_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x38')]=_0x58dc08[0x1],_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x406')]=_0x58dc08[0x2],_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1a1c')]=_0x58dc08[0x3],_0x5e99e1['agent'][_0x447b1a('0x6d9')]=_0x58dc08[_0x447b1a('0x12c8')](0x4,_0x58dc08[_0x447b1a('0x1564')])['join'](',');}break;case _0x447b1a('0x1db1'):{const _0x2158a5=_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1407')]['split'](',');_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x7ae')]=_0x2158a5[0x0],_0x5e99e1['agent'][_0x447b1a('0x204a')]=_0x2158a5[0x1],_0x5e99e1['agent'][_0x447b1a('0x5ba')]=_0x2158a5[0x2],_0x5e99e1[_0x447b1a('0x2327')]['botname']=_0x2158a5[0x3],_0x5e99e1['agent'][_0x447b1a('0x6d9')]=_0x2158a5[_0x447b1a('0x12c8')](0x4,_0x2158a5[_0x447b1a('0x1564')])['join'](',');}break;case _0x447b1a('0x2408'):{const _0x2dd08e=_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1407')][_0x447b1a('0x1fc5')](',');_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x35')]=isNaN(_0x2dd08e[0x0])?_0x2dd08e[0x0]:parseInt(_0x2dd08e[0x0],0xa),_0x5e99e1['agent'][_0x447b1a('0x1bcd')]=_0x2dd08e[_0x447b1a('0x12c8')](0x1,_0x2dd08e[_0x447b1a('0x1564')])[_0x447b1a('0x1630')](',');}break;case'message':_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1bcd')]=_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1407')];break;case _0x447b1a('0x877'):_0x5e99e1[_0x447b1a('0x2327')]['name']=_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1407')][_0x447b1a('0x1fc5')]('=')[0x0],_0x5e99e1['agent'][_0x447b1a('0x1c6b')]=_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1407')][_0x447b1a('0x1fc5')]('=')[0x1];break;case _0x447b1a('0x19ae'):_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x273a')]=_0x5e99e1[_0x447b1a('0x2327')]['appdata'];break;default:{const _0x230574=_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1407')][_0x447b1a('0x1fc5')](',');_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x2327')]=_0x2e3ca0()[_0x447b1a('0x173f')](_0x230574[0x0])?_0x230574[0x0]:isNaN(_0x230574[0x0])?_0x230574[0x0]:parseInt(_0x230574[0x0],0xa),_0x5e99e1['agent'][_0x447b1a('0x1668')]=_0x2e3ca0()[_0x447b1a('0x173f')](_0x230574[0x1])?_0x230574[0x1]:isNaN(_0x230574[0x1])?_0x230574[0x1]:parseInt(_0x230574[0x1],0xa);}break;}else _0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x1668')]=0x1e;_0x5e99e1[_0x447b1a('0x2327')]['type']&&_0x5e99e1['agent'][_0x447b1a('0xcf0')][_0x447b1a('0x93a')]()===_0x447b1a('0x17cd')&&_0x5e99e1['agent'][_0x447b1a('0x11f3')][_0x447b1a('0x93a')]()===_0x447b1a('0x659')&&(_0x5e99e1[_0x447b1a('0x2327')]['prefix']=_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0xd31')]?_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0xd31')][_0x447b1a('0x1fc5')]('$')[0x0]:undefined,_0x5e99e1['agent'][_0x447b1a('0xabd')]=_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x73c')]?'CALLERID(all)='+_0x5e99e1[_0x447b1a('0x2327')][_0x447b1a('0x73c')]:undefined);_0x5e99e1[_0x447b1a('0x2671')]=_0x1487b0,_0x5e99e1[_0x447b1a('0xf82')]=_0x29b516,_0x28f471['hasRole'](_0x447b1a('0x20c2'))?_0x418bbe[_0x447b1a('0xc96')][_0x447b1a('0x1e6e')]({'fields':_0x447b1a('0xa10'),'sort':_0x447b1a('0x60a'),'role':_0x447b1a('0x2327'),'nolimit':_0x447b1a('0x26ac')})[_0x447b1a('0xe53')]['then'](function(_0xbbbaa5){const _0x73cf3b=_0x447b1a;_0x5e99e1[_0x73cf3b('0x756')]=_0xbbbaa5[_0x73cf3b('0xf5d')]||[];})[_0x447b1a('0x130a')](function(_0xc714b7){const _0x5bf3e0=_0x447b1a;_0x521710[_0x5bf3e0('0x52a')]({'title':_0xc714b7[_0x5bf3e0('0x13ee')]?_0x5bf3e0('0x2168')+_0xc714b7[_0x5bf3e0('0x13ee')]+'\x20-\x20'+_0xc714b7['statusText']:'SYSTEM:GET_AGENTS','msg':_0xc714b7['data']?JSON[_0x5bf3e0('0x258a')](_0xc714b7[_0x5bf3e0('0x5a5')]):_0xc714b7['toString']()});}):_0x418bbe['user'][_0x447b1a('0x1e6e')]({'fields':'id,name','sort':_0x447b1a('0x60a'),'role':'agent','nolimit':_0x447b1a('0x26ac')})[_0x447b1a('0xe53')][_0x447b1a('0x683')](function(_0xb5ef0){const _0x318718=_0x447b1a;_0x5e99e1[_0x318718('0x756')]=_0xb5ef0[_0x318718('0xf5d')]||[];})[_0x447b1a('0x683')](function(){const _0x12c1b3=_0x447b1a;return _0x418bbe['userProfileSection'][_0x12c1b3('0x1e6e')]({'userProfileId':_0x5e99e1[_0x12c1b3('0x11ed')][_0x12c1b3('0x2f')],'sectionId':0xca})[_0x12c1b3('0xe53')];})[_0x447b1a('0x683')](function(_0x59ea9b){const _0x4df755=_0x447b1a,_0x2e3292=_0x59ea9b&&_0x59ea9b['rows']?_0x59ea9b[_0x4df755('0xf5d')][0x0]:null;if(!_0x2e3292){const _0x594a69=[];let _0x15012a=null;_0x5e99e1[_0x4df755('0x2327')]&&(_0x15012a=_0x2e3ca0()['find'](_0x5e99e1['agents'],{'name':_0x5e99e1[_0x4df755('0x2327')][_0x4df755('0x2327')]}));for(let _0x532882=0x0;_0x532882<_0x5e99e1[_0x4df755('0x756')][_0x4df755('0x1564')];_0x532882++){_0x15012a&&_0x5e99e1[_0x4df755('0x756')][_0x532882]['id']===_0x15012a['id']&&(_0x5e99e1[_0x4df755('0x756')][_0x532882][_0x4df755('0x319')]=![],_0x594a69[_0x4df755('0x1fd0')](_0x5e99e1[_0x4df755('0x756')][_0x532882]));}_0x5e99e1[_0x4df755('0x756')]=_0x594a69;}else{if(!_0x2e3292[_0x4df755('0x170')])return _0x418bbe[_0x4df755('0xcf7')][_0x4df755('0x1e6e')]({'sectionId':_0x2e3292['id']})['$promise'][_0x4df755('0x683')](function(_0x44b0ed){const _0x1832b3=_0x4df755,_0x376b76=_0x2e3ca0()[_0x1832b3('0x386')](_0x44b0ed['rows'],function(_0x33f552){const _0xc6a73=_0x1832b3;return _0x2e3ca0()[_0xc6a73('0x1c07')](_0x5e99e1['agents'],{'id':_0x33f552[_0xc6a73('0x832')]});});let _0x27fb70=null;_0x5e99e1[_0x1832b3('0x2327')]&&(_0x27fb70=_0x2e3ca0()[_0x1832b3('0x1c07')](_0x5e99e1[_0x1832b3('0x756')],{'name':_0x5e99e1[_0x1832b3('0x2327')][_0x1832b3('0x2327')]}));if(_0x27fb70&&!_0x2e3ca0()[_0x1832b3('0x7a2')](_0x376b76,['id',_0x27fb70['id']])){const _0x14a7bc=_0x2e3ca0()[_0x1832b3('0x1c07')](_0x5e99e1['agents'],{'id':_0x27fb70['id']});_0x14a7bc[_0x1832b3('0x319')]=![],_0x376b76[_0x1832b3('0x1fd0')](_0x14a7bc);}_0x5e99e1[_0x1832b3('0x756')]=_0x376b76;});}})['catch'](function(_0xe9490a){const _0x171229=_0x447b1a;_0x521710[_0x171229('0x52a')]({'title':_0xe9490a[_0x171229('0x13ee')]?_0x171229('0x2168')+_0xe9490a['status']+_0x171229('0xbf6')+_0xe9490a[_0x171229('0x24a9')]:_0x171229('0x391'),'msg':_0xe9490a[_0x171229('0x5a5')]?JSON['stringify'](_0xe9490a['data']):_0xe9490a['toString']()});});function _0x1487b0(){const _0x3584f4=_0x447b1a;_0x5e99e1[_0x3584f4('0x17f')]=[];const _0x4f5f38=[];_0x5e99e1['agent'][_0x3584f4('0xcf0')]&&_0x5e99e1['agent']['type'][_0x3584f4('0x93a')]()===_0x3584f4('0x17cd')&&_0x5e99e1['agent'][_0x3584f4('0x11f3')]==='outboundDial'&&(_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0xd31')]=_0x3134e3[_0x3584f4('0x145a')]?(_0x5e99e1['agent'][_0x3584f4('0x24fa')]||'')+'${EXTEN:'+_0x3134e3[_0x3584f4('0x145a')]+'}':(_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x24fa')]||'')+_0x3584f4('0x20cb'),_0x3134e3['recordingFormat']!==_0x3584f4('0x925')?_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x158e')][_0x3584f4('0x824')](_0x3584f4('0x1b1'))<0x0&&(_0x5e99e1['agent']['options']+=_0x3584f4('0x1b1')):_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x158e')]=_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x158e')][_0x3584f4('0x1725')]('U(xcally-mixmonitor-context)',''));const _0x36f51f=_0x2e3ca0()['find'](_0x5e99e1[_0x3584f4('0x756')],{'name':_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x2327')]});_0x36f51f&&(_0x5e99e1[_0x3584f4('0x2327')]['UserId']=_0x36f51f['id']);if(_0x5e99e1['agent'][_0x3584f4('0x11f3')]&&_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x11f3')]===_0x3584f4('0xbf0')){}else switch((_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x1d75')]||_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x11f3')])[_0x3584f4('0x93a')]()){case _0x3584f4('0x877'):_0x5e99e1['agent'][_0x3584f4('0x1407')]=_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x60a')]+'='+_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x1c6b')];break;case _0x3584f4('0xbf0'):break;default:_0x4f5f38[0x0]=_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x2327')],_0x4f5f38[0x1]=_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x1668')],_0x5e99e1[_0x3584f4('0x2327')][_0x3584f4('0x1407')]=_0x4f5f38[_0x3584f4('0x1630')](',');}_0x29b516(_0x5e99e1[_0x3584f4('0x2327')]);}function _0x29b516(_0x2ae2c1){const _0x193082=_0x447b1a;_0x1a3ef6[_0x193082('0x1715')](_0x2ae2c1);}}const _0x12fdab=_0x17e3d7;_0xa391b9[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0xbc7'),_0x189033('0x1963'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0xa391b9(_0x321515,_0xdb0b49,_0x47ef58,_0x5759d0,_0x8e82a1,_0x59e6a2,_0x50fc8a,_0x1f0dc5){const _0x520296=_0x189033,_0x2bdd96=this;_0x2bdd96[_0x520296('0x11ed')]=_0x50fc8a[_0x520296('0x20b2')](),_0x2bdd96[_0x520296('0x17f')]=[],_0x2bdd96[_0x520296('0xf28')]=_0x520296('0x505')+(_0x5759d0[_0x520296('0x11f3')]||_0x5759d0['app'])['toUpperCase'](),_0x2bdd96[_0x520296('0x1db1')]=angular[_0x520296('0x1a86')](_0x5759d0),_0x2bdd96['crudPermissions']=_0x1f0dc5,_0x2bdd96['hasModulePermissions']={};if(_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1407')])switch(_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x11f3')]?_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x11f3')][_0x520296('0x93a')]():_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1d75')][_0x520296('0x93a')]()){case _0x520296('0xbf0'):break;case _0x520296('0x205c'):{const _0x34f586=_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1407')][_0x520296('0x1fc5')](',');_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1d46')]=_0x34f586[0x0],_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1a1c')]=_0x34f586[0x1],_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x6d9')]=_0x34f586['slice'](0x2,_0x34f586[_0x520296('0x1564')])[_0x520296('0x1630')](',');}break;case _0x520296('0xd24'):{const _0x33ed45=_0x2bdd96['amazonlex']['appdata'][_0x520296('0x1fc5')](',');_0x2bdd96['amazonlex'][_0x520296('0x2119')]=_0x33ed45[0x0],_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x38')]=_0x33ed45[0x1],_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x406')]=_0x33ed45[0x2],_0x2bdd96[_0x520296('0x1db1')]['language']=_0x33ed45[0x3],_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x6d9')]=_0x33ed45[_0x520296('0x12c8')](0x4,_0x33ed45['length'])['join'](',');}break;case _0x520296('0x1db1'):{const _0x1ccabf=_0x2bdd96['amazonlex'][_0x520296('0x1407')][_0x520296('0x1fc5')](',');_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x7ae')]=_0x1ccabf[0x0],_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x204a')]=_0x1ccabf[0x1],_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x5ba')]=_0x1ccabf[0x2],_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x11a9')]=_0x1ccabf[0x3],_0x2bdd96[_0x520296('0x1db1')]['welcomemessage']=_0x1ccabf[_0x520296('0x12c8')](0x4,_0x1ccabf[_0x520296('0x1564')])[_0x520296('0x1630')](',');}break;case'autoreply':{const _0x41e899=_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1407')][_0x520296('0x1fc5')](',');_0x2bdd96[_0x520296('0x1db1')]['times']=isNaN(_0x41e899[0x0])?_0x41e899[0x0]:parseInt(_0x41e899[0x0],0xa),_0x2bdd96[_0x520296('0x1db1')]['text']=_0x41e899[_0x520296('0x12c8')](0x1,_0x41e899[_0x520296('0x1564')])['join'](',');}break;case _0x520296('0x8c2'):_0x2bdd96['amazonlex'][_0x520296('0x1bcd')]=_0x2bdd96[_0x520296('0x1db1')]['appdata'];break;case'set':_0x2bdd96[_0x520296('0x1db1')]['name']=_0x2bdd96[_0x520296('0x1db1')]['appdata'][_0x520296('0x1fc5')]('=')[0x0],_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1c6b')]=_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1407')]['split']('=')[0x1];break;case _0x520296('0x19ae'):_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x273a')]=_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1407')];break;default:{const _0x32cc42=_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x1407')][_0x520296('0x1fc5')](',');_0x2bdd96[_0x520296('0x1db1')]['accesskeyid']=_0x2e3ca0()[_0x520296('0x173f')](_0x32cc42[0x0])?_0x32cc42[0x0]:isNaN(_0x32cc42[0x0])?_0x32cc42[0x0]:parseInt(_0x32cc42[0x0],0xa),_0x2bdd96[_0x520296('0x1db1')]['secretaccesskey']=_0x2e3ca0()[_0x520296('0x173f')](_0x32cc42[0x1])?_0x32cc42[0x1]:isNaN(_0x32cc42[0x1])?_0x32cc42[0x1]:parseInt(_0x32cc42[0x1],0xa),_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x5ba')]=_0x2e3ca0()[_0x520296('0x173f')](_0x32cc42[0x2])?_0x32cc42[0x2]:isNaN(_0x32cc42[0x2])?_0x32cc42[0x2]:parseInt(_0x32cc42[0x2],0xa),_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x11a9')]=_0x2e3ca0()[_0x520296('0x173f')](_0x32cc42[0x3])?_0x32cc42[0x3]:isNaN(_0x32cc42[0x3])?_0x32cc42[0x3]:parseInt(_0x32cc42[0x3],0xa),_0x2bdd96[_0x520296('0x1db1')]['welcomemessage']=_0x2e3ca0()[_0x520296('0x173f')](_0x32cc42[0x4])?_0x32cc42[0x4]:isNaN(_0x32cc42[0x4])?_0x32cc42[0x4]:parseInt(_0x32cc42[0x4],0xa);}break;}else _0x2bdd96[_0x520296('0x1db1')][_0x520296('0x5ba')]=_0x520296('0xfb5');_0x2bdd96[_0x520296('0x1db1')][_0x520296('0xcf0')]&&_0x2bdd96[_0x520296('0x1db1')][_0x520296('0xcf0')][_0x520296('0x93a')]()==='outbound'&&_0x2bdd96['amazonlex'][_0x520296('0x11f3')][_0x520296('0x93a')]()===_0x520296('0x659')&&(_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x24fa')]=_0x2bdd96[_0x520296('0x1db1')][_0x520296('0xd31')]?_0x2bdd96[_0x520296('0x1db1')]['phone'][_0x520296('0x1fc5')]('$')[0x0]:undefined,_0x2bdd96[_0x520296('0x1db1')]['callerId']=_0x2bdd96[_0x520296('0x1db1')][_0x520296('0x73c')]?_0x520296('0xac1')+_0x2bdd96['amazonlex']['callerID']:undefined);_0x2bdd96[_0x520296('0x2671')]=_0x114b7f,_0x2bdd96[_0x520296('0xf82')]=_0x2de71d;function _0x114b7f(){const _0x162736=_0x520296;_0x2bdd96[_0x162736('0x17f')]=[];const _0xbc894b=[];_0x2bdd96[_0x162736('0x1db1')][_0x162736('0xcf0')]&&_0x2bdd96[_0x162736('0x1db1')][_0x162736('0xcf0')][_0x162736('0x93a')]()===_0x162736('0x17cd')&&_0x2bdd96['amazonlex'][_0x162736('0x11f3')]===_0x162736('0x4d2')&&(_0x2bdd96[_0x162736('0x1db1')][_0x162736('0xd31')]=_0x8e82a1['cutdigits']?(_0x2bdd96[_0x162736('0x1db1')][_0x162736('0x24fa')]||'')+_0x162736('0x249e')+_0x8e82a1[_0x162736('0x145a')]+'}':(_0x2bdd96['amazonlex']['prefix']||'')+'${EXTEN}',_0x8e82a1[_0x162736('0x75b')]!=='none'?_0x2bdd96[_0x162736('0x1db1')]['options'][_0x162736('0x824')](_0x162736('0x1b1'))<0x0&&(_0x2bdd96['amazonlex'][_0x162736('0x158e')]+=_0x162736('0x1b1')):_0x2bdd96[_0x162736('0x1db1')][_0x162736('0x158e')]=_0x2bdd96[_0x162736('0x1db1')][_0x162736('0x158e')][_0x162736('0x1725')](_0x162736('0x1b1'),''));if(_0x2bdd96['amazonlex'][_0x162736('0x11f3')]&&_0x2bdd96['amazonlex']['appType']===_0x162736('0xbf0')){}else switch((_0x2bdd96[_0x162736('0x1db1')]['app']||_0x2bdd96[_0x162736('0x1db1')][_0x162736('0x11f3')])[_0x162736('0x93a')]()){case'set':_0x2bdd96[_0x162736('0x1db1')][_0x162736('0x1407')]=_0x2bdd96[_0x162736('0x1db1')][_0x162736('0x60a')]+'='+_0x2bdd96[_0x162736('0x1db1')][_0x162736('0x1c6b')];break;case'custom':break;default:_0xbc894b[0x0]=_0x2bdd96[_0x162736('0x1db1')][_0x162736('0x7ae')],_0xbc894b[0x1]=_0x2bdd96[_0x162736('0x1db1')]['secretaccesskey'],_0xbc894b[0x2]=_0x2bdd96['amazonlex']['lexregion'],_0xbc894b[0x3]=_0x2bdd96['amazonlex'][_0x162736('0x11a9')],_0xbc894b[0x4]=_0x2bdd96[_0x162736('0x1db1')][_0x162736('0x6d9')],_0x2bdd96[_0x162736('0x1db1')]['appdata']=_0xbc894b[_0x162736('0x1630')](',');}_0x2de71d(_0x2bdd96[_0x162736('0x1db1')]);}function _0x2de71d(_0xe1f668){const _0x34e8b9=_0x520296;_0x321515[_0x34e8b9('0x1715')](_0xe1f668);}}const _0x36169b=_0xa391b9;_0x486eea[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0xbc7'),_0x189033('0x1963'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x486eea(_0xb9b9ce,_0x43e1ff,_0x1e2b6a,_0x31de8c,_0x4f8cda,_0x105512,_0x16b463,_0x1ba32f){const _0x592688=_0x189033,_0x7b980a=this;_0x7b980a[_0x592688('0x11ed')]=_0x16b463['getCurrentUser'](),_0x7b980a[_0x592688('0x17f')]=[],_0x7b980a[_0x592688('0xf28')]=_0x592688('0x505')+(_0x31de8c[_0x592688('0x11f3')]||_0x31de8c[_0x592688('0x1d75')])[_0x592688('0x80')](),_0x7b980a[_0x592688('0x2408')]=angular[_0x592688('0x1a86')](_0x31de8c),_0x7b980a[_0x592688('0x1134')]=_0x1ba32f,_0x7b980a[_0x592688('0x258d')]={};if(_0x7b980a['autoreply'][_0x592688('0x1407')])switch(_0x7b980a[_0x592688('0x2408')][_0x592688('0x11f3')]?_0x7b980a[_0x592688('0x2408')][_0x592688('0x11f3')][_0x592688('0x93a')]():_0x7b980a['autoreply'][_0x592688('0x1d75')]['toLowerCase']()){case'custom':break;case _0x592688('0x205c'):{const _0xb2f5db=_0x7b980a[_0x592688('0x2408')]['appdata'][_0x592688('0x1fc5')](',');_0x7b980a[_0x592688('0x2408')][_0x592688('0x1d46')]=_0xb2f5db[0x0],_0x7b980a[_0x592688('0x2408')]['language']=_0xb2f5db[0x1],_0x7b980a[_0x592688('0x2408')][_0x592688('0x6d9')]=_0xb2f5db[_0x592688('0x12c8')](0x2,_0xb2f5db[_0x592688('0x1564')])['join'](',');}break;case _0x592688('0xd24'):{const _0x316478=_0x7b980a[_0x592688('0x2408')][_0x592688('0x1407')][_0x592688('0x1fc5')](',');_0x7b980a[_0x592688('0x2408')]['projectId']=_0x316478[0x0],_0x7b980a[_0x592688('0x2408')]['clientEmail']=_0x316478[0x1],_0x7b980a[_0x592688('0x2408')][_0x592688('0x406')]=_0x316478[0x2],_0x7b980a[_0x592688('0x2408')][_0x592688('0x1a1c')]=_0x316478[0x3],_0x7b980a[_0x592688('0x2408')][_0x592688('0x6d9')]=_0x316478[_0x592688('0x12c8')](0x4,_0x316478['length'])[_0x592688('0x1630')](',');}break;case _0x592688('0x1db1'):{const _0x43429c=_0x7b980a['autoreply'][_0x592688('0x1407')][_0x592688('0x1fc5')](',');_0x7b980a[_0x592688('0x2408')][_0x592688('0x7ae')]=_0x43429c[0x0],_0x7b980a['autoreply'][_0x592688('0x204a')]=_0x43429c[0x1],_0x7b980a['autoreply'][_0x592688('0x5ba')]=_0x43429c[0x2],_0x7b980a[_0x592688('0x2408')]['botname']=_0x43429c[0x3],_0x7b980a[_0x592688('0x2408')]['welcomemessage']=_0x43429c['slice'](0x4,_0x43429c[_0x592688('0x1564')])[_0x592688('0x1630')](',');}break;case'autoreply':{const _0x54a7dc=_0x7b980a['autoreply'][_0x592688('0x1407')][_0x592688('0x1fc5')](',');_0x7b980a[_0x592688('0x2408')][_0x592688('0x35')]=isNaN(_0x54a7dc[0x0])?_0x54a7dc[0x0]:parseInt(_0x54a7dc[0x0],0xa),_0x7b980a[_0x592688('0x2408')]['text']=_0x54a7dc[_0x592688('0x12c8')](0x1,_0x54a7dc[_0x592688('0x1564')])['join'](',');}break;case'message':_0x7b980a['autoreply'][_0x592688('0x1bcd')]=_0x7b980a[_0x592688('0x2408')][_0x592688('0x1407')];break;case _0x592688('0x877'):_0x7b980a[_0x592688('0x2408')][_0x592688('0x60a')]=_0x7b980a[_0x592688('0x2408')]['appdata'][_0x592688('0x1fc5')]('=')[0x0],_0x7b980a[_0x592688('0x2408')][_0x592688('0x1c6b')]=_0x7b980a[_0x592688('0x2408')][_0x592688('0x1407')]['split']('=')[0x1];break;case _0x592688('0x19ae'):_0x7b980a['autoreply'][_0x592688('0x273a')]=_0x7b980a[_0x592688('0x2408')][_0x592688('0x1407')];break;default:{const _0x37042b=_0x7b980a[_0x592688('0x2408')][_0x592688('0x1407')][_0x592688('0x1fc5')](',');_0x7b980a['autoreply'][_0x592688('0x35')]=_0x2e3ca0()['isEmpty'](_0x37042b[0x0])?_0x37042b[0x0]:isNaN(_0x37042b[0x0])?_0x37042b[0x0]:parseInt(_0x37042b[0x0],0xa),_0x7b980a[_0x592688('0x2408')][_0x592688('0x1bcd')]=_0x2e3ca0()[_0x592688('0x173f')](_0x37042b[0x1])?_0x37042b[0x1]:isNaN(_0x37042b[0x1])?_0x37042b[0x1]:parseInt(_0x37042b[0x1],0xa);}break;}else _0x7b980a[_0x592688('0x2408')]['times']=0x1;_0x7b980a[_0x592688('0x2408')]['type']&&_0x7b980a[_0x592688('0x2408')][_0x592688('0xcf0')]['toLowerCase']()===_0x592688('0x17cd')&&_0x7b980a[_0x592688('0x2408')]['appType'][_0x592688('0x93a')]()===_0x592688('0x659')&&(_0x7b980a[_0x592688('0x2408')][_0x592688('0x24fa')]=_0x7b980a[_0x592688('0x2408')][_0x592688('0xd31')]?_0x7b980a[_0x592688('0x2408')][_0x592688('0xd31')]['split']('$')[0x0]:undefined,_0x7b980a[_0x592688('0x2408')][_0x592688('0xabd')]=_0x7b980a[_0x592688('0x2408')]['callerID']?_0x592688('0xac1')+_0x7b980a['autoreply']['callerID']:undefined);_0x7b980a[_0x592688('0x2671')]=_0x3a0286,_0x7b980a[_0x592688('0xf82')]=_0x62cdfa;function _0x3a0286(){const _0x5938fe=_0x592688;_0x7b980a['errors']=[];const _0x3d6ebd=[];_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0xcf0')]&&_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0xcf0')][_0x5938fe('0x93a')]()===_0x5938fe('0x17cd')&&_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x11f3')]===_0x5938fe('0x4d2')&&(_0x7b980a[_0x5938fe('0x2408')]['phone']=_0x4f8cda[_0x5938fe('0x145a')]?(_0x7b980a['autoreply'][_0x5938fe('0x24fa')]||'')+_0x5938fe('0x249e')+_0x4f8cda['cutdigits']+'}':(_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x24fa')]||'')+'${EXTEN}',_0x4f8cda[_0x5938fe('0x75b')]!=='none'?_0x7b980a[_0x5938fe('0x2408')]['options'][_0x5938fe('0x824')](_0x5938fe('0x1b1'))<0x0&&(_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x158e')]+=_0x5938fe('0x1b1')):_0x7b980a[_0x5938fe('0x2408')]['options']=_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x158e')][_0x5938fe('0x1725')](_0x5938fe('0x1b1'),''));if(_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x11f3')]&&_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x11f3')]===_0x5938fe('0xbf0')){}else switch((_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x1d75')]||_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x11f3')])[_0x5938fe('0x93a')]()){case _0x5938fe('0x877'):_0x7b980a['autoreply'][_0x5938fe('0x1407')]=_0x7b980a[_0x5938fe('0x2408')]['name']+'='+_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x1c6b')];break;case _0x5938fe('0xbf0'):break;default:_0x3d6ebd[0x0]=_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x35')],_0x3d6ebd[0x1]=_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x1bcd')],_0x7b980a[_0x5938fe('0x2408')][_0x5938fe('0x1407')]=_0x3d6ebd[_0x5938fe('0x1630')](',');}_0x62cdfa(_0x7b980a['autoreply']);}function _0x62cdfa(_0x283747){const _0x4c47e6=_0x592688;_0xb9b9ce[_0x4c47e6('0x1715')](_0x283747);}}const _0x4c56dc=_0x486eea;_0x26dbb9[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0xbc7'),_0x189033('0x1963'),_0x189033('0x56b'),'Auth','crudPermissions'];function _0x26dbb9(_0x14bae5,_0x16fd2b,_0x2ec155,_0xcdd562,_0x441a8b,_0x40d467,_0x264171,_0x4c8e87){const _0x323119=_0x189033,_0x538622=this;_0x538622[_0x323119('0x11ed')]=_0x264171[_0x323119('0x20b2')](),_0x538622[_0x323119('0x17f')]=[],_0x538622[_0x323119('0xf28')]=_0x323119('0x505')+(_0xcdd562[_0x323119('0x11f3')]||_0xcdd562[_0x323119('0x1d75')])[_0x323119('0x80')](),_0x538622[_0x323119('0x12b0')]=angular['copy'](_0xcdd562),_0x538622['crudPermissions']=_0x4c8e87,_0x538622[_0x323119('0x258d')]={};if(_0x538622[_0x323119('0x12b0')]['appdata'])switch(_0x538622['close'][_0x323119('0x11f3')]?_0x538622[_0x323119('0x12b0')][_0x323119('0x11f3')]['toLowerCase']():_0x538622['close']['app']['toLowerCase']()){case'custom':break;case _0x323119('0x205c'):{const _0x21b65f=_0x538622[_0x323119('0x12b0')][_0x323119('0x1407')]['split'](',');_0x538622['close'][_0x323119('0x1d46')]=_0x21b65f[0x0],_0x538622[_0x323119('0x12b0')]['language']=_0x21b65f[0x1],_0x538622['close'][_0x323119('0x6d9')]=_0x21b65f['slice'](0x2,_0x21b65f[_0x323119('0x1564')])['join'](',');}break;case _0x323119('0xd24'):{const _0x529e95=_0x538622[_0x323119('0x12b0')][_0x323119('0x1407')][_0x323119('0x1fc5')](',');_0x538622['close'][_0x323119('0x2119')]=_0x529e95[0x0],_0x538622[_0x323119('0x12b0')][_0x323119('0x38')]=_0x529e95[0x1],_0x538622['close'][_0x323119('0x406')]=_0x529e95[0x2],_0x538622[_0x323119('0x12b0')]['language']=_0x529e95[0x3],_0x538622[_0x323119('0x12b0')][_0x323119('0x6d9')]=_0x529e95[_0x323119('0x12c8')](0x4,_0x529e95['length'])[_0x323119('0x1630')](',');}break;case _0x323119('0x1db1'):{const _0x367b1d=_0x538622['close'][_0x323119('0x1407')][_0x323119('0x1fc5')](',');_0x538622[_0x323119('0x12b0')][_0x323119('0x7ae')]=_0x367b1d[0x0],_0x538622[_0x323119('0x12b0')][_0x323119('0x204a')]=_0x367b1d[0x1],_0x538622[_0x323119('0x12b0')][_0x323119('0x5ba')]=_0x367b1d[0x2],_0x538622[_0x323119('0x12b0')][_0x323119('0x11a9')]=_0x367b1d[0x3],_0x538622[_0x323119('0x12b0')]['welcomemessage']=_0x367b1d['slice'](0x4,_0x367b1d['length'])[_0x323119('0x1630')](',');}break;case'autoreply':{const _0xcddb2c=_0x538622[_0x323119('0x12b0')]['appdata'][_0x323119('0x1fc5')](',');_0x538622[_0x323119('0x12b0')][_0x323119('0x35')]=isNaN(_0xcddb2c[0x0])?_0xcddb2c[0x0]:parseInt(_0xcddb2c[0x0],0xa),_0x538622[_0x323119('0x12b0')][_0x323119('0x1bcd')]=_0xcddb2c['slice'](0x1,_0xcddb2c[_0x323119('0x1564')])[_0x323119('0x1630')](',');}break;case _0x323119('0x8c2'):_0x538622[_0x323119('0x12b0')][_0x323119('0x1bcd')]=_0x538622[_0x323119('0x12b0')][_0x323119('0x1407')];break;case _0x323119('0x877'):_0x538622['close'][_0x323119('0x60a')]=_0x538622[_0x323119('0x12b0')][_0x323119('0x1407')][_0x323119('0x1fc5')]('=')[0x0],_0x538622[_0x323119('0x12b0')][_0x323119('0x1c6b')]=_0x538622[_0x323119('0x12b0')][_0x323119('0x1407')][_0x323119('0x1fc5')]('=')[0x1];break;case'agi':_0x538622[_0x323119('0x12b0')][_0x323119('0x273a')]=_0x538622[_0x323119('0x12b0')]['appdata'];break;default:{const _0x511f0c=_0x538622[_0x323119('0x12b0')][_0x323119('0x1407')][_0x323119('0x1fc5')](',');_0x538622[_0x323119('0x12b0')][_0x323119('0x43f')]=_0x2e3ca0()[_0x323119('0x173f')](_0x511f0c[0x0])?_0x511f0c[0x0]:isNaN(_0x511f0c[0x0])?_0x511f0c[0x0]:parseInt(_0x511f0c[0x0],0xa);}break;}else{}_0x538622[_0x323119('0x12b0')][_0x323119('0xcf0')]&&_0x538622[_0x323119('0x12b0')][_0x323119('0xcf0')][_0x323119('0x93a')]()===_0x323119('0x17cd')&&_0x538622[_0x323119('0x12b0')][_0x323119('0x11f3')][_0x323119('0x93a')]()===_0x323119('0x659')&&(_0x538622[_0x323119('0x12b0')][_0x323119('0x24fa')]=_0x538622[_0x323119('0x12b0')][_0x323119('0xd31')]?_0x538622[_0x323119('0x12b0')][_0x323119('0xd31')][_0x323119('0x1fc5')]('$')[0x0]:undefined,_0x538622[_0x323119('0x12b0')]['callerId']=_0x538622['close'][_0x323119('0x73c')]?_0x323119('0xac1')+_0x538622[_0x323119('0x12b0')][_0x323119('0x73c')]:undefined);_0x538622['saveOpenchannelAccountApp']=_0x41dbd7,_0x538622['closeDialog']=_0x1ad48f;function _0x41dbd7(){const _0x565890=_0x323119;_0x538622[_0x565890('0x17f')]=[];const _0x2eaece=[];_0x538622['close'][_0x565890('0xcf0')]&&_0x538622[_0x565890('0x12b0')][_0x565890('0xcf0')][_0x565890('0x93a')]()===_0x565890('0x17cd')&&_0x538622[_0x565890('0x12b0')][_0x565890('0x11f3')]===_0x565890('0x4d2')&&(_0x538622[_0x565890('0x12b0')][_0x565890('0xd31')]=_0x441a8b[_0x565890('0x145a')]?(_0x538622[_0x565890('0x12b0')][_0x565890('0x24fa')]||'')+_0x565890('0x249e')+_0x441a8b[_0x565890('0x145a')]+'}':(_0x538622[_0x565890('0x12b0')][_0x565890('0x24fa')]||'')+_0x565890('0x20cb'),_0x441a8b[_0x565890('0x75b')]!==_0x565890('0x925')?_0x538622[_0x565890('0x12b0')][_0x565890('0x158e')]['indexOf'](_0x565890('0x1b1'))<0x0&&(_0x538622[_0x565890('0x12b0')]['options']+='U(xcally-mixmonitor-context)'):_0x538622[_0x565890('0x12b0')][_0x565890('0x158e')]=_0x538622[_0x565890('0x12b0')][_0x565890('0x158e')]['replace'](_0x565890('0x1b1'),''));if(_0x538622[_0x565890('0x12b0')]['appType']&&_0x538622[_0x565890('0x12b0')]['appType']===_0x565890('0xbf0')){}else switch((_0x538622['close'][_0x565890('0x1d75')]||_0x538622['close']['appType'])[_0x565890('0x93a')]()){case _0x565890('0x877'):_0x538622['close'][_0x565890('0x1407')]=_0x538622['close']['name']+'='+_0x538622[_0x565890('0x12b0')]['value'];break;case'custom':break;default:_0x2eaece[0x0]=_0x538622[_0x565890('0x12b0')][_0x565890('0x43f')],_0x538622[_0x565890('0x12b0')][_0x565890('0x1407')]=_0x2eaece['join'](',');}_0x1ad48f(_0x538622['close']);}function _0x1ad48f(_0x3abffe){const _0x33ce79=_0x323119;_0x14bae5[_0x33ce79('0x1715')](_0x3abffe);}}const _0x47e9c6=_0x26dbb9;_0x22ce2a['$inject']=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0xbc7'),_0x189033('0x1963'),_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0x22ce2a(_0x13be57,_0x29747a,_0x5060a1,_0x4b7400,_0x311dcc,_0x2d2817,_0x411e2d,_0x3c1825){const _0x400bc8=_0x189033,_0x3ee564=this;_0x3ee564[_0x400bc8('0x11ed')]=_0x411e2d[_0x400bc8('0x20b2')](),_0x3ee564[_0x400bc8('0x17f')]=[],_0x3ee564['title']=_0x400bc8('0x505')+(_0x4b7400[_0x400bc8('0x11f3')]||_0x4b7400[_0x400bc8('0x1d75')])[_0x400bc8('0x80')](),_0x3ee564['dialogflow']=angular[_0x400bc8('0x1a86')](_0x4b7400),_0x3ee564[_0x400bc8('0x1134')]=_0x3c1825,_0x3ee564[_0x400bc8('0x258d')]={};if(_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1407')])switch(_0x3ee564[_0x400bc8('0x205c')]['appType']?_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x11f3')][_0x400bc8('0x93a')]():_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1d75')][_0x400bc8('0x93a')]()){case'custom':break;case _0x400bc8('0x205c'):{const _0x592885=_0x3ee564['dialogflow'][_0x400bc8('0x1407')]['split'](',');_0x3ee564['dialogflow'][_0x400bc8('0x1d46')]=_0x592885[0x0],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1a1c')]=_0x592885[0x1],_0x3ee564['dialogflow'][_0x400bc8('0x6d9')]=_0x592885[_0x400bc8('0x12c8')](0x2,_0x592885[_0x400bc8('0x1564')])[_0x400bc8('0x1630')](',');}break;case'dialogflowv2':{const _0x3660ce=_0x3ee564[_0x400bc8('0x205c')]['appdata'][_0x400bc8('0x1fc5')](',');_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x2119')]=_0x3660ce[0x0],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x38')]=_0x3660ce[0x1],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x406')]=_0x3660ce[0x2],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1a1c')]=_0x3660ce[0x3],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x6d9')]=_0x3660ce[_0x400bc8('0x12c8')](0x4,_0x3660ce[_0x400bc8('0x1564')])[_0x400bc8('0x1630')](',');}break;case _0x400bc8('0x1db1'):{const _0x5822f1=_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1407')][_0x400bc8('0x1fc5')](',');_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x7ae')]=_0x5822f1[0x0],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x204a')]=_0x5822f1[0x1],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x5ba')]=_0x5822f1[0x2],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x11a9')]=_0x5822f1[0x3],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x6d9')]=_0x5822f1['slice'](0x4,_0x5822f1[_0x400bc8('0x1564')])['join'](',');}break;case _0x400bc8('0x2408'):{const _0x2a0d76=_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1407')]['split'](',');_0x3ee564['dialogflow'][_0x400bc8('0x35')]=isNaN(_0x2a0d76[0x0])?_0x2a0d76[0x0]:parseInt(_0x2a0d76[0x0],0xa),_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1bcd')]=_0x2a0d76[_0x400bc8('0x12c8')](0x1,_0x2a0d76['length'])[_0x400bc8('0x1630')](',');}break;case _0x400bc8('0x8c2'):_0x3ee564['dialogflow'][_0x400bc8('0x1bcd')]=_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1407')];break;case _0x400bc8('0x877'):_0x3ee564[_0x400bc8('0x205c')]['name']=_0x3ee564['dialogflow'][_0x400bc8('0x1407')]['split']('=')[0x0],_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1c6b')]=_0x3ee564['dialogflow'][_0x400bc8('0x1407')][_0x400bc8('0x1fc5')]('=')[0x1];break;case _0x400bc8('0x19ae'):_0x3ee564['dialogflow']['project']=_0x3ee564['dialogflow'][_0x400bc8('0x1407')];break;default:{const _0x6f03ed=_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1407')][_0x400bc8('0x1fc5')](',');_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x1d46')]=_0x2e3ca0()[_0x400bc8('0x173f')](_0x6f03ed[0x0])?_0x6f03ed[0x0]:isNaN(_0x6f03ed[0x0])?_0x6f03ed[0x0]:parseInt(_0x6f03ed[0x0],0xa),_0x3ee564['dialogflow'][_0x400bc8('0x1a1c')]=_0x2e3ca0()[_0x400bc8('0x173f')](_0x6f03ed[0x1])?_0x6f03ed[0x1]:isNaN(_0x6f03ed[0x1])?_0x6f03ed[0x1]:parseInt(_0x6f03ed[0x1],0xa),_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x6d9')]=_0x2e3ca0()['isEmpty'](_0x6f03ed[0x2])?_0x6f03ed[0x2]:isNaN(_0x6f03ed[0x2])?_0x6f03ed[0x2]:parseInt(_0x6f03ed[0x2],0xa);}break;}else _0x3ee564[_0x400bc8('0x205c')]['language']='en';_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0xcf0')]&&_0x3ee564[_0x400bc8('0x205c')]['type'][_0x400bc8('0x93a')]()===_0x400bc8('0x17cd')&&_0x3ee564['dialogflow'][_0x400bc8('0x11f3')][_0x400bc8('0x93a')]()===_0x400bc8('0x659')&&(_0x3ee564['dialogflow']['prefix']=_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0xd31')]?_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0xd31')][_0x400bc8('0x1fc5')]('$')[0x0]:undefined,_0x3ee564[_0x400bc8('0x205c')]['callerId']=_0x3ee564['dialogflow']['callerID']?_0x400bc8('0xac1')+_0x3ee564[_0x400bc8('0x205c')][_0x400bc8('0x73c')]:undefined);_0x3ee564[_0x400bc8('0x2671')]=_0x3ee271,_0x3ee564[_0x400bc8('0xf82')]=_0x450053;function _0x3ee271(){const _0x444e99=_0x400bc8;_0x3ee564[_0x444e99('0x17f')]=[];const _0x10d530=[];_0x3ee564[_0x444e99('0x205c')][_0x444e99('0xcf0')]&&_0x3ee564['dialogflow'][_0x444e99('0xcf0')]['toLowerCase']()===_0x444e99('0x17cd')&&_0x3ee564[_0x444e99('0x205c')][_0x444e99('0x11f3')]===_0x444e99('0x4d2')&&(_0x3ee564[_0x444e99('0x205c')]['phone']=_0x311dcc[_0x444e99('0x145a')]?(_0x3ee564[_0x444e99('0x205c')]['prefix']||'')+_0x444e99('0x249e')+_0x311dcc[_0x444e99('0x145a')]+'}':(_0x3ee564['dialogflow'][_0x444e99('0x24fa')]||'')+_0x444e99('0x20cb'),_0x311dcc['recordingFormat']!=='none'?_0x3ee564['dialogflow'][_0x444e99('0x158e')]['indexOf'](_0x444e99('0x1b1'))<0x0&&(_0x3ee564[_0x444e99('0x205c')][_0x444e99('0x158e')]+='U(xcally-mixmonitor-context)'):_0x3ee564[_0x444e99('0x205c')][_0x444e99('0x158e')]=_0x3ee564[_0x444e99('0x205c')]['options'][_0x444e99('0x1725')](_0x444e99('0x1b1'),''));if(_0x3ee564['dialogflow'][_0x444e99('0x11f3')]&&_0x3ee564[_0x444e99('0x205c')]['appType']===_0x444e99('0xbf0')){}else switch((_0x3ee564[_0x444e99('0x205c')]['app']||_0x3ee564[_0x444e99('0x205c')][_0x444e99('0x11f3')])[_0x444e99('0x93a')]()){case'set':_0x3ee564[_0x444e99('0x205c')][_0x444e99('0x1407')]=_0x3ee564['dialogflow'][_0x444e99('0x60a')]+'='+_0x3ee564[_0x444e99('0x205c')][_0x444e99('0x1c6b')];break;case _0x444e99('0xbf0'):break;default:_0x10d530[0x0]=_0x3ee564[_0x444e99('0x205c')]['key'],_0x10d530[0x1]=_0x3ee564[_0x444e99('0x205c')][_0x444e99('0x1a1c')],_0x10d530[0x2]=_0x3ee564[_0x444e99('0x205c')][_0x444e99('0x6d9')],_0x3ee564[_0x444e99('0x205c')][_0x444e99('0x1407')]=_0x10d530[_0x444e99('0x1630')](',');}_0x450053(_0x3ee564[_0x444e99('0x205c')]);}function _0x450053(_0x2ef2e1){const _0x3493d0=_0x400bc8;_0x13be57[_0x3493d0('0x1715')](_0x2ef2e1);}}const _0x32e253=_0x22ce2a;_0x33c853[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'openchannelAccountApp',_0x189033('0x1963'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x33c853(_0x22872d,_0x31c6d7,_0x4c25ee,_0x443fe5,_0x4063d5,_0x35ccc2,_0x22d3d4,_0x3d5b4c){const _0x3c9c9d=_0x189033,_0x2e41d1=this;_0x2e41d1['currentUser']=_0x22d3d4[_0x3c9c9d('0x20b2')](),_0x2e41d1[_0x3c9c9d('0x17f')]=[],_0x2e41d1['title']=_0x3c9c9d('0x505')+(_0x443fe5[_0x3c9c9d('0x11f3')]||_0x443fe5[_0x3c9c9d('0x1d75')])[_0x3c9c9d('0x80')](),_0x2e41d1['gotoif']=angular[_0x3c9c9d('0x1a86')](_0x443fe5),_0x2e41d1[_0x3c9c9d('0x1134')]=_0x3d5b4c,_0x2e41d1[_0x3c9c9d('0x258d')]={};if(_0x2e41d1[_0x3c9c9d('0xc33')]['appdata'])switch(_0x2e41d1['gotoif'][_0x3c9c9d('0x11f3')]?_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x11f3')][_0x3c9c9d('0x93a')]():_0x2e41d1['gotoif'][_0x3c9c9d('0x1d75')][_0x3c9c9d('0x93a')]()){case'custom':break;case _0x3c9c9d('0x205c'):{const _0x2147b3=_0x2e41d1[_0x3c9c9d('0xc33')]['appdata'][_0x3c9c9d('0x1fc5')](',');_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x1d46')]=_0x2147b3[0x0],_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x1a1c')]=_0x2147b3[0x1],_0x2e41d1[_0x3c9c9d('0xc33')]['welcomemessage']=_0x2147b3['slice'](0x2,_0x2147b3[_0x3c9c9d('0x1564')])[_0x3c9c9d('0x1630')](',');}break;case'dialogflowv2':{const _0x58571b=_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x1407')][_0x3c9c9d('0x1fc5')](',');_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x2119')]=_0x58571b[0x0],_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x38')]=_0x58571b[0x1],_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x406')]=_0x58571b[0x2],_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x1a1c')]=_0x58571b[0x3],_0x2e41d1[_0x3c9c9d('0xc33')]['welcomemessage']=_0x58571b[_0x3c9c9d('0x12c8')](0x4,_0x58571b[_0x3c9c9d('0x1564')])[_0x3c9c9d('0x1630')](',');}break;case'amazonlex':{const _0x1f0e52=_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x1407')]['split'](',');_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x7ae')]=_0x1f0e52[0x0],_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x204a')]=_0x1f0e52[0x1],_0x2e41d1['gotoif']['lexregion']=_0x1f0e52[0x2],_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x11a9')]=_0x1f0e52[0x3],_0x2e41d1[_0x3c9c9d('0xc33')]['welcomemessage']=_0x1f0e52[_0x3c9c9d('0x12c8')](0x4,_0x1f0e52[_0x3c9c9d('0x1564')])[_0x3c9c9d('0x1630')](',');}break;case _0x3c9c9d('0x2408'):{const _0x9a051e=_0x2e41d1['gotoif']['appdata'][_0x3c9c9d('0x1fc5')](',');_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x35')]=isNaN(_0x9a051e[0x0])?_0x9a051e[0x0]:parseInt(_0x9a051e[0x0],0xa),_0x2e41d1['gotoif'][_0x3c9c9d('0x1bcd')]=_0x9a051e[_0x3c9c9d('0x12c8')](0x1,_0x9a051e[_0x3c9c9d('0x1564')])['join'](',');}break;case _0x3c9c9d('0x8c2'):_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x1bcd')]=_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x1407')];break;case _0x3c9c9d('0x877'):_0x2e41d1['gotoif']['name']=_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x1407')][_0x3c9c9d('0x1fc5')]('=')[0x0],_0x2e41d1[_0x3c9c9d('0xc33')]['value']=_0x2e41d1['gotoif']['appdata'][_0x3c9c9d('0x1fc5')]('=')[0x1];break;case'agi':_0x2e41d1['gotoif']['project']=_0x2e41d1[_0x3c9c9d('0xc33')]['appdata'];break;default:{const _0x3bd8ec=_0x2e41d1[_0x3c9c9d('0xc33')]['appdata'][_0x3c9c9d('0x1fc5')](',');_0x2e41d1['gotoif'][_0x3c9c9d('0x168e')]=_0x2e3ca0()[_0x3c9c9d('0x173f')](_0x3bd8ec[0x0])?_0x3bd8ec[0x0]:isNaN(_0x3bd8ec[0x0])?_0x3bd8ec[0x0]:parseInt(_0x3bd8ec[0x0],0xa),_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x27e5')]=_0x2e3ca0()[_0x3c9c9d('0x173f')](_0x3bd8ec[0x1])?_0x3bd8ec[0x1]:isNaN(_0x3bd8ec[0x1])?_0x3bd8ec[0x1]:parseInt(_0x3bd8ec[0x1],0xa),_0x2e41d1['gotoif'][_0x3c9c9d('0x1813')]=_0x2e3ca0()['isEmpty'](_0x3bd8ec[0x2])?_0x3bd8ec[0x2]:isNaN(_0x3bd8ec[0x2])?_0x3bd8ec[0x2]:parseInt(_0x3bd8ec[0x2],0xa);}break;}else{}_0x2e41d1[_0x3c9c9d('0xc33')]['type']&&_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0xcf0')][_0x3c9c9d('0x93a')]()===_0x3c9c9d('0x17cd')&&_0x2e41d1['gotoif'][_0x3c9c9d('0x11f3')]['toLowerCase']()==='outbounddial'&&(_0x2e41d1[_0x3c9c9d('0xc33')]['prefix']=_0x2e41d1['gotoif'][_0x3c9c9d('0xd31')]?_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0xd31')][_0x3c9c9d('0x1fc5')]('$')[0x0]:undefined,_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0xabd')]=_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x73c')]?_0x3c9c9d('0xac1')+_0x2e41d1[_0x3c9c9d('0xc33')][_0x3c9c9d('0x73c')]:undefined);_0x2e41d1['saveOpenchannelAccountApp']=_0x3938ec,_0x2e41d1[_0x3c9c9d('0xf82')]=_0x290fcf;function _0x3938ec(){const _0x4a72b7=_0x3c9c9d;_0x2e41d1['errors']=[];const _0x3029e8=[];_0x2e41d1[_0x4a72b7('0xc33')]['type']&&_0x2e41d1[_0x4a72b7('0xc33')]['type'][_0x4a72b7('0x93a')]()===_0x4a72b7('0x17cd')&&_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x11f3')]===_0x4a72b7('0x4d2')&&(_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0xd31')]=_0x4063d5[_0x4a72b7('0x145a')]?(_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x24fa')]||'')+_0x4a72b7('0x249e')+_0x4063d5[_0x4a72b7('0x145a')]+'}':(_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x24fa')]||'')+_0x4a72b7('0x20cb'),_0x4063d5['recordingFormat']!==_0x4a72b7('0x925')?_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x158e')][_0x4a72b7('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x158e')]+='U(xcally-mixmonitor-context)'):_0x2e41d1['gotoif'][_0x4a72b7('0x158e')]=_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x158e')][_0x4a72b7('0x1725')](_0x4a72b7('0x1b1'),''));if(_0x2e41d1[_0x4a72b7('0xc33')]['appType']&&_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x11f3')]==='custom'){}else switch((_0x2e41d1['gotoif'][_0x4a72b7('0x1d75')]||_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x11f3')])[_0x4a72b7('0x93a')]()){case _0x4a72b7('0x877'):_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x1407')]=_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x60a')]+'='+_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x1c6b')];break;case _0x4a72b7('0xbf0'):break;default:_0x3029e8[0x0]=_0x2e41d1['gotoif'][_0x4a72b7('0x168e')],_0x3029e8[0x1]=_0x2e41d1['gotoif'][_0x4a72b7('0x27e5')],_0x3029e8[0x2]=_0x2e41d1[_0x4a72b7('0xc33')][_0x4a72b7('0x1813')],_0x2e41d1['gotoif'][_0x4a72b7('0x1407')]=_0x3029e8[_0x4a72b7('0x1630')](',');}_0x290fcf(_0x2e41d1['gotoif']);}function _0x290fcf(_0x3df557){_0x22872d['hide'](_0x3df557);}}const _0x480a8c=_0x33c853;_0x468b29[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0xbc7'),_0x189033('0x1963'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x468b29(_0x3b2db1,_0x4aafda,_0x38c602,_0x4ff187,_0x31126e,_0x329c36,_0x87d616,_0x27b5b3){const _0x5c421e=_0x189033,_0x5915b4=this;_0x5915b4['currentUser']=_0x87d616[_0x5c421e('0x20b2')](),_0x5915b4[_0x5c421e('0x17f')]=[],_0x5915b4[_0x5c421e('0xf28')]=_0x5c421e('0x505')+(_0x4ff187[_0x5c421e('0x11f3')]||_0x4ff187[_0x5c421e('0x1d75')])[_0x5c421e('0x80')](),_0x5915b4['gotop']=angular['copy'](_0x4ff187),_0x5915b4[_0x5c421e('0x1134')]=_0x27b5b3,_0x5915b4[_0x5c421e('0x258d')]={};if(_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')])switch(_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x11f3')]?_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x11f3')][_0x5c421e('0x93a')]():_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1d75')][_0x5c421e('0x93a')]()){case'custom':break;case _0x5c421e('0x205c'):{const _0x3cccbf=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')][_0x5c421e('0x1fc5')](',');_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1d46')]=_0x3cccbf[0x0],_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1a1c')]=_0x3cccbf[0x1],_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x6d9')]=_0x3cccbf[_0x5c421e('0x12c8')](0x2,_0x3cccbf[_0x5c421e('0x1564')])[_0x5c421e('0x1630')](',');}break;case _0x5c421e('0xd24'):{const _0xf93217=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')][_0x5c421e('0x1fc5')](',');_0x5915b4['gotop']['projectId']=_0xf93217[0x0],_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x38')]=_0xf93217[0x1],_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x406')]=_0xf93217[0x2],_0x5915b4['gotop'][_0x5c421e('0x1a1c')]=_0xf93217[0x3],_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x6d9')]=_0xf93217['slice'](0x4,_0xf93217[_0x5c421e('0x1564')])[_0x5c421e('0x1630')](',');}break;case'amazonlex':{const _0x312ca4=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')][_0x5c421e('0x1fc5')](',');_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x7ae')]=_0x312ca4[0x0],_0x5915b4['gotop'][_0x5c421e('0x204a')]=_0x312ca4[0x1],_0x5915b4['gotop'][_0x5c421e('0x5ba')]=_0x312ca4[0x2],_0x5915b4['gotop'][_0x5c421e('0x11a9')]=_0x312ca4[0x3],_0x5915b4['gotop']['welcomemessage']=_0x312ca4[_0x5c421e('0x12c8')](0x4,_0x312ca4['length'])[_0x5c421e('0x1630')](',');}break;case _0x5c421e('0x2408'):{const _0xa18f39=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')]['split'](',');_0x5915b4[_0x5c421e('0x1da0')]['times']=isNaN(_0xa18f39[0x0])?_0xa18f39[0x0]:parseInt(_0xa18f39[0x0],0xa),_0x5915b4['gotop'][_0x5c421e('0x1bcd')]=_0xa18f39['slice'](0x1,_0xa18f39['length'])[_0x5c421e('0x1630')](',');}break;case'message':_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1bcd')]=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')];break;case _0x5c421e('0x877'):_0x5915b4['gotop']['name']=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')][_0x5c421e('0x1fc5')]('=')[0x0],_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1c6b')]=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')][_0x5c421e('0x1fc5')]('=')[0x1];break;case'agi':_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x273a')]=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')];break;default:{const _0x4d475d=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x1407')]['split'](',');_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0xe1e')]=_0x2e3ca0()[_0x5c421e('0x173f')](_0x4d475d[0x0])?_0x4d475d[0x0]:isNaN(_0x4d475d[0x0])?_0x4d475d[0x0]:parseInt(_0x4d475d[0x0],0xa);}break;}else{}_0x5915b4[_0x5c421e('0x1da0')]['type']&&_0x5915b4['gotop'][_0x5c421e('0xcf0')][_0x5c421e('0x93a')]()===_0x5c421e('0x17cd')&&_0x5915b4['gotop']['appType'][_0x5c421e('0x93a')]()==='outbounddial'&&(_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0x24fa')]=_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0xd31')]?_0x5915b4[_0x5c421e('0x1da0')][_0x5c421e('0xd31')][_0x5c421e('0x1fc5')]('$')[0x0]:undefined,_0x5915b4[_0x5c421e('0x1da0')]['callerId']=_0x5915b4[_0x5c421e('0x1da0')]['callerID']?'CALLERID(all)='+_0x5915b4[_0x5c421e('0x1da0')]['callerID']:undefined);_0x5915b4[_0x5c421e('0x2671')]=_0x56112d,_0x5915b4[_0x5c421e('0xf82')]=_0x28edf8;function _0x56112d(){const _0x2e5c10=_0x5c421e;_0x5915b4[_0x2e5c10('0x17f')]=[];const _0x2f95cb=[];_0x5915b4[_0x2e5c10('0x1da0')]['type']&&_0x5915b4[_0x2e5c10('0x1da0')]['type'][_0x2e5c10('0x93a')]()===_0x2e5c10('0x17cd')&&_0x5915b4[_0x2e5c10('0x1da0')]['appType']===_0x2e5c10('0x4d2')&&(_0x5915b4[_0x2e5c10('0x1da0')][_0x2e5c10('0xd31')]=_0x31126e[_0x2e5c10('0x145a')]?(_0x5915b4['gotop'][_0x2e5c10('0x24fa')]||'')+'${EXTEN:'+_0x31126e[_0x2e5c10('0x145a')]+'}':(_0x5915b4[_0x2e5c10('0x1da0')][_0x2e5c10('0x24fa')]||'')+_0x2e5c10('0x20cb'),_0x31126e[_0x2e5c10('0x75b')]!==_0x2e5c10('0x925')?_0x5915b4[_0x2e5c10('0x1da0')]['options']['indexOf'](_0x2e5c10('0x1b1'))<0x0&&(_0x5915b4['gotop'][_0x2e5c10('0x158e')]+=_0x2e5c10('0x1b1')):_0x5915b4[_0x2e5c10('0x1da0')][_0x2e5c10('0x158e')]=_0x5915b4[_0x2e5c10('0x1da0')][_0x2e5c10('0x158e')][_0x2e5c10('0x1725')](_0x2e5c10('0x1b1'),''));if(_0x5915b4['gotop']['appType']&&_0x5915b4[_0x2e5c10('0x1da0')][_0x2e5c10('0x11f3')]===_0x2e5c10('0xbf0')){}else switch((_0x5915b4[_0x2e5c10('0x1da0')][_0x2e5c10('0x1d75')]||_0x5915b4['gotop']['appType'])[_0x2e5c10('0x93a')]()){case _0x2e5c10('0x877'):_0x5915b4['gotop'][_0x2e5c10('0x1407')]=_0x5915b4['gotop'][_0x2e5c10('0x60a')]+'='+_0x5915b4[_0x2e5c10('0x1da0')][_0x2e5c10('0x1c6b')];break;case _0x2e5c10('0xbf0'):break;default:_0x2f95cb[0x0]=_0x5915b4[_0x2e5c10('0x1da0')][_0x2e5c10('0xe1e')],_0x5915b4[_0x2e5c10('0x1da0')][_0x2e5c10('0x1407')]=_0x2f95cb[_0x2e5c10('0x1630')](',');}_0x28edf8(_0x5915b4[_0x2e5c10('0x1da0')]);}function _0x28edf8(_0x405613){const _0x193690=_0x5c421e;_0x3b2db1[_0x193690('0x1715')](_0x405613);}}const _0xc6dbf=_0x468b29;_0x18408c[_0x189033('0x14be')]=[_0x189033('0x938'),'$mdDialog','$mdToast',_0x189033('0x844'),_0x189033('0x115c'),_0x189033('0xe98'),_0x189033('0x1d70'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x18408c(_0x30306a,_0x47bcfb,_0x3054f7,_0x363d43,_0x3e1e6f,_0x5be625,_0x4f25f5,_0x4d3ea2,_0x4a12bc,_0xf0970d){const _0x40164c=_0x189033,_0x283126=this;_0x283126[_0x40164c('0x11ed')]=_0x4a12bc[_0x40164c('0x20b2')](),_0x283126[_0x40164c('0x17f')]=[],_0x283126[_0x40164c('0xf28')]=_0x40164c('0xc62'),_0x283126['interval']=angular[_0x40164c('0x1a86')](_0x3e1e6f),_0x283126[_0x40164c('0xe98')]=_0x5be625,_0x283126[_0x40164c('0x1470')]=![],_0x283126[_0x40164c('0x1de1')]=[_0x40164c('0x10af'),'custom',_0x40164c('0x2335')],_0x283126[_0x40164c('0x1134')]=_0xf0970d,_0x283126[_0x40164c('0x167a')]=_0x363d43[_0x40164c('0xe88')](),_0x283126['monthNumber']=_0x363d43[_0x40164c('0x222e')](),_0x283126['monthName']=_0x363d43[_0x40164c('0x1fe4')](),_0x283126[_0x40164c('0x13ce')]=_0x363d43['getDaysOfMonth']();if(!_0x283126[_0x40164c('0x115c')])_0x283126[_0x40164c('0x115c')]={'interval':'*,*,*,*'},_0x283126[_0x40164c('0xcf0')]=_0x40164c('0x10af'),_0x283126['title']=_0x40164c('0x1e94'),_0x283126[_0x40164c('0x1470')]=!![];else{if(_0x283126[_0x40164c('0x115c')]['interval']!==_0x40164c('0x1b54')){_0x283126[_0x40164c('0xcf0')]=_0x40164c('0xbf0');const _0x1cb752=_0x283126[_0x40164c('0x115c')][_0x40164c('0x115c')]['split'](','),_0x31061c=_0x1cb752[0x0],_0x20533b=_0x1cb752[0x1],_0x43bd97=_0x1cb752[0x2],_0x159e59=_0x1cb752[0x3];if(_0x31061c!=='*'){const _0x195544=_0x31061c[_0x40164c('0x1fc5')]('-')[0x0],_0x103161=_0x31061c[_0x40164c('0x1fc5')]('-')[0x1];let _0x1cd873;_0x1cd873=new Date(),_0x1cd873[_0x40164c('0x2813')](Number(_0x195544[_0x40164c('0x1fc5')](':')[0x0])),_0x1cd873[_0x40164c('0x1fb7')](Number(_0x195544[_0x40164c('0x1fc5')](':')[0x1])),_0x283126['timeRangeFrom']=_0x1cd873,_0x1cd873=new Date(),_0x1cd873[_0x40164c('0x2813')](Number(_0x103161['split'](':')[0x0])),_0x1cd873[_0x40164c('0x1fb7')](Number(_0x103161['split'](':')[0x1])),_0x283126['timeRangeTo']=_0x1cd873;}_0x20533b!=='*'&&(_0x283126['dayOfWeekFrom']=_0x20533b[_0x40164c('0x1fc5')]('-')[0x0],_0x283126[_0x40164c('0x1269')]=_0x20533b[_0x40164c('0x1fc5')]('-')[0x1]),_0x43bd97!=='*'&&(_0x283126[_0x40164c('0xf13')]=_0x43bd97[_0x40164c('0x1fc5')]('-')[0x0],_0x283126[_0x40164c('0xfe5')]=_0x43bd97[_0x40164c('0x1fc5')]('-')[0x1]),_0x159e59!=='*'&&(_0x283126[_0x40164c('0x1690')]=_0x159e59[_0x40164c('0x1fc5')]('-')[0x0],_0x283126[_0x40164c('0x1f12')]=_0x159e59['split']('-')[0x1]);}else _0x283126['type']=_0x40164c('0x10af');}_0x30306a[_0x40164c('0x7f2')]['id']&&!_0x283126[_0x40164c('0x115c')]['application']&&(_0x283126[_0x40164c('0x115c')]['IntervalId']=_0x30306a['params']['id']);_0x283126[_0x40164c('0x115c')][_0x40164c('0x5ae')]&&_0x283126['interval'][_0x40164c('0x121e')]&&(_0x283126[_0x40164c('0xcf0')]=_0x40164c('0x2335'));_0x283126[_0x40164c('0x1a4d')]=_0x133958,_0x283126[_0x40164c('0x1807')]=_0x3ad704,_0x283126[_0x40164c('0xf82')]=_0x33917c;_0x283126[_0x40164c('0x115c')][_0x40164c('0x121e')]&&(_0x4a12bc[_0x40164c('0xca1')](_0x40164c('0x20c2'))?_0x4d3ea2['interval'][_0x40164c('0x1e6e')]({'fields':_0x40164c('0x1e24'),'IntervalId':_0x40164c('0x13c'),'nolimit':!![]})[_0x40164c('0xe53')]['then'](function(_0x4e290d){const _0x80139f=_0x40164c;_0x283126[_0x80139f('0xe98')]=_0x4e290d[_0x80139f('0xf5d')]||[];})[_0x40164c('0x130a')](function(_0x3d4100){const _0x41b68e=_0x40164c;_0x4f25f5[_0x41b68e('0x52a')]({'title':_0x3d4100[_0x41b68e('0x13ee')]?_0x41b68e('0x2168')+_0x3d4100[_0x41b68e('0x13ee')]+_0x41b68e('0xbf6')+_0x3d4100[_0x41b68e('0x24a9')]:'SYSTEM:GET_INTERVALS','msg':_0x3d4100[_0x41b68e('0x5a5')]?JSON['stringify'](_0x3d4100[_0x41b68e('0x5a5')]):_0x3d4100[_0x41b68e('0x1ff0')]()});}):_0x4d3ea2['interval'][_0x40164c('0x1e6e')]({'fields':_0x40164c('0x1e24'),'IntervalId':'null','nolimit':!![]})[_0x40164c('0xe53')][_0x40164c('0x683')](function(_0x5ec757){const _0x10ceb6=_0x40164c;_0x283126[_0x10ceb6('0xe98')]=_0x5ec757[_0x10ceb6('0xf5d')]||[];})[_0x40164c('0x683')](function(){const _0x34dbed=_0x40164c;return _0x4d3ea2['userProfileSection'][_0x34dbed('0x1e6e')]({'userProfileId':_0x283126['currentUser'][_0x34dbed('0x2f')],'sectionId':0x3ec})[_0x34dbed('0xe53')];})[_0x40164c('0x683')](function(_0x23b43a){const _0x3cfbb3=_0x40164c,_0x1671f1=_0x23b43a&&_0x23b43a['rows']?_0x23b43a['rows'][0x0]:null;if(!_0x1671f1)_0x283126[_0x3cfbb3('0xe98')]=[];else{if(!_0x1671f1[_0x3cfbb3('0x170')])return _0x4d3ea2['userProfileResource'][_0x3cfbb3('0x1e6e')]({'sectionId':_0x1671f1['id']})[_0x3cfbb3('0xe53')][_0x3cfbb3('0x683')](function(_0x44f184){const _0x400b2f=_0x3cfbb3,_0x151ea6=_0x44f184&&_0x44f184['rows']?_0x44f184[_0x400b2f('0xf5d')]:[],_0x2f7a39=[];let _0x4e5d3c=null;_0x283126['interval']&&(_0x4e5d3c=_0x2e3ca0()['find'](_0x283126['intervals'],{'name':_0x283126[_0x400b2f('0x115c')][_0x400b2f('0x5ae')]})),_0x4e5d3c&&!_0x2e3ca0()[_0x400b2f('0x7a2')](_0x151ea6,[_0x400b2f('0x832'),_0x4e5d3c['id']])&&_0x283126[_0x400b2f('0xe98')][_0x400b2f('0x1299')](function(_0x51fee5){const _0x274dcf=_0x400b2f;_0x51fee5['id']===_0x4e5d3c['id']&&(_0x51fee5['canSelect']=![],_0x2f7a39[_0x274dcf('0x1fd0')](_0x51fee5));}),_0x283126['intervals']=_0x2f7a39;});}})[_0x40164c('0x130a')](function(_0x52ed61){const _0x2066ea=_0x40164c;_0x4f25f5[_0x2066ea('0x52a')]({'title':_0x52ed61[_0x2066ea('0x13ee')]?_0x2066ea('0x2168')+_0x52ed61[_0x2066ea('0x13ee')]+_0x2066ea('0xbf6')+_0x52ed61[_0x2066ea('0x24a9')]:_0x2066ea('0x1e65'),'msg':_0x52ed61[_0x2066ea('0x5a5')]?JSON[_0x2066ea('0x258a')](_0x52ed61[_0x2066ea('0x5a5')]):_0x52ed61[_0x2066ea('0x1ff0')]()});}));function _0x3c7332(){const _0x17c81c=_0x40164c;switch(_0x283126[_0x17c81c('0xcf0')]){case _0x17c81c('0x10af'):case _0x17c81c('0x2335'):return _0x17c81c('0x1b54');case _0x17c81c('0xbf0'):{const _0x42da1b=[];if(_0x283126['timeRangeFrom']!=='*'&&_0x283126[_0x17c81c('0xc32')]&&_0x283126['timeRangeTo']){const _0x34ef4c=(_0x283126['timeRangeFrom'][_0x17c81c('0x2575')]()<0xa?'0':'')+_0x283126['timeRangeFrom'][_0x17c81c('0x2575')]()+':'+((_0x283126[_0x17c81c('0xc32')]['getMinutes']()<0xa?'0':'')+_0x283126[_0x17c81c('0xc32')][_0x17c81c('0x1b5b')]()),_0x276eff=(_0x283126['timeRangeTo'][_0x17c81c('0x2575')]()<0xa?'0':'')+_0x283126['timeRangeTo'][_0x17c81c('0x2575')]()+':'+((_0x283126[_0x17c81c('0xaa0')][_0x17c81c('0x1b5b')]()<0xa?'0':'')+_0x283126[_0x17c81c('0xaa0')][_0x17c81c('0x1b5b')]());_0x42da1b[_0x17c81c('0x1fd0')](_0x34ef4c+'-'+_0x276eff);}else _0x42da1b[_0x17c81c('0x1fd0')]('*');return _0x283126[_0x17c81c('0x232d')]?_0x283126[_0x17c81c('0x1269')]?_0x42da1b[_0x17c81c('0x1fd0')](_0x283126[_0x17c81c('0x232d')]+'-'+_0x283126[_0x17c81c('0x1269')]):_0x42da1b[_0x17c81c('0x1fd0')](_0x283126[_0x17c81c('0x232d')]):_0x42da1b[_0x17c81c('0x1fd0')]('*'),_0x283126['monthDayFrom']?_0x283126[_0x17c81c('0xfe5')]?_0x42da1b[_0x17c81c('0x1fd0')](_0x283126[_0x17c81c('0xf13')]+'-'+_0x283126[_0x17c81c('0xfe5')]):_0x42da1b[_0x17c81c('0x1fd0')](_0x283126['monthDayFrom']):_0x42da1b[_0x17c81c('0x1fd0')]('*'),_0x283126[_0x17c81c('0x1690')]?_0x283126['monthTo']?_0x42da1b['push'](_0x283126['monthFrom']+'-'+_0x283126['monthTo']):_0x42da1b['push'](_0x283126['monthFrom']):_0x42da1b[_0x17c81c('0x1fd0')]('*'),_0x42da1b['join']();}}}function _0x133958(){const _0x1dab71=_0x40164c;_0x283126['errors']=[],_0x283126[_0x1dab71('0x115c')]['interval']=_0x3c7332(),_0x4d3ea2[_0x1dab71('0x115c')][_0x1dab71('0xb0a')](_0x283126[_0x1dab71('0x115c')])[_0x1dab71('0xe53')][_0x1dab71('0x683')](function(_0x1ccf71){const _0x31ca18=_0x1dab71;_0x283126['intervals'][_0x31ca18('0x1fd0')](_0x1ccf71),_0x4f25f5[_0x31ca18('0x53')]({'title':_0x31ca18('0x24b5'),'msg':_0x283126[_0x31ca18('0x115c')]['name']?_0x283126['interval'][_0x31ca18('0x60a')]+'\x20has\x20been\x20created!':''}),_0x33917c();})[_0x1dab71('0x130a')](function(_0x3278dc){const _0x323829=_0x1dab71;console[_0x323829('0x52a')](_0x3278dc),_0x283126[_0x323829('0x17f')]=_0x3278dc[_0x323829('0x5a5')][_0x323829('0x17f')]||[{'message':_0x3278dc[_0x323829('0x1ff0')](),'type':_0x323829('0x1d24')}];});}function _0x3ad704(){const _0x27d995=_0x40164c;_0x283126[_0x27d995('0x17f')]=[],_0x283126[_0x27d995('0x115c')][_0x27d995('0x115c')]=_0x3c7332(),_0x283126[_0x27d995('0x115c')][_0x27d995('0x121e')]?(_0x283126['type']!==_0x27d995('0x2335')&&(_0x283126[_0x27d995('0x115c')]['IntervalId']=null),_0x33917c(_0x283126[_0x27d995('0x115c')])):_0x4d3ea2['interval'][_0x27d995('0x2480')]({'id':_0x283126[_0x27d995('0x115c')]['id']},_0x283126[_0x27d995('0x115c')])[_0x27d995('0xe53')][_0x27d995('0x683')](function(_0x10bd53){const _0x585e94=_0x27d995,_0x1a56b8=_0x2e3ca0()['find'](_0x283126['intervals'],{'id':_0x10bd53['id']});_0x1a56b8&&_0x2e3ca0()['merge'](_0x1a56b8,_0x10bd53),_0x4f25f5[_0x585e94('0x53')]({'title':_0x585e94('0x18c3'),'msg':'Interval\x20has\x20been\x20saved!'}),_0x33917c();})[_0x27d995('0x130a')](function(_0x174e56){const _0x2ac436=_0x27d995;console[_0x2ac436('0x52a')](_0x174e56),_0x283126['errors']=_0x174e56[_0x2ac436('0x5a5')]['errors']||[{'message':_0x174e56[_0x2ac436('0x1ff0')](),'type':'api.interval.update'}];});}function _0x33917c(_0x1a3666){const _0x3c6b92=_0x40164c;_0x47bcfb[_0x3c6b92('0x1715')](_0x1a3666);}}const _0x41f7f=_0x18408c;_0x5329aa['$inject']=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0xbc7'),'openchannelAccount','api','Auth','crudPermissions'];function _0x5329aa(_0x201c94,_0x52989b,_0x529957,_0x2e9d6b,_0x45ff6b,_0x2c6949,_0xd3b5fd,_0x29958f){const _0x2374c6=_0x189033,_0x43e7c3=this;_0x43e7c3['currentUser']=_0xd3b5fd[_0x2374c6('0x20b2')](),_0x43e7c3[_0x2374c6('0x17f')]=[],_0x43e7c3[_0x2374c6('0xf28')]=_0x2374c6('0x505')+(_0x2e9d6b[_0x2374c6('0x11f3')]||_0x2e9d6b[_0x2374c6('0x1d75')])[_0x2374c6('0x80')](),_0x43e7c3[_0x2374c6('0x1126')]=angular['copy'](_0x2e9d6b),_0x43e7c3[_0x2374c6('0x1134')]=_0x29958f,_0x43e7c3[_0x2374c6('0x258d')]={};if(_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1407')])switch(_0x43e7c3['noop'][_0x2374c6('0x11f3')]?_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x11f3')]['toLowerCase']():_0x43e7c3[_0x2374c6('0x1126')]['app'][_0x2374c6('0x93a')]()){case _0x2374c6('0xbf0'):break;case _0x2374c6('0x205c'):{const _0x48ffae=_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1407')][_0x2374c6('0x1fc5')](',');_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1d46')]=_0x48ffae[0x0],_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1a1c')]=_0x48ffae[0x1],_0x43e7c3['noop']['welcomemessage']=_0x48ffae['slice'](0x2,_0x48ffae[_0x2374c6('0x1564')])[_0x2374c6('0x1630')](',');}break;case _0x2374c6('0xd24'):{const _0x4fa7e3=_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1407')][_0x2374c6('0x1fc5')](',');_0x43e7c3['noop']['projectId']=_0x4fa7e3[0x0],_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x38')]=_0x4fa7e3[0x1],_0x43e7c3[_0x2374c6('0x1126')]['privateKey']=_0x4fa7e3[0x2],_0x43e7c3[_0x2374c6('0x1126')]['language']=_0x4fa7e3[0x3],_0x43e7c3[_0x2374c6('0x1126')]['welcomemessage']=_0x4fa7e3[_0x2374c6('0x12c8')](0x4,_0x4fa7e3[_0x2374c6('0x1564')])[_0x2374c6('0x1630')](',');}break;case _0x2374c6('0x1db1'):{const _0x5a3337=_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1407')][_0x2374c6('0x1fc5')](',');_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x7ae')]=_0x5a3337[0x0],_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x204a')]=_0x5a3337[0x1],_0x43e7c3['noop']['lexregion']=_0x5a3337[0x2],_0x43e7c3['noop'][_0x2374c6('0x11a9')]=_0x5a3337[0x3],_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x6d9')]=_0x5a3337[_0x2374c6('0x12c8')](0x4,_0x5a3337[_0x2374c6('0x1564')])[_0x2374c6('0x1630')](',');}break;case'autoreply':{const _0x49874d=_0x43e7c3[_0x2374c6('0x1126')]['appdata']['split'](',');_0x43e7c3[_0x2374c6('0x1126')]['times']=isNaN(_0x49874d[0x0])?_0x49874d[0x0]:parseInt(_0x49874d[0x0],0xa),_0x43e7c3['noop'][_0x2374c6('0x1bcd')]=_0x49874d[_0x2374c6('0x12c8')](0x1,_0x49874d[_0x2374c6('0x1564')])[_0x2374c6('0x1630')](',');}break;case _0x2374c6('0x8c2'):_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1bcd')]=_0x43e7c3['noop'][_0x2374c6('0x1407')];break;case _0x2374c6('0x877'):_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x60a')]=_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1407')]['split']('=')[0x0],_0x43e7c3['noop'][_0x2374c6('0x1c6b')]=_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1407')][_0x2374c6('0x1fc5')]('=')[0x1];break;case _0x2374c6('0x19ae'):_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x273a')]=_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x1407')];break;default:{const _0x48fdb5=_0x43e7c3['noop'][_0x2374c6('0x1407')][_0x2374c6('0x1fc5')](',');_0x43e7c3[_0x2374c6('0x1126')]['value']=_0x2e3ca0()[_0x2374c6('0x173f')](_0x48fdb5[0x0])?_0x48fdb5[0x0]:isNaN(_0x48fdb5[0x0])?_0x48fdb5[0x0]:parseInt(_0x48fdb5[0x0],0xa);}break;}else{}_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0xcf0')]&&_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0xcf0')][_0x2374c6('0x93a')]()==='outbound'&&_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x11f3')][_0x2374c6('0x93a')]()===_0x2374c6('0x659')&&(_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x24fa')]=_0x43e7c3['noop']['phone']?_0x43e7c3[_0x2374c6('0x1126')]['phone'][_0x2374c6('0x1fc5')]('$')[0x0]:undefined,_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0xabd')]=_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x73c')]?_0x2374c6('0xac1')+_0x43e7c3[_0x2374c6('0x1126')][_0x2374c6('0x73c')]:undefined);_0x43e7c3[_0x2374c6('0x2671')]=_0x1b7049,_0x43e7c3[_0x2374c6('0xf82')]=_0x4a4589;function _0x1b7049(){const _0x3ceb5f=_0x2374c6;_0x43e7c3[_0x3ceb5f('0x17f')]=[];const _0x284c92=[];_0x43e7c3[_0x3ceb5f('0x1126')][_0x3ceb5f('0xcf0')]&&_0x43e7c3[_0x3ceb5f('0x1126')]['type']['toLowerCase']()===_0x3ceb5f('0x17cd')&&_0x43e7c3[_0x3ceb5f('0x1126')][_0x3ceb5f('0x11f3')]===_0x3ceb5f('0x4d2')&&(_0x43e7c3[_0x3ceb5f('0x1126')][_0x3ceb5f('0xd31')]=_0x45ff6b[_0x3ceb5f('0x145a')]?(_0x43e7c3[_0x3ceb5f('0x1126')][_0x3ceb5f('0x24fa')]||'')+_0x3ceb5f('0x249e')+_0x45ff6b[_0x3ceb5f('0x145a')]+'}':(_0x43e7c3[_0x3ceb5f('0x1126')]['prefix']||'')+'${EXTEN}',_0x45ff6b[_0x3ceb5f('0x75b')]!==_0x3ceb5f('0x925')?_0x43e7c3[_0x3ceb5f('0x1126')][_0x3ceb5f('0x158e')][_0x3ceb5f('0x824')](_0x3ceb5f('0x1b1'))<0x0&&(_0x43e7c3[_0x3ceb5f('0x1126')][_0x3ceb5f('0x158e')]+=_0x3ceb5f('0x1b1')):_0x43e7c3[_0x3ceb5f('0x1126')]['options']=_0x43e7c3[_0x3ceb5f('0x1126')]['options']['replace'](_0x3ceb5f('0x1b1'),''));if(_0x43e7c3['noop']['appType']&&_0x43e7c3['noop']['appType']===_0x3ceb5f('0xbf0')){}else switch((_0x43e7c3[_0x3ceb5f('0x1126')]['app']||_0x43e7c3[_0x3ceb5f('0x1126')][_0x3ceb5f('0x11f3')])[_0x3ceb5f('0x93a')]()){case _0x3ceb5f('0x877'):_0x43e7c3[_0x3ceb5f('0x1126')]['appdata']=_0x43e7c3[_0x3ceb5f('0x1126')][_0x3ceb5f('0x60a')]+'='+_0x43e7c3[_0x3ceb5f('0x1126')]['value'];break;case'custom':break;default:_0x284c92[0x0]=_0x43e7c3['noop'][_0x3ceb5f('0x1c6b')],_0x43e7c3['noop'][_0x3ceb5f('0x1407')]=_0x284c92['join'](',');}_0x4a4589(_0x43e7c3[_0x3ceb5f('0x1126')]);}function _0x4a4589(_0x515d17){_0x201c94['hide'](_0x515d17);}}const _0x1f8b86=_0x5329aa;_0x42c97c[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'openchannelAccountApp',_0x189033('0x1963'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x42c97c(_0x5a16af,_0x1c4740,_0x12cdda,_0x54ef9c,_0x3089ae,_0x261093,_0x32a00c,_0x4d5fe8){const _0x48a2f9=_0x189033,_0x3fdf6f=this;_0x3fdf6f[_0x48a2f9('0x11ed')]=_0x32a00c[_0x48a2f9('0x20b2')](),_0x3fdf6f['errors']=[],_0x3fdf6f[_0x48a2f9('0xf28')]=_0x48a2f9('0x505')+(_0x54ef9c['appType']||_0x54ef9c['app'])[_0x48a2f9('0x80')](),_0x3fdf6f[_0x48a2f9('0x660')]=angular[_0x48a2f9('0x1a86')](_0x54ef9c),_0x3fdf6f[_0x48a2f9('0x1134')]=_0x4d5fe8,_0x3fdf6f['hasModulePermissions']={};if(_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1407')])switch(_0x3fdf6f[_0x48a2f9('0x660')]['appType']?_0x3fdf6f['queue'][_0x48a2f9('0x11f3')][_0x48a2f9('0x93a')]():_0x3fdf6f['queue'][_0x48a2f9('0x1d75')]['toLowerCase']()){case _0x48a2f9('0xbf0'):break;case'dialogflow':{const _0x335f74=_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1407')][_0x48a2f9('0x1fc5')](',');_0x3fdf6f[_0x48a2f9('0x660')]['key']=_0x335f74[0x0],_0x3fdf6f[_0x48a2f9('0x660')]['language']=_0x335f74[0x1],_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x6d9')]=_0x335f74[_0x48a2f9('0x12c8')](0x2,_0x335f74[_0x48a2f9('0x1564')])[_0x48a2f9('0x1630')](',');}break;case _0x48a2f9('0xd24'):{const _0x168069=_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1407')][_0x48a2f9('0x1fc5')](',');_0x3fdf6f[_0x48a2f9('0x660')]['projectId']=_0x168069[0x0],_0x3fdf6f['queue']['clientEmail']=_0x168069[0x1],_0x3fdf6f[_0x48a2f9('0x660')]['privateKey']=_0x168069[0x2],_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1a1c')]=_0x168069[0x3],_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x6d9')]=_0x168069[_0x48a2f9('0x12c8')](0x4,_0x168069[_0x48a2f9('0x1564')])[_0x48a2f9('0x1630')](',');}break;case'amazonlex':{const _0x25eb14=_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1407')][_0x48a2f9('0x1fc5')](',');_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x7ae')]=_0x25eb14[0x0],_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x204a')]=_0x25eb14[0x1],_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x5ba')]=_0x25eb14[0x2],_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x11a9')]=_0x25eb14[0x3],_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x6d9')]=_0x25eb14[_0x48a2f9('0x12c8')](0x4,_0x25eb14[_0x48a2f9('0x1564')])[_0x48a2f9('0x1630')](',');}break;case _0x48a2f9('0x2408'):{const _0x2eab5=_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1407')]['split'](',');_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x35')]=isNaN(_0x2eab5[0x0])?_0x2eab5[0x0]:parseInt(_0x2eab5[0x0],0xa),_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1bcd')]=_0x2eab5[_0x48a2f9('0x12c8')](0x1,_0x2eab5[_0x48a2f9('0x1564')])[_0x48a2f9('0x1630')](',');}break;case _0x48a2f9('0x8c2'):_0x3fdf6f['queue'][_0x48a2f9('0x1bcd')]=_0x3fdf6f[_0x48a2f9('0x660')]['appdata'];break;case _0x48a2f9('0x877'):_0x3fdf6f['queue'][_0x48a2f9('0x60a')]=_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1407')]['split']('=')[0x0],_0x3fdf6f[_0x48a2f9('0x660')]['value']=_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1407')][_0x48a2f9('0x1fc5')]('=')[0x1];break;case _0x48a2f9('0x19ae'):_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x273a')]=_0x3fdf6f['queue']['appdata'];break;default:{const _0x1bbb9b=_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1407')][_0x48a2f9('0x1fc5')](',');_0x3fdf6f[_0x48a2f9('0x660')]['queue']=_0x2e3ca0()['isEmpty'](_0x1bbb9b[0x0])?_0x1bbb9b[0x0]:isNaN(_0x1bbb9b[0x0])?_0x1bbb9b[0x0]:parseInt(_0x1bbb9b[0x0],0xa),_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1668')]=_0x2e3ca0()['isEmpty'](_0x1bbb9b[0x1])?_0x1bbb9b[0x1]:isNaN(_0x1bbb9b[0x1])?_0x1bbb9b[0x1]:parseInt(_0x1bbb9b[0x1],0xa);}break;}else _0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x660')]=0x12c,_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x1668')]=0x12c;_0x3fdf6f['queue'][_0x48a2f9('0xcf0')]&&_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0xcf0')][_0x48a2f9('0x93a')]()===_0x48a2f9('0x17cd')&&_0x3fdf6f['queue'][_0x48a2f9('0x11f3')]['toLowerCase']()===_0x48a2f9('0x659')&&(_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x24fa')]=_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0xd31')]?_0x3fdf6f['queue'][_0x48a2f9('0xd31')][_0x48a2f9('0x1fc5')]('$')[0x0]:undefined,_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0xabd')]=_0x3fdf6f[_0x48a2f9('0x660')][_0x48a2f9('0x73c')]?_0x48a2f9('0xac1')+_0x3fdf6f[_0x48a2f9('0x660')]['callerID']:undefined);_0x3fdf6f[_0x48a2f9('0x2671')]=_0x3d831e,_0x3fdf6f[_0x48a2f9('0xf82')]=_0x50b0c6,_0x32a00c['hasRole'](_0x48a2f9('0x20c2'))?_0x261093[_0x48a2f9('0x20a1')][_0x48a2f9('0x1e6e')]({'fields':_0x48a2f9('0x2035'),'sort':_0x48a2f9('0x60a'),'nolimit':_0x48a2f9('0x26ac')})[_0x48a2f9('0xe53')][_0x48a2f9('0x683')](function(_0x8c8b0){const _0x11a4e4=_0x48a2f9;_0x3fdf6f['queues']=_0x8c8b0[_0x11a4e4('0xf5d')]||[];})[_0x48a2f9('0x130a')](function(_0x580309){const _0x397628=_0x48a2f9;_0x12cdda['error']({'title':_0x580309['status']?_0x397628('0x2168')+_0x580309[_0x397628('0x13ee')]+'\x20-\x20'+_0x580309[_0x397628('0x24a9')]:_0x397628('0x22dc'),'msg':_0x580309[_0x397628('0x5a5')]?JSON[_0x397628('0x258a')](_0x580309[_0x397628('0x5a5')]):_0x580309[_0x397628('0x1ff0')]()});}):_0x261093['openchannelQueue'][_0x48a2f9('0x1e6e')]({'fields':'id,name,type','sort':_0x48a2f9('0x60a'),'nolimit':_0x48a2f9('0x26ac')})[_0x48a2f9('0xe53')][_0x48a2f9('0x683')](function(_0x5b0b23){const _0x2151ab=_0x48a2f9;_0x3fdf6f[_0x2151ab('0x2da')]=_0x5b0b23[_0x2151ab('0xf5d')]||[];})[_0x48a2f9('0x683')](function(){const _0x4a032b=_0x48a2f9;return _0x261093[_0x4a032b('0x22df')][_0x4a032b('0x1e6e')]({'userProfileId':_0x3fdf6f[_0x4a032b('0x11ed')][_0x4a032b('0x2f')],'sectionId':0x321})[_0x4a032b('0xe53')];})[_0x48a2f9('0x683')](function(_0x51ff64){const _0x522a6d=_0x48a2f9,_0x31f721=_0x51ff64&&_0x51ff64['rows']?_0x51ff64[_0x522a6d('0xf5d')][0x0]:null;if(!_0x31f721){const _0xd374b8=[];let _0x1668d9=null;_0x3fdf6f['queue']&&(_0x1668d9=_0x2e3ca0()[_0x522a6d('0x1c07')](_0x3fdf6f['queues'],{'name':_0x3fdf6f[_0x522a6d('0x660')][_0x522a6d('0x660')]}));for(let _0x46107b=0x0;_0x46107b<_0x3fdf6f[_0x522a6d('0x2da')][_0x522a6d('0x1564')];_0x46107b++){_0x1668d9&&_0x3fdf6f[_0x522a6d('0x2da')][_0x46107b]['id']===_0x1668d9['id']&&(_0x3fdf6f[_0x522a6d('0x2da')][_0x46107b][_0x522a6d('0x319')]=![],_0xd374b8[_0x522a6d('0x1fd0')](_0x3fdf6f[_0x522a6d('0x2da')][_0x46107b]));}_0x3fdf6f['queues']=_0xd374b8;}else{if(!_0x31f721['autoAssociation'])return _0x261093[_0x522a6d('0xcf7')][_0x522a6d('0x1e6e')]({'sectionId':_0x31f721['id']})[_0x522a6d('0xe53')][_0x522a6d('0x683')](function(_0x315150){const _0x11ba02=_0x522a6d,_0x410a90=_0x2e3ca0()[_0x11ba02('0x386')](_0x315150[_0x11ba02('0xf5d')],function(_0x1def73){const _0x2682dc=_0x11ba02;return _0x2e3ca0()[_0x2682dc('0x1c07')](_0x3fdf6f[_0x2682dc('0x2da')],{'id':_0x1def73['resourceId']});});let _0xa6e78b=null;_0x3fdf6f[_0x11ba02('0x660')]&&(_0xa6e78b=_0x2e3ca0()[_0x11ba02('0x1c07')](_0x3fdf6f['queues'],{'name':_0x3fdf6f['queue'][_0x11ba02('0x660')]}));if(_0xa6e78b&&!_0x2e3ca0()['some'](_0x410a90,['id',_0xa6e78b['id']])){const _0xd8ab73=_0x2e3ca0()['find'](_0x3fdf6f[_0x11ba02('0x2da')],{'id':_0xa6e78b['id']});_0xd8ab73[_0x11ba02('0x319')]=![],_0x410a90[_0x11ba02('0x1fd0')](_0xd8ab73);}_0x3fdf6f[_0x11ba02('0x2da')]=_0x410a90;});}})[_0x48a2f9('0x130a')](function(_0x448906){const _0xc09789=_0x48a2f9;_0x12cdda[_0xc09789('0x52a')]({'title':_0x448906[_0xc09789('0x13ee')]?_0xc09789('0x2168')+_0x448906[_0xc09789('0x13ee')]+_0xc09789('0xbf6')+_0x448906[_0xc09789('0x24a9')]:_0xc09789('0x934'),'msg':_0x448906[_0xc09789('0x5a5')]?JSON[_0xc09789('0x258a')](_0x448906[_0xc09789('0x5a5')]):_0x448906[_0xc09789('0x1ff0')]()});});function _0x3d831e(){const _0x11a95f=_0x48a2f9;_0x3fdf6f[_0x11a95f('0x17f')]=[];const _0x12a8df=[];_0x3fdf6f['queue'][_0x11a95f('0xcf0')]&&_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0xcf0')][_0x11a95f('0x93a')]()==='outbound'&&_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x11f3')]===_0x11a95f('0x4d2')&&(_0x3fdf6f['queue'][_0x11a95f('0xd31')]=_0x3089ae['cutdigits']?(_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x24fa')]||'')+_0x11a95f('0x249e')+_0x3089ae[_0x11a95f('0x145a')]+'}':(_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x24fa')]||'')+_0x11a95f('0x20cb'),_0x3089ae[_0x11a95f('0x75b')]!==_0x11a95f('0x925')?_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x158e')]['indexOf'](_0x11a95f('0x1b1'))<0x0&&(_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x158e')]+='U(xcally-mixmonitor-context)'):_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x158e')]=_0x3fdf6f['queue'][_0x11a95f('0x158e')][_0x11a95f('0x1725')](_0x11a95f('0x1b1'),''));const _0x4c9825=_0x2e3ca0()['find'](_0x3fdf6f[_0x11a95f('0x2da')],{'name':_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x660')]});_0x4c9825&&(_0x3fdf6f[_0x11a95f('0x660')][_0x2e3ca0()['capitalize']('openChannel')+'QueueId']=_0x4c9825['id']);if(_0x3fdf6f[_0x11a95f('0x660')]['appType']&&_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x11f3')]===_0x11a95f('0xbf0')){}else switch((_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x1d75')]||_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x11f3')])[_0x11a95f('0x93a')]()){case _0x11a95f('0x877'):_0x3fdf6f['queue']['appdata']=_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x60a')]+'='+_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x1c6b')];break;case _0x11a95f('0xbf0'):break;default:_0x12a8df[0x0]=_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x660')],_0x12a8df[0x1]=_0x3fdf6f[_0x11a95f('0x660')]['timeout'],_0x3fdf6f[_0x11a95f('0x660')][_0x11a95f('0x1407')]=_0x12a8df['join'](',');}_0x50b0c6(_0x3fdf6f[_0x11a95f('0x660')]);}function _0x50b0c6(_0xbb3fdd){const _0x59edfe=_0x48a2f9;_0x5a16af[_0x59edfe('0x1715')](_0xbb3fdd);}}const _0x1e8c81=_0x42c97c;_0x5ad566[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0xbc7'),'openchannelAccount',_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x5ad566(_0x4f9952,_0x4dfc5c,_0x4a4aca,_0x159f3b,_0x53ae68,_0x26f9a4,_0xc27132,_0x1073b6){const _0x5a9ad9=_0x189033,_0x46f1c2=this;_0x46f1c2['currentUser']=_0xc27132[_0x5a9ad9('0x20b2')](),_0x46f1c2['errors']=[],_0x46f1c2[_0x5a9ad9('0xf28')]=_0x5a9ad9('0x505')+(_0x159f3b[_0x5a9ad9('0x11f3')]||_0x159f3b[_0x5a9ad9('0x1d75')])[_0x5a9ad9('0x80')](),_0x46f1c2[_0x5a9ad9('0x24f2')]=angular[_0x5a9ad9('0x1a86')](_0x159f3b),_0x46f1c2['crudPermissions']=_0x1073b6,_0x46f1c2[_0x5a9ad9('0x258d')]={};if(_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x1407')])switch(_0x46f1c2['system'][_0x5a9ad9('0x11f3')]?_0x46f1c2[_0x5a9ad9('0x24f2')]['appType'][_0x5a9ad9('0x93a')]():_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x1d75')][_0x5a9ad9('0x93a')]()){case _0x5a9ad9('0xbf0'):break;case _0x5a9ad9('0x205c'):{const _0x5c6418=_0x46f1c2[_0x5a9ad9('0x24f2')]['appdata'][_0x5a9ad9('0x1fc5')](',');_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x1d46')]=_0x5c6418[0x0],_0x46f1c2[_0x5a9ad9('0x24f2')]['language']=_0x5c6418[0x1],_0x46f1c2['system'][_0x5a9ad9('0x6d9')]=_0x5c6418[_0x5a9ad9('0x12c8')](0x2,_0x5c6418[_0x5a9ad9('0x1564')])[_0x5a9ad9('0x1630')](',');}break;case _0x5a9ad9('0xd24'):{const _0x925ab1=_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x1407')]['split'](',');_0x46f1c2[_0x5a9ad9('0x24f2')]['projectId']=_0x925ab1[0x0],_0x46f1c2[_0x5a9ad9('0x24f2')]['clientEmail']=_0x925ab1[0x1],_0x46f1c2[_0x5a9ad9('0x24f2')]['privateKey']=_0x925ab1[0x2],_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x1a1c')]=_0x925ab1[0x3],_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x6d9')]=_0x925ab1[_0x5a9ad9('0x12c8')](0x4,_0x925ab1[_0x5a9ad9('0x1564')])[_0x5a9ad9('0x1630')](',');}break;case _0x5a9ad9('0x1db1'):{const _0x38198b=_0x46f1c2[_0x5a9ad9('0x24f2')]['appdata'][_0x5a9ad9('0x1fc5')](',');_0x46f1c2['system'][_0x5a9ad9('0x7ae')]=_0x38198b[0x0],_0x46f1c2[_0x5a9ad9('0x24f2')]['secretaccesskey']=_0x38198b[0x1],_0x46f1c2[_0x5a9ad9('0x24f2')]['lexregion']=_0x38198b[0x2],_0x46f1c2['system'][_0x5a9ad9('0x11a9')]=_0x38198b[0x3],_0x46f1c2[_0x5a9ad9('0x24f2')]['welcomemessage']=_0x38198b[_0x5a9ad9('0x12c8')](0x4,_0x38198b[_0x5a9ad9('0x1564')])['join'](',');}break;case _0x5a9ad9('0x2408'):{const _0x270648=_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x1407')][_0x5a9ad9('0x1fc5')](',');_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x35')]=isNaN(_0x270648[0x0])?_0x270648[0x0]:parseInt(_0x270648[0x0],0xa),_0x46f1c2[_0x5a9ad9('0x24f2')]['text']=_0x270648[_0x5a9ad9('0x12c8')](0x1,_0x270648[_0x5a9ad9('0x1564')])['join'](',');}break;case _0x5a9ad9('0x8c2'):_0x46f1c2['system'][_0x5a9ad9('0x1bcd')]=_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x1407')];break;case _0x5a9ad9('0x877'):_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x60a')]=_0x46f1c2['system'][_0x5a9ad9('0x1407')][_0x5a9ad9('0x1fc5')]('=')[0x0],_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x1c6b')]=_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x1407')]['split']('=')[0x1];break;case _0x5a9ad9('0x19ae'):_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x273a')]=_0x46f1c2['system'][_0x5a9ad9('0x1407')];break;default:{const _0x167985=_0x46f1c2[_0x5a9ad9('0x24f2')]['appdata'][_0x5a9ad9('0x1fc5')](',');_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x6db')]=_0x2e3ca0()[_0x5a9ad9('0x173f')](_0x167985[0x0])?_0x167985[0x0]:isNaN(_0x167985[0x0])?_0x167985[0x0]:parseInt(_0x167985[0x0],0xa),_0x46f1c2[_0x5a9ad9('0x24f2')]['variable']=_0x2e3ca0()['isEmpty'](_0x167985[0x1])?_0x167985[0x1]:isNaN(_0x167985[0x1])?_0x167985[0x1]:parseInt(_0x167985[0x1],0xa);}break;}else _0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x26e0')]='';_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0xcf0')]&&_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0xcf0')][_0x5a9ad9('0x93a')]()===_0x5a9ad9('0x17cd')&&_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x11f3')]['toLowerCase']()==='outbounddial'&&(_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x24fa')]=_0x46f1c2[_0x5a9ad9('0x24f2')]['phone']?_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0xd31')][_0x5a9ad9('0x1fc5')]('$')[0x0]:undefined,_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0xabd')]=_0x46f1c2[_0x5a9ad9('0x24f2')][_0x5a9ad9('0x73c')]?_0x5a9ad9('0xac1')+_0x46f1c2[_0x5a9ad9('0x24f2')]['callerID']:undefined);_0x46f1c2[_0x5a9ad9('0x2671')]=_0x23d58a,_0x46f1c2['closeDialog']=_0x4480e2,_0xc27132[_0x5a9ad9('0xca1')](_0x5a9ad9('0x20c2'))?_0x26f9a4[_0x5a9ad9('0x26e0')][_0x5a9ad9('0x1e6e')]({'fields':'id,name','sort':_0x5a9ad9('0x60a'),'nolimit':'true'})[_0x5a9ad9('0xe53')][_0x5a9ad9('0x683')](function(_0x5c776c){const _0xee3b17=_0x5a9ad9;_0x46f1c2[_0xee3b17('0x220b')]=_0x5c776c[_0xee3b17('0xf5d')]||[];})[_0x5a9ad9('0x130a')](function(_0x3fa973){const _0x21875c=_0x5a9ad9;_0x4a4aca[_0x21875c('0x52a')]({'title':_0x3fa973['status']?_0x21875c('0x2168')+_0x3fa973['status']+_0x21875c('0xbf6')+_0x3fa973[_0x21875c('0x24a9')]:_0x21875c('0x9a9'),'msg':_0x3fa973['data']?JSON['stringify'](_0x3fa973['data']):_0x3fa973['toString']()});}):_0x26f9a4[_0x5a9ad9('0x26e0')]['get']({'fields':_0x5a9ad9('0xa10'),'sort':_0x5a9ad9('0x60a'),'nolimit':_0x5a9ad9('0x26ac')})[_0x5a9ad9('0xe53')][_0x5a9ad9('0x683')](function(_0x226497){const _0x15a855=_0x5a9ad9;_0x46f1c2[_0x15a855('0x220b')]=_0x226497[_0x15a855('0xf5d')]||[];})[_0x5a9ad9('0x683')](function(){const _0x3e7a49=_0x5a9ad9;return _0x26f9a4[_0x3e7a49('0x22df')][_0x3e7a49('0x1e6e')]({'userProfileId':_0x46f1c2[_0x3e7a49('0x11ed')][_0x3e7a49('0x2f')],'sectionId':0x3f4})[_0x3e7a49('0xe53')];})[_0x5a9ad9('0x683')](function(_0x16ab10){const _0x59d716=_0x5a9ad9,_0x4b3b59=_0x16ab10&&_0x16ab10['rows']?_0x16ab10[_0x59d716('0xf5d')][0x0]:null;if(!_0x4b3b59){const _0x31beed=[];let _0x4ff7b6=null;_0x46f1c2['system']&&(_0x4ff7b6=_0x2e3ca0()[_0x59d716('0x1c07')](_0x46f1c2['variables'],{'name':_0x46f1c2[_0x59d716('0x24f2')][_0x59d716('0x26e0')]}));for(let _0x408736=0x0;_0x408736<_0x46f1c2[_0x59d716('0x220b')][_0x59d716('0x1564')];_0x408736++){_0x4ff7b6&&_0x46f1c2['variables'][_0x408736]['id']===_0x4ff7b6['id']&&(_0x46f1c2[_0x59d716('0x220b')][_0x408736][_0x59d716('0x319')]=![],_0x31beed[_0x59d716('0x1fd0')](_0x46f1c2[_0x59d716('0x220b')][_0x408736]));}_0x46f1c2[_0x59d716('0x220b')]=_0x31beed;}else{if(!_0x4b3b59[_0x59d716('0x170')])return _0x26f9a4['userProfileResource'][_0x59d716('0x1e6e')]({'sectionId':_0x4b3b59['id']})['$promise'][_0x59d716('0x683')](function(_0x483d06){const _0x3033ec=_0x59d716,_0x9f8a25=_0x2e3ca0()['map'](_0x483d06[_0x3033ec('0xf5d')],function(_0xd39695){const _0x3197a0=_0x3033ec;return _0x2e3ca0()['find'](_0x46f1c2[_0x3197a0('0x220b')],{'id':_0xd39695['resourceId']});});let _0x46797d=null;_0x46f1c2[_0x3033ec('0x24f2')]&&(_0x46797d=_0x2e3ca0()['find'](_0x46f1c2[_0x3033ec('0x220b')],{'name':_0x46f1c2[_0x3033ec('0x24f2')][_0x3033ec('0x26e0')]}));if(_0x46797d&&!_0x2e3ca0()[_0x3033ec('0x7a2')](_0x9f8a25,['id',_0x46797d['id']])){const _0x136d22=_0x2e3ca0()['find'](_0x46f1c2[_0x3033ec('0x220b')],{'id':_0x46797d['id']});_0x136d22[_0x3033ec('0x319')]=![],_0x9f8a25[_0x3033ec('0x1fd0')](_0x136d22);}_0x46f1c2[_0x3033ec('0x220b')]=_0x9f8a25;});}})['catch'](function(_0x557d54){const _0xc63d9=_0x5a9ad9;_0x4a4aca[_0xc63d9('0x52a')]({'title':_0x557d54['status']?_0xc63d9('0x2168')+_0x557d54['status']+'\x20-\x20'+_0x557d54[_0xc63d9('0x24a9')]:_0xc63d9('0x392'),'msg':_0x557d54[_0xc63d9('0x5a5')]?JSON[_0xc63d9('0x258a')](_0x557d54[_0xc63d9('0x5a5')]):_0x557d54[_0xc63d9('0x1ff0')]()});});function _0x23d58a(){const _0x12485a=_0x5a9ad9;_0x46f1c2[_0x12485a('0x17f')]=[];const _0x219b95=[];_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0xcf0')]&&_0x46f1c2[_0x12485a('0x24f2')]['type'][_0x12485a('0x93a')]()==='outbound'&&_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x11f3')]===_0x12485a('0x4d2')&&(_0x46f1c2['system'][_0x12485a('0xd31')]=_0x53ae68[_0x12485a('0x145a')]?(_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x24fa')]||'')+_0x12485a('0x249e')+_0x53ae68['cutdigits']+'}':(_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x24fa')]||'')+_0x12485a('0x20cb'),_0x53ae68[_0x12485a('0x75b')]!==_0x12485a('0x925')?_0x46f1c2[_0x12485a('0x24f2')]['options']['indexOf'](_0x12485a('0x1b1'))<0x0&&(_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x158e')]+=_0x12485a('0x1b1')):_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x158e')]=_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x158e')]['replace'](_0x12485a('0x1b1'),''));if(_0x46f1c2['system']['appType']&&_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x11f3')]==='custom'){}else switch((_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x1d75')]||_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x11f3')])[_0x12485a('0x93a')]()){case _0x12485a('0x877'):_0x46f1c2[_0x12485a('0x24f2')]['appdata']=_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x60a')]+'='+_0x46f1c2[_0x12485a('0x24f2')][_0x12485a('0x1c6b')];break;case _0x12485a('0xbf0'):break;default:_0x219b95[0x0]=_0x46f1c2['system'][_0x12485a('0x6db')],_0x219b95[0x1]=_0x46f1c2['system'][_0x12485a('0x26e0')],_0x46f1c2['system']['appdata']=_0x219b95[_0x12485a('0x1630')](',');}_0x4480e2(_0x46f1c2[_0x12485a('0x24f2')]);}function _0x4480e2(_0x31bfdd){_0x4f9952['hide'](_0x31bfdd);}}const _0x805271=_0x5ad566;_0x23d1c1['$inject']=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0xbc7'),_0x189033('0x1963'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x23d1c1(_0x55be00,_0xe3ca67,_0x1ed642,_0x54b0f1,_0x1f4c8d,_0x568291,_0x3c8e8d,_0x155d45){const _0x11fa9d=_0x189033,_0xbf385b=this;_0xbf385b[_0x11fa9d('0x11ed')]=_0x3c8e8d[_0x11fa9d('0x20b2')](),_0xbf385b[_0x11fa9d('0x17f')]=[],_0xbf385b[_0x11fa9d('0xf28')]=_0x11fa9d('0x505')+(_0x54b0f1['appType']||_0x54b0f1[_0x11fa9d('0x1d75')])['toUpperCase'](),_0xbf385b[_0x11fa9d('0x270')]=angular[_0x11fa9d('0x1a86')](_0x54b0f1),_0xbf385b[_0x11fa9d('0x1134')]=_0x155d45,_0xbf385b['hasModulePermissions']={};if(_0xbf385b['tag'][_0x11fa9d('0x1407')])switch(_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x11f3')]?_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x11f3')]['toLowerCase']():_0xbf385b[_0x11fa9d('0x270')]['app'][_0x11fa9d('0x93a')]()){case _0x11fa9d('0xbf0'):break;case _0x11fa9d('0x205c'):{const _0xf107c0=_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x1407')][_0x11fa9d('0x1fc5')](',');_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x1d46')]=_0xf107c0[0x0],_0xbf385b['tag'][_0x11fa9d('0x1a1c')]=_0xf107c0[0x1],_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x6d9')]=_0xf107c0[_0x11fa9d('0x12c8')](0x2,_0xf107c0['length'])[_0x11fa9d('0x1630')](',');}break;case'dialogflowv2':{const _0xfc403c=_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x1407')]['split'](',');_0xbf385b[_0x11fa9d('0x270')]['projectId']=_0xfc403c[0x0],_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x38')]=_0xfc403c[0x1],_0xbf385b['tag'][_0x11fa9d('0x406')]=_0xfc403c[0x2],_0xbf385b['tag'][_0x11fa9d('0x1a1c')]=_0xfc403c[0x3],_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x6d9')]=_0xfc403c[_0x11fa9d('0x12c8')](0x4,_0xfc403c[_0x11fa9d('0x1564')])[_0x11fa9d('0x1630')](',');}break;case _0x11fa9d('0x1db1'):{const _0x242393=_0xbf385b[_0x11fa9d('0x270')]['appdata']['split'](',');_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x7ae')]=_0x242393[0x0],_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x204a')]=_0x242393[0x1],_0xbf385b['tag']['lexregion']=_0x242393[0x2],_0xbf385b[_0x11fa9d('0x270')]['botname']=_0x242393[0x3],_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x6d9')]=_0x242393[_0x11fa9d('0x12c8')](0x4,_0x242393['length'])[_0x11fa9d('0x1630')](',');}break;case _0x11fa9d('0x2408'):{const _0x23bbb7=_0xbf385b['tag']['appdata'][_0x11fa9d('0x1fc5')](',');_0xbf385b['tag'][_0x11fa9d('0x35')]=isNaN(_0x23bbb7[0x0])?_0x23bbb7[0x0]:parseInt(_0x23bbb7[0x0],0xa),_0xbf385b['tag'][_0x11fa9d('0x1bcd')]=_0x23bbb7[_0x11fa9d('0x12c8')](0x1,_0x23bbb7[_0x11fa9d('0x1564')])[_0x11fa9d('0x1630')](',');}break;case _0x11fa9d('0x8c2'):_0xbf385b['tag'][_0x11fa9d('0x1bcd')]=_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x1407')];break;case _0x11fa9d('0x877'):_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x60a')]=_0xbf385b['tag']['appdata'][_0x11fa9d('0x1fc5')]('=')[0x0],_0xbf385b['tag'][_0x11fa9d('0x1c6b')]=_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x1407')]['split']('=')[0x1];break;case'agi':_0xbf385b[_0x11fa9d('0x270')]['project']=_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x1407')];break;default:{const _0x3fef8f=_0xbf385b['tag'][_0x11fa9d('0x1407')][_0x11fa9d('0x1fc5')](',');_0xbf385b['tag'][_0x11fa9d('0x270')]=_0x2e3ca0()['isEmpty'](_0x3fef8f[0x0])?_0x3fef8f[0x0]:isNaN(_0x3fef8f[0x0])?_0x3fef8f[0x0]:parseInt(_0x3fef8f[0x0],0xa);}break;}else{}_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0xcf0')]&&_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0xcf0')][_0x11fa9d('0x93a')]()==='outbound'&&_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x11f3')][_0x11fa9d('0x93a')]()==='outbounddial'&&(_0xbf385b['tag'][_0x11fa9d('0x24fa')]=_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0xd31')]?_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0xd31')][_0x11fa9d('0x1fc5')]('$')[0x0]:undefined,_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0xabd')]=_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x73c')]?_0x11fa9d('0xac1')+_0xbf385b[_0x11fa9d('0x270')][_0x11fa9d('0x73c')]:undefined);_0xbf385b[_0x11fa9d('0x2671')]=_0x295f80,_0xbf385b[_0x11fa9d('0xf82')]=_0x48a86c,_0x3c8e8d[_0x11fa9d('0xca1')](_0x11fa9d('0x20c2'))?_0x568291[_0x11fa9d('0x270')][_0x11fa9d('0x1e6e')]({'fields':'id,name','sort':'name','nolimit':_0x11fa9d('0x26ac')})[_0x11fa9d('0xe53')][_0x11fa9d('0x683')](function(_0x5e7e7c){const _0x49cd2a=_0x11fa9d;_0xbf385b[_0x49cd2a('0x1ce6')]=_0x5e7e7c['rows']||[];})[_0x11fa9d('0x130a')](function(_0x17a52a){const _0x5e92c5=_0x11fa9d;_0x1ed642[_0x5e92c5('0x52a')]({'title':_0x17a52a[_0x5e92c5('0x13ee')]?_0x5e92c5('0x2168')+_0x17a52a[_0x5e92c5('0x13ee')]+'\x20-\x20'+_0x17a52a[_0x5e92c5('0x24a9')]:_0x5e92c5('0x14ef'),'msg':_0x17a52a['data']?JSON[_0x5e92c5('0x258a')](_0x17a52a[_0x5e92c5('0x5a5')]):_0x17a52a[_0x5e92c5('0x1ff0')]()});}):_0x568291['tag']['get']({'fields':_0x11fa9d('0xa10'),'sort':'name','nolimit':_0x11fa9d('0x26ac')})['$promise'][_0x11fa9d('0x683')](function(_0x6fc32e){const _0x3a5040=_0x11fa9d;_0xbf385b['tags']=_0x6fc32e[_0x3a5040('0xf5d')]||[];})[_0x11fa9d('0x683')](function(){const _0x11b245=_0x11fa9d;return _0x568291[_0x11b245('0x22df')][_0x11b245('0x1e6e')]({'userProfileId':_0xbf385b['currentUser'][_0x11b245('0x2f')],'sectionId':0x3f0})[_0x11b245('0xe53')];})[_0x11fa9d('0x683')](function(_0x9813d8){const _0x2b1300=_0x11fa9d,_0x3bb4ac=_0x9813d8&&_0x9813d8[_0x2b1300('0xf5d')]?_0x9813d8['rows'][0x0]:null;if(!_0x3bb4ac){const _0x3c3f0a=[];let _0x3f59c9=null;_0xbf385b['tag']&&(_0x3f59c9=_0x2e3ca0()[_0x2b1300('0x1c07')](_0xbf385b[_0x2b1300('0x1ce6')],{'name':_0xbf385b[_0x2b1300('0x270')][_0x2b1300('0x270')]}));for(let _0x4c643c=0x0;_0x4c643c<_0xbf385b[_0x2b1300('0x1ce6')][_0x2b1300('0x1564')];_0x4c643c++){_0x3f59c9&&_0xbf385b[_0x2b1300('0x1ce6')][_0x4c643c]['id']===_0x3f59c9['id']&&(_0xbf385b[_0x2b1300('0x1ce6')][_0x4c643c][_0x2b1300('0x319')]=![],_0x3c3f0a[_0x2b1300('0x1fd0')](_0xbf385b['tags'][_0x4c643c]));}_0xbf385b[_0x2b1300('0x1ce6')]=_0x3c3f0a;}else{if(!_0x3bb4ac[_0x2b1300('0x170')])return _0x568291[_0x2b1300('0xcf7')]['get']({'sectionId':_0x3bb4ac['id']})[_0x2b1300('0xe53')][_0x2b1300('0x683')](function(_0x2e1dd6){const _0x417370=_0x2b1300,_0x393d8d=_0x2e3ca0()['map'](_0x2e1dd6[_0x417370('0xf5d')],function(_0x465c74){const _0x5e1ce9=_0x417370;return _0x2e3ca0()[_0x5e1ce9('0x1c07')](_0xbf385b[_0x5e1ce9('0x1ce6')],{'id':_0x465c74['resourceId']});});let _0x166f5c=null;_0xbf385b[_0x417370('0x270')]&&(_0x166f5c=_0x2e3ca0()['find'](_0xbf385b['tags'],{'name':_0xbf385b[_0x417370('0x270')][_0x417370('0x270')]}));if(_0x166f5c&&!_0x2e3ca0()[_0x417370('0x7a2')](_0x393d8d,['id',_0x166f5c['id']])){const _0x50b695=_0x2e3ca0()[_0x417370('0x1c07')](_0xbf385b['tags'],{'id':_0x166f5c['id']});_0x50b695[_0x417370('0x319')]=![],_0x393d8d[_0x417370('0x1fd0')](_0x50b695);}_0xbf385b[_0x417370('0x1ce6')]=_0x393d8d;});}})[_0x11fa9d('0x130a')](function(_0x46319b){const _0x16c07a=_0x11fa9d;_0x1ed642[_0x16c07a('0x52a')]({'title':_0x46319b['status']?_0x16c07a('0x2168')+_0x46319b[_0x16c07a('0x13ee')]+_0x16c07a('0xbf6')+_0x46319b[_0x16c07a('0x24a9')]:_0x16c07a('0x1118'),'msg':_0x46319b[_0x16c07a('0x5a5')]?JSON[_0x16c07a('0x258a')](_0x46319b[_0x16c07a('0x5a5')]):_0x46319b['toString']()});});function _0x295f80(){const _0xf1cc13=_0x11fa9d;_0xbf385b[_0xf1cc13('0x17f')]=[];const _0x253eba=[];_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0xcf0')]&&_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0xcf0')][_0xf1cc13('0x93a')]()===_0xf1cc13('0x17cd')&&_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0x11f3')]===_0xf1cc13('0x4d2')&&(_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0xd31')]=_0x1f4c8d[_0xf1cc13('0x145a')]?(_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0x24fa')]||'')+_0xf1cc13('0x249e')+_0x1f4c8d[_0xf1cc13('0x145a')]+'}':(_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0x24fa')]||'')+_0xf1cc13('0x20cb'),_0x1f4c8d['recordingFormat']!==_0xf1cc13('0x925')?_0xbf385b[_0xf1cc13('0x270')]['options'][_0xf1cc13('0x824')](_0xf1cc13('0x1b1'))<0x0&&(_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0x158e')]+='U(xcally-mixmonitor-context)'):_0xbf385b[_0xf1cc13('0x270')]['options']=_0xbf385b[_0xf1cc13('0x270')]['options']['replace'](_0xf1cc13('0x1b1'),''));const _0x4ea7b2=_0x2e3ca0()['find'](_0xbf385b['tags'],{'name':_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0x270')]});_0x4ea7b2&&(_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0xb6d')]=_0x4ea7b2['id']);if(_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0x11f3')]&&_0xbf385b['tag'][_0xf1cc13('0x11f3')]===_0xf1cc13('0xbf0')){}else switch((_0xbf385b[_0xf1cc13('0x270')]['app']||_0xbf385b['tag'][_0xf1cc13('0x11f3')])[_0xf1cc13('0x93a')]()){case _0xf1cc13('0x877'):_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0x1407')]=_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0x60a')]+'='+_0xbf385b['tag']['value'];break;case _0xf1cc13('0xbf0'):break;default:_0x253eba[0x0]=_0xbf385b['tag']['tag'],_0xbf385b[_0xf1cc13('0x270')][_0xf1cc13('0x1407')]=_0x253eba[_0xf1cc13('0x1630')](',');}_0x48a86c(_0xbf385b[_0xf1cc13('0x270')]);}function _0x48a86c(_0x18e7a0){const _0x4b5a92=_0x11fa9d;_0x55be00[_0x4b5a92('0x1715')](_0x18e7a0);}}const _0x206b61=_0x23d1c1;_0x1d7b41[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),'$state','$q',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),'Auth'];function _0x1d7b41(_0x129e5a,_0xa9c901,_0x1db2a4,_0x54b92d,_0xe08118,_0x9c52b3,_0x2b08db,_0x4ca034,_0x7e6674,_0x2f4fde,_0x465ff6){const _0x5ee5e0=_0x189033,_0x3255af=this;_0x3255af[_0x5ee5e0('0x11ed')]=_0x465ff6['getCurrentUser'](),_0x3255af[_0x5ee5e0('0x1963')]={},_0x3255af[_0x5ee5e0('0x1f63')]={'count':0x0,'rows':[]},_0x3255af[_0x5ee5e0('0x1988')]=[],_0x3255af[_0x5ee5e0('0x1134')],_0x3255af[_0x5ee5e0('0x23a2')]={'read':_0x5ee5e0('0x13c'),'closed':_0x5ee5e0('0x13c'),'sort':_0x5ee5e0('0xddd'),'includeAll':'true','limit':0xa,'page':0x1},_0x3255af['init']=_0x5a2265,_0x3255af[_0x5ee5e0('0x26eb')]=_0x4724cb,_0x3255af['openchannelInteractionDownload']=_0x8c8cf4,_0x3255af['success']=_0x2657e0,_0x3255af['getOpenchannelAccountInteractions']=_0xe5f624,_0x3255af[_0x5ee5e0('0x1aeb')]=_0x24488a,_0x3255af[_0x5ee5e0('0x2121')]=_0x5068eb,_0x3255af[_0x5ee5e0('0x45a')]=_0x4d54be,_0x3255af[_0x5ee5e0('0x1646')]=_0x4e8b77,_0x3255af[_0x5ee5e0('0x9e0')]=_0x34813f;function _0x5a2265(_0x58563f,_0x416318){const _0x5c1ae5=_0x5ee5e0;_0x3255af[_0x5c1ae5('0x1963')]=_0x58563f,_0x3255af['crudPermissions']=typeof _0x416318!=='undefined'?_0x416318:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3255af[_0x5c1ae5('0x23a2')][_0x5c1ae5('0x1061')]=_0x3255af[_0x5c1ae5('0x1963')]['id'],_0x3255af[_0x5c1ae5('0x19c9')]={'fields':_0x56b254()},_0x2931fc();}function _0x2931fc(){const _0x9b6d85=_0x5ee5e0;return _0x2f4fde[_0x9b6d85('0x270')][_0x9b6d85('0x1e6e')]()[_0x9b6d85('0xe53')][_0x9b6d85('0x683')](function(_0x445664){const _0x590a6f=_0x9b6d85;_0x3255af[_0x590a6f('0x1ce6')]=_0x445664||{'count':0x0,'rows':[]};})[_0x9b6d85('0x683')](function(){_0x3255af['quickFilters']=_0x288d60();});}function _0x288d60(){const _0x283a20=_0x5ee5e0;return[{'name':_0x283a20('0x10c1'),'key':'createdAt','type':'date','label':_0x283a20('0x1006')},{'name':_0x283a20('0xc51'),'key':_0x283a20('0x20db'),'type':'select','label':_0x283a20('0x1866'),'customOptions':[{'value':0x0,'translate':_0x283a20('0x2226')},{'value':0x1,'translate':'DASHBOARDS.READ'},{'value':null,'translate':_0x283a20('0x475')}]},{'name':'Status','key':_0x283a20('0xd8a'),'type':_0x283a20('0xb31'),'label':'DASHBOARDS.SELECT_STATUS','customOptions':[{'value':0x0,'translate':_0x283a20('0x10b1')},{'value':0x1,'translate':'DASHBOARDS.CLOSED'},{'value':null,'translate':_0x283a20('0x475')}]},{'name':_0x283a20('0x62c'),'key':_0x283a20('0x10c5'),'type':'select','label':_0x283a20('0x21fb'),'customOptions':[{'value':'null','translate':_0x283a20('0x2608')},{'value':undefined,'translate':_0x283a20('0x475')}]},{'name':'Tag','key':'tag','type':'multiselect','label':_0x283a20('0x2264'),'options':_0x3255af[_0x283a20('0x1ce6')][_0x283a20('0xf5d')],'placeholder':_0x283a20('0x7cb')}];}function _0x56b254(){const _0x49b1db=_0x5ee5e0;return[{'name':'Id','column':'id','type':_0x49b1db('0x121f')},{'name':_0x49b1db('0x1309'),'column':_0x49b1db('0x1309'),'type':'autocomplete','options':{'searchFields':['firstName',_0x49b1db('0x510'),_0x49b1db('0x1c92')],'route':{'model':'cmContact','action':_0x49b1db('0x1e6e'),'params':{'fields':_0x49b1db('0x8ff'),'Contact':_0x49b1db('0xfd'),'nolimit':!![]}},'extraOperators':['$substring'],'excludedOperators':['$ne']}},{'name':_0x49b1db('0x25a9'),'column':_0x49b1db('0x1e66'),'type':_0x49b1db('0x1bcd'),'options':{'excludedOperators':[_0x49b1db('0x393'),_0x49b1db('0x17ee')]}},{'name':_0x49b1db('0x1765'),'column':_0x49b1db('0x183b'),'type':_0x49b1db('0x1bcd'),'options':{'excludedOperators':[_0x49b1db('0x393'),_0x49b1db('0x17ee')]}},{'name':_0x49b1db('0x1d9d'),'column':'closed','type':_0x49b1db('0xb31'),'values':[{'id':0x0,'translate':_0x49b1db('0x10b1')},{'id':0x1,'translate':_0x49b1db('0x270a')}],'options':{'excludedOperators':['$ne']}},{'name':'Agent','column':_0x49b1db('0x1dad'),'type':_0x49b1db('0xeb'),'options':{'table':'i','route':{'model':_0x49b1db('0xc96'),'action':_0x49b1db('0x1e6e'),'params':{'role':_0x49b1db('0x2327'),'fields':_0x49b1db('0x2686'),'nolimit':!![]}},'searchFields':[_0x49b1db('0x11bc'),_0x49b1db('0x60a')],'extraOperators':[_0x49b1db('0xe55')],'excludedOperators':[_0x49b1db('0x17ee')]}},{'name':_0x49b1db('0x198f'),'column':'Tag','type':_0x49b1db('0xf6c'),'options':{'route':{'model':_0x49b1db('0x270'),'action':_0x49b1db('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x49b1db('0x1479')]}},{'name':_0x49b1db('0x10c1'),'column':_0x49b1db('0x1a4'),'type':_0x49b1db('0x270e'),'options':{'excludedOperators':['$ne']}},{'name':'Read','column':_0x49b1db('0x122e'),'type':'select','values':[{'id':0x1,'translate':'DASHBOARDS.READ'},{'id':0x0,'translate':_0x49b1db('0x2226')}],'options':{'excludedOperators':[_0x49b1db('0x17ee')]}}];}function _0x5068eb(){const _0x15bbce=_0x5ee5e0;_0x2b08db[_0x15bbce('0x1d4')]({'controller':'AdvancedSearchController','controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular['element'](_0x4ca034['body']),'clickOutsideToClose':![],'locals':{'fields':_0x3255af[_0x15bbce('0x19c9')][_0x15bbce('0x189a')],'color':undefined,'storagePath':_0x15bbce('0x121c')},'fullscreen':!![]})[_0x15bbce('0x683')](function(_0x380c7d){const _0x19b957=_0x15bbce;_0x3255af['query'][_0x19b957('0x19a4')]=_0x380c7d===![]?undefined:_0x380c7d;if(_0x3255af[_0x19b957('0x23a2')][_0x19b957('0x19a4')])_0xe5f624();else _0x380c7d===![]&&_0xe5f624();})[_0x15bbce('0x130a')](function(_0x3dca08){const _0x4615fd=_0x15bbce;_0x7e6674[_0x4615fd('0x52a')]({'title':_0x4615fd('0x1119'),'msg':_0x3dca08[_0x4615fd('0x5a5')]?JSON[_0x4615fd('0x258a')](_0x3dca08[_0x4615fd('0x5a5')][_0x4615fd('0x8c2')]):_0x3dca08[_0x4615fd('0x1ff0')]()});});}function _0x8c8cf4(_0xbfa05b,_0x3b6ed2,_0x398fdc){const _0x30f542=_0x5ee5e0;return _0x2f4fde[_0x30f542('0x17ff')][_0x30f542('0x18e8')]({'id':_0xbfa05b['id'],'exists':!![],'attachments':_0x398fdc})['$promise']['then'](function(_0x3f3450){const _0x4c953a=_0x30f542,_0x546fad=[_0x3f3450[_0x4c953a('0x1fb3')]];let _0x3c8a83='interaction'+_0xbfa05b['id'];const _0x26d81a=new Blob(_0x546fad,{'type':_0x3f3450[_0x4c953a('0xcf0')]});_0x3c8a83=_0x4c953a('0xcf5')+_0xbfa05b['id']+_0x4c953a('0x18ff');const _0x18979a=window[_0x4c953a('0x12e1')][_0x4c953a('0x1ffa')]('a');_0x18979a[_0x4c953a('0x130f')](_0x4c953a('0x2767'),URL[_0x4c953a('0x2820')](_0x26d81a)),_0x18979a['setAttribute']('download',_0x3c8a83),document[_0x4c953a('0x18e5')][_0x4c953a('0x1e43')](_0x18979a),_0x18979a['click']();})['catch'](function(_0x45db27){const _0x505c6d=_0x30f542;if(_0x45db27[_0x505c6d('0x5a5')]&&_0x45db27['data'][_0x505c6d('0x17f')]&&_0x45db27['data'][_0x505c6d('0x17f')]['length'])for(let _0x12f6e4=0x0;_0x12f6e4<_0x45db27[_0x505c6d('0x5a5')][_0x505c6d('0x17f')][_0x505c6d('0x1564')];_0x12f6e4+=0x1){_0x7e6674['error']({'title':_0x45db27[_0x505c6d('0x5a5')][_0x505c6d('0x17f')][_0x12f6e4]['type'],'msg':_0x45db27[_0x505c6d('0x5a5')][_0x505c6d('0x17f')][_0x12f6e4][_0x505c6d('0x8c2')]});}else _0x7e6674[_0x505c6d('0x52a')]({'title':_0x45db27[_0x505c6d('0x13ee')]?'API:'+_0x45db27[_0x505c6d('0x13ee')]+_0x505c6d('0xbf6')+_0x45db27[_0x505c6d('0x24a9')]:_0x505c6d('0x1c5d'),'msg':_0x45db27[_0x505c6d('0x5a5')]?JSON[_0x505c6d('0x258a')](_0x45db27['data'][_0x505c6d('0x8c2')]):_0x45db27['toString']()});});}function _0x4724cb(_0x30918d,_0x4842d2){const _0x48167d=_0x5ee5e0,_0x14d69e=_0x2b08db[_0x48167d('0x1c6f')]()[_0x48167d('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20interaction?')[_0x48167d('0x26e3')](''+(_0x30918d[_0x48167d('0x60a')]||_0x30918d['id']&&_0x2e3ca0()[_0x48167d('0x2711')]('interaction\x20#')+_0x30918d['id']||_0x48167d('0xa98'))+_0x48167d('0x20f1')+_0x48167d('0x1ee7'))['ariaLabel'](_0x48167d('0x19a8'))[_0x48167d('0xe42')](_0x4842d2)['ok']('OK')[_0x48167d('0x19fb')](_0x48167d('0x16b8'));_0x2b08db[_0x48167d('0x1d4')](_0x14d69e)[_0x48167d('0x683')](function(){_0x4e8b77(_0x30918d);},function(){const _0x41bba2=_0x48167d;console[_0x41bba2('0x1b2b')]('CANCEL');});}function _0x2657e0(_0x11ba16){const _0x845936=_0x5ee5e0;_0x3255af['openchannelAccountInteractions']=_0x11ba16||{'count':0x0,'rows':[]};for(let _0x44908e=0x0;_0x44908e<_0x3255af['openchannelAccountInteractions'][_0x845936('0xf5d')][_0x845936('0x1564')];_0x44908e+=0x1){const _0x5e2865=_0x3255af[_0x845936('0x1f63')][_0x845936('0xf5d')][_0x44908e];_0x267044(_0x5e2865),_0x5e2865[_0x845936('0x2464')][_0x845936('0x60a')]=_0x4f1537(_0x5e2865);}}function _0xe5f624(){const _0x4efeb5=_0x5ee5e0;_0x3255af[_0x4efeb5('0x23a2')][_0x4efeb5('0x1cc8')]=(_0x3255af[_0x4efeb5('0x23a2')][_0x4efeb5('0xdf8')]-0x1)*_0x3255af[_0x4efeb5('0x23a2')]['limit'],_0x3255af[_0x4efeb5('0x1883')]=_0x2f4fde['openchannelInteraction'][_0x4efeb5('0x1e6e')](_0x3255af[_0x4efeb5('0x23a2')],_0x2657e0)['$promise'];}function _0x24488a(_0x4c6d8f,_0x5c1332){const _0x28a4b0=_0x5ee5e0;_0x2b08db[_0x28a4b0('0x1d4')]({'controller':'AgentGeneralInteractionController','controllerAs':'vm','templateUrl':_0x37aa85,'parent':angular[_0x28a4b0('0x1fcc')](_0x4ca034[_0x28a4b0('0x18e5')]),'targetEvent':_0x4c6d8f,'clickOutsideToClose':!![],'onShowing':function(_0x1e5f45){const _0x32d4d4=_0x28a4b0;_0x1e5f45['vm'][_0x32d4d4('0x12f3')]({'id':0x1,'channel':_0x32d4d4('0x1261'),'interaction':_0x5c1332,'spy':!![]},_0xa9c901[_0x32d4d4('0x1cd5')]['vm']['setting']);}});}function _0x4e8b77(_0x1b79e3){const _0x4c844a=_0x5ee5e0;_0x2f4fde[_0x4c844a('0x17ff')]['delete']({'id':_0x1b79e3['id']})[_0x4c844a('0xe53')][_0x4c844a('0x683')](function(){const _0x44aa79=_0x4c844a;_0x2e3ca0()[_0x44aa79('0x3ec')](_0x3255af[_0x44aa79('0x1f63')][_0x44aa79('0xf5d')],{'id':_0x1b79e3['id']}),_0x3255af[_0x44aa79('0x1f63')]['count']-=0x1,!_0x3255af['openchannelAccountInteractions'][_0x44aa79('0xf5d')]['length']&&_0xe5f624(),_0x7e6674[_0x44aa79('0x53')]({'title':'Interaction\x20deleted!','msg':_0x1b79e3['name']?_0x1b79e3[_0x44aa79('0x60a')]+_0x44aa79('0x194d'):''});})['catch'](function(_0x447480){const _0x18b9b7=_0x4c844a;if(_0x447480[_0x18b9b7('0x5a5')]&&_0x447480['data'][_0x18b9b7('0x17f')]&&_0x447480[_0x18b9b7('0x5a5')][_0x18b9b7('0x17f')][_0x18b9b7('0x1564')]){_0x3255af['errors']=_0x447480['data'][_0x18b9b7('0x17f')]||[{'message':_0x447480[_0x18b9b7('0x1ff0')](),'type':_0x18b9b7('0x9eb')}];for(let _0x20a993=0x0;_0x20a993<_0x447480[_0x18b9b7('0x5a5')][_0x18b9b7('0x17f')][_0x18b9b7('0x1564')];_0x20a993++){_0x7e6674[_0x18b9b7('0x52a')]({'title':_0x447480[_0x18b9b7('0x5a5')]['errors'][_0x20a993][_0x18b9b7('0xcf0')],'msg':_0x447480['data'][_0x18b9b7('0x17f')][_0x20a993]['message']});}}else _0x7e6674[_0x18b9b7('0x52a')]({'title':_0x447480[_0x18b9b7('0x13ee')]?_0x18b9b7('0x2168')+_0x447480['status']+_0x18b9b7('0xbf6')+_0x447480['statusText']:_0x18b9b7('0x9eb'),'msg':_0x447480['data']?JSON[_0x18b9b7('0x258a')](_0x447480[_0x18b9b7('0x5a5')][_0x18b9b7('0x8c2')]):_0x447480[_0x18b9b7('0x8c2')]||_0x447480[_0x18b9b7('0x1ff0')]()});});}function _0x4d54be(){const _0x3199c2=_0x5ee5e0,_0x419ab3=angular[_0x3199c2('0x1a86')](_0x3255af['selectedOpenchannelAccountInteractions']);return _0x3255af['selectedOpenchannelAccountInteractions']=[],_0x419ab3;}function _0x34813f(_0x1367da){const _0x4a6888=_0x5ee5e0,_0x55faa6=_0x2b08db[_0x4a6888('0x1c6f')]()[_0x4a6888('0xf28')](_0x4a6888('0x1cba'))['htmlContent'](_0x4a6888('0xed5')+_0x3255af[_0x4a6888('0x1988')][_0x4a6888('0x1564')]+_0x4a6888('0x93c')+_0x4a6888('0x1ee7'))[_0x4a6888('0x1040')](_0x4a6888('0xe27'))['targetEvent'](_0x1367da)['ok']('OK')[_0x4a6888('0x19fb')](_0x4a6888('0x16b8'));_0x2b08db[_0x4a6888('0x1d4')](_0x55faa6)[_0x4a6888('0x683')](function(){const _0x102548=_0x4a6888;_0x3255af['selectedOpenchannelAccountInteractions']['forEach'](function(_0x34a694){_0x4e8b77(_0x34a694);}),_0x3255af[_0x102548('0x1988')]=[];});}function _0x267044(_0x3625fe){const _0x22ca6b=_0x5ee5e0;if(_0x3625fe[_0x22ca6b('0x705')])_0x3625fe[_0x22ca6b('0x12b3')]=_0x3625fe['from'];else _0x3625fe['Contact']?_0x3625fe[_0x22ca6b('0x12b3')]=(_0x3625fe['Contact'][_0x22ca6b('0xeef')]||'')+'\x20'+(_0x3625fe[_0x22ca6b('0x1309')][_0x22ca6b('0x510')]||''):_0x3625fe[_0x22ca6b('0x12b3')]=_0xe08118['instant'](_0x22ca6b('0xa60'));}function _0x4f1537(_0x289255){const _0x20be07=_0x5ee5e0;if(_0x289255[_0x20be07('0x10c5')])return _0x289255['UserId']===_0x3255af[_0x20be07('0x11ed')]['id']?_0xe08118[_0x20be07('0x2728')](_0x20be07('0x96a')):_0x289255[_0x20be07('0x2464')][_0x20be07('0x11bc')]+'\x20<'+_0x289255['Owner'][_0x20be07('0x1d43')]+'>';return _0xe08118[_0x20be07('0x2728')]('DASHBOARDS.NOT_ASSIGNED');}let _0x352ca4=!![],_0x4eddf3=0x1;_0xa9c901[_0x5ee5e0('0x186d')]('vm_dc.query.filter',function(_0x4fe792,_0x3ee59c){const _0x2b2e27=_0x5ee5e0;_0x352ca4?_0x9c52b3(function(){_0x352ca4=![];}):(!_0x3ee59c&&(_0x4eddf3=_0x3255af['query']['page']),_0x4fe792!==_0x3ee59c&&(_0x3255af[_0x2b2e27('0x23a2')][_0x2b2e27('0xdf8')]=0x1),!_0x4fe792&&(_0x3255af[_0x2b2e27('0x23a2')]['page']=_0x4eddf3),_0xe5f624());});}const _0x4f28ba=_0x1d7b41,_0x174bc5=_0x180212['p']+'src/js/modules/main/apps/openchannel/views/openchannelAccounts/edit/openchannelCannedAnswers/dialog.html/dialog.html';_0xee3b3f[_0x189033('0x14be')]=['$cookies',_0x189033('0x7a5'),_0x189033('0x938'),'$q','$translate','$timeout',_0x189033('0x1e48'),'$document',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0xee3b3f(_0x1fadd2,_0x429a95,_0x44307e,_0x4a09e9,_0x249b9b,_0x350127,_0xd50cb8,_0xce7ba2,_0x436847,_0xf6bdc6,_0x1fa80f){const _0xac8c91=_0x189033,_0xcc0c22=this;_0xcc0c22[_0xac8c91('0x11ed')]=_0x1fa80f[_0xac8c91('0x20b2')](),_0xcc0c22[_0xac8c91('0x1963')]={},_0xcc0c22[_0xac8c91('0x93e')]={'count':0x0,'rows':[]},_0xcc0c22[_0xac8c91('0x2186')]=[],_0xcc0c22['crudPermissions'],_0xcc0c22[_0xac8c91('0x23a2')]={'fields':'createdAt,updatedAt,id,key,value,description','limit':0xa,'page':0x1},_0xcc0c22[_0xac8c91('0x12f3')]=_0x3f5642,_0xcc0c22['deleteConfirm']=_0x40278d,_0xcc0c22[_0xac8c91('0x53')]=_0x42a260,_0xcc0c22[_0xac8c91('0x22fb')]=_0x3d18a9,_0xcc0c22[_0xac8c91('0x1f3')]=_0x2c6c7a,_0xcc0c22[_0xac8c91('0x880')]=_0x4af32b,_0xcc0c22['deleteOpenchannelAccountOpenchannelCannedAnswer']=_0x439e9b,_0xcc0c22[_0xac8c91('0x16ff')]=_0x5ed6a4;function _0x3f5642(_0x59bc60,_0x517e87){const _0x5f0f7d=_0xac8c91;_0xcc0c22[_0x5f0f7d('0x1963')]=_0x59bc60,_0xcc0c22['crudPermissions']=typeof _0x517e87!==_0x5f0f7d('0x1867')?_0x517e87:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0xcc0c22[_0x5f0f7d('0x23a2')][_0x5f0f7d('0x1061')]=_0xcc0c22[_0x5f0f7d('0x1963')]['id'],_0xcc0c22['query']['id']=_0xcc0c22[_0x5f0f7d('0x1963')]['id'],_0x3d18a9();}function _0x40278d(_0x3e65d5,_0x752805){const _0x466669=_0xac8c91,_0x57bb54=_0xd50cb8[_0x466669('0x1c6f')]()[_0x466669('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20openchannelCannedAnswer?')[_0x466669('0x26e3')](_0x466669('0xed5')+(_0x3e65d5['name']||_0x3e65d5['id']&&_0x2e3ca0()[_0x466669('0x2711')]('openchannelCannedAnswer\x20#')+_0x3e65d5['id']||_0x466669('0x26ad'))+_0x466669('0x20f1')+'\x20will\x20be\x20deleted.')[_0x466669('0x1040')](_0x466669('0x2268'))[_0x466669('0xe42')](_0x752805)['ok']('OK')[_0x466669('0x19fb')](_0x466669('0x16b8'));_0xd50cb8[_0x466669('0x1d4')](_0x57bb54)[_0x466669('0x683')](function(){_0x439e9b(_0x3e65d5);},function(){const _0x257326=_0x466669;console[_0x257326('0x1b2b')](_0x257326('0x16b8'));});}function _0x42a260(_0x1a823d){const _0x3b08bf=_0xac8c91;_0xcc0c22[_0x3b08bf('0x93e')]=_0x1a823d||{'count':0x0,'rows':[]};}function _0x3d18a9(){const _0x29cb1d=_0xac8c91;_0xcc0c22[_0x29cb1d('0x23a2')][_0x29cb1d('0x1cc8')]=(_0xcc0c22[_0x29cb1d('0x23a2')][_0x29cb1d('0xdf8')]-0x1)*_0xcc0c22['query'][_0x29cb1d('0x6f0')],_0xcc0c22[_0x29cb1d('0x1883')]=_0xf6bdc6[_0x29cb1d('0x1963')][_0x29cb1d('0x87f')](_0xcc0c22['query'],_0x42a260)['$promise'];}function _0x2c6c7a(_0x1ec26a,_0x153748){const _0x1c6030=_0xac8c91;_0xd50cb8[_0x1c6030('0x1d4')]({'controller':_0x1c6030('0x16f4'),'controllerAs':'vm','templateUrl':_0x174bc5,'parent':angular['element'](_0xce7ba2[_0x1c6030('0x18e5')]),'targetEvent':_0x1ec26a,'clickOutsideToClose':!![],'locals':{'openchannelAccount':_0xcc0c22[_0x1c6030('0x1963')],'openchannelCannedAnswer':_0x153748,'openchannelCannedAnswers':_0xcc0c22[_0x1c6030('0x93e')][_0x1c6030('0xf5d')],'license':null,'setting':null,'crudPermissions':_0xcc0c22[_0x1c6030('0x1134')]}});}function _0x439e9b(_0x202101){const _0x45909b=_0xac8c91;_0xf6bdc6[_0x45909b('0x136c')][_0x45909b('0xd7e')]({'id':_0x202101['id']})[_0x45909b('0xe53')]['then'](function(){const _0x5d9b37=_0x45909b;_0x2e3ca0()[_0x5d9b37('0x3ec')](_0xcc0c22['openchannelAccountOpenchannelCannedAnswers'][_0x5d9b37('0xf5d')],{'id':_0x202101['id']}),_0xcc0c22[_0x5d9b37('0x93e')][_0x5d9b37('0x50d')]-=0x1,!_0xcc0c22[_0x5d9b37('0x93e')][_0x5d9b37('0xf5d')][_0x5d9b37('0x1564')]&&_0x3d18a9(),_0x436847[_0x5d9b37('0x53')]({'title':_0x5d9b37('0x1929'),'msg':_0x202101[_0x5d9b37('0x60a')]?_0x202101['name']+_0x5d9b37('0x194d'):''});})[_0x45909b('0x130a')](function(_0x245340){const _0x1cef80=_0x45909b;if(_0x245340[_0x1cef80('0x5a5')]&&_0x245340[_0x1cef80('0x5a5')][_0x1cef80('0x17f')]&&_0x245340['data'][_0x1cef80('0x17f')][_0x1cef80('0x1564')]){_0xcc0c22[_0x1cef80('0x17f')]=_0x245340[_0x1cef80('0x5a5')][_0x1cef80('0x17f')]||[{'message':_0x245340[_0x1cef80('0x1ff0')](),'type':_0x1cef80('0x9eb')}];for(let _0x24b1cd=0x0;_0x24b1cd<_0x245340[_0x1cef80('0x5a5')][_0x1cef80('0x17f')][_0x1cef80('0x1564')];_0x24b1cd++){_0x436847[_0x1cef80('0x52a')]({'title':_0x245340[_0x1cef80('0x5a5')][_0x1cef80('0x17f')][_0x24b1cd]['type'],'msg':_0x245340['data'][_0x1cef80('0x17f')][_0x24b1cd][_0x1cef80('0x8c2')]});}}else _0x436847[_0x1cef80('0x52a')]({'title':_0x245340[_0x1cef80('0x13ee')]?'API:'+_0x245340[_0x1cef80('0x13ee')]+_0x1cef80('0xbf6')+_0x245340['statusText']:_0x1cef80('0x9eb'),'msg':_0x245340['data']?JSON[_0x1cef80('0x258a')](_0x245340[_0x1cef80('0x5a5')][_0x1cef80('0x8c2')]):_0x245340[_0x1cef80('0x8c2')]||_0x245340[_0x1cef80('0x1ff0')]()});});}function _0x4af32b(){const _0x4f27fa=_0xac8c91,_0x52e4c9=angular['copy'](_0xcc0c22[_0x4f27fa('0x2186')]);return _0xcc0c22[_0x4f27fa('0x2186')]=[],_0x52e4c9;}function _0x5ed6a4(_0x56b399){const _0x11db34=_0xac8c91,_0x25028e=_0xd50cb8[_0x11db34('0x1c6f')]()[_0x11db34('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20openchannelCannedAnswers?')[_0x11db34('0x26e3')](_0x11db34('0xed5')+_0xcc0c22['selectedOpenchannelAccountOpenchannelCannedAnswers'][_0x11db34('0x1564')]+'\x20selected'+_0x11db34('0x1ee7'))['ariaLabel'](_0x11db34('0x59e'))[_0x11db34('0xe42')](_0x56b399)['ok']('OK')['cancel'](_0x11db34('0x16b8'));_0xd50cb8[_0x11db34('0x1d4')](_0x25028e)[_0x11db34('0x683')](function(){const _0x5dd499=_0x11db34;_0xcc0c22['selectedOpenchannelAccountOpenchannelCannedAnswers']['forEach'](function(_0x169f03){_0x439e9b(_0x169f03);}),_0xcc0c22[_0x5dd499('0x2186')]=[];});}let _0x2645a7=!![],_0x4aecf3=0x1;_0x429a95['$watch'](_0xac8c91('0x229'),function(_0x41101f,_0x5b66a6){const _0x530d32=_0xac8c91;_0x2645a7?_0x350127(function(){_0x2645a7=![];}):(!_0x5b66a6&&(_0x4aecf3=_0xcc0c22[_0x530d32('0x23a2')][_0x530d32('0xdf8')]),_0x41101f!==_0x5b66a6&&(_0xcc0c22[_0x530d32('0x23a2')][_0x530d32('0xdf8')]=0x1),!_0x41101f&&(_0xcc0c22[_0x530d32('0x23a2')]['page']=_0x4aecf3),_0x3d18a9());});}const _0x1887db=_0xee3b3f;_0x374cd9[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate','toasty',_0x189033('0x3cc'),_0x189033('0x26ad'),'api','Auth',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x374cd9(_0x31385a,_0xcf016e,_0x236979,_0x3123c6,_0x16f145,_0x369e67,_0x23c322,_0x3f581e,_0x5ccee8,_0x5c481f,_0x20a0d8,_0x180d41,_0x28f57f,_0x4a5db0){const _0x5b4d5c=_0x189033,_0x1256d6=this;_0x1256d6[_0x5b4d5c('0x11ed')]=_0x20a0d8[_0x5b4d5c('0x20b2')](),_0x1256d6[_0x5b4d5c('0x17f')]=[],_0x1256d6['setting']=_0x28f57f,_0x1256d6[_0x5b4d5c('0xace')]=_0x180d41,_0x1256d6['crudPermissions']=_0x4a5db0,_0x1256d6[_0x5b4d5c('0x258d')]={},_0x1256d6[_0x5b4d5c('0x19b2')]=_0x1256d6[_0x5b4d5c('0x260a')]&&_0x1256d6[_0x5b4d5c('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1256d6['title']='OPENCHANNEL.EDIT_OPENCHANNELCANNEDANSWER',_0x1256d6['openchannelCannedAnswer']=angular[_0x5b4d5c('0x1a86')](_0x5ccee8),_0x1256d6['openchannelCannedAnswers']=_0x3f581e,_0x1256d6[_0x5b4d5c('0x24e4')]=![];!_0x1256d6[_0x5b4d5c('0x26ad')]&&(_0x1256d6[_0x5b4d5c('0x26ad')]={},_0x1256d6[_0x5b4d5c('0xf28')]='OPENCHANNEL.NEW_OPENCHANNELCANNEDANSWER',_0x1256d6[_0x5b4d5c('0x24e4')]=!![]);_0xcf016e[_0x5b4d5c('0x7f2')]['id']&&(_0x1256d6[_0x5b4d5c('0x26ad')][_0x5b4d5c('0x1061')]=_0xcf016e[_0x5b4d5c('0x7f2')]['id']);_0x1256d6[_0x5b4d5c('0x136a')]=_0x16ebd1,_0x1256d6['saveOpenchannelCannedAnswer']=_0x505e0d,_0x1256d6[_0x5b4d5c('0x549')]=_0x487096,_0x1256d6[_0x5b4d5c('0x16b3')]=_0x582712,_0x1256d6[_0x5b4d5c('0xf82')]=_0x55e93f;function _0x16ebd1(){const _0x490527=_0x5b4d5c;_0x1256d6[_0x490527('0x17f')]=[],_0x5c481f[_0x490527('0x136c')][_0x490527('0xb0a')](_0x1256d6[_0x490527('0x26ad')])[_0x490527('0xe53')][_0x490527('0x683')](function(_0x42a3f4){const _0x363133=_0x490527;_0x1256d6['openchannelCannedAnswers'][_0x363133('0x1167')](_0x42a3f4['toJSON']()),_0x23c322[_0x363133('0x53')]({'title':_0x363133('0x25a2'),'msg':_0x1256d6[_0x363133('0x26ad')][_0x363133('0x60a')]?_0x1256d6[_0x363133('0x26ad')][_0x363133('0x60a')]+'\x20has\x20been\x20created!':''}),_0x55e93f(_0x42a3f4);})[_0x490527('0x130a')](function(_0x51a8fe){const _0x4700a3=_0x490527;if(_0x51a8fe[_0x4700a3('0x5a5')]&&_0x51a8fe['data']['errors']&&_0x51a8fe[_0x4700a3('0x5a5')]['errors']['length']){_0x1256d6[_0x4700a3('0x17f')]=_0x51a8fe[_0x4700a3('0x5a5')][_0x4700a3('0x17f')]||[{'message':_0x51a8fe[_0x4700a3('0x1ff0')](),'type':_0x4700a3('0x267b')}];for(let _0x5699e7=0x0;_0x5699e7<_0x51a8fe['data'][_0x4700a3('0x17f')]['length'];_0x5699e7+=0x1){_0x23c322[_0x4700a3('0x52a')]({'title':_0x51a8fe[_0x4700a3('0x5a5')][_0x4700a3('0x17f')][_0x5699e7][_0x4700a3('0xcf0')],'msg':_0x51a8fe[_0x4700a3('0x5a5')][_0x4700a3('0x17f')][_0x5699e7]['message']});}}else _0x23c322['error']({'title':_0x51a8fe[_0x4700a3('0x13ee')]?'API:'+_0x51a8fe[_0x4700a3('0x13ee')]+_0x4700a3('0xbf6')+_0x51a8fe[_0x4700a3('0x24a9')]:_0x4700a3('0x267b'),'msg':_0x51a8fe[_0x4700a3('0x5a5')]?JSON['stringify'](_0x51a8fe[_0x4700a3('0x5a5')][_0x4700a3('0x8c2')]):_0x51a8fe['toString']()});});}function _0x505e0d(){const _0x5d49f5=_0x5b4d5c;_0x1256d6[_0x5d49f5('0x17f')]=[],_0x5c481f[_0x5d49f5('0x136c')][_0x5d49f5('0x2480')]({'id':_0x1256d6[_0x5d49f5('0x26ad')]['id']},_0x1256d6['openchannelCannedAnswer'])[_0x5d49f5('0xe53')][_0x5d49f5('0x683')](function(_0x33e0b8){const _0x4153ce=_0x5d49f5,_0x128561=_0x2e3ca0()[_0x4153ce('0x1c07')](_0x1256d6['openchannelCannedAnswers'],{'id':_0x33e0b8['id']});_0x128561&&_0x2e3ca0()[_0x4153ce('0xf22')](_0x128561,_0x2e3ca0()['pick'](_0x33e0b8[_0x4153ce('0x24e1')](),_0x2e3ca0()[_0x4153ce('0x55e')](_0x128561))),_0x23c322['success']({'title':_0x4153ce('0x11ec'),'msg':_0x1256d6[_0x4153ce('0x26ad')][_0x4153ce('0x60a')]?_0x1256d6[_0x4153ce('0x26ad')]['name']+_0x4153ce('0xf59'):''}),_0x55e93f(_0x33e0b8);})['catch'](function(_0x9458b9){const _0x2ea94a=_0x5d49f5;if(_0x9458b9[_0x2ea94a('0x5a5')]&&_0x9458b9[_0x2ea94a('0x5a5')][_0x2ea94a('0x17f')]&&_0x9458b9['data'][_0x2ea94a('0x17f')]['length']){_0x1256d6[_0x2ea94a('0x17f')]=_0x9458b9['data'][_0x2ea94a('0x17f')]||[{'message':_0x9458b9[_0x2ea94a('0x1ff0')](),'type':_0x2ea94a('0x1301')}];for(let _0x2bd70a=0x0;_0x2bd70a<_0x9458b9[_0x2ea94a('0x5a5')]['errors'][_0x2ea94a('0x1564')];_0x2bd70a++){_0x23c322['error']({'title':_0x9458b9[_0x2ea94a('0x5a5')][_0x2ea94a('0x17f')][_0x2bd70a]['type'],'msg':_0x9458b9['data'][_0x2ea94a('0x17f')][_0x2bd70a][_0x2ea94a('0x8c2')]});}}else _0x23c322['error']({'title':_0x9458b9[_0x2ea94a('0x13ee')]?_0x2ea94a('0x2168')+_0x9458b9['status']+_0x2ea94a('0xbf6')+_0x9458b9[_0x2ea94a('0x24a9')]:'api.cannedAnswer.update','msg':_0x9458b9['data']?JSON[_0x2ea94a('0x258a')](_0x9458b9['data'][_0x2ea94a('0x8c2')]):_0x9458b9[_0x2ea94a('0x1ff0')]()});});}function _0x487096(_0x461b87){const _0x41b494=_0x5b4d5c;_0x1256d6[_0x41b494('0x17f')]=[];const _0x332552=_0x3123c6[_0x41b494('0x1c6f')]()[_0x41b494('0xf28')](_0x41b494('0x4d'))[_0x41b494('0xa6a')](_0x41b494('0x567'))[_0x41b494('0x1040')](_0x41b494('0x80c'))['ok'](_0x41b494('0x2307'))[_0x41b494('0x19fb')](_0x41b494('0x253a'))[_0x41b494('0xe42')](_0x461b87);_0x3123c6[_0x41b494('0x1d4')](_0x332552)[_0x41b494('0x683')](function(){const _0x5c316f=_0x41b494;_0x5c481f[_0x5c316f('0x136c')][_0x5c316f('0xd7e')]({'id':_0x1256d6[_0x5c316f('0x26ad')]['id']})[_0x5c316f('0xe53')]['then'](function(){const _0x393959=_0x5c316f;_0x2e3ca0()[_0x393959('0x3ec')](_0x1256d6['openchannelCannedAnswers'],{'id':_0x1256d6[_0x393959('0x26ad')]['id']}),_0x23c322[_0x393959('0x53')]({'title':_0x393959('0xc95'),'msg':(_0x1256d6[_0x393959('0x26ad')][_0x393959('0x60a')]||_0x393959('0x26ad'))+_0x393959('0x194d')}),_0x55e93f(_0x1256d6[_0x393959('0x26ad')]);})[_0x5c316f('0x130a')](function(_0x1748a4){const _0x399416=_0x5c316f;if(_0x1748a4[_0x399416('0x5a5')]&&_0x1748a4['data'][_0x399416('0x17f')]&&_0x1748a4[_0x399416('0x5a5')]['errors'][_0x399416('0x1564')]){_0x1256d6[_0x399416('0x17f')]=_0x1748a4[_0x399416('0x5a5')][_0x399416('0x17f')]||[{'message':_0x1748a4[_0x399416('0x1ff0')](),'type':_0x399416('0x253e')}];for(let _0x1e54ab=0x0;_0x1e54ab<_0x1748a4[_0x399416('0x5a5')][_0x399416('0x17f')][_0x399416('0x1564')];_0x1e54ab++){_0x23c322[_0x399416('0x52a')]({'title':_0x1748a4['data']['errors'][_0x1e54ab][_0x399416('0xcf0')],'msg':_0x1748a4['data']['errors'][_0x1e54ab][_0x399416('0x8c2')]});}}else _0x23c322['error']({'title':_0x1748a4['status']?_0x399416('0x2168')+_0x1748a4[_0x399416('0x13ee')]+'\x20-\x20'+_0x1748a4[_0x399416('0x24a9')]:_0x399416('0x253e'),'msg':_0x1748a4['data']?JSON[_0x399416('0x258a')](_0x1748a4[_0x399416('0x5a5')][_0x399416('0x8c2')]):_0x1748a4[_0x399416('0x8c2')]||_0x1748a4['toString']()});});},function(){});}function _0x582712(_0x42f773){return _0x42f773===null?undefined:new Date(_0x42f773);}function _0x55e93f(_0x4242e8){const _0x37699a=_0x5b4d5c;_0x3123c6[_0x37699a('0x1715')](_0x4242e8);}}const _0x597da2=_0x374cd9;_0x3d4d56[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),'api',_0x189033('0x1d70'),_0x189033('0xba1')];function _0x3d4d56(_0x5215e6,_0x41f60d,_0x4f7787,_0x1b7063,_0x3d4dcc,_0x2566a8,_0x55d0a7,_0x535ec3,_0x5c533a,_0x4c1bb0,_0x2d5251){const _0x2295dc=_0x189033,_0xc9083e=this;_0xc9083e[_0x2295dc('0x11ed')]=_0x2d5251['getCurrentUser'](),_0xc9083e['dispositions']={'count':0x0,'rows':[]},_0xc9083e[_0x2295dc('0x17')]=[],_0xc9083e[_0x2295dc('0x1134')],_0xc9083e[_0x2295dc('0x1d01')]={'first':_0x2295dc('0x1fd1'),'second':_0x2295dc('0x7c2'),'third':_0x2295dc('0x10ce')},_0xc9083e['query']={'fields':_0x2295dc('0xadb'),'sort':_0x2295dc('0xc36'),'limit':0xa,'page':0x1},_0xc9083e[_0x2295dc('0x12f3')]=_0x24bda0,_0xc9083e[_0x2295dc('0x26eb')]=_0x136a5d,_0xc9083e['success']=_0xd39ccd,_0xc9083e['getDispositions']=_0x4f251b,_0xc9083e['createOrEditDisposition']=_0x56f3ac,_0xc9083e['deleteDisposition']=_0x4a8b3c,_0xc9083e[_0x2295dc('0x224b')]=_0x3b928f,_0xc9083e['deleteSelectedDispositions']=_0x27d35e,_0xc9083e[_0x2295dc('0x268c')]=_0x3afddc,_0xc9083e[_0x2295dc('0x1801')]=_0x136512;function _0x24bda0(_0x1684bd,_0x3f3de1){const _0x1f806d=_0x2295dc;_0xc9083e['openchannelAccount']=_0x1684bd||{},_0xc9083e[_0x1f806d('0x1134')]=typeof _0x3f3de1!==_0x1f806d('0x1867')?_0x3f3de1:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0xc9083e[_0x1f806d('0x23a2')]['OpenchannelAccountId']=_0xc9083e['openchannelAccount']['id'],_0xc9083e[_0x1f806d('0x23a2')]['id']=_0xc9083e[_0x1f806d('0x1963')]['id'],_0x4f251b();}function _0x56f3ac(_0x2b5961,_0x151945){const _0x34d4c5=_0x2295dc;_0x3d4dcc[_0x34d4c5('0x1d4')]({'controller':'CreateOrEditDispositionDialogController','controllerAs':'vm','templateUrl':_0x32807f,'parent':angular['element'](_0x2566a8['body']),'targetEvent':_0x2b5961,'clickOutsideToClose':!![],'locals':{'disposition':_0x151945,'dispositions':_0xc9083e[_0x34d4c5('0x191e')][_0x34d4c5('0xf5d')],'model':{'id':_0xc9083e['openchannelAccount']['id'],'field':_0x34d4c5('0x1061')},'license':null,'setting':null,'crudPermissions':_0xc9083e[_0x34d4c5('0x1134')]}})[_0x34d4c5('0x683')](function(_0x207c18){if(_0x207c18)_0x4f251b();});}function _0x136a5d(_0x105d85,_0x23cb47){const _0x253ae7=_0x2295dc,_0x80c36c=_0x2e3ca0()[_0x253ae7('0x7a2')](_0xc9083e['dispositions'][_0x253ae7('0xf5d')],[_0x253ae7('0x1b62'),_0x105d85['id']]),_0x3073ef=_0x3d4dcc['confirm']()[_0x253ae7('0xf28')](_0x535ec3[_0x253ae7('0x2728')]('TOOLS.NOTIFICATIONS.DISPOSITION_DELETE_TITLE'))[_0x253ae7('0xa6a')](_0x535ec3['instant'](_0x253ae7('0x13bf')+(_0x80c36c?_0x253ae7('0x2235'):'DISPOSITION_DELETE_MESSAGE'),{'name':_0x105d85[_0x253ae7('0x60a')]}))[_0x253ae7('0x1040')](_0x253ae7('0x550'))['targetEvent'](_0x23cb47)['ok']('OK')['cancel'](_0x535ec3[_0x253ae7('0x2728')](_0x253ae7('0x9a1')));_0x3d4dcc[_0x253ae7('0x1d4')](_0x3073ef)[_0x253ae7('0x683')](function(){_0x4a8b3c(_0x105d85);});}function _0xd39ccd(_0x37f042){const _0x4d6b73=_0x2295dc;_0xc9083e[_0x4d6b73('0x191e')]=_0x37f042||{'count':0x0,'rows':[]};}function _0x4f251b(){const _0x55fbd2=_0x2295dc;_0xc9083e['query'][_0x55fbd2('0x1cc8')]=(_0xc9083e['query'][_0x55fbd2('0xdf8')]-0x1)*_0xc9083e['query'][_0x55fbd2('0x6f0')],_0xc9083e['promise']=_0x5c533a[_0x55fbd2('0x1963')][_0x55fbd2('0x13d9')](_0xc9083e[_0x55fbd2('0x23a2')],_0xd39ccd)['$promise'];}function _0x4a8b3c(_0x477ed5){const _0x3b1e09=_0x2295dc;_0x5c533a[_0x3b1e09('0x43f')][_0x3b1e09('0xd7e')]({'id':_0x477ed5['id']})['$promise'][_0x3b1e09('0x683')](function(){const _0x2c57cf=_0x3b1e09;_0x4f251b(),_0x4c1bb0[_0x2c57cf('0x53')]({'title':_0x535ec3[_0x2c57cf('0x2728')](_0x2c57cf('0x210b'))});})['catch'](function(_0x150b7b){const _0x4caba2=_0x3b1e09;if(_0x150b7b[_0x4caba2('0x5a5')]&&_0x150b7b[_0x4caba2('0x5a5')][_0x4caba2('0x17f')]&&_0x150b7b[_0x4caba2('0x5a5')]['errors']['length']){_0xc9083e['errors']=_0x150b7b[_0x4caba2('0x5a5')][_0x4caba2('0x17f')]||[{'message':_0x150b7b['toString'](),'type':'SYSTEM:DELETEdisposition'}];for(let _0x5da964=0x0;_0x5da964<_0x150b7b[_0x4caba2('0x5a5')][_0x4caba2('0x17f')][_0x4caba2('0x1564')];_0x5da964++){_0x4c1bb0[_0x4caba2('0x52a')]({'title':_0x150b7b['data'][_0x4caba2('0x17f')][_0x5da964]['type'],'msg':_0x150b7b[_0x4caba2('0x5a5')][_0x4caba2('0x17f')][_0x5da964]['message']});}}else _0x4c1bb0[_0x4caba2('0x52a')]({'title':_0x150b7b[_0x4caba2('0x13ee')]?_0x4caba2('0x2168')+_0x150b7b[_0x4caba2('0x13ee')]+_0x4caba2('0xbf6')+_0x150b7b['statusText']:_0x4caba2('0x189b'),'msg':_0x150b7b[_0x4caba2('0x5a5')]?JSON['stringify'](_0x150b7b[_0x4caba2('0x5a5')][_0x4caba2('0x8c2')]):_0x150b7b[_0x4caba2('0x8c2')]||_0x150b7b['toString']()});});}function _0x3b928f(){const _0x390d02=_0x2295dc,_0xb389ab=angular['copy'](_0xc9083e[_0x390d02('0x17')]);return _0xc9083e[_0x390d02('0x17')]=[],_0xb389ab;}function _0x27d35e(_0x3cc812){const _0x26a285=_0x2295dc,_0xf213f5=_0x3d4dcc[_0x26a285('0x1c6f')]()['title'](_0x535ec3['instant'](_0x26a285('0xfa')))[_0x26a285('0xa6a')](_0x535ec3[_0x26a285('0x2728')]('TOOLS.NOTIFICATIONS.DISPOSITIONS_DELETE_MESSAGE',{'total':_0xc9083e[_0x26a285('0x17')][_0x26a285('0x1564')]}))[_0x26a285('0x1040')](_0x26a285('0xb49'))[_0x26a285('0xe42')](_0x3cc812)['ok']('OK')[_0x26a285('0x19fb')](_0x535ec3[_0x26a285('0x2728')](_0x26a285('0x9a1')));_0x3d4dcc[_0x26a285('0x1d4')](_0xf213f5)['then'](function(){const _0x331a32=_0x26a285;_0xc9083e[_0x331a32('0x17')][_0x331a32('0x1299')](function(_0x325569){_0x4a8b3c(_0x325569);}),_0xc9083e['selectedDispositions']=[];});}function _0x3afddc(){const _0x4a5d0b=_0x2295dc;_0xc9083e[_0x4a5d0b('0x17')]=[];}function _0x136512(){const _0x476822=_0x2295dc;_0xc9083e['selectedDispositions']=_0xc9083e['dispositions'][_0x476822('0xf5d')];}let _0xf57d5d=!![],_0x25812a=0x1;_0x5215e6[_0x2295dc('0x186d')](_0x2295dc('0x229'),function(_0xc37bab,_0x3ad442){const _0x5e423a=_0x2295dc;_0xf57d5d?_0x55d0a7(function(){_0xf57d5d=![];}):(!_0x3ad442&&(_0x25812a=_0xc9083e[_0x5e423a('0x23a2')][_0x5e423a('0xdf8')]),_0xc37bab!==_0x3ad442&&(_0xc9083e[_0x5e423a('0x23a2')][_0x5e423a('0xdf8')]=0x1),!_0xc37bab&&(_0xc9083e['query'][_0x5e423a('0xdf8')]=_0x25812a),_0x4f251b());});}const _0x5ed64b=_0x3d4d56,_0x222d8d=_0x180212['p']+_0x189033('0x1608');_0x1c7921['$inject']=[_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d08'),'license',_0x189033('0x260a'),'api','toasty',_0x189033('0xba1'),_0x189033('0x1963'),_0x189033('0x22df')];function _0x1c7921(_0x37f479,_0x46f1a1,_0x4e476c,_0x596a58,_0x4e83f6,_0x6b4713,_0x308baa,_0x3a5768,_0x5302b9,_0x134910,_0x3c8429,_0x520b2c){const _0x4b5da8=_0x189033,_0x25ed62=this;_0x25ed62[_0x4b5da8('0x11ed')]=_0x134910[_0x4b5da8('0x20b2')](),_0x25ed62['license']=_0x6b4713,_0x25ed62[_0x4b5da8('0x260a')]=_0x308baa,_0x25ed62[_0x4b5da8('0x19b2')]=_0x25ed62[_0x4b5da8('0x260a')][_0x4b5da8('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x25ed62[_0x4b5da8('0x1224')]=_0x46f1a1[_0x4b5da8('0x173e')]()+'://'+_0x46f1a1[_0x4b5da8('0x19ac')](),_0x25ed62[_0x4b5da8('0x1963')]=_0x3c8429||_0x37f479[_0x4b5da8('0x7f2')][_0x4b5da8('0x1963')]||{},_0x25ed62['userProfileSection']=_0x520b2c&&_0x520b2c['count']==0x1?_0x520b2c[_0x4b5da8('0xf5d')][0x0]:null,_0x25ed62[_0x4b5da8('0x1134')]=_0x134910['parseCrudPermissions'](_0x25ed62[_0x4b5da8('0x22df')]?_0x25ed62[_0x4b5da8('0x22df')]['crudPermissions']:null),_0x25ed62['hasModulePermissions']={},_0x25ed62[_0x4b5da8('0x517')]=_0x37f479['params'][_0x4b5da8('0x1904')]||0x0,_0x25ed62[_0x4b5da8('0x2814')]=_0x4bd901,_0x25ed62[_0x4b5da8('0x2430')]=_0x5302b9[_0x4b5da8('0x2289')],_0x25ed62[_0x4b5da8('0x26cd')]=_0x3df81b,_0x25ed62[_0x4b5da8('0x339')]=_0x195fb7,_0x134910[_0x4b5da8('0xca1')](_0x4b5da8('0x20c2'))?_0x3a5768['cmList'][_0x4b5da8('0x1e6e')]({'fields':_0x4b5da8('0xa10'),'sort':_0x4b5da8('0x60a')})['$promise'][_0x4b5da8('0x683')](function(_0x409f93){const _0x43c135=_0x4b5da8;_0x25ed62[_0x43c135('0xe01')]=_0x409f93[_0x43c135('0xf5d')]||[];})['catch'](function(_0x457024){const _0x16542d=_0x4b5da8;_0x5302b9[_0x16542d('0x52a')]({'title':_0x457024[_0x16542d('0x13ee')]?_0x16542d('0x2168')+_0x457024[_0x16542d('0x13ee')]+_0x16542d('0xbf6')+_0x457024['statusText']:_0x16542d('0x251b'),'msg':_0x457024[_0x16542d('0x5a5')]?JSON[_0x16542d('0x258a')](_0x457024[_0x16542d('0x5a5')]):_0x457024['toString']()});}):_0x3a5768[_0x4b5da8('0x259b')][_0x4b5da8('0x1e6e')]({'fields':_0x4b5da8('0xa10'),'sort':_0x4b5da8('0x60a')})[_0x4b5da8('0xe53')][_0x4b5da8('0x683')](function(_0x163b0f){_0x25ed62['lists']=_0x163b0f['rows']||[];})[_0x4b5da8('0x683')](function(){const _0x18eb27=_0x4b5da8;return _0x3a5768[_0x18eb27('0x22df')][_0x18eb27('0x1e6e')]({'userProfileId':_0x25ed62[_0x18eb27('0x11ed')]['userProfileId'],'sectionId':0x12d})['$promise'];})['then'](function(_0x5b1cac){const _0x2f79c6=_0x4b5da8,_0x3be801=_0x5b1cac&&_0x5b1cac[_0x2f79c6('0xf5d')]?_0x5b1cac[_0x2f79c6('0xf5d')][0x0]:null;if(!_0x3be801){const _0x541e27=[];let _0x55ee05=null;_0x25ed62['openchannelAccount']&&(_0x55ee05=_0x2e3ca0()[_0x2f79c6('0x1c07')](_0x25ed62[_0x2f79c6('0xe01')],{'id':Number(_0x25ed62[_0x2f79c6('0x1963')]['ListId'])}));for(let _0x2bbde3=0x0;_0x2bbde3<_0x25ed62['lists'][_0x2f79c6('0x1564')];_0x2bbde3++){_0x55ee05&&_0x25ed62[_0x2f79c6('0xe01')][_0x2bbde3]['id']===_0x55ee05['id']&&(_0x25ed62[_0x2f79c6('0xe01')][_0x2bbde3][_0x2f79c6('0x319')]=![],_0x541e27['push'](_0x25ed62[_0x2f79c6('0xe01')][_0x2bbde3]));}_0x25ed62[_0x2f79c6('0xe01')]=_0x541e27;}else{if(!_0x3be801[_0x2f79c6('0x170')])return _0x3a5768[_0x2f79c6('0xcf7')][_0x2f79c6('0x1e6e')]({'sectionId':_0x3be801['id']})['$promise'][_0x2f79c6('0x683')](function(_0xfaa287){const _0x55aa7a=_0x2f79c6,_0x48fc3d=_0x2e3ca0()[_0x55aa7a('0x386')](_0xfaa287[_0x55aa7a('0xf5d')],function(_0xccd7ea){const _0x2e469b=_0x55aa7a;return _0x2e3ca0()['find'](_0x25ed62['lists'],{'id':_0xccd7ea[_0x2e469b('0x832')]});});let _0x3457df=null;_0x25ed62[_0x55aa7a('0x1963')]&&(_0x3457df=_0x2e3ca0()[_0x55aa7a('0x1c07')](_0x25ed62[_0x55aa7a('0xe01')],{'id':Number(_0x25ed62[_0x55aa7a('0x1963')][_0x55aa7a('0x1e4f')])}));if(_0x3457df&&!_0x2e3ca0()[_0x55aa7a('0x7a2')](_0x48fc3d,['id',_0x3457df['id']])){const _0x3ccd18=_0x2e3ca0()['find'](_0x25ed62[_0x55aa7a('0xe01')],{'id':_0x3457df['id']});_0x3ccd18[_0x55aa7a('0x319')]=![],_0x48fc3d[_0x55aa7a('0x1fd0')](_0x3ccd18);}_0x25ed62['lists']=_0x48fc3d;});}})[_0x4b5da8('0x130a')](function(_0x55455c){const _0x4772a6=_0x4b5da8;_0x5302b9[_0x4772a6('0x52a')]({'title':_0x55455c[_0x4772a6('0x13ee')]?_0x4772a6('0x2168')+_0x55455c[_0x4772a6('0x13ee')]+'\x20-\x20'+_0x55455c[_0x4772a6('0x24a9')]:'SYSTEM:GETlists','msg':_0x55455c[_0x4772a6('0x5a5')]?JSON[_0x4772a6('0x258a')](_0x55455c[_0x4772a6('0x5a5')]):_0x55455c[_0x4772a6('0x1ff0')]()});}),_0x3a5768['cmContact'][_0x4b5da8('0x2267')]({'id':_0x25ed62[_0x4b5da8('0x1963')][_0x4b5da8('0x1e4f')]})[_0x4b5da8('0xe53')]['then'](function(_0x2695fd){const _0x5c71df=_0x4b5da8;_0x25ed62['fields']=[],_0x2695fd=_0x2e3ca0()['values'](_0x2695fd['toJSON']());const _0x99f31c=['id','createdAt','updatedAt',_0x5c71df('0x1125'),'scheduledat',_0x5c71df('0x1e4f'),'CompanyId'];for(let _0x52de12=0x0;_0x52de12<_0x2695fd[_0x5c71df('0x1564')];_0x52de12++){!_0x2e3ca0()[_0x5c71df('0x2292')](_0x99f31c,_0x2695fd[_0x52de12]['columnName'])&&_0x25ed62['fields'][_0x5c71df('0x1fd0')](_0x2695fd[_0x52de12]);}})[_0x4b5da8('0x130a')](function(_0x5a9d21){const _0x22067b=_0x4b5da8;_0x5302b9[_0x22067b('0x52a')]({'title':_0x5a9d21[_0x22067b('0x13ee')]?_0x22067b('0x2168')+_0x5a9d21[_0x22067b('0x13ee')]+'\x20-\x20'+_0x5a9d21[_0x22067b('0x24a9')]:_0x22067b('0x2470'),'msg':_0x5a9d21[_0x22067b('0x5a5')]?JSON[_0x22067b('0x258a')](_0x5a9d21['data']):_0x5a9d21[_0x22067b('0x1ff0')]()});}),_0x134910['hasRole'](_0x4b5da8('0x20c2'))?_0x3a5768['pause'][_0x4b5da8('0x1e6e')]({'fields':'name,id','sort':_0x4b5da8('0x60a'),'nolimit':'true'})[_0x4b5da8('0xe53')][_0x4b5da8('0x683')](function(_0x24c562){const _0x13db89=_0x4b5da8;_0x25ed62['pauses']=_0x24c562[_0x13db89('0xf5d')]||[];})[_0x4b5da8('0x130a')](function(_0x1eb08f){const _0x447807=_0x4b5da8;_0x5302b9['error']({'title':_0x1eb08f[_0x447807('0x13ee')]?_0x447807('0x2168')+_0x1eb08f[_0x447807('0x13ee')]+'\x20-\x20'+_0x1eb08f[_0x447807('0x24a9')]:_0x447807('0x4ba'),'msg':_0x1eb08f[_0x447807('0x5a5')]?JSON['stringify'](_0x1eb08f[_0x447807('0x5a5')]):_0x1eb08f['toString']()});}):_0x3a5768[_0x4b5da8('0xa4')]['get']({'fields':_0x4b5da8('0x1688'),'sort':_0x4b5da8('0x60a'),'nolimit':'true'})[_0x4b5da8('0xe53')][_0x4b5da8('0x683')](function(_0x40e51a){const _0x1026fc=_0x4b5da8;_0x25ed62[_0x1026fc('0x22ab')]=_0x40e51a['rows']||[];})['then'](function(){const _0x39d6fd=_0x4b5da8;return _0x3a5768[_0x39d6fd('0x22df')][_0x39d6fd('0x1e6e')]({'userProfileId':_0x25ed62[_0x39d6fd('0x11ed')]['userProfileId'],'sectionId':0x3ed})['$promise'];})[_0x4b5da8('0x683')](function(_0x1a3a59){const _0x3fab64=_0x4b5da8,_0x164535=_0x1a3a59&&_0x1a3a59[_0x3fab64('0xf5d')]?_0x1a3a59[_0x3fab64('0xf5d')][0x0]:null;if(!_0x164535)_0x25ed62[_0x3fab64('0x22ab')]=[];else{if(!_0x164535[_0x3fab64('0x170')])return _0x3a5768[_0x3fab64('0xcf7')][_0x3fab64('0x1e6e')]({'sectionId':_0x164535['id']})['$promise'][_0x3fab64('0x683')](function(_0x1f545e){const _0x648600=_0x3fab64,_0x5ff791=_0x2e3ca0()['map'](_0x1f545e[_0x648600('0xf5d')],function(_0x20ccc7){const _0x531cd8=_0x648600;return _0x2e3ca0()['find'](_0x25ed62[_0x531cd8('0x22ab')],{'id':_0x20ccc7['resourceId']});});_0x25ed62[_0x648600('0x22ab')][_0x648600('0x1299')](function(_0x5f225e){const _0x414771=_0x648600;!_0x2e3ca0()['some'](_0x5ff791,['id',_0x5f225e['id']])&&(_0x5f225e[_0x414771('0x319')]=![]),_0x5ff791[_0x414771('0x1fd0')](_0x5f225e);}),_0x25ed62[_0x648600('0x22ab')]=_0x5ff791;});}})[_0x4b5da8('0x130a')](function(_0xb25fa){const _0x564e70=_0x4b5da8;_0x5302b9[_0x564e70('0x52a')]({'title':_0xb25fa[_0x564e70('0x13ee')]?_0x564e70('0x2168')+_0xb25fa[_0x564e70('0x13ee')]+_0x564e70('0xbf6')+_0xb25fa['statusText']:_0x564e70('0xc45'),'msg':_0xb25fa[_0x564e70('0x5a5')]?JSON[_0x564e70('0x258a')](_0xb25fa['data']):_0xb25fa[_0x564e70('0x1ff0')]()});});function _0x4bd901(_0x3bbb0e,_0x5b63c6){const _0x38b25f=_0x4b5da8;_0x4e476c['show']({'controller':'OpenchannelAccountagentaddController','controllerAs':'vm','templateUrl':_0x222d8d,'parent':angular[_0x38b25f('0x1fcc')](_0x596a58[_0x38b25f('0x18e5')]),'targetEvent':_0x5b63c6,'clickOutsideToClose':!![],'locals':{'openchannelAccount':_0x3bbb0e,'openchannelAccounts':_0x25ed62[_0x38b25f('0x1952')]?_0x25ed62[_0x38b25f('0x1952')][_0x38b25f('0xf5d')]:[],'crudPermissions':_0x25ed62['crudPermissions'],'realtime':![]}});}function _0x3df81b(){const _0x5bfa9e=_0x4b5da8;_0x37f479['go'](_0x5bfa9e('0x225d'),{},{'reload':_0x5bfa9e('0x225d')});}function _0x195fb7(){const _0x135900=_0x4b5da8;_0x3a5768[_0x135900('0x1963')][_0x135900('0x2480')]({'id':_0x25ed62['openchannelAccount']['id']},_0x25ed62['openchannelAccount'])['$promise'][_0x135900('0x683')](function(){const _0x4a3e3d=_0x135900;_0x5302b9[_0x4a3e3d('0x53')]({'title':'OpenchannelAccount\x20updated!','msg':_0x25ed62[_0x4a3e3d('0x1963')]['name']?_0x25ed62[_0x4a3e3d('0x1963')][_0x4a3e3d('0x60a')]+_0x4a3e3d('0x96c'):''});})[_0x135900('0x130a')](function(_0x52b595){const _0x3c3d3b=_0x135900;_0x5302b9[_0x3c3d3b('0x52a')]({'title':_0x52b595['status']?_0x3c3d3b('0x2168')+_0x52b595['status']+_0x3c3d3b('0xbf6')+_0x52b595[_0x3c3d3b('0x24a9')]:_0x3c3d3b('0x9eb'),'msg':_0x52b595[_0x3c3d3b('0x5a5')]?JSON[_0x3c3d3b('0x258a')](_0x52b595[_0x3c3d3b('0x5a5')]):_0x52b595[_0x3c3d3b('0x1ff0')]()});});}}const _0x242e19=_0x1c7921,_0x3f19e8=_0x180212['p']+_0x189033('0x2117');_0x25e050[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),'$translate',_0x189033('0x1952'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x25e050(_0x4d17ea,_0x4e4011,_0x5aaad1,_0x357d56,_0x28360c,_0x20ddc6,_0x320f9e,_0xcc2c0f,_0x479c31,_0x244dda,_0x38813c,_0xeb126d,_0x4b4f51,_0x1de8f3,_0x32d74b,_0x223201,_0x55bd71){const _0x3d6f5f=_0x189033,_0x2f1a2e=this;_0x2f1a2e['license']=_0x223201,_0x2f1a2e[_0x3d6f5f('0x260a')]=_0x55bd71,_0x2f1a2e[_0x3d6f5f('0x11ed')]=_0x32d74b['getCurrentUser'](),_0x2f1a2e['openchannelAccounts']=_0x479c31||{'count':0x0,'rows':[]},_0x2f1a2e[_0x3d6f5f('0x2a')]=_0x244dda,_0x2f1a2e[_0x3d6f5f('0x22df')]=_0x38813c&&_0x38813c[_0x3d6f5f('0x50d')]==0x1?_0x38813c[_0x3d6f5f('0xf5d')][0x0]:null,_0x2f1a2e[_0x3d6f5f('0x1134')]=_0x32d74b[_0x3d6f5f('0x142a')](_0x2f1a2e[_0x3d6f5f('0x22df')]?_0x2f1a2e[_0x3d6f5f('0x22df')][_0x3d6f5f('0x1134')]:null),_0x2f1a2e['table']=_0x3d6f5f('0x1952'),_0x2f1a2e[_0x3d6f5f('0x247')]='',_0x2f1a2e['listOrderAsc']=null,_0x2f1a2e[_0x3d6f5f('0x1e2e')]=[],_0x2f1a2e[_0x3d6f5f('0x23a2')]={'fields':_0x3d6f5f('0x83'),'sort':_0x3d6f5f('0xc36'),'limit':0xa,'page':0x1},_0x2f1a2e['editstate']=_0x481e6d,_0x2f1a2e[_0x3d6f5f('0xce9')]=_0x302a8f,_0x2f1a2e[_0x3d6f5f('0x2814')]=_0xdabdc9,_0x2f1a2e[_0x3d6f5f('0x194f')]=_0x5b7b6c,_0x2f1a2e[_0x3d6f5f('0x53')]=_0x572602,_0x2f1a2e['getOpenchannelAccounts']=_0x157e57,_0x2f1a2e[_0x3d6f5f('0x69d')]=_0x979d6a,_0x2f1a2e[_0x3d6f5f('0x2400')]=_0x352264,_0x2f1a2e[_0x3d6f5f('0x285f')]=_0x5a26f7,_0x2f1a2e[_0x3d6f5f('0x1a17')]=_0x37a97d,_0x2f1a2e['deselectOpenchannelAccounts']=_0xa47b04,_0x2f1a2e[_0x3d6f5f('0x437')]=_0x3c0bdb,_0x32d74b[_0x3d6f5f('0xca1')](_0x3d6f5f('0x20c2'))?_0xeb126d['cmList'][_0x3d6f5f('0x1e6e')]({'fields':_0x3d6f5f('0xa10'),'sort':_0x3d6f5f('0x60a')})[_0x3d6f5f('0xe53')][_0x3d6f5f('0x683')](function(_0xeee795){const _0x3f47e5=_0x3d6f5f;_0x2f1a2e[_0x3f47e5('0xe01')]=_0xeee795['rows']||[];})['catch'](function(_0x1c550f){const _0x16d0cc=_0x3d6f5f;_0x1de8f3['error']({'title':_0x1c550f['status']?_0x16d0cc('0x2168')+_0x1c550f[_0x16d0cc('0x13ee')]+'\x20-\x20'+_0x1c550f[_0x16d0cc('0x24a9')]:_0x16d0cc('0x251b'),'msg':_0x1c550f['data']?JSON[_0x16d0cc('0x258a')](_0x1c550f['data']):_0x1c550f['toString']()});}):_0xeb126d['cmList'][_0x3d6f5f('0x1e6e')]({'fields':_0x3d6f5f('0xa10'),'sort':'name'})[_0x3d6f5f('0xe53')][_0x3d6f5f('0x683')](function(_0xb011c2){const _0x5d084c=_0x3d6f5f;_0x2f1a2e[_0x5d084c('0xe01')]=_0xb011c2['rows']||[];})['then'](function(){const _0x32a0ac=_0x3d6f5f;return _0xeb126d[_0x32a0ac('0x22df')][_0x32a0ac('0x1e6e')]({'userProfileId':_0x2f1a2e[_0x32a0ac('0x11ed')][_0x32a0ac('0x2f')],'sectionId':0x12d})['$promise'];})[_0x3d6f5f('0x683')](function(_0x3839f3){const _0x5c323=_0x3d6f5f,_0x340288=_0x3839f3&&_0x3839f3[_0x5c323('0xf5d')]?_0x3839f3[_0x5c323('0xf5d')][0x0]:null;if(!_0x340288){const _0x74d1f4=[];let _0x244631=null;_0x2f1a2e[_0x5c323('0x1963')]&&(_0x244631=_0x2e3ca0()['find'](_0x2f1a2e['lists'],{'id':Number(_0x2f1a2e[_0x5c323('0x1963')][_0x5c323('0x1e4f')])}));for(let _0x2a7bca=0x0;_0x2a7bca<_0x2f1a2e[_0x5c323('0xe01')][_0x5c323('0x1564')];_0x2a7bca++){_0x244631&&_0x2f1a2e[_0x5c323('0xe01')][_0x2a7bca]['id']===_0x244631['id']&&(_0x2f1a2e[_0x5c323('0xe01')][_0x2a7bca][_0x5c323('0x319')]=![],_0x74d1f4[_0x5c323('0x1fd0')](_0x2f1a2e[_0x5c323('0xe01')][_0x2a7bca]));}_0x2f1a2e[_0x5c323('0xe01')]=_0x74d1f4;}else{if(!_0x340288['autoAssociation'])return _0xeb126d[_0x5c323('0xcf7')][_0x5c323('0x1e6e')]({'sectionId':_0x340288['id']})[_0x5c323('0xe53')][_0x5c323('0x683')](function(_0xa2b23c){const _0x54181=_0x5c323,_0x482c6d=_0x2e3ca0()[_0x54181('0x386')](_0xa2b23c[_0x54181('0xf5d')],function(_0x272ebe){const _0x50d820=_0x54181;return _0x2e3ca0()[_0x50d820('0x1c07')](_0x2f1a2e[_0x50d820('0xe01')],{'id':_0x272ebe['resourceId']});});let _0x576b72=null;_0x2f1a2e[_0x54181('0x1963')]&&(_0x576b72=_0x2e3ca0()['find'](_0x2f1a2e['lists'],{'id':Number(_0x2f1a2e[_0x54181('0x1963')][_0x54181('0x1e4f')])}));if(_0x576b72&&!_0x2e3ca0()[_0x54181('0x7a2')](_0x482c6d,['id',_0x576b72['id']])){const _0x174aff=_0x2e3ca0()[_0x54181('0x1c07')](_0x2f1a2e['lists'],{'id':_0x576b72['id']});_0x174aff['canSelect']=![],_0x482c6d[_0x54181('0x1fd0')](_0x174aff);}_0x2f1a2e[_0x54181('0xe01')]=_0x482c6d;});}})[_0x3d6f5f('0x130a')](function(_0x2c00d2){const _0x270455=_0x3d6f5f;_0x1de8f3[_0x270455('0x52a')]({'title':_0x2c00d2[_0x270455('0x13ee')]?_0x270455('0x2168')+_0x2c00d2[_0x270455('0x13ee')]+_0x270455('0xbf6')+_0x2c00d2[_0x270455('0x24a9')]:_0x270455('0x11e3'),'msg':_0x2c00d2[_0x270455('0x5a5')]?JSON[_0x270455('0x258a')](_0x2c00d2['data']):_0x2c00d2[_0x270455('0x1ff0')]()});});function _0x481e6d(_0x101420){const _0x2578db=_0x3d6f5f;_0x5aaad1['go'](_0x2578db('0xae7'),{'id':_0x101420['id'],'openchannelAccount':_0x101420,'crudPermissions':_0x2f1a2e[_0x2578db('0x1134')]});}function _0x302a8f(_0x1bf83a){const _0x75d0db=_0x3d6f5f;_0x5aaad1['go'](_0x75d0db('0xae7'),{'id':_0x1bf83a['id'],'tab':0x5});}function _0xdabdc9(_0xda189e,_0x4dad73){const _0x3c956e=_0x3d6f5f;_0x28360c[_0x3c956e('0x1d4')]({'controller':_0x3c956e('0xac6'),'controllerAs':'vm','templateUrl':_0x222d8d,'parent':angular[_0x3c956e('0x1fcc')](_0x20ddc6[_0x3c956e('0x18e5')]),'targetEvent':_0x4dad73,'clickOutsideToClose':!![],'locals':{'openchannelAccount':_0xda189e,'openchannelAccounts':_0x2f1a2e[_0x3c956e('0x1952')]?_0x2f1a2e[_0x3c956e('0x1952')]['rows']:[],'crudPermissions':_0x2f1a2e['crudPermissions'],'realtime':![]}});}function _0x5b7b6c(_0x171953,_0x477472){const _0x351ade=_0x3d6f5f,_0x1726e6=_0x28360c['confirm']()['title'](_0x351ade('0x1b01')+_0x2e3ca0()['startCase']('openchannelAccount')+'?')['htmlContent'](_0x351ade('0xed5')+(_0x171953[_0x351ade('0x60a')]||_0x351ade('0x1963'))+_0x351ade('0x20f1')+_0x351ade('0x1ee7'))[_0x351ade('0x1040')](_0x351ade('0x1914'))['targetEvent'](_0x477472)['ok']('OK')[_0x351ade('0x19fb')](_0x351ade('0x16b8'));_0x28360c[_0x351ade('0x1d4')](_0x1726e6)['then'](function(){_0x352264(_0x171953);},function(){const _0x40ba9c=_0x351ade;console[_0x40ba9c('0x1b2b')](_0x40ba9c('0x16b8'));});}let _0x4baf3a=!![],_0x57851d=0x1;_0x4d17ea['$watch']('vm.query.filter',function(_0x1a7c5a,_0x33f04d){const _0x11a6c2=_0x3d6f5f;_0x4baf3a?_0x320f9e(function(){_0x4baf3a=![];}):(!_0x33f04d&&(_0x57851d=_0x2f1a2e['query'][_0x11a6c2('0xdf8')]),_0x1a7c5a!==_0x33f04d&&(_0x2f1a2e[_0x11a6c2('0x23a2')][_0x11a6c2('0xdf8')]=0x1),!_0x1a7c5a&&(_0x2f1a2e[_0x11a6c2('0x23a2')][_0x11a6c2('0xdf8')]=_0x57851d),_0x2f1a2e[_0x11a6c2('0x24e3')]());});function _0x572602(_0x5cf384){const _0x5c026e=_0x3d6f5f;_0x2f1a2e[_0x5c026e('0x1952')]=_0x5cf384||{'count':0x0,'rows':[]};}function _0x157e57(){const _0x1c875e=_0x3d6f5f;_0x2f1a2e['query'][_0x1c875e('0x1cc8')]=(_0x2f1a2e['query'][_0x1c875e('0xdf8')]-0x1)*_0x2f1a2e[_0x1c875e('0x23a2')]['limit'],_0x32d74b[_0x1c875e('0xca1')](_0x1c875e('0x20c2'))?_0x2f1a2e[_0x1c875e('0x1883')]=_0xeb126d['openchannelAccount']['get'](_0x2f1a2e[_0x1c875e('0x23a2')],_0x572602)[_0x1c875e('0xe53')]:(_0x2f1a2e['query']['id']=_0x2f1a2e[_0x1c875e('0x2a')]['id'],_0x2f1a2e[_0x1c875e('0x23a2')][_0x1c875e('0x1aa')]=_0x1c875e('0x1e08'),_0x2f1a2e[_0x1c875e('0x1883')]=_0xeb126d[_0x1c875e('0x2a')][_0x1c875e('0x241d')](_0x2f1a2e[_0x1c875e('0x23a2')],_0x572602)['$promise']);}function _0x979d6a(_0x34eb4c,_0x1dd12f){const _0x189133=_0x3d6f5f;_0x28360c['show']({'controller':'CreateOrEditOpenchannelAccountDialogController','controllerAs':'vm','templateUrl':_0x3f19e8,'parent':angular[_0x189133('0x1fcc')](_0x20ddc6['body']),'targetEvent':_0x34eb4c,'clickOutsideToClose':!![],'locals':{'openchannelAccount':_0x1dd12f,'openchannelAccounts':_0x2f1a2e[_0x189133('0x1952')]['rows'],'license':_0x2f1a2e['license'],'setting':_0x2f1a2e[_0x189133('0x260a')],'crudPermissions':_0x2f1a2e['crudPermissions']}});}function _0x352264(_0x78ae76){const _0xdbf144=_0x3d6f5f;_0xeb126d[_0xdbf144('0x1963')][_0xdbf144('0xd7e')]({'id':_0x78ae76['id']})[_0xdbf144('0xe53')][_0xdbf144('0x683')](function(){const _0x223ca2=_0xdbf144;_0x2e3ca0()['remove'](_0x2f1a2e[_0x223ca2('0x1952')][_0x223ca2('0xf5d')],{'id':_0x78ae76['id']}),_0x2f1a2e[_0x223ca2('0x1952')][_0x223ca2('0x50d')]-=0x1,!_0x2f1a2e[_0x223ca2('0x1952')][_0x223ca2('0xf5d')][_0x223ca2('0x1564')]&&_0x2f1a2e[_0x223ca2('0x24e3')](),_0x1de8f3[_0x223ca2('0x53')]({'title':_0x2e3ca0()[_0x223ca2('0x1e03')](_0x223ca2('0x199d'))+_0x223ca2('0xbfc'),'msg':_0x78ae76[_0x223ca2('0x60a')]?_0x78ae76[_0x223ca2('0x60a')]+_0x223ca2('0x194d'):''});})[_0xdbf144('0x130a')](function(_0x2d34ff){const _0x43653a=_0xdbf144;if(_0x2d34ff['data']&&_0x2d34ff[_0x43653a('0x5a5')]['errors']&&_0x2d34ff[_0x43653a('0x5a5')][_0x43653a('0x17f')][_0x43653a('0x1564')]){_0x2f1a2e['errors']=_0x2d34ff['data'][_0x43653a('0x17f')]||[{'message':_0x2d34ff[_0x43653a('0x1ff0')](),'type':'SYSTEM:DELETEopenchannelAccount'}];for(let _0xd1d52d=0x0;_0xd1d52d<_0x2d34ff[_0x43653a('0x5a5')][_0x43653a('0x17f')][_0x43653a('0x1564')];_0xd1d52d++){_0x1de8f3[_0x43653a('0x52a')]({'title':_0x2d34ff['data']['errors'][_0xd1d52d][_0x43653a('0xcf0')],'msg':_0x2d34ff[_0x43653a('0x5a5')][_0x43653a('0x17f')][_0xd1d52d]['message']});}}else _0x1de8f3['error']({'title':_0x2d34ff[_0x43653a('0x13ee')]?_0x43653a('0x2168')+_0x2d34ff['status']+_0x43653a('0xbf6')+_0x2d34ff['statusText']:_0x43653a('0x19fe'),'msg':_0x2d34ff[_0x43653a('0x5a5')]?JSON['stringify'](_0x2d34ff[_0x43653a('0x5a5')]['message']):_0x2d34ff['message']||_0x2d34ff['toString']()});});}function _0x5a26f7(){const _0x3232d7=_0x3d6f5f,_0x5b46d1=angular[_0x3232d7('0x1a86')](_0x2f1a2e[_0x3232d7('0x1e2e')]);return _0x2f1a2e[_0x3232d7('0x1e2e')]=[],_0x5b46d1;}function _0x37a97d(_0x157ff7){const _0x49c504=_0x3d6f5f,_0x114ef7=_0x28360c[_0x49c504('0x1c6f')]()[_0x49c504('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20openchannelAccounts?')[_0x49c504('0x26e3')](_0x49c504('0xed5')+_0x2f1a2e[_0x49c504('0x1e2e')][_0x49c504('0x1564')]+_0x49c504('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x49c504('0x188d'))['targetEvent'](_0x157ff7)['ok']('OK')[_0x49c504('0x19fb')](_0x49c504('0x16b8'));_0x28360c[_0x49c504('0x1d4')](_0x114ef7)[_0x49c504('0x683')](function(){const _0x5a50cf=_0x49c504;_0x2f1a2e[_0x5a50cf('0x1e2e')][_0x5a50cf('0x1299')](function(_0x35bbd0){_0x352264(_0x35bbd0);}),_0x2f1a2e['selectedOpenchannelAccounts']=[];});}function _0xa47b04(){const _0x230f58=_0x3d6f5f;_0x2f1a2e[_0x230f58('0x1e2e')]=[];}function _0x3c0bdb(){const _0x252505=_0x3d6f5f;_0x2f1a2e[_0x252505('0x1e2e')]=_0x2f1a2e[_0x252505('0x1952')][_0x252505('0xf5d')];}}const _0x30339a=_0x25e050;_0x45852b[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty',_0x189033('0xae'),'openchannelQueue','api','Auth','license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x45852b(_0x2671e4,_0x4a67f4,_0x19bedc,_0xc88c23,_0x2d5184,_0x56e891,_0x2a180c,_0xba9043,_0x234c73,_0x1bc08d,_0x43b091,_0x3c97c4,_0x43917f,_0x235547){const _0x16b266=_0x189033,_0x4682f5=this;_0x4682f5[_0x16b266('0x11ed')]=_0x43b091[_0x16b266('0x20b2')](),_0x4682f5[_0x16b266('0x17f')]=[],_0x4682f5[_0x16b266('0x260a')]=_0x43917f,_0x4682f5['license']=_0x3c97c4,_0x4682f5['crudPermissions']=_0x235547,_0x4682f5[_0x16b266('0x258d')]={},_0x4682f5[_0x16b266('0x19b2')]=_0x4682f5[_0x16b266('0x260a')]&&_0x4682f5['setting'][_0x16b266('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4682f5[_0x16b266('0xf28')]=_0x16b266('0x2319'),_0x4682f5[_0x16b266('0x20a1')]=angular[_0x16b266('0x1a86')](_0x234c73),_0x4682f5[_0x16b266('0xae')]=_0xba9043,_0x4682f5[_0x16b266('0x1d0c')]=![];!_0x4682f5[_0x16b266('0x20a1')]&&(_0x4682f5[_0x16b266('0x20a1')]={'strategy':_0x16b266('0x25ee'),'timeout':0xa},_0x4682f5['title']=_0x16b266('0x208'),_0x4682f5[_0x16b266('0x1d0c')]=!![]);_0x4682f5[_0x16b266('0x1bba')]=_0xd38a2b,_0x4682f5[_0x16b266('0x2333')]=_0x230457,_0x4682f5['deleteOpenchannelQueue']=_0x4be4ab,_0x4682f5[_0x16b266('0x16b3')]=_0x5ad3ea,_0x4682f5[_0x16b266('0xf82')]=_0x2c56ca;function _0xd38a2b(){const _0x28b3bb=_0x16b266;_0x4682f5['errors']=[],_0x1bc08d[_0x28b3bb('0x20a1')][_0x28b3bb('0xb0a')](_0x4682f5[_0x28b3bb('0x20a1')])[_0x28b3bb('0xe53')]['then'](function(_0x6f71a7){const _0x57a184=_0x28b3bb;_0x4682f5[_0x57a184('0xae')][_0x57a184('0x1167')](_0x6f71a7['toJSON']()),_0x2a180c[_0x57a184('0x53')]({'title':_0x57a184('0x20b3'),'msg':_0x4682f5[_0x57a184('0x20a1')][_0x57a184('0x60a')]?_0x4682f5[_0x57a184('0x20a1')][_0x57a184('0x60a')]+_0x57a184('0x14b5'):''}),_0x2c56ca(_0x6f71a7);})['catch'](function(_0x2c2834){const _0x4dc34c=_0x28b3bb;if(_0x2c2834[_0x4dc34c('0x5a5')]&&_0x2c2834['data']['errors']&&_0x2c2834['data']['errors'][_0x4dc34c('0x1564')]){_0x4682f5[_0x4dc34c('0x17f')]=_0x2c2834[_0x4dc34c('0x5a5')][_0x4dc34c('0x17f')]||[{'message':_0x2c2834[_0x4dc34c('0x1ff0')](),'type':_0x4dc34c('0xffa')}];for(let _0x294f17=0x0;_0x294f17<_0x2c2834[_0x4dc34c('0x5a5')][_0x4dc34c('0x17f')][_0x4dc34c('0x1564')];_0x294f17+=0x1){_0x2a180c['error']({'title':_0x2c2834[_0x4dc34c('0x5a5')][_0x4dc34c('0x17f')][_0x294f17][_0x4dc34c('0xcf0')],'msg':_0x2c2834[_0x4dc34c('0x5a5')][_0x4dc34c('0x17f')][_0x294f17][_0x4dc34c('0x8c2')]});}}else _0x2a180c[_0x4dc34c('0x52a')]({'title':_0x2c2834[_0x4dc34c('0x13ee')]?_0x4dc34c('0x2168')+_0x2c2834[_0x4dc34c('0x13ee')]+_0x4dc34c('0xbf6')+_0x2c2834[_0x4dc34c('0x24a9')]:'api.openchannelQueue.save','msg':_0x2c2834['data']?JSON['stringify'](_0x2c2834[_0x4dc34c('0x5a5')][_0x4dc34c('0x8c2')]):_0x2c2834[_0x4dc34c('0x1ff0')]()});});}function _0x230457(){const _0x3c14ae=_0x16b266;_0x4682f5[_0x3c14ae('0x17f')]=[],_0x1bc08d[_0x3c14ae('0x20a1')][_0x3c14ae('0x2480')]({'id':_0x4682f5[_0x3c14ae('0x20a1')]['id']},_0x4682f5['openchannelQueue'])[_0x3c14ae('0xe53')]['then'](function(_0x33b0e9){const _0x210df3=_0x3c14ae,_0x3769b3=_0x2e3ca0()[_0x210df3('0x1c07')](_0x4682f5[_0x210df3('0xae')],{'id':_0x33b0e9['id']});_0x3769b3&&_0x2e3ca0()['merge'](_0x3769b3,_0x2e3ca0()[_0x210df3('0x24d0')](_0x33b0e9[_0x210df3('0x24e1')](),_0x2e3ca0()['keys'](_0x3769b3))),_0x2a180c[_0x210df3('0x53')]({'title':_0x210df3('0xa9f'),'msg':_0x4682f5[_0x210df3('0x20a1')][_0x210df3('0x60a')]?_0x4682f5[_0x210df3('0x20a1')]['name']+_0x210df3('0xf59'):''}),_0x2c56ca(_0x33b0e9);})['catch'](function(_0x3e6392){const _0x3def0b=_0x3c14ae;if(_0x3e6392[_0x3def0b('0x5a5')]&&_0x3e6392[_0x3def0b('0x5a5')][_0x3def0b('0x17f')]&&_0x3e6392['data'][_0x3def0b('0x17f')][_0x3def0b('0x1564')]){_0x4682f5['errors']=_0x3e6392['data']['errors']||[{'message':_0x3e6392[_0x3def0b('0x1ff0')](),'type':_0x3def0b('0xe8b')}];for(let _0x126366=0x0;_0x126366<_0x3e6392[_0x3def0b('0x5a5')][_0x3def0b('0x17f')]['length'];_0x126366++){_0x2a180c[_0x3def0b('0x52a')]({'title':_0x3e6392[_0x3def0b('0x5a5')][_0x3def0b('0x17f')][_0x126366][_0x3def0b('0xcf0')],'msg':_0x3e6392[_0x3def0b('0x5a5')][_0x3def0b('0x17f')][_0x126366][_0x3def0b('0x8c2')]});}}else _0x2a180c[_0x3def0b('0x52a')]({'title':_0x3e6392[_0x3def0b('0x13ee')]?_0x3def0b('0x2168')+_0x3e6392[_0x3def0b('0x13ee')]+_0x3def0b('0xbf6')+_0x3e6392[_0x3def0b('0x24a9')]:_0x3def0b('0xe8b'),'msg':_0x3e6392[_0x3def0b('0x5a5')]?JSON['stringify'](_0x3e6392[_0x3def0b('0x5a5')][_0x3def0b('0x8c2')]):_0x3e6392[_0x3def0b('0x1ff0')]()});});}function _0x4be4ab(_0x4ceb7d){const _0x17127b=_0x16b266;_0x4682f5[_0x17127b('0x17f')]=[];const _0x120069=_0xc88c23[_0x17127b('0x1c6f')]()[_0x17127b('0xf28')]('Are\x20you\x20sure?')['content'](_0x17127b('0x9f8'))[_0x17127b('0x1040')](_0x17127b('0x22a0'))['ok']('Delete')['cancel'](_0x17127b('0x253a'))['targetEvent'](_0x4ceb7d);_0xc88c23[_0x17127b('0x1d4')](_0x120069)[_0x17127b('0x683')](function(){const _0x180082=_0x17127b;_0x1bc08d[_0x180082('0x20a1')][_0x180082('0xd7e')]({'id':_0x4682f5[_0x180082('0x20a1')]['id']})[_0x180082('0xe53')][_0x180082('0x683')](function(){const _0x565a83=_0x180082;_0x2e3ca0()[_0x565a83('0x3ec')](_0x4682f5[_0x565a83('0xae')],{'id':_0x4682f5['openchannelQueue']['id']}),_0x2a180c[_0x565a83('0x53')]({'title':_0x565a83('0x26c'),'msg':(_0x4682f5[_0x565a83('0x20a1')][_0x565a83('0x60a')]||_0x565a83('0x20a1'))+_0x565a83('0x194d')}),_0x2c56ca(_0x4682f5[_0x565a83('0x20a1')]);})[_0x180082('0x130a')](function(_0x337f03){const _0x4f634e=_0x180082;if(_0x337f03[_0x4f634e('0x5a5')]&&_0x337f03['data']['errors']&&_0x337f03[_0x4f634e('0x5a5')]['errors']['length']){_0x4682f5[_0x4f634e('0x17f')]=_0x337f03[_0x4f634e('0x5a5')][_0x4f634e('0x17f')]||[{'message':_0x337f03[_0x4f634e('0x1ff0')](),'type':_0x4f634e('0x237d')}];for(let _0x444b3a=0x0;_0x444b3a<_0x337f03[_0x4f634e('0x5a5')][_0x4f634e('0x17f')][_0x4f634e('0x1564')];_0x444b3a++){_0x2a180c['error']({'title':_0x337f03[_0x4f634e('0x5a5')]['errors'][_0x444b3a][_0x4f634e('0xcf0')],'msg':_0x337f03[_0x4f634e('0x5a5')][_0x4f634e('0x17f')][_0x444b3a]['message']});}}else _0x2a180c['error']({'title':_0x337f03[_0x4f634e('0x13ee')]?_0x4f634e('0x2168')+_0x337f03[_0x4f634e('0x13ee')]+_0x4f634e('0xbf6')+_0x337f03[_0x4f634e('0x24a9')]:_0x4f634e('0x237d'),'msg':_0x337f03[_0x4f634e('0x5a5')]?JSON[_0x4f634e('0x258a')](_0x337f03[_0x4f634e('0x5a5')][_0x4f634e('0x8c2')]):_0x337f03[_0x4f634e('0x8c2')]||_0x337f03['toString']()});});},function(){});}function _0x5ad3ea(_0x30f65d){return _0x30f65d===null?undefined:new Date(_0x30f65d);}function _0x2c56ca(_0x3dfcbd){const _0x3f3e0f=_0x16b266;_0xc88c23[_0x3f3e0f('0x1715')](_0x3dfcbd);}}const _0x1781f9=_0x45852b;_0xb51373[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'api',_0x189033('0x20a1'),_0x189033('0xae'),_0x189033('0x2c9'),'$translate',_0x189033('0xba1'),_0x189033('0x1134')];function _0xb51373(_0xe03310,_0x3dc5bd,_0xe7dbfa,_0x59ec59,_0x4170b1,_0x22f266,_0x5d2b56,_0x42b4a8,_0x68bc39,_0x517f78){const _0x20511e=_0x189033,_0x1eecb7=this;_0x1eecb7['currentUser']=_0x68bc39[_0x20511e('0x20b2')](),_0x1eecb7[_0x20511e('0x20a1')]=_0x4170b1,_0x1eecb7[_0x20511e('0x1134')]=_0x517f78,_0x1eecb7[_0x20511e('0x2c9')]=_0x5d2b56,_0x1eecb7['items']=[],_0x1eecb7[_0x20511e('0x1c47')]=[],_0x1eecb7[_0x20511e('0x1378')]=[],_0x1eecb7[_0x20511e('0x125e')]=[],_0x1eecb7[_0x20511e('0x23a7')]=[],_0x1eecb7['pendingChanges']=![],_0x1eecb7[_0x20511e('0x1dd2')]=_0x46fe8b,_0x1eecb7[_0x20511e('0xa5f')]=_0x3ec023,_0x1eecb7['closeDialog']=_0x275a44,_0x1eecb7[_0x20511e('0x169f')]={'readOnly':!_0x1eecb7[_0x20511e('0x1134')][_0x20511e('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x20511e('0x60a'),'line1':_0x20511e('0x11bc'),'line2':[_0x20511e('0x60a'),'internal'],'line3':'','labelAll':_0x42b4a8[_0x20511e('0x2728')](_0x20511e('0x1db2')),'labelSelected':_0x42b4a8[_0x20511e('0x2728')]('OPENCHANNEL.SELECTED_AGENTS'),'transferCallback':function(){const _0x55d9e=_0x20511e,_0x432e0c=_0x2e3ca0()[_0x55d9e('0x25cb')](_0x1eecb7[_0x55d9e('0x23a7')],_0x1eecb7[_0x55d9e('0x1378')],'id');_0x1eecb7[_0x55d9e('0x2106')]=_0x2e3ca0()[_0x55d9e('0x173f')](_0x432e0c)?![]:!![];}};function _0x46fe8b(){const _0x48a927=_0x20511e;return _0x68bc39[_0x48a927('0xca1')]('admin')?_0x1295d8()['catch'](function(_0x114280){const _0xf521e2=_0x48a927;_0xe7dbfa[_0xf521e2('0x52a')]({'title':_0x114280['status']?'API:'+_0x114280[_0xf521e2('0x13ee')]+'\x20-\x20'+_0x114280['statusText']:_0xf521e2('0x144f'),'msg':_0x114280[_0xf521e2('0x13ee')]?JSON[_0xf521e2('0x258a')](_0x114280[_0xf521e2('0x5a5')]):_0x114280[_0xf521e2('0x1ff0')]()});}):_0x40906a()['then'](function(_0xd0df9a){const _0x344b88=_0x48a927;return _0x1eecb7[_0x344b88('0x1aa')]=_0xd0df9a,_0x1295d8();})[_0x48a927('0x130a')](function(_0x1f603a){const _0x2da008=_0x48a927;_0xe7dbfa[_0x2da008('0x52a')]({'title':_0x1f603a['status']?'API:'+_0x1f603a['status']+_0x2da008('0xbf6')+_0x1f603a['statusText']:_0x2da008('0x144f'),'msg':_0x1f603a[_0x2da008('0x13ee')]?JSON[_0x2da008('0x258a')](_0x1f603a[_0x2da008('0x5a5')]):_0x1f603a[_0x2da008('0x1ff0')]()});});}function _0x40906a(){return _0x3dc5bd(function(_0x1a93ba,_0x5370f3){const _0x41d9f1=a0_0x4e0a;_0x59ec59[_0x41d9f1('0x22df')][_0x41d9f1('0x1e6e')]({'userProfileId':_0x1eecb7['currentUser'][_0x41d9f1('0x2f')],'name':_0x41d9f1('0x1bc0')})[_0x41d9f1('0xe53')][_0x41d9f1('0x683')](function(_0x629f84){const _0xa1c5fa=_0x41d9f1,_0x92f9f9=_0x629f84&&_0x629f84[_0xa1c5fa('0xf5d')]?_0x629f84[_0xa1c5fa('0xf5d')][0x0]:null;_0x1a93ba(_0x92f9f9);})[_0x41d9f1('0x130a')](function(_0x28fc0e){_0x5370f3(_0x28fc0e);});});}function _0x1295d8(){return _0x3dc5bd(function(_0x436a07,_0x166d62){const _0x17edbf=a0_0x4e0a;return _0x4bcb12()[_0x17edbf('0x683')](function(_0x40ba57){const _0x415729=_0x17edbf;return _0x1eecb7[_0x415729('0x1996')]=_0x40ba57[_0x415729('0xf5d')]?_0x40ba57['rows']:[],_0x68bc39[_0x415729('0xca1')](_0x415729('0x20c2'))?_0x40ba57:_0x1eecb7[_0x415729('0x1aa')]?_0x1eecb7[_0x415729('0x1aa')][_0x415729('0x170')]?_0x40ba57:_0x8bb426():null;})['then'](function(_0x40fb6b){const _0x492c65=_0x17edbf,_0x243701=_0x40fb6b&&_0x40fb6b[_0x492c65('0xf5d')]?_0x40fb6b[_0x492c65('0xf5d')]:[];return _0x1eecb7['allowedItems']=_0x2e3ca0()[_0x492c65('0x386')](_0x243701,function(_0x4d5d9d){const _0x416aaa=_0x492c65;return _0x2e3ca0()['find'](_0x1eecb7[_0x416aaa('0x1996')],{'id':_0x68bc39[_0x416aaa('0xca1')](_0x416aaa('0x20c2'))||_0x1eecb7[_0x416aaa('0x1aa')][_0x416aaa('0x170')]?_0x4d5d9d['id']:_0x4d5d9d[_0x416aaa('0x832')]});}),_0x1eecb7[_0x492c65('0x125e')]=angular[_0x492c65('0x1a86')](_0x1eecb7[_0x492c65('0x1c47')]),_0x1eecb7[_0x492c65('0x1996')][_0x492c65('0x1299')](function(_0x2003b7){const _0x472116=_0x492c65,_0x3c39e9=_0x2e3ca0()[_0x472116('0x1c07')](_0x1eecb7[_0x472116('0x1c47')],{'id':_0x2003b7['id']});_0x68bc39[_0x472116('0xca1')](_0x472116('0x20c2'))?_0x2003b7[_0x472116('0x24f4')]=!![]:_0x2003b7[_0x472116('0x24f4')]=typeof _0x3c39e9!=='undefined'?!![]:![];}),_0x11eb18();})['then'](function(_0x1f4e09){const _0x409265=_0x17edbf,_0x1f03ac=_0x1f4e09&&_0x1f4e09[_0x409265('0xf5d')]?_0x1f4e09['rows']:[];_0x1eecb7['selectedItems']=_0x2e3ca0()['map'](_0x1f03ac,function(_0x3aa412){const _0x502f35=_0x409265,_0x2745bb=_0x2e3ca0()[_0x502f35('0x1c07')](_0x1eecb7[_0x502f35('0x1996')],{'id':_0x3aa412['id']});return _0x2745bb['penalty']=_0x3aa412[_0x502f35('0x1dcf')]?'penalty\x20'+_0x3aa412['UserOpenchannelQueue'][_0x502f35('0x1e2a')]:'',_0x2745bb['internal']=typeof _0x3aa412[_0x502f35('0x1d43')]!==_0x502f35('0x1867')?'<'+_0x3aa412['internal']+'>':'',_0x2745bb;}),_0x1eecb7[_0x409265('0x23a7')]=angular[_0x409265('0x1a86')](_0x1eecb7[_0x409265('0x1378')]),_0x1eecb7['dualMultiselectOptions'][_0x409265('0x1378')]=_0x1eecb7['selectedItems'],_0x1eecb7['dualMultiselectOptions']['items']=_0x2e3ca0()[_0x409265('0x461')](_0x1eecb7['allowedItems'],_0x1eecb7['dualMultiselectOptions'][_0x409265('0x1378')],'id'),_0x436a07();})[_0x17edbf('0x130a')](function(_0x562e9b){_0x166d62(_0x562e9b);});});}function _0x8bb426(){return _0x3dc5bd(function(_0x324208,_0xae3da4){const _0x3dd5a5=a0_0x4e0a;return _0x59ec59[_0x3dd5a5('0xcf7')][_0x3dd5a5('0x1e6e')]({'sectionId':_0x1eecb7[_0x3dd5a5('0x1aa')]['id'],'nolimit':!![]})[_0x3dd5a5('0xe53')][_0x3dd5a5('0x683')](function(_0x34417b){_0x324208(_0x34417b);})['catch'](function(_0x2de327){_0xae3da4(_0x2de327);});});}function _0x11eb18(){return _0x3dc5bd(function(_0x4e0130,_0xa4be5a){const _0x48eb71=a0_0x4e0a;return _0x59ec59[_0x48eb71('0x20a1')][_0x48eb71('0x8e7')]({'id':_0x1eecb7['openchannelQueue']['id'],'fields':_0x48eb71('0x72b'),'nolimit':!![],'role':'agent'})[_0x48eb71('0xe53')][_0x48eb71('0x683')](function(_0x10514d){_0x4e0130(_0x10514d);})[_0x48eb71('0x130a')](function(_0x4a1c5f){_0xa4be5a(_0x4a1c5f);});});}function _0x4bcb12(){return _0x3dc5bd(function(_0x515ea6,_0x1dbf08){const _0x38ecba=a0_0x4e0a;return _0x59ec59[_0x38ecba('0xc96')][_0x38ecba('0x1e6e')]({'fields':_0x38ecba('0x72b'),'nolimit':!![],'role':_0x38ecba('0x2327')})[_0x38ecba('0xe53')][_0x38ecba('0x683')](function(_0x2e89fb){_0x515ea6(_0x2e89fb);})[_0x38ecba('0x130a')](function(_0x1cf1ba){_0x1dbf08(_0x1cf1ba);});});}function _0x46b7bb(_0x469af3){return _0x3dc5bd(function(_0x339a8b,_0x404ccf){const _0x357189=a0_0x4e0a;_0x2e3ca0()[_0x357189('0x173f')](_0x469af3)?_0x339a8b():_0x59ec59['openchannelQueue'][_0x357189('0x2179')]({'id':_0x1eecb7[_0x357189('0x20a1')]['id'],'ids':_0x2e3ca0()[_0x357189('0x386')](_0x469af3,'id')})[_0x357189('0xe53')][_0x357189('0x683')](function(){_0x339a8b();})[_0x357189('0x130a')](function(_0x47cc31){_0x404ccf(_0x47cc31);});});}function _0x2f3d25(_0x570f30){return _0x3dc5bd(function(_0x36b130,_0x44be6a){const _0x56814e=a0_0x4e0a;_0x2e3ca0()[_0x56814e('0x173f')](_0x570f30)?_0x36b130():_0x59ec59[_0x56814e('0x20a1')]['removeAgents']({'id':_0x1eecb7[_0x56814e('0x20a1')]['id'],'ids':_0x2e3ca0()[_0x56814e('0x386')](_0x570f30,'id')})[_0x56814e('0xe53')][_0x56814e('0x683')](function(){_0x36b130();})[_0x56814e('0x130a')](function(_0x146e11){_0x44be6a(_0x146e11);});});}function _0x3ec023(){const _0x3c1d5f=_0x20511e,_0x24afc6=_0x2e3ca0()[_0x3c1d5f('0x461')](_0x1eecb7[_0x3c1d5f('0x23a7')],_0x1eecb7[_0x3c1d5f('0x1378')],'id'),_0xbdddc1=_0x2e3ca0()['differenceBy'](_0x1eecb7[_0x3c1d5f('0x1378')],_0x1eecb7[_0x3c1d5f('0x23a7')],'id');return _0x2f3d25(_0x24afc6)[_0x3c1d5f('0x683')](function(){return _0x46b7bb(_0xbdddc1);})[_0x3c1d5f('0x683')](function(){const _0x45087e=_0x3c1d5f;_0x1eecb7[_0x45087e('0x2106')]=![],_0x1eecb7[_0x45087e('0x125e')]=angular[_0x45087e('0x1a86')](_0x1eecb7[_0x45087e('0x1c47')]),_0x1eecb7[_0x45087e('0x23a7')]=angular[_0x45087e('0x1a86')](_0x1eecb7[_0x45087e('0x1378')]),_0xe7dbfa[_0x45087e('0x53')]({'title':_0x45087e('0xd28'),'msg':_0x45087e('0x89d')});})[_0x3c1d5f('0x130a')](function(_0x274044){const _0x41d2f3=_0x3c1d5f;_0xe7dbfa[_0x41d2f3('0x52a')]({'title':_0x274044[_0x41d2f3('0x13ee')]?_0x41d2f3('0x2168')+_0x274044[_0x41d2f3('0x13ee')]+_0x41d2f3('0xbf6')+_0x274044['statusText']:_0x41d2f3('0x1b71'),'msg':_0x274044['status']?JSON[_0x41d2f3('0x258a')](_0x274044[_0x41d2f3('0x5a5')]):_0x274044[_0x41d2f3('0x1ff0')]()});});}function _0x275a44(){_0xe03310['hide']();}}const _0x42081d=_0xb51373;_0xe8be57[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x20a1'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0xe8be57(_0x1501c3,_0x2a1707,_0x20299a,_0xfff521,_0x5dba36,_0x5cd5b1,_0x2dabcd,_0x4b39b2){const _0x5f1427=_0x189033,_0xa6f2c=this;_0xa6f2c[_0x5f1427('0x11ed')]=_0x2dabcd['getCurrentUser'](),_0xa6f2c[_0x5f1427('0x20a1')]=_0x5dba36,_0xa6f2c['crudPermissions']=_0x4b39b2,_0xa6f2c[_0x5f1427('0x1996')]=[],_0xa6f2c[_0x5f1427('0x1c47')]=[],_0xa6f2c[_0x5f1427('0x1378')]=[],_0xa6f2c['startingAllowedItems']=[],_0xa6f2c[_0x5f1427('0x23a7')]=[],_0xa6f2c[_0x5f1427('0x2106')]=![],_0xa6f2c[_0x5f1427('0x169f')]={'readOnly':!_0xa6f2c[_0x5f1427('0x1134')][_0x5f1427('0x1978')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x5f1427('0x60a'),'line1':_0x5f1427('0x60a'),'line2':'','line3':'','labelAll':_0x5cd5b1[_0x5f1427('0x2728')](_0x5f1427('0x1e69')),'labelSelected':_0x5cd5b1['instant']('OPENCHANNEL.SELECTED_TEAMS'),'transferCallback':function(){const _0x1081dc=_0x5f1427,_0x16915d=_0x2e3ca0()[_0x1081dc('0x25cb')](_0xa6f2c[_0x1081dc('0x23a7')],_0xa6f2c[_0x1081dc('0x1378')],'id');_0xa6f2c[_0x1081dc('0x2106')]=_0x2e3ca0()[_0x1081dc('0x173f')](_0x16915d)?![]:!![];}},_0xa6f2c[_0x5f1427('0x1dd2')]=_0x113d14,_0xa6f2c[_0x5f1427('0x1a89')]=_0x576980,_0xa6f2c[_0x5f1427('0xf82')]=_0x5de9e5;function _0x113d14(){const _0x40cb73=_0x5f1427;return _0x2dabcd[_0x40cb73('0xca1')](_0x40cb73('0x20c2'))?_0x382563()['catch'](function(_0x2f592d){const _0x331a71=_0x40cb73;_0x20299a[_0x331a71('0x52a')]({'title':_0x2f592d[_0x331a71('0x13ee')]?_0x331a71('0x2168')+_0x2f592d['status']+_0x331a71('0xbf6')+_0x2f592d[_0x331a71('0x24a9')]:_0x331a71('0x1820'),'msg':_0x2f592d[_0x331a71('0x13ee')]?JSON[_0x331a71('0x258a')](_0x2f592d[_0x331a71('0x5a5')]):_0x2f592d[_0x331a71('0x1ff0')]()});}):_0x1a23ad()['then'](function(_0x1db3fd){return _0xa6f2c['section']=_0x1db3fd,_0x382563();})[_0x40cb73('0x130a')](function(_0x345a89){const _0x43a841=_0x40cb73;_0x20299a[_0x43a841('0x52a')]({'title':_0x345a89[_0x43a841('0x13ee')]?_0x43a841('0x2168')+_0x345a89[_0x43a841('0x13ee')]+_0x43a841('0xbf6')+_0x345a89[_0x43a841('0x24a9')]:'SYSTEM:GET_TEAMS','msg':_0x345a89[_0x43a841('0x13ee')]?JSON[_0x43a841('0x258a')](_0x345a89['data']):_0x345a89[_0x43a841('0x1ff0')]()});});}function _0x1a23ad(){return _0x2a1707(function(_0x2b2582,_0x5ede1c){const _0x5b45ad=a0_0x4e0a;_0xfff521[_0x5b45ad('0x22df')][_0x5b45ad('0x1e6e')]({'userProfileId':_0xa6f2c[_0x5b45ad('0x11ed')]['userProfileId'],'name':_0x5b45ad('0x15bc')})[_0x5b45ad('0xe53')][_0x5b45ad('0x683')](function(_0x1f2574){const _0x5e60cf=_0x5b45ad,_0x199ae0=_0x1f2574&&_0x1f2574['rows']?_0x1f2574[_0x5e60cf('0xf5d')][0x0]:null;_0x2b2582(_0x199ae0);})[_0x5b45ad('0x130a')](function(_0x3f0361){_0x5ede1c(_0x3f0361);});});}function _0x382563(){return _0x2a1707(function(_0x25f62e,_0x5c5f89){const _0x268d3f=a0_0x4e0a;return _0xf37d03()['then'](function(_0x3de903){const _0x3afd65=a0_0x4e0a;return _0xa6f2c[_0x3afd65('0x1996')]=_0x3de903[_0x3afd65('0xf5d')]?_0x3de903[_0x3afd65('0xf5d')]:[],_0x2dabcd[_0x3afd65('0xca1')]('admin')?_0x3de903:_0xa6f2c['section']?_0xa6f2c[_0x3afd65('0x1aa')][_0x3afd65('0x170')]?_0x3de903:_0xfccffb():null;})[_0x268d3f('0x683')](function(_0x3f01c2){const _0x42c82a=_0x268d3f,_0x35df97=_0x3f01c2&&_0x3f01c2[_0x42c82a('0xf5d')]?_0x3f01c2['rows']:[];return _0xa6f2c['allowedItems']=_0x2e3ca0()['map'](_0x35df97,function(_0x15f313){const _0x2a6d79=_0x42c82a;return _0x2e3ca0()[_0x2a6d79('0x1c07')](_0xa6f2c[_0x2a6d79('0x1996')],{'id':_0x2dabcd[_0x2a6d79('0xca1')](_0x2a6d79('0x20c2'))||_0xa6f2c['section'][_0x2a6d79('0x170')]?_0x15f313['id']:_0x15f313[_0x2a6d79('0x832')]});}),_0xa6f2c[_0x42c82a('0x1996')][_0x42c82a('0x1299')](function(_0x3dfa3c){const _0x34bade=_0x42c82a,_0x4eb256=_0x2e3ca0()[_0x34bade('0x1c07')](_0xa6f2c['allowedItems'],{'id':_0x3dfa3c['id']});_0x2dabcd[_0x34bade('0xca1')](_0x34bade('0x20c2'))?_0x3dfa3c[_0x34bade('0x24f4')]=!![]:_0x3dfa3c[_0x34bade('0x24f4')]=typeof _0x4eb256!==_0x34bade('0x1867')?!![]:![];}),_0x57c87f();})[_0x268d3f('0x683')](function(_0x455a6a){const _0xf84317=_0x268d3f,_0x52d56e=_0x455a6a&&_0x455a6a['rows']?_0x455a6a['rows']:[];_0xa6f2c['selectedItems']=_0x2e3ca0()[_0xf84317('0x386')](_0x52d56e,function(_0xf53487){const _0x4c3805=_0xf84317;return _0x2e3ca0()['find'](_0xa6f2c[_0x4c3805('0x1996')],{'id':_0xf53487['id']});}),_0xa6f2c[_0xf84317('0x23a7')]=angular[_0xf84317('0x1a86')](_0xa6f2c[_0xf84317('0x1378')]),_0xa6f2c['dualMultiselectOptions'][_0xf84317('0x1378')]=_0xa6f2c[_0xf84317('0x1378')],_0xa6f2c[_0xf84317('0x169f')][_0xf84317('0x1996')]=_0x2e3ca0()[_0xf84317('0x461')](_0xa6f2c[_0xf84317('0x1c47')],_0xa6f2c[_0xf84317('0x169f')][_0xf84317('0x1378')],'id'),_0x25f62e();})[_0x268d3f('0x130a')](function(_0x42fb3e){_0x5c5f89(_0x42fb3e);});});}function _0xfccffb(){return _0x2a1707(function(_0x48fa64,_0x2e55bf){const _0x392502=a0_0x4e0a;return _0xfff521[_0x392502('0xcf7')][_0x392502('0x1e6e')]({'sectionId':_0xa6f2c['section']['id'],'nolimit':!![]})[_0x392502('0xe53')]['then'](function(_0x34f692){_0x48fa64(_0x34f692);})[_0x392502('0x130a')](function(_0x33a024){_0x2e55bf(_0x33a024);});});}function _0x57c87f(){return _0x2a1707(function(_0x1b090b,_0x3432bc){const _0x5c0c65=a0_0x4e0a;return _0xfff521[_0x5c0c65('0x20a1')]['getTeams']({'id':_0xa6f2c[_0x5c0c65('0x20a1')]['id'],'fields':_0x5c0c65('0xa10'),'nolimit':!![]})[_0x5c0c65('0xe53')][_0x5c0c65('0x683')](function(_0x1653fb){_0x1b090b(_0x1653fb);})['catch'](function(_0x2a2955){_0x3432bc(_0x2a2955);});});}function _0xf37d03(){return _0x2a1707(function(_0x29381d,_0x43981f){const _0x2a341c=a0_0x4e0a;return _0xfff521[_0x2a341c('0xd88')][_0x2a341c('0x1e6e')]({'fields':_0x2a341c('0xa10'),'nolimit':!![]})[_0x2a341c('0xe53')][_0x2a341c('0x683')](function(_0x583846){_0x29381d(_0x583846);})[_0x2a341c('0x130a')](function(_0x4e055b){_0x43981f(_0x4e055b);});});}function _0x2578e4(_0x5c4911){return _0x2a1707(function(_0x5ccfe1,_0x3e8983){const _0x279b42=a0_0x4e0a;_0x2e3ca0()['isEmpty'](_0x5c4911)?_0x5ccfe1():_0xfff521[_0x279b42('0x20a1')][_0x279b42('0x1558')]({'id':_0xa6f2c['openchannelQueue']['id'],'ids':_0x2e3ca0()[_0x279b42('0x386')](_0x5c4911,'id')})[_0x279b42('0xe53')]['then'](function(){_0x5ccfe1();})[_0x279b42('0x130a')](function(_0x7e815f){_0x3e8983(_0x7e815f);});});}function _0x2f49c0(_0x154e1a){return _0x2a1707(function(_0x324d30,_0x3e9a58){const _0x26a8f5=a0_0x4e0a;_0x2e3ca0()[_0x26a8f5('0x173f')](_0x154e1a)?_0x324d30():_0xfff521[_0x26a8f5('0x20a1')][_0x26a8f5('0x2521')]({'id':_0xa6f2c[_0x26a8f5('0x20a1')]['id'],'ids':_0x2e3ca0()['map'](_0x154e1a,'id')})[_0x26a8f5('0xe53')]['then'](function(){_0x324d30();})[_0x26a8f5('0x130a')](function(_0x52d3cf){_0x3e9a58(_0x52d3cf);});});}function _0x576980(){const _0x531208=_0x5f1427,_0x5d0df5=_0x2e3ca0()['differenceBy'](_0xa6f2c[_0x531208('0x23a7')],_0xa6f2c[_0x531208('0x1378')],'id'),_0x1bdceb=_0x2e3ca0()['differenceBy'](_0xa6f2c[_0x531208('0x1378')],_0xa6f2c[_0x531208('0x23a7')],'id');return _0x2f49c0(_0x5d0df5)[_0x531208('0x683')](function(){return _0x2578e4(_0x1bdceb);})[_0x531208('0x683')](function(){const _0x267e9f=_0x531208;_0xa6f2c[_0x267e9f('0x2106')]=![],_0xa6f2c[_0x267e9f('0x125e')]=angular[_0x267e9f('0x1a86')](_0xa6f2c[_0x267e9f('0x1c47')]),_0xa6f2c[_0x267e9f('0x23a7')]=angular[_0x267e9f('0x1a86')](_0xa6f2c[_0x267e9f('0x1378')]),_0x20299a['success']({'title':_0x267e9f('0xd28'),'msg':'Teams\x20association\x20has\x20been\x20updated!'});})[_0x531208('0x130a')](function(_0x5d8a8d){const _0x5a209b=_0x531208;_0x20299a[_0x5a209b('0x52a')]({'title':_0x5d8a8d[_0x5a209b('0x13ee')]?_0x5a209b('0x2168')+_0x5d8a8d['status']+_0x5a209b('0xbf6')+_0x5d8a8d[_0x5a209b('0x24a9')]:_0x5a209b('0x1b71'),'msg':_0x5d8a8d['status']?JSON[_0x5a209b('0x258a')](_0x5d8a8d[_0x5a209b('0x5a5')]):_0x5d8a8d[_0x5a209b('0x1ff0')]()});});}function _0x5de9e5(){_0x1501c3['hide']();}}const _0x3eae92=_0xe8be57,_0x532502=_0x180212['p']+_0x189033('0x1a91');_0x57d0d9[_0x189033('0x14be')]=[_0x189033('0x938'),'$location','$mdDialog',_0x189033('0x16ea'),'$translate','license',_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x20a1'),'userProfileSection'];function _0x57d0d9(_0x201251,_0x7ca5bc,_0x5a8a05,_0x1e4529,_0x5bfdf3,_0x44e9a0,_0x42cfe4,_0x15415f,_0xf7327f,_0x57525b,_0x1d85c2,_0x478caa){const _0x2e5c7f=_0x189033,_0x47a0a9=this;_0x47a0a9['currentUser']=_0x57525b['getCurrentUser'](),_0x47a0a9[_0x2e5c7f('0xace')]=_0x44e9a0,_0x47a0a9['setting']=_0x42cfe4,_0x47a0a9[_0x2e5c7f('0x19b2')]=_0x47a0a9[_0x2e5c7f('0x260a')][_0x2e5c7f('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x47a0a9[_0x2e5c7f('0x1224')]=_0x7ca5bc[_0x2e5c7f('0x173e')]()+_0x2e5c7f('0x20de')+_0x7ca5bc['host'](),_0x47a0a9[_0x2e5c7f('0x20a1')]=_0x1d85c2||_0x201251[_0x2e5c7f('0x7f2')][_0x2e5c7f('0x20a1')]||{},_0x47a0a9[_0x2e5c7f('0x22df')]=_0x478caa&&_0x478caa[_0x2e5c7f('0x50d')]==0x1?_0x478caa[_0x2e5c7f('0xf5d')][0x0]:null,_0x47a0a9[_0x2e5c7f('0x1134')]=_0x57525b[_0x2e5c7f('0x142a')](_0x47a0a9[_0x2e5c7f('0x22df')]?_0x47a0a9[_0x2e5c7f('0x22df')]['crudPermissions']:null),_0x47a0a9[_0x2e5c7f('0x258d')]={},_0x47a0a9['selectedTab']=_0x201251[_0x2e5c7f('0x7f2')][_0x2e5c7f('0x1904')]||0x0,_0x47a0a9[_0x2e5c7f('0xe0e')]=_0x288d5e,_0x47a0a9[_0x2e5c7f('0x2814')]=_0x5a24f9,_0x47a0a9[_0x2e5c7f('0x2430')]=_0xf7327f[_0x2e5c7f('0x2289')],_0x47a0a9[_0x2e5c7f('0x2105')]=_0x3bf129,_0x47a0a9[_0x2e5c7f('0x2333')]=_0x1868b2;function _0x288d5e(_0x24459d,_0x691d34){const _0x1d13c3=_0x2e5c7f;_0x5a8a05['show']({'controller':'OpenchannelQueueteamaddController','controllerAs':'vm','templateUrl':_0x532502,'parent':angular[_0x1d13c3('0x1fcc')](_0x1e4529['body']),'targetEvent':_0x691d34,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x24459d,'openchannelQueues':_0x47a0a9['openchannelQueues']?_0x47a0a9['openchannelQueues'][_0x1d13c3('0xf5d')]:[],'crudPermissions':_0x47a0a9[_0x1d13c3('0x1134')]}});}function _0x5a24f9(_0x3bf012,_0x2911a7){const _0x4823b1=_0x2e5c7f;_0x5a8a05['show']({'controller':_0x4823b1('0x116d'),'controllerAs':'vm','templateUrl':_0x11f391,'parent':angular[_0x4823b1('0x1fcc')](_0x1e4529['body']),'targetEvent':_0x2911a7,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x3bf012,'openchannelQueues':_0x47a0a9[_0x4823b1('0xae')]?_0x47a0a9[_0x4823b1('0xae')][_0x4823b1('0xf5d')]:[],'crudPermissions':_0x47a0a9[_0x4823b1('0x1134')],'realtime':![]}});}function _0x3bf129(){const _0xa2907a=_0x2e5c7f;_0x201251['go'](_0xa2907a('0x2200'),{},{'reload':'app.openchannel.openchannelQueues'});}function _0x1868b2(){const _0x5ea3b7=_0x2e5c7f;_0x15415f[_0x5ea3b7('0x20a1')][_0x5ea3b7('0x2480')]({'id':_0x47a0a9[_0x5ea3b7('0x20a1')]['id']},_0x47a0a9['openchannelQueue'])[_0x5ea3b7('0xe53')][_0x5ea3b7('0x683')](function(){const _0x3c6a3b=_0x5ea3b7;_0xf7327f[_0x3c6a3b('0x53')]({'title':_0x3c6a3b('0x2151'),'msg':_0x47a0a9[_0x3c6a3b('0x20a1')][_0x3c6a3b('0x60a')]?_0x47a0a9[_0x3c6a3b('0x20a1')][_0x3c6a3b('0x60a')]+'\x20has\x20been\x20updated!':''});})[_0x5ea3b7('0x130a')](function(_0x418241){const _0x514b4e=_0x5ea3b7;_0xf7327f[_0x514b4e('0x52a')]({'title':_0x418241[_0x514b4e('0x13ee')]?_0x514b4e('0x2168')+_0x418241['status']+_0x514b4e('0xbf6')+_0x418241[_0x514b4e('0x24a9')]:_0x514b4e('0x1e40'),'msg':_0x418241['data']?JSON[_0x514b4e('0x258a')](_0x418241[_0x514b4e('0x5a5')]):_0x418241[_0x514b4e('0x1ff0')]()});});}}const _0x523085=_0x57d0d9;_0x902436[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),'openchannelQueues',_0x189033('0x2a'),_0x189033('0x22df'),'api',_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),'setting'];function _0x902436(_0xd86935,_0x500c3d,_0x37f542,_0x5dc850,_0x5198fb,_0x550c24,_0x5df4a0,_0x2f76c3,_0x1e17ed,_0x21e7c2,_0x3c2cf2,_0x128473,_0x21f10,_0x2d1017,_0x42d36e,_0x56c186,_0x1c688b){const _0x7a1113=_0x189033,_0x43e5dc=this;_0x43e5dc[_0x7a1113('0xace')]=_0x56c186,_0x43e5dc[_0x7a1113('0x260a')]=_0x1c688b,_0x43e5dc['currentUser']=_0x42d36e[_0x7a1113('0x20b2')](),_0x43e5dc[_0x7a1113('0xae')]=_0x1e17ed||{'count':0x0,'rows':[]},_0x43e5dc[_0x7a1113('0x2a')]=_0x21e7c2,_0x43e5dc['userProfileSection']=_0x3c2cf2&&_0x3c2cf2[_0x7a1113('0x50d')]==0x1?_0x3c2cf2[_0x7a1113('0xf5d')][0x0]:null,_0x43e5dc[_0x7a1113('0x1134')]=_0x42d36e[_0x7a1113('0x142a')](_0x43e5dc['userProfileSection']?_0x43e5dc[_0x7a1113('0x22df')][_0x7a1113('0x1134')]:null),_0x43e5dc['table']='openchannelQueues',_0x43e5dc[_0x7a1113('0x247')]='',_0x43e5dc[_0x7a1113('0x1ce2')]=null,_0x43e5dc[_0x7a1113('0x2122')]=[],_0x43e5dc[_0x7a1113('0x23a2')]={'fields':_0x7a1113('0x1b67'),'sort':_0x7a1113('0xc36'),'channel':_0x7a1113('0x1261'),'limit':0xa,'page':0x1},_0x43e5dc['arraystrategy']=_0x2e3ca0()[_0x7a1113('0x24db')]([{'option':'Beepall','value':_0x7a1113('0x185b')},{'option':_0x7a1113('0x15cd'),'value':'\x27rrmemory\x27'}],function(_0x1f416b){const _0x527bc1=_0x7a1113;return _0x2e3ca0()['replace'](_0x1f416b[_0x527bc1('0x1c6b')],new RegExp('\x27','g'),'');}),_0x43e5dc[_0x7a1113('0xc63')]=_0x2e76fe,_0x43e5dc[_0x7a1113('0xe0e')]=_0x4c9866,_0x43e5dc[_0x7a1113('0x2814')]=_0x29b4fd,_0x43e5dc[_0x7a1113('0x194f')]=_0x1f7d02,_0x43e5dc[_0x7a1113('0x213c')]=_0x551163,_0x43e5dc[_0x7a1113('0x53')]=_0x9fdd66,_0x43e5dc[_0x7a1113('0x2759')]=_0x2d352c,_0x43e5dc['createOrEditOpenchannelQueue']=_0x258a20,_0x43e5dc['deleteOpenchannelQueue']=_0x1b1082,_0x43e5dc['exportSelectedOpenchannelQueues']=_0x2cf1d4,_0x43e5dc[_0x7a1113('0x2568')]=_0x4c58c8,_0x43e5dc['deselectOpenchannelQueues']=_0x2205fb,_0x43e5dc[_0x7a1113('0x265e')]=_0x59fc98;function _0x2e76fe(_0x439322){const _0x7570b8=_0x7a1113;_0x37f542['go'](_0x7570b8('0x25c0'),{'id':_0x439322['id'],'openchannelQueue':_0x439322,'crudPermissions':_0x43e5dc['crudPermissions']});}function _0x4c9866(_0x54cc5d,_0x4b7b46){const _0x1ba14d=_0x7a1113;_0x5198fb[_0x1ba14d('0x1d4')]({'controller':_0x1ba14d('0x205b'),'controllerAs':'vm','templateUrl':_0x532502,'parent':angular['element'](_0x550c24[_0x1ba14d('0x18e5')]),'targetEvent':_0x4b7b46,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x54cc5d,'openchannelQueues':_0x43e5dc['openchannelQueues']?_0x43e5dc[_0x1ba14d('0xae')][_0x1ba14d('0xf5d')]:[],'crudPermissions':_0x43e5dc['crudPermissions']}});}function _0x29b4fd(_0x20b02b,_0x12601c){const _0xadf6b3=_0x7a1113;_0x5198fb[_0xadf6b3('0x1d4')]({'controller':_0xadf6b3('0x116d'),'controllerAs':'vm','templateUrl':_0x11f391,'parent':angular[_0xadf6b3('0x1fcc')](_0x550c24[_0xadf6b3('0x18e5')]),'targetEvent':_0x12601c,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x20b02b,'openchannelQueues':_0x43e5dc[_0xadf6b3('0xae')]?_0x43e5dc['openchannelQueues']['rows']:[],'crudPermissions':_0x43e5dc[_0xadf6b3('0x1134')],'realtime':![]}});}function _0x1f7d02(_0x4f5163,_0x51361c){const _0x9b0e24=_0x7a1113,_0x26f1cc=_0x5198fb[_0x9b0e24('0x1c6f')]()['title'](_0x9b0e24('0x1b01')+_0x2e3ca0()[_0x9b0e24('0x1e03')](_0x9b0e24('0x20a1'))+'?')[_0x9b0e24('0x26e3')](''+(_0x4f5163[_0x9b0e24('0x60a')]||_0x9b0e24('0x20a1'))+''+_0x9b0e24('0x1ee7'))[_0x9b0e24('0x1040')]('delete\x20openchannelQueue')[_0x9b0e24('0xe42')](_0x51361c)['ok']('OK')[_0x9b0e24('0x19fb')](_0x9b0e24('0x16b8'));_0x5198fb[_0x9b0e24('0x1d4')](_0x26f1cc)[_0x9b0e24('0x683')](function(){_0x1b1082(_0x4f5163);},function(){const _0xe67907=_0x9b0e24;console[_0xe67907('0x1b2b')](_0xe67907('0x16b8'));});}function _0x551163(){const _0x33ae9a=_0x7a1113;if(_0x42d36e[_0x33ae9a('0xca1')]('admin'))_0x37f542['go'](_0x33ae9a('0x21d8'),{});else return _0x128473[_0x33ae9a('0x22df')][_0x33ae9a('0x1e6e')]({'userProfileId':_0x42d36e[_0x33ae9a('0x20b2')]()[_0x33ae9a('0x2f')],'sectionId':0x32a})[_0x33ae9a('0xe53')][_0x33ae9a('0x683')](function(_0x2ebb72){const _0x4e2eb3=_0x33ae9a,_0x48b977=_0x2ebb72&&_0x2ebb72[_0x4e2eb3('0xf5d')]?_0x2ebb72[_0x4e2eb3('0xf5d')][0x0]:null;_0x48b977&&_0x48b977[_0x4e2eb3('0x1333')]?_0x37f542['go'](_0x4e2eb3('0x21d8'),{}):_0x2d1017[_0x4e2eb3('0x2289')]({'title':_0x2f76c3['instant'](_0x4e2eb3('0x213e')),'msg':_0x2f76c3[_0x4e2eb3('0x2728')](_0x4e2eb3('0xdba'))});})['catch'](function(_0x34dde9){const _0x66fe21=_0x33ae9a;_0x2d1017[_0x66fe21('0x52a')]({'title':_0x34dde9[_0x66fe21('0x13ee')]?_0x66fe21('0x2168')+_0x34dde9[_0x66fe21('0x13ee')]+'\x20-\x20'+_0x34dde9[_0x66fe21('0x24a9')]:_0x66fe21('0xf2a'),'msg':_0x34dde9['status']?JSON[_0x66fe21('0x258a')](_0x34dde9[_0x66fe21('0x5a5')]):_0x34dde9[_0x66fe21('0x1ff0')]()});});}let _0x939077=!![],_0x304066=0x1;_0xd86935[_0x7a1113('0x186d')]('vm.query.filter',function(_0x48a61b,_0x1d7c04){const _0x19ad0b=_0x7a1113;_0x939077?_0x5df4a0(function(){_0x939077=![];}):(!_0x1d7c04&&(_0x304066=_0x43e5dc[_0x19ad0b('0x23a2')][_0x19ad0b('0xdf8')]),_0x48a61b!==_0x1d7c04&&(_0x43e5dc[_0x19ad0b('0x23a2')][_0x19ad0b('0xdf8')]=0x1),!_0x48a61b&&(_0x43e5dc['query'][_0x19ad0b('0xdf8')]=_0x304066),_0x43e5dc[_0x19ad0b('0x2759')]());});function _0x9fdd66(_0x26381c){const _0x5738c5=_0x7a1113;_0x43e5dc[_0x5738c5('0xae')]=_0x26381c||{'count':0x0,'rows':[]};}function _0x2d352c(){const _0x32fb0c=_0x7a1113;_0x43e5dc[_0x32fb0c('0x23a2')][_0x32fb0c('0x1cc8')]=(_0x43e5dc['query']['page']-0x1)*_0x43e5dc[_0x32fb0c('0x23a2')][_0x32fb0c('0x6f0')],_0x42d36e['hasRole'](_0x32fb0c('0x20c2'))?_0x43e5dc['promise']=_0x128473[_0x32fb0c('0x20a1')]['get'](_0x43e5dc[_0x32fb0c('0x23a2')],_0x9fdd66)[_0x32fb0c('0xe53')]:(_0x43e5dc['query']['id']=_0x43e5dc['userProfile']['id'],_0x43e5dc['query']['section']=_0x32fb0c('0x3da'),_0x43e5dc[_0x32fb0c('0x1883')]=_0x128473['userProfile'][_0x32fb0c('0x241d')](_0x43e5dc[_0x32fb0c('0x23a2')],_0x9fdd66)[_0x32fb0c('0xe53')]);}function _0x258a20(_0x1f194a,_0x4f419c){const _0x1544f9=_0x7a1113;_0x5198fb[_0x1544f9('0x1d4')]({'controller':_0x1544f9('0x263d'),'controllerAs':'vm','templateUrl':_0x281833,'parent':angular[_0x1544f9('0x1fcc')](_0x550c24[_0x1544f9('0x18e5')]),'targetEvent':_0x1f194a,'clickOutsideToClose':!![],'locals':{'openchannelQueue':_0x4f419c,'openchannelQueues':_0x43e5dc[_0x1544f9('0xae')]['rows'],'license':_0x43e5dc[_0x1544f9('0xace')],'setting':_0x43e5dc[_0x1544f9('0x260a')],'crudPermissions':_0x43e5dc[_0x1544f9('0x1134')]}});}function _0x1b1082(_0x3c2d6d){const _0x1e9995=_0x7a1113;_0x128473[_0x1e9995('0x20a1')]['delete']({'id':_0x3c2d6d['id']})['$promise'][_0x1e9995('0x683')](function(){const _0x29e6f7=_0x1e9995;_0x2e3ca0()[_0x29e6f7('0x3ec')](_0x43e5dc[_0x29e6f7('0xae')][_0x29e6f7('0xf5d')],{'id':_0x3c2d6d['id']}),_0x43e5dc[_0x29e6f7('0xae')]['count']-=0x1,!_0x43e5dc['openchannelQueues']['rows']['length']&&_0x43e5dc[_0x29e6f7('0x2759')](),_0x2d1017['success']({'title':_0x2e3ca0()[_0x29e6f7('0x1e03')]('OpenchannelQueue')+_0x29e6f7('0xbfc'),'msg':_0x3c2d6d[_0x29e6f7('0x60a')]?_0x3c2d6d[_0x29e6f7('0x60a')]+_0x29e6f7('0x194d'):''});})[_0x1e9995('0x130a')](function(_0xe08ff4){const _0x2ca572=_0x1e9995;if(_0xe08ff4[_0x2ca572('0x5a5')]&&_0xe08ff4[_0x2ca572('0x5a5')]['errors']&&_0xe08ff4[_0x2ca572('0x5a5')]['errors'][_0x2ca572('0x1564')]){_0x43e5dc['errors']=_0xe08ff4[_0x2ca572('0x5a5')][_0x2ca572('0x17f')]||[{'message':_0xe08ff4[_0x2ca572('0x1ff0')](),'type':_0x2ca572('0x1be7')}];for(let _0x1dba95=0x0;_0x1dba95<_0xe08ff4[_0x2ca572('0x5a5')][_0x2ca572('0x17f')][_0x2ca572('0x1564')];_0x1dba95++){_0x2d1017[_0x2ca572('0x52a')]({'title':_0xe08ff4[_0x2ca572('0x5a5')][_0x2ca572('0x17f')][_0x1dba95]['type'],'msg':_0xe08ff4[_0x2ca572('0x5a5')][_0x2ca572('0x17f')][_0x1dba95]['message']});}}else _0x2d1017[_0x2ca572('0x52a')]({'title':_0xe08ff4['status']?_0x2ca572('0x2168')+_0xe08ff4[_0x2ca572('0x13ee')]+'\x20-\x20'+_0xe08ff4[_0x2ca572('0x24a9')]:_0x2ca572('0x1be7'),'msg':_0xe08ff4['data']?JSON[_0x2ca572('0x258a')](_0xe08ff4['data'][_0x2ca572('0x8c2')]):_0xe08ff4['message']||_0xe08ff4[_0x2ca572('0x1ff0')]()});});}function _0x2cf1d4(){const _0x392f1d=_0x7a1113,_0x57e5c3=angular[_0x392f1d('0x1a86')](_0x43e5dc[_0x392f1d('0x2122')]);return _0x43e5dc[_0x392f1d('0x2122')]=[],_0x57e5c3;}function _0x4c58c8(_0x15cca8){const _0x529bcd=_0x7a1113,_0x9fc379=_0x5198fb[_0x529bcd('0x1c6f')]()[_0x529bcd('0xf28')](_0x529bcd('0x528'))[_0x529bcd('0x26e3')](_0x529bcd('0xed5')+_0x43e5dc[_0x529bcd('0x2122')][_0x529bcd('0x1564')]+_0x529bcd('0x93c')+'\x20will\x20be\x20deleted.')[_0x529bcd('0x1040')](_0x529bcd('0x324'))[_0x529bcd('0xe42')](_0x15cca8)['ok']('OK')[_0x529bcd('0x19fb')]('CANCEL');_0x5198fb[_0x529bcd('0x1d4')](_0x9fc379)[_0x529bcd('0x683')](function(){const _0x5b5e36=_0x529bcd;_0x43e5dc['selectedOpenchannelQueues']['forEach'](function(_0x3d4604){_0x1b1082(_0x3d4604);}),_0x43e5dc[_0x5b5e36('0x2122')]=[];});}function _0x2205fb(){const _0x4d8c40=_0x7a1113;_0x43e5dc[_0x4d8c40('0x2122')]=[];}function _0x59fc98(){const _0x462e89=_0x7a1113;_0x43e5dc[_0x462e89('0x2122')]=_0x43e5dc[_0x462e89('0xae')][_0x462e89('0xf5d')];}}const _0x3d7d1b=_0x902436;_0x2c9455[_0x189033('0x14be')]=[_0x189033('0x1398'),'$translatePartialLoaderProvider'];function _0x2c9455(_0x209106,_0x574bbb){const _0x434d5b=_0x189033;_0x209106[_0x434d5b('0x2598')](_0x434d5b('0x17a8'),{'abstract':!![],'url':_0x434d5b('0x17d4')})['state'](_0x434d5b('0x2200'),{'url':_0x434d5b('0x1c15'),'views':{'content@app':{'templateUrl':_0x1c7e48,'controller':_0x434d5b('0x159')}},'resolve':{'openchannelQueues':['apiResolver',_0x434d5b('0xba1'),function(_0x17dd23,_0x4afe2c){const _0x4adc70=_0x434d5b;return _0x4afe2c['hasRole'](_0x4adc70('0x20c2'))?_0x17dd23['resolve'](_0x4adc70('0xc73'),{'fields':_0x4adc70('0x1b67'),'sort':'-updatedAt','channel':_0x4adc70('0x1261'),'limit':0xa,'offset':0x0}):_0x17dd23[_0x4adc70('0xed7')](_0x4adc70('0x191b'),{'id':_0x4afe2c[_0x4adc70('0x20b2')]()[_0x4adc70('0x2f')],'section':_0x4adc70('0x3da'),'fields':_0x4adc70('0x1b67'),'sort':_0x4adc70('0xc36'),'channel':'openchannel','limit':0xa,'offset':0x0});}],'userProfile':[_0x434d5b('0x4b1'),_0x434d5b('0xba1'),function(_0x12fbf7,_0x2607c){const _0x5778cf=_0x434d5b;return _0x2607c[_0x5778cf('0xca1')]('admin')?null:_0x12fbf7['resolve'](_0x5778cf('0x1464'),{'fields':'id,name,crudPermissions','id':_0x2607c[_0x5778cf('0x20b2')]()[_0x5778cf('0x2f')]});}],'userProfileSection':[_0x434d5b('0x4b1'),'Auth',function(_0x11c477,_0x248d18){const _0x4d369d=_0x434d5b;return _0x248d18[_0x4d369d('0xca1')](_0x4d369d('0x20c2'))?null:_0x11c477[_0x4d369d('0xed7')](_0x4d369d('0x360'),{'fields':_0x4d369d('0x1f47'),'userProfileId':_0x248d18[_0x4d369d('0x20b2')]()[_0x4d369d('0x2f')],'sectionId':0x321});}]},'authenticate':!![],'permissionId':0x321,'bodyClass':_0x434d5b('0x1261')})[_0x434d5b('0x2598')](_0x434d5b('0x25c0'),{'url':_0x434d5b('0x1560'),'params':{'openchannelQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x4ce45a,'controller':'OpenchannelQueueController\x20as\x20vm'}},'resolve':{'openchannelQueue':[_0x434d5b('0x4b1'),_0x434d5b('0x8ea'),function(_0x115303,_0x347feb){const _0x44bd11=_0x434d5b;return _0x115303[_0x44bd11('0xed7')](_0x44bd11('0xc73'),{'fields':_0x44bd11('0x1b67'),'id':_0x347feb['id']});}],'userProfileSection':[_0x434d5b('0x4b1'),_0x434d5b('0xba1'),function(_0x395117,_0x2df42d){const _0x3aa7fc=_0x434d5b;return _0x395117[_0x3aa7fc('0xed7')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x2df42d[_0x3aa7fc('0x20b2')]()[_0x3aa7fc('0x2f')],'sectionId':0x321});}]},'authenticate':!![],'permissionId':0x321,'bodyClass':_0x434d5b('0x1261')})[_0x434d5b('0x2598')](_0x434d5b('0x225d'),{'url':_0x434d5b('0xb78'),'views':{'content@app':{'templateUrl':_0x1c030d,'controller':_0x434d5b('0x1a44')}},'resolve':{'openchannelAccounts':[_0x434d5b('0x4b1'),_0x434d5b('0xba1'),function(_0x3deaf7,_0x529bc6){const _0x12504c=_0x434d5b;return _0x529bc6[_0x12504c('0xca1')]('admin')?_0x3deaf7[_0x12504c('0xed7')]('openchannelAccount@get',{'fields':_0x12504c('0x83'),'sort':_0x12504c('0xc36'),'limit':0xa,'offset':0x0}):_0x3deaf7[_0x12504c('0xed7')](_0x12504c('0x191b'),{'id':_0x529bc6[_0x12504c('0x20b2')]()[_0x12504c('0x2f')],'section':_0x12504c('0x1e08'),'fields':_0x12504c('0x83'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':[_0x434d5b('0x4b1'),_0x434d5b('0xba1'),function(_0x10de71,_0x1a0b4d){const _0x2e931f=_0x434d5b;return _0x1a0b4d['hasRole']('admin')?null:_0x10de71['resolve']('userProfile@get',{'fields':_0x2e931f('0x16f'),'id':_0x1a0b4d[_0x2e931f('0x20b2')]()['userProfileId']});}],'userProfileSection':['apiResolver',_0x434d5b('0xba1'),function(_0xe5cea9,_0x124bad){const _0x390d89=_0x434d5b;return _0x124bad[_0x390d89('0xca1')](_0x390d89('0x20c2'))?null:_0xe5cea9[_0x390d89('0xed7')](_0x390d89('0x360'),{'fields':_0x390d89('0x1f47'),'userProfileId':_0x124bad['getCurrentUser']()['userProfileId'],'sectionId':0x322});}]},'authenticate':!![],'permissionId':0x322,'bodyClass':_0x434d5b('0x1261')})[_0x434d5b('0x2598')](_0x434d5b('0xae7'),{'url':_0x434d5b('0x1560'),'params':{'openchannelAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x35d1cf,'controller':'OpenchannelAccountController\x20as\x20vm'}},'resolve':{'openchannelAccount':[_0x434d5b('0x4b1'),_0x434d5b('0x8ea'),function(_0xfecf0f,_0x3b8e32){const _0x1ce621=_0x434d5b;return _0xfecf0f['resolve'](_0x1ce621('0x2497'),{'fields':'createdAt,updatedAt,id,name,key,token,replyUri,ListId,waitForTheAssignedAgent,mapKey,mandatoryDisposition,mandatoryDispositionPauseId,description,receiveUri,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','id':_0x3b8e32['id']});}],'userProfileSection':[_0x434d5b('0x4b1'),_0x434d5b('0xba1'),function(_0x53d8d8,_0x17e38d){const _0x28ea9a=_0x434d5b;return _0x53d8d8[_0x28ea9a('0xed7')](_0x28ea9a('0x360'),{'fields':_0x28ea9a('0x1f47'),'userProfileId':_0x17e38d[_0x28ea9a('0x20b2')]()[_0x28ea9a('0x2f')],'sectionId':0x322});}]},'authenticate':!![],'permissionId':0x322,'bodyClass':_0x434d5b('0x1261')}),_0x574bbb[_0x434d5b('0x7d2')](_0x434d5b('0xb53'));}angular[_0x189033('0x1e26')](_0x189033('0x17a8'),[_0x189033('0x6cf'),_0x189033('0x1ddb'),_0x189033('0x2290'),_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),_0x189033('0x2609'),_0x189033('0x273d'),_0x189033('0x76'),'mwFormBuilder',_0x189033('0x7fa'),'mwFormUtils',_0x189033('0x3b5'),_0x189033('0x153a'),_0x189033('0x1447'),'angularMaterialFormBuilder',_0x189033('0x20c7'),_0x189033('0x1566'),'angular.filter',_0x189033('0x1ab0')])['config'](_0x2c9455)[_0x189033('0x1da3')](_0x189033('0x134f'),_0x41f723)[_0x189033('0x1da3')](_0x189033('0x132c'),_0x204bf1)[_0x189033('0x1da3')](_0x189033('0xac6'),_0x3ff2ab)[_0x189033('0x1da3')](_0x189033('0x11b7'),_0x12fdab)[_0x189033('0x1da3')](_0x189033('0x15b1'),_0x36169b)['controller'](_0x189033('0x124b'),_0x4c56dc)['controller']('EditOpenchannelAccountAppcloseDialogController',_0x47e9c6)[_0x189033('0x1da3')](_0x189033('0x25d4'),_0x32e253)[_0x189033('0x1da3')](_0x189033('0xc7e'),_0x480a8c)[_0x189033('0x1da3')](_0x189033('0x2432'),_0xc6dbf)[_0x189033('0x1da3')]('EditOpenchannelAccountAppintervalDialogController',_0x41f7f)[_0x189033('0x1da3')](_0x189033('0x11a6'),_0x1f8b86)[_0x189033('0x1da3')](_0x189033('0x2442'),_0x1e8c81)['controller'](_0x189033('0x232f'),_0x805271)['controller']('EditOpenchannelAccountApptagDialogController',_0x206b61)[_0x189033('0x1da3')](_0x189033('0x9a8'),_0x4f28ba)[_0x189033('0x1da3')](_0x189033('0xe15'),_0x1887db)[_0x189033('0x1da3')](_0x189033('0x16f4'),_0x597da2)['controller']('OpenchannelAccountDispositionsController',_0x5ed64b)[_0x189033('0x1da3')]('OpenchannelAccountController',_0x242e19)['controller'](_0x189033('0x144'),_0x30339a)['controller'](_0x189033('0x263d'),_0x1781f9)['controller'](_0x189033('0x116d'),_0x42081d)[_0x189033('0x1da3')](_0x189033('0x205b'),_0x3eae92)['controller'](_0x189033('0x2339'),_0x523085)[_0x189033('0x1da3')](_0x189033('0x61c'),_0x3d7d1b);const _0x36a8b1=_0x180212['p']+_0x189033('0x17ba'),_0x35c70a=_0x180212['p']+_0x189033('0x23cf'),_0x23829c=_0x180212['p']+_0x189033('0xc69'),_0x595434=_0x180212['p']+_0x189033('0x5cd'),_0x408ae7=_0x180212['p']+'src/js/modules/main/apps/fax/views/realtime/realtime.html/realtime.html',_0x409a5a=_0x180212['p']+_0x189033('0x1bb9'),_0x1cd612=_0x180212['p']+_0x189033('0xf26'),_0xdd48ca=_0x180212['p']+'src/js/modules/main/apps/fax/views/realtime/queues/view.html/view.html',_0x345ee7=_0x180212['p']+_0x189033('0x207e');_0x208b3a[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$timeout',_0x189033('0x1e48'),'$document',_0x189033('0x938'),_0x189033('0x56b'),_0x189033('0x1556'),'toasty',_0x189033('0x2595'),_0x189033('0xa6c'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1')];function _0x208b3a(_0x115f26,_0x27774c,_0x46bdcf,_0x3c8dca,_0x43cb1f,_0x3a0691,_0x1aea8d,_0x449570,_0x445d1b,_0x95ed7,_0x405038,_0x14553b,_0x12a608){const _0x49f32e=_0x189033,_0x52055a=this;_0x52055a[_0x49f32e('0x11ed')]=_0x12a608['getCurrentUser'](),_0x52055a[_0x49f32e('0x50d')]=_0x445d1b&&_0x445d1b[_0x49f32e('0x50d')]?_0x445d1b[_0x49f32e('0x50d')]:0x0,_0x52055a[_0x49f32e('0x2595')]=_0x445d1b?_0x2e3ca0()[_0x49f32e('0x24db')](_0x445d1b[_0x49f32e('0xf5d')]?_0x445d1b[_0x49f32e('0xf5d')]:[],'id'):{},_0x52055a[_0x49f32e('0xa6c')]=_0x95ed7?_0x2e3ca0()[_0x49f32e('0x24db')](_0x95ed7[_0x49f32e('0xf5d')]?_0x95ed7[_0x49f32e('0xf5d')]:[],'id'):{},_0x52055a[_0x49f32e('0x2a')]=_0x405038,_0x52055a[_0x49f32e('0x22df')]=_0x14553b&&_0x14553b['count']==0x1?_0x14553b[_0x49f32e('0xf5d')][0x0]:null,_0x52055a['crudPermissions']=_0x12a608[_0x49f32e('0x142a')](_0x52055a[_0x49f32e('0x22df')]?_0x52055a[_0x49f32e('0x22df')][_0x49f32e('0x1134')]:null),_0x52055a[_0x49f32e('0x23a2')]={'sort':_0x49f32e('0x13e2'),'limit':0xa,'page':0x1},_0x52055a[_0x49f32e('0x53')]=_0x1d9a92,_0x52055a['$onInit']=_0x12f632,_0x52055a[_0x49f32e('0x2842')]=_0x1287d8,_0x52055a[_0x49f32e('0x2819')]=_0x5ba188,_0x52055a[_0x49f32e('0x1b0c')]=_0x19f845,_0x52055a['goToFaxAccount']=_0x46cee7,_0x52055a[_0x49f32e('0x150d')]=[],_0x2e3ca0()['forIn'](_0x52055a[_0x49f32e('0x2595')],function(_0x36d896){const _0x314bfd=_0x49f32e;_0x52055a[_0x314bfd('0x150d')][_0x314bfd('0x1fd0')](_0x36d896['id']);}),_0x1aea8d['on'](_0x49f32e('0x1049'),_0x52055a[_0x49f32e('0x2819')]),_0x1aea8d['on'](_0x49f32e('0x80d'),_0x52055a['onSave']),_0x1aea8d['on'](_0x49f32e('0x2656'),_0x52055a[_0x49f32e('0x1b0c')]);function _0x12f632(){const _0x18ecbb=_0x49f32e;_0x2e3ca0()['forIn'](_0x52055a[_0x18ecbb('0x2595')],function(_0x934d74,_0x592921){const _0x1f910e=_0x18ecbb;_0x52055a['rpcFaxAccounts'][_0x592921]&&_0x2e3ca0()['merge'](_0x934d74,_0x52055a[_0x1f910e('0xa6c')][_0x592921]);}),_0x2e3ca0()['forIn'](_0x52055a[_0x18ecbb('0x2595')],function(_0x54368f,_0x368145){const _0x1e7c51=_0x18ecbb,_0x3975a4={'id':_0x368145,'sort':_0x1e7c51('0x24aa'),'direction':'in','limit':0x1,'offset':0x0,'$gte':'createdAt,'+_0x1aaf93()()[_0x1e7c51('0x1627')]('day')[_0x1e7c51('0x26dd')](_0x1e7c51('0x865'))};_0x3a0691[_0x1e7c51('0x244a')][_0x1e7c51('0x1cdb')](_0x3975a4)[_0x1e7c51('0xe53')][_0x1e7c51('0x683')](function(_0x53a0c){const _0x5eb2f0=_0x1e7c51;return _0x53a0c&&(_0x54368f['in']=_0x53a0c[_0x5eb2f0('0x50d')]||0x0,_0x54368f[_0x5eb2f0('0x921')]=_0x53a0c['rows']&&_0x53a0c[_0x5eb2f0('0xf5d')]['length']?_0x53a0c[_0x5eb2f0('0xf5d')][0x0][_0x5eb2f0('0x1a4')]:undefined),_0x3975a4['direction']='out',_0x3a0691[_0x5eb2f0('0x244a')]['getMessages'](_0x3975a4)['$promise'];})[_0x1e7c51('0x683')](function(_0x3f5b12){const _0x3989bd=_0x1e7c51;_0x3f5b12&&(_0x54368f['out']=_0x3f5b12[_0x3989bd('0x50d')]||0x0,_0x54368f[_0x3989bd('0x1d14')]=_0x3f5b12['rows']&&_0x3f5b12['rows'][_0x3989bd('0x1564')]?_0x3f5b12['rows'][0x0][_0x3989bd('0x1a4')]:undefined);})[_0x1e7c51('0x130a')](function(_0xcd81cd){console['log'](_0xcd81cd);});});}function _0x5ba188(_0x22245e){const _0x1016c4=_0x49f32e;_0x52055a[_0x1016c4('0x2595')][_0x22245e['id']]&&_0x2e3ca0()[_0x1016c4('0xf22')](_0x52055a['faxAccounts'][_0x22245e['id']],_0x22245e);}function _0x19f845(_0x39d204){const _0x150722=_0x49f32e;_0x52055a[_0x150722('0x2595')][_0x39d204[_0x150722('0xe22')]]&&(_0x39d204[_0x150722('0x2655')]=='in'?(_0x52055a[_0x150722('0x2595')][_0x39d204[_0x150722('0xe22')]]['in']+=0x1,_0x52055a['faxAccounts'][_0x39d204['FaxAccountId']][_0x150722('0x921')]=_0x39d204[_0x150722('0x1a4')]):(_0x52055a[_0x150722('0x2595')][_0x39d204[_0x150722('0xe22')]]['out']+=0x1,_0x52055a['faxAccounts'][_0x39d204[_0x150722('0xe22')]]['lastOut']=_0x39d204[_0x150722('0x1a4')]));}function _0x46cee7(_0x4fc291,_0x424fac){const _0x3e39eb=_0x49f32e;_0x43cb1f['go'](_0x3e39eb('0x2836'),{'id':_0x424fac['id'],'faxAccount':_0x424fac});}let _0xa9401f=!![],_0x1d95bc=0x1;_0x115f26[_0x49f32e('0x186d')](_0x49f32e('0x1e1d'),function(_0x117706,_0x9f7652){const _0x5a0429=_0x49f32e;_0xa9401f?_0x27774c(function(){_0xa9401f=![];}):(!_0x9f7652&&(_0x1d95bc=_0x52055a[_0x5a0429('0x23a2')][_0x5a0429('0xdf8')]),_0x117706!==_0x9f7652&&(_0x52055a[_0x5a0429('0x23a2')]['page']=0x1),!_0x117706&&(_0x52055a[_0x5a0429('0x23a2')][_0x5a0429('0xdf8')]=_0x1d95bc),_0x52055a[_0x5a0429('0x2842')]());});function _0x1d9a92(_0x476c01){const _0x256b1d=_0x49f32e;_0x52055a[_0x256b1d('0x2595')]=_0x476c01?_0x2e3ca0()[_0x256b1d('0x24db')](_0x476c01['rows']?_0x476c01[_0x256b1d('0xf5d')]:[],'id'):{};if(_0x476c01[_0x256b1d('0xf5d')]){_0x52055a['order']=[];for(let _0x1ecb21=0x0;_0x1ecb21<_0x476c01[_0x256b1d('0xf5d')][_0x256b1d('0x1564')];_0x1ecb21++){_0x52055a['order'][_0x256b1d('0x1fd0')](_0x476c01[_0x256b1d('0xf5d')][_0x1ecb21]['id']);}}_0x12f632();}function _0x1287d8(){const _0x50bfa6=_0x49f32e;_0x52055a[_0x50bfa6('0x23a2')][_0x50bfa6('0x1cc8')]=(_0x52055a[_0x50bfa6('0x23a2')]['page']-0x1)*_0x52055a[_0x50bfa6('0x23a2')][_0x50bfa6('0x6f0')],_0x12a608['hasRole'](_0x50bfa6('0x20c2'))?_0x52055a['promise']=_0x3a0691['faxAccount'][_0x50bfa6('0x1e6e')](_0x52055a[_0x50bfa6('0x23a2')],_0x1d9a92)[_0x50bfa6('0xe53')]:(_0x52055a['query']['id']=_0x52055a['userProfile']['id'],_0x52055a[_0x50bfa6('0x23a2')][_0x50bfa6('0x1aa')]='FaxAccounts',_0x52055a[_0x50bfa6('0x1883')]=_0x3a0691[_0x50bfa6('0x2a')][_0x50bfa6('0x241d')](_0x52055a['query'],_0x1d9a92)[_0x50bfa6('0xe53')]);}_0x115f26['$on'](_0x49f32e('0x4b8'),function(){const _0x312774=_0x49f32e;_0x1aea8d[_0x312774('0x1b9e')](_0x312774('0x1049')),_0x1aea8d[_0x312774('0x1b9e')](_0x312774('0x80d')),_0x1aea8d[_0x312774('0x1b9e')]('faxMessage:save');});}const _0x2792d4=_0x208b3a;_0xb5a887['$inject']=[_0x189033('0x7a5'),'$q',_0x189033('0x2f9'),_0x189033('0x1e48'),'$document',_0x189033('0x241e'),_0x189033('0x22ab'),_0x189033('0x756'),_0x189033('0x127b'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0xa72'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x1b27')];function _0xb5a887(_0x418aff,_0x1b7439,_0x152c56,_0x31331a,_0x8d0ddf,_0x1a532b,_0x508460,_0x4e4170,_0x107b7d,_0x5c920d,_0x34cc1a,_0x2aa405,_0x290c9e,_0x4e1e2e,_0x16af28,_0x2aae29,_0x6af78b,_0x120a3d){const _0x437666=_0x189033,_0x5d6eb9=this,_0x412133=['userpic',_0x437666('0x2309'),'lastLoginAt','lastPauseAt',_0x437666('0x17fe'),_0x437666('0x8cc'),'internal','address','chatPause',_0x437666('0x1a11'),_0x437666('0x774'),_0x437666('0x1b89'),_0x437666('0x185d'),_0x437666('0x716'),_0x437666('0x1431'),'chatCapacity',_0x437666('0x218'),_0x437666('0x2409'),_0x437666('0x205'),_0x437666('0x1484'),_0x437666('0x1079'),'chatCurrentCapacity',_0x437666('0x1f9b'),_0x437666('0x15c1'),_0x437666('0x1902'),_0x437666('0xaba'),_0x437666('0x157f'),_0x437666('0x1487'),_0x437666('0x2a8'),'mailStatus',_0x437666('0x2787'),'whatsappStatus',_0x437666('0x278b'),_0x437666('0x15e0'),'chatStatusTime',_0x437666('0x15db'),_0x437666('0xc07'),'smsStatusTime',_0x437666('0x17c2'),'faxStatusTime',_0x437666('0x23b4'),_0x437666('0x660'),_0x437666('0x10f5'),_0x437666('0xd70'),_0x437666('0xa31'),_0x437666('0x2259')],_0x29abb6=[_0x437666('0x1938'),_0x437666('0x1a11'),_0x437666('0x774'),_0x437666('0x1b89'),_0x437666('0x185d'),_0x437666('0x716'),_0x437666('0x1431'),'online'];_0x5d6eb9[_0x437666('0x11ed')]=_0x2aae29['getCurrentUser'](),_0x5d6eb9[_0x437666('0x24d2')]=[_0x437666('0x2727'),_0x437666('0x5d7'),_0x437666('0x63'),_0x437666('0x1026'),_0x437666('0x79')],_0x5d6eb9[_0x437666('0x22ab')]=_0x508460||{'count':0x0,'rows':[]},_0x5d6eb9[_0x437666('0xace')]=_0x6af78b,_0x5d6eb9[_0x437666('0x2a')]=_0x4e1e2e,_0x5d6eb9[_0x437666('0x22df')]=_0x16af28&&_0x16af28[_0x437666('0x50d')]==0x1?_0x16af28[_0x437666('0xf5d')][0x0]:null,_0x5d6eb9[_0x437666('0x1134')]=_0x2aae29[_0x437666('0x142a')](_0x5d6eb9['userProfileSection']?_0x5d6eb9['userProfileSection'][_0x437666('0x1134')]:null),_0x5d6eb9['agents']=_0x4e4170?_0x2e3ca0()['keyBy'](_0x4e4170[_0x437666('0xf5d')]?_0x4e4170[_0x437666('0xf5d')]:[],'id'):{},_0x5d6eb9[_0x437666('0x127b')]=_0x107b7d?_0x2e3ca0()['keyBy'](_0x107b7d[_0x437666('0xf5d')]?_0x107b7d[_0x437666('0xf5d')]:[],'id'):{},_0x5d6eb9['paginatedAgents']={},_0x5d6eb9[_0x437666('0x182c')]=![],_0x5d6eb9[_0x437666('0x150d')]=[],_0x5d6eb9['agentInternal']={};for(const _0x268845 in _0x5d6eb9['agents']){typeof _0x5d6eb9[_0x437666('0x756')][_0x268845]!==_0x437666('0x1867')&&(_0x5d6eb9['agents'][_0x268845][_0x437666('0x12f3')]=!![]);}_0x5d6eb9[_0x437666('0x23a2')]={'limit':0xa,'page':0x1,'order':'fullname','globalStatusFilter':'','pauseTypeFilter':''},_0x5d6eb9[_0x437666('0x1999')]=_0x8095b8,_0x5d6eb9[_0x437666('0x1880')]=_0xbcdfd,_0x5d6eb9['pause']=_0x23c88d,_0x5d6eb9[_0x437666('0x70e')]=_0x13bdee,_0x5d6eb9[_0x437666('0x411')]=_0xdb4f97,_0x5d6eb9[_0x437666('0x2d2')]=_0x556b35,_0x5d6eb9[_0x437666('0x1bf4')]=_0xc97726,_0x5d6eb9[_0x437666('0x3ee')]=_0x2fe6b3,_0x5d6eb9[_0x437666('0x2678')]=_0x4473a9,_0x5d6eb9[_0x437666('0x1f68')]=_0x262727,_0x5d6eb9[_0x437666('0x2819')]=_0x3f084a,_0x5d6eb9[_0x437666('0x1418')]=_0x34e4e9,_0x5d6eb9[_0x437666('0x1dd2')]=_0x473819,_0x5d6eb9[_0x437666('0x16b6')]=_0x29e2b5,_0x5d6eb9[_0x437666('0x2250')]=_0x12cb68,_0x5d6eb9[_0x437666('0x1f6c')]=_0x2aeae1,_0x34cc1a['on']('user:save',_0x5d6eb9[_0x437666('0x2819')]),_0x34cc1a['on'](_0x437666('0x2719'),_0x5d6eb9[_0x437666('0x1418')]),_0x34cc1a['on'](_0x437666('0x216d'),_0x5d6eb9[_0x437666('0x16b6')]),_0x34cc1a['on'](_0x437666('0x3b6'),_0x5d6eb9[_0x437666('0x2250')]),_0x473819();let _0x405e17=_0x120a3d(function(){const _0xac687c=_0x437666;_0x5d6eb9[_0xac687c('0x182c')]&&(_0x5d6eb9[_0xac687c('0x182c')]=![],_0x473819());},0x3e7);function _0x473819(){const _0x4e5938=_0x437666;_0x5d6eb9[_0x4e5938('0x182c')]=![];const _0x32511=_0x1b7439[_0x4e5938('0x448')]();_0x5d6eb9[_0x4e5938('0x1883')]=_0x32511[_0x4e5938('0x1883')],_0x5d6eb9[_0x4e5938('0xdf9')]=[],_0x5d6eb9[_0x4e5938('0x150d')]=[],_0x2e3ca0()[_0x4e5938('0x15d0')](_0x5d6eb9[_0x4e5938('0x756')],function(_0x2b2773,_0x4bca4b){const _0x4b3f6b=_0x4e5938;_0x5d6eb9[_0x4b3f6b('0x127b')][_0x4bca4b]&&_0x2e3ca0()['merge'](_0x2b2773,_0x2e3ca0()[_0x4b3f6b('0x24d0')](_0x2e3ca0()['omit'](_0x5d6eb9[_0x4b3f6b('0x127b')][_0x4bca4b],_0x29abb6),_0x412133)),_0xc97726(_0x2b2773),_0x2b2773[_0x4b3f6b('0x2309')]?(_0x5d6eb9['filteredAgents']['push'](_0x2b2773),_0x5d6eb9[_0x4b3f6b('0x7c6')][_0x2b2773['internal']]=_0x4bca4b):_0x2b2773[_0x4b3f6b('0x24d')]=_0x2e3ca0()[_0x4b3f6b('0xea3')](_0x1aaf93()()[_0x4b3f6b('0x26dd')]('x'));});_0x5d6eb9[_0x4e5938('0x23a2')][_0x4e5938('0x1102')]&&_0x2e3ca0()[_0x4e5938('0x3ec')](_0x5d6eb9[_0x4e5938('0xdf9')],function(_0x41177f){const _0x2e80ba=_0x4e5938;return _0x41177f[_0x2e80ba('0x12fa')]!==_0x5d6eb9[_0x2e80ba('0x23a2')]['globalStatusFilter'];});_0x5d6eb9[_0x4e5938('0x23a2')][_0x4e5938('0x1606')]&&_0x2e3ca0()[_0x4e5938('0x3ec')](_0x5d6eb9[_0x4e5938('0xdf9')],function(_0x25652c){const _0x743292=_0x4e5938;return _0x25652c[_0x743292('0x17fe')]!==_0x5d6eb9[_0x743292('0x23a2')][_0x743292('0x1606')];});_0x5d6eb9[_0x4e5938('0x23a2')]['filter']&&_0x2e3ca0()[_0x4e5938('0x3ec')](_0x5d6eb9['filteredAgents'],function(_0x14da13){const _0x49a332=_0x4e5938;return _0x14da13[_0x49a332('0x11bc')][_0x49a332('0x93a')]()[_0x49a332('0x824')](_0x5d6eb9[_0x49a332('0x23a2')][_0x49a332('0x25')][_0x49a332('0x93a')]())<0x0;});_0x5d6eb9[_0x4e5938('0xdf9')]=_0x3d4688(_0x5d6eb9[_0x4e5938('0xdf9')]);const _0x5c359b=(_0x5d6eb9[_0x4e5938('0x23a2')][_0x4e5938('0xdf8')]-0x1)*_0x5d6eb9[_0x4e5938('0x23a2')]['limit'];_0x5d6eb9[_0x4e5938('0x20d5')]=_0x2e3ca0()[_0x4e5938('0x16b7')](_0x5d6eb9[_0x4e5938('0xdf9')],_0x5c359b)['slice'](0x0,_0x5d6eb9[_0x4e5938('0x23a2')][_0x4e5938('0x6f0')]);for(let _0x16c910=0x0;_0x16c910<_0x5d6eb9[_0x4e5938('0x20d5')][_0x4e5938('0x1564')];_0x16c910+=0x1){_0x5d6eb9[_0x4e5938('0x150d')]['push'](_0x5d6eb9[_0x4e5938('0x20d5')][_0x16c910]['id']);}_0x32511[_0x4e5938('0xed7')](),_0x5d6eb9['load']=!![];}function _0x3f084a(_0x23e074){const _0x1b5441=_0x437666;_0x5d6eb9[_0x1b5441('0x756')][_0x23e074['id']]&&(_0x2e3ca0()[_0x1b5441('0xf22')](_0x5d6eb9[_0x1b5441('0x756')][_0x23e074['id']],_0x2e3ca0()['pick'](_0x2e3ca0()['omit'](_0x23e074,_0x29abb6),_0x412133)),_0x2e3ca0()[_0x1b5441('0xf22')](_0x5d6eb9[_0x1b5441('0x127b')][_0x23e074['id']],_0x2e3ca0()[_0x1b5441('0x24d0')](_0x2e3ca0()[_0x1b5441('0x8b5')](_0x23e074,_0x29abb6),_0x412133)),_0xc97726(_0x5d6eb9[_0x1b5441('0x756')][_0x23e074['id']]));}function _0x34e4e9(_0x53d31c){const _0x5a3835=_0x437666;_0x5d6eb9[_0x5a3835('0x756')][_0x53d31c['id']]&&(_0x2e3ca0()[_0x5a3835('0xf22')](_0x5d6eb9[_0x5a3835('0x756')][_0x53d31c['id']],_0x2e3ca0()[_0x5a3835('0x24d0')](_0x53d31c,_0x412133)),_0x2e3ca0()[_0x5a3835('0xf22')](_0x5d6eb9[_0x5a3835('0x127b')][_0x53d31c['id']],_0x2e3ca0()[_0x5a3835('0x24d0')](_0x53d31c,_0x412133)),_0x53d31c[_0x5a3835('0x8cc')]&&(_0x5d6eb9[_0x5a3835('0x756')][_0x53d31c['id']][_0x5a3835('0x24d')]=_0x53d31c[_0x5a3835('0x8cc')],_0x5d6eb9[_0x5a3835('0x127b')][_0x53d31c['id']][_0x5a3835('0x24d')]=_0x53d31c[_0x5a3835('0x8cc')]),_0xc97726(_0x5d6eb9['agents'][_0x53d31c['id']]));}function _0x29e2b5(_0x5c7770){const _0x54ffd6=_0x437666;_0x5d6eb9[_0x54ffd6('0x756')][_0x5d6eb9[_0x54ffd6('0x7c6')][_0x5c7770[_0x54ffd6('0x1d79')]]]&&(_0x2e3ca0()[_0x54ffd6('0xf22')](_0x5d6eb9[_0x54ffd6('0x756')][_0x5d6eb9[_0x54ffd6('0x7c6')][_0x5c7770[_0x54ffd6('0x1d79')]]],_0x2e3ca0()[_0x54ffd6('0x24d0')](_0x5c7770,[_0x54ffd6('0x660'),'destconnectedlinenum'])),_0x2e3ca0()[_0x54ffd6('0xf22')](_0x5d6eb9['rpcAgents'][_0x5d6eb9['agentInternal'][_0x5c7770[_0x54ffd6('0x1d79')]]],_0x2e3ca0()[_0x54ffd6('0x24d0')](_0x5c7770,[_0x54ffd6('0x660'),_0x54ffd6('0x10f5')])));}function _0x12cb68(_0x51ca3f){const _0x18f096=_0x437666;_0x5d6eb9[_0x18f096('0x756')][_0x5d6eb9['agentInternal'][_0x51ca3f[_0x18f096('0x1d79')]]]&&(_0x5d6eb9[_0x18f096('0x756')][_0x5d6eb9[_0x18f096('0x7c6')][_0x51ca3f[_0x18f096('0x1d79')]]]=_0x2e3ca0()[_0x18f096('0x8b5')](_0x5d6eb9[_0x18f096('0x756')][_0x5d6eb9['agentInternal'][_0x51ca3f[_0x18f096('0x1d79')]]],[_0x18f096('0x660'),_0x18f096('0x10f5')]),_0x5d6eb9[_0x18f096('0x127b')][_0x5d6eb9[_0x18f096('0x7c6')][_0x51ca3f[_0x18f096('0x1d79')]]]=_0x2e3ca0()[_0x18f096('0x8b5')](_0x5d6eb9['rpcAgents'][_0x5d6eb9['agentInternal'][_0x51ca3f[_0x18f096('0x1d79')]]],[_0x18f096('0x660'),'destconnectedlinenum']));}function _0x8095b8(_0x59bc04){const _0x2a1d6f=_0x437666;return _0x5c920d[_0x2a1d6f('0xc96')][_0x2a1d6f('0x1999')]({'id':_0x59bc04['id'],'device':_0x2a1d6f('0x2c9'),'agent_id':_0x59bc04['id'],'agent_name':_0x59bc04['name']})['$promise'][_0x2a1d6f('0x683')](function(){const _0xb3ebcb=_0x2a1d6f;_0x2aa405[_0xb3ebcb('0x53')]({'title':_0xb3ebcb('0x1683'),'msg':_0x59bc04[_0xb3ebcb('0x11bc')]+_0xb3ebcb('0x2488')}),_0x5d6eb9['agents'][_0x59bc04['id']]&&(_0x5d6eb9[_0xb3ebcb('0x756')][_0x59bc04['id']][_0xb3ebcb('0x2309')]=![]),_0x5d6eb9[_0xb3ebcb('0x127b')][_0x59bc04['id']]&&(_0x5d6eb9[_0xb3ebcb('0x127b')][_0x59bc04['id']][_0xb3ebcb('0x2309')]=![]),_0x473819();})[_0x2a1d6f('0x130a')](function(_0x4a5c70){const _0x4ff9ca=_0x2a1d6f;_0x2aa405[_0x4ff9ca('0x52a')]({'title':_0x4a5c70[_0x4ff9ca('0x13ee')]?_0x4ff9ca('0x2168')+_0x4a5c70[_0x4ff9ca('0x13ee')]+_0x4ff9ca('0xbf6')+_0x4a5c70[_0x4ff9ca('0x24a9')]:_0x4ff9ca('0x154f'),'msg':_0x4a5c70[_0x4ff9ca('0x5a5')]?JSON[_0x4ff9ca('0x258a')](_0x4a5c70[_0x4ff9ca('0x5a5')][_0x4ff9ca('0x8c2')]):_0x4a5c70[_0x4ff9ca('0x1ff0')]()});});}function _0x23c88d(_0x1f7906,_0x6b9db7){const _0x282eb7=_0x437666;return _0x5c920d[_0x282eb7('0xc96')][_0x282eb7('0xa4')]({'id':_0x1f7906['id'],'type':_0x6b9db7})[_0x282eb7('0xe53')][_0x282eb7('0x683')](function(_0x526465){const _0x58288c=_0x282eb7;_0x5d6eb9[_0x58288c('0x756')][_0x1f7906['id']]&&_0x2e3ca0()['merge'](_0x5d6eb9[_0x58288c('0x756')][_0x1f7906['id']],_0x2e3ca0()[_0x58288c('0x24d0')](_0x526465,_0x412133)),_0x5d6eb9['rpcAgents'][_0x1f7906['id']]&&_0x2e3ca0()[_0x58288c('0xf22')](_0x5d6eb9[_0x58288c('0x127b')][_0x1f7906['id']],_0x2e3ca0()[_0x58288c('0x24d0')](_0x526465,_0x412133)),_0xc97726(_0x5d6eb9[_0x58288c('0x756')][_0x1f7906['id']]);})[_0x282eb7('0x130a')](function(_0x13e449){const _0x483ee5=_0x282eb7;_0x2aa405[_0x483ee5('0x52a')]({'title':_0x13e449[_0x483ee5('0x13ee')]?_0x483ee5('0x2168')+_0x13e449[_0x483ee5('0x13ee')]+'\x20-\x20'+_0x13e449[_0x483ee5('0x24a9')]:'api.staff.save','msg':_0x13e449[_0x483ee5('0x5a5')]?JSON[_0x483ee5('0x258a')](_0x13e449[_0x483ee5('0x5a5')][_0x483ee5('0x8c2')]):_0x13e449[_0x483ee5('0x1ff0')]()});});}function _0x13bdee(_0x8b7c73){const _0x152612=_0x437666;return _0x5c920d[_0x152612('0xc96')][_0x152612('0x1778')]({'id':_0x8b7c73['id']})[_0x152612('0xe53')]['then'](function(_0x4f16d0){const _0x2dbdea=_0x152612;_0x5d6eb9[_0x2dbdea('0x756')][_0x8b7c73['id']]&&_0x2e3ca0()[_0x2dbdea('0xf22')](_0x5d6eb9['agents'][_0x8b7c73['id']],_0x2e3ca0()[_0x2dbdea('0x24d0')](_0x4f16d0,_0x412133)),_0x5d6eb9[_0x2dbdea('0x127b')][_0x8b7c73['id']]&&_0x2e3ca0()[_0x2dbdea('0xf22')](_0x5d6eb9['rpcAgents'][_0x8b7c73['id']],_0x2e3ca0()['pick'](_0x4f16d0,_0x412133)),_0xc97726(_0x5d6eb9[_0x2dbdea('0x756')][_0x8b7c73['id']]);})[_0x152612('0x130a')](function(_0x3220e8){const _0x27ecdd=_0x152612;_0x2aa405[_0x27ecdd('0x52a')]({'title':_0x3220e8[_0x27ecdd('0x13ee')]?_0x27ecdd('0x2168')+_0x3220e8['status']+'\x20-\x20'+_0x3220e8[_0x27ecdd('0x24a9')]:_0x27ecdd('0x154f'),'msg':_0x3220e8[_0x27ecdd('0x5a5')]?JSON[_0x27ecdd('0x258a')](_0x3220e8['data'][_0x27ecdd('0x8c2')]):_0x3220e8['toString']()});});}function _0xdb4f97(_0x173cc7){const _0x5273de=_0x437666;_0x31331a[_0x5273de('0x1d4')](_0x31331a[_0x5273de('0x2430')]()[_0x5273de('0x188f')](!![])['title'](_0x5273de('0x71a'))[_0x5273de('0x26e3')](_0x5273de('0x1f0'))['ok']('Ok')['targetEvent'](_0x173cc7));}function _0xbcdfd(_0x4b1524,_0x10ce22){const _0x5b812a=_0x437666;_0x31331a[_0x5b812a('0x1d4')]({'controller':_0x5b812a('0x1e85'),'controllerAs':'vm','templateUrl':_0xf3687b,'parent':angular[_0x5b812a('0x1fcc')](_0x8d0ddf['body']),'targetEvent':_0x10ce22,'clickOutsideToClose':!![],'locals':{'agent':_0x4b1524,'agents':[],'channel':_0x5b812a('0x23e9'),'direction':_0x5b812a('0x1535'),'crudPermissions':_0x5d6eb9[_0x5b812a('0x1134')]}});}function _0x2fe6b3(_0x5965d4){const _0xbc63ed=_0x437666;return _0x5965d4===_0xbc63ed('0xa4')||_0x5965d4===_0xbc63ed('0x651');}function _0x4473a9(_0x4bee7f){const _0x121fc8=_0x437666;return _0x4bee7f===_0x121fc8('0xa4');}function _0x262727(_0x48a331){const _0x4f187b=_0x437666;return _0x48a331===_0x4f187b('0x651');}function _0x46ca7a(_0x268f81){const _0x4b9493=_0x437666;return _0x268f81===_0x4b9493('0x1586')||_0x268f81===_0x4b9493('0xdd4')||_0x268f81===_0x4b9493('0x19d2')||_0x268f81===_0x4b9493('0x2727')||_0x2e3ca0()[_0x4b9493('0x8f2')](_0x268f81);}function _0x556b35(_0x550522,_0x10128f){const _0x3dcbfb=_0x437666;if(_0x10128f===_0x3dcbfb('0xcf2')){if(_0x550522[_0x10128f+_0x3dcbfb('0x1d9d')]!=='idle')return _0x550522[_0x10128f+_0x3dcbfb('0x1d9d')];if(_0x550522[_0x10128f+'Pause'])return _0x550522[_0x10128f+'Status']=_0x3dcbfb('0xa4'),_0x3dcbfb('0xa4');return _0x3dcbfb('0x1586');}else{if(_0x550522[_0x10128f+_0x3dcbfb('0x2113')])return _0x550522[_0x10128f+_0x3dcbfb('0x1d9d')]=_0x3dcbfb('0xa4'),_0x3dcbfb('0xa4');return _0x550522[_0x10128f+_0x3dcbfb('0x1d9d')];}}function _0xc97726(_0x1e7521){const _0x33d5d1=_0x437666;let _0x417045=_0x33d5d1('0xdd4');if(_0x2e3ca0()[_0x33d5d1('0x161')]([_0x556b35(_0x1e7521,'voice'),_0x556b35(_0x1e7521,'chat'),_0x556b35(_0x1e7521,_0x33d5d1('0x129f')),_0x556b35(_0x1e7521,_0x33d5d1('0x1261')),_0x556b35(_0x1e7521,_0x33d5d1('0x1285')),_0x556b35(_0x1e7521,'whatsapp'),_0x556b35(_0x1e7521,_0x33d5d1('0x23e9'))],_0x2fe6b3))_0x417045=_0x33d5d1('0xa4');else{if(_0x2e3ca0()['some']([_0x556b35(_0x1e7521,_0x33d5d1('0xcf2')),_0x556b35(_0x1e7521,_0x33d5d1('0x24e')),_0x556b35(_0x1e7521,_0x33d5d1('0x129f')),_0x556b35(_0x1e7521,_0x33d5d1('0x1261')),_0x556b35(_0x1e7521,_0x33d5d1('0x1285')),_0x556b35(_0x1e7521,'whatsapp'),_0x556b35(_0x1e7521,'fax')],_0x2fe6b3))_0x417045=_0x33d5d1('0x651');else _0x2e3ca0()[_0x33d5d1('0x161')]([_0x556b35(_0x1e7521,'voice'),_0x556b35(_0x1e7521,'chat'),_0x556b35(_0x1e7521,_0x33d5d1('0x129f')),_0x556b35(_0x1e7521,_0x33d5d1('0x1261')),_0x556b35(_0x1e7521,_0x33d5d1('0x1285')),_0x556b35(_0x1e7521,'whatsapp'),_0x556b35(_0x1e7521,_0x33d5d1('0x23e9'))],_0x46ca7a)?_0x417045=_0x33d5d1('0x1586'):_0x417045=_0x33d5d1('0x63');}_0x1e7521[_0x33d5d1('0x12fa')]!==_0x417045&&(_0x1e7521[_0x33d5d1('0x12fa')]=_0x417045,_0x1e7521[_0x33d5d1('0x12f3')]?(_0x1e7521[_0x33d5d1('0x12f3')]=![],_0x1e7521[_0x33d5d1('0x24d')]=_0x2fe6b3(_0x417045)?_0x2e3ca0()[_0x33d5d1('0xea3')](_0x1aaf93()(_0x1e7521[_0x33d5d1('0x8cc')])[_0x33d5d1('0x26dd')]('x')):_0x2e3ca0()[_0x33d5d1('0x69b')]([_0x1e7521[_0x33d5d1('0x23b4')],_0x1e7521['chatStatusTime'],_0x1e7521[_0x33d5d1('0xc07')],_0x1e7521[_0x33d5d1('0x1a70')],_0x1e7521[_0x33d5d1('0x17c2')],_0x1e7521[_0x33d5d1('0x15db')],_0x1e7521[_0x33d5d1('0x21d1')]])):_0x1e7521[_0x33d5d1('0x24d')]=_0x2e3ca0()[_0x33d5d1('0xea3')](_0x1aaf93()()[_0x33d5d1('0x26dd')]('x')));}function _0x3d4688(_0x3ee515){const _0x13f909=_0x437666,_0x2278a9=_0x2e3ca0()[_0x13f909('0x18ad')](_0x5d6eb9[_0x13f909('0x23a2')]['order'],'-')?_0x13f909('0x1f5a'):_0x13f909('0xe38');return _0x2e3ca0()[_0x13f909('0x2ef')](_0x3ee515,[_0x5d6eb9[_0x13f909('0x23a2')][_0x13f909('0x150d')]['replace']('-','')],[_0x2278a9]);}function _0x2158db(){_0x405e17&&(_0x120a3d['cancel'](_0x405e17),_0x405e17=null);}function _0x2aeae1(_0x237bf6,_0x14fd7d){const _0x30ed0c=_0x437666;return _0x5c920d['user'][_0x30ed0c('0x2480')]({'id':_0x237bf6['id']},{'screenrecording':_0x14fd7d})[_0x30ed0c('0xe53')]['catch'](function(_0x221de2){const _0x275c59=_0x30ed0c;_0x2aa405[_0x275c59('0x52a')]({'title':_0x221de2[_0x275c59('0x13ee')]?_0x275c59('0x2168')+_0x221de2[_0x275c59('0x13ee')]+'\x20-\x20'+_0x221de2[_0x275c59('0x24a9')]:_0x275c59('0x162b'),'msg':_0x221de2[_0x275c59('0x5a5')]?JSON[_0x275c59('0x258a')](_0x221de2[_0x275c59('0x5a5')][_0x275c59('0x8c2')]):_0x221de2['toString']()});});}_0x418aff['$on'](_0x437666('0x4b8'),function(){const _0x5564f0=_0x437666;_0x34cc1a['removeAllListeners'](_0x5564f0('0x18f0')),_0x34cc1a[_0x5564f0('0x1b9e')]('user:update'),_0x34cc1a['removeAllListeners'](_0x5564f0('0x216d')),_0x34cc1a[_0x5564f0('0x1b9e')](_0x5564f0('0x3b6')),_0x2158db();});}const _0x2a24b9=_0xb5a887,_0x12aa32=_0x180212['p']+'src/js/modules/main/apps/fax/views/faxQueues/edit/agentadd/agentadd.html/agentadd.html',_0x387711=_0x180212['p']+_0x189033('0x7e2');_0x1c0a22[_0x189033('0x14be')]=['$scope',_0x189033('0x2f9'),_0x189033('0x1e48'),'$q','$document',_0x189033('0x1b27'),_0x189033('0x2da'),_0x189033('0x1a10'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1')];function _0x1c0a22(_0x3f0eed,_0x387ee1,_0x3e75af,_0x1c4e4e,_0x7f9850,_0x2537c5,_0x33e835,_0x45d573,_0x5bd11e,_0x40d195,_0x18db3f,_0x22442a,_0x1f25eb,_0x5d6235){const _0x1412b8=_0x189033,_0x11f987=this,_0x46affa=[_0x1412b8('0x1506'),'available','waiting',_0x1412b8('0x7a4'),_0x1412b8('0x17f2'),_0x1412b8('0x1a95'),_0x1412b8('0x8c2'),_0x1412b8('0x1455'),_0x1412b8('0x1091'),_0x1412b8('0x17c1'),_0x1412b8('0x1a1d')];_0x11f987[_0x1412b8('0x11ed')]=_0x5d6235[_0x1412b8('0x20b2')](),_0x11f987['count']=_0x33e835[_0x1412b8('0x50d')]?_0x33e835[_0x1412b8('0x50d')]:0x0,_0x11f987['queues']=_0x33e835?_0x2e3ca0()[_0x1412b8('0x24db')](_0x33e835[_0x1412b8('0xf5d')]?_0x33e835[_0x1412b8('0xf5d')]:[],'id'):{},_0x11f987['rpcQueues']=_0x45d573?_0x2e3ca0()[_0x1412b8('0x24db')](_0x45d573['rows']?_0x45d573[_0x1412b8('0xf5d')]:[],'id'):{},_0x11f987[_0x1412b8('0x2a')]=_0x22442a,_0x11f987['userProfileSection']=_0x1f25eb&&_0x1f25eb[_0x1412b8('0x50d')]==0x1?_0x1f25eb['rows'][0x0]:null,_0x11f987[_0x1412b8('0x1134')]=_0x5d6235[_0x1412b8('0x142a')](_0x11f987[_0x1412b8('0x22df')]?_0x11f987[_0x1412b8('0x22df')][_0x1412b8('0x1134')]:null);_0x5d6235[_0x1412b8('0xca1')](_0x1412b8('0x20c2'))?_0x11f987[_0x1412b8('0x23a2')]={'type':_0x1412b8('0x1535'),'sort':'-updatedAt','limit':0xa,'page':0x1}:_0x11f987[_0x1412b8('0x23a2')]={'id':_0x11f987[_0x1412b8('0x11ed')]['id'],'channel':_0x1412b8('0x23e9'),'type':_0x1412b8('0x1535'),'sort':'-updatedAt','limit':0xa,'page':0x1};_0x11f987['success']=_0x4f6d6f,_0x11f987[_0x1412b8('0x4c9')]=_0x1674d5,_0x11f987[_0x1412b8('0x1fd4')]=_0x2ae199,_0x11f987['agentAdd']=_0x280c7c,_0x11f987['updateQueue']=_0x47dd5d,_0x11f987[_0x1412b8('0x2819')]=_0x4a5fbf,_0x11f987['onSaveMember']=_0x13fa13,_0x11f987[_0x1412b8('0x203e')]=_0x1ec186,_0x11f987[_0x1412b8('0x4a5')]=_0x5310b2,_0x11f987[_0x1412b8('0xd8b')]=_0x2fe528,_0x11f987[_0x1412b8('0xb2b')]=_0x3cae1f,_0x11f987['$onInit']=_0x343518,_0x11f987[_0x1412b8('0x150d')]=[],_0x2e3ca0()[_0x1412b8('0x15d0')](_0x11f987[_0x1412b8('0x2da')],function(_0x2b47ba){const _0x1273e3=_0x1412b8;_0x11f987[_0x1273e3('0x150d')][_0x1273e3('0x1fd0')](_0x2b47ba['id']);}),_0x40d195['on'](_0x1412b8('0x2314'),_0x11f987[_0x1412b8('0x2819')]),_0x40d195['on'](_0x1412b8('0x1495'),_0x11f987[_0x1412b8('0x3ae')]),_0x40d195['on'](_0x1412b8('0xcf4'),_0x11f987[_0x1412b8('0x203e')]),_0x40d195['on'](_0x1412b8('0x2719'),_0x11f987[_0x1412b8('0x4a5')]),_0x40d195['on'](_0x1412b8('0x56f'),_0x11f987[_0x1412b8('0xb2b')]),_0x40d195['on'](_0x1412b8('0x217c'),_0x11f987[_0x1412b8('0xd8b')]);function _0x343518(){const _0xf22eb1=_0x1412b8,_0x37c1ec=[];return _0x2e3ca0()[_0xf22eb1('0x15d0')](_0x11f987['queues'],function(_0x37bd72,_0x4c9d9d){const _0x16de04=_0xf22eb1;_0x37bd72['paused']=0x0,_0x37bd72['loggedInDb']=0x0,_0x11f987[_0x16de04('0x2da')][_0x4c9d9d][_0x16de04('0x756')]={},_0x37c1ec[_0x16de04('0x1fd0')](_0x5bd11e[_0x16de04('0x209c')][_0x16de04('0x27cf')]({'id':_0x4c9d9d})[_0x16de04('0xe53')]),_0x11f987[_0x16de04('0x1a10')][_0x4c9d9d]&&_0x2e3ca0()['merge'](_0x37bd72,_0x2e3ca0()[_0x16de04('0x24d0')](_0x11f987['rpcQueues'][_0x4c9d9d],_0x46affa));}),_0x1c4e4e[_0xf22eb1('0x252c')](_0x37c1ec)[_0xf22eb1('0x683')](function(_0x3b3162){const _0x5d1258=_0xf22eb1;for(let _0x1adc25=0x0;_0x1adc25<_0x3b3162[_0x5d1258('0x1564')];_0x1adc25+=0x1){for(let _0x453e4a=0x0;_0x453e4a<_0x3b3162[_0x1adc25][_0x5d1258('0xf5d')][_0x5d1258('0x1564')];_0x453e4a++){_0x3b3162[_0x1adc25][_0x5d1258('0xf5d')][_0x453e4a]['paused']&&_0x11f987[_0x5d1258('0x2da')][_0x3b3162[_0x1adc25][_0x5d1258('0xf5d')][_0x453e4a][_0x5d1258('0x26cc')]][_0x5d1258('0x1a1d')]++,_0x11f987[_0x5d1258('0x2da')][_0x3b3162[_0x1adc25][_0x5d1258('0xf5d')][_0x453e4a]['FaxQueueId']][_0x5d1258('0x25a4')]++,_0x11f987[_0x5d1258('0x2da')][_0x3b3162[_0x1adc25][_0x5d1258('0xf5d')][_0x453e4a][_0x5d1258('0x26cc')]][_0x5d1258('0x756')][_0x3b3162[_0x1adc25]['rows'][_0x453e4a][_0x5d1258('0x10c5')]]=_0x3b3162[_0x1adc25][_0x5d1258('0xf5d')][_0x453e4a]['FaxQueueId'];}}})[_0xf22eb1('0x130a')](function(_0x2dc17b){console['error'](_0x2dc17b);});}function _0x4a5fbf(_0x5759e6){const _0xee6bb=_0x1412b8;_0x11f987[_0xee6bb('0x2da')][_0x5759e6['id']]&&_0x2e3ca0()[_0xee6bb('0xf22')](_0x11f987[_0xee6bb('0x2da')][_0x5759e6['id']],_0x2e3ca0()[_0xee6bb('0x24d0')](_0x5759e6,_0x46affa));}function _0x13fa13(_0x5860d7){const _0xd1ef15=_0x1412b8;_0x11f987[_0xd1ef15('0x2da')][_0x5860d7[_0xd1ef15('0x26cc')]]&&_0x11f987[_0xd1ef15('0x2da')][_0x5860d7[_0xd1ef15('0x26cc')]]['loggedInDb']++;}function _0x1ec186(_0x3b183f){const _0x1e843d=_0x1412b8;_0x11f987['queues'][_0x3b183f[_0x1e843d('0x26cc')]]&&_0x11f987[_0x1e843d('0x2da')][_0x3b183f[_0x1e843d('0x26cc')]][_0x1e843d('0x25a4')]--;}function _0x5310b2(_0x4260c9){const _0x48c64a=_0x1412b8;console[_0x48c64a('0x1b2b')](_0x48c64a('0x4a5'),_0x4260c9);if(_0x4260c9[_0x48c64a('0x1431')])_0x2e3ca0()[_0x48c64a('0x15d0')](_0x11f987['queues'],function(_0x223850){const _0x5941f5=_0x48c64a;_0x223850[_0x5941f5('0x756')][_0x4260c9['id']]&&(_0x223850[_0x5941f5('0x1a1d')]+=0x1,console['log'](_0x5941f5('0xa4')));});else!_0x4260c9['voicePause']&&_0x2e3ca0()['forIn'](_0x11f987[_0x48c64a('0x2da')],function(_0x23e34d){const _0x5088f3=_0x48c64a;_0x23e34d[_0x5088f3('0x756')][_0x4260c9['id']]&&(_0x23e34d[_0x5088f3('0x1a1d')]>0x0&&(_0x23e34d[_0x5088f3('0x1a1d')]-=0x1,console['log']('unpause')));});}function _0x2fe528(_0x405ba6){const _0x4ca65a=_0x1412b8;console[_0x4ca65a('0x1b2b')](_0x4ca65a('0x16aa'),_0x405ba6),_0x11f987[_0x4ca65a('0x2da')][_0x405ba6[_0x4ca65a('0x26cc')]]&&(_0x11f987[_0x4ca65a('0x2da')][_0x405ba6[_0x4ca65a('0x26cc')]][_0x4ca65a('0x25a4')]+=0x1,_0x11f987[_0x4ca65a('0x2da')][_0x405ba6[_0x4ca65a('0x26cc')]]['agents'][_0x405ba6[_0x4ca65a('0x10c5')]]=_0x405ba6[_0x4ca65a('0x26cc')]);}function _0x3cae1f(_0x34d630){const _0x446d6c=_0x1412b8;console['log'](_0x446d6c('0xb2b'),_0x34d630),_0x11f987[_0x446d6c('0x2da')][_0x34d630[_0x446d6c('0x26cc')]]&&_0x11f987[_0x446d6c('0x2da')][_0x34d630[_0x446d6c('0x26cc')]][_0x446d6c('0x25a4')]>0x0&&(_0x11f987[_0x446d6c('0x2da')][_0x34d630[_0x446d6c('0x26cc')]]['loggedInDb']-=0x1,delete _0x11f987['queues'][_0x34d630['FaxQueueId']][_0x446d6c('0x756')][_0x34d630['UserId']]);}let _0x460584=!![],_0x421d15=0x1;_0x3f0eed[_0x1412b8('0x186d')]('vm.query.filter',function(_0x2c43a4,_0xaad5e7){const _0x572ae7=_0x1412b8;_0x460584?_0x387ee1(function(){_0x460584=![];}):(!_0xaad5e7&&(_0x421d15=_0x11f987[_0x572ae7('0x23a2')][_0x572ae7('0xdf8')]),_0x2c43a4!==_0xaad5e7&&(_0x11f987[_0x572ae7('0x23a2')][_0x572ae7('0xdf8')]=0x1),!_0x2c43a4&&(_0x11f987['query']['page']=_0x421d15),_0x11f987['getQueues']());});function _0x4f6d6f(_0x48b01b){const _0x2b50e3=_0x1412b8;_0x11f987['count']=_0x48b01b[_0x2b50e3('0x50d')],_0x11f987[_0x2b50e3('0x2da')]=_0x48b01b?_0x2e3ca0()['keyBy'](_0x48b01b[_0x2b50e3('0xf5d')]?_0x48b01b['rows']:[],'id'):{};if(_0x48b01b[_0x2b50e3('0xf5d')]){_0x11f987[_0x2b50e3('0x150d')]=[];for(let _0xa886a5=0x0;_0xa886a5<_0x48b01b[_0x2b50e3('0xf5d')][_0x2b50e3('0x1564')];_0xa886a5++){_0x11f987[_0x2b50e3('0x150d')][_0x2b50e3('0x1fd0')](_0x48b01b[_0x2b50e3('0xf5d')][_0xa886a5]['id']);}}_0x343518();}function _0x1674d5(){const _0x2b5873=_0x1412b8;_0x11f987[_0x2b5873('0x23a2')][_0x2b5873('0x1cc8')]=(_0x11f987[_0x2b5873('0x23a2')][_0x2b5873('0xdf8')]-0x1)*_0x11f987[_0x2b5873('0x23a2')]['limit'],_0x5d6235['hasRole']('admin')?_0x11f987['promise']=_0x5bd11e[_0x2b5873('0x209c')]['get'](_0x11f987[_0x2b5873('0x23a2')],_0x4f6d6f)[_0x2b5873('0xe53')]:(_0x11f987[_0x2b5873('0x23a2')]['id']=_0x11f987[_0x2b5873('0x2a')]['id'],_0x11f987['query'][_0x2b5873('0x1aa')]='FaxQueues',_0x11f987['promise']=_0x5bd11e['userProfile'][_0x2b5873('0x241d')](_0x11f987[_0x2b5873('0x23a2')],_0x4f6d6f)['$promise']);}function _0x2ae199(_0x183e85,_0x3e2347){const _0x34e85e=_0x1412b8;_0x3e75af[_0x34e85e('0x1d4')]({'controller':_0x34e85e('0xb4f'),'controllerAs':'vm','templateUrl':_0x387711,'parent':angular['element'](_0x7f9850[_0x34e85e('0x18e5')]),'targetEvent':_0x183e85,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x3e2347,'faxQueues':_0x2e3ca0()[_0x34e85e('0x17a0')](_0x11f987['queues']),'license':null,'setting':null,'crudPermissions':_0x11f987[_0x34e85e('0x1134')]}});}function _0x280c7c(_0xf2066b,_0x130f61){const _0x17e6e8=_0x1412b8;_0x3e75af[_0x17e6e8('0x1d4')]({'controller':_0x17e6e8('0xbd8'),'controllerAs':'vm','templateUrl':_0x12aa32,'parent':angular[_0x17e6e8('0x1fcc')](_0x7f9850['body']),'targetEvent':_0xf2066b,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x130f61,'faxQueues':_0x11f987[_0x17e6e8('0x2da')]?_0x11f987[_0x17e6e8('0x2da')][_0x17e6e8('0xf5d')]:[],'realtime':![],'crudPermissions':_0x11f987[_0x17e6e8('0x1134')]}});}function _0x47dd5d(_0x5c2a51){const _0x44bcab=_0x1412b8;return _0x5bd11e[_0x44bcab('0x209c')][_0x44bcab('0x2480')](_0x5c2a51)['$promise'][_0x44bcab('0x683')](function(){const _0x6b44aa=_0x44bcab;_0x18db3f[_0x6b44aa('0x53')]({'title':_0x6b44aa('0x5c7'),'msg':_0x5c2a51[_0x6b44aa('0x60a')]?_0x5c2a51[_0x6b44aa('0x60a')]+_0x6b44aa('0x96c'):''});})[_0x44bcab('0x130a')](function(_0x2452c4){const _0x93f803=_0x44bcab;_0x18db3f['error']({'title':_0x93f803('0xb4'),'msg':_0x2452c4[_0x93f803('0x8c2')]});});}_0x3f0eed['$on'](_0x1412b8('0x4b8'),function(){const _0x5ab381=_0x1412b8;_0x40d195[_0x5ab381('0x1b9e')](_0x5ab381('0x2314')),_0x40d195['removeAllListeners']('userFaxQueue:remove'),_0x40d195['removeAllListeners'](_0x5ab381('0x1495')),_0x40d195[_0x5ab381('0x1b9e')]('user:update'),_0x40d195[_0x5ab381('0x1b9e')](_0x5ab381('0x56f')),_0x40d195[_0x5ab381('0x1b9e')]('userVoiceQueue:save');});}const _0x403fe4=_0x1c0a22;function _0x422265(){const _0x5f46fa=_0x189033;return{'status':{'registered':_0x5f46fa('0x584'),'unregistered':'red-300-fg\x20icon-close-circle','lagged':_0x5f46fa('0x1da'),'reachable':'green-300-fg\x20icon-checkbox-marked-circle','unreachable':_0x5f46fa('0x1da'),'unknown':_0x5f46fa('0xcb0')},'state':{'unknown':_0x5f46fa('0x27f9'),'not_inuse':_0x5f46fa('0x280d'),'inuse':_0x5f46fa('0x10c0'),'busy':_0x5f46fa('0x25ad'),'invalid':'grey-fg\x20icon-phone-hangup','unavailable':_0x5f46fa('0x27f9'),'ringing':_0x5f46fa('0x20f0'),'ringinuse':_0x5f46fa('0x20f0'),'onhold':'blue-300-fg\x20icon-phone-paused'},'channelStatus':{'ring':_0x5f46fa('0x20f0'),'up':_0x5f46fa('0x1133'),'hangup':_0x5f46fa('0x22be')},'channelStatusOut':{'ring':_0x5f46fa('0x2370'),'up':_0x5f46fa('0x1133'),'hangup':_0x5f46fa('0x22be')}};}const _0x3122b0=_0x422265;_0x5a468c[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0x1556')];function _0x5a468c(_0x46cc8b,_0x2d6e99,_0xc41d4b){const _0x3ae4a3=_0x189033,_0x368907=this;_0xc41d4b[_0x3ae4a3('0x1346')](),_0xc41d4b[_0x3ae4a3('0x12ac')](),_0x368907[_0x3ae4a3('0x517')]=0x0;switch(_0x2d6e99[_0x3ae4a3('0xb24')]['name']){case'app.fax.realtime.agents':_0x368907[_0x3ae4a3('0x517')]=0x0;break;case'app.fax.realtime.trunks':_0x368907[_0x3ae4a3('0x517')]=0x1;break;case _0x3ae4a3('0x24fd'):_0x368907[_0x3ae4a3('0x517')]=0x2;break;case _0x3ae4a3('0x5ce'):_0x368907['selectedTab']=0x3;break;default:_0x368907['selectedTab']=0x0,_0x2d6e99['go'](_0x3ae4a3('0x3f3'));}_0x46cc8b[_0x3ae4a3('0x186d')](_0x3ae4a3('0x9a4'),function(_0x47d6a1,_0x4e8d1){const _0x1ddfe3=_0x3ae4a3;if(_0x47d6a1!==_0x4e8d1)switch(_0x47d6a1){case 0x0:_0x2d6e99['go']('app.fax.realtime.agents');break;case 0x1:_0x2d6e99['go'](_0x1ddfe3('0x2c8'));break;case 0x2:_0x2d6e99['go'](_0x1ddfe3('0x24fd'));break;case 0x3:_0x2d6e99['go']('app.fax.realtime.accounts');break;default:_0x2d6e99['go'](_0x1ddfe3('0x3f3'));}});}const _0x527369=_0x5a468c;_0x5885f9[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$timeout',_0x189033('0x1e48'),_0x189033('0x20fe'),_0x189033('0x19fc'),_0x189033('0x56b'),_0x189033('0x1556'),'helperClasses',_0x189033('0x938'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1')];function _0x5885f9(_0x54e46c,_0x910999,_0x362c9a,_0x59902c,_0x1af578,_0x181831,_0x25aa98,_0x313b9d,_0x180117,_0x222c5a,_0x2655d0,_0x79c289){const _0x2c2469=_0x189033,_0x50f54c=this,_0x95a778=[_0x2c2469('0x13ee'),'stateRegistry','registry',_0x2c2469('0x19ac'),_0x2c2469('0x4a2'),_0x2c2469('0x1d43'),_0x2c2469('0x2598'),_0x2c2469('0x13ee')];_0x50f54c[_0x2c2469('0x11ed')]=_0x79c289['getCurrentUser'](),_0x50f54c[_0x2c2469('0x50d')]=_0x59902c['count'],_0x50f54c[_0x2c2469('0x20fe')]=_0x59902c?_0x59902c['rows']:[],_0x50f54c[_0x2c2469('0x19fc')]=_0x1af578?_0x1af578[_0x2c2469('0xf5d')]?_0x1af578[_0x2c2469('0xf5d')]:[]:[],_0x50f54c[_0x2c2469('0x23a2')]={'fields':_0x2c2469('0xa10'),'active':!![],'sort':'-updatedAt','limit':0xa,'page':0x1},_0x50f54c[_0x2c2469('0x22e0')]=_0x313b9d[_0x2c2469('0x13ee')],_0x50f54c['stateClass']=_0x313b9d['state'],_0x50f54c[_0x2c2469('0x2a')]=_0x222c5a,_0x50f54c[_0x2c2469('0x22df')]=_0x2655d0&&_0x2655d0[_0x2c2469('0x50d')]==0x1?_0x2655d0[_0x2c2469('0xf5d')][0x0]:null,_0x50f54c['crudPermissions']=_0x79c289[_0x2c2469('0x142a')](_0x50f54c[_0x2c2469('0x22df')]?_0x50f54c[_0x2c2469('0x22df')][_0x2c2469('0x1134')]:null),_0x50f54c[_0x2c2469('0x53')]=_0x4843bb,_0x50f54c['$onInit']=_0x7277c2,_0x50f54c[_0x2c2469('0x411')]=_0x304707,_0x50f54c[_0x2c2469('0x5c5')]=_0x1b658a,_0x50f54c[_0x2c2469('0xaca')]=_0x3a0469,_0x50f54c[_0x2c2469('0x2819')]=_0x1fd1e2,_0x25aa98['on'](_0x2c2469('0x2777'),_0x50f54c[_0x2c2469('0x2819')]);function _0x7277c2(){const _0x3628c5=_0x2c2469;let _0x3ac6a2;for(let _0x556cce=0x0;_0x556cce<_0x50f54c[_0x3628c5('0x20fe')][_0x3628c5('0x1564')];_0x556cce+=0x1){_0x3ac6a2=_0x2e3ca0()[_0x3628c5('0x1ce4')](_0x50f54c[_0x3628c5('0x19fc')],['id',_0x50f54c[_0x3628c5('0x20fe')][_0x556cce]['id']]),_0x3ac6a2>=0x0&&_0x2e3ca0()[_0x3628c5('0xf22')](_0x50f54c[_0x3628c5('0x20fe')][_0x556cce],_0x2e3ca0()['pick'](_0x50f54c[_0x3628c5('0x19fc')][_0x3ac6a2],_0x95a778));}}function _0x304707(_0x3cf596){const _0x13c49c=_0x2c2469;_0x362c9a['show'](_0x362c9a['alert']()[_0x13c49c('0x188f')](!![])[_0x13c49c('0xf28')](_0x13c49c('0x71a'))[_0x13c49c('0x26e3')](_0x13c49c('0x1f0'))['ok']('Ok')['targetEvent'](_0x3cf596));}function _0x1dc456(_0x59bff0,_0x235e82,_0x2d1bca){const _0x3b08b7=_0x2c2469;_0x235e82>=0x0&&_0x2e3ca0()[_0x3b08b7('0xf22')](_0x59bff0[_0x235e82],_0x2e3ca0()[_0x3b08b7('0x24d0')](_0x2d1bca,_0x95a778));}function _0x1fd1e2(_0x3bb1eb){const _0x1d2584=_0x2c2469,_0xad216d=_0x2e3ca0()[_0x1d2584('0x1ce4')](_0x50f54c[_0x1d2584('0x20fe')],['id',_0x3bb1eb['id']]),_0x5041b9=_0x2e3ca0()[_0x1d2584('0x1ce4')](_0x50f54c[_0x1d2584('0x19fc')],['id',_0x3bb1eb['id']]);_0x1dc456(_0x50f54c['trunks'],_0xad216d,_0x3bb1eb),_0x1dc456(_0x50f54c[_0x1d2584('0x19fc')],_0x5041b9,_0x3bb1eb);}let _0x3cbf24=!![],_0xbb59ee=0x1;_0x54e46c[_0x2c2469('0x186d')](_0x2c2469('0x1e1d'),function(_0x4486d0,_0x5c5e0e){const _0x55e63b=_0x2c2469;_0x3cbf24?_0x910999(function(){_0x3cbf24=![];}):(!_0x5c5e0e&&(_0xbb59ee=_0x50f54c['query'][_0x55e63b('0xdf8')]),_0x4486d0!==_0x5c5e0e&&(_0x50f54c[_0x55e63b('0x23a2')]['page']=0x1),!_0x4486d0&&(_0x50f54c[_0x55e63b('0x23a2')]['page']=_0xbb59ee),_0x50f54c['getTrunks']());});function _0x4843bb(_0x21a7f5){const _0x18e118=_0x2c2469;_0x50f54c['count']=_0x21a7f5['count'],_0x50f54c['trunks']=_0x21a7f5?_0x21a7f5[_0x18e118('0xf5d')]?_0x21a7f5[_0x18e118('0xf5d')]:[]:[],_0x7277c2();}function _0x1b658a(){const _0x1de6ea=_0x2c2469;_0x50f54c[_0x1de6ea('0x23a2')][_0x1de6ea('0x1cc8')]=(_0x50f54c[_0x1de6ea('0x23a2')]['page']-0x1)*_0x50f54c[_0x1de6ea('0x23a2')][_0x1de6ea('0x6f0')],_0x79c289[_0x1de6ea('0xca1')](_0x1de6ea('0x20c2'))?_0x50f54c[_0x1de6ea('0x1883')]=_0x181831[_0x1de6ea('0x1a93')][_0x1de6ea('0x1e6e')](_0x50f54c[_0x1de6ea('0x23a2')],_0x4843bb)[_0x1de6ea('0xe53')]:(_0x50f54c[_0x1de6ea('0x23a2')]['id']=_0x50f54c['userProfile']['id'],_0x50f54c['query'][_0x1de6ea('0x1aa')]='Trunks',_0x50f54c[_0x1de6ea('0x1883')]=_0x181831[_0x1de6ea('0x2a')][_0x1de6ea('0x241d')](_0x50f54c[_0x1de6ea('0x23a2')],_0x4843bb)[_0x1de6ea('0xe53')]);}_0x54e46c[_0x2c2469('0x26a2')](_0x2c2469('0x4b8'),function(){const _0x94a4ae=_0x2c2469;_0x25aa98[_0x94a4ae('0x1b9e')](_0x94a4ae('0x2777'));});function _0x3a0469(_0x43bf89,_0x28aca3){const _0xc53b82=_0x2c2469;_0x180117['go'](_0xc53b82('0xc28'),{'id':_0x28aca3['id']});}}const _0x585dd9=_0x5885f9;_0x128dc8[_0x189033('0x14be')]=[_0x189033('0x1398')];function _0x128dc8(_0x419e2f){const _0xe0fe97=_0x189033;_0x419e2f[_0xe0fe97('0x2598')](_0xe0fe97('0x817'),{'url':_0xe0fe97('0xf7c'),'views':{'content@app':{'templateUrl':_0x408ae7,'controller':_0xe0fe97('0x9c7')}},'resolve':{'userProfile':[_0xe0fe97('0x4b1'),'Auth',function(_0x449972,_0xa8eaf5){const _0x2d7f7c=_0xe0fe97;return _0xa8eaf5[_0x2d7f7c('0xca1')](_0x2d7f7c('0x20c2'))?null:_0x449972[_0x2d7f7c('0xed7')](_0x2d7f7c('0x1464'),{'fields':_0x2d7f7c('0x16f'),'id':_0xa8eaf5['getCurrentUser']()[_0x2d7f7c('0x2f')]});}],'userProfileSection':[_0xe0fe97('0x4b1'),_0xe0fe97('0xba1'),function(_0x5ea4dd,_0x173191){const _0x3fa28a=_0xe0fe97;return _0x173191['hasRole']('admin')?null:_0x5ea4dd[_0x3fa28a('0xed7')](_0x3fa28a('0x360'),{'fields':_0x3fa28a('0x1f47'),'userProfileId':_0x173191['getCurrentUser']()['userProfileId'],'sectionId':0x38e});}]},'authenticate':!![],'permissionId':0x38e})['state'](_0xe0fe97('0x3f3'),{'url':_0xe0fe97('0xf1a'),'controller':_0xe0fe97('0x26b2'),'templateUrl':_0x409a5a,'resolve':{'pauses':[_0xe0fe97('0x4b1'),function(_0x2cb591){const _0x5c62ab=_0xe0fe97;return _0x2cb591[_0x5c62ab('0xed7')]('pause@get',{'nolimit':!![]});}],'agents':['apiResolver',_0xe0fe97('0xba1'),function(_0x1400d6,_0x3c1e9b){const _0x12a3f1=_0xe0fe97;return _0x3c1e9b[_0x12a3f1('0xca1')]('admin')?_0x1400d6[_0x12a3f1('0xed7')](_0x12a3f1('0x25c9'),{'fields':_0x12a3f1('0x174e'),'role':_0x12a3f1('0x2327'),'sort':_0x12a3f1('0x11bc'),'nolimit':!![]}):_0x1400d6[_0x12a3f1('0xed7')](_0x12a3f1('0x191b'),{'id':_0x3c1e9b[_0x12a3f1('0x20b2')]()[_0x12a3f1('0x2f')],'section':'Agents','fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0x12a3f1('0x2327'),'sort':_0x12a3f1('0x11bc'),'nolimit':!![]});}],'userProfile':['apiResolver','Auth',function(_0x288fc5,_0x45bb6f){const _0x352a0b=_0xe0fe97;return _0x45bb6f[_0x352a0b('0xca1')](_0x352a0b('0x20c2'))?null:_0x288fc5['resolve'](_0x352a0b('0x1464'),{'fields':_0x352a0b('0x16f'),'id':_0x45bb6f[_0x352a0b('0x20b2')]()[_0x352a0b('0x2f')]});}],'userProfileSection':['apiResolver','Auth',function(_0x5ece3f,_0x1e3644){const _0xc87041=_0xe0fe97;return _0x1e3644['hasRole'](_0xc87041('0x20c2'))?null:_0x5ece3f[_0xc87041('0xed7')](_0xc87041('0x360'),{'fields':_0xc87041('0x1f47'),'userProfileId':_0x1e3644[_0xc87041('0x20b2')]()[_0xc87041('0x2f')],'sectionId':0xca});}],'rpcAgents':[_0xe0fe97('0x4b1'),function(_0x3f25d0){const _0x2c147d=_0xe0fe97;return _0x3f25d0[_0x2c147d('0xed7')](_0x2c147d('0x36a'));}]},'authenticate':!![],'permissionId':0x38e})[_0xe0fe97('0x2598')](_0xe0fe97('0x2c8'),{'url':_0xe0fe97('0x18ba'),'controller':_0xe0fe97('0x1414'),'templateUrl':_0x1cd612,'resolve':{'trunks':['apiResolver','Auth',function(_0x5c5eb9,_0x1db95e){const _0x274c69=_0xe0fe97;return _0x1db95e[_0x274c69('0xca1')](_0x274c69('0x20c2'))?_0x5c5eb9['resolve']('trunk@get',{'fields':_0x274c69('0xa10'),'active':!![],'sort':_0x274c69('0xc36'),'limit':0xa,'offset':0x0}):_0x5c5eb9[_0x274c69('0xed7')](_0x274c69('0x191b'),{'id':_0x1db95e[_0x274c69('0x20b2')]()[_0x274c69('0x2f')],'section':_0x274c69('0x485'),'fields':'id,name','active':!![],'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':[_0xe0fe97('0x4b1'),_0xe0fe97('0xba1'),function(_0x29bcda,_0x456358){const _0x416706=_0xe0fe97;return _0x456358['hasRole'](_0x416706('0x20c2'))?null:_0x29bcda[_0x416706('0xed7')](_0x416706('0x1464'),{'fields':_0x416706('0x16f'),'id':_0x456358[_0x416706('0x20b2')]()[_0x416706('0x2f')]});}],'userProfileSection':[_0xe0fe97('0x4b1'),'Auth',function(_0x3619dd,_0x43bb2a){const _0x3f2414=_0xe0fe97;return _0x43bb2a[_0x3f2414('0xca1')](_0x3f2414('0x20c2'))?null:_0x3619dd['resolve'](_0x3f2414('0x360'),{'fields':_0x3f2414('0x1f47'),'userProfileId':_0x43bb2a[_0x3f2414('0x20b2')]()['userProfileId'],'sectionId':0x3f3});}],'rpcTrunks':[_0xe0fe97('0x4b1'),function(_0x349d20){const _0x1d16b3=_0xe0fe97;return _0x349d20[_0x1d16b3('0xed7')](_0x1d16b3('0x1fa9'));}]},'authenticate':!![],'permissionId':0x38e})['state'](_0xe0fe97('0x24fd'),{'url':'/queues','controller':_0xe0fe97('0x1804'),'templateUrl':_0xdd48ca,'resolve':{'queues':[_0xe0fe97('0x4b1'),_0xe0fe97('0xba1'),function(_0x4b1436,_0x52a814){const _0x53ea13=_0xe0fe97;return _0x52a814['hasRole']('admin')?_0x4b1436[_0x53ea13('0xed7')](_0x53ea13('0x10ac'),{'type':_0x53ea13('0x1535'),'sort':_0x53ea13('0xc36'),'limit':0xa,'offset':0x0}):_0x4b1436[_0x53ea13('0xed7')](_0x53ea13('0x191b'),{'id':_0x52a814[_0x53ea13('0x20b2')]()['userProfileId'],'section':'FaxQueues','channel':_0x53ea13('0x23e9'),'type':_0x53ea13('0x1535'),'sort':_0x53ea13('0xc36'),'limit':0xa,'page':0x1});}],'userProfile':[_0xe0fe97('0x4b1'),_0xe0fe97('0xba1'),function(_0x2cc5ae,_0xa249b1){const _0x4e10bb=_0xe0fe97;return _0xa249b1[_0x4e10bb('0xca1')](_0x4e10bb('0x20c2'))?null:_0x2cc5ae[_0x4e10bb('0xed7')](_0x4e10bb('0x1464'),{'fields':_0x4e10bb('0x16f'),'id':_0xa249b1[_0x4e10bb('0x20b2')]()[_0x4e10bb('0x2f')]});}],'userProfileSection':[_0xe0fe97('0x4b1'),_0xe0fe97('0xba1'),function(_0x19ccf7,_0x23e29c){const _0x5cb2d1=_0xe0fe97;return _0x23e29c[_0x5cb2d1('0xca1')](_0x5cb2d1('0x20c2'))?null:_0x19ccf7[_0x5cb2d1('0xed7')](_0x5cb2d1('0x360'),{'fields':_0x5cb2d1('0x1f47'),'userProfileId':_0x23e29c[_0x5cb2d1('0x20b2')]()['userProfileId'],'sectionId':0x385});}],'rpcQueues':[_0xe0fe97('0x4b1'),function(_0x4c466f){const _0x2eb585=_0xe0fe97;return _0x4c466f[_0x2eb585('0xed7')](_0x2eb585('0x1b6'));}]},'authenticate':!![],'permissionId':0x38e})[_0xe0fe97('0x2598')](_0xe0fe97('0x5ce'),{'url':'/accounts','controller':_0xe0fe97('0x18b6'),'templateUrl':_0x345ee7,'resolve':{'faxAccounts':[_0xe0fe97('0x4b1'),_0xe0fe97('0xba1'),function(_0x9235a9,_0x3d685d){const _0x9a67b0=_0xe0fe97;return _0x3d685d[_0x9a67b0('0xca1')](_0x9a67b0('0x20c2'))?_0x9235a9[_0x9a67b0('0xed7')](_0x9a67b0('0x2076'),{'sort':_0x9a67b0('0xc36'),'limit':0xa,'offset':0x0}):_0x9235a9['resolve'](_0x9a67b0('0x191b'),{'id':_0x3d685d['getCurrentUser']()[_0x9a67b0('0x2f')],'section':'FaxAccounts','sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0xe0fe97('0xba1'),function(_0x32e41d,_0x34d996){const _0x29c303=_0xe0fe97;return _0x34d996[_0x29c303('0xca1')](_0x29c303('0x20c2'))?null:_0x32e41d[_0x29c303('0xed7')]('userProfile@get',{'fields':_0x29c303('0x16f'),'id':_0x34d996[_0x29c303('0x20b2')]()[_0x29c303('0x2f')]});}],'userProfileSection':['apiResolver',_0xe0fe97('0xba1'),function(_0x54fbdf,_0x2f45c2){const _0x492f3c=_0xe0fe97;return _0x2f45c2[_0x492f3c('0xca1')](_0x492f3c('0x20c2'))?null:_0x54fbdf[_0x492f3c('0xed7')](_0x492f3c('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x2f45c2['getCurrentUser']()[_0x492f3c('0x2f')],'sectionId':0x386});}],'rpcFaxAccounts':[_0xe0fe97('0x4b1'),function(_0x185fdb){const _0x1928fa=_0xe0fe97;return _0x185fdb[_0x1928fa('0xed7')](_0x1928fa('0x276'));}]},'authenticate':!![],'permissionId':0x38e});}angular[_0x189033('0x1e26')](_0x189033('0x817'),[])[_0x189033('0x272d')](_0x128dc8)[_0x189033('0x1da3')](_0x189033('0x2321'),_0x2792d4)[_0x189033('0x1da3')](_0x189033('0x14f9'),_0x2a24b9)[_0x189033('0x1da3')](_0x189033('0x133e'),_0x403fe4)[_0x189033('0x1f97')](_0x189033('0xa72'),_0x3122b0)['controller'](_0x189033('0x2766'),_0x527369)[_0x189033('0x1da3')](_0x189033('0x1f54'),_0x585dd9),_0x50e192[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x2595'),_0x189033('0x244a'),'api',_0x189033('0xba1'),_0x189033('0xace'),'setting','crudPermissions'];function _0x50e192(_0x3c01f4,_0x221cf3,_0x3a61c7,_0x4f250f,_0x3b6a21,_0x6a8d59,_0x3be6cd,_0x25de1e,_0xd9e5b6,_0x1c8b4b,_0x1d924e,_0x416f64,_0x300e74,_0x4ddc84){const _0x519789=_0x189033,_0x1bb31f=this;_0x1bb31f[_0x519789('0x11ed')]=_0x1d924e[_0x519789('0x20b2')](),_0x1bb31f['errors']=[],_0x1bb31f['setting']=_0x300e74,_0x1bb31f['license']=_0x416f64,_0x1bb31f[_0x519789('0x1134')]=_0x4ddc84,_0x1bb31f['hasModulePermissions']={},_0x1bb31f[_0x519789('0x19b2')]=_0x1bb31f[_0x519789('0x260a')]&&_0x1bb31f[_0x519789('0x260a')][_0x519789('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1bb31f['title']=_0x519789('0x166f'),_0x1bb31f['faxAccount']=angular[_0x519789('0x1a86')](_0xd9e5b6),_0x1bb31f[_0x519789('0x2595')]=_0x25de1e,_0x1bb31f[_0x519789('0x2376')]=![];!_0x1bb31f[_0x519789('0x244a')]&&(_0x1bb31f[_0x519789('0x244a')]={'waitForTheAssignedAgent':0xa,'notificationSound':!![],'queueTransferTimeout':0x12c,'agentTransferTimeout':0x12c},_0x1bb31f['title']=_0x519789('0x317'),_0x1bb31f[_0x519789('0x2376')]=!![]);_0x221cf3[_0x519789('0x7f2')]['id']&&(_0x1bb31f[_0x519789('0x244a')]['FaxAccountId']=_0x221cf3['params']['id']);_0x1bb31f[_0x519789('0x14d0')]=_0x3e2d95,_0x1bb31f[_0x519789('0x2483')]=_0x5b4a6b,_0x1bb31f[_0x519789('0x2240')]=_0x1cc258,_0x1bb31f[_0x519789('0x16b3')]=_0x50fa23,_0x1bb31f[_0x519789('0xf82')]=_0x447d44,_0x1d924e[_0x519789('0xca1')](_0x519789('0x20c2'))?_0x1c8b4b[_0x519789('0x1a93')][_0x519789('0x1e6e')]({'fields':_0x519789('0xa10'),'sort':_0x519789('0x60a')})[_0x519789('0xe53')]['then'](function(_0x4151d6){const _0xcad6a0=_0x519789;_0x1bb31f[_0xcad6a0('0x20fe')]=_0x4151d6[_0xcad6a0('0xf5d')]||[];})[_0x519789('0x130a')](function(_0x5e7602){const _0x585362=_0x519789;_0x3be6cd['error']({'title':_0x5e7602['status']?'API:'+_0x5e7602[_0x585362('0x13ee')]+'\x20-\x20'+_0x5e7602['statusText']:_0x585362('0xfd0'),'msg':_0x5e7602[_0x585362('0x5a5')]?JSON[_0x585362('0x258a')](_0x5e7602['data']):_0x5e7602[_0x585362('0x1ff0')]()});}):_0x1c8b4b[_0x519789('0x1a93')][_0x519789('0x1e6e')]({'fields':'id,name','sort':'name'})[_0x519789('0xe53')]['then'](function(_0x519aef){const _0x426226=_0x519789;_0x1bb31f[_0x426226('0x20fe')]=_0x519aef[_0x426226('0xf5d')]||[];})[_0x519789('0x683')](function(){const _0x4f87bf=_0x519789;return _0x1c8b4b[_0x4f87bf('0x22df')][_0x4f87bf('0x1e6e')]({'userProfileId':_0x1bb31f[_0x4f87bf('0x11ed')]['userProfileId'],'sectionId':0x3f3})[_0x4f87bf('0xe53')];})[_0x519789('0x683')](function(_0x30c48e){const _0x2ed158=_0x519789,_0x8268cb=_0x30c48e&&_0x30c48e[_0x2ed158('0xf5d')]?_0x30c48e[_0x2ed158('0xf5d')][0x0]:null;if(!_0x8268cb){const _0x16a2e9=[];let _0x55d163=null;_0x1bb31f[_0x2ed158('0x244a')]&&(_0x55d163=_0x2e3ca0()['find'](_0x1bb31f[_0x2ed158('0x20fe')],{'id':Number(_0x1bb31f[_0x2ed158('0x244a')]['TrunkId'])}));for(let _0x57c3f3=0x0;_0x57c3f3<_0x1bb31f[_0x2ed158('0x20fe')][_0x2ed158('0x1564')];_0x57c3f3++){_0x55d163&&_0x1bb31f[_0x2ed158('0x20fe')][_0x57c3f3]['id']===_0x55d163['id']&&(_0x1bb31f['trunks'][_0x57c3f3][_0x2ed158('0x319')]=![],_0x16a2e9[_0x2ed158('0x1fd0')](_0x1bb31f[_0x2ed158('0x20fe')][_0x57c3f3]));}_0x1bb31f['trunks']=_0x16a2e9;}else{if(!_0x8268cb[_0x2ed158('0x170')])return _0x1c8b4b[_0x2ed158('0xcf7')]['get']({'sectionId':_0x8268cb['id']})[_0x2ed158('0xe53')][_0x2ed158('0x683')](function(_0x1c6127){const _0x12acdc=_0x2ed158,_0x38d0cc=_0x2e3ca0()[_0x12acdc('0x386')](_0x1c6127[_0x12acdc('0xf5d')],function(_0x2aa644){const _0x405f89=_0x12acdc;return _0x2e3ca0()[_0x405f89('0x1c07')](_0x1bb31f[_0x405f89('0x20fe')],{'id':_0x2aa644[_0x405f89('0x832')]});});let _0x14510e=null;_0x1bb31f[_0x12acdc('0x244a')]&&(_0x14510e=_0x2e3ca0()[_0x12acdc('0x1c07')](_0x1bb31f['trunks'],{'id':Number(_0x1bb31f[_0x12acdc('0x244a')]['TrunkId'])}));if(_0x14510e&&!_0x2e3ca0()['some'](_0x38d0cc,['id',_0x14510e['id']])){const _0x138311=_0x2e3ca0()['find'](_0x1bb31f['trunks'],{'id':_0x14510e['id']});_0x138311['canSelect']=![],_0x38d0cc['push'](_0x138311);}_0x1bb31f[_0x12acdc('0x20fe')]=_0x38d0cc;});}})[_0x519789('0x130a')](function(_0x42179c){const _0x3843ab=_0x519789;_0x3be6cd[_0x3843ab('0x52a')]({'title':_0x42179c['status']?_0x3843ab('0x2168')+_0x42179c[_0x3843ab('0x13ee')]+'\x20-\x20'+_0x42179c[_0x3843ab('0x24a9')]:'SYSTEM:GETtrunks','msg':_0x42179c[_0x3843ab('0x5a5')]?JSON[_0x3843ab('0x258a')](_0x42179c[_0x3843ab('0x5a5')]):_0x42179c[_0x3843ab('0x1ff0')]()});}),_0x1d924e[_0x519789('0xca1')]('admin')?_0x1c8b4b[_0x519789('0x259b')][_0x519789('0x1e6e')]({'fields':_0x519789('0xa10'),'sort':_0x519789('0x60a')})[_0x519789('0xe53')][_0x519789('0x683')](function(_0x5e6816){const _0x436e3f=_0x519789;_0x1bb31f[_0x436e3f('0xe01')]=_0x5e6816['rows']||[];})[_0x519789('0x130a')](function(_0x40d559){const _0x1f5939=_0x519789;_0x3be6cd[_0x1f5939('0x52a')]({'title':_0x40d559[_0x1f5939('0x13ee')]?_0x1f5939('0x2168')+_0x40d559[_0x1f5939('0x13ee')]+_0x1f5939('0xbf6')+_0x40d559[_0x1f5939('0x24a9')]:'SYSTEM:GET_LISTS','msg':_0x40d559['data']?JSON[_0x1f5939('0x258a')](_0x40d559['data']):_0x40d559[_0x1f5939('0x1ff0')]()});}):_0x1c8b4b[_0x519789('0x259b')][_0x519789('0x1e6e')]({'fields':_0x519789('0xa10'),'sort':_0x519789('0x60a')})['$promise'][_0x519789('0x683')](function(_0x1f4ad3){const _0x1fb327=_0x519789;_0x1bb31f[_0x1fb327('0xe01')]=_0x1f4ad3[_0x1fb327('0xf5d')]||[];})[_0x519789('0x683')](function(){const _0x5d4e24=_0x519789;return _0x1c8b4b[_0x5d4e24('0x22df')][_0x5d4e24('0x1e6e')]({'userProfileId':_0x1bb31f[_0x5d4e24('0x11ed')]['userProfileId'],'sectionId':0x12d})[_0x5d4e24('0xe53')];})[_0x519789('0x683')](function(_0x38b426){const _0x18b3dd=_0x519789,_0x1e8ab6=_0x38b426&&_0x38b426['rows']?_0x38b426[_0x18b3dd('0xf5d')][0x0]:null;if(!_0x1e8ab6){const _0x3638c7=[];let _0x49bf72=null;_0x1bb31f['faxAccount']&&(_0x49bf72=_0x2e3ca0()[_0x18b3dd('0x1c07')](_0x1bb31f[_0x18b3dd('0xe01')],{'id':Number(_0x1bb31f[_0x18b3dd('0x244a')][_0x18b3dd('0x1e4f')])}));for(let _0x45c0ac=0x0;_0x45c0ac<_0x1bb31f[_0x18b3dd('0xe01')][_0x18b3dd('0x1564')];_0x45c0ac++){_0x49bf72&&_0x1bb31f[_0x18b3dd('0xe01')][_0x45c0ac]['id']===_0x49bf72['id']&&(_0x1bb31f['lists'][_0x45c0ac]['canSelect']=![],_0x3638c7[_0x18b3dd('0x1fd0')](_0x1bb31f['lists'][_0x45c0ac]));}_0x1bb31f['lists']=_0x3638c7;}else{if(!_0x1e8ab6[_0x18b3dd('0x170')])return _0x1c8b4b[_0x18b3dd('0xcf7')][_0x18b3dd('0x1e6e')]({'sectionId':_0x1e8ab6['id']})[_0x18b3dd('0xe53')]['then'](function(_0x1a9747){const _0x29ead8=_0x18b3dd,_0x446f20=_0x2e3ca0()['map'](_0x1a9747[_0x29ead8('0xf5d')],function(_0x174d84){const _0x3a91cf=_0x29ead8;return _0x2e3ca0()['find'](_0x1bb31f[_0x3a91cf('0xe01')],{'id':_0x174d84[_0x3a91cf('0x832')]});});let _0x3bd39d=null;_0x1bb31f[_0x29ead8('0x244a')]&&(_0x3bd39d=_0x2e3ca0()[_0x29ead8('0x1c07')](_0x1bb31f[_0x29ead8('0xe01')],{'id':Number(_0x1bb31f[_0x29ead8('0x244a')][_0x29ead8('0x1e4f')])}));if(_0x3bd39d&&!_0x2e3ca0()['some'](_0x446f20,['id',_0x3bd39d['id']])){const _0x27b6ee=_0x2e3ca0()['find'](_0x1bb31f[_0x29ead8('0xe01')],{'id':_0x3bd39d['id']});_0x27b6ee[_0x29ead8('0x319')]=![],_0x446f20['push'](_0x27b6ee);}_0x1bb31f[_0x29ead8('0xe01')]=_0x446f20;});}})[_0x519789('0x130a')](function(_0x84cd2c){const _0x347d2e=_0x519789;_0x3be6cd[_0x347d2e('0x52a')]({'title':_0x84cd2c['status']?_0x347d2e('0x2168')+_0x84cd2c[_0x347d2e('0x13ee')]+'\x20-\x20'+_0x84cd2c['statusText']:'SYSTEM:GETlists','msg':_0x84cd2c[_0x347d2e('0x5a5')]?JSON[_0x347d2e('0x258a')](_0x84cd2c[_0x347d2e('0x5a5')]):_0x84cd2c[_0x347d2e('0x1ff0')]()});});function _0x3e2d95(){const _0x272f78=_0x519789;_0x1bb31f[_0x272f78('0x17f')]=[],_0x1c8b4b['faxAccount'][_0x272f78('0x6ca')](_0x1bb31f[_0x272f78('0x244a')])[_0x272f78('0xe53')][_0x272f78('0x683')](function(_0x596a34){const _0x4217c8=_0x272f78;_0x1bb31f[_0x4217c8('0x2595')][_0x4217c8('0x1167')](_0x596a34['toJSON']()),_0x3be6cd[_0x4217c8('0x53')]({'title':_0x4217c8('0x12ea'),'msg':_0x1bb31f[_0x4217c8('0x244a')]['name']?_0x1bb31f['faxAccount'][_0x4217c8('0x60a')]+_0x4217c8('0x14b5'):''}),_0x447d44(_0x596a34);})['catch'](function(_0x4a8684){const _0x32fa8c=_0x272f78;if(_0x4a8684[_0x32fa8c('0x5a5')]&&_0x4a8684[_0x32fa8c('0x5a5')][_0x32fa8c('0x17f')]&&_0x4a8684[_0x32fa8c('0x5a5')][_0x32fa8c('0x17f')][_0x32fa8c('0x1564')]){_0x1bb31f['errors']=_0x4a8684[_0x32fa8c('0x5a5')][_0x32fa8c('0x17f')]||[{'message':_0x4a8684[_0x32fa8c('0x1ff0')](),'type':'api.faxAccount.save'}];for(let _0x40e2f5=0x0;_0x40e2f5<_0x4a8684[_0x32fa8c('0x5a5')][_0x32fa8c('0x17f')][_0x32fa8c('0x1564')];_0x40e2f5+=0x1){_0x3be6cd[_0x32fa8c('0x52a')]({'title':_0x4a8684[_0x32fa8c('0x5a5')][_0x32fa8c('0x17f')][_0x40e2f5][_0x32fa8c('0xcf0')],'msg':_0x4a8684[_0x32fa8c('0x5a5')]['errors'][_0x40e2f5][_0x32fa8c('0x8c2')]});}}else _0x3be6cd[_0x32fa8c('0x52a')]({'title':_0x4a8684['status']?_0x32fa8c('0x2168')+_0x4a8684['status']+_0x32fa8c('0xbf6')+_0x4a8684[_0x32fa8c('0x24a9')]:_0x32fa8c('0xb2c'),'msg':_0x4a8684[_0x32fa8c('0x5a5')]?JSON[_0x32fa8c('0x258a')](_0x4a8684['data'][_0x32fa8c('0x8c2')]):_0x4a8684[_0x32fa8c('0x1ff0')]()});});}function _0x5b4a6b(){const _0x4cdc9c=_0x519789;_0x1bb31f[_0x4cdc9c('0x17f')]=[],_0x1c8b4b[_0x4cdc9c('0x244a')][_0x4cdc9c('0xcd')](_0x1bb31f[_0x4cdc9c('0x244a')])[_0x4cdc9c('0xe53')][_0x4cdc9c('0x683')](function(_0x1ef5ab){const _0x5b4d3d=_0x4cdc9c,_0x38b6b8=_0x2e3ca0()['find'](_0x1bb31f[_0x5b4d3d('0x2595')],{'id':_0x1ef5ab['id']});_0x38b6b8&&_0x2e3ca0()[_0x5b4d3d('0xf22')](_0x38b6b8,_0x2e3ca0()['pick'](_0x1ef5ab[_0x5b4d3d('0x24e1')](),_0x2e3ca0()['keys'](_0x38b6b8))),_0x3be6cd[_0x5b4d3d('0x53')]({'title':_0x5b4d3d('0x1098'),'msg':_0x1bb31f[_0x5b4d3d('0x244a')][_0x5b4d3d('0x60a')]?_0x1bb31f[_0x5b4d3d('0x244a')]['name']+_0x5b4d3d('0xf59'):''}),_0x447d44(_0x1ef5ab);})['catch'](function(_0x5d5a7b){const _0x5d2ef3=_0x4cdc9c;if(_0x5d5a7b['data']&&_0x5d5a7b[_0x5d2ef3('0x5a5')]['errors']&&_0x5d5a7b['data'][_0x5d2ef3('0x17f')][_0x5d2ef3('0x1564')]){_0x1bb31f[_0x5d2ef3('0x17f')]=_0x5d5a7b[_0x5d2ef3('0x5a5')][_0x5d2ef3('0x17f')]||[{'message':_0x5d5a7b[_0x5d2ef3('0x1ff0')](),'type':_0x5d2ef3('0xfc1')}];for(let _0x255f73=0x0;_0x255f73<_0x5d5a7b[_0x5d2ef3('0x5a5')][_0x5d2ef3('0x17f')][_0x5d2ef3('0x1564')];_0x255f73++){_0x3be6cd[_0x5d2ef3('0x52a')]({'title':_0x5d5a7b['data'][_0x5d2ef3('0x17f')][_0x255f73][_0x5d2ef3('0xcf0')],'msg':_0x5d5a7b[_0x5d2ef3('0x5a5')]['errors'][_0x255f73][_0x5d2ef3('0x8c2')]});}}else _0x3be6cd[_0x5d2ef3('0x52a')]({'title':_0x5d5a7b['status']?_0x5d2ef3('0x2168')+_0x5d5a7b[_0x5d2ef3('0x13ee')]+'\x20-\x20'+_0x5d5a7b[_0x5d2ef3('0x24a9')]:_0x5d2ef3('0xfc1'),'msg':_0x5d5a7b['data']?JSON[_0x5d2ef3('0x258a')](_0x5d5a7b[_0x5d2ef3('0x5a5')]['message']):_0x5d5a7b[_0x5d2ef3('0x1ff0')]()});});}function _0x1cc258(_0x5c5448){const _0x5bc301=_0x519789;_0x1bb31f[_0x5bc301('0x17f')]=[];const _0x3d7747=_0x4f250f[_0x5bc301('0x1c6f')]()['title']('Are\x20you\x20sure?')[_0x5bc301('0xa6a')](_0x5bc301('0xd42'))['ariaLabel'](_0x5bc301('0x23e6'))['ok'](_0x5bc301('0x2307'))[_0x5bc301('0x19fb')](_0x5bc301('0x253a'))['targetEvent'](_0x5c5448);_0x4f250f[_0x5bc301('0x1d4')](_0x3d7747)['then'](function(){const _0xe36e60=_0x5bc301;_0x1c8b4b[_0xe36e60('0x244a')][_0xe36e60('0xd7e')]({'id':_0x1bb31f['faxAccount']['id']})[_0xe36e60('0xe53')]['then'](function(){const _0x5e02d9=_0xe36e60;_0x2e3ca0()[_0x5e02d9('0x3ec')](_0x1bb31f[_0x5e02d9('0x2595')],{'id':_0x1bb31f[_0x5e02d9('0x244a')]['id']}),_0x3be6cd[_0x5e02d9('0x53')]({'title':_0x5e02d9('0x86b'),'msg':(_0x1bb31f[_0x5e02d9('0x244a')][_0x5e02d9('0x60a')]||_0x5e02d9('0x244a'))+_0x5e02d9('0x194d')}),_0x447d44(_0x1bb31f[_0x5e02d9('0x244a')]);})['catch'](function(_0x6e5058){const _0x5abb3e=_0xe36e60;if(_0x6e5058[_0x5abb3e('0x5a5')]&&_0x6e5058[_0x5abb3e('0x5a5')][_0x5abb3e('0x17f')]&&_0x6e5058[_0x5abb3e('0x5a5')]['errors'][_0x5abb3e('0x1564')]){_0x1bb31f[_0x5abb3e('0x17f')]=_0x6e5058[_0x5abb3e('0x5a5')]['errors']||[{'message':_0x6e5058['toString'](),'type':'api.faxAccount.delete'}];for(let _0xf43096=0x0;_0xf43096<_0x6e5058[_0x5abb3e('0x5a5')]['errors'][_0x5abb3e('0x1564')];_0xf43096++){_0x3be6cd['error']({'title':_0x6e5058[_0x5abb3e('0x5a5')][_0x5abb3e('0x17f')][_0xf43096][_0x5abb3e('0xcf0')],'msg':_0x6e5058[_0x5abb3e('0x5a5')][_0x5abb3e('0x17f')][_0xf43096][_0x5abb3e('0x8c2')]});}}else _0x3be6cd[_0x5abb3e('0x52a')]({'title':_0x6e5058['status']?'API:'+_0x6e5058[_0x5abb3e('0x13ee')]+_0x5abb3e('0xbf6')+_0x6e5058['statusText']:'api.faxAccount.delete','msg':_0x6e5058[_0x5abb3e('0x5a5')]?JSON[_0x5abb3e('0x258a')](_0x6e5058[_0x5abb3e('0x5a5')][_0x5abb3e('0x8c2')]):_0x6e5058[_0x5abb3e('0x8c2')]||_0x6e5058[_0x5abb3e('0x1ff0')]()});});},function(){});}function _0x50fa23(_0x547c78){return _0x547c78===null?undefined:new Date(_0x547c78);}function _0x447d44(_0x36b802){const _0x1aad93=_0x519789;_0x4f250f[_0x1aad93('0x1715')](_0x36b802);}}const _0x181790=_0x50e192,_0x5bfc0e=_0x180212['p']+_0x189033('0x34f'),_0x262686=_0x180212['p']+_0x189033('0x5d1'),_0x3dd51e=_0x180212['p']+_0x189033('0xf3c'),_0x4e2481=_0x180212['p']+_0x189033('0x1a3'),_0x151f38=_0x180212['p']+_0x189033('0x1188'),_0x33a7b1=_0x180212['p']+'src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/noop/dialog.html/dialog.html',_0x26dddc=_0x180212['p']+'src/js/modules/main/apps/fax/views/faxAccounts/edit/apps/queue/dialog.html/dialog.html',_0x4ac8bd=_0x180212['p']+_0x189033('0x24bd'),_0xbea2fe=_0x180212['p']+_0x189033('0xd55');_0x88cb05[_0x189033('0x14be')]=[_0x189033('0x56b'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0xba1')];const _0x3b5284={'agent':_0x5bfc0e,'close':_0x262686,'gotoif':_0x3dd51e,'gotop':_0x4e2481,'interval':_0x151f38,'noop':_0x33a7b1,'queue':_0x26dddc,'system':_0x4ac8bd,'tag':_0xbea2fe};function _0x88cb05(_0x44e86e,_0x41d9c4,_0x1de946,_0x31ea4d,_0x13aba7){const _0x479ba0=_0x189033,_0x445863=this;_0x445863[_0x479ba0('0x11ed')]=_0x13aba7[_0x479ba0('0x20b2')](),_0x445863[_0x479ba0('0x244a')]={},_0x445863[_0x479ba0('0xd02')]={'count':0x0,'rows':[]},_0x445863[_0x479ba0('0x252')]=[],_0x445863[_0x479ba0('0x1134')],_0x445863[_0x479ba0('0x23a2')]={'sort':'priority'},_0x445863[_0x479ba0('0x346')]=_0x2e3ca0()[_0x479ba0('0xfae')](_0x2e3ca0()[_0x479ba0('0x742')]([{'app':'Interval','appType':'interval','types':['always',_0x479ba0('0xbf0'),_0x479ba0('0x2335')],'fields':[],'isApp':![]},{'app':'noop','appType':_0x479ba0('0x1126'),'type':'noop','icon':_0x479ba0('0x7ee'),'interval':'*,*,*,*','required':!![],'isApp':!![],'fields':[{'title':_0x479ba0('0x75d'),'name':_0x479ba0('0x1c6b'),'type':_0x479ba0('0x1bcd'),'param':0x0}]},{'app':'system','appType':_0x479ba0('0x24f2'),'type':_0x479ba0('0x24f2'),'icon':_0x479ba0('0x7ee'),'interval':_0x479ba0('0x1b54'),'required':!![],'isApp':!![],'extraApi':[{'name':'variables','field':{'name':_0x479ba0('0x26e0'),'key':_0x479ba0('0x60a')},'route':_0x479ba0('0x26e0'),'filters':{'fields':_0x479ba0('0xa10'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':'Command','name':'command','type':'text','required':!![],'param':0x0},{'title':_0x479ba0('0xde7'),'name':_0x479ba0('0x26e0'),'type':'apiselect','values':_0x479ba0('0x220b'),'value':'variable.name','option':_0x479ba0('0x2277'),'defaultValues':[{'value':'\x27\x27','option':_0x479ba0('0x2749')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':'gotop','appType':_0x479ba0('0x1da0'),'type':_0x479ba0('0x27fe'),'icon':_0x479ba0('0x7ee'),'interval':_0x479ba0('0x1b54'),'isApp':!![],'fields':[{'title':_0x479ba0('0x19b4'),'name':_0x479ba0('0xe1e'),'type':_0x479ba0('0x121f'),'required':!![],'min':0x0,'param':0x0}]},{'app':_0x479ba0('0xc33'),'appType':_0x479ba0('0xc33'),'type':_0x479ba0('0xc33'),'icon':_0x479ba0('0x7ee'),'interval':_0x479ba0('0x1b54'),'isApp':!![],'fields':[{'title':'Condition','name':_0x479ba0('0x168e'),'type':_0x479ba0('0x1bcd'),'required':!![],'param':0x0},{'title':_0x479ba0('0x27e5'),'name':_0x479ba0('0x27e5'),'type':_0x479ba0('0x121f'),'min':0x1,'required':!![],'param':0x1},{'title':_0x479ba0('0x1813'),'name':_0x479ba0('0x1813'),'type':_0x479ba0('0x121f'),'min':0x1,'required':!![],'param':0x2}]},{'app':_0x479ba0('0x660'),'appType':_0x479ba0('0x660'),'foreignKey':_0x479ba0('0x26cc'),'type':_0x479ba0('0x660'),'icon':'icon-apps','interval':_0x479ba0('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x479ba0('0x2da'),'field':{'name':'queue','key':_0x479ba0('0x60a')},'route':_0x479ba0('0x209c'),'filters':{'fields':_0x479ba0('0x2035'),'sort':_0x479ba0('0x60a'),'nolimit':!![]},'permissions':{'section':0x385}}],'fields':[{'title':_0x479ba0('0x1fa'),'name':_0x479ba0('0x660'),'type':_0x479ba0('0x1aae'),'values':_0x479ba0('0x2da'),'value':_0x479ba0('0x2543'),'option':_0x479ba0('0x2543'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':_0x479ba0('0xa09'),'name':_0x479ba0('0x1668'),'type':_0x479ba0('0x121f'),'max':0x20c49b,'min':0x0,'defaultValue':0x12c,'required':!![],'param':0x1}]},{'app':'agent','appType':'agent','type':_0x479ba0('0x2327'),'foreignKey':_0x479ba0('0x10c5'),'icon':_0x479ba0('0x7ee'),'interval':_0x479ba0('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x479ba0('0x756'),'field':{'name':_0x479ba0('0x2327'),'key':'name'},'route':_0x479ba0('0xc96'),'filters':{'fields':_0x479ba0('0xa10'),'sort':_0x479ba0('0x60a'),'role':_0x479ba0('0x2327'),'nolimit':!![]},'permissions':{'section':0xca}}],'fields':[{'title':'Agent','name':'agent','type':_0x479ba0('0x1aae'),'values':_0x479ba0('0x756'),'value':_0x479ba0('0x1ed0'),'option':_0x479ba0('0x1ed0'),'required':!![],'param':0x0},{'title':_0x479ba0('0xa09'),'name':_0x479ba0('0x1668'),'type':'number','max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':_0x479ba0('0x12b0'),'appType':_0x479ba0('0x12b0'),'type':_0x479ba0('0x12b0'),'icon':_0x479ba0('0x7ee'),'interval':_0x479ba0('0x1b54'),'isApp':!![],'fields':[{'title':_0x479ba0('0x11d4'),'name':_0x479ba0('0x43f'),'type':_0x479ba0('0x1bcd'),'required':!![],'param':0x0}]},{'app':_0x479ba0('0x270'),'appType':_0x479ba0('0x270'),'type':_0x479ba0('0x270'),'foreignKey':_0x479ba0('0xb6d'),'icon':_0x479ba0('0x7ee'),'interval':_0x479ba0('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x479ba0('0x1ce6'),'field':{'name':'tag','key':_0x479ba0('0x60a')},'route':_0x479ba0('0x270'),'filters':{'fields':_0x479ba0('0xa10'),'sort':_0x479ba0('0x60a'),'nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x479ba0('0x1e'),'name':_0x479ba0('0x270'),'type':_0x479ba0('0x1aae'),'values':_0x479ba0('0x1ce6'),'value':_0x479ba0('0x1402'),'option':_0x479ba0('0x1402'),'required':!![],'param':0x0}]}],[_0x479ba0('0x1d75')]),{'isApp':![]}),_0x445863['list']={'group':{'name':_0x479ba0('0x11bf'),'pull':_0x479ba0('0x147f')},'animation':0x64,'sort':![]},_0x445863['applications']={'group':{'name':_0x479ba0('0x489'),'put':'opt1'},'animation':0x64,'onAdd':function(_0x120339){const _0x5ac8c4=_0x479ba0;_0x475761(_0x120339,_0x120339[_0x5ac8c4('0x1ce1')]);},'onSort':function(){_0x55ba43();}},_0x445863[_0x479ba0('0x12f3')]=_0x42737a,_0x445863[_0x479ba0('0x26eb')]=_0x5cb2ff,_0x445863[_0x479ba0('0x70d')]=_0x57dca0,_0x445863['editFaxAccountApp']=_0x475761,_0x445863[_0x479ba0('0x24f7')]=_0x439c45,_0x445863[_0x479ba0('0xb1a')]=_0x25df15,_0x445863['deleteSelectedFaxAccountApps']=_0x4d19e1,_0x445863[_0x479ba0('0x13f5')]=_0x55ba43,_0x445863[_0x479ba0('0x14a')]=_0x2c8034;function _0x42737a(_0x27ea74,_0x2f5ed2){const _0x56d4da=_0x479ba0;_0x445863[_0x56d4da('0x244a')]=_0x27ea74,_0x445863[_0x56d4da('0x1134')]=typeof _0x2f5ed2!==_0x56d4da('0x1867')?_0x2f5ed2:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x445863[_0x56d4da('0x2146')][_0x56d4da('0x120b')]=!_0x445863[_0x56d4da('0x1134')][_0x56d4da('0x1978')]?!![]:![],_0x445863[_0x56d4da('0x23a2')]['id']=_0x27ea74['id'],_0x445863[_0x56d4da('0x23a2')]['isApp']=!![],_0x445863[_0x56d4da('0x23a2')]['nolimit']=!![],_0x445863['getFaxAccountApps'](),_0x445863[_0x56d4da('0x14a')]();}function _0x5cb2ff(_0x873e67,_0x3ca707,_0x2a22fb){const _0x381249=_0x479ba0,_0xb7ae23=_0x41d9c4['confirm']()[_0x381249('0xf28')](_0x381249('0x421'))[_0x381249('0x26e3')](_0x381249('0xed5')+_0x873e67[_0x381249('0x1d75')]+_0x381249('0x20f1')+_0x381249('0x1ee7'))[_0x381249('0x1040')](_0x381249('0x1312'))[_0x381249('0xe42')](_0x2a22fb)['ok']('OK')[_0x381249('0x19fb')](_0x381249('0x16b8'));_0x41d9c4[_0x381249('0x1d4')](_0xb7ae23)[_0x381249('0x683')](function(){const _0x3a2ffe=_0x381249;_0x445863[_0x3a2ffe('0xd02')]['rows'][_0x3a2ffe('0x2040')](_0x3ca707,0x1),_0x55ba43();},function(){const _0x3eb1f4=_0x381249;console[_0x3eb1f4('0x1b2b')](_0x3eb1f4('0x16b8'));});}function _0x475761(_0x3ab645,_0x1646e7){const _0x1a7759=_0x479ba0;if(_0x445863[_0x1a7759('0xd02')][_0x1a7759('0xf5d')]['length']){const _0x5e962d=_0x445863[_0x1a7759('0xd02')][_0x1a7759('0xf5d')][_0x1646e7]?_0x445863['faxAccountApps']['rows'][_0x1646e7]:_0x445863[_0x1a7759('0xd02')]['rows'][0x0],_0x32f276=(_0x5e962d[_0x1a7759('0x11f3')]||_0x5e962d[_0x1a7759('0x1d75')])[_0x1a7759('0x93a')]();_0x41d9c4[_0x1a7759('0x1d4')]({'controller':_0x1a7759('0x17f5')+_0x32f276+_0x1a7759('0x9e4'),'controllerAs':'vm','templateUrl':_0x3b5284[_0x32f276],'parent':angular[_0x1a7759('0x1fcc')](_0x1de946[_0x1a7759('0x18e5')]),'targetEvent':_0x3ab645,'clickOutsideToClose':!![],'locals':{'faxAccountApp':_0x5e962d,'faxAccount':_0x445863[_0x1a7759('0x244a')],'crudPermissions':_0x445863['crudPermissions']}})[_0x1a7759('0x683')](function(_0x397d47){const _0x127273=_0x1a7759;_0x397d47&&(_0x397d47['id']?_0x445863[_0x127273('0xd02')][_0x127273('0xf5d')][_0x1646e7]=_0x397d47:_0x445863[_0x127273('0xd02')][_0x127273('0xf5d')][_0x127273('0x2040')](_0x1646e7,0x0,_0x397d47),_0x55ba43());})['catch'](function(_0x2931a7){const _0x8dab26=_0x1a7759;_0x2931a7&&_0x31ea4d[_0x8dab26('0x52a')]({'title':_0x2931a7[_0x8dab26('0x13ee')]?'API:'+_0x2931a7[_0x8dab26('0x13ee')]+_0x8dab26('0xbf6')+_0x2931a7[_0x8dab26('0x24a9')]:_0x8dab26('0xf1b'),'msg':_0x2931a7[_0x8dab26('0x5a5')]?JSON['stringify'](_0x2931a7[_0x8dab26('0x5a5')]):_0x2931a7[_0x8dab26('0x1ff0')]()});});}}function _0x439c45(_0x3a08f7,_0xc8be9c){const _0x5b2997=_0x479ba0;if(_0x445863[_0x5b2997('0xd02')][_0x5b2997('0xf5d')]['length']){const _0x20d5b8=_0x445863[_0x5b2997('0xd02')]['rows'][_0xc8be9c]?_0x445863['faxAccountApps'][_0x5b2997('0xf5d')][_0xc8be9c]:_0x445863['faxAccountApps'][_0x5b2997('0xf5d')][0x0];_0x41d9c4['show']({'controller':_0x5b2997('0x27e9'),'controllerAs':'vm','templateUrl':_0x151f38,'parent':angular['element'](_0x1de946[_0x5b2997('0x18e5')]),'targetEvent':_0x3a08f7,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0x20d5b8[_0x5b2997('0x115c')],'IntervalId':_0x20d5b8['IntervalId'],'application':!![]},'intervals':[],'crudPermissions':_0x445863[_0x5b2997('0x1134')]}})['then'](function(_0x4187bf){const _0x39765a=_0x5b2997;_0x4187bf&&(_0x20d5b8['interval']=_0x4187bf[_0x39765a('0x115c')]||'*,*,*,*',_0x20d5b8['IntervalId']=_0x4187bf[_0x39765a('0x5ae')]||null,_0x55ba43());});}}function _0x55ba43(){const _0x1bef07=_0x479ba0;let _0x3a64c5=0x1,_0x303e37=[];for(let _0x38bac3=0x0;_0x38bac3<_0x445863[_0x1bef07('0xd02')][_0x1bef07('0xf5d')]['length'];_0x38bac3++){const _0x3f2490=_0x445863[_0x1bef07('0xd02')][_0x1bef07('0xf5d')][_0x38bac3],_0xe3af2f=[],_0x2f7713=[];_0x3f2490[_0x1bef07('0xe98')]=_0x3f2490[_0x1bef07('0x115c')]!==_0x1bef07('0x1b54')?[_0x3f2490['interval']]:_0x3f2490[_0x1bef07('0x5ae')]?_0x2e3ca0()[_0x1bef07('0x386')](_0x2e3ca0()[_0x1bef07('0x25')](_0x445863[_0x1bef07('0xe98')][_0x1bef07('0xf5d')],{'IntervalId':_0x3f2490[_0x1bef07('0x5ae')]}),_0x1bef07('0x115c')):[],_0x3f2490['context']=_0x445863['faxAccount'][_0x1bef07('0x22d3')],_0x3f2490['exten']=_0x445863[_0x1bef07('0x244a')][_0x1bef07('0x1a5b')],_0x3f2490[_0x1bef07('0xcf0')]&&(_0x3f2490[_0x1bef07('0xcf0')]=_0x3f2490[_0x1bef07('0xcf0')][_0x1bef07('0x93a')]()),_0x3f2490['priority']=_0xe3af2f[_0x1bef07('0x1564')]?_0x2e3ca0()['last'](_0xe3af2f)[_0x1bef07('0xe1e')]+0x1:_0x3a64c5,_0x3a64c5=(_0x2f7713[_0x1bef07('0x1564')]?_0x2e3ca0()['last'](_0x2f7713)[_0x1bef07('0xe1e')]:_0x3f2490[_0x1bef07('0xe1e')])+0x1,_0x303e37=_0x2e3ca0()['concat'](_0x303e37,_0xe3af2f,[_0x3f2490],_0x2f7713);}_0x44e86e[_0x1bef07('0x244a')]['addApplications']({'id':_0x445863['faxAccount']['id']},_0x2e3ca0()[_0x1bef07('0x742')](_0x303e37,_0x1bef07('0xe1e')))['$promise']['then'](function(_0x5aa068){const _0x3283a9=_0x1bef07;_0x445863['faxAccountApps'][_0x3283a9('0xf5d')]=_0x5aa068[_0x3283a9('0xf5d')];})['catch'](function(_0x247060){const _0x4b7be5=_0x1bef07;console[_0x4b7be5('0x52a')](_0x247060);});}function _0x5ec6e5(_0x28fe99){_0x445863['faxAccountApps']=_0x28fe99||{'count':0x0,'rows':[]};}function _0x2c8034(){const _0x172059=_0x479ba0;return _0x44e86e[_0x172059('0x115c')][_0x172059('0x1e6e')]({'fields':'id,interval,IntervalId'})[_0x172059('0xe53')][_0x172059('0x683')](function(_0x1998e7){const _0x753725=_0x172059;_0x445863[_0x753725('0xe98')]=_0x1998e7;})[_0x172059('0x130a')](function(_0x2c62af){console['error'](_0x2c62af);});}function _0x57dca0(){const _0x45dcef=_0x479ba0;_0x445863['promise']=_0x44e86e[_0x45dcef('0x244a')]['getApplications'](_0x445863[_0x45dcef('0x23a2')],_0x5ec6e5)[_0x45dcef('0xe53')];}function _0x25df15(_0x5c3a77){const _0x40da66=_0x479ba0;_0x2e3ca0()[_0x40da66('0x3ec')](_0x445863[_0x40da66('0xd02')][_0x40da66('0xf5d')],{'id':_0x5c3a77['id']}),_0x55ba43(),_0x31ea4d[_0x40da66('0x53')]({'title':_0x40da66('0x1f71'),'msg':_0x5c3a77['app']?_0x5c3a77[_0x40da66('0x1d75')]+'\x20has\x20been\x20deleted!':''});}function _0x4d19e1(_0x113c53){const _0x38beea=_0x479ba0,_0x5bcf1b=_0x41d9c4[_0x38beea('0x1c6f')]()[_0x38beea('0xf28')](_0x38beea('0x188'))['htmlContent'](''+_0x445863['selectedFaxAccountApps'][_0x38beea('0x1564')]+_0x38beea('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel']('delete\x20applications')[_0x38beea('0xe42')](_0x113c53)['ok']('OK')[_0x38beea('0x19fb')](_0x38beea('0x16b8'));_0x41d9c4[_0x38beea('0x1d4')](_0x5bcf1b)[_0x38beea('0x683')](function(){const _0x25c65d=_0x38beea;_0x445863[_0x25c65d('0x252')][_0x25c65d('0x1299')](function(_0x140abc){const _0x4b75b1=_0x25c65d;_0x2e3ca0()['remove'](_0x445863[_0x4b75b1('0xd02')][_0x4b75b1('0xf5d')],{'id':_0x140abc['id']});}),_0x445863[_0x25c65d('0x252')]=[],_0x55ba43();});}}const _0x463248=_0x88cb05;_0x565227[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x244a'),_0x189033('0x2595'),'realtime',_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x565227(_0x3749ec,_0x4357d3,_0x5eb8f4,_0x3fa771,_0x395592,_0x2bd715,_0x19217c,_0x541926,_0x2681be,_0x123928){const _0x4a2058=_0x189033,_0x315ebb=this;_0x315ebb['currentUser']=_0x2681be[_0x4a2058('0x20b2')](),_0x315ebb['faxAccount']=_0x395592,_0x315ebb[_0x4a2058('0x1134')]=_0x123928,_0x315ebb[_0x4a2058('0x2c9')]=_0x19217c,_0x315ebb[_0x4a2058('0x1996')]=[],_0x315ebb[_0x4a2058('0x1c47')]=[],_0x315ebb[_0x4a2058('0x1378')]=[],_0x315ebb[_0x4a2058('0x125e')]=[],_0x315ebb[_0x4a2058('0x23a7')]=[],_0x315ebb[_0x4a2058('0x2106')]=![],_0x315ebb[_0x4a2058('0x1dd2')]=_0x2ff71f,_0x315ebb[_0x4a2058('0xa5f')]=_0x3690ca,_0x315ebb[_0x4a2058('0xf82')]=_0x1bb6c4,_0x315ebb[_0x4a2058('0x169f')]={'readOnly':!_0x315ebb[_0x4a2058('0x1134')][_0x4a2058('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x4a2058('0x60a'),'line1':'fullname','line2':[_0x4a2058('0x60a'),'internal'],'line3':'','labelAll':_0x541926[_0x4a2058('0x2728')]('FAX.ALL_AGENTS'),'labelSelected':_0x541926[_0x4a2058('0x2728')](_0x4a2058('0x1e86')),'transferCallback':function(){const _0xea84b3=_0x4a2058,_0x5657bd=_0x2e3ca0()['xorBy'](_0x315ebb[_0xea84b3('0x23a7')],_0x315ebb['selectedItems'],'id');_0x315ebb[_0xea84b3('0x2106')]=_0x2e3ca0()[_0xea84b3('0x173f')](_0x5657bd)?![]:!![];}};function _0x2ff71f(){const _0x4714ff=_0x4a2058;return _0x2681be[_0x4714ff('0xca1')](_0x4714ff('0x20c2'))?_0xe2a09()[_0x4714ff('0x130a')](function(_0x2b6fc9){const _0x3ce08c=_0x4714ff;_0x5eb8f4[_0x3ce08c('0x52a')]({'title':_0x2b6fc9['status']?_0x3ce08c('0x2168')+_0x2b6fc9[_0x3ce08c('0x13ee')]+'\x20-\x20'+_0x2b6fc9[_0x3ce08c('0x24a9')]:_0x3ce08c('0x144f'),'msg':_0x2b6fc9[_0x3ce08c('0x13ee')]?JSON['stringify'](_0x2b6fc9[_0x3ce08c('0x5a5')]):_0x2b6fc9[_0x3ce08c('0x1ff0')]()});}):_0x25771d()[_0x4714ff('0x683')](function(_0x209c26){const _0x3f4ca6=_0x4714ff;return _0x315ebb[_0x3f4ca6('0x1aa')]=_0x209c26,_0xe2a09();})[_0x4714ff('0x130a')](function(_0x25c64d){const _0x4ffcbf=_0x4714ff;_0x5eb8f4[_0x4ffcbf('0x52a')]({'title':_0x25c64d[_0x4ffcbf('0x13ee')]?'API:'+_0x25c64d['status']+_0x4ffcbf('0xbf6')+_0x25c64d[_0x4ffcbf('0x24a9')]:_0x4ffcbf('0x144f'),'msg':_0x25c64d[_0x4ffcbf('0x13ee')]?JSON[_0x4ffcbf('0x258a')](_0x25c64d[_0x4ffcbf('0x5a5')]):_0x25c64d[_0x4ffcbf('0x1ff0')]()});});}function _0x25771d(){return _0x4357d3(function(_0x2dd232,_0x4efba1){const _0x41ce24=a0_0x4e0a;_0x3fa771[_0x41ce24('0x22df')][_0x41ce24('0x1e6e')]({'userProfileId':_0x315ebb['currentUser']['userProfileId'],'name':_0x41ce24('0x1bc0')})[_0x41ce24('0xe53')][_0x41ce24('0x683')](function(_0x4a8d93){const _0x324763=_0x41ce24,_0x4f0221=_0x4a8d93&&_0x4a8d93[_0x324763('0xf5d')]?_0x4a8d93[_0x324763('0xf5d')][0x0]:null;_0x2dd232(_0x4f0221);})[_0x41ce24('0x130a')](function(_0x44d932){_0x4efba1(_0x44d932);});});}function _0xe2a09(){return _0x4357d3(function(_0xa2b84e,_0x4ebd49){const _0x4480ee=a0_0x4e0a;return _0x44af95()[_0x4480ee('0x683')](function(_0x476b0c){const _0x402365=_0x4480ee;return _0x315ebb['items']=_0x476b0c[_0x402365('0xf5d')]?_0x476b0c[_0x402365('0xf5d')]:[],_0x2681be[_0x402365('0xca1')]('admin')?_0x476b0c:_0x315ebb[_0x402365('0x1aa')]?_0x315ebb[_0x402365('0x1aa')][_0x402365('0x170')]?_0x476b0c:_0x4e7db0():null;})[_0x4480ee('0x683')](function(_0x581f14){const _0x57b27e=_0x4480ee,_0xc4fbde=_0x581f14&&_0x581f14[_0x57b27e('0xf5d')]?_0x581f14[_0x57b27e('0xf5d')]:[];return _0x315ebb[_0x57b27e('0x1c47')]=_0x2e3ca0()[_0x57b27e('0x386')](_0xc4fbde,function(_0x2858cb){const _0x61f4ca=_0x57b27e;return _0x2e3ca0()[_0x61f4ca('0x1c07')](_0x315ebb[_0x61f4ca('0x1996')],{'id':_0x2681be[_0x61f4ca('0xca1')](_0x61f4ca('0x20c2'))||_0x315ebb[_0x61f4ca('0x1aa')][_0x61f4ca('0x170')]?_0x2858cb['id']:_0x2858cb[_0x61f4ca('0x832')]});}),_0x315ebb['startingAllowedItems']=angular[_0x57b27e('0x1a86')](_0x315ebb[_0x57b27e('0x1c47')]),_0x315ebb['items'][_0x57b27e('0x1299')](function(_0x13c094){const _0x1bb2fb=_0x57b27e,_0x283caf=_0x2e3ca0()['find'](_0x315ebb[_0x1bb2fb('0x1c47')],{'id':_0x13c094['id']});_0x2681be[_0x1bb2fb('0xca1')](_0x1bb2fb('0x20c2'))?_0x13c094[_0x1bb2fb('0x24f4')]=!![]:_0x13c094['isValid']=typeof _0x283caf!=='undefined'?!![]:![];}),_0x51f48a();})[_0x4480ee('0x683')](function(_0x3abbe4){const _0x1e9fec=_0x4480ee,_0x1daa0f=_0x3abbe4&&_0x3abbe4['rows']?_0x3abbe4['rows']:[];_0x315ebb[_0x1e9fec('0x1378')]=_0x2e3ca0()['map'](_0x1daa0f,function(_0xa5b51){const _0x33928e=_0x1e9fec,_0x1a691a=_0x2e3ca0()['find'](_0x315ebb['items'],{'id':_0xa5b51['id']});return _0x1a691a['penalty']=_0xa5b51[_0x33928e('0x1bf6')]?'penalty\x20'+_0xa5b51[_0x33928e('0x1bf6')][_0x33928e('0x1e2a')]:'',_0x1a691a[_0x33928e('0x1d43')]=typeof _0xa5b51[_0x33928e('0x1d43')]!==_0x33928e('0x1867')?'<'+_0xa5b51[_0x33928e('0x1d43')]+'>':'',_0x1a691a;}),_0x315ebb['startingSelectedItems']=angular[_0x1e9fec('0x1a86')](_0x315ebb['selectedItems']),_0x315ebb[_0x1e9fec('0x169f')][_0x1e9fec('0x1378')]=_0x315ebb[_0x1e9fec('0x1378')],_0x315ebb[_0x1e9fec('0x169f')][_0x1e9fec('0x1996')]=_0x2e3ca0()[_0x1e9fec('0x461')](_0x315ebb['allowedItems'],_0x315ebb['dualMultiselectOptions'][_0x1e9fec('0x1378')],'id'),_0xa2b84e();})[_0x4480ee('0x130a')](function(_0x2347e1){_0x4ebd49(_0x2347e1);});});}function _0x4e7db0(){return _0x4357d3(function(_0x425d51,_0x3a55e6){const _0x1c5f77=a0_0x4e0a;return _0x3fa771[_0x1c5f77('0xcf7')]['get']({'sectionId':_0x315ebb[_0x1c5f77('0x1aa')]['id'],'nolimit':!![]})[_0x1c5f77('0xe53')][_0x1c5f77('0x683')](function(_0x458cfa){_0x425d51(_0x458cfa);})[_0x1c5f77('0x130a')](function(_0x394258){_0x3a55e6(_0x394258);});});}function _0x51f48a(){return _0x4357d3(function(_0x1fd96f,_0x57a0c0){const _0x310c24=a0_0x4e0a;return _0x3fa771[_0x310c24('0x244a')][_0x310c24('0x8e7')]({'id':_0x315ebb[_0x310c24('0x244a')]['id'],'fields':'id,name,internal,fullname','nolimit':!![],'role':_0x310c24('0x2327')})[_0x310c24('0xe53')]['then'](function(_0x33b2ab){_0x1fd96f(_0x33b2ab);})['catch'](function(_0x1c4883){_0x57a0c0(_0x1c4883);});});}function _0x44af95(){return _0x4357d3(function(_0x3f75bb,_0x41087e){const _0x30b316=a0_0x4e0a;return _0x3fa771[_0x30b316('0xc96')][_0x30b316('0x1e6e')]({'fields':_0x30b316('0x72b'),'nolimit':!![],'role':'agent'})[_0x30b316('0xe53')][_0x30b316('0x683')](function(_0x412f5f){_0x3f75bb(_0x412f5f);})[_0x30b316('0x130a')](function(_0x47cb65){_0x41087e(_0x47cb65);});});}function _0x2a15bc(_0x31891c){return _0x4357d3(function(_0x5b91c8,_0x38d20d){const _0xb784bf=a0_0x4e0a;_0x2e3ca0()[_0xb784bf('0x173f')](_0x31891c)?_0x5b91c8():_0x3fa771[_0xb784bf('0x244a')][_0xb784bf('0x2179')]({'id':_0x315ebb[_0xb784bf('0x244a')]['id'],'ids':_0x2e3ca0()[_0xb784bf('0x386')](_0x31891c,'id')})[_0xb784bf('0xe53')][_0xb784bf('0x683')](function(){_0x5b91c8();})[_0xb784bf('0x130a')](function(_0x23492c){_0x38d20d(_0x23492c);});});}function _0x2091cc(_0x4a21e6){return _0x4357d3(function(_0x1c8db4,_0x2c9ad6){const _0x481e2a=a0_0x4e0a;_0x2e3ca0()[_0x481e2a('0x173f')](_0x4a21e6)?_0x1c8db4():_0x3fa771[_0x481e2a('0x244a')][_0x481e2a('0xf9')]({'id':_0x315ebb['faxAccount']['id'],'ids':_0x2e3ca0()['map'](_0x4a21e6,'id')})[_0x481e2a('0xe53')]['then'](function(){_0x1c8db4();})[_0x481e2a('0x130a')](function(_0x15c9c2){_0x2c9ad6(_0x15c9c2);});});}function _0x3690ca(){const _0x59bb91=_0x4a2058,_0x18f250=_0x2e3ca0()['differenceBy'](_0x315ebb[_0x59bb91('0x23a7')],_0x315ebb[_0x59bb91('0x1378')],'id'),_0x4127eb=_0x2e3ca0()[_0x59bb91('0x461')](_0x315ebb['selectedItems'],_0x315ebb[_0x59bb91('0x23a7')],'id');return _0x2091cc(_0x18f250)[_0x59bb91('0x683')](function(){return _0x2a15bc(_0x4127eb);})[_0x59bb91('0x683')](function(){const _0x44d866=_0x59bb91;_0x315ebb['pendingChanges']=![],_0x315ebb['startingAllowedItems']=angular['copy'](_0x315ebb[_0x44d866('0x1c47')]),_0x315ebb[_0x44d866('0x23a7')]=angular[_0x44d866('0x1a86')](_0x315ebb[_0x44d866('0x1378')]),_0x5eb8f4[_0x44d866('0x53')]({'title':'SUCCESS','msg':_0x44d866('0x89d')});})[_0x59bb91('0x130a')](function(_0x2383db){const _0x25fe3d=_0x59bb91;_0x5eb8f4[_0x25fe3d('0x52a')]({'title':_0x2383db[_0x25fe3d('0x13ee')]?'API:'+_0x2383db[_0x25fe3d('0x13ee')]+_0x25fe3d('0xbf6')+_0x2383db['statusText']:'SYSTEM:LISTS_ASSOCIATION','msg':_0x2383db[_0x25fe3d('0x13ee')]?JSON[_0x25fe3d('0x258a')](_0x2383db['data']):_0x2383db[_0x25fe3d('0x1ff0')]()});});}function _0x1bb6c4(){const _0x55845d=_0x4a2058;_0x3749ec[_0x55845d('0x1715')]();}}const _0x30e014=_0x565227;_0x258789[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x993'),_0x189033('0x244a'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x258789(_0x122c58,_0x54e637,_0x3da4c0,_0x545e01,_0x2fb745,_0x39e8dc,_0x44d4a1,_0x3e4214){const _0x4608a9=_0x189033,_0x1d0a5a=this;_0x1d0a5a[_0x4608a9('0x11ed')]=_0x44d4a1[_0x4608a9('0x20b2')](),_0x1d0a5a['errors']=[],_0x1d0a5a[_0x4608a9('0xf28')]=_0x4608a9('0xf9f')+(_0x545e01[_0x4608a9('0x11f3')]||_0x545e01[_0x4608a9('0x1d75')])['toUpperCase'](),_0x1d0a5a[_0x4608a9('0x2327')]=angular[_0x4608a9('0x1a86')](_0x545e01),_0x1d0a5a[_0x4608a9('0x1134')]=_0x3e4214,_0x1d0a5a[_0x4608a9('0x258d')]={};if(_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1407')])switch(_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x11f3')]?_0x1d0a5a['agent'][_0x4608a9('0x11f3')][_0x4608a9('0x93a')]():_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1d75')][_0x4608a9('0x93a')]()){case'custom':break;case'dialogflow':{const _0x12fba7=_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1407')]['split'](',');_0x1d0a5a['agent'][_0x4608a9('0x1d46')]=_0x12fba7[0x0],_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1a1c')]=_0x12fba7[0x1],_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x6d9')]=_0x12fba7[_0x4608a9('0x12c8')](0x2,_0x12fba7[_0x4608a9('0x1564')])[_0x4608a9('0x1630')](',');}break;case _0x4608a9('0xd24'):{const _0x3ae9fd=_0x1d0a5a['agent'][_0x4608a9('0x1407')][_0x4608a9('0x1fc5')](',');_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x2119')]=_0x3ae9fd[0x0],_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x38')]=_0x3ae9fd[0x1],_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x406')]=_0x3ae9fd[0x2],_0x1d0a5a['agent'][_0x4608a9('0x1a1c')]=_0x3ae9fd[0x3],_0x1d0a5a['agent'][_0x4608a9('0x6d9')]=_0x3ae9fd[_0x4608a9('0x12c8')](0x4,_0x3ae9fd[_0x4608a9('0x1564')])[_0x4608a9('0x1630')](',');}break;case _0x4608a9('0x1db1'):{const _0x4d5482=_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1407')]['split'](',');_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x7ae')]=_0x4d5482[0x0],_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x204a')]=_0x4d5482[0x1],_0x1d0a5a[_0x4608a9('0x2327')]['lexregion']=_0x4d5482[0x2],_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x11a9')]=_0x4d5482[0x3],_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x6d9')]=_0x4d5482[_0x4608a9('0x12c8')](0x4,_0x4d5482[_0x4608a9('0x1564')])[_0x4608a9('0x1630')](',');}break;case'autoreply':{const _0x55310d=_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1407')][_0x4608a9('0x1fc5')](',');_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x35')]=isNaN(_0x55310d[0x0])?_0x55310d[0x0]:parseInt(_0x55310d[0x0],0xa),_0x1d0a5a['agent'][_0x4608a9('0x1bcd')]=_0x55310d[_0x4608a9('0x12c8')](0x1,_0x55310d[_0x4608a9('0x1564')])[_0x4608a9('0x1630')](',');}break;case _0x4608a9('0x8c2'):_0x1d0a5a['agent'][_0x4608a9('0x1bcd')]=_0x1d0a5a['agent'][_0x4608a9('0x1407')];break;case _0x4608a9('0x877'):_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x60a')]=_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1407')]['split']('=')[0x0],_0x1d0a5a[_0x4608a9('0x2327')]['value']=_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1407')][_0x4608a9('0x1fc5')]('=')[0x1];break;case _0x4608a9('0x19ae'):_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x273a')]=_0x1d0a5a['agent'][_0x4608a9('0x1407')];break;default:{const _0x16b76f=_0x1d0a5a[_0x4608a9('0x2327')]['appdata'][_0x4608a9('0x1fc5')](',');_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x2327')]=_0x2e3ca0()[_0x4608a9('0x173f')](_0x16b76f[0x0])?_0x16b76f[0x0]:isNaN(_0x16b76f[0x0])?_0x16b76f[0x0]:parseInt(_0x16b76f[0x0],0xa),_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1668')]=_0x2e3ca0()['isEmpty'](_0x16b76f[0x1])?_0x16b76f[0x1]:isNaN(_0x16b76f[0x1])?_0x16b76f[0x1]:parseInt(_0x16b76f[0x1],0xa);}break;}else _0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x1668')]=0x1e;_0x1d0a5a['agent'][_0x4608a9('0xcf0')]&&_0x1d0a5a['agent'][_0x4608a9('0xcf0')][_0x4608a9('0x93a')]()==='outbound'&&_0x1d0a5a['agent']['appType'][_0x4608a9('0x93a')]()===_0x4608a9('0x659')&&(_0x1d0a5a['agent']['prefix']=_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0xd31')]?_0x1d0a5a['agent'][_0x4608a9('0xd31')]['split']('$')[0x0]:undefined,_0x1d0a5a[_0x4608a9('0x2327')]['callerId']=_0x1d0a5a[_0x4608a9('0x2327')][_0x4608a9('0x73c')]?_0x4608a9('0xac1')+_0x1d0a5a['agent'][_0x4608a9('0x73c')]:undefined);_0x1d0a5a[_0x4608a9('0xeb2')]=_0x5139df,_0x1d0a5a['closeDialog']=_0x166a14,_0x44d4a1['hasRole'](_0x4608a9('0x20c2'))?_0x39e8dc[_0x4608a9('0xc96')][_0x4608a9('0x1e6e')]({'fields':_0x4608a9('0xa10'),'sort':_0x4608a9('0x60a'),'role':_0x4608a9('0x2327'),'nolimit':_0x4608a9('0x26ac')})[_0x4608a9('0xe53')]['then'](function(_0x5b35ac){const _0x136d0d=_0x4608a9;_0x1d0a5a[_0x136d0d('0x756')]=_0x5b35ac[_0x136d0d('0xf5d')]||[];})[_0x4608a9('0x130a')](function(_0x6b2537){const _0x35c4e3=_0x4608a9;_0x3da4c0[_0x35c4e3('0x52a')]({'title':_0x6b2537['status']?_0x35c4e3('0x2168')+_0x6b2537[_0x35c4e3('0x13ee')]+'\x20-\x20'+_0x6b2537[_0x35c4e3('0x24a9')]:_0x35c4e3('0x144f'),'msg':_0x6b2537[_0x35c4e3('0x5a5')]?JSON[_0x35c4e3('0x258a')](_0x6b2537[_0x35c4e3('0x5a5')]):_0x6b2537['toString']()});}):_0x39e8dc[_0x4608a9('0xc96')][_0x4608a9('0x1e6e')]({'fields':_0x4608a9('0xa10'),'sort':_0x4608a9('0x60a'),'role':_0x4608a9('0x2327'),'nolimit':_0x4608a9('0x26ac')})[_0x4608a9('0xe53')][_0x4608a9('0x683')](function(_0x21e745){const _0x25cddf=_0x4608a9;_0x1d0a5a[_0x25cddf('0x756')]=_0x21e745[_0x25cddf('0xf5d')]||[];})['then'](function(){const _0x4090d8=_0x4608a9;return _0x39e8dc['userProfileSection'][_0x4090d8('0x1e6e')]({'userProfileId':_0x1d0a5a['currentUser'][_0x4090d8('0x2f')],'sectionId':0xca})['$promise'];})['then'](function(_0x45c9c1){const _0x3dfbb6=_0x4608a9,_0x2e4155=_0x45c9c1&&_0x45c9c1[_0x3dfbb6('0xf5d')]?_0x45c9c1['rows'][0x0]:null;if(!_0x2e4155){const _0x40caa1=[];let _0x2e7d05=null;_0x1d0a5a['agent']&&(_0x2e7d05=_0x2e3ca0()['find'](_0x1d0a5a['agents'],{'name':_0x1d0a5a['agent'][_0x3dfbb6('0x2327')]}));for(let _0xfd31aa=0x0;_0xfd31aa<_0x1d0a5a['agents'][_0x3dfbb6('0x1564')];_0xfd31aa++){_0x2e7d05&&_0x1d0a5a[_0x3dfbb6('0x756')][_0xfd31aa]['id']===_0x2e7d05['id']&&(_0x1d0a5a[_0x3dfbb6('0x756')][_0xfd31aa][_0x3dfbb6('0x319')]=![],_0x40caa1[_0x3dfbb6('0x1fd0')](_0x1d0a5a[_0x3dfbb6('0x756')][_0xfd31aa]));}_0x1d0a5a[_0x3dfbb6('0x756')]=_0x40caa1;}else{if(!_0x2e4155[_0x3dfbb6('0x170')])return _0x39e8dc[_0x3dfbb6('0xcf7')]['get']({'sectionId':_0x2e4155['id']})[_0x3dfbb6('0xe53')][_0x3dfbb6('0x683')](function(_0x5e61b3){const _0x63cf81=_0x3dfbb6,_0x488bdf=_0x2e3ca0()[_0x63cf81('0x386')](_0x5e61b3['rows'],function(_0x1f4f39){const _0x66ce79=_0x63cf81;return _0x2e3ca0()[_0x66ce79('0x1c07')](_0x1d0a5a[_0x66ce79('0x756')],{'id':_0x1f4f39[_0x66ce79('0x832')]});});let _0x3d4305=null;_0x1d0a5a['agent']&&(_0x3d4305=_0x2e3ca0()['find'](_0x1d0a5a[_0x63cf81('0x756')],{'name':_0x1d0a5a['agent'][_0x63cf81('0x2327')]}));if(_0x3d4305&&!_0x2e3ca0()['some'](_0x488bdf,['id',_0x3d4305['id']])){const _0x1059a4=_0x2e3ca0()['find'](_0x1d0a5a[_0x63cf81('0x756')],{'id':_0x3d4305['id']});_0x1059a4['canSelect']=![],_0x488bdf[_0x63cf81('0x1fd0')](_0x1059a4);}_0x1d0a5a['agents']=_0x488bdf;});}})[_0x4608a9('0x130a')](function(_0x6cf0b7){const _0x1d49b7=_0x4608a9;_0x3da4c0['error']({'title':_0x6cf0b7[_0x1d49b7('0x13ee')]?_0x1d49b7('0x2168')+_0x6cf0b7['status']+_0x1d49b7('0xbf6')+_0x6cf0b7[_0x1d49b7('0x24a9')]:_0x1d49b7('0x391'),'msg':_0x6cf0b7[_0x1d49b7('0x5a5')]?JSON[_0x1d49b7('0x258a')](_0x6cf0b7['data']):_0x6cf0b7['toString']()});});function _0x5139df(){const _0x5a19e8=_0x4608a9;_0x1d0a5a['errors']=[];const _0x32b2e9=[];_0x1d0a5a['agent'][_0x5a19e8('0xcf0')]&&_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0xcf0')]['toLowerCase']()==='outbound'&&_0x1d0a5a['agent'][_0x5a19e8('0x11f3')]===_0x5a19e8('0x4d2')&&(_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0xd31')]=_0x2fb745['cutdigits']?(_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x24fa')]||'')+_0x5a19e8('0x249e')+_0x2fb745['cutdigits']+'}':(_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x24fa')]||'')+_0x5a19e8('0x20cb'),_0x2fb745[_0x5a19e8('0x75b')]!==_0x5a19e8('0x925')?_0x1d0a5a[_0x5a19e8('0x2327')]['options'][_0x5a19e8('0x824')](_0x5a19e8('0x1b1'))<0x0&&(_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x158e')]+=_0x5a19e8('0x1b1')):_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x158e')]=_0x1d0a5a['agent']['options'][_0x5a19e8('0x1725')]('U(xcally-mixmonitor-context)',''));const _0x41a9b5=_0x2e3ca0()['find'](_0x1d0a5a[_0x5a19e8('0x756')],{'name':_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x2327')]});_0x41a9b5&&(_0x1d0a5a[_0x5a19e8('0x2327')]['UserId']=_0x41a9b5['id']);if(_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x11f3')]&&_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x11f3')]===_0x5a19e8('0xbf0')){}else switch((_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x1d75')]||_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x11f3')])['toLowerCase']()){case _0x5a19e8('0x877'):_0x1d0a5a['agent']['appdata']=_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x60a')]+'='+_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x1c6b')];break;case _0x5a19e8('0xbf0'):break;default:_0x32b2e9[0x0]=_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x2327')],_0x32b2e9[0x1]=_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x1668')],_0x1d0a5a[_0x5a19e8('0x2327')][_0x5a19e8('0x1407')]=_0x32b2e9[_0x5a19e8('0x1630')](',');}_0x166a14(_0x1d0a5a[_0x5a19e8('0x2327')]);}function _0x166a14(_0x562b06){const _0x217cfd=_0x4608a9;_0x122c58[_0x217cfd('0x1715')](_0x562b06);}}const _0x86f81=_0x258789;_0x8e1127[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'faxAccountApp',_0x189033('0x244a'),'api','Auth','crudPermissions'];function _0x8e1127(_0x2f2ee7,_0x35aa52,_0x45d2bf,_0x159f71,_0x13de5e,_0x18664b,_0xe06149,_0x40ca81){const _0x554fc7=_0x189033,_0x278128=this;_0x278128[_0x554fc7('0x11ed')]=_0xe06149[_0x554fc7('0x20b2')](),_0x278128['errors']=[],_0x278128[_0x554fc7('0xf28')]=_0x554fc7('0xf9f')+(_0x159f71[_0x554fc7('0x11f3')]||_0x159f71[_0x554fc7('0x1d75')])[_0x554fc7('0x80')](),_0x278128['close']=angular[_0x554fc7('0x1a86')](_0x159f71),_0x278128[_0x554fc7('0x1134')]=_0x40ca81,_0x278128[_0x554fc7('0x258d')]={};if(_0x278128[_0x554fc7('0x12b0')]['appdata'])switch(_0x278128[_0x554fc7('0x12b0')]['appType']?_0x278128['close'][_0x554fc7('0x11f3')]['toLowerCase']():_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1d75')][_0x554fc7('0x93a')]()){case _0x554fc7('0xbf0'):break;case _0x554fc7('0x205c'):{const _0x47c6da=_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1407')][_0x554fc7('0x1fc5')](',');_0x278128['close']['key']=_0x47c6da[0x0],_0x278128['close'][_0x554fc7('0x1a1c')]=_0x47c6da[0x1],_0x278128[_0x554fc7('0x12b0')]['welcomemessage']=_0x47c6da[_0x554fc7('0x12c8')](0x2,_0x47c6da['length'])[_0x554fc7('0x1630')](',');}break;case _0x554fc7('0xd24'):{const _0x34c1bc=_0x278128['close'][_0x554fc7('0x1407')]['split'](',');_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x2119')]=_0x34c1bc[0x0],_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x38')]=_0x34c1bc[0x1],_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x406')]=_0x34c1bc[0x2],_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1a1c')]=_0x34c1bc[0x3],_0x278128[_0x554fc7('0x12b0')]['welcomemessage']=_0x34c1bc[_0x554fc7('0x12c8')](0x4,_0x34c1bc[_0x554fc7('0x1564')])[_0x554fc7('0x1630')](',');}break;case _0x554fc7('0x1db1'):{const _0x4cf4c7=_0x278128[_0x554fc7('0x12b0')]['appdata'][_0x554fc7('0x1fc5')](',');_0x278128['close'][_0x554fc7('0x7ae')]=_0x4cf4c7[0x0],_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x204a')]=_0x4cf4c7[0x1],_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x5ba')]=_0x4cf4c7[0x2],_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x11a9')]=_0x4cf4c7[0x3],_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x6d9')]=_0x4cf4c7[_0x554fc7('0x12c8')](0x4,_0x4cf4c7[_0x554fc7('0x1564')])['join'](',');}break;case _0x554fc7('0x2408'):{const _0x4a42cc=_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1407')][_0x554fc7('0x1fc5')](',');_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x35')]=isNaN(_0x4a42cc[0x0])?_0x4a42cc[0x0]:parseInt(_0x4a42cc[0x0],0xa),_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1bcd')]=_0x4a42cc[_0x554fc7('0x12c8')](0x1,_0x4a42cc[_0x554fc7('0x1564')])[_0x554fc7('0x1630')](',');}break;case _0x554fc7('0x8c2'):_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1bcd')]=_0x278128['close'][_0x554fc7('0x1407')];break;case'set':_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x60a')]=_0x278128[_0x554fc7('0x12b0')]['appdata'][_0x554fc7('0x1fc5')]('=')[0x0],_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1c6b')]=_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1407')]['split']('=')[0x1];break;case _0x554fc7('0x19ae'):_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x273a')]=_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1407')];break;default:{const _0x36a7c3=_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x1407')][_0x554fc7('0x1fc5')](',');_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x43f')]=_0x2e3ca0()[_0x554fc7('0x173f')](_0x36a7c3[0x0])?_0x36a7c3[0x0]:isNaN(_0x36a7c3[0x0])?_0x36a7c3[0x0]:parseInt(_0x36a7c3[0x0],0xa);}break;}else{}_0x278128[_0x554fc7('0x12b0')]['type']&&_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0xcf0')][_0x554fc7('0x93a')]()===_0x554fc7('0x17cd')&&_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x11f3')][_0x554fc7('0x93a')]()===_0x554fc7('0x659')&&(_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x24fa')]=_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0xd31')]?_0x278128[_0x554fc7('0x12b0')]['phone'][_0x554fc7('0x1fc5')]('$')[0x0]:undefined,_0x278128['close'][_0x554fc7('0xabd')]=_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x73c')]?_0x554fc7('0xac1')+_0x278128[_0x554fc7('0x12b0')][_0x554fc7('0x73c')]:undefined);_0x278128[_0x554fc7('0xeb2')]=_0x4e7c79,_0x278128[_0x554fc7('0xf82')]=_0x17b933;function _0x4e7c79(){const _0x1c5850=_0x554fc7;_0x278128[_0x1c5850('0x17f')]=[];const _0x5da00b=[];_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0xcf0')]&&_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0xcf0')][_0x1c5850('0x93a')]()===_0x1c5850('0x17cd')&&_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x11f3')]===_0x1c5850('0x4d2')&&(_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0xd31')]=_0x13de5e[_0x1c5850('0x145a')]?(_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x24fa')]||'')+'${EXTEN:'+_0x13de5e[_0x1c5850('0x145a')]+'}':(_0x278128['close'][_0x1c5850('0x24fa')]||'')+_0x1c5850('0x20cb'),_0x13de5e[_0x1c5850('0x75b')]!==_0x1c5850('0x925')?_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x158e')]['indexOf'](_0x1c5850('0x1b1'))<0x0&&(_0x278128[_0x1c5850('0x12b0')]['options']+='U(xcally-mixmonitor-context)'):_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x158e')]=_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x158e')][_0x1c5850('0x1725')](_0x1c5850('0x1b1'),''));if(_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x11f3')]&&_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x11f3')]===_0x1c5850('0xbf0')){}else switch((_0x278128['close'][_0x1c5850('0x1d75')]||_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x11f3')])[_0x1c5850('0x93a')]()){case'set':_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x1407')]=_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x60a')]+'='+_0x278128[_0x1c5850('0x12b0')]['value'];break;case _0x1c5850('0xbf0'):break;default:_0x5da00b[0x0]=_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x43f')],_0x278128[_0x1c5850('0x12b0')][_0x1c5850('0x1407')]=_0x5da00b[_0x1c5850('0x1630')](',');}_0x17b933(_0x278128[_0x1c5850('0x12b0')]);}function _0x17b933(_0x520b92){const _0x5f4e5b=_0x554fc7;_0x2f2ee7[_0x5f4e5b('0x1715')](_0x520b92);}}const _0x1f5626=_0x8e1127;_0x1a51b4[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x993'),_0x189033('0x244a'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x1a51b4(_0x4450d9,_0x3f7d03,_0x782c9f,_0x2df20b,_0x556ddb,_0x461d6d,_0x109106,_0x36e0cd){const _0x58c1dc=_0x189033,_0x3ee4a1=this;_0x3ee4a1['currentUser']=_0x109106['getCurrentUser'](),_0x3ee4a1[_0x58c1dc('0x17f')]=[],_0x3ee4a1['title']=_0x58c1dc('0xf9f')+(_0x2df20b[_0x58c1dc('0x11f3')]||_0x2df20b[_0x58c1dc('0x1d75')])[_0x58c1dc('0x80')](),_0x3ee4a1[_0x58c1dc('0xc33')]=angular['copy'](_0x2df20b),_0x3ee4a1[_0x58c1dc('0x1134')]=_0x36e0cd,_0x3ee4a1['hasModulePermissions']={};if(_0x3ee4a1['gotoif']['appdata'])switch(_0x3ee4a1['gotoif']['appType']?_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x11f3')][_0x58c1dc('0x93a')]():_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x1d75')][_0x58c1dc('0x93a')]()){case'custom':break;case _0x58c1dc('0x205c'):{const _0x50e832=_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x1407')]['split'](',');_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x1d46')]=_0x50e832[0x0],_0x3ee4a1[_0x58c1dc('0xc33')]['language']=_0x50e832[0x1],_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x6d9')]=_0x50e832[_0x58c1dc('0x12c8')](0x2,_0x50e832[_0x58c1dc('0x1564')])[_0x58c1dc('0x1630')](',');}break;case _0x58c1dc('0xd24'):{const _0x33bc3e=_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x1407')][_0x58c1dc('0x1fc5')](',');_0x3ee4a1[_0x58c1dc('0xc33')]['projectId']=_0x33bc3e[0x0],_0x3ee4a1['gotoif'][_0x58c1dc('0x38')]=_0x33bc3e[0x1],_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x406')]=_0x33bc3e[0x2],_0x3ee4a1[_0x58c1dc('0xc33')]['language']=_0x33bc3e[0x3],_0x3ee4a1['gotoif'][_0x58c1dc('0x6d9')]=_0x33bc3e[_0x58c1dc('0x12c8')](0x4,_0x33bc3e[_0x58c1dc('0x1564')])[_0x58c1dc('0x1630')](',');}break;case _0x58c1dc('0x1db1'):{const _0x31c894=_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x1407')]['split'](',');_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x7ae')]=_0x31c894[0x0],_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x204a')]=_0x31c894[0x1],_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x5ba')]=_0x31c894[0x2],_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x11a9')]=_0x31c894[0x3],_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x6d9')]=_0x31c894[_0x58c1dc('0x12c8')](0x4,_0x31c894[_0x58c1dc('0x1564')])[_0x58c1dc('0x1630')](',');}break;case'autoreply':{const _0x41ec7e=_0x3ee4a1[_0x58c1dc('0xc33')]['appdata'][_0x58c1dc('0x1fc5')](',');_0x3ee4a1['gotoif'][_0x58c1dc('0x35')]=isNaN(_0x41ec7e[0x0])?_0x41ec7e[0x0]:parseInt(_0x41ec7e[0x0],0xa),_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x1bcd')]=_0x41ec7e[_0x58c1dc('0x12c8')](0x1,_0x41ec7e[_0x58c1dc('0x1564')])[_0x58c1dc('0x1630')](',');}break;case _0x58c1dc('0x8c2'):_0x3ee4a1[_0x58c1dc('0xc33')]['text']=_0x3ee4a1['gotoif'][_0x58c1dc('0x1407')];break;case _0x58c1dc('0x877'):_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x60a')]=_0x3ee4a1[_0x58c1dc('0xc33')]['appdata'][_0x58c1dc('0x1fc5')]('=')[0x0],_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x1c6b')]=_0x3ee4a1[_0x58c1dc('0xc33')]['appdata'][_0x58c1dc('0x1fc5')]('=')[0x1];break;case'agi':_0x3ee4a1[_0x58c1dc('0xc33')]['project']=_0x3ee4a1[_0x58c1dc('0xc33')]['appdata'];break;default:{const _0x49884b=_0x3ee4a1['gotoif'][_0x58c1dc('0x1407')]['split'](',');_0x3ee4a1[_0x58c1dc('0xc33')]['condition']=_0x2e3ca0()[_0x58c1dc('0x173f')](_0x49884b[0x0])?_0x49884b[0x0]:isNaN(_0x49884b[0x0])?_0x49884b[0x0]:parseInt(_0x49884b[0x0],0xa),_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0x27e5')]=_0x2e3ca0()[_0x58c1dc('0x173f')](_0x49884b[0x1])?_0x49884b[0x1]:isNaN(_0x49884b[0x1])?_0x49884b[0x1]:parseInt(_0x49884b[0x1],0xa),_0x3ee4a1['gotoif']['falsepriority']=_0x2e3ca0()['isEmpty'](_0x49884b[0x2])?_0x49884b[0x2]:isNaN(_0x49884b[0x2])?_0x49884b[0x2]:parseInt(_0x49884b[0x2],0xa);}break;}else{}_0x3ee4a1['gotoif'][_0x58c1dc('0xcf0')]&&_0x3ee4a1['gotoif'][_0x58c1dc('0xcf0')][_0x58c1dc('0x93a')]()===_0x58c1dc('0x17cd')&&_0x3ee4a1[_0x58c1dc('0xc33')]['appType'][_0x58c1dc('0x93a')]()==='outbounddial'&&(_0x3ee4a1['gotoif'][_0x58c1dc('0x24fa')]=_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0xd31')]?_0x3ee4a1[_0x58c1dc('0xc33')]['phone'][_0x58c1dc('0x1fc5')]('$')[0x0]:undefined,_0x3ee4a1[_0x58c1dc('0xc33')][_0x58c1dc('0xabd')]=_0x3ee4a1['gotoif'][_0x58c1dc('0x73c')]?_0x58c1dc('0xac1')+_0x3ee4a1['gotoif'][_0x58c1dc('0x73c')]:undefined);_0x3ee4a1[_0x58c1dc('0xeb2')]=_0xf4e643,_0x3ee4a1[_0x58c1dc('0xf82')]=_0x470f05;function _0xf4e643(){const _0x212400=_0x58c1dc;_0x3ee4a1['errors']=[];const _0x249276=[];_0x3ee4a1[_0x212400('0xc33')][_0x212400('0xcf0')]&&_0x3ee4a1[_0x212400('0xc33')][_0x212400('0xcf0')]['toLowerCase']()===_0x212400('0x17cd')&&_0x3ee4a1['gotoif'][_0x212400('0x11f3')]===_0x212400('0x4d2')&&(_0x3ee4a1['gotoif']['phone']=_0x556ddb[_0x212400('0x145a')]?(_0x3ee4a1[_0x212400('0xc33')]['prefix']||'')+_0x212400('0x249e')+_0x556ddb[_0x212400('0x145a')]+'}':(_0x3ee4a1['gotoif'][_0x212400('0x24fa')]||'')+_0x212400('0x20cb'),_0x556ddb[_0x212400('0x75b')]!==_0x212400('0x925')?_0x3ee4a1[_0x212400('0xc33')]['options'][_0x212400('0x824')](_0x212400('0x1b1'))<0x0&&(_0x3ee4a1['gotoif']['options']+='U(xcally-mixmonitor-context)'):_0x3ee4a1[_0x212400('0xc33')][_0x212400('0x158e')]=_0x3ee4a1[_0x212400('0xc33')][_0x212400('0x158e')]['replace'](_0x212400('0x1b1'),''));if(_0x3ee4a1[_0x212400('0xc33')]['appType']&&_0x3ee4a1[_0x212400('0xc33')][_0x212400('0x11f3')]==='custom'){}else switch((_0x3ee4a1[_0x212400('0xc33')]['app']||_0x3ee4a1['gotoif'][_0x212400('0x11f3')])[_0x212400('0x93a')]()){case _0x212400('0x877'):_0x3ee4a1[_0x212400('0xc33')][_0x212400('0x1407')]=_0x3ee4a1[_0x212400('0xc33')][_0x212400('0x60a')]+'='+_0x3ee4a1[_0x212400('0xc33')][_0x212400('0x1c6b')];break;case'custom':break;default:_0x249276[0x0]=_0x3ee4a1[_0x212400('0xc33')][_0x212400('0x168e')],_0x249276[0x1]=_0x3ee4a1[_0x212400('0xc33')][_0x212400('0x27e5')],_0x249276[0x2]=_0x3ee4a1[_0x212400('0xc33')]['falsepriority'],_0x3ee4a1['gotoif'][_0x212400('0x1407')]=_0x249276[_0x212400('0x1630')](',');}_0x470f05(_0x3ee4a1[_0x212400('0xc33')]);}function _0x470f05(_0x14dfc5){const _0x57fc9c=_0x58c1dc;_0x4450d9[_0x57fc9c('0x1715')](_0x14dfc5);}}const _0x453505=_0x1a51b4;_0x5b8dbc[_0x189033('0x14be')]=['$mdDialog','$q','toasty',_0x189033('0x993'),_0x189033('0x244a'),'api',_0x189033('0xba1'),'crudPermissions'];function _0x5b8dbc(_0x528a4d,_0x5487bc,_0x346ac0,_0x44003d,_0x4ff425,_0x4e47d4,_0x49b512,_0x310834){const _0x42128f=_0x189033,_0x5c9b3b=this;_0x5c9b3b[_0x42128f('0x11ed')]=_0x49b512['getCurrentUser'](),_0x5c9b3b[_0x42128f('0x17f')]=[],_0x5c9b3b[_0x42128f('0xf28')]=_0x42128f('0xf9f')+(_0x44003d[_0x42128f('0x11f3')]||_0x44003d[_0x42128f('0x1d75')])[_0x42128f('0x80')](),_0x5c9b3b[_0x42128f('0x1da0')]=angular[_0x42128f('0x1a86')](_0x44003d),_0x5c9b3b[_0x42128f('0x1134')]=_0x310834,_0x5c9b3b[_0x42128f('0x258d')]={};if(_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x1407')])switch(_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x11f3')]?_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x11f3')][_0x42128f('0x93a')]():_0x5c9b3b['gotop'][_0x42128f('0x1d75')][_0x42128f('0x93a')]()){case _0x42128f('0xbf0'):break;case _0x42128f('0x205c'):{const _0x40e653=_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x1407')][_0x42128f('0x1fc5')](',');_0x5c9b3b['gotop'][_0x42128f('0x1d46')]=_0x40e653[0x0],_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x1a1c')]=_0x40e653[0x1],_0x5c9b3b[_0x42128f('0x1da0')]['welcomemessage']=_0x40e653[_0x42128f('0x12c8')](0x2,_0x40e653[_0x42128f('0x1564')])[_0x42128f('0x1630')](',');}break;case _0x42128f('0xd24'):{const _0x49d5a4=_0x5c9b3b[_0x42128f('0x1da0')]['appdata'][_0x42128f('0x1fc5')](',');_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x2119')]=_0x49d5a4[0x0],_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x38')]=_0x49d5a4[0x1],_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x406')]=_0x49d5a4[0x2],_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x1a1c')]=_0x49d5a4[0x3],_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x6d9')]=_0x49d5a4['slice'](0x4,_0x49d5a4[_0x42128f('0x1564')])[_0x42128f('0x1630')](',');}break;case _0x42128f('0x1db1'):{const _0x5936ca=_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x1407')]['split'](',');_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x7ae')]=_0x5936ca[0x0],_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x204a')]=_0x5936ca[0x1],_0x5c9b3b[_0x42128f('0x1da0')]['lexregion']=_0x5936ca[0x2],_0x5c9b3b['gotop']['botname']=_0x5936ca[0x3],_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x6d9')]=_0x5936ca['slice'](0x4,_0x5936ca['length'])[_0x42128f('0x1630')](',');}break;case _0x42128f('0x2408'):{const _0x24daf3=_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x1407')][_0x42128f('0x1fc5')](',');_0x5c9b3b[_0x42128f('0x1da0')]['times']=isNaN(_0x24daf3[0x0])?_0x24daf3[0x0]:parseInt(_0x24daf3[0x0],0xa),_0x5c9b3b[_0x42128f('0x1da0')]['text']=_0x24daf3[_0x42128f('0x12c8')](0x1,_0x24daf3[_0x42128f('0x1564')])[_0x42128f('0x1630')](',');}break;case _0x42128f('0x8c2'):_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x1bcd')]=_0x5c9b3b[_0x42128f('0x1da0')]['appdata'];break;case'set':_0x5c9b3b[_0x42128f('0x1da0')]['name']=_0x5c9b3b[_0x42128f('0x1da0')]['appdata']['split']('=')[0x0],_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x1c6b')]=_0x5c9b3b[_0x42128f('0x1da0')]['appdata']['split']('=')[0x1];break;case _0x42128f('0x19ae'):_0x5c9b3b['gotop']['project']=_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x1407')];break;default:{const _0x368dd3=_0x5c9b3b['gotop'][_0x42128f('0x1407')][_0x42128f('0x1fc5')](',');_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0xe1e')]=_0x2e3ca0()[_0x42128f('0x173f')](_0x368dd3[0x0])?_0x368dd3[0x0]:isNaN(_0x368dd3[0x0])?_0x368dd3[0x0]:parseInt(_0x368dd3[0x0],0xa);}break;}else{}_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0xcf0')]&&_0x5c9b3b['gotop'][_0x42128f('0xcf0')][_0x42128f('0x93a')]()===_0x42128f('0x17cd')&&_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x11f3')]['toLowerCase']()==='outbounddial'&&(_0x5c9b3b['gotop'][_0x42128f('0x24fa')]=_0x5c9b3b[_0x42128f('0x1da0')]['phone']?_0x5c9b3b[_0x42128f('0x1da0')]['phone'][_0x42128f('0x1fc5')]('$')[0x0]:undefined,_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0xabd')]=_0x5c9b3b[_0x42128f('0x1da0')][_0x42128f('0x73c')]?_0x42128f('0xac1')+_0x5c9b3b[_0x42128f('0x1da0')]['callerID']:undefined);_0x5c9b3b[_0x42128f('0xeb2')]=_0x450945,_0x5c9b3b[_0x42128f('0xf82')]=_0x14c82b;function _0x450945(){const _0x19352b=_0x42128f;_0x5c9b3b[_0x19352b('0x17f')]=[];const _0x50d6ab=[];_0x5c9b3b['gotop'][_0x19352b('0xcf0')]&&_0x5c9b3b[_0x19352b('0x1da0')]['type']['toLowerCase']()===_0x19352b('0x17cd')&&_0x5c9b3b[_0x19352b('0x1da0')][_0x19352b('0x11f3')]===_0x19352b('0x4d2')&&(_0x5c9b3b[_0x19352b('0x1da0')][_0x19352b('0xd31')]=_0x4ff425['cutdigits']?(_0x5c9b3b[_0x19352b('0x1da0')]['prefix']||'')+_0x19352b('0x249e')+_0x4ff425[_0x19352b('0x145a')]+'}':(_0x5c9b3b[_0x19352b('0x1da0')]['prefix']||'')+'${EXTEN}',_0x4ff425[_0x19352b('0x75b')]!==_0x19352b('0x925')?_0x5c9b3b[_0x19352b('0x1da0')]['options']['indexOf'](_0x19352b('0x1b1'))<0x0&&(_0x5c9b3b[_0x19352b('0x1da0')]['options']+=_0x19352b('0x1b1')):_0x5c9b3b[_0x19352b('0x1da0')][_0x19352b('0x158e')]=_0x5c9b3b['gotop'][_0x19352b('0x158e')][_0x19352b('0x1725')](_0x19352b('0x1b1'),''));if(_0x5c9b3b[_0x19352b('0x1da0')]['appType']&&_0x5c9b3b['gotop'][_0x19352b('0x11f3')]==='custom'){}else switch((_0x5c9b3b[_0x19352b('0x1da0')][_0x19352b('0x1d75')]||_0x5c9b3b['gotop']['appType'])['toLowerCase']()){case _0x19352b('0x877'):_0x5c9b3b['gotop']['appdata']=_0x5c9b3b['gotop'][_0x19352b('0x60a')]+'='+_0x5c9b3b['gotop'][_0x19352b('0x1c6b')];break;case _0x19352b('0xbf0'):break;default:_0x50d6ab[0x0]=_0x5c9b3b[_0x19352b('0x1da0')][_0x19352b('0xe1e')],_0x5c9b3b[_0x19352b('0x1da0')][_0x19352b('0x1407')]=_0x50d6ab['join'](',');}_0x14c82b(_0x5c9b3b[_0x19352b('0x1da0')]);}function _0x14c82b(_0x2d5013){const _0xcab499=_0x42128f;_0x528a4d[_0xcab499('0x1715')](_0x2d5013);}}const _0x233117=_0x5b8dbc;_0x16e8b8[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x1e48'),_0x189033('0xb33'),_0x189033('0x844'),_0x189033('0x115c'),_0x189033('0xe98'),_0x189033('0x1d70'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x16e8b8(_0x28f4a1,_0x369bae,_0x1a466a,_0x43c2ad,_0x417fb6,_0x5e6e0e,_0x53d287,_0x4bacad,_0x5626ad,_0x47cbe2){const _0x4e5940=_0x189033,_0x2c6280=this;_0x2c6280['currentUser']=_0x5626ad[_0x4e5940('0x20b2')](),_0x2c6280['errors']=[],_0x2c6280[_0x4e5940('0xf28')]=_0x4e5940('0xc62'),_0x2c6280[_0x4e5940('0x115c')]=angular[_0x4e5940('0x1a86')](_0x417fb6),_0x2c6280[_0x4e5940('0xe98')]=_0x5e6e0e,_0x2c6280['newInterval']=![],_0x2c6280['types']=[_0x4e5940('0x10af'),_0x4e5940('0xbf0'),_0x4e5940('0x2335')],_0x2c6280[_0x4e5940('0x1134')]=_0x47cbe2,_0x2c6280[_0x4e5940('0x167a')]=_0x43c2ad[_0x4e5940('0xe88')](),_0x2c6280['monthNumber']=_0x43c2ad[_0x4e5940('0x222e')](),_0x2c6280[_0x4e5940('0x1e32')]=_0x43c2ad['getMonthName'](),_0x2c6280[_0x4e5940('0x13ce')]=_0x43c2ad[_0x4e5940('0x181b')]();if(!_0x2c6280[_0x4e5940('0x115c')])_0x2c6280[_0x4e5940('0x115c')]={'interval':_0x4e5940('0x1b54')},_0x2c6280[_0x4e5940('0xcf0')]=_0x4e5940('0x10af'),_0x2c6280[_0x4e5940('0xf28')]=_0x4e5940('0x1e94'),_0x2c6280['newInterval']=!![];else{if(_0x2c6280[_0x4e5940('0x115c')]['interval']!==_0x4e5940('0x1b54')){_0x2c6280[_0x4e5940('0xcf0')]=_0x4e5940('0xbf0');const _0xdd6a3=_0x2c6280[_0x4e5940('0x115c')][_0x4e5940('0x115c')][_0x4e5940('0x1fc5')](','),_0x248240=_0xdd6a3[0x0],_0x18aafa=_0xdd6a3[0x1],_0x578538=_0xdd6a3[0x2],_0x23519d=_0xdd6a3[0x3];if(_0x248240!=='*'){const _0x48b4ed=_0x248240['split']('-')[0x0],_0x589b8b=_0x248240[_0x4e5940('0x1fc5')]('-')[0x1];let _0x19cec8;_0x19cec8=new Date(),_0x19cec8[_0x4e5940('0x2813')](Number(_0x48b4ed[_0x4e5940('0x1fc5')](':')[0x0])),_0x19cec8[_0x4e5940('0x1fb7')](Number(_0x48b4ed[_0x4e5940('0x1fc5')](':')[0x1])),_0x2c6280[_0x4e5940('0xc32')]=_0x19cec8,_0x19cec8=new Date(),_0x19cec8['setHours'](Number(_0x589b8b[_0x4e5940('0x1fc5')](':')[0x0])),_0x19cec8[_0x4e5940('0x1fb7')](Number(_0x589b8b[_0x4e5940('0x1fc5')](':')[0x1])),_0x2c6280[_0x4e5940('0xaa0')]=_0x19cec8;}_0x18aafa!=='*'&&(_0x2c6280['dayOfWeekFrom']=_0x18aafa[_0x4e5940('0x1fc5')]('-')[0x0],_0x2c6280[_0x4e5940('0x1269')]=_0x18aafa[_0x4e5940('0x1fc5')]('-')[0x1]),_0x578538!=='*'&&(_0x2c6280[_0x4e5940('0xf13')]=_0x578538['split']('-')[0x0],_0x2c6280[_0x4e5940('0xfe5')]=_0x578538[_0x4e5940('0x1fc5')]('-')[0x1]),_0x23519d!=='*'&&(_0x2c6280[_0x4e5940('0x1690')]=_0x23519d[_0x4e5940('0x1fc5')]('-')[0x0],_0x2c6280[_0x4e5940('0x1f12')]=_0x23519d[_0x4e5940('0x1fc5')]('-')[0x1]);}else _0x2c6280['type']=_0x4e5940('0x10af');}_0x28f4a1[_0x4e5940('0x7f2')]['id']&&!_0x2c6280[_0x4e5940('0x115c')]['application']&&(_0x2c6280['interval']['IntervalId']=_0x28f4a1[_0x4e5940('0x7f2')]['id']);_0x2c6280[_0x4e5940('0x115c')]['IntervalId']&&_0x2c6280[_0x4e5940('0x115c')][_0x4e5940('0x121e')]&&(_0x2c6280[_0x4e5940('0xcf0')]=_0x4e5940('0x2335'));_0x2c6280[_0x4e5940('0x1a4d')]=_0x54cd59,_0x2c6280[_0x4e5940('0x1807')]=_0xb4ec9b,_0x2c6280[_0x4e5940('0xf82')]=_0x550f4b;_0x2c6280[_0x4e5940('0x115c')][_0x4e5940('0x121e')]&&(_0x5626ad[_0x4e5940('0xca1')](_0x4e5940('0x20c2'))?_0x4bacad['interval'][_0x4e5940('0x1e6e')]({'fields':'id,name,interval,IntervalId','IntervalId':'null','nolimit':!![]})['$promise'][_0x4e5940('0x683')](function(_0x33db5f){const _0x43beb7=_0x4e5940;_0x2c6280[_0x43beb7('0xe98')]=_0x33db5f[_0x43beb7('0xf5d')]||[];})[_0x4e5940('0x130a')](function(_0x4a5ded){const _0x4562ab=_0x4e5940;_0x53d287['error']({'title':_0x4a5ded[_0x4562ab('0x13ee')]?'API:'+_0x4a5ded[_0x4562ab('0x13ee')]+_0x4562ab('0xbf6')+_0x4a5ded[_0x4562ab('0x24a9')]:_0x4562ab('0x1e65'),'msg':_0x4a5ded[_0x4562ab('0x5a5')]?JSON['stringify'](_0x4a5ded[_0x4562ab('0x5a5')]):_0x4a5ded['toString']()});}):_0x4bacad[_0x4e5940('0x115c')][_0x4e5940('0x1e6e')]({'fields':_0x4e5940('0x1e24'),'IntervalId':_0x4e5940('0x13c'),'nolimit':!![]})[_0x4e5940('0xe53')]['then'](function(_0x54ffa9){const _0x54b7d4=_0x4e5940;_0x2c6280[_0x54b7d4('0xe98')]=_0x54ffa9[_0x54b7d4('0xf5d')]||[];})[_0x4e5940('0x683')](function(){const _0x2a4aa2=_0x4e5940;return _0x4bacad[_0x2a4aa2('0x22df')][_0x2a4aa2('0x1e6e')]({'userProfileId':_0x2c6280[_0x2a4aa2('0x11ed')][_0x2a4aa2('0x2f')],'sectionId':0x3ec})[_0x2a4aa2('0xe53')];})[_0x4e5940('0x683')](function(_0x582ae2){const _0x307efc=_0x4e5940,_0x43fa79=_0x582ae2&&_0x582ae2[_0x307efc('0xf5d')]?_0x582ae2['rows'][0x0]:null;if(!_0x43fa79)_0x2c6280[_0x307efc('0xe98')]=[];else{if(!_0x43fa79['autoAssociation'])return _0x4bacad[_0x307efc('0xcf7')][_0x307efc('0x1e6e')]({'sectionId':_0x43fa79['id']})[_0x307efc('0xe53')][_0x307efc('0x683')](function(_0x4cca51){const _0x112c8a=_0x307efc,_0x2588a3=_0x4cca51&&_0x4cca51[_0x112c8a('0xf5d')]?_0x4cca51[_0x112c8a('0xf5d')]:[],_0x54bb99=[];let _0x3a6172=null;_0x2c6280['interval']&&(_0x3a6172=_0x2e3ca0()[_0x112c8a('0x1c07')](_0x2c6280[_0x112c8a('0xe98')],{'name':_0x2c6280[_0x112c8a('0x115c')][_0x112c8a('0x5ae')]})),_0x3a6172&&!_0x2e3ca0()[_0x112c8a('0x7a2')](_0x2588a3,[_0x112c8a('0x832'),_0x3a6172['id']])&&_0x2c6280['intervals']['forEach'](function(_0x3fab5e){const _0x19c0ef=_0x112c8a;_0x3fab5e['id']===_0x3a6172['id']&&(_0x3fab5e[_0x19c0ef('0x319')]=![],_0x54bb99[_0x19c0ef('0x1fd0')](_0x3fab5e));}),_0x2c6280[_0x112c8a('0xe98')]=_0x54bb99;});}})[_0x4e5940('0x130a')](function(_0x55cd7e){const _0x2acfc8=_0x4e5940;_0x53d287['error']({'title':_0x55cd7e[_0x2acfc8('0x13ee')]?_0x2acfc8('0x2168')+_0x55cd7e[_0x2acfc8('0x13ee')]+_0x2acfc8('0xbf6')+_0x55cd7e['statusText']:_0x2acfc8('0x1e65'),'msg':_0x55cd7e[_0x2acfc8('0x5a5')]?JSON[_0x2acfc8('0x258a')](_0x55cd7e[_0x2acfc8('0x5a5')]):_0x55cd7e[_0x2acfc8('0x1ff0')]()});}));function _0x57964c(){const _0xbce587=_0x4e5940;switch(_0x2c6280[_0xbce587('0xcf0')]){case _0xbce587('0x10af'):case _0xbce587('0x2335'):return _0xbce587('0x1b54');case'custom':{const _0x4094fc=[];if(_0x2c6280[_0xbce587('0xc32')]!=='*'&&_0x2c6280[_0xbce587('0xc32')]&&_0x2c6280[_0xbce587('0xaa0')]){const _0x1363de=(_0x2c6280[_0xbce587('0xc32')]['getHours']()<0xa?'0':'')+_0x2c6280['timeRangeFrom']['getHours']()+':'+((_0x2c6280[_0xbce587('0xc32')]['getMinutes']()<0xa?'0':'')+_0x2c6280[_0xbce587('0xc32')][_0xbce587('0x1b5b')]()),_0x1b7668=(_0x2c6280[_0xbce587('0xaa0')][_0xbce587('0x2575')]()<0xa?'0':'')+_0x2c6280[_0xbce587('0xaa0')]['getHours']()+':'+((_0x2c6280['timeRangeTo']['getMinutes']()<0xa?'0':'')+_0x2c6280[_0xbce587('0xaa0')]['getMinutes']());_0x4094fc[_0xbce587('0x1fd0')](_0x1363de+'-'+_0x1b7668);}else _0x4094fc[_0xbce587('0x1fd0')]('*');return _0x2c6280[_0xbce587('0x232d')]?_0x2c6280[_0xbce587('0x1269')]?_0x4094fc[_0xbce587('0x1fd0')](_0x2c6280[_0xbce587('0x232d')]+'-'+_0x2c6280[_0xbce587('0x1269')]):_0x4094fc['push'](_0x2c6280[_0xbce587('0x232d')]):_0x4094fc[_0xbce587('0x1fd0')]('*'),_0x2c6280[_0xbce587('0xf13')]?_0x2c6280[_0xbce587('0xfe5')]?_0x4094fc[_0xbce587('0x1fd0')](_0x2c6280[_0xbce587('0xf13')]+'-'+_0x2c6280[_0xbce587('0xfe5')]):_0x4094fc[_0xbce587('0x1fd0')](_0x2c6280[_0xbce587('0xf13')]):_0x4094fc[_0xbce587('0x1fd0')]('*'),_0x2c6280[_0xbce587('0x1690')]?_0x2c6280[_0xbce587('0x1f12')]?_0x4094fc[_0xbce587('0x1fd0')](_0x2c6280[_0xbce587('0x1690')]+'-'+_0x2c6280['monthTo']):_0x4094fc[_0xbce587('0x1fd0')](_0x2c6280[_0xbce587('0x1690')]):_0x4094fc[_0xbce587('0x1fd0')]('*'),_0x4094fc['join']();}}}function _0x54cd59(){const _0x40e90b=_0x4e5940;_0x2c6280[_0x40e90b('0x17f')]=[],_0x2c6280[_0x40e90b('0x115c')][_0x40e90b('0x115c')]=_0x57964c(),_0x4bacad[_0x40e90b('0x115c')][_0x40e90b('0xb0a')](_0x2c6280[_0x40e90b('0x115c')])[_0x40e90b('0xe53')][_0x40e90b('0x683')](function(_0x5dfe77){const _0x158782=_0x40e90b;_0x2c6280[_0x158782('0xe98')][_0x158782('0x1fd0')](_0x5dfe77),_0x53d287[_0x158782('0x53')]({'title':'Interval\x20properly\x20created','msg':_0x2c6280[_0x158782('0x115c')][_0x158782('0x60a')]?_0x2c6280['interval'][_0x158782('0x60a')]+_0x158782('0x14b5'):''}),_0x550f4b();})[_0x40e90b('0x130a')](function(_0x357aba){const _0x3ecf9f=_0x40e90b;console[_0x3ecf9f('0x52a')](_0x357aba),_0x2c6280[_0x3ecf9f('0x17f')]=_0x357aba[_0x3ecf9f('0x5a5')][_0x3ecf9f('0x17f')]||[{'message':_0x357aba['toString'](),'type':'api.interval.save'}];});}function _0xb4ec9b(){const _0x46be56=_0x4e5940;_0x2c6280[_0x46be56('0x17f')]=[],_0x2c6280['interval'][_0x46be56('0x115c')]=_0x57964c(),_0x2c6280[_0x46be56('0x115c')][_0x46be56('0x121e')]?(_0x2c6280['type']!==_0x46be56('0x2335')&&(_0x2c6280[_0x46be56('0x115c')][_0x46be56('0x5ae')]=null),_0x550f4b(_0x2c6280[_0x46be56('0x115c')])):_0x4bacad[_0x46be56('0x115c')]['update']({'id':_0x2c6280['interval']['id']},_0x2c6280['interval'])[_0x46be56('0xe53')][_0x46be56('0x683')](function(_0x5209f0){const _0x2a9492=_0x46be56,_0x106b46=_0x2e3ca0()[_0x2a9492('0x1c07')](_0x2c6280['intervals'],{'id':_0x5209f0['id']});_0x106b46&&_0x2e3ca0()[_0x2a9492('0xf22')](_0x106b46,_0x5209f0),_0x53d287[_0x2a9492('0x53')]({'title':_0x2a9492('0x18c3'),'msg':'Interval\x20has\x20been\x20saved!'}),_0x550f4b();})[_0x46be56('0x130a')](function(_0x49bbcc){const _0x54e52d=_0x46be56;console[_0x54e52d('0x52a')](_0x49bbcc),_0x2c6280[_0x54e52d('0x17f')]=_0x49bbcc[_0x54e52d('0x5a5')][_0x54e52d('0x17f')]||[{'message':_0x49bbcc[_0x54e52d('0x1ff0')](),'type':_0x54e52d('0x605')}];});}function _0x550f4b(_0x39f8e1){const _0x27b0b6=_0x4e5940;_0x369bae[_0x27b0b6('0x1715')](_0x39f8e1);}}const _0x3a3fb2=_0x16e8b8;_0x3bedda[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x993'),'faxAccount','api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x3bedda(_0x2f59f9,_0x16221d,_0x22802f,_0x5d6cdf,_0x432a97,_0x5959ee,_0x21944e,_0x38e7bd){const _0x38eff4=_0x189033,_0x4edd0e=this;_0x4edd0e[_0x38eff4('0x11ed')]=_0x21944e[_0x38eff4('0x20b2')](),_0x4edd0e[_0x38eff4('0x17f')]=[],_0x4edd0e[_0x38eff4('0xf28')]=_0x38eff4('0xf9f')+(_0x5d6cdf[_0x38eff4('0x11f3')]||_0x5d6cdf[_0x38eff4('0x1d75')])[_0x38eff4('0x80')](),_0x4edd0e[_0x38eff4('0x1126')]=angular['copy'](_0x5d6cdf),_0x4edd0e['crudPermissions']=_0x38e7bd,_0x4edd0e['hasModulePermissions']={};if(_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x1407')])switch(_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x11f3')]?_0x4edd0e['noop'][_0x38eff4('0x11f3')]['toLowerCase']():_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x1d75')][_0x38eff4('0x93a')]()){case'custom':break;case _0x38eff4('0x205c'):{const _0x5a3ece=_0x4edd0e[_0x38eff4('0x1126')]['appdata'][_0x38eff4('0x1fc5')](',');_0x4edd0e['noop'][_0x38eff4('0x1d46')]=_0x5a3ece[0x0],_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x1a1c')]=_0x5a3ece[0x1],_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x6d9')]=_0x5a3ece[_0x38eff4('0x12c8')](0x2,_0x5a3ece[_0x38eff4('0x1564')])[_0x38eff4('0x1630')](',');}break;case _0x38eff4('0xd24'):{const _0x33d9ee=_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x1407')]['split'](',');_0x4edd0e['noop'][_0x38eff4('0x2119')]=_0x33d9ee[0x0],_0x4edd0e[_0x38eff4('0x1126')]['clientEmail']=_0x33d9ee[0x1],_0x4edd0e[_0x38eff4('0x1126')]['privateKey']=_0x33d9ee[0x2],_0x4edd0e['noop']['language']=_0x33d9ee[0x3],_0x4edd0e[_0x38eff4('0x1126')]['welcomemessage']=_0x33d9ee[_0x38eff4('0x12c8')](0x4,_0x33d9ee[_0x38eff4('0x1564')])['join'](',');}break;case _0x38eff4('0x1db1'):{const _0x478a4a=_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x1407')][_0x38eff4('0x1fc5')](',');_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x7ae')]=_0x478a4a[0x0],_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x204a')]=_0x478a4a[0x1],_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x5ba')]=_0x478a4a[0x2],_0x4edd0e[_0x38eff4('0x1126')]['botname']=_0x478a4a[0x3],_0x4edd0e['noop'][_0x38eff4('0x6d9')]=_0x478a4a[_0x38eff4('0x12c8')](0x4,_0x478a4a[_0x38eff4('0x1564')])[_0x38eff4('0x1630')](',');}break;case _0x38eff4('0x2408'):{const _0x2517be=_0x4edd0e[_0x38eff4('0x1126')]['appdata'][_0x38eff4('0x1fc5')](',');_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x35')]=isNaN(_0x2517be[0x0])?_0x2517be[0x0]:parseInt(_0x2517be[0x0],0xa),_0x4edd0e[_0x38eff4('0x1126')]['text']=_0x2517be[_0x38eff4('0x12c8')](0x1,_0x2517be[_0x38eff4('0x1564')])[_0x38eff4('0x1630')](',');}break;case _0x38eff4('0x8c2'):_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x1bcd')]=_0x4edd0e['noop'][_0x38eff4('0x1407')];break;case _0x38eff4('0x877'):_0x4edd0e['noop'][_0x38eff4('0x60a')]=_0x4edd0e['noop'][_0x38eff4('0x1407')][_0x38eff4('0x1fc5')]('=')[0x0],_0x4edd0e[_0x38eff4('0x1126')]['value']=_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x1407')][_0x38eff4('0x1fc5')]('=')[0x1];break;case'agi':_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x273a')]=_0x4edd0e['noop'][_0x38eff4('0x1407')];break;default:{const _0x15e070=_0x4edd0e['noop'][_0x38eff4('0x1407')][_0x38eff4('0x1fc5')](',');_0x4edd0e['noop'][_0x38eff4('0x1c6b')]=_0x2e3ca0()[_0x38eff4('0x173f')](_0x15e070[0x0])?_0x15e070[0x0]:isNaN(_0x15e070[0x0])?_0x15e070[0x0]:parseInt(_0x15e070[0x0],0xa);}break;}else{}_0x4edd0e[_0x38eff4('0x1126')]['type']&&_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0xcf0')][_0x38eff4('0x93a')]()===_0x38eff4('0x17cd')&&_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x11f3')][_0x38eff4('0x93a')]()===_0x38eff4('0x659')&&(_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x24fa')]=_0x4edd0e[_0x38eff4('0x1126')]['phone']?_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0xd31')][_0x38eff4('0x1fc5')]('$')[0x0]:undefined,_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0xabd')]=_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x73c')]?'CALLERID(all)='+_0x4edd0e[_0x38eff4('0x1126')][_0x38eff4('0x73c')]:undefined);_0x4edd0e[_0x38eff4('0xeb2')]=_0xbcb8ca,_0x4edd0e[_0x38eff4('0xf82')]=_0x411311;function _0xbcb8ca(){const _0x4f856c=_0x38eff4;_0x4edd0e[_0x4f856c('0x17f')]=[];const _0x5ca999=[];_0x4edd0e[_0x4f856c('0x1126')][_0x4f856c('0xcf0')]&&_0x4edd0e[_0x4f856c('0x1126')][_0x4f856c('0xcf0')][_0x4f856c('0x93a')]()===_0x4f856c('0x17cd')&&_0x4edd0e[_0x4f856c('0x1126')][_0x4f856c('0x11f3')]===_0x4f856c('0x4d2')&&(_0x4edd0e['noop']['phone']=_0x432a97[_0x4f856c('0x145a')]?(_0x4edd0e[_0x4f856c('0x1126')][_0x4f856c('0x24fa')]||'')+_0x4f856c('0x249e')+_0x432a97[_0x4f856c('0x145a')]+'}':(_0x4edd0e['noop'][_0x4f856c('0x24fa')]||'')+_0x4f856c('0x20cb'),_0x432a97[_0x4f856c('0x75b')]!==_0x4f856c('0x925')?_0x4edd0e[_0x4f856c('0x1126')][_0x4f856c('0x158e')][_0x4f856c('0x824')](_0x4f856c('0x1b1'))<0x0&&(_0x4edd0e['noop'][_0x4f856c('0x158e')]+=_0x4f856c('0x1b1')):_0x4edd0e[_0x4f856c('0x1126')][_0x4f856c('0x158e')]=_0x4edd0e[_0x4f856c('0x1126')][_0x4f856c('0x158e')]['replace'](_0x4f856c('0x1b1'),''));if(_0x4edd0e['noop'][_0x4f856c('0x11f3')]&&_0x4edd0e[_0x4f856c('0x1126')][_0x4f856c('0x11f3')]===_0x4f856c('0xbf0')){}else switch((_0x4edd0e['noop'][_0x4f856c('0x1d75')]||_0x4edd0e[_0x4f856c('0x1126')]['appType'])[_0x4f856c('0x93a')]()){case'set':_0x4edd0e['noop'][_0x4f856c('0x1407')]=_0x4edd0e[_0x4f856c('0x1126')]['name']+'='+_0x4edd0e[_0x4f856c('0x1126')]['value'];break;case'custom':break;default:_0x5ca999[0x0]=_0x4edd0e[_0x4f856c('0x1126')][_0x4f856c('0x1c6b')],_0x4edd0e[_0x4f856c('0x1126')]['appdata']=_0x5ca999['join'](',');}_0x411311(_0x4edd0e['noop']);}function _0x411311(_0x4b9934){const _0x3bd213=_0x38eff4;_0x2f59f9[_0x3bd213('0x1715')](_0x4b9934);}}const _0x141cb6=_0x3bedda;_0xd70344[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x993'),'faxAccount',_0x189033('0x56b'),'Auth','crudPermissions'];function _0xd70344(_0x56bc9c,_0xf06eeb,_0x4aa48c,_0x4217ac,_0x47b59d,_0x300feb,_0x8cb0c8,_0xe13712){const _0x155cb7=_0x189033,_0x228fbd=this;_0x228fbd[_0x155cb7('0x11ed')]=_0x8cb0c8[_0x155cb7('0x20b2')](),_0x228fbd[_0x155cb7('0x17f')]=[],_0x228fbd[_0x155cb7('0xf28')]=_0x155cb7('0xf9f')+(_0x4217ac['appType']||_0x4217ac[_0x155cb7('0x1d75')])[_0x155cb7('0x80')](),_0x228fbd[_0x155cb7('0x660')]=angular[_0x155cb7('0x1a86')](_0x4217ac),_0x228fbd['crudPermissions']=_0xe13712,_0x228fbd[_0x155cb7('0x258d')]={};if(_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1407')])switch(_0x228fbd['queue']['appType']?_0x228fbd[_0x155cb7('0x660')]['appType'][_0x155cb7('0x93a')]():_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1d75')]['toLowerCase']()){case _0x155cb7('0xbf0'):break;case _0x155cb7('0x205c'):{const _0x12619b=_0x228fbd['queue'][_0x155cb7('0x1407')]['split'](',');_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1d46')]=_0x12619b[0x0],_0x228fbd[_0x155cb7('0x660')]['language']=_0x12619b[0x1],_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x6d9')]=_0x12619b[_0x155cb7('0x12c8')](0x2,_0x12619b[_0x155cb7('0x1564')])[_0x155cb7('0x1630')](',');}break;case'dialogflowv2':{const _0xebd790=_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1407')][_0x155cb7('0x1fc5')](',');_0x228fbd[_0x155cb7('0x660')]['projectId']=_0xebd790[0x0],_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x38')]=_0xebd790[0x1],_0x228fbd['queue']['privateKey']=_0xebd790[0x2],_0x228fbd['queue'][_0x155cb7('0x1a1c')]=_0xebd790[0x3],_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x6d9')]=_0xebd790[_0x155cb7('0x12c8')](0x4,_0xebd790[_0x155cb7('0x1564')])[_0x155cb7('0x1630')](',');}break;case'amazonlex':{const _0x5498ea=_0x228fbd['queue'][_0x155cb7('0x1407')]['split'](',');_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x7ae')]=_0x5498ea[0x0],_0x228fbd['queue'][_0x155cb7('0x204a')]=_0x5498ea[0x1],_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x5ba')]=_0x5498ea[0x2],_0x228fbd[_0x155cb7('0x660')]['botname']=_0x5498ea[0x3],_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x6d9')]=_0x5498ea[_0x155cb7('0x12c8')](0x4,_0x5498ea[_0x155cb7('0x1564')])[_0x155cb7('0x1630')](',');}break;case _0x155cb7('0x2408'):{const _0x1d10cc=_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1407')][_0x155cb7('0x1fc5')](',');_0x228fbd[_0x155cb7('0x660')]['times']=isNaN(_0x1d10cc[0x0])?_0x1d10cc[0x0]:parseInt(_0x1d10cc[0x0],0xa),_0x228fbd['queue'][_0x155cb7('0x1bcd')]=_0x1d10cc[_0x155cb7('0x12c8')](0x1,_0x1d10cc[_0x155cb7('0x1564')])['join'](',');}break;case _0x155cb7('0x8c2'):_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1bcd')]=_0x228fbd['queue']['appdata'];break;case _0x155cb7('0x877'):_0x228fbd['queue'][_0x155cb7('0x60a')]=_0x228fbd['queue']['appdata'][_0x155cb7('0x1fc5')]('=')[0x0],_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1c6b')]=_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1407')][_0x155cb7('0x1fc5')]('=')[0x1];break;case _0x155cb7('0x19ae'):_0x228fbd['queue'][_0x155cb7('0x273a')]=_0x228fbd[_0x155cb7('0x660')]['appdata'];break;default:{const _0xa865ff=_0x228fbd['queue'][_0x155cb7('0x1407')][_0x155cb7('0x1fc5')](',');_0x228fbd['queue']['queue']=_0x2e3ca0()[_0x155cb7('0x173f')](_0xa865ff[0x0])?_0xa865ff[0x0]:isNaN(_0xa865ff[0x0])?_0xa865ff[0x0]:parseInt(_0xa865ff[0x0],0xa),_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1668')]=_0x2e3ca0()[_0x155cb7('0x173f')](_0xa865ff[0x1])?_0xa865ff[0x1]:isNaN(_0xa865ff[0x1])?_0xa865ff[0x1]:parseInt(_0xa865ff[0x1],0xa);}break;}else _0x228fbd['queue'][_0x155cb7('0x660')]=0x12c,_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x1668')]=0x12c;_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0xcf0')]&&_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0xcf0')]['toLowerCase']()===_0x155cb7('0x17cd')&&_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x11f3')]['toLowerCase']()===_0x155cb7('0x659')&&(_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x24fa')]=_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0xd31')]?_0x228fbd['queue']['phone'][_0x155cb7('0x1fc5')]('$')[0x0]:undefined,_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0xabd')]=_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x73c')]?'CALLERID(all)='+_0x228fbd[_0x155cb7('0x660')][_0x155cb7('0x73c')]:undefined);_0x228fbd['saveFaxAccountApp']=_0x6276d8,_0x228fbd[_0x155cb7('0xf82')]=_0x2a3922,_0x8cb0c8[_0x155cb7('0xca1')](_0x155cb7('0x20c2'))?_0x300feb[_0x155cb7('0x209c')][_0x155cb7('0x1e6e')]({'fields':'id,name,type','sort':_0x155cb7('0x60a'),'nolimit':'true'})[_0x155cb7('0xe53')][_0x155cb7('0x683')](function(_0x4d3967){const _0x56c92a=_0x155cb7;_0x228fbd[_0x56c92a('0x2da')]=_0x4d3967[_0x56c92a('0xf5d')]||[];})[_0x155cb7('0x130a')](function(_0xbd0dee){const _0x39fb0d=_0x155cb7;_0x4aa48c[_0x39fb0d('0x52a')]({'title':_0xbd0dee['status']?_0x39fb0d('0x2168')+_0xbd0dee[_0x39fb0d('0x13ee')]+_0x39fb0d('0xbf6')+_0xbd0dee[_0x39fb0d('0x24a9')]:_0x39fb0d('0x22dc'),'msg':_0xbd0dee[_0x39fb0d('0x5a5')]?JSON[_0x39fb0d('0x258a')](_0xbd0dee[_0x39fb0d('0x5a5')]):_0xbd0dee[_0x39fb0d('0x1ff0')]()});}):_0x300feb[_0x155cb7('0x209c')][_0x155cb7('0x1e6e')]({'fields':'id,name,type','sort':_0x155cb7('0x60a'),'nolimit':'true'})[_0x155cb7('0xe53')][_0x155cb7('0x683')](function(_0x58200c){const _0x5203bc=_0x155cb7;_0x228fbd['queues']=_0x58200c[_0x5203bc('0xf5d')]||[];})[_0x155cb7('0x683')](function(){const _0x2cd425=_0x155cb7;return _0x300feb[_0x2cd425('0x22df')][_0x2cd425('0x1e6e')]({'userProfileId':_0x228fbd['currentUser']['userProfileId'],'sectionId':0x385})[_0x2cd425('0xe53')];})[_0x155cb7('0x683')](function(_0x385ca9){const _0x387753=_0x155cb7,_0x3ff63d=_0x385ca9&&_0x385ca9['rows']?_0x385ca9[_0x387753('0xf5d')][0x0]:null;if(!_0x3ff63d){const _0x4d949a=[];let _0x22fdd2=null;_0x228fbd[_0x387753('0x660')]&&(_0x22fdd2=_0x2e3ca0()[_0x387753('0x1c07')](_0x228fbd[_0x387753('0x2da')],{'name':_0x228fbd[_0x387753('0x660')][_0x387753('0x660')]}));for(let _0x1f3d32=0x0;_0x1f3d32<_0x228fbd['queues']['length'];_0x1f3d32++){_0x22fdd2&&_0x228fbd[_0x387753('0x2da')][_0x1f3d32]['id']===_0x22fdd2['id']&&(_0x228fbd[_0x387753('0x2da')][_0x1f3d32][_0x387753('0x319')]=![],_0x4d949a[_0x387753('0x1fd0')](_0x228fbd[_0x387753('0x2da')][_0x1f3d32]));}_0x228fbd[_0x387753('0x2da')]=_0x4d949a;}else{if(!_0x3ff63d[_0x387753('0x170')])return _0x300feb[_0x387753('0xcf7')]['get']({'sectionId':_0x3ff63d['id']})['$promise'][_0x387753('0x683')](function(_0x36d52e){const _0x323f3b=_0x387753,_0x4c4ec5=_0x2e3ca0()[_0x323f3b('0x386')](_0x36d52e[_0x323f3b('0xf5d')],function(_0x1c0372){const _0x14d60e=_0x323f3b;return _0x2e3ca0()['find'](_0x228fbd[_0x14d60e('0x2da')],{'id':_0x1c0372[_0x14d60e('0x832')]});});let _0x4020e0=null;_0x228fbd['queue']&&(_0x4020e0=_0x2e3ca0()[_0x323f3b('0x1c07')](_0x228fbd[_0x323f3b('0x2da')],{'name':_0x228fbd[_0x323f3b('0x660')][_0x323f3b('0x660')]}));if(_0x4020e0&&!_0x2e3ca0()[_0x323f3b('0x7a2')](_0x4c4ec5,['id',_0x4020e0['id']])){const _0x2eeafe=_0x2e3ca0()[_0x323f3b('0x1c07')](_0x228fbd['queues'],{'id':_0x4020e0['id']});_0x2eeafe[_0x323f3b('0x319')]=![],_0x4c4ec5['push'](_0x2eeafe);}_0x228fbd[_0x323f3b('0x2da')]=_0x4c4ec5;});}})[_0x155cb7('0x130a')](function(_0x18a5a1){const _0xe1774f=_0x155cb7;_0x4aa48c[_0xe1774f('0x52a')]({'title':_0x18a5a1[_0xe1774f('0x13ee')]?_0xe1774f('0x2168')+_0x18a5a1['status']+'\x20-\x20'+_0x18a5a1[_0xe1774f('0x24a9')]:'SYSTEM:GETqueues','msg':_0x18a5a1[_0xe1774f('0x5a5')]?JSON[_0xe1774f('0x258a')](_0x18a5a1[_0xe1774f('0x5a5')]):_0x18a5a1[_0xe1774f('0x1ff0')]()});});function _0x6276d8(){const _0x500345=_0x155cb7;_0x228fbd[_0x500345('0x17f')]=[];const _0x55eab0=[];_0x228fbd['queue'][_0x500345('0xcf0')]&&_0x228fbd[_0x500345('0x660')][_0x500345('0xcf0')]['toLowerCase']()===_0x500345('0x17cd')&&_0x228fbd['queue'][_0x500345('0x11f3')]===_0x500345('0x4d2')&&(_0x228fbd[_0x500345('0x660')][_0x500345('0xd31')]=_0x47b59d[_0x500345('0x145a')]?(_0x228fbd[_0x500345('0x660')][_0x500345('0x24fa')]||'')+_0x500345('0x249e')+_0x47b59d[_0x500345('0x145a')]+'}':(_0x228fbd['queue']['prefix']||'')+'${EXTEN}',_0x47b59d[_0x500345('0x75b')]!==_0x500345('0x925')?_0x228fbd[_0x500345('0x660')][_0x500345('0x158e')][_0x500345('0x824')](_0x500345('0x1b1'))<0x0&&(_0x228fbd[_0x500345('0x660')][_0x500345('0x158e')]+=_0x500345('0x1b1')):_0x228fbd['queue']['options']=_0x228fbd[_0x500345('0x660')][_0x500345('0x158e')][_0x500345('0x1725')](_0x500345('0x1b1'),''));const _0x355ecb=_0x2e3ca0()[_0x500345('0x1c07')](_0x228fbd[_0x500345('0x2da')],{'name':_0x228fbd[_0x500345('0x660')]['queue']});_0x355ecb&&(_0x228fbd[_0x500345('0x660')][_0x2e3ca0()['capitalize']('fax')+'QueueId']=_0x355ecb['id']);if(_0x228fbd['queue']['appType']&&_0x228fbd[_0x500345('0x660')][_0x500345('0x11f3')]===_0x500345('0xbf0')){}else switch((_0x228fbd[_0x500345('0x660')][_0x500345('0x1d75')]||_0x228fbd['queue'][_0x500345('0x11f3')])[_0x500345('0x93a')]()){case _0x500345('0x877'):_0x228fbd[_0x500345('0x660')][_0x500345('0x1407')]=_0x228fbd[_0x500345('0x660')][_0x500345('0x60a')]+'='+_0x228fbd[_0x500345('0x660')][_0x500345('0x1c6b')];break;case _0x500345('0xbf0'):break;default:_0x55eab0[0x0]=_0x228fbd[_0x500345('0x660')][_0x500345('0x660')],_0x55eab0[0x1]=_0x228fbd[_0x500345('0x660')][_0x500345('0x1668')],_0x228fbd[_0x500345('0x660')][_0x500345('0x1407')]=_0x55eab0[_0x500345('0x1630')](',');}_0x2a3922(_0x228fbd[_0x500345('0x660')]);}function _0x2a3922(_0x2252c4){const _0x100e7f=_0x155cb7;_0x56bc9c[_0x100e7f('0x1715')](_0x2252c4);}}const _0xfe0fd7=_0xd70344;_0x46d868['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'faxAccountApp','faxAccount','api','Auth',_0x189033('0x1134')];function _0x46d868(_0x19a59e,_0x2824f3,_0x5c5803,_0x17e202,_0x2a29e7,_0x41dce2,_0xc96240,_0x21a86d){const _0x1e532d=_0x189033,_0x354543=this;_0x354543['currentUser']=_0xc96240[_0x1e532d('0x20b2')](),_0x354543[_0x1e532d('0x17f')]=[],_0x354543['title']=_0x1e532d('0xf9f')+(_0x17e202[_0x1e532d('0x11f3')]||_0x17e202[_0x1e532d('0x1d75')])[_0x1e532d('0x80')](),_0x354543[_0x1e532d('0x24f2')]=angular[_0x1e532d('0x1a86')](_0x17e202),_0x354543[_0x1e532d('0x1134')]=_0x21a86d,_0x354543[_0x1e532d('0x258d')]={};if(_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1407')])switch(_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x11f3')]?_0x354543['system'][_0x1e532d('0x11f3')][_0x1e532d('0x93a')]():_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1d75')]['toLowerCase']()){case _0x1e532d('0xbf0'):break;case _0x1e532d('0x205c'):{const _0x29e907=_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1407')]['split'](',');_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1d46')]=_0x29e907[0x0],_0x354543['system'][_0x1e532d('0x1a1c')]=_0x29e907[0x1],_0x354543['system'][_0x1e532d('0x6d9')]=_0x29e907[_0x1e532d('0x12c8')](0x2,_0x29e907['length'])['join'](',');}break;case'dialogflowv2':{const _0x45287a=_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1407')]['split'](',');_0x354543[_0x1e532d('0x24f2')]['projectId']=_0x45287a[0x0],_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x38')]=_0x45287a[0x1],_0x354543[_0x1e532d('0x24f2')]['privateKey']=_0x45287a[0x2],_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1a1c')]=_0x45287a[0x3],_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x6d9')]=_0x45287a[_0x1e532d('0x12c8')](0x4,_0x45287a[_0x1e532d('0x1564')])[_0x1e532d('0x1630')](',');}break;case _0x1e532d('0x1db1'):{const _0x30cc25=_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1407')]['split'](',');_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x7ae')]=_0x30cc25[0x0],_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x204a')]=_0x30cc25[0x1],_0x354543['system'][_0x1e532d('0x5ba')]=_0x30cc25[0x2],_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x11a9')]=_0x30cc25[0x3],_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x6d9')]=_0x30cc25[_0x1e532d('0x12c8')](0x4,_0x30cc25[_0x1e532d('0x1564')])[_0x1e532d('0x1630')](',');}break;case _0x1e532d('0x2408'):{const _0xcf3b28=_0x354543[_0x1e532d('0x24f2')]['appdata']['split'](',');_0x354543['system'][_0x1e532d('0x35')]=isNaN(_0xcf3b28[0x0])?_0xcf3b28[0x0]:parseInt(_0xcf3b28[0x0],0xa),_0x354543['system'][_0x1e532d('0x1bcd')]=_0xcf3b28[_0x1e532d('0x12c8')](0x1,_0xcf3b28[_0x1e532d('0x1564')])['join'](',');}break;case _0x1e532d('0x8c2'):_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1bcd')]=_0x354543['system'][_0x1e532d('0x1407')];break;case _0x1e532d('0x877'):_0x354543['system']['name']=_0x354543['system']['appdata'][_0x1e532d('0x1fc5')]('=')[0x0],_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1c6b')]=_0x354543['system'][_0x1e532d('0x1407')][_0x1e532d('0x1fc5')]('=')[0x1];break;case _0x1e532d('0x19ae'):_0x354543[_0x1e532d('0x24f2')]['project']=_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1407')];break;default:{const _0xde03a8=_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x1407')][_0x1e532d('0x1fc5')](',');_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x6db')]=_0x2e3ca0()[_0x1e532d('0x173f')](_0xde03a8[0x0])?_0xde03a8[0x0]:isNaN(_0xde03a8[0x0])?_0xde03a8[0x0]:parseInt(_0xde03a8[0x0],0xa),_0x354543[_0x1e532d('0x24f2')]['variable']=_0x2e3ca0()['isEmpty'](_0xde03a8[0x1])?_0xde03a8[0x1]:isNaN(_0xde03a8[0x1])?_0xde03a8[0x1]:parseInt(_0xde03a8[0x1],0xa);}}else _0x354543['system'][_0x1e532d('0x26e0')]='';_0x354543[_0x1e532d('0x24f2')]['type']&&_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0xcf0')][_0x1e532d('0x93a')]()==='outbound'&&_0x354543['system'][_0x1e532d('0x11f3')][_0x1e532d('0x93a')]()===_0x1e532d('0x659')&&(_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x24fa')]=_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0xd31')]?_0x354543['system'][_0x1e532d('0xd31')][_0x1e532d('0x1fc5')]('$')[0x0]:undefined,_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0xabd')]=_0x354543[_0x1e532d('0x24f2')]['callerID']?_0x1e532d('0xac1')+_0x354543[_0x1e532d('0x24f2')][_0x1e532d('0x73c')]:undefined);_0x354543[_0x1e532d('0xeb2')]=_0x533133,_0x354543[_0x1e532d('0xf82')]=_0xfa5039,_0xc96240[_0x1e532d('0xca1')]('admin')?_0x41dce2[_0x1e532d('0x26e0')][_0x1e532d('0x1e6e')]({'fields':_0x1e532d('0xa10'),'sort':_0x1e532d('0x60a'),'nolimit':_0x1e532d('0x26ac')})[_0x1e532d('0xe53')]['then'](function(_0x1d0bed){const _0x492299=_0x1e532d;_0x354543[_0x492299('0x220b')]=_0x1d0bed[_0x492299('0xf5d')]||[];})[_0x1e532d('0x130a')](function(_0x342ea8){const _0x12fac3=_0x1e532d;_0x5c5803[_0x12fac3('0x52a')]({'title':_0x342ea8['status']?_0x12fac3('0x2168')+_0x342ea8[_0x12fac3('0x13ee')]+_0x12fac3('0xbf6')+_0x342ea8[_0x12fac3('0x24a9')]:'SYSTEM:GET_VARIABLES','msg':_0x342ea8[_0x12fac3('0x5a5')]?JSON['stringify'](_0x342ea8[_0x12fac3('0x5a5')]):_0x342ea8[_0x12fac3('0x1ff0')]()});}):_0x41dce2[_0x1e532d('0x26e0')]['get']({'fields':'id,name','sort':_0x1e532d('0x60a'),'nolimit':'true'})[_0x1e532d('0xe53')]['then'](function(_0x1bd457){const _0x5dba2e=_0x1e532d;_0x354543[_0x5dba2e('0x220b')]=_0x1bd457[_0x5dba2e('0xf5d')]||[];})[_0x1e532d('0x683')](function(){const _0x44bbfb=_0x1e532d;return _0x41dce2[_0x44bbfb('0x22df')][_0x44bbfb('0x1e6e')]({'userProfileId':_0x354543[_0x44bbfb('0x11ed')][_0x44bbfb('0x2f')],'sectionId':0x3f4})['$promise'];})[_0x1e532d('0x683')](function(_0x22cc87){const _0x2a316d=_0x1e532d,_0x5d0906=_0x22cc87&&_0x22cc87[_0x2a316d('0xf5d')]?_0x22cc87[_0x2a316d('0xf5d')][0x0]:null;if(!_0x5d0906){const _0x4a521f=[];let _0x40390e=null;_0x354543[_0x2a316d('0x24f2')]&&(_0x40390e=_0x2e3ca0()['find'](_0x354543[_0x2a316d('0x220b')],{'name':_0x354543['system'][_0x2a316d('0x26e0')]}));for(let _0x4340be=0x0;_0x4340be<_0x354543['variables'][_0x2a316d('0x1564')];_0x4340be++){_0x40390e&&_0x354543[_0x2a316d('0x220b')][_0x4340be]['id']===_0x40390e['id']&&(_0x354543[_0x2a316d('0x220b')][_0x4340be][_0x2a316d('0x319')]=![],_0x4a521f[_0x2a316d('0x1fd0')](_0x354543[_0x2a316d('0x220b')][_0x4340be]));}_0x354543[_0x2a316d('0x220b')]=_0x4a521f;}else{if(!_0x5d0906[_0x2a316d('0x170')])return _0x41dce2[_0x2a316d('0xcf7')][_0x2a316d('0x1e6e')]({'sectionId':_0x5d0906['id']})[_0x2a316d('0xe53')][_0x2a316d('0x683')](function(_0x1bc7af){const _0x3da3dd=_0x2a316d,_0xc57035=_0x2e3ca0()[_0x3da3dd('0x386')](_0x1bc7af['rows'],function(_0x173790){const _0x40c08d=_0x3da3dd;return _0x2e3ca0()[_0x40c08d('0x1c07')](_0x354543['variables'],{'id':_0x173790[_0x40c08d('0x832')]});});let _0x19e8cf=null;_0x354543['system']&&(_0x19e8cf=_0x2e3ca0()[_0x3da3dd('0x1c07')](_0x354543[_0x3da3dd('0x220b')],{'name':_0x354543[_0x3da3dd('0x24f2')][_0x3da3dd('0x26e0')]}));if(_0x19e8cf&&!_0x2e3ca0()[_0x3da3dd('0x7a2')](_0xc57035,['id',_0x19e8cf['id']])){const _0x4df0ff=_0x2e3ca0()[_0x3da3dd('0x1c07')](_0x354543[_0x3da3dd('0x220b')],{'id':_0x19e8cf['id']});_0x4df0ff['canSelect']=![],_0xc57035[_0x3da3dd('0x1fd0')](_0x4df0ff);}_0x354543[_0x3da3dd('0x220b')]=_0xc57035;});}})[_0x1e532d('0x130a')](function(_0x398482){const _0x22477d=_0x1e532d;_0x5c5803[_0x22477d('0x52a')]({'title':_0x398482[_0x22477d('0x13ee')]?_0x22477d('0x2168')+_0x398482[_0x22477d('0x13ee')]+_0x22477d('0xbf6')+_0x398482['statusText']:_0x22477d('0x392'),'msg':_0x398482['data']?JSON[_0x22477d('0x258a')](_0x398482[_0x22477d('0x5a5')]):_0x398482[_0x22477d('0x1ff0')]()});});function _0x533133(){const _0x13f664=_0x1e532d;_0x354543[_0x13f664('0x17f')]=[];const _0xf443f0=[];_0x354543[_0x13f664('0x24f2')][_0x13f664('0xcf0')]&&_0x354543[_0x13f664('0x24f2')]['type'][_0x13f664('0x93a')]()===_0x13f664('0x17cd')&&_0x354543[_0x13f664('0x24f2')][_0x13f664('0x11f3')]==='outboundDial'&&(_0x354543[_0x13f664('0x24f2')][_0x13f664('0xd31')]=_0x2a29e7[_0x13f664('0x145a')]?(_0x354543[_0x13f664('0x24f2')][_0x13f664('0x24fa')]||'')+_0x13f664('0x249e')+_0x2a29e7[_0x13f664('0x145a')]+'}':(_0x354543[_0x13f664('0x24f2')]['prefix']||'')+_0x13f664('0x20cb'),_0x2a29e7['recordingFormat']!=='none'?_0x354543[_0x13f664('0x24f2')][_0x13f664('0x158e')][_0x13f664('0x824')](_0x13f664('0x1b1'))<0x0&&(_0x354543['system'][_0x13f664('0x158e')]+=_0x13f664('0x1b1')):_0x354543[_0x13f664('0x24f2')]['options']=_0x354543[_0x13f664('0x24f2')]['options']['replace'](_0x13f664('0x1b1'),''));if(_0x354543[_0x13f664('0x24f2')][_0x13f664('0x11f3')]&&_0x354543['system'][_0x13f664('0x11f3')]===_0x13f664('0xbf0')){}else switch((_0x354543[_0x13f664('0x24f2')][_0x13f664('0x1d75')]||_0x354543[_0x13f664('0x24f2')][_0x13f664('0x11f3')])['toLowerCase']()){case _0x13f664('0x877'):_0x354543[_0x13f664('0x24f2')][_0x13f664('0x1407')]=_0x354543['system'][_0x13f664('0x60a')]+'='+_0x354543['system'][_0x13f664('0x1c6b')];break;case'custom':break;default:_0xf443f0[0x0]=_0x354543[_0x13f664('0x24f2')][_0x13f664('0x6db')],_0xf443f0[0x1]=_0x354543[_0x13f664('0x24f2')][_0x13f664('0x26e0')],_0x354543[_0x13f664('0x24f2')]['appdata']=_0xf443f0[_0x13f664('0x1630')](',');}_0xfa5039(_0x354543[_0x13f664('0x24f2')]);}function _0xfa5039(_0x20153f){const _0x37c134=_0x1e532d;_0x19a59e[_0x37c134('0x1715')](_0x20153f);}}const _0x37dace=_0x46d868;_0x293e2e[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x993'),_0x189033('0x244a'),_0x189033('0x56b'),'Auth','crudPermissions'];function _0x293e2e(_0x576bcd,_0x3ca077,_0x427467,_0x3c1b4c,_0x33d3ab,_0x9f31ae,_0x49693d,_0x3cd6dd){const _0x57b086=_0x189033,_0x52c2d4=this;_0x52c2d4['currentUser']=_0x49693d[_0x57b086('0x20b2')](),_0x52c2d4[_0x57b086('0x17f')]=[],_0x52c2d4['title']=_0x57b086('0xf9f')+(_0x3c1b4c[_0x57b086('0x11f3')]||_0x3c1b4c['app'])[_0x57b086('0x80')](),_0x52c2d4[_0x57b086('0x270')]=angular['copy'](_0x3c1b4c),_0x52c2d4[_0x57b086('0x1134')]=_0x3cd6dd,_0x52c2d4['hasModulePermissions']={};if(_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1407')])switch(_0x52c2d4['tag'][_0x57b086('0x11f3')]?_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x11f3')]['toLowerCase']():_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1d75')][_0x57b086('0x93a')]()){case'custom':break;case _0x57b086('0x205c'):{const _0x2fd6ad=_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1407')][_0x57b086('0x1fc5')](',');_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1d46')]=_0x2fd6ad[0x0],_0x52c2d4['tag'][_0x57b086('0x1a1c')]=_0x2fd6ad[0x1],_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x6d9')]=_0x2fd6ad['slice'](0x2,_0x2fd6ad['length'])[_0x57b086('0x1630')](',');}break;case _0x57b086('0xd24'):{const _0x460589=_0x52c2d4[_0x57b086('0x270')]['appdata'][_0x57b086('0x1fc5')](',');_0x52c2d4[_0x57b086('0x270')]['projectId']=_0x460589[0x0],_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x38')]=_0x460589[0x1],_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x406')]=_0x460589[0x2],_0x52c2d4['tag'][_0x57b086('0x1a1c')]=_0x460589[0x3],_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x6d9')]=_0x460589[_0x57b086('0x12c8')](0x4,_0x460589[_0x57b086('0x1564')])[_0x57b086('0x1630')](',');}break;case'amazonlex':{const _0xcebaa5=_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1407')]['split'](',');_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x7ae')]=_0xcebaa5[0x0],_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x204a')]=_0xcebaa5[0x1],_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x5ba')]=_0xcebaa5[0x2],_0x52c2d4[_0x57b086('0x270')]['botname']=_0xcebaa5[0x3],_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x6d9')]=_0xcebaa5['slice'](0x4,_0xcebaa5[_0x57b086('0x1564')])[_0x57b086('0x1630')](',');}break;case'autoreply':{const _0x3be8a1=_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1407')][_0x57b086('0x1fc5')](',');_0x52c2d4[_0x57b086('0x270')]['times']=isNaN(_0x3be8a1[0x0])?_0x3be8a1[0x0]:parseInt(_0x3be8a1[0x0],0xa),_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1bcd')]=_0x3be8a1['slice'](0x1,_0x3be8a1[_0x57b086('0x1564')])[_0x57b086('0x1630')](',');}break;case'message':_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1bcd')]=_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1407')];break;case _0x57b086('0x877'):_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x60a')]=_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1407')]['split']('=')[0x0],_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1c6b')]=_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1407')][_0x57b086('0x1fc5')]('=')[0x1];break;case _0x57b086('0x19ae'):_0x52c2d4['tag']['project']=_0x52c2d4[_0x57b086('0x270')]['appdata'];break;default:{const _0x40c958=_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x1407')][_0x57b086('0x1fc5')](',');_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x270')]=_0x2e3ca0()['isEmpty'](_0x40c958[0x0])?_0x40c958[0x0]:isNaN(_0x40c958[0x0])?_0x40c958[0x0]:parseInt(_0x40c958[0x0],0xa);}break;}else{}_0x52c2d4[_0x57b086('0x270')][_0x57b086('0xcf0')]&&_0x52c2d4[_0x57b086('0x270')]['type'][_0x57b086('0x93a')]()===_0x57b086('0x17cd')&&_0x52c2d4[_0x57b086('0x270')][_0x57b086('0x11f3')][_0x57b086('0x93a')]()===_0x57b086('0x659')&&(_0x52c2d4['tag'][_0x57b086('0x24fa')]=_0x52c2d4[_0x57b086('0x270')]['phone']?_0x52c2d4[_0x57b086('0x270')]['phone'][_0x57b086('0x1fc5')]('$')[0x0]:undefined,_0x52c2d4[_0x57b086('0x270')][_0x57b086('0xabd')]=_0x52c2d4['tag'][_0x57b086('0x73c')]?_0x57b086('0xac1')+_0x52c2d4['tag'][_0x57b086('0x73c')]:undefined);_0x52c2d4[_0x57b086('0xeb2')]=_0x4cbcc5,_0x52c2d4[_0x57b086('0xf82')]=_0x3acf11,_0x49693d[_0x57b086('0xca1')](_0x57b086('0x20c2'))?_0x9f31ae[_0x57b086('0x270')][_0x57b086('0x1e6e')]({'fields':_0x57b086('0xa10'),'sort':_0x57b086('0x60a'),'nolimit':'true'})[_0x57b086('0xe53')]['then'](function(_0xda697e){const _0x2b9953=_0x57b086;_0x52c2d4[_0x2b9953('0x1ce6')]=_0xda697e['rows']||[];})['catch'](function(_0x301236){const _0x5329ef=_0x57b086;_0x427467['error']({'title':_0x301236['status']?'API:'+_0x301236['status']+'\x20-\x20'+_0x301236[_0x5329ef('0x24a9')]:_0x5329ef('0x14ef'),'msg':_0x301236['data']?JSON['stringify'](_0x301236[_0x5329ef('0x5a5')]):_0x301236['toString']()});}):_0x9f31ae[_0x57b086('0x270')][_0x57b086('0x1e6e')]({'fields':_0x57b086('0xa10'),'sort':_0x57b086('0x60a'),'nolimit':_0x57b086('0x26ac')})[_0x57b086('0xe53')][_0x57b086('0x683')](function(_0x5de3b3){const _0x2b1a8c=_0x57b086;_0x52c2d4[_0x2b1a8c('0x1ce6')]=_0x5de3b3[_0x2b1a8c('0xf5d')]||[];})[_0x57b086('0x683')](function(){const _0x90e507=_0x57b086;return _0x9f31ae[_0x90e507('0x22df')][_0x90e507('0x1e6e')]({'userProfileId':_0x52c2d4['currentUser'][_0x90e507('0x2f')],'sectionId':0x3f0})[_0x90e507('0xe53')];})[_0x57b086('0x683')](function(_0x3d18ce){const _0x325d86=_0x57b086,_0x263965=_0x3d18ce&&_0x3d18ce[_0x325d86('0xf5d')]?_0x3d18ce[_0x325d86('0xf5d')][0x0]:null;if(!_0x263965){const _0x4b1d96=[];let _0x558625=null;_0x52c2d4[_0x325d86('0x270')]&&(_0x558625=_0x2e3ca0()['find'](_0x52c2d4[_0x325d86('0x1ce6')],{'name':_0x52c2d4[_0x325d86('0x270')]['tag']}));for(let _0x31c20d=0x0;_0x31c20d<_0x52c2d4[_0x325d86('0x1ce6')][_0x325d86('0x1564')];_0x31c20d++){_0x558625&&_0x52c2d4[_0x325d86('0x1ce6')][_0x31c20d]['id']===_0x558625['id']&&(_0x52c2d4[_0x325d86('0x1ce6')][_0x31c20d][_0x325d86('0x319')]=![],_0x4b1d96[_0x325d86('0x1fd0')](_0x52c2d4['tags'][_0x31c20d]));}_0x52c2d4[_0x325d86('0x1ce6')]=_0x4b1d96;}else{if(!_0x263965[_0x325d86('0x170')])return _0x9f31ae[_0x325d86('0xcf7')]['get']({'sectionId':_0x263965['id']})['$promise'][_0x325d86('0x683')](function(_0xd36ae4){const _0x35631f=_0x325d86,_0x1d1b4c=_0x2e3ca0()[_0x35631f('0x386')](_0xd36ae4[_0x35631f('0xf5d')],function(_0x4f8fd2){const _0x201860=_0x35631f;return _0x2e3ca0()[_0x201860('0x1c07')](_0x52c2d4[_0x201860('0x1ce6')],{'id':_0x4f8fd2['resourceId']});});let _0xc66259=null;_0x52c2d4['tag']&&(_0xc66259=_0x2e3ca0()[_0x35631f('0x1c07')](_0x52c2d4[_0x35631f('0x1ce6')],{'name':_0x52c2d4[_0x35631f('0x270')]['tag']}));if(_0xc66259&&!_0x2e3ca0()['some'](_0x1d1b4c,['id',_0xc66259['id']])){const _0x1596bb=_0x2e3ca0()[_0x35631f('0x1c07')](_0x52c2d4[_0x35631f('0x1ce6')],{'id':_0xc66259['id']});_0x1596bb[_0x35631f('0x319')]=![],_0x1d1b4c[_0x35631f('0x1fd0')](_0x1596bb);}_0x52c2d4[_0x35631f('0x1ce6')]=_0x1d1b4c;});}})[_0x57b086('0x130a')](function(_0x2813c8){const _0x362333=_0x57b086;_0x427467[_0x362333('0x52a')]({'title':_0x2813c8[_0x362333('0x13ee')]?_0x362333('0x2168')+_0x2813c8[_0x362333('0x13ee')]+_0x362333('0xbf6')+_0x2813c8[_0x362333('0x24a9')]:'SYSTEM:GETtags','msg':_0x2813c8[_0x362333('0x5a5')]?JSON['stringify'](_0x2813c8[_0x362333('0x5a5')]):_0x2813c8[_0x362333('0x1ff0')]()});});function _0x4cbcc5(){const _0x5b2d77=_0x57b086;_0x52c2d4[_0x5b2d77('0x17f')]=[];const _0x1c52bd=[];_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0xcf0')]&&_0x52c2d4['tag'][_0x5b2d77('0xcf0')][_0x5b2d77('0x93a')]()==='outbound'&&_0x52c2d4[_0x5b2d77('0x270')]['appType']===_0x5b2d77('0x4d2')&&(_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0xd31')]=_0x33d3ab['cutdigits']?(_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0x24fa')]||'')+_0x5b2d77('0x249e')+_0x33d3ab[_0x5b2d77('0x145a')]+'}':(_0x52c2d4[_0x5b2d77('0x270')]['prefix']||'')+_0x5b2d77('0x20cb'),_0x33d3ab[_0x5b2d77('0x75b')]!=='none'?_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0x158e')]['indexOf'](_0x5b2d77('0x1b1'))<0x0&&(_0x52c2d4['tag'][_0x5b2d77('0x158e')]+=_0x5b2d77('0x1b1')):_0x52c2d4[_0x5b2d77('0x270')]['options']=_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0x158e')][_0x5b2d77('0x1725')]('U(xcally-mixmonitor-context)',''));const _0xc75410=_0x2e3ca0()['find'](_0x52c2d4['tags'],{'name':_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0x270')]});_0xc75410&&(_0x52c2d4['tag'][_0x5b2d77('0xb6d')]=_0xc75410['id']);if(_0x52c2d4[_0x5b2d77('0x270')]['appType']&&_0x52c2d4[_0x5b2d77('0x270')]['appType']===_0x5b2d77('0xbf0')){}else switch((_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0x1d75')]||_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0x11f3')])[_0x5b2d77('0x93a')]()){case _0x5b2d77('0x877'):_0x52c2d4[_0x5b2d77('0x270')]['appdata']=_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0x60a')]+'='+_0x52c2d4['tag'][_0x5b2d77('0x1c6b')];break;case'custom':break;default:_0x1c52bd[0x0]=_0x52c2d4[_0x5b2d77('0x270')][_0x5b2d77('0x270')],_0x52c2d4[_0x5b2d77('0x270')]['appdata']=_0x1c52bd[_0x5b2d77('0x1630')](',');}_0x3acf11(_0x52c2d4['tag']);}function _0x3acf11(_0x5101a8){const _0x38b548=_0x57b086;_0x576bcd[_0x38b548('0x1715')](_0x5101a8);}}const _0x5cc1c2=_0x293e2e;_0x2eabab[_0x189033('0x14be')]=['$scope',_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),_0x189033('0x1d08'),'api',_0x189033('0x1d70'),_0x189033('0xba1')];function _0x2eabab(_0xd5421d,_0x23f2e4,_0x2635de,_0x42b08b,_0x3f4da8,_0x19c817,_0x5ad4b7,_0x353f9b,_0x29813b,_0x76aa46,_0x459ec5){const _0x4a01cc=_0x189033,_0x58fb6c=this;_0x58fb6c[_0x4a01cc('0x11ed')]=_0x459ec5['getCurrentUser'](),_0x58fb6c['dispositions']={'count':0x0,'rows':[]},_0x58fb6c[_0x4a01cc('0x17')]=[],_0x58fb6c[_0x4a01cc('0x1134')],_0x58fb6c[_0x4a01cc('0x1d01')]={'first':_0x4a01cc('0x1fd1'),'second':_0x4a01cc('0x7c2'),'third':_0x4a01cc('0x10ce')},_0x58fb6c[_0x4a01cc('0x23a2')]={'fields':_0x4a01cc('0xadb'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x58fb6c[_0x4a01cc('0x12f3')]=_0x385036,_0x58fb6c[_0x4a01cc('0x26eb')]=_0x3e80c9,_0x58fb6c['success']=_0x2b65fe,_0x58fb6c[_0x4a01cc('0x13d9')]=_0x450c68,_0x58fb6c[_0x4a01cc('0xe69')]=_0x2f5384,_0x58fb6c[_0x4a01cc('0x207b')]=_0x1eceff,_0x58fb6c[_0x4a01cc('0x224b')]=_0x387fbb,_0x58fb6c[_0x4a01cc('0x238e')]=_0x77593b,_0x58fb6c['deselectDispositions']=_0x455209,_0x58fb6c[_0x4a01cc('0x1801')]=_0x18f858;function _0x385036(_0x17a895,_0x95f931){const _0x28bbec=_0x4a01cc;_0x58fb6c[_0x28bbec('0x244a')]=_0x17a895||{},_0x58fb6c[_0x28bbec('0x1134')]=typeof _0x95f931!=='undefined'?_0x95f931:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x58fb6c['query'][_0x28bbec('0xe22')]=_0x58fb6c['faxAccount']['id'],_0x58fb6c[_0x28bbec('0x23a2')]['id']=_0x58fb6c[_0x28bbec('0x244a')]['id'],_0x450c68();}function _0x2f5384(_0x28d30c,_0x49fd2d){const _0x3a1611=_0x4a01cc;_0x3f4da8[_0x3a1611('0x1d4')]({'controller':_0x3a1611('0x1ecc'),'controllerAs':'vm','templateUrl':_0x32807f,'parent':angular[_0x3a1611('0x1fcc')](_0x19c817[_0x3a1611('0x18e5')]),'targetEvent':_0x28d30c,'clickOutsideToClose':!![],'locals':{'disposition':_0x49fd2d,'dispositions':_0x58fb6c['dispositions']['rows'],'model':{'id':_0x58fb6c[_0x3a1611('0x244a')]['id'],'field':_0x3a1611('0xe22')},'license':null,'setting':null,'crudPermissions':_0x58fb6c[_0x3a1611('0x1134')]}})[_0x3a1611('0x683')](function(_0x3a41fc){if(_0x3a41fc)_0x450c68();});}function _0x3e80c9(_0x280269,_0x2b2fce){const _0x133d09=_0x4a01cc,_0xe690f2=_0x2e3ca0()[_0x133d09('0x7a2')](_0x58fb6c['dispositions'][_0x133d09('0xf5d')],[_0x133d09('0x1b62'),_0x280269['id']]),_0xa6dcad=_0x3f4da8[_0x133d09('0x1c6f')]()[_0x133d09('0xf28')](_0x353f9b[_0x133d09('0x2728')](_0x133d09('0x15d8')))['content'](_0x353f9b[_0x133d09('0x2728')](_0x133d09('0x13bf')+(_0xe690f2?'DISPOSITION_DELETE_MESSAGE_CHILDREN':_0x133d09('0x106')),{'name':_0x280269[_0x133d09('0x60a')]}))['ariaLabel'](_0x133d09('0x550'))[_0x133d09('0xe42')](_0x2b2fce)['ok']('OK')[_0x133d09('0x19fb')](_0x353f9b['instant'](_0x133d09('0x9a1')));_0x3f4da8[_0x133d09('0x1d4')](_0xa6dcad)[_0x133d09('0x683')](function(){_0x1eceff(_0x280269);});}function _0x2b65fe(_0x59d298){const _0x41c3c5=_0x4a01cc;_0x58fb6c[_0x41c3c5('0x191e')]=_0x59d298||{'count':0x0,'rows':[]};}function _0x450c68(){const _0x516d07=_0x4a01cc;_0x58fb6c[_0x516d07('0x23a2')][_0x516d07('0x1cc8')]=(_0x58fb6c[_0x516d07('0x23a2')]['page']-0x1)*_0x58fb6c[_0x516d07('0x23a2')][_0x516d07('0x6f0')],_0x58fb6c['promise']=_0x29813b['faxAccount'][_0x516d07('0x13d9')](_0x58fb6c[_0x516d07('0x23a2')],_0x2b65fe)[_0x516d07('0xe53')];}function _0x1eceff(_0x33f526){const _0x1a6a8c=_0x4a01cc;_0x29813b[_0x1a6a8c('0x43f')][_0x1a6a8c('0xd7e')]({'id':_0x33f526['id']})[_0x1a6a8c('0xe53')][_0x1a6a8c('0x683')](function(){const _0x33c838=_0x1a6a8c;_0x450c68(),_0x76aa46[_0x33c838('0x53')]({'title':_0x353f9b['instant'](_0x33c838('0x210b'))});})['catch'](function(_0x5dcfcb){const _0x2d5ec9=_0x1a6a8c;if(_0x5dcfcb[_0x2d5ec9('0x5a5')]&&_0x5dcfcb[_0x2d5ec9('0x5a5')][_0x2d5ec9('0x17f')]&&_0x5dcfcb[_0x2d5ec9('0x5a5')][_0x2d5ec9('0x17f')][_0x2d5ec9('0x1564')]){_0x58fb6c[_0x2d5ec9('0x17f')]=_0x5dcfcb[_0x2d5ec9('0x5a5')][_0x2d5ec9('0x17f')]||[{'message':_0x5dcfcb[_0x2d5ec9('0x1ff0')](),'type':_0x2d5ec9('0x189b')}];for(let _0x5b0734=0x0;_0x5b0734<_0x5dcfcb['data'][_0x2d5ec9('0x17f')][_0x2d5ec9('0x1564')];_0x5b0734++){_0x76aa46[_0x2d5ec9('0x52a')]({'title':_0x5dcfcb[_0x2d5ec9('0x5a5')][_0x2d5ec9('0x17f')][_0x5b0734][_0x2d5ec9('0xcf0')],'msg':_0x5dcfcb[_0x2d5ec9('0x5a5')][_0x2d5ec9('0x17f')][_0x5b0734][_0x2d5ec9('0x8c2')]});}}else _0x76aa46[_0x2d5ec9('0x52a')]({'title':_0x5dcfcb[_0x2d5ec9('0x13ee')]?_0x2d5ec9('0x2168')+_0x5dcfcb[_0x2d5ec9('0x13ee')]+_0x2d5ec9('0xbf6')+_0x5dcfcb[_0x2d5ec9('0x24a9')]:'SYSTEM:DELETEdisposition','msg':_0x5dcfcb['data']?JSON[_0x2d5ec9('0x258a')](_0x5dcfcb[_0x2d5ec9('0x5a5')][_0x2d5ec9('0x8c2')]):_0x5dcfcb[_0x2d5ec9('0x8c2')]||_0x5dcfcb['toString']()});});}function _0x387fbb(){const _0xb9e0ae=_0x4a01cc,_0x1b9047=angular['copy'](_0x58fb6c['selectedDispositions']);return _0x58fb6c[_0xb9e0ae('0x17')]=[],_0x1b9047;}function _0x77593b(_0x271f5a){const _0x234cc7=_0x4a01cc,_0x30595b=_0x3f4da8['confirm']()[_0x234cc7('0xf28')](_0x353f9b[_0x234cc7('0x2728')](_0x234cc7('0xfa')))['content'](_0x353f9b[_0x234cc7('0x2728')]('TOOLS.NOTIFICATIONS.DISPOSITIONS_DELETE_MESSAGE',{'total':_0x58fb6c[_0x234cc7('0x17')][_0x234cc7('0x1564')]}))[_0x234cc7('0x1040')]('Delete\x20dispositions')[_0x234cc7('0xe42')](_0x271f5a)['ok']('OK')[_0x234cc7('0x19fb')](_0x353f9b[_0x234cc7('0x2728')](_0x234cc7('0x9a1')));_0x3f4da8[_0x234cc7('0x1d4')](_0x30595b)[_0x234cc7('0x683')](function(){const _0x24b98b=_0x234cc7;_0x58fb6c[_0x24b98b('0x17')]['forEach'](function(_0x4ffa14){_0x1eceff(_0x4ffa14);}),_0x58fb6c[_0x24b98b('0x17')]=[];});}function _0x455209(){const _0x12e600=_0x4a01cc;_0x58fb6c[_0x12e600('0x17')]=[];}function _0x18f858(){const _0x3567d9=_0x4a01cc;_0x58fb6c[_0x3567d9('0x17')]=_0x58fb6c[_0x3567d9('0x191e')]['rows'];}let _0x17b2f0=!![],_0x173c07=0x1;_0xd5421d['$watch'](_0x4a01cc('0x229'),function(_0x6838b0,_0x756d4b){const _0x315a01=_0x4a01cc;_0x17b2f0?_0x5ad4b7(function(){_0x17b2f0=![];}):(!_0x756d4b&&(_0x173c07=_0x58fb6c['query']['page']),_0x6838b0!==_0x756d4b&&(_0x58fb6c[_0x315a01('0x23a2')][_0x315a01('0xdf8')]=0x1),!_0x6838b0&&(_0x58fb6c[_0x315a01('0x23a2')]['page']=_0x173c07),_0x450c68());});}const _0x24888c=_0x2eabab;_0x36d93b[_0x189033('0x14be')]=['$cookies',_0x189033('0x7a5'),_0x189033('0x938'),'$q','$translate',_0x189033('0x2f9'),_0x189033('0x1e48'),'$document','toasty','api',_0x189033('0xba1')];function _0x36d93b(_0x5ddccd,_0x4641a4,_0x57a1bd,_0x23ae2c,_0x2fb32d,_0x113297,_0x381ce6,_0x3c8c9a,_0x4226dd,_0x432f8f,_0x486a8e){const _0x4f33b2=_0x189033,_0x1fc718=this;_0x1fc718['currentUser']=_0x486a8e[_0x4f33b2('0x20b2')](),_0x1fc718[_0x4f33b2('0x244a')]={},_0x1fc718[_0x4f33b2('0x358')]={'count':0x0,'rows':[]},_0x1fc718[_0x4f33b2('0xb1')]=[],_0x1fc718[_0x4f33b2('0x1134')],_0x1fc718[_0x4f33b2('0x23a2')]={'read':_0x4f33b2('0x13c'),'closed':_0x4f33b2('0x13c'),'sort':'-createdAt','includeAll':'true','limit':0xa,'page':0x1},_0x1fc718[_0x4f33b2('0x12f3')]=_0x5e57e1,_0x1fc718[_0x4f33b2('0x26eb')]=_0x4e8136,_0x1fc718[_0x4f33b2('0x119e')]=_0x5b7e02,_0x1fc718[_0x4f33b2('0x53')]=_0x3c6d89,_0x1fc718[_0x4f33b2('0xa1b')]=_0x578499,_0x1fc718[_0x4f33b2('0x5cc')]=_0x3bcd13,_0x1fc718['openAdvancedSearch']=_0x2a634c,_0x1fc718['exportSelectedFaxAccountInteractions']=_0xf369d4,_0x1fc718['deleteFaxAccountInteraction']=_0x15d806,_0x1fc718[_0x4f33b2('0x17f7')]=_0x8fe22d;function _0x5e57e1(_0x403c9f,_0x14744e){const _0x110876=_0x4f33b2;_0x1fc718['faxAccount']=_0x403c9f,_0x1fc718[_0x110876('0x1134')]=typeof _0x14744e!==_0x110876('0x1867')?_0x14744e:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1fc718['query'][_0x110876('0xe22')]=_0x1fc718[_0x110876('0x244a')]['id'],_0x1fc718[_0x110876('0x19c9')]={'fields':_0x1f794c()},_0x564aa2();}function _0x564aa2(){const _0xd92cb3=_0x4f33b2;return _0x432f8f[_0xd92cb3('0x270')][_0xd92cb3('0x1e6e')]()['$promise'][_0xd92cb3('0x683')](function(_0xe67ab1){const _0x1784ea=_0xd92cb3;_0x1fc718[_0x1784ea('0x1ce6')]=_0xe67ab1||{'count':0x0,'rows':[]};})[_0xd92cb3('0x683')](function(){const _0xe181c8=_0xd92cb3;_0x1fc718[_0xe181c8('0xc71')]=_0x384a00();});}function _0x384a00(){const _0x48abff=_0x4f33b2;return[{'name':_0x48abff('0x10c1'),'key':_0x48abff('0x1a4'),'type':_0x48abff('0x270e'),'label':'DASHBOARDS.SELECT_DATE'},{'name':'Messages','key':_0x48abff('0x20db'),'type':_0x48abff('0xb31'),'label':_0x48abff('0x1866'),'customOptions':[{'value':0x0,'translate':'DASHBOARDS.UNREAD'},{'value':0x1,'translate':'DASHBOARDS.READ'},{'value':null,'translate':_0x48abff('0x475')}]},{'name':_0x48abff('0x1d9d'),'key':_0x48abff('0xd8a'),'type':_0x48abff('0xb31'),'label':_0x48abff('0x1b77'),'customOptions':[{'value':0x0,'translate':_0x48abff('0x10b1')},{'value':0x1,'translate':_0x48abff('0x270a')},{'value':null,'translate':_0x48abff('0x475')}]},{'name':_0x48abff('0x62c'),'key':'UserId','type':_0x48abff('0xb31'),'label':'DASHBOARDS.SELECT_AGENT','customOptions':[{'value':_0x48abff('0x13c'),'translate':_0x48abff('0x2608')},{'value':undefined,'translate':'DASHBOARDS.ALL'}]},{'name':_0x48abff('0x1e'),'key':_0x48abff('0x270'),'type':_0x48abff('0xf6c'),'label':_0x48abff('0x2264'),'options':_0x1fc718['tags'][_0x48abff('0xf5d')],'placeholder':_0x48abff('0x7cb')}];}function _0x1f794c(){const _0x45e35d=_0x4f33b2;return[{'name':'Id','column':'id','type':_0x45e35d('0x121f')},{'name':_0x45e35d('0x1309'),'column':_0x45e35d('0x1309'),'type':'autocomplete','options':{'searchFields':[_0x45e35d('0xeef'),_0x45e35d('0x510'),_0x45e35d('0x1c92')],'route':{'model':'cmContact','action':'get','params':{'fields':_0x45e35d('0x8ff'),'Contact':'@autocomplete','nolimit':!![]}},'extraOperators':[_0x45e35d('0xe55')],'excludedOperators':[_0x45e35d('0x17ee')]}},{'name':'Subject','column':_0x45e35d('0x1e66'),'type':_0x45e35d('0x1bcd'),'options':{'excludedOperators':[_0x45e35d('0x393'),'$ne']}},{'name':_0x45e35d('0x1765'),'column':_0x45e35d('0x183b'),'type':_0x45e35d('0x1bcd'),'options':{'excludedOperators':[_0x45e35d('0x393'),_0x45e35d('0x17ee')]}},{'name':'Status','column':_0x45e35d('0xd8a'),'type':'select','values':[{'id':0x0,'translate':'DASHBOARDS.OPENED'},{'id':0x1,'translate':_0x45e35d('0x270a')}],'options':{'excludedOperators':[_0x45e35d('0x17ee')]}},{'name':_0x45e35d('0x62c'),'column':_0x45e35d('0x1dad'),'type':_0x45e35d('0xeb'),'options':{'table':'i','route':{'model':_0x45e35d('0xc96'),'action':_0x45e35d('0x1e6e'),'params':{'role':_0x45e35d('0x2327'),'fields':_0x45e35d('0x2686'),'nolimit':!![]}},'searchFields':[_0x45e35d('0x11bc'),_0x45e35d('0x60a')],'extraOperators':[_0x45e35d('0xe55')],'excludedOperators':[_0x45e35d('0x17ee')]}},{'name':'Tags','column':'Tag','type':_0x45e35d('0xf6c'),'options':{'route':{'model':_0x45e35d('0x270'),'action':_0x45e35d('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x45e35d('0x1479')]}},{'name':_0x45e35d('0x10c1'),'column':'createdAt','type':_0x45e35d('0x270e'),'options':{'excludedOperators':[_0x45e35d('0x17ee')]}},{'name':_0x45e35d('0x1bb6'),'column':_0x45e35d('0x122e'),'type':_0x45e35d('0xb31'),'values':[{'id':0x1,'translate':_0x45e35d('0x38f')},{'id':0x0,'translate':_0x45e35d('0x2226')}],'options':{'excludedOperators':[_0x45e35d('0x17ee')]}}];}function _0x2a634c(){const _0x392eb0=_0x4f33b2;_0x381ce6[_0x392eb0('0x1d4')]({'controller':_0x392eb0('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x392eb0('0x1fcc')](_0x3c8c9a[_0x392eb0('0x18e5')]),'clickOutsideToClose':![],'locals':{'fields':_0x1fc718[_0x392eb0('0x19c9')][_0x392eb0('0x189a')],'color':undefined,'storagePath':_0x392eb0('0xdb6')},'fullscreen':!![]})[_0x392eb0('0x683')](function(_0x3a0f1c){const _0x49832b=_0x392eb0;_0x1fc718['query'][_0x49832b('0x19a4')]=_0x3a0f1c===![]?undefined:_0x3a0f1c;if(_0x1fc718['query']['search'])_0x578499();else _0x3a0f1c===![]&&_0x578499();})[_0x392eb0('0x130a')](function(_0x3a63ed){const _0x58b21c=_0x392eb0;_0x4226dd['error']({'title':_0x58b21c('0x1119'),'msg':_0x3a63ed[_0x58b21c('0x5a5')]?JSON[_0x58b21c('0x258a')](_0x3a63ed[_0x58b21c('0x5a5')]['message']):_0x3a63ed[_0x58b21c('0x1ff0')]()});});}function _0x5b7e02(_0x5e261e,_0x35849b,_0xf567ab){const _0x102954=_0x4f33b2;return _0x432f8f[_0x102954('0x1352')][_0x102954('0x18e8')]({'id':_0x5e261e['id'],'exists':!![],'attachments':_0xf567ab})[_0x102954('0xe53')][_0x102954('0x683')](function(_0x2429d4){const _0x218747=_0x102954,_0xbb5bd=[_0x2429d4['buffer']];let _0x5de385=_0x218747('0xa98')+_0x5e261e['id'];const _0x531847=new Blob(_0xbb5bd,{'type':_0x2429d4['type']});_0x5de385='fax-interaction'+_0x5e261e['id']+_0x218747('0x18ff');const _0xacc504=window[_0x218747('0x12e1')][_0x218747('0x1ffa')]('a');_0xacc504[_0x218747('0x130f')](_0x218747('0x2767'),URL[_0x218747('0x2820')](_0x531847)),_0xacc504[_0x218747('0x130f')](_0x218747('0x18e8'),_0x5de385),document['body'][_0x218747('0x1e43')](_0xacc504),_0xacc504[_0x218747('0x1d42')]();})[_0x102954('0x130a')](function(_0x4bcb3e){const _0x5ecb45=_0x102954;if(_0x4bcb3e[_0x5ecb45('0x5a5')]&&_0x4bcb3e[_0x5ecb45('0x5a5')][_0x5ecb45('0x17f')]&&_0x4bcb3e['data'][_0x5ecb45('0x17f')]['length'])for(let _0x166049=0x0;_0x166049<_0x4bcb3e[_0x5ecb45('0x5a5')]['errors']['length'];_0x166049+=0x1){_0x4226dd[_0x5ecb45('0x52a')]({'title':_0x4bcb3e[_0x5ecb45('0x5a5')][_0x5ecb45('0x17f')][_0x166049][_0x5ecb45('0xcf0')],'msg':_0x4bcb3e[_0x5ecb45('0x5a5')]['errors'][_0x166049]['message']});}else _0x4226dd['error']({'title':_0x4bcb3e[_0x5ecb45('0x13ee')]?_0x5ecb45('0x2168')+_0x4bcb3e[_0x5ecb45('0x13ee')]+_0x5ecb45('0xbf6')+_0x4bcb3e[_0x5ecb45('0x24a9')]:_0x5ecb45('0xb2c'),'msg':_0x4bcb3e['data']?JSON[_0x5ecb45('0x258a')](_0x4bcb3e[_0x5ecb45('0x5a5')]['message']):_0x4bcb3e['toString']()});});}function _0x4e8136(_0x13e9d8,_0x31aec8){const _0x197ea0=_0x4f33b2,_0x134b6f=_0x381ce6['confirm']()[_0x197ea0('0xf28')](_0x197ea0('0xb1f'))[_0x197ea0('0x26e3')](_0x197ea0('0xed5')+(_0x13e9d8['name']||_0x13e9d8['id']&&_0x2e3ca0()[_0x197ea0('0x2711')](_0x197ea0('0x936'))+_0x13e9d8['id']||_0x197ea0('0xa98'))+''+_0x197ea0('0x1ee7'))[_0x197ea0('0x1040')](_0x197ea0('0x19a8'))[_0x197ea0('0xe42')](_0x31aec8)['ok']('OK')['cancel'](_0x197ea0('0x16b8'));_0x381ce6[_0x197ea0('0x1d4')](_0x134b6f)[_0x197ea0('0x683')](function(){_0x15d806(_0x13e9d8);},function(){const _0xe06b96=_0x197ea0;console[_0xe06b96('0x1b2b')](_0xe06b96('0x16b8'));});}function _0x3c6d89(_0x13912c){const _0x450872=_0x4f33b2;_0x1fc718[_0x450872('0x358')]=_0x13912c||{'count':0x0,'rows':[]};for(let _0x79a684=0x0;_0x79a684<_0x1fc718[_0x450872('0x358')][_0x450872('0xf5d')]['length'];_0x79a684+=0x1){const _0x2294aa=_0x1fc718['faxAccountInteractions'][_0x450872('0xf5d')][_0x79a684];_0x5aecfa(_0x2294aa),_0x2294aa[_0x450872('0x2464')][_0x450872('0x60a')]=_0x369899(_0x2294aa);}}function _0x578499(){const _0x202acb=_0x4f33b2;_0x1fc718['query']['offset']=(_0x1fc718[_0x202acb('0x23a2')][_0x202acb('0xdf8')]-0x1)*_0x1fc718[_0x202acb('0x23a2')][_0x202acb('0x6f0')],_0x1fc718['promise']=_0x432f8f['faxInteraction'][_0x202acb('0x1e6e')](_0x1fc718['query'],_0x3c6d89)[_0x202acb('0xe53')];}function _0x3bcd13(_0x1077c9,_0x130e6e){const _0x141d31=_0x4f33b2;_0x381ce6[_0x141d31('0x1d4')]({'controller':_0x141d31('0x13ab'),'controllerAs':'vm','templateUrl':_0x37aa85,'parent':angular[_0x141d31('0x1fcc')](_0x3c8c9a[_0x141d31('0x18e5')]),'targetEvent':_0x1077c9,'clickOutsideToClose':!![],'onShowing':function(_0x44d3eb){const _0xf7e4e=_0x141d31;_0x44d3eb['vm']['init']({'id':0x1,'channel':_0xf7e4e('0x23e9'),'interaction':_0x130e6e,'spy':!![]},_0x4641a4['$parent']['vm']['setting']);}});}function _0x15d806(_0xde7b0){const _0x39a9cc=_0x4f33b2;_0x432f8f[_0x39a9cc('0x1352')][_0x39a9cc('0xd7e')]({'id':_0xde7b0['id']})['$promise'][_0x39a9cc('0x683')](function(){const _0x1eae54=_0x39a9cc;_0x2e3ca0()[_0x1eae54('0x3ec')](_0x1fc718[_0x1eae54('0x358')][_0x1eae54('0xf5d')],{'id':_0xde7b0['id']}),_0x1fc718['faxAccountInteractions'][_0x1eae54('0x50d')]-=0x1,!_0x1fc718[_0x1eae54('0x358')]['rows'][_0x1eae54('0x1564')]&&_0x578499(),_0x4226dd[_0x1eae54('0x53')]({'title':_0x1eae54('0x1c86'),'msg':_0xde7b0[_0x1eae54('0x60a')]?_0xde7b0[_0x1eae54('0x60a')]+_0x1eae54('0x194d'):''});})[_0x39a9cc('0x130a')](function(_0x51d76b){const _0x1b2cc2=_0x39a9cc;if(_0x51d76b[_0x1b2cc2('0x5a5')]&&_0x51d76b['data']['errors']&&_0x51d76b[_0x1b2cc2('0x5a5')][_0x1b2cc2('0x17f')]['length']){_0x1fc718[_0x1b2cc2('0x17f')]=_0x51d76b[_0x1b2cc2('0x5a5')][_0x1b2cc2('0x17f')]||[{'message':_0x51d76b[_0x1b2cc2('0x1ff0')](),'type':'SYSTEM:GETfaxAccount'}];for(let _0x28ff28=0x0;_0x28ff28<_0x51d76b[_0x1b2cc2('0x5a5')][_0x1b2cc2('0x17f')][_0x1b2cc2('0x1564')];_0x28ff28++){_0x4226dd['error']({'title':_0x51d76b[_0x1b2cc2('0x5a5')]['errors'][_0x28ff28][_0x1b2cc2('0xcf0')],'msg':_0x51d76b[_0x1b2cc2('0x5a5')]['errors'][_0x28ff28][_0x1b2cc2('0x8c2')]});}}else _0x4226dd[_0x1b2cc2('0x52a')]({'title':_0x51d76b[_0x1b2cc2('0x13ee')]?'API:'+_0x51d76b[_0x1b2cc2('0x13ee')]+_0x1b2cc2('0xbf6')+_0x51d76b[_0x1b2cc2('0x24a9')]:_0x1b2cc2('0x6b1'),'msg':_0x51d76b['data']?JSON['stringify'](_0x51d76b['data']['message']):_0x51d76b['message']||_0x51d76b['toString']()});});}function _0xf369d4(){const _0x5c700e=_0x4f33b2,_0x8f9541=angular['copy'](_0x1fc718[_0x5c700e('0xb1')]);return _0x1fc718[_0x5c700e('0xb1')]=[],_0x8f9541;}function _0x8fe22d(_0x295acf){const _0x4cf5c1=_0x4f33b2,_0x2ae9d9=_0x381ce6[_0x4cf5c1('0x1c6f')]()[_0x4cf5c1('0xf28')](_0x4cf5c1('0x1cba'))[_0x4cf5c1('0x26e3')](_0x4cf5c1('0xed5')+_0x1fc718[_0x4cf5c1('0xb1')][_0x4cf5c1('0x1564')]+_0x4cf5c1('0x93c')+_0x4cf5c1('0x1ee7'))['ariaLabel'](_0x4cf5c1('0xe27'))[_0x4cf5c1('0xe42')](_0x295acf)['ok']('OK')[_0x4cf5c1('0x19fb')]('CANCEL');_0x381ce6[_0x4cf5c1('0x1d4')](_0x2ae9d9)['then'](function(){const _0x2d313e=_0x4cf5c1;_0x1fc718[_0x2d313e('0xb1')][_0x2d313e('0x1299')](function(_0x2529c6){_0x15d806(_0x2529c6);}),_0x1fc718['selectedFaxAccountInteractions']=[];});}function _0x5aecfa(_0x5b8daa){const _0x2fdbf2=_0x4f33b2;_0x5b8daa[_0x2fdbf2('0x1309')]?(_0x5b8daa[_0x2fdbf2('0x12b3')]=(_0x5b8daa[_0x2fdbf2('0x1309')]['firstName']||'')+'\x20'+(_0x5b8daa[_0x2fdbf2('0x1309')]['lastName']||''),_0x5b8daa[_0x2fdbf2('0x22f9')]=_0x5b8daa[_0x2fdbf2('0x1309')][_0x2fdbf2('0x23e9')]):_0x5b8daa[_0x2fdbf2('0x12b3')]=_0x2fb32d['instant'](_0x2fdbf2('0x215e'));}function _0x369899(_0x5a08f2){const _0x59cb2e=_0x4f33b2;if(_0x5a08f2['UserId'])return _0x5a08f2[_0x59cb2e('0x10c5')]===_0x1fc718[_0x59cb2e('0x11ed')]['id']?_0x2fb32d[_0x59cb2e('0x2728')](_0x59cb2e('0x96a')):_0x5a08f2[_0x59cb2e('0x2464')]['fullname']+'\x20<'+_0x5a08f2[_0x59cb2e('0x2464')]['internal']+'>';return _0x2fb32d['instant'](_0x59cb2e('0x2608'));}let _0x11a9d7=!![],_0x396255=0x1;_0x4641a4['$watch'](_0x4f33b2('0x229'),function(_0x2225b2,_0x37b77f){const _0x52b2f6=_0x4f33b2;_0x11a9d7?_0x113297(function(){_0x11a9d7=![];}):(!_0x37b77f&&(_0x396255=_0x1fc718[_0x52b2f6('0x23a2')][_0x52b2f6('0xdf8')]),_0x2225b2!==_0x37b77f&&(_0x1fc718[_0x52b2f6('0x23a2')][_0x52b2f6('0xdf8')]=0x1),!_0x2225b2&&(_0x1fc718[_0x52b2f6('0x23a2')]['page']=_0x396255),_0x578499());});}const _0xa0e6f2=_0x36d93b,_0x1b51f4=_0x180212['p']+'src/js/modules/main/apps/fax/views/faxAccounts/edit/agentadd/agentadd.html/agentadd.html';_0x4e91fb[_0x189033('0x14be')]=[_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$document','$translate',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),'toasty',_0x189033('0xba1'),_0x189033('0x244a'),_0x189033('0x22df')];function _0x4e91fb(_0x3df0c7,_0x5ca36f,_0x4a8771,_0x475b53,_0x41769b,_0x24b72f,_0x46874a,_0x51cc94,_0x146d1a,_0x5b19cd,_0x3c3df0,_0x4e8fef){const _0x2243fd=_0x189033,_0x5884ce=this;_0x5884ce['currentUser']=_0x5b19cd[_0x2243fd('0x20b2')](),_0x5884ce[_0x2243fd('0xace')]=_0x24b72f,_0x5884ce[_0x2243fd('0x260a')]=_0x46874a,_0x5884ce[_0x2243fd('0x19b2')]=_0x5884ce['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5884ce[_0x2243fd('0x1224')]=_0x5ca36f[_0x2243fd('0x173e')]()+_0x2243fd('0x20de')+_0x5ca36f['host'](),_0x5884ce['faxAccount']=_0x3c3df0||_0x3df0c7['params'][_0x2243fd('0x244a')]||{},_0x5884ce[_0x2243fd('0x22df')]=_0x4e8fef&&_0x4e8fef[_0x2243fd('0x50d')]==0x1?_0x4e8fef[_0x2243fd('0xf5d')][0x0]:null,_0x5884ce[_0x2243fd('0x1134')]=_0x5b19cd[_0x2243fd('0x142a')](_0x5884ce[_0x2243fd('0x22df')]?_0x5884ce[_0x2243fd('0x22df')][_0x2243fd('0x1134')]:null),_0x5884ce[_0x2243fd('0x258d')]={},_0x5884ce[_0x2243fd('0x517')]=_0x3df0c7[_0x2243fd('0x7f2')][_0x2243fd('0x1904')]||0x0,_0x5884ce[_0x2243fd('0x1a9f')]=_0x538ef1,_0x5884ce[_0x2243fd('0x2814')]=_0x13256d,_0x5884ce['alert']=_0x146d1a[_0x2243fd('0x2289')],_0x5884ce[_0x2243fd('0x27f0')]=_0x22d08c,_0x5884ce[_0x2243fd('0x2483')]=_0xea0ed7,_0x5b19cd[_0x2243fd('0xca1')](_0x2243fd('0x20c2'))?_0x51cc94[_0x2243fd('0x1a93')]['get']({'fields':_0x2243fd('0xa10'),'sort':'name'})['$promise']['then'](function(_0x2c85a3){const _0x4b1901=_0x2243fd;_0x5884ce[_0x4b1901('0x20fe')]=_0x2c85a3['rows']||[];})[_0x2243fd('0x130a')](function(_0xab8f6c){const _0x258948=_0x2243fd;_0x146d1a['error']({'title':_0xab8f6c[_0x258948('0x13ee')]?_0x258948('0x2168')+_0xab8f6c['status']+_0x258948('0xbf6')+_0xab8f6c[_0x258948('0x24a9')]:_0x258948('0xfd0'),'msg':_0xab8f6c['data']?JSON[_0x258948('0x258a')](_0xab8f6c['data']):_0xab8f6c['toString']()});}):_0x51cc94['trunk'][_0x2243fd('0x1e6e')]({'fields':_0x2243fd('0xa10'),'sort':_0x2243fd('0x60a')})[_0x2243fd('0xe53')][_0x2243fd('0x683')](function(_0x34be14){const _0x2aa858=_0x2243fd;_0x5884ce[_0x2aa858('0x20fe')]=_0x34be14[_0x2aa858('0xf5d')]||[];})['then'](function(){const _0x2d51ff=_0x2243fd;return _0x51cc94[_0x2d51ff('0x22df')][_0x2d51ff('0x1e6e')]({'userProfileId':_0x5884ce['currentUser']['userProfileId'],'sectionId':0x3f3})[_0x2d51ff('0xe53')];})[_0x2243fd('0x683')](function(_0x9a578f){const _0x19ecc6=_0x2243fd,_0x3c530f=_0x9a578f&&_0x9a578f[_0x19ecc6('0xf5d')]?_0x9a578f[_0x19ecc6('0xf5d')][0x0]:null;if(!_0x3c530f){const _0x46bad5=[];let _0x189b0c=null;_0x5884ce['faxAccount']&&(_0x189b0c=_0x2e3ca0()[_0x19ecc6('0x1c07')](_0x5884ce[_0x19ecc6('0x20fe')],{'id':Number(_0x5884ce[_0x19ecc6('0x244a')]['TrunkId'])}));for(let _0x4b6a86=0x0;_0x4b6a86<_0x5884ce[_0x19ecc6('0x20fe')][_0x19ecc6('0x1564')];_0x4b6a86++){_0x189b0c&&_0x5884ce[_0x19ecc6('0x20fe')][_0x4b6a86]['id']===_0x189b0c['id']&&(_0x5884ce[_0x19ecc6('0x20fe')][_0x4b6a86]['canSelect']=![],_0x46bad5[_0x19ecc6('0x1fd0')](_0x5884ce['trunks'][_0x4b6a86]));}_0x5884ce[_0x19ecc6('0x20fe')]=_0x46bad5;}else{if(!_0x3c530f[_0x19ecc6('0x170')])return _0x51cc94[_0x19ecc6('0xcf7')][_0x19ecc6('0x1e6e')]({'sectionId':_0x3c530f['id']})[_0x19ecc6('0xe53')][_0x19ecc6('0x683')](function(_0x3a1bdd){const _0x51d42c=_0x19ecc6,_0x581407=_0x2e3ca0()[_0x51d42c('0x386')](_0x3a1bdd[_0x51d42c('0xf5d')],function(_0x54b9be){const _0x211484=_0x51d42c;return _0x2e3ca0()['find'](_0x5884ce[_0x211484('0x20fe')],{'id':_0x54b9be[_0x211484('0x832')]});});let _0x54da46=null;_0x5884ce[_0x51d42c('0x244a')]&&(_0x54da46=_0x2e3ca0()['find'](_0x5884ce[_0x51d42c('0x20fe')],{'id':Number(_0x5884ce[_0x51d42c('0x244a')][_0x51d42c('0xf10')])}));if(_0x54da46&&!_0x2e3ca0()[_0x51d42c('0x7a2')](_0x581407,['id',_0x54da46['id']])){const _0x5ed8f4=_0x2e3ca0()['find'](_0x5884ce[_0x51d42c('0x20fe')],{'id':_0x54da46['id']});_0x5ed8f4[_0x51d42c('0x319')]=![],_0x581407[_0x51d42c('0x1fd0')](_0x5ed8f4);}_0x5884ce[_0x51d42c('0x20fe')]=_0x581407;});}})[_0x2243fd('0x130a')](function(_0x46d6a0){const _0x34a759=_0x2243fd;_0x146d1a['error']({'title':_0x46d6a0[_0x34a759('0x13ee')]?'API:'+_0x46d6a0[_0x34a759('0x13ee')]+_0x34a759('0xbf6')+_0x46d6a0['statusText']:_0x34a759('0x93'),'msg':_0x46d6a0['data']?JSON['stringify'](_0x46d6a0[_0x34a759('0x5a5')]):_0x46d6a0[_0x34a759('0x1ff0')]()});}),_0x5b19cd[_0x2243fd('0xca1')](_0x2243fd('0x20c2'))?_0x51cc94['cmList'][_0x2243fd('0x1e6e')]({'fields':'id,name','sort':_0x2243fd('0x60a')})[_0x2243fd('0xe53')][_0x2243fd('0x683')](function(_0x325ee0){const _0x462097=_0x2243fd;_0x5884ce[_0x462097('0xe01')]=_0x325ee0[_0x462097('0xf5d')]||[];})[_0x2243fd('0x130a')](function(_0x1158e0){const _0x40d29e=_0x2243fd;_0x146d1a['error']({'title':_0x1158e0[_0x40d29e('0x13ee')]?_0x40d29e('0x2168')+_0x1158e0['status']+_0x40d29e('0xbf6')+_0x1158e0[_0x40d29e('0x24a9')]:_0x40d29e('0x251b'),'msg':_0x1158e0[_0x40d29e('0x5a5')]?JSON[_0x40d29e('0x258a')](_0x1158e0[_0x40d29e('0x5a5')]):_0x1158e0[_0x40d29e('0x1ff0')]()});}):_0x51cc94[_0x2243fd('0x259b')][_0x2243fd('0x1e6e')]({'fields':_0x2243fd('0xa10'),'sort':_0x2243fd('0x60a')})[_0x2243fd('0xe53')][_0x2243fd('0x683')](function(_0x447347){const _0x3242aa=_0x2243fd;_0x5884ce[_0x3242aa('0xe01')]=_0x447347['rows']||[];})[_0x2243fd('0x683')](function(){const _0x1acb98=_0x2243fd;return _0x51cc94[_0x1acb98('0x22df')][_0x1acb98('0x1e6e')]({'userProfileId':_0x5884ce[_0x1acb98('0x11ed')][_0x1acb98('0x2f')],'sectionId':0x12d})[_0x1acb98('0xe53')];})[_0x2243fd('0x683')](function(_0x7fdf3){const _0x43781e=_0x2243fd,_0x2070f9=_0x7fdf3&&_0x7fdf3[_0x43781e('0xf5d')]?_0x7fdf3[_0x43781e('0xf5d')][0x0]:null;if(!_0x2070f9){const _0x1c5eaf=[];let _0x2548b8=null;_0x5884ce[_0x43781e('0x244a')]&&(_0x2548b8=_0x2e3ca0()[_0x43781e('0x1c07')](_0x5884ce['lists'],{'id':Number(_0x5884ce[_0x43781e('0x244a')][_0x43781e('0x1e4f')])}));for(let _0xd81863=0x0;_0xd81863<_0x5884ce[_0x43781e('0xe01')]['length'];_0xd81863++){_0x2548b8&&_0x5884ce[_0x43781e('0xe01')][_0xd81863]['id']===_0x2548b8['id']&&(_0x5884ce[_0x43781e('0xe01')][_0xd81863][_0x43781e('0x319')]=![],_0x1c5eaf['push'](_0x5884ce['lists'][_0xd81863]));}_0x5884ce[_0x43781e('0xe01')]=_0x1c5eaf;}else{if(!_0x2070f9[_0x43781e('0x170')])return _0x51cc94[_0x43781e('0xcf7')][_0x43781e('0x1e6e')]({'sectionId':_0x2070f9['id']})['$promise']['then'](function(_0x148403){const _0x6c569=_0x43781e,_0x2f5fe4=_0x2e3ca0()['map'](_0x148403[_0x6c569('0xf5d')],function(_0xd12147){const _0x28c535=_0x6c569;return _0x2e3ca0()[_0x28c535('0x1c07')](_0x5884ce[_0x28c535('0xe01')],{'id':_0xd12147[_0x28c535('0x832')]});});let _0x2a5605=null;_0x5884ce['faxAccount']&&(_0x2a5605=_0x2e3ca0()[_0x6c569('0x1c07')](_0x5884ce[_0x6c569('0xe01')],{'id':Number(_0x5884ce[_0x6c569('0x244a')][_0x6c569('0x1e4f')])}));if(_0x2a5605&&!_0x2e3ca0()[_0x6c569('0x7a2')](_0x2f5fe4,['id',_0x2a5605['id']])){const _0x16ccba=_0x2e3ca0()[_0x6c569('0x1c07')](_0x5884ce[_0x6c569('0xe01')],{'id':_0x2a5605['id']});_0x16ccba[_0x6c569('0x319')]=![],_0x2f5fe4[_0x6c569('0x1fd0')](_0x16ccba);}_0x5884ce[_0x6c569('0xe01')]=_0x2f5fe4;});}})[_0x2243fd('0x130a')](function(_0x10dff9){const _0x1f7507=_0x2243fd;_0x146d1a[_0x1f7507('0x52a')]({'title':_0x10dff9[_0x1f7507('0x13ee')]?'API:'+_0x10dff9[_0x1f7507('0x13ee')]+_0x1f7507('0xbf6')+_0x10dff9['statusText']:'SYSTEM:GETlists','msg':_0x10dff9['data']?JSON['stringify'](_0x10dff9[_0x1f7507('0x5a5')]):_0x10dff9[_0x1f7507('0x1ff0')]()});}),_0x5b19cd[_0x2243fd('0xca1')](_0x2243fd('0x20c2'))?_0x51cc94[_0x2243fd('0xa4')][_0x2243fd('0x1e6e')]({'fields':_0x2243fd('0x1688'),'sort':_0x2243fd('0x60a'),'nolimit':_0x2243fd('0x26ac')})[_0x2243fd('0xe53')]['then'](function(_0xb73134){const _0xb40837=_0x2243fd;_0x5884ce[_0xb40837('0x22ab')]=_0xb73134['rows']||[];})[_0x2243fd('0x130a')](function(_0x242fad){const _0x59651b=_0x2243fd;_0x146d1a[_0x59651b('0x52a')]({'title':_0x242fad['status']?'API:'+_0x242fad[_0x59651b('0x13ee')]+_0x59651b('0xbf6')+_0x242fad[_0x59651b('0x24a9')]:'SYSTEM:GET_PAUSES','msg':_0x242fad[_0x59651b('0x5a5')]?JSON[_0x59651b('0x258a')](_0x242fad[_0x59651b('0x5a5')]):_0x242fad['toString']()});}):_0x51cc94[_0x2243fd('0xa4')][_0x2243fd('0x1e6e')]({'fields':'name,id','sort':'name','nolimit':_0x2243fd('0x26ac')})[_0x2243fd('0xe53')][_0x2243fd('0x683')](function(_0x5c02a2){_0x5884ce['pauses']=_0x5c02a2['rows']||[];})['then'](function(){const _0x989ab4=_0x2243fd;return _0x51cc94[_0x989ab4('0x22df')][_0x989ab4('0x1e6e')]({'userProfileId':_0x5884ce[_0x989ab4('0x11ed')][_0x989ab4('0x2f')],'sectionId':0x3ed})[_0x989ab4('0xe53')];})[_0x2243fd('0x683')](function(_0x48b067){const _0x18ae5d=_0x2243fd,_0x51e41d=_0x48b067&&_0x48b067[_0x18ae5d('0xf5d')]?_0x48b067[_0x18ae5d('0xf5d')][0x0]:null;if(!_0x51e41d)_0x5884ce[_0x18ae5d('0x22ab')]=[];else{if(!_0x51e41d[_0x18ae5d('0x170')])return _0x51cc94[_0x18ae5d('0xcf7')][_0x18ae5d('0x1e6e')]({'sectionId':_0x51e41d['id']})[_0x18ae5d('0xe53')][_0x18ae5d('0x683')](function(_0x4a0163){const _0x3b41b0=_0x18ae5d,_0xa7fd11=_0x2e3ca0()[_0x3b41b0('0x386')](_0x4a0163[_0x3b41b0('0xf5d')],function(_0x387210){const _0x3e16cf=_0x3b41b0;return _0x2e3ca0()[_0x3e16cf('0x1c07')](_0x5884ce[_0x3e16cf('0x22ab')],{'id':_0x387210[_0x3e16cf('0x832')]});});_0x5884ce[_0x3b41b0('0x22ab')][_0x3b41b0('0x1299')](function(_0x221b6b){const _0x331dab=_0x3b41b0;!_0x2e3ca0()[_0x331dab('0x7a2')](_0xa7fd11,['id',_0x221b6b['id']])&&(_0x221b6b[_0x331dab('0x319')]=![]),_0xa7fd11['push'](_0x221b6b);}),_0x5884ce[_0x3b41b0('0x22ab')]=_0xa7fd11;});}})['catch'](function(_0x2e5aaf){const _0x525c9e=_0x2243fd;_0x146d1a['error']({'title':_0x2e5aaf[_0x525c9e('0x13ee')]?_0x525c9e('0x2168')+_0x2e5aaf[_0x525c9e('0x13ee')]+_0x525c9e('0xbf6')+_0x2e5aaf[_0x525c9e('0x24a9')]:'SYSTEM:GETpauses','msg':_0x2e5aaf[_0x525c9e('0x5a5')]?JSON['stringify'](_0x2e5aaf[_0x525c9e('0x5a5')]):_0x2e5aaf[_0x525c9e('0x1ff0')]()});});function _0x538ef1(){const _0x38c357=_0x2243fd;if(_0x5b19cd[_0x38c357('0xca1')](_0x38c357('0x20c2')))_0x3df0c7['go'](_0x38c357('0x5ce'),{});else return _0x51cc94['userProfileSection'][_0x38c357('0x1e6e')]({'userProfileId':_0x5b19cd['getCurrentUser']()[_0x38c357('0x2f')],'sectionId':0x38e})[_0x38c357('0xe53')][_0x38c357('0x683')](function(_0x24e985){const _0x27e6a6=_0x38c357,_0x3302b4=_0x24e985&&_0x24e985[_0x27e6a6('0xf5d')]?_0x24e985[_0x27e6a6('0xf5d')][0x0]:null;_0x3302b4&&_0x3302b4[_0x27e6a6('0x1333')]?_0x3df0c7['go'](_0x27e6a6('0x5ce'),{}):_0x146d1a[_0x27e6a6('0x2289')]({'title':_0x41769b[_0x27e6a6('0x2728')](_0x27e6a6('0x213e')),'msg':_0x41769b[_0x27e6a6('0x2728')](_0x27e6a6('0xdba'))});})['catch'](function(_0x1c8e6f){const _0x88db96=_0x38c357;_0x146d1a[_0x88db96('0x52a')]({'title':_0x1c8e6f[_0x88db96('0x13ee')]?'API:'+_0x1c8e6f[_0x88db96('0x13ee')]+_0x88db96('0xbf6')+_0x1c8e6f[_0x88db96('0x24a9')]:'USERPROFILE:GET_SECTION','msg':_0x1c8e6f['status']?JSON['stringify'](_0x1c8e6f[_0x88db96('0x5a5')]):_0x1c8e6f[_0x88db96('0x1ff0')]()});});}function _0x13256d(_0xa909e,_0x43300d){const _0x4a0e6=_0x2243fd;_0x4a8771[_0x4a0e6('0x1d4')]({'controller':'FaxAccountagentaddController','controllerAs':'vm','templateUrl':_0x1b51f4,'parent':angular[_0x4a0e6('0x1fcc')](_0x475b53[_0x4a0e6('0x18e5')]),'targetEvent':_0x43300d,'clickOutsideToClose':!![],'locals':{'faxAccount':_0xa909e,'faxAccounts':_0x5884ce[_0x4a0e6('0x2595')]?_0x5884ce[_0x4a0e6('0x2595')]['rows']:[],'crudPermissions':_0x5884ce[_0x4a0e6('0x1134')],'realtime':![]}});}function _0x22d08c(){const _0x25a1bb=_0x2243fd;_0x3df0c7['go'](_0x25a1bb('0x2875'),{},{'reload':_0x25a1bb('0x2875')});}function _0xea0ed7(){const _0x332b02=_0x2243fd;_0x51cc94[_0x332b02('0x244a')][_0x332b02('0xcd')](_0x5884ce[_0x332b02('0x244a')])['$promise'][_0x332b02('0x683')](function(){const _0xc8433=_0x332b02;_0x146d1a[_0xc8433('0x53')]({'title':'FaxAccount\x20updated!','msg':_0x5884ce[_0xc8433('0x244a')][_0xc8433('0x60a')]?_0x5884ce[_0xc8433('0x244a')][_0xc8433('0x60a')]+_0xc8433('0x96c'):''});})['catch'](function(_0x1440d1){const _0x115fb9=_0x332b02;_0x146d1a['error']({'title':_0x1440d1['status']?_0x115fb9('0x2168')+_0x1440d1[_0x115fb9('0x13ee')]+_0x115fb9('0xbf6')+_0x1440d1[_0x115fb9('0x24a9')]:_0x115fb9('0x6b1'),'msg':_0x1440d1[_0x115fb9('0x5a5')]?JSON[_0x115fb9('0x258a')](_0x1440d1[_0x115fb9('0x5a5')]):_0x1440d1['toString']()});});}}const _0xfe0436=_0x4e91fb,_0x18ce15=_0x180212['p']+'src/js/modules/main/apps/fax/views/faxAccounts/create/dialog.html/dialog.html';_0x517f92[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x2595'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),'Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x517f92(_0x3f4672,_0x5afd56,_0x290c5e,_0x239983,_0x41190c,_0x326b16,_0x5087c1,_0xc97dce,_0x468e39,_0x59d22e,_0x185e47,_0x231329,_0xdfa840,_0x180b98,_0x41d7e5,_0x9a9853,_0x16fceb){const _0x4fc03a=_0x189033,_0x9acfd7=this;_0x9acfd7['license']=_0x9a9853,_0x9acfd7['setting']=_0x16fceb,_0x9acfd7[_0x4fc03a('0x11ed')]=_0x41d7e5[_0x4fc03a('0x20b2')](),_0x9acfd7['faxAccounts']=_0x468e39||{'count':0x0,'rows':[]},_0x9acfd7[_0x4fc03a('0x2a')]=_0x59d22e,_0x9acfd7[_0x4fc03a('0x22df')]=_0x185e47&&_0x185e47[_0x4fc03a('0x50d')]==0x1?_0x185e47[_0x4fc03a('0xf5d')][0x0]:null,_0x9acfd7[_0x4fc03a('0x1134')]=_0x41d7e5[_0x4fc03a('0x142a')](_0x9acfd7[_0x4fc03a('0x22df')]?_0x9acfd7[_0x4fc03a('0x22df')][_0x4fc03a('0x1134')]:null),_0x9acfd7[_0x4fc03a('0x5c4')]=_0x4fc03a('0x2595'),_0x9acfd7[_0x4fc03a('0x247')]='',_0x9acfd7['listOrderAsc']=null,_0x9acfd7[_0x4fc03a('0x222a')]=[],_0x9acfd7[_0x4fc03a('0x23a2')]={'fields':'createdAt,updatedAt,id,name,key,headerinfo,TrunkId,localstationid,ListId,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,ecm,minrate,maxrate,modem,gateway,faxdetect,t38timeout,tech,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','sort':_0x4fc03a('0xc36'),'limit':0xa,'page':0x1},_0x9acfd7['arrayecm']=_0x2e3ca0()[_0x4fc03a('0x24db')]([{'option':_0x4fc03a('0x7cd'),'value':_0x4fc03a('0x2036')},{'option':'no','value':_0x4fc03a('0x23ca')}],function(_0x10a434){const _0x38335d=_0x4fc03a;return _0x2e3ca0()[_0x38335d('0x1725')](_0x10a434['value'],new RegExp('\x27','g'),'');}),_0x9acfd7[_0x4fc03a('0x25e9')]=_0x2e3ca0()['keyBy']([{'option':_0x4fc03a('0xbf4'),'value':_0x4fc03a('0x1d13')},{'option':_0x4fc03a('0xf00'),'value':'\x274800\x27'},{'option':'7200','value':_0x4fc03a('0x1744')},{'option':_0x4fc03a('0x1e50'),'value':'\x279600\x27'},{'option':_0x4fc03a('0xe25'),'value':_0x4fc03a('0x136b')},{'option':_0x4fc03a('0x82b'),'value':_0x4fc03a('0x158a')}],function(_0x264967){const _0x409df8=_0x4fc03a;return _0x2e3ca0()['replace'](_0x264967[_0x409df8('0x1c6b')],new RegExp('\x27','g'),'');}),_0x9acfd7[_0x4fc03a('0x22cf')]=_0x2e3ca0()['keyBy']([{'option':_0x4fc03a('0xbf4'),'value':'\x272400\x27'},{'option':'4800','value':_0x4fc03a('0xf24')},{'option':_0x4fc03a('0x212c'),'value':'\x277200\x27'},{'option':_0x4fc03a('0x1e50'),'value':_0x4fc03a('0x1ace')},{'option':_0x4fc03a('0xe25'),'value':_0x4fc03a('0x136b')},{'option':_0x4fc03a('0x82b'),'value':'\x2714400\x27'}],function(_0x1eba41){const _0x327fd3=_0x4fc03a;return _0x2e3ca0()[_0x327fd3('0x1725')](_0x1eba41[_0x327fd3('0x1c6b')],new RegExp('\x27','g'),'');}),_0x9acfd7['arraytech']=_0x2e3ca0()[_0x4fc03a('0x24db')]([{'option':_0x4fc03a('0xcec'),'value':_0x4fc03a('0xb51')},{'option':_0x4fc03a('0x20bc'),'value':_0x4fc03a('0xa34')},{'option':_0x4fc03a('0x23f7'),'value':'\x27DADHI\x27'},{'option':'KHOMP','value':_0x4fc03a('0x2462')}],function(_0x37f882){const _0x4afb8f=_0x4fc03a;return _0x2e3ca0()[_0x4afb8f('0x1725')](_0x37f882[_0x4afb8f('0x1c6b')],new RegExp('\x27','g'),'');}),_0x9acfd7[_0x4fc03a('0xc63')]=_0x4f8a7e,_0x9acfd7[_0x4fc03a('0xce9')]=_0x5de2b5,_0x9acfd7[_0x4fc03a('0x213c')]=_0x1ba783,_0x9acfd7['agentadddialog']=_0x3e14a0,_0x9acfd7[_0x4fc03a('0x194f')]=_0xce3efa,_0x9acfd7[_0x4fc03a('0x53')]=_0x252454,_0x9acfd7[_0x4fc03a('0x2842')]=_0x4bbf2a,_0x9acfd7['createOrEditFaxAccount']=_0x3226ec,_0x9acfd7[_0x4fc03a('0x2240')]=_0x358a88,_0x9acfd7[_0x4fc03a('0xee4')]=_0x17a4ad,_0x9acfd7['deleteSelectedFaxAccounts']=_0x219b27,_0x9acfd7['deselectFaxAccounts']=_0x283b6f,_0x9acfd7[_0x4fc03a('0x2581')]=_0x283f1d,_0x41d7e5[_0x4fc03a('0xca1')](_0x4fc03a('0x20c2'))?_0x231329[_0x4fc03a('0x1a93')][_0x4fc03a('0x1e6e')]({'fields':_0x4fc03a('0xa10'),'sort':'name'})['$promise'][_0x4fc03a('0x683')](function(_0x51eaef){const _0x488e10=_0x4fc03a;_0x9acfd7[_0x488e10('0x20fe')]=_0x51eaef['rows']||[];})[_0x4fc03a('0x130a')](function(_0x1be802){const _0x63d749=_0x4fc03a;_0x180b98[_0x63d749('0x52a')]({'title':_0x1be802[_0x63d749('0x13ee')]?_0x63d749('0x2168')+_0x1be802['status']+_0x63d749('0xbf6')+_0x1be802[_0x63d749('0x24a9')]:'SYSTEM:GET_TRUNKS','msg':_0x1be802[_0x63d749('0x5a5')]?JSON[_0x63d749('0x258a')](_0x1be802[_0x63d749('0x5a5')]):_0x1be802[_0x63d749('0x1ff0')]()});}):_0x231329[_0x4fc03a('0x1a93')][_0x4fc03a('0x1e6e')]({'fields':_0x4fc03a('0xa10'),'sort':_0x4fc03a('0x60a')})[_0x4fc03a('0xe53')][_0x4fc03a('0x683')](function(_0x27a085){const _0x34fe3a=_0x4fc03a;_0x9acfd7[_0x34fe3a('0x20fe')]=_0x27a085[_0x34fe3a('0xf5d')]||[];})[_0x4fc03a('0x683')](function(){const _0x18cee7=_0x4fc03a;return _0x231329[_0x18cee7('0x22df')][_0x18cee7('0x1e6e')]({'userProfileId':_0x9acfd7[_0x18cee7('0x11ed')][_0x18cee7('0x2f')],'sectionId':0x3f3})['$promise'];})[_0x4fc03a('0x683')](function(_0x5aa189){const _0x3467a6=_0x4fc03a,_0x1cb543=_0x5aa189&&_0x5aa189[_0x3467a6('0xf5d')]?_0x5aa189[_0x3467a6('0xf5d')][0x0]:null;if(!_0x1cb543){const _0x11bc0d=[],_0x5c645e=[];_0x9acfd7[_0x3467a6('0x2595')][_0x3467a6('0xf5d')]['forEach'](function(_0x8a12e9){const _0x3d7ab2=_0x3467a6,_0x132492=_0x2e3ca0()[_0x3d7ab2('0x1c07')](_0x9acfd7[_0x3d7ab2('0x20fe')],{'id':Number(_0x8a12e9[_0x3d7ab2('0xf10')])});_0x5c645e[_0x3d7ab2('0x1fd0')](_0x132492);});for(let _0x590b80=0x0;_0x590b80<_0x9acfd7['trunks'][_0x3467a6('0x1564')];_0x590b80++){const _0x326545=_0x2e3ca0()['some'](_0x5c645e,{'id':_0x9acfd7[_0x3467a6('0x20fe')][_0x590b80]['id']});_0x326545&&(_0x9acfd7['trunks'][_0x590b80][_0x3467a6('0x319')]=![],_0x11bc0d[_0x3467a6('0x1fd0')](_0x9acfd7['trunks'][_0x590b80]));}_0x9acfd7[_0x3467a6('0x20fe')]=_0x11bc0d;}else{if(!_0x1cb543['autoAssociation'])return _0x231329[_0x3467a6('0xcf7')][_0x3467a6('0x1e6e')]({'sectionId':_0x1cb543['id']})['$promise'][_0x3467a6('0x683')](function(_0x11803c){const _0x503669=_0x3467a6,_0x48b86b=_0x2e3ca0()['map'](_0x11803c[_0x503669('0xf5d')],function(_0x1d11f1){const _0x276ef8=_0x503669;return _0x2e3ca0()[_0x276ef8('0x1c07')](_0x9acfd7[_0x276ef8('0x20fe')],{'id':_0x1d11f1[_0x276ef8('0x832')]});});let _0x293f8c=null;_0x293f8c=[],_0x9acfd7[_0x503669('0x2595')][_0x503669('0xf5d')][_0x503669('0x1299')](function(_0x3468ff){const _0x42a3bf=_0x503669,_0x5f08d0=_0x2e3ca0()[_0x42a3bf('0x1c07')](_0x9acfd7['trunks'],{'id':Number(_0x3468ff[_0x42a3bf('0xf10')])});_0x293f8c['push'](_0x5f08d0);}),!_0x2e3ca0()[_0x503669('0x173f')](_0x293f8c)&&_0x293f8c[_0x503669('0x1299')](function(_0x2debdb){const _0x105e46=_0x503669;if(!_0x2e3ca0()[_0x105e46('0x7a2')](_0x48b86b,['id',_0x2debdb['id']])){const _0x42f97f=_0x2e3ca0()[_0x105e46('0x1c07')](_0x9acfd7[_0x105e46('0x20fe')],{'id':_0x2debdb['id']});_0x42f97f[_0x105e46('0x319')]=![],_0x48b86b[_0x105e46('0x1fd0')](_0x42f97f);}}),_0x9acfd7['trunks']=_0x48b86b;});}})['catch'](function(_0x3e34a1){const _0xa398e9=_0x4fc03a;_0x180b98[_0xa398e9('0x52a')]({'title':_0x3e34a1[_0xa398e9('0x13ee')]?_0xa398e9('0x2168')+_0x3e34a1['status']+'\x20-\x20'+_0x3e34a1['statusText']:_0xa398e9('0x93'),'msg':_0x3e34a1[_0xa398e9('0x5a5')]?JSON[_0xa398e9('0x258a')](_0x3e34a1['data']):_0x3e34a1['toString']()});}),_0x41d7e5[_0x4fc03a('0xca1')](_0x4fc03a('0x20c2'))?_0x231329[_0x4fc03a('0x259b')]['get']({'fields':_0x4fc03a('0xa10'),'sort':_0x4fc03a('0x60a')})[_0x4fc03a('0xe53')]['then'](function(_0x194c3f){const _0x1a1bfe=_0x4fc03a;_0x9acfd7[_0x1a1bfe('0xe01')]=_0x194c3f[_0x1a1bfe('0xf5d')]||[];})[_0x4fc03a('0x130a')](function(_0x57b596){const _0x1aae82=_0x4fc03a;_0x180b98[_0x1aae82('0x52a')]({'title':_0x57b596[_0x1aae82('0x13ee')]?_0x1aae82('0x2168')+_0x57b596[_0x1aae82('0x13ee')]+_0x1aae82('0xbf6')+_0x57b596[_0x1aae82('0x24a9')]:'SYSTEM:GET_LISTS','msg':_0x57b596[_0x1aae82('0x5a5')]?JSON['stringify'](_0x57b596[_0x1aae82('0x5a5')]):_0x57b596['toString']()});}):_0x231329[_0x4fc03a('0x259b')][_0x4fc03a('0x1e6e')]({'fields':_0x4fc03a('0xa10'),'sort':_0x4fc03a('0x60a')})['$promise']['then'](function(_0x1128b7){const _0x3a2bf5=_0x4fc03a;_0x9acfd7[_0x3a2bf5('0xe01')]=_0x1128b7[_0x3a2bf5('0xf5d')]||[];})['then'](function(){const _0x169284=_0x4fc03a;return _0x231329[_0x169284('0x22df')][_0x169284('0x1e6e')]({'userProfileId':_0x9acfd7[_0x169284('0x11ed')][_0x169284('0x2f')],'sectionId':0x12d})['$promise'];})[_0x4fc03a('0x683')](function(_0x12e6ac){const _0x45a01a=_0x4fc03a,_0x5918ee=_0x12e6ac&&_0x12e6ac[_0x45a01a('0xf5d')]?_0x12e6ac[_0x45a01a('0xf5d')][0x0]:null;if(!_0x5918ee){const _0x39b6b3=[];let _0x32e7b6=null;_0x9acfd7['faxAccount']&&(_0x32e7b6=_0x2e3ca0()[_0x45a01a('0x1c07')](_0x9acfd7[_0x45a01a('0xe01')],{'id':Number(_0x9acfd7[_0x45a01a('0x244a')][_0x45a01a('0x1e4f')])}));for(let _0x58fc92=0x0;_0x58fc92<_0x9acfd7[_0x45a01a('0xe01')]['length'];_0x58fc92++){_0x32e7b6&&_0x9acfd7[_0x45a01a('0xe01')][_0x58fc92]['id']===_0x32e7b6['id']&&(_0x9acfd7['lists'][_0x58fc92][_0x45a01a('0x319')]=![],_0x39b6b3[_0x45a01a('0x1fd0')](_0x9acfd7[_0x45a01a('0xe01')][_0x58fc92]));}_0x9acfd7[_0x45a01a('0xe01')]=_0x39b6b3;}else{if(!_0x5918ee['autoAssociation'])return _0x231329['userProfileResource'][_0x45a01a('0x1e6e')]({'sectionId':_0x5918ee['id']})[_0x45a01a('0xe53')]['then'](function(_0xa3c625){const _0x576ad1=_0x45a01a,_0x19aa26=_0x2e3ca0()[_0x576ad1('0x386')](_0xa3c625[_0x576ad1('0xf5d')],function(_0x43fe3b){const _0x5efddf=_0x576ad1;return _0x2e3ca0()[_0x5efddf('0x1c07')](_0x9acfd7['lists'],{'id':_0x43fe3b['resourceId']});});let _0x5bb5df=null;_0x9acfd7[_0x576ad1('0x244a')]&&(_0x5bb5df=_0x2e3ca0()[_0x576ad1('0x1c07')](_0x9acfd7[_0x576ad1('0xe01')],{'id':Number(_0x9acfd7[_0x576ad1('0x244a')][_0x576ad1('0x1e4f')])}));if(_0x5bb5df&&!_0x2e3ca0()[_0x576ad1('0x7a2')](_0x19aa26,['id',_0x5bb5df['id']])){const _0x497dff=_0x2e3ca0()[_0x576ad1('0x1c07')](_0x9acfd7['lists'],{'id':_0x5bb5df['id']});_0x497dff[_0x576ad1('0x319')]=![],_0x19aa26[_0x576ad1('0x1fd0')](_0x497dff);}_0x9acfd7['lists']=_0x19aa26;});}})['catch'](function(_0x19d8f7){const _0x269163=_0x4fc03a;_0x180b98['error']({'title':_0x19d8f7[_0x269163('0x13ee')]?'API:'+_0x19d8f7['status']+_0x269163('0xbf6')+_0x19d8f7[_0x269163('0x24a9')]:_0x269163('0x11e3'),'msg':_0x19d8f7[_0x269163('0x5a5')]?JSON[_0x269163('0x258a')](_0x19d8f7[_0x269163('0x5a5')]):_0x19d8f7['toString']()});});function _0x4f8a7e(_0x229d00){const _0x2e70cf=_0x4fc03a;_0x290c5e['go'](_0x2e70cf('0x2836'),{'id':_0x229d00['id'],'faxAccount':_0x229d00,'crudPermissions':_0x9acfd7['crudPermissions']});}function _0x5de2b5(_0x7a2871){const _0x35642e=_0x4fc03a;_0x290c5e['go'](_0x35642e('0x2836'),{'id':_0x7a2871['id'],'tab':0x5});}function _0x1ba783(){const _0xc000f9=_0x4fc03a;if(_0x41d7e5['hasRole']('admin'))_0x290c5e['go'](_0xc000f9('0x5ce'),{});else return _0x231329[_0xc000f9('0x22df')]['get']({'userProfileId':_0x41d7e5[_0xc000f9('0x20b2')]()['userProfileId'],'sectionId':0x38e})[_0xc000f9('0xe53')]['then'](function(_0x5cb7){const _0x306ca8=_0xc000f9,_0x253f53=_0x5cb7&&_0x5cb7[_0x306ca8('0xf5d')]?_0x5cb7['rows'][0x0]:null;_0x253f53&&_0x253f53[_0x306ca8('0x1333')]?_0x290c5e['go'](_0x306ca8('0x5ce'),{}):_0x180b98['info']({'title':_0xc97dce[_0x306ca8('0x2728')](_0x306ca8('0x213e')),'msg':_0xc97dce['instant'](_0x306ca8('0xdba'))});})['catch'](function(_0x1ae08b){const _0x16ba8e=_0xc000f9;_0x180b98[_0x16ba8e('0x52a')]({'title':_0x1ae08b['status']?_0x16ba8e('0x2168')+_0x1ae08b[_0x16ba8e('0x13ee')]+'\x20-\x20'+_0x1ae08b[_0x16ba8e('0x24a9')]:_0x16ba8e('0xf2a'),'msg':_0x1ae08b[_0x16ba8e('0x13ee')]?JSON['stringify'](_0x1ae08b[_0x16ba8e('0x5a5')]):_0x1ae08b[_0x16ba8e('0x1ff0')]()});});}function _0x3e14a0(_0x10d627,_0x170003){const _0x3d1a5d=_0x4fc03a;_0x41190c[_0x3d1a5d('0x1d4')]({'controller':_0x3d1a5d('0x24cf'),'controllerAs':'vm','templateUrl':_0x1b51f4,'parent':angular['element'](_0x326b16[_0x3d1a5d('0x18e5')]),'targetEvent':_0x170003,'clickOutsideToClose':!![],'locals':{'faxAccount':_0x10d627,'faxAccounts':_0x9acfd7['faxAccounts']?_0x9acfd7[_0x3d1a5d('0x2595')][_0x3d1a5d('0xf5d')]:[],'crudPermissions':_0x9acfd7[_0x3d1a5d('0x1134')],'realtime':![]}});}function _0xce3efa(_0x4d083a,_0x46c470){const _0xecb209=_0x4fc03a,_0x1d1672=_0x41190c[_0xecb209('0x1c6f')]()[_0xecb209('0xf28')](_0xecb209('0x1b01')+_0x2e3ca0()[_0xecb209('0x1e03')](_0xecb209('0x244a'))+'?')['htmlContent'](_0xecb209('0xed5')+(_0x4d083a[_0xecb209('0x60a')]||_0xecb209('0x244a'))+''+'\x20will\x20be\x20deleted.')[_0xecb209('0x1040')]('delete\x20faxAccount')['targetEvent'](_0x46c470)['ok']('OK')['cancel'](_0xecb209('0x16b8'));_0x41190c[_0xecb209('0x1d4')](_0x1d1672)[_0xecb209('0x683')](function(){_0x358a88(_0x4d083a);},function(){const _0x59da41=_0xecb209;console[_0x59da41('0x1b2b')](_0x59da41('0x16b8'));});}let _0x5e8901=!![],_0x5d6a78=0x1;_0x3f4672['$watch']('vm.query.filter',function(_0x38b298,_0x33a8c0){const _0x3bfff5=_0x4fc03a;_0x5e8901?_0x5087c1(function(){_0x5e8901=![];}):(!_0x33a8c0&&(_0x5d6a78=_0x9acfd7[_0x3bfff5('0x23a2')][_0x3bfff5('0xdf8')]),_0x38b298!==_0x33a8c0&&(_0x9acfd7[_0x3bfff5('0x23a2')]['page']=0x1),!_0x38b298&&(_0x9acfd7[_0x3bfff5('0x23a2')][_0x3bfff5('0xdf8')]=_0x5d6a78),_0x9acfd7['getFaxAccounts']());});function _0x252454(_0xd283b2){_0x9acfd7['faxAccounts']=_0xd283b2||{'count':0x0,'rows':[]};}function _0x4bbf2a(){const _0x226233=_0x4fc03a;_0x9acfd7[_0x226233('0x23a2')][_0x226233('0x1cc8')]=(_0x9acfd7[_0x226233('0x23a2')][_0x226233('0xdf8')]-0x1)*_0x9acfd7[_0x226233('0x23a2')][_0x226233('0x6f0')],_0x41d7e5['hasRole'](_0x226233('0x20c2'))?_0x9acfd7[_0x226233('0x1883')]=_0x231329[_0x226233('0x244a')][_0x226233('0x1e6e')](_0x9acfd7[_0x226233('0x23a2')],_0x252454)[_0x226233('0xe53')]:(_0x9acfd7[_0x226233('0x23a2')]['id']=_0x9acfd7[_0x226233('0x2a')]['id'],_0x9acfd7[_0x226233('0x23a2')][_0x226233('0x1aa')]=_0x226233('0x13af'),_0x9acfd7[_0x226233('0x1883')]=_0x231329[_0x226233('0x2a')]['getResources'](_0x9acfd7[_0x226233('0x23a2')],_0x252454)[_0x226233('0xe53')]);}function _0x3226ec(_0x49121f,_0x29aef3){const _0xc6d0dd=_0x4fc03a;_0x41190c['show']({'controller':_0xc6d0dd('0x1d9a'),'controllerAs':'vm','templateUrl':_0x18ce15,'parent':angular[_0xc6d0dd('0x1fcc')](_0x326b16[_0xc6d0dd('0x18e5')]),'targetEvent':_0x49121f,'clickOutsideToClose':!![],'locals':{'faxAccount':_0x29aef3,'faxAccounts':_0x9acfd7['faxAccounts'][_0xc6d0dd('0xf5d')],'license':_0x9acfd7[_0xc6d0dd('0xace')],'setting':_0x9acfd7[_0xc6d0dd('0x260a')],'crudPermissions':_0x9acfd7[_0xc6d0dd('0x1134')]}});}function _0x358a88(_0x18914d){const _0x38c8f0=_0x4fc03a;_0x231329[_0x38c8f0('0x244a')]['delete']({'id':_0x18914d['id']})[_0x38c8f0('0xe53')]['then'](function(){const _0x24c0fb=_0x38c8f0;_0x2e3ca0()[_0x24c0fb('0x3ec')](_0x9acfd7['faxAccounts']['rows'],{'id':_0x18914d['id']}),_0x9acfd7[_0x24c0fb('0x2595')][_0x24c0fb('0x50d')]-=0x1,!_0x9acfd7['faxAccounts'][_0x24c0fb('0xf5d')][_0x24c0fb('0x1564')]&&_0x9acfd7[_0x24c0fb('0x2842')](),_0x180b98['success']({'title':_0x2e3ca0()[_0x24c0fb('0x1e03')](_0x24c0fb('0x27ae'))+'\x20deleted!','msg':_0x18914d['name']?_0x18914d[_0x24c0fb('0x60a')]+_0x24c0fb('0x194d'):''});})[_0x38c8f0('0x130a')](function(_0xf24dc){const _0x44a916=_0x38c8f0;if(_0xf24dc[_0x44a916('0x5a5')]&&_0xf24dc[_0x44a916('0x5a5')]['errors']&&_0xf24dc[_0x44a916('0x5a5')][_0x44a916('0x17f')][_0x44a916('0x1564')]){_0x9acfd7[_0x44a916('0x17f')]=_0xf24dc['data']['errors']||[{'message':_0xf24dc[_0x44a916('0x1ff0')](),'type':_0x44a916('0x37d')}];for(let _0x5d4eb5=0x0;_0x5d4eb5<_0xf24dc['data']['errors']['length'];_0x5d4eb5++){_0x180b98[_0x44a916('0x52a')]({'title':_0xf24dc[_0x44a916('0x5a5')][_0x44a916('0x17f')][_0x5d4eb5]['type'],'msg':_0xf24dc[_0x44a916('0x5a5')][_0x44a916('0x17f')][_0x5d4eb5][_0x44a916('0x8c2')]});}}else _0x180b98[_0x44a916('0x52a')]({'title':_0xf24dc[_0x44a916('0x13ee')]?'API:'+_0xf24dc[_0x44a916('0x13ee')]+_0x44a916('0xbf6')+_0xf24dc['statusText']:_0x44a916('0x37d'),'msg':_0xf24dc[_0x44a916('0x5a5')]?JSON[_0x44a916('0x258a')](_0xf24dc[_0x44a916('0x5a5')][_0x44a916('0x8c2')]):_0xf24dc[_0x44a916('0x8c2')]||_0xf24dc[_0x44a916('0x1ff0')]()});});}function _0x17a4ad(){const _0x313c81=_0x4fc03a,_0x2b7ef5=angular[_0x313c81('0x1a86')](_0x9acfd7[_0x313c81('0x222a')]);return _0x9acfd7[_0x313c81('0x222a')]=[],_0x2b7ef5;}function _0x219b27(_0x9ef639){const _0x395f8a=_0x4fc03a,_0x1bd41b=_0x41190c['confirm']()[_0x395f8a('0xf28')](_0x395f8a('0x5da'))[_0x395f8a('0x26e3')](_0x395f8a('0xed5')+_0x9acfd7[_0x395f8a('0x222a')][_0x395f8a('0x1564')]+_0x395f8a('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x395f8a('0x15e1'))[_0x395f8a('0xe42')](_0x9ef639)['ok']('OK')['cancel']('CANCEL');_0x41190c[_0x395f8a('0x1d4')](_0x1bd41b)[_0x395f8a('0x683')](function(){const _0x2e34d9=_0x395f8a;_0x9acfd7['selectedFaxAccounts'][_0x2e34d9('0x1299')](function(_0x5730cf){_0x358a88(_0x5730cf);}),_0x9acfd7['selectedFaxAccounts']=[];});}function _0x283b6f(){_0x9acfd7['selectedFaxAccounts']=[];}function _0x283f1d(){const _0x4f6418=_0x4fc03a;_0x9acfd7['selectedFaxAccounts']=_0x9acfd7['faxAccounts'][_0x4f6418('0xf5d')];}}const _0x1701a4=_0x517f92;_0x4085ba[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty','faxQueues',_0x189033('0x209c'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x4085ba(_0xcfa3c0,_0x4981b3,_0x1fe668,_0x33cbbd,_0x115140,_0x3ec83c,_0x2a770d,_0x574a43,_0x4567ab,_0x5bc461,_0x117ea1,_0x4836ac,_0x4abca6,_0x4914){const _0x4d04dc=_0x189033,_0xc3028a=this;_0xc3028a[_0x4d04dc('0x11ed')]=_0x117ea1[_0x4d04dc('0x20b2')](),_0xc3028a[_0x4d04dc('0x17f')]=[],_0xc3028a[_0x4d04dc('0x260a')]=_0x4abca6,_0xc3028a['license']=_0x4836ac,_0xc3028a[_0x4d04dc('0x1134')]=_0x4914,_0xc3028a[_0x4d04dc('0x258d')]={},_0xc3028a[_0x4d04dc('0x19b2')]=_0xc3028a[_0x4d04dc('0x260a')]&&_0xc3028a[_0x4d04dc('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xc3028a[_0x4d04dc('0xf28')]=_0x4d04dc('0x1d66'),_0xc3028a[_0x4d04dc('0x209c')]=angular[_0x4d04dc('0x1a86')](_0x4567ab),_0xc3028a[_0x4d04dc('0xec3')]=_0x574a43,_0xc3028a[_0x4d04dc('0x1ee4')]=![];!_0xc3028a[_0x4d04dc('0x209c')]&&(_0xc3028a[_0x4d04dc('0x209c')]={'strategy':_0x4d04dc('0x25ee'),'timeout':0xa},_0xc3028a[_0x4d04dc('0xf28')]=_0x4d04dc('0x1b48'),_0xc3028a[_0x4d04dc('0x1ee4')]=!![]);_0xc3028a[_0x4d04dc('0x78')]=_0x9cfeca,_0xc3028a[_0x4d04dc('0x2048')]=_0x32516b,_0xc3028a['deleteFaxQueue']=_0xd3366b,_0xc3028a[_0x4d04dc('0x16b3')]=_0x5ca31e,_0xc3028a[_0x4d04dc('0xf82')]=_0x5e5e73;function _0x9cfeca(){const _0x386693=_0x4d04dc;_0xc3028a['errors']=[],_0x5bc461[_0x386693('0x209c')][_0x386693('0xb0a')](_0xc3028a[_0x386693('0x209c')])[_0x386693('0xe53')][_0x386693('0x683')](function(_0x328ef1){const _0x3439ce=_0x386693;_0xc3028a[_0x3439ce('0xec3')][_0x3439ce('0x1167')](_0x328ef1['toJSON']()),_0x2a770d[_0x3439ce('0x53')]({'title':'FaxQueue\x20properly\x20created','msg':_0xc3028a[_0x3439ce('0x209c')][_0x3439ce('0x60a')]?_0xc3028a[_0x3439ce('0x209c')]['name']+'\x20has\x20been\x20created!':''}),_0x5e5e73(_0x328ef1);})[_0x386693('0x130a')](function(_0x1fd144){const _0x12b196=_0x386693;if(_0x1fd144['data']&&_0x1fd144[_0x12b196('0x5a5')][_0x12b196('0x17f')]&&_0x1fd144[_0x12b196('0x5a5')]['errors']['length']){_0xc3028a[_0x12b196('0x17f')]=_0x1fd144[_0x12b196('0x5a5')][_0x12b196('0x17f')]||[{'message':_0x1fd144[_0x12b196('0x1ff0')](),'type':_0x12b196('0x1edd')}];for(let _0x179cc7=0x0;_0x179cc7<_0x1fd144[_0x12b196('0x5a5')][_0x12b196('0x17f')]['length'];_0x179cc7+=0x1){_0x2a770d[_0x12b196('0x52a')]({'title':_0x1fd144[_0x12b196('0x5a5')]['errors'][_0x179cc7][_0x12b196('0xcf0')],'msg':_0x1fd144[_0x12b196('0x5a5')]['errors'][_0x179cc7][_0x12b196('0x8c2')]});}}else _0x2a770d[_0x12b196('0x52a')]({'title':_0x1fd144[_0x12b196('0x13ee')]?'API:'+_0x1fd144[_0x12b196('0x13ee')]+_0x12b196('0xbf6')+_0x1fd144[_0x12b196('0x24a9')]:'api.faxQueue.save','msg':_0x1fd144[_0x12b196('0x5a5')]?JSON[_0x12b196('0x258a')](_0x1fd144[_0x12b196('0x5a5')][_0x12b196('0x8c2')]):_0x1fd144[_0x12b196('0x1ff0')]()});});}function _0x32516b(){const _0x3333a6=_0x4d04dc;_0xc3028a[_0x3333a6('0x17f')]=[],_0x5bc461[_0x3333a6('0x209c')]['update']({'id':_0xc3028a['faxQueue']['id']},_0xc3028a[_0x3333a6('0x209c')])[_0x3333a6('0xe53')][_0x3333a6('0x683')](function(_0x1c166c){const _0x35e094=_0x3333a6,_0x12ccc5=_0x2e3ca0()[_0x35e094('0x1c07')](_0xc3028a[_0x35e094('0xec3')],{'id':_0x1c166c['id']});_0x12ccc5&&_0x2e3ca0()['merge'](_0x12ccc5,_0x2e3ca0()[_0x35e094('0x24d0')](_0x1c166c['toJSON'](),_0x2e3ca0()[_0x35e094('0x55e')](_0x12ccc5))),_0x2a770d[_0x35e094('0x53')]({'title':_0x35e094('0x858'),'msg':_0xc3028a[_0x35e094('0x209c')][_0x35e094('0x60a')]?_0xc3028a[_0x35e094('0x209c')][_0x35e094('0x60a')]+_0x35e094('0xf59'):''}),_0x5e5e73(_0x1c166c);})['catch'](function(_0x45f2d0){const _0x2f9067=_0x3333a6;if(_0x45f2d0['data']&&_0x45f2d0['data'][_0x2f9067('0x17f')]&&_0x45f2d0[_0x2f9067('0x5a5')][_0x2f9067('0x17f')]['length']){_0xc3028a[_0x2f9067('0x17f')]=_0x45f2d0[_0x2f9067('0x5a5')][_0x2f9067('0x17f')]||[{'message':_0x45f2d0['toString'](),'type':_0x2f9067('0x1d71')}];for(let _0x2082d8=0x0;_0x2082d8<_0x45f2d0[_0x2f9067('0x5a5')][_0x2f9067('0x17f')]['length'];_0x2082d8++){_0x2a770d[_0x2f9067('0x52a')]({'title':_0x45f2d0['data']['errors'][_0x2082d8][_0x2f9067('0xcf0')],'msg':_0x45f2d0[_0x2f9067('0x5a5')]['errors'][_0x2082d8][_0x2f9067('0x8c2')]});}}else _0x2a770d[_0x2f9067('0x52a')]({'title':_0x45f2d0['status']?_0x2f9067('0x2168')+_0x45f2d0[_0x2f9067('0x13ee')]+_0x2f9067('0xbf6')+_0x45f2d0[_0x2f9067('0x24a9')]:_0x2f9067('0x1d71'),'msg':_0x45f2d0[_0x2f9067('0x5a5')]?JSON[_0x2f9067('0x258a')](_0x45f2d0[_0x2f9067('0x5a5')]['message']):_0x45f2d0[_0x2f9067('0x1ff0')]()});});}function _0xd3366b(_0x365fd4){const _0xe3a4a0=_0x4d04dc;_0xc3028a[_0xe3a4a0('0x17f')]=[];const _0x477ac9=_0x33cbbd[_0xe3a4a0('0x1c6f')]()[_0xe3a4a0('0xf28')](_0xe3a4a0('0x4d'))['content'](_0xe3a4a0('0x14f5'))['ariaLabel'](_0xe3a4a0('0x1d73'))['ok'](_0xe3a4a0('0x2307'))[_0xe3a4a0('0x19fb')]('Cancel')[_0xe3a4a0('0xe42')](_0x365fd4);_0x33cbbd[_0xe3a4a0('0x1d4')](_0x477ac9)[_0xe3a4a0('0x683')](function(){const _0x5a526b=_0xe3a4a0;_0x5bc461[_0x5a526b('0x209c')][_0x5a526b('0xd7e')]({'id':_0xc3028a[_0x5a526b('0x209c')]['id']})['$promise'][_0x5a526b('0x683')](function(){const _0x28f452=_0x5a526b;_0x2e3ca0()['remove'](_0xc3028a[_0x28f452('0xec3')],{'id':_0xc3028a[_0x28f452('0x209c')]['id']}),_0x2a770d[_0x28f452('0x53')]({'title':'FaxQueue\x20properly\x20deleted!','msg':(_0xc3028a[_0x28f452('0x209c')][_0x28f452('0x60a')]||'faxQueue')+'\x20has\x20been\x20deleted!'}),_0x5e5e73(_0xc3028a[_0x28f452('0x209c')]);})[_0x5a526b('0x130a')](function(_0x1070c4){const _0x26d380=_0x5a526b;if(_0x1070c4[_0x26d380('0x5a5')]&&_0x1070c4[_0x26d380('0x5a5')][_0x26d380('0x17f')]&&_0x1070c4[_0x26d380('0x5a5')][_0x26d380('0x17f')][_0x26d380('0x1564')]){_0xc3028a[_0x26d380('0x17f')]=_0x1070c4['data'][_0x26d380('0x17f')]||[{'message':_0x1070c4['toString'](),'type':_0x26d380('0x1ed')}];for(let _0x581414=0x0;_0x581414<_0x1070c4[_0x26d380('0x5a5')][_0x26d380('0x17f')]['length'];_0x581414++){_0x2a770d['error']({'title':_0x1070c4[_0x26d380('0x5a5')][_0x26d380('0x17f')][_0x581414][_0x26d380('0xcf0')],'msg':_0x1070c4['data'][_0x26d380('0x17f')][_0x581414][_0x26d380('0x8c2')]});}}else _0x2a770d[_0x26d380('0x52a')]({'title':_0x1070c4[_0x26d380('0x13ee')]?_0x26d380('0x2168')+_0x1070c4[_0x26d380('0x13ee')]+_0x26d380('0xbf6')+_0x1070c4['statusText']:_0x26d380('0x1ed'),'msg':_0x1070c4[_0x26d380('0x5a5')]?JSON[_0x26d380('0x258a')](_0x1070c4[_0x26d380('0x5a5')]['message']):_0x1070c4[_0x26d380('0x8c2')]||_0x1070c4[_0x26d380('0x1ff0')]()});});},function(){});}function _0x5ca31e(_0x25537a){return _0x25537a===null?undefined:new Date(_0x25537a);}function _0x5e5e73(_0x3eddee){const _0x1862b6=_0x4d04dc;_0x33cbbd[_0x1862b6('0x1715')](_0x3eddee);}}const _0xe3618=_0x4085ba;_0x2524ad[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),'faxQueue',_0x189033('0xec3'),_0x189033('0x2c9'),_0x189033('0x1d08'),'Auth',_0x189033('0x1134')];function _0x2524ad(_0x112b77,_0x832b19,_0x210015,_0x57203f,_0x202b5e,_0x255128,_0x12127e,_0xf7327c,_0x1ee9f8,_0x3e7016){const _0x545c36=_0x189033,_0xf797dc=this;_0xf797dc[_0x545c36('0x11ed')]=_0x1ee9f8[_0x545c36('0x20b2')](),_0xf797dc[_0x545c36('0x209c')]=_0x202b5e,_0xf797dc[_0x545c36('0x1134')]=_0x3e7016,_0xf797dc[_0x545c36('0x2c9')]=_0x12127e,_0xf797dc[_0x545c36('0x1996')]=[],_0xf797dc[_0x545c36('0x1c47')]=[],_0xf797dc[_0x545c36('0x1378')]=[],_0xf797dc[_0x545c36('0x125e')]=[],_0xf797dc['startingSelectedItems']=[],_0xf797dc[_0x545c36('0x2106')]=![],_0xf797dc['onInit']=_0x15e79e,_0xf797dc[_0x545c36('0xa5f')]=_0x5c8bfb,_0xf797dc['closeDialog']=_0x223d70,_0xf797dc[_0x545c36('0x169f')]={'readOnly':!_0xf797dc[_0x545c36('0x1134')][_0x545c36('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x545c36('0x60a'),'line1':_0x545c36('0x11bc'),'line2':[_0x545c36('0x60a'),_0x545c36('0x1d43')],'line3':'','labelAll':_0xf7327c[_0x545c36('0x2728')]('FAX.ALL_AGENTS'),'labelSelected':_0xf7327c[_0x545c36('0x2728')](_0x545c36('0x1e86')),'transferCallback':function(){const _0x2ba533=_0x545c36,_0x24aaad=_0x2e3ca0()[_0x2ba533('0x25cb')](_0xf797dc['startingSelectedItems'],_0xf797dc['selectedItems'],'id');_0xf797dc[_0x2ba533('0x2106')]=_0x2e3ca0()[_0x2ba533('0x173f')](_0x24aaad)?![]:!![];}};function _0x15e79e(){const _0x1c6603=_0x545c36;return _0x1ee9f8[_0x1c6603('0xca1')](_0x1c6603('0x20c2'))?_0x2c2d33()[_0x1c6603('0x130a')](function(_0x3ace55){const _0x9063d3=_0x1c6603;_0x210015[_0x9063d3('0x52a')]({'title':_0x3ace55[_0x9063d3('0x13ee')]?_0x9063d3('0x2168')+_0x3ace55[_0x9063d3('0x13ee')]+_0x9063d3('0xbf6')+_0x3ace55[_0x9063d3('0x24a9')]:_0x9063d3('0x144f'),'msg':_0x3ace55[_0x9063d3('0x13ee')]?JSON['stringify'](_0x3ace55[_0x9063d3('0x5a5')]):_0x3ace55[_0x9063d3('0x1ff0')]()});}):_0x197982()[_0x1c6603('0x683')](function(_0xd8e743){const _0x2961cf=_0x1c6603;return _0xf797dc[_0x2961cf('0x1aa')]=_0xd8e743,_0x2c2d33();})[_0x1c6603('0x130a')](function(_0xe4c62){const _0x37b128=_0x1c6603;_0x210015[_0x37b128('0x52a')]({'title':_0xe4c62[_0x37b128('0x13ee')]?_0x37b128('0x2168')+_0xe4c62[_0x37b128('0x13ee')]+_0x37b128('0xbf6')+_0xe4c62['statusText']:'SYSTEM:GET_AGENTS','msg':_0xe4c62[_0x37b128('0x13ee')]?JSON['stringify'](_0xe4c62['data']):_0xe4c62[_0x37b128('0x1ff0')]()});});}function _0x197982(){return _0x832b19(function(_0x2c2bb1,_0x3eff25){const _0x46b620=a0_0x4e0a;_0x57203f[_0x46b620('0x22df')][_0x46b620('0x1e6e')]({'userProfileId':_0xf797dc[_0x46b620('0x11ed')]['userProfileId'],'name':'Agents'})['$promise'][_0x46b620('0x683')](function(_0x2e5d3a){const _0x48810e=_0x46b620,_0x2d9662=_0x2e5d3a&&_0x2e5d3a[_0x48810e('0xf5d')]?_0x2e5d3a[_0x48810e('0xf5d')][0x0]:null;_0x2c2bb1(_0x2d9662);})[_0x46b620('0x130a')](function(_0x121f45){_0x3eff25(_0x121f45);});});}function _0x2c2d33(){return _0x832b19(function(_0x546345,_0x1fc9d6){const _0x2e33dd=a0_0x4e0a;return _0x44078d()[_0x2e33dd('0x683')](function(_0x2b44e2){const _0x4aa0e9=_0x2e33dd;return _0xf797dc[_0x4aa0e9('0x1996')]=_0x2b44e2[_0x4aa0e9('0xf5d')]?_0x2b44e2[_0x4aa0e9('0xf5d')]:[],_0x1ee9f8[_0x4aa0e9('0xca1')](_0x4aa0e9('0x20c2'))?_0x2b44e2:_0xf797dc[_0x4aa0e9('0x1aa')]?_0xf797dc[_0x4aa0e9('0x1aa')][_0x4aa0e9('0x170')]?_0x2b44e2:_0x1d63ee():null;})[_0x2e33dd('0x683')](function(_0x7a1716){const _0x84f176=_0x2e33dd,_0x142d50=_0x7a1716&&_0x7a1716[_0x84f176('0xf5d')]?_0x7a1716[_0x84f176('0xf5d')]:[];return _0xf797dc[_0x84f176('0x1c47')]=_0x2e3ca0()[_0x84f176('0x386')](_0x142d50,function(_0x2f9a4a){const _0xe0b235=_0x84f176;return _0x2e3ca0()[_0xe0b235('0x1c07')](_0xf797dc[_0xe0b235('0x1996')],{'id':_0x1ee9f8[_0xe0b235('0xca1')](_0xe0b235('0x20c2'))||_0xf797dc[_0xe0b235('0x1aa')][_0xe0b235('0x170')]?_0x2f9a4a['id']:_0x2f9a4a[_0xe0b235('0x832')]});}),_0xf797dc[_0x84f176('0x125e')]=angular['copy'](_0xf797dc[_0x84f176('0x1c47')]),_0xf797dc[_0x84f176('0x1996')]['forEach'](function(_0x3254be){const _0x358d2c=_0x84f176,_0x1e8dc8=_0x2e3ca0()[_0x358d2c('0x1c07')](_0xf797dc[_0x358d2c('0x1c47')],{'id':_0x3254be['id']});_0x1ee9f8[_0x358d2c('0xca1')]('admin')?_0x3254be[_0x358d2c('0x24f4')]=!![]:_0x3254be[_0x358d2c('0x24f4')]=typeof _0x1e8dc8!==_0x358d2c('0x1867')?!![]:![];}),_0x50158d();})[_0x2e33dd('0x683')](function(_0x495baf){const _0x41b041=_0x2e33dd,_0x2a39cf=_0x495baf&&_0x495baf['rows']?_0x495baf[_0x41b041('0xf5d')]:[];_0xf797dc[_0x41b041('0x1378')]=_0x2e3ca0()[_0x41b041('0x386')](_0x2a39cf,function(_0x47ee5e){const _0x4d1ae0=_0x41b041,_0x3ed139=_0x2e3ca0()[_0x4d1ae0('0x1c07')](_0xf797dc['items'],{'id':_0x47ee5e['id']});return _0x3ed139['penalty']=_0x47ee5e[_0x4d1ae0('0xb42')]?_0x4d1ae0('0x23d0')+_0x47ee5e[_0x4d1ae0('0xb42')][_0x4d1ae0('0x1e2a')]:'',_0x3ed139[_0x4d1ae0('0x1d43')]=typeof _0x47ee5e[_0x4d1ae0('0x1d43')]!=='undefined'?'<'+_0x47ee5e[_0x4d1ae0('0x1d43')]+'>':'',_0x3ed139;}),_0xf797dc[_0x41b041('0x23a7')]=angular['copy'](_0xf797dc[_0x41b041('0x1378')]),_0xf797dc[_0x41b041('0x169f')][_0x41b041('0x1378')]=_0xf797dc[_0x41b041('0x1378')],_0xf797dc[_0x41b041('0x169f')][_0x41b041('0x1996')]=_0x2e3ca0()[_0x41b041('0x461')](_0xf797dc[_0x41b041('0x1c47')],_0xf797dc['dualMultiselectOptions'][_0x41b041('0x1378')],'id'),_0x546345();})[_0x2e33dd('0x130a')](function(_0x5cc570){_0x1fc9d6(_0x5cc570);});});}function _0x1d63ee(){return _0x832b19(function(_0x2d6087,_0x1c9ab1){const _0x5375c7=a0_0x4e0a;return _0x57203f['userProfileResource']['get']({'sectionId':_0xf797dc[_0x5375c7('0x1aa')]['id'],'nolimit':!![]})[_0x5375c7('0xe53')][_0x5375c7('0x683')](function(_0x4821fe){_0x2d6087(_0x4821fe);})['catch'](function(_0x1376f8){_0x1c9ab1(_0x1376f8);});});}function _0x50158d(){return _0x832b19(function(_0x56b662,_0x3ce527){const _0x177ecd=a0_0x4e0a;return _0x57203f['faxQueue'][_0x177ecd('0x8e7')]({'id':_0xf797dc['faxQueue']['id'],'fields':_0x177ecd('0x72b'),'nolimit':!![],'role':'agent'})[_0x177ecd('0xe53')][_0x177ecd('0x683')](function(_0x3b3ae3){_0x56b662(_0x3b3ae3);})['catch'](function(_0x4e9512){_0x3ce527(_0x4e9512);});});}function _0x44078d(){return _0x832b19(function(_0x23c9b0,_0x1edfec){const _0x200de3=a0_0x4e0a;return _0x57203f[_0x200de3('0xc96')]['get']({'fields':'id,name,internal,fullname','nolimit':!![],'role':_0x200de3('0x2327')})[_0x200de3('0xe53')][_0x200de3('0x683')](function(_0xccd463){_0x23c9b0(_0xccd463);})[_0x200de3('0x130a')](function(_0x210bbf){_0x1edfec(_0x210bbf);});});}function _0x288d61(_0x4fbdac){return _0x832b19(function(_0x1f39bc,_0x128b4d){const _0x299fad=a0_0x4e0a;_0x2e3ca0()[_0x299fad('0x173f')](_0x4fbdac)?_0x1f39bc():_0x57203f[_0x299fad('0x209c')]['addAgents']({'id':_0xf797dc[_0x299fad('0x209c')]['id'],'ids':_0x2e3ca0()[_0x299fad('0x386')](_0x4fbdac,'id')})['$promise'][_0x299fad('0x683')](function(){_0x1f39bc();})['catch'](function(_0x280f9e){_0x128b4d(_0x280f9e);});});}function _0x1b906d(_0x494494){return _0x832b19(function(_0x33b3d7,_0x5e0da9){const _0x10666a=a0_0x4e0a;_0x2e3ca0()[_0x10666a('0x173f')](_0x494494)?_0x33b3d7():_0x57203f[_0x10666a('0x209c')][_0x10666a('0xf9')]({'id':_0xf797dc[_0x10666a('0x209c')]['id'],'ids':_0x2e3ca0()[_0x10666a('0x386')](_0x494494,'id')})[_0x10666a('0xe53')][_0x10666a('0x683')](function(){_0x33b3d7();})[_0x10666a('0x130a')](function(_0x4de642){_0x5e0da9(_0x4de642);});});}function _0x5c8bfb(){const _0x1390f2=_0x545c36,_0x53eb42=_0x2e3ca0()['differenceBy'](_0xf797dc[_0x1390f2('0x23a7')],_0xf797dc[_0x1390f2('0x1378')],'id'),_0x4bf326=_0x2e3ca0()['differenceBy'](_0xf797dc['selectedItems'],_0xf797dc[_0x1390f2('0x23a7')],'id');return _0x1b906d(_0x53eb42)[_0x1390f2('0x683')](function(){return _0x288d61(_0x4bf326);})[_0x1390f2('0x683')](function(){const _0x3f715f=_0x1390f2;_0xf797dc[_0x3f715f('0x2106')]=![],_0xf797dc[_0x3f715f('0x125e')]=angular[_0x3f715f('0x1a86')](_0xf797dc[_0x3f715f('0x1c47')]),_0xf797dc['startingSelectedItems']=angular[_0x3f715f('0x1a86')](_0xf797dc[_0x3f715f('0x1378')]),_0x210015[_0x3f715f('0x53')]({'title':_0x3f715f('0xd28'),'msg':_0x3f715f('0x89d')});})[_0x1390f2('0x130a')](function(_0x2a6aa1){const _0x2746d5=_0x1390f2;_0x210015[_0x2746d5('0x52a')]({'title':_0x2a6aa1[_0x2746d5('0x13ee')]?_0x2746d5('0x2168')+_0x2a6aa1[_0x2746d5('0x13ee')]+_0x2746d5('0xbf6')+_0x2a6aa1[_0x2746d5('0x24a9')]:'SYSTEM:LISTS_ASSOCIATION','msg':_0x2a6aa1['status']?JSON[_0x2746d5('0x258a')](_0x2a6aa1[_0x2746d5('0x5a5')]):_0x2a6aa1['toString']()});});}function _0x223d70(){const _0x52c774=_0x545c36;_0x112b77[_0x52c774('0x1715')]();}}const _0xfbd9e8=_0x2524ad;_0x587f46[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x209c'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x587f46(_0x2b5821,_0x26d075,_0x3b9f29,_0x304339,_0x585dd2,_0x4a4daf,_0x3b2412,_0x56c3e1){const _0x471699=_0x189033,_0x93c9e1=this;_0x93c9e1[_0x471699('0x11ed')]=_0x3b2412['getCurrentUser'](),_0x93c9e1[_0x471699('0x209c')]=_0x585dd2,_0x93c9e1[_0x471699('0x1134')]=_0x56c3e1,_0x93c9e1[_0x471699('0x1996')]=[],_0x93c9e1[_0x471699('0x1c47')]=[],_0x93c9e1[_0x471699('0x1378')]=[],_0x93c9e1[_0x471699('0x125e')]=[],_0x93c9e1[_0x471699('0x23a7')]=[],_0x93c9e1['pendingChanges']=![],_0x93c9e1[_0x471699('0x169f')]={'readOnly':!_0x93c9e1[_0x471699('0x1134')][_0x471699('0x1978')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x471699('0x60a'),'line1':_0x471699('0x60a'),'line2':'','line3':'','labelAll':_0x4a4daf['instant'](_0x471699('0x8d5')),'labelSelected':_0x4a4daf[_0x471699('0x2728')]('FAX.SELECTED_TEAMS'),'transferCallback':function(){const _0x6a2a94=_0x471699,_0x50ede9=_0x2e3ca0()[_0x6a2a94('0x25cb')](_0x93c9e1[_0x6a2a94('0x23a7')],_0x93c9e1[_0x6a2a94('0x1378')],'id');_0x93c9e1[_0x6a2a94('0x2106')]=_0x2e3ca0()[_0x6a2a94('0x173f')](_0x50ede9)?![]:!![];}},_0x93c9e1[_0x471699('0x1dd2')]=_0x245051,_0x93c9e1[_0x471699('0x1a89')]=_0x581dff,_0x93c9e1[_0x471699('0xf82')]=_0x59f9c5;function _0x245051(){const _0x1c8b0f=_0x471699;return _0x3b2412['hasRole'](_0x1c8b0f('0x20c2'))?_0x4adbad()[_0x1c8b0f('0x130a')](function(_0x30137f){const _0x5808eb=_0x1c8b0f;_0x3b9f29[_0x5808eb('0x52a')]({'title':_0x30137f[_0x5808eb('0x13ee')]?'API:'+_0x30137f[_0x5808eb('0x13ee')]+'\x20-\x20'+_0x30137f[_0x5808eb('0x24a9')]:'SYSTEM:GET_TEAMS','msg':_0x30137f['status']?JSON[_0x5808eb('0x258a')](_0x30137f[_0x5808eb('0x5a5')]):_0x30137f['toString']()});}):_0x287bd7()['then'](function(_0x4c55ff){const _0x517c57=_0x1c8b0f;return _0x93c9e1[_0x517c57('0x1aa')]=_0x4c55ff,_0x4adbad();})[_0x1c8b0f('0x130a')](function(_0x33e928){const _0x5a2a2e=_0x1c8b0f;_0x3b9f29[_0x5a2a2e('0x52a')]({'title':_0x33e928[_0x5a2a2e('0x13ee')]?_0x5a2a2e('0x2168')+_0x33e928[_0x5a2a2e('0x13ee')]+'\x20-\x20'+_0x33e928[_0x5a2a2e('0x24a9')]:'SYSTEM:GET_TEAMS','msg':_0x33e928['status']?JSON[_0x5a2a2e('0x258a')](_0x33e928[_0x5a2a2e('0x5a5')]):_0x33e928[_0x5a2a2e('0x1ff0')]()});});}function _0x287bd7(){return _0x26d075(function(_0xde54da,_0x4ae86b){const _0x420fe0=a0_0x4e0a;_0x304339[_0x420fe0('0x22df')]['get']({'userProfileId':_0x93c9e1[_0x420fe0('0x11ed')]['userProfileId'],'name':_0x420fe0('0x15bc')})[_0x420fe0('0xe53')][_0x420fe0('0x683')](function(_0x5aafae){const _0x3420f7=_0x420fe0,_0x482b3=_0x5aafae&&_0x5aafae[_0x3420f7('0xf5d')]?_0x5aafae['rows'][0x0]:null;_0xde54da(_0x482b3);})[_0x420fe0('0x130a')](function(_0x587a35){_0x4ae86b(_0x587a35);});});}function _0x4adbad(){return _0x26d075(function(_0x309a75,_0xc3b483){const _0x504582=a0_0x4e0a;return _0x12d02a()[_0x504582('0x683')](function(_0x49ef91){const _0x16a31a=_0x504582;return _0x93c9e1[_0x16a31a('0x1996')]=_0x49ef91[_0x16a31a('0xf5d')]?_0x49ef91['rows']:[],_0x3b2412['hasRole'](_0x16a31a('0x20c2'))?_0x49ef91:_0x93c9e1[_0x16a31a('0x1aa')]?_0x93c9e1[_0x16a31a('0x1aa')][_0x16a31a('0x170')]?_0x49ef91:_0x2abe1b():null;})[_0x504582('0x683')](function(_0x3ad4b2){const _0x49df43=_0x504582,_0x17f141=_0x3ad4b2&&_0x3ad4b2[_0x49df43('0xf5d')]?_0x3ad4b2[_0x49df43('0xf5d')]:[];return _0x93c9e1[_0x49df43('0x1c47')]=_0x2e3ca0()[_0x49df43('0x386')](_0x17f141,function(_0x584a09){const _0x17ddaa=_0x49df43;return _0x2e3ca0()[_0x17ddaa('0x1c07')](_0x93c9e1['items'],{'id':_0x3b2412['hasRole'](_0x17ddaa('0x20c2'))||_0x93c9e1[_0x17ddaa('0x1aa')]['autoAssociation']?_0x584a09['id']:_0x584a09[_0x17ddaa('0x832')]});}),_0x93c9e1[_0x49df43('0x1996')][_0x49df43('0x1299')](function(_0x19850f){const _0x295899=_0x49df43,_0x2ab63c=_0x2e3ca0()[_0x295899('0x1c07')](_0x93c9e1[_0x295899('0x1c47')],{'id':_0x19850f['id']});_0x3b2412[_0x295899('0xca1')]('admin')?_0x19850f[_0x295899('0x24f4')]=!![]:_0x19850f[_0x295899('0x24f4')]=typeof _0x2ab63c!==_0x295899('0x1867')?!![]:![];}),_0x59bc18();})[_0x504582('0x683')](function(_0xf3e5af){const _0x3008c9=_0x504582,_0x122152=_0xf3e5af&&_0xf3e5af[_0x3008c9('0xf5d')]?_0xf3e5af[_0x3008c9('0xf5d')]:[];_0x93c9e1['selectedItems']=_0x2e3ca0()[_0x3008c9('0x386')](_0x122152,function(_0x159fc2){const _0x2fd0aa=_0x3008c9;return _0x2e3ca0()['find'](_0x93c9e1[_0x2fd0aa('0x1996')],{'id':_0x159fc2['id']});}),_0x93c9e1[_0x3008c9('0x23a7')]=angular[_0x3008c9('0x1a86')](_0x93c9e1[_0x3008c9('0x1378')]),_0x93c9e1['dualMultiselectOptions'][_0x3008c9('0x1378')]=_0x93c9e1['selectedItems'],_0x93c9e1['dualMultiselectOptions'][_0x3008c9('0x1996')]=_0x2e3ca0()[_0x3008c9('0x461')](_0x93c9e1['allowedItems'],_0x93c9e1['dualMultiselectOptions'][_0x3008c9('0x1378')],'id'),_0x309a75();})[_0x504582('0x130a')](function(_0x18a105){_0xc3b483(_0x18a105);});});}function _0x2abe1b(){return _0x26d075(function(_0x4a0ebc,_0x4bc090){const _0x9765b1=a0_0x4e0a;return _0x304339[_0x9765b1('0xcf7')][_0x9765b1('0x1e6e')]({'sectionId':_0x93c9e1[_0x9765b1('0x1aa')]['id'],'nolimit':!![]})[_0x9765b1('0xe53')]['then'](function(_0x204c2f){_0x4a0ebc(_0x204c2f);})[_0x9765b1('0x130a')](function(_0x3faec4){_0x4bc090(_0x3faec4);});});}function _0x59bc18(){return _0x26d075(function(_0x1d9742,_0xf37df){const _0x4429da=a0_0x4e0a;return _0x304339[_0x4429da('0x209c')][_0x4429da('0xf90')]({'id':_0x93c9e1[_0x4429da('0x209c')]['id'],'fields':_0x4429da('0xa10'),'nolimit':!![]})[_0x4429da('0xe53')][_0x4429da('0x683')](function(_0x31e3a2){_0x1d9742(_0x31e3a2);})[_0x4429da('0x130a')](function(_0x508df8){_0xf37df(_0x508df8);});});}function _0x12d02a(){return _0x26d075(function(_0xdf9ffa,_0x57b1da){const _0x315a09=a0_0x4e0a;return _0x304339[_0x315a09('0xd88')][_0x315a09('0x1e6e')]({'fields':'id,name','nolimit':!![]})[_0x315a09('0xe53')][_0x315a09('0x683')](function(_0x2d444c){_0xdf9ffa(_0x2d444c);})['catch'](function(_0x3a72bc){_0x57b1da(_0x3a72bc);});});}function _0xddebe0(_0x50a538){return _0x26d075(function(_0x5acdce,_0x17a8b0){const _0x2aa142=a0_0x4e0a;_0x2e3ca0()[_0x2aa142('0x173f')](_0x50a538)?_0x5acdce():_0x304339[_0x2aa142('0x209c')][_0x2aa142('0x1558')]({'id':_0x93c9e1[_0x2aa142('0x209c')]['id'],'ids':_0x2e3ca0()[_0x2aa142('0x386')](_0x50a538,'id')})[_0x2aa142('0xe53')][_0x2aa142('0x683')](function(){_0x5acdce();})['catch'](function(_0x539d9d){_0x17a8b0(_0x539d9d);});});}function _0x4caaa3(_0xc1f381){return _0x26d075(function(_0x11e4dd,_0x1ece4b){const _0x2d5eaa=a0_0x4e0a;_0x2e3ca0()[_0x2d5eaa('0x173f')](_0xc1f381)?_0x11e4dd():_0x304339[_0x2d5eaa('0x209c')][_0x2d5eaa('0x2521')]({'id':_0x93c9e1[_0x2d5eaa('0x209c')]['id'],'ids':_0x2e3ca0()[_0x2d5eaa('0x386')](_0xc1f381,'id')})['$promise'][_0x2d5eaa('0x683')](function(){_0x11e4dd();})[_0x2d5eaa('0x130a')](function(_0x32f9c8){_0x1ece4b(_0x32f9c8);});});}function _0x581dff(){const _0x309967=_0x471699,_0x452f87=_0x2e3ca0()['differenceBy'](_0x93c9e1[_0x309967('0x23a7')],_0x93c9e1[_0x309967('0x1378')],'id'),_0x26f9a1=_0x2e3ca0()[_0x309967('0x461')](_0x93c9e1[_0x309967('0x1378')],_0x93c9e1[_0x309967('0x23a7')],'id');return _0x4caaa3(_0x452f87)[_0x309967('0x683')](function(){return _0xddebe0(_0x26f9a1);})[_0x309967('0x683')](function(){const _0x228f69=_0x309967;_0x93c9e1['pendingChanges']=![],_0x93c9e1['startingAllowedItems']=angular[_0x228f69('0x1a86')](_0x93c9e1[_0x228f69('0x1c47')]),_0x93c9e1[_0x228f69('0x23a7')]=angular['copy'](_0x93c9e1['selectedItems']),_0x3b9f29[_0x228f69('0x53')]({'title':_0x228f69('0xd28'),'msg':_0x228f69('0x476')});})['catch'](function(_0x5af846){const _0x1eda7e=_0x309967;_0x3b9f29['error']({'title':_0x5af846[_0x1eda7e('0x13ee')]?'API:'+_0x5af846['status']+'\x20-\x20'+_0x5af846[_0x1eda7e('0x24a9')]:_0x1eda7e('0x1b71'),'msg':_0x5af846[_0x1eda7e('0x13ee')]?JSON['stringify'](_0x5af846['data']):_0x5af846[_0x1eda7e('0x1ff0')]()});});}function _0x59f9c5(){const _0xf4428c=_0x471699;_0x2b5821[_0xf4428c('0x1715')]();}}const _0x302961=_0x587f46,_0x33856f=_0x180212['p']+_0x189033('0x27fa');_0x22bf13['$inject']=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$translate',_0x189033('0xace'),'setting',_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x209c'),'userProfileSection'];function _0x22bf13(_0x1db520,_0x413601,_0x415199,_0x1b2c20,_0x953819,_0x19782c,_0x584730,_0x2598eb,_0x571a31,_0x57dd6e,_0x791277,_0x478d28){const _0x1d3c5e=_0x189033,_0x1137fa=this;_0x1137fa[_0x1d3c5e('0x11ed')]=_0x57dd6e['getCurrentUser'](),_0x1137fa[_0x1d3c5e('0xace')]=_0x19782c,_0x1137fa[_0x1d3c5e('0x260a')]=_0x584730,_0x1137fa[_0x1d3c5e('0x19b2')]=_0x1137fa['setting'][_0x1d3c5e('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1137fa[_0x1d3c5e('0x1224')]=_0x413601['protocol']()+'://'+_0x413601[_0x1d3c5e('0x19ac')](),_0x1137fa[_0x1d3c5e('0x209c')]=_0x791277||_0x1db520[_0x1d3c5e('0x7f2')][_0x1d3c5e('0x209c')]||{},_0x1137fa[_0x1d3c5e('0x22df')]=_0x478d28&&_0x478d28[_0x1d3c5e('0x50d')]==0x1?_0x478d28[_0x1d3c5e('0xf5d')][0x0]:null,_0x1137fa[_0x1d3c5e('0x1134')]=_0x57dd6e[_0x1d3c5e('0x142a')](_0x1137fa[_0x1d3c5e('0x22df')]?_0x1137fa[_0x1d3c5e('0x22df')]['crudPermissions']:null),_0x1137fa[_0x1d3c5e('0x258d')]={},_0x1137fa['selectedTab']=_0x1db520[_0x1d3c5e('0x7f2')]['tab']||0x0,_0x1137fa[_0x1d3c5e('0xe0e')]=_0x443d90,_0x1137fa[_0x1d3c5e('0x2814')]=_0x26ba07,_0x1137fa[_0x1d3c5e('0x2430')]=_0x571a31['info'],_0x1137fa[_0x1d3c5e('0x1fc1')]=_0x5f43bc,_0x1137fa[_0x1d3c5e('0x2048')]=_0x36fcba;function _0x443d90(_0x20d31d,_0x2a32b1){const _0x2bbe42=_0x1d3c5e;_0x415199[_0x2bbe42('0x1d4')]({'controller':_0x2bbe42('0x1571'),'controllerAs':'vm','templateUrl':_0x33856f,'parent':angular[_0x2bbe42('0x1fcc')](_0x1b2c20[_0x2bbe42('0x18e5')]),'targetEvent':_0x2a32b1,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x20d31d,'faxQueues':_0x1137fa[_0x2bbe42('0xec3')]?_0x1137fa['faxQueues']['rows']:[],'crudPermissions':_0x1137fa[_0x2bbe42('0x1134')]}});}function _0x26ba07(_0x586f42,_0x5c2298){const _0xad009e=_0x1d3c5e;_0x415199['show']({'controller':'FaxQueueagentaddController','controllerAs':'vm','templateUrl':_0x12aa32,'parent':angular['element'](_0x1b2c20[_0xad009e('0x18e5')]),'targetEvent':_0x5c2298,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x586f42,'faxQueues':_0x1137fa[_0xad009e('0xec3')]?_0x1137fa[_0xad009e('0xec3')][_0xad009e('0xf5d')]:[],'crudPermissions':_0x1137fa['crudPermissions'],'realtime':![]}});}function _0x5f43bc(){const _0x3dbfb6=_0x1d3c5e;_0x1db520['go'](_0x3dbfb6('0xb2e'),{},{'reload':_0x3dbfb6('0xb2e')});}function _0x36fcba(){const _0x3d8e58=_0x1d3c5e;_0x2598eb[_0x3d8e58('0x209c')][_0x3d8e58('0x2480')]({'id':_0x1137fa[_0x3d8e58('0x209c')]['id']},_0x1137fa[_0x3d8e58('0x209c')])['$promise'][_0x3d8e58('0x683')](function(){const _0xa15ecc=_0x3d8e58;_0x571a31[_0xa15ecc('0x53')]({'title':_0xa15ecc('0x23'),'msg':_0x1137fa[_0xa15ecc('0x209c')][_0xa15ecc('0x60a')]?_0x1137fa['faxQueue'][_0xa15ecc('0x60a')]+_0xa15ecc('0x96c'):''});})[_0x3d8e58('0x130a')](function(_0x10f5a0){const _0x27bb2e=_0x3d8e58;_0x571a31[_0x27bb2e('0x52a')]({'title':_0x10f5a0[_0x27bb2e('0x13ee')]?'API:'+_0x10f5a0['status']+_0x27bb2e('0xbf6')+_0x10f5a0[_0x27bb2e('0x24a9')]:'SYSTEM:GETfaxQueue','msg':_0x10f5a0[_0x27bb2e('0x5a5')]?JSON['stringify'](_0x10f5a0[_0x27bb2e('0x5a5')]):_0x10f5a0[_0x27bb2e('0x1ff0')]()});});}}const _0x29741e=_0x22bf13;_0xd502a8[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$window',_0x189033('0x938'),_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0xec3'),_0x189033('0x2a'),'userProfileSection','api',_0x189033('0x1cc2'),'toasty',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0xd502a8(_0x54ed97,_0xd172fe,_0x126597,_0x22ece1,_0x262596,_0x27e23a,_0x4468cc,_0x30e85b,_0x41d8d4,_0x3f775e,_0x14265d,_0x5f3ba5,_0x45fcf6,_0x5de20f,_0x442884,_0x26abb2,_0x3f30ef){const _0x44377c=_0x189033,_0x5576f8=this;_0x5576f8[_0x44377c('0xace')]=_0x26abb2,_0x5576f8[_0x44377c('0x260a')]=_0x3f30ef,_0x5576f8[_0x44377c('0x11ed')]=_0x442884['getCurrentUser'](),_0x5576f8['faxQueues']=_0x41d8d4||{'count':0x0,'rows':[]},_0x5576f8[_0x44377c('0x2a')]=_0x3f775e,_0x5576f8[_0x44377c('0x22df')]=_0x14265d&&_0x14265d[_0x44377c('0x50d')]==0x1?_0x14265d[_0x44377c('0xf5d')][0x0]:null,_0x5576f8[_0x44377c('0x1134')]=_0x442884[_0x44377c('0x142a')](_0x5576f8[_0x44377c('0x22df')]?_0x5576f8['userProfileSection'][_0x44377c('0x1134')]:null),_0x5576f8[_0x44377c('0x5c4')]=_0x44377c('0xec3'),_0x5576f8[_0x44377c('0x247')]='',_0x5576f8[_0x44377c('0x1ce2')]=null,_0x5576f8[_0x44377c('0x85e')]=[],_0x5576f8[_0x44377c('0x23a2')]={'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','sort':_0x44377c('0xc36'),'channel':_0x44377c('0x23e9'),'limit':0xa,'page':0x1},_0x5576f8[_0x44377c('0x21de')]=_0x2e3ca0()['keyBy']([{'option':_0x44377c('0x953'),'value':_0x44377c('0x185b')},{'option':_0x44377c('0x15cd'),'value':_0x44377c('0x4ab')}],function(_0x2061dd){const _0x39b9d9=_0x44377c;return _0x2e3ca0()[_0x39b9d9('0x1725')](_0x2061dd['value'],new RegExp('\x27','g'),'');}),_0x5576f8[_0x44377c('0xc63')]=_0x296438,_0x5576f8['teamadddialog']=_0x46dbc9,_0x5576f8[_0x44377c('0x2814')]=_0xaacafe,_0x5576f8['deleteconfirm']=_0x49bdd6,_0x5576f8[_0x44377c('0x213c')]=_0x260714,_0x5576f8['success']=_0x27ab32,_0x5576f8[_0x44377c('0x693')]=_0x4c0919,_0x5576f8[_0x44377c('0x1fd4')]=_0x4be302,_0x5576f8[_0x44377c('0x2692')]=_0x523c14,_0x5576f8['exportSelectedFaxQueues']=_0x48059f,_0x5576f8[_0x44377c('0x18f4')]=_0x1bd450,_0x5576f8[_0x44377c('0xef4')]=_0x490d04,_0x5576f8[_0x44377c('0x1c88')]=_0x282edf;function _0x296438(_0x19df8b){const _0x39db9a=_0x44377c;_0x126597['go'](_0x39db9a('0x1997'),{'id':_0x19df8b['id'],'faxQueue':_0x19df8b,'crudPermissions':_0x5576f8['crudPermissions']});}function _0x46dbc9(_0x54f608,_0x2ffd7b){const _0x1ac494=_0x44377c;_0x262596[_0x1ac494('0x1d4')]({'controller':_0x1ac494('0x1571'),'controllerAs':'vm','templateUrl':_0x33856f,'parent':angular[_0x1ac494('0x1fcc')](_0x27e23a[_0x1ac494('0x18e5')]),'targetEvent':_0x2ffd7b,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x54f608,'faxQueues':_0x5576f8[_0x1ac494('0xec3')]?_0x5576f8[_0x1ac494('0xec3')][_0x1ac494('0xf5d')]:[],'crudPermissions':_0x5576f8['crudPermissions']}});}function _0xaacafe(_0x13bd6d,_0x39bb2f){const _0x4227f4=_0x44377c;_0x262596[_0x4227f4('0x1d4')]({'controller':_0x4227f4('0xbd8'),'controllerAs':'vm','templateUrl':_0x12aa32,'parent':angular[_0x4227f4('0x1fcc')](_0x27e23a['body']),'targetEvent':_0x39bb2f,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x13bd6d,'faxQueues':_0x5576f8[_0x4227f4('0xec3')]?_0x5576f8[_0x4227f4('0xec3')][_0x4227f4('0xf5d')]:[],'crudPermissions':_0x5576f8[_0x4227f4('0x1134')],'realtime':![]}});}function _0x49bdd6(_0x1155e0,_0x59d509){const _0x5da903=_0x44377c,_0x44b94a=_0x262596[_0x5da903('0x1c6f')]()[_0x5da903('0xf28')](_0x5da903('0x1b01')+_0x2e3ca0()[_0x5da903('0x1e03')](_0x5da903('0x209c'))+'?')['htmlContent'](_0x5da903('0xed5')+(_0x1155e0['name']||_0x5da903('0x209c'))+'
'+'\x20will\x20be\x20deleted.')[_0x5da903('0x1040')](_0x5da903('0xc79'))['targetEvent'](_0x59d509)['ok']('OK')[_0x5da903('0x19fb')]('CANCEL');_0x262596[_0x5da903('0x1d4')](_0x44b94a)['then'](function(){_0x523c14(_0x1155e0);},function(){const _0x195a7f=_0x5da903;console[_0x195a7f('0x1b2b')](_0x195a7f('0x16b8'));});}function _0x260714(){const _0x441627=_0x44377c;if(_0x442884[_0x441627('0xca1')](_0x441627('0x20c2')))_0x126597['go']('app.fax.realtime.queues',{});else return _0x5f3ba5['userProfileSection'][_0x441627('0x1e6e')]({'userProfileId':_0x442884[_0x441627('0x20b2')]()['userProfileId'],'sectionId':0x38e})[_0x441627('0xe53')][_0x441627('0x683')](function(_0x5ce16d){const _0x4d6100=_0x441627,_0x10a2e0=_0x5ce16d&&_0x5ce16d[_0x4d6100('0xf5d')]?_0x5ce16d['rows'][0x0]:null;_0x10a2e0&&_0x10a2e0['enabled']?_0x126597['go'](_0x4d6100('0x24fd'),{}):_0x5de20f[_0x4d6100('0x2289')]({'title':_0x30e85b[_0x4d6100('0x2728')](_0x4d6100('0x213e')),'msg':_0x30e85b['instant'](_0x4d6100('0xdba'))});})[_0x441627('0x130a')](function(_0x59b82b){const _0x1e56ff=_0x441627;_0x5de20f[_0x1e56ff('0x52a')]({'title':_0x59b82b['status']?_0x1e56ff('0x2168')+_0x59b82b['status']+_0x1e56ff('0xbf6')+_0x59b82b[_0x1e56ff('0x24a9')]:_0x1e56ff('0xf2a'),'msg':_0x59b82b[_0x1e56ff('0x13ee')]?JSON[_0x1e56ff('0x258a')](_0x59b82b[_0x1e56ff('0x5a5')]):_0x59b82b[_0x1e56ff('0x1ff0')]()});});}let _0x558a8e=!![],_0x507bc0=0x1;_0x54ed97['$watch']('vm.query.filter',function(_0x228cc8,_0x37c010){const _0x1083a1=_0x44377c;_0x558a8e?_0x4468cc(function(){_0x558a8e=![];}):(!_0x37c010&&(_0x507bc0=_0x5576f8[_0x1083a1('0x23a2')][_0x1083a1('0xdf8')]),_0x228cc8!==_0x37c010&&(_0x5576f8['query'][_0x1083a1('0xdf8')]=0x1),!_0x228cc8&&(_0x5576f8[_0x1083a1('0x23a2')][_0x1083a1('0xdf8')]=_0x507bc0),_0x5576f8[_0x1083a1('0x693')]());});function _0x27ab32(_0x47de53){const _0x590429=_0x44377c;_0x5576f8[_0x590429('0xec3')]=_0x47de53||{'count':0x0,'rows':[]};}function _0x4c0919(){const _0x3db931=_0x44377c;_0x5576f8[_0x3db931('0x23a2')]['offset']=(_0x5576f8['query']['page']-0x1)*_0x5576f8[_0x3db931('0x23a2')][_0x3db931('0x6f0')],_0x442884['hasRole'](_0x3db931('0x20c2'))?_0x5576f8[_0x3db931('0x1883')]=_0x5f3ba5[_0x3db931('0x209c')][_0x3db931('0x1e6e')](_0x5576f8[_0x3db931('0x23a2')],_0x27ab32)[_0x3db931('0xe53')]:(_0x5576f8[_0x3db931('0x23a2')]['id']=_0x5576f8['userProfile']['id'],_0x5576f8['query']['section']=_0x3db931('0x22cb'),_0x5576f8[_0x3db931('0x1883')]=_0x5f3ba5[_0x3db931('0x2a')][_0x3db931('0x241d')](_0x5576f8[_0x3db931('0x23a2')],_0x27ab32)[_0x3db931('0xe53')]);}function _0x4be302(_0x5a107a,_0x34d64b){const _0x14e52d=_0x44377c;_0x262596[_0x14e52d('0x1d4')]({'controller':_0x14e52d('0xb4f'),'controllerAs':'vm','templateUrl':_0x387711,'parent':angular[_0x14e52d('0x1fcc')](_0x27e23a[_0x14e52d('0x18e5')]),'targetEvent':_0x5a107a,'clickOutsideToClose':!![],'locals':{'faxQueue':_0x34d64b,'faxQueues':_0x5576f8['faxQueues']['rows'],'license':_0x5576f8['license'],'setting':_0x5576f8[_0x14e52d('0x260a')],'crudPermissions':_0x5576f8[_0x14e52d('0x1134')]}});}function _0x523c14(_0x454785){const _0x2de5e9=_0x44377c;_0x5f3ba5[_0x2de5e9('0x209c')][_0x2de5e9('0xd7e')]({'id':_0x454785['id']})[_0x2de5e9('0xe53')][_0x2de5e9('0x683')](function(){const _0x100552=_0x2de5e9;_0x2e3ca0()[_0x100552('0x3ec')](_0x5576f8[_0x100552('0xec3')]['rows'],{'id':_0x454785['id']}),_0x5576f8[_0x100552('0xec3')][_0x100552('0x50d')]-=0x1,!_0x5576f8[_0x100552('0xec3')][_0x100552('0xf5d')][_0x100552('0x1564')]&&_0x5576f8[_0x100552('0x693')](),_0x5de20f[_0x100552('0x53')]({'title':_0x2e3ca0()['startCase']('FaxQueue')+'\x20deleted!','msg':_0x454785[_0x100552('0x60a')]?_0x454785[_0x100552('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0x2de5e9('0x130a')](function(_0x4253fe){const _0x1ee8e1=_0x2de5e9;if(_0x4253fe['data']&&_0x4253fe['data']['errors']&&_0x4253fe[_0x1ee8e1('0x5a5')]['errors'][_0x1ee8e1('0x1564')]){_0x5576f8[_0x1ee8e1('0x17f')]=_0x4253fe['data'][_0x1ee8e1('0x17f')]||[{'message':_0x4253fe[_0x1ee8e1('0x1ff0')](),'type':_0x1ee8e1('0x2358')}];for(let _0x154fa8=0x0;_0x154fa8<_0x4253fe[_0x1ee8e1('0x5a5')]['errors'][_0x1ee8e1('0x1564')];_0x154fa8++){_0x5de20f['error']({'title':_0x4253fe['data'][_0x1ee8e1('0x17f')][_0x154fa8][_0x1ee8e1('0xcf0')],'msg':_0x4253fe[_0x1ee8e1('0x5a5')][_0x1ee8e1('0x17f')][_0x154fa8][_0x1ee8e1('0x8c2')]});}}else _0x5de20f[_0x1ee8e1('0x52a')]({'title':_0x4253fe[_0x1ee8e1('0x13ee')]?_0x1ee8e1('0x2168')+_0x4253fe[_0x1ee8e1('0x13ee')]+_0x1ee8e1('0xbf6')+_0x4253fe[_0x1ee8e1('0x24a9')]:'SYSTEM:DELETEfaxQueue','msg':_0x4253fe[_0x1ee8e1('0x5a5')]?JSON['stringify'](_0x4253fe[_0x1ee8e1('0x5a5')][_0x1ee8e1('0x8c2')]):_0x4253fe[_0x1ee8e1('0x8c2')]||_0x4253fe['toString']()});});}function _0x48059f(){const _0x3ec09b=_0x44377c,_0x5ae03c=angular[_0x3ec09b('0x1a86')](_0x5576f8[_0x3ec09b('0x85e')]);return _0x5576f8[_0x3ec09b('0x85e')]=[],_0x5ae03c;}function _0x1bd450(_0x9c1509){const _0x488fd8=_0x44377c,_0x1b802d=_0x262596[_0x488fd8('0x1c6f')]()[_0x488fd8('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20faxQueues?')['htmlContent'](_0x488fd8('0xed5')+_0x5576f8['selectedFaxQueues']['length']+_0x488fd8('0x93c')+_0x488fd8('0x1ee7'))[_0x488fd8('0x1040')](_0x488fd8('0x12ba'))[_0x488fd8('0xe42')](_0x9c1509)['ok']('OK')[_0x488fd8('0x19fb')](_0x488fd8('0x16b8'));_0x262596[_0x488fd8('0x1d4')](_0x1b802d)[_0x488fd8('0x683')](function(){const _0x2c34ab=_0x488fd8;_0x5576f8[_0x2c34ab('0x85e')][_0x2c34ab('0x1299')](function(_0x183b94){_0x523c14(_0x183b94);}),_0x5576f8[_0x2c34ab('0x85e')]=[];});}function _0x490d04(){_0x5576f8['selectedFaxQueues']=[];}function _0x282edf(){const _0x1944c5=_0x44377c;_0x5576f8['selectedFaxQueues']=_0x5576f8[_0x1944c5('0xec3')][_0x1944c5('0xf5d')];}}const _0x39488a=_0xd502a8;_0xd0634d[_0x189033('0x14be')]=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0xd0634d(_0xeef509,_0x2db7a7){const _0x247993=_0x189033;_0xeef509[_0x247993('0x2598')](_0x247993('0xe32'),{'abstract':!![],'url':'/fax'})[_0x247993('0x2598')](_0x247993('0xb2e'),{'url':'/faxQueues','views':{'content@app':{'templateUrl':_0x36a8b1,'controller':_0x247993('0x17e0')}},'resolve':{'faxQueues':[_0x247993('0x4b1'),_0x247993('0xba1'),function(_0x4b6dbb,_0x358903){const _0x169f8d=_0x247993;return _0x358903['hasRole'](_0x169f8d('0x20c2'))?_0x4b6dbb[_0x169f8d('0xed7')](_0x169f8d('0x10ac'),{'fields':_0x169f8d('0x1b67'),'sort':_0x169f8d('0xc36'),'channel':_0x169f8d('0x23e9'),'limit':0xa,'offset':0x0}):_0x4b6dbb[_0x169f8d('0xed7')](_0x169f8d('0x191b'),{'id':_0x358903[_0x169f8d('0x20b2')]()[_0x169f8d('0x2f')],'section':'FaxQueues','fields':'createdAt,updatedAt,id,name,strategy,timeout,description','sort':_0x169f8d('0xc36'),'channel':'fax','limit':0xa,'offset':0x0});}],'userProfile':[_0x247993('0x4b1'),_0x247993('0xba1'),function(_0x133eef,_0x2aaaed){const _0x23cd79=_0x247993;return _0x2aaaed[_0x23cd79('0xca1')](_0x23cd79('0x20c2'))?null:_0x133eef[_0x23cd79('0xed7')](_0x23cd79('0x1464'),{'fields':_0x23cd79('0x16f'),'id':_0x2aaaed[_0x23cd79('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x247993('0x4b1'),_0x247993('0xba1'),function(_0x41f49b,_0xfe13f5){const _0x4dd22b=_0x247993;return _0xfe13f5[_0x4dd22b('0xca1')]('admin')?null:_0x41f49b[_0x4dd22b('0xed7')]('userProfileSection@get',{'fields':_0x4dd22b('0x1f47'),'userProfileId':_0xfe13f5[_0x4dd22b('0x20b2')]()[_0x4dd22b('0x2f')],'sectionId':0x385});}]},'authenticate':!![],'permissionId':0x385,'bodyClass':_0x247993('0x23e9')})['state'](_0x247993('0x1997'),{'url':_0x247993('0x1560'),'params':{'faxQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x35c70a,'controller':'FaxQueueController\x20as\x20vm'}},'resolve':{'faxQueue':[_0x247993('0x4b1'),_0x247993('0x8ea'),function(_0x450404,_0x536b87){const _0x28e685=_0x247993;return _0x450404[_0x28e685('0xed7')]('faxQueue@get',{'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','id':_0x536b87['id']});}],'userProfileSection':[_0x247993('0x4b1'),_0x247993('0xba1'),function(_0x1d1033,_0x821703){const _0x3b4647=_0x247993;return _0x1d1033[_0x3b4647('0xed7')](_0x3b4647('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x821703[_0x3b4647('0x20b2')]()[_0x3b4647('0x2f')],'sectionId':0x385});}]},'authenticate':!![],'permissionId':0x385,'bodyClass':_0x247993('0x23e9')})[_0x247993('0x2598')](_0x247993('0x2875'),{'url':_0x247993('0x2888'),'views':{'content@app':{'templateUrl':_0x23829c,'controller':_0x247993('0x1a9a')}},'resolve':{'faxAccounts':[_0x247993('0x4b1'),'Auth',function(_0x172197,_0x2cc5f6){const _0xafcebd=_0x247993;return _0x2cc5f6['hasRole'](_0xafcebd('0x20c2'))?_0x172197[_0xafcebd('0xed7')](_0xafcebd('0x2076'),{'fields':'createdAt,updatedAt,id,name,key,headerinfo,TrunkId,localstationid,ListId,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,ecm,minrate,maxrate,modem,gateway,faxdetect,t38timeout,tech,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x172197[_0xafcebd('0xed7')](_0xafcebd('0x191b'),{'id':_0x2cc5f6[_0xafcebd('0x20b2')]()[_0xafcebd('0x2f')],'section':_0xafcebd('0x13af'),'fields':_0xafcebd('0x143e'),'sort':_0xafcebd('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x247993('0x4b1'),'Auth',function(_0x411386,_0x49ed53){const _0x426014=_0x247993;return _0x49ed53[_0x426014('0xca1')](_0x426014('0x20c2'))?null:_0x411386[_0x426014('0xed7')](_0x426014('0x1464'),{'fields':_0x426014('0x16f'),'id':_0x49ed53['getCurrentUser']()[_0x426014('0x2f')]});}],'userProfileSection':[_0x247993('0x4b1'),'Auth',function(_0x361304,_0x141ea5){const _0x1fb837=_0x247993;return _0x141ea5[_0x1fb837('0xca1')](_0x1fb837('0x20c2'))?null:_0x361304[_0x1fb837('0xed7')](_0x1fb837('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x141ea5['getCurrentUser']()[_0x1fb837('0x2f')],'sectionId':0x386});}]},'authenticate':!![],'permissionId':0x386,'bodyClass':_0x247993('0x23e9')})[_0x247993('0x2598')](_0x247993('0x2836'),{'url':'/:id?tab','params':{'faxAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x595434,'controller':_0x247993('0x227')}},'resolve':{'faxAccount':[_0x247993('0x4b1'),'$stateParams',function(_0x3064c8,_0x4bcd33){const _0x46840f=_0x247993;return _0x3064c8['resolve'](_0x46840f('0x2076'),{'fields':'createdAt,updatedAt,id,name,key,headerinfo,TrunkId,localstationid,ListId,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,description,ecm,minrate,maxrate,modem,gateway,faxdetect,t38timeout,tech,notificationSound,notificationShake,notificationTemplate,queueTransfer,queueTransferTimeout,agentTransfer,agentTransferTimeout','id':_0x4bcd33['id']});}],'userProfileSection':[_0x247993('0x4b1'),_0x247993('0xba1'),function(_0x3bf71b,_0xdaa13f){const _0x51f30c=_0x247993;return _0x3bf71b[_0x51f30c('0xed7')](_0x51f30c('0x360'),{'fields':_0x51f30c('0x1f47'),'userProfileId':_0xdaa13f[_0x51f30c('0x20b2')]()[_0x51f30c('0x2f')],'sectionId':0x386});}]},'authenticate':!![],'permissionId':0x386,'bodyClass':_0x247993('0x23e9')}),_0x2db7a7[_0x247993('0x7d2')]('app/main/apps/fax');}angular[_0x189033('0x1e26')](_0x189033('0xe32'),[_0x189033('0x6cf'),_0x189033('0x1ddb'),_0x189033('0x2290'),_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),_0x189033('0x2609'),'ngAnimate',_0x189033('0x76'),'mwFormBuilder',_0x189033('0x7fa'),_0x189033('0x197b'),_0x189033('0x3b5'),_0x189033('0x153a'),_0x189033('0x1447'),_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da'),'app.fax.realtime'])[_0x189033('0x272d')](_0xd0634d)[_0x189033('0x1da3')]('CreateOrEditFaxAccountDialogController',_0x181790)['controller'](_0x189033('0x1856'),_0x463248)['controller'](_0x189033('0x24cf'),_0x30e014)['controller'](_0x189033('0x1bc1'),_0x86f81)['controller'](_0x189033('0x1613'),_0x1f5626)['controller'](_0x189033('0x1721'),_0x453505)[_0x189033('0x1da3')](_0x189033('0xa41'),_0x233117)[_0x189033('0x1da3')](_0x189033('0x27e9'),_0x3a3fb2)[_0x189033('0x1da3')](_0x189033('0x26ee'),_0x141cb6)['controller']('EditFaxAccountAppqueueDialogController',_0xfe0fd7)[_0x189033('0x1da3')](_0x189033('0x18f1'),_0x37dace)[_0x189033('0x1da3')]('EditFaxAccountApptagDialogController',_0x5cc1c2)[_0x189033('0x1da3')]('FaxAccountDispositionsController',_0x24888c)[_0x189033('0x1da3')](_0x189033('0x1142'),_0xa0e6f2)[_0x189033('0x1da3')]('FaxAccountController',_0xfe0436)[_0x189033('0x1da3')](_0x189033('0xca3'),_0x1701a4)[_0x189033('0x1da3')](_0x189033('0xb4f'),_0xe3618)[_0x189033('0x1da3')](_0x189033('0xbd8'),_0xfbd9e8)[_0x189033('0x1da3')](_0x189033('0x1571'),_0x302961)[_0x189033('0x1da3')](_0x189033('0x269a'),_0x29741e)[_0x189033('0x1da3')](_0x189033('0xea4'),_0x39488a);const _0x1ab724=_0x180212['p']+'src/js/modules/main/apps/tools/views/dispositions/dispositions.html/dispositions.html';_0x43d375['$inject']=[_0x189033('0x1e48'),_0x189033('0x1d08'),'$q',_0x189033('0x1d70'),_0x189033('0x191e'),_0x189033('0x43f'),_0x189033('0x2437'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134'),_0x189033('0xace'),'setting'];function _0x43d375(_0xba2e2d,_0x289477,_0x12ec2a,_0x1429ce,_0x560399,_0x2e5500,_0x409ab6,_0x52f87d,_0x329bf0,_0x3897ef,_0xab1b1b,_0x13a2f7){const _0x3bd8d6=_0x189033,_0x48889b=this;_0x48889b[_0x3bd8d6('0x11ed')]=_0x329bf0[_0x3bd8d6('0x20b2')](),_0x48889b[_0x3bd8d6('0x43f')]=angular[_0x3bd8d6('0x1a86')](_0x2e5500),_0x48889b[_0x3bd8d6('0x191e')]=angular[_0x3bd8d6('0x1a86')](_0x560399),_0x48889b[_0x3bd8d6('0x260a')]=_0x13a2f7,_0x48889b[_0x3bd8d6('0xace')]=_0xab1b1b,_0x48889b[_0x3bd8d6('0x1134')]=_0x3897ef,_0x48889b[_0x3bd8d6('0x1581')]=![],_0x48889b['errors']=[];!_0x48889b[_0x3bd8d6('0x43f')]?(_0x48889b[_0x3bd8d6('0x43f')]={'level':_0x3bd8d6('0x2f5')},_0x48889b[_0x3bd8d6('0x1581')]=!![]):_0x58da4a();if(_0x409ab6){const _0x289789=_0x409ab6[_0x3bd8d6('0x2013')];_0x48889b[_0x3bd8d6('0x43f')][_0x289789]=_0x409ab6['id'];}_0x48889b[_0x3bd8d6('0x1aea')]=_0x155fa4,_0x48889b[_0x3bd8d6('0x16f7')]=_0x5b9240,_0x48889b['saveDisposition']=_0x2535a3,_0x48889b[_0x3bd8d6('0x207b')]=_0x805c6b,_0x48889b[_0x3bd8d6('0x180a')]=_0x34eaae,_0x48889b[_0x3bd8d6('0xf82')]=_0xb9c0ca;function _0x58da4a(){const _0x54552a=_0x3bd8d6;if(_0x48889b[_0x54552a('0x43f')][_0x54552a('0x20da')]==='first')return;_0x48889b['parentDisposition']=_0x2e3ca0()['find'](_0x48889b[_0x54552a('0x191e')],['id',_0x48889b[_0x54552a('0x43f')][_0x54552a('0x1b62')]]);if(!_0x48889b['parentDisposition']){_0x41ad57()[_0x54552a('0x683')](function(){const _0x454704=_0x54552a;for(let _0x2e7b7f=0x0;_0x2e7b7f<_0x48889b[_0x454704('0x10f2')][_0x454704('0x1564')];_0x2e7b7f++){const _0x3c90dd=_0x48889b['allDispositions'][_0x2e7b7f];if(_0x3c90dd['id']===_0x48889b['disposition']['ParentId']){_0x7541d(_0x3c90dd),_0x3c90dd['canSelect']=![],_0x48889b[_0x454704('0x191e')][_0x454704('0x1fd0')](_0x3c90dd);break;}}});return;}_0x7541d(_0x48889b[_0x54552a('0x46c')]);}function _0x41ad57(){return _0x12ec2a(function(_0x5483dd,_0x37545d){const _0x5b9c09=a0_0x4e0a;_0x52f87d['disposition'][_0x5b9c09('0x1e6e')]({'fields':_0x5b9c09('0x2714'),'sort':'id','nolimit':_0x5b9c09('0x26ac')})[_0x5b9c09('0xe53')][_0x5b9c09('0x683')](function(_0x3fef3d){const _0x5784bd=_0x5b9c09;_0x48889b['allDispositions']=_0x3fef3d[_0x5784bd('0xf5d')]||[],_0x5483dd();})[_0x5b9c09('0x130a')](function(_0x2dec38){_0x37545d(_0x2dec38);});});}function _0x7541d(_0x552932){const _0x1e4fcb=_0x3bd8d6;_0x552932['level']===_0x1e4fcb('0x2f5')?_0x48889b[_0x1e4fcb('0xb82')]=_0x552932:(_0x48889b['anySecondLevelDisposition']=!![],_0x48889b[_0x1e4fcb('0xc5d')]=_0x552932,_0x48889b[_0x1e4fcb('0xb82')]=_0x2e3ca0()['find'](_0x48889b[_0x1e4fcb('0x191e')],['id',_0x48889b['secondLevelDisposition'][_0x1e4fcb('0x1b62')]]),!_0x48889b[_0x1e4fcb('0xb82')]&&_0x41ad57()['then'](function(){const _0x4cc7f7=_0x1e4fcb;_0x48889b['firstLevelDisposition']=_0x2e3ca0()['find'](_0x48889b[_0x4cc7f7('0x10f2')],['id',_0x48889b[_0x4cc7f7('0xc5d')][_0x4cc7f7('0x1b62')]]),_0x48889b[_0x4cc7f7('0xb82')][_0x4cc7f7('0x319')]=![],_0x48889b[_0x4cc7f7('0x191e')]['push'](_0x48889b[_0x4cc7f7('0xb82')]);}));}function _0x34eaae(_0x47f35f){const _0xb6d843=_0x3bd8d6;_0x47f35f===_0xb6d843('0x2f5')?(_0x48889b[_0xb6d843('0xb82')]=undefined,_0x48889b['secondLevelDisposition']=undefined,_0x48889b[_0xb6d843('0x58')]=![]):_0x48889b[_0xb6d843('0xc5d')]=undefined;}function _0x155fa4(){const _0x5dcf93=_0x3bd8d6;_0x48889b[_0x5dcf93('0xc5d')]=undefined,_0x48889b[_0x5dcf93('0x58')]=_0x2e3ca0()[_0x5dcf93('0x7a2')](_0x48889b['dispositions'],function(_0x593a98){const _0x107217=_0x5dcf93;return _0x593a98[_0x107217('0x1b62')]===_0x48889b[_0x107217('0xb82')]['id']&&_0x593a98['id']!=_0x48889b[_0x107217('0x43f')]['id'];});}function _0x5b9240(){const _0x232db3=_0x3bd8d6;_0x48889b['errors']=[];if(_0x48889b[_0x232db3('0xc5d')])_0x48889b[_0x232db3('0x43f')][_0x232db3('0x1b62')]=_0x48889b[_0x232db3('0xc5d')]['id'],_0x48889b[_0x232db3('0x43f')][_0x232db3('0x20da')]=_0x232db3('0x1d77');else _0x48889b[_0x232db3('0xb82')]&&(_0x48889b[_0x232db3('0x43f')][_0x232db3('0x1b62')]=_0x48889b[_0x232db3('0xb82')]['id'],_0x48889b[_0x232db3('0x43f')][_0x232db3('0x20da')]=_0x232db3('0x1f7b'));_0x52f87d[_0x232db3('0x43f')][_0x232db3('0xb0a')](_0x48889b['disposition'])[_0x232db3('0xe53')][_0x232db3('0x683')](function(_0x391290){const _0x1781c9=_0x232db3;_0x48889b[_0x1781c9('0x191e')]['unshift'](_0x391290[_0x1781c9('0x24e1')]()),_0x1429ce[_0x1781c9('0x53')]({'title':_0x289477[_0x1781c9('0x2728')](_0x1781c9('0xfa8'))}),_0xb9c0ca(!![]);})[_0x232db3('0x130a')](function(_0x554351){const _0x55b8b8=_0x232db3;if(_0x554351[_0x55b8b8('0x5a5')]&&_0x554351[_0x55b8b8('0x5a5')][_0x55b8b8('0x17f')]&&_0x554351[_0x55b8b8('0x5a5')][_0x55b8b8('0x17f')][_0x55b8b8('0x1564')]){_0x48889b['errors']=_0x554351['data'][_0x55b8b8('0x17f')]||[{'message':_0x554351[_0x55b8b8('0x1ff0')](),'type':_0x55b8b8('0x2041')}];for(let _0x22ba59=0x0;_0x22ba59<_0x554351['data'][_0x55b8b8('0x17f')][_0x55b8b8('0x1564')];_0x22ba59+=0x1){_0x1429ce[_0x55b8b8('0x52a')]({'title':_0x554351[_0x55b8b8('0x5a5')][_0x55b8b8('0x17f')][_0x22ba59][_0x55b8b8('0xcf0')],'msg':_0x554351[_0x55b8b8('0x5a5')]['errors'][_0x22ba59][_0x55b8b8('0x8c2')]});}}else _0x1429ce[_0x55b8b8('0x52a')]({'title':_0x554351[_0x55b8b8('0x13ee')]?'API:'+_0x554351[_0x55b8b8('0x13ee')]+_0x55b8b8('0xbf6')+_0x554351[_0x55b8b8('0x24a9')]:_0x55b8b8('0x2041'),'msg':_0x554351[_0x55b8b8('0x5a5')]?JSON[_0x55b8b8('0x258a')](_0x554351[_0x55b8b8('0x5a5')]['message']):_0x554351[_0x55b8b8('0x1ff0')]()});});}function _0x2535a3(){const _0x23b122=_0x3bd8d6;_0x48889b[_0x23b122('0x17f')]=[];if(_0x48889b['secondLevelDisposition'])_0x48889b['disposition'][_0x23b122('0x1b62')]=_0x48889b[_0x23b122('0xc5d')]['id'],_0x48889b[_0x23b122('0x43f')]['level']='third';else _0x48889b[_0x23b122('0xb82')]&&(_0x48889b[_0x23b122('0x43f')][_0x23b122('0x1b62')]=_0x48889b[_0x23b122('0xb82')]['id'],_0x48889b['disposition'][_0x23b122('0x20da')]=_0x23b122('0x1f7b'));_0x52f87d['disposition']['update']({'id':_0x48889b['disposition']['id']},_0x48889b[_0x23b122('0x43f')])[_0x23b122('0xe53')][_0x23b122('0x683')](function(_0x58080b){const _0x476a2a=_0x23b122,_0x225a88=_0x2e3ca0()[_0x476a2a('0x1c07')](_0x48889b[_0x476a2a('0x191e')],{'id':_0x58080b['id']});_0x225a88&&_0x2e3ca0()[_0x476a2a('0xf22')](_0x225a88,_0x2e3ca0()['pick'](_0x58080b[_0x476a2a('0x24e1')](),_0x2e3ca0()[_0x476a2a('0x55e')](_0x225a88))),_0x1429ce[_0x476a2a('0x53')]({'title':_0x289477[_0x476a2a('0x2728')]('TOOLS.NOTIFICATIONS.DISPOSITION_SAVED_SUCCESS_TITLE')}),_0xb9c0ca(!![]);})['catch'](function(_0x49190a){const _0x5613cc=_0x23b122;if(_0x49190a['data']&&_0x49190a[_0x5613cc('0x5a5')][_0x5613cc('0x17f')]&&_0x49190a[_0x5613cc('0x5a5')][_0x5613cc('0x17f')][_0x5613cc('0x1564')]){_0x48889b[_0x5613cc('0x17f')]=_0x49190a[_0x5613cc('0x5a5')]['errors']||[{'message':_0x49190a[_0x5613cc('0x1ff0')](),'type':_0x5613cc('0x21b')}];for(let _0x3ed384=0x0;_0x3ed384<_0x49190a[_0x5613cc('0x5a5')]['errors'][_0x5613cc('0x1564')];_0x3ed384++){_0x1429ce[_0x5613cc('0x52a')]({'title':_0x49190a['data'][_0x5613cc('0x17f')][_0x3ed384]['type'],'msg':_0x49190a[_0x5613cc('0x5a5')][_0x5613cc('0x17f')][_0x3ed384][_0x5613cc('0x8c2')]});}}else _0x1429ce['error']({'title':_0x49190a['status']?_0x5613cc('0x2168')+_0x49190a[_0x5613cc('0x13ee')]+_0x5613cc('0xbf6')+_0x49190a[_0x5613cc('0x24a9')]:_0x5613cc('0x21b'),'msg':_0x49190a[_0x5613cc('0x5a5')]?JSON['stringify'](_0x49190a[_0x5613cc('0x5a5')][_0x5613cc('0x8c2')]):_0x49190a[_0x5613cc('0x1ff0')]()});});}function _0x805c6b(_0x4723a8){const _0x18d224=_0x3bd8d6;_0x48889b[_0x18d224('0x17f')]=[];const _0x3e1351=_0x2e3ca0()[_0x18d224('0x7a2')](_0x48889b[_0x18d224('0x191e')],[_0x18d224('0x1b62'),_0x48889b['disposition']['id']]),_0x51a96f=_0xba2e2d[_0x18d224('0x1c6f')]({'skipHide':!![]})[_0x18d224('0xf28')](_0x289477[_0x18d224('0x2728')]('TOOLS.NOTIFICATIONS.DISPOSITION_DELETE_TITLE'))[_0x18d224('0xa6a')](_0x289477[_0x18d224('0x2728')](_0x18d224('0x13bf')+(_0x3e1351?_0x18d224('0x2235'):'DISPOSITION_DELETE_MESSAGE'),{'name':_0x48889b['disposition']['name']}))[_0x18d224('0x1040')](_0x18d224('0x550'))['ok'](_0x289477[_0x18d224('0x2728')](_0x18d224('0xc53')))[_0x18d224('0x19fb')](_0x289477[_0x18d224('0x2728')](_0x18d224('0x9a1')))['targetEvent'](_0x4723a8);_0xba2e2d[_0x18d224('0x1d4')](_0x51a96f)[_0x18d224('0x683')](function(){const _0x5bf797=_0x18d224;_0x52f87d[_0x5bf797('0x43f')][_0x5bf797('0xd7e')]({'id':_0x48889b[_0x5bf797('0x43f')]['id']})['$promise'][_0x5bf797('0x683')](function(){const _0x529411=_0x5bf797;_0x1429ce['success']({'title':_0x289477['instant'](_0x529411('0x210b'))}),_0xb9c0ca(!![]);})[_0x5bf797('0x130a')](function(_0x135ffb){const _0x125c50=_0x5bf797;if(_0x135ffb[_0x125c50('0x5a5')]&&_0x135ffb['data'][_0x125c50('0x17f')]&&_0x135ffb[_0x125c50('0x5a5')]['errors'][_0x125c50('0x1564')]){_0x48889b['errors']=_0x135ffb['data'][_0x125c50('0x17f')]||[{'message':_0x135ffb[_0x125c50('0x1ff0')](),'type':_0x125c50('0xbe4')}];for(let _0xec2909=0x0;_0xec2909<_0x135ffb[_0x125c50('0x5a5')][_0x125c50('0x17f')][_0x125c50('0x1564')];_0xec2909++){_0x1429ce['error']({'title':_0x135ffb[_0x125c50('0x5a5')][_0x125c50('0x17f')][_0xec2909]['type'],'msg':_0x135ffb[_0x125c50('0x5a5')][_0x125c50('0x17f')][_0xec2909][_0x125c50('0x8c2')]});}}else _0x1429ce[_0x125c50('0x52a')]({'title':_0x135ffb[_0x125c50('0x13ee')]?_0x125c50('0x2168')+_0x135ffb[_0x125c50('0x13ee')]+_0x125c50('0xbf6')+_0x135ffb[_0x125c50('0x24a9')]:_0x125c50('0xbe4'),'msg':_0x135ffb[_0x125c50('0x5a5')]?JSON['stringify'](_0x135ffb[_0x125c50('0x5a5')]['message']):_0x135ffb[_0x125c50('0x8c2')]||_0x135ffb['toString']()});});});}function _0xb9c0ca(_0x9a20c4){_0xba2e2d['hide'](_0x9a20c4);}}const _0x1dd96d=_0x43d375;_0x5963a2['$inject']=['$scope','$window',_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0x191e'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),'toasty',_0x189033('0xba1'),'license',_0x189033('0x260a')];function _0x5963a2(_0x366106,_0x7b6c96,_0x33953,_0x8bd74f,_0x21214b,_0x55e9ac,_0x29ae31,_0x379e6c,_0x31ad3f,_0x12fd86,_0x354ff6,_0x33977f,_0x2eb880,_0x5e45de,_0x578468,_0x512a24){const _0x566648=_0x189033,_0x1e59f2=this;_0x1e59f2['license']=_0x578468,_0x1e59f2[_0x566648('0x260a')]=_0x512a24,_0x1e59f2[_0x566648('0x11ed')]=_0x5e45de[_0x566648('0x20b2')](),_0x1e59f2[_0x566648('0x191e')]=_0x31ad3f||{'count':0x0,'rows':[]},_0x1e59f2['userProfile']=_0x12fd86,_0x1e59f2[_0x566648('0x22df')]=_0x354ff6&&_0x354ff6[_0x566648('0x50d')]==0x1?_0x354ff6[_0x566648('0xf5d')][0x0]:null,_0x1e59f2['crudPermissions']=_0x5e45de[_0x566648('0x142a')](_0x1e59f2[_0x566648('0x22df')]?_0x1e59f2[_0x566648('0x22df')][_0x566648('0x1134')]:null),_0x1e59f2[_0x566648('0x17')]=[],_0x1e59f2[_0x566648('0x1d01')]={'first':'1st','second':_0x566648('0x7c2'),'third':_0x566648('0x10ce')},_0x1e59f2[_0x566648('0x23a2')]={'fields':_0x566648('0xadb'),'sort':_0x566648('0xc36'),'MailAccountId':'null','FaxAccountId':_0x566648('0x13c'),'SmsAccountId':_0x566648('0x13c'),'OpenchannelAccountId':_0x566648('0x13c'),'ChatWebsiteId':_0x566648('0x13c'),'WhatsappAccountId':_0x566648('0x13c'),'ListId':_0x566648('0x13c'),'limit':0xa,'page':0x1},_0x1e59f2[_0x566648('0x194f')]=_0x65fae5,_0x1e59f2[_0x566648('0x53')]=_0x41c1ea,_0x1e59f2[_0x566648('0x13d9')]=_0x8db92f,_0x1e59f2[_0x566648('0xe69')]=_0xdf967b,_0x1e59f2[_0x566648('0x207b')]=_0x4aecfa,_0x1e59f2[_0x566648('0x224b')]=_0x53c3a4,_0x1e59f2[_0x566648('0x238e')]=_0x2fe2c9,_0x1e59f2[_0x566648('0x268c')]=_0x560ad8,_0x1e59f2[_0x566648('0x1801')]=_0x221d79;function _0xdf967b(_0x354751,_0x41262d){const _0x416756=_0x566648;_0x21214b[_0x416756('0x1d4')]({'controller':_0x416756('0x1ecc'),'controllerAs':'vm','templateUrl':_0x32807f,'parent':angular[_0x416756('0x1fcc')](_0x55e9ac[_0x416756('0x18e5')]),'targetEvent':_0x354751,'clickOutsideToClose':!![],'locals':{'disposition':_0x41262d,'dispositions':_0x1e59f2[_0x416756('0x191e')][_0x416756('0xf5d')],'model':null,'license':_0x1e59f2[_0x416756('0xace')],'setting':_0x1e59f2[_0x416756('0x260a')],'crudPermissions':_0x1e59f2[_0x416756('0x1134')]}})[_0x416756('0x683')](function(_0x154af4){if(_0x154af4===!![])_0x8db92f();});}function _0x65fae5(_0x4dce58,_0x2ec91a){const _0x50cbf3=_0x566648,_0x129a1f=_0x2e3ca0()[_0x50cbf3('0x7a2')](_0x1e59f2[_0x50cbf3('0x191e')][_0x50cbf3('0xf5d')],[_0x50cbf3('0x1b62'),_0x4dce58['id']]),_0x86ef2a=_0x21214b[_0x50cbf3('0x1c6f')]()[_0x50cbf3('0xf28')](_0x379e6c['instant'](_0x50cbf3('0x15d8')))[_0x50cbf3('0xa6a')](_0x379e6c['instant'](_0x50cbf3('0x13bf')+(_0x129a1f?_0x50cbf3('0x2235'):_0x50cbf3('0x106')),{'name':_0x4dce58[_0x50cbf3('0x60a')]}))[_0x50cbf3('0x1040')](_0x50cbf3('0x550'))[_0x50cbf3('0xe42')](_0x2ec91a)['ok']('OK')['cancel'](_0x379e6c[_0x50cbf3('0x2728')]('TOOLS.CANCEL'));_0x21214b['show'](_0x86ef2a)[_0x50cbf3('0x683')](function(){_0x4aecfa(_0x4dce58);});}function _0x41c1ea(_0x1eff4b){const _0x4d8ea9=_0x566648;_0x1e59f2[_0x4d8ea9('0x191e')]=_0x1eff4b||{'count':0x0,'rows':[]};}function _0x8db92f(){const _0x47a96b=_0x566648;_0x1e59f2[_0x47a96b('0x23a2')][_0x47a96b('0x1cc8')]=(_0x1e59f2['query'][_0x47a96b('0xdf8')]-0x1)*_0x1e59f2['query'][_0x47a96b('0x6f0')],_0x5e45de['isAdmin']()?_0x1e59f2['promise']=_0x33977f['disposition'][_0x47a96b('0x1e6e')](_0x1e59f2['query'],_0x41c1ea)[_0x47a96b('0xe53')]:(_0x1e59f2[_0x47a96b('0x23a2')]['id']=_0x1e59f2['userProfile']['id'],_0x1e59f2[_0x47a96b('0x23a2')][_0x47a96b('0x1aa')]=_0x47a96b('0xf09'),_0x1e59f2[_0x47a96b('0x1883')]=_0x33977f['userProfile'][_0x47a96b('0x241d')](_0x1e59f2[_0x47a96b('0x23a2')],_0x41c1ea)[_0x47a96b('0xe53')]);}function _0x4aecfa(_0x4fc595){const _0x5d8dcb=_0x566648;_0x33977f[_0x5d8dcb('0x43f')][_0x5d8dcb('0xd7e')]({'id':_0x4fc595['id']})[_0x5d8dcb('0xe53')][_0x5d8dcb('0x683')](function(){const _0x55c359=_0x5d8dcb;_0x8db92f(),_0x2eb880[_0x55c359('0x53')]({'title':_0x379e6c[_0x55c359('0x2728')](_0x55c359('0x210b'))});})[_0x5d8dcb('0x130a')](function(_0x4a2bc3){const _0x2773cf=_0x5d8dcb;if(_0x4a2bc3[_0x2773cf('0x5a5')]&&_0x4a2bc3['data'][_0x2773cf('0x17f')]&&_0x4a2bc3[_0x2773cf('0x5a5')][_0x2773cf('0x17f')][_0x2773cf('0x1564')]){_0x1e59f2[_0x2773cf('0x17f')]=_0x4a2bc3[_0x2773cf('0x5a5')]['errors']||[{'message':_0x4a2bc3['toString'](),'type':'SYSTEM:DELETEdisposition'}];for(let _0x3adf45=0x0;_0x3adf45<_0x4a2bc3[_0x2773cf('0x5a5')]['errors'][_0x2773cf('0x1564')];_0x3adf45++){_0x2eb880[_0x2773cf('0x52a')]({'title':_0x4a2bc3[_0x2773cf('0x5a5')][_0x2773cf('0x17f')][_0x3adf45][_0x2773cf('0xcf0')],'msg':_0x4a2bc3[_0x2773cf('0x5a5')][_0x2773cf('0x17f')][_0x3adf45][_0x2773cf('0x8c2')]});}}else _0x2eb880['error']({'title':_0x4a2bc3['status']?'API:'+_0x4a2bc3[_0x2773cf('0x13ee')]+_0x2773cf('0xbf6')+_0x4a2bc3[_0x2773cf('0x24a9')]:'SYSTEM:DELETEdisposition','msg':_0x4a2bc3[_0x2773cf('0x5a5')]?JSON[_0x2773cf('0x258a')](_0x4a2bc3[_0x2773cf('0x5a5')][_0x2773cf('0x8c2')]):_0x4a2bc3[_0x2773cf('0x8c2')]||_0x4a2bc3[_0x2773cf('0x1ff0')]()});});}function _0x53c3a4(){const _0x511c6d=_0x566648,_0x136479=angular[_0x511c6d('0x1a86')](_0x1e59f2[_0x511c6d('0x17')]);return _0x1e59f2[_0x511c6d('0x17')]=[],_0x136479;}function _0x2fe2c9(_0xe017e2){const _0x2778ee=_0x566648,_0x54756b=_0x21214b[_0x2778ee('0x1c6f')]()['title'](_0x379e6c[_0x2778ee('0x2728')](_0x2778ee('0xfa')))[_0x2778ee('0xa6a')](_0x379e6c[_0x2778ee('0x2728')](_0x2778ee('0x1ebe'),{'total':_0x1e59f2[_0x2778ee('0x17')][_0x2778ee('0x1564')]}))[_0x2778ee('0x1040')](_0x2778ee('0xb49'))['targetEvent'](_0xe017e2)['ok']('OK')['cancel'](_0x379e6c['instant'](_0x2778ee('0x9a1')));_0x21214b['show'](_0x54756b)[_0x2778ee('0x683')](function(){const _0xf1145c=_0x2778ee;_0x1e59f2[_0xf1145c('0x17')]['forEach'](function(_0x54a08b){_0x4aecfa(_0x54a08b);}),_0x1e59f2[_0xf1145c('0x17')]=[];});}function _0x560ad8(){const _0x4ee9fa=_0x566648;_0x1e59f2[_0x4ee9fa('0x17')]=[];}function _0x221d79(){const _0x40ec36=_0x566648;_0x1e59f2[_0x40ec36('0x17')]=_0x1e59f2[_0x40ec36('0x191e')][_0x40ec36('0xf5d')];}let _0x5b09e8=!![],_0x158fd9=0x1;_0x366106[_0x566648('0x186d')]('vm.query.filter',function(_0x2bfabd,_0x350a31){const _0x379ed3=_0x566648;_0x5b09e8?_0x29ae31(function(){_0x5b09e8=![];}):(!_0x350a31&&(_0x158fd9=_0x1e59f2[_0x379ed3('0x23a2')][_0x379ed3('0xdf8')]),_0x2bfabd!==_0x350a31&&(_0x1e59f2['query'][_0x379ed3('0xdf8')]=0x1),!_0x2bfabd&&(_0x1e59f2[_0x379ed3('0x23a2')][_0x379ed3('0xdf8')]=_0x158fd9),_0x8db92f());});}const _0x108b2c=_0x5963a2;_0x3615d2[_0x189033('0x14be')]=[_0x189033('0x1398')];function _0x3615d2(_0x8a7466){const _0x53beec=_0x189033;_0x8a7466[_0x53beec('0x2598')](_0x53beec('0x15ed'),{'url':_0x53beec('0x1bd1'),'views':{'content@app':{'templateUrl':_0x1ab724,'controller':'DispositionsController\x20as\x20vm'}},'resolve':{'dispositions':[_0x53beec('0x4b1'),_0x53beec('0xba1'),function(_0x5d8f53,_0xb8411f){const _0x295f3b=_0x53beec;return _0xb8411f['hasRole']('admin')?_0x5d8f53[_0x295f3b('0xed7')](_0x295f3b('0xfaa'),{'fields':_0x295f3b('0xadb'),'sort':_0x295f3b('0xc36'),'MailAccountId':_0x295f3b('0x13c'),'FaxAccountId':_0x295f3b('0x13c'),'SmsAccountId':_0x295f3b('0x13c'),'OpenchannelAccountId':_0x295f3b('0x13c'),'ChatWebsiteId':_0x295f3b('0x13c'),'WhatsappAccountId':_0x295f3b('0x13c'),'ListId':_0x295f3b('0x13c'),'limit':0xa,'offset':0x0}):_0x5d8f53['resolve'](_0x295f3b('0x191b'),{'id':_0xb8411f[_0x295f3b('0x20b2')]()[_0x295f3b('0x2f')],'section':_0x295f3b('0xf09'),'fields':'id,level,name,description,ParentId,createdAt,updatedAt','sort':_0x295f3b('0xc36'),'MailAccountId':_0x295f3b('0x13c'),'FaxAccountId':'null','SmsAccountId':_0x295f3b('0x13c'),'OpenchannelAccountId':_0x295f3b('0x13c'),'ChatWebsiteId':_0x295f3b('0x13c'),'WhatsappAccountId':_0x295f3b('0x13c'),'ListId':'null','limit':0xa,'offset':0x0});}],'userProfile':[_0x53beec('0x4b1'),'Auth',function(_0xa2e647,_0x49ac86){const _0x3a7b09=_0x53beec;return _0x49ac86['hasRole'](_0x3a7b09('0x20c2'))?null:_0xa2e647[_0x3a7b09('0xed7')](_0x3a7b09('0x1464'),{'fields':_0x3a7b09('0x16f'),'id':_0x49ac86[_0x3a7b09('0x20b2')]()[_0x3a7b09('0x2f')]});}],'userProfileSection':[_0x53beec('0x4b1'),_0x53beec('0xba1'),function(_0x5698a1,_0x318a9f){const _0x20fdb6=_0x53beec;return _0x318a9f[_0x20fdb6('0xca1')](_0x20fdb6('0x20c2'))?null:_0x5698a1[_0x20fdb6('0xed7')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x318a9f[_0x20fdb6('0x20b2')]()[_0x20fdb6('0x2f')],'sectionId':0x3ea});}]},'authenticate':!![],'permissionId':0x3ea,'bodyClass':_0x53beec('0x1f88')});}angular['module']('app.tools.dispositions',[])[_0x189033('0x272d')](_0x3615d2)[_0x189033('0x1da3')]('CreateOrEditDispositionDialogController',_0x1dd96d)[_0x189033('0x1da3')](_0x189033('0x1762'),_0x108b2c);const _0xcddef1=_0x180212['p']+'src/js/modules/main/apps/tools/views/triggers/triggers.html/triggers.html',_0x45fd47=_0x180212['p']+'src/js/modules/main/apps/tools/views/triggers/edit/view.html/view.html';_0x5f09d0['$inject']=[_0x189033('0x1e48'),'$translate',_0x189033('0x1d70'),_0x189033('0x13f2'),_0x189033('0x25e2'),'api',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x5f09d0(_0x319e9a,_0x3ba40f,_0x3a2320,_0x21271e,_0x302815,_0x387446,_0x3a14c8,_0x44c74e,_0x712dea,_0x3f082a){const _0x546f97=_0x189033,_0x316e13=this;_0x316e13[_0x546f97('0x11ed')]=_0x3a14c8['getCurrentUser'](),_0x316e13[_0x546f97('0x25e2')]=angular['copy'](_0x302815),_0x316e13['triggers']=angular[_0x546f97('0x1a86')](_0x21271e),_0x316e13[_0x546f97('0x260a')]=_0x712dea,_0x316e13[_0x546f97('0xace')]=_0x44c74e,_0x316e13[_0x546f97('0x1134')]=_0x3f082a,_0x316e13[_0x546f97('0x117')]=![],_0x316e13[_0x546f97('0x17f')]=[];!_0x316e13['trigger']&&(_0x316e13['trigger']={'channel':_0x546f97('0xcf2')},_0x316e13[_0x546f97('0x117')]=!![]);_0x316e13[_0x546f97('0x2502')]=_0x3d604e,_0x316e13[_0x546f97('0x119a')]=_0xbea466,_0x316e13[_0x546f97('0x690')]=_0x3b9616,_0x316e13[_0x546f97('0xf82')]=_0xd2b919;function _0x3d604e(){const _0x5a053d=_0x546f97;_0x316e13[_0x5a053d('0x17f')]=[],_0x387446[_0x5a053d('0x25e2')]['save'](_0x316e13['trigger'])[_0x5a053d('0xe53')][_0x5a053d('0x683')](function(_0xb1a1a7){const _0x598022=_0x5a053d;_0x316e13['triggers']['unshift'](_0xb1a1a7[_0x598022('0x24e1')]()),_0x3a2320[_0x598022('0x53')]({'title':_0x3ba40f[_0x598022('0x2728')]('TOOLS.NOTIFICATIONS.TRIGGER_CREATED_SUCCESS_TITLE')}),_0xd2b919(_0x316e13[_0x598022('0x13f2')]);})[_0x5a053d('0x130a')](function(_0x46e43f){const _0x9a4c54=_0x5a053d;if(_0x46e43f[_0x9a4c54('0x5a5')]&&_0x46e43f['data'][_0x9a4c54('0x17f')]&&_0x46e43f['data'][_0x9a4c54('0x17f')][_0x9a4c54('0x1564')]){_0x316e13[_0x9a4c54('0x17f')]=_0x46e43f[_0x9a4c54('0x5a5')]['errors']||[{'message':_0x46e43f[_0x9a4c54('0x1ff0')](),'type':_0x9a4c54('0x13d0')}];for(let _0x2f3c8c=0x0;_0x2f3c8c<_0x46e43f[_0x9a4c54('0x5a5')]['errors'][_0x9a4c54('0x1564')];_0x2f3c8c+=0x1){_0x3a2320[_0x9a4c54('0x52a')]({'title':_0x46e43f[_0x9a4c54('0x5a5')][_0x9a4c54('0x17f')][_0x2f3c8c][_0x9a4c54('0xcf0')],'msg':_0x46e43f['data'][_0x9a4c54('0x17f')][_0x2f3c8c][_0x9a4c54('0x8c2')]});}}else _0x3a2320['error']({'title':_0x46e43f[_0x9a4c54('0x13ee')]?_0x9a4c54('0x2168')+_0x46e43f['status']+_0x9a4c54('0xbf6')+_0x46e43f[_0x9a4c54('0x24a9')]:_0x9a4c54('0x13d0'),'msg':_0x46e43f['data']?JSON[_0x9a4c54('0x258a')](_0x46e43f[_0x9a4c54('0x5a5')]['message']):_0x46e43f[_0x9a4c54('0x1ff0')]()});});}function _0xbea466(){const _0x451c67=_0x546f97;_0x316e13[_0x451c67('0x17f')]=[],_0x387446[_0x451c67('0x25e2')][_0x451c67('0x2480')]({'id':_0x316e13[_0x451c67('0x25e2')]['id']},_0x316e13[_0x451c67('0x25e2')])['$promise'][_0x451c67('0x683')](function(){const _0x4fadcc=_0x451c67;_0x316e13[_0x4fadcc('0x13f2')]=_0x2e3ca0()[_0x4fadcc('0x386')](_0x316e13[_0x4fadcc('0x13f2')],function(_0x2b3dff){const _0x49b9ec=_0x4fadcc;if(_0x2b3dff['id']===_0x316e13[_0x49b9ec('0x25e2')]['id'])return _0x316e13['trigger'];else return _0x2b3dff;}),_0x3a2320[_0x4fadcc('0x53')]({'title':_0x3ba40f[_0x4fadcc('0x2728')](_0x4fadcc('0x161e'))}),_0xd2b919(_0x316e13[_0x4fadcc('0x13f2')]);})[_0x451c67('0x130a')](function(_0x1a091d){const _0x3ac125=_0x451c67;if(_0x1a091d[_0x3ac125('0x5a5')]&&_0x1a091d[_0x3ac125('0x5a5')][_0x3ac125('0x17f')]&&_0x1a091d[_0x3ac125('0x5a5')][_0x3ac125('0x17f')][_0x3ac125('0x1564')]){_0x316e13[_0x3ac125('0x17f')]=_0x1a091d[_0x3ac125('0x5a5')]['errors']||[{'message':_0x1a091d[_0x3ac125('0x1ff0')](),'type':_0x3ac125('0x15c5')}];for(let _0x4454af=0x0;_0x4454af<_0x1a091d[_0x3ac125('0x5a5')][_0x3ac125('0x17f')]['length'];_0x4454af++){_0x3a2320['error']({'title':_0x1a091d[_0x3ac125('0x5a5')][_0x3ac125('0x17f')][_0x4454af][_0x3ac125('0xcf0')],'msg':_0x1a091d[_0x3ac125('0x5a5')][_0x3ac125('0x17f')][_0x4454af][_0x3ac125('0x8c2')]});}}else _0x3a2320[_0x3ac125('0x52a')]({'title':_0x1a091d['status']?_0x3ac125('0x2168')+_0x1a091d[_0x3ac125('0x13ee')]+'\x20-\x20'+_0x1a091d[_0x3ac125('0x24a9')]:_0x3ac125('0x15c5'),'msg':_0x1a091d[_0x3ac125('0x5a5')]?JSON['stringify'](_0x1a091d['data'][_0x3ac125('0x8c2')]):_0x1a091d[_0x3ac125('0x1ff0')]()});});}function _0x3b9616(_0x4f16f4){const _0x9019b7=_0x546f97;_0x316e13[_0x9019b7('0x17f')]=[];const _0x39f2d1=_0x319e9a[_0x9019b7('0x1c6f')]({'skipHide':!![]})[_0x9019b7('0xf28')](_0x3ba40f[_0x9019b7('0x2728')](_0x9019b7('0x1a98')))[_0x9019b7('0xa6a')](_0x3ba40f[_0x9019b7('0x2728')](_0x9019b7('0xe6d'),{'name':_0x316e13[_0x9019b7('0x25e2')]['name']}))[_0x9019b7('0x1040')](_0x9019b7('0x14c4'))['ok'](_0x3ba40f[_0x9019b7('0x2728')](_0x9019b7('0xc53')))['cancel'](_0x3ba40f[_0x9019b7('0x2728')](_0x9019b7('0x9a1')))[_0x9019b7('0xe42')](_0x4f16f4);_0x319e9a[_0x9019b7('0x1d4')](_0x39f2d1)['then'](function(){const _0x31d592=_0x9019b7;_0x387446['trigger'][_0x31d592('0xd7e')]({'id':_0x316e13[_0x31d592('0x25e2')]['id']})['$promise'][_0x31d592('0x683')](function(){const _0x1a0c88=_0x31d592;_0x316e13[_0x1a0c88('0x13f2')]=_0x2e3ca0()[_0x1a0c88('0x25')](_0x316e13[_0x1a0c88('0x13f2')],function(_0x52ec6b){return _0x52ec6b['id']!==_0x316e13['trigger']['id'];}),_0x3a2320[_0x1a0c88('0x53')]({'title':_0x3ba40f[_0x1a0c88('0x2728')](_0x1a0c88('0x217f'))}),_0xd2b919(_0x316e13[_0x1a0c88('0x13f2')]);})['catch'](function(_0x568edc){const _0x527d17=_0x31d592;if(_0x568edc[_0x527d17('0x5a5')]&&_0x568edc[_0x527d17('0x5a5')][_0x527d17('0x17f')]&&_0x568edc['data'][_0x527d17('0x17f')][_0x527d17('0x1564')]){_0x316e13['errors']=_0x568edc['data']['errors']||[{'message':_0x568edc[_0x527d17('0x1ff0')](),'type':'api.trigger.delete'}];for(let _0x1dc0f3=0x0;_0x1dc0f3<_0x568edc[_0x527d17('0x5a5')][_0x527d17('0x17f')][_0x527d17('0x1564')];_0x1dc0f3++){_0x3a2320[_0x527d17('0x52a')]({'title':_0x568edc['data'][_0x527d17('0x17f')][_0x1dc0f3][_0x527d17('0xcf0')],'msg':_0x568edc['data']['errors'][_0x1dc0f3][_0x527d17('0x8c2')]});}}else _0x3a2320[_0x527d17('0x52a')]({'title':_0x568edc[_0x527d17('0x13ee')]?'API:'+_0x568edc[_0x527d17('0x13ee')]+_0x527d17('0xbf6')+_0x568edc[_0x527d17('0x24a9')]:_0x527d17('0x1c78'),'msg':_0x568edc[_0x527d17('0x5a5')]?JSON[_0x527d17('0x258a')](_0x568edc['data'][_0x527d17('0x8c2')]):_0x568edc[_0x527d17('0x8c2')]||_0x568edc[_0x527d17('0x1ff0')]()});});},function(){});}function _0xd2b919(_0x3d1425){const _0x3455ca=_0x546f97;_0x319e9a[_0x3455ca('0x1715')](_0x3d1425);}}const _0x1baac8=_0x5f09d0,_0x2933e9=_0x180212['p']+_0x189033('0x240d');_0x221b80[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$document',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x221b80(_0xb91500,_0x62e980,_0x4edd48,_0x17898f,_0x4ecbb9,_0xde1eb4,_0x58c79a,_0x4e7ea9){const _0xb076e9=_0x189033,_0x3261df=this;_0x3261df[_0xb076e9('0x11ed')]=_0x4e7ea9['getCurrentUser'](),_0x3261df[_0xb076e9('0x25e2')]={},_0x3261df[_0xb076e9('0xd85')]={'count':0x0,'rows':[]},_0x3261df['selectedTriggerActions']=[],_0x3261df[_0xb076e9('0x23a2')]={'fields':_0xb076e9('0x57c'),'limit':0xa,'page':0x1},_0x3261df[_0xb076e9('0x179d')]={'zendesk':_0xb076e9('0x6'),'salesforce':_0xb076e9('0x634'),'sugarcrm':_0xb076e9('0x268d'),'freshdesk':_0xb076e9('0x861'),'desk':'Desk','zoho':_0xb076e9('0x1925'),'vtiger':_0xb076e9('0x2336'),'dynamics365':_0xb076e9('0x1852'),'servicenow':'ServiceNow','freshsales':_0xb076e9('0x1e1f')},_0x3261df[_0xb076e9('0x1cdd')]={0x0:_0xb076e9('0x12a1'),0x1:_0xb076e9('0x16bb'),0x2:_0xb076e9('0x927')},_0x3261df[_0xb076e9('0x1dd2')]=_0x1a7508,_0x3261df[_0xb076e9('0x53')]=_0x107220,_0x3261df[_0xb076e9('0x3d6')]=_0x432020,_0x3261df[_0xb076e9('0x285')]=_0x353643,_0x3261df['exportSelectedTriggerActions']=_0x3edf7b,_0x3261df[_0xb076e9('0x26eb')]=_0x21e6ee,_0x3261df[_0xb076e9('0x525')]=_0x10be20;function _0x1a7508(_0x5e4b77,_0x134da8){const _0x573880=_0xb076e9;_0x3261df[_0x573880('0x25e2')]=_0x5e4b77,_0x3261df['crudPermissions']=typeof _0x134da8!==_0x573880('0x1867')?_0x134da8:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3261df[_0x573880('0x23a2')][_0x573880('0xfbc')]=_0x3261df[_0x573880('0x25e2')]['id'],_0x3261df[_0x573880('0x23a2')]['id']=_0x3261df[_0x573880('0x25e2')]['id'],_0x432020();}function _0x3d3100(){const _0x2c2cb5=_0xb076e9;_0x4e7ea9[_0x2c2cb5('0x1d32')]()?_0x58c79a[_0x2c2cb5('0x259b')]['get']({'fields':_0x2c2cb5('0xa10'),'sort':_0x2c2cb5('0x60a'),'nolimit':_0x2c2cb5('0x26ac')})[_0x2c2cb5('0xe53')][_0x2c2cb5('0x683')](function(_0x43d919){const _0x276ef6=_0x2c2cb5;_0x3261df[_0x276ef6('0xe01')]=_0x43d919[_0x276ef6('0xf5d')]||[];})[_0x2c2cb5('0x130a')](function(_0x3ffe6c){const _0x3e8f18=_0x2c2cb5;_0xde1eb4[_0x3e8f18('0x52a')]({'title':_0x3ffe6c[_0x3e8f18('0x13ee')]?_0x3e8f18('0x2168')+_0x3ffe6c[_0x3e8f18('0x13ee')]+_0x3e8f18('0xbf6')+_0x3ffe6c[_0x3e8f18('0x24a9')]:_0x3e8f18('0x251b'),'msg':_0x3ffe6c[_0x3e8f18('0x5a5')]?JSON[_0x3e8f18('0x258a')](_0x3ffe6c[_0x3e8f18('0x5a5')]):_0x3ffe6c[_0x3e8f18('0x1ff0')]()});}):_0x58c79a[_0x2c2cb5('0x259b')][_0x2c2cb5('0x1e6e')]({'fields':_0x2c2cb5('0xa10'),'sort':'name','nolimit':'true'})['$promise'][_0x2c2cb5('0x683')](function(_0x30a128){const _0x33f05f=_0x2c2cb5;_0x3261df[_0x33f05f('0xe01')]=_0x30a128['rows']||[];})['then'](function(){const _0x556141=_0x2c2cb5;return _0x58c79a['userProfileSection'][_0x556141('0x1e6e')]({'userProfileId':_0x3261df[_0x556141('0x11ed')][_0x556141('0x2f')],'sectionId':0x12d})['$promise'];})[_0x2c2cb5('0x683')](function(_0x50d995){const _0x4171f8=_0x2c2cb5,_0xa60286=_0x50d995&&_0x50d995[_0x4171f8('0xf5d')]?_0x50d995[_0x4171f8('0xf5d')][0x0]:null;if(!_0xa60286){const _0x1f3302=[],_0x5b0324=[];_0x3261df['triggerActions']['rows'][_0x4171f8('0x1299')](function(_0x4d4e62){const _0x1b9557=_0x4171f8;if(_0x4d4e62[_0x1b9557('0x1f0e')]==='contactManager'){const _0x219c4f=_0x2e3ca0()[_0x1b9557('0x1c07')](_0x3261df[_0x1b9557('0xe01')],{'id':Number(_0x4d4e62[_0x1b9557('0x2790')])});_0x5b0324[_0x1b9557('0x1fd0')](_0x219c4f);}});for(let _0x1bbd03=0x0;_0x1bbd03<_0x3261df[_0x4171f8('0xe01')][_0x4171f8('0x1564')];_0x1bbd03++){const _0x36318e=_0x2e3ca0()[_0x4171f8('0x7a2')](_0x5b0324,{'id':_0x3261df[_0x4171f8('0xe01')][_0x1bbd03]['id']});_0x36318e&&(_0x3261df[_0x4171f8('0xe01')][_0x1bbd03][_0x4171f8('0x319')]=![],_0x1f3302[_0x4171f8('0x1fd0')](_0x3261df[_0x4171f8('0xe01')][_0x1bbd03]));}_0x3261df[_0x4171f8('0xe01')]=_0x1f3302;}else{if(!_0xa60286['autoAssociation'])return _0x58c79a[_0x4171f8('0xcf7')][_0x4171f8('0x1e6e')]({'sectionId':_0xa60286['id']})[_0x4171f8('0xe53')][_0x4171f8('0x683')](function(_0xdb85bc){const _0xc3e341=_0x4171f8,_0x3a1450=_0x2e3ca0()[_0xc3e341('0x386')](_0xdb85bc['rows'],function(_0x10088c){const _0xb506df=_0xc3e341;return _0x2e3ca0()[_0xb506df('0x1c07')](_0x3261df[_0xb506df('0xe01')],{'id':_0x10088c[_0xb506df('0x832')]});});let _0x150fec=null;_0x150fec=[],_0x3261df[_0xc3e341('0xd85')][_0xc3e341('0xf5d')][_0xc3e341('0x1299')](function(_0x47ddba){const _0x28c087=_0xc3e341;if(_0x47ddba[_0x28c087('0x1f0e')]===_0x28c087('0x869')){const _0x39a07c=_0x2e3ca0()[_0x28c087('0x1c07')](_0x3261df['lists'],{'id':Number(_0x47ddba[_0x28c087('0x2790')])});_0x150fec[_0x28c087('0x1fd0')](_0x39a07c);}}),!_0x2e3ca0()[_0xc3e341('0x173f')](_0x150fec)&&_0x150fec[_0xc3e341('0x1299')](function(_0x2450fa){const _0x5a8914=_0xc3e341;if(!_0x2e3ca0()[_0x5a8914('0x7a2')](_0x3a1450,['id',_0x2450fa['id']])){const _0x3bdfca=_0x2e3ca0()['find'](_0x3261df[_0x5a8914('0xe01')],{'id':_0x2450fa['id']});_0x3bdfca['canSelect']=![],_0x3a1450[_0x5a8914('0x1fd0')](_0x3bdfca);}}),_0x3261df[_0xc3e341('0xe01')]=_0x3a1450;});}})[_0x2c2cb5('0x130a')](function(_0x42c067){const _0x22e733=_0x2c2cb5;_0xde1eb4[_0x22e733('0x52a')]({'title':_0x42c067[_0x22e733('0x13ee')]?'API:'+_0x42c067[_0x22e733('0x13ee')]+_0x22e733('0xbf6')+_0x42c067['statusText']:'SYSTEM:GETlists','msg':_0x42c067[_0x22e733('0x5a5')]?JSON[_0x22e733('0x258a')](_0x42c067[_0x22e733('0x5a5')]):_0x42c067[_0x22e733('0x1ff0')]()});});}function _0x2ac3df(){const _0xc4a836=_0xb076e9,_0x34e4bc=_0x2e3ca0()(_0x3261df[_0xc4a836('0xd85')][_0xc4a836('0xf5d')])[_0xc4a836('0x386')](function(_0x44811e){const _0x2e0147=_0xc4a836;return _0x44811e[_0x2e0147('0x1f0e')]==='integration'?_0x44811e[_0x2e0147('0x2790')]:undefined;})[_0xc4a836('0x1043')]()[_0xc4a836('0xbf7')]()[_0xc4a836('0x1c6b')]();_0x34e4bc[_0xc4a836('0x1299')](function(_0x8711b3){const _0x34daf2=_0xc4a836,_0x2b3805=_0x8711b3+_0x34daf2('0x2059');if(!_0x3261df[_0x2b3805]){const _0x1fc879=_0x34daf2('0x1d17')+_0x2e3ca0()[_0x34daf2('0x1e03')](_0x8711b3)+'Account';_0x58c79a[_0x1fc879][_0x34daf2('0x1e6e')]({'fields':_0x34daf2('0xa10'),'sort':'id','nolimit':_0x34daf2('0x26ac')})['$promise'][_0x34daf2('0x683')](function(_0x2ea066){const _0x99b55a=_0x34daf2;_0x3261df[_0x2b3805]=_0x2ea066[_0x99b55a('0xf5d')]||[];})[_0x34daf2('0x130a')](function(_0x437240){const _0x68b03b=_0x34daf2;_0xde1eb4[_0x68b03b('0x52a')]({'title':_0x437240[_0x68b03b('0x13ee')]?'API:'+_0x437240[_0x68b03b('0x13ee')]+_0x68b03b('0xbf6')+_0x437240[_0x68b03b('0x24a9')]:_0x68b03b('0xf4a')+_0x2b3805[_0x68b03b('0x80')]()+'ACCOUNTS','msg':_0x437240[_0x68b03b('0x5a5')]?JSON['stringify'](_0x437240[_0x68b03b('0x5a5')]):_0x437240[_0x68b03b('0x1ff0')]()});});}});}function _0xdebf4(){const _0x142853=_0xb076e9;_0x4e7ea9[_0x142853('0x1d32')]()?_0x58c79a[_0x142853('0xa8b')][_0x142853('0x1e6e')]({'fields':'id,name','sort':_0x142853('0x60a'),'nolimit':_0x142853('0x26ac')})[_0x142853('0xe53')][_0x142853('0x683')](function(_0x66bca9){const _0x1d0391=_0x142853;_0x3261df[_0x1d0391('0x1248')]=_0x66bca9[_0x1d0391('0xf5d')]||[];})[_0x142853('0x130a')](function(_0x175d8f){const _0x246394=_0x142853;_0xde1eb4[_0x246394('0x52a')]({'title':_0x175d8f[_0x246394('0x13ee')]?'API:'+_0x175d8f['status']+_0x246394('0xbf6')+_0x175d8f[_0x246394('0x24a9')]:_0x246394('0xd0e'),'msg':_0x175d8f[_0x246394('0x5a5')]?JSON[_0x246394('0x258a')](_0x175d8f[_0x246394('0x5a5')]):_0x175d8f['toString']()});}):_0x58c79a[_0x142853('0xa8b')][_0x142853('0x1e6e')]({'fields':_0x142853('0xa10'),'sort':_0x142853('0x60a'),'nolimit':_0x142853('0x26ac')})[_0x142853('0xe53')]['then'](function(_0x572178){const _0x495bd0=_0x142853;_0x3261df[_0x495bd0('0x1248')]=_0x572178[_0x495bd0('0xf5d')]||[];})[_0x142853('0x683')](function(){const _0x4167b1=_0x142853;return _0x58c79a[_0x4167b1('0x22df')]['get']({'userProfileId':_0x3261df[_0x4167b1('0x11ed')][_0x4167b1('0x2f')],'sectionId':0x6a5})[_0x4167b1('0xe53')];})[_0x142853('0x683')](function(_0xd7c38f){const _0x55121d=_0x142853,_0x17523f=_0xd7c38f&&_0xd7c38f['rows']?_0xd7c38f[_0x55121d('0xf5d')][0x0]:null;if(!_0x17523f){const _0xe25561=[],_0x234bba=[];_0x3261df[_0x55121d('0xd85')][_0x55121d('0xf5d')][_0x55121d('0x1299')](function(_0x1d33e3){const _0x3e6aab=_0x55121d;if(_0x1d33e3[_0x3e6aab('0x1f0e')]==='jscripty'){const _0x5c9cfa=_0x2e3ca0()[_0x3e6aab('0x1c07')](_0x3261df[_0x3e6aab('0x1248')],{'id':Number(_0x1d33e3[_0x3e6aab('0x2790')])});_0x234bba['push'](_0x5c9cfa);}});for(let _0x57a9ea=0x0;_0x57a9ea<_0x3261df['projects'][_0x55121d('0x1564')];_0x57a9ea++){const _0x9687a8=_0x2e3ca0()[_0x55121d('0x7a2')](_0x234bba,{'id':_0x3261df[_0x55121d('0x1248')][_0x57a9ea]['id']});_0x9687a8&&(_0x3261df[_0x55121d('0x1248')][_0x57a9ea]['canSelect']=![],_0xe25561['push'](_0x3261df[_0x55121d('0x1248')][_0x57a9ea]));}_0x3261df[_0x55121d('0x1248')]=_0xe25561;}else{if(!_0x17523f['autoAssociation'])return _0x58c79a[_0x55121d('0xcf7')][_0x55121d('0x1e6e')]({'sectionId':_0x17523f['id']})[_0x55121d('0xe53')][_0x55121d('0x683')](function(_0x730555){const _0x23eb2b=_0x55121d,_0x334786=_0x2e3ca0()['map'](_0x730555['rows'],function(_0x1d58e0){const _0x303770=a0_0x4e0a;return _0x2e3ca0()['find'](_0x3261df[_0x303770('0x1248')],{'id':_0x1d58e0[_0x303770('0x832')]});});let _0x425729=null;_0x425729=[],_0x3261df[_0x23eb2b('0xd85')][_0x23eb2b('0xf5d')][_0x23eb2b('0x1299')](function(_0x461cfc){const _0x46b4af=_0x23eb2b;if(_0x461cfc[_0x46b4af('0x1f0e')]==='jscripty'){const _0xac71de=_0x2e3ca0()[_0x46b4af('0x1c07')](_0x3261df['projects'],{'id':Number(_0x461cfc['data1'])});_0x425729[_0x46b4af('0x1fd0')](_0xac71de);}}),!_0x2e3ca0()['isEmpty'](_0x425729)&&_0x425729[_0x23eb2b('0x1299')](function(_0x416e49){const _0x1ad807=_0x23eb2b;if(!_0x2e3ca0()[_0x1ad807('0x7a2')](_0x334786,['id',_0x416e49['id']])){const _0x1050cb=_0x2e3ca0()['find'](_0x3261df[_0x1ad807('0x1248')],{'id':_0x416e49['id']});_0x1050cb[_0x1ad807('0x319')]=![],_0x334786[_0x1ad807('0x1fd0')](_0x1050cb);}}),_0x3261df[_0x23eb2b('0x1248')]=_0x334786;});}})[_0x142853('0x130a')](function(_0x3eeb27){const _0x4b0ea6=_0x142853;_0xde1eb4[_0x4b0ea6('0x52a')]({'title':_0x3eeb27['status']?_0x4b0ea6('0x2168')+_0x3eeb27[_0x4b0ea6('0x13ee')]+'\x20-\x20'+_0x3eeb27[_0x4b0ea6('0x24a9')]:_0x4b0ea6('0x616'),'msg':_0x3eeb27[_0x4b0ea6('0x5a5')]?JSON['stringify'](_0x3eeb27['data']):_0x3eeb27['toString']()});});}function _0x441f45(){const _0xbde82a=_0xb076e9;_0x4e7ea9[_0xbde82a('0x1d32')]()?_0x58c79a[_0xbde82a('0x1cc6')]['get']({'fields':'id,name','sort':'id','nolimit':_0xbde82a('0x26ac')})[_0xbde82a('0xe53')][_0xbde82a('0x683')](function(_0x29a8ee){const _0x3f90cb=_0xbde82a;_0x3261df[_0x3f90cb('0x84b')]=_0x29a8ee['rows']||[];})[_0xbde82a('0x130a')](function(_0x3895a7){const _0x2e5a4f=_0xbde82a;_0xde1eb4['error']({'title':_0x3895a7[_0x2e5a4f('0x13ee')]?_0x2e5a4f('0x2168')+_0x3895a7[_0x2e5a4f('0x13ee')]+'\x20-\x20'+_0x3895a7[_0x2e5a4f('0x24a9')]:_0x2e5a4f('0xab7'),'msg':_0x3895a7[_0x2e5a4f('0x5a5')]?JSON[_0x2e5a4f('0x258a')](_0x3895a7['data']):_0x3895a7[_0x2e5a4f('0x1ff0')]()});}):_0x58c79a[_0xbde82a('0x1cc6')]['get']({'fields':'id,name','sort':'id','nolimit':_0xbde82a('0x26ac')})['$promise'][_0xbde82a('0x683')](function(_0x174b0f){const _0x4f6de3=_0xbde82a;_0x3261df[_0x4f6de3('0x84b')]=_0x174b0f[_0x4f6de3('0xf5d')]||[];})[_0xbde82a('0x683')](function(){const _0x3d5f11=_0xbde82a;return _0x58c79a[_0x3d5f11('0x22df')][_0x3d5f11('0x1e6e')]({'userProfileId':_0x3261df['currentUser'][_0x3d5f11('0x2f')],'sectionId':0x3f1})[_0x3d5f11('0xe53')];})[_0xbde82a('0x683')](function(_0x41b114){const _0x53147b=_0xbde82a,_0x5c9016=_0x41b114&&_0x41b114[_0x53147b('0xf5d')]?_0x41b114[_0x53147b('0xf5d')][0x0]:null;if(!_0x5c9016){const _0x38c665=[],_0x27d608=[];_0x3261df[_0x53147b('0xd85')][_0x53147b('0xf5d')][_0x53147b('0x1299')](function(_0x1f9f34){const _0x185701=_0x53147b;if(_0x2e3ca0()['includes'](['motionbar',_0x185701('0x47d')],_0x1f9f34['action'])){const _0x12d914=_0x2e3ca0()[_0x185701('0x1c07')](_0x3261df[_0x185701('0x84b')],{'id':Number(_0x1f9f34[_0x185701('0x1d30')])});_0x27d608[_0x185701('0x1fd0')](_0x12d914);}});for(let _0x43cfc2=0x0;_0x43cfc2<_0x3261df['templates'][_0x53147b('0x1564')];_0x43cfc2++){const _0xd8e935=_0x2e3ca0()['some'](_0x27d608,{'id':_0x3261df[_0x53147b('0x84b')][_0x43cfc2]['id']});_0xd8e935&&(_0x3261df[_0x53147b('0x84b')][_0x43cfc2]['canSelect']=![],_0x38c665[_0x53147b('0x1fd0')](_0x3261df[_0x53147b('0x84b')][_0x43cfc2]));}_0x3261df['templates']=_0x38c665;}else{if(!_0x5c9016[_0x53147b('0x170')])return _0x58c79a['userProfileResource'][_0x53147b('0x1e6e')]({'sectionId':_0x5c9016['id']})['$promise']['then'](function(_0xc2357e){const _0x243898=_0x53147b,_0x4df728=_0x2e3ca0()['map'](_0xc2357e[_0x243898('0xf5d')],function(_0x41cd7e){const _0x5926aa=_0x243898;return _0x2e3ca0()[_0x5926aa('0x1c07')](_0x3261df[_0x5926aa('0x84b')],{'id':_0x41cd7e['resourceId']});});let _0xfa2021=null;_0xfa2021=[],_0x3261df[_0x243898('0xd85')][_0x243898('0xf5d')]['forEach'](function(_0xe8318){const _0x343855=_0x243898;if(_0x2e3ca0()[_0x343855('0x2292')](['motionbar','browser'],_0xe8318[_0x343855('0x1f0e')])){const _0x5bf5ac=_0x2e3ca0()[_0x343855('0x1c07')](_0x3261df[_0x343855('0x84b')],{'id':Number(_0xe8318[_0x343855('0x1d30')])});_0xfa2021[_0x343855('0x1fd0')](_0x5bf5ac);}}),!_0x2e3ca0()[_0x243898('0x173f')](_0xfa2021)&&_0xfa2021['forEach'](function(_0x1b1fa5){const _0x26336b=_0x243898;if(!_0x2e3ca0()['some'](_0x4df728,['id',_0x1b1fa5['id']])){const _0x22f4ce=_0x2e3ca0()[_0x26336b('0x1c07')](_0x3261df[_0x26336b('0x84b')],{'id':_0x1b1fa5['id']});_0x22f4ce['canSelect']=![],_0x4df728[_0x26336b('0x1fd0')](_0x22f4ce);}}),_0x3261df[_0x243898('0x84b')]=_0x4df728;});}})[_0xbde82a('0x130a')](function(_0x41fc74){const _0x5aecb9=_0xbde82a;_0xde1eb4[_0x5aecb9('0x52a')]({'title':_0x41fc74[_0x5aecb9('0x13ee')]?'API:'+_0x41fc74[_0x5aecb9('0x13ee')]+_0x5aecb9('0xbf6')+_0x41fc74[_0x5aecb9('0x24a9')]:'SYSTEM:GET_TEMPLATES','msg':_0x41fc74['data']?JSON[_0x5aecb9('0x258a')](_0x41fc74['data']):_0x41fc74['toString']()});});}function _0x58ae33(){const _0x2cf7da=_0xb076e9;if(_0x2e3ca0()[_0x2cf7da('0x7a2')](_0x3261df[_0x2cf7da('0xd85')][_0x2cf7da('0xf5d')],[_0x2cf7da('0x1f0e'),'contactManager'])){if(!_0x3261df[_0x2cf7da('0xe01')])_0x3d3100();}_0x2e3ca0()[_0x2cf7da('0x7a2')](_0x3261df[_0x2cf7da('0xd85')][_0x2cf7da('0xf5d')],[_0x2cf7da('0x1f0e'),_0x2cf7da('0x3e8')])&&_0x2ac3df();if(_0x2e3ca0()[_0x2cf7da('0x7a2')](_0x3261df[_0x2cf7da('0xd85')][_0x2cf7da('0xf5d')],function(_0xee253c){const _0x73f2f4=_0x2cf7da;return _0x2e3ca0()[_0x73f2f4('0x2292')]([_0x73f2f4('0x1a00'),_0x73f2f4('0x47d')],_0xee253c[_0x73f2f4('0x1f0e')]);})){if(!_0x3261df[_0x2cf7da('0x84b')])_0x441f45();}if(_0x2e3ca0()[_0x2cf7da('0x7a2')](_0x3261df[_0x2cf7da('0xd85')][_0x2cf7da('0xf5d')],['action',_0x2cf7da('0x18e6')])){if(!_0x3261df[_0x2cf7da('0x1248')])_0xdebf4();}}function _0x107220(_0x4566fa){const _0x855a66=_0xb076e9;_0x3261df[_0x855a66('0xd85')]=_0x4566fa||{'count':0x0,'rows':[]},_0x58ae33();}function _0x432020(){const _0x571f80=_0xb076e9;_0x3261df[_0x571f80('0x23a2')][_0x571f80('0x1cc8')]=(_0x3261df[_0x571f80('0x23a2')][_0x571f80('0xdf8')]-0x1)*_0x3261df[_0x571f80('0x23a2')][_0x571f80('0x6f0')],_0x3261df[_0x571f80('0x1883')]=_0x58c79a[_0x571f80('0x25e2')][_0x571f80('0x275')](_0x3261df[_0x571f80('0x23a2')],_0x107220)[_0x571f80('0xe53')];}function _0x353643(_0x13d4ab,_0x50a5e6){const _0x18cd3f=_0xb076e9;_0x17898f['show']({'controller':_0x18cd3f('0x11ae'),'controllerAs':'vm','templateUrl':_0x2933e9,'parent':angular[_0x18cd3f('0x1fcc')](_0x4ecbb9[_0x18cd3f('0x18e5')]),'targetEvent':_0x13d4ab,'clickOutsideToClose':!![],'locals':{'trigger':_0x3261df[_0x18cd3f('0x25e2')],'action':_0x50a5e6,'actions':_0x3261df['triggerActions'][_0x18cd3f('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x3261df['crudPermissions']}})[_0x18cd3f('0x683')](function(_0x29174e){const _0x1bb75a=_0x18cd3f;_0x29174e&&(_0x3261df[_0x1bb75a('0xd85')]={'count':_0x29174e[_0x1bb75a('0x1564')],'rows':_0x29174e},_0x58ae33());});}function _0x21e6ee(_0x5e0aa4,_0x2bb207){const _0x5adea0=_0xb076e9,_0x3d89a4=_0x17898f[_0x5adea0('0x1c6f')]()[_0x5adea0('0xf28')](_0x62e980['instant'](_0x5adea0('0x1c8c')))[_0x5adea0('0x1040')](_0x5adea0('0xf5'))[_0x5adea0('0xe42')](_0x2bb207)['ok']('OK')[_0x5adea0('0x19fb')](_0x62e980[_0x5adea0('0x2728')]('TOOLS.CANCEL'));_0x17898f['show'](_0x3d89a4)[_0x5adea0('0x683')](function(){_0x154565(_0x5e0aa4,!![]);});}function _0x154565(_0x4a3d31,_0xd8a6cb){const _0x5e3ffb=_0xb076e9;_0x58c79a[_0x5e3ffb('0x1f0e')][_0x5e3ffb('0xd7e')]({'id':_0x4a3d31['id']})['$promise'][_0x5e3ffb('0x683')](function(){const _0x2cef4b=_0x5e3ffb;_0x432020(),_0xd8a6cb&&_0xde1eb4[_0x2cef4b('0x53')]({'title':_0x62e980[_0x2cef4b('0x2728')](_0x2cef4b('0x7e1'))});})[_0x5e3ffb('0x130a')](function(_0x313517){const _0x802862=_0x5e3ffb;if(_0x313517[_0x802862('0x5a5')]&&_0x313517[_0x802862('0x5a5')]['errors']&&_0x313517[_0x802862('0x5a5')][_0x802862('0x17f')]['length']){_0x3261df[_0x802862('0x17f')]=_0x313517['data']['errors']||[{'message':_0x313517[_0x802862('0x1ff0')](),'type':'SYSTEM:GETtrigger'}];for(let _0x8b8046=0x0;_0x8b8046<_0x313517[_0x802862('0x5a5')][_0x802862('0x17f')]['length'];_0x8b8046++){_0xde1eb4[_0x802862('0x52a')]({'title':_0x313517[_0x802862('0x5a5')][_0x802862('0x17f')][_0x8b8046][_0x802862('0xcf0')],'msg':_0x313517[_0x802862('0x5a5')][_0x802862('0x17f')][_0x8b8046][_0x802862('0x8c2')]});}}else _0xde1eb4[_0x802862('0x52a')]({'title':_0x313517[_0x802862('0x13ee')]?_0x802862('0x2168')+_0x313517[_0x802862('0x13ee')]+_0x802862('0xbf6')+_0x313517[_0x802862('0x24a9')]:_0x802862('0x107f'),'msg':_0x313517[_0x802862('0x5a5')]?JSON[_0x802862('0x258a')](_0x313517['data']['message']):_0x313517[_0x802862('0x8c2')]||_0x313517['toString']()});});}function _0x3edf7b(){const _0x260bc8=_0xb076e9,_0x11774a=angular[_0x260bc8('0x1a86')](_0x3261df[_0x260bc8('0x35e')]);return _0x3261df[_0x260bc8('0x35e')]=[],_0x11774a;}function _0x10be20(_0x4b86bd){const _0x246b6e=_0xb076e9,_0x195b0a=_0x17898f[_0x246b6e('0x1c6f')]()[_0x246b6e('0xf28')](_0x62e980[_0x246b6e('0x2728')](_0x246b6e('0x118a')))[_0x246b6e('0xa6a')](_0x62e980[_0x246b6e('0x2728')](_0x246b6e('0x20f7'),{'total':_0x3261df[_0x246b6e('0x35e')][_0x246b6e('0x1564')]}))[_0x246b6e('0x1040')](_0x246b6e('0x4a4'))[_0x246b6e('0xe42')](_0x4b86bd)['ok']('OK')[_0x246b6e('0x19fb')](_0x62e980[_0x246b6e('0x2728')]('TOOLS.CANCEL'));_0x17898f[_0x246b6e('0x1d4')](_0x195b0a)[_0x246b6e('0x683')](function(){const _0x25e591=_0x246b6e;_0x3261df[_0x25e591('0x35e')][_0x25e591('0x1299')](function(_0x521fa1){_0x154565(_0x521fa1);}),_0x3261df[_0x25e591('0x35e')]=[],_0xde1eb4['success']({'title':_0x62e980['instant'](_0x25e591('0xe8d'))});});}let _0x567e04=!![],_0x40727f=0x1;_0xb91500[_0xb076e9('0x186d')](_0xb076e9('0x229'),function(_0x25a941,_0x19e97e){const _0x9f63f8=_0xb076e9;_0x567e04?_0x4edd48(function(){_0x567e04=![];}):(!_0x19e97e&&(_0x40727f=_0x3261df[_0x9f63f8('0x23a2')][_0x9f63f8('0xdf8')]),_0x25a941!==_0x19e97e&&(_0x3261df[_0x9f63f8('0x23a2')][_0x9f63f8('0xdf8')]=0x1),!_0x25a941&&(_0x3261df['query']['page']=_0x40727f),_0x432020());});}const _0x415b1f=_0x221b80;_0x15f2d7[_0x189033('0x14be')]=['$state',_0x189033('0x1e48'),_0x189033('0x1d08'),_0x189033('0x1d70'),'actions',_0x189033('0x1f0e'),_0x189033('0x25e2'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x15f2d7(_0x3ad3e3,_0x53eed3,_0x511f4e,_0x49491f,_0x2f32de,_0x10ce4f,_0x447923,_0x23c7e2,_0x46efea,_0x3c54da,_0x13cfdb,_0x8b6437){const _0x4e4c22=_0x189033,_0x3ce77c=this;_0x3ce77c['currentUser']=_0x46efea[_0x4e4c22('0x20b2')](),_0x3ce77c[_0x4e4c22('0x1f0e')]=angular[_0x4e4c22('0x1a86')](_0x10ce4f),_0x3ce77c['actions']=angular[_0x4e4c22('0x1a86')](_0x2f32de),_0x3ce77c[_0x4e4c22('0x260a')]=_0x13cfdb,_0x3ce77c[_0x4e4c22('0xace')]=_0x3c54da,_0x3ce77c[_0x4e4c22('0x1134')]=_0x8b6437,_0x3ce77c[_0x4e4c22('0x622')]=![],_0x3ce77c[_0x4e4c22('0x17f')]=[],_0x3ce77c[_0x4e4c22('0x25e2')]=angular[_0x4e4c22('0x1a86')](_0x447923);!_0x3ce77c['action']&&(_0x3ce77c[_0x4e4c22('0x1f0e')]={},_0x3ce77c[_0x4e4c22('0x622')]=!![]);_0x3ce77c[_0x4e4c22('0x1f0e')][_0x4e4c22('0xfbc')]=_0x3ad3e3[_0x4e4c22('0x7f2')]['id']||undefined,_0x3ce77c[_0x4e4c22('0x1d8d')]=[_0x4e4c22('0xd31'),_0x4e4c22('0x200f'),'fax'],_0x3ce77c['addNewAction']=_0x2fe18f,_0x3ce77c[_0x4e4c22('0x12c7')]=_0x449576,_0x3ce77c[_0x4e4c22('0x1e15')]=_0x37e499,_0x3ce77c[_0x4e4c22('0x4d6')]=_0x583bf2,_0x3ce77c[_0x4e4c22('0x23f9')]=_0x4663f6,_0x3ce77c['onSearchFieldsInit']=_0x2cd165,_0x3ce77c[_0x4e4c22('0x1185')]=_0x186ace,_0x3ce77c['onIntegrationSelection']=_0x316870,_0x3ce77c[_0x4e4c22('0x74f')]=_0x18c355,_0x3ce77c['onTypeSelection']=_0x4d0704,_0x3ce77c['onAutocreateSelection']=_0x906eb6,_0x3ce77c[_0x4e4c22('0xc0')]=_0x18c279,_0x3ce77c[_0x4e4c22('0xf82')]=_0x16b84a;function _0x583bf2(){const _0x1cb510=_0x4e4c22;_0x46efea['hasModulePermissions'](_0x1cb510('0x1c22'))[_0x1cb510('0x683')](function(_0x14bf79){const _0x34ef3d=_0x1cb510;_0x3ce77c[_0x34ef3d('0xe09')]=_0x14bf79;})[_0x1cb510('0x130a')](function(_0xfecbca){const _0x373898=_0x1cb510;_0x49491f[_0x373898('0x52a')]({'title':_0xfecbca[_0x373898('0x13ee')]?_0x373898('0x2168')+_0xfecbca[_0x373898('0x13ee')]+_0x373898('0xbf6')+_0xfecbca[_0x373898('0x24a9')]:_0x373898('0x83a'),'msg':_0xfecbca[_0x373898('0x5a5')]?JSON['stringify'](_0xfecbca['data']):_0xfecbca[_0x373898('0x1ff0')]()});});if(_0x3ce77c[_0x1cb510('0x1f0e')][_0x1cb510('0x1f0e')])_0x534b60();}function _0x4663f6(){const _0x636bd9=_0x4e4c22,_0x2f2b44=[0x515,0x516,0x517,0x519,0x51a,0x51b,0x51c,0x51d,0x51e,0x51f];_0x46efea[_0x636bd9('0x168b')](_0x2f2b44)[_0x636bd9('0x683')](function(_0x421a56){const _0x285486=_0x636bd9;_0x3ce77c[_0x285486('0x1b23')]=_0x2e3ca0()[_0x285486('0xf22')](_0x3ce77c[_0x285486('0x1b23')],_0x421a56);})[_0x636bd9('0x130a')](function(_0x205752){const _0x3988b9=_0x636bd9;_0x49491f[_0x3988b9('0x52a')]({'title':_0x205752['status']?_0x3988b9('0x2168')+_0x205752[_0x3988b9('0x13ee')]+_0x3988b9('0xbf6')+_0x205752[_0x3988b9('0x24a9')]:_0x3988b9('0x22c3'),'msg':_0x205752[_0x3988b9('0x5a5')]?JSON[_0x3988b9('0x258a')](_0x205752[_0x3988b9('0x5a5')]):_0x205752[_0x3988b9('0x1ff0')]()});});}function _0x2cd165(){const _0x4cbb77=_0x4e4c22;if(!_0x3ce77c[_0x4cbb77('0x622')])_0x5220f4();}function _0x3f59c8(){const _0xa8c199=_0x4e4c22;_0x46efea[_0xa8c199('0x1d32')]()?_0x23c7e2[_0xa8c199('0x259b')][_0xa8c199('0x1e6e')]({'fields':_0xa8c199('0xa10'),'sort':_0xa8c199('0x60a'),'nolimit':_0xa8c199('0x26ac')})[_0xa8c199('0xe53')][_0xa8c199('0x683')](function(_0x333096){const _0x2f3a37=_0xa8c199;_0x3ce77c[_0x2f3a37('0xe01')]=_0x333096[_0x2f3a37('0xf5d')]||[];})[_0xa8c199('0x130a')](function(_0x405aa2){const _0x26b22f=_0xa8c199;_0x49491f[_0x26b22f('0x52a')]({'title':_0x405aa2[_0x26b22f('0x13ee')]?_0x26b22f('0x2168')+_0x405aa2[_0x26b22f('0x13ee')]+'\x20-\x20'+_0x405aa2[_0x26b22f('0x24a9')]:_0x26b22f('0x251b'),'msg':_0x405aa2[_0x26b22f('0x5a5')]?JSON[_0x26b22f('0x258a')](_0x405aa2[_0x26b22f('0x5a5')]):_0x405aa2[_0x26b22f('0x1ff0')]()});}):_0x23c7e2[_0xa8c199('0x259b')]['get']({'fields':_0xa8c199('0xa10'),'sort':_0xa8c199('0x60a'),'nolimit':'true'})['$promise'][_0xa8c199('0x683')](function(_0x31b353){_0x3ce77c['lists']=_0x31b353['rows']||[];})[_0xa8c199('0x683')](function(){const _0x4bbb27=_0xa8c199;return _0x23c7e2['userProfileSection']['get']({'userProfileId':_0x3ce77c[_0x4bbb27('0x11ed')][_0x4bbb27('0x2f')],'sectionId':0x12d})[_0x4bbb27('0xe53')];})[_0xa8c199('0x683')](function(_0x3cdc6b){const _0x186393=_0xa8c199,_0x23697a=_0x3cdc6b&&_0x3cdc6b[_0x186393('0xf5d')]?_0x3cdc6b[_0x186393('0xf5d')][0x0]:null;if(!_0x23697a){const _0x585622=[],_0x5eaace=[];_0x3ce77c[_0x186393('0xd85')][_0x186393('0xf5d')][_0x186393('0x1299')](function(_0x243507){const _0x1c94fc=_0x186393;if(_0x243507['action']==='contactManager'){const _0x48a4b9=_0x2e3ca0()['find'](_0x3ce77c[_0x1c94fc('0xe01')],{'id':Number(_0x243507[_0x1c94fc('0x2790')])});_0x5eaace['push'](_0x48a4b9);}});for(let _0x22a68d=0x0;_0x22a68d<_0x3ce77c[_0x186393('0xe01')][_0x186393('0x1564')];_0x22a68d++){const _0x21c06b=_0x2e3ca0()[_0x186393('0x7a2')](_0x5eaace,{'id':_0x3ce77c[_0x186393('0xe01')][_0x22a68d]['id']});_0x21c06b&&(_0x3ce77c[_0x186393('0xe01')][_0x22a68d][_0x186393('0x319')]=![],_0x585622['push'](_0x3ce77c[_0x186393('0xe01')][_0x22a68d]));}_0x3ce77c[_0x186393('0xe01')]=_0x585622;}else{if(!_0x23697a[_0x186393('0x170')])return _0x23c7e2[_0x186393('0xcf7')][_0x186393('0x1e6e')]({'sectionId':_0x23697a['id']})[_0x186393('0xe53')]['then'](function(_0x546ffa){const _0x329d06=_0x186393,_0x6ba544=_0x2e3ca0()[_0x329d06('0x386')](_0x546ffa[_0x329d06('0xf5d')],function(_0xe3194b){const _0x2c6a58=_0x329d06;return _0x2e3ca0()['find'](_0x3ce77c[_0x2c6a58('0xe01')],{'id':_0xe3194b[_0x2c6a58('0x832')]});});let _0x5525f9=null;_0x5525f9=[],_0x3ce77c['triggerActions'][_0x329d06('0xf5d')][_0x329d06('0x1299')](function(_0xe85f54){const _0x30759a=_0x329d06;if(_0xe85f54['action']==='contactManager'){const _0xd34ce5=_0x2e3ca0()[_0x30759a('0x1c07')](_0x3ce77c[_0x30759a('0xe01')],{'id':Number(_0xe85f54[_0x30759a('0x2790')])});_0x5525f9['push'](_0xd34ce5);}}),!_0x2e3ca0()[_0x329d06('0x173f')](_0x5525f9)&&_0x5525f9[_0x329d06('0x1299')](function(_0x432b04){const _0x59b354=_0x329d06;if(!_0x2e3ca0()['some'](_0x6ba544,['id',_0x432b04['id']])){const _0x5ad13a=_0x2e3ca0()[_0x59b354('0x1c07')](_0x3ce77c[_0x59b354('0xe01')],{'id':_0x432b04['id']});_0x5ad13a[_0x59b354('0x319')]=![],_0x6ba544['push'](_0x5ad13a);}}),_0x3ce77c['lists']=_0x6ba544;});}})['catch'](function(_0x5bdcd5){const _0x489f24=_0xa8c199;_0x49491f[_0x489f24('0x52a')]({'title':_0x5bdcd5[_0x489f24('0x13ee')]?_0x489f24('0x2168')+_0x5bdcd5['status']+_0x489f24('0xbf6')+_0x5bdcd5[_0x489f24('0x24a9')]:_0x489f24('0x11e3'),'msg':_0x5bdcd5[_0x489f24('0x5a5')]?JSON[_0x489f24('0x258a')](_0x5bdcd5[_0x489f24('0x5a5')]):_0x5bdcd5[_0x489f24('0x1ff0')]()});});}function _0x1d09fb(){const _0x47617c=_0x4e4c22;_0x23c7e2[_0x47617c('0x276e')][_0x47617c('0x2267')]({})[_0x47617c('0xe53')][_0x47617c('0x683')](function(_0x107502){const _0x1b231b=_0x47617c;_0x3ce77c[_0x1b231b('0x1b43')]=[],_0x3ce77c[_0x1b231b('0xc4d')]=[];const _0x26b607=_0x2e3ca0()['values'](_0x107502[_0x1b231b('0x24e1')]());for(let _0x330464=0x0;_0x330464<_0x26b607['length'];_0x330464++){if(_0x2e3ca0()[_0x1b231b('0x2292')](_0x3ce77c[_0x1b231b('0x1d8d')],_0x26b607[_0x330464][_0x1b231b('0xa99')]))_0x3ce77c[_0x1b231b('0x1b43')][_0x1b231b('0x1fd0')](_0x26b607[_0x330464]);else{if(_0x2e3ca0()['startsWith'](_0x26b607[_0x330464][_0x1b231b('0xa99')],'cf_')){if(_0x26b607[_0x330464][_0x1b231b('0xbf0')]['type']===_0x1b231b('0x1bcd'))_0x3ce77c[_0x1b231b('0xc4d')][_0x1b231b('0x1fd0')](_0x26b607[_0x330464]);}}}})['catch'](function(_0x20cbf2){const _0x6ac59e=_0x47617c;_0x49491f[_0x6ac59e('0x52a')]({'title':_0x20cbf2[_0x6ac59e('0x13ee')]?_0x6ac59e('0x2168')+_0x20cbf2[_0x6ac59e('0x13ee')]+_0x6ac59e('0xbf6')+_0x20cbf2['statusText']:_0x6ac59e('0x22b6'),'msg':_0x20cbf2['data']?JSON[_0x6ac59e('0x258a')](_0x20cbf2[_0x6ac59e('0x5a5')]):_0x20cbf2[_0x6ac59e('0x1ff0')]()});});}function _0x5220f4(){const _0x273e91=_0x4e4c22;_0x23c7e2[_0x273e91('0x259b')][_0x273e91('0xcb')]({'id':_0x3ce77c[_0x273e91('0x1f0e')][_0x273e91('0x2790')],'ListId':_0x3ce77c[_0x273e91('0x1f0e')][_0x273e91('0x2790')]})['$promise'][_0x273e91('0x683')](function(_0x17fe5d){const _0x279c01=_0x273e91;_0x3ce77c[_0x279c01('0xa33')]=_0x2e3ca0()[_0x279c01('0x25')](_0x17fe5d[_0x279c01('0xf5d')],[_0x279c01('0xcf0'),_0x279c01('0x1bcd')]),_0x3ce77c[_0x279c01('0xa33')]['forEach'](function(_0x1106a7){const _0x5a77a2=_0x279c01;_0x1106a7[_0x5a77a2('0xa99')]=_0x5a77a2('0x1469')+_0x1106a7['id'];});})[_0x273e91('0x130a')](function(_0x24fe97){const _0x1b32a2=_0x273e91;_0x49491f[_0x1b32a2('0x52a')]({'title':_0x24fe97['status']?_0x1b32a2('0x2168')+_0x24fe97[_0x1b32a2('0x13ee')]+'\x20-\x20'+_0x24fe97['statusText']:'SYSTEM:GET_LIST_CUSTOM_FIELDS','msg':_0x24fe97[_0x1b32a2('0x5a5')]?JSON['stringify'](_0x24fe97['data']):_0x24fe97['toString']()});});}function _0x2e398b(){const _0x40b480=_0x4e4c22;_0x46efea[_0x40b480('0x1d32')]()?_0x23c7e2[_0x40b480('0xa8b')][_0x40b480('0x1e6e')]({'fields':_0x40b480('0xa10'),'sort':_0x40b480('0x60a'),'nolimit':_0x40b480('0x26ac')})[_0x40b480('0xe53')]['then'](function(_0x217a17){const _0x5e610d=_0x40b480;_0x3ce77c[_0x5e610d('0x1248')]=_0x217a17[_0x5e610d('0xf5d')]||[];})[_0x40b480('0x130a')](function(_0x8c8245){const _0x456d6d=_0x40b480;_0x49491f[_0x456d6d('0x52a')]({'title':_0x8c8245[_0x456d6d('0x13ee')]?_0x456d6d('0x2168')+_0x8c8245[_0x456d6d('0x13ee')]+_0x456d6d('0xbf6')+_0x8c8245[_0x456d6d('0x24a9')]:_0x456d6d('0xd0e'),'msg':_0x8c8245[_0x456d6d('0x5a5')]?JSON['stringify'](_0x8c8245[_0x456d6d('0x5a5')]):_0x8c8245[_0x456d6d('0x1ff0')]()});}):_0x23c7e2['jscriptyProject'][_0x40b480('0x1e6e')]({'fields':_0x40b480('0xa10'),'sort':_0x40b480('0x60a'),'nolimit':_0x40b480('0x26ac')})[_0x40b480('0xe53')][_0x40b480('0x683')](function(_0x15fe44){const _0x37eabd=_0x40b480;_0x3ce77c['projects']=_0x15fe44[_0x37eabd('0xf5d')]||[];})[_0x40b480('0x683')](function(){const _0x211ecf=_0x40b480;return _0x23c7e2['userProfileSection'][_0x211ecf('0x1e6e')]({'userProfileId':_0x3ce77c[_0x211ecf('0x11ed')][_0x211ecf('0x2f')],'sectionId':0x6a5})[_0x211ecf('0xe53')];})[_0x40b480('0x683')](function(_0x330c58){const _0x4e5d72=_0x40b480,_0x2cd4ba=_0x330c58&&_0x330c58[_0x4e5d72('0xf5d')]?_0x330c58[_0x4e5d72('0xf5d')][0x0]:null;if(!_0x2cd4ba){const _0x1de39b=[],_0x582198=[];_0x3ce77c[_0x4e5d72('0xd85')]['rows']['forEach'](function(_0x530b95){const _0x34d6e9=_0x4e5d72;if(_0x530b95[_0x34d6e9('0x1f0e')]===_0x34d6e9('0x18e6')){const _0x8dd4dc=_0x2e3ca0()[_0x34d6e9('0x1c07')](_0x3ce77c[_0x34d6e9('0x1248')],{'id':Number(_0x530b95[_0x34d6e9('0x2790')])});_0x582198[_0x34d6e9('0x1fd0')](_0x8dd4dc);}});for(let _0x55890c=0x0;_0x55890c<_0x3ce77c[_0x4e5d72('0x1248')]['length'];_0x55890c++){const _0x25928a=_0x2e3ca0()[_0x4e5d72('0x7a2')](_0x582198,{'id':_0x3ce77c[_0x4e5d72('0x1248')][_0x55890c]['id']});_0x25928a&&(_0x3ce77c['projects'][_0x55890c][_0x4e5d72('0x319')]=![],_0x1de39b[_0x4e5d72('0x1fd0')](_0x3ce77c['projects'][_0x55890c]));}_0x3ce77c[_0x4e5d72('0x1248')]=_0x1de39b;}else{if(!_0x2cd4ba['autoAssociation'])return _0x23c7e2['userProfileResource'][_0x4e5d72('0x1e6e')]({'sectionId':_0x2cd4ba['id']})['$promise']['then'](function(_0x4012d9){const _0x121172=_0x4e5d72,_0x3555a1=_0x2e3ca0()['map'](_0x4012d9[_0x121172('0xf5d')],function(_0xba9111){const _0xf4cb8b=_0x121172;return _0x2e3ca0()[_0xf4cb8b('0x1c07')](_0x3ce77c['projects'],{'id':_0xba9111[_0xf4cb8b('0x832')]});});let _0x4e8411=null;_0x4e8411=[],_0x3ce77c['triggerActions'][_0x121172('0xf5d')]['forEach'](function(_0x5edec0){const _0x2a3192=_0x121172;if(_0x5edec0[_0x2a3192('0x1f0e')]===_0x2a3192('0x18e6')){const _0x1f7b2f=_0x2e3ca0()[_0x2a3192('0x1c07')](_0x3ce77c[_0x2a3192('0x1248')],{'id':Number(_0x5edec0[_0x2a3192('0x2790')])});_0x4e8411[_0x2a3192('0x1fd0')](_0x1f7b2f);}}),!_0x2e3ca0()[_0x121172('0x173f')](_0x4e8411)&&_0x4e8411[_0x121172('0x1299')](function(_0x2f770e){const _0x35450e=_0x121172;if(!_0x2e3ca0()['some'](_0x3555a1,['id',_0x2f770e['id']])){const _0x4c7512=_0x2e3ca0()[_0x35450e('0x1c07')](_0x3ce77c[_0x35450e('0x1248')],{'id':_0x2f770e['id']});_0x4c7512[_0x35450e('0x319')]=![],_0x3555a1[_0x35450e('0x1fd0')](_0x4c7512);}}),_0x3ce77c['projects']=_0x3555a1;});}})[_0x40b480('0x130a')](function(_0x10b199){const _0x4a07c9=_0x40b480;_0x49491f['error']({'title':_0x10b199['status']?_0x4a07c9('0x2168')+_0x10b199['status']+_0x4a07c9('0xbf6')+_0x10b199[_0x4a07c9('0x24a9')]:_0x4a07c9('0x616'),'msg':_0x10b199[_0x4a07c9('0x5a5')]?JSON[_0x4a07c9('0x258a')](_0x10b199[_0x4a07c9('0x5a5')]):_0x10b199[_0x4a07c9('0x1ff0')]()});});}function _0x1aae72(){const _0x386547=_0x4e4c22;_0x46efea[_0x386547('0x1d32')]()?_0x23c7e2['template']['get']({'fields':_0x386547('0xa10'),'sort':'id','nolimit':'true'})[_0x386547('0xe53')][_0x386547('0x683')](function(_0x34e661){const _0xd1f4d3=_0x386547;_0x3ce77c[_0xd1f4d3('0x84b')]=_0x34e661[_0xd1f4d3('0xf5d')]||[];})['catch'](function(_0x4bffa6){const _0x47024f=_0x386547;_0x49491f[_0x47024f('0x52a')]({'title':_0x4bffa6['status']?_0x47024f('0x2168')+_0x4bffa6[_0x47024f('0x13ee')]+_0x47024f('0xbf6')+_0x4bffa6['statusText']:_0x47024f('0xab7'),'msg':_0x4bffa6[_0x47024f('0x5a5')]?JSON[_0x47024f('0x258a')](_0x4bffa6['data']):_0x4bffa6[_0x47024f('0x1ff0')]()});}):_0x23c7e2['template'][_0x386547('0x1e6e')]({'fields':_0x386547('0xa10'),'sort':'id','nolimit':'true'})['$promise']['then'](function(_0x9edc95){const _0x2796b2=_0x386547;_0x3ce77c[_0x2796b2('0x84b')]=_0x9edc95[_0x2796b2('0xf5d')]||[];})['then'](function(){const _0xe8f851=_0x386547;return _0x23c7e2[_0xe8f851('0x22df')][_0xe8f851('0x1e6e')]({'userProfileId':_0x3ce77c[_0xe8f851('0x11ed')]['userProfileId'],'sectionId':0x3f1})['$promise'];})[_0x386547('0x683')](function(_0x1ed5af){const _0x70a9c0=_0x386547,_0x4a97e5=_0x1ed5af&&_0x1ed5af[_0x70a9c0('0xf5d')]?_0x1ed5af['rows'][0x0]:null;if(!_0x4a97e5){const _0x17b1da=[],_0x43fca6=[];_0x3ce77c[_0x70a9c0('0xd85')]['rows'][_0x70a9c0('0x1299')](function(_0x155dfa){const _0x5855e9=_0x70a9c0;if(_0x2e3ca0()[_0x5855e9('0x2292')]([_0x5855e9('0x1a00'),_0x5855e9('0x47d')],_0x155dfa[_0x5855e9('0x1f0e')])){const _0x60a55b=_0x2e3ca0()[_0x5855e9('0x1c07')](_0x3ce77c['templates'],{'id':Number(_0x155dfa[_0x5855e9('0x1d30')])});_0x43fca6[_0x5855e9('0x1fd0')](_0x60a55b);}});for(let _0x1abc09=0x0;_0x1abc09<_0x3ce77c['templates'][_0x70a9c0('0x1564')];_0x1abc09++){const _0x2ecef3=_0x2e3ca0()[_0x70a9c0('0x7a2')](_0x43fca6,{'id':_0x3ce77c[_0x70a9c0('0x84b')][_0x1abc09]['id']});_0x2ecef3&&(_0x3ce77c[_0x70a9c0('0x84b')][_0x1abc09][_0x70a9c0('0x319')]=![],_0x17b1da['push'](_0x3ce77c['templates'][_0x1abc09]));}_0x3ce77c[_0x70a9c0('0x84b')]=_0x17b1da;}else{if(!_0x4a97e5[_0x70a9c0('0x170')])return _0x23c7e2[_0x70a9c0('0xcf7')][_0x70a9c0('0x1e6e')]({'sectionId':_0x4a97e5['id']})[_0x70a9c0('0xe53')][_0x70a9c0('0x683')](function(_0x15223a){const _0x15eec1=_0x70a9c0,_0x27c53d=_0x2e3ca0()[_0x15eec1('0x386')](_0x15223a[_0x15eec1('0xf5d')],function(_0x56ab38){const _0x5920de=_0x15eec1;return _0x2e3ca0()[_0x5920de('0x1c07')](_0x3ce77c[_0x5920de('0x84b')],{'id':_0x56ab38[_0x5920de('0x832')]});});let _0xe144a1=null;_0xe144a1=[],_0x3ce77c[_0x15eec1('0xd85')][_0x15eec1('0xf5d')]['forEach'](function(_0x56fc1a){const _0x1d8ed9=_0x15eec1;if(_0x2e3ca0()[_0x1d8ed9('0x2292')](['motionbar',_0x1d8ed9('0x47d')],_0x56fc1a[_0x1d8ed9('0x1f0e')])){const _0x754100=_0x2e3ca0()['find'](_0x3ce77c[_0x1d8ed9('0x84b')],{'id':Number(_0x56fc1a[_0x1d8ed9('0x1d30')])});_0xe144a1[_0x1d8ed9('0x1fd0')](_0x754100);}}),!_0x2e3ca0()[_0x15eec1('0x173f')](_0xe144a1)&&_0xe144a1[_0x15eec1('0x1299')](function(_0x271944){const _0x7c9f3e=_0x15eec1;if(!_0x2e3ca0()[_0x7c9f3e('0x7a2')](_0x27c53d,['id',_0x271944['id']])){const _0x565eb1=_0x2e3ca0()[_0x7c9f3e('0x1c07')](_0x3ce77c[_0x7c9f3e('0x84b')],{'id':_0x271944['id']});_0x565eb1[_0x7c9f3e('0x319')]=![],_0x27c53d[_0x7c9f3e('0x1fd0')](_0x565eb1);}}),_0x3ce77c[_0x15eec1('0x84b')]=_0x27c53d;});}})[_0x386547('0x130a')](function(_0x386c2b){const _0x3c32b1=_0x386547;_0x49491f[_0x3c32b1('0x52a')]({'title':_0x386c2b['status']?_0x3c32b1('0x2168')+_0x386c2b[_0x3c32b1('0x13ee')]+_0x3c32b1('0xbf6')+_0x386c2b[_0x3c32b1('0x24a9')]:'SYSTEM:GET_TEMPLATES','msg':_0x386c2b[_0x3c32b1('0x5a5')]?JSON[_0x3c32b1('0x258a')](_0x386c2b[_0x3c32b1('0x5a5')]):_0x386c2b[_0x3c32b1('0x1ff0')]()});});}function _0x34d0c4(){const _0x2b3d1e=_0x4e4c22;switch(_0x3ce77c[_0x2b3d1e('0x1f0e')]['data1']){case'zendesk':return _0x3ce77c[_0x2b3d1e('0x1b23')][0x515];case'salesforce':return _0x3ce77c[_0x2b3d1e('0x1b23')][0x516];case'sugarcrm':return _0x3ce77c[_0x2b3d1e('0x1b23')][0x519];case _0x2b3d1e('0x6f2'):return _0x3ce77c[_0x2b3d1e('0x1b23')][0x517];case _0x2b3d1e('0x14da'):return _0x3ce77c[_0x2b3d1e('0x1b23')][0x51a];case _0x2b3d1e('0x2569'):return _0x3ce77c[_0x2b3d1e('0x1b23')][0x51b];case _0x2b3d1e('0x144c'):return _0x3ce77c[_0x2b3d1e('0x1b23')][0x51c];case'dynamics365':return _0x3ce77c['hasSectionPermissions'][0x51d];case _0x2b3d1e('0xb79'):return _0x3ce77c[_0x2b3d1e('0x1b23')][0x51e];case _0x2b3d1e('0x187b'):return _0x3ce77c[_0x2b3d1e('0x1b23')][0x51f];}}function _0x3bb59a(){const _0x3e5b31=_0x4e4c22;_0x3ce77c['action'][_0x3e5b31('0x2790')]=undefined,_0x3ce77c['action'][_0x3e5b31('0x1d30')]=undefined,_0x3ce77c['action'][_0x3e5b31('0x21be')]=undefined,_0x3ce77c[_0x3e5b31('0x1f0e')][_0x3e5b31('0x18ac')]=undefined,_0x3ce77c[_0x3e5b31('0x1f0e')][_0x3e5b31('0xd21')]=_0x3ce77c[_0x3e5b31('0x1f0e')]['action']===_0x3e5b31('0x1e9f')?0x5:undefined;}function _0x534b60(){const _0x201460=_0x4e4c22;switch(_0x3ce77c[_0x201460('0x1f0e')][_0x201460('0x1f0e')]){case _0x201460('0x869'):if(!_0x3ce77c[_0x201460('0xe01')])_0x3f59c8();if(!_0x3ce77c[_0x201460('0x1b43')])_0x1d09fb();_0x3ce77c[_0x201460('0x1f0e')][_0x201460('0x21be')]=_0x3ce77c[_0x201460('0x1f0e')]['data3']?_0x3ce77c[_0x201460('0x1f0e')]['data3'][_0x201460('0x1fc5')](','):['phone'];if(_0x3ce77c[_0x201460('0x1f0e')][_0x201460('0x1d30')]==='1'&&!_0x3ce77c['action'][_0x201460('0x18ac')])_0x3ce77c[_0x201460('0x1f0e')][_0x201460('0x18ac')]='phone';break;case _0x201460('0x18e6'):if(!_0x3ce77c['projects'])_0x2e398b();break;case'urlForward':if(!_0x3ce77c[_0x201460('0x1f0e')][_0x201460('0xd21')])_0x3ce77c[_0x201460('0x1f0e')][_0x201460('0xd21')]=0x5;break;}}function _0x186ace(){_0x3bb59a(),_0x534b60();}function _0x316870(){const _0x41f8bc=_0x4e4c22;_0x3ce77c[_0x41f8bc('0x1f0e')][_0x41f8bc('0x1d30')]=undefined,_0x3ce77c[_0x41f8bc('0x1f0e')][_0x41f8bc('0x21be')]=undefined,_0x3ce77c['action'][_0x41f8bc('0x1e5b')]=_0x3ce77c[_0x41f8bc('0x622')]?![]:!_0x34d0c4();const _0x1968be=_0x41f8bc('0x1d17')+_0x2e3ca0()[_0x41f8bc('0x21ab')](_0x3ce77c[_0x41f8bc('0x1f0e')]['data1'])+_0x41f8bc('0xa78');_0x23c7e2[_0x1968be][_0x41f8bc('0x1e6e')]({'fields':_0x41f8bc('0xa10'),'sort':'id','nolimit':'true'})['$promise']['then'](function(_0x44b36c){const _0x430bb1=_0x41f8bc;_0x3ce77c[_0x430bb1('0x1c31')]=_0x44b36c[_0x430bb1('0xf5d')]||[];})[_0x41f8bc('0x130a')](function(_0x51edd9){const _0x1c8756=_0x41f8bc;_0x49491f[_0x1c8756('0x52a')]({'title':_0x51edd9[_0x1c8756('0x13ee')]?'API:'+_0x51edd9[_0x1c8756('0x13ee')]+_0x1c8756('0xbf6')+_0x51edd9[_0x1c8756('0x24a9')]:_0x1c8756('0xf4a')+_0x3ce77c[_0x1c8756('0x1f0e')]['data1'][_0x1c8756('0x80')]()+_0x1c8756('0x597'),'msg':_0x51edd9['data']?JSON[_0x1c8756('0x258a')](_0x51edd9[_0x1c8756('0x5a5')]):_0x51edd9[_0x1c8756('0x1ff0')]()});});}function _0x18c355(){_0x5220f4();}function _0x4d0704(){const _0x2b0e71=_0x4e4c22;if(_0x3ce77c[_0x2b0e71('0x1f0e')][_0x2b0e71('0x2790')]==='0'&&!_0x3ce77c[_0x2b0e71('0x84b')])_0x1aae72();}function _0x906eb6(){const _0x37ae0c=_0x4e4c22;if(_0x3ce77c[_0x37ae0c('0x1f0e')]['data2']==='0')_0x3ce77c[_0x37ae0c('0x1f0e')][_0x37ae0c('0x18ac')]=undefined;if(!_0x3ce77c[_0x37ae0c('0x1f0e')]['data4']&&_0x3ce77c[_0x37ae0c('0x1f0e')][_0x37ae0c('0x1d30')]==='1')_0x3ce77c[_0x37ae0c('0x1f0e')][_0x37ae0c('0x18ac')]=_0x37ae0c('0xd31');}function _0x18c279(){const _0x4b568b=_0x4e4c22;_0x3ce77c[_0x4b568b('0x1f0e')][_0x4b568b('0x21be')]=undefined;const _0x53fe19=_0x4b568b('0x1d17')+_0x2e3ca0()[_0x4b568b('0x21ab')](_0x3ce77c[_0x4b568b('0x1f0e')][_0x4b568b('0x2790')])+_0x4b568b('0x1ccb');_0x23c7e2[_0x53fe19][_0x4b568b('0x1e6e')]({'fields':_0x4b568b('0x53a'),'sort':'id','nolimit':_0x4b568b('0x26ac')})['$promise'][_0x4b568b('0x683')](function(_0x20b010){const _0x332976=_0x4b568b;_0x3ce77c[_0x332976('0x1573')]=_0x20b010['rows']||[];})[_0x4b568b('0x130a')](function(_0x385d5a){const _0x2b11b7=_0x4b568b;_0x49491f[_0x2b11b7('0x52a')]({'title':_0x385d5a[_0x2b11b7('0x13ee')]?'API:'+_0x385d5a[_0x2b11b7('0x13ee')]+_0x2b11b7('0xbf6')+_0x385d5a[_0x2b11b7('0x24a9')]:_0x2b11b7('0xf4a')+_0x3ce77c['action'][_0x2b11b7('0x2790')]['toUpperCase']()+'CONFIGURATIONS','msg':_0x385d5a['data']?JSON['stringify'](_0x385d5a[_0x2b11b7('0x5a5')]):_0x385d5a[_0x2b11b7('0x1ff0')]()});});}function _0x3224ed(){const _0x5429da=_0x4e4c22,_0x836d23=angular[_0x5429da('0x1a86')](_0x3ce77c['action']);if(_0x2e3ca0()[_0x5429da('0x94b')](_0x836d23['data3']))_0x836d23[_0x5429da('0x21be')]=_0x3ce77c['action'][_0x5429da('0x21be')][_0x5429da('0x1630')](',');return _0x836d23;}function _0x2fe18f(){const _0x3cabf0=_0x4e4c22;_0x3ce77c['errors']=[];const _0x1bf24b=_0x3224ed();_0x23c7e2[_0x3cabf0('0x25e2')][_0x3cabf0('0x27b3')]({'id':_0x3ad3e3[_0x3cabf0('0x7f2')]['id']},_0x1bf24b)['$promise'][_0x3cabf0('0x683')](function(_0x35caef){const _0x3414ab=_0x3cabf0;_0x3ce77c[_0x3414ab('0xa0b')]['unshift'](_0x35caef[_0x3414ab('0x24e1')]()),_0x49491f[_0x3414ab('0x53')]({'title':_0x511f4e['instant']('TOOLS.NOTIFICATIONS.ACTION_CREATED_SUCCESS_TITLE')}),_0x16b84a(_0x3ce77c[_0x3414ab('0xa0b')]);})[_0x3cabf0('0x130a')](function(_0x7c4fe9){const _0x4dfec9=_0x3cabf0;if(_0x7c4fe9['data']&&_0x7c4fe9[_0x4dfec9('0x5a5')][_0x4dfec9('0x17f')]&&_0x7c4fe9[_0x4dfec9('0x5a5')][_0x4dfec9('0x17f')][_0x4dfec9('0x1564')]){_0x3ce77c[_0x4dfec9('0x17f')]=_0x7c4fe9['data'][_0x4dfec9('0x17f')]||[{'message':_0x7c4fe9[_0x4dfec9('0x1ff0')](),'type':_0x4dfec9('0x123e')}];for(let _0x533700=0x0;_0x533700<_0x7c4fe9['data']['errors'][_0x4dfec9('0x1564')];_0x533700+=0x1){_0x49491f[_0x4dfec9('0x52a')]({'title':_0x7c4fe9['data'][_0x4dfec9('0x17f')][_0x533700][_0x4dfec9('0xcf0')],'msg':_0x7c4fe9[_0x4dfec9('0x5a5')][_0x4dfec9('0x17f')][_0x533700][_0x4dfec9('0x8c2')]});}}else _0x49491f['error']({'title':_0x7c4fe9['status']?_0x4dfec9('0x2168')+_0x7c4fe9[_0x4dfec9('0x13ee')]+_0x4dfec9('0xbf6')+_0x7c4fe9[_0x4dfec9('0x24a9')]:_0x4dfec9('0x123e'),'msg':_0x7c4fe9[_0x4dfec9('0x5a5')]?JSON[_0x4dfec9('0x258a')](_0x7c4fe9[_0x4dfec9('0x5a5')]['message']):_0x7c4fe9[_0x4dfec9('0x1ff0')]()});});}function _0x449576(){const _0x3854f9=_0x4e4c22;_0x3ce77c[_0x3854f9('0x17f')]=[];const _0x2b8036=_0x3224ed();_0x23c7e2[_0x3854f9('0x1f0e')][_0x3854f9('0x2480')]({'id':_0x2b8036['id']},_0x2b8036)[_0x3854f9('0xe53')][_0x3854f9('0x683')](function(){const _0x34df32=_0x3854f9;_0x3ce77c[_0x34df32('0xa0b')]=_0x2e3ca0()[_0x34df32('0x386')](_0x3ce77c[_0x34df32('0xa0b')],function(_0x49684a){if(_0x49684a['id']===_0x2b8036['id'])return _0x2b8036;else return _0x49684a;}),_0x49491f[_0x34df32('0x53')]({'title':_0x511f4e['instant'](_0x34df32('0x1961'))}),_0x16b84a(_0x3ce77c[_0x34df32('0xa0b')]);})[_0x3854f9('0x130a')](function(_0x54b9a4){const _0x250cba=_0x3854f9;if(_0x54b9a4[_0x250cba('0x5a5')]&&_0x54b9a4[_0x250cba('0x5a5')]['errors']&&_0x54b9a4[_0x250cba('0x5a5')][_0x250cba('0x17f')][_0x250cba('0x1564')]){_0x3ce77c['errors']=_0x54b9a4[_0x250cba('0x5a5')][_0x250cba('0x17f')]||[{'message':_0x54b9a4['toString'](),'type':'api.action.update'}];for(let _0x21d5fc=0x0;_0x21d5fc<_0x54b9a4[_0x250cba('0x5a5')][_0x250cba('0x17f')]['length'];_0x21d5fc++){_0x49491f[_0x250cba('0x52a')]({'title':_0x54b9a4['data']['errors'][_0x21d5fc][_0x250cba('0xcf0')],'msg':_0x54b9a4[_0x250cba('0x5a5')][_0x250cba('0x17f')][_0x21d5fc]['message']});}}else _0x49491f[_0x250cba('0x52a')]({'title':_0x54b9a4[_0x250cba('0x13ee')]?_0x250cba('0x2168')+_0x54b9a4['status']+_0x250cba('0xbf6')+_0x54b9a4[_0x250cba('0x24a9')]:'api.action.update','msg':_0x54b9a4[_0x250cba('0x5a5')]?JSON[_0x250cba('0x258a')](_0x54b9a4[_0x250cba('0x5a5')]['message']):_0x54b9a4['toString']()});});}function _0x37e499(_0x3b1989){const _0x24c0bc=_0x4e4c22;_0x3ce77c['errors']=[];const _0x3dd278=_0x53eed3[_0x24c0bc('0x1c6f')]({'skipHide':!![]})[_0x24c0bc('0xf28')](_0x511f4e[_0x24c0bc('0x2728')]('TOOLS.NOTIFICATIONS.ACTION_DELETE_TITLE'))[_0x24c0bc('0x1040')](_0x24c0bc('0xf5'))['ok'](_0x511f4e[_0x24c0bc('0x2728')]('TOOLS.DELETE'))[_0x24c0bc('0x19fb')](_0x511f4e['instant'](_0x24c0bc('0x9a1')))[_0x24c0bc('0xe42')](_0x3b1989);_0x53eed3[_0x24c0bc('0x1d4')](_0x3dd278)[_0x24c0bc('0x683')](function(){const _0x505786=_0x24c0bc;_0x23c7e2[_0x505786('0x1f0e')]['delete']({'id':_0x3ce77c[_0x505786('0x1f0e')]['id']})['$promise']['then'](function(){const _0x3f895a=_0x505786;_0x3ce77c[_0x3f895a('0xa0b')]=_0x2e3ca0()[_0x3f895a('0x25')](_0x3ce77c[_0x3f895a('0xa0b')],function(_0x168ef6){const _0x3db977=_0x3f895a;return _0x168ef6['id']!==_0x3ce77c[_0x3db977('0x1f0e')]['id'];}),_0x49491f[_0x3f895a('0x53')]({'title':_0x511f4e['instant'](_0x3f895a('0x7e1'))}),_0x16b84a(_0x3ce77c[_0x3f895a('0xa0b')]);})[_0x505786('0x130a')](function(_0x224f8f){const _0x3f7c3a=_0x505786;if(_0x224f8f['data']&&_0x224f8f[_0x3f7c3a('0x5a5')][_0x3f7c3a('0x17f')]&&_0x224f8f['data'][_0x3f7c3a('0x17f')]['length']){_0x3ce77c['errors']=_0x224f8f[_0x3f7c3a('0x5a5')][_0x3f7c3a('0x17f')]||[{'message':_0x224f8f[_0x3f7c3a('0x1ff0')](),'type':_0x3f7c3a('0x1ffb')}];for(let _0xc66033=0x0;_0xc66033<_0x224f8f[_0x3f7c3a('0x5a5')][_0x3f7c3a('0x17f')][_0x3f7c3a('0x1564')];_0xc66033++){_0x49491f[_0x3f7c3a('0x52a')]({'title':_0x224f8f[_0x3f7c3a('0x5a5')]['errors'][_0xc66033]['type'],'msg':_0x224f8f[_0x3f7c3a('0x5a5')][_0x3f7c3a('0x17f')][_0xc66033]['message']});}}else _0x49491f[_0x3f7c3a('0x52a')]({'title':_0x224f8f[_0x3f7c3a('0x13ee')]?'API:'+_0x224f8f[_0x3f7c3a('0x13ee')]+'\x20-\x20'+_0x224f8f[_0x3f7c3a('0x24a9')]:_0x3f7c3a('0x1ffb'),'msg':_0x224f8f['data']?JSON[_0x3f7c3a('0x258a')](_0x224f8f[_0x3f7c3a('0x5a5')][_0x3f7c3a('0x8c2')]):_0x224f8f[_0x3f7c3a('0x8c2')]||_0x224f8f[_0x3f7c3a('0x1ff0')]()});});},function(){});}function _0x16b84a(_0x57345b){const _0x30ef2c=_0x4e4c22;_0x53eed3[_0x30ef2c('0x1715')](_0x57345b);}}const _0x4f2410=_0x15f2d7,_0x2c368d=_0x180212['p']+_0x189033('0xd56');_0x2d8d63['$inject']=['$scope','$q',_0x189033('0x1d08'),_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x2d8d63(_0x2d49be,_0x11ea0f,_0x411490,_0x23953c,_0x3f0baa,_0x12578b,_0x3e4a8a,_0x5e461b,_0x39a347){const _0x38874b=_0x189033,_0x1456f1=this;_0x1456f1[_0x38874b('0x11ed')]=_0x39a347[_0x38874b('0x20b2')](),_0x1456f1[_0x38874b('0x25e2')]={},_0x1456f1[_0x38874b('0x1a5d')]={'count':0x0,'rows':[]},_0x1456f1[_0x38874b('0x245b')]=[],_0x1456f1[_0x38874b('0x23a2')]={'fields':_0x38874b('0x1e80'),'limit':0xa,'page':0x1},_0x1456f1[_0x38874b('0x189a')]={'queue':_0x38874b('0x1fa'),'lastevent':'Call_Status','routeId':_0x38874b('0x19c3'),'agent':_0x38874b('0x62c'),'account':_0x38874b('0xa78'),'interaction':'Interaction','message':_0x38874b('0x205e')},_0x1456f1[_0x38874b('0x17d7')]={'abandoned':_0x38874b('0x1919'),'timeout':_0x38874b('0xa09'),'complete':_0x38874b('0x614'),'rejected':'Reject','called':_0x38874b('0x1a67'),'connect':'Answer','nosuchnumber':_0x38874b('0x1255'),'busy':'Busy','noanswer':_0x38874b('0x25be'),'congestion':_0x38874b('0x2094'),'agentreject':_0x38874b('0x3cf')},_0x1456f1[_0x38874b('0x1f48')]={'in':_0x38874b('0x5a6'),'out':_0x38874b('0x17aa'),'accept':'Accepted','reject':_0x38874b('0x22c4')},_0x1456f1[_0x38874b('0x1dd2')]=_0x5547f4,_0x1456f1[_0x38874b('0x53')]=_0x4e3c22,_0x1456f1[_0x38874b('0x68b')]=_0x47afa3,_0x1456f1['createOrEditTriggerAllCondition']=_0x5f15d5,_0x1456f1['exportSelectedTriggerAllConditions']=_0x563002,_0x1456f1[_0x38874b('0x26eb')]=_0x556e53,_0x1456f1[_0x38874b('0x217b')]=_0x15ba40;function _0x5547f4(_0x3c22e8,_0x3f66c8){const _0x5a3d74=_0x38874b;_0x1456f1[_0x5a3d74('0x25e2')]=_0x3c22e8,_0x1456f1[_0x5a3d74('0x1134')]=typeof _0x3f66c8!==_0x5a3d74('0x1867')?_0x3f66c8:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1456f1[_0x5a3d74('0x23a2')]['TriggerAllId']=_0x1456f1['trigger']['id'],_0x1456f1[_0x5a3d74('0x23a2')]['id']=_0x1456f1[_0x5a3d74('0x25e2')]['id'],_0x47afa3();}function _0xf83a34(){const _0x2ac8d8=_0x38874b,_0x1a3d92=_0x1456f1['trigger']['channel'],_0x370bd9=_0x1456f1[_0x2ac8d8('0x25e2')]['channel']+_0x1456f1[_0x2ac8d8('0x25e2')][_0x2ac8d8('0xdd6')]==='chat'?_0x2ac8d8('0x25e7'):'Accounts',_0x20b371=_0x1456f1[_0x2ac8d8('0x25e2')]['channel']+(_0x1456f1[_0x2ac8d8('0x25e2')][_0x2ac8d8('0xdd6')]===_0x2ac8d8('0x24e')?_0x2ac8d8('0xe4c'):'Account');let _0x4775ab;switch(_0x1456f1[_0x2ac8d8('0x25e2')]['channel']){case'chat':_0x4775ab=0x1f6;break;case _0x2ac8d8('0x23e9'):_0x4775ab=0x386;break;case'mail':_0x4775ab=0x25a;break;case _0x2ac8d8('0x1261'):_0x4775ab=0x322;break;case'sms':_0x4775ab=0x2be;break;case'whatsapp':_0x4775ab=0x836;break;}_0x39a347['isAdmin']()?_0x5e461b[_0x20b371]['get']({'fields':_0x2ac8d8('0xa10'),'sort':'id','nolimit':_0x2ac8d8('0x26ac')})[_0x2ac8d8('0xe53')]['then'](function(_0x1fadfd){const _0x9bdb29=_0x2ac8d8;_0x1456f1[_0x370bd9]=_0x1fadfd[_0x9bdb29('0xf5d')]||[];})['catch'](function(_0x340c6b){const _0xf44e50=_0x2ac8d8;_0x3e4a8a['error']({'title':_0x340c6b[_0xf44e50('0x13ee')]?_0xf44e50('0x2168')+_0x340c6b[_0xf44e50('0x13ee')]+_0xf44e50('0xbf6')+_0x340c6b[_0xf44e50('0x24a9')]:'SYSTEM:GET_'+_0x1a3d92[_0xf44e50('0x80')]()+_0x1a3d92===_0xf44e50('0x24e')?_0xf44e50('0x1327'):_0xf44e50('0x597'),'msg':_0x340c6b['data']?JSON['stringify'](_0x340c6b[_0xf44e50('0x5a5')]):_0x340c6b['toString']()});}):_0x5e461b[_0x20b371][_0x2ac8d8('0x1e6e')]({'fields':_0x2ac8d8('0xa10'),'sort':'id','nolimit':'true'})[_0x2ac8d8('0xe53')][_0x2ac8d8('0x683')](function(_0x5d2b77){const _0xcfb609=_0x2ac8d8;_0x1456f1[_0x370bd9]=_0x5d2b77[_0xcfb609('0xf5d')]||[];})[_0x2ac8d8('0x683')](function(){const _0x50c604=_0x2ac8d8;return _0x5e461b['userProfileSection']['get']({'userProfileId':_0x1456f1[_0x50c604('0x11ed')]['userProfileId'],'sectionId':_0x4775ab})[_0x50c604('0xe53')];})['then'](function(_0x3c5bc9){const _0x166b91=_0x2ac8d8,_0x39b76c=_0x3c5bc9&&_0x3c5bc9[_0x166b91('0xf5d')]?_0x3c5bc9[_0x166b91('0xf5d')][0x0]:null;if(!_0x39b76c){const _0x3ba8c5=[],_0x38308f=[];_0x1456f1[_0x166b91('0x1a5d')][_0x166b91('0xf5d')][_0x166b91('0x1299')](function(_0x1af94a){const _0x4741d9=_0x166b91;if(_0x1af94a['field']===_0x4741d9('0x1d2f')){const _0x267205=_0x2e3ca0()[_0x4741d9('0x1c07')](_0x1456f1[_0x370bd9],{'id':Number(_0x1af94a['value'])});_0x38308f[_0x4741d9('0x1fd0')](_0x267205);}});for(let _0x4b3dd0=0x0;_0x4b3dd0<_0x1456f1[_0x370bd9][_0x166b91('0x1564')];_0x4b3dd0++){const _0x3c59ba=_0x2e3ca0()[_0x166b91('0x7a2')](_0x38308f,{'id':_0x1456f1[_0x370bd9][_0x4b3dd0]['id']});_0x3c59ba&&(_0x1456f1[_0x370bd9][_0x4b3dd0][_0x166b91('0x319')]=![],_0x3ba8c5['push'](_0x1456f1[_0x370bd9][_0x4b3dd0]));}_0x1456f1[_0x370bd9]=_0x3ba8c5;}else{if(!_0x39b76c['autoAssociation'])return _0x5e461b[_0x166b91('0xcf7')][_0x166b91('0x1e6e')]({'sectionId':_0x39b76c['id']})[_0x166b91('0xe53')][_0x166b91('0x683')](function(_0x457855){const _0x5db486=_0x166b91,_0x630c2f=_0x2e3ca0()['map'](_0x457855[_0x5db486('0xf5d')],function(_0x3d0534){const _0x42fb44=_0x5db486;return _0x2e3ca0()[_0x42fb44('0x1c07')](_0x1456f1[_0x370bd9],{'id':_0x3d0534[_0x42fb44('0x832')]});});let _0x37fcde=null;_0x37fcde=[],_0x1456f1['triggerAllConditions'][_0x5db486('0xf5d')][_0x5db486('0x1299')](function(_0x4aba1c){const _0xbe738c=_0x5db486;if(_0x4aba1c[_0xbe738c('0x2013')]===_0xbe738c('0x1d2f')){const _0x31921a=_0x2e3ca0()[_0xbe738c('0x1c07')](_0x1456f1[_0x370bd9],{'id':Number(_0x4aba1c['value'])});_0x37fcde[_0xbe738c('0x1fd0')](_0x31921a);}}),!_0x2e3ca0()['isEmpty'](_0x37fcde)&&_0x37fcde['forEach'](function(_0x5772b2){const _0x35f691=_0x5db486;if(!_0x2e3ca0()['some'](_0x630c2f,['id',_0x5772b2['id']])){const _0x148362=_0x2e3ca0()[_0x35f691('0x1c07')](_0x1456f1[_0x370bd9],{'id':_0x5772b2['id']});_0x148362[_0x35f691('0x319')]=![],_0x630c2f[_0x35f691('0x1fd0')](_0x148362);}}),_0x1456f1[_0x370bd9]=_0x630c2f;});}})['catch'](function(_0x57445c){const _0x6d53cc=_0x2ac8d8;_0x3e4a8a[_0x6d53cc('0x52a')]({'title':_0x57445c[_0x6d53cc('0x13ee')]?_0x6d53cc('0x2168')+_0x57445c[_0x6d53cc('0x13ee')]+_0x6d53cc('0xbf6')+_0x57445c['statusText']:_0x6d53cc('0xf4a')+_0x1a3d92[_0x6d53cc('0x80')]()+_0x1a3d92==='chat'?'WEBSITES':_0x6d53cc('0x597'),'msg':_0x57445c[_0x6d53cc('0x5a5')]?JSON[_0x6d53cc('0x258a')](_0x57445c[_0x6d53cc('0x5a5')]):_0x57445c['toString']()});});}function _0x4fbe2b(){const _0x5e72f1=_0x38874b,_0x1104a0=[{'id':0x191,'type':_0x5e72f1('0x1535')},{'id':0x5dd,'type':_0x5e72f1('0x17cd')}];let _0x133637=null;_0x39a347[_0x5e72f1('0x1d32')]()?_0x5e461b[_0x5e72f1('0x204c')][_0x5e72f1('0x1e6e')]({'fields':'id,name,type','sort':_0x5e72f1('0x60a'),'nolimit':_0x5e72f1('0x26ac')})['$promise'][_0x5e72f1('0x683')](function(_0x2962a0){const _0x2734d7=_0x5e72f1;_0x1456f1[_0x2734d7('0x2da')]=_0x2962a0[_0x2734d7('0xf5d')]||[];})[_0x5e72f1('0x130a')](function(_0x3e46eb){const _0x30fd0e=_0x5e72f1;_0x3e4a8a[_0x30fd0e('0x52a')]({'title':_0x3e46eb[_0x30fd0e('0x13ee')]?'API:'+_0x3e46eb['status']+'\x20-\x20'+_0x3e46eb[_0x30fd0e('0x24a9')]:_0x30fd0e('0x15f3'),'msg':_0x3e46eb[_0x30fd0e('0x5a5')]?JSON[_0x30fd0e('0x258a')](_0x3e46eb['data']):_0x3e46eb['toString']()});}):_0x5e461b[_0x5e72f1('0x204c')][_0x5e72f1('0x1e6e')]({'fields':_0x5e72f1('0x2035'),'sort':_0x5e72f1('0x60a'),'nolimit':'true'})[_0x5e72f1('0xe53')][_0x5e72f1('0x683')](function(_0x3e81eb){const _0x10b9fc=_0x5e72f1;_0x133637=_0x3e81eb[_0x10b9fc('0xf5d')]||[];})[_0x5e72f1('0x683')](function(){const _0x1c8e89=_0x5e72f1,_0x4c08db=[];for(let _0x24b90f=0x0;_0x24b90f<_0x1104a0[_0x1c8e89('0x1564')];_0x24b90f++){_0x4c08db['push'](_0x5e461b[_0x1c8e89('0x22df')][_0x1c8e89('0x1e6e')]({'userProfileId':_0x1456f1[_0x1c8e89('0x11ed')][_0x1c8e89('0x2f')],'sectionId':_0x1104a0[_0x24b90f]['id']})[_0x1c8e89('0xe53')]);}return _0x11ea0f['all'](_0x4c08db);})[_0x5e72f1('0x683')](function(_0x1cc3df){const _0x51f3dc=_0x5e72f1,_0x265bc9=_0x2e3ca0()[_0x51f3dc('0x386')](_0x1cc3df,function(_0x3e2c81){const _0x70661=_0x51f3dc;return _0x3e2c81&&_0x3e2c81['rows']?_0x3e2c81[_0x70661('0xf5d')][0x0]:null;}),_0x48c578=[];for(let _0x102002=0x0;_0x102002<_0x1104a0[_0x51f3dc('0x1564')];_0x102002++){const _0x5cc44d=_0x2e3ca0()[_0x51f3dc('0x1c07')](_0x265bc9,[_0x51f3dc('0x21c0'),_0x1104a0[_0x102002]['id']]);if(_0x5cc44d){if(!_0x5cc44d[_0x51f3dc('0x170')])_0x48c578[_0x51f3dc('0x1fd0')](_0x5e461b[_0x51f3dc('0xcf7')][_0x51f3dc('0x1e6e')]({'sectionId':_0x5cc44d['id']})[_0x51f3dc('0xe53')]);else{const _0xae50a9=[];_0x133637[_0x51f3dc('0x1299')](function(_0x42609b){const _0x5115c5=_0x51f3dc;_0x42609b[_0x5115c5('0xcf0')]===_0x1104a0[_0x102002][_0x5115c5('0xcf0')]&&_0xae50a9[_0x5115c5('0x1fd0')](_0x42609b);}),_0x48c578['push']({'rows':_0xae50a9,'count':_0xae50a9[_0x51f3dc('0x1564')]});}}}return _0x11ea0f[_0x51f3dc('0x252c')](_0x48c578);})[_0x5e72f1('0x683')](function(_0x2f7e23){const _0x4aadea=_0x5e72f1,_0x36eeed=[],_0x31b6e1=[];_0x1456f1['triggerAllConditions']['rows'][_0x4aadea('0x1299')](function(_0x3fcac3){const _0x304c94=_0x4aadea;if(_0x3fcac3[_0x304c94('0x2013')]===_0x304c94('0x660')){const _0x3f005b=_0x2e3ca0()[_0x304c94('0x1c07')](_0x133637,{'name':_0x3fcac3[_0x304c94('0x1c6b')]});_0x31b6e1['push'](_0x3f005b);}});for(let _0xf3aeeb=0x0;_0xf3aeeb<_0x2f7e23[_0x4aadea('0x1564')];_0xf3aeeb++){const _0x21ffed=_0x2f7e23[_0xf3aeeb][_0x4aadea('0xf5d')]||[];_0x21ffed[_0x4aadea('0x1299')](function(_0x538150){const _0x2377a3=_0x4aadea;_0x36eeed[_0x2377a3('0x1fd0')](_0x538150);});}!_0x2e3ca0()[_0x4aadea('0x173f')](_0x31b6e1)&&_0x31b6e1[_0x4aadea('0x1299')](function(_0x5b84cc){const _0x27e9fa=_0x4aadea;if(!_0x2e3ca0()[_0x27e9fa('0x7a2')](_0x36eeed,['resourceId',_0x5b84cc['id']])){const _0x5e1648=_0x2e3ca0()[_0x27e9fa('0x1c07')](_0x133637,{'id':_0x5b84cc['id']});_0x5e1648[_0x27e9fa('0x319')]=![],_0x36eeed['push'](_0x5e1648);}}),_0x1456f1[_0x4aadea('0x2da')]=_0x36eeed;})[_0x5e72f1('0x130a')](function(_0x5e83ee){const _0x257974=_0x5e72f1;_0x3e4a8a[_0x257974('0x52a')]({'title':_0x5e83ee[_0x257974('0x13ee')]?_0x257974('0x2168')+_0x5e83ee[_0x257974('0x13ee')]+_0x257974('0xbf6')+_0x5e83ee['statusText']:_0x257974('0x22dc'),'msg':_0x5e83ee[_0x257974('0x5a5')]?JSON[_0x257974('0x258a')](_0x5e83ee['data']):_0x5e83ee[_0x257974('0x1ff0')]()});});}function _0xc16d4(){const _0x288b56=_0x38874b;_0x39a347['isAdmin']()?_0x5e461b['voiceExtension'][_0x288b56('0x1e6e')]({'fields':'id,exten','type':_0x288b56('0x17cd'),'VoiceExtensionId':_0x288b56('0x13c'),'nolimit':'true'})[_0x288b56('0xe53')]['then'](function(_0x3db08e){const _0x133c9a=_0x288b56;_0x1456f1[_0x133c9a('0x871')]=_0x3db08e[_0x133c9a('0xf5d')]||[];})[_0x288b56('0x130a')](function(_0x301972){const _0x19e7fc=_0x288b56;_0x3e4a8a[_0x19e7fc('0x52a')]({'title':_0x301972[_0x19e7fc('0x13ee')]?_0x19e7fc('0x2168')+_0x301972['status']+_0x19e7fc('0xbf6')+_0x301972[_0x19e7fc('0x24a9')]:_0x19e7fc('0xaf8'),'msg':_0x301972[_0x19e7fc('0x5a5')]?JSON[_0x19e7fc('0x258a')](_0x301972[_0x19e7fc('0x5a5')]):_0x301972[_0x19e7fc('0x1ff0')]()});}):_0x5e461b[_0x288b56('0x14cb')][_0x288b56('0x1e6e')]({'fields':_0x288b56('0x5c6'),'type':_0x288b56('0x17cd'),'VoiceExtensionId':'null','nolimit':_0x288b56('0x26ac')})[_0x288b56('0xe53')][_0x288b56('0x683')](function(_0x2b4d6f){const _0x187b76=_0x288b56;_0x1456f1[_0x187b76('0x871')]=_0x2b4d6f[_0x187b76('0xf5d')]||[];})[_0x288b56('0x683')](function(){const _0x5166b8=_0x288b56;return _0x5e461b['userProfileSection'][_0x5166b8('0x1e6e')]({'userProfileId':_0x1456f1['currentUser']['userProfileId'],'sectionId':0x193})['$promise'];})[_0x288b56('0x683')](function(_0x40ab97){const _0x1e50cc=_0x288b56,_0x2d2126=_0x40ab97&&_0x40ab97[_0x1e50cc('0xf5d')]?_0x40ab97[_0x1e50cc('0xf5d')][0x0]:null;if(!_0x2d2126){const _0x735907=[],_0x581078=[];_0x1456f1[_0x1e50cc('0x1a5d')]['rows'][_0x1e50cc('0x1299')](function(_0x316262){const _0x1d6d47=_0x1e50cc;if(_0x316262[_0x1d6d47('0x2013')]===_0x1d6d47('0x4f8')){const _0x34e61f=_0x2e3ca0()[_0x1d6d47('0x1c07')](_0x1456f1['outboundRoutes'],{'id':Number(_0x316262['value'])});_0x581078['push'](_0x34e61f);}});for(let _0x26184f=0x0;_0x26184f<_0x1456f1[_0x1e50cc('0x871')][_0x1e50cc('0x1564')];_0x26184f++){const _0x30fd1e=_0x2e3ca0()[_0x1e50cc('0x7a2')](_0x581078,{'id':_0x1456f1['outboundRoutes'][_0x26184f]['id']});_0x30fd1e&&(_0x1456f1['outboundRoutes'][_0x26184f][_0x1e50cc('0x319')]=![],_0x735907['push'](_0x1456f1[_0x1e50cc('0x871')][_0x26184f]));}_0x1456f1[_0x1e50cc('0x871')]=_0x735907;}else{if(!_0x2d2126['autoAssociation'])return _0x5e461b['userProfileResource'][_0x1e50cc('0x1e6e')]({'sectionId':_0x2d2126['id']})[_0x1e50cc('0xe53')]['then'](function(_0x11b138){const _0x127c32=_0x1e50cc,_0x569a52=_0x2e3ca0()[_0x127c32('0x386')](_0x11b138['rows'],function(_0x3e856c){const _0x26b164=_0x127c32;return _0x2e3ca0()[_0x26b164('0x1c07')](_0x1456f1['outboundRoutes'],{'id':_0x3e856c[_0x26b164('0x832')]});});let _0x33bf45=null;_0x33bf45=[],_0x1456f1[_0x127c32('0x1a5d')][_0x127c32('0xf5d')][_0x127c32('0x1299')](function(_0x33fae1){const _0x1bd23a=_0x127c32;if(_0x33fae1[_0x1bd23a('0x2013')]===_0x1bd23a('0x4f8')){const _0x2a8860=_0x2e3ca0()['find'](_0x1456f1[_0x1bd23a('0x871')],{'id':Number(_0x33fae1[_0x1bd23a('0x1c6b')])});_0x33bf45[_0x1bd23a('0x1fd0')](_0x2a8860);}}),!_0x2e3ca0()[_0x127c32('0x173f')](_0x33bf45)&&_0x33bf45['forEach'](function(_0x1afc4a){const _0x4b1a1e=_0x127c32;if(!_0x2e3ca0()[_0x4b1a1e('0x7a2')](_0x569a52,['id',_0x1afc4a['id']])){const _0x43e6b8=_0x2e3ca0()[_0x4b1a1e('0x1c07')](_0x1456f1[_0x4b1a1e('0x871')],{'id':_0x1afc4a['id']});_0x43e6b8['canSelect']=![],_0x569a52[_0x4b1a1e('0x1fd0')](_0x43e6b8);}}),_0x1456f1[_0x127c32('0x871')]=_0x569a52;});}})[_0x288b56('0x130a')](function(_0x5c5603){const _0x5a1f13=_0x288b56;_0x3e4a8a[_0x5a1f13('0x52a')]({'title':_0x5c5603[_0x5a1f13('0x13ee')]?_0x5a1f13('0x2168')+_0x5c5603[_0x5a1f13('0x13ee')]+_0x5a1f13('0xbf6')+_0x5c5603[_0x5a1f13('0x24a9')]:_0x5a1f13('0xaf8'),'msg':_0x5c5603['data']?JSON[_0x5a1f13('0x258a')](_0x5c5603[_0x5a1f13('0x5a5')]):_0x5c5603[_0x5a1f13('0x1ff0')]()});});}function _0x2f5367(){const _0x1858b2=_0x38874b;_0x39a347['isAdmin']()?_0x5e461b[_0x1858b2('0xc96')][_0x1858b2('0x1e6e')]({'fields':'id,name,fullname','sort':'name','role':_0x1858b2('0x2327'),'nolimit':_0x1858b2('0x26ac')})[_0x1858b2('0xe53')][_0x1858b2('0x683')](function(_0x4bed0e){const _0x6f68a6=_0x1858b2;_0x1456f1['agents']=_0x4bed0e[_0x6f68a6('0xf5d')]||[];})['catch'](function(_0x47df79){const _0x1a2e5e=_0x1858b2;_0x3e4a8a[_0x1a2e5e('0x52a')]({'title':_0x47df79[_0x1a2e5e('0x13ee')]?_0x1a2e5e('0x2168')+_0x47df79['status']+_0x1a2e5e('0xbf6')+_0x47df79[_0x1a2e5e('0x24a9')]:_0x1a2e5e('0x144f'),'msg':_0x47df79['data']?JSON[_0x1a2e5e('0x258a')](_0x47df79['data']):_0x47df79[_0x1a2e5e('0x1ff0')]()});}):_0x5e461b['user'][_0x1858b2('0x1e6e')]({'fields':'id,name,fullname','sort':_0x1858b2('0x60a'),'role':'agent','nolimit':_0x1858b2('0x26ac')})['$promise'][_0x1858b2('0x683')](function(_0x4e57dc){const _0xfd721a=_0x1858b2;_0x1456f1[_0xfd721a('0x756')]=_0x4e57dc[_0xfd721a('0xf5d')]||[];})[_0x1858b2('0x683')](function(){const _0x17af1d=_0x1858b2;return _0x5e461b[_0x17af1d('0x22df')][_0x17af1d('0x1e6e')]({'userProfileId':_0x1456f1['currentUser'][_0x17af1d('0x2f')],'sectionId':0xca})['$promise'];})['then'](function(_0x165327){const _0x5ec96a=_0x1858b2,_0x2ea292=_0x165327&&_0x165327[_0x5ec96a('0xf5d')]?_0x165327[_0x5ec96a('0xf5d')][0x0]:null;if(!_0x2ea292){const _0x359c97=[],_0x9ecb72=[];_0x1456f1[_0x5ec96a('0x1a5d')][_0x5ec96a('0xf5d')]['forEach'](function(_0x10ce98){const _0x3ad40a=_0x5ec96a;if(_0x10ce98[_0x3ad40a('0x2013')]===_0x3ad40a('0x2327')){const _0x261481=_0x2e3ca0()['find'](_0x1456f1[_0x3ad40a('0x756')],{'name':_0x10ce98['value']});_0x9ecb72['push'](_0x261481);}});for(let _0x57c1b2=0x0;_0x57c1b2<_0x1456f1[_0x5ec96a('0x756')][_0x5ec96a('0x1564')];_0x57c1b2++){const _0x11911e=_0x2e3ca0()[_0x5ec96a('0x7a2')](_0x9ecb72,{'id':_0x1456f1[_0x5ec96a('0x756')][_0x57c1b2]['id']});_0x11911e&&(_0x1456f1[_0x5ec96a('0x756')][_0x57c1b2][_0x5ec96a('0x319')]=![],_0x359c97[_0x5ec96a('0x1fd0')](_0x1456f1[_0x5ec96a('0x756')][_0x57c1b2]));}_0x1456f1['agents']=_0x359c97;}else{if(!_0x2ea292[_0x5ec96a('0x170')])return _0x5e461b[_0x5ec96a('0xcf7')]['get']({'sectionId':_0x2ea292['id']})[_0x5ec96a('0xe53')][_0x5ec96a('0x683')](function(_0x1c4ac1){const _0x446eab=_0x5ec96a,_0x2a80fd=_0x2e3ca0()[_0x446eab('0x386')](_0x1c4ac1['rows'],function(_0x11f19b){const _0x2a44cf=_0x446eab;return _0x2e3ca0()[_0x2a44cf('0x1c07')](_0x1456f1['agents'],{'id':_0x11f19b[_0x2a44cf('0x832')]});});let _0x4f514e=null;_0x4f514e=[],_0x1456f1[_0x446eab('0x1a5d')]['rows'][_0x446eab('0x1299')](function(_0x40a693){const _0x3f803f=_0x446eab;if(_0x40a693['field']===_0x3f803f('0x2327')){const _0x4106c4=_0x2e3ca0()[_0x3f803f('0x1c07')](_0x1456f1[_0x3f803f('0x756')],{'name':_0x40a693[_0x3f803f('0x1c6b')]});_0x4f514e[_0x3f803f('0x1fd0')](_0x4106c4);}}),!_0x2e3ca0()[_0x446eab('0x173f')](_0x4f514e)&&_0x4f514e[_0x446eab('0x1299')](function(_0x5dbef9){const _0x3f5853=_0x446eab;if(!_0x2e3ca0()['some'](_0x2a80fd,['id',_0x5dbef9['id']])){const _0x5e5d84=_0x2e3ca0()['find'](_0x1456f1['agents'],{'id':_0x5dbef9['id']});_0x5e5d84[_0x3f5853('0x319')]=![],_0x2a80fd[_0x3f5853('0x1fd0')](_0x5e5d84);}}),_0x1456f1[_0x446eab('0x756')]=_0x2a80fd;});}})[_0x1858b2('0x130a')](function(_0x12a207){const _0x2d92a3=_0x1858b2;_0x3e4a8a[_0x2d92a3('0x52a')]({'title':_0x12a207[_0x2d92a3('0x13ee')]?_0x2d92a3('0x2168')+_0x12a207[_0x2d92a3('0x13ee')]+_0x2d92a3('0xbf6')+_0x12a207[_0x2d92a3('0x24a9')]:'SYSTEM:GET_AGENTS','msg':_0x12a207[_0x2d92a3('0x5a5')]?JSON[_0x2d92a3('0x258a')](_0x12a207['data']):_0x12a207[_0x2d92a3('0x1ff0')]()});});}function _0x3f0d59(){const _0x4b3e72=_0x38874b;if(_0x1456f1[_0x4b3e72('0x25e2')][_0x4b3e72('0xdd6')]===_0x4b3e72('0xcf2')){if(_0x2e3ca0()['some'](_0x1456f1[_0x4b3e72('0x1a5d')][_0x4b3e72('0xf5d')],[_0x4b3e72('0x2013'),'queue'])){if(!_0x1456f1[_0x4b3e72('0x2da')])_0x4fbe2b();}if(_0x2e3ca0()[_0x4b3e72('0x7a2')](_0x1456f1[_0x4b3e72('0x1a5d')][_0x4b3e72('0xf5d')],[_0x4b3e72('0x2013'),'routeId'])){if(!_0x1456f1[_0x4b3e72('0x871')])_0xc16d4();}if(_0x2e3ca0()['some'](_0x1456f1[_0x4b3e72('0x1a5d')][_0x4b3e72('0xf5d')],[_0x4b3e72('0x2013'),_0x4b3e72('0x2327')])){if(!_0x1456f1[_0x4b3e72('0x756')])_0x2f5367();}}else _0xf83a34();}function _0x4e3c22(_0x411bcb){_0x1456f1['triggerAllConditions']=_0x411bcb||{'count':0x0,'rows':[]},_0x3f0d59();}function _0x47afa3(){const _0x13f5b5=_0x38874b;_0x1456f1[_0x13f5b5('0x23a2')]['offset']=(_0x1456f1[_0x13f5b5('0x23a2')][_0x13f5b5('0xdf8')]-0x1)*_0x1456f1[_0x13f5b5('0x23a2')][_0x13f5b5('0x6f0')],_0x1456f1[_0x13f5b5('0x1883')]=_0x5e461b['trigger'][_0x13f5b5('0xac8')](_0x1456f1[_0x13f5b5('0x23a2')],_0x4e3c22)[_0x13f5b5('0xe53')];}function _0x5f15d5(_0x53a8fc,_0x37d0d7){const _0x54a747=_0x38874b;_0x3f0baa[_0x54a747('0x1d4')]({'controller':_0x54a747('0x195e'),'controllerAs':'vm','templateUrl':_0x2c368d,'parent':angular[_0x54a747('0x1fcc')](_0x12578b['body']),'targetEvent':_0x53a8fc,'clickOutsideToClose':!![],'locals':{'trigger':_0x1456f1['trigger'],'allCondition':_0x37d0d7,'allConditions':_0x1456f1[_0x54a747('0x1a5d')][_0x54a747('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x1456f1[_0x54a747('0x1134')]}})[_0x54a747('0x683')](function(_0x32f917){const _0x45fb7c=_0x54a747;_0x32f917&&(_0x1456f1[_0x45fb7c('0x1a5d')]={'count':_0x32f917['length'],'rows':_0x32f917},_0x3f0d59());});}function _0x556e53(_0x3a253c,_0x10f512){const _0x2ccffa=_0x38874b,_0x3e1eaf=_0x3f0baa[_0x2ccffa('0x1c6f')]()[_0x2ccffa('0xf28')](_0x411490[_0x2ccffa('0x2728')](_0x2ccffa('0x26e1')))[_0x2ccffa('0x1040')](_0x2ccffa('0xc8a'))['targetEvent'](_0x10f512)['ok']('OK')['cancel'](_0x411490[_0x2ccffa('0x2728')](_0x2ccffa('0x9a1')));_0x3f0baa[_0x2ccffa('0x1d4')](_0x3e1eaf)['then'](function(){_0x577799(_0x3a253c,!![]);});}function _0x577799(_0x4f42f3,_0x1ff175){const _0x15e6ac=_0x38874b;_0x5e461b[_0x15e6ac('0x168e')][_0x15e6ac('0xd7e')]({'id':_0x4f42f3['id']})[_0x15e6ac('0xe53')][_0x15e6ac('0x683')](function(){const _0x4a56f3=_0x15e6ac;_0x47afa3(),_0x1ff175&&_0x3e4a8a['success']({'title':_0x411490[_0x4a56f3('0x2728')]('TOOLS.NOTIFICATIONS.CONDITION_DELETED_SUCCESS_TITLE')});})[_0x15e6ac('0x130a')](function(_0x207ec0){const _0x5b1bd2=_0x15e6ac;if(_0x207ec0[_0x5b1bd2('0x5a5')]&&_0x207ec0[_0x5b1bd2('0x5a5')][_0x5b1bd2('0x17f')]&&_0x207ec0['data']['errors'][_0x5b1bd2('0x1564')]){_0x1456f1[_0x5b1bd2('0x17f')]=_0x207ec0[_0x5b1bd2('0x5a5')][_0x5b1bd2('0x17f')]||[{'message':_0x207ec0[_0x5b1bd2('0x1ff0')](),'type':'SYSTEM:GETtrigger'}];for(let _0x29cd75=0x0;_0x29cd75<_0x207ec0[_0x5b1bd2('0x5a5')][_0x5b1bd2('0x17f')][_0x5b1bd2('0x1564')];_0x29cd75++){_0x3e4a8a[_0x5b1bd2('0x52a')]({'title':_0x207ec0[_0x5b1bd2('0x5a5')][_0x5b1bd2('0x17f')][_0x29cd75][_0x5b1bd2('0xcf0')],'msg':_0x207ec0['data'][_0x5b1bd2('0x17f')][_0x29cd75][_0x5b1bd2('0x8c2')]});}}else _0x3e4a8a[_0x5b1bd2('0x52a')]({'title':_0x207ec0[_0x5b1bd2('0x13ee')]?'API:'+_0x207ec0[_0x5b1bd2('0x13ee')]+'\x20-\x20'+_0x207ec0[_0x5b1bd2('0x24a9')]:_0x5b1bd2('0x107f'),'msg':_0x207ec0[_0x5b1bd2('0x5a5')]?JSON['stringify'](_0x207ec0[_0x5b1bd2('0x5a5')][_0x5b1bd2('0x8c2')]):_0x207ec0[_0x5b1bd2('0x8c2')]||_0x207ec0[_0x5b1bd2('0x1ff0')]()});});}function _0x563002(){const _0x20b04c=_0x38874b,_0x4b4b3b=angular['copy'](_0x1456f1[_0x20b04c('0x245b')]);return _0x1456f1['selectedTriggerAllConditions']=[],_0x4b4b3b;}function _0x15ba40(_0x4cb976){const _0x107f02=_0x38874b,_0x267d8a=_0x3f0baa[_0x107f02('0x1c6f')]()['title'](_0x411490['instant'](_0x107f02('0xb9e')))[_0x107f02('0xa6a')](_0x411490[_0x107f02('0x2728')](_0x107f02('0x2703'),{'total':_0x1456f1[_0x107f02('0x245b')][_0x107f02('0x1564')]}))[_0x107f02('0x1040')](_0x107f02('0x27b0'))[_0x107f02('0xe42')](_0x4cb976)['ok']('OK')['cancel'](_0x411490['instant'](_0x107f02('0x9a1')));_0x3f0baa[_0x107f02('0x1d4')](_0x267d8a)[_0x107f02('0x683')](function(){const _0x4277d1=_0x107f02;_0x1456f1[_0x4277d1('0x245b')][_0x4277d1('0x1299')](function(_0x5a294e){_0x577799(_0x5a294e);}),_0x1456f1[_0x4277d1('0x245b')]=[],_0x3e4a8a[_0x4277d1('0x53')]({'title':_0x411490['instant']('TOOLS.NOTIFICATIONS.CONDITIONS_DELETED_SUCCESS_TITLE')});});}let _0x140621=!![],_0x3e814f=0x1;_0x2d49be[_0x38874b('0x186d')](_0x38874b('0x229'),function(_0x28377b,_0xc2483b){const _0x5b47ed=_0x38874b;_0x140621?_0x23953c(function(){_0x140621=![];}):(!_0xc2483b&&(_0x3e814f=_0x1456f1[_0x5b47ed('0x23a2')][_0x5b47ed('0xdf8')]),_0x28377b!==_0xc2483b&&(_0x1456f1[_0x5b47ed('0x23a2')][_0x5b47ed('0xdf8')]=0x1),!_0x28377b&&(_0x1456f1['query'][_0x5b47ed('0xdf8')]=_0x3e814f),_0x47afa3());});}const _0x28a3b5=_0x2d8d63;_0x112331[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1055'),_0x189033('0x179f'),_0x189033('0x25e2'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x112331(_0x23adc1,_0x4d11e1,_0x56b372,_0x4950ac,_0x96c539,_0x3e2887,_0x203fd9,_0x54ecd2,_0x1d571d,_0x15bc09,_0x6b28ed,_0x3d3b3c,_0x4a888f,_0xaf63cc,_0x59e0c6){const _0x5b251e=_0x189033,_0x538783=this;_0x538783[_0x5b251e('0x11ed')]=_0x3d3b3c[_0x5b251e('0x20b2')](),_0x538783[_0x5b251e('0x17f')]=[],_0x538783[_0x5b251e('0x260a')]=_0xaf63cc,_0x538783[_0x5b251e('0xace')]=_0x4a888f,_0x538783['crudPermissions']=_0x59e0c6,_0x538783[_0x5b251e('0x258d')]={},_0x538783['passwordPattern']=_0x538783[_0x5b251e('0x260a')]&&_0x538783[_0x5b251e('0x260a')][_0x5b251e('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x538783['title']=_0x5b251e('0x165a'),_0x538783[_0x5b251e('0x179f')]=angular[_0x5b251e('0x1a86')](_0x1d571d),_0x538783[_0x5b251e('0x1055')]=_0x54ecd2,_0x538783[_0x5b251e('0x68c')]=![],_0x538783['trigger']=angular[_0x5b251e('0x1a86')](_0x15bc09);!_0x538783[_0x5b251e('0x179f')]&&(_0x538783['allCondition']={'field':'queue','operator':'equals','value':'in'},_0x538783[_0x5b251e('0xf28')]=_0x5b251e('0x5f3'),_0x538783[_0x5b251e('0x68c')]=!![]);_0x4d11e1['params']['id']&&(_0x538783[_0x5b251e('0x179f')][_0x5b251e('0x1e42')]=_0x4d11e1[_0x5b251e('0x7f2')]['id']);_0x538783[_0x5b251e('0x1561')]=_0x17bd13,_0x538783[_0x5b251e('0x3f7')]=_0x191c13,_0x538783[_0x5b251e('0x581')]=_0x2ea878,_0x538783[_0x5b251e('0x16b3')]=_0x4b8330,_0x538783[_0x5b251e('0xf82')]=_0x60200b,_0x3d3b3c[_0x5b251e('0xca1')](_0x5b251e('0x20c2'))?_0x6b28ed[_0x5b251e('0x2681')][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0xa10'),'sort':'id','nolimit':'true'})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x3f0843){const _0x1c7b9f=_0x5b251e;_0x538783['chatAccounts']=_0x3f0843[_0x1c7b9f('0xf5d')]||[];})['catch'](function(_0x2f2800){const _0x1fac94=_0x5b251e;_0x203fd9[_0x1fac94('0x52a')]({'title':_0x2f2800[_0x1fac94('0x13ee')]?_0x1fac94('0x2168')+_0x2f2800[_0x1fac94('0x13ee')]+_0x1fac94('0xbf6')+_0x2f2800[_0x1fac94('0x24a9')]:_0x1fac94('0x1702'),'msg':_0x2f2800[_0x1fac94('0x5a5')]?JSON['stringify'](_0x2f2800[_0x1fac94('0x5a5')]):_0x2f2800['toString']()});}):_0x6b28ed[_0x5b251e('0x2681')][_0x5b251e('0x1e6e')]({'fields':'id,name','sort':'id','nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x523e2c){const _0x20c5dd=_0x5b251e;_0x538783['chatAccounts']=_0x523e2c[_0x20c5dd('0xf5d')]||[];})[_0x5b251e('0x683')](function(){const _0x5b5630=_0x5b251e;return _0x6b28ed[_0x5b5630('0x22df')]['get']({'userProfileId':_0x538783[_0x5b5630('0x11ed')][_0x5b5630('0x2f')],'sectionId':0x1f6})['$promise'];})[_0x5b251e('0x683')](function(_0x55481b){const _0xd5c877=_0x5b251e,_0x57c7c2=_0x55481b&&_0x55481b[_0xd5c877('0xf5d')]?_0x55481b[_0xd5c877('0xf5d')][0x0]:null;if(!_0x57c7c2){const _0x42ff9a=[];let _0x438798=null;_0x538783[_0xd5c877('0x179f')]&&(_0x438798=_0x2e3ca0()[_0xd5c877('0x1c07')](_0x538783[_0xd5c877('0x11e2')],{'id':Number(_0x538783[_0xd5c877('0x179f')][_0xd5c877('0x1c6b')])}));for(let _0xc4d626=0x0;_0xc4d626<_0x538783['chatAccounts'][_0xd5c877('0x1564')];_0xc4d626++){_0x438798&&_0x538783['chatAccounts'][_0xc4d626]['id']===_0x438798['id']&&(_0x538783[_0xd5c877('0x11e2')][_0xc4d626][_0xd5c877('0x319')]=![],_0x42ff9a[_0xd5c877('0x1fd0')](_0x538783['chatAccounts'][_0xc4d626]));}_0x538783[_0xd5c877('0x11e2')]=_0x42ff9a;}else{if(!_0x57c7c2[_0xd5c877('0x170')])return _0x6b28ed[_0xd5c877('0xcf7')]['get']({'sectionId':_0x57c7c2['id']})['$promise'][_0xd5c877('0x683')](function(_0x34ca3a){const _0x1ecd81=_0xd5c877,_0x3a1525=_0x2e3ca0()[_0x1ecd81('0x386')](_0x34ca3a['rows'],function(_0x4667c4){const _0x4bf2f1=_0x1ecd81;return _0x2e3ca0()[_0x4bf2f1('0x1c07')](_0x538783['chatAccounts'],{'id':_0x4667c4[_0x4bf2f1('0x832')]});});let _0x394ff3=null;_0x538783[_0x1ecd81('0x179f')]&&(_0x394ff3=_0x2e3ca0()[_0x1ecd81('0x1c07')](_0x538783[_0x1ecd81('0x11e2')],{'id':Number(_0x538783[_0x1ecd81('0x179f')][_0x1ecd81('0x1c6b')])}));if(_0x394ff3&&!_0x2e3ca0()['some'](_0x3a1525,['id',_0x394ff3['id']])){const _0x49a266=_0x2e3ca0()[_0x1ecd81('0x1c07')](_0x538783[_0x1ecd81('0x11e2')],{'id':_0x394ff3['id']});_0x49a266[_0x1ecd81('0x319')]=![],_0x3a1525[_0x1ecd81('0x1fd0')](_0x49a266);}_0x538783[_0x1ecd81('0x11e2')]=_0x3a1525;});}})[_0x5b251e('0x130a')](function(_0x5065ec){const _0x1a54bf=_0x5b251e;_0x203fd9['error']({'title':_0x5065ec[_0x1a54bf('0x13ee')]?'API:'+_0x5065ec[_0x1a54bf('0x13ee')]+'\x20-\x20'+_0x5065ec['statusText']:_0x1a54bf('0x1228'),'msg':_0x5065ec[_0x1a54bf('0x5a5')]?JSON[_0x1a54bf('0x258a')](_0x5065ec['data']):_0x5065ec[_0x1a54bf('0x1ff0')]()});}),_0x3d3b3c['hasRole'](_0x5b251e('0x20c2'))?_0x6b28ed[_0x5b251e('0xb87')][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0xa10'),'sort':'id','nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')]['then'](function(_0x5f30bf){const _0x457d9e=_0x5b251e;_0x538783[_0x457d9e('0x1093')]=_0x5f30bf[_0x457d9e('0xf5d')]||[];})[_0x5b251e('0x130a')](function(_0x3420b7){const _0x1279c5=_0x5b251e;_0x203fd9[_0x1279c5('0x52a')]({'title':_0x3420b7[_0x1279c5('0x13ee')]?'API:'+_0x3420b7[_0x1279c5('0x13ee')]+_0x1279c5('0xbf6')+_0x3420b7[_0x1279c5('0x24a9')]:_0x1279c5('0x12be'),'msg':_0x3420b7[_0x1279c5('0x5a5')]?JSON['stringify'](_0x3420b7[_0x1279c5('0x5a5')]):_0x3420b7[_0x1279c5('0x1ff0')]()});}):_0x6b28ed['mailAccount'][_0x5b251e('0x1e6e')]({'fields':'id,name','sort':'id','nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x5626bf){const _0x12882e=_0x5b251e;_0x538783[_0x12882e('0x1093')]=_0x5626bf[_0x12882e('0xf5d')]||[];})[_0x5b251e('0x683')](function(){const _0x38d30a=_0x5b251e;return _0x6b28ed[_0x38d30a('0x22df')]['get']({'userProfileId':_0x538783[_0x38d30a('0x11ed')][_0x38d30a('0x2f')],'sectionId':0x25a})[_0x38d30a('0xe53')];})[_0x5b251e('0x683')](function(_0x4422d1){const _0x3332de=_0x5b251e,_0x587ce3=_0x4422d1&&_0x4422d1[_0x3332de('0xf5d')]?_0x4422d1['rows'][0x0]:null;if(!_0x587ce3){const _0x1f4b75=[];let _0x1c4a70=null;_0x538783[_0x3332de('0x179f')]&&(_0x1c4a70=_0x2e3ca0()[_0x3332de('0x1c07')](_0x538783['mailAccounts'],{'id':Number(_0x538783[_0x3332de('0x179f')][_0x3332de('0x1c6b')])}));for(let _0x2759aa=0x0;_0x2759aa<_0x538783[_0x3332de('0x1093')]['length'];_0x2759aa++){_0x1c4a70&&_0x538783['mailAccounts'][_0x2759aa]['id']===_0x1c4a70['id']&&(_0x538783[_0x3332de('0x1093')][_0x2759aa][_0x3332de('0x319')]=![],_0x1f4b75['push'](_0x538783['mailAccounts'][_0x2759aa]));}_0x538783['mailAccounts']=_0x1f4b75;}else{if(!_0x587ce3[_0x3332de('0x170')])return _0x6b28ed['userProfileResource']['get']({'sectionId':_0x587ce3['id']})[_0x3332de('0xe53')]['then'](function(_0x4a97c0){const _0x4d264b=_0x3332de,_0x16ef5b=_0x2e3ca0()[_0x4d264b('0x386')](_0x4a97c0[_0x4d264b('0xf5d')],function(_0x4fcca4){const _0x4a7cae=_0x4d264b;return _0x2e3ca0()[_0x4a7cae('0x1c07')](_0x538783[_0x4a7cae('0x1093')],{'id':_0x4fcca4['resourceId']});});let _0x2b7803=null;_0x538783['allCondition']&&(_0x2b7803=_0x2e3ca0()[_0x4d264b('0x1c07')](_0x538783[_0x4d264b('0x1093')],{'id':Number(_0x538783[_0x4d264b('0x179f')][_0x4d264b('0x1c6b')])}));if(_0x2b7803&&!_0x2e3ca0()[_0x4d264b('0x7a2')](_0x16ef5b,['id',_0x2b7803['id']])){const _0x3190d6=_0x2e3ca0()[_0x4d264b('0x1c07')](_0x538783['mailAccounts'],{'id':_0x2b7803['id']});_0x3190d6[_0x4d264b('0x319')]=![],_0x16ef5b[_0x4d264b('0x1fd0')](_0x3190d6);}_0x538783[_0x4d264b('0x1093')]=_0x16ef5b;});}})[_0x5b251e('0x130a')](function(_0x5899e2){const _0xdeded1=_0x5b251e;_0x203fd9['error']({'title':_0x5899e2[_0xdeded1('0x13ee')]?'API:'+_0x5899e2['status']+_0xdeded1('0xbf6')+_0x5899e2['statusText']:_0xdeded1('0x1ded'),'msg':_0x5899e2[_0xdeded1('0x5a5')]?JSON[_0xdeded1('0x258a')](_0x5899e2[_0xdeded1('0x5a5')]):_0x5899e2[_0xdeded1('0x1ff0')]()});}),_0x3d3b3c[_0x5b251e('0xca1')](_0x5b251e('0x20c2'))?_0x6b28ed['smsAccount'][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0xa10'),'sort':'id','nolimit':_0x5b251e('0x26ac')})['$promise'][_0x5b251e('0x683')](function(_0x3361ec){const _0x13d384=_0x5b251e;_0x538783['smsAccounts']=_0x3361ec[_0x13d384('0xf5d')]||[];})['catch'](function(_0x47e5c3){const _0x27e12f=_0x5b251e;_0x203fd9['error']({'title':_0x47e5c3[_0x27e12f('0x13ee')]?'API:'+_0x47e5c3[_0x27e12f('0x13ee')]+'\x20-\x20'+_0x47e5c3[_0x27e12f('0x24a9')]:_0x27e12f('0xad4'),'msg':_0x47e5c3[_0x27e12f('0x5a5')]?JSON[_0x27e12f('0x258a')](_0x47e5c3[_0x27e12f('0x5a5')]):_0x47e5c3[_0x27e12f('0x1ff0')]()});}):_0x6b28ed[_0x5b251e('0xa0e')][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0xa10'),'sort':'id','nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x2cfc9f){_0x538783['smsAccounts']=_0x2cfc9f['rows']||[];})['then'](function(){const _0x52accf=_0x5b251e;return _0x6b28ed[_0x52accf('0x22df')][_0x52accf('0x1e6e')]({'userProfileId':_0x538783['currentUser'][_0x52accf('0x2f')],'sectionId':0x2be})['$promise'];})[_0x5b251e('0x683')](function(_0x437cf5){const _0x2c55c8=_0x5b251e,_0x7a264e=_0x437cf5&&_0x437cf5[_0x2c55c8('0xf5d')]?_0x437cf5[_0x2c55c8('0xf5d')][0x0]:null;if(!_0x7a264e){const _0x1420fc=[];let _0x515234=null;_0x538783[_0x2c55c8('0x179f')]&&(_0x515234=_0x2e3ca0()[_0x2c55c8('0x1c07')](_0x538783[_0x2c55c8('0x197c')],{'id':Number(_0x538783['allCondition'][_0x2c55c8('0x1c6b')])}));for(let _0x1f9aa2=0x0;_0x1f9aa2<_0x538783[_0x2c55c8('0x197c')][_0x2c55c8('0x1564')];_0x1f9aa2++){_0x515234&&_0x538783[_0x2c55c8('0x197c')][_0x1f9aa2]['id']===_0x515234['id']&&(_0x538783['smsAccounts'][_0x1f9aa2]['canSelect']=![],_0x1420fc[_0x2c55c8('0x1fd0')](_0x538783[_0x2c55c8('0x197c')][_0x1f9aa2]));}_0x538783['smsAccounts']=_0x1420fc;}else{if(!_0x7a264e['autoAssociation'])return _0x6b28ed[_0x2c55c8('0xcf7')][_0x2c55c8('0x1e6e')]({'sectionId':_0x7a264e['id']})['$promise'][_0x2c55c8('0x683')](function(_0x318dd8){const _0x34230b=_0x2c55c8,_0x38e8d2=_0x2e3ca0()[_0x34230b('0x386')](_0x318dd8[_0x34230b('0xf5d')],function(_0x58a073){const _0x19c263=_0x34230b;return _0x2e3ca0()[_0x19c263('0x1c07')](_0x538783[_0x19c263('0x197c')],{'id':_0x58a073[_0x19c263('0x832')]});});let _0x45580b=null;_0x538783[_0x34230b('0x179f')]&&(_0x45580b=_0x2e3ca0()[_0x34230b('0x1c07')](_0x538783[_0x34230b('0x197c')],{'id':Number(_0x538783[_0x34230b('0x179f')][_0x34230b('0x1c6b')])}));if(_0x45580b&&!_0x2e3ca0()['some'](_0x38e8d2,['id',_0x45580b['id']])){const _0x1bd13b=_0x2e3ca0()[_0x34230b('0x1c07')](_0x538783[_0x34230b('0x197c')],{'id':_0x45580b['id']});_0x1bd13b[_0x34230b('0x319')]=![],_0x38e8d2[_0x34230b('0x1fd0')](_0x1bd13b);}_0x538783['smsAccounts']=_0x38e8d2;});}})[_0x5b251e('0x130a')](function(_0x3e8bec){const _0x415b4d=_0x5b251e;_0x203fd9[_0x415b4d('0x52a')]({'title':_0x3e8bec[_0x415b4d('0x13ee')]?_0x415b4d('0x2168')+_0x3e8bec[_0x415b4d('0x13ee')]+_0x415b4d('0xbf6')+_0x3e8bec['statusText']:_0x415b4d('0x16af'),'msg':_0x3e8bec['data']?JSON[_0x415b4d('0x258a')](_0x3e8bec[_0x415b4d('0x5a5')]):_0x3e8bec[_0x415b4d('0x1ff0')]()});}),_0x3d3b3c[_0x5b251e('0xca1')](_0x5b251e('0x20c2'))?_0x6b28ed[_0x5b251e('0x1990')]['get']({'fields':_0x5b251e('0xa10'),'sort':'id','nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x5a95ab){const _0x588bdf=_0x5b251e;_0x538783[_0x588bdf('0x263c')]=_0x5a95ab[_0x588bdf('0xf5d')]||[];})['catch'](function(_0x340c37){const _0x10bde0=_0x5b251e;_0x203fd9['error']({'title':_0x340c37['status']?'API:'+_0x340c37[_0x10bde0('0x13ee')]+_0x10bde0('0xbf6')+_0x340c37[_0x10bde0('0x24a9')]:'SYSTEM:GET_WHATSAPPACCOUNTS','msg':_0x340c37[_0x10bde0('0x5a5')]?JSON['stringify'](_0x340c37[_0x10bde0('0x5a5')]):_0x340c37[_0x10bde0('0x1ff0')]()});}):_0x6b28ed['whatsappAccount'][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0xa10'),'sort':'id','nolimit':_0x5b251e('0x26ac')})['$promise'][_0x5b251e('0x683')](function(_0x33db6e){const _0x6e8199=_0x5b251e;_0x538783[_0x6e8199('0x263c')]=_0x33db6e[_0x6e8199('0xf5d')]||[];})[_0x5b251e('0x683')](function(){const _0x59de9c=_0x5b251e;return _0x6b28ed[_0x59de9c('0x22df')][_0x59de9c('0x1e6e')]({'userProfileId':_0x538783[_0x59de9c('0x11ed')][_0x59de9c('0x2f')],'sectionId':0x836})[_0x59de9c('0xe53')];})[_0x5b251e('0x683')](function(_0x3dd0a0){const _0x15ff18=_0x5b251e,_0x2106c7=_0x3dd0a0&&_0x3dd0a0['rows']?_0x3dd0a0[_0x15ff18('0xf5d')][0x0]:null;if(!_0x2106c7){const _0x5dc400=[];let _0x39b7c5=null;_0x538783[_0x15ff18('0x179f')]&&(_0x39b7c5=_0x2e3ca0()[_0x15ff18('0x1c07')](_0x538783[_0x15ff18('0x263c')],{'id':Number(_0x538783[_0x15ff18('0x179f')][_0x15ff18('0x1c6b')])}));for(let _0x234fdb=0x0;_0x234fdb<_0x538783['whatsappAccounts']['length'];_0x234fdb++){_0x39b7c5&&_0x538783['whatsappAccounts'][_0x234fdb]['id']===_0x39b7c5['id']&&(_0x538783[_0x15ff18('0x263c')][_0x234fdb]['canSelect']=![],_0x5dc400[_0x15ff18('0x1fd0')](_0x538783[_0x15ff18('0x263c')][_0x234fdb]));}_0x538783[_0x15ff18('0x263c')]=_0x5dc400;}else{if(!_0x2106c7['autoAssociation'])return _0x6b28ed[_0x15ff18('0xcf7')][_0x15ff18('0x1e6e')]({'sectionId':_0x2106c7['id']})[_0x15ff18('0xe53')][_0x15ff18('0x683')](function(_0x19396c){const _0x4ca1b8=_0x15ff18,_0x4070a1=_0x2e3ca0()[_0x4ca1b8('0x386')](_0x19396c[_0x4ca1b8('0xf5d')],function(_0x73e6a){const _0x2b683e=_0x4ca1b8;return _0x2e3ca0()['find'](_0x538783[_0x2b683e('0x263c')],{'id':_0x73e6a[_0x2b683e('0x832')]});});let _0x52d69a=null;_0x538783[_0x4ca1b8('0x179f')]&&(_0x52d69a=_0x2e3ca0()[_0x4ca1b8('0x1c07')](_0x538783[_0x4ca1b8('0x263c')],{'id':Number(_0x538783['allCondition']['value'])}));if(_0x52d69a&&!_0x2e3ca0()[_0x4ca1b8('0x7a2')](_0x4070a1,['id',_0x52d69a['id']])){const _0x5d2ab3=_0x2e3ca0()[_0x4ca1b8('0x1c07')](_0x538783[_0x4ca1b8('0x263c')],{'id':_0x52d69a['id']});_0x5d2ab3[_0x4ca1b8('0x319')]=![],_0x4070a1[_0x4ca1b8('0x1fd0')](_0x5d2ab3);}_0x538783[_0x4ca1b8('0x263c')]=_0x4070a1;});}})[_0x5b251e('0x130a')](function(_0x465881){const _0x16ce75=_0x5b251e;_0x203fd9[_0x16ce75('0x52a')]({'title':_0x465881['status']?_0x16ce75('0x2168')+_0x465881[_0x16ce75('0x13ee')]+_0x16ce75('0xbf6')+_0x465881[_0x16ce75('0x24a9')]:_0x16ce75('0x9ce'),'msg':_0x465881['data']?JSON['stringify'](_0x465881['data']):_0x465881[_0x16ce75('0x1ff0')]()});}),_0x3d3b3c[_0x5b251e('0xca1')]('admin')?_0x6b28ed['faxAccount'][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0xa10'),'sort':'id','nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x54761f){const _0x27efe1=_0x5b251e;_0x538783[_0x27efe1('0x2595')]=_0x54761f[_0x27efe1('0xf5d')]||[];})[_0x5b251e('0x130a')](function(_0xb1446c){const _0x36bde0=_0x5b251e;_0x203fd9[_0x36bde0('0x52a')]({'title':_0xb1446c[_0x36bde0('0x13ee')]?'API:'+_0xb1446c['status']+_0x36bde0('0xbf6')+_0xb1446c[_0x36bde0('0x24a9')]:_0x36bde0('0x9f0'),'msg':_0xb1446c[_0x36bde0('0x5a5')]?JSON[_0x36bde0('0x258a')](_0xb1446c[_0x36bde0('0x5a5')]):_0xb1446c[_0x36bde0('0x1ff0')]()});}):_0x6b28ed[_0x5b251e('0x244a')][_0x5b251e('0x1e6e')]({'fields':'id,name','sort':'id','nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')]['then'](function(_0x55917f){const _0x1c433d=_0x5b251e;_0x538783[_0x1c433d('0x2595')]=_0x55917f[_0x1c433d('0xf5d')]||[];})['then'](function(){const _0x491f75=_0x5b251e;return _0x6b28ed['userProfileSection'][_0x491f75('0x1e6e')]({'userProfileId':_0x538783[_0x491f75('0x11ed')][_0x491f75('0x2f')],'sectionId':0x386})[_0x491f75('0xe53')];})[_0x5b251e('0x683')](function(_0x46c00e){const _0x5d9396=_0x5b251e,_0x3f92d0=_0x46c00e&&_0x46c00e[_0x5d9396('0xf5d')]?_0x46c00e['rows'][0x0]:null;if(!_0x3f92d0){const _0x4b8a30=[];let _0x39b03e=null;_0x538783['allCondition']&&(_0x39b03e=_0x2e3ca0()[_0x5d9396('0x1c07')](_0x538783[_0x5d9396('0x2595')],{'id':Number(_0x538783['allCondition']['value'])}));for(let _0x557925=0x0;_0x557925<_0x538783[_0x5d9396('0x2595')][_0x5d9396('0x1564')];_0x557925++){_0x39b03e&&_0x538783['faxAccounts'][_0x557925]['id']===_0x39b03e['id']&&(_0x538783['faxAccounts'][_0x557925][_0x5d9396('0x319')]=![],_0x4b8a30[_0x5d9396('0x1fd0')](_0x538783[_0x5d9396('0x2595')][_0x557925]));}_0x538783[_0x5d9396('0x2595')]=_0x4b8a30;}else{if(!_0x3f92d0[_0x5d9396('0x170')])return _0x6b28ed['userProfileResource']['get']({'sectionId':_0x3f92d0['id']})[_0x5d9396('0xe53')][_0x5d9396('0x683')](function(_0x405ac1){const _0x5aae0f=_0x5d9396,_0x23d060=_0x2e3ca0()['map'](_0x405ac1[_0x5aae0f('0xf5d')],function(_0x19281c){const _0x4491be=_0x5aae0f;return _0x2e3ca0()[_0x4491be('0x1c07')](_0x538783[_0x4491be('0x2595')],{'id':_0x19281c[_0x4491be('0x832')]});});let _0x12e54c=null;_0x538783[_0x5aae0f('0x179f')]&&(_0x12e54c=_0x2e3ca0()[_0x5aae0f('0x1c07')](_0x538783[_0x5aae0f('0x2595')],{'id':Number(_0x538783[_0x5aae0f('0x179f')][_0x5aae0f('0x1c6b')])}));if(_0x12e54c&&!_0x2e3ca0()['some'](_0x23d060,['id',_0x12e54c['id']])){const _0x39887b=_0x2e3ca0()['find'](_0x538783['faxAccounts'],{'id':_0x12e54c['id']});_0x39887b['canSelect']=![],_0x23d060['push'](_0x39887b);}_0x538783[_0x5aae0f('0x2595')]=_0x23d060;});}})[_0x5b251e('0x130a')](function(_0x9b0ff9){const _0x45fa69=_0x5b251e;_0x203fd9[_0x45fa69('0x52a')]({'title':_0x9b0ff9['status']?'API:'+_0x9b0ff9[_0x45fa69('0x13ee')]+'\x20-\x20'+_0x9b0ff9[_0x45fa69('0x24a9')]:_0x45fa69('0x1842'),'msg':_0x9b0ff9[_0x45fa69('0x5a5')]?JSON[_0x45fa69('0x258a')](_0x9b0ff9[_0x45fa69('0x5a5')]):_0x9b0ff9[_0x45fa69('0x1ff0')]()});}),_0x3d3b3c[_0x5b251e('0xca1')](_0x5b251e('0x20c2'))?_0x6b28ed[_0x5b251e('0x1963')][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0xa10'),'sort':'id','nolimit':'true'})['$promise'][_0x5b251e('0x683')](function(_0x25887f){const _0x285419=_0x5b251e;_0x538783[_0x285419('0x1952')]=_0x25887f[_0x285419('0xf5d')]||[];})['catch'](function(_0x5733c7){const _0x4328e2=_0x5b251e;_0x203fd9[_0x4328e2('0x52a')]({'title':_0x5733c7[_0x4328e2('0x13ee')]?'API:'+_0x5733c7[_0x4328e2('0x13ee')]+_0x4328e2('0xbf6')+_0x5733c7[_0x4328e2('0x24a9')]:_0x4328e2('0x1948'),'msg':_0x5733c7['data']?JSON[_0x4328e2('0x258a')](_0x5733c7[_0x4328e2('0x5a5')]):_0x5733c7[_0x4328e2('0x1ff0')]()});}):_0x6b28ed[_0x5b251e('0x1963')][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0xa10'),'sort':'id','nolimit':'true'})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x28fe0c){const _0x5dab68=_0x5b251e;_0x538783[_0x5dab68('0x1952')]=_0x28fe0c[_0x5dab68('0xf5d')]||[];})[_0x5b251e('0x683')](function(){const _0x15d58e=_0x5b251e;return _0x6b28ed[_0x15d58e('0x22df')][_0x15d58e('0x1e6e')]({'userProfileId':_0x538783[_0x15d58e('0x11ed')][_0x15d58e('0x2f')],'sectionId':0x322})[_0x15d58e('0xe53')];})[_0x5b251e('0x683')](function(_0x5290d0){const _0x3f9465=_0x5b251e,_0x586313=_0x5290d0&&_0x5290d0[_0x3f9465('0xf5d')]?_0x5290d0[_0x3f9465('0xf5d')][0x0]:null;if(!_0x586313){const _0x20774a=[];let _0x1a3ad7=null;_0x538783[_0x3f9465('0x179f')]&&(_0x1a3ad7=_0x2e3ca0()[_0x3f9465('0x1c07')](_0x538783[_0x3f9465('0x1952')],{'id':Number(_0x538783['allCondition'][_0x3f9465('0x1c6b')])}));for(let _0x485889=0x0;_0x485889<_0x538783['openchannelAccounts']['length'];_0x485889++){_0x1a3ad7&&_0x538783[_0x3f9465('0x1952')][_0x485889]['id']===_0x1a3ad7['id']&&(_0x538783[_0x3f9465('0x1952')][_0x485889][_0x3f9465('0x319')]=![],_0x20774a[_0x3f9465('0x1fd0')](_0x538783[_0x3f9465('0x1952')][_0x485889]));}_0x538783[_0x3f9465('0x1952')]=_0x20774a;}else{if(!_0x586313['autoAssociation'])return _0x6b28ed[_0x3f9465('0xcf7')]['get']({'sectionId':_0x586313['id']})[_0x3f9465('0xe53')]['then'](function(_0x25a413){const _0xd28f08=_0x3f9465,_0x2e6a4a=_0x2e3ca0()[_0xd28f08('0x386')](_0x25a413[_0xd28f08('0xf5d')],function(_0x213185){const _0x544c8c=_0xd28f08;return _0x2e3ca0()['find'](_0x538783['openchannelAccounts'],{'id':_0x213185[_0x544c8c('0x832')]});});let _0x72592f=null;_0x538783['allCondition']&&(_0x72592f=_0x2e3ca0()[_0xd28f08('0x1c07')](_0x538783[_0xd28f08('0x1952')],{'id':Number(_0x538783[_0xd28f08('0x179f')][_0xd28f08('0x1c6b')])}));if(_0x72592f&&!_0x2e3ca0()['some'](_0x2e6a4a,['id',_0x72592f['id']])){const _0xef61=_0x2e3ca0()['find'](_0x538783[_0xd28f08('0x1952')],{'id':_0x72592f['id']});_0xef61[_0xd28f08('0x319')]=![],_0x2e6a4a['push'](_0xef61);}_0x538783[_0xd28f08('0x1952')]=_0x2e6a4a;});}})[_0x5b251e('0x130a')](function(_0x59c9ad){const _0x35394b=_0x5b251e;_0x203fd9[_0x35394b('0x52a')]({'title':_0x59c9ad['status']?_0x35394b('0x2168')+_0x59c9ad[_0x35394b('0x13ee')]+_0x35394b('0xbf6')+_0x59c9ad[_0x35394b('0x24a9')]:_0x35394b('0xf5a'),'msg':_0x59c9ad[_0x35394b('0x5a5')]?JSON[_0x35394b('0x258a')](_0x59c9ad[_0x35394b('0x5a5')]):_0x59c9ad[_0x35394b('0x1ff0')]()});});const _0x167160=[{'id':0x191,'type':_0x5b251e('0x1535')},{'id':0x5dd,'type':_0x5b251e('0x17cd')}];let _0x529f85=null;_0x3d3b3c[_0x5b251e('0xca1')](_0x5b251e('0x20c2'))?_0x6b28ed[_0x5b251e('0x204c')][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0x2035'),'sort':_0x5b251e('0x60a'),'nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x10b15f){const _0x2ab145=_0x5b251e;_0x538783[_0x2ab145('0x2da')]=_0x10b15f['rows']||[];})[_0x5b251e('0x130a')](function(_0x1dd83a){const _0x36dc51=_0x5b251e;_0x203fd9[_0x36dc51('0x52a')]({'title':_0x1dd83a['status']?_0x36dc51('0x2168')+_0x1dd83a['status']+'\x20-\x20'+_0x1dd83a[_0x36dc51('0x24a9')]:_0x36dc51('0x22dc'),'msg':_0x1dd83a[_0x36dc51('0x5a5')]?JSON[_0x36dc51('0x258a')](_0x1dd83a[_0x36dc51('0x5a5')]):_0x1dd83a[_0x36dc51('0x1ff0')]()});}):_0x6b28ed[_0x5b251e('0x204c')][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0x2035'),'sort':_0x5b251e('0x60a'),'nolimit':'true'})[_0x5b251e('0xe53')]['then'](function(_0x383a64){const _0x103976=_0x5b251e;_0x529f85=_0x383a64[_0x103976('0xf5d')]||[];})[_0x5b251e('0x683')](function(){const _0x43e519=_0x5b251e,_0x53efb5=[];for(let _0x2b3442=0x0;_0x2b3442<_0x167160[_0x43e519('0x1564')];_0x2b3442++){_0x53efb5[_0x43e519('0x1fd0')](_0x6b28ed[_0x43e519('0x22df')][_0x43e519('0x1e6e')]({'userProfileId':_0x538783[_0x43e519('0x11ed')]['userProfileId'],'sectionId':_0x167160[_0x2b3442]['id']})[_0x43e519('0xe53')]);}return _0x96c539[_0x43e519('0x252c')](_0x53efb5);})[_0x5b251e('0x683')](function(_0xff5bf3){const _0x12e564=_0x5b251e,_0x38a5f2=_0x2e3ca0()[_0x12e564('0x386')](_0xff5bf3,function(_0x28c604){const _0x2e9158=_0x12e564;return _0x28c604&&_0x28c604[_0x2e9158('0xf5d')]?_0x28c604['rows'][0x0]:null;}),_0x17b1c2=[];for(let _0xb423f0=0x0;_0xb423f0<_0x167160['length'];_0xb423f0++){const _0x4e7be5=_0x2e3ca0()[_0x12e564('0x1c07')](_0x38a5f2,['sectionId',_0x167160[_0xb423f0]['id']]);if(_0x4e7be5){if(!_0x4e7be5[_0x12e564('0x170')])_0x17b1c2[_0x12e564('0x1fd0')](_0x6b28ed['userProfileResource'][_0x12e564('0x1e6e')]({'sectionId':_0x4e7be5['id']})[_0x12e564('0xe53')]);else{const _0x4d3aff=[];_0x529f85[_0x12e564('0x1299')](function(_0x5d1f32){const _0x21843b=_0x12e564;_0x5d1f32[_0x21843b('0xcf0')]===_0x167160[_0xb423f0]['type']&&_0x4d3aff[_0x21843b('0x1fd0')](_0x5d1f32);}),_0x17b1c2[_0x12e564('0x1fd0')]({'rows':_0x4d3aff,'count':_0x4d3aff[_0x12e564('0x1564')]});}}}return _0x96c539[_0x12e564('0x252c')](_0x17b1c2);})[_0x5b251e('0x683')](function(_0x1a6015){const _0x3821e9=_0x5b251e,_0x5dda34=[];let _0x2196a1=null;_0x538783[_0x3821e9('0x179f')]&&(_0x2196a1=_0x2e3ca0()[_0x3821e9('0x1c07')](_0x529f85,{'name':_0x538783[_0x3821e9('0x179f')]['value']}));for(let _0x301473=0x0;_0x301473<_0x1a6015[_0x3821e9('0x1564')];_0x301473++){const _0x3b07bf=_0x1a6015[_0x301473]['rows']||[];_0x3b07bf[_0x3821e9('0x1299')](function(_0x4a2f81){const _0x13d8e6=_0x3821e9;_0x5dda34[_0x13d8e6('0x1fd0')](_0x4a2f81);});}_0x2196a1&&!_0x2e3ca0()['some'](_0x5dda34,['resourceId',_0x2196a1['id']])&&_0x529f85[_0x3821e9('0x1299')](function(_0x75b188){const _0x58890f=_0x3821e9;_0x75b188['id']===_0x2196a1['id']&&(_0x75b188[_0x58890f('0x319')]=![],_0x5dda34[_0x58890f('0x1fd0')](_0x75b188));}),_0x538783[_0x3821e9('0x2da')]=_0x5dda34;})[_0x5b251e('0x130a')](function(_0x25a5d7){const _0x15b280=_0x5b251e;_0x203fd9[_0x15b280('0x52a')]({'title':_0x25a5d7[_0x15b280('0x13ee')]?'API:'+_0x25a5d7[_0x15b280('0x13ee')]+_0x15b280('0xbf6')+_0x25a5d7[_0x15b280('0x24a9')]:'SYSTEM:GETqueues','msg':_0x25a5d7[_0x15b280('0x5a5')]?JSON[_0x15b280('0x258a')](_0x25a5d7['data']):_0x25a5d7['toString']()});}),_0x3d3b3c[_0x5b251e('0xca1')](_0x5b251e('0x20c2'))?_0x6b28ed[_0x5b251e('0x14cb')]['get']({'fields':_0x5b251e('0x5c6'),'type':'outbound','VoiceExtensionId':_0x5b251e('0x13c'),'nolimit':_0x5b251e('0x26ac')})['$promise']['then'](function(_0x4f50b3){const _0x9932c4=_0x5b251e;_0x538783[_0x9932c4('0x871')]=_0x4f50b3['rows']||[];})[_0x5b251e('0x130a')](function(_0x3f43ad){const _0x530ed0=_0x5b251e;_0x203fd9[_0x530ed0('0x52a')]({'title':_0x3f43ad[_0x530ed0('0x13ee')]?_0x530ed0('0x2168')+_0x3f43ad[_0x530ed0('0x13ee')]+_0x530ed0('0xbf6')+_0x3f43ad[_0x530ed0('0x24a9')]:_0x530ed0('0xaf8'),'msg':_0x3f43ad[_0x530ed0('0x5a5')]?JSON['stringify'](_0x3f43ad[_0x530ed0('0x5a5')]):_0x3f43ad[_0x530ed0('0x1ff0')]()});}):_0x6b28ed[_0x5b251e('0x14cb')]['get']({'fields':_0x5b251e('0x5c6'),'type':_0x5b251e('0x17cd'),'VoiceExtensionId':_0x5b251e('0x13c'),'nolimit':_0x5b251e('0x26ac')})['$promise'][_0x5b251e('0x683')](function(_0x116edb){const _0x9445e9=_0x5b251e;_0x538783[_0x9445e9('0x871')]=_0x116edb[_0x9445e9('0xf5d')]||[];})[_0x5b251e('0x683')](function(){const _0x3decfd=_0x5b251e;return _0x6b28ed[_0x3decfd('0x22df')][_0x3decfd('0x1e6e')]({'userProfileId':_0x538783['currentUser']['userProfileId'],'sectionId':0x193})[_0x3decfd('0xe53')];})[_0x5b251e('0x683')](function(_0x212e82){const _0x4f668f=_0x5b251e,_0x431fad=_0x212e82&&_0x212e82[_0x4f668f('0xf5d')]?_0x212e82[_0x4f668f('0xf5d')][0x0]:null;if(!_0x431fad){const _0x23d66a=[];let _0x5c0f4e=null;_0x538783['allCondition']&&(_0x5c0f4e=_0x2e3ca0()[_0x4f668f('0x1c07')](_0x538783['outboundRoutes'],{'id':Number(_0x538783[_0x4f668f('0x179f')]['value'])}));for(let _0x3b33d0=0x0;_0x3b33d0<_0x538783[_0x4f668f('0x871')][_0x4f668f('0x1564')];_0x3b33d0++){_0x5c0f4e&&_0x538783['outboundRoutes'][_0x3b33d0]['id']===_0x5c0f4e['id']&&(_0x538783['outboundRoutes'][_0x3b33d0]['canSelect']=![],_0x23d66a[_0x4f668f('0x1fd0')](_0x538783['outboundRoutes'][_0x3b33d0]));}_0x538783[_0x4f668f('0x871')]=_0x23d66a;}else{if(!_0x431fad[_0x4f668f('0x170')])return _0x6b28ed['userProfileResource'][_0x4f668f('0x1e6e')]({'sectionId':_0x431fad['id']})[_0x4f668f('0xe53')]['then'](function(_0x575f2f){const _0x32ad82=_0x4f668f,_0x59b0d2=_0x2e3ca0()['map'](_0x575f2f[_0x32ad82('0xf5d')],function(_0x392fbf){const _0x1a55f5=_0x32ad82;return _0x2e3ca0()[_0x1a55f5('0x1c07')](_0x538783[_0x1a55f5('0x871')],{'id':_0x392fbf[_0x1a55f5('0x832')]});});let _0x4af2a9=null;_0x538783['allCondition']&&(_0x4af2a9=_0x2e3ca0()[_0x32ad82('0x1c07')](_0x538783[_0x32ad82('0x871')],{'id':Number(_0x538783[_0x32ad82('0x179f')][_0x32ad82('0x1c6b')])}));if(_0x4af2a9&&!_0x2e3ca0()[_0x32ad82('0x7a2')](_0x59b0d2,['id',_0x4af2a9['id']])){const _0x1b3d4b=_0x2e3ca0()['find'](_0x538783[_0x32ad82('0x871')],{'id':_0x4af2a9['id']});_0x1b3d4b['canSelect']=![],_0x59b0d2[_0x32ad82('0x1fd0')](_0x1b3d4b);}_0x538783['outboundRoutes']=_0x59b0d2;});}})[_0x5b251e('0x130a')](function(_0x3d1bf6){const _0x337083=_0x5b251e;_0x203fd9[_0x337083('0x52a')]({'title':_0x3d1bf6[_0x337083('0x13ee')]?_0x337083('0x2168')+_0x3d1bf6[_0x337083('0x13ee')]+'\x20-\x20'+_0x3d1bf6['statusText']:_0x337083('0x79d'),'msg':_0x3d1bf6[_0x337083('0x5a5')]?JSON[_0x337083('0x258a')](_0x3d1bf6[_0x337083('0x5a5')]):_0x3d1bf6[_0x337083('0x1ff0')]()});}),_0x3d3b3c[_0x5b251e('0xca1')](_0x5b251e('0x20c2'))?_0x6b28ed['user'][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0x2686'),'sort':'name','role':_0x5b251e('0x2327'),'nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x3d3a31){const _0x769447=_0x5b251e;_0x538783[_0x769447('0x756')]=_0x3d3a31['rows']||[];})[_0x5b251e('0x130a')](function(_0x317967){const _0x291bec=_0x5b251e;_0x203fd9[_0x291bec('0x52a')]({'title':_0x317967['status']?'API:'+_0x317967['status']+_0x291bec('0xbf6')+_0x317967[_0x291bec('0x24a9')]:_0x291bec('0x144f'),'msg':_0x317967[_0x291bec('0x5a5')]?JSON[_0x291bec('0x258a')](_0x317967[_0x291bec('0x5a5')]):_0x317967[_0x291bec('0x1ff0')]()});}):_0x6b28ed[_0x5b251e('0xc96')][_0x5b251e('0x1e6e')]({'fields':_0x5b251e('0x2686'),'sort':_0x5b251e('0x60a'),'role':_0x5b251e('0x2327'),'nolimit':_0x5b251e('0x26ac')})[_0x5b251e('0xe53')][_0x5b251e('0x683')](function(_0x197671){const _0x15582b=_0x5b251e;_0x538783[_0x15582b('0x756')]=_0x197671[_0x15582b('0xf5d')]||[];})[_0x5b251e('0x683')](function(){const _0x19385a=_0x5b251e;return _0x6b28ed['userProfileSection'][_0x19385a('0x1e6e')]({'userProfileId':_0x538783[_0x19385a('0x11ed')][_0x19385a('0x2f')],'sectionId':0xca})[_0x19385a('0xe53')];})[_0x5b251e('0x683')](function(_0x4b3949){const _0x3057ab=_0x5b251e,_0x16e1e6=_0x4b3949&&_0x4b3949[_0x3057ab('0xf5d')]?_0x4b3949['rows'][0x0]:null;if(!_0x16e1e6){const _0x15fc88=[];let _0x51aa26=null;_0x538783[_0x3057ab('0x179f')]&&(_0x51aa26=_0x2e3ca0()[_0x3057ab('0x1c07')](_0x538783[_0x3057ab('0x756')],{'name':_0x538783['allCondition'][_0x3057ab('0x1c6b')]}));for(let _0x3053ee=0x0;_0x3053ee<_0x538783[_0x3057ab('0x756')][_0x3057ab('0x1564')];_0x3053ee++){_0x51aa26&&_0x538783['agents'][_0x3053ee]['id']===_0x51aa26['id']&&(_0x538783[_0x3057ab('0x756')][_0x3053ee][_0x3057ab('0x319')]=![],_0x15fc88['push'](_0x538783[_0x3057ab('0x756')][_0x3053ee]));}_0x538783[_0x3057ab('0x756')]=_0x15fc88;}else{if(!_0x16e1e6[_0x3057ab('0x170')])return _0x6b28ed[_0x3057ab('0xcf7')]['get']({'sectionId':_0x16e1e6['id']})[_0x3057ab('0xe53')][_0x3057ab('0x683')](function(_0x15a51a){const _0x151bbe=_0x3057ab,_0x144e9c=_0x2e3ca0()[_0x151bbe('0x386')](_0x15a51a[_0x151bbe('0xf5d')],function(_0x1cf878){const _0x3dd792=_0x151bbe;return _0x2e3ca0()['find'](_0x538783[_0x3dd792('0x756')],{'id':_0x1cf878[_0x3dd792('0x832')]});});let _0x3074a6=null;_0x538783[_0x151bbe('0x179f')]&&(_0x3074a6=_0x2e3ca0()[_0x151bbe('0x1c07')](_0x538783['agents'],{'name':_0x538783[_0x151bbe('0x179f')]['value']}));if(_0x3074a6&&!_0x2e3ca0()[_0x151bbe('0x7a2')](_0x144e9c,['id',_0x3074a6['id']])){const _0x42f3c7=_0x2e3ca0()['find'](_0x538783[_0x151bbe('0x756')],{'id':_0x3074a6['id']});_0x42f3c7['canSelect']=![],_0x144e9c[_0x151bbe('0x1fd0')](_0x42f3c7);}_0x538783[_0x151bbe('0x756')]=_0x144e9c;});}})[_0x5b251e('0x130a')](function(_0x36fad3){const _0xeac47=_0x5b251e;_0x203fd9[_0xeac47('0x52a')]({'title':_0x36fad3[_0xeac47('0x13ee')]?_0xeac47('0x2168')+_0x36fad3[_0xeac47('0x13ee')]+_0xeac47('0xbf6')+_0x36fad3[_0xeac47('0x24a9')]:_0xeac47('0x391'),'msg':_0x36fad3['data']?JSON['stringify'](_0x36fad3['data']):_0x36fad3['toString']()});});function _0x17bd13(){const _0x29f70f=_0x5b251e;_0x538783[_0x29f70f('0x17f')]=[],_0x6b28ed['trigger'][_0x29f70f('0xc8f')]({'id':_0x4d11e1['params']['id']},_0x538783['allCondition'])[_0x29f70f('0xe53')]['then'](function(_0x438c3c){const _0x3b593d=_0x29f70f;_0x538783['allconditions'][_0x3b593d('0x1167')](_0x438c3c[_0x3b593d('0x24e1')]()),_0x203fd9[_0x3b593d('0x53')]({'title':_0x3b593d('0xedc'),'msg':_0x538783['allCondition'][_0x3b593d('0x60a')]?_0x538783[_0x3b593d('0x179f')][_0x3b593d('0x60a')]+'\x20has\x20been\x20created!':''}),_0x60200b(_0x438c3c);})[_0x29f70f('0x130a')](function(_0x1d3f92){const _0x5c0753=_0x29f70f;if(_0x1d3f92['data']&&_0x1d3f92[_0x5c0753('0x5a5')][_0x5c0753('0x17f')]&&_0x1d3f92[_0x5c0753('0x5a5')][_0x5c0753('0x17f')][_0x5c0753('0x1564')]){_0x538783['errors']=_0x1d3f92['data']['errors']||[{'message':_0x1d3f92[_0x5c0753('0x1ff0')](),'type':_0x5c0753('0x2821')}];for(let _0x5b8faa=0x0;_0x5b8faa<_0x1d3f92['data'][_0x5c0753('0x17f')][_0x5c0753('0x1564')];_0x5b8faa+=0x1){_0x203fd9[_0x5c0753('0x52a')]({'title':_0x1d3f92[_0x5c0753('0x5a5')][_0x5c0753('0x17f')][_0x5b8faa][_0x5c0753('0xcf0')],'msg':_0x1d3f92[_0x5c0753('0x5a5')][_0x5c0753('0x17f')][_0x5b8faa][_0x5c0753('0x8c2')]});}}else _0x203fd9[_0x5c0753('0x52a')]({'title':_0x1d3f92[_0x5c0753('0x13ee')]?_0x5c0753('0x2168')+_0x1d3f92[_0x5c0753('0x13ee')]+_0x5c0753('0xbf6')+_0x1d3f92['statusText']:'api.condition.save','msg':_0x1d3f92[_0x5c0753('0x5a5')]?JSON['stringify'](_0x1d3f92[_0x5c0753('0x5a5')]['message']):_0x1d3f92[_0x5c0753('0x1ff0')]()});});}function _0x191c13(){const _0x5cb7ec=_0x5b251e;_0x538783[_0x5cb7ec('0x17f')]=[],_0x6b28ed['condition'][_0x5cb7ec('0x2480')]({'id':_0x538783[_0x5cb7ec('0x179f')]['id']},_0x538783[_0x5cb7ec('0x179f')])['$promise']['then'](function(_0x5a4dfc){const _0x1d824f=_0x5cb7ec,_0x365741=_0x2e3ca0()['find'](_0x538783['allconditions'],{'id':_0x5a4dfc['id']});_0x365741&&_0x2e3ca0()[_0x1d824f('0xf22')](_0x365741,_0x2e3ca0()[_0x1d824f('0x24d0')](_0x5a4dfc[_0x1d824f('0x24e1')](),_0x2e3ca0()[_0x1d824f('0x55e')](_0x365741))),_0x203fd9[_0x1d824f('0x53')]({'title':'AllCondition\x20properly\x20saved!','msg':_0x538783[_0x1d824f('0x179f')][_0x1d824f('0x60a')]?_0x538783['allCondition'][_0x1d824f('0x60a')]+_0x1d824f('0xf59'):''}),_0x60200b(_0x5a4dfc);})[_0x5cb7ec('0x130a')](function(_0x4d9007){const _0x5025cb=_0x5cb7ec;if(_0x4d9007[_0x5025cb('0x5a5')]&&_0x4d9007[_0x5025cb('0x5a5')][_0x5025cb('0x17f')]&&_0x4d9007[_0x5025cb('0x5a5')][_0x5025cb('0x17f')][_0x5025cb('0x1564')]){_0x538783[_0x5025cb('0x17f')]=_0x4d9007[_0x5025cb('0x5a5')][_0x5025cb('0x17f')]||[{'message':_0x4d9007['toString'](),'type':'api.condition.update'}];for(let _0x3a3c2a=0x0;_0x3a3c2a<_0x4d9007[_0x5025cb('0x5a5')][_0x5025cb('0x17f')][_0x5025cb('0x1564')];_0x3a3c2a++){_0x203fd9['error']({'title':_0x4d9007[_0x5025cb('0x5a5')][_0x5025cb('0x17f')][_0x3a3c2a]['type'],'msg':_0x4d9007['data'][_0x5025cb('0x17f')][_0x3a3c2a]['message']});}}else _0x203fd9[_0x5025cb('0x52a')]({'title':_0x4d9007[_0x5025cb('0x13ee')]?_0x5025cb('0x2168')+_0x4d9007[_0x5025cb('0x13ee')]+_0x5025cb('0xbf6')+_0x4d9007[_0x5025cb('0x24a9')]:_0x5025cb('0x55f'),'msg':_0x4d9007[_0x5025cb('0x5a5')]?JSON[_0x5025cb('0x258a')](_0x4d9007[_0x5025cb('0x5a5')][_0x5025cb('0x8c2')]):_0x4d9007[_0x5025cb('0x1ff0')]()});});}function _0x2ea878(_0x47e6e9){const _0x1daf23=_0x5b251e;_0x538783['errors']=[];const _0x34cbe5=_0x4950ac[_0x1daf23('0x1c6f')]()['title'](_0x1daf23('0x4d'))['content']('The\x20allCondition\x20will\x20be\x20deleted.')['ariaLabel']('Delete\x20AllCondition')['ok'](_0x1daf23('0x2307'))['cancel']('Cancel')[_0x1daf23('0xe42')](_0x47e6e9);_0x4950ac['show'](_0x34cbe5)[_0x1daf23('0x683')](function(){const _0x24c1cf=_0x1daf23;_0x6b28ed[_0x24c1cf('0x168e')]['delete']({'id':_0x538783['allCondition']['id']})['$promise'][_0x24c1cf('0x683')](function(){const _0x23bf72=_0x24c1cf;_0x2e3ca0()[_0x23bf72('0x3ec')](_0x538783['allconditions'],{'id':_0x538783[_0x23bf72('0x179f')]['id']}),_0x203fd9[_0x23bf72('0x53')]({'title':_0x23bf72('0x1158'),'msg':(_0x538783[_0x23bf72('0x179f')][_0x23bf72('0x60a')]||_0x23bf72('0x179f'))+_0x23bf72('0x194d')}),_0x60200b(_0x538783[_0x23bf72('0x179f')]);})[_0x24c1cf('0x130a')](function(_0x2db6b9){const _0x1e2608=_0x24c1cf;if(_0x2db6b9[_0x1e2608('0x5a5')]&&_0x2db6b9[_0x1e2608('0x5a5')]['errors']&&_0x2db6b9[_0x1e2608('0x5a5')][_0x1e2608('0x17f')][_0x1e2608('0x1564')]){_0x538783[_0x1e2608('0x17f')]=_0x2db6b9[_0x1e2608('0x5a5')][_0x1e2608('0x17f')]||[{'message':_0x2db6b9[_0x1e2608('0x1ff0')](),'type':_0x1e2608('0x1be3')}];for(let _0x2f5d47=0x0;_0x2f5d47<_0x2db6b9[_0x1e2608('0x5a5')][_0x1e2608('0x17f')][_0x1e2608('0x1564')];_0x2f5d47++){_0x203fd9[_0x1e2608('0x52a')]({'title':_0x2db6b9[_0x1e2608('0x5a5')][_0x1e2608('0x17f')][_0x2f5d47]['type'],'msg':_0x2db6b9[_0x1e2608('0x5a5')][_0x1e2608('0x17f')][_0x2f5d47][_0x1e2608('0x8c2')]});}}else _0x203fd9[_0x1e2608('0x52a')]({'title':_0x2db6b9[_0x1e2608('0x13ee')]?'API:'+_0x2db6b9[_0x1e2608('0x13ee')]+'\x20-\x20'+_0x2db6b9[_0x1e2608('0x24a9')]:'api.condition.delete','msg':_0x2db6b9['data']?JSON[_0x1e2608('0x258a')](_0x2db6b9[_0x1e2608('0x5a5')]['message']):_0x2db6b9[_0x1e2608('0x8c2')]||_0x2db6b9[_0x1e2608('0x1ff0')]()});});},function(){});}function _0x4b8330(_0x21dced){return _0x21dced===null?undefined:new Date(_0x21dced);}function _0x60200b(_0x57ff5e){const _0x2d7d0c=_0x5b251e;_0x4950ac[_0x2d7d0c('0x1715')](_0x57ff5e);}}const _0x5724f5=_0x112331,_0x5a9aed=_0x180212['p']+_0x189033('0x11cc');_0xb11613['$inject']=[_0x189033('0x7a5'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),'toasty',_0x189033('0x56b'),_0x189033('0xba1')];function _0xb11613(_0x412bfb,_0x4858e7,_0x29bf08,_0x27f412,_0x3546ec,_0x5181e2,_0x59a717,_0x2caf2d,_0xa6a7ec){const _0x2f4be8=_0x189033,_0x2be59d=this;_0x2be59d['currentUser']=_0xa6a7ec[_0x2f4be8('0x20b2')](),_0x2be59d[_0x2f4be8('0x25e2')]={},_0x2be59d['triggerAnyConditions']={'count':0x0,'rows':[]},_0x2be59d[_0x2f4be8('0x2b7')]=[],_0x2be59d['query']={'fields':_0x2f4be8('0x1e80'),'limit':0xa,'page':0x1},_0x2be59d[_0x2f4be8('0x189a')]={'queue':'Queue','lastevent':_0x2f4be8('0x1258'),'routeId':_0x2f4be8('0x19c3'),'agent':'Agent','account':_0x2f4be8('0xa78'),'interaction':_0x2f4be8('0x1896'),'message':_0x2f4be8('0x205e')},_0x2be59d[_0x2f4be8('0x17d7')]={'abandoned':'Abandon','timeout':_0x2f4be8('0xa09'),'complete':_0x2f4be8('0x614'),'rejected':'Reject','called':_0x2f4be8('0x1a67'),'connect':'Answer','nosuchnumber':'NoSuchNumber','busy':_0x2f4be8('0x2630'),'noanswer':_0x2f4be8('0x25be'),'congestion':_0x2f4be8('0x2094'),'agentreject':_0x2f4be8('0x3cf')},_0x2be59d[_0x2f4be8('0x1f48')]={'in':'Incoming','out':'Outgoing','accept':_0x2f4be8('0x519'),'reject':_0x2f4be8('0x22c4')},_0x2be59d[_0x2f4be8('0x1dd2')]=_0x304358,_0x2be59d['success']=_0x179cd1,_0x2be59d[_0x2f4be8('0xd82')]=_0x433b10,_0x2be59d[_0x2f4be8('0x11a2')]=_0x2a1c1b,_0x2be59d[_0x2f4be8('0x153e')]=_0xeefa3f,_0x2be59d[_0x2f4be8('0x26eb')]=_0x2ab8d1,_0x2be59d[_0x2f4be8('0x23a0')]=_0x37627d,_0x2be59d[_0x2f4be8('0x1d49')]=_0x2b3e48;function _0x304358(_0x371ef3,_0x2294c0){const _0x3a0134=_0x2f4be8;_0x2be59d[_0x3a0134('0x25e2')]=_0x371ef3,_0x2be59d[_0x3a0134('0x1134')]=typeof _0x2294c0!==_0x3a0134('0x1867')?_0x2294c0:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x2be59d['query']['TriggerAnyId']=_0x2be59d['trigger']['id'],_0x2be59d[_0x3a0134('0x23a2')]['id']=_0x2be59d['trigger']['id'],_0x433b10();}function _0x5158af(){const _0x406956=_0x2f4be8,_0x39099d=_0x2be59d['trigger'][_0x406956('0xdd6')]+_0x2be59d[_0x406956('0x25e2')][_0x406956('0xdd6')]===_0x406956('0x24e')?_0x406956('0x25e7'):_0x406956('0x2059'),_0x4f950e=_0x2be59d[_0x406956('0x25e2')]['channel']+(_0x2be59d[_0x406956('0x25e2')][_0x406956('0xdd6')]==='chat'?_0x406956('0xe4c'):'Account');let _0x320c14;switch(_0x2be59d[_0x406956('0x25e2')]['channel']){case _0x406956('0x24e'):_0x320c14=0x1f6;break;case'fax':_0x320c14=0x386;break;case _0x406956('0x129f'):_0x320c14=0x25a;break;case'openchannel':_0x320c14=0x322;break;case'sms':_0x320c14=0x2be;break;case _0x406956('0x16e7'):_0x320c14=0x836;break;}if(_0xa6a7ec[_0x406956('0x1d32')]()){const _0x135c72=_0x2be59d['trigger'][_0x406956('0xdd6')];_0x2caf2d[_0x4f950e]['get']({'fields':_0x406956('0xa10'),'sort':'id','nolimit':_0x406956('0x26ac')})[_0x406956('0xe53')][_0x406956('0x683')](function(_0x21750a){const _0x3cc345=_0x406956;_0x2be59d[_0x39099d]=_0x21750a[_0x3cc345('0xf5d')]||[];})[_0x406956('0x130a')](function(_0x47475d){const _0x538f7a=_0x406956;_0x59a717[_0x538f7a('0x52a')]({'title':_0x47475d[_0x538f7a('0x13ee')]?_0x538f7a('0x2168')+_0x47475d['status']+_0x538f7a('0xbf6')+_0x47475d[_0x538f7a('0x24a9')]:_0x538f7a('0xf4a')+_0x135c72[_0x538f7a('0x80')]()+_0x135c72===_0x538f7a('0x24e')?'WEBSITES':'ACCOUNTS','msg':_0x47475d[_0x538f7a('0x5a5')]?JSON[_0x538f7a('0x258a')](_0x47475d[_0x538f7a('0x5a5')]):_0x47475d['toString']()});});}else{const _0x42804b=_0x2be59d['trigger'][_0x406956('0xdd6')];_0x2caf2d[_0x4f950e]['get']({'fields':_0x406956('0xa10'),'sort':'id','nolimit':_0x406956('0x26ac')})[_0x406956('0xe53')][_0x406956('0x683')](function(_0x4538bd){const _0x1c7ee4=_0x406956;_0x2be59d[_0x39099d]=_0x4538bd[_0x1c7ee4('0xf5d')]||[];})[_0x406956('0x683')](function(){const _0x4a17fb=_0x406956;return _0x2caf2d[_0x4a17fb('0x22df')][_0x4a17fb('0x1e6e')]({'userProfileId':_0x2be59d[_0x4a17fb('0x11ed')][_0x4a17fb('0x2f')],'sectionId':_0x320c14})[_0x4a17fb('0xe53')];})['then'](function(_0x45de56){const _0x2ecae5=_0x406956,_0x332784=_0x45de56&&_0x45de56[_0x2ecae5('0xf5d')]?_0x45de56[_0x2ecae5('0xf5d')][0x0]:null;if(!_0x332784){const _0x3db8f5=[],_0x459956=[];_0x2be59d[_0x2ecae5('0x1c3f')][_0x2ecae5('0xf5d')][_0x2ecae5('0x1299')](function(_0x4143d3){const _0x47aca3=_0x2ecae5;if(_0x4143d3[_0x47aca3('0x2013')]==='account'){const _0x479869=_0x2e3ca0()[_0x47aca3('0x1c07')](_0x2be59d[_0x39099d],{'id':Number(_0x4143d3[_0x47aca3('0x1c6b')])});_0x459956[_0x47aca3('0x1fd0')](_0x479869);}});for(let _0x5e3f86=0x0;_0x5e3f86<_0x2be59d[_0x39099d][_0x2ecae5('0x1564')];_0x5e3f86++){const _0x293a2c=_0x2e3ca0()[_0x2ecae5('0x7a2')](_0x459956,{'id':_0x2be59d[_0x39099d][_0x5e3f86]['id']});_0x293a2c&&(_0x2be59d[_0x39099d][_0x5e3f86][_0x2ecae5('0x319')]=![],_0x3db8f5[_0x2ecae5('0x1fd0')](_0x2be59d[_0x39099d][_0x5e3f86]));}_0x2be59d[_0x39099d]=_0x3db8f5;}else{if(!_0x332784[_0x2ecae5('0x170')])return _0x2caf2d['userProfileResource'][_0x2ecae5('0x1e6e')]({'sectionId':_0x332784['id']})[_0x2ecae5('0xe53')]['then'](function(_0x1e3769){const _0x6f1468=_0x2ecae5,_0x5682c7=_0x2e3ca0()['map'](_0x1e3769[_0x6f1468('0xf5d')],function(_0x32dfa4){const _0x2cd31f=_0x6f1468;return _0x2e3ca0()[_0x2cd31f('0x1c07')](_0x2be59d[_0x39099d],{'id':_0x32dfa4['resourceId']});});let _0x22330f=null;_0x22330f=[],_0x2be59d['triggerAnyConditions'][_0x6f1468('0xf5d')][_0x6f1468('0x1299')](function(_0x1e22df){const _0x9ea7fe=_0x6f1468;if(_0x1e22df[_0x9ea7fe('0x2013')]==='account'){const _0x2bc006=_0x2e3ca0()[_0x9ea7fe('0x1c07')](_0x2be59d[_0x39099d],{'id':Number(_0x1e22df[_0x9ea7fe('0x1c6b')])});_0x22330f['push'](_0x2bc006);}}),!_0x2e3ca0()['isEmpty'](_0x22330f)&&_0x22330f[_0x6f1468('0x1299')](function(_0x458eb3){const _0x15a0a3=_0x6f1468;if(!_0x2e3ca0()[_0x15a0a3('0x7a2')](_0x5682c7,['id',_0x458eb3['id']])){const _0x1c6d66=_0x2e3ca0()[_0x15a0a3('0x1c07')](_0x2be59d[_0x39099d],{'id':_0x458eb3['id']});_0x1c6d66[_0x15a0a3('0x319')]=![],_0x5682c7[_0x15a0a3('0x1fd0')](_0x1c6d66);}}),_0x2be59d[_0x39099d]=_0x5682c7;});}})['catch'](function(_0x1ce229){const _0x1d0706=_0x406956;_0x59a717[_0x1d0706('0x52a')]({'title':_0x1ce229[_0x1d0706('0x13ee')]?_0x1d0706('0x2168')+_0x1ce229[_0x1d0706('0x13ee')]+_0x1d0706('0xbf6')+_0x1ce229['statusText']:_0x1d0706('0xf4a')+_0x42804b[_0x1d0706('0x80')]()+_0x42804b===_0x1d0706('0x24e')?_0x1d0706('0x1327'):_0x1d0706('0x597'),'msg':_0x1ce229[_0x1d0706('0x5a5')]?JSON[_0x1d0706('0x258a')](_0x1ce229[_0x1d0706('0x5a5')]):_0x1ce229[_0x1d0706('0x1ff0')]()});});}}function _0xe45f56(){const _0x13ed15=_0x2f4be8,_0x4b1e2f=[{'id':0x191,'type':_0x13ed15('0x1535')},{'id':0x5dd,'type':_0x13ed15('0x17cd')}];let _0x421d72=null;_0xa6a7ec[_0x13ed15('0x1d32')]()?_0x2caf2d[_0x13ed15('0x204c')][_0x13ed15('0x1e6e')]({'fields':_0x13ed15('0x2035'),'sort':_0x13ed15('0x60a'),'nolimit':'true'})[_0x13ed15('0xe53')][_0x13ed15('0x683')](function(_0x38c99e){const _0x520475=_0x13ed15;_0x2be59d['queues']=_0x38c99e[_0x520475('0xf5d')]||[];})[_0x13ed15('0x130a')](function(_0x2570a8){const _0x478df9=_0x13ed15;_0x59a717[_0x478df9('0x52a')]({'title':_0x2570a8[_0x478df9('0x13ee')]?_0x478df9('0x2168')+_0x2570a8['status']+_0x478df9('0xbf6')+_0x2570a8[_0x478df9('0x24a9')]:_0x478df9('0x15f3'),'msg':_0x2570a8[_0x478df9('0x5a5')]?JSON[_0x478df9('0x258a')](_0x2570a8[_0x478df9('0x5a5')]):_0x2570a8[_0x478df9('0x1ff0')]()});}):_0x2caf2d[_0x13ed15('0x204c')]['get']({'fields':_0x13ed15('0x2035'),'sort':'name','nolimit':'true'})['$promise'][_0x13ed15('0x683')](function(_0x4e2757){const _0x54974b=_0x13ed15;_0x421d72=_0x4e2757[_0x54974b('0xf5d')]||[];})[_0x13ed15('0x683')](function(){const _0x3e52fc=_0x13ed15,_0x2f95e7=[];for(let _0xd3178f=0x0;_0xd3178f<_0x4b1e2f[_0x3e52fc('0x1564')];_0xd3178f++){_0x2f95e7[_0x3e52fc('0x1fd0')](_0x2caf2d[_0x3e52fc('0x22df')][_0x3e52fc('0x1e6e')]({'userProfileId':_0x2be59d[_0x3e52fc('0x11ed')][_0x3e52fc('0x2f')],'sectionId':_0x4b1e2f[_0xd3178f]['id']})['$promise']);}return _0x4858e7['all'](_0x2f95e7);})[_0x13ed15('0x683')](function(_0x272b70){const _0x1e2ceb=_0x13ed15,_0x11ae37=_0x2e3ca0()[_0x1e2ceb('0x386')](_0x272b70,function(_0x46bc8f){const _0x32558c=_0x1e2ceb;return _0x46bc8f&&_0x46bc8f['rows']?_0x46bc8f[_0x32558c('0xf5d')][0x0]:null;}),_0x4e812a=[];for(let _0x59c727=0x0;_0x59c727<_0x4b1e2f[_0x1e2ceb('0x1564')];_0x59c727++){const _0x3070b7=_0x2e3ca0()[_0x1e2ceb('0x1c07')](_0x11ae37,['sectionId',_0x4b1e2f[_0x59c727]['id']]);if(_0x3070b7){if(!_0x3070b7['autoAssociation'])_0x4e812a[_0x1e2ceb('0x1fd0')](_0x2caf2d[_0x1e2ceb('0xcf7')][_0x1e2ceb('0x1e6e')]({'sectionId':_0x3070b7['id']})[_0x1e2ceb('0xe53')]);else{const _0x58e8e5=[];_0x421d72[_0x1e2ceb('0x1299')](function(_0x17e1fb){const _0x351e30=_0x1e2ceb;_0x17e1fb[_0x351e30('0xcf0')]===_0x4b1e2f[_0x59c727][_0x351e30('0xcf0')]&&_0x58e8e5[_0x351e30('0x1fd0')](_0x17e1fb);}),_0x4e812a[_0x1e2ceb('0x1fd0')]({'rows':_0x58e8e5,'count':_0x58e8e5[_0x1e2ceb('0x1564')]});}}}return _0x4858e7['all'](_0x4e812a);})['then'](function(_0x4b1fce){const _0x30f1ba=_0x13ed15,_0xca724b=[],_0x500601=[];_0x2be59d['triggerAnyConditions'][_0x30f1ba('0xf5d')][_0x30f1ba('0x1299')](function(_0xfde6b4){const _0x597a02=_0x30f1ba;if(_0xfde6b4[_0x597a02('0x2013')]===_0x597a02('0x660')){const _0x5988c1=_0x2e3ca0()['find'](_0x421d72,{'name':_0xfde6b4['value']});_0x500601[_0x597a02('0x1fd0')](_0x5988c1);}});for(let _0x2b16a3=0x0;_0x2b16a3<_0x4b1fce[_0x30f1ba('0x1564')];_0x2b16a3++){const _0x14050a=_0x4b1fce[_0x2b16a3][_0x30f1ba('0xf5d')]||[];_0x14050a[_0x30f1ba('0x1299')](function(_0xbff3ac){_0xca724b['push'](_0xbff3ac);});}!_0x2e3ca0()[_0x30f1ba('0x173f')](_0x500601)&&_0x500601['forEach'](function(_0x3b209d){const _0x45d44c=_0x30f1ba;if(!_0x2e3ca0()['some'](_0xca724b,['resourceId',_0x3b209d['id']])){const _0x4728fa=_0x2e3ca0()[_0x45d44c('0x1c07')](_0x421d72,{'id':_0x3b209d['id']});_0x4728fa[_0x45d44c('0x319')]=![],_0xca724b[_0x45d44c('0x1fd0')](_0x4728fa);}}),_0x2be59d['queues']=_0xca724b;})[_0x13ed15('0x130a')](function(_0x22aa91){const _0x571faa=_0x13ed15;_0x59a717[_0x571faa('0x52a')]({'title':_0x22aa91[_0x571faa('0x13ee')]?_0x571faa('0x2168')+_0x22aa91['status']+_0x571faa('0xbf6')+_0x22aa91[_0x571faa('0x24a9')]:'SYSTEM:GET_QUEUES','msg':_0x22aa91[_0x571faa('0x5a5')]?JSON['stringify'](_0x22aa91[_0x571faa('0x5a5')]):_0x22aa91[_0x571faa('0x1ff0')]()});});}function _0x10ea42(){const _0x5058d7=_0x2f4be8;_0xa6a7ec['isAdmin']()?_0x2caf2d[_0x5058d7('0x14cb')][_0x5058d7('0x1e6e')]({'fields':'id,exten','type':'outbound','VoiceExtensionId':_0x5058d7('0x13c'),'nolimit':_0x5058d7('0x26ac')})[_0x5058d7('0xe53')][_0x5058d7('0x683')](function(_0x478890){const _0x527295=_0x5058d7;_0x2be59d[_0x527295('0x871')]=_0x478890[_0x527295('0xf5d')]||[];})['catch'](function(_0x8a106){const _0x4d5231=_0x5058d7;_0x59a717[_0x4d5231('0x52a')]({'title':_0x8a106[_0x4d5231('0x13ee')]?'API:'+_0x8a106[_0x4d5231('0x13ee')]+'\x20-\x20'+_0x8a106['statusText']:_0x4d5231('0xaf8'),'msg':_0x8a106[_0x4d5231('0x5a5')]?JSON[_0x4d5231('0x258a')](_0x8a106['data']):_0x8a106[_0x4d5231('0x1ff0')]()});}):_0x2caf2d[_0x5058d7('0x14cb')][_0x5058d7('0x1e6e')]({'fields':_0x5058d7('0x5c6'),'type':'outbound','VoiceExtensionId':_0x5058d7('0x13c'),'nolimit':_0x5058d7('0x26ac')})[_0x5058d7('0xe53')]['then'](function(_0xfe9967){const _0x5295f8=_0x5058d7;_0x2be59d['outboundRoutes']=_0xfe9967[_0x5295f8('0xf5d')]||[];})[_0x5058d7('0x683')](function(){const _0x1ff6d2=_0x5058d7;return _0x2caf2d[_0x1ff6d2('0x22df')][_0x1ff6d2('0x1e6e')]({'userProfileId':_0x2be59d[_0x1ff6d2('0x11ed')][_0x1ff6d2('0x2f')],'sectionId':0x193})[_0x1ff6d2('0xe53')];})[_0x5058d7('0x683')](function(_0xa5bead){const _0x2bc949=_0x5058d7,_0x3d9bd1=_0xa5bead&&_0xa5bead[_0x2bc949('0xf5d')]?_0xa5bead[_0x2bc949('0xf5d')][0x0]:null;if(!_0x3d9bd1){const _0x4737f2=[],_0x36b360=[];_0x2be59d[_0x2bc949('0x1c3f')]['rows'][_0x2bc949('0x1299')](function(_0x17e53b){const _0x63cc9a=_0x2bc949;if(_0x17e53b[_0x63cc9a('0x2013')]==='routeId'){const _0x535bae=_0x2e3ca0()[_0x63cc9a('0x1c07')](_0x2be59d[_0x63cc9a('0x871')],{'id':Number(_0x17e53b[_0x63cc9a('0x1c6b')])});_0x36b360['push'](_0x535bae);}});for(let _0x2c175f=0x0;_0x2c175f<_0x2be59d[_0x2bc949('0x871')][_0x2bc949('0x1564')];_0x2c175f++){const _0x5939f3=_0x2e3ca0()[_0x2bc949('0x7a2')](_0x36b360,{'id':_0x2be59d[_0x2bc949('0x871')][_0x2c175f]['id']});_0x5939f3&&(_0x2be59d[_0x2bc949('0x871')][_0x2c175f]['canSelect']=![],_0x4737f2['push'](_0x2be59d[_0x2bc949('0x871')][_0x2c175f]));}_0x2be59d[_0x2bc949('0x871')]=_0x4737f2;}else{if(!_0x3d9bd1['autoAssociation'])return _0x2caf2d[_0x2bc949('0xcf7')]['get']({'sectionId':_0x3d9bd1['id']})['$promise']['then'](function(_0x5edabc){const _0x5b6784=_0x2bc949,_0x22dd2d=_0x2e3ca0()[_0x5b6784('0x386')](_0x5edabc[_0x5b6784('0xf5d')],function(_0x243103){const _0x171efc=_0x5b6784;return _0x2e3ca0()['find'](_0x2be59d[_0x171efc('0x871')],{'id':_0x243103[_0x171efc('0x832')]});});let _0x31f526=null;_0x31f526=[],_0x2be59d[_0x5b6784('0x1c3f')][_0x5b6784('0xf5d')][_0x5b6784('0x1299')](function(_0xb28bd4){const _0x1145de=_0x5b6784;if(_0xb28bd4['field']===_0x1145de('0x4f8')){const _0x4115fb=_0x2e3ca0()[_0x1145de('0x1c07')](_0x2be59d[_0x1145de('0x871')],{'id':Number(_0xb28bd4[_0x1145de('0x1c6b')])});_0x31f526[_0x1145de('0x1fd0')](_0x4115fb);}}),!_0x2e3ca0()[_0x5b6784('0x173f')](_0x31f526)&&_0x31f526[_0x5b6784('0x1299')](function(_0x9a34b9){const _0x31f392=_0x5b6784;if(!_0x2e3ca0()[_0x31f392('0x7a2')](_0x22dd2d,['id',_0x9a34b9['id']])){const _0x825795=_0x2e3ca0()[_0x31f392('0x1c07')](_0x2be59d[_0x31f392('0x871')],{'id':_0x9a34b9['id']});_0x825795[_0x31f392('0x319')]=![],_0x22dd2d[_0x31f392('0x1fd0')](_0x825795);}}),_0x2be59d['outboundRoutes']=_0x22dd2d;});}})['catch'](function(_0x458562){const _0x37df45=_0x5058d7;_0x59a717[_0x37df45('0x52a')]({'title':_0x458562[_0x37df45('0x13ee')]?_0x37df45('0x2168')+_0x458562[_0x37df45('0x13ee')]+_0x37df45('0xbf6')+_0x458562[_0x37df45('0x24a9')]:_0x37df45('0xaf8'),'msg':_0x458562[_0x37df45('0x5a5')]?JSON['stringify'](_0x458562[_0x37df45('0x5a5')]):_0x458562[_0x37df45('0x1ff0')]()});});}function _0x4586ed(){const _0x4d42e0=_0x2f4be8;_0xa6a7ec[_0x4d42e0('0x1d32')]()?_0x2caf2d[_0x4d42e0('0xc96')][_0x4d42e0('0x1e6e')]({'fields':_0x4d42e0('0x2686'),'sort':_0x4d42e0('0x60a'),'role':'agent','nolimit':_0x4d42e0('0x26ac')})[_0x4d42e0('0xe53')]['then'](function(_0x44b481){const _0xe11053=_0x4d42e0;_0x2be59d[_0xe11053('0x756')]=_0x44b481['rows']||[];})[_0x4d42e0('0x130a')](function(_0x505bf7){const _0x34301b=_0x4d42e0;_0x59a717[_0x34301b('0x52a')]({'title':_0x505bf7[_0x34301b('0x13ee')]?_0x34301b('0x2168')+_0x505bf7[_0x34301b('0x13ee')]+_0x34301b('0xbf6')+_0x505bf7[_0x34301b('0x24a9')]:_0x34301b('0x144f'),'msg':_0x505bf7['data']?JSON[_0x34301b('0x258a')](_0x505bf7['data']):_0x505bf7[_0x34301b('0x1ff0')]()});}):_0x2caf2d[_0x4d42e0('0xc96')][_0x4d42e0('0x1e6e')]({'fields':_0x4d42e0('0x2686'),'sort':_0x4d42e0('0x60a'),'role':_0x4d42e0('0x2327'),'nolimit':_0x4d42e0('0x26ac')})[_0x4d42e0('0xe53')]['then'](function(_0x282f55){const _0x377393=_0x4d42e0;_0x2be59d[_0x377393('0x756')]=_0x282f55[_0x377393('0xf5d')]||[];})[_0x4d42e0('0x683')](function(){const _0x4cfe52=_0x4d42e0;return _0x2caf2d[_0x4cfe52('0x22df')]['get']({'userProfileId':_0x2be59d['currentUser'][_0x4cfe52('0x2f')],'sectionId':0xca})[_0x4cfe52('0xe53')];})[_0x4d42e0('0x683')](function(_0x19424c){const _0xd7d737=_0x4d42e0,_0x2a6e5d=_0x19424c&&_0x19424c[_0xd7d737('0xf5d')]?_0x19424c[_0xd7d737('0xf5d')][0x0]:null;if(!_0x2a6e5d){const _0x55a42b=[],_0x38f954=[];_0x2be59d[_0xd7d737('0x1c3f')][_0xd7d737('0xf5d')][_0xd7d737('0x1299')](function(_0x3e8455){const _0x52a346=_0xd7d737;if(_0x3e8455[_0x52a346('0x2013')]===_0x52a346('0x2327')){const _0x198ba9=_0x2e3ca0()['find'](_0x2be59d[_0x52a346('0x756')],{'name':_0x3e8455[_0x52a346('0x1c6b')]});_0x38f954[_0x52a346('0x1fd0')](_0x198ba9);}});for(let _0x54220f=0x0;_0x54220f<_0x2be59d[_0xd7d737('0x756')][_0xd7d737('0x1564')];_0x54220f++){const _0xd0931f=_0x2e3ca0()[_0xd7d737('0x7a2')](_0x38f954,{'id':_0x2be59d['agents'][_0x54220f]['id']});_0xd0931f&&(_0x2be59d[_0xd7d737('0x756')][_0x54220f][_0xd7d737('0x319')]=![],_0x55a42b[_0xd7d737('0x1fd0')](_0x2be59d[_0xd7d737('0x756')][_0x54220f]));}_0x2be59d[_0xd7d737('0x756')]=_0x55a42b;}else{if(!_0x2a6e5d[_0xd7d737('0x170')])return _0x2caf2d[_0xd7d737('0xcf7')][_0xd7d737('0x1e6e')]({'sectionId':_0x2a6e5d['id']})[_0xd7d737('0xe53')][_0xd7d737('0x683')](function(_0x5e8b0c){const _0x3277e1=_0xd7d737,_0x5ecf2f=_0x2e3ca0()[_0x3277e1('0x386')](_0x5e8b0c[_0x3277e1('0xf5d')],function(_0x389a7d){const _0x1b514b=_0x3277e1;return _0x2e3ca0()[_0x1b514b('0x1c07')](_0x2be59d[_0x1b514b('0x756')],{'id':_0x389a7d[_0x1b514b('0x832')]});});let _0x472b41=null;_0x472b41=[],_0x2be59d[_0x3277e1('0x1c3f')][_0x3277e1('0xf5d')]['forEach'](function(_0x355897){const _0x5da1af=_0x3277e1;if(_0x355897[_0x5da1af('0x2013')]===_0x5da1af('0x2327')){const _0x4b962d=_0x2e3ca0()['find'](_0x2be59d[_0x5da1af('0x756')],{'name':_0x355897['value']});_0x472b41['push'](_0x4b962d);}}),!_0x2e3ca0()[_0x3277e1('0x173f')](_0x472b41)&&_0x472b41['forEach'](function(_0x58a3c7){const _0x2d78fd=_0x3277e1;if(!_0x2e3ca0()['some'](_0x5ecf2f,['id',_0x58a3c7['id']])){const _0x55ee77=_0x2e3ca0()['find'](_0x2be59d[_0x2d78fd('0x756')],{'id':_0x58a3c7['id']});_0x55ee77[_0x2d78fd('0x319')]=![],_0x5ecf2f[_0x2d78fd('0x1fd0')](_0x55ee77);}}),_0x2be59d['agents']=_0x5ecf2f;});}})[_0x4d42e0('0x130a')](function(_0x6f390e){const _0x18cef8=_0x4d42e0;_0x59a717[_0x18cef8('0x52a')]({'title':_0x6f390e['status']?_0x18cef8('0x2168')+_0x6f390e['status']+'\x20-\x20'+_0x6f390e[_0x18cef8('0x24a9')]:_0x18cef8('0x144f'),'msg':_0x6f390e[_0x18cef8('0x5a5')]?JSON[_0x18cef8('0x258a')](_0x6f390e[_0x18cef8('0x5a5')]):_0x6f390e[_0x18cef8('0x1ff0')]()});});}function _0x4c0ac9(){const _0x448e57=_0x2f4be8;if(_0x2be59d['trigger']['channel']===_0x448e57('0xcf2')){if(_0x2e3ca0()[_0x448e57('0x7a2')](_0x2be59d[_0x448e57('0x1c3f')][_0x448e57('0xf5d')],[_0x448e57('0x2013'),_0x448e57('0x660')])){if(!_0x2be59d[_0x448e57('0x2da')])_0xe45f56();}if(_0x2e3ca0()[_0x448e57('0x7a2')](_0x2be59d[_0x448e57('0x1c3f')][_0x448e57('0xf5d')],['field',_0x448e57('0x4f8')])){if(!_0x2be59d[_0x448e57('0x871')])_0x10ea42();}if(_0x2e3ca0()[_0x448e57('0x7a2')](_0x2be59d[_0x448e57('0x1c3f')][_0x448e57('0xf5d')],['field',_0x448e57('0x2327')])){if(!_0x2be59d[_0x448e57('0x756')])_0x4586ed();}}else _0x5158af();}function _0x179cd1(_0x5ac222){const _0x23a1b8=_0x2f4be8;_0x2be59d[_0x23a1b8('0x1c3f')]=_0x5ac222||{'count':0x0,'rows':[]},_0x4c0ac9();}function _0x433b10(){const _0x581b49=_0x2f4be8;_0x2be59d[_0x581b49('0x23a2')][_0x581b49('0x1cc8')]=(_0x2be59d['query'][_0x581b49('0xdf8')]-0x1)*_0x2be59d['query']['limit'],_0x2be59d[_0x581b49('0x1883')]=_0x2caf2d[_0x581b49('0x25e2')][_0x581b49('0x18a9')](_0x2be59d['query'],_0x179cd1)[_0x581b49('0xe53')];}function _0x2a1c1b(_0x4f47fe,_0x54fde6){const _0x4af72e=_0x2f4be8;_0x3546ec[_0x4af72e('0x1d4')]({'controller':_0x4af72e('0xb5'),'controllerAs':'vm','templateUrl':_0x5a9aed,'parent':angular[_0x4af72e('0x1fcc')](_0x5181e2[_0x4af72e('0x18e5')]),'targetEvent':_0x4f47fe,'clickOutsideToClose':!![],'locals':{'trigger':_0x2be59d['trigger'],'anyCondition':_0x54fde6,'anyConditions':_0x2be59d[_0x4af72e('0x1c3f')][_0x4af72e('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x2be59d[_0x4af72e('0x1134')]}})[_0x4af72e('0x683')](function(_0x17559a){const _0x2bc8c7=_0x4af72e;_0x17559a&&(_0x2be59d[_0x2bc8c7('0x1c3f')]={'count':_0x17559a[_0x2bc8c7('0x1564')],'rows':_0x17559a},_0x4c0ac9());});}function _0x2ab8d1(_0x106dd4,_0x2ef26){const _0x373827=_0x2f4be8,_0x69c210=_0x3546ec[_0x373827('0x1c6f')]()[_0x373827('0xf28')](_0x29bf08[_0x373827('0x2728')]('TOOLS.NOTIFICATIONS.CONDITION_DELETE_TITLE'))[_0x373827('0x1040')]('Delete\x20condition')[_0x373827('0xe42')](_0x2ef26)['ok']('OK')['cancel'](_0x29bf08['instant'](_0x373827('0x9a1')));_0x3546ec[_0x373827('0x1d4')](_0x69c210)[_0x373827('0x683')](function(){_0x37627d(_0x106dd4,!![]);});}function _0x37627d(_0x4940aa,_0x28e732){const _0x22fc80=_0x2f4be8;_0x2caf2d['condition'][_0x22fc80('0xd7e')]({'id':_0x4940aa['id']})['$promise'][_0x22fc80('0x683')](function(){const _0x3106bd=_0x22fc80;_0x433b10(),_0x28e732&&_0x59a717[_0x3106bd('0x53')]({'title':_0x29bf08['instant']('TOOLS.NOTIFICATIONS.CONDITION_DELETED_SUCCESS_TITLE')});})[_0x22fc80('0x130a')](function(_0xb3f8c){const _0x4c9460=_0x22fc80;if(_0xb3f8c[_0x4c9460('0x5a5')]&&_0xb3f8c[_0x4c9460('0x5a5')]['errors']&&_0xb3f8c['data'][_0x4c9460('0x17f')]['length']){_0x2be59d['errors']=_0xb3f8c['data'][_0x4c9460('0x17f')]||[{'message':_0xb3f8c['toString'](),'type':_0x4c9460('0x107f')}];for(let _0x2c0f14=0x0;_0x2c0f14<_0xb3f8c[_0x4c9460('0x5a5')][_0x4c9460('0x17f')][_0x4c9460('0x1564')];_0x2c0f14++){_0x59a717[_0x4c9460('0x52a')]({'title':_0xb3f8c['data']['errors'][_0x2c0f14][_0x4c9460('0xcf0')],'msg':_0xb3f8c['data'][_0x4c9460('0x17f')][_0x2c0f14][_0x4c9460('0x8c2')]});}}else _0x59a717['error']({'title':_0xb3f8c[_0x4c9460('0x13ee')]?'API:'+_0xb3f8c['status']+'\x20-\x20'+_0xb3f8c[_0x4c9460('0x24a9')]:_0x4c9460('0x107f'),'msg':_0xb3f8c['data']?JSON[_0x4c9460('0x258a')](_0xb3f8c[_0x4c9460('0x5a5')][_0x4c9460('0x8c2')]):_0xb3f8c[_0x4c9460('0x8c2')]||_0xb3f8c[_0x4c9460('0x1ff0')]()});});}function _0xeefa3f(){const _0x3d2d45=_0x2f4be8,_0x262ad9=angular['copy'](_0x2be59d[_0x3d2d45('0x2b7')]);return _0x2be59d[_0x3d2d45('0x2b7')]=[],_0x262ad9;}function _0x2b3e48(_0x5e6dec){const _0x56916c=_0x2f4be8,_0x2c861c=_0x3546ec[_0x56916c('0x1c6f')]()['title'](_0x29bf08[_0x56916c('0x2728')](_0x56916c('0xb9e')))[_0x56916c('0xa6a')](_0x29bf08['instant'](_0x56916c('0x2703'),{'total':_0x2be59d[_0x56916c('0x2b7')][_0x56916c('0x1564')]}))[_0x56916c('0x1040')]('Delete\x20conditions')[_0x56916c('0xe42')](_0x5e6dec)['ok']('OK')['cancel'](_0x29bf08[_0x56916c('0x2728')](_0x56916c('0x9a1')));_0x3546ec['show'](_0x2c861c)[_0x56916c('0x683')](function(){const _0x3dd946=_0x56916c;_0x2be59d[_0x3dd946('0x2b7')]['forEach'](function(_0xe1604b){_0x37627d(_0xe1604b);}),_0x2be59d['selectedTriggerAnyConditions']=[],_0x59a717[_0x3dd946('0x53')]({'title':_0x29bf08[_0x3dd946('0x2728')](_0x3dd946('0x126e'))});});}let _0x229fcf=!![],_0x499c5a=0x1;_0x412bfb['$watch'](_0x2f4be8('0x229'),function(_0x41c086,_0x3a2c61){const _0x469856=_0x2f4be8;_0x229fcf?_0x27f412(function(){_0x229fcf=![];}):(!_0x3a2c61&&(_0x499c5a=_0x2be59d[_0x469856('0x23a2')][_0x469856('0xdf8')]),_0x41c086!==_0x3a2c61&&(_0x2be59d[_0x469856('0x23a2')][_0x469856('0xdf8')]=0x1),!_0x41c086&&(_0x2be59d['query'][_0x469856('0xdf8')]=_0x499c5a),_0x433b10());});}const _0x3fd461=_0xb11613;_0x1b1af3['$inject']=['$state',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x24a7'),'allCondition',_0x189033('0x25e2'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x1b1af3(_0x1faf2b,_0x5424fd,_0x4660cd,_0xa4497f,_0x27ff3e,_0x2f4643,_0xb899ca,_0x202e96,_0x259bbd,_0x15d3b7,_0x11617b,_0x235db5,_0x277aa1){const _0x22890c=_0x189033,_0xcb419=this;_0xcb419['currentUser']=_0x15d3b7['getCurrentUser'](),_0xcb419['allCondition']=angular[_0x22890c('0x1a86')](_0xb899ca),_0xcb419[_0x22890c('0x24a7')]=angular[_0x22890c('0x1a86')](_0x2f4643),_0xcb419[_0x22890c('0x260a')]=_0x235db5,_0xcb419[_0x22890c('0xace')]=_0x11617b,_0xcb419[_0x22890c('0x1134')]=_0x277aa1,_0xcb419[_0x22890c('0x258d')]={},_0xcb419[_0x22890c('0x68c')]=![],_0xcb419[_0x22890c('0x17f')]=[],_0xcb419[_0x22890c('0x25e2')]=angular[_0x22890c('0x1a86')](_0x202e96);!_0xcb419[_0x22890c('0x179f')]?(_0xcb419[_0x22890c('0x179f')]={'operator':_0x22890c('0xa18')},_0xcb419[_0x22890c('0x68c')]=!![]):_0x56dfde();_0xcb419['allCondition']['TriggerAllId']=_0x1faf2b['params']['id']||undefined,_0xcb419['callStatuses']=[{'name':_0x22890c('0x1919'),'value':_0x22890c('0x15aa')},{'name':_0x22890c('0xa09'),'value':_0x22890c('0x1668')},{'name':_0x22890c('0x614'),'value':_0x22890c('0x238')},{'name':_0x22890c('0x13bc'),'value':_0x22890c('0x1c36')},{'name':_0x22890c('0x1a67'),'value':_0x22890c('0x4dc')},{'name':_0x22890c('0x7d6'),'value':'connect'},{'name':_0x22890c('0x1255'),'value':'nosuchnumber'},{'name':'Busy','value':'busy'},{'name':_0x22890c('0x25be'),'value':_0x22890c('0x182b')},{'name':_0x22890c('0x2094'),'value':_0x22890c('0x15df')},{'name':_0x22890c('0x3cf'),'value':'agentreject'}],_0xcb419[_0x22890c('0x1d5c')]=_0x56a7c5,_0xcb419['addNewAllCondition']=_0x5a28ef,_0xcb419[_0x22890c('0x3f7')]=_0x5ade75,_0xcb419['deleteAllCondition']=_0x29698c,_0xcb419[_0x22890c('0xf82')]=_0x488728;function _0x255d36(){const _0x512999=_0x22890c,_0x400dbf=[{'id':0x191,'type':_0x512999('0x1535')},{'id':0x5dd,'type':_0x512999('0x17cd')}];let _0x1e61be=null;_0x15d3b7[_0x512999('0x1d32')]()?_0x259bbd[_0x512999('0x204c')][_0x512999('0x1e6e')]({'fields':_0x512999('0x2035'),'sort':_0x512999('0x60a'),'nolimit':_0x512999('0x26ac')})[_0x512999('0xe53')][_0x512999('0x683')](function(_0x597a58){const _0x2b04b5=_0x512999;_0xcb419[_0x2b04b5('0x2da')]=_0x597a58[_0x2b04b5('0xf5d')]||[];})[_0x512999('0x130a')](function(_0x2434bc){const _0x41f11b=_0x512999;_0x27ff3e[_0x41f11b('0x52a')]({'title':_0x2434bc[_0x41f11b('0x13ee')]?_0x41f11b('0x2168')+_0x2434bc[_0x41f11b('0x13ee')]+'\x20-\x20'+_0x2434bc[_0x41f11b('0x24a9')]:'SYSTEM:GET_VOICEQUEUES','msg':_0x2434bc[_0x41f11b('0x5a5')]?JSON[_0x41f11b('0x258a')](_0x2434bc[_0x41f11b('0x5a5')]):_0x2434bc[_0x41f11b('0x1ff0')]()});}):_0x259bbd[_0x512999('0x204c')][_0x512999('0x1e6e')]({'fields':_0x512999('0x2035'),'sort':'name','nolimit':_0x512999('0x26ac')})['$promise'][_0x512999('0x683')](function(_0x5d014){const _0x14991e=_0x512999;_0x1e61be=_0x5d014[_0x14991e('0xf5d')]||[];})[_0x512999('0x683')](function(){const _0x78ecc1=_0x512999,_0x54ea29=[];for(let _0x427603=0x0;_0x427603<_0x400dbf[_0x78ecc1('0x1564')];_0x427603++){_0x54ea29[_0x78ecc1('0x1fd0')](_0x259bbd['userProfileSection'][_0x78ecc1('0x1e6e')]({'userProfileId':_0xcb419[_0x78ecc1('0x11ed')][_0x78ecc1('0x2f')],'sectionId':_0x400dbf[_0x427603]['id']})[_0x78ecc1('0xe53')]);}return _0x4660cd['all'](_0x54ea29);})['then'](function(_0x580809){const _0x4e98dd=_0x512999,_0x308044=_0x2e3ca0()['map'](_0x580809,function(_0x37961f){const _0x48c432=a0_0x4e0a;return _0x37961f&&_0x37961f['rows']?_0x37961f[_0x48c432('0xf5d')][0x0]:null;}),_0x501d6c=[];for(let _0x49cf6b=0x0;_0x49cf6b<_0x400dbf['length'];_0x49cf6b++){const _0x534c74=_0x2e3ca0()[_0x4e98dd('0x1c07')](_0x308044,[_0x4e98dd('0x21c0'),_0x400dbf[_0x49cf6b]['id']]);if(_0x534c74){if(!_0x534c74[_0x4e98dd('0x170')])_0x501d6c[_0x4e98dd('0x1fd0')](_0x259bbd[_0x4e98dd('0xcf7')][_0x4e98dd('0x1e6e')]({'sectionId':_0x534c74['id']})[_0x4e98dd('0xe53')]);else{const _0x245e99=[];_0x1e61be[_0x4e98dd('0x1299')](function(_0x2eb195){const _0x8fb6e8=_0x4e98dd;_0x2eb195[_0x8fb6e8('0xcf0')]===_0x400dbf[_0x49cf6b][_0x8fb6e8('0xcf0')]&&_0x245e99[_0x8fb6e8('0x1fd0')](_0x2eb195);}),_0x501d6c[_0x4e98dd('0x1fd0')]({'rows':_0x245e99,'count':_0x245e99['length']});}}}return _0x4660cd[_0x4e98dd('0x252c')](_0x501d6c);})[_0x512999('0x683')](function(_0x1a799c){const _0x51eea4=_0x512999,_0x1a797f=[],_0x125b6d=[];_0xcb419['triggerallConditions'][_0x51eea4('0xf5d')][_0x51eea4('0x1299')](function(_0xd93bdb){const _0x3b961f=_0x51eea4;if(_0xd93bdb['field']===_0x3b961f('0x660')){const _0x54e703=_0x2e3ca0()[_0x3b961f('0x1c07')](_0x1e61be,{'name':_0xd93bdb['value']});_0x125b6d[_0x3b961f('0x1fd0')](_0x54e703);}});for(let _0x481d62=0x0;_0x481d62<_0x1a799c[_0x51eea4('0x1564')];_0x481d62++){const _0x496e74=_0x1a799c[_0x481d62][_0x51eea4('0xf5d')]||[];_0x496e74[_0x51eea4('0x1299')](function(_0x32fb75){const _0x44b814=_0x51eea4;_0x1a797f[_0x44b814('0x1fd0')](_0x32fb75);});}!_0x2e3ca0()[_0x51eea4('0x173f')](_0x125b6d)&&_0x125b6d['forEach'](function(_0x4b0b5f){const _0x472ebd=_0x51eea4;if(!_0x2e3ca0()[_0x472ebd('0x7a2')](_0x1a797f,[_0x472ebd('0x832'),_0x4b0b5f['id']])){const _0x5c3f44=_0x2e3ca0()[_0x472ebd('0x1c07')](_0x1e61be,{'id':_0x4b0b5f['id']});_0x5c3f44[_0x472ebd('0x319')]=![],_0x1a797f[_0x472ebd('0x1fd0')](_0x5c3f44);}}),_0xcb419[_0x51eea4('0x2da')]=_0x1a797f;})['catch'](function(_0x58b5a5){const _0x53d3d0=_0x512999;_0x27ff3e[_0x53d3d0('0x52a')]({'title':_0x58b5a5[_0x53d3d0('0x13ee')]?_0x53d3d0('0x2168')+_0x58b5a5[_0x53d3d0('0x13ee')]+_0x53d3d0('0xbf6')+_0x58b5a5[_0x53d3d0('0x24a9')]:'SYSTEM:GET_QUEUES','msg':_0x58b5a5['data']?JSON[_0x53d3d0('0x258a')](_0x58b5a5[_0x53d3d0('0x5a5')]):_0x58b5a5[_0x53d3d0('0x1ff0')]()});});}function _0x178cd4(){const _0x1197c9=_0x22890c;_0x15d3b7[_0x1197c9('0x1d32')]()?_0x259bbd[_0x1197c9('0x14cb')][_0x1197c9('0x1e6e')]({'fields':_0x1197c9('0x5c6'),'type':_0x1197c9('0x17cd'),'VoiceExtensionId':_0x1197c9('0x13c'),'nolimit':'true'})[_0x1197c9('0xe53')]['then'](function(_0x200fa1){const _0x2809e2=_0x1197c9;_0xcb419[_0x2809e2('0x871')]=_0x200fa1[_0x2809e2('0xf5d')]||[];})[_0x1197c9('0x130a')](function(_0x4be123){const _0x3f9c1b=_0x1197c9;_0x27ff3e[_0x3f9c1b('0x52a')]({'title':_0x4be123[_0x3f9c1b('0x13ee')]?_0x3f9c1b('0x2168')+_0x4be123[_0x3f9c1b('0x13ee')]+'\x20-\x20'+_0x4be123[_0x3f9c1b('0x24a9')]:_0x3f9c1b('0xaf8'),'msg':_0x4be123['data']?JSON[_0x3f9c1b('0x258a')](_0x4be123['data']):_0x4be123[_0x3f9c1b('0x1ff0')]()});}):_0x259bbd['voiceExtension']['get']({'fields':'id,exten','type':_0x1197c9('0x17cd'),'VoiceExtensionId':_0x1197c9('0x13c'),'nolimit':'true'})['$promise'][_0x1197c9('0x683')](function(_0x4a1f72){const _0x506f30=_0x1197c9;_0xcb419[_0x506f30('0x871')]=_0x4a1f72[_0x506f30('0xf5d')]||[];})['then'](function(){const _0x263638=_0x1197c9;return _0x259bbd[_0x263638('0x22df')][_0x263638('0x1e6e')]({'userProfileId':_0xcb419['currentUser'][_0x263638('0x2f')],'sectionId':0x193})[_0x263638('0xe53')];})[_0x1197c9('0x683')](function(_0x58870b){const _0x5bd461=_0x1197c9,_0xbe1028=_0x58870b&&_0x58870b[_0x5bd461('0xf5d')]?_0x58870b[_0x5bd461('0xf5d')][0x0]:null;if(!_0xbe1028){const _0x572cde=[],_0x1567ae=[];_0xcb419['triggerallConditions']['rows'][_0x5bd461('0x1299')](function(_0x57de38){const _0x264f09=_0x5bd461;if(_0x57de38[_0x264f09('0x2013')]===_0x264f09('0x4f8')){const _0x13d8ec=_0x2e3ca0()['find'](_0xcb419[_0x264f09('0x871')],{'id':Number(_0x57de38[_0x264f09('0x1c6b')])});_0x1567ae['push'](_0x13d8ec);}});for(let _0x56df1a=0x0;_0x56df1a<_0xcb419[_0x5bd461('0x871')][_0x5bd461('0x1564')];_0x56df1a++){const _0x1eaeff=_0x2e3ca0()[_0x5bd461('0x7a2')](_0x1567ae,{'id':_0xcb419[_0x5bd461('0x871')][_0x56df1a]['id']});_0x1eaeff&&(_0xcb419['outboundRoutes'][_0x56df1a][_0x5bd461('0x319')]=![],_0x572cde[_0x5bd461('0x1fd0')](_0xcb419[_0x5bd461('0x871')][_0x56df1a]));}_0xcb419['outboundRoutes']=_0x572cde;}else{if(!_0xbe1028['autoAssociation'])return _0x259bbd[_0x5bd461('0xcf7')][_0x5bd461('0x1e6e')]({'sectionId':_0xbe1028['id']})[_0x5bd461('0xe53')][_0x5bd461('0x683')](function(_0x55413b){const _0x23012f=_0x5bd461,_0x48a13a=_0x2e3ca0()[_0x23012f('0x386')](_0x55413b['rows'],function(_0x4efd4b){const _0x1320f2=_0x23012f;return _0x2e3ca0()[_0x1320f2('0x1c07')](_0xcb419['outboundRoutes'],{'id':_0x4efd4b[_0x1320f2('0x832')]});});let _0x445330=null;_0x445330=[],_0xcb419[_0x23012f('0x1bb7')][_0x23012f('0xf5d')][_0x23012f('0x1299')](function(_0x18f5ba){const _0x45a87a=_0x23012f;if(_0x18f5ba[_0x45a87a('0x2013')]===_0x45a87a('0x4f8')){const _0x1008c5=_0x2e3ca0()['find'](_0xcb419[_0x45a87a('0x871')],{'id':Number(_0x18f5ba[_0x45a87a('0x1c6b')])});_0x445330['push'](_0x1008c5);}}),!_0x2e3ca0()[_0x23012f('0x173f')](_0x445330)&&_0x445330[_0x23012f('0x1299')](function(_0x3e1f1a){const _0x405e38=_0x23012f;if(!_0x2e3ca0()['some'](_0x48a13a,['id',_0x3e1f1a['id']])){const _0x21bfee=_0x2e3ca0()['find'](_0xcb419['outboundRoutes'],{'id':_0x3e1f1a['id']});_0x21bfee['canSelect']=![],_0x48a13a[_0x405e38('0x1fd0')](_0x21bfee);}}),_0xcb419[_0x23012f('0x871')]=_0x48a13a;});}})[_0x1197c9('0x130a')](function(_0x4d2b45){const _0x21e653=_0x1197c9;_0x27ff3e['error']({'title':_0x4d2b45[_0x21e653('0x13ee')]?_0x21e653('0x2168')+_0x4d2b45[_0x21e653('0x13ee')]+'\x20-\x20'+_0x4d2b45[_0x21e653('0x24a9')]:_0x21e653('0xaf8'),'msg':_0x4d2b45[_0x21e653('0x5a5')]?JSON[_0x21e653('0x258a')](_0x4d2b45[_0x21e653('0x5a5')]):_0x4d2b45['toString']()});});}function _0x477ad7(){const _0x5771ea=_0x22890c;_0x15d3b7[_0x5771ea('0x1d32')]()?_0x259bbd[_0x5771ea('0xc96')]['get']({'fields':'id,name,fullname','sort':'name','role':_0x5771ea('0x2327'),'nolimit':'true'})[_0x5771ea('0xe53')][_0x5771ea('0x683')](function(_0x365c18){const _0x3ae7bd=_0x5771ea;_0xcb419[_0x3ae7bd('0x756')]=_0x365c18['rows']||[];})['catch'](function(_0x4d0bea){const _0x89e1be=_0x5771ea;_0x27ff3e[_0x89e1be('0x52a')]({'title':_0x4d0bea[_0x89e1be('0x13ee')]?_0x89e1be('0x2168')+_0x4d0bea[_0x89e1be('0x13ee')]+'\x20-\x20'+_0x4d0bea['statusText']:'SYSTEM:GET_AGENTS','msg':_0x4d0bea[_0x89e1be('0x5a5')]?JSON[_0x89e1be('0x258a')](_0x4d0bea[_0x89e1be('0x5a5')]):_0x4d0bea[_0x89e1be('0x1ff0')]()});}):_0x259bbd[_0x5771ea('0xc96')][_0x5771ea('0x1e6e')]({'fields':'id,name,fullname','sort':_0x5771ea('0x60a'),'role':_0x5771ea('0x2327'),'nolimit':'true'})['$promise'][_0x5771ea('0x683')](function(_0x4b725b){_0xcb419['agents']=_0x4b725b['rows']||[];})[_0x5771ea('0x683')](function(){const _0x4a3f18=_0x5771ea;return _0x259bbd[_0x4a3f18('0x22df')][_0x4a3f18('0x1e6e')]({'userProfileId':_0xcb419[_0x4a3f18('0x11ed')][_0x4a3f18('0x2f')],'sectionId':0xca})['$promise'];})[_0x5771ea('0x683')](function(_0x3cc221){const _0x131d7b=_0x5771ea,_0x92907e=_0x3cc221&&_0x3cc221[_0x131d7b('0xf5d')]?_0x3cc221[_0x131d7b('0xf5d')][0x0]:null;if(!_0x92907e){const _0x1377c6=[],_0x348d1c=[];_0xcb419['triggerallConditions'][_0x131d7b('0xf5d')][_0x131d7b('0x1299')](function(_0x8e683d){const _0x26773c=_0x131d7b;if(_0x8e683d[_0x26773c('0x2013')]===_0x26773c('0x2327')){const _0x193b49=_0x2e3ca0()[_0x26773c('0x1c07')](_0xcb419[_0x26773c('0x756')],{'name':_0x8e683d['value']});_0x348d1c[_0x26773c('0x1fd0')](_0x193b49);}});for(let _0x3305af=0x0;_0x3305af<_0xcb419[_0x131d7b('0x756')][_0x131d7b('0x1564')];_0x3305af++){const _0x496d6d=_0x2e3ca0()[_0x131d7b('0x7a2')](_0x348d1c,{'id':_0xcb419['agents'][_0x3305af]['id']});_0x496d6d&&(_0xcb419[_0x131d7b('0x756')][_0x3305af]['canSelect']=![],_0x1377c6['push'](_0xcb419[_0x131d7b('0x756')][_0x3305af]));}_0xcb419[_0x131d7b('0x756')]=_0x1377c6;}else{if(!_0x92907e[_0x131d7b('0x170')])return _0x259bbd['userProfileResource']['get']({'sectionId':_0x92907e['id']})[_0x131d7b('0xe53')][_0x131d7b('0x683')](function(_0x2c5354){const _0x4b1749=_0x131d7b,_0xa8b38=_0x2e3ca0()[_0x4b1749('0x386')](_0x2c5354[_0x4b1749('0xf5d')],function(_0x438ec4){const _0x3e0201=_0x4b1749;return _0x2e3ca0()[_0x3e0201('0x1c07')](_0xcb419[_0x3e0201('0x756')],{'id':_0x438ec4[_0x3e0201('0x832')]});});let _0x176fdc=null;_0x176fdc=[],_0xcb419[_0x4b1749('0x1bb7')]['rows'][_0x4b1749('0x1299')](function(_0x1c9626){const _0x4147da=_0x4b1749;if(_0x1c9626[_0x4147da('0x2013')]===_0x4147da('0x2327')){const _0xe586e5=_0x2e3ca0()[_0x4147da('0x1c07')](_0xcb419[_0x4147da('0x756')],{'name':_0x1c9626[_0x4147da('0x1c6b')]});_0x176fdc['push'](_0xe586e5);}}),!_0x2e3ca0()[_0x4b1749('0x173f')](_0x176fdc)&&_0x176fdc[_0x4b1749('0x1299')](function(_0x26dde9){const _0x53ac2e=_0x4b1749;if(!_0x2e3ca0()[_0x53ac2e('0x7a2')](_0xa8b38,['id',_0x26dde9['id']])){const _0x3becc5=_0x2e3ca0()[_0x53ac2e('0x1c07')](_0xcb419['agents'],{'id':_0x26dde9['id']});_0x3becc5[_0x53ac2e('0x319')]=![],_0xa8b38['push'](_0x3becc5);}}),_0xcb419['agents']=_0xa8b38;});}})[_0x5771ea('0x130a')](function(_0x25a315){const _0x46e9eb=_0x5771ea;_0x27ff3e[_0x46e9eb('0x52a')]({'title':_0x25a315[_0x46e9eb('0x13ee')]?'API:'+_0x25a315[_0x46e9eb('0x13ee')]+_0x46e9eb('0xbf6')+_0x25a315['statusText']:_0x46e9eb('0x144f'),'msg':_0x25a315[_0x46e9eb('0x5a5')]?JSON[_0x46e9eb('0x258a')](_0x25a315[_0x46e9eb('0x5a5')]):_0x25a315[_0x46e9eb('0x1ff0')]()});});}function _0xd1437d(){const _0x1a1ef0=_0x22890c,_0x14ce7c=_0xcb419[_0x1a1ef0('0x25e2')][_0x1a1ef0('0xdd6')]+(_0xcb419[_0x1a1ef0('0x25e2')][_0x1a1ef0('0xdd6')]===_0x1a1ef0('0x24e')?'Website':_0x1a1ef0('0xa78'));let _0x45c9e5;switch(_0xcb419['trigger'][_0x1a1ef0('0xdd6')]){case _0x1a1ef0('0x24e'):_0x45c9e5=0x1f6;break;case _0x1a1ef0('0x23e9'):_0x45c9e5=0x386;break;case'mail':_0x45c9e5=0x25a;break;case'openchannel':_0x45c9e5=0x322;break;case _0x1a1ef0('0x1285'):_0x45c9e5=0x2be;break;case _0x1a1ef0('0x16e7'):_0x45c9e5=0x836;break;}if(_0x15d3b7[_0x1a1ef0('0x1d32')]()){const _0x2dc302=_0xcb419['trigger'][_0x1a1ef0('0xdd6')];_0x259bbd[_0x14ce7c]['get']({'fields':'id,name','sort':'id','nolimit':_0x1a1ef0('0x26ac')})[_0x1a1ef0('0xe53')]['then'](function(_0x2f1b35){const _0x3137d4=_0x1a1ef0;_0xcb419[_0x3137d4('0x1c31')]=_0x2f1b35[_0x3137d4('0xf5d')]||[];})[_0x1a1ef0('0x130a')](function(_0x5286a6){const _0x4adf7c=_0x1a1ef0;_0x27ff3e['error']({'title':_0x5286a6['status']?_0x4adf7c('0x2168')+_0x5286a6['status']+_0x4adf7c('0xbf6')+_0x5286a6[_0x4adf7c('0x24a9')]:_0x4adf7c('0xf4a')+_0x2dc302[_0x4adf7c('0x80')]()+_0x2dc302===_0x4adf7c('0x24e')?_0x4adf7c('0x1327'):_0x4adf7c('0x597'),'msg':_0x5286a6[_0x4adf7c('0x5a5')]?JSON['stringify'](_0x5286a6[_0x4adf7c('0x5a5')]):_0x5286a6[_0x4adf7c('0x1ff0')]()});});}else _0x259bbd[_0x14ce7c][_0x1a1ef0('0x1e6e')]({'fields':_0x1a1ef0('0xa10'),'sort':'id','nolimit':_0x1a1ef0('0x26ac')})[_0x1a1ef0('0xe53')][_0x1a1ef0('0x683')](function(_0x17ced6){const _0x4e7fcd=_0x1a1ef0;_0xcb419[_0x4e7fcd('0x1c31')]=_0x17ced6[_0x4e7fcd('0xf5d')]||[];})['then'](function(){const _0x43726b=_0x1a1ef0;return _0x259bbd[_0x43726b('0x22df')][_0x43726b('0x1e6e')]({'userProfileId':_0xcb419['currentUser'][_0x43726b('0x2f')],'sectionId':_0x45c9e5})['$promise'];})[_0x1a1ef0('0x683')](function(_0x29f6c6){const _0x545d67=_0x1a1ef0,_0x59e92f=_0x29f6c6&&_0x29f6c6[_0x545d67('0xf5d')]?_0x29f6c6[_0x545d67('0xf5d')][0x0]:null;if(!_0x59e92f){const _0x4241ae=[],_0x36ee34=[];_0xcb419[_0x545d67('0x1bb7')]['rows'][_0x545d67('0x1299')](function(_0x2339af){const _0x2fa0dd=_0x545d67;if(_0x2339af['field']===_0x2fa0dd('0x1d2f')){const _0x2bff4e=_0x2e3ca0()[_0x2fa0dd('0x1c07')](_0xcb419[_0x2fa0dd('0x1c31')],{'id':Number(_0x2339af[_0x2fa0dd('0x1c6b')])});_0x36ee34['push'](_0x2bff4e);}});for(let _0x18a5c4=0x0;_0x18a5c4<_0xcb419[_0x545d67('0x1c31')][_0x545d67('0x1564')];_0x18a5c4++){const _0x226d1a=_0x2e3ca0()[_0x545d67('0x7a2')](_0x36ee34,{'id':_0xcb419[_0x545d67('0x1c31')][_0x18a5c4]['id']});_0x226d1a&&(_0xcb419[_0x545d67('0x1c31')][_0x18a5c4]['canSelect']=![],_0x4241ae[_0x545d67('0x1fd0')](_0xcb419[_0x545d67('0x1c31')][_0x18a5c4]));}_0xcb419[_0x545d67('0x1c31')]=_0x4241ae;}else{if(!_0x59e92f[_0x545d67('0x170')])return _0x259bbd['userProfileResource'][_0x545d67('0x1e6e')]({'sectionId':_0x59e92f['id']})[_0x545d67('0xe53')][_0x545d67('0x683')](function(_0x3ba5a0){const _0x1a6f3c=_0x545d67,_0x994e8d=_0x2e3ca0()['map'](_0x3ba5a0[_0x1a6f3c('0xf5d')],function(_0x3ca679){const _0x30eeb3=_0x1a6f3c;return _0x2e3ca0()[_0x30eeb3('0x1c07')](_0xcb419['accounts'],{'id':_0x3ca679['resourceId']});});let _0x4b210b=null;_0x4b210b=[],_0xcb419['triggerallConditions'][_0x1a6f3c('0xf5d')][_0x1a6f3c('0x1299')](function(_0x27f705){const _0x235691=_0x1a6f3c;if(_0x27f705[_0x235691('0x2013')]===_0x235691('0x1d2f')){const _0x2bb20c=_0x2e3ca0()['find'](_0xcb419['accounts'],{'id':Number(_0x27f705[_0x235691('0x1c6b')])});_0x4b210b[_0x235691('0x1fd0')](_0x2bb20c);}}),!_0x2e3ca0()[_0x1a6f3c('0x173f')](_0x4b210b)&&_0x4b210b[_0x1a6f3c('0x1299')](function(_0x1f041e){const _0x2f49e6=_0x1a6f3c;if(!_0x2e3ca0()['some'](_0x994e8d,['id',_0x1f041e['id']])){const _0x94fc18=_0x2e3ca0()[_0x2f49e6('0x1c07')](_0xcb419[_0x2f49e6('0x1c31')],{'id':_0x1f041e['id']});_0x94fc18[_0x2f49e6('0x319')]=![],_0x994e8d[_0x2f49e6('0x1fd0')](_0x94fc18);}}),_0xcb419[_0x1a6f3c('0x1c31')]=_0x994e8d;});}})[_0x1a1ef0('0x130a')](function(_0x10b6fd){const _0x10887d=_0x1a1ef0,_0x322930=_0xcb419[_0x10887d('0x25e2')][_0x10887d('0xdd6')];_0x27ff3e[_0x10887d('0x52a')]({'title':_0x10b6fd[_0x10887d('0x13ee')]?_0x10887d('0x2168')+_0x10b6fd[_0x10887d('0x13ee')]+_0x10887d('0xbf6')+_0x10b6fd[_0x10887d('0x24a9')]:_0x10887d('0xf4a')+_0x322930[_0x10887d('0x80')]()+_0x322930===_0x10887d('0x24e')?_0x10887d('0x1327'):_0x10887d('0x597'),'msg':_0x10b6fd['data']?JSON[_0x10887d('0x258a')](_0x10b6fd['data']):_0x10b6fd[_0x10887d('0x1ff0')]()});});}function _0x56dfde(){const _0x58feee=_0x22890c;switch(_0xcb419['allCondition'][_0x58feee('0x2013')]){case _0x58feee('0x660'):if(!_0xcb419['queues'])_0x255d36();break;case _0x58feee('0x4f8'):if(!_0xcb419[_0x58feee('0x871')])_0x178cd4();break;case'agent':if(!_0xcb419[_0x58feee('0x756')])_0x477ad7();break;case _0x58feee('0x1d2f'):_0xd1437d();break;}}function _0x56a7c5(){_0x56dfde();}function _0x5a28ef(){const _0x1a9037=_0x22890c;_0xcb419[_0x1a9037('0x17f')]=[],_0x259bbd[_0x1a9037('0x25e2')][_0x1a9037('0xc8f')]({'id':_0x1faf2b[_0x1a9037('0x7f2')]['id']},_0xcb419[_0x1a9037('0x179f')])[_0x1a9037('0xe53')]['then'](function(_0x13097f){const _0x41cb99=_0x1a9037;_0xcb419['allConditions'][_0x41cb99('0x1167')](_0x13097f[_0x41cb99('0x24e1')]()),_0x27ff3e[_0x41cb99('0x53')]({'title':_0xa4497f[_0x41cb99('0x2728')](_0x41cb99('0x8f8'))}),_0x488728(_0xcb419[_0x41cb99('0x24a7')]);})[_0x1a9037('0x130a')](function(_0x19d086){const _0x502a26=_0x1a9037;if(_0x19d086[_0x502a26('0x5a5')]&&_0x19d086[_0x502a26('0x5a5')][_0x502a26('0x17f')]&&_0x19d086[_0x502a26('0x5a5')][_0x502a26('0x17f')]['length']){_0xcb419['errors']=_0x19d086['data']['errors']||[{'message':_0x19d086[_0x502a26('0x1ff0')](),'type':_0x502a26('0x2821')}];for(let _0x209512=0x0;_0x209512<_0x19d086[_0x502a26('0x5a5')][_0x502a26('0x17f')][_0x502a26('0x1564')];_0x209512+=0x1){_0x27ff3e[_0x502a26('0x52a')]({'title':_0x19d086['data']['errors'][_0x209512][_0x502a26('0xcf0')],'msg':_0x19d086[_0x502a26('0x5a5')][_0x502a26('0x17f')][_0x209512][_0x502a26('0x8c2')]});}}else _0x27ff3e[_0x502a26('0x52a')]({'title':_0x19d086[_0x502a26('0x13ee')]?_0x502a26('0x2168')+_0x19d086[_0x502a26('0x13ee')]+'\x20-\x20'+_0x19d086[_0x502a26('0x24a9')]:_0x502a26('0x2821'),'msg':_0x19d086['data']?JSON[_0x502a26('0x258a')](_0x19d086[_0x502a26('0x5a5')][_0x502a26('0x8c2')]):_0x19d086['toString']()});});}function _0x5ade75(){const _0x18c406=_0x22890c;_0xcb419[_0x18c406('0x17f')]=[],_0x259bbd[_0x18c406('0x168e')][_0x18c406('0x2480')]({'id':_0xcb419[_0x18c406('0x179f')]['id']},_0xcb419['allCondition'])[_0x18c406('0xe53')][_0x18c406('0x683')](function(){const _0x47a197=_0x18c406;_0xcb419[_0x47a197('0x24a7')]=_0x2e3ca0()[_0x47a197('0x386')](_0xcb419['allConditions'],function(_0x52634d){const _0x4e78b0=_0x47a197;if(_0x52634d['id']===_0xcb419[_0x4e78b0('0x179f')]['id'])return _0xcb419[_0x4e78b0('0x179f')];else return _0x52634d;}),_0x27ff3e['success']({'title':_0xa4497f[_0x47a197('0x2728')](_0x47a197('0xf0'))}),_0x488728(_0xcb419[_0x47a197('0x24a7')]);})[_0x18c406('0x130a')](function(_0x4ee5d7){const _0x2f2ca4=_0x18c406;if(_0x4ee5d7[_0x2f2ca4('0x5a5')]&&_0x4ee5d7[_0x2f2ca4('0x5a5')][_0x2f2ca4('0x17f')]&&_0x4ee5d7[_0x2f2ca4('0x5a5')][_0x2f2ca4('0x17f')][_0x2f2ca4('0x1564')]){_0xcb419[_0x2f2ca4('0x17f')]=_0x4ee5d7[_0x2f2ca4('0x5a5')][_0x2f2ca4('0x17f')]||[{'message':_0x4ee5d7[_0x2f2ca4('0x1ff0')](),'type':_0x2f2ca4('0x55f')}];for(let _0x4cb8e0=0x0;_0x4cb8e0<_0x4ee5d7['data'][_0x2f2ca4('0x17f')]['length'];_0x4cb8e0++){_0x27ff3e[_0x2f2ca4('0x52a')]({'title':_0x4ee5d7[_0x2f2ca4('0x5a5')][_0x2f2ca4('0x17f')][_0x4cb8e0]['type'],'msg':_0x4ee5d7['data'][_0x2f2ca4('0x17f')][_0x4cb8e0][_0x2f2ca4('0x8c2')]});}}else _0x27ff3e['error']({'title':_0x4ee5d7[_0x2f2ca4('0x13ee')]?_0x2f2ca4('0x2168')+_0x4ee5d7[_0x2f2ca4('0x13ee')]+_0x2f2ca4('0xbf6')+_0x4ee5d7[_0x2f2ca4('0x24a9')]:'api.condition.update','msg':_0x4ee5d7['data']?JSON['stringify'](_0x4ee5d7[_0x2f2ca4('0x5a5')][_0x2f2ca4('0x8c2')]):_0x4ee5d7['toString']()});});}function _0x29698c(_0x2ae1a8){const _0xd27ec1=_0x22890c;_0xcb419[_0xd27ec1('0x17f')]=[];const _0x2f0ef0=_0x5424fd[_0xd27ec1('0x1c6f')]({'skipHide':!![]})[_0xd27ec1('0xf28')](_0xa4497f[_0xd27ec1('0x2728')](_0xd27ec1('0x26e1')))[_0xd27ec1('0x1040')]('Delete\x20condition')['ok'](_0xa4497f['instant']('TOOLS.DELETE'))[_0xd27ec1('0x19fb')](_0xa4497f[_0xd27ec1('0x2728')](_0xd27ec1('0x9a1')))[_0xd27ec1('0xe42')](_0x2ae1a8);_0x5424fd[_0xd27ec1('0x1d4')](_0x2f0ef0)[_0xd27ec1('0x683')](function(){const _0x24d549=_0xd27ec1;_0x259bbd['condition'][_0x24d549('0xd7e')]({'id':_0xcb419[_0x24d549('0x179f')]['id']})['$promise']['then'](function(){const _0x35a114=_0x24d549;_0xcb419[_0x35a114('0x24a7')]=_0x2e3ca0()[_0x35a114('0x25')](_0xcb419[_0x35a114('0x24a7')],function(_0x3e9272){const _0x3a7aa6=_0x35a114;return _0x3e9272['id']!==_0xcb419[_0x3a7aa6('0x179f')]['id'];}),_0x27ff3e[_0x35a114('0x53')]({'title':_0xa4497f[_0x35a114('0x2728')](_0x35a114('0x1c5'))}),_0x488728(_0xcb419[_0x35a114('0x24a7')]);})[_0x24d549('0x130a')](function(_0x660f64){const _0x39a782=_0x24d549;if(_0x660f64[_0x39a782('0x5a5')]&&_0x660f64[_0x39a782('0x5a5')][_0x39a782('0x17f')]&&_0x660f64[_0x39a782('0x5a5')][_0x39a782('0x17f')][_0x39a782('0x1564')]){_0xcb419[_0x39a782('0x17f')]=_0x660f64[_0x39a782('0x5a5')][_0x39a782('0x17f')]||[{'message':_0x660f64[_0x39a782('0x1ff0')](),'type':_0x39a782('0x1be3')}];for(let _0x373ea6=0x0;_0x373ea6<_0x660f64[_0x39a782('0x5a5')][_0x39a782('0x17f')][_0x39a782('0x1564')];_0x373ea6++){_0x27ff3e[_0x39a782('0x52a')]({'title':_0x660f64[_0x39a782('0x5a5')][_0x39a782('0x17f')][_0x373ea6]['type'],'msg':_0x660f64[_0x39a782('0x5a5')]['errors'][_0x373ea6][_0x39a782('0x8c2')]});}}else _0x27ff3e[_0x39a782('0x52a')]({'title':_0x660f64['status']?_0x39a782('0x2168')+_0x660f64[_0x39a782('0x13ee')]+_0x39a782('0xbf6')+_0x660f64[_0x39a782('0x24a9')]:_0x39a782('0x1be3'),'msg':_0x660f64[_0x39a782('0x5a5')]?JSON[_0x39a782('0x258a')](_0x660f64['data'][_0x39a782('0x8c2')]):_0x660f64[_0x39a782('0x8c2')]||_0x660f64[_0x39a782('0x1ff0')]()});});},function(){});}function _0x488728(_0x4249ba){const _0x24bffd=_0x22890c;_0x5424fd[_0x24bffd('0x1715')](_0x4249ba);}}const _0x2804ba=_0x1b1af3;_0x3f6c0[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x1d08'),'license',_0x189033('0x260a'),_0x189033('0x56b'),'toasty',_0x189033('0xba1'),_0x189033('0x25e2'),_0x189033('0x22df')];function _0x3f6c0(_0x3453f5,_0x3b2536,_0x317490,_0xadbc1b,_0x6043a7,_0x2ff327,_0x592a23,_0x49adca,_0x4cf7ad){const _0x33ece6=_0x189033,_0x166d77=this;_0x166d77[_0x33ece6('0x11ed')]=_0x592a23[_0x33ece6('0x20b2')](),_0x166d77[_0x33ece6('0xace')]=_0x317490,_0x166d77[_0x33ece6('0x260a')]=_0xadbc1b,_0x166d77[_0x33ece6('0x25e2')]=_0x49adca||_0x3453f5['params'][_0x33ece6('0x25e2')]||{},_0x166d77[_0x33ece6('0x517')]=_0x3453f5[_0x33ece6('0x7f2')]['tab']||0x0;_0x3453f5['params'][_0x33ece6('0x1134')]?_0x166d77[_0x33ece6('0x1134')]=_0x3453f5[_0x33ece6('0x7f2')][_0x33ece6('0x1134')]:(_0x166d77['userProfileSection']=_0x4cf7ad&&_0x4cf7ad['count']==0x1?_0x4cf7ad['rows'][0x0]:null,_0x166d77[_0x33ece6('0x1134')]=_0x592a23[_0x33ece6('0x142a')](_0x166d77[_0x33ece6('0x22df')]?_0x166d77[_0x33ece6('0x22df')][_0x33ece6('0x1134')]:null));_0x166d77['gotoTriggers']=_0x17339d,_0x166d77['saveTrigger']=_0x58c198;function _0x17339d(){const _0x200eba=_0x33ece6;_0x3453f5['go'](_0x200eba('0x27c5'),{},{'reload':'app.tools.triggers'});}function _0x58c198(){const _0x3a887a=_0x33ece6;_0x6043a7['trigger'][_0x3a887a('0x2480')]({'id':_0x166d77[_0x3a887a('0x25e2')]['id']},_0x166d77['trigger'])[_0x3a887a('0xe53')][_0x3a887a('0x683')](function(){const _0x39b04c=_0x3a887a;_0x2ff327[_0x39b04c('0x53')]({'title':_0x3b2536[_0x39b04c('0x2728')]('TOOLS.NOTIFICATIONS.TRIGGER_SAVED_SUCCESS_TITLE')});})[_0x3a887a('0x130a')](function(_0x4a0e6c){const _0x493a18=_0x3a887a;_0x2ff327[_0x493a18('0x52a')]({'title':_0x4a0e6c[_0x493a18('0x13ee')]?_0x493a18('0x2168')+_0x4a0e6c[_0x493a18('0x13ee')]+_0x493a18('0xbf6')+_0x4a0e6c[_0x493a18('0x24a9')]:_0x493a18('0x107f'),'msg':_0x4a0e6c[_0x493a18('0x5a5')]?JSON['stringify'](_0x4a0e6c[_0x493a18('0x5a5')]):_0x4a0e6c[_0x493a18('0x1ff0')]()});});}}const _0x4bd74e=_0x3f6c0,_0x48e9e6=_0x180212['p']+_0x189033('0x18fb');_0xe2e559[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),'triggers',_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),'toasty',_0x189033('0xba1'),_0x189033('0xace'),'setting'];function _0xe2e559(_0x48f97b,_0x382d25,_0x5d09fa,_0x54731f,_0x5d6b35,_0x1d2df3,_0x414c08,_0x5ef883,_0x19a79d,_0x123916,_0x44819e,_0x481a6f,_0x2846e1,_0x533e7e){const _0x4ed2ef=_0x189033,_0x103357=this;_0x103357[_0x4ed2ef('0xace')]=_0x2846e1,_0x103357[_0x4ed2ef('0x260a')]=_0x533e7e,_0x103357[_0x4ed2ef('0x11ed')]=_0x481a6f[_0x4ed2ef('0x20b2')](),_0x103357[_0x4ed2ef('0x13f2')]=_0x414c08||{'count':0x0,'rows':[]},_0x103357[_0x4ed2ef('0x2a')]=_0x5ef883,_0x103357[_0x4ed2ef('0x22df')]=_0x19a79d&&_0x19a79d[_0x4ed2ef('0x50d')]==0x1?_0x19a79d['rows'][0x0]:null,_0x103357[_0x4ed2ef('0x1134')]=_0x481a6f[_0x4ed2ef('0x142a')](_0x103357['userProfileSection']?_0x103357[_0x4ed2ef('0x22df')]['crudPermissions']:null),_0x103357[_0x4ed2ef('0x1bbd')]=[],_0x103357[_0x4ed2ef('0x23a2')]={'fields':_0x4ed2ef('0xf92'),'sort':_0x4ed2ef('0xc36'),'limit':0xa,'page':0x1},_0x103357[_0x4ed2ef('0x126d')]=_0x3d73bb,_0x103357['createOrEditTrigger']=_0x5ce3e5,_0x103357['success']=_0x3eaa6d,_0x103357[_0x4ed2ef('0x6ba')]=_0x48bb57,_0x103357[_0x4ed2ef('0x194f')]=_0xea4c56,_0x103357[_0x4ed2ef('0x102e')]=_0x464d0a,_0x103357['deleteSelectedTriggers']=_0x4f6547,_0x103357[_0x4ed2ef('0x210')]=_0x18b6ea,_0x103357[_0x4ed2ef('0x2249')]=_0x1a2c6f;function _0x3d73bb(_0x2cd6ef){const _0x3ff39b=_0x4ed2ef;_0x382d25['go'](_0x3ff39b('0x15a0'),{'id':_0x2cd6ef['id'],'trigger':_0x2cd6ef,'crudPermissions':_0x103357[_0x3ff39b('0x1134')]});}function _0x5ce3e5(_0x3047e0,_0x435928){const _0x256baf=_0x4ed2ef;if(_0x103357[_0x256baf('0x1134')][_0x256baf('0x50e')]||_0x103357[_0x256baf('0x1134')]['canDelete']&&!_0x103357[_0x256baf('0x1134')][_0x256baf('0x1978')]){_0x3d73bb(_0x435928);return;}_0x5d09fa['show']({'controller':_0x256baf('0x248'),'controllerAs':'vm','templateUrl':_0x48e9e6,'parent':angular['element'](_0x54731f[_0x256baf('0x18e5')]),'targetEvent':_0x3047e0,'clickOutsideToClose':!![],'locals':{'trigger':_0x435928,'triggers':_0x103357[_0x256baf('0x13f2')][_0x256baf('0xf5d')],'license':_0x103357[_0x256baf('0xace')],'setting':_0x103357[_0x256baf('0x260a')],'crudPermissions':_0x103357['crudPermissions']}})[_0x256baf('0x683')](function(_0xc7f2b8){const _0x4e82ad=_0x256baf;_0xc7f2b8&&(_0x103357[_0x4e82ad('0x13f2')]={'count':_0xc7f2b8[_0x4e82ad('0x1564')],'rows':_0xc7f2b8});});}function _0x3eaa6d(_0x50e15d){const _0x305cb4=_0x4ed2ef;_0x103357[_0x305cb4('0x13f2')]=_0x50e15d||{'count':0x0,'rows':[]};}function _0x48bb57(){const _0x2fd637=_0x4ed2ef;_0x103357[_0x2fd637('0x23a2')][_0x2fd637('0x1cc8')]=(_0x103357[_0x2fd637('0x23a2')][_0x2fd637('0xdf8')]-0x1)*_0x103357[_0x2fd637('0x23a2')][_0x2fd637('0x6f0')],_0x481a6f[_0x2fd637('0x1d32')]()?_0x103357[_0x2fd637('0x1883')]=_0x123916[_0x2fd637('0x25e2')][_0x2fd637('0x1e6e')](_0x103357[_0x2fd637('0x23a2')],_0x3eaa6d)['$promise']:(_0x103357['query']['id']=_0x103357[_0x2fd637('0x2a')]['id'],_0x103357[_0x2fd637('0x23a2')]['section']=_0x2fd637('0x220c'),_0x103357['promise']=_0x123916['userProfile'][_0x2fd637('0x241d')](_0x103357[_0x2fd637('0x23a2')],_0x3eaa6d)['$promise']);}function _0xea4c56(_0x187959,_0x245437){const _0x17d406=_0x4ed2ef,_0x103973=_0x5d09fa[_0x17d406('0x1c6f')]()[_0x17d406('0xf28')](_0x1d2df3[_0x17d406('0x2728')](_0x17d406('0x1a98')))['content'](_0x1d2df3[_0x17d406('0x2728')](_0x17d406('0xe6d'),{'name':_0x187959['name']}))[_0x17d406('0x1040')]('Delete\x20trigger')['targetEvent'](_0x245437)['ok']('OK')[_0x17d406('0x19fb')](_0x1d2df3[_0x17d406('0x2728')](_0x17d406('0x9a1')));_0x5d09fa[_0x17d406('0x1d4')](_0x103973)[_0x17d406('0x683')](function(){_0x31572b(_0x187959,!![]);});}function _0x31572b(_0x4106b8,_0x490ee9){const _0x4d34c0=_0x4ed2ef;_0x123916[_0x4d34c0('0x25e2')][_0x4d34c0('0xd7e')]({'id':_0x4106b8['id']})[_0x4d34c0('0xe53')][_0x4d34c0('0x683')](function(){const _0x197c25=_0x4d34c0;_0x48bb57(),_0x490ee9&&_0x44819e['success']({'title':_0x1d2df3[_0x197c25('0x2728')](_0x197c25('0x217f'))});})[_0x4d34c0('0x130a')](function(_0x1f6232){const _0x69a864=_0x4d34c0;if(_0x1f6232[_0x69a864('0x5a5')]&&_0x1f6232[_0x69a864('0x5a5')][_0x69a864('0x17f')]&&_0x1f6232[_0x69a864('0x5a5')][_0x69a864('0x17f')]['length']){_0x103357[_0x69a864('0x17f')]=_0x1f6232[_0x69a864('0x5a5')][_0x69a864('0x17f')]||[{'message':_0x1f6232[_0x69a864('0x1ff0')](),'type':_0x69a864('0xd48')}];for(let _0x4ca9c2=0x0;_0x4ca9c2<_0x1f6232[_0x69a864('0x5a5')][_0x69a864('0x17f')]['length'];_0x4ca9c2++){_0x44819e['error']({'title':_0x1f6232[_0x69a864('0x5a5')][_0x69a864('0x17f')][_0x4ca9c2][_0x69a864('0xcf0')],'msg':_0x1f6232[_0x69a864('0x5a5')][_0x69a864('0x17f')][_0x4ca9c2][_0x69a864('0x8c2')]});}}else _0x44819e[_0x69a864('0x52a')]({'title':_0x1f6232[_0x69a864('0x13ee')]?_0x69a864('0x2168')+_0x1f6232[_0x69a864('0x13ee')]+'\x20-\x20'+_0x1f6232['statusText']:_0x69a864('0xd48'),'msg':_0x1f6232[_0x69a864('0x5a5')]?JSON[_0x69a864('0x258a')](_0x1f6232[_0x69a864('0x5a5')][_0x69a864('0x8c2')]):_0x1f6232['message']||_0x1f6232[_0x69a864('0x1ff0')]()});});}function _0x464d0a(){const _0x574f2f=_0x4ed2ef,_0x2f669a=angular[_0x574f2f('0x1a86')](_0x103357['selectedTriggers']);return _0x103357[_0x574f2f('0x1bbd')]=[],_0x2f669a;}function _0x4f6547(_0x3a7611){const _0x48f005=_0x4ed2ef,_0x3305b5=_0x5d09fa[_0x48f005('0x1c6f')]()[_0x48f005('0xf28')](_0x1d2df3[_0x48f005('0x2728')](_0x48f005('0x271d')))[_0x48f005('0xa6a')](_0x1d2df3['instant'](_0x48f005('0x13c6'),{'total':_0x103357[_0x48f005('0x1bbd')]['length']}))[_0x48f005('0x1040')](_0x48f005('0x1d11'))[_0x48f005('0xe42')](_0x3a7611)['ok']('OK')['cancel'](_0x1d2df3[_0x48f005('0x2728')](_0x48f005('0x9a1')));_0x5d09fa[_0x48f005('0x1d4')](_0x3305b5)[_0x48f005('0x683')](function(){const _0x349203=_0x48f005;_0x103357['selectedTriggers'][_0x349203('0x1299')](function(_0x27c7b4){_0x31572b(_0x27c7b4);}),_0x103357[_0x349203('0x1bbd')]=[],_0x44819e[_0x349203('0x53')]({'title':_0x1d2df3[_0x349203('0x2728')](_0x349203('0x1264'))});});}function _0x18b6ea(){const _0xb4593f=_0x4ed2ef;_0x103357[_0xb4593f('0x1bbd')]=[];}function _0x1a2c6f(){const _0x18d55f=_0x4ed2ef;_0x103357[_0x18d55f('0x1bbd')]=_0x103357['triggers'][_0x18d55f('0xf5d')];}let _0x35198e=!![],_0xde32ca=0x1;_0x48f97b[_0x4ed2ef('0x186d')]('vm.query.filter',function(_0x13d322,_0x5d6533){const _0x231320=_0x4ed2ef;_0x35198e?_0x5d6b35(function(){_0x35198e=![];}):(!_0x5d6533&&(_0xde32ca=_0x103357[_0x231320('0x23a2')][_0x231320('0xdf8')]),_0x13d322!==_0x5d6533&&(_0x103357[_0x231320('0x23a2')][_0x231320('0xdf8')]=0x1),!_0x13d322&&(_0x103357['query'][_0x231320('0xdf8')]=_0xde32ca),_0x48bb57());});}const _0xe41b30=_0xe2e559;_0x3e8248['$inject']=[_0x189033('0x1398')];function _0x3e8248(_0x2583a0){const _0x3efc1a=_0x189033;_0x2583a0[_0x3efc1a('0x2598')](_0x3efc1a('0x27c5'),{'url':_0x3efc1a('0xa58'),'views':{'content@app':{'templateUrl':_0xcddef1,'controller':_0x3efc1a('0x1d50')}},'resolve':{'triggers':[_0x3efc1a('0x4b1'),_0x3efc1a('0xba1'),function(_0x18ffd9,_0x187007){const _0x57b781=_0x3efc1a;return _0x187007[_0x57b781('0xca1')](_0x57b781('0x20c2'))?_0x18ffd9[_0x57b781('0xed7')](_0x57b781('0x1796'),{'fields':_0x57b781('0xd6a'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x18ffd9[_0x57b781('0xed7')](_0x57b781('0x191b'),{'id':_0x187007['getCurrentUser']()[_0x57b781('0x2f')],'section':_0x57b781('0x220c'),'fields':_0x57b781('0xd6a'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x3efc1a('0xba1'),function(_0x3955f4,_0x483686){const _0x55c3e9=_0x3efc1a;return _0x483686['hasRole'](_0x55c3e9('0x20c2'))?null:_0x3955f4[_0x55c3e9('0xed7')](_0x55c3e9('0x1464'),{'fields':_0x55c3e9('0x16f'),'id':_0x483686[_0x55c3e9('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x3efc1a('0x4b1'),_0x3efc1a('0xba1'),function(_0x4b7334,_0x28a000){const _0x3cbe5a=_0x3efc1a;return _0x28a000[_0x3cbe5a('0xca1')](_0x3cbe5a('0x20c2'))?null:_0x4b7334[_0x3cbe5a('0xed7')]('userProfileSection@get',{'fields':_0x3cbe5a('0x1f47'),'userProfileId':_0x28a000[_0x3cbe5a('0x20b2')]()[_0x3cbe5a('0x2f')],'sectionId':0x3f2});}]},'authenticate':!![],'permissionId':0x3f2,'bodyClass':_0x3efc1a('0x1f88')})[_0x3efc1a('0x2598')]('app.tools.triggers.edit',{'url':'/:id?tab','params':{'trigger':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x45fd47,'controller':_0x3efc1a('0x25db')}},'resolve':{'trigger':[_0x3efc1a('0x4b1'),'$stateParams',function(_0x26dedb,_0x131903){const _0x4aa405=_0x3efc1a;return _0x26dedb['resolve'](_0x4aa405('0x1796'),{'fields':_0x4aa405('0xd6a'),'id':_0x131903['id']});}],'userProfileSection':[_0x3efc1a('0x4b1'),_0x3efc1a('0xba1'),function(_0x2d482e,_0x58bc5b){const _0x4350fb=_0x3efc1a;return _0x2d482e['resolve'](_0x4350fb('0x360'),{'fields':_0x4350fb('0x1f47'),'userProfileId':_0x58bc5b['getCurrentUser']()[_0x4350fb('0x2f')],'sectionId':0x3f2});}]},'authenticate':!![],'permissionId':0x3f2,'bodyClass':'tools'});}angular[_0x189033('0x1e26')](_0x189033('0x27c5'),[])[_0x189033('0x272d')](_0x3e8248)[_0x189033('0x1da3')](_0x189033('0x248'),_0x1baac8)[_0x189033('0x1da3')](_0x189033('0xc6f'),_0x415b1f)['controller']('CreateOrEditActionDialogController',_0x4f2410)[_0x189033('0x1da3')](_0x189033('0x100'),_0x28a3b5)[_0x189033('0x1da3')]('CreateOrEditAllConditionDialogController',_0x5724f5)[_0x189033('0x1da3')](_0x189033('0x800'),_0x3fd461)['controller'](_0x189033('0xb5'),_0x2804ba)['controller'](_0x189033('0x1afd'),_0x4bd74e)[_0x189033('0x1da3')](_0x189033('0x2065'),_0xe41b30);const _0x3f201e=_0x180212['p']+_0x189033('0x548'),_0x179fd9=_0x180212['p']+'src/js/modules/main/apps/tools/views/customDashboards/customDashboards.html/customDashboards.html',_0x1ddd1e=_0x180212['p']+_0x189033('0x1034'),_0x4cbe35=_0x180212['p']+_0x189033('0x1178'),_0x5f24b3=_0x180212['p']+'src/js/modules/main/apps/tools/views/intervals/edit/view.html/view.html',_0x597f2f=_0x180212['p']+_0x189033('0x737'),_0xc41af9=_0x180212['p']+'src/js/modules/main/apps/tools/views/schedules/schedules.html/schedules.html',_0x1473ca=_0x180212['p']+_0x189033('0x2216'),_0x3005f2=_0x180212['p']+_0x189033('0x1cb'),_0x1edf0a=_0x180212['p']+_0x189033('0x141b'),_0x2f5a52=_0x180212['p']+_0x189033('0xf5b'),_0x454471=_0x180212['p']+_0x189033('0x1465'),_0x572121=_0x180212['p']+_0x189033('0xffe'),_0x295543=_0x180212['p']+_0x189033('0x5ab');_0x447a3f['$inject']=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav','$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x111c'),_0x189033('0x2a'),'userProfileSection',_0x189033('0x56b'),'msUtils','toasty',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x447a3f(_0x116f62,_0x169576,_0x2171a3,_0x1808d9,_0x5b459b,_0x44a77b,_0x21e551,_0x44f26a,_0x273c67,_0x81f325,_0x587faf,_0x5a2d97,_0x4540,_0x5f0924,_0x384732,_0x45a8a1,_0x179be7){const _0x3d64c3=_0x189033,_0x323218=this;_0x323218['license']=_0x45a8a1,_0x323218[_0x3d64c3('0x260a')]=_0x179be7,_0x323218[_0x3d64c3('0x11ed')]=_0x384732[_0x3d64c3('0x20b2')](),_0x323218[_0x3d64c3('0x111c')]=_0x273c67||{'count':0x0,'rows':[]},_0x323218[_0x3d64c3('0x2a')]=_0x81f325,_0x323218['userProfileSection']=_0x587faf&&_0x587faf[_0x3d64c3('0x50d')]==0x1?_0x587faf[_0x3d64c3('0xf5d')][0x0]:null,_0x323218[_0x3d64c3('0x1134')]=_0x384732[_0x3d64c3('0x142a')](_0x323218[_0x3d64c3('0x22df')]?_0x323218[_0x3d64c3('0x22df')][_0x3d64c3('0x1134')]:null),_0x323218['table']=_0x3d64c3('0x111c'),_0x323218['listOrder']='',_0x323218[_0x3d64c3('0x1ce2')]=null,_0x323218[_0x3d64c3('0xb81')]=[],_0x323218[_0x3d64c3('0x23a2')]={'fields':'createdAt,updatedAt,id,key,value,description','sort':_0x3d64c3('0xc36'),'MailAccountId':_0x3d64c3('0x13c'),'FaxAccountId':_0x3d64c3('0x13c'),'SmsAccountId':_0x3d64c3('0x13c'),'OpenchannelAccountId':_0x3d64c3('0x13c'),'ChatWebsiteId':'null','limit':0xa,'page':0x1},_0x323218[_0x3d64c3('0x1249')]=_0x1a6c35,_0x323218[_0x3d64c3('0x194f')]=_0x51ea7b,_0x323218[_0x3d64c3('0x53')]=_0x357818,_0x323218['getCannedAnswers']=_0x561f16,_0x323218['createOrEditCannedAnswer']=_0x234884,_0x323218[_0x3d64c3('0x1432')]=_0x3883cc,_0x323218[_0x3d64c3('0x53d')]=_0x40c1a1,_0x323218[_0x3d64c3('0x1ad1')]=_0x44956a,_0x323218[_0x3d64c3('0x193b')]=_0xc7484f,_0x323218[_0x3d64c3('0xeb0')]=_0x44e6ad;function _0x1a6c35(_0x58df5b,_0x397811){const _0x16c8e1=_0x3d64c3;_0x5b459b['show']({'controller':_0x16c8e1('0x248b'),'controllerAs':'vm','templateUrl':_0x295543,'parent':angular[_0x16c8e1('0x1fcc')](_0x44a77b[_0x16c8e1('0x18e5')]),'targetEvent':_0x397811,'clickOutsideToClose':!![],'locals':{'cannedAnswer':_0x58df5b,'cannedAnswers':_0x323218[_0x16c8e1('0x111c')][_0x16c8e1('0xf5d')],'license':_0x323218[_0x16c8e1('0xace')],'setting':null,'crudPermissions':_0x323218[_0x16c8e1('0x1134')]}});}function _0x51ea7b(_0x5c23d9,_0x3ec402){const _0x158c6f=_0x3d64c3,_0x5dcc03=_0x5b459b[_0x158c6f('0x1c6f')]()['title'](_0x158c6f('0x1b01')+_0x2e3ca0()[_0x158c6f('0x1e03')]('cannedAnswer')+'?')[_0x158c6f('0x26e3')](''+(_0x5c23d9[_0x158c6f('0x60a')]||_0x158c6f('0x136c'))+_0x158c6f('0x20f1')+_0x158c6f('0x1ee7'))[_0x158c6f('0x1040')](_0x158c6f('0x1247'))['targetEvent'](_0x3ec402)['ok']('OK')[_0x158c6f('0x19fb')](_0x158c6f('0x16b8'));_0x5b459b['show'](_0x5dcc03)['then'](function(){_0x3883cc(_0x5c23d9);},function(){const _0x2bbec1=_0x158c6f;console[_0x2bbec1('0x1b2b')]('CANCEL');});}let _0x4c6510=!![],_0x1e4c80=0x1;_0x116f62[_0x3d64c3('0x186d')]('vm.query.filter',function(_0x139de2,_0x5305eb){const _0x4c0f8d=_0x3d64c3;_0x4c6510?_0x21e551(function(){_0x4c6510=![];}):(!_0x5305eb&&(_0x1e4c80=_0x323218['query']['page']),_0x139de2!==_0x5305eb&&(_0x323218[_0x4c0f8d('0x23a2')][_0x4c0f8d('0xdf8')]=0x1),!_0x139de2&&(_0x323218[_0x4c0f8d('0x23a2')]['page']=_0x1e4c80),_0x323218[_0x4c0f8d('0x6dc')]());});function _0x357818(_0x401f8d){const _0x2fb8a9=_0x3d64c3;_0x323218[_0x2fb8a9('0x111c')]=_0x401f8d||{'count':0x0,'rows':[]};}function _0x561f16(){const _0x338d13=_0x3d64c3;_0x323218[_0x338d13('0x23a2')]['offset']=(_0x323218[_0x338d13('0x23a2')][_0x338d13('0xdf8')]-0x1)*_0x323218[_0x338d13('0x23a2')][_0x338d13('0x6f0')],_0x384732[_0x338d13('0xca1')](_0x338d13('0x20c2'))?_0x323218[_0x338d13('0x1883')]=_0x5a2d97[_0x338d13('0x136c')][_0x338d13('0x1e6e')](_0x323218[_0x338d13('0x23a2')],_0x357818)[_0x338d13('0xe53')]:(_0x323218['query']['id']=_0x323218[_0x338d13('0x2a')]['id'],_0x323218['query']['section']=_0x338d13('0x14f6'),_0x323218[_0x338d13('0x1883')]=_0x5a2d97['userProfile'][_0x338d13('0x241d')](_0x323218[_0x338d13('0x23a2')],_0x357818)[_0x338d13('0xe53')]);}function _0x234884(_0xc44ad7,_0x5c34e4){const _0x220dce=_0x3d64c3;_0x5b459b['show']({'controller':_0x220dce('0x248b'),'controllerAs':'vm','templateUrl':_0x295543,'parent':angular[_0x220dce('0x1fcc')](_0x44a77b[_0x220dce('0x18e5')]),'targetEvent':_0xc44ad7,'clickOutsideToClose':!![],'locals':{'cannedAnswer':_0x5c34e4,'cannedAnswers':_0x323218[_0x220dce('0x111c')][_0x220dce('0xf5d')],'license':_0x323218[_0x220dce('0xace')],'setting':_0x323218['setting'],'crudPermissions':_0x323218[_0x220dce('0x1134')]}});}function _0x3883cc(_0x2c11d7){const _0x409afe=_0x3d64c3;_0x5a2d97[_0x409afe('0x136c')][_0x409afe('0xd7e')]({'id':_0x2c11d7['id']})[_0x409afe('0xe53')][_0x409afe('0x683')](function(){const _0x2485fe=_0x409afe;_0x2e3ca0()[_0x2485fe('0x3ec')](_0x323218[_0x2485fe('0x111c')][_0x2485fe('0xf5d')],{'id':_0x2c11d7['id']}),_0x323218[_0x2485fe('0x111c')][_0x2485fe('0x50d')]-=0x1,!_0x323218[_0x2485fe('0x111c')][_0x2485fe('0xf5d')][_0x2485fe('0x1564')]&&_0x323218['getCannedAnswers'](),_0x5f0924[_0x2485fe('0x53')]({'title':_0x2e3ca0()['startCase']('CannedAnswer')+_0x2485fe('0xbfc'),'msg':_0x2c11d7[_0x2485fe('0x60a')]?_0x2c11d7[_0x2485fe('0x60a')]+_0x2485fe('0x194d'):''});})[_0x409afe('0x130a')](function(_0x35340f){const _0x484094=_0x409afe;if(_0x35340f['data']&&_0x35340f['data']['errors']&&_0x35340f[_0x484094('0x5a5')][_0x484094('0x17f')]['length']){_0x323218[_0x484094('0x17f')]=_0x35340f[_0x484094('0x5a5')][_0x484094('0x17f')]||[{'message':_0x35340f[_0x484094('0x1ff0')](),'type':_0x484094('0x9cd')}];for(let _0x100d3a=0x0;_0x100d3a<_0x35340f['data'][_0x484094('0x17f')][_0x484094('0x1564')];_0x100d3a++){_0x5f0924[_0x484094('0x52a')]({'title':_0x35340f[_0x484094('0x5a5')][_0x484094('0x17f')][_0x100d3a]['type'],'msg':_0x35340f[_0x484094('0x5a5')][_0x484094('0x17f')][_0x100d3a][_0x484094('0x8c2')]});}}else _0x5f0924[_0x484094('0x52a')]({'title':_0x35340f['status']?_0x484094('0x2168')+_0x35340f[_0x484094('0x13ee')]+_0x484094('0xbf6')+_0x35340f['statusText']:_0x484094('0x9cd'),'msg':_0x35340f[_0x484094('0x5a5')]?JSON[_0x484094('0x258a')](_0x35340f['data'][_0x484094('0x8c2')]):_0x35340f[_0x484094('0x8c2')]||_0x35340f[_0x484094('0x1ff0')]()});});}function _0x40c1a1(){const _0x391c11=_0x3d64c3,_0x12c463=angular[_0x391c11('0x1a86')](_0x323218['selectedCannedAnswers']);return _0x323218['selectedCannedAnswers']=[],_0x12c463;}function _0x44956a(_0x4730da){const _0x38e70e=_0x3d64c3,_0x3e8bb9=_0x5b459b[_0x38e70e('0x1c6f')]()[_0x38e70e('0xf28')](_0x38e70e('0xcf8'))[_0x38e70e('0x26e3')](''+_0x323218[_0x38e70e('0xb81')][_0x38e70e('0x1564')]+_0x38e70e('0x93c')+'\x20will\x20be\x20deleted.')[_0x38e70e('0x1040')]('delete\x20CannedAnswers')['targetEvent'](_0x4730da)['ok']('OK')[_0x38e70e('0x19fb')]('CANCEL');_0x5b459b[_0x38e70e('0x1d4')](_0x3e8bb9)[_0x38e70e('0x683')](function(){const _0x422272=_0x38e70e;_0x323218[_0x422272('0xb81')][_0x422272('0x1299')](function(_0xfdeafe){_0x3883cc(_0xfdeafe);}),_0x323218['selectedCannedAnswers']=[];});}function _0xc7484f(){_0x323218['selectedCannedAnswers']=[];}function _0x44e6ad(){const _0x44a114=_0x3d64c3;_0x323218[_0x44a114('0xb81')]=_0x323218['cannedAnswers'][_0x44a114('0xf5d')];}}const _0x5999df=_0x447a3f;_0x434291[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$q','$translate','toasty','cannedAnswers','cannedAnswer',_0x189033('0x56b'),'Auth',_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x434291(_0x2050ba,_0x1216cd,_0x18bb62,_0xca0d13,_0x16df12,_0x5cd7a9,_0x3a05fe,_0x1b53c6,_0x8cb167,_0x43f782,_0x33a799,_0x53f3ac,_0x13c016,_0x4b51d0){const _0x414d47=_0x189033,_0xba8702=this;_0xba8702['currentUser']=_0x33a799['getCurrentUser'](),_0xba8702[_0x414d47('0x17f')]=[],_0xba8702[_0x414d47('0x260a')]=_0x13c016,_0xba8702[_0x414d47('0xace')]=_0x53f3ac,_0xba8702[_0x414d47('0x1134')]=_0x4b51d0,_0xba8702[_0x414d47('0x258d')]={},_0xba8702[_0x414d47('0x19b2')]=_0xba8702[_0x414d47('0x260a')]&&_0xba8702[_0x414d47('0x260a')][_0x414d47('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xba8702['title']='TOOLS.EDIT_CANNEDANSWER',_0xba8702['cannedAnswer']=angular[_0x414d47('0x1a86')](_0x8cb167),_0xba8702[_0x414d47('0x111c')]=_0x1b53c6,_0xba8702['newCannedAnswer']=![];!_0xba8702[_0x414d47('0x136c')]&&(_0xba8702[_0x414d47('0x136c')]={},_0xba8702[_0x414d47('0xf28')]=_0x414d47('0x2515'),_0xba8702[_0x414d47('0x92f')]=!![]);_0xba8702[_0x414d47('0x1546')]=_0x52e163,_0xba8702[_0x414d47('0x19b6')]=_0x9f3df0,_0xba8702['deleteCannedAnswer']=_0x459607,_0xba8702[_0x414d47('0x16b3')]=_0x5db421,_0xba8702['closeDialog']=_0x3eee2a;function _0x52e163(){const _0x286034=_0x414d47;_0xba8702['errors']=[],_0x43f782[_0x286034('0x136c')][_0x286034('0xb0a')](_0xba8702[_0x286034('0x136c')])[_0x286034('0xe53')][_0x286034('0x683')](function(_0x35ad93){const _0x1377b5=_0x286034;_0xba8702[_0x1377b5('0x111c')][_0x1377b5('0x1167')](_0x35ad93['toJSON']()),_0x3a05fe['success']({'title':_0x1377b5('0x1c91'),'msg':_0xba8702[_0x1377b5('0x136c')][_0x1377b5('0x60a')]?_0xba8702['cannedAnswer'][_0x1377b5('0x60a')]+'\x20has\x20been\x20created!':''}),_0x3eee2a(_0x35ad93);})[_0x286034('0x130a')](function(_0x31f1db){const _0x5070d6=_0x286034;if(_0x31f1db[_0x5070d6('0x5a5')]&&_0x31f1db[_0x5070d6('0x5a5')][_0x5070d6('0x17f')]&&_0x31f1db[_0x5070d6('0x5a5')][_0x5070d6('0x17f')][_0x5070d6('0x1564')]){_0xba8702['errors']=_0x31f1db['data'][_0x5070d6('0x17f')]||[{'message':_0x31f1db[_0x5070d6('0x1ff0')](),'type':_0x5070d6('0x267b')}];for(let _0x9e4ad5=0x0;_0x9e4ad5<_0x31f1db[_0x5070d6('0x5a5')][_0x5070d6('0x17f')]['length'];_0x9e4ad5+=0x1){_0x3a05fe['error']({'title':_0x31f1db[_0x5070d6('0x5a5')][_0x5070d6('0x17f')][_0x9e4ad5]['type'],'msg':_0x31f1db['data'][_0x5070d6('0x17f')][_0x9e4ad5][_0x5070d6('0x8c2')]});}}else _0x3a05fe[_0x5070d6('0x52a')]({'title':_0x31f1db[_0x5070d6('0x13ee')]?_0x5070d6('0x2168')+_0x31f1db['status']+'\x20-\x20'+_0x31f1db[_0x5070d6('0x24a9')]:_0x5070d6('0x267b'),'msg':_0x31f1db['data']?JSON['stringify'](_0x31f1db['data']['message']):_0x31f1db[_0x5070d6('0x1ff0')]()});});}function _0x9f3df0(){const _0x35cc63=_0x414d47;_0xba8702['errors']=[],_0x43f782[_0x35cc63('0x136c')][_0x35cc63('0x2480')]({'id':_0xba8702[_0x35cc63('0x136c')]['id']},_0xba8702['cannedAnswer'])['$promise'][_0x35cc63('0x683')](function(_0x4b9f31){const _0x8e4288=_0x35cc63,_0x75a153=_0x2e3ca0()['find'](_0xba8702[_0x8e4288('0x111c')],{'id':_0x4b9f31['id']});_0x75a153&&_0x2e3ca0()[_0x8e4288('0xf22')](_0x75a153,_0x2e3ca0()[_0x8e4288('0x24d0')](_0x4b9f31[_0x8e4288('0x24e1')](),_0x2e3ca0()[_0x8e4288('0x55e')](_0x75a153))),_0x3a05fe[_0x8e4288('0x53')]({'title':_0x8e4288('0x190e'),'msg':_0xba8702['cannedAnswer'][_0x8e4288('0x60a')]?_0xba8702['cannedAnswer'][_0x8e4288('0x60a')]+_0x8e4288('0xf59'):''}),_0x3eee2a(_0x4b9f31);})[_0x35cc63('0x130a')](function(_0x2e2669){const _0x280897=_0x35cc63;if(_0x2e2669[_0x280897('0x5a5')]&&_0x2e2669[_0x280897('0x5a5')][_0x280897('0x17f')]&&_0x2e2669[_0x280897('0x5a5')][_0x280897('0x17f')][_0x280897('0x1564')]){_0xba8702[_0x280897('0x17f')]=_0x2e2669[_0x280897('0x5a5')][_0x280897('0x17f')]||[{'message':_0x2e2669[_0x280897('0x1ff0')](),'type':'api.cannedAnswer.update'}];for(let _0x27c8aa=0x0;_0x27c8aa<_0x2e2669['data']['errors'][_0x280897('0x1564')];_0x27c8aa++){_0x3a05fe['error']({'title':_0x2e2669[_0x280897('0x5a5')][_0x280897('0x17f')][_0x27c8aa]['type'],'msg':_0x2e2669[_0x280897('0x5a5')][_0x280897('0x17f')][_0x27c8aa][_0x280897('0x8c2')]});}}else _0x3a05fe[_0x280897('0x52a')]({'title':_0x2e2669[_0x280897('0x13ee')]?_0x280897('0x2168')+_0x2e2669[_0x280897('0x13ee')]+'\x20-\x20'+_0x2e2669[_0x280897('0x24a9')]:_0x280897('0x1301'),'msg':_0x2e2669['data']?JSON['stringify'](_0x2e2669[_0x280897('0x5a5')]['message']):_0x2e2669[_0x280897('0x1ff0')]()});});}function _0x459607(_0x44cf11){const _0x553c40=_0x414d47;_0xba8702[_0x553c40('0x17f')]=[];const _0x546b93=_0xca0d13['confirm']()[_0x553c40('0xf28')](_0x553c40('0x4d'))[_0x553c40('0xa6a')]('The\x20cannedAnswer\x20will\x20be\x20deleted.')['ariaLabel'](_0x553c40('0x20c8'))['ok'](_0x553c40('0x2307'))['cancel'](_0x553c40('0x253a'))[_0x553c40('0xe42')](_0x44cf11);_0xca0d13[_0x553c40('0x1d4')](_0x546b93)[_0x553c40('0x683')](function(){const _0x322db6=_0x553c40;_0x43f782[_0x322db6('0x136c')]['delete']({'id':_0xba8702[_0x322db6('0x136c')]['id']})['$promise'][_0x322db6('0x683')](function(){const _0x26f2c0=_0x322db6;_0x2e3ca0()[_0x26f2c0('0x3ec')](_0xba8702['cannedAnswers'],{'id':_0xba8702[_0x26f2c0('0x136c')]['id']}),_0x3a05fe[_0x26f2c0('0x53')]({'title':_0x26f2c0('0x2080'),'msg':(_0xba8702[_0x26f2c0('0x136c')][_0x26f2c0('0x60a')]||_0x26f2c0('0x136c'))+_0x26f2c0('0x194d')}),_0x3eee2a(_0xba8702[_0x26f2c0('0x136c')]);})[_0x322db6('0x130a')](function(_0x482fee){const _0x266514=_0x322db6;if(_0x482fee[_0x266514('0x5a5')]&&_0x482fee[_0x266514('0x5a5')][_0x266514('0x17f')]&&_0x482fee['data'][_0x266514('0x17f')][_0x266514('0x1564')]){_0xba8702[_0x266514('0x17f')]=_0x482fee[_0x266514('0x5a5')]['errors']||[{'message':_0x482fee['toString'](),'type':_0x266514('0x253e')}];for(let _0x29aac0=0x0;_0x29aac0<_0x482fee[_0x266514('0x5a5')]['errors']['length'];_0x29aac0++){_0x3a05fe[_0x266514('0x52a')]({'title':_0x482fee[_0x266514('0x5a5')][_0x266514('0x17f')][_0x29aac0]['type'],'msg':_0x482fee['data'][_0x266514('0x17f')][_0x29aac0][_0x266514('0x8c2')]});}}else _0x3a05fe[_0x266514('0x52a')]({'title':_0x482fee[_0x266514('0x13ee')]?'API:'+_0x482fee[_0x266514('0x13ee')]+_0x266514('0xbf6')+_0x482fee[_0x266514('0x24a9')]:_0x266514('0x253e'),'msg':_0x482fee['data']?JSON[_0x266514('0x258a')](_0x482fee[_0x266514('0x5a5')][_0x266514('0x8c2')]):_0x482fee[_0x266514('0x8c2')]||_0x482fee[_0x266514('0x1ff0')]()});});},function(){});}function _0x5db421(_0x55d2dd){return _0x55d2dd===null?undefined:new Date(_0x55d2dd);}function _0x3eee2a(_0x30ed59){const _0x405fdf=_0x414d47;_0xca0d13[_0x405fdf('0x1715')](_0x30ed59);}}const _0x28cc03=_0x434291;_0xfbb8ed[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty',_0x189033('0x111d'),_0x189033('0x22a5'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting','crudPermissions'];function _0xfbb8ed(_0x47b0f5,_0x32a1f9,_0x25539f,_0x4c4e27,_0x3030c4,_0x536ba3,_0x16938,_0x2299dd,_0x34fbe5,_0x555e07,_0x3480ff,_0x517c56,_0x221a39,_0x1d198e){const _0x2b1c2c=_0x189033,_0x52fe82=this;_0x52fe82[_0x2b1c2c('0x11ed')]=_0x3480ff[_0x2b1c2c('0x20b2')](),_0x52fe82[_0x2b1c2c('0x17f')]=[],_0x52fe82[_0x2b1c2c('0x260a')]=_0x221a39,_0x52fe82[_0x2b1c2c('0xace')]=_0x517c56,_0x52fe82[_0x2b1c2c('0x1134')]=_0x1d198e,_0x52fe82[_0x2b1c2c('0x258d')]={},_0x52fe82[_0x2b1c2c('0x19b2')]=_0x52fe82[_0x2b1c2c('0x260a')]&&_0x52fe82[_0x2b1c2c('0x260a')][_0x2b1c2c('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x52fe82[_0x2b1c2c('0xf28')]=_0x2b1c2c('0x13cd'),_0x52fe82[_0x2b1c2c('0x22a5')]=angular[_0x2b1c2c('0x1a86')](_0x34fbe5),_0x52fe82[_0x2b1c2c('0x111d')]=_0x2299dd,_0x52fe82['newCustomDashboard']=![];!_0x52fe82[_0x2b1c2c('0x22a5')]&&(_0x52fe82[_0x2b1c2c('0x22a5')]={},_0x52fe82[_0x2b1c2c('0xf28')]=_0x2b1c2c('0xcf1'),_0x52fe82[_0x2b1c2c('0x1773')]=!![]);_0x52fe82[_0x2b1c2c('0x7ca')]=_0x331531,_0x52fe82[_0x2b1c2c('0x108e')]=_0xfb5a43,_0x52fe82['deleteCustomDashboard']=_0xc29bb6,_0x52fe82[_0x2b1c2c('0x16b3')]=_0x537dec,_0x52fe82[_0x2b1c2c('0xf82')]=_0x5c9d3a;function _0x331531(){const _0x519cf9=_0x2b1c2c;_0x52fe82[_0x519cf9('0x17f')]=[],_0x555e07[_0x519cf9('0x1a6')][_0x519cf9('0xb0a')](_0x52fe82[_0x519cf9('0x22a5')])[_0x519cf9('0xe53')][_0x519cf9('0x683')](function(_0x508523){const _0x1f060e=_0x519cf9;_0x52fe82['customDashboards'][_0x1f060e('0x1167')](_0x508523['toJSON']()),_0x16938[_0x1f060e('0x53')]({'title':_0x1f060e('0x1c1a'),'msg':_0x52fe82[_0x1f060e('0x22a5')][_0x1f060e('0x60a')]?_0x52fe82['customDashboard'][_0x1f060e('0x60a')]+_0x1f060e('0x14b5'):''}),_0x5c9d3a(_0x508523);})[_0x519cf9('0x130a')](function(_0x23616b){const _0x54dfb3=_0x519cf9;if(_0x23616b['data']&&_0x23616b[_0x54dfb3('0x5a5')]['errors']&&_0x23616b['data'][_0x54dfb3('0x17f')][_0x54dfb3('0x1564')]){_0x52fe82[_0x54dfb3('0x17f')]=_0x23616b[_0x54dfb3('0x5a5')]['errors']||[{'message':_0x23616b[_0x54dfb3('0x1ff0')](),'type':_0x54dfb3('0x160')}];for(let _0x3bde1e=0x0;_0x3bde1e<_0x23616b[_0x54dfb3('0x5a5')][_0x54dfb3('0x17f')]['length'];_0x3bde1e+=0x1){_0x16938[_0x54dfb3('0x52a')]({'title':_0x23616b[_0x54dfb3('0x5a5')][_0x54dfb3('0x17f')][_0x3bde1e][_0x54dfb3('0xcf0')],'msg':_0x23616b[_0x54dfb3('0x5a5')][_0x54dfb3('0x17f')][_0x3bde1e][_0x54dfb3('0x8c2')]});}}else _0x16938[_0x54dfb3('0x52a')]({'title':_0x23616b[_0x54dfb3('0x13ee')]?_0x54dfb3('0x2168')+_0x23616b[_0x54dfb3('0x13ee')]+'\x20-\x20'+_0x23616b[_0x54dfb3('0x24a9')]:'api.dashboard.save','msg':_0x23616b[_0x54dfb3('0x5a5')]?JSON[_0x54dfb3('0x258a')](_0x23616b[_0x54dfb3('0x5a5')][_0x54dfb3('0x8c2')]):_0x23616b['toString']()});});}function _0xfb5a43(){const _0x13389a=_0x2b1c2c;_0x52fe82['errors']=[],_0x555e07[_0x13389a('0x1a6')][_0x13389a('0x2480')]({'id':_0x52fe82[_0x13389a('0x22a5')]['id']},_0x52fe82[_0x13389a('0x22a5')])['$promise']['then'](function(_0x472133){const _0x42637a=_0x13389a,_0xba35d1=_0x2e3ca0()['find'](_0x52fe82[_0x42637a('0x111d')],{'id':_0x472133['id']});_0xba35d1&&_0x2e3ca0()[_0x42637a('0xf22')](_0xba35d1,_0x2e3ca0()[_0x42637a('0x24d0')](_0x472133['toJSON'](),_0x2e3ca0()['keys'](_0xba35d1))),_0x16938['success']({'title':_0x42637a('0x177b'),'msg':_0x52fe82['customDashboard'][_0x42637a('0x60a')]?_0x52fe82[_0x42637a('0x22a5')][_0x42637a('0x60a')]+_0x42637a('0xf59'):''}),_0x5c9d3a(_0x472133);})[_0x13389a('0x130a')](function(_0x2299ea){const _0x4c365d=_0x13389a;if(_0x2299ea[_0x4c365d('0x5a5')]&&_0x2299ea[_0x4c365d('0x5a5')][_0x4c365d('0x17f')]&&_0x2299ea[_0x4c365d('0x5a5')][_0x4c365d('0x17f')][_0x4c365d('0x1564')]){_0x52fe82[_0x4c365d('0x17f')]=_0x2299ea[_0x4c365d('0x5a5')][_0x4c365d('0x17f')]||[{'message':_0x2299ea['toString'](),'type':_0x4c365d('0x25f9')}];for(let _0x43b3e5=0x0;_0x43b3e5<_0x2299ea[_0x4c365d('0x5a5')][_0x4c365d('0x17f')][_0x4c365d('0x1564')];_0x43b3e5++){_0x16938['error']({'title':_0x2299ea[_0x4c365d('0x5a5')][_0x4c365d('0x17f')][_0x43b3e5][_0x4c365d('0xcf0')],'msg':_0x2299ea[_0x4c365d('0x5a5')]['errors'][_0x43b3e5][_0x4c365d('0x8c2')]});}}else _0x16938['error']({'title':_0x2299ea['status']?_0x4c365d('0x2168')+_0x2299ea[_0x4c365d('0x13ee')]+_0x4c365d('0xbf6')+_0x2299ea[_0x4c365d('0x24a9')]:_0x4c365d('0x25f9'),'msg':_0x2299ea[_0x4c365d('0x5a5')]?JSON['stringify'](_0x2299ea[_0x4c365d('0x5a5')][_0x4c365d('0x8c2')]):_0x2299ea['toString']()});});}function _0xc29bb6(_0x14b0fa){const _0x17f11c=_0x2b1c2c;_0x52fe82[_0x17f11c('0x17f')]=[];const _0x4d6068=_0x4c4e27[_0x17f11c('0x1c6f')]()[_0x17f11c('0xf28')](_0x17f11c('0x4d'))[_0x17f11c('0xa6a')](_0x17f11c('0x21e9'))[_0x17f11c('0x1040')](_0x17f11c('0x174d'))['ok']('Delete')[_0x17f11c('0x19fb')](_0x17f11c('0x253a'))[_0x17f11c('0xe42')](_0x14b0fa);_0x4c4e27[_0x17f11c('0x1d4')](_0x4d6068)[_0x17f11c('0x683')](function(){const _0x53ad0e=_0x17f11c;_0x555e07['dashboard'][_0x53ad0e('0xd7e')]({'id':_0x52fe82[_0x53ad0e('0x22a5')]['id']})[_0x53ad0e('0xe53')]['then'](function(){const _0x16db7e=_0x53ad0e;_0x2e3ca0()[_0x16db7e('0x3ec')](_0x52fe82[_0x16db7e('0x111d')],{'id':_0x52fe82['customDashboard']['id']}),_0x16938[_0x16db7e('0x53')]({'title':_0x16db7e('0xcf'),'msg':(_0x52fe82[_0x16db7e('0x22a5')]['name']||_0x16db7e('0x22a5'))+_0x16db7e('0x194d')}),_0x5c9d3a(_0x52fe82['customDashboard']);})[_0x53ad0e('0x130a')](function(_0x40b48b){const _0x1257b5=_0x53ad0e;if(_0x40b48b[_0x1257b5('0x5a5')]&&_0x40b48b[_0x1257b5('0x5a5')][_0x1257b5('0x17f')]&&_0x40b48b[_0x1257b5('0x5a5')]['errors'][_0x1257b5('0x1564')]){_0x52fe82[_0x1257b5('0x17f')]=_0x40b48b['data'][_0x1257b5('0x17f')]||[{'message':_0x40b48b['toString'](),'type':'api.dashboard.delete'}];for(let _0xd9ce1a=0x0;_0xd9ce1a<_0x40b48b[_0x1257b5('0x5a5')][_0x1257b5('0x17f')][_0x1257b5('0x1564')];_0xd9ce1a++){_0x16938[_0x1257b5('0x52a')]({'title':_0x40b48b[_0x1257b5('0x5a5')][_0x1257b5('0x17f')][_0xd9ce1a][_0x1257b5('0xcf0')],'msg':_0x40b48b['data'][_0x1257b5('0x17f')][_0xd9ce1a][_0x1257b5('0x8c2')]});}}else _0x16938[_0x1257b5('0x52a')]({'title':_0x40b48b[_0x1257b5('0x13ee')]?_0x1257b5('0x2168')+_0x40b48b[_0x1257b5('0x13ee')]+_0x1257b5('0xbf6')+_0x40b48b[_0x1257b5('0x24a9')]:'api.dashboard.delete','msg':_0x40b48b['data']?JSON[_0x1257b5('0x258a')](_0x40b48b['data'][_0x1257b5('0x8c2')]):_0x40b48b[_0x1257b5('0x8c2')]||_0x40b48b[_0x1257b5('0x1ff0')]()});});},function(){});}function _0x537dec(_0x39497f){return _0x39497f===null?undefined:new Date(_0x39497f);}function _0x5c9d3a(_0x587837){const _0x440dcb=_0x2b1c2c;_0x4c4e27[_0x440dcb('0x1715')](_0x587837);}}const _0x512d96=_0xfbb8ed,_0x57998a=_0x180212['p']+_0x189033('0xa07');_0x3a36d9[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x111d'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),'Auth',_0x189033('0xace'),'setting'];function _0x3a36d9(_0x203278,_0x585d4f,_0x265e7c,_0x4321a0,_0x136c06,_0x4db836,_0x40ed77,_0x3eb4dd,_0x35330a,_0x8d7469,_0x382409,_0xaa7c62,_0x2d01ff,_0x44bccd,_0x224410,_0x317d49,_0x3eb7e1){const _0x176dad=_0x189033,_0x2b25d1=this;_0x2b25d1[_0x176dad('0xace')]=_0x317d49,_0x2b25d1[_0x176dad('0x260a')]=_0x3eb7e1,_0x2b25d1[_0x176dad('0x11ed')]=_0x224410[_0x176dad('0x20b2')](),_0x2b25d1[_0x176dad('0x111d')]=_0x35330a||{'count':0x0,'rows':[]},_0x2b25d1[_0x176dad('0x2a')]=_0x8d7469,_0x2b25d1[_0x176dad('0x22df')]=_0x382409&&_0x382409[_0x176dad('0x50d')]==0x1?_0x382409['rows'][0x0]:null,_0x2b25d1[_0x176dad('0x1134')]=_0x224410[_0x176dad('0x142a')](_0x2b25d1[_0x176dad('0x22df')]?_0x2b25d1[_0x176dad('0x22df')][_0x176dad('0x1134')]:null),_0x2b25d1[_0x176dad('0x5c4')]=_0x176dad('0x111d'),_0x2b25d1[_0x176dad('0x247')]='',_0x2b25d1[_0x176dad('0x1ce2')]=null,_0x2b25d1['selectedCustomDashboards']=[],_0x2b25d1[_0x176dad('0x23a2')]={'fields':_0x176dad('0x120a'),'sort':_0x176dad('0xc36'),'limit':0xa,'page':0x1},_0x2b25d1[_0x176dad('0xc63')]=_0x4c7364,_0x2b25d1['gotodashboardgoto']=_0x53cb60,_0x2b25d1[_0x176dad('0x194f')]=_0x870943,_0x2b25d1[_0x176dad('0x53')]=_0x235edf,_0x2b25d1[_0x176dad('0x139d')]=_0x271ef3,_0x2b25d1['createOrEditCustomDashboard']=_0x2a9ca2,_0x2b25d1[_0x176dad('0x51b')]=_0x1076d3,_0x2b25d1[_0x176dad('0xe9f')]=_0x47e55a,_0x2b25d1[_0x176dad('0xf06')]=_0x29821d,_0x2b25d1[_0x176dad('0x6d0')]=_0x460e4a,_0x2b25d1[_0x176dad('0x242f')]=_0x4d797d;function _0x4c7364(_0x28f77c){const _0x2cbeba=_0x176dad;_0x265e7c['go'](_0x2cbeba('0x1d33'),{'id':_0x28f77c['id'],'customDashboard':_0x28f77c,'crudPermissions':_0x2b25d1[_0x2cbeba('0x1134')]});}function _0x53cb60(_0xc4b8c9){const _0x5ae5ad=_0x176dad;_0x265e7c['go'](_0x5ae5ad('0x1273'),{'id':_0xc4b8c9['id']});}function _0x870943(_0x20b0e2,_0x2d5a56){const _0x515c34=_0x176dad,_0x52a591=_0x136c06[_0x515c34('0x1c6f')]()[_0x515c34('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x515c34('0x1e03')](_0x515c34('0x22a5'))+'?')['htmlContent'](''+(_0x20b0e2['name']||_0x515c34('0x22a5'))+''+_0x515c34('0x1ee7'))[_0x515c34('0x1040')]('delete\x20customDashboard')['targetEvent'](_0x2d5a56)['ok']('OK')[_0x515c34('0x19fb')](_0x515c34('0x16b8'));_0x136c06[_0x515c34('0x1d4')](_0x52a591)['then'](function(){_0x1076d3(_0x20b0e2);},function(){const _0x3bfc68=_0x515c34;console[_0x3bfc68('0x1b2b')](_0x3bfc68('0x16b8'));});}let _0x1d56ca=!![],_0x53bf19=0x1;_0x203278[_0x176dad('0x186d')]('vm.query.filter',function(_0x3c14ff,_0x5e26ff){const _0x13197a=_0x176dad;_0x1d56ca?_0x40ed77(function(){_0x1d56ca=![];}):(!_0x5e26ff&&(_0x53bf19=_0x2b25d1[_0x13197a('0x23a2')][_0x13197a('0xdf8')]),_0x3c14ff!==_0x5e26ff&&(_0x2b25d1[_0x13197a('0x23a2')][_0x13197a('0xdf8')]=0x1),!_0x3c14ff&&(_0x2b25d1[_0x13197a('0x23a2')][_0x13197a('0xdf8')]=_0x53bf19),_0x2b25d1[_0x13197a('0x139d')]());});function _0x235edf(_0x11ded7){const _0x15acbb=_0x176dad;_0x2b25d1[_0x15acbb('0x111d')]=_0x11ded7||{'count':0x0,'rows':[]};}function _0x271ef3(){const _0x3fdc45=_0x176dad;_0x2b25d1[_0x3fdc45('0x23a2')][_0x3fdc45('0x1cc8')]=(_0x2b25d1[_0x3fdc45('0x23a2')][_0x3fdc45('0xdf8')]-0x1)*_0x2b25d1[_0x3fdc45('0x23a2')]['limit'],_0x224410[_0x3fdc45('0xca1')](_0x3fdc45('0x20c2'))?_0x2b25d1['promise']=_0xaa7c62['dashboard'][_0x3fdc45('0x1e6e')](_0x2b25d1[_0x3fdc45('0x23a2')],_0x235edf)['$promise']:(_0x2b25d1[_0x3fdc45('0x23a2')]['id']=_0x2b25d1[_0x3fdc45('0x2a')]['id'],_0x2b25d1[_0x3fdc45('0x23a2')][_0x3fdc45('0x1aa')]='CustomDashboards',_0x2b25d1[_0x3fdc45('0x1883')]=_0xaa7c62[_0x3fdc45('0x2a')]['getResources'](_0x2b25d1[_0x3fdc45('0x23a2')],_0x235edf)[_0x3fdc45('0xe53')]);}function _0x2a9ca2(_0x5101f5,_0x1ecb3f){const _0x4622fa=_0x176dad;_0x136c06[_0x4622fa('0x1d4')]({'controller':'CreateOrEditCustomDashboardDialogController','controllerAs':'vm','templateUrl':_0x57998a,'parent':angular[_0x4622fa('0x1fcc')](_0x4db836['body']),'targetEvent':_0x5101f5,'clickOutsideToClose':!![],'locals':{'customDashboard':_0x1ecb3f,'customDashboards':_0x2b25d1['customDashboards'][_0x4622fa('0xf5d')],'license':_0x2b25d1[_0x4622fa('0xace')],'setting':_0x2b25d1[_0x4622fa('0x260a')],'crudPermissions':_0x2b25d1[_0x4622fa('0x1134')]}});}function _0x1076d3(_0xe814fd){const _0x558e10=_0x176dad;_0xaa7c62[_0x558e10('0x1a6')][_0x558e10('0xd7e')]({'id':_0xe814fd['id']})['$promise'][_0x558e10('0x683')](function(){const _0x2830cb=_0x558e10;_0x2e3ca0()[_0x2830cb('0x3ec')](_0x2b25d1['customDashboards'][_0x2830cb('0xf5d')],{'id':_0xe814fd['id']}),_0x2b25d1[_0x2830cb('0x111d')]['count']-=0x1,!_0x2b25d1['customDashboards'][_0x2830cb('0xf5d')][_0x2830cb('0x1564')]&&_0x2b25d1[_0x2830cb('0x139d')](),_0x44bccd[_0x2830cb('0x53')]({'title':_0x2e3ca0()[_0x2830cb('0x1e03')](_0x2830cb('0x18d8'))+_0x2830cb('0xbfc'),'msg':_0xe814fd['name']?_0xe814fd[_0x2830cb('0x60a')]+_0x2830cb('0x194d'):''});})['catch'](function(_0x46f502){const _0x340fb2=_0x558e10;if(_0x46f502[_0x340fb2('0x5a5')]&&_0x46f502[_0x340fb2('0x5a5')][_0x340fb2('0x17f')]&&_0x46f502[_0x340fb2('0x5a5')][_0x340fb2('0x17f')][_0x340fb2('0x1564')]){_0x2b25d1[_0x340fb2('0x17f')]=_0x46f502[_0x340fb2('0x5a5')][_0x340fb2('0x17f')]||[{'message':_0x46f502[_0x340fb2('0x1ff0')](),'type':'SYSTEM:DELETEdashboard'}];for(let _0x1ee346=0x0;_0x1ee346<_0x46f502[_0x340fb2('0x5a5')][_0x340fb2('0x17f')][_0x340fb2('0x1564')];_0x1ee346++){_0x44bccd[_0x340fb2('0x52a')]({'title':_0x46f502[_0x340fb2('0x5a5')]['errors'][_0x1ee346][_0x340fb2('0xcf0')],'msg':_0x46f502[_0x340fb2('0x5a5')]['errors'][_0x1ee346][_0x340fb2('0x8c2')]});}}else _0x44bccd[_0x340fb2('0x52a')]({'title':_0x46f502['status']?'API:'+_0x46f502[_0x340fb2('0x13ee')]+'\x20-\x20'+_0x46f502[_0x340fb2('0x24a9')]:_0x340fb2('0x1c20'),'msg':_0x46f502[_0x340fb2('0x5a5')]?JSON[_0x340fb2('0x258a')](_0x46f502[_0x340fb2('0x5a5')]['message']):_0x46f502['message']||_0x46f502[_0x340fb2('0x1ff0')]()});});}function _0x47e55a(){const _0x1dac8f=_0x176dad,_0x283424=angular[_0x1dac8f('0x1a86')](_0x2b25d1['selectedCustomDashboards']);return _0x2b25d1[_0x1dac8f('0x2745')]=[],_0x283424;}function _0x29821d(_0x4d6e5c){const _0x103152=_0x176dad,_0x1c01b5=_0x136c06[_0x103152('0x1c6f')]()['title'](_0x103152('0x1e2b'))['htmlContent'](''+_0x2b25d1[_0x103152('0x2745')]['length']+'\x20selected'+_0x103152('0x1ee7'))[_0x103152('0x1040')](_0x103152('0x252a'))[_0x103152('0xe42')](_0x4d6e5c)['ok']('OK')[_0x103152('0x19fb')](_0x103152('0x16b8'));_0x136c06[_0x103152('0x1d4')](_0x1c01b5)['then'](function(){const _0x44b178=_0x103152;_0x2b25d1[_0x44b178('0x2745')][_0x44b178('0x1299')](function(_0x13cbca){_0x1076d3(_0x13cbca);}),_0x2b25d1[_0x44b178('0x2745')]=[];});}function _0x460e4a(){_0x2b25d1['selectedCustomDashboards']=[];}function _0x4d797d(){const _0x4d2d6b=_0x176dad;_0x2b25d1[_0x4d2d6b('0x2745')]=_0x2b25d1[_0x4d2d6b('0x111d')][_0x4d2d6b('0xf5d')];}}const _0x1b192d=_0x3a36d9;_0x456487[_0x189033('0x14be')]=['$mdDialog',_0x189033('0x938'),_0x189033('0x1d70'),_0x189033('0x56b'),'customDashboard',_0x189033('0x111d'),_0x189033('0x1d08')];function _0x456487(_0x1c2370,_0x1326c2,_0x2717ff,_0x48379d,_0x4e1bf1,_0x4dde3f,_0x10fcfb){const _0x38ba45=_0x189033,_0x1ea7ee=this;_0x1ea7ee['newCustomDashboard']=!![],_0x1ea7ee[_0x38ba45('0x22a5')]=angular[_0x38ba45('0x1a86')](_0x4e1bf1),_0x1ea7ee['customDashboards']=_0x4dde3f,_0x1ea7ee['title']=_0x10fcfb['instant'](_0x38ba45('0x221a'));_0x4e1bf1&&_0x4e1bf1[_0x38ba45('0x60a')]&&(_0x1ea7ee['title']+=':\x20'+_0x4e1bf1[_0x38ba45('0x60a')]);_0x1ea7ee[_0x38ba45('0x1b56')]=_0x5652cf,_0x1ea7ee[_0x38ba45('0xf82')]=_0x445c28;function _0x5652cf(){const _0x4d1049=_0x38ba45;return _0x48379d[_0x4d1049('0x1a6')][_0x4d1049('0x147f')]({'id':_0x4e1bf1['id'],'includeAll':!![]},_0x1ea7ee['customDashboard'])['$promise'][_0x4d1049('0x683')](function(_0x2c980a){const _0x30f634=_0x4d1049;_0x1ea7ee[_0x30f634('0x111d')][_0x30f634('0x1167')](_0x2c980a[_0x30f634('0x24e1')]()),_0x2717ff[_0x30f634('0x53')]({'title':_0x30f634('0x20ab'),'msg':_0x1ea7ee[_0x30f634('0x22a5')]['name']?_0x1ea7ee[_0x30f634('0x22a5')][_0x30f634('0x60a')]+'\x20has\x20been\x20cloned!':''}),_0x1326c2['go']('app.tools.customDashboards.edit',{'id':_0x2c980a['id']}),_0x445c28(_0x2c980a);})[_0x4d1049('0x130a')](function(_0x208f7e){const _0x32ecb3=_0x4d1049;if(_0x208f7e[_0x32ecb3('0x5a5')]&&_0x208f7e['data'][_0x32ecb3('0x17f')]&&_0x208f7e['data']['errors'][_0x32ecb3('0x1564')]){_0x1ea7ee['errors']=_0x208f7e[_0x32ecb3('0x5a5')][_0x32ecb3('0x17f')]||[{'message':_0x208f7e[_0x32ecb3('0x1ff0')](),'type':_0x32ecb3('0x773')}];for(let _0x131020=0x0;_0x131020<_0x208f7e[_0x32ecb3('0x5a5')][_0x32ecb3('0x17f')][_0x32ecb3('0x1564')];_0x131020+=0x1){_0x2717ff[_0x32ecb3('0x52a')]({'title':_0x208f7e[_0x32ecb3('0x5a5')][_0x32ecb3('0x17f')][_0x131020][_0x32ecb3('0xcf0')],'msg':_0x208f7e[_0x32ecb3('0x5a5')][_0x32ecb3('0x17f')][_0x131020][_0x32ecb3('0x8c2')]});}}else _0x2717ff[_0x32ecb3('0x52a')]({'title':_0x208f7e[_0x32ecb3('0x13ee')]?_0x32ecb3('0x2168')+_0x208f7e[_0x32ecb3('0x13ee')]+_0x32ecb3('0xbf6')+_0x208f7e['statusText']:_0x32ecb3('0x773'),'msg':_0x208f7e['data']?JSON[_0x32ecb3('0x258a')](_0x208f7e[_0x32ecb3('0x5a5')][_0x32ecb3('0x8c2')]):_0x208f7e['toString']()});});}function _0x445c28(_0x513f22){const _0x5ebe19=_0x38ba45;_0x1c2370[_0x5ebe19('0x1715')](_0x513f22);}}const _0x3213bf=_0x456487,_0x1539cb=_0x180212['p']+_0x189033('0x1358');_0x3e1869['$inject']=[_0x189033('0x1e48'),'$document',_0x189033('0x1556'),'toasty',_0x189033('0x56b')];function _0x3e1869(_0x3e5e28,_0x4d119a,_0x55968a,_0x5a0a23,_0x453fc7){const _0x2d4eec=_0x189033,_0x1feb06=this;_0x1feb06[_0x2d4eec('0x22a5')]={},_0x1feb06[_0x2d4eec('0x426')]=_0x453fc7[_0x2d4eec('0x1b1b')]['getVoiceQueues']({'fields':_0x2d4eec('0xa10')}),_0x1feb06['init']=_0x189f20,_0x1feb06['createOrEditWidget']=_0x5165b2,_0x1feb06[_0x2d4eec('0x1629')]=_0x48d67d;function _0x189f20(_0x117502,_0x372faa){const _0x2dae8b=_0x2d4eec;return _0x1feb06['crudPermissions']=typeof _0x372faa!==_0x2dae8b('0x1867')?_0x372faa:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1feb06['customDashboard']=_0x117502,_0x1feb06[_0x2dae8b('0x22a5')]['draggable']={'enabled':!![],'handle':_0x2dae8b('0xcac'),'stop':_0x55f614},_0x1feb06[_0x2dae8b('0x22a5')][_0x2dae8b('0x174c')]={'enabled':!![],'handle':'.resizable','stop':_0x55f614},_0x1feb06[_0x2dae8b('0x22a5')][_0x2dae8b('0x1ef8')]=[],_0x453fc7['dashboard'][_0x2dae8b('0x25c7')]({'id':_0x117502['id']})[_0x2dae8b('0xe53')][_0x2dae8b('0x683')](function(_0x2702d1){const _0x44aeaa=_0x2dae8b;if(_0x2702d1&&_0x2702d1[_0x44aeaa('0x50d')]&&_0x2702d1[_0x44aeaa('0xf5d')])for(let _0x1ca73a=0x0;_0x1ca73a<_0x2702d1[_0x44aeaa('0xf5d')][_0x44aeaa('0x1564')];_0x1ca73a+=0x1){_0x2702d1[_0x44aeaa('0xf5d')][_0x1ca73a]['voiceQueues']=_0x1feb06['voiceQueues'],_0x2702d1[_0x44aeaa('0xf5d')][_0x1ca73a][_0x44aeaa('0x1890')]=_0x2e3ca0()[_0x44aeaa('0x386')](_0x1feb06[_0x44aeaa('0x426')][_0x44aeaa('0xf5d')],'id'),_0x2702d1[_0x44aeaa('0xf5d')][_0x1ca73a][_0x44aeaa('0x2698')]=_0x44aeaa('0x1b3a')+_0x2702d1[_0x44aeaa('0xf5d')][_0x1ca73a][_0x44aeaa('0xcf0')]+'/ms-widget-engine.'+_0x2702d1[_0x44aeaa('0xf5d')][_0x1ca73a][_0x44aeaa('0xcf0')]+_0x44aeaa('0x1f6'),_0x1feb06[_0x44aeaa('0x22a5')][_0x44aeaa('0x1ef8')][_0x44aeaa('0x1fd0')](_0x2702d1[_0x44aeaa('0xf5d')][_0x1ca73a]);}})[_0x2dae8b('0x130a')](function(_0x3d1af4){const _0x2b955c=_0x2dae8b;console[_0x2b955c('0x52a')](_0x3d1af4);});}function _0x5165b2(_0x2f153f){const _0x301edb=_0x2d4eec;if(_0x2f153f&&_0x2f153f['attrs'])for(let _0x2f7cb8=0x0;_0x2f7cb8<_0x2f153f['attrs'][_0x301edb('0x1564')];_0x2f7cb8+=0x1){_0x2f153f[_0x301edb('0x1221')][_0x2f7cb8][_0x301edb('0x60a')]===_0x301edb('0x8e4')&&(_0x2f153f[_0x301edb('0x750')]=_0x2f153f[_0x301edb('0x1221')][_0x2f7cb8]['type']),_0x2f153f[_0x2f153f['attrs'][_0x2f7cb8]['name']]=_0x2f153f[_0x301edb('0x1221')][_0x2f7cb8][_0x301edb('0x1c6b')];}_0x3e5e28['show']({'controller':_0x301edb('0x33'),'controllerAs':'vm','templateUrl':_0x1539cb,'parent':angular['element'](_0x4d119a[_0x301edb('0x18e5')]),'clickOutsideToClose':!![],'locals':{'dashboarditem':_0x2f153f,'dashboard':_0x1feb06[_0x301edb('0x22a5')][_0x301edb('0x1ef8')],'license':null,'setting':null,'crudPermissions':_0x1feb06[_0x301edb('0x1134')]}})[_0x301edb('0x683')](function(_0x27a454){const _0x41e6e1=_0x301edb;if(_0x27a454)for(let _0x5213a5=0x0;_0x5213a5<_0x1feb06[_0x41e6e1('0x22a5')][_0x41e6e1('0x1ef8')][_0x41e6e1('0x1564')];_0x5213a5+=0x1){_0x1feb06[_0x41e6e1('0x22a5')]['widgets'][_0x5213a5]['id']===_0x27a454['id']&&(_0x1feb06[_0x41e6e1('0x22a5')]['widgets'][_0x5213a5][_0x41e6e1('0x1221')]=_0x27a454[_0x41e6e1('0x1221')],_0x1feb06[_0x41e6e1('0x22a5')][_0x41e6e1('0x1ef8')][_0x5213a5][_0x41e6e1('0x426')]=_0x1feb06['voiceQueues'],_0x1feb06[_0x41e6e1('0x22a5')][_0x41e6e1('0x1ef8')][_0x5213a5][_0x41e6e1('0x1890')]=_0x2e3ca0()[_0x41e6e1('0x386')](_0x1feb06[_0x41e6e1('0x426')][_0x41e6e1('0xf5d')],'id'),_0x1feb06['customDashboard']['widgets'][_0x5213a5]['templateUrl']=_0x41e6e1('0x1b3a')+_0x1feb06[_0x41e6e1('0x22a5')][_0x41e6e1('0x1ef8')][_0x5213a5][_0x41e6e1('0xcf0')]+'/ms-widget-engine.'+_0x1feb06[_0x41e6e1('0x22a5')][_0x41e6e1('0x1ef8')][_0x5213a5][_0x41e6e1('0xcf0')]+_0x41e6e1('0x1f6'));}});}function _0x48d67d(_0x32cf0d){const _0x4917d2=_0x2d4eec,_0x623eb=_0x3e5e28[_0x4917d2('0x1c6f')]()[_0x4917d2('0xf28')](_0x4917d2('0xf5c')+_0x32cf0d[_0x4917d2('0xf28')]+'?')[_0x4917d2('0x1525')]('')['ariaLabel'](_0x4917d2('0x10cd'))['ok'](_0x4917d2('0x13f7'))[_0x4917d2('0x19fb')]('NO');_0x3e5e28['show'](_0x623eb)[_0x4917d2('0x683')](function(){const _0x4c6d68=_0x4917d2;return _0x453fc7[_0x4c6d68('0x2565')][_0x4c6d68('0xd7e')]({'id':_0x32cf0d['id']})[_0x4c6d68('0xe53')][_0x4c6d68('0x683')](function(){const _0x275e66=_0x4c6d68;_0x2e3ca0()['remove'](_0x1feb06['customDashboard']['widgets'],{'id':_0x32cf0d['id']}),_0x5a0a23[_0x275e66('0x53')]({'title':_0x275e66('0xf83'),'msg':_0x32cf0d[_0x275e66('0x60a')]?_0x32cf0d['name']+_0x275e66('0x194d'):_0x275e66('0x1844')});})['catch'](function(_0x5eacd9){const _0x2b4c2f=_0x4c6d68;if(_0x5eacd9[_0x2b4c2f('0x5a5')]&&_0x5eacd9['data'][_0x2b4c2f('0x17f')]&&_0x5eacd9[_0x2b4c2f('0x5a5')]['errors'][_0x2b4c2f('0x1564')]){_0x1feb06[_0x2b4c2f('0x17f')]=_0x5eacd9[_0x2b4c2f('0x5a5')][_0x2b4c2f('0x17f')]||[{'message':_0x5eacd9[_0x2b4c2f('0x1ff0')](),'type':_0x2b4c2f('0x2323')}];for(let _0x43fa36=0x0;_0x43fa36<_0x5eacd9['data']['errors'][_0x2b4c2f('0x1564')];_0x43fa36++){_0x5a0a23[_0x2b4c2f('0x52a')]({'title':_0x5eacd9['data'][_0x2b4c2f('0x17f')][_0x43fa36][_0x2b4c2f('0xcf0')],'msg':_0x5eacd9[_0x2b4c2f('0x5a5')]['errors'][_0x43fa36][_0x2b4c2f('0x8c2')]});}}else _0x5a0a23[_0x2b4c2f('0x52a')]({'title':_0x5eacd9['status']?_0x2b4c2f('0x2168')+_0x5eacd9[_0x2b4c2f('0x13ee')]+_0x2b4c2f('0xbf6')+_0x5eacd9[_0x2b4c2f('0x24a9')]:_0x2b4c2f('0x1c20'),'msg':_0x5eacd9[_0x2b4c2f('0x5a5')]?JSON[_0x2b4c2f('0x258a')](_0x5eacd9[_0x2b4c2f('0x5a5')][_0x2b4c2f('0x8c2')]):_0x5eacd9['message']||_0x5eacd9[_0x2b4c2f('0x1ff0')]()});console[_0x2b4c2f('0x52a')](_0x5eacd9);});});}function _0x55f614(_0x33a573,_0x458a40,_0x32650d){const _0x46ab46=_0x2d4eec;return _0x453fc7['dashboardItem']['update'](_0x32650d)[_0x46ab46('0xe53')][_0x46ab46('0x130a')](function(_0x1f52e1){const _0x2c10de=_0x46ab46;console[_0x2c10de('0x52a')](_0x1f52e1);});}}const _0x3ca130=_0x3e1869,_0x2ed001=_0x180212['p']+'src/js/modules/main/apps/tools/views/customDashboards/partialViews/reports/treeReports.html/treeReports.html';_0x219d04[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state','$location','$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1a6'),_0x189033('0x4a1'),'api',_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x219d04(_0x53906b,_0xa32f6c,_0x454ebf,_0x431e84,_0x540395,_0x2c5131,_0x35f251,_0x2f3b97,_0x175321,_0x37314d,_0x1cad1b,_0x4d5546,_0x2f28c3,_0x557cc7){const _0x3cfca0=_0x189033,_0x3a2fab=this;_0x3a2fab[_0x3cfca0('0x11ed')]=_0x1cad1b[_0x3cfca0('0x20b2')](),_0x3a2fab['errors']=[],_0x3a2fab[_0x3cfca0('0x260a')]=_0x2f28c3,_0x3a2fab[_0x3cfca0('0xace')]=_0x4d5546,_0x3a2fab[_0x3cfca0('0x1134')]=_0x557cc7,_0x3a2fab[_0x3cfca0('0x258d')]={},_0x3a2fab[_0x3cfca0('0x19b2')]=_0x3a2fab[_0x3cfca0('0x260a')]&&_0x3a2fab[_0x3cfca0('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3a2fab[_0x3cfca0('0xf28')]='TOOLS.EDIT_DASHBOARDITEM',_0x3a2fab[_0x3cfca0('0x4a1')]=angular[_0x3cfca0('0x1a86')](_0x175321),_0x3a2fab['dashboard']=_0x2f3b97,_0x3a2fab[_0x3cfca0('0x1ee1')]=![],_0x3a2fab[_0x3cfca0('0xe5a')]=[],_0x3a2fab[_0x3cfca0('0x23a2')]={'fields':_0x3cfca0('0x1664'),'limit':0xa,'page':0x1,'sort':'-updatedAt'};!_0x3a2fab[_0x3cfca0('0x4a1')]?(_0x3a2fab[_0x3cfca0('0x4a1')]={'type':_0x3cfca0('0x288'),'attrUrl':_0x3cfca0('0x552'),'attrHourFormat':'HH:mm:ss','attrTimezone':_0x3cfca0('0x1548'),'attrMetric':_0x3cfca0('0x2263'),'attrSerie1':_0x3cfca0('0x2263'),'attrSerie2':_0x3cfca0('0x13c'),'attrSerie3':_0x3cfca0('0x13c'),'attrRefresh':0xa,'attrFontSize':0x14,'foreground':_0x3cfca0('0x1019'),'background':_0x3cfca0('0x1655')},_0x3a2fab[_0x3cfca0('0xf28')]=_0x3cfca0('0x14fe'),_0x3a2fab['newDashboardItem']=!![]):_0x3a2fab['dashboarditem'][_0x3cfca0('0xcf0')]=='web-report'&&(_0x3a2fab[_0x3cfca0('0x213')]=_0x3a2fab['dashboarditem'][_0x3cfca0('0x750')]===_0x3cfca0('0xbf0')?_0x3cfca0('0x197f'):_0x3cfca0('0x20ec'),_0x37314d[_0x3a2fab[_0x3cfca0('0x213')]][_0x3cfca0('0x1e6e')]({'fields':_0x3cfca0('0x822')})['$promise'][_0x3cfca0('0x683')](function(_0x5a91d3){const _0x31be04=_0x3cfca0;_0x3a2fab[_0x31be04('0x916')]=_0x2e3ca0()[_0x31be04('0x1c07')](_0x5a91d3['rows'],{'id':_0x3a2fab['dashboarditem'][_0x31be04('0x8e4')]}),_0x3a2fab[_0x31be04('0x4a1')]['report']=_0x3a2fab[_0x31be04('0x916')][_0x31be04('0x60a')],_0x3a2fab[_0x31be04('0x23a2')][_0x31be04('0x2361')]=_0x3a2fab[_0x31be04('0x916')][_0x31be04('0x2361')];}));_0x3a2fab[_0x3cfca0('0xbd5')]=_0x482d4d,_0x3a2fab[_0x3cfca0('0x9af')]=_0x48f15d,_0x3a2fab[_0x3cfca0('0x12d3')]=_0x245059,_0x3a2fab['getDateFromString']=_0x4ac6ca,_0x3a2fab[_0x3cfca0('0x2398')]=_0x435f52,_0x3a2fab[_0x3cfca0('0x26f8')]=_0x2e296f,_0x3a2fab[_0x3cfca0('0x417')]=_0x3c4262,_0x3a2fab[_0x3cfca0('0xf0c')]=_0x14362f,_0x3a2fab[_0x3cfca0('0xf82')]=_0x13af2f,_0x37314d[_0x3cfca0('0x1aaf')][_0x3cfca0('0x1e6e')]({})[_0x3cfca0('0xe53')]['then'](function(_0x3b1492){const _0x10cbed=_0x3cfca0;_0x3a2fab[_0x10cbed('0x1c99')]=_0x3b1492[_0x10cbed('0xf5d')]||[];})[_0x3cfca0('0x130a')](function(_0x22c618){const _0xa168d9=_0x3cfca0;_0x35f251[_0xa168d9('0x52a')]({'title':_0x22c618[_0xa168d9('0x13ee')]?_0xa168d9('0x2168')+_0x22c618[_0xa168d9('0x13ee')]+_0xa168d9('0xbf6')+_0x22c618[_0xa168d9('0x24a9')]:_0xa168d9('0x182f'),'msg':_0x22c618[_0xa168d9('0x5a5')]?JSON['stringify'](_0x22c618[_0xa168d9('0x5a5')]):_0x22c618[_0xa168d9('0x1ff0')]()});});const _0x577c1a=[{'id':0x191,'type':'inbound'},{'id':0x5dd,'type':_0x3cfca0('0x17cd')}];let _0x4ce1da=null;_0x1cad1b[_0x3cfca0('0xca1')](_0x3cfca0('0x20c2'))?_0x37314d[_0x3cfca0('0x204c')][_0x3cfca0('0x1e6e')]({'fields':_0x3cfca0('0x2035'),'sort':_0x3cfca0('0x60a'),'nolimit':_0x3cfca0('0x26ac')})['$promise'][_0x3cfca0('0x683')](function(_0x3060e0){const _0x16f9e2=_0x3cfca0;_0x3a2fab[_0x16f9e2('0x426')]=_0x3060e0[_0x16f9e2('0xf5d')]||[];})['catch'](function(_0x1d9a9d){const _0x4e0f1b=_0x3cfca0;_0x35f251[_0x4e0f1b('0x52a')]({'title':_0x1d9a9d[_0x4e0f1b('0x13ee')]?_0x4e0f1b('0x2168')+_0x1d9a9d[_0x4e0f1b('0x13ee')]+_0x4e0f1b('0xbf6')+_0x1d9a9d[_0x4e0f1b('0x24a9')]:_0x4e0f1b('0x15f3'),'msg':_0x1d9a9d[_0x4e0f1b('0x5a5')]?JSON[_0x4e0f1b('0x258a')](_0x1d9a9d[_0x4e0f1b('0x5a5')]):_0x1d9a9d[_0x4e0f1b('0x1ff0')]()});}):_0x37314d[_0x3cfca0('0x204c')]['get']({'fields':_0x3cfca0('0x2035'),'sort':'name','nolimit':'true'})[_0x3cfca0('0xe53')][_0x3cfca0('0x683')](function(_0x25ebfa){_0x4ce1da=_0x25ebfa['rows']||[];})[_0x3cfca0('0x683')](function(){const _0x492f74=_0x3cfca0,_0x370d45=[];for(let _0x312a6c=0x0;_0x312a6c<_0x577c1a[_0x492f74('0x1564')];_0x312a6c++){_0x370d45[_0x492f74('0x1fd0')](_0x37314d[_0x492f74('0x22df')][_0x492f74('0x1e6e')]({'userProfileId':_0x3a2fab[_0x492f74('0x11ed')]['userProfileId'],'sectionId':_0x577c1a[_0x312a6c]['id']})[_0x492f74('0xe53')]);}return _0x540395[_0x492f74('0x252c')](_0x370d45);})['then'](function(_0xfe11d1){const _0x5f3f19=_0x3cfca0,_0x2a2357=_0x2e3ca0()['map'](_0xfe11d1,function(_0x725870){const _0x454dd8=a0_0x4e0a;return _0x725870&&_0x725870['rows']?_0x725870[_0x454dd8('0xf5d')][0x0]:null;}),_0x172e29=[];for(let _0x7ad22e=0x0;_0x7ad22e<_0x577c1a[_0x5f3f19('0x1564')];_0x7ad22e++){const _0x42309b=_0x2e3ca0()[_0x5f3f19('0x1c07')](_0x2a2357,[_0x5f3f19('0x21c0'),_0x577c1a[_0x7ad22e]['id']]);if(_0x42309b){if(!_0x42309b[_0x5f3f19('0x170')])_0x172e29[_0x5f3f19('0x1fd0')](_0x37314d[_0x5f3f19('0xcf7')]['get']({'sectionId':_0x42309b['id']})['$promise']);else{const _0x57f0fa=[];_0x4ce1da[_0x5f3f19('0x1299')](function(_0x3565e8){const _0x14bffa=_0x5f3f19;_0x3565e8['type']===_0x577c1a[_0x7ad22e]['type']&&_0x57f0fa[_0x14bffa('0x1fd0')](_0x3565e8);}),_0x172e29[_0x5f3f19('0x1fd0')]({'rows':_0x57f0fa,'count':_0x57f0fa[_0x5f3f19('0x1564')]});}}}return _0x540395[_0x5f3f19('0x252c')](_0x172e29);})['then'](function(_0x4dee22){const _0x1afd87=_0x3cfca0,_0xa9c49c=[];let _0x2f1e5f=null;_0x3a2fab[_0x1afd87('0x4a1')]&&(_0x2f1e5f=_0x2e3ca0()[_0x1afd87('0x1c07')](_0x4ce1da,{'id':Number(_0x3a2fab[_0x1afd87('0x4a1')][_0x1afd87('0x154b')])}));for(let _0x24d473=0x0;_0x24d473<_0x4dee22[_0x1afd87('0x1564')];_0x24d473++){const _0x3e7d80=_0x4dee22[_0x24d473]['rows']||[];_0x3e7d80[_0x1afd87('0x1299')](function(_0x5b31ac){const _0x2a0f48=_0x1afd87;_0xa9c49c[_0x2a0f48('0x1fd0')](_0x5b31ac);});}_0x2f1e5f&&!_0x2e3ca0()['some'](_0xa9c49c,[_0x1afd87('0x832'),_0x2f1e5f['id']])&&_0x4ce1da[_0x1afd87('0x1299')](function(_0x50e701){_0x50e701['id']===_0x2f1e5f['id']&&(_0x50e701['canSelect']=![],_0xa9c49c['push'](_0x50e701));}),_0x3a2fab['voiceQueues']=_0xa9c49c;})[_0x3cfca0('0x130a')](function(_0x1e7c38){const _0x4a72a2=_0x3cfca0;_0x35f251[_0x4a72a2('0x52a')]({'title':_0x1e7c38[_0x4a72a2('0x13ee')]?_0x4a72a2('0x2168')+_0x1e7c38['status']+_0x4a72a2('0xbf6')+_0x1e7c38[_0x4a72a2('0x24a9')]:_0x4a72a2('0x1675'),'msg':_0x1e7c38[_0x4a72a2('0x5a5')]?JSON[_0x4a72a2('0x258a')](_0x1e7c38[_0x4a72a2('0x5a5')]):_0x1e7c38[_0x4a72a2('0x1ff0')]()});});function _0x482d4d(){const _0x522408=_0x3cfca0;_0x3a2fab[_0x522408('0x17f')]=[],_0x37314d['dashboard'][_0x522408('0x84e')]({'id':_0xa32f6c[_0x522408('0x7f2')]['id']},_0x3a2fab[_0x522408('0x4a1')])[_0x522408('0xe53')][_0x522408('0x683')](function(_0x26cfee){const _0x2eb502=_0x522408;_0x3a2fab[_0x2eb502('0x1a6')][_0x2eb502('0x1167')](_0x26cfee[_0x2eb502('0x24e1')]()),_0x35f251['success']({'title':_0x2eb502('0xa9c'),'msg':_0x3a2fab['dashboarditem'][_0x2eb502('0x60a')]?_0x3a2fab[_0x2eb502('0x4a1')][_0x2eb502('0x60a')]+_0x2eb502('0x14b5'):''}),_0x13af2f(_0x26cfee);})['catch'](function(_0x1ca30c){const _0x5fafba=_0x522408;if(_0x1ca30c[_0x5fafba('0x5a5')]&&_0x1ca30c[_0x5fafba('0x5a5')]['errors']&&_0x1ca30c[_0x5fafba('0x5a5')][_0x5fafba('0x17f')][_0x5fafba('0x1564')]){_0x3a2fab[_0x5fafba('0x17f')]=_0x1ca30c[_0x5fafba('0x5a5')][_0x5fafba('0x17f')]||[{'message':_0x1ca30c[_0x5fafba('0x1ff0')](),'type':_0x5fafba('0xedb')}];for(let _0x5c2f17=0x0;_0x5c2f17<_0x1ca30c[_0x5fafba('0x5a5')][_0x5fafba('0x17f')][_0x5fafba('0x1564')];_0x5c2f17+=0x1){_0x35f251[_0x5fafba('0x52a')]({'title':_0x1ca30c['data']['errors'][_0x5c2f17][_0x5fafba('0xcf0')],'msg':_0x1ca30c['data'][_0x5fafba('0x17f')][_0x5c2f17]['message']});}}else _0x35f251[_0x5fafba('0x52a')]({'title':_0x1ca30c[_0x5fafba('0x13ee')]?_0x5fafba('0x2168')+_0x1ca30c[_0x5fafba('0x13ee')]+_0x5fafba('0xbf6')+_0x1ca30c['statusText']:_0x5fafba('0xedb'),'msg':_0x1ca30c['data']?JSON['stringify'](_0x1ca30c['data'][_0x5fafba('0x8c2')]):_0x1ca30c[_0x5fafba('0x1ff0')]()});});}function _0x48f15d(){const _0x3c4ef3=_0x3cfca0;_0x3a2fab[_0x3c4ef3('0x17f')]=[],_0x37314d[_0x3c4ef3('0x2565')]['update']({'id':_0x3a2fab[_0x3c4ef3('0x4a1')]['id']},_0x3a2fab[_0x3c4ef3('0x4a1')])[_0x3c4ef3('0xe53')][_0x3c4ef3('0x683')](function(_0x2fa0c5){const _0x3c76a7=_0x3c4ef3,_0x2605b2=_0x2e3ca0()[_0x3c76a7('0x1c07')](_0x3a2fab['dashboard'],{'id':_0x2fa0c5['id']});_0x2605b2&&_0x2e3ca0()[_0x3c76a7('0xf22')](_0x2605b2,_0x2e3ca0()[_0x3c76a7('0x24d0')](_0x2fa0c5[_0x3c76a7('0x24e1')](),_0x2e3ca0()[_0x3c76a7('0x55e')](_0x2605b2))),_0x35f251[_0x3c76a7('0x53')]({'title':_0x3c76a7('0x1268'),'msg':_0x3a2fab[_0x3c76a7('0x4a1')][_0x3c76a7('0x60a')]?_0x3a2fab[_0x3c76a7('0x4a1')][_0x3c76a7('0x60a')]+_0x3c76a7('0xf59'):''}),_0x13af2f(_0x2fa0c5);})['catch'](function(_0x58bb65){const _0x23b6d6=_0x3c4ef3;if(_0x58bb65['data']&&_0x58bb65[_0x23b6d6('0x5a5')][_0x23b6d6('0x17f')]&&_0x58bb65[_0x23b6d6('0x5a5')][_0x23b6d6('0x17f')][_0x23b6d6('0x1564')]){_0x3a2fab[_0x23b6d6('0x17f')]=_0x58bb65[_0x23b6d6('0x5a5')][_0x23b6d6('0x17f')]||[{'message':_0x58bb65[_0x23b6d6('0x1ff0')](),'type':_0x23b6d6('0x19c6')}];for(let _0x2d28d3=0x0;_0x2d28d3<_0x58bb65['data'][_0x23b6d6('0x17f')]['length'];_0x2d28d3++){_0x35f251['error']({'title':_0x58bb65['data'][_0x23b6d6('0x17f')][_0x2d28d3][_0x23b6d6('0xcf0')],'msg':_0x58bb65[_0x23b6d6('0x5a5')][_0x23b6d6('0x17f')][_0x2d28d3][_0x23b6d6('0x8c2')]});}}else _0x35f251[_0x23b6d6('0x52a')]({'title':_0x58bb65[_0x23b6d6('0x13ee')]?'API:'+_0x58bb65[_0x23b6d6('0x13ee')]+_0x23b6d6('0xbf6')+_0x58bb65[_0x23b6d6('0x24a9')]:_0x23b6d6('0x19c6'),'msg':_0x58bb65[_0x23b6d6('0x5a5')]?JSON[_0x23b6d6('0x258a')](_0x58bb65[_0x23b6d6('0x5a5')][_0x23b6d6('0x8c2')]):_0x58bb65['toString']()});});}function _0x245059(_0x2fd16){const _0x2e5ab2=_0x3cfca0;_0x3a2fab[_0x2e5ab2('0x17f')]=[];const _0x2c8ec9=_0x431e84[_0x2e5ab2('0x1c6f')]()['title']('Are\x20you\x20sure?')[_0x2e5ab2('0xa6a')]('The\x20dashboarditem\x20will\x20be\x20deleted.')['ariaLabel']('Delete\x20DashboardItem')['ok']('Delete')[_0x2e5ab2('0x19fb')](_0x2e5ab2('0x253a'))[_0x2e5ab2('0xe42')](_0x2fd16);_0x431e84[_0x2e5ab2('0x1d4')](_0x2c8ec9)[_0x2e5ab2('0x683')](function(){const _0x412a31=_0x2e5ab2;_0x37314d[_0x412a31('0x2565')][_0x412a31('0xd7e')]({'id':_0x3a2fab['dashboarditem']['id']})[_0x412a31('0xe53')][_0x412a31('0x683')](function(){const _0x1c4909=_0x412a31;_0x2e3ca0()['remove'](_0x3a2fab['dashboard'],{'id':_0x3a2fab[_0x1c4909('0x4a1')]['id']}),_0x35f251['success']({'title':'DashboardItem\x20properly\x20deleted!','msg':(_0x3a2fab[_0x1c4909('0x4a1')]['name']||_0x1c4909('0x4a1'))+'\x20has\x20been\x20deleted!'}),_0x13af2f(_0x3a2fab[_0x1c4909('0x4a1')]);})[_0x412a31('0x130a')](function(_0x1824b2){const _0xa6f9ba=_0x412a31;if(_0x1824b2[_0xa6f9ba('0x5a5')]&&_0x1824b2[_0xa6f9ba('0x5a5')][_0xa6f9ba('0x17f')]&&_0x1824b2[_0xa6f9ba('0x5a5')]['errors'][_0xa6f9ba('0x1564')]){_0x3a2fab['errors']=_0x1824b2['data'][_0xa6f9ba('0x17f')]||[{'message':_0x1824b2['toString'](),'type':_0xa6f9ba('0xaac')}];for(let _0x3b52e7=0x0;_0x3b52e7<_0x1824b2['data'][_0xa6f9ba('0x17f')]['length'];_0x3b52e7++){_0x35f251['error']({'title':_0x1824b2[_0xa6f9ba('0x5a5')][_0xa6f9ba('0x17f')][_0x3b52e7][_0xa6f9ba('0xcf0')],'msg':_0x1824b2[_0xa6f9ba('0x5a5')][_0xa6f9ba('0x17f')][_0x3b52e7]['message']});}}else _0x35f251[_0xa6f9ba('0x52a')]({'title':_0x1824b2[_0xa6f9ba('0x13ee')]?'API:'+_0x1824b2[_0xa6f9ba('0x13ee')]+_0xa6f9ba('0xbf6')+_0x1824b2['statusText']:_0xa6f9ba('0xaac'),'msg':_0x1824b2[_0xa6f9ba('0x5a5')]?JSON[_0xa6f9ba('0x258a')](_0x1824b2[_0xa6f9ba('0x5a5')][_0xa6f9ba('0x8c2')]):_0x1824b2[_0xa6f9ba('0x8c2')]||_0x1824b2[_0xa6f9ba('0x1ff0')]()});});},function(){});}function _0x1810fb(){const _0x389c2b=_0x3cfca0,_0x455d27={'core':{'multiple':![],'animation':!![],'error':function(_0xd12115){const _0x45d69f=a0_0x4e0a;console['error'](_0x45d69f('0x2167')+angular[_0x45d69f('0x1bf7')](_0xd12115));},'check_callback':!![],'worker':!![]},'version':0x1,'plugins':['wholerow']};return _0x3a2fab[_0x389c2b('0x11ed')][_0x389c2b('0xecb')]!=='admin'?_0x37314d[_0x389c2b('0x22df')]['get']({'fields':_0x389c2b('0x1f47'),'userProfileId':_0x3a2fab[_0x389c2b('0x11ed')][_0x389c2b('0x2f')],'sectionId':0x4b3})['$promise']['then'](function(_0x96ff05){const _0x59fc12=_0x389c2b;return _0x3a2fab[_0x59fc12('0x22df')]=_0x96ff05&&_0x96ff05[_0x59fc12('0x50d')]==0x1?_0x96ff05[_0x59fc12('0xf5d')][0x0]:null,_0x455d27;})['catch'](function(_0x9379f0){const _0x2d3d07=_0x389c2b;_0x35f251[_0x2d3d07('0x52a')]({'title':_0x2d3d07('0x1119'),'msg':_0x9379f0[_0x2d3d07('0x8c2')]});}):_0x455d27;}function _0x27021e(_0xf07147){return _0xf07147?{'loaded':_0x37b4c9,'select_node':_0x4304bd}:{'loaded':_0x5ac8cf,'select_node':_0x48a527};}function _0x4304bd(_0x2cd894,_0x19caa5){const _0x114e0e=_0x3cfca0;_0x3a2fab[_0x114e0e('0x1325')][_0x114e0e('0x184b')](!![])['deselect_all'](),_0x3a2fab[_0x114e0e('0x1325')][_0x114e0e('0x184b')](!![])[_0x114e0e('0x1def')](),_0x3a2fab[_0x114e0e('0x121b')]=_0x19caa5[_0x114e0e('0x759')],_0x3a2fab['currentNode'][_0x114e0e('0xbf0')]=!![],_0x3a2fab['currentPath']=_0x3a2fab[_0x114e0e('0x13f6')][_0x114e0e('0x184b')](!![])[_0x114e0e('0xfd5')](_0x3a2fab[_0x114e0e('0x121b')])[_0x114e0e('0x1630')]('/\x20'),_0x3a2fab[_0x114e0e('0x213')]=_0x114e0e('0x197f'),_0x3a2fab[_0x114e0e('0x23a2')][_0x114e0e('0x2361')]=_0x19caa5['node']['id'],_0x435f52();}function _0x48a527(_0x2ce088,_0xf4c0bd){const _0x2b101a=_0x3cfca0;_0x3a2fab[_0x2b101a('0x13f6')][_0x2b101a('0x184b')](!![])[_0x2b101a('0x1788')](),_0x3a2fab['treeCustomInstance'][_0x2b101a('0x184b')](!![])[_0x2b101a('0x1def')](),_0x3a2fab['currentNode']=_0xf4c0bd[_0x2b101a('0x759')],_0x3a2fab['currentNode']['custom']=![],_0x3a2fab[_0x2b101a('0x228d')]=_0x3a2fab[_0x2b101a('0x1325')][_0x2b101a('0x184b')](!![])['get_path'](_0x3a2fab[_0x2b101a('0x121b')])[_0x2b101a('0x1630')]('/\x20'),_0x3a2fab[_0x2b101a('0x213')]=_0x2b101a('0x20ec'),_0x3a2fab[_0x2b101a('0x23a2')][_0x2b101a('0x2361')]=_0xf4c0bd[_0x2b101a('0x759')]['id'],_0x435f52();}function _0x37b4c9(){const _0x552c1d=_0x3cfca0;if(!_0x3a2fab[_0x552c1d('0x1ee1')]&&_0x3a2fab[_0x552c1d('0x213')]===_0x552c1d('0x197f')){const _0x2284de=_0x3a2fab['treeCustomInstance']['jstree'](!![])['get_node'](_0x3a2fab['query'][_0x552c1d('0x2361')]);_0x4304bd(null,{'node':_0x2284de,'selected':_0x2284de['id']});}}function _0x5ac8cf(){const _0x55fed4=_0x3cfca0;if(!_0x3a2fab['newDashboardItem']&&_0x3a2fab[_0x55fed4('0x213')]===_0x55fed4('0x20ec')){const _0x3b43c4=_0x3a2fab[_0x55fed4('0x1325')]['jstree'](!![])['get_node'](_0x3a2fab[_0x55fed4('0x23a2')][_0x55fed4('0x2361')]);_0x48a527(null,{'node':_0x3b43c4,'selected':_0x3b43c4['id']});}}function _0x435f52(){const _0x2d6b80=_0x3cfca0;_0x3a2fab[_0x2d6b80('0x23a2')][_0x2d6b80('0x1cc8')]=(_0x3a2fab[_0x2d6b80('0x23a2')]['page']-0x1)*_0x3a2fab[_0x2d6b80('0x23a2')][_0x2d6b80('0x6f0')];if(_0x3a2fab[_0x2d6b80('0x213')]){if(_0x3a2fab[_0x2d6b80('0x11ed')][_0x2d6b80('0xecb')]==='admin')_0x3a2fab[_0x2d6b80('0x1883')]=_0x37314d[_0x3a2fab[_0x2d6b80('0x213')]][_0x2d6b80('0x1e6e')](_0x3a2fab['query'],_0x214744)['$promise'];else{if(!_0x3a2fab['userProfileSection'])return _0x214744(null);else{if(_0x3a2fab['userProfileSection'][_0x2d6b80('0x170')])_0x3a2fab[_0x2d6b80('0x1883')]=_0x37314d[_0x3a2fab[_0x2d6b80('0x213')]]['get'](_0x3a2fab[_0x2d6b80('0x23a2')],_0x214744)[_0x2d6b80('0xe53')];else{let _0x4c817d=[];_0x3a2fab[_0x2d6b80('0x1883')]=_0x37314d[_0x3a2fab[_0x2d6b80('0x213')]][_0x2d6b80('0x1e6e')](_0x3a2fab[_0x2d6b80('0x23a2')])[_0x2d6b80('0xe53')][_0x2d6b80('0x683')](function(_0xc590cf){const _0x547782=_0x2d6b80;return _0x4c817d=_0xc590cf&&_0xc590cf[_0x547782('0xf5d')]?_0xc590cf['rows']:[],_0x4c817d['length']>0x0?_0x37314d[_0x547782('0xcf7')][_0x547782('0x1e6e')]({'sectionId':_0x3a2fab[_0x547782('0x22df')]['id'],'type':_0x3a2fab[_0x547782('0x213')]==='analyticDefaultReport'?'DefaultReports':_0x547782('0x1a3c')})[_0x547782('0xe53')][_0x547782('0x683')](function(_0xd5605e){const _0x5d4547=_0x547782,_0x5ef8ff=_0xd5605e&&_0xd5605e[_0x5d4547('0xf5d')]?_0xd5605e[_0x5d4547('0xf5d')]:[];if(_0x5ef8ff[_0x5d4547('0x1564')]>0x0){const _0x5d7e82=[];return _0x4c817d['forEach'](function(_0x46938a){const _0x5acf27=_0x5d4547,_0x4a8877=_0x2e3ca0()['find'](_0x5ef8ff,[_0x5acf27('0x832'),_0x46938a['id']]);if(_0x4a8877)_0x5d7e82[_0x5acf27('0x1fd0')](_0x46938a);}),_0x214744({'count':_0x5d7e82[_0x5d4547('0x1564')],'rows':_0x5d7e82});}else return _0x214744(null);}):_0x214744(null);})['catch'](function(_0x4113b6){const _0x557587=_0x2d6b80;_0x35f251['error']({'title':_0x4113b6[_0x557587('0x13ee')]?'API:'+_0x4113b6['status']+_0x557587('0xbf6')+_0x4113b6['statusText']:_0x557587('0x101c'),'msg':_0x4113b6[_0x557587('0x5a5')]?JSON[_0x557587('0x258a')](_0x4113b6[_0x557587('0x5a5')]):_0x4113b6[_0x557587('0x1ff0')]()});});}}}}}function _0x214744(_0x2b608f){const _0x5774ee=_0x3cfca0;_0x3a2fab['reports']=_0x2b608f||{'count':0x0,'rows':[]},!_0x3a2fab[_0x5774ee('0x1ee1')]&&_0x3a2fab[_0x5774ee('0xe5a')][_0x5774ee('0x1fd0')](_0x2e3ca0()[_0x5774ee('0x1c07')](_0x3a2fab[_0x5774ee('0x4c2')][_0x5774ee('0xf5d')],{'id':_0x3a2fab['currentReport']['id']}));}function _0x14362f(){const _0x5b7630=_0x3cfca0;_0x3a2fab[_0x5b7630('0x91d')]=_0x3a2fab[_0x5b7630('0x1c99')][0x0]?angular[_0x5b7630('0x1cb2')](_0x3a2fab[_0x5b7630('0x1c99')][0x0][_0x5b7630('0x2eb')]):[],_0x3a2fab['treeCustomData']=_0x3a2fab['treeReports'][0x1]?angular[_0x5b7630('0x1cb2')](_0x3a2fab['treeReports'][0x1][_0x5b7630('0x2eb')]):[],_0x3a2fab['treeConfig']=_0x1810fb(),_0x3a2fab['treeDefaultEvents']=_0x27021e(![]),_0x3a2fab[_0x5b7630('0x26b7')]=_0x27021e(!![]),_0x431e84['show']({'controller':function(){return _0x3a2fab;},'controllerAs':'vm','templateUrl':_0x2ed001,'autoWrap':!![],'skipHide':!![]});}function _0x2e296f(){const _0x1931e0=_0x3cfca0;_0x3a2fab[_0x1931e0('0x4a1')][_0x1931e0('0xaaf')]=_0x3a2fab[_0x1931e0('0xe5a')][0x0]['name'],_0x3a2fab['dashboarditem']['attrReport']=_0x3a2fab[_0x1931e0('0xe5a')][0x0]['id'],_0x3a2fab['dashboarditem'][_0x1931e0('0x750')]=_0x3a2fab[_0x1931e0('0x121b')][_0x1931e0('0xbf0')]?_0x1931e0('0xbf0'):_0x1931e0('0x9cb');if(!_0x3a2fab[_0x1931e0('0x1ee1')]){const _0x9707a2={'name':_0x1931e0('0x8e4'),'type':_0x3a2fab[_0x1931e0('0x4a1')][_0x1931e0('0x750')],'value':_0x3a2fab[_0x1931e0('0xe5a')][0x0]['id']};_0x3a2fab[_0x1931e0('0x4a1')][_0x1931e0('0x1221')][_0x1931e0('0x2040')](_0x2e3ca0()[_0x1931e0('0x1ce4')](_0x3a2fab['dashboarditem'][_0x1931e0('0x1221')],0x1,_0x9707a2));}_0x53906b[_0x1931e0('0x1927')][_0x1931e0('0xaaf')]['$setDirty'](),_0x431e84[_0x1931e0('0x1715')]();}function _0x3c4262(){const _0x585b88=_0x3cfca0;_0x431e84[_0x585b88('0x1715')]();}function _0x4ac6ca(_0x3fc116){return _0x3fc116===null?undefined:new Date(_0x3fc116);}function _0x13af2f(_0x45a684){const _0x1b24a5=_0x3cfca0;_0x431e84[_0x1b24a5('0x1715')](_0x45a684);}}const _0x3dbbbf=_0x219d04,_0x1ed616=_0x180212['p']+'src/js/modules/main/apps/tools/views/customDashboards/edit/clone/clone.html/clone.html';_0xdb4aad[_0x189033('0x14be')]=['$state',_0x189033('0xb8d'),_0x189033('0x1e48'),'$document',_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),'Auth',_0x189033('0x22a5'),'userProfileSection'];function _0xdb4aad(_0x40cbc2,_0x4509b6,_0x4e6e9a,_0x276095,_0x3ead4c,_0x50be5c,_0x54d2c6,_0x5670ca,_0x246edc,_0x14736e,_0x37e3dd,_0x4448e5){const _0xe9fc5f=_0x189033,_0x2f3435=this;_0x2f3435[_0xe9fc5f('0x11ed')]=_0x14736e[_0xe9fc5f('0x20b2')](),_0x2f3435[_0xe9fc5f('0xace')]=_0x50be5c,_0x2f3435[_0xe9fc5f('0x260a')]=_0x54d2c6,_0x2f3435[_0xe9fc5f('0x19b2')]=_0x2f3435[_0xe9fc5f('0x260a')][_0xe9fc5f('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2f3435[_0xe9fc5f('0x1224')]=_0x4509b6[_0xe9fc5f('0x173e')]()+_0xe9fc5f('0x20de')+_0x4509b6[_0xe9fc5f('0x19ac')](),_0x2f3435[_0xe9fc5f('0x22a5')]=_0x37e3dd||_0x40cbc2['params']['customDashboard']||{},_0x2f3435['userProfileSection']=_0x4448e5&&_0x4448e5[_0xe9fc5f('0x50d')]==0x1?_0x4448e5[_0xe9fc5f('0xf5d')][0x0]:null,_0x2f3435[_0xe9fc5f('0x1134')]=_0x14736e[_0xe9fc5f('0x142a')](_0x2f3435[_0xe9fc5f('0x22df')]?_0x2f3435['userProfileSection']['crudPermissions']:null),_0x2f3435['hasModulePermissions']={},_0x2f3435['selectedTab']=_0x40cbc2[_0xe9fc5f('0x7f2')][_0xe9fc5f('0x1904')]||0x0,_0x2f3435['clonedialog']=_0x59dd2d,_0x2f3435[_0xe9fc5f('0x1a9f')]=_0x5415d6,_0x2f3435[_0xe9fc5f('0x2430')]=_0x246edc['info'],_0x2f3435[_0xe9fc5f('0x179c')]=_0x398c6a,_0x2f3435[_0xe9fc5f('0x108e')]=_0x4b9779;function _0x59dd2d(_0xd324d4,_0x1cf30c){const _0x1962f6=_0xe9fc5f;_0x4e6e9a['show']({'controller':_0x1962f6('0x71d'),'controllerAs':'vm','templateUrl':_0x1ed616,'parent':angular[_0x1962f6('0x1fcc')](_0x276095[_0x1962f6('0x18e5')]),'targetEvent':_0x1cf30c,'clickOutsideToClose':!![],'locals':{'customDashboard':_0xd324d4,'customDashboards':_0x2f3435[_0x1962f6('0x111d')]?_0x2f3435[_0x1962f6('0x111d')][_0x1962f6('0xf5d')]:[],'crudPermissions':_0x2f3435[_0x1962f6('0x1134')]}});}function _0x5415d6(_0x3f7466){const _0x4f4286=_0xe9fc5f;_0x40cbc2['go'](_0x4f4286('0x1273'),{'id':_0x3f7466['id']});}function _0x398c6a(){const _0x31b28e=_0xe9fc5f;_0x40cbc2['go']('app.tools.customDashboards',{},{'reload':_0x31b28e('0x7b3')});}function _0x4b9779(){const _0x254404=_0xe9fc5f;_0x5670ca['dashboard'][_0x254404('0x2480')]({'id':_0x2f3435[_0x254404('0x22a5')]['id']},_0x2f3435[_0x254404('0x22a5')])[_0x254404('0xe53')]['then'](function(){const _0x1b0c2a=_0x254404;_0x246edc[_0x1b0c2a('0x53')]({'title':_0x1b0c2a('0x8a3'),'msg':_0x2f3435[_0x1b0c2a('0x22a5')]['name']?_0x2f3435['customDashboard']['name']+_0x1b0c2a('0x96c'):''});})[_0x254404('0x130a')](function(_0xa0e5bc){const _0x4f30e9=_0x254404;_0x246edc[_0x4f30e9('0x52a')]({'title':_0xa0e5bc[_0x4f30e9('0x13ee')]?_0x4f30e9('0x2168')+_0xa0e5bc[_0x4f30e9('0x13ee')]+_0x4f30e9('0xbf6')+_0xa0e5bc['statusText']:'SYSTEM:GETdashboard','msg':_0xa0e5bc['data']?JSON[_0x4f30e9('0x258a')](_0xa0e5bc[_0x4f30e9('0x5a5')]):_0xa0e5bc[_0x4f30e9('0x1ff0')]()});});}}const _0x13c6b1=_0xdb4aad;_0x308e45[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0xe98'),_0x189033('0x115c'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x308e45(_0xe4da2f,_0x521b3a,_0x1e9e17,_0x3b7638,_0x2bcc3c,_0x275fa8,_0xec014e,_0x161909,_0x10b005,_0x5660c3,_0x414efe,_0x693745,_0x2cc185,_0x2ab04d){const _0x38a639=_0x189033,_0x45d39c=this;_0x45d39c[_0x38a639('0x11ed')]=_0x414efe[_0x38a639('0x20b2')](),_0x45d39c[_0x38a639('0x17f')]=[],_0x45d39c[_0x38a639('0x260a')]=_0x2cc185,_0x45d39c[_0x38a639('0xace')]=_0x693745,_0x45d39c[_0x38a639('0x1134')]=_0x2ab04d,_0x45d39c[_0x38a639('0x258d')]={},_0x45d39c[_0x38a639('0x19b2')]=_0x45d39c[_0x38a639('0x260a')]&&_0x45d39c[_0x38a639('0x260a')][_0x38a639('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x45d39c[_0x38a639('0xf28')]=_0x38a639('0xc62'),_0x45d39c['interval']=angular[_0x38a639('0x1a86')](_0x10b005),_0x45d39c['intervals']=_0x161909,_0x45d39c[_0x38a639('0x1470')]=![];!_0x45d39c[_0x38a639('0x115c')]&&(_0x45d39c[_0x38a639('0x115c')]={},_0x45d39c[_0x38a639('0xf28')]='TOOLS.NEW_INTERVAL',_0x45d39c[_0x38a639('0x1470')]=!![]);_0x45d39c[_0x38a639('0x1a4d')]=_0x12a738,_0x45d39c[_0x38a639('0x1807')]=_0x32b313,_0x45d39c['deleteInterval']=_0x9820e,_0x45d39c[_0x38a639('0x16b3')]=_0x16a5ff,_0x45d39c['closeDialog']=_0x175a63;function _0x12a738(){const _0x3f9b05=_0x38a639;_0x45d39c[_0x3f9b05('0x17f')]=[],_0x5660c3['interval']['save'](_0x45d39c['interval'])['$promise'][_0x3f9b05('0x683')](function(_0x340a49){const _0x1d9b69=_0x3f9b05;_0x45d39c['intervals']['unshift'](_0x340a49[_0x1d9b69('0x24e1')]()),_0xec014e[_0x1d9b69('0x53')]({'title':_0x1d9b69('0x24b5'),'msg':_0x45d39c[_0x1d9b69('0x115c')]['name']?_0x45d39c[_0x1d9b69('0x115c')]['name']+'\x20has\x20been\x20created!':''}),_0x175a63(_0x340a49);})[_0x3f9b05('0x130a')](function(_0x15e539){const _0x368576=_0x3f9b05;if(_0x15e539[_0x368576('0x5a5')]&&_0x15e539[_0x368576('0x5a5')][_0x368576('0x17f')]&&_0x15e539[_0x368576('0x5a5')][_0x368576('0x17f')][_0x368576('0x1564')]){_0x45d39c['errors']=_0x15e539[_0x368576('0x5a5')][_0x368576('0x17f')]||[{'message':_0x15e539[_0x368576('0x1ff0')](),'type':_0x368576('0x1d24')}];for(let _0x332124=0x0;_0x332124<_0x15e539[_0x368576('0x5a5')][_0x368576('0x17f')][_0x368576('0x1564')];_0x332124+=0x1){_0xec014e[_0x368576('0x52a')]({'title':_0x15e539[_0x368576('0x5a5')][_0x368576('0x17f')][_0x332124][_0x368576('0xcf0')],'msg':_0x15e539['data']['errors'][_0x332124][_0x368576('0x8c2')]});}}else _0xec014e[_0x368576('0x52a')]({'title':_0x15e539['status']?'API:'+_0x15e539['status']+_0x368576('0xbf6')+_0x15e539['statusText']:_0x368576('0x1d24'),'msg':_0x15e539[_0x368576('0x5a5')]?JSON[_0x368576('0x258a')](_0x15e539[_0x368576('0x5a5')][_0x368576('0x8c2')]):_0x15e539[_0x368576('0x1ff0')]()});});}function _0x32b313(){const _0x5f1f94=_0x38a639;_0x45d39c[_0x5f1f94('0x17f')]=[],_0x5660c3['interval'][_0x5f1f94('0x2480')]({'id':_0x45d39c['interval']['id']},_0x45d39c['interval'])['$promise'][_0x5f1f94('0x683')](function(_0x5348db){const _0x1d61c6=_0x5f1f94,_0xc25f1=_0x2e3ca0()['find'](_0x45d39c[_0x1d61c6('0xe98')],{'id':_0x5348db['id']});_0xc25f1&&_0x2e3ca0()[_0x1d61c6('0xf22')](_0xc25f1,_0x2e3ca0()['pick'](_0x5348db[_0x1d61c6('0x24e1')](),_0x2e3ca0()[_0x1d61c6('0x55e')](_0xc25f1))),_0xec014e[_0x1d61c6('0x53')]({'title':_0x1d61c6('0x18c3'),'msg':_0x45d39c['interval'][_0x1d61c6('0x60a')]?_0x45d39c['interval']['name']+'\x20has\x20been\x20saved!':''}),_0x175a63(_0x5348db);})[_0x5f1f94('0x130a')](function(_0x496279){const _0x326b2=_0x5f1f94;if(_0x496279[_0x326b2('0x5a5')]&&_0x496279['data'][_0x326b2('0x17f')]&&_0x496279['data'][_0x326b2('0x17f')]['length']){_0x45d39c[_0x326b2('0x17f')]=_0x496279[_0x326b2('0x5a5')][_0x326b2('0x17f')]||[{'message':_0x496279[_0x326b2('0x1ff0')](),'type':_0x326b2('0x605')}];for(let _0x519628=0x0;_0x519628<_0x496279[_0x326b2('0x5a5')][_0x326b2('0x17f')][_0x326b2('0x1564')];_0x519628++){_0xec014e[_0x326b2('0x52a')]({'title':_0x496279['data'][_0x326b2('0x17f')][_0x519628]['type'],'msg':_0x496279[_0x326b2('0x5a5')][_0x326b2('0x17f')][_0x519628]['message']});}}else _0xec014e[_0x326b2('0x52a')]({'title':_0x496279[_0x326b2('0x13ee')]?'API:'+_0x496279[_0x326b2('0x13ee')]+'\x20-\x20'+_0x496279[_0x326b2('0x24a9')]:_0x326b2('0x605'),'msg':_0x496279['data']?JSON['stringify'](_0x496279[_0x326b2('0x5a5')][_0x326b2('0x8c2')]):_0x496279[_0x326b2('0x1ff0')]()});});}function _0x9820e(_0x5d10a9){const _0x240a5c=_0x38a639;_0x45d39c[_0x240a5c('0x17f')]=[];const _0x3aab05=_0x3b7638['confirm']()[_0x240a5c('0xf28')](_0x240a5c('0x4d'))[_0x240a5c('0xa6a')]('The\x20interval\x20will\x20be\x20deleted.')['ariaLabel'](_0x240a5c('0x1e3c'))['ok'](_0x240a5c('0x2307'))[_0x240a5c('0x19fb')](_0x240a5c('0x253a'))['targetEvent'](_0x5d10a9);_0x3b7638['show'](_0x3aab05)[_0x240a5c('0x683')](function(){const _0x3ffa64=_0x240a5c;_0x5660c3[_0x3ffa64('0x115c')][_0x3ffa64('0xd7e')]({'id':_0x45d39c[_0x3ffa64('0x115c')]['id']})['$promise']['then'](function(){const _0x2294da=_0x3ffa64;_0x2e3ca0()[_0x2294da('0x3ec')](_0x45d39c[_0x2294da('0xe98')],{'id':_0x45d39c[_0x2294da('0x115c')]['id']}),_0xec014e[_0x2294da('0x53')]({'title':_0x2294da('0x1b66'),'msg':(_0x45d39c[_0x2294da('0x115c')][_0x2294da('0x60a')]||'interval')+'\x20has\x20been\x20deleted!'}),_0x175a63(_0x45d39c[_0x2294da('0x115c')]);})[_0x3ffa64('0x130a')](function(_0x2bacc6){const _0x333683=_0x3ffa64;if(_0x2bacc6[_0x333683('0x5a5')]&&_0x2bacc6[_0x333683('0x5a5')][_0x333683('0x17f')]&&_0x2bacc6[_0x333683('0x5a5')][_0x333683('0x17f')]['length']){_0x45d39c[_0x333683('0x17f')]=_0x2bacc6[_0x333683('0x5a5')][_0x333683('0x17f')]||[{'message':_0x2bacc6[_0x333683('0x1ff0')](),'type':'api.interval.delete'}];for(let _0x161f39=0x0;_0x161f39<_0x2bacc6['data']['errors'][_0x333683('0x1564')];_0x161f39++){_0xec014e[_0x333683('0x52a')]({'title':_0x2bacc6[_0x333683('0x5a5')][_0x333683('0x17f')][_0x161f39]['type'],'msg':_0x2bacc6['data'][_0x333683('0x17f')][_0x161f39][_0x333683('0x8c2')]});}}else _0xec014e['error']({'title':_0x2bacc6['status']?_0x333683('0x2168')+_0x2bacc6[_0x333683('0x13ee')]+'\x20-\x20'+_0x2bacc6[_0x333683('0x24a9')]:_0x333683('0xfd3'),'msg':_0x2bacc6[_0x333683('0x5a5')]?JSON['stringify'](_0x2bacc6[_0x333683('0x5a5')][_0x333683('0x8c2')]):_0x2bacc6[_0x333683('0x8c2')]||_0x2bacc6[_0x333683('0x1ff0')]()});});},function(){});}function _0x16a5ff(_0x1abb46){return _0x1abb46===null?undefined:new Date(_0x1abb46);}function _0x175a63(_0x2d8918){_0x3b7638['hide'](_0x2d8918);}}const _0x22f4fd=_0x308e45;_0x3b96d4[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x1e48'),_0x189033('0xb33'),_0x189033('0x844'),_0x189033('0x115c'),_0x189033('0xe98'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0x3b96d4(_0x40dc5b,_0x1bd51e,_0x4cb5d3,_0x101587,_0x43ad92,_0x1b88cc,_0x407dee,_0x4d3b72,_0x5d3dd8,_0x33223d){const _0x24a0d3=_0x189033,_0x56c335=this;_0x56c335[_0x24a0d3('0x11ed')]=_0x5d3dd8[_0x24a0d3('0x20b2')](),_0x56c335[_0x24a0d3('0x17f')]=[],_0x56c335[_0x24a0d3('0xf28')]=_0x24a0d3('0xc62'),_0x56c335['interval']=angular[_0x24a0d3('0x1a86')](_0x43ad92),_0x56c335[_0x24a0d3('0xe98')]=_0x1b88cc,_0x56c335[_0x24a0d3('0x1470')]=![],_0x56c335['types']=[_0x24a0d3('0x10af'),'custom'],_0x56c335[_0x24a0d3('0x1134')]=_0x33223d,_0x56c335[_0x24a0d3('0x167a')]=_0x101587[_0x24a0d3('0xe88')](),_0x56c335[_0x24a0d3('0x1dfd')]=_0x101587[_0x24a0d3('0x222e')](),_0x56c335[_0x24a0d3('0x1e32')]=_0x101587['getMonthName'](),_0x56c335['daysOfMonth']=_0x101587[_0x24a0d3('0x181b')]();if(!_0x56c335[_0x24a0d3('0x115c')])_0x56c335[_0x24a0d3('0x115c')]={'interval':_0x24a0d3('0x1b54')},_0x56c335[_0x24a0d3('0xcf0')]=_0x24a0d3('0x10af'),_0x56c335[_0x24a0d3('0xf28')]=_0x24a0d3('0x1e94'),_0x56c335[_0x24a0d3('0x1470')]=!![];else{if(_0x56c335[_0x24a0d3('0x115c')][_0x24a0d3('0x115c')]!==_0x24a0d3('0x1b54')){_0x56c335['type']=_0x24a0d3('0xbf0');const _0x2e1568=_0x56c335[_0x24a0d3('0x115c')]['interval'][_0x24a0d3('0x1fc5')](','),_0x4c52e6=_0x2e1568[0x0],_0x548960=_0x2e1568[0x1],_0x3381ab=_0x2e1568[0x2],_0x1ad5da=_0x2e1568[0x3];if(_0x4c52e6!=='*'){const _0x4c4060=_0x4c52e6[_0x24a0d3('0x1fc5')]('-')[0x0],_0x15d34b=_0x4c52e6['split']('-')[0x1];let _0x1063b8;_0x1063b8=new Date(),_0x1063b8[_0x24a0d3('0x2813')](Number(_0x4c4060[_0x24a0d3('0x1fc5')](':')[0x0])),_0x1063b8[_0x24a0d3('0x1fb7')](Number(_0x4c4060[_0x24a0d3('0x1fc5')](':')[0x1])),_0x56c335[_0x24a0d3('0xc32')]=_0x1063b8,_0x1063b8=new Date(),_0x1063b8[_0x24a0d3('0x2813')](Number(_0x15d34b[_0x24a0d3('0x1fc5')](':')[0x0])),_0x1063b8[_0x24a0d3('0x1fb7')](Number(_0x15d34b[_0x24a0d3('0x1fc5')](':')[0x1])),_0x56c335['timeRangeTo']=_0x1063b8;}_0x548960!=='*'&&(_0x56c335['dayOfWeekFrom']=_0x548960['split']('-')[0x0],_0x56c335[_0x24a0d3('0x1269')]=_0x548960[_0x24a0d3('0x1fc5')]('-')[0x1]),_0x3381ab!=='*'&&(_0x56c335[_0x24a0d3('0xf13')]=_0x3381ab[_0x24a0d3('0x1fc5')]('-')[0x0],_0x56c335['monthDayTo']=_0x3381ab['split']('-')[0x1]),_0x1ad5da!=='*'&&(_0x56c335[_0x24a0d3('0x1690')]=_0x1ad5da[_0x24a0d3('0x1fc5')]('-')[0x0],_0x56c335['monthTo']=_0x1ad5da[_0x24a0d3('0x1fc5')]('-')[0x1]);}else _0x56c335['type']=_0x24a0d3('0x10af');}_0x40dc5b['params']['id']&&!_0x56c335[_0x24a0d3('0x115c')]['application']&&(_0x56c335[_0x24a0d3('0x115c')]['IntervalId']=_0x40dc5b[_0x24a0d3('0x7f2')]['id']);_0x56c335[_0x24a0d3('0x115c')][_0x24a0d3('0x5ae')]&&_0x56c335['interval'][_0x24a0d3('0x121e')]&&(_0x56c335[_0x24a0d3('0xcf0')]=_0x24a0d3('0x2335'));_0x56c335[_0x24a0d3('0x1a4d')]=_0x3f6b76,_0x56c335['saveInterval']=_0x4854ae,_0x56c335[_0x24a0d3('0xf82')]=_0x424a36;_0x56c335[_0x24a0d3('0x115c')][_0x24a0d3('0x121e')]&&(_0x5d3dd8[_0x24a0d3('0xca1')]('admin')?_0x4d3b72['interval'][_0x24a0d3('0x1e6e')]({'fields':_0x24a0d3('0x1e24'),'IntervalId':_0x24a0d3('0x13c'),'nolimit':!![]})[_0x24a0d3('0xe53')][_0x24a0d3('0x683')](function(_0x381b99){const _0x228c38=_0x24a0d3;_0x56c335[_0x228c38('0xe98')]=_0x381b99[_0x228c38('0xf5d')]||[];})[_0x24a0d3('0x130a')](function(_0x16004a){const _0x205174=_0x24a0d3;_0x407dee[_0x205174('0x52a')]({'title':_0x16004a[_0x205174('0x13ee')]?_0x205174('0x2168')+_0x16004a['status']+_0x205174('0xbf6')+_0x16004a[_0x205174('0x24a9')]:_0x205174('0x1e65'),'msg':_0x16004a[_0x205174('0x5a5')]?JSON[_0x205174('0x258a')](_0x16004a[_0x205174('0x5a5')]):_0x16004a[_0x205174('0x1ff0')]()});}):_0x4d3b72['interval'][_0x24a0d3('0x1e6e')]({'fields':_0x24a0d3('0x1e24'),'IntervalId':'null','nolimit':!![]})[_0x24a0d3('0xe53')][_0x24a0d3('0x683')](function(_0x40a8b4){const _0x34eb33=_0x24a0d3;_0x56c335[_0x34eb33('0xe98')]=_0x40a8b4['rows']||[];})[_0x24a0d3('0x683')](function(){const _0x870375=_0x24a0d3;return _0x4d3b72[_0x870375('0x22df')]['get']({'userProfileId':_0x56c335[_0x870375('0x11ed')][_0x870375('0x2f')],'sectionId':0x3ec})['$promise'];})[_0x24a0d3('0x683')](function(_0xff8073){const _0x4718bf=_0x24a0d3,_0x195cc6=_0xff8073&&_0xff8073[_0x4718bf('0xf5d')]?_0xff8073[_0x4718bf('0xf5d')][0x0]:null;if(!_0x195cc6)_0x56c335[_0x4718bf('0xe98')]=[];else{if(!_0x195cc6[_0x4718bf('0x170')])return _0x4d3b72[_0x4718bf('0xcf7')][_0x4718bf('0x1e6e')]({'sectionId':_0x195cc6['id']})['$promise']['then'](function(_0x2df16a){const _0x5dd40f=_0x4718bf,_0x269557=_0x2df16a&&_0x2df16a[_0x5dd40f('0xf5d')]?_0x2df16a[_0x5dd40f('0xf5d')]:[],_0x1b62eb=[];let _0x4a7776=null;_0x56c335['interval']&&(_0x4a7776=_0x2e3ca0()[_0x5dd40f('0x1c07')](_0x56c335[_0x5dd40f('0xe98')],{'name':_0x56c335[_0x5dd40f('0x115c')]['IntervalId']})),_0x4a7776&&!_0x2e3ca0()[_0x5dd40f('0x7a2')](_0x269557,[_0x5dd40f('0x832'),_0x4a7776['id']])&&_0x56c335[_0x5dd40f('0xe98')][_0x5dd40f('0x1299')](function(_0x46470d){const _0x4941fc=_0x5dd40f;_0x46470d['id']===_0x4a7776['id']&&(_0x46470d[_0x4941fc('0x319')]=![],_0x1b62eb[_0x4941fc('0x1fd0')](_0x46470d));}),_0x56c335['intervals']=_0x1b62eb;});}})['catch'](function(_0x55bd10){const _0x7a0d22=_0x24a0d3;_0x407dee[_0x7a0d22('0x52a')]({'title':_0x55bd10['status']?_0x7a0d22('0x2168')+_0x55bd10[_0x7a0d22('0x13ee')]+_0x7a0d22('0xbf6')+_0x55bd10[_0x7a0d22('0x24a9')]:'SYSTEM:GET_INTERVALS','msg':_0x55bd10[_0x7a0d22('0x5a5')]?JSON[_0x7a0d22('0x258a')](_0x55bd10[_0x7a0d22('0x5a5')]):_0x55bd10[_0x7a0d22('0x1ff0')]()});}));function _0x3e8296(){const _0x5d4917=_0x24a0d3;switch(_0x56c335[_0x5d4917('0xcf0')]){case'always':case _0x5d4917('0x2335'):return'*,*,*,*';case'custom':{const _0x44b188=[];if(_0x56c335[_0x5d4917('0xc32')]!=='*'&&_0x56c335['timeRangeFrom']&&_0x56c335[_0x5d4917('0xaa0')]){const _0x944597=(_0x56c335[_0x5d4917('0xc32')][_0x5d4917('0x2575')]()<0xa?'0':'')+_0x56c335[_0x5d4917('0xc32')][_0x5d4917('0x2575')]()+':'+((_0x56c335[_0x5d4917('0xc32')][_0x5d4917('0x1b5b')]()<0xa?'0':'')+_0x56c335[_0x5d4917('0xc32')]['getMinutes']()),_0x497ab9=(_0x56c335[_0x5d4917('0xaa0')]['getHours']()<0xa?'0':'')+_0x56c335[_0x5d4917('0xaa0')]['getHours']()+':'+((_0x56c335[_0x5d4917('0xaa0')]['getMinutes']()<0xa?'0':'')+_0x56c335[_0x5d4917('0xaa0')][_0x5d4917('0x1b5b')]());_0x44b188['push'](_0x944597+'-'+_0x497ab9);}else _0x44b188[_0x5d4917('0x1fd0')]('*');return _0x56c335[_0x5d4917('0x232d')]?_0x56c335[_0x5d4917('0x1269')]?_0x44b188['push'](_0x56c335[_0x5d4917('0x232d')]+'-'+_0x56c335[_0x5d4917('0x1269')]):_0x44b188[_0x5d4917('0x1fd0')](_0x56c335[_0x5d4917('0x232d')]):_0x44b188[_0x5d4917('0x1fd0')]('*'),_0x56c335[_0x5d4917('0xf13')]?_0x56c335[_0x5d4917('0xfe5')]?_0x44b188[_0x5d4917('0x1fd0')](_0x56c335['monthDayFrom']+'-'+_0x56c335[_0x5d4917('0xfe5')]):_0x44b188[_0x5d4917('0x1fd0')](_0x56c335[_0x5d4917('0xf13')]):_0x44b188[_0x5d4917('0x1fd0')]('*'),_0x56c335[_0x5d4917('0x1690')]?_0x56c335[_0x5d4917('0x1f12')]?_0x44b188[_0x5d4917('0x1fd0')](_0x56c335[_0x5d4917('0x1690')]+'-'+_0x56c335[_0x5d4917('0x1f12')]):_0x44b188[_0x5d4917('0x1fd0')](_0x56c335['monthFrom']):_0x44b188[_0x5d4917('0x1fd0')]('*'),_0x44b188[_0x5d4917('0x1630')]();}}}function _0x3f6b76(){const _0x3db040=_0x24a0d3;_0x56c335[_0x3db040('0x17f')]=[],_0x56c335[_0x3db040('0x115c')]['interval']=_0x3e8296(),_0x4d3b72[_0x3db040('0x115c')][_0x3db040('0xb0a')](_0x56c335[_0x3db040('0x115c')])[_0x3db040('0xe53')][_0x3db040('0x683')](function(_0x235203){const _0x1040bb=_0x3db040;_0x56c335[_0x1040bb('0xe98')][_0x1040bb('0x1fd0')](_0x235203),_0x407dee[_0x1040bb('0x53')]({'title':_0x1040bb('0x24b5'),'msg':_0x56c335[_0x1040bb('0x115c')]['name']?_0x56c335[_0x1040bb('0x115c')]['name']+_0x1040bb('0x14b5'):''}),_0x424a36();})[_0x3db040('0x130a')](function(_0x4186be){const _0x22e018=_0x3db040;console[_0x22e018('0x52a')](_0x4186be),_0x56c335[_0x22e018('0x17f')]=_0x4186be['data']['errors']||[{'message':_0x4186be['toString'](),'type':'api.interval.save'}];});}function _0x4854ae(){const _0x8b110a=_0x24a0d3;_0x56c335[_0x8b110a('0x17f')]=[],_0x56c335[_0x8b110a('0x115c')]['interval']=_0x3e8296(),_0x56c335['interval'][_0x8b110a('0x121e')]?(_0x56c335[_0x8b110a('0xcf0')]!==_0x8b110a('0x2335')&&(_0x56c335['interval']['IntervalId']=null),_0x424a36(_0x56c335[_0x8b110a('0x115c')])):_0x4d3b72[_0x8b110a('0x115c')][_0x8b110a('0x2480')]({'id':_0x56c335[_0x8b110a('0x115c')]['id']},_0x56c335[_0x8b110a('0x115c')])[_0x8b110a('0xe53')][_0x8b110a('0x683')](function(_0x308a83){const _0x4066f5=_0x8b110a,_0x2120c4=_0x2e3ca0()['find'](_0x56c335[_0x4066f5('0xe98')],{'id':_0x308a83['id']});_0x2120c4&&_0x2e3ca0()[_0x4066f5('0xf22')](_0x2120c4,_0x308a83),_0x407dee[_0x4066f5('0x53')]({'title':_0x4066f5('0x18c3'),'msg':_0x4066f5('0x224')}),_0x424a36();})['catch'](function(_0x206c7b){const _0xf78c01=_0x8b110a;console['error'](_0x206c7b),_0x56c335[_0xf78c01('0x17f')]=_0x206c7b['data']['errors']||[{'message':_0x206c7b[_0xf78c01('0x1ff0')](),'type':'api.interval.update'}];});}function _0x424a36(_0x4852e5){const _0x4b19c9=_0x24a0d3;_0x1bd51e[_0x4b19c9('0x1715')](_0x4852e5);}}const _0x548e82=_0x3b96d4,_0x1fdcd7=_0x180212['p']+_0x189033('0x1972');_0x1a7ad0[_0x189033('0x14be')]=[_0x189033('0x17e4'),'$scope',_0x189033('0x938'),'$q','$translate','$timeout',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),'api',_0x189033('0xba1')];function _0x1a7ad0(_0x102ab5,_0x5685b0,_0x52ea4b,_0x2eb929,_0x5c40bd,_0xbe4ae,_0x18848f,_0x221464,_0x56ebe8,_0x1ad6fa,_0x54b576){const _0x728f69=_0x189033,_0x3fe794=this;_0x3fe794['currentUser']=_0x54b576[_0x728f69('0x20b2')](),_0x3fe794[_0x728f69('0x115c')]={},_0x3fe794[_0x728f69('0x68')]={'count':0x0,'rows':[]},_0x3fe794['selectedIntervalIntervals']=[],_0x3fe794[_0x728f69('0x1134')],_0x3fe794[_0x728f69('0x1027')]={'animation':0x64,'onSort':function(_0x1ec723){const _0x478561=_0x728f69;_0x1ad6fa[_0x478561('0x115c')]['addIntervals']({'id':_0x3fe794[_0x478561('0x115c')]['id']},_0x1ec723[_0x478561('0x10a2')])[_0x478561('0xe53')][_0x478561('0x683')](function(_0x12ce41){const _0x579d3a=_0x478561;_0x3fe794[_0x579d3a('0x68')]['rows']=_0x12ce41;})[_0x478561('0x130a')](function(_0x1a7f8f){const _0x4bd8db=_0x478561;_0x56ebe8[_0x4bd8db('0x52a')]({'title':_0x1a7f8f[_0x4bd8db('0x13ee')]?_0x4bd8db('0x2168')+_0x1a7f8f[_0x4bd8db('0x13ee')]+'\x20-\x20'+_0x1a7f8f[_0x4bd8db('0x24a9')]:'SYSTEM:SORTABLETABLE','msg':_0x1a7f8f[_0x4bd8db('0x5a5')]?JSON[_0x4bd8db('0x258a')](_0x1a7f8f[_0x4bd8db('0x5a5')]):_0x1a7f8f[_0x4bd8db('0x1ff0')]()});});}},_0x3fe794[_0x728f69('0x23a2')]={'fields':_0x728f69('0x11d7'),'nolimit':'true','limit':0xa,'page':0x1},_0x3fe794[_0x728f69('0x12f3')]=_0x3b1067,_0x3fe794[_0x728f69('0x26eb')]=_0x2dec30,_0x3fe794[_0x728f69('0x53')]=_0x49e56c,_0x3fe794['getIntervalIntervals']=_0xb02c67,_0x3fe794[_0x728f69('0x251d')]=_0x42fbde,_0x3fe794[_0x728f69('0x1598')]=_0x51d37f,_0x3fe794[_0x728f69('0x1de5')]=_0x20c513,_0x3fe794[_0x728f69('0x61d')]=_0x501b0e;function _0x3b1067(_0x10ae14,_0x11d6d8){const _0x4a1089=_0x728f69;_0x3fe794['interval']=_0x10ae14,_0x3fe794['crudPermissions']=typeof _0x11d6d8!=='undefined'?_0x11d6d8:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3fe794['sortableTable'][_0x4a1089('0x120b')]=!_0x3fe794[_0x4a1089('0x1134')]['canEdit']?!![]:![],_0x3fe794[_0x4a1089('0x23a2')]['id']=_0x3fe794[_0x4a1089('0x115c')]['id'],_0xb02c67();}function _0x2dec30(_0x4b2270,_0x3e93df){const _0x47c164=_0x728f69,_0xdfaadc=_0x18848f[_0x47c164('0x1c6f')]()[_0x47c164('0xf28')](_0x47c164('0x1bcf'))[_0x47c164('0x26e3')](_0x47c164('0xed5')+(_0x4b2270[_0x47c164('0x60a')]||_0x4b2270['id']&&_0x2e3ca0()[_0x47c164('0x2711')](_0x47c164('0x4d8'))+_0x4b2270['id']||_0x47c164('0x115c'))+''+'\x20will\x20be\x20deleted.')[_0x47c164('0x1040')](_0x47c164('0x129'))[_0x47c164('0xe42')](_0x3e93df)['ok']('OK')['cancel']('CANCEL');_0x18848f[_0x47c164('0x1d4')](_0xdfaadc)[_0x47c164('0x683')](function(){_0x20c513(_0x4b2270);},function(){const _0x172037=_0x47c164;console['log'](_0x172037('0x16b8'));});}function _0x49e56c(_0xcd2334){const _0x10cf37=_0x728f69;_0x3fe794[_0x10cf37('0x68')]=_0xcd2334||{'count':0x0,'rows':[]};}function _0xb02c67(){const _0x4a0faa=_0x728f69;_0x3fe794[_0x4a0faa('0x23a2')][_0x4a0faa('0x1cc8')]=(_0x3fe794['query']['page']-0x1)*_0x3fe794['query'][_0x4a0faa('0x6f0')],_0x3fe794[_0x4a0faa('0x1883')]=_0x1ad6fa[_0x4a0faa('0x115c')][_0x4a0faa('0x14a')](_0x3fe794[_0x4a0faa('0x23a2')],_0x49e56c)['$promise'];}function _0x42fbde(_0x41573b,_0x3ca1cd){const _0x27d2ea=_0x728f69;_0x18848f[_0x27d2ea('0x1d4')]({'controller':'EditAppintervalDialogController','controllerAs':'vm','templateUrl':_0x1fdcd7,'parent':angular[_0x27d2ea('0x1fcc')](_0x221464[_0x27d2ea('0x18e5')]),'targetEvent':_0x41573b,'clickOutsideToClose':!![],'locals':{'interval':_0x3ca1cd,'intervals':_0x3fe794[_0x27d2ea('0x68')][_0x27d2ea('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x3fe794['crudPermissions']}});}function _0x20c513(_0x45318b){const _0x370089=_0x728f69;_0x1ad6fa['interval']['delete']({'id':_0x45318b['id']})['$promise'][_0x370089('0x683')](function(){const _0x2d5d93=_0x370089;_0x2e3ca0()['remove'](_0x3fe794[_0x2d5d93('0x68')][_0x2d5d93('0xf5d')],{'id':_0x45318b['id']}),_0x3fe794[_0x2d5d93('0x68')][_0x2d5d93('0x50d')]-=0x1,!_0x3fe794[_0x2d5d93('0x68')][_0x2d5d93('0xf5d')]['length']&&_0xb02c67(),_0x56ebe8[_0x2d5d93('0x53')]({'title':_0x2d5d93('0xdf5'),'msg':_0x45318b[_0x2d5d93('0x60a')]?_0x45318b['name']+_0x2d5d93('0x194d'):''});})[_0x370089('0x130a')](function(_0x13b653){const _0x43a527=_0x370089;if(_0x13b653[_0x43a527('0x5a5')]&&_0x13b653['data'][_0x43a527('0x17f')]&&_0x13b653[_0x43a527('0x5a5')][_0x43a527('0x17f')]['length']){_0x3fe794['errors']=_0x13b653[_0x43a527('0x5a5')][_0x43a527('0x17f')]||[{'message':_0x13b653[_0x43a527('0x1ff0')](),'type':'SYSTEM:GETinterval'}];for(let _0x405574=0x0;_0x405574<_0x13b653['data']['errors'][_0x43a527('0x1564')];_0x405574++){_0x56ebe8[_0x43a527('0x52a')]({'title':_0x13b653[_0x43a527('0x5a5')][_0x43a527('0x17f')][_0x405574][_0x43a527('0xcf0')],'msg':_0x13b653[_0x43a527('0x5a5')][_0x43a527('0x17f')][_0x405574][_0x43a527('0x8c2')]});}}else _0x56ebe8[_0x43a527('0x52a')]({'title':_0x13b653[_0x43a527('0x13ee')]?_0x43a527('0x2168')+_0x13b653[_0x43a527('0x13ee')]+'\x20-\x20'+_0x13b653[_0x43a527('0x24a9')]:'SYSTEM:GETinterval','msg':_0x13b653[_0x43a527('0x5a5')]?JSON['stringify'](_0x13b653[_0x43a527('0x5a5')][_0x43a527('0x8c2')]):_0x13b653[_0x43a527('0x8c2')]||_0x13b653[_0x43a527('0x1ff0')]()});});}function _0x51d37f(){const _0xa13081=_0x728f69,_0xe9184e=angular[_0xa13081('0x1a86')](_0x3fe794[_0xa13081('0x2791')]);return _0x3fe794[_0xa13081('0x2791')]=[],_0xe9184e;}function _0x501b0e(_0x4c51ef){const _0x1c1223=_0x728f69,_0x276cf9=_0x18848f[_0x1c1223('0x1c6f')]()[_0x1c1223('0xf28')](_0x1c1223('0x2792'))[_0x1c1223('0x26e3')](_0x1c1223('0xed5')+_0x3fe794[_0x1c1223('0x2791')][_0x1c1223('0x1564')]+_0x1c1223('0x93c')+_0x1c1223('0x1ee7'))['ariaLabel'](_0x1c1223('0x743'))[_0x1c1223('0xe42')](_0x4c51ef)['ok']('OK')[_0x1c1223('0x19fb')]('CANCEL');_0x18848f[_0x1c1223('0x1d4')](_0x276cf9)[_0x1c1223('0x683')](function(){const _0x16b35c=_0x1c1223;_0x3fe794[_0x16b35c('0x2791')][_0x16b35c('0x1299')](function(_0x3fd1c5){_0x20c513(_0x3fd1c5);}),_0x3fe794['selectedIntervalIntervals']=[];});}let _0x1dde35=!![],_0x4b6d93=0x1;_0x5685b0[_0x728f69('0x186d')]('vm_dc.query.filter',function(_0x13b8ff,_0x3f4d13){const _0x21676d=_0x728f69;_0x1dde35?_0xbe4ae(function(){_0x1dde35=![];}):(!_0x3f4d13&&(_0x4b6d93=_0x3fe794['query']['page']),_0x13b8ff!==_0x3f4d13&&(_0x3fe794['query'][_0x21676d('0xdf8')]=0x1),!_0x13b8ff&&(_0x3fe794[_0x21676d('0x23a2')][_0x21676d('0xdf8')]=_0x4b6d93),_0xb02c67());});}const _0x301609=_0x1a7ad0;_0x36fe66[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x16ea'),'$translate',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x115c'),_0x189033('0x22df')];function _0x36fe66(_0x1807be,_0x12c3f9,_0x2a7b10,_0x270de2,_0x25c8f5,_0x2c6e0c,_0x34cc03,_0x1966de,_0x1d7bbf,_0x1a71a4,_0x3a8bc1,_0x21f3cd){const _0x587f57=_0x189033,_0x195026=this;_0x195026[_0x587f57('0x11ed')]=_0x1a71a4['getCurrentUser'](),_0x195026['license']=_0x2c6e0c,_0x195026[_0x587f57('0x260a')]=_0x34cc03,_0x195026[_0x587f57('0x19b2')]=_0x195026[_0x587f57('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x195026[_0x587f57('0x1224')]=_0x12c3f9[_0x587f57('0x173e')]()+_0x587f57('0x20de')+_0x12c3f9[_0x587f57('0x19ac')](),_0x195026[_0x587f57('0x115c')]=_0x3a8bc1||_0x1807be['params'][_0x587f57('0x115c')]||{},_0x195026[_0x587f57('0x22df')]=_0x21f3cd&&_0x21f3cd[_0x587f57('0x50d')]==0x1?_0x21f3cd[_0x587f57('0xf5d')][0x0]:null,_0x195026[_0x587f57('0x1134')]=_0x1a71a4[_0x587f57('0x142a')](_0x195026[_0x587f57('0x22df')]?_0x195026[_0x587f57('0x22df')][_0x587f57('0x1134')]:null),_0x195026['hasModulePermissions']={},_0x195026[_0x587f57('0x517')]=_0x1807be[_0x587f57('0x7f2')]['tab']||0x0,_0x195026[_0x587f57('0x2430')]=_0x1d7bbf[_0x587f57('0x2289')],_0x195026[_0x587f57('0xe1d')]=_0x300727,_0x195026[_0x587f57('0x1807')]=_0x1a29ba;function _0x300727(){const _0x1ccddd=_0x587f57;_0x1807be['go'](_0x1ccddd('0xca7'),{},{'reload':_0x1ccddd('0xca7')});}function _0x1a29ba(){const _0x1e36a8=_0x587f57;_0x1966de[_0x1e36a8('0x115c')][_0x1e36a8('0x2480')]({'id':_0x195026['interval']['id']},_0x195026[_0x1e36a8('0x115c')])['$promise'][_0x1e36a8('0x683')](function(){const _0x1c9bdc=_0x1e36a8;_0x1d7bbf[_0x1c9bdc('0x53')]({'title':'Interval\x20updated!','msg':_0x195026[_0x1c9bdc('0x115c')]['name']?_0x195026[_0x1c9bdc('0x115c')][_0x1c9bdc('0x60a')]+_0x1c9bdc('0x96c'):''});})['catch'](function(_0xec960b){const _0x245dec=_0x1e36a8;_0x1d7bbf[_0x245dec('0x52a')]({'title':_0xec960b[_0x245dec('0x13ee')]?_0x245dec('0x2168')+_0xec960b['status']+_0x245dec('0xbf6')+_0xec960b[_0x245dec('0x24a9')]:_0x245dec('0x203'),'msg':_0xec960b[_0x245dec('0x5a5')]?JSON[_0x245dec('0x258a')](_0xec960b[_0x245dec('0x5a5')]):_0xec960b[_0x245dec('0x1ff0')]()});});}}const _0x21e165=_0x36fe66,_0x5b22d5=_0x180212['p']+_0x189033('0x16f0');_0x49f938[_0x189033('0x14be')]=['$scope',_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0xe98'),_0x189033('0x2a'),'userProfileSection',_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x49f938(_0x50dfb7,_0x43c93f,_0x4b6fac,_0x22ded5,_0x1f7829,_0x2e89dd,_0x12da05,_0x1f75ec,_0x1c2c72,_0x13d3af,_0x58cf2a,_0x4526ff,_0x3c1cd8,_0x28b231,_0x8906b5,_0x300457,_0x4e09af){const _0x13aeb4=_0x189033,_0x2374c7=this;_0x2374c7[_0x13aeb4('0xace')]=_0x300457,_0x2374c7[_0x13aeb4('0x260a')]=_0x4e09af,_0x2374c7[_0x13aeb4('0x11ed')]=_0x8906b5['getCurrentUser'](),_0x2374c7[_0x13aeb4('0xe98')]=_0x1c2c72||{'count':0x0,'rows':[]},_0x2374c7['userProfile']=_0x13d3af,_0x2374c7[_0x13aeb4('0x22df')]=_0x58cf2a&&_0x58cf2a['count']==0x1?_0x58cf2a[_0x13aeb4('0xf5d')][0x0]:null,_0x2374c7[_0x13aeb4('0x1134')]=_0x8906b5[_0x13aeb4('0x142a')](_0x2374c7[_0x13aeb4('0x22df')]?_0x2374c7[_0x13aeb4('0x22df')][_0x13aeb4('0x1134')]:null),_0x2374c7['table']=_0x13aeb4('0xe98'),_0x2374c7[_0x13aeb4('0x247')]='',_0x2374c7[_0x13aeb4('0x1ce2')]=null,_0x2374c7[_0x13aeb4('0x327')]=[],_0x2374c7[_0x13aeb4('0x23a2')]={'fields':_0x13aeb4('0x120a'),'sort':'-updatedAt','IntervalId':_0x13aeb4('0x13c'),'limit':0xa,'page':0x1},_0x2374c7[_0x13aeb4('0xc63')]=_0x4bca85,_0x2374c7[_0x13aeb4('0x194f')]=_0x534868,_0x2374c7[_0x13aeb4('0x53')]=_0x2235ea,_0x2374c7[_0x13aeb4('0x14a')]=_0x15eff4,_0x2374c7[_0x13aeb4('0xb35')]=_0x223213,_0x2374c7[_0x13aeb4('0x1471')]=_0x744aa9,_0x2374c7['exportSelectedIntervals']=_0x1e225b,_0x2374c7[_0x13aeb4('0x23b2')]=_0x1a8005,_0x2374c7[_0x13aeb4('0x180e')]=_0x559920,_0x2374c7[_0x13aeb4('0x1c84')]=_0x242dd3;function _0x4bca85(_0x2fb713){const _0x4bc519=_0x13aeb4;_0x4b6fac['go']('app.tools.intervals.edit',{'id':_0x2fb713['id'],'interval':_0x2fb713,'crudPermissions':_0x2374c7[_0x4bc519('0x1134')]});}function _0x534868(_0x896d53,_0x51a465){const _0x2ec22f=_0x13aeb4,_0x4ca45e=_0x1f7829[_0x2ec22f('0x1c6f')]()[_0x2ec22f('0xf28')](_0x2ec22f('0x1b01')+_0x2e3ca0()[_0x2ec22f('0x1e03')](_0x2ec22f('0x115c'))+'?')[_0x2ec22f('0x26e3')](''+(_0x896d53[_0x2ec22f('0x60a')]||_0x2ec22f('0x115c'))+_0x2ec22f('0x20f1')+'\x20will\x20be\x20deleted.')[_0x2ec22f('0x1040')](_0x2ec22f('0x129'))[_0x2ec22f('0xe42')](_0x51a465)['ok']('OK')[_0x2ec22f('0x19fb')](_0x2ec22f('0x16b8'));_0x1f7829['show'](_0x4ca45e)[_0x2ec22f('0x683')](function(){_0x744aa9(_0x896d53);},function(){const _0x36da6d=_0x2ec22f;console['log'](_0x36da6d('0x16b8'));});}let _0x1d76e9=!![],_0x32d7e1=0x1;_0x50dfb7[_0x13aeb4('0x186d')]('vm.query.filter',function(_0x162035,_0x23dbd6){const _0x56eb77=_0x13aeb4;_0x1d76e9?_0x12da05(function(){_0x1d76e9=![];}):(!_0x23dbd6&&(_0x32d7e1=_0x2374c7['query'][_0x56eb77('0xdf8')]),_0x162035!==_0x23dbd6&&(_0x2374c7[_0x56eb77('0x23a2')][_0x56eb77('0xdf8')]=0x1),!_0x162035&&(_0x2374c7[_0x56eb77('0x23a2')]['page']=_0x32d7e1),_0x2374c7[_0x56eb77('0x14a')]());});function _0x2235ea(_0x88188f){const _0x780836=_0x13aeb4;_0x2374c7[_0x780836('0xe98')]=_0x88188f||{'count':0x0,'rows':[]};}function _0x15eff4(){const _0x4e72ff=_0x13aeb4;_0x2374c7['query'][_0x4e72ff('0x1cc8')]=(_0x2374c7['query'][_0x4e72ff('0xdf8')]-0x1)*_0x2374c7[_0x4e72ff('0x23a2')][_0x4e72ff('0x6f0')],_0x8906b5[_0x4e72ff('0xca1')](_0x4e72ff('0x20c2'))?_0x2374c7['promise']=_0x4526ff[_0x4e72ff('0x115c')][_0x4e72ff('0x1e6e')](_0x2374c7['query'],_0x2235ea)[_0x4e72ff('0xe53')]:(_0x2374c7[_0x4e72ff('0x23a2')]['id']=_0x2374c7[_0x4e72ff('0x2a')]['id'],_0x2374c7[_0x4e72ff('0x23a2')][_0x4e72ff('0x1aa')]=_0x4e72ff('0xb38'),_0x2374c7[_0x4e72ff('0x1883')]=_0x4526ff['userProfile'][_0x4e72ff('0x241d')](_0x2374c7['query'],_0x2235ea)[_0x4e72ff('0xe53')]);}function _0x223213(_0x2c2953,_0x2410b6){const _0xc5381f=_0x13aeb4;_0x1f7829[_0xc5381f('0x1d4')]({'controller':'CreateOrEditIntervalDialogController','controllerAs':'vm','templateUrl':_0x5b22d5,'parent':angular[_0xc5381f('0x1fcc')](_0x2e89dd['body']),'targetEvent':_0x2c2953,'clickOutsideToClose':!![],'locals':{'interval':_0x2410b6,'intervals':_0x2374c7['intervals'][_0xc5381f('0xf5d')],'license':_0x2374c7['license'],'setting':_0x2374c7[_0xc5381f('0x260a')],'crudPermissions':_0x2374c7[_0xc5381f('0x1134')]}});}function _0x744aa9(_0x11681b){const _0x1d430b=_0x13aeb4;_0x4526ff[_0x1d430b('0x115c')][_0x1d430b('0xd7e')]({'id':_0x11681b['id']})[_0x1d430b('0xe53')]['then'](function(){const _0x3a2f26=_0x1d430b;_0x2e3ca0()['remove'](_0x2374c7[_0x3a2f26('0xe98')][_0x3a2f26('0xf5d')],{'id':_0x11681b['id']}),_0x2374c7[_0x3a2f26('0xe98')][_0x3a2f26('0x50d')]-=0x1,!_0x2374c7[_0x3a2f26('0xe98')][_0x3a2f26('0xf5d')][_0x3a2f26('0x1564')]&&_0x2374c7[_0x3a2f26('0x14a')](),_0x28b231['success']({'title':_0x2e3ca0()['startCase'](_0x3a2f26('0x22ee'))+'\x20deleted!','msg':_0x11681b[_0x3a2f26('0x60a')]?_0x11681b[_0x3a2f26('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0x1d430b('0x130a')](function(_0x530940){const _0x517960=_0x1d430b;if(_0x530940[_0x517960('0x5a5')]&&_0x530940['data']['errors']&&_0x530940[_0x517960('0x5a5')][_0x517960('0x17f')][_0x517960('0x1564')]){_0x2374c7[_0x517960('0x17f')]=_0x530940[_0x517960('0x5a5')]['errors']||[{'message':_0x530940[_0x517960('0x1ff0')](),'type':_0x517960('0x2647')}];for(let _0x414a8c=0x0;_0x414a8c<_0x530940[_0x517960('0x5a5')]['errors']['length'];_0x414a8c++){_0x28b231[_0x517960('0x52a')]({'title':_0x530940[_0x517960('0x5a5')]['errors'][_0x414a8c][_0x517960('0xcf0')],'msg':_0x530940[_0x517960('0x5a5')][_0x517960('0x17f')][_0x414a8c][_0x517960('0x8c2')]});}}else _0x28b231[_0x517960('0x52a')]({'title':_0x530940[_0x517960('0x13ee')]?_0x517960('0x2168')+_0x530940['status']+_0x517960('0xbf6')+_0x530940[_0x517960('0x24a9')]:_0x517960('0x2647'),'msg':_0x530940[_0x517960('0x5a5')]?JSON[_0x517960('0x258a')](_0x530940[_0x517960('0x5a5')][_0x517960('0x8c2')]):_0x530940[_0x517960('0x8c2')]||_0x530940[_0x517960('0x1ff0')]()});});}function _0x1e225b(){const _0x1ef67d=_0x13aeb4,_0x3ca6f0=angular['copy'](_0x2374c7[_0x1ef67d('0x327')]);return _0x2374c7['selectedIntervals']=[],_0x3ca6f0;}function _0x1a8005(_0x147e82){const _0x5a0735=_0x13aeb4,_0x21f54c=_0x1f7829[_0x5a0735('0x1c6f')]()[_0x5a0735('0xf28')](_0x5a0735('0x2792'))[_0x5a0735('0x26e3')](_0x5a0735('0xed5')+_0x2374c7['selectedIntervals'][_0x5a0735('0x1564')]+_0x5a0735('0x93c')+_0x5a0735('0x1ee7'))[_0x5a0735('0x1040')](_0x5a0735('0x1b17'))[_0x5a0735('0xe42')](_0x147e82)['ok']('OK')[_0x5a0735('0x19fb')](_0x5a0735('0x16b8'));_0x1f7829[_0x5a0735('0x1d4')](_0x21f54c)[_0x5a0735('0x683')](function(){const _0x2dcedd=_0x5a0735;_0x2374c7[_0x2dcedd('0x327')][_0x2dcedd('0x1299')](function(_0x2f7784){_0x744aa9(_0x2f7784);}),_0x2374c7['selectedIntervals']=[];});}function _0x559920(){const _0x51a914=_0x13aeb4;_0x2374c7[_0x51a914('0x327')]=[];}function _0x242dd3(){const _0x3dc7f3=_0x13aeb4;_0x2374c7[_0x3dc7f3('0x327')]=_0x2374c7['intervals'][_0x3dc7f3('0xf5d')];}}const _0x413e82=_0x49f938;_0x43496e['$inject']=[_0x189033('0x7a5'),'$state','$location',_0x189033('0x1e48'),'$q','$translate','toasty',_0x189033('0x22ab'),_0x189033('0xa4'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x43496e(_0x44450d,_0x3d57f0,_0x425007,_0x3fe2bb,_0x3286ac,_0x361db5,_0x198db3,_0x2ae1d8,_0x1da5e6,_0x4d6065,_0x4d15d2,_0xdf2063,_0x5968a9,_0xbb0cab){const _0x11fa62=_0x189033,_0x38ba90=this;_0x38ba90[_0x11fa62('0x11ed')]=_0x4d15d2['getCurrentUser'](),_0x38ba90[_0x11fa62('0x17f')]=[],_0x38ba90['setting']=_0x5968a9,_0x38ba90[_0x11fa62('0xace')]=_0xdf2063,_0x38ba90[_0x11fa62('0x1134')]=_0xbb0cab,_0x38ba90[_0x11fa62('0x258d')]={},_0x38ba90[_0x11fa62('0x19b2')]=_0x38ba90[_0x11fa62('0x260a')]&&_0x38ba90[_0x11fa62('0x260a')][_0x11fa62('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x38ba90[_0x11fa62('0xf28')]=_0x11fa62('0x32f'),_0x38ba90[_0x11fa62('0xa4')]=angular[_0x11fa62('0x1a86')](_0x1da5e6),_0x38ba90['pauses']=_0x2ae1d8,_0x38ba90[_0x11fa62('0xaab')]=![];!_0x38ba90['pause']&&(_0x38ba90[_0x11fa62('0xa4')]={},_0x38ba90[_0x11fa62('0xf28')]='TOOLS.NEW_PAUSE',_0x38ba90[_0x11fa62('0xaab')]=!![]);_0x38ba90[_0x11fa62('0x9b9')]=_0x14d910,_0x38ba90[_0x11fa62('0x26c6')]=_0x4f9d79,_0x38ba90[_0x11fa62('0x1b7d')]=_0x35db8b,_0x38ba90[_0x11fa62('0x16b3')]=_0x5c03ce,_0x38ba90[_0x11fa62('0xf82')]=_0x349c32;function _0x14d910(){const _0x1f1277=_0x11fa62;_0x38ba90['errors']=[],_0x4d6065[_0x1f1277('0xa4')]['save'](_0x38ba90[_0x1f1277('0xa4')])[_0x1f1277('0xe53')][_0x1f1277('0x683')](function(_0x273f64){const _0x42cd49=_0x1f1277;_0x38ba90[_0x42cd49('0x22ab')]['unshift'](_0x273f64[_0x42cd49('0x24e1')]()),_0x198db3[_0x42cd49('0x53')]({'title':'Pause\x20properly\x20created','msg':_0x38ba90[_0x42cd49('0xa4')][_0x42cd49('0x60a')]?_0x38ba90[_0x42cd49('0xa4')][_0x42cd49('0x60a')]+_0x42cd49('0x14b5'):''}),_0x349c32(_0x273f64);})[_0x1f1277('0x130a')](function(_0x387088){const _0x187a67=_0x1f1277;if(_0x387088[_0x187a67('0x5a5')]&&_0x387088[_0x187a67('0x5a5')][_0x187a67('0x17f')]&&_0x387088[_0x187a67('0x5a5')][_0x187a67('0x17f')][_0x187a67('0x1564')]){_0x38ba90[_0x187a67('0x17f')]=_0x387088[_0x187a67('0x5a5')][_0x187a67('0x17f')]||[{'message':_0x387088[_0x187a67('0x1ff0')](),'type':_0x187a67('0x17fd')}];for(let _0x103c9a=0x0;_0x103c9a<_0x387088[_0x187a67('0x5a5')][_0x187a67('0x17f')][_0x187a67('0x1564')];_0x103c9a+=0x1){_0x198db3[_0x187a67('0x52a')]({'title':_0x387088['data'][_0x187a67('0x17f')][_0x103c9a][_0x187a67('0xcf0')],'msg':_0x387088['data']['errors'][_0x103c9a][_0x187a67('0x8c2')]});}}else _0x198db3['error']({'title':_0x387088['status']?_0x187a67('0x2168')+_0x387088[_0x187a67('0x13ee')]+_0x187a67('0xbf6')+_0x387088[_0x187a67('0x24a9')]:_0x187a67('0x17fd'),'msg':_0x387088[_0x187a67('0x5a5')]?JSON[_0x187a67('0x258a')](_0x387088['data']['message']):_0x387088['toString']()});});}function _0x4f9d79(){const _0xe0c4b5=_0x11fa62;_0x38ba90[_0xe0c4b5('0x17f')]=[],_0x4d6065[_0xe0c4b5('0xa4')][_0xe0c4b5('0x2480')]({'id':_0x38ba90['pause']['id']},_0x38ba90[_0xe0c4b5('0xa4')])[_0xe0c4b5('0xe53')]['then'](function(_0x4aa3ec){const _0x58fec6=_0xe0c4b5,_0x2416bb=_0x2e3ca0()[_0x58fec6('0x1c07')](_0x38ba90['pauses'],{'id':_0x4aa3ec['id']});_0x2416bb&&_0x2e3ca0()[_0x58fec6('0xf22')](_0x2416bb,_0x2e3ca0()[_0x58fec6('0x24d0')](_0x4aa3ec['toJSON'](),_0x2e3ca0()[_0x58fec6('0x55e')](_0x2416bb))),_0x198db3[_0x58fec6('0x53')]({'title':_0x58fec6('0x2338'),'msg':_0x38ba90[_0x58fec6('0xa4')][_0x58fec6('0x60a')]?_0x38ba90['pause']['name']+_0x58fec6('0xf59'):''}),_0x349c32(_0x4aa3ec);})[_0xe0c4b5('0x130a')](function(_0x526ec1){const _0x15e2e5=_0xe0c4b5;if(_0x526ec1[_0x15e2e5('0x5a5')]&&_0x526ec1[_0x15e2e5('0x5a5')][_0x15e2e5('0x17f')]&&_0x526ec1[_0x15e2e5('0x5a5')][_0x15e2e5('0x17f')][_0x15e2e5('0x1564')]){_0x38ba90[_0x15e2e5('0x17f')]=_0x526ec1[_0x15e2e5('0x5a5')]['errors']||[{'message':_0x526ec1[_0x15e2e5('0x1ff0')](),'type':'api.pause.update'}];for(let _0x5f0a2f=0x0;_0x5f0a2f<_0x526ec1['data'][_0x15e2e5('0x17f')]['length'];_0x5f0a2f++){_0x198db3[_0x15e2e5('0x52a')]({'title':_0x526ec1['data'][_0x15e2e5('0x17f')][_0x5f0a2f]['type'],'msg':_0x526ec1['data']['errors'][_0x5f0a2f]['message']});}}else _0x198db3[_0x15e2e5('0x52a')]({'title':_0x526ec1[_0x15e2e5('0x13ee')]?_0x15e2e5('0x2168')+_0x526ec1[_0x15e2e5('0x13ee')]+_0x15e2e5('0xbf6')+_0x526ec1[_0x15e2e5('0x24a9')]:_0x15e2e5('0x1f92'),'msg':_0x526ec1[_0x15e2e5('0x5a5')]?JSON[_0x15e2e5('0x258a')](_0x526ec1[_0x15e2e5('0x5a5')][_0x15e2e5('0x8c2')]):_0x526ec1[_0x15e2e5('0x1ff0')]()});});}function _0x35db8b(_0x42d4ed){const _0x41847f=_0x11fa62;_0x38ba90['errors']=[];const _0x510fde=_0x3fe2bb['confirm']()['title'](_0x41847f('0x4d'))[_0x41847f('0xa6a')](_0x41847f('0xda'))[_0x41847f('0x1040')]('Delete\x20Pause')['ok'](_0x41847f('0x2307'))[_0x41847f('0x19fb')](_0x41847f('0x253a'))[_0x41847f('0xe42')](_0x42d4ed);_0x3fe2bb['show'](_0x510fde)[_0x41847f('0x683')](function(){const _0x4f53bd=_0x41847f;_0x4d6065[_0x4f53bd('0xa4')][_0x4f53bd('0xd7e')]({'id':_0x38ba90[_0x4f53bd('0xa4')]['id']})[_0x4f53bd('0xe53')][_0x4f53bd('0x683')](function(){const _0x29581f=_0x4f53bd;_0x2e3ca0()[_0x29581f('0x3ec')](_0x38ba90[_0x29581f('0x22ab')],{'id':_0x38ba90[_0x29581f('0xa4')]['id']}),_0x198db3[_0x29581f('0x53')]({'title':'Pause\x20properly\x20deleted!','msg':(_0x38ba90[_0x29581f('0xa4')][_0x29581f('0x60a')]||_0x29581f('0xa4'))+_0x29581f('0x194d')}),_0x349c32(_0x38ba90['pause']);})[_0x4f53bd('0x130a')](function(_0x3634ae){const _0x2563ad=_0x4f53bd;if(_0x3634ae[_0x2563ad('0x5a5')]&&_0x3634ae[_0x2563ad('0x5a5')][_0x2563ad('0x17f')]&&_0x3634ae['data'][_0x2563ad('0x17f')][_0x2563ad('0x1564')]){_0x38ba90[_0x2563ad('0x17f')]=_0x3634ae[_0x2563ad('0x5a5')][_0x2563ad('0x17f')]||[{'message':_0x3634ae[_0x2563ad('0x1ff0')](),'type':_0x2563ad('0x10fd')}];for(let _0x1cc86e=0x0;_0x1cc86e<_0x3634ae[_0x2563ad('0x5a5')][_0x2563ad('0x17f')][_0x2563ad('0x1564')];_0x1cc86e++){_0x198db3['error']({'title':_0x3634ae[_0x2563ad('0x5a5')][_0x2563ad('0x17f')][_0x1cc86e][_0x2563ad('0xcf0')],'msg':_0x3634ae[_0x2563ad('0x5a5')][_0x2563ad('0x17f')][_0x1cc86e][_0x2563ad('0x8c2')]});}}else _0x198db3[_0x2563ad('0x52a')]({'title':_0x3634ae[_0x2563ad('0x13ee')]?'API:'+_0x3634ae[_0x2563ad('0x13ee')]+_0x2563ad('0xbf6')+_0x3634ae[_0x2563ad('0x24a9')]:_0x2563ad('0x10fd'),'msg':_0x3634ae[_0x2563ad('0x5a5')]?JSON[_0x2563ad('0x258a')](_0x3634ae['data'][_0x2563ad('0x8c2')]):_0x3634ae['message']||_0x3634ae[_0x2563ad('0x1ff0')]()});});},function(){});}function _0x5c03ce(_0x55a68c){return _0x55a68c===null?undefined:new Date(_0x55a68c);}function _0x349c32(_0x17b208){_0x3fe2bb['hide'](_0x17b208);}}const _0x12e4cb=_0x43496e,_0x3e5b2a=_0x180212['p']+_0x189033('0x3ea');_0x52f69d[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x22ab'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),'toasty','Auth',_0x189033('0xace'),'setting'];function _0x52f69d(_0x5bd6d5,_0xeb5d07,_0x3c5fcc,_0x30444f,_0x3cb486,_0x44ea4c,_0x25cacc,_0x1cda15,_0x353131,_0x50872b,_0x2c7109,_0x52f881,_0x1f4ea8,_0x218b31,_0x1fda5a,_0x194b28,_0x2cb1fe){const _0x63538c=_0x189033,_0x1d8358=this;_0x1d8358[_0x63538c('0xace')]=_0x194b28,_0x1d8358[_0x63538c('0x260a')]=_0x2cb1fe,_0x1d8358[_0x63538c('0x11ed')]=_0x1fda5a[_0x63538c('0x20b2')](),_0x1d8358[_0x63538c('0x22ab')]=_0x353131||{'count':0x0,'rows':[]},_0x1d8358[_0x63538c('0x2a')]=_0x50872b,_0x1d8358[_0x63538c('0x22df')]=_0x2c7109&&_0x2c7109[_0x63538c('0x50d')]==0x1?_0x2c7109[_0x63538c('0xf5d')][0x0]:null,_0x1d8358[_0x63538c('0x1134')]=_0x1fda5a[_0x63538c('0x142a')](_0x1d8358[_0x63538c('0x22df')]?_0x1d8358[_0x63538c('0x22df')]['crudPermissions']:null),_0x1d8358['table']=_0x63538c('0x22ab'),_0x1d8358[_0x63538c('0x247')]='',_0x1d8358[_0x63538c('0x1ce2')]=null,_0x1d8358[_0x63538c('0x27d1')]=[],_0x1d8358[_0x63538c('0x23a2')]={'fields':'createdAt,updatedAt,id,name,description','sort':'-updatedAt','limit':0xa,'page':0x1},_0x1d8358[_0x63538c('0x1249')]=_0x3670cd,_0x1d8358[_0x63538c('0x194f')]=_0x534ee0,_0x1d8358[_0x63538c('0x53')]=_0x10b3bc,_0x1d8358[_0x63538c('0x89a')]=_0x20a81d,_0x1d8358[_0x63538c('0x1ce0')]=_0xc74524,_0x1d8358[_0x63538c('0x1b7d')]=_0x229692,_0x1d8358[_0x63538c('0x148')]=_0x1217bc,_0x1d8358[_0x63538c('0x2280')]=_0xe1ea44,_0x1d8358[_0x63538c('0xfcc')]=_0x1c7943,_0x1d8358[_0x63538c('0x1c50')]=_0x4a62ba;function _0x3670cd(_0x259d86,_0x1f902b){const _0x1160cd=_0x63538c;_0x3cb486['show']({'controller':_0x1160cd('0x6eb'),'controllerAs':'vm','templateUrl':_0x3e5b2a,'parent':angular[_0x1160cd('0x1fcc')](_0x44ea4c[_0x1160cd('0x18e5')]),'targetEvent':_0x1f902b,'clickOutsideToClose':!![],'locals':{'pause':_0x259d86,'pauses':_0x1d8358[_0x1160cd('0x22ab')][_0x1160cd('0xf5d')],'license':_0x1d8358[_0x1160cd('0xace')],'setting':null,'crudPermissions':_0x1d8358[_0x1160cd('0x1134')]}});}function _0x534ee0(_0x1ca691,_0x1597f5){const _0x34232c=_0x63538c,_0xa3cdd2=_0x3cb486['confirm']()[_0x34232c('0xf28')](_0x34232c('0x1b01')+_0x2e3ca0()['startCase'](_0x34232c('0xa4'))+'?')[_0x34232c('0x26e3')](''+(_0x1ca691[_0x34232c('0x60a')]||_0x34232c('0xa4'))+''+'\x20will\x20be\x20deleted.')[_0x34232c('0x1040')](_0x34232c('0x1aef'))[_0x34232c('0xe42')](_0x1597f5)['ok']('OK')['cancel'](_0x34232c('0x16b8'));_0x3cb486[_0x34232c('0x1d4')](_0xa3cdd2)['then'](function(){_0x229692(_0x1ca691);},function(){const _0x1c7548=_0x34232c;console['log'](_0x1c7548('0x16b8'));});}let _0x3a3647=!![],_0x389515=0x1;_0x5bd6d5[_0x63538c('0x186d')](_0x63538c('0x1e1d'),function(_0x1a1b47,_0x466703){const _0xbf1e02=_0x63538c;_0x3a3647?_0x25cacc(function(){_0x3a3647=![];}):(!_0x466703&&(_0x389515=_0x1d8358['query']['page']),_0x1a1b47!==_0x466703&&(_0x1d8358[_0xbf1e02('0x23a2')][_0xbf1e02('0xdf8')]=0x1),!_0x1a1b47&&(_0x1d8358[_0xbf1e02('0x23a2')][_0xbf1e02('0xdf8')]=_0x389515),_0x1d8358['getPauses']());});function _0x10b3bc(_0x5398d2){_0x1d8358['pauses']=_0x5398d2||{'count':0x0,'rows':[]};}function _0x20a81d(){const _0x22b0e0=_0x63538c;_0x1d8358['query'][_0x22b0e0('0x1cc8')]=(_0x1d8358[_0x22b0e0('0x23a2')][_0x22b0e0('0xdf8')]-0x1)*_0x1d8358[_0x22b0e0('0x23a2')][_0x22b0e0('0x6f0')],_0x1fda5a[_0x22b0e0('0xca1')](_0x22b0e0('0x20c2'))?_0x1d8358[_0x22b0e0('0x1883')]=_0x52f881[_0x22b0e0('0xa4')]['get'](_0x1d8358[_0x22b0e0('0x23a2')],_0x10b3bc)['$promise']:(_0x1d8358['query']['id']=_0x1d8358[_0x22b0e0('0x2a')]['id'],_0x1d8358[_0x22b0e0('0x23a2')]['section']=_0x22b0e0('0x1dcc'),_0x1d8358[_0x22b0e0('0x1883')]=_0x52f881[_0x22b0e0('0x2a')][_0x22b0e0('0x241d')](_0x1d8358[_0x22b0e0('0x23a2')],_0x10b3bc)[_0x22b0e0('0xe53')]);}function _0xc74524(_0x1d2e8a,_0xdf53fc){const _0x2dd1be=_0x63538c;_0x3cb486[_0x2dd1be('0x1d4')]({'controller':_0x2dd1be('0x6eb'),'controllerAs':'vm','templateUrl':_0x3e5b2a,'parent':angular[_0x2dd1be('0x1fcc')](_0x44ea4c[_0x2dd1be('0x18e5')]),'targetEvent':_0x1d2e8a,'clickOutsideToClose':!![],'locals':{'pause':_0xdf53fc,'pauses':_0x1d8358['pauses'][_0x2dd1be('0xf5d')],'license':_0x1d8358['license'],'setting':_0x1d8358[_0x2dd1be('0x260a')],'crudPermissions':_0x1d8358['crudPermissions']}});}function _0x229692(_0x401360){const _0x1e847f=_0x63538c;_0x52f881['pause'][_0x1e847f('0xd7e')]({'id':_0x401360['id']})[_0x1e847f('0xe53')][_0x1e847f('0x683')](function(){const _0x2beeac=_0x1e847f;_0x2e3ca0()[_0x2beeac('0x3ec')](_0x1d8358['pauses']['rows'],{'id':_0x401360['id']}),_0x1d8358[_0x2beeac('0x22ab')]['count']-=0x1,!_0x1d8358['pauses'][_0x2beeac('0xf5d')][_0x2beeac('0x1564')]&&_0x1d8358[_0x2beeac('0x89a')](),_0x218b31['success']({'title':_0x2e3ca0()[_0x2beeac('0x1e03')](_0x2beeac('0x2113'))+_0x2beeac('0xbfc'),'msg':_0x401360['name']?_0x401360['name']+_0x2beeac('0x194d'):''});})[_0x1e847f('0x130a')](function(_0x559367){const _0x35faee=_0x1e847f;if(_0x559367[_0x35faee('0x5a5')]&&_0x559367[_0x35faee('0x5a5')][_0x35faee('0x17f')]&&_0x559367[_0x35faee('0x5a5')][_0x35faee('0x17f')]['length']){_0x1d8358[_0x35faee('0x17f')]=_0x559367['data'][_0x35faee('0x17f')]||[{'message':_0x559367[_0x35faee('0x1ff0')](),'type':_0x35faee('0x3a2')}];for(let _0x238091=0x0;_0x238091<_0x559367[_0x35faee('0x5a5')][_0x35faee('0x17f')][_0x35faee('0x1564')];_0x238091++){_0x218b31['error']({'title':_0x559367['data']['errors'][_0x238091][_0x35faee('0xcf0')],'msg':_0x559367[_0x35faee('0x5a5')]['errors'][_0x238091][_0x35faee('0x8c2')]});}}else _0x218b31[_0x35faee('0x52a')]({'title':_0x559367[_0x35faee('0x13ee')]?_0x35faee('0x2168')+_0x559367[_0x35faee('0x13ee')]+'\x20-\x20'+_0x559367[_0x35faee('0x24a9')]:_0x35faee('0x3a2'),'msg':_0x559367[_0x35faee('0x5a5')]?JSON['stringify'](_0x559367[_0x35faee('0x5a5')]['message']):_0x559367['message']||_0x559367['toString']()});});}function _0x1217bc(){const _0x3e4b00=_0x63538c,_0x260bba=angular[_0x3e4b00('0x1a86')](_0x1d8358[_0x3e4b00('0x27d1')]);return _0x1d8358[_0x3e4b00('0x27d1')]=[],_0x260bba;}function _0xe1ea44(_0x248edd){const _0xba8ff2=_0x63538c,_0x341a89=_0x3cb486[_0xba8ff2('0x1c6f')]()[_0xba8ff2('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20pauses?')[_0xba8ff2('0x26e3')](''+_0x1d8358[_0xba8ff2('0x27d1')][_0xba8ff2('0x1564')]+'\x20selected'+_0xba8ff2('0x1ee7'))[_0xba8ff2('0x1040')](_0xba8ff2('0x1150'))[_0xba8ff2('0xe42')](_0x248edd)['ok']('OK')['cancel']('CANCEL');_0x3cb486[_0xba8ff2('0x1d4')](_0x341a89)[_0xba8ff2('0x683')](function(){const _0x746222=_0xba8ff2;_0x1d8358[_0x746222('0x27d1')][_0x746222('0x1299')](function(_0x1c6eb1){_0x229692(_0x1c6eb1);}),_0x1d8358['selectedPauses']=[];});}function _0x1c7943(){_0x1d8358['selectedPauses']=[];}function _0x4a62ba(){const _0x57c3da=_0x63538c;_0x1d8358[_0x57c3da('0x27d1')]=_0x1d8358[_0x57c3da('0x22ab')][_0x57c3da('0xf5d')];}}const _0x13a2b4=_0x52f69d,_0x1dc206=_0x180212['p']+_0x189033('0x235a');_0x394326['$inject']=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),'schedules',_0x189033('0x8ae'),_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x394326(_0x1574ea,_0x324b71,_0x147b0f,_0x4bf57f,_0x169252,_0x15efe6,_0xd2cb1a,_0x5135cc,_0x2c3a6b,_0x31f0e7,_0x5ea0b4,_0x44b1f5,_0x379dc8,_0x870da0){const _0x3f9c8c=_0x189033,_0x2fb954=this;_0x2fb954[_0x3f9c8c('0x11ed')]=_0x5ea0b4[_0x3f9c8c('0x20b2')](),_0x2fb954[_0x3f9c8c('0x17f')]=[],_0x2fb954[_0x3f9c8c('0x260a')]=_0x379dc8,_0x2fb954[_0x3f9c8c('0xace')]=_0x44b1f5,_0x2fb954[_0x3f9c8c('0x1134')]=_0x870da0,_0x2fb954['hasModulePermissions']={},_0x2fb954[_0x3f9c8c('0x19b2')]=_0x2fb954[_0x3f9c8c('0x260a')]&&_0x2fb954[_0x3f9c8c('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2fb954[_0x3f9c8c('0xf28')]=_0x3f9c8c('0x942'),_0x2fb954[_0x3f9c8c('0x8ae')]=angular[_0x3f9c8c('0x1a86')](_0x2c3a6b),_0x2fb954[_0x3f9c8c('0xa8')]=_0x5135cc,_0x2fb954[_0x3f9c8c('0x5fa')]=![],_0x2fb954['selectedReport']=[],_0x2fb954[_0x3f9c8c('0x23a2')]={'fields':_0x3f9c8c('0x1664'),'limit':0xa,'page':0x1,'sort':_0x3f9c8c('0xc36')};if(!_0x2fb954['schedule'])_0x2fb954['schedule']={'output':_0x3f9c8c('0x21a9'),'active':!![],'startAt':new Date(),'endAt':new Date(Date['now']()+0x1e*0x18*0x3c*0x3c*0x3e8),'cron':_0x3f9c8c('0x1a14'),'subtractNumber':0x1,'subtractUnit':'days','sendMail':![],'sendIfEmpty':!![]},_0x2fb954[_0x3f9c8c('0xf28')]=_0x3f9c8c('0x1f44'),_0x2fb954[_0x3f9c8c('0x5fa')]=!![];else{_0x2fb954[_0x3f9c8c('0x213')]=_0x2fb954[_0x3f9c8c('0x8ae')][_0x3f9c8c('0x24a1')]?_0x3f9c8c('0x20ec'):_0x3f9c8c('0x197f');const _0x2a02a1=_0x2fb954[_0x3f9c8c('0x8ae')][_0x3f9c8c('0x24a1')]?_0x2fb954[_0x3f9c8c('0x8ae')][_0x3f9c8c('0x24a1')]:_0x2fb954[_0x3f9c8c('0x8ae')][_0x3f9c8c('0x1b81')];_0x31f0e7[_0x2fb954[_0x3f9c8c('0x213')]][_0x3f9c8c('0x1e6e')]({'fields':_0x3f9c8c('0x822')})[_0x3f9c8c('0xe53')][_0x3f9c8c('0x683')](function(_0x4bfff3){const _0x3bc6e4=_0x3f9c8c;_0x2fb954['currentReport']=_0x2e3ca0()[_0x3bc6e4('0x1c07')](_0x4bfff3[_0x3bc6e4('0xf5d')],{'id':_0x2a02a1}),_0x2fb954[_0x3bc6e4('0x8ae')]['report']=_0x2fb954[_0x3bc6e4('0x916')][_0x3bc6e4('0x60a')],_0x2fb954[_0x3bc6e4('0x23a2')][_0x3bc6e4('0x2361')]=_0x2fb954[_0x3bc6e4('0x916')]['parent'];});}_0x2fb954[_0x3f9c8c('0x155b')]=_0x3ac640,_0x2fb954['saveSchedule']=_0x3a1272,_0x2fb954['deleteSchedule']=_0x438e19,_0x2fb954['getDateFromString']=_0x36b24e,_0x2fb954[_0x3f9c8c('0x2398')]=_0x18ac8d,_0x2fb954[_0x3f9c8c('0x26f8')]=_0x32b653,_0x2fb954['closeReportDialog']=_0x4174ce,_0x2fb954[_0x3f9c8c('0xf0c')]=_0x34641d,_0x2fb954['closeDialog']=_0x424bee,_0x31f0e7['analyticTreeReport'][_0x3f9c8c('0x1e6e')]({})[_0x3f9c8c('0xe53')][_0x3f9c8c('0x683')](function(_0x40755d){const _0x56b288=_0x3f9c8c;_0x2fb954[_0x56b288('0x1c99')]=_0x40755d['rows']||[];})['catch'](function(_0x539599){const _0x4dae8a=_0x3f9c8c;_0xd2cb1a['error']({'title':_0x539599['status']?'API:'+_0x539599[_0x4dae8a('0x13ee')]+_0x4dae8a('0xbf6')+_0x539599[_0x4dae8a('0x24a9')]:'SYSTEM:GET_TREEREPORTS','msg':_0x539599[_0x4dae8a('0x5a5')]?JSON[_0x4dae8a('0x258a')](_0x539599[_0x4dae8a('0x5a5')]):_0x539599[_0x4dae8a('0x1ff0')]()});}),_0x5ea0b4[_0x3f9c8c('0xca1')]('admin')?_0x31f0e7['mailAccount'][_0x3f9c8c('0x1e6e')]({'fields':_0x3f9c8c('0xa10'),'sort':'name'})['$promise'][_0x3f9c8c('0x683')](function(_0x302f9a){const _0x4b6fa8=_0x3f9c8c;_0x2fb954[_0x4b6fa8('0x1093')]=_0x302f9a['rows']||[];})[_0x3f9c8c('0x130a')](function(_0x3abac4){const _0x43bf4e=_0x3f9c8c;_0xd2cb1a['error']({'title':_0x3abac4[_0x43bf4e('0x13ee')]?_0x43bf4e('0x2168')+_0x3abac4[_0x43bf4e('0x13ee')]+_0x43bf4e('0xbf6')+_0x3abac4[_0x43bf4e('0x24a9')]:'SYSTEM:GET_MAILACCOUNTS','msg':_0x3abac4['data']?JSON['stringify'](_0x3abac4[_0x43bf4e('0x5a5')]):_0x3abac4[_0x43bf4e('0x1ff0')]()});}):_0x31f0e7[_0x3f9c8c('0xb87')]['get']({'fields':'id,name','sort':_0x3f9c8c('0x60a')})['$promise']['then'](function(_0x159dfe){const _0x30fb9d=_0x3f9c8c;_0x2fb954[_0x30fb9d('0x1093')]=_0x159dfe[_0x30fb9d('0xf5d')]||[];})[_0x3f9c8c('0x683')](function(){const _0x2801a5=_0x3f9c8c;return _0x31f0e7['userProfileSection']['get']({'userProfileId':_0x2fb954[_0x2801a5('0x11ed')]['userProfileId'],'sectionId':0x25a})[_0x2801a5('0xe53')];})[_0x3f9c8c('0x683')](function(_0x4b4cc1){const _0x22d0b8=_0x3f9c8c,_0xd8818a=_0x4b4cc1&&_0x4b4cc1[_0x22d0b8('0xf5d')]?_0x4b4cc1[_0x22d0b8('0xf5d')][0x0]:null;if(!_0xd8818a){const _0xb4dfc9=[];let _0xb9492c=null;_0x2fb954[_0x22d0b8('0x8ae')]&&(_0xb9492c=_0x2e3ca0()[_0x22d0b8('0x1c07')](_0x2fb954[_0x22d0b8('0x1093')],{'id':Number(_0x2fb954['schedule'][_0x22d0b8('0x1cd')])}));for(let _0x30f6c2=0x0;_0x30f6c2<_0x2fb954[_0x22d0b8('0x1093')][_0x22d0b8('0x1564')];_0x30f6c2++){_0xb9492c&&_0x2fb954[_0x22d0b8('0x1093')][_0x30f6c2]['id']===_0xb9492c['id']&&(_0x2fb954[_0x22d0b8('0x1093')][_0x30f6c2]['canSelect']=![],_0xb4dfc9[_0x22d0b8('0x1fd0')](_0x2fb954[_0x22d0b8('0x1093')][_0x30f6c2]));}_0x2fb954['mailAccounts']=_0xb4dfc9;}else{if(!_0xd8818a[_0x22d0b8('0x170')])return _0x31f0e7[_0x22d0b8('0xcf7')][_0x22d0b8('0x1e6e')]({'sectionId':_0xd8818a['id']})['$promise']['then'](function(_0x512588){const _0x1c1d9d=_0x22d0b8,_0x159ace=_0x2e3ca0()[_0x1c1d9d('0x386')](_0x512588[_0x1c1d9d('0xf5d')],function(_0x464ebd){const _0x5e1fcb=_0x1c1d9d;return _0x2e3ca0()[_0x5e1fcb('0x1c07')](_0x2fb954[_0x5e1fcb('0x1093')],{'id':_0x464ebd[_0x5e1fcb('0x832')]});});let _0x2df88e=null;_0x2fb954[_0x1c1d9d('0x8ae')]&&(_0x2df88e=_0x2e3ca0()[_0x1c1d9d('0x1c07')](_0x2fb954[_0x1c1d9d('0x1093')],{'id':Number(_0x2fb954[_0x1c1d9d('0x8ae')][_0x1c1d9d('0x1cd')])}));if(_0x2df88e&&!_0x2e3ca0()[_0x1c1d9d('0x7a2')](_0x159ace,['id',_0x2df88e['id']])){const _0x48011a=_0x2e3ca0()[_0x1c1d9d('0x1c07')](_0x2fb954[_0x1c1d9d('0x1093')],{'id':_0x2df88e['id']});_0x48011a['canSelect']=![],_0x159ace[_0x1c1d9d('0x1fd0')](_0x48011a);}_0x2fb954[_0x1c1d9d('0x1093')]=_0x159ace;});}})[_0x3f9c8c('0x130a')](function(_0xb03a09){const _0x173e5a=_0x3f9c8c;_0xd2cb1a['error']({'title':_0xb03a09[_0x173e5a('0x13ee')]?_0x173e5a('0x2168')+_0xb03a09[_0x173e5a('0x13ee')]+_0x173e5a('0xbf6')+_0xb03a09['statusText']:_0x173e5a('0x1ded'),'msg':_0xb03a09['data']?JSON[_0x173e5a('0x258a')](_0xb03a09[_0x173e5a('0x5a5')]):_0xb03a09[_0x173e5a('0x1ff0')]()});});function _0x3ac640(){const _0x1556f5=_0x3f9c8c;_0x2fb954[_0x1556f5('0x17f')]=[],_0x31f0e7['schedule']['save'](_0x2fb954[_0x1556f5('0x8ae')])[_0x1556f5('0xe53')][_0x1556f5('0x683')](function(_0x4b246f){const _0x210ea2=_0x1556f5;_0x2fb954[_0x210ea2('0xa8')][_0x210ea2('0x1167')](_0x4b246f[_0x210ea2('0x24e1')]()),_0xd2cb1a['success']({'title':_0x210ea2('0xf73'),'msg':_0x2fb954[_0x210ea2('0x8ae')][_0x210ea2('0x60a')]?_0x2fb954[_0x210ea2('0x8ae')]['name']+_0x210ea2('0x14b5'):''}),_0x424bee(_0x4b246f);})[_0x1556f5('0x130a')](function(_0x4bb853){const _0x2b331b=_0x1556f5;if(_0x4bb853[_0x2b331b('0x5a5')]&&_0x4bb853['data'][_0x2b331b('0x17f')]&&_0x4bb853[_0x2b331b('0x5a5')]['errors'][_0x2b331b('0x1564')]){_0x2fb954[_0x2b331b('0x17f')]=_0x4bb853['data']['errors']||[{'message':_0x4bb853[_0x2b331b('0x1ff0')](),'type':'api.schedule.save'}];for(let _0x4d5ca0=0x0;_0x4d5ca0<_0x4bb853[_0x2b331b('0x5a5')]['errors'][_0x2b331b('0x1564')];_0x4d5ca0+=0x1){_0xd2cb1a['error']({'title':_0x4bb853[_0x2b331b('0x5a5')][_0x2b331b('0x17f')][_0x4d5ca0][_0x2b331b('0xcf0')],'msg':_0x4bb853[_0x2b331b('0x5a5')]['errors'][_0x4d5ca0][_0x2b331b('0x8c2')]});}}else _0xd2cb1a[_0x2b331b('0x52a')]({'title':_0x4bb853[_0x2b331b('0x13ee')]?_0x2b331b('0x2168')+_0x4bb853[_0x2b331b('0x13ee')]+'\x20-\x20'+_0x4bb853[_0x2b331b('0x24a9')]:_0x2b331b('0x2691'),'msg':_0x4bb853['data']?JSON[_0x2b331b('0x258a')](_0x4bb853[_0x2b331b('0x5a5')][_0x2b331b('0x8c2')]):_0x4bb853[_0x2b331b('0x1ff0')]()});});}function _0x3a1272(){const _0x291cd5=_0x3f9c8c;_0x2fb954['errors']=[],_0x31f0e7['schedule'][_0x291cd5('0x2480')]({'id':_0x2fb954['schedule']['id']},_0x2fb954[_0x291cd5('0x8ae')])[_0x291cd5('0xe53')][_0x291cd5('0x683')](function(_0x48f532){const _0x2ca679=_0x291cd5,_0x32eb31=_0x2e3ca0()[_0x2ca679('0x1c07')](_0x2fb954[_0x2ca679('0xa8')],{'id':_0x48f532['id']});_0x32eb31&&_0x2e3ca0()[_0x2ca679('0xf22')](_0x32eb31,_0x2e3ca0()['pick'](_0x48f532[_0x2ca679('0x24e1')](),_0x2e3ca0()[_0x2ca679('0x55e')](_0x32eb31))),_0xd2cb1a[_0x2ca679('0x53')]({'title':_0x2ca679('0x1aba'),'msg':_0x2fb954[_0x2ca679('0x8ae')][_0x2ca679('0x60a')]?_0x2fb954[_0x2ca679('0x8ae')]['name']+_0x2ca679('0xf59'):''}),_0x424bee(_0x48f532);})[_0x291cd5('0x130a')](function(_0x1f3371){const _0x33315a=_0x291cd5;if(_0x1f3371['data']&&_0x1f3371[_0x33315a('0x5a5')][_0x33315a('0x17f')]&&_0x1f3371['data'][_0x33315a('0x17f')][_0x33315a('0x1564')]){_0x2fb954[_0x33315a('0x17f')]=_0x1f3371[_0x33315a('0x5a5')]['errors']||[{'message':_0x1f3371[_0x33315a('0x1ff0')](),'type':'api.schedule.update'}];for(let _0xf823d0=0x0;_0xf823d0<_0x1f3371['data'][_0x33315a('0x17f')][_0x33315a('0x1564')];_0xf823d0++){_0xd2cb1a[_0x33315a('0x52a')]({'title':_0x1f3371['data'][_0x33315a('0x17f')][_0xf823d0][_0x33315a('0xcf0')],'msg':_0x1f3371['data']['errors'][_0xf823d0][_0x33315a('0x8c2')]});}}else _0xd2cb1a['error']({'title':_0x1f3371[_0x33315a('0x13ee')]?_0x33315a('0x2168')+_0x1f3371[_0x33315a('0x13ee')]+_0x33315a('0xbf6')+_0x1f3371['statusText']:_0x33315a('0x1c82'),'msg':_0x1f3371[_0x33315a('0x5a5')]?JSON[_0x33315a('0x258a')](_0x1f3371[_0x33315a('0x5a5')][_0x33315a('0x8c2')]):_0x1f3371[_0x33315a('0x1ff0')]()});});}function _0x438e19(_0x42406b){const _0xfd8950=_0x3f9c8c;_0x2fb954[_0xfd8950('0x17f')]=[];const _0x544180=_0x4bf57f['confirm']()[_0xfd8950('0xf28')](_0xfd8950('0x4d'))[_0xfd8950('0xa6a')]('The\x20schedule\x20will\x20be\x20deleted.')[_0xfd8950('0x1040')](_0xfd8950('0x8a1'))['ok'](_0xfd8950('0x2307'))[_0xfd8950('0x19fb')](_0xfd8950('0x253a'))[_0xfd8950('0xe42')](_0x42406b);_0x4bf57f[_0xfd8950('0x1d4')](_0x544180)[_0xfd8950('0x683')](function(){const _0x19afe5=_0xfd8950;_0x31f0e7['schedule'][_0x19afe5('0xd7e')]({'id':_0x2fb954[_0x19afe5('0x8ae')]['id']})['$promise']['then'](function(){const _0x26e416=_0x19afe5;_0x2e3ca0()[_0x26e416('0x3ec')](_0x2fb954[_0x26e416('0xa8')],{'id':_0x2fb954['schedule']['id']}),_0xd2cb1a[_0x26e416('0x53')]({'title':_0x26e416('0x11a'),'msg':(_0x2fb954[_0x26e416('0x8ae')]['name']||_0x26e416('0x8ae'))+_0x26e416('0x194d')}),_0x424bee(_0x2fb954[_0x26e416('0x8ae')]);})['catch'](function(_0x10c4f3){const _0x24d3f1=_0x19afe5;if(_0x10c4f3['data']&&_0x10c4f3[_0x24d3f1('0x5a5')]['errors']&&_0x10c4f3[_0x24d3f1('0x5a5')][_0x24d3f1('0x17f')][_0x24d3f1('0x1564')]){_0x2fb954[_0x24d3f1('0x17f')]=_0x10c4f3[_0x24d3f1('0x5a5')][_0x24d3f1('0x17f')]||[{'message':_0x10c4f3[_0x24d3f1('0x1ff0')](),'type':'api.schedule.delete'}];for(let _0x1df70b=0x0;_0x1df70b<_0x10c4f3['data'][_0x24d3f1('0x17f')][_0x24d3f1('0x1564')];_0x1df70b++){_0xd2cb1a['error']({'title':_0x10c4f3[_0x24d3f1('0x5a5')][_0x24d3f1('0x17f')][_0x1df70b][_0x24d3f1('0xcf0')],'msg':_0x10c4f3['data']['errors'][_0x1df70b][_0x24d3f1('0x8c2')]});}}else _0xd2cb1a['error']({'title':_0x10c4f3[_0x24d3f1('0x13ee')]?'API:'+_0x10c4f3[_0x24d3f1('0x13ee')]+_0x24d3f1('0xbf6')+_0x10c4f3[_0x24d3f1('0x24a9')]:'api.schedule.delete','msg':_0x10c4f3['data']?JSON[_0x24d3f1('0x258a')](_0x10c4f3[_0x24d3f1('0x5a5')][_0x24d3f1('0x8c2')]):_0x10c4f3['message']||_0x10c4f3['toString']()});});},function(){});}function _0x1573e0(){const _0x5b5664=_0x3f9c8c,_0x499e8c={'core':{'multiple':![],'animation':!![],'error':function(_0x48bbf2){const _0x5bbb9=a0_0x4e0a;console[_0x5bbb9('0x52a')](_0x5bbb9('0x2167')+angular[_0x5bbb9('0x1bf7')](_0x48bbf2));},'check_callback':!![],'worker':!![]},'version':0x1,'plugins':[_0x5b5664('0x12a7')]};return _0x2fb954['currentUser'][_0x5b5664('0xecb')]!==_0x5b5664('0x20c2')?_0x31f0e7[_0x5b5664('0x22df')][_0x5b5664('0x1e6e')]({'fields':_0x5b5664('0x1f47'),'userProfileId':_0x2fb954[_0x5b5664('0x11ed')]['userProfileId'],'sectionId':0x4b3})[_0x5b5664('0xe53')][_0x5b5664('0x683')](function(_0x11e1e2){const _0x3eca82=_0x5b5664;return _0x2fb954[_0x3eca82('0x22df')]=_0x11e1e2&&_0x11e1e2[_0x3eca82('0x50d')]==0x1?_0x11e1e2['rows'][0x0]:null,_0x499e8c;})[_0x5b5664('0x130a')](function(_0x142078){const _0x13dd49=_0x5b5664;_0xd2cb1a['error']({'title':_0x13dd49('0x1119'),'msg':_0x142078[_0x13dd49('0x8c2')]});}):_0x499e8c;}function _0x23ccd6(_0x1a6e3e){return _0x1a6e3e?{'loaded':_0x38bc11,'select_node':_0x742f76}:{'loaded':_0xaa6a39,'select_node':_0x15d936};}function _0x742f76(_0x15fb55,_0x51022c){const _0x3d79e3=_0x3f9c8c;_0x2fb954[_0x3d79e3('0x1325')][_0x3d79e3('0x184b')](!![])[_0x3d79e3('0x1788')](),_0x2fb954[_0x3d79e3('0x1325')][_0x3d79e3('0x184b')](!![])['close_all'](),_0x2fb954[_0x3d79e3('0x121b')]=_0x51022c[_0x3d79e3('0x759')],_0x2fb954[_0x3d79e3('0x121b')]['custom']=!![],_0x2fb954[_0x3d79e3('0x228d')]=_0x2fb954[_0x3d79e3('0x13f6')][_0x3d79e3('0x184b')](!![])[_0x3d79e3('0xfd5')](_0x2fb954[_0x3d79e3('0x121b')])[_0x3d79e3('0x1630')]('/\x20'),_0x2fb954[_0x3d79e3('0x213')]=_0x3d79e3('0x197f'),_0x2fb954['query']['parent']=_0x51022c['node']['id'],_0x18ac8d();}function _0x15d936(_0x6fa4cf,_0x41dc27){const _0x26b134=_0x3f9c8c;_0x2fb954[_0x26b134('0x13f6')][_0x26b134('0x184b')](!![])['deselect_all'](),_0x2fb954[_0x26b134('0x13f6')][_0x26b134('0x184b')](!![])['close_all'](),_0x2fb954[_0x26b134('0x121b')]=_0x41dc27[_0x26b134('0x759')],_0x2fb954[_0x26b134('0x121b')][_0x26b134('0xbf0')]=![],_0x2fb954[_0x26b134('0x228d')]=_0x2fb954[_0x26b134('0x1325')][_0x26b134('0x184b')](!![])['get_path'](_0x2fb954[_0x26b134('0x121b')])['join']('/\x20'),_0x2fb954[_0x26b134('0x213')]=_0x26b134('0x20ec'),_0x2fb954['query'][_0x26b134('0x2361')]=_0x41dc27['node']['id'],_0x18ac8d();}function _0x38bc11(){const _0x4e9c8e=_0x3f9c8c;if(!_0x2fb954[_0x4e9c8e('0x5fa')]&&_0x2fb954['apiName']===_0x4e9c8e('0x197f')){const _0x3a9fd2=_0x2fb954[_0x4e9c8e('0x13f6')][_0x4e9c8e('0x184b')](!![])[_0x4e9c8e('0x36f')](_0x2fb954[_0x4e9c8e('0x23a2')]['parent']);_0x742f76(null,{'node':_0x3a9fd2,'selected':_0x3a9fd2['id']});}}function _0xaa6a39(){const _0xa69b0b=_0x3f9c8c;if(!_0x2fb954[_0xa69b0b('0x5fa')]&&_0x2fb954[_0xa69b0b('0x213')]==='analyticDefaultReport'){const _0x2af827=_0x2fb954['treeDefaultInstance']['jstree'](!![])[_0xa69b0b('0x36f')](_0x2fb954[_0xa69b0b('0x23a2')]['parent']);_0x15d936(null,{'node':_0x2af827,'selected':_0x2af827['id']});}}function _0x18ac8d(){const _0x52d44c=_0x3f9c8c;_0x2fb954[_0x52d44c('0x23a2')][_0x52d44c('0x1cc8')]=(_0x2fb954[_0x52d44c('0x23a2')][_0x52d44c('0xdf8')]-0x1)*_0x2fb954[_0x52d44c('0x23a2')][_0x52d44c('0x6f0')];if(_0x2fb954[_0x52d44c('0x213')]){if(_0x2fb954[_0x52d44c('0x11ed')][_0x52d44c('0xecb')]===_0x52d44c('0x20c2'))_0x2fb954['promise']=_0x31f0e7[_0x2fb954[_0x52d44c('0x213')]][_0x52d44c('0x1e6e')](_0x2fb954[_0x52d44c('0x23a2')],_0x27171b)['$promise'];else{if(!_0x2fb954['userProfileSection'])return _0x27171b(null);else{if(_0x2fb954[_0x52d44c('0x22df')][_0x52d44c('0x170')])_0x2fb954[_0x52d44c('0x1883')]=_0x31f0e7[_0x2fb954['apiName']][_0x52d44c('0x1e6e')](_0x2fb954['query'],_0x27171b)[_0x52d44c('0xe53')];else{let _0x26d49d=[];_0x2fb954['promise']=_0x31f0e7[_0x2fb954[_0x52d44c('0x213')]]['get'](_0x2fb954[_0x52d44c('0x23a2')])['$promise'][_0x52d44c('0x683')](function(_0x2c0211){const _0x1a644a=_0x52d44c;return _0x26d49d=_0x2c0211&&_0x2c0211['rows']?_0x2c0211['rows']:[],_0x26d49d[_0x1a644a('0x1564')]>0x0?_0x31f0e7[_0x1a644a('0xcf7')][_0x1a644a('0x1e6e')]({'sectionId':_0x2fb954[_0x1a644a('0x22df')]['id'],'type':_0x2fb954['apiName']===_0x1a644a('0x20ec')?_0x1a644a('0xbbb'):_0x1a644a('0x1a3c')})[_0x1a644a('0xe53')][_0x1a644a('0x683')](function(_0x1c62fe){const _0x2596d0=_0x1a644a,_0x57e1c2=_0x1c62fe&&_0x1c62fe[_0x2596d0('0xf5d')]?_0x1c62fe[_0x2596d0('0xf5d')]:[];if(_0x57e1c2['length']>0x0){const _0x368900=[];return _0x26d49d[_0x2596d0('0x1299')](function(_0x2c9f48){const _0x51b955=_0x2596d0,_0x2fa720=_0x2e3ca0()[_0x51b955('0x1c07')](_0x57e1c2,['resourceId',_0x2c9f48['id']]);if(_0x2fa720)_0x368900[_0x51b955('0x1fd0')](_0x2c9f48);}),_0x27171b({'count':_0x368900[_0x2596d0('0x1564')],'rows':_0x368900});}else return _0x27171b(null);}):_0x27171b(null);})[_0x52d44c('0x130a')](function(_0x5781d6){const _0x5e5b54=_0x52d44c;_0xd2cb1a[_0x5e5b54('0x52a')]({'title':_0x5781d6[_0x5e5b54('0x13ee')]?_0x5e5b54('0x2168')+_0x5781d6[_0x5e5b54('0x13ee')]+_0x5e5b54('0xbf6')+_0x5781d6[_0x5e5b54('0x24a9')]:_0x5e5b54('0x101c'),'msg':_0x5781d6[_0x5e5b54('0x5a5')]?JSON[_0x5e5b54('0x258a')](_0x5781d6[_0x5e5b54('0x5a5')]):_0x5781d6['toString']()});});}}}}}function _0x27171b(_0x549648){const _0x5a90ac=_0x3f9c8c;_0x2fb954[_0x5a90ac('0x4c2')]=_0x549648||{'count':0x0,'rows':[]},!_0x2fb954['newSchedule']&&_0x2fb954['selectedReport']['push'](_0x2e3ca0()[_0x5a90ac('0x1c07')](_0x2fb954[_0x5a90ac('0x4c2')][_0x5a90ac('0xf5d')],{'id':_0x2fb954[_0x5a90ac('0x916')]['id']}));}function _0x34641d(){const _0x2ad1b3=_0x3f9c8c;_0x2fb954[_0x2ad1b3('0x91d')]=_0x2fb954[_0x2ad1b3('0x1c99')][0x0]?angular[_0x2ad1b3('0x1cb2')](_0x2fb954[_0x2ad1b3('0x1c99')][0x0]['tree']):[],_0x2fb954['treeCustomData']=_0x2fb954[_0x2ad1b3('0x1c99')][0x1]?angular['fromJson'](_0x2fb954[_0x2ad1b3('0x1c99')][0x1][_0x2ad1b3('0x2eb')]):[],_0x2fb954[_0x2ad1b3('0x1a4e')]=_0x1573e0(),_0x2fb954[_0x2ad1b3('0x11cb')]=_0x23ccd6(![]),_0x2fb954[_0x2ad1b3('0x26b7')]=_0x23ccd6(!![]),_0x4bf57f[_0x2ad1b3('0x1d4')]({'controller':function(){return _0x2fb954;},'controllerAs':'vm','templateUrl':_0x1dc206,'autoWrap':!![],'skipHide':!![]});}function _0x32b653(){const _0x38b137=_0x3f9c8c;_0x2fb954['schedule'][_0x38b137('0xaaf')]=_0x2fb954[_0x38b137('0xe5a')][0x0][_0x38b137('0x60a')],_0x2fb954[_0x38b137('0x121b')][_0x38b137('0xbf0')]?(_0x2fb954[_0x38b137('0x8ae')]['CustomReportId']=_0x2fb954[_0x38b137('0xe5a')][0x0]['id'],delete _0x2fb954[_0x38b137('0x8ae')]['DefaultReportId']):(_0x2fb954[_0x38b137('0x8ae')][_0x38b137('0x24a1')]=_0x2fb954[_0x38b137('0xe5a')][0x0]['id'],delete _0x2fb954['schedule'][_0x38b137('0x1b81')]),_0x1574ea[_0x38b137('0x2840')]['report'][_0x38b137('0x228')](),_0x4bf57f['hide']();}function _0x4174ce(){const _0x38286d=_0x3f9c8c;_0x4bf57f[_0x38286d('0x1715')]();}function _0x36b24e(_0x2813d5){return _0x2813d5===null?undefined:new Date(_0x2813d5);}function _0x424bee(_0x4cbf61){_0x4bf57f['hide'](_0x4cbf61);}}const _0x154680=_0x394326,_0xc88006=_0x180212['p']+_0x189033('0x1962');_0xe527c7[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0xa8'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),'Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0xe527c7(_0x131d87,_0x16a765,_0x35678c,_0x333a89,_0x451d6d,_0x3e814d,_0x1c572e,_0x446149,_0x5be3c1,_0x30a96e,_0x5f2c18,_0x172a75,_0x513280,_0x8208a3,_0x160486,_0x11d02e,_0x5b48eb){const _0x1bb3de=_0x189033,_0xbedaf2=this;_0xbedaf2[_0x1bb3de('0xace')]=_0x11d02e,_0xbedaf2['setting']=_0x5b48eb,_0xbedaf2[_0x1bb3de('0x11ed')]=_0x160486['getCurrentUser'](),_0xbedaf2[_0x1bb3de('0xa8')]=_0x5be3c1||{'count':0x0,'rows':[]},_0xbedaf2[_0x1bb3de('0x2a')]=_0x30a96e,_0xbedaf2[_0x1bb3de('0x22df')]=_0x5f2c18&&_0x5f2c18[_0x1bb3de('0x50d')]==0x1?_0x5f2c18[_0x1bb3de('0xf5d')][0x0]:null,_0xbedaf2['crudPermissions']=_0x160486[_0x1bb3de('0x142a')](_0xbedaf2[_0x1bb3de('0x22df')]?_0xbedaf2[_0x1bb3de('0x22df')][_0x1bb3de('0x1134')]:null),_0xbedaf2[_0x1bb3de('0x5c4')]=_0x1bb3de('0xa8'),_0xbedaf2['listOrder']='',_0xbedaf2[_0x1bb3de('0x1ce2')]=null,_0xbedaf2[_0x1bb3de('0x210d')]=[],_0xbedaf2[_0x1bb3de('0x23a2')]={'fields':_0x1bb3de('0x1a40'),'sort':_0x1bb3de('0xc36'),'limit':0xa,'page':0x1},_0xbedaf2[_0x1bb3de('0x1010')]=_0x2e3ca0()[_0x1bb3de('0x24db')]([{'option':'CSV','value':_0x1bb3de('0x14b4')},{'option':_0x1bb3de('0x26c9'),'value':_0x1bb3de('0x91c')},{'option':_0x1bb3de('0x1466'),'value':_0x1bb3de('0x68a')}],function(_0x2c17e8){const _0x109162=_0x1bb3de;return _0x2e3ca0()['replace'](_0x2c17e8[_0x109162('0x1c6b')],new RegExp('\x27','g'),'');}),_0xbedaf2[_0x1bb3de('0xf8d')]=_0x2e3ca0()[_0x1bb3de('0x24db')]([{'option':_0x1bb3de('0x356'),'value':_0x1bb3de('0x265d')},{'option':'Hours','value':_0x1bb3de('0x7f7')},{'option':_0x1bb3de('0x25d6'),'value':_0x1bb3de('0x22b8')},{'option':_0x1bb3de('0x1e98'),'value':'\x27weeks\x27'},{'option':_0x1bb3de('0x26d2'),'value':'\x27months\x27'},{'option':_0x1bb3de('0x18ab'),'value':_0x1bb3de('0x11f4')},{'option':_0x1bb3de('0x14b'),'value':'\x27years\x27'}],function(_0x362029){const _0x737bb8=_0x1bb3de;return _0x2e3ca0()[_0x737bb8('0x1725')](_0x362029[_0x737bb8('0x1c6b')],new RegExp('\x27','g'),'');}),_0xbedaf2[_0x1bb3de('0x1249')]=_0x77e05b,_0xbedaf2[_0x1bb3de('0xa26')]=_0xb0edd2,_0xbedaf2[_0x1bb3de('0x194f')]=_0x37b9ac,_0xbedaf2['success']=_0x225f1d,_0xbedaf2[_0x1bb3de('0x1840')]=_0x43676e,_0xbedaf2[_0x1bb3de('0x24d1')]=_0x23c6a6,_0xbedaf2[_0x1bb3de('0x1ebd')]=_0x4bfce4,_0xbedaf2[_0x1bb3de('0x1f94')]=_0x18c696,_0xbedaf2[_0x1bb3de('0x11f6')]=_0x1ca096,_0xbedaf2['deselectScheduler']=_0x40918a,_0xbedaf2['selectAllScheduler']=_0x394974,_0x172a75[_0x1bb3de('0x1aaf')][_0x1bb3de('0x1e6e')]({})['$promise']['then'](function(_0x31f07d){const _0x489f4d=_0x1bb3de;_0xbedaf2[_0x489f4d('0x1c99')]=_0x31f07d[_0x489f4d('0xf5d')]||[];})[_0x1bb3de('0x130a')](function(_0x3b6c83){const _0x50e95b=_0x1bb3de;_0x8208a3[_0x50e95b('0x52a')]({'title':_0x3b6c83[_0x50e95b('0x13ee')]?_0x50e95b('0x2168')+_0x3b6c83[_0x50e95b('0x13ee')]+_0x50e95b('0xbf6')+_0x3b6c83[_0x50e95b('0x24a9')]:_0x50e95b('0x182f'),'msg':_0x3b6c83['data']?JSON[_0x50e95b('0x258a')](_0x3b6c83[_0x50e95b('0x5a5')]):_0x3b6c83[_0x50e95b('0x1ff0')]()});}),_0x160486['hasRole'](_0x1bb3de('0x20c2'))?_0x172a75[_0x1bb3de('0xb87')][_0x1bb3de('0x1e6e')]({'fields':_0x1bb3de('0xa10'),'sort':'name'})['$promise'][_0x1bb3de('0x683')](function(_0x2829da){const _0x3f23a6=_0x1bb3de;_0xbedaf2['mailAccounts']=_0x2829da[_0x3f23a6('0xf5d')]||[];})[_0x1bb3de('0x130a')](function(_0x587a0e){const _0x5c7ee8=_0x1bb3de;_0x8208a3['error']({'title':_0x587a0e[_0x5c7ee8('0x13ee')]?'API:'+_0x587a0e[_0x5c7ee8('0x13ee')]+_0x5c7ee8('0xbf6')+_0x587a0e[_0x5c7ee8('0x24a9')]:_0x5c7ee8('0x12be'),'msg':_0x587a0e[_0x5c7ee8('0x5a5')]?JSON[_0x5c7ee8('0x258a')](_0x587a0e['data']):_0x587a0e[_0x5c7ee8('0x1ff0')]()});}):_0x172a75[_0x1bb3de('0xb87')]['get']({'fields':_0x1bb3de('0xa10'),'sort':_0x1bb3de('0x60a')})['$promise'][_0x1bb3de('0x683')](function(_0x1246ea){const _0x25502b=_0x1bb3de;_0xbedaf2['mailAccounts']=_0x1246ea[_0x25502b('0xf5d')]||[];})[_0x1bb3de('0x683')](function(){const _0x1e8c36=_0x1bb3de;return _0x172a75['userProfileSection'][_0x1e8c36('0x1e6e')]({'userProfileId':_0xbedaf2[_0x1e8c36('0x11ed')][_0x1e8c36('0x2f')],'sectionId':0x25a})[_0x1e8c36('0xe53')];})[_0x1bb3de('0x683')](function(_0x12b98a){const _0x411b88=_0x1bb3de,_0x47252a=_0x12b98a&&_0x12b98a[_0x411b88('0xf5d')]?_0x12b98a[_0x411b88('0xf5d')][0x0]:null;if(!_0x47252a){const _0x27d5d5=[];let _0x4e8993=null;_0xbedaf2[_0x411b88('0x8ae')]&&(_0x4e8993=_0x2e3ca0()['find'](_0xbedaf2[_0x411b88('0x1093')],{'id':Number(_0xbedaf2['schedule'][_0x411b88('0x1cd')])}));for(let _0x4ca719=0x0;_0x4ca719<_0xbedaf2[_0x411b88('0x1093')]['length'];_0x4ca719++){_0x4e8993&&_0xbedaf2[_0x411b88('0x1093')][_0x4ca719]['id']===_0x4e8993['id']&&(_0xbedaf2[_0x411b88('0x1093')][_0x4ca719][_0x411b88('0x319')]=![],_0x27d5d5['push'](_0xbedaf2[_0x411b88('0x1093')][_0x4ca719]));}_0xbedaf2[_0x411b88('0x1093')]=_0x27d5d5;}else{if(!_0x47252a[_0x411b88('0x170')])return _0x172a75['userProfileResource'][_0x411b88('0x1e6e')]({'sectionId':_0x47252a['id']})[_0x411b88('0xe53')][_0x411b88('0x683')](function(_0x3e8a29){const _0x55ada3=_0x411b88,_0x19ffeb=_0x2e3ca0()[_0x55ada3('0x386')](_0x3e8a29['rows'],function(_0x2b455a){const _0x1fa7b3=_0x55ada3;return _0x2e3ca0()[_0x1fa7b3('0x1c07')](_0xbedaf2['mailAccounts'],{'id':_0x2b455a[_0x1fa7b3('0x832')]});});let _0x47b73f=null;_0xbedaf2[_0x55ada3('0x8ae')]&&(_0x47b73f=_0x2e3ca0()[_0x55ada3('0x1c07')](_0xbedaf2[_0x55ada3('0x1093')],{'id':Number(_0xbedaf2['schedule']['MailAccountId'])}));if(_0x47b73f&&!_0x2e3ca0()['some'](_0x19ffeb,['id',_0x47b73f['id']])){const _0x5a3e11=_0x2e3ca0()['find'](_0xbedaf2[_0x55ada3('0x1093')],{'id':_0x47b73f['id']});_0x5a3e11[_0x55ada3('0x319')]=![],_0x19ffeb[_0x55ada3('0x1fd0')](_0x5a3e11);}_0xbedaf2[_0x55ada3('0x1093')]=_0x19ffeb;});}})[_0x1bb3de('0x130a')](function(_0x190bfa){const _0x3dc465=_0x1bb3de;_0x8208a3[_0x3dc465('0x52a')]({'title':_0x190bfa[_0x3dc465('0x13ee')]?_0x3dc465('0x2168')+_0x190bfa[_0x3dc465('0x13ee')]+_0x3dc465('0xbf6')+_0x190bfa[_0x3dc465('0x24a9')]:_0x3dc465('0x1ded'),'msg':_0x190bfa[_0x3dc465('0x5a5')]?JSON[_0x3dc465('0x258a')](_0x190bfa[_0x3dc465('0x5a5')]):_0x190bfa['toString']()});});function _0x77e05b(_0x3f4b31,_0x2394ea){const _0x1b704f=_0x1bb3de;_0x451d6d[_0x1b704f('0x1d4')]({'controller':_0x1b704f('0x1186'),'controllerAs':'vm','templateUrl':_0xc88006,'parent':angular[_0x1b704f('0x1fcc')](_0x3e814d[_0x1b704f('0x18e5')]),'targetEvent':_0x2394ea,'clickOutsideToClose':!![],'locals':{'schedule':_0x3f4b31,'schedules':_0xbedaf2[_0x1b704f('0xa8')]['rows'],'license':_0xbedaf2[_0x1b704f('0xace')],'setting':null,'crudPermissions':_0xbedaf2['crudPermissions']}});}function _0xb0edd2(_0x55a5a6,_0x40c7bc){const _0x3a23ba=_0x1bb3de,_0x43208b=_0x451d6d[_0x3a23ba('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20run\x20the\x20schedule?')[_0x3a23ba('0x26e3')](''+(_0x55a5a6['name']||_0x3a23ba('0x8ae'))+''+_0x3a23ba('0x5a1'))[_0x3a23ba('0x1040')]('delete\x20schedule')[_0x3a23ba('0xe42')](_0x40c7bc)['ok']('OK')['cancel'](_0x3a23ba('0x16b8'));_0x451d6d['show'](_0x43208b)[_0x3a23ba('0x683')](function(){const _0x1c33f0=_0x3a23ba;return _0x172a75[_0x1c33f0('0x8ae')]['run']({'id':_0x55a5a6['id']})[_0x1c33f0('0xe53')];},function(){const _0x3666b5=_0x3a23ba;console[_0x3666b5('0x1b2b')]('CANCEL');});}function _0x37b9ac(_0x10ce38,_0x68f993){const _0x17f369=_0x1bb3de,_0x402bd4=_0x451d6d['confirm']()[_0x17f369('0xf28')](_0x17f369('0x1b01')+_0x2e3ca0()[_0x17f369('0x1e03')](_0x17f369('0x8ae'))+'?')[_0x17f369('0x26e3')](_0x17f369('0xed5')+(_0x10ce38['name']||'schedule')+_0x17f369('0x20f1')+_0x17f369('0x1ee7'))[_0x17f369('0x1040')]('delete\x20schedule')[_0x17f369('0xe42')](_0x68f993)['ok']('OK')[_0x17f369('0x19fb')](_0x17f369('0x16b8'));_0x451d6d[_0x17f369('0x1d4')](_0x402bd4)['then'](function(){_0x4bfce4(_0x10ce38);},function(){const _0x4745f9=_0x17f369;console[_0x4745f9('0x1b2b')](_0x4745f9('0x16b8'));});}let _0x3911fe=!![],_0x152640=0x1;_0x131d87[_0x1bb3de('0x186d')](_0x1bb3de('0x1e1d'),function(_0x16c396,_0x4342a4){const _0x1fd6ab=_0x1bb3de;_0x3911fe?_0x1c572e(function(){_0x3911fe=![];}):(!_0x4342a4&&(_0x152640=_0xbedaf2['query'][_0x1fd6ab('0xdf8')]),_0x16c396!==_0x4342a4&&(_0xbedaf2[_0x1fd6ab('0x23a2')][_0x1fd6ab('0xdf8')]=0x1),!_0x16c396&&(_0xbedaf2[_0x1fd6ab('0x23a2')][_0x1fd6ab('0xdf8')]=_0x152640),_0xbedaf2[_0x1fd6ab('0x1840')]());});function _0x225f1d(_0xedecd0){const _0x45ef90=_0x1bb3de;_0xbedaf2[_0x45ef90('0xa8')]=_0xedecd0||{'count':0x0,'rows':[]};}function _0x43676e(){const _0x43e822=_0x1bb3de;_0xbedaf2[_0x43e822('0x23a2')]['offset']=(_0xbedaf2['query'][_0x43e822('0xdf8')]-0x1)*_0xbedaf2[_0x43e822('0x23a2')]['limit'],_0x160486[_0x43e822('0xca1')]('admin')?_0xbedaf2[_0x43e822('0x1883')]=_0x172a75['schedule'][_0x43e822('0x1e6e')](_0xbedaf2[_0x43e822('0x23a2')],_0x225f1d)[_0x43e822('0xe53')]:(_0xbedaf2[_0x43e822('0x23a2')]['id']=_0xbedaf2[_0x43e822('0x2a')]['id'],_0xbedaf2['query']['section']=_0x43e822('0x2147'),_0xbedaf2[_0x43e822('0x1883')]=_0x172a75[_0x43e822('0x2a')][_0x43e822('0x241d')](_0xbedaf2[_0x43e822('0x23a2')],_0x225f1d)['$promise']);}function _0x23c6a6(_0x501a7f,_0x4d15ff){const _0x38e8a9=_0x1bb3de;_0x451d6d[_0x38e8a9('0x1d4')]({'controller':_0x38e8a9('0x1186'),'controllerAs':'vm','templateUrl':_0xc88006,'parent':angular['element'](_0x3e814d[_0x38e8a9('0x18e5')]),'targetEvent':_0x501a7f,'clickOutsideToClose':!![],'locals':{'schedule':_0x4d15ff,'schedules':_0xbedaf2['schedules'][_0x38e8a9('0xf5d')],'license':_0xbedaf2[_0x38e8a9('0xace')],'setting':_0xbedaf2[_0x38e8a9('0x260a')],'crudPermissions':_0xbedaf2[_0x38e8a9('0x1134')]}});}function _0x4bfce4(_0x2d69ac){const _0x17daab=_0x1bb3de;_0x172a75[_0x17daab('0x8ae')][_0x17daab('0xd7e')]({'id':_0x2d69ac['id']})[_0x17daab('0xe53')][_0x17daab('0x683')](function(){const _0x89c920=_0x17daab;_0x2e3ca0()[_0x89c920('0x3ec')](_0xbedaf2['schedules'][_0x89c920('0xf5d')],{'id':_0x2d69ac['id']}),_0xbedaf2['schedules'][_0x89c920('0x50d')]-=0x1,!_0xbedaf2['schedules'][_0x89c920('0xf5d')]['length']&&_0xbedaf2[_0x89c920('0x1840')](),_0x8208a3[_0x89c920('0x53')]({'title':_0x2e3ca0()['startCase']('Schedule')+_0x89c920('0xbfc'),'msg':_0x2d69ac[_0x89c920('0x60a')]?_0x2d69ac['name']+'\x20has\x20been\x20deleted!':''});})[_0x17daab('0x130a')](function(_0x2b20ef){const _0x375b09=_0x17daab;if(_0x2b20ef[_0x375b09('0x5a5')]&&_0x2b20ef[_0x375b09('0x5a5')][_0x375b09('0x17f')]&&_0x2b20ef['data']['errors']['length']){_0xbedaf2['errors']=_0x2b20ef[_0x375b09('0x5a5')][_0x375b09('0x17f')]||[{'message':_0x2b20ef[_0x375b09('0x1ff0')](),'type':_0x375b09('0x225b')}];for(let _0x49fb0d=0x0;_0x49fb0d<_0x2b20ef[_0x375b09('0x5a5')][_0x375b09('0x17f')][_0x375b09('0x1564')];_0x49fb0d++){_0x8208a3[_0x375b09('0x52a')]({'title':_0x2b20ef[_0x375b09('0x5a5')][_0x375b09('0x17f')][_0x49fb0d][_0x375b09('0xcf0')],'msg':_0x2b20ef[_0x375b09('0x5a5')][_0x375b09('0x17f')][_0x49fb0d][_0x375b09('0x8c2')]});}}else _0x8208a3['error']({'title':_0x2b20ef[_0x375b09('0x13ee')]?_0x375b09('0x2168')+_0x2b20ef['status']+'\x20-\x20'+_0x2b20ef[_0x375b09('0x24a9')]:_0x375b09('0x225b'),'msg':_0x2b20ef[_0x375b09('0x5a5')]?JSON[_0x375b09('0x258a')](_0x2b20ef[_0x375b09('0x5a5')]['message']):_0x2b20ef[_0x375b09('0x8c2')]||_0x2b20ef[_0x375b09('0x1ff0')]()});});}function _0x18c696(){const _0x1af501=_0x1bb3de,_0x489558=angular['copy'](_0xbedaf2[_0x1af501('0x210d')]);return _0xbedaf2[_0x1af501('0x210d')]=[],_0x489558;}function _0x1ca096(_0x409ae1){const _0x4a1f81=_0x1bb3de,_0x1225ba=_0x451d6d['confirm']()[_0x4a1f81('0xf28')](_0x4a1f81('0x1b38'))[_0x4a1f81('0x26e3')](''+_0xbedaf2[_0x4a1f81('0x210d')][_0x4a1f81('0x1564')]+_0x4a1f81('0x93c')+_0x4a1f81('0x1ee7'))[_0x4a1f81('0x1040')](_0x4a1f81('0xee0'))[_0x4a1f81('0xe42')](_0x409ae1)['ok']('OK')[_0x4a1f81('0x19fb')](_0x4a1f81('0x16b8'));_0x451d6d[_0x4a1f81('0x1d4')](_0x1225ba)['then'](function(){const _0x209fe2=_0x4a1f81;_0xbedaf2[_0x209fe2('0x210d')][_0x209fe2('0x1299')](function(_0x1a9620){_0x4bfce4(_0x1a9620);}),_0xbedaf2[_0x209fe2('0x210d')]=[];});}function _0x40918a(){const _0x2bf121=_0x1bb3de;_0xbedaf2[_0x2bf121('0x210d')]=[];}function _0x394974(){const _0x3b383b=_0x1bb3de;_0xbedaf2[_0x3b383b('0x210d')]=_0xbedaf2[_0x3b383b('0xa8')][_0x3b383b('0xf5d')];}}const _0x28cb23=_0xe527c7;_0x5a4abb['$inject']=['$scope',_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x11d2'),_0x189033('0x1638'),'api',_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x5a4abb(_0x504904,_0x15fbf9,_0xa86e92,_0x14cc36,_0x1dc9ad,_0x2694c9,_0x3a74bd,_0x3fb574,_0x44f91b,_0x5be0cf,_0x52c560,_0x59f467,_0x579fef,_0x5075a8){const _0x475d0f=_0x189033,_0x41998a=this;_0x41998a[_0x475d0f('0x11ed')]=_0x52c560[_0x475d0f('0x20b2')](),_0x41998a[_0x475d0f('0x17f')]=[],_0x41998a[_0x475d0f('0x260a')]=_0x579fef,_0x41998a[_0x475d0f('0xace')]=_0x59f467,_0x41998a['crudPermissions']=_0x5075a8,_0x41998a[_0x475d0f('0x258d')]={},_0x41998a[_0x475d0f('0x19b2')]=_0x41998a[_0x475d0f('0x260a')]&&_0x41998a[_0x475d0f('0x260a')][_0x475d0f('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x41998a[_0x475d0f('0xf28')]='TOOLS.EDIT_SOUND',_0x41998a[_0x475d0f('0x1638')]=angular[_0x475d0f('0x1a86')](_0x44f91b),_0x41998a[_0x475d0f('0x11d2')]=_0x3fb574,_0x41998a[_0x475d0f('0x2194')]=![];!_0x41998a['sound']&&(_0x41998a[_0x475d0f('0x1638')]={},_0x41998a['title']=_0x475d0f('0x2444'),_0x41998a[_0x475d0f('0x2194')]=!![]);_0x41998a['addNewSound']=_0x3cf0a5,_0x41998a['saveSound']=_0x45cb00,_0x41998a['deleteSound']=_0x225691,_0x41998a[_0x475d0f('0x16b3')]=_0x291ac8,_0x41998a[_0x475d0f('0xf82')]=_0x15d2cb;function _0x3cf0a5(){const _0x52b0cd=_0x475d0f;_0x41998a['errors']=[],_0x5be0cf['sound'][_0x52b0cd('0xb0a')](_0x41998a['sound'])['$promise'][_0x52b0cd('0x683')](function(_0x26af18){const _0x171c91=_0x52b0cd;_0x41998a[_0x171c91('0x11d2')]['unshift'](_0x26af18[_0x171c91('0x24e1')]()),_0x3a74bd[_0x171c91('0x53')]({'title':_0x171c91('0x5b9'),'msg':_0x41998a['sound'][_0x171c91('0x60a')]?_0x41998a[_0x171c91('0x1638')][_0x171c91('0x60a')]+_0x171c91('0x14b5'):''}),_0x15d2cb(_0x26af18);})[_0x52b0cd('0x130a')](function(_0x3e2b81){const _0x28978b=_0x52b0cd;if(_0x3e2b81[_0x28978b('0x5a5')]&&_0x3e2b81['data'][_0x28978b('0x17f')]&&_0x3e2b81['data'][_0x28978b('0x17f')][_0x28978b('0x1564')]){_0x41998a[_0x28978b('0x17f')]=_0x3e2b81[_0x28978b('0x5a5')][_0x28978b('0x17f')]||[{'message':_0x3e2b81[_0x28978b('0x1ff0')](),'type':_0x28978b('0x63c')}];for(let _0x1ef9f6=0x0;_0x1ef9f6<_0x3e2b81[_0x28978b('0x5a5')]['errors'][_0x28978b('0x1564')];_0x1ef9f6+=0x1){_0x3a74bd[_0x28978b('0x52a')]({'title':_0x3e2b81[_0x28978b('0x5a5')][_0x28978b('0x17f')][_0x1ef9f6]['type'],'msg':_0x3e2b81['data'][_0x28978b('0x17f')][_0x1ef9f6][_0x28978b('0x8c2')]});}}else _0x3a74bd[_0x28978b('0x52a')]({'title':_0x3e2b81['status']?_0x28978b('0x2168')+_0x3e2b81[_0x28978b('0x13ee')]+_0x28978b('0xbf6')+_0x3e2b81[_0x28978b('0x24a9')]:_0x28978b('0x63c'),'msg':_0x3e2b81[_0x28978b('0x5a5')]?JSON[_0x28978b('0x258a')](_0x3e2b81[_0x28978b('0x5a5')]['message']):_0x3e2b81[_0x28978b('0x1ff0')]()});});}function _0x45cb00(){const _0x2ab016=_0x475d0f;_0x41998a[_0x2ab016('0x17f')]=[],_0x5be0cf[_0x2ab016('0x1638')]['update']({'id':_0x41998a['sound']['id']},_0x41998a[_0x2ab016('0x1638')])[_0x2ab016('0xe53')][_0x2ab016('0x683')](function(_0x25decd){const _0x540f52=_0x2ab016,_0x140354=_0x2e3ca0()['find'](_0x41998a[_0x540f52('0x11d2')],{'id':_0x25decd['id']});_0x140354&&_0x2e3ca0()[_0x540f52('0xf22')](_0x140354,_0x2e3ca0()[_0x540f52('0x24d0')](_0x25decd[_0x540f52('0x24e1')](),_0x2e3ca0()[_0x540f52('0x55e')](_0x140354))),_0x3a74bd[_0x540f52('0x53')]({'title':_0x540f52('0x19a5'),'msg':_0x41998a[_0x540f52('0x1638')][_0x540f52('0x60a')]?_0x41998a[_0x540f52('0x1638')][_0x540f52('0x60a')]+_0x540f52('0xf59'):''}),_0x15d2cb(_0x25decd);})[_0x2ab016('0x130a')](function(_0x49161b){const _0x107b55=_0x2ab016;if(_0x49161b[_0x107b55('0x5a5')]&&_0x49161b['data'][_0x107b55('0x17f')]&&_0x49161b['data']['errors'][_0x107b55('0x1564')]){_0x41998a['errors']=_0x49161b[_0x107b55('0x5a5')]['errors']||[{'message':_0x49161b[_0x107b55('0x1ff0')](),'type':_0x107b55('0x4cb')}];for(let _0x5ca0b5=0x0;_0x5ca0b5<_0x49161b[_0x107b55('0x5a5')][_0x107b55('0x17f')][_0x107b55('0x1564')];_0x5ca0b5++){_0x3a74bd[_0x107b55('0x52a')]({'title':_0x49161b[_0x107b55('0x5a5')][_0x107b55('0x17f')][_0x5ca0b5][_0x107b55('0xcf0')],'msg':_0x49161b[_0x107b55('0x5a5')][_0x107b55('0x17f')][_0x5ca0b5][_0x107b55('0x8c2')]});}}else _0x3a74bd[_0x107b55('0x52a')]({'title':_0x49161b[_0x107b55('0x13ee')]?'API:'+_0x49161b[_0x107b55('0x13ee')]+'\x20-\x20'+_0x49161b[_0x107b55('0x24a9')]:'api.sound.update','msg':_0x49161b[_0x107b55('0x5a5')]?JSON[_0x107b55('0x258a')](_0x49161b[_0x107b55('0x5a5')][_0x107b55('0x8c2')]):_0x49161b['toString']()});});}function _0x225691(_0x1f131c){const _0x1d3ad1=_0x475d0f;_0x41998a['errors']=[];const _0x3e854d=_0x14cc36[_0x1d3ad1('0x1c6f')]()[_0x1d3ad1('0xf28')](_0x1d3ad1('0x4d'))[_0x1d3ad1('0xa6a')](_0x1d3ad1('0x2c'))[_0x1d3ad1('0x1040')](_0x1d3ad1('0x21f9'))['ok'](_0x1d3ad1('0x2307'))['cancel'](_0x1d3ad1('0x253a'))[_0x1d3ad1('0xe42')](_0x1f131c);_0x14cc36[_0x1d3ad1('0x1d4')](_0x3e854d)[_0x1d3ad1('0x683')](function(){const _0x5f2eae=_0x1d3ad1;_0x5be0cf[_0x5f2eae('0x1638')]['delete']({'id':_0x41998a[_0x5f2eae('0x1638')]['id']})[_0x5f2eae('0xe53')][_0x5f2eae('0x683')](function(){const _0x3c9c09=_0x5f2eae;_0x2e3ca0()[_0x3c9c09('0x3ec')](_0x41998a['sounds'],{'id':_0x41998a[_0x3c9c09('0x1638')]['id']}),_0x3a74bd[_0x3c9c09('0x53')]({'title':_0x3c9c09('0x1cd0'),'msg':(_0x41998a[_0x3c9c09('0x1638')][_0x3c9c09('0x60a')]||'sound')+_0x3c9c09('0x194d')}),_0x15d2cb(_0x41998a['sound']);})[_0x5f2eae('0x130a')](function(_0x18e863){const _0x3237d7=_0x5f2eae;if(_0x18e863['data']&&_0x18e863['data'][_0x3237d7('0x17f')]&&_0x18e863[_0x3237d7('0x5a5')][_0x3237d7('0x17f')][_0x3237d7('0x1564')]){_0x41998a[_0x3237d7('0x17f')]=_0x18e863['data'][_0x3237d7('0x17f')]||[{'message':_0x18e863[_0x3237d7('0x1ff0')](),'type':_0x3237d7('0x12bd')}];for(let _0x76acd3=0x0;_0x76acd3<_0x18e863[_0x3237d7('0x5a5')][_0x3237d7('0x17f')][_0x3237d7('0x1564')];_0x76acd3++){_0x3a74bd[_0x3237d7('0x52a')]({'title':_0x18e863[_0x3237d7('0x5a5')][_0x3237d7('0x17f')][_0x76acd3][_0x3237d7('0xcf0')],'msg':_0x18e863[_0x3237d7('0x5a5')][_0x3237d7('0x17f')][_0x76acd3][_0x3237d7('0x8c2')]});}}else _0x3a74bd[_0x3237d7('0x52a')]({'title':_0x18e863['status']?_0x3237d7('0x2168')+_0x18e863[_0x3237d7('0x13ee')]+_0x3237d7('0xbf6')+_0x18e863['statusText']:'api.sound.delete','msg':_0x18e863[_0x3237d7('0x5a5')]?JSON['stringify'](_0x18e863[_0x3237d7('0x5a5')][_0x3237d7('0x8c2')]):_0x18e863[_0x3237d7('0x8c2')]||_0x18e863[_0x3237d7('0x1ff0')]()});});},function(){});}function _0x291ac8(_0xa79f3){return _0xa79f3===null?undefined:new Date(_0xa79f3);}function _0x15d2cb(_0x1cbff8){const _0x5c19a5=_0x475d0f;_0x14cc36[_0x5c19a5('0x1715')](_0x1cbff8);}}const _0x2610cf=_0x5a4abb,_0x235478=_0x180212['p']+'src/js/modules/main/apps/tools/views/sounds/create/dialog.html/dialog.html',_0x7c605b=_0x180212['p']+'src/js/modules/main/apps/tools/views/sounds/upload/dialog.html/dialog.html';_0x4bf131[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0x11d2'),'userProfile','userProfileSection',_0x189033('0x56b'),'msUtils',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x4bf131(_0x560d6b,_0x2b15a9,_0x37e735,_0x3a8212,_0x5660bb,_0x2ff6f2,_0x35ee31,_0x55410e,_0x18cdd7,_0x5124d0,_0x2c9386,_0x4965bd,_0x330eb6,_0x548129,_0x26cce3,_0x164670,_0x40524a){const _0x3997a5=_0x189033,_0x433141=this;_0x433141[_0x3997a5('0xace')]=_0x164670,_0x433141['setting']=_0x40524a,_0x433141['currentUser']=_0x26cce3[_0x3997a5('0x20b2')](),_0x433141[_0x3997a5('0x11d2')]=_0x18cdd7||{'count':0x0,'rows':[]},_0x433141[_0x3997a5('0x2a')]=_0x5124d0,_0x433141[_0x3997a5('0x22df')]=_0x2c9386&&_0x2c9386[_0x3997a5('0x50d')]==0x1?_0x2c9386['rows'][0x0]:null,_0x433141[_0x3997a5('0x1134')]=_0x26cce3[_0x3997a5('0x142a')](_0x433141[_0x3997a5('0x22df')]?_0x433141[_0x3997a5('0x22df')][_0x3997a5('0x1134')]:null),_0x433141['table']=_0x3997a5('0x11d2'),_0x433141[_0x3997a5('0x247')]='',_0x433141[_0x3997a5('0x1ce2')]=null,_0x433141[_0x3997a5('0xa9b')]=[],_0x433141[_0x3997a5('0x23a2')]={'fields':_0x3997a5('0x25c1'),'sort':_0x3997a5('0xc36'),'limit':0xa,'page':0x1},_0x433141[_0x3997a5('0x1249')]=_0x2b1624,_0x433141[_0x3997a5('0x29d')]=_0x18b8ec,_0x433141[_0x3997a5('0x194f')]=_0x4864c3,_0x433141['success']=_0x2850a8,_0x433141[_0x3997a5('0xc50')]=_0x21914f,_0x433141[_0x3997a5('0x120c')]=_0xf05f81,_0x433141['deleteSound']=_0x495b4f,_0x433141['exportSelectedSounds']=_0x4acedb,_0x433141[_0x3997a5('0x24dc')]=_0x1116e5,_0x433141['deselectSounds']=_0x4dfdc6,_0x433141[_0x3997a5('0x2788')]=_0x4417e0,_0x433141[_0x3997a5('0xbc9')]=_0x5f4e0f;function _0x2b1624(_0x4672db,_0x1b9470){const _0xece77f=_0x3997a5;_0x5660bb[_0xece77f('0x1d4')]({'controller':_0xece77f('0x1780'),'controllerAs':'vm','templateUrl':_0x235478,'parent':angular[_0xece77f('0x1fcc')](_0x2ff6f2['body']),'targetEvent':_0x1b9470,'clickOutsideToClose':!![],'locals':{'sound':_0x4672db,'sounds':_0x433141[_0xece77f('0x11d2')][_0xece77f('0xf5d')],'license':_0x433141[_0xece77f('0xace')],'setting':null,'crudPermissions':_0x433141[_0xece77f('0x1134')]}});}function _0x18b8ec(_0x2534e8){const _0x382df7=_0x3997a5;return _0x4965bd[_0x382df7('0x1638')]['download']({'id':_0x2534e8['id']})[_0x382df7('0xe53')]['then'](function(_0x4a2006){const _0x3943fa=_0x382df7,_0x5abd2c=[_0x4a2006['buffer']];let _0x2901b4=_0x3943fa('0x18e8');const _0x77ce00=new Blob(_0x5abd2c,{'type':_0x4a2006[_0x3943fa('0xcf0')]});_0x2901b4=_0x2534e8[_0x3943fa('0xd59')]?_0x2534e8[_0x3943fa('0x1144')]+'.'+_0x2534e8['converted_format']:_0x2534e8[_0x3943fa('0x1144')];const _0x444330=window[_0x3943fa('0x12e1')][_0x3943fa('0x1ffa')]('a');_0x444330[_0x3943fa('0x130f')](_0x3943fa('0x2767'),URL[_0x3943fa('0x2820')](_0x77ce00)),_0x444330[_0x3943fa('0x130f')](_0x3943fa('0x18e8'),_0x2901b4),document['body'][_0x3943fa('0x1e43')](_0x444330),_0x444330['click']();})[_0x382df7('0x130a')](function(_0x296b64){const _0x42b129=_0x382df7;if(_0x296b64['data']&&_0x296b64[_0x42b129('0x5a5')][_0x42b129('0x17f')]&&_0x296b64[_0x42b129('0x5a5')][_0x42b129('0x17f')][_0x42b129('0x1564')])for(let _0x4b84ec=0x0;_0x4b84ec<_0x296b64[_0x42b129('0x5a5')][_0x42b129('0x17f')]['length'];_0x4b84ec++){_0x548129['error']({'title':_0x296b64[_0x42b129('0x5a5')][_0x42b129('0x17f')][_0x4b84ec]['type'],'msg':_0x296b64[_0x42b129('0x5a5')][_0x42b129('0x17f')][_0x4b84ec][_0x42b129('0x8c2')]});}else _0x548129['error']({'title':_0x296b64[_0x42b129('0x13ee')]?_0x42b129('0x2168')+_0x296b64[_0x42b129('0x13ee')]+_0x42b129('0xbf6')+_0x296b64[_0x42b129('0x24a9')]:_0x42b129('0x63c'),'msg':_0x296b64[_0x42b129('0x5a5')]?JSON[_0x42b129('0x258a')](_0x296b64[_0x42b129('0x5a5')][_0x42b129('0x8c2')]):_0x296b64[_0x42b129('0x1ff0')]()});});}function _0x4864c3(_0x70bfe5,_0x41c635){const _0x41239e=_0x3997a5,_0x30ac2d=_0x5660bb[_0x41239e('0x1c6f')]()[_0x41239e('0xf28')](_0x41239e('0x1b01')+_0x2e3ca0()[_0x41239e('0x1e03')](_0x41239e('0x1638'))+'?')['htmlContent'](''+(_0x70bfe5[_0x41239e('0x60a')]||_0x41239e('0x1638'))+_0x41239e('0x20f1')+_0x41239e('0x1ee7'))['ariaLabel'](_0x41239e('0x1428'))[_0x41239e('0xe42')](_0x41c635)['ok']('OK')[_0x41239e('0x19fb')](_0x41239e('0x16b8'));_0x5660bb[_0x41239e('0x1d4')](_0x30ac2d)[_0x41239e('0x683')](function(){_0x495b4f(_0x70bfe5);},function(){const _0x36a92c=_0x41239e;console[_0x36a92c('0x1b2b')]('CANCEL');});}let _0xd8015e=!![],_0x350b3e=0x1;_0x560d6b[_0x3997a5('0x186d')](_0x3997a5('0x1e1d'),function(_0x48cb35,_0x2568ab){const _0x447126=_0x3997a5;_0xd8015e?_0x35ee31(function(){_0xd8015e=![];}):(!_0x2568ab&&(_0x350b3e=_0x433141[_0x447126('0x23a2')][_0x447126('0xdf8')]),_0x48cb35!==_0x2568ab&&(_0x433141[_0x447126('0x23a2')]['page']=0x1),!_0x48cb35&&(_0x433141[_0x447126('0x23a2')][_0x447126('0xdf8')]=_0x350b3e),_0x433141['getSounds']());});function _0x2850a8(_0x9139d9){const _0x4fb3ca=_0x3997a5;_0x433141[_0x4fb3ca('0x11d2')]=_0x9139d9||{'count':0x0,'rows':[]};}function _0x21914f(){const _0x1129b4=_0x3997a5;_0x433141['query']['offset']=(_0x433141[_0x1129b4('0x23a2')][_0x1129b4('0xdf8')]-0x1)*_0x433141[_0x1129b4('0x23a2')][_0x1129b4('0x6f0')],_0x26cce3[_0x1129b4('0xca1')](_0x1129b4('0x20c2'))?_0x433141[_0x1129b4('0x1883')]=_0x4965bd[_0x1129b4('0x1638')][_0x1129b4('0x1e6e')](_0x433141[_0x1129b4('0x23a2')],_0x2850a8)[_0x1129b4('0xe53')]:(_0x433141[_0x1129b4('0x23a2')]['id']=_0x433141[_0x1129b4('0x2a')]['id'],_0x433141['query'][_0x1129b4('0x1aa')]='Sounds',_0x433141[_0x1129b4('0x1883')]=_0x4965bd[_0x1129b4('0x2a')][_0x1129b4('0x241d')](_0x433141[_0x1129b4('0x23a2')],_0x2850a8)[_0x1129b4('0xe53')]);}function _0xf05f81(_0x4a0feb,_0x55a03c){const _0x5648b6=_0x3997a5;_0x5660bb[_0x5648b6('0x1d4')]({'controller':_0x5648b6('0x1780'),'controllerAs':'vm','templateUrl':_0x235478,'parent':angular[_0x5648b6('0x1fcc')](_0x2ff6f2[_0x5648b6('0x18e5')]),'targetEvent':_0x4a0feb,'clickOutsideToClose':!![],'locals':{'sound':_0x55a03c,'sounds':_0x433141[_0x5648b6('0x11d2')]['rows'],'license':_0x433141[_0x5648b6('0xace')],'setting':_0x433141['setting'],'crudPermissions':_0x433141[_0x5648b6('0x1134')]}});}function _0x495b4f(_0x2bfae4){const _0x5b0520=_0x3997a5;_0x4965bd['sound'][_0x5b0520('0xd7e')]({'id':_0x2bfae4['id']})[_0x5b0520('0xe53')][_0x5b0520('0x683')](function(){const _0x47efe7=_0x5b0520;_0x2e3ca0()['remove'](_0x433141['sounds']['rows'],{'id':_0x2bfae4['id']}),_0x433141['sounds'][_0x47efe7('0x50d')]-=0x1,!_0x433141['sounds']['rows'][_0x47efe7('0x1564')]&&_0x433141[_0x47efe7('0xc50')](),_0x548129['success']({'title':_0x2e3ca0()['startCase'](_0x47efe7('0x1ef3'))+_0x47efe7('0xbfc'),'msg':_0x2bfae4['name']?_0x2bfae4[_0x47efe7('0x60a')]+_0x47efe7('0x194d'):''});})[_0x5b0520('0x130a')](function(_0x4a503c){const _0x5eed5f=_0x5b0520;if(_0x4a503c[_0x5eed5f('0x5a5')]&&_0x4a503c[_0x5eed5f('0x5a5')][_0x5eed5f('0x17f')]&&_0x4a503c[_0x5eed5f('0x5a5')]['errors']['length']){_0x433141[_0x5eed5f('0x17f')]=_0x4a503c[_0x5eed5f('0x5a5')][_0x5eed5f('0x17f')]||[{'message':_0x4a503c[_0x5eed5f('0x1ff0')](),'type':_0x5eed5f('0x98d')}];for(let _0x38b0a2=0x0;_0x38b0a2<_0x4a503c[_0x5eed5f('0x5a5')][_0x5eed5f('0x17f')][_0x5eed5f('0x1564')];_0x38b0a2++){_0x548129['error']({'title':_0x4a503c[_0x5eed5f('0x5a5')][_0x5eed5f('0x17f')][_0x38b0a2][_0x5eed5f('0xcf0')],'msg':_0x4a503c[_0x5eed5f('0x5a5')][_0x5eed5f('0x17f')][_0x38b0a2][_0x5eed5f('0x8c2')]});}}else _0x548129[_0x5eed5f('0x52a')]({'title':_0x4a503c[_0x5eed5f('0x13ee')]?_0x5eed5f('0x2168')+_0x4a503c[_0x5eed5f('0x13ee')]+_0x5eed5f('0xbf6')+_0x4a503c[_0x5eed5f('0x24a9')]:'SYSTEM:DELETEsound','msg':_0x4a503c['data']?JSON['stringify'](_0x4a503c['data']['message']):_0x4a503c[_0x5eed5f('0x8c2')]||_0x4a503c[_0x5eed5f('0x1ff0')]()});});}function _0x4acedb(){const _0x442e09=_0x3997a5,_0x268d6a=angular['copy'](_0x433141[_0x442e09('0xa9b')]);return _0x433141[_0x442e09('0xa9b')]=[],_0x268d6a;}function _0x1116e5(_0x170456){const _0x41c154=_0x3997a5,_0x1ce70c=_0x5660bb[_0x41c154('0x1c6f')]()[_0x41c154('0xf28')](_0x41c154('0x19ad'))[_0x41c154('0x26e3')](''+_0x433141[_0x41c154('0xa9b')][_0x41c154('0x1564')]+_0x41c154('0x93c')+_0x41c154('0x1ee7'))[_0x41c154('0x1040')](_0x41c154('0x2114'))[_0x41c154('0xe42')](_0x170456)['ok']('OK')[_0x41c154('0x19fb')]('CANCEL');_0x5660bb[_0x41c154('0x1d4')](_0x1ce70c)[_0x41c154('0x683')](function(){const _0x3f0d75=_0x41c154;_0x433141[_0x3f0d75('0xa9b')][_0x3f0d75('0x1299')](function(_0xd0c226){_0x495b4f(_0xd0c226);}),_0x433141[_0x3f0d75('0xa9b')]=[];});}function _0x4dfdc6(){const _0x9d462a=_0x3997a5;_0x433141[_0x9d462a('0xa9b')]=[];}function _0x4417e0(){const _0x4dafa6=_0x3997a5;_0x433141[_0x4dafa6('0xa9b')]=_0x433141[_0x4dafa6('0x11d2')][_0x4dafa6('0xf5d')];}function _0x5f4e0f(_0x5b404a){const _0x289b2b=_0x3997a5;_0x5660bb[_0x289b2b('0x1d4')]({'controller':'UploadSoundDialogController','controllerAs':'vm','templateUrl':_0x7c605b,'parent':angular['element'](_0x2ff6f2[_0x289b2b('0x18e5')]),'targetEvent':_0x5b404a,'clickOutsideToClose':!![],'locals':{'sounds':_0x433141[_0x289b2b('0x11d2')][_0x289b2b('0xf5d')]}});}}const _0x30786c=_0x4bf131;_0xfb7857[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x11d2'),'api',_0x189033('0xba1')];function _0xfb7857(_0x381842,_0x299987,_0x4642bb,_0x26ad25,_0xf8d2c7,_0xf2d93b){const _0x3182d6=_0x189033,_0x80d6=this,_0x3bd2d8=0xf,_0x25bcec=_0x3bd2d8*0x400*0x400;_0x80d6[_0x3182d6('0x11ed')]=_0xf2d93b[_0x3182d6('0x20b2')](),_0x80d6['errors']=[],_0x80d6[_0x3182d6('0xf28')]=_0x3182d6('0x506'),_0x80d6[_0x3182d6('0x11d2')]=_0x26ad25,_0x80d6[_0x3182d6('0xac3')]=[],_0x80d6[_0x3182d6('0x27d5')]='none',_0x80d6[_0x3182d6('0x1638')]={},_0x80d6[_0x3182d6('0x8f')]={'maxChunkRetries':0x1,'chunkSize':_0x25bcec,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![],'target':_0x3182d6('0xdb3')},_0x80d6[_0x3182d6('0x1fa6')]={'flow':{}},_0x80d6[_0x3182d6('0xfbe')]=![],_0x80d6['fileAdded']=_0x15e785,_0x80d6[_0x3182d6('0xa03')]=_0x29a8b3,_0x80d6['fileSuccess']=_0x45216f,_0x80d6[_0x3182d6('0xd64')]=_0xf26514,_0x80d6['uploadComplete']=_0x2efee9,_0x80d6[_0x3182d6('0xf82')]=_0x36875f;function _0x15e785(_0x700108){const _0xeccc52=_0x3182d6,_0x175ab1=[_0xeccc52('0x1d2a'),_0xeccc52('0x2061'),_0xeccc52('0x1ac0')];if(!_0x2e3ca0()[_0xeccc52('0x2292')](_0x175ab1,_0x700108[_0xeccc52('0x1197')]()))return _0x4642bb[_0xeccc52('0x52a')]({'title':_0xeccc52('0xa00')+_0x700108[_0xeccc52('0x1197')](),'msg':_0xeccc52('0x2560')+_0x175ab1['join']()}),![];if(_0x700108[_0xeccc52('0x1a41')]>_0x25bcec)return _0x4642bb[_0xeccc52('0x52a')]({'title':_0xeccc52('0x19a2'),'msg':'The\x20max\x20allowed\x20size\x20is\x20'+_0x3bd2d8+'MB'}),![];return _0x80d6[_0xeccc52('0x1638')]={'id':_0x700108[_0xeccc52('0x2379')],'file':_0x700108},_0x80d6[_0xeccc52('0xac3')][_0xeccc52('0x1167')](_0x80d6[_0xeccc52('0x1638')]),!![];}function _0x29a8b3(){const _0x32f8db=_0x3182d6;_0x80d6['uploadState']=_0x32f8db('0x132'),_0x80d6['ngFlow'][_0x32f8db('0x190a')]['opts'][_0x32f8db('0xb7d')]={'X-Requested-With':_0x32f8db('0xbfd'),'Authorization':_0x32f8db('0x189e')+_0x381842[_0x32f8db('0x1e6e')](_0x32f8db('0x555'))},_0x80d6[_0x32f8db('0x1fa6')]['flow'][_0x32f8db('0x2810')][_0x32f8db('0x23a2')]={'role':_0x80d6['currentUser']['role'],'userProfileId':_0x80d6[_0x32f8db('0x11ed')]['userProfileId']},_0x80d6[_0x32f8db('0x1fa6')][_0x32f8db('0x190a')][_0x32f8db('0xa03')]();}function _0x45216f(_0x5706aa,_0x30433b){const _0x1bce3a=_0x3182d6;_0x80d6[_0x1bce3a('0x11d2')]['unshift'](JSON[_0x1bce3a('0x1f34')](_0x30433b)),angular[_0x1bce3a('0x1299')](_0x80d6[_0x1bce3a('0xac3')],function(_0x342b26){const _0x3e2cb0=_0x1bce3a;if(_0x342b26['id']===_0x5706aa[_0x3e2cb0('0x2379')]){const _0x3c0ae9=new FileReader();_0x3c0ae9[_0x3e2cb0('0x23e1')](_0x342b26['file'][_0x3e2cb0('0x21dd')]),_0x3c0ae9['onload']=function(_0x509371){const _0x220ad0=_0x3e2cb0;_0x342b26[_0x220ad0('0x1284')]=_0x509371[_0x220ad0('0x568')]['result'];};}});}function _0xf26514(){const _0x14e937=_0x3182d6;_0x80d6['ngFlow'][_0x14e937('0x190a')][_0x14e937('0x19fb')](),_0x4642bb['error']({'title':_0x14e937('0x22fa'),'msg':_0x14e937('0x23b5')}),_0x80d6[_0x14e937('0x27d5')]=_0x14e937('0x1fb');}function _0x2efee9(){const _0x5b9f28=_0x3182d6;_0x80d6[_0x5b9f28('0x27d5')]!==_0x5b9f28('0x1fb')&&(_0x80d6[_0x5b9f28('0x27d5')]=_0x5b9f28('0x305'),_0x4642bb[_0x5b9f28('0x53')]({'title':'Upload\x20completed','msg':_0x80d6['sound'][_0x5b9f28('0x21dd')][_0x5b9f28('0x60a')]+'\x20uploaded\x20successfully'}));}function _0x36875f(){_0x299987['hide']();}}const _0x56f839=_0xfb7857;_0x543416[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty',_0x189033('0x1ce6'),'tag',_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x543416(_0x34b658,_0x2756f0,_0x534596,_0x4085ad,_0x40a6fa,_0x48e1cb,_0x248e19,_0x141555,_0x2c1958,_0x4103c5,_0x4ea000,_0x4fe01a,_0x4a49f2,_0x16a481){const _0x34536a=_0x189033,_0x242989=this;_0x242989['currentUser']=_0x4ea000[_0x34536a('0x20b2')](),_0x242989['errors']=[],_0x242989[_0x34536a('0x260a')]=_0x4a49f2,_0x242989[_0x34536a('0xace')]=_0x4fe01a,_0x242989['crudPermissions']=_0x16a481,_0x242989[_0x34536a('0x258d')]={},_0x242989['passwordPattern']=_0x242989[_0x34536a('0x260a')]&&_0x242989[_0x34536a('0x260a')][_0x34536a('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x242989[_0x34536a('0xf28')]=_0x34536a('0x26e2'),_0x242989[_0x34536a('0x270')]=angular['copy'](_0x2c1958),_0x242989[_0x34536a('0x1ce6')]=_0x141555,_0x242989[_0x34536a('0x9f6')]=![];!_0x242989[_0x34536a('0x270')]&&(_0x242989[_0x34536a('0x270')]={},_0x242989[_0x34536a('0xf28')]=_0x34536a('0x2500'),_0x242989[_0x34536a('0x9f6')]=!![]);_0x242989[_0x34536a('0x19bc')]=_0x2c1644,_0x242989[_0x34536a('0x51c')]=_0x49b71a,_0x242989[_0x34536a('0xf68')]=_0x62974b,_0x242989[_0x34536a('0x16b3')]=_0x264c93,_0x242989['closeDialog']=_0x4ea4aa;function _0x2c1644(){const _0x4aa8d1=_0x34536a;_0x242989[_0x4aa8d1('0x17f')]=[],_0x4103c5[_0x4aa8d1('0x270')]['save'](_0x242989['tag'])['$promise'][_0x4aa8d1('0x683')](function(_0x1101dc){const _0x7f28fa=_0x4aa8d1;_0x242989[_0x7f28fa('0x1ce6')][_0x7f28fa('0x1167')](_0x1101dc[_0x7f28fa('0x24e1')]()),_0x248e19[_0x7f28fa('0x53')]({'title':'Tag\x20properly\x20created','msg':_0x242989[_0x7f28fa('0x270')][_0x7f28fa('0x60a')]?_0x242989['tag'][_0x7f28fa('0x60a')]+_0x7f28fa('0x14b5'):''}),_0x4ea4aa(_0x1101dc);})[_0x4aa8d1('0x130a')](function(_0x551779){const _0x39f257=_0x4aa8d1;if(_0x551779[_0x39f257('0x5a5')]&&_0x551779[_0x39f257('0x5a5')]['errors']&&_0x551779[_0x39f257('0x5a5')][_0x39f257('0x17f')][_0x39f257('0x1564')]){_0x242989['errors']=_0x551779['data'][_0x39f257('0x17f')]||[{'message':_0x551779['toString'](),'type':_0x39f257('0x41f')}];for(let _0x5878b3=0x0;_0x5878b3<_0x551779[_0x39f257('0x5a5')]['errors'][_0x39f257('0x1564')];_0x5878b3+=0x1){_0x248e19['error']({'title':_0x551779[_0x39f257('0x5a5')][_0x39f257('0x17f')][_0x5878b3][_0x39f257('0xcf0')],'msg':_0x551779[_0x39f257('0x5a5')][_0x39f257('0x17f')][_0x5878b3][_0x39f257('0x8c2')]});}}else _0x248e19[_0x39f257('0x52a')]({'title':_0x551779['status']?_0x39f257('0x2168')+_0x551779[_0x39f257('0x13ee')]+_0x39f257('0xbf6')+_0x551779['statusText']:'api.tag.save','msg':_0x551779['data']?JSON[_0x39f257('0x258a')](_0x551779['data'][_0x39f257('0x8c2')]):_0x551779[_0x39f257('0x1ff0')]()});});}function _0x49b71a(){const _0x27a7c3=_0x34536a;_0x242989[_0x27a7c3('0x17f')]=[],_0x4103c5['tag'][_0x27a7c3('0x2480')]({'id':_0x242989['tag']['id']},_0x242989['tag'])[_0x27a7c3('0xe53')][_0x27a7c3('0x683')](function(_0x270961){const _0xf4c366=_0x27a7c3,_0x4dab78=_0x2e3ca0()[_0xf4c366('0x1c07')](_0x242989['tags'],{'id':_0x270961['id']});_0x4dab78&&_0x2e3ca0()[_0xf4c366('0xf22')](_0x4dab78,_0x2e3ca0()[_0xf4c366('0x24d0')](_0x270961[_0xf4c366('0x24e1')](),_0x2e3ca0()['keys'](_0x4dab78))),_0x248e19[_0xf4c366('0x53')]({'title':_0xf4c366('0xd61'),'msg':_0x242989[_0xf4c366('0x270')][_0xf4c366('0x60a')]?_0x242989[_0xf4c366('0x270')]['name']+_0xf4c366('0xf59'):''}),_0x4ea4aa(_0x270961);})[_0x27a7c3('0x130a')](function(_0x52bf56){const _0x4854ee=_0x27a7c3;if(_0x52bf56[_0x4854ee('0x5a5')]&&_0x52bf56['data'][_0x4854ee('0x17f')]&&_0x52bf56[_0x4854ee('0x5a5')][_0x4854ee('0x17f')]['length']){_0x242989[_0x4854ee('0x17f')]=_0x52bf56[_0x4854ee('0x5a5')][_0x4854ee('0x17f')]||[{'message':_0x52bf56[_0x4854ee('0x1ff0')](),'type':_0x4854ee('0x828')}];for(let _0x2788e6=0x0;_0x2788e6<_0x52bf56[_0x4854ee('0x5a5')]['errors'][_0x4854ee('0x1564')];_0x2788e6++){_0x248e19[_0x4854ee('0x52a')]({'title':_0x52bf56['data'][_0x4854ee('0x17f')][_0x2788e6][_0x4854ee('0xcf0')],'msg':_0x52bf56[_0x4854ee('0x5a5')][_0x4854ee('0x17f')][_0x2788e6]['message']});}}else _0x248e19[_0x4854ee('0x52a')]({'title':_0x52bf56[_0x4854ee('0x13ee')]?'API:'+_0x52bf56[_0x4854ee('0x13ee')]+_0x4854ee('0xbf6')+_0x52bf56[_0x4854ee('0x24a9')]:_0x4854ee('0x828'),'msg':_0x52bf56[_0x4854ee('0x5a5')]?JSON[_0x4854ee('0x258a')](_0x52bf56[_0x4854ee('0x5a5')][_0x4854ee('0x8c2')]):_0x52bf56['toString']()});});}function _0x62974b(_0x312a60){const _0x5e7c84=_0x34536a;_0x242989['errors']=[];const _0x244f3f=_0x4085ad['confirm']()['title']('Are\x20you\x20sure?')['content'](_0x5e7c84('0x17a6'))[_0x5e7c84('0x1040')]('Delete\x20Tag')['ok'](_0x5e7c84('0x2307'))[_0x5e7c84('0x19fb')]('Cancel')[_0x5e7c84('0xe42')](_0x312a60);_0x4085ad[_0x5e7c84('0x1d4')](_0x244f3f)['then'](function(){const _0x315083=_0x5e7c84;_0x4103c5['tag'][_0x315083('0xd7e')]({'id':_0x242989[_0x315083('0x270')]['id']})['$promise'][_0x315083('0x683')](function(){const _0x239b2e=_0x315083;_0x2e3ca0()[_0x239b2e('0x3ec')](_0x242989[_0x239b2e('0x1ce6')],{'id':_0x242989[_0x239b2e('0x270')]['id']}),_0x248e19[_0x239b2e('0x53')]({'title':_0x239b2e('0x1bc6'),'msg':(_0x242989[_0x239b2e('0x270')]['name']||_0x239b2e('0x270'))+'\x20has\x20been\x20deleted!'}),_0x4ea4aa(_0x242989[_0x239b2e('0x270')]);})['catch'](function(_0xd45e59){const _0x400441=_0x315083;if(_0xd45e59['data']&&_0xd45e59['data']['errors']&&_0xd45e59[_0x400441('0x5a5')][_0x400441('0x17f')][_0x400441('0x1564')]){_0x242989[_0x400441('0x17f')]=_0xd45e59['data'][_0x400441('0x17f')]||[{'message':_0xd45e59[_0x400441('0x1ff0')](),'type':_0x400441('0x16fe')}];for(let _0x37fc58=0x0;_0x37fc58<_0xd45e59[_0x400441('0x5a5')][_0x400441('0x17f')][_0x400441('0x1564')];_0x37fc58++){_0x248e19[_0x400441('0x52a')]({'title':_0xd45e59['data'][_0x400441('0x17f')][_0x37fc58][_0x400441('0xcf0')],'msg':_0xd45e59[_0x400441('0x5a5')]['errors'][_0x37fc58][_0x400441('0x8c2')]});}}else _0x248e19[_0x400441('0x52a')]({'title':_0xd45e59[_0x400441('0x13ee')]?_0x400441('0x2168')+_0xd45e59['status']+_0x400441('0xbf6')+_0xd45e59[_0x400441('0x24a9')]:_0x400441('0x16fe'),'msg':_0xd45e59[_0x400441('0x5a5')]?JSON[_0x400441('0x258a')](_0xd45e59['data'][_0x400441('0x8c2')]):_0xd45e59['message']||_0xd45e59[_0x400441('0x1ff0')]()});});},function(){});}function _0x264c93(_0x549d6c){return _0x549d6c===null?undefined:new Date(_0x549d6c);}function _0x4ea4aa(_0x571e52){_0x4085ad['hide'](_0x571e52);}}const _0xf98cd1=_0x543416,_0x23366e=_0x180212['p']+_0x189033('0xdbb');_0x50e0dc['$inject']=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x1ce6'),'userProfile',_0x189033('0x22df'),'api',_0x189033('0x1cc2'),'toasty',_0x189033('0xba1'),'license',_0x189033('0x260a')];function _0x50e0dc(_0x31038d,_0x425399,_0xb7be84,_0x558126,_0x38f241,_0x42be03,_0x2ad825,_0x118f57,_0x204ef2,_0x291a0b,_0x4901af,_0x241165,_0x5d6bc8,_0x170736,_0x9611d6,_0x4953ed,_0x3e0575){const _0x4c6748=_0x189033,_0x19f96e=this;_0x19f96e[_0x4c6748('0xace')]=_0x4953ed,_0x19f96e[_0x4c6748('0x260a')]=_0x3e0575,_0x19f96e['currentUser']=_0x9611d6['getCurrentUser'](),_0x19f96e[_0x4c6748('0x1ce6')]=_0x204ef2||{'count':0x0,'rows':[]},_0x19f96e['userProfile']=_0x291a0b,_0x19f96e[_0x4c6748('0x22df')]=_0x4901af&&_0x4901af[_0x4c6748('0x50d')]==0x1?_0x4901af[_0x4c6748('0xf5d')][0x0]:null,_0x19f96e['crudPermissions']=_0x9611d6[_0x4c6748('0x142a')](_0x19f96e[_0x4c6748('0x22df')]?_0x19f96e['userProfileSection']['crudPermissions']:null),_0x19f96e[_0x4c6748('0x5c4')]=_0x4c6748('0x1ce6'),_0x19f96e['listOrder']='',_0x19f96e[_0x4c6748('0x1ce2')]=null,_0x19f96e[_0x4c6748('0x2100')]=[],_0x19f96e[_0x4c6748('0x23a2')]={'fields':_0x4c6748('0x1667'),'sort':_0x4c6748('0xc36'),'limit':0xa,'page':0x1},_0x19f96e[_0x4c6748('0x1249')]=_0x32c212,_0x19f96e[_0x4c6748('0x194f')]=_0x5ddf85,_0x19f96e['success']=_0x3a20c5,_0x19f96e[_0x4c6748('0x8a5')]=_0x29e8bd,_0x19f96e[_0x4c6748('0x19f4')]=_0xafb7ec,_0x19f96e[_0x4c6748('0xf68')]=_0xed58e3,_0x19f96e[_0x4c6748('0x1a29')]=_0x278018,_0x19f96e['deleteSelectedTags']=_0x5ac588,_0x19f96e[_0x4c6748('0x1fa7')]=_0x40e4dd,_0x19f96e[_0x4c6748('0x28')]=_0x1b9082;function _0x32c212(_0x3a23f9,_0xea9990){const _0x257cc9=_0x4c6748;_0x38f241[_0x257cc9('0x1d4')]({'controller':_0x257cc9('0x17b2'),'controllerAs':'vm','templateUrl':_0x23366e,'parent':angular[_0x257cc9('0x1fcc')](_0x42be03['body']),'targetEvent':_0xea9990,'clickOutsideToClose':!![],'locals':{'tag':_0x3a23f9,'tags':_0x19f96e[_0x257cc9('0x1ce6')]['rows'],'license':_0x19f96e['license'],'setting':null,'crudPermissions':_0x19f96e[_0x257cc9('0x1134')]}});}function _0x5ddf85(_0x440ee7,_0x128bcc){const _0x17188a=_0x4c6748,_0x4a118e=_0x38f241[_0x17188a('0x1c6f')]()[_0x17188a('0xf28')](_0x17188a('0x1b01')+_0x2e3ca0()[_0x17188a('0x1e03')](_0x17188a('0x270'))+'?')['htmlContent'](''+(_0x440ee7[_0x17188a('0x60a')]||_0x17188a('0x270'))+_0x17188a('0x20f1')+_0x17188a('0x1ee7'))[_0x17188a('0x1040')](_0x17188a('0x2387'))[_0x17188a('0xe42')](_0x128bcc)['ok']('OK')['cancel'](_0x17188a('0x16b8'));_0x38f241[_0x17188a('0x1d4')](_0x4a118e)[_0x17188a('0x683')](function(){_0xed58e3(_0x440ee7);},function(){const _0x5dfb6a=_0x17188a;console['log'](_0x5dfb6a('0x16b8'));});}let _0x55dc24=!![],_0x3d2195=0x1;_0x31038d[_0x4c6748('0x186d')](_0x4c6748('0x1e1d'),function(_0x10fa5b,_0x52a219){const _0x40465a=_0x4c6748;_0x55dc24?_0x2ad825(function(){_0x55dc24=![];}):(!_0x52a219&&(_0x3d2195=_0x19f96e[_0x40465a('0x23a2')][_0x40465a('0xdf8')]),_0x10fa5b!==_0x52a219&&(_0x19f96e[_0x40465a('0x23a2')][_0x40465a('0xdf8')]=0x1),!_0x10fa5b&&(_0x19f96e[_0x40465a('0x23a2')][_0x40465a('0xdf8')]=_0x3d2195),_0x19f96e[_0x40465a('0x8a5')]());});function _0x3a20c5(_0xb62bd7){const _0x1f0c7b=_0x4c6748;_0x19f96e[_0x1f0c7b('0x1ce6')]=_0xb62bd7||{'count':0x0,'rows':[]};}function _0x29e8bd(){const _0x52772e=_0x4c6748;_0x19f96e[_0x52772e('0x23a2')]['offset']=(_0x19f96e[_0x52772e('0x23a2')][_0x52772e('0xdf8')]-0x1)*_0x19f96e[_0x52772e('0x23a2')]['limit'],_0x9611d6[_0x52772e('0xca1')](_0x52772e('0x20c2'))?_0x19f96e['promise']=_0x241165[_0x52772e('0x270')]['get'](_0x19f96e[_0x52772e('0x23a2')],_0x3a20c5)[_0x52772e('0xe53')]:(_0x19f96e[_0x52772e('0x23a2')]['id']=_0x19f96e[_0x52772e('0x2a')]['id'],_0x19f96e[_0x52772e('0x23a2')][_0x52772e('0x1aa')]=_0x52772e('0x198f'),_0x19f96e[_0x52772e('0x1883')]=_0x241165['userProfile'][_0x52772e('0x241d')](_0x19f96e[_0x52772e('0x23a2')],_0x3a20c5)[_0x52772e('0xe53')]);}function _0xafb7ec(_0x48656a,_0x4175df){const _0x1548dc=_0x4c6748;_0x38f241[_0x1548dc('0x1d4')]({'controller':_0x1548dc('0x17b2'),'controllerAs':'vm','templateUrl':_0x23366e,'parent':angular[_0x1548dc('0x1fcc')](_0x42be03[_0x1548dc('0x18e5')]),'targetEvent':_0x48656a,'clickOutsideToClose':!![],'locals':{'tag':_0x4175df,'tags':_0x19f96e[_0x1548dc('0x1ce6')]['rows'],'license':_0x19f96e[_0x1548dc('0xace')],'setting':_0x19f96e['setting'],'crudPermissions':_0x19f96e[_0x1548dc('0x1134')]}});}function _0xed58e3(_0x3d052c){const _0x5ace96=_0x4c6748;_0x241165[_0x5ace96('0x270')][_0x5ace96('0xd7e')]({'id':_0x3d052c['id']})[_0x5ace96('0xe53')][_0x5ace96('0x683')](function(){const _0x6e4944=_0x5ace96;_0x2e3ca0()[_0x6e4944('0x3ec')](_0x19f96e['tags']['rows'],{'id':_0x3d052c['id']}),_0x19f96e['tags'][_0x6e4944('0x50d')]-=0x1,!_0x19f96e[_0x6e4944('0x1ce6')][_0x6e4944('0xf5d')]['length']&&_0x19f96e[_0x6e4944('0x8a5')](),_0x170736[_0x6e4944('0x53')]({'title':_0x2e3ca0()[_0x6e4944('0x1e03')](_0x6e4944('0x1e'))+_0x6e4944('0xbfc'),'msg':_0x3d052c[_0x6e4944('0x60a')]?_0x3d052c['name']+_0x6e4944('0x194d'):''});})[_0x5ace96('0x130a')](function(_0x4244fe){const _0x483119=_0x5ace96;if(_0x4244fe[_0x483119('0x5a5')]&&_0x4244fe[_0x483119('0x5a5')]['errors']&&_0x4244fe[_0x483119('0x5a5')][_0x483119('0x17f')]['length']){_0x19f96e[_0x483119('0x17f')]=_0x4244fe[_0x483119('0x5a5')][_0x483119('0x17f')]||[{'message':_0x4244fe[_0x483119('0x1ff0')](),'type':_0x483119('0x825')}];for(let _0xfec3e2=0x0;_0xfec3e2<_0x4244fe[_0x483119('0x5a5')][_0x483119('0x17f')]['length'];_0xfec3e2++){_0x170736[_0x483119('0x52a')]({'title':_0x4244fe[_0x483119('0x5a5')]['errors'][_0xfec3e2][_0x483119('0xcf0')],'msg':_0x4244fe[_0x483119('0x5a5')]['errors'][_0xfec3e2][_0x483119('0x8c2')]});}}else _0x170736[_0x483119('0x52a')]({'title':_0x4244fe[_0x483119('0x13ee')]?_0x483119('0x2168')+_0x4244fe[_0x483119('0x13ee')]+_0x483119('0xbf6')+_0x4244fe[_0x483119('0x24a9')]:_0x483119('0x825'),'msg':_0x4244fe[_0x483119('0x5a5')]?JSON[_0x483119('0x258a')](_0x4244fe[_0x483119('0x5a5')][_0x483119('0x8c2')]):_0x4244fe['message']||_0x4244fe[_0x483119('0x1ff0')]()});});}function _0x278018(){const _0x514381=_0x4c6748,_0x331fc2=angular[_0x514381('0x1a86')](_0x19f96e[_0x514381('0x2100')]);return _0x19f96e['selectedTags']=[],_0x331fc2;}function _0x5ac588(_0x417bd5){const _0x1c5cd6=_0x4c6748,_0x491621=_0x38f241[_0x1c5cd6('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20tags?')[_0x1c5cd6('0x26e3')](_0x1c5cd6('0xed5')+_0x19f96e[_0x1c5cd6('0x2100')][_0x1c5cd6('0x1564')]+_0x1c5cd6('0x93c')+_0x1c5cd6('0x1ee7'))[_0x1c5cd6('0x1040')](_0x1c5cd6('0x1a51'))[_0x1c5cd6('0xe42')](_0x417bd5)['ok']('OK')['cancel']('CANCEL');_0x38f241[_0x1c5cd6('0x1d4')](_0x491621)[_0x1c5cd6('0x683')](function(){const _0x3bc38f=_0x1c5cd6;_0x19f96e[_0x3bc38f('0x2100')][_0x3bc38f('0x1299')](function(_0x36ba6c){_0xed58e3(_0x36ba6c);}),_0x19f96e['selectedTags']=[];});}function _0x40e4dd(){const _0x20c93d=_0x4c6748;_0x19f96e[_0x20c93d('0x2100')]=[];}function _0x1b9082(){const _0x2be909=_0x4c6748;_0x19f96e[_0x2be909('0x2100')]=_0x19f96e['tags']['rows'];}}const _0xb144e8=_0x50e0dc;_0x2e703f['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x84b'),'template',_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),'crudPermissions'];function _0x2e703f(_0x12de8c,_0x2fcd6d,_0x3de420,_0x115b85,_0x48b1ec,_0x52cbe0,_0x2ba2dd,_0x30a012,_0x5999d6,_0x3e21ee,_0x58d3b5,_0x5a24d4,_0x21fce8,_0x108e91){const _0x31daa1=_0x189033,_0x1f200f=this;_0x1f200f[_0x31daa1('0x11ed')]=_0x58d3b5[_0x31daa1('0x20b2')](),_0x1f200f['errors']=[],_0x1f200f[_0x31daa1('0x260a')]=_0x21fce8,_0x1f200f[_0x31daa1('0xace')]=_0x5a24d4,_0x1f200f['crudPermissions']=_0x108e91,_0x1f200f['hasModulePermissions']={},_0x1f200f[_0x31daa1('0x19b2')]=_0x1f200f[_0x31daa1('0x260a')]&&_0x1f200f[_0x31daa1('0x260a')][_0x31daa1('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1f200f['title']='TOOLS.EDIT_TEMPLATE',_0x1f200f[_0x31daa1('0x1cc6')]=angular[_0x31daa1('0x1a86')](_0x5999d6),_0x1f200f[_0x31daa1('0x84b')]=_0x30a012,_0x1f200f[_0x31daa1('0x17ac')]=![];!_0x1f200f['template']&&(_0x1f200f[_0x31daa1('0x1cc6')]={},_0x1f200f[_0x31daa1('0xf28')]=_0x31daa1('0x1bc7'),_0x1f200f[_0x31daa1('0x17ac')]=!![]);_0x1f200f[_0x31daa1('0xaa8')]=_0x3e2c1e,_0x1f200f['saveTemplate']=_0x53fb58,_0x1f200f[_0x31daa1('0x18a3')]=_0x17b633,_0x1f200f['getDateFromString']=_0x4611c0,_0x1f200f[_0x31daa1('0xf82')]=_0x4c5c9d;function _0x3e2c1e(){const _0x39b7a5=_0x31daa1;_0x1f200f['errors']=[],_0x3e21ee[_0x39b7a5('0x1cc6')]['save'](_0x1f200f[_0x39b7a5('0x1cc6')])[_0x39b7a5('0xe53')]['then'](function(_0x5eb493){const _0x47224e=_0x39b7a5;_0x1f200f['templates'][_0x47224e('0x1167')](_0x5eb493[_0x47224e('0x24e1')]()),_0x2ba2dd[_0x47224e('0x53')]({'title':'Template\x20properly\x20created','msg':_0x1f200f[_0x47224e('0x1cc6')][_0x47224e('0x60a')]?_0x1f200f['template'][_0x47224e('0x60a')]+_0x47224e('0x14b5'):''}),_0x4c5c9d(_0x5eb493);})[_0x39b7a5('0x130a')](function(_0x280a4d){const _0x30628a=_0x39b7a5;if(_0x280a4d[_0x30628a('0x5a5')]&&_0x280a4d[_0x30628a('0x5a5')][_0x30628a('0x17f')]&&_0x280a4d[_0x30628a('0x5a5')][_0x30628a('0x17f')][_0x30628a('0x1564')]){_0x1f200f[_0x30628a('0x17f')]=_0x280a4d[_0x30628a('0x5a5')][_0x30628a('0x17f')]||[{'message':_0x280a4d['toString'](),'type':_0x30628a('0x2ce')}];for(let _0x282eba=0x0;_0x282eba<_0x280a4d[_0x30628a('0x5a5')]['errors'][_0x30628a('0x1564')];_0x282eba+=0x1){_0x2ba2dd['error']({'title':_0x280a4d[_0x30628a('0x5a5')][_0x30628a('0x17f')][_0x282eba][_0x30628a('0xcf0')],'msg':_0x280a4d['data'][_0x30628a('0x17f')][_0x282eba][_0x30628a('0x8c2')]});}}else _0x2ba2dd[_0x30628a('0x52a')]({'title':_0x280a4d[_0x30628a('0x13ee')]?'API:'+_0x280a4d[_0x30628a('0x13ee')]+'\x20-\x20'+_0x280a4d[_0x30628a('0x24a9')]:'api.template.save','msg':_0x280a4d[_0x30628a('0x5a5')]?JSON['stringify'](_0x280a4d[_0x30628a('0x5a5')][_0x30628a('0x8c2')]):_0x280a4d[_0x30628a('0x1ff0')]()});});}function _0x53fb58(){const _0x17dca2=_0x31daa1;_0x1f200f[_0x17dca2('0x17f')]=[],_0x3e21ee['template'][_0x17dca2('0x2480')]({'id':_0x1f200f[_0x17dca2('0x1cc6')]['id']},_0x1f200f['template'])[_0x17dca2('0xe53')][_0x17dca2('0x683')](function(_0x4289f6){const _0x2cedf8=_0x17dca2,_0x8d8c3e=_0x2e3ca0()[_0x2cedf8('0x1c07')](_0x1f200f[_0x2cedf8('0x84b')],{'id':_0x4289f6['id']});_0x8d8c3e&&_0x2e3ca0()[_0x2cedf8('0xf22')](_0x8d8c3e,_0x2e3ca0()[_0x2cedf8('0x24d0')](_0x4289f6[_0x2cedf8('0x24e1')](),_0x2e3ca0()[_0x2cedf8('0x55e')](_0x8d8c3e))),_0x2ba2dd[_0x2cedf8('0x53')]({'title':_0x2cedf8('0x203a'),'msg':_0x1f200f[_0x2cedf8('0x1cc6')]['name']?_0x1f200f[_0x2cedf8('0x1cc6')][_0x2cedf8('0x60a')]+_0x2cedf8('0xf59'):''}),_0x4c5c9d(_0x4289f6);})['catch'](function(_0x2accc9){const _0x46a95a=_0x17dca2;if(_0x2accc9[_0x46a95a('0x5a5')]&&_0x2accc9[_0x46a95a('0x5a5')][_0x46a95a('0x17f')]&&_0x2accc9[_0x46a95a('0x5a5')][_0x46a95a('0x17f')]['length']){_0x1f200f[_0x46a95a('0x17f')]=_0x2accc9[_0x46a95a('0x5a5')][_0x46a95a('0x17f')]||[{'message':_0x2accc9[_0x46a95a('0x1ff0')](),'type':_0x46a95a('0x223b')}];for(let _0x119005=0x0;_0x119005<_0x2accc9[_0x46a95a('0x5a5')][_0x46a95a('0x17f')][_0x46a95a('0x1564')];_0x119005++){_0x2ba2dd[_0x46a95a('0x52a')]({'title':_0x2accc9[_0x46a95a('0x5a5')][_0x46a95a('0x17f')][_0x119005][_0x46a95a('0xcf0')],'msg':_0x2accc9[_0x46a95a('0x5a5')][_0x46a95a('0x17f')][_0x119005][_0x46a95a('0x8c2')]});}}else _0x2ba2dd[_0x46a95a('0x52a')]({'title':_0x2accc9[_0x46a95a('0x13ee')]?'API:'+_0x2accc9[_0x46a95a('0x13ee')]+_0x46a95a('0xbf6')+_0x2accc9[_0x46a95a('0x24a9')]:_0x46a95a('0x223b'),'msg':_0x2accc9[_0x46a95a('0x5a5')]?JSON[_0x46a95a('0x258a')](_0x2accc9[_0x46a95a('0x5a5')]['message']):_0x2accc9[_0x46a95a('0x1ff0')]()});});}function _0x17b633(_0x4633e0){const _0xb9b34f=_0x31daa1;_0x1f200f['errors']=[];const _0x15ed9d=_0x115b85[_0xb9b34f('0x1c6f')]()[_0xb9b34f('0xf28')](_0xb9b34f('0x4d'))['content'](_0xb9b34f('0x1797'))['ariaLabel'](_0xb9b34f('0x325'))['ok'](_0xb9b34f('0x2307'))['cancel'](_0xb9b34f('0x253a'))[_0xb9b34f('0xe42')](_0x4633e0);_0x115b85['show'](_0x15ed9d)[_0xb9b34f('0x683')](function(){const _0x1f69af=_0xb9b34f;_0x3e21ee['template'][_0x1f69af('0xd7e')]({'id':_0x1f200f[_0x1f69af('0x1cc6')]['id']})[_0x1f69af('0xe53')][_0x1f69af('0x683')](function(){const _0x3bfb32=_0x1f69af;_0x2e3ca0()[_0x3bfb32('0x3ec')](_0x1f200f[_0x3bfb32('0x84b')],{'id':_0x1f200f[_0x3bfb32('0x1cc6')]['id']}),_0x2ba2dd[_0x3bfb32('0x53')]({'title':_0x3bfb32('0x2184'),'msg':(_0x1f200f[_0x3bfb32('0x1cc6')]['name']||_0x3bfb32('0x1cc6'))+_0x3bfb32('0x194d')}),_0x4c5c9d(_0x1f200f['template']);})[_0x1f69af('0x130a')](function(_0x42a66c){const _0x8b640c=_0x1f69af;if(_0x42a66c[_0x8b640c('0x5a5')]&&_0x42a66c[_0x8b640c('0x5a5')][_0x8b640c('0x17f')]&&_0x42a66c['data'][_0x8b640c('0x17f')][_0x8b640c('0x1564')]){_0x1f200f[_0x8b640c('0x17f')]=_0x42a66c[_0x8b640c('0x5a5')][_0x8b640c('0x17f')]||[{'message':_0x42a66c['toString'](),'type':_0x8b640c('0x314')}];for(let _0x39ba84=0x0;_0x39ba84<_0x42a66c[_0x8b640c('0x5a5')][_0x8b640c('0x17f')][_0x8b640c('0x1564')];_0x39ba84++){_0x2ba2dd[_0x8b640c('0x52a')]({'title':_0x42a66c['data'][_0x8b640c('0x17f')][_0x39ba84]['type'],'msg':_0x42a66c['data']['errors'][_0x39ba84][_0x8b640c('0x8c2')]});}}else _0x2ba2dd['error']({'title':_0x42a66c[_0x8b640c('0x13ee')]?_0x8b640c('0x2168')+_0x42a66c[_0x8b640c('0x13ee')]+_0x8b640c('0xbf6')+_0x42a66c[_0x8b640c('0x24a9')]:'api.template.delete','msg':_0x42a66c[_0x8b640c('0x5a5')]?JSON['stringify'](_0x42a66c[_0x8b640c('0x5a5')]['message']):_0x42a66c[_0x8b640c('0x8c2')]||_0x42a66c[_0x8b640c('0x1ff0')]()});});},function(){});}function _0x4611c0(_0x102a5c){return _0x102a5c===null?undefined:new Date(_0x102a5c);}function _0x4c5c9d(_0x114e32){const _0xf3c06=_0x31daa1;_0x115b85[_0xf3c06('0x1715')](_0x114e32);}}const _0x4eadf6=_0x2e703f,_0x5c17ae=_0x180212['p']+_0x189033('0x19bf');_0x15d5b2[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout','$translate',_0x189033('0x84b'),_0x189033('0x2a'),_0x189033('0x22df'),'api',_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x15d5b2(_0x5c5555,_0x1136f1,_0x1493d1,_0x2419b1,_0x10fc65,_0x3c9255,_0x583dc6,_0x1a3281,_0x5562e3,_0x3311cf,_0x302649,_0x568a05,_0x106e5e,_0x387310,_0xa57260,_0x208b92,_0x2e7b33){const _0x34a308=_0x189033,_0x4b6b06=this;_0x4b6b06[_0x34a308('0xace')]=_0x208b92,_0x4b6b06[_0x34a308('0x260a')]=_0x2e7b33,_0x4b6b06[_0x34a308('0x11ed')]=_0xa57260[_0x34a308('0x20b2')](),_0x4b6b06[_0x34a308('0x84b')]=_0x5562e3||{'count':0x0,'rows':[]},_0x4b6b06[_0x34a308('0x2a')]=_0x3311cf,_0x4b6b06[_0x34a308('0x22df')]=_0x302649&&_0x302649['count']==0x1?_0x302649['rows'][0x0]:null,_0x4b6b06[_0x34a308('0x1134')]=_0xa57260[_0x34a308('0x142a')](_0x4b6b06[_0x34a308('0x22df')]?_0x4b6b06[_0x34a308('0x22df')][_0x34a308('0x1134')]:null),_0x4b6b06[_0x34a308('0x5c4')]='templates',_0x4b6b06['listOrder']='',_0x4b6b06[_0x34a308('0x1ce2')]=null,_0x4b6b06['selectedTemplates']=[],_0x4b6b06['query']={'fields':_0x34a308('0x755'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x4b6b06['editdialog']=_0x130859,_0x4b6b06[_0x34a308('0x194f')]=_0x2ffd4a,_0x4b6b06[_0x34a308('0x53')]=_0x19c8ca,_0x4b6b06[_0x34a308('0xe7d')]=_0x55ddfa,_0x4b6b06[_0x34a308('0x7f1')]=_0x53bc60,_0x4b6b06[_0x34a308('0x18a3')]=_0x5236b0,_0x4b6b06[_0x34a308('0x32e')]=_0x51e7a9,_0x4b6b06[_0x34a308('0x2295')]=_0x357fb3,_0x4b6b06[_0x34a308('0xa6b')]=_0x126144,_0x4b6b06[_0x34a308('0x2618')]=_0x3c1eb3;function _0x130859(_0x30a8d6,_0x2a9ab2){const _0x5b4352=_0x34a308;_0x10fc65[_0x5b4352('0x1d4')]({'controller':_0x5b4352('0x182a'),'controllerAs':'vm','templateUrl':_0x5c17ae,'parent':angular[_0x5b4352('0x1fcc')](_0x3c9255[_0x5b4352('0x18e5')]),'targetEvent':_0x2a9ab2,'clickOutsideToClose':!![],'locals':{'template':_0x30a8d6,'templates':_0x4b6b06[_0x5b4352('0x84b')]['rows'],'license':_0x4b6b06['license'],'setting':null,'crudPermissions':_0x4b6b06[_0x5b4352('0x1134')]}});}function _0x2ffd4a(_0x75fb0c,_0x115ca6){const _0x3cb836=_0x34a308,_0x50b8b8=_0x10fc65['confirm']()[_0x3cb836('0xf28')](_0x3cb836('0x1b01')+_0x2e3ca0()[_0x3cb836('0x1e03')]('template')+'?')[_0x3cb836('0x26e3')](_0x3cb836('0xed5')+(_0x75fb0c[_0x3cb836('0x60a')]||_0x3cb836('0x1cc6'))+_0x3cb836('0x20f1')+'\x20will\x20be\x20deleted.')[_0x3cb836('0x1040')](_0x3cb836('0x6c'))[_0x3cb836('0xe42')](_0x115ca6)['ok']('OK')[_0x3cb836('0x19fb')](_0x3cb836('0x16b8'));_0x10fc65[_0x3cb836('0x1d4')](_0x50b8b8)[_0x3cb836('0x683')](function(){_0x5236b0(_0x75fb0c);},function(){const _0xc89fdf=_0x3cb836;console[_0xc89fdf('0x1b2b')]('CANCEL');});}let _0x415f40=!![],_0x4ee2b9=0x1;_0x5c5555['$watch'](_0x34a308('0x1e1d'),function(_0x6d7a7b,_0x22e152){const _0x343aa8=_0x34a308;_0x415f40?_0x583dc6(function(){_0x415f40=![];}):(!_0x22e152&&(_0x4ee2b9=_0x4b6b06[_0x343aa8('0x23a2')][_0x343aa8('0xdf8')]),_0x6d7a7b!==_0x22e152&&(_0x4b6b06[_0x343aa8('0x23a2')][_0x343aa8('0xdf8')]=0x1),!_0x6d7a7b&&(_0x4b6b06['query']['page']=_0x4ee2b9),_0x4b6b06[_0x343aa8('0xe7d')]());});function _0x19c8ca(_0x2c18b5){_0x4b6b06['templates']=_0x2c18b5||{'count':0x0,'rows':[]};}function _0x55ddfa(){const _0xc35aed=_0x34a308;_0x4b6b06[_0xc35aed('0x23a2')][_0xc35aed('0x1cc8')]=(_0x4b6b06[_0xc35aed('0x23a2')][_0xc35aed('0xdf8')]-0x1)*_0x4b6b06[_0xc35aed('0x23a2')][_0xc35aed('0x6f0')],_0xa57260[_0xc35aed('0xca1')](_0xc35aed('0x20c2'))?_0x4b6b06[_0xc35aed('0x1883')]=_0x568a05[_0xc35aed('0x1cc6')][_0xc35aed('0x1e6e')](_0x4b6b06[_0xc35aed('0x23a2')],_0x19c8ca)[_0xc35aed('0xe53')]:(_0x4b6b06[_0xc35aed('0x23a2')]['id']=_0x4b6b06['userProfile']['id'],_0x4b6b06[_0xc35aed('0x23a2')][_0xc35aed('0x1aa')]=_0xc35aed('0x161d'),_0x4b6b06['promise']=_0x568a05[_0xc35aed('0x2a')]['getResources'](_0x4b6b06['query'],_0x19c8ca)[_0xc35aed('0xe53')]);}function _0x53bc60(_0x3cecd2,_0x4ac3a1){const _0x44d632=_0x34a308;_0x10fc65['show']({'controller':_0x44d632('0x182a'),'controllerAs':'vm','templateUrl':_0x5c17ae,'parent':angular[_0x44d632('0x1fcc')](_0x3c9255[_0x44d632('0x18e5')]),'targetEvent':_0x3cecd2,'clickOutsideToClose':!![],'locals':{'template':_0x4ac3a1,'templates':_0x4b6b06[_0x44d632('0x84b')][_0x44d632('0xf5d')],'license':_0x4b6b06['license'],'setting':_0x4b6b06[_0x44d632('0x260a')],'crudPermissions':_0x4b6b06[_0x44d632('0x1134')]}});}function _0x5236b0(_0x540b3b){const _0x469f67=_0x34a308;_0x568a05[_0x469f67('0x1cc6')][_0x469f67('0xd7e')]({'id':_0x540b3b['id']})[_0x469f67('0xe53')]['then'](function(){const _0x46a093=_0x469f67;_0x2e3ca0()[_0x46a093('0x3ec')](_0x4b6b06['templates'][_0x46a093('0xf5d')],{'id':_0x540b3b['id']}),_0x4b6b06['templates'][_0x46a093('0x50d')]-=0x1,!_0x4b6b06['templates'][_0x46a093('0xf5d')][_0x46a093('0x1564')]&&_0x4b6b06['getTemplates'](),_0x387310[_0x46a093('0x53')]({'title':_0x2e3ca0()['startCase'](_0x46a093('0xf18'))+'\x20deleted!','msg':_0x540b3b[_0x46a093('0x60a')]?_0x540b3b[_0x46a093('0x60a')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x2eeb30){const _0x6216c5=_0x469f67;if(_0x2eeb30['data']&&_0x2eeb30[_0x6216c5('0x5a5')][_0x6216c5('0x17f')]&&_0x2eeb30[_0x6216c5('0x5a5')][_0x6216c5('0x17f')][_0x6216c5('0x1564')]){_0x4b6b06[_0x6216c5('0x17f')]=_0x2eeb30[_0x6216c5('0x5a5')][_0x6216c5('0x17f')]||[{'message':_0x2eeb30[_0x6216c5('0x1ff0')](),'type':_0x6216c5('0x21cd')}];for(let _0x3733e8=0x0;_0x3733e8<_0x2eeb30[_0x6216c5('0x5a5')]['errors']['length'];_0x3733e8++){_0x387310[_0x6216c5('0x52a')]({'title':_0x2eeb30[_0x6216c5('0x5a5')][_0x6216c5('0x17f')][_0x3733e8][_0x6216c5('0xcf0')],'msg':_0x2eeb30[_0x6216c5('0x5a5')][_0x6216c5('0x17f')][_0x3733e8][_0x6216c5('0x8c2')]});}}else _0x387310[_0x6216c5('0x52a')]({'title':_0x2eeb30[_0x6216c5('0x13ee')]?_0x6216c5('0x2168')+_0x2eeb30['status']+_0x6216c5('0xbf6')+_0x2eeb30[_0x6216c5('0x24a9')]:_0x6216c5('0x21cd'),'msg':_0x2eeb30[_0x6216c5('0x5a5')]?JSON[_0x6216c5('0x258a')](_0x2eeb30[_0x6216c5('0x5a5')][_0x6216c5('0x8c2')]):_0x2eeb30[_0x6216c5('0x8c2')]||_0x2eeb30['toString']()});});}function _0x51e7a9(){const _0xec76a1=_0x34a308,_0x1de67a=angular[_0xec76a1('0x1a86')](_0x4b6b06[_0xec76a1('0xf60')]);return _0x4b6b06['selectedTemplates']=[],_0x1de67a;}function _0x357fb3(_0x2ca903){const _0x43845f=_0x34a308,_0x2f4116=_0x10fc65['confirm']()[_0x43845f('0xf28')](_0x43845f('0x1673'))[_0x43845f('0x26e3')](_0x43845f('0xed5')+_0x4b6b06[_0x43845f('0xf60')][_0x43845f('0x1564')]+_0x43845f('0x93c')+_0x43845f('0x1ee7'))[_0x43845f('0x1040')](_0x43845f('0xfa9'))['targetEvent'](_0x2ca903)['ok']('OK')[_0x43845f('0x19fb')](_0x43845f('0x16b8'));_0x10fc65[_0x43845f('0x1d4')](_0x2f4116)['then'](function(){const _0x27cb1f=_0x43845f;_0x4b6b06['selectedTemplates'][_0x27cb1f('0x1299')](function(_0x1fe908){_0x5236b0(_0x1fe908);}),_0x4b6b06[_0x27cb1f('0xf60')]=[];});}function _0x126144(){const _0x3c9442=_0x34a308;_0x4b6b06[_0x3c9442('0xf60')]=[];}function _0x3c1eb3(){const _0x149631=_0x34a308;_0x4b6b06[_0x149631('0xf60')]=_0x4b6b06['templates']['rows'];}}const _0x341874=_0x15d5b2;_0x518b94[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty',_0x189033('0x20fe'),'trunk',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x518b94(_0x5246b7,_0x4b1759,_0x1923bd,_0x193347,_0x4dc928,_0x20eee8,_0x33ad7d,_0x381d0f,_0x48787c,_0xce3c4b,_0x126ece,_0x1b22b6,_0x4d5c67,_0x176c8d){const _0x323588=_0x189033,_0x5df615=this;_0x5df615['currentUser']=_0x126ece[_0x323588('0x20b2')](),_0x5df615[_0x323588('0x17f')]=[],_0x5df615['setting']=_0x4d5c67,_0x5df615['license']=_0x1b22b6,_0x5df615[_0x323588('0x1134')]=_0x176c8d,_0x5df615[_0x323588('0x258d')]={},_0x5df615[_0x323588('0x19b2')]=_0x5df615[_0x323588('0x260a')]&&_0x5df615[_0x323588('0x260a')][_0x323588('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5df615[_0x323588('0xf28')]='TOOLS.EDIT_TRUNK',_0x5df615[_0x323588('0x1a93')]=angular[_0x323588('0x1a86')](_0x48787c),_0x5df615[_0x323588('0x20fe')]=_0x381d0f,_0x5df615['newTrunk']=![];!_0x5df615[_0x323588('0x1a93')]&&(_0x5df615[_0x323588('0x1a93')]={'active':!![],'type':'friend','dtmfmode':_0x323588('0x3c0'),'qualify':_0x323588('0x7cd'),'t38pt_udptl':'no'},_0x5df615[_0x323588('0xf28')]=_0x323588('0x2279'),_0x5df615[_0x323588('0x2794')]=!![]);_0x5df615['addNewTrunk']=_0x2cb35f,_0x5df615[_0x323588('0x1f49')]=_0x30f7cf,_0x5df615['deleteTrunk']=_0x13846e,_0x5df615[_0x323588('0x16b3')]=_0x4e6295,_0x5df615[_0x323588('0xf82')]=_0x4d14ee;function _0x2cb35f(){const _0x732edd=_0x323588;_0x5df615[_0x732edd('0x17f')]=[],_0xce3c4b[_0x732edd('0x1a93')][_0x732edd('0xb0a')](_0x5df615[_0x732edd('0x1a93')])['$promise'][_0x732edd('0x683')](function(_0x328fec){const _0x599076=_0x732edd;_0x5df615['trunks']['unshift'](_0x328fec[_0x599076('0x24e1')]()),_0x33ad7d[_0x599076('0x53')]({'title':_0x599076('0x78f'),'msg':_0x5df615[_0x599076('0x1a93')][_0x599076('0x60a')]?_0x5df615[_0x599076('0x1a93')]['name']+_0x599076('0x14b5'):''}),_0x4d14ee(_0x328fec);})[_0x732edd('0x130a')](function(_0x5ac010){const _0x4dec66=_0x732edd;if(_0x5ac010[_0x4dec66('0x5a5')]&&_0x5ac010[_0x4dec66('0x5a5')][_0x4dec66('0x17f')]&&_0x5ac010['data'][_0x4dec66('0x17f')][_0x4dec66('0x1564')]){_0x5df615[_0x4dec66('0x17f')]=_0x5ac010[_0x4dec66('0x5a5')][_0x4dec66('0x17f')]||[{'message':_0x5ac010[_0x4dec66('0x1ff0')](),'type':_0x4dec66('0x24cd')}];for(let _0x5b75f8=0x0;_0x5b75f8<_0x5ac010[_0x4dec66('0x5a5')][_0x4dec66('0x17f')][_0x4dec66('0x1564')];_0x5b75f8+=0x1){_0x33ad7d[_0x4dec66('0x52a')]({'title':_0x5ac010['data'][_0x4dec66('0x17f')][_0x5b75f8][_0x4dec66('0xcf0')],'msg':_0x5ac010[_0x4dec66('0x5a5')][_0x4dec66('0x17f')][_0x5b75f8][_0x4dec66('0x8c2')]});}}else _0x33ad7d[_0x4dec66('0x52a')]({'title':_0x5ac010[_0x4dec66('0x13ee')]?_0x4dec66('0x2168')+_0x5ac010[_0x4dec66('0x13ee')]+'\x20-\x20'+_0x5ac010[_0x4dec66('0x24a9')]:_0x4dec66('0x24cd'),'msg':_0x5ac010[_0x4dec66('0x5a5')]?JSON[_0x4dec66('0x258a')](_0x5ac010[_0x4dec66('0x5a5')][_0x4dec66('0x8c2')]):_0x5ac010[_0x4dec66('0x1ff0')]()});});}function _0x30f7cf(){const _0x531c50=_0x323588;_0x5df615[_0x531c50('0x17f')]=[],_0xce3c4b[_0x531c50('0x1a93')][_0x531c50('0x2480')]({'id':_0x5df615[_0x531c50('0x1a93')]['id']},_0x5df615[_0x531c50('0x1a93')])[_0x531c50('0xe53')][_0x531c50('0x683')](function(_0x2854e6){const _0x30383b=_0x531c50,_0x2e5f52=_0x2e3ca0()[_0x30383b('0x1c07')](_0x5df615[_0x30383b('0x20fe')],{'id':_0x2854e6['id']});_0x2e5f52&&_0x2e3ca0()[_0x30383b('0xf22')](_0x2e5f52,_0x2e3ca0()[_0x30383b('0x24d0')](_0x2854e6[_0x30383b('0x24e1')](),_0x2e3ca0()[_0x30383b('0x55e')](_0x2e5f52))),_0x33ad7d[_0x30383b('0x53')]({'title':_0x30383b('0x20f'),'msg':_0x5df615[_0x30383b('0x1a93')][_0x30383b('0x60a')]?_0x5df615[_0x30383b('0x1a93')][_0x30383b('0x60a')]+_0x30383b('0xf59'):''}),_0x4d14ee(_0x2854e6);})['catch'](function(_0x485f86){const _0x151fa0=_0x531c50;if(_0x485f86['data']&&_0x485f86[_0x151fa0('0x5a5')][_0x151fa0('0x17f')]&&_0x485f86[_0x151fa0('0x5a5')]['errors'][_0x151fa0('0x1564')]){_0x5df615[_0x151fa0('0x17f')]=_0x485f86[_0x151fa0('0x5a5')][_0x151fa0('0x17f')]||[{'message':_0x485f86['toString'](),'type':_0x151fa0('0x1fe2')}];for(let _0x44dc20=0x0;_0x44dc20<_0x485f86[_0x151fa0('0x5a5')][_0x151fa0('0x17f')]['length'];_0x44dc20++){_0x33ad7d[_0x151fa0('0x52a')]({'title':_0x485f86['data'][_0x151fa0('0x17f')][_0x44dc20][_0x151fa0('0xcf0')],'msg':_0x485f86[_0x151fa0('0x5a5')][_0x151fa0('0x17f')][_0x44dc20][_0x151fa0('0x8c2')]});}}else _0x33ad7d[_0x151fa0('0x52a')]({'title':_0x485f86[_0x151fa0('0x13ee')]?'API:'+_0x485f86[_0x151fa0('0x13ee')]+_0x151fa0('0xbf6')+_0x485f86[_0x151fa0('0x24a9')]:_0x151fa0('0x1fe2'),'msg':_0x485f86['data']?JSON[_0x151fa0('0x258a')](_0x485f86[_0x151fa0('0x5a5')]['message']):_0x485f86[_0x151fa0('0x1ff0')]()});});}function _0x13846e(_0x3f7e76){const _0xa33f6a=_0x323588;_0x5df615['errors']=[];const _0x42b393=_0x193347['confirm']()[_0xa33f6a('0xf28')](_0xa33f6a('0x4d'))[_0xa33f6a('0xa6a')](_0xa33f6a('0x1e75'))[_0xa33f6a('0x1040')](_0xa33f6a('0xad1'))['ok'](_0xa33f6a('0x2307'))[_0xa33f6a('0x19fb')](_0xa33f6a('0x253a'))[_0xa33f6a('0xe42')](_0x3f7e76);_0x193347['show'](_0x42b393)['then'](function(){const _0x559ace=_0xa33f6a;_0xce3c4b[_0x559ace('0x1a93')]['delete']({'id':_0x5df615['trunk']['id']})[_0x559ace('0xe53')][_0x559ace('0x683')](function(){const _0x5179d2=_0x559ace;_0x2e3ca0()[_0x5179d2('0x3ec')](_0x5df615[_0x5179d2('0x20fe')],{'id':_0x5df615[_0x5179d2('0x1a93')]['id']}),_0x33ad7d['success']({'title':_0x5179d2('0x1475'),'msg':(_0x5df615[_0x5179d2('0x1a93')][_0x5179d2('0x60a')]||_0x5179d2('0x1a93'))+_0x5179d2('0x194d')}),_0x4d14ee(_0x5df615[_0x5179d2('0x1a93')]);})[_0x559ace('0x130a')](function(_0x3c9852){const _0x278c94=_0x559ace;if(_0x3c9852[_0x278c94('0x5a5')]&&_0x3c9852[_0x278c94('0x5a5')][_0x278c94('0x17f')]&&_0x3c9852[_0x278c94('0x5a5')][_0x278c94('0x17f')]['length']){_0x5df615['errors']=_0x3c9852['data'][_0x278c94('0x17f')]||[{'message':_0x3c9852[_0x278c94('0x1ff0')](),'type':_0x278c94('0x812')}];for(let _0x1722a4=0x0;_0x1722a4<_0x3c9852[_0x278c94('0x5a5')][_0x278c94('0x17f')]['length'];_0x1722a4++){_0x33ad7d[_0x278c94('0x52a')]({'title':_0x3c9852[_0x278c94('0x5a5')][_0x278c94('0x17f')][_0x1722a4]['type'],'msg':_0x3c9852[_0x278c94('0x5a5')][_0x278c94('0x17f')][_0x1722a4][_0x278c94('0x8c2')]});}}else _0x33ad7d[_0x278c94('0x52a')]({'title':_0x3c9852[_0x278c94('0x13ee')]?_0x278c94('0x2168')+_0x3c9852[_0x278c94('0x13ee')]+'\x20-\x20'+_0x3c9852[_0x278c94('0x24a9')]:_0x278c94('0x812'),'msg':_0x3c9852['data']?JSON[_0x278c94('0x258a')](_0x3c9852[_0x278c94('0x5a5')][_0x278c94('0x8c2')]):_0x3c9852['message']||_0x3c9852[_0x278c94('0x1ff0')]()});});},function(){});}function _0x4e6295(_0x11ebd8){return _0x11ebd8===null?undefined:new Date(_0x11ebd8);}function _0x4d14ee(_0x2e38ba){_0x193347['hide'](_0x2e38ba);}}const _0xd12883=_0x518b94;_0xdac673['$inject']=['$mdDialog',_0x189033('0x938'),_0x189033('0x1d70'),_0x189033('0x56b'),'trunk',_0x189033('0x20fe'),_0x189033('0x1d08')];function _0xdac673(_0x58098d,_0x2a2734,_0x5aed25,_0x10897c,_0x929f2f,_0x4927f8,_0xfcb8fc){const _0x1bae94=_0x189033,_0x59f27d=this;_0x59f27d[_0x1bae94('0x2794')]=!![],_0x59f27d[_0x1bae94('0x1a93')]=angular['copy'](_0x929f2f),_0x59f27d[_0x1bae94('0x20fe')]=_0x4927f8,_0x59f27d[_0x1bae94('0xf28')]=_0xfcb8fc[_0x1bae94('0x2728')](_0x1bae94('0x3ef'));_0x929f2f&&_0x929f2f[_0x1bae94('0x60a')]&&(_0x59f27d['title']+=':\x20'+_0x929f2f[_0x1bae94('0x60a')]);_0x59f27d[_0x1bae94('0x1a4b')]=_0xc1e1d,_0x59f27d[_0x1bae94('0xf82')]=_0x12bf85;function _0xc1e1d(){const _0x167597=_0x1bae94;return _0x10897c[_0x167597('0x1a93')][_0x167597('0x147f')]({'id':_0x929f2f['id']},_0x59f27d[_0x167597('0x1a93')])[_0x167597('0xe53')]['then'](function(_0x59c805){const _0x268a7a=_0x167597;_0x59f27d[_0x268a7a('0x20fe')][_0x268a7a('0x1167')](_0x59c805[_0x268a7a('0x24e1')]()),_0x5aed25[_0x268a7a('0x53')]({'title':_0x268a7a('0xeac'),'msg':_0x59f27d[_0x268a7a('0x1a93')]['name']?_0x59f27d[_0x268a7a('0x1a93')][_0x268a7a('0x60a')]+_0x268a7a('0x640'):''}),_0x2a2734['go'](_0x268a7a('0xc28'),{'id':_0x59c805['id']}),_0x12bf85(_0x59c805);})['catch'](function(_0x54dbd2){const _0x5648c3=_0x167597;if(_0x54dbd2[_0x5648c3('0x5a5')]&&_0x54dbd2[_0x5648c3('0x5a5')][_0x5648c3('0x17f')]&&_0x54dbd2[_0x5648c3('0x5a5')]['errors'][_0x5648c3('0x1564')]){_0x59f27d['errors']=_0x54dbd2[_0x5648c3('0x5a5')][_0x5648c3('0x17f')]||[{'message':_0x54dbd2[_0x5648c3('0x1ff0')](),'type':_0x5648c3('0x1f72')}];for(let _0x4d53f4=0x0;_0x4d53f4<_0x54dbd2[_0x5648c3('0x5a5')]['errors'][_0x5648c3('0x1564')];_0x4d53f4+=0x1){_0x5aed25['error']({'title':_0x54dbd2[_0x5648c3('0x5a5')][_0x5648c3('0x17f')][_0x4d53f4][_0x5648c3('0xcf0')],'msg':_0x54dbd2[_0x5648c3('0x5a5')][_0x5648c3('0x17f')][_0x4d53f4][_0x5648c3('0x8c2')]});}}else _0x5aed25[_0x5648c3('0x52a')]({'title':_0x54dbd2[_0x5648c3('0x13ee')]?_0x5648c3('0x2168')+_0x54dbd2[_0x5648c3('0x13ee')]+'\x20-\x20'+_0x54dbd2['statusText']:'api.trunk.clone','msg':_0x54dbd2[_0x5648c3('0x5a5')]?JSON[_0x5648c3('0x258a')](_0x54dbd2[_0x5648c3('0x5a5')][_0x5648c3('0x8c2')]):_0x54dbd2[_0x5648c3('0x1ff0')]()});});}function _0x12bf85(_0x3c8d23){_0x58098d['hide'](_0x3c8d23);}}const _0x8498f4=_0xdac673,_0x30152f=_0x180212['p']+_0x189033('0x1692');_0x141981[_0x189033('0x14be')]=['$state',_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),'license',_0x189033('0x260a'),'api',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x1a93'),_0x189033('0x22df')];function _0x141981(_0x4387ca,_0x22e2ac,_0x2be6e6,_0x1f80e2,_0x533607,_0x1deed7,_0x1989ca,_0x536959,_0x1b111c,_0x3bcfc8,_0x4311ca,_0x1b013b){const _0x38dc56=_0x189033,_0xd7fb68=this;_0xd7fb68['currentUser']=_0x3bcfc8[_0x38dc56('0x20b2')](),_0xd7fb68[_0x38dc56('0xace')]=_0x1deed7,_0xd7fb68['setting']=_0x1989ca,_0xd7fb68[_0x38dc56('0x19b2')]=_0xd7fb68[_0x38dc56('0x260a')][_0x38dc56('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xd7fb68[_0x38dc56('0x1224')]=_0x22e2ac[_0x38dc56('0x173e')]()+_0x38dc56('0x20de')+_0x22e2ac['host'](),_0xd7fb68['trunk']=_0x4311ca||_0x4387ca[_0x38dc56('0x7f2')][_0x38dc56('0x1a93')]||{},_0xd7fb68[_0x38dc56('0x22df')]=_0x1b013b&&_0x1b013b[_0x38dc56('0x50d')]==0x1?_0x1b013b[_0x38dc56('0xf5d')][0x0]:null,_0xd7fb68[_0x38dc56('0x1134')]=_0x3bcfc8[_0x38dc56('0x142a')](_0xd7fb68[_0x38dc56('0x22df')]?_0xd7fb68[_0x38dc56('0x22df')][_0x38dc56('0x1134')]:null),_0xd7fb68[_0x38dc56('0x258d')]={},_0xd7fb68[_0x38dc56('0x517')]=_0x4387ca[_0x38dc56('0x7f2')][_0x38dc56('0x1904')]||0x0,_0xd7fb68[_0x38dc56('0x1a9f')]=_0xbb6bb5,_0xd7fb68['clonedialog']=_0x446e24,_0xd7fb68['alert']=_0x1b111c[_0x38dc56('0x2289')],_0xd7fb68[_0x38dc56('0x21bc')]=_0x48a293,_0xd7fb68['saveTrunk']=_0x3fe2ba,_0x3bcfc8['hasRole'](_0x38dc56('0x20c2'))?_0x536959[_0x38dc56('0x1e4d')][_0x38dc56('0x1e6e')]({'fields':_0x38dc56('0xa10'),'sort':'name'})['$promise'][_0x38dc56('0x683')](function(_0x1bc89f){const _0x5e022e=_0x38dc56;_0xd7fb68[_0x5e022e('0x1693')]=_0x1bc89f['rows']||[];})['catch'](function(_0x5b7053){const _0x3e4219=_0x38dc56;_0x1b111c[_0x3e4219('0x52a')]({'title':_0x5b7053[_0x3e4219('0x13ee')]?_0x3e4219('0x2168')+_0x5b7053['status']+_0x3e4219('0xbf6')+_0x5b7053['statusText']:_0x3e4219('0x1379'),'msg':_0x5b7053[_0x3e4219('0x5a5')]?JSON[_0x3e4219('0x258a')](_0x5b7053[_0x3e4219('0x5a5')]):_0x5b7053[_0x3e4219('0x1ff0')]()});}):_0x536959[_0x38dc56('0x1e4d')][_0x38dc56('0x1e6e')]({'fields':_0x38dc56('0xa10'),'sort':_0x38dc56('0x60a')})[_0x38dc56('0xe53')]['then'](function(_0x2a85b4){const _0x5be155=_0x38dc56;_0xd7fb68[_0x5be155('0x1693')]=_0x2a85b4[_0x5be155('0xf5d')]||[];})[_0x38dc56('0x683')](function(){const _0x175573=_0x38dc56;return _0x536959[_0x175573('0x22df')][_0x175573('0x1e6e')]({'userProfileId':_0xd7fb68['currentUser'][_0x175573('0x2f')],'sectionId':0x195})[_0x175573('0xe53')];})[_0x38dc56('0x683')](function(_0x41d31b){const _0x18870a=_0x38dc56,_0x225ff6=_0x41d31b&&_0x41d31b[_0x18870a('0xf5d')]?_0x41d31b[_0x18870a('0xf5d')][0x0]:null;if(!_0x225ff6)return _0x536959[_0x18870a('0x1e4d')]['get']({'fields':'id,name','sort':_0x18870a('0x60a'),'defaultEntry':0x1})[_0x18870a('0xe53')][_0x18870a('0x683')](function(_0x251e48){const _0x28247f=_0x18870a;_0xd7fb68[_0x28247f('0x1693')]=_0x251e48[_0x28247f('0xf5d')]||[];});else{if(!_0x225ff6[_0x18870a('0x170')])return _0x536959[_0x18870a('0xcf7')]['get']({'sectionId':_0x225ff6['id']})['$promise'][_0x18870a('0x683')](function(_0x7683ec){const _0x71e745=_0x18870a,_0x39196a=_0x2e3ca0()[_0x71e745('0x386')](_0x7683ec[_0x71e745('0xf5d')],function(_0x3d7924){const _0x565d08=_0x71e745;return _0x2e3ca0()['find'](_0xd7fb68[_0x565d08('0x1693')],{'id':_0x3d7924[_0x565d08('0x832')]});});let _0x5ee55a=null;_0xd7fb68[_0x71e745('0x1a93')]&&(_0x5ee55a=_0x2e3ca0()[_0x71e745('0x1c07')](_0xd7fb68[_0x71e745('0x1693')],{'name':_0xd7fb68[_0x71e745('0x1a93')][_0x71e745('0x22d3')]}));if(_0x5ee55a&&!_0x2e3ca0()[_0x71e745('0x7a2')](_0x39196a,['id',_0x5ee55a['id']])){const _0x22d14e=_0x2e3ca0()['find'](_0xd7fb68['contexts'],{'id':_0x5ee55a['id']});_0x22d14e['canSelect']=![],_0x39196a[_0x71e745('0x1fd0')](_0x22d14e);}_0xd7fb68[_0x71e745('0x1693')]=_0x39196a;});}})[_0x38dc56('0x130a')](function(_0x3b9149){const _0x578c73=_0x38dc56;_0x1b111c[_0x578c73('0x52a')]({'title':_0x3b9149[_0x578c73('0x13ee')]?_0x578c73('0x2168')+_0x3b9149[_0x578c73('0x13ee')]+'\x20-\x20'+_0x3b9149[_0x578c73('0x24a9')]:_0x578c73('0x1a60'),'msg':_0x3b9149['data']?JSON[_0x578c73('0x258a')](_0x3b9149[_0x578c73('0x5a5')]):_0x3b9149[_0x578c73('0x1ff0')]()});});function _0xbb6bb5(){const _0xa56a4c=_0x38dc56;if(_0x3bcfc8[_0xa56a4c('0xca1')]('admin'))_0x4387ca['go'](_0xa56a4c('0x19d8'),{});else return _0x536959['userProfileSection'][_0xa56a4c('0x1e6e')]({'userProfileId':_0x3bcfc8['getCurrentUser']()['userProfileId'],'sectionId':0x19b})[_0xa56a4c('0xe53')]['then'](function(_0x304514){const _0x4635f4=_0xa56a4c,_0x3a4ab9=_0x304514&&_0x304514[_0x4635f4('0xf5d')]?_0x304514[_0x4635f4('0xf5d')][0x0]:null;_0x3a4ab9&&_0x3a4ab9['enabled']?_0x4387ca['go'](_0x4635f4('0x19d8'),{}):_0x1b111c[_0x4635f4('0x2289')]({'title':_0x533607[_0x4635f4('0x2728')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x533607[_0x4635f4('0x2728')](_0x4635f4('0xdba'))});})['catch'](function(_0x1fe160){const _0x2658b2=_0xa56a4c;_0x1b111c[_0x2658b2('0x52a')]({'title':_0x1fe160[_0x2658b2('0x13ee')]?_0x2658b2('0x2168')+_0x1fe160[_0x2658b2('0x13ee')]+'\x20-\x20'+_0x1fe160[_0x2658b2('0x24a9')]:_0x2658b2('0xf2a'),'msg':_0x1fe160[_0x2658b2('0x13ee')]?JSON[_0x2658b2('0x258a')](_0x1fe160[_0x2658b2('0x5a5')]):_0x1fe160[_0x2658b2('0x1ff0')]()});});}function _0x446e24(_0x136151,_0x5e277c){const _0x569225=_0x38dc56;_0x2be6e6[_0x569225('0x1d4')]({'controller':_0x569225('0x2390'),'controllerAs':'vm','templateUrl':_0x30152f,'parent':angular[_0x569225('0x1fcc')](_0x1f80e2[_0x569225('0x18e5')]),'targetEvent':_0x5e277c,'clickOutsideToClose':!![],'locals':{'trunk':_0x136151,'trunks':_0xd7fb68[_0x569225('0x20fe')]?_0xd7fb68['trunks'][_0x569225('0xf5d')]:[],'crudPermissions':_0xd7fb68[_0x569225('0x1134')]}});}function _0x48a293(){const _0x276b84=_0x38dc56;_0x4387ca['go'](_0x276b84('0x222b'),{},{'reload':'app.tools.trunks'});}function _0x3fe2ba(){const _0x7b6878=_0x38dc56;_0x536959[_0x7b6878('0x1a93')][_0x7b6878('0x2480')]({'id':_0xd7fb68[_0x7b6878('0x1a93')]['id']},_0xd7fb68[_0x7b6878('0x1a93')])['$promise'][_0x7b6878('0x683')](function(){const _0x2f6342=_0x7b6878;_0x1b111c[_0x2f6342('0x53')]({'title':_0x2f6342('0x25b1'),'msg':_0xd7fb68['trunk']['name']?_0xd7fb68[_0x2f6342('0x1a93')][_0x2f6342('0x60a')]+'\x20has\x20been\x20updated!':''});})[_0x7b6878('0x130a')](function(_0x1cefa0){const _0x1fd88e=_0x7b6878;_0x1b111c[_0x1fd88e('0x52a')]({'title':_0x1cefa0['status']?_0x1fd88e('0x2168')+_0x1cefa0[_0x1fd88e('0x13ee')]+_0x1fd88e('0xbf6')+_0x1cefa0['statusText']:_0x1fd88e('0x12f9'),'msg':_0x1cefa0['data']?JSON[_0x1fd88e('0x258a')](_0x1cefa0[_0x1fd88e('0x5a5')]):_0x1cefa0[_0x1fd88e('0x1ff0')]()});});}}const _0x1e649a=_0x141981,_0x2aa767=_0x180212['p']+'src/js/modules/main/apps/tools/views/trunks/create/dialog.html/dialog.html';_0x547a93['$inject']=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),'$document','$timeout',_0x189033('0x1d08'),_0x189033('0x20fe'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x547a93(_0x5ae55c,_0x314919,_0x3e57ca,_0x6f61b8,_0x55665c,_0x3b272c,_0x2a2c10,_0x5069de,_0x25ce0f,_0x4c78c5,_0x332621,_0x49e81b,_0x199efa,_0x3c90b2,_0x3e5c10,_0xdddb99,_0x3a3446){const _0x5b7472=_0x189033,_0x82c782=this;_0x82c782['license']=_0xdddb99,_0x82c782[_0x5b7472('0x260a')]=_0x3a3446,_0x82c782['currentUser']=_0x3e5c10[_0x5b7472('0x20b2')](),_0x82c782[_0x5b7472('0x20fe')]=_0x25ce0f||{'count':0x0,'rows':[]},_0x82c782[_0x5b7472('0x2a')]=_0x4c78c5,_0x82c782['userProfileSection']=_0x332621&&_0x332621[_0x5b7472('0x50d')]==0x1?_0x332621[_0x5b7472('0xf5d')][0x0]:null,_0x82c782[_0x5b7472('0x1134')]=_0x3e5c10[_0x5b7472('0x142a')](_0x82c782[_0x5b7472('0x22df')]?_0x82c782['userProfileSection'][_0x5b7472('0x1134')]:null),_0x82c782[_0x5b7472('0x5c4')]='trunks',_0x82c782[_0x5b7472('0x247')]='',_0x82c782[_0x5b7472('0x1ce2')]=null,_0x82c782[_0x5b7472('0x190f')]=[],_0x82c782['query']={'fields':_0x5b7472('0x2425'),'sort':_0x5b7472('0xc36'),'limit':0xa,'page':0x1},_0x82c782[_0x5b7472('0x10b7')]=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':_0x5b7472('0x214d'),'value':_0x5b7472('0x4e9')},{'option':_0x5b7472('0x1dad'),'value':_0x5b7472('0x158f')},{'option':'Peer','value':'\x27peer\x27'}],function(_0x4d1634){const _0x2986fd=_0x5b7472;return _0x2e3ca0()[_0x2986fd('0x1725')](_0x4d1634[_0x2986fd('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782[_0x5b7472('0x1204')]=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':_0x5b7472('0x3c0'),'value':_0x5b7472('0x16a8')},{'option':'info','value':_0x5b7472('0x1c0')},{'option':_0x5b7472('0x12dd'),'value':_0x5b7472('0x52b')},{'option':'inband','value':_0x5b7472('0xd5f')},{'option':'auto','value':'\x27auto\x27'}],function(_0x4ff15a){const _0x5ad516=_0x5b7472;return _0x2e3ca0()[_0x5ad516('0x1725')](_0x4ff15a['value'],new RegExp('\x27','g'),'');}),_0x82c782[_0x5b7472('0x14c3')]=_0x2e3ca0()['keyBy']([{'option':'force_rport','value':_0x5b7472('0x20b7')},{'option':_0x5b7472('0x261e'),'value':_0x5b7472('0xe1')},{'option':_0x5b7472('0x7cd'),'value':'\x27yes\x27'},{'option':'no','value':'\x27no\x27'},{'option':_0x5b7472('0x649'),'value':_0x5b7472('0xd77')},{'option':'route','value':_0x5b7472('0x23a6')}],function(_0x443ec5){const _0x1a00e4=_0x5b7472;return _0x2e3ca0()[_0x1a00e4('0x1725')](_0x443ec5[_0x1a00e4('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782[_0x5b7472('0x27a3')]=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':_0x5b7472('0x7cd'),'value':'\x27yes\x27'},{'option':'no','value':_0x5b7472('0x23ca')}],function(_0x4ecc70){const _0x2bf641=_0x5b7472;return _0x2e3ca0()[_0x2bf641('0x1725')](_0x4ecc70[_0x2bf641('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782[_0x5b7472('0x2673')]=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':'ulaw','value':'\x27ulaw\x27'},{'option':_0x5b7472('0xdf6'),'value':_0x5b7472('0xa1e')},{'option':_0x5b7472('0x1ac0'),'value':_0x5b7472('0x1755')},{'option':_0x5b7472('0x1faf'),'value':_0x5b7472('0x24cc')},{'option':_0x5b7472('0x1db'),'value':_0x5b7472('0x1f5c')},{'option':_0x5b7472('0x4dd'),'value':_0x5b7472('0x226b')},{'option':_0x5b7472('0x14bf'),'value':'\x27g729\x27'},{'option':_0x5b7472('0x40d'),'value':_0x5b7472('0x12e7')},{'option':'opus','value':_0x5b7472('0x2873')},{'option':_0x5b7472('0x6e6'),'value':_0x5b7472('0x483')}],function(_0x31fe19){const _0x4b1c08=_0x5b7472;return _0x2e3ca0()[_0x4b1c08('0x1725')](_0x31fe19['value'],new RegExp('\x27','g'),'');}),_0x82c782['arrayinsecure']=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':_0x5b7472('0x4a2'),'value':_0x5b7472('0xe91')},{'option':_0x5b7472('0x1724'),'value':'\x27invite\x27'},{'option':_0x5b7472('0x1a06'),'value':_0x5b7472('0x251f')}],function(_0x3c32c9){const _0x2130f6=_0x5b7472;return _0x2e3ca0()['replace'](_0x3c32c9[_0x2130f6('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782[_0x5b7472('0x1d88')]=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':_0x5b7472('0x7cd'),'value':_0x5b7472('0x2036')},{'option':'no','value':_0x5b7472('0x23ca')},{'option':_0x5b7472('0x22ea'),'value':_0x5b7472('0x1b13')},{'option':_0x5b7472('0x2480'),'value':_0x5b7472('0x752')}],function(_0x56b3d6){const _0x157ab9=_0x5b7472;return _0x2e3ca0()[_0x157ab9('0x1725')](_0x56b3d6[_0x157ab9('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782[_0x5b7472('0x17d5')]=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':_0x5b7472('0x7cd'),'value':_0x5b7472('0x2036')},{'option':'no','value':_0x5b7472('0x23ca')}],function(_0x55c210){const _0x2f16fb=_0x5b7472;return _0x2e3ca0()[_0x2f16fb('0x1725')](_0x55c210[_0x2f16fb('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782[_0x5b7472('0xd90')]=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':_0x5b7472('0x7cd'),'value':_0x5b7472('0x2036')},{'option':'no','value':_0x5b7472('0x23ca')}],function(_0x140bec){const _0x3c778d=_0x5b7472;return _0x2e3ca0()[_0x3c778d('0x1725')](_0x140bec[_0x3c778d('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782['arraytrustrpid']=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':_0x5b7472('0x7cd'),'value':_0x5b7472('0x2036')},{'option':'no','value':_0x5b7472('0x23ca')}],function(_0x41fda3){const _0x57420a=_0x5b7472;return _0x2e3ca0()[_0x57420a('0x1725')](_0x41fda3[_0x57420a('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782['arraysendrpid']=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':'yes','value':_0x5b7472('0x2036')},{'option':'no','value':_0x5b7472('0x23ca')},{'option':_0x5b7472('0x13f4'),'value':_0x5b7472('0x1106')}],function(_0x33f292){const _0x734e50=_0x5b7472;return _0x2e3ca0()['replace'](_0x33f292[_0x734e50('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782['arrayencryption']=_0x2e3ca0()['keyBy']([{'option':_0x5b7472('0x7cd'),'value':_0x5b7472('0x2036')},{'option':'no','value':_0x5b7472('0x23ca')}],function(_0x2a8490){const _0x3739a1=_0x5b7472;return _0x2e3ca0()[_0x3739a1('0x1725')](_0x2a8490['value'],new RegExp('\x27','g'),'');}),_0x82c782[_0x5b7472('0xfb8')]=_0x2e3ca0()['keyBy']([{'option':_0x5b7472('0x41d'),'value':'\x27udp\x27'},{'option':'tcp','value':_0x5b7472('0xf6')},{'option':'ws','value':_0x5b7472('0x117e')},{'option':_0x5b7472('0x2615'),'value':_0x5b7472('0x26fa')},{'option':_0x5b7472('0x171f'),'value':_0x5b7472('0x9ee')}],function(_0x330823){const _0x376d25=_0x5b7472;return _0x2e3ca0()[_0x376d25('0x1725')](_0x330823[_0x376d25('0x1c6b')],new RegExp('\x27','g'),'');}),_0x82c782[_0x5b7472('0x10df')]=_0x2e3ca0()[_0x5b7472('0x24db')]([{'option':_0x5b7472('0xe76'),'value':_0x5b7472('0x2036')},{'option':'No','value':_0x5b7472('0x23ca')},{'option':_0x5b7472('0x1023'),'value':_0x5b7472('0x6c7')}],function(_0x71a366){const _0x5c0bce=_0x5b7472;return _0x2e3ca0()[_0x5c0bce('0x1725')](_0x71a366['value'],new RegExp('\x27','g'),'');}),_0x82c782['editstate']=_0x5939ae,_0x82c782[_0x5b7472('0x163d')]=_0x18fe10,_0x82c782['gotorealtimegoto']=_0x3117e2,_0x82c782[_0x5b7472('0x194f')]=_0x48bfa1,_0x82c782[_0x5b7472('0x53')]=_0x167075,_0x82c782[_0x5b7472('0x5c5')]=_0x2224a9,_0x82c782[_0x5b7472('0x284d')]=_0x5086c5,_0x82c782[_0x5b7472('0x4b3')]=_0x3610fb,_0x82c782['exportSelectedTrunks']=_0xaace66,_0x82c782['deleteSelectedTrunks']=_0x4b4379,_0x82c782['deselectTrunks']=_0x417f04,_0x82c782[_0x5b7472('0x1b47')]=_0x58c49c;function _0x5939ae(_0x1a337c){const _0x1d1346=_0x5b7472;_0x3e57ca['go'](_0x1d1346('0xc28'),{'id':_0x1a337c['id'],'trunk':_0x1a337c,'crudPermissions':_0x82c782[_0x1d1346('0x1134')]});}function _0x18fe10(_0x5c86fb,_0x1b3f76){const _0x58e51f=_0x5b7472;_0x55665c[_0x58e51f('0x1d4')]({'controller':_0x58e51f('0x2390'),'controllerAs':'vm','templateUrl':_0x30152f,'parent':angular[_0x58e51f('0x1fcc')](_0x3b272c[_0x58e51f('0x18e5')]),'targetEvent':_0x1b3f76,'clickOutsideToClose':!![],'locals':{'trunk':_0x5c86fb,'trunks':_0x82c782['trunks']?_0x82c782[_0x58e51f('0x20fe')][_0x58e51f('0xf5d')]:[],'crudPermissions':_0x82c782['crudPermissions']}});}function _0x3117e2(){const _0x51b4db=_0x5b7472;if(_0x3e5c10[_0x51b4db('0xca1')](_0x51b4db('0x20c2')))_0x3e57ca['go'](_0x51b4db('0x19d8'),{});else return _0x49e81b['userProfileSection']['get']({'userProfileId':_0x3e5c10[_0x51b4db('0x20b2')]()[_0x51b4db('0x2f')],'sectionId':0x19b})[_0x51b4db('0xe53')][_0x51b4db('0x683')](function(_0x40609a){const _0x4cd25f=_0x51b4db,_0x3214e0=_0x40609a&&_0x40609a[_0x4cd25f('0xf5d')]?_0x40609a[_0x4cd25f('0xf5d')][0x0]:null;_0x3214e0&&_0x3214e0[_0x4cd25f('0x1333')]?_0x3e57ca['go'](_0x4cd25f('0x19d8'),{}):_0x3c90b2[_0x4cd25f('0x2289')]({'title':_0x5069de[_0x4cd25f('0x2728')](_0x4cd25f('0x213e')),'msg':_0x5069de[_0x4cd25f('0x2728')](_0x4cd25f('0xdba'))});})[_0x51b4db('0x130a')](function(_0x5bf76c){const _0xffa236=_0x51b4db;_0x3c90b2[_0xffa236('0x52a')]({'title':_0x5bf76c[_0xffa236('0x13ee')]?_0xffa236('0x2168')+_0x5bf76c[_0xffa236('0x13ee')]+_0xffa236('0xbf6')+_0x5bf76c[_0xffa236('0x24a9')]:_0xffa236('0xf2a'),'msg':_0x5bf76c[_0xffa236('0x13ee')]?JSON[_0xffa236('0x258a')](_0x5bf76c['data']):_0x5bf76c['toString']()});});}function _0x48bfa1(_0x597454,_0x50688d){const _0x2d896c=_0x5b7472,_0x37ed4c=_0x55665c[_0x2d896c('0x1c6f')]()['title'](_0x2d896c('0x1b01')+_0x2e3ca0()['startCase'](_0x2d896c('0x1a93'))+'?')[_0x2d896c('0x26e3')](_0x2d896c('0xed5')+(_0x597454[_0x2d896c('0x60a')]||_0x2d896c('0x1a93'))+_0x2d896c('0x20f1')+_0x2d896c('0x1ee7'))[_0x2d896c('0x1040')](_0x2d896c('0xab'))['targetEvent'](_0x50688d)['ok']('OK')['cancel'](_0x2d896c('0x16b8'));_0x55665c[_0x2d896c('0x1d4')](_0x37ed4c)[_0x2d896c('0x683')](function(){_0x3610fb(_0x597454);},function(){const _0x1ad7a8=_0x2d896c;console['log'](_0x1ad7a8('0x16b8'));});}let _0x2ed1a4=!![],_0x1715d5=0x1;_0x5ae55c[_0x5b7472('0x186d')](_0x5b7472('0x1e1d'),function(_0x58e4d4,_0x2b9d8b){const _0x3982c8=_0x5b7472;_0x2ed1a4?_0x2a2c10(function(){_0x2ed1a4=![];}):(!_0x2b9d8b&&(_0x1715d5=_0x82c782[_0x3982c8('0x23a2')][_0x3982c8('0xdf8')]),_0x58e4d4!==_0x2b9d8b&&(_0x82c782[_0x3982c8('0x23a2')][_0x3982c8('0xdf8')]=0x1),!_0x58e4d4&&(_0x82c782['query']['page']=_0x1715d5),_0x82c782[_0x3982c8('0x5c5')]());});function _0x167075(_0x468f7d){const _0x115aed=_0x5b7472;_0x82c782[_0x115aed('0x20fe')]=_0x468f7d||{'count':0x0,'rows':[]};}function _0x2224a9(){const _0x27e13f=_0x5b7472;_0x82c782[_0x27e13f('0x23a2')][_0x27e13f('0x1cc8')]=(_0x82c782['query']['page']-0x1)*_0x82c782[_0x27e13f('0x23a2')]['limit'],_0x3e5c10['hasRole'](_0x27e13f('0x20c2'))?_0x82c782[_0x27e13f('0x1883')]=_0x49e81b[_0x27e13f('0x1a93')]['get'](_0x82c782[_0x27e13f('0x23a2')],_0x167075)[_0x27e13f('0xe53')]:(_0x82c782[_0x27e13f('0x23a2')]['id']=_0x82c782[_0x27e13f('0x2a')]['id'],_0x82c782[_0x27e13f('0x23a2')][_0x27e13f('0x1aa')]=_0x27e13f('0x485'),_0x82c782[_0x27e13f('0x1883')]=_0x49e81b[_0x27e13f('0x2a')][_0x27e13f('0x241d')](_0x82c782[_0x27e13f('0x23a2')],_0x167075)[_0x27e13f('0xe53')]);}function _0x5086c5(_0x52a264,_0x53c7cf){const _0x5e65a6=_0x5b7472;_0x55665c[_0x5e65a6('0x1d4')]({'controller':_0x5e65a6('0x1c73'),'controllerAs':'vm','templateUrl':_0x2aa767,'parent':angular[_0x5e65a6('0x1fcc')](_0x3b272c[_0x5e65a6('0x18e5')]),'targetEvent':_0x52a264,'clickOutsideToClose':!![],'locals':{'trunk':_0x53c7cf,'trunks':_0x82c782[_0x5e65a6('0x20fe')][_0x5e65a6('0xf5d')],'license':_0x82c782[_0x5e65a6('0xace')],'setting':_0x82c782[_0x5e65a6('0x260a')],'crudPermissions':_0x82c782[_0x5e65a6('0x1134')]}});}function _0x3610fb(_0x5f0af8){const _0x53f983=_0x5b7472;_0x49e81b[_0x53f983('0x1a93')][_0x53f983('0xd7e')]({'id':_0x5f0af8['id']})[_0x53f983('0xe53')][_0x53f983('0x683')](function(){const _0x10d648=_0x53f983;_0x2e3ca0()[_0x10d648('0x3ec')](_0x82c782[_0x10d648('0x20fe')][_0x10d648('0xf5d')],{'id':_0x5f0af8['id']}),_0x82c782['trunks'][_0x10d648('0x50d')]-=0x1,!_0x82c782[_0x10d648('0x20fe')][_0x10d648('0xf5d')][_0x10d648('0x1564')]&&_0x82c782[_0x10d648('0x5c5')](),_0x3c90b2['success']({'title':_0x2e3ca0()[_0x10d648('0x1e03')]('Trunk')+_0x10d648('0xbfc'),'msg':_0x5f0af8[_0x10d648('0x60a')]?_0x5f0af8[_0x10d648('0x60a')]+_0x10d648('0x194d'):''});})[_0x53f983('0x130a')](function(_0x1fe14e){const _0x1c36ee=_0x53f983;if(_0x1fe14e[_0x1c36ee('0x5a5')]&&_0x1fe14e[_0x1c36ee('0x5a5')][_0x1c36ee('0x17f')]&&_0x1fe14e[_0x1c36ee('0x5a5')][_0x1c36ee('0x17f')][_0x1c36ee('0x1564')]){_0x82c782['errors']=_0x1fe14e[_0x1c36ee('0x5a5')]['errors']||[{'message':_0x1fe14e['toString'](),'type':_0x1c36ee('0x18de')}];for(let _0x3fd3e3=0x0;_0x3fd3e3<_0x1fe14e[_0x1c36ee('0x5a5')][_0x1c36ee('0x17f')][_0x1c36ee('0x1564')];_0x3fd3e3++){_0x3c90b2[_0x1c36ee('0x52a')]({'title':_0x1fe14e[_0x1c36ee('0x5a5')]['errors'][_0x3fd3e3]['type'],'msg':_0x1fe14e[_0x1c36ee('0x5a5')]['errors'][_0x3fd3e3][_0x1c36ee('0x8c2')]});}}else _0x3c90b2[_0x1c36ee('0x52a')]({'title':_0x1fe14e['status']?_0x1c36ee('0x2168')+_0x1fe14e[_0x1c36ee('0x13ee')]+_0x1c36ee('0xbf6')+_0x1fe14e[_0x1c36ee('0x24a9')]:_0x1c36ee('0x18de'),'msg':_0x1fe14e['data']?JSON[_0x1c36ee('0x258a')](_0x1fe14e[_0x1c36ee('0x5a5')]['message']):_0x1fe14e[_0x1c36ee('0x8c2')]||_0x1fe14e['toString']()});});}function _0xaace66(){const _0x4e2bc0=_0x5b7472,_0x1c1d4a=angular[_0x4e2bc0('0x1a86')](_0x82c782[_0x4e2bc0('0x190f')]);return _0x82c782[_0x4e2bc0('0x190f')]=[],_0x1c1d4a;}function _0x4b4379(_0xfe6fe){const _0x3a635f=_0x5b7472,_0x380fd7=_0x55665c['confirm']()[_0x3a635f('0xf28')](_0x3a635f('0x8ec'))['htmlContent'](_0x3a635f('0xed5')+_0x82c782[_0x3a635f('0x190f')][_0x3a635f('0x1564')]+_0x3a635f('0x93c')+_0x3a635f('0x1ee7'))['ariaLabel'](_0x3a635f('0x19f8'))[_0x3a635f('0xe42')](_0xfe6fe)['ok']('OK')[_0x3a635f('0x19fb')](_0x3a635f('0x16b8'));_0x55665c['show'](_0x380fd7)['then'](function(){const _0x408a12=_0x3a635f;_0x82c782[_0x408a12('0x190f')][_0x408a12('0x1299')](function(_0x280349){_0x3610fb(_0x280349);}),_0x82c782[_0x408a12('0x190f')]=[];});}function _0x417f04(){const _0x1f4dca=_0x5b7472;_0x82c782[_0x1f4dca('0x190f')]=[];}function _0x58c49c(){const _0x57a286=_0x5b7472;_0x82c782['selectedTrunks']=_0x82c782['trunks'][_0x57a286('0xf5d')];}}const _0x20e84d=_0x547a93;_0x597f73[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x220b'),'variable',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x597f73(_0x5dc83d,_0x54fea0,_0x4c9f07,_0x5bb86c,_0x1fafbf,_0x1e6f67,_0x20a678,_0x347250,_0x39b0d0,_0x1fd3ec,_0x26e3a7,_0x79d74,_0x689d6,_0x554658){const _0x283129=_0x189033,_0x21ae0e=this;_0x21ae0e[_0x283129('0x11ed')]=_0x26e3a7['getCurrentUser'](),_0x21ae0e[_0x283129('0x17f')]=[],_0x21ae0e['setting']=_0x689d6,_0x21ae0e[_0x283129('0xace')]=_0x79d74,_0x21ae0e[_0x283129('0x1134')]=_0x554658,_0x21ae0e[_0x283129('0x258d')]={},_0x21ae0e[_0x283129('0x19b2')]=_0x21ae0e[_0x283129('0x260a')]&&_0x21ae0e[_0x283129('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x21ae0e[_0x283129('0xf28')]=_0x283129('0x1d7b'),_0x21ae0e[_0x283129('0x26e0')]=angular['copy'](_0x39b0d0),_0x21ae0e['variables']=_0x347250,_0x21ae0e[_0x283129('0x2112')]=![];!_0x21ae0e[_0x283129('0x26e0')]&&(_0x21ae0e[_0x283129('0x26e0')]={},_0x21ae0e['title']=_0x283129('0x111'),_0x21ae0e[_0x283129('0x2112')]=!![]);_0x21ae0e[_0x283129('0x8de')]=_0xef4335,_0x21ae0e[_0x283129('0x1caa')]=_0x3e94fb,_0x21ae0e[_0x283129('0x149b')]=_0x3f5388,_0x21ae0e[_0x283129('0x16b3')]=_0x25de99,_0x21ae0e[_0x283129('0xf82')]=_0x40ed14;function _0xef4335(){const _0x29bb35=_0x283129;_0x21ae0e[_0x29bb35('0x17f')]=[],_0x1fd3ec[_0x29bb35('0x26e0')][_0x29bb35('0xb0a')](_0x21ae0e['variable'])[_0x29bb35('0xe53')][_0x29bb35('0x683')](function(_0x531ea4){const _0x112804=_0x29bb35;_0x21ae0e[_0x112804('0x220b')]['unshift'](_0x531ea4[_0x112804('0x24e1')]()),_0x20a678[_0x112804('0x53')]({'title':_0x112804('0xe2c'),'msg':_0x21ae0e[_0x112804('0x26e0')][_0x112804('0x60a')]?_0x21ae0e[_0x112804('0x26e0')][_0x112804('0x60a')]+_0x112804('0x14b5'):''}),_0x40ed14(_0x531ea4);})[_0x29bb35('0x130a')](function(_0x450e25){const _0x3e29f8=_0x29bb35;if(_0x450e25[_0x3e29f8('0x5a5')]&&_0x450e25['data'][_0x3e29f8('0x17f')]&&_0x450e25[_0x3e29f8('0x5a5')][_0x3e29f8('0x17f')][_0x3e29f8('0x1564')]){_0x21ae0e[_0x3e29f8('0x17f')]=_0x450e25['data']['errors']||[{'message':_0x450e25[_0x3e29f8('0x1ff0')](),'type':_0x3e29f8('0xbfa')}];for(let _0x58c123=0x0;_0x58c123<_0x450e25['data'][_0x3e29f8('0x17f')][_0x3e29f8('0x1564')];_0x58c123+=0x1){_0x20a678[_0x3e29f8('0x52a')]({'title':_0x450e25[_0x3e29f8('0x5a5')][_0x3e29f8('0x17f')][_0x58c123][_0x3e29f8('0xcf0')],'msg':_0x450e25['data']['errors'][_0x58c123][_0x3e29f8('0x8c2')]});}}else _0x20a678[_0x3e29f8('0x52a')]({'title':_0x450e25[_0x3e29f8('0x13ee')]?_0x3e29f8('0x2168')+_0x450e25[_0x3e29f8('0x13ee')]+_0x3e29f8('0xbf6')+_0x450e25[_0x3e29f8('0x24a9')]:_0x3e29f8('0xbfa'),'msg':_0x450e25[_0x3e29f8('0x5a5')]?JSON[_0x3e29f8('0x258a')](_0x450e25[_0x3e29f8('0x5a5')]['message']):_0x450e25[_0x3e29f8('0x1ff0')]()});});}function _0x3e94fb(){const _0x2a8b98=_0x283129;_0x21ae0e[_0x2a8b98('0x17f')]=[],_0x1fd3ec[_0x2a8b98('0x26e0')][_0x2a8b98('0x2480')]({'id':_0x21ae0e[_0x2a8b98('0x26e0')]['id']},_0x21ae0e[_0x2a8b98('0x26e0')])['$promise'][_0x2a8b98('0x683')](function(_0x68f1db){const _0x1b3ea7=_0x2a8b98,_0x1fc98b=_0x2e3ca0()[_0x1b3ea7('0x1c07')](_0x21ae0e[_0x1b3ea7('0x220b')],{'id':_0x68f1db['id']});_0x1fc98b&&_0x2e3ca0()[_0x1b3ea7('0xf22')](_0x1fc98b,_0x2e3ca0()[_0x1b3ea7('0x24d0')](_0x68f1db['toJSON'](),_0x2e3ca0()[_0x1b3ea7('0x55e')](_0x1fc98b))),_0x20a678[_0x1b3ea7('0x53')]({'title':_0x1b3ea7('0x1799'),'msg':_0x21ae0e[_0x1b3ea7('0x26e0')]['name']?_0x21ae0e['variable'][_0x1b3ea7('0x60a')]+_0x1b3ea7('0xf59'):''}),_0x40ed14(_0x68f1db);})[_0x2a8b98('0x130a')](function(_0x352e68){const _0x24c26c=_0x2a8b98;if(_0x352e68['data']&&_0x352e68[_0x24c26c('0x5a5')][_0x24c26c('0x17f')]&&_0x352e68['data']['errors']['length']){_0x21ae0e[_0x24c26c('0x17f')]=_0x352e68['data'][_0x24c26c('0x17f')]||[{'message':_0x352e68['toString'](),'type':'api.variable.update'}];for(let _0x32f640=0x0;_0x32f640<_0x352e68[_0x24c26c('0x5a5')]['errors'][_0x24c26c('0x1564')];_0x32f640++){_0x20a678[_0x24c26c('0x52a')]({'title':_0x352e68['data'][_0x24c26c('0x17f')][_0x32f640][_0x24c26c('0xcf0')],'msg':_0x352e68[_0x24c26c('0x5a5')][_0x24c26c('0x17f')][_0x32f640]['message']});}}else _0x20a678[_0x24c26c('0x52a')]({'title':_0x352e68[_0x24c26c('0x13ee')]?_0x24c26c('0x2168')+_0x352e68[_0x24c26c('0x13ee')]+_0x24c26c('0xbf6')+_0x352e68[_0x24c26c('0x24a9')]:_0x24c26c('0x4b'),'msg':_0x352e68[_0x24c26c('0x5a5')]?JSON[_0x24c26c('0x258a')](_0x352e68[_0x24c26c('0x5a5')][_0x24c26c('0x8c2')]):_0x352e68[_0x24c26c('0x1ff0')]()});});}function _0x3f5388(_0x1975b9){const _0x2bfc7a=_0x283129;_0x21ae0e[_0x2bfc7a('0x17f')]=[];const _0x1884e5=_0x5bb86c[_0x2bfc7a('0x1c6f')]()[_0x2bfc7a('0xf28')](_0x2bfc7a('0x4d'))['content'](_0x2bfc7a('0xfb4'))[_0x2bfc7a('0x1040')]('Delete\x20Variable')['ok']('Delete')['cancel']('Cancel')['targetEvent'](_0x1975b9);_0x5bb86c['show'](_0x1884e5)[_0x2bfc7a('0x683')](function(){const _0x4d082f=_0x2bfc7a;_0x1fd3ec[_0x4d082f('0x26e0')][_0x4d082f('0xd7e')]({'id':_0x21ae0e[_0x4d082f('0x26e0')]['id']})[_0x4d082f('0xe53')]['then'](function(){const _0x583f8e=_0x4d082f;_0x2e3ca0()['remove'](_0x21ae0e['variables'],{'id':_0x21ae0e['variable']['id']}),_0x20a678['success']({'title':_0x583f8e('0x807'),'msg':(_0x21ae0e[_0x583f8e('0x26e0')][_0x583f8e('0x60a')]||_0x583f8e('0x26e0'))+'\x20has\x20been\x20deleted!'}),_0x40ed14(_0x21ae0e['variable']);})[_0x4d082f('0x130a')](function(_0x3dbef8){const _0x217d8d=_0x4d082f;if(_0x3dbef8[_0x217d8d('0x5a5')]&&_0x3dbef8[_0x217d8d('0x5a5')][_0x217d8d('0x17f')]&&_0x3dbef8['data']['errors'][_0x217d8d('0x1564')]){_0x21ae0e[_0x217d8d('0x17f')]=_0x3dbef8[_0x217d8d('0x5a5')][_0x217d8d('0x17f')]||[{'message':_0x3dbef8[_0x217d8d('0x1ff0')](),'type':'api.variable.delete'}];for(let _0x15e159=0x0;_0x15e159<_0x3dbef8[_0x217d8d('0x5a5')][_0x217d8d('0x17f')][_0x217d8d('0x1564')];_0x15e159++){_0x20a678['error']({'title':_0x3dbef8[_0x217d8d('0x5a5')][_0x217d8d('0x17f')][_0x15e159][_0x217d8d('0xcf0')],'msg':_0x3dbef8['data'][_0x217d8d('0x17f')][_0x15e159][_0x217d8d('0x8c2')]});}}else _0x20a678['error']({'title':_0x3dbef8[_0x217d8d('0x13ee')]?_0x217d8d('0x2168')+_0x3dbef8[_0x217d8d('0x13ee')]+_0x217d8d('0xbf6')+_0x3dbef8[_0x217d8d('0x24a9')]:_0x217d8d('0xd87'),'msg':_0x3dbef8[_0x217d8d('0x5a5')]?JSON[_0x217d8d('0x258a')](_0x3dbef8[_0x217d8d('0x5a5')][_0x217d8d('0x8c2')]):_0x3dbef8[_0x217d8d('0x8c2')]||_0x3dbef8[_0x217d8d('0x1ff0')]()});});},function(){});}function _0x25de99(_0x5b3a52){return _0x5b3a52===null?undefined:new Date(_0x5b3a52);}function _0x40ed14(_0x42db0e){const _0x175b0f=_0x283129;_0x5bb86c[_0x175b0f('0x1715')](_0x42db0e);}}const _0x25464c=_0x597f73,_0x3b99c6=_0x180212['p']+_0x189033('0x1397');_0x5794cd[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0x220b'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),'Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x5794cd(_0xa6c2b4,_0x4d7744,_0x345fc9,_0xe9039,_0x222013,_0x1924f8,_0x30948e,_0x43a93a,_0x31c3f4,_0x52dae9,_0xb14fa3,_0x59509d,_0x3d57fa,_0x32cc89,_0x5ab044,_0x38ec60,_0x153036){const _0x4733de=_0x189033,_0x26667a=this;_0x26667a[_0x4733de('0xace')]=_0x38ec60,_0x26667a[_0x4733de('0x260a')]=_0x153036,_0x26667a[_0x4733de('0x11ed')]=_0x5ab044[_0x4733de('0x20b2')](),_0x26667a[_0x4733de('0x220b')]=_0x31c3f4||{'count':0x0,'rows':[]},_0x26667a['userProfile']=_0x52dae9,_0x26667a[_0x4733de('0x22df')]=_0xb14fa3&&_0xb14fa3[_0x4733de('0x50d')]==0x1?_0xb14fa3[_0x4733de('0xf5d')][0x0]:null,_0x26667a[_0x4733de('0x1134')]=_0x5ab044['parseCrudPermissions'](_0x26667a[_0x4733de('0x22df')]?_0x26667a[_0x4733de('0x22df')][_0x4733de('0x1134')]:null),_0x26667a[_0x4733de('0x5c4')]=_0x4733de('0x220b'),_0x26667a[_0x4733de('0x247')]='',_0x26667a[_0x4733de('0x1ce2')]=null,_0x26667a[_0x4733de('0xc42')]=[],_0x26667a['query']={'fields':_0x4733de('0x120a'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x26667a[_0x4733de('0x1249')]=_0x46ed3a,_0x26667a[_0x4733de('0x194f')]=_0x1eb3a4,_0x26667a[_0x4733de('0x53')]=_0x2c9b75,_0x26667a[_0x4733de('0x1ee0')]=_0x10e689,_0x26667a[_0x4733de('0xfde')]=_0x5c8e2a,_0x26667a[_0x4733de('0x149b')]=_0x5484eb,_0x26667a[_0x4733de('0x11b3')]=_0x152bbd,_0x26667a['deleteSelectedVariables']=_0x3fa167,_0x26667a['deselectVariables']=_0xef8f05,_0x26667a['selectAllVariables']=_0x4f6cee;function _0x46ed3a(_0x5d519e,_0x1f5987){const _0x266cd7=_0x4733de;_0x222013['show']({'controller':_0x266cd7('0x1a62'),'controllerAs':'vm','templateUrl':_0x3b99c6,'parent':angular[_0x266cd7('0x1fcc')](_0x1924f8['body']),'targetEvent':_0x1f5987,'clickOutsideToClose':!![],'locals':{'variable':_0x5d519e,'variables':_0x26667a['variables'][_0x266cd7('0xf5d')],'license':_0x26667a[_0x266cd7('0xace')],'setting':null,'crudPermissions':_0x26667a[_0x266cd7('0x1134')]}});}function _0x1eb3a4(_0x416f44,_0x1823fa){const _0x275af4=_0x4733de,_0x87c2e7=_0x222013['confirm']()[_0x275af4('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x275af4('0x1e03')]('variable')+'?')[_0x275af4('0x26e3')](_0x275af4('0xed5')+(_0x416f44['name']||_0x275af4('0x26e0'))+_0x275af4('0x20f1')+_0x275af4('0x1ee7'))[_0x275af4('0x1040')]('delete\x20variable')['targetEvent'](_0x1823fa)['ok']('OK')[_0x275af4('0x19fb')](_0x275af4('0x16b8'));_0x222013['show'](_0x87c2e7)[_0x275af4('0x683')](function(){_0x5484eb(_0x416f44);},function(){const _0x507f13=_0x275af4;console[_0x507f13('0x1b2b')](_0x507f13('0x16b8'));});}let _0x37dcfd=!![],_0x2408cc=0x1;_0xa6c2b4[_0x4733de('0x186d')]('vm.query.filter',function(_0x1bda28,_0x44bbc){const _0x230b0d=_0x4733de;_0x37dcfd?_0x30948e(function(){_0x37dcfd=![];}):(!_0x44bbc&&(_0x2408cc=_0x26667a[_0x230b0d('0x23a2')][_0x230b0d('0xdf8')]),_0x1bda28!==_0x44bbc&&(_0x26667a['query']['page']=0x1),!_0x1bda28&&(_0x26667a[_0x230b0d('0x23a2')][_0x230b0d('0xdf8')]=_0x2408cc),_0x26667a['getVariables']());});function _0x2c9b75(_0x3ff501){const _0x57f2d2=_0x4733de;_0x26667a[_0x57f2d2('0x220b')]=_0x3ff501||{'count':0x0,'rows':[]};}function _0x10e689(){const _0x86c6eb=_0x4733de;_0x26667a[_0x86c6eb('0x23a2')][_0x86c6eb('0x1cc8')]=(_0x26667a['query'][_0x86c6eb('0xdf8')]-0x1)*_0x26667a['query'][_0x86c6eb('0x6f0')],_0x5ab044['hasRole'](_0x86c6eb('0x20c2'))?_0x26667a['promise']=_0x59509d['variable'][_0x86c6eb('0x1e6e')](_0x26667a['query'],_0x2c9b75)[_0x86c6eb('0xe53')]:(_0x26667a[_0x86c6eb('0x23a2')]['id']=_0x26667a['userProfile']['id'],_0x26667a[_0x86c6eb('0x23a2')]['section']=_0x86c6eb('0x2095'),_0x26667a[_0x86c6eb('0x1883')]=_0x59509d[_0x86c6eb('0x2a')][_0x86c6eb('0x241d')](_0x26667a[_0x86c6eb('0x23a2')],_0x2c9b75)[_0x86c6eb('0xe53')]);}function _0x5c8e2a(_0x237449,_0x12f41f){const _0x3b001c=_0x4733de;_0x222013[_0x3b001c('0x1d4')]({'controller':'CreateOrEditVariableDialogController','controllerAs':'vm','templateUrl':_0x3b99c6,'parent':angular['element'](_0x1924f8['body']),'targetEvent':_0x237449,'clickOutsideToClose':!![],'locals':{'variable':_0x12f41f,'variables':_0x26667a[_0x3b001c('0x220b')][_0x3b001c('0xf5d')],'license':_0x26667a[_0x3b001c('0xace')],'setting':_0x26667a[_0x3b001c('0x260a')],'crudPermissions':_0x26667a[_0x3b001c('0x1134')]}});}function _0x5484eb(_0x2256f9){const _0x5265ad=_0x4733de;_0x59509d[_0x5265ad('0x26e0')][_0x5265ad('0xd7e')]({'id':_0x2256f9['id']})[_0x5265ad('0xe53')][_0x5265ad('0x683')](function(){const _0x29ec74=_0x5265ad;_0x2e3ca0()[_0x29ec74('0x3ec')](_0x26667a[_0x29ec74('0x220b')][_0x29ec74('0xf5d')],{'id':_0x2256f9['id']}),_0x26667a['variables'][_0x29ec74('0x50d')]-=0x1,!_0x26667a['variables']['rows']['length']&&_0x26667a['getVariables'](),_0x32cc89[_0x29ec74('0x53')]({'title':_0x2e3ca0()[_0x29ec74('0x1e03')](_0x29ec74('0xde7'))+'\x20deleted!','msg':_0x2256f9[_0x29ec74('0x60a')]?_0x2256f9[_0x29ec74('0x60a')]+_0x29ec74('0x194d'):''});})['catch'](function(_0x412417){const _0x8b5a0d=_0x5265ad;if(_0x412417[_0x8b5a0d('0x5a5')]&&_0x412417[_0x8b5a0d('0x5a5')][_0x8b5a0d('0x17f')]&&_0x412417[_0x8b5a0d('0x5a5')][_0x8b5a0d('0x17f')][_0x8b5a0d('0x1564')]){_0x26667a[_0x8b5a0d('0x17f')]=_0x412417[_0x8b5a0d('0x5a5')][_0x8b5a0d('0x17f')]||[{'message':_0x412417[_0x8b5a0d('0x1ff0')](),'type':'SYSTEM:DELETEvariable'}];for(let _0x448db1=0x0;_0x448db1<_0x412417[_0x8b5a0d('0x5a5')][_0x8b5a0d('0x17f')]['length'];_0x448db1++){_0x32cc89[_0x8b5a0d('0x52a')]({'title':_0x412417[_0x8b5a0d('0x5a5')][_0x8b5a0d('0x17f')][_0x448db1][_0x8b5a0d('0xcf0')],'msg':_0x412417['data'][_0x8b5a0d('0x17f')][_0x448db1][_0x8b5a0d('0x8c2')]});}}else _0x32cc89[_0x8b5a0d('0x52a')]({'title':_0x412417['status']?_0x8b5a0d('0x2168')+_0x412417[_0x8b5a0d('0x13ee')]+_0x8b5a0d('0xbf6')+_0x412417[_0x8b5a0d('0x24a9')]:_0x8b5a0d('0x1c05'),'msg':_0x412417[_0x8b5a0d('0x5a5')]?JSON[_0x8b5a0d('0x258a')](_0x412417[_0x8b5a0d('0x5a5')]['message']):_0x412417[_0x8b5a0d('0x8c2')]||_0x412417[_0x8b5a0d('0x1ff0')]()});});}function _0x152bbd(){const _0x4494d6=_0x4733de,_0x12e697=angular[_0x4494d6('0x1a86')](_0x26667a[_0x4494d6('0xc42')]);return _0x26667a[_0x4494d6('0xc42')]=[],_0x12e697;}function _0x3fa167(_0x3dd2d1){const _0x19a755=_0x4733de,_0x1d0121=_0x222013[_0x19a755('0x1c6f')]()[_0x19a755('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20variables?')[_0x19a755('0x26e3')](_0x19a755('0xed5')+_0x26667a[_0x19a755('0xc42')][_0x19a755('0x1564')]+_0x19a755('0x93c')+_0x19a755('0x1ee7'))['ariaLabel'](_0x19a755('0x179e'))[_0x19a755('0xe42')](_0x3dd2d1)['ok']('OK')[_0x19a755('0x19fb')](_0x19a755('0x16b8'));_0x222013[_0x19a755('0x1d4')](_0x1d0121)[_0x19a755('0x683')](function(){const _0x103a64=_0x19a755;_0x26667a['selectedVariables'][_0x103a64('0x1299')](function(_0x5fffcf){_0x5484eb(_0x5fffcf);}),_0x26667a['selectedVariables']=[];});}function _0xef8f05(){const _0x1d7042=_0x4733de;_0x26667a[_0x1d7042('0xc42')]=[];}function _0x4f6cee(){const _0x23878b=_0x4733de;_0x26667a[_0x23878b('0xc42')]=_0x26667a['variables']['rows'];}}const _0x4265ad=_0x5794cd;_0x3ccc76['$inject']=['$stateProvider',_0x189033('0x19ee')];function _0x3ccc76(_0x9630c9,_0x454092){const _0x52f4ec=_0x189033;_0x9630c9['state']('app.tools',{'abstract':!![],'url':_0x52f4ec('0x1bc2')})[_0x52f4ec('0x2598')]('app.tools.cannedAnswers',{'url':_0x52f4ec('0x26f7'),'views':{'content@app':{'templateUrl':_0x3f201e,'controller':_0x52f4ec('0x1292')}},'resolve':{'cannedAnswers':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x1988d7,_0x1484df){const _0x214317=_0x52f4ec;return _0x1484df[_0x214317('0xca1')](_0x214317('0x20c2'))?_0x1988d7[_0x214317('0xed7')](_0x214317('0x124d'),{'fields':_0x214317('0x8ee'),'sort':_0x214317('0xc36'),'MailAccountId':_0x214317('0x13c'),'FaxAccountId':'null','SmsAccountId':_0x214317('0x13c'),'OpenchannelAccountId':_0x214317('0x13c'),'ChatWebsiteId':_0x214317('0x13c'),'limit':0xa,'offset':0x0}):_0x1988d7[_0x214317('0xed7')](_0x214317('0x191b'),{'id':_0x1484df['getCurrentUser']()[_0x214317('0x2f')],'section':_0x214317('0x14f6'),'fields':_0x214317('0x8ee'),'sort':_0x214317('0xc36'),'MailAccountId':_0x214317('0x13c'),'FaxAccountId':_0x214317('0x13c'),'SmsAccountId':'null','OpenchannelAccountId':_0x214317('0x13c'),'ChatWebsiteId':'null','limit':0xa,'offset':0x0});}],'userProfile':[_0x52f4ec('0x4b1'),'Auth',function(_0x202464,_0x58fb88){const _0x3ca6a4=_0x52f4ec;return _0x58fb88['hasRole'](_0x3ca6a4('0x20c2'))?null:_0x202464['resolve'](_0x3ca6a4('0x1464'),{'fields':_0x3ca6a4('0x16f'),'id':_0x58fb88[_0x3ca6a4('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x52f4ec('0x4b1'),'Auth',function(_0x21961f,_0x37a9ac){const _0x34a4ac=_0x52f4ec;return _0x37a9ac[_0x34a4ac('0xca1')](_0x34a4ac('0x20c2'))?null:_0x21961f[_0x34a4ac('0xed7')]('userProfileSection@get',{'fields':_0x34a4ac('0x1f47'),'userProfileId':_0x37a9ac[_0x34a4ac('0x20b2')]()[_0x34a4ac('0x2f')],'sectionId':0x3e9});}]},'authenticate':!![],'permissionId':0x3e9,'bodyClass':_0x52f4ec('0x1f88')})[_0x52f4ec('0x2598')](_0x52f4ec('0x7b3'),{'url':_0x52f4ec('0x1b39'),'views':{'content@app':{'templateUrl':_0x179fd9,'controller':_0x52f4ec('0xee9')}},'resolve':{'customDashboards':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x22706d,_0x596286){const _0x295ec5=_0x52f4ec;return _0x596286[_0x295ec5('0xca1')](_0x295ec5('0x20c2'))?_0x22706d[_0x295ec5('0xed7')](_0x295ec5('0x1183'),{'fields':_0x295ec5('0x120a'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x22706d[_0x295ec5('0xed7')](_0x295ec5('0x191b'),{'id':_0x596286[_0x295ec5('0x20b2')]()[_0x295ec5('0x2f')],'section':_0x295ec5('0x6fe'),'fields':_0x295ec5('0x120a'),'sort':_0x295ec5('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x37afa8,_0x48b96e){const _0x41cfd5=_0x52f4ec;return _0x48b96e['hasRole'](_0x41cfd5('0x20c2'))?null:_0x37afa8[_0x41cfd5('0xed7')]('userProfile@get',{'fields':_0x41cfd5('0x16f'),'id':_0x48b96e[_0x41cfd5('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x52f4ec('0x4b1'),'Auth',function(_0x42caa6,_0x4b092c){const _0x55ed47=_0x52f4ec;return _0x4b092c[_0x55ed47('0xca1')](_0x55ed47('0x20c2'))?null:_0x42caa6[_0x55ed47('0xed7')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x4b092c['getCurrentUser']()[_0x55ed47('0x2f')],'sectionId':0x3eb});}]},'authenticate':!![],'permissionId':0x3eb,'bodyClass':_0x52f4ec('0x1f88')})[_0x52f4ec('0x2598')](_0x52f4ec('0x1d33'),{'url':_0x52f4ec('0x1560'),'params':{'customDashboard':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x1ddd1e,'controller':_0x52f4ec('0x107b')}},'resolve':{'customDashboard':[_0x52f4ec('0x4b1'),_0x52f4ec('0x8ea'),function(_0x5b089e,_0x28a095){const _0x2b3783=_0x52f4ec;return _0x5b089e[_0x2b3783('0xed7')](_0x2b3783('0x1183'),{'fields':_0x2b3783('0x120a'),'id':_0x28a095['id']});}],'userProfileSection':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x37ccb5,_0x934aa4){const _0x5a8b86=_0x52f4ec;return _0x37ccb5[_0x5a8b86('0xed7')]('userProfileSection@get',{'fields':_0x5a8b86('0x1f47'),'userProfileId':_0x934aa4[_0x5a8b86('0x20b2')]()[_0x5a8b86('0x2f')],'sectionId':0x3eb});}]},'authenticate':!![],'permissionId':0x3eb,'bodyClass':_0x52f4ec('0x1f88')})['state'](_0x52f4ec('0xca7'),{'url':_0x52f4ec('0x26d1'),'views':{'content@app':{'templateUrl':_0x4cbe35,'controller':_0x52f4ec('0xf6a')}},'resolve':{'intervals':[_0x52f4ec('0x4b1'),'Auth',function(_0x5ead2f,_0x31f641){const _0x48513e=_0x52f4ec;return _0x31f641['hasRole'](_0x48513e('0x20c2'))?_0x5ead2f[_0x48513e('0xed7')]('interval@get',{'fields':_0x48513e('0x120a'),'sort':_0x48513e('0xc36'),'IntervalId':_0x48513e('0x13c'),'limit':0xa,'offset':0x0}):_0x5ead2f[_0x48513e('0xed7')](_0x48513e('0x191b'),{'id':_0x31f641[_0x48513e('0x20b2')]()[_0x48513e('0x2f')],'section':_0x48513e('0xb38'),'fields':_0x48513e('0x120a'),'sort':'-updatedAt','IntervalId':_0x48513e('0x13c'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x52f4ec('0xba1'),function(_0x307b72,_0x45204f){const _0x141650=_0x52f4ec;return _0x45204f[_0x141650('0xca1')]('admin')?null:_0x307b72['resolve'](_0x141650('0x1464'),{'fields':_0x141650('0x16f'),'id':_0x45204f['getCurrentUser']()[_0x141650('0x2f')]});}],'userProfileSection':[_0x52f4ec('0x4b1'),'Auth',function(_0x3d3581,_0x7a7531){const _0x45dc35=_0x52f4ec;return _0x7a7531[_0x45dc35('0xca1')](_0x45dc35('0x20c2'))?null:_0x3d3581['resolve'](_0x45dc35('0x360'),{'fields':_0x45dc35('0x1f47'),'userProfileId':_0x7a7531[_0x45dc35('0x20b2')]()[_0x45dc35('0x2f')],'sectionId':0x3ec});}]},'authenticate':!![],'permissionId':0x3ec,'bodyClass':_0x52f4ec('0x1f88')})['state'](_0x52f4ec('0x296'),{'url':_0x52f4ec('0x1560'),'params':{'interval':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x5f24b3,'controller':_0x52f4ec('0xbe1')}},'resolve':{'interval':[_0x52f4ec('0x4b1'),'$stateParams',function(_0xdcfe27,_0x586717){const _0x939c7f=_0x52f4ec;return _0xdcfe27[_0x939c7f('0xed7')]('interval@get',{'fields':_0x939c7f('0x120a'),'id':_0x586717['id']});}],'userProfileSection':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x156ebf,_0x5fb5c5){const _0x5b400c=_0x52f4ec;return _0x156ebf[_0x5b400c('0xed7')]('userProfileSection@get',{'fields':_0x5b400c('0x1f47'),'userProfileId':_0x5fb5c5['getCurrentUser']()[_0x5b400c('0x2f')],'sectionId':0x3ec});}]},'authenticate':!![],'permissionId':0x3ec,'bodyClass':_0x52f4ec('0x1f88')})[_0x52f4ec('0x2598')](_0x52f4ec('0x259e'),{'url':_0x52f4ec('0x16d'),'views':{'content@app':{'templateUrl':_0x597f2f,'controller':_0x52f4ec('0x27dc')}},'resolve':{'pauses':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x3440ad,_0x124502){const _0x6db37c=_0x52f4ec;return _0x124502[_0x6db37c('0xca1')](_0x6db37c('0x20c2'))?_0x3440ad['resolve'](_0x6db37c('0x112'),{'fields':_0x6db37c('0x120a'),'sort':_0x6db37c('0xc36'),'limit':0xa,'offset':0x0}):_0x3440ad[_0x6db37c('0xed7')](_0x6db37c('0x191b'),{'id':_0x124502[_0x6db37c('0x20b2')]()[_0x6db37c('0x2f')],'section':_0x6db37c('0x1dcc'),'fields':_0x6db37c('0x120a'),'sort':_0x6db37c('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x2b1e44,_0x3a315e){const _0x5b2008=_0x52f4ec;return _0x3a315e[_0x5b2008('0xca1')](_0x5b2008('0x20c2'))?null:_0x2b1e44[_0x5b2008('0xed7')](_0x5b2008('0x1464'),{'fields':'id,name,crudPermissions','id':_0x3a315e[_0x5b2008('0x20b2')]()[_0x5b2008('0x2f')]});}],'userProfileSection':['apiResolver',_0x52f4ec('0xba1'),function(_0x58790f,_0x2594db){const _0x52fd74=_0x52f4ec;return _0x2594db[_0x52fd74('0xca1')]('admin')?null:_0x58790f[_0x52fd74('0xed7')](_0x52fd74('0x360'),{'fields':_0x52fd74('0x1f47'),'userProfileId':_0x2594db['getCurrentUser']()[_0x52fd74('0x2f')],'sectionId':0x3ed});}]},'authenticate':!![],'permissionId':0x3ed,'bodyClass':_0x52f4ec('0x1f88')})['state'](_0x52f4ec('0xd3e'),{'url':_0x52f4ec('0x1f32'),'views':{'content@app':{'templateUrl':_0xc41af9,'controller':_0x52f4ec('0x1677')}},'resolve':{'schedules':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x1c6b29,_0x1d2ab2){const _0x4f3cd1=_0x52f4ec;return _0x1d2ab2[_0x4f3cd1('0xca1')](_0x4f3cd1('0x20c2'))?_0x1c6b29[_0x4f3cd1('0xed7')](_0x4f3cd1('0x94a'),{'fields':_0x4f3cd1('0x1a40'),'sort':_0x4f3cd1('0xc36'),'limit':0xa,'offset':0x0}):_0x1c6b29[_0x4f3cd1('0xed7')]('userProfile@getResources',{'id':_0x1d2ab2[_0x4f3cd1('0x20b2')]()[_0x4f3cd1('0x2f')],'section':_0x4f3cd1('0x2147'),'fields':_0x4f3cd1('0x1a40'),'sort':_0x4f3cd1('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x52f4ec('0x4b1'),'Auth',function(_0x4e46f4,_0x21a680){const _0x4eaf69=_0x52f4ec;return _0x21a680[_0x4eaf69('0xca1')](_0x4eaf69('0x20c2'))?null:_0x4e46f4[_0x4eaf69('0xed7')](_0x4eaf69('0x1464'),{'fields':_0x4eaf69('0x16f'),'id':_0x21a680[_0x4eaf69('0x20b2')]()[_0x4eaf69('0x2f')]});}],'userProfileSection':['apiResolver',_0x52f4ec('0xba1'),function(_0x389205,_0x1836ec){const _0x4cf75a=_0x52f4ec;return _0x1836ec[_0x4cf75a('0xca1')](_0x4cf75a('0x20c2'))?null:_0x389205[_0x4cf75a('0xed7')](_0x4cf75a('0x360'),{'fields':_0x4cf75a('0x1f47'),'userProfileId':_0x1836ec[_0x4cf75a('0x20b2')]()[_0x4cf75a('0x2f')],'sectionId':0x3ee});}]},'authenticate':!![],'permissionId':0x3ee,'bodyClass':_0x52f4ec('0x1f88')})[_0x52f4ec('0x2598')](_0x52f4ec('0x4c'),{'url':'/sounds','views':{'content@app':{'templateUrl':_0x1473ca,'controller':_0x52f4ec('0x1bb')}},'resolve':{'sounds':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x7f74ee,_0x56573d){const _0x679c9b=_0x52f4ec;return _0x56573d['hasRole']('admin')?_0x7f74ee['resolve']('sound@get',{'fields':_0x679c9b('0x25c1'),'sort':_0x679c9b('0xc36'),'limit':0xa,'offset':0x0}):_0x7f74ee[_0x679c9b('0xed7')](_0x679c9b('0x191b'),{'id':_0x56573d[_0x679c9b('0x20b2')]()[_0x679c9b('0x2f')],'section':_0x679c9b('0x628'),'fields':_0x679c9b('0x25c1'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x3f924f,_0x3f4ea4){const _0x28de5e=_0x52f4ec;return _0x3f4ea4[_0x28de5e('0xca1')]('admin')?null:_0x3f924f['resolve'](_0x28de5e('0x1464'),{'fields':'id,name,crudPermissions','id':_0x3f4ea4['getCurrentUser']()[_0x28de5e('0x2f')]});}],'userProfileSection':['apiResolver',_0x52f4ec('0xba1'),function(_0x87924b,_0x59da31){const _0x29272f=_0x52f4ec;return _0x59da31[_0x29272f('0xca1')](_0x29272f('0x20c2'))?null:_0x87924b[_0x29272f('0xed7')](_0x29272f('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x59da31[_0x29272f('0x20b2')]()[_0x29272f('0x2f')],'sectionId':0x3ef});}]},'authenticate':!![],'permissionId':0x3ef,'bodyClass':'tools'})[_0x52f4ec('0x2598')]('app.tools.tags',{'url':_0x52f4ec('0x24e5'),'views':{'content@app':{'templateUrl':_0x3005f2,'controller':_0x52f4ec('0x15ca')}},'resolve':{'tags':['apiResolver',_0x52f4ec('0xba1'),function(_0x15e2a1,_0x1443e7){const _0x2c1367=_0x52f4ec;return _0x1443e7[_0x2c1367('0xca1')](_0x2c1367('0x20c2'))?_0x15e2a1['resolve'](_0x2c1367('0xb55'),{'fields':'createdAt,updatedAt,id,name,description,color','sort':_0x2c1367('0xc36'),'limit':0xa,'offset':0x0}):_0x15e2a1['resolve'](_0x2c1367('0x191b'),{'id':_0x1443e7[_0x2c1367('0x20b2')]()[_0x2c1367('0x2f')],'section':'Tags','fields':_0x2c1367('0x1667'),'sort':_0x2c1367('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x4d0a6a,_0x5e448f){const _0x27da42=_0x52f4ec;return _0x5e448f[_0x27da42('0xca1')](_0x27da42('0x20c2'))?null:_0x4d0a6a['resolve']('userProfile@get',{'fields':_0x27da42('0x16f'),'id':_0x5e448f[_0x27da42('0x20b2')]()[_0x27da42('0x2f')]});}],'userProfileSection':[_0x52f4ec('0x4b1'),'Auth',function(_0x451ff5,_0x2c94f9){const _0x40e3d7=_0x52f4ec;return _0x2c94f9[_0x40e3d7('0xca1')](_0x40e3d7('0x20c2'))?null:_0x451ff5['resolve'](_0x40e3d7('0x360'),{'fields':_0x40e3d7('0x1f47'),'userProfileId':_0x2c94f9[_0x40e3d7('0x20b2')]()[_0x40e3d7('0x2f')],'sectionId':0x3f0});}]},'authenticate':!![],'permissionId':0x3f0,'bodyClass':_0x52f4ec('0x1f88')})[_0x52f4ec('0x2598')](_0x52f4ec('0x1a08'),{'url':'/templates','views':{'content@app':{'templateUrl':_0x1edf0a,'controller':_0x52f4ec('0x1fb8')}},'resolve':{'templates':['apiResolver',_0x52f4ec('0xba1'),function(_0x265d6f,_0xdc294){const _0x25751f=_0x52f4ec;return _0xdc294[_0x25751f('0xca1')]('admin')?_0x265d6f[_0x25751f('0xed7')](_0x25751f('0x256a'),{'fields':_0x25751f('0x755'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x265d6f['resolve'](_0x25751f('0x191b'),{'id':_0xdc294['getCurrentUser']()[_0x25751f('0x2f')],'section':_0x25751f('0x161d'),'fields':_0x25751f('0x755'),'sort':_0x25751f('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x2a66fe,_0x453adc){const _0x22f0c8=_0x52f4ec;return _0x453adc[_0x22f0c8('0xca1')](_0x22f0c8('0x20c2'))?null:_0x2a66fe[_0x22f0c8('0xed7')](_0x22f0c8('0x1464'),{'fields':_0x22f0c8('0x16f'),'id':_0x453adc[_0x22f0c8('0x20b2')]()[_0x22f0c8('0x2f')]});}],'userProfileSection':[_0x52f4ec('0x4b1'),'Auth',function(_0x34cd07,_0x3160a2){const _0x4c86af=_0x52f4ec;return _0x3160a2['hasRole'](_0x4c86af('0x20c2'))?null:_0x34cd07[_0x4c86af('0xed7')](_0x4c86af('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x3160a2[_0x4c86af('0x20b2')]()['userProfileId'],'sectionId':0x3f1});}]},'authenticate':!![],'permissionId':0x3f1,'bodyClass':_0x52f4ec('0x1f88')})[_0x52f4ec('0x2598')]('app.tools.trunks',{'url':_0x52f4ec('0x18ba'),'views':{'content@app':{'templateUrl':_0x2f5a52,'controller':_0x52f4ec('0x112e')}},'resolve':{'trunks':[_0x52f4ec('0x4b1'),'Auth',function(_0x31455c,_0x1d05e3){const _0x1d5950=_0x52f4ec;return _0x1d05e3[_0x1d5950('0xca1')](_0x1d5950('0x20c2'))?_0x31455c[_0x1d5950('0xed7')](_0x1d5950('0x18a8'),{'fields':_0x1d5950('0x2425'),'sort':_0x1d5950('0xc36'),'limit':0xa,'offset':0x0}):_0x31455c[_0x1d5950('0xed7')](_0x1d5950('0x191b'),{'id':_0x1d05e3[_0x1d5950('0x20b2')]()[_0x1d5950('0x2f')],'section':_0x1d5950('0x485'),'fields':_0x1d5950('0x2425'),'sort':_0x1d5950('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x52f4ec('0x4b1'),'Auth',function(_0x2148db,_0x48e091){const _0x27ebaf=_0x52f4ec;return _0x48e091[_0x27ebaf('0xca1')](_0x27ebaf('0x20c2'))?null:_0x2148db['resolve'](_0x27ebaf('0x1464'),{'fields':_0x27ebaf('0x16f'),'id':_0x48e091[_0x27ebaf('0x20b2')]()[_0x27ebaf('0x2f')]});}],'userProfileSection':['apiResolver',_0x52f4ec('0xba1'),function(_0x475993,_0x2d91aa){const _0x46cd06=_0x52f4ec;return _0x2d91aa[_0x46cd06('0xca1')](_0x46cd06('0x20c2'))?null:_0x475993[_0x46cd06('0xed7')](_0x46cd06('0x360'),{'fields':_0x46cd06('0x1f47'),'userProfileId':_0x2d91aa[_0x46cd06('0x20b2')]()[_0x46cd06('0x2f')],'sectionId':0x3f3});}]},'authenticate':!![],'permissionId':0x3f3,'bodyClass':_0x52f4ec('0x1f88')})[_0x52f4ec('0x2598')](_0x52f4ec('0xc28'),{'url':_0x52f4ec('0x1560'),'params':{'trunk':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x454471,'controller':_0x52f4ec('0x201f')}},'resolve':{'trunk':[_0x52f4ec('0x4b1'),_0x52f4ec('0x8ea'),function(_0x497dc1,_0x5db7ee){return _0x497dc1['resolve']('trunk@get',{'fields':'createdAt,updatedAt,id,name,active,host,secret,defaultuser,context,callerid,type,dtmfmode,nat,qualify,allow,insecure,call_limit,registry,description,directmedia,callcounter,fromdomain,fromuser,outboundproxy,usereqphone,trustrpid,sendrpid,encryption,port,transport,t38pt_udptl,videosupport,otherFields','id':_0x5db7ee['id']});}],'userProfileSection':[_0x52f4ec('0x4b1'),'Auth',function(_0x24ca94,_0x53d263){const _0xd146b2=_0x52f4ec;return _0x24ca94[_0xd146b2('0xed7')](_0xd146b2('0x360'),{'fields':_0xd146b2('0x1f47'),'userProfileId':_0x53d263[_0xd146b2('0x20b2')]()[_0xd146b2('0x2f')],'sectionId':0x3f3});}]},'authenticate':!![],'permissionId':0x3f3,'bodyClass':_0x52f4ec('0x1f88')})[_0x52f4ec('0x2598')](_0x52f4ec('0x26e9'),{'url':'/variables','views':{'content@app':{'templateUrl':_0x572121,'controller':_0x52f4ec('0xbe0')}},'resolve':{'variables':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x544f14,_0x51cb1a){const _0x5055ff=_0x52f4ec;return _0x51cb1a['hasRole'](_0x5055ff('0x20c2'))?_0x544f14[_0x5055ff('0xed7')](_0x5055ff('0x1716'),{'fields':_0x5055ff('0x120a'),'sort':_0x5055ff('0xc36'),'limit':0xa,'offset':0x0}):_0x544f14[_0x5055ff('0xed7')]('userProfile@getResources',{'id':_0x51cb1a[_0x5055ff('0x20b2')]()[_0x5055ff('0x2f')],'section':_0x5055ff('0x2095'),'fields':_0x5055ff('0x120a'),'sort':_0x5055ff('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x52f4ec('0x4b1'),'Auth',function(_0x376d09,_0x62012e){const _0x1faa69=_0x52f4ec;return _0x62012e[_0x1faa69('0xca1')]('admin')?null:_0x376d09[_0x1faa69('0xed7')]('userProfile@get',{'fields':_0x1faa69('0x16f'),'id':_0x62012e[_0x1faa69('0x20b2')]()[_0x1faa69('0x2f')]});}],'userProfileSection':[_0x52f4ec('0x4b1'),_0x52f4ec('0xba1'),function(_0x5ed3fb,_0x50fe8a){const _0x1d5eaa=_0x52f4ec;return _0x50fe8a[_0x1d5eaa('0xca1')]('admin')?null:_0x5ed3fb['resolve']('userProfileSection@get',{'fields':_0x1d5eaa('0x1f47'),'userProfileId':_0x50fe8a[_0x1d5eaa('0x20b2')]()['userProfileId'],'sectionId':0x3f4});}]},'authenticate':!![],'permissionId':0x3f4,'bodyClass':'tools'}),_0x454092[_0x52f4ec('0x7d2')]('app/main/apps/tools');}angular[_0x189033('0x1e26')]('app.tools',[_0x189033('0x6cf'),_0x189033('0x1ddb'),_0x189033('0x2290'),'flow',_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),_0x189033('0x2609'),_0x189033('0x273d'),_0x189033('0x76'),_0x189033('0x516'),_0x189033('0x7fa'),'mwFormUtils',_0x189033('0x3b5'),_0x189033('0x153a'),_0x189033('0x1447'),_0x189033('0x2645'),'material.components.expansionPanels',_0x189033('0x1566'),_0x189033('0x19da'),_0x189033('0x15ed'),_0x189033('0x27c5')])[_0x189033('0x272d')](_0x3ccc76)['controller']('CannedAnswersController',_0x5999df)['controller'](_0x189033('0x248b'),_0x28cc03)[_0x189033('0x1da3')]('CreateOrEditCustomDashboardDialogController',_0x512d96)[_0x189033('0x1da3')]('CustomDashboardsController',_0x1b192d)[_0x189033('0x1da3')](_0x189033('0x71d'),_0x3213bf)['controller'](_0x189033('0x156f'),_0x3ca130)['controller'](_0x189033('0x33'),_0x3dbbbf)[_0x189033('0x1da3')](_0x189033('0x1a20'),_0x13c6b1)[_0x189033('0x1da3')]('CreateOrEditIntervalDialogController',_0x22f4fd)[_0x189033('0x1da3')]('EditAppintervalDialogController',_0x548e82)[_0x189033('0x1da3')](_0x189033('0x26d9'),_0x301609)[_0x189033('0x1da3')](_0x189033('0x19e6'),_0x21e165)[_0x189033('0x1da3')](_0x189033('0x23a5'),_0x413e82)['controller'](_0x189033('0x6eb'),_0x12e4cb)[_0x189033('0x1da3')](_0x189033('0x2650'),_0x13a2b4)[_0x189033('0x1da3')](_0x189033('0x1186'),_0x154680)[_0x189033('0x1da3')](_0x189033('0x27b8'),_0x28cb23)[_0x189033('0x1da3')](_0x189033('0x1780'),_0x2610cf)[_0x189033('0x1da3')](_0x189033('0x261f'),_0x30786c)[_0x189033('0x1da3')](_0x189033('0x300'),_0x56f839)[_0x189033('0x1da3')](_0x189033('0x17b2'),_0xf98cd1)['controller'](_0x189033('0x198d'),_0xb144e8)[_0x189033('0x1da3')](_0x189033('0x182a'),_0x4eadf6)[_0x189033('0x1da3')](_0x189033('0x1ca5'),_0x341874)[_0x189033('0x1da3')]('CreateOrEditTrunkDialogController',_0xd12883)[_0x189033('0x1da3')](_0x189033('0x2390'),_0x8498f4)[_0x189033('0x1da3')]('TrunkController',_0x1e649a)[_0x189033('0x1da3')]('TrunksController',_0x20e84d)[_0x189033('0x1da3')](_0x189033('0x1a62'),_0x25464c)[_0x189033('0x1da3')](_0x189033('0x1cab'),_0x4265ad);const _0xdb16b3=_0x180212['p']+'src/js/modules/main/apps/callysquare/views/projects/projects.html/projects.html',_0x558166=_0x180212['p']+_0x189033('0x9b8');_0xcd7087[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x2063'),_0x189033('0x938'),'$q',_0x189033('0xba1'),_0x189033('0x1d70'),_0x189033('0x1248'),_0x189033('0x273a'),_0x189033('0x56b'),_0x189033('0x1373'),_0x189033('0x1134')];function _0xcd7087(_0x107223,_0x448276,_0x4d2e49,_0x528bcb,_0x751289,_0x3d1f26,_0x54c927,_0x2cb8ab,_0x403020,_0x8daee7,_0x169dac){const _0x4b96c0=_0x189033,_0x6f6313=this;_0x6f6313[_0x4b96c0('0x17f')]=[],_0x6f6313[_0x4b96c0('0xf28')]=_0x4b96c0('0x1d91'),_0x6f6313[_0x4b96c0('0x1134')]=_0x169dac,_0x6f6313[_0x4b96c0('0x273a')]=angular[_0x4b96c0('0x1a86')](_0x2cb8ab),_0x6f6313[_0x4b96c0('0xec')]=!![],_0x6f6313[_0x4b96c0('0x1248')]=_0x54c927,_0x6f6313[_0x4b96c0('0x2228')]=![],_0x6f6313[_0x4b96c0('0x1373')]=_0x8daee7;!_0x6f6313['project']&&(_0x6f6313[_0x4b96c0('0x273a')]={'name':'','description':''},_0x6f6313['title']='CALLYSQUARE.NEW_PROJECT',_0x6f6313[_0x4b96c0('0x2228')]=!![]);_0x6f6313[_0x4b96c0('0x1732')]=_0x44d464,_0x6f6313[_0x4b96c0('0x1fd')]=_0x4de40d,_0x6f6313[_0x4b96c0('0x15a4')]=_0x24c5e0,_0x6f6313[_0x4b96c0('0xf82')]=_0x265630;function _0x44d464(){const _0x1c73e9=_0x4b96c0;_0x6f6313[_0x1c73e9('0x17f')]=[],_0x403020[_0x1c73e9('0x27ea')][_0x1c73e9('0xb0a')](_0x6f6313['project'])[_0x1c73e9('0xe53')][_0x1c73e9('0x683')](function(_0x2b7bbe){const _0xf80291=_0x1c73e9;return _0x403020[_0xf80291('0xc96')][_0xf80291('0x5bf')]({'id':_0x751289[_0xf80291('0x20b2')]()['id'],'ids':[_0x2b7bbe['id']]})[_0xf80291('0xe53')],_0x2b7bbe;})[_0x1c73e9('0x683')](function(_0x3a3cd5){const _0x43e4f4=_0x1c73e9;_0x6f6313[_0x43e4f4('0x1248')][_0x43e4f4('0x1167')](_0x3a3cd5),_0x3d1f26[_0x43e4f4('0x53')]({'title':_0x43e4f4('0x610'),'msg':_0x6f6313['project'][_0x43e4f4('0x60a')]?_0x6f6313['project']['name']+'\x20has\x20been\x20created!':''}),_0x265630(_0x3a3cd5),_0x6f6313[_0x43e4f4('0x1373')]&&(_0x6f6313['newWindow']?_0x448276[_0x43e4f4('0x1614')](_0x43e4f4('0x1c44')+_0x3a3cd5['id'],_0x43e4f4('0x18b3')):_0x4d2e49['go'](_0x43e4f4('0x1c81'),{'id':_0x3a3cd5['id']}));})[_0x1c73e9('0x130a')](function(_0x3da2cb){const _0x36d99a=_0x1c73e9;if(_0x3da2cb[_0x36d99a('0x5a5')]&&_0x3da2cb[_0x36d99a('0x5a5')][_0x36d99a('0x17f')]&&_0x3da2cb[_0x36d99a('0x5a5')][_0x36d99a('0x17f')][_0x36d99a('0x1564')]){_0x6f6313[_0x36d99a('0x17f')]=_0x3da2cb[_0x36d99a('0x5a5')][_0x36d99a('0x17f')]||[{'message':_0x3da2cb[_0x36d99a('0x1ff0')](),'type':'api.squareProject.save'}];for(let _0xc39a44=0x0;_0xc39a44<_0x3da2cb[_0x36d99a('0x5a5')][_0x36d99a('0x17f')][_0x36d99a('0x1564')];_0xc39a44++){_0x3d1f26['error']({'title':_0x3da2cb[_0x36d99a('0x5a5')][_0x36d99a('0x17f')][_0xc39a44][_0x36d99a('0xcf0')],'msg':_0x3da2cb[_0x36d99a('0x5a5')][_0x36d99a('0x17f')][_0xc39a44][_0x36d99a('0x8c2')]});}}else _0x3d1f26[_0x36d99a('0x52a')]({'title':_0x3da2cb[_0x36d99a('0x13ee')]?_0x36d99a('0x2168')+_0x3da2cb[_0x36d99a('0x13ee')]+_0x36d99a('0xbf6')+_0x3da2cb[_0x36d99a('0x24a9')]:_0x36d99a('0x25bb'),'msg':_0x3da2cb[_0x36d99a('0x5a5')]?JSON[_0x36d99a('0x258a')](_0x3da2cb[_0x36d99a('0x5a5')][_0x36d99a('0x8c2')]):_0x3da2cb[_0x36d99a('0x1ff0')]()});});}function _0x4de40d(){const _0x242b42=_0x4b96c0;_0x6f6313[_0x242b42('0x17f')]=[],_0x403020[_0x242b42('0x27ea')][_0x242b42('0x2480')]({'id':_0x6f6313[_0x242b42('0x273a')]['id']},_0x6f6313['project'])[_0x242b42('0xe53')][_0x242b42('0x683')](function(_0x4e852e){const _0x540dab=_0x242b42,_0x2b7f79=_0x2e3ca0()['find'](_0x6f6313[_0x540dab('0x1248')],{'id':_0x4e852e['id']});_0x2b7f79&&_0x2e3ca0()[_0x540dab('0xf22')](_0x2b7f79,_0x4e852e),_0x3d1f26['success']({'title':_0x540dab('0x630'),'msg':_0x6f6313[_0x540dab('0x273a')][_0x540dab('0x60a')]?_0x6f6313[_0x540dab('0x273a')]['name']+_0x540dab('0xf59'):''}),_0x265630(_0x4e852e);})[_0x242b42('0x130a')](function(_0x437a01){const _0x5500bf=_0x242b42;if(_0x437a01[_0x5500bf('0x5a5')]&&_0x437a01['data']['errors']&&_0x437a01[_0x5500bf('0x5a5')][_0x5500bf('0x17f')][_0x5500bf('0x1564')]){_0x6f6313[_0x5500bf('0x17f')]=_0x437a01[_0x5500bf('0x5a5')][_0x5500bf('0x17f')]||[{'message':_0x437a01[_0x5500bf('0x1ff0')](),'type':_0x5500bf('0x24a6')}];for(let _0xf02a2b=0x0;_0xf02a2b<_0x437a01[_0x5500bf('0x5a5')][_0x5500bf('0x17f')][_0x5500bf('0x1564')];_0xf02a2b++){_0x3d1f26['error']({'title':_0x437a01[_0x5500bf('0x5a5')]['errors'][_0xf02a2b][_0x5500bf('0xcf0')],'msg':_0x437a01[_0x5500bf('0x5a5')][_0x5500bf('0x17f')][_0xf02a2b]['message']});}}else _0x3d1f26['error']({'title':_0x437a01[_0x5500bf('0x13ee')]?_0x5500bf('0x2168')+_0x437a01[_0x5500bf('0x13ee')]+'\x20-\x20'+_0x437a01[_0x5500bf('0x24a9')]:_0x5500bf('0x24a6'),'msg':_0x437a01['data']?JSON[_0x5500bf('0x258a')](_0x437a01['data'][_0x5500bf('0x8c2')]):_0x437a01[_0x5500bf('0x1ff0')]()});});}function _0x24c5e0(){const _0x441567=_0x4b96c0;_0x6f6313[_0x441567('0x17f')]=[];const _0x160e9b=_0x107223[_0x441567('0x1c6f')]()[_0x441567('0xf28')](_0x441567('0x4d'))[_0x441567('0xa6a')]('The\x20project\x20will\x20be\x20deleted.')[_0x441567('0x1040')](_0x441567('0x860'))['ok'](_0x441567('0x2307'))[_0x441567('0x19fb')]('Cancel')[_0x441567('0xe42')](event);_0x107223[_0x441567('0x1d4')](_0x160e9b)[_0x441567('0x683')](function(){const _0x3861a5=_0x441567;_0x403020[_0x3861a5('0x27ea')]['delete']({'id':_0x6f6313[_0x3861a5('0x273a')]['id']})[_0x3861a5('0xe53')]['then'](function(){const _0x4def27=_0x3861a5;return _0x403020[_0x4def27('0x27ea')][_0x4def27('0x16dc')]({'id':_0x6f6313[_0x4def27('0x273a')]['id']})['$promise'];})[_0x3861a5('0x683')](function(_0x59b1){const _0xd5af9d=_0x3861a5,_0x3f0b21=[],_0x25f7b2=_0x59b1[_0xd5af9d('0xf5d')];for(let _0x45c0e3=0x0;_0x45c0e3<_0x25f7b2['length'];_0x45c0e3++){_0x3f0b21[_0xd5af9d('0x1fd0')](_0x403020[_0xd5af9d('0xc96')][_0xd5af9d('0x24c8')]({'id':_0x751289[_0xd5af9d('0x20b2')]()['id'],'ids':[_0x6f6313['project']['id']]})['$promise']);}return _0x528bcb['all'](_0x3f0b21);})['then'](function(){const _0x5a78a8=_0x3861a5;_0x2e3ca0()[_0x5a78a8('0x3ec')](_0x6f6313[_0x5a78a8('0x1248')],{'id':_0x6f6313[_0x5a78a8('0x273a')]['id']}),_0x3d1f26[_0x5a78a8('0x53')]({'title':_0x5a78a8('0x1663'),'msg':_0x6f6313[_0x5a78a8('0x273a')][_0x5a78a8('0x60a')]?_0x6f6313['project'][_0x5a78a8('0x60a')]+_0x5a78a8('0x194d'):''}),_0x265630(_0x6f6313[_0x5a78a8('0x273a')]);})['catch'](function(_0x550af6){const _0x3ce6c8=_0x3861a5;console[_0x3ce6c8('0x52a')](_0x550af6),_0x6f6313[_0x3ce6c8('0x17f')]=_0x550af6['data'][_0x3ce6c8('0x17f')]||[{'message':_0x550af6[_0x3ce6c8('0x1ff0')](),'type':'api.squareProject.delete'}];});},function(){});}function _0x265630(_0x52d709){const _0x1a9ae6=_0x4b96c0;_0x107223[_0x1a9ae6('0x1715')](_0x52d709);}}const _0x77f9fb=_0xcd7087;_0x5c9c6a[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x56b'),'toasty','ispeechAsrModel',_0x189033('0xd54'),_0x189033('0x137a'),_0x189033('0x1399'),'googleCloudTtslanguageCode',_0x189033('0xbaa'),'users',_0x189033('0x20fe'),'queues',_0x189033('0x11d2'),_0x189033('0x220b'),_0x189033('0x5b8'),_0x189033('0x1248'),'contexts',_0x189033('0xe98'),_0x189033('0x1093'),_0x189033('0x84b'),_0x189033('0xe01'),_0x189033('0x21a3'),_0x189033('0x23ad'),_0x189033('0x10e'),_0x189033('0x1b4c'),_0x189033('0x197c'),'pauses',_0x189033('0x18a6'),'dialogFlowV2Language','awsLexRegion','Auth','crudPermissions'];function _0x5c9c6a(_0x44791a,_0x4c4cec,_0x1808c4,_0x5229d0,_0x21ef2e,_0x34fd88,_0x568330,_0x3e05f3,_0x6da9e3,_0x4c0889,_0x4ea71e,_0x1985b5,_0x5a2c04,_0x1458a5,_0x519f2b,_0x1395a0,_0x32dc4a,_0x46ca28,_0x4e0ac5,_0x561b87,_0x3b0aa0,_0x14427c,_0x34c0b1,_0x51b414,_0x200ac4,_0x32fdf7,_0x326c0f,_0x2e3555,_0x8a4d16,_0x28a723,_0x318d52,_0x35e092){const _0x34936b=_0x189033,_0x1176b6=this,_0x218dac={'playback':['file_id'],'answer':[_0x34936b('0x1668')],'menu':[_0x34936b('0x2097'),_0x34936b('0x2236'),_0x34936b('0x54a'),_0x34936b('0x65f')],'getdigits':[_0x34936b('0x2097'),'variable_id',_0x34936b('0x1af2'),_0x34936b('0x1520'),_0x34936b('0x65f')],'getsecretdigits':['file_id',_0x34936b('0x16d0'),_0x34936b('0x1af2'),_0x34936b('0x1520'),_0x34936b('0x15cc'),_0x34936b('0x65f')],'vswitch':[_0x34936b('0x16d0')],'database':[_0x34936b('0xa48'),'query'],'ext_dial':['trunk_name',_0x34936b('0xd31'),_0x34936b('0x1668')],'set':[_0x34936b('0x16d0')],'math':[_0x34936b('0x16d0')],'gotoc':['context','extension',_0x34936b('0xe1e')],'system':['command'],'agi':[_0x34936b('0x6db')],'gotoif':['condition'],'saydigits':[_0x34936b('0xce0')],'saynumber':[_0x34936b('0x121f')],'sayphonetic':[_0x34936b('0x1bcd')],'record':[_0x34936b('0x21dd'),_0x34936b('0x1668')],'goal':[_0x34936b('0x221b')],'dial':[_0x34936b('0x68d'),'timeout'],'queue':[_0x34936b('0xbe8'),_0x34936b('0x1668')],'callback':[_0x34936b('0x788'),_0x34936b('0x60a'),_0x34936b('0xd31'),_0x34936b('0x1e49')],'gotoiftime':[_0x34936b('0x1a56')],'voicemail':[_0x34936b('0x10ae')],'subproject':[_0x34936b('0x1281')],'sendSMS':[_0x34936b('0xe8'),'to','sms_text'],'sendMail':['account_id','to'],'sendFax':[_0x34936b('0x1e3f'),'to',_0x34936b('0x20f4')],'google_cloud_tts':[_0x34936b('0x1af9'),'google_cloud_tts_text_type',_0x34936b('0x1bcd')],'tts':[_0x34936b('0x1bcd')],'ispeechtts':[_0x34936b('0x1bcd'),'key',_0x34936b('0x66d')],'ispeechasr':[_0x34936b('0x1d46'),_0x34936b('0x1668')],'custom_app':[_0x34936b('0x121e')],'googleasr':[_0x34936b('0x1d46'),'timeout'],'awspolly':[_0x34936b('0x152c'),'aws_secret_access_key','text',_0x34936b('0x2701')],'lumenvoxtts':[_0x34936b('0x1bcd')],'sestektts':[_0x34936b('0x1bcd')],'lumenvoxasr':[_0x34936b('0xb99')],'sestekasr':[_0x34936b('0xb99')],'tildeasr':[_0x34936b('0x2046'),'appsecret',_0x34936b('0x933')],'login':[_0x34936b('0x115d')],'pause':[_0x34936b('0x115d'),_0x34936b('0x261b')],'unpause':[_0x34936b('0x115d')],'logout':[_0x34936b('0x115d')],'dialogflow':[_0x34936b('0x1d46'),_0x34936b('0x1bcd'),_0x34936b('0x918')],'awslex':[_0x34936b('0x152c'),_0x34936b('0x1e28'),_0x34936b('0xb88'),_0x34936b('0x2694'),_0x34936b('0x1bcd')],'sesteknda':['text',_0x34936b('0xdcf'),_0x34936b('0x1733'),_0x34936b('0x1e96'),_0x34936b('0x5be')],'restapi':[_0x34936b('0x1284'),_0x34936b('0x206a')],'mrcpsynth':[_0x34936b('0x1bcd')],'mrcprecog':[_0x34936b('0xb99')],'dialogflowV2':[_0x34936b('0x7f4'),_0x34936b('0x86f'),_0x34936b('0xdc5'),'dialogflowV2_language','text']},_0x5ad2a4={'queue':['file_id'],'database':[_0x34936b('0x16d0')],'pause':[_0x34936b('0x261b')]},_0x1f8c25={'sendMail':['to','cc',_0x34936b('0x5b0')],'voicemail':[_0x34936b('0x10ae')]};_0x1176b6[_0x34936b('0x370')]=_0x14427c[_0x34936b('0xdfb')],_0x1176b6['attributes']=_0x2e3ca0()['map'](_0x14427c['attributes'],function(_0x45fdf5){const _0x317c1d=_0x34936b;return{'name':_0x45fdf5[_0x317c1d('0x60a')],'value':_0x45fdf5[_0x317c1d('0x1c6b')],'defaultValue':_0x5ad2a4[_0x1176b6[_0x317c1d('0x370')]]&&_0x2e3ca0()['includes'](_0x5ad2a4[_0x1176b6[_0x317c1d('0x370')]],_0x45fdf5[_0x317c1d('0x60a')]),'required':_0x218dac[_0x1176b6['cellName']]&&_0x2e3ca0()['includes'](_0x218dac[_0x1176b6[_0x317c1d('0x370')]],_0x45fdf5[_0x317c1d('0x60a')]),'help':_0x1f8c25[_0x1176b6[_0x317c1d('0x370')]]&&_0x2e3ca0()[_0x317c1d('0x2292')](_0x1f8c25[_0x1176b6[_0x317c1d('0x370')]],_0x45fdf5[_0x317c1d('0x60a')])};}),_0x1176b6[_0x34936b('0x17a0')]={'authMethod':[{'value':'noauth','option':_0x34936b('0x1b5')},{'value':_0x34936b('0x98f'),'option':_0x34936b('0xf7e')}],'answer':[{'value':_0x34936b('0x7cd'),'option':'Yes'},{'value':'no','option':'No'}],'ndagenerate_audio':[{'value':0x1,'option':_0x34936b('0xe76')},{'value':0x0,'option':'No'}],'ndaactivity_type':[{'value':_0x34936b('0x8c2'),'option':_0x34936b('0x205e')},{'value':'conversationUpdate','option':'Conversation\x20Update'},{'value':'contactRelationUpdate','option':_0x34936b('0x14f8')},{'value':_0x34936b('0x1a12'),'option':_0x34936b('0x910')}],'hiddendigitspos':[{'value':'first','option':_0x34936b('0x24d4')},{'value':_0x34936b('0xc0f'),'option':_0x34936b('0x6df')}],'recordingFormat':[{'value':_0x34936b('0x1d2a'),'option':'Wav'},{'value':'gsm','option':_0x34936b('0x1fac')}],'intkey':[{'value':'#','option':'#'},{'value':'*','option':'*'}],'beep':[{'value':_0x34936b('0x1964'),'option':'Yes'},{'value':_0x34936b('0x636'),'option':'No'}],'model':_0x5229d0,'ispeech_asr_language':_0x21ef2e,'ispeech_tts_language':_0x568330,'languageCode':_0x3e05f3,'ssmlGender':[{'value':_0x34936b('0x1cd6'),'option':'Female'},{'value':_0x34936b('0x24f'),'option':_0x34936b('0x4e8')}],'google_tts_language':_0x6da9e3,'google_asr_language':_0x34fd88,'google_cloud_tts_text_type':[{'value':'text','option':_0x34936b('0x1d8c')},{'value':_0x34936b('0x2a6'),'option':_0x34936b('0x2520')}],'aws_polly_region':_0x200ac4,'aws_polly_voice':_0x51b414,'aws_text_type':[{'value':_0x34936b('0x1bcd'),'option':_0x34936b('0x1d8c')},{'value':'ssml','option':_0x34936b('0x2520')}],'callback_priority':[{'option':'Highest','value':0x4},{'option':_0x34936b('0x1526'),'value':0x3},{'option':_0x34936b('0x13e'),'value':0x2},{'option':'Low','value':0x1},{'option':'Lowest','value':0x0}],'findBy':[{'value':'internal','option':_0x34936b('0x2507')},{'value':'phone','option':_0x34936b('0x99c')},{'value':_0x34936b('0x200f'),'option':_0x34936b('0x195d')}],'dialogflow_language':_0x2e3555,'dialogflowV2_language':_0x8a4d16,'aws_lex_region':_0x28a723,'method':[{'value':'GET','option':_0x34936b('0x2270')},{'value':_0x34936b('0x1e25'),'option':_0x34936b('0x1e25')},{'value':'PUT','option':_0x34936b('0x2176')},{'value':_0x34936b('0x1266'),'option':_0x34936b('0x1266')}]},_0x1176b6[_0x34936b('0x1134')]=_0x35e092,_0x1176b6[_0x34936b('0x1dd2')]=_0x126491,_0x1176b6[_0x34936b('0xf82')]=_0x2929e4,_0x1176b6[_0x34936b('0x1417')]=_0x9d678a;function _0x126491(){const _0x7c12b=_0x34936b;_0x318d52[_0x7c12b('0xca1')]('admin')?_0x3b694():_0x271538();}function _0x9d678a(_0x4c5635,_0x260d73,_0x515288,_0x50255f){const _0x407f07=_0x34936b;return _0x2e3ca0()[_0x407f07('0x386')](_0x4c5635,function(_0x536b04){const _0x50266f=_0x407f07;return{'value':_0x536b04[_0x260d73],'option':_0x536b04[_0x515288],'group':_0x50255f?_0x536b04[_0x50255f]:undefined,'canSelect':typeof _0x536b04['canSelect']!==_0x50266f('0x1867')?_0x536b04[_0x50266f('0x319')]:!![]};});}function _0x34eebf(_0x2ceb43,_0x44b201,_0x33eafb,_0x1fc5d7){const _0x520eb1=_0x34936b,_0x27fdbc=_0x2e3ca0()[_0x520eb1('0x25')](_0x2ceb43,function(_0x4017ce){return _0x4017ce[_0x1fc5d7]===null;}),_0x6d679f=[];return _0x2e3ca0()[_0x520eb1('0x1299')](_0x27fdbc,function(_0x59c10f){const _0x5ce759=_0x520eb1;_0x6d679f['push']({'value':_0x59c10f[_0x44b201],'option':_0x59c10f[_0x33eafb]});const _0x132831=_0x2e3ca0()['filter'](_0x2ceb43,function(_0x435bfd){return _0x435bfd[_0x1fc5d7]===_0x59c10f['id'];});_0x2e3ca0()[_0x5ce759('0x1299')](_0x132831,function(_0x1d290d){const _0x531073=_0x5ce759;_0x6d679f['push']({'value':_0x1d290d[_0x44b201],'option':_0x531073('0xbf6')+_0x1d290d[_0x33eafb]});});}),_0x6d679f;}function _0x3b694(){const _0x508008=_0x34936b,_0x55663c={'sip_id':_0x9d678a(_0x4c0889,'id',_0x508008('0x11bc'),'role'),'trunk_name':_0x9d678a(_0x4ea71e,_0x508008('0x60a'),_0x508008('0x60a')),'trunk_id':_0x9d678a(_0x4ea71e,'id',_0x508008('0x60a')),'queue_id':_0x9d678a(_0x1985b5,'id',_0x508008('0x60a')),'file_id':_0x9d678a(_0x5a2c04,'id','name'),'variable_id':_0x9d678a(_0x1458a5,'id',_0x508008('0x60a')),'odbc_id':_0x9d678a(_0x519f2b,'id',_0x508008('0x60a')),'project_id':_0x9d678a(_0x1395a0,'id','name'),'context':_0x9d678a(_0x32dc4a,'id',_0x508008('0x60a')),'interval_id':_0x34eebf(_0x46ca28,'id',_0x508008('0x60a'),_0x508008('0x5ae')),'account_id':_0x9d678a(_0x4e0ac5,'id','name'),'template_id':_0x9d678a(_0x561b87,'id',_0x508008('0x60a')),'list_id':_0x9d678a(_0x3b0aa0,'id',_0x508008('0x60a')),'sms_account_id':_0x9d678a(_0x32fdf7,'id',_0x508008('0x60a')),'pause_id':_0x9d678a(_0x326c0f,'id','name')},_0x1d63b0=_0x2e3ca0()[_0x508008('0xf22')](_0x1176b6['values'],_0x55663c);_0x1176b6[_0x508008('0x17a0')]=_0x1d63b0;}function _0x271538(){const _0x5f53f8=_0x34936b,_0x576459=[_0x5f53f8('0x68d'),_0x5f53f8('0x1d86'),_0x5f53f8('0x2732'),_0x5f53f8('0xbe8'),_0x5f53f8('0x2097'),'variable_id',_0x5f53f8('0xa48'),_0x5f53f8('0x1281'),_0x5f53f8('0x22d3'),_0x5f53f8('0x1a56'),_0x5f53f8('0x1e3f'),_0x5f53f8('0x2310'),_0x5f53f8('0x788'),_0x5f53f8('0xe8'),_0x5f53f8('0x261b')];for(let _0x25fe84=0x0;_0x25fe84<_0x1176b6[_0x5f53f8('0x9c9')]['length'];_0x25fe84++){if(_0x2e3ca0()[_0x5f53f8('0x2292')](_0x576459,_0x1176b6[_0x5f53f8('0x9c9')][_0x25fe84][_0x5f53f8('0x60a')]))switch(_0x1176b6[_0x5f53f8('0x9c9')][_0x25fe84][_0x5f53f8('0x60a')]){case _0x5f53f8('0x68d'):_0x43f04f();break;case _0x5f53f8('0x1d86'):_0x1c0b89();break;case _0x5f53f8('0x2732'):_0x2a984f();break;case _0x5f53f8('0xbe8'):_0x584e68();break;case _0x5f53f8('0x2097'):_0x42717b();break;case _0x5f53f8('0x16d0'):_0x359d24();break;case _0x5f53f8('0xa48'):_0x548049();break;case _0x5f53f8('0x1281'):_0x100587();break;case'context':_0x306bfe();break;case _0x5f53f8('0x1a56'):_0x5efcc0();break;case'account_id':_0x202307();break;case _0x5f53f8('0x2310'):_0x541f1f();break;case'list_id':_0x11fd7d();break;case'sms_account_id':_0x4b603e();break;case _0x5f53f8('0x261b'):_0x3b794f();break;}}}function _0x43f04f(){const _0x4a6c90=_0x34936b,_0x324f8d=Number(_0x2e3ca0()[_0x4a6c90('0x1c07')](_0x1176b6[_0x4a6c90('0x9c9')],{'name':_0x4a6c90('0x68d')})['value']),_0x414f66=_0x2e3ca0()['some'](_0x4c0889,{'id':_0x324f8d});if(!_0x414f66&&_0x324f8d>0x0)return _0x4c4cec[_0x4a6c90('0xc96')]['get']({'id':_0x324f8d,'fields':_0x4a6c90('0x2868')})[_0x4a6c90('0xe53')][_0x4a6c90('0x683')](function(_0x448d81){const _0x3d02fa=_0x4a6c90,_0x1d5faa=_0x448d81[_0x3d02fa('0x24e1')]();_0x1d5faa[_0x3d02fa('0x319')]=![],_0x4c0889[_0x3d02fa('0x1fd0')](_0x1d5faa),_0x1176b6[_0x3d02fa('0x17a0')][_0x3d02fa('0x68d')]=_0x9d678a(_0x4c0889,'id',_0x3d02fa('0x11bc'),_0x3d02fa('0xecb'));})[_0x4a6c90('0x130a')](function(_0x12b894){const _0x237ea6=_0x4a6c90;_0x1808c4['error']({'title':_0x12b894[_0x237ea6('0x13ee')]?_0x237ea6('0x2168')+_0x12b894[_0x237ea6('0x13ee')]+_0x237ea6('0xbf6')+_0x12b894[_0x237ea6('0x24a9')]:_0x237ea6('0xa0c'),'msg':_0x12b894[_0x237ea6('0x5a5')]?JSON[_0x237ea6('0x258a')](_0x12b894['data'][_0x237ea6('0x8c2')]):_0x12b894[_0x237ea6('0x1ff0')]()});});else _0x1176b6[_0x4a6c90('0x17a0')][_0x4a6c90('0x68d')]=_0x9d678a(_0x4c0889,'id',_0x4a6c90('0x11bc'),'role');}function _0x11fd7d(){const _0x56b144=_0x34936b,_0x169a1b=Number(_0x2e3ca0()[_0x56b144('0x1c07')](_0x1176b6[_0x56b144('0x9c9')],{'name':_0x56b144('0x788')})['value']),_0x1679e6=_0x2e3ca0()[_0x56b144('0x7a2')](_0x3b0aa0,{'id':_0x169a1b});if(!_0x1679e6&&_0x169a1b>0x0)return _0x4c4cec[_0x56b144('0x259b')][_0x56b144('0x1e6e')]({'id':_0x169a1b,'fields':'id,name'})[_0x56b144('0xe53')]['then'](function(_0x1256b0){const _0x4dc604=_0x56b144,_0xb9a53c=_0x1256b0[_0x4dc604('0x24e1')]();_0xb9a53c[_0x4dc604('0x319')]=![],_0x3b0aa0['push'](_0xb9a53c),_0x1176b6[_0x4dc604('0x17a0')][_0x4dc604('0x788')]=_0x9d678a(_0x3b0aa0,'id',_0x4dc604('0x60a'));})[_0x56b144('0x130a')](function(_0x27394e){const _0x5ae22c=_0x56b144;_0x1808c4['error']({'title':_0x27394e[_0x5ae22c('0x13ee')]?'API:'+_0x27394e[_0x5ae22c('0x13ee')]+'\x20-\x20'+_0x27394e[_0x5ae22c('0x24a9')]:'GET_LIST','msg':_0x27394e[_0x5ae22c('0x5a5')]?JSON[_0x5ae22c('0x258a')](_0x27394e['data'][_0x5ae22c('0x8c2')]):_0x27394e['toString']()});});else _0x1176b6[_0x56b144('0x17a0')][_0x56b144('0x788')]=_0x9d678a(_0x3b0aa0,'id',_0x56b144('0x60a'));}function _0x2a984f(){const _0x438771=_0x34936b,_0x51608a=Number(_0x2e3ca0()[_0x438771('0x1c07')](_0x1176b6[_0x438771('0x9c9')],{'name':_0x438771('0x2732')})[_0x438771('0x1c6b')]),_0x39f7ea=_0x2e3ca0()[_0x438771('0x7a2')](_0x4ea71e,{'id':_0x51608a});if(!_0x39f7ea&&_0x51608a>0x0)return _0x4c4cec['trunk'][_0x438771('0x1e6e')]({'id':_0x51608a,'fields':_0x438771('0xa10')})[_0x438771('0xe53')][_0x438771('0x683')](function(_0x37b96d){const _0x3c128a=_0x438771,_0x453f00=_0x37b96d[_0x3c128a('0x24e1')]();_0x453f00['canSelect']=![],_0x4ea71e['push'](_0x453f00),_0x1176b6[_0x3c128a('0x17a0')][_0x3c128a('0x2732')]=_0x9d678a(_0x4ea71e,'id','name');})[_0x438771('0x130a')](function(_0x386bdb){const _0x3aa66b=_0x438771;_0x1808c4[_0x3aa66b('0x52a')]({'title':_0x386bdb[_0x3aa66b('0x13ee')]?_0x3aa66b('0x2168')+_0x386bdb[_0x3aa66b('0x13ee')]+'\x20-\x20'+_0x386bdb[_0x3aa66b('0x24a9')]:_0x3aa66b('0x27a1'),'msg':_0x386bdb['data']?JSON[_0x3aa66b('0x258a')](_0x386bdb['data'][_0x3aa66b('0x8c2')]):_0x386bdb[_0x3aa66b('0x1ff0')]()});});else _0x1176b6[_0x438771('0x17a0')][_0x438771('0x2732')]=_0x9d678a(_0x4ea71e,'id',_0x438771('0x60a'));}function _0x1c0b89(){const _0x8a3d5d=_0x34936b,_0x504bb=_0x2e3ca0()[_0x8a3d5d('0x1c07')](_0x1176b6['attributes'],{'name':_0x8a3d5d('0x1d86')})[_0x8a3d5d('0x1c6b')],_0x1e204f=_0x2e3ca0()[_0x8a3d5d('0x7a2')](_0x4ea71e,{'name':_0x504bb});if(!_0x1e204f&&_0x504bb)return _0x4c4cec['trunk'][_0x8a3d5d('0x1e6e')]({'name':_0x504bb,'fields':_0x8a3d5d('0xa10')})[_0x8a3d5d('0xe53')][_0x8a3d5d('0x683')](function(_0x4e482f){const _0x493e14=_0x8a3d5d;if(_0x4e482f[_0x493e14('0x50d')]>0x0&&_0x4e482f[_0x493e14('0xf5d')][_0x493e14('0x1564')]>0x0){const _0x29b5a4=_0x4e482f[_0x493e14('0xf5d')][0x0];_0x29b5a4[_0x493e14('0x319')]=![],_0x4ea71e[_0x493e14('0x1fd0')](_0x29b5a4),_0x1176b6[_0x493e14('0x17a0')][_0x493e14('0x1d86')]=_0x9d678a(_0x4ea71e,_0x493e14('0x60a'),_0x493e14('0x60a'));}})[_0x8a3d5d('0x130a')](function(_0x358224){const _0x2b5599=_0x8a3d5d;_0x1808c4['error']({'title':_0x358224['status']?_0x2b5599('0x2168')+_0x358224['status']+_0x2b5599('0xbf6')+_0x358224[_0x2b5599('0x24a9')]:_0x2b5599('0x27a1'),'msg':_0x358224[_0x2b5599('0x5a5')]?JSON['stringify'](_0x358224[_0x2b5599('0x5a5')][_0x2b5599('0x8c2')]):_0x358224[_0x2b5599('0x1ff0')]()});});else _0x1176b6[_0x8a3d5d('0x17a0')][_0x8a3d5d('0x1d86')]=_0x9d678a(_0x4ea71e,'name',_0x8a3d5d('0x60a'));}function _0x584e68(){const _0xe46b7b=_0x34936b,_0x1fd213=Number(_0x2e3ca0()['find'](_0x1176b6[_0xe46b7b('0x9c9')],{'name':_0xe46b7b('0xbe8')})['value']),_0x1e9c49=_0x2e3ca0()[_0xe46b7b('0x7a2')](_0x1985b5,{'id':_0x1fd213});if(!_0x1e9c49&&_0x1fd213>0x0)return _0x4c4cec[_0xe46b7b('0x204c')]['get']({'id':_0x1fd213,'fields':_0xe46b7b('0xa10')})[_0xe46b7b('0xe53')][_0xe46b7b('0x683')](function(_0x410b9c){const _0xad1e52=_0xe46b7b,_0x3d113c=_0x410b9c[_0xad1e52('0x24e1')]();_0x3d113c[_0xad1e52('0x319')]=![],_0x1985b5['push'](_0x3d113c),_0x1176b6[_0xad1e52('0x17a0')][_0xad1e52('0xbe8')]=_0x9d678a(_0x1985b5,'id','name');})[_0xe46b7b('0x130a')](function(_0x5e5c14){const _0x10baf0=_0xe46b7b;_0x1808c4[_0x10baf0('0x52a')]({'title':_0x5e5c14[_0x10baf0('0x13ee')]?_0x10baf0('0x2168')+_0x5e5c14['status']+'\x20-\x20'+_0x5e5c14['statusText']:_0x10baf0('0x143c'),'msg':_0x5e5c14[_0x10baf0('0x5a5')]?JSON[_0x10baf0('0x258a')](_0x5e5c14[_0x10baf0('0x5a5')][_0x10baf0('0x8c2')]):_0x5e5c14[_0x10baf0('0x1ff0')]()});});else _0x1176b6[_0xe46b7b('0x17a0')]['queue_id']=_0x9d678a(_0x1985b5,'id',_0xe46b7b('0x60a'));}function _0x42717b(){const _0x4f0908=_0x34936b,_0xcbc35e=Number(_0x2e3ca0()[_0x4f0908('0x1c07')](_0x1176b6[_0x4f0908('0x9c9')],{'name':_0x4f0908('0x2097')})[_0x4f0908('0x1c6b')]),_0x2674e1=_0x2e3ca0()[_0x4f0908('0x7a2')](_0x5a2c04,{'id':_0xcbc35e});if(!_0x2674e1&&_0xcbc35e>0x0)return _0x4c4cec[_0x4f0908('0x1638')][_0x4f0908('0x1e6e')]({'id':_0xcbc35e,'fields':_0x4f0908('0xa10')})['$promise'][_0x4f0908('0x683')](function(_0xb486b5){const _0x2c1c0b=_0x4f0908,_0x42f44f=_0xb486b5[_0x2c1c0b('0x24e1')]();_0x42f44f[_0x2c1c0b('0x319')]=![],_0x5a2c04['push'](_0x42f44f),_0x1176b6[_0x2c1c0b('0x17a0')][_0x2c1c0b('0x2097')]=_0x9d678a(_0x5a2c04,'id',_0x2c1c0b('0x60a'));})[_0x4f0908('0x130a')](function(_0x4f3b54){const _0x53cb68=_0x4f0908;_0x1808c4['error']({'title':_0x4f3b54[_0x53cb68('0x13ee')]?_0x53cb68('0x2168')+_0x4f3b54[_0x53cb68('0x13ee')]+'\x20-\x20'+_0x4f3b54[_0x53cb68('0x24a9')]:_0x53cb68('0xe95'),'msg':_0x4f3b54[_0x53cb68('0x5a5')]?JSON[_0x53cb68('0x258a')](_0x4f3b54['data'][_0x53cb68('0x8c2')]):_0x4f3b54[_0x53cb68('0x1ff0')]()});});else _0x1176b6[_0x4f0908('0x17a0')][_0x4f0908('0x2097')]=_0x9d678a(_0x5a2c04,'id','name');}function _0x359d24(){const _0x497ce2=_0x34936b,_0xcbfe8f=Number(_0x2e3ca0()[_0x497ce2('0x1c07')](_0x1176b6[_0x497ce2('0x9c9')],{'name':'variable_id'})[_0x497ce2('0x1c6b')]),_0x41fe6d=_0x2e3ca0()[_0x497ce2('0x7a2')](_0x1458a5,{'id':_0xcbfe8f});if(!_0x41fe6d&&_0xcbfe8f>0x0)return _0x4c4cec[_0x497ce2('0x26e0')][_0x497ce2('0x1e6e')]({'id':_0xcbfe8f,'fields':_0x497ce2('0xa10')})[_0x497ce2('0xe53')]['then'](function(_0x550067){const _0x13d04c=_0x497ce2,_0x9d3068=_0x550067['toJSON']();_0x9d3068[_0x13d04c('0x319')]=![],_0x1458a5[_0x13d04c('0x1fd0')](_0x9d3068),_0x1176b6['values'][_0x13d04c('0x16d0')]=_0x9d678a(_0x1458a5,'id',_0x13d04c('0x60a'));})[_0x497ce2('0x130a')](function(_0x4f235c){const _0x45f3dd=_0x497ce2;_0x1808c4['error']({'title':_0x4f235c[_0x45f3dd('0x13ee')]?_0x45f3dd('0x2168')+_0x4f235c[_0x45f3dd('0x13ee')]+_0x45f3dd('0xbf6')+_0x4f235c['statusText']:_0x45f3dd('0x589'),'msg':_0x4f235c[_0x45f3dd('0x5a5')]?JSON['stringify'](_0x4f235c[_0x45f3dd('0x5a5')]['message']):_0x4f235c[_0x45f3dd('0x1ff0')]()});});else _0x1176b6[_0x497ce2('0x17a0')][_0x497ce2('0x16d0')]=_0x9d678a(_0x1458a5,'id',_0x497ce2('0x60a'));}function _0x548049(){const _0x1aeff6=_0x34936b,_0x368ad4=Number(_0x2e3ca0()['find'](_0x1176b6[_0x1aeff6('0x9c9')],{'name':_0x1aeff6('0xa48')})[_0x1aeff6('0x1c6b')]),_0x2037d2=_0x2e3ca0()[_0x1aeff6('0x7a2')](_0x519f2b,{'id':_0x368ad4});if(!_0x2037d2&&_0x368ad4>0x0)return _0x4c4cec[_0x1aeff6('0x39a')][_0x1aeff6('0x1e6e')]({'id':_0x368ad4,'fields':_0x1aeff6('0xa10')})[_0x1aeff6('0xe53')][_0x1aeff6('0x683')](function(_0x390aaa){const _0x2e2019=_0x1aeff6,_0x8049cc=_0x390aaa['toJSON']();_0x8049cc[_0x2e2019('0x319')]=![],_0x519f2b[_0x2e2019('0x1fd0')](_0x8049cc),_0x1176b6[_0x2e2019('0x17a0')]['odbc_id']=_0x9d678a(_0x519f2b,'id',_0x2e2019('0x60a'));})[_0x1aeff6('0x130a')](function(_0x3e3b89){const _0x331180=_0x1aeff6;_0x1808c4[_0x331180('0x52a')]({'title':_0x3e3b89['status']?_0x331180('0x2168')+_0x3e3b89['status']+'\x20-\x20'+_0x3e3b89[_0x331180('0x24a9')]:_0x331180('0x1783'),'msg':_0x3e3b89['data']?JSON[_0x331180('0x258a')](_0x3e3b89[_0x331180('0x5a5')][_0x331180('0x8c2')]):_0x3e3b89[_0x331180('0x1ff0')]()});});else _0x1176b6[_0x1aeff6('0x17a0')][_0x1aeff6('0xa48')]=_0x9d678a(_0x519f2b,'id',_0x1aeff6('0x60a'));}function _0x100587(){const _0x1cd235=_0x34936b,_0x5a8c39=Number(_0x2e3ca0()[_0x1cd235('0x1c07')](_0x1176b6['attributes'],{'name':_0x1cd235('0x1281')})[_0x1cd235('0x1c6b')]),_0xc638e=_0x2e3ca0()[_0x1cd235('0x7a2')](_0x1395a0,{'id':_0x5a8c39});if(!_0xc638e&&_0x5a8c39>0x0)return _0x4c4cec[_0x1cd235('0x27ea')][_0x1cd235('0x1e6e')]({'id':_0x5a8c39,'fields':_0x1cd235('0xa10')})[_0x1cd235('0xe53')][_0x1cd235('0x683')](function(_0x3a0c27){const _0x3500f6=_0x1cd235,_0x4e4782=_0x3a0c27[_0x3500f6('0x24e1')]();_0x4e4782[_0x3500f6('0x319')]=![],_0x1395a0[_0x3500f6('0x1fd0')](_0x4e4782),_0x1176b6[_0x3500f6('0x17a0')][_0x3500f6('0x1281')]=_0x9d678a(_0x1395a0,'id','name');})[_0x1cd235('0x130a')](function(_0x9e0487){const _0x410728=_0x1cd235;_0x1808c4[_0x410728('0x52a')]({'title':_0x9e0487['status']?_0x410728('0x2168')+_0x9e0487[_0x410728('0x13ee')]+_0x410728('0xbf6')+_0x9e0487['statusText']:_0x410728('0x14db'),'msg':_0x9e0487['data']?JSON[_0x410728('0x258a')](_0x9e0487[_0x410728('0x5a5')][_0x410728('0x8c2')]):_0x9e0487[_0x410728('0x1ff0')]()});});else _0x1176b6[_0x1cd235('0x17a0')][_0x1cd235('0x1281')]=_0x9d678a(_0x1395a0,'id',_0x1cd235('0x60a'));}function _0x306bfe(){const _0x17868c=_0x34936b,_0xf4f6a6=Number(_0x2e3ca0()[_0x17868c('0x1c07')](_0x1176b6['attributes'],{'name':_0x17868c('0x22d3')})[_0x17868c('0x1c6b')]),_0x10d673=_0x2e3ca0()[_0x17868c('0x7a2')](_0x32dc4a,{'id':_0xf4f6a6});if(!_0x10d673&&_0xf4f6a6>0x0)return _0x4c4cec['voiceContext'][_0x17868c('0x1e6e')]({'id':_0xf4f6a6,'fields':_0x17868c('0xa10')})[_0x17868c('0xe53')][_0x17868c('0x683')](function(_0x5827ab){const _0x29bed9=_0x17868c,_0x2158d6=_0x5827ab[_0x29bed9('0x24e1')]();_0x2158d6[_0x29bed9('0x319')]=![],_0x32dc4a[_0x29bed9('0x1fd0')](_0x2158d6),_0x1176b6['values'][_0x29bed9('0x22d3')]=_0x9d678a(_0x32dc4a,'id',_0x29bed9('0x60a'));})[_0x17868c('0x130a')](function(_0x158869){const _0x5777a6=_0x17868c;_0x1808c4[_0x5777a6('0x52a')]({'title':_0x158869[_0x5777a6('0x13ee')]?'API:'+_0x158869[_0x5777a6('0x13ee')]+_0x5777a6('0xbf6')+_0x158869[_0x5777a6('0x24a9')]:_0x5777a6('0x18bc'),'msg':_0x158869[_0x5777a6('0x5a5')]?JSON[_0x5777a6('0x258a')](_0x158869[_0x5777a6('0x5a5')][_0x5777a6('0x8c2')]):_0x158869[_0x5777a6('0x1ff0')]()});});else _0x1176b6[_0x17868c('0x17a0')][_0x17868c('0x22d3')]=_0x9d678a(_0x32dc4a,'id','name');}function _0x5efcc0(){const _0xbf4f9c=_0x34936b,_0x52c21d=Number(_0x2e3ca0()[_0xbf4f9c('0x1c07')](_0x1176b6[_0xbf4f9c('0x9c9')],{'name':_0xbf4f9c('0x1a56')})[_0xbf4f9c('0x1c6b')]),_0x49d522=_0x2e3ca0()[_0xbf4f9c('0x7a2')](_0x46ca28,{'id':_0x52c21d});if(!_0x49d522&&_0x52c21d>0x0)return _0x4c4cec[_0xbf4f9c('0x115c')][_0xbf4f9c('0x1e6e')]({'id':_0x52c21d,'fields':'id,name,IntervalId'})[_0xbf4f9c('0xe53')]['then'](function(_0x35a343){const _0x564e89=_0xbf4f9c,_0x1f84f0=_0x35a343[_0x564e89('0x24e1')]();_0x1f84f0[_0x564e89('0x319')]=![],_0x46ca28['push'](_0x1f84f0),_0x1176b6['values']['interval_id']=_0x9d678a(_0x46ca28,'id','name','IntervalId');})[_0xbf4f9c('0x130a')](function(_0x4f1ac7){const _0x76dc59=_0xbf4f9c;_0x1808c4[_0x76dc59('0x52a')]({'title':_0x4f1ac7[_0x76dc59('0x13ee')]?'API:'+_0x4f1ac7[_0x76dc59('0x13ee')]+_0x76dc59('0xbf6')+_0x4f1ac7['statusText']:_0x76dc59('0x1277'),'msg':_0x4f1ac7[_0x76dc59('0x5a5')]?JSON['stringify'](_0x4f1ac7[_0x76dc59('0x5a5')][_0x76dc59('0x8c2')]):_0x4f1ac7[_0x76dc59('0x1ff0')]()});});else _0x1176b6[_0xbf4f9c('0x17a0')][_0xbf4f9c('0x1a56')]=_0x9d678a(_0x46ca28,'id',_0xbf4f9c('0x60a'),_0xbf4f9c('0x5ae'));}function _0x202307(){const _0xc4347d=_0x34936b,_0x106ff8=Number(_0x2e3ca0()['find'](_0x1176b6[_0xc4347d('0x9c9')],{'name':_0xc4347d('0x1e3f')})['value']),_0x301fe6=_0x2e3ca0()[_0xc4347d('0x7a2')](_0x4e0ac5,{'id':_0x106ff8});if(!_0x301fe6&&_0x106ff8>0x0)return _0x4c4cec['mailAccount'][_0xc4347d('0x1e6e')]({'id':_0x106ff8,'fields':'id,name'})['$promise'][_0xc4347d('0x683')](function(_0x5677a2){const _0x428fb1=_0xc4347d,_0x2f80b8=_0x5677a2[_0x428fb1('0x24e1')]();_0x2f80b8[_0x428fb1('0x319')]=![],_0x4e0ac5[_0x428fb1('0x1fd0')](_0x2f80b8),_0x1176b6[_0x428fb1('0x17a0')][_0x428fb1('0x1e3f')]=_0x9d678a(_0x4e0ac5,'id','name');})[_0xc4347d('0x130a')](function(_0x39fd2e){const _0x196d42=_0xc4347d;_0x1808c4[_0x196d42('0x52a')]({'title':_0x39fd2e[_0x196d42('0x13ee')]?_0x196d42('0x2168')+_0x39fd2e['status']+_0x196d42('0xbf6')+_0x39fd2e[_0x196d42('0x24a9')]:_0x196d42('0x7b4'),'msg':_0x39fd2e[_0x196d42('0x5a5')]?JSON[_0x196d42('0x258a')](_0x39fd2e[_0x196d42('0x5a5')]['message']):_0x39fd2e[_0x196d42('0x1ff0')]()});});else _0x1176b6[_0xc4347d('0x17a0')][_0xc4347d('0x1e3f')]=_0x9d678a(_0x4e0ac5,'id',_0xc4347d('0x60a'));}function _0x4b603e(){const _0x48c211=_0x34936b,_0x320dd4=Number(_0x2e3ca0()['find'](_0x1176b6[_0x48c211('0x9c9')],{'name':_0x48c211('0xe8')})[_0x48c211('0x1c6b')]),_0x283349=_0x2e3ca0()[_0x48c211('0x7a2')](_0x32fdf7,{'id':_0x320dd4});if(!_0x283349&&_0x320dd4>0x0)return _0x4c4cec[_0x48c211('0xa0e')][_0x48c211('0x1e6e')]({'id':_0x320dd4,'fields':_0x48c211('0xa10')})[_0x48c211('0xe53')]['then'](function(_0x5ddfc6){const _0x3239f7=_0x48c211,_0x17f759=_0x5ddfc6[_0x3239f7('0x24e1')]();_0x17f759['canSelect']=![],_0x32fdf7[_0x3239f7('0x1fd0')](_0x17f759),_0x1176b6[_0x3239f7('0x17a0')][_0x3239f7('0xe8')]=_0x9d678a(_0x32fdf7,'id','name');})[_0x48c211('0x130a')](function(_0x55a6a6){const _0x19b1d9=_0x48c211;_0x1808c4['error']({'title':_0x55a6a6[_0x19b1d9('0x13ee')]?'API:'+_0x55a6a6[_0x19b1d9('0x13ee')]+_0x19b1d9('0xbf6')+_0x55a6a6[_0x19b1d9('0x24a9')]:'GET_SMS_ACCOUNT','msg':_0x55a6a6[_0x19b1d9('0x5a5')]?JSON[_0x19b1d9('0x258a')](_0x55a6a6[_0x19b1d9('0x5a5')][_0x19b1d9('0x8c2')]):_0x55a6a6[_0x19b1d9('0x1ff0')]()});});else _0x1176b6[_0x48c211('0x17a0')][_0x48c211('0xe8')]=_0x9d678a(_0x32fdf7,'id','name');}function _0x541f1f(){const _0x1a8804=_0x34936b,_0x254360=Number(_0x2e3ca0()[_0x1a8804('0x1c07')](_0x1176b6[_0x1a8804('0x9c9')],{'name':_0x1a8804('0x2310')})[_0x1a8804('0x1c6b')]),_0x2eee22=_0x2e3ca0()[_0x1a8804('0x7a2')](_0x561b87,{'id':_0x254360});if(!_0x2eee22&&_0x254360>0x0)return _0x4c4cec[_0x1a8804('0x1cc6')][_0x1a8804('0x1e6e')]({'id':_0x254360,'fields':'id,name'})[_0x1a8804('0xe53')][_0x1a8804('0x683')](function(_0x3bffb7){const _0x3b8903=_0x1a8804,_0x267230=_0x3bffb7['toJSON']();_0x267230[_0x3b8903('0x319')]=![],_0x561b87['push'](_0x267230),_0x1176b6[_0x3b8903('0x17a0')][_0x3b8903('0x2310')]=_0x9d678a(_0x561b87,'id',_0x3b8903('0x60a'));})[_0x1a8804('0x130a')](function(_0x24cc9d){const _0x3e32cc=_0x1a8804;_0x1808c4[_0x3e32cc('0x52a')]({'title':_0x24cc9d[_0x3e32cc('0x13ee')]?_0x3e32cc('0x2168')+_0x24cc9d[_0x3e32cc('0x13ee')]+_0x3e32cc('0xbf6')+_0x24cc9d['statusText']:_0x3e32cc('0x29a'),'msg':_0x24cc9d[_0x3e32cc('0x5a5')]?JSON['stringify'](_0x24cc9d[_0x3e32cc('0x5a5')]['message']):_0x24cc9d[_0x3e32cc('0x1ff0')]()});});else _0x1176b6[_0x1a8804('0x17a0')][_0x1a8804('0x2310')]=_0x9d678a(_0x561b87,'id',_0x1a8804('0x60a'));}function _0x3b794f(){const _0x2577ce=_0x34936b,_0x4cf82b=Number(_0x2e3ca0()[_0x2577ce('0x1c07')](_0x1176b6[_0x2577ce('0x9c9')],{'name':_0x2577ce('0x261b')})[_0x2577ce('0x1c6b')]),_0x57defa=_0x2e3ca0()['some'](_0x326c0f,{'id':_0x4cf82b});if(!_0x57defa&&_0x4cf82b>0x0)return _0x4c4cec['pause'][_0x2577ce('0x1e6e')]({'id':_0x4cf82b,'fields':_0x2577ce('0xa10')})[_0x2577ce('0xe53')][_0x2577ce('0x683')](function(_0x46e018){const _0x125e88=_0x2577ce,_0x48b880=_0x46e018['toJSON']();_0x48b880[_0x125e88('0x319')]=![],_0x326c0f[_0x125e88('0x1fd0')](_0x48b880),_0x1176b6['values'][_0x125e88('0x261b')]=_0x9d678a(_0x326c0f,'id',_0x125e88('0x60a'));})[_0x2577ce('0x130a')](function(_0x1eb86b){const _0x2f2f8f=_0x2577ce;_0x1808c4['error']({'title':_0x1eb86b[_0x2f2f8f('0x13ee')]?_0x2f2f8f('0x2168')+_0x1eb86b[_0x2f2f8f('0x13ee')]+'\x20-\x20'+_0x1eb86b[_0x2f2f8f('0x24a9')]:'GET_PAUSE','msg':_0x1eb86b[_0x2f2f8f('0x5a5')]?JSON[_0x2f2f8f('0x258a')](_0x1eb86b['data'][_0x2f2f8f('0x8c2')]):_0x1eb86b[_0x2f2f8f('0x1ff0')]()});});else _0x1176b6['values'][_0x2577ce('0x261b')]=_0x9d678a(_0x326c0f,'id','name');}function _0x2929e4(_0x40d51f){const _0x23a8a6=_0x34936b;_0x40d51f&&_0x34c0b1(_0x1176b6[_0x23a8a6('0x9c9')]),_0x44791a[_0x23a8a6('0x1715')]();}}const _0x5767a0=_0x5c9c6a;function _0x5d2ad7(){const _0x10cfe5=_0x189033;return{'require':_0x10cfe5('0x1f60'),'link':function(_0x25a7b8,_0x1b106f,_0x50a9c9,_0x412cc8){const _0x5ba568=_0x10cfe5;_0x412cc8['$parsers'][_0x5ba568('0x1fd0')](function(_0x19c735){return''+_0x19c735;}),_0x412cc8['$formatters'][_0x5ba568('0x1fd0')](function(_0x348439){return parseFloat(_0x348439);});}};}const _0x22bd63=_0x5d2ad7;function _0x10f3d9(){const _0x2a8486=_0x189033;return[{'value':'da','option':_0x2a8486('0x17d9')},{'value':'en','option':_0x2a8486('0xf48')},{'value':'de','option':_0x2a8486('0x118e')},{'value':'it','option':_0x2a8486('0x2217')},{'value':'es','option':_0x2a8486('0xbe9')},{'value':'fr','option':_0x2a8486('0x51a')},{'value':'id','option':_0x2a8486('0x9ec')},{'value':'ja','option':'Japanese'},{'value':'ko','option':_0x2a8486('0x4b5')},{'value':'nl','option':_0x2a8486('0xe03')},{'value':'no','option':_0x2a8486('0x1e53')},{'value':'pt','option':'Portuguese\x20(European)'},{'value':_0x2a8486('0x509'),'option':_0x2a8486('0x521')},{'value':'ru','option':_0x2a8486('0x103e')},{'value':'sv','option':_0x2a8486('0x1ff5')},{'value':'th','option':_0x2a8486('0xbc')},{'value':'uk','option':_0x2a8486('0x965')},{'value':'zh-CN','option':_0x2a8486('0x277f')},{'value':_0x2a8486('0x1139'),'option':'Chinese\x20(Hong\x20Kong)'},{'value':_0x2a8486('0x26bd'),'option':_0x2a8486('0x700')}];}function _0x2a39c1(){const _0x511bb3=_0x189033;return[{'value':_0x511bb3('0x1139'),'option':_0x511bb3('0x1de6')},{'value':'zh-CN','option':_0x511bb3('0x277f')},{'value':_0x511bb3('0x26bd'),'option':'Chinese\x20(Traditional)'},{'value':'da','option':_0x511bb3('0x17d9')},{'value':'nl','option':'Dutch'},{'value':'en','option':_0x511bb3('0xf48')},{'value':_0x511bb3('0x286'),'option':_0x511bb3('0xbc1')},{'value':_0x511bb3('0x117b'),'option':_0x511bb3('0x6fa')},{'value':_0x511bb3('0x3d7'),'option':_0x511bb3('0x1e8')},{'value':_0x511bb3('0x1aac'),'option':_0x511bb3('0xa57')},{'value':'en-US','option':_0x511bb3('0x40b')},{'value':'fr','option':_0x511bb3('0x51a')},{'value':_0x511bb3('0x333'),'option':_0x511bb3('0x842')},{'value':_0x511bb3('0x12fc'),'option':_0x511bb3('0x1037')},{'value':'de','option':_0x511bb3('0x118e')},{'value':'hi','option':_0x511bb3('0x81c')},{'value':'id','option':_0x511bb3('0x9ec')},{'value':'it','option':_0x511bb3('0x2217')},{'value':'ja','option':'Japanese'},{'value':'ko','option':_0x511bb3('0x233a')},{'value':'no','option':_0x511bb3('0x1e53')},{'value':'pl','option':_0x511bb3('0x10a7')},{'value':_0x511bb3('0x56c'),'option':_0x511bb3('0x15b3')},{'value':_0x511bb3('0xa21'),'option':_0x511bb3('0x1876')},{'value':'ru','option':_0x511bb3('0x103e')},{'value':'es','option':_0x511bb3('0xbe9')},{'value':_0x511bb3('0x7e5'),'option':_0x511bb3('0x1e41')},{'value':_0x511bb3('0x45c'),'option':_0x511bb3('0x208e')},{'value':'sw','option':_0x511bb3('0x1ff5')},{'value':'th','option':_0x511bb3('0xbc')},{'value':'tr','option':'Turkish'},{'value':'uk','option':'Ukrainian'}];}function _0x5a5185(){const _0x1cfc3b=_0x189033;return[{'value':_0x1cfc3b('0xba9'),'option':_0x1cfc3b('0x205a')},{'value':'cs-CZ','option':'Czech\x20(Czech\x20Republic)'},{'value':_0x1cfc3b('0x488'),'option':_0x1cfc3b('0x15a1')},{'value':'de-DE','option':_0x1cfc3b('0x2018')},{'value':_0x1cfc3b('0x133d'),'option':_0x1cfc3b('0x8bf')},{'value':_0x1cfc3b('0x286'),'option':_0x1cfc3b('0xbdc')},{'value':_0x1cfc3b('0x1aac'),'option':'English\x20(India)'},{'value':_0x1cfc3b('0x3d7'),'option':_0x1cfc3b('0x1d29')},{'value':'en-US','option':'English\x20(US)'},{'value':_0x1cfc3b('0x175f'),'option':_0x1cfc3b('0x12ad')},{'value':'fil-PH','option':_0x1cfc3b('0x1c61')},{'value':_0x1cfc3b('0x333'),'option':_0x1cfc3b('0x842')},{'value':'fr-FR','option':_0x1cfc3b('0x433')},{'value':'hi-IN','option':_0x1cfc3b('0x2317')},{'value':_0x1cfc3b('0x2823'),'option':'Hungarian\x20(Hungary)'},{'value':'id-ID','option':_0x1cfc3b('0x102d')},{'value':_0x1cfc3b('0x1ee8'),'option':_0x1cfc3b('0x2504')},{'value':_0x1cfc3b('0x227c'),'option':_0x1cfc3b('0x27cb')},{'value':'ko-KR','option':_0x1cfc3b('0x4b5')},{'value':_0x1cfc3b('0x224a'),'option':_0x1cfc3b('0x25b4')},{'value':_0x1cfc3b('0x237e'),'option':'Norwegian\x20(Norway)'},{'value':_0x1cfc3b('0x121d'),'option':_0x1cfc3b('0x9c2')},{'value':_0x1cfc3b('0x56c'),'option':_0x1cfc3b('0x15b3')},{'value':'pt-PT','option':'Portuguese\x20(Portugal)'},{'value':'ru-RU','option':_0x1cfc3b('0x395')},{'value':_0x1cfc3b('0x2252'),'option':_0x1cfc3b('0x1a6a')},{'value':'es-ES','option':_0x1cfc3b('0x208e')},{'value':'sv-SE','option':_0x1cfc3b('0x27e2')},{'value':_0x1cfc3b('0xbeb'),'option':'Turkish\x20(Turkey)'},{'value':'uk-UA','option':_0x1cfc3b('0x1a8e')},{'value':_0x1cfc3b('0x116'),'option':_0x1cfc3b('0x2016')}];}function _0x5b1b78(){const _0x5d1cb8=_0x189033;return[{'value':'af','option':_0x5d1cb8('0x2516')},{'value':'sq','option':_0x5d1cb8('0x97f')},{'value':'am','option':'Amharic'},{'value':'ar','option':_0x5d1cb8('0x205a')},{'value':'hy','option':_0x5d1cb8('0x193')},{'value':'az','option':_0x5d1cb8('0x686')},{'value':'eu','option':'Basque'},{'value':'be','option':_0x5d1cb8('0x3b4')},{'value':'bn','option':_0x5d1cb8('0xb2f')},{'value':'bh','option':'Bihari'},{'value':'bs','option':_0x5d1cb8('0x1815')},{'value':'br','option':_0x5d1cb8('0x2812')},{'value':'bg','option':'Bulgarian'},{'value':'km','option':_0x5d1cb8('0x1395')},{'value':'ca','option':_0x5d1cb8('0x237')},{'value':_0x5d1cb8('0x175d'),'option':_0x5d1cb8('0x277f')},{'value':'zh-TW','option':_0x5d1cb8('0x700')},{'value':'co','option':_0x5d1cb8('0xfd9')},{'value':'hr','option':_0x5d1cb8('0xbab')},{'value':'cs','option':_0x5d1cb8('0xd6d')},{'value':'da','option':_0x5d1cb8('0x17d9')},{'value':'nl','option':'Dutch'},{'value':'en','option':_0x5d1cb8('0xf48')},{'value':'eo','option':'Esperanto'},{'value':'et','option':_0x5d1cb8('0x1bac')},{'value':'fo','option':_0x5d1cb8('0xc76')},{'value':'tl','option':'Filipino'},{'value':'fi','option':_0x5d1cb8('0x22c')},{'value':'fr','option':_0x5d1cb8('0x51a')},{'value':'fy','option':_0x5d1cb8('0x2631')},{'value':'gl','option':'Galician'},{'value':'ka','option':_0x5d1cb8('0x1a1b')},{'value':'de','option':_0x5d1cb8('0x118e')},{'value':'el','option':_0x5d1cb8('0x1aa9')},{'value':'gn','option':_0x5d1cb8('0x1dda')},{'value':'gu','option':_0x5d1cb8('0x201b')},{'value':_0x5d1cb8('0x175e'),'option':_0x5d1cb8('0x2091')},{'value':'ha','option':'Hausa'},{'value':'iw','option':_0x5d1cb8('0xf1c')},{'value':'hi','option':_0x5d1cb8('0x81c')},{'value':'hu','option':_0x5d1cb8('0x2832')},{'value':'is','option':_0x5d1cb8('0x868')},{'value':'id','option':'Indonesian'},{'value':'ia','option':_0x5d1cb8('0x22a6')},{'value':'ga','option':_0x5d1cb8('0x80f')},{'value':'it','option':_0x5d1cb8('0x2217')},{'value':'jw','option':'Javanese'},{'value':'ja','option':_0x5d1cb8('0x1abb')},{'value':'kn','option':_0x5d1cb8('0xb45')},{'value':'kk','option':_0x5d1cb8('0x1958')},{'value':'rw','option':_0x5d1cb8('0x2542')},{'value':'rn','option':'Kirundi'},{'value':'xx-klingon','option':_0x5d1cb8('0x414')},{'value':'ku','option':_0x5d1cb8('0x293')},{'value':'ko','option':'Korean'},{'value':'ky','option':_0x5d1cb8('0x789')},{'value':'lo','option':_0x5d1cb8('0x216b')},{'value':'la','option':_0x5d1cb8('0x9c5')},{'value':'lv','option':_0x5d1cb8('0x1f33')},{'value':'ln','option':'Lingala'},{'value':'lt','option':_0x5d1cb8('0xbc4')},{'value':'mk','option':_0x5d1cb8('0x389')},{'value':'mg','option':'Malagasy'},{'value':'ml','option':_0x5d1cb8('0x615')},{'value':'mt','option':_0x5d1cb8('0x15f4')},{'value':'mi','option':'Maori'},{'value':'mr','option':_0x5d1cb8('0xabf')},{'value':'mo','option':_0x5d1cb8('0x9a2')},{'value':'mn','option':'Mongolian'},{'value':_0x5d1cb8('0x1ba7'),'option':_0x5d1cb8('0x1369')},{'value':'ne','option':'Nepali'},{'value':'no','option':_0x5d1cb8('0x1e53')},{'value':'nn','option':_0x5d1cb8('0x177')},{'value':'oc','option':'Occitan'},{'value':'or','option':_0x5d1cb8('0x1fea')},{'value':'om','option':_0x5d1cb8('0xa06')},{'value':'ps','option':_0x5d1cb8('0x18eb')},{'value':'fa','option':_0x5d1cb8('0x6c3')},{'value':'xx-pirate','option':_0x5d1cb8('0x22d')},{'value':'pl','option':_0x5d1cb8('0x10a7')},{'value':_0x5d1cb8('0x56c'),'option':_0x5d1cb8('0x15b3')},{'value':_0x5d1cb8('0xa21'),'option':_0x5d1cb8('0x1876')},{'value':'pa','option':'Punjabi'},{'value':'qu','option':_0x5d1cb8('0x168')},{'value':'ro','option':_0x5d1cb8('0x47b')},{'value':'rm','option':'Romansh'},{'value':'ru','option':'Russian'},{'value':'gd','option':_0x5d1cb8('0x1d8')},{'value':'sr','option':'Serbian'},{'value':'sh','option':'Serbo-Croatian'},{'value':'st','option':_0x5d1cb8('0x1719')},{'value':'sn','option':'Shona'},{'value':'sd','option':_0x5d1cb8('0x1da4')},{'value':'si','option':_0x5d1cb8('0x261')},{'value':'sk','option':_0x5d1cb8('0x967')},{'value':'sl','option':_0x5d1cb8('0x1756')},{'value':'so','option':_0x5d1cb8('0x16b9')},{'value':'es','option':_0x5d1cb8('0xbe9')},{'value':'su','option':_0x5d1cb8('0x27fc')},{'value':'sw','option':'Swahili'},{'value':'sv','option':_0x5d1cb8('0x1ff5')},{'value':'tg','option':_0x5d1cb8('0x26af')},{'value':'ta','option':_0x5d1cb8('0x1c26')},{'value':'tt','option':_0x5d1cb8('0xdcd')},{'value':'te','option':_0x5d1cb8('0x2102')},{'value':'th','option':_0x5d1cb8('0xbc')},{'value':'ti','option':_0x5d1cb8('0x232')},{'value':'to','option':_0x5d1cb8('0x1ffc')},{'value':'tr','option':_0x5d1cb8('0x17b0')},{'value':'tk','option':_0x5d1cb8('0xda3')},{'value':'tw','option':_0x5d1cb8('0xc8')},{'value':'ug','option':_0x5d1cb8('0xf49')},{'value':'uk','option':_0x5d1cb8('0x965')},{'value':'ur','option':_0x5d1cb8('0xbbd')},{'value':'uz','option':_0x5d1cb8('0x1549')},{'value':'vi','option':_0x5d1cb8('0x477')},{'value':'cy','option':_0x5d1cb8('0x1b09')},{'value':'xh','option':'Xhosa'},{'value':'yi','option':'Yiddish'},{'value':'yo','option':_0x5d1cb8('0x1dc1')},{'value':'zu','option':_0x5d1cb8('0x89')}];}function _0x5302c8(){const _0x1d689d=_0x189033;return[{'value':_0x1d689d('0xf07'),'option':'Afrikaans\x20(South\x20Africa)'},{'value':_0x1d689d('0x1bb5'),'option':_0x1d689d('0x255d')},{'value':_0x1d689d('0x1f4'),'option':'Armenian\x20(Armenia)'},{'value':'az-AZ','option':_0x1d689d('0xe8c')},{'value':_0x1d689d('0xca9'),'option':_0x1d689d('0x102d')},{'value':'ms-MY','option':_0x1d689d('0x286c')},{'value':_0x1d689d('0x14b3'),'option':'Bengali\x20(Bangladesh)'},{'value':_0x1d689d('0x2455'),'option':'Bengali\x20(India)'},{'value':_0x1d689d('0x2680'),'option':'Catalan\x20(Spain)'},{'value':_0x1d689d('0x27f1'),'option':'Czech\x20(Czech\x20Republic)'},{'value':_0x1d689d('0x488'),'option':'Danish\x20(Denmark)'},{'value':'de-DE','option':_0x1d689d('0x245e')},{'value':_0x1d689d('0x286'),'option':_0x1d689d('0xbc1')},{'value':_0x1d689d('0x117b'),'option':'English\x20(Canada)'},{'value':_0x1d689d('0x271b'),'option':_0x1d689d('0xb22')},{'value':_0x1d689d('0x3d7'),'option':'English\x20(United\x20Kingdom)'},{'value':_0x1d689d('0x1aac'),'option':_0x1d689d('0xa57')},{'value':'en-IE','option':'English\x20(Ireland)'},{'value':_0x1d689d('0x2037'),'option':_0x1d689d('0x8c4')},{'value':'en-NZ','option':_0x1d689d('0x20d6')},{'value':_0x1d689d('0xf84'),'option':_0x1d689d('0xd96')},{'value':'en-PH','option':_0x1d689d('0x439')},{'value':_0x1d689d('0x13b2'),'option':_0x1d689d('0xb74')},{'value':_0x1d689d('0x124e'),'option':_0x1d689d('0x202e')},{'value':_0x1d689d('0x1704'),'option':_0x1d689d('0x65b')},{'value':_0x1d689d('0x1d18'),'option':'Spanish\x20(Argentina)'},{'value':_0x1d689d('0x17fa'),'option':'Spanish\x20(Bolivia)'},{'value':_0x1d689d('0x19eb'),'option':_0x1d689d('0x127c')},{'value':_0x1d689d('0x7b7'),'option':_0x1d689d('0x9aa')},{'value':_0x1d689d('0xaa'),'option':_0x1d689d('0x16d8')},{'value':_0x1d689d('0x1353'),'option':_0x1d689d('0x1c1e')},{'value':_0x1d689d('0x856'),'option':_0x1d689d('0x13a6')},{'value':_0x1d689d('0x45c'),'option':'Spanish\x20(Spain)'},{'value':'es-US','option':'Spanish\x20(United\x20States)'},{'value':_0x1d689d('0xf33'),'option':_0x1d689d('0x36e')},{'value':_0x1d689d('0x655'),'option':_0x1d689d('0x2205')},{'value':_0x1d689d('0x2e2'),'option':_0x1d689d('0xb1b')},{'value':'es-NI','option':_0x1d689d('0x112b')},{'value':_0x1d689d('0x1231'),'option':_0x1d689d('0x277e')},{'value':_0x1d689d('0x633'),'option':'Spanish\x20(Paraguay)'},{'value':'es-PE','option':'Spanish\x20(Peru)'},{'value':_0x1d689d('0x24a4'),'option':'Spanish\x20(Puerto\x20Rico)'},{'value':_0x1d689d('0x77a'),'option':_0x1d689d('0x862')},{'value':_0x1d689d('0x1ea5'),'option':_0x1d689d('0x61b')},{'value':_0x1d689d('0x43a'),'option':'Spanish\x20(Venezuela)'},{'value':_0x1d689d('0x3b1'),'option':_0x1d689d('0x11f7')},{'value':'fil-PH','option':_0x1d689d('0x1c61')},{'value':_0x1d689d('0x333'),'option':_0x1d689d('0x842')},{'value':_0x1d689d('0x12fc'),'option':'French\x20(France)'},{'value':'gl-ES','option':_0x1d689d('0x82')},{'value':_0x1d689d('0x1c75'),'option':_0x1d689d('0xfa3')},{'value':_0x1d689d('0x1242'),'option':'Gujarati\x20(India)'},{'value':'hr-HR','option':_0x1d689d('0x12b9')},{'value':'zu-ZA','option':_0x1d689d('0x17cb')},{'value':_0x1d689d('0x625'),'option':_0x1d689d('0x1c9a')},{'value':_0x1d689d('0x1ee8'),'option':_0x1d689d('0x2504')},{'value':_0x1d689d('0xde8'),'option':_0x1d689d('0x1555')},{'value':_0x1d689d('0x2843'),'option':_0x1d689d('0x215d')},{'value':'km-KH','option':_0x1d689d('0xef8')},{'value':_0x1d689d('0x6fb'),'option':'Lao\x20(Laos)'},{'value':'lv-LV','option':_0x1d689d('0x1ee')},{'value':_0x1d689d('0xc1e'),'option':_0x1d689d('0x101')},{'value':_0x1d689d('0x2823'),'option':_0x1d689d('0xc83')},{'value':_0x1d689d('0xa3f'),'option':_0x1d689d('0xa6e')},{'value':_0x1d689d('0x23b1'),'option':_0x1d689d('0xbb7')},{'value':'nl-NL','option':_0x1d689d('0x2018')},{'value':_0x1d689d('0x561'),'option':_0x1d689d('0x115a')},{'value':_0x1d689d('0x237e'),'option':_0x1d689d('0xe93')},{'value':_0x1d689d('0x121d'),'option':_0x1d689d('0x9c2')},{'value':_0x1d689d('0x56c'),'option':_0x1d689d('0x15b3')},{'value':'pt-PT','option':_0x1d689d('0x1876')},{'value':_0x1d689d('0x1f6b'),'option':_0x1d689d('0x2438')},{'value':_0x1d689d('0x27bf'),'option':'Sinhala\x20(Srilanka)'},{'value':'sk-SK','option':_0x1d689d('0x1a6a')},{'value':_0x1d689d('0x14ed'),'option':_0x1d689d('0xeba')},{'value':_0x1d689d('0x2461'),'option':'Sundanese\x20(Indonesia)'},{'value':_0x1d689d('0x200d'),'option':_0x1d689d('0x1a02')},{'value':_0x1d689d('0x148c'),'option':_0x1d689d('0x26a')},{'value':'fi-FI','option':_0x1d689d('0x12ad')},{'value':'sv-SE','option':_0x1d689d('0x27e2')},{'value':_0x1d689d('0x1dfc'),'option':_0x1d689d('0x1036')},{'value':'ta-SG','option':'Tamil\x20(Singapore)'},{'value':_0x1d689d('0x8bd'),'option':'Tamil\x20(Sri\x20Lanka)'},{'value':_0x1d689d('0xb57'),'option':'Tamil\x20(Malaysia)'},{'value':_0x1d689d('0x20bd'),'option':_0x1d689d('0xe3d')},{'value':_0x1d689d('0x116'),'option':_0x1d689d('0x2016')},{'value':'tr-TR','option':_0x1d689d('0x472')},{'value':_0x1d689d('0xb13'),'option':_0x1d689d('0x981')},{'value':_0x1d689d('0x9d1'),'option':_0x1d689d('0x2463')},{'value':_0x1d689d('0x133d'),'option':_0x1d689d('0x8bf')},{'value':_0x1d689d('0x594'),'option':_0x1d689d('0x1a2e')},{'value':_0x1d689d('0x1a72'),'option':_0x1d689d('0x395')},{'value':_0x1d689d('0x1b92'),'option':_0x1d689d('0x9f5')},{'value':_0x1d689d('0x1143'),'option':_0x1d689d('0x1a8e')},{'value':'he-IL','option':_0x1d689d('0x10a1')},{'value':'ar-IL','option':_0x1d689d('0x72a')},{'value':_0x1d689d('0x14d3'),'option':'Arabic\x20(Jordan)'},{'value':'ar-AE','option':_0x1d689d('0x1cce')},{'value':'ar-BH','option':'Arabic\x20(Bahrain)'},{'value':_0x1d689d('0xe4a'),'option':_0x1d689d('0x15f0')},{'value':'ar-SA','option':_0x1d689d('0x2606')},{'value':_0x1d689d('0x23fd'),'option':_0x1d689d('0x9fd')},{'value':'ar-KW','option':_0x1d689d('0x1953')},{'value':'ar-MA','option':'Arabic\x20(Morocco)'},{'value':_0x1d689d('0x38d'),'option':_0x1d689d('0x75e')},{'value':_0x1d689d('0xac'),'option':_0x1d689d('0x16fc')},{'value':_0x1d689d('0x2373'),'option':'Arabic\x20(State\x20of\x20Palestine)'},{'value':'ar-QA','option':_0x1d689d('0x23c8')},{'value':_0x1d689d('0x27d4'),'option':_0x1d689d('0x177e')},{'value':'ar-EG','option':_0x1d689d('0x1b36')},{'value':_0x1d689d('0xcea'),'option':_0x1d689d('0x142c')},{'value':_0x1d689d('0x1147'),'option':_0x1d689d('0x2317')},{'value':_0x1d689d('0xc64'),'option':_0x1d689d('0x1e8b')},{'value':'ko-KR','option':_0x1d689d('0x4b5')},{'value':_0x1d689d('0x146'),'option':'Chinese,\x20Mandarin\x20(Traditional,\x20Taiwan)'},{'value':'yue-Hant-HK','option':_0x1d689d('0x236d')},{'value':_0x1d689d('0x227c'),'option':_0x1d689d('0x27cb')},{'value':_0x1d689d('0x171c'),'option':_0x1d689d('0x20cc')},{'value':_0x1d689d('0x3f4'),'option':_0x1d689d('0xddf')}];}function _0x45f47f(){const _0x365484=_0x189033;return[{'value':_0x365484('0x14d5'),'option':_0x365484('0x53e')},{'value':_0x365484('0x26f2'),'option':_0x365484('0x1f78')},{'value':'ukenglishfemale','option':'UK\x20English\x20Female'},{'value':_0x365484('0x15a9'),'option':_0x365484('0x23ba')},{'value':_0x365484('0x1b69'),'option':'Australian\x20English'},{'value':_0x365484('0xcb7'),'option':'US\x20Spanish\x20Female'},{'value':_0x365484('0x1886'),'option':_0x365484('0x2166')},{'value':'chchinesefemale','option':_0x365484('0x22ff')},{'value':'chchinesemale','option':_0x365484('0x23f3')},{'value':_0x365484('0x1206'),'option':_0x365484('0x2435')},{'value':_0x365484('0x23d3'),'option':_0x365484('0x1e4a')},{'value':_0x365484('0x893'),'option':_0x365484('0xef6')},{'value':_0x365484('0x1bce'),'option':_0x365484('0x1087')},{'value':_0x365484('0x1aff'),'option':_0x365484('0x126f')},{'value':_0x365484('0x2476'),'option':_0x365484('0xd95')},{'value':_0x365484('0x12ed'),'option':_0x365484('0x76a')},{'value':_0x365484('0x155f'),'option':_0x365484('0x70a')},{'value':_0x365484('0x1c8'),'option':_0x365484('0x1df5')},{'value':_0x365484('0x1959'),'option':_0x365484('0x1e82')},{'value':_0x365484('0x45e'),'option':_0x365484('0x1b42')},{'value':_0x365484('0x11de'),'option':'European\x20Spanish\x20Female'},{'value':_0x365484('0x96e'),'option':_0x365484('0x1a69')},{'value':_0x365484('0x13c9'),'option':_0x365484('0x1d27')},{'value':_0x365484('0x7df'),'option':_0x365484('0x15d4')},{'value':_0x365484('0x212b'),'option':_0x365484('0x21a5')},{'value':_0x365484('0xf41'),'option':'European\x20Finnish\x20Female'},{'value':_0x365484('0x15e7'),'option':'European\x20French\x20Female'},{'value':'eurfrenchmale','option':'European\x20French\x20Male'},{'value':_0x365484('0x896'),'option':'European\x20Norwegian\x20Female'},{'value':'eurdutchfemale','option':_0x365484('0x2547')},{'value':_0x365484('0x12f2'),'option':_0x365484('0x1c00')},{'value':'euritalianfemale','option':'European\x20Italian\x20Female'},{'value':_0x365484('0x418'),'option':_0x365484('0x121')},{'value':'eurturkishfemale','option':_0x365484('0x25ca')},{'value':_0x365484('0x78e'),'option':_0x365484('0x1cfe')},{'value':'eurgermanfemale','option':_0x365484('0x6e1')},{'value':'eurgermanmale','option':_0x365484('0x189d')},{'value':_0x365484('0x44a'),'option':'Russian\x20Female'},{'value':_0x365484('0x89f'),'option':_0x365484('0x5f1')},{'value':_0x365484('0x514'),'option':_0x365484('0x20a9')},{'value':'cafrenchfemale','option':_0x365484('0xb3f')},{'value':_0x365484('0x423'),'option':_0x365484('0x1096')}];}function _0x2634d7(){const _0x5843e2=_0x189033;return[{'value':'en-US','option':_0x5843e2('0x40b')},{'value':_0x5843e2('0x117b'),'option':_0x5843e2('0x6fa')},{'value':_0x5843e2('0x3d7'),'option':_0x5843e2('0x1d29')},{'value':_0x5843e2('0x286'),'option':_0x5843e2('0xbc1')},{'value':_0x5843e2('0x45c'),'option':_0x5843e2('0x208e')},{'value':'es-MX','option':_0x5843e2('0xb1b')},{'value':_0x5843e2('0x1ee8'),'option':_0x5843e2('0xe05')},{'value':_0x5843e2('0x12fc'),'option':_0x5843e2('0x245e')},{'value':'fr-CA','option':_0x5843e2('0x842')},{'value':_0x5843e2('0x121d'),'option':_0x5843e2('0x9c2')},{'value':'pt-PT','option':_0x5843e2('0x1876')},{'value':_0x5843e2('0x2680'),'option':_0x5843e2('0x128')},{'value':_0x5843e2('0x26bd'),'option':'Chinese\x20(Taiwan)'},{'value':'da-DK','option':'Danish\x20(Denmark)'},{'value':'ja-JP','option':_0x5843e2('0x27cb')},{'value':'ko-KR','option':_0x5843e2('0x13aa')},{'value':_0x5843e2('0x12c'),'option':'Dutch\x20(Netherlands)'},{'value':'nb-NO','option':'Norwegian\x20(Norway)'},{'value':'pt-BR','option':_0x5843e2('0x15b3')},{'value':_0x5843e2('0x1a72'),'option':_0x5843e2('0x395')},{'value':_0x5843e2('0x22bd'),'option':_0x5843e2('0x27e2')},{'value':_0x5843e2('0x175d'),'option':'Chinese\x20(China)'},{'value':'zh-HK','option':_0x5843e2('0xc60')}];}function _0x4cc3c0(){const _0x160eaa=_0x189033;return[{'value':'0','option':_0x160eaa('0x1b74')},{'value':_0x160eaa('0x270e'),'option':'Date'},{'value':_0x160eaa('0x10d9'),'option':_0x160eaa('0xb39')},{'value':_0x160eaa('0x1cc4'),'option':_0x160eaa('0x199e')},{'value':_0x160eaa('0x1aa8'),'option':_0x160eaa('0x1111')},{'value':_0x160eaa('0x1014'),'option':_0x160eaa('0x11fd')},{'value':_0x160eaa('0x147a'),'option':_0x160eaa('0x1e55')},{'value':'phonenumber','option':'Phone\x20number'},{'value':_0x160eaa('0xa17'),'option':'Streets'},{'value':_0x160eaa('0xebd'),'option':'US\x20City/States'}];}function _0x2bb589(){const _0x4f3f53=_0x189033;return[{'value':_0x4f3f53('0x1fbb'),'option':_0x4f3f53('0x17a9')},{'value':'Astrid','option':_0x4f3f53('0x105b')},{'value':_0x4f3f53('0x1590'),'option':_0x4f3f53('0x1bd')},{'value':_0x4f3f53('0x104f'),'option':_0x4f3f53('0x18ec')},{'value':_0x4f3f53('0xd60'),'option':_0x4f3f53('0x20d3')},{'value':_0x4f3f53('0x20f9'),'option':_0x4f3f53('0x2377')},{'value':_0x4f3f53('0x1ce9'),'option':_0x4f3f53('0xd3c')},{'value':_0x4f3f53('0xb16'),'option':'Conchita\x20(Spanish,\x20Castilian,\x20Female)'},{'value':'Cristiano','option':_0x4f3f53('0x1f43')},{'value':_0x4f3f53('0x1518'),'option':_0x4f3f53('0x1d1')},{'value':_0x4f3f53('0x536'),'option':_0x4f3f53('0x1d97')},{'value':'Enrique','option':_0x4f3f53('0x776')},{'value':_0x4f3f53('0x741'),'option':_0x4f3f53('0x2123')},{'value':_0x4f3f53('0x258b'),'option':'Filiz\x20(Turkish,\x20Female)'},{'value':_0x4f3f53('0x281d'),'option':'Geraint\x20(English,\x20Welsh,\x20Male)'},{'value':_0x4f3f53('0x257f'),'option':_0x4f3f53('0x2052')},{'value':_0x4f3f53('0xafd'),'option':_0x4f3f53('0xa5c')},{'value':'Hans','option':_0x4f3f53('0x17b5')},{'value':_0x4f3f53('0x22f0'),'option':_0x4f3f53('0x154a')},{'value':_0x4f3f53('0x1e6'),'option':_0x4f3f53('0x13c0')},{'value':_0x4f3f53('0x1e0a'),'option':'Jacek\x20(Polish,\x20Male)'},{'value':'Jan','option':'Jan\x20(Polish,\x20Male)'},{'value':'Joanna','option':_0x4f3f53('0x22c1')},{'value':_0x4f3f53('0x22ca'),'option':_0x4f3f53('0x1433')},{'value':_0x4f3f53('0x16f2'),'option':_0x4f3f53('0x2708')},{'value':_0x4f3f53('0xb76'),'option':_0x4f3f53('0x2801')},{'value':'Kendra','option':_0x4f3f53('0x212e')},{'value':_0x4f3f53('0x111a'),'option':'Kimberly\x20(English,\x20US,\x20Female)'},{'value':_0x4f3f53('0x2237'),'option':_0x4f3f53('0x570')},{'value':_0x4f3f53('0x2353'),'option':_0x4f3f53('0x281e')},{'value':_0x4f3f53('0x1e0d'),'option':_0x4f3f53('0x944')},{'value':_0x4f3f53('0x19bd'),'option':_0x4f3f53('0x5b7')},{'value':_0x4f3f53('0x16de'),'option':_0x4f3f53('0x214a')},{'value':_0x4f3f53('0x1c70'),'option':_0x4f3f53('0x3e5')},{'value':_0x4f3f53('0x2649'),'option':_0x4f3f53('0x172e')},{'value':'Miguel','option':_0x4f3f53('0xc55')},{'value':_0x4f3f53('0x13c1'),'option':_0x4f3f53('0x1b78')},{'value':_0x4f3f53('0x17eb'),'option':_0x4f3f53('0x998')},{'value':'Nicole','option':_0x4f3f53('0x17f0')},{'value':_0x4f3f53('0x1069'),'option':'Penelope\x20(Spanish,\x20US,\x20Female)'},{'value':_0x4f3f53('0x9bd'),'option':_0x4f3f53('0x1d09')},{'value':_0x4f3f53('0x11a8'),'option':_0x4f3f53('0x2074')},{'value':'Ruben','option':_0x4f3f53('0x217a')},{'value':_0x4f3f53('0x1460'),'option':_0x4f3f53('0x1b35')},{'value':_0x4f3f53('0x40c'),'option':'Salli\x20(English,\x20US,\x20Female)'},{'value':_0x4f3f53('0x1314'),'option':_0x4f3f53('0x10d8')},{'value':'Vitoria','option':'Vitoria\x20(Portuguese,\x20Brazilian,\x20Female)'}];}function _0x3d0554(){const _0x29ad23=_0x189033;return[{'value':_0x29ad23('0xfb5'),'option':_0x29ad23('0x260e')},{'value':_0x29ad23('0x11eb'),'option':_0x29ad23('0x1371')},{'value':_0x29ad23('0x1483'),'option':_0x29ad23('0x9b6')},{'value':_0x29ad23('0x1551'),'option':_0x29ad23('0xc2b')},{'value':_0x29ad23('0x11b9'),'option':_0x29ad23('0x2312')},{'value':_0x29ad23('0x1905'),'option':_0x29ad23('0x1e10')},{'value':_0x29ad23('0x22c5'),'option':_0x29ad23('0xf61')},{'value':_0x29ad23('0xce6'),'option':_0x29ad23('0x1eb1')},{'value':_0x29ad23('0xbf'),'option':_0x29ad23('0x76b')},{'value':_0x29ad23('0x6ab'),'option':_0x29ad23('0x71b')},{'value':_0x29ad23('0xf8f'),'option':_0x29ad23('0x15b6')},{'value':_0x29ad23('0x2697'),'option':_0x29ad23('0x422')},{'value':_0x29ad23('0xd72'),'option':'Asia\x20Pacific\x20(Tokyo)'},{'value':_0x29ad23('0x349'),'option':_0x29ad23('0x14cf')},{'value':_0x29ad23('0xba3'),'option':'South\x20America\x20(São\x20Paulo)'}];}function _0x3e3fe9(){const _0x32767f=_0x189033;return[{'value':_0x32767f('0xfb5'),'option':_0x32767f('0x260e')},{'value':'us-west-2','option':'US\x20West\x20(Oregon)'},{'value':_0x32767f('0x1905'),'option':_0x32767f('0x1e10')},{'value':'ap-southeast-2','option':_0x32767f('0x15b6')}];}_0x20dbe2[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x24b6'),_0x189033('0x23ad')];function _0x20dbe2(_0x25fe66,_0x588545,_0x10976b,_0x38b70e){const _0xa79a47=_0x189033,_0x3e0e34=this;_0x3e0e34[_0xa79a47('0x273a')]={'preproduction':_0x10976b};function _0x3afce1(_0x2a08d8){const _0x3eac91=_0xa79a47;_0x2a08d8?(_0x38b70e(_0x3e0e34[_0x3eac91('0x273a')][_0x3eac91('0x1944')]),_0x25fe66[_0x3eac91('0x1715')](_0x3e0e34[_0x3eac91('0x273a')]['preproduction'])):_0x25fe66[_0x3eac91('0x1715')]();}_0x3e0e34['closeDialog']=_0x3afce1;}const _0x110f97=_0x20dbe2;_0x593595['$inject']=['$mdDialog',_0x189033('0x23ad')];function _0x593595(_0x525935,_0x2f453a){const _0x508a8a=_0x189033,_0x4863a2=this,_0x14c5c4=0x5,_0x43fbd6=_0x14c5c4*0x400*0x400;_0x4863a2['errors']=[],_0x4863a2[_0x508a8a('0x8f')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x43fbd6,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x4863a2[_0x508a8a('0x1fa6')]={'flow':{}},_0x4863a2[_0x508a8a('0xfbe')]=![],_0x4863a2['closeDialog']=_0x4bbe32,_0x4863a2[_0x508a8a('0x1aad')]=_0x27677e;function _0x27677e(_0xe5efee){const _0x3cb91c=_0x508a8a;_0x4863a2[_0x3cb91c('0x17f')]=[];const _0x1866f2=[_0x3cb91c('0x4f')];!_0x2e3ca0()['includes'](_0x1866f2,_0xe5efee[_0x3cb91c('0x1197')]())&&_0x4863a2[_0x3cb91c('0x17f')][_0x3cb91c('0x1fd0')]({'message':_0x3cb91c('0x10d4')+_0xe5efee[_0x3cb91c('0x1197')]()+_0x3cb91c('0xefc')});_0xe5efee['size']>_0x43fbd6&&_0x4863a2[_0x3cb91c('0x17f')][_0x3cb91c('0x1fd0')]({'message':_0x3cb91c('0x2482')+_0x14c5c4+'MB'});if(!_0x4863a2['errors'][_0x3cb91c('0x1564')]){const _0x4284a2=new FileReader();_0x4284a2[_0x3cb91c('0x43b')]=function(_0x47f481){_0x4bbe32(_0x47f481['target']['result']);},_0x4284a2[_0x3cb91c('0x207')](_0xe5efee['file']);}}function _0x4bbe32(_0x2af671){const _0x4f70fc=_0x508a8a;_0x2af671?(_0x2f453a(_0x2af671),_0x525935[_0x4f70fc('0x1715')](_0x2af671)):_0x525935['hide']();}}const _0x21c83f=_0x593595;_0x299573[_0x189033('0x14be')]=[_0x189033('0x1e48'),'toasty',_0x189033('0x273a'),'api'];function _0x299573(_0x8c900d,_0x22bb52,_0x43608f,_0x486305){const _0x25dea3=_0x189033,_0x214422=this;_0x214422[_0x25dea3('0x273a')]=_0x2e3ca0()[_0x25dea3('0x147f')](_0x43608f);function _0x489edc(){const _0xabf144=_0x25dea3;_0x214422[_0xabf144('0x17f')]=[],_0x486305[_0xabf144('0x27ea')][_0xabf144('0x2480')]({'id':_0x214422[_0xabf144('0x273a')]['id']},{'notes':_0x214422[_0xabf144('0x273a')]['notes'],'description':_0x214422[_0xabf144('0x273a')]['description']})[_0xabf144('0xe53')][_0xabf144('0x683')](function(_0x111b57){const _0x19c556=_0xabf144;_0x22bb52['success']({'title':_0x19c556('0x335'),'msg':_0x214422[_0x19c556('0x273a')][_0x19c556('0x60a')]?_0x214422['project'][_0x19c556('0x60a')]+_0x19c556('0x96c'):''}),_0x8c900d[_0x19c556('0x1715')](_0x111b57);})[_0xabf144('0x130a')](function(_0x38b2ef){const _0xbd6852=_0xabf144;console[_0xbd6852('0x52a')](_0x38b2ef),_0x214422[_0xbd6852('0x17f')]=_0x38b2ef[_0xbd6852('0x5a5')][_0xbd6852('0x17f')]||[{'message':_0x38b2ef[_0xbd6852('0x1ff0')](),'type':_0xbd6852('0x24a6')}];});}function _0x5ea201(){_0x8c900d['hide']();}_0x214422[_0x25dea3('0xf82')]=_0x5ea201,_0x214422[_0x25dea3('0xb0a')]=_0x489edc;}const _0x4d339e=_0x299573;_0x2a0eba[_0x189033('0x14be')]=[_0x189033('0x1e48'),'toasty',_0x189033('0x1248'),'$window',_0x189033('0x938')];function _0x2a0eba(_0x5b9bdf,_0x3d53b9,_0x912d16,_0x14593f,_0x465521){const _0x27f4d4=_0x189033,_0x2e7348=this;_0x2e7348[_0x27f4d4('0x1248')]=_0x912d16,_0x2e7348['id']='',_0x2e7348[_0x27f4d4('0xec')]=!![];function _0x544e35(_0x1e87f0){const _0x2e99d7=_0x27f4d4;_0x2e7348[_0x2e99d7('0x17f')]=[],_0x1e87f0?(_0x5b9bdf[_0x2e99d7('0x1715')](),_0x2e7348[_0x2e99d7('0xec')]?_0x14593f[_0x2e99d7('0x1614')]('/callysquare/projects/'+_0x2e7348['id'],_0x2e99d7('0x18b3')):_0x465521['go'](_0x2e99d7('0x1c81'),{'id':_0x2e7348['id']})):_0x5b9bdf[_0x2e99d7('0x1715')]();}_0x2e7348['closeDialog']=_0x544e35;}const _0x5d8471=_0x2a0eba;_0x141abe[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x56b'),'project','projects',_0x189033('0x1d08')];function _0x141abe(_0x3427d6,_0x3c61b7,_0x5e39f0,_0x5a5ac4,_0x214537,_0x5c926b){const _0x234b66=_0x189033,_0x341f5c=this;_0x341f5c['project']=_0x5a5ac4,_0x341f5c[_0x234b66('0x1e2a')]=0x0,_0x341f5c[_0x234b66('0x1996')]=[],_0x341f5c[_0x234b66('0x1378')]=[],_0x341f5c[_0x234b66('0xf82')]=_0x1e7906,_0x341f5c['dualMultiselectOptions']={'readOnly':![],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':'fullname','line2':[_0x234b66('0x60a'),_0x234b66('0x1d43')],'line3':_0x234b66('0x1e2a'),'labelAll':_0x5c926b[_0x234b66('0x2728')]('CALLYSQUARE.ALL_USERS'),'labelSelected':_0x5c926b['instant'](_0x234b66('0xae8')),'transferCallback':function(_0x28e992,_0x2d00f6){const _0x5a5915=_0x234b66;_0x5e39f0['squareProject'][_0x2d00f6?_0x5a5915('0x541'):_0x5a5915('0x1f28')]({'id':_0x341f5c[_0x5a5915('0x273a')]['id'],'ids':_0x2e3ca0()[_0x5a5915('0x386')](_0x28e992,'id'),'penalty':_0x341f5c[_0x5a5915('0x1e2a')]||0x0})[_0x5a5915('0xe53')][_0x5a5915('0x683')](function(){const _0xe37c01=_0x5a5915;_0x3c61b7[_0xe37c01('0x53')]({'title':'Project\x20properly\x20'+(_0x2d00f6?_0xe37c01('0x2651'):_0xe37c01('0x2582')),'msg':_0xe37c01('0x14f4')+(_0x2d00f6?_0xe37c01('0x2651'):_0xe37c01('0x2582'))+'!'}),!_0x2d00f6&&_0x128265();})['catch'](function(_0x255f32){const _0x1dfba6=_0x5a5915;_0x3c61b7[_0x1dfba6('0x52a')]({'title':_0x255f32[_0x1dfba6('0x13ee')]?_0x1dfba6('0x2168')+_0x255f32[_0x1dfba6('0x13ee')]+_0x1dfba6('0xbf6')+_0x255f32[_0x1dfba6('0x24a9')]:'SYSTEM:squareProjects.ADDUSERS','msg':_0x255f32['status']?JSON[_0x1dfba6('0x258a')](_0x255f32['data']):_0x255f32['toString']()});});}};function _0x128265(){const _0x1a7293=_0x234b66;return _0x5e39f0[_0x1a7293('0x27ea')][_0x1a7293('0x16dc')]({'id':_0x341f5c[_0x1a7293('0x273a')]['id'],'fields':_0x1a7293('0x1338'),'nolimit':!![],'role':_0x1a7293('0xc96')})['$promise'][_0x1a7293('0x683')](function(_0x3ad4c2){const _0x5204f7=_0x1a7293;return _0x341f5c[_0x5204f7('0x1378')]=_0x3ad4c2['rows']?_0x2e3ca0()[_0x5204f7('0x386')](_0x3ad4c2[_0x5204f7('0xf5d')],function(_0x267d9c){return _0x267d9c;}):[],_0x341f5c[_0x5204f7('0x169f')][_0x5204f7('0x1378')]=_0x341f5c[_0x5204f7('0x1378')],_0x5e39f0[_0x5204f7('0xc96')][_0x5204f7('0x1e6e')]({'fields':'id,fullname,name,internal','role':_0x5204f7('0xc96'),'nolimit':!![]})[_0x5204f7('0xe53')];})[_0x1a7293('0x683')](function(_0x582c5d){const _0x4db1b3=_0x1a7293;_0x341f5c['items']=_0x582c5d[_0x4db1b3('0xf5d')]?_0x2e3ca0()[_0x4db1b3('0x386')](_0x582c5d[_0x4db1b3('0xf5d')],function(_0x46c96c){return _0x46c96c;}):[],_0x341f5c[_0x4db1b3('0x169f')][_0x4db1b3('0x1996')]=_0x2e3ca0()[_0x4db1b3('0x461')](_0x341f5c[_0x4db1b3('0x1996')],_0x341f5c['selectedItems'],'id');})[_0x1a7293('0x130a')](function(_0xac47c){const _0x3f1ed9=_0x1a7293;_0x3c61b7[_0x3f1ed9('0x52a')]({'title':_0xac47c['status']?'API:'+_0xac47c[_0x3f1ed9('0x13ee')]+_0x3f1ed9('0xbf6')+_0xac47c[_0x3f1ed9('0x24a9')]:_0x3f1ed9('0x40f'),'msg':_0xac47c[_0x3f1ed9('0x13ee')]?JSON[_0x3f1ed9('0x258a')](_0xac47c[_0x3f1ed9('0x5a5')]):_0xac47c[_0x3f1ed9('0x1ff0')]()});});}function _0x1e7906(){const _0x2fddec=_0x234b66;_0x3427d6[_0x2fddec('0x1715')]();}_0x128265();}const _0xf62afa=_0x141abe;_0x4ae56d[_0x189033('0x14be')]=[_0x189033('0x1e48'),'toasty',_0x189033('0x273a'),_0x189033('0x24b6'),_0x189033('0x56b'),_0x189033('0x2063'),_0x189033('0x938')];function _0x4ae56d(_0x47fe0c,_0x39b601,_0x12924c,_0x496f0b,_0x26be29,_0x164fa7,_0x5dc385){const _0x1b3c19=_0x189033,_0x588abd=this;_0x588abd['project']=angular[_0x1b3c19('0x1a86')](_0x12924c),_0x588abd[_0x1b3c19('0x273a')][_0x1b3c19('0x60a')]+=_0x1b3c19('0x1720'),_0x588abd['project']['preproduction']=_0x496f0b,_0x588abd[_0x1b3c19('0xec')]=!![];function _0x50d936(){const _0x451b6a=_0x1b3c19;delete _0x588abd[_0x451b6a('0x273a')]['id'],_0x26be29[_0x451b6a('0x27ea')][_0x451b6a('0xb0a')](_0x588abd['project'])[_0x451b6a('0xe53')][_0x451b6a('0x683')](function(_0x137f73){const _0x3350dc=_0x451b6a;_0x39b601['success']({'title':_0x3350dc('0x610'),'msg':_0x588abd['project']['name']?_0x588abd[_0x3350dc('0x273a')][_0x3350dc('0x60a')]+_0x3350dc('0x14b5'):''}),_0x47fe0c[_0x3350dc('0x1715')](_0x137f73),_0x588abd[_0x3350dc('0xec')]?_0x164fa7[_0x3350dc('0x1614')](_0x3350dc('0x1c44')+_0x137f73['id'],_0x3350dc('0x18b3')):_0x5dc385['go'](_0x3350dc('0x1c81'),{'id':_0x137f73['id']});})['catch'](function(_0x2c48e1){const _0xa14a1d=_0x451b6a;console[_0xa14a1d('0x52a')](_0x2c48e1),_0x588abd[_0xa14a1d('0x17f')]=_0x2c48e1[_0xa14a1d('0x5a5')][_0xa14a1d('0x17f')]||[{'message':_0x2c48e1['toString'](),'type':_0xa14a1d('0x25bb')}];});}function _0x2aa862(){_0x47fe0c['hide']();}_0x588abd[_0x1b3c19('0xf82')]=_0x2aa862,_0x588abd[_0x1b3c19('0xb0a')]=_0x50d936;}const _0x26454c=_0x4ae56d,_0x27fb8d=_0x180212['p']+_0x189033('0x2392'),_0x1d0d91=_0x180212['p']+_0x189033('0x5de'),_0xc279bf=_0x180212['p']+'src/js/modules/main/apps/callysquare/views/projects/edit/open/open.html/open.html',_0x677742=_0x180212['p']+_0x189033('0x23b0'),_0x5d871b=_0x180212['p']+_0x189033('0x1684'),_0xe6048a=_0x180212['p']+_0x189033('0xf01'),_0x133e04=_0x180212['p']+_0x189033('0x1ed6');_0xa30415[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x16ea'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x273a'),_0x189033('0x3bf'),_0x189033('0x20fe'),_0x189033('0x2da'),_0x189033('0x11d2'),_0x189033('0x220b'),_0x189033('0x5b8'),_0x189033('0x1693'),_0x189033('0x1248'),'intervals',_0x189033('0x1093'),_0x189033('0x84b'),_0x189033('0xe01'),'smsAccounts',_0x189033('0x22ab'),'userProfileSection',_0x189033('0xba1')];const _0x29a539=window[_0x189033('0x2423')],_0x3ce6ee=window[_0x189033('0x1de4')];function _0xa30415(_0x510d00,_0x1df68e,_0x89600b,_0x4d542a,_0x4993d4,_0x4e1c80,_0x48a420,_0x3dc3d4,_0x1fc2d4,_0x521652,_0x3d90f3,_0x461bfd,_0xd019d8,_0x258c56,_0xd6d7b7,_0x8702f5,_0x5b9c21,_0x4534c6,_0x17e0f5,_0x4da95b,_0xf47254,_0x4f63d7,_0x3916bd,_0xf8305a){const _0x285408=_0x189033,_0x3ff6f7=this;_0x3ff6f7[_0x285408('0x11ed')]=_0xf8305a[_0x285408('0x20b2')](),_0x3ff6f7[_0x285408('0x273a')]=_0x3dc3d4||{},_0x3ff6f7[_0x285408('0x22df')]=_0x3916bd&&_0x3916bd[_0x285408('0x50d')]==0x1?_0x3916bd[_0x285408('0xf5d')][0x0]:null,_0x3ff6f7[_0x285408('0x1134')]=_0xf8305a[_0x285408('0x142a')](_0x3ff6f7[_0x285408('0x22df')]?_0x3ff6f7[_0x285408('0x22df')][_0x285408('0x1134')]:null),_0x3ff6f7[_0x285408('0x1dd2')]=_0x1e3fbd,_0x3ff6f7[_0x285408('0x115')]=_0x433f05,_0x3ff6f7[_0x285408('0x1bc9')]=_0x2aac4f,_0x3ff6f7['newProject']=_0x2a2ac4,_0x3ff6f7[_0x285408('0x25f2')]=_0x543975,_0x3ff6f7['saveProjectAs']=_0x2a706e,_0x3ff6f7[_0x285408('0x2112')]=_0x829bf8,_0x3ff6f7[_0x285408('0x2782')]=_0x163f14,_0x3ff6f7[_0x285408('0x221e')]=_0x5b3feb,_0x3ff6f7[_0x285408('0x61f')]=_0x3f6742,_0x3ff6f7[_0x285408('0x1458')]=_0x45f1ae;function _0x1e3fbd(){const _0x34df46=_0x285408,_0xca62df=new _0x29a539(_0x3ff6f7,new _0x3ce6ee(),document[_0x34df46('0x1759')](_0x34df46('0x216f')));_0xca62df[_0x34df46('0x110f')](_0x3ff6f7[_0x34df46('0x273a')][_0x34df46('0x1944')],_0x3ff6f7[_0x34df46('0x273a')][_0x34df46('0x60a')],_0x3ff6f7[_0x34df46('0x273a')]);}function _0x2aac4f(_0x4f6064,_0x5d845d){const _0x69e833=_0x285408;_0x89600b[_0x69e833('0x1d4')]({'controller':_0x69e833('0x1dd1'),'controllerAs':'vm','templateUrl':_0x27fb8d,'parent':angular[_0x69e833('0x1fcc')](_0x1df68e[_0x69e833('0x18e5')]),'clickOutsideToClose':!![],'locals':{'users':_0x1fc2d4['rows']||[],'trunks':_0x521652['rows']||[],'queues':_0x3d90f3[_0x69e833('0xf5d')]||[],'sounds':_0x461bfd[_0x69e833('0xf5d')]||[],'variables':_0xd019d8[_0x69e833('0xf5d')]||[],'databases':_0x258c56['rows']||[],'contexts':_0xd6d7b7[_0x69e833('0xf5d')]||[],'projects':_0x8702f5[_0x69e833('0xf5d')]||[],'intervals':_0x5b9c21[_0x69e833('0xf5d')]||[],'mailAccounts':_0x4534c6[_0x69e833('0xf5d')]||[],'smsAccounts':_0xf47254[_0x69e833('0xf5d')]||[],'pauses':_0x4f63d7[_0x69e833('0xf5d')]||[],'templates':_0x17e0f5[_0x69e833('0xf5d')]||[],'lists':_0x4da95b['rows']||[],'cell':_0x4f6064,'saveCallback':_0x5d845d,'crudPermissions':_0x3ff6f7[_0x69e833('0x1134')]}});}function _0x2a2ac4(_0x469222){const _0x57088c=_0x285408;_0x89600b[_0x57088c('0x1d4')]({'controller':'CreateOrEditSquareProjectDialogController','controllerAs':'vm','templateUrl':_0x1d0d91,'parent':angular[_0x57088c('0x1fcc')](_0x1df68e[_0x57088c('0x18e5')]),'clickOutsideToClose':!![],'locals':{'project':_0x469222,'projects':_0x8702f5[_0x57088c('0xf5d')],'openFromEditor':!![],'license':null,'setting':null,'crudPermissions':_0x3ff6f7[_0x57088c('0x1134')]}});}function _0x543975(){const _0x1c6d3e=_0x285408;_0x89600b[_0x1c6d3e('0x1d4')]({'controller':'MxGraphOpenProjectController','controllerAs':'vm','templateUrl':_0xc279bf,'parent':angular[_0x1c6d3e('0x1fcc')](_0x1df68e[_0x1c6d3e('0x18e5')]),'clickOutsideToClose':!![],'locals':{'projects':_0x8702f5['rows']||[]}});}function _0x2a706e(_0x21fe9d){const _0x59110a=_0x285408;_0x89600b[_0x59110a('0x1d4')]({'controller':_0x59110a('0xc57'),'controllerAs':'vm','templateUrl':_0x677742,'parent':angular[_0x59110a('0x1fcc')](_0x1df68e[_0x59110a('0x18e5')]),'clickOutsideToClose':!![],'locals':{'project':_0x3ff6f7[_0x59110a('0x273a')],'currentXML':_0x21fe9d}})[_0x59110a('0x683')](function(_0x4e82b4){const _0x340158=_0x59110a;_0x4e82b4&&_0x8702f5[_0x340158('0xf5d')][_0x340158('0x1fd0')](_0x4e82b4);});}function _0x53c936(){return _0x4d542a(function(_0x466ecc,_0x54196f){const _0x55725a=a0_0x4e0a;return _0x48a420[_0x55725a('0x22df')]['get']({'userProfileId':_0x3ff6f7[_0x55725a('0x11ed')][_0x55725a('0x2f')],'sectionId':0x3f4})['$promise']['then'](function(_0x2ae4a6){const _0x1814f6=_0x55725a,_0x28a73f=_0x2ae4a6[_0x1814f6('0xf5d')]?_0x2ae4a6[_0x1814f6('0xf5d')][0x0]:null,_0x2e6cf0=_0xf8305a[_0x1814f6('0x142a')](_0x28a73f?_0x28a73f[_0x1814f6('0x1134')]:null);_0x466ecc(_0x2e6cf0);})[_0x55725a('0x130a')](function(_0x43b99c){_0x54196f(_0x43b99c);});});}function _0x829bf8(_0x5b14c2){const _0xcb0a3b=_0x285408;return _0x53c936()[_0xcb0a3b('0x683')](function(_0x743708){const _0x682c0b=_0xcb0a3b;_0x743708[_0x682c0b('0x1978')]?_0x89600b[_0x682c0b('0x1d4')]({'controller':_0x682c0b('0x1a62'),'controllerAs':'vm','templateUrl':_0x3b99c6,'parent':angular[_0x682c0b('0x1fcc')](_0x1df68e[_0x682c0b('0x18e5')]),'clickOutsideToClose':!![],'locals':{'variable':_0x5b14c2,'variables':_0xd019d8[_0x682c0b('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x743708}}):_0x4e1c80['info']({'title':_0x4993d4['instant'](_0x682c0b('0x213e')),'msg':_0x4993d4[_0x682c0b('0x2728')]('STAFF.PERMISSIONS_UNAUTHORIZED_CREATION_MESSAGE')});})['catch'](function(_0x1f5df4){const _0x195348=_0xcb0a3b;_0x4e1c80[_0x195348('0x52a')]({'title':_0x1f5df4[_0x195348('0x13ee')]?_0x195348('0x2168')+_0x1f5df4[_0x195348('0x13ee')]+_0x195348('0xbf6')+_0x1f5df4[_0x195348('0x24a9')]:'API:NEW_VARIABLE','msg':_0x1f5df4['data']?JSON[_0x195348('0x258a')](_0x1f5df4[_0x195348('0x5a5')]):_0x1f5df4[_0x195348('0x1ff0')]()});});}function _0x163f14(_0x10ace6){const _0x362a45=_0x285408;_0x89600b['show']({'controller':_0x362a45('0x1d95'),'controllerAs':'vm','templateUrl':_0x5d871b,'parent':angular[_0x362a45('0x1fcc')](_0x1df68e['body']),'targetEvent':_0x10ace6,'clickOutsideToClose':!![],'locals':{'project':_0x3ff6f7['project']}})[_0x362a45('0x683')](function(_0xf23510){const _0x136ec2=_0x362a45;_0xf23510&&_0x2e3ca0()[_0x136ec2('0xf22')](_0x3ff6f7[_0x136ec2('0x273a')],_0xf23510);});}function _0x5b3feb(_0x34380b,_0x5a7173){const _0x186b1d=_0x285408;_0x89600b[_0x186b1d('0x1d4')]({'controller':_0x186b1d('0x26dc'),'controllerAs':'vm','templateUrl':_0xe6048a,'parent':angular[_0x186b1d('0x1fcc')](_0x1df68e[_0x186b1d('0x18e5')]),'clickOutsideToClose':!![],'locals':{'currentXML':_0x34380b,'saveCallback':_0x5a7173}})[_0x186b1d('0x683')](function(_0x4be711){const _0x32c1b4=_0x186b1d;_0x4be711&&(_0x3ff6f7[_0x32c1b4('0x273a')]['preproduction']=_0x4be711);});}function _0x3f6742(_0x3e7013){const _0x310100=_0x285408;_0x89600b[_0x310100('0x1d4')]({'controller':_0x310100('0x5e1'),'controllerAs':'vm','templateUrl':_0x133e04,'parent':angular[_0x310100('0x1fcc')](_0x1df68e[_0x310100('0x18e5')]),'clickOutsideToClose':!![],'locals':{'saveCallback':_0x3e7013}})['then'](function(_0x3868b5){const _0x5c6701=_0x310100;_0x3868b5&&(_0x3ff6f7[_0x5c6701('0x273a')][_0x5c6701('0x1944')]=_0x3868b5);});}function _0x433f05(_0x50dbed,_0x4b0011){const _0x4831c0=_0x285408,_0x41bbbd={'preproduction':_0x50dbed};_0x4b0011&&(_0x41bbbd['production']=_0x50dbed),_0x48a420[_0x4831c0('0x27ea')][_0x4831c0('0x2480')]({'id':_0x3ff6f7['project']['id']},_0x41bbbd)['$promise']['then'](function(_0x5128f6){const _0x22bea4=_0x4831c0;_0x4e1c80[_0x22bea4('0x53')]({'title':_0x22bea4('0xbfe')+(_0x4b0011?_0x22bea4('0x5ea'):_0x22bea4('0x118c'))+'!','msg':_0x3ff6f7[_0x22bea4('0x273a')][_0x22bea4('0x60a')]?_0x3ff6f7['project']['name']+_0x22bea4('0x1e58')+(_0x4b0011?_0x22bea4('0x5ea'):_0x22bea4('0x118c'))+'!':''}),_0x3ff6f7[_0x22bea4('0x273a')]['preproduction']=_0x5128f6[_0x22bea4('0x1944')];})[_0x4831c0('0x130a')](function(_0x26bf51){const _0x3735d7=_0x4831c0;_0x4e1c80[_0x3735d7('0x52a')]({'title':_0x26bf51[_0x3735d7('0x13ee')]?_0x3735d7('0x2168')+_0x26bf51[_0x3735d7('0x13ee')]+'\x20-\x20'+_0x26bf51[_0x3735d7('0x24a9')]:'SYSTEM:GETsquareProject','msg':_0x26bf51['data']?JSON[_0x3735d7('0x258a')](_0x26bf51[_0x3735d7('0x5a5')]):_0x26bf51[_0x3735d7('0x1ff0')]()});});}function _0x45f1ae(){const _0x4f299d=_0x285408;_0x510d00['go'](_0x4f299d('0x24ed'),{},{'reload':_0x4f299d('0x24ed')});}}const _0x4aabdd=_0xa30415;_0xbf64cc['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1248'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d70'),_0x189033('0xba1')];function _0xbf64cc(_0x16deba,_0x4c4ef6,_0x1aaaa7,_0x10db25,_0x560a87,_0x2f7071,_0x27315c,_0x2c1756,_0x223b85,_0xd15f27,_0x39ad24,_0x367a9e,_0x563c92){const _0x419126=_0x189033,_0x27203e=this;_0x27203e['currentUser']=_0x563c92[_0x419126('0x20b2')](),_0x27203e['projects']=_0x10db25||{'count':0x0,'rows':[]},_0x27203e[_0x419126('0x2a')]=_0x560a87,_0x27203e['userProfileSection']=_0x2f7071&&_0x2f7071[_0x419126('0x50d')]==0x1?_0x2f7071[_0x419126('0xf5d')][0x0]:null,_0x27203e[_0x419126('0x1134')]=_0x563c92[_0x419126('0x142a')](_0x27203e[_0x419126('0x22df')]?_0x27203e[_0x419126('0x22df')][_0x419126('0x1134')]:null),_0x27203e[_0x419126('0x5c4')]=_0x419126('0x1248'),_0x27203e['listOrder']='',_0x27203e[_0x419126('0x1ce2')]=null,_0x27203e['selectedProjects']=[],_0x27203e['query']={'fields':'id,name,description,notes','sort':'-updatedAt','limit':0xa,'page':0x1},_0x27203e['editstate']=_0x343e2e,_0x27203e[_0x419126('0x194f')]=_0x3f5750,_0x27203e[_0x419126('0x53')]=_0x57529b,_0x27203e[_0x419126('0x20b8')]=_0x3287a1,_0x27203e['createOrEditProject']=_0x4dec36,_0x27203e['deleteProject']=_0x1a1fc0,_0x27203e[_0x419126('0x1dd4')]=_0x3cd944,_0x27203e[_0x419126('0x115b')]=_0x33318d,_0x27203e['deselectProjects']=_0x5f3f18,_0x27203e[_0x419126('0x159b')]=_0x123fa0;function _0x343e2e(_0x4c1b2d){const _0x5da1b1=_0x419126;_0x4c4ef6['go'](_0x5da1b1('0x1c81'),{'id':_0x4c1b2d['id'],'crudPermissions':_0x27203e['crudPermissions']});}function _0x3f5750(_0x12471c,_0x4c6e64){const _0x4c5968=_0x419126,_0x3a8023=_0x223b85[_0x4c5968('0x1c6f')]()[_0x4c5968('0xf28')](_0x4c5968('0xce3'))[_0x4c5968('0x26e3')](_0x4c5968('0xed5')+_0x12471c[_0x4c5968('0x60a')]+''+_0x4c5968('0x1ee7'))[_0x4c5968('0x1040')](_0x4c5968('0x2085'))[_0x4c5968('0xe42')](_0x4c6e64)['ok']('OK')['cancel'](_0x4c5968('0x16b8'));_0x223b85[_0x4c5968('0x1d4')](_0x3a8023)[_0x4c5968('0x683')](function(){_0x1a1fc0(_0x12471c);},function(){const _0x335d19=_0x4c5968;console['log'](_0x335d19('0x16b8'));});}let _0x717be5=!![],_0x2cc3a3=0x1;_0x16deba['$watch']('vm.query.filter',function(_0x38d109,_0x20e3c7){const _0x5fbec7=_0x419126;_0x717be5?_0x39ad24(function(){_0x717be5=![];}):(!_0x20e3c7&&(_0x2cc3a3=_0x27203e[_0x5fbec7('0x23a2')][_0x5fbec7('0xdf8')]),_0x38d109!==_0x20e3c7&&(_0x27203e['query'][_0x5fbec7('0xdf8')]=0x1),!_0x38d109&&(_0x27203e[_0x5fbec7('0x23a2')]['page']=_0x2cc3a3),_0x27203e[_0x5fbec7('0x20b8')]());});function _0x57529b(_0x1142fd){const _0x1c68b0=_0x419126;_0x27203e[_0x1c68b0('0x1248')]=_0x1142fd||{'count':0x0,'rows':[]};}function _0x3287a1(){const _0x27aa87=_0x419126;_0x27203e[_0x27aa87('0x23a2')][_0x27aa87('0x1cc8')]=(_0x27203e[_0x27aa87('0x23a2')][_0x27aa87('0xdf8')]-0x1)*_0x27203e['query'][_0x27aa87('0x6f0')],_0x563c92[_0x27aa87('0xca1')](_0x27aa87('0x20c2'))?_0x27203e['promise']=_0x27315c[_0x27aa87('0x27ea')][_0x27aa87('0x1e6e')](_0x27203e[_0x27aa87('0x23a2')],_0x57529b)[_0x27aa87('0xe53')]:(_0x27203e[_0x27aa87('0x23a2')]['id']=_0x27203e['userProfile']['id'],_0x27203e[_0x27aa87('0x23a2')][_0x27aa87('0x1aa')]=_0x27aa87('0x2506'),_0x27203e['promise']=_0x27315c[_0x27aa87('0x2a')]['getResources'](_0x27203e[_0x27aa87('0x23a2')],_0x57529b)['$promise']);}function _0x4dec36(_0x3bd37a,_0x57c468){const _0x32abf4=_0x419126;_0x223b85['show']({'controller':_0x32abf4('0x4d3'),'controllerAs':'vm','templateUrl':_0x1d0d91,'parent':angular[_0x32abf4('0x1fcc')](_0xd15f27[_0x32abf4('0x18e5')]),'targetEvent':_0x3bd37a,'clickOutsideToClose':!![],'locals':{'project':_0x57c468,'projects':_0x27203e[_0x32abf4('0x1248')][_0x32abf4('0xf5d')],'openFromEditor':null,'setting':null,'crudPermissions':_0x27203e[_0x32abf4('0x1134')]}});}function _0x1a1fc0(_0x8ce150){const _0xe0e873=_0x419126;_0x27315c[_0xe0e873('0x27ea')][_0xe0e873('0xd7e')]({'id':_0x8ce150['id']})['$promise'][_0xe0e873('0x683')](function(){const _0x255856=_0xe0e873;_0x2e3ca0()[_0x255856('0x3ec')](_0x27203e['projects']['rows'],{'id':_0x8ce150['id']}),_0x27203e[_0x255856('0x1248')][_0x255856('0x50d')]-=0x1,!_0x27203e[_0x255856('0x1248')][_0x255856('0xf5d')][_0x255856('0x1564')]&&_0x27203e['getProjects'](),_0x367a9e['success']({'title':_0x255856('0x49'),'msg':_0x8ce150['name']?_0x8ce150[_0x255856('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0xe0e873('0x130a')](function(_0x3f9b91){const _0x13a46b=_0xe0e873;if(_0x3f9b91[_0x13a46b('0x5a5')]&&_0x3f9b91[_0x13a46b('0x5a5')]['errors']&&_0x3f9b91['data']['errors'][_0x13a46b('0x1564')]){_0x27203e['errors']=_0x3f9b91[_0x13a46b('0x5a5')][_0x13a46b('0x17f')]||[{'message':_0x3f9b91[_0x13a46b('0x1ff0')](),'type':_0x13a46b('0x15f6')}];for(let _0xebc4f6=0x0;_0xebc4f6<_0x3f9b91[_0x13a46b('0x5a5')]['errors'][_0x13a46b('0x1564')];_0xebc4f6++){_0x367a9e['error']({'title':_0x3f9b91['data'][_0x13a46b('0x17f')][_0xebc4f6][_0x13a46b('0xcf0')],'msg':_0x3f9b91[_0x13a46b('0x5a5')][_0x13a46b('0x17f')][_0xebc4f6][_0x13a46b('0x8c2')]});}}else _0x367a9e['error']({'title':_0x3f9b91['status']?_0x13a46b('0x2168')+_0x3f9b91[_0x13a46b('0x13ee')]+_0x13a46b('0xbf6')+_0x3f9b91[_0x13a46b('0x24a9')]:_0x13a46b('0x15f6'),'msg':_0x3f9b91['data']?JSON['stringify'](_0x3f9b91[_0x13a46b('0x5a5')][_0x13a46b('0x8c2')]):_0x3f9b91[_0x13a46b('0x8c2')]||_0x3f9b91[_0x13a46b('0x1ff0')]()});});}function _0x3cd944(){const _0x14f37d=_0x419126,_0x3516e9=angular[_0x14f37d('0x1a86')](_0x27203e['selectedProjects']);return _0x27203e['selectedProjects']=[],_0x3516e9;}function _0x33318d(_0x1deda8){const _0x368043=_0x419126,_0x583e39=_0x223b85[_0x368043('0x1c6f')]()[_0x368043('0xf28')](_0x368043('0x151c'))[_0x368043('0x26e3')](''+_0x27203e['selectedProjects'][_0x368043('0x1564')]+_0x368043('0x93c')+_0x368043('0x1ee7'))[_0x368043('0x1040')](_0x368043('0x14a1'))[_0x368043('0xe42')](_0x1deda8)['ok']('OK')['cancel'](_0x368043('0x16b8'));_0x223b85[_0x368043('0x1d4')](_0x583e39)[_0x368043('0x683')](function(){const _0x4021e0=_0x368043;_0x27203e[_0x4021e0('0x25e3')]['forEach'](function(_0x2052a1){_0x1a1fc0(_0x2052a1);}),_0x27203e[_0x4021e0('0x25e3')]=[];});}function _0x5f3f18(){const _0x40ffc4=_0x419126;_0x27203e[_0x40ffc4('0x25e3')]=[];}function _0x123fa0(){const _0x2408df=_0x419126;_0x27203e['selectedProjects']=_0x27203e[_0x2408df('0x1248')][_0x2408df('0xf5d')];}}const _0x14a9a0=_0xbf64cc;_0x58f327[_0x189033('0x14be')]=[_0x189033('0x1398')];function _0x58f327(_0x5af7f9){const _0x472ad1=_0x189033;_0x5af7f9[_0x472ad1('0x2598')](_0x472ad1('0x24ed'),{'url':'/projects','views':{'content@app':{'templateUrl':_0xdb16b3,'controller':'ProjectsController\x20as\x20vm'}},'resolve':{'projects':['apiResolver',_0x472ad1('0xba1'),function(_0x401770,_0x392e91){const _0x2987c3=_0x472ad1;return _0x392e91[_0x2987c3('0xca1')](_0x2987c3('0x20c2'))?_0x401770[_0x2987c3('0xed7')](_0x2987c3('0x903'),{'fields':'id,name,description,notes','sort':_0x2987c3('0x60a'),'limit':0xa,'offset':0x0}):_0x401770[_0x2987c3('0xed7')]('userProfile@getResources',{'id':_0x392e91[_0x2987c3('0x20b2')]()[_0x2987c3('0x2f')],'section':_0x2987c3('0x2506'),'fields':'id,name,description,notes','sort':'name','limit':0xa,'offset':0x0});}],'userProfile':[_0x472ad1('0x4b1'),_0x472ad1('0xba1'),function(_0x2bae37,_0x1a398e){const _0x5c97f6=_0x472ad1;return _0x2bae37[_0x5c97f6('0xed7')](_0x5c97f6('0x1464'),{'fields':_0x5c97f6('0x16f'),'id':_0x1a398e[_0x5c97f6('0x20b2')]()[_0x5c97f6('0x2f')]});}],'userProfileSection':[_0x472ad1('0x4b1'),'Auth',function(_0x34b214,_0x1d9a6f){const _0x4d7668=_0x472ad1;return _0x34b214[_0x4d7668('0xed7')](_0x4d7668('0x360'),{'fields':_0x4d7668('0x1f47'),'userProfileId':_0x1d9a6f[_0x4d7668('0x20b2')]()[_0x4d7668('0x2f')],'sectionId':0x44f});}]},'authenticate':!![],'permissionId':0x44f,'bodyClass':'callysquare'})['state'](_0x472ad1('0x1c81'),{'url':_0x472ad1('0x2196'),'views':{'content@app':{'templateUrl':_0x558166,'controller':'ProjectController\x20as\x20vm'}},'params':{'crudPermissions':undefined},'resolve':{'project':['apiResolver',_0x472ad1('0x8ea'),function(_0x256d68,_0xeeabed){const _0x5f2597=_0x472ad1;return _0x256d68[_0x5f2597('0xed7')](_0x5f2597('0x903'),{'id':_0xeeabed['id']});}],'users':['apiResolver','Auth',function(_0x5d63c8,_0xe45de9){const _0x2ee3ed=_0x472ad1;return _0xe45de9[_0x2ee3ed('0xca1')]('admin')?_0x5d63c8['resolve'](_0x2ee3ed('0x25c9'),{'fields':_0x2ee3ed('0x2868'),'sort':_0x2ee3ed('0x60a'),'nolimit':!![]}):_0x5d63c8[_0x2ee3ed('0xed7')](_0x2ee3ed('0x191b'),{'id':_0xe45de9[_0x2ee3ed('0x20b2')]()[_0x2ee3ed('0x2f')],'section':_0x2ee3ed('0x2139'),'mergeResources':!![],'fields':_0x2ee3ed('0x2868'),'sort':'name','nolimit':!![]});}],'trunks':[_0x472ad1('0x4b1'),_0x472ad1('0xba1'),function(_0x5a2fcb,_0xe4f089){const _0x4c1e63=_0x472ad1;return _0xe4f089['hasRole']('admin')?_0x5a2fcb[_0x4c1e63('0xed7')](_0x4c1e63('0x18a8'),{'fields':'id,name','sort':_0x4c1e63('0x60a'),'nolimit':!![]}):_0x5a2fcb[_0x4c1e63('0xed7')]('userProfile@getResources',{'id':_0xe4f089['getCurrentUser']()[_0x4c1e63('0x2f')],'section':_0x4c1e63('0x485'),'fields':'id,name','sort':_0x4c1e63('0x60a'),'nolimit':!![]});}],'queues':[_0x472ad1('0x4b1'),'Auth',function(_0x59d85,_0x549b1f){const _0x2aca74=_0x472ad1;return _0x549b1f['hasRole'](_0x2aca74('0x20c2'))?_0x59d85['resolve'](_0x2aca74('0x2730'),{'type':'inbound','fields':_0x2aca74('0xa10'),'sort':_0x2aca74('0x60a'),'nolimit':!![]}):_0x59d85['resolve']('userProfile@getResources',{'id':_0x549b1f['getCurrentUser']()[_0x2aca74('0x2f')],'section':'VoiceQueues','type':'inbound','fields':_0x2aca74('0xa10'),'sort':_0x2aca74('0x60a'),'nolimit':!![]});}],'sounds':[_0x472ad1('0x4b1'),'Auth',function(_0x2104dd,_0x9996b5){const _0x5c499a=_0x472ad1;return _0x9996b5[_0x5c499a('0xca1')]('admin')?_0x2104dd['resolve'](_0x5c499a('0x251e'),{'fields':_0x5c499a('0xa10'),'sort':'name','nolimit':!![]}):_0x2104dd['resolve'](_0x5c499a('0x191b'),{'id':_0x9996b5['getCurrentUser']()[_0x5c499a('0x2f')],'section':_0x5c499a('0x628'),'fields':_0x5c499a('0xa10'),'sort':_0x5c499a('0x60a'),'nolimit':!![]});}],'variables':[_0x472ad1('0x4b1'),_0x472ad1('0xba1'),function(_0x50f941,_0x2475cb){const _0x36234a=_0x472ad1;return _0x2475cb[_0x36234a('0xca1')](_0x36234a('0x20c2'))?_0x50f941[_0x36234a('0xed7')](_0x36234a('0x1716'),{'fields':_0x36234a('0xa10'),'sort':_0x36234a('0x60a'),'nolimit':!![]}):_0x50f941[_0x36234a('0xed7')]('userProfile@getResources',{'id':_0x2475cb['getCurrentUser']()['userProfileId'],'section':_0x36234a('0x2095'),'fields':_0x36234a('0xa10'),'sort':_0x36234a('0x60a'),'nolimit':!![]});}],'databases':[_0x472ad1('0x4b1'),_0x472ad1('0xba1'),function(_0x32ae85,_0x3f0977){const _0x17da06=_0x472ad1;return _0x3f0977[_0x17da06('0xca1')](_0x17da06('0x20c2'))?_0x32ae85[_0x17da06('0xed7')](_0x17da06('0x2d7'),{'fields':'id,name','sort':_0x17da06('0x60a'),'nolimit':!![]}):_0x32ae85['resolve'](_0x17da06('0x191b'),{'id':_0x3f0977[_0x17da06('0x20b2')]()[_0x17da06('0x2f')],'section':_0x17da06('0x26fe'),'fields':_0x17da06('0xa10'),'sort':_0x17da06('0x60a'),'nolimit':!![]});}],'projects':['apiResolver',_0x472ad1('0xba1'),function(_0x55c1da,_0x7a201){const _0x53a20b=_0x472ad1;return _0x7a201['hasRole'](_0x53a20b('0x20c2'))?_0x55c1da[_0x53a20b('0xed7')](_0x53a20b('0x903'),{'fields':_0x53a20b('0xa10'),'sort':_0x53a20b('0x60a'),'nolimit':!![]}):_0x55c1da[_0x53a20b('0xed7')](_0x53a20b('0x191b'),{'id':_0x7a201[_0x53a20b('0x20b2')]()[_0x53a20b('0x2f')],'section':_0x53a20b('0x2506'),'fields':_0x53a20b('0xa10'),'sort':_0x53a20b('0x60a'),'nolimit':!![]});}],'contexts':[_0x472ad1('0x4b1'),_0x472ad1('0xba1'),function(_0x5d28b6,_0x2c979b){const _0x4e6111=_0x472ad1;return _0x2c979b[_0x4e6111('0xca1')]('admin')?_0x5d28b6[_0x4e6111('0xed7')](_0x4e6111('0x1bf9'),{'fields':_0x4e6111('0xa10'),'sort':_0x4e6111('0x60a'),'nolimit':!![]}):_0x5d28b6[_0x4e6111('0xed7')](_0x4e6111('0x191b'),{'id':_0x2c979b[_0x4e6111('0x20b2')]()[_0x4e6111('0x2f')],'section':'Contexts','fields':_0x4e6111('0xa10'),'sort':'name','nolimit':!![]});}],'intervals':['apiResolver','Auth',function(_0x1dda8b,_0x4954fe){const _0x571b67=_0x472ad1;return _0x4954fe[_0x571b67('0xca1')]('admin')?_0x1dda8b['resolve'](_0x571b67('0x175b'),{'fields':'id,name,IntervalId','sort':_0x571b67('0x60a'),'nolimit':!![]}):_0x1dda8b[_0x571b67('0xed7')]('userProfile@getResources',{'id':_0x4954fe['getCurrentUser']()[_0x571b67('0x2f')],'section':_0x571b67('0xb38'),'fields':_0x571b67('0x1b31'),'sort':'name','nolimit':!![]});}],'mailAccounts':[_0x472ad1('0x4b1'),'Auth',function(_0x5d7b2f,_0x4b3778){const _0x47c8cf=_0x472ad1;return _0x4b3778['hasRole'](_0x47c8cf('0x20c2'))?_0x5d7b2f[_0x47c8cf('0xed7')]('mailAccount@get',{'fields':_0x47c8cf('0xa10'),'sort':_0x47c8cf('0x60a'),'nolimit':!![]}):_0x5d7b2f['resolve'](_0x47c8cf('0x191b'),{'id':_0x4b3778['getCurrentUser']()[_0x47c8cf('0x2f')],'section':_0x47c8cf('0x2672'),'fields':_0x47c8cf('0xa10'),'sort':'name','nolimit':!![]});}],'templates':[_0x472ad1('0x4b1'),_0x472ad1('0xba1'),function(_0x512f2d,_0x3e654f){const _0x27a6a6=_0x472ad1;return _0x3e654f[_0x27a6a6('0xca1')](_0x27a6a6('0x20c2'))?_0x512f2d['resolve'](_0x27a6a6('0x256a'),{'fields':_0x27a6a6('0xa10'),'sort':'name','nolimit':!![]}):_0x512f2d[_0x27a6a6('0xed7')](_0x27a6a6('0x191b'),{'id':_0x3e654f['getCurrentUser']()['userProfileId'],'section':'Templates','fields':'id,name','sort':'name','nolimit':!![]});}],'lists':['apiResolver',_0x472ad1('0xba1'),function(_0x331bd9,_0x4302a6){const _0x255c86=_0x472ad1;return _0x4302a6[_0x255c86('0xca1')](_0x255c86('0x20c2'))?_0x331bd9['resolve']('cmList@get',{'fields':_0x255c86('0xa10'),'sort':_0x255c86('0x60a'),'nolimit':!![]}):_0x331bd9[_0x255c86('0xed7')](_0x255c86('0x191b'),{'id':_0x4302a6[_0x255c86('0x20b2')]()[_0x255c86('0x2f')],'section':_0x255c86('0x1114'),'fields':'id,name','sort':_0x255c86('0x60a'),'nolimit':!![]});}],'smsAccounts':[_0x472ad1('0x4b1'),_0x472ad1('0xba1'),function(_0x714b78,_0x2cf2b2){const _0x295e3d=_0x472ad1;return _0x2cf2b2[_0x295e3d('0xca1')](_0x295e3d('0x20c2'))?_0x714b78['resolve'](_0x295e3d('0xf29'),{'fields':_0x295e3d('0xa10'),'sort':_0x295e3d('0x60a'),'nolimit':!![]}):_0x714b78[_0x295e3d('0xed7')]('userProfile@getResources',{'id':_0x2cf2b2[_0x295e3d('0x20b2')]()[_0x295e3d('0x2f')],'section':_0x295e3d('0x334'),'fields':'id,name','sort':_0x295e3d('0x60a'),'nolimit':!![]});}],'pauses':[_0x472ad1('0x4b1'),_0x472ad1('0xba1'),function(_0xab4f7c,_0x49e4a9){const _0x315b33=_0x472ad1;return _0x49e4a9[_0x315b33('0xca1')](_0x315b33('0x20c2'))?_0xab4f7c[_0x315b33('0xed7')](_0x315b33('0x112'),{'fields':_0x315b33('0xa10'),'sort':'name','nolimit':!![]}):_0xab4f7c[_0x315b33('0xed7')](_0x315b33('0x191b'),{'id':_0x49e4a9[_0x315b33('0x20b2')]()[_0x315b33('0x2f')],'section':_0x315b33('0x1dcc'),'fields':_0x315b33('0xa10'),'sort':_0x315b33('0x60a'),'nolimit':!![]});}],'userProfileSection':[_0x472ad1('0x4b1'),'Auth',function(_0x56d6b0,_0x47d358){const _0xd6afcc=_0x472ad1;return _0x56d6b0[_0xd6afcc('0xed7')](_0xd6afcc('0x360'),{'fields':_0xd6afcc('0x1f47'),'userProfileId':_0x47d358[_0xd6afcc('0x20b2')]()[_0xd6afcc('0x2f')],'sectionId':0x44f});}]},'authenticate':!![],'permissionId':0x44f,'bodyClass':_0x472ad1('0x1c5e')});}angular[_0x189033('0x1e26')]('app.callysquare.projects',[])['config'](_0x58f327)[_0x189033('0x1da3')](_0x189033('0x4d3'),_0x77f9fb)['controller'](_0x189033('0x1dd1'),_0x5767a0)['directive'](_0x189033('0x7ac'),_0x22bd63)[_0x189033('0x1f97')]('ispeechAsrModel',_0x4cc3c0)[_0x189033('0x1f97')](_0x189033('0xd54'),_0x2634d7)[_0x189033('0x1f97')]('ispeechTtsLanguage',_0x45f47f)[_0x189033('0x1f97')](_0x189033('0x7d4'),_0x5a5185)['factory'](_0x189033('0xbaa'),_0x5b1b78)[_0x189033('0x1f97')]('googleAsrLanguage',_0x5302c8)[_0x189033('0x1f97')](_0x189033('0x10e'),_0x2bb589)[_0x189033('0x1f97')](_0x189033('0x1b4c'),_0x3d0554)['factory'](_0x189033('0xfc2'),_0x3e3fe9)[_0x189033('0x1f97')](_0x189033('0x18a6'),_0x10f3d9)[_0x189033('0x1f97')](_0x189033('0x708'),_0x2a39c1)[_0x189033('0x1da3')](_0x189033('0x26dc'),_0x110f97)[_0x189033('0x1da3')](_0x189033('0x5e1'),_0x21c83f)[_0x189033('0x1da3')](_0x189033('0x1d95'),_0x4d339e)[_0x189033('0x1da3')]('MxGraphOpenProjectController',_0x5d8471)[_0x189033('0x1da3')](_0x189033('0x21c4'),_0xf62afa)['controller'](_0x189033('0xc57'),_0x26454c)['controller'](_0x189033('0x1db9'),_0x4aabdd)[_0x189033('0x1da3')](_0x189033('0xe1c'),_0x14a9a0);const _0x177665=_0x180212['p']+'src/js/modules/main/apps/callysquare/views/odbcs/odbcs.html/odbcs.html',_0x267cd4=_0x180212['p']+'src/js/modules/main/apps/callysquare/views/squareRecordings/squareRecordings.html/squareRecordings.html';_0x173345[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x77d'),_0x189033('0x21d6'),_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),'crudPermissions'];function _0x173345(_0x33b444,_0x2df93f,_0x3cd2b3,_0x6827a6,_0x82b941,_0xb272c6,_0x1ada3e,_0xac2e6f,_0x161e36,_0x3a5096,_0x5e2093,_0x1b57f1,_0x2d144e,_0x59d923){const _0x26cde2=_0x189033,_0x10efc0=this;_0x10efc0[_0x26cde2('0x11ed')]=_0x5e2093['getCurrentUser'](),_0x10efc0['errors']=[],_0x10efc0['setting']=_0x2d144e,_0x10efc0[_0x26cde2('0xace')]=_0x1b57f1,_0x10efc0['crudPermissions']=_0x59d923,_0x10efc0[_0x26cde2('0x258d')]={},_0x10efc0[_0x26cde2('0x19b2')]=_0x10efc0[_0x26cde2('0x260a')]&&_0x10efc0[_0x26cde2('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x10efc0[_0x26cde2('0xf28')]=_0x26cde2('0x218d'),_0x10efc0['odbc']=angular[_0x26cde2('0x1a86')](_0x161e36),_0x10efc0[_0x26cde2('0x77d')]=_0xac2e6f,_0x10efc0[_0x26cde2('0x2465')]=![];!_0x10efc0[_0x26cde2('0x21d6')]&&(_0x10efc0[_0x26cde2('0x21d6')]={},_0x10efc0[_0x26cde2('0xf28')]=_0x26cde2('0x1494'),_0x10efc0[_0x26cde2('0x2465')]=!![]);_0x10efc0[_0x26cde2('0x1e87')]=_0x12f33b,_0x10efc0[_0x26cde2('0x13fc')]=_0x269c12,_0x10efc0[_0x26cde2('0x1a80')]=_0x32a7e3,_0x10efc0[_0x26cde2('0x16b3')]=_0x1f93cd,_0x10efc0['closeDialog']=_0xcad686;function _0x12f33b(){const _0x1df873=_0x26cde2;_0x10efc0[_0x1df873('0x17f')]=[],_0x3a5096[_0x1df873('0x39a')][_0x1df873('0xb0a')](_0x10efc0[_0x1df873('0x21d6')])[_0x1df873('0xe53')]['then'](function(_0x6496f3){const _0xb5199f=_0x1df873;_0x10efc0[_0xb5199f('0x77d')]['unshift'](_0x6496f3[_0xb5199f('0x24e1')]()),_0x1ada3e['success']({'title':'Odbc\x20properly\x20created','msg':_0x10efc0[_0xb5199f('0x21d6')][_0xb5199f('0x60a')]?_0x10efc0[_0xb5199f('0x21d6')][_0xb5199f('0x60a')]+_0xb5199f('0x14b5'):''}),_0xcad686(_0x6496f3);})['catch'](function(_0x23c275){const _0x1cc1f9=_0x1df873;if(_0x23c275[_0x1cc1f9('0x5a5')]&&_0x23c275['data'][_0x1cc1f9('0x17f')]&&_0x23c275[_0x1cc1f9('0x5a5')][_0x1cc1f9('0x17f')][_0x1cc1f9('0x1564')]){_0x10efc0['errors']=_0x23c275[_0x1cc1f9('0x5a5')][_0x1cc1f9('0x17f')]||[{'message':_0x23c275[_0x1cc1f9('0x1ff0')](),'type':_0x1cc1f9('0x254e')}];for(let _0x25e6ec=0x0;_0x25e6ec<_0x23c275['data'][_0x1cc1f9('0x17f')][_0x1cc1f9('0x1564')];_0x25e6ec+=0x1){_0x1ada3e[_0x1cc1f9('0x52a')]({'title':_0x23c275['data']['errors'][_0x25e6ec][_0x1cc1f9('0xcf0')],'msg':_0x23c275[_0x1cc1f9('0x5a5')]['errors'][_0x25e6ec]['message']});}}else _0x1ada3e[_0x1cc1f9('0x52a')]({'title':_0x23c275[_0x1cc1f9('0x13ee')]?_0x1cc1f9('0x2168')+_0x23c275[_0x1cc1f9('0x13ee')]+'\x20-\x20'+_0x23c275[_0x1cc1f9('0x24a9')]:_0x1cc1f9('0x254e'),'msg':_0x23c275['data']?JSON[_0x1cc1f9('0x258a')](_0x23c275[_0x1cc1f9('0x5a5')][_0x1cc1f9('0x8c2')]):_0x23c275[_0x1cc1f9('0x1ff0')]()});});}function _0x269c12(){const _0x1b6b20=_0x26cde2;_0x10efc0[_0x1b6b20('0x17f')]=[],_0x3a5096['squareOdbc'][_0x1b6b20('0x2480')]({'id':_0x10efc0[_0x1b6b20('0x21d6')]['id']},_0x10efc0[_0x1b6b20('0x21d6')])[_0x1b6b20('0xe53')][_0x1b6b20('0x683')](function(_0x42a55a){const _0x3bff64=_0x1b6b20,_0x3e38fc=_0x2e3ca0()['find'](_0x10efc0[_0x3bff64('0x77d')],{'id':_0x42a55a['id']});_0x3e38fc&&_0x2e3ca0()[_0x3bff64('0xf22')](_0x3e38fc,_0x2e3ca0()[_0x3bff64('0x24d0')](_0x42a55a[_0x3bff64('0x24e1')](),_0x2e3ca0()[_0x3bff64('0x55e')](_0x3e38fc))),_0x1ada3e['success']({'title':'Odbc\x20properly\x20saved!','msg':_0x10efc0[_0x3bff64('0x21d6')]['name']?_0x10efc0[_0x3bff64('0x21d6')]['name']+_0x3bff64('0xf59'):''}),_0xcad686(_0x42a55a);})[_0x1b6b20('0x130a')](function(_0x4d082b){const _0x43f5a4=_0x1b6b20;if(_0x4d082b[_0x43f5a4('0x5a5')]&&_0x4d082b['data'][_0x43f5a4('0x17f')]&&_0x4d082b['data'][_0x43f5a4('0x17f')][_0x43f5a4('0x1564')]){_0x10efc0[_0x43f5a4('0x17f')]=_0x4d082b['data'][_0x43f5a4('0x17f')]||[{'message':_0x4d082b[_0x43f5a4('0x1ff0')](),'type':_0x43f5a4('0x2e7')}];for(let _0x59b9f8=0x0;_0x59b9f8<_0x4d082b[_0x43f5a4('0x5a5')][_0x43f5a4('0x17f')][_0x43f5a4('0x1564')];_0x59b9f8++){_0x1ada3e['error']({'title':_0x4d082b['data'][_0x43f5a4('0x17f')][_0x59b9f8]['type'],'msg':_0x4d082b['data'][_0x43f5a4('0x17f')][_0x59b9f8]['message']});}}else _0x1ada3e['error']({'title':_0x4d082b[_0x43f5a4('0x13ee')]?'API:'+_0x4d082b[_0x43f5a4('0x13ee')]+_0x43f5a4('0xbf6')+_0x4d082b[_0x43f5a4('0x24a9')]:_0x43f5a4('0x2e7'),'msg':_0x4d082b[_0x43f5a4('0x5a5')]?JSON['stringify'](_0x4d082b[_0x43f5a4('0x5a5')][_0x43f5a4('0x8c2')]):_0x4d082b['toString']()});});}function _0x32a7e3(_0x54639a){const _0x3f4925=_0x26cde2;_0x10efc0[_0x3f4925('0x17f')]=[];const _0xd95387=_0x6827a6[_0x3f4925('0x1c6f')]()['title'](_0x3f4925('0x4d'))[_0x3f4925('0xa6a')](_0x3f4925('0x48e'))['ariaLabel'](_0x3f4925('0x152d'))['ok'](_0x3f4925('0x2307'))[_0x3f4925('0x19fb')]('Cancel')['targetEvent'](_0x54639a);_0x6827a6[_0x3f4925('0x1d4')](_0xd95387)[_0x3f4925('0x683')](function(){const _0x3841fe=_0x3f4925;_0x3a5096[_0x3841fe('0x39a')][_0x3841fe('0xd7e')]({'id':_0x10efc0[_0x3841fe('0x21d6')]['id']})['$promise']['then'](function(){const _0x5b70d2=_0x3841fe;_0x2e3ca0()[_0x5b70d2('0x3ec')](_0x10efc0[_0x5b70d2('0x77d')],{'id':_0x10efc0[_0x5b70d2('0x21d6')]['id']}),_0x1ada3e[_0x5b70d2('0x53')]({'title':_0x5b70d2('0x1b5c'),'msg':(_0x10efc0[_0x5b70d2('0x21d6')][_0x5b70d2('0x60a')]||_0x5b70d2('0x21d6'))+_0x5b70d2('0x194d')}),_0xcad686(_0x10efc0[_0x5b70d2('0x21d6')]);})[_0x3841fe('0x130a')](function(_0x2658d5){const _0x1df4f4=_0x3841fe;if(_0x2658d5[_0x1df4f4('0x5a5')]&&_0x2658d5[_0x1df4f4('0x5a5')][_0x1df4f4('0x17f')]&&_0x2658d5[_0x1df4f4('0x5a5')][_0x1df4f4('0x17f')]['length']){_0x10efc0[_0x1df4f4('0x17f')]=_0x2658d5['data'][_0x1df4f4('0x17f')]||[{'message':_0x2658d5[_0x1df4f4('0x1ff0')](),'type':'api.squareOdbc.delete'}];for(let _0x40f698=0x0;_0x40f698<_0x2658d5[_0x1df4f4('0x5a5')][_0x1df4f4('0x17f')][_0x1df4f4('0x1564')];_0x40f698++){_0x1ada3e['error']({'title':_0x2658d5[_0x1df4f4('0x5a5')][_0x1df4f4('0x17f')][_0x40f698]['type'],'msg':_0x2658d5['data'][_0x1df4f4('0x17f')][_0x40f698][_0x1df4f4('0x8c2')]});}}else _0x1ada3e['error']({'title':_0x2658d5[_0x1df4f4('0x13ee')]?'API:'+_0x2658d5[_0x1df4f4('0x13ee')]+_0x1df4f4('0xbf6')+_0x2658d5['statusText']:_0x1df4f4('0x1afb'),'msg':_0x2658d5[_0x1df4f4('0x5a5')]?JSON[_0x1df4f4('0x258a')](_0x2658d5['data'][_0x1df4f4('0x8c2')]):_0x2658d5[_0x1df4f4('0x8c2')]||_0x2658d5[_0x1df4f4('0x1ff0')]()});});},function(){});}function _0x1f93cd(_0x137357){return _0x137357===null?undefined:new Date(_0x137357);}function _0xcad686(_0x575b85){_0x6827a6['hide'](_0x575b85);}}const _0x2b664e=_0x173345,_0x76f1e1=_0x180212['p']+'src/js/modules/main/apps/callysquare/views/odbcs/create/dialog.html/dialog.html';_0x577f75[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),'$translate',_0x189033('0x77d'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),'license',_0x189033('0x260a')];function _0x577f75(_0x2fd95f,_0x3b9d26,_0x4fd45b,_0x41c035,_0x14cd31,_0x5a11bf,_0x3d4210,_0x5e2e7d,_0x3081a6,_0x4595dd,_0x4165dc,_0x133cd7,_0x2931dd,_0x4e5c4e,_0x575d76,_0xd20a9e,_0x2238cd){const _0x4fbfb3=_0x189033,_0xd30a4a=this;_0xd30a4a['license']=_0xd20a9e,_0xd30a4a[_0x4fbfb3('0x260a')]=_0x2238cd,_0xd30a4a[_0x4fbfb3('0x11ed')]=_0x575d76[_0x4fbfb3('0x20b2')](),_0xd30a4a[_0x4fbfb3('0x77d')]=_0x3081a6||{'count':0x0,'rows':[]},_0xd30a4a[_0x4fbfb3('0x2a')]=_0x4595dd,_0xd30a4a['userProfileSection']=_0x4165dc&&_0x4165dc[_0x4fbfb3('0x50d')]==0x1?_0x4165dc[_0x4fbfb3('0xf5d')][0x0]:null,_0xd30a4a[_0x4fbfb3('0x1134')]=_0x575d76[_0x4fbfb3('0x142a')](_0xd30a4a[_0x4fbfb3('0x22df')]?_0xd30a4a[_0x4fbfb3('0x22df')][_0x4fbfb3('0x1134')]:null),_0xd30a4a[_0x4fbfb3('0x5c4')]='odbcs',_0xd30a4a[_0x4fbfb3('0x247')]='',_0xd30a4a[_0x4fbfb3('0x1ce2')]=null,_0xd30a4a[_0x4fbfb3('0x13dd')]=[],_0xd30a4a[_0x4fbfb3('0x23a2')]={'fields':_0x4fbfb3('0xd6e'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0xd30a4a[_0x4fbfb3('0x1249')]=_0xc891d2,_0xd30a4a[_0x4fbfb3('0x7b')]=_0x2297cd,_0xd30a4a[_0x4fbfb3('0x194f')]=_0x3602fc,_0xd30a4a['success']=_0x3429e8,_0xd30a4a[_0x4fbfb3('0x1848')]=_0x205354,_0xd30a4a['createOrEditOdbc']=_0x426989,_0xd30a4a[_0x4fbfb3('0x1a80')]=_0x343dd9,_0xd30a4a[_0x4fbfb3('0xdeb')]=_0x4be647,_0xd30a4a[_0x4fbfb3('0xcc0')]=_0x1420cb,_0xd30a4a[_0x4fbfb3('0xa56')]=_0x1af8dd,_0xd30a4a[_0x4fbfb3('0x1f62')]=_0x3dd182;function _0xc891d2(_0x182e6b,_0x372a00){const _0x14dfe=_0x4fbfb3;_0x14cd31[_0x14dfe('0x1d4')]({'controller':_0x14dfe('0xce4'),'controllerAs':'vm','templateUrl':_0x76f1e1,'parent':angular[_0x14dfe('0x1fcc')](_0x5a11bf[_0x14dfe('0x18e5')]),'targetEvent':_0x372a00,'clickOutsideToClose':!![],'locals':{'odbc':_0x182e6b,'odbcs':_0xd30a4a['odbcs'][_0x14dfe('0xf5d')],'license':_0xd30a4a[_0x14dfe('0xace')],'setting':null,'crudPermissions':_0xd30a4a[_0x14dfe('0x1134')]}});}function _0x2297cd(_0x5f156d){const _0x1ab7b4=_0x4fbfb3;return _0x133cd7['squareOdbc'][_0x1ab7b4('0x237c')]({'id':_0x5f156d['id']})[_0x1ab7b4('0xe53')][_0x1ab7b4('0x683')](function(){const _0x24c404=_0x1ab7b4;_0x4e5c4e[_0x24c404('0x53')]({'title':_0x24c404('0x25fa'),'msg':'Connection\x20succeded!'});})['catch'](function(_0x208639){const _0x53741f=_0x1ab7b4;_0x4e5c4e[_0x53741f('0x52a')]({'title':_0x53741f('0x25fa'),'msg':_0x208639[_0x53741f('0x5a5')]?JSON[_0x53741f('0x258a')](_0x208639[_0x53741f('0x5a5')]):_0x208639['toString']()});});}function _0x3602fc(_0xb5eb48,_0xa83108){const _0x143937=_0x4fbfb3,_0x4f907c=_0x14cd31['confirm']()[_0x143937('0xf28')](_0x143937('0x1b01')+_0x2e3ca0()[_0x143937('0x1e03')]('odbc')+'?')['htmlContent'](''+(_0xb5eb48[_0x143937('0x60a')]||_0x143937('0x21d6'))+_0x143937('0x20f1')+_0x143937('0x1ee7'))[_0x143937('0x1040')](_0x143937('0xcba'))[_0x143937('0xe42')](_0xa83108)['ok']('OK')['cancel'](_0x143937('0x16b8'));_0x14cd31[_0x143937('0x1d4')](_0x4f907c)[_0x143937('0x683')](function(){_0x343dd9(_0xb5eb48);},function(){const _0x197aa7=_0x143937;console[_0x197aa7('0x1b2b')](_0x197aa7('0x16b8'));});}let _0x1ac1fe=!![],_0x1281da=0x1;_0x2fd95f[_0x4fbfb3('0x186d')]('vm.query.filter',function(_0xfaf643,_0x325c09){const _0x122faa=_0x4fbfb3;_0x1ac1fe?_0x3d4210(function(){_0x1ac1fe=![];}):(!_0x325c09&&(_0x1281da=_0xd30a4a[_0x122faa('0x23a2')]['page']),_0xfaf643!==_0x325c09&&(_0xd30a4a['query'][_0x122faa('0xdf8')]=0x1),!_0xfaf643&&(_0xd30a4a[_0x122faa('0x23a2')][_0x122faa('0xdf8')]=_0x1281da),_0xd30a4a['getODBC']());});function _0x3429e8(_0x408dfe){const _0x4862b0=_0x4fbfb3;_0xd30a4a[_0x4862b0('0x77d')]=_0x408dfe||{'count':0x0,'rows':[]};}function _0x205354(){const _0x28ef81=_0x4fbfb3;_0xd30a4a[_0x28ef81('0x23a2')][_0x28ef81('0x1cc8')]=(_0xd30a4a[_0x28ef81('0x23a2')][_0x28ef81('0xdf8')]-0x1)*_0xd30a4a['query'][_0x28ef81('0x6f0')],_0x575d76[_0x28ef81('0xca1')](_0x28ef81('0x20c2'))?_0xd30a4a[_0x28ef81('0x1883')]=_0x133cd7[_0x28ef81('0x39a')][_0x28ef81('0x1e6e')](_0xd30a4a[_0x28ef81('0x23a2')],_0x3429e8)['$promise']:(_0xd30a4a[_0x28ef81('0x23a2')]['id']=_0xd30a4a[_0x28ef81('0x2a')]['id'],_0xd30a4a[_0x28ef81('0x23a2')][_0x28ef81('0x1aa')]=_0x28ef81('0x26fe'),_0xd30a4a[_0x28ef81('0x1883')]=_0x133cd7[_0x28ef81('0x2a')][_0x28ef81('0x241d')](_0xd30a4a[_0x28ef81('0x23a2')],_0x3429e8)[_0x28ef81('0xe53')]);}function _0x426989(_0x24e10e,_0x3ae75b){const _0x375873=_0x4fbfb3;_0x14cd31[_0x375873('0x1d4')]({'controller':_0x375873('0xce4'),'controllerAs':'vm','templateUrl':_0x76f1e1,'parent':angular['element'](_0x5a11bf[_0x375873('0x18e5')]),'targetEvent':_0x24e10e,'clickOutsideToClose':!![],'locals':{'odbc':_0x3ae75b,'odbcs':_0xd30a4a[_0x375873('0x77d')][_0x375873('0xf5d')],'license':_0xd30a4a[_0x375873('0xace')],'setting':_0xd30a4a[_0x375873('0x260a')],'crudPermissions':_0xd30a4a['crudPermissions']}});}function _0x343dd9(_0x1266eb){const _0x38ec3c=_0x4fbfb3;_0x133cd7[_0x38ec3c('0x39a')][_0x38ec3c('0xd7e')]({'id':_0x1266eb['id']})[_0x38ec3c('0xe53')]['then'](function(){const _0x51c0ad=_0x38ec3c;_0x2e3ca0()[_0x51c0ad('0x3ec')](_0xd30a4a[_0x51c0ad('0x77d')][_0x51c0ad('0xf5d')],{'id':_0x1266eb['id']}),_0xd30a4a[_0x51c0ad('0x77d')][_0x51c0ad('0x50d')]-=0x1,!_0xd30a4a[_0x51c0ad('0x77d')][_0x51c0ad('0xf5d')]['length']&&_0xd30a4a[_0x51c0ad('0x1848')](),_0x4e5c4e['success']({'title':_0x2e3ca0()['startCase'](_0x51c0ad('0xa87'))+'\x20deleted!','msg':_0x1266eb[_0x51c0ad('0x60a')]?_0x1266eb['name']+'\x20has\x20been\x20deleted!':''});})[_0x38ec3c('0x130a')](function(_0x36b460){const _0x18bc25=_0x38ec3c;if(_0x36b460[_0x18bc25('0x5a5')]&&_0x36b460[_0x18bc25('0x5a5')][_0x18bc25('0x17f')]&&_0x36b460['data'][_0x18bc25('0x17f')]['length']){_0xd30a4a[_0x18bc25('0x17f')]=_0x36b460['data'][_0x18bc25('0x17f')]||[{'message':_0x36b460[_0x18bc25('0x1ff0')](),'type':'SYSTEM:DELETEsquareOdbc'}];for(let _0x703e81=0x0;_0x703e81<_0x36b460['data'][_0x18bc25('0x17f')][_0x18bc25('0x1564')];_0x703e81++){_0x4e5c4e['error']({'title':_0x36b460['data'][_0x18bc25('0x17f')][_0x703e81][_0x18bc25('0xcf0')],'msg':_0x36b460[_0x18bc25('0x5a5')][_0x18bc25('0x17f')][_0x703e81]['message']});}}else _0x4e5c4e[_0x18bc25('0x52a')]({'title':_0x36b460[_0x18bc25('0x13ee')]?_0x18bc25('0x2168')+_0x36b460['status']+'\x20-\x20'+_0x36b460[_0x18bc25('0x24a9')]:_0x18bc25('0x1d0f'),'msg':_0x36b460['data']?JSON['stringify'](_0x36b460[_0x18bc25('0x5a5')][_0x18bc25('0x8c2')]):_0x36b460[_0x18bc25('0x8c2')]||_0x36b460['toString']()});});}function _0x4be647(){const _0x1e7a53=_0x4fbfb3,_0x15c94c=angular['copy'](_0xd30a4a[_0x1e7a53('0x13dd')]);return _0xd30a4a['selectedODBC']=[],_0x15c94c;}function _0x1420cb(_0xe7471c){const _0x537fc4=_0x4fbfb3,_0x4549f7=_0x14cd31['confirm']()[_0x537fc4('0xf28')](_0x537fc4('0x1578'))[_0x537fc4('0x26e3')](_0x537fc4('0xed5')+_0xd30a4a[_0x537fc4('0x13dd')][_0x537fc4('0x1564')]+_0x537fc4('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x537fc4('0x3c6'))[_0x537fc4('0xe42')](_0xe7471c)['ok']('OK')[_0x537fc4('0x19fb')]('CANCEL');_0x14cd31[_0x537fc4('0x1d4')](_0x4549f7)[_0x537fc4('0x683')](function(){const _0x2f5cb8=_0x537fc4;_0xd30a4a[_0x2f5cb8('0x13dd')]['forEach'](function(_0x560fcc){_0x343dd9(_0x560fcc);}),_0xd30a4a[_0x2f5cb8('0x13dd')]=[];});}function _0x1af8dd(){const _0x2d72d7=_0x4fbfb3;_0xd30a4a[_0x2d72d7('0x13dd')]=[];}function _0x3dd182(){const _0x38f5cb=_0x4fbfb3;_0xd30a4a[_0x38f5cb('0x13dd')]=_0xd30a4a['odbcs'][_0x38f5cb('0xf5d')];}}const _0x14efd8=_0x577f75;_0x2d9ce2[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$q','$translate',_0x189033('0x1d70'),_0x189033('0x1517'),_0x189033('0x823'),'api',_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x2d9ce2(_0x2c6ab5,_0x2a8e07,_0x42b814,_0x244272,_0x542705,_0x32f72c,_0x23e5af,_0x14cbf6,_0x5cc8a6,_0x263c95,_0x140ce9,_0x10d171,_0x2cf7bb,_0x56e717){const _0x3590fe=_0x189033,_0x160b5d=this;_0x160b5d[_0x3590fe('0x11ed')]=_0x140ce9[_0x3590fe('0x20b2')](),_0x160b5d[_0x3590fe('0x17f')]=[],_0x160b5d['setting']=_0x2cf7bb,_0x160b5d[_0x3590fe('0xace')]=_0x10d171,_0x160b5d['crudPermissions']=_0x56e717,_0x160b5d[_0x3590fe('0x258d')]={},_0x160b5d[_0x3590fe('0x19b2')]=_0x160b5d[_0x3590fe('0x260a')]&&_0x160b5d[_0x3590fe('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x160b5d[_0x3590fe('0xf28')]=_0x3590fe('0x4be'),_0x160b5d[_0x3590fe('0x823')]=angular['copy'](_0x5cc8a6),_0x160b5d[_0x3590fe('0x1517')]=_0x14cbf6,_0x160b5d[_0x3590fe('0x1416')]=![];!_0x160b5d[_0x3590fe('0x823')]&&(_0x160b5d['squareRecording']={},_0x160b5d[_0x3590fe('0xf28')]='CALLYSQUARE.NEW_SQUARERECORDING',_0x160b5d[_0x3590fe('0x1416')]=!![]);_0x160b5d[_0x3590fe('0x2729')]=_0x3639c6,_0x160b5d[_0x3590fe('0x56')]=_0x45502e,_0x160b5d[_0x3590fe('0x1d5f')]=_0x4ebc9e,_0x160b5d[_0x3590fe('0x16b3')]=_0x5c6c42,_0x160b5d[_0x3590fe('0xf82')]=_0x57f6a9;function _0x3639c6(){const _0x111f36=_0x3590fe;_0x160b5d['errors']=[],_0x263c95['squareRecording']['save'](_0x160b5d[_0x111f36('0x823')])['$promise'][_0x111f36('0x683')](function(_0x3f9dc3){const _0x377146=_0x111f36;_0x160b5d[_0x377146('0x1517')][_0x377146('0x1167')](_0x3f9dc3[_0x377146('0x24e1')]()),_0x23e5af[_0x377146('0x53')]({'title':_0x377146('0x1c2b'),'msg':_0x160b5d[_0x377146('0x823')][_0x377146('0x60a')]?_0x160b5d[_0x377146('0x823')][_0x377146('0x60a')]+'\x20has\x20been\x20created!':''}),_0x57f6a9(_0x3f9dc3);})[_0x111f36('0x130a')](function(_0x1b0339){const _0x24ca73=_0x111f36;if(_0x1b0339[_0x24ca73('0x5a5')]&&_0x1b0339[_0x24ca73('0x5a5')]['errors']&&_0x1b0339[_0x24ca73('0x5a5')]['errors'][_0x24ca73('0x1564')]){_0x160b5d[_0x24ca73('0x17f')]=_0x1b0339['data'][_0x24ca73('0x17f')]||[{'message':_0x1b0339['toString'](),'type':_0x24ca73('0x1d28')}];for(let _0x486fa9=0x0;_0x486fa9<_0x1b0339[_0x24ca73('0x5a5')]['errors'][_0x24ca73('0x1564')];_0x486fa9+=0x1){_0x23e5af[_0x24ca73('0x52a')]({'title':_0x1b0339[_0x24ca73('0x5a5')][_0x24ca73('0x17f')][_0x486fa9]['type'],'msg':_0x1b0339['data'][_0x24ca73('0x17f')][_0x486fa9][_0x24ca73('0x8c2')]});}}else _0x23e5af[_0x24ca73('0x52a')]({'title':_0x1b0339['status']?_0x24ca73('0x2168')+_0x1b0339['status']+_0x24ca73('0xbf6')+_0x1b0339[_0x24ca73('0x24a9')]:'api.squareRecording.save','msg':_0x1b0339[_0x24ca73('0x5a5')]?JSON[_0x24ca73('0x258a')](_0x1b0339[_0x24ca73('0x5a5')]['message']):_0x1b0339[_0x24ca73('0x1ff0')]()});});}function _0x45502e(){const _0x5aa40d=_0x3590fe;_0x160b5d[_0x5aa40d('0x17f')]=[],_0x263c95[_0x5aa40d('0x823')][_0x5aa40d('0x2480')]({'id':_0x160b5d[_0x5aa40d('0x823')]['id']},_0x160b5d[_0x5aa40d('0x823')])[_0x5aa40d('0xe53')][_0x5aa40d('0x683')](function(_0x522d71){const _0x11718b=_0x5aa40d,_0x5800cd=_0x2e3ca0()[_0x11718b('0x1c07')](_0x160b5d[_0x11718b('0x1517')],{'id':_0x522d71['id']});_0x5800cd&&_0x2e3ca0()[_0x11718b('0xf22')](_0x5800cd,_0x2e3ca0()['pick'](_0x522d71['toJSON'](),_0x2e3ca0()[_0x11718b('0x55e')](_0x5800cd))),_0x23e5af['success']({'title':_0x11718b('0xe3e'),'msg':_0x160b5d[_0x11718b('0x823')]['name']?_0x160b5d[_0x11718b('0x823')][_0x11718b('0x60a')]+_0x11718b('0xf59'):''}),_0x57f6a9(_0x522d71);})['catch'](function(_0xe2bd40){const _0x43bb45=_0x5aa40d;if(_0xe2bd40[_0x43bb45('0x5a5')]&&_0xe2bd40[_0x43bb45('0x5a5')]['errors']&&_0xe2bd40['data'][_0x43bb45('0x17f')][_0x43bb45('0x1564')]){_0x160b5d[_0x43bb45('0x17f')]=_0xe2bd40[_0x43bb45('0x5a5')]['errors']||[{'message':_0xe2bd40[_0x43bb45('0x1ff0')](),'type':'api.squareRecording.update'}];for(let _0x2866a2=0x0;_0x2866a2<_0xe2bd40['data'][_0x43bb45('0x17f')]['length'];_0x2866a2++){_0x23e5af[_0x43bb45('0x52a')]({'title':_0xe2bd40[_0x43bb45('0x5a5')][_0x43bb45('0x17f')][_0x2866a2][_0x43bb45('0xcf0')],'msg':_0xe2bd40[_0x43bb45('0x5a5')][_0x43bb45('0x17f')][_0x2866a2]['message']});}}else _0x23e5af['error']({'title':_0xe2bd40[_0x43bb45('0x13ee')]?'API:'+_0xe2bd40[_0x43bb45('0x13ee')]+_0x43bb45('0xbf6')+_0xe2bd40[_0x43bb45('0x24a9')]:_0x43bb45('0x128b'),'msg':_0xe2bd40[_0x43bb45('0x5a5')]?JSON[_0x43bb45('0x258a')](_0xe2bd40['data']['message']):_0xe2bd40[_0x43bb45('0x1ff0')]()});});}function _0x4ebc9e(_0xda1610){const _0x1b05a0=_0x3590fe;_0x160b5d['errors']=[];const _0x59dbd1=_0x244272[_0x1b05a0('0x1c6f')]()['title'](_0x1b05a0('0x4d'))['content'](_0x1b05a0('0x20cf'))[_0x1b05a0('0x1040')](_0x1b05a0('0x592'))['ok'](_0x1b05a0('0x2307'))[_0x1b05a0('0x19fb')](_0x1b05a0('0x253a'))['targetEvent'](_0xda1610);_0x244272[_0x1b05a0('0x1d4')](_0x59dbd1)[_0x1b05a0('0x683')](function(){const _0xbd475e=_0x1b05a0;_0x263c95[_0xbd475e('0x823')]['delete']({'id':_0x160b5d['squareRecording']['id']})[_0xbd475e('0xe53')][_0xbd475e('0x683')](function(){const _0x8daee=_0xbd475e;_0x2e3ca0()[_0x8daee('0x3ec')](_0x160b5d[_0x8daee('0x1517')],{'id':_0x160b5d[_0x8daee('0x823')]['id']}),_0x23e5af['success']({'title':_0x8daee('0x12d2'),'msg':(_0x160b5d[_0x8daee('0x823')][_0x8daee('0x60a')]||_0x8daee('0x823'))+'\x20has\x20been\x20deleted!'}),_0x57f6a9(_0x160b5d[_0x8daee('0x823')]);})['catch'](function(_0x49993b){const _0x23b207=_0xbd475e;if(_0x49993b[_0x23b207('0x5a5')]&&_0x49993b[_0x23b207('0x5a5')][_0x23b207('0x17f')]&&_0x49993b[_0x23b207('0x5a5')][_0x23b207('0x17f')][_0x23b207('0x1564')]){_0x160b5d[_0x23b207('0x17f')]=_0x49993b['data'][_0x23b207('0x17f')]||[{'message':_0x49993b[_0x23b207('0x1ff0')](),'type':_0x23b207('0x2210')}];for(let _0x25e709=0x0;_0x25e709<_0x49993b[_0x23b207('0x5a5')][_0x23b207('0x17f')]['length'];_0x25e709++){_0x23e5af['error']({'title':_0x49993b['data'][_0x23b207('0x17f')][_0x25e709]['type'],'msg':_0x49993b['data'][_0x23b207('0x17f')][_0x25e709]['message']});}}else _0x23e5af['error']({'title':_0x49993b[_0x23b207('0x13ee')]?_0x23b207('0x2168')+_0x49993b[_0x23b207('0x13ee')]+_0x23b207('0xbf6')+_0x49993b[_0x23b207('0x24a9')]:_0x23b207('0x2210'),'msg':_0x49993b[_0x23b207('0x5a5')]?JSON[_0x23b207('0x258a')](_0x49993b[_0x23b207('0x5a5')][_0x23b207('0x8c2')]):_0x49993b[_0x23b207('0x8c2')]||_0x49993b['toString']()});});},function(){});}function _0x5c6c42(_0x12aba4){return _0x12aba4===null?undefined:new Date(_0x12aba4);}function _0x57f6a9(_0x2d8304){const _0xdfa2ec=_0x3590fe;_0x244272[_0xdfa2ec('0x1715')](_0x2d8304);}}const _0x5b76f5=_0x2d9ce2,_0x2b713e=_0x180212['p']+_0x189033('0xbb6');_0x4096ab[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x1517'),_0x189033('0x2a'),_0x189033('0x22df'),'api','msUtils',_0x189033('0x1d70'),'Auth','license',_0x189033('0x260a')];function _0x4096ab(_0x1583db,_0x2a5f6a,_0x205962,_0x186c1c,_0x49729d,_0x43cbf5,_0x34ae63,_0x3eae77,_0x2edb15,_0x54b3fa,_0x4c4067,_0x5d3e34,_0xc3a3bd,_0x4287de,_0x520d03,_0x3085c3,_0x344162){const _0x553337=_0x189033,_0x1d0926=this;_0x1d0926[_0x553337('0xace')]=_0x3085c3,_0x1d0926[_0x553337('0x260a')]=_0x344162,_0x1d0926[_0x553337('0x11ed')]=_0x520d03['getCurrentUser'](),_0x1d0926[_0x553337('0x1517')]=_0x2edb15||{'count':0x0,'rows':[]},_0x1d0926[_0x553337('0x2a')]=_0x54b3fa,_0x1d0926[_0x553337('0x22df')]=_0x4c4067&&_0x4c4067[_0x553337('0x50d')]==0x1?_0x4c4067['rows'][0x0]:null,_0x1d0926[_0x553337('0x1134')]=_0x520d03[_0x553337('0x142a')](_0x1d0926[_0x553337('0x22df')]?_0x1d0926['userProfileSection'][_0x553337('0x1134')]:null),_0x1d0926[_0x553337('0x5c4')]='squareRecordings',_0x1d0926[_0x553337('0x247')]='',_0x1d0926[_0x553337('0x1ce2')]=null,_0x1d0926[_0x553337('0x1ac1')]=[],_0x1d0926['query']={'fields':_0x553337('0x184a'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x1d0926[_0x553337('0x29d')]=_0x1a332a,_0x1d0926[_0x553337('0x194f')]=_0x14aecb,_0x1d0926[_0x553337('0x53')]=_0x31e967,_0x1d0926[_0x553337('0xf8')]=_0x2f8e3d,_0x1d0926[_0x553337('0x90f')]=_0x560aa7,_0x1d0926[_0x553337('0x1d5f')]=_0x5599cf,_0x1d0926[_0x553337('0x1ca2')]=_0x14b9f9,_0x1d0926['deleteSelectedSquareRecordings']=_0x245b7e,_0x1d0926['deselectSquareRecordings']=_0xaad3b1,_0x1d0926['selectAllSquareRecordings']=_0x2caf0b;function _0x1a332a(_0x4c1090){const _0x3d9225=_0x553337;return _0x5d3e34[_0x3d9225('0x823')][_0x3d9225('0x18e8')]({'id':_0x4c1090['id']})[_0x3d9225('0xe53')][_0x3d9225('0x683')](function(_0x22a2b7){const _0x47d6c4=_0x3d9225,_0x434ce0=[_0x22a2b7[_0x47d6c4('0x1fb3')]];let _0x29709c=_0x47d6c4('0x18e8');const _0x279b99=new Blob(_0x434ce0,{'type':_0x22a2b7[_0x47d6c4('0xcf0')]});_0x29709c=_0x4c1090['uniqueid']+_0x4c1090[_0x47d6c4('0x26dd')];const _0x5bb44c=window[_0x47d6c4('0x12e1')][_0x47d6c4('0x1ffa')]('a');_0x5bb44c['setAttribute']('href',URL[_0x47d6c4('0x2820')](_0x279b99)),_0x5bb44c[_0x47d6c4('0x130f')](_0x47d6c4('0x18e8'),_0x29709c),document[_0x47d6c4('0x18e5')][_0x47d6c4('0x1e43')](_0x5bb44c),_0x5bb44c[_0x47d6c4('0x1d42')]();})[_0x3d9225('0x130a')](function(_0x305675){const _0x3b314e=_0x3d9225;if(_0x305675[_0x3b314e('0x5a5')]&&_0x305675[_0x3b314e('0x5a5')][_0x3b314e('0x17f')]&&_0x305675[_0x3b314e('0x5a5')]['errors'][_0x3b314e('0x1564')])for(let _0x4f7c55=0x0;_0x4f7c55<_0x305675[_0x3b314e('0x5a5')][_0x3b314e('0x17f')][_0x3b314e('0x1564')];_0x4f7c55++){_0x4287de['error']({'title':_0x305675['data']['errors'][_0x4f7c55][_0x3b314e('0xcf0')],'msg':_0x305675[_0x3b314e('0x5a5')]['errors'][_0x4f7c55][_0x3b314e('0x8c2')]});}else _0x4287de[_0x3b314e('0x52a')]({'title':_0x305675[_0x3b314e('0x13ee')]?_0x3b314e('0x2168')+_0x305675[_0x3b314e('0x13ee')]+'\x20-\x20'+_0x305675[_0x3b314e('0x24a9')]:_0x3b314e('0x1d28'),'msg':_0x305675[_0x3b314e('0x5a5')]?JSON[_0x3b314e('0x258a')](_0x305675[_0x3b314e('0x5a5')]['message']):_0x305675[_0x3b314e('0x1ff0')]()});});}function _0x14aecb(_0x420c92,_0x3faac8){const _0x2b9da1=_0x553337,_0x904763=_0x49729d['confirm']()[_0x2b9da1('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x2b9da1('0x1e03')](_0x2b9da1('0x823'))+'?')[_0x2b9da1('0x26e3')](''+(_0x420c92[_0x2b9da1('0x60a')]||_0x2b9da1('0x823'))+_0x2b9da1('0x20f1')+_0x2b9da1('0x1ee7'))[_0x2b9da1('0x1040')](_0x2b9da1('0x539'))[_0x2b9da1('0xe42')](_0x3faac8)['ok']('OK')[_0x2b9da1('0x19fb')](_0x2b9da1('0x16b8'));_0x49729d['show'](_0x904763)[_0x2b9da1('0x683')](function(){_0x5599cf(_0x420c92);},function(){const _0x184319=_0x2b9da1;console[_0x184319('0x1b2b')](_0x184319('0x16b8'));});}let _0x5de2aa=!![],_0x27a9d4=0x1;_0x1583db[_0x553337('0x186d')]('vm.query.filter',function(_0x3b0aed,_0x52c56b){const _0x407e4f=_0x553337;_0x5de2aa?_0x34ae63(function(){_0x5de2aa=![];}):(!_0x52c56b&&(_0x27a9d4=_0x1d0926[_0x407e4f('0x23a2')]['page']),_0x3b0aed!==_0x52c56b&&(_0x1d0926[_0x407e4f('0x23a2')]['page']=0x1),!_0x3b0aed&&(_0x1d0926[_0x407e4f('0x23a2')][_0x407e4f('0xdf8')]=_0x27a9d4),_0x1d0926[_0x407e4f('0xf8')]());});function _0x31e967(_0xb991f7){const _0x1f0a06=_0x553337;_0x1d0926[_0x1f0a06('0x1517')]=_0xb991f7||{'count':0x0,'rows':[]};}function _0x2f8e3d(){const _0x1d8d91=_0x553337;_0x1d0926[_0x1d8d91('0x23a2')][_0x1d8d91('0x1cc8')]=(_0x1d0926['query'][_0x1d8d91('0xdf8')]-0x1)*_0x1d0926[_0x1d8d91('0x23a2')][_0x1d8d91('0x6f0')],_0x520d03[_0x1d8d91('0xca1')](_0x1d8d91('0x20c2'))?_0x1d0926[_0x1d8d91('0x1883')]=_0x5d3e34[_0x1d8d91('0x823')][_0x1d8d91('0x1e6e')](_0x1d0926[_0x1d8d91('0x23a2')],_0x31e967)[_0x1d8d91('0xe53')]:(_0x1d0926[_0x1d8d91('0x23a2')]['id']=_0x1d0926[_0x1d8d91('0x2a')]['id'],_0x1d0926[_0x1d8d91('0x23a2')][_0x1d8d91('0x1aa')]=_0x1d8d91('0x1dcb'),_0x1d0926['promise']=_0x5d3e34['userProfile'][_0x1d8d91('0x241d')](_0x1d0926[_0x1d8d91('0x23a2')],_0x31e967)[_0x1d8d91('0xe53')]);}function _0x560aa7(_0x2b522c,_0x5e602e){const _0x104346=_0x553337;_0x49729d['show']({'controller':_0x104346('0xfe1'),'controllerAs':'vm','templateUrl':_0x2b713e,'parent':angular[_0x104346('0x1fcc')](_0x43cbf5[_0x104346('0x18e5')]),'targetEvent':_0x2b522c,'clickOutsideToClose':!![],'locals':{'squareRecording':_0x5e602e,'squareRecordings':_0x1d0926['squareRecordings'][_0x104346('0xf5d')],'license':_0x1d0926['license'],'setting':_0x1d0926[_0x104346('0x260a')],'crudPermissions':_0x1d0926['crudPermissions']}});}function _0x5599cf(_0x474b8e){const _0x253d36=_0x553337;_0x5d3e34[_0x253d36('0x823')][_0x253d36('0xd7e')]({'id':_0x474b8e['id']})[_0x253d36('0xe53')][_0x253d36('0x683')](function(){const _0x47c3ff=_0x253d36;_0x2e3ca0()[_0x47c3ff('0x3ec')](_0x1d0926[_0x47c3ff('0x1517')]['rows'],{'id':_0x474b8e['id']}),_0x1d0926['squareRecordings']['count']-=0x1,!_0x1d0926['squareRecordings'][_0x47c3ff('0xf5d')][_0x47c3ff('0x1564')]&&_0x1d0926['getSquareRecordings'](),_0x4287de[_0x47c3ff('0x53')]({'title':_0x2e3ca0()['startCase'](_0x47c3ff('0x1162'))+_0x47c3ff('0xbfc'),'msg':_0x474b8e[_0x47c3ff('0x60a')]?_0x474b8e[_0x47c3ff('0x60a')]+_0x47c3ff('0x194d'):''});})['catch'](function(_0x3420a1){const _0x848be9=_0x253d36;if(_0x3420a1['data']&&_0x3420a1[_0x848be9('0x5a5')]['errors']&&_0x3420a1[_0x848be9('0x5a5')]['errors'][_0x848be9('0x1564')]){_0x1d0926[_0x848be9('0x17f')]=_0x3420a1['data'][_0x848be9('0x17f')]||[{'message':_0x3420a1[_0x848be9('0x1ff0')](),'type':_0x848be9('0x21ac')}];for(let _0x537ca6=0x0;_0x537ca6<_0x3420a1[_0x848be9('0x5a5')]['errors'][_0x848be9('0x1564')];_0x537ca6++){_0x4287de[_0x848be9('0x52a')]({'title':_0x3420a1['data']['errors'][_0x537ca6]['type'],'msg':_0x3420a1[_0x848be9('0x5a5')]['errors'][_0x537ca6]['message']});}}else _0x4287de[_0x848be9('0x52a')]({'title':_0x3420a1[_0x848be9('0x13ee')]?_0x848be9('0x2168')+_0x3420a1[_0x848be9('0x13ee')]+_0x848be9('0xbf6')+_0x3420a1['statusText']:_0x848be9('0x21ac'),'msg':_0x3420a1[_0x848be9('0x5a5')]?JSON['stringify'](_0x3420a1['data']['message']):_0x3420a1['message']||_0x3420a1[_0x848be9('0x1ff0')]()});});}function _0x14b9f9(){const _0x27c85e=_0x553337,_0x4c97aa=angular[_0x27c85e('0x1a86')](_0x1d0926[_0x27c85e('0x1ac1')]);return _0x1d0926[_0x27c85e('0x1ac1')]=[],_0x4c97aa;}function _0x245b7e(_0x33f62b){const _0x9f12e4=_0x553337,_0x15a8df=_0x49729d['confirm']()[_0x9f12e4('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20squareRecordings?')[_0x9f12e4('0x26e3')](_0x9f12e4('0xed5')+_0x1d0926[_0x9f12e4('0x1ac1')][_0x9f12e4('0x1564')]+_0x9f12e4('0x93c')+_0x9f12e4('0x1ee7'))['ariaLabel'](_0x9f12e4('0xc65'))[_0x9f12e4('0xe42')](_0x33f62b)['ok']('OK')[_0x9f12e4('0x19fb')](_0x9f12e4('0x16b8'));_0x49729d[_0x9f12e4('0x1d4')](_0x15a8df)[_0x9f12e4('0x683')](function(){const _0x1e7240=_0x9f12e4;_0x1d0926[_0x1e7240('0x1ac1')][_0x1e7240('0x1299')](function(_0x20a1cc){_0x5599cf(_0x20a1cc);}),_0x1d0926[_0x1e7240('0x1ac1')]=[];});}function _0xaad3b1(){const _0x4aee7d=_0x553337;_0x1d0926[_0x4aee7d('0x1ac1')]=[];}function _0x2caf0b(){const _0x1c5ff6=_0x553337;_0x1d0926[_0x1c5ff6('0x1ac1')]=_0x1d0926[_0x1c5ff6('0x1517')][_0x1c5ff6('0xf5d')];}}const _0x34fc95=_0x4096ab;_0x50946a[_0x189033('0x14be')]=['$stateProvider','$translatePartialLoaderProvider'];function _0x50946a(_0x38eeb3,_0x50fa52){const _0x36b9dd=_0x189033;_0x38eeb3['state'](_0x36b9dd('0x12d8'),{'abstract':!![],'url':_0x36b9dd('0xf87')})['state'](_0x36b9dd('0x399'),{'url':_0x36b9dd('0x65e'),'views':{'content@app':{'templateUrl':_0x177665,'controller':_0x36b9dd('0x1016')}},'resolve':{'odbcs':[_0x36b9dd('0x4b1'),_0x36b9dd('0xba1'),function(_0x4ba632,_0xda8be0){const _0x42ee59=_0x36b9dd;return _0xda8be0[_0x42ee59('0xca1')]('admin')?_0x4ba632[_0x42ee59('0xed7')](_0x42ee59('0x2d7'),{'fields':'createdAt,updatedAt,id,name,dsn,description','sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x4ba632[_0x42ee59('0xed7')](_0x42ee59('0x191b'),{'id':_0xda8be0[_0x42ee59('0x20b2')]()[_0x42ee59('0x2f')],'section':_0x42ee59('0x26fe'),'fields':_0x42ee59('0xd6e'),'sort':_0x42ee59('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x36b9dd('0x4b1'),_0x36b9dd('0xba1'),function(_0x155902,_0x3cae26){const _0x503d00=_0x36b9dd;return _0x3cae26['hasRole'](_0x503d00('0x20c2'))?null:_0x155902[_0x503d00('0xed7')](_0x503d00('0x1464'),{'fields':_0x503d00('0x16f'),'id':_0x3cae26[_0x503d00('0x20b2')]()[_0x503d00('0x2f')]});}],'userProfileSection':[_0x36b9dd('0x4b1'),_0x36b9dd('0xba1'),function(_0x135968,_0x5da133){const _0x337c3c=_0x36b9dd;return _0x5da133[_0x337c3c('0xca1')](_0x337c3c('0x20c2'))?null:_0x135968['resolve']('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5da133[_0x337c3c('0x20b2')]()[_0x337c3c('0x2f')],'sectionId':0x44d});}]},'authenticate':!![],'permissionId':0x44d,'bodyClass':_0x36b9dd('0x1c5e')})[_0x36b9dd('0x2598')](_0x36b9dd('0x1bb8'),{'url':'/squareRecordings','views':{'content@app':{'templateUrl':_0x267cd4,'controller':'SquareRecordingsController\x20as\x20vm'}},'resolve':{'squareRecordings':[_0x36b9dd('0x4b1'),_0x36b9dd('0xba1'),function(_0x12f3f7,_0x1d7f9f){const _0x4c0ddf=_0x36b9dd;return _0x1d7f9f[_0x4c0ddf('0xca1')](_0x4c0ddf('0x20c2'))?_0x12f3f7['resolve'](_0x4c0ddf('0x1a82'),{'fields':_0x4c0ddf('0x184a'),'sort':_0x4c0ddf('0xc36'),'limit':0xa,'offset':0x0}):_0x12f3f7[_0x4c0ddf('0xed7')](_0x4c0ddf('0x191b'),{'id':_0x1d7f9f['getCurrentUser']()[_0x4c0ddf('0x2f')],'section':_0x4c0ddf('0x1dcb'),'fields':_0x4c0ddf('0x184a'),'sort':_0x4c0ddf('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x36b9dd('0x4b1'),_0x36b9dd('0xba1'),function(_0x1b665a,_0x58bd5a){const _0xd447f5=_0x36b9dd;return _0x58bd5a['hasRole'](_0xd447f5('0x20c2'))?null:_0x1b665a[_0xd447f5('0xed7')](_0xd447f5('0x1464'),{'fields':_0xd447f5('0x16f'),'id':_0x58bd5a[_0xd447f5('0x20b2')]()[_0xd447f5('0x2f')]});}],'userProfileSection':[_0x36b9dd('0x4b1'),_0x36b9dd('0xba1'),function(_0x4bbd9b,_0x1b0642){const _0x555a3a=_0x36b9dd;return _0x1b0642['hasRole'](_0x555a3a('0x20c2'))?null:_0x4bbd9b['resolve'](_0x555a3a('0x360'),{'fields':_0x555a3a('0x1f47'),'userProfileId':_0x1b0642['getCurrentUser']()[_0x555a3a('0x2f')],'sectionId':0x44e});}]},'authenticate':!![],'permissionId':0x44e,'bodyClass':_0x36b9dd('0x1c5e')}),_0x50fa52[_0x36b9dd('0x7d2')](_0x36b9dd('0x1fba'));}angular[_0x189033('0x1e26')]('app.callysquare',[_0x189033('0x6cf'),'ngPassword',_0x189033('0x2290'),_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),_0x189033('0x2609'),_0x189033('0x273d'),_0x189033('0x76'),_0x189033('0x516'),_0x189033('0x7fa'),_0x189033('0x197b'),_0x189033('0x3b5'),_0x189033('0x153a'),_0x189033('0x1447'),_0x189033('0x2645'),_0x189033('0x20c7'),'chart.js',_0x189033('0x19da'),_0x189033('0x24ed')])[_0x189033('0x272d')](_0x50946a)['controller'](_0x189033('0xce4'),_0x2b664e)[_0x189033('0x1da3')](_0x189033('0x6f8'),_0x14efd8)[_0x189033('0x1da3')]('CreateOrEditSquareRecordingDialogController',_0x5b76f5)['controller']('SquareRecordingsController',_0x34fc95);const _0x2caf41=_0x180212['p']+_0x189033('0x1d9e'),_0x55c930=_0x180212['p']+_0x189033('0xc93'),_0x159ee8=_0x180212['p']+_0x189033('0x2265'),_0x54574f=_0x180212['p']+'src/js/modules/main/apps/analytics/views/reports/edit/view.html/view.html';var _0x457984=_0x180212(0xd5a);_0x53ea0f['$inject']=['$location',_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0xaaf'),'api',_0x189033('0x213'),_0x189033('0x189c')];function _0x53ea0f(_0xee78bf,_0x4ba629,_0x16a79e,_0x2f5100,_0x36b73f,_0x12d0c5,_0x2e3e72){const _0x2ec856=_0x189033,_0x752b8a=this;_0x752b8a['errors']=[],_0x752b8a[_0x2ec856('0xaaf')]=angular[_0x2ec856('0x1a86')](_0x2f5100),_0x752b8a['report'][_0x2ec856('0x60a')]+=_0x2ec856('0xeed'),_0x752b8a[_0x2ec856('0x189c')]=_0x2e3e72,_0x752b8a[_0x2ec856('0x2262')]={'core':{'multiple':![],'animation':!![],'error':function(_0x39115e){const _0x96522a=_0x2ec856;console[_0x96522a('0x52a')](_0x96522a('0x2167')+angular[_0x96522a('0x1bf7')](_0x39115e));},'check_callback':!![],'worker':!![]},'version':0x1,'plugins':[_0x2ec856('0x12a7')]},_0x752b8a[_0x2ec856('0x26b7')]={'select_node':_0x1a1007},_0x752b8a[_0x2ec856('0x257a')]=_0x591a6e,_0x752b8a[_0x2ec856('0xf82')]=_0x29f1a8;function _0x591a6e(){const _0x273954=_0x2ec856;_0x752b8a[_0x273954('0x17f')]=[];let _0xbeac5a;_0x36b73f[_0x273954('0x197f')]['save']({'name':_0x752b8a[_0x273954('0xaaf')][_0x273954('0x60a')],'description':_0x752b8a['report']['description'],'table':_0x752b8a[_0x273954('0xaaf')][_0x273954('0x5c4')],'conditions':_0x752b8a['report'][_0x273954('0x27a5')],'joins':_0x752b8a['report'][_0x273954('0x21b0')],'parent':_0x752b8a['currentNode']['id']})[_0x273954('0xe53')][_0x273954('0x683')](function(_0x354d1f){const _0x4ea90e=_0x273954;_0xbeac5a=_0x354d1f,_0x16a79e[_0x4ea90e('0x53')]({'title':_0x4ea90e('0x2078'),'msg':_0x752b8a[_0x4ea90e('0xaaf')][_0x4ea90e('0x60a')]?_0x752b8a[_0x4ea90e('0xaaf')][_0x4ea90e('0x60a')]+_0x4ea90e('0xc16'):''});const _0x183d9c={'fields':'field,alias,function,format,groupBy,orderBy,custom,MetricId','nolimit':!![]};return _0x183d9c[_0x12d0c5==='analyticCustomReport'?_0x4ea90e('0x1b81'):_0x4ea90e('0x24a1')]=_0x752b8a[_0x4ea90e('0xaaf')]['id'],_0x36b73f['analyticFieldReport'][_0x4ea90e('0x1e6e')](_0x183d9c)['$promise'];})[_0x273954('0x683')](function(_0x4a5417){const _0x1fcd1e=_0x273954,_0x52ead4=_0x2e3ca0()[_0x1fcd1e('0x386')](_0x4a5417[_0x1fcd1e('0xf5d')],function(_0x45a9e4){const _0x390f09=_0x1fcd1e;return _0x2e3ca0()[_0x390f09('0x618')]({},_0x45a9e4,{'CustomReportId':_0xbeac5a['id']});});return _0x36b73f[_0x1fcd1e('0x2871')]['bulkCreate'](_0x52ead4)[_0x1fcd1e('0xe53')];})[_0x273954('0x683')](function(){const _0x5b3e8a=_0x273954;_0x16a79e['success']({'title':'Fields\x20copied!','msg':_0x5b3e8a('0xa15')}),_0x29f1a8();})[_0x273954('0x130a')](function(_0x2f7569){const _0x50de1e=_0x273954;_0x16a79e[_0x50de1e('0x52a')]({'title':_0x2f7569[_0x50de1e('0x13ee')]?'API:'+_0x2f7569[_0x50de1e('0x13ee')]+_0x50de1e('0xbf6')+_0x2f7569['statusText']:_0x50de1e('0x3d1'),'msg':_0x2f7569[_0x50de1e('0x5a5')]?JSON[_0x50de1e('0x258a')](_0x2f7569[_0x50de1e('0x5a5')]['message']):_0x2f7569['toString']()});});}function _0x1a1007(_0x169352,_0x20ff78){const _0x292eed=_0x2ec856;_0x752b8a[_0x292eed('0x121b')]=_0x20ff78['node'];}function _0x29f1a8(){const _0x1ede19=_0x2ec856;_0x4ba629[_0x1ede19('0x1715')]();}}const _0x529dbc=_0x53ea0f;_0x424364[_0x189033('0x14be')]=[_0x189033('0xb8d'),_0x189033('0x1e48'),'toasty',_0x189033('0x4c2'),_0x189033('0xaaf'),_0x189033('0x56b'),_0x189033('0x213'),_0x189033('0x121b'),'describeTable','crudPermissions'];function _0x424364(_0xa7c407,_0x42c409,_0x2c64df,_0x2e8a8f,_0x4ff1b6,_0x5d801f,_0x45d985,_0xf583c9,_0x589594,_0x2a925e){const _0x1568a6=_0x189033,_0x282097=this;_0x282097['errors']=[],_0x282097[_0x1568a6('0x1539')]=[],_0x282097['title']=_0x1568a6('0x198b'),_0x282097[_0x1568a6('0x1134')]=_0x2a925e,_0x282097[_0x1568a6('0xaaf')]=angular['copy'](_0x4ff1b6),_0x282097[_0x1568a6('0x4c2')]=_0x2e8a8f,_0x282097[_0x1568a6('0x922')]=![],_0x282097[_0x1568a6('0x24')]=_0x589594[_0x1568a6('0x1417')](),_0x282097[_0x1568a6('0x1c68')]=[{'key':_0x1568a6('0x1630'),'value':_0x1568a6('0x1009')},{'key':_0x1568a6('0x1bfe'),'value':_0x1568a6('0x6bb')},{'key':_0x1568a6('0x1b87'),'value':_0x1568a6('0x1a24')},{'key':_0x1568a6('0xb0d'),'value':'Cross\x20Join'}];!_0x282097[_0x1568a6('0xaaf')]&&(_0x282097[_0x1568a6('0xaaf')]={'name':'','table':_0x1568a6('0x254c'),'description':'','parent':_0xf583c9['id']},_0x282097[_0x1568a6('0xf28')]=_0x1568a6('0x21f5'),_0x282097['newReport']=!![]);_0x282097[_0x1568a6('0x2724')]=_0xc4a0d3,_0x282097[_0x1568a6('0x154c')]=_0x5a1119,_0x282097['deleteReport']=_0xad0a9d,_0x282097['closeDialog']=_0x23d7c0,_0x282097['selectedTableChange']=_0x354c28,_0x282097[_0x1568a6('0x1335')]=_0x4e6330,_0x282097[_0x1568a6('0x298')]=_0xc33139;function _0x4e6330(_0x3ea9a3){const _0x192ed7=_0x1568a6;_0x282097[_0x192ed7('0x1539')][_0x192ed7('0x2040')](_0x3ea9a3,0x1);}function _0xc33139(_0x1d5193,_0x4dcf15,_0xff2a7a){const _0xe24310=_0x1568a6,_0x3c158c=_0x2e3ca0()['find'](_0x282097[_0xe24310('0x24')],{'name':_0xff2a7a});_0x3c158c&&_0x3c158c[_0xe24310('0x56b')]&&_0x5d801f[_0x3c158c[_0xe24310('0x56b')]][_0xe24310('0x2267')]()[_0xe24310('0xe53')][_0xe24310('0x683')](function(_0x1569a0){const _0x25da1c=_0xe24310;_0x1d5193[_0x4dcf15]=_0x2e3ca0()[_0x25da1c('0x2829')](_0x2e3ca0()[_0x25da1c('0x55e')](_0x1569a0),['$promise',_0x25da1c('0x1980')]);})[_0xe24310('0x130a')](function(_0x5a1686){const _0x2c7d89=_0xe24310;console[_0x2c7d89('0x52a')](_0x5a1686);});}function _0x354c28(_0x3f92fb){const _0x5c420d=_0x1568a6;_0x3f92fb&&(delete _0x282097[_0x5c420d('0x2261')],_0x282097[_0x5c420d('0x1539')][_0x5c420d('0x1fd0')](_0x3f92fb));}function _0xc4a0d3(){const _0x153176=_0x1568a6;_0x282097[_0x153176('0x17f')]=[],_0x282097[_0x153176('0xaaf')]['joins']=_0x2e3ca0()[_0x153176('0x386')](_0x282097['joinTables']||[],function(_0xc40af){const _0x481348=_0x153176;return{'parentKey':_0xc40af['parentKey'],'foreignTable':_0xc40af[_0x481348('0x60a')],'foreignKey':_0xc40af[_0x481348('0x262c')],'type':_0xc40af[_0x481348('0xcf0')][_0x481348('0x93a')]()};}),_0x282097[_0x153176('0xaaf')][_0x153176('0x21b0')]=JSON[_0x153176('0x258a')](_0x282097[_0x153176('0xaaf')]['joins']),_0x5d801f[_0x45d985][_0x153176('0xb0a')](_0x282097[_0x153176('0xaaf')])[_0x153176('0xe53')][_0x153176('0x683')](function(_0x27bdc8){const _0x38ae8c=_0x153176;_0x282097[_0x38ae8c('0x4c2')][_0x38ae8c('0x1167')](_0x27bdc8),_0x2c64df[_0x38ae8c('0x53')]({'title':_0x38ae8c('0x14c0'),'msg':_0x282097[_0x38ae8c('0xaaf')]['name']?_0x282097[_0x38ae8c('0xaaf')][_0x38ae8c('0x60a')]+_0x38ae8c('0x14b5'):''}),_0x23d7c0();})['catch'](function(_0x33beca){const _0x4bca9b=_0x153176;if(_0x33beca['data']&&_0x33beca[_0x4bca9b('0x5a5')]['errors']&&_0x33beca['data'][_0x4bca9b('0x17f')][_0x4bca9b('0x1564')]){_0x282097[_0x4bca9b('0x17f')]=_0x33beca['data']['errors']||[{'message':_0x33beca[_0x4bca9b('0x1ff0')](),'type':_0x4bca9b('0x3b9')}];for(let _0x5992a1=0x0;_0x5992a1<_0x33beca[_0x4bca9b('0x5a5')][_0x4bca9b('0x17f')][_0x4bca9b('0x1564')];_0x5992a1++){_0x2c64df[_0x4bca9b('0x52a')]({'title':_0x33beca[_0x4bca9b('0x5a5')][_0x4bca9b('0x17f')][_0x5992a1][_0x4bca9b('0xcf0')],'msg':_0x33beca[_0x4bca9b('0x5a5')]['errors'][_0x5992a1][_0x4bca9b('0x8c2')]});}}else _0x2c64df[_0x4bca9b('0x52a')]({'title':_0x33beca[_0x4bca9b('0x13ee')]?'API:'+_0x33beca['status']+_0x4bca9b('0xbf6')+_0x33beca[_0x4bca9b('0x24a9')]:_0x4bca9b('0x3b9'),'msg':_0x33beca[_0x4bca9b('0x5a5')]?JSON[_0x4bca9b('0x258a')](_0x33beca[_0x4bca9b('0x5a5')][_0x4bca9b('0x8c2')]):_0x33beca[_0x4bca9b('0x1ff0')]()});});}function _0x5a1119(){const _0x51eabe=_0x1568a6;_0x282097[_0x51eabe('0x17f')]=[],_0x5d801f[_0x45d985][_0x51eabe('0x2480')]({'id':_0x282097[_0x51eabe('0xaaf')]['id']},_0x282097['report'])[_0x51eabe('0xe53')][_0x51eabe('0x683')](function(_0x1a625a){const _0x5a418d=_0x51eabe,_0x5c56b1=_0x2e3ca0()[_0x5a418d('0x1c07')](_0x282097[_0x5a418d('0x4c2')],{'id':_0x1a625a['id']});_0x5c56b1&&_0x2e3ca0()[_0x5a418d('0xf22')](_0x5c56b1,_0x1a625a),_0x2c64df[_0x5a418d('0x53')]({'title':_0x5a418d('0x2675'),'msg':_0x282097[_0x5a418d('0xaaf')][_0x5a418d('0x60a')]?_0x282097[_0x5a418d('0xaaf')][_0x5a418d('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x23d7c0();})[_0x51eabe('0x130a')](function(_0x35fbed){const _0x3ee239=_0x51eabe;if(_0x35fbed[_0x3ee239('0x5a5')]&&_0x35fbed[_0x3ee239('0x5a5')][_0x3ee239('0x17f')]&&_0x35fbed[_0x3ee239('0x5a5')][_0x3ee239('0x17f')][_0x3ee239('0x1564')]){_0x282097['errors']=_0x35fbed['data'][_0x3ee239('0x17f')]||[{'message':_0x35fbed[_0x3ee239('0x1ff0')](),'type':'api.analyticReport.update'}];for(let _0x496d57=0x0;_0x496d57<_0x35fbed['data'][_0x3ee239('0x17f')]['length'];_0x496d57++){_0x2c64df[_0x3ee239('0x52a')]({'title':_0x35fbed[_0x3ee239('0x5a5')][_0x3ee239('0x17f')][_0x496d57][_0x3ee239('0xcf0')],'msg':_0x35fbed[_0x3ee239('0x5a5')][_0x3ee239('0x17f')][_0x496d57][_0x3ee239('0x8c2')]});}}else _0x2c64df[_0x3ee239('0x52a')]({'title':_0x35fbed[_0x3ee239('0x13ee')]?_0x3ee239('0x2168')+_0x35fbed[_0x3ee239('0x13ee')]+_0x3ee239('0xbf6')+_0x35fbed['statusText']:'api.analyticReport.update','msg':_0x35fbed[_0x3ee239('0x5a5')]?JSON[_0x3ee239('0x258a')](_0x35fbed['data'][_0x3ee239('0x8c2')]):_0x35fbed[_0x3ee239('0x1ff0')]()});});}function _0xad0a9d(){const _0x519192=_0x1568a6;_0x282097['errors']=[];const _0x4b1e7d=_0x42c409[_0x519192('0x1c6f')]()['title']('Are\x20you\x20sure?')[_0x519192('0xa6a')](_0x519192('0x474'))[_0x519192('0x1040')](_0x519192('0x1863'))['ok']('Delete')[_0x519192('0x19fb')]('Cancel')[_0x519192('0xe42')](event);_0x42c409['show'](_0x4b1e7d)[_0x519192('0x683')](function(){const _0x192653=_0x519192;_0x5d801f[_0x45d985][_0x192653('0xd7e')]({'id':_0x282097['report']['id']})['$promise']['then'](function(){const _0x49b188=_0x192653;_0x2e3ca0()[_0x49b188('0x3ec')](_0x282097['reports'],{'id':_0x282097[_0x49b188('0xaaf')]['id']}),_0x2c64df[_0x49b188('0x53')]({'title':_0x49b188('0xeae'),'msg':_0x282097[_0x49b188('0xaaf')][_0x49b188('0x60a')]?_0x282097[_0x49b188('0xaaf')]['name']+_0x49b188('0x194d'):''}),_0x23d7c0();})['catch'](function(_0x1bd6b8){const _0x15cae5=_0x192653;_0x282097['errors']=_0x1bd6b8[_0x15cae5('0x5a5')][_0x15cae5('0x17f')]||[{'message':_0x1bd6b8[_0x15cae5('0x1ff0')](),'type':_0x15cae5('0xf9a')}];});},function(){});}function _0x23d7c0(){const _0x108527=_0x1568a6;_0x42c409[_0x108527('0x1715')]();}}const _0x132365=_0x424364;_0x46e2e3[_0x189033('0x14be')]=[_0x189033('0x1e48'),'describeTable','toasty','sqlUtil'];function _0x46e2e3(_0x1f2e11,_0xeb0647,_0x1207dc,_0x2f6ffc){const _0x570189=_0x189033,_0x2dddbd=this;_0x2dddbd[_0x570189('0xaaf')]={},_0x2dddbd['conditions']=_0x2f6ffc[_0x570189('0xda9')],_0x2dddbd['init']=_0x1c68c5,_0x2dddbd[_0x570189('0x2532')]=_0x752d43,_0x2dddbd[_0x570189('0x27fd')]=_0x3c4d9e,_0x2dddbd[_0x570189('0x26eb')]=_0x28b799,_0x2dddbd[_0x570189('0x2171')]=_0xab85d3;function _0x1c68c5(_0xed3ed5,_0x2f194e){const _0x218a27=_0x570189;_0x2dddbd[_0x218a27('0xaaf')]=_0xed3ed5,_0x2dddbd[_0x218a27('0xaaf')][_0x218a27('0x168e')]=angular[_0x218a27('0x1cb2')](_0xed3ed5[_0x218a27('0x27a5')])||{'group':{'operator':'AND','rules':[]}},_0x2dddbd[_0x218a27('0x1134')]=typeof _0x2f194e!==_0x218a27('0x1867')?_0x2f194e:{'readOnly':!![],'canEdit':![],'canDelete':![]};for(let _0x96810a=0x0;_0x96810a<_0x2dddbd[_0x218a27('0xaaf')][_0x218a27('0x168e')][_0x218a27('0x980')][_0x218a27('0x1619')]['length'];_0x96810a++){if(_0x2dddbd[_0x218a27('0xaaf')]['condition'][_0x218a27('0x980')]['rules'][_0x96810a][_0x218a27('0x2013')]){const _0x32a368=_0x2dddbd[_0x218a27('0xaaf')][_0x218a27('0x168e')]['group'][_0x218a27('0x1619')][_0x96810a]['field'][_0x218a27('0x1fc5')]('.');_0x32a368[_0x218a27('0x1564')]===0x1&&(_0x2dddbd['report'][_0x218a27('0x168e')][_0x218a27('0x980')][_0x218a27('0x1619')][_0x96810a][_0x218a27('0x2013')]=_0x2dddbd[_0x218a27('0xaaf')][_0x218a27('0x5c4')]+'.'+_0x2dddbd[_0x218a27('0xaaf')][_0x218a27('0x168e')][_0x218a27('0x980')][_0x218a27('0x1619')][_0x96810a][_0x218a27('0x2013')]);}}_0xeb0647[_0x218a27('0x24f5')](_0x2dddbd[_0x218a27('0xaaf')][_0x218a27('0x5c4')])[_0x218a27('0x683')](function(_0x3f33a9){const _0x375df8=_0x218a27;_0x2dddbd[_0x375df8('0x1a7f')]=_0x2e3ca0()[_0x375df8('0x2829')](_0x2e3ca0()['keys'](_0x3f33a9),['$promise',_0x375df8('0x1980'),_0x375df8('0x1a4'),'updatedAt']);})[_0x218a27('0x130a')](function(_0x370ccd){const _0x23ad16=_0x218a27;_0x1207dc['error']({'title':_0x370ccd[_0x23ad16('0x13ee')]?_0x23ad16('0x2168')+_0x370ccd[_0x23ad16('0x13ee')]+_0x23ad16('0xbf6')+_0x370ccd[_0x23ad16('0x24a9')]:_0x23ad16('0x16df'),'msg':_0x370ccd['data']?JSON[_0x23ad16('0x258a')](_0x370ccd[_0x23ad16('0x5a5')]):_0x370ccd[_0x23ad16('0x1ff0')]()});});}function _0x752d43(_0x109fc3){const _0x4eb787=_0x570189;_0x109fc3[_0x4eb787('0x1167')]({'condition':'=','field':'','value':''});}function _0x3c4d9e(_0x19f4d7){const _0x8bc672=_0x570189;_0x19f4d7['push']({'group':{'operator':_0x8bc672('0xe43'),'rules':[]}});}function _0x28b799(_0x5d15f2,_0x5d8139,_0x42670a){const _0x2b79b8=_0x570189,_0xb528d6=_0x1f2e11[_0x2b79b8('0x1c6f')]()[_0x2b79b8('0xf28')](_0x2b79b8('0x926'))[_0x2b79b8('0x26e3')]('The\x20item\x20will\x20be\x20deleted.')[_0x2b79b8('0x1040')](_0x2b79b8('0x1004'))[_0x2b79b8('0xe42')](_0x42670a)['ok']('OK')[_0x2b79b8('0x19fb')]('CANCEL');_0x1f2e11[_0x2b79b8('0x1d4')](_0xb528d6)[_0x2b79b8('0x683')](function(){_0x5d15f2['splice'](_0x5d8139,0x1);},function(){const _0x1fa833=_0x2b79b8;console['log'](_0x1fa833('0x16b8'));});}function _0xab85d3(_0x1fa7ed){const _0x45aaa7=_0x570189;return!_0x2e3ca0()['includes']([_0x45aaa7('0x834'),_0x45aaa7('0x25d5'),_0x45aaa7('0x19e9'),_0x45aaa7('0x42c')],_0x1fa7ed);}}const _0x2a8ffa=_0x46e2e3;_0x711b05[_0x189033('0x14be')]=[_0x189033('0x56b')];function _0x711b05(_0x2ca4df){const _0x13e55f=_0x189033,_0x590683={'cm_companies':_0x13e55f('0x27db'),'cm_contacts':_0x13e55f('0x276e'),'cm_hopper':_0x13e55f('0x26cf'),'cm_hopper_final':_0x13e55f('0x163f'),'cm_hopper_history':'cmHopperHistory','cm_lists':'cmList','chat_websites':'chatWebsite','chat_queues':'chatQueue','chat_interactions':_0x13e55f('0x1809'),'chat_messages':_0x13e55f('0x1203'),'chat_offline_messages':_0x13e55f('0xc3c'),'report_chat_queue':_0x13e55f('0x5c2'),'report_chat_transfer':_0x13e55f('0x268e'),'mail_accounts':'mailAccount','mail_queues':_0x13e55f('0x2160'),'mail_interactions':'mailInteraction','mail_messages':_0x13e55f('0xc8b'),'report_mail_queue':_0x13e55f('0x21f6'),'report_mail_transfer':_0x13e55f('0xdea'),'openchannel_accounts':_0x13e55f('0x1963'),'openchannel_queues':_0x13e55f('0x20a1'),'openchannel_interactions':_0x13e55f('0x17ff'),'openchannel_messages':'openchannelMessage','report_openchannel_queue':_0x13e55f('0x265f'),'report_openchannel_transfer':_0x13e55f('0x19'),'sms_accounts':_0x13e55f('0xa0e'),'sms_queues':_0x13e55f('0x193f'),'sms_interactions':_0x13e55f('0x22d8'),'sms_messages':_0x13e55f('0x1a45'),'report_sms_queue':_0x13e55f('0xc5f'),'report_sms_transfer':_0x13e55f('0x280e'),'fax_accounts':'faxAccount','fax_queues':_0x13e55f('0x209c'),'fax_interactions':_0x13e55f('0x1352'),'fax_messages':_0x13e55f('0x1cc'),'report_fax_transfer':_0x13e55f('0x21e0'),'report_fax_queue':'faxQueueReport','report_call':_0x13e55f('0x337'),'report_agent':_0x13e55f('0xf53'),'report_square':_0x13e55f('0x1aa6'),'report_member':_0x13e55f('0x48c'),'report_queue':_0x13e55f('0x243'),'report_square_details':_0x13e55f('0x1497'),'report_dial':_0x13e55f('0x1793'),'report_jscripty_sessions':_0x13e55f('0x1038'),'report_jscripty_questions':_0x13e55f('0x1015'),'report_jscripty_answers':_0x13e55f('0x1c08'),'users':_0x13e55f('0xc96'),'voice_recordings':_0x13e55f('0x52f'),'cdr':_0x13e55f('0x2845'),'whatsapp_accounts':_0x13e55f('0x1990'),'whatsapp_queues':'whatsappQueue','whatsapp_interactions':_0x13e55f('0x1db7'),'whatsapp_messages':_0x13e55f('0xd01'),'report_whatsapp_queue':_0x13e55f('0x206e'),'report_whatsapp_transfer':_0x13e55f('0x93d')};return{'getMap':function(){const _0x2f9e31=_0x13e55f,_0x52a6d5=[];return _0x2e3ca0()[_0x2f9e31('0x15d0')](_0x590683,function(_0x4cdfaf,_0x102e5d){const _0x1121a8=_0x2f9e31;_0x52a6d5[_0x1121a8('0x1fd0')]({'name':_0x102e5d,'api':_0x4cdfaf});}),_0x52a6d5;},'getColumns':function(_0x5f2000){const _0x2aad97=_0x13e55f,_0x4e14a1=_0x590683[_0x5f2000];return _0x2ca4df[_0x4e14a1][_0x2aad97('0x2267')]()[_0x2aad97('0xe53')];}};}const _0x4f676b=_0x711b05;_0x2d0acc[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x1d70'),_0x189033('0xaaf'),_0x189033('0xe9a'),'reportField',_0x189033('0x12d'),_0x189033('0x1a7f'),'sqlUtil',_0x189033('0x56b'),_0x189033('0x1134')];function _0x2d0acc(_0x543226,_0xbd27b,_0x167b5f,_0x4b0480,_0x10137b,_0x488ada,_0x90aa63,_0x4d7671,_0x37c30e,_0x14e202,_0x27dcea,_0x3eddce){const _0x5cb8fc=_0x189033,_0x5153f2=this;_0x5153f2[_0x5cb8fc('0x17f')]=[],_0x5153f2['title']='Edit\x20Report\x20Field',_0x5153f2[_0x5cb8fc('0xaaf')]=_0x10137b,_0x5153f2[_0x5cb8fc('0x11e7')]=angular[_0x5cb8fc('0x1a86')](_0x90aa63),_0x5153f2[_0x5cb8fc('0xe9a')]=_0x488ada,_0x5153f2[_0x5cb8fc('0x12d')]=_0x4d7671,_0x5153f2[_0x5cb8fc('0x1a7f')]=_0x37c30e,_0x5153f2[_0x5cb8fc('0x2495')]=_0x14e202,_0x5153f2[_0x5cb8fc('0x1c24')]=![],_0x5153f2['crudPermissions']=_0x3eddce;if(!_0x5153f2[_0x5cb8fc('0x11e7')])_0x5153f2['reportField']={'type':_0x5cb8fc('0x2008'),'function':null,'format':null,'groupBy':![],'orderBy':null},_0x5153f2[_0x5cb8fc('0xf28')]=_0x5cb8fc('0x1562'),_0x5153f2[_0x5cb8fc('0x1c24')]=!![];else{_0x5153f2[_0x5cb8fc('0x11e7')][_0x5cb8fc('0xcf0')]=_0x5153f2[_0x5cb8fc('0x11e7')][_0x5cb8fc('0xbf0')]?_0x5cb8fc('0xbf0'):_0x5153f2[_0x5cb8fc('0x11e7')][_0x5cb8fc('0xfa1')]?'metric':_0x5cb8fc('0x2008');if(_0x5153f2[_0x5cb8fc('0x11e7')]['field']&&!_0x5153f2[_0x5cb8fc('0x11e7')]['custom']&&_0x2e3ca0()[_0x5cb8fc('0x8f2')](_0x5153f2['reportField'][_0x5cb8fc('0xfa1')])){const _0x1cfd34=_0x5153f2[_0x5cb8fc('0x11e7')][_0x5cb8fc('0x2013')][_0x5cb8fc('0x1fc5')]('.');_0x1cfd34[_0x5cb8fc('0x1564')]===0x1&&(_0x5153f2[_0x5cb8fc('0x11e7')][_0x5cb8fc('0x2013')]=_0x5153f2[_0x5cb8fc('0xaaf')][_0x5cb8fc('0x5c4')]+'.'+_0x5153f2[_0x5cb8fc('0x11e7')][_0x5cb8fc('0x2013')]);}}_0x5153f2['addNewReportField']=_0x18ad7a,_0x5153f2[_0x5cb8fc('0xafe')]=_0x21bdfe,_0x5153f2[_0x5cb8fc('0x1c3a')]=_0x433ca1,_0x5153f2['closeDialog']=_0x3d27bd;function _0x18ad7a(){const _0x304b08=_0x5cb8fc;_0x5153f2[_0x304b08('0x17f')]=[],_0x5153f2[_0x304b08('0x11e7')][_0x304b08('0xbf0')]=_0x5153f2[_0x304b08('0x11e7')][_0x304b08('0xcf0')]==='custom',_0x5153f2[_0x304b08('0x11e7')][_0x304b08('0xfa1')]=_0x5153f2[_0x304b08('0x11e7')][_0x304b08('0xcf0')]==='metric'?_0x5153f2['reportField'][_0x304b08('0xfa1')]:null,_0x5153f2[_0x304b08('0x11e7')]['CustomReportId']=_0x5153f2['report']['id'],_0x27dcea['analyticFieldReport'][_0x304b08('0xb0a')](_0x5153f2[_0x304b08('0x11e7')])['$promise'][_0x304b08('0x683')](function(_0x3c88be){const _0x55091e=_0x304b08;_0x5153f2[_0x55091e('0xe9a')][_0x55091e('0x1fd0')](_0x3c88be),_0x4b0480[_0x55091e('0x53')]({'title':_0x55091e('0x1ae8'),'msg':_0x5153f2[_0x55091e('0x11e7')][_0x55091e('0x2013')]?_0x5153f2['reportField'][_0x55091e('0x2013')]+'\x20has\x20been\x20created!':_0x5153f2[_0x55091e('0x11e7')][_0x55091e('0xcf0')]+_0x55091e('0x14b5')}),_0x3d27bd();})[_0x304b08('0x130a')](function(_0x3e732b){const _0x2252db=_0x304b08;_0x5153f2[_0x2252db('0x17f')]=_0x3e732b['data'][_0x2252db('0x17f')]||[{'message':_0x3e732b[_0x2252db('0x1ff0')](),'type':_0x2252db('0x2cf')}];});}function _0x21bdfe(){const _0x4aedff=_0x5cb8fc;_0x5153f2[_0x4aedff('0x17f')]=[],_0x5153f2[_0x4aedff('0x11e7')][_0x4aedff('0xbf0')]=_0x5153f2[_0x4aedff('0x11e7')][_0x4aedff('0xcf0')]===_0x4aedff('0xbf0'),_0x5153f2[_0x4aedff('0x11e7')]['MetricId']=_0x5153f2[_0x4aedff('0x11e7')][_0x4aedff('0xcf0')]===_0x4aedff('0x248f')?_0x5153f2['reportField']['MetricId']:null,_0x27dcea[_0x4aedff('0x2871')][_0x4aedff('0x2480')]({'id':_0x5153f2[_0x4aedff('0x11e7')]['id']},_0x5153f2[_0x4aedff('0x11e7')])[_0x4aedff('0xe53')][_0x4aedff('0x683')](function(_0x4c6a92){const _0x275504=_0x4aedff,_0x5cdc6c=_0x2e3ca0()[_0x275504('0x1c07')](_0x5153f2['reportFields'],{'id':_0x4c6a92['id']});_0x5cdc6c&&_0x2e3ca0()['merge'](_0x5cdc6c,_0x4c6a92),_0x4b0480[_0x275504('0x53')]({'title':_0x275504('0xce1'),'msg':_0x5153f2[_0x275504('0x11e7')]['field']?_0x5153f2[_0x275504('0x11e7')][_0x275504('0x2013')]+_0x275504('0xf59'):''}),_0x3d27bd();})[_0x4aedff('0x130a')](function(_0xe5a2be){const _0x1e5558=_0x4aedff;_0x5153f2[_0x1e5558('0x17f')]=_0xe5a2be[_0x1e5558('0x5a5')][_0x1e5558('0x17f')]||[{'message':_0xe5a2be[_0x1e5558('0x1ff0')](),'type':'api.analyticFieldReport.update'}];});}function _0x433ca1(_0xb193db){const _0x2159f0=_0x5cb8fc;_0x5153f2[_0x2159f0('0x17f')]=[];const _0x5e9ead=_0x167b5f[_0x2159f0('0x1c6f')]()[_0x2159f0('0xf28')]('Are\x20you\x20sure?')[_0x2159f0('0xa6a')](_0x2159f0('0x1341'))[_0x2159f0('0x1040')](_0x2159f0('0x1863'))['ok'](_0x2159f0('0x2307'))[_0x2159f0('0x19fb')](_0x2159f0('0x253a'))[_0x2159f0('0xe42')](_0xb193db);_0x167b5f[_0x2159f0('0x1d4')](_0x5e9ead)[_0x2159f0('0x683')](function(){const _0x389f55=_0x2159f0;_0x27dcea['analyticFieldReport'][_0x389f55('0xd7e')]({'id':_0x5153f2[_0x389f55('0x11e7')]['id']})[_0x389f55('0xe53')][_0x389f55('0x683')](function(){const _0x24cea0=_0x389f55;_0x2e3ca0()[_0x24cea0('0x3ec')](_0x5153f2['reportFields'],{'id':_0x5153f2[_0x24cea0('0x11e7')]['id']}),_0x4b0480[_0x24cea0('0x53')]({'title':'Report\x20Field\x20properly\x20deleted!','msg':_0x5153f2['reportField']['field']?_0x5153f2[_0x24cea0('0x11e7')]['field']+_0x24cea0('0x194d'):''}),_0x3d27bd();})['catch'](function(_0x2d3ca0){const _0x83f9f2=_0x389f55;_0x5153f2[_0x83f9f2('0x17f')]=_0x2d3ca0['data'][_0x83f9f2('0x17f')]||[{'message':_0x2d3ca0['toString'](),'type':_0x83f9f2('0x444')}];});},function(){});}function _0x3d27bd(){const _0xaba784=_0x5cb8fc;_0x167b5f[_0xaba784('0x1715')]();}}const _0x4db28a=_0x2d0acc,_0x3cc106=_0x180212['p']+_0x189033('0x1dc4');_0x52e2b6[_0x189033('0x14be')]=['$cookies','$scope',_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),'toasty',_0x189033('0x56b'),_0x189033('0x2411'),_0x189033('0x2495'),'$translate'];function _0x52e2b6(_0x211db9,_0x4d66ff,_0x3099fc,_0x1c6ba9,_0x2e7caf,_0x3d148b,_0x43f676,_0x4e5573,_0x2f1197,_0x366c14){const _0x806ba5=_0x189033,_0x3ab1db=this;_0x3ab1db[_0x806ba5('0xaaf')]={},_0x3ab1db[_0x806ba5('0xe9a')]={'count':0x0,'rows':[]},_0x3ab1db['functions']=_0x2e3ca0()[_0x806ba5('0x24db')](_0x2f1197[_0x806ba5('0x91b')],_0x806ba5('0x1c6b')),_0x3ab1db[_0x806ba5('0x204f')]=_0x2e3ca0()['keyBy'](_0x2f1197[_0x806ba5('0xd9f')],_0x806ba5('0x1c6b')),_0x3ab1db['groupBy']=_0x2e3ca0()[_0x806ba5('0x24db')](_0x2f1197['getGroupBy'],_0x806ba5('0x1c6b')),_0x3ab1db[_0x806ba5('0x2ef')]=_0x2e3ca0()['keyBy'](_0x2f1197[_0x806ba5('0x2192')],_0x806ba5('0x1c6b')),_0x3ab1db[_0x806ba5('0x780')]=[],_0x3ab1db['query']={'fields':_0x806ba5('0x1714'),'nolimit':!![]},_0x3ab1db[_0x806ba5('0x1027')]={'animation':0x64,'onSort':function(_0x12ccde){const _0x596c77=_0x806ba5;_0x43f676['analyticFieldReport']['addFields']({'id':_0x3ab1db[_0x596c77('0xaaf')]['id']},_0x12ccde[_0x596c77('0x10a2')])[_0x596c77('0xe53')][_0x596c77('0x683')](function(_0x5843f5){const _0x5568d4=_0x596c77;_0x3ab1db[_0x5568d4('0xe9a')][_0x5568d4('0xf5d')]=_0x5843f5;})[_0x596c77('0x130a')](function(_0x23b4ba){const _0x550da4=_0x596c77;_0x3d148b[_0x550da4('0x52a')]({'title':_0x23b4ba[_0x550da4('0x13ee')]?_0x550da4('0x2168')+_0x23b4ba[_0x550da4('0x13ee')]+_0x550da4('0xbf6')+_0x23b4ba[_0x550da4('0x24a9')]:_0x550da4('0xdc2')});});}},_0x3ab1db['init']=_0x441878,_0x3ab1db[_0x806ba5('0x26eb')]=_0x24bcc6,_0x3ab1db[_0x806ba5('0x53')]=_0x2be8ce,_0x3ab1db[_0x806ba5('0x21e8')]=_0x151ed9,_0x3ab1db[_0x806ba5('0x177d')]=_0x576c93,_0x3ab1db[_0x806ba5('0x1c3a')]=_0x47d494,_0x3ab1db[_0x806ba5('0x16f3')]=_0x38934c,_0x3ab1db[_0x806ba5('0xe8f')]=_0x4a85c0,_0x3ab1db['getMetricValue']=_0x479209;function _0x441878(_0x393b36,_0x117718){const _0x3827d5=_0x806ba5;_0x3ab1db[_0x3827d5('0xaaf')]=_0x393b36,_0x3ab1db['query'][_0x3827d5('0x1b81')]=_0x3ab1db[_0x3827d5('0xaaf')]['id'],_0x3ab1db[_0x3827d5('0x1134')]=typeof _0x117718!=='undefined'?_0x117718:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3ab1db[_0x3827d5('0x1027')][_0x3827d5('0x120b')]=!_0x3ab1db['crudPermissions'][_0x3827d5('0x1978')]?!![]:![],_0x4e5573[_0x3827d5('0x24f5')](_0x3ab1db[_0x3827d5('0xaaf')][_0x3827d5('0x5c4')])[_0x3827d5('0x683')](function(_0x42a343){const _0x3b3022=_0x3827d5;return _0x3ab1db[_0x3b3022('0x1a7f')]=_0x2e3ca0()[_0x3b3022('0x2829')](_0x2e3ca0()['keys'](_0x42a343),[_0x3b3022('0xe53'),'$resolved']),_0x43f676[_0x3b3022('0x1c97')]['get']({'fields':_0x3b3022('0x109d'),'nolimit':!![]})[_0x3b3022('0xe53')];})['then'](function(_0x400169){const _0x14ee8a=_0x3827d5;_0x3ab1db[_0x14ee8a('0x12d')]=_0x400169[_0x14ee8a('0xf5d')];})[_0x3827d5('0x130a')](function(_0x428601){const _0x17a92e=_0x3827d5;_0x3d148b['error']({'title':_0x428601[_0x17a92e('0x13ee')]?_0x17a92e('0x2168')+_0x428601[_0x17a92e('0x13ee')]+_0x17a92e('0xbf6')+_0x428601['statusText']:_0x17a92e('0x16df'),'msg':_0x428601[_0x17a92e('0x5a5')]?JSON[_0x17a92e('0x258a')](_0x428601[_0x17a92e('0x5a5')]):_0x428601[_0x17a92e('0x1ff0')]()});}),_0x3ab1db[_0x3827d5('0x21e8')]();}function _0x24bcc6(_0x28b340,_0x219b53){const _0x1cfe49=_0x806ba5,_0x4d5133=_0x1c6ba9[_0x1cfe49('0x1c6f')]()[_0x1cfe49('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x1cfe49('0x26e3')](_0x1cfe49('0xed5')+_0x28b340['field']+_0x1cfe49('0x20f1')+'\x20will\x20be\x20deleted.')['ariaLabel']('delete\x20field')['targetEvent'](_0x219b53)['ok']('OK')['cancel'](_0x1cfe49('0x16b8'));_0x1c6ba9[_0x1cfe49('0x1d4')](_0x4d5133)[_0x1cfe49('0x683')](function(){_0x47d494(_0x28b340);},function(){const _0x4450f5=_0x1cfe49;console[_0x4450f5('0x1b2b')](_0x4450f5('0x16b8'));});}let _0x556ca8=!![];_0x4d66ff[_0x806ba5('0x186d')](_0x806ba5('0x2459'),function(){const _0x142e74=_0x806ba5;_0x556ca8?_0x3099fc(function(){_0x556ca8=![];}):_0x3ab1db[_0x142e74('0x21e8')]();});function _0x2be8ce(_0x43a534){const _0xe14d5c=_0x806ba5;_0x3ab1db[_0xe14d5c('0xe9a')]=_0x43a534||{'count':0x0,'rows':[]};}function _0x151ed9(){const _0x1bbbbb=_0x806ba5;_0x3ab1db['promise']=_0x43f676[_0x1bbbbb('0x2871')]['get'](_0x3ab1db[_0x1bbbbb('0x23a2')],_0x2be8ce)[_0x1bbbbb('0xe53')];}function _0x576c93(_0x383157,_0x4ea4a7){const _0xe6d11c=_0x806ba5;_0x1c6ba9[_0xe6d11c('0x1d4')]({'controller':'CreateOrEditReportFieldDialogController','controllerAs':'vm','templateUrl':_0x3cc106,'parent':angular[_0xe6d11c('0x1fcc')](_0x2e7caf[_0xe6d11c('0x18e5')]),'targetEvent':_0x383157,'clickOutsideToClose':!![],'locals':{'report':_0x3ab1db[_0xe6d11c('0xaaf')],'reportField':_0x4ea4a7,'reportFields':_0x3ab1db[_0xe6d11c('0xe9a')][_0xe6d11c('0xf5d')],'metrics':_0x3ab1db[_0xe6d11c('0x12d')],'columns':_0x3ab1db[_0xe6d11c('0x1a7f')],'setting':null,'crudPermissions':_0x3ab1db[_0xe6d11c('0x1134')]}});}function _0x47d494(_0x204eaa){const _0x4cca03=_0x806ba5;_0x43f676[_0x4cca03('0x2871')][_0x4cca03('0xd7e')]({'id':_0x204eaa['id']})[_0x4cca03('0xe53')][_0x4cca03('0x683')](function(){const _0x53fbf6=_0x4cca03;_0x3ab1db[_0x53fbf6('0x780')]=[],_0x2e3ca0()[_0x53fbf6('0x3ec')](_0x3ab1db[_0x53fbf6('0xe9a')][_0x53fbf6('0xf5d')],{'id':_0x204eaa['id']}),_0x3ab1db[_0x53fbf6('0xe9a')][_0x53fbf6('0x50d')]-=0x1,!_0x3ab1db[_0x53fbf6('0xe9a')]['rows'][_0x53fbf6('0x1564')]&&_0x3ab1db[_0x53fbf6('0x21e8')](),_0x3d148b[_0x53fbf6('0x53')]({'title':_0x53fbf6('0x1666'),'msg':_0x204eaa['field']?_0x204eaa['field']+_0x53fbf6('0x194d'):''});})[_0x4cca03('0x130a')](function(_0x4ac701){const _0x1a5878=_0x4cca03;_0x3d148b['error']({'title':_0x4ac701[_0x1a5878('0x13ee')]?_0x1a5878('0x2168')+_0x4ac701[_0x1a5878('0x13ee')]+_0x1a5878('0xbf6')+_0x4ac701[_0x1a5878('0x24a9')]:_0x1a5878('0x1ab2'),'msg':_0x4ac701[_0x1a5878('0x5a5')]?JSON[_0x1a5878('0x258a')](_0x4ac701['data']):_0x4ac701[_0x1a5878('0x1ff0')]()});});}function _0x38934c(_0x3ebd4b){const _0x52edae=_0x806ba5,_0x4ceeba=_0x1c6ba9[_0x52edae('0x1c6f')]()[_0x52edae('0xf28')](_0x52edae('0x19b1'))[_0x52edae('0x26e3')](_0x52edae('0xed5')+_0x3ab1db[_0x52edae('0x780')][_0x52edae('0x1564')]+_0x52edae('0x93c')+_0x52edae('0x1ee7'))[_0x52edae('0x1040')](_0x52edae('0x994'))['targetEvent'](_0x3ebd4b)['ok']('OK')[_0x52edae('0x19fb')](_0x52edae('0x16b8'));_0x1c6ba9['show'](_0x4ceeba)[_0x52edae('0x683')](function(){const _0xa50e3e=_0x52edae;_0x3ab1db['selectedReportFields'][_0xa50e3e('0x1299')](function(_0x4d6efd){_0x47d494(_0x4d6efd);}),_0x3ab1db['selectedReportFields']=[];});}function _0x4a85c0(_0x343ff2){const _0x18b869=_0x806ba5,_0x142aae=_0x2e3ca0()['find'](_0x3ab1db[_0x18b869('0x12d')],{'id':_0x343ff2});return _0x142aae?_0x142aae[_0x18b869('0x60a')]:_0x366c14[_0x18b869('0x2728')](_0x18b869('0x1cf9'));}function _0x479209(_0x126c58){const _0x49ca89=_0x806ba5,_0x240150=_0x2e3ca0()[_0x49ca89('0x1c07')](_0x3ab1db[_0x49ca89('0x12d')],{'id':_0x126c58});return _0x240150?_0x240150[_0x49ca89('0x248f')]:_0x366c14[_0x49ca89('0x2728')](_0x49ca89('0x1cf9'));}}const _0x58df81=_0x52e2b6;function _0x540c77(){const _0x3eeda1=_0x189033,_0x4ab57d=[{'value':_0x3eeda1('0x1434'),'option':function(_0x9acc62){const _0x40489b=_0x3eeda1;return _0x40489b('0x20e7')+_0x9acc62+')';}},{'value':_0x3eeda1('0xb6'),'option':function(_0x35ffcb){const _0x11e823=_0x3eeda1;return _0x11e823('0x1a2b')+_0x35ffcb+')';}},{'value':_0x3eeda1('0x227d'),'option':function(_0x3c09cf){const _0x489099=_0x3eeda1;return _0x489099('0x1b60')+_0x3c09cf+')';}},{'value':_0x3eeda1('0x2508'),'option':function(_0xc68798){const _0x3ba76d=_0x3eeda1;return _0x3ba76d('0x2837')+_0xc68798+')';}},{'value':_0x3eeda1('0x1fda'),'option':function(_0x5bd67d){const _0x2f42f8=_0x3eeda1;return _0x2f42f8('0x8b')+_0x5bd67d+')';}},{'value':'AVG','option':function(_0x31be89){const _0x8e38c4=_0x3eeda1;return _0x8e38c4('0x282b')+_0x31be89+')';}},{'value':_0x3eeda1('0x1611'),'option':function(_0x135b0c){return'GROUP_CONCAT\x20('+_0x135b0c+')';}},{'value':'GROUP_CONCAT\x20ASC','option':function(_0x4a9097){const _0x159aba=_0x3eeda1;return _0x159aba('0x1d3b')+_0x4a9097+_0x159aba('0x198')+_0x4a9097+_0x159aba('0x20e3');}},{'value':'GROUP_CONCAT\x20DESC','option':function(_0x3693fb){const _0x189326=_0x3eeda1;return _0x189326('0x1d3b')+_0x3693fb+_0x189326('0x198')+_0x3693fb+'\x20DESC)';}}],_0x155b53=[{'value':'SEC_TO_TIME','option':function(_0x27091b){const _0x390313=_0x3eeda1;return _0x390313('0xbd')+_0x27091b+')';}},{'value':'DATE','option':function(_0x58715d){return'DATE\x20('+_0x58715d+')';}},{'value':'HOUR','option':function(_0x28049d){return'HOUR\x20('+_0x28049d+')';}},{'value':'ROUND','option':function(_0x580b53){const _0x2a53a2=_0x3eeda1;return _0x2a53a2('0x207c')+_0x580b53+')';}},{'value':'UNIX_TIMESTAMP','option':function(_0x878c5e){const _0x315e69=_0x3eeda1;return _0x315e69('0x254d')+_0x878c5e+')';}}],_0x5b172d=[{'value':![],'option':function(){return'No';}},{'value':!![],'option':function(_0x172738){return'GROUP\x20BY\x20'+_0x172738;}}],_0x36e802=[{'value':'ASC','option':function(_0x3c1d37){const _0x1955ac=_0x3eeda1;return _0x1955ac('0x2d9')+_0x3c1d37+'\x20ASC';}},{'value':_0x3eeda1('0xee8'),'option':function(_0x4aca5e){const _0x1189ee=_0x3eeda1;return _0x1189ee('0x2d9')+_0x4aca5e+_0x1189ee('0x1170');}}],_0xd2b8aa=['=','!=','<','<=','>','>=','LIKE',_0x3eeda1('0x1a3d'),_0x3eeda1('0x834'),_0x3eeda1('0x25d5'),_0x3eeda1('0x19e9'),_0x3eeda1('0x42c')];return{'getFunctions':_0x4ab57d,'getFormats':_0x155b53,'getGroupBy':_0x5b172d,'getOrderBy':_0x36e802,'getConditions':_0xd2b8aa};}const _0xf49d7c=_0x540c77;_0x2ec8c0['$inject']=[_0x189033('0x938'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xaaf'),_0x189033('0xba1'),'userProfileSection'];function _0x2ec8c0(_0x4eff94,_0xe28652,_0x5387ca,_0x49ec40,_0x29606b,_0x2b6617){const _0x2bc701=_0x189033,_0x104d42=this;_0x104d42[_0x2bc701('0xaaf')]=_0x49ec40||{},_0x104d42[_0x2bc701('0x22df')]=_0x2b6617&&_0x2b6617['count']==0x1?_0x2b6617[_0x2bc701('0xf5d')][0x0]:null,_0x104d42['crudPermissions']=_0x29606b[_0x2bc701('0x142a')](_0x104d42['userProfileSection']?_0x104d42[_0x2bc701('0x22df')][_0x2bc701('0x1134')]:null),_0x104d42[_0x2bc701('0x517')]=_0x4eff94[_0x2bc701('0x7f2')][_0x2bc701('0x1904')]||0x0,_0x104d42[_0x2bc701('0xf31')]=_0x2e0c75,_0x104d42['saveReport']=_0x98e40a,_0x104d42[_0x2bc701('0x1eb4')]=_0x18573f,_0x104d42[_0x2bc701('0x4f1')]=_0x1519d5,_0x104d42[_0x2bc701('0x8b9')]=_0x5d767d,_0x104d42[_0x2bc701('0x94b')]=_0x224f3a,_0x104d42[_0x2bc701('0x1849')]=_0x4d533f;function _0x2e0c75(){const _0x3bcf27=_0x2bc701;_0x4eff94['go']('app.analytics.reports',{},{'reload':_0x3bcf27('0x2721')});}function _0x98e40a(){const _0x360dbe=_0x2bc701;_0x104d42[_0x360dbe('0xaaf')]['conditions']=angular[_0x360dbe('0x1bf7')](_0x104d42['report']['condition']),_0x5387ca[_0x360dbe('0x197f')][_0x360dbe('0x2480')]({'id':_0x104d42[_0x360dbe('0xaaf')]['id']},_0x2e3ca0()[_0x360dbe('0x8b5')](_0x104d42[_0x360dbe('0xaaf')],_0x360dbe('0x21b0')))[_0x360dbe('0xe53')]['then'](function(){const _0x434251=_0x360dbe;_0xe28652[_0x434251('0x53')]({'title':'Report\x20updated!','msg':_0x104d42[_0x434251('0xaaf')][_0x434251('0x60a')]?_0x104d42['report'][_0x434251('0x60a')]+_0x434251('0x96c'):''});})[_0x360dbe('0x130a')](function(_0x2ed819){const _0x3d9489=_0x360dbe;_0xe28652['error']({'title':_0x2ed819['status']?_0x3d9489('0x2168')+_0x2ed819[_0x3d9489('0x13ee')]+_0x3d9489('0xbf6')+_0x2ed819['statusText']:_0x3d9489('0x1200'),'msg':_0x2ed819[_0x3d9489('0x5a5')]?JSON[_0x3d9489('0x258a')](_0x2ed819['data']):_0x2ed819[_0x3d9489('0x1ff0')]()});});}function _0x18573f(){const _0x2bc797=_0x2bc701;_0x104d42[_0x2bc797('0x1a7f')]=[],_0x104d42['rows']=[],_0x104d42[_0x2bc797('0x52a')]=![],_0x5387ca['analyticFieldReport'][_0x2bc797('0x1e6e')]({'fields':_0x2bc797('0x220e'),'nolimit':!![],'CustomReportId':_0x104d42[_0x2bc797('0xaaf')]['id']})[_0x2bc797('0xe53')][_0x2bc797('0x683')](function(_0x761705){const _0x5972d3=_0x2bc797;return _0x104d42[_0x5972d3('0x1a7f')]=_0x761705?_0x761705[_0x5972d3('0xf5d')]:[],_0x5387ca[_0x5972d3('0x197f')][_0x5972d3('0x5f9')]({'id':_0x104d42[_0x5972d3('0xaaf')]['id']})['$promise'];})['then'](function(_0x5b88de){const _0x486fa5=_0x2bc797;_0x104d42[_0x486fa5('0xf5d')]=_0x5b88de;})[_0x2bc797('0x130a')](function(_0x5c6afc){const _0x27d84d=_0x2bc797;console[_0x27d84d('0x1b2b')](_0x5c6afc),_0x104d42[_0x27d84d('0x52a')]={'title':_0x5c6afc[_0x27d84d('0x13ee')]?_0x27d84d('0x2168')+_0x5c6afc[_0x27d84d('0x13ee')]+'\x20-\x20'+_0x5c6afc[_0x27d84d('0x24a9')]:_0x27d84d('0x24c9'),'msg':_0x5c6afc[_0x27d84d('0x5a5')]?_0x5c6afc['data'][_0x27d84d('0x8c2')]:_0x5c6afc[_0x27d84d('0x1ff0')](),'sql':_0x5c6afc['data']?_0x5c6afc['data'][_0x27d84d('0x2361')]?_0x5c6afc[_0x27d84d('0x5a5')]['parent'][_0x27d84d('0x1e35')]:_0x27d84d('0x1908'):'NO\x20QUERY'},_0xe28652[_0x27d84d('0x52a')](_0x104d42[_0x27d84d('0x52a')]);});}function _0x4d533f(_0x5888cc,_0x4f1b92){const _0x160d1a=_0x2bc701;return _0x1aaf93()(_0x4f1b92,'YYYY-MM-DDTHH:mm:ssZ',!![])[_0x160d1a('0x24f4')]()&&(_0x4f1b92=_0x1aaf93()(_0x4f1b92,'')[_0x160d1a('0x26dd')](_0x160d1a('0x865'))),_0x4f1b92;}function _0x1519d5(){const _0x405ab0=_0x2bc701;return _0x104d42['queryResult']=_0x405ab0('0xae9'),_0x5387ca[_0x405ab0('0x197f')][_0x405ab0('0x23a2')]({'id':_0x104d42['report']['id']})['$promise']['then'](function(_0x590b01){const _0x128d32=_0x405ab0;_0x104d42[_0x128d32('0x1205')]=_0x590b01[_0x128d32('0x1e35')];})[_0x405ab0('0x130a')](function(_0x50adb2){const _0x50eb4e=_0x405ab0;_0x104d42[_0x50eb4e('0x1205')]='',console[_0x50eb4e('0x1b2b')](_0x50adb2),_0x104d42[_0x50eb4e('0x52a')]={'title':_0x50adb2['status']?'API:'+_0x50adb2[_0x50eb4e('0x13ee')]+_0x50eb4e('0xbf6')+_0x50adb2[_0x50eb4e('0x24a9')]:_0x50eb4e('0x24c9'),'msg':_0x50adb2['data']?_0x50adb2['data'][_0x50eb4e('0x8c2')]:_0x50adb2[_0x50eb4e('0x1ff0')](),'sql':_0x50adb2[_0x50eb4e('0x5a5')]?_0x50adb2[_0x50eb4e('0x5a5')][_0x50eb4e('0x2361')]?_0x50adb2[_0x50eb4e('0x5a5')][_0x50eb4e('0x2361')][_0x50eb4e('0x1e35')]:_0x50eb4e('0x1908'):_0x50eb4e('0x1908')},_0xe28652[_0x50eb4e('0x52a')](_0x104d42[_0x50eb4e('0x52a')]);});}function _0x5d767d(_0xac4ac,_0x3dd782){const _0x4e8df3=_0x2bc701;if(_0x224f3a(_0xac4ac))return _0x2e3ca0()[_0x4e8df3('0x386')](_0xac4ac,_0x3dd782)['join'](',');return'';}function _0x224f3a(_0x47a135){const _0x2f63c3=_0x2bc701;return _0x2e3ca0()[_0x2f63c3('0x94b')](_0x47a135);}}const _0x164082=_0x2ec8c0;_0x5435c9[_0x189033('0x14be')]=[_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x1d70'),'report','api','apiName'];function _0x5435c9(_0x20b9ec,_0x254dd8,_0x54abbb,_0x46a578,_0x170a8c,_0x54ae5f){const _0x459ab1=_0x189033,_0x44ff32=this;_0x44ff32[_0x459ab1('0x17f')]=[],_0x44ff32['report']=angular[_0x459ab1('0x1a86')](_0x46a578),_0x44ff32[_0x459ab1('0x1849')]=_0x31cc21,_0x44ff32[_0x459ab1('0xf82')]=_0x56078e,_0xeb5fa7();function _0xeb5fa7(){const _0x4f114d=_0x459ab1;_0x44ff32[_0x4f114d('0x1a7f')]=[],_0x44ff32[_0x4f114d('0xf5d')]=[],_0x44ff32[_0x4f114d('0x52a')]=![];const _0x70fff={'fields':_0x4f114d('0x220e'),'nolimit':!![]};_0x70fff[_0x54ae5f===_0x4f114d('0x197f')?_0x4f114d('0x1b81'):'DefaultReportId']=_0x44ff32[_0x4f114d('0xaaf')]['id'],_0x44ff32['promise']=_0x170a8c['analyticFieldReport'][_0x4f114d('0x1e6e')](_0x70fff)[_0x4f114d('0xe53')][_0x4f114d('0x683')](function(_0x1467b9){const _0x547fe4=_0x4f114d;return _0x44ff32[_0x547fe4('0x1a7f')]=_0x1467b9?_0x1467b9[_0x547fe4('0xf5d')]:[],_0x170a8c[_0x54ae5f][_0x547fe4('0x5f9')]({'id':_0x44ff32[_0x547fe4('0xaaf')]['id']})['$promise'];})[_0x4f114d('0x683')](function(_0x350685){_0x44ff32['rows']=_0x350685;})[_0x4f114d('0x130a')](function(_0x4535c5){const _0x328ec7=_0x4f114d;console[_0x328ec7('0x1b2b')](_0x4535c5),_0x44ff32[_0x328ec7('0x52a')]={'title':_0x4535c5[_0x328ec7('0x13ee')]?_0x328ec7('0x2168')+_0x4535c5[_0x328ec7('0x13ee')]+'\x20-\x20'+_0x4535c5[_0x328ec7('0x24a9')]:_0x328ec7('0x24c9'),'msg':_0x4535c5['data']?_0x4535c5[_0x328ec7('0x5a5')]['message']:_0x4535c5['toString'](),'sql':_0x4535c5[_0x328ec7('0x5a5')]?_0x4535c5[_0x328ec7('0x5a5')]['parent']?_0x4535c5[_0x328ec7('0x5a5')][_0x328ec7('0x2361')]['sql']:'NO\x20QUERY':_0x328ec7('0x1908')},_0x54abbb[_0x328ec7('0x52a')](_0x44ff32[_0x328ec7('0x52a')]);});}function _0x31cc21(_0x1a771b,_0x1a7184){const _0x4f4c9b=_0x459ab1;return _0x1aaf93()(_0x1a7184,_0x4f4c9b('0x1b7e'),!![])[_0x4f4c9b('0x24f4')]()&&(_0x1a7184=_0x1aaf93()(_0x1a7184,'')['format'](_0x4f4c9b('0x865'))),_0x1a7184;}function _0x56078e(){const _0x5ac95a=_0x459ab1;_0x254dd8[_0x5ac95a('0x1715')]();}}const _0x18b9d0=_0x5435c9,_0x2fc471=_0x180212['p']+_0x189033('0x1196'),_0x5e22e8=_0x180212['p']+_0x189033('0x1d83'),_0x296a9c=_0x180212['p']+_0x189033('0x110d'),_0x25b8ce=_0x180212['p']+_0x189033('0xcf3');_0x2009f[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x16ea'),_0x189033('0x1e48'),_0x189033('0x938'),_0x189033('0x2063'),'$translate',_0x189033('0x2a'),_0x189033('0x22df'),'api',_0x189033('0x1c99'),'toasty',_0x189033('0xba1')];function _0x2009f(_0x52966d,_0x47c137,_0x21f58c,_0x1472ab,_0x37269f,_0x38c08a,_0xb33a42,_0x285380,_0x2e98ef,_0x36596f,_0x4da5a7,_0x2192ac,_0x163e1c){const _0x53eb2e=_0x189033,_0x9ed388=this;_0x9ed388[_0x53eb2e('0x11ed')]=_0x163e1c['getCurrentUser'](),_0x9ed388[_0x53eb2e('0x4c2')]={'count':0x0,'rows':[]},_0x9ed388['userProfile']=_0x285380,_0x9ed388[_0x53eb2e('0x22df')]=_0x2e98ef&&_0x2e98ef[_0x53eb2e('0x50d')]==0x1?_0x2e98ef[_0x53eb2e('0xf5d')][0x0]:null,_0x9ed388[_0x53eb2e('0x1134')]=_0x163e1c[_0x53eb2e('0x142a')](_0x9ed388['userProfileSection']?_0x9ed388['userProfileSection'][_0x53eb2e('0x1134')]:null),_0x9ed388[_0x53eb2e('0x1e67')]=[],_0x9ed388[_0x53eb2e('0x23a2')]={'fields':'createdAt,updatedAt,id,name,description,table,parent,conditions,joins','limit':0xa,'page':0x1,'sort':_0x53eb2e('0xc36')},_0x9ed388[_0x53eb2e('0x213')]=null,_0x9ed388[_0x53eb2e('0x228d')]='',_0x9ed388[_0x53eb2e('0xfed')]=!![],_0x9ed388[_0x53eb2e('0xc63')]=_0x2427f4,_0x9ed388[_0x53eb2e('0x1b6f')]=_0x20c2ad,_0x9ed388[_0x53eb2e('0x955')]=_0x44b1f3,_0x9ed388[_0x53eb2e('0x968')]=_0x4c537b,_0x9ed388[_0x53eb2e('0xfda')]=_0x297de8,_0x9ed388[_0x53eb2e('0x194f')]=_0x42f15d,_0x9ed388[_0x53eb2e('0x53')]=_0x5bfe11,_0x9ed388[_0x53eb2e('0x2398')]=_0x38e81c,_0x9ed388['createOrEditReport']=_0x292d7f,_0x9ed388[_0x53eb2e('0x215')]=_0x3ad8e1,_0x9ed388[_0x53eb2e('0xed3')]=_0x1e0606,_0x9ed388[_0x53eb2e('0x273e')]=_0x32815c,_0x9ed388[_0x53eb2e('0x276b')]=_0x1ca9af,_0x9ed388[_0x53eb2e('0x213d')]=_0xf8a47,_0x9ed388[_0x53eb2e('0x1d99')]=_0x57eacc,_0x9ed388[_0x53eb2e('0x91d')]=_0x4da5a7[_0x53eb2e('0xf5d')][0x0]?angular['fromJson'](_0x4da5a7[_0x53eb2e('0xf5d')][0x0][_0x53eb2e('0x2eb')]):[],_0x9ed388[_0x53eb2e('0x189c')]=_0x4da5a7[_0x53eb2e('0xf5d')][0x1]?angular[_0x53eb2e('0x1cb2')](_0x4da5a7[_0x53eb2e('0xf5d')][0x1][_0x53eb2e('0x2eb')]):[],_0x9ed388[_0x53eb2e('0x20e8')]=_0x4d571d(![]),_0x9ed388[_0x53eb2e('0x2262')]=_0x4d571d(!![]),_0x9ed388[_0x53eb2e('0x11cb')]=_0x50b237(![]),_0x9ed388[_0x53eb2e('0x26b7')]=_0x50b237(!![]);function _0x2427f4(_0x41750d){const _0x1b3b68=_0x53eb2e;_0x37269f['go'](_0x1b3b68('0x16ef'),{'id':_0x41750d['id'],'crudPermissions':_0x9ed388[_0x1b3b68('0x1134')]});}function _0x20c2ad(_0x4d8b19,_0x6181fc){const _0x29ffca=_0x53eb2e;_0x1472ab[_0x29ffca('0x1d4')]({'controller':_0x29ffca('0x19d6'),'controllerAs':'vm','templateUrl':_0x2fc471,'parent':angular[_0x29ffca('0x1fcc')](_0x21f58c['body']),'targetEvent':_0x6181fc,'clickOutsideToClose':!![],'locals':{'report':_0x4d8b19,'apiName':_0x9ed388[_0x29ffca('0x213')],'treeCustomData':_0x9ed388[_0x29ffca('0x13f6')][_0x29ffca('0x184b')](!![])[_0x29ffca('0xdd1')]('#')}})[_0x29ffca('0x2874')](function(){});}function _0x44b1f3(_0xd589a6,_0x491bb3){const _0x4965b4=_0x53eb2e;_0x1472ab['show']({'controller':_0x4965b4('0x9b0'),'controllerAs':'vm','templateUrl':_0x5e22e8,'parent':angular[_0x4965b4('0x1fcc')](_0x21f58c['body']),'targetEvent':_0x491bb3,'clickOutsideToClose':!![],'locals':{'report':_0xd589a6,'apiName':_0x9ed388['apiName']}});}function _0x4c537b(_0x1fb64c,_0x558753){const _0x16f75c=_0x53eb2e;_0x1472ab[_0x16f75c('0x1d4')]({'controller':_0x16f75c('0xe44'),'controllerAs':'vm','templateUrl':_0x296a9c,'parent':angular['element'](_0x21f58c[_0x16f75c('0x18e5')]),'targetEvent':_0x558753,'clickOutsideToClose':!![],'locals':{'report':_0x1fb64c,'apiName':_0x9ed388[_0x16f75c('0x213')],'currentPath':_0x9ed388[_0x16f75c('0x228d')]}});}function _0x297de8(_0xa7c2f0){const _0x8c67d8=_0x53eb2e;let _0x444596;_0x36596f['analyticMetric'][_0x8c67d8('0x1e6e')]({'fields':_0x8c67d8('0x109d'),'nolimit':!![]})['$promise']['then'](function(_0x30859f){const _0x10bdb0=_0x8c67d8;_0x444596=_0x2e3ca0()[_0x10bdb0('0x24db')](_0x30859f[_0x10bdb0('0xf5d')],'id');const _0x4d79c7={'fields':_0x10bdb0('0x22ba'),'nolimit':!![]};return _0x4d79c7[_0x9ed388[_0x10bdb0('0x213')]==='analyticCustomReport'?_0x10bdb0('0x1b81'):_0x10bdb0('0x24a1')]=_0xa7c2f0['id'],_0x36596f[_0x10bdb0('0x2871')][_0x10bdb0('0x1e6e')](_0x4d79c7)[_0x10bdb0('0xe53')];})[_0x8c67d8('0x683')](function(_0x11e7a9){const _0x5a642f=_0x8c67d8;for(let _0x47b0a=0x0;_0x47b0a<_0x11e7a9[_0x5a642f('0xf5d')][_0x5a642f('0x1564')];_0x47b0a+=0x1){_0x11e7a9[_0x5a642f('0xf5d')][_0x47b0a][_0x5a642f('0xfa1')]&&(_0x11e7a9[_0x5a642f('0xf5d')][_0x47b0a]['field']=_0x444596[_0x11e7a9[_0x5a642f('0xf5d')][_0x47b0a][_0x5a642f('0xfa1')]][_0x5a642f('0x248f')],_0x11e7a9[_0x5a642f('0xf5d')][_0x47b0a][_0x5a642f('0xbf0')]=!![]),delete _0x11e7a9[_0x5a642f('0xf5d')][_0x47b0a]['MetricId'];}const _0x1c0b03=_0x38c08a[_0x5a642f('0x12e1')][_0x5a642f('0x1ffa')]('a');_0x1c0b03[_0x5a642f('0x2767')]=_0x5a642f('0x2529')+_0x38c08a['encodeURIComponent'](angular[_0x5a642f('0x1bf7')]({'name':_0xa7c2f0[_0x5a642f('0x60a')],'description':_0xa7c2f0[_0x5a642f('0xd6b')],'table':_0xa7c2f0[_0x5a642f('0x5c4')],'conditions':_0xa7c2f0[_0x5a642f('0x27a5')],'joins':_0xa7c2f0[_0x5a642f('0x21b0')],'fields':_0x11e7a9['rows']})),_0x1c0b03[_0x5a642f('0x18e8')]=_0xa7c2f0[_0x5a642f('0x60a')]+_0x5a642f('0x4cd'),_0x1c0b03[_0x5a642f('0x568')]=_0x5a642f('0xa77'),_0x1c0b03['click'](),_0x2192ac[_0x5a642f('0x53')]({'title':_0x5a642f('0x2827'),'msg':_0xa7c2f0[_0x5a642f('0x60a')]?_0xa7c2f0['name']+_0x5a642f('0x13ff'):''});})[_0x8c67d8('0x130a')](function(_0x113646){const _0x3be9a7=_0x8c67d8;_0x2192ac[_0x3be9a7('0x52a')]({'title':_0x113646['status']?_0x3be9a7('0x2168')+_0x113646[_0x3be9a7('0x13ee')]+_0x3be9a7('0xbf6')+_0x113646[_0x3be9a7('0x24a9')]:_0x3be9a7('0x2083'),'msg':_0x113646[_0x3be9a7('0x5a5')]?JSON['stringify'](_0x113646[_0x3be9a7('0x5a5')]):_0x113646[_0x3be9a7('0x1ff0')]()});});}function _0x42f15d(_0x3854f7,_0xfa8fd5){const _0x508166=_0x53eb2e,_0x41fc76=_0x1472ab[_0x508166('0x1c6f')]()['title'](_0x508166('0x1975'))['htmlContent'](''+_0x3854f7['name']+_0x508166('0x20f1')+_0x508166('0x1ee7'))[_0x508166('0x1040')](_0x508166('0x22f7'))[_0x508166('0xe42')](_0xfa8fd5)['ok']('OK')[_0x508166('0x19fb')](_0x508166('0x16b8'));_0x1472ab[_0x508166('0x1d4')](_0x41fc76)[_0x508166('0x683')](function(){_0x1e0606(_0x3854f7);},function(){const _0x5c93f6=_0x508166;console['log'](_0x5c93f6('0x16b8'));});}let _0x56a431=!![],_0x5e4019=0x1;_0x52966d['$watch']('vm.query.filter',function(_0x3bac8b,_0x140180){const _0x542d82=_0x53eb2e;_0x56a431?_0x47c137(function(){_0x56a431=![];}):(!_0x140180&&(_0x5e4019=_0x9ed388[_0x542d82('0x23a2')][_0x542d82('0xdf8')]),_0x3bac8b!==_0x140180&&(_0x9ed388[_0x542d82('0x23a2')][_0x542d82('0xdf8')]=0x1),!_0x3bac8b&&(_0x9ed388[_0x542d82('0x23a2')][_0x542d82('0xdf8')]=_0x5e4019),_0x9ed388[_0x542d82('0x2398')]());}),_0x52966d[_0x53eb2e('0x186d')]('vm.search',function(_0x599a66){const _0x2b6bf1=_0x53eb2e;_0x9ed388['treeDefaultInstance']&&_0x9ed388['treeDefaultInstance']['jstree'](!![])['search'](_0x599a66),_0x9ed388['treeCustomInstance']&&_0x9ed388['treeCustomInstance']['jstree'](!![])[_0x2b6bf1('0x19a4')](_0x599a66);});function _0x5bfe11(_0x58662e){const _0x56c5ba=_0x53eb2e;_0x9ed388[_0x56c5ba('0x4c2')]=_0x58662e||{'count':0x0,'rows':[]};}function _0x38e81c(){const _0x50de0a=_0x53eb2e;_0x9ed388['query'][_0x50de0a('0x1cc8')]=(_0x9ed388[_0x50de0a('0x23a2')][_0x50de0a('0xdf8')]-0x1)*_0x9ed388[_0x50de0a('0x23a2')][_0x50de0a('0x6f0')];if(_0x9ed388[_0x50de0a('0x213')]){if(_0x9ed388['currentUser'][_0x50de0a('0xecb')]===_0x50de0a('0x20c2')||_0x9ed388['userProfileSection'][_0x50de0a('0x170')])_0x9ed388[_0x50de0a('0x1883')]=_0x36596f[_0x9ed388['apiName']][_0x50de0a('0x1e6e')](_0x9ed388[_0x50de0a('0x23a2')],_0x5bfe11)[_0x50de0a('0xe53')];else{let _0x2b0742=[];_0x9ed388[_0x50de0a('0x1883')]=_0x36596f[_0x9ed388[_0x50de0a('0x213')]][_0x50de0a('0x1e6e')](_0x9ed388['query'])[_0x50de0a('0xe53')][_0x50de0a('0x683')](function(_0x28ad0d){const _0x11c497=_0x50de0a;return _0x2b0742=_0x28ad0d&&_0x28ad0d[_0x11c497('0xf5d')]?_0x28ad0d['rows']:[],_0x2b0742[_0x11c497('0x1564')]>0x0?_0x36596f[_0x11c497('0xcf7')][_0x11c497('0x1e6e')]({'sectionId':_0x9ed388['userProfileSection']['id'],'type':_0x9ed388[_0x11c497('0x213')]==='analyticDefaultReport'?_0x11c497('0xbbb'):_0x11c497('0x1a3c')})[_0x11c497('0xe53')][_0x11c497('0x683')](function(_0x42d530){const _0x31e2b2=_0x11c497,_0x826dbd=_0x42d530&&_0x42d530[_0x31e2b2('0xf5d')]?_0x42d530['rows']:[];if(_0x826dbd[_0x31e2b2('0x1564')]>0x0){const _0x1b2175=[];return _0x2b0742[_0x31e2b2('0x1299')](function(_0x4ad43c){const _0x35b423=_0x31e2b2,_0x29ad52=_0x2e3ca0()[_0x35b423('0x1c07')](_0x826dbd,[_0x35b423('0x832'),_0x4ad43c['id']]);if(_0x29ad52)_0x1b2175['push'](_0x4ad43c);}),_0x5bfe11({'count':_0x1b2175['length'],'rows':_0x1b2175});}else return _0x5bfe11(null);}):_0x5bfe11(null);});}}}function _0x292d7f(_0x5e652c,_0x25c4a2){const _0x411d59=_0x53eb2e;_0x1472ab[_0x411d59('0x1d4')]({'controller':_0x411d59('0x18bb'),'controllerAs':'vm','templateUrl':_0x25b8ce,'parent':angular[_0x411d59('0x1fcc')](_0x21f58c['body']),'targetEvent':_0x5e652c,'clickOutsideToClose':!![],'locals':{'report':_0x25c4a2,'reports':_0x9ed388['reports'][_0x411d59('0xf5d')],'apiName':_0x9ed388[_0x411d59('0x213')],'currentNode':_0x9ed388['currentNode'],'setting':null,'crudPermissions':_0x9ed388['crudPermissions']}});}function _0x3ad8e1(_0x11159c){const _0x482bd9=_0x53eb2e;if(_0x11159c[_0x482bd9('0x21dd')]['type']==='application/json'){const _0x5948de=new FileReader();_0x5948de['onload']=function(_0x423063){const _0x3b1f2f=_0x482bd9;console[_0x3b1f2f('0x1b2b')](_0x423063[_0x3b1f2f('0x568')]['result']);try{let _0x58f6b5=atob(_0x423063[_0x3b1f2f('0x568')][_0x3b1f2f('0x7c9')]['split'](',')[0x1]);_0x58f6b5=angular[_0x3b1f2f('0x1cb2')](_0x58f6b5),_0x36596f[_0x3b1f2f('0x197f')]['save']({'name':_0x58f6b5[_0x3b1f2f('0x60a')],'description':_0x58f6b5[_0x3b1f2f('0xd6b')],'table':_0x58f6b5[_0x3b1f2f('0x5c4')],'conditions':_0x58f6b5[_0x3b1f2f('0x27a5')],'joins':_0x58f6b5['joins'],'parent':_0x9ed388[_0x3b1f2f('0x121b')]['id']})[_0x3b1f2f('0xe53')][_0x3b1f2f('0x683')](function(_0x3069ad){const _0x50e8f3=_0x3b1f2f;_0x9ed388[_0x50e8f3('0x4c2')]['rows'][_0x50e8f3('0x1167')](_0x3069ad),_0x2192ac[_0x50e8f3('0x53')]({'title':_0x50e8f3('0x1e2'),'msg':_0x3069ad[_0x50e8f3('0x60a')]?_0x3069ad['name']+_0x50e8f3('0xf59'):''});const _0x3a73be=_0x2e3ca0()['map'](_0x58f6b5[_0x50e8f3('0x189a')],function(_0x37b7ee){const _0x553ec7=_0x50e8f3;return _0x2e3ca0()[_0x553ec7('0x618')]({},_0x37b7ee,{'CustomReportId':_0x3069ad['id']});});return _0x36596f[_0x50e8f3('0x2871')][_0x50e8f3('0x215b')](_0x3a73be)[_0x50e8f3('0xe53')];})['then'](function(){const _0x2d41a1=_0x3b1f2f;_0x2192ac['success']({'title':_0x2d41a1('0x1ecf'),'msg':'Fields\x20has\x20been\x20saved!'});})[_0x3b1f2f('0x130a')](function(_0x15f938){const _0x52b179=_0x3b1f2f;_0x2192ac[_0x52b179('0x52a')]({'title':_0x15f938[_0x52b179('0x13ee')]?_0x52b179('0x2168')+_0x15f938[_0x52b179('0x13ee')]+'\x20-\x20'+_0x15f938[_0x52b179('0x24a9')]:'SYSTEM:GETanalyticReport','msg':_0x15f938['data']?JSON[_0x52b179('0x258a')](_0x15f938[_0x52b179('0x5a5')]):_0x15f938[_0x52b179('0x1ff0')]()});});}catch(_0x1b21c8){console[_0x3b1f2f('0x52a')](_0x1b21c8),_0x2192ac[_0x3b1f2f('0x52a')]({'title':'Decode\x20File\x20Error','msg':_0x1b21c8[_0x3b1f2f('0x1ff0')]()});}},_0x5948de[_0x482bd9('0x23e1')](_0x11159c['file']);}else _0x2192ac['error']({'title':_0x482bd9('0x1456'),'msg':'Please\x20use\x20only\x20json\x20files'});}function _0x1e0606(_0x5d41a4){const _0x2ff9e7=_0x53eb2e;_0x9ed388[_0x2ff9e7('0x213')]&&_0x36596f[_0x9ed388['apiName']]['delete']({'id':_0x5d41a4['id']})[_0x2ff9e7('0xe53')]['then'](function(){const _0x576787=_0x2ff9e7;_0x2e3ca0()[_0x576787('0x3ec')](_0x9ed388['reports'][_0x576787('0xf5d')],{'id':_0x5d41a4['id']}),_0x9ed388['reports'][_0x576787('0x50d')]-=0x1,!_0x9ed388['reports']['rows'][_0x576787('0x1564')]&&_0x9ed388[_0x576787('0x2398')](),_0x2192ac[_0x576787('0x53')]({'title':'Report\x20deleted!','msg':_0x5d41a4[_0x576787('0x60a')]?_0x5d41a4[_0x576787('0x60a')]+_0x576787('0x194d'):''});})[_0x2ff9e7('0x130a')](function(_0x405685){const _0x54a60f=_0x2ff9e7;if(_0x405685[_0x54a60f('0x5a5')]&&_0x405685[_0x54a60f('0x5a5')][_0x54a60f('0x17f')]&&_0x405685[_0x54a60f('0x5a5')][_0x54a60f('0x17f')]['length']){_0x9ed388[_0x54a60f('0x17f')]=_0x405685[_0x54a60f('0x5a5')][_0x54a60f('0x17f')]||[{'message':_0x405685['toString'](),'type':'api.analyticreport.delete'}];for(let _0x16d52e=0x0;_0x16d52e<_0x405685['data'][_0x54a60f('0x17f')][_0x54a60f('0x1564')];_0x16d52e++){_0x2192ac[_0x54a60f('0x52a')]({'title':_0x405685[_0x54a60f('0x5a5')][_0x54a60f('0x17f')][_0x16d52e]['type'],'msg':_0x405685[_0x54a60f('0x5a5')][_0x54a60f('0x17f')][_0x16d52e]['message']});}}else _0x2192ac[_0x54a60f('0x52a')]({'title':_0x405685[_0x54a60f('0x13ee')]?_0x54a60f('0x2168')+_0x405685[_0x54a60f('0x13ee')]+_0x54a60f('0xbf6')+_0x405685[_0x54a60f('0x24a9')]:_0x54a60f('0xac5'),'msg':_0x405685[_0x54a60f('0x5a5')]?JSON['stringify'](_0x405685[_0x54a60f('0x5a5')][_0x54a60f('0x8c2')]):_0x405685[_0x54a60f('0x8c2')]||_0x405685[_0x54a60f('0x1ff0')]()});});}function _0x32815c(){const _0x94b832=_0x53eb2e,_0x508a5f=angular[_0x94b832('0x1a86')](_0x9ed388[_0x94b832('0x1e67')]);return _0x9ed388[_0x94b832('0x1e67')]=[],_0x508a5f;}function _0x1ca9af(_0x55d597){const _0x39d662=_0x53eb2e,_0x250dd9=_0x1472ab['confirm']()[_0x39d662('0xf28')](_0x39d662('0x19f5'))[_0x39d662('0x26e3')](_0x39d662('0xed5')+_0x9ed388[_0x39d662('0x1e67')][_0x39d662('0x1564')]+_0x39d662('0x93c')+_0x39d662('0x1ee7'))[_0x39d662('0x1040')]('delete\x20Reports')[_0x39d662('0xe42')](_0x55d597)['ok']('OK')[_0x39d662('0x19fb')]('CANCEL');_0x1472ab[_0x39d662('0x1d4')](_0x250dd9)['then'](function(){const _0x40cf89=_0x39d662;_0x9ed388[_0x40cf89('0x1e67')][_0x40cf89('0x1299')](function(_0x1fdc20){_0x1e0606(_0x1fdc20);}),_0x9ed388[_0x40cf89('0x1e67')]=[];});}function _0xf8a47(){const _0x5cf185=_0x53eb2e;_0x9ed388[_0x5cf185('0x1e67')]=[];}function _0x57eacc(){const _0x1dae1a=_0x53eb2e;_0x9ed388[_0x1dae1a('0x1e67')]=_0x9ed388['reports'][_0x1dae1a('0xf5d')];}function _0x220254(_0x36a918,_0x5143a4){const _0x30c6c3=_0x53eb2e;_0x9ed388[_0x30c6c3('0x1325')][_0x30c6c3('0x184b')](!![])[_0x30c6c3('0x1788')](),_0x9ed388[_0x30c6c3('0x1325')][_0x30c6c3('0x184b')](!![])['close_all'](),_0x9ed388[_0x30c6c3('0x121b')]=_0x5143a4['node'],_0x9ed388['currentNode'][_0x30c6c3('0xbf0')]=!![],_0x9ed388[_0x30c6c3('0x228d')]=_0x9ed388[_0x30c6c3('0x13f6')][_0x30c6c3('0x184b')](!![])[_0x30c6c3('0xfd5')](_0x9ed388[_0x30c6c3('0x121b')])[_0x30c6c3('0x1630')]('/\x20'),_0x9ed388[_0x30c6c3('0x213')]=_0x30c6c3('0x197f'),_0x9ed388['query'][_0x30c6c3('0x2361')]=_0x5143a4[_0x30c6c3('0x759')]['id'],_0x38e81c();}function _0x4bfc9a(_0x14397e,_0x29eb40){const _0xc66ce4=_0x53eb2e;_0x9ed388['treeCustomInstance']['jstree'](!![])[_0xc66ce4('0x1788')](),_0x9ed388['treeCustomInstance'][_0xc66ce4('0x184b')](!![])[_0xc66ce4('0x1def')](),_0x9ed388[_0xc66ce4('0x121b')]=_0x29eb40['node'],_0x9ed388[_0xc66ce4('0x121b')][_0xc66ce4('0xbf0')]=![],_0x9ed388[_0xc66ce4('0x228d')]=_0x9ed388['treeDefaultInstance']['jstree'](!![])[_0xc66ce4('0xfd5')](_0x9ed388['currentNode'])['join']('/\x20'),_0x9ed388[_0xc66ce4('0x213')]=_0xc66ce4('0x20ec'),_0x9ed388[_0xc66ce4('0x23a2')][_0xc66ce4('0x2361')]=_0x29eb40[_0xc66ce4('0x759')]['id'],_0x38e81c();}function _0x2f4a0d(_0x4fe752,_0x5a316e){const _0x1460a7=_0x53eb2e,_0x86aa8c=angular[_0x1460a7('0x1bf7')](_0x9ed388[_0x1460a7('0x13f6')]['jstree'](!![])[_0x1460a7('0xdd1')]('#'));_0x36596f[_0x1460a7('0x1aaf')][_0x1460a7('0x2480')]({'id':0x2,'tree':_0x86aa8c})[_0x1460a7('0xe53')][_0x1460a7('0x683')](function(){const _0x27a324=_0x1460a7;_0x4da5a7[_0x27a324('0xf5d')][0x1]&&(_0x4da5a7[_0x27a324('0xf5d')][0x1][_0x27a324('0x2eb')]=_0x86aa8c),_0x2192ac[_0x27a324('0x53')]({'title':'Node\x20Updated','msg':_0x5a316e[_0x27a324('0x759')][_0x27a324('0x1bcd')]?_0x5a316e[_0x27a324('0x759')]['text']+_0x27a324('0x96c'):_0x27a324('0x5a7')});})[_0x1460a7('0x130a')](function(_0x3174eb){const _0xed37d5=_0x1460a7;_0x2192ac[_0xed37d5('0x52a')]({'title':_0x3174eb[_0xed37d5('0x13ee')]?'API:'+_0x3174eb[_0xed37d5('0x13ee')]+'\x20-\x20'+_0x3174eb['statusText']:_0xed37d5('0x1894'),'msg':_0x3174eb[_0xed37d5('0x5a5')]?JSON['stringify'](_0x3174eb[_0xed37d5('0x5a5')]):_0x3174eb[_0xed37d5('0x1ff0')]()});});}function _0x4d571d(_0x3eabb7){const _0xe9b8f9=_0x53eb2e;return{'core':{'multiple':![],'animation':!![],'error':function(_0x2b2b38){console['error']('treeCtrl:\x20error\x20from\x20js\x20tree\x20-\x20'+angular['toJson'](_0x2b2b38));},'check_callback':!![],'worker':!![]},'version':0x1,'plugins':_0x3eabb7?[_0xe9b8f9('0x1a48'),_0xe9b8f9('0x24c2'),_0xe9b8f9('0x19a4'),_0xe9b8f9('0x2598'),'wholerow']:['search',_0xe9b8f9('0x2598'),_0xe9b8f9('0x12a7')],'contextmenu':{'items':function(_0x520854){const _0x516c13=_0xe9b8f9,_0x172d82={};return _0x9ed388['crudPermissions']['canEdit']&&_0x2e3ca0()[_0x516c13('0x196a')](_0x172d82,{'create':{'label':_0xb33a42['instant'](_0x516c13('0x16d5')),'action':function(){const _0x477d15=_0x516c13;_0x520854=_0x9ed388['treeCustomInstance']['jstree'](!![])[_0x477d15('0x553')](_0x520854),_0x9ed388[_0x477d15('0x13f6')][_0x477d15('0x184b')](!![])['edit'](_0x520854);}},'rename':{'_disabled':_0x520854[_0x516c13('0x2361')]==='#','label':_0xb33a42[_0x516c13('0x2728')]('ANALYTICS.RENAME'),'action':function(){const _0x4e11bd=_0x516c13;_0x9ed388[_0x4e11bd('0x13f6')][_0x4e11bd('0x184b')](!![])[_0x4e11bd('0x1319')](_0x520854);}}}),_0x9ed388['crudPermissions'][_0x516c13('0xed6')]&&_0x2e3ca0()[_0x516c13('0x196a')](_0x172d82,{'remove':{'_disabled':_0x520854[_0x516c13('0x2361')]==='#','label':_0xb33a42[_0x516c13('0x2728')]('ANALYTICS.REMOVE'),'action':function(){const _0xa91a58=_0x516c13,_0x238ea0=_0x1472ab[_0xa91a58('0x1c6f')]()[_0xa91a58('0xf28')](_0xa91a58('0x44b'))[_0xa91a58('0x26e3')](''+(_0x520854['text']?_0x520854[_0xa91a58('0x1bcd')]:'Node')+_0xa91a58('0x20f1')+_0xa91a58('0x225a'))[_0xa91a58('0x1040')]('delete\x20node')['ok']('OK')[_0xa91a58('0x19fb')](_0xa91a58('0x16b8'));_0x1472ab[_0xa91a58('0x1d4')](_0x238ea0)[_0xa91a58('0x683')](function(){const _0x588b46=_0xa91a58;let _0x580c67=_0x9ed388[_0x588b46('0x13f6')][_0x588b46('0x184b')](!![])['get_parent'](_0x520854);_0x580c67=_0x9ed388[_0x588b46('0x13f6')][_0x588b46('0x184b')](!![])['get_node'](_0x580c67),_0x9ed388['treeCustomInstance'][_0x588b46('0x184b')](!![])[_0x588b46('0x566')](_0x520854),_0x2d31a3([_0x520854['id']][_0x588b46('0x746')](_0x520854['children_d']||[])),_0x9ed388['treeCustomInstance'][_0x588b46('0x184b')](!![])[_0x588b46('0x377')](_0x580c67);});}}}),_0x172d82;}}};}function _0x2d31a3(_0x2fd558){const _0x16216d=_0x53eb2e;return _0x36596f[_0x16216d('0x197f')]['get']({'parent':_0x2fd558['join'](','),'fields':_0x16216d('0xa10')})[_0x16216d('0xe53')][_0x16216d('0x683')](function(_0x115c04){const _0x113dcc=_0x16216d;_0x115c04&&_0x115c04[_0x113dcc('0xf5d')]&&_0x115c04[_0x113dcc('0xf5d')][_0x113dcc('0x1299')](function(_0x56e319){_0x1e0606(_0x56e319);});})[_0x16216d('0x130a')](function(_0x589029){const _0x3837d3=_0x16216d;_0x2192ac[_0x3837d3('0x52a')]({'title':_0x589029[_0x3837d3('0x13ee')]?_0x3837d3('0x2168')+_0x589029[_0x3837d3('0x13ee')]+_0x3837d3('0xbf6')+_0x589029[_0x3837d3('0x24a9')]:'SYSTEM:DELETEreportsByParents','msg':_0x589029[_0x3837d3('0x5a5')]?JSON[_0x3837d3('0x258a')](_0x589029[_0x3837d3('0x5a5')]):_0x589029[_0x3837d3('0x1ff0')]()});});}function _0x50b237(_0x449bc4){return _0x449bc4?{'create_node':_0x2f4a0d,'rename_node':_0x2f4a0d,'move_node':_0x2f4a0d,'delete_node':_0x2f4a0d,'select_node':_0x220254}:{'select_node':_0x4bfc9a};}}const _0x4477ad=_0x2009f,_0x13a503=_0x180212['p']+_0x189033('0x852');_0x6ef561[_0x189033('0x14be')]=[_0x189033('0xb8d'),_0x189033('0x1e48'),'toasty',_0x189033('0xaaf'),_0x189033('0x56b'),_0x189033('0x213'),_0x189033('0x16ea'),_0x189033('0x228d')];function _0x6ef561(_0x8e44c3,_0x3a2cee,_0xff95fe,_0x3b93d6,_0xcf6e81,_0x108509,_0x57b045,_0x43ef56){const _0x3cede6=_0x189033,_0xa0b1e7=this;_0xa0b1e7[_0x3cede6('0x17f')]=[],_0xa0b1e7[_0x3cede6('0xaaf')]=angular[_0x3cede6('0x1a86')](_0x3b93d6),_0xa0b1e7['export']={},_0xa0b1e7[_0x3cede6('0x274')]=_0x1bcc65,_0xa0b1e7[_0x3cede6('0xf82')]=_0x28ac71,_0xa0b1e7[_0x3cede6('0x122b')]=_0x42b6d1,_0x42b6d1();function _0x42b6d1(){const _0x4d687f=_0x3cede6;_0xa0b1e7['export']={'id':_0xa0b1e7[_0x4d687f('0xaaf')]['id'],'name':_0xa0b1e7[_0x4d687f('0xaaf')]['name'],'startDate':new Date(_0x1aaf93()()[_0x4d687f('0x1627')](_0x4d687f('0x1efa'))),'endDate':new Date(_0x1aaf93()()[_0x4d687f('0x3b3')](_0x4d687f('0x1efa'))),'output':_0x4d687f('0x21a9'),'fullPath':_0x43ef56?_0x43ef56+'/'+_0xa0b1e7[_0x4d687f('0xaaf')]['name']:_0xa0b1e7[_0x4d687f('0xaaf')]['name']};}function _0x1bcc65(_0x95a1e0){const _0x226677=_0x3cede6;_0xa0b1e7[_0x226677('0x17f')]=[],_0xa0b1e7[_0x226677('0x1992')]=_0x2e3ca0()[_0x226677('0x196a')]({},_0xa0b1e7[_0x226677('0xf6d')],{'startDate':_0x1aaf93()(_0xa0b1e7['export'][_0x226677('0x1811')])[_0x226677('0x26dd')](_0x226677('0x865')),'endDate':_0x1aaf93()(_0xa0b1e7['export'][_0x226677('0x260d')])['format'](_0x226677('0x865'))}),_0xcf6e81[_0x108509][_0x226677('0x11a0')](_0xa0b1e7[_0x226677('0x1992')])[_0x226677('0xe53')][_0x226677('0x683')](function(_0x2b7fc0){const _0x348784=_0x226677;_0xa0b1e7[_0x348784('0xf6d')][_0x348784('0x2393')]==='web'?_0x3a2cee[_0x348784('0x1d4')]({'controller':'WebReportDialogController','controllerAs':'vm','templateUrl':_0x13a503,'parent':angular['element'](_0x57b045[_0x348784('0x18e5')]),'targetEvent':_0x95a1e0,'skipHide':!![],'locals':{'apiName':_0x108509,'exportDate':_0xa0b1e7['exportDate'],'results':_0x2b7fc0},'resolve':{'columns':[_0x348784('0x4b1'),function(_0xf29800){const _0x20ea2b=_0x348784,_0xae40b1={'fields':_0x20ea2b('0x220e'),'nolimit':!![]};return _0xae40b1[_0x108509===_0x20ea2b('0x197f')?_0x20ea2b('0x1b81'):_0x20ea2b('0x24a1')]=_0xa0b1e7['report']['id'],_0xf29800[_0x20ea2b('0xed7')](_0x20ea2b('0x229e'),_0xae40b1);}]}}):(_0xff95fe[_0x348784('0x53')]({'title':_0x348784('0xd08'),'msg':_0xa0b1e7[_0x348784('0xaaf')]['name']?_0xa0b1e7[_0x348784('0xaaf')][_0x348784('0x60a')]+_0x348784('0x4ee'):''}),_0x28ac71());})[_0x226677('0x130a')](function(_0x17927d){const _0x355d63=_0x226677;_0xff95fe['error']({'title':_0x17927d[_0x355d63('0x13ee')]?'API:'+_0x17927d[_0x355d63('0x13ee')]+_0x355d63('0xbf6')+_0x17927d[_0x355d63('0x24a9')]:_0x355d63('0x16df'),'msg':_0x17927d['data']?JSON[_0x355d63('0x258a')](_0x17927d[_0x355d63('0x5a5')]['message']):_0x17927d[_0x355d63('0x1ff0')]()});});}function _0x28ac71(){const _0x1eb54b=_0x3cede6;_0x3a2cee[_0x1eb54b('0x1715')]();}}const _0x243666=_0x6ef561;_0x2a46eb[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x1a7f'),_0x189033('0x546'),_0x189033('0x213'),'exportDate'];function _0x2a46eb(_0x36e5ef,_0x5b540a,_0x7babd6,_0x34f279,_0x55d0b7,_0x540323,_0x2efd03){const _0x46af12=_0x189033,_0x5df438=this;_0x5df438['errors']=[],_0x5df438[_0x46af12('0x1a7f')]=_0x34f279?_0x34f279[_0x46af12('0xf5d')]:[],_0x5df438[_0x46af12('0x546')]=_0x55d0b7||{'rows':[],'count':0x0},_0x5df438['query']={'limit':0xa,'page':0x1},_0x5df438[_0x46af12('0xf82')]=_0x15a239,_0x5df438[_0x46af12('0xa81')]=_0x17b4f8,_0x5df438['valueReplacer']=_0x8210ab;function _0x17b4f8(){const _0x2ff916=_0x46af12;_0x2efd03[_0x2ff916('0x1cc8')]=(_0x5df438[_0x2ff916('0x23a2')][_0x2ff916('0xdf8')]-0x1)*_0x5df438[_0x2ff916('0x23a2')][_0x2ff916('0x6f0')],_0x2efd03[_0x2ff916('0x6f0')]=_0x5df438[_0x2ff916('0x23a2')][_0x2ff916('0x6f0')],_0x5df438[_0x2ff916('0x1883')]=_0x7babd6[_0x540323]['run'](_0x2efd03,_0x51b1fe)['$promise'];}function _0x8210ab(_0x464bdd,_0x4e7d7b){const _0x27eff5=_0x46af12;return _0x1aaf93()(_0x4e7d7b,_0x27eff5('0x1b7e'),!![])[_0x27eff5('0x24f4')]()&&(_0x4e7d7b=_0x1aaf93()(_0x4e7d7b,'')[_0x27eff5('0x26dd')](_0x27eff5('0x865'))),_0x4e7d7b;}function _0x51b1fe(_0x366ca6){_0x5df438['results']=_0x366ca6||{'count':0x0,'rows':[]};}function _0x15a239(){const _0x49132d=_0x46af12;_0x36e5ef[_0x49132d('0x1715')]();}}const _0x1d0ce5=_0x2a46eb;_0x4a3245[_0x189033('0x14be')]=['$stateProvider'];function _0x4a3245(_0x6beac9){const _0x40341a=_0x189033;_0x6beac9[_0x40341a('0x2598')](_0x40341a('0x2721'),{'url':_0x40341a('0xb9'),'views':{'content@app':{'templateUrl':_0x159ee8,'controller':'ReportsController\x20as\x20vm'}},'resolve':{'treeReports':[_0x40341a('0x4b1'),function(_0x5dcdbd){const _0x5b6ffa=_0x40341a;return _0x5dcdbd[_0x5b6ffa('0xed7')](_0x5b6ffa('0x1fff'),{'fields':'id,tree','limit':0xa,'offset':0x0});}],'userProfile':[_0x40341a('0x4b1'),_0x40341a('0xba1'),function(_0x5c3ffd,_0x448740){const _0x2d4c89=_0x40341a;return _0x5c3ffd['resolve']('userProfile@get',{'fields':_0x2d4c89('0x16f'),'id':_0x448740[_0x2d4c89('0x20b2')]()[_0x2d4c89('0x2f')]});}],'userProfileSection':['apiResolver','Auth',function(_0x4a3552,_0x36773d){const _0x26db10=_0x40341a;return _0x4a3552[_0x26db10('0xed7')](_0x26db10('0x360'),{'fields':_0x26db10('0x1f47'),'userProfileId':_0x36773d[_0x26db10('0x20b2')]()[_0x26db10('0x2f')],'sectionId':0x4b3});}]},'authenticate':!![],'permissionId':0x4b3,'bodyClass':_0x40341a('0xa01')})[_0x40341a('0x2598')](_0x40341a('0x16ef'),{'url':_0x40341a('0x1560'),'views':{'content@app':{'templateUrl':_0x54574f,'controller':_0x40341a('0x19f1')}},'resolve':{'report':['apiResolver',_0x40341a('0x8ea'),'$q',_0x40341a('0x2411'),function(_0x3acd93,_0x4ddaa1,_0x372231,_0x2a9e07){const _0x55c7e3=_0x40341a;let _0x3a8fff;return _0x3acd93[_0x55c7e3('0xed7')](_0x55c7e3('0x2735'),{'fields':_0x55c7e3('0xb54'),'id':_0x4ddaa1['id']})['then'](function(_0x40436b){const _0x3a1444=_0x55c7e3,_0xe4e3d8=[];_0x3a8fff=_0x40436b;if(_0x3a8fff['joins'])try{_0x3a8fff[_0x3a1444('0x21b0')]=JSON[_0x3a1444('0x1f34')](_0x3a8fff[_0x3a1444('0x21b0')]);for(let _0x44c8e6=0x0;_0x44c8e6<_0x3a8fff[_0x3a1444('0x21b0')][_0x3a1444('0x1564')];_0x44c8e6+=0x1){_0xe4e3d8['push'](_0x2a9e07[_0x3a1444('0x24f5')](_0x3a8fff[_0x3a1444('0x21b0')][_0x44c8e6]['foreignTable']));}}catch(_0x900a98){console[_0x3a1444('0x1b2b')](_0x900a98);}return _0x372231['all'](_0xe4e3d8);})[_0x55c7e3('0x683')](function(_0x33fee9){const _0x3d0fba=_0x55c7e3;for(let _0x52beac=0x0;_0x52beac<_0x33fee9[_0x3d0fba('0x1564')];_0x52beac+=0x1){_0x3a8fff[_0x3d0fba('0x21b0')][_0x52beac][_0x3d0fba('0x1f3b')]=_0x2e3ca0()[_0x3d0fba('0x2829')](_0x2e3ca0()[_0x3d0fba('0x55e')](_0x33fee9[_0x52beac]),[_0x3d0fba('0xe53'),_0x3d0fba('0x1980')]);}return _0x3a8fff;});}],'userProfileSection':[_0x40341a('0x4b1'),_0x40341a('0xba1'),function(_0x1fec08,_0x23cc3b){const _0x3e32f6=_0x40341a;return _0x1fec08['resolve'](_0x3e32f6('0x360'),{'fields':_0x3e32f6('0x1f47'),'userProfileId':_0x23cc3b[_0x3e32f6('0x20b2')]()[_0x3e32f6('0x2f')],'sectionId':0x4b3});}]},'authenticate':!![],'permissionId':0x4b3,'bodyClass':_0x40341a('0xa01')});}angular['module'](_0x189033('0x2721'),[_0x189033('0xd00')])[_0x189033('0x272d')](_0x4a3245)[_0x189033('0x1da3')](_0x189033('0x19d6'),_0x529dbc)[_0x189033('0x1da3')](_0x189033('0x18bb'),_0x132365)['controller'](_0x189033('0x1450'),_0x2a8ffa)[_0x189033('0x1f97')]('describeTable',_0x4f676b)['controller'](_0x189033('0x1628'),_0x4db28a)['controller'](_0x189033('0x24c3'),_0x58df81)['factory'](_0x189033('0x2495'),_0xf49d7c)['controller']('ReportController',_0x164082)[_0x189033('0x1da3')](_0x189033('0x9b0'),_0x18b9d0)[_0x189033('0x1da3')](_0x189033('0x1f5d'),_0x4477ad)['controller'](_0x189033('0xe44'),_0x243666)[_0x189033('0x1da3')](_0x189033('0x33d'),_0x1d0ce5),_0x21ef7b[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state','$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x16eb'),'extractedReport',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x21ef7b(_0x57633c,_0x20903d,_0x59c740,_0x931f84,_0x4d99e1,_0x5ac6ba,_0xc4ef9,_0x4d6e54,_0x5dc932,_0x56b4b0,_0x2d7d18,_0x4adddf,_0x5211fa,_0x5d88fb){const _0x2d6e=_0x189033,_0x21e066=this;_0x21e066['currentUser']=_0x2d7d18[_0x2d6e('0x20b2')](),_0x21e066['errors']=[],_0x21e066['setting']=_0x5211fa,_0x21e066[_0x2d6e('0xace')]=_0x4adddf,_0x21e066[_0x2d6e('0x1134')]=_0x5d88fb,_0x21e066['hasModulePermissions']={},_0x21e066['passwordPattern']=_0x21e066[_0x2d6e('0x260a')]&&_0x21e066['setting'][_0x2d6e('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x21e066['title']=_0x2d6e('0x231'),_0x21e066['extractedReport']=angular[_0x2d6e('0x1a86')](_0x5dc932),_0x21e066[_0x2d6e('0x16eb')]=_0x4d6e54,_0x21e066[_0x2d6e('0x3be')]=![];!_0x21e066['extractedReport']&&(_0x21e066[_0x2d6e('0x2699')]={},_0x21e066[_0x2d6e('0xf28')]='ANALYTICS.NEW_EXTRACTEDREPORT',_0x21e066['newExtractedReport']=!![]);_0x21e066[_0x2d6e('0x6a4')]=_0x4db5a1,_0x21e066[_0x2d6e('0x650')]=_0x4d37f5,_0x21e066['deleteExtractedReport']=_0x26e692,_0x21e066[_0x2d6e('0x16b3')]=_0x28cb3c,_0x21e066['closeDialog']=_0x2fd834;function _0x4db5a1(){const _0x48bde9=_0x2d6e;_0x21e066[_0x48bde9('0x17f')]=[],_0x56b4b0[_0x48bde9('0x1911')][_0x48bde9('0xb0a')](_0x21e066[_0x48bde9('0x2699')])[_0x48bde9('0xe53')][_0x48bde9('0x683')](function(_0x3b5561){const _0x2d4813=_0x48bde9;_0x21e066['extractedReports'][_0x2d4813('0x1167')](_0x3b5561[_0x2d4813('0x24e1')]()),_0xc4ef9['success']({'title':_0x2d4813('0x10b4'),'msg':_0x21e066['extractedReport']['name']?_0x21e066['extractedReport'][_0x2d4813('0x60a')]+_0x2d4813('0x14b5'):''}),_0x2fd834(_0x3b5561);})[_0x48bde9('0x130a')](function(_0x42d432){const _0x29272b=_0x48bde9;if(_0x42d432['data']&&_0x42d432['data'][_0x29272b('0x17f')]&&_0x42d432[_0x29272b('0x5a5')][_0x29272b('0x17f')]['length']){_0x21e066[_0x29272b('0x17f')]=_0x42d432['data'][_0x29272b('0x17f')]||[{'message':_0x42d432[_0x29272b('0x1ff0')](),'type':_0x29272b('0x368')}];for(let _0x18522f=0x0;_0x18522f<_0x42d432['data'][_0x29272b('0x17f')][_0x29272b('0x1564')];_0x18522f+=0x1){_0xc4ef9[_0x29272b('0x52a')]({'title':_0x42d432[_0x29272b('0x5a5')][_0x29272b('0x17f')][_0x18522f][_0x29272b('0xcf0')],'msg':_0x42d432['data'][_0x29272b('0x17f')][_0x18522f][_0x29272b('0x8c2')]});}}else _0xc4ef9[_0x29272b('0x52a')]({'title':_0x42d432['status']?_0x29272b('0x2168')+_0x42d432['status']+'\x20-\x20'+_0x42d432['statusText']:_0x29272b('0x368'),'msg':_0x42d432[_0x29272b('0x5a5')]?JSON['stringify'](_0x42d432[_0x29272b('0x5a5')]['message']):_0x42d432['toString']()});});}function _0x4d37f5(){const _0x55216b=_0x2d6e;_0x21e066[_0x55216b('0x17f')]=[],_0x56b4b0[_0x55216b('0x1911')][_0x55216b('0x2480')]({'id':_0x21e066['extractedReport']['id']},_0x21e066[_0x55216b('0x2699')])[_0x55216b('0xe53')][_0x55216b('0x683')](function(_0x16c69e){const _0x386681=_0x55216b,_0x2dacc5=_0x2e3ca0()[_0x386681('0x1c07')](_0x21e066[_0x386681('0x16eb')],{'id':_0x16c69e['id']});_0x2dacc5&&_0x2e3ca0()[_0x386681('0xf22')](_0x2dacc5,_0x2e3ca0()['pick'](_0x16c69e['toJSON'](),_0x2e3ca0()[_0x386681('0x55e')](_0x2dacc5))),_0xc4ef9[_0x386681('0x53')]({'title':_0x386681('0x782'),'msg':_0x21e066[_0x386681('0x2699')]['name']?_0x21e066[_0x386681('0x2699')][_0x386681('0x60a')]+_0x386681('0xf59'):''}),_0x2fd834(_0x16c69e);})[_0x55216b('0x130a')](function(_0x19c9c3){const _0x3f4bff=_0x55216b;if(_0x19c9c3[_0x3f4bff('0x5a5')]&&_0x19c9c3[_0x3f4bff('0x5a5')][_0x3f4bff('0x17f')]&&_0x19c9c3['data'][_0x3f4bff('0x17f')][_0x3f4bff('0x1564')]){_0x21e066['errors']=_0x19c9c3[_0x3f4bff('0x5a5')][_0x3f4bff('0x17f')]||[{'message':_0x19c9c3[_0x3f4bff('0x1ff0')](),'type':_0x3f4bff('0x449')}];for(let _0x55f51b=0x0;_0x55f51b<_0x19c9c3[_0x3f4bff('0x5a5')][_0x3f4bff('0x17f')][_0x3f4bff('0x1564')];_0x55f51b++){_0xc4ef9['error']({'title':_0x19c9c3[_0x3f4bff('0x5a5')][_0x3f4bff('0x17f')][_0x55f51b]['type'],'msg':_0x19c9c3['data'][_0x3f4bff('0x17f')][_0x55f51b][_0x3f4bff('0x8c2')]});}}else _0xc4ef9[_0x3f4bff('0x52a')]({'title':_0x19c9c3['status']?'API:'+_0x19c9c3['status']+_0x3f4bff('0xbf6')+_0x19c9c3['statusText']:_0x3f4bff('0x449'),'msg':_0x19c9c3[_0x3f4bff('0x5a5')]?JSON['stringify'](_0x19c9c3['data'][_0x3f4bff('0x8c2')]):_0x19c9c3[_0x3f4bff('0x1ff0')]()});});}function _0x26e692(_0x739f55){const _0xc072e1=_0x2d6e;_0x21e066['errors']=[];const _0x2d7e10=_0x931f84['confirm']()[_0xc072e1('0xf28')](_0xc072e1('0x4d'))[_0xc072e1('0xa6a')](_0xc072e1('0x12b5'))[_0xc072e1('0x1040')]('Delete\x20ExtractedReport')['ok']('Delete')[_0xc072e1('0x19fb')]('Cancel')[_0xc072e1('0xe42')](_0x739f55);_0x931f84[_0xc072e1('0x1d4')](_0x2d7e10)[_0xc072e1('0x683')](function(){const _0x357a2b=_0xc072e1;_0x56b4b0['analyticExtractedReport'][_0x357a2b('0xd7e')]({'id':_0x21e066[_0x357a2b('0x2699')]['id']})[_0x357a2b('0xe53')][_0x357a2b('0x683')](function(){const _0x5c5b3a=_0x357a2b;_0x2e3ca0()['remove'](_0x21e066[_0x5c5b3a('0x16eb')],{'id':_0x21e066[_0x5c5b3a('0x2699')]['id']}),_0xc4ef9[_0x5c5b3a('0x53')]({'title':_0x5c5b3a('0x1cc5'),'msg':(_0x21e066[_0x5c5b3a('0x2699')]['name']||_0x5c5b3a('0x2699'))+'\x20has\x20been\x20deleted!'}),_0x2fd834(_0x21e066['extractedReport']);})[_0x357a2b('0x130a')](function(_0x5f03ca){const _0x520ea6=_0x357a2b;if(_0x5f03ca[_0x520ea6('0x5a5')]&&_0x5f03ca[_0x520ea6('0x5a5')][_0x520ea6('0x17f')]&&_0x5f03ca['data'][_0x520ea6('0x17f')][_0x520ea6('0x1564')]){_0x21e066[_0x520ea6('0x17f')]=_0x5f03ca[_0x520ea6('0x5a5')]['errors']||[{'message':_0x5f03ca[_0x520ea6('0x1ff0')](),'type':_0x520ea6('0xc44')}];for(let _0x18ec06=0x0;_0x18ec06<_0x5f03ca['data'][_0x520ea6('0x17f')][_0x520ea6('0x1564')];_0x18ec06++){_0xc4ef9[_0x520ea6('0x52a')]({'title':_0x5f03ca['data'][_0x520ea6('0x17f')][_0x18ec06][_0x520ea6('0xcf0')],'msg':_0x5f03ca[_0x520ea6('0x5a5')][_0x520ea6('0x17f')][_0x18ec06][_0x520ea6('0x8c2')]});}}else _0xc4ef9['error']({'title':_0x5f03ca[_0x520ea6('0x13ee')]?_0x520ea6('0x2168')+_0x5f03ca['status']+_0x520ea6('0xbf6')+_0x5f03ca[_0x520ea6('0x24a9')]:_0x520ea6('0xc44'),'msg':_0x5f03ca[_0x520ea6('0x5a5')]?JSON[_0x520ea6('0x258a')](_0x5f03ca['data'][_0x520ea6('0x8c2')]):_0x5f03ca[_0x520ea6('0x8c2')]||_0x5f03ca[_0x520ea6('0x1ff0')]()});});},function(){});}function _0x28cb3c(_0x188951){return _0x188951===null?undefined:new Date(_0x188951);}function _0x2fd834(_0x52da49){const _0x4cd902=_0x2d6e;_0x931f84[_0x4cd902('0x1715')](_0x52da49);}}const _0x5b9944=_0x21ef7b,_0x16afe7=_0x180212['p']+'src/js/modules/main/apps/analytics/views/extractedReports/create/dialog.html/dialog.html';_0x18485f[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0x16eb'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),'msUtils','toasty',_0x189033('0xba1'),'license',_0x189033('0x260a')];function _0x18485f(_0x25e243,_0x6fade6,_0x4b4826,_0x17e644,_0x835c01,_0xc59c0a,_0x121a4d,_0x5ee207,_0x1079ac,_0x569695,_0x1b5e7b,_0x28812d,_0x5c0c03,_0x32072a,_0x57c1e3,_0x149ca5,_0x49dade){const _0x3a7f59=_0x189033,_0x5436c4=this;_0x5436c4[_0x3a7f59('0xace')]=_0x149ca5,_0x5436c4[_0x3a7f59('0x260a')]=_0x49dade,_0x5436c4[_0x3a7f59('0x11ed')]=_0x57c1e3[_0x3a7f59('0x20b2')](),_0x5436c4[_0x3a7f59('0x16eb')]=_0x1079ac||{'count':0x0,'rows':[]},_0x5436c4[_0x3a7f59('0x2a')]=_0x569695,_0x5436c4[_0x3a7f59('0x22df')]=_0x1b5e7b&&_0x1b5e7b[_0x3a7f59('0x50d')]==0x1?_0x1b5e7b[_0x3a7f59('0xf5d')][0x0]:null,_0x5436c4[_0x3a7f59('0x1134')]=_0x57c1e3[_0x3a7f59('0x142a')](_0x5436c4[_0x3a7f59('0x22df')]?_0x5436c4['userProfileSection'][_0x3a7f59('0x1134')]:null),_0x5436c4[_0x3a7f59('0x5c4')]=_0x3a7f59('0x16eb'),_0x5436c4['listOrder']='',_0x5436c4[_0x3a7f59('0x1ce2')]=null,_0x5436c4[_0x3a7f59('0x1d90')]=[],_0x5436c4[_0x3a7f59('0x23a2')]={'fields':_0x3a7f59('0x11e6'),'sort':'-updatedAt','limit':0xa,'page':0x1},_0x5436c4['editdialog']=_0x57f1db,_0x5436c4[_0x3a7f59('0x29d')]=_0x4b7874,_0x5436c4['deleteconfirm']=_0x453069,_0x5436c4['success']=_0x125c1b,_0x5436c4[_0x3a7f59('0x243d')]=_0x15b546,_0x5436c4[_0x3a7f59('0x242')]=_0x6618e9,_0x5436c4[_0x3a7f59('0x1c1c')]=_0x3211df,_0x5436c4[_0x3a7f59('0x134a')]=_0x1c0389,_0x5436c4['deleteSelectedExtractedReports']=_0x518af2,_0x5436c4[_0x3a7f59('0x1f8e')]=_0x5399ce,_0x5436c4[_0x3a7f59('0x1709')]=_0x45f462;function _0x57f1db(_0x56543b,_0x45e979){const _0x9feacc=_0x3a7f59;_0x835c01[_0x9feacc('0x1d4')]({'controller':'CreateOrEditExtractedReportDialogController','controllerAs':'vm','templateUrl':_0x16afe7,'parent':angular['element'](_0xc59c0a[_0x9feacc('0x18e5')]),'targetEvent':_0x45e979,'clickOutsideToClose':!![],'locals':{'extractedReport':_0x56543b,'extractedReports':_0x5436c4[_0x9feacc('0x16eb')][_0x9feacc('0xf5d')],'license':_0x5436c4[_0x9feacc('0xace')],'setting':null,'crudPermissions':_0x5436c4[_0x9feacc('0x1134')]}});}function _0x4b7874(_0x35229e){const _0x1a1a02=_0x3a7f59;return _0x28812d[_0x1a1a02('0x1911')][_0x1a1a02('0x18e8')]({'id':_0x35229e['id']})[_0x1a1a02('0xe53')][_0x1a1a02('0x683')](function(_0x2894c6){const _0x408f86=_0x1a1a02,_0x47bae8=[_0x2894c6['buffer']];let _0x59d47b=_0x408f86('0x18e8');const _0x2447f0=new Blob(_0x47bae8,{'type':_0x2894c6[_0x408f86('0xcf0')]});_0x59d47b=_0x35229e[_0x408f86('0xe16')];const _0x364f06=window[_0x408f86('0x12e1')][_0x408f86('0x1ffa')]('a');_0x364f06[_0x408f86('0x130f')](_0x408f86('0x2767'),URL[_0x408f86('0x2820')](_0x2447f0)),_0x364f06[_0x408f86('0x130f')]('download',_0x59d47b),document[_0x408f86('0x18e5')][_0x408f86('0x1e43')](_0x364f06),_0x364f06[_0x408f86('0x1d42')]();})[_0x1a1a02('0x130a')](function(_0x581753){const _0x5e4375=_0x1a1a02;if(_0x581753['data']&&_0x581753[_0x5e4375('0x5a5')][_0x5e4375('0x17f')]&&_0x581753[_0x5e4375('0x5a5')]['errors'][_0x5e4375('0x1564')])for(let _0x2d446e=0x0;_0x2d446e<_0x581753['data']['errors'][_0x5e4375('0x1564')];_0x2d446e++){_0x32072a[_0x5e4375('0x52a')]({'title':_0x581753[_0x5e4375('0x5a5')][_0x5e4375('0x17f')][_0x2d446e][_0x5e4375('0xcf0')],'msg':_0x581753[_0x5e4375('0x5a5')][_0x5e4375('0x17f')][_0x2d446e][_0x5e4375('0x8c2')]});}else _0x32072a[_0x5e4375('0x52a')]({'title':_0x581753[_0x5e4375('0x13ee')]?'API:'+_0x581753[_0x5e4375('0x13ee')]+_0x5e4375('0xbf6')+_0x581753[_0x5e4375('0x24a9')]:_0x5e4375('0x368'),'msg':_0x581753[_0x5e4375('0x5a5')]?JSON[_0x5e4375('0x258a')](_0x581753[_0x5e4375('0x5a5')]['message']):_0x581753[_0x5e4375('0x1ff0')]()});});}function _0x453069(_0x27dc17,_0x1606b0){const _0x5d3661=_0x3a7f59,_0xecb8e8=_0x835c01[_0x5d3661('0x1c6f')]()['title'](_0x5d3661('0x1b01')+_0x2e3ca0()[_0x5d3661('0x1e03')](_0x5d3661('0x2699'))+'?')[_0x5d3661('0x26e3')](_0x5d3661('0xed5')+(_0x27dc17[_0x5d3661('0x60a')]||_0x5d3661('0x2699'))+_0x5d3661('0x20f1')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x5d3661('0x241f'))[_0x5d3661('0xe42')](_0x1606b0)['ok']('OK')['cancel'](_0x5d3661('0x16b8'));_0x835c01[_0x5d3661('0x1d4')](_0xecb8e8)['then'](function(){_0x3211df(_0x27dc17);},function(){const _0x1a0252=_0x5d3661;console[_0x1a0252('0x1b2b')](_0x1a0252('0x16b8'));});}let _0x39d92e=!![],_0x25faeb=0x1;_0x25e243[_0x3a7f59('0x186d')](_0x3a7f59('0x1e1d'),function(_0xfd8f48,_0x49421a){const _0x5f3f45=_0x3a7f59;_0x39d92e?_0x121a4d(function(){_0x39d92e=![];}):(!_0x49421a&&(_0x25faeb=_0x5436c4['query'][_0x5f3f45('0xdf8')]),_0xfd8f48!==_0x49421a&&(_0x5436c4[_0x5f3f45('0x23a2')][_0x5f3f45('0xdf8')]=0x1),!_0xfd8f48&&(_0x5436c4[_0x5f3f45('0x23a2')][_0x5f3f45('0xdf8')]=_0x25faeb),_0x5436c4[_0x5f3f45('0x243d')]());});function _0x125c1b(_0x3fffd8){_0x5436c4['extractedReports']=_0x3fffd8||{'count':0x0,'rows':[]};}function _0x15b546(){const _0xeed985=_0x3a7f59;_0x5436c4['query']['offset']=(_0x5436c4[_0xeed985('0x23a2')][_0xeed985('0xdf8')]-0x1)*_0x5436c4['query'][_0xeed985('0x6f0')],_0x57c1e3['hasRole'](_0xeed985('0x20c2'))?_0x5436c4[_0xeed985('0x1883')]=_0x28812d['analyticExtractedReport'][_0xeed985('0x1e6e')](_0x5436c4[_0xeed985('0x23a2')],_0x125c1b)[_0xeed985('0xe53')]:(_0x5436c4[_0xeed985('0x23a2')]['id']=_0x5436c4[_0xeed985('0x2a')]['id'],_0x5436c4['query'][_0xeed985('0x1aa')]=_0xeed985('0x14ec'),_0x5436c4[_0xeed985('0x1883')]=_0x28812d[_0xeed985('0x2a')][_0xeed985('0x241d')](_0x5436c4[_0xeed985('0x23a2')],_0x125c1b)['$promise']);}function _0x6618e9(_0x2aa208,_0x1105c9){const _0x6131e5=_0x3a7f59;_0x835c01[_0x6131e5('0x1d4')]({'controller':_0x6131e5('0x23a1'),'controllerAs':'vm','templateUrl':_0x16afe7,'parent':angular['element'](_0xc59c0a[_0x6131e5('0x18e5')]),'targetEvent':_0x2aa208,'clickOutsideToClose':!![],'locals':{'extractedReport':_0x1105c9,'extractedReports':_0x5436c4['extractedReports'][_0x6131e5('0xf5d')],'license':_0x5436c4[_0x6131e5('0xace')],'setting':_0x5436c4[_0x6131e5('0x260a')],'crudPermissions':_0x5436c4['crudPermissions']}});}function _0x3211df(_0x42a1bd){const _0x3fed71=_0x3a7f59;_0x28812d['analyticExtractedReport'][_0x3fed71('0xd7e')]({'id':_0x42a1bd['id']})['$promise'][_0x3fed71('0x683')](function(){const _0x4acf94=_0x3fed71;_0x2e3ca0()[_0x4acf94('0x3ec')](_0x5436c4[_0x4acf94('0x16eb')][_0x4acf94('0xf5d')],{'id':_0x42a1bd['id']}),_0x5436c4[_0x4acf94('0x16eb')][_0x4acf94('0x50d')]-=0x1,!_0x5436c4[_0x4acf94('0x16eb')][_0x4acf94('0xf5d')]['length']&&_0x5436c4[_0x4acf94('0x243d')](),_0x32072a[_0x4acf94('0x53')]({'title':_0x2e3ca0()[_0x4acf94('0x1e03')]('ExtractedReport')+'\x20deleted!','msg':_0x42a1bd['name']?_0x42a1bd[_0x4acf94('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0x3fed71('0x130a')](function(_0x100306){const _0x56083a=_0x3fed71;if(_0x100306[_0x56083a('0x5a5')]&&_0x100306['data'][_0x56083a('0x17f')]&&_0x100306[_0x56083a('0x5a5')][_0x56083a('0x17f')]['length']){_0x5436c4['errors']=_0x100306['data'][_0x56083a('0x17f')]||[{'message':_0x100306[_0x56083a('0x1ff0')](),'type':_0x56083a('0x1e3b')}];for(let _0x23d18a=0x0;_0x23d18a<_0x100306[_0x56083a('0x5a5')][_0x56083a('0x17f')][_0x56083a('0x1564')];_0x23d18a++){_0x32072a[_0x56083a('0x52a')]({'title':_0x100306[_0x56083a('0x5a5')]['errors'][_0x23d18a][_0x56083a('0xcf0')],'msg':_0x100306[_0x56083a('0x5a5')]['errors'][_0x23d18a][_0x56083a('0x8c2')]});}}else _0x32072a[_0x56083a('0x52a')]({'title':_0x100306[_0x56083a('0x13ee')]?'API:'+_0x100306['status']+_0x56083a('0xbf6')+_0x100306[_0x56083a('0x24a9')]:_0x56083a('0x1e3b'),'msg':_0x100306[_0x56083a('0x5a5')]?JSON[_0x56083a('0x258a')](_0x100306[_0x56083a('0x5a5')][_0x56083a('0x8c2')]):_0x100306[_0x56083a('0x8c2')]||_0x100306[_0x56083a('0x1ff0')]()});});}function _0x1c0389(){const _0x3b3d5a=_0x3a7f59,_0x50fe6f=angular[_0x3b3d5a('0x1a86')](_0x5436c4[_0x3b3d5a('0x1d90')]);return _0x5436c4[_0x3b3d5a('0x1d90')]=[],_0x50fe6f;}function _0x518af2(_0x51e6da){const _0x36f433=_0x3a7f59,_0x5dd79c=_0x835c01[_0x36f433('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20extractedReports?')[_0x36f433('0x26e3')](_0x36f433('0xed5')+_0x5436c4['selectedExtractedReports'][_0x36f433('0x1564')]+_0x36f433('0x93c')+'\x20will\x20be\x20deleted.')[_0x36f433('0x1040')]('delete\x20ExtractedReports')[_0x36f433('0xe42')](_0x51e6da)['ok']('OK')[_0x36f433('0x19fb')](_0x36f433('0x16b8'));_0x835c01['show'](_0x5dd79c)['then'](function(){const _0x233b34=_0x36f433;_0x5436c4[_0x233b34('0x1d90')][_0x233b34('0x1299')](function(_0x3fb8d1){_0x3211df(_0x3fb8d1);}),_0x5436c4[_0x233b34('0x1d90')]=[];});}function _0x5399ce(){_0x5436c4['selectedExtractedReports']=[];}function _0x45f462(){const _0xdaac71=_0x3a7f59;_0x5436c4[_0xdaac71('0x1d90')]=_0x5436c4[_0xdaac71('0x16eb')][_0xdaac71('0xf5d')];}}const _0x4eaf60=_0x18485f;_0x3dafc8[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x12d'),_0x189033('0x248f'),'api',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x3dafc8(_0x2344c2,_0x47cd76,_0x2e95c7,_0x4c83f3,_0x5ba61b,_0x2c4ca7,_0x43ed43,_0x31e602,_0x37e8bf,_0x229b51,_0x172ce2,_0x37addd,_0x534116,_0x382fd6){const _0x7847d7=_0x189033,_0xc3e8a3=this;_0xc3e8a3['currentUser']=_0x172ce2[_0x7847d7('0x20b2')](),_0xc3e8a3['errors']=[],_0xc3e8a3[_0x7847d7('0x260a')]=_0x534116,_0xc3e8a3[_0x7847d7('0xace')]=_0x37addd,_0xc3e8a3[_0x7847d7('0x1134')]=_0x382fd6,_0xc3e8a3[_0x7847d7('0x258d')]={},_0xc3e8a3['passwordPattern']=_0xc3e8a3[_0x7847d7('0x260a')]&&_0xc3e8a3[_0x7847d7('0x260a')][_0x7847d7('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xc3e8a3[_0x7847d7('0xf28')]='ANALYTICS.EDIT_METRIC',_0xc3e8a3[_0x7847d7('0x248f')]=angular[_0x7847d7('0x1a86')](_0x37e8bf),_0xc3e8a3[_0x7847d7('0x12d')]=_0x31e602,_0xc3e8a3[_0x7847d7('0x632')]=![];!_0xc3e8a3['metric']&&(_0xc3e8a3[_0x7847d7('0x248f')]={'table':_0x7847d7('0x254c')},_0xc3e8a3[_0x7847d7('0xf28')]=_0x7847d7('0x10e9'),_0xc3e8a3[_0x7847d7('0x632')]=!![]);_0xc3e8a3[_0x7847d7('0x145')]=_0x6066e2,_0xc3e8a3[_0x7847d7('0xbe')]=_0xf82356,_0xc3e8a3[_0x7847d7('0x30b')]=_0x2c6467,_0xc3e8a3[_0x7847d7('0x16b3')]=_0x2f5110,_0xc3e8a3[_0x7847d7('0xf82')]=_0x352926;function _0x6066e2(){const _0x2ae993=_0x7847d7;_0xc3e8a3['errors']=[],_0x229b51['analyticMetric']['save'](_0xc3e8a3[_0x2ae993('0x248f')])[_0x2ae993('0xe53')][_0x2ae993('0x683')](function(_0x1a21d4){const _0x5acaf0=_0x2ae993;_0xc3e8a3[_0x5acaf0('0x12d')][_0x5acaf0('0x1167')](_0x1a21d4['toJSON']()),_0x43ed43[_0x5acaf0('0x53')]({'title':'Metric\x20properly\x20created','msg':_0xc3e8a3[_0x5acaf0('0x248f')][_0x5acaf0('0x60a')]?_0xc3e8a3['metric'][_0x5acaf0('0x60a')]+_0x5acaf0('0x14b5'):''}),_0x352926(_0x1a21d4);})[_0x2ae993('0x130a')](function(_0x214bd9){const _0x55959d=_0x2ae993;if(_0x214bd9[_0x55959d('0x5a5')]&&_0x214bd9[_0x55959d('0x5a5')]['errors']&&_0x214bd9[_0x55959d('0x5a5')][_0x55959d('0x17f')][_0x55959d('0x1564')]){_0xc3e8a3['errors']=_0x214bd9[_0x55959d('0x5a5')]['errors']||[{'message':_0x214bd9['toString'](),'type':_0x55959d('0x1e11')}];for(let _0x415f50=0x0;_0x415f50<_0x214bd9[_0x55959d('0x5a5')]['errors']['length'];_0x415f50+=0x1){_0x43ed43[_0x55959d('0x52a')]({'title':_0x214bd9[_0x55959d('0x5a5')][_0x55959d('0x17f')][_0x415f50][_0x55959d('0xcf0')],'msg':_0x214bd9[_0x55959d('0x5a5')][_0x55959d('0x17f')][_0x415f50]['message']});}}else _0x43ed43[_0x55959d('0x52a')]({'title':_0x214bd9['status']?'API:'+_0x214bd9[_0x55959d('0x13ee')]+_0x55959d('0xbf6')+_0x214bd9[_0x55959d('0x24a9')]:_0x55959d('0x1e11'),'msg':_0x214bd9[_0x55959d('0x5a5')]?JSON[_0x55959d('0x258a')](_0x214bd9[_0x55959d('0x5a5')][_0x55959d('0x8c2')]):_0x214bd9[_0x55959d('0x1ff0')]()});});}function _0xf82356(){const _0x460395=_0x7847d7;_0xc3e8a3[_0x460395('0x17f')]=[],_0x229b51[_0x460395('0x1c97')][_0x460395('0x2480')]({'id':_0xc3e8a3['metric']['id']},_0xc3e8a3[_0x460395('0x248f')])[_0x460395('0xe53')][_0x460395('0x683')](function(_0x5dbd64){const _0x21fd11=_0x460395,_0x3b3b9a=_0x2e3ca0()[_0x21fd11('0x1c07')](_0xc3e8a3[_0x21fd11('0x12d')],{'id':_0x5dbd64['id']});_0x3b3b9a&&_0x2e3ca0()[_0x21fd11('0xf22')](_0x3b3b9a,_0x2e3ca0()[_0x21fd11('0x24d0')](_0x5dbd64[_0x21fd11('0x24e1')](),_0x2e3ca0()[_0x21fd11('0x55e')](_0x3b3b9a))),_0x43ed43[_0x21fd11('0x53')]({'title':_0x21fd11('0x176e'),'msg':_0xc3e8a3[_0x21fd11('0x248f')][_0x21fd11('0x60a')]?_0xc3e8a3[_0x21fd11('0x248f')][_0x21fd11('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x352926(_0x5dbd64);})[_0x460395('0x130a')](function(_0x54d7f5){const _0x1966e7=_0x460395;if(_0x54d7f5[_0x1966e7('0x5a5')]&&_0x54d7f5[_0x1966e7('0x5a5')]['errors']&&_0x54d7f5['data']['errors']['length']){_0xc3e8a3[_0x1966e7('0x17f')]=_0x54d7f5[_0x1966e7('0x5a5')]['errors']||[{'message':_0x54d7f5[_0x1966e7('0x1ff0')](),'type':_0x1966e7('0x1843')}];for(let _0xb70ee1=0x0;_0xb70ee1<_0x54d7f5[_0x1966e7('0x5a5')][_0x1966e7('0x17f')][_0x1966e7('0x1564')];_0xb70ee1++){_0x43ed43[_0x1966e7('0x52a')]({'title':_0x54d7f5['data'][_0x1966e7('0x17f')][_0xb70ee1][_0x1966e7('0xcf0')],'msg':_0x54d7f5[_0x1966e7('0x5a5')][_0x1966e7('0x17f')][_0xb70ee1]['message']});}}else _0x43ed43[_0x1966e7('0x52a')]({'title':_0x54d7f5[_0x1966e7('0x13ee')]?_0x1966e7('0x2168')+_0x54d7f5[_0x1966e7('0x13ee')]+_0x1966e7('0xbf6')+_0x54d7f5['statusText']:_0x1966e7('0x1843'),'msg':_0x54d7f5[_0x1966e7('0x5a5')]?JSON[_0x1966e7('0x258a')](_0x54d7f5['data'][_0x1966e7('0x8c2')]):_0x54d7f5[_0x1966e7('0x1ff0')]()});});}function _0x2c6467(_0x58cc64){const _0x5e1059=_0x7847d7;_0xc3e8a3[_0x5e1059('0x17f')]=[];const _0x2b6a6e=_0x4c83f3[_0x5e1059('0x1c6f')]()[_0x5e1059('0xf28')](_0x5e1059('0x4d'))[_0x5e1059('0xa6a')](_0x5e1059('0x1d8e'))[_0x5e1059('0x1040')]('Delete\x20Metric')['ok']('Delete')[_0x5e1059('0x19fb')](_0x5e1059('0x253a'))['targetEvent'](_0x58cc64);_0x4c83f3[_0x5e1059('0x1d4')](_0x2b6a6e)[_0x5e1059('0x683')](function(){const _0x186c50=_0x5e1059;_0x229b51['analyticMetric'][_0x186c50('0xd7e')]({'id':_0xc3e8a3[_0x186c50('0x248f')]['id']})['$promise'][_0x186c50('0x683')](function(){const _0x3c2898=_0x186c50;_0x2e3ca0()[_0x3c2898('0x3ec')](_0xc3e8a3[_0x3c2898('0x12d')],{'id':_0xc3e8a3['metric']['id']}),_0x43ed43[_0x3c2898('0x53')]({'title':_0x3c2898('0x2665'),'msg':(_0xc3e8a3['metric'][_0x3c2898('0x60a')]||'metric')+_0x3c2898('0x194d')}),_0x352926(_0xc3e8a3[_0x3c2898('0x248f')]);})[_0x186c50('0x130a')](function(_0x50a95d){const _0x5969f0=_0x186c50;if(_0x50a95d['data']&&_0x50a95d['data'][_0x5969f0('0x17f')]&&_0x50a95d[_0x5969f0('0x5a5')][_0x5969f0('0x17f')]['length']){_0xc3e8a3[_0x5969f0('0x17f')]=_0x50a95d[_0x5969f0('0x5a5')]['errors']||[{'message':_0x50a95d[_0x5969f0('0x1ff0')](),'type':'api.analyticMetric.delete'}];for(let _0x3603bf=0x0;_0x3603bf<_0x50a95d['data'][_0x5969f0('0x17f')]['length'];_0x3603bf++){_0x43ed43['error']({'title':_0x50a95d[_0x5969f0('0x5a5')]['errors'][_0x3603bf][_0x5969f0('0xcf0')],'msg':_0x50a95d[_0x5969f0('0x5a5')][_0x5969f0('0x17f')][_0x3603bf][_0x5969f0('0x8c2')]});}}else _0x43ed43[_0x5969f0('0x52a')]({'title':_0x50a95d[_0x5969f0('0x13ee')]?'API:'+_0x50a95d[_0x5969f0('0x13ee')]+_0x5969f0('0xbf6')+_0x50a95d[_0x5969f0('0x24a9')]:_0x5969f0('0x21e6'),'msg':_0x50a95d['data']?JSON['stringify'](_0x50a95d['data']['message']):_0x50a95d[_0x5969f0('0x8c2')]||_0x50a95d[_0x5969f0('0x1ff0')]()});});},function(){});}function _0x2f5110(_0x1d7847){return _0x1d7847===null?undefined:new Date(_0x1d7847);}function _0x352926(_0x1cfea7){const _0x29d811=_0x7847d7;_0x4c83f3[_0x29d811('0x1715')](_0x1cfea7);}}const _0x277f96=_0x3dafc8,_0xaa57f6=_0x180212['p']+_0x189033('0x2009');_0x3c5cdf[_0x189033('0x14be')]=['$scope',_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x12d'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),'Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x3c5cdf(_0x3b9755,_0x15fff9,_0x19912f,_0x33467c,_0x16957e,_0x5356d6,_0xcbd068,_0x5f37a4,_0xf35c8,_0x5a5782,_0x5cee8f,_0x1b4486,_0x58a197,_0x1f7c34,_0x244aec,_0x5850ac,_0x177723){const _0x5a3edb=_0x189033,_0x504956=this;_0x504956[_0x5a3edb('0xace')]=_0x5850ac,_0x504956[_0x5a3edb('0x260a')]=_0x177723,_0x504956[_0x5a3edb('0x11ed')]=_0x244aec['getCurrentUser'](),_0x504956[_0x5a3edb('0x12d')]=_0xf35c8||{'count':0x0,'rows':[]},_0x504956[_0x5a3edb('0x2a')]=_0x5a5782,_0x504956['userProfileSection']=_0x5cee8f&&_0x5cee8f[_0x5a3edb('0x50d')]==0x1?_0x5cee8f['rows'][0x0]:null,_0x504956[_0x5a3edb('0x1134')]=_0x244aec['parseCrudPermissions'](_0x504956['userProfileSection']?_0x504956[_0x5a3edb('0x22df')][_0x5a3edb('0x1134')]:null),_0x504956[_0x5a3edb('0x5c4')]='metrics',_0x504956[_0x5a3edb('0x247')]='',_0x504956[_0x5a3edb('0x1ce2')]=null,_0x504956[_0x5a3edb('0x951')]=[],_0x504956[_0x5a3edb('0x23a2')]={'fields':_0x5a3edb('0x9c8'),'sort':_0x5a3edb('0xc36'),'limit':0xa,'page':0x1},_0x504956[_0x5a3edb('0x20c6')]=_0x2e3ca0()[_0x5a3edb('0x24db')]([{'option':_0x5a3edb('0xc4a'),'value':_0x5a3edb('0x1421')},{'option':_0x5a3edb('0x39d'),'value':_0x5a3edb('0x3b7')},{'option':_0x5a3edb('0x236c'),'value':_0x5a3edb('0x109')},{'option':_0x5a3edb('0x21c1'),'value':_0x5a3edb('0x4e2')},{'option':_0x5a3edb('0x17b3'),'value':_0x5a3edb('0x1701')},{'option':_0x5a3edb('0x1845'),'value':_0x5a3edb('0x369')},{'option':_0x5a3edb('0x94e'),'value':_0x5a3edb('0x27ab')},{'option':'Chat\x20Queues','value':_0x5a3edb('0x21af')},{'option':_0x5a3edb('0x12c0'),'value':'\x27report_chat_queue\x27'},{'option':_0x5a3edb('0x1819'),'value':'\x27report_chat_transfer\x27'},{'option':_0x5a3edb('0x2229'),'value':_0x5a3edb('0x24b7')},{'option':_0x5a3edb('0xdb2'),'value':_0x5a3edb('0x1279')},{'option':'CSquare\x20Report','value':'\x27report_square\x27'},{'option':'CSquare\x20Details\x20Report','value':'\x27report_square_details\x27'},{'option':_0x5a3edb('0x21ee'),'value':'\x27report_dial\x27'},{'option':_0x5a3edb('0xbde'),'value':_0x5a3edb('0x1083')},{'option':_0x5a3edb('0x4de'),'value':_0x5a3edb('0x69c')},{'option':'Dialer\x20Hopper\x20Final','value':_0x5a3edb('0x208b')},{'option':_0x5a3edb('0xec9'),'value':_0x5a3edb('0x1241')},{'option':_0x5a3edb('0x97'),'value':'\x27mail_interactions\x27'},{'option':_0x5a3edb('0x1637'),'value':_0x5a3edb('0xc2f')},{'option':_0x5a3edb('0x1de7'),'value':'\x27mail_queues\x27'},{'option':_0x5a3edb('0x163e'),'value':'\x27report_mail_queue\x27'},{'option':'Email\x20Report\x20Transfer','value':_0x5a3edb('0x1c60')},{'option':_0x5a3edb('0x1a9c'),'value':'\x27fax_accounts\x27'},{'option':_0x5a3edb('0x169e'),'value':'\x27fax_interactions\x27'},{'option':_0x5a3edb('0x26b4'),'value':_0x5a3edb('0xd11')},{'option':_0x5a3edb('0x7f3'),'value':'\x27fax_queues\x27'},{'option':_0x5a3edb('0x164d'),'value':'\x27report_fax_queue\x27'},{'option':_0x5a3edb('0xb46'),'value':_0x5a3edb('0x1b18')},{'option':_0x5a3edb('0x15a6'),'value':_0x5a3edb('0xeda')},{'option':_0x5a3edb('0x4c6'),'value':'\x27report_jscripty_questions\x27'},{'option':_0x5a3edb('0x2577'),'value':_0x5a3edb('0x9e3')},{'option':'Lists','value':_0x5a3edb('0x11b2')},{'option':_0x5a3edb('0x9d4'),'value':'\x27report_member\x27'},{'option':_0x5a3edb('0x231d'),'value':'\x27openchannel_accounts\x27'},{'option':_0x5a3edb('0x147d'),'value':_0x5a3edb('0x25c')},{'option':'Openchannel\x20Messages','value':_0x5a3edb('0x12fe')},{'option':_0x5a3edb('0x230e'),'value':_0x5a3edb('0x279a')},{'option':_0x5a3edb('0x2fe'),'value':_0x5a3edb('0xa91')},{'option':_0x5a3edb('0x21d5'),'value':_0x5a3edb('0x1d6d')},{'option':_0x5a3edb('0x626'),'value':_0x5a3edb('0x245a')},{'option':_0x5a3edb('0x919'),'value':_0x5a3edb('0x2141')},{'option':'SMS\x20Interaction','value':_0x5a3edb('0xe1f')},{'option':_0x5a3edb('0x736'),'value':_0x5a3edb('0xb17')},{'option':_0x5a3edb('0xfd1'),'value':_0x5a3edb('0x236f')},{'option':_0x5a3edb('0x1941'),'value':'\x27report_sms_queue\x27'},{'option':_0x5a3edb('0x16bc'),'value':_0x5a3edb('0x106d')},{'option':_0x5a3edb('0x2139'),'value':_0x5a3edb('0x270d')},{'option':_0x5a3edb('0x6ac'),'value':'\x27voice_recordings\x27'},{'option':'Whatsapp\x20Account','value':_0x5a3edb('0x214')},{'option':_0x5a3edb('0x4f9'),'value':'\x27whatsapp_interactions\x27'},{'option':_0x5a3edb('0x826'),'value':_0x5a3edb('0xaf9')},{'option':_0x5a3edb('0x10c9'),'value':'\x27whatsapp_queues\x27'},{'option':_0x5a3edb('0xa51'),'value':_0x5a3edb('0x20ca')},{'option':'Whatsapp\x20Report\x20Transfer','value':_0x5a3edb('0x16a4')}],function(_0xdc39af){const _0x1e867c=_0x5a3edb;return _0x2e3ca0()['replace'](_0xdc39af[_0x1e867c('0x1c6b')],new RegExp('\x27','g'),'');}),_0x504956[_0x5a3edb('0x1249')]=_0x54553e,_0x504956['deleteconfirm']=_0x1b50e5,_0x504956['success']=_0x42209d,_0x504956['getMetrics']=_0x11e775,_0x504956[_0x5a3edb('0x6f3')]=_0x4f578b,_0x504956[_0x5a3edb('0x30b')]=_0x20ed95,_0x504956['exportSelectedMetrics']=_0x3a25e4,_0x504956[_0x5a3edb('0x20dd')]=_0x3bec3f,_0x504956[_0x5a3edb('0x45')]=_0x376bd8,_0x504956[_0x5a3edb('0x165d')]=_0x2a704a;function _0x54553e(_0x3b6480,_0x2878cc){const _0x57696b=_0x5a3edb;_0x16957e[_0x57696b('0x1d4')]({'controller':'CreateOrEditMetricDialogController','controllerAs':'vm','templateUrl':_0xaa57f6,'parent':angular['element'](_0x5356d6[_0x57696b('0x18e5')]),'targetEvent':_0x2878cc,'clickOutsideToClose':!![],'locals':{'metric':_0x3b6480,'metrics':_0x504956[_0x57696b('0x12d')]['rows'],'license':_0x504956['license'],'setting':null,'crudPermissions':_0x504956[_0x57696b('0x1134')]}});}function _0x1b50e5(_0x12d717,_0x899ff5){const _0x1c9be9=_0x5a3edb,_0x39288c=_0x16957e['confirm']()[_0x1c9be9('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()['startCase'](_0x1c9be9('0x248f'))+'?')[_0x1c9be9('0x26e3')](''+(_0x12d717[_0x1c9be9('0x60a')]||_0x1c9be9('0x248f'))+_0x1c9be9('0x20f1')+_0x1c9be9('0x1ee7'))[_0x1c9be9('0x1040')](_0x1c9be9('0x1671'))['targetEvent'](_0x899ff5)['ok']('OK')[_0x1c9be9('0x19fb')](_0x1c9be9('0x16b8'));_0x16957e[_0x1c9be9('0x1d4')](_0x39288c)[_0x1c9be9('0x683')](function(){_0x20ed95(_0x12d717);},function(){const _0x4b86bb=_0x1c9be9;console['log'](_0x4b86bb('0x16b8'));});}let _0x35679a=!![],_0x2b6b89=0x1;_0x3b9755[_0x5a3edb('0x186d')](_0x5a3edb('0x1e1d'),function(_0x22c7fe,_0x3e174b){const _0x128da9=_0x5a3edb;_0x35679a?_0xcbd068(function(){_0x35679a=![];}):(!_0x3e174b&&(_0x2b6b89=_0x504956[_0x128da9('0x23a2')][_0x128da9('0xdf8')]),_0x22c7fe!==_0x3e174b&&(_0x504956[_0x128da9('0x23a2')]['page']=0x1),!_0x22c7fe&&(_0x504956[_0x128da9('0x23a2')][_0x128da9('0xdf8')]=_0x2b6b89),_0x504956[_0x128da9('0x2738')]());});function _0x42209d(_0x187c44){const _0x592cbc=_0x5a3edb;_0x504956[_0x592cbc('0x12d')]=_0x187c44||{'count':0x0,'rows':[]};}function _0x11e775(){const _0x331652=_0x5a3edb;_0x504956['query']['offset']=(_0x504956['query'][_0x331652('0xdf8')]-0x1)*_0x504956['query']['limit'],_0x244aec['hasRole'](_0x331652('0x20c2'))?_0x504956['promise']=_0x1b4486[_0x331652('0x1c97')]['get'](_0x504956['query'],_0x42209d)[_0x331652('0xe53')]:(_0x504956[_0x331652('0x23a2')]['id']=_0x504956[_0x331652('0x2a')]['id'],_0x504956['query'][_0x331652('0x1aa')]=_0x331652('0x264d'),_0x504956[_0x331652('0x1883')]=_0x1b4486[_0x331652('0x2a')][_0x331652('0x241d')](_0x504956['query'],_0x42209d)[_0x331652('0xe53')]);}function _0x4f578b(_0x2c7375,_0x5a5068){const _0x1e0091=_0x5a3edb;_0x16957e['show']({'controller':_0x1e0091('0x24ba'),'controllerAs':'vm','templateUrl':_0xaa57f6,'parent':angular['element'](_0x5356d6[_0x1e0091('0x18e5')]),'targetEvent':_0x2c7375,'clickOutsideToClose':!![],'locals':{'metric':_0x5a5068,'metrics':_0x504956['metrics'][_0x1e0091('0xf5d')],'license':_0x504956[_0x1e0091('0xace')],'setting':_0x504956[_0x1e0091('0x260a')],'crudPermissions':_0x504956['crudPermissions']}});}function _0x20ed95(_0x1a89f3){const _0x507149=_0x5a3edb;_0x1b4486[_0x507149('0x1c97')][_0x507149('0xd7e')]({'id':_0x1a89f3['id']})[_0x507149('0xe53')][_0x507149('0x683')](function(){const _0x1533a9=_0x507149;_0x2e3ca0()[_0x1533a9('0x3ec')](_0x504956[_0x1533a9('0x12d')][_0x1533a9('0xf5d')],{'id':_0x1a89f3['id']}),_0x504956[_0x1533a9('0x12d')][_0x1533a9('0x50d')]-=0x1,!_0x504956[_0x1533a9('0x12d')][_0x1533a9('0xf5d')][_0x1533a9('0x1564')]&&_0x504956[_0x1533a9('0x2738')](),_0x1f7c34[_0x1533a9('0x53')]({'title':_0x2e3ca0()[_0x1533a9('0x1e03')]('Metric')+_0x1533a9('0xbfc'),'msg':_0x1a89f3[_0x1533a9('0x60a')]?_0x1a89f3[_0x1533a9('0x60a')]+_0x1533a9('0x194d'):''});})[_0x507149('0x130a')](function(_0x470b62){const _0x2d4936=_0x507149;if(_0x470b62[_0x2d4936('0x5a5')]&&_0x470b62[_0x2d4936('0x5a5')][_0x2d4936('0x17f')]&&_0x470b62[_0x2d4936('0x5a5')][_0x2d4936('0x17f')][_0x2d4936('0x1564')]){_0x504956[_0x2d4936('0x17f')]=_0x470b62[_0x2d4936('0x5a5')][_0x2d4936('0x17f')]||[{'message':_0x470b62['toString'](),'type':_0x2d4936('0x2286')}];for(let _0x523ea9=0x0;_0x523ea9<_0x470b62[_0x2d4936('0x5a5')][_0x2d4936('0x17f')][_0x2d4936('0x1564')];_0x523ea9++){_0x1f7c34[_0x2d4936('0x52a')]({'title':_0x470b62['data'][_0x2d4936('0x17f')][_0x523ea9][_0x2d4936('0xcf0')],'msg':_0x470b62[_0x2d4936('0x5a5')][_0x2d4936('0x17f')][_0x523ea9][_0x2d4936('0x8c2')]});}}else _0x1f7c34[_0x2d4936('0x52a')]({'title':_0x470b62[_0x2d4936('0x13ee')]?_0x2d4936('0x2168')+_0x470b62[_0x2d4936('0x13ee')]+_0x2d4936('0xbf6')+_0x470b62[_0x2d4936('0x24a9')]:'SYSTEM:DELETEanalyticMetric','msg':_0x470b62[_0x2d4936('0x5a5')]?JSON[_0x2d4936('0x258a')](_0x470b62['data'][_0x2d4936('0x8c2')]):_0x470b62['message']||_0x470b62['toString']()});});}function _0x3a25e4(){const _0x1fc0fe=_0x5a3edb,_0x44c7c9=angular[_0x1fc0fe('0x1a86')](_0x504956[_0x1fc0fe('0x951')]);return _0x504956[_0x1fc0fe('0x951')]=[],_0x44c7c9;}function _0x3bec3f(_0x23bcf1){const _0x256649=_0x5a3edb,_0x28f4ff=_0x16957e[_0x256649('0x1c6f')]()[_0x256649('0xf28')](_0x256649('0x1df6'))['htmlContent'](_0x256649('0xed5')+_0x504956[_0x256649('0x951')]['length']+_0x256649('0x93c')+_0x256649('0x1ee7'))[_0x256649('0x1040')](_0x256649('0x22'))['targetEvent'](_0x23bcf1)['ok']('OK')[_0x256649('0x19fb')](_0x256649('0x16b8'));_0x16957e[_0x256649('0x1d4')](_0x28f4ff)[_0x256649('0x683')](function(){const _0x3fd5c1=_0x256649;_0x504956[_0x3fd5c1('0x951')]['forEach'](function(_0x3ae36e){_0x20ed95(_0x3ae36e);}),_0x504956[_0x3fd5c1('0x951')]=[];});}function _0x376bd8(){const _0x2a3d70=_0x5a3edb;_0x504956[_0x2a3d70('0x951')]=[];}function _0x2a704a(){const _0x2f5f9b=_0x5a3edb;_0x504956['selectedMetrics']=_0x504956[_0x2f5f9b('0x12d')][_0x2f5f9b('0xf5d')];}}const _0x41deb9=_0x3c5cdf;_0x1f8be5['$inject']=[_0x189033('0x1398'),'$translatePartialLoaderProvider'];function _0x1f8be5(_0x38b0da,_0x561922){const _0x39ee6e=_0x189033;_0x38b0da[_0x39ee6e('0x2598')](_0x39ee6e('0x452'),{'abstract':!![],'url':_0x39ee6e('0x1f40')})['state']('app.analytics.metrics',{'url':_0x39ee6e('0x1012'),'views':{'content@app':{'templateUrl':_0x2caf41,'controller':_0x39ee6e('0x104a')}},'resolve':{'metrics':[_0x39ee6e('0x4b1'),_0x39ee6e('0xba1'),function(_0x54806b,_0x986590){const _0x5c6376=_0x39ee6e;return _0x986590[_0x5c6376('0xca1')](_0x5c6376('0x20c2'))?_0x54806b[_0x5c6376('0xed7')](_0x5c6376('0x10ed'),{'fields':'createdAt,updatedAt,id,name,table,metric,description','sort':_0x5c6376('0xc36'),'limit':0xa,'offset':0x0}):_0x54806b['resolve'](_0x5c6376('0x191b'),{'id':_0x986590[_0x5c6376('0x20b2')]()[_0x5c6376('0x2f')],'section':_0x5c6376('0x264d'),'fields':_0x5c6376('0x9c8'),'sort':_0x5c6376('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x39ee6e('0x4b1'),_0x39ee6e('0xba1'),function(_0x43cfdc,_0x372685){const _0x2f7b3f=_0x39ee6e;return _0x372685[_0x2f7b3f('0xca1')](_0x2f7b3f('0x20c2'))?null:_0x43cfdc[_0x2f7b3f('0xed7')](_0x2f7b3f('0x1464'),{'fields':_0x2f7b3f('0x16f'),'id':_0x372685[_0x2f7b3f('0x20b2')]()[_0x2f7b3f('0x2f')]});}],'userProfileSection':[_0x39ee6e('0x4b1'),_0x39ee6e('0xba1'),function(_0x429538,_0x54fb95){const _0x2e473d=_0x39ee6e;return _0x54fb95[_0x2e473d('0xca1')](_0x2e473d('0x20c2'))?null:_0x429538['resolve']('userProfileSection@get',{'fields':_0x2e473d('0x1f47'),'userProfileId':_0x54fb95[_0x2e473d('0x20b2')]()['userProfileId'],'sectionId':0x4b1});}]},'authenticate':!![],'permissionId':0x4b1,'bodyClass':'analytics'})[_0x39ee6e('0x2598')](_0x39ee6e('0x5c8'),{'url':'/extractedReports','views':{'content@app':{'templateUrl':_0x55c930,'controller':_0x39ee6e('0x446')}},'resolve':{'extractedReports':[_0x39ee6e('0x4b1'),_0x39ee6e('0xba1'),function(_0xbcc55c,_0x5dd2c7){const _0x24023e=_0x39ee6e;return _0x5dd2c7[_0x24023e('0xca1')](_0x24023e('0x20c2'))?_0xbcc55c[_0x24023e('0xed7')](_0x24023e('0x103f'),{'fields':_0x24023e('0x11e6'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0xbcc55c['resolve'](_0x24023e('0x191b'),{'id':_0x5dd2c7[_0x24023e('0x20b2')]()[_0x24023e('0x2f')],'section':_0x24023e('0x14ec'),'fields':'createdAt,updatedAt,id,name,basename,savename,type,startDate,endDate,status,output,reportId,reportType','sort':_0x24023e('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x39ee6e('0x4b1'),_0x39ee6e('0xba1'),function(_0x35b9af,_0x5d03f0){const _0x135040=_0x39ee6e;return _0x5d03f0['hasRole']('admin')?null:_0x35b9af[_0x135040('0xed7')](_0x135040('0x1464'),{'fields':_0x135040('0x16f'),'id':_0x5d03f0['getCurrentUser']()[_0x135040('0x2f')]});}],'userProfileSection':[_0x39ee6e('0x4b1'),_0x39ee6e('0xba1'),function(_0x3f6409,_0x3bd477){const _0x4f63f3=_0x39ee6e;return _0x3bd477[_0x4f63f3('0xca1')](_0x4f63f3('0x20c2'))?null:_0x3f6409[_0x4f63f3('0xed7')](_0x4f63f3('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x3bd477['getCurrentUser']()[_0x4f63f3('0x2f')],'sectionId':0x4b2});}]},'authenticate':!![],'permissionId':0x4b2,'bodyClass':_0x39ee6e('0xa01')}),_0x561922[_0x39ee6e('0x7d2')](_0x39ee6e('0x1df2'));}angular[_0x189033('0x1e26')](_0x189033('0x452'),['ngCsv',_0x189033('0x1ddb'),_0x189033('0x2290'),_0x189033('0x190a'),_0x189033('0x25fc'),'ckeditor','ng-sortable','ngAria','ngAnimate',_0x189033('0x76'),'mwFormBuilder',_0x189033('0x7fa'),_0x189033('0x197b'),'ngclipboard','angular-cron-jobs','ngEmbed',_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da'),_0x189033('0x2721')])['config'](_0x1f8be5)[_0x189033('0x1da3')](_0x189033('0x23a1'),_0x5b9944)['controller']('ExtractedReportsController',_0x4eaf60)[_0x189033('0x1da3')](_0x189033('0x24ba'),_0x277f96)[_0x189033('0x1da3')](_0x189033('0x33f'),_0x41deb9);const _0x1cacb4=_0x180212['p']+_0x189033('0x2284'),_0x57d37e=_0x180212['p']+_0x189033('0xdec'),_0x3b643a=_0x180212['p']+_0x189033('0x235c'),_0x55a2a2=_0x180212['p']+'src/js/modules/main/apps/integrations/views/salesforceAccounts/edit/view.html/view.html',_0x33c9a8=_0x180212['p']+_0x189033('0x1ab7'),_0x42855a=_0x180212['p']+'src/js/modules/main/apps/integrations/views/freshdeskAccounts/edit/view.html/view.html',_0x5c8fb4=_0x180212['p']+_0x189033('0x1b3d'),_0x3a3dc1=_0x180212['p']+_0x189033('0x1f9'),_0x2b688b=_0x180212['p']+_0x189033('0xf20'),_0x17c819=_0x180212['p']+_0x189033('0xe7'),_0x30bd8a=_0x180212['p']+_0x189033('0x1afa'),_0x24baf4=_0x180212['p']+_0x189033('0x184'),_0x455be5=_0x180212['p']+_0x189033('0x1ab6'),_0x4ac943=_0x180212['p']+_0x189033('0x1e54'),_0x1008d1=_0x180212['p']+_0x189033('0x72d'),_0x15b0ab=_0x180212['p']+_0x189033('0x1e3a'),_0x2b74ee=_0x180212['p']+'src/js/modules/main/apps/integrations/views/servicenowAccounts/servicenowAccounts.html/servicenowAccounts.html',_0xdbe799=_0x180212['p']+_0x189033('0x1817'),_0x35df94=_0x180212['p']+_0x189033('0x403'),_0x5b7175=_0x180212['p']+_0x189033('0x1310');_0x310881[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x1b12'),_0x189033('0x194e'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x310881(_0x63528d,_0x3a0a10,_0x5e95a7,_0x4d04ca,_0x9fa183,_0x19f26e,_0x323bf7,_0x53dcee,_0x55e6c4,_0x3cbc53,_0x4d7107,_0x56c1f3,_0x5e70ef,_0xbf6294){const _0x5d3b83=_0x189033,_0x5d2c60=this;_0x5d2c60[_0x5d3b83('0x11ed')]=_0x4d7107[_0x5d3b83('0x20b2')](),_0x5d2c60[_0x5d3b83('0x17f')]=[],_0x5d2c60[_0x5d3b83('0x260a')]=_0x5e70ef,_0x5d2c60[_0x5d3b83('0xace')]=_0x56c1f3,_0x5d2c60['crudPermissions']=_0xbf6294,_0x5d2c60[_0x5d3b83('0x258d')]={},_0x5d2c60[_0x5d3b83('0x19b2')]=_0x5d2c60[_0x5d3b83('0x260a')]&&_0x5d2c60[_0x5d3b83('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5d2c60[_0x5d3b83('0xf28')]='INTEGRATIONS.EDIT_DESKACCOUNT',_0x5d2c60['deskAccount']=angular['copy'](_0x55e6c4),_0x5d2c60[_0x5d3b83('0x1b12')]=_0x53dcee,_0x5d2c60[_0x5d3b83('0x6a3')]=![];!_0x5d2c60['deskAccount']&&(_0x5d2c60[_0x5d3b83('0x194e')]={'type':_0x5d3b83('0x2d1'),'authType':_0x5d3b83('0xd99'),'serverUrl':_0x5e95a7[_0x5d3b83('0x173e')]()+_0x5d3b83('0x20de')+_0x5e95a7[_0x5d3b83('0x19ac')]()+(_0x5e95a7[_0x5d3b83('0x4a2')]()?':'+_0x5e95a7[_0x5d3b83('0x4a2')]():'')},_0x5d2c60['title']=_0x5d3b83('0x3ff'),_0x5d2c60[_0x5d3b83('0x6a3')]=!![]);_0x5d2c60[_0x5d3b83('0x1e91')]=_0x236c3f,_0x5d2c60[_0x5d3b83('0xc1a')]=_0x96fe2d,_0x5d2c60['deleteDeskAccount']=_0x2ec071,_0x5d2c60[_0x5d3b83('0x16b3')]=_0x3a4ae9,_0x5d2c60[_0x5d3b83('0xf82')]=_0x23c4c2;function _0x236c3f(){const _0x2c15cf=_0x5d3b83;_0x5d2c60[_0x2c15cf('0x17f')]=[],_0x3cbc53['intDeskAccount'][_0x2c15cf('0xb0a')](_0x5d2c60[_0x2c15cf('0x194e')])['$promise'][_0x2c15cf('0x683')](function(_0x356260){const _0x2c31d6=_0x2c15cf;_0x5d2c60[_0x2c31d6('0x1b12')][_0x2c31d6('0x1167')](_0x356260[_0x2c31d6('0x24e1')]()),_0x323bf7[_0x2c31d6('0x53')]({'title':'DeskAccount\x20properly\x20created','msg':_0x5d2c60['deskAccount'][_0x2c31d6('0x60a')]?_0x5d2c60[_0x2c31d6('0x194e')]['name']+'\x20has\x20been\x20created!':''}),_0x23c4c2(_0x356260);})[_0x2c15cf('0x130a')](function(_0xcb1573){const _0xa12a6b=_0x2c15cf;if(_0xcb1573['data']&&_0xcb1573['data']['errors']&&_0xcb1573['data'][_0xa12a6b('0x17f')][_0xa12a6b('0x1564')]){_0x5d2c60[_0xa12a6b('0x17f')]=_0xcb1573[_0xa12a6b('0x5a5')][_0xa12a6b('0x17f')]||[{'message':_0xcb1573[_0xa12a6b('0x1ff0')](),'type':_0xa12a6b('0x18db')}];for(let _0xa5a9ef=0x0;_0xa5a9ef<_0xcb1573[_0xa12a6b('0x5a5')][_0xa12a6b('0x17f')][_0xa12a6b('0x1564')];_0xa5a9ef+=0x1){_0x323bf7[_0xa12a6b('0x52a')]({'title':_0xcb1573[_0xa12a6b('0x5a5')][_0xa12a6b('0x17f')][_0xa5a9ef][_0xa12a6b('0xcf0')],'msg':_0xcb1573['data']['errors'][_0xa5a9ef][_0xa12a6b('0x8c2')]});}}else _0x323bf7[_0xa12a6b('0x52a')]({'title':_0xcb1573[_0xa12a6b('0x13ee')]?_0xa12a6b('0x2168')+_0xcb1573[_0xa12a6b('0x13ee')]+_0xa12a6b('0xbf6')+_0xcb1573[_0xa12a6b('0x24a9')]:_0xa12a6b('0x18db'),'msg':_0xcb1573['data']?JSON[_0xa12a6b('0x258a')](_0xcb1573[_0xa12a6b('0x5a5')][_0xa12a6b('0x8c2')]):_0xcb1573[_0xa12a6b('0x1ff0')]()});});}function _0x96fe2d(){const _0x581f6c=_0x5d3b83;_0x5d2c60[_0x581f6c('0x17f')]=[],_0x3cbc53[_0x581f6c('0xe2b')][_0x581f6c('0x2480')]({'id':_0x5d2c60['deskAccount']['id']},_0x5d2c60['deskAccount'])['$promise'][_0x581f6c('0x683')](function(_0x1b9f48){const _0x52ddf8=_0x581f6c,_0x3655e5=_0x2e3ca0()['find'](_0x5d2c60['deskAccounts'],{'id':_0x1b9f48['id']});_0x3655e5&&_0x2e3ca0()[_0x52ddf8('0xf22')](_0x3655e5,_0x2e3ca0()[_0x52ddf8('0x24d0')](_0x1b9f48[_0x52ddf8('0x24e1')](),_0x2e3ca0()['keys'](_0x3655e5))),_0x323bf7[_0x52ddf8('0x53')]({'title':_0x52ddf8('0x17d3'),'msg':_0x5d2c60[_0x52ddf8('0x194e')][_0x52ddf8('0x60a')]?_0x5d2c60[_0x52ddf8('0x194e')]['name']+_0x52ddf8('0xf59'):''}),_0x23c4c2(_0x1b9f48);})[_0x581f6c('0x130a')](function(_0x531118){const _0x23080b=_0x581f6c;if(_0x531118[_0x23080b('0x5a5')]&&_0x531118[_0x23080b('0x5a5')][_0x23080b('0x17f')]&&_0x531118[_0x23080b('0x5a5')][_0x23080b('0x17f')][_0x23080b('0x1564')]){_0x5d2c60['errors']=_0x531118[_0x23080b('0x5a5')][_0x23080b('0x17f')]||[{'message':_0x531118[_0x23080b('0x1ff0')](),'type':_0x23080b('0xadd')}];for(let _0x316c4b=0x0;_0x316c4b<_0x531118[_0x23080b('0x5a5')][_0x23080b('0x17f')][_0x23080b('0x1564')];_0x316c4b++){_0x323bf7[_0x23080b('0x52a')]({'title':_0x531118[_0x23080b('0x5a5')][_0x23080b('0x17f')][_0x316c4b][_0x23080b('0xcf0')],'msg':_0x531118[_0x23080b('0x5a5')]['errors'][_0x316c4b][_0x23080b('0x8c2')]});}}else _0x323bf7[_0x23080b('0x52a')]({'title':_0x531118[_0x23080b('0x13ee')]?_0x23080b('0x2168')+_0x531118[_0x23080b('0x13ee')]+_0x23080b('0xbf6')+_0x531118[_0x23080b('0x24a9')]:'api.intDeskAccount.update','msg':_0x531118[_0x23080b('0x5a5')]?JSON['stringify'](_0x531118[_0x23080b('0x5a5')][_0x23080b('0x8c2')]):_0x531118[_0x23080b('0x1ff0')]()});});}function _0x2ec071(_0x50e0df){const _0x9f7e09=_0x5d3b83;_0x5d2c60[_0x9f7e09('0x17f')]=[];const _0x587e7c=_0x4d04ca[_0x9f7e09('0x1c6f')]()[_0x9f7e09('0xf28')](_0x9f7e09('0x4d'))['content']('The\x20deskAccount\x20will\x20be\x20deleted.')[_0x9f7e09('0x1040')]('Delete\x20DeskAccount')['ok']('Delete')['cancel'](_0x9f7e09('0x253a'))[_0x9f7e09('0xe42')](_0x50e0df);_0x4d04ca[_0x9f7e09('0x1d4')](_0x587e7c)[_0x9f7e09('0x683')](function(){const _0x4acf81=_0x9f7e09;_0x3cbc53[_0x4acf81('0xe2b')][_0x4acf81('0xd7e')]({'id':_0x5d2c60[_0x4acf81('0x194e')]['id']})['$promise'][_0x4acf81('0x683')](function(){const _0xe7f479=_0x4acf81;_0x2e3ca0()[_0xe7f479('0x3ec')](_0x5d2c60[_0xe7f479('0x1b12')],{'id':_0x5d2c60[_0xe7f479('0x194e')]['id']}),_0x323bf7[_0xe7f479('0x53')]({'title':'DeskAccount\x20properly\x20deleted!','msg':(_0x5d2c60['deskAccount'][_0xe7f479('0x60a')]||_0xe7f479('0x194e'))+_0xe7f479('0x194d')}),_0x23c4c2(_0x5d2c60['deskAccount']);})['catch'](function(_0x3dee3a){const _0x16d586=_0x4acf81;if(_0x3dee3a[_0x16d586('0x5a5')]&&_0x3dee3a[_0x16d586('0x5a5')][_0x16d586('0x17f')]&&_0x3dee3a[_0x16d586('0x5a5')]['errors']['length']){_0x5d2c60[_0x16d586('0x17f')]=_0x3dee3a[_0x16d586('0x5a5')][_0x16d586('0x17f')]||[{'message':_0x3dee3a[_0x16d586('0x1ff0')](),'type':_0x16d586('0x5b2')}];for(let _0x4f187f=0x0;_0x4f187f<_0x3dee3a[_0x16d586('0x5a5')][_0x16d586('0x17f')][_0x16d586('0x1564')];_0x4f187f++){_0x323bf7[_0x16d586('0x52a')]({'title':_0x3dee3a[_0x16d586('0x5a5')][_0x16d586('0x17f')][_0x4f187f][_0x16d586('0xcf0')],'msg':_0x3dee3a[_0x16d586('0x5a5')][_0x16d586('0x17f')][_0x4f187f][_0x16d586('0x8c2')]});}}else _0x323bf7[_0x16d586('0x52a')]({'title':_0x3dee3a['status']?_0x16d586('0x2168')+_0x3dee3a[_0x16d586('0x13ee')]+_0x16d586('0xbf6')+_0x3dee3a['statusText']:_0x16d586('0x5b2'),'msg':_0x3dee3a[_0x16d586('0x5a5')]?JSON[_0x16d586('0x258a')](_0x3dee3a[_0x16d586('0x5a5')][_0x16d586('0x8c2')]):_0x3dee3a[_0x16d586('0x8c2')]||_0x3dee3a[_0x16d586('0x1ff0')]()});});},function(){});}function _0x3a4ae9(_0x46d6ca){return _0x46d6ca===null?undefined:new Date(_0x46d6ca);}function _0x23c4c2(_0x471357){_0x4d04ca['hide'](_0x471357);}}const _0x12f9be=_0x310881,_0x122787=_0x180212['p']+_0x189033('0x51d');_0x59b854['$inject']=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),'$translate','deskAccounts',_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),'license',_0x189033('0x260a')];function _0x59b854(_0x7ebe69,_0x5740d6,_0xce62c4,_0x42970f,_0x3752f8,_0x3dd38f,_0x2fb862,_0x4436a3,_0x543a62,_0x395df5,_0x3fd985,_0x36f2c6,_0x326714,_0x4f980c,_0x22821a,_0x362e17,_0x2c542d){const _0x120bf5=_0x189033,_0x541df5=this;_0x541df5['license']=_0x362e17,_0x541df5[_0x120bf5('0x260a')]=_0x2c542d,_0x541df5[_0x120bf5('0x11ed')]=_0x22821a[_0x120bf5('0x20b2')](),_0x541df5[_0x120bf5('0x1b12')]=_0x543a62||{'count':0x0,'rows':[]},_0x541df5[_0x120bf5('0x2a')]=_0x395df5,_0x541df5[_0x120bf5('0x22df')]=_0x3fd985&&_0x3fd985['count']==0x1?_0x3fd985[_0x120bf5('0xf5d')][0x0]:null,_0x541df5['crudPermissions']=_0x22821a[_0x120bf5('0x142a')](_0x541df5['userProfileSection']?_0x541df5['userProfileSection']['crudPermissions']:null),_0x541df5[_0x120bf5('0x5c4')]=_0x120bf5('0x1b12'),_0x541df5[_0x120bf5('0x247')]='',_0x541df5[_0x120bf5('0x1ce2')]=null,_0x541df5[_0x120bf5('0x18f8')]=[],_0x541df5['query']={'fields':_0x120bf5('0x806'),'limit':0xa,'page':0x1},_0x541df5[_0x120bf5('0x10b7')]=_0x2e3ca0()['keyBy']([{'option':'Integration_Tab','value':_0x120bf5('0xd46')},{'option':_0x120bf5('0x24ac'),'value':_0x120bf5('0xf78')}],function(_0x3e53fc){const _0x168040=_0x120bf5;return _0x2e3ca0()['replace'](_0x3e53fc[_0x168040('0x1c6b')],new RegExp('\x27','g'),'');}),_0x541df5[_0x120bf5('0x31b')]=_0x2e3ca0()[_0x120bf5('0x24db')]([{'option':_0x120bf5('0x720'),'value':_0x120bf5('0xb63')}],function(_0x3f3559){const _0x33c524=_0x120bf5;return _0x2e3ca0()[_0x33c524('0x1725')](_0x3f3559[_0x33c524('0x1c6b')],new RegExp('\x27','g'),'');}),_0x541df5['editstate']=_0x50dd08,_0x541df5[_0x120bf5('0x375')]=_0x4fc8b0,_0x541df5[_0x120bf5('0x194f')]=_0x4558e9,_0x541df5[_0x120bf5('0x53')]=_0x1e6cff,_0x541df5[_0x120bf5('0xf6e')]=_0x30af9d,_0x541df5['createOrEditDeskAccount']=_0x259d20,_0x541df5[_0x120bf5('0xe8a')]=_0x2cb4a5,_0x541df5[_0x120bf5('0xeb8')]=_0x536cd2,_0x541df5[_0x120bf5('0x99d')]=_0x57e564,_0x541df5[_0x120bf5('0x196f')]=_0x3dfca2,_0x541df5[_0x120bf5('0x17ae')]=_0xc98df3;function _0x50dd08(_0x25ea22){const _0x2bbeee=_0x120bf5;_0xce62c4['go'](_0x2bbeee('0x1818'),{'id':_0x25ea22['id'],'deskAccount':_0x25ea22,'crudPermissions':_0x541df5['crudPermissions']});}function _0x4fc8b0(_0x1e316d){const _0x3846cd=_0x120bf5;return _0x36f2c6[_0x3846cd('0xe2b')][_0x3846cd('0x298')]({'id':_0x1e316d['id'],'test':!![]})[_0x3846cd('0xe53')][_0x3846cd('0x683')](function(){const _0x9f7f25=_0x3846cd;_0x4f980c['success']({'title':_0x9f7f25('0x199a'),'msg':_0x9f7f25('0x1c6d')});})[_0x3846cd('0x130a')](function(_0x3b9e67){const _0x31583f=_0x3846cd;_0x4f980c[_0x31583f('0x52a')]({'title':_0x31583f('0x199a'),'msg':_0x3b9e67[_0x31583f('0x5a5')]?_0x3b9e67[_0x31583f('0x5a5')][_0x31583f('0x8c2')]?_0x3b9e67['data'][_0x31583f('0x8c2')]:JSON[_0x31583f('0x258a')](_0x3b9e67['data']):_0x3b9e67['toString']()});});}function _0x4558e9(_0x256078,_0x4bd513){const _0x35650d=_0x120bf5,_0x13935c=_0x3752f8[_0x35650d('0x1c6f')]()[_0x35650d('0xf28')](_0x35650d('0x1b01')+_0x2e3ca0()[_0x35650d('0x1e03')](_0x35650d('0x194e'))+'?')[_0x35650d('0x26e3')](_0x35650d('0xed5')+(_0x256078[_0x35650d('0x60a')]||_0x35650d('0x194e'))+_0x35650d('0x20f1')+_0x35650d('0x1ee7'))[_0x35650d('0x1040')](_0x35650d('0x271c'))[_0x35650d('0xe42')](_0x4bd513)['ok']('OK')[_0x35650d('0x19fb')](_0x35650d('0x16b8'));_0x3752f8[_0x35650d('0x1d4')](_0x13935c)['then'](function(){_0x2cb4a5(_0x256078);},function(){const _0x234b05=_0x35650d;console['log'](_0x234b05('0x16b8'));});}let _0x422d0b=!![],_0x590a47=0x1;_0x7ebe69[_0x120bf5('0x186d')](_0x120bf5('0x1e1d'),function(_0x5ad0fe,_0x3d839f){const _0x4c797e=_0x120bf5;_0x422d0b?_0x2fb862(function(){_0x422d0b=![];}):(!_0x3d839f&&(_0x590a47=_0x541df5['query'][_0x4c797e('0xdf8')]),_0x5ad0fe!==_0x3d839f&&(_0x541df5[_0x4c797e('0x23a2')][_0x4c797e('0xdf8')]=0x1),!_0x5ad0fe&&(_0x541df5[_0x4c797e('0x23a2')]['page']=_0x590a47),_0x541df5[_0x4c797e('0xf6e')]());});function _0x1e6cff(_0x4998a9){const _0x570d05=_0x120bf5;_0x541df5[_0x570d05('0x1b12')]=_0x4998a9||{'count':0x0,'rows':[]};}function _0x30af9d(){const _0x3174fb=_0x120bf5;_0x541df5[_0x3174fb('0x23a2')][_0x3174fb('0x1cc8')]=(_0x541df5['query'][_0x3174fb('0xdf8')]-0x1)*_0x541df5['query']['limit'],_0x22821a['hasRole'](_0x3174fb('0x20c2'))?_0x541df5[_0x3174fb('0x1883')]=_0x36f2c6['intDeskAccount'][_0x3174fb('0x1e6e')](_0x541df5['query'],_0x1e6cff)[_0x3174fb('0xe53')]:(_0x541df5[_0x3174fb('0x23a2')]['id']=_0x541df5[_0x3174fb('0x2a')]['id'],_0x541df5[_0x3174fb('0x23a2')][_0x3174fb('0x1aa')]=_0x3174fb('0x6a8'),_0x541df5[_0x3174fb('0x1883')]=_0x36f2c6[_0x3174fb('0x2a')][_0x3174fb('0x241d')](_0x541df5[_0x3174fb('0x23a2')],_0x1e6cff)[_0x3174fb('0xe53')]);}function _0x259d20(_0x1deb08,_0x57224e){const _0x4c7079=_0x120bf5;_0x3752f8['show']({'controller':'CreateOrEditDeskAccountDialogController','controllerAs':'vm','templateUrl':_0x122787,'parent':angular[_0x4c7079('0x1fcc')](_0x3dd38f[_0x4c7079('0x18e5')]),'targetEvent':_0x1deb08,'clickOutsideToClose':!![],'locals':{'deskAccount':_0x57224e,'deskAccounts':_0x541df5[_0x4c7079('0x1b12')][_0x4c7079('0xf5d')],'license':_0x541df5[_0x4c7079('0xace')],'setting':_0x541df5[_0x4c7079('0x260a')],'crudPermissions':_0x541df5[_0x4c7079('0x1134')]}});}function _0x2cb4a5(_0x4370ef){const _0x45adc1=_0x120bf5;_0x36f2c6[_0x45adc1('0xe2b')]['delete']({'id':_0x4370ef['id']})['$promise']['then'](function(){const _0x3df1ae=_0x45adc1;_0x2e3ca0()['remove'](_0x541df5['deskAccounts']['rows'],{'id':_0x4370ef['id']}),_0x541df5[_0x3df1ae('0x1b12')][_0x3df1ae('0x50d')]-=0x1,!_0x541df5[_0x3df1ae('0x1b12')][_0x3df1ae('0xf5d')][_0x3df1ae('0x1564')]&&_0x541df5[_0x3df1ae('0xf6e')](),_0x4f980c[_0x3df1ae('0x53')]({'title':_0x2e3ca0()['startCase'](_0x3df1ae('0x4c7'))+'\x20deleted!','msg':_0x4370ef[_0x3df1ae('0x60a')]?_0x4370ef['name']+'\x20has\x20been\x20deleted!':''});})[_0x45adc1('0x130a')](function(_0x5ae978){const _0x5da13d=_0x45adc1;if(_0x5ae978[_0x5da13d('0x5a5')]&&_0x5ae978[_0x5da13d('0x5a5')][_0x5da13d('0x17f')]&&_0x5ae978[_0x5da13d('0x5a5')][_0x5da13d('0x17f')]['length']){_0x541df5[_0x5da13d('0x17f')]=_0x5ae978[_0x5da13d('0x5a5')][_0x5da13d('0x17f')]||[{'message':_0x5ae978['toString'](),'type':_0x5da13d('0x228f')}];for(let _0x385a27=0x0;_0x385a27<_0x5ae978[_0x5da13d('0x5a5')][_0x5da13d('0x17f')][_0x5da13d('0x1564')];_0x385a27++){_0x4f980c['error']({'title':_0x5ae978[_0x5da13d('0x5a5')][_0x5da13d('0x17f')][_0x385a27][_0x5da13d('0xcf0')],'msg':_0x5ae978['data'][_0x5da13d('0x17f')][_0x385a27][_0x5da13d('0x8c2')]});}}else _0x4f980c['error']({'title':_0x5ae978[_0x5da13d('0x13ee')]?_0x5da13d('0x2168')+_0x5ae978[_0x5da13d('0x13ee')]+'\x20-\x20'+_0x5ae978['statusText']:_0x5da13d('0x228f'),'msg':_0x5ae978[_0x5da13d('0x5a5')]?JSON[_0x5da13d('0x258a')](_0x5ae978[_0x5da13d('0x5a5')][_0x5da13d('0x8c2')]):_0x5ae978['message']||_0x5ae978[_0x5da13d('0x1ff0')]()});});}function _0x536cd2(){const _0x406764=_0x120bf5,_0x1edffb=angular[_0x406764('0x1a86')](_0x541df5[_0x406764('0x18f8')]);return _0x541df5[_0x406764('0x18f8')]=[],_0x1edffb;}function _0x57e564(_0x1a53f0){const _0x313fd6=_0x120bf5,_0xf81b77=_0x3752f8[_0x313fd6('0x1c6f')]()['title'](_0x313fd6('0xd8d'))[_0x313fd6('0x26e3')](_0x313fd6('0xed5')+_0x541df5[_0x313fd6('0x18f8')]['length']+_0x313fd6('0x93c')+_0x313fd6('0x1ee7'))[_0x313fd6('0x1040')](_0x313fd6('0x17cf'))[_0x313fd6('0xe42')](_0x1a53f0)['ok']('OK')['cancel']('CANCEL');_0x3752f8['show'](_0xf81b77)[_0x313fd6('0x683')](function(){const _0x242b14=_0x313fd6;_0x541df5[_0x242b14('0x18f8')][_0x242b14('0x1299')](function(_0x24eaf9){_0x2cb4a5(_0x24eaf9);}),_0x541df5['selectedDeskAccounts']=[];});}function _0x3dfca2(){const _0x3be799=_0x120bf5;_0x541df5[_0x3be799('0x18f8')]=[];}function _0xc98df3(){const _0x384dbf=_0x120bf5;_0x541df5[_0x384dbf('0x18f8')]=_0x541df5[_0x384dbf('0x1b12')][_0x384dbf('0xf5d')];}}const _0x59bd2a=_0x59b854,_0x33096c=_0x180212['p']+_0x189033('0x1ca7'),_0x119507=_0x180212['p']+_0x189033('0xf96');_0xcb933e['$inject']=[_0x189033('0x1e48'),'$document',_0x189033('0x56b'),'toasty',_0x189033('0xba1')];function _0xcb933e(_0x114ce4,_0x30b842,_0x1af64b,_0x4f36b6,_0x379605){const _0x3897e9=_0x189033,_0x269450=this;_0x269450[_0x3897e9('0x11ed')]=_0x379605['getCurrentUser'](),_0x269450[_0x3897e9('0x194e')]={},_0x269450[_0x3897e9('0x23bc')]={},_0x269450[_0x3897e9('0x1573')]=[],_0x269450['selectedDeskConfiguration']=-0x1,_0x269450[_0x3897e9('0x1134')],_0x269450[_0x3897e9('0x12f3')]=_0x51b668,_0x269450[_0x3897e9('0x964')]=_0x4c3306,_0x269450[_0x3897e9('0x33e')]=_0x5ee642,_0x269450[_0x3897e9('0x1eb3')]=_0x3471f1,_0x269450[_0x3897e9('0x2100')]=[],_0x269450[_0x3897e9('0x20fd')]=_0x229159,_0x1af64b['tag'][_0x3897e9('0x1e6e')]({'nolimit':!![],'sort':_0x3897e9('0x60a')})[_0x3897e9('0xe53')][_0x3897e9('0x683')](function(_0x3d88ef){const _0x2a9e3d=_0x3897e9;_0x269450[_0x2a9e3d('0x1ce6')]=_0x3d88ef[_0x2a9e3d('0xf5d')]?_0x3d88ef['rows']:[];})['catch'](function(_0x19d0f0){const _0x1e2c91=_0x3897e9;_0x4f36b6[_0x1e2c91('0x52a')]({'title':_0x19d0f0[_0x1e2c91('0x13ee')]?'API:'+_0x19d0f0[_0x1e2c91('0x13ee')]+_0x1e2c91('0xbf6')+_0x19d0f0[_0x1e2c91('0x24a9')]:_0x1e2c91('0x10a4'),'msg':_0x19d0f0[_0x1e2c91('0x5a5')]?JSON[_0x1e2c91('0x258a')](_0x19d0f0[_0x1e2c91('0x5a5')]):_0x19d0f0['toString']()});});function _0x229159(){const _0x5ae2f5=_0x3897e9;_0x1af64b[_0x5ae2f5('0x2451')]['setTags']({'id':_0x269450['deskConfiguration']['id'],'ids':_0x269450[_0x5ae2f5('0x2100')]})[_0x5ae2f5('0xe53')]['then'](function(){const _0x35dd0e=_0x5ae2f5;_0x4f36b6[_0x35dd0e('0x53')]({'title':_0x35dd0e('0xc9b'),'msg':_0x35dd0e('0xfc3')});})[_0x5ae2f5('0x130a')](function(_0x53c4c3){const _0x4afce9=_0x5ae2f5;_0x4f36b6[_0x4afce9('0x52a')]({'title':_0x53c4c3[_0x4afce9('0x13ee')]?_0x4afce9('0x2168')+_0x53c4c3['status']+_0x4afce9('0xbf6')+_0x53c4c3['statusText']:_0x4afce9('0x137d'),'msg':_0x53c4c3[_0x4afce9('0x5a5')]?JSON[_0x4afce9('0x258a')](_0x53c4c3[_0x4afce9('0x5a5')]):_0x53c4c3[_0x4afce9('0x1ff0')]()});});}function _0x51b668(_0x439557,_0x2f07fb){const _0x25ce64=_0x3897e9;_0x269450[_0x25ce64('0x194e')]=_0x439557,_0x269450[_0x25ce64('0x1134')]=typeof _0x2f07fb!==_0x25ce64('0x1867')?_0x2f07fb:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1af64b[_0x25ce64('0xe2b')][_0x25ce64('0x1575')]({'id':_0x269450[_0x25ce64('0x194e')]['id'],'sort':_0x25ce64('0xc36')})[_0x25ce64('0xe53')][_0x25ce64('0x683')](function(_0x45bce4){const _0x19c744=_0x25ce64;return _0x269450[_0x19c744('0x1573')]=_0x45bce4[_0x19c744('0xf5d')]?_0x45bce4[_0x19c744('0xf5d')]:[],_0x269450['configurations'][_0x19c744('0x1564')]&&_0x269450[_0x19c744('0x964')](0x0),_0x1af64b[_0x19c744('0x26e0')][_0x19c744('0x1e6e')]({'nolimit':!![],'sort':'name'})[_0x19c744('0xe53')];})[_0x25ce64('0x683')](function(_0x343a29){const _0x1387ff=_0x25ce64;_0x269450['variables']=_0x343a29['rows']?_0x343a29[_0x1387ff('0xf5d')]:[],_0x269450[_0x1387ff('0x1822')]=_0x2e3ca0()['keyBy'](_0x269450[_0x1387ff('0x220b')],'id');})[_0x25ce64('0x130a')](function(_0x470d0f){const _0x14d283=_0x25ce64;_0x4f36b6['error']({'title':_0x470d0f[_0x14d283('0x13ee')]?_0x14d283('0x2168')+_0x470d0f[_0x14d283('0x13ee')]+_0x14d283('0xbf6')+_0x470d0f['statusText']:_0x14d283('0xe2a'),'msg':_0x470d0f[_0x14d283('0x5a5')]?JSON[_0x14d283('0x258a')](_0x470d0f['data']):_0x470d0f['toString']()});});}function _0x4c3306(_0x46ab0c){const _0x37390d=_0x3897e9;_0x269450[_0x37390d('0x23bc')]=_0x269450['configurations'][_0x46ab0c],_0x269450[_0x37390d('0x1b19')]=_0x46ab0c,_0x1af64b[_0x37390d('0x2451')][_0x37390d('0x20ac')]({'id':_0x269450[_0x37390d('0x23bc')]['id']})[_0x37390d('0xe53')]['then'](function(_0x124d92){const _0x2728c4=_0x37390d;return _0x269450['subjects']=_0x124d92[_0x2728c4('0xf5d')]?_0x124d92[_0x2728c4('0xf5d')]:[],_0x1af64b['intDeskConfiguration'][_0x2728c4('0x412')]({'id':_0x269450[_0x2728c4('0x23bc')]['id']})[_0x2728c4('0xe53')];})[_0x37390d('0x683')](function(_0x529d8e){const _0x1f83ea=_0x37390d;return _0x269450['descriptions']=_0x529d8e[_0x1f83ea('0xf5d')]?_0x529d8e['rows']:[],_0x1af64b[_0x1f83ea('0x2451')]['getFields']({'id':_0x269450[_0x1f83ea('0x23bc')]['id']})[_0x1f83ea('0xe53')];})[_0x37390d('0x683')](function(_0x61e96a){_0x269450['fields']=_0x61e96a['rows']?_0x61e96a['rows']:[];})[_0x37390d('0x130a')](function(_0x1d4b3f){const _0x21906a=_0x37390d;_0x4f36b6[_0x21906a('0x52a')]({'title':_0x1d4b3f['status']?_0x21906a('0x2168')+_0x1d4b3f[_0x21906a('0x13ee')]+_0x21906a('0xbf6')+_0x1d4b3f[_0x21906a('0x24a9')]:_0x21906a('0x167c'),'msg':_0x1d4b3f[_0x21906a('0x5a5')]?JSON[_0x21906a('0x258a')](_0x1d4b3f[_0x21906a('0x5a5')]):_0x1d4b3f['toString']()});}),_0x1af64b[_0x37390d('0x2451')]['getTags']({'id':_0x269450['deskConfiguration']['id']})[_0x37390d('0xe53')][_0x37390d('0x683')](function(_0x1071f7){const _0x12787a=_0x37390d;_0x269450[_0x12787a('0x2100')]=_0x1071f7['rows']?_0x2e3ca0()[_0x12787a('0x386')](_0x1071f7[_0x12787a('0xf5d')],'id'):[];})['catch'](function(_0x209176){const _0x33949f=_0x37390d;_0x4f36b6[_0x33949f('0x52a')]({'title':_0x209176[_0x33949f('0x13ee')]?'API:'+_0x209176[_0x33949f('0x13ee')]+'\x20-\x20'+_0x209176[_0x33949f('0x24a9')]:_0x33949f('0x10a4'),'msg':_0x209176['data']?JSON['stringify'](_0x209176[_0x33949f('0x5a5')]):_0x209176['toString']()});});}function _0x5ee642(_0x4028a8,_0x51d5ed){const _0x5e2e8b=_0x3897e9;_0x114ce4[_0x5e2e8b('0x1d4')]({'controller':_0x5e2e8b('0x1900'),'controllerAs':'vm','templateUrl':_0x33096c,'parent':angular[_0x5e2e8b('0x1fcc')](_0x30b842['body']),'targetEvent':_0x4028a8,'clickOutsideToClose':!![],'locals':{'deskConfiguration':_0x51d5ed,'configurations':_0x269450[_0x5e2e8b('0x1573')],'license':null,'setting':null,'crudPermissions':_0x269450[_0x5e2e8b('0x1134')]}})[_0x5e2e8b('0x2874')](function(){const _0x2760d3=_0x5e2e8b;_0x269450[_0x2760d3('0x964')](0x0);});}function _0x3471f1(_0x5499a5,_0x24fbe3){const _0x3e1a4e=_0x3897e9,_0x25d065=_0x114ce4[_0x3e1a4e('0x1c6f')]()['title'](_0x3e1a4e('0xadf'))[_0x3e1a4e('0x26e3')](_0x3e1a4e('0xed5')+(_0x24fbe3[_0x3e1a4e('0x60a')]||_0x3e1a4e('0x23bc'))+_0x3e1a4e('0x20f1')+_0x3e1a4e('0x1ee7'))[_0x3e1a4e('0x1040')](_0x3e1a4e('0x582'))[_0x3e1a4e('0xe42')](_0x5499a5)['ok']('OK')[_0x3e1a4e('0x19fb')](_0x3e1a4e('0x16b8'));_0x114ce4['show'](_0x25d065)[_0x3e1a4e('0x683')](function(){const _0x2f9c03=_0x3e1a4e;_0x1af64b['intDeskConfiguration'][_0x2f9c03('0xd7e')]({'id':_0x24fbe3['id']})['$promise']['then'](function(){const _0x4c25bc=_0x2f9c03;_0x2e3ca0()['remove'](_0x269450[_0x4c25bc('0x1573')],{'id':_0x24fbe3['id']}),_0x4f36b6[_0x4c25bc('0x53')]({'title':_0x4c25bc('0x7db'),'msg':_0x24fbe3[_0x4c25bc('0x60a')]?_0x24fbe3[_0x4c25bc('0x60a')]+_0x4c25bc('0x194d'):''});})['catch'](function(_0x5a0226){const _0x3783d0=_0x2f9c03;_0x4f36b6['error']({'title':_0x5a0226[_0x3783d0('0x13ee')]?_0x3783d0('0x2168')+_0x5a0226[_0x3783d0('0x13ee')]+'\x20-\x20'+_0x5a0226[_0x3783d0('0x24a9')]:_0x3783d0('0x1e44'),'msg':_0x5a0226['data']?JSON[_0x3783d0('0x258a')](_0x5a0226['data']):_0x5a0226[_0x3783d0('0x1ff0')]()});})[_0x2f9c03('0x2874')](function(){const _0x65f887=_0x2f9c03;_0x269450[_0x65f887('0x964')](0x0);});},function(){const _0x43ed06=_0x3e1a4e;console[_0x43ed06('0x1b2b')](_0x43ed06('0x16b8'));});}_0x269450[_0x3897e9('0x1781')]=[],_0x269450[_0x3897e9('0x2654')]=_0xddf6fa,_0x269450[_0x3897e9('0x2802')]=_0x4f18f4,_0x269450[_0x3897e9('0x1734')]=_0x56ab8d;function _0xddf6fa(_0x20a656,_0x299866){const _0x2f1bc0=_0x3897e9;_0x114ce4[_0x2f1bc0('0x1d4')]({'controller':_0x2f1bc0('0xec5'),'controllerAs':'vm','templateUrl':_0x119507,'parent':angular[_0x2f1bc0('0x1fcc')](_0x30b842[_0x2f1bc0('0x18e5')]),'targetEvent':_0x20a656,'clickOutsideToClose':!![],'locals':{'type':_0x2f1bc0('0x1e66'),'item':_0x299866,'items':_0x269450['subjects'],'configuration':_0x269450[_0x2f1bc0('0x23bc')],'account':_0x269450[_0x2f1bc0('0x194e')],'license':null,'setting':null,'crudPermissions':_0x269450[_0x2f1bc0('0x1134')]}});}function _0x32fd13(_0x37a59e){const _0x583832=_0x3897e9;_0x1af64b['intDeskField']['delete']({'id':_0x37a59e['id']})[_0x583832('0xe53')][_0x583832('0x683')](function(){const _0x57b4d8=_0x583832;_0x2e3ca0()['remove'](_0x269450[_0x57b4d8('0x1ead')],{'id':_0x37a59e['id']}),_0x4f36b6[_0x57b4d8('0x53')]({'title':_0x57b4d8('0x637'),'msg':_0x57b4d8('0x2795')});})[_0x583832('0x130a')](function(_0x644427){const _0x3ad20c=_0x583832;_0x4f36b6[_0x3ad20c('0x52a')]({'title':_0x644427[_0x3ad20c('0x13ee')]?_0x3ad20c('0x2168')+_0x644427[_0x3ad20c('0x13ee')]+_0x3ad20c('0xbf6')+_0x644427[_0x3ad20c('0x24a9')]:_0x3ad20c('0x1d23'),'msg':_0x644427[_0x3ad20c('0x5a5')]?JSON[_0x3ad20c('0x258a')](_0x644427[_0x3ad20c('0x5a5')]):_0x644427[_0x3ad20c('0x1ff0')]()});});}function _0x4f18f4(_0x23d65a,_0x4facd1){const _0x2a10b9=_0x3897e9,_0x164c7c=_0x114ce4[_0x2a10b9('0x1c6f')]()[_0x2a10b9('0xf28')](_0x2a10b9('0x17ed'))['htmlContent'](_0x2a10b9('0x601')+_0x2a10b9('0x1ee7'))[_0x2a10b9('0x1040')](_0x2a10b9('0x20d'))[_0x2a10b9('0xe42')](_0x23d65a)['ok']('OK')[_0x2a10b9('0x19fb')](_0x2a10b9('0x16b8'));_0x114ce4['show'](_0x164c7c)[_0x2a10b9('0x683')](function(){_0x32fd13(_0x4facd1);},function(){const _0x53eda6=_0x2a10b9;console['log'](_0x53eda6('0x16b8'));});}function _0x56ab8d(_0x1f829d){const _0x2a93e7=_0x3897e9,_0x2d8889=_0x114ce4['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20subjects?')[_0x2a93e7('0x26e3')](_0x2a93e7('0xed5')+_0x269450[_0x2a93e7('0x1781')][_0x2a93e7('0x1564')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x2a93e7('0x1040')](_0x2a93e7('0x9fb'))[_0x2a93e7('0xe42')](_0x1f829d)['ok']('OK')[_0x2a93e7('0x19fb')](_0x2a93e7('0x16b8'));_0x114ce4[_0x2a93e7('0x1d4')](_0x2d8889)[_0x2a93e7('0x683')](function(){const _0x4983fd=_0x2a93e7;_0x269450['selectedSubjects']['forEach'](function(_0x312a7b){_0x32fd13(_0x312a7b);}),_0x269450[_0x4983fd('0x1781')]=[];});}_0x269450[_0x3897e9('0xcb1')]=[],_0x269450[_0x3897e9('0x1094')]=_0x3150c6,_0x269450[_0x3897e9('0x27b2')]=_0x354930,_0x269450['deleteSelectedDescriptions']=_0x2e90ac;function _0x3150c6(_0x5c55f1,_0x50d9ae){const _0x1a5ad5=_0x3897e9;_0x114ce4[_0x1a5ad5('0x1d4')]({'controller':_0x1a5ad5('0xec5'),'controllerAs':'vm','templateUrl':_0x119507,'parent':angular[_0x1a5ad5('0x1fcc')](_0x30b842['body']),'targetEvent':_0x5c55f1,'clickOutsideToClose':!![],'locals':{'type':_0x1a5ad5('0xd6b'),'item':_0x50d9ae,'items':_0x269450[_0x1a5ad5('0x18f7')],'configuration':_0x269450[_0x1a5ad5('0x23bc')],'account':_0x269450[_0x1a5ad5('0x194e')],'license':null,'setting':null,'crudPermissions':_0x269450[_0x1a5ad5('0x1134')]}});}function _0x13b67e(_0x23a3d4){const _0x3d7919=_0x3897e9;_0x1af64b['intDeskField'][_0x3d7919('0xd7e')]({'id':_0x23a3d4['id']})[_0x3d7919('0xe53')]['then'](function(){const _0x3e31c6=_0x3d7919;_0x2e3ca0()[_0x3e31c6('0x3ec')](_0x269450['descriptions'],{'id':_0x23a3d4['id']}),_0x4f36b6[_0x3e31c6('0x53')]({'title':_0x3e31c6('0x1cf8'),'msg':_0x3e31c6('0x21c7')});})[_0x3d7919('0x130a')](function(_0x38e48f){const _0x29d4c4=_0x3d7919;_0x4f36b6['error']({'title':_0x38e48f[_0x29d4c4('0x13ee')]?_0x29d4c4('0x2168')+_0x38e48f[_0x29d4c4('0x13ee')]+_0x29d4c4('0xbf6')+_0x38e48f['statusText']:_0x29d4c4('0x1d23'),'msg':_0x38e48f[_0x29d4c4('0x5a5')]?JSON[_0x29d4c4('0x258a')](_0x38e48f['data']):_0x38e48f['toString']()});});}function _0x354930(_0x55a2a6,_0x4c2a64){const _0x2a02c3=_0x3897e9,_0x2832d6=_0x114ce4[_0x2a02c3('0x1c6f')]()[_0x2a02c3('0xf28')](_0x2a02c3('0xb72'))['htmlContent'](_0x2a02c3('0xd5e')+_0x2a02c3('0x1ee7'))[_0x2a02c3('0x1040')](_0x2a02c3('0x221c'))[_0x2a02c3('0xe42')](_0x55a2a6)['ok']('OK')[_0x2a02c3('0x19fb')](_0x2a02c3('0x16b8'));_0x114ce4['show'](_0x2832d6)[_0x2a02c3('0x683')](function(){_0x13b67e(_0x4c2a64);},function(){const _0x2c9c06=_0x2a02c3;console[_0x2c9c06('0x1b2b')](_0x2c9c06('0x16b8'));});}function _0x2e90ac(_0x393b90){const _0x437273=_0x3897e9,_0x215064=_0x114ce4[_0x437273('0x1c6f')]()[_0x437273('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20descriptions?')[_0x437273('0x26e3')](_0x437273('0xed5')+_0x269450[_0x437273('0xcb1')][_0x437273('0x1564')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x437273('0x1040')]('delete\x20descriptions')[_0x437273('0xe42')](_0x393b90)['ok']('OK')[_0x437273('0x19fb')](_0x437273('0x16b8'));_0x114ce4[_0x437273('0x1d4')](_0x215064)[_0x437273('0x683')](function(){const _0xda45a3=_0x437273;_0x269450['selectedDescriptions']['forEach'](function(_0x1f00e1){_0x13b67e(_0x1f00e1);}),_0x269450[_0xda45a3('0xcb1')]=[];});}_0x269450[_0x3897e9('0x310')]=[],_0x269450[_0x3897e9('0x84f')]=_0x14d2d3,_0x269450['deleteFieldConfirm']=_0x117952,_0x269450[_0x3897e9('0x204e')]=_0x19a7b2;function _0x14d2d3(_0x1dad0c,_0x4f3be0){const _0x495b71=_0x3897e9;_0x114ce4[_0x495b71('0x1d4')]({'controller':_0x495b71('0xec5'),'controllerAs':'vm','templateUrl':_0x119507,'parent':angular[_0x495b71('0x1fcc')](_0x30b842[_0x495b71('0x18e5')]),'targetEvent':_0x1dad0c,'clickOutsideToClose':!![],'locals':{'type':_0x495b71('0x2013'),'item':_0x4f3be0,'items':_0x269450['fields'],'configuration':_0x269450[_0x495b71('0x23bc')],'account':_0x269450[_0x495b71('0x194e')],'license':null,'setting':null,'crudPermissions':_0x269450[_0x495b71('0x1134')]}});}function _0x1144ba(_0x11a364){const _0x5258d8=_0x3897e9;_0x1af64b[_0x5258d8('0x24ec')]['delete']({'id':_0x11a364['id']})[_0x5258d8('0xe53')][_0x5258d8('0x683')](function(){const _0x106ef1=_0x5258d8;_0x2e3ca0()['remove'](_0x269450['fields'],{'id':_0x11a364['id']}),_0x4f36b6['success']({'title':_0x106ef1('0x1666'),'msg':'Field\x20has\x20been\x20deleted!'});})['catch'](function(_0x20ef14){const _0x311bce=_0x5258d8;_0x4f36b6[_0x311bce('0x52a')]({'title':_0x20ef14[_0x311bce('0x13ee')]?'API:'+_0x20ef14['status']+_0x311bce('0xbf6')+_0x20ef14[_0x311bce('0x24a9')]:_0x311bce('0x1d23'),'msg':_0x20ef14['data']?JSON[_0x311bce('0x258a')](_0x20ef14[_0x311bce('0x5a5')]):_0x20ef14['toString']()});});}function _0x117952(_0x2519f0,_0x42a5e9){const _0x252fbd=_0x3897e9,_0x15e72e=_0x114ce4[_0x252fbd('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x252fbd('0x26e3')](_0x252fbd('0x23b9')+_0x252fbd('0x1ee7'))[_0x252fbd('0x1040')]('delete\x20field')[_0x252fbd('0xe42')](_0x2519f0)['ok']('OK')[_0x252fbd('0x19fb')]('CANCEL');_0x114ce4['show'](_0x15e72e)['then'](function(){_0x1144ba(_0x42a5e9);},function(){const _0x4a9674=_0x252fbd;console[_0x4a9674('0x1b2b')](_0x4a9674('0x16b8'));});}function _0x19a7b2(_0x36ccf3){const _0x3b2f26=_0x3897e9,_0x4a97be=_0x114ce4[_0x3b2f26('0x1c6f')]()[_0x3b2f26('0xf28')](_0x3b2f26('0x19b1'))[_0x3b2f26('0x26e3')](_0x3b2f26('0xed5')+_0x269450[_0x3b2f26('0x310')]['length']+'\x20selected'+_0x3b2f26('0x1ee7'))[_0x3b2f26('0x1040')](_0x3b2f26('0x994'))[_0x3b2f26('0xe42')](_0x36ccf3)['ok']('OK')[_0x3b2f26('0x19fb')]('CANCEL');_0x114ce4[_0x3b2f26('0x1d4')](_0x4a97be)[_0x3b2f26('0x683')](function(){const _0x46a2bc=_0x3b2f26;_0x269450['selectedFields'][_0x46a2bc('0x1299')](function(_0x1ced00){_0x1144ba(_0x1ced00);}),_0x269450[_0x46a2bc('0x310')]=[];});}}const _0x3361c4=_0xcb933e;_0x5f5c31['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty',_0x189033('0x1573'),_0x189033('0x23bc'),'api',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x5f5c31(_0x42a0c9,_0x421b70,_0x530099,_0x49a3eb,_0x1d534d,_0x26b8a2,_0x38d7b0,_0x24fcb0,_0x46b4a2,_0x4dde5d,_0x355f1a,_0x122dc0,_0xa5da72,_0x4b0bae){const _0xb86684=_0x189033,_0x167d5e=this;_0x167d5e[_0xb86684('0x11ed')]=_0x355f1a[_0xb86684('0x20b2')](),_0x167d5e[_0xb86684('0x17f')]=[],_0x167d5e['setting']=_0xa5da72,_0x167d5e[_0xb86684('0xace')]=_0x122dc0,_0x167d5e[_0xb86684('0x1134')]=_0x4b0bae,_0x167d5e['hasModulePermissions']={},_0x167d5e[_0xb86684('0x19b2')]=_0x167d5e[_0xb86684('0x260a')]&&_0x167d5e[_0xb86684('0x260a')][_0xb86684('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x167d5e[_0xb86684('0xf28')]=_0xb86684('0x1304'),_0x167d5e[_0xb86684('0x23bc')]=angular['copy'](_0x46b4a2),_0x167d5e[_0xb86684('0x1573')]=_0x24fcb0,_0x167d5e[_0xb86684('0x33b')]=![];!_0x167d5e[_0xb86684('0x23bc')]&&(_0x167d5e[_0xb86684('0x23bc')]={'channel':_0xb86684('0xcf2'),'type':_0xb86684('0x1535')},_0x167d5e[_0xb86684('0xf28')]=_0xb86684('0x23d2'),_0x167d5e[_0xb86684('0x33b')]=!![]);_0x167d5e[_0xb86684('0xeb7')]=_0x127ae7,_0x167d5e[_0xb86684('0xaf2')]=_0x21e5b0,_0x167d5e['deleteDeskConfiguration']=_0x245f36,_0x167d5e[_0xb86684('0x16b3')]=_0x274065,_0x167d5e[_0xb86684('0xf82')]=_0x563ec4;function _0x127ae7(){const _0x252ab4=_0xb86684;_0x167d5e[_0x252ab4('0x17f')]=[],_0x4dde5d[_0x252ab4('0xe2b')][_0x252ab4('0x2003')]({'id':_0x421b70['params']['id']},_0x167d5e[_0x252ab4('0x23bc')])['$promise'][_0x252ab4('0x683')](function(_0x380509){const _0x52a98f=_0x252ab4;_0x167d5e[_0x52a98f('0x1573')]['unshift'](_0x380509[_0x52a98f('0x24e1')]()),_0x38d7b0[_0x52a98f('0x53')]({'title':_0x52a98f('0x2359'),'msg':_0x167d5e['deskConfiguration'][_0x52a98f('0x60a')]?_0x167d5e['deskConfiguration'][_0x52a98f('0x60a')]+_0x52a98f('0x14b5'):''}),_0x563ec4(_0x380509);})[_0x252ab4('0x130a')](function(_0x1cb4c8){const _0x1670cf=_0x252ab4;if(_0x1cb4c8[_0x1670cf('0x5a5')]&&_0x1cb4c8[_0x1670cf('0x5a5')][_0x1670cf('0x17f')]&&_0x1cb4c8['data'][_0x1670cf('0x17f')]['length']){_0x167d5e[_0x1670cf('0x17f')]=_0x1cb4c8['data'][_0x1670cf('0x17f')]||[{'message':_0x1cb4c8['toString'](),'type':_0x1670cf('0xe4b')}];for(let _0x439719=0x0;_0x439719<_0x1cb4c8[_0x1670cf('0x5a5')][_0x1670cf('0x17f')][_0x1670cf('0x1564')];_0x439719+=0x1){_0x38d7b0[_0x1670cf('0x52a')]({'title':_0x1cb4c8[_0x1670cf('0x5a5')]['errors'][_0x439719][_0x1670cf('0xcf0')],'msg':_0x1cb4c8[_0x1670cf('0x5a5')][_0x1670cf('0x17f')][_0x439719][_0x1670cf('0x8c2')]});}}else _0x38d7b0[_0x1670cf('0x52a')]({'title':_0x1cb4c8['status']?_0x1670cf('0x2168')+_0x1cb4c8[_0x1670cf('0x13ee')]+'\x20-\x20'+_0x1cb4c8[_0x1670cf('0x24a9')]:'api.intDeskConfiguration.save','msg':_0x1cb4c8[_0x1670cf('0x5a5')]?JSON['stringify'](_0x1cb4c8[_0x1670cf('0x5a5')][_0x1670cf('0x8c2')]):_0x1cb4c8[_0x1670cf('0x1ff0')]()});});}function _0x21e5b0(){const _0x270e0e=_0xb86684;_0x167d5e['errors']=[],_0x4dde5d['intDeskConfiguration'][_0x270e0e('0x2480')]({'id':_0x167d5e[_0x270e0e('0x23bc')]['id']},_0x167d5e['deskConfiguration'])[_0x270e0e('0xe53')]['then'](function(_0x335415){const _0x5f76b3=_0x270e0e,_0x2a1b7e=_0x2e3ca0()['find'](_0x167d5e[_0x5f76b3('0x1573')],{'id':_0x335415['id']});_0x2a1b7e&&_0x2e3ca0()[_0x5f76b3('0xf22')](_0x2a1b7e,_0x2e3ca0()[_0x5f76b3('0x24d0')](_0x335415[_0x5f76b3('0x24e1')](),_0x2e3ca0()[_0x5f76b3('0x55e')](_0x2a1b7e))),_0x38d7b0[_0x5f76b3('0x53')]({'title':_0x5f76b3('0x1db5'),'msg':_0x167d5e[_0x5f76b3('0x23bc')][_0x5f76b3('0x60a')]?_0x167d5e[_0x5f76b3('0x23bc')]['name']+_0x5f76b3('0xf59'):''}),_0x563ec4(_0x335415);})[_0x270e0e('0x130a')](function(_0x1bc3d8){const _0x1b7c7d=_0x270e0e;if(_0x1bc3d8[_0x1b7c7d('0x5a5')]&&_0x1bc3d8['data'][_0x1b7c7d('0x17f')]&&_0x1bc3d8[_0x1b7c7d('0x5a5')][_0x1b7c7d('0x17f')][_0x1b7c7d('0x1564')]){_0x167d5e[_0x1b7c7d('0x17f')]=_0x1bc3d8[_0x1b7c7d('0x5a5')]['errors']||[{'message':_0x1bc3d8[_0x1b7c7d('0x1ff0')](),'type':_0x1b7c7d('0x26e')}];for(let _0x51f96d=0x0;_0x51f96d<_0x1bc3d8[_0x1b7c7d('0x5a5')][_0x1b7c7d('0x17f')]['length'];_0x51f96d++){_0x38d7b0[_0x1b7c7d('0x52a')]({'title':_0x1bc3d8[_0x1b7c7d('0x5a5')][_0x1b7c7d('0x17f')][_0x51f96d][_0x1b7c7d('0xcf0')],'msg':_0x1bc3d8['data'][_0x1b7c7d('0x17f')][_0x51f96d][_0x1b7c7d('0x8c2')]});}}else _0x38d7b0[_0x1b7c7d('0x52a')]({'title':_0x1bc3d8[_0x1b7c7d('0x13ee')]?'API:'+_0x1bc3d8[_0x1b7c7d('0x13ee')]+'\x20-\x20'+_0x1bc3d8[_0x1b7c7d('0x24a9')]:_0x1b7c7d('0x26e'),'msg':_0x1bc3d8[_0x1b7c7d('0x5a5')]?JSON['stringify'](_0x1bc3d8[_0x1b7c7d('0x5a5')][_0x1b7c7d('0x8c2')]):_0x1bc3d8[_0x1b7c7d('0x1ff0')]()});});}function _0x245f36(_0x69c5a2){const _0x50978f=_0xb86684;_0x167d5e['errors']=[];const _0x40ba55=_0x49a3eb['confirm']()[_0x50978f('0xf28')](_0x50978f('0x4d'))[_0x50978f('0xa6a')]('The\x20deskConfiguration\x20will\x20be\x20deleted.')['ariaLabel'](_0x50978f('0x108f'))['ok']('Delete')[_0x50978f('0x19fb')](_0x50978f('0x253a'))[_0x50978f('0xe42')](_0x69c5a2);_0x49a3eb[_0x50978f('0x1d4')](_0x40ba55)['then'](function(){const _0x482ba3=_0x50978f;_0x4dde5d[_0x482ba3('0x2451')][_0x482ba3('0xd7e')]({'id':_0x167d5e['deskConfiguration']['id']})[_0x482ba3('0xe53')][_0x482ba3('0x683')](function(){const _0x5c593d=_0x482ba3;_0x2e3ca0()['remove'](_0x167d5e[_0x5c593d('0x1573')],{'id':_0x167d5e['deskConfiguration']['id']}),_0x38d7b0[_0x5c593d('0x53')]({'title':'DeskConfiguration\x20properly\x20deleted!','msg':(_0x167d5e[_0x5c593d('0x23bc')][_0x5c593d('0x60a')]||_0x5c593d('0x23bc'))+_0x5c593d('0x194d')}),_0x563ec4(_0x167d5e['deskConfiguration']);})[_0x482ba3('0x130a')](function(_0x1be2c6){const _0x44bc6b=_0x482ba3;if(_0x1be2c6[_0x44bc6b('0x5a5')]&&_0x1be2c6[_0x44bc6b('0x5a5')][_0x44bc6b('0x17f')]&&_0x1be2c6[_0x44bc6b('0x5a5')][_0x44bc6b('0x17f')]['length']){_0x167d5e[_0x44bc6b('0x17f')]=_0x1be2c6[_0x44bc6b('0x5a5')][_0x44bc6b('0x17f')]||[{'message':_0x1be2c6['toString'](),'type':_0x44bc6b('0x191a')}];for(let _0x530058=0x0;_0x530058<_0x1be2c6[_0x44bc6b('0x5a5')]['errors'][_0x44bc6b('0x1564')];_0x530058++){_0x38d7b0[_0x44bc6b('0x52a')]({'title':_0x1be2c6['data']['errors'][_0x530058]['type'],'msg':_0x1be2c6[_0x44bc6b('0x5a5')][_0x44bc6b('0x17f')][_0x530058][_0x44bc6b('0x8c2')]});}}else _0x38d7b0[_0x44bc6b('0x52a')]({'title':_0x1be2c6[_0x44bc6b('0x13ee')]?_0x44bc6b('0x2168')+_0x1be2c6['status']+_0x44bc6b('0xbf6')+_0x1be2c6[_0x44bc6b('0x24a9')]:_0x44bc6b('0x191a'),'msg':_0x1be2c6['data']?JSON[_0x44bc6b('0x258a')](_0x1be2c6[_0x44bc6b('0x5a5')]['message']):_0x1be2c6[_0x44bc6b('0x8c2')]||_0x1be2c6[_0x44bc6b('0x1ff0')]()});});},function(){});}function _0x274065(_0x1269c8){return _0x1269c8===null?undefined:new Date(_0x1269c8);}function _0x563ec4(_0x4dc20c){const _0x307a5a=_0xb86684;_0x49a3eb[_0x307a5a('0x1715')](_0x4dc20c);}}const _0x27bf2d=_0x5f5c31;_0x31e54a[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x1d70'),_0x189033('0x208d'),_0x189033('0x1996'),_0x189033('0x23ef'),'account','type',_0x189033('0x56b'),'Auth','crudPermissions'];function _0x31e54a(_0x26c8f1,_0x52e8e4,_0x2b9d36,_0x12d6c5,_0x1fee6b,_0x501af6,_0x32c749,_0xdcf72a,_0x494d87,_0x1c20a3,_0x10cf0b,_0x5a67fe,_0x2a9b48){const _0x1bbcaf=_0x189033,_0x139d6b=this;_0x139d6b['currentUser']=_0x5a67fe[_0x1bbcaf('0x20b2')](),_0x139d6b['errors']=[],_0x139d6b[_0x1bbcaf('0xf28')]='INTEGRATIONS.EDIT_'+_0x2e3ca0()['toUpper'](_0x1c20a3),_0x139d6b[_0x1bbcaf('0x23ef')]=angular['copy'](_0xdcf72a),_0x139d6b['items']=_0x32c749,_0x139d6b[_0x1bbcaf('0xcf0')]=_0x1c20a3,_0x139d6b[_0x1bbcaf('0x1134')]=_0x2a9b48,_0x139d6b[_0x1bbcaf('0x3d2')]=![];!_0x139d6b['item']&&(_0x139d6b[_0x1bbcaf('0x23ef')]={'type':_0x1bbcaf('0xc06')},_0x139d6b[_0x1bbcaf('0x23ef')][_0x2e3ca0()[_0x1bbcaf('0x21ab')](_0x1c20a3)+'Id']=_0x501af6['id'],_0x139d6b['title']=_0x1bbcaf('0x22de')+_0x2e3ca0()['toUpper'](_0x1c20a3),_0x139d6b[_0x1bbcaf('0x3d2')]=!![]);_0x139d6b[_0x1bbcaf('0x2591')]=_0x4787ba,_0x139d6b[_0x1bbcaf('0x2716')]=_0x4bb59c,_0x139d6b[_0x1bbcaf('0x6b8')]=_0x49d5f5,_0x139d6b['getSelectedVariable']=_0x539cce,_0x139d6b[_0x1bbcaf('0xf82')]=_0x465200,_0x10cf0b[_0x1bbcaf('0x26e0')][_0x1bbcaf('0x1e6e')]({'nolimit':!![]})[_0x1bbcaf('0xe53')]['then'](function(_0x5d00e6){const _0x5ef93b=_0x1bbcaf;return _0x139d6b[_0x5ef93b('0x220b')]=_0x5d00e6[_0x5ef93b('0xf5d')]?_0x5d00e6[_0x5ef93b('0xf5d')]:[],_0x10cf0b[_0x5ef93b('0xf53')][_0x5ef93b('0x2267')]()[_0x5ef93b('0xe53')];})[_0x1bbcaf('0x683')](function(_0x306ca4){const _0x487489=_0x1bbcaf;return _0x139d6b[_0x487489('0x20c1')]=_0x2e3ca0()['difference'](_0x2e3ca0()['keys'](_0x306ca4),['$promise',_0x487489('0x1980'),_0x487489('0x1a4'),_0x487489('0x2000'),_0x487489('0x1d58')]),_0x139d6b[_0x487489('0x20c1')][_0x487489('0x1fd0')](_0x487489('0x1e93')),_0x10cf0b[_0x487489('0x1793')][_0x487489('0x2267')]()[_0x487489('0xe53')];})[_0x1bbcaf('0x683')](function(_0x429449){const _0xcb130e=_0x1bbcaf;_0x139d6b['voiceDialReportColumns']=_0x2e3ca0()[_0xcb130e('0x2829')](_0x2e3ca0()[_0xcb130e('0x55e')](_0x429449),[_0xcb130e('0xe53'),_0xcb130e('0x1980'),_0xcb130e('0x1a4'),_0xcb130e('0x2000'),_0xcb130e('0x1d58')]),_0x139d6b['voiceDialReportColumns'][_0xcb130e('0x1fd0')](_0xcb130e('0x1e93'));})[_0x1bbcaf('0x130a')](function(_0x5a1aab){const _0x3b17a8=_0x1bbcaf;_0x1fee6b['error']({'title':_0x5a1aab['status']?'API:'+_0x5a1aab[_0x3b17a8('0x13ee')]+'\x20-\x20'+_0x5a1aab[_0x3b17a8('0x24a9')]:_0x3b17a8('0x1fd3'),'msg':_0x5a1aab['data']?JSON['stringify'](_0x5a1aab['data']):_0x5a1aab[_0x3b17a8('0x1ff0')]()});}),_0x10cf0b[_0x1bbcaf('0xe2b')][_0x1bbcaf('0x298')]({'id':_0x494d87['id'],'ticketType':_0x501af6[_0x1bbcaf('0x20c9')]?_0x501af6[_0x1bbcaf('0x20c9')]:undefined})[_0x1bbcaf('0xe53')][_0x1bbcaf('0x683')](function(_0x4f5601){const _0x10eb14=_0x1bbcaf;_0x139d6b[_0x10eb14('0xd32')]=!![],_0x139d6b['fields']=_0x4f5601[_0x10eb14('0xf5d')]?_0x4f5601[_0x10eb14('0xf5d')]:[],_0x139d6b[_0x10eb14('0x23ef')][_0x10eb14('0x280')]&&(_0x139d6b[_0x10eb14('0x7f8')]=_0x2e3ca0()[_0x10eb14('0x1c07')](_0x139d6b[_0x10eb14('0x189a')],{'id':_0x139d6b['item'][_0x10eb14('0x280')]}));})[_0x1bbcaf('0x130a')](function(_0x32370a){const _0x2b41e5=_0x1bbcaf;_0x139d6b['accountConnected']=![],console[_0x2b41e5('0x52a')](_0x32370a);});function _0x4787ba(){const _0x3246d8=_0x1bbcaf;_0x139d6b[_0x3246d8('0x17f')]=[],_0x139d6b[_0x3246d8('0x7f8')]&&(_0x139d6b['item'][_0x3246d8('0x280')]=_0x139d6b['customField']['id'],_0x139d6b[_0x3246d8('0x23ef')][_0x3246d8('0x2584')]=_0x139d6b[_0x3246d8('0x7f8')][_0x3246d8('0x60a')],_0x139d6b[_0x3246d8('0x23ef')]['customField']=_0x139d6b[_0x3246d8('0x7f8')][_0x3246d8('0xbf0')]),_0x10cf0b[_0x3246d8('0x24ec')][_0x3246d8('0xb0a')](_0x139d6b[_0x3246d8('0x23ef')])[_0x3246d8('0xe53')][_0x3246d8('0x683')](function(_0x4bdcb1){const _0x1baad0=_0x3246d8;_0x139d6b[_0x1baad0('0x1996')][_0x1baad0('0x1167')](_0x4bdcb1),_0x1fee6b['success']({'title':_0x2e3ca0()[_0x1baad0('0x21ab')](_0x1c20a3)+_0x1baad0('0x282a'),'msg':_0x2e3ca0()['capitalize'](_0x1c20a3)+'\x20has\x20been\x20created!'}),_0x465200();})[_0x3246d8('0x130a')](function(_0x445767){const _0x58e4d1=_0x3246d8;console[_0x58e4d1('0x52a')](_0x445767),_0x139d6b[_0x58e4d1('0x17f')]=_0x445767[_0x58e4d1('0x5a5')][_0x58e4d1('0x17f')]||[{'message':_0x445767[_0x58e4d1('0x1ff0')](),'type':'api.item.save'}];});}function _0x4bb59c(){const _0x449a74=_0x1bbcaf;_0x139d6b[_0x449a74('0x17f')]=[],_0x139d6b[_0x449a74('0x7f8')]&&(_0x139d6b[_0x449a74('0x23ef')][_0x449a74('0x280')]=_0x139d6b['customField']['id'],_0x139d6b[_0x449a74('0x23ef')][_0x449a74('0x2584')]=_0x139d6b[_0x449a74('0x7f8')][_0x449a74('0x60a')],_0x139d6b['item'][_0x449a74('0x7f8')]=_0x139d6b[_0x449a74('0x7f8')][_0x449a74('0xbf0')]),_0x10cf0b[_0x449a74('0x24ec')][_0x449a74('0x2480')]({'id':_0x139d6b[_0x449a74('0x23ef')]['id']},_0x139d6b[_0x449a74('0x23ef')])[_0x449a74('0xe53')][_0x449a74('0x683')](function(_0xe47183){const _0x36ef5b=_0x449a74,_0x330a75=_0x2e3ca0()[_0x36ef5b('0x1c07')](_0x139d6b['items'],{'id':_0xe47183['id']});_0x330a75&&_0x2e3ca0()[_0x36ef5b('0xf22')](_0x330a75,_0xe47183),_0x1fee6b[_0x36ef5b('0x53')]({'title':_0x2e3ca0()['capitalize'](_0x1c20a3)+'\x20properly\x20saved!','msg':_0x2e3ca0()[_0x36ef5b('0x21ab')](_0x1c20a3)+_0x36ef5b('0xf59')}),_0x465200();})['catch'](function(_0x442c8c){const _0x1d0882=_0x449a74;console['error'](_0x442c8c),_0x139d6b['errors']=_0x442c8c['data'][_0x1d0882('0x17f')]||[{'message':_0x442c8c[_0x1d0882('0x1ff0')](),'type':_0x1d0882('0x25d0')}];});}function _0x49d5f5(_0x5656f1){const _0x3549f7=_0x1bbcaf;_0x139d6b[_0x3549f7('0x17f')]=[];const _0x5e948d=_0x12d6c5[_0x3549f7('0x1c6f')]()[_0x3549f7('0xf28')](_0x3549f7('0x4d'))[_0x3549f7('0xa6a')]('The\x20'+_0x1c20a3+_0x3549f7('0x1ee7'))['ariaLabel'](_0x3549f7('0x609')+_0x2e3ca0()[_0x3549f7('0x21ab')](_0x1c20a3))['ok']('Delete')['cancel'](_0x3549f7('0x253a'))['targetEvent'](_0x5656f1);_0x12d6c5[_0x3549f7('0x1d4')](_0x5e948d)[_0x3549f7('0x683')](function(){const _0x21aa51=_0x3549f7;_0x10cf0b[_0x21aa51('0x24ec')][_0x21aa51('0xd7e')]({'id':_0x139d6b[_0x21aa51('0x23ef')]['id']})[_0x21aa51('0xe53')][_0x21aa51('0x683')](function(){const _0x331161=_0x21aa51;_0x2e3ca0()[_0x331161('0x3ec')](_0x139d6b[_0x331161('0x1996')],{'id':_0x139d6b[_0x331161('0x23ef')]['id']}),_0x1fee6b[_0x331161('0x53')]({'title':_0x2e3ca0()[_0x331161('0x21ab')](_0x1c20a3)+_0x331161('0x27d7'),'msg':_0x2e3ca0()[_0x331161('0x21ab')](_0x1c20a3)+_0x331161('0x194d')}),_0x465200();})[_0x21aa51('0x130a')](function(_0x4d98ee){const _0x5ae649=_0x21aa51;console[_0x5ae649('0x52a')](_0x4d98ee),_0x139d6b[_0x5ae649('0x17f')]=_0x4d98ee[_0x5ae649('0x5a5')][_0x5ae649('0x17f')]||[{'message':_0x4d98ee['toString'](),'type':_0x5ae649('0x70c')}];});},function(){});}function _0x539cce(){const _0x6d9d85=_0x1bbcaf;return _0x139d6b['item'][_0x6d9d85('0x113b')]!==undefined?_0x139d6b[_0x6d9d85('0x23ef')][_0x6d9d85('0x113b')]:_0x6d9d85('0xbbf');}function _0x465200(){const _0x498df7=_0x1bbcaf;_0x12d6c5[_0x498df7('0x1715')]();}}const _0xfe546=_0x31e54a;_0x7abab3['$inject']=[_0x189033('0x938'),'$location',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x194e'),'userProfileSection'];function _0x7abab3(_0x35146e,_0x777e07,_0x3b4153,_0x457049,_0x4c77f3,_0x3a8442,_0x37cde3,_0xdb30ec,_0x10ac18,_0x320d1b,_0x49b332,_0x3e5093){const _0x27f61e=_0x189033,_0x22c91d=this;_0x22c91d[_0x27f61e('0x11ed')]=_0x320d1b[_0x27f61e('0x20b2')](),_0x22c91d[_0x27f61e('0xace')]=_0x3a8442,_0x22c91d[_0x27f61e('0x260a')]=_0x37cde3,_0x22c91d[_0x27f61e('0x19b2')]=_0x22c91d['setting'][_0x27f61e('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x22c91d['location']=_0x777e07['protocol']()+'://'+_0x777e07['host'](),_0x22c91d[_0x27f61e('0x194e')]=_0x49b332||_0x35146e[_0x27f61e('0x7f2')][_0x27f61e('0x194e')]||{},_0x22c91d[_0x27f61e('0x22df')]=_0x3e5093&&_0x3e5093[_0x27f61e('0x50d')]==0x1?_0x3e5093[_0x27f61e('0xf5d')][0x0]:null,_0x22c91d[_0x27f61e('0x1134')]=_0x320d1b[_0x27f61e('0x142a')](_0x22c91d[_0x27f61e('0x22df')]?_0x22c91d[_0x27f61e('0x22df')][_0x27f61e('0x1134')]:null),_0x22c91d[_0x27f61e('0x258d')]={},_0x22c91d[_0x27f61e('0x517')]=_0x35146e['params'][_0x27f61e('0x1904')]||0x0,_0x22c91d[_0x27f61e('0x2430')]=_0x10ac18[_0x27f61e('0x2289')],_0x22c91d[_0x27f61e('0xf97')]=_0x4a4089,_0x22c91d[_0x27f61e('0xc1a')]=_0x5740d2;function _0x4a4089(){_0x35146e['go']('app.integrations.deskAccounts',{},{'reload':'app.integrations.deskAccounts'});}function _0x5740d2(){const _0x56ab9d=_0x27f61e;_0xdb30ec[_0x56ab9d('0xe2b')]['update']({'id':_0x22c91d[_0x56ab9d('0x194e')]['id']},_0x22c91d[_0x56ab9d('0x194e')])[_0x56ab9d('0xe53')]['then'](function(){const _0x409fa2=_0x56ab9d;_0x10ac18[_0x409fa2('0x53')]({'title':_0x409fa2('0x1680'),'msg':_0x22c91d[_0x409fa2('0x194e')][_0x409fa2('0x60a')]?_0x22c91d[_0x409fa2('0x194e')][_0x409fa2('0x60a')]+_0x409fa2('0x96c'):''});})[_0x56ab9d('0x130a')](function(_0x98be14){const _0x37f666=_0x56ab9d;_0x10ac18[_0x37f666('0x52a')]({'title':_0x98be14[_0x37f666('0x13ee')]?'API:'+_0x98be14[_0x37f666('0x13ee')]+'\x20-\x20'+_0x98be14[_0x37f666('0x24a9')]:'SYSTEM:GETintDeskAccount','msg':_0x98be14[_0x37f666('0x5a5')]?JSON['stringify'](_0x98be14['data']):_0x98be14[_0x37f666('0x1ff0')]()});});}}const _0x5e36b2=_0x7abab3;_0x18e2f3['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1aa1'),_0x189033('0x239d'),_0x189033('0x56b'),_0x189033('0xba1'),'license','setting',_0x189033('0x1134')];function _0x18e2f3(_0x518fb0,_0x150bdf,_0x577ae5,_0x1d5976,_0x424c89,_0x21da38,_0x375d7a,_0x56a962,_0x4e1c5f,_0x1da2e0,_0x2f49bd,_0xe434d3,_0x35beb9,_0x2d6fcd){const _0x3266a3=_0x189033,_0x686c66=this;_0x686c66[_0x3266a3('0x11ed')]=_0x2f49bd[_0x3266a3('0x20b2')](),_0x686c66[_0x3266a3('0x17f')]=[],_0x686c66[_0x3266a3('0x260a')]=_0x35beb9,_0x686c66[_0x3266a3('0xace')]=_0xe434d3,_0x686c66['crudPermissions']=_0x2d6fcd,_0x686c66[_0x3266a3('0x258d')]={},_0x686c66['passwordPattern']=_0x686c66['setting']&&_0x686c66[_0x3266a3('0x260a')][_0x3266a3('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x686c66[_0x3266a3('0xf28')]=_0x3266a3('0x25b9'),_0x686c66[_0x3266a3('0x239d')]=angular[_0x3266a3('0x1a86')](_0x4e1c5f),_0x686c66[_0x3266a3('0x1aa1')]=_0x56a962,_0x686c66[_0x3266a3('0x1f4b')]=![];!_0x686c66[_0x3266a3('0x239d')]&&(_0x686c66[_0x3266a3('0x239d')]={'serverUrl':_0x577ae5[_0x3266a3('0x173e')]()+'://'+_0x577ae5[_0x3266a3('0x19ac')]()+(_0x577ae5[_0x3266a3('0x4a2')]()?':'+_0x577ae5[_0x3266a3('0x4a2')]():'')},_0x686c66[_0x3266a3('0xf28')]=_0x3266a3('0x173a'),_0x686c66['newDynamics365Account']=!![]);_0x686c66['addNewDynamics365Account']=_0x2781eb,_0x686c66[_0x3266a3('0x2458')]=_0x59c3f8,_0x686c66['deleteDynamics365Account']=_0x575ca2,_0x686c66[_0x3266a3('0x16b3')]=_0x21bcc4,_0x686c66['closeDialog']=_0x3764af;function _0x2781eb(){const _0x41c151=_0x3266a3;_0x686c66[_0x41c151('0x17f')]=[],_0x1da2e0[_0x41c151('0x2601')]['save'](_0x686c66[_0x41c151('0x239d')])[_0x41c151('0xe53')][_0x41c151('0x683')](function(_0x3a1026){const _0x551457=_0x41c151;_0x686c66[_0x551457('0x1aa1')][_0x551457('0x1167')](_0x3a1026[_0x551457('0x24e1')]()),_0x375d7a['success']({'title':_0x551457('0x1489'),'msg':_0x686c66[_0x551457('0x239d')]['name']?_0x686c66['dynamics365Account']['name']+_0x551457('0x14b5'):''}),_0x3764af(_0x3a1026);})[_0x41c151('0x130a')](function(_0x55f101){const _0x1ac218=_0x41c151;if(_0x55f101[_0x1ac218('0x5a5')]&&_0x55f101[_0x1ac218('0x5a5')][_0x1ac218('0x17f')]&&_0x55f101[_0x1ac218('0x5a5')][_0x1ac218('0x17f')]['length']){_0x686c66['errors']=_0x55f101[_0x1ac218('0x5a5')]['errors']||[{'message':_0x55f101[_0x1ac218('0x1ff0')](),'type':_0x1ac218('0x340')}];for(let _0x24362f=0x0;_0x24362f<_0x55f101['data'][_0x1ac218('0x17f')][_0x1ac218('0x1564')];_0x24362f+=0x1){_0x375d7a[_0x1ac218('0x52a')]({'title':_0x55f101['data'][_0x1ac218('0x17f')][_0x24362f]['type'],'msg':_0x55f101[_0x1ac218('0x5a5')][_0x1ac218('0x17f')][_0x24362f][_0x1ac218('0x8c2')]});}}else _0x375d7a[_0x1ac218('0x52a')]({'title':_0x55f101[_0x1ac218('0x13ee')]?_0x1ac218('0x2168')+_0x55f101[_0x1ac218('0x13ee')]+_0x1ac218('0xbf6')+_0x55f101[_0x1ac218('0x24a9')]:_0x1ac218('0x340'),'msg':_0x55f101[_0x1ac218('0x5a5')]?JSON[_0x1ac218('0x258a')](_0x55f101[_0x1ac218('0x5a5')][_0x1ac218('0x8c2')]):_0x55f101['toString']()});});}function _0x59c3f8(){const _0xe4b72=_0x3266a3;_0x686c66['errors']=[],_0x1da2e0[_0xe4b72('0x2601')][_0xe4b72('0x2480')]({'id':_0x686c66[_0xe4b72('0x239d')]['id']},_0x686c66[_0xe4b72('0x239d')])[_0xe4b72('0xe53')][_0xe4b72('0x683')](function(_0x22fa1d){const _0x1363ed=_0xe4b72,_0x32030d=_0x2e3ca0()[_0x1363ed('0x1c07')](_0x686c66[_0x1363ed('0x1aa1')],{'id':_0x22fa1d['id']});_0x32030d&&_0x2e3ca0()[_0x1363ed('0xf22')](_0x32030d,_0x2e3ca0()[_0x1363ed('0x24d0')](_0x22fa1d['toJSON'](),_0x2e3ca0()[_0x1363ed('0x55e')](_0x32030d))),_0x375d7a['success']({'title':_0x1363ed('0x1265'),'msg':_0x686c66['dynamics365Account'][_0x1363ed('0x60a')]?_0x686c66[_0x1363ed('0x239d')][_0x1363ed('0x60a')]+_0x1363ed('0xf59'):''}),_0x3764af(_0x22fa1d);})[_0xe4b72('0x130a')](function(_0x45f67a){const _0x55b3b0=_0xe4b72;if(_0x45f67a[_0x55b3b0('0x5a5')]&&_0x45f67a['data'][_0x55b3b0('0x17f')]&&_0x45f67a['data'][_0x55b3b0('0x17f')][_0x55b3b0('0x1564')]){_0x686c66['errors']=_0x45f67a[_0x55b3b0('0x5a5')][_0x55b3b0('0x17f')]||[{'message':_0x45f67a[_0x55b3b0('0x1ff0')](),'type':_0x55b3b0('0x13b3')}];for(let _0x1804a7=0x0;_0x1804a7<_0x45f67a['data'][_0x55b3b0('0x17f')][_0x55b3b0('0x1564')];_0x1804a7++){_0x375d7a[_0x55b3b0('0x52a')]({'title':_0x45f67a['data'][_0x55b3b0('0x17f')][_0x1804a7][_0x55b3b0('0xcf0')],'msg':_0x45f67a[_0x55b3b0('0x5a5')][_0x55b3b0('0x17f')][_0x1804a7][_0x55b3b0('0x8c2')]});}}else _0x375d7a['error']({'title':_0x45f67a['status']?_0x55b3b0('0x2168')+_0x45f67a[_0x55b3b0('0x13ee')]+_0x55b3b0('0xbf6')+_0x45f67a[_0x55b3b0('0x24a9')]:'api.intDynamics365Account.update','msg':_0x45f67a['data']?JSON['stringify'](_0x45f67a[_0x55b3b0('0x5a5')][_0x55b3b0('0x8c2')]):_0x45f67a[_0x55b3b0('0x1ff0')]()});});}function _0x575ca2(_0x5917ba){const _0x169977=_0x3266a3;_0x686c66['errors']=[];const _0x48841a=_0x1d5976[_0x169977('0x1c6f')]()[_0x169977('0xf28')](_0x169977('0x4d'))[_0x169977('0xa6a')](_0x169977('0x795'))[_0x169977('0x1040')](_0x169977('0x1e7c'))['ok'](_0x169977('0x2307'))[_0x169977('0x19fb')]('Cancel')[_0x169977('0xe42')](_0x5917ba);_0x1d5976[_0x169977('0x1d4')](_0x48841a)[_0x169977('0x683')](function(){const _0x2608f9=_0x169977;_0x1da2e0[_0x2608f9('0x2601')][_0x2608f9('0xd7e')]({'id':_0x686c66['dynamics365Account']['id']})['$promise']['then'](function(){const _0x582072=_0x2608f9;_0x2e3ca0()[_0x582072('0x3ec')](_0x686c66[_0x582072('0x1aa1')],{'id':_0x686c66[_0x582072('0x239d')]['id']}),_0x375d7a[_0x582072('0x53')]({'title':'Dynamics365Account\x20properly\x20deleted!','msg':(_0x686c66['dynamics365Account'][_0x582072('0x60a')]||_0x582072('0x239d'))+_0x582072('0x194d')}),_0x3764af(_0x686c66[_0x582072('0x239d')]);})[_0x2608f9('0x130a')](function(_0x3cbbac){const _0x1601fd=_0x2608f9;if(_0x3cbbac[_0x1601fd('0x5a5')]&&_0x3cbbac[_0x1601fd('0x5a5')][_0x1601fd('0x17f')]&&_0x3cbbac[_0x1601fd('0x5a5')][_0x1601fd('0x17f')][_0x1601fd('0x1564')]){_0x686c66[_0x1601fd('0x17f')]=_0x3cbbac[_0x1601fd('0x5a5')][_0x1601fd('0x17f')]||[{'message':_0x3cbbac[_0x1601fd('0x1ff0')](),'type':'api.intDynamics365Account.delete'}];for(let _0x480f8a=0x0;_0x480f8a<_0x3cbbac[_0x1601fd('0x5a5')][_0x1601fd('0x17f')][_0x1601fd('0x1564')];_0x480f8a++){_0x375d7a[_0x1601fd('0x52a')]({'title':_0x3cbbac[_0x1601fd('0x5a5')]['errors'][_0x480f8a][_0x1601fd('0xcf0')],'msg':_0x3cbbac[_0x1601fd('0x5a5')][_0x1601fd('0x17f')][_0x480f8a][_0x1601fd('0x8c2')]});}}else _0x375d7a[_0x1601fd('0x52a')]({'title':_0x3cbbac[_0x1601fd('0x13ee')]?_0x1601fd('0x2168')+_0x3cbbac[_0x1601fd('0x13ee')]+_0x1601fd('0xbf6')+_0x3cbbac[_0x1601fd('0x24a9')]:_0x1601fd('0x2557'),'msg':_0x3cbbac[_0x1601fd('0x5a5')]?JSON[_0x1601fd('0x258a')](_0x3cbbac['data']['message']):_0x3cbbac['message']||_0x3cbbac[_0x1601fd('0x1ff0')]()});});},function(){});}function _0x21bcc4(_0x1eee33){return _0x1eee33===null?undefined:new Date(_0x1eee33);}function _0x3764af(_0x1290a3){const _0x2f5464=_0x3266a3;_0x1d5976[_0x2f5464('0x1715')](_0x1290a3);}}const _0x604d91=_0x18e2f3,_0xf76eb=_0x180212['p']+_0x189033('0x2234');_0x265707[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$window',_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x1aa1'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),'setting'];function _0x265707(_0x5ddf81,_0x320fa6,_0x25ea48,_0x2abcfe,_0x553f70,_0x6c32e8,_0x54bd41,_0x6fe19e,_0x46ccd9,_0x58710e,_0x5022d7,_0x2a1fed,_0x4292b4,_0x55b4f6,_0x43664e,_0x77e8d8,_0x5910b2){const _0x47dba1=_0x189033,_0x587b52=this;_0x587b52['license']=_0x77e8d8,_0x587b52[_0x47dba1('0x260a')]=_0x5910b2,_0x587b52[_0x47dba1('0x11ed')]=_0x43664e['getCurrentUser'](),_0x587b52['dynamics365Accounts']=_0x46ccd9||{'count':0x0,'rows':[]},_0x587b52['userProfile']=_0x58710e,_0x587b52[_0x47dba1('0x22df')]=_0x5022d7&&_0x5022d7[_0x47dba1('0x50d')]==0x1?_0x5022d7[_0x47dba1('0xf5d')][0x0]:null,_0x587b52[_0x47dba1('0x1134')]=_0x43664e[_0x47dba1('0x142a')](_0x587b52[_0x47dba1('0x22df')]?_0x587b52[_0x47dba1('0x22df')][_0x47dba1('0x1134')]:null),_0x587b52['table']=_0x47dba1('0x1aa1'),_0x587b52[_0x47dba1('0x247')]='',_0x587b52[_0x47dba1('0x1ce2')]=null,_0x587b52[_0x47dba1('0x2889')]=[],_0x587b52['query']={'fields':'createdAt,updatedAt,id,name,username,password,remoteUri,tenantId,clientId,clientSecret,serverUrl,description','limit':0xa,'page':0x1},_0x587b52['editstate']=_0x5316c8,_0x587b52['testtestintegrationaccount']=_0x279196,_0x587b52[_0x47dba1('0x194f')]=_0x4d7d7f,_0x587b52[_0x47dba1('0x53')]=_0x18e5fb,_0x587b52[_0x47dba1('0x4ec')]=_0x20f067,_0x587b52[_0x47dba1('0x10d5')]=_0x35f800,_0x587b52[_0x47dba1('0xc7a')]=_0x1288c7,_0x587b52[_0x47dba1('0x1c89')]=_0x4eaeba,_0x587b52['deleteSelectedDynamics365Accounts']=_0x4c3ed6,_0x587b52[_0x47dba1('0x26fd')]=_0x343f28,_0x587b52[_0x47dba1('0x1d5b')]=_0x43b5;function _0x5316c8(_0x56a67e){const _0x889780=_0x47dba1;_0x25ea48['go'](_0x889780('0x3ce'),{'id':_0x56a67e['id'],'dynamics365Account':_0x56a67e,'crudPermissions':_0x587b52[_0x889780('0x1134')]});}function _0x279196(_0x22413c){const _0x5789ab=_0x47dba1;return _0x2a1fed['intDynamics365Account'][_0x5789ab('0x298')]({'id':_0x22413c['id'],'test':!![]})[_0x5789ab('0xe53')][_0x5789ab('0x683')](function(){const _0x15daf8=_0x5789ab;_0x55b4f6[_0x15daf8('0x53')]({'title':'Dynamics365Account\x20properly\x20tested','msg':_0x15daf8('0x1c6d')});})['catch'](function(_0x2bf630){const _0x17c084=_0x5789ab;_0x55b4f6[_0x17c084('0x52a')]({'title':_0x17c084('0xb2'),'msg':_0x2bf630[_0x17c084('0x5a5')]?_0x2bf630[_0x17c084('0x5a5')]['message']?_0x2bf630[_0x17c084('0x5a5')][_0x17c084('0x8c2')]:JSON['stringify'](_0x2bf630[_0x17c084('0x5a5')]):_0x2bf630[_0x17c084('0x1ff0')]()});});}function _0x4d7d7f(_0x5c6df0,_0x156516){const _0x962a3a=_0x47dba1,_0x2555e2=_0x553f70['confirm']()['title'](_0x962a3a('0x1b01')+_0x2e3ca0()[_0x962a3a('0x1e03')](_0x962a3a('0x239d'))+'?')[_0x962a3a('0x26e3')](_0x962a3a('0xed5')+(_0x5c6df0['name']||_0x962a3a('0x239d'))+_0x962a3a('0x20f1')+_0x962a3a('0x1ee7'))[_0x962a3a('0x1040')](_0x962a3a('0x1ba6'))[_0x962a3a('0xe42')](_0x156516)['ok']('OK')[_0x962a3a('0x19fb')](_0x962a3a('0x16b8'));_0x553f70[_0x962a3a('0x1d4')](_0x2555e2)['then'](function(){_0x1288c7(_0x5c6df0);},function(){console['log']('CANCEL');});}let _0x543872=!![],_0x16585c=0x1;_0x5ddf81[_0x47dba1('0x186d')](_0x47dba1('0x1e1d'),function(_0x48b868,_0xc76099){const _0x27ae4a=_0x47dba1;_0x543872?_0x54bd41(function(){_0x543872=![];}):(!_0xc76099&&(_0x16585c=_0x587b52[_0x27ae4a('0x23a2')][_0x27ae4a('0xdf8')]),_0x48b868!==_0xc76099&&(_0x587b52[_0x27ae4a('0x23a2')][_0x27ae4a('0xdf8')]=0x1),!_0x48b868&&(_0x587b52[_0x27ae4a('0x23a2')][_0x27ae4a('0xdf8')]=_0x16585c),_0x587b52[_0x27ae4a('0x4ec')]());});function _0x18e5fb(_0xcdc738){const _0x3aed4c=_0x47dba1;_0x587b52[_0x3aed4c('0x1aa1')]=_0xcdc738||{'count':0x0,'rows':[]};}function _0x20f067(){const _0x4508c9=_0x47dba1;_0x587b52[_0x4508c9('0x23a2')][_0x4508c9('0x1cc8')]=(_0x587b52['query'][_0x4508c9('0xdf8')]-0x1)*_0x587b52[_0x4508c9('0x23a2')][_0x4508c9('0x6f0')],_0x43664e[_0x4508c9('0xca1')](_0x4508c9('0x20c2'))?_0x587b52[_0x4508c9('0x1883')]=_0x2a1fed[_0x4508c9('0x2601')]['get'](_0x587b52[_0x4508c9('0x23a2')],_0x18e5fb)[_0x4508c9('0xe53')]:(_0x587b52['query']['id']=_0x587b52[_0x4508c9('0x2a')]['id'],_0x587b52['query']['section']=_0x4508c9('0xa0a'),_0x587b52[_0x4508c9('0x1883')]=_0x2a1fed[_0x4508c9('0x2a')][_0x4508c9('0x241d')](_0x587b52[_0x4508c9('0x23a2')],_0x18e5fb)[_0x4508c9('0xe53')]);}function _0x35f800(_0x972c6f,_0x1603d4){const _0x484ff5=_0x47dba1;_0x553f70[_0x484ff5('0x1d4')]({'controller':_0x484ff5('0x1052'),'controllerAs':'vm','templateUrl':_0xf76eb,'parent':angular[_0x484ff5('0x1fcc')](_0x6c32e8[_0x484ff5('0x18e5')]),'targetEvent':_0x972c6f,'clickOutsideToClose':!![],'locals':{'dynamics365Account':_0x1603d4,'dynamics365Accounts':_0x587b52[_0x484ff5('0x1aa1')][_0x484ff5('0xf5d')],'license':_0x587b52[_0x484ff5('0xace')],'setting':_0x587b52[_0x484ff5('0x260a')],'crudPermissions':_0x587b52['crudPermissions']}});}function _0x1288c7(_0x1a193e){const _0x47af77=_0x47dba1;_0x2a1fed[_0x47af77('0x2601')]['delete']({'id':_0x1a193e['id']})[_0x47af77('0xe53')][_0x47af77('0x683')](function(){const _0x262b8d=_0x47af77;_0x2e3ca0()[_0x262b8d('0x3ec')](_0x587b52[_0x262b8d('0x1aa1')][_0x262b8d('0xf5d')],{'id':_0x1a193e['id']}),_0x587b52['dynamics365Accounts'][_0x262b8d('0x50d')]-=0x1,!_0x587b52[_0x262b8d('0x1aa1')][_0x262b8d('0xf5d')]['length']&&_0x587b52['getDynamics365Accounts'](),_0x55b4f6[_0x262b8d('0x53')]({'title':_0x2e3ca0()[_0x262b8d('0x1e03')](_0x262b8d('0xb40'))+_0x262b8d('0xbfc'),'msg':_0x1a193e[_0x262b8d('0x60a')]?_0x1a193e[_0x262b8d('0x60a')]+_0x262b8d('0x194d'):''});})[_0x47af77('0x130a')](function(_0x47c84a){const _0x4c1b2a=_0x47af77;if(_0x47c84a[_0x4c1b2a('0x5a5')]&&_0x47c84a[_0x4c1b2a('0x5a5')][_0x4c1b2a('0x17f')]&&_0x47c84a[_0x4c1b2a('0x5a5')]['errors'][_0x4c1b2a('0x1564')]){_0x587b52[_0x4c1b2a('0x17f')]=_0x47c84a[_0x4c1b2a('0x5a5')][_0x4c1b2a('0x17f')]||[{'message':_0x47c84a[_0x4c1b2a('0x1ff0')](),'type':'SYSTEM:DELETEintDynamics365Account'}];for(let _0x5c50a4=0x0;_0x5c50a4<_0x47c84a['data'][_0x4c1b2a('0x17f')][_0x4c1b2a('0x1564')];_0x5c50a4++){_0x55b4f6[_0x4c1b2a('0x52a')]({'title':_0x47c84a['data'][_0x4c1b2a('0x17f')][_0x5c50a4]['type'],'msg':_0x47c84a[_0x4c1b2a('0x5a5')][_0x4c1b2a('0x17f')][_0x5c50a4][_0x4c1b2a('0x8c2')]});}}else _0x55b4f6[_0x4c1b2a('0x52a')]({'title':_0x47c84a['status']?'API:'+_0x47c84a[_0x4c1b2a('0x13ee')]+_0x4c1b2a('0xbf6')+_0x47c84a[_0x4c1b2a('0x24a9')]:_0x4c1b2a('0x2038'),'msg':_0x47c84a['data']?JSON[_0x4c1b2a('0x258a')](_0x47c84a['data'][_0x4c1b2a('0x8c2')]):_0x47c84a['message']||_0x47c84a[_0x4c1b2a('0x1ff0')]()});});}function _0x4eaeba(){const _0x5949b5=_0x47dba1,_0x198b1c=angular['copy'](_0x587b52[_0x5949b5('0x2889')]);return _0x587b52[_0x5949b5('0x2889')]=[],_0x198b1c;}function _0x4c3ed6(_0x3ebeb6){const _0x20256=_0x47dba1,_0x2ff6b7=_0x553f70['confirm']()[_0x20256('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20dynamics365Accounts?')[_0x20256('0x26e3')](''+_0x587b52[_0x20256('0x2889')][_0x20256('0x1564')]+_0x20256('0x93c')+_0x20256('0x1ee7'))[_0x20256('0x1040')](_0x20256('0x119b'))[_0x20256('0xe42')](_0x3ebeb6)['ok']('OK')['cancel']('CANCEL');_0x553f70[_0x20256('0x1d4')](_0x2ff6b7)[_0x20256('0x683')](function(){const _0x3eac74=_0x20256;_0x587b52[_0x3eac74('0x2889')][_0x3eac74('0x1299')](function(_0x2a6ddf){_0x1288c7(_0x2a6ddf);}),_0x587b52[_0x3eac74('0x2889')]=[];});}function _0x343f28(){const _0x19e9eb=_0x47dba1;_0x587b52[_0x19e9eb('0x2889')]=[];}function _0x43b5(){const _0x553e63=_0x47dba1;_0x587b52[_0x553e63('0x2889')]=_0x587b52[_0x553e63('0x1aa1')][_0x553e63('0xf5d')];}}const _0x181331=_0x265707,_0x34fb57=_0x180212['p']+_0x189033('0x91e'),_0x463c72=_0x180212['p']+'src/js/modules/main/apps/integrations/views/dynamics365Accounts/edit/item/dialog.html/dialog.html';_0x2bef93[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x16ea'),'api',_0x189033('0x1d70'),_0x189033('0xba1')];function _0x2bef93(_0x9fbb43,_0x401a6a,_0x10b258,_0x69a693,_0xc8533a){const _0x541e2a=_0x189033,_0x195c82=this;_0x195c82['currentUser']=_0xc8533a[_0x541e2a('0x20b2')](),_0x195c82[_0x541e2a('0x239d')]={},_0x195c82[_0x541e2a('0x13e1')]={},_0x195c82[_0x541e2a('0x1573')]=[],_0x195c82[_0x541e2a('0x1060')]=-0x1,_0x195c82[_0x541e2a('0x1134')],_0x195c82[_0x541e2a('0x12f3')]=_0x476b5d,_0x195c82['getDynamics365Configuration']=_0x48ef32,_0x195c82['createOrEditDynamics365Configuration']=_0x5a616a,_0x195c82[_0x541e2a('0x219b')]=_0x343144;function _0x476b5d(_0x52361f,_0x3a17a5){const _0x3bfbab=_0x541e2a;_0x195c82[_0x3bfbab('0x239d')]=_0x52361f,_0x195c82[_0x3bfbab('0x1134')]=typeof _0x3a17a5!==_0x3bfbab('0x1867')?_0x3a17a5:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x10b258['intDynamics365Account'][_0x3bfbab('0x1575')]({'id':_0x195c82[_0x3bfbab('0x239d')]['id'],'sort':_0x3bfbab('0xc36')})[_0x3bfbab('0xe53')][_0x3bfbab('0x683')](function(_0x59d2d2){const _0x1fbacf=_0x3bfbab;return _0x195c82[_0x1fbacf('0x1573')]=_0x59d2d2['rows']?_0x59d2d2[_0x1fbacf('0xf5d')]:[],_0x195c82['configurations'][_0x1fbacf('0x1564')]&&_0x195c82[_0x1fbacf('0x4eb')](0x0),_0x10b258[_0x1fbacf('0x26e0')][_0x1fbacf('0x1e6e')]({'nolimit':!![],'sort':'name'})[_0x1fbacf('0xe53')];})[_0x3bfbab('0x683')](function(_0x313656){const _0x322055=_0x3bfbab;_0x195c82[_0x322055('0x220b')]=_0x313656[_0x322055('0xf5d')]?_0x313656[_0x322055('0xf5d')]:[],_0x195c82[_0x322055('0x1822')]=_0x2e3ca0()['keyBy'](_0x195c82[_0x322055('0x220b')],'id');})['catch'](function(_0x20b19d){const _0x4251e1=_0x3bfbab;_0x69a693['error']({'title':_0x20b19d[_0x4251e1('0x13ee')]?_0x4251e1('0x2168')+_0x20b19d[_0x4251e1('0x13ee')]+_0x4251e1('0xbf6')+_0x20b19d[_0x4251e1('0x24a9')]:_0x4251e1('0xe2a'),'msg':_0x20b19d[_0x4251e1('0x5a5')]?JSON[_0x4251e1('0x258a')](_0x20b19d[_0x4251e1('0x5a5')]):_0x20b19d[_0x4251e1('0x1ff0')]()});});}function _0x48ef32(_0x4d736e){const _0x4ceda4=_0x541e2a;_0x195c82['dynamics365Configuration']=_0x195c82[_0x4ceda4('0x1573')][_0x4d736e],_0x195c82[_0x4ceda4('0x1060')]=_0x4d736e,_0x10b258[_0x4ceda4('0x1f08')]['getSubjects']({'id':_0x195c82[_0x4ceda4('0x13e1')]['id']})[_0x4ceda4('0xe53')]['then'](function(_0x518724){const _0x5c91ab=_0x4ceda4;return _0x195c82[_0x5c91ab('0x1ead')]=_0x518724[_0x5c91ab('0xf5d')]?_0x518724['rows']:[],_0x10b258['intDynamics365Configuration'][_0x5c91ab('0x412')]({'id':_0x195c82[_0x5c91ab('0x13e1')]['id']})[_0x5c91ab('0xe53')];})[_0x4ceda4('0x683')](function(_0x974398){const _0x57d39d=_0x4ceda4;return _0x195c82[_0x57d39d('0x18f7')]=_0x974398['rows']?_0x974398[_0x57d39d('0xf5d')]:[],_0x10b258[_0x57d39d('0x1f08')]['getFields']({'id':_0x195c82[_0x57d39d('0x13e1')]['id']})['$promise'];})['then'](function(_0x41ad81){const _0x1f1b99=_0x4ceda4;_0x195c82['fields']=_0x41ad81['rows']?_0x41ad81[_0x1f1b99('0xf5d')]:[];})[_0x4ceda4('0x130a')](function(_0x582bd7){const _0x4e5046=_0x4ceda4;_0x69a693['error']({'title':_0x582bd7['status']?_0x4e5046('0x2168')+_0x582bd7[_0x4e5046('0x13ee')]+_0x4e5046('0xbf6')+_0x582bd7[_0x4e5046('0x24a9')]:_0x4e5046('0x167c'),'msg':_0x582bd7['data']?JSON[_0x4e5046('0x258a')](_0x582bd7['data']):_0x582bd7[_0x4e5046('0x1ff0')]()});});}function _0x5a616a(_0xafa1a8,_0x53a245){const _0x23651a=_0x541e2a;_0x9fbb43[_0x23651a('0x1d4')]({'controller':_0x23651a('0xe9b'),'controllerAs':'vm','templateUrl':_0x34fb57,'parent':angular[_0x23651a('0x1fcc')](_0x401a6a[_0x23651a('0x18e5')]),'targetEvent':_0xafa1a8,'clickOutsideToClose':!![],'locals':{'dynamics365Configuration':_0x53a245,'configurations':_0x195c82[_0x23651a('0x1573')],'license':null,'setting':null,'crudPermissions':_0x195c82['crudPermissions']}})[_0x23651a('0x2874')](function(){const _0x4f0752=_0x23651a;_0x195c82[_0x4f0752('0x4eb')](0x0);});}function _0x343144(_0x5c30b4,_0x4599ab){const _0x3c806e=_0x541e2a,_0x115327=_0x9fbb43[_0x3c806e('0x1c6f')]()['title'](_0x3c806e('0x2150'))[_0x3c806e('0x26e3')](''+(_0x4599ab['name']||_0x3c806e('0x13e1'))+_0x3c806e('0x20f1')+'\x20will\x20be\x20deleted.')[_0x3c806e('0x1040')]('delete\x20dynamics365Configuration')['targetEvent'](_0x5c30b4)['ok']('OK')['cancel'](_0x3c806e('0x16b8'));_0x9fbb43[_0x3c806e('0x1d4')](_0x115327)[_0x3c806e('0x683')](function(){const _0x1e8578=_0x3c806e;_0x10b258[_0x1e8578('0x1f08')][_0x1e8578('0xd7e')]({'id':_0x4599ab['id']})[_0x1e8578('0xe53')][_0x1e8578('0x683')](function(){const _0x536c15=_0x1e8578;_0x2e3ca0()[_0x536c15('0x3ec')](_0x195c82['configurations'],{'id':_0x4599ab['id']}),_0x69a693['success']({'title':'Dynamics365Configuration\x20deleted!','msg':_0x4599ab[_0x536c15('0x60a')]?_0x4599ab[_0x536c15('0x60a')]+_0x536c15('0x194d'):''});})[_0x1e8578('0x130a')](function(_0x82725a){const _0x3ae8ea=_0x1e8578;_0x69a693['error']({'title':_0x82725a['status']?'API:'+_0x82725a[_0x3ae8ea('0x13ee')]+_0x3ae8ea('0xbf6')+_0x82725a['statusText']:_0x3ae8ea('0x1e44'),'msg':_0x82725a[_0x3ae8ea('0x5a5')]?JSON['stringify'](_0x82725a[_0x3ae8ea('0x5a5')]):_0x82725a[_0x3ae8ea('0x1ff0')]()});})[_0x1e8578('0x2874')](function(){const _0x4ca78c=_0x1e8578;_0x195c82[_0x4ca78c('0x4eb')](0x0);});},function(){const _0x3e3af9=_0x3c806e;console[_0x3e3af9('0x1b2b')](_0x3e3af9('0x16b8'));});}_0x195c82['selectedSubjects']=[],_0x195c82[_0x541e2a('0x2654')]=_0x493c8f,_0x195c82[_0x541e2a('0x2802')]=_0x51b2f8,_0x195c82[_0x541e2a('0x1734')]=_0x39d253;function _0x493c8f(_0x3df953,_0x35b0c8){const _0x498443=_0x541e2a;_0x9fbb43[_0x498443('0x1d4')]({'controller':_0x498443('0x2182'),'controllerAs':'vm','templateUrl':_0x463c72,'parent':angular[_0x498443('0x1fcc')](_0x401a6a[_0x498443('0x18e5')]),'targetEvent':_0x3df953,'clickOutsideToClose':!![],'locals':{'type':_0x498443('0x1e66'),'item':_0x35b0c8,'items':_0x195c82[_0x498443('0x1ead')],'configuration':_0x195c82[_0x498443('0x13e1')],'account':_0x195c82[_0x498443('0x239d')],'license':null,'setting':null,'crudPermissions':_0x195c82[_0x498443('0x1134')]}});}function _0x23f9f2(_0x228573){const _0x3bd997=_0x541e2a;_0x10b258[_0x3bd997('0x130b')][_0x3bd997('0xd7e')]({'id':_0x228573['id']})[_0x3bd997('0xe53')][_0x3bd997('0x683')](function(){const _0x9495eb=_0x3bd997;_0x2e3ca0()[_0x9495eb('0x3ec')](_0x195c82[_0x9495eb('0x1ead')],{'id':_0x228573['id']}),_0x69a693[_0x9495eb('0x53')]({'title':_0x9495eb('0x637'),'msg':_0x9495eb('0x2795')});})[_0x3bd997('0x130a')](function(_0xf5f980){const _0x4a9d1a=_0x3bd997;_0x69a693[_0x4a9d1a('0x52a')]({'title':_0xf5f980[_0x4a9d1a('0x13ee')]?_0x4a9d1a('0x2168')+_0xf5f980[_0x4a9d1a('0x13ee')]+'\x20-\x20'+_0xf5f980[_0x4a9d1a('0x24a9')]:_0x4a9d1a('0x1d23'),'msg':_0xf5f980['data']?JSON[_0x4a9d1a('0x258a')](_0xf5f980['data']):_0xf5f980[_0x4a9d1a('0x1ff0')]()});});}function _0x51b2f8(_0x1a5639,_0x4d755c){const _0x105018=_0x541e2a,_0x52cc4d=_0x9fbb43['confirm']()[_0x105018('0xf28')](_0x105018('0x17ed'))[_0x105018('0x26e3')](_0x105018('0x601')+_0x105018('0x1ee7'))[_0x105018('0x1040')]('delete\x20subject')[_0x105018('0xe42')](_0x1a5639)['ok']('OK')[_0x105018('0x19fb')](_0x105018('0x16b8'));_0x9fbb43['show'](_0x52cc4d)[_0x105018('0x683')](function(){_0x23f9f2(_0x4d755c);},function(){const _0x5eb7ea=_0x105018;console[_0x5eb7ea('0x1b2b')]('CANCEL');});}function _0x39d253(_0x149ee9){const _0x4ccf86=_0x541e2a,_0x389d75=_0x9fbb43['confirm']()[_0x4ccf86('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20subjects?')[_0x4ccf86('0x26e3')](''+_0x195c82['selectedSubjects']['length']+_0x4ccf86('0x93c')+_0x4ccf86('0x1ee7'))['ariaLabel'](_0x4ccf86('0x9fb'))['targetEvent'](_0x149ee9)['ok']('OK')[_0x4ccf86('0x19fb')](_0x4ccf86('0x16b8'));_0x9fbb43[_0x4ccf86('0x1d4')](_0x389d75)[_0x4ccf86('0x683')](function(){const _0x5cf3b3=_0x4ccf86;_0x195c82['selectedSubjects'][_0x5cf3b3('0x1299')](function(_0x194450){_0x23f9f2(_0x194450);}),_0x195c82[_0x5cf3b3('0x1781')]=[];});}_0x195c82[_0x541e2a('0xcb1')]=[],_0x195c82[_0x541e2a('0x1094')]=_0x3b7320,_0x195c82[_0x541e2a('0x27b2')]=_0x59d661,_0x195c82[_0x541e2a('0x27df')]=_0x2c3048;function _0x3b7320(_0x276f0e,_0x4ace94){const _0x6dc8b7=_0x541e2a;_0x9fbb43[_0x6dc8b7('0x1d4')]({'controller':_0x6dc8b7('0x2182'),'controllerAs':'vm','templateUrl':_0x463c72,'parent':angular[_0x6dc8b7('0x1fcc')](_0x401a6a[_0x6dc8b7('0x18e5')]),'targetEvent':_0x276f0e,'clickOutsideToClose':!![],'locals':{'type':_0x6dc8b7('0xd6b'),'item':_0x4ace94,'items':_0x195c82[_0x6dc8b7('0x18f7')],'configuration':_0x195c82[_0x6dc8b7('0x13e1')],'account':_0x195c82[_0x6dc8b7('0x239d')],'license':null,'setting':null,'crudPermissions':_0x195c82[_0x6dc8b7('0x1134')]}});}function _0x342726(_0x118f21){const _0x39338d=_0x541e2a;_0x10b258[_0x39338d('0x130b')][_0x39338d('0xd7e')]({'id':_0x118f21['id']})['$promise'][_0x39338d('0x683')](function(){const _0x139d4d=_0x39338d;_0x2e3ca0()[_0x139d4d('0x3ec')](_0x195c82[_0x139d4d('0x18f7')],{'id':_0x118f21['id']}),_0x69a693[_0x139d4d('0x53')]({'title':_0x139d4d('0x1cf8'),'msg':_0x139d4d('0x21c7')});})[_0x39338d('0x130a')](function(_0x4bef33){const _0x5ce0b9=_0x39338d;_0x69a693['error']({'title':_0x4bef33[_0x5ce0b9('0x13ee')]?'API:'+_0x4bef33[_0x5ce0b9('0x13ee')]+_0x5ce0b9('0xbf6')+_0x4bef33[_0x5ce0b9('0x24a9')]:_0x5ce0b9('0x1d23'),'msg':_0x4bef33[_0x5ce0b9('0x5a5')]?JSON[_0x5ce0b9('0x258a')](_0x4bef33[_0x5ce0b9('0x5a5')]):_0x4bef33[_0x5ce0b9('0x1ff0')]()});});}function _0x59d661(_0x36d105,_0x59fd64){const _0x55738a=_0x541e2a,_0x4f2623=_0x9fbb43[_0x55738a('0x1c6f')]()[_0x55738a('0xf28')](_0x55738a('0xb72'))['htmlContent']('Description'+_0x55738a('0x1ee7'))['ariaLabel']('delete\x20description')[_0x55738a('0xe42')](_0x36d105)['ok']('OK')[_0x55738a('0x19fb')](_0x55738a('0x16b8'));_0x9fbb43[_0x55738a('0x1d4')](_0x4f2623)[_0x55738a('0x683')](function(){_0x342726(_0x59fd64);},function(){const _0x56e3d5=_0x55738a;console['log'](_0x56e3d5('0x16b8'));});}function _0x2c3048(_0x58f259){const _0x14656c=_0x541e2a,_0x2afd6d=_0x9fbb43['confirm']()['title'](_0x14656c('0x1984'))[_0x14656c('0x26e3')](_0x14656c('0xed5')+_0x195c82[_0x14656c('0xcb1')][_0x14656c('0x1564')]+_0x14656c('0x93c')+_0x14656c('0x1ee7'))[_0x14656c('0x1040')](_0x14656c('0x1859'))['targetEvent'](_0x58f259)['ok']('OK')[_0x14656c('0x19fb')](_0x14656c('0x16b8'));_0x9fbb43[_0x14656c('0x1d4')](_0x2afd6d)['then'](function(){const _0x47673b=_0x14656c;_0x195c82[_0x47673b('0xcb1')][_0x47673b('0x1299')](function(_0x4b51ad){_0x342726(_0x4b51ad);}),_0x195c82[_0x47673b('0xcb1')]=[];});}_0x195c82['selectedFields']=[],_0x195c82[_0x541e2a('0x84f')]=_0x3840c5,_0x195c82[_0x541e2a('0x9f9')]=_0x31ed37,_0x195c82['deleteSelectedFields']=_0x5605dc;function _0x3840c5(_0x4a892a,_0x4db927){const _0x17188c=_0x541e2a;_0x9fbb43[_0x17188c('0x1d4')]({'controller':_0x17188c('0x2182'),'controllerAs':'vm','templateUrl':_0x463c72,'parent':angular['element'](_0x401a6a[_0x17188c('0x18e5')]),'targetEvent':_0x4a892a,'clickOutsideToClose':!![],'locals':{'type':_0x17188c('0x2013'),'item':_0x4db927,'items':_0x195c82[_0x17188c('0x189a')],'configuration':_0x195c82[_0x17188c('0x13e1')],'account':_0x195c82[_0x17188c('0x239d')],'license':null,'setting':null,'crudPermissions':_0x195c82[_0x17188c('0x1134')]}});}function _0x139c66(_0x338b85){const _0x1739e3=_0x541e2a;_0x10b258['intDynamics365Field'][_0x1739e3('0xd7e')]({'id':_0x338b85['id']})[_0x1739e3('0xe53')][_0x1739e3('0x683')](function(){const _0x12050b=_0x1739e3;_0x2e3ca0()[_0x12050b('0x3ec')](_0x195c82[_0x12050b('0x189a')],{'id':_0x338b85['id']}),_0x69a693[_0x12050b('0x53')]({'title':_0x12050b('0x1666'),'msg':_0x12050b('0x1eda')});})[_0x1739e3('0x130a')](function(_0x6be68a){const _0x582132=_0x1739e3;_0x69a693[_0x582132('0x52a')]({'title':_0x6be68a[_0x582132('0x13ee')]?_0x582132('0x2168')+_0x6be68a['status']+'\x20-\x20'+_0x6be68a['statusText']:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x6be68a['data']?JSON['stringify'](_0x6be68a[_0x582132('0x5a5')]):_0x6be68a[_0x582132('0x1ff0')]()});});}function _0x31ed37(_0x418882,_0x5cebcb){const _0x4b95fb=_0x541e2a,_0x1507e7=_0x9fbb43[_0x4b95fb('0x1c6f')]()[_0x4b95fb('0xf28')](_0x4b95fb('0x16b5'))[_0x4b95fb('0x26e3')](_0x4b95fb('0x23b9')+_0x4b95fb('0x1ee7'))[_0x4b95fb('0x1040')]('delete\x20field')[_0x4b95fb('0xe42')](_0x418882)['ok']('OK')[_0x4b95fb('0x19fb')](_0x4b95fb('0x16b8'));_0x9fbb43[_0x4b95fb('0x1d4')](_0x1507e7)[_0x4b95fb('0x683')](function(){_0x139c66(_0x5cebcb);},function(){const _0x477f7d=_0x4b95fb;console[_0x477f7d('0x1b2b')](_0x477f7d('0x16b8'));});}function _0x5605dc(_0x2899f6){const _0x10e8c0=_0x541e2a,_0x2a26d8=_0x9fbb43[_0x10e8c0('0x1c6f')]()[_0x10e8c0('0xf28')](_0x10e8c0('0x19b1'))['htmlContent'](_0x10e8c0('0xed5')+_0x195c82[_0x10e8c0('0x310')][_0x10e8c0('0x1564')]+_0x10e8c0('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x10e8c0('0x994'))[_0x10e8c0('0xe42')](_0x2899f6)['ok']('OK')[_0x10e8c0('0x19fb')](_0x10e8c0('0x16b8'));_0x9fbb43[_0x10e8c0('0x1d4')](_0x2a26d8)[_0x10e8c0('0x683')](function(){const _0x3c6349=_0x10e8c0;_0x195c82[_0x3c6349('0x310')][_0x3c6349('0x1299')](function(_0x37aae4){_0x139c66(_0x37aae4);}),_0x195c82[_0x3c6349('0x310')]=[];});}}const _0x515d32=_0x2bef93;_0x37608f[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),'configurations','dynamics365Configuration',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x37608f(_0x1025ac,_0x1d6921,_0x2ec128,_0x5bcb14,_0x1e288f,_0x4a308e,_0x1192c2,_0x9dc284,_0xc7bd8e,_0x4265b2,_0x1e2e8d,_0x14999d,_0x59df20,_0x41e77e){const _0xab1a48=_0x189033,_0x16c453=this;_0x16c453[_0xab1a48('0x11ed')]=_0x1e2e8d['getCurrentUser'](),_0x16c453['errors']=[],_0x16c453[_0xab1a48('0x260a')]=_0x59df20,_0x16c453[_0xab1a48('0xace')]=_0x14999d,_0x16c453['crudPermissions']=_0x41e77e,_0x16c453['hasModulePermissions']={},_0x16c453['passwordPattern']=_0x16c453[_0xab1a48('0x260a')]&&_0x16c453[_0xab1a48('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x16c453[_0xab1a48('0xf28')]=_0xab1a48('0x1286'),_0x16c453[_0xab1a48('0x13e1')]=angular['copy'](_0xc7bd8e),_0x16c453[_0xab1a48('0x1573')]=_0x9dc284,_0x16c453[_0xab1a48('0x10b6')]=![];!_0x16c453[_0xab1a48('0x13e1')]&&(_0x16c453[_0xab1a48('0x13e1')]={'channel':_0xab1a48('0xcf2'),'type':_0xab1a48('0x1535'),'ticketType':'incident'},_0x16c453[_0xab1a48('0xf28')]=_0xab1a48('0x978'),_0x16c453[_0xab1a48('0x10b6')]=!![]);_0x16c453[_0xab1a48('0xee3')]=_0x2aa6ee,_0x16c453[_0xab1a48('0x1065')]=_0x2fa28e,_0x16c453['deleteDynamics365Configuration']=_0x51ee56,_0x16c453['getDateFromString']=_0xd74eb0,_0x16c453[_0xab1a48('0xf82')]=_0x2573a0;function _0x2aa6ee(){const _0x2cc39e=_0xab1a48;_0x16c453[_0x2cc39e('0x17f')]=[],_0x4265b2[_0x2cc39e('0x2601')][_0x2cc39e('0x2003')]({'id':_0x1d6921[_0x2cc39e('0x7f2')]['id']},_0x16c453[_0x2cc39e('0x13e1')])[_0x2cc39e('0xe53')][_0x2cc39e('0x683')](function(_0x5ccc5d){const _0x2c4798=_0x2cc39e;_0x16c453[_0x2c4798('0x1573')]['unshift'](_0x5ccc5d[_0x2c4798('0x24e1')]()),_0x1192c2['success']({'title':_0x2c4798('0x45d'),'msg':_0x16c453['dynamics365Configuration'][_0x2c4798('0x60a')]?_0x16c453[_0x2c4798('0x13e1')][_0x2c4798('0x60a')]+'\x20has\x20been\x20created!':''}),_0x2573a0(_0x5ccc5d);})[_0x2cc39e('0x130a')](function(_0x21e7a4){const _0x5221a1=_0x2cc39e;if(_0x21e7a4['data']&&_0x21e7a4[_0x5221a1('0x5a5')]['errors']&&_0x21e7a4['data'][_0x5221a1('0x17f')][_0x5221a1('0x1564')]){_0x16c453['errors']=_0x21e7a4['data'][_0x5221a1('0x17f')]||[{'message':_0x21e7a4[_0x5221a1('0x1ff0')](),'type':'api.intDynamics365Configuration.save'}];for(let _0x59abf6=0x0;_0x59abf6<_0x21e7a4[_0x5221a1('0x5a5')]['errors'][_0x5221a1('0x1564')];_0x59abf6+=0x1){_0x1192c2[_0x5221a1('0x52a')]({'title':_0x21e7a4['data']['errors'][_0x59abf6][_0x5221a1('0xcf0')],'msg':_0x21e7a4[_0x5221a1('0x5a5')]['errors'][_0x59abf6][_0x5221a1('0x8c2')]});}}else _0x1192c2['error']({'title':_0x21e7a4[_0x5221a1('0x13ee')]?_0x5221a1('0x2168')+_0x21e7a4[_0x5221a1('0x13ee')]+_0x5221a1('0xbf6')+_0x21e7a4['statusText']:_0x5221a1('0x3b8'),'msg':_0x21e7a4[_0x5221a1('0x5a5')]?JSON[_0x5221a1('0x258a')](_0x21e7a4[_0x5221a1('0x5a5')][_0x5221a1('0x8c2')]):_0x21e7a4[_0x5221a1('0x1ff0')]()});});}function _0x2fa28e(){const _0x49ee36=_0xab1a48;_0x16c453['errors']=[],_0x4265b2[_0x49ee36('0x1f08')][_0x49ee36('0x2480')]({'id':_0x16c453[_0x49ee36('0x13e1')]['id']},_0x16c453['dynamics365Configuration'])[_0x49ee36('0xe53')][_0x49ee36('0x683')](function(_0x219c1f){const _0xfb9106=_0x49ee36,_0x3604e3=_0x2e3ca0()['find'](_0x16c453['configurations'],{'id':_0x219c1f['id']});_0x3604e3&&_0x2e3ca0()[_0xfb9106('0xf22')](_0x3604e3,_0x2e3ca0()[_0xfb9106('0x24d0')](_0x219c1f[_0xfb9106('0x24e1')](),_0x2e3ca0()[_0xfb9106('0x55e')](_0x3604e3))),_0x1192c2[_0xfb9106('0x53')]({'title':_0xfb9106('0x20ad'),'msg':_0x16c453[_0xfb9106('0x13e1')][_0xfb9106('0x60a')]?_0x16c453[_0xfb9106('0x13e1')]['name']+'\x20has\x20been\x20saved!':''}),_0x2573a0(_0x219c1f);})[_0x49ee36('0x130a')](function(_0x1c8902){const _0x213625=_0x49ee36;if(_0x1c8902[_0x213625('0x5a5')]&&_0x1c8902[_0x213625('0x5a5')][_0x213625('0x17f')]&&_0x1c8902[_0x213625('0x5a5')]['errors'][_0x213625('0x1564')]){_0x16c453[_0x213625('0x17f')]=_0x1c8902[_0x213625('0x5a5')]['errors']||[{'message':_0x1c8902[_0x213625('0x1ff0')](),'type':'api.intDynamics365Configuration.update'}];for(let _0x4c675e=0x0;_0x4c675e<_0x1c8902[_0x213625('0x5a5')][_0x213625('0x17f')][_0x213625('0x1564')];_0x4c675e++){_0x1192c2['error']({'title':_0x1c8902['data'][_0x213625('0x17f')][_0x4c675e][_0x213625('0xcf0')],'msg':_0x1c8902[_0x213625('0x5a5')][_0x213625('0x17f')][_0x4c675e][_0x213625('0x8c2')]});}}else _0x1192c2[_0x213625('0x52a')]({'title':_0x1c8902['status']?_0x213625('0x2168')+_0x1c8902['status']+_0x213625('0xbf6')+_0x1c8902[_0x213625('0x24a9')]:'api.intDynamics365Configuration.update','msg':_0x1c8902[_0x213625('0x5a5')]?JSON[_0x213625('0x258a')](_0x1c8902[_0x213625('0x5a5')][_0x213625('0x8c2')]):_0x1c8902[_0x213625('0x1ff0')]()});});}function _0x51ee56(_0x479480){const _0x949047=_0xab1a48;_0x16c453[_0x949047('0x17f')]=[];const _0x620491=_0x5bcb14[_0x949047('0x1c6f')]()[_0x949047('0xf28')](_0x949047('0x4d'))[_0x949047('0xa6a')](_0x949047('0x1f98'))[_0x949047('0x1040')](_0x949047('0x163b'))['ok'](_0x949047('0x2307'))[_0x949047('0x19fb')]('Cancel')['targetEvent'](_0x479480);_0x5bcb14[_0x949047('0x1d4')](_0x620491)[_0x949047('0x683')](function(){const _0x4c8ace=_0x949047;_0x4265b2[_0x4c8ace('0x1f08')][_0x4c8ace('0xd7e')]({'id':_0x16c453[_0x4c8ace('0x13e1')]['id']})['$promise']['then'](function(){const _0x4be06c=_0x4c8ace;_0x2e3ca0()[_0x4be06c('0x3ec')](_0x16c453[_0x4be06c('0x1573')],{'id':_0x16c453[_0x4be06c('0x13e1')]['id']}),_0x1192c2['success']({'title':_0x4be06c('0x230'),'msg':(_0x16c453['dynamics365Configuration'][_0x4be06c('0x60a')]||'dynamics365Configuration')+'\x20has\x20been\x20deleted!'}),_0x2573a0(_0x16c453[_0x4be06c('0x13e1')]);})[_0x4c8ace('0x130a')](function(_0x1796ad){const _0x70cba2=_0x4c8ace;if(_0x1796ad[_0x70cba2('0x5a5')]&&_0x1796ad['data'][_0x70cba2('0x17f')]&&_0x1796ad[_0x70cba2('0x5a5')][_0x70cba2('0x17f')][_0x70cba2('0x1564')]){_0x16c453['errors']=_0x1796ad['data'][_0x70cba2('0x17f')]||[{'message':_0x1796ad[_0x70cba2('0x1ff0')](),'type':_0x70cba2('0xe75')}];for(let _0x1bdc7a=0x0;_0x1bdc7a<_0x1796ad[_0x70cba2('0x5a5')][_0x70cba2('0x17f')][_0x70cba2('0x1564')];_0x1bdc7a++){_0x1192c2[_0x70cba2('0x52a')]({'title':_0x1796ad[_0x70cba2('0x5a5')][_0x70cba2('0x17f')][_0x1bdc7a]['type'],'msg':_0x1796ad['data'][_0x70cba2('0x17f')][_0x1bdc7a][_0x70cba2('0x8c2')]});}}else _0x1192c2[_0x70cba2('0x52a')]({'title':_0x1796ad['status']?'API:'+_0x1796ad[_0x70cba2('0x13ee')]+_0x70cba2('0xbf6')+_0x1796ad[_0x70cba2('0x24a9')]:_0x70cba2('0xe75'),'msg':_0x1796ad['data']?JSON['stringify'](_0x1796ad['data']['message']):_0x1796ad[_0x70cba2('0x8c2')]||_0x1796ad[_0x70cba2('0x1ff0')]()});});},function(){});}function _0xd74eb0(_0x1f682f){return _0x1f682f===null?undefined:new Date(_0x1f682f);}function _0x2573a0(_0x510217){const _0x14ed0b=_0xab1a48;_0x5bcb14[_0x14ed0b('0x1715')](_0x510217);}}const _0x482b83=_0x37608f;_0x1d3b7a[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x1d70'),'configuration',_0x189033('0x1996'),'item','account',_0x189033('0xcf0'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x1d3b7a(_0x2d6a6d,_0x3f1513,_0x5cb144,_0x2f3fb5,_0x2b8194,_0x3e026c,_0x3355e9,_0x33e91e,_0xae25c4,_0x2f0df9,_0x19bc29,_0x45fce2,_0xce9758){const _0x34b276=_0x189033,_0xd5f439=this;_0xd5f439[_0x34b276('0x11ed')]=_0x45fce2[_0x34b276('0x20b2')](),_0xd5f439[_0x34b276('0x17f')]=[],_0xd5f439['title']=_0x34b276('0x176c')+_0x2e3ca0()[_0x34b276('0x65')](_0x2f0df9),_0xd5f439[_0x34b276('0x23ef')]=angular['copy'](_0x33e91e),_0xd5f439['items']=_0x3355e9,_0xd5f439[_0x34b276('0xcf0')]=_0x2f0df9,_0xd5f439[_0x34b276('0x1134')]=_0xce9758,_0xd5f439['newItem']=![];!_0xd5f439[_0x34b276('0x23ef')]&&(_0xd5f439[_0x34b276('0x23ef')]={'type':_0x34b276('0xc06')},_0xd5f439['item'][_0x2e3ca0()[_0x34b276('0x21ab')](_0x2f0df9)+'Id']=_0x3e026c['id'],_0xd5f439[_0x34b276('0xf28')]='INTEGRATIONS.NEW_'+_0x2e3ca0()['toUpper'](_0x2f0df9),_0xd5f439[_0x34b276('0x3d2')]=!![]);_0xd5f439[_0x34b276('0x2591')]=_0x33290d,_0xd5f439[_0x34b276('0x2716')]=_0x3efe25,_0xd5f439[_0x34b276('0x6b8')]=_0x86916d,_0xd5f439[_0x34b276('0x18a')]=_0x471c25,_0xd5f439[_0x34b276('0xf82')]=_0x5581e5,_0x19bc29[_0x34b276('0x26e0')][_0x34b276('0x1e6e')]({'nolimit':!![]})['$promise'][_0x34b276('0x683')](function(_0x9cf60e){const _0x142cab=_0x34b276;return _0xd5f439[_0x142cab('0x220b')]=_0x9cf60e[_0x142cab('0xf5d')]?_0x9cf60e[_0x142cab('0xf5d')]:[],_0x19bc29[_0x142cab('0xf53')]['describe']()[_0x142cab('0xe53')];})['then'](function(_0x1fbdee){const _0x5e38f0=_0x34b276;return _0xd5f439[_0x5e38f0('0x20c1')]=_0x2e3ca0()[_0x5e38f0('0x2829')](_0x2e3ca0()[_0x5e38f0('0x55e')](_0x1fbdee),[_0x5e38f0('0xe53'),_0x5e38f0('0x1980'),'createdAt',_0x5e38f0('0x2000'),_0x5e38f0('0x1d58')]),_0xd5f439[_0x5e38f0('0x20c1')][_0x5e38f0('0x1fd0')](_0x5e38f0('0x1e93')),_0x19bc29[_0x5e38f0('0x1793')]['describe']()['$promise'];})['then'](function(_0x24573f){const _0x1e4fac=_0x34b276;_0xd5f439['voiceDialReportColumns']=_0x2e3ca0()[_0x1e4fac('0x2829')](_0x2e3ca0()['keys'](_0x24573f),['$promise',_0x1e4fac('0x1980'),_0x1e4fac('0x1a4'),_0x1e4fac('0x2000'),_0x1e4fac('0x1d58')]),_0xd5f439[_0x1e4fac('0x1d6a')][_0x1e4fac('0x1fd0')](_0x1e4fac('0x1e93'));})[_0x34b276('0x130a')](function(_0x532bec){const _0x3eb8ba=_0x34b276;_0x2b8194['error']({'title':_0x532bec[_0x3eb8ba('0x13ee')]?'API:'+_0x532bec[_0x3eb8ba('0x13ee')]+_0x3eb8ba('0xbf6')+_0x532bec[_0x3eb8ba('0x24a9')]:_0x3eb8ba('0x1fd3'),'msg':_0x532bec['data']?JSON[_0x3eb8ba('0x258a')](_0x532bec[_0x3eb8ba('0x5a5')]):_0x532bec[_0x3eb8ba('0x1ff0')]()});}),_0x19bc29[_0x34b276('0x2601')][_0x34b276('0x298')]({'id':_0xae25c4['id'],'ticketType':_0x3e026c[_0x34b276('0x20c9')]?_0x3e026c['ticketType']:undefined})[_0x34b276('0xe53')][_0x34b276('0x683')](function(_0x4082d9){const _0x305fc2=_0x34b276;_0xd5f439[_0x305fc2('0xd32')]=!![],_0xd5f439[_0x305fc2('0x189a')]=_0x4082d9['rows']?_0x4082d9[_0x305fc2('0xf5d')]:[],_0xd5f439[_0x305fc2('0x23ef')][_0x305fc2('0x280')]&&(_0xd5f439[_0x305fc2('0x7f8')]=_0x2e3ca0()[_0x305fc2('0x1c07')](_0xd5f439['fields'],{'id':_0xd5f439[_0x305fc2('0x23ef')][_0x305fc2('0x280')]}));})[_0x34b276('0x130a')](function(_0x595942){const _0x3fd8ea=_0x34b276;_0xd5f439[_0x3fd8ea('0xd32')]=![],console[_0x3fd8ea('0x52a')](_0x595942);});function _0x33290d(){const _0x4b89ef=_0x34b276;_0xd5f439['errors']=[],_0xd5f439[_0x4b89ef('0x7f8')]&&(_0xd5f439['item'][_0x4b89ef('0x280')]=_0xd5f439['customField']['id'],_0xd5f439['item']['nameField']=_0xd5f439[_0x4b89ef('0x7f8')]['name'],_0xd5f439[_0x4b89ef('0x23ef')][_0x4b89ef('0x7f8')]=_0xd5f439[_0x4b89ef('0x7f8')][_0x4b89ef('0xbf0')]),_0x19bc29['intDynamics365Field'][_0x4b89ef('0xb0a')](_0xd5f439[_0x4b89ef('0x23ef')])['$promise'][_0x4b89ef('0x683')](function(_0x498bda){const _0x3cb301=_0x4b89ef;_0xd5f439[_0x3cb301('0x1996')][_0x3cb301('0x1167')](_0x498bda),_0x2b8194['success']({'title':_0x2e3ca0()[_0x3cb301('0x21ab')](_0x2f0df9)+'\x20properly\x20created','msg':_0x2e3ca0()[_0x3cb301('0x21ab')](_0x2f0df9)+_0x3cb301('0x14b5')}),_0x5581e5();})[_0x4b89ef('0x130a')](function(_0x274268){const _0x34b573=_0x4b89ef;console[_0x34b573('0x52a')](_0x274268),_0xd5f439[_0x34b573('0x17f')]=_0x274268['data'][_0x34b573('0x17f')]||[{'message':_0x274268[_0x34b573('0x1ff0')](),'type':'api.item.save'}];});}function _0x3efe25(){const _0x3e8d7c=_0x34b276;_0xd5f439['errors']=[],_0xd5f439[_0x3e8d7c('0x7f8')]&&(_0xd5f439[_0x3e8d7c('0x23ef')][_0x3e8d7c('0x280')]=_0xd5f439['customField']['id'],_0xd5f439[_0x3e8d7c('0x23ef')]['nameField']=_0xd5f439['customField'][_0x3e8d7c('0x60a')],_0xd5f439[_0x3e8d7c('0x23ef')]['customField']=_0xd5f439[_0x3e8d7c('0x7f8')][_0x3e8d7c('0xbf0')]),_0x19bc29[_0x3e8d7c('0x130b')]['update']({'id':_0xd5f439[_0x3e8d7c('0x23ef')]['id']},_0xd5f439['item'])['$promise'][_0x3e8d7c('0x683')](function(_0x3b3ee0){const _0x436d69=_0x3e8d7c,_0x2b1338=_0x2e3ca0()['find'](_0xd5f439[_0x436d69('0x1996')],{'id':_0x3b3ee0['id']});_0x2b1338&&_0x2e3ca0()[_0x436d69('0xf22')](_0x2b1338,_0x3b3ee0),_0x2b8194['success']({'title':_0x2e3ca0()[_0x436d69('0x21ab')](_0x2f0df9)+_0x436d69('0x15dd'),'msg':_0x2e3ca0()[_0x436d69('0x21ab')](_0x2f0df9)+'\x20has\x20been\x20saved!'}),_0x5581e5();})[_0x3e8d7c('0x130a')](function(_0x10c37d){const _0x2b6d8a=_0x3e8d7c;console[_0x2b6d8a('0x52a')](_0x10c37d),_0xd5f439[_0x2b6d8a('0x17f')]=_0x10c37d[_0x2b6d8a('0x5a5')]['errors']||[{'message':_0x10c37d[_0x2b6d8a('0x1ff0')](),'type':_0x2b6d8a('0x25d0')}];});}function _0x86916d(_0x2fa78b){const _0x71faa8=_0x34b276;_0xd5f439[_0x71faa8('0x17f')]=[];const _0x52f964=_0x2f3fb5['confirm']()[_0x71faa8('0xf28')]('Are\x20you\x20sure?')['content']('The\x20'+_0x2f0df9+_0x71faa8('0x1ee7'))[_0x71faa8('0x1040')](_0x71faa8('0x609')+_0x2e3ca0()[_0x71faa8('0x21ab')](_0x2f0df9))['ok'](_0x71faa8('0x2307'))[_0x71faa8('0x19fb')](_0x71faa8('0x253a'))[_0x71faa8('0xe42')](_0x2fa78b);_0x2f3fb5[_0x71faa8('0x1d4')](_0x52f964)[_0x71faa8('0x683')](function(){const _0x3035fb=_0x71faa8;_0x19bc29['intDynamics365Field'][_0x3035fb('0xd7e')]({'id':_0xd5f439['item']['id']})[_0x3035fb('0xe53')][_0x3035fb('0x683')](function(){const _0x5d2743=_0x3035fb;_0x2e3ca0()[_0x5d2743('0x3ec')](_0xd5f439[_0x5d2743('0x1996')],{'id':_0xd5f439[_0x5d2743('0x23ef')]['id']}),_0x2b8194[_0x5d2743('0x53')]({'title':_0x2e3ca0()[_0x5d2743('0x21ab')](_0x2f0df9)+_0x5d2743('0x27d7'),'msg':_0x2e3ca0()[_0x5d2743('0x21ab')](_0x2f0df9)+'\x20has\x20been\x20deleted!'}),_0x5581e5();})['catch'](function(_0x50fb96){const _0x4dfb72=_0x3035fb;console[_0x4dfb72('0x52a')](_0x50fb96),_0xd5f439[_0x4dfb72('0x17f')]=_0x50fb96[_0x4dfb72('0x5a5')][_0x4dfb72('0x17f')]||[{'message':_0x50fb96['toString'](),'type':_0x4dfb72('0x70c')}];});},function(){});}function _0x471c25(){const _0x520330=_0x34b276;return _0xd5f439[_0x520330('0x23ef')][_0x520330('0x113b')]!==undefined?_0xd5f439['item']['variableName']:'Please\x20select\x20a\x20variable';}function _0x5581e5(){_0x2f3fb5['hide']();}}const _0x195d64=_0x1d3b7a;_0x3eba8c[_0x189033('0x14be')]=[_0x189033('0x938'),'$location','$mdDialog','$document',_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),'api',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x239d'),_0x189033('0x22df')];function _0x3eba8c(_0x3b1e8e,_0x434ca8,_0x208cf6,_0x3f6b40,_0xee0b24,_0x8c89c,_0x401702,_0x1b2c4f,_0x2f1600,_0x3f74d6,_0x528f4b,_0x5df094){const _0x1eba09=_0x189033,_0x8b39b3=this;_0x8b39b3[_0x1eba09('0x11ed')]=_0x3f74d6[_0x1eba09('0x20b2')](),_0x8b39b3['license']=_0x8c89c,_0x8b39b3[_0x1eba09('0x260a')]=_0x401702,_0x8b39b3[_0x1eba09('0x19b2')]=_0x8b39b3['setting'][_0x1eba09('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x8b39b3[_0x1eba09('0x1224')]=_0x434ca8[_0x1eba09('0x173e')]()+'://'+_0x434ca8[_0x1eba09('0x19ac')](),_0x8b39b3[_0x1eba09('0x239d')]=_0x528f4b||_0x3b1e8e[_0x1eba09('0x7f2')]['dynamics365Account']||{},_0x8b39b3['userProfileSection']=_0x5df094&&_0x5df094[_0x1eba09('0x50d')]==0x1?_0x5df094[_0x1eba09('0xf5d')][0x0]:null,_0x8b39b3[_0x1eba09('0x1134')]=_0x3f74d6[_0x1eba09('0x142a')](_0x8b39b3[_0x1eba09('0x22df')]?_0x8b39b3[_0x1eba09('0x22df')][_0x1eba09('0x1134')]:null),_0x8b39b3[_0x1eba09('0x258d')]={},_0x8b39b3[_0x1eba09('0x517')]=_0x3b1e8e['params'][_0x1eba09('0x1904')]||0x0,_0x8b39b3[_0x1eba09('0x2430')]=_0x2f1600[_0x1eba09('0x2289')],_0x8b39b3['gotoDynamics365Accounts']=_0xfb01d9,_0x8b39b3[_0x1eba09('0x2458')]=_0xd7181;function _0xfb01d9(){const _0x2ac939=_0x1eba09;_0x3b1e8e['go']('app.integrations.dynamics365Accounts',{},{'reload':_0x2ac939('0x2201')});}function _0xd7181(){const _0x28d0a8=_0x1eba09;_0x1b2c4f[_0x28d0a8('0x2601')][_0x28d0a8('0x2480')]({'id':_0x8b39b3[_0x28d0a8('0x239d')]['id']},_0x8b39b3[_0x28d0a8('0x239d')])[_0x28d0a8('0xe53')][_0x28d0a8('0x683')](function(){const _0x35c6a0=_0x28d0a8;_0x2f1600['success']({'title':_0x35c6a0('0x1443'),'msg':_0x8b39b3[_0x35c6a0('0x239d')][_0x35c6a0('0x60a')]?_0x8b39b3['dynamics365Account']['name']+'\x20has\x20been\x20updated!':''});})[_0x28d0a8('0x130a')](function(_0x31bc41){const _0x596ae1=_0x28d0a8;_0x2f1600['error']({'title':_0x31bc41[_0x596ae1('0x13ee')]?_0x596ae1('0x2168')+_0x31bc41[_0x596ae1('0x13ee')]+_0x596ae1('0xbf6')+_0x31bc41[_0x596ae1('0x24a9')]:_0x596ae1('0x263a'),'msg':_0x31bc41[_0x596ae1('0x5a5')]?JSON[_0x596ae1('0x258a')](_0x31bc41[_0x596ae1('0x5a5')]):_0x31bc41['toString']()});});}}const _0x4a548c=_0x3eba8c;_0x1136e3[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x107c'),'freshdeskAccount',_0x189033('0x56b'),'Auth','license',_0x189033('0x260a'),'crudPermissions'];function _0x1136e3(_0x45a1ca,_0x4d12c2,_0x462c23,_0x3b7b8b,_0x513624,_0x2cede1,_0x6cab88,_0x102cee,_0x44abe0,_0x13de02,_0xaf3a88,_0x1662fb,_0x26b014,_0x4184b3){const _0xcc211=_0x189033,_0x6ada79=this;_0x6ada79[_0xcc211('0x11ed')]=_0xaf3a88['getCurrentUser'](),_0x6ada79[_0xcc211('0x17f')]=[],_0x6ada79[_0xcc211('0x260a')]=_0x26b014,_0x6ada79[_0xcc211('0xace')]=_0x1662fb,_0x6ada79[_0xcc211('0x1134')]=_0x4184b3,_0x6ada79[_0xcc211('0x258d')]={},_0x6ada79[_0xcc211('0x19b2')]=_0x6ada79[_0xcc211('0x260a')]&&_0x6ada79['setting'][_0xcc211('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x6ada79['title']=_0xcc211('0x2389'),_0x6ada79[_0xcc211('0x1aee')]=angular[_0xcc211('0x1a86')](_0x44abe0),_0x6ada79[_0xcc211('0x107c')]=_0x102cee,_0x6ada79[_0xcc211('0x767')]=![];!_0x6ada79[_0xcc211('0x1aee')]&&(_0x6ada79['freshdeskAccount']={'serverUrl':_0x462c23[_0xcc211('0x173e')]()+_0xcc211('0x20de')+_0x462c23[_0xcc211('0x19ac')]()+(_0x462c23[_0xcc211('0x4a2')]()?':'+_0x462c23[_0xcc211('0x4a2')]():'')},_0x6ada79[_0xcc211('0xf28')]='INTEGRATIONS.NEW_FRESHDESKACCOUNT',_0x6ada79['newFreshdeskAccount']=!![]);_0x6ada79[_0xcc211('0x1c2')]=_0x2173a4,_0x6ada79[_0xcc211('0x23e')]=_0x4da783,_0x6ada79[_0xcc211('0x6ad')]=_0x5ee49a,_0x6ada79[_0xcc211('0x16b3')]=_0x430beb,_0x6ada79[_0xcc211('0xf82')]=_0x126f62;function _0x2173a4(){const _0x4d089f=_0xcc211;_0x6ada79['errors']=[],_0x13de02[_0x4d089f('0x15dc')][_0x4d089f('0xb0a')](_0x6ada79['freshdeskAccount'])[_0x4d089f('0xe53')][_0x4d089f('0x683')](function(_0x339881){const _0x4b1d83=_0x4d089f;_0x6ada79[_0x4b1d83('0x107c')][_0x4b1d83('0x1167')](_0x339881[_0x4b1d83('0x24e1')]()),_0x6cab88['success']({'title':_0x4b1d83('0x5e7'),'msg':_0x6ada79['freshdeskAccount'][_0x4b1d83('0x60a')]?_0x6ada79['freshdeskAccount'][_0x4b1d83('0x60a')]+_0x4b1d83('0x14b5'):''}),_0x126f62(_0x339881);})['catch'](function(_0x3debf7){const _0x24d85b=_0x4d089f;if(_0x3debf7[_0x24d85b('0x5a5')]&&_0x3debf7[_0x24d85b('0x5a5')][_0x24d85b('0x17f')]&&_0x3debf7['data'][_0x24d85b('0x17f')]['length']){_0x6ada79[_0x24d85b('0x17f')]=_0x3debf7[_0x24d85b('0x5a5')][_0x24d85b('0x17f')]||[{'message':_0x3debf7[_0x24d85b('0x1ff0')](),'type':_0x24d85b('0x185')}];for(let _0x408609=0x0;_0x408609<_0x3debf7[_0x24d85b('0x5a5')][_0x24d85b('0x17f')][_0x24d85b('0x1564')];_0x408609+=0x1){_0x6cab88[_0x24d85b('0x52a')]({'title':_0x3debf7[_0x24d85b('0x5a5')][_0x24d85b('0x17f')][_0x408609][_0x24d85b('0xcf0')],'msg':_0x3debf7[_0x24d85b('0x5a5')][_0x24d85b('0x17f')][_0x408609][_0x24d85b('0x8c2')]});}}else _0x6cab88[_0x24d85b('0x52a')]({'title':_0x3debf7[_0x24d85b('0x13ee')]?_0x24d85b('0x2168')+_0x3debf7[_0x24d85b('0x13ee')]+'\x20-\x20'+_0x3debf7['statusText']:_0x24d85b('0x185'),'msg':_0x3debf7[_0x24d85b('0x5a5')]?JSON[_0x24d85b('0x258a')](_0x3debf7[_0x24d85b('0x5a5')]['message']):_0x3debf7[_0x24d85b('0x1ff0')]()});});}function _0x4da783(){const _0x31e974=_0xcc211;_0x6ada79['errors']=[],_0x13de02[_0x31e974('0x15dc')][_0x31e974('0x2480')]({'id':_0x6ada79['freshdeskAccount']['id']},_0x6ada79[_0x31e974('0x1aee')])[_0x31e974('0xe53')][_0x31e974('0x683')](function(_0x5f5163){const _0x3257c1=_0x31e974,_0x54ab3f=_0x2e3ca0()[_0x3257c1('0x1c07')](_0x6ada79[_0x3257c1('0x107c')],{'id':_0x5f5163['id']});_0x54ab3f&&_0x2e3ca0()['merge'](_0x54ab3f,_0x2e3ca0()[_0x3257c1('0x24d0')](_0x5f5163[_0x3257c1('0x24e1')](),_0x2e3ca0()[_0x3257c1('0x55e')](_0x54ab3f))),_0x6cab88['success']({'title':_0x3257c1('0x2816'),'msg':_0x6ada79[_0x3257c1('0x1aee')][_0x3257c1('0x60a')]?_0x6ada79['freshdeskAccount']['name']+'\x20has\x20been\x20saved!':''}),_0x126f62(_0x5f5163);})['catch'](function(_0xc991c3){const _0x41443e=_0x31e974;if(_0xc991c3[_0x41443e('0x5a5')]&&_0xc991c3[_0x41443e('0x5a5')][_0x41443e('0x17f')]&&_0xc991c3[_0x41443e('0x5a5')][_0x41443e('0x17f')][_0x41443e('0x1564')]){_0x6ada79[_0x41443e('0x17f')]=_0xc991c3[_0x41443e('0x5a5')][_0x41443e('0x17f')]||[{'message':_0xc991c3['toString'](),'type':_0x41443e('0xe5c')}];for(let _0x365452=0x0;_0x365452<_0xc991c3[_0x41443e('0x5a5')][_0x41443e('0x17f')][_0x41443e('0x1564')];_0x365452++){_0x6cab88[_0x41443e('0x52a')]({'title':_0xc991c3['data'][_0x41443e('0x17f')][_0x365452][_0x41443e('0xcf0')],'msg':_0xc991c3[_0x41443e('0x5a5')][_0x41443e('0x17f')][_0x365452]['message']});}}else _0x6cab88[_0x41443e('0x52a')]({'title':_0xc991c3[_0x41443e('0x13ee')]?_0x41443e('0x2168')+_0xc991c3[_0x41443e('0x13ee')]+_0x41443e('0xbf6')+_0xc991c3[_0x41443e('0x24a9')]:'api.intFreshdeskAccount.update','msg':_0xc991c3['data']?JSON[_0x41443e('0x258a')](_0xc991c3[_0x41443e('0x5a5')][_0x41443e('0x8c2')]):_0xc991c3[_0x41443e('0x1ff0')]()});});}function _0x5ee49a(_0x18d364){const _0xdc66ab=_0xcc211;_0x6ada79[_0xdc66ab('0x17f')]=[];const _0x1273ee=_0x3b7b8b[_0xdc66ab('0x1c6f')]()[_0xdc66ab('0xf28')](_0xdc66ab('0x4d'))[_0xdc66ab('0xa6a')](_0xdc66ab('0xf79'))[_0xdc66ab('0x1040')]('Delete\x20FreshdeskAccount')['ok'](_0xdc66ab('0x2307'))['cancel'](_0xdc66ab('0x253a'))[_0xdc66ab('0xe42')](_0x18d364);_0x3b7b8b['show'](_0x1273ee)[_0xdc66ab('0x683')](function(){const _0x1d888c=_0xdc66ab;_0x13de02[_0x1d888c('0x15dc')]['delete']({'id':_0x6ada79[_0x1d888c('0x1aee')]['id']})[_0x1d888c('0xe53')][_0x1d888c('0x683')](function(){const _0x191187=_0x1d888c;_0x2e3ca0()[_0x191187('0x3ec')](_0x6ada79[_0x191187('0x107c')],{'id':_0x6ada79[_0x191187('0x1aee')]['id']}),_0x6cab88['success']({'title':_0x191187('0x1b24'),'msg':(_0x6ada79[_0x191187('0x1aee')][_0x191187('0x60a')]||'freshdeskAccount')+_0x191187('0x194d')}),_0x126f62(_0x6ada79['freshdeskAccount']);})[_0x1d888c('0x130a')](function(_0x11bbfe){const _0x330f38=_0x1d888c;if(_0x11bbfe[_0x330f38('0x5a5')]&&_0x11bbfe[_0x330f38('0x5a5')][_0x330f38('0x17f')]&&_0x11bbfe[_0x330f38('0x5a5')][_0x330f38('0x17f')][_0x330f38('0x1564')]){_0x6ada79['errors']=_0x11bbfe[_0x330f38('0x5a5')][_0x330f38('0x17f')]||[{'message':_0x11bbfe['toString'](),'type':_0x330f38('0x1a7b')}];for(let _0x4d2a84=0x0;_0x4d2a84<_0x11bbfe[_0x330f38('0x5a5')][_0x330f38('0x17f')]['length'];_0x4d2a84++){_0x6cab88[_0x330f38('0x52a')]({'title':_0x11bbfe['data'][_0x330f38('0x17f')][_0x4d2a84][_0x330f38('0xcf0')],'msg':_0x11bbfe[_0x330f38('0x5a5')]['errors'][_0x4d2a84]['message']});}}else _0x6cab88[_0x330f38('0x52a')]({'title':_0x11bbfe[_0x330f38('0x13ee')]?_0x330f38('0x2168')+_0x11bbfe[_0x330f38('0x13ee')]+_0x330f38('0xbf6')+_0x11bbfe[_0x330f38('0x24a9')]:_0x330f38('0x1a7b'),'msg':_0x11bbfe[_0x330f38('0x5a5')]?JSON[_0x330f38('0x258a')](_0x11bbfe['data']['message']):_0x11bbfe[_0x330f38('0x8c2')]||_0x11bbfe['toString']()});});},function(){});}function _0x430beb(_0x477254){return _0x477254===null?undefined:new Date(_0x477254);}function _0x126f62(_0xc8d9ba){_0x3b7b8b['hide'](_0xc8d9ba);}}const _0x182e52=_0x1136e3,_0x5dfef1=_0x180212['p']+_0x189033('0x1c23'),_0x113d84=_0x180212['p']+_0x189033('0x1d98');_0x938227[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$document',_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1')];function _0x938227(_0x248ae5,_0x201d2a,_0x5942cb,_0x16af84,_0x477b10){const _0x420f3f=_0x189033,_0x343124=this;_0x343124['currentUser']=_0x477b10[_0x420f3f('0x20b2')](),_0x343124[_0x420f3f('0x1aee')]={},_0x343124[_0x420f3f('0x1957')]={},_0x343124[_0x420f3f('0x1573')]=[],_0x343124['selectedFreshdeskConfiguration']=-0x1,_0x343124[_0x420f3f('0x1134')],_0x343124[_0x420f3f('0x12f3')]=_0x1c9d62,_0x343124[_0x420f3f('0x19e5')]=_0x2b4b48,_0x343124['createOrEditFreshdeskConfiguration']=_0x43f215,_0x343124['deleteFreshdeskConfiguration']=_0x4fd893,_0x343124[_0x420f3f('0x2100')]=[],_0x343124[_0x420f3f('0x20fd')]=_0x162960,_0x5942cb[_0x420f3f('0x270')][_0x420f3f('0x1e6e')]({'nolimit':!![],'sort':'name'})['$promise']['then'](function(_0x324973){const _0x4da5a8=_0x420f3f;_0x343124['tags']=_0x324973[_0x4da5a8('0xf5d')]?_0x324973[_0x4da5a8('0xf5d')]:[];})['catch'](function(_0x7ce00a){const _0x268ea5=_0x420f3f;_0x16af84[_0x268ea5('0x52a')]({'title':_0x7ce00a[_0x268ea5('0x13ee')]?_0x268ea5('0x2168')+_0x7ce00a['status']+_0x268ea5('0xbf6')+_0x7ce00a['statusText']:_0x268ea5('0x10a4'),'msg':_0x7ce00a[_0x268ea5('0x5a5')]?JSON[_0x268ea5('0x258a')](_0x7ce00a[_0x268ea5('0x5a5')]):_0x7ce00a[_0x268ea5('0x1ff0')]()});});function _0x162960(){const _0x1d8a40=_0x420f3f;_0x5942cb[_0x1d8a40('0xf2d')]['setTags']({'id':_0x343124[_0x1d8a40('0x1957')]['id'],'ids':_0x343124['selectedTags']})[_0x1d8a40('0xe53')][_0x1d8a40('0x683')](function(){const _0x5cef77=_0x1d8a40;_0x16af84[_0x5cef77('0x53')]({'title':_0x5cef77('0xc9b'),'msg':'Tags\x20has\x20been\x20set!'});})[_0x1d8a40('0x130a')](function(_0x55a90c){const _0x19eece=_0x1d8a40;_0x16af84[_0x19eece('0x52a')]({'title':_0x55a90c[_0x19eece('0x13ee')]?'API:'+_0x55a90c['status']+'\x20-\x20'+_0x55a90c[_0x19eece('0x24a9')]:_0x19eece('0x137d'),'msg':_0x55a90c[_0x19eece('0x5a5')]?JSON[_0x19eece('0x258a')](_0x55a90c[_0x19eece('0x5a5')]):_0x55a90c[_0x19eece('0x1ff0')]()});});}function _0x1c9d62(_0x372c27,_0xc47ef3){const _0x2715cf=_0x420f3f;_0x343124[_0x2715cf('0x1aee')]=_0x372c27,_0x343124[_0x2715cf('0x1134')]=typeof _0xc47ef3!=='undefined'?_0xc47ef3:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x5942cb[_0x2715cf('0x15dc')]['getConfigurations']({'id':_0x343124[_0x2715cf('0x1aee')]['id'],'sort':_0x2715cf('0xc36')})[_0x2715cf('0xe53')]['then'](function(_0x1f1a4b){const _0x4f0c96=_0x2715cf;return _0x343124['configurations']=_0x1f1a4b[_0x4f0c96('0xf5d')]?_0x1f1a4b['rows']:[],_0x343124[_0x4f0c96('0x1573')]['length']&&_0x343124[_0x4f0c96('0x19e5')](0x0),_0x5942cb['variable'][_0x4f0c96('0x1e6e')]({'nolimit':!![],'sort':'name'})[_0x4f0c96('0xe53')];})[_0x2715cf('0x683')](function(_0x58639b){const _0x5504a2=_0x2715cf;_0x343124[_0x5504a2('0x220b')]=_0x58639b[_0x5504a2('0xf5d')]?_0x58639b[_0x5504a2('0xf5d')]:[],_0x343124[_0x5504a2('0x1822')]=_0x2e3ca0()[_0x5504a2('0x24db')](_0x343124[_0x5504a2('0x220b')],'id');})[_0x2715cf('0x130a')](function(_0x4bac1d){const _0x239d88=_0x2715cf;_0x16af84[_0x239d88('0x52a')]({'title':_0x4bac1d['status']?_0x239d88('0x2168')+_0x4bac1d[_0x239d88('0x13ee')]+'\x20-\x20'+_0x4bac1d[_0x239d88('0x24a9')]:_0x239d88('0xe2a'),'msg':_0x4bac1d[_0x239d88('0x5a5')]?JSON['stringify'](_0x4bac1d[_0x239d88('0x5a5')]):_0x4bac1d[_0x239d88('0x1ff0')]()});});}function _0x2b4b48(_0x4c7c21){const _0x3532a6=_0x420f3f;_0x343124[_0x3532a6('0x1957')]=_0x343124['configurations'][_0x4c7c21],_0x343124[_0x3532a6('0xbec')]=_0x4c7c21,_0x5942cb[_0x3532a6('0xf2d')][_0x3532a6('0x20ac')]({'id':_0x343124[_0x3532a6('0x1957')]['id']})[_0x3532a6('0xe53')][_0x3532a6('0x683')](function(_0x24d8fe){const _0x4c44ed=_0x3532a6;return _0x343124[_0x4c44ed('0x1ead')]=_0x24d8fe['rows']?_0x24d8fe['rows']:[],_0x5942cb[_0x4c44ed('0xf2d')][_0x4c44ed('0x412')]({'id':_0x343124['freshdeskConfiguration']['id']})['$promise'];})[_0x3532a6('0x683')](function(_0x19cf3d){const _0x3d1968=_0x3532a6;return _0x343124[_0x3d1968('0x18f7')]=_0x19cf3d[_0x3d1968('0xf5d')]?_0x19cf3d[_0x3d1968('0xf5d')]:[],_0x5942cb[_0x3d1968('0xf2d')]['getFields']({'id':_0x343124[_0x3d1968('0x1957')]['id']})['$promise'];})[_0x3532a6('0x683')](function(_0x290cc1){const _0x3d5f88=_0x3532a6;_0x343124['fields']=_0x290cc1[_0x3d5f88('0xf5d')]?_0x290cc1['rows']:[];})[_0x3532a6('0x130a')](function(_0x2cdd94){const _0x4aca98=_0x3532a6;_0x16af84['error']({'title':_0x2cdd94[_0x4aca98('0x13ee')]?_0x4aca98('0x2168')+_0x2cdd94['status']+_0x4aca98('0xbf6')+_0x2cdd94[_0x4aca98('0x24a9')]:_0x4aca98('0x167c'),'msg':_0x2cdd94[_0x4aca98('0x5a5')]?JSON['stringify'](_0x2cdd94[_0x4aca98('0x5a5')]):_0x2cdd94[_0x4aca98('0x1ff0')]()});}),_0x5942cb[_0x3532a6('0xf2d')]['getTags']({'id':_0x343124[_0x3532a6('0x1957')]['id']})['$promise'][_0x3532a6('0x683')](function(_0x55eeac){const _0x54a218=_0x3532a6;_0x343124[_0x54a218('0x2100')]=_0x55eeac['rows']?_0x2e3ca0()[_0x54a218('0x386')](_0x55eeac['rows'],'id'):[];})[_0x3532a6('0x130a')](function(_0x3c3e8f){const _0x49d250=_0x3532a6;_0x16af84[_0x49d250('0x52a')]({'title':_0x3c3e8f[_0x49d250('0x13ee')]?_0x49d250('0x2168')+_0x3c3e8f['status']+'\x20-\x20'+_0x3c3e8f[_0x49d250('0x24a9')]:_0x49d250('0x10a4'),'msg':_0x3c3e8f['data']?JSON[_0x49d250('0x258a')](_0x3c3e8f[_0x49d250('0x5a5')]):_0x3c3e8f['toString']()});});}function _0x43f215(_0x48d701,_0x564250){const _0x1e3b20=_0x420f3f;_0x248ae5[_0x1e3b20('0x1d4')]({'controller':_0x1e3b20('0xd80'),'controllerAs':'vm','templateUrl':_0x5dfef1,'parent':angular[_0x1e3b20('0x1fcc')](_0x201d2a[_0x1e3b20('0x18e5')]),'targetEvent':_0x48d701,'clickOutsideToClose':!![],'locals':{'freshdeskConfiguration':_0x564250,'configurations':_0x343124[_0x1e3b20('0x1573')],'license':null,'setting':null,'crudPermissions':_0x343124[_0x1e3b20('0x1134')]}})[_0x1e3b20('0x2874')](function(){_0x343124['getFreshdeskConfiguration'](0x0);});}function _0x4fd893(_0x4c0056,_0x42e528){const _0x269c58=_0x420f3f,_0x88c230=_0x248ae5['confirm']()[_0x269c58('0xf28')](_0x269c58('0x1749'))[_0x269c58('0x26e3')](_0x269c58('0xed5')+(_0x42e528[_0x269c58('0x60a')]||_0x269c58('0x1957'))+''+_0x269c58('0x1ee7'))[_0x269c58('0x1040')](_0x269c58('0x878'))[_0x269c58('0xe42')](_0x4c0056)['ok']('OK')[_0x269c58('0x19fb')](_0x269c58('0x16b8'));_0x248ae5[_0x269c58('0x1d4')](_0x88c230)[_0x269c58('0x683')](function(){const _0x492423=_0x269c58;_0x5942cb[_0x492423('0xf2d')][_0x492423('0xd7e')]({'id':_0x42e528['id']})['$promise']['then'](function(){const _0x41f96d=_0x492423;_0x2e3ca0()[_0x41f96d('0x3ec')](_0x343124[_0x41f96d('0x1573')],{'id':_0x42e528['id']}),_0x16af84[_0x41f96d('0x53')]({'title':_0x41f96d('0x89e'),'msg':_0x42e528[_0x41f96d('0x60a')]?_0x42e528[_0x41f96d('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0x492423('0x130a')](function(_0x129c28){const _0x44d87e=_0x492423;_0x16af84[_0x44d87e('0x52a')]({'title':_0x129c28[_0x44d87e('0x13ee')]?_0x44d87e('0x2168')+_0x129c28[_0x44d87e('0x13ee')]+'\x20-\x20'+_0x129c28[_0x44d87e('0x24a9')]:_0x44d87e('0x1e44'),'msg':_0x129c28[_0x44d87e('0x5a5')]?JSON['stringify'](_0x129c28[_0x44d87e('0x5a5')]):_0x129c28[_0x44d87e('0x1ff0')]()});})[_0x492423('0x2874')](function(){const _0x3ab274=_0x492423;_0x343124[_0x3ab274('0x19e5')](0x0);});},function(){const _0x208b9a=_0x269c58;console[_0x208b9a('0x1b2b')](_0x208b9a('0x16b8'));});}_0x343124['selectedSubjects']=[],_0x343124[_0x420f3f('0x2654')]=_0x350c9c,_0x343124[_0x420f3f('0x2802')]=_0x2ad1ca,_0x343124[_0x420f3f('0x1734')]=_0x11b7b6;function _0x350c9c(_0x1b458e,_0x5cf038){const _0x3341b6=_0x420f3f;_0x248ae5[_0x3341b6('0x1d4')]({'controller':_0x3341b6('0x96'),'controllerAs':'vm','templateUrl':_0x113d84,'parent':angular['element'](_0x201d2a[_0x3341b6('0x18e5')]),'targetEvent':_0x1b458e,'clickOutsideToClose':!![],'locals':{'type':'subject','item':_0x5cf038,'items':_0x343124[_0x3341b6('0x1ead')],'configuration':_0x343124[_0x3341b6('0x1957')],'account':_0x343124[_0x3341b6('0x1aee')],'license':null,'setting':null,'crudPermissions':_0x343124[_0x3341b6('0x1134')]}});}function _0x1aa007(_0x14f114){const _0x40373c=_0x420f3f;_0x5942cb[_0x40373c('0x847')]['delete']({'id':_0x14f114['id']})[_0x40373c('0xe53')][_0x40373c('0x683')](function(){const _0x4febac=_0x40373c;_0x2e3ca0()[_0x4febac('0x3ec')](_0x343124[_0x4febac('0x1ead')],{'id':_0x14f114['id']}),_0x16af84[_0x4febac('0x53')]({'title':_0x4febac('0x637'),'msg':'Subject\x20has\x20been\x20deleted!'});})['catch'](function(_0x14e6b4){const _0x5ab63e=_0x40373c;_0x16af84[_0x5ab63e('0x52a')]({'title':_0x14e6b4[_0x5ab63e('0x13ee')]?_0x5ab63e('0x2168')+_0x14e6b4[_0x5ab63e('0x13ee')]+_0x5ab63e('0xbf6')+_0x14e6b4[_0x5ab63e('0x24a9')]:_0x5ab63e('0x1d23'),'msg':_0x14e6b4[_0x5ab63e('0x5a5')]?JSON[_0x5ab63e('0x258a')](_0x14e6b4['data']):_0x14e6b4['toString']()});});}function _0x2ad1ca(_0xc647de,_0x119690){const _0x8bf986=_0x420f3f,_0xa3e8f5=_0x248ae5[_0x8bf986('0x1c6f')]()[_0x8bf986('0xf28')](_0x8bf986('0x17ed'))['htmlContent'](_0x8bf986('0x601')+_0x8bf986('0x1ee7'))['ariaLabel'](_0x8bf986('0x20d'))[_0x8bf986('0xe42')](_0xc647de)['ok']('OK')['cancel'](_0x8bf986('0x16b8'));_0x248ae5['show'](_0xa3e8f5)['then'](function(){_0x1aa007(_0x119690);},function(){const _0x1d4daf=_0x8bf986;console[_0x1d4daf('0x1b2b')]('CANCEL');});}function _0x11b7b6(_0x5cfd97){const _0x539129=_0x420f3f,_0x4f82b1=_0x248ae5[_0x539129('0x1c6f')]()[_0x539129('0xf28')](_0x539129('0xad5'))[_0x539129('0x26e3')](''+_0x343124[_0x539129('0x1781')][_0x539129('0x1564')]+_0x539129('0x93c')+_0x539129('0x1ee7'))[_0x539129('0x1040')](_0x539129('0x9fb'))[_0x539129('0xe42')](_0x5cfd97)['ok']('OK')[_0x539129('0x19fb')](_0x539129('0x16b8'));_0x248ae5[_0x539129('0x1d4')](_0x4f82b1)[_0x539129('0x683')](function(){const _0x3744a6=_0x539129;_0x343124[_0x3744a6('0x1781')][_0x3744a6('0x1299')](function(_0x2d349f){_0x1aa007(_0x2d349f);}),_0x343124[_0x3744a6('0x1781')]=[];});}_0x343124[_0x420f3f('0xcb1')]=[],_0x343124['createOrEditDescription']=_0xc442b9,_0x343124[_0x420f3f('0x27b2')]=_0x17fe4d,_0x343124['deleteSelectedDescriptions']=_0x4074ea;function _0xc442b9(_0x362841,_0x4d270c){const _0xb5d166=_0x420f3f;_0x248ae5[_0xb5d166('0x1d4')]({'controller':_0xb5d166('0x96'),'controllerAs':'vm','templateUrl':_0x113d84,'parent':angular['element'](_0x201d2a[_0xb5d166('0x18e5')]),'targetEvent':_0x362841,'clickOutsideToClose':!![],'locals':{'type':'description','item':_0x4d270c,'items':_0x343124['descriptions'],'configuration':_0x343124[_0xb5d166('0x1957')],'account':_0x343124[_0xb5d166('0x1aee')],'license':null,'setting':null,'crudPermissions':_0x343124[_0xb5d166('0x1134')]}});}function _0xcb233d(_0xe276a8){const _0x937259=_0x420f3f;_0x5942cb[_0x937259('0x847')][_0x937259('0xd7e')]({'id':_0xe276a8['id']})[_0x937259('0xe53')][_0x937259('0x683')](function(){const _0xdacf16=_0x937259;_0x2e3ca0()[_0xdacf16('0x3ec')](_0x343124['descriptions'],{'id':_0xe276a8['id']}),_0x16af84[_0xdacf16('0x53')]({'title':_0xdacf16('0x1cf8'),'msg':_0xdacf16('0x21c7')});})[_0x937259('0x130a')](function(_0x4e8e4f){const _0x35b43b=_0x937259;_0x16af84['error']({'title':_0x4e8e4f['status']?'API:'+_0x4e8e4f['status']+_0x35b43b('0xbf6')+_0x4e8e4f['statusText']:_0x35b43b('0x1d23'),'msg':_0x4e8e4f['data']?JSON[_0x35b43b('0x258a')](_0x4e8e4f['data']):_0x4e8e4f[_0x35b43b('0x1ff0')]()});});}function _0x17fe4d(_0x5f5b7d,_0x378d28){const _0x4d5a76=_0x420f3f,_0x178bfc=_0x248ae5['confirm']()[_0x4d5a76('0xf28')](_0x4d5a76('0xb72'))['htmlContent']('Description'+_0x4d5a76('0x1ee7'))[_0x4d5a76('0x1040')]('delete\x20description')[_0x4d5a76('0xe42')](_0x5f5b7d)['ok']('OK')['cancel']('CANCEL');_0x248ae5[_0x4d5a76('0x1d4')](_0x178bfc)[_0x4d5a76('0x683')](function(){_0xcb233d(_0x378d28);},function(){const _0x7bf29b=_0x4d5a76;console[_0x7bf29b('0x1b2b')](_0x7bf29b('0x16b8'));});}function _0x4074ea(_0x406eac){const _0x2ed4ed=_0x420f3f,_0x347dbc=_0x248ae5[_0x2ed4ed('0x1c6f')]()[_0x2ed4ed('0xf28')](_0x2ed4ed('0x1984'))[_0x2ed4ed('0x26e3')](_0x2ed4ed('0xed5')+_0x343124['selectedDescriptions'][_0x2ed4ed('0x1564')]+'\x20selected'+_0x2ed4ed('0x1ee7'))[_0x2ed4ed('0x1040')](_0x2ed4ed('0x1859'))[_0x2ed4ed('0xe42')](_0x406eac)['ok']('OK')[_0x2ed4ed('0x19fb')](_0x2ed4ed('0x16b8'));_0x248ae5[_0x2ed4ed('0x1d4')](_0x347dbc)[_0x2ed4ed('0x683')](function(){const _0x5e129c=_0x2ed4ed;_0x343124[_0x5e129c('0xcb1')][_0x5e129c('0x1299')](function(_0x4c1270){_0xcb233d(_0x4c1270);}),_0x343124[_0x5e129c('0xcb1')]=[];});}_0x343124[_0x420f3f('0x310')]=[],_0x343124[_0x420f3f('0x84f')]=_0x34e5cc,_0x343124[_0x420f3f('0x9f9')]=_0x20287e,_0x343124[_0x420f3f('0x204e')]=_0x5c5b02;function _0x34e5cc(_0x394f45,_0x253eaf){const _0x1d6293=_0x420f3f;_0x248ae5[_0x1d6293('0x1d4')]({'controller':'CreateOrEditFreshdeskAccountItemDialogController','controllerAs':'vm','templateUrl':_0x113d84,'parent':angular[_0x1d6293('0x1fcc')](_0x201d2a[_0x1d6293('0x18e5')]),'targetEvent':_0x394f45,'clickOutsideToClose':!![],'locals':{'type':_0x1d6293('0x2013'),'item':_0x253eaf,'items':_0x343124['fields'],'configuration':_0x343124[_0x1d6293('0x1957')],'account':_0x343124[_0x1d6293('0x1aee')],'license':null,'setting':null,'crudPermissions':_0x343124[_0x1d6293('0x1134')]}});}function _0x40ee70(_0x4c166c){const _0x32694b=_0x420f3f;_0x5942cb[_0x32694b('0x847')][_0x32694b('0xd7e')]({'id':_0x4c166c['id']})[_0x32694b('0xe53')][_0x32694b('0x683')](function(){const _0x138f0a=_0x32694b;_0x2e3ca0()[_0x138f0a('0x3ec')](_0x343124[_0x138f0a('0x189a')],{'id':_0x4c166c['id']}),_0x16af84['success']({'title':_0x138f0a('0x1666'),'msg':_0x138f0a('0x1eda')});})['catch'](function(_0xace82e){const _0x5ab9ac=_0x32694b;_0x16af84[_0x5ab9ac('0x52a')]({'title':_0xace82e[_0x5ab9ac('0x13ee')]?_0x5ab9ac('0x2168')+_0xace82e[_0x5ab9ac('0x13ee')]+_0x5ab9ac('0xbf6')+_0xace82e[_0x5ab9ac('0x24a9')]:_0x5ab9ac('0x1d23'),'msg':_0xace82e['data']?JSON[_0x5ab9ac('0x258a')](_0xace82e[_0x5ab9ac('0x5a5')]):_0xace82e['toString']()});});}function _0x20287e(_0x541073,_0x54fe09){const _0x266ef9=_0x420f3f,_0x285c73=_0x248ae5[_0x266ef9('0x1c6f')]()[_0x266ef9('0xf28')](_0x266ef9('0x16b5'))[_0x266ef9('0x26e3')]('Field'+_0x266ef9('0x1ee7'))[_0x266ef9('0x1040')]('delete\x20field')[_0x266ef9('0xe42')](_0x541073)['ok']('OK')[_0x266ef9('0x19fb')]('CANCEL');_0x248ae5['show'](_0x285c73)[_0x266ef9('0x683')](function(){_0x40ee70(_0x54fe09);},function(){const _0x4895c1=_0x266ef9;console[_0x4895c1('0x1b2b')](_0x4895c1('0x16b8'));});}function _0x5c5b02(_0x7c40b){const _0x54ebb2=_0x420f3f,_0x23c790=_0x248ae5[_0x54ebb2('0x1c6f')]()[_0x54ebb2('0xf28')](_0x54ebb2('0x19b1'))[_0x54ebb2('0x26e3')](''+_0x343124[_0x54ebb2('0x310')][_0x54ebb2('0x1564')]+_0x54ebb2('0x93c')+_0x54ebb2('0x1ee7'))[_0x54ebb2('0x1040')](_0x54ebb2('0x994'))[_0x54ebb2('0xe42')](_0x7c40b)['ok']('OK')['cancel'](_0x54ebb2('0x16b8'));_0x248ae5['show'](_0x23c790)[_0x54ebb2('0x683')](function(){const _0x2453ba=_0x54ebb2;_0x343124['selectedFields'][_0x2453ba('0x1299')](function(_0x4663c0){_0x40ee70(_0x4663c0);}),_0x343124[_0x2453ba('0x310')]=[];});}}const _0xd5c486=_0x938227;_0x5b9538[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1573'),'freshdeskConfiguration',_0x189033('0x56b'),'Auth',_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x5b9538(_0x56419e,_0x14ad63,_0xe2d6e4,_0x4c130d,_0x1ecb31,_0x3caa46,_0x11851c,_0x1fa185,_0x1b897a,_0x21367f,_0x39d00c,_0x28f7bd,_0x4e8328,_0x53071b){const _0x6498af=_0x189033,_0x465dfa=this;_0x465dfa['currentUser']=_0x39d00c[_0x6498af('0x20b2')](),_0x465dfa['errors']=[],_0x465dfa[_0x6498af('0x260a')]=_0x4e8328,_0x465dfa[_0x6498af('0xace')]=_0x28f7bd,_0x465dfa['crudPermissions']=_0x53071b,_0x465dfa['hasModulePermissions']={},_0x465dfa[_0x6498af('0x19b2')]=_0x465dfa[_0x6498af('0x260a')]&&_0x465dfa[_0x6498af('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x465dfa['title']=_0x6498af('0x16c0'),_0x465dfa[_0x6498af('0x1957')]=angular[_0x6498af('0x1a86')](_0x1b897a),_0x465dfa[_0x6498af('0x1573')]=_0x1fa185,_0x465dfa[_0x6498af('0x14bb')]=![];!_0x465dfa[_0x6498af('0x1957')]&&(_0x465dfa['freshdeskConfiguration']={'channel':_0x6498af('0xcf2'),'type':_0x6498af('0x1535')},_0x465dfa[_0x6498af('0xf28')]=_0x6498af('0x16db'),_0x465dfa[_0x6498af('0x14bb')]=!![]);_0x465dfa[_0x6498af('0x24e9')]=_0x7af6a5,_0x465dfa[_0x6498af('0x95e')]=_0x345f4c,_0x465dfa[_0x6498af('0xb61')]=_0x4ffde3,_0x465dfa['getDateFromString']=_0x465a59,_0x465dfa[_0x6498af('0xf82')]=_0x5bd2c8;function _0x7af6a5(){const _0x275c64=_0x6498af;_0x465dfa[_0x275c64('0x17f')]=[],_0x21367f[_0x275c64('0x15dc')][_0x275c64('0x2003')]({'id':_0x14ad63[_0x275c64('0x7f2')]['id']},_0x465dfa[_0x275c64('0x1957')])[_0x275c64('0xe53')][_0x275c64('0x683')](function(_0x3eb4f2){const _0x476f06=_0x275c64;_0x465dfa[_0x476f06('0x1573')][_0x476f06('0x1167')](_0x3eb4f2[_0x476f06('0x24e1')]()),_0x11851c[_0x476f06('0x53')]({'title':_0x476f06('0x1193'),'msg':_0x465dfa[_0x476f06('0x1957')][_0x476f06('0x60a')]?_0x465dfa['freshdeskConfiguration'][_0x476f06('0x60a')]+'\x20has\x20been\x20created!':''}),_0x5bd2c8(_0x3eb4f2);})[_0x275c64('0x130a')](function(_0x4c20db){const _0x55501c=_0x275c64;if(_0x4c20db[_0x55501c('0x5a5')]&&_0x4c20db[_0x55501c('0x5a5')][_0x55501c('0x17f')]&&_0x4c20db[_0x55501c('0x5a5')][_0x55501c('0x17f')]['length']){_0x465dfa[_0x55501c('0x17f')]=_0x4c20db['data'][_0x55501c('0x17f')]||[{'message':_0x4c20db[_0x55501c('0x1ff0')](),'type':_0x55501c('0x2198')}];for(let _0x34e7c7=0x0;_0x34e7c7<_0x4c20db[_0x55501c('0x5a5')]['errors'][_0x55501c('0x1564')];_0x34e7c7+=0x1){_0x11851c[_0x55501c('0x52a')]({'title':_0x4c20db[_0x55501c('0x5a5')][_0x55501c('0x17f')][_0x34e7c7]['type'],'msg':_0x4c20db['data']['errors'][_0x34e7c7][_0x55501c('0x8c2')]});}}else _0x11851c[_0x55501c('0x52a')]({'title':_0x4c20db[_0x55501c('0x13ee')]?_0x55501c('0x2168')+_0x4c20db[_0x55501c('0x13ee')]+_0x55501c('0xbf6')+_0x4c20db[_0x55501c('0x24a9')]:'api.intFreshdeskConfiguration.save','msg':_0x4c20db[_0x55501c('0x5a5')]?JSON[_0x55501c('0x258a')](_0x4c20db['data'][_0x55501c('0x8c2')]):_0x4c20db[_0x55501c('0x1ff0')]()});});}function _0x345f4c(){const _0x3c284e=_0x6498af;_0x465dfa['errors']=[],_0x21367f['intFreshdeskConfiguration'][_0x3c284e('0x2480')]({'id':_0x465dfa[_0x3c284e('0x1957')]['id']},_0x465dfa[_0x3c284e('0x1957')])[_0x3c284e('0xe53')]['then'](function(_0x402626){const _0x1d5d27=_0x3c284e,_0x556868=_0x2e3ca0()[_0x1d5d27('0x1c07')](_0x465dfa[_0x1d5d27('0x1573')],{'id':_0x402626['id']});_0x556868&&_0x2e3ca0()['merge'](_0x556868,_0x2e3ca0()[_0x1d5d27('0x24d0')](_0x402626[_0x1d5d27('0x24e1')](),_0x2e3ca0()['keys'](_0x556868))),_0x11851c['success']({'title':_0x1d5d27('0x13fd'),'msg':_0x465dfa[_0x1d5d27('0x1957')][_0x1d5d27('0x60a')]?_0x465dfa[_0x1d5d27('0x1957')][_0x1d5d27('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x5bd2c8(_0x402626);})[_0x3c284e('0x130a')](function(_0x4bf1c9){const _0xe625b5=_0x3c284e;if(_0x4bf1c9[_0xe625b5('0x5a5')]&&_0x4bf1c9[_0xe625b5('0x5a5')][_0xe625b5('0x17f')]&&_0x4bf1c9['data'][_0xe625b5('0x17f')]['length']){_0x465dfa[_0xe625b5('0x17f')]=_0x4bf1c9[_0xe625b5('0x5a5')][_0xe625b5('0x17f')]||[{'message':_0x4bf1c9[_0xe625b5('0x1ff0')](),'type':_0xe625b5('0x1adb')}];for(let _0x8ade34=0x0;_0x8ade34<_0x4bf1c9[_0xe625b5('0x5a5')]['errors'][_0xe625b5('0x1564')];_0x8ade34++){_0x11851c[_0xe625b5('0x52a')]({'title':_0x4bf1c9['data']['errors'][_0x8ade34][_0xe625b5('0xcf0')],'msg':_0x4bf1c9['data'][_0xe625b5('0x17f')][_0x8ade34][_0xe625b5('0x8c2')]});}}else _0x11851c[_0xe625b5('0x52a')]({'title':_0x4bf1c9[_0xe625b5('0x13ee')]?_0xe625b5('0x2168')+_0x4bf1c9[_0xe625b5('0x13ee')]+_0xe625b5('0xbf6')+_0x4bf1c9[_0xe625b5('0x24a9')]:_0xe625b5('0x1adb'),'msg':_0x4bf1c9[_0xe625b5('0x5a5')]?JSON['stringify'](_0x4bf1c9[_0xe625b5('0x5a5')][_0xe625b5('0x8c2')]):_0x4bf1c9[_0xe625b5('0x1ff0')]()});});}function _0x4ffde3(_0x403a66){const _0x544066=_0x6498af;_0x465dfa[_0x544066('0x17f')]=[];const _0x9029be=_0x4c130d[_0x544066('0x1c6f')]()[_0x544066('0xf28')](_0x544066('0x4d'))[_0x544066('0xa6a')]('The\x20freshdeskConfiguration\x20will\x20be\x20deleted.')[_0x544066('0x1040')](_0x544066('0x1ba5'))['ok'](_0x544066('0x2307'))[_0x544066('0x19fb')](_0x544066('0x253a'))['targetEvent'](_0x403a66);_0x4c130d['show'](_0x9029be)[_0x544066('0x683')](function(){const _0xdc22cd=_0x544066;_0x21367f[_0xdc22cd('0xf2d')][_0xdc22cd('0xd7e')]({'id':_0x465dfa[_0xdc22cd('0x1957')]['id']})[_0xdc22cd('0xe53')][_0xdc22cd('0x683')](function(){const _0x4962c7=_0xdc22cd;_0x2e3ca0()['remove'](_0x465dfa[_0x4962c7('0x1573')],{'id':_0x465dfa[_0x4962c7('0x1957')]['id']}),_0x11851c['success']({'title':_0x4962c7('0x1ef2'),'msg':(_0x465dfa[_0x4962c7('0x1957')][_0x4962c7('0x60a')]||_0x4962c7('0x1957'))+_0x4962c7('0x194d')}),_0x5bd2c8(_0x465dfa[_0x4962c7('0x1957')]);})['catch'](function(_0x575102){const _0x1d2d00=_0xdc22cd;if(_0x575102[_0x1d2d00('0x5a5')]&&_0x575102['data'][_0x1d2d00('0x17f')]&&_0x575102[_0x1d2d00('0x5a5')][_0x1d2d00('0x17f')][_0x1d2d00('0x1564')]){_0x465dfa[_0x1d2d00('0x17f')]=_0x575102['data'][_0x1d2d00('0x17f')]||[{'message':_0x575102[_0x1d2d00('0x1ff0')](),'type':_0x1d2d00('0xe4')}];for(let _0x29cbd0=0x0;_0x29cbd0<_0x575102[_0x1d2d00('0x5a5')]['errors'][_0x1d2d00('0x1564')];_0x29cbd0++){_0x11851c[_0x1d2d00('0x52a')]({'title':_0x575102['data'][_0x1d2d00('0x17f')][_0x29cbd0]['type'],'msg':_0x575102[_0x1d2d00('0x5a5')][_0x1d2d00('0x17f')][_0x29cbd0][_0x1d2d00('0x8c2')]});}}else _0x11851c['error']({'title':_0x575102[_0x1d2d00('0x13ee')]?_0x1d2d00('0x2168')+_0x575102[_0x1d2d00('0x13ee')]+_0x1d2d00('0xbf6')+_0x575102[_0x1d2d00('0x24a9')]:'api.intFreshdeskConfiguration.delete','msg':_0x575102[_0x1d2d00('0x5a5')]?JSON[_0x1d2d00('0x258a')](_0x575102['data'][_0x1d2d00('0x8c2')]):_0x575102[_0x1d2d00('0x8c2')]||_0x575102[_0x1d2d00('0x1ff0')]()});});},function(){});}function _0x465a59(_0x4c1fb2){return _0x4c1fb2===null?undefined:new Date(_0x4c1fb2);}function _0x5bd2c8(_0x116912){const _0x358f44=_0x6498af;_0x4c130d[_0x358f44('0x1715')](_0x116912);}}const _0x370357=_0x5b9538;_0xa30e07[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),'$mdDialog',_0x189033('0x1d70'),_0x189033('0x208d'),'items',_0x189033('0x23ef'),_0x189033('0x1d2f'),'type',_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0xa30e07(_0x46b065,_0x1b6fbc,_0x38076f,_0x46ca87,_0x28a8fd,_0xda6bd5,_0x7efc8,_0x474c40,_0x38a212,_0x49394a,_0x1e153d,_0x347308,_0x21a92f){const _0x2e09dc=_0x189033,_0x30a42b=this;_0x30a42b[_0x2e09dc('0x11ed')]=_0x347308[_0x2e09dc('0x20b2')](),_0x30a42b[_0x2e09dc('0x17f')]=[],_0x30a42b[_0x2e09dc('0xf28')]=_0x2e09dc('0x176c')+_0x2e3ca0()['toUpper'](_0x49394a),_0x30a42b[_0x2e09dc('0x23ef')]=angular['copy'](_0x474c40),_0x30a42b[_0x2e09dc('0x1996')]=_0x7efc8,_0x30a42b[_0x2e09dc('0xcf0')]=_0x49394a,_0x30a42b['crudPermissions']=_0x21a92f,_0x30a42b[_0x2e09dc('0x3d2')]=![];!_0x30a42b[_0x2e09dc('0x23ef')]&&(_0x30a42b['item']={'type':_0x2e09dc('0xc06')},_0x30a42b[_0x2e09dc('0x23ef')][_0x2e3ca0()[_0x2e09dc('0x21ab')](_0x49394a)+'Id']=_0xda6bd5['id'],_0x30a42b[_0x2e09dc('0xf28')]='INTEGRATIONS.NEW_'+_0x2e3ca0()[_0x2e09dc('0x65')](_0x49394a),_0x30a42b['newItem']=!![]);_0x30a42b[_0x2e09dc('0x2591')]=_0x17a8b2,_0x30a42b['saveItem']=_0xff5909,_0x30a42b['deleteItem']=_0x9eb8f5,_0x30a42b[_0x2e09dc('0x18a')]=_0x4d3616,_0x30a42b[_0x2e09dc('0xf82')]=_0x2534ec,_0x1e153d['variable'][_0x2e09dc('0x1e6e')]({'nolimit':!![]})[_0x2e09dc('0xe53')][_0x2e09dc('0x683')](function(_0x1282fd){const _0x2b1701=_0x2e09dc;return _0x30a42b[_0x2b1701('0x220b')]=_0x1282fd[_0x2b1701('0xf5d')]?_0x1282fd[_0x2b1701('0xf5d')]:[],_0x1e153d[_0x2b1701('0xf53')][_0x2b1701('0x2267')]()[_0x2b1701('0xe53')];})[_0x2e09dc('0x683')](function(_0x110090){const _0x56ad24=_0x2e09dc;return _0x30a42b[_0x56ad24('0x20c1')]=_0x2e3ca0()['difference'](_0x2e3ca0()['keys'](_0x110090),[_0x56ad24('0xe53'),_0x56ad24('0x1980'),'createdAt',_0x56ad24('0x2000'),_0x56ad24('0x1d58')]),_0x30a42b[_0x56ad24('0x20c1')][_0x56ad24('0x1fd0')]('recordingURL'),_0x1e153d[_0x56ad24('0x1793')][_0x56ad24('0x2267')]()[_0x56ad24('0xe53')];})['then'](function(_0x1e64c4){const _0x45df7f=_0x2e09dc;_0x30a42b[_0x45df7f('0x1d6a')]=_0x2e3ca0()[_0x45df7f('0x2829')](_0x2e3ca0()[_0x45df7f('0x55e')](_0x1e64c4),[_0x45df7f('0xe53'),_0x45df7f('0x1980'),'createdAt','updatedAt',_0x45df7f('0x1d58')]),_0x30a42b[_0x45df7f('0x1d6a')][_0x45df7f('0x1fd0')](_0x45df7f('0x1e93'));})[_0x2e09dc('0x130a')](function(_0x4ceb87){const _0x3bec3a=_0x2e09dc;_0x28a8fd['error']({'title':_0x4ceb87[_0x3bec3a('0x13ee')]?_0x3bec3a('0x2168')+_0x4ceb87[_0x3bec3a('0x13ee')]+_0x3bec3a('0xbf6')+_0x4ceb87[_0x3bec3a('0x24a9')]:_0x3bec3a('0x1fd3'),'msg':_0x4ceb87[_0x3bec3a('0x5a5')]?JSON[_0x3bec3a('0x258a')](_0x4ceb87['data']):_0x4ceb87[_0x3bec3a('0x1ff0')]()});}),_0x1e153d[_0x2e09dc('0x15dc')][_0x2e09dc('0x298')]({'id':_0x38a212['id'],'ticketType':_0xda6bd5[_0x2e09dc('0x20c9')]?_0xda6bd5['ticketType']:undefined})[_0x2e09dc('0xe53')][_0x2e09dc('0x683')](function(_0x52fd91){const _0x2c0e25=_0x2e09dc;_0x30a42b[_0x2c0e25('0xd32')]=!![],_0x30a42b[_0x2c0e25('0x189a')]=_0x52fd91[_0x2c0e25('0xf5d')]?_0x52fd91[_0x2c0e25('0xf5d')]:[],_0x30a42b[_0x2c0e25('0x23ef')][_0x2c0e25('0x280')]&&(_0x30a42b['customField']=_0x2e3ca0()[_0x2c0e25('0x1c07')](_0x30a42b[_0x2c0e25('0x189a')],{'id':_0x30a42b['item'][_0x2c0e25('0x280')]}));})['catch'](function(_0x52ffa0){const _0x386cd0=_0x2e09dc;_0x30a42b[_0x386cd0('0xd32')]=![],console[_0x386cd0('0x52a')](_0x52ffa0);});function _0x17a8b2(){const _0x4fb54a=_0x2e09dc;_0x30a42b['errors']=[],_0x30a42b[_0x4fb54a('0x7f8')]&&(_0x30a42b[_0x4fb54a('0x23ef')][_0x4fb54a('0x280')]=_0x30a42b[_0x4fb54a('0x7f8')]['id'],_0x30a42b['item'][_0x4fb54a('0x2584')]=_0x30a42b[_0x4fb54a('0x7f8')][_0x4fb54a('0x60a')],_0x30a42b['item'][_0x4fb54a('0x7f8')]=_0x30a42b[_0x4fb54a('0x7f8')][_0x4fb54a('0xbf0')]),_0x1e153d['intFreshdeskField'][_0x4fb54a('0xb0a')](_0x30a42b[_0x4fb54a('0x23ef')])[_0x4fb54a('0xe53')]['then'](function(_0x1ebddc){const _0x653354=_0x4fb54a;_0x30a42b[_0x653354('0x1996')]['unshift'](_0x1ebddc),_0x28a8fd[_0x653354('0x53')]({'title':_0x2e3ca0()['capitalize'](_0x49394a)+_0x653354('0x282a'),'msg':_0x2e3ca0()[_0x653354('0x21ab')](_0x49394a)+_0x653354('0x14b5')}),_0x2534ec();})['catch'](function(_0x9c381b){const _0x4bb99a=_0x4fb54a;console['error'](_0x9c381b),_0x30a42b[_0x4bb99a('0x17f')]=_0x9c381b[_0x4bb99a('0x5a5')][_0x4bb99a('0x17f')]||[{'message':_0x9c381b[_0x4bb99a('0x1ff0')](),'type':_0x4bb99a('0x1928')}];});}function _0xff5909(){const _0x1377d3=_0x2e09dc;_0x30a42b[_0x1377d3('0x17f')]=[],_0x30a42b[_0x1377d3('0x7f8')]&&(_0x30a42b[_0x1377d3('0x23ef')][_0x1377d3('0x280')]=_0x30a42b[_0x1377d3('0x7f8')]['id'],_0x30a42b['item']['nameField']=_0x30a42b[_0x1377d3('0x7f8')][_0x1377d3('0x60a')],_0x30a42b['item'][_0x1377d3('0x7f8')]=_0x30a42b['customField']['custom']),_0x1e153d['intFreshdeskField']['update']({'id':_0x30a42b['item']['id']},_0x30a42b['item'])[_0x1377d3('0xe53')][_0x1377d3('0x683')](function(_0x3a2a35){const _0x2bbfca=_0x1377d3,_0x32de86=_0x2e3ca0()[_0x2bbfca('0x1c07')](_0x30a42b[_0x2bbfca('0x1996')],{'id':_0x3a2a35['id']});_0x32de86&&_0x2e3ca0()[_0x2bbfca('0xf22')](_0x32de86,_0x3a2a35),_0x28a8fd[_0x2bbfca('0x53')]({'title':_0x2e3ca0()[_0x2bbfca('0x21ab')](_0x49394a)+_0x2bbfca('0x15dd'),'msg':_0x2e3ca0()[_0x2bbfca('0x21ab')](_0x49394a)+'\x20has\x20been\x20saved!'}),_0x2534ec();})['catch'](function(_0x1b7f96){const _0x36d88a=_0x1377d3;console[_0x36d88a('0x52a')](_0x1b7f96),_0x30a42b['errors']=_0x1b7f96[_0x36d88a('0x5a5')][_0x36d88a('0x17f')]||[{'message':_0x1b7f96['toString'](),'type':_0x36d88a('0x25d0')}];});}function _0x9eb8f5(_0x53104a){const _0x5f3771=_0x2e09dc;_0x30a42b[_0x5f3771('0x17f')]=[];const _0x3d606e=_0x46ca87['confirm']()[_0x5f3771('0xf28')]('Are\x20you\x20sure?')[_0x5f3771('0xa6a')](_0x5f3771('0x3fc')+_0x49394a+'\x20will\x20be\x20deleted.')[_0x5f3771('0x1040')](_0x5f3771('0x609')+_0x2e3ca0()[_0x5f3771('0x21ab')](_0x49394a))['ok']('Delete')[_0x5f3771('0x19fb')](_0x5f3771('0x253a'))[_0x5f3771('0xe42')](_0x53104a);_0x46ca87[_0x5f3771('0x1d4')](_0x3d606e)['then'](function(){const _0x29f4a9=_0x5f3771;_0x1e153d[_0x29f4a9('0x847')][_0x29f4a9('0xd7e')]({'id':_0x30a42b[_0x29f4a9('0x23ef')]['id']})['$promise'][_0x29f4a9('0x683')](function(){const _0x31adb6=_0x29f4a9;_0x2e3ca0()[_0x31adb6('0x3ec')](_0x30a42b['items'],{'id':_0x30a42b['item']['id']}),_0x28a8fd[_0x31adb6('0x53')]({'title':_0x2e3ca0()[_0x31adb6('0x21ab')](_0x49394a)+_0x31adb6('0x27d7'),'msg':_0x2e3ca0()[_0x31adb6('0x21ab')](_0x49394a)+_0x31adb6('0x194d')}),_0x2534ec();})[_0x29f4a9('0x130a')](function(_0x559a0a){const _0x17257c=_0x29f4a9;console[_0x17257c('0x52a')](_0x559a0a),_0x30a42b[_0x17257c('0x17f')]=_0x559a0a[_0x17257c('0x5a5')][_0x17257c('0x17f')]||[{'message':_0x559a0a[_0x17257c('0x1ff0')](),'type':'api.item.delete'}];});},function(){});}function _0x4d3616(){const _0x1e5069=_0x2e09dc;return _0x30a42b[_0x1e5069('0x23ef')][_0x1e5069('0x113b')]!==undefined?_0x30a42b[_0x1e5069('0x23ef')][_0x1e5069('0x113b')]:_0x1e5069('0xbbf');}function _0x2534ec(){const _0xefd531=_0x2e09dc;_0x46ca87[_0xefd531('0x1715')]();}}const _0x4ef6f3=_0xa30e07;_0x20bcfd[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),'api',_0x189033('0x1d70'),_0x189033('0xba1'),'freshdeskAccount',_0x189033('0x22df')];function _0x20bcfd(_0x14bd89,_0x858a60,_0x47e8ea,_0x45f082,_0x3d8b68,_0x54e160,_0x414c6b,_0x1a4593,_0x1a7b0e,_0x4f3b11,_0x5d7865,_0x1a2b2a){const _0x3293cf=_0x189033,_0x5ad46d=this;_0x5ad46d[_0x3293cf('0x11ed')]=_0x4f3b11[_0x3293cf('0x20b2')](),_0x5ad46d['license']=_0x54e160,_0x5ad46d[_0x3293cf('0x260a')]=_0x414c6b,_0x5ad46d['passwordPattern']=_0x5ad46d['setting'][_0x3293cf('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5ad46d[_0x3293cf('0x1224')]=_0x858a60[_0x3293cf('0x173e')]()+'://'+_0x858a60[_0x3293cf('0x19ac')](),_0x5ad46d[_0x3293cf('0x1aee')]=_0x5d7865||_0x14bd89[_0x3293cf('0x7f2')][_0x3293cf('0x1aee')]||{},_0x5ad46d['userProfileSection']=_0x1a2b2a&&_0x1a2b2a[_0x3293cf('0x50d')]==0x1?_0x1a2b2a[_0x3293cf('0xf5d')][0x0]:null,_0x5ad46d['crudPermissions']=_0x4f3b11[_0x3293cf('0x142a')](_0x5ad46d[_0x3293cf('0x22df')]?_0x5ad46d[_0x3293cf('0x22df')][_0x3293cf('0x1134')]:null),_0x5ad46d[_0x3293cf('0x258d')]={},_0x5ad46d[_0x3293cf('0x517')]=_0x14bd89[_0x3293cf('0x7f2')]['tab']||0x0,_0x5ad46d[_0x3293cf('0x2430')]=_0x1a7b0e[_0x3293cf('0x2289')],_0x5ad46d[_0x3293cf('0x19b0')]=_0x477ac2,_0x5ad46d[_0x3293cf('0x23e')]=_0x3ea843;function _0x477ac2(){const _0x4b3684=_0x3293cf;_0x14bd89['go'](_0x4b3684('0x1982'),{},{'reload':_0x4b3684('0x1982')});}function _0x3ea843(){const _0x5a7996=_0x3293cf;_0x1a4593[_0x5a7996('0x15dc')][_0x5a7996('0x2480')]({'id':_0x5ad46d[_0x5a7996('0x1aee')]['id']},_0x5ad46d[_0x5a7996('0x1aee')])[_0x5a7996('0xe53')][_0x5a7996('0x683')](function(){const _0x297a9d=_0x5a7996;_0x1a7b0e['success']({'title':_0x297a9d('0x1a59'),'msg':_0x5ad46d[_0x297a9d('0x1aee')][_0x297a9d('0x60a')]?_0x5ad46d[_0x297a9d('0x1aee')][_0x297a9d('0x60a')]+_0x297a9d('0x96c'):''});})[_0x5a7996('0x130a')](function(_0x31138a){const _0x1d0d25=_0x5a7996;_0x1a7b0e[_0x1d0d25('0x52a')]({'title':_0x31138a[_0x1d0d25('0x13ee')]?_0x1d0d25('0x2168')+_0x31138a[_0x1d0d25('0x13ee')]+'\x20-\x20'+_0x31138a[_0x1d0d25('0x24a9')]:'SYSTEM:GETintFreshdeskAccount','msg':_0x31138a[_0x1d0d25('0x5a5')]?JSON['stringify'](_0x31138a['data']):_0x31138a[_0x1d0d25('0x1ff0')]()});});}}const _0x183000=_0x20bcfd,_0x5df4e0=_0x180212['p']+_0x189033('0x26c3');_0x56345f[_0x189033('0x14be')]=['$scope',_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),'freshdeskAccounts',_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),'toasty',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x56345f(_0x4f0cb3,_0x1f2c5f,_0x19f0af,_0xacdad9,_0x399f94,_0x40ff80,_0x25bb5d,_0x28627f,_0x7b396b,_0x1cde9a,_0x20862f,_0x4dc247,_0x1ed9f4,_0x4225a8,_0x2b5b73,_0x1622f5,_0x25e7e8){const _0x3555e4=_0x189033,_0x1cbc4=this;_0x1cbc4['license']=_0x1622f5,_0x1cbc4['setting']=_0x25e7e8,_0x1cbc4['currentUser']=_0x2b5b73[_0x3555e4('0x20b2')](),_0x1cbc4[_0x3555e4('0x107c')]=_0x7b396b||{'count':0x0,'rows':[]},_0x1cbc4['userProfile']=_0x1cde9a,_0x1cbc4['userProfileSection']=_0x20862f&&_0x20862f[_0x3555e4('0x50d')]==0x1?_0x20862f[_0x3555e4('0xf5d')][0x0]:null,_0x1cbc4[_0x3555e4('0x1134')]=_0x2b5b73[_0x3555e4('0x142a')](_0x1cbc4[_0x3555e4('0x22df')]?_0x1cbc4['userProfileSection'][_0x3555e4('0x1134')]:null),_0x1cbc4[_0x3555e4('0x5c4')]='freshdeskAccounts',_0x1cbc4['listOrder']='',_0x1cbc4['listOrderAsc']=null,_0x1cbc4[_0x3555e4('0x26b1')]=[],_0x1cbc4[_0x3555e4('0x23a2')]={'fields':_0x3555e4('0x149d'),'limit':0xa,'page':0x1},_0x1cbc4[_0x3555e4('0xc63')]=_0x36b0a2,_0x1cbc4[_0x3555e4('0x375')]=_0x3e6e14,_0x1cbc4[_0x3555e4('0x194f')]=_0x539842,_0x1cbc4[_0x3555e4('0x53')]=_0x5ec939,_0x1cbc4[_0x3555e4('0x1af3')]=_0x2eef0f,_0x1cbc4[_0x3555e4('0x21f4')]=_0x165f98,_0x1cbc4['deleteFreshdeskAccount']=_0x24d1a0,_0x1cbc4[_0x3555e4('0xe3')]=_0x546a01,_0x1cbc4[_0x3555e4('0x9c')]=_0x58e7f0,_0x1cbc4[_0x3555e4('0x1b37')]=_0x9cb259,_0x1cbc4[_0x3555e4('0x1e4')]=_0x4bb93c;function _0x36b0a2(_0x17c38c){const _0x42cabe=_0x3555e4;_0x19f0af['go'](_0x42cabe('0x1dc6'),{'id':_0x17c38c['id'],'freshdeskAccount':_0x17c38c,'crudPermissions':_0x1cbc4[_0x42cabe('0x1134')]});}function _0x3e6e14(_0x161894){const _0x11e81c=_0x3555e4;return _0x4dc247['intFreshdeskAccount'][_0x11e81c('0x298')]({'id':_0x161894['id'],'test':!![]})['$promise'][_0x11e81c('0x683')](function(){const _0x7b2421=_0x11e81c;_0x4225a8[_0x7b2421('0x53')]({'title':_0x7b2421('0x1427'),'msg':_0x7b2421('0x1c6d')});})[_0x11e81c('0x130a')](function(_0x180ab0){const _0x39a312=_0x11e81c;_0x4225a8[_0x39a312('0x52a')]({'title':_0x39a312('0x1427'),'msg':_0x180ab0[_0x39a312('0x5a5')]?_0x180ab0[_0x39a312('0x5a5')]['message']?_0x180ab0['data']['message']:JSON['stringify'](_0x180ab0[_0x39a312('0x5a5')]):_0x180ab0[_0x39a312('0x1ff0')]()});});}function _0x539842(_0x1739c3,_0x5c8954){const _0x5dd4cd=_0x3555e4,_0x4370ec=_0x399f94[_0x5dd4cd('0x1c6f')]()['title'](_0x5dd4cd('0x1b01')+_0x2e3ca0()['startCase'](_0x5dd4cd('0x1aee'))+'?')[_0x5dd4cd('0x26e3')](_0x5dd4cd('0xed5')+(_0x1739c3[_0x5dd4cd('0x60a')]||_0x5dd4cd('0x1aee'))+_0x5dd4cd('0x20f1')+_0x5dd4cd('0x1ee7'))[_0x5dd4cd('0x1040')](_0x5dd4cd('0xb41'))[_0x5dd4cd('0xe42')](_0x5c8954)['ok']('OK')['cancel'](_0x5dd4cd('0x16b8'));_0x399f94[_0x5dd4cd('0x1d4')](_0x4370ec)['then'](function(){_0x24d1a0(_0x1739c3);},function(){const _0x3e5a8f=_0x5dd4cd;console[_0x3e5a8f('0x1b2b')](_0x3e5a8f('0x16b8'));});}let _0x43c832=!![],_0x4c8d46=0x1;_0x4f0cb3['$watch'](_0x3555e4('0x1e1d'),function(_0x36fce9,_0x134f55){const _0x3dacce=_0x3555e4;_0x43c832?_0x25bb5d(function(){_0x43c832=![];}):(!_0x134f55&&(_0x4c8d46=_0x1cbc4[_0x3dacce('0x23a2')][_0x3dacce('0xdf8')]),_0x36fce9!==_0x134f55&&(_0x1cbc4[_0x3dacce('0x23a2')]['page']=0x1),!_0x36fce9&&(_0x1cbc4[_0x3dacce('0x23a2')]['page']=_0x4c8d46),_0x1cbc4[_0x3dacce('0x1af3')]());});function _0x5ec939(_0x315350){const _0x1ab859=_0x3555e4;_0x1cbc4[_0x1ab859('0x107c')]=_0x315350||{'count':0x0,'rows':[]};}function _0x2eef0f(){const _0x2ac53e=_0x3555e4;_0x1cbc4[_0x2ac53e('0x23a2')][_0x2ac53e('0x1cc8')]=(_0x1cbc4[_0x2ac53e('0x23a2')][_0x2ac53e('0xdf8')]-0x1)*_0x1cbc4[_0x2ac53e('0x23a2')][_0x2ac53e('0x6f0')],_0x2b5b73['hasRole'](_0x2ac53e('0x20c2'))?_0x1cbc4[_0x2ac53e('0x1883')]=_0x4dc247[_0x2ac53e('0x15dc')][_0x2ac53e('0x1e6e')](_0x1cbc4[_0x2ac53e('0x23a2')],_0x5ec939)[_0x2ac53e('0xe53')]:(_0x1cbc4[_0x2ac53e('0x23a2')]['id']=_0x1cbc4[_0x2ac53e('0x2a')]['id'],_0x1cbc4[_0x2ac53e('0x23a2')]['section']='FreshdeskAccounts',_0x1cbc4[_0x2ac53e('0x1883')]=_0x4dc247[_0x2ac53e('0x2a')][_0x2ac53e('0x241d')](_0x1cbc4[_0x2ac53e('0x23a2')],_0x5ec939)[_0x2ac53e('0xe53')]);}function _0x165f98(_0x285a92,_0x29e337){const _0x145d2a=_0x3555e4;_0x399f94[_0x145d2a('0x1d4')]({'controller':'CreateOrEditFreshdeskAccountDialogController','controllerAs':'vm','templateUrl':_0x5df4e0,'parent':angular[_0x145d2a('0x1fcc')](_0x40ff80[_0x145d2a('0x18e5')]),'targetEvent':_0x285a92,'clickOutsideToClose':!![],'locals':{'freshdeskAccount':_0x29e337,'freshdeskAccounts':_0x1cbc4[_0x145d2a('0x107c')][_0x145d2a('0xf5d')],'license':_0x1cbc4['license'],'setting':_0x1cbc4[_0x145d2a('0x260a')],'crudPermissions':_0x1cbc4[_0x145d2a('0x1134')]}});}function _0x24d1a0(_0x39d55b){const _0x217547=_0x3555e4;_0x4dc247[_0x217547('0x15dc')]['delete']({'id':_0x39d55b['id']})[_0x217547('0xe53')][_0x217547('0x683')](function(){const _0x57468d=_0x217547;_0x2e3ca0()[_0x57468d('0x3ec')](_0x1cbc4[_0x57468d('0x107c')][_0x57468d('0xf5d')],{'id':_0x39d55b['id']}),_0x1cbc4['freshdeskAccounts']['count']-=0x1,!_0x1cbc4['freshdeskAccounts'][_0x57468d('0xf5d')][_0x57468d('0x1564')]&&_0x1cbc4[_0x57468d('0x1af3')](),_0x4225a8[_0x57468d('0x53')]({'title':_0x2e3ca0()[_0x57468d('0x1e03')](_0x57468d('0xb5c'))+_0x57468d('0xbfc'),'msg':_0x39d55b[_0x57468d('0x60a')]?_0x39d55b[_0x57468d('0x60a')]+_0x57468d('0x194d'):''});})[_0x217547('0x130a')](function(_0x4037dd){const _0x4bbd32=_0x217547;if(_0x4037dd[_0x4bbd32('0x5a5')]&&_0x4037dd[_0x4bbd32('0x5a5')][_0x4bbd32('0x17f')]&&_0x4037dd[_0x4bbd32('0x5a5')][_0x4bbd32('0x17f')][_0x4bbd32('0x1564')]){_0x1cbc4[_0x4bbd32('0x17f')]=_0x4037dd[_0x4bbd32('0x5a5')]['errors']||[{'message':_0x4037dd[_0x4bbd32('0x1ff0')](),'type':'SYSTEM:DELETEintFreshdeskAccount'}];for(let _0x4a2703=0x0;_0x4a2703<_0x4037dd[_0x4bbd32('0x5a5')]['errors'][_0x4bbd32('0x1564')];_0x4a2703++){_0x4225a8[_0x4bbd32('0x52a')]({'title':_0x4037dd['data'][_0x4bbd32('0x17f')][_0x4a2703][_0x4bbd32('0xcf0')],'msg':_0x4037dd[_0x4bbd32('0x5a5')][_0x4bbd32('0x17f')][_0x4a2703][_0x4bbd32('0x8c2')]});}}else _0x4225a8['error']({'title':_0x4037dd[_0x4bbd32('0x13ee')]?_0x4bbd32('0x2168')+_0x4037dd['status']+_0x4bbd32('0xbf6')+_0x4037dd[_0x4bbd32('0x24a9')]:_0x4bbd32('0x114e'),'msg':_0x4037dd[_0x4bbd32('0x5a5')]?JSON[_0x4bbd32('0x258a')](_0x4037dd[_0x4bbd32('0x5a5')][_0x4bbd32('0x8c2')]):_0x4037dd[_0x4bbd32('0x8c2')]||_0x4037dd[_0x4bbd32('0x1ff0')]()});});}function _0x546a01(){const _0x2832bd=_0x3555e4,_0x3fda46=angular[_0x2832bd('0x1a86')](_0x1cbc4['selectedFreshdeskAccounts']);return _0x1cbc4[_0x2832bd('0x26b1')]=[],_0x3fda46;}function _0x58e7f0(_0x4c5af6){const _0x57bfc1=_0x3555e4,_0x2b6d1b=_0x399f94[_0x57bfc1('0x1c6f')]()[_0x57bfc1('0xf28')](_0x57bfc1('0xd9a'))[_0x57bfc1('0x26e3')](_0x57bfc1('0xed5')+_0x1cbc4['selectedFreshdeskAccounts'][_0x57bfc1('0x1564')]+'\x20selected'+_0x57bfc1('0x1ee7'))[_0x57bfc1('0x1040')]('delete\x20FreshdeskAccounts')['targetEvent'](_0x4c5af6)['ok']('OK')[_0x57bfc1('0x19fb')](_0x57bfc1('0x16b8'));_0x399f94[_0x57bfc1('0x1d4')](_0x2b6d1b)['then'](function(){const _0x2b3a9b=_0x57bfc1;_0x1cbc4['selectedFreshdeskAccounts'][_0x2b3a9b('0x1299')](function(_0x1636f8){_0x24d1a0(_0x1636f8);}),_0x1cbc4[_0x2b3a9b('0x26b1')]=[];});}function _0x9cb259(){_0x1cbc4['selectedFreshdeskAccounts']=[];}function _0x4bb93c(){const _0x467c46=_0x3555e4;_0x1cbc4['selectedFreshdeskAccounts']=_0x1cbc4[_0x467c46('0x107c')][_0x467c46('0xf5d')];}}const _0x27b562=_0x56345f;_0x3509da[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x2808'),'freshsalesAccount',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x3509da(_0x167779,_0x5d3f12,_0x5503ab,_0x13949a,_0x2a4673,_0x4799ec,_0x28982a,_0x503b23,_0x1a4d6a,_0x29e83c,_0xaed7c9,_0x56ac2e,_0x99783b,_0x3773e7){const _0x14d226=_0x189033,_0x5004db=this;_0x5004db['currentUser']=_0xaed7c9[_0x14d226('0x20b2')](),_0x5004db[_0x14d226('0x17f')]=[],_0x5004db['setting']=_0x99783b,_0x5004db[_0x14d226('0xace')]=_0x56ac2e,_0x5004db[_0x14d226('0x1134')]=_0x3773e7,_0x5004db[_0x14d226('0x258d')]={},_0x5004db[_0x14d226('0x19b2')]=_0x5004db['setting']&&_0x5004db[_0x14d226('0x260a')][_0x14d226('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5004db[_0x14d226('0xf28')]=_0x14d226('0xa4c'),_0x5004db[_0x14d226('0xf27')]=angular[_0x14d226('0x1a86')](_0x1a4d6a),_0x5004db[_0x14d226('0x2808')]=_0x503b23,_0x5004db['newFreshsalesAccount']=![];!_0x5004db[_0x14d226('0xf27')]&&(_0x5004db['freshsalesAccount']={'serverUrl':_0x5503ab['protocol']()+_0x14d226('0x20de')+_0x5503ab[_0x14d226('0x19ac')]()+(_0x5503ab[_0x14d226('0x4a2')]()?':'+_0x5503ab['port']():'')},_0x5004db['title']='INTEGRATIONS.NEW_FRESHSALESACCOUNT',_0x5004db['newFreshsalesAccount']=!![]);_0x5004db[_0x14d226('0x6a2')]=_0x606b2b,_0x5004db[_0x14d226('0x2579')]=_0x5cf5ae,_0x5004db['deleteFreshsalesAccount']=_0x408493,_0x5004db[_0x14d226('0x16b3')]=_0x35be52,_0x5004db['closeDialog']=_0x348f19;function _0x606b2b(){const _0x4fd602=_0x14d226;_0x5004db['errors']=[],_0x29e83c['intFreshsalesAccount']['save'](_0x5004db[_0x4fd602('0xf27')])[_0x4fd602('0xe53')][_0x4fd602('0x683')](function(_0x1999b8){const _0x709b1b=_0x4fd602;_0x5004db[_0x709b1b('0x2808')][_0x709b1b('0x1167')](_0x1999b8[_0x709b1b('0x24e1')]()),_0x28982a[_0x709b1b('0x53')]({'title':_0x709b1b('0x237a'),'msg':_0x5004db[_0x709b1b('0xf27')][_0x709b1b('0x60a')]?_0x5004db[_0x709b1b('0xf27')][_0x709b1b('0x60a')]+'\x20has\x20been\x20created!':''}),_0x348f19(_0x1999b8);})[_0x4fd602('0x130a')](function(_0x4e0572){const _0x4e3cff=_0x4fd602;if(_0x4e0572[_0x4e3cff('0x5a5')]&&_0x4e0572[_0x4e3cff('0x5a5')]['errors']&&_0x4e0572[_0x4e3cff('0x5a5')][_0x4e3cff('0x17f')]['length']){_0x5004db[_0x4e3cff('0x17f')]=_0x4e0572[_0x4e3cff('0x5a5')][_0x4e3cff('0x17f')]||[{'message':_0x4e0572[_0x4e3cff('0x1ff0')](),'type':_0x4e3cff('0x12c3')}];for(let _0x556fdf=0x0;_0x556fdf<_0x4e0572[_0x4e3cff('0x5a5')][_0x4e3cff('0x17f')][_0x4e3cff('0x1564')];_0x556fdf+=0x1){_0x28982a[_0x4e3cff('0x52a')]({'title':_0x4e0572[_0x4e3cff('0x5a5')][_0x4e3cff('0x17f')][_0x556fdf]['type'],'msg':_0x4e0572['data'][_0x4e3cff('0x17f')][_0x556fdf]['message']});}}else _0x28982a[_0x4e3cff('0x52a')]({'title':_0x4e0572['status']?_0x4e3cff('0x2168')+_0x4e0572['status']+_0x4e3cff('0xbf6')+_0x4e0572[_0x4e3cff('0x24a9')]:_0x4e3cff('0x12c3'),'msg':_0x4e0572['data']?JSON[_0x4e3cff('0x258a')](_0x4e0572['data'][_0x4e3cff('0x8c2')]):_0x4e0572[_0x4e3cff('0x1ff0')]()});});}function _0x5cf5ae(){const _0x2da6f4=_0x14d226;_0x5004db['errors']=[],_0x29e83c[_0x2da6f4('0xa71')][_0x2da6f4('0x2480')]({'id':_0x5004db['freshsalesAccount']['id']},_0x5004db[_0x2da6f4('0xf27')])['$promise']['then'](function(_0x43baaf){const _0xedbd83=_0x2da6f4,_0x41d73d=_0x2e3ca0()[_0xedbd83('0x1c07')](_0x5004db[_0xedbd83('0x2808')],{'id':_0x43baaf['id']});_0x41d73d&&_0x2e3ca0()[_0xedbd83('0xf22')](_0x41d73d,_0x2e3ca0()[_0xedbd83('0x24d0')](_0x43baaf[_0xedbd83('0x24e1')](),_0x2e3ca0()['keys'](_0x41d73d))),_0x28982a[_0xedbd83('0x53')]({'title':_0xedbd83('0x27f'),'msg':_0x5004db[_0xedbd83('0xf27')][_0xedbd83('0x60a')]?_0x5004db['freshsalesAccount'][_0xedbd83('0x60a')]+_0xedbd83('0xf59'):''}),_0x348f19(_0x43baaf);})[_0x2da6f4('0x130a')](function(_0x28a4ac){const _0x5c0c80=_0x2da6f4;if(_0x28a4ac[_0x5c0c80('0x5a5')]&&_0x28a4ac['data']['errors']&&_0x28a4ac[_0x5c0c80('0x5a5')][_0x5c0c80('0x17f')][_0x5c0c80('0x1564')]){_0x5004db[_0x5c0c80('0x17f')]=_0x28a4ac['data'][_0x5c0c80('0x17f')]||[{'message':_0x28a4ac[_0x5c0c80('0x1ff0')](),'type':'api.intFreshsalesAccount.update'}];for(let _0x17e01b=0x0;_0x17e01b<_0x28a4ac[_0x5c0c80('0x5a5')][_0x5c0c80('0x17f')][_0x5c0c80('0x1564')];_0x17e01b++){_0x28982a['error']({'title':_0x28a4ac[_0x5c0c80('0x5a5')][_0x5c0c80('0x17f')][_0x17e01b][_0x5c0c80('0xcf0')],'msg':_0x28a4ac[_0x5c0c80('0x5a5')][_0x5c0c80('0x17f')][_0x17e01b][_0x5c0c80('0x8c2')]});}}else _0x28982a[_0x5c0c80('0x52a')]({'title':_0x28a4ac[_0x5c0c80('0x13ee')]?'API:'+_0x28a4ac[_0x5c0c80('0x13ee')]+_0x5c0c80('0xbf6')+_0x28a4ac['statusText']:_0x5c0c80('0x24f9'),'msg':_0x28a4ac[_0x5c0c80('0x5a5')]?JSON[_0x5c0c80('0x258a')](_0x28a4ac[_0x5c0c80('0x5a5')][_0x5c0c80('0x8c2')]):_0x28a4ac[_0x5c0c80('0x1ff0')]()});});}function _0x408493(_0x42b03b){const _0xbc98fb=_0x14d226;_0x5004db[_0xbc98fb('0x17f')]=[];const _0x453558=_0x13949a[_0xbc98fb('0x1c6f')]()['title'](_0xbc98fb('0x4d'))[_0xbc98fb('0xa6a')]('The\x20freshsalesAccount\x20will\x20be\x20deleted.')[_0xbc98fb('0x1040')]('Delete\x20FreshsalesAccount')['ok'](_0xbc98fb('0x2307'))[_0xbc98fb('0x19fb')]('Cancel')[_0xbc98fb('0xe42')](_0x42b03b);_0x13949a[_0xbc98fb('0x1d4')](_0x453558)[_0xbc98fb('0x683')](function(){const _0x58a196=_0xbc98fb;_0x29e83c['intFreshsalesAccount']['delete']({'id':_0x5004db[_0x58a196('0xf27')]['id']})[_0x58a196('0xe53')][_0x58a196('0x683')](function(){const _0x3d3b12=_0x58a196;_0x2e3ca0()['remove'](_0x5004db[_0x3d3b12('0x2808')],{'id':_0x5004db[_0x3d3b12('0xf27')]['id']}),_0x28982a[_0x3d3b12('0x53')]({'title':_0x3d3b12('0x26d0'),'msg':(_0x5004db[_0x3d3b12('0xf27')][_0x3d3b12('0x60a')]||_0x3d3b12('0xf27'))+'\x20has\x20been\x20deleted!'}),_0x348f19(_0x5004db[_0x3d3b12('0xf27')]);})[_0x58a196('0x130a')](function(_0x5d8845){const _0x5b4e54=_0x58a196;if(_0x5d8845[_0x5b4e54('0x5a5')]&&_0x5d8845[_0x5b4e54('0x5a5')]['errors']&&_0x5d8845[_0x5b4e54('0x5a5')][_0x5b4e54('0x17f')][_0x5b4e54('0x1564')]){_0x5004db[_0x5b4e54('0x17f')]=_0x5d8845['data']['errors']||[{'message':_0x5d8845[_0x5b4e54('0x1ff0')](),'type':_0x5b4e54('0x1a31')}];for(let _0x5a0d84=0x0;_0x5a0d84<_0x5d8845['data']['errors'][_0x5b4e54('0x1564')];_0x5a0d84++){_0x28982a[_0x5b4e54('0x52a')]({'title':_0x5d8845[_0x5b4e54('0x5a5')][_0x5b4e54('0x17f')][_0x5a0d84][_0x5b4e54('0xcf0')],'msg':_0x5d8845[_0x5b4e54('0x5a5')][_0x5b4e54('0x17f')][_0x5a0d84][_0x5b4e54('0x8c2')]});}}else _0x28982a['error']({'title':_0x5d8845['status']?'API:'+_0x5d8845[_0x5b4e54('0x13ee')]+_0x5b4e54('0xbf6')+_0x5d8845[_0x5b4e54('0x24a9')]:_0x5b4e54('0x1a31'),'msg':_0x5d8845['data']?JSON[_0x5b4e54('0x258a')](_0x5d8845['data'][_0x5b4e54('0x8c2')]):_0x5d8845[_0x5b4e54('0x8c2')]||_0x5d8845['toString']()});});},function(){});}function _0x35be52(_0x51e499){return _0x51e499===null?undefined:new Date(_0x51e499);}function _0x348f19(_0x2a3bf9){const _0x49a3a2=_0x14d226;_0x13949a[_0x49a3a2('0x1715')](_0x2a3bf9);}}const _0x158e09=_0x3509da,_0x8f256d=_0x180212['p']+'src/js/modules/main/apps/integrations/views/freshsalesAccounts/edit/configurations/dialog.html/dialog.html',_0x375a48=_0x180212['p']+_0x189033('0x2639');_0xbec515[_0x189033('0x14be')]=['$mdDialog',_0x189033('0x16ea'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1')];function _0xbec515(_0x558d9f,_0x820a74,_0x3a5eed,_0x5275f6,_0x3c4444){const _0x1ef599=_0x189033,_0x57dc2b=this;_0x57dc2b[_0x1ef599('0x11ed')]=_0x3c4444[_0x1ef599('0x20b2')](),_0x57dc2b[_0x1ef599('0xf27')]={},_0x57dc2b['freshsalesConfiguration']={},_0x57dc2b[_0x1ef599('0x1573')]=[],_0x57dc2b[_0x1ef599('0x1468')]=-0x1,_0x57dc2b['crudPermissions'],_0x57dc2b[_0x1ef599('0x12f3')]=_0x534202,_0x57dc2b[_0x1ef599('0x3ad')]=_0x6727e5,_0x57dc2b[_0x1ef599('0x274f')]=_0x434515,_0x57dc2b[_0x1ef599('0xd22')]=_0x41d6b;function _0x534202(_0x5dca5f,_0x5cb6fe){const _0x16dfcd=_0x1ef599;_0x57dc2b['freshsalesAccount']=_0x5dca5f,_0x57dc2b[_0x16dfcd('0x1134')]=typeof _0x5cb6fe!=='undefined'?_0x5cb6fe:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3a5eed['intFreshsalesAccount'][_0x16dfcd('0x1575')]({'id':_0x57dc2b[_0x16dfcd('0xf27')]['id'],'sort':_0x16dfcd('0xc36')})[_0x16dfcd('0xe53')][_0x16dfcd('0x683')](function(_0x4aa007){const _0x53d818=_0x16dfcd;return _0x57dc2b['configurations']=_0x4aa007[_0x53d818('0xf5d')]?_0x4aa007[_0x53d818('0xf5d')]:[],_0x57dc2b[_0x53d818('0x1573')][_0x53d818('0x1564')]&&_0x57dc2b[_0x53d818('0x3ad')](0x0),_0x3a5eed[_0x53d818('0x26e0')][_0x53d818('0x1e6e')]({'nolimit':!![],'sort':_0x53d818('0x60a')})[_0x53d818('0xe53')];})[_0x16dfcd('0x683')](function(_0x3de72e){const _0x50c4b1=_0x16dfcd;_0x57dc2b[_0x50c4b1('0x220b')]=_0x3de72e[_0x50c4b1('0xf5d')]?_0x3de72e[_0x50c4b1('0xf5d')]:[],_0x57dc2b[_0x50c4b1('0x1822')]=_0x2e3ca0()[_0x50c4b1('0x24db')](_0x57dc2b[_0x50c4b1('0x220b')],'id');})[_0x16dfcd('0x130a')](function(_0x536903){const _0x238197=_0x16dfcd;_0x5275f6[_0x238197('0x52a')]({'title':_0x536903['status']?_0x238197('0x2168')+_0x536903[_0x238197('0x13ee')]+_0x238197('0xbf6')+_0x536903[_0x238197('0x24a9')]:'SYSTEM:GETCONFIGURATION','msg':_0x536903['data']?JSON[_0x238197('0x258a')](_0x536903['data']):_0x536903[_0x238197('0x1ff0')]()});});}function _0x6727e5(_0x3279c7){const _0x2dcc5b=_0x1ef599;_0x57dc2b[_0x2dcc5b('0x28d')]=_0x57dc2b[_0x2dcc5b('0x1573')][_0x3279c7],_0x57dc2b[_0x2dcc5b('0x1468')]=_0x3279c7,_0x3a5eed[_0x2dcc5b('0x1be2')][_0x2dcc5b('0x20ac')]({'id':_0x57dc2b[_0x2dcc5b('0x28d')]['id']})['$promise'][_0x2dcc5b('0x683')](function(_0x5eec8d){const _0x459a64=_0x2dcc5b;return _0x57dc2b[_0x459a64('0x1ead')]=_0x5eec8d[_0x459a64('0xf5d')]?_0x5eec8d[_0x459a64('0xf5d')]:[],_0x3a5eed[_0x459a64('0x1be2')][_0x459a64('0x412')]({'id':_0x57dc2b[_0x459a64('0x28d')]['id']})['$promise'];})[_0x2dcc5b('0x683')](function(_0x441a02){const _0x1f932d=_0x2dcc5b;return _0x57dc2b[_0x1f932d('0x18f7')]=_0x441a02[_0x1f932d('0xf5d')]?_0x441a02['rows']:[],_0x3a5eed[_0x1f932d('0x1be2')][_0x1f932d('0x298')]({'id':_0x57dc2b[_0x1f932d('0x28d')]['id']})[_0x1f932d('0xe53')];})[_0x2dcc5b('0x683')](function(_0x1e5261){const _0x51c768=_0x2dcc5b;_0x57dc2b[_0x51c768('0x189a')]=_0x1e5261[_0x51c768('0xf5d')]?_0x1e5261[_0x51c768('0xf5d')]:[];})[_0x2dcc5b('0x130a')](function(_0x498823){const _0x19785c=_0x2dcc5b;_0x5275f6[_0x19785c('0x52a')]({'title':_0x498823[_0x19785c('0x13ee')]?_0x19785c('0x2168')+_0x498823['status']+_0x19785c('0xbf6')+_0x498823[_0x19785c('0x24a9')]:_0x19785c('0x167c'),'msg':_0x498823['data']?JSON[_0x19785c('0x258a')](_0x498823[_0x19785c('0x5a5')]):_0x498823[_0x19785c('0x1ff0')]()});});}function _0x434515(_0x137221,_0x561322){const _0x3a1521=_0x1ef599;_0x558d9f[_0x3a1521('0x1d4')]({'controller':_0x3a1521('0xf19'),'controllerAs':'vm','templateUrl':_0x8f256d,'parent':angular[_0x3a1521('0x1fcc')](_0x820a74['body']),'targetEvent':_0x137221,'clickOutsideToClose':!![],'locals':{'freshsalesConfiguration':_0x561322,'configurations':_0x57dc2b['configurations'],'license':null,'setting':null,'crudPermissions':_0x57dc2b['crudPermissions']}})[_0x3a1521('0x2874')](function(){const _0xda6d0f=_0x3a1521;_0x57dc2b[_0xda6d0f('0x3ad')](0x0);});}function _0x41d6b(_0x751067,_0xa435cd){const _0x217aed=_0x1ef599,_0x2d4398=_0x558d9f[_0x217aed('0x1c6f')]()['title'](_0x217aed('0x10db'))[_0x217aed('0x26e3')](''+(_0xa435cd[_0x217aed('0x60a')]||_0x217aed('0x28d'))+_0x217aed('0x20f1')+_0x217aed('0x1ee7'))[_0x217aed('0x1040')](_0x217aed('0x1eff'))[_0x217aed('0xe42')](_0x751067)['ok']('OK')[_0x217aed('0x19fb')](_0x217aed('0x16b8'));_0x558d9f[_0x217aed('0x1d4')](_0x2d4398)[_0x217aed('0x683')](function(){const _0x96c7e8=_0x217aed;_0x3a5eed['intFreshsalesConfiguration'][_0x96c7e8('0xd7e')]({'id':_0xa435cd['id']})[_0x96c7e8('0xe53')]['then'](function(){const _0x29edc7=_0x96c7e8;_0x2e3ca0()[_0x29edc7('0x3ec')](_0x57dc2b[_0x29edc7('0x1573')],{'id':_0xa435cd['id']}),_0x5275f6[_0x29edc7('0x53')]({'title':_0x29edc7('0x1ad2'),'msg':_0xa435cd[_0x29edc7('0x60a')]?_0xa435cd[_0x29edc7('0x60a')]+_0x29edc7('0x194d'):''});})[_0x96c7e8('0x130a')](function(_0x1f4ed4){const _0x46641e=_0x96c7e8;_0x5275f6[_0x46641e('0x52a')]({'title':_0x1f4ed4[_0x46641e('0x13ee')]?'API:'+_0x1f4ed4[_0x46641e('0x13ee')]+_0x46641e('0xbf6')+_0x1f4ed4[_0x46641e('0x24a9')]:'SYSTEM:DELETECONFIGURATION','msg':_0x1f4ed4[_0x46641e('0x5a5')]?JSON[_0x46641e('0x258a')](_0x1f4ed4[_0x46641e('0x5a5')]):_0x1f4ed4[_0x46641e('0x1ff0')]()});})[_0x96c7e8('0x2874')](function(){_0x57dc2b['getFreshsalesConfiguration'](0x0);});},function(){const _0x5a8759=_0x217aed;console[_0x5a8759('0x1b2b')]('CANCEL');});}_0x57dc2b[_0x1ef599('0x1781')]=[],_0x57dc2b[_0x1ef599('0x2654')]=_0x4fae9f,_0x57dc2b[_0x1ef599('0x2802')]=_0x3c2ae2,_0x57dc2b[_0x1ef599('0x1734')]=_0x5093ed;function _0x4fae9f(_0x2dbf14,_0x5508d8){const _0x3207cb=_0x1ef599;_0x558d9f[_0x3207cb('0x1d4')]({'controller':_0x3207cb('0x2428'),'controllerAs':'vm','templateUrl':_0x375a48,'parent':angular[_0x3207cb('0x1fcc')](_0x820a74[_0x3207cb('0x18e5')]),'targetEvent':_0x2dbf14,'clickOutsideToClose':!![],'locals':{'type':_0x3207cb('0x1e66'),'item':_0x5508d8,'items':_0x57dc2b[_0x3207cb('0x1ead')],'configuration':_0x57dc2b[_0x3207cb('0x28d')],'account':_0x57dc2b['freshsalesAccount'],'license':null,'setting':null,'crudPermissions':_0x57dc2b['crudPermissions']}});}function _0x48f9d6(_0x4ba268){const _0x14dfe6=_0x1ef599;_0x3a5eed[_0x14dfe6('0xddb')][_0x14dfe6('0xd7e')]({'id':_0x4ba268['id']})[_0x14dfe6('0xe53')][_0x14dfe6('0x683')](function(){const _0x3251a0=_0x14dfe6;_0x2e3ca0()[_0x3251a0('0x3ec')](_0x57dc2b[_0x3251a0('0x1ead')],{'id':_0x4ba268['id']}),_0x5275f6[_0x3251a0('0x53')]({'title':_0x3251a0('0x637'),'msg':_0x3251a0('0x2795')});})['catch'](function(_0x20877e){const _0x16450c=_0x14dfe6;_0x5275f6['error']({'title':_0x20877e[_0x16450c('0x13ee')]?'API:'+_0x20877e[_0x16450c('0x13ee')]+_0x16450c('0xbf6')+_0x20877e[_0x16450c('0x24a9')]:_0x16450c('0x1d23'),'msg':_0x20877e[_0x16450c('0x5a5')]?JSON[_0x16450c('0x258a')](_0x20877e['data']):_0x20877e[_0x16450c('0x1ff0')]()});});}function _0x3c2ae2(_0x4478a7,_0x291768){const _0x1b89ac=_0x1ef599,_0x5a4365=_0x558d9f[_0x1b89ac('0x1c6f')]()[_0x1b89ac('0xf28')](_0x1b89ac('0x17ed'))['htmlContent'](_0x1b89ac('0x601')+_0x1b89ac('0x1ee7'))[_0x1b89ac('0x1040')](_0x1b89ac('0x20d'))[_0x1b89ac('0xe42')](_0x4478a7)['ok']('OK')[_0x1b89ac('0x19fb')](_0x1b89ac('0x16b8'));_0x558d9f[_0x1b89ac('0x1d4')](_0x5a4365)['then'](function(){_0x48f9d6(_0x291768);},function(){const _0x301d04=_0x1b89ac;console[_0x301d04('0x1b2b')](_0x301d04('0x16b8'));});}function _0x5093ed(_0x767d3a){const _0x14bc50=_0x1ef599,_0x2b58b5=_0x558d9f['confirm']()[_0x14bc50('0xf28')](_0x14bc50('0xad5'))[_0x14bc50('0x26e3')](_0x14bc50('0xed5')+_0x57dc2b[_0x14bc50('0x1781')]['length']+_0x14bc50('0x93c')+'\x20will\x20be\x20deleted.')[_0x14bc50('0x1040')]('delete\x20subjects')[_0x14bc50('0xe42')](_0x767d3a)['ok']('OK')[_0x14bc50('0x19fb')](_0x14bc50('0x16b8'));_0x558d9f[_0x14bc50('0x1d4')](_0x2b58b5)[_0x14bc50('0x683')](function(){const _0x23fe9a=_0x14bc50;_0x57dc2b[_0x23fe9a('0x1781')][_0x23fe9a('0x1299')](function(_0xfb9962){_0x48f9d6(_0xfb9962);}),_0x57dc2b['selectedSubjects']=[];});}_0x57dc2b[_0x1ef599('0xcb1')]=[],_0x57dc2b[_0x1ef599('0x1094')]=_0x190ed3,_0x57dc2b[_0x1ef599('0x27b2')]=_0x5d802b,_0x57dc2b[_0x1ef599('0x27df')]=_0x2543ca;function _0x190ed3(_0x2197b0,_0x35834c){const _0x1e7576=_0x1ef599;_0x558d9f[_0x1e7576('0x1d4')]({'controller':'CreateOrEditFreshsalesAccountItemDialogController','controllerAs':'vm','templateUrl':_0x375a48,'parent':angular[_0x1e7576('0x1fcc')](_0x820a74[_0x1e7576('0x18e5')]),'targetEvent':_0x2197b0,'clickOutsideToClose':!![],'locals':{'type':_0x1e7576('0xd6b'),'item':_0x35834c,'items':_0x57dc2b[_0x1e7576('0x18f7')],'configuration':_0x57dc2b[_0x1e7576('0x28d')],'account':_0x57dc2b[_0x1e7576('0xf27')],'license':null,'setting':null,'crudPermissions':_0x57dc2b[_0x1e7576('0x1134')]}});}function _0x1aa8c8(_0xa736a8){const _0x33f516=_0x1ef599;_0x3a5eed[_0x33f516('0xddb')][_0x33f516('0xd7e')]({'id':_0xa736a8['id']})[_0x33f516('0xe53')][_0x33f516('0x683')](function(){const _0x4dbf0a=_0x33f516;_0x2e3ca0()[_0x4dbf0a('0x3ec')](_0x57dc2b[_0x4dbf0a('0x18f7')],{'id':_0xa736a8['id']}),_0x5275f6['success']({'title':_0x4dbf0a('0x1cf8'),'msg':_0x4dbf0a('0x21c7')});})[_0x33f516('0x130a')](function(_0x50fa3c){const _0x4b4d37=_0x33f516;_0x5275f6[_0x4b4d37('0x52a')]({'title':_0x50fa3c['status']?_0x4b4d37('0x2168')+_0x50fa3c[_0x4b4d37('0x13ee')]+_0x4b4d37('0xbf6')+_0x50fa3c[_0x4b4d37('0x24a9')]:_0x4b4d37('0x1d23'),'msg':_0x50fa3c['data']?JSON['stringify'](_0x50fa3c[_0x4b4d37('0x5a5')]):_0x50fa3c[_0x4b4d37('0x1ff0')]()});});}function _0x5d802b(_0x22da16,_0x1953e2){const _0x6f1b4c=_0x1ef599,_0x537418=_0x558d9f[_0x6f1b4c('0x1c6f')]()[_0x6f1b4c('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20description?')[_0x6f1b4c('0x26e3')](_0x6f1b4c('0xd5e')+'\x20will\x20be\x20deleted.')[_0x6f1b4c('0x1040')](_0x6f1b4c('0x221c'))[_0x6f1b4c('0xe42')](_0x22da16)['ok']('OK')[_0x6f1b4c('0x19fb')](_0x6f1b4c('0x16b8'));_0x558d9f[_0x6f1b4c('0x1d4')](_0x537418)[_0x6f1b4c('0x683')](function(){_0x1aa8c8(_0x1953e2);},function(){const _0x498333=_0x6f1b4c;console[_0x498333('0x1b2b')](_0x498333('0x16b8'));});}function _0x2543ca(_0xf37cfa){const _0x3a8129=_0x1ef599,_0x3c4b9e=_0x558d9f[_0x3a8129('0x1c6f')]()[_0x3a8129('0xf28')](_0x3a8129('0x1984'))['htmlContent'](_0x3a8129('0xed5')+_0x57dc2b[_0x3a8129('0xcb1')]['length']+_0x3a8129('0x93c')+_0x3a8129('0x1ee7'))[_0x3a8129('0x1040')](_0x3a8129('0x1859'))[_0x3a8129('0xe42')](_0xf37cfa)['ok']('OK')['cancel']('CANCEL');_0x558d9f[_0x3a8129('0x1d4')](_0x3c4b9e)[_0x3a8129('0x683')](function(){const _0x176355=_0x3a8129;_0x57dc2b[_0x176355('0xcb1')][_0x176355('0x1299')](function(_0x32cf18){_0x1aa8c8(_0x32cf18);}),_0x57dc2b[_0x176355('0xcb1')]=[];});}_0x57dc2b[_0x1ef599('0x310')]=[],_0x57dc2b['createOrEditField']=_0xeef0e8,_0x57dc2b[_0x1ef599('0x9f9')]=_0x41b899,_0x57dc2b['deleteSelectedFields']=_0x12532a;function _0xeef0e8(_0xc3c704,_0x1a56a0){const _0x3d746f=_0x1ef599;_0x558d9f[_0x3d746f('0x1d4')]({'controller':_0x3d746f('0x2428'),'controllerAs':'vm','templateUrl':_0x375a48,'parent':angular[_0x3d746f('0x1fcc')](_0x820a74['body']),'targetEvent':_0xc3c704,'clickOutsideToClose':!![],'locals':{'type':_0x3d746f('0x2013'),'item':_0x1a56a0,'items':_0x57dc2b[_0x3d746f('0x189a')],'configuration':_0x57dc2b['freshsalesConfiguration'],'account':_0x57dc2b['freshsalesAccount'],'license':null,'setting':null,'crudPermissions':_0x57dc2b['crudPermissions']}});}function _0x4c68a8(_0x331b95){const _0x540bf5=_0x1ef599;_0x3a5eed[_0x540bf5('0xddb')][_0x540bf5('0xd7e')]({'id':_0x331b95['id']})[_0x540bf5('0xe53')]['then'](function(){const _0x6a8c4=_0x540bf5;_0x2e3ca0()[_0x6a8c4('0x3ec')](_0x57dc2b['fields'],{'id':_0x331b95['id']}),_0x5275f6[_0x6a8c4('0x53')]({'title':_0x6a8c4('0x1666'),'msg':_0x6a8c4('0x1eda')});})[_0x540bf5('0x130a')](function(_0x5d76d3){const _0x4703e0=_0x540bf5;_0x5275f6[_0x4703e0('0x52a')]({'title':_0x5d76d3['status']?_0x4703e0('0x2168')+_0x5d76d3[_0x4703e0('0x13ee')]+_0x4703e0('0xbf6')+_0x5d76d3[_0x4703e0('0x24a9')]:_0x4703e0('0x1d23'),'msg':_0x5d76d3[_0x4703e0('0x5a5')]?JSON[_0x4703e0('0x258a')](_0x5d76d3[_0x4703e0('0x5a5')]):_0x5d76d3[_0x4703e0('0x1ff0')]()});});}function _0x41b899(_0x329783,_0x23c058){const _0x57fd6b=_0x1ef599,_0x1d30ca=_0x558d9f['confirm']()[_0x57fd6b('0xf28')](_0x57fd6b('0x16b5'))[_0x57fd6b('0x26e3')]('Field'+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x57fd6b('0x1edb'))[_0x57fd6b('0xe42')](_0x329783)['ok']('OK')[_0x57fd6b('0x19fb')]('CANCEL');_0x558d9f['show'](_0x1d30ca)[_0x57fd6b('0x683')](function(){_0x4c68a8(_0x23c058);},function(){const _0x137e0c=_0x57fd6b;console['log'](_0x137e0c('0x16b8'));});}function _0x12532a(_0xf0f2be){const _0x1dd181=_0x1ef599,_0x4a6eb4=_0x558d9f[_0x1dd181('0x1c6f')]()[_0x1dd181('0xf28')](_0x1dd181('0x19b1'))[_0x1dd181('0x26e3')](''+_0x57dc2b['selectedFields'][_0x1dd181('0x1564')]+_0x1dd181('0x93c')+_0x1dd181('0x1ee7'))[_0x1dd181('0x1040')](_0x1dd181('0x994'))[_0x1dd181('0xe42')](_0xf0f2be)['ok']('OK')[_0x1dd181('0x19fb')](_0x1dd181('0x16b8'));_0x558d9f['show'](_0x4a6eb4)[_0x1dd181('0x683')](function(){const _0x2bde69=_0x1dd181;_0x57dc2b['selectedFields'][_0x2bde69('0x1299')](function(_0x1441d8){_0x4c68a8(_0x1441d8);}),_0x57dc2b['selectedFields']=[];});}}const _0x3e2a61=_0xbec515;_0x33a7d2[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),'configurations',_0x189033('0x28d'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x33a7d2(_0x4246fd,_0x2f75b8,_0x54e60b,_0x495ba5,_0x5e37ea,_0x32d6af,_0xa7f2de,_0x3aa733,_0x25794e,_0x452eda,_0xa7d032,_0x2936de,_0x55c2e0,_0x370921){const _0x546562=_0x189033,_0x1a1ef8=this;_0x1a1ef8[_0x546562('0x11ed')]=_0xa7d032[_0x546562('0x20b2')](),_0x1a1ef8[_0x546562('0x17f')]=[],_0x1a1ef8[_0x546562('0x260a')]=_0x55c2e0,_0x1a1ef8[_0x546562('0xace')]=_0x2936de,_0x1a1ef8[_0x546562('0x1134')]=_0x370921,_0x1a1ef8[_0x546562('0x258d')]={},_0x1a1ef8['passwordPattern']=_0x1a1ef8[_0x546562('0x260a')]&&_0x1a1ef8['setting'][_0x546562('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1a1ef8[_0x546562('0xf28')]=_0x546562('0x10d7'),_0x1a1ef8[_0x546562('0x28d')]=angular[_0x546562('0x1a86')](_0x25794e),_0x1a1ef8['configurations']=_0x3aa733,_0x1a1ef8[_0x546562('0x7c3')]=![];!_0x1a1ef8[_0x546562('0x28d')]&&(_0x1a1ef8[_0x546562('0x28d')]={'channel':_0x546562('0xcf2'),'type':_0x546562('0x1535')},_0x1a1ef8['title']=_0x546562('0x1c54'),_0x1a1ef8[_0x546562('0x7c3')]=!![]);_0x1a1ef8['addNewFreshsalesConfiguration']=_0x873167,_0x1a1ef8[_0x546562('0x1340')]=_0x20c335,_0x1a1ef8[_0x546562('0xd22')]=_0x20576e,_0x1a1ef8[_0x546562('0x16b3')]=_0xf6523b,_0x1a1ef8['closeDialog']=_0x8c3cc7;function _0x873167(){const _0x11bd8e=_0x546562;_0x1a1ef8['errors']=[],_0x452eda[_0x11bd8e('0xa71')][_0x11bd8e('0x2003')]({'id':_0x2f75b8[_0x11bd8e('0x7f2')]['id']},_0x1a1ef8[_0x11bd8e('0x28d')])[_0x11bd8e('0xe53')]['then'](function(_0x2635ff){const _0x2980f0=_0x11bd8e;_0x1a1ef8[_0x2980f0('0x1573')][_0x2980f0('0x1167')](_0x2635ff[_0x2980f0('0x24e1')]()),_0xa7f2de[_0x2980f0('0x53')]({'title':_0x2980f0('0x266f'),'msg':_0x1a1ef8['freshsalesConfiguration'][_0x2980f0('0x60a')]?_0x1a1ef8['freshsalesConfiguration'][_0x2980f0('0x60a')]+'\x20has\x20been\x20created!':''}),_0x8c3cc7(_0x2635ff);})['catch'](function(_0x35a15e){const _0xd003ac=_0x11bd8e;if(_0x35a15e[_0xd003ac('0x5a5')]&&_0x35a15e[_0xd003ac('0x5a5')]['errors']&&_0x35a15e[_0xd003ac('0x5a5')][_0xd003ac('0x17f')][_0xd003ac('0x1564')]){_0x1a1ef8[_0xd003ac('0x17f')]=_0x35a15e[_0xd003ac('0x5a5')]['errors']||[{'message':_0x35a15e[_0xd003ac('0x1ff0')](),'type':_0xd003ac('0x51')}];for(let _0x1994db=0x0;_0x1994db<_0x35a15e['data']['errors']['length'];_0x1994db+=0x1){_0xa7f2de['error']({'title':_0x35a15e[_0xd003ac('0x5a5')][_0xd003ac('0x17f')][_0x1994db][_0xd003ac('0xcf0')],'msg':_0x35a15e['data'][_0xd003ac('0x17f')][_0x1994db][_0xd003ac('0x8c2')]});}}else _0xa7f2de[_0xd003ac('0x52a')]({'title':_0x35a15e[_0xd003ac('0x13ee')]?_0xd003ac('0x2168')+_0x35a15e[_0xd003ac('0x13ee')]+_0xd003ac('0xbf6')+_0x35a15e['statusText']:_0xd003ac('0x51'),'msg':_0x35a15e[_0xd003ac('0x5a5')]?JSON['stringify'](_0x35a15e[_0xd003ac('0x5a5')][_0xd003ac('0x8c2')]):_0x35a15e[_0xd003ac('0x1ff0')]()});});}function _0x20c335(){const _0x4ced8a=_0x546562;_0x1a1ef8[_0x4ced8a('0x17f')]=[],_0x452eda[_0x4ced8a('0x1be2')][_0x4ced8a('0x2480')]({'id':_0x1a1ef8[_0x4ced8a('0x28d')]['id']},_0x1a1ef8[_0x4ced8a('0x28d')])[_0x4ced8a('0xe53')][_0x4ced8a('0x683')](function(_0x55cb2a){const _0xd4f630=_0x4ced8a,_0xf19260=_0x2e3ca0()[_0xd4f630('0x1c07')](_0x1a1ef8[_0xd4f630('0x1573')],{'id':_0x55cb2a['id']});_0xf19260&&_0x2e3ca0()[_0xd4f630('0xf22')](_0xf19260,_0x2e3ca0()['pick'](_0x55cb2a[_0xd4f630('0x24e1')](),_0x2e3ca0()[_0xd4f630('0x55e')](_0xf19260))),_0xa7f2de[_0xd4f630('0x53')]({'title':_0xd4f630('0x19b3'),'msg':_0x1a1ef8[_0xd4f630('0x28d')]['name']?_0x1a1ef8[_0xd4f630('0x28d')][_0xd4f630('0x60a')]+_0xd4f630('0xf59'):''}),_0x8c3cc7(_0x55cb2a);})[_0x4ced8a('0x130a')](function(_0x3a7997){const _0x502ec1=_0x4ced8a;if(_0x3a7997[_0x502ec1('0x5a5')]&&_0x3a7997[_0x502ec1('0x5a5')][_0x502ec1('0x17f')]&&_0x3a7997[_0x502ec1('0x5a5')][_0x502ec1('0x17f')][_0x502ec1('0x1564')]){_0x1a1ef8[_0x502ec1('0x17f')]=_0x3a7997[_0x502ec1('0x5a5')][_0x502ec1('0x17f')]||[{'message':_0x3a7997[_0x502ec1('0x1ff0')](),'type':_0x502ec1('0x1832')}];for(let _0x4b8833=0x0;_0x4b8833<_0x3a7997[_0x502ec1('0x5a5')][_0x502ec1('0x17f')][_0x502ec1('0x1564')];_0x4b8833++){_0xa7f2de[_0x502ec1('0x52a')]({'title':_0x3a7997[_0x502ec1('0x5a5')][_0x502ec1('0x17f')][_0x4b8833][_0x502ec1('0xcf0')],'msg':_0x3a7997['data'][_0x502ec1('0x17f')][_0x4b8833][_0x502ec1('0x8c2')]});}}else _0xa7f2de['error']({'title':_0x3a7997[_0x502ec1('0x13ee')]?'API:'+_0x3a7997[_0x502ec1('0x13ee')]+_0x502ec1('0xbf6')+_0x3a7997[_0x502ec1('0x24a9')]:_0x502ec1('0x1832'),'msg':_0x3a7997[_0x502ec1('0x5a5')]?JSON[_0x502ec1('0x258a')](_0x3a7997['data'][_0x502ec1('0x8c2')]):_0x3a7997[_0x502ec1('0x1ff0')]()});});}function _0x20576e(_0x2ecfa4){const _0x579882=_0x546562;_0x1a1ef8[_0x579882('0x17f')]=[];const _0x4d2633=_0x495ba5[_0x579882('0x1c6f')]()[_0x579882('0xf28')](_0x579882('0x4d'))['content'](_0x579882('0x11c5'))[_0x579882('0x1040')](_0x579882('0x87'))['ok'](_0x579882('0x2307'))['cancel'](_0x579882('0x253a'))[_0x579882('0xe42')](_0x2ecfa4);_0x495ba5[_0x579882('0x1d4')](_0x4d2633)[_0x579882('0x683')](function(){const _0x21f1eb=_0x579882;_0x452eda[_0x21f1eb('0x1be2')][_0x21f1eb('0xd7e')]({'id':_0x1a1ef8[_0x21f1eb('0x28d')]['id']})['$promise']['then'](function(){const _0x2f61b7=_0x21f1eb;_0x2e3ca0()[_0x2f61b7('0x3ec')](_0x1a1ef8[_0x2f61b7('0x1573')],{'id':_0x1a1ef8[_0x2f61b7('0x28d')]['id']}),_0xa7f2de[_0x2f61b7('0x53')]({'title':_0x2f61b7('0x26f1'),'msg':(_0x1a1ef8[_0x2f61b7('0x28d')][_0x2f61b7('0x60a')]||_0x2f61b7('0x28d'))+'\x20has\x20been\x20deleted!'}),_0x8c3cc7(_0x1a1ef8[_0x2f61b7('0x28d')]);})[_0x21f1eb('0x130a')](function(_0x460755){const _0x5763be=_0x21f1eb;if(_0x460755['data']&&_0x460755[_0x5763be('0x5a5')][_0x5763be('0x17f')]&&_0x460755[_0x5763be('0x5a5')][_0x5763be('0x17f')][_0x5763be('0x1564')]){_0x1a1ef8[_0x5763be('0x17f')]=_0x460755[_0x5763be('0x5a5')][_0x5763be('0x17f')]||[{'message':_0x460755[_0x5763be('0x1ff0')](),'type':_0x5763be('0x1906')}];for(let _0x3a301e=0x0;_0x3a301e<_0x460755['data']['errors'][_0x5763be('0x1564')];_0x3a301e++){_0xa7f2de['error']({'title':_0x460755['data'][_0x5763be('0x17f')][_0x3a301e]['type'],'msg':_0x460755[_0x5763be('0x5a5')]['errors'][_0x3a301e][_0x5763be('0x8c2')]});}}else _0xa7f2de[_0x5763be('0x52a')]({'title':_0x460755[_0x5763be('0x13ee')]?_0x5763be('0x2168')+_0x460755[_0x5763be('0x13ee')]+_0x5763be('0xbf6')+_0x460755['statusText']:_0x5763be('0x1906'),'msg':_0x460755[_0x5763be('0x5a5')]?JSON['stringify'](_0x460755[_0x5763be('0x5a5')][_0x5763be('0x8c2')]):_0x460755[_0x5763be('0x8c2')]||_0x460755['toString']()});});},function(){});}function _0xf6523b(_0x2cad0b){return _0x2cad0b===null?undefined:new Date(_0x2cad0b);}function _0x8c3cc7(_0xe0fe84){_0x495ba5['hide'](_0xe0fe84);}}const _0x21a16b=_0x33a7d2;_0x5863da['$inject']=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x208d'),_0x189033('0x1996'),_0x189033('0x23ef'),'account',_0x189033('0xcf0'),_0x189033('0x56b'),'Auth','crudPermissions'];function _0x5863da(_0x88fc9,_0x1eae7d,_0x2abc95,_0x5d21f9,_0x55f538,_0x437a49,_0x322c52,_0x38bf6c,_0x2cf336,_0x319dbe,_0x47dd05,_0x51fca4,_0x2e69da){const _0x21468a=_0x189033,_0x5e3eb1=this;_0x5e3eb1[_0x21468a('0x11ed')]=_0x51fca4[_0x21468a('0x20b2')](),_0x5e3eb1['errors']=[],_0x5e3eb1[_0x21468a('0xf28')]=_0x21468a('0x176c')+_0x2e3ca0()[_0x21468a('0x65')](_0x319dbe),_0x5e3eb1['item']=angular[_0x21468a('0x1a86')](_0x38bf6c),_0x5e3eb1['items']=_0x322c52,_0x5e3eb1['type']=_0x319dbe,_0x5e3eb1[_0x21468a('0x1134')]=_0x2e69da,_0x5e3eb1[_0x21468a('0x3d2')]=![];!_0x5e3eb1[_0x21468a('0x23ef')]&&(_0x5e3eb1[_0x21468a('0x23ef')]={'type':'string'},_0x5e3eb1['item'][_0x2e3ca0()['capitalize'](_0x319dbe)+'Id']=_0x437a49['id'],_0x5e3eb1[_0x21468a('0xf28')]='INTEGRATIONS.NEW_'+_0x2e3ca0()[_0x21468a('0x65')](_0x319dbe),_0x5e3eb1[_0x21468a('0x3d2')]=!![]);_0x5e3eb1[_0x21468a('0x2591')]=_0x5592e1,_0x5e3eb1[_0x21468a('0x2716')]=_0x566367,_0x5e3eb1['deleteItem']=_0x2b2ca0,_0x5e3eb1[_0x21468a('0x18a')]=_0x506c4b,_0x5e3eb1[_0x21468a('0xf82')]=_0xeb607c,_0x47dd05[_0x21468a('0x26e0')][_0x21468a('0x1e6e')]({'nolimit':!![]})[_0x21468a('0xe53')][_0x21468a('0x683')](function(_0x384c50){const _0x48ce66=_0x21468a;return _0x5e3eb1[_0x48ce66('0x220b')]=_0x384c50[_0x48ce66('0xf5d')]?_0x384c50['rows']:[],_0x47dd05[_0x48ce66('0xf53')][_0x48ce66('0x2267')]()[_0x48ce66('0xe53')];})[_0x21468a('0x683')](function(_0x57e3fc){const _0x46cee9=_0x21468a;return _0x5e3eb1['voiceAgentReportColumns']=_0x2e3ca0()[_0x46cee9('0x2829')](_0x2e3ca0()[_0x46cee9('0x55e')](_0x57e3fc),[_0x46cee9('0xe53'),_0x46cee9('0x1980'),_0x46cee9('0x1a4'),_0x46cee9('0x2000'),_0x46cee9('0x1d58')]),_0x5e3eb1[_0x46cee9('0x20c1')][_0x46cee9('0x1fd0')](_0x46cee9('0x1e93')),_0x47dd05[_0x46cee9('0x1793')][_0x46cee9('0x2267')]()[_0x46cee9('0xe53')];})[_0x21468a('0x683')](function(_0x45848c){const _0x140e02=_0x21468a;_0x5e3eb1[_0x140e02('0x1d6a')]=_0x2e3ca0()['difference'](_0x2e3ca0()['keys'](_0x45848c),[_0x140e02('0xe53'),_0x140e02('0x1980'),_0x140e02('0x1a4'),_0x140e02('0x2000'),_0x140e02('0x1d58')]),_0x5e3eb1[_0x140e02('0x1d6a')][_0x140e02('0x1fd0')](_0x140e02('0x1e93'));})[_0x21468a('0x130a')](function(_0x3c681b){const _0xd005ec=_0x21468a;_0x55f538[_0xd005ec('0x52a')]({'title':_0x3c681b[_0xd005ec('0x13ee')]?'API:'+_0x3c681b[_0xd005ec('0x13ee')]+_0xd005ec('0xbf6')+_0x3c681b['statusText']:_0xd005ec('0x1fd3'),'msg':_0x3c681b[_0xd005ec('0x5a5')]?JSON[_0xd005ec('0x258a')](_0x3c681b[_0xd005ec('0x5a5')]):_0x3c681b['toString']()});}),_0x47dd05['intFreshsalesAccount'][_0x21468a('0x298')]({'id':_0x2cf336['id'],'ticketType':_0x437a49['ticketType']?_0x437a49[_0x21468a('0x20c9')]:undefined})['$promise']['then'](function(_0x143471){const _0x25519b=_0x21468a;_0x5e3eb1[_0x25519b('0xd32')]=!![],_0x5e3eb1[_0x25519b('0x189a')]=_0x143471['rows']?_0x143471['rows']:[],_0x5e3eb1[_0x25519b('0x23ef')]['idField']&&(_0x5e3eb1[_0x25519b('0x7f8')]=_0x2e3ca0()[_0x25519b('0x1c07')](_0x5e3eb1['fields'],{'id':_0x5e3eb1[_0x25519b('0x23ef')][_0x25519b('0x280')]}));})['catch'](function(_0xd4ab90){const _0x36e356=_0x21468a;_0x5e3eb1[_0x36e356('0xd32')]=![],console[_0x36e356('0x52a')](_0xd4ab90);});function _0x5592e1(){const _0x3a6226=_0x21468a;_0x5e3eb1[_0x3a6226('0x17f')]=[],_0x5e3eb1[_0x3a6226('0x7f8')]&&(_0x5e3eb1['item']['idField']=_0x5e3eb1[_0x3a6226('0x7f8')]['id'],_0x5e3eb1[_0x3a6226('0x23ef')][_0x3a6226('0x2584')]=_0x5e3eb1[_0x3a6226('0x7f8')]['name'],_0x5e3eb1[_0x3a6226('0x23ef')][_0x3a6226('0x7f8')]=_0x5e3eb1[_0x3a6226('0x7f8')]['custom']),_0x47dd05[_0x3a6226('0xddb')][_0x3a6226('0xb0a')](_0x5e3eb1[_0x3a6226('0x23ef')])[_0x3a6226('0xe53')][_0x3a6226('0x683')](function(_0x29c12b){const _0x300b87=_0x3a6226;_0x5e3eb1[_0x300b87('0x1996')][_0x300b87('0x1167')](_0x29c12b),_0x55f538[_0x300b87('0x53')]({'title':_0x2e3ca0()[_0x300b87('0x21ab')](_0x319dbe)+_0x300b87('0x282a'),'msg':_0x2e3ca0()[_0x300b87('0x21ab')](_0x319dbe)+_0x300b87('0x14b5')}),_0xeb607c();})['catch'](function(_0x39d081){const _0x524ec3=_0x3a6226;console[_0x524ec3('0x52a')](_0x39d081),_0x5e3eb1[_0x524ec3('0x17f')]=_0x39d081[_0x524ec3('0x5a5')][_0x524ec3('0x17f')]||[{'message':_0x39d081['toString'](),'type':'api.item.save'}];});}function _0x566367(){const _0x6f72d5=_0x21468a;_0x5e3eb1[_0x6f72d5('0x17f')]=[],_0x5e3eb1[_0x6f72d5('0x7f8')]&&(_0x5e3eb1[_0x6f72d5('0x23ef')][_0x6f72d5('0x280')]=_0x5e3eb1['customField']['id'],_0x5e3eb1['item'][_0x6f72d5('0x2584')]=_0x5e3eb1[_0x6f72d5('0x7f8')][_0x6f72d5('0x60a')],_0x5e3eb1[_0x6f72d5('0x23ef')][_0x6f72d5('0x7f8')]=_0x5e3eb1['customField'][_0x6f72d5('0xbf0')]),_0x47dd05[_0x6f72d5('0xddb')][_0x6f72d5('0x2480')]({'id':_0x5e3eb1[_0x6f72d5('0x23ef')]['id']},_0x5e3eb1['item'])[_0x6f72d5('0xe53')]['then'](function(_0x58a963){const _0xece2fd=_0x6f72d5,_0x2148a2=_0x2e3ca0()[_0xece2fd('0x1c07')](_0x5e3eb1[_0xece2fd('0x1996')],{'id':_0x58a963['id']});_0x2148a2&&_0x2e3ca0()[_0xece2fd('0xf22')](_0x2148a2,_0x58a963),_0x55f538[_0xece2fd('0x53')]({'title':_0x2e3ca0()['capitalize'](_0x319dbe)+_0xece2fd('0x15dd'),'msg':_0x2e3ca0()[_0xece2fd('0x21ab')](_0x319dbe)+_0xece2fd('0xf59')}),_0xeb607c();})[_0x6f72d5('0x130a')](function(_0x340374){const _0x1b6774=_0x6f72d5;console[_0x1b6774('0x52a')](_0x340374),_0x5e3eb1['errors']=_0x340374['data']['errors']||[{'message':_0x340374[_0x1b6774('0x1ff0')](),'type':'api.intItem.update'}];});}function _0x2b2ca0(_0x49f41a){const _0x40daab=_0x21468a;_0x5e3eb1['errors']=[];const _0x1f0d89=_0x5d21f9[_0x40daab('0x1c6f')]()['title'](_0x40daab('0x4d'))[_0x40daab('0xa6a')](_0x40daab('0x3fc')+_0x319dbe+_0x40daab('0x1ee7'))[_0x40daab('0x1040')](_0x40daab('0x609')+_0x2e3ca0()[_0x40daab('0x21ab')](_0x319dbe))['ok'](_0x40daab('0x2307'))[_0x40daab('0x19fb')]('Cancel')['targetEvent'](_0x49f41a);_0x5d21f9[_0x40daab('0x1d4')](_0x1f0d89)[_0x40daab('0x683')](function(){const _0x3353f6=_0x40daab;_0x47dd05[_0x3353f6('0xddb')][_0x3353f6('0xd7e')]({'id':_0x5e3eb1[_0x3353f6('0x23ef')]['id']})[_0x3353f6('0xe53')]['then'](function(){const _0x3fbb29=_0x3353f6;_0x2e3ca0()[_0x3fbb29('0x3ec')](_0x5e3eb1[_0x3fbb29('0x1996')],{'id':_0x5e3eb1['item']['id']}),_0x55f538[_0x3fbb29('0x53')]({'title':_0x2e3ca0()[_0x3fbb29('0x21ab')](_0x319dbe)+_0x3fbb29('0x27d7'),'msg':_0x2e3ca0()['capitalize'](_0x319dbe)+_0x3fbb29('0x194d')}),_0xeb607c();})[_0x3353f6('0x130a')](function(_0x127d34){const _0x33f65e=_0x3353f6;console['error'](_0x127d34),_0x5e3eb1[_0x33f65e('0x17f')]=_0x127d34[_0x33f65e('0x5a5')][_0x33f65e('0x17f')]||[{'message':_0x127d34[_0x33f65e('0x1ff0')](),'type':_0x33f65e('0x70c')}];});},function(){});}function _0x506c4b(){const _0x36258e=_0x21468a;return _0x5e3eb1[_0x36258e('0x23ef')][_0x36258e('0x113b')]!==undefined?_0x5e3eb1[_0x36258e('0x23ef')][_0x36258e('0x113b')]:_0x36258e('0xbbf');}function _0xeb607c(){const _0xfbf71d=_0x21468a;_0x5d21f9[_0xfbf71d('0x1715')]();}}const _0x53b96b=_0x5863da;_0x1c10af[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xf27'),_0x189033('0x22df')];function _0x1c10af(_0x2256fa,_0x25e01a,_0xfbfe41,_0x24bc43,_0x2d71b7,_0x58ebc7,_0x5dd728,_0x1728e2,_0xb6512f,_0x2fa130,_0x59ed24,_0x375fb7){const _0x1d4451=_0x189033,_0x253dfe=this;_0x253dfe[_0x1d4451('0x11ed')]=_0x2fa130[_0x1d4451('0x20b2')](),_0x253dfe[_0x1d4451('0xace')]=_0x58ebc7,_0x253dfe[_0x1d4451('0x260a')]=_0x5dd728,_0x253dfe['passwordPattern']=_0x253dfe[_0x1d4451('0x260a')][_0x1d4451('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x253dfe[_0x1d4451('0x1224')]=_0x25e01a[_0x1d4451('0x173e')]()+_0x1d4451('0x20de')+_0x25e01a[_0x1d4451('0x19ac')](),_0x253dfe[_0x1d4451('0xf27')]=_0x59ed24||_0x2256fa[_0x1d4451('0x7f2')][_0x1d4451('0xf27')]||{},_0x253dfe['userProfileSection']=_0x375fb7&&_0x375fb7[_0x1d4451('0x50d')]==0x1?_0x375fb7[_0x1d4451('0xf5d')][0x0]:null,_0x253dfe[_0x1d4451('0x1134')]=_0x2fa130[_0x1d4451('0x142a')](_0x253dfe['userProfileSection']?_0x253dfe['userProfileSection'][_0x1d4451('0x1134')]:null),_0x253dfe[_0x1d4451('0x258d')]={},_0x253dfe[_0x1d4451('0x517')]=_0x2256fa['params']['tab']||0x0,_0x253dfe[_0x1d4451('0x2430')]=_0xb6512f[_0x1d4451('0x2289')],_0x253dfe[_0x1d4451('0x21ae')]=_0x194319,_0x253dfe[_0x1d4451('0x2579')]=_0x3e66b4;function _0x194319(){const _0x350c96=_0x1d4451;_0x2256fa['go'](_0x350c96('0xd78'),{},{'reload':_0x350c96('0xd78')});}function _0x3e66b4(){const _0x2378fc=_0x1d4451;_0x1728e2[_0x2378fc('0xa71')][_0x2378fc('0x2480')]({'id':_0x253dfe[_0x2378fc('0xf27')]['id']},_0x253dfe[_0x2378fc('0xf27')])['$promise'][_0x2378fc('0x683')](function(){const _0xe2d0ce=_0x2378fc;_0xb6512f[_0xe2d0ce('0x53')]({'title':_0xe2d0ce('0x1b68'),'msg':_0x253dfe[_0xe2d0ce('0xf27')][_0xe2d0ce('0x60a')]?_0x253dfe['freshsalesAccount']['name']+'\x20has\x20been\x20updated!':''});})[_0x2378fc('0x130a')](function(_0x1b279a){const _0x37d81f=_0x2378fc;_0xb6512f[_0x37d81f('0x52a')]({'title':_0x1b279a[_0x37d81f('0x13ee')]?_0x37d81f('0x2168')+_0x1b279a[_0x37d81f('0x13ee')]+_0x37d81f('0xbf6')+_0x1b279a[_0x37d81f('0x24a9')]:_0x37d81f('0x23b3'),'msg':_0x1b279a[_0x37d81f('0x5a5')]?JSON['stringify'](_0x1b279a[_0x37d81f('0x5a5')]):_0x1b279a[_0x37d81f('0x1ff0')]()});});}}const _0x7401db=_0x1c10af,_0x20fccf=_0x180212['p']+'src/js/modules/main/apps/integrations/views/freshsalesAccounts/create/dialog.html/dialog.html';_0x35c72a[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),'$document','$timeout','$translate',_0x189033('0x2808'),_0x189033('0x2a'),'userProfileSection',_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x35c72a(_0x4ca3e7,_0x45fa18,_0x54f0b8,_0x41c019,_0x8a3ad5,_0x8a5e38,_0x404a21,_0x3e5387,_0x13bc4d,_0x4880b6,_0x5cd5d9,_0x4006fd,_0x11c42f,_0x3a793e,_0x1a0949,_0x55d746,_0x44d895){const _0x410244=_0x189033,_0x4f2eec=this;_0x4f2eec['license']=_0x55d746,_0x4f2eec[_0x410244('0x260a')]=_0x44d895,_0x4f2eec[_0x410244('0x11ed')]=_0x1a0949[_0x410244('0x20b2')](),_0x4f2eec[_0x410244('0x2808')]=_0x13bc4d||{'count':0x0,'rows':[]},_0x4f2eec[_0x410244('0x2a')]=_0x4880b6,_0x4f2eec[_0x410244('0x22df')]=_0x5cd5d9&&_0x5cd5d9[_0x410244('0x50d')]==0x1?_0x5cd5d9[_0x410244('0xf5d')][0x0]:null,_0x4f2eec[_0x410244('0x1134')]=_0x1a0949[_0x410244('0x142a')](_0x4f2eec[_0x410244('0x22df')]?_0x4f2eec[_0x410244('0x22df')]['crudPermissions']:null),_0x4f2eec[_0x410244('0x5c4')]='freshsalesAccounts',_0x4f2eec[_0x410244('0x247')]='',_0x4f2eec[_0x410244('0x1ce2')]=null,_0x4f2eec['selectedFreshsalesAccounts']=[],_0x4f2eec[_0x410244('0x23a2')]={'fields':_0x410244('0x149d'),'limit':0xa,'page':0x1},_0x4f2eec['editstate']=_0x4667a2,_0x4f2eec[_0x410244('0x375')]=_0x4a24bb,_0x4f2eec[_0x410244('0x194f')]=_0x26902a,_0x4f2eec[_0x410244('0x53')]=_0x3b173c,_0x4f2eec[_0x410244('0x932')]=_0x18a1d5,_0x4f2eec['createOrEditFreshsalesAccount']=_0x5a178c,_0x4f2eec[_0x410244('0xf25')]=_0x1b02c0,_0x4f2eec[_0x410244('0x684')]=_0x11543b,_0x4f2eec[_0x410244('0x217e')]=_0x5dd380,_0x4f2eec[_0x410244('0x667')]=_0x274c2d,_0x4f2eec[_0x410244('0x1cc1')]=_0x20a859;function _0x4667a2(_0x719827){const _0x32e2b4=_0x410244;_0x54f0b8['go'](_0x32e2b4('0x11c7'),{'id':_0x719827['id'],'freshsalesAccount':_0x719827,'crudPermissions':_0x4f2eec[_0x32e2b4('0x1134')]});}function _0x4a24bb(_0x2e2bb9){const _0x168724=_0x410244;return _0x4006fd['intFreshsalesAccount'][_0x168724('0x298')]({'id':_0x2e2bb9['id'],'test':!![]})[_0x168724('0xe53')][_0x168724('0x683')](function(){const _0x410b98=_0x168724;_0x3a793e[_0x410b98('0x53')]({'title':'FreshsalesAccount\x20properly\x20tested','msg':_0x410b98('0x1c6d')});})[_0x168724('0x130a')](function(_0x195c1f){const _0xf7e4c4=_0x168724;_0x3a793e[_0xf7e4c4('0x52a')]({'title':_0xf7e4c4('0x778'),'msg':_0x195c1f['data']?_0x195c1f[_0xf7e4c4('0x5a5')][_0xf7e4c4('0x8c2')]?_0x195c1f[_0xf7e4c4('0x5a5')][_0xf7e4c4('0x8c2')]:JSON[_0xf7e4c4('0x258a')](_0x195c1f['data']):_0x195c1f[_0xf7e4c4('0x1ff0')]()});});}function _0x26902a(_0x449184,_0x211051){const _0x313574=_0x410244,_0x27b4b0=_0x8a3ad5[_0x313574('0x1c6f')]()[_0x313574('0xf28')](_0x313574('0x1b01')+_0x2e3ca0()[_0x313574('0x1e03')](_0x313574('0xf27'))+'?')['htmlContent'](''+(_0x449184[_0x313574('0x60a')]||_0x313574('0xf27'))+''+'\x20will\x20be\x20deleted.')[_0x313574('0x1040')]('delete\x20freshsalesAccount')[_0x313574('0xe42')](_0x211051)['ok']('OK')[_0x313574('0x19fb')]('CANCEL');_0x8a3ad5[_0x313574('0x1d4')](_0x27b4b0)[_0x313574('0x683')](function(){_0x1b02c0(_0x449184);},function(){const _0x40f78f=_0x313574;console[_0x40f78f('0x1b2b')](_0x40f78f('0x16b8'));});}let _0x300000=!![],_0x44f7dd=0x1;_0x4ca3e7[_0x410244('0x186d')](_0x410244('0x1e1d'),function(_0x13d4ca,_0xb2e136){const _0x32b974=_0x410244;_0x300000?_0x404a21(function(){_0x300000=![];}):(!_0xb2e136&&(_0x44f7dd=_0x4f2eec[_0x32b974('0x23a2')][_0x32b974('0xdf8')]),_0x13d4ca!==_0xb2e136&&(_0x4f2eec[_0x32b974('0x23a2')]['page']=0x1),!_0x13d4ca&&(_0x4f2eec[_0x32b974('0x23a2')][_0x32b974('0xdf8')]=_0x44f7dd),_0x4f2eec['getFreshsalesAccounts']());});function _0x3b173c(_0x1ae7b5){const _0x1a7d1e=_0x410244;_0x4f2eec[_0x1a7d1e('0x2808')]=_0x1ae7b5||{'count':0x0,'rows':[]};}function _0x18a1d5(){const _0xe75110=_0x410244;_0x4f2eec['query'][_0xe75110('0x1cc8')]=(_0x4f2eec[_0xe75110('0x23a2')][_0xe75110('0xdf8')]-0x1)*_0x4f2eec[_0xe75110('0x23a2')]['limit'],_0x1a0949['hasRole'](_0xe75110('0x20c2'))?_0x4f2eec[_0xe75110('0x1883')]=_0x4006fd[_0xe75110('0xa71')][_0xe75110('0x1e6e')](_0x4f2eec[_0xe75110('0x23a2')],_0x3b173c)[_0xe75110('0xe53')]:(_0x4f2eec['query']['id']=_0x4f2eec['userProfile']['id'],_0x4f2eec[_0xe75110('0x23a2')]['section']=_0xe75110('0x94f'),_0x4f2eec[_0xe75110('0x1883')]=_0x4006fd[_0xe75110('0x2a')][_0xe75110('0x241d')](_0x4f2eec[_0xe75110('0x23a2')],_0x3b173c)[_0xe75110('0xe53')]);}function _0x5a178c(_0x35baf5,_0x2dc210){const _0x2083ed=_0x410244;_0x8a3ad5[_0x2083ed('0x1d4')]({'controller':'CreateOrEditFreshsalesAccountDialogController','controllerAs':'vm','templateUrl':_0x20fccf,'parent':angular[_0x2083ed('0x1fcc')](_0x8a5e38[_0x2083ed('0x18e5')]),'targetEvent':_0x35baf5,'clickOutsideToClose':!![],'locals':{'freshsalesAccount':_0x2dc210,'freshsalesAccounts':_0x4f2eec[_0x2083ed('0x2808')][_0x2083ed('0xf5d')],'license':_0x4f2eec[_0x2083ed('0xace')],'setting':_0x4f2eec['setting'],'crudPermissions':_0x4f2eec[_0x2083ed('0x1134')]}});}function _0x1b02c0(_0x4b6c46){const _0x2bf667=_0x410244;_0x4006fd[_0x2bf667('0xa71')][_0x2bf667('0xd7e')]({'id':_0x4b6c46['id']})[_0x2bf667('0xe53')][_0x2bf667('0x683')](function(){const _0x4c51d6=_0x2bf667;_0x2e3ca0()[_0x4c51d6('0x3ec')](_0x4f2eec[_0x4c51d6('0x2808')][_0x4c51d6('0xf5d')],{'id':_0x4b6c46['id']}),_0x4f2eec['freshsalesAccounts']['count']-=0x1,!_0x4f2eec['freshsalesAccounts']['rows']['length']&&_0x4f2eec[_0x4c51d6('0x932')](),_0x3a793e[_0x4c51d6('0x53')]({'title':_0x2e3ca0()[_0x4c51d6('0x1e03')]('FreshsalesAccount')+_0x4c51d6('0xbfc'),'msg':_0x4b6c46[_0x4c51d6('0x60a')]?_0x4b6c46[_0x4c51d6('0x60a')]+_0x4c51d6('0x194d'):''});})['catch'](function(_0x1c738a){const _0x252a88=_0x2bf667;if(_0x1c738a[_0x252a88('0x5a5')]&&_0x1c738a[_0x252a88('0x5a5')][_0x252a88('0x17f')]&&_0x1c738a['data'][_0x252a88('0x17f')][_0x252a88('0x1564')]){_0x4f2eec[_0x252a88('0x17f')]=_0x1c738a[_0x252a88('0x5a5')][_0x252a88('0x17f')]||[{'message':_0x1c738a[_0x252a88('0x1ff0')](),'type':_0x252a88('0x1f3d')}];for(let _0x517086=0x0;_0x517086<_0x1c738a['data']['errors'][_0x252a88('0x1564')];_0x517086++){_0x3a793e[_0x252a88('0x52a')]({'title':_0x1c738a[_0x252a88('0x5a5')][_0x252a88('0x17f')][_0x517086][_0x252a88('0xcf0')],'msg':_0x1c738a['data'][_0x252a88('0x17f')][_0x517086][_0x252a88('0x8c2')]});}}else _0x3a793e[_0x252a88('0x52a')]({'title':_0x1c738a['status']?_0x252a88('0x2168')+_0x1c738a['status']+_0x252a88('0xbf6')+_0x1c738a[_0x252a88('0x24a9')]:_0x252a88('0x1f3d'),'msg':_0x1c738a[_0x252a88('0x5a5')]?JSON[_0x252a88('0x258a')](_0x1c738a[_0x252a88('0x5a5')]['message']):_0x1c738a[_0x252a88('0x8c2')]||_0x1c738a['toString']()});});}function _0x11543b(){const _0x368591=_0x410244,_0x1db391=angular[_0x368591('0x1a86')](_0x4f2eec[_0x368591('0x299')]);return _0x4f2eec[_0x368591('0x299')]=[],_0x1db391;}function _0x5dd380(_0x162d70){const _0x5afeef=_0x410244,_0x2c8f42=_0x8a3ad5[_0x5afeef('0x1c6f')]()[_0x5afeef('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20freshsalesAccounts?')[_0x5afeef('0x26e3')](_0x5afeef('0xed5')+_0x4f2eec['selectedFreshsalesAccounts'][_0x5afeef('0x1564')]+_0x5afeef('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel']('delete\x20FreshsalesAccounts')[_0x5afeef('0xe42')](_0x162d70)['ok']('OK')[_0x5afeef('0x19fb')]('CANCEL');_0x8a3ad5[_0x5afeef('0x1d4')](_0x2c8f42)['then'](function(){const _0x50f76e=_0x5afeef;_0x4f2eec['selectedFreshsalesAccounts'][_0x50f76e('0x1299')](function(_0xb184cd){_0x1b02c0(_0xb184cd);}),_0x4f2eec[_0x50f76e('0x299')]=[];});}function _0x274c2d(){_0x4f2eec['selectedFreshsalesAccounts']=[];}function _0x20a859(){const _0x8fc930=_0x410244;_0x4f2eec[_0x8fc930('0x299')]=_0x4f2eec[_0x8fc930('0x2808')][_0x8fc930('0xf5d')];}}const _0x6c7185=_0x35c72a;_0x1f38ea[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0xcdc'),'salesforceAccount',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x1f38ea(_0x5246b9,_0x45bfcc,_0x157c29,_0x339579,_0x4fbd1d,_0x22dcea,_0x3481c4,_0xa73b12,_0x2e82db,_0x24064b,_0x17cc36,_0x5b0dd7,_0x40cc4b,_0x32bd48){const _0xa3c0b9=_0x189033,_0xf01ab0=this;_0xf01ab0['currentUser']=_0x17cc36[_0xa3c0b9('0x20b2')](),_0xf01ab0[_0xa3c0b9('0x17f')]=[],_0xf01ab0[_0xa3c0b9('0x260a')]=_0x40cc4b,_0xf01ab0[_0xa3c0b9('0xace')]=_0x5b0dd7,_0xf01ab0['crudPermissions']=_0x32bd48,_0xf01ab0[_0xa3c0b9('0x258d')]={},_0xf01ab0['passwordPattern']=_0xf01ab0[_0xa3c0b9('0x260a')]&&_0xf01ab0[_0xa3c0b9('0x260a')][_0xa3c0b9('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xf01ab0['title']=_0xa3c0b9('0xfc4'),_0xf01ab0[_0xa3c0b9('0x2769')]=angular[_0xa3c0b9('0x1a86')](_0x2e82db),_0xf01ab0[_0xa3c0b9('0xcdc')]=_0xa73b12,_0xf01ab0['newSalesforceAccount']=![];!_0xf01ab0[_0xa3c0b9('0x2769')]&&(_0xf01ab0[_0xa3c0b9('0x2769')]={'type':'integrationTab','serverUrl':_0x157c29['protocol']()+_0xa3c0b9('0x20de')+_0x157c29[_0xa3c0b9('0x19ac')]()+(_0x157c29[_0xa3c0b9('0x4a2')]()?':'+_0x157c29[_0xa3c0b9('0x4a2')]():'')},_0xf01ab0['title']=_0xa3c0b9('0x2700'),_0xf01ab0[_0xa3c0b9('0x17d8')]=!![]);_0xf01ab0[_0xa3c0b9('0x1de8')]=_0x2b4c31,_0xf01ab0[_0xa3c0b9('0x15b8')]=_0x337060,_0xf01ab0[_0xa3c0b9('0x138c')]=_0x5ca046,_0xf01ab0[_0xa3c0b9('0x16b3')]=_0x37d2bd,_0xf01ab0['closeDialog']=_0xec1761;function _0x2b4c31(){const _0x2ad9e1=_0xa3c0b9;_0xf01ab0[_0x2ad9e1('0x17f')]=[],_0x24064b[_0x2ad9e1('0xf30')][_0x2ad9e1('0xb0a')](_0xf01ab0['salesforceAccount'])['$promise'][_0x2ad9e1('0x683')](function(_0x147a76){const _0xdba8b1=_0x2ad9e1;_0xf01ab0[_0xdba8b1('0xcdc')]['unshift'](_0x147a76[_0xdba8b1('0x24e1')]()),_0x3481c4[_0xdba8b1('0x53')]({'title':'SalesforceAccount\x20properly\x20created','msg':_0xf01ab0[_0xdba8b1('0x2769')]['name']?_0xf01ab0[_0xdba8b1('0x2769')][_0xdba8b1('0x60a')]+_0xdba8b1('0x14b5'):''}),_0xec1761(_0x147a76);})[_0x2ad9e1('0x130a')](function(_0x40eec1){const _0xa00297=_0x2ad9e1;if(_0x40eec1[_0xa00297('0x5a5')]&&_0x40eec1[_0xa00297('0x5a5')][_0xa00297('0x17f')]&&_0x40eec1[_0xa00297('0x5a5')]['errors']['length']){_0xf01ab0[_0xa00297('0x17f')]=_0x40eec1['data']['errors']||[{'message':_0x40eec1[_0xa00297('0x1ff0')](),'type':_0xa00297('0x6ea')}];for(let _0x476139=0x0;_0x476139<_0x40eec1['data']['errors'][_0xa00297('0x1564')];_0x476139+=0x1){_0x3481c4[_0xa00297('0x52a')]({'title':_0x40eec1[_0xa00297('0x5a5')][_0xa00297('0x17f')][_0x476139]['type'],'msg':_0x40eec1['data'][_0xa00297('0x17f')][_0x476139][_0xa00297('0x8c2')]});}}else _0x3481c4[_0xa00297('0x52a')]({'title':_0x40eec1[_0xa00297('0x13ee')]?_0xa00297('0x2168')+_0x40eec1[_0xa00297('0x13ee')]+_0xa00297('0xbf6')+_0x40eec1[_0xa00297('0x24a9')]:_0xa00297('0x6ea'),'msg':_0x40eec1['data']?JSON[_0xa00297('0x258a')](_0x40eec1['data'][_0xa00297('0x8c2')]):_0x40eec1[_0xa00297('0x1ff0')]()});});}function _0x337060(){const _0x237c82=_0xa3c0b9;_0xf01ab0[_0x237c82('0x17f')]=[],_0x24064b[_0x237c82('0xf30')][_0x237c82('0x2480')]({'id':_0xf01ab0['salesforceAccount']['id']},_0xf01ab0[_0x237c82('0x2769')])[_0x237c82('0xe53')]['then'](function(_0x3a24db){const _0xe33a33=_0x237c82,_0x27a6f7=_0x2e3ca0()[_0xe33a33('0x1c07')](_0xf01ab0['salesforceAccounts'],{'id':_0x3a24db['id']});_0x27a6f7&&_0x2e3ca0()[_0xe33a33('0xf22')](_0x27a6f7,_0x2e3ca0()['pick'](_0x3a24db[_0xe33a33('0x24e1')](),_0x2e3ca0()['keys'](_0x27a6f7))),_0x3481c4[_0xe33a33('0x53')]({'title':_0xe33a33('0x188a'),'msg':_0xf01ab0['salesforceAccount'][_0xe33a33('0x60a')]?_0xf01ab0[_0xe33a33('0x2769')]['name']+'\x20has\x20been\x20saved!':''}),_0xec1761(_0x3a24db);})['catch'](function(_0x284b85){const _0x28c9e2=_0x237c82;if(_0x284b85[_0x28c9e2('0x5a5')]&&_0x284b85[_0x28c9e2('0x5a5')][_0x28c9e2('0x17f')]&&_0x284b85[_0x28c9e2('0x5a5')][_0x28c9e2('0x17f')][_0x28c9e2('0x1564')]){_0xf01ab0['errors']=_0x284b85[_0x28c9e2('0x5a5')]['errors']||[{'message':_0x284b85['toString'](),'type':_0x28c9e2('0x1678')}];for(let _0x152850=0x0;_0x152850<_0x284b85['data'][_0x28c9e2('0x17f')][_0x28c9e2('0x1564')];_0x152850++){_0x3481c4[_0x28c9e2('0x52a')]({'title':_0x284b85[_0x28c9e2('0x5a5')]['errors'][_0x152850][_0x28c9e2('0xcf0')],'msg':_0x284b85['data']['errors'][_0x152850]['message']});}}else _0x3481c4[_0x28c9e2('0x52a')]({'title':_0x284b85[_0x28c9e2('0x13ee')]?_0x28c9e2('0x2168')+_0x284b85[_0x28c9e2('0x13ee')]+'\x20-\x20'+_0x284b85[_0x28c9e2('0x24a9')]:'api.intSalesforceAccount.update','msg':_0x284b85[_0x28c9e2('0x5a5')]?JSON[_0x28c9e2('0x258a')](_0x284b85[_0x28c9e2('0x5a5')][_0x28c9e2('0x8c2')]):_0x284b85[_0x28c9e2('0x1ff0')]()});});}function _0x5ca046(_0x56b167){const _0x397bdd=_0xa3c0b9;_0xf01ab0[_0x397bdd('0x17f')]=[];const _0x413f17=_0x339579[_0x397bdd('0x1c6f')]()[_0x397bdd('0xf28')]('Are\x20you\x20sure?')[_0x397bdd('0xa6a')](_0x397bdd('0x2805'))['ariaLabel'](_0x397bdd('0x9fa'))['ok'](_0x397bdd('0x2307'))[_0x397bdd('0x19fb')](_0x397bdd('0x253a'))[_0x397bdd('0xe42')](_0x56b167);_0x339579[_0x397bdd('0x1d4')](_0x413f17)['then'](function(){const _0x5e6f30=_0x397bdd;_0x24064b[_0x5e6f30('0xf30')]['delete']({'id':_0xf01ab0[_0x5e6f30('0x2769')]['id']})[_0x5e6f30('0xe53')][_0x5e6f30('0x683')](function(){const _0x23976d=_0x5e6f30;_0x2e3ca0()[_0x23976d('0x3ec')](_0xf01ab0[_0x23976d('0xcdc')],{'id':_0xf01ab0['salesforceAccount']['id']}),_0x3481c4[_0x23976d('0x53')]({'title':'SalesforceAccount\x20properly\x20deleted!','msg':(_0xf01ab0[_0x23976d('0x2769')][_0x23976d('0x60a')]||_0x23976d('0x2769'))+_0x23976d('0x194d')}),_0xec1761(_0xf01ab0[_0x23976d('0x2769')]);})[_0x5e6f30('0x130a')](function(_0x383abb){const _0x3d1f96=_0x5e6f30;if(_0x383abb['data']&&_0x383abb[_0x3d1f96('0x5a5')][_0x3d1f96('0x17f')]&&_0x383abb[_0x3d1f96('0x5a5')][_0x3d1f96('0x17f')][_0x3d1f96('0x1564')]){_0xf01ab0[_0x3d1f96('0x17f')]=_0x383abb[_0x3d1f96('0x5a5')]['errors']||[{'message':_0x383abb['toString'](),'type':'api.intSalesforceAccount.delete'}];for(let _0x4f31e5=0x0;_0x4f31e5<_0x383abb[_0x3d1f96('0x5a5')]['errors'][_0x3d1f96('0x1564')];_0x4f31e5++){_0x3481c4[_0x3d1f96('0x52a')]({'title':_0x383abb[_0x3d1f96('0x5a5')][_0x3d1f96('0x17f')][_0x4f31e5][_0x3d1f96('0xcf0')],'msg':_0x383abb['data'][_0x3d1f96('0x17f')][_0x4f31e5]['message']});}}else _0x3481c4[_0x3d1f96('0x52a')]({'title':_0x383abb[_0x3d1f96('0x13ee')]?_0x3d1f96('0x2168')+_0x383abb['status']+_0x3d1f96('0xbf6')+_0x383abb[_0x3d1f96('0x24a9')]:_0x3d1f96('0x19e4'),'msg':_0x383abb[_0x3d1f96('0x5a5')]?JSON['stringify'](_0x383abb[_0x3d1f96('0x5a5')][_0x3d1f96('0x8c2')]):_0x383abb['message']||_0x383abb[_0x3d1f96('0x1ff0')]()});});},function(){});}function _0x37d2bd(_0x5c1ade){return _0x5c1ade===null?undefined:new Date(_0x5c1ade);}function _0xec1761(_0x830af3){const _0x1d6b20=_0xa3c0b9;_0x339579[_0x1d6b20('0x1715')](_0x830af3);}}const _0x4b6c99=_0x1f38ea,_0x5aff40=_0x180212['p']+_0x189033('0x11fb'),_0x3e2bfd=_0x180212['p']+'src/js/modules/main/apps/integrations/views/salesforceAccounts/edit/item/dialog.html/dialog.html';_0x3aca0c[_0x189033('0x14be')]=['$mdDialog',_0x189033('0x16ea'),'api',_0x189033('0x1d70'),_0x189033('0xba1')];function _0x3aca0c(_0x10ce17,_0x5780ec,_0x2997c5,_0x389680,_0xf747bc){const _0x5a5a09=_0x189033,_0x125f5d=this;_0x125f5d[_0x5a5a09('0x11ed')]=_0xf747bc['getCurrentUser'](),_0x125f5d['salesforceAccount']={},_0x125f5d['salesforceConfiguration']={},_0x125f5d[_0x5a5a09('0x1573')]=[],_0x125f5d[_0x5a5a09('0x3a6')]=-0x1,_0x125f5d['crudPermissions'],_0x125f5d[_0x5a5a09('0x12f3')]=_0x54ff78,_0x125f5d['getSalesforceConfiguration']=_0x542b34,_0x125f5d['createOrEditSalesforceConfiguration']=_0x760c56,_0x125f5d[_0x5a5a09('0x7f5')]=_0x5a46be,_0x125f5d[_0x5a5a09('0x284e')]=_0x49389e;function _0x49389e(){const _0x3cc55e=_0x5a5a09;return _0x2997c5['intSalesforceConfiguration'][_0x3cc55e('0x2480')]({'id':_0x125f5d['salesforceConfiguration']['id']},_0x125f5d['salesforceConfiguration'])[_0x3cc55e('0xe53')][_0x3cc55e('0x683')](function(){const _0x10cf3e=_0x3cc55e;_0x389680[_0x10cf3e('0x53')]({'title':_0x10cf3e('0x52c'),'msg':_0x10cf3e('0x1e73')});})['catch'](function(_0x4cf870){const _0x25dec2=_0x3cc55e;_0x389680[_0x25dec2('0x52a')]({'title':_0x4cf870['status']?_0x25dec2('0x2168')+_0x4cf870['status']+_0x25dec2('0xbf6')+_0x4cf870[_0x25dec2('0x24a9')]:'SYSTEM:UPDATECONFIGURATIONFIELD','msg':_0x4cf870[_0x25dec2('0x5a5')]?JSON[_0x25dec2('0x258a')](_0x4cf870[_0x25dec2('0x5a5')]):_0x4cf870['toString']()});});}function _0x54ff78(_0x4d0ede,_0xe913fa){const _0x262842=_0x5a5a09;_0x125f5d[_0x262842('0x2769')]=_0x4d0ede,_0x125f5d['crudPermissions']=typeof _0xe913fa!==_0x262842('0x1867')?_0xe913fa:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x2997c5['intSalesforceAccount'][_0x262842('0x1575')]({'id':_0x125f5d[_0x262842('0x2769')]['id'],'sort':'-updatedAt'})['$promise'][_0x262842('0x683')](function(_0x580204){const _0x1ef44e=_0x262842;return _0x125f5d['configurations']=_0x580204[_0x1ef44e('0xf5d')]?_0x580204[_0x1ef44e('0xf5d')]:[],_0x125f5d['configurations'][_0x1ef44e('0x1564')]&&_0x125f5d['getSalesforceConfiguration'](0x0),_0x2997c5['variable'][_0x1ef44e('0x1e6e')]({'nolimit':!![],'sort':'name'})['$promise'];})['then'](function(_0x33c476){const _0x1dcc75=_0x262842;_0x125f5d[_0x1dcc75('0x220b')]=_0x33c476[_0x1dcc75('0xf5d')]?_0x33c476[_0x1dcc75('0xf5d')]:[],_0x125f5d[_0x1dcc75('0x1822')]=_0x2e3ca0()[_0x1dcc75('0x24db')](_0x125f5d[_0x1dcc75('0x220b')],'id');})['catch'](function(_0x46a2b8){const _0x428f41=_0x262842;_0x389680[_0x428f41('0x52a')]({'title':_0x46a2b8[_0x428f41('0x13ee')]?_0x428f41('0x2168')+_0x46a2b8[_0x428f41('0x13ee')]+_0x428f41('0xbf6')+_0x46a2b8['statusText']:_0x428f41('0xe2a'),'msg':_0x46a2b8[_0x428f41('0x5a5')]?JSON['stringify'](_0x46a2b8['data']):_0x46a2b8[_0x428f41('0x1ff0')]()});});}function _0x542b34(_0xc297f){const _0x124ce0=_0x5a5a09;_0x125f5d[_0x124ce0('0x1821')]=_0x125f5d[_0x124ce0('0x1573')][_0xc297f],_0x125f5d['selectedSalesforceConfiguration']=_0xc297f,_0x2997c5[_0x124ce0('0x161f')]['getSubjects']({'id':_0x125f5d[_0x124ce0('0x1821')]['id']})[_0x124ce0('0xe53')][_0x124ce0('0x683')](function(_0xbf1321){const _0x4214a0=_0x124ce0;return _0x125f5d['subjects']=_0xbf1321['rows']?_0xbf1321[_0x4214a0('0xf5d')]:[],_0x2997c5['intSalesforceConfiguration']['getDescriptions']({'id':_0x125f5d[_0x4214a0('0x1821')]['id']})[_0x4214a0('0xe53')];})[_0x124ce0('0x683')](function(_0x11ee8c){const _0x1a2d6b=_0x124ce0;return _0x125f5d[_0x1a2d6b('0x18f7')]=_0x11ee8c[_0x1a2d6b('0xf5d')]?_0x11ee8c[_0x1a2d6b('0xf5d')]:[],_0x2997c5[_0x1a2d6b('0x161f')][_0x1a2d6b('0x298')]({'id':_0x125f5d['salesforceConfiguration']['id']})['$promise'];})[_0x124ce0('0x683')](function(_0x29b174){const _0x1d644c=_0x124ce0;_0x125f5d[_0x1d644c('0x189a')]=_0x29b174[_0x1d644c('0xf5d')]?_0x29b174['rows']:[];})[_0x124ce0('0x130a')](function(_0x45e3b7){const _0x25fb15=_0x124ce0;_0x389680[_0x25fb15('0x52a')]({'title':_0x45e3b7['status']?'API:'+_0x45e3b7[_0x25fb15('0x13ee')]+'\x20-\x20'+_0x45e3b7['statusText']:_0x25fb15('0x167c'),'msg':_0x45e3b7[_0x25fb15('0x5a5')]?JSON[_0x25fb15('0x258a')](_0x45e3b7[_0x25fb15('0x5a5')]):_0x45e3b7['toString']()});});}function _0x760c56(_0x17b045,_0x4ba184){const _0x2a8612=_0x5a5a09;_0x10ce17['show']({'controller':_0x2a8612('0x1a1e'),'controllerAs':'vm','templateUrl':_0x5aff40,'parent':angular[_0x2a8612('0x1fcc')](_0x5780ec[_0x2a8612('0x18e5')]),'targetEvent':_0x17b045,'clickOutsideToClose':!![],'locals':{'salesforceConfiguration':_0x4ba184,'configurations':_0x125f5d[_0x2a8612('0x1573')],'license':null,'setting':null,'crudPermissions':_0x125f5d[_0x2a8612('0x1134')]}})[_0x2a8612('0x2874')](function(){const _0x2a8e23=_0x2a8612;_0x125f5d[_0x2a8e23('0x1d9')](0x0);});}function _0x5a46be(_0x4fe461,_0x18ad2d){const _0xdf93a6=_0x5a5a09,_0xd4cff9=_0x10ce17[_0xdf93a6('0x1c6f')]()['title'](_0xdf93a6('0x1320'))[_0xdf93a6('0x26e3')](_0xdf93a6('0xed5')+(_0x18ad2d['name']||'salesforceConfiguration')+''+_0xdf93a6('0x1ee7'))[_0xdf93a6('0x1040')](_0xdf93a6('0x1647'))['targetEvent'](_0x4fe461)['ok']('OK')[_0xdf93a6('0x19fb')](_0xdf93a6('0x16b8'));_0x10ce17['show'](_0xd4cff9)[_0xdf93a6('0x683')](function(){const _0x3a42d2=_0xdf93a6;_0x2997c5['intSalesforceConfiguration'][_0x3a42d2('0xd7e')]({'id':_0x18ad2d['id']})['$promise'][_0x3a42d2('0x683')](function(){const _0xda91c2=_0x3a42d2;_0x2e3ca0()[_0xda91c2('0x3ec')](_0x125f5d[_0xda91c2('0x1573')],{'id':_0x18ad2d['id']}),_0x389680[_0xda91c2('0x53')]({'title':_0xda91c2('0x202c'),'msg':_0x18ad2d['name']?_0x18ad2d[_0xda91c2('0x60a')]+'\x20has\x20been\x20deleted!':''});})[_0x3a42d2('0x130a')](function(_0x54e5a9){const _0x2b21e7=_0x3a42d2;_0x389680[_0x2b21e7('0x52a')]({'title':_0x54e5a9[_0x2b21e7('0x13ee')]?_0x2b21e7('0x2168')+_0x54e5a9[_0x2b21e7('0x13ee')]+_0x2b21e7('0xbf6')+_0x54e5a9[_0x2b21e7('0x24a9')]:_0x2b21e7('0x1e44'),'msg':_0x54e5a9[_0x2b21e7('0x5a5')]?JSON[_0x2b21e7('0x258a')](_0x54e5a9[_0x2b21e7('0x5a5')]):_0x54e5a9[_0x2b21e7('0x1ff0')]()});})[_0x3a42d2('0x2874')](function(){const _0x58cb49=_0x3a42d2;_0x125f5d[_0x58cb49('0x1d9')](0x0);});},function(){const _0x309977=_0xdf93a6;console[_0x309977('0x1b2b')]('CANCEL');});}_0x125f5d[_0x5a5a09('0x1781')]=[],_0x125f5d[_0x5a5a09('0x2654')]=_0x234be5,_0x125f5d[_0x5a5a09('0x2802')]=_0x2b640d,_0x125f5d['deleteSelectedSubjects']=_0x4ab906;function _0x234be5(_0x5751b6,_0x70949f){const _0x251591=_0x5a5a09;_0x10ce17[_0x251591('0x1d4')]({'controller':_0x251591('0x25f4'),'controllerAs':'vm','templateUrl':_0x3e2bfd,'parent':angular['element'](_0x5780ec[_0x251591('0x18e5')]),'targetEvent':_0x5751b6,'clickOutsideToClose':!![],'locals':{'type':'subject','item':_0x70949f,'items':_0x125f5d[_0x251591('0x1ead')],'configuration':_0x125f5d['salesforceConfiguration'],'account':_0x125f5d[_0x251591('0x2769')],'license':null,'setting':null,'crudPermissions':_0x125f5d[_0x251591('0x1134')]}});}function _0x8b15ac(_0x291639){const _0x3b2267=_0x5a5a09;_0x2997c5[_0x3b2267('0x73e')]['delete']({'id':_0x291639['id']})[_0x3b2267('0xe53')]['then'](function(){const _0x521bf4=_0x3b2267;_0x2e3ca0()[_0x521bf4('0x3ec')](_0x125f5d[_0x521bf4('0x1ead')],{'id':_0x291639['id']}),_0x389680['success']({'title':'Subject\x20deleted!','msg':_0x521bf4('0x2795')});})[_0x3b2267('0x130a')](function(_0x3df307){const _0x9ddbaf=_0x3b2267;_0x389680[_0x9ddbaf('0x52a')]({'title':_0x3df307['status']?_0x9ddbaf('0x2168')+_0x3df307[_0x9ddbaf('0x13ee')]+_0x9ddbaf('0xbf6')+_0x3df307[_0x9ddbaf('0x24a9')]:_0x9ddbaf('0x1d23'),'msg':_0x3df307[_0x9ddbaf('0x5a5')]?JSON[_0x9ddbaf('0x258a')](_0x3df307[_0x9ddbaf('0x5a5')]):_0x3df307[_0x9ddbaf('0x1ff0')]()});});}function _0x2b640d(_0x5bd479,_0x457592){const _0xe228e4=_0x5a5a09,_0x200917=_0x10ce17['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20subject?')['htmlContent'](_0xe228e4('0x601')+_0xe228e4('0x1ee7'))[_0xe228e4('0x1040')](_0xe228e4('0x20d'))[_0xe228e4('0xe42')](_0x5bd479)['ok']('OK')[_0xe228e4('0x19fb')](_0xe228e4('0x16b8'));_0x10ce17[_0xe228e4('0x1d4')](_0x200917)[_0xe228e4('0x683')](function(){_0x8b15ac(_0x457592);},function(){console['log']('CANCEL');});}function _0x4ab906(_0x16b805){const _0x1a1531=_0x5a5a09,_0x374b86=_0x10ce17[_0x1a1531('0x1c6f')]()[_0x1a1531('0xf28')](_0x1a1531('0xad5'))[_0x1a1531('0x26e3')](_0x1a1531('0xed5')+_0x125f5d['selectedSubjects']['length']+_0x1a1531('0x93c')+_0x1a1531('0x1ee7'))[_0x1a1531('0x1040')](_0x1a1531('0x9fb'))[_0x1a1531('0xe42')](_0x16b805)['ok']('OK')[_0x1a1531('0x19fb')](_0x1a1531('0x16b8'));_0x10ce17['show'](_0x374b86)['then'](function(){const _0x47043e=_0x1a1531;_0x125f5d['selectedSubjects'][_0x47043e('0x1299')](function(_0x4d1e13){_0x8b15ac(_0x4d1e13);}),_0x125f5d[_0x47043e('0x1781')]=[];});}_0x125f5d[_0x5a5a09('0xcb1')]=[],_0x125f5d[_0x5a5a09('0x1094')]=_0xbfb7d0,_0x125f5d[_0x5a5a09('0x27b2')]=_0x426be0,_0x125f5d[_0x5a5a09('0x27df')]=_0x4848cf;function _0xbfb7d0(_0x510f30,_0x24ca89){const _0x59cf7=_0x5a5a09;_0x10ce17[_0x59cf7('0x1d4')]({'controller':'CreateOrEditSalesforceAccountItemDialogController','controllerAs':'vm','templateUrl':_0x3e2bfd,'parent':angular[_0x59cf7('0x1fcc')](_0x5780ec[_0x59cf7('0x18e5')]),'targetEvent':_0x510f30,'clickOutsideToClose':!![],'locals':{'type':_0x59cf7('0xd6b'),'item':_0x24ca89,'items':_0x125f5d[_0x59cf7('0x18f7')],'configuration':_0x125f5d['salesforceConfiguration'],'account':_0x125f5d[_0x59cf7('0x2769')],'license':null,'setting':null,'crudPermissions':_0x125f5d['crudPermissions']}});}function _0x5576e8(_0x4668b0){const _0x11fcbb=_0x5a5a09;_0x2997c5[_0x11fcbb('0x73e')][_0x11fcbb('0xd7e')]({'id':_0x4668b0['id']})[_0x11fcbb('0xe53')][_0x11fcbb('0x683')](function(){const _0x17ec64=_0x11fcbb;_0x2e3ca0()[_0x17ec64('0x3ec')](_0x125f5d['descriptions'],{'id':_0x4668b0['id']}),_0x389680[_0x17ec64('0x53')]({'title':_0x17ec64('0x1cf8'),'msg':_0x17ec64('0x21c7')});})[_0x11fcbb('0x130a')](function(_0x59c0ca){const _0x17996e=_0x11fcbb;_0x389680[_0x17996e('0x52a')]({'title':_0x59c0ca[_0x17996e('0x13ee')]?'API:'+_0x59c0ca['status']+_0x17996e('0xbf6')+_0x59c0ca[_0x17996e('0x24a9')]:_0x17996e('0x1d23'),'msg':_0x59c0ca[_0x17996e('0x5a5')]?JSON[_0x17996e('0x258a')](_0x59c0ca[_0x17996e('0x5a5')]):_0x59c0ca[_0x17996e('0x1ff0')]()});});}function _0x426be0(_0x31fae1,_0x352f84){const _0x43fbb2=_0x5a5a09,_0x4f471a=_0x10ce17[_0x43fbb2('0x1c6f')]()[_0x43fbb2('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20description?')[_0x43fbb2('0x26e3')]('Description'+_0x43fbb2('0x1ee7'))[_0x43fbb2('0x1040')](_0x43fbb2('0x221c'))[_0x43fbb2('0xe42')](_0x31fae1)['ok']('OK')[_0x43fbb2('0x19fb')](_0x43fbb2('0x16b8'));_0x10ce17['show'](_0x4f471a)['then'](function(){_0x5576e8(_0x352f84);},function(){const _0xcf6a79=_0x43fbb2;console[_0xcf6a79('0x1b2b')]('CANCEL');});}function _0x4848cf(_0x42ef91){const _0x28fbda=_0x5a5a09,_0x495804=_0x10ce17[_0x28fbda('0x1c6f')]()[_0x28fbda('0xf28')](_0x28fbda('0x1984'))[_0x28fbda('0x26e3')](_0x28fbda('0xed5')+_0x125f5d[_0x28fbda('0xcb1')][_0x28fbda('0x1564')]+'\x20selected'+_0x28fbda('0x1ee7'))['ariaLabel'](_0x28fbda('0x1859'))[_0x28fbda('0xe42')](_0x42ef91)['ok']('OK')[_0x28fbda('0x19fb')](_0x28fbda('0x16b8'));_0x10ce17[_0x28fbda('0x1d4')](_0x495804)['then'](function(){const _0xe6010d=_0x28fbda;_0x125f5d[_0xe6010d('0xcb1')][_0xe6010d('0x1299')](function(_0x19b4e9){_0x5576e8(_0x19b4e9);}),_0x125f5d[_0xe6010d('0xcb1')]=[];});}_0x125f5d[_0x5a5a09('0x310')]=[],_0x125f5d[_0x5a5a09('0x84f')]=_0x3cc632,_0x125f5d['deleteFieldConfirm']=_0x574c04,_0x125f5d[_0x5a5a09('0x204e')]=_0x570635;function _0x3cc632(_0x148fde,_0x4d0d65){const _0x53ab7c=_0x5a5a09;_0x10ce17[_0x53ab7c('0x1d4')]({'controller':_0x53ab7c('0x25f4'),'controllerAs':'vm','templateUrl':_0x3e2bfd,'parent':angular[_0x53ab7c('0x1fcc')](_0x5780ec['body']),'targetEvent':_0x148fde,'clickOutsideToClose':!![],'locals':{'type':_0x53ab7c('0x2013'),'item':_0x4d0d65,'items':_0x125f5d[_0x53ab7c('0x189a')],'configuration':_0x125f5d[_0x53ab7c('0x1821')],'account':_0x125f5d[_0x53ab7c('0x2769')],'license':null,'setting':null,'crudPermissions':_0x125f5d[_0x53ab7c('0x1134')]}});}function _0x813e20(_0x17ded3){const _0x6846d7=_0x5a5a09;_0x2997c5[_0x6846d7('0x73e')]['delete']({'id':_0x17ded3['id']})[_0x6846d7('0xe53')]['then'](function(){const _0x1c727b=_0x6846d7;_0x2e3ca0()[_0x1c727b('0x3ec')](_0x125f5d[_0x1c727b('0x189a')],{'id':_0x17ded3['id']}),_0x389680['success']({'title':_0x1c727b('0x1666'),'msg':_0x1c727b('0x1eda')});})['catch'](function(_0x3a54cc){const _0x1df340=_0x6846d7;_0x389680[_0x1df340('0x52a')]({'title':_0x3a54cc[_0x1df340('0x13ee')]?_0x1df340('0x2168')+_0x3a54cc['status']+_0x1df340('0xbf6')+_0x3a54cc[_0x1df340('0x24a9')]:_0x1df340('0x1d23'),'msg':_0x3a54cc[_0x1df340('0x5a5')]?JSON[_0x1df340('0x258a')](_0x3a54cc['data']):_0x3a54cc['toString']()});});}function _0x574c04(_0x1043a2,_0x1eb7b8){const _0x4a0d72=_0x5a5a09,_0x44714a=_0x10ce17[_0x4a0d72('0x1c6f')]()[_0x4a0d72('0xf28')](_0x4a0d72('0x16b5'))[_0x4a0d72('0x26e3')](_0x4a0d72('0x23b9')+'\x20will\x20be\x20deleted.')[_0x4a0d72('0x1040')]('delete\x20field')[_0x4a0d72('0xe42')](_0x1043a2)['ok']('OK')[_0x4a0d72('0x19fb')](_0x4a0d72('0x16b8'));_0x10ce17[_0x4a0d72('0x1d4')](_0x44714a)['then'](function(){_0x813e20(_0x1eb7b8);},function(){const _0x2bbb37=_0x4a0d72;console[_0x2bbb37('0x1b2b')](_0x2bbb37('0x16b8'));});}function _0x570635(_0x1d2d15){const _0x527b0b=_0x5a5a09,_0x499e2c=_0x10ce17[_0x527b0b('0x1c6f')]()[_0x527b0b('0xf28')](_0x527b0b('0x19b1'))[_0x527b0b('0x26e3')](''+_0x125f5d[_0x527b0b('0x310')][_0x527b0b('0x1564')]+'\x20selected'+_0x527b0b('0x1ee7'))[_0x527b0b('0x1040')](_0x527b0b('0x994'))[_0x527b0b('0xe42')](_0x1d2d15)['ok']('OK')[_0x527b0b('0x19fb')](_0x527b0b('0x16b8'));_0x10ce17[_0x527b0b('0x1d4')](_0x499e2c)['then'](function(){const _0x279a49=_0x527b0b;_0x125f5d[_0x279a49('0x310')][_0x279a49('0x1299')](function(_0x2b0c37){_0x813e20(_0x2b0c37);}),_0x125f5d[_0x279a49('0x310')]=[];});}}const _0x2beb2b=_0x3aca0c;_0x2cecc7[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1573'),'salesforceConfiguration',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x2cecc7(_0x2c606b,_0x1350f5,_0x27dcc3,_0x5f0d17,_0x2f98c6,_0x15a536,_0x4199be,_0x58dc2d,_0x354407,_0x246d07,_0x69623a,_0x9a5bce,_0x13e9d4,_0x3e6cd2){const _0x4c35ef=_0x189033,_0x1947a2=this;_0x1947a2['currentUser']=_0x69623a[_0x4c35ef('0x20b2')](),_0x1947a2['errors']=[],_0x1947a2['setting']=_0x13e9d4,_0x1947a2[_0x4c35ef('0xace')]=_0x9a5bce,_0x1947a2[_0x4c35ef('0x1134')]=_0x3e6cd2,_0x1947a2['hasModulePermissions']={},_0x1947a2['passwordPattern']=_0x1947a2['setting']&&_0x1947a2[_0x4c35ef('0x260a')][_0x4c35ef('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1947a2[_0x4c35ef('0xf28')]=_0x4c35ef('0x836'),_0x1947a2[_0x4c35ef('0x1821')]=angular[_0x4c35ef('0x1a86')](_0x354407),_0x1947a2[_0x4c35ef('0x1573')]=_0x58dc2d,_0x1947a2[_0x4c35ef('0x4')]=![];!_0x1947a2[_0x4c35ef('0x1821')]&&(_0x1947a2[_0x4c35ef('0x1821')]={'channel':_0x4c35ef('0xcf2'),'type':_0x4c35ef('0x1535'),'ticketType':_0x4c35ef('0x11be')},_0x1947a2[_0x4c35ef('0xf28')]='INTEGRATIONS.NEW_SALESFORCECONFIGURATION',_0x1947a2['newSalesforceConfiguration']=!![]);_0x1947a2[_0x4c35ef('0x105e')]=_0x42635d,_0x1947a2[_0x4c35ef('0x2275')]=_0x17d3dd,_0x1947a2[_0x4c35ef('0x7f5')]=_0x4a9734,_0x1947a2['getDateFromString']=_0xa4923f,_0x1947a2[_0x4c35ef('0xf82')]=_0x2d531a;function _0x42635d(){const _0x31fbb0=_0x4c35ef;_0x1947a2[_0x31fbb0('0x17f')]=[],_0x246d07[_0x31fbb0('0xf30')]['addConfiguration']({'id':_0x1350f5[_0x31fbb0('0x7f2')]['id']},_0x1947a2['salesforceConfiguration'])['$promise'][_0x31fbb0('0x683')](function(_0x217c35){const _0x5dedcc=_0x31fbb0;_0x1947a2[_0x5dedcc('0x1573')][_0x5dedcc('0x1167')](_0x217c35['toJSON']()),_0x4199be['success']({'title':'SalesforceConfiguration\x20properly\x20created','msg':_0x1947a2[_0x5dedcc('0x1821')][_0x5dedcc('0x60a')]?_0x1947a2[_0x5dedcc('0x1821')][_0x5dedcc('0x60a')]+_0x5dedcc('0x14b5'):''}),_0x2d531a(_0x217c35);})[_0x31fbb0('0x130a')](function(_0x1badcc){const _0x477a1c=_0x31fbb0;if(_0x1badcc[_0x477a1c('0x5a5')]&&_0x1badcc[_0x477a1c('0x5a5')][_0x477a1c('0x17f')]&&_0x1badcc[_0x477a1c('0x5a5')]['errors'][_0x477a1c('0x1564')]){_0x1947a2[_0x477a1c('0x17f')]=_0x1badcc['data'][_0x477a1c('0x17f')]||[{'message':_0x1badcc[_0x477a1c('0x1ff0')](),'type':_0x477a1c('0x1c27')}];for(let _0xfc18d8=0x0;_0xfc18d8<_0x1badcc['data'][_0x477a1c('0x17f')][_0x477a1c('0x1564')];_0xfc18d8+=0x1){_0x4199be[_0x477a1c('0x52a')]({'title':_0x1badcc['data'][_0x477a1c('0x17f')][_0xfc18d8][_0x477a1c('0xcf0')],'msg':_0x1badcc['data'][_0x477a1c('0x17f')][_0xfc18d8][_0x477a1c('0x8c2')]});}}else _0x4199be['error']({'title':_0x1badcc['status']?'API:'+_0x1badcc[_0x477a1c('0x13ee')]+_0x477a1c('0xbf6')+_0x1badcc[_0x477a1c('0x24a9')]:'api.intSalesforceConfiguration.save','msg':_0x1badcc[_0x477a1c('0x5a5')]?JSON[_0x477a1c('0x258a')](_0x1badcc[_0x477a1c('0x5a5')][_0x477a1c('0x8c2')]):_0x1badcc[_0x477a1c('0x1ff0')]()});});}function _0x17d3dd(){const _0x174d37=_0x4c35ef;_0x1947a2[_0x174d37('0x17f')]=[],_0x246d07[_0x174d37('0x161f')][_0x174d37('0x2480')]({'id':_0x1947a2[_0x174d37('0x1821')]['id']},_0x1947a2[_0x174d37('0x1821')])[_0x174d37('0xe53')][_0x174d37('0x683')](function(_0x31bcb8){const _0x57dd14=_0x174d37,_0x3a9d4b=_0x2e3ca0()[_0x57dd14('0x1c07')](_0x1947a2[_0x57dd14('0x1573')],{'id':_0x31bcb8['id']});_0x3a9d4b&&_0x2e3ca0()[_0x57dd14('0xf22')](_0x3a9d4b,_0x2e3ca0()['pick'](_0x31bcb8[_0x57dd14('0x24e1')](),_0x2e3ca0()[_0x57dd14('0x55e')](_0x3a9d4b))),_0x4199be[_0x57dd14('0x53')]({'title':_0x57dd14('0xa7c'),'msg':_0x1947a2['salesforceConfiguration'][_0x57dd14('0x60a')]?_0x1947a2['salesforceConfiguration']['name']+_0x57dd14('0xf59'):''}),_0x2d531a(_0x31bcb8);})[_0x174d37('0x130a')](function(_0xaeb31e){const _0x57dc49=_0x174d37;if(_0xaeb31e['data']&&_0xaeb31e[_0x57dc49('0x5a5')][_0x57dc49('0x17f')]&&_0xaeb31e[_0x57dc49('0x5a5')][_0x57dc49('0x17f')][_0x57dc49('0x1564')]){_0x1947a2[_0x57dc49('0x17f')]=_0xaeb31e[_0x57dc49('0x5a5')]['errors']||[{'message':_0xaeb31e[_0x57dc49('0x1ff0')](),'type':_0x57dc49('0x18e4')}];for(let _0x41b6a3=0x0;_0x41b6a3<_0xaeb31e[_0x57dc49('0x5a5')][_0x57dc49('0x17f')][_0x57dc49('0x1564')];_0x41b6a3++){_0x4199be[_0x57dc49('0x52a')]({'title':_0xaeb31e['data'][_0x57dc49('0x17f')][_0x41b6a3]['type'],'msg':_0xaeb31e['data']['errors'][_0x41b6a3][_0x57dc49('0x8c2')]});}}else _0x4199be['error']({'title':_0xaeb31e[_0x57dc49('0x13ee')]?_0x57dc49('0x2168')+_0xaeb31e[_0x57dc49('0x13ee')]+'\x20-\x20'+_0xaeb31e[_0x57dc49('0x24a9')]:_0x57dc49('0x18e4'),'msg':_0xaeb31e[_0x57dc49('0x5a5')]?JSON['stringify'](_0xaeb31e[_0x57dc49('0x5a5')][_0x57dc49('0x8c2')]):_0xaeb31e[_0x57dc49('0x1ff0')]()});});}function _0x4a9734(_0x2c05dd){const _0xc4e309=_0x4c35ef;_0x1947a2[_0xc4e309('0x17f')]=[];const _0x291913=_0x5f0d17['confirm']()['title'](_0xc4e309('0x4d'))[_0xc4e309('0xa6a')](_0xc4e309('0x2002'))[_0xc4e309('0x1040')](_0xc4e309('0x5c'))['ok']('Delete')[_0xc4e309('0x19fb')](_0xc4e309('0x253a'))['targetEvent'](_0x2c05dd);_0x5f0d17[_0xc4e309('0x1d4')](_0x291913)[_0xc4e309('0x683')](function(){const _0x2b3076=_0xc4e309;_0x246d07[_0x2b3076('0x161f')][_0x2b3076('0xd7e')]({'id':_0x1947a2[_0x2b3076('0x1821')]['id']})[_0x2b3076('0xe53')]['then'](function(){const _0x5c76a=_0x2b3076;_0x2e3ca0()['remove'](_0x1947a2[_0x5c76a('0x1573')],{'id':_0x1947a2[_0x5c76a('0x1821')]['id']}),_0x4199be['success']({'title':'SalesforceConfiguration\x20properly\x20deleted!','msg':(_0x1947a2[_0x5c76a('0x1821')][_0x5c76a('0x60a')]||_0x5c76a('0x1821'))+_0x5c76a('0x194d')}),_0x2d531a(_0x1947a2[_0x5c76a('0x1821')]);})[_0x2b3076('0x130a')](function(_0x201bbd){const _0x31ccc3=_0x2b3076;if(_0x201bbd[_0x31ccc3('0x5a5')]&&_0x201bbd[_0x31ccc3('0x5a5')][_0x31ccc3('0x17f')]&&_0x201bbd[_0x31ccc3('0x5a5')][_0x31ccc3('0x17f')]['length']){_0x1947a2[_0x31ccc3('0x17f')]=_0x201bbd['data'][_0x31ccc3('0x17f')]||[{'message':_0x201bbd['toString'](),'type':'api.intSalesforceConfiguration.delete'}];for(let _0x1813a6=0x0;_0x1813a6<_0x201bbd['data']['errors'][_0x31ccc3('0x1564')];_0x1813a6++){_0x4199be[_0x31ccc3('0x52a')]({'title':_0x201bbd['data'][_0x31ccc3('0x17f')][_0x1813a6][_0x31ccc3('0xcf0')],'msg':_0x201bbd[_0x31ccc3('0x5a5')][_0x31ccc3('0x17f')][_0x1813a6][_0x31ccc3('0x8c2')]});}}else _0x4199be[_0x31ccc3('0x52a')]({'title':_0x201bbd[_0x31ccc3('0x13ee')]?_0x31ccc3('0x2168')+_0x201bbd['status']+'\x20-\x20'+_0x201bbd[_0x31ccc3('0x24a9')]:'api.intSalesforceConfiguration.delete','msg':_0x201bbd[_0x31ccc3('0x5a5')]?JSON['stringify'](_0x201bbd[_0x31ccc3('0x5a5')][_0x31ccc3('0x8c2')]):_0x201bbd[_0x31ccc3('0x8c2')]||_0x201bbd[_0x31ccc3('0x1ff0')]()});});},function(){});}function _0xa4923f(_0x178c5f){return _0x178c5f===null?undefined:new Date(_0x178c5f);}function _0x2d531a(_0x50e593){const _0x927602=_0x4c35ef;_0x5f0d17[_0x927602('0x1715')](_0x50e593);}}const _0x2dc897=_0x2cecc7;_0x525ff7[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x208d'),_0x189033('0x1996'),_0x189033('0x23ef'),_0x189033('0x1d2f'),_0x189033('0xcf0'),'api','Auth',_0x189033('0x1134')];function _0x525ff7(_0x10a11e,_0x4c83ba,_0x386b49,_0x4ebff6,_0x26324f,_0xac378c,_0x5e261f,_0x418a3d,_0x1288d9,_0x1e15cb,_0xbd2d1a,_0x186722,_0x124604){const _0x441e2e=_0x189033,_0x53924f=this;_0x53924f[_0x441e2e('0x11ed')]=_0x186722[_0x441e2e('0x20b2')](),_0x53924f[_0x441e2e('0x17f')]=[],_0x53924f[_0x441e2e('0xf28')]=_0x441e2e('0x176c')+_0x2e3ca0()['toUpper'](_0x1e15cb),_0x53924f[_0x441e2e('0x23ef')]=angular[_0x441e2e('0x1a86')](_0x418a3d),_0x53924f[_0x441e2e('0x1996')]=_0x5e261f,_0x53924f[_0x441e2e('0xcf0')]=_0x1e15cb,_0x53924f[_0x441e2e('0x1134')]=_0x124604,_0x53924f[_0x441e2e('0x3d2')]=![];!_0x53924f['item']&&(_0x53924f[_0x441e2e('0x23ef')]={'type':'string'},_0x53924f[_0x441e2e('0x23ef')][_0x2e3ca0()[_0x441e2e('0x21ab')](_0x1e15cb)+'Id']=_0xac378c['id'],_0x53924f[_0x441e2e('0xf28')]=_0x441e2e('0x22de')+_0x2e3ca0()['toUpper'](_0x1e15cb),_0x53924f[_0x441e2e('0x3d2')]=!![]);_0x53924f[_0x441e2e('0x2591')]=_0x5cd93d,_0x53924f[_0x441e2e('0x2716')]=_0x2db2c7,_0x53924f[_0x441e2e('0x6b8')]=_0x5451af,_0x53924f[_0x441e2e('0x18a')]=_0x28a281,_0x53924f[_0x441e2e('0xf82')]=_0x107fc3,_0xbd2d1a[_0x441e2e('0x26e0')][_0x441e2e('0x1e6e')]({'nolimit':!![]})[_0x441e2e('0xe53')][_0x441e2e('0x683')](function(_0x56f500){const _0x5a2001=_0x441e2e;return _0x53924f[_0x5a2001('0x220b')]=_0x56f500[_0x5a2001('0xf5d')]?_0x56f500[_0x5a2001('0xf5d')]:[],_0xbd2d1a[_0x5a2001('0xf53')]['describe']()[_0x5a2001('0xe53')];})[_0x441e2e('0x683')](function(_0x30b569){const _0x4de7fd=_0x441e2e;return _0x53924f[_0x4de7fd('0x20c1')]=_0x2e3ca0()[_0x4de7fd('0x2829')](_0x2e3ca0()[_0x4de7fd('0x55e')](_0x30b569),[_0x4de7fd('0xe53'),'$resolved',_0x4de7fd('0x1a4'),'updatedAt',_0x4de7fd('0x1d58')]),_0x53924f[_0x4de7fd('0x20c1')]['push'](_0x4de7fd('0x1e93')),_0xbd2d1a['voiceDialReport'][_0x4de7fd('0x2267')]()[_0x4de7fd('0xe53')];})['then'](function(_0x46303b){const _0x3ccadd=_0x441e2e;_0x53924f['voiceDialReportColumns']=_0x2e3ca0()['difference'](_0x2e3ca0()[_0x3ccadd('0x55e')](_0x46303b),[_0x3ccadd('0xe53'),_0x3ccadd('0x1980'),'createdAt',_0x3ccadd('0x2000'),_0x3ccadd('0x1d58')]),_0x53924f[_0x3ccadd('0x1d6a')][_0x3ccadd('0x1fd0')](_0x3ccadd('0x1e93'));})[_0x441e2e('0x130a')](function(_0x1b95d4){const _0x4c57a0=_0x441e2e;_0x26324f[_0x4c57a0('0x52a')]({'title':_0x1b95d4[_0x4c57a0('0x13ee')]?_0x4c57a0('0x2168')+_0x1b95d4[_0x4c57a0('0x13ee')]+'\x20-\x20'+_0x1b95d4[_0x4c57a0('0x24a9')]:'SYSTEM:GETVARIABLES','msg':_0x1b95d4[_0x4c57a0('0x5a5')]?JSON[_0x4c57a0('0x258a')](_0x1b95d4[_0x4c57a0('0x5a5')]):_0x1b95d4[_0x4c57a0('0x1ff0')]()});}),_0xbd2d1a['intSalesforceAccount'][_0x441e2e('0x298')]({'id':_0x1288d9['id'],'ticketType':_0xac378c['ticketType']?_0xac378c[_0x441e2e('0x20c9')]:undefined})[_0x441e2e('0xe53')][_0x441e2e('0x683')](function(_0x38f969){const _0xae4949=_0x441e2e;_0x53924f[_0xae4949('0xd32')]=!![],_0x53924f[_0xae4949('0x189a')]=_0x38f969['rows']?_0x38f969[_0xae4949('0xf5d')]:[],_0x53924f['item'][_0xae4949('0x280')]&&(_0x53924f[_0xae4949('0x7f8')]=_0x2e3ca0()[_0xae4949('0x1c07')](_0x53924f[_0xae4949('0x189a')],{'id':_0x53924f[_0xae4949('0x23ef')]['idField']}));})['catch'](function(_0x13013b){const _0x2798f8=_0x441e2e;_0x53924f[_0x2798f8('0xd32')]=![],console[_0x2798f8('0x52a')](_0x13013b);});function _0x5cd93d(){const _0x4ba8a6=_0x441e2e;_0x53924f[_0x4ba8a6('0x17f')]=[],_0x53924f['customField']&&(_0x53924f[_0x4ba8a6('0x23ef')]['idField']=_0x53924f[_0x4ba8a6('0x7f8')]['id'],_0x53924f[_0x4ba8a6('0x23ef')]['nameField']=_0x53924f['customField'][_0x4ba8a6('0x60a')],_0x53924f[_0x4ba8a6('0x23ef')][_0x4ba8a6('0x7f8')]=_0x53924f['customField'][_0x4ba8a6('0xbf0')]),_0xbd2d1a['intSalesforceField'][_0x4ba8a6('0xb0a')](_0x53924f[_0x4ba8a6('0x23ef')])[_0x4ba8a6('0xe53')][_0x4ba8a6('0x683')](function(_0x100f2c){const _0x13997a=_0x4ba8a6;_0x53924f[_0x13997a('0x1996')][_0x13997a('0x1167')](_0x100f2c),_0x26324f['success']({'title':_0x2e3ca0()[_0x13997a('0x21ab')](_0x1e15cb)+_0x13997a('0x282a'),'msg':_0x2e3ca0()[_0x13997a('0x21ab')](_0x1e15cb)+'\x20has\x20been\x20created!'}),_0x107fc3();})[_0x4ba8a6('0x130a')](function(_0x3340cd){const _0x23aefd=_0x4ba8a6;console[_0x23aefd('0x52a')](_0x3340cd),_0x53924f[_0x23aefd('0x17f')]=_0x3340cd[_0x23aefd('0x5a5')][_0x23aefd('0x17f')]||[{'message':_0x3340cd[_0x23aefd('0x1ff0')](),'type':_0x23aefd('0x1928')}];});}function _0x2db2c7(){const _0x21dc6e=_0x441e2e;_0x53924f[_0x21dc6e('0x17f')]=[],_0x53924f[_0x21dc6e('0x7f8')]&&(_0x53924f[_0x21dc6e('0x23ef')][_0x21dc6e('0x280')]=_0x53924f[_0x21dc6e('0x7f8')]['id'],_0x53924f[_0x21dc6e('0x23ef')]['nameField']=_0x53924f[_0x21dc6e('0x7f8')][_0x21dc6e('0x60a')],_0x53924f[_0x21dc6e('0x23ef')][_0x21dc6e('0x7f8')]=_0x53924f['customField'][_0x21dc6e('0xbf0')]),_0xbd2d1a['intSalesforceField']['update']({'id':_0x53924f[_0x21dc6e('0x23ef')]['id']},_0x53924f['item'])['$promise'][_0x21dc6e('0x683')](function(_0x5e0fec){const _0x26158e=_0x21dc6e,_0x76d3ee=_0x2e3ca0()[_0x26158e('0x1c07')](_0x53924f[_0x26158e('0x1996')],{'id':_0x5e0fec['id']});_0x76d3ee&&_0x2e3ca0()[_0x26158e('0xf22')](_0x76d3ee,_0x5e0fec),_0x26324f[_0x26158e('0x53')]({'title':_0x2e3ca0()[_0x26158e('0x21ab')](_0x1e15cb)+_0x26158e('0x15dd'),'msg':_0x2e3ca0()[_0x26158e('0x21ab')](_0x1e15cb)+'\x20has\x20been\x20saved!'}),_0x107fc3();})[_0x21dc6e('0x130a')](function(_0x30d5b1){const _0x25b5f7=_0x21dc6e;console[_0x25b5f7('0x52a')](_0x30d5b1),_0x53924f[_0x25b5f7('0x17f')]=_0x30d5b1[_0x25b5f7('0x5a5')]['errors']||[{'message':_0x30d5b1[_0x25b5f7('0x1ff0')](),'type':'api.intItem.update'}];});}function _0x5451af(_0x4e720c){const _0x5eeff3=_0x441e2e;_0x53924f[_0x5eeff3('0x17f')]=[];const _0x2d617c=_0x4ebff6[_0x5eeff3('0x1c6f')]()[_0x5eeff3('0xf28')](_0x5eeff3('0x4d'))[_0x5eeff3('0xa6a')](_0x5eeff3('0x3fc')+_0x1e15cb+_0x5eeff3('0x1ee7'))[_0x5eeff3('0x1040')](_0x5eeff3('0x609')+_0x2e3ca0()['capitalize'](_0x1e15cb))['ok']('Delete')[_0x5eeff3('0x19fb')](_0x5eeff3('0x253a'))['targetEvent'](_0x4e720c);_0x4ebff6[_0x5eeff3('0x1d4')](_0x2d617c)[_0x5eeff3('0x683')](function(){const _0x144a3e=_0x5eeff3;_0xbd2d1a['intSalesforceField']['delete']({'id':_0x53924f['item']['id']})[_0x144a3e('0xe53')][_0x144a3e('0x683')](function(){const _0x212c29=_0x144a3e;_0x2e3ca0()['remove'](_0x53924f[_0x212c29('0x1996')],{'id':_0x53924f[_0x212c29('0x23ef')]['id']}),_0x26324f[_0x212c29('0x53')]({'title':_0x2e3ca0()['capitalize'](_0x1e15cb)+_0x212c29('0x27d7'),'msg':_0x2e3ca0()['capitalize'](_0x1e15cb)+_0x212c29('0x194d')}),_0x107fc3();})[_0x144a3e('0x130a')](function(_0x5b778c){const _0x33e606=_0x144a3e;console[_0x33e606('0x52a')](_0x5b778c),_0x53924f[_0x33e606('0x17f')]=_0x5b778c[_0x33e606('0x5a5')][_0x33e606('0x17f')]||[{'message':_0x5b778c[_0x33e606('0x1ff0')](),'type':_0x33e606('0x70c')}];});},function(){});}function _0x28a281(){const _0x46091d=_0x441e2e;return _0x53924f[_0x46091d('0x23ef')]['variableName']!==undefined?_0x53924f['item'][_0x46091d('0x113b')]:_0x46091d('0xbbf');}function _0x107fc3(){const _0x5b65ac=_0x441e2e;_0x4ebff6[_0x5b65ac('0x1715')]();}}const _0x3a66fe=_0x525ff7;_0x35c8fa[_0x189033('0x14be')]=[_0x189033('0x938'),'$location','$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),'toasty',_0x189033('0xba1'),'salesforceAccount',_0x189033('0x22df')];function _0x35c8fa(_0xebabd8,_0x5acdb3,_0x46fd32,_0x52189f,_0x195421,_0x33448a,_0x1d639f,_0x1ea419,_0x5605b4,_0x1453bc,_0xbc6de9,_0x45078e){const _0x330d8e=_0x189033,_0x24a489=this;_0x24a489[_0x330d8e('0x11ed')]=_0x1453bc[_0x330d8e('0x20b2')](),_0x24a489[_0x330d8e('0xace')]=_0x33448a,_0x24a489[_0x330d8e('0x260a')]=_0x1d639f,_0x24a489[_0x330d8e('0x19b2')]=_0x24a489[_0x330d8e('0x260a')][_0x330d8e('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x24a489[_0x330d8e('0x1224')]=_0x5acdb3['protocol']()+_0x330d8e('0x20de')+_0x5acdb3[_0x330d8e('0x19ac')](),_0x24a489['salesforceAccount']=_0xbc6de9||_0xebabd8[_0x330d8e('0x7f2')]['salesforceAccount']||{},_0x24a489['userProfileSection']=_0x45078e&&_0x45078e[_0x330d8e('0x50d')]==0x1?_0x45078e['rows'][0x0]:null,_0x24a489[_0x330d8e('0x1134')]=_0x1453bc[_0x330d8e('0x142a')](_0x24a489[_0x330d8e('0x22df')]?_0x24a489[_0x330d8e('0x22df')][_0x330d8e('0x1134')]:null),_0x24a489[_0x330d8e('0x258d')]={},_0x24a489[_0x330d8e('0x517')]=_0xebabd8[_0x330d8e('0x7f2')][_0x330d8e('0x1904')]||0x0,_0x24a489[_0x330d8e('0x2430')]=_0x5605b4['info'],_0x24a489[_0x330d8e('0x1d52')]=_0x2fdc28,_0x24a489[_0x330d8e('0x15b8')]=_0x59e80b;function _0x2fdc28(){const _0x2f1dfa=_0x330d8e;_0xebabd8['go'](_0x2f1dfa('0x1eb6'),{},{'reload':'app.integrations.salesforceAccounts'});}function _0x59e80b(){const _0x4e7bb4=_0x330d8e;_0x1ea419['intSalesforceAccount']['update']({'id':_0x24a489['salesforceAccount']['id']},_0x24a489[_0x4e7bb4('0x2769')])[_0x4e7bb4('0xe53')][_0x4e7bb4('0x683')](function(){const _0x33d496=_0x4e7bb4;_0x5605b4[_0x33d496('0x53')]({'title':_0x33d496('0x1916'),'msg':_0x24a489['salesforceAccount'][_0x33d496('0x60a')]?_0x24a489['salesforceAccount'][_0x33d496('0x60a')]+_0x33d496('0x96c'):''});})[_0x4e7bb4('0x130a')](function(_0x4f8446){const _0x3e5b1a=_0x4e7bb4;_0x5605b4[_0x3e5b1a('0x52a')]({'title':_0x4f8446[_0x3e5b1a('0x13ee')]?_0x3e5b1a('0x2168')+_0x4f8446['status']+_0x3e5b1a('0xbf6')+_0x4f8446['statusText']:_0x3e5b1a('0x1c19'),'msg':_0x4f8446[_0x3e5b1a('0x5a5')]?JSON[_0x3e5b1a('0x258a')](_0x4f8446[_0x3e5b1a('0x5a5')]):_0x4f8446[_0x3e5b1a('0x1ff0')]()});});}}const _0x520e38=_0x35c8fa,_0x580c19=_0x180212['p']+_0x189033('0x5ec');_0x975923[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$window','$state','$mdSidenav','$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0xcdc'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),'toasty','Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x975923(_0xaee290,_0x6c3000,_0x36332c,_0xad2daf,_0x1c60a2,_0x2ec9fc,_0x4fd433,_0x26aeb2,_0x218f46,_0xa64d1c,_0x58e089,_0x1c4543,_0xcb0725,_0x59b1d6,_0x1b9ab3,_0x4ae058,_0x2ed621){const _0x3cd334=_0x189033,_0x30c9de=this;_0x30c9de[_0x3cd334('0xace')]=_0x4ae058,_0x30c9de[_0x3cd334('0x260a')]=_0x2ed621,_0x30c9de[_0x3cd334('0x11ed')]=_0x1b9ab3['getCurrentUser'](),_0x30c9de[_0x3cd334('0xcdc')]=_0x218f46||{'count':0x0,'rows':[]},_0x30c9de[_0x3cd334('0x2a')]=_0xa64d1c,_0x30c9de[_0x3cd334('0x22df')]=_0x58e089&&_0x58e089[_0x3cd334('0x50d')]==0x1?_0x58e089[_0x3cd334('0xf5d')][0x0]:null,_0x30c9de[_0x3cd334('0x1134')]=_0x1b9ab3['parseCrudPermissions'](_0x30c9de['userProfileSection']?_0x30c9de['userProfileSection'][_0x3cd334('0x1134')]:null),_0x30c9de[_0x3cd334('0x5c4')]=_0x3cd334('0xcdc'),_0x30c9de[_0x3cd334('0x247')]='',_0x30c9de[_0x3cd334('0x1ce2')]=null,_0x30c9de[_0x3cd334('0x1b4e')]=[],_0x30c9de[_0x3cd334('0x23a2')]={'fields':_0x3cd334('0x244c'),'limit':0xa,'page':0x1},_0x30c9de['arraytype']=_0x2e3ca0()[_0x3cd334('0x24db')]([{'option':_0x3cd334('0x1729'),'value':_0x3cd334('0xd46')},{'option':_0x3cd334('0x24ac'),'value':_0x3cd334('0xf78')}],function(_0x21c6ca){const _0x2b7a37=_0x3cd334;return _0x2e3ca0()[_0x2b7a37('0x1725')](_0x21c6ca[_0x2b7a37('0x1c6b')],new RegExp('\x27','g'),'');}),_0x30c9de['editstate']=_0x7bcf72,_0x30c9de['testtestintegrationaccount']=_0x51c54b,_0x30c9de[_0x3cd334('0x194f')]=_0x5e8073,_0x30c9de[_0x3cd334('0x53')]=_0x5b8009,_0x30c9de[_0x3cd334('0x2178')]=_0x46f9d6,_0x30c9de[_0x3cd334('0x275c')]=_0xe6d42,_0x30c9de['deleteSalesforceAccount']=_0x529c7a,_0x30c9de[_0x3cd334('0x209b')]=_0x23c7f4,_0x30c9de['deleteSelectedSalesforceAccounts']=_0x379d7b,_0x30c9de[_0x3cd334('0x1296')]=_0xd21742,_0x30c9de[_0x3cd334('0x1d9f')]=_0x3313c3;function _0x7bcf72(_0x120e04){const _0x33ac74=_0x3cd334;_0x36332c['go'](_0x33ac74('0x1791'),{'id':_0x120e04['id'],'salesforceAccount':_0x120e04,'crudPermissions':_0x30c9de[_0x33ac74('0x1134')]});}function _0x51c54b(_0x40f19a){const _0x144b13=_0x3cd334;return _0x1c4543[_0x144b13('0xf30')][_0x144b13('0x298')]({'id':_0x40f19a['id'],'test':!![]})[_0x144b13('0xe53')][_0x144b13('0x683')](function(){const _0x34ebe8=_0x144b13;_0x59b1d6['success']({'title':_0x34ebe8('0x1b8c'),'msg':_0x34ebe8('0x1c6d')});})[_0x144b13('0x130a')](function(_0x110c0f){const _0x5661c3=_0x144b13;_0x59b1d6[_0x5661c3('0x52a')]({'title':_0x5661c3('0x1b8c'),'msg':_0x110c0f[_0x5661c3('0x5a5')]?_0x110c0f['data'][_0x5661c3('0x8c2')]?_0x110c0f[_0x5661c3('0x5a5')][_0x5661c3('0x8c2')]:JSON[_0x5661c3('0x258a')](_0x110c0f[_0x5661c3('0x5a5')]):_0x110c0f[_0x5661c3('0x1ff0')]()});});}function _0x5e8073(_0x1140be,_0x18dd9f){const _0x44b09f=_0x3cd334,_0x4bfc16=_0x1c60a2[_0x44b09f('0x1c6f')]()[_0x44b09f('0xf28')](_0x44b09f('0x1b01')+_0x2e3ca0()['startCase']('salesforceAccount')+'?')[_0x44b09f('0x26e3')](_0x44b09f('0xed5')+(_0x1140be[_0x44b09f('0x60a')]||_0x44b09f('0x2769'))+_0x44b09f('0x20f1')+_0x44b09f('0x1ee7'))[_0x44b09f('0x1040')](_0x44b09f('0x1078'))[_0x44b09f('0xe42')](_0x18dd9f)['ok']('OK')[_0x44b09f('0x19fb')](_0x44b09f('0x16b8'));_0x1c60a2[_0x44b09f('0x1d4')](_0x4bfc16)[_0x44b09f('0x683')](function(){_0x529c7a(_0x1140be);},function(){const _0x2cf7e2=_0x44b09f;console['log'](_0x2cf7e2('0x16b8'));});}let _0x49ea32=!![],_0x83b9cf=0x1;_0xaee290[_0x3cd334('0x186d')](_0x3cd334('0x1e1d'),function(_0x542a17,_0x50513d){const _0x270677=_0x3cd334;_0x49ea32?_0x4fd433(function(){_0x49ea32=![];}):(!_0x50513d&&(_0x83b9cf=_0x30c9de[_0x270677('0x23a2')][_0x270677('0xdf8')]),_0x542a17!==_0x50513d&&(_0x30c9de[_0x270677('0x23a2')][_0x270677('0xdf8')]=0x1),!_0x542a17&&(_0x30c9de[_0x270677('0x23a2')][_0x270677('0xdf8')]=_0x83b9cf),_0x30c9de[_0x270677('0x2178')]());});function _0x5b8009(_0x19fa6e){const _0x39c282=_0x3cd334;_0x30c9de[_0x39c282('0xcdc')]=_0x19fa6e||{'count':0x0,'rows':[]};}function _0x46f9d6(){const _0xe29c88=_0x3cd334;_0x30c9de[_0xe29c88('0x23a2')][_0xe29c88('0x1cc8')]=(_0x30c9de['query'][_0xe29c88('0xdf8')]-0x1)*_0x30c9de[_0xe29c88('0x23a2')][_0xe29c88('0x6f0')],_0x1b9ab3['hasRole']('admin')?_0x30c9de[_0xe29c88('0x1883')]=_0x1c4543[_0xe29c88('0xf30')][_0xe29c88('0x1e6e')](_0x30c9de[_0xe29c88('0x23a2')],_0x5b8009)['$promise']:(_0x30c9de[_0xe29c88('0x23a2')]['id']=_0x30c9de[_0xe29c88('0x2a')]['id'],_0x30c9de[_0xe29c88('0x23a2')][_0xe29c88('0x1aa')]=_0xe29c88('0x613'),_0x30c9de[_0xe29c88('0x1883')]=_0x1c4543[_0xe29c88('0x2a')]['getResources'](_0x30c9de[_0xe29c88('0x23a2')],_0x5b8009)[_0xe29c88('0xe53')]);}function _0xe6d42(_0x59d2ef,_0x566379){const _0x25928b=_0x3cd334;_0x1c60a2[_0x25928b('0x1d4')]({'controller':_0x25928b('0x17d0'),'controllerAs':'vm','templateUrl':_0x580c19,'parent':angular[_0x25928b('0x1fcc')](_0x2ec9fc[_0x25928b('0x18e5')]),'targetEvent':_0x59d2ef,'clickOutsideToClose':!![],'locals':{'salesforceAccount':_0x566379,'salesforceAccounts':_0x30c9de[_0x25928b('0xcdc')][_0x25928b('0xf5d')],'license':_0x30c9de[_0x25928b('0xace')],'setting':_0x30c9de['setting'],'crudPermissions':_0x30c9de[_0x25928b('0x1134')]}});}function _0x529c7a(_0x2b25ad){const _0x557a72=_0x3cd334;_0x1c4543['intSalesforceAccount'][_0x557a72('0xd7e')]({'id':_0x2b25ad['id']})[_0x557a72('0xe53')][_0x557a72('0x683')](function(){const _0x5349a8=_0x557a72;_0x2e3ca0()['remove'](_0x30c9de[_0x5349a8('0xcdc')][_0x5349a8('0xf5d')],{'id':_0x2b25ad['id']}),_0x30c9de[_0x5349a8('0xcdc')]['count']-=0x1,!_0x30c9de[_0x5349a8('0xcdc')][_0x5349a8('0xf5d')][_0x5349a8('0x1564')]&&_0x30c9de['getSalesforceAccounts'](),_0x59b1d6[_0x5349a8('0x53')]({'title':_0x2e3ca0()[_0x5349a8('0x1e03')](_0x5349a8('0xb71'))+'\x20deleted!','msg':_0x2b25ad[_0x5349a8('0x60a')]?_0x2b25ad[_0x5349a8('0x60a')]+_0x5349a8('0x194d'):''});})[_0x557a72('0x130a')](function(_0x82aae8){const _0x1b14a2=_0x557a72;if(_0x82aae8[_0x1b14a2('0x5a5')]&&_0x82aae8[_0x1b14a2('0x5a5')][_0x1b14a2('0x17f')]&&_0x82aae8[_0x1b14a2('0x5a5')]['errors']['length']){_0x30c9de[_0x1b14a2('0x17f')]=_0x82aae8['data'][_0x1b14a2('0x17f')]||[{'message':_0x82aae8[_0x1b14a2('0x1ff0')](),'type':_0x1b14a2('0x486')}];for(let _0x5993c5=0x0;_0x5993c5<_0x82aae8[_0x1b14a2('0x5a5')][_0x1b14a2('0x17f')]['length'];_0x5993c5++){_0x59b1d6[_0x1b14a2('0x52a')]({'title':_0x82aae8[_0x1b14a2('0x5a5')][_0x1b14a2('0x17f')][_0x5993c5][_0x1b14a2('0xcf0')],'msg':_0x82aae8[_0x1b14a2('0x5a5')][_0x1b14a2('0x17f')][_0x5993c5]['message']});}}else _0x59b1d6['error']({'title':_0x82aae8[_0x1b14a2('0x13ee')]?_0x1b14a2('0x2168')+_0x82aae8[_0x1b14a2('0x13ee')]+_0x1b14a2('0xbf6')+_0x82aae8[_0x1b14a2('0x24a9')]:_0x1b14a2('0x486'),'msg':_0x82aae8['data']?JSON['stringify'](_0x82aae8[_0x1b14a2('0x5a5')]['message']):_0x82aae8[_0x1b14a2('0x8c2')]||_0x82aae8[_0x1b14a2('0x1ff0')]()});});}function _0x23c7f4(){const _0x3996b6=_0x3cd334,_0x140a87=angular[_0x3996b6('0x1a86')](_0x30c9de['selectedSalesforceAccounts']);return _0x30c9de[_0x3996b6('0x1b4e')]=[],_0x140a87;}function _0x379d7b(_0x51006f){const _0x40022d=_0x3cd334,_0x5146ee=_0x1c60a2['confirm']()[_0x40022d('0xf28')](_0x40022d('0x2658'))[_0x40022d('0x26e3')](_0x40022d('0xed5')+_0x30c9de[_0x40022d('0x1b4e')][_0x40022d('0x1564')]+_0x40022d('0x93c')+_0x40022d('0x1ee7'))[_0x40022d('0x1040')](_0x40022d('0x134'))[_0x40022d('0xe42')](_0x51006f)['ok']('OK')[_0x40022d('0x19fb')](_0x40022d('0x16b8'));_0x1c60a2['show'](_0x5146ee)[_0x40022d('0x683')](function(){const _0x5de3f1=_0x40022d;_0x30c9de[_0x5de3f1('0x1b4e')]['forEach'](function(_0xcd2846){_0x529c7a(_0xcd2846);}),_0x30c9de[_0x5de3f1('0x1b4e')]=[];});}function _0xd21742(){_0x30c9de['selectedSalesforceAccounts']=[];}function _0x3313c3(){const _0x2eee8f=_0x3cd334;_0x30c9de['selectedSalesforceAccounts']=_0x30c9de[_0x2eee8f('0xcdc')][_0x2eee8f('0xf5d')];}}const _0x51114e=_0x975923;_0x543584[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x1410'),_0x189033('0x88'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting','crudPermissions'];function _0x543584(_0x53cabf,_0x451859,_0x53aab9,_0x34292b,_0x43f591,_0x444c5a,_0x5bcb0c,_0xe44913,_0x2ac518,_0x583225,_0x43e834,_0x31d04a,_0x1bd2d8,_0x3e369b){const _0x22484a=_0x189033,_0x1839b4=this;_0x1839b4[_0x22484a('0x11ed')]=_0x43e834[_0x22484a('0x20b2')](),_0x1839b4['errors']=[],_0x1839b4[_0x22484a('0x260a')]=_0x1bd2d8,_0x1839b4[_0x22484a('0xace')]=_0x31d04a,_0x1839b4[_0x22484a('0x1134')]=_0x3e369b,_0x1839b4[_0x22484a('0x258d')]={},_0x1839b4['passwordPattern']=_0x1839b4['setting']&&_0x1839b4[_0x22484a('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1839b4['title']=_0x22484a('0x2659'),_0x1839b4[_0x22484a('0x88')]=angular[_0x22484a('0x1a86')](_0x2ac518),_0x1839b4[_0x22484a('0x1410')]=_0xe44913,_0x1839b4[_0x22484a('0x1531')]=![];!_0x1839b4[_0x22484a('0x88')]&&(_0x1839b4[_0x22484a('0x88')]={'serverUrl':_0x53aab9[_0x22484a('0x173e')]()+_0x22484a('0x20de')+_0x53aab9[_0x22484a('0x19ac')]()+(_0x53aab9[_0x22484a('0x4a2')]()?':'+_0x53aab9[_0x22484a('0x4a2')]():'')},_0x1839b4[_0x22484a('0xf28')]='INTEGRATIONS.NEW_SERVICENOWACCOUNT',_0x1839b4[_0x22484a('0x1531')]=!![]);_0x1839b4[_0x22484a('0x354')]=_0x5eda90,_0x1839b4[_0x22484a('0x26d6')]=_0x30d06d,_0x1839b4[_0x22484a('0x16e6')]=_0x5e3f84,_0x1839b4[_0x22484a('0x16b3')]=_0x36b224,_0x1839b4['closeDialog']=_0x1f9c45;function _0x5eda90(){const _0x5ed919=_0x22484a;_0x1839b4[_0x5ed919('0x17f')]=[],_0x583225['intServicenowAccount'][_0x5ed919('0xb0a')](_0x1839b4[_0x5ed919('0x88')])['$promise'][_0x5ed919('0x683')](function(_0x3dea33){const _0x4849c9=_0x5ed919;_0x1839b4[_0x4849c9('0x1410')][_0x4849c9('0x1167')](_0x3dea33[_0x4849c9('0x24e1')]()),_0x5bcb0c[_0x4849c9('0x53')]({'title':_0x4849c9('0x1168'),'msg':_0x1839b4['servicenowAccount'][_0x4849c9('0x60a')]?_0x1839b4[_0x4849c9('0x88')][_0x4849c9('0x60a')]+_0x4849c9('0x14b5'):''}),_0x1f9c45(_0x3dea33);})[_0x5ed919('0x130a')](function(_0x54732f){const _0x9fa090=_0x5ed919;if(_0x54732f[_0x9fa090('0x5a5')]&&_0x54732f[_0x9fa090('0x5a5')][_0x9fa090('0x17f')]&&_0x54732f[_0x9fa090('0x5a5')][_0x9fa090('0x17f')]['length']){_0x1839b4[_0x9fa090('0x17f')]=_0x54732f[_0x9fa090('0x5a5')][_0x9fa090('0x17f')]||[{'message':_0x54732f[_0x9fa090('0x1ff0')](),'type':'api.intServicenowAccount.save'}];for(let _0x132db1=0x0;_0x132db1<_0x54732f[_0x9fa090('0x5a5')][_0x9fa090('0x17f')][_0x9fa090('0x1564')];_0x132db1+=0x1){_0x5bcb0c['error']({'title':_0x54732f[_0x9fa090('0x5a5')][_0x9fa090('0x17f')][_0x132db1][_0x9fa090('0xcf0')],'msg':_0x54732f[_0x9fa090('0x5a5')][_0x9fa090('0x17f')][_0x132db1]['message']});}}else _0x5bcb0c[_0x9fa090('0x52a')]({'title':_0x54732f[_0x9fa090('0x13ee')]?_0x9fa090('0x2168')+_0x54732f[_0x9fa090('0x13ee')]+_0x9fa090('0xbf6')+_0x54732f[_0x9fa090('0x24a9')]:_0x9fa090('0x32c'),'msg':_0x54732f[_0x9fa090('0x5a5')]?JSON[_0x9fa090('0x258a')](_0x54732f['data'][_0x9fa090('0x8c2')]):_0x54732f[_0x9fa090('0x1ff0')]()});});}function _0x30d06d(){const _0x1d5bb9=_0x22484a;_0x1839b4['errors']=[],_0x583225['intServicenowAccount'][_0x1d5bb9('0x2480')]({'id':_0x1839b4['servicenowAccount']['id']},_0x1839b4[_0x1d5bb9('0x88')])[_0x1d5bb9('0xe53')][_0x1d5bb9('0x683')](function(_0x40b7fa){const _0x2dd113=_0x1d5bb9,_0x3838dd=_0x2e3ca0()[_0x2dd113('0x1c07')](_0x1839b4[_0x2dd113('0x1410')],{'id':_0x40b7fa['id']});_0x3838dd&&_0x2e3ca0()[_0x2dd113('0xf22')](_0x3838dd,_0x2e3ca0()['pick'](_0x40b7fa[_0x2dd113('0x24e1')](),_0x2e3ca0()[_0x2dd113('0x55e')](_0x3838dd))),_0x5bcb0c['success']({'title':_0x2dd113('0x664'),'msg':_0x1839b4[_0x2dd113('0x88')][_0x2dd113('0x60a')]?_0x1839b4[_0x2dd113('0x88')]['name']+'\x20has\x20been\x20saved!':''}),_0x1f9c45(_0x40b7fa);})[_0x1d5bb9('0x130a')](function(_0x256ebd){const _0x920f=_0x1d5bb9;if(_0x256ebd[_0x920f('0x5a5')]&&_0x256ebd[_0x920f('0x5a5')][_0x920f('0x17f')]&&_0x256ebd[_0x920f('0x5a5')][_0x920f('0x17f')][_0x920f('0x1564')]){_0x1839b4[_0x920f('0x17f')]=_0x256ebd[_0x920f('0x5a5')]['errors']||[{'message':_0x256ebd[_0x920f('0x1ff0')](),'type':'api.intServicenowAccount.update'}];for(let _0x569f80=0x0;_0x569f80<_0x256ebd[_0x920f('0x5a5')][_0x920f('0x17f')]['length'];_0x569f80++){_0x5bcb0c[_0x920f('0x52a')]({'title':_0x256ebd[_0x920f('0x5a5')][_0x920f('0x17f')][_0x569f80][_0x920f('0xcf0')],'msg':_0x256ebd[_0x920f('0x5a5')]['errors'][_0x569f80][_0x920f('0x8c2')]});}}else _0x5bcb0c['error']({'title':_0x256ebd[_0x920f('0x13ee')]?'API:'+_0x256ebd[_0x920f('0x13ee')]+_0x920f('0xbf6')+_0x256ebd[_0x920f('0x24a9')]:_0x920f('0xf34'),'msg':_0x256ebd[_0x920f('0x5a5')]?JSON[_0x920f('0x258a')](_0x256ebd[_0x920f('0x5a5')][_0x920f('0x8c2')]):_0x256ebd[_0x920f('0x1ff0')]()});});}function _0x5e3f84(_0x5789e0){const _0x2f0637=_0x22484a;_0x1839b4[_0x2f0637('0x17f')]=[];const _0x2f080c=_0x34292b[_0x2f0637('0x1c6f')]()['title']('Are\x20you\x20sure?')[_0x2f0637('0xa6a')]('The\x20servicenowAccount\x20will\x20be\x20deleted.')[_0x2f0637('0x1040')]('Delete\x20ServicenowAccount')['ok'](_0x2f0637('0x2307'))[_0x2f0637('0x19fb')]('Cancel')[_0x2f0637('0xe42')](_0x5789e0);_0x34292b['show'](_0x2f080c)[_0x2f0637('0x683')](function(){const _0xbc2212=_0x2f0637;_0x583225[_0xbc2212('0x2169')]['delete']({'id':_0x1839b4['servicenowAccount']['id']})[_0xbc2212('0xe53')][_0xbc2212('0x683')](function(){const _0x5d0339=_0xbc2212;_0x2e3ca0()[_0x5d0339('0x3ec')](_0x1839b4[_0x5d0339('0x1410')],{'id':_0x1839b4[_0x5d0339('0x88')]['id']}),_0x5bcb0c[_0x5d0339('0x53')]({'title':_0x5d0339('0xd57'),'msg':(_0x1839b4[_0x5d0339('0x88')][_0x5d0339('0x60a')]||_0x5d0339('0x88'))+_0x5d0339('0x194d')}),_0x1f9c45(_0x1839b4[_0x5d0339('0x88')]);})[_0xbc2212('0x130a')](function(_0x3d0369){const _0x374c85=_0xbc2212;if(_0x3d0369[_0x374c85('0x5a5')]&&_0x3d0369[_0x374c85('0x5a5')][_0x374c85('0x17f')]&&_0x3d0369[_0x374c85('0x5a5')][_0x374c85('0x17f')][_0x374c85('0x1564')]){_0x1839b4[_0x374c85('0x17f')]=_0x3d0369[_0x374c85('0x5a5')][_0x374c85('0x17f')]||[{'message':_0x3d0369[_0x374c85('0x1ff0')](),'type':_0x374c85('0x617')}];for(let _0x11bc73=0x0;_0x11bc73<_0x3d0369[_0x374c85('0x5a5')][_0x374c85('0x17f')][_0x374c85('0x1564')];_0x11bc73++){_0x5bcb0c['error']({'title':_0x3d0369[_0x374c85('0x5a5')]['errors'][_0x11bc73][_0x374c85('0xcf0')],'msg':_0x3d0369[_0x374c85('0x5a5')][_0x374c85('0x17f')][_0x11bc73][_0x374c85('0x8c2')]});}}else _0x5bcb0c['error']({'title':_0x3d0369['status']?_0x374c85('0x2168')+_0x3d0369[_0x374c85('0x13ee')]+_0x374c85('0xbf6')+_0x3d0369[_0x374c85('0x24a9')]:_0x374c85('0x617'),'msg':_0x3d0369[_0x374c85('0x5a5')]?JSON[_0x374c85('0x258a')](_0x3d0369['data']['message']):_0x3d0369[_0x374c85('0x8c2')]||_0x3d0369['toString']()});});},function(){});}function _0x36b224(_0x5c8cbb){return _0x5c8cbb===null?undefined:new Date(_0x5c8cbb);}function _0x1f9c45(_0x1dc3ee){const _0x531ace=_0x22484a;_0x34292b[_0x531ace('0x1715')](_0x1dc3ee);}}const _0x1178a9=_0x543584,_0xeab424=_0x180212['p']+_0x189033('0xc2a'),_0x1ce649=_0x180212['p']+'src/js/modules/main/apps/integrations/views/servicenowAccounts/edit/item/dialog.html/dialog.html';_0xb4659c[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x16ea'),'api','toasty','Auth'];function _0xb4659c(_0x1b62f5,_0x3cd836,_0x4d10c2,_0x3ed1f2,_0x4d9bda){const _0x1a18db=_0x189033,_0x4bd88a=this;_0x4bd88a[_0x1a18db('0x11ed')]=_0x4d9bda[_0x1a18db('0x20b2')](),_0x4bd88a[_0x1a18db('0x88')]={},_0x4bd88a[_0x1a18db('0x1ddd')]={},_0x4bd88a[_0x1a18db('0x1573')]=[],_0x4bd88a[_0x1a18db('0x172')]=-0x1,_0x4bd88a[_0x1a18db('0x1134')],_0x4bd88a[_0x1a18db('0x12f3')]=_0x38b78f,_0x4bd88a[_0x1a18db('0xabc')]=_0x5096ac,_0x4bd88a['createOrEditServicenowConfiguration']=_0x4611a3,_0x4bd88a[_0x1a18db('0x1f26')]=_0x4e5b11;function _0x38b78f(_0x503122,_0x2d55a4){const _0x2f7eff=_0x1a18db;_0x4bd88a[_0x2f7eff('0x88')]=_0x503122,_0x4bd88a[_0x2f7eff('0x1134')]=typeof _0x2d55a4!==_0x2f7eff('0x1867')?_0x2d55a4:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x4d10c2['intServicenowAccount'][_0x2f7eff('0x1575')]({'id':_0x4bd88a['servicenowAccount']['id'],'sort':_0x2f7eff('0xc36')})[_0x2f7eff('0xe53')][_0x2f7eff('0x683')](function(_0x31ae8b){const _0xbc7066=_0x2f7eff;return _0x4bd88a[_0xbc7066('0x1573')]=_0x31ae8b['rows']?_0x31ae8b[_0xbc7066('0xf5d')]:[],_0x4bd88a['configurations']['length']&&_0x4bd88a[_0xbc7066('0xabc')](0x0),_0x4d10c2['variable']['get']({'nolimit':!![],'sort':_0xbc7066('0x60a')})[_0xbc7066('0xe53')];})[_0x2f7eff('0x683')](function(_0x119c98){const _0x498429=_0x2f7eff;_0x4bd88a[_0x498429('0x220b')]=_0x119c98[_0x498429('0xf5d')]?_0x119c98['rows']:[],_0x4bd88a[_0x498429('0x1822')]=_0x2e3ca0()[_0x498429('0x24db')](_0x4bd88a['variables'],'id');})[_0x2f7eff('0x130a')](function(_0x5492fb){const _0x3fd074=_0x2f7eff;_0x3ed1f2[_0x3fd074('0x52a')]({'title':_0x5492fb[_0x3fd074('0x13ee')]?'API:'+_0x5492fb[_0x3fd074('0x13ee')]+'\x20-\x20'+_0x5492fb[_0x3fd074('0x24a9')]:_0x3fd074('0xe2a'),'msg':_0x5492fb['data']?JSON[_0x3fd074('0x258a')](_0x5492fb['data']):_0x5492fb[_0x3fd074('0x1ff0')]()});});}function _0x5096ac(_0x25f911){const _0x1f9a7e=_0x1a18db;_0x4bd88a['servicenowConfiguration']=_0x4bd88a[_0x1f9a7e('0x1573')][_0x25f911],_0x4bd88a[_0x1f9a7e('0x172')]=_0x25f911,_0x4d10c2[_0x1f9a7e('0x11e5')][_0x1f9a7e('0x20ac')]({'id':_0x4bd88a[_0x1f9a7e('0x1ddd')]['id']})[_0x1f9a7e('0xe53')][_0x1f9a7e('0x683')](function(_0x1cd778){const _0x4789b4=_0x1f9a7e;return _0x4bd88a[_0x4789b4('0x1ead')]=_0x1cd778[_0x4789b4('0xf5d')]?_0x1cd778['rows']:[],_0x4d10c2[_0x4789b4('0x11e5')]['getDescriptions']({'id':_0x4bd88a[_0x4789b4('0x1ddd')]['id']})['$promise'];})[_0x1f9a7e('0x683')](function(_0x58a121){const _0x291ac2=_0x1f9a7e;return _0x4bd88a[_0x291ac2('0x18f7')]=_0x58a121[_0x291ac2('0xf5d')]?_0x58a121['rows']:[],_0x4d10c2[_0x291ac2('0x11e5')][_0x291ac2('0x298')]({'id':_0x4bd88a['servicenowConfiguration']['id']})[_0x291ac2('0xe53')];})[_0x1f9a7e('0x683')](function(_0x2c7552){const _0x16c94c=_0x1f9a7e;_0x4bd88a[_0x16c94c('0x189a')]=_0x2c7552['rows']?_0x2c7552[_0x16c94c('0xf5d')]:[];})[_0x1f9a7e('0x130a')](function(_0x543a9f){const _0x1c9e74=_0x1f9a7e;_0x3ed1f2['error']({'title':_0x543a9f['status']?_0x1c9e74('0x2168')+_0x543a9f['status']+'\x20-\x20'+_0x543a9f[_0x1c9e74('0x24a9')]:_0x1c9e74('0x167c'),'msg':_0x543a9f[_0x1c9e74('0x5a5')]?JSON['stringify'](_0x543a9f[_0x1c9e74('0x5a5')]):_0x543a9f[_0x1c9e74('0x1ff0')]()});});}function _0x4611a3(_0x3c82da,_0x515a04){const _0x4cd418=_0x1a18db;_0x1b62f5[_0x4cd418('0x1d4')]({'controller':_0x4cd418('0xf23'),'controllerAs':'vm','templateUrl':_0xeab424,'parent':angular[_0x4cd418('0x1fcc')](_0x3cd836[_0x4cd418('0x18e5')]),'targetEvent':_0x3c82da,'clickOutsideToClose':!![],'locals':{'servicenowConfiguration':_0x515a04,'configurations':_0x4bd88a[_0x4cd418('0x1573')],'license':null,'setting':null,'crudPermissions':_0x4bd88a['crudPermissions']}})['finally'](function(){const _0x2dcac3=_0x4cd418;_0x4bd88a[_0x2dcac3('0xabc')](0x0);});}function _0x4e5b11(_0x186ff1,_0x4e65bc){const _0x4cd9c7=_0x1a18db,_0x33aa9b=_0x1b62f5[_0x4cd9c7('0x1c6f')]()[_0x4cd9c7('0xf28')](_0x4cd9c7('0xca8'))['htmlContent'](_0x4cd9c7('0xed5')+(_0x4e65bc[_0x4cd9c7('0x60a')]||_0x4cd9c7('0x1ddd'))+_0x4cd9c7('0x20f1')+_0x4cd9c7('0x1ee7'))[_0x4cd9c7('0x1040')](_0x4cd9c7('0x9cf'))[_0x4cd9c7('0xe42')](_0x186ff1)['ok']('OK')[_0x4cd9c7('0x19fb')]('CANCEL');_0x1b62f5[_0x4cd9c7('0x1d4')](_0x33aa9b)[_0x4cd9c7('0x683')](function(){const _0x39bbf5=_0x4cd9c7;_0x4d10c2[_0x39bbf5('0x11e5')][_0x39bbf5('0xd7e')]({'id':_0x4e65bc['id']})[_0x39bbf5('0xe53')][_0x39bbf5('0x683')](function(){const _0x215f07=_0x39bbf5;_0x2e3ca0()['remove'](_0x4bd88a[_0x215f07('0x1573')],{'id':_0x4e65bc['id']}),_0x3ed1f2[_0x215f07('0x53')]({'title':_0x215f07('0x206c'),'msg':_0x4e65bc[_0x215f07('0x60a')]?_0x4e65bc[_0x215f07('0x60a')]+_0x215f07('0x194d'):''});})[_0x39bbf5('0x130a')](function(_0x530adc){const _0x2ab87b=_0x39bbf5;_0x3ed1f2[_0x2ab87b('0x52a')]({'title':_0x530adc[_0x2ab87b('0x13ee')]?_0x2ab87b('0x2168')+_0x530adc[_0x2ab87b('0x13ee')]+'\x20-\x20'+_0x530adc[_0x2ab87b('0x24a9')]:_0x2ab87b('0x1e44'),'msg':_0x530adc[_0x2ab87b('0x5a5')]?JSON[_0x2ab87b('0x258a')](_0x530adc['data']):_0x530adc['toString']()});})[_0x39bbf5('0x2874')](function(){const _0x250eaa=_0x39bbf5;_0x4bd88a[_0x250eaa('0xabc')](0x0);});},function(){const _0x855b0a=_0x4cd9c7;console[_0x855b0a('0x1b2b')](_0x855b0a('0x16b8'));});}_0x4bd88a[_0x1a18db('0x1781')]=[],_0x4bd88a[_0x1a18db('0x2654')]=_0x51117d,_0x4bd88a['deleteSubjectConfirm']=_0x5b6fd2,_0x4bd88a['deleteSelectedSubjects']=_0x54929b;function _0x51117d(_0x31c5bf,_0x81bad7){const _0x1b0c8c=_0x1a18db;_0x1b62f5['show']({'controller':_0x1b0c8c('0x258'),'controllerAs':'vm','templateUrl':_0x1ce649,'parent':angular['element'](_0x3cd836[_0x1b0c8c('0x18e5')]),'targetEvent':_0x31c5bf,'clickOutsideToClose':!![],'locals':{'type':'subject','item':_0x81bad7,'items':_0x4bd88a['subjects'],'configuration':_0x4bd88a[_0x1b0c8c('0x1ddd')],'account':_0x4bd88a[_0x1b0c8c('0x88')],'license':null,'setting':null,'crudPermissions':_0x4bd88a[_0x1b0c8c('0x1134')]}});}function _0x1d07d4(_0x2122f9){const _0x4d76fe=_0x1a18db;_0x4d10c2[_0x4d76fe('0x1c55')][_0x4d76fe('0xd7e')]({'id':_0x2122f9['id']})[_0x4d76fe('0xe53')][_0x4d76fe('0x683')](function(){const _0x27bd09=_0x4d76fe;_0x2e3ca0()[_0x27bd09('0x3ec')](_0x4bd88a['subjects'],{'id':_0x2122f9['id']}),_0x3ed1f2[_0x27bd09('0x53')]({'title':_0x27bd09('0x637'),'msg':'Subject\x20has\x20been\x20deleted!'});})[_0x4d76fe('0x130a')](function(_0x28ae0d){const _0x2133c3=_0x4d76fe;_0x3ed1f2[_0x2133c3('0x52a')]({'title':_0x28ae0d[_0x2133c3('0x13ee')]?_0x2133c3('0x2168')+_0x28ae0d[_0x2133c3('0x13ee')]+_0x2133c3('0xbf6')+_0x28ae0d[_0x2133c3('0x24a9')]:_0x2133c3('0x1d23'),'msg':_0x28ae0d['data']?JSON[_0x2133c3('0x258a')](_0x28ae0d[_0x2133c3('0x5a5')]):_0x28ae0d['toString']()});});}function _0x5b6fd2(_0x37e4b9,_0x4a363f){const _0x39c65a=_0x1a18db,_0x3ce58a=_0x1b62f5[_0x39c65a('0x1c6f')]()[_0x39c65a('0xf28')](_0x39c65a('0x17ed'))['htmlContent'](_0x39c65a('0x601')+_0x39c65a('0x1ee7'))[_0x39c65a('0x1040')](_0x39c65a('0x20d'))['targetEvent'](_0x37e4b9)['ok']('OK')[_0x39c65a('0x19fb')]('CANCEL');_0x1b62f5[_0x39c65a('0x1d4')](_0x3ce58a)[_0x39c65a('0x683')](function(){_0x1d07d4(_0x4a363f);},function(){const _0x2aebfb=_0x39c65a;console[_0x2aebfb('0x1b2b')](_0x2aebfb('0x16b8'));});}function _0x54929b(_0x253efc){const _0x34645d=_0x1a18db,_0x9d2481=_0x1b62f5[_0x34645d('0x1c6f')]()['title'](_0x34645d('0xad5'))[_0x34645d('0x26e3')](_0x34645d('0xed5')+_0x4bd88a[_0x34645d('0x1781')][_0x34645d('0x1564')]+_0x34645d('0x93c')+'\x20will\x20be\x20deleted.')[_0x34645d('0x1040')](_0x34645d('0x9fb'))['targetEvent'](_0x253efc)['ok']('OK')[_0x34645d('0x19fb')](_0x34645d('0x16b8'));_0x1b62f5[_0x34645d('0x1d4')](_0x9d2481)[_0x34645d('0x683')](function(){const _0x2988a4=_0x34645d;_0x4bd88a['selectedSubjects'][_0x2988a4('0x1299')](function(_0x4c12d1){_0x1d07d4(_0x4c12d1);}),_0x4bd88a['selectedSubjects']=[];});}_0x4bd88a[_0x1a18db('0xcb1')]=[],_0x4bd88a[_0x1a18db('0x1094')]=_0x4a7dc6,_0x4bd88a[_0x1a18db('0x27b2')]=_0x4523dc,_0x4bd88a[_0x1a18db('0x27df')]=_0x1eb3ec;function _0x4a7dc6(_0x664da5,_0x2ea595){const _0x427ec7=_0x1a18db;_0x1b62f5[_0x427ec7('0x1d4')]({'controller':_0x427ec7('0x258'),'controllerAs':'vm','templateUrl':_0x1ce649,'parent':angular[_0x427ec7('0x1fcc')](_0x3cd836['body']),'targetEvent':_0x664da5,'clickOutsideToClose':!![],'locals':{'type':_0x427ec7('0xd6b'),'item':_0x2ea595,'items':_0x4bd88a[_0x427ec7('0x18f7')],'configuration':_0x4bd88a['servicenowConfiguration'],'account':_0x4bd88a[_0x427ec7('0x88')],'license':null,'setting':null,'crudPermissions':_0x4bd88a[_0x427ec7('0x1134')]}});}function _0x1e4123(_0x4e96b9){const _0x2ba373=_0x1a18db;_0x4d10c2[_0x2ba373('0x1c55')]['delete']({'id':_0x4e96b9['id']})[_0x2ba373('0xe53')][_0x2ba373('0x683')](function(){const _0x4fe6dd=_0x2ba373;_0x2e3ca0()['remove'](_0x4bd88a[_0x4fe6dd('0x18f7')],{'id':_0x4e96b9['id']}),_0x3ed1f2[_0x4fe6dd('0x53')]({'title':'Description\x20deleted!','msg':_0x4fe6dd('0x21c7')});})['catch'](function(_0xfc05a0){const _0x2fee21=_0x2ba373;_0x3ed1f2['error']({'title':_0xfc05a0[_0x2fee21('0x13ee')]?_0x2fee21('0x2168')+_0xfc05a0[_0x2fee21('0x13ee')]+_0x2fee21('0xbf6')+_0xfc05a0['statusText']:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0xfc05a0['data']?JSON[_0x2fee21('0x258a')](_0xfc05a0['data']):_0xfc05a0[_0x2fee21('0x1ff0')]()});});}function _0x4523dc(_0x35e1cc,_0x38d405){const _0x2a99b1=_0x1a18db,_0x11f921=_0x1b62f5[_0x2a99b1('0x1c6f')]()['title'](_0x2a99b1('0xb72'))[_0x2a99b1('0x26e3')]('Description'+_0x2a99b1('0x1ee7'))['ariaLabel'](_0x2a99b1('0x221c'))['targetEvent'](_0x35e1cc)['ok']('OK')[_0x2a99b1('0x19fb')](_0x2a99b1('0x16b8'));_0x1b62f5[_0x2a99b1('0x1d4')](_0x11f921)[_0x2a99b1('0x683')](function(){_0x1e4123(_0x38d405);},function(){const _0x502624=_0x2a99b1;console[_0x502624('0x1b2b')]('CANCEL');});}function _0x1eb3ec(_0x9b7435){const _0x3411c6=_0x1a18db,_0x5742b0=_0x1b62f5[_0x3411c6('0x1c6f')]()[_0x3411c6('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20descriptions?')['htmlContent'](_0x3411c6('0xed5')+_0x4bd88a['selectedDescriptions'][_0x3411c6('0x1564')]+_0x3411c6('0x93c')+'\x20will\x20be\x20deleted.')[_0x3411c6('0x1040')](_0x3411c6('0x1859'))[_0x3411c6('0xe42')](_0x9b7435)['ok']('OK')[_0x3411c6('0x19fb')](_0x3411c6('0x16b8'));_0x1b62f5[_0x3411c6('0x1d4')](_0x5742b0)[_0x3411c6('0x683')](function(){const _0x3e25b1=_0x3411c6;_0x4bd88a[_0x3e25b1('0xcb1')][_0x3e25b1('0x1299')](function(_0xa533a2){_0x1e4123(_0xa533a2);}),_0x4bd88a[_0x3e25b1('0xcb1')]=[];});}_0x4bd88a['selectedFields']=[],_0x4bd88a[_0x1a18db('0x84f')]=_0x2220c0,_0x4bd88a['deleteFieldConfirm']=_0x56f73e,_0x4bd88a[_0x1a18db('0x204e')]=_0x1b197b;function _0x2220c0(_0x3fb04c,_0x2992e3){const _0x55bdbc=_0x1a18db;_0x1b62f5[_0x55bdbc('0x1d4')]({'controller':_0x55bdbc('0x258'),'controllerAs':'vm','templateUrl':_0x1ce649,'parent':angular['element'](_0x3cd836[_0x55bdbc('0x18e5')]),'targetEvent':_0x3fb04c,'clickOutsideToClose':!![],'locals':{'type':'field','item':_0x2992e3,'items':_0x4bd88a['fields'],'configuration':_0x4bd88a[_0x55bdbc('0x1ddd')],'account':_0x4bd88a[_0x55bdbc('0x88')],'license':null,'setting':null,'crudPermissions':_0x4bd88a[_0x55bdbc('0x1134')]}});}function _0x57721f(_0x1a937d){const _0x418666=_0x1a18db;_0x4d10c2['intServicenowField'][_0x418666('0xd7e')]({'id':_0x1a937d['id']})[_0x418666('0xe53')]['then'](function(){const _0x2a025f=_0x418666;_0x2e3ca0()['remove'](_0x4bd88a[_0x2a025f('0x189a')],{'id':_0x1a937d['id']}),_0x3ed1f2[_0x2a025f('0x53')]({'title':_0x2a025f('0x1666'),'msg':_0x2a025f('0x1eda')});})[_0x418666('0x130a')](function(_0x2102b4){const _0x3e58e3=_0x418666;_0x3ed1f2[_0x3e58e3('0x52a')]({'title':_0x2102b4[_0x3e58e3('0x13ee')]?_0x3e58e3('0x2168')+_0x2102b4[_0x3e58e3('0x13ee')]+_0x3e58e3('0xbf6')+_0x2102b4[_0x3e58e3('0x24a9')]:_0x3e58e3('0x1d23'),'msg':_0x2102b4[_0x3e58e3('0x5a5')]?JSON[_0x3e58e3('0x258a')](_0x2102b4[_0x3e58e3('0x5a5')]):_0x2102b4['toString']()});});}function _0x56f73e(_0x58c8b4,_0x4393e6){const _0x5e0a85=_0x1a18db,_0x4c5a4b=_0x1b62f5[_0x5e0a85('0x1c6f')]()[_0x5e0a85('0xf28')](_0x5e0a85('0x16b5'))[_0x5e0a85('0x26e3')](_0x5e0a85('0x23b9')+_0x5e0a85('0x1ee7'))[_0x5e0a85('0x1040')](_0x5e0a85('0x1edb'))[_0x5e0a85('0xe42')](_0x58c8b4)['ok']('OK')[_0x5e0a85('0x19fb')](_0x5e0a85('0x16b8'));_0x1b62f5[_0x5e0a85('0x1d4')](_0x4c5a4b)[_0x5e0a85('0x683')](function(){_0x57721f(_0x4393e6);},function(){const _0x4b5478=_0x5e0a85;console['log'](_0x4b5478('0x16b8'));});}function _0x1b197b(_0x4fcc35){const _0x328721=_0x1a18db,_0x534891=_0x1b62f5['confirm']()[_0x328721('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20fields?')['htmlContent'](_0x328721('0xed5')+_0x4bd88a[_0x328721('0x310')][_0x328721('0x1564')]+_0x328721('0x93c')+_0x328721('0x1ee7'))[_0x328721('0x1040')](_0x328721('0x994'))['targetEvent'](_0x4fcc35)['ok']('OK')[_0x328721('0x19fb')](_0x328721('0x16b8'));_0x1b62f5[_0x328721('0x1d4')](_0x534891)['then'](function(){const _0x5c323b=_0x328721;_0x4bd88a['selectedFields'][_0x5c323b('0x1299')](function(_0x2d081a){_0x57721f(_0x2d081a);}),_0x4bd88a['selectedFields']=[];});}}const _0x34c593=_0xb4659c;_0x1d7d69[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),'configurations',_0x189033('0x1ddd'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x1d7d69(_0x1c50a8,_0x2acc9f,_0xe7fb80,_0x39cd22,_0x21750c,_0x5752d9,_0x456fea,_0xac3165,_0x451c47,_0x1b81cd,_0xc93d2a,_0x3944d2,_0x57c923,_0x364bff){const _0xf67cf3=_0x189033,_0x4edccd=this;_0x4edccd['currentUser']=_0xc93d2a['getCurrentUser'](),_0x4edccd[_0xf67cf3('0x17f')]=[],_0x4edccd[_0xf67cf3('0x260a')]=_0x57c923,_0x4edccd[_0xf67cf3('0xace')]=_0x3944d2,_0x4edccd[_0xf67cf3('0x1134')]=_0x364bff,_0x4edccd['hasModulePermissions']={},_0x4edccd[_0xf67cf3('0x19b2')]=_0x4edccd['setting']&&_0x4edccd[_0xf67cf3('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4edccd[_0xf67cf3('0xf28')]=_0xf67cf3('0x8b0'),_0x4edccd['servicenowConfiguration']=angular['copy'](_0x451c47),_0x4edccd[_0xf67cf3('0x1573')]=_0xac3165,_0x4edccd[_0xf67cf3('0x1237')]=![];!_0x4edccd['servicenowConfiguration']&&(_0x4edccd[_0xf67cf3('0x1ddd')]={'channel':_0xf67cf3('0xcf2'),'type':_0xf67cf3('0x1535')},_0x4edccd['title']=_0xf67cf3('0x81'),_0x4edccd[_0xf67cf3('0x1237')]=!![]);_0x4edccd[_0xf67cf3('0x7f6')]=_0x338286,_0x4edccd[_0xf67cf3('0x9ae')]=_0x5379fe,_0x4edccd[_0xf67cf3('0x1f26')]=_0xb654d5,_0x4edccd[_0xf67cf3('0x16b3')]=_0xaa5cc,_0x4edccd[_0xf67cf3('0xf82')]=_0x208e59;function _0x338286(){const _0x1e9484=_0xf67cf3;_0x4edccd[_0x1e9484('0x17f')]=[],_0x1b81cd[_0x1e9484('0x2169')][_0x1e9484('0x2003')]({'id':_0x2acc9f[_0x1e9484('0x7f2')]['id']},_0x4edccd[_0x1e9484('0x1ddd')])[_0x1e9484('0xe53')][_0x1e9484('0x683')](function(_0x472ea9){const _0x488779=_0x1e9484;_0x4edccd[_0x488779('0x1573')][_0x488779('0x1167')](_0x472ea9[_0x488779('0x24e1')]()),_0x456fea[_0x488779('0x53')]({'title':_0x488779('0x263b'),'msg':_0x4edccd[_0x488779('0x1ddd')][_0x488779('0x60a')]?_0x4edccd['servicenowConfiguration'][_0x488779('0x60a')]+_0x488779('0x14b5'):''}),_0x208e59(_0x472ea9);})[_0x1e9484('0x130a')](function(_0x53f219){const _0x2bb808=_0x1e9484;if(_0x53f219[_0x2bb808('0x5a5')]&&_0x53f219[_0x2bb808('0x5a5')][_0x2bb808('0x17f')]&&_0x53f219[_0x2bb808('0x5a5')][_0x2bb808('0x17f')][_0x2bb808('0x1564')]){_0x4edccd[_0x2bb808('0x17f')]=_0x53f219[_0x2bb808('0x5a5')][_0x2bb808('0x17f')]||[{'message':_0x53f219['toString'](),'type':_0x2bb808('0x113a')}];for(let _0x3be08e=0x0;_0x3be08e<_0x53f219[_0x2bb808('0x5a5')]['errors'][_0x2bb808('0x1564')];_0x3be08e+=0x1){_0x456fea[_0x2bb808('0x52a')]({'title':_0x53f219[_0x2bb808('0x5a5')][_0x2bb808('0x17f')][_0x3be08e][_0x2bb808('0xcf0')],'msg':_0x53f219[_0x2bb808('0x5a5')][_0x2bb808('0x17f')][_0x3be08e][_0x2bb808('0x8c2')]});}}else _0x456fea['error']({'title':_0x53f219[_0x2bb808('0x13ee')]?'API:'+_0x53f219[_0x2bb808('0x13ee')]+_0x2bb808('0xbf6')+_0x53f219[_0x2bb808('0x24a9')]:'api.intServicenowConfiguration.save','msg':_0x53f219[_0x2bb808('0x5a5')]?JSON[_0x2bb808('0x258a')](_0x53f219[_0x2bb808('0x5a5')][_0x2bb808('0x8c2')]):_0x53f219[_0x2bb808('0x1ff0')]()});});}function _0x5379fe(){const _0x14574a=_0xf67cf3;_0x4edccd[_0x14574a('0x17f')]=[],_0x1b81cd[_0x14574a('0x11e5')]['update']({'id':_0x4edccd[_0x14574a('0x1ddd')]['id']},_0x4edccd[_0x14574a('0x1ddd')])[_0x14574a('0xe53')][_0x14574a('0x683')](function(_0x415eed){const _0x2daf8d=_0x14574a,_0x5e5c4b=_0x2e3ca0()[_0x2daf8d('0x1c07')](_0x4edccd[_0x2daf8d('0x1573')],{'id':_0x415eed['id']});_0x5e5c4b&&_0x2e3ca0()[_0x2daf8d('0xf22')](_0x5e5c4b,_0x2e3ca0()[_0x2daf8d('0x24d0')](_0x415eed[_0x2daf8d('0x24e1')](),_0x2e3ca0()[_0x2daf8d('0x55e')](_0x5e5c4b))),_0x456fea[_0x2daf8d('0x53')]({'title':_0x2daf8d('0x1615'),'msg':_0x4edccd[_0x2daf8d('0x1ddd')]['name']?_0x4edccd[_0x2daf8d('0x1ddd')][_0x2daf8d('0x60a')]+_0x2daf8d('0xf59'):''}),_0x208e59(_0x415eed);})[_0x14574a('0x130a')](function(_0xe5efe4){const _0x4e2f09=_0x14574a;if(_0xe5efe4[_0x4e2f09('0x5a5')]&&_0xe5efe4[_0x4e2f09('0x5a5')][_0x4e2f09('0x17f')]&&_0xe5efe4[_0x4e2f09('0x5a5')][_0x4e2f09('0x17f')][_0x4e2f09('0x1564')]){_0x4edccd[_0x4e2f09('0x17f')]=_0xe5efe4[_0x4e2f09('0x5a5')]['errors']||[{'message':_0xe5efe4['toString'](),'type':_0x4e2f09('0xaa1')}];for(let _0x4d2c9d=0x0;_0x4d2c9d<_0xe5efe4[_0x4e2f09('0x5a5')][_0x4e2f09('0x17f')][_0x4e2f09('0x1564')];_0x4d2c9d++){_0x456fea['error']({'title':_0xe5efe4[_0x4e2f09('0x5a5')]['errors'][_0x4d2c9d][_0x4e2f09('0xcf0')],'msg':_0xe5efe4[_0x4e2f09('0x5a5')][_0x4e2f09('0x17f')][_0x4d2c9d][_0x4e2f09('0x8c2')]});}}else _0x456fea[_0x4e2f09('0x52a')]({'title':_0xe5efe4[_0x4e2f09('0x13ee')]?_0x4e2f09('0x2168')+_0xe5efe4[_0x4e2f09('0x13ee')]+_0x4e2f09('0xbf6')+_0xe5efe4[_0x4e2f09('0x24a9')]:_0x4e2f09('0xaa1'),'msg':_0xe5efe4['data']?JSON[_0x4e2f09('0x258a')](_0xe5efe4[_0x4e2f09('0x5a5')]['message']):_0xe5efe4[_0x4e2f09('0x1ff0')]()});});}function _0xb654d5(_0x695449){const _0x33fca6=_0xf67cf3;_0x4edccd[_0x33fca6('0x17f')]=[];const _0x26b0f3=_0x39cd22[_0x33fca6('0x1c6f')]()[_0x33fca6('0xf28')](_0x33fca6('0x4d'))['content']('The\x20servicenowConfiguration\x20will\x20be\x20deleted.')[_0x33fca6('0x1040')](_0x33fca6('0x1084'))['ok']('Delete')[_0x33fca6('0x19fb')](_0x33fca6('0x253a'))[_0x33fca6('0xe42')](_0x695449);_0x39cd22[_0x33fca6('0x1d4')](_0x26b0f3)[_0x33fca6('0x683')](function(){const _0x1ccf5c=_0x33fca6;_0x1b81cd[_0x1ccf5c('0x11e5')]['delete']({'id':_0x4edccd[_0x1ccf5c('0x1ddd')]['id']})['$promise']['then'](function(){const _0x59090d=_0x1ccf5c;_0x2e3ca0()[_0x59090d('0x3ec')](_0x4edccd[_0x59090d('0x1573')],{'id':_0x4edccd[_0x59090d('0x1ddd')]['id']}),_0x456fea[_0x59090d('0x53')]({'title':_0x59090d('0x47f'),'msg':(_0x4edccd[_0x59090d('0x1ddd')][_0x59090d('0x60a')]||'servicenowConfiguration')+_0x59090d('0x194d')}),_0x208e59(_0x4edccd[_0x59090d('0x1ddd')]);})[_0x1ccf5c('0x130a')](function(_0x167612){const _0x1ea750=_0x1ccf5c;if(_0x167612[_0x1ea750('0x5a5')]&&_0x167612[_0x1ea750('0x5a5')]['errors']&&_0x167612['data'][_0x1ea750('0x17f')][_0x1ea750('0x1564')]){_0x4edccd[_0x1ea750('0x17f')]=_0x167612[_0x1ea750('0x5a5')][_0x1ea750('0x17f')]||[{'message':_0x167612[_0x1ea750('0x1ff0')](),'type':_0x1ea750('0x1485')}];for(let _0x2f51a0=0x0;_0x2f51a0<_0x167612['data']['errors'][_0x1ea750('0x1564')];_0x2f51a0++){_0x456fea[_0x1ea750('0x52a')]({'title':_0x167612[_0x1ea750('0x5a5')]['errors'][_0x2f51a0][_0x1ea750('0xcf0')],'msg':_0x167612[_0x1ea750('0x5a5')][_0x1ea750('0x17f')][_0x2f51a0]['message']});}}else _0x456fea[_0x1ea750('0x52a')]({'title':_0x167612[_0x1ea750('0x13ee')]?_0x1ea750('0x2168')+_0x167612[_0x1ea750('0x13ee')]+_0x1ea750('0xbf6')+_0x167612['statusText']:_0x1ea750('0x1485'),'msg':_0x167612[_0x1ea750('0x5a5')]?JSON[_0x1ea750('0x258a')](_0x167612[_0x1ea750('0x5a5')][_0x1ea750('0x8c2')]):_0x167612['message']||_0x167612[_0x1ea750('0x1ff0')]()});});},function(){});}function _0xaa5cc(_0x34b87d){return _0x34b87d===null?undefined:new Date(_0x34b87d);}function _0x208e59(_0x573fa9){const _0x44f567=_0xf67cf3;_0x39cd22[_0x44f567('0x1715')](_0x573fa9);}}const _0xe6262c=_0x1d7d69;_0x10c026[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state','$location',_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x208d'),_0x189033('0x1996'),_0x189033('0x23ef'),_0x189033('0x1d2f'),_0x189033('0xcf0'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x10c026(_0xef3b1f,_0x25ce30,_0x2a28b6,_0x1ab9b9,_0x554f76,_0x9dc3aa,_0x57e00c,_0x194436,_0x33ea64,_0x36c8b0,_0xe3f05c,_0x201ff6,_0x57831a){const _0x24455e=_0x189033,_0x5a7463=this;_0x5a7463[_0x24455e('0x11ed')]=_0x201ff6['getCurrentUser'](),_0x5a7463[_0x24455e('0x17f')]=[],_0x5a7463['title']=_0x24455e('0x176c')+_0x2e3ca0()['toUpper'](_0x36c8b0),_0x5a7463['item']=angular[_0x24455e('0x1a86')](_0x194436),_0x5a7463[_0x24455e('0x1996')]=_0x57e00c,_0x5a7463[_0x24455e('0xcf0')]=_0x36c8b0,_0x5a7463[_0x24455e('0x1134')]=_0x57831a,_0x5a7463['newItem']=![];!_0x5a7463[_0x24455e('0x23ef')]&&(_0x5a7463[_0x24455e('0x23ef')]={'type':_0x24455e('0xc06')},_0x5a7463[_0x24455e('0x23ef')][_0x2e3ca0()[_0x24455e('0x21ab')](_0x36c8b0)+'Id']=_0x9dc3aa['id'],_0x5a7463['title']=_0x24455e('0x22de')+_0x2e3ca0()[_0x24455e('0x65')](_0x36c8b0),_0x5a7463[_0x24455e('0x3d2')]=!![]);_0x5a7463['addNewItem']=_0x6c971e,_0x5a7463[_0x24455e('0x2716')]=_0x421ec7,_0x5a7463[_0x24455e('0x6b8')]=_0x149d59,_0x5a7463[_0x24455e('0x18a')]=_0x4c867a,_0x5a7463[_0x24455e('0xf82')]=_0x56e9cb,_0xe3f05c[_0x24455e('0x26e0')][_0x24455e('0x1e6e')]({'nolimit':!![]})[_0x24455e('0xe53')][_0x24455e('0x683')](function(_0x8776b9){const _0x369cba=_0x24455e;return _0x5a7463['variables']=_0x8776b9[_0x369cba('0xf5d')]?_0x8776b9[_0x369cba('0xf5d')]:[],_0xe3f05c[_0x369cba('0xf53')][_0x369cba('0x2267')]()[_0x369cba('0xe53')];})[_0x24455e('0x683')](function(_0x515953){const _0x18ec19=_0x24455e;return _0x5a7463[_0x18ec19('0x20c1')]=_0x2e3ca0()['difference'](_0x2e3ca0()[_0x18ec19('0x55e')](_0x515953),[_0x18ec19('0xe53'),'$resolved',_0x18ec19('0x1a4'),_0x18ec19('0x2000'),_0x18ec19('0x1d58')]),_0x5a7463[_0x18ec19('0x20c1')][_0x18ec19('0x1fd0')](_0x18ec19('0x1e93')),_0xe3f05c[_0x18ec19('0x1793')]['describe']()[_0x18ec19('0xe53')];})[_0x24455e('0x683')](function(_0x3b7e37){const _0x3ebcd9=_0x24455e;_0x5a7463[_0x3ebcd9('0x1d6a')]=_0x2e3ca0()[_0x3ebcd9('0x2829')](_0x2e3ca0()[_0x3ebcd9('0x55e')](_0x3b7e37),[_0x3ebcd9('0xe53'),_0x3ebcd9('0x1980'),'createdAt',_0x3ebcd9('0x2000'),_0x3ebcd9('0x1d58')]),_0x5a7463[_0x3ebcd9('0x1d6a')][_0x3ebcd9('0x1fd0')](_0x3ebcd9('0x1e93'));})['catch'](function(_0x59f381){const _0x196725=_0x24455e;_0x554f76[_0x196725('0x52a')]({'title':_0x59f381[_0x196725('0x13ee')]?_0x196725('0x2168')+_0x59f381[_0x196725('0x13ee')]+'\x20-\x20'+_0x59f381[_0x196725('0x24a9')]:_0x196725('0x1fd3'),'msg':_0x59f381[_0x196725('0x5a5')]?JSON['stringify'](_0x59f381['data']):_0x59f381[_0x196725('0x1ff0')]()});}),_0xe3f05c['intServicenowAccount'][_0x24455e('0x298')]({'id':_0x33ea64['id'],'ticketType':_0x9dc3aa['ticketType']?_0x9dc3aa[_0x24455e('0x20c9')]:undefined})[_0x24455e('0xe53')][_0x24455e('0x683')](function(_0x4bc3d0){const _0x3274b9=_0x24455e;_0x5a7463[_0x3274b9('0xd32')]=!![],_0x5a7463[_0x3274b9('0x189a')]=_0x4bc3d0[_0x3274b9('0xf5d')]?_0x4bc3d0[_0x3274b9('0xf5d')]:[],_0x5a7463['item'][_0x3274b9('0x280')]&&(_0x5a7463['customField']=_0x2e3ca0()['find'](_0x5a7463[_0x3274b9('0x189a')],{'id':_0x5a7463['item'][_0x3274b9('0x280')]}));})[_0x24455e('0x130a')](function(_0x53c59f){const _0x1c8dca=_0x24455e;_0x5a7463[_0x1c8dca('0xd32')]=![],console[_0x1c8dca('0x52a')](_0x53c59f);});function _0x6c971e(){const _0x5b085a=_0x24455e;_0x5a7463[_0x5b085a('0x17f')]=[],_0x5a7463[_0x5b085a('0x7f8')]&&(_0x5a7463[_0x5b085a('0x23ef')][_0x5b085a('0x280')]=_0x5a7463[_0x5b085a('0x7f8')]['id'],_0x5a7463[_0x5b085a('0x23ef')][_0x5b085a('0x2584')]=_0x5a7463[_0x5b085a('0x7f8')][_0x5b085a('0x60a')],_0x5a7463['item'][_0x5b085a('0x7f8')]=_0x5a7463['customField']['custom']),_0xe3f05c[_0x5b085a('0x1c55')][_0x5b085a('0xb0a')](_0x5a7463[_0x5b085a('0x23ef')])[_0x5b085a('0xe53')][_0x5b085a('0x683')](function(_0x4636d0){const _0x4230d2=_0x5b085a;_0x5a7463['items'][_0x4230d2('0x1167')](_0x4636d0),_0x554f76['success']({'title':_0x2e3ca0()[_0x4230d2('0x21ab')](_0x36c8b0)+'\x20properly\x20created','msg':_0x2e3ca0()[_0x4230d2('0x21ab')](_0x36c8b0)+_0x4230d2('0x14b5')}),_0x56e9cb();})[_0x5b085a('0x130a')](function(_0x35d8b1){const _0x86dafa=_0x5b085a;console['error'](_0x35d8b1),_0x5a7463[_0x86dafa('0x17f')]=_0x35d8b1['data'][_0x86dafa('0x17f')]||[{'message':_0x35d8b1[_0x86dafa('0x1ff0')](),'type':_0x86dafa('0x1928')}];});}function _0x421ec7(){const _0x348741=_0x24455e;_0x5a7463['errors']=[],_0x5a7463[_0x348741('0x7f8')]&&(_0x5a7463['item'][_0x348741('0x280')]=_0x5a7463[_0x348741('0x7f8')]['id'],_0x5a7463[_0x348741('0x23ef')]['nameField']=_0x5a7463['customField']['name'],_0x5a7463[_0x348741('0x23ef')]['customField']=_0x5a7463[_0x348741('0x7f8')][_0x348741('0xbf0')]),_0xe3f05c['intServicenowField'][_0x348741('0x2480')]({'id':_0x5a7463[_0x348741('0x23ef')]['id']},_0x5a7463[_0x348741('0x23ef')])[_0x348741('0xe53')][_0x348741('0x683')](function(_0x24f6d1){const _0x6ad470=_0x348741,_0x3215a4=_0x2e3ca0()['find'](_0x5a7463[_0x6ad470('0x1996')],{'id':_0x24f6d1['id']});_0x3215a4&&_0x2e3ca0()[_0x6ad470('0xf22')](_0x3215a4,_0x24f6d1),_0x554f76[_0x6ad470('0x53')]({'title':_0x2e3ca0()[_0x6ad470('0x21ab')](_0x36c8b0)+_0x6ad470('0x15dd'),'msg':_0x2e3ca0()[_0x6ad470('0x21ab')](_0x36c8b0)+'\x20has\x20been\x20saved!'}),_0x56e9cb();})['catch'](function(_0x7c97d5){const _0x1478ab=_0x348741;console[_0x1478ab('0x52a')](_0x7c97d5),_0x5a7463['errors']=_0x7c97d5['data'][_0x1478ab('0x17f')]||[{'message':_0x7c97d5['toString'](),'type':'api.intItem.update'}];});}function _0x149d59(_0x354c66){const _0x4d6474=_0x24455e;_0x5a7463[_0x4d6474('0x17f')]=[];const _0x417c61=_0x1ab9b9['confirm']()[_0x4d6474('0xf28')]('Are\x20you\x20sure?')['content'](_0x4d6474('0x3fc')+_0x36c8b0+_0x4d6474('0x1ee7'))[_0x4d6474('0x1040')](_0x4d6474('0x609')+_0x2e3ca0()[_0x4d6474('0x21ab')](_0x36c8b0))['ok'](_0x4d6474('0x2307'))['cancel']('Cancel')[_0x4d6474('0xe42')](_0x354c66);_0x1ab9b9[_0x4d6474('0x1d4')](_0x417c61)[_0x4d6474('0x683')](function(){const _0x25ff92=_0x4d6474;_0xe3f05c['intServicenowField'][_0x25ff92('0xd7e')]({'id':_0x5a7463[_0x25ff92('0x23ef')]['id']})[_0x25ff92('0xe53')][_0x25ff92('0x683')](function(){const _0xfeac23=_0x25ff92;_0x2e3ca0()[_0xfeac23('0x3ec')](_0x5a7463[_0xfeac23('0x1996')],{'id':_0x5a7463[_0xfeac23('0x23ef')]['id']}),_0x554f76['success']({'title':_0x2e3ca0()[_0xfeac23('0x21ab')](_0x36c8b0)+_0xfeac23('0x27d7'),'msg':_0x2e3ca0()[_0xfeac23('0x21ab')](_0x36c8b0)+_0xfeac23('0x194d')}),_0x56e9cb();})['catch'](function(_0x31054f){const _0x22bdd1=_0x25ff92;console['error'](_0x31054f),_0x5a7463[_0x22bdd1('0x17f')]=_0x31054f[_0x22bdd1('0x5a5')]['errors']||[{'message':_0x31054f[_0x22bdd1('0x1ff0')](),'type':_0x22bdd1('0x70c')}];});},function(){});}function _0x4c867a(){const _0x508139=_0x24455e;return _0x5a7463[_0x508139('0x23ef')][_0x508139('0x113b')]!==undefined?_0x5a7463[_0x508139('0x23ef')][_0x508139('0x113b')]:_0x508139('0xbbf');}function _0x56e9cb(){const _0x38b4d4=_0x24455e;_0x1ab9b9[_0x38b4d4('0x1715')]();}}const _0x594da9=_0x10c026;_0x450275[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$document','$translate','license',_0x189033('0x260a'),_0x189033('0x56b'),'toasty','Auth',_0x189033('0x88'),_0x189033('0x22df')];function _0x450275(_0x46cb19,_0xee50d1,_0x268170,_0x230c9c,_0xfc25f,_0x1f8354,_0x157b8f,_0x1b732e,_0x261027,_0x90c257,_0x1cccc4,_0x2304ad){const _0xb27895=_0x189033,_0x282b5f=this;_0x282b5f[_0xb27895('0x11ed')]=_0x90c257[_0xb27895('0x20b2')](),_0x282b5f[_0xb27895('0xace')]=_0x1f8354,_0x282b5f[_0xb27895('0x260a')]=_0x157b8f,_0x282b5f['passwordPattern']=_0x282b5f[_0xb27895('0x260a')][_0xb27895('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x282b5f[_0xb27895('0x1224')]=_0xee50d1[_0xb27895('0x173e')]()+_0xb27895('0x20de')+_0xee50d1[_0xb27895('0x19ac')](),_0x282b5f['servicenowAccount']=_0x1cccc4||_0x46cb19['params']['servicenowAccount']||{},_0x282b5f[_0xb27895('0x22df')]=_0x2304ad&&_0x2304ad[_0xb27895('0x50d')]==0x1?_0x2304ad[_0xb27895('0xf5d')][0x0]:null,_0x282b5f[_0xb27895('0x1134')]=_0x90c257[_0xb27895('0x142a')](_0x282b5f[_0xb27895('0x22df')]?_0x282b5f[_0xb27895('0x22df')][_0xb27895('0x1134')]:null),_0x282b5f[_0xb27895('0x258d')]={},_0x282b5f[_0xb27895('0x517')]=_0x46cb19['params']['tab']||0x0,_0x282b5f['alert']=_0x261027[_0xb27895('0x2289')],_0x282b5f[_0xb27895('0x2687')]=_0x170cb5,_0x282b5f[_0xb27895('0x26d6')]=_0x564b62;function _0x170cb5(){const _0x443e28=_0xb27895;_0x46cb19['go'](_0x443e28('0x2847'),{},{'reload':_0x443e28('0x2847')});}function _0x564b62(){const _0x2e9a98=_0xb27895;_0x1b732e[_0x2e9a98('0x2169')][_0x2e9a98('0x2480')]({'id':_0x282b5f[_0x2e9a98('0x88')]['id']},_0x282b5f[_0x2e9a98('0x88')])['$promise'][_0x2e9a98('0x683')](function(){const _0x28ea2a=_0x2e9a98;_0x261027[_0x28ea2a('0x53')]({'title':_0x28ea2a('0x1eab'),'msg':_0x282b5f[_0x28ea2a('0x88')][_0x28ea2a('0x60a')]?_0x282b5f['servicenowAccount'][_0x28ea2a('0x60a')]+'\x20has\x20been\x20updated!':''});})[_0x2e9a98('0x130a')](function(_0x2bc647){const _0x2a5d0a=_0x2e9a98;_0x261027[_0x2a5d0a('0x52a')]({'title':_0x2bc647[_0x2a5d0a('0x13ee')]?'API:'+_0x2bc647[_0x2a5d0a('0x13ee')]+_0x2a5d0a('0xbf6')+_0x2bc647[_0x2a5d0a('0x24a9')]:_0x2a5d0a('0x2fc'),'msg':_0x2bc647[_0x2a5d0a('0x5a5')]?JSON[_0x2a5d0a('0x258a')](_0x2bc647[_0x2a5d0a('0x5a5')]):_0x2bc647[_0x2a5d0a('0x1ff0')]()});});}}const _0x4c4dbf=_0x450275,_0x402de2=_0x180212['p']+_0x189033('0x32a');_0x30c3ea['$inject']=['$scope',_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),'$translate',_0x189033('0x1410'),_0x189033('0x2a'),'userProfileSection',_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x30c3ea(_0x759bf4,_0x3132c0,_0x458744,_0x2764b8,_0x39a33a,_0x46f09e,_0x2ec177,_0x25dd0f,_0x17909c,_0x101915,_0x473844,_0x49a763,_0x525cf7,_0x4c2199,_0x524719,_0x745cc8,_0xa17f50){const _0x3915a2=_0x189033,_0x5b29c4=this;_0x5b29c4[_0x3915a2('0xace')]=_0x745cc8,_0x5b29c4[_0x3915a2('0x260a')]=_0xa17f50,_0x5b29c4['currentUser']=_0x524719['getCurrentUser'](),_0x5b29c4[_0x3915a2('0x1410')]=_0x17909c||{'count':0x0,'rows':[]},_0x5b29c4['userProfile']=_0x101915,_0x5b29c4[_0x3915a2('0x22df')]=_0x473844&&_0x473844[_0x3915a2('0x50d')]==0x1?_0x473844[_0x3915a2('0xf5d')][0x0]:null,_0x5b29c4[_0x3915a2('0x1134')]=_0x524719[_0x3915a2('0x142a')](_0x5b29c4[_0x3915a2('0x22df')]?_0x5b29c4[_0x3915a2('0x22df')][_0x3915a2('0x1134')]:null),_0x5b29c4['table']=_0x3915a2('0x1410'),_0x5b29c4[_0x3915a2('0x247')]='',_0x5b29c4['listOrderAsc']=null,_0x5b29c4[_0x3915a2('0x25de')]=[],_0x5b29c4[_0x3915a2('0x23a2')]={'fields':_0x3915a2('0x7ea'),'limit':0xa,'page':0x1},_0x5b29c4[_0x3915a2('0xc63')]=_0x429b48,_0x5b29c4[_0x3915a2('0x375')]=_0x1ef2c2,_0x5b29c4['deleteconfirm']=_0x1fa45b,_0x5b29c4[_0x3915a2('0x53')]=_0x185420,_0x5b29c4[_0x3915a2('0x1a90')]=_0xa804d0,_0x5b29c4[_0x3915a2('0x106c')]=_0x1459e3,_0x5b29c4[_0x3915a2('0x16e6')]=_0xc4e790,_0x5b29c4[_0x3915a2('0x21f8')]=_0xceceb2,_0x5b29c4[_0x3915a2('0x1eaa')]=_0x45c887,_0x5b29c4[_0x3915a2('0x1596')]=_0x45a516,_0x5b29c4[_0x3915a2('0x280a')]=_0xf5b186;function _0x429b48(_0x5ab8af){const _0xe5c947=_0x3915a2;_0x458744['go'](_0xe5c947('0x1610'),{'id':_0x5ab8af['id'],'servicenowAccount':_0x5ab8af,'crudPermissions':_0x5b29c4['crudPermissions']});}function _0x1ef2c2(_0x35965f){const _0x258369=_0x3915a2;return _0x49a763[_0x258369('0x2169')][_0x258369('0x298')]({'id':_0x35965f['id'],'test':!![]})['$promise'][_0x258369('0x683')](function(){const _0x4dd2ab=_0x258369;_0x4c2199[_0x4dd2ab('0x53')]({'title':_0x4dd2ab('0x19a3'),'msg':_0x4dd2ab('0x1c6d')});})['catch'](function(_0x1e3186){const _0xadc7f1=_0x258369;_0x4c2199[_0xadc7f1('0x52a')]({'title':'ServicenowAccount\x20properly\x20tested','msg':_0x1e3186[_0xadc7f1('0x5a5')]?_0x1e3186[_0xadc7f1('0x5a5')][_0xadc7f1('0x8c2')]?_0x1e3186['data'][_0xadc7f1('0x8c2')]:JSON[_0xadc7f1('0x258a')](_0x1e3186[_0xadc7f1('0x5a5')]):_0x1e3186[_0xadc7f1('0x1ff0')]()});});}function _0x1fa45b(_0x3e2ace,_0x24931e){const _0x567ceb=_0x3915a2,_0x4391f7=_0x39a33a[_0x567ceb('0x1c6f')]()[_0x567ceb('0xf28')](_0x567ceb('0x1b01')+_0x2e3ca0()['startCase'](_0x567ceb('0x88'))+'?')['htmlContent'](_0x567ceb('0xed5')+(_0x3e2ace[_0x567ceb('0x60a')]||_0x567ceb('0x88'))+_0x567ceb('0x20f1')+_0x567ceb('0x1ee7'))[_0x567ceb('0x1040')](_0x567ceb('0x1210'))[_0x567ceb('0xe42')](_0x24931e)['ok']('OK')['cancel'](_0x567ceb('0x16b8'));_0x39a33a['show'](_0x4391f7)[_0x567ceb('0x683')](function(){_0xc4e790(_0x3e2ace);},function(){console['log']('CANCEL');});}let _0x21a18d=!![],_0xcc50c6=0x1;_0x759bf4[_0x3915a2('0x186d')](_0x3915a2('0x1e1d'),function(_0x5e3899,_0x1f8668){const _0x1abac0=_0x3915a2;_0x21a18d?_0x2ec177(function(){_0x21a18d=![];}):(!_0x1f8668&&(_0xcc50c6=_0x5b29c4[_0x1abac0('0x23a2')][_0x1abac0('0xdf8')]),_0x5e3899!==_0x1f8668&&(_0x5b29c4['query'][_0x1abac0('0xdf8')]=0x1),!_0x5e3899&&(_0x5b29c4[_0x1abac0('0x23a2')]['page']=_0xcc50c6),_0x5b29c4[_0x1abac0('0x1a90')]());});function _0x185420(_0x4424ed){const _0x225f97=_0x3915a2;_0x5b29c4[_0x225f97('0x1410')]=_0x4424ed||{'count':0x0,'rows':[]};}function _0xa804d0(){const _0x3fd97a=_0x3915a2;_0x5b29c4['query'][_0x3fd97a('0x1cc8')]=(_0x5b29c4[_0x3fd97a('0x23a2')][_0x3fd97a('0xdf8')]-0x1)*_0x5b29c4[_0x3fd97a('0x23a2')][_0x3fd97a('0x6f0')],_0x524719[_0x3fd97a('0xca1')](_0x3fd97a('0x20c2'))?_0x5b29c4[_0x3fd97a('0x1883')]=_0x49a763[_0x3fd97a('0x2169')]['get'](_0x5b29c4[_0x3fd97a('0x23a2')],_0x185420)[_0x3fd97a('0xe53')]:(_0x5b29c4[_0x3fd97a('0x23a2')]['id']=_0x5b29c4[_0x3fd97a('0x2a')]['id'],_0x5b29c4['query'][_0x3fd97a('0x1aa')]=_0x3fd97a('0x201e'),_0x5b29c4['promise']=_0x49a763[_0x3fd97a('0x2a')][_0x3fd97a('0x241d')](_0x5b29c4[_0x3fd97a('0x23a2')],_0x185420)[_0x3fd97a('0xe53')]);}function _0x1459e3(_0x503dd2,_0x19f77d){const _0x2b2a6c=_0x3915a2;_0x39a33a[_0x2b2a6c('0x1d4')]({'controller':_0x2b2a6c('0x263f'),'controllerAs':'vm','templateUrl':_0x402de2,'parent':angular[_0x2b2a6c('0x1fcc')](_0x46f09e[_0x2b2a6c('0x18e5')]),'targetEvent':_0x503dd2,'clickOutsideToClose':!![],'locals':{'servicenowAccount':_0x19f77d,'servicenowAccounts':_0x5b29c4[_0x2b2a6c('0x1410')][_0x2b2a6c('0xf5d')],'license':_0x5b29c4['license'],'setting':_0x5b29c4[_0x2b2a6c('0x260a')],'crudPermissions':_0x5b29c4[_0x2b2a6c('0x1134')]}});}function _0xc4e790(_0x971a11){const _0x5ca160=_0x3915a2;_0x49a763[_0x5ca160('0x2169')][_0x5ca160('0xd7e')]({'id':_0x971a11['id']})[_0x5ca160('0xe53')][_0x5ca160('0x683')](function(){const _0x2ffd3f=_0x5ca160;_0x2e3ca0()[_0x2ffd3f('0x3ec')](_0x5b29c4[_0x2ffd3f('0x1410')][_0x2ffd3f('0xf5d')],{'id':_0x971a11['id']}),_0x5b29c4['servicenowAccounts'][_0x2ffd3f('0x50d')]-=0x1,!_0x5b29c4[_0x2ffd3f('0x1410')][_0x2ffd3f('0xf5d')]['length']&&_0x5b29c4[_0x2ffd3f('0x1a90')](),_0x4c2199[_0x2ffd3f('0x53')]({'title':_0x2e3ca0()[_0x2ffd3f('0x1e03')](_0x2ffd3f('0x24a0'))+_0x2ffd3f('0xbfc'),'msg':_0x971a11[_0x2ffd3f('0x60a')]?_0x971a11['name']+_0x2ffd3f('0x194d'):''});})['catch'](function(_0x1d2218){const _0x2d7c73=_0x5ca160;if(_0x1d2218[_0x2d7c73('0x5a5')]&&_0x1d2218[_0x2d7c73('0x5a5')]['errors']&&_0x1d2218['data']['errors'][_0x2d7c73('0x1564')]){_0x5b29c4[_0x2d7c73('0x17f')]=_0x1d2218['data']['errors']||[{'message':_0x1d2218[_0x2d7c73('0x1ff0')](),'type':_0x2d7c73('0x1877')}];for(let _0x38a95c=0x0;_0x38a95c<_0x1d2218['data']['errors'][_0x2d7c73('0x1564')];_0x38a95c++){_0x4c2199[_0x2d7c73('0x52a')]({'title':_0x1d2218[_0x2d7c73('0x5a5')][_0x2d7c73('0x17f')][_0x38a95c][_0x2d7c73('0xcf0')],'msg':_0x1d2218[_0x2d7c73('0x5a5')][_0x2d7c73('0x17f')][_0x38a95c][_0x2d7c73('0x8c2')]});}}else _0x4c2199[_0x2d7c73('0x52a')]({'title':_0x1d2218[_0x2d7c73('0x13ee')]?_0x2d7c73('0x2168')+_0x1d2218[_0x2d7c73('0x13ee')]+'\x20-\x20'+_0x1d2218[_0x2d7c73('0x24a9')]:'SYSTEM:DELETEintServicenowAccount','msg':_0x1d2218[_0x2d7c73('0x5a5')]?JSON[_0x2d7c73('0x258a')](_0x1d2218[_0x2d7c73('0x5a5')][_0x2d7c73('0x8c2')]):_0x1d2218[_0x2d7c73('0x8c2')]||_0x1d2218[_0x2d7c73('0x1ff0')]()});});}function _0xceceb2(){const _0x350a35=_0x3915a2,_0x21cf8d=angular[_0x350a35('0x1a86')](_0x5b29c4[_0x350a35('0x25de')]);return _0x5b29c4[_0x350a35('0x25de')]=[],_0x21cf8d;}function _0x45c887(_0x5a1a50){const _0x3e9d36=_0x3915a2,_0x57aa30=_0x39a33a['confirm']()[_0x3e9d36('0xf28')](_0x3e9d36('0x1ef'))[_0x3e9d36('0x26e3')](''+_0x5b29c4[_0x3e9d36('0x25de')]['length']+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x3e9d36('0x1040')](_0x3e9d36('0xb93'))['targetEvent'](_0x5a1a50)['ok']('OK')[_0x3e9d36('0x19fb')](_0x3e9d36('0x16b8'));_0x39a33a[_0x3e9d36('0x1d4')](_0x57aa30)[_0x3e9d36('0x683')](function(){const _0x585dc3=_0x3e9d36;_0x5b29c4[_0x585dc3('0x25de')][_0x585dc3('0x1299')](function(_0x45785e){_0xc4e790(_0x45785e);}),_0x5b29c4[_0x585dc3('0x25de')]=[];});}function _0x45a516(){const _0x1e7447=_0x3915a2;_0x5b29c4[_0x1e7447('0x25de')]=[];}function _0xf5b186(){const _0x1fc373=_0x3915a2;_0x5b29c4[_0x1fc373('0x25de')]=_0x5b29c4[_0x1fc373('0x1410')][_0x1fc373('0xf5d')];}}const _0x477350=_0x30c3ea;_0x3a2a4e[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),'sugarcrmAccounts',_0x189033('0x1bdf'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x3a2a4e(_0x28b6eb,_0x3c4dd6,_0x2e7f6a,_0x52d8d0,_0x1cfc0a,_0x2ad47a,_0x5c6061,_0x2b297d,_0x50b6c6,_0x1f4a3a,_0x515cda,_0x28d233,_0x92390a,_0x42114f){const _0x586d51=_0x189033,_0xa3f0f9=this;_0xa3f0f9[_0x586d51('0x11ed')]=_0x515cda[_0x586d51('0x20b2')](),_0xa3f0f9['errors']=[],_0xa3f0f9[_0x586d51('0x260a')]=_0x92390a,_0xa3f0f9[_0x586d51('0xace')]=_0x28d233,_0xa3f0f9[_0x586d51('0x1134')]=_0x42114f,_0xa3f0f9[_0x586d51('0x258d')]={},_0xa3f0f9['passwordPattern']=_0xa3f0f9[_0x586d51('0x260a')]&&_0xa3f0f9['setting'][_0x586d51('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xa3f0f9[_0x586d51('0xf28')]=_0x586d51('0x396'),_0xa3f0f9[_0x586d51('0x1bdf')]=angular[_0x586d51('0x1a86')](_0x50b6c6),_0xa3f0f9[_0x586d51('0x1851')]=_0x2b297d,_0xa3f0f9[_0x586d51('0x105')]=![];!_0xa3f0f9['sugarcrmAccount']&&(_0xa3f0f9[_0x586d51('0x1bdf')]={'serverUrl':_0x2e7f6a['protocol']()+_0x586d51('0x20de')+_0x2e7f6a[_0x586d51('0x19ac')]()+(_0x2e7f6a['port']()?':'+_0x2e7f6a[_0x586d51('0x4a2')]():'')},_0xa3f0f9[_0x586d51('0xf28')]='INTEGRATIONS.NEW_SUGARCRMACCOUNT',_0xa3f0f9[_0x586d51('0x105')]=!![]);_0xa3f0f9[_0x586d51('0x7d1')]=_0x275ca3,_0xa3f0f9[_0x586d51('0x19cf')]=_0x6fc26f,_0xa3f0f9[_0x586d51('0x1ce')]=_0x12b852,_0xa3f0f9['getDateFromString']=_0x2bb770,_0xa3f0f9[_0x586d51('0xf82')]=_0x60c270;function _0x275ca3(){const _0x503bf2=_0x586d51;_0xa3f0f9[_0x503bf2('0x17f')]=[],_0x1f4a3a[_0x503bf2('0x26f5')][_0x503bf2('0xb0a')](_0xa3f0f9[_0x503bf2('0x1bdf')])[_0x503bf2('0xe53')][_0x503bf2('0x683')](function(_0x152936){const _0x1a84db=_0x503bf2;_0xa3f0f9[_0x1a84db('0x1851')]['unshift'](_0x152936['toJSON']()),_0x5c6061['success']({'title':'SugarcrmAccount\x20properly\x20created','msg':_0xa3f0f9['sugarcrmAccount'][_0x1a84db('0x60a')]?_0xa3f0f9[_0x1a84db('0x1bdf')][_0x1a84db('0x60a')]+_0x1a84db('0x14b5'):''}),_0x60c270(_0x152936);})[_0x503bf2('0x130a')](function(_0x493bc9){const _0x501163=_0x503bf2;if(_0x493bc9[_0x501163('0x5a5')]&&_0x493bc9[_0x501163('0x5a5')][_0x501163('0x17f')]&&_0x493bc9[_0x501163('0x5a5')][_0x501163('0x17f')]['length']){_0xa3f0f9['errors']=_0x493bc9[_0x501163('0x5a5')][_0x501163('0x17f')]||[{'message':_0x493bc9[_0x501163('0x1ff0')](),'type':_0x501163('0x328')}];for(let _0x4bd562=0x0;_0x4bd562<_0x493bc9['data']['errors'][_0x501163('0x1564')];_0x4bd562+=0x1){_0x5c6061[_0x501163('0x52a')]({'title':_0x493bc9['data']['errors'][_0x4bd562][_0x501163('0xcf0')],'msg':_0x493bc9['data'][_0x501163('0x17f')][_0x4bd562]['message']});}}else _0x5c6061['error']({'title':_0x493bc9['status']?'API:'+_0x493bc9[_0x501163('0x13ee')]+_0x501163('0xbf6')+_0x493bc9[_0x501163('0x24a9')]:_0x501163('0x328'),'msg':_0x493bc9[_0x501163('0x5a5')]?JSON[_0x501163('0x258a')](_0x493bc9[_0x501163('0x5a5')][_0x501163('0x8c2')]):_0x493bc9[_0x501163('0x1ff0')]()});});}function _0x6fc26f(){const _0x563f77=_0x586d51;_0xa3f0f9['errors']=[],_0x1f4a3a[_0x563f77('0x26f5')]['update']({'id':_0xa3f0f9[_0x563f77('0x1bdf')]['id']},_0xa3f0f9[_0x563f77('0x1bdf')])[_0x563f77('0xe53')][_0x563f77('0x683')](function(_0x8f9ff){const _0x1755b2=_0x563f77,_0x5f07dc=_0x2e3ca0()[_0x1755b2('0x1c07')](_0xa3f0f9[_0x1755b2('0x1851')],{'id':_0x8f9ff['id']});_0x5f07dc&&_0x2e3ca0()[_0x1755b2('0xf22')](_0x5f07dc,_0x2e3ca0()[_0x1755b2('0x24d0')](_0x8f9ff['toJSON'](),_0x2e3ca0()[_0x1755b2('0x55e')](_0x5f07dc))),_0x5c6061[_0x1755b2('0x53')]({'title':'SugarcrmAccount\x20properly\x20saved!','msg':_0xa3f0f9[_0x1755b2('0x1bdf')][_0x1755b2('0x60a')]?_0xa3f0f9[_0x1755b2('0x1bdf')]['name']+_0x1755b2('0xf59'):''}),_0x60c270(_0x8f9ff);})['catch'](function(_0x3b61dd){const _0xd7b8f=_0x563f77;if(_0x3b61dd[_0xd7b8f('0x5a5')]&&_0x3b61dd['data'][_0xd7b8f('0x17f')]&&_0x3b61dd['data']['errors']['length']){_0xa3f0f9[_0xd7b8f('0x17f')]=_0x3b61dd[_0xd7b8f('0x5a5')]['errors']||[{'message':_0x3b61dd[_0xd7b8f('0x1ff0')](),'type':'api.intSugarcrmAccount.update'}];for(let _0x144925=0x0;_0x144925<_0x3b61dd[_0xd7b8f('0x5a5')]['errors'][_0xd7b8f('0x1564')];_0x144925++){_0x5c6061[_0xd7b8f('0x52a')]({'title':_0x3b61dd[_0xd7b8f('0x5a5')][_0xd7b8f('0x17f')][_0x144925]['type'],'msg':_0x3b61dd[_0xd7b8f('0x5a5')][_0xd7b8f('0x17f')][_0x144925]['message']});}}else _0x5c6061['error']({'title':_0x3b61dd[_0xd7b8f('0x13ee')]?_0xd7b8f('0x2168')+_0x3b61dd[_0xd7b8f('0x13ee')]+_0xd7b8f('0xbf6')+_0x3b61dd[_0xd7b8f('0x24a9')]:_0xd7b8f('0x164c'),'msg':_0x3b61dd[_0xd7b8f('0x5a5')]?JSON[_0xd7b8f('0x258a')](_0x3b61dd[_0xd7b8f('0x5a5')][_0xd7b8f('0x8c2')]):_0x3b61dd[_0xd7b8f('0x1ff0')]()});});}function _0x12b852(_0x5e7ca7){const _0x35def=_0x586d51;_0xa3f0f9[_0x35def('0x17f')]=[];const _0xe10ba6=_0x52d8d0[_0x35def('0x1c6f')]()['title'](_0x35def('0x4d'))[_0x35def('0xa6a')]('The\x20sugarcrmAccount\x20will\x20be\x20deleted.')['ariaLabel'](_0x35def('0x1985'))['ok'](_0x35def('0x2307'))['cancel'](_0x35def('0x253a'))['targetEvent'](_0x5e7ca7);_0x52d8d0[_0x35def('0x1d4')](_0xe10ba6)[_0x35def('0x683')](function(){const _0x3c0d56=_0x35def;_0x1f4a3a[_0x3c0d56('0x26f5')]['delete']({'id':_0xa3f0f9[_0x3c0d56('0x1bdf')]['id']})[_0x3c0d56('0xe53')][_0x3c0d56('0x683')](function(){const _0x52c181=_0x3c0d56;_0x2e3ca0()[_0x52c181('0x3ec')](_0xa3f0f9['sugarcrmAccounts'],{'id':_0xa3f0f9[_0x52c181('0x1bdf')]['id']}),_0x5c6061['success']({'title':_0x52c181('0xa3d'),'msg':(_0xa3f0f9[_0x52c181('0x1bdf')][_0x52c181('0x60a')]||'sugarcrmAccount')+_0x52c181('0x194d')}),_0x60c270(_0xa3f0f9[_0x52c181('0x1bdf')]);})[_0x3c0d56('0x130a')](function(_0x403b92){const _0x2eefd9=_0x3c0d56;if(_0x403b92[_0x2eefd9('0x5a5')]&&_0x403b92['data']['errors']&&_0x403b92[_0x2eefd9('0x5a5')][_0x2eefd9('0x17f')][_0x2eefd9('0x1564')]){_0xa3f0f9[_0x2eefd9('0x17f')]=_0x403b92[_0x2eefd9('0x5a5')][_0x2eefd9('0x17f')]||[{'message':_0x403b92['toString'](),'type':_0x2eefd9('0x1b5e')}];for(let _0x2c8709=0x0;_0x2c8709<_0x403b92[_0x2eefd9('0x5a5')][_0x2eefd9('0x17f')][_0x2eefd9('0x1564')];_0x2c8709++){_0x5c6061[_0x2eefd9('0x52a')]({'title':_0x403b92[_0x2eefd9('0x5a5')][_0x2eefd9('0x17f')][_0x2c8709][_0x2eefd9('0xcf0')],'msg':_0x403b92[_0x2eefd9('0x5a5')][_0x2eefd9('0x17f')][_0x2c8709][_0x2eefd9('0x8c2')]});}}else _0x5c6061[_0x2eefd9('0x52a')]({'title':_0x403b92['status']?'API:'+_0x403b92[_0x2eefd9('0x13ee')]+_0x2eefd9('0xbf6')+_0x403b92[_0x2eefd9('0x24a9')]:_0x2eefd9('0x1b5e'),'msg':_0x403b92['data']?JSON[_0x2eefd9('0x258a')](_0x403b92['data']['message']):_0x403b92[_0x2eefd9('0x8c2')]||_0x403b92[_0x2eefd9('0x1ff0')]()});});},function(){});}function _0x2bb770(_0x2f6bd9){return _0x2f6bd9===null?undefined:new Date(_0x2f6bd9);}function _0x60c270(_0x5afaf5){_0x52d8d0['hide'](_0x5afaf5);}}const _0x9b488c=_0x3a2a4e,_0x28f305=_0x180212['p']+'src/js/modules/main/apps/integrations/views/sugarcrmAccounts/edit/configurations/dialog.html/dialog.html',_0x22d9ab=_0x180212['p']+_0x189033('0x713');_0x42a7fc[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$document','api',_0x189033('0x1d70'),_0x189033('0xba1')];function _0x42a7fc(_0x3dc170,_0x2cefa8,_0x424f20,_0x1b863d,_0xa13a1e){const _0x2ac221=_0x189033,_0x52b2ed=this;_0x52b2ed['currentUser']=_0xa13a1e[_0x2ac221('0x20b2')](),_0x52b2ed[_0x2ac221('0x1bdf')]={},_0x52b2ed[_0x2ac221('0x7d7')]={},_0x52b2ed[_0x2ac221('0x1573')]=[],_0x52b2ed[_0x2ac221('0x366')]=-0x1,_0x52b2ed['crudPermissions'],_0x52b2ed[_0x2ac221('0x12f3')]=_0x3a1c8e,_0x52b2ed['getSugarcrmConfiguration']=_0x1f68f0,_0x52b2ed[_0x2ac221('0xf4e')]=_0x55b6fb,_0x52b2ed[_0x2ac221('0xfec')]=_0x35390b;function _0x3a1c8e(_0x44f2d9,_0x171b41){const _0x2db7b4=_0x2ac221;_0x52b2ed[_0x2db7b4('0x1bdf')]=_0x44f2d9,_0x52b2ed[_0x2db7b4('0x1134')]=typeof _0x171b41!=='undefined'?_0x171b41:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x424f20[_0x2db7b4('0x26f5')][_0x2db7b4('0x1575')]({'id':_0x52b2ed['sugarcrmAccount']['id'],'sort':_0x2db7b4('0xc36')})['$promise'][_0x2db7b4('0x683')](function(_0x2678ee){const _0x318e2e=_0x2db7b4;return _0x52b2ed['configurations']=_0x2678ee[_0x318e2e('0xf5d')]?_0x2678ee[_0x318e2e('0xf5d')]:[],_0x52b2ed[_0x318e2e('0x1573')]['length']&&_0x52b2ed[_0x318e2e('0x2443')](0x0),_0x424f20['variable']['get']({'nolimit':!![],'sort':_0x318e2e('0x60a')})['$promise'];})[_0x2db7b4('0x683')](function(_0x5d05c6){const _0x51340d=_0x2db7b4;_0x52b2ed['variables']=_0x5d05c6[_0x51340d('0xf5d')]?_0x5d05c6[_0x51340d('0xf5d')]:[],_0x52b2ed[_0x51340d('0x1822')]=_0x2e3ca0()[_0x51340d('0x24db')](_0x52b2ed[_0x51340d('0x220b')],'id');})[_0x2db7b4('0x130a')](function(_0x5bd127){const _0x251d7d=_0x2db7b4;_0x1b863d[_0x251d7d('0x52a')]({'title':_0x5bd127['status']?_0x251d7d('0x2168')+_0x5bd127[_0x251d7d('0x13ee')]+_0x251d7d('0xbf6')+_0x5bd127[_0x251d7d('0x24a9')]:_0x251d7d('0xe2a'),'msg':_0x5bd127[_0x251d7d('0x5a5')]?JSON[_0x251d7d('0x258a')](_0x5bd127[_0x251d7d('0x5a5')]):_0x5bd127[_0x251d7d('0x1ff0')]()});});}function _0x1f68f0(_0x495d3e){const _0x47153a=_0x2ac221;_0x52b2ed[_0x47153a('0x7d7')]=_0x52b2ed['configurations'][_0x495d3e],_0x52b2ed['selectedSugarcrmConfiguration']=_0x495d3e,_0x424f20['intSugarcrmConfiguration'][_0x47153a('0x20ac')]({'id':_0x52b2ed[_0x47153a('0x7d7')]['id']})[_0x47153a('0xe53')][_0x47153a('0x683')](function(_0x2878ed){const _0x193886=_0x47153a;return _0x52b2ed[_0x193886('0x1ead')]=_0x2878ed[_0x193886('0xf5d')]?_0x2878ed[_0x193886('0xf5d')]:[],_0x424f20[_0x193886('0x9d8')][_0x193886('0x412')]({'id':_0x52b2ed[_0x193886('0x7d7')]['id']})['$promise'];})[_0x47153a('0x683')](function(_0x48525e){const _0x5f6732=_0x47153a;return _0x52b2ed[_0x5f6732('0x18f7')]=_0x48525e[_0x5f6732('0xf5d')]?_0x48525e[_0x5f6732('0xf5d')]:[],_0x424f20[_0x5f6732('0x9d8')][_0x5f6732('0x298')]({'id':_0x52b2ed['sugarcrmConfiguration']['id']})[_0x5f6732('0xe53')];})['then'](function(_0x360963){const _0x24d36b=_0x47153a;_0x52b2ed[_0x24d36b('0x189a')]=_0x360963[_0x24d36b('0xf5d')]?_0x360963['rows']:[];})[_0x47153a('0x130a')](function(_0x2d2584){const _0x1d9725=_0x47153a;_0x1b863d[_0x1d9725('0x52a')]({'title':_0x2d2584[_0x1d9725('0x13ee')]?_0x1d9725('0x2168')+_0x2d2584[_0x1d9725('0x13ee')]+_0x1d9725('0xbf6')+_0x2d2584[_0x1d9725('0x24a9')]:'SYSTEM:GETConfigurations','msg':_0x2d2584[_0x1d9725('0x5a5')]?JSON[_0x1d9725('0x258a')](_0x2d2584[_0x1d9725('0x5a5')]):_0x2d2584[_0x1d9725('0x1ff0')]()});});}function _0x55b6fb(_0x4e5329,_0x40e8e1){const _0x570d6a=_0x2ac221;_0x3dc170['show']({'controller':'CreateOrEditSugarcrmConfigurationDialogController','controllerAs':'vm','templateUrl':_0x28f305,'parent':angular[_0x570d6a('0x1fcc')](_0x2cefa8[_0x570d6a('0x18e5')]),'targetEvent':_0x4e5329,'clickOutsideToClose':!![],'locals':{'sugarcrmConfiguration':_0x40e8e1,'configurations':_0x52b2ed[_0x570d6a('0x1573')],'license':null,'setting':null,'crudPermissions':_0x52b2ed[_0x570d6a('0x1134')]}})['finally'](function(){const _0x3db395=_0x570d6a;_0x52b2ed[_0x3db395('0x2443')](0x0);});}function _0x35390b(_0x472475,_0x2a9ee6){const _0x5dd9a1=_0x2ac221,_0x165668=_0x3dc170[_0x5dd9a1('0x1c6f')]()[_0x5dd9a1('0xf28')](_0x5dd9a1('0x1c98'))[_0x5dd9a1('0x26e3')](''+(_0x2a9ee6[_0x5dd9a1('0x60a')]||_0x5dd9a1('0x7d7'))+_0x5dd9a1('0x20f1')+_0x5dd9a1('0x1ee7'))['ariaLabel'](_0x5dd9a1('0x1557'))['targetEvent'](_0x472475)['ok']('OK')[_0x5dd9a1('0x19fb')](_0x5dd9a1('0x16b8'));_0x3dc170[_0x5dd9a1('0x1d4')](_0x165668)['then'](function(){const _0x439280=_0x5dd9a1;_0x424f20['intSugarcrmConfiguration'][_0x439280('0xd7e')]({'id':_0x2a9ee6['id']})['$promise']['then'](function(){const _0x5294e7=_0x439280;_0x2e3ca0()[_0x5294e7('0x3ec')](_0x52b2ed[_0x5294e7('0x1573')],{'id':_0x2a9ee6['id']}),_0x1b863d[_0x5294e7('0x53')]({'title':_0x5294e7('0xaad'),'msg':_0x2a9ee6['name']?_0x2a9ee6[_0x5294e7('0x60a')]+_0x5294e7('0x194d'):''});})[_0x439280('0x130a')](function(_0x1bdd36){const _0x210192=_0x439280;_0x1b863d[_0x210192('0x52a')]({'title':_0x1bdd36[_0x210192('0x13ee')]?'API:'+_0x1bdd36['status']+_0x210192('0xbf6')+_0x1bdd36['statusText']:_0x210192('0x1e44'),'msg':_0x1bdd36[_0x210192('0x5a5')]?JSON[_0x210192('0x258a')](_0x1bdd36['data']):_0x1bdd36[_0x210192('0x1ff0')]()});})[_0x439280('0x2874')](function(){const _0x60c3bb=_0x439280;_0x52b2ed[_0x60c3bb('0x2443')](0x0);});},function(){const _0xddd213=_0x5dd9a1;console['log'](_0xddd213('0x16b8'));});}_0x52b2ed[_0x2ac221('0x1781')]=[],_0x52b2ed['createOrEditSubject']=_0x1d4440,_0x52b2ed[_0x2ac221('0x2802')]=_0x447bca,_0x52b2ed[_0x2ac221('0x1734')]=_0x285edb;function _0x1d4440(_0x3b3678,_0xd1b262){const _0x19efe7=_0x2ac221;_0x3dc170[_0x19efe7('0x1d4')]({'controller':_0x19efe7('0xbed'),'controllerAs':'vm','templateUrl':_0x22d9ab,'parent':angular[_0x19efe7('0x1fcc')](_0x2cefa8[_0x19efe7('0x18e5')]),'targetEvent':_0x3b3678,'clickOutsideToClose':!![],'locals':{'type':_0x19efe7('0x1e66'),'item':_0xd1b262,'items':_0x52b2ed[_0x19efe7('0x1ead')],'configuration':_0x52b2ed[_0x19efe7('0x7d7')],'account':_0x52b2ed[_0x19efe7('0x1bdf')],'license':null,'setting':null,'crudPermissions':_0x52b2ed[_0x19efe7('0x1134')]}});}function _0x30f8a3(_0x2adc19){const _0x522ddc=_0x2ac221;_0x424f20[_0x522ddc('0x1007')]['delete']({'id':_0x2adc19['id']})[_0x522ddc('0xe53')][_0x522ddc('0x683')](function(){const _0x385a48=_0x522ddc;_0x2e3ca0()[_0x385a48('0x3ec')](_0x52b2ed[_0x385a48('0x1ead')],{'id':_0x2adc19['id']}),_0x1b863d[_0x385a48('0x53')]({'title':_0x385a48('0x637'),'msg':_0x385a48('0x2795')});})['catch'](function(_0x4c805c){const _0x2be69e=_0x522ddc;_0x1b863d[_0x2be69e('0x52a')]({'title':_0x4c805c[_0x2be69e('0x13ee')]?_0x2be69e('0x2168')+_0x4c805c['status']+_0x2be69e('0xbf6')+_0x4c805c[_0x2be69e('0x24a9')]:_0x2be69e('0x1d23'),'msg':_0x4c805c[_0x2be69e('0x5a5')]?JSON['stringify'](_0x4c805c[_0x2be69e('0x5a5')]):_0x4c805c[_0x2be69e('0x1ff0')]()});});}function _0x447bca(_0x1ab1a1,_0x304527){const _0x1c0e6e=_0x2ac221,_0x5ad1d3=_0x3dc170['confirm']()['title'](_0x1c0e6e('0x17ed'))[_0x1c0e6e('0x26e3')]('Subject'+'\x20will\x20be\x20deleted.')[_0x1c0e6e('0x1040')](_0x1c0e6e('0x20d'))['targetEvent'](_0x1ab1a1)['ok']('OK')[_0x1c0e6e('0x19fb')](_0x1c0e6e('0x16b8'));_0x3dc170[_0x1c0e6e('0x1d4')](_0x5ad1d3)[_0x1c0e6e('0x683')](function(){_0x30f8a3(_0x304527);},function(){const _0x4aab8f=_0x1c0e6e;console['log'](_0x4aab8f('0x16b8'));});}function _0x285edb(_0x508ed2){const _0x1dfd4f=_0x2ac221,_0x538eff=_0x3dc170[_0x1dfd4f('0x1c6f')]()[_0x1dfd4f('0xf28')](_0x1dfd4f('0xad5'))[_0x1dfd4f('0x26e3')](_0x1dfd4f('0xed5')+_0x52b2ed['selectedSubjects'][_0x1dfd4f('0x1564')]+_0x1dfd4f('0x93c')+_0x1dfd4f('0x1ee7'))[_0x1dfd4f('0x1040')](_0x1dfd4f('0x9fb'))[_0x1dfd4f('0xe42')](_0x508ed2)['ok']('OK')[_0x1dfd4f('0x19fb')](_0x1dfd4f('0x16b8'));_0x3dc170[_0x1dfd4f('0x1d4')](_0x538eff)[_0x1dfd4f('0x683')](function(){const _0xa952e7=_0x1dfd4f;_0x52b2ed[_0xa952e7('0x1781')][_0xa952e7('0x1299')](function(_0x11ab6d){_0x30f8a3(_0x11ab6d);}),_0x52b2ed[_0xa952e7('0x1781')]=[];});}_0x52b2ed[_0x2ac221('0xcb1')]=[],_0x52b2ed[_0x2ac221('0x1094')]=_0x1e9ccb,_0x52b2ed[_0x2ac221('0x27b2')]=_0x3af138,_0x52b2ed['deleteSelectedDescriptions']=_0x23882f;function _0x1e9ccb(_0x161bfc,_0x91c79){const _0x360d3b=_0x2ac221;_0x3dc170['show']({'controller':_0x360d3b('0xbed'),'controllerAs':'vm','templateUrl':_0x22d9ab,'parent':angular['element'](_0x2cefa8[_0x360d3b('0x18e5')]),'targetEvent':_0x161bfc,'clickOutsideToClose':!![],'locals':{'type':_0x360d3b('0xd6b'),'item':_0x91c79,'items':_0x52b2ed[_0x360d3b('0x18f7')],'configuration':_0x52b2ed[_0x360d3b('0x7d7')],'account':_0x52b2ed[_0x360d3b('0x1bdf')],'license':null,'setting':null,'crudPermissions':_0x52b2ed[_0x360d3b('0x1134')]}});}function _0x79a625(_0xa0f5c6){const _0x42c18f=_0x2ac221;_0x424f20['intSugarcrmField'][_0x42c18f('0xd7e')]({'id':_0xa0f5c6['id']})[_0x42c18f('0xe53')]['then'](function(){const _0xa942a9=_0x42c18f;_0x2e3ca0()[_0xa942a9('0x3ec')](_0x52b2ed[_0xa942a9('0x18f7')],{'id':_0xa0f5c6['id']}),_0x1b863d['success']({'title':_0xa942a9('0x1cf8'),'msg':'Description\x20has\x20been\x20deleted!'});})[_0x42c18f('0x130a')](function(_0x584043){const _0x12f24e=_0x42c18f;_0x1b863d[_0x12f24e('0x52a')]({'title':_0x584043[_0x12f24e('0x13ee')]?_0x12f24e('0x2168')+_0x584043[_0x12f24e('0x13ee')]+_0x12f24e('0xbf6')+_0x584043[_0x12f24e('0x24a9')]:_0x12f24e('0x1d23'),'msg':_0x584043[_0x12f24e('0x5a5')]?JSON[_0x12f24e('0x258a')](_0x584043[_0x12f24e('0x5a5')]):_0x584043[_0x12f24e('0x1ff0')]()});});}function _0x3af138(_0x5f36bc,_0x4aff9f){const _0x5781fb=_0x2ac221,_0x1eb97f=_0x3dc170[_0x5781fb('0x1c6f')]()[_0x5781fb('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20description?')[_0x5781fb('0x26e3')]('Description'+_0x5781fb('0x1ee7'))['ariaLabel'](_0x5781fb('0x221c'))['targetEvent'](_0x5f36bc)['ok']('OK')[_0x5781fb('0x19fb')](_0x5781fb('0x16b8'));_0x3dc170[_0x5781fb('0x1d4')](_0x1eb97f)[_0x5781fb('0x683')](function(){_0x79a625(_0x4aff9f);},function(){const _0x13ab3=_0x5781fb;console[_0x13ab3('0x1b2b')]('CANCEL');});}function _0x23882f(_0x256c62){const _0x1cbc2c=_0x2ac221,_0x5e9276=_0x3dc170[_0x1cbc2c('0x1c6f')]()[_0x1cbc2c('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20descriptions?')[_0x1cbc2c('0x26e3')](_0x1cbc2c('0xed5')+_0x52b2ed[_0x1cbc2c('0xcb1')][_0x1cbc2c('0x1564')]+_0x1cbc2c('0x93c')+_0x1cbc2c('0x1ee7'))[_0x1cbc2c('0x1040')](_0x1cbc2c('0x1859'))[_0x1cbc2c('0xe42')](_0x256c62)['ok']('OK')['cancel']('CANCEL');_0x3dc170[_0x1cbc2c('0x1d4')](_0x5e9276)[_0x1cbc2c('0x683')](function(){const _0xa4b5af=_0x1cbc2c;_0x52b2ed[_0xa4b5af('0xcb1')][_0xa4b5af('0x1299')](function(_0x5f07e0){_0x79a625(_0x5f07e0);}),_0x52b2ed[_0xa4b5af('0xcb1')]=[];});}_0x52b2ed[_0x2ac221('0x310')]=[],_0x52b2ed[_0x2ac221('0x84f')]=_0x34b1b0,_0x52b2ed[_0x2ac221('0x9f9')]=_0x1f4900,_0x52b2ed[_0x2ac221('0x204e')]=_0x13586d;function _0x34b1b0(_0x8ba9dc,_0xbbed10){const _0x392e85=_0x2ac221;_0x3dc170['show']({'controller':_0x392e85('0xbed'),'controllerAs':'vm','templateUrl':_0x22d9ab,'parent':angular[_0x392e85('0x1fcc')](_0x2cefa8[_0x392e85('0x18e5')]),'targetEvent':_0x8ba9dc,'clickOutsideToClose':!![],'locals':{'type':_0x392e85('0x2013'),'item':_0xbbed10,'items':_0x52b2ed[_0x392e85('0x189a')],'configuration':_0x52b2ed['sugarcrmConfiguration'],'account':_0x52b2ed[_0x392e85('0x1bdf')],'license':null,'setting':null,'crudPermissions':_0x52b2ed['crudPermissions']}});}function _0x32c071(_0x3c336f){const _0x4147f9=_0x2ac221;_0x424f20[_0x4147f9('0x1007')]['delete']({'id':_0x3c336f['id']})[_0x4147f9('0xe53')][_0x4147f9('0x683')](function(){const _0x505f36=_0x4147f9;_0x2e3ca0()['remove'](_0x52b2ed[_0x505f36('0x189a')],{'id':_0x3c336f['id']}),_0x1b863d[_0x505f36('0x53')]({'title':_0x505f36('0x1666'),'msg':_0x505f36('0x1eda')});})['catch'](function(_0x806254){const _0x1ff75c=_0x4147f9;_0x1b863d['error']({'title':_0x806254[_0x1ff75c('0x13ee')]?_0x1ff75c('0x2168')+_0x806254[_0x1ff75c('0x13ee')]+_0x1ff75c('0xbf6')+_0x806254[_0x1ff75c('0x24a9')]:_0x1ff75c('0x1d23'),'msg':_0x806254[_0x1ff75c('0x5a5')]?JSON['stringify'](_0x806254['data']):_0x806254['toString']()});});}function _0x1f4900(_0x11018d,_0x23a5f9){const _0x1c9752=_0x2ac221,_0x49af9d=_0x3dc170[_0x1c9752('0x1c6f')]()[_0x1c9752('0xf28')](_0x1c9752('0x16b5'))['htmlContent']('Field'+'\x20will\x20be\x20deleted.')['ariaLabel']('delete\x20field')[_0x1c9752('0xe42')](_0x11018d)['ok']('OK')[_0x1c9752('0x19fb')](_0x1c9752('0x16b8'));_0x3dc170[_0x1c9752('0x1d4')](_0x49af9d)[_0x1c9752('0x683')](function(){_0x32c071(_0x23a5f9);},function(){const _0x216c96=_0x1c9752;console[_0x216c96('0x1b2b')](_0x216c96('0x16b8'));});}function _0x13586d(_0x5a3b1c){const _0x186110=_0x2ac221,_0x35743c=_0x3dc170['confirm']()[_0x186110('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20fields?')[_0x186110('0x26e3')](''+_0x52b2ed[_0x186110('0x310')]['length']+_0x186110('0x93c')+_0x186110('0x1ee7'))[_0x186110('0x1040')](_0x186110('0x994'))['targetEvent'](_0x5a3b1c)['ok']('OK')[_0x186110('0x19fb')](_0x186110('0x16b8'));_0x3dc170[_0x186110('0x1d4')](_0x35743c)[_0x186110('0x683')](function(){const _0x4d0ef6=_0x186110;_0x52b2ed[_0x4d0ef6('0x310')][_0x4d0ef6('0x1299')](function(_0xc74c4e){_0x32c071(_0xc74c4e);}),_0x52b2ed[_0x4d0ef6('0x310')]=[];});}}const _0xc72a12=_0x42a7fc;_0x5d8f07[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),'configurations',_0x189033('0x7d7'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x5d8f07(_0x3d2ad6,_0x3bf77f,_0x562ca1,_0x2503f5,_0x4009fe,_0x1103e8,_0x1744bd,_0x5381d1,_0x2451c8,_0x327310,_0x26d41f,_0x8c25d6,_0x28445a,_0x2e228f){const _0x31c727=_0x189033,_0x4f9439=this;_0x4f9439[_0x31c727('0x11ed')]=_0x26d41f['getCurrentUser'](),_0x4f9439[_0x31c727('0x17f')]=[],_0x4f9439[_0x31c727('0x260a')]=_0x28445a,_0x4f9439[_0x31c727('0xace')]=_0x8c25d6,_0x4f9439['crudPermissions']=_0x2e228f,_0x4f9439['hasModulePermissions']={},_0x4f9439[_0x31c727('0x19b2')]=_0x4f9439['setting']&&_0x4f9439[_0x31c727('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4f9439[_0x31c727('0xf28')]='INTEGRATIONS.EDIT_SUGARCRMCONFIGURATION',_0x4f9439[_0x31c727('0x7d7')]=angular[_0x31c727('0x1a86')](_0x2451c8),_0x4f9439['configurations']=_0x5381d1,_0x4f9439['newSugarcrmConfiguration']=![];!_0x4f9439['sugarcrmConfiguration']&&(_0x4f9439[_0x31c727('0x7d7')]={'channel':_0x31c727('0xcf2'),'type':_0x31c727('0x1535')},_0x4f9439['title']=_0x31c727('0x126c'),_0x4f9439[_0x31c727('0x13df')]=!![]);_0x4f9439[_0x31c727('0x2215')]=_0x26c5c2,_0x4f9439[_0x31c727('0x1fd8')]=_0x2b8558,_0x4f9439[_0x31c727('0xfec')]=_0x3a530c,_0x4f9439[_0x31c727('0x16b3')]=_0x3e081f,_0x4f9439['closeDialog']=_0x2977bb;function _0x26c5c2(){const _0x24ac61=_0x31c727;_0x4f9439[_0x24ac61('0x17f')]=[],_0x327310[_0x24ac61('0x26f5')][_0x24ac61('0x2003')]({'id':_0x3bf77f[_0x24ac61('0x7f2')]['id']},_0x4f9439['sugarcrmConfiguration'])[_0x24ac61('0xe53')][_0x24ac61('0x683')](function(_0x3994a9){const _0x1d002b=_0x24ac61;_0x4f9439[_0x1d002b('0x1573')]['unshift'](_0x3994a9[_0x1d002b('0x24e1')]()),_0x1744bd['success']({'title':_0x1d002b('0x18f3'),'msg':_0x4f9439[_0x1d002b('0x7d7')][_0x1d002b('0x60a')]?_0x4f9439['sugarcrmConfiguration'][_0x1d002b('0x60a')]+_0x1d002b('0x14b5'):''}),_0x2977bb(_0x3994a9);})[_0x24ac61('0x130a')](function(_0x17c467){const _0x47dc30=_0x24ac61;if(_0x17c467[_0x47dc30('0x5a5')]&&_0x17c467[_0x47dc30('0x5a5')][_0x47dc30('0x17f')]&&_0x17c467['data'][_0x47dc30('0x17f')]['length']){_0x4f9439[_0x47dc30('0x17f')]=_0x17c467[_0x47dc30('0x5a5')][_0x47dc30('0x17f')]||[{'message':_0x17c467[_0x47dc30('0x1ff0')](),'type':_0x47dc30('0x16e8')}];for(let _0x327086=0x0;_0x327086<_0x17c467[_0x47dc30('0x5a5')]['errors'][_0x47dc30('0x1564')];_0x327086+=0x1){_0x1744bd[_0x47dc30('0x52a')]({'title':_0x17c467[_0x47dc30('0x5a5')][_0x47dc30('0x17f')][_0x327086][_0x47dc30('0xcf0')],'msg':_0x17c467[_0x47dc30('0x5a5')][_0x47dc30('0x17f')][_0x327086][_0x47dc30('0x8c2')]});}}else _0x1744bd['error']({'title':_0x17c467[_0x47dc30('0x13ee')]?_0x47dc30('0x2168')+_0x17c467['status']+_0x47dc30('0xbf6')+_0x17c467[_0x47dc30('0x24a9')]:_0x47dc30('0x16e8'),'msg':_0x17c467[_0x47dc30('0x5a5')]?JSON[_0x47dc30('0x258a')](_0x17c467[_0x47dc30('0x5a5')][_0x47dc30('0x8c2')]):_0x17c467['toString']()});});}function _0x2b8558(){const _0x1bf0d6=_0x31c727;_0x4f9439[_0x1bf0d6('0x17f')]=[],_0x327310[_0x1bf0d6('0x9d8')][_0x1bf0d6('0x2480')]({'id':_0x4f9439[_0x1bf0d6('0x7d7')]['id']},_0x4f9439[_0x1bf0d6('0x7d7')])[_0x1bf0d6('0xe53')][_0x1bf0d6('0x683')](function(_0x2d9c60){const _0x34dc4a=_0x1bf0d6,_0x3e2700=_0x2e3ca0()[_0x34dc4a('0x1c07')](_0x4f9439[_0x34dc4a('0x1573')],{'id':_0x2d9c60['id']});_0x3e2700&&_0x2e3ca0()[_0x34dc4a('0xf22')](_0x3e2700,_0x2e3ca0()[_0x34dc4a('0x24d0')](_0x2d9c60[_0x34dc4a('0x24e1')](),_0x2e3ca0()[_0x34dc4a('0x55e')](_0x3e2700))),_0x1744bd['success']({'title':_0x34dc4a('0x24b0'),'msg':_0x4f9439['sugarcrmConfiguration'][_0x34dc4a('0x60a')]?_0x4f9439[_0x34dc4a('0x7d7')][_0x34dc4a('0x60a')]+_0x34dc4a('0xf59'):''}),_0x2977bb(_0x2d9c60);})[_0x1bf0d6('0x130a')](function(_0x291c64){const _0x2076fc=_0x1bf0d6;if(_0x291c64[_0x2076fc('0x5a5')]&&_0x291c64[_0x2076fc('0x5a5')][_0x2076fc('0x17f')]&&_0x291c64[_0x2076fc('0x5a5')][_0x2076fc('0x17f')][_0x2076fc('0x1564')]){_0x4f9439[_0x2076fc('0x17f')]=_0x291c64['data'][_0x2076fc('0x17f')]||[{'message':_0x291c64[_0x2076fc('0x1ff0')](),'type':_0x2076fc('0x5fd')}];for(let _0x4cb7e5=0x0;_0x4cb7e5<_0x291c64['data'][_0x2076fc('0x17f')][_0x2076fc('0x1564')];_0x4cb7e5++){_0x1744bd['error']({'title':_0x291c64['data'][_0x2076fc('0x17f')][_0x4cb7e5][_0x2076fc('0xcf0')],'msg':_0x291c64[_0x2076fc('0x5a5')]['errors'][_0x4cb7e5][_0x2076fc('0x8c2')]});}}else _0x1744bd[_0x2076fc('0x52a')]({'title':_0x291c64[_0x2076fc('0x13ee')]?_0x2076fc('0x2168')+_0x291c64[_0x2076fc('0x13ee')]+_0x2076fc('0xbf6')+_0x291c64['statusText']:_0x2076fc('0x5fd'),'msg':_0x291c64[_0x2076fc('0x5a5')]?JSON[_0x2076fc('0x258a')](_0x291c64[_0x2076fc('0x5a5')][_0x2076fc('0x8c2')]):_0x291c64[_0x2076fc('0x1ff0')]()});});}function _0x3a530c(_0x5a0230){const _0x7fc223=_0x31c727;_0x4f9439[_0x7fc223('0x17f')]=[];const _0x206a31=_0x2503f5[_0x7fc223('0x1c6f')]()[_0x7fc223('0xf28')](_0x7fc223('0x4d'))['content']('The\x20sugarcrmConfiguration\x20will\x20be\x20deleted.')[_0x7fc223('0x1040')](_0x7fc223('0x96d'))['ok'](_0x7fc223('0x2307'))[_0x7fc223('0x19fb')](_0x7fc223('0x253a'))[_0x7fc223('0xe42')](_0x5a0230);_0x2503f5['show'](_0x206a31)[_0x7fc223('0x683')](function(){const _0x4dcfae=_0x7fc223;_0x327310[_0x4dcfae('0x9d8')][_0x4dcfae('0xd7e')]({'id':_0x4f9439['sugarcrmConfiguration']['id']})[_0x4dcfae('0xe53')][_0x4dcfae('0x683')](function(){const _0x206358=_0x4dcfae;_0x2e3ca0()[_0x206358('0x3ec')](_0x4f9439['configurations'],{'id':_0x4f9439[_0x206358('0x7d7')]['id']}),_0x1744bd[_0x206358('0x53')]({'title':_0x206358('0xacd'),'msg':(_0x4f9439[_0x206358('0x7d7')][_0x206358('0x60a')]||_0x206358('0x7d7'))+_0x206358('0x194d')}),_0x2977bb(_0x4f9439[_0x206358('0x7d7')]);})[_0x4dcfae('0x130a')](function(_0x268b29){const _0x49198f=_0x4dcfae;if(_0x268b29[_0x49198f('0x5a5')]&&_0x268b29['data'][_0x49198f('0x17f')]&&_0x268b29[_0x49198f('0x5a5')]['errors'][_0x49198f('0x1564')]){_0x4f9439['errors']=_0x268b29[_0x49198f('0x5a5')][_0x49198f('0x17f')]||[{'message':_0x268b29['toString'](),'type':_0x49198f('0x1a04')}];for(let _0x46b0f5=0x0;_0x46b0f5<_0x268b29[_0x49198f('0x5a5')][_0x49198f('0x17f')][_0x49198f('0x1564')];_0x46b0f5++){_0x1744bd[_0x49198f('0x52a')]({'title':_0x268b29[_0x49198f('0x5a5')][_0x49198f('0x17f')][_0x46b0f5]['type'],'msg':_0x268b29['data'][_0x49198f('0x17f')][_0x46b0f5][_0x49198f('0x8c2')]});}}else _0x1744bd[_0x49198f('0x52a')]({'title':_0x268b29[_0x49198f('0x13ee')]?'API:'+_0x268b29[_0x49198f('0x13ee')]+_0x49198f('0xbf6')+_0x268b29[_0x49198f('0x24a9')]:'api.intSugarcrmConfiguration.delete','msg':_0x268b29[_0x49198f('0x5a5')]?JSON[_0x49198f('0x258a')](_0x268b29[_0x49198f('0x5a5')]['message']):_0x268b29[_0x49198f('0x8c2')]||_0x268b29[_0x49198f('0x1ff0')]()});});},function(){});}function _0x3e081f(_0xd160d0){return _0xd160d0===null?undefined:new Date(_0xd160d0);}function _0x2977bb(_0x4f49d9){const _0xa24852=_0x31c727;_0x2503f5[_0xa24852('0x1715')](_0x4f49d9);}}const _0x12e726=_0x5d8f07;_0x22fdc3['$inject']=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),'$mdDialog',_0x189033('0x1d70'),_0x189033('0x208d'),_0x189033('0x1996'),_0x189033('0x23ef'),_0x189033('0x1d2f'),_0x189033('0xcf0'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x22fdc3(_0x5cb541,_0x957e36,_0x275919,_0x28a4ed,_0x2fc37b,_0x35893b,_0x968c7b,_0x85ad85,_0x2c3512,_0x187f0d,_0x120ca2,_0x33b010,_0x223fa2){const _0x612cfa=_0x189033,_0x491bd6=this;_0x491bd6[_0x612cfa('0x11ed')]=_0x33b010[_0x612cfa('0x20b2')](),_0x491bd6['errors']=[],_0x491bd6[_0x612cfa('0xf28')]=_0x612cfa('0x176c')+_0x2e3ca0()[_0x612cfa('0x65')](_0x187f0d),_0x491bd6[_0x612cfa('0x23ef')]=angular[_0x612cfa('0x1a86')](_0x85ad85),_0x491bd6[_0x612cfa('0x1996')]=_0x968c7b,_0x491bd6[_0x612cfa('0xcf0')]=_0x187f0d,_0x491bd6[_0x612cfa('0x1134')]=_0x223fa2,_0x491bd6[_0x612cfa('0x3d2')]=![];!_0x491bd6[_0x612cfa('0x23ef')]&&(_0x491bd6['item']={'type':_0x612cfa('0xc06')},_0x491bd6[_0x612cfa('0x23ef')][_0x2e3ca0()[_0x612cfa('0x21ab')](_0x187f0d)+'Id']=_0x35893b['id'],_0x491bd6['title']=_0x612cfa('0x22de')+_0x2e3ca0()['toUpper'](_0x187f0d),_0x491bd6[_0x612cfa('0x3d2')]=!![]);_0x491bd6[_0x612cfa('0x2591')]=_0x658ebb,_0x491bd6['saveItem']=_0x1e78d5,_0x491bd6[_0x612cfa('0x6b8')]=_0x4f1874,_0x491bd6[_0x612cfa('0x18a')]=_0x2aeef1,_0x491bd6[_0x612cfa('0xf82')]=_0x418e2e,_0x120ca2[_0x612cfa('0x26e0')][_0x612cfa('0x1e6e')]({'nolimit':!![]})[_0x612cfa('0xe53')][_0x612cfa('0x683')](function(_0x276bf5){const _0x54a55d=_0x612cfa;return _0x491bd6['variables']=_0x276bf5['rows']?_0x276bf5[_0x54a55d('0xf5d')]:[],_0x120ca2[_0x54a55d('0xf53')]['describe']()[_0x54a55d('0xe53')];})[_0x612cfa('0x683')](function(_0xc795fd){const _0x376299=_0x612cfa;return _0x491bd6[_0x376299('0x20c1')]=_0x2e3ca0()[_0x376299('0x2829')](_0x2e3ca0()['keys'](_0xc795fd),[_0x376299('0xe53'),_0x376299('0x1980'),_0x376299('0x1a4'),'updatedAt','sourceid']),_0x491bd6[_0x376299('0x20c1')]['push']('recordingURL'),_0x120ca2[_0x376299('0x1793')][_0x376299('0x2267')]()[_0x376299('0xe53')];})[_0x612cfa('0x683')](function(_0xbef67e){const _0x2e803f=_0x612cfa;_0x491bd6['voiceDialReportColumns']=_0x2e3ca0()[_0x2e803f('0x2829')](_0x2e3ca0()[_0x2e803f('0x55e')](_0xbef67e),[_0x2e803f('0xe53'),_0x2e803f('0x1980'),_0x2e803f('0x1a4'),_0x2e803f('0x2000'),_0x2e803f('0x1d58')]),_0x491bd6[_0x2e803f('0x1d6a')][_0x2e803f('0x1fd0')](_0x2e803f('0x1e93'));})[_0x612cfa('0x130a')](function(_0x51a62a){const _0x55170a=_0x612cfa;_0x2fc37b[_0x55170a('0x52a')]({'title':_0x51a62a[_0x55170a('0x13ee')]?'API:'+_0x51a62a[_0x55170a('0x13ee')]+_0x55170a('0xbf6')+_0x51a62a[_0x55170a('0x24a9')]:_0x55170a('0x1fd3'),'msg':_0x51a62a[_0x55170a('0x5a5')]?JSON[_0x55170a('0x258a')](_0x51a62a[_0x55170a('0x5a5')]):_0x51a62a['toString']()});}),_0x120ca2[_0x612cfa('0x26f5')]['getFields']({'id':_0x2c3512['id'],'ticketType':_0x35893b[_0x612cfa('0x20c9')]?_0x35893b[_0x612cfa('0x20c9')]:undefined})[_0x612cfa('0xe53')][_0x612cfa('0x683')](function(_0xe7772f){const _0x468972=_0x612cfa;_0x491bd6[_0x468972('0xd32')]=!![],_0x491bd6[_0x468972('0x189a')]=_0xe7772f['rows']?_0xe7772f[_0x468972('0xf5d')]:[],_0x491bd6['item'][_0x468972('0x280')]&&(_0x491bd6['customField']=_0x2e3ca0()[_0x468972('0x1c07')](_0x491bd6['fields'],{'id':_0x491bd6['item']['idField']}));})[_0x612cfa('0x130a')](function(_0x5e6c10){const _0x5bb411=_0x612cfa;_0x491bd6['accountConnected']=![],console[_0x5bb411('0x52a')](_0x5e6c10);});function _0x658ebb(){const _0x4f281d=_0x612cfa;_0x491bd6[_0x4f281d('0x17f')]=[],_0x491bd6[_0x4f281d('0x7f8')]&&(_0x491bd6[_0x4f281d('0x23ef')]['idField']=_0x491bd6['customField']['id'],_0x491bd6[_0x4f281d('0x23ef')][_0x4f281d('0x2584')]=_0x491bd6[_0x4f281d('0x7f8')][_0x4f281d('0x60a')],_0x491bd6[_0x4f281d('0x23ef')][_0x4f281d('0x7f8')]=_0x491bd6[_0x4f281d('0x7f8')][_0x4f281d('0xbf0')]),_0x120ca2[_0x4f281d('0x1007')][_0x4f281d('0xb0a')](_0x491bd6[_0x4f281d('0x23ef')])[_0x4f281d('0xe53')][_0x4f281d('0x683')](function(_0x544ef8){const _0xf1bee6=_0x4f281d;_0x491bd6[_0xf1bee6('0x1996')][_0xf1bee6('0x1167')](_0x544ef8),_0x2fc37b[_0xf1bee6('0x53')]({'title':_0x2e3ca0()[_0xf1bee6('0x21ab')](_0x187f0d)+'\x20properly\x20created','msg':_0x2e3ca0()[_0xf1bee6('0x21ab')](_0x187f0d)+_0xf1bee6('0x14b5')}),_0x418e2e();})[_0x4f281d('0x130a')](function(_0x3a1c64){const _0x4b21e0=_0x4f281d;console[_0x4b21e0('0x52a')](_0x3a1c64),_0x491bd6[_0x4b21e0('0x17f')]=_0x3a1c64['data']['errors']||[{'message':_0x3a1c64['toString'](),'type':_0x4b21e0('0x1928')}];});}function _0x1e78d5(){const _0x2bca91=_0x612cfa;_0x491bd6[_0x2bca91('0x17f')]=[],_0x491bd6[_0x2bca91('0x7f8')]&&(_0x491bd6[_0x2bca91('0x23ef')][_0x2bca91('0x280')]=_0x491bd6[_0x2bca91('0x7f8')]['id'],_0x491bd6[_0x2bca91('0x23ef')][_0x2bca91('0x2584')]=_0x491bd6[_0x2bca91('0x7f8')][_0x2bca91('0x60a')],_0x491bd6['item'][_0x2bca91('0x7f8')]=_0x491bd6[_0x2bca91('0x7f8')][_0x2bca91('0xbf0')]),_0x120ca2['intSugarcrmField'][_0x2bca91('0x2480')]({'id':_0x491bd6['item']['id']},_0x491bd6[_0x2bca91('0x23ef')])[_0x2bca91('0xe53')][_0x2bca91('0x683')](function(_0x20ce0e){const _0xfb04c0=_0x2bca91,_0x3e115a=_0x2e3ca0()[_0xfb04c0('0x1c07')](_0x491bd6['items'],{'id':_0x20ce0e['id']});_0x3e115a&&_0x2e3ca0()[_0xfb04c0('0xf22')](_0x3e115a,_0x20ce0e),_0x2fc37b[_0xfb04c0('0x53')]({'title':_0x2e3ca0()[_0xfb04c0('0x21ab')](_0x187f0d)+_0xfb04c0('0x15dd'),'msg':_0x2e3ca0()[_0xfb04c0('0x21ab')](_0x187f0d)+_0xfb04c0('0xf59')}),_0x418e2e();})['catch'](function(_0x1f849e){const _0x57db4f=_0x2bca91;console['error'](_0x1f849e),_0x491bd6[_0x57db4f('0x17f')]=_0x1f849e[_0x57db4f('0x5a5')][_0x57db4f('0x17f')]||[{'message':_0x1f849e[_0x57db4f('0x1ff0')](),'type':'api.intItem.update'}];});}function _0x4f1874(_0x3e6a80){const _0x2ec58=_0x612cfa;_0x491bd6['errors']=[];const _0xea1c33=_0x28a4ed[_0x2ec58('0x1c6f')]()[_0x2ec58('0xf28')]('Are\x20you\x20sure?')['content'](_0x2ec58('0x3fc')+_0x187f0d+_0x2ec58('0x1ee7'))[_0x2ec58('0x1040')](_0x2ec58('0x609')+_0x2e3ca0()[_0x2ec58('0x21ab')](_0x187f0d))['ok'](_0x2ec58('0x2307'))[_0x2ec58('0x19fb')](_0x2ec58('0x253a'))['targetEvent'](_0x3e6a80);_0x28a4ed['show'](_0xea1c33)['then'](function(){const _0x471a9b=_0x2ec58;_0x120ca2[_0x471a9b('0x1007')][_0x471a9b('0xd7e')]({'id':_0x491bd6[_0x471a9b('0x23ef')]['id']})['$promise'][_0x471a9b('0x683')](function(){const _0x2f0796=_0x471a9b;_0x2e3ca0()[_0x2f0796('0x3ec')](_0x491bd6[_0x2f0796('0x1996')],{'id':_0x491bd6[_0x2f0796('0x23ef')]['id']}),_0x2fc37b[_0x2f0796('0x53')]({'title':_0x2e3ca0()['capitalize'](_0x187f0d)+_0x2f0796('0x27d7'),'msg':_0x2e3ca0()['capitalize'](_0x187f0d)+_0x2f0796('0x194d')}),_0x418e2e();})[_0x471a9b('0x130a')](function(_0x206cb3){const _0xb24c38=_0x471a9b;console[_0xb24c38('0x52a')](_0x206cb3),_0x491bd6[_0xb24c38('0x17f')]=_0x206cb3[_0xb24c38('0x5a5')][_0xb24c38('0x17f')]||[{'message':_0x206cb3[_0xb24c38('0x1ff0')](),'type':_0xb24c38('0x70c')}];});},function(){});}function _0x2aeef1(){const _0x39d5f6=_0x612cfa;return _0x491bd6[_0x39d5f6('0x23ef')][_0x39d5f6('0x113b')]!==undefined?_0x491bd6[_0x39d5f6('0x23ef')]['variableName']:_0x39d5f6('0xbbf');}function _0x418e2e(){const _0x137d36=_0x612cfa;_0x28a4ed[_0x137d36('0x1715')]();}}const _0x43cd3a=_0x22fdc3;_0x230b88[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$document',_0x189033('0x1d08'),_0x189033('0xace'),'setting',_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0x1bdf'),_0x189033('0x22df')];function _0x230b88(_0xbdb1eb,_0x3a421a,_0x42af57,_0x3d5d65,_0x9ee11c,_0x3317b9,_0x4415e9,_0x4a2429,_0x7f7d04,_0x3e4c15,_0x579415,_0x19a49f){const _0xa54205=_0x189033,_0x2fe1a7=this;_0x2fe1a7[_0xa54205('0x11ed')]=_0x3e4c15[_0xa54205('0x20b2')](),_0x2fe1a7[_0xa54205('0xace')]=_0x3317b9,_0x2fe1a7[_0xa54205('0x260a')]=_0x4415e9,_0x2fe1a7['passwordPattern']=_0x2fe1a7[_0xa54205('0x260a')][_0xa54205('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2fe1a7[_0xa54205('0x1224')]=_0x3a421a[_0xa54205('0x173e')]()+_0xa54205('0x20de')+_0x3a421a['host'](),_0x2fe1a7[_0xa54205('0x1bdf')]=_0x579415||_0xbdb1eb['params'][_0xa54205('0x1bdf')]||{},_0x2fe1a7[_0xa54205('0x22df')]=_0x19a49f&&_0x19a49f['count']==0x1?_0x19a49f[_0xa54205('0xf5d')][0x0]:null,_0x2fe1a7[_0xa54205('0x1134')]=_0x3e4c15['parseCrudPermissions'](_0x2fe1a7[_0xa54205('0x22df')]?_0x2fe1a7[_0xa54205('0x22df')][_0xa54205('0x1134')]:null),_0x2fe1a7[_0xa54205('0x258d')]={},_0x2fe1a7['selectedTab']=_0xbdb1eb[_0xa54205('0x7f2')]['tab']||0x0,_0x2fe1a7['alert']=_0x7f7d04[_0xa54205('0x2289')],_0x2fe1a7['gotoSugarcrmAccounts']=_0x3b7a7b,_0x2fe1a7[_0xa54205('0x19cf')]=_0x57c563;function _0x3b7a7b(){const _0x4e1a11=_0xa54205;_0xbdb1eb['go'](_0x4e1a11('0xec1'),{},{'reload':_0x4e1a11('0xec1')});}function _0x57c563(){const _0x12cd4f=_0xa54205;_0x4a2429['intSugarcrmAccount'][_0x12cd4f('0x2480')]({'id':_0x2fe1a7[_0x12cd4f('0x1bdf')]['id']},_0x2fe1a7['sugarcrmAccount'])['$promise'][_0x12cd4f('0x683')](function(){const _0x4547eb=_0x12cd4f;_0x7f7d04['success']({'title':_0x4547eb('0x5a9'),'msg':_0x2fe1a7['sugarcrmAccount'][_0x4547eb('0x60a')]?_0x2fe1a7['sugarcrmAccount']['name']+'\x20has\x20been\x20updated!':''});})[_0x12cd4f('0x130a')](function(_0x464f54){const _0xeba720=_0x12cd4f;_0x7f7d04[_0xeba720('0x52a')]({'title':_0x464f54[_0xeba720('0x13ee')]?_0xeba720('0x2168')+_0x464f54[_0xeba720('0x13ee')]+_0xeba720('0xbf6')+_0x464f54[_0xeba720('0x24a9')]:'SYSTEM:GETintSugarcrmAccount','msg':_0x464f54[_0xeba720('0x5a5')]?JSON[_0xeba720('0x258a')](_0x464f54['data']):_0x464f54[_0xeba720('0x1ff0')]()});});}}const _0x1e4ce5=_0x230b88,_0x574144=_0x180212['p']+_0x189033('0x420');_0x487f47[_0x189033('0x14be')]=['$scope',_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),'$mdDialog','$document',_0x189033('0x2f9'),'$translate',_0x189033('0x1851'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x487f47(_0x54b7a0,_0x3345c8,_0x488809,_0xb6b769,_0x4b10dc,_0x3a8688,_0x322c3d,_0x187fe3,_0x7b6398,_0x16bae5,_0x4b3190,_0xa89e74,_0x467aef,_0x1e89c6,_0x54f74e,_0x20313d,_0x22bd52){const _0x2f2dc3=_0x189033,_0x5c40bf=this;_0x5c40bf[_0x2f2dc3('0xace')]=_0x20313d,_0x5c40bf[_0x2f2dc3('0x260a')]=_0x22bd52,_0x5c40bf['currentUser']=_0x54f74e[_0x2f2dc3('0x20b2')](),_0x5c40bf['sugarcrmAccounts']=_0x7b6398||{'count':0x0,'rows':[]},_0x5c40bf[_0x2f2dc3('0x2a')]=_0x16bae5,_0x5c40bf[_0x2f2dc3('0x22df')]=_0x4b3190&&_0x4b3190[_0x2f2dc3('0x50d')]==0x1?_0x4b3190[_0x2f2dc3('0xf5d')][0x0]:null,_0x5c40bf['crudPermissions']=_0x54f74e[_0x2f2dc3('0x142a')](_0x5c40bf['userProfileSection']?_0x5c40bf[_0x2f2dc3('0x22df')][_0x2f2dc3('0x1134')]:null),_0x5c40bf['table']=_0x2f2dc3('0x1851'),_0x5c40bf[_0x2f2dc3('0x247')]='',_0x5c40bf['listOrderAsc']=null,_0x5c40bf[_0x2f2dc3('0x23c1')]=[],_0x5c40bf[_0x2f2dc3('0x23a2')]={'fields':_0x2f2dc3('0x1481'),'limit':0xa,'page':0x1},_0x5c40bf[_0x2f2dc3('0xc63')]=_0x2d90cb,_0x5c40bf[_0x2f2dc3('0x375')]=_0x4533a1,_0x5c40bf[_0x2f2dc3('0x194f')]=_0x13e74a,_0x5c40bf[_0x2f2dc3('0x53')]=_0x3aad86,_0x5c40bf[_0x2f2dc3('0x1dce')]=_0x174270,_0x5c40bf['createOrEditSugarcrmAccount']=_0x196ad0,_0x5c40bf[_0x2f2dc3('0x1ce')]=_0x311bc7,_0x5c40bf['exportSelectedSugarcrmAccounts']=_0x1acdc1,_0x5c40bf[_0x2f2dc3('0x266')]=_0x160ef3,_0x5c40bf[_0x2f2dc3('0x4d7')]=_0x140669,_0x5c40bf[_0x2f2dc3('0x2793')]=_0x2b54ef;function _0x2d90cb(_0x18544b){const _0x36675b=_0x2f2dc3;_0x488809['go'](_0x36675b('0x1eca'),{'id':_0x18544b['id'],'sugarcrmAccount':_0x18544b,'crudPermissions':_0x5c40bf[_0x36675b('0x1134')]});}function _0x4533a1(_0x8e11bb){const _0x20c252=_0x2f2dc3;return _0xa89e74[_0x20c252('0x26f5')][_0x20c252('0x298')]({'id':_0x8e11bb['id'],'test':!![]})[_0x20c252('0xe53')][_0x20c252('0x683')](function(){const _0x183353=_0x20c252;_0x1e89c6[_0x183353('0x53')]({'title':_0x183353('0x21a'),'msg':_0x183353('0x1c6d')});})[_0x20c252('0x130a')](function(_0x525653){const _0x5300f7=_0x20c252;_0x1e89c6['error']({'title':_0x5300f7('0x21a'),'msg':_0x525653[_0x5300f7('0x5a5')]?_0x525653[_0x5300f7('0x5a5')][_0x5300f7('0x8c2')]?_0x525653[_0x5300f7('0x5a5')]['message']:JSON[_0x5300f7('0x258a')](_0x525653[_0x5300f7('0x5a5')]):_0x525653[_0x5300f7('0x1ff0')]()});});}function _0x13e74a(_0x1bbb38,_0x2148d1){const _0x581c4d=_0x2f2dc3,_0x4d4828=_0x4b10dc[_0x581c4d('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x581c4d('0x1e03')]('sugarcrmAccount')+'?')[_0x581c4d('0x26e3')](_0x581c4d('0xed5')+(_0x1bbb38[_0x581c4d('0x60a')]||_0x581c4d('0x1bdf'))+_0x581c4d('0x20f1')+_0x581c4d('0x1ee7'))['ariaLabel'](_0x581c4d('0x1632'))['targetEvent'](_0x2148d1)['ok']('OK')['cancel'](_0x581c4d('0x16b8'));_0x4b10dc[_0x581c4d('0x1d4')](_0x4d4828)[_0x581c4d('0x683')](function(){_0x311bc7(_0x1bbb38);},function(){const _0x5a8b42=_0x581c4d;console['log'](_0x5a8b42('0x16b8'));});}let _0x55d4e2=!![],_0x586246=0x1;_0x54b7a0[_0x2f2dc3('0x186d')](_0x2f2dc3('0x1e1d'),function(_0x335401,_0x48d051){const _0x411158=_0x2f2dc3;_0x55d4e2?_0x322c3d(function(){_0x55d4e2=![];}):(!_0x48d051&&(_0x586246=_0x5c40bf['query'][_0x411158('0xdf8')]),_0x335401!==_0x48d051&&(_0x5c40bf['query']['page']=0x1),!_0x335401&&(_0x5c40bf[_0x411158('0x23a2')][_0x411158('0xdf8')]=_0x586246),_0x5c40bf['getSugarcrmAccounts']());});function _0x3aad86(_0x4fa572){const _0x59a14b=_0x2f2dc3;_0x5c40bf[_0x59a14b('0x1851')]=_0x4fa572||{'count':0x0,'rows':[]};}function _0x174270(){const _0x4a485c=_0x2f2dc3;_0x5c40bf[_0x4a485c('0x23a2')][_0x4a485c('0x1cc8')]=(_0x5c40bf[_0x4a485c('0x23a2')][_0x4a485c('0xdf8')]-0x1)*_0x5c40bf['query']['limit'],_0x54f74e[_0x4a485c('0xca1')]('admin')?_0x5c40bf['promise']=_0xa89e74[_0x4a485c('0x26f5')][_0x4a485c('0x1e6e')](_0x5c40bf[_0x4a485c('0x23a2')],_0x3aad86)[_0x4a485c('0xe53')]:(_0x5c40bf['query']['id']=_0x5c40bf['userProfile']['id'],_0x5c40bf[_0x4a485c('0x23a2')][_0x4a485c('0x1aa')]=_0x4a485c('0x1e70'),_0x5c40bf[_0x4a485c('0x1883')]=_0xa89e74[_0x4a485c('0x2a')][_0x4a485c('0x241d')](_0x5c40bf[_0x4a485c('0x23a2')],_0x3aad86)[_0x4a485c('0xe53')]);}function _0x196ad0(_0x30d3c3,_0x58bff3){const _0x2805b8=_0x2f2dc3;_0x4b10dc[_0x2805b8('0x1d4')]({'controller':_0x2805b8('0x247f'),'controllerAs':'vm','templateUrl':_0x574144,'parent':angular[_0x2805b8('0x1fcc')](_0x3a8688[_0x2805b8('0x18e5')]),'targetEvent':_0x30d3c3,'clickOutsideToClose':!![],'locals':{'sugarcrmAccount':_0x58bff3,'sugarcrmAccounts':_0x5c40bf['sugarcrmAccounts'][_0x2805b8('0xf5d')],'license':_0x5c40bf[_0x2805b8('0xace')],'setting':_0x5c40bf[_0x2805b8('0x260a')],'crudPermissions':_0x5c40bf[_0x2805b8('0x1134')]}});}function _0x311bc7(_0x2a0734){const _0xa4754=_0x2f2dc3;_0xa89e74[_0xa4754('0x26f5')][_0xa4754('0xd7e')]({'id':_0x2a0734['id']})[_0xa4754('0xe53')][_0xa4754('0x683')](function(){const _0x31d2dd=_0xa4754;_0x2e3ca0()[_0x31d2dd('0x3ec')](_0x5c40bf[_0x31d2dd('0x1851')]['rows'],{'id':_0x2a0734['id']}),_0x5c40bf[_0x31d2dd('0x1851')]['count']-=0x1,!_0x5c40bf[_0x31d2dd('0x1851')]['rows'][_0x31d2dd('0x1564')]&&_0x5c40bf['getSugarcrmAccounts'](),_0x1e89c6[_0x31d2dd('0x53')]({'title':_0x2e3ca0()[_0x31d2dd('0x1e03')](_0x31d2dd('0x10e0'))+_0x31d2dd('0xbfc'),'msg':_0x2a0734['name']?_0x2a0734[_0x31d2dd('0x60a')]+_0x31d2dd('0x194d'):''});})[_0xa4754('0x130a')](function(_0x396534){const _0x2b1368=_0xa4754;if(_0x396534[_0x2b1368('0x5a5')]&&_0x396534['data'][_0x2b1368('0x17f')]&&_0x396534[_0x2b1368('0x5a5')][_0x2b1368('0x17f')][_0x2b1368('0x1564')]){_0x5c40bf[_0x2b1368('0x17f')]=_0x396534[_0x2b1368('0x5a5')]['errors']||[{'message':_0x396534['toString'](),'type':_0x2b1368('0x1b96')}];for(let _0x3d94cf=0x0;_0x3d94cf<_0x396534[_0x2b1368('0x5a5')][_0x2b1368('0x17f')][_0x2b1368('0x1564')];_0x3d94cf++){_0x1e89c6[_0x2b1368('0x52a')]({'title':_0x396534[_0x2b1368('0x5a5')][_0x2b1368('0x17f')][_0x3d94cf][_0x2b1368('0xcf0')],'msg':_0x396534[_0x2b1368('0x5a5')]['errors'][_0x3d94cf][_0x2b1368('0x8c2')]});}}else _0x1e89c6['error']({'title':_0x396534['status']?_0x2b1368('0x2168')+_0x396534[_0x2b1368('0x13ee')]+_0x2b1368('0xbf6')+_0x396534['statusText']:'SYSTEM:DELETEintSugarcrmAccount','msg':_0x396534['data']?JSON[_0x2b1368('0x258a')](_0x396534[_0x2b1368('0x5a5')][_0x2b1368('0x8c2')]):_0x396534[_0x2b1368('0x8c2')]||_0x396534[_0x2b1368('0x1ff0')]()});});}function _0x1acdc1(){const _0x4aa2d6=_0x2f2dc3,_0x56c5e7=angular[_0x4aa2d6('0x1a86')](_0x5c40bf[_0x4aa2d6('0x23c1')]);return _0x5c40bf[_0x4aa2d6('0x23c1')]=[],_0x56c5e7;}function _0x160ef3(_0x4edbbe){const _0x554796=_0x2f2dc3,_0x2da7bc=_0x4b10dc[_0x554796('0x1c6f')]()[_0x554796('0xf28')](_0x554796('0x12c1'))[_0x554796('0x26e3')](''+_0x5c40bf[_0x554796('0x23c1')][_0x554796('0x1564')]+'\x20selected'+_0x554796('0x1ee7'))[_0x554796('0x1040')](_0x554796('0x10fb'))[_0x554796('0xe42')](_0x4edbbe)['ok']('OK')[_0x554796('0x19fb')]('CANCEL');_0x4b10dc[_0x554796('0x1d4')](_0x2da7bc)[_0x554796('0x683')](function(){const _0x5b69a4=_0x554796;_0x5c40bf['selectedSugarcrmAccounts'][_0x5b69a4('0x1299')](function(_0x336913){_0x311bc7(_0x336913);}),_0x5c40bf['selectedSugarcrmAccounts']=[];});}function _0x140669(){const _0xc7905d=_0x2f2dc3;_0x5c40bf[_0xc7905d('0x23c1')]=[];}function _0x2b54ef(){const _0x4a4d29=_0x2f2dc3;_0x5c40bf['selectedSugarcrmAccounts']=_0x5c40bf[_0x4a4d29('0x1851')][_0x4a4d29('0xf5d')];}}const _0x1ceb40=_0x487f47;_0x51bba5[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),'$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1800'),'vtigerAccount',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x51bba5(_0x37c678,_0x24ffc5,_0xe92b70,_0x2938bb,_0x2559eb,_0x58ce54,_0x295e10,_0xe6c725,_0x598d4,_0x2ebcf7,_0xff01c,_0x8db3b9,_0x78463,_0x598984){const _0xea589b=_0x189033,_0x34ea06=this;_0x34ea06[_0xea589b('0x11ed')]=_0xff01c['getCurrentUser'](),_0x34ea06[_0xea589b('0x17f')]=[],_0x34ea06[_0xea589b('0x260a')]=_0x78463,_0x34ea06[_0xea589b('0xace')]=_0x8db3b9,_0x34ea06[_0xea589b('0x1134')]=_0x598984,_0x34ea06[_0xea589b('0x258d')]={},_0x34ea06[_0xea589b('0x19b2')]=_0x34ea06[_0xea589b('0x260a')]&&_0x34ea06['setting'][_0xea589b('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x34ea06[_0xea589b('0xf28')]=_0xea589b('0x2247'),_0x34ea06[_0xea589b('0xa49')]=angular[_0xea589b('0x1a86')](_0x598d4),_0x34ea06[_0xea589b('0x1800')]=_0xe6c725,_0x34ea06[_0xea589b('0x1604')]=![];!_0x34ea06[_0xea589b('0xa49')]&&(_0x34ea06[_0xea589b('0xa49')]={'serverUrl':_0xe92b70[_0xea589b('0x173e')]()+_0xea589b('0x20de')+_0xe92b70['host']()+(_0xe92b70[_0xea589b('0x4a2')]()?':'+_0xe92b70[_0xea589b('0x4a2')]():'')},_0x34ea06[_0xea589b('0xf28')]=_0xea589b('0xf76'),_0x34ea06[_0xea589b('0x1604')]=!![]);_0x34ea06['addNewVtigerAccount']=_0x4882da,_0x34ea06[_0xea589b('0x13ae')]=_0x529906,_0x34ea06[_0xea589b('0x4e5')]=_0x116b42,_0x34ea06[_0xea589b('0x16b3')]=_0x5e46f3,_0x34ea06['closeDialog']=_0x4c64c1;function _0x4882da(){const _0x2169fc=_0xea589b;_0x34ea06['errors']=[],_0x2ebcf7[_0x2169fc('0x26cb')][_0x2169fc('0xb0a')](_0x34ea06['vtigerAccount'])[_0x2169fc('0xe53')]['then'](function(_0xe678d5){const _0x3b28a5=_0x2169fc;_0x34ea06[_0x3b28a5('0x1800')][_0x3b28a5('0x1167')](_0xe678d5[_0x3b28a5('0x24e1')]()),_0x295e10[_0x3b28a5('0x53')]({'title':'VtigerAccount\x20properly\x20created','msg':_0x34ea06[_0x3b28a5('0xa49')]['name']?_0x34ea06[_0x3b28a5('0xa49')][_0x3b28a5('0x60a')]+'\x20has\x20been\x20created!':''}),_0x4c64c1(_0xe678d5);})[_0x2169fc('0x130a')](function(_0x1d8d46){const _0xc7a6ce=_0x2169fc;if(_0x1d8d46['data']&&_0x1d8d46[_0xc7a6ce('0x5a5')]['errors']&&_0x1d8d46[_0xc7a6ce('0x5a5')][_0xc7a6ce('0x17f')]['length']){_0x34ea06[_0xc7a6ce('0x17f')]=_0x1d8d46['data']['errors']||[{'message':_0x1d8d46[_0xc7a6ce('0x1ff0')](),'type':_0xc7a6ce('0xf40')}];for(let _0x4fd7d7=0x0;_0x4fd7d7<_0x1d8d46['data'][_0xc7a6ce('0x17f')][_0xc7a6ce('0x1564')];_0x4fd7d7+=0x1){_0x295e10[_0xc7a6ce('0x52a')]({'title':_0x1d8d46['data'][_0xc7a6ce('0x17f')][_0x4fd7d7][_0xc7a6ce('0xcf0')],'msg':_0x1d8d46[_0xc7a6ce('0x5a5')][_0xc7a6ce('0x17f')][_0x4fd7d7][_0xc7a6ce('0x8c2')]});}}else _0x295e10[_0xc7a6ce('0x52a')]({'title':_0x1d8d46[_0xc7a6ce('0x13ee')]?_0xc7a6ce('0x2168')+_0x1d8d46[_0xc7a6ce('0x13ee')]+_0xc7a6ce('0xbf6')+_0x1d8d46[_0xc7a6ce('0x24a9')]:_0xc7a6ce('0xf40'),'msg':_0x1d8d46[_0xc7a6ce('0x5a5')]?JSON[_0xc7a6ce('0x258a')](_0x1d8d46[_0xc7a6ce('0x5a5')]['message']):_0x1d8d46[_0xc7a6ce('0x1ff0')]()});});}function _0x529906(){const _0x58f2af=_0xea589b;_0x34ea06[_0x58f2af('0x17f')]=[],_0x2ebcf7[_0x58f2af('0x26cb')][_0x58f2af('0x2480')]({'id':_0x34ea06[_0x58f2af('0xa49')]['id']},_0x34ea06[_0x58f2af('0xa49')])[_0x58f2af('0xe53')]['then'](function(_0x43a592){const _0x38667e=_0x58f2af,_0x31847a=_0x2e3ca0()[_0x38667e('0x1c07')](_0x34ea06[_0x38667e('0x1800')],{'id':_0x43a592['id']});_0x31847a&&_0x2e3ca0()[_0x38667e('0xf22')](_0x31847a,_0x2e3ca0()[_0x38667e('0x24d0')](_0x43a592[_0x38667e('0x24e1')](),_0x2e3ca0()[_0x38667e('0x55e')](_0x31847a))),_0x295e10[_0x38667e('0x53')]({'title':_0x38667e('0x11b0'),'msg':_0x34ea06[_0x38667e('0xa49')][_0x38667e('0x60a')]?_0x34ea06['vtigerAccount'][_0x38667e('0x60a')]+_0x38667e('0xf59'):''}),_0x4c64c1(_0x43a592);})['catch'](function(_0x3ca16d){const _0xe2328f=_0x58f2af;if(_0x3ca16d[_0xe2328f('0x5a5')]&&_0x3ca16d[_0xe2328f('0x5a5')][_0xe2328f('0x17f')]&&_0x3ca16d['data']['errors']['length']){_0x34ea06[_0xe2328f('0x17f')]=_0x3ca16d['data']['errors']||[{'message':_0x3ca16d[_0xe2328f('0x1ff0')](),'type':_0xe2328f('0x19c7')}];for(let _0x24d09f=0x0;_0x24d09f<_0x3ca16d[_0xe2328f('0x5a5')]['errors'][_0xe2328f('0x1564')];_0x24d09f++){_0x295e10[_0xe2328f('0x52a')]({'title':_0x3ca16d[_0xe2328f('0x5a5')]['errors'][_0x24d09f][_0xe2328f('0xcf0')],'msg':_0x3ca16d[_0xe2328f('0x5a5')][_0xe2328f('0x17f')][_0x24d09f]['message']});}}else _0x295e10[_0xe2328f('0x52a')]({'title':_0x3ca16d[_0xe2328f('0x13ee')]?_0xe2328f('0x2168')+_0x3ca16d[_0xe2328f('0x13ee')]+'\x20-\x20'+_0x3ca16d['statusText']:_0xe2328f('0x19c7'),'msg':_0x3ca16d[_0xe2328f('0x5a5')]?JSON['stringify'](_0x3ca16d[_0xe2328f('0x5a5')][_0xe2328f('0x8c2')]):_0x3ca16d[_0xe2328f('0x1ff0')]()});});}function _0x116b42(_0x19d66b){const _0x4bbaf9=_0xea589b;_0x34ea06[_0x4bbaf9('0x17f')]=[];const _0x3f7f7b=_0x2938bb[_0x4bbaf9('0x1c6f')]()['title'](_0x4bbaf9('0x4d'))[_0x4bbaf9('0xa6a')](_0x4bbaf9('0x5a0'))[_0x4bbaf9('0x1040')](_0x4bbaf9('0x1047'))['ok'](_0x4bbaf9('0x2307'))['cancel'](_0x4bbaf9('0x253a'))[_0x4bbaf9('0xe42')](_0x19d66b);_0x2938bb[_0x4bbaf9('0x1d4')](_0x3f7f7b)[_0x4bbaf9('0x683')](function(){const _0x105b2e=_0x4bbaf9;_0x2ebcf7[_0x105b2e('0x26cb')][_0x105b2e('0xd7e')]({'id':_0x34ea06[_0x105b2e('0xa49')]['id']})[_0x105b2e('0xe53')]['then'](function(){const _0x26bdbd=_0x105b2e;_0x2e3ca0()[_0x26bdbd('0x3ec')](_0x34ea06[_0x26bdbd('0x1800')],{'id':_0x34ea06[_0x26bdbd('0xa49')]['id']}),_0x295e10['success']({'title':_0x26bdbd('0x1acb'),'msg':(_0x34ea06[_0x26bdbd('0xa49')][_0x26bdbd('0x60a')]||'vtigerAccount')+_0x26bdbd('0x194d')}),_0x4c64c1(_0x34ea06[_0x26bdbd('0xa49')]);})[_0x105b2e('0x130a')](function(_0x146464){const _0xc6eab0=_0x105b2e;if(_0x146464['data']&&_0x146464['data'][_0xc6eab0('0x17f')]&&_0x146464[_0xc6eab0('0x5a5')][_0xc6eab0('0x17f')][_0xc6eab0('0x1564')]){_0x34ea06[_0xc6eab0('0x17f')]=_0x146464[_0xc6eab0('0x5a5')][_0xc6eab0('0x17f')]||[{'message':_0x146464[_0xc6eab0('0x1ff0')](),'type':'api.intVtigerAccount.delete'}];for(let _0x242915=0x0;_0x242915<_0x146464[_0xc6eab0('0x5a5')]['errors'][_0xc6eab0('0x1564')];_0x242915++){_0x295e10[_0xc6eab0('0x52a')]({'title':_0x146464['data'][_0xc6eab0('0x17f')][_0x242915][_0xc6eab0('0xcf0')],'msg':_0x146464[_0xc6eab0('0x5a5')][_0xc6eab0('0x17f')][_0x242915][_0xc6eab0('0x8c2')]});}}else _0x295e10[_0xc6eab0('0x52a')]({'title':_0x146464[_0xc6eab0('0x13ee')]?_0xc6eab0('0x2168')+_0x146464[_0xc6eab0('0x13ee')]+_0xc6eab0('0xbf6')+_0x146464['statusText']:'api.intVtigerAccount.delete','msg':_0x146464[_0xc6eab0('0x5a5')]?JSON[_0xc6eab0('0x258a')](_0x146464[_0xc6eab0('0x5a5')][_0xc6eab0('0x8c2')]):_0x146464[_0xc6eab0('0x8c2')]||_0x146464[_0xc6eab0('0x1ff0')]()});});},function(){});}function _0x5e46f3(_0x5eb3b2){return _0x5eb3b2===null?undefined:new Date(_0x5eb3b2);}function _0x4c64c1(_0x16bc74){const _0x3d2c16=_0xea589b;_0x2938bb[_0x3d2c16('0x1715')](_0x16bc74);}}const _0x36b5ad=_0x51bba5,_0x2c6869=_0x180212['p']+_0x189033('0xdb4'),_0x4f04f1=_0x180212['p']+_0x189033('0x6b5');_0x413e1d['$inject']=[_0x189033('0x1e48'),_0x189033('0x16ea'),'api','toasty',_0x189033('0xba1')];function _0x413e1d(_0x452c20,_0xa77834,_0x409f94,_0x5ecaf0,_0x451d61){const _0x4c0ffb=_0x189033,_0x1a034f=this;_0x1a034f[_0x4c0ffb('0x11ed')]=_0x451d61[_0x4c0ffb('0x20b2')](),_0x1a034f[_0x4c0ffb('0xa49')]={},_0x1a034f[_0x4c0ffb('0xab5')]={},_0x1a034f['configurations']=[],_0x1a034f['selectedVtigerConfiguration']=-0x1,_0x1a034f['crudPermissions'],_0x1a034f[_0x4c0ffb('0x12f3')]=_0x43686c,_0x1a034f[_0x4c0ffb('0x5fc')]=_0x257816,_0x1a034f[_0x4c0ffb('0x261c')]=_0x87eed0,_0x1a034f['deleteVtigerConfiguration']=_0x59067f;function _0x43686c(_0x3a2e83,_0x3a6349){const _0x7babe2=_0x4c0ffb;_0x1a034f[_0x7babe2('0xa49')]=_0x3a2e83,_0x1a034f[_0x7babe2('0x1134')]=typeof _0x3a6349!=='undefined'?_0x3a6349:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x409f94[_0x7babe2('0x26cb')][_0x7babe2('0x1575')]({'id':_0x1a034f[_0x7babe2('0xa49')]['id'],'sort':'-updatedAt'})['$promise'][_0x7babe2('0x683')](function(_0x3bbf56){const _0xb71a46=_0x7babe2;return _0x1a034f['configurations']=_0x3bbf56[_0xb71a46('0xf5d')]?_0x3bbf56[_0xb71a46('0xf5d')]:[],_0x1a034f[_0xb71a46('0x1573')][_0xb71a46('0x1564')]&&_0x1a034f[_0xb71a46('0x5fc')](0x0),_0x409f94['variable']['get']({'nolimit':!![],'sort':_0xb71a46('0x60a')})[_0xb71a46('0xe53')];})[_0x7babe2('0x683')](function(_0x302c21){const _0x11783c=_0x7babe2;_0x1a034f[_0x11783c('0x220b')]=_0x302c21[_0x11783c('0xf5d')]?_0x302c21['rows']:[],_0x1a034f[_0x11783c('0x1822')]=_0x2e3ca0()[_0x11783c('0x24db')](_0x1a034f['variables'],'id');})[_0x7babe2('0x130a')](function(_0x3df3db){const _0x5dc93b=_0x7babe2;_0x5ecaf0[_0x5dc93b('0x52a')]({'title':_0x3df3db[_0x5dc93b('0x13ee')]?'API:'+_0x3df3db[_0x5dc93b('0x13ee')]+_0x5dc93b('0xbf6')+_0x3df3db['statusText']:_0x5dc93b('0xe2a'),'msg':_0x3df3db[_0x5dc93b('0x5a5')]?JSON[_0x5dc93b('0x258a')](_0x3df3db[_0x5dc93b('0x5a5')]):_0x3df3db[_0x5dc93b('0x1ff0')]()});});}function _0x257816(_0x439da2){const _0x5b0c1a=_0x4c0ffb;_0x1a034f[_0x5b0c1a('0xab5')]=_0x1a034f[_0x5b0c1a('0x1573')][_0x439da2],_0x1a034f[_0x5b0c1a('0xb0e')]=_0x439da2,_0x409f94[_0x5b0c1a('0x25dd')][_0x5b0c1a('0x20ac')]({'id':_0x1a034f['vtigerConfiguration']['id']})['$promise'][_0x5b0c1a('0x683')](function(_0x5221fb){const _0xb39d14=_0x5b0c1a;return _0x1a034f[_0xb39d14('0x1ead')]=_0x5221fb['rows']?_0x5221fb[_0xb39d14('0xf5d')]:[],_0x409f94[_0xb39d14('0x25dd')]['getDescriptions']({'id':_0x1a034f['vtigerConfiguration']['id']})[_0xb39d14('0xe53')];})[_0x5b0c1a('0x683')](function(_0x21ed3d){const _0x43cbf8=_0x5b0c1a;return _0x1a034f['descriptions']=_0x21ed3d[_0x43cbf8('0xf5d')]?_0x21ed3d[_0x43cbf8('0xf5d')]:[],_0x409f94[_0x43cbf8('0x25dd')][_0x43cbf8('0x298')]({'id':_0x1a034f[_0x43cbf8('0xab5')]['id']})['$promise'];})[_0x5b0c1a('0x683')](function(_0x283ab4){const _0x8e875e=_0x5b0c1a;_0x1a034f['fields']=_0x283ab4[_0x8e875e('0xf5d')]?_0x283ab4[_0x8e875e('0xf5d')]:[];})['catch'](function(_0x15a927){const _0x3fa868=_0x5b0c1a;_0x5ecaf0[_0x3fa868('0x52a')]({'title':_0x15a927[_0x3fa868('0x13ee')]?_0x3fa868('0x2168')+_0x15a927['status']+_0x3fa868('0xbf6')+_0x15a927[_0x3fa868('0x24a9')]:_0x3fa868('0x167c'),'msg':_0x15a927['data']?JSON['stringify'](_0x15a927[_0x3fa868('0x5a5')]):_0x15a927[_0x3fa868('0x1ff0')]()});});}function _0x87eed0(_0x2f51b8,_0x3ce3c6){const _0x23f2b7=_0x4c0ffb;_0x452c20[_0x23f2b7('0x1d4')]({'controller':_0x23f2b7('0x103b'),'controllerAs':'vm','templateUrl':_0x2c6869,'parent':angular[_0x23f2b7('0x1fcc')](_0xa77834[_0x23f2b7('0x18e5')]),'targetEvent':_0x2f51b8,'clickOutsideToClose':!![],'locals':{'vtigerConfiguration':_0x3ce3c6,'configurations':_0x1a034f['configurations'],'license':null,'setting':null,'crudPermissions':_0x1a034f[_0x23f2b7('0x1134')]}})['finally'](function(){const _0x40a3e8=_0x23f2b7;_0x1a034f[_0x40a3e8('0x5fc')](0x0);});}function _0x59067f(_0x2305c2,_0x36843a){const _0x16b9ea=_0x4c0ffb,_0x424455=_0x452c20[_0x16b9ea('0x1c6f')]()[_0x16b9ea('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20vtigerConfiguration?')['htmlContent'](''+(_0x36843a['name']||_0x16b9ea('0xab5'))+''+_0x16b9ea('0x1ee7'))[_0x16b9ea('0x1040')](_0x16b9ea('0x16c2'))[_0x16b9ea('0xe42')](_0x2305c2)['ok']('OK')[_0x16b9ea('0x19fb')](_0x16b9ea('0x16b8'));_0x452c20[_0x16b9ea('0x1d4')](_0x424455)[_0x16b9ea('0x683')](function(){const _0x17f34e=_0x16b9ea;_0x409f94['intVtigerConfiguration'][_0x17f34e('0xd7e')]({'id':_0x36843a['id']})[_0x17f34e('0xe53')][_0x17f34e('0x683')](function(){const _0x228457=_0x17f34e;_0x2e3ca0()[_0x228457('0x3ec')](_0x1a034f['configurations'],{'id':_0x36843a['id']}),_0x5ecaf0[_0x228457('0x53')]({'title':_0x228457('0xbd2'),'msg':_0x36843a[_0x228457('0x60a')]?_0x36843a[_0x228457('0x60a')]+_0x228457('0x194d'):''});})[_0x17f34e('0x130a')](function(_0x5586bf){const _0x50e241=_0x17f34e;_0x5ecaf0[_0x50e241('0x52a')]({'title':_0x5586bf[_0x50e241('0x13ee')]?_0x50e241('0x2168')+_0x5586bf['status']+_0x50e241('0xbf6')+_0x5586bf[_0x50e241('0x24a9')]:'SYSTEM:DELETECONFIGURATION','msg':_0x5586bf[_0x50e241('0x5a5')]?JSON[_0x50e241('0x258a')](_0x5586bf[_0x50e241('0x5a5')]):_0x5586bf[_0x50e241('0x1ff0')]()});})[_0x17f34e('0x2874')](function(){const _0x42e31c=_0x17f34e;_0x1a034f[_0x42e31c('0x5fc')](0x0);});},function(){const _0x11831d=_0x16b9ea;console[_0x11831d('0x1b2b')](_0x11831d('0x16b8'));});}_0x1a034f[_0x4c0ffb('0x1781')]=[],_0x1a034f['createOrEditSubject']=_0x41ea33,_0x1a034f[_0x4c0ffb('0x2802')]=_0x227c2d,_0x1a034f['deleteSelectedSubjects']=_0x47bcd7;function _0x41ea33(_0x386676,_0x44dd0d){const _0x3c520d=_0x4c0ffb;_0x452c20[_0x3c520d('0x1d4')]({'controller':_0x3c520d('0x12cb'),'controllerAs':'vm','templateUrl':_0x4f04f1,'parent':angular[_0x3c520d('0x1fcc')](_0xa77834[_0x3c520d('0x18e5')]),'targetEvent':_0x386676,'clickOutsideToClose':!![],'locals':{'type':_0x3c520d('0x1e66'),'item':_0x44dd0d,'items':_0x1a034f[_0x3c520d('0x1ead')],'configuration':_0x1a034f[_0x3c520d('0xab5')],'account':_0x1a034f[_0x3c520d('0xa49')],'license':null,'setting':null,'crudPermissions':_0x1a034f[_0x3c520d('0x1134')]}});}function _0x380dc6(_0x4e9e46){const _0x53edaa=_0x4c0ffb;_0x409f94[_0x53edaa('0x9e1')][_0x53edaa('0xd7e')]({'id':_0x4e9e46['id']})[_0x53edaa('0xe53')][_0x53edaa('0x683')](function(){const _0x416b2e=_0x53edaa;_0x2e3ca0()[_0x416b2e('0x3ec')](_0x1a034f['subjects'],{'id':_0x4e9e46['id']}),_0x5ecaf0['success']({'title':_0x416b2e('0x637'),'msg':_0x416b2e('0x2795')});})[_0x53edaa('0x130a')](function(_0x4868d8){const _0x23317b=_0x53edaa;_0x5ecaf0[_0x23317b('0x52a')]({'title':_0x4868d8['status']?_0x23317b('0x2168')+_0x4868d8[_0x23317b('0x13ee')]+'\x20-\x20'+_0x4868d8[_0x23317b('0x24a9')]:_0x23317b('0x1d23'),'msg':_0x4868d8[_0x23317b('0x5a5')]?JSON['stringify'](_0x4868d8['data']):_0x4868d8[_0x23317b('0x1ff0')]()});});}function _0x227c2d(_0x5c0a57,_0x4ba4ac){const _0x37ebb5=_0x4c0ffb,_0x19d1d5=_0x452c20[_0x37ebb5('0x1c6f')]()['title'](_0x37ebb5('0x17ed'))[_0x37ebb5('0x26e3')]('Subject'+_0x37ebb5('0x1ee7'))[_0x37ebb5('0x1040')](_0x37ebb5('0x20d'))['targetEvent'](_0x5c0a57)['ok']('OK')[_0x37ebb5('0x19fb')](_0x37ebb5('0x16b8'));_0x452c20[_0x37ebb5('0x1d4')](_0x19d1d5)['then'](function(){_0x380dc6(_0x4ba4ac);},function(){const _0x42d9c4=_0x37ebb5;console[_0x42d9c4('0x1b2b')](_0x42d9c4('0x16b8'));});}function _0x47bcd7(_0x161e57){const _0x412857=_0x4c0ffb,_0x5af16b=_0x452c20['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20subjects?')[_0x412857('0x26e3')](_0x412857('0xed5')+_0x1a034f[_0x412857('0x1781')][_0x412857('0x1564')]+_0x412857('0x93c')+_0x412857('0x1ee7'))['ariaLabel']('delete\x20subjects')[_0x412857('0xe42')](_0x161e57)['ok']('OK')['cancel'](_0x412857('0x16b8'));_0x452c20['show'](_0x5af16b)[_0x412857('0x683')](function(){const _0xd1c3f1=_0x412857;_0x1a034f['selectedSubjects'][_0xd1c3f1('0x1299')](function(_0x4ec2ac){_0x380dc6(_0x4ec2ac);}),_0x1a034f['selectedSubjects']=[];});}_0x1a034f[_0x4c0ffb('0xcb1')]=[],_0x1a034f[_0x4c0ffb('0x1094')]=_0x48bf2b,_0x1a034f[_0x4c0ffb('0x27b2')]=_0x196961,_0x1a034f[_0x4c0ffb('0x27df')]=_0x53d45c;function _0x48bf2b(_0x2d36fd,_0x5a3ed4){const _0x49435a=_0x4c0ffb;_0x452c20[_0x49435a('0x1d4')]({'controller':_0x49435a('0x12cb'),'controllerAs':'vm','templateUrl':_0x4f04f1,'parent':angular[_0x49435a('0x1fcc')](_0xa77834[_0x49435a('0x18e5')]),'targetEvent':_0x2d36fd,'clickOutsideToClose':!![],'locals':{'type':'description','item':_0x5a3ed4,'items':_0x1a034f['descriptions'],'configuration':_0x1a034f[_0x49435a('0xab5')],'account':_0x1a034f[_0x49435a('0xa49')],'license':null,'setting':null,'crudPermissions':_0x1a034f[_0x49435a('0x1134')]}});}function _0x59d5f3(_0x5c3d60){const _0x53d6ed=_0x4c0ffb;_0x409f94['intVtigerField']['delete']({'id':_0x5c3d60['id']})[_0x53d6ed('0xe53')][_0x53d6ed('0x683')](function(){const _0x366128=_0x53d6ed;_0x2e3ca0()['remove'](_0x1a034f['descriptions'],{'id':_0x5c3d60['id']}),_0x5ecaf0['success']({'title':'Description\x20deleted!','msg':_0x366128('0x21c7')});})[_0x53d6ed('0x130a')](function(_0x1dc36a){const _0x4dffe9=_0x53d6ed;_0x5ecaf0[_0x4dffe9('0x52a')]({'title':_0x1dc36a['status']?_0x4dffe9('0x2168')+_0x1dc36a[_0x4dffe9('0x13ee')]+_0x4dffe9('0xbf6')+_0x1dc36a[_0x4dffe9('0x24a9')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x1dc36a[_0x4dffe9('0x5a5')]?JSON[_0x4dffe9('0x258a')](_0x1dc36a[_0x4dffe9('0x5a5')]):_0x1dc36a[_0x4dffe9('0x1ff0')]()});});}function _0x196961(_0x5d541b,_0x2d3121){const _0x3fcebc=_0x4c0ffb,_0x5e9e1d=_0x452c20[_0x3fcebc('0x1c6f')]()[_0x3fcebc('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20description?')[_0x3fcebc('0x26e3')](_0x3fcebc('0xd5e')+_0x3fcebc('0x1ee7'))[_0x3fcebc('0x1040')](_0x3fcebc('0x221c'))[_0x3fcebc('0xe42')](_0x5d541b)['ok']('OK')[_0x3fcebc('0x19fb')](_0x3fcebc('0x16b8'));_0x452c20[_0x3fcebc('0x1d4')](_0x5e9e1d)['then'](function(){_0x59d5f3(_0x2d3121);},function(){const _0x5e1f1a=_0x3fcebc;console[_0x5e1f1a('0x1b2b')](_0x5e1f1a('0x16b8'));});}function _0x53d45c(_0x22c2ee){const _0x42dc27=_0x4c0ffb,_0x536dbc=_0x452c20[_0x42dc27('0x1c6f')]()[_0x42dc27('0xf28')](_0x42dc27('0x1984'))[_0x42dc27('0x26e3')](''+_0x1a034f[_0x42dc27('0xcb1')][_0x42dc27('0x1564')]+_0x42dc27('0x93c')+_0x42dc27('0x1ee7'))[_0x42dc27('0x1040')](_0x42dc27('0x1859'))['targetEvent'](_0x22c2ee)['ok']('OK')['cancel']('CANCEL');_0x452c20[_0x42dc27('0x1d4')](_0x536dbc)[_0x42dc27('0x683')](function(){const _0x267e6f=_0x42dc27;_0x1a034f[_0x267e6f('0xcb1')][_0x267e6f('0x1299')](function(_0x467abe){_0x59d5f3(_0x467abe);}),_0x1a034f[_0x267e6f('0xcb1')]=[];});}_0x1a034f[_0x4c0ffb('0x310')]=[],_0x1a034f[_0x4c0ffb('0x84f')]=_0x45c057,_0x1a034f[_0x4c0ffb('0x9f9')]=_0x1525b4,_0x1a034f[_0x4c0ffb('0x204e')]=_0x38f852;function _0x45c057(_0x441466,_0x31606c){const _0x512512=_0x4c0ffb;_0x452c20[_0x512512('0x1d4')]({'controller':_0x512512('0x12cb'),'controllerAs':'vm','templateUrl':_0x4f04f1,'parent':angular[_0x512512('0x1fcc')](_0xa77834[_0x512512('0x18e5')]),'targetEvent':_0x441466,'clickOutsideToClose':!![],'locals':{'type':_0x512512('0x2013'),'item':_0x31606c,'items':_0x1a034f['fields'],'configuration':_0x1a034f[_0x512512('0xab5')],'account':_0x1a034f[_0x512512('0xa49')],'license':null,'setting':null,'crudPermissions':_0x1a034f[_0x512512('0x1134')]}});}function _0x43b0e2(_0x2e7bc0){const _0x6faaab=_0x4c0ffb;_0x409f94[_0x6faaab('0x9e1')]['delete']({'id':_0x2e7bc0['id']})[_0x6faaab('0xe53')][_0x6faaab('0x683')](function(){const _0x28357a=_0x6faaab;_0x2e3ca0()[_0x28357a('0x3ec')](_0x1a034f['fields'],{'id':_0x2e7bc0['id']}),_0x5ecaf0[_0x28357a('0x53')]({'title':_0x28357a('0x1666'),'msg':_0x28357a('0x1eda')});})[_0x6faaab('0x130a')](function(_0x5d980f){const _0x53f27f=_0x6faaab;_0x5ecaf0['error']({'title':_0x5d980f['status']?_0x53f27f('0x2168')+_0x5d980f[_0x53f27f('0x13ee')]+_0x53f27f('0xbf6')+_0x5d980f[_0x53f27f('0x24a9')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x5d980f[_0x53f27f('0x5a5')]?JSON[_0x53f27f('0x258a')](_0x5d980f['data']):_0x5d980f[_0x53f27f('0x1ff0')]()});});}function _0x1525b4(_0xfa95d1,_0x27d9c5){const _0x4cfbae=_0x4c0ffb,_0x26d76f=_0x452c20[_0x4cfbae('0x1c6f')]()[_0x4cfbae('0xf28')](_0x4cfbae('0x16b5'))['htmlContent']('Field'+'\x20will\x20be\x20deleted.')[_0x4cfbae('0x1040')](_0x4cfbae('0x1edb'))['targetEvent'](_0xfa95d1)['ok']('OK')[_0x4cfbae('0x19fb')](_0x4cfbae('0x16b8'));_0x452c20[_0x4cfbae('0x1d4')](_0x26d76f)[_0x4cfbae('0x683')](function(){_0x43b0e2(_0x27d9c5);},function(){const _0x24d669=_0x4cfbae;console[_0x24d669('0x1b2b')](_0x24d669('0x16b8'));});}function _0x38f852(_0x426760){const _0x5979ce=_0x4c0ffb,_0x314045=_0x452c20[_0x5979ce('0x1c6f')]()[_0x5979ce('0xf28')](_0x5979ce('0x19b1'))[_0x5979ce('0x26e3')](_0x5979ce('0xed5')+_0x1a034f[_0x5979ce('0x310')][_0x5979ce('0x1564')]+_0x5979ce('0x93c')+_0x5979ce('0x1ee7'))[_0x5979ce('0x1040')](_0x5979ce('0x994'))[_0x5979ce('0xe42')](_0x426760)['ok']('OK')['cancel'](_0x5979ce('0x16b8'));_0x452c20['show'](_0x314045)['then'](function(){const _0xafad3a=_0x5979ce;_0x1a034f['selectedFields'][_0xafad3a('0x1299')](function(_0x194d97){_0x43b0e2(_0x194d97);}),_0x1a034f['selectedFields']=[];});}}const _0x2056a7=_0x413e1d;_0x5a16b7[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate','toasty','configurations','vtigerConfiguration',_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x5a16b7(_0x620c03,_0x1fab59,_0x31baf9,_0x40f626,_0xdddd71,_0x354e87,_0x4c5b9e,_0x20f9b9,_0x5efabf,_0x1d947b,_0x27c812,_0x1ba12d,_0x189efc,_0xc8967f){const _0x335d30=_0x189033,_0x5210ab=this;_0x5210ab[_0x335d30('0x11ed')]=_0x27c812[_0x335d30('0x20b2')](),_0x5210ab[_0x335d30('0x17f')]=[],_0x5210ab[_0x335d30('0x260a')]=_0x189efc,_0x5210ab[_0x335d30('0xace')]=_0x1ba12d,_0x5210ab['crudPermissions']=_0xc8967f,_0x5210ab[_0x335d30('0x258d')]={},_0x5210ab[_0x335d30('0x19b2')]=_0x5210ab['setting']&&_0x5210ab[_0x335d30('0x260a')][_0x335d30('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5210ab['title']=_0x335d30('0x1aa7'),_0x5210ab[_0x335d30('0xab5')]=angular[_0x335d30('0x1a86')](_0x5efabf),_0x5210ab[_0x335d30('0x1573')]=_0x20f9b9,_0x5210ab['newVtigerConfiguration']=![];!_0x5210ab[_0x335d30('0xab5')]&&(_0x5210ab['vtigerConfiguration']={'channel':'voice','type':'inbound'},_0x5210ab[_0x335d30('0xf28')]=_0x335d30('0xae6'),_0x5210ab[_0x335d30('0x20f8')]=!![]);_0x5210ab[_0x335d30('0x19e0')]=_0x41e427,_0x5210ab['saveVtigerConfiguration']=_0x160c35,_0x5210ab[_0x335d30('0x2513')]=_0x4e293a,_0x5210ab[_0x335d30('0x16b3')]=_0x201835,_0x5210ab[_0x335d30('0xf82')]=_0x1bd3bf;function _0x41e427(){const _0x187109=_0x335d30;_0x5210ab[_0x187109('0x17f')]=[],_0x1d947b[_0x187109('0x26cb')][_0x187109('0x2003')]({'id':_0x1fab59['params']['id']},_0x5210ab[_0x187109('0xab5')])[_0x187109('0xe53')][_0x187109('0x683')](function(_0x555057){const _0x5b951d=_0x187109;_0x5210ab['configurations'][_0x5b951d('0x1167')](_0x555057[_0x5b951d('0x24e1')]()),_0x4c5b9e['success']({'title':'VtigerConfiguration\x20properly\x20created','msg':_0x5210ab[_0x5b951d('0xab5')][_0x5b951d('0x60a')]?_0x5210ab['vtigerConfiguration'][_0x5b951d('0x60a')]+_0x5b951d('0x14b5'):''}),_0x1bd3bf(_0x555057);})[_0x187109('0x130a')](function(_0x1faa91){const _0x15fd33=_0x187109;if(_0x1faa91['data']&&_0x1faa91[_0x15fd33('0x5a5')][_0x15fd33('0x17f')]&&_0x1faa91[_0x15fd33('0x5a5')]['errors'][_0x15fd33('0x1564')]){_0x5210ab[_0x15fd33('0x17f')]=_0x1faa91[_0x15fd33('0x5a5')][_0x15fd33('0x17f')]||[{'message':_0x1faa91['toString'](),'type':_0x15fd33('0x2232')}];for(let _0x274809=0x0;_0x274809<_0x1faa91[_0x15fd33('0x5a5')][_0x15fd33('0x17f')][_0x15fd33('0x1564')];_0x274809+=0x1){_0x4c5b9e['error']({'title':_0x1faa91['data']['errors'][_0x274809][_0x15fd33('0xcf0')],'msg':_0x1faa91[_0x15fd33('0x5a5')]['errors'][_0x274809][_0x15fd33('0x8c2')]});}}else _0x4c5b9e[_0x15fd33('0x52a')]({'title':_0x1faa91[_0x15fd33('0x13ee')]?_0x15fd33('0x2168')+_0x1faa91[_0x15fd33('0x13ee')]+'\x20-\x20'+_0x1faa91[_0x15fd33('0x24a9')]:_0x15fd33('0x2232'),'msg':_0x1faa91[_0x15fd33('0x5a5')]?JSON[_0x15fd33('0x258a')](_0x1faa91['data'][_0x15fd33('0x8c2')]):_0x1faa91[_0x15fd33('0x1ff0')]()});});}function _0x160c35(){const _0x36a5c1=_0x335d30;_0x5210ab[_0x36a5c1('0x17f')]=[],_0x1d947b[_0x36a5c1('0x25dd')][_0x36a5c1('0x2480')]({'id':_0x5210ab['vtigerConfiguration']['id']},_0x5210ab[_0x36a5c1('0xab5')])['$promise'][_0x36a5c1('0x683')](function(_0x19f867){const _0x5746c5=_0x36a5c1,_0x2deeef=_0x2e3ca0()[_0x5746c5('0x1c07')](_0x5210ab['configurations'],{'id':_0x19f867['id']});_0x2deeef&&_0x2e3ca0()[_0x5746c5('0xf22')](_0x2deeef,_0x2e3ca0()['pick'](_0x19f867[_0x5746c5('0x24e1')](),_0x2e3ca0()[_0x5746c5('0x55e')](_0x2deeef))),_0x4c5b9e[_0x5746c5('0x53')]({'title':'VtigerConfiguration\x20properly\x20saved!','msg':_0x5210ab[_0x5746c5('0xab5')][_0x5746c5('0x60a')]?_0x5210ab['vtigerConfiguration']['name']+'\x20has\x20been\x20saved!':''}),_0x1bd3bf(_0x19f867);})[_0x36a5c1('0x130a')](function(_0x249f26){const _0x7128e2=_0x36a5c1;if(_0x249f26['data']&&_0x249f26[_0x7128e2('0x5a5')][_0x7128e2('0x17f')]&&_0x249f26['data'][_0x7128e2('0x17f')][_0x7128e2('0x1564')]){_0x5210ab[_0x7128e2('0x17f')]=_0x249f26['data'][_0x7128e2('0x17f')]||[{'message':_0x249f26[_0x7128e2('0x1ff0')](),'type':'api.intVtigerConfiguration.update'}];for(let _0x5d2cea=0x0;_0x5d2cea<_0x249f26[_0x7128e2('0x5a5')]['errors'][_0x7128e2('0x1564')];_0x5d2cea++){_0x4c5b9e[_0x7128e2('0x52a')]({'title':_0x249f26[_0x7128e2('0x5a5')]['errors'][_0x5d2cea][_0x7128e2('0xcf0')],'msg':_0x249f26[_0x7128e2('0x5a5')][_0x7128e2('0x17f')][_0x5d2cea][_0x7128e2('0x8c2')]});}}else _0x4c5b9e[_0x7128e2('0x52a')]({'title':_0x249f26[_0x7128e2('0x13ee')]?_0x7128e2('0x2168')+_0x249f26[_0x7128e2('0x13ee')]+_0x7128e2('0xbf6')+_0x249f26[_0x7128e2('0x24a9')]:_0x7128e2('0x4d1'),'msg':_0x249f26[_0x7128e2('0x5a5')]?JSON[_0x7128e2('0x258a')](_0x249f26['data'][_0x7128e2('0x8c2')]):_0x249f26[_0x7128e2('0x1ff0')]()});});}function _0x4e293a(_0x365c8d){const _0x37d04c=_0x335d30;_0x5210ab[_0x37d04c('0x17f')]=[];const _0x9669ae=_0x40f626[_0x37d04c('0x1c6f')]()[_0x37d04c('0xf28')]('Are\x20you\x20sure?')['content'](_0x37d04c('0x1151'))[_0x37d04c('0x1040')](_0x37d04c('0x112d'))['ok'](_0x37d04c('0x2307'))[_0x37d04c('0x19fb')](_0x37d04c('0x253a'))[_0x37d04c('0xe42')](_0x365c8d);_0x40f626[_0x37d04c('0x1d4')](_0x9669ae)['then'](function(){const _0x4d80d3=_0x37d04c;_0x1d947b[_0x4d80d3('0x25dd')][_0x4d80d3('0xd7e')]({'id':_0x5210ab['vtigerConfiguration']['id']})['$promise']['then'](function(){const _0x34909f=_0x4d80d3;_0x2e3ca0()['remove'](_0x5210ab[_0x34909f('0x1573')],{'id':_0x5210ab[_0x34909f('0xab5')]['id']}),_0x4c5b9e[_0x34909f('0x53')]({'title':_0x34909f('0x14bc'),'msg':(_0x5210ab[_0x34909f('0xab5')]['name']||_0x34909f('0xab5'))+_0x34909f('0x194d')}),_0x1bd3bf(_0x5210ab[_0x34909f('0xab5')]);})[_0x4d80d3('0x130a')](function(_0x306bbb){const _0x4d7a5c=_0x4d80d3;if(_0x306bbb[_0x4d7a5c('0x5a5')]&&_0x306bbb[_0x4d7a5c('0x5a5')][_0x4d7a5c('0x17f')]&&_0x306bbb['data']['errors']['length']){_0x5210ab[_0x4d7a5c('0x17f')]=_0x306bbb[_0x4d7a5c('0x5a5')]['errors']||[{'message':_0x306bbb[_0x4d7a5c('0x1ff0')](),'type':_0x4d7a5c('0x2014')}];for(let _0x2a792c=0x0;_0x2a792c<_0x306bbb[_0x4d7a5c('0x5a5')][_0x4d7a5c('0x17f')][_0x4d7a5c('0x1564')];_0x2a792c++){_0x4c5b9e[_0x4d7a5c('0x52a')]({'title':_0x306bbb[_0x4d7a5c('0x5a5')]['errors'][_0x2a792c]['type'],'msg':_0x306bbb[_0x4d7a5c('0x5a5')]['errors'][_0x2a792c][_0x4d7a5c('0x8c2')]});}}else _0x4c5b9e['error']({'title':_0x306bbb[_0x4d7a5c('0x13ee')]?'API:'+_0x306bbb[_0x4d7a5c('0x13ee')]+_0x4d7a5c('0xbf6')+_0x306bbb[_0x4d7a5c('0x24a9')]:_0x4d7a5c('0x2014'),'msg':_0x306bbb[_0x4d7a5c('0x5a5')]?JSON['stringify'](_0x306bbb[_0x4d7a5c('0x5a5')][_0x4d7a5c('0x8c2')]):_0x306bbb[_0x4d7a5c('0x8c2')]||_0x306bbb[_0x4d7a5c('0x1ff0')]()});});},function(){});}function _0x201835(_0x3c2318){return _0x3c2318===null?undefined:new Date(_0x3c2318);}function _0x1bd3bf(_0x3a2f29){const _0xedbe7e=_0x335d30;_0x40f626[_0xedbe7e('0x1715')](_0x3a2f29);}}const _0x1e3c92=_0x5a16b7;_0x55fe20['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'toasty',_0x189033('0x208d'),_0x189033('0x1996'),_0x189033('0x23ef'),_0x189033('0x1d2f'),_0x189033('0xcf0'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x55fe20(_0x356d35,_0x54547a,_0x548fca,_0x1e6baf,_0x4a7469,_0x30361a,_0x167306,_0x3715fe,_0x3f3267,_0x2f0c33,_0x4aed5d,_0x451ddf,_0x13d2a0){const _0x4357a2=_0x189033,_0x4d90c1=this;_0x4d90c1['currentUser']=_0x451ddf[_0x4357a2('0x20b2')](),_0x4d90c1['errors']=[],_0x4d90c1['title']=_0x4357a2('0x176c')+_0x2e3ca0()['toUpper'](_0x2f0c33),_0x4d90c1[_0x4357a2('0x23ef')]=angular['copy'](_0x3715fe),_0x4d90c1[_0x4357a2('0x1996')]=_0x167306,_0x4d90c1[_0x4357a2('0xcf0')]=_0x2f0c33,_0x4d90c1[_0x4357a2('0x1134')]=_0x13d2a0,_0x4d90c1['newItem']=![];!_0x4d90c1['item']&&(_0x4d90c1[_0x4357a2('0x23ef')]={'type':_0x4357a2('0xc06')},_0x4d90c1['item'][_0x2e3ca0()[_0x4357a2('0x21ab')](_0x2f0c33)+'Id']=_0x30361a['id'],_0x4d90c1[_0x4357a2('0xf28')]='INTEGRATIONS.NEW_'+_0x2e3ca0()[_0x4357a2('0x65')](_0x2f0c33),_0x4d90c1[_0x4357a2('0x3d2')]=!![]);_0x4d90c1['addNewItem']=_0x528f45,_0x4d90c1['saveItem']=_0x125b68,_0x4d90c1[_0x4357a2('0x6b8')]=_0x444601,_0x4d90c1['getSelectedVariable']=_0x1d8de7,_0x4d90c1[_0x4357a2('0xf82')]=_0x390705,_0x4aed5d['variable']['get']({'nolimit':!![]})[_0x4357a2('0xe53')][_0x4357a2('0x683')](function(_0x41f18f){const _0x286636=_0x4357a2;return _0x4d90c1[_0x286636('0x220b')]=_0x41f18f[_0x286636('0xf5d')]?_0x41f18f[_0x286636('0xf5d')]:[],_0x4aed5d[_0x286636('0xf53')][_0x286636('0x2267')]()[_0x286636('0xe53')];})[_0x4357a2('0x683')](function(_0x56df24){const _0x4a3a06=_0x4357a2;return _0x4d90c1[_0x4a3a06('0x20c1')]=_0x2e3ca0()[_0x4a3a06('0x2829')](_0x2e3ca0()['keys'](_0x56df24),[_0x4a3a06('0xe53'),_0x4a3a06('0x1980'),_0x4a3a06('0x1a4'),_0x4a3a06('0x2000'),_0x4a3a06('0x1d58')]),_0x4d90c1[_0x4a3a06('0x20c1')][_0x4a3a06('0x1fd0')](_0x4a3a06('0x1e93')),_0x4aed5d[_0x4a3a06('0x1793')][_0x4a3a06('0x2267')]()['$promise'];})[_0x4357a2('0x683')](function(_0x2e1e8e){const _0x5268cb=_0x4357a2;_0x4d90c1['voiceDialReportColumns']=_0x2e3ca0()[_0x5268cb('0x2829')](_0x2e3ca0()[_0x5268cb('0x55e')](_0x2e1e8e),[_0x5268cb('0xe53'),'$resolved',_0x5268cb('0x1a4'),_0x5268cb('0x2000'),_0x5268cb('0x1d58')]),_0x4d90c1['voiceDialReportColumns'][_0x5268cb('0x1fd0')](_0x5268cb('0x1e93'));})[_0x4357a2('0x130a')](function(_0x107063){const _0x474536=_0x4357a2;_0x4a7469[_0x474536('0x52a')]({'title':_0x107063[_0x474536('0x13ee')]?_0x474536('0x2168')+_0x107063[_0x474536('0x13ee')]+'\x20-\x20'+_0x107063[_0x474536('0x24a9')]:_0x474536('0x1fd3'),'msg':_0x107063[_0x474536('0x5a5')]?JSON[_0x474536('0x258a')](_0x107063[_0x474536('0x5a5')]):_0x107063[_0x474536('0x1ff0')]()});}),_0x4aed5d['intVtigerAccount'][_0x4357a2('0x298')]({'id':_0x3f3267['id'],'ticketType':_0x30361a[_0x4357a2('0x20c9')]?_0x30361a[_0x4357a2('0x20c9')]:undefined})[_0x4357a2('0xe53')][_0x4357a2('0x683')](function(_0x4f53d6){const _0x35c98c=_0x4357a2;_0x4d90c1[_0x35c98c('0xd32')]=!![],_0x4d90c1[_0x35c98c('0x189a')]=_0x4f53d6['rows']?_0x4f53d6['rows']:[],_0x4d90c1[_0x35c98c('0x23ef')][_0x35c98c('0x280')]&&(_0x4d90c1[_0x35c98c('0x7f8')]=_0x2e3ca0()[_0x35c98c('0x1c07')](_0x4d90c1[_0x35c98c('0x189a')],{'id':_0x4d90c1[_0x35c98c('0x23ef')]['idField']}));})[_0x4357a2('0x130a')](function(_0x3a3d68){const _0x4b9d0d=_0x4357a2;_0x4d90c1[_0x4b9d0d('0xd32')]=![],console['error'](_0x3a3d68);});function _0x528f45(){const _0x5a8bb3=_0x4357a2;_0x4d90c1['errors']=[],_0x4d90c1[_0x5a8bb3('0x7f8')]&&(_0x4d90c1[_0x5a8bb3('0x23ef')][_0x5a8bb3('0x280')]=_0x4d90c1['customField']['id'],_0x4d90c1[_0x5a8bb3('0x23ef')][_0x5a8bb3('0x2584')]=_0x4d90c1[_0x5a8bb3('0x7f8')][_0x5a8bb3('0x60a')],_0x4d90c1[_0x5a8bb3('0x23ef')][_0x5a8bb3('0x7f8')]=_0x4d90c1[_0x5a8bb3('0x7f8')][_0x5a8bb3('0xbf0')]),_0x4aed5d['intVtigerField'][_0x5a8bb3('0xb0a')](_0x4d90c1['item'])['$promise'][_0x5a8bb3('0x683')](function(_0x326d6e){const _0x197c33=_0x5a8bb3;_0x4d90c1['items'][_0x197c33('0x1167')](_0x326d6e),_0x4a7469[_0x197c33('0x53')]({'title':_0x2e3ca0()[_0x197c33('0x21ab')](_0x2f0c33)+'\x20properly\x20created','msg':_0x2e3ca0()[_0x197c33('0x21ab')](_0x2f0c33)+'\x20has\x20been\x20created!'}),_0x390705();})['catch'](function(_0x3bb11f){const _0x2a9715=_0x5a8bb3;console['error'](_0x3bb11f),_0x4d90c1[_0x2a9715('0x17f')]=_0x3bb11f[_0x2a9715('0x5a5')][_0x2a9715('0x17f')]||[{'message':_0x3bb11f['toString'](),'type':'api.item.save'}];});}function _0x125b68(){const _0x482624=_0x4357a2;_0x4d90c1[_0x482624('0x17f')]=[],_0x4d90c1[_0x482624('0x7f8')]&&(_0x4d90c1[_0x482624('0x23ef')][_0x482624('0x280')]=_0x4d90c1[_0x482624('0x7f8')]['id'],_0x4d90c1[_0x482624('0x23ef')]['nameField']=_0x4d90c1[_0x482624('0x7f8')][_0x482624('0x60a')],_0x4d90c1['item'][_0x482624('0x7f8')]=_0x4d90c1[_0x482624('0x7f8')][_0x482624('0xbf0')]),_0x4aed5d[_0x482624('0x9e1')][_0x482624('0x2480')]({'id':_0x4d90c1[_0x482624('0x23ef')]['id']},_0x4d90c1[_0x482624('0x23ef')])['$promise'][_0x482624('0x683')](function(_0x38fc1a){const _0x15885e=_0x482624,_0x4a5402=_0x2e3ca0()['find'](_0x4d90c1[_0x15885e('0x1996')],{'id':_0x38fc1a['id']});_0x4a5402&&_0x2e3ca0()[_0x15885e('0xf22')](_0x4a5402,_0x38fc1a),_0x4a7469[_0x15885e('0x53')]({'title':_0x2e3ca0()[_0x15885e('0x21ab')](_0x2f0c33)+_0x15885e('0x15dd'),'msg':_0x2e3ca0()[_0x15885e('0x21ab')](_0x2f0c33)+_0x15885e('0xf59')}),_0x390705();})[_0x482624('0x130a')](function(_0x3a4956){const _0x62695a=_0x482624;console[_0x62695a('0x52a')](_0x3a4956),_0x4d90c1[_0x62695a('0x17f')]=_0x3a4956[_0x62695a('0x5a5')][_0x62695a('0x17f')]||[{'message':_0x3a4956[_0x62695a('0x1ff0')](),'type':_0x62695a('0x25d0')}];});}function _0x444601(_0x4ae3bb){const _0x126af2=_0x4357a2;_0x4d90c1[_0x126af2('0x17f')]=[];const _0xe1184d=_0x1e6baf['confirm']()[_0x126af2('0xf28')](_0x126af2('0x4d'))['content']('The\x20'+_0x2f0c33+_0x126af2('0x1ee7'))[_0x126af2('0x1040')](_0x126af2('0x609')+_0x2e3ca0()[_0x126af2('0x21ab')](_0x2f0c33))['ok'](_0x126af2('0x2307'))[_0x126af2('0x19fb')](_0x126af2('0x253a'))[_0x126af2('0xe42')](_0x4ae3bb);_0x1e6baf[_0x126af2('0x1d4')](_0xe1184d)[_0x126af2('0x683')](function(){const _0x131a07=_0x126af2;_0x4aed5d[_0x131a07('0x9e1')][_0x131a07('0xd7e')]({'id':_0x4d90c1[_0x131a07('0x23ef')]['id']})[_0x131a07('0xe53')][_0x131a07('0x683')](function(){const _0x5d1078=_0x131a07;_0x2e3ca0()['remove'](_0x4d90c1[_0x5d1078('0x1996')],{'id':_0x4d90c1[_0x5d1078('0x23ef')]['id']}),_0x4a7469['success']({'title':_0x2e3ca0()[_0x5d1078('0x21ab')](_0x2f0c33)+'\x20properly\x20deleted!','msg':_0x2e3ca0()[_0x5d1078('0x21ab')](_0x2f0c33)+_0x5d1078('0x194d')}),_0x390705();})[_0x131a07('0x130a')](function(_0x44ca2b){const _0x5243ef=_0x131a07;console['error'](_0x44ca2b),_0x4d90c1[_0x5243ef('0x17f')]=_0x44ca2b[_0x5243ef('0x5a5')][_0x5243ef('0x17f')]||[{'message':_0x44ca2b[_0x5243ef('0x1ff0')](),'type':_0x5243ef('0x70c')}];});},function(){});}function _0x1d8de7(){const _0x5e5ad7=_0x4357a2;return _0x4d90c1[_0x5e5ad7('0x23ef')][_0x5e5ad7('0x113b')]!==undefined?_0x4d90c1[_0x5e5ad7('0x23ef')]['variableName']:'Please\x20select\x20a\x20variable';}function _0x390705(){const _0x4e6379=_0x4357a2;_0x1e6baf[_0x4e6379('0x1715')]();}}const _0x25a06b=_0x55fe20;_0x5b042c[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),'Auth',_0x189033('0xa49'),_0x189033('0x22df')];function _0x5b042c(_0x2a026b,_0x5ee69c,_0x38319b,_0x1f083e,_0x4a4c55,_0x56c184,_0x5d0c50,_0x45f247,_0x2b0dea,_0x468c79,_0x35a817,_0x43effc){const _0x5bb44f=_0x189033,_0xcc208f=this;_0xcc208f[_0x5bb44f('0x11ed')]=_0x468c79[_0x5bb44f('0x20b2')](),_0xcc208f['license']=_0x56c184,_0xcc208f[_0x5bb44f('0x260a')]=_0x5d0c50,_0xcc208f[_0x5bb44f('0x19b2')]=_0xcc208f['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xcc208f[_0x5bb44f('0x1224')]=_0x5ee69c[_0x5bb44f('0x173e')]()+_0x5bb44f('0x20de')+_0x5ee69c[_0x5bb44f('0x19ac')](),_0xcc208f[_0x5bb44f('0xa49')]=_0x35a817||_0x2a026b[_0x5bb44f('0x7f2')][_0x5bb44f('0xa49')]||{},_0xcc208f[_0x5bb44f('0x22df')]=_0x43effc&&_0x43effc[_0x5bb44f('0x50d')]==0x1?_0x43effc['rows'][0x0]:null,_0xcc208f[_0x5bb44f('0x1134')]=_0x468c79[_0x5bb44f('0x142a')](_0xcc208f[_0x5bb44f('0x22df')]?_0xcc208f[_0x5bb44f('0x22df')][_0x5bb44f('0x1134')]:null),_0xcc208f[_0x5bb44f('0x258d')]={},_0xcc208f[_0x5bb44f('0x517')]=_0x2a026b[_0x5bb44f('0x7f2')][_0x5bb44f('0x1904')]||0x0,_0xcc208f[_0x5bb44f('0x2430')]=_0x2b0dea[_0x5bb44f('0x2289')],_0xcc208f['gotoVtigerAccounts']=_0x3b3be0,_0xcc208f[_0x5bb44f('0x13ae')]=_0x185660;function _0x3b3be0(){const _0xbbf380=_0x5bb44f;_0x2a026b['go'](_0xbbf380('0x1dca'),{},{'reload':_0xbbf380('0x1dca')});}function _0x185660(){const _0x4ad984=_0x5bb44f;_0x45f247[_0x4ad984('0x26cb')][_0x4ad984('0x2480')]({'id':_0xcc208f[_0x4ad984('0xa49')]['id']},_0xcc208f[_0x4ad984('0xa49')])[_0x4ad984('0xe53')][_0x4ad984('0x683')](function(){const _0x2b974e=_0x4ad984;_0x2b0dea[_0x2b974e('0x53')]({'title':_0x2b974e('0x9ba'),'msg':_0xcc208f[_0x2b974e('0xa49')]['name']?_0xcc208f[_0x2b974e('0xa49')][_0x2b974e('0x60a')]+_0x2b974e('0x96c'):''});})[_0x4ad984('0x130a')](function(_0x5070e6){const _0x4ed9f5=_0x4ad984;_0x2b0dea['error']({'title':_0x5070e6['status']?_0x4ed9f5('0x2168')+_0x5070e6['status']+_0x4ed9f5('0xbf6')+_0x5070e6[_0x4ed9f5('0x24a9')]:_0x4ed9f5('0xd41'),'msg':_0x5070e6[_0x4ed9f5('0x5a5')]?JSON[_0x4ed9f5('0x258a')](_0x5070e6[_0x4ed9f5('0x5a5')]):_0x5070e6[_0x4ed9f5('0x1ff0')]()});});}}const _0x5a1538=_0x5b042c,_0x5d6409=_0x180212['p']+_0x189033('0xe86');_0x1b2322[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),'$translate',_0x189033('0x1800'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x1b2322(_0xc20533,_0x202ed6,_0x2ff1b8,_0x52ec26,_0x3891ce,_0x14674f,_0xcf63e2,_0x192393,_0x575284,_0xe1783c,_0x1fd955,_0x42a047,_0x2c25f3,_0x404352,_0x3f1108,_0xc3fa95,_0x2fb7f8){const _0x531bc7=_0x189033,_0x3feed6=this;_0x3feed6[_0x531bc7('0xace')]=_0xc3fa95,_0x3feed6['setting']=_0x2fb7f8,_0x3feed6['currentUser']=_0x3f1108['getCurrentUser'](),_0x3feed6[_0x531bc7('0x1800')]=_0x575284||{'count':0x0,'rows':[]},_0x3feed6[_0x531bc7('0x2a')]=_0xe1783c,_0x3feed6[_0x531bc7('0x22df')]=_0x1fd955&&_0x1fd955['count']==0x1?_0x1fd955[_0x531bc7('0xf5d')][0x0]:null,_0x3feed6['crudPermissions']=_0x3f1108[_0x531bc7('0x142a')](_0x3feed6[_0x531bc7('0x22df')]?_0x3feed6[_0x531bc7('0x22df')][_0x531bc7('0x1134')]:null),_0x3feed6['table']='vtigerAccounts',_0x3feed6[_0x531bc7('0x247')]='',_0x3feed6[_0x531bc7('0x1ce2')]=null,_0x3feed6[_0x531bc7('0xa47')]=[],_0x3feed6[_0x531bc7('0x23a2')]={'fields':'createdAt,updatedAt,id,name,description,username,accessKey,remoteUri,serverUrl','limit':0xa,'page':0x1},_0x3feed6[_0x531bc7('0xc63')]=_0x1bccc3,_0x3feed6[_0x531bc7('0x375')]=_0x21a25e,_0x3feed6[_0x531bc7('0x194f')]=_0x484473,_0x3feed6[_0x531bc7('0x53')]=_0x404aa4,_0x3feed6['getVtigerAccounts']=_0x35df76,_0x3feed6[_0x531bc7('0x1c4')]=_0xaa7284,_0x3feed6[_0x531bc7('0x4e5')]=_0x72037d,_0x3feed6[_0x531bc7('0x135d')]=_0x3a3ee4,_0x3feed6['deleteSelectedVtigerAccounts']=_0x5a3925,_0x3feed6[_0x531bc7('0xb09')]=_0x34f669,_0x3feed6[_0x531bc7('0x23aa')]=_0x41fd70;function _0x1bccc3(_0x4fdf45){const _0x1df790=_0x531bc7;_0x2ff1b8['go'](_0x1df790('0xc6b'),{'id':_0x4fdf45['id'],'vtigerAccount':_0x4fdf45,'crudPermissions':_0x3feed6['crudPermissions']});}function _0x21a25e(_0x115053){const _0xf2b08a=_0x531bc7;return _0x42a047['intVtigerAccount'][_0xf2b08a('0x298')]({'id':_0x115053['id'],'test':!![]})[_0xf2b08a('0xe53')]['then'](function(){const _0x33f197=_0xf2b08a;_0x404352['success']({'title':_0x33f197('0x13f8'),'msg':'Connection\x20succeded!'});})['catch'](function(_0x1d47e3){const _0x5b6e65=_0xf2b08a;_0x404352[_0x5b6e65('0x52a')]({'title':_0x5b6e65('0x13f8'),'msg':_0x1d47e3[_0x5b6e65('0x5a5')]?_0x1d47e3[_0x5b6e65('0x5a5')][_0x5b6e65('0x8c2')]?_0x1d47e3[_0x5b6e65('0x5a5')][_0x5b6e65('0x8c2')]:JSON['stringify'](_0x1d47e3[_0x5b6e65('0x5a5')]):_0x1d47e3[_0x5b6e65('0x1ff0')]()});});}function _0x484473(_0x383010,_0x4043b9){const _0x266dbb=_0x531bc7,_0xfa80a9=_0x3891ce['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x266dbb('0x1e03')]('vtigerAccount')+'?')[_0x266dbb('0x26e3')](_0x266dbb('0xed5')+(_0x383010['name']||_0x266dbb('0xa49'))+_0x266dbb('0x20f1')+_0x266dbb('0x1ee7'))[_0x266dbb('0x1040')](_0x266dbb('0x1512'))[_0x266dbb('0xe42')](_0x4043b9)['ok']('OK')[_0x266dbb('0x19fb')]('CANCEL');_0x3891ce[_0x266dbb('0x1d4')](_0xfa80a9)[_0x266dbb('0x683')](function(){_0x72037d(_0x383010);},function(){const _0x359ed4=_0x266dbb;console[_0x359ed4('0x1b2b')](_0x359ed4('0x16b8'));});}let _0x1f63bb=!![],_0x4ad1d6=0x1;_0xc20533[_0x531bc7('0x186d')](_0x531bc7('0x1e1d'),function(_0x304f87,_0x295290){const _0x52551c=_0x531bc7;_0x1f63bb?_0xcf63e2(function(){_0x1f63bb=![];}):(!_0x295290&&(_0x4ad1d6=_0x3feed6[_0x52551c('0x23a2')][_0x52551c('0xdf8')]),_0x304f87!==_0x295290&&(_0x3feed6[_0x52551c('0x23a2')][_0x52551c('0xdf8')]=0x1),!_0x304f87&&(_0x3feed6[_0x52551c('0x23a2')][_0x52551c('0xdf8')]=_0x4ad1d6),_0x3feed6[_0x52551c('0x364')]());});function _0x404aa4(_0x15e941){const _0x28cc4=_0x531bc7;_0x3feed6[_0x28cc4('0x1800')]=_0x15e941||{'count':0x0,'rows':[]};}function _0x35df76(){const _0x49f63e=_0x531bc7;_0x3feed6['query']['offset']=(_0x3feed6[_0x49f63e('0x23a2')][_0x49f63e('0xdf8')]-0x1)*_0x3feed6[_0x49f63e('0x23a2')][_0x49f63e('0x6f0')],_0x3f1108[_0x49f63e('0xca1')](_0x49f63e('0x20c2'))?_0x3feed6['promise']=_0x42a047[_0x49f63e('0x26cb')]['get'](_0x3feed6['query'],_0x404aa4)[_0x49f63e('0xe53')]:(_0x3feed6[_0x49f63e('0x23a2')]['id']=_0x3feed6['userProfile']['id'],_0x3feed6[_0x49f63e('0x23a2')][_0x49f63e('0x1aa')]=_0x49f63e('0x1392'),_0x3feed6[_0x49f63e('0x1883')]=_0x42a047[_0x49f63e('0x2a')][_0x49f63e('0x241d')](_0x3feed6[_0x49f63e('0x23a2')],_0x404aa4)[_0x49f63e('0xe53')]);}function _0xaa7284(_0x47218f,_0x37a54f){const _0x10f9af=_0x531bc7;_0x3891ce[_0x10f9af('0x1d4')]({'controller':_0x10f9af('0x16ec'),'controllerAs':'vm','templateUrl':_0x5d6409,'parent':angular[_0x10f9af('0x1fcc')](_0x14674f['body']),'targetEvent':_0x47218f,'clickOutsideToClose':!![],'locals':{'vtigerAccount':_0x37a54f,'vtigerAccounts':_0x3feed6['vtigerAccounts']['rows'],'license':_0x3feed6[_0x10f9af('0xace')],'setting':_0x3feed6['setting'],'crudPermissions':_0x3feed6[_0x10f9af('0x1134')]}});}function _0x72037d(_0x2101df){const _0x4ee6c3=_0x531bc7;_0x42a047[_0x4ee6c3('0x26cb')][_0x4ee6c3('0xd7e')]({'id':_0x2101df['id']})[_0x4ee6c3('0xe53')][_0x4ee6c3('0x683')](function(){const _0x4db90b=_0x4ee6c3;_0x2e3ca0()[_0x4db90b('0x3ec')](_0x3feed6['vtigerAccounts']['rows'],{'id':_0x2101df['id']}),_0x3feed6['vtigerAccounts'][_0x4db90b('0x50d')]-=0x1,!_0x3feed6[_0x4db90b('0x1800')]['rows']['length']&&_0x3feed6['getVtigerAccounts'](),_0x404352[_0x4db90b('0x53')]({'title':_0x2e3ca0()['startCase']('VtigerAccount')+_0x4db90b('0xbfc'),'msg':_0x2101df[_0x4db90b('0x60a')]?_0x2101df[_0x4db90b('0x60a')]+_0x4db90b('0x194d'):''});})['catch'](function(_0x375bbc){const _0x37b85c=_0x4ee6c3;if(_0x375bbc[_0x37b85c('0x5a5')]&&_0x375bbc[_0x37b85c('0x5a5')]['errors']&&_0x375bbc[_0x37b85c('0x5a5')][_0x37b85c('0x17f')][_0x37b85c('0x1564')]){_0x3feed6[_0x37b85c('0x17f')]=_0x375bbc[_0x37b85c('0x5a5')][_0x37b85c('0x17f')]||[{'message':_0x375bbc[_0x37b85c('0x1ff0')](),'type':_0x37b85c('0x238c')}];for(let _0x652a55=0x0;_0x652a55<_0x375bbc[_0x37b85c('0x5a5')][_0x37b85c('0x17f')]['length'];_0x652a55++){_0x404352[_0x37b85c('0x52a')]({'title':_0x375bbc[_0x37b85c('0x5a5')][_0x37b85c('0x17f')][_0x652a55][_0x37b85c('0xcf0')],'msg':_0x375bbc[_0x37b85c('0x5a5')]['errors'][_0x652a55][_0x37b85c('0x8c2')]});}}else _0x404352[_0x37b85c('0x52a')]({'title':_0x375bbc['status']?'API:'+_0x375bbc['status']+_0x37b85c('0xbf6')+_0x375bbc[_0x37b85c('0x24a9')]:'SYSTEM:DELETEintVtigerAccount','msg':_0x375bbc['data']?JSON[_0x37b85c('0x258a')](_0x375bbc[_0x37b85c('0x5a5')]['message']):_0x375bbc[_0x37b85c('0x8c2')]||_0x375bbc[_0x37b85c('0x1ff0')]()});});}function _0x3a3ee4(){const _0x4aa7de=_0x531bc7,_0x3d0383=angular[_0x4aa7de('0x1a86')](_0x3feed6['selectedVtigerAccounts']);return _0x3feed6[_0x4aa7de('0xa47')]=[],_0x3d0383;}function _0x5a3925(_0x377d67){const _0x408ec1=_0x531bc7,_0x3c5165=_0x3891ce[_0x408ec1('0x1c6f')]()[_0x408ec1('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20vtigerAccounts?')[_0x408ec1('0x26e3')](_0x408ec1('0xed5')+_0x3feed6[_0x408ec1('0xa47')]['length']+_0x408ec1('0x93c')+_0x408ec1('0x1ee7'))[_0x408ec1('0x1040')](_0x408ec1('0x4fa'))[_0x408ec1('0xe42')](_0x377d67)['ok']('OK')[_0x408ec1('0x19fb')](_0x408ec1('0x16b8'));_0x3891ce[_0x408ec1('0x1d4')](_0x3c5165)[_0x408ec1('0x683')](function(){const _0x3d4a8c=_0x408ec1;_0x3feed6[_0x3d4a8c('0xa47')]['forEach'](function(_0x4a3d8a){_0x72037d(_0x4a3d8a);}),_0x3feed6[_0x3d4a8c('0xa47')]=[];});}function _0x34f669(){const _0x21a9b3=_0x531bc7;_0x3feed6[_0x21a9b3('0xa47')]=[];}function _0x41fd70(){const _0x2fef94=_0x531bc7;_0x3feed6[_0x2fef94('0xa47')]=_0x3feed6[_0x2fef94('0x1800')][_0x2fef94('0xf5d')];}}const _0x1f1136=_0x1b2322;_0xe8a390[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x320'),_0x189033('0x1602'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0xe8a390(_0x57710e,_0x226b8c,_0x447eb2,_0x521e08,_0xc88a01,_0x27bd32,_0x6c0c52,_0xe0e612,_0x530249,_0x133d43,_0x1925d0,_0x4e94a7,_0x2dd19c,_0x424e75){const _0x56a52f=_0x189033,_0xf2e29a=this;_0xf2e29a[_0x56a52f('0x11ed')]=_0x1925d0[_0x56a52f('0x20b2')](),_0xf2e29a[_0x56a52f('0x17f')]=[],_0xf2e29a[_0x56a52f('0x260a')]=_0x2dd19c,_0xf2e29a[_0x56a52f('0xace')]=_0x4e94a7,_0xf2e29a[_0x56a52f('0x1134')]=_0x424e75,_0xf2e29a[_0x56a52f('0x258d')]={},_0xf2e29a[_0x56a52f('0x19b2')]=_0xf2e29a[_0x56a52f('0x260a')]&&_0xf2e29a[_0x56a52f('0x260a')][_0x56a52f('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xf2e29a[_0x56a52f('0xf28')]=_0x56a52f('0x9b'),_0xf2e29a[_0x56a52f('0x1602')]=angular['copy'](_0x530249),_0xf2e29a['zendeskAccounts']=_0xe0e612,_0xf2e29a[_0x56a52f('0x5ca')]=![];!_0xf2e29a['zendeskAccount']&&(_0xf2e29a[_0x56a52f('0x1602')]={'type':'integrationTab','authType':_0x56a52f('0x1e96'),'serverUrl':_0x447eb2[_0x56a52f('0x173e')]()+'://'+_0x447eb2[_0x56a52f('0x19ac')]()+(_0x447eb2['port']()?':'+_0x447eb2[_0x56a52f('0x4a2')]():'')},_0xf2e29a[_0x56a52f('0xf28')]='INTEGRATIONS.NEW_ZENDESKACCOUNT',_0xf2e29a['newZendeskAccount']=!![]);_0xf2e29a['addNewZendeskAccount']=_0x133c0a,_0xf2e29a[_0x56a52f('0xa0f')]=_0x50bbdb,_0xf2e29a['deleteZendeskAccount']=_0x112ecc,_0xf2e29a[_0x56a52f('0x16b3')]=_0x257415,_0xf2e29a['closeDialog']=_0x5823e8;function _0x133c0a(){const _0x9d87ed=_0x56a52f;_0xf2e29a[_0x9d87ed('0x17f')]=[],_0x133d43['intZendeskAccount'][_0x9d87ed('0xb0a')](_0xf2e29a[_0x9d87ed('0x1602')])['$promise'][_0x9d87ed('0x683')](function(_0x21fb8c){const _0x203640=_0x9d87ed;_0xf2e29a[_0x203640('0x320')]['unshift'](_0x21fb8c[_0x203640('0x24e1')]()),_0x6c0c52['success']({'title':_0x203640('0x931'),'msg':_0xf2e29a['zendeskAccount'][_0x203640('0x60a')]?_0xf2e29a[_0x203640('0x1602')][_0x203640('0x60a')]+_0x203640('0x14b5'):''}),_0x5823e8(_0x21fb8c);})[_0x9d87ed('0x130a')](function(_0x28bb99){const _0x456a44=_0x9d87ed;if(_0x28bb99['data']&&_0x28bb99['data'][_0x456a44('0x17f')]&&_0x28bb99[_0x456a44('0x5a5')][_0x456a44('0x17f')][_0x456a44('0x1564')]){_0xf2e29a['errors']=_0x28bb99['data']['errors']||[{'message':_0x28bb99[_0x456a44('0x1ff0')](),'type':'api.intZendeskAccount.save'}];for(let _0x31f0d5=0x0;_0x31f0d5<_0x28bb99[_0x456a44('0x5a5')][_0x456a44('0x17f')][_0x456a44('0x1564')];_0x31f0d5+=0x1){_0x6c0c52['error']({'title':_0x28bb99[_0x456a44('0x5a5')]['errors'][_0x31f0d5]['type'],'msg':_0x28bb99[_0x456a44('0x5a5')][_0x456a44('0x17f')][_0x31f0d5][_0x456a44('0x8c2')]});}}else _0x6c0c52[_0x456a44('0x52a')]({'title':_0x28bb99['status']?_0x456a44('0x2168')+_0x28bb99[_0x456a44('0x13ee')]+_0x456a44('0xbf6')+_0x28bb99[_0x456a44('0x24a9')]:_0x456a44('0x631'),'msg':_0x28bb99[_0x456a44('0x5a5')]?JSON[_0x456a44('0x258a')](_0x28bb99[_0x456a44('0x5a5')][_0x456a44('0x8c2')]):_0x28bb99[_0x456a44('0x1ff0')]()});});}function _0x50bbdb(){const _0x629f5e=_0x56a52f;_0xf2e29a[_0x629f5e('0x17f')]=[],_0x133d43[_0x629f5e('0x1a0')][_0x629f5e('0x2480')]({'id':_0xf2e29a['zendeskAccount']['id']},_0xf2e29a['zendeskAccount'])[_0x629f5e('0xe53')][_0x629f5e('0x683')](function(_0x2abf50){const _0x1c4abe=_0x629f5e,_0x2166a0=_0x2e3ca0()[_0x1c4abe('0x1c07')](_0xf2e29a[_0x1c4abe('0x320')],{'id':_0x2abf50['id']});_0x2166a0&&_0x2e3ca0()[_0x1c4abe('0xf22')](_0x2166a0,_0x2e3ca0()[_0x1c4abe('0x24d0')](_0x2abf50[_0x1c4abe('0x24e1')](),_0x2e3ca0()[_0x1c4abe('0x55e')](_0x2166a0))),_0x6c0c52[_0x1c4abe('0x53')]({'title':_0x1c4abe('0x16e5'),'msg':_0xf2e29a[_0x1c4abe('0x1602')][_0x1c4abe('0x60a')]?_0xf2e29a[_0x1c4abe('0x1602')][_0x1c4abe('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x5823e8(_0x2abf50);})['catch'](function(_0x1647be){const _0x3b75ee=_0x629f5e;if(_0x1647be[_0x3b75ee('0x5a5')]&&_0x1647be[_0x3b75ee('0x5a5')]['errors']&&_0x1647be[_0x3b75ee('0x5a5')]['errors'][_0x3b75ee('0x1564')]){_0xf2e29a[_0x3b75ee('0x17f')]=_0x1647be[_0x3b75ee('0x5a5')][_0x3b75ee('0x17f')]||[{'message':_0x1647be[_0x3b75ee('0x1ff0')](),'type':_0x3b75ee('0x1861')}];for(let _0x1f263b=0x0;_0x1f263b<_0x1647be['data'][_0x3b75ee('0x17f')][_0x3b75ee('0x1564')];_0x1f263b++){_0x6c0c52['error']({'title':_0x1647be[_0x3b75ee('0x5a5')][_0x3b75ee('0x17f')][_0x1f263b][_0x3b75ee('0xcf0')],'msg':_0x1647be[_0x3b75ee('0x5a5')][_0x3b75ee('0x17f')][_0x1f263b][_0x3b75ee('0x8c2')]});}}else _0x6c0c52['error']({'title':_0x1647be['status']?'API:'+_0x1647be[_0x3b75ee('0x13ee')]+_0x3b75ee('0xbf6')+_0x1647be[_0x3b75ee('0x24a9')]:_0x3b75ee('0x1861'),'msg':_0x1647be[_0x3b75ee('0x5a5')]?JSON[_0x3b75ee('0x258a')](_0x1647be[_0x3b75ee('0x5a5')][_0x3b75ee('0x8c2')]):_0x1647be[_0x3b75ee('0x1ff0')]()});});}function _0x112ecc(_0x4f566c){const _0x42eccd=_0x56a52f;_0xf2e29a[_0x42eccd('0x17f')]=[];const _0x159fad=_0x521e08[_0x42eccd('0x1c6f')]()['title'](_0x42eccd('0x4d'))[_0x42eccd('0xa6a')](_0x42eccd('0x231e'))[_0x42eccd('0x1040')](_0x42eccd('0x3c'))['ok'](_0x42eccd('0x2307'))['cancel']('Cancel')[_0x42eccd('0xe42')](_0x4f566c);_0x521e08[_0x42eccd('0x1d4')](_0x159fad)[_0x42eccd('0x683')](function(){const _0x59ed62=_0x42eccd;_0x133d43['intZendeskAccount'][_0x59ed62('0xd7e')]({'id':_0xf2e29a[_0x59ed62('0x1602')]['id']})[_0x59ed62('0xe53')]['then'](function(){const _0x19ebf8=_0x59ed62;_0x2e3ca0()[_0x19ebf8('0x3ec')](_0xf2e29a['zendeskAccounts'],{'id':_0xf2e29a[_0x19ebf8('0x1602')]['id']}),_0x6c0c52[_0x19ebf8('0x53')]({'title':_0x19ebf8('0x18d9'),'msg':(_0xf2e29a[_0x19ebf8('0x1602')][_0x19ebf8('0x60a')]||_0x19ebf8('0x1602'))+_0x19ebf8('0x194d')}),_0x5823e8(_0xf2e29a['zendeskAccount']);})[_0x59ed62('0x130a')](function(_0x4d226f){const _0x38859a=_0x59ed62;if(_0x4d226f['data']&&_0x4d226f['data'][_0x38859a('0x17f')]&&_0x4d226f[_0x38859a('0x5a5')]['errors'][_0x38859a('0x1564')]){_0xf2e29a[_0x38859a('0x17f')]=_0x4d226f[_0x38859a('0x5a5')]['errors']||[{'message':_0x4d226f[_0x38859a('0x1ff0')](),'type':_0x38859a('0x1b34')}];for(let _0x48102e=0x0;_0x48102e<_0x4d226f[_0x38859a('0x5a5')][_0x38859a('0x17f')]['length'];_0x48102e++){_0x6c0c52[_0x38859a('0x52a')]({'title':_0x4d226f[_0x38859a('0x5a5')][_0x38859a('0x17f')][_0x48102e][_0x38859a('0xcf0')],'msg':_0x4d226f['data'][_0x38859a('0x17f')][_0x48102e][_0x38859a('0x8c2')]});}}else _0x6c0c52[_0x38859a('0x52a')]({'title':_0x4d226f[_0x38859a('0x13ee')]?_0x38859a('0x2168')+_0x4d226f[_0x38859a('0x13ee')]+_0x38859a('0xbf6')+_0x4d226f[_0x38859a('0x24a9')]:_0x38859a('0x1b34'),'msg':_0x4d226f[_0x38859a('0x5a5')]?JSON[_0x38859a('0x258a')](_0x4d226f['data'][_0x38859a('0x8c2')]):_0x4d226f[_0x38859a('0x8c2')]||_0x4d226f['toString']()});});},function(){});}function _0x257415(_0x1ca988){return _0x1ca988===null?undefined:new Date(_0x1ca988);}function _0x5823e8(_0x3585f9){_0x521e08['hide'](_0x3585f9);}}const _0x544ea8=_0xe8a390;_0x526dc6[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x208d'),_0x189033('0x1996'),'item',_0x189033('0x1d2f'),_0x189033('0xcf0'),_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x526dc6(_0x5de2ba,_0x301fff,_0x2de141,_0x990244,_0x2fe603,_0x294b89,_0x9b9039,_0x10b78c,_0x364a50,_0x31fa9f,_0x1269ac,_0x146a41,_0x25fb4d){const _0x1c5458=_0x189033,_0x168589=this;_0x168589[_0x1c5458('0x11ed')]=_0x146a41[_0x1c5458('0x20b2')](),_0x168589[_0x1c5458('0x17f')]=[],_0x168589[_0x1c5458('0xf28')]='INTEGRATIONS.EDIT_'+_0x2e3ca0()['toUpper'](_0x31fa9f),_0x168589[_0x1c5458('0x23ef')]=angular[_0x1c5458('0x1a86')](_0x10b78c),_0x168589[_0x1c5458('0x1996')]=_0x9b9039,_0x168589['type']=_0x31fa9f,_0x168589[_0x1c5458('0x1134')]=_0x25fb4d,_0x168589[_0x1c5458('0x3d2')]=![];!_0x168589[_0x1c5458('0x23ef')]&&(_0x168589[_0x1c5458('0x23ef')]={'type':'string'},_0x168589[_0x1c5458('0x23ef')][_0x2e3ca0()['capitalize'](_0x31fa9f)+'Id']=_0x294b89['id'],_0x168589[_0x1c5458('0xf28')]=_0x1c5458('0x22de')+_0x2e3ca0()['toUpper'](_0x31fa9f),_0x168589['newItem']=!![]);_0x168589['addNewItem']=_0x2ebb3c,_0x168589['saveItem']=_0x701ab8,_0x168589['deleteItem']=_0x203f27,_0x168589[_0x1c5458('0x18a')]=_0x5ab09e,_0x168589[_0x1c5458('0xf82')]=_0x391c9c,_0x1269ac['variable']['get']({'nolimit':!![]})[_0x1c5458('0xe53')][_0x1c5458('0x683')](function(_0x37089d){const _0x240a4b=_0x1c5458;return _0x168589[_0x240a4b('0x220b')]=_0x37089d[_0x240a4b('0xf5d')]?_0x37089d[_0x240a4b('0xf5d')]:[],_0x1269ac[_0x240a4b('0xf53')][_0x240a4b('0x2267')]()[_0x240a4b('0xe53')];})[_0x1c5458('0x683')](function(_0x399acb){const _0x4bfbc4=_0x1c5458;return _0x168589[_0x4bfbc4('0x20c1')]=_0x2e3ca0()['difference'](_0x2e3ca0()['keys'](_0x399acb),[_0x4bfbc4('0xe53'),_0x4bfbc4('0x1980'),_0x4bfbc4('0x1a4'),_0x4bfbc4('0x2000'),_0x4bfbc4('0x1d58')]),_0x168589[_0x4bfbc4('0x20c1')][_0x4bfbc4('0x1fd0')](_0x4bfbc4('0x1e93')),_0x1269ac[_0x4bfbc4('0x1793')][_0x4bfbc4('0x2267')]()[_0x4bfbc4('0xe53')];})[_0x1c5458('0x683')](function(_0x49bd72){const _0x4549d9=_0x1c5458;_0x168589[_0x4549d9('0x1d6a')]=_0x2e3ca0()[_0x4549d9('0x2829')](_0x2e3ca0()[_0x4549d9('0x55e')](_0x49bd72),[_0x4549d9('0xe53'),'$resolved',_0x4549d9('0x1a4'),'updatedAt',_0x4549d9('0x1d58')]),_0x168589['voiceDialReportColumns'][_0x4549d9('0x1fd0')](_0x4549d9('0x1e93'));})[_0x1c5458('0x130a')](function(_0x117ddb){const _0x14a3e1=_0x1c5458;_0x2fe603[_0x14a3e1('0x52a')]({'title':_0x117ddb[_0x14a3e1('0x13ee')]?_0x14a3e1('0x2168')+_0x117ddb[_0x14a3e1('0x13ee')]+_0x14a3e1('0xbf6')+_0x117ddb[_0x14a3e1('0x24a9')]:'SYSTEM:GETVARIABLES','msg':_0x117ddb[_0x14a3e1('0x5a5')]?JSON[_0x14a3e1('0x258a')](_0x117ddb['data']):_0x117ddb[_0x14a3e1('0x1ff0')]()});}),_0x1269ac[_0x1c5458('0x1a0')]['getFields']({'id':_0x364a50['id'],'ticketType':_0x294b89[_0x1c5458('0x20c9')]?_0x294b89['ticketType']:undefined})['$promise'][_0x1c5458('0x683')](function(_0x557bc1){const _0x58eb0d=_0x1c5458;_0x168589['accountConnected']=!![],_0x168589[_0x58eb0d('0x189a')]=_0x557bc1[_0x58eb0d('0xf5d')]?_0x557bc1[_0x58eb0d('0xf5d')]:[],_0x168589[_0x58eb0d('0x23ef')][_0x58eb0d('0x280')]&&(_0x168589['customField']=_0x2e3ca0()[_0x58eb0d('0x1c07')](_0x168589[_0x58eb0d('0x189a')],{'id':_0x168589[_0x58eb0d('0x23ef')]['idField']}));})[_0x1c5458('0x130a')](function(_0x317e5b){const _0x2fb152=_0x1c5458;_0x168589[_0x2fb152('0xd32')]=![],console[_0x2fb152('0x52a')](_0x317e5b);});function _0x2ebb3c(){const _0x1bdb2d=_0x1c5458;_0x168589[_0x1bdb2d('0x17f')]=[],_0x168589[_0x1bdb2d('0x7f8')]&&(_0x168589[_0x1bdb2d('0x23ef')][_0x1bdb2d('0x280')]=_0x168589[_0x1bdb2d('0x7f8')]['id'],_0x168589[_0x1bdb2d('0x23ef')][_0x1bdb2d('0x2584')]=_0x168589[_0x1bdb2d('0x7f8')][_0x1bdb2d('0x60a')],_0x168589[_0x1bdb2d('0x23ef')][_0x1bdb2d('0x7f8')]=_0x168589[_0x1bdb2d('0x7f8')][_0x1bdb2d('0xbf0')]),_0x1269ac[_0x1bdb2d('0xb26')][_0x1bdb2d('0xb0a')](_0x168589[_0x1bdb2d('0x23ef')])[_0x1bdb2d('0xe53')][_0x1bdb2d('0x683')](function(_0x322abb){const _0x1f3d3a=_0x1bdb2d;_0x168589[_0x1f3d3a('0x1996')][_0x1f3d3a('0x1167')](_0x322abb),_0x2fe603[_0x1f3d3a('0x53')]({'title':_0x2e3ca0()['capitalize'](_0x31fa9f)+_0x1f3d3a('0x282a'),'msg':_0x2e3ca0()[_0x1f3d3a('0x21ab')](_0x31fa9f)+_0x1f3d3a('0x14b5')}),_0x391c9c();})[_0x1bdb2d('0x130a')](function(_0x4f5be7){const _0x249137=_0x1bdb2d;console[_0x249137('0x52a')](_0x4f5be7),_0x168589[_0x249137('0x17f')]=_0x4f5be7[_0x249137('0x5a5')]['errors']||[{'message':_0x4f5be7[_0x249137('0x1ff0')](),'type':_0x249137('0x1928')}];});}function _0x701ab8(){const _0x4694e2=_0x1c5458;_0x168589['errors']=[],_0x168589[_0x4694e2('0x7f8')]&&(_0x168589[_0x4694e2('0x23ef')][_0x4694e2('0x280')]=_0x168589['customField']['id'],_0x168589[_0x4694e2('0x23ef')]['nameField']=_0x168589[_0x4694e2('0x7f8')][_0x4694e2('0x60a')],_0x168589[_0x4694e2('0x23ef')]['customField']=_0x168589[_0x4694e2('0x7f8')]['custom']),_0x1269ac['intZendeskField'][_0x4694e2('0x2480')]({'id':_0x168589[_0x4694e2('0x23ef')]['id']},_0x168589[_0x4694e2('0x23ef')])[_0x4694e2('0xe53')][_0x4694e2('0x683')](function(_0x2b5bf2){const _0x35fb8a=_0x4694e2,_0x129257=_0x2e3ca0()['find'](_0x168589[_0x35fb8a('0x1996')],{'id':_0x2b5bf2['id']});_0x129257&&_0x2e3ca0()['merge'](_0x129257,_0x2b5bf2),_0x2fe603['success']({'title':_0x2e3ca0()[_0x35fb8a('0x21ab')](_0x31fa9f)+_0x35fb8a('0x15dd'),'msg':_0x2e3ca0()[_0x35fb8a('0x21ab')](_0x31fa9f)+'\x20has\x20been\x20saved!'}),_0x391c9c();})[_0x4694e2('0x130a')](function(_0x37a1c9){const _0x321845=_0x4694e2;console[_0x321845('0x52a')](_0x37a1c9),_0x168589[_0x321845('0x17f')]=_0x37a1c9[_0x321845('0x5a5')][_0x321845('0x17f')]||[{'message':_0x37a1c9[_0x321845('0x1ff0')](),'type':_0x321845('0x25d0')}];});}function _0x203f27(_0x33c19c){const _0x9ebdcb=_0x1c5458;_0x168589['errors']=[];const _0x322e59=_0x990244['confirm']()['title'](_0x9ebdcb('0x4d'))[_0x9ebdcb('0xa6a')](_0x9ebdcb('0x3fc')+_0x31fa9f+_0x9ebdcb('0x1ee7'))['ariaLabel'](_0x9ebdcb('0x609')+_0x2e3ca0()['capitalize'](_0x31fa9f))['ok']('Delete')[_0x9ebdcb('0x19fb')](_0x9ebdcb('0x253a'))[_0x9ebdcb('0xe42')](_0x33c19c);_0x990244['show'](_0x322e59)[_0x9ebdcb('0x683')](function(){const _0x111100=_0x9ebdcb;_0x1269ac['intZendeskField'][_0x111100('0xd7e')]({'id':_0x168589[_0x111100('0x23ef')]['id']})['$promise'][_0x111100('0x683')](function(){const _0x4be76d=_0x111100;_0x2e3ca0()['remove'](_0x168589[_0x4be76d('0x1996')],{'id':_0x168589[_0x4be76d('0x23ef')]['id']}),_0x2fe603[_0x4be76d('0x53')]({'title':_0x2e3ca0()[_0x4be76d('0x21ab')](_0x31fa9f)+_0x4be76d('0x27d7'),'msg':_0x2e3ca0()[_0x4be76d('0x21ab')](_0x31fa9f)+'\x20has\x20been\x20deleted!'}),_0x391c9c();})['catch'](function(_0x2072cc){const _0x4996bf=_0x111100;console[_0x4996bf('0x52a')](_0x2072cc),_0x168589[_0x4996bf('0x17f')]=_0x2072cc['data'][_0x4996bf('0x17f')]||[{'message':_0x2072cc[_0x4996bf('0x1ff0')](),'type':'api.item.delete'}];});},function(){});}function _0x5ab09e(){const _0x110837=_0x1c5458;return _0x168589['item'][_0x110837('0x113b')]!==undefined?_0x168589['item'][_0x110837('0x113b')]:'Please\x20select\x20a\x20variable';}function _0x391c9c(){const _0x3cdd98=_0x1c5458;_0x990244[_0x3cdd98('0x1715')]();}}const _0x35cbaf=_0x526dc6;_0x1d4529[_0x189033('0x14be')]=['$state','$location',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),'Auth',_0x189033('0x1602'),_0x189033('0x22df')];function _0x1d4529(_0x5beb85,_0x4febba,_0x404d00,_0x3cba5b,_0x264ff3,_0x1fa86d,_0x52038d,_0xc7b777,_0x3b1ec3,_0x19443f,_0x4bd38f,_0x2389d8){const _0x731a1e=_0x189033,_0xdf96a1=this;_0xdf96a1[_0x731a1e('0x11ed')]=_0x19443f[_0x731a1e('0x20b2')](),_0xdf96a1[_0x731a1e('0xace')]=_0x1fa86d,_0xdf96a1[_0x731a1e('0x260a')]=_0x52038d,_0xdf96a1[_0x731a1e('0x19b2')]=_0xdf96a1['setting'][_0x731a1e('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xdf96a1['location']=_0x4febba[_0x731a1e('0x173e')]()+_0x731a1e('0x20de')+_0x4febba[_0x731a1e('0x19ac')](),_0xdf96a1[_0x731a1e('0x1602')]=_0x4bd38f||_0x5beb85[_0x731a1e('0x7f2')][_0x731a1e('0x1602')]||{},_0xdf96a1[_0x731a1e('0x22df')]=_0x2389d8&&_0x2389d8[_0x731a1e('0x50d')]==0x1?_0x2389d8[_0x731a1e('0xf5d')][0x0]:null,_0xdf96a1[_0x731a1e('0x1134')]=_0x19443f[_0x731a1e('0x142a')](_0xdf96a1['userProfileSection']?_0xdf96a1[_0x731a1e('0x22df')][_0x731a1e('0x1134')]:null),_0xdf96a1['hasModulePermissions']={},_0xdf96a1['selectedTab']=_0x5beb85['params'][_0x731a1e('0x1904')]||0x0,_0xdf96a1['alert']=_0x3b1ec3[_0x731a1e('0x2289')],_0xdf96a1[_0x731a1e('0x132e')]=_0x2dcbb2,_0xdf96a1[_0x731a1e('0xa0f')]=_0x481a46;function _0x2dcbb2(){const _0x2545c4=_0x731a1e;_0x5beb85['go'](_0x2545c4('0x6ff'),{},{'reload':_0x2545c4('0x6ff')});}function _0x481a46(){const _0x2932b3=_0x731a1e;_0xc7b777[_0x2932b3('0x1a0')][_0x2932b3('0x2480')]({'id':_0xdf96a1[_0x2932b3('0x1602')]['id']},_0xdf96a1['zendeskAccount'])[_0x2932b3('0xe53')][_0x2932b3('0x683')](function(){const _0x2b496b=_0x2932b3;_0x3b1ec3[_0x2b496b('0x53')]({'title':_0x2b496b('0xe19'),'msg':_0xdf96a1[_0x2b496b('0x1602')]['name']?_0xdf96a1[_0x2b496b('0x1602')][_0x2b496b('0x60a')]+_0x2b496b('0x96c'):''});})[_0x2932b3('0x130a')](function(_0x37032e){const _0x37d838=_0x2932b3;_0x3b1ec3[_0x37d838('0x52a')]({'title':_0x37032e['status']?_0x37d838('0x2168')+_0x37032e[_0x37d838('0x13ee')]+'\x20-\x20'+_0x37032e[_0x37d838('0x24a9')]:_0x37d838('0xee2'),'msg':_0x37032e[_0x37d838('0x5a5')]?JSON[_0x37d838('0x258a')](_0x37032e[_0x37d838('0x5a5')]):_0x37032e[_0x37d838('0x1ff0')]()});});}}const _0x18c387=_0x1d4529,_0x2940d0=_0x180212['p']+_0x189033('0x966'),_0x42eb6a=_0x180212['p']+'src/js/modules/main/apps/integrations/views/zendeskAccounts/edit/item/dialog.html/dialog.html';_0x2b7c27[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$document','api',_0x189033('0x1d70'),_0x189033('0xba1')];function _0x2b7c27(_0x1e94c9,_0xce8e84,_0x861ebe,_0x39c9a,_0x458bc5){const _0x41895c=_0x189033,_0x4f73d3=this;_0x4f73d3[_0x41895c('0x11ed')]=_0x458bc5[_0x41895c('0x20b2')](),_0x4f73d3['zendeskAccount']={},_0x4f73d3[_0x41895c('0x147e')]={},_0x4f73d3[_0x41895c('0x248d')]=[],_0x4f73d3[_0x41895c('0x21f2')]=-0x1,_0x4f73d3[_0x41895c('0x1134')],_0x4f73d3[_0x41895c('0x12f3')]=_0x22bb21,_0x4f73d3[_0x41895c('0xa59')]=_0x3b9a4b,_0x4f73d3[_0x41895c('0x2890')]=_0x21982a,_0x4f73d3[_0x41895c('0xef')]=_0x41caf6,_0x4f73d3['selectedTags']=[],_0x4f73d3['selectTagsChanged']=_0x14faaf,_0x861ebe['tag'][_0x41895c('0x1e6e')]({'nolimit':!![],'sort':'name'})[_0x41895c('0xe53')][_0x41895c('0x683')](function(_0x4f4705){const _0x4e5c35=_0x41895c;_0x4f73d3[_0x4e5c35('0x1ce6')]=_0x4f4705[_0x4e5c35('0xf5d')]?_0x4f4705[_0x4e5c35('0xf5d')]:[];})[_0x41895c('0x130a')](function(_0x34246f){const _0x103736=_0x41895c;_0x39c9a[_0x103736('0x52a')]({'title':_0x34246f[_0x103736('0x13ee')]?_0x103736('0x2168')+_0x34246f[_0x103736('0x13ee')]+'\x20-\x20'+_0x34246f[_0x103736('0x24a9')]:'SYSTEM:GETTAGS','msg':_0x34246f[_0x103736('0x5a5')]?JSON[_0x103736('0x258a')](_0x34246f[_0x103736('0x5a5')]):_0x34246f[_0x103736('0x1ff0')]()});});function _0x14faaf(){const _0x546494=_0x41895c;_0x861ebe[_0x546494('0xeeb')][_0x546494('0x167d')]({'id':_0x4f73d3[_0x546494('0x147e')]['id'],'ids':_0x4f73d3[_0x546494('0x2100')]})[_0x546494('0xe53')][_0x546494('0x683')](function(){const _0x204f12=_0x546494;_0x39c9a[_0x204f12('0x53')]({'title':_0x204f12('0xc9b'),'msg':'Tags\x20has\x20been\x20set!'});})[_0x546494('0x130a')](function(_0x289dfa){const _0x47b566=_0x546494;_0x39c9a[_0x47b566('0x52a')]({'title':_0x289dfa['status']?_0x47b566('0x2168')+_0x289dfa[_0x47b566('0x13ee')]+_0x47b566('0xbf6')+_0x289dfa['statusText']:_0x47b566('0x137d'),'msg':_0x289dfa[_0x47b566('0x5a5')]?JSON['stringify'](_0x289dfa[_0x47b566('0x5a5')]):_0x289dfa['toString']()});});}function _0x22bb21(_0x182428,_0x1b86fa){const _0x360b44=_0x41895c;_0x4f73d3[_0x360b44('0x1602')]=_0x182428,_0x4f73d3['crudPermissions']=typeof _0x1b86fa!==_0x360b44('0x1867')?_0x1b86fa:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x861ebe[_0x360b44('0x1a0')]['getConfigurations']({'id':_0x4f73d3[_0x360b44('0x1602')]['id'],'sort':_0x360b44('0xc36')})[_0x360b44('0xe53')][_0x360b44('0x683')](function(_0x3b58be){const _0x21691e=_0x360b44;return _0x4f73d3[_0x21691e('0x248d')]=_0x3b58be[_0x21691e('0xf5d')]?_0x3b58be[_0x21691e('0xf5d')]:[],_0x4f73d3[_0x21691e('0x248d')][_0x21691e('0x1564')]&&_0x4f73d3[_0x21691e('0xa59')](0x0),_0x861ebe[_0x21691e('0x26e0')][_0x21691e('0x1e6e')]({'nolimit':!![],'sort':'name'})[_0x21691e('0xe53')];})['then'](function(_0x50203c){const _0x4b1e92=_0x360b44;_0x4f73d3[_0x4b1e92('0x220b')]=_0x50203c[_0x4b1e92('0xf5d')]?_0x50203c[_0x4b1e92('0xf5d')]:[],_0x4f73d3[_0x4b1e92('0x1822')]=_0x2e3ca0()[_0x4b1e92('0x24db')](_0x4f73d3[_0x4b1e92('0x220b')],'id');})[_0x360b44('0x130a')](function(_0x412d3a){const _0x4cdf3f=_0x360b44;_0x39c9a['error']({'title':_0x412d3a['status']?_0x4cdf3f('0x2168')+_0x412d3a['status']+_0x4cdf3f('0xbf6')+_0x412d3a['statusText']:_0x4cdf3f('0xe2a'),'msg':_0x412d3a[_0x4cdf3f('0x5a5')]?JSON[_0x4cdf3f('0x258a')](_0x412d3a[_0x4cdf3f('0x5a5')]):_0x412d3a[_0x4cdf3f('0x1ff0')]()});});}function _0x3b9a4b(_0x519abb){const _0x14b623=_0x41895c;_0x4f73d3[_0x14b623('0x147e')]=_0x4f73d3[_0x14b623('0x248d')][_0x519abb],_0x4f73d3['selectedZendeskConfiguration']=_0x519abb,_0x861ebe[_0x14b623('0xeeb')]['getSubjects']({'id':_0x4f73d3[_0x14b623('0x147e')]['id']})['$promise'][_0x14b623('0x683')](function(_0x1971bb){const _0x293863=_0x14b623;return _0x4f73d3['subjects']=_0x1971bb[_0x293863('0xf5d')]?_0x1971bb[_0x293863('0xf5d')]:[],_0x861ebe[_0x293863('0xeeb')][_0x293863('0x412')]({'id':_0x4f73d3['zendeskConfiguration']['id']})[_0x293863('0xe53')];})[_0x14b623('0x683')](function(_0xec309e){const _0x46b519=_0x14b623;return _0x4f73d3['descriptions']=_0xec309e[_0x46b519('0xf5d')]?_0xec309e[_0x46b519('0xf5d')]:[],_0x861ebe[_0x46b519('0xeeb')]['getFields']({'id':_0x4f73d3[_0x46b519('0x147e')]['id']})[_0x46b519('0xe53')];})['then'](function(_0x3bb475){const _0x23e503=_0x14b623;_0x4f73d3[_0x23e503('0x189a')]=_0x3bb475[_0x23e503('0xf5d')]?_0x3bb475[_0x23e503('0xf5d')]:[];})[_0x14b623('0x130a')](function(_0x1d86ab){const _0xf1e2c7=_0x14b623;_0x39c9a[_0xf1e2c7('0x52a')]({'title':_0x1d86ab[_0xf1e2c7('0x13ee')]?_0xf1e2c7('0x2168')+_0x1d86ab['status']+'\x20-\x20'+_0x1d86ab[_0xf1e2c7('0x24a9')]:_0xf1e2c7('0x167c'),'msg':_0x1d86ab[_0xf1e2c7('0x5a5')]?JSON[_0xf1e2c7('0x258a')](_0x1d86ab[_0xf1e2c7('0x5a5')]):_0x1d86ab[_0xf1e2c7('0x1ff0')]()});}),_0x861ebe[_0x14b623('0xeeb')]['getTags']({'id':_0x4f73d3[_0x14b623('0x147e')]['id']})['$promise'][_0x14b623('0x683')](function(_0x418b04){const _0x491b6c=_0x14b623;_0x4f73d3[_0x491b6c('0x2100')]=_0x418b04['rows']?_0x2e3ca0()[_0x491b6c('0x386')](_0x418b04['rows'],'id'):[];})[_0x14b623('0x130a')](function(_0x35c8c4){const _0x1fc8ce=_0x14b623;_0x39c9a[_0x1fc8ce('0x52a')]({'title':_0x35c8c4[_0x1fc8ce('0x13ee')]?_0x1fc8ce('0x2168')+_0x35c8c4['status']+'\x20-\x20'+_0x35c8c4['statusText']:'SYSTEM:GETTAGS','msg':_0x35c8c4[_0x1fc8ce('0x5a5')]?JSON['stringify'](_0x35c8c4[_0x1fc8ce('0x5a5')]):_0x35c8c4['toString']()});});}function _0x21982a(_0x2c59bf,_0x144161){const _0x300ce5=_0x41895c;_0x1e94c9[_0x300ce5('0x1d4')]({'controller':_0x300ce5('0x6c5'),'controllerAs':'vm','templateUrl':_0x2940d0,'parent':angular['element'](_0xce8e84[_0x300ce5('0x18e5')]),'targetEvent':_0x2c59bf,'clickOutsideToClose':!![],'locals':{'zendeskConfiguration':_0x144161,'zendeskConfigurations':_0x4f73d3[_0x300ce5('0x248d')],'license':null,'setting':null,'crudPermissions':_0x4f73d3['crudPermissions']}})[_0x300ce5('0x2874')](function(){const _0x5f0a77=_0x300ce5;_0x4f73d3[_0x5f0a77('0xa59')](0x0);});}function _0x41caf6(_0xcc97a1,_0x4eb1e9){const _0x3aa602=_0x41895c,_0x4b0b04=_0x1e94c9[_0x3aa602('0x1c6f')]()[_0x3aa602('0xf28')](_0x3aa602('0x15ec'))[_0x3aa602('0x26e3')](_0x3aa602('0xed5')+(_0x4eb1e9['name']||'zendeskConfiguration')+_0x3aa602('0x20f1')+_0x3aa602('0x1ee7'))[_0x3aa602('0x1040')](_0x3aa602('0x1e8e'))[_0x3aa602('0xe42')](_0xcc97a1)['ok']('OK')[_0x3aa602('0x19fb')](_0x3aa602('0x16b8'));_0x1e94c9[_0x3aa602('0x1d4')](_0x4b0b04)[_0x3aa602('0x683')](function(){const _0x3bbe07=_0x3aa602;_0x861ebe[_0x3bbe07('0xeeb')][_0x3bbe07('0xd7e')]({'id':_0x4eb1e9['id']})['$promise'][_0x3bbe07('0x683')](function(){const _0x9e8ecb=_0x3bbe07;_0x2e3ca0()[_0x9e8ecb('0x3ec')](_0x4f73d3[_0x9e8ecb('0x248d')],{'id':_0x4eb1e9['id']}),_0x39c9a[_0x9e8ecb('0x53')]({'title':_0x9e8ecb('0x26f4'),'msg':_0x4eb1e9[_0x9e8ecb('0x60a')]?_0x4eb1e9['name']+'\x20has\x20been\x20deleted!':''});})[_0x3bbe07('0x130a')](function(_0x453dec){const _0x567d30=_0x3bbe07;_0x39c9a[_0x567d30('0x52a')]({'title':_0x453dec[_0x567d30('0x13ee')]?_0x567d30('0x2168')+_0x453dec[_0x567d30('0x13ee')]+_0x567d30('0xbf6')+_0x453dec[_0x567d30('0x24a9')]:_0x567d30('0x1e44'),'msg':_0x453dec[_0x567d30('0x5a5')]?JSON['stringify'](_0x453dec[_0x567d30('0x5a5')]):_0x453dec[_0x567d30('0x1ff0')]()});})[_0x3bbe07('0x2874')](function(){const _0x52b069=_0x3bbe07;_0x4f73d3[_0x52b069('0xa59')](0x0);});},function(){const _0x3ff76a=_0x3aa602;console[_0x3ff76a('0x1b2b')](_0x3ff76a('0x16b8'));});}_0x4f73d3['selectedSubjects']=[],_0x4f73d3[_0x41895c('0x2654')]=_0x59d266,_0x4f73d3['deleteSubjectConfirm']=_0x4d3aba,_0x4f73d3[_0x41895c('0x1734')]=_0x35af7a;function _0x59d266(_0x208b52,_0x370d42){const _0x50a916=_0x41895c;_0x1e94c9['show']({'controller':_0x50a916('0x1223'),'controllerAs':'vm','templateUrl':_0x42eb6a,'parent':angular[_0x50a916('0x1fcc')](_0xce8e84['body']),'targetEvent':_0x208b52,'clickOutsideToClose':!![],'locals':{'type':_0x50a916('0x1e66'),'item':_0x370d42,'items':_0x4f73d3[_0x50a916('0x1ead')],'configuration':_0x4f73d3[_0x50a916('0x147e')],'account':_0x4f73d3[_0x50a916('0x1602')],'license':null,'setting':null,'crudPermissions':_0x4f73d3[_0x50a916('0x1134')]}});}function _0x14dde0(_0x35e8d1){const _0x201be1=_0x41895c;_0x861ebe[_0x201be1('0xb26')][_0x201be1('0xd7e')]({'id':_0x35e8d1['id']})[_0x201be1('0xe53')]['then'](function(){const _0x5ba03b=_0x201be1;_0x2e3ca0()[_0x5ba03b('0x3ec')](_0x4f73d3['subjects'],{'id':_0x35e8d1['id']}),_0x39c9a['success']({'title':_0x5ba03b('0x637'),'msg':_0x5ba03b('0x2795')});})['catch'](function(_0x1fa6a3){const _0x5843be=_0x201be1;_0x39c9a[_0x5843be('0x52a')]({'title':_0x1fa6a3[_0x5843be('0x13ee')]?_0x5843be('0x2168')+_0x1fa6a3[_0x5843be('0x13ee')]+_0x5843be('0xbf6')+_0x1fa6a3['statusText']:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x1fa6a3[_0x5843be('0x5a5')]?JSON[_0x5843be('0x258a')](_0x1fa6a3[_0x5843be('0x5a5')]):_0x1fa6a3[_0x5843be('0x1ff0')]()});});}function _0x4d3aba(_0x188243,_0x393583){const _0x38394b=_0x41895c,_0x3b6548=_0x1e94c9[_0x38394b('0x1c6f')]()[_0x38394b('0xf28')](_0x38394b('0x17ed'))[_0x38394b('0x26e3')](_0x38394b('0x601')+_0x38394b('0x1ee7'))[_0x38394b('0x1040')](_0x38394b('0x20d'))[_0x38394b('0xe42')](_0x188243)['ok']('OK')['cancel'](_0x38394b('0x16b8'));_0x1e94c9[_0x38394b('0x1d4')](_0x3b6548)[_0x38394b('0x683')](function(){_0x14dde0(_0x393583);},function(){const _0x370b79=_0x38394b;console[_0x370b79('0x1b2b')](_0x370b79('0x16b8'));});}function _0x35af7a(_0x4f79d3){const _0x2deea6=_0x41895c,_0x36a55b=_0x1e94c9[_0x2deea6('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20subjects?')[_0x2deea6('0x26e3')](_0x2deea6('0xed5')+_0x4f73d3[_0x2deea6('0x1781')]['length']+_0x2deea6('0x93c')+_0x2deea6('0x1ee7'))[_0x2deea6('0x1040')](_0x2deea6('0x9fb'))[_0x2deea6('0xe42')](_0x4f79d3)['ok']('OK')[_0x2deea6('0x19fb')](_0x2deea6('0x16b8'));_0x1e94c9[_0x2deea6('0x1d4')](_0x36a55b)[_0x2deea6('0x683')](function(){const _0x346f71=_0x2deea6;_0x4f73d3[_0x346f71('0x1781')][_0x346f71('0x1299')](function(_0x39e939){_0x14dde0(_0x39e939);}),_0x4f73d3['selectedSubjects']=[];});}_0x4f73d3[_0x41895c('0xcb1')]=[],_0x4f73d3[_0x41895c('0x1094')]=_0xcb543d,_0x4f73d3['deleteDescriptionConfirm']=_0x3fa0b8,_0x4f73d3[_0x41895c('0x27df')]=_0x2e4ef1;function _0xcb543d(_0x2f7139,_0x3e898c){const _0x12810c=_0x41895c;_0x1e94c9[_0x12810c('0x1d4')]({'controller':_0x12810c('0x1223'),'controllerAs':'vm','templateUrl':_0x42eb6a,'parent':angular['element'](_0xce8e84[_0x12810c('0x18e5')]),'targetEvent':_0x2f7139,'clickOutsideToClose':!![],'locals':{'type':'description','item':_0x3e898c,'items':_0x4f73d3[_0x12810c('0x18f7')],'configuration':_0x4f73d3[_0x12810c('0x147e')],'account':_0x4f73d3[_0x12810c('0x1602')],'license':null,'setting':null,'crudPermissions':_0x4f73d3[_0x12810c('0x1134')]}});}function _0x571c01(_0x473696){const _0x306067=_0x41895c;_0x861ebe[_0x306067('0xb26')][_0x306067('0xd7e')]({'id':_0x473696['id']})['$promise']['then'](function(){const _0x4363fa=_0x306067;_0x2e3ca0()['remove'](_0x4f73d3[_0x4363fa('0x18f7')],{'id':_0x473696['id']}),_0x39c9a[_0x4363fa('0x53')]({'title':_0x4363fa('0x1cf8'),'msg':'Description\x20has\x20been\x20deleted!'});})['catch'](function(_0x33ed67){const _0x58fcc0=_0x306067;_0x39c9a[_0x58fcc0('0x52a')]({'title':_0x33ed67[_0x58fcc0('0x13ee')]?'API:'+_0x33ed67['status']+_0x58fcc0('0xbf6')+_0x33ed67[_0x58fcc0('0x24a9')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x33ed67[_0x58fcc0('0x5a5')]?JSON[_0x58fcc0('0x258a')](_0x33ed67[_0x58fcc0('0x5a5')]):_0x33ed67[_0x58fcc0('0x1ff0')]()});});}function _0x3fa0b8(_0x27f7b7,_0x408a89){const _0x2f887c=_0x41895c,_0x3f9e61=_0x1e94c9[_0x2f887c('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20description?')['htmlContent'](_0x2f887c('0xd5e')+'\x20will\x20be\x20deleted.')[_0x2f887c('0x1040')](_0x2f887c('0x221c'))['targetEvent'](_0x27f7b7)['ok']('OK')['cancel'](_0x2f887c('0x16b8'));_0x1e94c9[_0x2f887c('0x1d4')](_0x3f9e61)[_0x2f887c('0x683')](function(){_0x571c01(_0x408a89);},function(){const _0x224d8e=_0x2f887c;console[_0x224d8e('0x1b2b')](_0x224d8e('0x16b8'));});}function _0x2e4ef1(_0x5c2006){const _0x2744d1=_0x41895c,_0x1a7758=_0x1e94c9['confirm']()[_0x2744d1('0xf28')](_0x2744d1('0x1984'))[_0x2744d1('0x26e3')](''+_0x4f73d3[_0x2744d1('0xcb1')][_0x2744d1('0x1564')]+_0x2744d1('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel']('delete\x20descriptions')[_0x2744d1('0xe42')](_0x5c2006)['ok']('OK')[_0x2744d1('0x19fb')](_0x2744d1('0x16b8'));_0x1e94c9['show'](_0x1a7758)[_0x2744d1('0x683')](function(){const _0x583039=_0x2744d1;_0x4f73d3['selectedDescriptions'][_0x583039('0x1299')](function(_0x503958){_0x571c01(_0x503958);}),_0x4f73d3[_0x583039('0xcb1')]=[];});}_0x4f73d3[_0x41895c('0x310')]=[],_0x4f73d3['createOrEditField']=_0x2d5af8,_0x4f73d3[_0x41895c('0x9f9')]=_0x197c0e,_0x4f73d3['deleteSelectedFields']=_0x1888e7;function _0x2d5af8(_0x388202,_0x47ba8f){const _0x3b6f03=_0x41895c;_0x1e94c9[_0x3b6f03('0x1d4')]({'controller':_0x3b6f03('0x1223'),'controllerAs':'vm','templateUrl':_0x42eb6a,'parent':angular[_0x3b6f03('0x1fcc')](_0xce8e84['body']),'targetEvent':_0x388202,'clickOutsideToClose':!![],'locals':{'type':'field','item':_0x47ba8f,'items':_0x4f73d3['fields'],'configuration':_0x4f73d3[_0x3b6f03('0x147e')],'account':_0x4f73d3[_0x3b6f03('0x1602')],'license':null,'setting':null,'crudPermissions':_0x4f73d3[_0x3b6f03('0x1134')]}});}function _0x54394b(_0x33c27d){const _0x10dc78=_0x41895c;_0x861ebe[_0x10dc78('0xb26')][_0x10dc78('0xd7e')]({'id':_0x33c27d['id']})['$promise'][_0x10dc78('0x683')](function(){const _0x36aa5c=_0x10dc78;_0x2e3ca0()[_0x36aa5c('0x3ec')](_0x4f73d3[_0x36aa5c('0x189a')],{'id':_0x33c27d['id']}),_0x39c9a[_0x36aa5c('0x53')]({'title':_0x36aa5c('0x1666'),'msg':_0x36aa5c('0x1eda')});})[_0x10dc78('0x130a')](function(_0x235e05){const _0x1efdf1=_0x10dc78;_0x39c9a[_0x1efdf1('0x52a')]({'title':_0x235e05[_0x1efdf1('0x13ee')]?_0x1efdf1('0x2168')+_0x235e05[_0x1efdf1('0x13ee')]+_0x1efdf1('0xbf6')+_0x235e05[_0x1efdf1('0x24a9')]:_0x1efdf1('0x1d23'),'msg':_0x235e05['data']?JSON[_0x1efdf1('0x258a')](_0x235e05[_0x1efdf1('0x5a5')]):_0x235e05[_0x1efdf1('0x1ff0')]()});});}function _0x197c0e(_0x1ab460,_0x4ffb74){const _0x5a63b1=_0x41895c,_0x52bc8a=_0x1e94c9['confirm']()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x5a63b1('0x26e3')](_0x5a63b1('0x23b9')+_0x5a63b1('0x1ee7'))[_0x5a63b1('0x1040')]('delete\x20field')[_0x5a63b1('0xe42')](_0x1ab460)['ok']('OK')['cancel'](_0x5a63b1('0x16b8'));_0x1e94c9[_0x5a63b1('0x1d4')](_0x52bc8a)['then'](function(){_0x54394b(_0x4ffb74);},function(){const _0x5244f4=_0x5a63b1;console['log'](_0x5244f4('0x16b8'));});}function _0x1888e7(_0x2df6cd){const _0xe67131=_0x41895c,_0x3b4a2a=_0x1e94c9[_0xe67131('0x1c6f')]()['title'](_0xe67131('0x19b1'))[_0xe67131('0x26e3')](_0xe67131('0xed5')+_0x4f73d3[_0xe67131('0x310')][_0xe67131('0x1564')]+'\x20selected'+_0xe67131('0x1ee7'))['ariaLabel'](_0xe67131('0x994'))[_0xe67131('0xe42')](_0x2df6cd)['ok']('OK')[_0xe67131('0x19fb')]('CANCEL');_0x1e94c9['show'](_0x3b4a2a)[_0xe67131('0x683')](function(){const _0x21f168=_0xe67131;_0x4f73d3[_0x21f168('0x310')][_0x21f168('0x1299')](function(_0x4a7f39){_0x54394b(_0x4a7f39);}),_0x4f73d3['selectedFields']=[];});}}const _0x5026bf=_0x2b7c27;_0x124d8e[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),'zendeskConfigurations',_0x189033('0x147e'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x124d8e(_0x68d1b9,_0x4e7696,_0x34ccad,_0x20d3a1,_0x1f01e4,_0x52ca38,_0x2d4325,_0x5d0305,_0x582a39,_0x5405d9,_0x4e48e8,_0x105537,_0x73d28e,_0x36163c){const _0x4b4f5f=_0x189033,_0x73481c=this;_0x73481c[_0x4b4f5f('0x11ed')]=_0x4e48e8['getCurrentUser'](),_0x73481c[_0x4b4f5f('0x17f')]=[],_0x73481c[_0x4b4f5f('0x260a')]=_0x73d28e,_0x73481c[_0x4b4f5f('0xace')]=_0x105537,_0x73481c[_0x4b4f5f('0x1134')]=_0x36163c,_0x73481c[_0x4b4f5f('0x258d')]={},_0x73481c[_0x4b4f5f('0x19b2')]=_0x73481c['setting']&&_0x73481c[_0x4b4f5f('0x260a')][_0x4b4f5f('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x73481c[_0x4b4f5f('0xf28')]=_0x4b4f5f('0x639'),_0x73481c[_0x4b4f5f('0x147e')]=angular['copy'](_0x582a39),_0x73481c[_0x4b4f5f('0x248d')]=_0x5d0305,_0x73481c[_0x4b4f5f('0x1c85')]=![];!_0x73481c[_0x4b4f5f('0x147e')]&&(_0x73481c['zendeskConfiguration']={'channel':_0x4b4f5f('0xcf2'),'type':_0x4b4f5f('0x1535')},_0x73481c[_0x4b4f5f('0xf28')]=_0x4b4f5f('0x2643'),_0x73481c[_0x4b4f5f('0x1c85')]=!![]);_0x73481c['addNewZendeskConfiguration']=_0x4b9be3,_0x73481c[_0x4b4f5f('0x21d2')]=_0x48135c,_0x73481c[_0x4b4f5f('0xef')]=_0x3596ea,_0x73481c[_0x4b4f5f('0x16b3')]=_0x40c9ed,_0x73481c['closeDialog']=_0x2f65b0;function _0x4b9be3(){const _0x164e08=_0x4b4f5f;_0x73481c[_0x164e08('0x17f')]=[],_0x5405d9[_0x164e08('0x1a0')][_0x164e08('0x2003')]({'id':_0x4e7696[_0x164e08('0x7f2')]['id']},_0x73481c[_0x164e08('0x147e')])['$promise']['then'](function(_0x43c193){const _0x26e1e6=_0x164e08;_0x73481c[_0x26e1e6('0x248d')][_0x26e1e6('0x1167')](_0x43c193['toJSON']()),_0x2d4325[_0x26e1e6('0x53')]({'title':'ZendeskConfiguration\x20properly\x20created','msg':_0x73481c[_0x26e1e6('0x147e')][_0x26e1e6('0x60a')]?_0x73481c[_0x26e1e6('0x147e')]['name']+'\x20has\x20been\x20created!':''}),_0x2f65b0(_0x43c193);})[_0x164e08('0x130a')](function(_0x2c3a51){const _0x1085fe=_0x164e08;if(_0x2c3a51[_0x1085fe('0x5a5')]&&_0x2c3a51[_0x1085fe('0x5a5')][_0x1085fe('0x17f')]&&_0x2c3a51[_0x1085fe('0x5a5')][_0x1085fe('0x17f')][_0x1085fe('0x1564')]){_0x73481c[_0x1085fe('0x17f')]=_0x2c3a51[_0x1085fe('0x5a5')]['errors']||[{'message':_0x2c3a51['toString'](),'type':_0x1085fe('0x1d6e')}];for(let _0x24d3d2=0x0;_0x24d3d2<_0x2c3a51[_0x1085fe('0x5a5')][_0x1085fe('0x17f')][_0x1085fe('0x1564')];_0x24d3d2+=0x1){_0x2d4325[_0x1085fe('0x52a')]({'title':_0x2c3a51[_0x1085fe('0x5a5')][_0x1085fe('0x17f')][_0x24d3d2][_0x1085fe('0xcf0')],'msg':_0x2c3a51['data']['errors'][_0x24d3d2][_0x1085fe('0x8c2')]});}}else _0x2d4325[_0x1085fe('0x52a')]({'title':_0x2c3a51[_0x1085fe('0x13ee')]?_0x1085fe('0x2168')+_0x2c3a51['status']+_0x1085fe('0xbf6')+_0x2c3a51[_0x1085fe('0x24a9')]:'api.intZendeskConfiguration.save','msg':_0x2c3a51[_0x1085fe('0x5a5')]?JSON[_0x1085fe('0x258a')](_0x2c3a51[_0x1085fe('0x5a5')][_0x1085fe('0x8c2')]):_0x2c3a51['toString']()});});}function _0x48135c(){const _0x24b97b=_0x4b4f5f;_0x73481c[_0x24b97b('0x17f')]=[],_0x5405d9[_0x24b97b('0xeeb')][_0x24b97b('0x2480')]({'id':_0x73481c[_0x24b97b('0x147e')]['id']},_0x73481c[_0x24b97b('0x147e')])[_0x24b97b('0xe53')]['then'](function(_0x498ed2){const _0x5d3303=_0x24b97b,_0x141f78=_0x2e3ca0()[_0x5d3303('0x1c07')](_0x73481c['zendeskConfigurations'],{'id':_0x498ed2['id']});_0x141f78&&_0x2e3ca0()[_0x5d3303('0xf22')](_0x141f78,_0x2e3ca0()[_0x5d3303('0x24d0')](_0x498ed2[_0x5d3303('0x24e1')](),_0x2e3ca0()[_0x5d3303('0x55e')](_0x141f78))),_0x2d4325[_0x5d3303('0x53')]({'title':'ZendeskConfiguration\x20properly\x20saved!','msg':_0x73481c[_0x5d3303('0x147e')]['name']?_0x73481c[_0x5d3303('0x147e')][_0x5d3303('0x60a')]+_0x5d3303('0xf59'):''}),_0x2f65b0(_0x498ed2);})[_0x24b97b('0x130a')](function(_0x2cedea){const _0x23a693=_0x24b97b;if(_0x2cedea[_0x23a693('0x5a5')]&&_0x2cedea[_0x23a693('0x5a5')][_0x23a693('0x17f')]&&_0x2cedea[_0x23a693('0x5a5')][_0x23a693('0x17f')][_0x23a693('0x1564')]){_0x73481c['errors']=_0x2cedea[_0x23a693('0x5a5')][_0x23a693('0x17f')]||[{'message':_0x2cedea[_0x23a693('0x1ff0')](),'type':_0x23a693('0x1bfc')}];for(let _0x37349e=0x0;_0x37349e<_0x2cedea[_0x23a693('0x5a5')]['errors'][_0x23a693('0x1564')];_0x37349e++){_0x2d4325[_0x23a693('0x52a')]({'title':_0x2cedea[_0x23a693('0x5a5')]['errors'][_0x37349e][_0x23a693('0xcf0')],'msg':_0x2cedea[_0x23a693('0x5a5')][_0x23a693('0x17f')][_0x37349e]['message']});}}else _0x2d4325[_0x23a693('0x52a')]({'title':_0x2cedea['status']?'API:'+_0x2cedea[_0x23a693('0x13ee')]+_0x23a693('0xbf6')+_0x2cedea[_0x23a693('0x24a9')]:'api.intZendeskConfiguration.update','msg':_0x2cedea[_0x23a693('0x5a5')]?JSON[_0x23a693('0x258a')](_0x2cedea[_0x23a693('0x5a5')][_0x23a693('0x8c2')]):_0x2cedea[_0x23a693('0x1ff0')]()});});}function _0x3596ea(_0x17b8a7){const _0x5867c4=_0x4b4f5f;_0x73481c[_0x5867c4('0x17f')]=[];const _0x1606e2=_0x20d3a1[_0x5867c4('0x1c6f')]()[_0x5867c4('0xf28')](_0x5867c4('0x4d'))[_0x5867c4('0xa6a')](_0x5867c4('0x27a0'))[_0x5867c4('0x1040')](_0x5867c4('0xdb8'))['ok']('Delete')[_0x5867c4('0x19fb')](_0x5867c4('0x253a'))['targetEvent'](_0x17b8a7);_0x20d3a1['show'](_0x1606e2)[_0x5867c4('0x683')](function(){const _0x42c588=_0x5867c4;_0x5405d9[_0x42c588('0xeeb')]['delete']({'id':_0x73481c['zendeskConfiguration']['id']})[_0x42c588('0xe53')][_0x42c588('0x683')](function(){const _0x4f679c=_0x42c588;_0x2e3ca0()[_0x4f679c('0x3ec')](_0x73481c[_0x4f679c('0x248d')],{'id':_0x73481c[_0x4f679c('0x147e')]['id']}),_0x2d4325[_0x4f679c('0x53')]({'title':_0x4f679c('0xe62'),'msg':(_0x73481c[_0x4f679c('0x147e')][_0x4f679c('0x60a')]||_0x4f679c('0x147e'))+_0x4f679c('0x194d')}),_0x2f65b0(_0x73481c[_0x4f679c('0x147e')]);})[_0x42c588('0x130a')](function(_0x45ad69){const _0x2bacf4=_0x42c588;if(_0x45ad69[_0x2bacf4('0x5a5')]&&_0x45ad69[_0x2bacf4('0x5a5')]['errors']&&_0x45ad69[_0x2bacf4('0x5a5')][_0x2bacf4('0x17f')]['length']){_0x73481c['errors']=_0x45ad69[_0x2bacf4('0x5a5')]['errors']||[{'message':_0x45ad69[_0x2bacf4('0x1ff0')](),'type':_0x2bacf4('0x18dc')}];for(let _0x2b74aa=0x0;_0x2b74aa<_0x45ad69[_0x2bacf4('0x5a5')][_0x2bacf4('0x17f')][_0x2bacf4('0x1564')];_0x2b74aa++){_0x2d4325[_0x2bacf4('0x52a')]({'title':_0x45ad69[_0x2bacf4('0x5a5')][_0x2bacf4('0x17f')][_0x2b74aa]['type'],'msg':_0x45ad69['data']['errors'][_0x2b74aa][_0x2bacf4('0x8c2')]});}}else _0x2d4325[_0x2bacf4('0x52a')]({'title':_0x45ad69[_0x2bacf4('0x13ee')]?_0x2bacf4('0x2168')+_0x45ad69[_0x2bacf4('0x13ee')]+_0x2bacf4('0xbf6')+_0x45ad69[_0x2bacf4('0x24a9')]:_0x2bacf4('0x18dc'),'msg':_0x45ad69[_0x2bacf4('0x5a5')]?JSON[_0x2bacf4('0x258a')](_0x45ad69[_0x2bacf4('0x5a5')][_0x2bacf4('0x8c2')]):_0x45ad69[_0x2bacf4('0x8c2')]||_0x45ad69[_0x2bacf4('0x1ff0')]()});});},function(){});}function _0x40c9ed(_0x91311d){return _0x91311d===null?undefined:new Date(_0x91311d);}function _0x2f65b0(_0x7d1ba1){const _0x255889=_0x4b4f5f;_0x20d3a1[_0x255889('0x1715')](_0x7d1ba1);}}const _0x257f5f=_0x124d8e,_0x1e3c38=_0x180212['p']+_0x189033('0x152');_0x39c6d6[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0x320'),_0x189033('0x2a'),'userProfileSection',_0x189033('0x56b'),_0x189033('0x1cc2'),'toasty',_0x189033('0xba1'),'license',_0x189033('0x260a')];function _0x39c6d6(_0x22bbb1,_0x2811c8,_0x2ef31f,_0x474589,_0x197811,_0x1fe2cb,_0x5c254a,_0x166c5d,_0x304ffe,_0x1b15b3,_0x167035,_0x2fbf06,_0x226954,_0x10a9fb,_0x5e480e,_0x2bbb5e,_0x11c2b9){const _0x21c682=_0x189033,_0x3908bc=this;_0x3908bc['license']=_0x2bbb5e,_0x3908bc['setting']=_0x11c2b9,_0x3908bc[_0x21c682('0x11ed')]=_0x5e480e[_0x21c682('0x20b2')](),_0x3908bc['zendeskAccounts']=_0x304ffe||{'count':0x0,'rows':[]},_0x3908bc[_0x21c682('0x2a')]=_0x1b15b3,_0x3908bc[_0x21c682('0x22df')]=_0x167035&&_0x167035[_0x21c682('0x50d')]==0x1?_0x167035[_0x21c682('0xf5d')][0x0]:null,_0x3908bc['crudPermissions']=_0x5e480e['parseCrudPermissions'](_0x3908bc[_0x21c682('0x22df')]?_0x3908bc['userProfileSection']['crudPermissions']:null),_0x3908bc[_0x21c682('0x5c4')]=_0x21c682('0x320'),_0x3908bc[_0x21c682('0x247')]='',_0x3908bc['listOrderAsc']=null,_0x3908bc[_0x21c682('0x272f')]=[],_0x3908bc[_0x21c682('0x23a2')]={'fields':_0x21c682('0x1695'),'limit':0xa,'page':0x1},_0x3908bc[_0x21c682('0x10b7')]=_0x2e3ca0()[_0x21c682('0x24db')]([{'option':'Integration_Tab','value':'\x27integrationTab\x27'},{'option':_0x21c682('0x24ac'),'value':_0x21c682('0xf78')}],function(_0x316a33){return _0x2e3ca0()['replace'](_0x316a33['value'],new RegExp('\x27','g'),'');}),_0x3908bc[_0x21c682('0x31b')]=_0x2e3ca0()[_0x21c682('0x24db')]([{'option':'Password','value':_0x21c682('0xd9c')},{'option':'Token','value':_0x21c682('0xd3')}],function(_0x1b18d8){const _0xd6120=_0x21c682;return _0x2e3ca0()['replace'](_0x1b18d8[_0xd6120('0x1c6b')],new RegExp('\x27','g'),'');}),_0x3908bc[_0x21c682('0xc63')]=_0x3f9e00,_0x3908bc[_0x21c682('0x375')]=_0x49530d,_0x3908bc[_0x21c682('0x194f')]=_0x779c77,_0x3908bc[_0x21c682('0x53')]=_0x32b415,_0x3908bc[_0x21c682('0x16ce')]=_0x2ea219,_0x3908bc[_0x21c682('0x1a68')]=_0x2f73e4,_0x3908bc['deleteZendeskAccount']=_0x473214,_0x3908bc[_0x21c682('0x1bdd')]=_0x1e411e,_0x3908bc[_0x21c682('0x21c6')]=_0x1f4ebe,_0x3908bc[_0x21c682('0x1ba4')]=_0x28e715,_0x3908bc[_0x21c682('0x23ff')]=_0x18bb7f;function _0x3f9e00(_0x4065e0){const _0x1cf37c=_0x21c682;_0x2ef31f['go'](_0x1cf37c('0x1f66'),{'id':_0x4065e0['id'],'zendeskAccount':_0x4065e0,'crudPermissions':_0x3908bc[_0x1cf37c('0x1134')]});}function _0x49530d(_0x396dce){const _0x43056b=_0x21c682;return _0x2fbf06['intZendeskAccount'][_0x43056b('0x298')]({'id':_0x396dce['id'],'test':!![]})[_0x43056b('0xe53')][_0x43056b('0x683')](function(){const _0x2f5374=_0x43056b;_0x10a9fb[_0x2f5374('0x53')]({'title':'ZendeskAccount\x20properly\x20tested','msg':'Connection\x20succeded!'});})['catch'](function(_0x2f8de5){const _0x376b89=_0x43056b;_0x10a9fb['error']({'title':_0x376b89('0xae1'),'msg':_0x2f8de5[_0x376b89('0x5a5')]?_0x2f8de5['data'][_0x376b89('0x8c2')]?_0x2f8de5[_0x376b89('0x5a5')][_0x376b89('0x8c2')]:JSON[_0x376b89('0x258a')](_0x2f8de5[_0x376b89('0x5a5')]):_0x2f8de5[_0x376b89('0x1ff0')]()});});}function _0x779c77(_0x5b496d,_0x46a034){const _0x56a98e=_0x21c682,_0xe66f41=_0x197811[_0x56a98e('0x1c6f')]()[_0x56a98e('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x56a98e('0x1e03')](_0x56a98e('0x1602'))+'?')[_0x56a98e('0x26e3')](_0x56a98e('0xed5')+(_0x5b496d[_0x56a98e('0x60a')]||_0x56a98e('0x1602'))+''+_0x56a98e('0x1ee7'))['ariaLabel'](_0x56a98e('0x23af'))[_0x56a98e('0xe42')](_0x46a034)['ok']('OK')['cancel'](_0x56a98e('0x16b8'));_0x197811[_0x56a98e('0x1d4')](_0xe66f41)[_0x56a98e('0x683')](function(){_0x473214(_0x5b496d);},function(){const _0x4ca50f=_0x56a98e;console[_0x4ca50f('0x1b2b')]('CANCEL');});}let _0x423af3=!![],_0x1b57cd=0x1;_0x22bbb1[_0x21c682('0x186d')]('vm.query.filter',function(_0x3915d2,_0x1646ea){const _0x2341ae=_0x21c682;_0x423af3?_0x5c254a(function(){_0x423af3=![];}):(!_0x1646ea&&(_0x1b57cd=_0x3908bc[_0x2341ae('0x23a2')]['page']),_0x3915d2!==_0x1646ea&&(_0x3908bc[_0x2341ae('0x23a2')][_0x2341ae('0xdf8')]=0x1),!_0x3915d2&&(_0x3908bc[_0x2341ae('0x23a2')][_0x2341ae('0xdf8')]=_0x1b57cd),_0x3908bc[_0x2341ae('0x16ce')]());});function _0x32b415(_0x37050a){const _0x1aab45=_0x21c682;_0x3908bc[_0x1aab45('0x320')]=_0x37050a||{'count':0x0,'rows':[]};}function _0x2ea219(){const _0x498c7f=_0x21c682;_0x3908bc[_0x498c7f('0x23a2')][_0x498c7f('0x1cc8')]=(_0x3908bc[_0x498c7f('0x23a2')][_0x498c7f('0xdf8')]-0x1)*_0x3908bc['query']['limit'],_0x5e480e[_0x498c7f('0xca1')]('admin')?_0x3908bc[_0x498c7f('0x1883')]=_0x2fbf06[_0x498c7f('0x1a0')][_0x498c7f('0x1e6e')](_0x3908bc[_0x498c7f('0x23a2')],_0x32b415)['$promise']:(_0x3908bc[_0x498c7f('0x23a2')]['id']=_0x3908bc[_0x498c7f('0x2a')]['id'],_0x3908bc['query']['section']='ZendeskAccounts',_0x3908bc[_0x498c7f('0x1883')]=_0x2fbf06[_0x498c7f('0x2a')][_0x498c7f('0x241d')](_0x3908bc[_0x498c7f('0x23a2')],_0x32b415)[_0x498c7f('0xe53')]);}function _0x2f73e4(_0x3a7df3,_0x277d81){const _0x2715ce=_0x21c682;_0x197811['show']({'controller':_0x2715ce('0x109f'),'controllerAs':'vm','templateUrl':_0x1e3c38,'parent':angular[_0x2715ce('0x1fcc')](_0x1fe2cb[_0x2715ce('0x18e5')]),'targetEvent':_0x3a7df3,'clickOutsideToClose':!![],'locals':{'zendeskAccount':_0x277d81,'zendeskAccounts':_0x3908bc[_0x2715ce('0x320')][_0x2715ce('0xf5d')],'license':_0x3908bc[_0x2715ce('0xace')],'setting':_0x3908bc[_0x2715ce('0x260a')],'crudPermissions':_0x3908bc['crudPermissions']}});}function _0x473214(_0x24c133){const _0x225ca3=_0x21c682;_0x2fbf06[_0x225ca3('0x1a0')][_0x225ca3('0xd7e')]({'id':_0x24c133['id']})[_0x225ca3('0xe53')][_0x225ca3('0x683')](function(){const _0x29d23c=_0x225ca3;_0x2e3ca0()[_0x29d23c('0x3ec')](_0x3908bc[_0x29d23c('0x320')][_0x29d23c('0xf5d')],{'id':_0x24c133['id']}),_0x3908bc[_0x29d23c('0x320')]['count']-=0x1,!_0x3908bc[_0x29d23c('0x320')][_0x29d23c('0xf5d')][_0x29d23c('0x1564')]&&_0x3908bc[_0x29d23c('0x16ce')](),_0x10a9fb[_0x29d23c('0x53')]({'title':_0x2e3ca0()[_0x29d23c('0x1e03')]('ZendeskAccount')+_0x29d23c('0xbfc'),'msg':_0x24c133['name']?_0x24c133[_0x29d23c('0x60a')]+_0x29d23c('0x194d'):''});})[_0x225ca3('0x130a')](function(_0x255eb8){const _0x404a34=_0x225ca3;if(_0x255eb8[_0x404a34('0x5a5')]&&_0x255eb8['data'][_0x404a34('0x17f')]&&_0x255eb8[_0x404a34('0x5a5')][_0x404a34('0x17f')][_0x404a34('0x1564')]){_0x3908bc['errors']=_0x255eb8[_0x404a34('0x5a5')]['errors']||[{'message':_0x255eb8[_0x404a34('0x1ff0')](),'type':_0x404a34('0x23e2')}];for(let _0x175b2c=0x0;_0x175b2c<_0x255eb8[_0x404a34('0x5a5')][_0x404a34('0x17f')][_0x404a34('0x1564')];_0x175b2c++){_0x10a9fb[_0x404a34('0x52a')]({'title':_0x255eb8[_0x404a34('0x5a5')]['errors'][_0x175b2c][_0x404a34('0xcf0')],'msg':_0x255eb8[_0x404a34('0x5a5')][_0x404a34('0x17f')][_0x175b2c]['message']});}}else _0x10a9fb[_0x404a34('0x52a')]({'title':_0x255eb8[_0x404a34('0x13ee')]?_0x404a34('0x2168')+_0x255eb8[_0x404a34('0x13ee')]+_0x404a34('0xbf6')+_0x255eb8['statusText']:_0x404a34('0x23e2'),'msg':_0x255eb8[_0x404a34('0x5a5')]?JSON['stringify'](_0x255eb8[_0x404a34('0x5a5')][_0x404a34('0x8c2')]):_0x255eb8[_0x404a34('0x8c2')]||_0x255eb8[_0x404a34('0x1ff0')]()});});}function _0x1e411e(){const _0x5b15a1=_0x21c682,_0x31e066=angular[_0x5b15a1('0x1a86')](_0x3908bc[_0x5b15a1('0x272f')]);return _0x3908bc[_0x5b15a1('0x272f')]=[],_0x31e066;}function _0x1f4ebe(_0x159697){const _0xf2078f=_0x21c682,_0x3dd914=_0x197811[_0xf2078f('0x1c6f')]()[_0xf2078f('0xf28')](_0xf2078f('0xa6d'))[_0xf2078f('0x26e3')](_0xf2078f('0xed5')+_0x3908bc['selectedZendeskAccounts'][_0xf2078f('0x1564')]+'\x20selected'+_0xf2078f('0x1ee7'))[_0xf2078f('0x1040')](_0xf2078f('0x35c'))[_0xf2078f('0xe42')](_0x159697)['ok']('OK')[_0xf2078f('0x19fb')]('CANCEL');_0x197811[_0xf2078f('0x1d4')](_0x3dd914)['then'](function(){const _0x5036f5=_0xf2078f;_0x3908bc[_0x5036f5('0x272f')][_0x5036f5('0x1299')](function(_0x5e33fd){_0x473214(_0x5e33fd);}),_0x3908bc['selectedZendeskAccounts']=[];});}function _0x28e715(){_0x3908bc['selectedZendeskAccounts']=[];}function _0x18bb7f(){const _0x33988d=_0x21c682;_0x3908bc[_0x33988d('0x272f')]=_0x3908bc['zendeskAccounts']['rows'];}}const _0xedbff7=_0x39c6d6;_0x19256c[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),'zohoAccounts',_0x189033('0x149'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x19256c(_0xb30236,_0x202b5f,_0x2fbec1,_0x414c4e,_0x20b448,_0x4e6ce6,_0x5f4139,_0x596be6,_0x5eaf78,_0x5245aa,_0x140404,_0x36d98e,_0x4069a8,_0xec45c5){const _0x1fc383=_0x189033,_0x3a9fa2=this;_0x3a9fa2[_0x1fc383('0x11ed')]=_0x140404[_0x1fc383('0x20b2')](),_0x3a9fa2[_0x1fc383('0x17f')]=[],_0x3a9fa2['setting']=_0x4069a8,_0x3a9fa2['license']=_0x36d98e,_0x3a9fa2[_0x1fc383('0x1134')]=_0xec45c5,_0x3a9fa2['hasModulePermissions']={},_0x3a9fa2[_0x1fc383('0x19b2')]=_0x3a9fa2[_0x1fc383('0x260a')]&&_0x3a9fa2[_0x1fc383('0x260a')][_0x1fc383('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3a9fa2['title']='INTEGRATIONS.EDIT_ZOHOACCOUNT',_0x3a9fa2[_0x1fc383('0x149')]=angular[_0x1fc383('0x1a86')](_0x5eaf78),_0x3a9fa2[_0x1fc383('0xdd9')]=_0x596be6,_0x3a9fa2[_0x1fc383('0x18cf')]=![];!_0x3a9fa2[_0x1fc383('0x149')]&&(_0x3a9fa2[_0x1fc383('0x149')]={'host':_0x1fc383('0x211f'),'zone':'EU','serverUrl':_0x2fbec1['protocol']()+_0x1fc383('0x20de')+_0x2fbec1[_0x1fc383('0x19ac')]()+(_0x2fbec1[_0x1fc383('0x4a2')]()?':'+_0x2fbec1[_0x1fc383('0x4a2')]():'')},_0x3a9fa2[_0x1fc383('0xf28')]='INTEGRATIONS.NEW_ZOHOACCOUNT',_0x3a9fa2[_0x1fc383('0x18cf')]=!![]);_0x3a9fa2[_0x1fc383('0x73a')]=_0x12b140,_0x3a9fa2['saveZohoAccount']=_0x255739,_0x3a9fa2[_0x1fc383('0x7b9')]=_0x3b5187,_0x3a9fa2['getDateFromString']=_0x4c6eeb,_0x3a9fa2[_0x1fc383('0xf82')]=_0x11ee35;function _0x12b140(){const _0x348e0d=_0x1fc383;_0x3a9fa2['errors']=[],_0x5245aa[_0x348e0d('0xb6c')][_0x348e0d('0xb0a')](_0x3a9fa2['zohoAccount'])[_0x348e0d('0xe53')]['then'](function(_0x22fa46){const _0x44455a=_0x348e0d;_0x3a9fa2['zohoAccounts'][_0x44455a('0x1167')](_0x22fa46[_0x44455a('0x24e1')]()),_0x5f4139['success']({'title':'ZohoAccount\x20properly\x20created','msg':_0x3a9fa2[_0x44455a('0x149')]['name']?_0x3a9fa2[_0x44455a('0x149')][_0x44455a('0x60a')]+_0x44455a('0x14b5'):''}),_0x11ee35(_0x22fa46);})['catch'](function(_0x773581){const _0x4d98ab=_0x348e0d;if(_0x773581[_0x4d98ab('0x5a5')]&&_0x773581[_0x4d98ab('0x5a5')]['errors']&&_0x773581[_0x4d98ab('0x5a5')][_0x4d98ab('0x17f')]['length']){_0x3a9fa2['errors']=_0x773581['data'][_0x4d98ab('0x17f')]||[{'message':_0x773581[_0x4d98ab('0x1ff0')](),'type':'api.intZohoAccount.save'}];for(let _0x25a0b3=0x0;_0x25a0b3<_0x773581[_0x4d98ab('0x5a5')][_0x4d98ab('0x17f')]['length'];_0x25a0b3+=0x1){_0x5f4139['error']({'title':_0x773581[_0x4d98ab('0x5a5')]['errors'][_0x25a0b3][_0x4d98ab('0xcf0')],'msg':_0x773581[_0x4d98ab('0x5a5')][_0x4d98ab('0x17f')][_0x25a0b3][_0x4d98ab('0x8c2')]});}}else _0x5f4139[_0x4d98ab('0x52a')]({'title':_0x773581[_0x4d98ab('0x13ee')]?_0x4d98ab('0x2168')+_0x773581['status']+_0x4d98ab('0xbf6')+_0x773581[_0x4d98ab('0x24a9')]:'api.intZohoAccount.save','msg':_0x773581[_0x4d98ab('0x5a5')]?JSON[_0x4d98ab('0x258a')](_0x773581[_0x4d98ab('0x5a5')][_0x4d98ab('0x8c2')]):_0x773581[_0x4d98ab('0x1ff0')]()});});}function _0x255739(){const _0x20f6a6=_0x1fc383;_0x3a9fa2[_0x20f6a6('0x17f')]=[],_0x5245aa[_0x20f6a6('0xb6c')]['update']({'id':_0x3a9fa2[_0x20f6a6('0x149')]['id']},_0x3a9fa2[_0x20f6a6('0x149')])[_0x20f6a6('0xe53')][_0x20f6a6('0x683')](function(_0xa299a8){const _0x17b8f2=_0x20f6a6,_0xb1dfcf=_0x2e3ca0()[_0x17b8f2('0x1c07')](_0x3a9fa2[_0x17b8f2('0xdd9')],{'id':_0xa299a8['id']});_0xb1dfcf&&_0x2e3ca0()[_0x17b8f2('0xf22')](_0xb1dfcf,_0x2e3ca0()[_0x17b8f2('0x24d0')](_0xa299a8[_0x17b8f2('0x24e1')](),_0x2e3ca0()[_0x17b8f2('0x55e')](_0xb1dfcf))),_0x5f4139[_0x17b8f2('0x53')]({'title':_0x17b8f2('0x237f'),'msg':_0x3a9fa2['zohoAccount'][_0x17b8f2('0x60a')]?_0x3a9fa2[_0x17b8f2('0x149')][_0x17b8f2('0x60a')]+_0x17b8f2('0xf59'):''}),_0x11ee35(_0xa299a8);})[_0x20f6a6('0x130a')](function(_0x3aecf3){const _0x25cd7c=_0x20f6a6;if(_0x3aecf3[_0x25cd7c('0x5a5')]&&_0x3aecf3[_0x25cd7c('0x5a5')][_0x25cd7c('0x17f')]&&_0x3aecf3[_0x25cd7c('0x5a5')][_0x25cd7c('0x17f')]['length']){_0x3a9fa2[_0x25cd7c('0x17f')]=_0x3aecf3[_0x25cd7c('0x5a5')][_0x25cd7c('0x17f')]||[{'message':_0x3aecf3[_0x25cd7c('0x1ff0')](),'type':_0x25cd7c('0x2043')}];for(let _0x4b726a=0x0;_0x4b726a<_0x3aecf3['data'][_0x25cd7c('0x17f')]['length'];_0x4b726a++){_0x5f4139[_0x25cd7c('0x52a')]({'title':_0x3aecf3['data'][_0x25cd7c('0x17f')][_0x4b726a][_0x25cd7c('0xcf0')],'msg':_0x3aecf3[_0x25cd7c('0x5a5')][_0x25cd7c('0x17f')][_0x4b726a]['message']});}}else _0x5f4139[_0x25cd7c('0x52a')]({'title':_0x3aecf3[_0x25cd7c('0x13ee')]?_0x25cd7c('0x2168')+_0x3aecf3[_0x25cd7c('0x13ee')]+_0x25cd7c('0xbf6')+_0x3aecf3[_0x25cd7c('0x24a9')]:_0x25cd7c('0x2043'),'msg':_0x3aecf3[_0x25cd7c('0x5a5')]?JSON['stringify'](_0x3aecf3[_0x25cd7c('0x5a5')][_0x25cd7c('0x8c2')]):_0x3aecf3[_0x25cd7c('0x1ff0')]()});});}function _0x3b5187(_0x2e5315){const _0x4a2704=_0x1fc383;_0x3a9fa2[_0x4a2704('0x17f')]=[];const _0x3cc39a=_0x414c4e[_0x4a2704('0x1c6f')]()[_0x4a2704('0xf28')]('Are\x20you\x20sure?')[_0x4a2704('0xa6a')](_0x4a2704('0x24e6'))[_0x4a2704('0x1040')](_0x4a2704('0x1de3'))['ok'](_0x4a2704('0x2307'))[_0x4a2704('0x19fb')](_0x4a2704('0x253a'))[_0x4a2704('0xe42')](_0x2e5315);_0x414c4e[_0x4a2704('0x1d4')](_0x3cc39a)[_0x4a2704('0x683')](function(){const _0x251c8a=_0x4a2704;_0x5245aa[_0x251c8a('0xb6c')]['delete']({'id':_0x3a9fa2[_0x251c8a('0x149')]['id']})['$promise'][_0x251c8a('0x683')](function(){const _0x32353c=_0x251c8a;_0x2e3ca0()['remove'](_0x3a9fa2['zohoAccounts'],{'id':_0x3a9fa2[_0x32353c('0x149')]['id']}),_0x5f4139['success']({'title':_0x32353c('0x131c'),'msg':(_0x3a9fa2['zohoAccount'][_0x32353c('0x60a')]||_0x32353c('0x149'))+_0x32353c('0x194d')}),_0x11ee35(_0x3a9fa2[_0x32353c('0x149')]);})[_0x251c8a('0x130a')](function(_0x5de544){const _0x3768d3=_0x251c8a;if(_0x5de544[_0x3768d3('0x5a5')]&&_0x5de544[_0x3768d3('0x5a5')][_0x3768d3('0x17f')]&&_0x5de544[_0x3768d3('0x5a5')][_0x3768d3('0x17f')][_0x3768d3('0x1564')]){_0x3a9fa2[_0x3768d3('0x17f')]=_0x5de544[_0x3768d3('0x5a5')][_0x3768d3('0x17f')]||[{'message':_0x5de544[_0x3768d3('0x1ff0')](),'type':_0x3768d3('0x1872')}];for(let _0x1c7988=0x0;_0x1c7988<_0x5de544[_0x3768d3('0x5a5')][_0x3768d3('0x17f')][_0x3768d3('0x1564')];_0x1c7988++){_0x5f4139[_0x3768d3('0x52a')]({'title':_0x5de544[_0x3768d3('0x5a5')][_0x3768d3('0x17f')][_0x1c7988][_0x3768d3('0xcf0')],'msg':_0x5de544['data']['errors'][_0x1c7988][_0x3768d3('0x8c2')]});}}else _0x5f4139[_0x3768d3('0x52a')]({'title':_0x5de544[_0x3768d3('0x13ee')]?'API:'+_0x5de544[_0x3768d3('0x13ee')]+_0x3768d3('0xbf6')+_0x5de544[_0x3768d3('0x24a9')]:_0x3768d3('0x1872'),'msg':_0x5de544[_0x3768d3('0x5a5')]?JSON[_0x3768d3('0x258a')](_0x5de544[_0x3768d3('0x5a5')][_0x3768d3('0x8c2')]):_0x5de544[_0x3768d3('0x8c2')]||_0x5de544[_0x3768d3('0x1ff0')]()});});},function(){});}function _0x4c6eeb(_0x5e2001){return _0x5e2001===null?undefined:new Date(_0x5e2001);}function _0x11ee35(_0x2b7ba2){const _0x2af206=_0x1fc383;_0x414c4e[_0x2af206('0x1715')](_0x2b7ba2);}}const _0x4d4f74=_0x19256c,_0x1c4f1c=_0x180212['p']+_0x189033('0x196d'),_0x33e484=_0x180212['p']+'src/js/modules/main/apps/integrations/views/zohoAccounts/edit/item/dialog.html/dialog.html';_0x366dd4[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x16ea'),'api','toasty',_0x189033('0xba1')];function _0x366dd4(_0x5ab19c,_0xd8357f,_0x17bf45,_0x2da65f,_0x3c8fd6){const _0x47dcf0=_0x189033,_0x5641a6=this;_0x5641a6[_0x47dcf0('0x11ed')]=_0x3c8fd6[_0x47dcf0('0x20b2')](),_0x5641a6[_0x47dcf0('0x149')]={},_0x5641a6[_0x47dcf0('0x1bb4')]={},_0x5641a6[_0x47dcf0('0x1573')]=[],_0x5641a6[_0x47dcf0('0x27f6')]=-0x1,_0x5641a6[_0x47dcf0('0x1134')],_0x5641a6[_0x47dcf0('0x12f3')]=_0x3d1364,_0x5641a6['getZohoConfiguration']=_0x44283d,_0x5641a6[_0x47dcf0('0x2032')]=_0x4b386f,_0x5641a6[_0x47dcf0('0x1c5a')]=_0x35f81d,_0x5641a6[_0x47dcf0('0x284e')]=_0x7c080;function _0x7c080(){const _0x4622a4=_0x47dcf0;return _0x17bf45[_0x4622a4('0x8d1')][_0x4622a4('0x2480')]({'id':_0x5641a6['zohoConfiguration']['id']},_0x5641a6[_0x4622a4('0x1bb4')])[_0x4622a4('0xe53')][_0x4622a4('0x683')](function(){const _0x395005=_0x4622a4;_0x2da65f[_0x395005('0x53')]({'title':'Module\x20updated!','msg':_0x395005('0x1e73')});})['catch'](function(_0x95ee50){const _0x20ad3e=_0x4622a4;_0x2da65f[_0x20ad3e('0x52a')]({'title':_0x95ee50[_0x20ad3e('0x13ee')]?'API:'+_0x95ee50[_0x20ad3e('0x13ee')]+_0x20ad3e('0xbf6')+_0x95ee50['statusText']:_0x20ad3e('0x33a'),'msg':_0x95ee50[_0x20ad3e('0x5a5')]?JSON[_0x20ad3e('0x258a')](_0x95ee50[_0x20ad3e('0x5a5')]):_0x95ee50[_0x20ad3e('0x1ff0')]()});});}function _0x3d1364(_0x53486d,_0x573889){const _0x529dda=_0x47dcf0;_0x5641a6[_0x529dda('0x149')]=_0x53486d,_0x5641a6['crudPermissions']=typeof _0x573889!==_0x529dda('0x1867')?_0x573889:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x17bf45['intZohoAccount'][_0x529dda('0x1575')]({'id':_0x5641a6[_0x529dda('0x149')]['id'],'sort':_0x529dda('0xc36')})[_0x529dda('0xe53')][_0x529dda('0x683')](function(_0x232005){const _0x5bdddd=_0x529dda;return _0x5641a6[_0x5bdddd('0x1573')]=_0x232005[_0x5bdddd('0xf5d')]?_0x232005[_0x5bdddd('0xf5d')]:[],_0x5641a6[_0x5bdddd('0x1573')][_0x5bdddd('0x1564')]&&_0x5641a6[_0x5bdddd('0x10f7')](0x0),_0x17bf45['variable'][_0x5bdddd('0x1e6e')]({'nolimit':!![],'sort':_0x5bdddd('0x60a')})[_0x5bdddd('0xe53')];})[_0x529dda('0x683')](function(_0x40cbb0){const _0x12033a=_0x529dda;_0x5641a6[_0x12033a('0x220b')]=_0x40cbb0['rows']?_0x40cbb0[_0x12033a('0xf5d')]:[],_0x5641a6[_0x12033a('0x1822')]=_0x2e3ca0()[_0x12033a('0x24db')](_0x5641a6[_0x12033a('0x220b')],'id');})[_0x529dda('0x130a')](function(_0xd44c4c){const _0x360c83=_0x529dda;_0x2da65f['error']({'title':_0xd44c4c[_0x360c83('0x13ee')]?_0x360c83('0x2168')+_0xd44c4c[_0x360c83('0x13ee')]+_0x360c83('0xbf6')+_0xd44c4c['statusText']:_0x360c83('0xe2a'),'msg':_0xd44c4c['data']?JSON['stringify'](_0xd44c4c['data']):_0xd44c4c[_0x360c83('0x1ff0')]()});});}function _0x44283d(_0xe452bf){const _0xedd780=_0x47dcf0;_0x5641a6[_0xedd780('0x1bb4')]=_0x5641a6['configurations'][_0xe452bf],_0x5641a6['selectedZohoConfiguration']=_0xe452bf,_0x17bf45[_0xedd780('0x8d1')][_0xedd780('0x20ac')]({'id':_0x5641a6[_0xedd780('0x1bb4')]['id']})[_0xedd780('0xe53')][_0xedd780('0x683')](function(_0x56faaf){const _0x41a20c=_0xedd780;return _0x5641a6['subjects']=_0x56faaf[_0x41a20c('0xf5d')]?_0x56faaf[_0x41a20c('0xf5d')]:[],_0x17bf45[_0x41a20c('0x8d1')]['getDescriptions']({'id':_0x5641a6['zohoConfiguration']['id']})[_0x41a20c('0xe53')];})[_0xedd780('0x683')](function(_0x15d375){const _0x420103=_0xedd780;return _0x5641a6[_0x420103('0x18f7')]=_0x15d375[_0x420103('0xf5d')]?_0x15d375[_0x420103('0xf5d')]:[],_0x17bf45[_0x420103('0x8d1')][_0x420103('0x298')]({'id':_0x5641a6[_0x420103('0x1bb4')]['id']})[_0x420103('0xe53')];})[_0xedd780('0x683')](function(_0x33a88b){const _0x398feb=_0xedd780;_0x5641a6['fields']=_0x33a88b[_0x398feb('0xf5d')]?_0x33a88b[_0x398feb('0xf5d')]:[];})[_0xedd780('0x130a')](function(_0x56ab85){const _0x2d3dde=_0xedd780;_0x2da65f[_0x2d3dde('0x52a')]({'title':_0x56ab85[_0x2d3dde('0x13ee')]?_0x2d3dde('0x2168')+_0x56ab85['status']+'\x20-\x20'+_0x56ab85[_0x2d3dde('0x24a9')]:'SYSTEM:GETConfigurations','msg':_0x56ab85[_0x2d3dde('0x5a5')]?JSON[_0x2d3dde('0x258a')](_0x56ab85[_0x2d3dde('0x5a5')]):_0x56ab85[_0x2d3dde('0x1ff0')]()});});}function _0x4b386f(_0x54bf9,_0x1db01e){const _0x237839=_0x47dcf0;_0x5ab19c['show']({'controller':'CreateOrEditZohoConfigurationDialogController','controllerAs':'vm','templateUrl':_0x1c4f1c,'parent':angular[_0x237839('0x1fcc')](_0xd8357f[_0x237839('0x18e5')]),'targetEvent':_0x54bf9,'clickOutsideToClose':!![],'locals':{'zohoConfiguration':_0x1db01e,'configurations':_0x5641a6[_0x237839('0x1573')],'license':null,'setting':null,'crudPermissions':_0x5641a6[_0x237839('0x1134')]}})[_0x237839('0x2874')](function(){const _0xc6465a=_0x237839;_0x5641a6[_0xc6465a('0x10f7')](0x0);});}function _0x35f81d(_0x4e3ace,_0x1b3186){const _0xc2ec0=_0x47dcf0,_0x1b76f4=_0x5ab19c[_0xc2ec0('0x1c6f')]()[_0xc2ec0('0xf28')](_0xc2ec0('0x14ba'))[_0xc2ec0('0x26e3')](_0xc2ec0('0xed5')+(_0x1b3186[_0xc2ec0('0x60a')]||_0xc2ec0('0x1bb4'))+_0xc2ec0('0x20f1')+_0xc2ec0('0x1ee7'))[_0xc2ec0('0x1040')](_0xc2ec0('0xf93'))[_0xc2ec0('0xe42')](_0x4e3ace)['ok']('OK')[_0xc2ec0('0x19fb')](_0xc2ec0('0x16b8'));_0x5ab19c[_0xc2ec0('0x1d4')](_0x1b76f4)['then'](function(){const _0x52ce3c=_0xc2ec0;_0x17bf45['intZohoConfiguration']['delete']({'id':_0x1b3186['id']})[_0x52ce3c('0xe53')][_0x52ce3c('0x683')](function(){const _0x18f597=_0x52ce3c;_0x2e3ca0()[_0x18f597('0x3ec')](_0x5641a6[_0x18f597('0x1573')],{'id':_0x1b3186['id']}),_0x2da65f[_0x18f597('0x53')]({'title':_0x18f597('0x3dc'),'msg':_0x1b3186[_0x18f597('0x60a')]?_0x1b3186[_0x18f597('0x60a')]+_0x18f597('0x194d'):''});})[_0x52ce3c('0x130a')](function(_0x445b3f){const _0xf02ba3=_0x52ce3c;_0x2da65f[_0xf02ba3('0x52a')]({'title':_0x445b3f[_0xf02ba3('0x13ee')]?_0xf02ba3('0x2168')+_0x445b3f[_0xf02ba3('0x13ee')]+'\x20-\x20'+_0x445b3f[_0xf02ba3('0x24a9')]:_0xf02ba3('0x1e44'),'msg':_0x445b3f[_0xf02ba3('0x5a5')]?JSON[_0xf02ba3('0x258a')](_0x445b3f[_0xf02ba3('0x5a5')]):_0x445b3f[_0xf02ba3('0x1ff0')]()});})[_0x52ce3c('0x2874')](function(){const _0x4c0b71=_0x52ce3c;_0x5641a6[_0x4c0b71('0x10f7')](0x0);});},function(){const _0x27ca59=_0xc2ec0;console[_0x27ca59('0x1b2b')](_0x27ca59('0x16b8'));});}_0x5641a6[_0x47dcf0('0x1781')]=[],_0x5641a6[_0x47dcf0('0x2654')]=_0x3aab44,_0x5641a6['deleteSubjectConfirm']=_0x5ad4e2,_0x5641a6['deleteSelectedSubjects']=_0x4e9138;function _0x3aab44(_0x42548c,_0x9a97de){const _0x576853=_0x47dcf0;_0x5ab19c[_0x576853('0x1d4')]({'controller':'CreateOrEditZohoAccountItemDialogController','controllerAs':'vm','templateUrl':_0x33e484,'parent':angular[_0x576853('0x1fcc')](_0xd8357f[_0x576853('0x18e5')]),'targetEvent':_0x42548c,'clickOutsideToClose':!![],'locals':{'type':_0x576853('0x1e66'),'item':_0x9a97de,'items':_0x5641a6['subjects'],'configuration':_0x5641a6[_0x576853('0x1bb4')],'account':_0x5641a6['zohoAccount'],'license':null,'setting':null,'crudPermissions':_0x5641a6[_0x576853('0x1134')]}});}function _0x50e337(_0x2d7a03){const _0x1153dd=_0x47dcf0;_0x17bf45[_0x1153dd('0x1ec1')][_0x1153dd('0xd7e')]({'id':_0x2d7a03['id']})[_0x1153dd('0xe53')]['then'](function(){const _0x102f78=_0x1153dd;_0x2e3ca0()[_0x102f78('0x3ec')](_0x5641a6[_0x102f78('0x1ead')],{'id':_0x2d7a03['id']}),_0x2da65f[_0x102f78('0x53')]({'title':_0x102f78('0x637'),'msg':'Subject\x20has\x20been\x20deleted!'});})['catch'](function(_0x507291){const _0x592de1=_0x1153dd;_0x2da65f[_0x592de1('0x52a')]({'title':_0x507291[_0x592de1('0x13ee')]?_0x592de1('0x2168')+_0x507291[_0x592de1('0x13ee')]+'\x20-\x20'+_0x507291[_0x592de1('0x24a9')]:_0x592de1('0x1d23'),'msg':_0x507291[_0x592de1('0x5a5')]?JSON[_0x592de1('0x258a')](_0x507291[_0x592de1('0x5a5')]):_0x507291[_0x592de1('0x1ff0')]()});});}function _0x5ad4e2(_0x51163b,_0xc96578){const _0x15e7b3=_0x47dcf0,_0xf66e60=_0x5ab19c[_0x15e7b3('0x1c6f')]()[_0x15e7b3('0xf28')](_0x15e7b3('0x17ed'))['htmlContent'](_0x15e7b3('0x601')+_0x15e7b3('0x1ee7'))[_0x15e7b3('0x1040')](_0x15e7b3('0x20d'))[_0x15e7b3('0xe42')](_0x51163b)['ok']('OK')[_0x15e7b3('0x19fb')](_0x15e7b3('0x16b8'));_0x5ab19c[_0x15e7b3('0x1d4')](_0xf66e60)[_0x15e7b3('0x683')](function(){_0x50e337(_0xc96578);},function(){const _0x799c78=_0x15e7b3;console[_0x799c78('0x1b2b')](_0x799c78('0x16b8'));});}function _0x4e9138(_0x189ab1){const _0x52363d=_0x47dcf0,_0x55a815=_0x5ab19c[_0x52363d('0x1c6f')]()[_0x52363d('0xf28')](_0x52363d('0xad5'))[_0x52363d('0x26e3')](_0x52363d('0xed5')+_0x5641a6[_0x52363d('0x1781')][_0x52363d('0x1564')]+_0x52363d('0x93c')+_0x52363d('0x1ee7'))[_0x52363d('0x1040')]('delete\x20subjects')[_0x52363d('0xe42')](_0x189ab1)['ok']('OK')['cancel']('CANCEL');_0x5ab19c[_0x52363d('0x1d4')](_0x55a815)['then'](function(){const _0xaea629=_0x52363d;_0x5641a6['selectedSubjects'][_0xaea629('0x1299')](function(_0x2069d5){_0x50e337(_0x2069d5);}),_0x5641a6[_0xaea629('0x1781')]=[];});}_0x5641a6[_0x47dcf0('0xcb1')]=[],_0x5641a6[_0x47dcf0('0x1094')]=_0x47ec08,_0x5641a6[_0x47dcf0('0x27b2')]=_0x10dcf6,_0x5641a6['deleteSelectedDescriptions']=_0x5c1775;function _0x47ec08(_0x3c2582,_0x576ec8){const _0x3ecc2d=_0x47dcf0;_0x5ab19c[_0x3ecc2d('0x1d4')]({'controller':_0x3ecc2d('0x1933'),'controllerAs':'vm','templateUrl':_0x33e484,'parent':angular[_0x3ecc2d('0x1fcc')](_0xd8357f['body']),'targetEvent':_0x3c2582,'clickOutsideToClose':!![],'locals':{'type':_0x3ecc2d('0xd6b'),'item':_0x576ec8,'items':_0x5641a6[_0x3ecc2d('0x18f7')],'configuration':_0x5641a6[_0x3ecc2d('0x1bb4')],'account':_0x5641a6['zohoAccount'],'license':null,'setting':null,'crudPermissions':_0x5641a6[_0x3ecc2d('0x1134')]}});}function _0xbeff34(_0x2caf9f){const _0x5cbd19=_0x47dcf0;_0x17bf45[_0x5cbd19('0x1ec1')]['delete']({'id':_0x2caf9f['id']})[_0x5cbd19('0xe53')]['then'](function(){const _0x22cf88=_0x5cbd19;_0x2e3ca0()[_0x22cf88('0x3ec')](_0x5641a6['descriptions'],{'id':_0x2caf9f['id']}),_0x2da65f[_0x22cf88('0x53')]({'title':'Description\x20deleted!','msg':_0x22cf88('0x21c7')});})[_0x5cbd19('0x130a')](function(_0x469a33){const _0x3c784a=_0x5cbd19;_0x2da65f['error']({'title':_0x469a33[_0x3c784a('0x13ee')]?_0x3c784a('0x2168')+_0x469a33[_0x3c784a('0x13ee')]+_0x3c784a('0xbf6')+_0x469a33['statusText']:_0x3c784a('0x1d23'),'msg':_0x469a33['data']?JSON[_0x3c784a('0x258a')](_0x469a33[_0x3c784a('0x5a5')]):_0x469a33[_0x3c784a('0x1ff0')]()});});}function _0x10dcf6(_0x4ca5cc,_0x4bcae1){const _0x209ddc=_0x47dcf0,_0x4e1d26=_0x5ab19c[_0x209ddc('0x1c6f')]()[_0x209ddc('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20description?')['htmlContent'](_0x209ddc('0xd5e')+_0x209ddc('0x1ee7'))[_0x209ddc('0x1040')]('delete\x20description')[_0x209ddc('0xe42')](_0x4ca5cc)['ok']('OK')[_0x209ddc('0x19fb')]('CANCEL');_0x5ab19c['show'](_0x4e1d26)[_0x209ddc('0x683')](function(){_0xbeff34(_0x4bcae1);},function(){const _0x271175=_0x209ddc;console[_0x271175('0x1b2b')](_0x271175('0x16b8'));});}function _0x5c1775(_0xf6db3a){const _0x243e72=_0x47dcf0,_0x30b17c=_0x5ab19c['confirm']()['title'](_0x243e72('0x1984'))[_0x243e72('0x26e3')](''+_0x5641a6['selectedDescriptions'][_0x243e72('0x1564')]+'\x20selected'+_0x243e72('0x1ee7'))[_0x243e72('0x1040')](_0x243e72('0x1859'))[_0x243e72('0xe42')](_0xf6db3a)['ok']('OK')[_0x243e72('0x19fb')](_0x243e72('0x16b8'));_0x5ab19c[_0x243e72('0x1d4')](_0x30b17c)['then'](function(){const _0x5dc662=_0x243e72;_0x5641a6[_0x5dc662('0xcb1')][_0x5dc662('0x1299')](function(_0x1adb59){_0xbeff34(_0x1adb59);}),_0x5641a6[_0x5dc662('0xcb1')]=[];});}_0x5641a6['selectedFields']=[],_0x5641a6['createOrEditField']=_0x2a9302,_0x5641a6[_0x47dcf0('0x9f9')]=_0x3d8878,_0x5641a6[_0x47dcf0('0x204e')]=_0x337acb;function _0x2a9302(_0x4f7e2a,_0x517b5f){const _0x1f9ff6=_0x47dcf0;_0x5ab19c[_0x1f9ff6('0x1d4')]({'controller':_0x1f9ff6('0x1933'),'controllerAs':'vm','templateUrl':_0x33e484,'parent':angular[_0x1f9ff6('0x1fcc')](_0xd8357f[_0x1f9ff6('0x18e5')]),'targetEvent':_0x4f7e2a,'clickOutsideToClose':!![],'locals':{'type':'field','item':_0x517b5f,'items':_0x5641a6[_0x1f9ff6('0x189a')],'configuration':_0x5641a6[_0x1f9ff6('0x1bb4')],'account':_0x5641a6[_0x1f9ff6('0x149')],'license':null,'setting':null,'crudPermissions':_0x5641a6[_0x1f9ff6('0x1134')]}});}function _0x1f5d92(_0x7d3122){const _0x53db40=_0x47dcf0;_0x17bf45[_0x53db40('0x1ec1')]['delete']({'id':_0x7d3122['id']})[_0x53db40('0xe53')][_0x53db40('0x683')](function(){const _0x1a9d08=_0x53db40;_0x2e3ca0()[_0x1a9d08('0x3ec')](_0x5641a6[_0x1a9d08('0x189a')],{'id':_0x7d3122['id']}),_0x2da65f['success']({'title':_0x1a9d08('0x1666'),'msg':_0x1a9d08('0x1eda')});})[_0x53db40('0x130a')](function(_0x259baa){const _0x2327a0=_0x53db40;_0x2da65f[_0x2327a0('0x52a')]({'title':_0x259baa[_0x2327a0('0x13ee')]?_0x2327a0('0x2168')+_0x259baa['status']+'\x20-\x20'+_0x259baa[_0x2327a0('0x24a9')]:'SYSTEM:DELETECONFIGURATIONFIELD','msg':_0x259baa['data']?JSON[_0x2327a0('0x258a')](_0x259baa[_0x2327a0('0x5a5')]):_0x259baa[_0x2327a0('0x1ff0')]()});});}function _0x3d8878(_0x18657f,_0x4a6b0f){const _0x10e823=_0x47dcf0,_0x18f36d=_0x5ab19c['confirm']()[_0x10e823('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20field?')[_0x10e823('0x26e3')](_0x10e823('0x23b9')+'\x20will\x20be\x20deleted.')[_0x10e823('0x1040')](_0x10e823('0x1edb'))[_0x10e823('0xe42')](_0x18657f)['ok']('OK')[_0x10e823('0x19fb')](_0x10e823('0x16b8'));_0x5ab19c[_0x10e823('0x1d4')](_0x18f36d)['then'](function(){_0x1f5d92(_0x4a6b0f);},function(){const _0x58738f=_0x10e823;console[_0x58738f('0x1b2b')](_0x58738f('0x16b8'));});}function _0x337acb(_0x215c04){const _0x905d05=_0x47dcf0,_0x4cc7c4=_0x5ab19c[_0x905d05('0x1c6f')]()['title'](_0x905d05('0x19b1'))[_0x905d05('0x26e3')](_0x905d05('0xed5')+_0x5641a6[_0x905d05('0x310')][_0x905d05('0x1564')]+_0x905d05('0x93c')+_0x905d05('0x1ee7'))[_0x905d05('0x1040')]('delete\x20fields')[_0x905d05('0xe42')](_0x215c04)['ok']('OK')[_0x905d05('0x19fb')]('CANCEL');_0x5ab19c['show'](_0x4cc7c4)[_0x905d05('0x683')](function(){const _0x29d1b6=_0x905d05;_0x5641a6['selectedFields'][_0x29d1b6('0x1299')](function(_0x4630b3){_0x1f5d92(_0x4630b3);}),_0x5641a6['selectedFields']=[];});}}const _0x1e5398=_0x366dd4;_0x44f1fb[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location','$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1573'),_0x189033('0x1bb4'),_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x44f1fb(_0x43ddc8,_0x42dac8,_0x397577,_0x347654,_0x4994b1,_0x4f0aa4,_0x2046a1,_0x250db6,_0x39fdbe,_0x4ceb2f,_0x5bd862,_0x568042,_0x178f05,_0x2050a7){const _0x468ad6=_0x189033,_0x14564c=this;_0x14564c[_0x468ad6('0x11ed')]=_0x5bd862[_0x468ad6('0x20b2')](),_0x14564c[_0x468ad6('0x17f')]=[],_0x14564c['setting']=_0x178f05,_0x14564c[_0x468ad6('0xace')]=_0x568042,_0x14564c[_0x468ad6('0x1134')]=_0x2050a7,_0x14564c[_0x468ad6('0x258d')]={},_0x14564c['passwordPattern']=_0x14564c['setting']&&_0x14564c[_0x468ad6('0x260a')][_0x468ad6('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x14564c[_0x468ad6('0xf28')]=_0x468ad6('0x1050'),_0x14564c[_0x468ad6('0x1bb4')]=angular[_0x468ad6('0x1a86')](_0x39fdbe),_0x14564c[_0x468ad6('0x1573')]=_0x250db6,_0x14564c[_0x468ad6('0x21cb')]=![];!_0x14564c['zohoConfiguration']&&(_0x14564c[_0x468ad6('0x1bb4')]={'channel':'voice','type':_0x468ad6('0x1535')},_0x14564c[_0x468ad6('0xf28')]=_0x468ad6('0xc0d'),_0x14564c['newZohoConfiguration']=!![]);_0x14564c['addNewZohoConfiguration']=_0x49151a,_0x14564c[_0x468ad6('0x1f02')]=_0x4c22ce,_0x14564c[_0x468ad6('0x1c5a')]=_0x1577f3,_0x14564c[_0x468ad6('0x16b3')]=_0x19034c,_0x14564c[_0x468ad6('0xf82')]=_0xa4e23b;function _0x49151a(){const _0x223ae0=_0x468ad6;_0x14564c[_0x223ae0('0x17f')]=[],_0x4ceb2f[_0x223ae0('0xb6c')]['addConfiguration']({'id':_0x42dac8[_0x223ae0('0x7f2')]['id']},_0x14564c['zohoConfiguration'])[_0x223ae0('0xe53')][_0x223ae0('0x683')](function(_0x325dc1){const _0x34fc76=_0x223ae0;_0x14564c[_0x34fc76('0x1573')][_0x34fc76('0x1167')](_0x325dc1[_0x34fc76('0x24e1')]()),_0x2046a1[_0x34fc76('0x53')]({'title':_0x34fc76('0x17c0'),'msg':_0x14564c['zohoConfiguration']['name']?_0x14564c[_0x34fc76('0x1bb4')][_0x34fc76('0x60a')]+_0x34fc76('0x14b5'):''}),_0xa4e23b(_0x325dc1);})['catch'](function(_0x2a33be){const _0x52606f=_0x223ae0;if(_0x2a33be['data']&&_0x2a33be[_0x52606f('0x5a5')]['errors']&&_0x2a33be['data']['errors'][_0x52606f('0x1564')]){_0x14564c[_0x52606f('0x17f')]=_0x2a33be[_0x52606f('0x5a5')][_0x52606f('0x17f')]||[{'message':_0x2a33be['toString'](),'type':_0x52606f('0x17b4')}];for(let _0x37718a=0x0;_0x37718a<_0x2a33be[_0x52606f('0x5a5')][_0x52606f('0x17f')][_0x52606f('0x1564')];_0x37718a+=0x1){_0x2046a1[_0x52606f('0x52a')]({'title':_0x2a33be[_0x52606f('0x5a5')]['errors'][_0x37718a][_0x52606f('0xcf0')],'msg':_0x2a33be[_0x52606f('0x5a5')]['errors'][_0x37718a][_0x52606f('0x8c2')]});}}else _0x2046a1[_0x52606f('0x52a')]({'title':_0x2a33be[_0x52606f('0x13ee')]?_0x52606f('0x2168')+_0x2a33be['status']+_0x52606f('0xbf6')+_0x2a33be[_0x52606f('0x24a9')]:_0x52606f('0x17b4'),'msg':_0x2a33be[_0x52606f('0x5a5')]?JSON['stringify'](_0x2a33be['data']['message']):_0x2a33be[_0x52606f('0x1ff0')]()});});}function _0x4c22ce(){const _0x39f818=_0x468ad6;_0x14564c[_0x39f818('0x17f')]=[],_0x4ceb2f[_0x39f818('0x8d1')][_0x39f818('0x2480')]({'id':_0x14564c[_0x39f818('0x1bb4')]['id']},_0x14564c[_0x39f818('0x1bb4')])['$promise'][_0x39f818('0x683')](function(_0x23bfb2){const _0x405f8f=_0x39f818,_0x3a9c1a=_0x2e3ca0()[_0x405f8f('0x1c07')](_0x14564c[_0x405f8f('0x1573')],{'id':_0x23bfb2['id']});_0x3a9c1a&&_0x2e3ca0()[_0x405f8f('0xf22')](_0x3a9c1a,_0x2e3ca0()[_0x405f8f('0x24d0')](_0x23bfb2[_0x405f8f('0x24e1')](),_0x2e3ca0()[_0x405f8f('0x55e')](_0x3a9c1a))),_0x2046a1['success']({'title':'ZohoConfiguration\x20properly\x20saved!','msg':_0x14564c[_0x405f8f('0x1bb4')][_0x405f8f('0x60a')]?_0x14564c['zohoConfiguration'][_0x405f8f('0x60a')]+_0x405f8f('0xf59'):''}),_0xa4e23b(_0x23bfb2);})[_0x39f818('0x130a')](function(_0x91b0bc){const _0x190197=_0x39f818;if(_0x91b0bc[_0x190197('0x5a5')]&&_0x91b0bc[_0x190197('0x5a5')][_0x190197('0x17f')]&&_0x91b0bc[_0x190197('0x5a5')][_0x190197('0x17f')][_0x190197('0x1564')]){_0x14564c[_0x190197('0x17f')]=_0x91b0bc[_0x190197('0x5a5')]['errors']||[{'message':_0x91b0bc[_0x190197('0x1ff0')](),'type':_0x190197('0x267e')}];for(let _0x21eb30=0x0;_0x21eb30<_0x91b0bc[_0x190197('0x5a5')][_0x190197('0x17f')][_0x190197('0x1564')];_0x21eb30++){_0x2046a1[_0x190197('0x52a')]({'title':_0x91b0bc[_0x190197('0x5a5')][_0x190197('0x17f')][_0x21eb30][_0x190197('0xcf0')],'msg':_0x91b0bc[_0x190197('0x5a5')][_0x190197('0x17f')][_0x21eb30]['message']});}}else _0x2046a1[_0x190197('0x52a')]({'title':_0x91b0bc[_0x190197('0x13ee')]?_0x190197('0x2168')+_0x91b0bc['status']+_0x190197('0xbf6')+_0x91b0bc[_0x190197('0x24a9')]:_0x190197('0x267e'),'msg':_0x91b0bc[_0x190197('0x5a5')]?JSON[_0x190197('0x258a')](_0x91b0bc[_0x190197('0x5a5')]['message']):_0x91b0bc[_0x190197('0x1ff0')]()});});}function _0x1577f3(_0x1505a3){const _0x24376e=_0x468ad6;_0x14564c[_0x24376e('0x17f')]=[];const _0x354129=_0x347654['confirm']()['title'](_0x24376e('0x4d'))[_0x24376e('0xa6a')]('The\x20zohoConfiguration\x20will\x20be\x20deleted.')['ariaLabel']('Delete\x20ZohoConfiguration')['ok'](_0x24376e('0x2307'))['cancel']('Cancel')['targetEvent'](_0x1505a3);_0x347654[_0x24376e('0x1d4')](_0x354129)['then'](function(){const _0x5981c0=_0x24376e;_0x4ceb2f[_0x5981c0('0x8d1')][_0x5981c0('0xd7e')]({'id':_0x14564c[_0x5981c0('0x1bb4')]['id']})[_0x5981c0('0xe53')]['then'](function(){const _0x183dcc=_0x5981c0;_0x2e3ca0()[_0x183dcc('0x3ec')](_0x14564c['configurations'],{'id':_0x14564c[_0x183dcc('0x1bb4')]['id']}),_0x2046a1[_0x183dcc('0x53')]({'title':_0x183dcc('0x1343'),'msg':(_0x14564c[_0x183dcc('0x1bb4')][_0x183dcc('0x60a')]||'zohoConfiguration')+_0x183dcc('0x194d')}),_0xa4e23b(_0x14564c['zohoConfiguration']);})[_0x5981c0('0x130a')](function(_0x3ce911){const _0x33ab6=_0x5981c0;if(_0x3ce911[_0x33ab6('0x5a5')]&&_0x3ce911['data'][_0x33ab6('0x17f')]&&_0x3ce911[_0x33ab6('0x5a5')]['errors'][_0x33ab6('0x1564')]){_0x14564c[_0x33ab6('0x17f')]=_0x3ce911[_0x33ab6('0x5a5')][_0x33ab6('0x17f')]||[{'message':_0x3ce911[_0x33ab6('0x1ff0')](),'type':'api.intZohoConfiguration.delete'}];for(let _0xaa1252=0x0;_0xaa1252<_0x3ce911['data'][_0x33ab6('0x17f')]['length'];_0xaa1252++){_0x2046a1[_0x33ab6('0x52a')]({'title':_0x3ce911[_0x33ab6('0x5a5')][_0x33ab6('0x17f')][_0xaa1252][_0x33ab6('0xcf0')],'msg':_0x3ce911[_0x33ab6('0x5a5')]['errors'][_0xaa1252][_0x33ab6('0x8c2')]});}}else _0x2046a1[_0x33ab6('0x52a')]({'title':_0x3ce911[_0x33ab6('0x13ee')]?_0x33ab6('0x2168')+_0x3ce911[_0x33ab6('0x13ee')]+_0x33ab6('0xbf6')+_0x3ce911[_0x33ab6('0x24a9')]:_0x33ab6('0x187e'),'msg':_0x3ce911[_0x33ab6('0x5a5')]?JSON[_0x33ab6('0x258a')](_0x3ce911[_0x33ab6('0x5a5')][_0x33ab6('0x8c2')]):_0x3ce911[_0x33ab6('0x8c2')]||_0x3ce911[_0x33ab6('0x1ff0')]()});});},function(){});}function _0x19034c(_0x19c8d9){return _0x19c8d9===null?undefined:new Date(_0x19c8d9);}function _0xa4e23b(_0x24a5eb){_0x347654['hide'](_0x24a5eb);}}const _0x5b90c0=_0x44f1fb;_0x26048c[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state','$location',_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x208d'),_0x189033('0x1996'),_0x189033('0x23ef'),_0x189033('0x1d2f'),_0x189033('0xcf0'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x26048c(_0x4360e6,_0x463626,_0x11290a,_0x564f88,_0x18ed75,_0x9578c2,_0x17ab3c,_0xf7c4a2,_0x4bae9e,_0x2fbb52,_0x184f09,_0x3605f8,_0xa56b31){const _0x1c7bd3=_0x189033,_0x53c20d=this;_0x53c20d[_0x1c7bd3('0x11ed')]=_0x3605f8[_0x1c7bd3('0x20b2')](),_0x53c20d[_0x1c7bd3('0x17f')]=[],_0x53c20d[_0x1c7bd3('0xf28')]=_0x1c7bd3('0x176c')+_0x2e3ca0()['toUpper'](_0x2fbb52),_0x53c20d[_0x1c7bd3('0x23ef')]=angular[_0x1c7bd3('0x1a86')](_0xf7c4a2),_0x53c20d[_0x1c7bd3('0x1996')]=_0x17ab3c,_0x53c20d[_0x1c7bd3('0xcf0')]=_0x2fbb52,_0x53c20d[_0x1c7bd3('0x1134')]=_0xa56b31,_0x53c20d['newItem']=![];!_0x53c20d[_0x1c7bd3('0x23ef')]&&(_0x53c20d[_0x1c7bd3('0x23ef')]={'type':'string'},_0x53c20d[_0x1c7bd3('0x23ef')][_0x2e3ca0()[_0x1c7bd3('0x21ab')](_0x2fbb52)+'Id']=_0x9578c2['id'],_0x53c20d[_0x1c7bd3('0xf28')]=_0x1c7bd3('0x22de')+_0x2e3ca0()[_0x1c7bd3('0x65')](_0x2fbb52),_0x53c20d[_0x1c7bd3('0x3d2')]=!![]);_0x53c20d[_0x1c7bd3('0x2591')]=_0xa44320,_0x53c20d[_0x1c7bd3('0x2716')]=_0x585835,_0x53c20d[_0x1c7bd3('0x6b8')]=_0x28940e,_0x53c20d[_0x1c7bd3('0x18a')]=_0x2e56f3,_0x53c20d[_0x1c7bd3('0xf82')]=_0x511341,_0x184f09[_0x1c7bd3('0x26e0')][_0x1c7bd3('0x1e6e')]({'nolimit':!![]})['$promise'][_0x1c7bd3('0x683')](function(_0x14394d){const _0x480440=_0x1c7bd3;return _0x53c20d[_0x480440('0x220b')]=_0x14394d['rows']?_0x14394d['rows']:[],_0x184f09[_0x480440('0xf53')][_0x480440('0x2267')]()[_0x480440('0xe53')];})[_0x1c7bd3('0x683')](function(_0xb1d0de){const _0x3c1285=_0x1c7bd3;return _0x53c20d[_0x3c1285('0x20c1')]=_0x2e3ca0()['difference'](_0x2e3ca0()[_0x3c1285('0x55e')](_0xb1d0de),[_0x3c1285('0xe53'),_0x3c1285('0x1980'),_0x3c1285('0x1a4'),_0x3c1285('0x2000'),_0x3c1285('0x1d58')]),_0x53c20d[_0x3c1285('0x20c1')][_0x3c1285('0x1fd0')](_0x3c1285('0x1e93')),_0x184f09[_0x3c1285('0x1793')][_0x3c1285('0x2267')]()[_0x3c1285('0xe53')];})['then'](function(_0x424087){const _0x21dce3=_0x1c7bd3;_0x53c20d[_0x21dce3('0x1d6a')]=_0x2e3ca0()['difference'](_0x2e3ca0()[_0x21dce3('0x55e')](_0x424087),[_0x21dce3('0xe53'),_0x21dce3('0x1980'),_0x21dce3('0x1a4'),_0x21dce3('0x2000'),_0x21dce3('0x1d58')]),_0x53c20d[_0x21dce3('0x1d6a')][_0x21dce3('0x1fd0')]('recordingURL');})[_0x1c7bd3('0x130a')](function(_0x540428){const _0x583639=_0x1c7bd3;_0x18ed75[_0x583639('0x52a')]({'title':_0x540428[_0x583639('0x13ee')]?_0x583639('0x2168')+_0x540428[_0x583639('0x13ee')]+_0x583639('0xbf6')+_0x540428[_0x583639('0x24a9')]:_0x583639('0x1fd3'),'msg':_0x540428[_0x583639('0x5a5')]?JSON[_0x583639('0x258a')](_0x540428['data']):_0x540428['toString']()});}),_0x184f09['intZohoAccount'][_0x1c7bd3('0x298')]({'id':_0x4bae9e['id'],'ticketType':_0x9578c2[_0x1c7bd3('0x20c9')]?_0x9578c2['ticketType']:undefined})[_0x1c7bd3('0xe53')][_0x1c7bd3('0x683')](function(_0x10624f){const _0x1ee5a0=_0x1c7bd3;_0x53c20d[_0x1ee5a0('0xd32')]=!![],_0x53c20d[_0x1ee5a0('0x189a')]=_0x10624f[_0x1ee5a0('0xf5d')]?_0x10624f[_0x1ee5a0('0xf5d')]:[],_0x53c20d[_0x1ee5a0('0x23ef')][_0x1ee5a0('0x280')]&&(_0x53c20d[_0x1ee5a0('0x7f8')]=_0x2e3ca0()['find'](_0x53c20d['fields'],{'id':_0x53c20d[_0x1ee5a0('0x23ef')][_0x1ee5a0('0x280')]}));})[_0x1c7bd3('0x130a')](function(_0xad2186){_0x53c20d['accountConnected']=![],console['error'](_0xad2186);});function _0xa44320(){const _0x44ef2b=_0x1c7bd3;_0x53c20d[_0x44ef2b('0x17f')]=[],_0x53c20d[_0x44ef2b('0x7f8')]&&(_0x53c20d[_0x44ef2b('0x23ef')][_0x44ef2b('0x280')]=_0x53c20d[_0x44ef2b('0x7f8')]['id'],_0x53c20d[_0x44ef2b('0x23ef')][_0x44ef2b('0x2584')]=_0x53c20d[_0x44ef2b('0x7f8')][_0x44ef2b('0x60a')],_0x53c20d[_0x44ef2b('0x23ef')][_0x44ef2b('0x7f8')]=_0x53c20d['customField'][_0x44ef2b('0xbf0')]),_0x184f09[_0x44ef2b('0x1ec1')][_0x44ef2b('0xb0a')](_0x53c20d['item'])[_0x44ef2b('0xe53')]['then'](function(_0x101c29){const _0x3106cc=_0x44ef2b;_0x53c20d[_0x3106cc('0x1996')]['unshift'](_0x101c29),_0x18ed75[_0x3106cc('0x53')]({'title':_0x2e3ca0()['capitalize'](_0x2fbb52)+_0x3106cc('0x282a'),'msg':_0x2e3ca0()['capitalize'](_0x2fbb52)+_0x3106cc('0x14b5')}),_0x511341();})[_0x44ef2b('0x130a')](function(_0x160705){const _0xa2d3f1=_0x44ef2b;console[_0xa2d3f1('0x52a')](_0x160705),_0x53c20d[_0xa2d3f1('0x17f')]=_0x160705[_0xa2d3f1('0x5a5')][_0xa2d3f1('0x17f')]||[{'message':_0x160705[_0xa2d3f1('0x1ff0')](),'type':'api.item.save'}];});}function _0x585835(){const _0x40b606=_0x1c7bd3;_0x53c20d[_0x40b606('0x17f')]=[],_0x53c20d['customField']&&(_0x53c20d[_0x40b606('0x23ef')]['idField']=_0x53c20d[_0x40b606('0x7f8')]['id'],_0x53c20d['item'][_0x40b606('0x2584')]=_0x53c20d['customField'][_0x40b606('0x60a')],_0x53c20d['item'][_0x40b606('0x7f8')]=_0x53c20d['customField'][_0x40b606('0xbf0')]),_0x184f09[_0x40b606('0x1ec1')]['update']({'id':_0x53c20d[_0x40b606('0x23ef')]['id']},_0x53c20d[_0x40b606('0x23ef')])['$promise'][_0x40b606('0x683')](function(_0x3796c1){const _0xf62e65=_0x40b606,_0x104f75=_0x2e3ca0()[_0xf62e65('0x1c07')](_0x53c20d['items'],{'id':_0x3796c1['id']});_0x104f75&&_0x2e3ca0()[_0xf62e65('0xf22')](_0x104f75,_0x3796c1),_0x18ed75[_0xf62e65('0x53')]({'title':_0x2e3ca0()['capitalize'](_0x2fbb52)+_0xf62e65('0x15dd'),'msg':_0x2e3ca0()['capitalize'](_0x2fbb52)+_0xf62e65('0xf59')}),_0x511341();})['catch'](function(_0xc12074){const _0xa7a635=_0x40b606;console[_0xa7a635('0x52a')](_0xc12074),_0x53c20d[_0xa7a635('0x17f')]=_0xc12074['data']['errors']||[{'message':_0xc12074[_0xa7a635('0x1ff0')](),'type':_0xa7a635('0x25d0')}];});}function _0x28940e(_0x3da99c){const _0x45fca8=_0x1c7bd3;_0x53c20d['errors']=[];const _0x176c23=_0x564f88[_0x45fca8('0x1c6f')]()[_0x45fca8('0xf28')](_0x45fca8('0x4d'))[_0x45fca8('0xa6a')](_0x45fca8('0x3fc')+_0x2fbb52+_0x45fca8('0x1ee7'))[_0x45fca8('0x1040')](_0x45fca8('0x609')+_0x2e3ca0()[_0x45fca8('0x21ab')](_0x2fbb52))['ok']('Delete')[_0x45fca8('0x19fb')](_0x45fca8('0x253a'))['targetEvent'](_0x3da99c);_0x564f88['show'](_0x176c23)[_0x45fca8('0x683')](function(){const _0x24b3b2=_0x45fca8;_0x184f09[_0x24b3b2('0x1ec1')]['delete']({'id':_0x53c20d[_0x24b3b2('0x23ef')]['id']})[_0x24b3b2('0xe53')][_0x24b3b2('0x683')](function(){const _0x116a7c=_0x24b3b2;_0x2e3ca0()[_0x116a7c('0x3ec')](_0x53c20d[_0x116a7c('0x1996')],{'id':_0x53c20d['item']['id']}),_0x18ed75[_0x116a7c('0x53')]({'title':_0x2e3ca0()[_0x116a7c('0x21ab')](_0x2fbb52)+_0x116a7c('0x27d7'),'msg':_0x2e3ca0()[_0x116a7c('0x21ab')](_0x2fbb52)+_0x116a7c('0x194d')}),_0x511341();})['catch'](function(_0x109357){const _0x5ebee7=_0x24b3b2;console[_0x5ebee7('0x52a')](_0x109357),_0x53c20d[_0x5ebee7('0x17f')]=_0x109357['data'][_0x5ebee7('0x17f')]||[{'message':_0x109357[_0x5ebee7('0x1ff0')](),'type':'api.item.delete'}];});},function(){});}function _0x2e56f3(){const _0x2148d8=_0x1c7bd3;return _0x53c20d[_0x2148d8('0x23ef')]['variableName']!==undefined?_0x53c20d['item'][_0x2148d8('0x113b')]:_0x2148d8('0xbbf');}function _0x511341(){_0x564f88['hide']();}}const _0x14c1c3=_0x26048c;_0x3688b5['$inject']=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),'toasty',_0x189033('0xba1'),'zohoAccount',_0x189033('0x22df')];function _0x3688b5(_0x407275,_0x2b2b67,_0x602739,_0x22306d,_0x5ec33e,_0x2a2a6a,_0x4327f2,_0x45b673,_0x4d5368,_0x58d24f,_0x27d8fe,_0x5451dd){const _0x52d500=_0x189033,_0x4ff767=this;_0x4ff767[_0x52d500('0x11ed')]=_0x58d24f[_0x52d500('0x20b2')](),_0x4ff767[_0x52d500('0xace')]=_0x2a2a6a,_0x4ff767['setting']=_0x4327f2,_0x4ff767[_0x52d500('0x19b2')]=_0x4ff767['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4ff767[_0x52d500('0x1224')]=_0x2b2b67[_0x52d500('0x173e')]()+_0x52d500('0x20de')+_0x2b2b67[_0x52d500('0x19ac')](),_0x4ff767[_0x52d500('0x149')]=_0x27d8fe||_0x407275[_0x52d500('0x7f2')][_0x52d500('0x149')]||{},_0x4ff767['userProfileSection']=_0x5451dd&&_0x5451dd['count']==0x1?_0x5451dd['rows'][0x0]:null,_0x4ff767[_0x52d500('0x1134')]=_0x58d24f[_0x52d500('0x142a')](_0x4ff767[_0x52d500('0x22df')]?_0x4ff767['userProfileSection']['crudPermissions']:null),_0x4ff767[_0x52d500('0x258d')]={},_0x4ff767[_0x52d500('0x517')]=_0x407275[_0x52d500('0x7f2')]['tab']||0x0,_0x4ff767[_0x52d500('0x2430')]=_0x4d5368[_0x52d500('0x2289')],_0x4ff767['gotoZohoAccounts']=_0x49deeb,_0x4ff767[_0x52d500('0x242a')]=_0x4d2e28;function _0x49deeb(){const _0x9fa8a4=_0x52d500;_0x407275['go']('app.integrations.zohoAccounts',{},{'reload':_0x9fa8a4('0x1ef4')});}function _0x4d2e28(){const _0x141b0d=_0x52d500;_0x45b673[_0x141b0d('0xb6c')]['update']({'id':_0x4ff767[_0x141b0d('0x149')]['id']},_0x4ff767[_0x141b0d('0x149')])[_0x141b0d('0xe53')]['then'](function(){const _0x5d6c9d=_0x141b0d;_0x4d5368['success']({'title':_0x5d6c9d('0x2133'),'msg':_0x4ff767[_0x5d6c9d('0x149')][_0x5d6c9d('0x60a')]?_0x4ff767[_0x5d6c9d('0x149')][_0x5d6c9d('0x60a')]+_0x5d6c9d('0x96c'):''});})['catch'](function(_0xfaa298){const _0x183d8a=_0x141b0d;_0x4d5368[_0x183d8a('0x52a')]({'title':_0xfaa298[_0x183d8a('0x13ee')]?_0x183d8a('0x2168')+_0xfaa298[_0x183d8a('0x13ee')]+_0x183d8a('0xbf6')+_0xfaa298[_0x183d8a('0x24a9')]:_0x183d8a('0x23cb'),'msg':_0xfaa298[_0x183d8a('0x5a5')]?JSON[_0x183d8a('0x258a')](_0xfaa298[_0x183d8a('0x5a5')]):_0xfaa298[_0x183d8a('0x1ff0')]()});});}}const _0x3da46e=_0x3688b5,_0x31955b=_0x180212['p']+_0x189033('0x2440');_0x29bfa0[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),'$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),'$translate',_0x189033('0xdd9'),_0x189033('0x2a'),'userProfileSection','api',_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x29bfa0(_0x3489dc,_0x474eed,_0x5067d9,_0xe40486,_0x4adb81,_0x1717df,_0x167a3c,_0xfef0e,_0x561f2f,_0x331331,_0x3e93c5,_0x14e8f2,_0x4d12b6,_0xa8c40f,_0x37c059,_0x23d0a5,_0x3e683e){const _0x30af25=_0x189033,_0x58dab5=this;_0x58dab5[_0x30af25('0xace')]=_0x23d0a5,_0x58dab5[_0x30af25('0x260a')]=_0x3e683e,_0x58dab5[_0x30af25('0x11ed')]=_0x37c059['getCurrentUser'](),_0x58dab5[_0x30af25('0xdd9')]=_0x561f2f||{'count':0x0,'rows':[]},_0x58dab5[_0x30af25('0x2a')]=_0x331331,_0x58dab5[_0x30af25('0x22df')]=_0x3e93c5&&_0x3e93c5[_0x30af25('0x50d')]==0x1?_0x3e93c5['rows'][0x0]:null,_0x58dab5['crudPermissions']=_0x37c059[_0x30af25('0x142a')](_0x58dab5[_0x30af25('0x22df')]?_0x58dab5[_0x30af25('0x22df')][_0x30af25('0x1134')]:null),_0x58dab5[_0x30af25('0x5c4')]='zohoAccounts',_0x58dab5[_0x30af25('0x247')]='',_0x58dab5[_0x30af25('0x1ce2')]=null,_0x58dab5[_0x30af25('0x1921')]=[],_0x58dab5[_0x30af25('0x23a2')]={'fields':_0x30af25('0x152b'),'limit':0xa,'page':0x1},_0x58dab5[_0x30af25('0x24e8')]=_0x2e3ca0()['keyBy']([{'option':'zoho.com','value':_0x30af25('0x122f')},{'option':_0x30af25('0x2600'),'value':_0x30af25('0x152e')}],function(_0x4c8f12){const _0x3c4669=_0x30af25;return _0x2e3ca0()[_0x3c4669('0x1725')](_0x4c8f12['value'],new RegExp('\x27','g'),'');}),_0x58dab5[_0x30af25('0x23df')]=_0x2e3ca0()[_0x30af25('0x24db')]([{'option':'US','value':_0x30af25('0x1b80')},{'option':'AU','value':'\x27AU\x27'},{'option':'EU','value':_0x30af25('0x17f4')},{'option':'IN','value':_0x30af25('0x2ec')},{'option':'CN','value':_0x30af25('0x14a8')}],function(_0x335657){const _0x201c6a=_0x30af25;return _0x2e3ca0()[_0x201c6a('0x1725')](_0x335657[_0x201c6a('0x1c6b')],new RegExp('\x27','g'),'');}),_0x58dab5[_0x30af25('0xc63')]=_0x51e0a9,_0x58dab5[_0x30af25('0x375')]=_0xf2c06f,_0x58dab5[_0x30af25('0x194f')]=_0xbfa308,_0x58dab5['success']=_0xaabf99,_0x58dab5[_0x30af25('0x26f9')]=_0x23d7c1,_0x58dab5[_0x30af25('0x540')]=_0x27e2dd,_0x58dab5['deleteZohoAccount']=_0x3feddd,_0x58dab5['exportSelectedZohoAccounts']=_0x32856b,_0x58dab5[_0x30af25('0x1b49')]=_0x2b75bb,_0x58dab5['deselectZohoAccounts']=_0x449380,_0x58dab5[_0x30af25('0x1d2c')]=_0x39bf4e;function _0x51e0a9(_0x1ae7e5){const _0x34fef0=_0x30af25;_0x5067d9['go'](_0x34fef0('0x219'),{'id':_0x1ae7e5['id'],'zohoAccount':_0x1ae7e5,'crudPermissions':_0x58dab5[_0x34fef0('0x1134')]});}function _0xf2c06f(_0x29121e){const _0x5bf2d8=_0x30af25;return _0x14e8f2[_0x5bf2d8('0xb6c')][_0x5bf2d8('0x298')]({'id':_0x29121e['id'],'test':!![]})[_0x5bf2d8('0xe53')][_0x5bf2d8('0x683')](function(){const _0x29be44=_0x5bf2d8;_0xa8c40f[_0x29be44('0x53')]({'title':_0x29be44('0x10ec'),'msg':_0x29be44('0x1c6d')});})[_0x5bf2d8('0x130a')](function(_0x397353){const _0x3ab101=_0x5bf2d8;_0xa8c40f['error']({'title':'ZohoAccount\x20properly\x20tested','msg':_0x397353['data']?_0x397353[_0x3ab101('0x5a5')]['message']?_0x397353[_0x3ab101('0x5a5')][_0x3ab101('0x8c2')]:JSON[_0x3ab101('0x258a')](_0x397353[_0x3ab101('0x5a5')]):_0x397353[_0x3ab101('0x1ff0')]()});});}function _0xbfa308(_0x5cfe16,_0x3e7435){const _0x2809b5=_0x30af25,_0x306b48=_0x4adb81[_0x2809b5('0x1c6f')]()[_0x2809b5('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x2809b5('0x1e03')](_0x2809b5('0x149'))+'?')[_0x2809b5('0x26e3')](_0x2809b5('0xed5')+(_0x5cfe16[_0x2809b5('0x60a')]||'zohoAccount')+''+_0x2809b5('0x1ee7'))[_0x2809b5('0x1040')]('delete\x20zohoAccount')[_0x2809b5('0xe42')](_0x3e7435)['ok']('OK')[_0x2809b5('0x19fb')](_0x2809b5('0x16b8'));_0x4adb81[_0x2809b5('0x1d4')](_0x306b48)['then'](function(){_0x3feddd(_0x5cfe16);},function(){const _0x2a8ab9=_0x2809b5;console['log'](_0x2a8ab9('0x16b8'));});}let _0x5b2660=!![],_0x3a1396=0x1;_0x3489dc[_0x30af25('0x186d')](_0x30af25('0x1e1d'),function(_0x4434cd,_0x19dd0f){const _0x432738=_0x30af25;_0x5b2660?_0x167a3c(function(){_0x5b2660=![];}):(!_0x19dd0f&&(_0x3a1396=_0x58dab5[_0x432738('0x23a2')]['page']),_0x4434cd!==_0x19dd0f&&(_0x58dab5[_0x432738('0x23a2')][_0x432738('0xdf8')]=0x1),!_0x4434cd&&(_0x58dab5[_0x432738('0x23a2')]['page']=_0x3a1396),_0x58dab5[_0x432738('0x26f9')]());});function _0xaabf99(_0x12efb9){const _0x5eab42=_0x30af25;_0x58dab5[_0x5eab42('0xdd9')]=_0x12efb9||{'count':0x0,'rows':[]};}function _0x23d7c1(){const _0x3fdfe8=_0x30af25;_0x58dab5[_0x3fdfe8('0x23a2')][_0x3fdfe8('0x1cc8')]=(_0x58dab5['query'][_0x3fdfe8('0xdf8')]-0x1)*_0x58dab5[_0x3fdfe8('0x23a2')][_0x3fdfe8('0x6f0')],_0x37c059[_0x3fdfe8('0xca1')]('admin')?_0x58dab5[_0x3fdfe8('0x1883')]=_0x14e8f2[_0x3fdfe8('0xb6c')][_0x3fdfe8('0x1e6e')](_0x58dab5['query'],_0xaabf99)[_0x3fdfe8('0xe53')]:(_0x58dab5[_0x3fdfe8('0x23a2')]['id']=_0x58dab5['userProfile']['id'],_0x58dab5['query'][_0x3fdfe8('0x1aa')]=_0x3fdfe8('0x21ca'),_0x58dab5[_0x3fdfe8('0x1883')]=_0x14e8f2[_0x3fdfe8('0x2a')][_0x3fdfe8('0x241d')](_0x58dab5[_0x3fdfe8('0x23a2')],_0xaabf99)['$promise']);}function _0x27e2dd(_0x2ffd06,_0x192885){const _0x40f0ae=_0x30af25;_0x4adb81[_0x40f0ae('0x1d4')]({'controller':_0x40f0ae('0x1bd6'),'controllerAs':'vm','templateUrl':_0x31955b,'parent':angular['element'](_0x1717df[_0x40f0ae('0x18e5')]),'targetEvent':_0x2ffd06,'clickOutsideToClose':!![],'locals':{'zohoAccount':_0x192885,'zohoAccounts':_0x58dab5[_0x40f0ae('0xdd9')]['rows'],'license':_0x58dab5['license'],'setting':_0x58dab5[_0x40f0ae('0x260a')],'crudPermissions':_0x58dab5['crudPermissions']}});}function _0x3feddd(_0x2f43d3){const _0x5ed7f6=_0x30af25;_0x14e8f2['intZohoAccount'][_0x5ed7f6('0xd7e')]({'id':_0x2f43d3['id']})[_0x5ed7f6('0xe53')][_0x5ed7f6('0x683')](function(){const _0x534a76=_0x5ed7f6;_0x2e3ca0()[_0x534a76('0x3ec')](_0x58dab5[_0x534a76('0xdd9')][_0x534a76('0xf5d')],{'id':_0x2f43d3['id']}),_0x58dab5[_0x534a76('0xdd9')]['count']-=0x1,!_0x58dab5[_0x534a76('0xdd9')]['rows'][_0x534a76('0x1564')]&&_0x58dab5[_0x534a76('0x26f9')](),_0xa8c40f[_0x534a76('0x53')]({'title':_0x2e3ca0()[_0x534a76('0x1e03')](_0x534a76('0xd36'))+'\x20deleted!','msg':_0x2f43d3[_0x534a76('0x60a')]?_0x2f43d3['name']+_0x534a76('0x194d'):''});})['catch'](function(_0x51d4b3){const _0x3307a9=_0x5ed7f6;if(_0x51d4b3[_0x3307a9('0x5a5')]&&_0x51d4b3['data'][_0x3307a9('0x17f')]&&_0x51d4b3[_0x3307a9('0x5a5')]['errors'][_0x3307a9('0x1564')]){_0x58dab5['errors']=_0x51d4b3[_0x3307a9('0x5a5')]['errors']||[{'message':_0x51d4b3[_0x3307a9('0x1ff0')](),'type':_0x3307a9('0x22d4')}];for(let _0x16a5d4=0x0;_0x16a5d4<_0x51d4b3['data'][_0x3307a9('0x17f')][_0x3307a9('0x1564')];_0x16a5d4++){_0xa8c40f[_0x3307a9('0x52a')]({'title':_0x51d4b3[_0x3307a9('0x5a5')][_0x3307a9('0x17f')][_0x16a5d4][_0x3307a9('0xcf0')],'msg':_0x51d4b3['data'][_0x3307a9('0x17f')][_0x16a5d4]['message']});}}else _0xa8c40f[_0x3307a9('0x52a')]({'title':_0x51d4b3[_0x3307a9('0x13ee')]?_0x3307a9('0x2168')+_0x51d4b3['status']+'\x20-\x20'+_0x51d4b3['statusText']:_0x3307a9('0x22d4'),'msg':_0x51d4b3[_0x3307a9('0x5a5')]?JSON[_0x3307a9('0x258a')](_0x51d4b3['data'][_0x3307a9('0x8c2')]):_0x51d4b3[_0x3307a9('0x8c2')]||_0x51d4b3['toString']()});});}function _0x32856b(){const _0x166db6=_0x30af25,_0x371a8d=angular['copy'](_0x58dab5['selectedZohoAccounts']);return _0x58dab5[_0x166db6('0x1921')]=[],_0x371a8d;}function _0x2b75bb(_0x2d3c33){const _0x5670d4=_0x30af25,_0x279125=_0x4adb81[_0x5670d4('0x1c6f')]()[_0x5670d4('0xf28')](_0x5670d4('0x47'))[_0x5670d4('0x26e3')](_0x5670d4('0xed5')+_0x58dab5['selectedZohoAccounts']['length']+_0x5670d4('0x93c')+_0x5670d4('0x1ee7'))[_0x5670d4('0x1040')](_0x5670d4('0x1e84'))['targetEvent'](_0x2d3c33)['ok']('OK')[_0x5670d4('0x19fb')](_0x5670d4('0x16b8'));_0x4adb81[_0x5670d4('0x1d4')](_0x279125)['then'](function(){const _0x145797=_0x5670d4;_0x58dab5[_0x145797('0x1921')][_0x145797('0x1299')](function(_0x3224ad){_0x3feddd(_0x3224ad);}),_0x58dab5['selectedZohoAccounts']=[];});}function _0x449380(){const _0x14319b=_0x30af25;_0x58dab5[_0x14319b('0x1921')]=[];}function _0x39bf4e(){const _0x390933=_0x30af25;_0x58dab5[_0x390933('0x1921')]=_0x58dab5['zohoAccounts'][_0x390933('0xf5d')];}}const _0x5c029b=_0x29bfa0;_0x19e9fe[_0x189033('0x14be')]=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x19e9fe(_0x2e966c,_0x145e18){const _0x13e7fe=_0x189033;_0x2e966c[_0x13e7fe('0x2598')](_0x13e7fe('0xfbf'),{'abstract':!![],'url':_0x13e7fe('0x18cc')})['state'](_0x13e7fe('0x6ff'),{'url':_0x13e7fe('0x647'),'views':{'content@app':{'templateUrl':_0x1cacb4,'controller':_0x13e7fe('0x1662')}},'resolve':{'zendeskAccounts':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x591dd2,_0x1e0ac1){const _0x182071=_0x13e7fe;return _0x1e0ac1[_0x182071('0xca1')](_0x182071('0x20c2'))?_0x591dd2[_0x182071('0xed7')]('intZendeskAccount@get',{'fields':'createdAt,updatedAt,id,name,type,username,remoteUri,authType,password,token,serverUrl,description','limit':0xa,'offset':0x0}):_0x591dd2[_0x182071('0xed7')]('userProfile@getResources',{'id':_0x1e0ac1[_0x182071('0x20b2')]()['userProfileId'],'section':_0x182071('0x21aa'),'fields':_0x182071('0x1695'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x16cc9a,_0x5d2cdc){const _0x1d4777=_0x13e7fe;return _0x5d2cdc[_0x1d4777('0xca1')](_0x1d4777('0x20c2'))?null:_0x16cc9a[_0x1d4777('0xed7')](_0x1d4777('0x1464'),{'fields':_0x1d4777('0x16f'),'id':_0x5d2cdc[_0x1d4777('0x20b2')]()[_0x1d4777('0x2f')]});}],'userProfileSection':['apiResolver',_0x13e7fe('0xba1'),function(_0x1b754e,_0x5ac83e){const _0x1c5879=_0x13e7fe;return _0x5ac83e[_0x1c5879('0xca1')](_0x1c5879('0x20c2'))?null:_0x1b754e[_0x1c5879('0xed7')](_0x1c5879('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x5ac83e[_0x1c5879('0x20b2')]()[_0x1c5879('0x2f')],'sectionId':0x515});}]},'authenticate':!![],'permissionId':0x515,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')](_0x13e7fe('0x1f66'),{'url':'/:id?tab','params':{'zendeskAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x57d37e,'controller':'ZendeskAccountController\x20as\x20vm'}},'resolve':{'zendeskAccount':[_0x13e7fe('0x4b1'),_0x13e7fe('0x8ea'),function(_0x9bfc0c,_0x4a390e){const _0x10560b=_0x13e7fe;return _0x9bfc0c[_0x10560b('0xed7')](_0x10560b('0x13cc'),{'fields':'createdAt,updatedAt,id,name,type,username,remoteUri,authType,password,token,serverUrl,description','id':_0x4a390e['id']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x54b5ef,_0x3359f4){const _0x14e80f=_0x13e7fe;return _0x54b5ef[_0x14e80f('0xed7')](_0x14e80f('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x3359f4[_0x14e80f('0x20b2')]()['userProfileId'],'sectionId':0x515});}]},'authenticate':!![],'permissionId':0x515,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')](_0x13e7fe('0x1eb6'),{'url':'/salesforceAccounts','views':{'content@app':{'templateUrl':_0x3b643a,'controller':_0x13e7fe('0x98c')}},'resolve':{'salesforceAccounts':['apiResolver',_0x13e7fe('0xba1'),function(_0x837628,_0x58cdae){const _0x1d82a8=_0x13e7fe;return _0x58cdae[_0x1d82a8('0xca1')](_0x1d82a8('0x20c2'))?_0x837628[_0x1d82a8('0xed7')](_0x1d82a8('0xc68'),{'fields':'createdAt,updatedAt,id,name,type,username,remoteUri,password,clientId,clientSecret,securityToken,serverUrl,description','limit':0xa,'offset':0x0}):_0x837628['resolve'](_0x1d82a8('0x191b'),{'id':_0x58cdae['getCurrentUser']()[_0x1d82a8('0x2f')],'section':_0x1d82a8('0x613'),'fields':'createdAt,updatedAt,id,name,type,username,remoteUri,password,clientId,clientSecret,securityToken,serverUrl,description','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x13e7fe('0xba1'),function(_0x5a2eea,_0x4d8858){const _0x54087a=_0x13e7fe;return _0x4d8858[_0x54087a('0xca1')]('admin')?null:_0x5a2eea[_0x54087a('0xed7')]('userProfile@get',{'fields':_0x54087a('0x16f'),'id':_0x4d8858['getCurrentUser']()[_0x54087a('0x2f')]});}],'userProfileSection':['apiResolver',_0x13e7fe('0xba1'),function(_0x45d793,_0x7ce47b){const _0x4b7d5a=_0x13e7fe;return _0x7ce47b['hasRole']('admin')?null:_0x45d793[_0x4b7d5a('0xed7')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x7ce47b[_0x4b7d5a('0x20b2')]()[_0x4b7d5a('0x2f')],'sectionId':0x516});}]},'authenticate':!![],'permissionId':0x516,'bodyClass':_0x13e7fe('0x1c2d')})['state'](_0x13e7fe('0x1791'),{'url':_0x13e7fe('0x1560'),'params':{'salesforceAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x55a2a2,'controller':'SalesforceAccountController\x20as\x20vm'}},'resolve':{'salesforceAccount':[_0x13e7fe('0x4b1'),_0x13e7fe('0x8ea'),function(_0xd29e52,_0x541010){const _0x212005=_0x13e7fe;return _0xd29e52[_0x212005('0xed7')](_0x212005('0xc68'),{'fields':_0x212005('0x244c'),'id':_0x541010['id']});}],'userProfileSection':['apiResolver',_0x13e7fe('0xba1'),function(_0x5a7771,_0x42da5f){const _0x192834=_0x13e7fe;return _0x5a7771[_0x192834('0xed7')](_0x192834('0x360'),{'fields':_0x192834('0x1f47'),'userProfileId':_0x42da5f[_0x192834('0x20b2')]()['userProfileId'],'sectionId':0x516});}]},'authenticate':!![],'permissionId':0x516,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')](_0x13e7fe('0x1982'),{'url':_0x13e7fe('0x23d'),'views':{'content@app':{'templateUrl':_0x33c9a8,'controller':_0x13e7fe('0x134b')}},'resolve':{'freshdeskAccounts':['apiResolver',_0x13e7fe('0xba1'),function(_0x32f56f,_0xf050d0){const _0x231ca2=_0x13e7fe;return _0xf050d0[_0x231ca2('0xca1')](_0x231ca2('0x20c2'))?_0x32f56f[_0x231ca2('0xed7')](_0x231ca2('0xe06'),{'fields':'createdAt,updatedAt,id,name,username,remoteUri,apiKey,serverUrl,description','limit':0xa,'offset':0x0}):_0x32f56f[_0x231ca2('0xed7')](_0x231ca2('0x191b'),{'id':_0xf050d0[_0x231ca2('0x20b2')]()[_0x231ca2('0x2f')],'section':_0x231ca2('0x211e'),'fields':'createdAt,updatedAt,id,name,username,remoteUri,apiKey,serverUrl,description','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x13e7fe('0xba1'),function(_0x2678b7,_0x269353){const _0x66b28c=_0x13e7fe;return _0x269353['hasRole'](_0x66b28c('0x20c2'))?null:_0x2678b7[_0x66b28c('0xed7')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x269353['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x2258b1,_0x5a53a1){const _0x23d6d9=_0x13e7fe;return _0x5a53a1[_0x23d6d9('0xca1')](_0x23d6d9('0x20c2'))?null:_0x2258b1[_0x23d6d9('0xed7')](_0x23d6d9('0x360'),{'fields':_0x23d6d9('0x1f47'),'userProfileId':_0x5a53a1['getCurrentUser']()[_0x23d6d9('0x2f')],'sectionId':0x517});}]},'authenticate':!![],'permissionId':0x517,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')]('app.integrations.freshdeskAccounts.edit',{'url':'/:id?tab','params':{'freshdeskAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x42855a,'controller':'FreshdeskAccountController\x20as\x20vm'}},'resolve':{'freshdeskAccount':[_0x13e7fe('0x4b1'),_0x13e7fe('0x8ea'),function(_0xc2545c,_0x72af0b){const _0x325f33=_0x13e7fe;return _0xc2545c[_0x325f33('0xed7')]('intFreshdeskAccount@get',{'fields':_0x325f33('0x149d'),'id':_0x72af0b['id']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x3e83e8,_0x5382ec){const _0xb6037b=_0x13e7fe;return _0x3e83e8['resolve'](_0xb6037b('0x360'),{'fields':_0xb6037b('0x1f47'),'userProfileId':_0x5382ec['getCurrentUser']()['userProfileId'],'sectionId':0x517});}]},'authenticate':!![],'permissionId':0x517,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')]('app.integrations.sugarcrmAccounts',{'url':_0x13e7fe('0x1251'),'views':{'content@app':{'templateUrl':_0x5c8fb4,'controller':_0x13e7fe('0x11cd')}},'resolve':{'sugarcrmAccounts':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x34f590,_0xf165e0){const _0x4808a2=_0x13e7fe;return _0xf165e0[_0x4808a2('0xca1')](_0x4808a2('0x20c2'))?_0x34f590['resolve'](_0x4808a2('0xef2'),{'fields':_0x4808a2('0x1481'),'limit':0xa,'offset':0x0}):_0x34f590[_0x4808a2('0xed7')]('userProfile@getResources',{'id':_0xf165e0['getCurrentUser']()['userProfileId'],'section':_0x4808a2('0x1e70'),'fields':'createdAt,updatedAt,id,name,username,remoteUri,password,serverUrl,description','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x13e7fe('0xba1'),function(_0x5bc49b,_0xd118e8){const _0x4410cf=_0x13e7fe;return _0xd118e8['hasRole'](_0x4410cf('0x20c2'))?null:_0x5bc49b[_0x4410cf('0xed7')](_0x4410cf('0x1464'),{'fields':'id,name,crudPermissions','id':_0xd118e8[_0x4410cf('0x20b2')]()[_0x4410cf('0x2f')]});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x4601f9,_0x4f30cd){const _0x53ce1b=_0x13e7fe;return _0x4f30cd[_0x53ce1b('0xca1')](_0x53ce1b('0x20c2'))?null:_0x4601f9['resolve']('userProfileSection@get',{'fields':_0x53ce1b('0x1f47'),'userProfileId':_0x4f30cd[_0x53ce1b('0x20b2')]()['userProfileId'],'sectionId':0x519});}]},'authenticate':!![],'permissionId':0x519,'bodyClass':_0x13e7fe('0x1c2d')})['state'](_0x13e7fe('0x1eca'),{'url':'/:id?tab','params':{'sugarcrmAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x3a3dc1,'controller':_0x13e7fe('0x2522')}},'resolve':{'sugarcrmAccount':[_0x13e7fe('0x4b1'),_0x13e7fe('0x8ea'),function(_0x478179,_0x2c4944){const _0x5985b1=_0x13e7fe;return _0x478179[_0x5985b1('0xed7')]('intSugarcrmAccount@get',{'fields':'createdAt,updatedAt,id,name,username,remoteUri,password,serverUrl,description','id':_0x2c4944['id']});}],'userProfileSection':['apiResolver',_0x13e7fe('0xba1'),function(_0x5dc24a,_0x9672d){const _0x295ca0=_0x13e7fe;return _0x5dc24a[_0x295ca0('0xed7')](_0x295ca0('0x360'),{'fields':_0x295ca0('0x1f47'),'userProfileId':_0x9672d[_0x295ca0('0x20b2')]()[_0x295ca0('0x2f')],'sectionId':0x519});}]},'authenticate':!![],'permissionId':0x519,'bodyClass':_0x13e7fe('0x1c2d')})['state'](_0x13e7fe('0x1442'),{'url':_0x13e7fe('0x90e'),'views':{'content@app':{'templateUrl':_0x2b688b,'controller':'DeskAccountsController\x20as\x20vm'}},'resolve':{'deskAccounts':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0xea92a5,_0x74bc2f){const _0x584d7b=_0x13e7fe;return _0x74bc2f[_0x584d7b('0xca1')](_0x584d7b('0x20c2'))?_0xea92a5[_0x584d7b('0xed7')](_0x584d7b('0x11ce'),{'fields':_0x584d7b('0x806'),'limit':0xa,'offset':0x0}):_0xea92a5['resolve']('userProfile@getResources',{'id':_0x74bc2f[_0x584d7b('0x20b2')]()[_0x584d7b('0x2f')],'section':_0x584d7b('0x6a8'),'fields':_0x584d7b('0x806'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x5eda7e,_0x5b818a){const _0x49740b=_0x13e7fe;return _0x5b818a[_0x49740b('0xca1')](_0x49740b('0x20c2'))?null:_0x5eda7e[_0x49740b('0xed7')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x5b818a[_0x49740b('0x20b2')]()[_0x49740b('0x2f')]});}],'userProfileSection':['apiResolver',_0x13e7fe('0xba1'),function(_0x3877df,_0x2ecc79){const _0x5169d3=_0x13e7fe;return _0x2ecc79[_0x5169d3('0xca1')](_0x5169d3('0x20c2'))?null:_0x3877df[_0x5169d3('0xed7')](_0x5169d3('0x360'),{'fields':_0x5169d3('0x1f47'),'userProfileId':_0x2ecc79['getCurrentUser']()[_0x5169d3('0x2f')],'sectionId':0x51a});}]},'authenticate':!![],'permissionId':0x51a,'bodyClass':_0x13e7fe('0x1c2d')})['state'](_0x13e7fe('0x1818'),{'url':_0x13e7fe('0x1560'),'params':{'deskAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x17c819,'controller':'DeskAccountController\x20as\x20vm'}},'resolve':{'deskAccount':[_0x13e7fe('0x4b1'),_0x13e7fe('0x8ea'),function(_0x30242c,_0x15a44f){const _0x4f9e8e=_0x13e7fe;return _0x30242c[_0x4f9e8e('0xed7')](_0x4f9e8e('0x11ce'),{'fields':_0x4f9e8e('0x806'),'id':_0x15a44f['id']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x464821,_0x3d7d2f){const _0x4316=_0x13e7fe;return _0x464821[_0x4316('0xed7')](_0x4316('0x360'),{'fields':_0x4316('0x1f47'),'userProfileId':_0x3d7d2f[_0x4316('0x20b2')]()['userProfileId'],'sectionId':0x51a});}]},'authenticate':!![],'permissionId':0x51a,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')]('app.integrations.zohoAccounts',{'url':_0x13e7fe('0x21d3'),'views':{'content@app':{'templateUrl':_0x30bd8a,'controller':_0x13e7fe('0x220a')}},'resolve':{'zohoAccounts':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x1a7a6d,_0xfa2edd){const _0x394cb3=_0x13e7fe;return _0xfa2edd[_0x394cb3('0xca1')](_0x394cb3('0x20c2'))?_0x1a7a6d[_0x394cb3('0xed7')](_0x394cb3('0x4b2'),{'fields':_0x394cb3('0x152b'),'limit':0xa,'offset':0x0}):_0x1a7a6d[_0x394cb3('0xed7')](_0x394cb3('0x191b'),{'id':_0xfa2edd[_0x394cb3('0x20b2')]()['userProfileId'],'section':_0x394cb3('0x21ca'),'fields':_0x394cb3('0x152b'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x3a50e7,_0x225cbd){const _0x5c8243=_0x13e7fe;return _0x225cbd[_0x5c8243('0xca1')](_0x5c8243('0x20c2'))?null:_0x3a50e7[_0x5c8243('0xed7')]('userProfile@get',{'fields':_0x5c8243('0x16f'),'id':_0x225cbd[_0x5c8243('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0xf1a76a,_0x490e51){const _0x41e284=_0x13e7fe;return _0x490e51[_0x41e284('0xca1')](_0x41e284('0x20c2'))?null:_0xf1a76a[_0x41e284('0xed7')](_0x41e284('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x490e51[_0x41e284('0x20b2')]()[_0x41e284('0x2f')],'sectionId':0x51b});}]},'authenticate':!![],'permissionId':0x51b,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')](_0x13e7fe('0x219'),{'url':_0x13e7fe('0x1560'),'params':{'zohoAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x24baf4,'controller':_0x13e7fe('0x450')}},'resolve':{'zohoAccount':[_0x13e7fe('0x4b1'),_0x13e7fe('0x8ea'),function(_0x580b2a,_0x5ad9f2){const _0x3f2372=_0x13e7fe;return _0x580b2a[_0x3f2372('0xed7')]('intZohoAccount@get',{'fields':_0x3f2372('0x152b'),'id':_0x5ad9f2['id']});}],'userProfileSection':[_0x13e7fe('0x4b1'),'Auth',function(_0x8c8626,_0xd27b90){const _0x54ca0e=_0x13e7fe;return _0x8c8626[_0x54ca0e('0xed7')](_0x54ca0e('0x360'),{'fields':_0x54ca0e('0x1f47'),'userProfileId':_0xd27b90[_0x54ca0e('0x20b2')]()[_0x54ca0e('0x2f')],'sectionId':0x51b});}]},'authenticate':!![],'permissionId':0x51b,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')](_0x13e7fe('0x1dca'),{'url':_0x13e7fe('0x283f'),'views':{'content@app':{'templateUrl':_0x455be5,'controller':_0x13e7fe('0x1dfa')}},'resolve':{'vtigerAccounts':['apiResolver',_0x13e7fe('0xba1'),function(_0x4064ba,_0x8c6d41){const _0x4fec78=_0x13e7fe;return _0x8c6d41[_0x4fec78('0xca1')](_0x4fec78('0x20c2'))?_0x4064ba[_0x4fec78('0xed7')](_0x4fec78('0x1c58'),{'fields':'createdAt,updatedAt,id,name,description,username,accessKey,remoteUri,serverUrl','limit':0xa,'offset':0x0}):_0x4064ba[_0x4fec78('0xed7')](_0x4fec78('0x191b'),{'id':_0x8c6d41[_0x4fec78('0x20b2')]()[_0x4fec78('0x2f')],'section':_0x4fec78('0x1392'),'fields':_0x4fec78('0x188b'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x30f883,_0x1c98f0){const _0x55bb39=_0x13e7fe;return _0x1c98f0[_0x55bb39('0xca1')](_0x55bb39('0x20c2'))?null:_0x30f883[_0x55bb39('0xed7')]('userProfile@get',{'fields':_0x55bb39('0x16f'),'id':_0x1c98f0[_0x55bb39('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x30268a,_0x2bf6f3){const _0x522118=_0x13e7fe;return _0x2bf6f3[_0x522118('0xca1')](_0x522118('0x20c2'))?null:_0x30268a[_0x522118('0xed7')](_0x522118('0x360'),{'fields':_0x522118('0x1f47'),'userProfileId':_0x2bf6f3[_0x522118('0x20b2')]()[_0x522118('0x2f')],'sectionId':0x51c});}]},'authenticate':!![],'permissionId':0x51c,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')]('app.integrations.vtigerAccounts.edit',{'url':'/:id?tab','params':{'vtigerAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x4ac943,'controller':_0x13e7fe('0xfe0')}},'resolve':{'vtigerAccount':[_0x13e7fe('0x4b1'),_0x13e7fe('0x8ea'),function(_0x1e86ed,_0x20bf61){const _0xeede79=_0x13e7fe;return _0x1e86ed[_0xeede79('0xed7')](_0xeede79('0x1c58'),{'fields':'createdAt,updatedAt,id,name,description,username,accessKey,remoteUri,serverUrl','id':_0x20bf61['id']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x29e48b,_0x28a5ba){const _0x3e4fd7=_0x13e7fe;return _0x29e48b[_0x3e4fd7('0xed7')](_0x3e4fd7('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x28a5ba[_0x3e4fd7('0x20b2')]()[_0x3e4fd7('0x2f')],'sectionId':0x51c});}]},'authenticate':!![],'permissionId':0x51c,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')]('app.integrations.dynamics365Accounts',{'url':'/dynamics365Accounts','views':{'content@app':{'templateUrl':_0x1008d1,'controller':_0x13e7fe('0x18d6')}},'resolve':{'dynamics365Accounts':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0xd5a9cb,_0x3b6127){const _0x2a2840=_0x13e7fe;return _0x3b6127['hasRole'](_0x2a2840('0x20c2'))?_0xd5a9cb[_0x2a2840('0xed7')](_0x2a2840('0xa66'),{'fields':_0x2a2840('0x1cdf'),'limit':0xa,'offset':0x0}):_0xd5a9cb[_0x2a2840('0xed7')](_0x2a2840('0x191b'),{'id':_0x3b6127['getCurrentUser']()['userProfileId'],'section':_0x2a2840('0xa0a'),'fields':_0x2a2840('0x1cdf'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x13e7fe('0xba1'),function(_0x3d3279,_0x421665){const _0x5808ef=_0x13e7fe;return _0x421665[_0x5808ef('0xca1')](_0x5808ef('0x20c2'))?null:_0x3d3279['resolve']('userProfile@get',{'fields':_0x5808ef('0x16f'),'id':_0x421665[_0x5808ef('0x20b2')]()[_0x5808ef('0x2f')]});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x5bc7a1,_0x1dee66){const _0x3a0283=_0x13e7fe;return _0x1dee66['hasRole'](_0x3a0283('0x20c2'))?null:_0x5bc7a1['resolve'](_0x3a0283('0x360'),{'fields':_0x3a0283('0x1f47'),'userProfileId':_0x1dee66['getCurrentUser']()['userProfileId'],'sectionId':0x51d});}]},'authenticate':!![],'permissionId':0x51d,'bodyClass':'integrations'})[_0x13e7fe('0x2598')](_0x13e7fe('0x3ce'),{'url':_0x13e7fe('0x1560'),'params':{'dynamics365Account':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x15b0ab,'controller':_0x13e7fe('0xfef')}},'resolve':{'dynamics365Account':[_0x13e7fe('0x4b1'),_0x13e7fe('0x8ea'),function(_0x3dc7d8,_0x26a92c){const _0x2512be=_0x13e7fe;return _0x3dc7d8['resolve'](_0x2512be('0xa66'),{'fields':_0x2512be('0x1cdf'),'id':_0x26a92c['id']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x1ae3fa,_0x24125b){const _0x3e904c=_0x13e7fe;return _0x1ae3fa[_0x3e904c('0xed7')](_0x3e904c('0x360'),{'fields':_0x3e904c('0x1f47'),'userProfileId':_0x24125b[_0x3e904c('0x20b2')]()[_0x3e904c('0x2f')],'sectionId':0x51d});}]},'authenticate':!![],'permissionId':0x51d,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')](_0x13e7fe('0x2847'),{'url':_0x13e7fe('0xd8c'),'views':{'content@app':{'templateUrl':_0x2b74ee,'controller':_0x13e7fe('0xaee')}},'resolve':{'servicenowAccounts':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x34baaf,_0x332dab){const _0x112dbb=_0x13e7fe;return _0x332dab[_0x112dbb('0xca1')](_0x112dbb('0x20c2'))?_0x34baaf['resolve']('intServicenowAccount@get',{'fields':_0x112dbb('0x7ea'),'limit':0xa,'offset':0x0}):_0x34baaf[_0x112dbb('0xed7')](_0x112dbb('0x191b'),{'id':_0x332dab[_0x112dbb('0x20b2')]()['userProfileId'],'section':_0x112dbb('0x201e'),'fields':_0x112dbb('0x7ea'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x4cb926,_0x2fbff1){const _0x101c0f=_0x13e7fe;return _0x2fbff1[_0x101c0f('0xca1')](_0x101c0f('0x20c2'))?null:_0x4cb926[_0x101c0f('0xed7')](_0x101c0f('0x1464'),{'fields':_0x101c0f('0x16f'),'id':_0x2fbff1[_0x101c0f('0x20b2')]()[_0x101c0f('0x2f')]});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x2c7528,_0x1fb498){const _0x1ae341=_0x13e7fe;return _0x1fb498[_0x1ae341('0xca1')](_0x1ae341('0x20c2'))?null:_0x2c7528[_0x1ae341('0xed7')](_0x1ae341('0x360'),{'fields':_0x1ae341('0x1f47'),'userProfileId':_0x1fb498[_0x1ae341('0x20b2')]()['userProfileId'],'sectionId':0x51e});}]},'authenticate':!![],'permissionId':0x51e,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')](_0x13e7fe('0x1610'),{'url':_0x13e7fe('0x1560'),'params':{'servicenowAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0xdbe799,'controller':_0x13e7fe('0x1806')}},'resolve':{'servicenowAccount':['apiResolver',_0x13e7fe('0x8ea'),function(_0xb41cad,_0x283ead){const _0xcbd041=_0x13e7fe;return _0xb41cad[_0xcbd041('0xed7')](_0xcbd041('0x379'),{'fields':_0xcbd041('0x7ea'),'id':_0x283ead['id']});}],'userProfileSection':[_0x13e7fe('0x4b1'),'Auth',function(_0x8db37e,_0x339765){const _0x7fddec=_0x13e7fe;return _0x8db37e[_0x7fddec('0xed7')](_0x7fddec('0x360'),{'fields':_0x7fddec('0x1f47'),'userProfileId':_0x339765['getCurrentUser']()[_0x7fddec('0x2f')],'sectionId':0x51e});}]},'authenticate':!![],'permissionId':0x51e,'bodyClass':_0x13e7fe('0x1c2d')})['state'](_0x13e7fe('0xd78'),{'url':_0x13e7fe('0x6ce'),'views':{'content@app':{'templateUrl':_0x35df94,'controller':_0x13e7fe('0x26d7')}},'resolve':{'freshsalesAccounts':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x2294ba,_0x3b1000){const _0x1709a9=_0x13e7fe;return _0x3b1000[_0x1709a9('0xca1')](_0x1709a9('0x20c2'))?_0x2294ba['resolve']('intFreshsalesAccount@get',{'fields':_0x1709a9('0x149d'),'limit':0xa,'offset':0x0}):_0x2294ba[_0x1709a9('0xed7')](_0x1709a9('0x191b'),{'id':_0x3b1000['getCurrentUser']()[_0x1709a9('0x2f')],'section':_0x1709a9('0x94f'),'fields':'createdAt,updatedAt,id,name,username,remoteUri,apiKey,serverUrl,description','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x13e7fe('0xba1'),function(_0x548880,_0xe55e9a){const _0x571dde=_0x13e7fe;return _0xe55e9a[_0x571dde('0xca1')](_0x571dde('0x20c2'))?null:_0x548880[_0x571dde('0xed7')](_0x571dde('0x1464'),{'fields':'id,name,crudPermissions','id':_0xe55e9a['getCurrentUser']()['userProfileId']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x1af44b,_0x24a913){const _0x10b0d7=_0x13e7fe;return _0x24a913[_0x10b0d7('0xca1')]('admin')?null:_0x1af44b[_0x10b0d7('0xed7')](_0x10b0d7('0x360'),{'fields':_0x10b0d7('0x1f47'),'userProfileId':_0x24a913[_0x10b0d7('0x20b2')]()[_0x10b0d7('0x2f')],'sectionId':0x518});}]},'authenticate':!![],'permissionId':0x518,'bodyClass':_0x13e7fe('0x1c2d')})[_0x13e7fe('0x2598')](_0x13e7fe('0x11c7'),{'url':_0x13e7fe('0x1560'),'params':{'freshsalesAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x5b7175,'controller':_0x13e7fe('0x1238')}},'resolve':{'freshsalesAccount':['apiResolver',_0x13e7fe('0x8ea'),function(_0x40921e,_0x597cd9){const _0x1886a9=_0x13e7fe;return _0x40921e['resolve'](_0x1886a9('0x612'),{'fields':_0x1886a9('0x149d'),'id':_0x597cd9['id']});}],'userProfileSection':[_0x13e7fe('0x4b1'),_0x13e7fe('0xba1'),function(_0x568695,_0x42666c){const _0x53266f=_0x13e7fe;return _0x568695[_0x53266f('0xed7')](_0x53266f('0x360'),{'fields':_0x53266f('0x1f47'),'userProfileId':_0x42666c[_0x53266f('0x20b2')]()[_0x53266f('0x2f')],'sectionId':0x518});}]},'authenticate':!![],'permissionId':0x518,'bodyClass':_0x13e7fe('0x1c2d')}),_0x145e18[_0x13e7fe('0x7d2')](_0x13e7fe('0x1bda'));}angular['module'](_0x189033('0xfbf'),['ngCsv',_0x189033('0x1ddb'),_0x189033('0x2290'),_0x189033('0x190a'),'mdColorPicker',_0x189033('0x2835'),_0x189033('0x1d9c'),'ngAria',_0x189033('0x273d'),_0x189033('0x76'),'mwFormBuilder',_0x189033('0x7fa'),_0x189033('0x197b'),'ngclipboard','angular-cron-jobs','ngEmbed',_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da')])[_0x189033('0x272d')](_0x19e9fe)[_0x189033('0x1da3')](_0x189033('0x2385'),_0x12f9be)[_0x189033('0x1da3')]('DeskAccountsController',_0x59bd2a)['controller']('DeskAccountConfigurationsController',_0x3361c4)[_0x189033('0x1da3')](_0x189033('0x1900'),_0x27bf2d)[_0x189033('0x1da3')]('CreateOrEditDeskAccountItemDialogController',_0xfe546)[_0x189033('0x1da3')]('DeskAccountController',_0x5e36b2)[_0x189033('0x1da3')](_0x189033('0x1052'),_0x604d91)[_0x189033('0x1da3')](_0x189033('0x2415'),_0x181331)[_0x189033('0x1da3')](_0x189033('0xe6e'),_0x515d32)[_0x189033('0x1da3')](_0x189033('0xe9b'),_0x482b83)[_0x189033('0x1da3')](_0x189033('0x2182'),_0x195d64)[_0x189033('0x1da3')](_0x189033('0x19e7'),_0x4a548c)[_0x189033('0x1da3')](_0x189033('0x451'),_0x182e52)[_0x189033('0x1da3')](_0x189033('0x18c8'),_0xd5c486)[_0x189033('0x1da3')](_0x189033('0xd80'),_0x370357)[_0x189033('0x1da3')](_0x189033('0x96'),_0x4ef6f3)['controller'](_0x189033('0xd74'),_0x183000)[_0x189033('0x1da3')]('FreshdeskAccountsController',_0x27b562)[_0x189033('0x1da3')](_0x189033('0x635'),_0x158e09)[_0x189033('0x1da3')](_0x189033('0x25a3'),_0x3e2a61)[_0x189033('0x1da3')](_0x189033('0xf19'),_0x21a16b)[_0x189033('0x1da3')](_0x189033('0x2428'),_0x53b96b)['controller']('FreshsalesAccountController',_0x7401db)[_0x189033('0x1da3')](_0x189033('0x1a97'),_0x6c7185)[_0x189033('0x1da3')]('CreateOrEditSalesforceAccountDialogController',_0x4b6c99)[_0x189033('0x1da3')](_0x189033('0xaea'),_0x2beb2b)['controller'](_0x189033('0x1a1e'),_0x2dc897)[_0x189033('0x1da3')](_0x189033('0x25f4'),_0x3a66fe)[_0x189033('0x1da3')](_0x189033('0x26c7'),_0x520e38)['controller'](_0x189033('0x63a'),_0x51114e)[_0x189033('0x1da3')](_0x189033('0x263f'),_0x1178a9)[_0x189033('0x1da3')](_0x189033('0x85c'),_0x34c593)[_0x189033('0x1da3')](_0x189033('0xf23'),_0xe6262c)['controller'](_0x189033('0x258'),_0x594da9)['controller'](_0x189033('0x6b3'),_0x4c4dbf)['controller'](_0x189033('0x1620'),_0x477350)[_0x189033('0x1da3')](_0x189033('0x247f'),_0x9b488c)[_0x189033('0x1da3')](_0x189033('0x1ee3'),_0xc72a12)[_0x189033('0x1da3')](_0x189033('0x115f'),_0x12e726)['controller']('CreateOrEditSugarcrmAccountItemDialogController',_0x43cd3a)['controller'](_0x189033('0x1ef7'),_0x1e4ce5)['controller'](_0x189033('0x17bc'),_0x1ceb40)['controller']('CreateOrEditVtigerAccountDialogController',_0x36b5ad)['controller'](_0x189033('0x22bc'),_0x2056a7)['controller']('CreateOrEditVtigerConfigurationDialogController',_0x1e3c92)[_0x189033('0x1da3')]('CreateOrEditVtigerAccountItemDialogController',_0x25a06b)[_0x189033('0x1da3')](_0x189033('0x20bb'),_0x5a1538)['controller']('VtigerAccountsController',_0x1f1136)[_0x189033('0x1da3')](_0x189033('0x109f'),_0x544ea8)[_0x189033('0x1da3')](_0x189033('0x1223'),_0x35cbaf)['controller']('ZendeskAccountController',_0x18c387)[_0x189033('0x1da3')]('ZendeskAccountConfigurationsController',_0x5026bf)[_0x189033('0x1da3')](_0x189033('0x6c5'),_0x257f5f)[_0x189033('0x1da3')](_0x189033('0x18bf'),_0xedbff7)['controller'](_0x189033('0x1bd6'),_0x4d4f74)[_0x189033('0x1da3')](_0x189033('0x142f'),_0x1e5398)['controller'](_0x189033('0x11'),_0x5b90c0)[_0x189033('0x1da3')](_0x189033('0x1933'),_0x14c1c3)[_0x189033('0x1da3')]('ZohoAccountController',_0x3da46e)[_0x189033('0x1da3')](_0x189033('0xc52'),_0x5c029b);const _0x4b5820=_0x180212['p']+_0x189033('0x2690'),_0x4d031e=_0x180212['p']+_0x189033('0x2ba'),_0x3cfac1=_0x180212['p']+_0x189033('0x1907');_0x6d762b['$inject']=[_0x189033('0x16ea'),'$mdDialog',_0x189033('0x938'),'license',_0x189033('0x1d70'),_0x189033('0x56b')];function _0x6d762b(_0x5b5d86,_0x4e659a,_0x5dd7ea,_0x47394f,_0x17e4d9,_0x342b2c){const _0x3ef0b0=_0x189033,_0x74748a=this;_0x74748a[_0x3ef0b0('0xace')]=_0x47394f||{},_0x74748a[_0x3ef0b0('0x756')]=0x0,_0x74748a[_0x3ef0b0('0x3bf')]=0x0,_0x74748a['telephones']=0x0,_0x74748a[_0x3ef0b0('0x178a')]=[{'name':'voice','icon':_0x3ef0b0('0xd73')},{'name':_0x3ef0b0('0x24e'),'icon':_0x3ef0b0('0xa46')},{'name':_0x3ef0b0('0x129f'),'icon':'icon-email'},{'name':'messaging','icon':'icon-message-text'},{'name':_0x3ef0b0('0x23e9'),'icon':_0x3ef0b0('0x8e9')},{'name':_0x3ef0b0('0x1261'),'icon':_0x3ef0b0('0x13f1')},{'name':_0x3ef0b0('0x16e7'),'icon':_0x3ef0b0('0x1b55')}],_0x74748a[_0x3ef0b0('0x12bc')]=[{'name':'cm','icon':_0x3ef0b0('0x20cd')},{'name':'dialer','icon':_0x3ef0b0('0x16a7')},{'name':_0x3ef0b0('0x18e6'),'icon':_0x3ef0b0('0x1c18')}],_0x74748a['addons']=[{'name':_0x3ef0b0('0xd04'),'icon':'icon-server-plus'},{'name':_0x3ef0b0('0x233e'),'icon':_0x3ef0b0('0x1fd5')},{'name':'custom','icon':'icon-table-edit'},{'name':_0x3ef0b0('0xd70'),'icon':_0x3ef0b0('0x1ae1')},{'name':'ai','icon':_0x3ef0b0('0x256f')}],_0x74748a[_0x3ef0b0('0x2be')]=[{'name':_0x3ef0b0('0x1c5e'),'icon':_0x3ef0b0('0xd65'),'restart':!![],'label':_0x3ef0b0('0x178a'),'enabled':_0x3ef0b0('0xcf2')},{'name':_0x3ef0b0('0x879'),'icon':_0x3ef0b0('0x8bc'),'restart':![],'label':_0x3ef0b0('0x2be'),'enabled':_0x3ef0b0('0x24e')}],_0x74748a[_0x3ef0b0('0xfdc')]=[{'name':_0x3ef0b0('0x2480'),'icon':'icon-cloud-download'}],_0x342b2c[_0x3ef0b0('0xc96')][_0x3ef0b0('0x1e6e')]({'fields':'id','role':'agent','online':!![]})[_0x3ef0b0('0xe53')][_0x3ef0b0('0x683')](function(_0x9995e4){const _0x4b9488=_0x3ef0b0;return _0x74748a[_0x4b9488('0x756')]=_0x9995e4&&_0x9995e4['count']?_0x9995e4[_0x4b9488('0x50d')]:0x0,_0x342b2c[_0x4b9488('0xc96')]['get']({'fields':'id','role':'user,admin'})[_0x4b9488('0xe53')];})[_0x3ef0b0('0x683')](function(_0x336d9a){const _0x28edff=_0x3ef0b0;return _0x74748a['users']=_0x336d9a&&_0x336d9a[_0x28edff('0x50d')]?_0x336d9a[_0x28edff('0x50d')]:0x0,_0x342b2c[_0x28edff('0xc96')][_0x28edff('0x1e6e')]({'fields':'id','role':'telephone'})[_0x28edff('0xe53')];})[_0x3ef0b0('0x683')](function(_0x397511){const _0x566227=_0x3ef0b0;_0x74748a[_0x566227('0x723')]=_0x397511&&_0x397511['count']?_0x397511[_0x566227('0x50d')]:0x0;})[_0x3ef0b0('0x130a')](function(_0x28370){const _0x1e50b5=_0x3ef0b0;console[_0x1e50b5('0x1b2b')](_0x28370);});function _0x8c7b5a(_0x107bbb){const _0x49ac90=_0x3ef0b0;_0x4e659a[_0x49ac90('0x1d4')]({'controller':_0x49ac90('0x13a7'),'controllerAs':'vm','templateUrl':_0x4d031e,'parent':angular[_0x49ac90('0x1fcc')](_0x5b5d86[_0x49ac90('0x18e5')]),'targetEvent':_0x107bbb,'clickOutsideToClose':!![],'locals':{'license':_0x47394f}});}function _0x3a5c1b(_0x4e85a3){const _0x1b0a8d=_0x3ef0b0;_0x4e659a[_0x1b0a8d('0x1d4')]({'controller':_0x1b0a8d('0x1588'),'controllerAs':'vm','templateUrl':_0x3cfac1,'parent':angular[_0x1b0a8d('0x1fcc')](_0x5b5d86[_0x1b0a8d('0x18e5')]),'targetEvent':_0x4e85a3,'clickOutsideToClose':!![],'locals':{'license':_0x47394f,'channels':_0x74748a[_0x1b0a8d('0x178a')],'modules':_0x74748a[_0x1b0a8d('0x12bc')],'addons':_0x74748a['addons'],'sessions':_0x74748a[_0x1b0a8d('0x2be')],'others':_0x74748a['others']}});}function _0x140d78(){const _0x2b9221=_0x3ef0b0;_0x5dd7ea['go'](_0x2b9221('0xbd3'),{'tab':0x1});}_0x74748a[_0x3ef0b0('0x1737')]=_0x3a5c1b,_0x74748a[_0x3ef0b0('0x2135')]=_0x8c7b5a,_0x74748a[_0x3ef0b0('0x50a')]=_0x140d78;}const _0x382d75=_0x6d762b;_0x3a6f70[_0x189033('0x14be')]=['$mdDialog','toasty',_0x189033('0xace'),'channels',_0x189033('0x12bc'),_0x189033('0x1232'),_0x189033('0x2be'),_0x189033('0xfdc'),'api',_0x189033('0xba1'),_0x189033('0x1d08')];function _0x3a6f70(_0xd48eaa,_0x3303b0,_0x244c15,_0x357a85,_0x18727e,_0xc4310c,_0x106e3e,_0x4f4bc2,_0x33e287,_0xbe24d5,_0x35985f){const _0x1a6c31=_0x189033,_0x48152a=this;_0x48152a[_0x1a6c31('0x17f')]=[],_0x48152a['user']=_0xbe24d5['getCurrentUser'](),_0x48152a['license']=angular['copy'](_0x244c15),_0x48152a[_0x1a6c31('0x178a')]=_0x357a85,_0x48152a[_0x1a6c31('0x12bc')]=_0x18727e,_0x48152a[_0x1a6c31('0x1232')]=_0xc4310c,_0x48152a[_0x1a6c31('0x2be')]=_0x106e3e,_0x48152a[_0x1a6c31('0xfdc')]=_0x4f4bc2,_0x48152a['license'][_0x1a6c31('0x60a')]=_0x48152a[_0x1a6c31('0xc96')]['fullname'],_0x48152a[_0x1a6c31('0xace')]['email']=_0x48152a['user'][_0x1a6c31('0x1c92')],_0x48152a['sendRequest']=_0x3e1789,_0x48152a['closeDialog']=_0x497a1c;function _0x3e1789(){const _0x1a05e1=_0x1a6c31;_0x48152a['errors']=[],_0x48152a['table']=_0x1a05e1('0x7a6');for(const _0x243dad in _0x48152a[_0x1a05e1('0xace')]){typeof _0x48152a[_0x1a05e1('0xace')][_0x243dad]!==_0x1a05e1('0x1867')&&!_0x2e3ca0()['includes'](['$promise',_0x1a05e1('0x1980')],_0x243dad)&&(_0x244c15[_0x243dad]===_0x48152a[_0x1a05e1('0xace')][_0x243dad]?_0x48152a[_0x1a05e1('0x5c4')]+='|'+_0x243dad+'|'+(_0x244c15[_0x243dad]!==undefined?_0x244c15[_0x243dad]:'')+'|'+_0x48152a[_0x1a05e1('0xace')][_0x243dad]+'|\x0a':_0x48152a['table']+='|'+_0x243dad+_0x1a05e1('0x162')+(_0x244c15[_0x243dad]!==undefined?_0x244c15[_0x243dad]:'')+_0x1a05e1('0x1ad')+_0x48152a[_0x1a05e1('0xace')][_0x243dad]+_0x1a05e1('0x6a7'));}_0x33e287[_0x1a05e1('0x2891')][_0x1a05e1('0xb0a')]({'key':_0x1a05e1('0x6b2'),'summary':_0x1a05e1('0x211c'),'description':_0x48152a[_0x1a05e1('0x5c4')],'issuetype':_0x1a05e1('0x20ba')})[_0x1a05e1('0xe53')][_0x1a05e1('0x683')](function(){const _0x16af52=_0x1a05e1;_0x3303b0[_0x16af52('0x53')]({'title':_0x16af52('0x229a'),'msg':_0x35985f['instant'](_0x16af52('0xc5b')),'timeout':0x3a98}),_0x497a1c();})[_0x1a05e1('0x130a')](function(_0x2e1f97){const _0x2b861f=_0x1a05e1;console[_0x2b861f('0x52a')](_0x2e1f97),_0x48152a[_0x2b861f('0x17f')]=[{'message':_0x35985f[_0x2b861f('0x2728')](_0x2b861f('0x27d8')),'type':_0x2b861f('0x1b3')}];});}function _0x497a1c(){const _0x28c985=_0x1a6c31;_0xd48eaa[_0x28c985('0x1715')]();}}const _0x1fbf22=_0x3a6f70;_0x3b4447['$inject']=['$mdDialog',_0x189033('0x1d70'),_0x189033('0xace'),_0x189033('0x56b')];function _0x3b4447(_0x27cf5f,_0x199558,_0x4a5971,_0xecf71a){const _0x21893e=_0x189033,_0x23b8af=this;_0x23b8af[_0x21893e('0x17f')]=[],_0x23b8af['license']=angular[_0x21893e('0x1a86')](_0x4a5971),_0x23b8af[_0x21893e('0x1041')],_0x23b8af[_0x21893e('0x2135')]=_0x558e3a,_0x23b8af[_0x21893e('0xf82')]=_0x5cb6c8;function _0x558e3a(){const _0xa30a96=_0x21893e;return _0xecf71a[_0xa30a96('0xace')][_0xa30a96('0x2480')]({'id':0x1,'key':_0x23b8af[_0xa30a96('0x1041')]})['$promise'][_0xa30a96('0x683')](function(_0x249e11){const _0x376584=_0xa30a96;_0x249e11&&(_0x249e11[_0x376584('0xcc1')]?_0x199558['error']({'title':_0x376584('0x254a'),'msg':'Invalid\x20license\x20key'}):_0x199558[_0x376584('0x53')]({'title':'License\x20properly\x20updated!','msg':_0x376584('0x1738')}));})[_0xa30a96('0x130a')](function(_0x528ec1){const _0x51467e=_0xa30a96;_0x199558['error']({'title':_0x528ec1[_0x51467e('0x13ee')]?_0x51467e('0x2168')+_0x528ec1[_0x51467e('0x13ee')]+_0x51467e('0xbf6')+_0x528ec1['statusText']:'SYSTEM:UPDATElicense','msg':_0x528ec1[_0x51467e('0x5a5')]?JSON['stringify'](_0x528ec1[_0x51467e('0x5a5')]):_0x528ec1[_0x51467e('0x1ff0')]()});});}function _0x5cb6c8(){const _0x1e9a60=_0x21893e;_0x27cf5f[_0x1e9a60('0x1715')]();}}const _0x538d68=_0x3b4447;_0x3679ae[_0x189033('0x14be')]=['$stateProvider'];function _0x3679ae(_0xf4cb2e){const _0x43ba3c=_0x189033;_0xf4cb2e[_0x43ba3c('0x2598')](_0x43ba3c('0x2024'),{'url':_0x43ba3c('0xe07'),'views':{'content@app':{'templateUrl':_0x4b5820,'controller':'LicenseController\x20as\x20vm'}},'authenticate':!![],'permissionId':0x578,'bodyClass':_0x43ba3c('0x5c3')});}angular[_0x189033('0x1e26')](_0x189033('0x2024'),[])['config'](_0x3679ae)[_0x189033('0x1da3')](_0x189033('0x1703'),_0x382d75)[_0x189033('0x1da3')](_0x189033('0x1588'),_0x1fbf22)[_0x189033('0x1da3')]('UpdateLicenseDialogController',_0x538d68);const _0x9553f3=_0x180212['p']+_0x189033('0x20fb');_0x589487[_0x189033('0x14be')]=['$scope',_0x189033('0x1b27'),'$mdDialog',_0x189033('0x938'),_0x189033('0x24f2'),'processes','toasty','api'];function _0x589487(_0x4e4e04,_0x56ec56,_0x39729a,_0x1cc1d4,_0x36fa1d,_0x32063d,_0x32c167,_0x42b8e5){const _0x289942=_0x189033,_0x30e183=this;let _0x4860bf=null;_0x30e183[_0x289942('0x24f2')]=_0x36fa1d||{},_0x30e183[_0x289942('0x133c')]=_0x32063d?_0x32063d[_0x289942('0xf5d')]:[],_0x30e183[_0x289942('0x55a')]=0x7,_0x30e183['selectedTab']=_0x1cc1d4[_0x289942('0x7f2')]['tab']||0x0,_0x30e183['getInfo']=_0x40d775,_0x30e183['getProcesses']=_0x553a45,_0x30e183[_0x289942('0x1d6b')]=_0x37fb3e,_0x30e183[_0x289942('0xc04')]=_0xc70924;function _0x37fb3e(){const _0x237a22=_0x289942;_0x56ec56[_0x237a22('0x19fb')](_0x4860bf),_0x4860bf=null;}function _0xc70924(_0x4e7be2,_0x56639d,_0x442e7a){const _0xd585cd=_0x289942,_0x43b646=_0x39729a['confirm']()[_0xd585cd('0xf28')](_0xd585cd('0x186f')+_0x56639d+'?')[_0xd585cd('0x1525')](_0xd585cd('0x16d9')+_0x442e7a[_0xd585cd('0x80')]())[_0xd585cd('0x1040')]('Lucky\x20day')[_0xd585cd('0xe42')](_0x4e7be2)['ok']('Ok')[_0xd585cd('0x19fb')]('Cancel');_0x39729a['show'](_0x43b646)[_0xd585cd('0x683')](function(){const _0x10fe69=_0xd585cd;return _0x42b8e5[_0x10fe69('0x2c2')][_0x10fe69('0x2480')]({'id':_0x56639d,'status':_0x442e7a});})[_0xd585cd('0x683')](function(){const _0x2a7822=_0xd585cd;_0x56ec56(_0x30e183[_0x2a7822('0xcee')],0x3e8,0x1);})[_0xd585cd('0x683')](function(){const _0x5a2669=_0xd585cd;_0x32c167[_0x5a2669('0x53')]({'title':'Process\x20updated!','msg':_0x5a2669('0x1751')+_0x442e7a});});}function _0x40d775(){const _0x50f00f=_0x289942;return _0x42b8e5[_0x50f00f('0x24f2')][_0x50f00f('0x1e6e')]()['$promise'][_0x50f00f('0x683')](function(_0x5e1592){_0x2e3ca0()['merge'](_0x30e183['system'],_0x5e1592);})[_0x50f00f('0x130a')](_0x30e183[_0x50f00f('0x1d6b')]);}function _0x553a45(){const _0x5dd16e=_0x289942;return _0x42b8e5[_0x5dd16e('0x2c2')][_0x5dd16e('0x1e6e')]()[_0x5dd16e('0xe53')][_0x5dd16e('0x683')](function(_0x54a524){const _0x3fad11=_0x5dd16e;_0x2e3ca0()[_0x3fad11('0xf22')](_0x30e183[_0x3fad11('0x133c')],_0x54a524?_0x54a524[_0x3fad11('0xf5d')]:[]);})[_0x5dd16e('0x130a')](_0x30e183['cancelInterval']);}_0x4860bf=_0x56ec56(_0x30e183[_0x289942('0x4b0')],0x1388),_0x4e4e04[_0x289942('0x26a2')](_0x289942('0x4b8'),function(){const _0x8dc28a=_0x289942;_0x30e183[_0x8dc28a('0x1d6b')]();});}const _0x246b39=_0x589487;_0x1fe7eb[_0x189033('0x14be')]=['$stateProvider'];function _0x1fe7eb(_0x4fdab9){const _0x429e25=_0x189033;_0x4fdab9[_0x429e25('0x2598')](_0x429e25('0xbd3'),{'url':_0x429e25('0x62b'),'views':{'content@app':{'templateUrl':_0x9553f3,'controller':_0x429e25('0x23d7')}},'resolve':{'system':[_0x429e25('0x4b1'),function(_0x462f5d){const _0x5b75af=_0x429e25;return _0x462f5d[_0x5b75af('0xed7')]('system@get');}],'processes':['apiResolver',function(_0x466454){const _0x18c850=_0x429e25;return _0x466454['resolve'](_0x18c850('0x1c30'));}]},'authenticate':!![],'permissionId':0x578,'bodyClass':'settings'});}angular[_0x189033('0x1e26')](_0x189033('0xbd3'),[])[_0x189033('0x272d')](_0x1fe7eb)[_0x189033('0x1da3')](_0x189033('0xfbd'),_0x246b39);const _0x52b26b=_0x180212['p']+'src/js/modules/main/apps/settings/views/updates/updates.html/updates.html';_0x47cb34[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$interval',_0x189033('0x2063'),_0x189033('0x2f9'),_0x189033('0x56b')];function _0x47cb34(_0x30691f,_0x2c8b1f,_0xab44df,_0x3c074e,_0x188ba8){const _0xdc7216=_0x189033,_0x279ba2=this;_0x279ba2[_0xdc7216('0xf28')]='SETTINGS.UPDATE',_0x279ba2[_0xdc7216('0x1e7')]=0x0,_0x279ba2[_0xdc7216('0x2cb')]=!![],_0x279ba2[_0xdc7216('0x2393')]=_0xdc7216('0x1d06'),_0x279ba2['success']=!![],_0x279ba2[_0xdc7216('0x115c')]=_0x2c8b1f(function(){const _0x597121=_0xdc7216;_0x279ba2[_0x597121('0x1e7')]<0x5a&&(_0x279ba2['progress']+=0x1);},0x3e8),_0x188ba8['version'][_0xdc7216('0x745')]()['$promise'][_0xdc7216('0x683')](function(_0x8d338c){const _0x573578=_0xdc7216;return _0x279ba2[_0x573578('0x2393')]=_0x8d338c[_0x573578('0x2393')]+'...',_0x188ba8['version'][_0x573578('0x1302')]()[_0x573578('0xe53')];})[_0xdc7216('0x683')](function(_0x4a7ed8){const _0xa79413=_0xdc7216;return _0x279ba2[_0xa79413('0x2393')]=_0x4a7ed8[_0xa79413('0x2393')]+_0xa79413('0xd67'),_0x188ba8['version']['pull']()[_0xa79413('0xe53')];})[_0xdc7216('0x683')](function(_0x3ab13b){const _0x156b62=_0xdc7216;return _0x279ba2['output']=_0x3ab13b[_0x156b62('0x2393')]+'...',_0x188ba8[_0x156b62('0x729')]['migrations']()['$promise'];})['then'](function(_0x41ce42){const _0x3f1fc5=_0xdc7216;return _0x279ba2['output']=_0x41ce42[_0x3f1fc5('0x2393')]+_0x3f1fc5('0xd67'),_0x188ba8[_0x3f1fc5('0x729')]['restart']()[_0x3f1fc5('0xe53')];})[_0xdc7216('0x683')](function(){const _0x3b00e5=_0xdc7216;_0x279ba2[_0x3b00e5('0x2393')]=_0x3b00e5('0xc18'),_0x3c074e(function(){_0x279ba2['stopInterval']();},0x7530);})[_0xdc7216('0x130a')](function(_0x32530e){const _0x45d825=_0xdc7216;_0x279ba2['success']=![],_0x279ba2[_0x45d825('0x16c4')](),_0x279ba2[_0x45d825('0x2393')]=JSON[_0x45d825('0x258a')](_0x32530e);});function _0xc60491(){const _0x2861ba=_0xdc7216;angular[_0x2861ba('0x127')](_0x279ba2[_0x2861ba('0x115c')])&&(_0x2c8b1f[_0x2861ba('0x19fb')](_0x279ba2[_0x2861ba('0x115c')]),_0x279ba2['interval']=undefined),_0x279ba2[_0x2861ba('0x1e7')]=0x64,_0x279ba2['updating']=![];}function _0x3351f6(){const _0x16e9a3=_0xdc7216;_0xab44df[_0x16e9a3('0x1224')]['reload']();}function _0x58d8db(){const _0x25b042=_0xdc7216;_0x30691f[_0x25b042('0x1715')]();}_0x279ba2[_0xdc7216('0xf82')]=_0x58d8db,_0x279ba2[_0xdc7216('0x40')]=_0x3351f6,_0x279ba2[_0xdc7216('0x16c4')]=_0xc60491;}const _0x2cb53f=_0x47cb34,_0x4bef6a=_0x180212['p']+'src/js/modules/main/apps/settings/views/updates/update/dialog.html/dialog.html';_0x1beac7[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$interval',_0x189033('0x16ea'),_0x189033('0x729')];function _0x1beac7(_0x587bd8,_0x3ea901,_0x5589af,_0x598013){const _0x3b7dcf=_0x189033,_0x562b0b=this;_0x562b0b['version']=_0x598013||{};function _0x160495(_0x7de0fd){const _0x480348=a0_0x4e0a,_0x376693=_0x587bd8[_0x480348('0x1c6f')]()[_0x480348('0xf28')]('Would\x20you\x20like\x20to\x20update\x20your\x20system?')[_0x480348('0x26e3')](_0x480348('0x1c09'))['ariaLabel']('')[_0x480348('0xe42')](_0x7de0fd)[_0x480348('0x188f')](!![])[_0x480348('0x2361')](angular[_0x480348('0x1fcc')](_0x5589af[_0x480348('0x18e5')]))['ok']('I\x20agree')[_0x480348('0x19fb')](_0x480348('0x87e'));_0x587bd8[_0x480348('0x1d4')](_0x376693)[_0x480348('0x683')](function(){const _0x3e0d28=_0x480348;_0x587bd8[_0x3e0d28('0x1d4')]({'controller':'UpdateDialogController','controllerAs':'vm','templateUrl':_0x4bef6a,'parent':angular[_0x3e0d28('0x1fcc')](_0x5589af[_0x3e0d28('0x18e5')]),'targetEvent':_0x7de0fd,'clickOutsideToClose':![]});});}_0x562b0b[_0x3b7dcf('0xa97')]=_0x160495;}const _0x3735aa=_0x1beac7;_0x1b2607['$inject']=[_0x189033('0x1398')];function _0x1b2607(_0x1a7a73){const _0x46a1ce=_0x189033;_0x1a7a73[_0x46a1ce('0x2598')]('app.settings.updates',{'url':'/updates','views':{'content@app':{'templateUrl':_0x52b26b,'controller':_0x46a1ce('0x1829')}},'resolve':{'version':[_0x46a1ce('0x4b1'),function(_0x5a6b2c){const _0x155ce6=_0x46a1ce;return _0x5a6b2c[_0x155ce6('0xed7')](_0x155ce6('0x6f4'),{'latest':!![]});}],'userProfile':['apiResolver','Auth',function(_0x20b254,_0x2f133e){const _0x174eaa=_0x46a1ce;return _0x20b254[_0x174eaa('0xed7')](_0x174eaa('0x1464'),{'fields':_0x174eaa('0x16f'),'id':_0x2f133e[_0x174eaa('0x20b2')]()[_0x174eaa('0x2f')]});}],'userProfileSection':[_0x46a1ce('0x4b1'),_0x46a1ce('0xba1'),function(_0x442ea5,_0x46a022){const _0x317a7f=_0x46a1ce;return _0x442ea5[_0x317a7f('0xed7')]('userProfileSection@get',{'fields':_0x317a7f('0x1f47'),'userProfileId':_0x46a022[_0x317a7f('0x20b2')]()[_0x317a7f('0x2f')],'sectionId':0x578});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':'settings'});}angular['module'](_0x189033('0x8c9'),[])[_0x189033('0x272d')](_0x1b2607)[_0x189033('0x1da3')](_0x189033('0xa2d'),_0x2cb53f)[_0x189033('0x1da3')](_0x189033('0x1e23'),_0x3735aa);const _0x2dfa5f=_0x180212['p']+_0x189033('0x170a'),_0xc831bb=_0x180212['p']+_0x189033('0x49b'),_0x3165c1=_0x180212['p']+_0x189033('0x2611'),_0x8a2652=_0x180212['p']+'src/js/modules/main/apps/settings/views/customizations/customizations.html/customizations.html',_0x24ded9=_0x180212['p']+_0x189033('0x14c5'),_0x3fa18f=_0x180212['p']+_0x189033('0x58b');_0x517a1c[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav','$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),'cloudProviders',_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x517a1c(_0x437bd2,_0x8db466,_0x1ecb35,_0x4b1b67,_0x891592,_0x195383,_0x54e822,_0x50e13e,_0x3f4504,_0x32a40e,_0x2db70c,_0x4318f3,_0x1199bf,_0x572a9b,_0x2f013f){const _0x4c5c2f=_0x189033,_0x570719=this;_0x570719['license']=_0x572a9b,_0x570719[_0x4c5c2f('0x260a')]=_0x2f013f,_0x570719[_0x4c5c2f('0x11ed')]=_0x1199bf[_0x4c5c2f('0x20b2')](),_0x570719[_0x4c5c2f('0x4ed')]=_0x3f4504||{'count':0x0,'rows':[]},_0x570719[_0x4c5c2f('0x5c4')]=_0x4c5c2f('0x4ed'),_0x570719['listOrder']='',_0x570719[_0x4c5c2f('0x1ce2')]=null,_0x570719[_0x4c5c2f('0x4ce')]=[],_0x570719['query']={'fields':'createdAt,updatedAt,id,name,service,data2,data1','sort':_0x4c5c2f('0xc36'),'limit':0xa,'page':0x1},_0x570719['arrayservice']=_0x2e3ca0()[_0x4c5c2f('0x24db')]([{'option':'AmazonAWS','value':_0x4c5c2f('0x1459')}],function(_0x236a26){const _0x371a6b=_0x4c5c2f;return _0x2e3ca0()[_0x371a6b('0x1725')](_0x236a26[_0x371a6b('0x1c6b')],new RegExp('\x27','g'),'');}),_0x570719[_0x4c5c2f('0x1249')]=_0x3f82e9,_0x570719['deleteconfirm']=_0x33dfab,_0x570719['success']=_0x323d20,_0x570719[_0x4c5c2f('0x1c46')]=_0x5e906c,_0x570719[_0x4c5c2f('0x18fc')]=_0x47c0d5,_0x570719['deleteCloudProvider']=_0x2a60f5,_0x570719[_0x4c5c2f('0x430')]=_0x40d100,_0x570719[_0x4c5c2f('0x1994')]=_0x35f1ae,_0x570719[_0x4c5c2f('0x27ce')]=_0x1f03c8,_0x570719['selectAllAiTools']=_0x3fc5f4;function _0x3f82e9(_0x8c3cc0,_0x4070fd){const _0x7e2136=_0x4c5c2f;_0x891592[_0x7e2136('0x1d4')]({'controller':_0x7e2136('0xa39'),'controllerAs':'vm','templateUrl':_0x3fa18f,'parent':angular[_0x7e2136('0x1fcc')](_0x195383[_0x7e2136('0x18e5')]),'targetEvent':_0x4070fd,'clickOutsideToClose':!![],'locals':{'cloudProvider':_0x8c3cc0,'cloudProviders':_0x570719['cloudProviders'][_0x7e2136('0xf5d')],'license':_0x570719[_0x7e2136('0xace')],'setting':null,'crudPermissions':_0x570719[_0x7e2136('0x1134')]}});}function _0x33dfab(_0xee278b,_0x315353){const _0x1ef248=_0x4c5c2f,_0x2346d4=_0x891592[_0x1ef248('0x1c6f')]()['title'](_0x1ef248('0x1b01')+_0x2e3ca0()[_0x1ef248('0x1e03')]('cloudProvider')+'?')[_0x1ef248('0x26e3')](_0x1ef248('0xed5')+(_0xee278b['name']||_0x1ef248('0x44'))+_0x1ef248('0x20f1')+_0x1ef248('0x1ee7'))['ariaLabel'](_0x1ef248('0x256c'))[_0x1ef248('0xe42')](_0x315353)['ok']('OK')['cancel']('CANCEL');_0x891592[_0x1ef248('0x1d4')](_0x2346d4)['then'](function(){_0x2a60f5(_0xee278b);},function(){const _0x1bbe45=_0x1ef248;console[_0x1bbe45('0x1b2b')](_0x1bbe45('0x16b8'));});}let _0x40ba81=!![],_0x4843a4=0x1;_0x437bd2[_0x4c5c2f('0x186d')](_0x4c5c2f('0x1e1d'),function(_0x34189e,_0x1663bd){const _0x54c3e4=_0x4c5c2f;_0x40ba81?_0x54e822(function(){_0x40ba81=![];}):(!_0x1663bd&&(_0x4843a4=_0x570719[_0x54c3e4('0x23a2')][_0x54c3e4('0xdf8')]),_0x34189e!==_0x1663bd&&(_0x570719['query'][_0x54c3e4('0xdf8')]=0x1),!_0x34189e&&(_0x570719[_0x54c3e4('0x23a2')][_0x54c3e4('0xdf8')]=_0x4843a4),_0x570719[_0x54c3e4('0x1c46')]());});function _0x323d20(_0x2c3d5e){const _0x761469=_0x4c5c2f;_0x570719[_0x761469('0x4ed')]=_0x2c3d5e||{'count':0x0,'rows':[]};}function _0x5e906c(){const _0x86ceb8=_0x4c5c2f;_0x570719[_0x86ceb8('0x23a2')][_0x86ceb8('0x1cc8')]=(_0x570719[_0x86ceb8('0x23a2')][_0x86ceb8('0xdf8')]-0x1)*_0x570719[_0x86ceb8('0x23a2')]['limit'],_0x1199bf[_0x86ceb8('0xca1')](_0x86ceb8('0x20c2'))?_0x570719[_0x86ceb8('0x1883')]=_0x32a40e[_0x86ceb8('0x44')][_0x86ceb8('0x1e6e')](_0x570719[_0x86ceb8('0x23a2')],_0x323d20)[_0x86ceb8('0xe53')]:(_0x570719[_0x86ceb8('0x23a2')]['id']=_0x570719[_0x86ceb8('0x2a')]['id'],_0x570719[_0x86ceb8('0x23a2')][_0x86ceb8('0x1aa')]=_0x86ceb8('0x221d'),_0x570719[_0x86ceb8('0x1883')]=_0x32a40e['userProfile'][_0x86ceb8('0x241d')](_0x570719[_0x86ceb8('0x23a2')],_0x323d20)[_0x86ceb8('0xe53')]);}function _0x47c0d5(_0x3e9067,_0x5a105a){const _0x4e9e18=_0x4c5c2f;_0x891592[_0x4e9e18('0x1d4')]({'controller':_0x4e9e18('0xa39'),'controllerAs':'vm','templateUrl':_0x3fa18f,'parent':angular['element'](_0x195383[_0x4e9e18('0x18e5')]),'targetEvent':_0x3e9067,'clickOutsideToClose':!![],'locals':{'cloudProvider':_0x5a105a,'cloudProviders':_0x570719[_0x4e9e18('0x4ed')][_0x4e9e18('0xf5d')],'license':_0x570719['license'],'setting':_0x570719[_0x4e9e18('0x260a')],'crudPermissions':_0x570719['crudPermissions']}});}function _0x2a60f5(_0x239177){const _0x1666d5=_0x4c5c2f;_0x32a40e[_0x1666d5('0x44')][_0x1666d5('0xd7e')]({'id':_0x239177['id']})['$promise'][_0x1666d5('0x683')](function(){const _0x5ee119=_0x1666d5;_0x2e3ca0()[_0x5ee119('0x3ec')](_0x570719[_0x5ee119('0x4ed')][_0x5ee119('0xf5d')],{'id':_0x239177['id']}),_0x570719['cloudProviders']['count']-=0x1,!_0x570719[_0x5ee119('0x4ed')][_0x5ee119('0xf5d')][_0x5ee119('0x1564')]&&_0x570719[_0x5ee119('0x1c46')](),_0x4318f3[_0x5ee119('0x53')]({'title':_0x2e3ca0()[_0x5ee119('0x1e03')](_0x5ee119('0x72f'))+'\x20deleted!','msg':_0x239177[_0x5ee119('0x60a')]?_0x239177[_0x5ee119('0x60a')]+_0x5ee119('0x194d'):''});})[_0x1666d5('0x130a')](function(_0x1d5bd5){const _0x574cfd=_0x1666d5;if(_0x1d5bd5[_0x574cfd('0x5a5')]&&_0x1d5bd5[_0x574cfd('0x5a5')][_0x574cfd('0x17f')]&&_0x1d5bd5[_0x574cfd('0x5a5')]['errors']['length']){_0x570719[_0x574cfd('0x17f')]=_0x1d5bd5[_0x574cfd('0x5a5')][_0x574cfd('0x17f')]||[{'message':_0x1d5bd5['toString'](),'type':_0x574cfd('0xb91')}];for(let _0x3c990c=0x0;_0x3c990c<_0x1d5bd5[_0x574cfd('0x5a5')]['errors'][_0x574cfd('0x1564')];_0x3c990c++){_0x4318f3['error']({'title':_0x1d5bd5[_0x574cfd('0x5a5')][_0x574cfd('0x17f')][_0x3c990c][_0x574cfd('0xcf0')],'msg':_0x1d5bd5['data'][_0x574cfd('0x17f')][_0x3c990c][_0x574cfd('0x8c2')]});}}else _0x4318f3[_0x574cfd('0x52a')]({'title':_0x1d5bd5[_0x574cfd('0x13ee')]?_0x574cfd('0x2168')+_0x1d5bd5[_0x574cfd('0x13ee')]+_0x574cfd('0xbf6')+_0x1d5bd5[_0x574cfd('0x24a9')]:_0x574cfd('0xb91'),'msg':_0x1d5bd5[_0x574cfd('0x5a5')]?JSON['stringify'](_0x1d5bd5[_0x574cfd('0x5a5')][_0x574cfd('0x8c2')]):_0x1d5bd5[_0x574cfd('0x8c2')]||_0x1d5bd5['toString']()});});}function _0x40d100(){const _0x56db17=_0x4c5c2f,_0x2b5aad=angular['copy'](_0x570719[_0x56db17('0x4ce')]);return _0x570719['selectedAiTools']=[],_0x2b5aad;}function _0x35f1ae(_0x3cf845){const _0x3606e1=_0x4c5c2f,_0x23ed44=_0x891592[_0x3606e1('0x1c6f')]()['title'](_0x3606e1('0x385'))[_0x3606e1('0x26e3')](''+_0x570719['selectedAiTools']['length']+_0x3606e1('0x93c')+_0x3606e1('0x1ee7'))['ariaLabel']('delete\x20CloudProviders')['targetEvent'](_0x3cf845)['ok']('OK')['cancel'](_0x3606e1('0x16b8'));_0x891592[_0x3606e1('0x1d4')](_0x23ed44)[_0x3606e1('0x683')](function(){const _0x5d3dbe=_0x3606e1;_0x570719[_0x5d3dbe('0x4ce')][_0x5d3dbe('0x1299')](function(_0x50d6d3){_0x2a60f5(_0x50d6d3);}),_0x570719[_0x5d3dbe('0x4ce')]=[];});}function _0x1f03c8(){const _0x588911=_0x4c5c2f;_0x570719[_0x588911('0x4ce')]=[];}function _0x3fc5f4(){const _0x362021=_0x4c5c2f;_0x570719['selectedAiTools']=_0x570719[_0x362021('0x4ed')][_0x362021('0xf5d')];}}const _0x224e32=_0x517a1c;_0x2c81d8['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x4ed'),_0x189033('0x44'),'api',_0x189033('0xba1'),_0x189033('0xace'),'setting'];function _0x2c81d8(_0x5def66,_0x30750d,_0x453712,_0x4752ab,_0x81282d,_0x1f6d8c,_0x14c14d,_0x47e599,_0x139d5a,_0x55f524,_0x231793,_0x22998b,_0x23de91){const _0x420dab=_0x189033,_0x332861=this;_0x332861[_0x420dab('0x11ed')]=_0x231793[_0x420dab('0x20b2')](),_0x332861[_0x420dab('0x17f')]=[],_0x332861['setting']=_0x23de91,_0x332861[_0x420dab('0xace')]=_0x22998b,_0x332861[_0x420dab('0x258d')]={},_0x332861[_0x420dab('0x19b2')]=_0x332861[_0x420dab('0x260a')]&&_0x332861[_0x420dab('0x260a')][_0x420dab('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x332861[_0x420dab('0xf28')]=_0x420dab('0xe'),_0x332861[_0x420dab('0x44')]=angular[_0x420dab('0x1a86')](_0x139d5a),_0x332861['cloudProviders']=_0x47e599,_0x332861[_0x420dab('0x595')]=![];!_0x332861['cloudProvider']&&(_0x332861[_0x420dab('0x44')]={},_0x332861[_0x420dab('0xf28')]=_0x420dab('0x3f'),_0x332861[_0x420dab('0x595')]=!![]);_0x332861[_0x420dab('0xe63')]=_0x5d358c,_0x332861[_0x420dab('0x2517')]=_0x513748,_0x332861[_0x420dab('0x192f')]=_0x439302,_0x332861[_0x420dab('0x16b3')]=_0x3293fa,_0x332861[_0x420dab('0xf82')]=_0x553ef3;function _0x5d358c(){const _0x378b63=_0x420dab;_0x332861['errors']=[],_0x55f524[_0x378b63('0x44')][_0x378b63('0xb0a')](_0x332861[_0x378b63('0x44')])[_0x378b63('0xe53')]['then'](function(_0x25f9b8){const _0x381afd=_0x378b63;_0x332861[_0x381afd('0x4ed')]['unshift'](_0x25f9b8['toJSON']()),_0x14c14d[_0x381afd('0x53')]({'title':'CloudProvider\x20properly\x20created','msg':_0x332861['cloudProvider'][_0x381afd('0x60a')]?_0x332861[_0x381afd('0x44')][_0x381afd('0x60a')]+_0x381afd('0x14b5'):''}),_0x553ef3(_0x25f9b8);})[_0x378b63('0x130a')](function(_0x12d56d){const _0x355cd1=_0x378b63;if(_0x12d56d[_0x355cd1('0x5a5')]&&_0x12d56d[_0x355cd1('0x5a5')][_0x355cd1('0x17f')]&&_0x12d56d[_0x355cd1('0x5a5')]['errors'][_0x355cd1('0x1564')]){_0x332861[_0x355cd1('0x17f')]=_0x12d56d[_0x355cd1('0x5a5')][_0x355cd1('0x17f')]||[{'message':_0x12d56d[_0x355cd1('0x1ff0')](),'type':_0x355cd1('0x1661')}];for(let _0x4f5bd6=0x0;_0x4f5bd6<_0x12d56d[_0x355cd1('0x5a5')][_0x355cd1('0x17f')]['length'];_0x4f5bd6+=0x1){_0x14c14d['error']({'title':_0x12d56d['data']['errors'][_0x4f5bd6][_0x355cd1('0xcf0')],'msg':_0x12d56d[_0x355cd1('0x5a5')][_0x355cd1('0x17f')][_0x4f5bd6]['message']});}}else _0x14c14d[_0x355cd1('0x52a')]({'title':_0x12d56d['status']?_0x355cd1('0x2168')+_0x12d56d[_0x355cd1('0x13ee')]+'\x20-\x20'+_0x12d56d[_0x355cd1('0x24a9')]:'api.cloudProvider.save','msg':_0x12d56d[_0x355cd1('0x5a5')]?JSON[_0x355cd1('0x258a')](_0x12d56d[_0x355cd1('0x5a5')][_0x355cd1('0x8c2')]):_0x12d56d[_0x355cd1('0x1ff0')]()});});}function _0x513748(){const _0x4abb17=_0x420dab;_0x332861[_0x4abb17('0x17f')]=[],_0x55f524[_0x4abb17('0x44')]['update']({'id':_0x332861[_0x4abb17('0x44')]['id']},_0x332861['cloudProvider'])['$promise']['then'](function(_0x500764){const _0x4fbc99=_0x4abb17,_0x527273=_0x2e3ca0()[_0x4fbc99('0x1c07')](_0x332861[_0x4fbc99('0x4ed')],{'id':_0x500764['id']});_0x527273&&_0x2e3ca0()[_0x4fbc99('0xf22')](_0x527273,_0x2e3ca0()[_0x4fbc99('0x24d0')](_0x500764[_0x4fbc99('0x24e1')](),_0x2e3ca0()[_0x4fbc99('0x55e')](_0x527273))),_0x14c14d[_0x4fbc99('0x53')]({'title':_0x4fbc99('0x128d'),'msg':_0x332861[_0x4fbc99('0x44')][_0x4fbc99('0x60a')]?_0x332861[_0x4fbc99('0x44')][_0x4fbc99('0x60a')]+_0x4fbc99('0xf59'):''}),_0x553ef3(_0x500764);})['catch'](function(_0xb286d9){const _0x3184a2=_0x4abb17;if(_0xb286d9[_0x3184a2('0x5a5')]&&_0xb286d9['data'][_0x3184a2('0x17f')]&&_0xb286d9['data'][_0x3184a2('0x17f')][_0x3184a2('0x1564')]){_0x332861['errors']=_0xb286d9['data']['errors']||[{'message':_0xb286d9[_0x3184a2('0x1ff0')](),'type':'api.cloudProvider.update'}];for(let _0x486575=0x0;_0x486575<_0xb286d9[_0x3184a2('0x5a5')][_0x3184a2('0x17f')]['length'];_0x486575++){_0x14c14d[_0x3184a2('0x52a')]({'title':_0xb286d9[_0x3184a2('0x5a5')][_0x3184a2('0x17f')][_0x486575][_0x3184a2('0xcf0')],'msg':_0xb286d9[_0x3184a2('0x5a5')][_0x3184a2('0x17f')][_0x486575]['message']});}}else _0x14c14d[_0x3184a2('0x52a')]({'title':_0xb286d9[_0x3184a2('0x13ee')]?_0x3184a2('0x2168')+_0xb286d9[_0x3184a2('0x13ee')]+_0x3184a2('0xbf6')+_0xb286d9['statusText']:_0x3184a2('0x16fb'),'msg':_0xb286d9[_0x3184a2('0x5a5')]?JSON[_0x3184a2('0x258a')](_0xb286d9[_0x3184a2('0x5a5')][_0x3184a2('0x8c2')]):_0xb286d9[_0x3184a2('0x1ff0')]()});});}function _0x439302(_0x2173dd){const _0x37d586=_0x420dab;_0x332861[_0x37d586('0x17f')]=[];const _0x5bd0a5=_0x4752ab['confirm']()[_0x37d586('0xf28')]('Are\x20you\x20sure?')['content'](_0x37d586('0x1181'))['ariaLabel'](_0x37d586('0x16b0'))['ok'](_0x37d586('0x2307'))['cancel'](_0x37d586('0x253a'))[_0x37d586('0xe42')](_0x2173dd);_0x4752ab[_0x37d586('0x1d4')](_0x5bd0a5)['then'](function(){const _0x26aee5=_0x37d586;_0x55f524[_0x26aee5('0x44')]['delete']({'id':_0x332861[_0x26aee5('0x44')]['id']})[_0x26aee5('0xe53')][_0x26aee5('0x683')](function(){const _0x247965=_0x26aee5;_0x2e3ca0()['remove'](_0x332861['cloudProviders'],{'id':_0x332861['cloudProvider']['id']}),_0x14c14d['success']({'title':'CloudProvider\x20properly\x20deleted!','msg':(_0x332861[_0x247965('0x44')]['name']||'cloudProvider')+'\x20has\x20been\x20deleted!'}),_0x553ef3(_0x332861[_0x247965('0x44')]);})[_0x26aee5('0x130a')](function(_0x367df4){const _0x2669eb=_0x26aee5;if(_0x367df4[_0x2669eb('0x5a5')]&&_0x367df4[_0x2669eb('0x5a5')][_0x2669eb('0x17f')]&&_0x367df4[_0x2669eb('0x5a5')][_0x2669eb('0x17f')]['length']){_0x332861[_0x2669eb('0x17f')]=_0x367df4[_0x2669eb('0x5a5')]['errors']||[{'message':_0x367df4['toString'](),'type':'api.cloudProvider.delete'}];for(let _0x27e61b=0x0;_0x27e61b<_0x367df4[_0x2669eb('0x5a5')]['errors'][_0x2669eb('0x1564')];_0x27e61b++){_0x14c14d[_0x2669eb('0x52a')]({'title':_0x367df4[_0x2669eb('0x5a5')][_0x2669eb('0x17f')][_0x27e61b]['type'],'msg':_0x367df4[_0x2669eb('0x5a5')]['errors'][_0x27e61b][_0x2669eb('0x8c2')]});}}else _0x14c14d['error']({'title':_0x367df4[_0x2669eb('0x13ee')]?'API:'+_0x367df4['status']+_0x2669eb('0xbf6')+_0x367df4[_0x2669eb('0x24a9')]:_0x2669eb('0x21d7'),'msg':_0x367df4[_0x2669eb('0x5a5')]?JSON['stringify'](_0x367df4['data'][_0x2669eb('0x8c2')]):_0x367df4[_0x2669eb('0x8c2')]||_0x367df4[_0x2669eb('0x1ff0')]()});});},function(){});}function _0x3293fa(_0x137e91){return _0x137e91===null?undefined:new Date(_0x137e91);}function _0x553ef3(_0x535fb6){const _0xfd7ecb=_0x420dab;_0x4752ab[_0xfd7ecb('0x1715')](_0x535fb6);}}const _0x35d446=_0x2c81d8;_0x37fcd4[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),'toasty',_0x189033('0x1a6c'),_0x189033('0x1915'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x37fcd4(_0x503d49,_0xa377fa,_0x44a74c,_0x3ff41b,_0x3598d7,_0x4174ff,_0x401ec7,_0x19623b,_0x4b8b79,_0x51b0f6,_0x59b831,_0x39726b,_0x9aa1ad,_0x1c9e09){const _0x26d2d0=_0x189033,_0x2bd70e=this;_0x2bd70e[_0x26d2d0('0x11ed')]=_0x59b831['getCurrentUser'](),_0x2bd70e[_0x26d2d0('0x17f')]=[],_0x2bd70e[_0x26d2d0('0x260a')]=_0x9aa1ad,_0x2bd70e[_0x26d2d0('0xace')]=_0x39726b,_0x2bd70e[_0x26d2d0('0x1134')]=_0x1c9e09,_0x2bd70e[_0x26d2d0('0x258d')]={},_0x2bd70e[_0x26d2d0('0x19b2')]=_0x2bd70e[_0x26d2d0('0x260a')]&&_0x2bd70e[_0x26d2d0('0x260a')][_0x26d2d0('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2bd70e['title']='SETTINGS.EDIT_CUSTOMIZATION',_0x2bd70e[_0x26d2d0('0x1915')]=angular[_0x26d2d0('0x1a86')](_0x4b8b79),_0x2bd70e[_0x26d2d0('0x1a6c')]=_0x19623b,_0x2bd70e[_0x26d2d0('0x1d47')]=![];!_0x2bd70e[_0x26d2d0('0x1915')]&&(_0x2bd70e[_0x26d2d0('0x1915')]={},_0x2bd70e[_0x26d2d0('0xf28')]=_0x26d2d0('0x26'),_0x2bd70e[_0x26d2d0('0x1d47')]=!![]);_0x2bd70e[_0x26d2d0('0x1554')]=_0x8fbf3d,_0x2bd70e['saveCustomization']=_0x2fa0b,_0x2bd70e['deleteCustomization']=_0x44af91,_0x2bd70e['getDateFromString']=_0x2429f6,_0x2bd70e[_0x26d2d0('0xf82')]=_0xcd101c;function _0x8fbf3d(){const _0x53bc3a=_0x26d2d0;_0x2bd70e['errors']=[],_0x51b0f6[_0x53bc3a('0x260a')][_0x53bc3a('0xb0a')](_0x2bd70e[_0x53bc3a('0x1915')])[_0x53bc3a('0xe53')]['then'](function(_0x44ff9b){const _0x325676=_0x53bc3a;_0x2bd70e[_0x325676('0x1a6c')][_0x325676('0x1167')](_0x44ff9b[_0x325676('0x24e1')]()),_0x401ec7[_0x325676('0x53')]({'title':_0x325676('0x1930'),'msg':_0x2bd70e['customization'][_0x325676('0x60a')]?_0x2bd70e[_0x325676('0x1915')][_0x325676('0x60a')]+_0x325676('0x14b5'):''}),_0xcd101c(_0x44ff9b);})[_0x53bc3a('0x130a')](function(_0x43385a){const _0x2b4148=_0x53bc3a;if(_0x43385a[_0x2b4148('0x5a5')]&&_0x43385a['data']['errors']&&_0x43385a[_0x2b4148('0x5a5')]['errors'][_0x2b4148('0x1564')]){_0x2bd70e['errors']=_0x43385a[_0x2b4148('0x5a5')][_0x2b4148('0x17f')]||[{'message':_0x43385a[_0x2b4148('0x1ff0')](),'type':_0x2b4148('0x22d2')}];for(let _0x52d607=0x0;_0x52d607<_0x43385a[_0x2b4148('0x5a5')][_0x2b4148('0x17f')][_0x2b4148('0x1564')];_0x52d607+=0x1){_0x401ec7[_0x2b4148('0x52a')]({'title':_0x43385a['data']['errors'][_0x52d607]['type'],'msg':_0x43385a[_0x2b4148('0x5a5')][_0x2b4148('0x17f')][_0x52d607][_0x2b4148('0x8c2')]});}}else _0x401ec7['error']({'title':_0x43385a['status']?_0x2b4148('0x2168')+_0x43385a[_0x2b4148('0x13ee')]+_0x2b4148('0xbf6')+_0x43385a['statusText']:'api.setting.save','msg':_0x43385a[_0x2b4148('0x5a5')]?JSON[_0x2b4148('0x258a')](_0x43385a[_0x2b4148('0x5a5')][_0x2b4148('0x8c2')]):_0x43385a[_0x2b4148('0x1ff0')]()});});}function _0x2fa0b(){const _0x578422=_0x26d2d0;_0x2bd70e[_0x578422('0x17f')]=[],_0x51b0f6[_0x578422('0x260a')]['update']({'id':_0x2bd70e[_0x578422('0x1915')]['id']},_0x2bd70e[_0x578422('0x1915')])[_0x578422('0xe53')][_0x578422('0x683')](function(_0x25fef1){const _0x1e1f89=_0x578422,_0x2910c9=_0x2e3ca0()['find'](_0x2bd70e[_0x1e1f89('0x1a6c')],{'id':_0x25fef1['id']});_0x2910c9&&_0x2e3ca0()[_0x1e1f89('0xf22')](_0x2910c9,_0x2e3ca0()[_0x1e1f89('0x24d0')](_0x25fef1[_0x1e1f89('0x24e1')](),_0x2e3ca0()[_0x1e1f89('0x55e')](_0x2910c9))),_0x401ec7[_0x1e1f89('0x53')]({'title':'Customization\x20properly\x20saved!','msg':_0x2bd70e[_0x1e1f89('0x1915')]['name']?_0x2bd70e[_0x1e1f89('0x1915')][_0x1e1f89('0x60a')]+_0x1e1f89('0xf59'):''}),_0xcd101c(_0x25fef1);})['catch'](function(_0x3240cc){const _0x947440=_0x578422;if(_0x3240cc['data']&&_0x3240cc[_0x947440('0x5a5')][_0x947440('0x17f')]&&_0x3240cc[_0x947440('0x5a5')]['errors']['length']){_0x2bd70e[_0x947440('0x17f')]=_0x3240cc[_0x947440('0x5a5')]['errors']||[{'message':_0x3240cc[_0x947440('0x1ff0')](),'type':_0x947440('0x1499')}];for(let _0x2447dc=0x0;_0x2447dc<_0x3240cc[_0x947440('0x5a5')][_0x947440('0x17f')]['length'];_0x2447dc++){_0x401ec7[_0x947440('0x52a')]({'title':_0x3240cc[_0x947440('0x5a5')][_0x947440('0x17f')][_0x2447dc][_0x947440('0xcf0')],'msg':_0x3240cc[_0x947440('0x5a5')][_0x947440('0x17f')][_0x2447dc]['message']});}}else _0x401ec7[_0x947440('0x52a')]({'title':_0x3240cc[_0x947440('0x13ee')]?_0x947440('0x2168')+_0x3240cc[_0x947440('0x13ee')]+_0x947440('0xbf6')+_0x3240cc['statusText']:_0x947440('0x1499'),'msg':_0x3240cc['data']?JSON['stringify'](_0x3240cc['data'][_0x947440('0x8c2')]):_0x3240cc[_0x947440('0x1ff0')]()});});}function _0x44af91(_0x54b536){const _0x15d5c9=_0x26d2d0;_0x2bd70e['errors']=[];const _0x5ac2f7=_0x3ff41b[_0x15d5c9('0x1c6f')]()[_0x15d5c9('0xf28')](_0x15d5c9('0x4d'))[_0x15d5c9('0xa6a')](_0x15d5c9('0x897'))[_0x15d5c9('0x1040')](_0x15d5c9('0x1eea'))['ok'](_0x15d5c9('0x2307'))[_0x15d5c9('0x19fb')](_0x15d5c9('0x253a'))[_0x15d5c9('0xe42')](_0x54b536);_0x3ff41b[_0x15d5c9('0x1d4')](_0x5ac2f7)[_0x15d5c9('0x683')](function(){const _0x213238=_0x15d5c9;_0x51b0f6[_0x213238('0x260a')][_0x213238('0xd7e')]({'id':_0x2bd70e[_0x213238('0x1915')]['id']})['$promise'][_0x213238('0x683')](function(){const _0x227acf=_0x213238;_0x2e3ca0()[_0x227acf('0x3ec')](_0x2bd70e['customizations'],{'id':_0x2bd70e[_0x227acf('0x1915')]['id']}),_0x401ec7[_0x227acf('0x53')]({'title':_0x227acf('0xe68'),'msg':(_0x2bd70e[_0x227acf('0x1915')][_0x227acf('0x60a')]||_0x227acf('0x1915'))+'\x20has\x20been\x20deleted!'}),_0xcd101c(_0x2bd70e[_0x227acf('0x1915')]);})[_0x213238('0x130a')](function(_0x1b9e23){const _0x2a6f46=_0x213238;if(_0x1b9e23[_0x2a6f46('0x5a5')]&&_0x1b9e23[_0x2a6f46('0x5a5')]['errors']&&_0x1b9e23['data'][_0x2a6f46('0x17f')][_0x2a6f46('0x1564')]){_0x2bd70e['errors']=_0x1b9e23[_0x2a6f46('0x5a5')]['errors']||[{'message':_0x1b9e23[_0x2a6f46('0x1ff0')](),'type':_0x2a6f46('0x2830')}];for(let _0x33cac8=0x0;_0x33cac8<_0x1b9e23[_0x2a6f46('0x5a5')][_0x2a6f46('0x17f')]['length'];_0x33cac8++){_0x401ec7['error']({'title':_0x1b9e23[_0x2a6f46('0x5a5')][_0x2a6f46('0x17f')][_0x33cac8][_0x2a6f46('0xcf0')],'msg':_0x1b9e23['data'][_0x2a6f46('0x17f')][_0x33cac8][_0x2a6f46('0x8c2')]});}}else _0x401ec7['error']({'title':_0x1b9e23[_0x2a6f46('0x13ee')]?_0x2a6f46('0x2168')+_0x1b9e23[_0x2a6f46('0x13ee')]+'\x20-\x20'+_0x1b9e23['statusText']:_0x2a6f46('0x2830'),'msg':_0x1b9e23[_0x2a6f46('0x5a5')]?JSON[_0x2a6f46('0x258a')](_0x1b9e23['data'][_0x2a6f46('0x8c2')]):_0x1b9e23[_0x2a6f46('0x8c2')]||_0x1b9e23['toString']()});});},function(){});}function _0x2429f6(_0x54ba86){return _0x54ba86===null?undefined:new Date(_0x54ba86);}function _0xcd101c(_0x542573){const _0xace21e=_0x26d2d0;_0x3ff41b[_0xace21e('0x1715')](_0x542573);}}const _0x54b679=_0x37fcd4;_0x53d00e['$inject']=[_0x189033('0x1a6c'),_0x189033('0x56b'),_0x189033('0x1d70'),'license',_0x189033('0xba1')];function _0x53d00e(_0x482ea2,_0x46c0fe,_0xbbc7db,_0x2b6257,_0x198e76){const _0x3d70e3=_0x189033,_0x50b45a=this;_0x50b45a['currentUser']=_0x198e76[_0x3d70e3('0x20b2')](),_0x50b45a[_0x3d70e3('0xace')]=_0x2b6257,_0x50b45a['customizations']=_0x482ea2,_0x50b45a[_0x3d70e3('0x1915')]={};_0x50b45a[_0x3d70e3('0x1a6c')]&&_0x50b45a[_0x3d70e3('0x1a6c')][_0x3d70e3('0xf5d')]&&_0x50b45a[_0x3d70e3('0x1a6c')][_0x3d70e3('0xf5d')]['length']&&(_0x50b45a[_0x3d70e3('0x1915')]=_0x50b45a[_0x3d70e3('0x1a6c')][_0x3d70e3('0xf5d')][0x0]);_0x50b45a[_0x3d70e3('0x2413')]=_0x31900c;function _0x31900c(){const _0xb42b96=_0x3d70e3;_0x50b45a[_0xb42b96('0x1915')]['id']?_0x46c0fe[_0xb42b96('0x260a')][_0xb42b96('0x2480')]({'id':_0x50b45a[_0xb42b96('0x1915')]['id']},_0x50b45a['customization'])['$promise'][_0xb42b96('0x683')](function(){const _0x346bd2=_0xb42b96;_0xbbc7db['success']({'title':_0x346bd2('0x149a'),'msg':_0x50b45a[_0x346bd2('0x1915')][_0x346bd2('0x60a')]?_0x50b45a['customization']['name']+_0x346bd2('0x96c'):''});})[_0xb42b96('0x130a')](function(_0x48bfaa){const _0x1cf70a=_0xb42b96;_0xbbc7db['error']({'title':_0x48bfaa[_0x1cf70a('0x13ee')]?'API:'+_0x48bfaa[_0x1cf70a('0x13ee')]+_0x1cf70a('0xbf6')+_0x48bfaa[_0x1cf70a('0x24a9')]:_0x1cf70a('0x181'),'msg':_0x48bfaa['data']?JSON[_0x1cf70a('0x258a')](_0x48bfaa[_0x1cf70a('0x5a5')]):_0x48bfaa[_0x1cf70a('0x1ff0')]()});}):_0x46c0fe[_0xb42b96('0x260a')][_0xb42b96('0xb0a')](_0x50b45a[_0xb42b96('0x1915')])['$promise']['then'](function(_0x2d5ab1){const _0x19871c=_0xb42b96;_0x2e3ca0()[_0x19871c('0xf22')](_0x50b45a[_0x19871c('0x1915')],_0x2d5ab1),_0xbbc7db[_0x19871c('0x53')]({'title':_0x19871c('0x149a'),'msg':_0x50b45a['customization'][_0x19871c('0x60a')]?_0x50b45a[_0x19871c('0x1915')]['name']+_0x19871c('0x96c'):''});})[_0xb42b96('0x130a')](function(_0x28d060){const _0x315b1c=_0xb42b96;_0xbbc7db[_0x315b1c('0x52a')]({'title':_0x28d060['status']?_0x315b1c('0x2168')+_0x28d060[_0x315b1c('0x13ee')]+_0x315b1c('0xbf6')+_0x28d060[_0x315b1c('0x24a9')]:_0x315b1c('0x181'),'msg':_0x28d060[_0x315b1c('0x5a5')]?JSON[_0x315b1c('0x258a')](_0x28d060[_0x315b1c('0x5a5')]):_0x28d060['toString']()});});}}const _0x453b05=_0x53d00e;_0x2d6ccd[_0x189033('0x14be')]=[_0x189033('0x17e4'),'toasty'];function _0x2d6ccd(_0x10c7bc,_0x19312f){const _0x542191=_0x189033,_0x415ea0=this,_0x10923b=0x8,_0x530314=_0x10923b*0x400*0x400;_0x415ea0[_0x542191('0x1915')]={},_0x415ea0['ngFlowOptions']={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x530314,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x415ea0['ngFlow']={'flow':{}},_0x415ea0['dropping']=![],_0x415ea0[_0x542191('0x1aad')]=_0x1a4b5e,_0x415ea0['upload']=_0x2ca4c8,_0x415ea0['fileSuccess']=_0x39cc77,_0x415ea0[_0x542191('0x12f3')]=_0x49de2f;function _0x49de2f(_0x42daa4){const _0xa99672=_0x542191;_0x415ea0[_0xa99672('0x1915')]=angular[_0xa99672('0x1a86')](_0x42daa4),_0x415ea0[_0xa99672('0x8f')][_0xa99672('0x568')]=_0xa99672('0x889')[_0xa99672('0x1725')](':id',_0x415ea0[_0xa99672('0x1915')]['id']),_0x415ea0[_0xa99672('0x1915')]['images']=[];}function _0x1a4b5e(_0x287e66){const _0x444ce6=_0x542191,_0x4320e1=[_0x444ce6('0x21ec'),_0x444ce6('0x159c'),_0x444ce6('0x1cee')];if(!_0x2e3ca0()[_0x444ce6('0x2292')](_0x4320e1,_0x287e66['getExtension']()))return _0x19312f[_0x444ce6('0x52a')]({'title':_0x444ce6('0xa00')+_0x287e66['getExtension'](),'msg':_0x444ce6('0x2560')+_0x4320e1[_0x444ce6('0x1630')]()}),![];if(_0x287e66['size']>_0x530314)return _0x19312f[_0x444ce6('0x52a')]({'title':_0x444ce6('0x19a2'),'msg':_0x444ce6('0x1622')+_0x10923b+'MB'}),![];const _0x34e6de={'id':_0x287e66[_0x444ce6('0x2379')],'file':_0x287e66,'type':_0x444ce6('0x132')};return _0x415ea0['customization'][_0x444ce6('0x2668')][_0x444ce6('0x1167')](_0x34e6de),!![];}function _0x2ca4c8(){const _0x118d45=_0x542191;_0x415ea0['ngFlow'][_0x118d45('0x190a')][_0x118d45('0x2810')][_0x118d45('0xb7d')]={'X-Requested-With':_0x118d45('0xbfd'),'Authorization':'Bearer\x20'+_0x10c7bc['get'](_0x118d45('0x555'))},_0x415ea0[_0x118d45('0x1fa6')][_0x118d45('0x190a')]['upload']();}function _0x39cc77(_0x48e50f){const _0x286f65=_0x542191;angular['forEach'](_0x415ea0[_0x286f65('0x1915')][_0x286f65('0x2668')],function(_0x544521){const _0xf8c50e=_0x286f65;if(_0x544521['id']===_0x48e50f['uniqueIdentifier']){const _0x29197f=new FileReader();_0x29197f[_0xf8c50e('0x23e1')](_0x544521[_0xf8c50e('0x21dd')][_0xf8c50e('0x21dd')]),_0x29197f[_0xf8c50e('0x43b')]=function(_0x5a7691){const _0x218b34=_0xf8c50e;_0x544521[_0x218b34('0x1284')]=_0x5a7691[_0x218b34('0x568')][_0x218b34('0x7c9')];},_0x544521[_0xf8c50e('0xcf0')]=_0xf8c50e('0x1110');}});}}const _0xb4996c=_0x2d6ccd;_0x227039[_0x189033('0x14be')]=['$cookies',_0x189033('0x1d70')];function _0x227039(_0x3341b9,_0x545f5f){const _0x2e2d4d=_0x189033,_0x440fee=this,_0x47ac40=0x8,_0x442bc1=_0x47ac40*0x400*0x400;_0x440fee[_0x2e2d4d('0x1915')]={},_0x440fee[_0x2e2d4d('0x8f')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x442bc1,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x440fee[_0x2e2d4d('0x1fa6')]={'flow':{}},_0x440fee[_0x2e2d4d('0xfbe')]=![],_0x440fee['fileAdded']=_0x2cf4b0,_0x440fee[_0x2e2d4d('0xa03')]=_0x29d8cd,_0x440fee[_0x2e2d4d('0x1152')]=_0x3a12a1,_0x440fee[_0x2e2d4d('0x12f3')]=_0x2665b8;function _0x2665b8(_0x4fe30b){const _0x1d3c0a=_0x2e2d4d;_0x440fee[_0x1d3c0a('0x1915')]=angular[_0x1d3c0a('0x1a86')](_0x4fe30b),_0x440fee['ngFlowOptions']['target']='/api/settings/1/logo'['replace'](':id',_0x440fee[_0x1d3c0a('0x1915')]['id']),_0x440fee[_0x1d3c0a('0x1915')]['images']=[];}function _0x2cf4b0(_0x3530b4){const _0x48820c=_0x2e2d4d,_0x49d2ac=[_0x48820c('0x21ec'),_0x48820c('0x159c')];if(!_0x2e3ca0()[_0x48820c('0x2292')](_0x49d2ac,_0x3530b4[_0x48820c('0x1197')]()))return _0x545f5f['error']({'title':'Invalid\x20extension:\x20'+_0x3530b4[_0x48820c('0x1197')](),'msg':_0x48820c('0x2560')+_0x49d2ac[_0x48820c('0x1630')]()}),![];if(_0x3530b4[_0x48820c('0x1a41')]>_0x442bc1)return _0x545f5f[_0x48820c('0x52a')]({'title':_0x48820c('0x19a2'),'msg':_0x48820c('0x1622')+_0x47ac40+'MB'}),![];const _0xc584dc={'id':_0x3530b4['uniqueIdentifier'],'file':_0x3530b4,'type':'uploading'};return _0x440fee[_0x48820c('0x1915')][_0x48820c('0x2668')][_0x48820c('0x1167')](_0xc584dc),!![];}function _0x29d8cd(){const _0x48f743=_0x2e2d4d;_0x440fee[_0x48f743('0x1fa6')]['flow'][_0x48f743('0x2810')][_0x48f743('0xb7d')]={'X-Requested-With':_0x48f743('0xbfd'),'Authorization':_0x48f743('0x189e')+_0x3341b9['get']('motion.token')},_0x440fee[_0x48f743('0x1fa6')][_0x48f743('0x190a')][_0x48f743('0xa03')]();}function _0x3a12a1(_0x23fea2){const _0x3030c9=_0x2e2d4d;angular[_0x3030c9('0x1299')](_0x440fee[_0x3030c9('0x1915')]['images'],function(_0x3904e7){const _0x6f2d7e=_0x3030c9;if(_0x3904e7['id']===_0x23fea2[_0x6f2d7e('0x2379')]){const _0x344daa=new FileReader();_0x344daa[_0x6f2d7e('0x23e1')](_0x3904e7[_0x6f2d7e('0x21dd')]['file']),_0x344daa[_0x6f2d7e('0x43b')]=function(_0x164fb2){const _0xb0cc33=_0x6f2d7e;_0x3904e7[_0xb0cc33('0x1284')]=_0x164fb2[_0xb0cc33('0x568')][_0xb0cc33('0x7c9')];},_0x3904e7[_0x6f2d7e('0xcf0')]=_0x6f2d7e('0x1110');}});}}const _0x469b43=_0x227039;_0x2decb5['$inject']=[_0x189033('0x17e4'),'toasty'];function _0x2decb5(_0xac4c71,_0x6932e3){const _0x4632a2=_0x189033,_0x1f83f7=this,_0x47f650=0x8,_0x327fc5=_0x47f650*0x400*0x400;_0x1f83f7['customization']={},_0x1f83f7[_0x4632a2('0x8f')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x327fc5,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x1f83f7[_0x4632a2('0x1fa6')]={'flow':{}},_0x1f83f7[_0x4632a2('0xfbe')]=![],_0x1f83f7[_0x4632a2('0x1aad')]=_0x6a4bf4,_0x1f83f7['upload']=_0x5d04df,_0x1f83f7[_0x4632a2('0x1152')]=_0x45abfc,_0x1f83f7['init']=_0x30372c;function _0x30372c(_0x5f1987){const _0x15e2ba=_0x4632a2;_0x1f83f7['customization']=angular['copy'](_0x5f1987),_0x1f83f7[_0x15e2ba('0x8f')][_0x15e2ba('0x568')]=_0x15e2ba('0x98e')[_0x15e2ba('0x1725')](_0x15e2ba('0x10f1'),_0x1f83f7[_0x15e2ba('0x1915')]['id']),_0x1f83f7[_0x15e2ba('0x1915')][_0x15e2ba('0x2668')]=[];}function _0x6a4bf4(_0x1ac873){const _0x539885=_0x4632a2,_0xfa9eb2=['png',_0x539885('0x159c')];if(!_0x2e3ca0()[_0x539885('0x2292')](_0xfa9eb2,_0x1ac873[_0x539885('0x1197')]()))return _0x6932e3[_0x539885('0x52a')]({'title':_0x539885('0xa00')+_0x1ac873['getExtension'](),'msg':_0x539885('0x2560')+_0xfa9eb2[_0x539885('0x1630')]()}),![];if(_0x1ac873[_0x539885('0x1a41')]>_0x327fc5)return _0x6932e3[_0x539885('0x52a')]({'title':_0x539885('0x19a2'),'msg':_0x539885('0x1622')+_0x47f650+'MB'}),![];const _0x1cb8c7={'id':_0x1ac873['uniqueIdentifier'],'file':_0x1ac873,'type':_0x539885('0x132')};return _0x1f83f7[_0x539885('0x1915')][_0x539885('0x2668')]['unshift'](_0x1cb8c7),!![];}function _0x5d04df(){const _0x4e6af4=_0x4632a2;_0x1f83f7[_0x4e6af4('0x1fa6')][_0x4e6af4('0x190a')][_0x4e6af4('0x2810')][_0x4e6af4('0xb7d')]={'X-Requested-With':_0x4e6af4('0xbfd'),'Authorization':'Bearer\x20'+_0xac4c71[_0x4e6af4('0x1e6e')](_0x4e6af4('0x555'))},_0x1f83f7[_0x4e6af4('0x1fa6')][_0x4e6af4('0x190a')][_0x4e6af4('0xa03')]();}function _0x45abfc(_0x18b7f3){const _0x3a9516=_0x4632a2;angular[_0x3a9516('0x1299')](_0x1f83f7[_0x3a9516('0x1915')][_0x3a9516('0x2668')],function(_0x397496){const _0x4c419c=_0x3a9516;if(_0x397496['id']===_0x18b7f3[_0x4c419c('0x2379')]){const _0x1f0e47=new FileReader();_0x1f0e47['readAsDataURL'](_0x397496['file'][_0x4c419c('0x21dd')]),_0x1f0e47['onload']=function(_0x2b2eb8){const _0x19b1fe=_0x4c419c;_0x397496[_0x19b1fe('0x1284')]=_0x2b2eb8[_0x19b1fe('0x568')][_0x19b1fe('0x7c9')];},_0x397496[_0x4c419c('0xcf0')]=_0x4c419c('0x1110');}});}}const _0x5883f3=_0x2decb5;_0x1cdbc3['$inject']=[_0x189033('0x17e4'),_0x189033('0x1d70')];function _0x1cdbc3(_0x3feabd,_0x113838){const _0x113cb7=_0x189033,_0x40534d=this,_0x4d2719=0x8,_0x366f17=_0x4d2719*0x400*0x400;_0x40534d[_0x113cb7('0x1915')]={},_0x40534d[_0x113cb7('0x8f')]={'singleFile':!![],'maxChunkRetries':0x1,'chunkSize':_0x366f17,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![]},_0x40534d[_0x113cb7('0x1fa6')]={'flow':{}},_0x40534d[_0x113cb7('0xfbe')]=![],_0x40534d[_0x113cb7('0x1aad')]=_0x16457f,_0x40534d[_0x113cb7('0xa03')]=_0xa59f59,_0x40534d[_0x113cb7('0x1152')]=_0x3f92b6,_0x40534d[_0x113cb7('0x12f3')]=_0x4a3a11;function _0x4a3a11(_0xcf82f1){const _0x1d176c=_0x113cb7;_0x40534d[_0x1d176c('0x1915')]=angular['copy'](_0xcf82f1),_0x40534d[_0x1d176c('0x8f')]['target']=_0x1d176c('0xe3a')[_0x1d176c('0x1725')](_0x1d176c('0x10f1'),_0x40534d[_0x1d176c('0x1915')]['id']),_0x40534d[_0x1d176c('0x1915')]['images']=[];}function _0x16457f(_0x107979){const _0x1bb5cf=_0x113cb7,_0x4bda3f=[_0x1bb5cf('0x21ec'),_0x1bb5cf('0x159c')];if(!_0x2e3ca0()[_0x1bb5cf('0x2292')](_0x4bda3f,_0x107979['getExtension']()))return _0x113838[_0x1bb5cf('0x52a')]({'title':_0x1bb5cf('0xa00')+_0x107979[_0x1bb5cf('0x1197')](),'msg':_0x1bb5cf('0x2560')+_0x4bda3f[_0x1bb5cf('0x1630')]()}),![];if(_0x107979['size']>_0x366f17)return _0x113838[_0x1bb5cf('0x52a')]({'title':_0x1bb5cf('0x19a2'),'msg':_0x1bb5cf('0x1622')+_0x4d2719+'MB'}),![];const _0x17cea7={'id':_0x107979[_0x1bb5cf('0x2379')],'file':_0x107979,'type':'uploading'};return _0x40534d['customization'][_0x1bb5cf('0x2668')]['unshift'](_0x17cea7),!![];}function _0xa59f59(){const _0xbee13=_0x113cb7;_0x40534d[_0xbee13('0x1fa6')][_0xbee13('0x190a')][_0xbee13('0x2810')]['headers']={'X-Requested-With':_0xbee13('0xbfd'),'Authorization':_0xbee13('0x189e')+_0x3feabd['get'](_0xbee13('0x555'))},_0x40534d[_0xbee13('0x1fa6')]['flow'][_0xbee13('0xa03')]();}function _0x3f92b6(_0x377735){const _0x17319e=_0x113cb7;angular[_0x17319e('0x1299')](_0x40534d[_0x17319e('0x1915')][_0x17319e('0x2668')],function(_0x5712ba){const _0x5b3849=_0x17319e;if(_0x5712ba['id']===_0x377735[_0x5b3849('0x2379')]){const _0x46edca=new FileReader();_0x46edca['readAsDataURL'](_0x5712ba['file'][_0x5b3849('0x21dd')]),_0x46edca[_0x5b3849('0x43b')]=function(_0x5a4807){const _0x4e2c49=_0x5b3849;_0x5712ba['url']=_0x5a4807[_0x4e2c49('0x568')][_0x4e2c49('0x7c9')];},_0x5712ba[_0x5b3849('0xcf0')]='image';}});}}const _0x3df174=_0x1cdbc3;_0x2a9275[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),'$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),'generals',_0x189033('0xd6f'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x2a9275(_0x5a5222,_0x2a2c84,_0x316eb5,_0x3963da,_0x8488c1,_0x3c2a98,_0x58b964,_0x5938fd,_0x4955d7,_0x879118,_0x2be6e8,_0x338ac1,_0x8e3c26,_0x86b73b){const _0xd3534d=_0x189033,_0x3a2975=this;_0x3a2975[_0xd3534d('0x11ed')]=_0x2be6e8[_0xd3534d('0x20b2')](),_0x3a2975[_0xd3534d('0x17f')]=[],_0x3a2975[_0xd3534d('0x260a')]=_0x8e3c26,_0x3a2975['license']=_0x338ac1,_0x3a2975[_0xd3534d('0x1134')]=_0x86b73b,_0x3a2975['hasModulePermissions']={},_0x3a2975[_0xd3534d('0x19b2')]=_0x3a2975['setting']&&_0x3a2975[_0xd3534d('0x260a')][_0xd3534d('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3a2975['title']=_0xd3534d('0x57d'),_0x3a2975['general']=angular['copy'](_0x4955d7),_0x3a2975['generals']=_0x5938fd,_0x3a2975[_0xd3534d('0x9b4')]=![];!_0x3a2975['general']&&(_0x3a2975[_0xd3534d('0xd6f')]={'min_internal':0x3e8,'chatTimeout':0x1e,'phoneBarAutoUpdater':!![],'phoneBarAutoUpdaterUrl':_0xd3534d('0x2876'),'splitSizeCsv':0x1388,'splitSizePdf':0x3e8,'splitSizeXlsx':0x1388,'messagesAlignment':_0xd3534d('0xc11'),'phoneBarRememberMeEnabled':!![],'allowedLoginAttempts':0x5,'blockDuration':0xa,'loginMailFrequency':0xa,'enforcePasswordHistory':!![],'passwordHistoryLimit':0x3},_0x3a2975['title']=_0xd3534d('0x6aa'),_0x3a2975[_0xd3534d('0x9b4')]=!![]);_0x3a2975['addNewGeneral']=_0x158339,_0x3a2975[_0xd3534d('0x25d8')]=_0x5486da,_0x3a2975[_0xd3534d('0x14fb')]=_0x48fa3c,_0x3a2975['getDateFromString']=_0x4bc225,_0x3a2975[_0xd3534d('0xf82')]=_0x5a3cbc,_0x879118[_0xd3534d('0x44')][_0xd3534d('0x1e6e')]({'fields':'id,name','sort':_0xd3534d('0x60a'),'nolimit':'true'})['$promise'][_0xd3534d('0x683')](function(_0x39fcbe){const _0x1a41d1=_0xd3534d;_0x3a2975[_0x1a41d1('0x4ed')]=_0x39fcbe[_0x1a41d1('0xf5d')]||[];})[_0xd3534d('0x130a')](function(_0x819788){const _0x294225=_0xd3534d;_0x58b964[_0x294225('0x52a')]({'title':_0x819788[_0x294225('0x13ee')]?'API:'+_0x819788[_0x294225('0x13ee')]+_0x294225('0xbf6')+_0x819788[_0x294225('0x24a9')]:_0x294225('0x228c'),'msg':_0x819788['data']?JSON[_0x294225('0x258a')](_0x819788[_0x294225('0x5a5')]):_0x819788[_0x294225('0x1ff0')]()});});function _0x158339(){const _0x599f09=_0xd3534d;_0x3a2975['errors']=[],_0x879118[_0x599f09('0x260a')][_0x599f09('0xb0a')](_0x3a2975[_0x599f09('0xd6f')])['$promise'][_0x599f09('0x683')](function(_0x175af4){const _0xa49882=_0x599f09;_0x3a2975[_0xa49882('0x8dd')][_0xa49882('0x1167')](_0x175af4[_0xa49882('0x24e1')]()),_0x58b964[_0xa49882('0x53')]({'title':_0xa49882('0x21e3'),'msg':_0x3a2975[_0xa49882('0xd6f')][_0xa49882('0x60a')]?_0x3a2975[_0xa49882('0xd6f')][_0xa49882('0x60a')]+'\x20has\x20been\x20created!':''}),_0x5a3cbc(_0x175af4);})['catch'](function(_0x17061a){const _0x18ea8d=_0x599f09;if(_0x17061a[_0x18ea8d('0x5a5')]&&_0x17061a['data'][_0x18ea8d('0x17f')]&&_0x17061a[_0x18ea8d('0x5a5')][_0x18ea8d('0x17f')]['length']){_0x3a2975[_0x18ea8d('0x17f')]=_0x17061a[_0x18ea8d('0x5a5')]['errors']||[{'message':_0x17061a[_0x18ea8d('0x1ff0')](),'type':_0x18ea8d('0x22d2')}];for(let _0x1df301=0x0;_0x1df301<_0x17061a[_0x18ea8d('0x5a5')]['errors'][_0x18ea8d('0x1564')];_0x1df301+=0x1){_0x58b964[_0x18ea8d('0x52a')]({'title':_0x17061a[_0x18ea8d('0x5a5')][_0x18ea8d('0x17f')][_0x1df301][_0x18ea8d('0xcf0')],'msg':_0x17061a[_0x18ea8d('0x5a5')][_0x18ea8d('0x17f')][_0x1df301][_0x18ea8d('0x8c2')]});}}else _0x58b964[_0x18ea8d('0x52a')]({'title':_0x17061a[_0x18ea8d('0x13ee')]?_0x18ea8d('0x2168')+_0x17061a[_0x18ea8d('0x13ee')]+_0x18ea8d('0xbf6')+_0x17061a[_0x18ea8d('0x24a9')]:_0x18ea8d('0x22d2'),'msg':_0x17061a[_0x18ea8d('0x5a5')]?JSON[_0x18ea8d('0x258a')](_0x17061a['data'][_0x18ea8d('0x8c2')]):_0x17061a[_0x18ea8d('0x1ff0')]()});});}function _0x5486da(){const _0x218399=_0xd3534d;_0x3a2975[_0x218399('0x17f')]=[],_0x879118[_0x218399('0x260a')][_0x218399('0x2480')]({'id':_0x3a2975[_0x218399('0xd6f')]['id']},_0x3a2975[_0x218399('0xd6f')])[_0x218399('0xe53')]['then'](function(_0x42f3d1){const _0x3413d0=_0x218399,_0x108861=_0x2e3ca0()[_0x3413d0('0x1c07')](_0x3a2975['generals'],{'id':_0x42f3d1['id']});_0x108861&&_0x2e3ca0()[_0x3413d0('0xf22')](_0x108861,_0x2e3ca0()[_0x3413d0('0x24d0')](_0x42f3d1['toJSON'](),_0x2e3ca0()['keys'](_0x108861))),_0x58b964[_0x3413d0('0x53')]({'title':_0x3413d0('0xba6'),'msg':_0x3a2975[_0x3413d0('0xd6f')][_0x3413d0('0x60a')]?_0x3a2975[_0x3413d0('0xd6f')]['name']+_0x3413d0('0xf59'):''}),_0x5a3cbc(_0x42f3d1);})[_0x218399('0x130a')](function(_0x23ac41){const _0x667cab=_0x218399;if(_0x23ac41[_0x667cab('0x5a5')]&&_0x23ac41['data'][_0x667cab('0x17f')]&&_0x23ac41[_0x667cab('0x5a5')][_0x667cab('0x17f')]['length']){_0x3a2975[_0x667cab('0x17f')]=_0x23ac41[_0x667cab('0x5a5')][_0x667cab('0x17f')]||[{'message':_0x23ac41[_0x667cab('0x1ff0')](),'type':_0x667cab('0x1499')}];for(let _0x16dab3=0x0;_0x16dab3<_0x23ac41[_0x667cab('0x5a5')][_0x667cab('0x17f')]['length'];_0x16dab3++){_0x58b964[_0x667cab('0x52a')]({'title':_0x23ac41[_0x667cab('0x5a5')][_0x667cab('0x17f')][_0x16dab3][_0x667cab('0xcf0')],'msg':_0x23ac41['data']['errors'][_0x16dab3][_0x667cab('0x8c2')]});}}else _0x58b964[_0x667cab('0x52a')]({'title':_0x23ac41[_0x667cab('0x13ee')]?_0x667cab('0x2168')+_0x23ac41['status']+_0x667cab('0xbf6')+_0x23ac41['statusText']:_0x667cab('0x1499'),'msg':_0x23ac41[_0x667cab('0x5a5')]?JSON['stringify'](_0x23ac41['data'][_0x667cab('0x8c2')]):_0x23ac41[_0x667cab('0x1ff0')]()});});}function _0x48fa3c(_0x43d35b){const _0x14d4b9=_0xd3534d;_0x3a2975[_0x14d4b9('0x17f')]=[];const _0x1efbc6=_0x3963da[_0x14d4b9('0x1c6f')]()[_0x14d4b9('0xf28')](_0x14d4b9('0x4d'))[_0x14d4b9('0xa6a')](_0x14d4b9('0x959'))[_0x14d4b9('0x1040')](_0x14d4b9('0x1ea8'))['ok'](_0x14d4b9('0x2307'))[_0x14d4b9('0x19fb')](_0x14d4b9('0x253a'))[_0x14d4b9('0xe42')](_0x43d35b);_0x3963da['show'](_0x1efbc6)[_0x14d4b9('0x683')](function(){const _0x2a3953=_0x14d4b9;_0x879118[_0x2a3953('0x260a')][_0x2a3953('0xd7e')]({'id':_0x3a2975[_0x2a3953('0xd6f')]['id']})[_0x2a3953('0xe53')][_0x2a3953('0x683')](function(){const _0x30e948=_0x2a3953;_0x2e3ca0()['remove'](_0x3a2975[_0x30e948('0x8dd')],{'id':_0x3a2975[_0x30e948('0xd6f')]['id']}),_0x58b964[_0x30e948('0x53')]({'title':'General\x20properly\x20deleted!','msg':(_0x3a2975[_0x30e948('0xd6f')]['name']||'general')+_0x30e948('0x194d')}),_0x5a3cbc(_0x3a2975[_0x30e948('0xd6f')]);})['catch'](function(_0x8dbd58){const _0x59b642=_0x2a3953;if(_0x8dbd58[_0x59b642('0x5a5')]&&_0x8dbd58['data'][_0x59b642('0x17f')]&&_0x8dbd58['data'][_0x59b642('0x17f')][_0x59b642('0x1564')]){_0x3a2975['errors']=_0x8dbd58[_0x59b642('0x5a5')][_0x59b642('0x17f')]||[{'message':_0x8dbd58[_0x59b642('0x1ff0')](),'type':_0x59b642('0x2830')}];for(let _0x8f54db=0x0;_0x8f54db<_0x8dbd58['data'][_0x59b642('0x17f')]['length'];_0x8f54db++){_0x58b964[_0x59b642('0x52a')]({'title':_0x8dbd58[_0x59b642('0x5a5')][_0x59b642('0x17f')][_0x8f54db]['type'],'msg':_0x8dbd58[_0x59b642('0x5a5')][_0x59b642('0x17f')][_0x8f54db]['message']});}}else _0x58b964[_0x59b642('0x52a')]({'title':_0x8dbd58[_0x59b642('0x13ee')]?'API:'+_0x8dbd58[_0x59b642('0x13ee')]+_0x59b642('0xbf6')+_0x8dbd58[_0x59b642('0x24a9')]:'api.setting.delete','msg':_0x8dbd58[_0x59b642('0x5a5')]?JSON[_0x59b642('0x258a')](_0x8dbd58['data'][_0x59b642('0x8c2')]):_0x8dbd58[_0x59b642('0x8c2')]||_0x8dbd58[_0x59b642('0x1ff0')]()});});},function(){});}function _0x4bc225(_0x1e3f14){return _0x1e3f14===null?undefined:new Date(_0x1e3f14);}function _0x5a3cbc(_0x8e3a8c){const _0x381620=_0xd3534d;_0x3963da[_0x381620('0x1715')](_0x8e3a8c);}}const _0x11a393=_0x2a9275;_0x231578[_0x189033('0x14be')]=[_0x189033('0x8dd'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xace'),_0x189033('0xba1')];function _0x231578(_0x9f596a,_0x1bbb99,_0x179fec,_0x5cdff4,_0xfd1fbc){const _0x512e79=_0x189033,_0x47ddd0=this;_0x47ddd0[_0x512e79('0x11ed')]=_0xfd1fbc[_0x512e79('0x20b2')](),_0x47ddd0[_0x512e79('0xace')]=_0x5cdff4,_0x47ddd0['generals']=_0x9f596a,_0x47ddd0[_0x512e79('0xd6f')]={};_0x47ddd0[_0x512e79('0x8dd')]&&_0x47ddd0[_0x512e79('0x8dd')][_0x512e79('0xf5d')]&&_0x47ddd0['generals']['rows'][_0x512e79('0x1564')]&&(_0x47ddd0[_0x512e79('0xd6f')]=_0x47ddd0[_0x512e79('0x8dd')][_0x512e79('0xf5d')][0x0]);_0x1bbb99['cloudProvider'][_0x512e79('0x1e6e')]({'fields':'id,name','sort':_0x512e79('0x60a'),'nolimit':'true'})[_0x512e79('0xe53')][_0x512e79('0x683')](function(_0xd1be31){const _0x463b7=_0x512e79;_0x47ddd0[_0x463b7('0x4ed')]=_0xd1be31[_0x463b7('0xf5d')]||[];})['catch'](function(_0x5b9ae2){const _0x1a5f1a=_0x512e79;_0x179fec[_0x1a5f1a('0x52a')]({'title':_0x5b9ae2[_0x1a5f1a('0x13ee')]?_0x1a5f1a('0x2168')+_0x5b9ae2['status']+_0x1a5f1a('0xbf6')+_0x5b9ae2[_0x1a5f1a('0x24a9')]:_0x1a5f1a('0x228c'),'msg':_0x5b9ae2['data']?JSON['stringify'](_0x5b9ae2[_0x1a5f1a('0x5a5')]):_0x5b9ae2[_0x1a5f1a('0x1ff0')]()});}),_0x47ddd0[_0x512e79('0x25d8')]=_0x57d1cd;function _0x57d1cd(){const _0x1be3f7=_0x512e79;_0x47ddd0['general']['id']?_0x1bbb99[_0x1be3f7('0x260a')][_0x1be3f7('0x2480')]({'id':_0x47ddd0['general']['id']},_0x47ddd0[_0x1be3f7('0xd6f')])[_0x1be3f7('0xe53')][_0x1be3f7('0x683')](function(){const _0x2e5b56=_0x1be3f7;_0x179fec['success']({'title':'General\x20updated!','msg':_0x47ddd0[_0x2e5b56('0xd6f')]['name']?_0x47ddd0[_0x2e5b56('0xd6f')]['name']+'\x20has\x20been\x20updated!':''});})[_0x1be3f7('0x130a')](function(_0x3d1826){const _0x1336e2=_0x1be3f7;_0x179fec['error']({'title':_0x3d1826['status']?'API:'+_0x3d1826[_0x1336e2('0x13ee')]+_0x1336e2('0xbf6')+_0x3d1826[_0x1336e2('0x24a9')]:'SYSTEM:GETsetting','msg':_0x3d1826[_0x1336e2('0x5a5')]?JSON[_0x1336e2('0x258a')](_0x3d1826[_0x1336e2('0x5a5')]):_0x3d1826[_0x1336e2('0x1ff0')]()});}):_0x1bbb99[_0x1be3f7('0x260a')]['save'](_0x47ddd0[_0x1be3f7('0xd6f')])['$promise'][_0x1be3f7('0x683')](function(_0x284f4c){const _0xdaf436=_0x1be3f7;_0x2e3ca0()['merge'](_0x47ddd0[_0xdaf436('0xd6f')],_0x284f4c),_0x179fec[_0xdaf436('0x53')]({'title':_0xdaf436('0x2170'),'msg':_0x47ddd0[_0xdaf436('0xd6f')][_0xdaf436('0x60a')]?_0x47ddd0['general'][_0xdaf436('0x60a')]+_0xdaf436('0x96c'):''});})[_0x1be3f7('0x130a')](function(_0x4c81eb){const _0x1299f4=_0x1be3f7;_0x179fec[_0x1299f4('0x52a')]({'title':_0x4c81eb[_0x1299f4('0x13ee')]?_0x1299f4('0x2168')+_0x4c81eb['status']+_0x1299f4('0xbf6')+_0x4c81eb[_0x1299f4('0x24a9')]:_0x1299f4('0x181'),'msg':_0x4c81eb['data']?JSON[_0x1299f4('0x258a')](_0x4c81eb[_0x1299f4('0x5a5')]):_0x4c81eb['toString']()});});}}const _0x1a7634=_0x231578;_0x2b8ebe[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state',_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x9d9'),_0x189033('0x18f6'),'api','Auth','license',_0x189033('0x260a')];function _0x2b8ebe(_0x549ad6,_0x338621,_0x25a275,_0x12db72,_0x317c83,_0x172ec5,_0x1ba382,_0x1a1458,_0x119b84,_0x1d7ccd,_0x2a352d,_0x151ea7,_0x87f5f5){const _0x5d92b3=_0x189033,_0x258912=this;_0x258912[_0x5d92b3('0x11ed')]=_0x2a352d['getCurrentUser'](),_0x258912[_0x5d92b3('0x17f')]=[],_0x258912['setting']=_0x87f5f5,_0x258912[_0x5d92b3('0xace')]=_0x151ea7,_0x258912[_0x5d92b3('0x258d')]={},_0x258912[_0x5d92b3('0x19b2')]=_0x258912[_0x5d92b3('0x260a')]&&_0x258912[_0x5d92b3('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x258912[_0x5d92b3('0xf28')]='SETTINGS.EDIT_NETWORK',_0x258912[_0x5d92b3('0x18f6')]=angular[_0x5d92b3('0x1a86')](_0x119b84),_0x258912[_0x5d92b3('0x9d9')]=_0x1a1458,_0x258912[_0x5d92b3('0x153f')]=![];!_0x258912['network']&&(_0x258912[_0x5d92b3('0x18f6')]={'type':_0x5d92b3('0x24a5')},_0x258912[_0x5d92b3('0xf28')]=_0x5d92b3('0xbc3'),_0x258912['newNetwork']=!![]);_0x258912['addNewNetwork']=_0x4865aa,_0x258912[_0x5d92b3('0x1f38')]=_0x27adaa,_0x258912[_0x5d92b3('0x1b15')]=_0x5b0638,_0x258912[_0x5d92b3('0x16b3')]=_0x5ae7b4,_0x258912[_0x5d92b3('0xf82')]=_0x1f8022;function _0x4865aa(){const _0x44639b=_0x5d92b3;_0x258912[_0x44639b('0x17f')]=[],_0x1d7ccd[_0x44639b('0x18f6')][_0x44639b('0xb0a')](_0x258912['network'])[_0x44639b('0xe53')][_0x44639b('0x683')](function(_0x1544e7){const _0x162eb7=_0x44639b;_0x258912[_0x162eb7('0x9d9')]['unshift'](_0x1544e7[_0x162eb7('0x24e1')]()),_0x1ba382[_0x162eb7('0x53')]({'title':_0x162eb7('0x11bd'),'msg':_0x258912['network'][_0x162eb7('0x60a')]?_0x258912[_0x162eb7('0x18f6')][_0x162eb7('0x60a')]+_0x162eb7('0x14b5'):''}),_0x1f8022(_0x1544e7);})['catch'](function(_0x6b797){const _0x15a6b0=_0x44639b;if(_0x6b797[_0x15a6b0('0x5a5')]&&_0x6b797[_0x15a6b0('0x5a5')][_0x15a6b0('0x17f')]&&_0x6b797[_0x15a6b0('0x5a5')]['errors'][_0x15a6b0('0x1564')]){_0x258912[_0x15a6b0('0x17f')]=_0x6b797[_0x15a6b0('0x5a5')][_0x15a6b0('0x17f')]||[{'message':_0x6b797[_0x15a6b0('0x1ff0')](),'type':_0x15a6b0('0x206b')}];for(let _0x412a0c=0x0;_0x412a0c<_0x6b797['data'][_0x15a6b0('0x17f')]['length'];_0x412a0c+=0x1){_0x1ba382[_0x15a6b0('0x52a')]({'title':_0x6b797[_0x15a6b0('0x5a5')]['errors'][_0x412a0c][_0x15a6b0('0xcf0')],'msg':_0x6b797[_0x15a6b0('0x5a5')][_0x15a6b0('0x17f')][_0x412a0c][_0x15a6b0('0x8c2')]});}}else _0x1ba382[_0x15a6b0('0x52a')]({'title':_0x6b797[_0x15a6b0('0x13ee')]?_0x15a6b0('0x2168')+_0x6b797['status']+_0x15a6b0('0xbf6')+_0x6b797[_0x15a6b0('0x24a9')]:_0x15a6b0('0x206b'),'msg':_0x6b797[_0x15a6b0('0x5a5')]?JSON['stringify'](_0x6b797[_0x15a6b0('0x5a5')]['message']):_0x6b797['toString']()});});}function _0x27adaa(){const _0x5a19ba=_0x5d92b3;_0x258912[_0x5a19ba('0x17f')]=[],_0x1d7ccd['network'][_0x5a19ba('0x2480')]({'id':_0x258912[_0x5a19ba('0x18f6')]['id']},_0x258912[_0x5a19ba('0x18f6')])[_0x5a19ba('0xe53')]['then'](function(_0x1bc7cc){const _0x1cc3f8=_0x5a19ba,_0x23be72=_0x2e3ca0()[_0x1cc3f8('0x1c07')](_0x258912[_0x1cc3f8('0x9d9')],{'id':_0x1bc7cc['id']});_0x23be72&&_0x2e3ca0()['merge'](_0x23be72,_0x2e3ca0()['pick'](_0x1bc7cc[_0x1cc3f8('0x24e1')](),_0x2e3ca0()[_0x1cc3f8('0x55e')](_0x23be72))),_0x1ba382[_0x1cc3f8('0x53')]({'title':_0x1cc3f8('0x2316'),'msg':_0x258912[_0x1cc3f8('0x18f6')][_0x1cc3f8('0x60a')]?_0x258912[_0x1cc3f8('0x18f6')][_0x1cc3f8('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x1f8022(_0x1bc7cc);})[_0x5a19ba('0x130a')](function(_0x308e4f){const _0x2969ec=_0x5a19ba;if(_0x308e4f[_0x2969ec('0x5a5')]&&_0x308e4f['data'][_0x2969ec('0x17f')]&&_0x308e4f[_0x2969ec('0x5a5')]['errors']['length']){_0x258912[_0x2969ec('0x17f')]=_0x308e4f['data'][_0x2969ec('0x17f')]||[{'message':_0x308e4f[_0x2969ec('0x1ff0')](),'type':_0x2969ec('0x274d')}];for(let _0xbaab61=0x0;_0xbaab61<_0x308e4f[_0x2969ec('0x5a5')]['errors'][_0x2969ec('0x1564')];_0xbaab61++){_0x1ba382[_0x2969ec('0x52a')]({'title':_0x308e4f['data'][_0x2969ec('0x17f')][_0xbaab61][_0x2969ec('0xcf0')],'msg':_0x308e4f[_0x2969ec('0x5a5')][_0x2969ec('0x17f')][_0xbaab61][_0x2969ec('0x8c2')]});}}else _0x1ba382[_0x2969ec('0x52a')]({'title':_0x308e4f[_0x2969ec('0x13ee')]?_0x2969ec('0x2168')+_0x308e4f[_0x2969ec('0x13ee')]+_0x2969ec('0xbf6')+_0x308e4f[_0x2969ec('0x24a9')]:_0x2969ec('0x274d'),'msg':_0x308e4f['data']?JSON['stringify'](_0x308e4f[_0x2969ec('0x5a5')][_0x2969ec('0x8c2')]):_0x308e4f[_0x2969ec('0x1ff0')]()});});}function _0x5b0638(_0x334ea5){const _0x563fc9=_0x5d92b3;_0x258912[_0x563fc9('0x17f')]=[];const _0x581ca4=_0x12db72['confirm']()['title'](_0x563fc9('0x4d'))['content'](_0x563fc9('0x1e02'))[_0x563fc9('0x1040')]('Delete\x20Network')['ok']('Delete')[_0x563fc9('0x19fb')](_0x563fc9('0x253a'))[_0x563fc9('0xe42')](_0x334ea5);_0x12db72['show'](_0x581ca4)[_0x563fc9('0x683')](function(){const _0x234b0d=_0x563fc9;_0x1d7ccd[_0x234b0d('0x18f6')][_0x234b0d('0xd7e')]({'id':_0x258912[_0x234b0d('0x18f6')]['id']})[_0x234b0d('0xe53')][_0x234b0d('0x683')](function(){const _0x344204=_0x234b0d;_0x2e3ca0()[_0x344204('0x3ec')](_0x258912[_0x344204('0x9d9')],{'id':_0x258912[_0x344204('0x18f6')]['id']}),_0x1ba382[_0x344204('0x53')]({'title':'Network\x20properly\x20deleted!','msg':(_0x258912[_0x344204('0x18f6')][_0x344204('0x60a')]||_0x344204('0x18f6'))+_0x344204('0x194d')}),_0x1f8022(_0x258912['network']);})[_0x234b0d('0x130a')](function(_0x2682b7){const _0xfa86ac=_0x234b0d;if(_0x2682b7[_0xfa86ac('0x5a5')]&&_0x2682b7[_0xfa86ac('0x5a5')][_0xfa86ac('0x17f')]&&_0x2682b7[_0xfa86ac('0x5a5')][_0xfa86ac('0x17f')][_0xfa86ac('0x1564')]){_0x258912['errors']=_0x2682b7['data']['errors']||[{'message':_0x2682b7['toString'](),'type':_0xfa86ac('0x1847')}];for(let _0x2bb94b=0x0;_0x2bb94b<_0x2682b7['data']['errors'][_0xfa86ac('0x1564')];_0x2bb94b++){_0x1ba382[_0xfa86ac('0x52a')]({'title':_0x2682b7['data'][_0xfa86ac('0x17f')][_0x2bb94b][_0xfa86ac('0xcf0')],'msg':_0x2682b7[_0xfa86ac('0x5a5')][_0xfa86ac('0x17f')][_0x2bb94b][_0xfa86ac('0x8c2')]});}}else _0x1ba382[_0xfa86ac('0x52a')]({'title':_0x2682b7['status']?'API:'+_0x2682b7['status']+_0xfa86ac('0xbf6')+_0x2682b7[_0xfa86ac('0x24a9')]:_0xfa86ac('0x1847'),'msg':_0x2682b7['data']?JSON[_0xfa86ac('0x258a')](_0x2682b7[_0xfa86ac('0x5a5')]['message']):_0x2682b7['message']||_0x2682b7['toString']()});});},function(){});}function _0x5ae7b4(_0x5897f7){return _0x5897f7===null?undefined:new Date(_0x5897f7);}function _0x1f8022(_0x486554){const _0x544f96=_0x5d92b3;_0x12db72[_0x544f96('0x1715')](_0x486554);}}const _0x45c212=_0x2b8ebe,_0x3ce21c=_0x180212['p']+'src/js/modules/main/apps/settings/views/networks/create/dialog.html/dialog.html';_0x4d8ca1[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x9d9'),_0x189033('0x56b'),_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x4d8ca1(_0x365087,_0x194a55,_0x4de648,_0x522087,_0x1b10c3,_0x37ed44,_0x4db5cc,_0x1f28e7,_0x3fd739,_0x5b67c7,_0x5198b3,_0x394e56,_0x52e484,_0x3d1ba1,_0x42d295){const _0x2dcc98=_0x189033,_0x447bd8=this;_0x447bd8[_0x2dcc98('0xace')]=_0x3d1ba1,_0x447bd8[_0x2dcc98('0x260a')]=_0x42d295,_0x447bd8[_0x2dcc98('0x11ed')]=_0x52e484[_0x2dcc98('0x20b2')](),_0x447bd8[_0x2dcc98('0x9d9')]=_0x3fd739||{'count':0x0,'rows':[]},_0x447bd8[_0x2dcc98('0x5c4')]=_0x2dcc98('0x9d9'),_0x447bd8[_0x2dcc98('0x247')]='',_0x447bd8[_0x2dcc98('0x1ce2')]=null,_0x447bd8['selectedNetworks']=[],_0x447bd8[_0x2dcc98('0x23a2')]={'fields':_0x2dcc98('0x11f2'),'sort':_0x2dcc98('0xc36'),'limit':0xa,'page':0x1},_0x447bd8[_0x2dcc98('0x10b7')]=_0x2e3ca0()[_0x2dcc98('0x24db')]([{'option':_0x2dcc98('0x322'),'value':'\x27localnet\x27'},{'option':_0x2dcc98('0x1eb7'),'value':_0x2dcc98('0xaec')},{'option':_0x2dcc98('0x962'),'value':_0x2dcc98('0x92c')},{'option':_0x2dcc98('0x24ce'),'value':_0x2dcc98('0x1ec7')}],function(_0x2f1960){const _0x250e13=_0x2dcc98;return _0x2e3ca0()[_0x250e13('0x1725')](_0x2f1960[_0x250e13('0x1c6b')],new RegExp('\x27','g'),'');}),_0x447bd8[_0x2dcc98('0x1249')]=_0x428d18,_0x447bd8[_0x2dcc98('0x194f')]=_0x26ec5b,_0x447bd8[_0x2dcc98('0x53')]=_0x24bd23,_0x447bd8[_0x2dcc98('0x23ce')]=_0x5b853f,_0x447bd8[_0x2dcc98('0x704')]=_0x2d6d11,_0x447bd8['deleteNetwork']=_0x477a23,_0x447bd8[_0x2dcc98('0x14e7')]=_0x579bc0,_0x447bd8['deleteSelectedNetworks']=_0x2d49b0,_0x447bd8['deselectNetworks']=_0x74784a,_0x447bd8[_0x2dcc98('0xc89')]=_0x152c10;function _0x428d18(_0x2c13e9,_0x522b4e){const _0x4b4308=_0x2dcc98;_0x1b10c3[_0x4b4308('0x1d4')]({'controller':_0x4b4308('0x20a5'),'controllerAs':'vm','templateUrl':_0x3ce21c,'parent':angular[_0x4b4308('0x1fcc')](_0x37ed44[_0x4b4308('0x18e5')]),'targetEvent':_0x522b4e,'clickOutsideToClose':!![],'locals':{'network':_0x2c13e9,'networks':_0x447bd8['networks'][_0x4b4308('0xf5d')],'license':_0x447bd8[_0x4b4308('0xace')],'setting':null,'crudPermissions':_0x447bd8[_0x4b4308('0x1134')]}});}function _0x26ec5b(_0x4f17ae,_0x59afd1){const _0x218b86=_0x2dcc98,_0xc46be6=_0x1b10c3[_0x218b86('0x1c6f')]()[_0x218b86('0xf28')](_0x218b86('0x1b01')+_0x2e3ca0()[_0x218b86('0x1e03')](_0x218b86('0x18f6'))+'?')['htmlContent'](_0x218b86('0xed5')+(_0x4f17ae[_0x218b86('0x60a')]||_0x218b86('0x18f6'))+_0x218b86('0x20f1')+_0x218b86('0x1ee7'))[_0x218b86('0x1040')]('delete\x20network')['targetEvent'](_0x59afd1)['ok']('OK')[_0x218b86('0x19fb')](_0x218b86('0x16b8'));_0x1b10c3[_0x218b86('0x1d4')](_0xc46be6)[_0x218b86('0x683')](function(){_0x477a23(_0x4f17ae);},function(){const _0x39a24b=_0x218b86;console[_0x39a24b('0x1b2b')](_0x39a24b('0x16b8'));});}let _0x2747f7=!![],_0x125256=0x1;_0x365087[_0x2dcc98('0x186d')](_0x2dcc98('0x1e1d'),function(_0x532399,_0x1a96e9){const _0x4f8ad0=_0x2dcc98;_0x2747f7?_0x4db5cc(function(){_0x2747f7=![];}):(!_0x1a96e9&&(_0x125256=_0x447bd8['query']['page']),_0x532399!==_0x1a96e9&&(_0x447bd8['query'][_0x4f8ad0('0xdf8')]=0x1),!_0x532399&&(_0x447bd8[_0x4f8ad0('0x23a2')][_0x4f8ad0('0xdf8')]=_0x125256),_0x447bd8[_0x4f8ad0('0x23ce')]());});function _0x24bd23(_0x25ebd9){const _0x536915=_0x2dcc98;_0x447bd8[_0x536915('0x9d9')]=_0x25ebd9||{'count':0x0,'rows':[]};}function _0x5b853f(){const _0x4751dc=_0x2dcc98;_0x447bd8[_0x4751dc('0x23a2')][_0x4751dc('0x1cc8')]=(_0x447bd8[_0x4751dc('0x23a2')][_0x4751dc('0xdf8')]-0x1)*_0x447bd8[_0x4751dc('0x23a2')]['limit'],_0x52e484[_0x4751dc('0xca1')](_0x4751dc('0x20c2'))?_0x447bd8[_0x4751dc('0x1883')]=_0x5b67c7['network']['get'](_0x447bd8[_0x4751dc('0x23a2')],_0x24bd23)['$promise']:(_0x447bd8[_0x4751dc('0x23a2')]['id']=_0x447bd8[_0x4751dc('0x2a')]['id'],_0x447bd8[_0x4751dc('0x23a2')][_0x4751dc('0x1aa')]='Networks',_0x447bd8['promise']=_0x5b67c7[_0x4751dc('0x2a')]['getResources'](_0x447bd8[_0x4751dc('0x23a2')],_0x24bd23)[_0x4751dc('0xe53')]);}function _0x2d6d11(_0x1a505e,_0x176900){const _0x421ae4=_0x2dcc98;_0x1b10c3[_0x421ae4('0x1d4')]({'controller':'CreateOrEditNetworkDialogController','controllerAs':'vm','templateUrl':_0x3ce21c,'parent':angular['element'](_0x37ed44[_0x421ae4('0x18e5')]),'targetEvent':_0x1a505e,'clickOutsideToClose':!![],'locals':{'network':_0x176900,'networks':_0x447bd8[_0x421ae4('0x9d9')][_0x421ae4('0xf5d')],'license':_0x447bd8['license'],'setting':_0x447bd8[_0x421ae4('0x260a')],'crudPermissions':_0x447bd8['crudPermissions']}});}function _0x477a23(_0x2fc313){const _0x4010ff=_0x2dcc98;_0x5b67c7[_0x4010ff('0x18f6')][_0x4010ff('0xd7e')]({'id':_0x2fc313['id']})['$promise'][_0x4010ff('0x683')](function(){const _0x59e594=_0x4010ff;_0x2e3ca0()[_0x59e594('0x3ec')](_0x447bd8[_0x59e594('0x9d9')]['rows'],{'id':_0x2fc313['id']}),_0x447bd8['networks'][_0x59e594('0x50d')]-=0x1,!_0x447bd8[_0x59e594('0x9d9')]['rows'][_0x59e594('0x1564')]&&_0x447bd8[_0x59e594('0x23ce')](),_0x394e56[_0x59e594('0x53')]({'title':_0x2e3ca0()[_0x59e594('0x1e03')](_0x59e594('0xdd7'))+_0x59e594('0xbfc'),'msg':_0x2fc313['name']?_0x2fc313[_0x59e594('0x60a')]+_0x59e594('0x194d'):''});})['catch'](function(_0x12d1b5){const _0x35eef8=_0x4010ff;if(_0x12d1b5['data']&&_0x12d1b5[_0x35eef8('0x5a5')]['errors']&&_0x12d1b5[_0x35eef8('0x5a5')][_0x35eef8('0x17f')][_0x35eef8('0x1564')]){_0x447bd8[_0x35eef8('0x17f')]=_0x12d1b5[_0x35eef8('0x5a5')]['errors']||[{'message':_0x12d1b5['toString'](),'type':'SYSTEM:DELETEnetwork'}];for(let _0x42f01e=0x0;_0x42f01e<_0x12d1b5[_0x35eef8('0x5a5')]['errors'][_0x35eef8('0x1564')];_0x42f01e++){_0x394e56['error']({'title':_0x12d1b5['data'][_0x35eef8('0x17f')][_0x42f01e][_0x35eef8('0xcf0')],'msg':_0x12d1b5[_0x35eef8('0x5a5')][_0x35eef8('0x17f')][_0x42f01e][_0x35eef8('0x8c2')]});}}else _0x394e56[_0x35eef8('0x52a')]({'title':_0x12d1b5['status']?_0x35eef8('0x2168')+_0x12d1b5[_0x35eef8('0x13ee')]+_0x35eef8('0xbf6')+_0x12d1b5[_0x35eef8('0x24a9')]:_0x35eef8('0xfdb'),'msg':_0x12d1b5['data']?JSON[_0x35eef8('0x258a')](_0x12d1b5['data']['message']):_0x12d1b5[_0x35eef8('0x8c2')]||_0x12d1b5['toString']()});});}function _0x579bc0(){const _0x1bb5d5=_0x2dcc98,_0x1d487c=angular[_0x1bb5d5('0x1a86')](_0x447bd8[_0x1bb5d5('0x1bd2')]);return _0x447bd8[_0x1bb5d5('0x1bd2')]=[],_0x1d487c;}function _0x2d49b0(_0x58afff){const _0x317132=_0x2dcc98,_0x7e0126=_0x1b10c3[_0x317132('0x1c6f')]()[_0x317132('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20networks?')['htmlContent'](_0x317132('0xed5')+_0x447bd8[_0x317132('0x1bd2')]['length']+_0x317132('0x93c')+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x317132('0x2731'))[_0x317132('0xe42')](_0x58afff)['ok']('OK')[_0x317132('0x19fb')](_0x317132('0x16b8'));_0x1b10c3[_0x317132('0x1d4')](_0x7e0126)['then'](function(){const _0x530962=_0x317132;_0x447bd8[_0x530962('0x1bd2')][_0x530962('0x1299')](function(_0x5d9dc8){_0x477a23(_0x5d9dc8);}),_0x447bd8[_0x530962('0x1bd2')]=[];});}function _0x74784a(){const _0x438446=_0x2dcc98;_0x447bd8[_0x438446('0x1bd2')]=[];}function _0x152c10(){const _0x34c00d=_0x2dcc98;_0x447bd8[_0x34c00d('0x1bd2')]=_0x447bd8['networks'][_0x34c00d('0xf5d')];}}const _0x3c3cda=_0x4d8ca1;_0x276029[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$q','$translate',_0x189033('0x1d70'),_0x189033('0x2646'),_0x189033('0x22e8'),_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x276029(_0x24c383,_0x2ba309,_0x31e42a,_0x3e7455,_0x4f9a4d,_0x55e723,_0xf13b6b,_0x38c661,_0x813555,_0x3d0331,_0x15519f,_0x915fcc,_0x53b677,_0x3f815e){const _0x2a77e3=_0x189033,_0x42549a=this;_0x42549a[_0x2a77e3('0x11ed')]=_0x15519f[_0x2a77e3('0x20b2')](),_0x42549a['errors']=[],_0x42549a[_0x2a77e3('0x260a')]=_0x53b677,_0x42549a['license']=_0x915fcc,_0x42549a[_0x2a77e3('0x1134')]=_0x3f815e,_0x42549a[_0x2a77e3('0x258d')]={},_0x42549a[_0x2a77e3('0x19b2')]=_0x42549a[_0x2a77e3('0x260a')]&&_0x42549a[_0x2a77e3('0x260a')][_0x2a77e3('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x42549a[_0x2a77e3('0xf28')]='SETTINGS.EDIT_SMTP',_0x42549a[_0x2a77e3('0x22e8')]=angular[_0x2a77e3('0x1a86')](_0x813555),_0x42549a[_0x2a77e3('0x2646')]=_0x38c661,_0x42549a[_0x2a77e3('0x16e')]=![];!_0x42549a[_0x2a77e3('0x22e8')]&&(_0x42549a[_0x2a77e3('0x22e8')]={'service':!![]},_0x42549a[_0x2a77e3('0xf28')]=_0x2a77e3('0x15f9'),_0x42549a[_0x2a77e3('0x16e')]=!![]);_0x42549a[_0x2a77e3('0x18ed')]=_0x41e176,_0x42549a['saveSmtp']=_0x4836e9,_0x42549a[_0x2a77e3('0xbca')]=_0x460f35,_0x42549a[_0x2a77e3('0x16b3')]=_0x555da5,_0x42549a[_0x2a77e3('0xf82')]=_0x4e4539;function _0x41e176(){const _0x20e5ef=_0x2a77e3;_0x42549a[_0x20e5ef('0x17f')]=[],_0x3d0331[_0x20e5ef('0xb87')][_0x20e5ef('0xb0a')](_0x42549a[_0x20e5ef('0x22e8')])[_0x20e5ef('0xe53')][_0x20e5ef('0x683')](function(_0x2564cc){const _0x40d405=_0x20e5ef;_0x42549a['smtps'][_0x40d405('0x1167')](_0x2564cc['toJSON']()),_0xf13b6b[_0x40d405('0x53')]({'title':_0x40d405('0x1971'),'msg':_0x42549a['smtp'][_0x40d405('0x60a')]?_0x42549a[_0x40d405('0x22e8')][_0x40d405('0x60a')]+_0x40d405('0x14b5'):''}),_0x4e4539(_0x2564cc);})[_0x20e5ef('0x130a')](function(_0x55908b){const _0x4386e4=_0x20e5ef;if(_0x55908b['data']&&_0x55908b[_0x4386e4('0x5a5')]['errors']&&_0x55908b['data'][_0x4386e4('0x17f')][_0x4386e4('0x1564')]){_0x42549a[_0x4386e4('0x17f')]=_0x55908b[_0x4386e4('0x5a5')][_0x4386e4('0x17f')]||[{'message':_0x55908b[_0x4386e4('0x1ff0')](),'type':_0x4386e4('0x2350')}];for(let _0x3a786b=0x0;_0x3a786b<_0x55908b[_0x4386e4('0x5a5')][_0x4386e4('0x17f')]['length'];_0x3a786b+=0x1){_0xf13b6b[_0x4386e4('0x52a')]({'title':_0x55908b['data']['errors'][_0x3a786b][_0x4386e4('0xcf0')],'msg':_0x55908b['data'][_0x4386e4('0x17f')][_0x3a786b][_0x4386e4('0x8c2')]});}}else _0xf13b6b[_0x4386e4('0x52a')]({'title':_0x55908b[_0x4386e4('0x13ee')]?_0x4386e4('0x2168')+_0x55908b[_0x4386e4('0x13ee')]+'\x20-\x20'+_0x55908b[_0x4386e4('0x24a9')]:_0x4386e4('0x2350'),'msg':_0x55908b[_0x4386e4('0x5a5')]?JSON[_0x4386e4('0x258a')](_0x55908b[_0x4386e4('0x5a5')][_0x4386e4('0x8c2')]):_0x55908b[_0x4386e4('0x1ff0')]()});});}function _0x4836e9(){const _0x203805=_0x2a77e3;_0x42549a['errors']=[],_0x3d0331[_0x203805('0xb87')]['update']({'id':_0x42549a[_0x203805('0x22e8')]['id']},_0x42549a['smtp'])[_0x203805('0xe53')][_0x203805('0x683')](function(_0x6d0eaf){const _0x1ea610=_0x203805,_0x18171b=_0x2e3ca0()[_0x1ea610('0x1c07')](_0x42549a[_0x1ea610('0x2646')],{'id':_0x6d0eaf['id']});_0x18171b&&_0x2e3ca0()['merge'](_0x18171b,_0x2e3ca0()['pick'](_0x6d0eaf['toJSON'](),_0x2e3ca0()[_0x1ea610('0x55e')](_0x18171b))),_0xf13b6b[_0x1ea610('0x53')]({'title':_0x1ea610('0x243f'),'msg':_0x42549a[_0x1ea610('0x22e8')][_0x1ea610('0x60a')]?_0x42549a[_0x1ea610('0x22e8')][_0x1ea610('0x60a')]+_0x1ea610('0xf59'):''}),_0x4e4539(_0x6d0eaf);})[_0x203805('0x130a')](function(_0x3f409d){const _0x5808cc=_0x203805;if(_0x3f409d[_0x5808cc('0x5a5')]&&_0x3f409d[_0x5808cc('0x5a5')][_0x5808cc('0x17f')]&&_0x3f409d['data'][_0x5808cc('0x17f')][_0x5808cc('0x1564')]){_0x42549a[_0x5808cc('0x17f')]=_0x3f409d[_0x5808cc('0x5a5')]['errors']||[{'message':_0x3f409d[_0x5808cc('0x1ff0')](),'type':_0x5808cc('0x1afc')}];for(let _0x399384=0x0;_0x399384<_0x3f409d[_0x5808cc('0x5a5')][_0x5808cc('0x17f')][_0x5808cc('0x1564')];_0x399384++){_0xf13b6b[_0x5808cc('0x52a')]({'title':_0x3f409d[_0x5808cc('0x5a5')][_0x5808cc('0x17f')][_0x399384]['type'],'msg':_0x3f409d[_0x5808cc('0x5a5')][_0x5808cc('0x17f')][_0x399384][_0x5808cc('0x8c2')]});}}else _0xf13b6b[_0x5808cc('0x52a')]({'title':_0x3f409d['status']?'API:'+_0x3f409d['status']+'\x20-\x20'+_0x3f409d['statusText']:_0x5808cc('0x1afc'),'msg':_0x3f409d['data']?JSON[_0x5808cc('0x258a')](_0x3f409d[_0x5808cc('0x5a5')][_0x5808cc('0x8c2')]):_0x3f409d[_0x5808cc('0x1ff0')]()});});}function _0x460f35(_0x49736c){const _0x24aecb=_0x2a77e3;_0x42549a[_0x24aecb('0x17f')]=[];const _0x195e72=_0x3e7455['confirm']()[_0x24aecb('0xf28')](_0x24aecb('0x4d'))['content'](_0x24aecb('0x5c0'))[_0x24aecb('0x1040')](_0x24aecb('0x21b6'))['ok'](_0x24aecb('0x2307'))['cancel'](_0x24aecb('0x253a'))[_0x24aecb('0xe42')](_0x49736c);_0x3e7455[_0x24aecb('0x1d4')](_0x195e72)[_0x24aecb('0x683')](function(){const _0x3d904a=_0x24aecb;_0x3d0331['mailAccount'][_0x3d904a('0xd7e')]({'id':_0x42549a[_0x3d904a('0x22e8')]['id']})['$promise'][_0x3d904a('0x683')](function(){const _0x18b706=_0x3d904a;_0x2e3ca0()['remove'](_0x42549a[_0x18b706('0x2646')],{'id':_0x42549a[_0x18b706('0x22e8')]['id']}),_0xf13b6b[_0x18b706('0x53')]({'title':_0x18b706('0x26d5'),'msg':(_0x42549a[_0x18b706('0x22e8')][_0x18b706('0x60a')]||_0x18b706('0x22e8'))+_0x18b706('0x194d')}),_0x4e4539(_0x42549a['smtp']);})['catch'](function(_0x84db29){const _0x3e1f47=_0x3d904a;if(_0x84db29[_0x3e1f47('0x5a5')]&&_0x84db29[_0x3e1f47('0x5a5')][_0x3e1f47('0x17f')]&&_0x84db29[_0x3e1f47('0x5a5')][_0x3e1f47('0x17f')][_0x3e1f47('0x1564')]){_0x42549a[_0x3e1f47('0x17f')]=_0x84db29['data'][_0x3e1f47('0x17f')]||[{'message':_0x84db29[_0x3e1f47('0x1ff0')](),'type':_0x3e1f47('0xd23')}];for(let _0x3c0024=0x0;_0x3c0024<_0x84db29[_0x3e1f47('0x5a5')]['errors'][_0x3e1f47('0x1564')];_0x3c0024++){_0xf13b6b[_0x3e1f47('0x52a')]({'title':_0x84db29[_0x3e1f47('0x5a5')]['errors'][_0x3c0024][_0x3e1f47('0xcf0')],'msg':_0x84db29[_0x3e1f47('0x5a5')][_0x3e1f47('0x17f')][_0x3c0024][_0x3e1f47('0x8c2')]});}}else _0xf13b6b[_0x3e1f47('0x52a')]({'title':_0x84db29[_0x3e1f47('0x13ee')]?_0x3e1f47('0x2168')+_0x84db29[_0x3e1f47('0x13ee')]+_0x3e1f47('0xbf6')+_0x84db29[_0x3e1f47('0x24a9')]:_0x3e1f47('0xd23'),'msg':_0x84db29[_0x3e1f47('0x5a5')]?JSON[_0x3e1f47('0x258a')](_0x84db29[_0x3e1f47('0x5a5')][_0x3e1f47('0x8c2')]):_0x84db29[_0x3e1f47('0x8c2')]||_0x84db29[_0x3e1f47('0x1ff0')]()});});},function(){});}function _0x555da5(_0x4e9b2c){return _0x4e9b2c===null?undefined:new Date(_0x4e9b2c);}function _0x4e4539(_0x3d6c5f){const _0x37dd91=_0x2a77e3;_0x3e7455[_0x37dd91('0x1715')](_0x3d6c5f);}}const _0x5be670=_0x276029;_0x17f7af['$inject']=[_0x189033('0x2646'),'api',_0x189033('0x1d70'),'license',_0x189033('0xba1')];function _0x17f7af(_0x5b00dc,_0x93e5c7,_0x63532b,_0x2cd6b8,_0x1c6464){const _0x4756f1=_0x189033,_0x47c148=this;_0x47c148[_0x4756f1('0x11ed')]=_0x1c6464['getCurrentUser'](),_0x47c148[_0x4756f1('0xace')]=_0x2cd6b8,_0x47c148[_0x4756f1('0x2646')]=_0x5b00dc,_0x47c148[_0x4756f1('0x22e8')]={};_0x47c148[_0x4756f1('0x2646')]&&_0x47c148['smtps'][_0x4756f1('0xf5d')]&&_0x47c148[_0x4756f1('0x2646')][_0x4756f1('0xf5d')][_0x4756f1('0x1564')]?_0x47c148[_0x4756f1('0x22e8')]=_0x47c148[_0x4756f1('0x2646')][_0x4756f1('0xf5d')][0x0]:_0x47c148[_0x4756f1('0x22e8')]={'service':!![],'Smtp':{'service':null}};_0x47c148[_0x4756f1('0xb7a')]=_0x9d77ee,_0x47c148['verifySmtp']=_0x335f8f;function _0x335f8f(){const _0x952717=_0x4756f1;_0x47c148['smtp']['id']&&_0x93e5c7[_0x952717('0xb87')][_0x952717('0x2751')]({'id':_0x47c148[_0x952717('0x22e8')]['id']})['$promise'][_0x952717('0x683')](function(){const _0xd5e07=_0x952717;_0x63532b[_0xd5e07('0x53')]({'title':_0xd5e07('0xc9e'),'msg':_0x47c148[_0xd5e07('0x22e8')][_0xd5e07('0x60a')]?_0x47c148[_0xd5e07('0x22e8')][_0xd5e07('0x60a')]+'\x20has\x20been\x20verified!':''});})[_0x952717('0x130a')](function(_0x3119bd){const _0x2017af=_0x952717;_0x63532b[_0x2017af('0x52a')]({'title':'Smtp\x20not\x20verified!\x20Remember\x20to\x20save\x20before\x20to\x20verify!','msg':_0x3119bd['data']?JSON[_0x2017af('0x258a')](_0x3119bd[_0x2017af('0x5a5')]):_0x3119bd[_0x2017af('0x1ff0')](),'timeout':0x2710});});}function _0x9d77ee(){const _0x5d34f7=_0x4756f1;_0x47c148['smtp']['id']?_0x93e5c7[_0x5d34f7('0xb87')]['update']({'id':_0x47c148[_0x5d34f7('0x22e8')]['id']},_0x47c148['smtp'])[_0x5d34f7('0xe53')]['then'](function(){const _0x4300bd=_0x5d34f7;_0x63532b[_0x4300bd('0x53')]({'title':_0x4300bd('0x14c6'),'msg':_0x47c148[_0x4300bd('0x22e8')]['name']?_0x47c148[_0x4300bd('0x22e8')][_0x4300bd('0x60a')]+_0x4300bd('0x96c'):''});})['catch'](function(_0x35b2c6){const _0x8aa7ff=_0x5d34f7;_0x63532b[_0x8aa7ff('0x52a')]({'title':_0x35b2c6[_0x8aa7ff('0x13ee')]?_0x8aa7ff('0x2168')+_0x35b2c6[_0x8aa7ff('0x13ee')]+_0x8aa7ff('0xbf6')+_0x35b2c6['statusText']:_0x8aa7ff('0x160e'),'msg':_0x35b2c6[_0x8aa7ff('0x5a5')]?JSON['stringify'](_0x35b2c6[_0x8aa7ff('0x5a5')]):_0x35b2c6['toString']()});}):_0x93e5c7[_0x5d34f7('0xb87')][_0x5d34f7('0xb0a')](_0x47c148[_0x5d34f7('0x22e8')])[_0x5d34f7('0xe53')][_0x5d34f7('0x683')](function(_0x17ad0c){const _0x3b647e=_0x5d34f7;_0x2e3ca0()[_0x3b647e('0xf22')](_0x47c148[_0x3b647e('0x22e8')],_0x17ad0c),_0x63532b['success']({'title':_0x3b647e('0x14c6'),'msg':_0x47c148['smtp']['name']?_0x47c148[_0x3b647e('0x22e8')]['name']+_0x3b647e('0x96c'):''});})['catch'](function(_0x4d73e8){const _0x2298ea=_0x5d34f7;_0x63532b['error']({'title':_0x4d73e8[_0x2298ea('0x13ee')]?_0x2298ea('0x2168')+_0x4d73e8[_0x2298ea('0x13ee')]+'\x20-\x20'+_0x4d73e8[_0x2298ea('0x24a9')]:'SYSTEM:GETmailAccount','msg':_0x4d73e8[_0x2298ea('0x5a5')]?JSON[_0x2298ea('0x258a')](_0x4d73e8['data']):_0x4d73e8[_0x2298ea('0x1ff0')]()});});}}const _0x4fbff7=_0x17f7af;_0x1a6ec5['$inject']=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x1a6ec5(_0x36b32f,_0x29546d){const _0x3ee023=_0x189033;_0x36b32f[_0x3ee023('0x2598')](_0x3ee023('0x1ae'),{'abstract':!![],'url':_0x3ee023('0x1cfd')})[_0x3ee023('0x2598')](_0x3ee023('0xcc4'),{'url':_0x3ee023('0x267c'),'views':{'content@app':{'templateUrl':_0x2dfa5f,'controller':_0x3ee023('0x1977')}},'resolve':{'generals':['apiResolver',function(_0x3e6b6){const _0xdabd30=_0x3ee023;return _0x3e6b6[_0xdabd30('0xed7')](_0xdabd30('0x271'),{'fields':_0xdabd30('0xbac'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':'settings'})[_0x3ee023('0x2598')](_0x3ee023('0x2d6'),{'url':_0x3ee023('0x251c'),'views':{'content@app':{'templateUrl':_0xc831bb,'controller':_0x3ee023('0x1f01')}},'resolve':{'smtps':[_0x3ee023('0x4b1'),function(_0x508337){const _0x3c1234=_0x3ee023;return _0x508337[_0x3c1234('0xed7')]('mailAccount@get',{'fields':_0x3c1234('0x26db'),'service':'1','limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':_0x3ee023('0x5c3')})[_0x3ee023('0x2598')](_0x3ee023('0x835'),{'url':_0x3ee023('0x1a36'),'views':{'content@app':{'templateUrl':_0x3165c1,'controller':'NetworksController\x20as\x20vm'}},'resolve':{'networks':[_0x3ee023('0x4b1'),function(_0xf11d38){const _0x307862=_0x3ee023;return _0xf11d38['resolve'](_0x307862('0x17b6'),{'fields':_0x307862('0x11f2'),'sort':_0x307862('0xc36'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':_0x3ee023('0x5c3')})[_0x3ee023('0x2598')](_0x3ee023('0x9a0'),{'url':'/customizations','views':{'content@app':{'templateUrl':_0x8a2652,'controller':'CustomizationsController\x20as\x20vm'}},'resolve':{'customizations':[_0x3ee023('0x4b1'),function(_0x47489c){const _0x42f2eb=_0x3ee023;return _0x47489c[_0x42f2eb('0xed7')](_0x42f2eb('0x271'),{'fields':_0x42f2eb('0x857'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':_0x3ee023('0x5c3')})[_0x3ee023('0x2598')](_0x3ee023('0x6c8'),{'url':_0x3ee023('0x7bd'),'views':{'content@app':{'templateUrl':_0x24ded9,'controller':_0x3ee023('0x165e')}},'resolve':{'cloudProviders':[_0x3ee023('0x4b1'),function(_0x1f8327){const _0x400abf=_0x3ee023;return _0x1f8327['resolve']('cloudProvider@get',{'fields':_0x400abf('0x8ba'),'sort':_0x400abf('0xc36'),'limit':0xa,'offset':0x0});}]},'authenticate':!![],'permissionId':0x578,'bodyClass':_0x3ee023('0x5c3')}),_0x29546d['addPart'](_0x3ee023('0xcc8'));}angular[_0x189033('0x1e26')](_0x189033('0x1ae'),[_0x189033('0x6cf'),_0x189033('0x1ddb'),_0x189033('0x2290'),'flow',_0x189033('0x25fc'),_0x189033('0x2835'),'ng-sortable',_0x189033('0x2609'),'ngAnimate','mdPickers',_0x189033('0x516'),'mwFormViewer',_0x189033('0x197b'),_0x189033('0x3b5'),'angular-cron-jobs',_0x189033('0x1447'),_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da'),'app.settings.updates',_0x189033('0x2024'),'app.settings.system'])[_0x189033('0x272d')](_0x1a6ec5)[_0x189033('0x1da3')]('CloudProvidersController',_0x224e32)['controller'](_0x189033('0xa39'),_0x35d446)[_0x189033('0x1da3')](_0x189033('0x9b1'),_0x54b679)[_0x189033('0x1da3')](_0x189033('0x182d'),_0x453b05)[_0x189033('0x1da3')]('CustomizationfaviconController',_0xb4996c)[_0x189033('0x1da3')]('CustomizationlogoController',_0x469b43)[_0x189033('0x1da3')](_0x189033('0x131d'),_0x5883f3)[_0x189033('0x1da3')](_0x189033('0xda7'),_0x3df174)[_0x189033('0x1da3')]('CreateOrEditGeneralDialogController',_0x11a393)[_0x189033('0x1da3')](_0x189033('0x2739'),_0x1a7634)[_0x189033('0x1da3')](_0x189033('0x20a5'),_0x45c212)[_0x189033('0x1da3')](_0x189033('0x16cc'),_0x3c3cda)['controller'](_0x189033('0x1f7'),_0x5be670)[_0x189033('0x1da3')](_0x189033('0xc01'),_0x4fbff7);const _0x4b83f6=_0x180212['p']+_0x189033('0x17af'),_0x233760=_0x180212['p']+_0x189033('0x12da'),_0xc6997f=_0x180212['p']+_0x189033('0x456'),_0x27e1ab=_0x180212['p']+_0x189033('0x2e6'),_0x59b9a2=_0x180212['p']+'src/js/modules/main/apps/motiondialer/views/realtime/abandonedcalls/view.html/view.html',_0x396a9c=_0x180212['p']+_0x189033('0x48f'),_0x59ae3c=_0x180212['p']+_0x189033('0x7e0'),_0x578fc1=_0x180212['p']+'src/js/modules/main/apps/dashboards/views/general/agent/home/abandoned/dispose/dialog.html/dialog.html';_0x3d736b['$inject']=[_0x189033('0x7a5'),'$timeout',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2063'),'$translate',_0x189033('0x56b'),'userProfile',_0x189033('0x22df'),_0x189033('0xba1'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0x756'),_0x189033('0x191e')];function _0x3d736b(_0x6e5adf,_0x3c5b68,_0x4953e0,_0x35d456,_0x2afad4,_0x48b8ff,_0xc7cb78,_0x262523,_0x198b1a,_0x578f04,_0x4fa5bc,_0x4dad9c,_0x3a3e5a,_0x357e68){const _0x56da67=_0x189033,_0x5af2aa=this;_0x5af2aa[_0x56da67('0x11ed')]=_0x578f04[_0x56da67('0x20b2')](),_0x5af2aa[_0x56da67('0x756')]=_0x3a3e5a?_0x3a3e5a:[],_0x5af2aa['dispositions']=_0x357e68,_0x5af2aa[_0x56da67('0x37b')]={'count':0x0,'rows':[]},_0x5af2aa[_0x56da67('0x12c2')]=![],_0x5af2aa['refresh']=!![],_0x5af2aa[_0x56da67('0x2a')]=_0x262523,_0x5af2aa[_0x56da67('0x22df')]=_0x198b1a&&_0x198b1a[_0x56da67('0x50d')]==0x1?_0x198b1a[_0x56da67('0xf5d')][0x0]:null,_0x5af2aa[_0x56da67('0x1134')]=_0x578f04[_0x56da67('0x142a')](_0x5af2aa[_0x56da67('0x22df')]?_0x5af2aa[_0x56da67('0x22df')][_0x56da67('0x1134')]:null),_0x5af2aa[_0x56da67('0x23a2')]={'fields':_0x56da67('0xa3c'),'type':'outbound','queuecallerexitreason':_0x56da67('0x498')+','+'ABANDONED','sort':_0x56da67('0xc36'),'limit':0xa,'page':0x1},_0x5af2aa['getAbandonedCalls']=_0x5d75f9,_0x5af2aa[_0x56da67('0x1897')]=_0x49b128,_0x5af2aa[_0x56da67('0xaf5')]=_0x5b2219,_0x5af2aa[_0x56da67('0x1160')]=_0x42f345,_0x5af2aa['onSaveVoiceQueueReport']=_0x3199c1,_0x5af2aa[_0x56da67('0x2754')]=_0x2c2521,_0x4fa5bc[_0x56da67('0x5a3')]('voiceQueueReport:save',_0x5af2aa['onSaveVoiceQueueReport']),_0x4fa5bc['on'](_0x56da67('0x2660'),_0x5af2aa[_0x56da67('0x2754')]),_0x259b1c();function _0x259b1c(){const _0x3099af=_0x56da67;let _0x137bed=_0x2afad4[_0x3099af('0x120e')][_0x3099af('0x1b28')](_0x3099af('0x2365')+_0x5af2aa[_0x3099af('0x11ed')]['id']);if(_0x137bed)_0x137bed=JSON[_0x3099af('0x1f34')](_0x137bed),_0x137bed&&_0x137bed['query']&&(_0x5af2aa[_0x3099af('0x23a2')]=_0x2e3ca0()[_0x3099af('0xf22')](_0x137bed['query'],_0x2e3ca0()[_0x3099af('0x8b5')](_0x5af2aa[_0x3099af('0x23a2')],[_0x3099af('0x671'),_0x3099af('0x6f0'),_0x3099af('0xdf8')])),_0x5af2aa['query']=_0x2e3ca0()[_0x3099af('0x8b5')](_0x5af2aa['query'],_0x3099af('0x25')));else{const _0x2a66e7={'$gte':_0x1aaf93()()[_0x3099af('0x1627')](_0x3099af('0x55b'))[_0x3099af('0xb11')](0x0,!![])[_0x3099af('0x26dd')](),'$lte':_0x1aaf93()()[_0x3099af('0x3b3')]('month')[_0x3099af('0xb11')](0x0,!![])[_0x3099af('0x26dd')]()};_0x5af2aa[_0x3099af('0x23a2')][_0x3099af('0x1a4')]=_0x2a66e7;}_0x578f04[_0x3099af('0xca1')](_0x3099af('0x20c2'))?_0xc7cb78[_0x3099af('0xc96')][_0x3099af('0x4c9')]({'id':_0x578f04['getCurrentUser']()['id'],'fields':_0x3099af('0xa10'),'channel':_0x3099af('0xcf2'),'type':_0x3099af('0x17cd'),'nolimit':!![]})[_0x3099af('0xe53')][_0x3099af('0x683')](function(_0x2c155f){const _0x4cb557=_0x3099af;_0x5af2aa['queues']=_0x2c155f||{'count':0x0,'rows':[]},_0x5af2aa[_0x4cb557('0xc9a')]=_0x2e3ca0()[_0x4cb557('0x1cc9')](_0x2e3ca0()[_0x4cb557('0x24db')](_0x5af2aa[_0x4cb557('0x2da')]['rows'],_0x4cb557('0x60a')),_0x4cb557('0x60a'));})['catch'](function(_0x5dbdec){const _0x5e05ac=_0x3099af;console[_0x5e05ac('0x52a')](_0x5dbdec);})[_0x3099af('0x2874')](function(){const _0x4fdf13=_0x3099af;_0x5af2aa[_0x4fdf13('0xc71')]=_0x5b7f36(),_0x5af2aa['getAbandonedCalls']();}):_0xc7cb78['userProfile'][_0x3099af('0x241d')]({'id':_0x5af2aa[_0x3099af('0x11ed')][_0x3099af('0x2f')],'section':_0x3099af('0x1a4c'),'channel':'voice','type':_0x3099af('0x17cd'),'sort':_0x3099af('0xc36'),'nolimit':!![]})[_0x3099af('0xe53')][_0x3099af('0x683')](function(_0x3b3c85){const _0xfffe11=_0x3099af;_0x5af2aa[_0xfffe11('0x2da')]=_0x3b3c85||{'count':0x0,'rows':[]},_0x5af2aa['queuesMap']=_0x2e3ca0()[_0xfffe11('0x1cc9')](_0x2e3ca0()[_0xfffe11('0x24db')](_0x5af2aa['queues'][_0xfffe11('0xf5d')],_0xfffe11('0x60a')),'name');})[_0x3099af('0x130a')](function(_0x278d25){const _0x346460=_0x3099af;console[_0x346460('0x52a')](_0x278d25);})[_0x3099af('0x2874')](function(){const _0x24154d=_0x3099af;_0x5af2aa['quickFilters']=_0x5b7f36(),_0x5af2aa[_0x24154d('0x25bd')]();});}function _0x5b7f36(){const _0x54fc7a=_0x56da67;return[{'name':_0x54fc7a('0x10c1'),'key':_0x54fc7a('0x1a4'),'type':_0x54fc7a('0x270e'),'label':_0x54fc7a('0x1006')},{'name':'Agent','key':'lastAssignedTo','type':_0x54fc7a('0xb31'),'label':_0x54fc7a('0x21fb'),'options':_0x5af2aa[_0x54fc7a('0x756')]['rows'],'customOptions':[{'value':_0x54fc7a('0x5eb'),'translate':_0x54fc7a('0x2608')},{'value':undefined,'translate':'DASHBOARDS.ALL'}]},{'name':_0x54fc7a('0x257b'),'key':_0x54fc7a('0x660'),'type':_0x54fc7a('0xf6c'),'label':_0x54fc7a('0x1fd6'),'options':_0x5af2aa['queues'][_0x54fc7a('0xf5d')]}];}function _0x5d75f9(){const _0x5bad14=_0x56da67;_0x5af2aa[_0x5bad14('0x7b2')]=![],_0x5af2aa[_0x5bad14('0x2da')][_0x5bad14('0x50d')]>0x0?(_0x5af2aa[_0x5bad14('0x23a2')][_0x5bad14('0x660')]=_0x5af2aa[_0x5bad14('0x2da')]['count']===0x1?_0x5af2aa['queues']['rows'][0x0]['name']:_0x5af2aa[_0x5bad14('0x23a2')][_0x5bad14('0x660')],_0x5af2aa['query'][_0x5bad14('0x1cc8')]=(_0x5af2aa[_0x5bad14('0x23a2')][_0x5bad14('0xdf8')]-0x1)*_0x5af2aa[_0x5bad14('0x23a2')]['limit'],_0x2afad4['localStorage']['setItem'](_0x5bad14('0x2365')+_0x5af2aa[_0x5bad14('0x11ed')]['id'],JSON[_0x5bad14('0x258a')]({'query':_0x2e3ca0()['omit'](_0x5af2aa[_0x5bad14('0x23a2')],'queue')})),_0x5af2aa[_0x5bad14('0x1883')]=_0xc7cb78[_0x5bad14('0x243')][_0x5bad14('0x267a')](_0x5af2aa[_0x5bad14('0x23a2')],_0x804cce)[_0x5bad14('0xe53')]):_0x804cce(null);}function _0x804cce(_0x58f0de){const _0x51b59b=_0x56da67;_0x5af2aa[_0x51b59b('0x37b')]=_0x58f0de||{'count':0x0,'rows':[]},_0x5af2aa[_0x51b59b('0x7b2')]=!![];}function _0x49b128(){const _0x14e98e=_0x56da67;_0x5af2aa[_0x14e98e('0x12c2')]=![],_0x5af2aa[_0x14e98e('0x25bd')]();}function _0x3199c1(_0x136797){const _0x5518cd=_0x56da67,_0xe87ee='outbound';_0x136797&&_0x5af2aa['queuesMap']&&_0x136797['queue']['type']===_0xe87ee&&_0x5af2aa[_0x5518cd('0xc9a')][_0x136797['queue']]&&(_0x5af2aa['showTooltip']=!![]);}function _0x2c2521(_0x1ea9f2){const _0x1c77ee=_0x56da67;if(_0x1ea9f2){const _0x402cd4=_0x2e3ca0()[_0x1c77ee('0x1ce4')](_0x5af2aa['abandonedCalls']['rows'],['id',_0x1ea9f2['id']]);_0x402cd4>=0x0&&_0x2e3ca0()[_0x1c77ee('0xf22')](_0x5af2aa[_0x1c77ee('0x37b')]['rows'][_0x402cd4],_0x1ea9f2);}}function _0x5b2219(_0x513fbd,_0x56943c){const _0x2f30ad=_0x56da67;_0x513fbd&&_0xc7cb78[_0x2f30ad('0x243')]['update']({'id':_0x513fbd['id'],'lastAssignedTo':_0x56943c?_0x56943c[_0x2f30ad('0x60a')]:null,'assigned':_0x56943c?!![]:![]})[_0x2f30ad('0xe53')][_0x2f30ad('0x130a')](function(_0x2e0efa){const _0x53f0f4=_0x2f30ad;console[_0x53f0f4('0x1b2b')](_0x2e0efa);});}function _0x42f345(_0xe4a918){const _0x50503f=_0x56da67;_0x4953e0[_0x50503f('0x1d4')]({'controller':_0x50503f('0x233c'),'controllerAs':'vm','templateUrl':_0x578fc1,'parent':angular[_0x50503f('0x1fcc')](_0x35d456['body']),'targetEvent':_0xe4a918,'resolve':{'globalDispositions':[_0x50503f('0x4b1'),function(_0x222141){const _0x3f55f3=_0x50503f;return _0x222141['resolve'](_0x3f55f3('0xfaa'),{'MailAccountId':_0x3f55f3('0x13c'),'FaxAccountId':_0x3f55f3('0x13c'),'SmsAccountId':_0x3f55f3('0x13c'),'WhatsappAccountId':_0x3f55f3('0x13c'),'OpenchannelAccountId':_0x3f55f3('0x13c'),'ChatWebsiteId':_0x3f55f3('0x13c'),'ListId':_0x3f55f3('0x13c')});}]},'locals':{'dispositions':_0x5af2aa['dispositions'],'call':_0xe4a918}})[_0x50503f('0x683')](function(_0x456129){const _0x24fb0a=_0x50503f;if(_0x456129){const _0x59096e={'id':_0xe4a918['id'],'disposition':_0x456129[_0x24fb0a('0xdc8')]||null,'secondDisposition':_0x456129[_0x24fb0a('0x53b')]||null,'thirdDisposition':_0x456129[_0x24fb0a('0x176')]||null};_0xc7cb78[_0x24fb0a('0x243')][_0x24fb0a('0x2480')](_0x59096e)['$promise'][_0x24fb0a('0x130a')](function(_0x21a835){const _0x54891a=_0x24fb0a;console[_0x54891a('0x1b2b')](_0x21a835);});}});}let _0x1e1f46=!![],_0x57f495=0x1;_0x6e5adf['$watch']('vm.query.filter',function(_0x525a49,_0x47ce03){const _0x5dac2b=_0x56da67;_0x1e1f46?_0x3c5b68(function(){_0x1e1f46=![];}):(!_0x47ce03&&(_0x57f495=_0x5af2aa['query']['page']),_0x525a49!==_0x47ce03&&(_0x5af2aa[_0x5dac2b('0x23a2')][_0x5dac2b('0xdf8')]=0x1),!_0x525a49&&(_0x5af2aa['query'][_0x5dac2b('0xdf8')]=_0x57f495),_0x5af2aa[_0x5dac2b('0x25bd')]());}),_0x6e5adf['$on'](_0x56da67('0x4b8'),function(){const _0x3f71e0=_0x56da67;_0x4fa5bc[_0x3f71e0('0x1b9e')](_0x3f71e0('0x187')),_0x4fa5bc['removeAllListeners'](_0x3f71e0('0x2660'));});}const _0x59c918=_0x3d736b;_0x1c9030[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$q',_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x241e'),_0x189033('0x22ab'),_0x189033('0x756'),'rpcAgents',_0x189033('0x56b'),'socket',_0x189033('0x1d70'),_0x189033('0xa72'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x1b27')];function _0x1c9030(_0x5b1bac,_0x2c5f29,_0x42cf74,_0x343f72,_0x1c3d33,_0x60d76c,_0x633dee,_0x44b2dc,_0x406dc9,_0x4823d0,_0x4f0128,_0x2f5fe5,_0x309ec7,_0x242c87,_0x59a1b5,_0x4a159f,_0x20be89,_0xc541f){const _0x145b88=_0x189033,_0x2e2a01=this,_0x2eb5aa=[_0x145b88('0xef9'),_0x145b88('0x2309'),'lastLoginAt',_0x145b88('0x8cc'),_0x145b88('0x17fe'),'lastPauseAt',_0x145b88('0x1d43'),_0x145b88('0x2050'),_0x145b88('0x1938'),_0x145b88('0x1a11'),_0x145b88('0x774'),_0x145b88('0x1b89'),'whatsappPause',_0x145b88('0x716'),_0x145b88('0x1431'),'chatCapacity',_0x145b88('0x218'),_0x145b88('0x2409'),_0x145b88('0x205'),_0x145b88('0x1484'),_0x145b88('0x1079'),_0x145b88('0x153b'),'openchannelCurrentCapacity','mailCurrentCapacity',_0x145b88('0x1902'),_0x145b88('0xaba'),_0x145b88('0x157f'),'chatStatus','openchannelStatus',_0x145b88('0xb90'),_0x145b88('0x2787'),_0x145b88('0x2512'),_0x145b88('0x278b'),_0x145b88('0x15e0'),_0x145b88('0x1a03'),_0x145b88('0x15db'),_0x145b88('0xc07'),_0x145b88('0x1a70'),_0x145b88('0x17c2'),_0x145b88('0x21d1'),_0x145b88('0x23b4'),_0x145b88('0x660'),_0x145b88('0x10f5'),_0x145b88('0xd70'),_0x145b88('0xa31'),_0x145b88('0x2259')],_0x1ccdee=[_0x145b88('0x1938'),_0x145b88('0x1a11'),'mailPause',_0x145b88('0x1b89'),'whatsappPause',_0x145b88('0x716'),_0x145b88('0x1431'),_0x145b88('0x2309')];_0x2e2a01['currentUser']=_0x4a159f['getCurrentUser'](),_0x2e2a01['availableStates']=['ringing',_0x145b88('0x5d7'),_0x145b88('0x63'),_0x145b88('0x1026'),_0x145b88('0x79')],_0x2e2a01[_0x145b88('0x22ab')]=_0x633dee||{'count':0x0,'rows':[]},_0x2e2a01[_0x145b88('0xace')]=_0x20be89,_0x2e2a01[_0x145b88('0x2a')]=_0x242c87,_0x2e2a01[_0x145b88('0x22df')]=_0x59a1b5&&_0x59a1b5[_0x145b88('0x50d')]==0x1?_0x59a1b5[_0x145b88('0xf5d')][0x0]:null,_0x2e2a01[_0x145b88('0x1134')]=_0x4a159f['parseCrudPermissions'](_0x2e2a01[_0x145b88('0x22df')]?_0x2e2a01[_0x145b88('0x22df')][_0x145b88('0x1134')]:null),_0x2e2a01['agents']=_0x44b2dc?_0x2e3ca0()[_0x145b88('0x24db')](_0x44b2dc[_0x145b88('0xf5d')]?_0x44b2dc[_0x145b88('0xf5d')]:[],'id'):{},_0x2e2a01[_0x145b88('0x127b')]=_0x406dc9?_0x2e3ca0()[_0x145b88('0x24db')](_0x406dc9['rows']?_0x406dc9['rows']:[],'id'):{},_0x2e2a01[_0x145b88('0x20d5')]={},_0x2e2a01[_0x145b88('0x182c')]=![],_0x2e2a01[_0x145b88('0x150d')]=[],_0x2e2a01[_0x145b88('0x7c6')]={};for(const _0xcf82b7 in _0x2e2a01[_0x145b88('0x756')]){typeof _0x2e2a01[_0x145b88('0x756')][_0xcf82b7]!==_0x145b88('0x1867')&&(_0x2e2a01['agents'][_0xcf82b7]['init']=!![]);}_0x2e2a01[_0x145b88('0x23a2')]={'limit':0xa,'page':0x1,'order':_0x145b88('0x11bc'),'globalStatusFilter':'','pauseTypeFilter':''},_0x2e2a01[_0x145b88('0x1999')]=_0x4e00ff,_0x2e2a01['queueAdd']=_0x5b5021,_0x2e2a01[_0x145b88('0xa4')]=_0x4c8e2a,_0x2e2a01['unPause']=_0x376c52,_0x2e2a01[_0x145b88('0x411')]=_0x4c3a8b,_0x2e2a01[_0x145b88('0x2d2')]=_0x13d23a,_0x2e2a01['getAgentGlobalStatus']=_0x32d064,_0x2e2a01[_0x145b88('0x3ee')]=_0x3345d6,_0x2e2a01[_0x145b88('0x2678')]=_0x452358,_0x2e2a01[_0x145b88('0x1f68')]=_0x11bf05,_0x2e2a01[_0x145b88('0x2819')]=_0x4077e9,_0x2e2a01['onUpdate']=_0x400944,_0x2e2a01[_0x145b88('0x1dd2')]=_0xcd9b74,_0x2e2a01[_0x145b88('0x16b6')]=_0x4eac99,_0x2e2a01[_0x145b88('0x2250')]=_0x99792b,_0x2e2a01[_0x145b88('0x1f6c')]=_0x565399,_0x4f0128['on'](_0x145b88('0x18f0'),_0x2e2a01['onSave']),_0x4f0128['on'](_0x145b88('0x2719'),_0x2e2a01[_0x145b88('0x1418')]),_0x4f0128['on'](_0x145b88('0x216d'),_0x2e2a01[_0x145b88('0x16b6')]),_0x4f0128['on'](_0x145b88('0x3b6'),_0x2e2a01[_0x145b88('0x2250')]),_0xcd9b74();let _0xa02e5c=_0xc541f(function(){const _0x5019ca=_0x145b88;_0x2e2a01[_0x5019ca('0x182c')]&&(_0x2e2a01[_0x5019ca('0x182c')]=![],_0xcd9b74());},0x3e7);function _0xcd9b74(){const _0x49ae1a=_0x145b88;_0x2e2a01[_0x49ae1a('0x182c')]=![];const _0x4ee553=_0x2c5f29[_0x49ae1a('0x448')]();_0x2e2a01['promise']=_0x4ee553[_0x49ae1a('0x1883')],_0x2e2a01[_0x49ae1a('0xdf9')]=[],_0x2e2a01[_0x49ae1a('0x150d')]=[],_0x2e3ca0()['forIn'](_0x2e2a01['agents'],function(_0x463b85,_0x265880){const _0x1474c7=_0x49ae1a;_0x2e2a01['rpcAgents'][_0x265880]&&_0x2e3ca0()['merge'](_0x463b85,_0x2e3ca0()[_0x1474c7('0x24d0')](_0x2e3ca0()['omit'](_0x2e2a01[_0x1474c7('0x127b')][_0x265880],_0x1ccdee),_0x2eb5aa)),_0x32d064(_0x463b85),_0x463b85[_0x1474c7('0x2309')]?(_0x2e2a01[_0x1474c7('0xdf9')][_0x1474c7('0x1fd0')](_0x463b85),_0x2e2a01[_0x1474c7('0x7c6')][_0x463b85[_0x1474c7('0x1d43')]]=_0x265880):_0x463b85[_0x1474c7('0x24d')]=_0x2e3ca0()[_0x1474c7('0xea3')](_0x1aaf93()()['format']('x'));});_0x2e2a01[_0x49ae1a('0x23a2')]['globalStatusFilter']&&_0x2e3ca0()[_0x49ae1a('0x3ec')](_0x2e2a01['filteredAgents'],function(_0x1da2f9){const _0x34e91a=_0x49ae1a;return _0x1da2f9['globalStatus']!==_0x2e2a01[_0x34e91a('0x23a2')]['globalStatusFilter'];});_0x2e2a01[_0x49ae1a('0x23a2')]['pauseTypeFilter']&&_0x2e3ca0()['remove'](_0x2e2a01['filteredAgents'],function(_0x2e6e54){const _0x4421dc=_0x49ae1a;return _0x2e6e54[_0x4421dc('0x17fe')]!==_0x2e2a01[_0x4421dc('0x23a2')][_0x4421dc('0x1606')];});_0x2e2a01['query'][_0x49ae1a('0x25')]&&_0x2e3ca0()[_0x49ae1a('0x3ec')](_0x2e2a01['filteredAgents'],function(_0xbda2ad){const _0x25dfdc=_0x49ae1a;return _0xbda2ad[_0x25dfdc('0x11bc')][_0x25dfdc('0x93a')]()[_0x25dfdc('0x824')](_0x2e2a01['query'][_0x25dfdc('0x25')][_0x25dfdc('0x93a')]())<0x0;});_0x2e2a01['filteredAgents']=_0x23d4f7(_0x2e2a01[_0x49ae1a('0xdf9')]);const _0x7a04b5=(_0x2e2a01[_0x49ae1a('0x23a2')]['page']-0x1)*_0x2e2a01[_0x49ae1a('0x23a2')][_0x49ae1a('0x6f0')];_0x2e2a01[_0x49ae1a('0x20d5')]=_0x2e3ca0()[_0x49ae1a('0x16b7')](_0x2e2a01[_0x49ae1a('0xdf9')],_0x7a04b5)[_0x49ae1a('0x12c8')](0x0,_0x2e2a01['query'][_0x49ae1a('0x6f0')]);for(let _0x4fc0cb=0x0;_0x4fc0cb<_0x2e2a01[_0x49ae1a('0x20d5')]['length'];_0x4fc0cb+=0x1){_0x2e2a01['order'][_0x49ae1a('0x1fd0')](_0x2e2a01[_0x49ae1a('0x20d5')][_0x4fc0cb]['id']);}_0x4ee553[_0x49ae1a('0xed7')](),_0x2e2a01[_0x49ae1a('0x182c')]=!![];}function _0x4077e9(_0x5e9173){const _0x51a06f=_0x145b88;_0x2e2a01[_0x51a06f('0x756')][_0x5e9173['id']]&&(_0x2e3ca0()[_0x51a06f('0xf22')](_0x2e2a01[_0x51a06f('0x756')][_0x5e9173['id']],_0x2e3ca0()[_0x51a06f('0x24d0')](_0x2e3ca0()[_0x51a06f('0x8b5')](_0x5e9173,_0x1ccdee),_0x2eb5aa)),_0x2e3ca0()[_0x51a06f('0xf22')](_0x2e2a01[_0x51a06f('0x127b')][_0x5e9173['id']],_0x2e3ca0()[_0x51a06f('0x24d0')](_0x2e3ca0()[_0x51a06f('0x8b5')](_0x5e9173,_0x1ccdee),_0x2eb5aa)),_0x32d064(_0x2e2a01[_0x51a06f('0x756')][_0x5e9173['id']]));}function _0x400944(_0x210393){const _0x2c94bc=_0x145b88;_0x2e2a01[_0x2c94bc('0x756')][_0x210393['id']]&&(_0x2e3ca0()[_0x2c94bc('0xf22')](_0x2e2a01[_0x2c94bc('0x756')][_0x210393['id']],_0x2e3ca0()[_0x2c94bc('0x24d0')](_0x210393,_0x2eb5aa)),_0x2e3ca0()[_0x2c94bc('0xf22')](_0x2e2a01[_0x2c94bc('0x127b')][_0x210393['id']],_0x2e3ca0()[_0x2c94bc('0x24d0')](_0x210393,_0x2eb5aa)),_0x210393[_0x2c94bc('0x8cc')]&&(_0x2e2a01[_0x2c94bc('0x756')][_0x210393['id']]['globalStatusTime']=_0x210393['lastPauseAt'],_0x2e2a01[_0x2c94bc('0x127b')][_0x210393['id']][_0x2c94bc('0x24d')]=_0x210393[_0x2c94bc('0x8cc')]),_0x32d064(_0x2e2a01[_0x2c94bc('0x756')][_0x210393['id']]));}function _0x4eac99(_0x361592){const _0x51c2a4=_0x145b88;_0x2e2a01['agents'][_0x2e2a01['agentInternal'][_0x361592[_0x51c2a4('0x1d79')]]]&&(_0x2e3ca0()['merge'](_0x2e2a01['agents'][_0x2e2a01['agentInternal'][_0x361592[_0x51c2a4('0x1d79')]]],_0x2e3ca0()[_0x51c2a4('0x24d0')](_0x361592,[_0x51c2a4('0x660'),_0x51c2a4('0x10f5')])),_0x2e3ca0()['merge'](_0x2e2a01['rpcAgents'][_0x2e2a01['agentInternal'][_0x361592[_0x51c2a4('0x1d79')]]],_0x2e3ca0()['pick'](_0x361592,[_0x51c2a4('0x660'),_0x51c2a4('0x10f5')])));}function _0x99792b(_0x39d077){const _0x577e1f=_0x145b88;_0x2e2a01['agents'][_0x2e2a01[_0x577e1f('0x7c6')][_0x39d077[_0x577e1f('0x1d79')]]]&&(_0x2e2a01[_0x577e1f('0x756')][_0x2e2a01[_0x577e1f('0x7c6')][_0x39d077[_0x577e1f('0x1d79')]]]=_0x2e3ca0()[_0x577e1f('0x8b5')](_0x2e2a01['agents'][_0x2e2a01['agentInternal'][_0x39d077[_0x577e1f('0x1d79')]]],[_0x577e1f('0x660'),_0x577e1f('0x10f5')]),_0x2e2a01['rpcAgents'][_0x2e2a01[_0x577e1f('0x7c6')][_0x39d077['destaccountcode']]]=_0x2e3ca0()[_0x577e1f('0x8b5')](_0x2e2a01['rpcAgents'][_0x2e2a01['agentInternal'][_0x39d077[_0x577e1f('0x1d79')]]],['queue',_0x577e1f('0x10f5')]));}function _0x4e00ff(_0xf0df6c){const _0x2b632b=_0x145b88;return _0x4823d0[_0x2b632b('0xc96')][_0x2b632b('0x1999')]({'id':_0xf0df6c['id'],'device':'realtime','agent_id':_0xf0df6c['id'],'agent_name':_0xf0df6c[_0x2b632b('0x60a')]})[_0x2b632b('0xe53')][_0x2b632b('0x683')](function(){const _0x4e870f=_0x2b632b;_0x2f5fe5[_0x4e870f('0x53')]({'title':_0x4e870f('0x1683'),'msg':_0xf0df6c[_0x4e870f('0x11bc')]+_0x4e870f('0x2488')}),_0x2e2a01[_0x4e870f('0x756')][_0xf0df6c['id']]&&(_0x2e2a01[_0x4e870f('0x756')][_0xf0df6c['id']]['online']=![]),_0x2e2a01['rpcAgents'][_0xf0df6c['id']]&&(_0x2e2a01[_0x4e870f('0x127b')][_0xf0df6c['id']][_0x4e870f('0x2309')]=![]),_0xcd9b74();})[_0x2b632b('0x130a')](function(_0x4ddc10){const _0x3f85c8=_0x2b632b;_0x2f5fe5['error']({'title':_0x4ddc10['status']?_0x3f85c8('0x2168')+_0x4ddc10[_0x3f85c8('0x13ee')]+_0x3f85c8('0xbf6')+_0x4ddc10[_0x3f85c8('0x24a9')]:_0x3f85c8('0x154f'),'msg':_0x4ddc10[_0x3f85c8('0x5a5')]?JSON[_0x3f85c8('0x258a')](_0x4ddc10[_0x3f85c8('0x5a5')][_0x3f85c8('0x8c2')]):_0x4ddc10[_0x3f85c8('0x1ff0')]()});});}function _0x4c8e2a(_0x3bb0a9,_0x5d654b){const _0x487b8a=_0x145b88;return _0x4823d0[_0x487b8a('0xc96')][_0x487b8a('0xa4')]({'id':_0x3bb0a9['id'],'type':_0x5d654b})[_0x487b8a('0xe53')]['then'](function(_0x2319b6){const _0x2f26cf=_0x487b8a;_0x2e2a01[_0x2f26cf('0x756')][_0x3bb0a9['id']]&&_0x2e3ca0()['merge'](_0x2e2a01[_0x2f26cf('0x756')][_0x3bb0a9['id']],_0x2e3ca0()[_0x2f26cf('0x24d0')](_0x2319b6,_0x2eb5aa)),_0x2e2a01[_0x2f26cf('0x127b')][_0x3bb0a9['id']]&&_0x2e3ca0()[_0x2f26cf('0xf22')](_0x2e2a01[_0x2f26cf('0x127b')][_0x3bb0a9['id']],_0x2e3ca0()['pick'](_0x2319b6,_0x2eb5aa)),_0x32d064(_0x2e2a01[_0x2f26cf('0x756')][_0x3bb0a9['id']]);})[_0x487b8a('0x130a')](function(_0x20b465){const _0x3567f0=_0x487b8a;_0x2f5fe5[_0x3567f0('0x52a')]({'title':_0x20b465['status']?_0x3567f0('0x2168')+_0x20b465[_0x3567f0('0x13ee')]+'\x20-\x20'+_0x20b465[_0x3567f0('0x24a9')]:'api.staff.save','msg':_0x20b465[_0x3567f0('0x5a5')]?JSON[_0x3567f0('0x258a')](_0x20b465[_0x3567f0('0x5a5')]['message']):_0x20b465['toString']()});});}function _0x376c52(_0x4446fc){const _0x19013c=_0x145b88;return _0x4823d0[_0x19013c('0xc96')][_0x19013c('0x1778')]({'id':_0x4446fc['id']})[_0x19013c('0xe53')][_0x19013c('0x683')](function(_0x4fa05f){const _0x5c3fa8=_0x19013c;_0x2e2a01[_0x5c3fa8('0x756')][_0x4446fc['id']]&&_0x2e3ca0()[_0x5c3fa8('0xf22')](_0x2e2a01[_0x5c3fa8('0x756')][_0x4446fc['id']],_0x2e3ca0()[_0x5c3fa8('0x24d0')](_0x4fa05f,_0x2eb5aa)),_0x2e2a01[_0x5c3fa8('0x127b')][_0x4446fc['id']]&&_0x2e3ca0()['merge'](_0x2e2a01[_0x5c3fa8('0x127b')][_0x4446fc['id']],_0x2e3ca0()[_0x5c3fa8('0x24d0')](_0x4fa05f,_0x2eb5aa)),_0x32d064(_0x2e2a01[_0x5c3fa8('0x756')][_0x4446fc['id']]);})['catch'](function(_0x5c6894){const _0x353d0f=_0x19013c;_0x2f5fe5[_0x353d0f('0x52a')]({'title':_0x5c6894[_0x353d0f('0x13ee')]?_0x353d0f('0x2168')+_0x5c6894['status']+_0x353d0f('0xbf6')+_0x5c6894[_0x353d0f('0x24a9')]:_0x353d0f('0x154f'),'msg':_0x5c6894[_0x353d0f('0x5a5')]?JSON[_0x353d0f('0x258a')](_0x5c6894[_0x353d0f('0x5a5')][_0x353d0f('0x8c2')]):_0x5c6894[_0x353d0f('0x1ff0')]()});});}function _0x4c3a8b(_0x40d3e8){const _0x4dba23=_0x145b88;_0x343f72[_0x4dba23('0x1d4')](_0x343f72['alert']()['clickOutsideToClose'](!![])['title'](_0x4dba23('0x71a'))[_0x4dba23('0x26e3')](_0x4dba23('0x1f0'))['ok']('Ok')[_0x4dba23('0xe42')](_0x40d3e8));}function _0x5b5021(_0x362cf3,_0x57d00b){const _0x75fa4e=_0x145b88;_0x343f72['show']({'controller':'AgentqueueaddController','controllerAs':'vm','templateUrl':_0xf3687b,'parent':angular[_0x75fa4e('0x1fcc')](_0x1c3d33[_0x75fa4e('0x18e5')]),'targetEvent':_0x57d00b,'clickOutsideToClose':!![],'locals':{'agent':_0x362cf3,'agents':[],'channel':_0x75fa4e('0xcf2'),'direction':_0x75fa4e('0x17cd'),'crudPermissions':_0x2e2a01['crudPermissions']}});}function _0x3345d6(_0x1fd4b3){const _0x20c8c5=_0x145b88;return _0x1fd4b3===_0x20c8c5('0xa4')||_0x1fd4b3==='*pause';}function _0x452358(_0x4ba229){const _0xe3745=_0x145b88;return _0x4ba229===_0xe3745('0xa4');}function _0x11bf05(_0x33c8fe){const _0x14468d=_0x145b88;return _0x33c8fe===_0x14468d('0x651');}function _0x54e33c(_0x3a215a){const _0x3d1d11=_0x145b88;return _0x3a215a===_0x3d1d11('0x1586')||_0x3a215a===_0x3d1d11('0xdd4')||_0x3a215a===_0x3d1d11('0x19d2')||_0x3a215a===_0x3d1d11('0x2727')||_0x2e3ca0()['isNil'](_0x3a215a);}function _0x13d23a(_0x3a7624,_0x1f45a6){const _0x3b35ef=_0x145b88;if(_0x1f45a6===_0x3b35ef('0xcf2')){if(_0x3a7624[_0x1f45a6+'Status']!==_0x3b35ef('0x1586'))return _0x3a7624[_0x1f45a6+_0x3b35ef('0x1d9d')];if(_0x3a7624[_0x1f45a6+_0x3b35ef('0x2113')])return _0x3a7624[_0x1f45a6+'Status']=_0x3b35ef('0xa4'),_0x3b35ef('0xa4');return _0x3b35ef('0x1586');}else{if(_0x3a7624[_0x1f45a6+_0x3b35ef('0x2113')])return _0x3a7624[_0x1f45a6+_0x3b35ef('0x1d9d')]=_0x3b35ef('0xa4'),_0x3b35ef('0xa4');return _0x3a7624[_0x1f45a6+'Status'];}}function _0x32d064(_0x3af71c){const _0x228cbc=_0x145b88;let _0x475b7a=_0x228cbc('0xdd4');if(_0x2e3ca0()['every']([_0x13d23a(_0x3af71c,'voice'),_0x13d23a(_0x3af71c,'chat'),_0x13d23a(_0x3af71c,'mail'),_0x13d23a(_0x3af71c,_0x228cbc('0x1261')),_0x13d23a(_0x3af71c,_0x228cbc('0x1285')),_0x13d23a(_0x3af71c,_0x228cbc('0x16e7')),_0x13d23a(_0x3af71c,_0x228cbc('0x23e9'))],_0x3345d6))_0x475b7a=_0x228cbc('0xa4');else{if(_0x2e3ca0()['some']([_0x13d23a(_0x3af71c,'voice'),_0x13d23a(_0x3af71c,'chat'),_0x13d23a(_0x3af71c,'mail'),_0x13d23a(_0x3af71c,_0x228cbc('0x1261')),_0x13d23a(_0x3af71c,_0x228cbc('0x1285')),_0x13d23a(_0x3af71c,_0x228cbc('0x16e7')),_0x13d23a(_0x3af71c,_0x228cbc('0x23e9'))],_0x3345d6))_0x475b7a=_0x228cbc('0x651');else _0x2e3ca0()[_0x228cbc('0x161')]([_0x13d23a(_0x3af71c,_0x228cbc('0xcf2')),_0x13d23a(_0x3af71c,'chat'),_0x13d23a(_0x3af71c,'mail'),_0x13d23a(_0x3af71c,_0x228cbc('0x1261')),_0x13d23a(_0x3af71c,_0x228cbc('0x1285')),_0x13d23a(_0x3af71c,_0x228cbc('0x16e7')),_0x13d23a(_0x3af71c,_0x228cbc('0x23e9'))],_0x54e33c)?_0x475b7a=_0x228cbc('0x1586'):_0x475b7a=_0x228cbc('0x63');}_0x3af71c[_0x228cbc('0x12fa')]!==_0x475b7a&&(_0x3af71c[_0x228cbc('0x12fa')]=_0x475b7a,_0x3af71c[_0x228cbc('0x12f3')]?(_0x3af71c[_0x228cbc('0x12f3')]=![],_0x3af71c[_0x228cbc('0x24d')]=_0x3345d6(_0x475b7a)?_0x2e3ca0()[_0x228cbc('0xea3')](_0x1aaf93()(_0x3af71c[_0x228cbc('0x8cc')])['format']('x')):_0x2e3ca0()[_0x228cbc('0x69b')]([_0x3af71c[_0x228cbc('0x23b4')],_0x3af71c[_0x228cbc('0x1a03')],_0x3af71c[_0x228cbc('0xc07')],_0x3af71c[_0x228cbc('0x1a70')],_0x3af71c[_0x228cbc('0x17c2')],_0x3af71c['openchannelStatusTime'],_0x3af71c[_0x228cbc('0x21d1')]])):_0x3af71c['globalStatusTime']=_0x2e3ca0()[_0x228cbc('0xea3')](_0x1aaf93()()['format']('x')));}function _0x23d4f7(_0x3a01ae){const _0x5904e7=_0x145b88,_0x4220a4=_0x2e3ca0()['startsWith'](_0x2e2a01[_0x5904e7('0x23a2')]['order'],'-')?_0x5904e7('0x1f5a'):'asc';return _0x2e3ca0()[_0x5904e7('0x2ef')](_0x3a01ae,[_0x2e2a01['query'][_0x5904e7('0x150d')][_0x5904e7('0x1725')]('-','')],[_0x4220a4]);}function _0x275b0c(){const _0x1bed47=_0x145b88;_0xa02e5c&&(_0xc541f[_0x1bed47('0x19fb')](_0xa02e5c),_0xa02e5c=null);}function _0x565399(_0x89ad9,_0x3749bb){const _0x5a74db=_0x145b88;return _0x4823d0['user'][_0x5a74db('0x2480')]({'id':_0x89ad9['id']},{'screenrecording':_0x3749bb})['$promise'][_0x5a74db('0x130a')](function(_0x4499ad){const _0x403a73=_0x5a74db;_0x2f5fe5['error']({'title':_0x4499ad[_0x403a73('0x13ee')]?_0x403a73('0x2168')+_0x4499ad[_0x403a73('0x13ee')]+'\x20-\x20'+_0x4499ad[_0x403a73('0x24a9')]:_0x403a73('0x162b'),'msg':_0x4499ad[_0x403a73('0x5a5')]?JSON[_0x403a73('0x258a')](_0x4499ad[_0x403a73('0x5a5')][_0x403a73('0x8c2')]):_0x4499ad['toString']()});});}_0x5b1bac['$on'](_0x145b88('0x4b8'),function(){const _0x390129=_0x145b88;_0x4f0128[_0x390129('0x1b9e')](_0x390129('0x18f0')),_0x4f0128[_0x390129('0x1b9e')](_0x390129('0x2719')),_0x4f0128[_0x390129('0x1b9e')](_0x390129('0x216d')),_0x4f0128['removeAllListeners']('user:agentcomplete'),_0x275b0c();});}const _0x1b8579=_0x1c9030,_0x44a61d=_0x180212['p']+_0x189033('0x1064');_0x22b620[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),'$mdDialog','$document',_0x189033('0x1b27'),_0x189033('0x4fc'),_0x189033('0x197a'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x2a'),_0x189033('0x22df'),'Auth'];function _0x22b620(_0x542420,_0x4b72db,_0x3f591a,_0x49421e,_0x4a5d83,_0x228d8a,_0x592a25,_0xd532ca,_0x37d100,_0x3034ee,_0x14a91b,_0x5754d0){const _0x581316=_0x189033,_0xcc71c8=this,_0x1833ea=[_0x581316('0x60a'),_0x581316('0x357'),_0x581316('0x1de0'),_0x581316('0x8c2'),_0x581316('0x1a95'),_0x581316('0x5ae'),'SquareProjectId',_0x581316('0x17c1'),_0x581316('0xf10'),_0x581316('0x244b'),_0x581316('0x1db8'),_0x581316('0x11af'),_0x581316('0xd6b')];_0xcc71c8[_0x581316('0x11ed')]=_0x5754d0[_0x581316('0x20b2')](),_0xcc71c8[_0x581316('0x50d')]=_0x592a25[_0x581316('0x50d')],_0xcc71c8['campaigns']=_0x592a25?_0x2e3ca0()[_0x581316('0x24db')](_0x592a25['rows']?_0x592a25[_0x581316('0xf5d')]:[],'id'):{},_0xcc71c8[_0x581316('0x4fc')]=_0x228d8a?_0x2e3ca0()[_0x581316('0x24db')](_0x228d8a[_0x581316('0xf5d')]?_0x228d8a[_0x581316('0xf5d')]:[],'id'):{},_0xcc71c8['userProfile']=_0x3034ee,_0xcc71c8[_0x581316('0x22df')]=_0x14a91b&&_0x14a91b[_0x581316('0x50d')]==0x1?_0x14a91b[_0x581316('0xf5d')][0x0]:null,_0xcc71c8[_0x581316('0x1134')]=_0x5754d0['parseCrudPermissions'](_0xcc71c8[_0x581316('0x22df')]?_0xcc71c8['userProfileSection'][_0x581316('0x1134')]:null),_0xcc71c8[_0x581316('0x23a2')]={'sort':'-updatedAt','limit':0xa,'page':0x1},_0xcc71c8[_0x581316('0x53')]=_0x5e7197,_0xcc71c8[_0x581316('0x14ca')]=_0xf3f252,_0xcc71c8[_0x581316('0x2819')]=_0x1745d8,_0xcc71c8[_0x581316('0x3a8')]=_0x2a613f,_0xcc71c8[_0x581316('0x11ba')]=_0x16b48e,_0x37d100[_0x581316('0x5a3')](_0x581316('0x2410'),_0xcc71c8[_0x581316('0x2819')]),_0xcc71c8[_0x581316('0x115c')]=_0x4a5d83(function(){},0x3e7);function _0x2a613f(){const _0x1c020c=_0x581316;_0x2e3ca0()['forIn'](_0xcc71c8[_0x1c020c('0x197a')],function(_0x15a5b2,_0x539c4c){const _0x513edd=_0x1c020c;_0xcc71c8[_0x513edd('0x4fc')][_0x539c4c]&&_0x2e3ca0()['merge'](_0x15a5b2,_0x2e3ca0()[_0x513edd('0x24d0')](_0xcc71c8[_0x513edd('0x4fc')][_0x539c4c],_0x1833ea));});}function _0x1745d8(_0x298fd0){const _0x1a2002=_0x581316;_0xcc71c8[_0x1a2002('0x197a')][_0x298fd0['id']]&&(_0x2e3ca0()[_0x1a2002('0xf22')](_0xcc71c8[_0x1a2002('0x197a')][_0x298fd0['id']],_0x2e3ca0()[_0x1a2002('0x24d0')](_0x298fd0,_0x1833ea)),_0x2e3ca0()['merge'](_0xcc71c8['rpcCampaigns'][_0x298fd0['id']],_0x2e3ca0()[_0x1a2002('0x24d0')](_0x298fd0,_0x1833ea)));}let _0x4439fb=!![],_0x4ce7ea=0x1;_0x542420[_0x581316('0x186d')](_0x581316('0x1e1d'),function(_0x1c72ef,_0x5109c1){const _0x19d1df=_0x581316;_0x4439fb?_0x4b72db(function(){_0x4439fb=![];}):(!_0x5109c1&&(_0x4ce7ea=_0xcc71c8['query'][_0x19d1df('0xdf8')]),_0x1c72ef!==_0x5109c1&&(_0xcc71c8['query'][_0x19d1df('0xdf8')]=0x1),!_0x1c72ef&&(_0xcc71c8['query'][_0x19d1df('0xdf8')]=_0x4ce7ea),_0xcc71c8[_0x19d1df('0x14ca')]());});function _0x5e7197(_0x3c5a71){const _0x75710d=_0x581316;_0xcc71c8[_0x75710d('0x50d')]=_0x3c5a71[_0x75710d('0x50d')],_0xcc71c8[_0x75710d('0x197a')]=_0x3c5a71?_0x2e3ca0()[_0x75710d('0x24db')](_0x3c5a71[_0x75710d('0xf5d')]?_0x3c5a71[_0x75710d('0xf5d')]:[],'id'):{},_0x2a613f();}function _0xf3f252(){const _0x189142=_0x581316;_0xcc71c8[_0x189142('0x23a2')]['offset']=(_0xcc71c8['query']['page']-0x1)*_0xcc71c8[_0x189142('0x23a2')][_0x189142('0x6f0')],_0x5754d0[_0x189142('0xca1')](_0x189142('0x20c2'))?_0xcc71c8[_0x189142('0x1883')]=_0xd532ca[_0x189142('0x6e9')][_0x189142('0x1e6e')](_0xcc71c8[_0x189142('0x23a2')],_0x5e7197)[_0x189142('0xe53')]:(_0xcc71c8[_0x189142('0x23a2')]['id']=_0xcc71c8[_0x189142('0x2a')]['id'],_0xcc71c8['query']['section']=_0x189142('0x23db'),_0xcc71c8[_0x189142('0x1883')]=_0xd532ca[_0x189142('0x2a')][_0x189142('0x241d')](_0xcc71c8[_0x189142('0x23a2')],_0x5e7197)[_0x189142('0xe53')]);}function _0x16b48e(_0x3d20e7,_0xca5137){const _0xd8b67c=_0x581316;_0x3f591a[_0xd8b67c('0x1d4')]({'controller':'CreateOrEditIvrCampaignDialogController','controllerAs':'vm','templateUrl':_0x44a61d,'parent':angular['element'](_0x49421e['body']),'targetEvent':_0x3d20e7,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0xca5137,'ivrCampaigns':_0x2e3ca0()[_0xd8b67c('0x17a0')](_0xcc71c8[_0xd8b67c('0x197a')]),'license':null,'setting':null,'crudPermissions':_0xcc71c8['crudPermissions']}});}_0x542420['$on']('$destroy',function(){const _0x403294=_0x581316;_0x37d100['removeAllListeners'](_0x403294('0x2410')),_0xcc71c8['interval']&&_0x4a5d83['cancel'](_0xcc71c8[_0x403294('0x115c')]);});}const _0x281f1f=_0x22b620;_0xf4eed3[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$timeout',_0x189033('0x1e48'),_0x189033('0x756'),_0x189033('0x2da'),'rpcVoiceQueuesChannels',_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0xa72'),_0x189033('0x1d70'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0xba1')];function _0xf4eed3(_0x192672,_0x5d8981,_0x157c0e,_0x22f864,_0x19a384,_0x47a638,_0x116424,_0x53174c,_0x277605,_0x13879a,_0x4eb047,_0x191b33,_0x47eb92){const _0x4841ce=_0x189033,_0x2b74d5=this;_0x2b74d5[_0x4841ce('0x11ed')]=_0x47eb92['getCurrentUser'](),_0x2b74d5[_0x4841ce('0x756')]=_0x22f864||{'count':0x0,'rows':[]},_0x2b74d5[_0x4841ce('0x2da')]=_0x19a384?_0x2e3ca0()[_0x4841ce('0x24db')](_0x19a384[_0x4841ce('0xf5d')]?_0x19a384['rows']:[],_0x4841ce('0x60a')):{},_0x2b74d5[_0x4841ce('0x2331')]=_0x47a638?_0x2e3ca0()[_0x4841ce('0x24db')](_0x47a638[_0x4841ce('0xf5d')]?_0x2e3ca0()[_0x4841ce('0x25')](_0x47a638[_0x4841ce('0xf5d')],{'type':_0x4841ce('0x17cd')}):[],_0x4841ce('0x573')):{},_0x2b74d5[_0x4841ce('0x203c')]={},_0x2b74d5[_0x4841ce('0x2a')]=_0x4eb047,_0x2b74d5[_0x4841ce('0x22df')]=_0x191b33&&_0x191b33[_0x4841ce('0x50d')]==0x1?_0x191b33[_0x4841ce('0xf5d')][0x0]:null,_0x2b74d5['crudPermissions']=_0x47eb92[_0x4841ce('0x142a')](_0x2b74d5['userProfileSection']?_0x2b74d5[_0x4841ce('0x22df')][_0x4841ce('0x1134')]:null),_0x2b74d5[_0x4841ce('0xcd9')]={'limit':0xa,'page':0x1},_0x2b74d5[_0x4841ce('0x2487')]=_0x3efdc4,_0x2b74d5[_0x4841ce('0x3a8')]=_0x3fd369,_0x2b74d5[_0x4841ce('0x2819')]=_0x3ca782,_0x2b74d5['onRemove']=_0xe918d0,_0x2b74d5['hangup']=_0x5c223f,_0x2b74d5[_0x4841ce('0x6da')]=_0x336174,_0x2b74d5[_0x4841ce('0x18f5')]=_0x50dbd4,_0x53174c['on'](_0x4841ce('0x99f'),_0x2b74d5[_0x4841ce('0x2819')]),_0x53174c['on'](_0x4841ce('0xea9'),_0x2b74d5[_0x4841ce('0x2136')]);function _0x3efdc4(_0x590c84){const _0x445c4b=_0x4841ce;return _0x2e3ca0()[_0x445c4b('0x1a41')](_0x590c84);}function _0x3fd369(){const _0x49e0ee=_0x4841ce;_0x2e3ca0()[_0x49e0ee('0x15d0')](_0x2b74d5[_0x49e0ee('0x2331')],function(_0x2750a1,_0x9bdb73){const _0x69263f=_0x49e0ee;_0x2e3ca0()[_0x69263f('0x1c07')](_0x2b74d5['queues'],{'name':_0x2750a1[_0x69263f('0x60a')]})&&(_0x2b74d5['rpcVoiceQueuesChannels'][_0x9bdb73]=_0x2750a1);});}function _0x3ca782(_0xd1be1a){const _0xc85e45=_0x4841ce;_0xd1be1a[_0xc85e45('0xcf0')]===_0xc85e45('0x17cd')&&(_0x2e3ca0()[_0xc85e45('0x1c07')](_0x2b74d5['queues'],{'name':_0xd1be1a['name']})&&(_0x2b74d5[_0xc85e45('0x203c')][_0xd1be1a[_0xc85e45('0x573')]]=_0xd1be1a));}function _0xe918d0(_0xbdeede){const _0x59e95c=_0x4841ce;_0x2b74d5[_0x59e95c('0x203c')][_0xbdeede[_0x59e95c('0x573')]]&&delete _0x2b74d5['rpcVoiceQueuesChannels'][_0xbdeede['uniqueid']];}function _0x5c223f(_0xf61707){const _0x46bebd=_0x4841ce;return _0x116424[_0x46bebd('0x1b1b')][_0x46bebd('0x22c6')]({'uniqueid':_0xf61707})[_0x46bebd('0xe53')][_0x46bebd('0x683')](function(_0x1efa9e){const _0x5273fb=_0x46bebd;_0x13879a['success']({'title':_0x5273fb('0xae4')+_0xf61707+_0x5273fb('0x10a'),'msg':_0x1efa9e[_0x5273fb('0x8c2')]||''});})[_0x46bebd('0x130a')](function(_0x43b106){const _0x2e0760=_0x46bebd;_0x13879a[_0x2e0760('0x52a')]({'title':_0x43b106['status']+_0x2e0760('0xbf6')+_0x43b106[_0x2e0760('0x24a9')],'msg':JSON[_0x2e0760('0x258a')](_0x43b106[_0x2e0760('0x5a5')])||_0x43b106[_0x2e0760('0x8c2')]['join']('\x20')});});}function _0x336174(_0x3539d1,_0x57a465,_0x22dfa0){const _0x741118=_0x4841ce;return _0x116424[_0x741118('0x1b1b')][_0x741118('0x3e3')]({'uniqueid':_0x3539d1,'exten':_0x57a465,'context':_0x22dfa0})['$promise'][_0x741118('0x683')](function(_0x2b3ab0){const _0x307307=_0x741118;_0x13879a['success']({'title':'Channel\x20'+_0x3539d1+_0x307307('0x2081'),'msg':_0x2b3ab0[_0x307307('0x8c2')]||''});})[_0x741118('0x130a')](function(_0x27f126){const _0x4e2180=_0x741118;_0x13879a['error']({'title':_0x27f126['status']+_0x4e2180('0xbf6')+_0x27f126['statusText'],'msg':JSON[_0x4e2180('0x258a')](_0x27f126['data'])||_0x27f126[_0x4e2180('0x8c2')][_0x4e2180('0x1630')]('\x20')});});}function _0x50dbd4(_0x433bca,_0x29043a){const _0x1f5415=_0x4841ce,_0x2b84c5=_0x157c0e[_0x1f5415('0xa84')]()['title'](_0x1f5415('0x2158'))[_0x1f5415('0x156b')](_0x1f5415('0x140f'))[_0x1f5415('0xe42')](_0x433bca)['ok']('Ok')[_0x1f5415('0x19fb')](_0x1f5415('0x253a'));return _0x157c0e[_0x1f5415('0x1d4')](_0x2b84c5)[_0x1f5415('0x683')](function(_0x5320c2){const _0x497c03=_0x1f5415;return _0x116424['rpc'][_0x497c03('0x3e3')]({'uniqueid':_0x29043a,'exten':_0x5320c2})[_0x497c03('0xe53')];})[_0x1f5415('0x683')](function(_0x49e5e1){const _0x33b772=_0x1f5415;_0x13879a[_0x33b772('0x53')]({'title':_0x33b772('0xae4')+_0x29043a+_0x33b772('0x2081'),'msg':_0x49e5e1[_0x33b772('0x8c2')]||''});})[_0x1f5415('0x130a')](function(_0x488598){const _0x48a87e=_0x1f5415;_0x13879a[_0x48a87e('0x52a')]({'title':_0x488598['status']+_0x48a87e('0xbf6')+_0x488598[_0x48a87e('0x24a9')],'msg':JSON[_0x48a87e('0x258a')](_0x488598['data'])||_0x488598[_0x48a87e('0x8c2')]['join']('\x20')});});}_0x192672[_0x4841ce('0x26a2')](_0x4841ce('0x4b8'),function(){const _0x62d79a=_0x4841ce;_0x53174c[_0x62d79a('0x1b9e')](_0x62d79a('0x99f')),_0x53174c[_0x62d79a('0x1b9e')]('voice_queue_channel:remove');});}const _0x385479=_0xf4eed3;_0x42a05f[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$timeout','$interval',_0x189033('0x2da'),_0x189033('0x1a10'),'api',_0x189033('0x1556'),_0x189033('0x2a'),_0x189033('0x22df'),'Auth'];function _0x42a05f(_0x36e0be,_0x232d2c,_0x360739,_0x143227,_0x425ad7,_0x380381,_0xf57b46,_0x25b146,_0x2f6936,_0x26fd90){const _0x24d164=_0x189033,_0x50311b=this,_0x3690ec=[_0x24d164('0x2263'),_0x24d164('0x1e47'),_0x24d164('0x1033'),_0x24d164('0x1f'),_0x24d164('0x1f19'),_0x24d164('0x5f2'),_0x24d164('0x18d3'),_0x24d164('0x4df'),_0x24d164('0xc23'),_0x24d164('0x1ce3'),_0x24d164('0xf14'),_0x24d164('0x237b'),_0x24d164('0x1e51'),'outboundOriginateFailureCallsDay','outboundAnswerAgiCallsDay','outboundReCallsDay','outboundRejectCallsDay'];_0x50311b[_0x24d164('0x50d')]=_0x143227['count'],_0x50311b['queues']=_0x143227?_0x2e3ca0()['keyBy'](_0x143227['rows']?_0x143227['rows']:[],'id'):{},_0x50311b['rpcQueues']=_0x425ad7?_0x2e3ca0()[_0x24d164('0x24db')](_0x425ad7['rows']?_0x425ad7['rows']:[],'id'):{},_0x50311b[_0x24d164('0x2a')]=_0x25b146,_0x50311b[_0x24d164('0x22df')]=_0x2f6936&&_0x2f6936[_0x24d164('0x50d')]==0x1?_0x2f6936[_0x24d164('0xf5d')][0x0]:null,_0x50311b['crudPermissions']=_0x26fd90['parseCrudPermissions'](_0x50311b[_0x24d164('0x22df')]?_0x50311b[_0x24d164('0x22df')][_0x24d164('0x1134')]:null);_0x26fd90[_0x24d164('0xca1')](_0x24d164('0x20c2'))?_0x50311b[_0x24d164('0x23a2')]={'type':_0x24d164('0x17cd'),'fields':'id,name','sort':_0x24d164('0xc36'),'limit':0xa,'page':0x1}:_0x50311b[_0x24d164('0x23a2')]={'id':_0x26fd90[_0x24d164('0x20b2')]()['id'],'channel':_0x24d164('0xcf2'),'type':_0x24d164('0x17cd'),'fields':'id,name','sort':_0x24d164('0xc36'),'limit':0xa,'page':0x1};_0x50311b[_0x24d164('0x53')]=_0x575713,_0x50311b[_0x24d164('0x4c9')]=_0x54ae13,_0x50311b[_0x24d164('0x2819')]=_0x2e1b03,_0x50311b[_0x24d164('0x3a8')]=_0x945731,_0xf57b46[_0x24d164('0x5a3')](_0x24d164('0x1df'),_0x50311b[_0x24d164('0x2819')]),_0x50311b['interval']=_0x360739(function(){},0x3e7);function _0x945731(){const _0x5911c8=_0x24d164;_0x2e3ca0()[_0x5911c8('0x15d0')](_0x50311b[_0x5911c8('0x2da')],function(_0x2455b4,_0x59fe01){const _0x1fd896=_0x5911c8;_0x50311b[_0x1fd896('0x1a10')][_0x59fe01]&&_0x2e3ca0()[_0x1fd896('0xf22')](_0x2455b4,_0x2e3ca0()[_0x1fd896('0x24d0')](_0x50311b[_0x1fd896('0x1a10')][_0x59fe01],_0x3690ec));});}function _0x2e1b03(_0x2d1fb2){const _0x244abb=_0x24d164;_0x50311b[_0x244abb('0x2da')][_0x2d1fb2['id']]&&_0x2e3ca0()[_0x244abb('0xf22')](_0x50311b['queues'][_0x2d1fb2['id']],_0x2e3ca0()[_0x244abb('0x24d0')](_0x2d1fb2,_0x3690ec));}let _0x4c88e6=!![],_0xc6604f=0x1;_0x36e0be[_0x24d164('0x186d')](_0x24d164('0x1e1d'),function(_0x541b20,_0x58267d){const _0x2a2a36=_0x24d164;_0x4c88e6?_0x232d2c(function(){_0x4c88e6=![];}):(!_0x58267d&&(_0xc6604f=_0x50311b[_0x2a2a36('0x23a2')][_0x2a2a36('0xdf8')]),_0x541b20!==_0x58267d&&(_0x50311b[_0x2a2a36('0x23a2')]['page']=0x1),!_0x541b20&&(_0x50311b[_0x2a2a36('0x23a2')]['page']=_0xc6604f),_0x50311b['getQueues']());});function _0x575713(_0x201480){const _0x1d96c4=_0x24d164;_0x50311b[_0x1d96c4('0x50d')]=_0x201480[_0x1d96c4('0x50d')],_0x50311b[_0x1d96c4('0x2da')]=_0x201480?_0x2e3ca0()[_0x1d96c4('0x24db')](_0x201480[_0x1d96c4('0xf5d')]?_0x201480[_0x1d96c4('0xf5d')]:[],'id'):{},_0x945731();}function _0x54ae13(){const _0x53e51e=_0x24d164;_0x50311b[_0x53e51e('0x23a2')][_0x53e51e('0x1cc8')]=(_0x50311b[_0x53e51e('0x23a2')]['page']-0x1)*_0x50311b[_0x53e51e('0x23a2')]['limit'],_0x26fd90[_0x53e51e('0xca1')](_0x53e51e('0x20c2'))?_0x50311b[_0x53e51e('0x1883')]=_0x380381[_0x53e51e('0x204c')]['get'](_0x50311b[_0x53e51e('0x23a2')],_0x575713)[_0x53e51e('0xe53')]:(_0x50311b[_0x53e51e('0x23a2')]['id']=_0x50311b[_0x53e51e('0x2a')]['id'],_0x50311b[_0x53e51e('0x23a2')][_0x53e51e('0x1aa')]=_0x53e51e('0x1a4c'),_0x50311b[_0x53e51e('0x1883')]=_0x380381[_0x53e51e('0x2a')][_0x53e51e('0x241d')](_0x50311b[_0x53e51e('0x23a2')],_0x575713)['$promise']);}_0x36e0be[_0x24d164('0x26a2')](_0x24d164('0x4b8'),function(){const _0x2666f5=_0x24d164;_0xf57b46[_0x2666f5('0x1b9e')](_0x2666f5('0x1df')),_0x50311b['interval']&&_0x360739[_0x2666f5('0x19fb')](_0x50311b[_0x2666f5('0x115c')]);});}const _0x49f38f=_0x42a05f,_0x340822=_0x180212['p']+_0x189033('0x1e9b'),_0x4091df=_0x180212['p']+_0x189033('0x656'),_0x48dc5f=_0x180212['p']+_0x189033('0x1ebf');_0x13c644[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$q',_0x189033('0x16ea'),_0x189033('0x1b27'),'queues',_0x189033('0x1a10'),_0x189033('0x56b'),'socket',_0x189033('0x1d70'),'userProfile',_0x189033('0x22df'),_0x189033('0xba1')];function _0x13c644(_0xebd602,_0x5ae3a7,_0x2b79db,_0x13b277,_0x26e27f,_0x167463,_0x1a0fb0,_0x2aefc9,_0x1e5ebf,_0x2b2447,_0x41df48,_0x2642aa,_0x449b05,_0x1b4d86){const _0x2864a6=_0x189033,_0xa98987=this,_0x5d8fe4=['loggedIn',_0x2864a6('0x8bb'),_0x2864a6('0x1386'),_0x2864a6('0x7a4'),_0x2864a6('0x17f2'),'originated',_0x2864a6('0x8c2'),_0x2864a6('0x1455'),_0x2864a6('0x1091'),'Trunk',_0x2864a6('0x1a1d'),'startPredictive',_0x2864a6('0x1dc8'),_0x2864a6('0x2510'),_0x2864a6('0x290'),_0x2864a6('0x538'),'erlangBusyFactor','dialPredictiveInterval','dialPredictiveIntervalMaxThreshold',_0x2864a6('0x1b30'),_0x2864a6('0x2115'),_0x2864a6('0x27aa'),_0x2864a6('0x1504'),_0x2864a6('0x87a'),'predictiveIntervalDroppedCallsCallersExit',_0x2864a6('0x1cbe'),_0x2864a6('0x21ef')];_0xa98987[_0x2864a6('0x11ed')]=_0x1b4d86['getCurrentUser'](),_0xa98987['count']=_0x1a0fb0[_0x2864a6('0x50d')]?_0x1a0fb0['count']:0x0,_0xa98987['queues']=_0x1a0fb0?_0x2e3ca0()['keyBy'](_0x1a0fb0[_0x2864a6('0xf5d')]?_0x1a0fb0[_0x2864a6('0xf5d')]:[],'id'):{},_0xa98987[_0x2864a6('0x1a10')]=_0x2aefc9?_0x2e3ca0()[_0x2864a6('0x24db')](_0x2aefc9['rows']?_0x2aefc9[_0x2864a6('0xf5d')]:[],'id'):{},_0xa98987[_0x2864a6('0x2a')]=_0x2642aa,_0xa98987[_0x2864a6('0x22df')]=_0x449b05&&_0x449b05['count']==0x1?_0x449b05[_0x2864a6('0xf5d')][0x0]:null,_0xa98987[_0x2864a6('0x1134')]=_0x1b4d86['parseCrudPermissions'](_0xa98987[_0x2864a6('0x22df')]?_0xa98987['userProfileSection'][_0x2864a6('0x1134')]:null);_0x1b4d86['hasRole'](_0x2864a6('0x20c2'))?_0xa98987[_0x2864a6('0x23a2')]={'type':'outbound','sort':'-updatedAt','limit':0xa,'page':0x1}:_0xa98987[_0x2864a6('0x23a2')]={'id':_0xa98987[_0x2864a6('0x11ed')]['id'],'channel':_0x2864a6('0xcf2'),'type':_0x2864a6('0x17cd'),'sort':_0x2864a6('0xc36'),'limit':0xa,'page':0x1};_0xa98987[_0x2864a6('0x53')]=_0x204d35,_0xa98987[_0x2864a6('0x4c9')]=_0x14ceb9,_0xa98987[_0x2864a6('0x221')]=_0x5ea7cd,_0xa98987['showPredictiveQueueCampaignInfo']=_0x979c28,_0xa98987[_0x2864a6('0x1a94')]=_0x4e39c0,_0xa98987[_0x2864a6('0x1f7c')]=_0x5d81de,_0xa98987['onSave']=_0x184580,_0xa98987['onSaveMember']=_0x5524c6,_0xa98987['onPause']=_0xeeae5,_0xa98987['onLogin']=_0x15e5f5,_0xa98987[_0x2864a6('0xb2b')]=_0x5485ab,_0xa98987[_0x2864a6('0x3a8')]=_0x33bc60,_0xa98987[_0x2864a6('0x150d')]=[],_0x2e3ca0()[_0x2864a6('0x15d0')](_0xa98987['queues'],function(_0x2ad791){const _0x35d112=_0x2864a6;_0xa98987['order'][_0x35d112('0x1fd0')](_0x2ad791['id']);}),_0x2b2447['onWithoutApply'](_0x2864a6('0x1df'),_0xa98987[_0x2864a6('0x2819')]),_0xa98987[_0x2864a6('0x115c')]=_0x167463(function(){},0x3e7),_0x2b2447['on'](_0x2864a6('0x2308'),_0xa98987[_0x2864a6('0x3ae')]),_0x2b2447['on'](_0x2864a6('0x2719'),_0xa98987[_0x2864a6('0x4a5')]),_0x2b2447['on'](_0x2864a6('0x56f'),_0xa98987[_0x2864a6('0xb2b')]),_0x2b2447['on'](_0x2864a6('0x217c'),_0xa98987[_0x2864a6('0xd8b')]);function _0x33bc60(){const _0x167ef5=_0x2864a6,_0x2dd6ee=[];return _0x2e3ca0()[_0x167ef5('0x15d0')](_0xa98987['queues'],function(_0x39e50b,_0xc02736){const _0x214d0b=_0x167ef5;_0x39e50b[_0x214d0b('0x1a1d')]=0x0,_0x39e50b[_0x214d0b('0x25a4')]=0x0,_0xa98987['queues'][_0xc02736]['agents']={},_0x2dd6ee[_0x214d0b('0x1fd0')](_0x1e5ebf[_0x214d0b('0x204c')][_0x214d0b('0x27cf')]({'id':_0xc02736})[_0x214d0b('0xe53')]),_0xa98987['rpcQueues'][_0xc02736]&&_0x2e3ca0()['merge'](_0x39e50b,_0x2e3ca0()[_0x214d0b('0x24d0')](_0xa98987[_0x214d0b('0x1a10')][_0xc02736],_0x5d8fe4));}),_0x13b277['all'](_0x2dd6ee)[_0x167ef5('0x683')](function(_0x4db414){const _0x55d67c=_0x167ef5;for(let _0x230282=0x0;_0x230282<_0x4db414['length'];_0x230282+=0x1){for(let _0x1a5c64=0x0;_0x1a5c64<_0x4db414[_0x230282][_0x55d67c('0xf5d')][_0x55d67c('0x1564')];_0x1a5c64++){_0x4db414[_0x230282][_0x55d67c('0xf5d')][_0x1a5c64]['paused']&&_0xa98987['queues'][_0x4db414[_0x230282][_0x55d67c('0xf5d')][_0x1a5c64][_0x55d67c('0x19ec')]][_0x55d67c('0x1a1d')]++,_0xa98987[_0x55d67c('0x2da')][_0x4db414[_0x230282][_0x55d67c('0xf5d')][_0x1a5c64][_0x55d67c('0x19ec')]][_0x55d67c('0x25a4')]++,_0xa98987[_0x55d67c('0x2da')][_0x4db414[_0x230282][_0x55d67c('0xf5d')][_0x1a5c64][_0x55d67c('0x19ec')]][_0x55d67c('0x756')][_0x4db414[_0x230282][_0x55d67c('0xf5d')][_0x1a5c64]['UserId']]=_0x4db414[_0x230282]['rows'][_0x1a5c64][_0x55d67c('0x19ec')];}}})['catch'](function(_0xfde0e){const _0x155ca8=_0x167ef5;console[_0x155ca8('0x52a')](_0xfde0e);});}function _0x184580(_0xdb7ead){const _0x32ba24=_0x2864a6;_0xa98987['queues'][_0xdb7ead['id']]&&(_0x2e3ca0()[_0x32ba24('0xf22')](_0xa98987[_0x32ba24('0x2da')][_0xdb7ead['id']],_0x2e3ca0()['pick'](_0xdb7ead,_0x5d8fe4)),_0x2e3ca0()[_0x32ba24('0x8f2')](_0xdb7ead[_0x32ba24('0x2548')])&&(_0xa98987[_0x32ba24('0x2da')][_0xdb7ead['id']][_0x32ba24('0x2548')]=undefined));}function _0x5524c6(_0x3cf473){const _0x3c2f33=_0x2864a6;_0xa98987['queues'][_0x3cf473[_0x3c2f33('0x1a35')]]&&_0xa98987['queues'][_0x3cf473['MotionDialerQueueId']][_0x3c2f33('0x25a4')]++;}function _0xeeae5(_0x53d563){const _0x42c0dc=_0x2864a6;console['log']('onPause',_0x53d563);if(_0x53d563[_0x42c0dc('0x1431')])_0x2e3ca0()['forIn'](_0xa98987[_0x42c0dc('0x2da')],function(_0x386800){const _0x3adc3f=_0x42c0dc;_0x386800[_0x3adc3f('0x756')][_0x53d563['id']]&&(_0x386800['paused']+=0x1,console[_0x3adc3f('0x1b2b')](_0x3adc3f('0xa4')));});else!_0x53d563[_0x42c0dc('0x1431')]&&_0x2e3ca0()[_0x42c0dc('0x15d0')](_0xa98987[_0x42c0dc('0x2da')],function(_0x46d9df){const _0x36c976=_0x42c0dc;_0x46d9df[_0x36c976('0x756')][_0x53d563['id']]&&(_0x46d9df['paused']>0x0&&(_0x46d9df['paused']-=0x1,console[_0x36c976('0x1b2b')](_0x36c976('0x1778'))));});}function _0x15e5f5(_0x4d87c7){const _0x329f11=_0x2864a6;console[_0x329f11('0x1b2b')](_0x329f11('0x16aa'),_0x4d87c7),_0xa98987['queues'][_0x4d87c7[_0x329f11('0x19ec')]]&&(_0xa98987['queues'][_0x4d87c7['VoiceQueueId']]['loggedInDb']+=0x1,_0xa98987[_0x329f11('0x2da')][_0x4d87c7[_0x329f11('0x19ec')]][_0x329f11('0x756')][_0x4d87c7[_0x329f11('0x10c5')]]=_0x4d87c7['VoiceQueueId']);}function _0x5485ab(_0x5dd824){const _0x166a1d=_0x2864a6;console[_0x166a1d('0x1b2b')](_0x166a1d('0xb2b'),_0x5dd824),_0xa98987[_0x166a1d('0x2da')][_0x5dd824[_0x166a1d('0x19ec')]]&&_0xa98987['queues'][_0x5dd824['VoiceQueueId']][_0x166a1d('0x25a4')]>0x0&&(_0xa98987[_0x166a1d('0x2da')][_0x5dd824['VoiceQueueId']][_0x166a1d('0x25a4')]-=0x1,delete _0xa98987[_0x166a1d('0x2da')][_0x5dd824[_0x166a1d('0x19ec')]][_0x166a1d('0x756')][_0x5dd824['UserId']]);}let _0x59efe8=!![],_0x503f07=0x1;_0xebd602[_0x2864a6('0x186d')](_0x2864a6('0x1e1d'),function(_0x3324de,_0x560dc1){const _0x41c954=_0x2864a6;_0x59efe8?_0x5ae3a7(function(){_0x59efe8=![];}):(!_0x560dc1&&(_0x503f07=_0xa98987[_0x41c954('0x23a2')]['page']),_0x3324de!==_0x560dc1&&(_0xa98987[_0x41c954('0x23a2')]['page']=0x1),!_0x3324de&&(_0xa98987[_0x41c954('0x23a2')][_0x41c954('0xdf8')]=_0x503f07),_0xa98987[_0x41c954('0x4c9')]());});function _0x204d35(_0x299832){const _0x11e405=_0x2864a6;_0xa98987[_0x11e405('0x50d')]=_0x299832[_0x11e405('0x50d')],_0xa98987[_0x11e405('0x2da')]=_0x299832?_0x2e3ca0()['keyBy'](_0x299832[_0x11e405('0xf5d')]?_0x299832[_0x11e405('0xf5d')]:[],'id'):{};if(_0x299832['rows']){_0xa98987[_0x11e405('0x150d')]=[];for(let _0x34d07f=0x0;_0x34d07f<_0x299832[_0x11e405('0xf5d')][_0x11e405('0x1564')];_0x34d07f++){_0xa98987['order']['push'](_0x299832[_0x11e405('0xf5d')][_0x34d07f]['id']);}}_0x33bc60();}function _0x14ceb9(){const _0x1f56d1=_0x2864a6;_0xa98987[_0x1f56d1('0x23a2')][_0x1f56d1('0x1cc8')]=(_0xa98987[_0x1f56d1('0x23a2')][_0x1f56d1('0xdf8')]-0x1)*_0xa98987[_0x1f56d1('0x23a2')]['limit'],_0x1b4d86[_0x1f56d1('0xca1')](_0x1f56d1('0x20c2'))?_0xa98987[_0x1f56d1('0x1883')]=_0x1e5ebf['voiceQueue'][_0x1f56d1('0x1e6e')](_0xa98987[_0x1f56d1('0x23a2')],_0x204d35)[_0x1f56d1('0xe53')]:(_0xa98987['query']['id']=_0xa98987['userProfile']['id'],_0xa98987[_0x1f56d1('0x23a2')][_0x1f56d1('0x1aa')]=_0x1f56d1('0x1a4c'),_0xa98987['promise']=_0x1e5ebf['userProfile'][_0x1f56d1('0x241d')](_0xa98987[_0x1f56d1('0x23a2')],_0x204d35)[_0x1f56d1('0xe53')]);}function _0x5ea7cd(_0x2b34bc,_0x3c53cb){const _0x1d2b65=_0x2864a6;_0x2b79db[_0x1d2b65('0x1d4')]({'controller':_0x1d2b65('0x15a3'),'controllerAs':'vm','templateUrl':_0x340822,'parent':angular['element'](_0x26e27f['body']),'targetEvent':_0x2b34bc,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x3c53cb,'queueCampaigns':_0x2e3ca0()[_0x1d2b65('0x17a0')](_0xa98987['queues']),'license':null,'setting':null,'crudPermissions':_0xa98987[_0x1d2b65('0x1134')]}});}function _0x979c28(_0xdba19d,_0x49413a){const _0x1e0aee=_0x2864a6;_0x2b79db[_0x1e0aee('0x1d4')]({'controller':_0x1e0aee('0x7dc'),'controllerAs':'vm','templateUrl':_0x4091df,'parent':angular['element'](_0x26e27f['body']),'targetEvent':_0xdba19d,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x49413a}});}function _0x4e39c0(_0x326ba8,_0x34d956){const _0x43128a=_0x2864a6;_0x2b79db[_0x43128a('0x1d4')]({'controller':_0x43128a('0x1283'),'controllerAs':'vm','templateUrl':_0x48dc5f,'parent':angular[_0x43128a('0x1fcc')](_0x26e27f[_0x43128a('0x18e5')]),'targetEvent':_0x326ba8,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x34d956,'queueCampaigns':_0xa98987[_0x43128a('0x2da')]?_0xa98987[_0x43128a('0x2da')]['rows']:[],'realtime':!![],'crudPermissions':_0xa98987[_0x43128a('0x1134')]}});}function _0x5d81de(_0x12b9e8){const _0x2dd3fc=_0x2864a6;return _0x1e5ebf[_0x2dd3fc('0x204c')][_0x2dd3fc('0x2480')](_0x12b9e8)[_0x2dd3fc('0xe53')]['then'](function(){const _0x5bb4c5=_0x2dd3fc;_0x41df48[_0x5bb4c5('0x53')]({'title':_0x5bb4c5('0x5c7'),'msg':_0x12b9e8['name']?_0x12b9e8[_0x5bb4c5('0x60a')]+_0x5bb4c5('0x96c'):''});})['catch'](function(_0x4e2cb7){const _0x4dc2f9=_0x2dd3fc;_0x41df48[_0x4dc2f9('0x52a')]({'title':'Error\x20creating\x20queue!','msg':_0x4e2cb7[_0x4dc2f9('0x8c2')]});});}_0xebd602[_0x2864a6('0x26a2')](_0x2864a6('0x4b8'),function(){const _0x41b96f=_0x2864a6;_0x2b2447[_0x41b96f('0x1b9e')](_0x41b96f('0x1df')),_0xa98987[_0x41b96f('0x115c')]&&_0x167463['cancel'](_0xa98987[_0x41b96f('0x115c')]),_0x2b2447['removeAllListeners']('userVoiceQueueRt:save'),_0x2b2447['removeAllListeners'](_0x41b96f('0x2719')),_0x2b2447[_0x41b96f('0x1b9e')]('userVoiceQueue:remove'),_0x2b2447[_0x41b96f('0x1b9e')](_0x41b96f('0x217c'));});}const _0x419781=_0x13c644;_0x44090f[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$interval','queueCampaign'];function _0x44090f(_0x5188e4,_0x355f91,_0xe459b0){const _0x52f40b=_0x189033,_0x31f3b9=this;_0x31f3b9[_0x52f40b('0x1bd9')]=_0xe459b0,_0x31f3b9[_0x52f40b('0xb5f')]=_0x3d1a26,_0x31f3b9[_0x52f40b('0x915')]=_0x5773f6,_0x31f3b9[_0x52f40b('0xf82')]=_0xd07281;function _0x3d1a26(_0x399248,_0x3774ec){const _0x372227=_0x52f40b;return _0x1aaf93()(_0x399248)[_0x372227('0x23c6')]('m',_0x3774ec)[_0x372227('0x26dd')](_0x372227('0x10fc'));}function _0x5773f6(_0x588bd2){const _0x1c535a=_0x52f40b;return _0x1aaf93()(_0x588bd2)[_0x1c535a('0x26dd')](_0x1c535a('0x10fc'));}function _0xd07281(){_0x5188e4['hide']();}}const _0x3fab47=_0x44090f;function _0x20db72(){const _0x11c4d0=_0x189033;return{'status':{'registered':'green-300-fg\x20icon-checkbox-marked-circle','unregistered':_0x11c4d0('0x1da'),'lagged':_0x11c4d0('0x1da'),'reachable':_0x11c4d0('0x584'),'unreachable':_0x11c4d0('0x1da'),'unknown':_0x11c4d0('0xcb0')},'state':{'unknown':_0x11c4d0('0x27f9'),'not_inuse':_0x11c4d0('0x280d'),'inuse':_0x11c4d0('0x10c0'),'busy':'red-300-fg\x20icon-phone-locked','invalid':'grey-fg\x20icon-phone-hangup','unavailable':_0x11c4d0('0x27f9'),'ringing':_0x11c4d0('0x20f0'),'ringinuse':_0x11c4d0('0x20f0'),'onhold':_0x11c4d0('0x1a52')},'channelStatus':{'ring':_0x11c4d0('0x20f0'),'up':_0x11c4d0('0x1133'),'hangup':_0x11c4d0('0x22be')},'channelStatusOut':{'ring':_0x11c4d0('0x2370'),'up':_0x11c4d0('0x1133'),'hangup':'red-300-fg\x20icon-phone-hangup'}};}const _0x43670f=_0x20db72;_0x4df25f[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0x1556')];function _0x4df25f(_0x3b7cd2,_0x7d6502,_0x55316a){const _0x5f43ab=_0x189033,_0x492ea4=this;_0x55316a['disconnect'](),_0x55316a[_0x5f43ab('0x12ac')](),_0x492ea4[_0x5f43ab('0x517')]=0x0;switch(_0x7d6502['current'][_0x5f43ab('0x60a')]){case _0x5f43ab('0x1654'):_0x492ea4['selectedTab']=0x0;break;case _0x5f43ab('0x76c'):_0x492ea4[_0x5f43ab('0x517')]=0x1;break;case'app.motiondialer.realtime.queue_calls':_0x492ea4['selectedTab']=0x2;break;case _0x5f43ab('0x294'):_0x492ea4[_0x5f43ab('0x517')]=0x3;break;case _0x5f43ab('0x2241'):_0x492ea4[_0x5f43ab('0x517')]=0x4;break;case _0x5f43ab('0x1fc4'):_0x492ea4[_0x5f43ab('0x517')]=0x5;break;default:_0x492ea4[_0x5f43ab('0x517')]=0x0,_0x7d6502['go'](_0x5f43ab('0x1654'));}_0x3b7cd2['$watch']('vm.selectedTab',function(_0x3eef47,_0x95c4fc){const _0x21b1f4=_0x5f43ab;if(_0x3eef47!==_0x95c4fc)switch(_0x3eef47){case 0x0:_0x7d6502['go'](_0x21b1f4('0x1654'));break;case 0x1:_0x7d6502['go'](_0x21b1f4('0x76c'));break;case 0x2:_0x7d6502['go'](_0x21b1f4('0xf03'));break;case 0x3:_0x7d6502['go'](_0x21b1f4('0x294'));break;case 0x4:_0x7d6502['go'](_0x21b1f4('0x2241'));break;case 0x5:_0x7d6502['go'](_0x21b1f4('0x1fc4'));break;default:_0x7d6502['go'](_0x21b1f4('0x1654'));}});}const _0xca98f2=_0x4df25f;_0x4ebda6[_0x189033('0x14be')]=['$stateProvider'];function _0x4ebda6(_0xce94d2){const _0x5e26e6=_0x189033;_0xce94d2[_0x5e26e6('0x2598')](_0x5e26e6('0xd4b'),{'url':_0x5e26e6('0xf7c'),'views':{'content@app':{'templateUrl':_0x4b83f6,'controller':_0x5e26e6('0x1caf')}},'resolve':{'userProfile':['apiResolver',_0x5e26e6('0xba1'),function(_0x49f8b2,_0x5d0046){const _0x36c716=_0x5e26e6;return _0x5d0046[_0x36c716('0xca1')](_0x36c716('0x20c2'))?null:_0x49f8b2[_0x36c716('0xed7')](_0x36c716('0x1464'),{'fields':'id,name,crudPermissions','id':_0x5d0046[_0x36c716('0x20b2')]()[_0x36c716('0x2f')]});}],'userProfileSection':['apiResolver',_0x5e26e6('0xba1'),function(_0x375d00,_0x4f72fa){const _0x5d858f=_0x5e26e6;return _0x4f72fa[_0x5d858f('0xca1')](_0x5d858f('0x20c2'))?null:_0x375d00[_0x5d858f('0xed7')]('userProfileSection@get',{'fields':_0x5d858f('0x1f47'),'userProfileId':_0x4f72fa[_0x5d858f('0x20b2')]()[_0x5d858f('0x2f')],'sectionId':0x5e6});}]},'authenticate':!![],'permissionId':0x5e6})['state']('app.motiondialer.realtime.agents',{'url':_0x5e26e6('0xf1a'),'controller':_0x5e26e6('0x1519'),'templateUrl':_0x233760,'resolve':{'pauses':[_0x5e26e6('0x4b1'),function(_0x16d86b){const _0x456604=_0x5e26e6;return _0x16d86b['resolve'](_0x456604('0x112'),{'nolimit':!![]});}],'agents':[_0x5e26e6('0x4b1'),'Auth',function(_0x1b642f,_0x3d7cc9){const _0xd83b08=_0x5e26e6;return _0x3d7cc9['hasRole'](_0xd83b08('0x20c2'))?_0x1b642f[_0xd83b08('0xed7')](_0xd83b08('0x25c9'),{'fields':'id,name,fullname,role,userpic,internal,online,voicePause,openchannelPause,faxPause,chatPause,smsPause,whatsappPause,mailPause,pauseType,lastPauseAt,lastLoginAt,lastPauseAt,chatCapacity,mailCapacity,openchannelCapacity,faxCapacity,smsCapacity,whatsappCapacity,screenrecording,phoneBarEnableScreenRecordingByAgent,phoneBarEnableAutomaticScreenRecording','role':_0xd83b08('0x2327'),'sort':_0xd83b08('0x11bc'),'nolimit':!![]}):_0x1b642f[_0xd83b08('0xed7')](_0xd83b08('0x191b'),{'id':_0x3d7cc9[_0xd83b08('0x20b2')]()[_0xd83b08('0x2f')],'section':'Agents','fields':_0xd83b08('0x174e'),'role':_0xd83b08('0x2327'),'sort':_0xd83b08('0x11bc'),'nolimit':!![]});}],'userProfile':[_0x5e26e6('0x4b1'),'Auth',function(_0x17978a,_0x2de655){const _0x13e8ff=_0x5e26e6;return _0x2de655[_0x13e8ff('0xca1')](_0x13e8ff('0x20c2'))?null:_0x17978a[_0x13e8ff('0xed7')](_0x13e8ff('0x1464'),{'fields':_0x13e8ff('0x16f'),'id':_0x2de655['getCurrentUser']()[_0x13e8ff('0x2f')]});}],'userProfileSection':['apiResolver',_0x5e26e6('0xba1'),function(_0x4fce55,_0x58c654){const _0x5872fb=_0x5e26e6;return _0x58c654[_0x5872fb('0xca1')](_0x5872fb('0x20c2'))?null:_0x4fce55[_0x5872fb('0xed7')]('userProfileSection@get',{'fields':_0x5872fb('0x1f47'),'userProfileId':_0x58c654['getCurrentUser']()[_0x5872fb('0x2f')],'sectionId':0xca});}],'rpcAgents':[_0x5e26e6('0x4b1'),function(_0xdbe556){const _0x15f513=_0x5e26e6;return _0xdbe556['resolve'](_0x15f513('0x36a'));}]},'authenticate':!![],'permissionId':0x5e6})[_0x5e26e6('0x2598')](_0x5e26e6('0x76c'),{'url':'/queues','controller':_0x5e26e6('0x1770'),'templateUrl':_0xc6997f,'resolve':{'queues':['apiResolver',_0x5e26e6('0xba1'),function(_0x4d89ab,_0x516624){const _0x1bf9f1=_0x5e26e6;return _0x516624['hasRole'](_0x1bf9f1('0x20c2'))?_0x4d89ab[_0x1bf9f1('0xed7')](_0x1bf9f1('0x2730'),{'type':_0x1bf9f1('0x17cd'),'sort':_0x1bf9f1('0xc36'),'limit':0xa,'offset':0x0}):_0x4d89ab[_0x1bf9f1('0xed7')]('userProfile@getResources',{'id':_0x516624[_0x1bf9f1('0x20b2')]()[_0x1bf9f1('0x2f')],'section':_0x1bf9f1('0x1a4c'),'channel':_0x1bf9f1('0xcf2'),'type':'outbound','sort':_0x1bf9f1('0xc36'),'limit':0xa,'page':0x1});}],'userProfile':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x59a90c,_0x5218fa){const _0x4634d9=_0x5e26e6;return _0x5218fa[_0x4634d9('0xca1')](_0x4634d9('0x20c2'))?null:_0x59a90c[_0x4634d9('0xed7')]('userProfile@get',{'fields':'id,name,crudPermissions','id':_0x5218fa[_0x4634d9('0x20b2')]()[_0x4634d9('0x2f')]});}],'userProfileSection':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x4690b3,_0x5bac60){const _0x324b25=_0x5e26e6;return _0x5bac60[_0x324b25('0xca1')](_0x324b25('0x20c2'))?null:_0x4690b3[_0x324b25('0xed7')](_0x324b25('0x360'),{'fields':_0x324b25('0x1f47'),'userProfileId':_0x5bac60[_0x324b25('0x20b2')]()[_0x324b25('0x2f')],'sectionId':0x5dd});}],'rpcQueues':[_0x5e26e6('0x4b1'),function(_0x572751){const _0x452bb6=_0x5e26e6;return _0x572751['resolve'](_0x452bb6('0x1406'));}]},'authenticate':!![],'permissionId':0x5e6})[_0x5e26e6('0x2598')](_0x5e26e6('0xf03'),{'url':_0x5e26e6('0x180c'),'controller':'QueueCallsMotionDialerRealtimeController\x20as\x20vm','templateUrl':_0x27e1ab,'resolve':{'agents':['apiResolver',_0x5e26e6('0xba1'),function(_0x2d3b11,_0x20cfd3){const _0x3ccfa6=_0x5e26e6;return _0x20cfd3['hasRole']('admin')?_0x2d3b11[_0x3ccfa6('0xed7')]('user@get',{'fields':_0x3ccfa6('0x545'),'role':_0x3ccfa6('0x2327'),'nolimit':!![]}):_0x2d3b11[_0x3ccfa6('0xed7')]('userProfile@getResources',{'id':_0x20cfd3[_0x3ccfa6('0x20b2')]()['userProfileId'],'section':_0x3ccfa6('0x1bc0'),'fields':'id,name,role,context','role':_0x3ccfa6('0x2327'),'nolimit':!![]});}],'queues':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x373f93,_0x38c232){const _0x3ca2da=_0x5e26e6;return _0x38c232['hasRole'](_0x3ca2da('0x20c2'))?_0x373f93[_0x3ca2da('0xed7')](_0x3ca2da('0x2730'),{'type':'outbound','sort':_0x3ca2da('0xc36'),'nolimit':!![]}):_0x373f93[_0x3ca2da('0xed7')](_0x3ca2da('0x191b'),{'id':_0x38c232['getCurrentUser']()['userProfileId'],'section':_0x3ca2da('0x1a4c'),'channel':_0x3ca2da('0xcf2'),'type':_0x3ca2da('0x17cd'),'sort':_0x3ca2da('0xc36'),'nolimit':!![]});}],'userProfile':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x3bfe32,_0x305e2c){const _0x125f03=_0x5e26e6;return _0x305e2c[_0x125f03('0xca1')](_0x125f03('0x20c2'))?null:_0x3bfe32[_0x125f03('0xed7')](_0x125f03('0x1464'),{'fields':'id,name,crudPermissions','id':_0x305e2c[_0x125f03('0x20b2')]()[_0x125f03('0x2f')]});}],'userProfileSection':[_0x5e26e6('0x4b1'),'Auth',function(_0x39fe77,_0xe5354f){const _0x248643=_0x5e26e6;return _0xe5354f['hasRole'](_0x248643('0x20c2'))?null:_0x39fe77[_0x248643('0xed7')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0xe5354f['getCurrentUser']()[_0x248643('0x2f')],'sectionId':0x5dd});}],'rpcVoiceQueuesChannels':['apiResolver',function(_0x3724fa){const _0x2a8113=_0x5e26e6;return _0x3724fa[_0x2a8113('0xed7')]('rpc@getVoiceQueuesChannels');}]},'authenticate':!![],'permissionId':0x5e6})['state'](_0x5e26e6('0x294'),{'url':'/abandonedcalls','controller':_0x5e26e6('0xecf'),'templateUrl':_0x59b9a2,'resolve':{'agents':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x58fafc,_0x46c09d){const _0x33f152=_0x5e26e6;return _0x46c09d[_0x33f152('0xca1')](_0x33f152('0x20c2'))?_0x58fafc[_0x33f152('0xed7')](_0x33f152('0x25c9'),{'fields':'id,name,role,context','role':_0x33f152('0x2327'),'nolimit':!![]}):_0x58fafc[_0x33f152('0xed7')]('userProfile@getResources',{'id':_0x46c09d[_0x33f152('0x20b2')]()[_0x33f152('0x2f')],'section':_0x33f152('0x1bc0'),'fields':_0x33f152('0x545'),'role':_0x33f152('0x2327'),'nolimit':!![]});}],'queues':['apiResolver',_0x5e26e6('0xba1'),function(_0x1002cb,_0x204024){const _0x4584de=_0x5e26e6;return _0x204024[_0x4584de('0xca1')](_0x4584de('0x20c2'))?_0x1002cb[_0x4584de('0xed7')](_0x4584de('0x2730'),{'type':_0x4584de('0x17cd'),'sort':_0x4584de('0xc36'),'nolimit':!![]}):_0x1002cb[_0x4584de('0xed7')](_0x4584de('0x191b'),{'id':_0x204024[_0x4584de('0x20b2')]()[_0x4584de('0x2f')],'section':_0x4584de('0x1a4c'),'channel':_0x4584de('0xcf2'),'type':_0x4584de('0x17cd'),'sort':_0x4584de('0xc36'),'nolimit':!![]});}],'dispositions':['apiResolver',_0x5e26e6('0xba1'),function(_0x3aace2,_0xe1a153){const _0x167f44=_0x5e26e6;return _0xe1a153[_0x167f44('0xca1')](_0x167f44('0x20c2'))?_0x3aace2[_0x167f44('0xed7')](_0x167f44('0xfaa'),{'fields':_0x167f44('0x311'),'sort':'-updatedAt','MailAccountId':_0x167f44('0x13c'),'FaxAccountId':_0x167f44('0x13c'),'SmsAccountId':'null','WhatsappAccountId':_0x167f44('0x13c'),'OpenchannelAccountId':'null','ChatWebsiteId':_0x167f44('0x13c'),'ListId':_0x167f44('0x13c'),'nolimit':!![]}):_0x3aace2[_0x167f44('0xed7')](_0x167f44('0x191b'),{'id':_0xe1a153[_0x167f44('0x20b2')]()['userProfileId'],'section':'Dispositions','fields':_0x167f44('0x2157'),'sort':'-updatedAt','MailAccountId':_0x167f44('0x13c'),'FaxAccountId':_0x167f44('0x13c'),'SmsAccountId':'null','WhatsappAccountId':'null','OpenchannelAccountId':'null','ChatWebsiteId':'null','ListId':_0x167f44('0x13c'),'nolimit':!![]});}],'userProfile':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x45f82b,_0x231b15){const _0x1d427d=_0x5e26e6;return _0x231b15['hasRole'](_0x1d427d('0x20c2'))?null:_0x45f82b[_0x1d427d('0xed7')](_0x1d427d('0x1464'),{'fields':_0x1d427d('0x16f'),'id':_0x231b15[_0x1d427d('0x20b2')]()[_0x1d427d('0x2f')]});}],'userProfileSection':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x4361a8,_0x4f8f9c){const _0x8d77f8=_0x5e26e6;return _0x4f8f9c[_0x8d77f8('0xca1')](_0x8d77f8('0x20c2'))?null:_0x4361a8[_0x8d77f8('0xed7')](_0x8d77f8('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x4f8f9c['getCurrentUser']()[_0x8d77f8('0x2f')],'sectionId':0x5dd});}]},'authenticate':!![],'permissionId':0x5e6})['state'](_0x5e26e6('0x2241'),{'url':_0x5e26e6('0x233'),'controller':'QueueParamsMotionDialerRealtimeController\x20as\x20vm','templateUrl':_0x396a9c,'resolve':{'queues':['apiResolver',_0x5e26e6('0xba1'),function(_0x3d8657,_0x1b9645){const _0xe7cd2e=_0x5e26e6;return _0x1b9645[_0xe7cd2e('0xca1')](_0xe7cd2e('0x20c2'))?_0x3d8657['resolve'](_0xe7cd2e('0x2730'),{'type':_0xe7cd2e('0x17cd'),'fields':_0xe7cd2e('0xa10'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x3d8657[_0xe7cd2e('0xed7')]('userProfile@getResources',{'id':_0x1b9645[_0xe7cd2e('0x20b2')]()['userProfileId'],'section':_0xe7cd2e('0x1a4c'),'channel':_0xe7cd2e('0xcf2'),'type':_0xe7cd2e('0x17cd'),'sort':_0xe7cd2e('0xc36'),'nolimit':!![]});}],'userProfile':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x20409d,_0x378195){const _0x162bed=_0x5e26e6;return _0x378195[_0x162bed('0xca1')](_0x162bed('0x20c2'))?null:_0x20409d[_0x162bed('0xed7')]('userProfile@get',{'fields':_0x162bed('0x16f'),'id':_0x378195[_0x162bed('0x20b2')]()[_0x162bed('0x2f')]});}],'userProfileSection':[_0x5e26e6('0x4b1'),'Auth',function(_0x5d0cdc,_0x3ea7de){const _0x49be75=_0x5e26e6;return _0x3ea7de[_0x49be75('0xca1')](_0x49be75('0x20c2'))?null:_0x5d0cdc[_0x49be75('0xed7')](_0x49be75('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x3ea7de[_0x49be75('0x20b2')]()[_0x49be75('0x2f')],'sectionId':0x5dd});}],'rpcQueues':[_0x5e26e6('0x4b1'),function(_0x48afd4){const _0x3f193b=_0x5e26e6;return _0x48afd4[_0x3f193b('0xed7')](_0x3f193b('0x1406'));}]},'authenticate':!![],'permissionId':0x5e6})[_0x5e26e6('0x2598')](_0x5e26e6('0x1fc4'),{'url':_0x5e26e6('0x120d'),'controller':'IvrCampaignsMotionDialerRealtimeController\x20as\x20vm','templateUrl':_0x59ae3c,'resolve':{'campaigns':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x20f264,_0x54cd1a){const _0x488784=_0x5e26e6;return _0x54cd1a['hasRole']('admin')?_0x20f264[_0x488784('0xed7')](_0x488784('0x1c32'),{'sort':_0x488784('0xc36'),'limit':0xa,'offset':0x0}):_0x20f264[_0x488784('0xed7')]('userProfile@getResources',{'id':_0x54cd1a[_0x488784('0x20b2')]()['userProfileId'],'section':_0x488784('0x23db'),'sort':'-updatedAt','limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x5e26e6('0xba1'),function(_0x3bd33d,_0x50af20){const _0x80028f=_0x5e26e6;return _0x50af20[_0x80028f('0xca1')](_0x80028f('0x20c2'))?null:_0x3bd33d['resolve'](_0x80028f('0x1464'),{'fields':'id,name,crudPermissions','id':_0x50af20[_0x80028f('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x5e26e6('0x4b1'),_0x5e26e6('0xba1'),function(_0x4dfaf4,_0x1509f4){const _0x46604c=_0x5e26e6;return _0x1509f4[_0x46604c('0xca1')](_0x46604c('0x20c2'))?null:_0x4dfaf4[_0x46604c('0xed7')]('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x1509f4[_0x46604c('0x20b2')]()[_0x46604c('0x2f')],'sectionId':0x5de});}],'rpcCampaigns':['apiResolver',function(_0x3acfab){const _0xe965e3=_0x5e26e6;return _0x3acfab[_0xe965e3('0xed7')](_0xe965e3('0x1508'));}]},'authenticate':!![],'permissionId':0x5e6});}angular[_0x189033('0x1e26')](_0x189033('0xd4b'),[])[_0x189033('0x272d')](_0x4ebda6)['controller'](_0x189033('0x2789'),_0x59c918)['controller'](_0x189033('0xa2c'),_0x1b8579)[_0x189033('0x1da3')](_0x189033('0x1fbd'),_0x281f1f)[_0x189033('0x1da3')]('QueueCallsMotionDialerRealtimeController',_0x385479)[_0x189033('0x1da3')]('QueueParamsMotionDialerRealtimeController',_0x49f38f)[_0x189033('0x1da3')](_0x189033('0x1419'),_0x419781)[_0x189033('0x1da3')](_0x189033('0x7dc'),_0x3fab47)['factory'](_0x189033('0xa72'),_0x43670f)['controller']('MotionDialerRealtimeController',_0xca98f2);const _0x53ea58=_0x180212['p']+_0x189033('0x2dc'),_0x2fc384=_0x180212['p']+'src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/view.html/view.html',_0xd59b02=_0x180212['p']+_0x189033('0xcc6'),_0x72e765=_0x180212['p']+'src/js/modules/main/apps/motiondialer/views/ivrCampaigns/edit/view.html/view.html';_0x55736e[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0xf0e'),_0x189033('0xaf6'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x55736e(_0x2d1e46,_0x58ff74,_0xc708bb,_0x154cca,_0x28d695,_0x2197ca,_0x3f02e5,_0x291ae4,_0x129c25,_0x1d2910,_0x319891,_0x42a150,_0x4dfdee,_0x20bf38){const _0x403b45=_0x189033,_0x54188a=this;_0x54188a[_0x403b45('0x11ed')]=_0x319891[_0x403b45('0x20b2')](),_0x54188a[_0x403b45('0x17f')]=[],_0x54188a[_0x403b45('0x260a')]=_0x4dfdee,_0x54188a[_0x403b45('0xace')]=_0x42a150,_0x54188a[_0x403b45('0x1134')]=_0x20bf38,_0x54188a[_0x403b45('0x258d')]={},_0x54188a[_0x403b45('0x19b2')]=_0x54188a[_0x403b45('0x260a')]&&_0x54188a[_0x403b45('0x260a')][_0x403b45('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x54188a[_0x403b45('0xf28')]=_0x403b45('0x1c0d'),_0x54188a[_0x403b45('0xaf6')]=angular[_0x403b45('0x1a86')](_0x129c25),_0x54188a[_0x403b45('0xf0e')]=_0x291ae4,_0x54188a[_0x403b45('0x11fe')]=![];!_0x54188a['ivrCampaign']&&(_0x54188a['ivrCampaign']={'active':!![],'type':_0x403b45('0x715'),'dialCheckDuplicateType':'always','dialCutDigit':0x0,'limitCalls':0x1e,'dialRandomLastDigitCallerIdNumber':0x0,'dialOriginateTimeout':0x1e,'dialGlobalMaxRetry':0x4,'dialCongestionMaxRetry':0x3,'dialCongestionRetryFrequency':0x96,'dialBusyMaxRetry':0x3,'dialBusyRetryFrequency':0x96,'dialNoAnswerMaxRetry':0x3,'dialNoAnswerRetryFrequency':0x96,'dialNoSuchNumberMaxRetry':0x3,'dialNoSuchNumberRetryFrequency':0x96,'dialDropMaxRetry':0x3,'dialDropRetryFrequency':0x96,'dialAbandonedMaxRetry':0x3,'dialAbandonedRetryFrequency':0x96,'dialMachineMaxRetry':0x3,'dialMachineRetryFrequency':0x96,'dialAgentRejectMaxRetry':0x3,'dialAgentRejectRetryFrequency':0x96,'dialOrderByScheduledAt':_0x403b45('0xa0d'),'dialGlobalInterval':'07:00-22:00,*,*,*','dialAMDInitialSilence':0x9c4,'dialAMDGreeting':0x5dc,'dialAMDAfterGreetingSilence':0x320,'dialAMDTotalAnalysisTime':0x1388,'dialAMDMinWordLength':0x64,'dialAMDBetweenWordsSilence':0x32,'dialAMDMaximumNumberOfWords':0x3,'dialAMDSilenceThreshold':0x100,'dialAMDMaximumWordLength':0x1388},_0x54188a['title']='MOTIONDIALER.NEW_IVRCAMPAIGN',_0x54188a[_0x403b45('0x11fe')]=!![]);_0x54188a[_0x403b45('0x15f1')]=_0x41d332,_0x54188a[_0x403b45('0x2628')]=_0x2f2d34,_0x54188a[_0x403b45('0x2bd')]=_0x552013,_0x54188a[_0x403b45('0x16b3')]=_0x54db82,_0x54188a[_0x403b45('0xf82')]=_0x2b5416,_0x319891[_0x403b45('0xca1')](_0x403b45('0x20c2'))?_0x1d2910['trunk'][_0x403b45('0x1e6e')]({'fields':'id,name','sort':_0x403b45('0x60a'),'table':_0x403b45('0x26ac')})[_0x403b45('0xe53')][_0x403b45('0x683')](function(_0x3283f){const _0x4401da=_0x403b45;_0x54188a['trunks']=_0x3283f[_0x4401da('0xf5d')]||[];})[_0x403b45('0x130a')](function(_0xa5d05b){const _0x529167=_0x403b45;_0x3f02e5[_0x529167('0x52a')]({'title':_0xa5d05b[_0x529167('0x13ee')]?'API:'+_0xa5d05b[_0x529167('0x13ee')]+_0x529167('0xbf6')+_0xa5d05b[_0x529167('0x24a9')]:_0x529167('0xfd0'),'msg':_0xa5d05b[_0x529167('0x5a5')]?JSON[_0x529167('0x258a')](_0xa5d05b['data']):_0xa5d05b[_0x529167('0x1ff0')]()});}):_0x1d2910['trunk']['get']({'fields':_0x403b45('0xa10'),'sort':_0x403b45('0x60a'),'table':'true'})[_0x403b45('0xe53')][_0x403b45('0x683')](function(_0x48d3f6){const _0x3bc382=_0x403b45;_0x54188a['trunks']=_0x48d3f6[_0x3bc382('0xf5d')]||[];})['then'](function(){const _0x543e79=_0x403b45;return _0x1d2910[_0x543e79('0x22df')]['get']({'userProfileId':_0x54188a[_0x543e79('0x11ed')]['userProfileId'],'sectionId':0x3f3})[_0x543e79('0xe53')];})[_0x403b45('0x683')](function(_0x5b5205){const _0x4d90ad=_0x403b45,_0xcd272c=_0x5b5205&&_0x5b5205[_0x4d90ad('0xf5d')]?_0x5b5205[_0x4d90ad('0xf5d')][0x0]:null;if(!_0xcd272c)_0x54188a[_0x4d90ad('0x20fe')]=[];else{if(!_0xcd272c[_0x4d90ad('0x170')])return _0x1d2910[_0x4d90ad('0xcf7')][_0x4d90ad('0x1e6e')]({'sectionId':_0xcd272c['id']})[_0x4d90ad('0xe53')][_0x4d90ad('0x683')](function(_0x91a08e){const _0x327704=_0x4d90ad,_0x20703d=_0x2e3ca0()[_0x327704('0x386')](_0x91a08e[_0x327704('0xf5d')],function(_0x3ed495){const _0x3a7135=_0x327704;return _0x2e3ca0()[_0x3a7135('0x1c07')](_0x54188a[_0x3a7135('0x20fe')],{'id':_0x3ed495[_0x3a7135('0x832')]});});_0x54188a[_0x327704('0x20fe')][_0x327704('0x1299')](function(_0x40ece4){const _0x412c3f=_0x327704;!_0x2e3ca0()[_0x412c3f('0x7a2')](_0x20703d,['id',_0x40ece4['id']])&&(_0x40ece4[_0x412c3f('0x319')]=![]),_0x20703d[_0x412c3f('0x1fd0')](_0x40ece4);}),_0x54188a[_0x327704('0x20fe')]=_0x20703d;});}})['catch'](function(_0x6843da){const _0x2ad6d6=_0x403b45;_0x3f02e5['error']({'title':_0x6843da['status']?_0x2ad6d6('0x2168')+_0x6843da[_0x2ad6d6('0x13ee')]+_0x2ad6d6('0xbf6')+_0x6843da['statusText']:'SYSTEM:GETtrunks','msg':_0x6843da[_0x2ad6d6('0x5a5')]?JSON[_0x2ad6d6('0x258a')](_0x6843da[_0x2ad6d6('0x5a5')]):_0x6843da['toString']()});}),_0x319891['hasRole']('admin')?_0x1d2910[_0x403b45('0x27ea')][_0x403b45('0x1e6e')]({'fields':_0x403b45('0xa10'),'sort':_0x403b45('0x60a')})[_0x403b45('0xe53')]['then'](function(_0x4b74e0){const _0xb6d915=_0x403b45;_0x54188a[_0xb6d915('0x1248')]=_0x4b74e0[_0xb6d915('0xf5d')]||[];})['catch'](function(_0x262000){const _0x391130=_0x403b45;_0x3f02e5[_0x391130('0x52a')]({'title':_0x262000[_0x391130('0x13ee')]?_0x391130('0x2168')+_0x262000['status']+_0x391130('0xbf6')+_0x262000['statusText']:_0x391130('0xd0e'),'msg':_0x262000[_0x391130('0x5a5')]?JSON[_0x391130('0x258a')](_0x262000[_0x391130('0x5a5')]):_0x262000['toString']()});}):_0x1d2910[_0x403b45('0x27ea')][_0x403b45('0x1e6e')]({'fields':_0x403b45('0xa10'),'sort':'name'})[_0x403b45('0xe53')]['then'](function(_0x3c5441){const _0x2c2884=_0x403b45;_0x54188a['projects']=_0x3c5441[_0x2c2884('0xf5d')]||[];})[_0x403b45('0x683')](function(){const _0x118c62=_0x403b45;return _0x1d2910['userProfileSection'][_0x118c62('0x1e6e')]({'userProfileId':_0x54188a['currentUser']['userProfileId'],'sectionId':0x44f})['$promise'];})[_0x403b45('0x683')](function(_0x3dd07e){const _0x15e313=_0x403b45,_0x2ced93=_0x3dd07e&&_0x3dd07e[_0x15e313('0xf5d')]?_0x3dd07e[_0x15e313('0xf5d')][0x0]:null;if(!_0x2ced93){const _0x5078b4=[];let _0xdf9602=null;_0x54188a['ivrCampaign']&&(_0xdf9602=_0x2e3ca0()[_0x15e313('0x1c07')](_0x54188a[_0x15e313('0x1248')],{'id':Number(_0x54188a[_0x15e313('0xaf6')][_0x15e313('0x16a5')])}));for(let _0x23b636=0x0;_0x23b636<_0x54188a[_0x15e313('0x1248')][_0x15e313('0x1564')];_0x23b636++){_0xdf9602&&_0x54188a['projects'][_0x23b636]['id']===_0xdf9602['id']&&(_0x54188a[_0x15e313('0x1248')][_0x23b636][_0x15e313('0x319')]=![],_0x5078b4[_0x15e313('0x1fd0')](_0x54188a[_0x15e313('0x1248')][_0x23b636]));}_0x54188a[_0x15e313('0x1248')]=_0x5078b4;}else{if(!_0x2ced93[_0x15e313('0x170')])return _0x1d2910[_0x15e313('0xcf7')][_0x15e313('0x1e6e')]({'sectionId':_0x2ced93['id']})[_0x15e313('0xe53')]['then'](function(_0x4f36ee){const _0x4d27a1=_0x15e313,_0x4243c7=_0x2e3ca0()[_0x4d27a1('0x386')](_0x4f36ee[_0x4d27a1('0xf5d')],function(_0x206414){const _0x2d30d0=_0x4d27a1;return _0x2e3ca0()[_0x2d30d0('0x1c07')](_0x54188a[_0x2d30d0('0x1248')],{'id':_0x206414[_0x2d30d0('0x832')]});});let _0x5eaded=null;_0x54188a[_0x4d27a1('0xaf6')]&&(_0x5eaded=_0x2e3ca0()['find'](_0x54188a[_0x4d27a1('0x1248')],{'id':Number(_0x54188a[_0x4d27a1('0xaf6')][_0x4d27a1('0x16a5')])}));if(_0x5eaded&&!_0x2e3ca0()[_0x4d27a1('0x7a2')](_0x4243c7,['id',_0x5eaded['id']])){const _0x416f77=_0x2e3ca0()['find'](_0x54188a['projects'],{'id':_0x5eaded['id']});_0x416f77[_0x4d27a1('0x319')]=![],_0x4243c7[_0x4d27a1('0x1fd0')](_0x416f77);}_0x54188a[_0x4d27a1('0x1248')]=_0x4243c7;});}})[_0x403b45('0x130a')](function(_0x264fa8){const _0x53f5e3=_0x403b45;_0x3f02e5['error']({'title':_0x264fa8[_0x53f5e3('0x13ee')]?_0x53f5e3('0x2168')+_0x264fa8[_0x53f5e3('0x13ee')]+'\x20-\x20'+_0x264fa8[_0x53f5e3('0x24a9')]:_0x53f5e3('0x616'),'msg':_0x264fa8[_0x53f5e3('0x5a5')]?JSON[_0x53f5e3('0x258a')](_0x264fa8[_0x53f5e3('0x5a5')]):_0x264fa8[_0x53f5e3('0x1ff0')]()});}),_0x319891['hasRole'](_0x403b45('0x20c2'))?_0x1d2910['interval']['get']({'fields':_0x403b45('0xa10'),'sort':'name','IntervalId':_0x403b45('0x13c')})[_0x403b45('0xe53')][_0x403b45('0x683')](function(_0x41992b){const _0x544359=_0x403b45;_0x54188a[_0x544359('0x115c')]=_0x41992b[_0x544359('0xf5d')]||[];})[_0x403b45('0x130a')](function(_0x4b8f80){const _0x2eff5c=_0x403b45;_0x3f02e5[_0x2eff5c('0x52a')]({'title':_0x4b8f80['status']?_0x2eff5c('0x2168')+_0x4b8f80[_0x2eff5c('0x13ee')]+'\x20-\x20'+_0x4b8f80['statusText']:_0x2eff5c('0x27e3'),'msg':_0x4b8f80[_0x2eff5c('0x5a5')]?JSON[_0x2eff5c('0x258a')](_0x4b8f80[_0x2eff5c('0x5a5')]):_0x4b8f80[_0x2eff5c('0x1ff0')]()});}):_0x1d2910['interval']['get']({'fields':_0x403b45('0xa10'),'sort':_0x403b45('0x60a'),'IntervalId':'null'})['$promise']['then'](function(_0x56fbe1){const _0x1f2dd4=_0x403b45;_0x54188a[_0x1f2dd4('0x115c')]=_0x56fbe1[_0x1f2dd4('0xf5d')]||[];})['then'](function(){const _0x42dff1=_0x403b45;return _0x1d2910[_0x42dff1('0x22df')][_0x42dff1('0x1e6e')]({'userProfileId':_0x54188a[_0x42dff1('0x11ed')][_0x42dff1('0x2f')],'sectionId':0x3ec})[_0x42dff1('0xe53')];})['then'](function(_0x4163a7){const _0x452b2c=_0x403b45,_0x5c9e64=_0x4163a7&&_0x4163a7['rows']?_0x4163a7[_0x452b2c('0xf5d')][0x0]:null;if(!_0x5c9e64){const _0x2e7c60=[];let _0x219dda=null;_0x54188a[_0x452b2c('0xaf6')]&&(_0x219dda=_0x2e3ca0()[_0x452b2c('0x1c07')](_0x54188a[_0x452b2c('0x115c')],{'id':Number(_0x54188a[_0x452b2c('0xaf6')][_0x452b2c('0x5ae')])}));for(let _0x3aadbd=0x0;_0x3aadbd<_0x54188a['interval'][_0x452b2c('0x1564')];_0x3aadbd++){_0x219dda&&_0x54188a[_0x452b2c('0x115c')][_0x3aadbd]['id']===_0x219dda['id']&&(_0x54188a[_0x452b2c('0x115c')][_0x3aadbd][_0x452b2c('0x319')]=![],_0x2e7c60[_0x452b2c('0x1fd0')](_0x54188a[_0x452b2c('0x115c')][_0x3aadbd]));}_0x54188a[_0x452b2c('0x115c')]=_0x2e7c60;}else{if(!_0x5c9e64['autoAssociation'])return _0x1d2910[_0x452b2c('0xcf7')]['get']({'sectionId':_0x5c9e64['id']})[_0x452b2c('0xe53')]['then'](function(_0x1c54b8){const _0x14638b=_0x452b2c,_0x3bbc66=_0x2e3ca0()['map'](_0x1c54b8['rows'],function(_0x5d4db4){const _0x11d364=a0_0x4e0a;return _0x2e3ca0()[_0x11d364('0x1c07')](_0x54188a[_0x11d364('0x115c')],{'id':_0x5d4db4['resourceId']});});let _0x1d4e25=null;_0x54188a[_0x14638b('0xaf6')]&&(_0x1d4e25=_0x2e3ca0()['find'](_0x54188a['interval'],{'id':Number(_0x54188a[_0x14638b('0xaf6')][_0x14638b('0x5ae')])}));if(_0x1d4e25&&!_0x2e3ca0()[_0x14638b('0x7a2')](_0x3bbc66,['id',_0x1d4e25['id']])){const _0x2f71c0=_0x2e3ca0()[_0x14638b('0x1c07')](_0x54188a[_0x14638b('0x115c')],{'id':_0x1d4e25['id']});_0x2f71c0[_0x14638b('0x319')]=![],_0x3bbc66[_0x14638b('0x1fd0')](_0x2f71c0);}_0x54188a['interval']=_0x3bbc66;});}})['catch'](function(_0x4bf703){const _0x371b8c=_0x403b45;_0x3f02e5[_0x371b8c('0x52a')]({'title':_0x4bf703[_0x371b8c('0x13ee')]?_0x371b8c('0x2168')+_0x4bf703[_0x371b8c('0x13ee')]+_0x371b8c('0xbf6')+_0x4bf703[_0x371b8c('0x24a9')]:_0x371b8c('0x203'),'msg':_0x4bf703[_0x371b8c('0x5a5')]?JSON[_0x371b8c('0x258a')](_0x4bf703[_0x371b8c('0x5a5')]):_0x4bf703[_0x371b8c('0x1ff0')]()});});function _0x41d332(){const _0x446725=_0x403b45;_0x54188a['errors']=[],_0x1d2910['campaign'][_0x446725('0xb0a')](_0x54188a[_0x446725('0xaf6')])[_0x446725('0xe53')][_0x446725('0x683')](function(_0x2db46d){const _0x614c37=_0x446725;_0x54188a[_0x614c37('0xf0e')][_0x614c37('0x1167')](_0x2db46d[_0x614c37('0x24e1')]()),_0x3f02e5[_0x614c37('0x53')]({'title':_0x614c37('0xfb'),'msg':_0x54188a[_0x614c37('0xaf6')]['name']?_0x54188a[_0x614c37('0xaf6')][_0x614c37('0x60a')]+_0x614c37('0x14b5'):''}),_0x2b5416(_0x2db46d);})[_0x446725('0x130a')](function(_0x520ede){const _0x1e6022=_0x446725;if(_0x520ede[_0x1e6022('0x5a5')]&&_0x520ede[_0x1e6022('0x5a5')][_0x1e6022('0x17f')]&&_0x520ede[_0x1e6022('0x5a5')]['errors']['length']){_0x54188a[_0x1e6022('0x17f')]=_0x520ede[_0x1e6022('0x5a5')][_0x1e6022('0x17f')]||[{'message':_0x520ede[_0x1e6022('0x1ff0')](),'type':_0x1e6022('0x226')}];for(let _0x2cdbb5=0x0;_0x2cdbb5<_0x520ede['data'][_0x1e6022('0x17f')]['length'];_0x2cdbb5+=0x1){_0x3f02e5['error']({'title':_0x520ede[_0x1e6022('0x5a5')]['errors'][_0x2cdbb5][_0x1e6022('0xcf0')],'msg':_0x520ede['data']['errors'][_0x2cdbb5][_0x1e6022('0x8c2')]});}}else _0x3f02e5[_0x1e6022('0x52a')]({'title':_0x520ede[_0x1e6022('0x13ee')]?_0x1e6022('0x2168')+_0x520ede[_0x1e6022('0x13ee')]+'\x20-\x20'+_0x520ede[_0x1e6022('0x24a9')]:_0x1e6022('0x226'),'msg':_0x520ede[_0x1e6022('0x5a5')]?JSON['stringify'](_0x520ede[_0x1e6022('0x5a5')][_0x1e6022('0x8c2')]):_0x520ede['toString']()});});}function _0x2f2d34(){const _0x2d837d=_0x403b45;_0x54188a['errors']=[],_0x1d2910[_0x2d837d('0x6e9')]['update']({'id':_0x54188a['ivrCampaign']['id']},_0x54188a[_0x2d837d('0xaf6')])['$promise'][_0x2d837d('0x683')](function(_0x214a14){const _0x34c039=_0x2d837d,_0xca3f08=_0x2e3ca0()['find'](_0x54188a['ivrCampaigns'],{'id':_0x214a14['id']});_0xca3f08&&_0x2e3ca0()[_0x34c039('0xf22')](_0xca3f08,_0x2e3ca0()[_0x34c039('0x24d0')](_0x214a14[_0x34c039('0x24e1')](),_0x2e3ca0()['keys'](_0xca3f08))),_0x3f02e5[_0x34c039('0x53')]({'title':_0x34c039('0x117a'),'msg':_0x54188a[_0x34c039('0xaf6')][_0x34c039('0x60a')]?_0x54188a[_0x34c039('0xaf6')][_0x34c039('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x2b5416(_0x214a14);})[_0x2d837d('0x130a')](function(_0x620317){const _0x20020d=_0x2d837d;if(_0x620317[_0x20020d('0x5a5')]&&_0x620317[_0x20020d('0x5a5')][_0x20020d('0x17f')]&&_0x620317[_0x20020d('0x5a5')][_0x20020d('0x17f')][_0x20020d('0x1564')]){_0x54188a[_0x20020d('0x17f')]=_0x620317[_0x20020d('0x5a5')][_0x20020d('0x17f')]||[{'message':_0x620317[_0x20020d('0x1ff0')](),'type':_0x20020d('0x1ad6')}];for(let _0x150853=0x0;_0x150853<_0x620317['data'][_0x20020d('0x17f')][_0x20020d('0x1564')];_0x150853++){_0x3f02e5[_0x20020d('0x52a')]({'title':_0x620317[_0x20020d('0x5a5')][_0x20020d('0x17f')][_0x150853][_0x20020d('0xcf0')],'msg':_0x620317[_0x20020d('0x5a5')][_0x20020d('0x17f')][_0x150853][_0x20020d('0x8c2')]});}}else _0x3f02e5[_0x20020d('0x52a')]({'title':_0x620317[_0x20020d('0x13ee')]?'API:'+_0x620317[_0x20020d('0x13ee')]+_0x20020d('0xbf6')+_0x620317['statusText']:_0x20020d('0x1ad6'),'msg':_0x620317[_0x20020d('0x5a5')]?JSON['stringify'](_0x620317[_0x20020d('0x5a5')]['message']):_0x620317[_0x20020d('0x1ff0')]()});});}function _0x552013(_0x17250e){const _0x1256e7=_0x403b45;_0x54188a[_0x1256e7('0x17f')]=[];const _0x2cb0c1=_0x154cca[_0x1256e7('0x1c6f')]()[_0x1256e7('0xf28')](_0x1256e7('0x4d'))[_0x1256e7('0xa6a')](_0x1256e7('0x529'))[_0x1256e7('0x1040')](_0x1256e7('0x27a8'))['ok'](_0x1256e7('0x2307'))[_0x1256e7('0x19fb')]('Cancel')[_0x1256e7('0xe42')](_0x17250e);_0x154cca[_0x1256e7('0x1d4')](_0x2cb0c1)[_0x1256e7('0x683')](function(){const _0x552c00=_0x1256e7;_0x1d2910[_0x552c00('0x6e9')][_0x552c00('0xd7e')]({'id':_0x54188a['ivrCampaign']['id']})[_0x552c00('0xe53')][_0x552c00('0x683')](function(){const _0x28246e=_0x552c00;_0x2e3ca0()[_0x28246e('0x3ec')](_0x54188a['ivrCampaigns'],{'id':_0x54188a[_0x28246e('0xaf6')]['id']}),_0x3f02e5[_0x28246e('0x53')]({'title':'IvrCampaign\x20properly\x20deleted!','msg':(_0x54188a[_0x28246e('0xaf6')][_0x28246e('0x60a')]||_0x28246e('0xaf6'))+_0x28246e('0x194d')}),_0x2b5416(_0x54188a[_0x28246e('0xaf6')]);})[_0x552c00('0x130a')](function(_0x49051f){const _0x1f3747=_0x552c00;if(_0x49051f[_0x1f3747('0x5a5')]&&_0x49051f[_0x1f3747('0x5a5')][_0x1f3747('0x17f')]&&_0x49051f[_0x1f3747('0x5a5')][_0x1f3747('0x17f')][_0x1f3747('0x1564')]){_0x54188a[_0x1f3747('0x17f')]=_0x49051f[_0x1f3747('0x5a5')][_0x1f3747('0x17f')]||[{'message':_0x49051f['toString'](),'type':_0x1f3747('0x226d')}];for(let _0x2ba99a=0x0;_0x2ba99a<_0x49051f[_0x1f3747('0x5a5')][_0x1f3747('0x17f')][_0x1f3747('0x1564')];_0x2ba99a++){_0x3f02e5[_0x1f3747('0x52a')]({'title':_0x49051f['data'][_0x1f3747('0x17f')][_0x2ba99a][_0x1f3747('0xcf0')],'msg':_0x49051f['data'][_0x1f3747('0x17f')][_0x2ba99a][_0x1f3747('0x8c2')]});}}else _0x3f02e5[_0x1f3747('0x52a')]({'title':_0x49051f['status']?_0x1f3747('0x2168')+_0x49051f['status']+_0x1f3747('0xbf6')+_0x49051f[_0x1f3747('0x24a9')]:_0x1f3747('0x226d'),'msg':_0x49051f[_0x1f3747('0x5a5')]?JSON[_0x1f3747('0x258a')](_0x49051f[_0x1f3747('0x5a5')][_0x1f3747('0x8c2')]):_0x49051f[_0x1f3747('0x8c2')]||_0x49051f[_0x1f3747('0x1ff0')]()});});},function(){});}function _0x54db82(_0x5bf7a6){return _0x5bf7a6===null?undefined:new Date(_0x5bf7a6);}function _0x2b5416(_0x56cf49){const _0x50ea49=_0x403b45;_0x154cca[_0x50ea49('0x1715')](_0x56cf49);}}const _0x206842=_0x55736e;_0x417b98[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),'ivrCampaign',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0xba1'),'crudPermissions'];function _0x417b98(_0x3d0c99,_0x4c6c34,_0x25a00f,_0x18ef97,_0x8cf345,_0x2e2f52,_0x21bd96,_0x5ccbf8,_0x421fbc){const _0x352148=_0x189033,_0x25de29=this;_0x25de29[_0x352148('0x11ed')]=_0x5ccbf8[_0x352148('0x20b2')](),_0x25de29[_0x352148('0xaf6')]=_0x8cf345,_0x25de29['crudPermissions']=_0x421fbc,_0x25de29[_0x352148('0x6d1')]=_0x352148('0x204c'),_0x25de29['getApi']=_0x352148('0x1582'),_0x25de29[_0x352148('0x407')]='addBlackLists',_0x25de29[_0x352148('0x17e8')]=_0x352148('0x2027'),_0x25de29[_0x352148('0x1996')]=[],_0x25de29[_0x352148('0x1c47')]=[],_0x25de29[_0x352148('0x1378')]=[],_0x25de29['startingAllowedItems']=[],_0x25de29['startingSelectedItems']=[],_0x25de29['pendingChanges']=![],_0x25de29['loading']=![],_0x25de29['dualMultiselectOptions']={'readOnly':!_0x25de29[_0x352148('0x1134')][_0x352148('0x1978')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':![],'orderBy':_0x352148('0x60a'),'line1':_0x352148('0x60a'),'line2':'','line3':'','labelAll':_0x2e2f52[_0x352148('0x2728')](_0x352148('0x425')),'labelSelected':_0x2e2f52['instant'](_0x352148('0x577')),'transferCallback':function(){const _0x131f33=_0x352148,_0x38b72a=_0x2e3ca0()[_0x131f33('0x25cb')](_0x25de29[_0x131f33('0x23a7')],_0x25de29[_0x131f33('0x1378')],'id');_0x25de29[_0x131f33('0x2106')]=_0x2e3ca0()['isEmpty'](_0x38b72a)?![]:!![];}},_0x25de29[_0x352148('0x1dd2')]=_0x598439,_0x25de29[_0x352148('0x21fd')]=_0x2e6d88,_0x25de29[_0x352148('0xf82')]=_0x2f04cb;function _0x598439(){const _0x296be1=_0x352148;return _0x5ccbf8[_0x296be1('0xca1')]('admin')?_0x18a3ea()[_0x296be1('0x130a')](function(_0x4f04e8){const _0x2bb0b4=_0x296be1;_0x25a00f[_0x2bb0b4('0x52a')]({'title':_0x4f04e8['status']?_0x2bb0b4('0x2168')+_0x4f04e8['status']+'\x20-\x20'+_0x4f04e8[_0x2bb0b4('0x24a9')]:_0x2bb0b4('0xa2a'),'msg':_0x4f04e8[_0x2bb0b4('0x13ee')]?JSON['stringify'](_0x4f04e8[_0x2bb0b4('0x5a5')]):_0x4f04e8['toString']()});}):_0x214480()[_0x296be1('0x683')](function(_0x14d00e){const _0x524f33=_0x296be1;return _0x25de29[_0x524f33('0x1aa')]=_0x14d00e,_0x18a3ea();})[_0x296be1('0x130a')](function(_0x17b263){const _0x2634b2=_0x296be1;_0x25a00f[_0x2634b2('0x52a')]({'title':_0x17b263['status']?_0x2634b2('0x2168')+_0x17b263[_0x2634b2('0x13ee')]+_0x2634b2('0xbf6')+_0x17b263[_0x2634b2('0x24a9')]:_0x2634b2('0xa2a'),'msg':_0x17b263[_0x2634b2('0x13ee')]?JSON[_0x2634b2('0x258a')](_0x17b263[_0x2634b2('0x5a5')]):_0x17b263[_0x2634b2('0x1ff0')]()});});}function _0x214480(){return _0x4c6c34(function(_0x36a81f,_0x18c1a1){const _0x7f37c3=a0_0x4e0a;_0x18ef97[_0x7f37c3('0x22df')][_0x7f37c3('0x1e6e')]({'userProfileId':_0x25de29['currentUser'][_0x7f37c3('0x2f')],'name':'Lists'})[_0x7f37c3('0xe53')][_0x7f37c3('0x683')](function(_0x307178){const _0x25a700=_0x307178&&_0x307178['rows']?_0x307178['rows'][0x0]:null;_0x36a81f(_0x25a700);})[_0x7f37c3('0x130a')](function(_0x527a9c){_0x18c1a1(_0x527a9c);});});}function _0x18a3ea(){return _0x4c6c34(function(_0x44f754,_0x33fc8b){const _0x17155a=a0_0x4e0a;return _0x3936a2()[_0x17155a('0x683')](function(_0x4a2ac9){const _0x24aab7=_0x17155a;return _0x25de29['items']=_0x4a2ac9['rows']?_0x4a2ac9[_0x24aab7('0xf5d')]:[],_0x5ccbf8['hasRole']('admin')?_0x4a2ac9:_0x25de29[_0x24aab7('0x1aa')]?_0x25de29[_0x24aab7('0x1aa')]['autoAssociation']?_0x4a2ac9:_0x50aa96():null;})[_0x17155a('0x683')](function(_0x2f7827){const _0x86a4d=_0x17155a,_0x492275=_0x2f7827&&_0x2f7827[_0x86a4d('0xf5d')]?_0x2f7827[_0x86a4d('0xf5d')]:[];return _0x25de29[_0x86a4d('0x1c47')]=_0x2e3ca0()[_0x86a4d('0x386')](_0x492275,function(_0x5a1746){const _0x4f0b23=_0x86a4d;return _0x2e3ca0()[_0x4f0b23('0x1c07')](_0x25de29[_0x4f0b23('0x1996')],{'id':_0x5ccbf8[_0x4f0b23('0xca1')](_0x4f0b23('0x20c2'))||_0x25de29[_0x4f0b23('0x1aa')][_0x4f0b23('0x170')]?_0x5a1746['id']:_0x5a1746[_0x4f0b23('0x832')]});}),_0x25de29[_0x86a4d('0x125e')]=angular[_0x86a4d('0x1a86')](_0x25de29[_0x86a4d('0x1c47')]),_0x25de29['items'][_0x86a4d('0x1299')](function(_0x5e4518){const _0x3e3486=_0x86a4d,_0x1034aa=_0x2e3ca0()['find'](_0x25de29[_0x3e3486('0x1c47')],{'id':_0x5e4518['id']});_0x25de29[_0x3e3486('0x11ed')][_0x3e3486('0xecb')]===_0x3e3486('0x20c2')?_0x5e4518['isValid']=!![]:_0x5e4518['isValid']=typeof _0x1034aa!=='undefined'?!![]:![];}),_0x25a44a();})[_0x17155a('0x683')](function(_0x31fe9e){const _0x12299b=_0x17155a,_0x32dc6f=_0x31fe9e&&_0x31fe9e[_0x12299b('0xf5d')]?_0x31fe9e[_0x12299b('0xf5d')]:[];_0x25de29[_0x12299b('0x1378')]=_0x2e3ca0()['map'](_0x32dc6f,function(_0x62d446){const _0x3c5277=_0x12299b;return _0x2e3ca0()[_0x3c5277('0x1c07')](_0x25de29['items'],{'id':_0x62d446['id']});}),_0x25de29[_0x12299b('0x23a7')]=angular[_0x12299b('0x1a86')](_0x25de29[_0x12299b('0x1378')]),_0x25de29[_0x12299b('0x169f')]['selectedItems']=_0x25de29[_0x12299b('0x1378')],_0x25de29[_0x12299b('0x169f')]['items']=_0x2e3ca0()[_0x12299b('0x461')](_0x25de29[_0x12299b('0x1c47')],_0x25de29[_0x12299b('0x169f')][_0x12299b('0x1378')],'id'),_0x44f754();})[_0x17155a('0x130a')](function(_0x1312b4){_0x33fc8b(_0x1312b4);});});}function _0x50aa96(){return _0x4c6c34(function(_0xba6ca2,_0x445b6e){const _0x37b089=a0_0x4e0a;return _0x18ef97[_0x37b089('0xcf7')][_0x37b089('0x1e6e')]({'sectionId':_0x25de29[_0x37b089('0x1aa')]['id'],'nolimit':!![]})[_0x37b089('0xe53')][_0x37b089('0x683')](function(_0x2f28d9){_0xba6ca2(_0x2f28d9);})[_0x37b089('0x130a')](function(_0x522cc8){_0x445b6e(_0x522cc8);});});}function _0x25a44a(){return _0x4c6c34(function(_0x12dc30,_0x26f15d){const _0x3968ea=a0_0x4e0a,_0x4eab86=_0x18ef97[_0x25de29[_0x3968ea('0x6d1')]];return _0x4eab86[_0x25de29[_0x3968ea('0x578')]]({'id':_0x25de29['ivrCampaign']['id'],'fields':'id,name','nolimit':!![]})[_0x3968ea('0xe53')][_0x3968ea('0x683')](function(_0x3acf2c){_0x12dc30(_0x3acf2c);})['catch'](function(_0x42771e){_0x26f15d(_0x42771e);});});}function _0x3936a2(){return _0x4c6c34(function(_0x5e8f2a,_0x4235b9){const _0x11ced7=a0_0x4e0a;return _0x18ef97[_0x11ced7('0x259b')][_0x11ced7('0x1e6e')]({'fields':_0x11ced7('0xa10'),'nolimit':!![]})[_0x11ced7('0xe53')][_0x11ced7('0x683')](function(_0x109ea0){_0x5e8f2a(_0x109ea0);})['catch'](function(_0x22f588){_0x4235b9(_0x22f588);});});}function _0x30a291(_0x298a73){return _0x4c6c34(function(_0x33f9cf,_0x589f30){const _0x375a3a=a0_0x4e0a;if(_0x2e3ca0()[_0x375a3a('0x173f')](_0x298a73))_0x33f9cf();else{const _0x120897=_0x18ef97[_0x25de29[_0x375a3a('0x6d1')]];_0x120897[_0x25de29[_0x375a3a('0x407')]]({'id':_0x25de29['ivrCampaign']['id'],'ids':_0x2e3ca0()[_0x375a3a('0x386')](_0x298a73,'id')})[_0x375a3a('0xe53')][_0x375a3a('0x683')](function(){_0x33f9cf();})[_0x375a3a('0x130a')](function(_0x1ed435){_0x589f30(_0x1ed435);});}});}function _0x2b9218(_0x5da6c2){return _0x4c6c34(function(_0x17ca82,_0x199be1){const _0x41456a=a0_0x4e0a;if(_0x2e3ca0()[_0x41456a('0x173f')](_0x5da6c2))_0x17ca82();else{const _0x52f2ac=_0x18ef97[_0x25de29[_0x41456a('0x6d1')]];_0x52f2ac[_0x25de29['removeApi']]({'id':_0x25de29[_0x41456a('0xaf6')]['id'],'ids':_0x2e3ca0()[_0x41456a('0x386')](_0x5da6c2,'id')})[_0x41456a('0xe53')][_0x41456a('0x683')](function(){_0x17ca82();})[_0x41456a('0x130a')](function(_0x44ce36){_0x199be1(_0x44ce36);});}});}function _0x2e6d88(){const _0x302c30=_0x352148;_0x25de29['loading']=!![];const _0x590b32=_0x2e3ca0()[_0x302c30('0x461')](_0x25de29['startingSelectedItems'],_0x25de29['selectedItems'],'id'),_0x5b4981=_0x2e3ca0()[_0x302c30('0x461')](_0x25de29['selectedItems'],_0x25de29['startingSelectedItems'],'id');return _0x2b9218(_0x590b32)[_0x302c30('0x683')](function(){return _0x30a291(_0x5b4981);})[_0x302c30('0x683')](function(){const _0x24f0a8=_0x302c30;_0x25de29[_0x24f0a8('0x2106')]=![],_0x25de29['startingAllowedItems']=angular['copy'](_0x25de29[_0x24f0a8('0x1c47')]),_0x25de29['startingSelectedItems']=angular[_0x24f0a8('0x1a86')](_0x25de29[_0x24f0a8('0x1378')]),_0x25a00f[_0x24f0a8('0x53')]({'title':_0x24f0a8('0xd28'),'msg':_0x24f0a8('0x195b')});})[_0x302c30('0x130a')](function(_0x231590){const _0x594e42=_0x302c30;_0x25a00f[_0x594e42('0x52a')]({'title':_0x231590[_0x594e42('0x13ee')]?_0x594e42('0x2168')+_0x231590[_0x594e42('0x13ee')]+_0x594e42('0xbf6')+_0x231590['statusText']:_0x594e42('0x1b71'),'msg':_0x231590[_0x594e42('0x13ee')]?JSON[_0x594e42('0x258a')](_0x231590[_0x594e42('0x5a5')]):_0x231590[_0x594e42('0x1ff0')]()});})[_0x302c30('0x2874')](function(){_0x25de29['loading']=![];});}function _0x2f04cb(){const _0x2c6538=_0x352148;_0x3d0c99[_0x2c6538('0x1715')]();}}const _0x1875bd=_0x417b98;_0x41d9e4[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x938'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xaf6'),_0x189033('0xf0e'),_0x189033('0x1d08')];function _0x41d9e4(_0x5c51f8,_0x388ce4,_0x121e13,_0x1b0603,_0x5c1448,_0x2cfedb,_0x3ebaa3){const _0x3fcbb7=_0x189033,_0x16aa1b=this;_0x16aa1b[_0x3fcbb7('0x11fe')]=!![],_0x16aa1b['ivrCampaign']=angular[_0x3fcbb7('0x1a86')](_0x5c1448),_0x16aa1b[_0x3fcbb7('0xf0e')]=_0x2cfedb,_0x16aa1b[_0x3fcbb7('0xf28')]=_0x3ebaa3[_0x3fcbb7('0x2728')](_0x3fcbb7('0xd1a'));_0x5c1448&&_0x5c1448[_0x3fcbb7('0x60a')]&&(_0x16aa1b[_0x3fcbb7('0xf28')]+=':\x20'+_0x5c1448[_0x3fcbb7('0x60a')]);_0x16aa1b[_0x3fcbb7('0x520')]=_0x2c1901,_0x16aa1b['closeDialog']=_0xcdf983;function _0x2c1901(){const _0x27ec7e=_0x3fcbb7;return _0x1b0603[_0x27ec7e('0x6e9')]['clone']({'id':_0x5c1448['id']},_0x16aa1b[_0x27ec7e('0xaf6')])[_0x27ec7e('0xe53')][_0x27ec7e('0x683')](function(_0x4d536f){const _0x269bb2=_0x27ec7e;_0x16aa1b[_0x269bb2('0xf0e')][_0x269bb2('0x1167')](_0x4d536f[_0x269bb2('0x24e1')]()),_0x121e13[_0x269bb2('0x53')]({'title':_0x269bb2('0x17a2'),'msg':_0x16aa1b['ivrCampaign'][_0x269bb2('0x60a')]?_0x16aa1b[_0x269bb2('0xaf6')]['name']+_0x269bb2('0x640'):''}),_0x388ce4['go']('app.motiondialer.ivrCampaigns.edit',{'id':_0x4d536f['id']}),_0xcdf983(_0x4d536f);})[_0x27ec7e('0x130a')](function(_0x5439cf){const _0x3b5db4=_0x27ec7e;if(_0x5439cf[_0x3b5db4('0x5a5')]&&_0x5439cf['data'][_0x3b5db4('0x17f')]&&_0x5439cf[_0x3b5db4('0x5a5')][_0x3b5db4('0x17f')][_0x3b5db4('0x1564')]){_0x16aa1b['errors']=_0x5439cf['data']['errors']||[{'message':_0x5439cf[_0x3b5db4('0x1ff0')](),'type':_0x3b5db4('0x28e')}];for(let _0x2abd05=0x0;_0x2abd05<_0x5439cf['data'][_0x3b5db4('0x17f')][_0x3b5db4('0x1564')];_0x2abd05+=0x1){_0x121e13[_0x3b5db4('0x52a')]({'title':_0x5439cf[_0x3b5db4('0x5a5')]['errors'][_0x2abd05][_0x3b5db4('0xcf0')],'msg':_0x5439cf[_0x3b5db4('0x5a5')][_0x3b5db4('0x17f')][_0x2abd05]['message']});}}else _0x121e13[_0x3b5db4('0x52a')]({'title':_0x5439cf['status']?_0x3b5db4('0x2168')+_0x5439cf[_0x3b5db4('0x13ee')]+_0x3b5db4('0xbf6')+_0x5439cf[_0x3b5db4('0x24a9')]:_0x3b5db4('0x28e'),'msg':_0x5439cf[_0x3b5db4('0x5a5')]?JSON[_0x3b5db4('0x258a')](_0x5439cf[_0x3b5db4('0x5a5')][_0x3b5db4('0x8c2')]):_0x5439cf[_0x3b5db4('0x1ff0')]()});});}function _0xcdf983(_0x531a20){const _0x2afa89=_0x3fcbb7;_0x5c51f8[_0x2afa89('0x1715')](_0x531a20);}}const _0x355c8c=_0x41d9e4;_0x4789c1[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),'$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x4789c1(_0x29ff6b,_0x45a642,_0x2e1e02,_0x325d3b,_0x416ce7,_0x262d69,_0x38d961,_0x1aa835,_0x5b09f6,_0x425230,_0x59cb38){const _0x1d4495=_0x189033,_0x1d6e6e=this;_0x1d6e6e[_0x1d4495('0x11ed')]=_0x59cb38[_0x1d4495('0x20b2')](),_0x1d6e6e[_0x1d4495('0xaf6')]={},_0x1d6e6e[_0x1d4495('0x1ac8')]={'count':0x0,'rows':[]},_0x1d6e6e[_0x1d4495('0x24ae')]=[],_0x1d6e6e[_0x1d4495('0x1134')],_0x1d6e6e['query']={'fields':_0x1d4495('0x6c0'),'sort':'-id','limit':0xa,'page':0x1},_0x1d6e6e[_0x1d4495('0x12f3')]=_0x1fb773,_0x1d6e6e['deleteConfirm']=_0x35ace4,_0x1d6e6e[_0x1d4495('0x53')]=_0x386964,_0x1d6e6e[_0x1d4495('0x1f5')]=_0xb2d354,_0x1d6e6e[_0x1d4495('0x1d56')]=_0x5f17df,_0x1d6e6e['deleteIvrCampaignHopperBlack']=_0x39e9ec,_0x1d6e6e[_0x1d4495('0x2466')]=_0x48104d;function _0x1fb773(_0x8be84c,_0x322ced){const _0x25af58=_0x1d4495;_0x1d6e6e[_0x25af58('0xaf6')]=_0x8be84c,_0x1d6e6e[_0x25af58('0x1134')]=typeof _0x322ced!==_0x25af58('0x1867')?_0x322ced:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x1d6e6e['query'][_0x25af58('0x11c')]=_0x1d6e6e[_0x25af58('0xaf6')]['id'],_0x1d6e6e[_0x25af58('0x23a2')]['id']=_0x1d6e6e['ivrCampaign']['id'],_0xb2d354();}function _0x35ace4(_0x5632f2,_0x59d451){const _0x151c34=_0x1d4495,_0x4985dc=_0x38d961[_0x151c34('0x1c6f')]()[_0x151c34('0xf28')](_0x151c34('0x1435'))['htmlContent'](''+(_0x5632f2[_0x151c34('0x60a')]||_0x5632f2['id']&&_0x2e3ca0()[_0x151c34('0x2711')](_0x151c34('0x22ed'))+_0x5632f2['id']||'hopperBlack')+_0x151c34('0x20f1')+_0x151c34('0x1ee7'))[_0x151c34('0x1040')](_0x151c34('0x1a71'))['targetEvent'](_0x59d451)['ok']('OK')[_0x151c34('0x19fb')]('CANCEL');_0x38d961[_0x151c34('0x1d4')](_0x4985dc)[_0x151c34('0x683')](function(){_0x39e9ec(_0x5632f2);},function(){const _0x45f318=_0x151c34;console['log'](_0x45f318('0x16b8'));});}function _0x386964(_0x1b902e){const _0x307dc1=_0x1d4495;_0x1d6e6e[_0x307dc1('0x1ac8')]=_0x1b902e||{'count':0x0,'rows':[]};}function _0xb2d354(){const _0x1be909=_0x1d4495;_0x1d6e6e[_0x1be909('0x23a2')][_0x1be909('0x1cc8')]=(_0x1d6e6e[_0x1be909('0x23a2')][_0x1be909('0xdf8')]-0x1)*_0x1d6e6e[_0x1be909('0x23a2')][_0x1be909('0x6f0')],_0x1d6e6e[_0x1be909('0x1883')]=_0x425230['campaign']['getHopperBlacks'](_0x1d6e6e[_0x1be909('0x23a2')],_0x386964)[_0x1be909('0xe53')];}function _0x39e9ec(_0x1d5215){const _0x514cae=_0x1d4495;_0x425230[_0x514cae('0x4bf')][_0x514cae('0xd7e')]({'id':_0x1d5215['id']})[_0x514cae('0xe53')]['then'](function(){const _0x5e57cc=_0x514cae;_0x2e3ca0()['remove'](_0x1d6e6e[_0x5e57cc('0x1ac8')][_0x5e57cc('0xf5d')],{'id':_0x1d5215['id']}),_0x1d6e6e['ivrCampaignHopperBlacks'][_0x5e57cc('0x50d')]-=0x1,!_0x1d6e6e['ivrCampaignHopperBlacks'][_0x5e57cc('0xf5d')][_0x5e57cc('0x1564')]&&_0xb2d354(),_0x5b09f6[_0x5e57cc('0x53')]({'title':_0x5e57cc('0x1fe6'),'msg':_0x1d5215[_0x5e57cc('0x60a')]?_0x1d5215['name']+'\x20has\x20been\x20deleted!':''});})[_0x514cae('0x130a')](function(_0x1a0c7b){const _0x19fb2b=_0x514cae;if(_0x1a0c7b[_0x19fb2b('0x5a5')]&&_0x1a0c7b[_0x19fb2b('0x5a5')][_0x19fb2b('0x17f')]&&_0x1a0c7b[_0x19fb2b('0x5a5')]['errors'][_0x19fb2b('0x1564')]){_0x1d6e6e[_0x19fb2b('0x17f')]=_0x1a0c7b[_0x19fb2b('0x5a5')][_0x19fb2b('0x17f')]||[{'message':_0x1a0c7b[_0x19fb2b('0x1ff0')](),'type':_0x19fb2b('0x104')}];for(let _0x3363cd=0x0;_0x3363cd<_0x1a0c7b[_0x19fb2b('0x5a5')][_0x19fb2b('0x17f')][_0x19fb2b('0x1564')];_0x3363cd++){_0x5b09f6[_0x19fb2b('0x52a')]({'title':_0x1a0c7b[_0x19fb2b('0x5a5')][_0x19fb2b('0x17f')][_0x3363cd]['type'],'msg':_0x1a0c7b[_0x19fb2b('0x5a5')][_0x19fb2b('0x17f')][_0x3363cd]['message']});}}else _0x5b09f6[_0x19fb2b('0x52a')]({'title':_0x1a0c7b['status']?_0x19fb2b('0x2168')+_0x1a0c7b['status']+_0x19fb2b('0xbf6')+_0x1a0c7b[_0x19fb2b('0x24a9')]:_0x19fb2b('0x104'),'msg':_0x1a0c7b['data']?JSON[_0x19fb2b('0x258a')](_0x1a0c7b[_0x19fb2b('0x5a5')]['message']):_0x1a0c7b['message']||_0x1a0c7b[_0x19fb2b('0x1ff0')]()});});}function _0x5f17df(){const _0x4e37ee=_0x1d4495,_0x510dfa=angular[_0x4e37ee('0x1a86')](_0x1d6e6e[_0x4e37ee('0x24ae')]);return _0x1d6e6e[_0x4e37ee('0x24ae')]=[],_0x510dfa;}function _0x48104d(_0x38e5fa){const _0x228b21=_0x1d4495,_0x3c2209=_0x38d961['confirm']()[_0x228b21('0xf28')](_0x228b21('0x2477'))['htmlContent'](''+_0x1d6e6e[_0x228b21('0x24ae')][_0x228b21('0x1564')]+_0x228b21('0x93c')+'\x20will\x20be\x20deleted.')[_0x228b21('0x1040')]('delete\x20hopperBlacks')[_0x228b21('0xe42')](_0x38e5fa)['ok']('OK')[_0x228b21('0x19fb')](_0x228b21('0x16b8'));_0x38d961['show'](_0x3c2209)['then'](function(){const _0x745815=_0x228b21;_0x1d6e6e[_0x745815('0x24ae')][_0x745815('0x1299')](function(_0x54f186){_0x39e9ec(_0x54f186);}),_0x1d6e6e[_0x745815('0x24ae')]=[];});}let _0x3dfbbc=!![],_0x1f834a=0x1;_0x45a642[_0x1d4495('0x186d')](_0x1d4495('0x229'),function(_0x2e0e6e,_0x37b2ba){const _0x34fe4a=_0x1d4495;_0x3dfbbc?_0x262d69(function(){_0x3dfbbc=![];}):(!_0x37b2ba&&(_0x1f834a=_0x1d6e6e[_0x34fe4a('0x23a2')]['page']),_0x2e0e6e!==_0x37b2ba&&(_0x1d6e6e[_0x34fe4a('0x23a2')][_0x34fe4a('0xdf8')]=0x1),!_0x2e0e6e&&(_0x1d6e6e[_0x34fe4a('0x23a2')]['page']=_0x1f834a),_0xb2d354());});}const _0x57abff=_0x4789c1;_0x486480[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x486480(_0x197bc9,_0x412c46,_0x500271,_0x200463,_0x52fafd,_0x1e5704,_0x3cef8c,_0x3dfef4,_0x1b9d13,_0x308a71,_0x8d1505){const _0x910a5c=_0x189033,_0x3b3d76=this;_0x3b3d76['currentUser']=_0x8d1505['getCurrentUser'](),_0x3b3d76[_0x910a5c('0x6d5')]={},_0x3b3d76[_0x910a5c('0xaf6')]={},_0x3b3d76[_0x910a5c('0x4ad')]={'count':0x0,'rows':[]},_0x3b3d76['selectedIvrCampaignHopperFinals']=[],_0x3b3d76[_0x910a5c('0x1134')],_0x3b3d76[_0x910a5c('0x23a2')]={'fields':_0x910a5c('0xb5a'),'sort':_0x910a5c('0x24aa'),'limit':0xa,'page':0x1},_0x3b3d76['init']=_0xd45a94,_0x3b3d76[_0x910a5c('0x26eb')]=_0x1e04db,_0x3b3d76['success']=_0x1f402a,_0x3b3d76['getIvrCampaignHopperFinals']=_0x1e20f5,_0x3b3d76[_0x910a5c('0xbb8')]=_0x599629,_0x3b3d76[_0x910a5c('0xcd2')]=_0x1d9177,_0x3b3d76[_0x910a5c('0x18df')]=_0x5e5363,_0x3b3d76[_0x910a5c('0x66a')]=_0xea2249,_0x3b3d76[_0x910a5c('0x3fb')]=_0x3466d6,_0x3b3d76['countContactsIvrCampaignHopperFinal']=_0x105996,_0x3b3d76['moveConfirm']=_0x59c9d9,_0x3b3d76[_0x910a5c('0xa7')]=_0x55b149;function _0xd45a94(_0xc7a34c,_0x2a537e){const _0x56daab=_0x910a5c;_0x3b3d76[_0x56daab('0xaf6')]=_0xc7a34c,_0x3b3d76[_0x56daab('0x1134')]=typeof _0x2a537e!==_0x56daab('0x1867')?_0x2a537e:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3b3d76[_0x56daab('0x23a2')][_0x56daab('0x11c')]=_0x3b3d76['ivrCampaign']['id'],_0x3b3d76['query']['id']=_0x3b3d76[_0x56daab('0xaf6')]['id'],_0x1e20f5();}function _0x1e04db(_0x2d8aea,_0x4f3053){const _0x107513=_0x910a5c,_0x3db532=_0x3cef8c[_0x107513('0x1c6f')]()[_0x107513('0xf28')](_0x107513('0x1682'))[_0x107513('0x26e3')](_0x107513('0xed5')+(_0x2d8aea[_0x107513('0x60a')]||_0x2d8aea['id']&&_0x2e3ca0()[_0x107513('0x2711')](_0x107513('0x943'))+_0x2d8aea['id']||_0x107513('0x2412'))+_0x107513('0x20f1')+_0x107513('0x1ee7'))[_0x107513('0x1040')]('delete\x20hopperFinal')[_0x107513('0xe42')](_0x4f3053)['ok']('OK')[_0x107513('0x19fb')](_0x107513('0x16b8'));_0x3cef8c['show'](_0x3db532)[_0x107513('0x683')](function(){_0x1d9177(_0x2d8aea);},function(){const _0x1ec577=_0x107513;console[_0x1ec577('0x1b2b')]('CANCEL');});}function _0x1f402a(_0x172046){const _0x59da92=_0x910a5c;_0x3b3d76[_0x59da92('0x4ad')]=_0x172046||{'count':0x0,'rows':[]};}function _0x1e20f5(){const _0x42afb1=_0x910a5c;_0x3b3d76[_0x42afb1('0x23a2')][_0x42afb1('0x1cc8')]=(_0x3b3d76['query'][_0x42afb1('0xdf8')]-0x1)*_0x3b3d76[_0x42afb1('0x23a2')]['limit'],_0x3b3d76['promise']=_0x308a71['campaign'][_0x42afb1('0x77b')](_0x3b3d76[_0x42afb1('0x23a2')],_0x1f402a)['$promise'];}function _0x1d9177(_0x319980){const _0x35b276=_0x910a5c;_0x308a71[_0x35b276('0x2412')][_0x35b276('0xd7e')]({'id':_0x319980['id']})['$promise'][_0x35b276('0x683')](function(){const _0x2c52be=_0x35b276;_0x2e3ca0()[_0x2c52be('0x3ec')](_0x3b3d76['ivrCampaignHopperFinals']['rows'],{'id':_0x319980['id']}),_0x3b3d76[_0x2c52be('0x4ad')]['count']-=0x1,!_0x3b3d76[_0x2c52be('0x4ad')][_0x2c52be('0xf5d')][_0x2c52be('0x1564')]&&_0x1e20f5(),_0x1b9d13[_0x2c52be('0x53')]({'title':_0x2c52be('0x2382'),'msg':_0x319980[_0x2c52be('0x60a')]?_0x319980[_0x2c52be('0x60a')]+_0x2c52be('0x194d'):''});})['catch'](function(_0x513b6d){const _0x1ef486=_0x35b276;if(_0x513b6d[_0x1ef486('0x5a5')]&&_0x513b6d[_0x1ef486('0x5a5')][_0x1ef486('0x17f')]&&_0x513b6d['data']['errors']['length']){_0x3b3d76[_0x1ef486('0x17f')]=_0x513b6d[_0x1ef486('0x5a5')][_0x1ef486('0x17f')]||[{'message':_0x513b6d[_0x1ef486('0x1ff0')](),'type':_0x1ef486('0x104')}];for(let _0x3b24eb=0x0;_0x3b24eb<_0x513b6d[_0x1ef486('0x5a5')]['errors'][_0x1ef486('0x1564')];_0x3b24eb++){_0x1b9d13[_0x1ef486('0x52a')]({'title':_0x513b6d[_0x1ef486('0x5a5')][_0x1ef486('0x17f')][_0x3b24eb][_0x1ef486('0xcf0')],'msg':_0x513b6d[_0x1ef486('0x5a5')][_0x1ef486('0x17f')][_0x3b24eb][_0x1ef486('0x8c2')]});}}else _0x1b9d13[_0x1ef486('0x52a')]({'title':_0x513b6d[_0x1ef486('0x13ee')]?_0x1ef486('0x2168')+_0x513b6d['status']+'\x20-\x20'+_0x513b6d[_0x1ef486('0x24a9')]:'SYSTEM:GETcampaign','msg':_0x513b6d[_0x1ef486('0x5a5')]?JSON[_0x1ef486('0x258a')](_0x513b6d[_0x1ef486('0x5a5')][_0x1ef486('0x8c2')]):_0x513b6d['message']||_0x513b6d[_0x1ef486('0x1ff0')]()});});}function _0x599629(){const _0x2af450=_0x910a5c,_0x3b7b91=angular[_0x2af450('0x1a86')](_0x3b3d76[_0x2af450('0x20c4')]);return _0x3b3d76[_0x2af450('0x20c4')]=[],_0x3b7b91;}function _0x5e5363(_0x1fcdb4){const _0x4f0929=_0x910a5c,_0x3f9846=_0x3cef8c[_0x4f0929('0x1c6f')]()[_0x4f0929('0xf28')](_0x4f0929('0x2352'))[_0x4f0929('0x26e3')](_0x4f0929('0xed5')+_0x3b3d76[_0x4f0929('0x20c4')][_0x4f0929('0x1564')]+_0x4f0929('0x93c')+'\x20will\x20be\x20deleted.')[_0x4f0929('0x1040')]('delete\x20hopperFinals')[_0x4f0929('0xe42')](_0x1fcdb4)['ok']('OK')[_0x4f0929('0x19fb')](_0x4f0929('0x16b8'));_0x3cef8c['show'](_0x3f9846)[_0x4f0929('0x683')](function(){const _0x1dbd1a=_0x4f0929;_0x3b3d76['selectedIvrCampaignHopperFinals'][_0x1dbd1a('0x1299')](function(_0x2ac141){_0x1d9177(_0x2ac141);}),_0x3b3d76['selectedIvrCampaignHopperFinals']=[];});}function _0x3466d6(_0x235bc6){const _0x59ee57=_0x910a5c;_0x308a71['cmHopperFinal'][_0x59ee57('0x3fb')]({'id':_0x3b3d76[_0x59ee57('0x23a2')]['id'],'state':_0x235bc6})[_0x59ee57('0xe53')][_0x59ee57('0x683')](function(_0x4181d7){const _0x218aac=_0x59ee57;_0x2e3ca0()[_0x218aac('0x8f2')](_0x4181d7)&&_0x2e3ca0()[_0x218aac('0x8f2')](_0x4181d7[0x0])?_0x1b9d13['info']({'title':_0x218aac('0x209f'),'msg':'0'}):_0x1b9d13['info']({'title':_0x218aac('0x209f'),'msg':JSON[_0x218aac('0x258a')](_0x4181d7[0x0][_0x218aac('0x1dbf')])});})[_0x59ee57('0x130a')](function(_0x3721ee){const _0x32b9a4=_0x59ee57;_0x1b9d13[_0x32b9a4('0x52a')]({'title':_0x3721ee[_0x32b9a4('0x13ee')]?_0x32b9a4('0x2168')+_0x3721ee[_0x32b9a4('0x13ee')]+_0x32b9a4('0xbf6')+_0x3721ee['statusText']:_0x32b9a4('0xa42'),'msg':_0x3721ee[_0x32b9a4('0x5a5')]?JSON['stringify'](_0x3721ee['data']['message']):_0x3721ee[_0x32b9a4('0x8c2')]||_0x3721ee['toString']()});});}function _0x105996(_0x486d95){const _0x5b715d=_0x910a5c;_0x308a71['cmHopperFinal'][_0x5b715d('0x523')]({'id':_0x486d95})[_0x5b715d('0xe53')][_0x5b715d('0x683')](function(_0x27dcce){const _0x1d5e48=_0x5b715d;_0x2e3ca0()['merge'](_0x3b3d76[_0x1d5e48('0x6d5')],_0x27dcce[0x0]);})['catch'](function(_0x307196){const _0x707aeb=_0x5b715d;_0x1b9d13[_0x707aeb('0x52a')]({'title':_0x307196['status']?_0x707aeb('0x2168')+_0x307196[_0x707aeb('0x13ee')]+_0x707aeb('0xbf6')+_0x307196['statusText']:'SYSTEM:GETcampaign','msg':_0x307196['data']?JSON[_0x707aeb('0x258a')](_0x307196[_0x707aeb('0x5a5')][_0x707aeb('0x8c2')]):_0x307196[_0x707aeb('0x8c2')]||_0x307196[_0x707aeb('0x1ff0')]()});});}function _0x55b149(_0x1bad4b){const _0x356e7c=_0x910a5c,_0x16960e=_0x3cef8c[_0x356e7c('0x1c6f')]()[_0x356e7c('0xf28')](_0x356e7c('0x13d4'))['htmlContent'](_0x356e7c('0x150f')+_0x356e7c('0x44e'))[_0x356e7c('0x1040')]('Restore\x20Contacts')[_0x356e7c('0xe42')](_0x1bad4b)['ok']('OK')[_0x356e7c('0x19fb')](_0x356e7c('0x16b8'));_0x3cef8c[_0x356e7c('0x1d4')](_0x16960e)[_0x356e7c('0x683')](function(){const _0x3ed332=_0x356e7c;_0x3b3d76[_0x3ed332('0x20c4')]['forEach'](function(_0x5d81db){_0xea2249(_0x5d81db);}),_0x3b3d76[_0x3ed332('0x20c4')]=[];});}function _0x59c9d9(_0x32b4f1,_0x55c440){const _0x221550=_0x910a5c,_0x561618=_0x3cef8c[_0x221550('0x1c6f')]()[_0x221550('0xf28')](_0x221550('0x73d'))[_0x221550('0x26e3')](_0x221550('0xed5')+_0x221550('0x1309')+''+_0x221550('0x44e'))[_0x221550('0x1040')](_0x221550('0xed9'))['targetEvent'](_0x55c440)['ok']('OK')[_0x221550('0x19fb')]('CANCEL');_0x3cef8c[_0x221550('0x1d4')](_0x561618)[_0x221550('0x683')](function(){_0xea2249(_0x32b4f1);},function(){const _0x8c7a61=_0x221550;console[_0x8c7a61('0x1b2b')](_0x8c7a61('0x16b8'));});}function _0xc9a035(_0x3a2518){const _0x4787a0=_0x910a5c,_0x51e2a3={};return _0x51e2a3[_0x4787a0('0xd31')]=_0x3a2518['calleridnum'],_0x51e2a3['scheduledat']=_0x1aaf93()()['format'](_0x4787a0('0x865')),_0x51e2a3[_0x4787a0('0x1e2c')]=0x0,_0x51e2a3[_0x4787a0('0xbfb')]=0x0,_0x51e2a3['countnoanswerretry']=0x0,_0x51e2a3[_0x4787a0('0x10d2')]=0x0,_0x51e2a3[_0x4787a0('0x670')]=_0x3a2518[_0x4787a0('0x670')],_0x51e2a3[_0x4787a0('0x1e4f')]=_0x3a2518[_0x4787a0('0x1e4f')],_0x51e2a3['UserId']=_0x3a2518['deleted']?null:_0x3a2518[_0x4787a0('0x10c5')],_0x51e2a3['VoiceQueueId']=_0x3a2518[_0x4787a0('0x19ec')],_0x51e2a3[_0x4787a0('0x11c')]=_0x3a2518[_0x4787a0('0x11c')],_0x51e2a3[_0x4787a0('0xe1e')]=_0x3a2518[_0x4787a0('0x202f')]?0x3:0x2,_0x51e2a3[_0x4787a0('0x202f')]=_0x3a2518[_0x4787a0('0x202f')]?!![]:![],_0x51e2a3;}function _0x323d71(_0x259975){const _0x447b1e=_0x910a5c,_0x2904b7={};return _0x2904b7[_0x447b1e('0x11a5')]=_0x259975[_0x447b1e('0x11a5')],_0x2904b7[_0x447b1e('0x554')]=_0x259975['calleridname'],_0x2904b7[_0x447b1e('0x1ff9')]=_0x1aaf93()()[_0x447b1e('0x26dd')]('YYYY-MM-DD\x20HH:mm:ss'),_0x2904b7[_0x447b1e('0x1e2c')]=_0x259975[_0x447b1e('0x1e2c')],_0x2904b7[_0x447b1e('0xbfb')]=_0x259975[_0x447b1e('0xbfb')],_0x2904b7[_0x447b1e('0x284c')]=_0x259975[_0x447b1e('0x284c')],_0x2904b7[_0x447b1e('0x10d2')]=_0x259975['countglobal'],_0x2904b7[_0x447b1e('0x670')]=_0x259975[_0x447b1e('0x670')],_0x2904b7['ListId']=_0x259975[_0x447b1e('0x1e4f')],_0x2904b7[_0x447b1e('0x10c5')]=_0x8d1505[_0x447b1e('0x20b2')]()['id'],_0x2904b7[_0x447b1e('0x19ec')]=_0x259975['VoiceQueueId'],_0x2904b7['CampaignId']=_0x259975[_0x447b1e('0x11c')],_0x2904b7[_0x447b1e('0xd26')]=_0x1aaf93()()['format'](_0x447b1e('0x865')),_0x2904b7[_0x447b1e('0x1d1b')]=!![],_0x2904b7[_0x447b1e('0x2598')]=0x19,_0x2904b7[_0x447b1e('0x2419')]='Restored',_0x2904b7['campaign']=_0x259975[_0x447b1e('0x6e9')],_0x2904b7['campaigntype']=_0x259975['VoiceQueueId']?_0x447b1e('0x660'):_0x447b1e('0x715'),_0x2904b7;}function _0xea2249(_0x13c460){const _0x253d0a=_0x910a5c;_0x308a71[_0x253d0a('0x163f')]['checkContactHopper'](_0x13c460)['$promise'][_0x253d0a('0x683')](function(_0x9bc032){const _0x2f0ff4=_0x253d0a;_0x1b9d13['info']({'title':_0x2f0ff4('0x1e8a'),'msg':'Contact\x20ID\x20'+_0x9bc032['ContactId']});})['catch'](function(_0x4a8933){const _0x29f8a5=_0x253d0a;_0x4a8933[_0x29f8a5('0x5a5')]==='Not\x20Found'?_0x308a71['cmHopper']['save'](_0xc9a035(_0x13c460))[_0x29f8a5('0xe53')][_0x29f8a5('0x683')](function(_0x4c56e3){const _0x1f6534=_0x29f8a5;_0x1b9d13['info']({'title':_0x1f6534('0xb08'),'msg':_0x1f6534('0x2a3')+_0x4c56e3[_0x1f6534('0x670')]}),_0x4c56e3[_0x1f6534('0x670')]&&_0x308a71['cmHopperHistory'][_0x1f6534('0xb0a')](_0x323d71(_0x13c460));})[_0x29f8a5('0x130a')](function(_0x3d559c){const _0xa81e26=_0x29f8a5;!_0x2e3ca0()[_0xa81e26('0x8f2')](_0x3d559c[_0xa81e26('0x5a5')])&&_0x3d559c[_0xa81e26('0x5a5')][_0xa81e26('0x8c2')]===_0xa81e26('0x22f3')?_0x1b9d13['info']({'title':_0xa81e26('0x1e8a'),'msg':'Contact\x20ID\x20'+_0x13c460['ContactId']}):_0x1b9d13[_0xa81e26('0x52a')]({'title':_0x3d559c[_0xa81e26('0x13ee')]?_0xa81e26('0x2168')+_0x3d559c[_0xa81e26('0x13ee')]+_0xa81e26('0xbf6')+_0x3d559c[_0xa81e26('0x24a9')]:'SYSTEM:GETvoiceQueue','msg':_0x3d559c[_0xa81e26('0x5a5')]?JSON[_0xa81e26('0x258a')](_0x3d559c[_0xa81e26('0x5a5')][_0xa81e26('0x8c2')]):_0x3d559c[_0xa81e26('0x8c2')]||_0x3d559c[_0xa81e26('0x1ff0')]()});}):_0x1b9d13[_0x29f8a5('0x52a')]({'title':_0x4a8933[_0x29f8a5('0x13ee')]?_0x29f8a5('0x2168')+_0x4a8933[_0x29f8a5('0x13ee')]+'\x20-\x20'+_0x4a8933[_0x29f8a5('0x24a9')]:_0x29f8a5('0xa42'),'msg':_0x4a8933['data']?JSON[_0x29f8a5('0x258a')](_0x4a8933[_0x29f8a5('0x5a5')]['message']):_0x4a8933[_0x29f8a5('0x8c2')]||_0x4a8933[_0x29f8a5('0x1ff0')]()});});}let _0x55ecb4=!![],_0x36145f=0x1;_0x412c46[_0x910a5c('0x186d')](_0x910a5c('0x229'),function(_0x4ddd06,_0x24f817){const _0x2e1686=_0x910a5c;_0x55ecb4?_0x1e5704(function(){_0x55ecb4=![];}):(!_0x24f817&&(_0x36145f=_0x3b3d76[_0x2e1686('0x23a2')]['page']),_0x4ddd06!==_0x24f817&&(_0x3b3d76[_0x2e1686('0x23a2')]['page']=0x1),!_0x4ddd06&&(_0x3b3d76[_0x2e1686('0x23a2')][_0x2e1686('0xdf8')]=_0x36145f),_0x1e20f5());});}const _0x261006=_0x486480;_0x194eb0[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$document',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x194eb0(_0x3ab3a6,_0x576949,_0x3b7268,_0x1f3cc7,_0x59edc9,_0x2fbf34,_0x5d7a9d,_0x24c932,_0x3d4f8d,_0x53be17,_0x1354cb){const _0x54e041=_0x189033,_0x219d0a=this;_0x219d0a[_0x54e041('0x11ed')]=_0x1354cb[_0x54e041('0x20b2')](),_0x219d0a[_0x54e041('0xaf6')]={},_0x219d0a[_0x54e041('0x1077')]={'count':0x0,'rows':[]},_0x219d0a['selectedIvrCampaignHopperHistories']=[],_0x219d0a[_0x54e041('0x1134')],_0x219d0a[_0x54e041('0x23a2')]={'fields':_0x54e041('0x583'),'sort':_0x54e041('0x24aa'),'limit':0xa,'page':0x1},_0x219d0a[_0x54e041('0x12f3')]=_0x890924,_0x219d0a[_0x54e041('0x26eb')]=_0x2b4e2c,_0x219d0a[_0x54e041('0x53')]=_0x32e1c4,_0x219d0a[_0x54e041('0x724')]=_0x53d157,_0x219d0a[_0x54e041('0x2f7')]=_0x121ab4,_0x219d0a['deleteIvrCampaignHopperHistory']=_0xad39bd,_0x219d0a[_0x54e041('0xadc')]=_0x107584;function _0x890924(_0x215635,_0x4a9cdc){const _0x278c2d=_0x54e041;_0x219d0a[_0x278c2d('0xaf6')]=_0x215635,_0x219d0a[_0x278c2d('0x1134')]=typeof _0x4a9cdc!=='undefined'?_0x4a9cdc:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x219d0a['query'][_0x278c2d('0x11c')]=_0x219d0a[_0x278c2d('0xaf6')]['id'],_0x219d0a[_0x278c2d('0x23a2')]['id']=_0x219d0a[_0x278c2d('0xaf6')]['id'],_0x53d157();}function _0x2b4e2c(_0x1cd9cb,_0x4c50a3){const _0x2b36de=_0x54e041,_0x22397f=_0x5d7a9d[_0x2b36de('0x1c6f')]()[_0x2b36de('0xf28')](_0x2b36de('0x226e'))[_0x2b36de('0x26e3')](_0x2b36de('0xed5')+(_0x1cd9cb[_0x2b36de('0x60a')]||_0x1cd9cb['id']&&_0x2e3ca0()[_0x2b36de('0x2711')]('hopperHistory\x20#')+_0x1cd9cb['id']||_0x2b36de('0xd37'))+_0x2b36de('0x20f1')+_0x2b36de('0x1ee7'))[_0x2b36de('0x1040')](_0x2b36de('0x11dc'))[_0x2b36de('0xe42')](_0x4c50a3)['ok']('OK')[_0x2b36de('0x19fb')](_0x2b36de('0x16b8'));_0x5d7a9d['show'](_0x22397f)[_0x2b36de('0x683')](function(){_0xad39bd(_0x1cd9cb);},function(){const _0x1ade61=_0x2b36de;console[_0x1ade61('0x1b2b')]('CANCEL');});}function _0x32e1c4(_0x4d2d06){const _0x544ead=_0x54e041;_0x219d0a[_0x544ead('0x1077')]=_0x4d2d06||{'count':0x0,'rows':[]};}function _0x53d157(){const _0x182025=_0x54e041;_0x219d0a[_0x182025('0x23a2')]['offset']=(_0x219d0a['query']['page']-0x1)*_0x219d0a[_0x182025('0x23a2')]['limit'],_0x219d0a[_0x182025('0x1883')]=_0x53be17[_0x182025('0x6e9')][_0x182025('0x816')](_0x219d0a[_0x182025('0x23a2')],_0x32e1c4)[_0x182025('0xe53')];}function _0xad39bd(_0x3c0f04){const _0x4bc10e=_0x54e041;_0x53be17[_0x4bc10e('0xd37')][_0x4bc10e('0xd7e')]({'id':_0x3c0f04['id']})[_0x4bc10e('0xe53')]['then'](function(){const _0xfaafae=_0x4bc10e;_0x2e3ca0()['remove'](_0x219d0a[_0xfaafae('0x1077')][_0xfaafae('0xf5d')],{'id':_0x3c0f04['id']}),_0x219d0a[_0xfaafae('0x1077')][_0xfaafae('0x50d')]-=0x1,!_0x219d0a[_0xfaafae('0x1077')][_0xfaafae('0xf5d')][_0xfaafae('0x1564')]&&_0x53d157(),_0x3d4f8d[_0xfaafae('0x53')]({'title':_0xfaafae('0xc78'),'msg':_0x3c0f04[_0xfaafae('0x60a')]?_0x3c0f04[_0xfaafae('0x60a')]+_0xfaafae('0x194d'):''});})[_0x4bc10e('0x130a')](function(_0x568a5e){const _0x57199c=_0x4bc10e;if(_0x568a5e[_0x57199c('0x5a5')]&&_0x568a5e['data'][_0x57199c('0x17f')]&&_0x568a5e[_0x57199c('0x5a5')][_0x57199c('0x17f')][_0x57199c('0x1564')]){_0x219d0a['errors']=_0x568a5e[_0x57199c('0x5a5')]['errors']||[{'message':_0x568a5e['toString'](),'type':_0x57199c('0x104')}];for(let _0x4bd16d=0x0;_0x4bd16d<_0x568a5e[_0x57199c('0x5a5')][_0x57199c('0x17f')][_0x57199c('0x1564')];_0x4bd16d++){_0x3d4f8d[_0x57199c('0x52a')]({'title':_0x568a5e[_0x57199c('0x5a5')][_0x57199c('0x17f')][_0x4bd16d]['type'],'msg':_0x568a5e['data'][_0x57199c('0x17f')][_0x4bd16d][_0x57199c('0x8c2')]});}}else _0x3d4f8d[_0x57199c('0x52a')]({'title':_0x568a5e[_0x57199c('0x13ee')]?_0x57199c('0x2168')+_0x568a5e['status']+_0x57199c('0xbf6')+_0x568a5e[_0x57199c('0x24a9')]:_0x57199c('0x104'),'msg':_0x568a5e[_0x57199c('0x5a5')]?JSON['stringify'](_0x568a5e['data'][_0x57199c('0x8c2')]):_0x568a5e['message']||_0x568a5e[_0x57199c('0x1ff0')]()});});}function _0x121ab4(){const _0x432fb4=_0x54e041,_0x464dfe=angular[_0x432fb4('0x1a86')](_0x219d0a['selectedIvrCampaignHopperHistories']);return _0x219d0a[_0x432fb4('0x362')]=[],_0x464dfe;}function _0x107584(_0x4cfd57){const _0x3b3c5b=_0x54e041,_0x53af7b=_0x5d7a9d[_0x3b3c5b('0x1c6f')]()['title'](_0x3b3c5b('0x14d1'))[_0x3b3c5b('0x26e3')](_0x3b3c5b('0xed5')+_0x219d0a[_0x3b3c5b('0x362')][_0x3b3c5b('0x1564')]+_0x3b3c5b('0x93c')+'\x20will\x20be\x20deleted.')[_0x3b3c5b('0x1040')]('delete\x20hopperHistories')['targetEvent'](_0x4cfd57)['ok']('OK')[_0x3b3c5b('0x19fb')]('CANCEL');_0x5d7a9d['show'](_0x53af7b)[_0x3b3c5b('0x683')](function(){const _0x1b4cef=_0x3b3c5b;_0x219d0a[_0x1b4cef('0x362')][_0x1b4cef('0x1299')](function(_0x4b339f){_0xad39bd(_0x4b339f);}),_0x219d0a[_0x1b4cef('0x362')]=[];});}let _0x15cbab=!![],_0xbb26da=0x1;_0x576949['$watch'](_0x54e041('0x229'),function(_0x476f6b,_0x197de2){const _0x4a926e=_0x54e041;_0x15cbab?_0x2fbf34(function(){_0x15cbab=![];}):(!_0x197de2&&(_0xbb26da=_0x219d0a['query'][_0x4a926e('0xdf8')]),_0x476f6b!==_0x197de2&&(_0x219d0a[_0x4a926e('0x23a2')][_0x4a926e('0xdf8')]=0x1),!_0x476f6b&&(_0x219d0a[_0x4a926e('0x23a2')][_0x4a926e('0xdf8')]=_0xbb26da),_0x53d157());});}const _0x3f776a=_0x194eb0;_0x25fc6b[_0x189033('0x14be')]=['$cookies',_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x25fc6b(_0x465018,_0x1ecae0,_0x4762a6,_0x158fcf,_0x28f224,_0x209ee3,_0x49127a,_0x2a3198,_0xbe6095,_0x27fb43,_0x11fe5a){const _0x471eb6=_0x189033,_0x44b55a=this;_0x44b55a[_0x471eb6('0x11ed')]=_0x11fe5a[_0x471eb6('0x20b2')](),_0x44b55a[_0x471eb6('0xaf6')]={},_0x44b55a[_0x471eb6('0x2768')]={'count':0x0,'rows':[]},_0x44b55a[_0x471eb6('0x4e0')]=[],_0x44b55a[_0x471eb6('0x1134')],_0x44b55a[_0x471eb6('0x23a2')]={'fields':_0x471eb6('0x16f9'),'sort':_0x471eb6('0xc36'),'limit':0xa,'page':0x1},_0x44b55a[_0x471eb6('0x8a4')]=_0x2e3ca0()[_0x471eb6('0x24db')]([{'option':'Highest','value':_0x471eb6('0x2395')},{'option':_0x471eb6('0x1526'),'value':_0x471eb6('0xe45')},{'option':_0x471eb6('0x13e'),'value':_0x471eb6('0x246f')},{'option':'Low','value':_0x471eb6('0x1597')},{'option':_0x471eb6('0x31c'),'value':_0x471eb6('0x1deb')}],function(_0x4b4bd5){const _0x150457=_0x471eb6;return _0x2e3ca0()[_0x150457('0x1725')](_0x4b4bd5[_0x150457('0x1c6b')],new RegExp('\x27','g'),'');}),_0x44b55a[_0x471eb6('0x12f3')]=_0x5b3ffd,_0x44b55a[_0x471eb6('0x26eb')]=_0x9bd792,_0x44b55a['success']=_0x489ac0,_0x44b55a[_0x471eb6('0x1256')]=_0x870405,_0x44b55a[_0x471eb6('0x23ed')]=_0x3bcd25,_0x44b55a['exportSelectedIvrCampaignHoppers']=_0x5403c5,_0x44b55a['deleteIvrCampaignHopper']=_0x431cdb,_0x44b55a[_0x471eb6('0x1513')]=_0x283b4b,_0x11fe5a[_0x471eb6('0xca1')]('admin')?_0x27fb43[_0x471eb6('0xc96')][_0x471eb6('0x1e6e')]({'fields':'id,name','role':'agent','sort':_0x471eb6('0x60a'),'nolimit':_0x471eb6('0x26ac')})[_0x471eb6('0xe53')][_0x471eb6('0x683')](function(_0x11d760){const _0x187a09=_0x471eb6;_0x44b55a[_0x187a09('0x756')]=_0x11d760[_0x187a09('0xf5d')]||[];})['catch'](function(_0x3b10cd){const _0x22eae0=_0x471eb6;_0xbe6095['error']({'title':_0x3b10cd[_0x22eae0('0x13ee')]?'API:'+_0x3b10cd[_0x22eae0('0x13ee')]+_0x22eae0('0xbf6')+_0x3b10cd[_0x22eae0('0x24a9')]:_0x22eae0('0x144f'),'msg':_0x3b10cd[_0x22eae0('0x5a5')]?JSON[_0x22eae0('0x258a')](_0x3b10cd[_0x22eae0('0x5a5')]):_0x3b10cd['toString']()});}):_0x27fb43[_0x471eb6('0xc96')][_0x471eb6('0x1e6e')]({'fields':_0x471eb6('0xa10'),'role':_0x471eb6('0x2327'),'sort':_0x471eb6('0x60a'),'nolimit':_0x471eb6('0x26ac')})[_0x471eb6('0xe53')][_0x471eb6('0x683')](function(_0x3e8c6f){const _0x468d3e=_0x471eb6;_0x44b55a[_0x468d3e('0x756')]=_0x3e8c6f[_0x468d3e('0xf5d')]||[];})[_0x471eb6('0x683')](function(){const _0x3d0a2f=_0x471eb6;return _0x27fb43[_0x3d0a2f('0x22df')]['get']({'userProfileId':_0x44b55a[_0x3d0a2f('0x11ed')]['userProfileId'],'sectionId':0xca})[_0x3d0a2f('0xe53')];})[_0x471eb6('0x683')](function(_0x2ac9d8){const _0x9f220c=_0x471eb6,_0x4d2e70=_0x2ac9d8&&_0x2ac9d8['rows']?_0x2ac9d8[_0x9f220c('0xf5d')][0x0]:null;if(!_0x4d2e70)_0x44b55a[_0x9f220c('0x756')]=[];else{if(!_0x4d2e70[_0x9f220c('0x170')])return _0x27fb43[_0x9f220c('0xcf7')][_0x9f220c('0x1e6e')]({'sectionId':_0x4d2e70['id']})[_0x9f220c('0xe53')][_0x9f220c('0x683')](function(_0x1f715b){const _0x1205b8=_0x9f220c,_0x4bf1c5=_0x2e3ca0()['map'](_0x1f715b[_0x1205b8('0xf5d')],function(_0x2d6b28){const _0xcb8cf8=_0x1205b8;return _0x2e3ca0()[_0xcb8cf8('0x1c07')](_0x44b55a[_0xcb8cf8('0x756')],{'id':_0x2d6b28[_0xcb8cf8('0x832')]});});_0x44b55a[_0x1205b8('0x756')][_0x1205b8('0x1299')](function(_0x21c07a){const _0x4c532e=_0x1205b8;!_0x2e3ca0()['some'](_0x4bf1c5,['id',_0x21c07a['id']])&&(_0x21c07a[_0x4c532e('0x319')]=![]),_0x4bf1c5['push'](_0x21c07a);}),_0x44b55a[_0x1205b8('0x756')]=_0x4bf1c5;});}})[_0x471eb6('0x130a')](function(_0x20b216){const _0x4b5378=_0x471eb6;_0xbe6095[_0x4b5378('0x52a')]({'title':_0x20b216[_0x4b5378('0x13ee')]?_0x4b5378('0x2168')+_0x20b216[_0x4b5378('0x13ee')]+'\x20-\x20'+_0x20b216['statusText']:'SYSTEM:GETagents','msg':_0x20b216['data']?JSON[_0x4b5378('0x258a')](_0x20b216[_0x4b5378('0x5a5')]):_0x20b216['toString']()});});function _0x5b3ffd(_0x464230,_0x5c24e8){const _0x15e84f=_0x471eb6;_0x44b55a['ivrCampaign']=_0x464230,_0x44b55a['crudPermissions']=typeof _0x5c24e8!==_0x15e84f('0x1867')?_0x5c24e8:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x44b55a[_0x15e84f('0x23a2')]['CampaignId']=_0x44b55a['ivrCampaign']['id'],_0x44b55a[_0x15e84f('0x23a2')]['id']=_0x44b55a[_0x15e84f('0xaf6')]['id'],_0x870405();}function _0x9bd792(_0x38c3f1,_0x140620){const _0x54bc01=_0x471eb6,_0x206808=_0x49127a[_0x54bc01('0x1c6f')]()[_0x54bc01('0xf28')](_0x54bc01('0xed1'))[_0x54bc01('0x26e3')](_0x54bc01('0xed5')+(_0x38c3f1[_0x54bc01('0x60a')]||_0x38c3f1['id']&&_0x2e3ca0()[_0x54bc01('0x2711')](_0x54bc01('0x2ad'))+_0x38c3f1['id']||_0x54bc01('0x1da2'))+''+'\x20will\x20be\x20deleted.')[_0x54bc01('0x1040')](_0x54bc01('0x18fa'))[_0x54bc01('0xe42')](_0x140620)['ok']('OK')[_0x54bc01('0x19fb')](_0x54bc01('0x16b8'));_0x49127a[_0x54bc01('0x1d4')](_0x206808)[_0x54bc01('0x683')](function(){_0x431cdb(_0x38c3f1);},function(){const _0x38cdd3=_0x54bc01;console[_0x38cdd3('0x1b2b')](_0x38cdd3('0x16b8'));});}function _0x489ac0(_0x3069a2){_0x44b55a['ivrCampaignHoppers']=_0x3069a2||{'count':0x0,'rows':[]};}function _0x870405(){const _0x982cff=_0x471eb6;_0x44b55a['query'][_0x982cff('0x1cc8')]=(_0x44b55a[_0x982cff('0x23a2')][_0x982cff('0xdf8')]-0x1)*_0x44b55a['query']['limit'],_0x44b55a[_0x982cff('0x1883')]=_0x27fb43['campaign'][_0x982cff('0x21f7')](_0x44b55a[_0x982cff('0x23a2')],_0x489ac0)[_0x982cff('0xe53')];}function _0x3bcd25(_0x42b493,_0x5506ff){const _0x5a359f=_0x471eb6;_0x49127a['show']({'controller':'CreateOrEditHopperCampaignIdDialogController','controllerAs':'vm','templateUrl':_0x4eeff0,'parent':angular[_0x5a359f('0x1fcc')](_0x2a3198[_0x5a359f('0x18e5')]),'targetEvent':_0x42b493,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x44b55a[_0x5a359f('0xaf6')],'hopper':_0x5506ff,'hoppers':_0x44b55a[_0x5a359f('0x2768')]['rows'],'license':null,'setting':null,'crudPermissions':_0x44b55a[_0x5a359f('0x1134')]}});}function _0x431cdb(_0x343671){const _0x12a4bc=_0x471eb6;_0x27fb43[_0x12a4bc('0x26cf')][_0x12a4bc('0xd7e')]({'id':_0x343671['id']})[_0x12a4bc('0xe53')][_0x12a4bc('0x683')](function(){const _0x43a380=_0x12a4bc;_0x2e3ca0()['remove'](_0x44b55a['ivrCampaignHoppers'][_0x43a380('0xf5d')],{'id':_0x343671['id']}),_0x44b55a[_0x43a380('0x2768')][_0x43a380('0x50d')]-=0x1,!_0x44b55a[_0x43a380('0x2768')][_0x43a380('0xf5d')]['length']&&_0x870405(),_0xbe6095[_0x43a380('0x53')]({'title':_0x43a380('0x23fc'),'msg':_0x343671['name']?_0x343671[_0x43a380('0x60a')]+'\x20has\x20been\x20deleted!':''});})['catch'](function(_0x1ba569){const _0x40e189=_0x12a4bc;if(_0x1ba569[_0x40e189('0x5a5')]&&_0x1ba569[_0x40e189('0x5a5')][_0x40e189('0x17f')]&&_0x1ba569['data']['errors'][_0x40e189('0x1564')]){_0x44b55a[_0x40e189('0x17f')]=_0x1ba569[_0x40e189('0x5a5')][_0x40e189('0x17f')]||[{'message':_0x1ba569[_0x40e189('0x1ff0')](),'type':'SYSTEM:GETcampaign'}];for(let _0x222fb4=0x0;_0x222fb4<_0x1ba569['data']['errors'][_0x40e189('0x1564')];_0x222fb4++){_0xbe6095[_0x40e189('0x52a')]({'title':_0x1ba569['data'][_0x40e189('0x17f')][_0x222fb4][_0x40e189('0xcf0')],'msg':_0x1ba569[_0x40e189('0x5a5')]['errors'][_0x222fb4][_0x40e189('0x8c2')]});}}else _0xbe6095[_0x40e189('0x52a')]({'title':_0x1ba569[_0x40e189('0x13ee')]?_0x40e189('0x2168')+_0x1ba569[_0x40e189('0x13ee')]+_0x40e189('0xbf6')+_0x1ba569[_0x40e189('0x24a9')]:_0x40e189('0x104'),'msg':_0x1ba569['data']?JSON[_0x40e189('0x258a')](_0x1ba569[_0x40e189('0x5a5')]['message']):_0x1ba569[_0x40e189('0x8c2')]||_0x1ba569[_0x40e189('0x1ff0')]()});});}function _0x5403c5(){const _0x16968=_0x471eb6,_0x1f430a=angular[_0x16968('0x1a86')](_0x44b55a[_0x16968('0x4e0')]);return _0x44b55a['selectedIvrCampaignHoppers']=[],_0x1f430a;}function _0x283b4b(_0x4499a5){const _0x3763ee=_0x471eb6,_0x42dc15=_0x49127a[_0x3763ee('0x1c6f')]()[_0x3763ee('0xf28')](_0x3763ee('0x228e'))[_0x3763ee('0x26e3')](_0x3763ee('0xed5')+_0x44b55a[_0x3763ee('0x4e0')][_0x3763ee('0x1564')]+_0x3763ee('0x93c')+_0x3763ee('0x1ee7'))['ariaLabel']('delete\x20hoppers')[_0x3763ee('0xe42')](_0x4499a5)['ok']('OK')[_0x3763ee('0x19fb')](_0x3763ee('0x16b8'));_0x49127a[_0x3763ee('0x1d4')](_0x42dc15)[_0x3763ee('0x683')](function(){const _0xe8febd=_0x3763ee;_0x44b55a[_0xe8febd('0x4e0')][_0xe8febd('0x1299')](function(_0x5b2ca6){_0x431cdb(_0x5b2ca6);}),_0x44b55a[_0xe8febd('0x4e0')]=[];});}let _0x2e6c2a=!![],_0x317afd=0x1;_0x1ecae0[_0x471eb6('0x186d')](_0x471eb6('0x229'),function(_0x2f8bcb,_0x374d79){const _0x3df8be=_0x471eb6;_0x2e6c2a?_0x209ee3(function(){_0x2e6c2a=![];}):(!_0x374d79&&(_0x317afd=_0x44b55a[_0x3df8be('0x23a2')][_0x3df8be('0xdf8')]),_0x2f8bcb!==_0x374d79&&(_0x44b55a[_0x3df8be('0x23a2')][_0x3df8be('0xdf8')]=0x1),!_0x2f8bcb&&(_0x44b55a[_0x3df8be('0x23a2')]['page']=_0x317afd),_0x870405());});}const _0xbd5181=_0x25fc6b;_0x1aae4e[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state','$location','$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),'hoppers',_0x189033('0x1da2'),_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),_0x189033('0x1134')];function _0x1aae4e(_0x7974f2,_0xa8f359,_0x2d906f,_0x5b0c42,_0x1a34a2,_0x4a95de,_0x1717cc,_0x5f351e,_0x3c87e8,_0x1eb162,_0x5dc46c,_0x22cebb,_0x5b37bb,_0x148908){const _0x3a7e46=_0x189033,_0xd3f7e1=this;_0xd3f7e1[_0x3a7e46('0x11ed')]=_0x5dc46c['getCurrentUser'](),_0xd3f7e1[_0x3a7e46('0x17f')]=[],_0xd3f7e1['setting']=_0x5b37bb,_0xd3f7e1[_0x3a7e46('0xace')]=_0x22cebb,_0xd3f7e1[_0x3a7e46('0x1134')]=_0x148908,_0xd3f7e1[_0x3a7e46('0x258d')]={},_0xd3f7e1[_0x3a7e46('0x19b2')]=_0xd3f7e1['setting']&&_0xd3f7e1[_0x3a7e46('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0xd3f7e1['title']=_0x3a7e46('0xbd0'),_0xd3f7e1[_0x3a7e46('0x1da2')]=angular[_0x3a7e46('0x1a86')](_0x3c87e8),_0xd3f7e1[_0x3a7e46('0x1c63')]=_0x5f351e,_0xd3f7e1[_0x3a7e46('0x7b6')]=![];!_0xd3f7e1[_0x3a7e46('0x1da2')]&&(_0xd3f7e1[_0x3a7e46('0x1da2')]={},_0xd3f7e1[_0x3a7e46('0xf28')]=_0x3a7e46('0x26e4'),_0xd3f7e1['newHopper']=!![]);_0xa8f359['params']['id']&&(_0xd3f7e1[_0x3a7e46('0x1da2')][_0x3a7e46('0x11c')]=_0xa8f359[_0x3a7e46('0x7f2')]['id']);_0xd3f7e1[_0x3a7e46('0x46f')]=_0x2e7173,_0xd3f7e1[_0x3a7e46('0xdab')]=_0x1f40a8,_0xd3f7e1['deleteHopper']=_0x394a1e,_0xd3f7e1['getDateFromString']=_0x20ea55,_0xd3f7e1[_0x3a7e46('0xf82')]=_0xdbee47,_0x5dc46c[_0x3a7e46('0xca1')](_0x3a7e46('0x20c2'))?_0x1eb162['user'][_0x3a7e46('0x1e6e')]({'fields':_0x3a7e46('0xa10'),'role':_0x3a7e46('0x2327'),'sort':_0x3a7e46('0x60a'),'nolimit':_0x3a7e46('0x26ac')})[_0x3a7e46('0xe53')]['then'](function(_0x26357d){const _0xe18a4b=_0x3a7e46;_0xd3f7e1['agents']=_0x26357d[_0xe18a4b('0xf5d')]||[];})['catch'](function(_0x58b89f){const _0x2ee08b=_0x3a7e46;_0x1717cc[_0x2ee08b('0x52a')]({'title':_0x58b89f[_0x2ee08b('0x13ee')]?_0x2ee08b('0x2168')+_0x58b89f[_0x2ee08b('0x13ee')]+_0x2ee08b('0xbf6')+_0x58b89f['statusText']:_0x2ee08b('0x144f'),'msg':_0x58b89f[_0x2ee08b('0x5a5')]?JSON[_0x2ee08b('0x258a')](_0x58b89f[_0x2ee08b('0x5a5')]):_0x58b89f[_0x2ee08b('0x1ff0')]()});}):_0x1eb162[_0x3a7e46('0xc96')][_0x3a7e46('0x1e6e')]({'fields':_0x3a7e46('0xa10'),'role':'agent','sort':_0x3a7e46('0x60a'),'nolimit':'true'})[_0x3a7e46('0xe53')]['then'](function(_0x304edb){const _0x2fea47=_0x3a7e46;_0xd3f7e1['agents']=_0x304edb[_0x2fea47('0xf5d')]||[];})[_0x3a7e46('0x683')](function(){const _0x267bc8=_0x3a7e46;return _0x1eb162[_0x267bc8('0x22df')][_0x267bc8('0x1e6e')]({'userProfileId':_0xd3f7e1[_0x267bc8('0x11ed')][_0x267bc8('0x2f')],'sectionId':0xca})[_0x267bc8('0xe53')];})['then'](function(_0x27e4b5){const _0x3e3676=_0x3a7e46,_0x3b5b19=_0x27e4b5&&_0x27e4b5[_0x3e3676('0xf5d')]?_0x27e4b5['rows'][0x0]:null;if(!_0x3b5b19)_0xd3f7e1[_0x3e3676('0x756')]=[];else{if(!_0x3b5b19[_0x3e3676('0x170')])return _0x1eb162[_0x3e3676('0xcf7')][_0x3e3676('0x1e6e')]({'sectionId':_0x3b5b19['id']})[_0x3e3676('0xe53')][_0x3e3676('0x683')](function(_0x142649){const _0x3c05f5=_0x3e3676,_0x361d8b=_0x2e3ca0()[_0x3c05f5('0x386')](_0x142649[_0x3c05f5('0xf5d')],function(_0x26ac85){const _0x1ebfd3=_0x3c05f5;return _0x2e3ca0()[_0x1ebfd3('0x1c07')](_0xd3f7e1[_0x1ebfd3('0x756')],{'id':_0x26ac85[_0x1ebfd3('0x832')]});});_0xd3f7e1[_0x3c05f5('0x756')][_0x3c05f5('0x1299')](function(_0x14d86d){const _0x1d0449=_0x3c05f5;!_0x2e3ca0()[_0x1d0449('0x7a2')](_0x361d8b,['id',_0x14d86d['id']])&&(_0x14d86d[_0x1d0449('0x319')]=![]),_0x361d8b[_0x1d0449('0x1fd0')](_0x14d86d);}),_0xd3f7e1[_0x3c05f5('0x756')]=_0x361d8b;});}})[_0x3a7e46('0x130a')](function(_0x176df2){const _0x474a1b=_0x3a7e46;_0x1717cc['error']({'title':_0x176df2[_0x474a1b('0x13ee')]?_0x474a1b('0x2168')+_0x176df2['status']+_0x474a1b('0xbf6')+_0x176df2[_0x474a1b('0x24a9')]:_0x474a1b('0x391'),'msg':_0x176df2[_0x474a1b('0x5a5')]?JSON['stringify'](_0x176df2['data']):_0x176df2[_0x474a1b('0x1ff0')]()});});function _0x2e7173(){const _0xf0b469=_0x3a7e46;_0xd3f7e1[_0xf0b469('0x17f')]=[],_0x1eb162[_0xf0b469('0x26cf')][_0xf0b469('0xb0a')](_0xd3f7e1[_0xf0b469('0x1da2')])['$promise'][_0xf0b469('0x683')](function(_0x194d38){const _0x7817d4=_0xf0b469;_0xd3f7e1[_0x7817d4('0x1c63')][_0x7817d4('0x1167')](_0x194d38[_0x7817d4('0x24e1')]()),_0x1717cc['success']({'title':_0x7817d4('0x23d4'),'msg':_0xd3f7e1['hopper'][_0x7817d4('0x60a')]?_0xd3f7e1[_0x7817d4('0x1da2')][_0x7817d4('0x60a')]+_0x7817d4('0x14b5'):''}),_0xdbee47(_0x194d38);})[_0xf0b469('0x130a')](function(_0x3b4192){const _0x2e1a12=_0xf0b469;if(_0x3b4192['data']&&_0x3b4192[_0x2e1a12('0x5a5')][_0x2e1a12('0x17f')]&&_0x3b4192[_0x2e1a12('0x5a5')][_0x2e1a12('0x17f')][_0x2e1a12('0x1564')]){_0xd3f7e1[_0x2e1a12('0x17f')]=_0x3b4192[_0x2e1a12('0x5a5')][_0x2e1a12('0x17f')]||[{'message':_0x3b4192['toString'](),'type':_0x2e1a12('0x1e1b')}];for(let _0x227238=0x0;_0x227238<_0x3b4192[_0x2e1a12('0x5a5')]['errors'][_0x2e1a12('0x1564')];_0x227238+=0x1){_0x1717cc['error']({'title':_0x3b4192[_0x2e1a12('0x5a5')][_0x2e1a12('0x17f')][_0x227238][_0x2e1a12('0xcf0')],'msg':_0x3b4192[_0x2e1a12('0x5a5')][_0x2e1a12('0x17f')][_0x227238][_0x2e1a12('0x8c2')]});}}else _0x1717cc[_0x2e1a12('0x52a')]({'title':_0x3b4192[_0x2e1a12('0x13ee')]?'API:'+_0x3b4192[_0x2e1a12('0x13ee')]+'\x20-\x20'+_0x3b4192['statusText']:'api.cmHopper.save','msg':_0x3b4192['data']?JSON[_0x2e1a12('0x258a')](_0x3b4192[_0x2e1a12('0x5a5')][_0x2e1a12('0x8c2')]):_0x3b4192[_0x2e1a12('0x1ff0')]()});});}function _0x1f40a8(){const _0x2d33cd=_0x3a7e46;_0xd3f7e1[_0x2d33cd('0x17f')]=[];let _0x56fa48,_0x573f7b,_0x3b114f,_0x12bb67;_0xd3f7e1[_0x2d33cd('0x1da2')][_0x2d33cd('0x10c5')]=_0xd3f7e1[_0x2d33cd('0x1da2')]['recallme']?_0xd3f7e1['hopper'][_0x2d33cd('0x10c5')]:null,_0xd3f7e1[_0x2d33cd('0x1da2')]['OwnerId']=_0x5dc46c[_0x2d33cd('0x20b2')]()['id'],_0x1eb162[_0x2d33cd('0x26cf')][_0x2d33cd('0x1e6e')]({'id':_0xd3f7e1[_0x2d33cd('0x1da2')]['id'],'attributes':[_0x2d33cd('0x1ff9')]})[_0x2d33cd('0xe53')][_0x2d33cd('0x683')](function(_0x12c2be){const _0x4f1512=_0x2d33cd;_0x2e3ca0()[_0x4f1512('0x8f2')](_0x12c2be)||_0x2e3ca0()[_0x4f1512('0x173f')](_0x12c2be)?_0x56fa48=_0x1aaf93()()[_0x4f1512('0x26dd')]('YYYY-MM-DD\x20HH:mm:ss'):_0x56fa48=_0x12c2be['scheduledat'];})[_0x2d33cd('0x2874')](function(){const _0x149402=_0x2d33cd;_0x1eb162[_0x149402('0x26cf')][_0x149402('0x2480')]({'id':_0xd3f7e1['hopper']['id']},_0x2e3ca0()[_0x149402('0x8b5')](_0xd3f7e1[_0x149402('0x1da2')],['VoiceQueueId',_0x149402('0x11c'),_0x149402('0x670'),_0x149402('0x1e4f')]))['$promise'][_0x149402('0x683')](function(_0x1ac4c8){const _0x2a34d2=_0x149402;_0x573f7b=_0x1ac4c8,_0x1eb162['cmContact'][_0x2a34d2('0x1e6e')]({'id':_0x573f7b[_0x2a34d2('0x670')],'attributes':['firstName',_0x2a34d2('0x510')]})[_0x2a34d2('0xe53')][_0x2a34d2('0x683')](function(_0x431d24){const _0xb391f2=_0x2a34d2;!_0x2e3ca0()[_0xb391f2('0x8f2')](_0x431d24)&&!_0x2e3ca0()['isNil'](_0x431d24[_0xb391f2('0xeef')])&&(_0x3b114f=_0x431d24['firstName'],!_0x2e3ca0()[_0xb391f2('0x8f2')](_0x431d24[_0xb391f2('0x510')])&&(_0x3b114f+='\x20'+_0x431d24[_0xb391f2('0x510')]));})['catch'](function(){_0x3b114f=undefined;})[_0x2a34d2('0x2874')](function(){const _0x43bf56=_0x2a34d2;_0x1eb162['campaign']['get']({'raw':![],'id':_0x573f7b[_0x43bf56('0x11c')],'attributes':['name']})[_0x43bf56('0xe53')]['then'](function(_0x22eab1){_0x12bb67=_0x22eab1['name'];})[_0x43bf56('0x130a')](function(){_0x12bb67=undefined;})[_0x43bf56('0x2874')](function(){const _0x687cfb=_0x43bf56;_0x1eb162[_0x687cfb('0x2583')]['save']({'state':0x18,'statedesc':_0x687cfb('0x99'),'scheduledat':_0x56fa48,'calleridnum':_0x573f7b[_0x687cfb('0xd31')],'calleridname':_0x3b114f,'campaigntype':_0x573f7b[_0x687cfb('0x19ec')]?'queue':_0x687cfb('0x715'),'campaign':_0x12bb67,'editedat':_0x1aaf93()()[_0x687cfb('0x26dd')](_0x687cfb('0x865')),'edited':!![],'ListId':_0x573f7b[_0x687cfb('0x1e4f')],'UserId':_0x5dc46c[_0x687cfb('0x20b2')]()['id'],'VoiceQueueId':_0x573f7b['VoiceQueueId'],'CampaignId':_0x573f7b[_0x687cfb('0x11c')],'ContactId':_0x573f7b[_0x687cfb('0x670')],'callback':_0x573f7b[_0x687cfb('0x22b5')],'callbackuniqueid':_0x573f7b[_0x687cfb('0x8ce')],'countbusyretry':_0x573f7b[_0x687cfb('0x1e2c')],'countcongestionretry':_0x573f7b[_0x687cfb('0xbfb')],'countglobal':_0x573f7b[_0x687cfb('0x10d2')],'countnoanswerretry':_0x573f7b[_0x687cfb('0x284c')],'followuptime':_0x573f7b[_0x687cfb('0x24d5')],'recallme':_0x573f7b[_0x687cfb('0x202f')]});});});const _0x19c512=_0x2e3ca0()[_0x2a34d2('0x1c07')](_0xd3f7e1[_0x2a34d2('0x1c63')],{'id':_0x1ac4c8['id']});_0x19c512&&_0x2e3ca0()[_0x2a34d2('0xf22')](_0x19c512,_0x2e3ca0()[_0x2a34d2('0x24d0')](_0x1ac4c8['toJSON'](),_0x2e3ca0()[_0x2a34d2('0x55e')](_0x19c512))),_0x1717cc[_0x2a34d2('0x53')]({'title':_0x2a34d2('0x16ac'),'msg':_0xd3f7e1[_0x2a34d2('0x1da2')]['name']?_0xd3f7e1[_0x2a34d2('0x1da2')][_0x2a34d2('0x60a')]+_0x2a34d2('0xf59'):''}),_0xdbee47(_0x1ac4c8);})['catch'](function(_0x333a27){const _0x27fbfc=_0x149402;if(_0x333a27[_0x27fbfc('0x5a5')]&&_0x333a27[_0x27fbfc('0x5a5')][_0x27fbfc('0x17f')]&&_0x333a27[_0x27fbfc('0x5a5')][_0x27fbfc('0x17f')]['length']){_0xd3f7e1[_0x27fbfc('0x17f')]=_0x333a27[_0x27fbfc('0x5a5')][_0x27fbfc('0x17f')]||[{'message':_0x333a27[_0x27fbfc('0x1ff0')](),'type':_0x27fbfc('0x83b')}];for(let _0x409483=0x0;_0x409483<_0x333a27[_0x27fbfc('0x5a5')][_0x27fbfc('0x17f')][_0x27fbfc('0x1564')];_0x409483++){_0x1717cc[_0x27fbfc('0x52a')]({'title':_0x333a27[_0x27fbfc('0x5a5')]['errors'][_0x409483][_0x27fbfc('0xcf0')],'msg':_0x333a27[_0x27fbfc('0x5a5')][_0x27fbfc('0x17f')][_0x409483][_0x27fbfc('0x8c2')]});}}else _0x1717cc['error']({'title':_0x333a27[_0x27fbfc('0x13ee')]?_0x27fbfc('0x2168')+_0x333a27[_0x27fbfc('0x13ee')]+_0x27fbfc('0xbf6')+_0x333a27[_0x27fbfc('0x24a9')]:'api.cmHopper.update','msg':_0x333a27[_0x27fbfc('0x5a5')]?JSON[_0x27fbfc('0x258a')](_0x333a27[_0x27fbfc('0x5a5')]['message']):_0x333a27[_0x27fbfc('0x1ff0')]()});});});}function _0x394a1e(_0x43bb3d){const _0x318b3e=_0x3a7e46;_0xd3f7e1['errors']=[];const _0x3bd2fb=_0x5b0c42['confirm']()['title'](_0x318b3e('0x4d'))[_0x318b3e('0xa6a')](_0x318b3e('0x2130'))[_0x318b3e('0x1040')](_0x318b3e('0x7e4'))['ok'](_0x318b3e('0x2307'))[_0x318b3e('0x19fb')]('Cancel')['targetEvent'](_0x43bb3d);_0x5b0c42[_0x318b3e('0x1d4')](_0x3bd2fb)['then'](function(){const _0x5cbd86=_0x318b3e;_0x1eb162[_0x5cbd86('0x26cf')][_0x5cbd86('0xd7e')]({'id':_0xd3f7e1[_0x5cbd86('0x1da2')]['id']})['$promise'][_0x5cbd86('0x683')](function(){const _0x3b0c93=_0x5cbd86;_0x2e3ca0()['remove'](_0xd3f7e1[_0x3b0c93('0x1c63')],{'id':_0xd3f7e1[_0x3b0c93('0x1da2')]['id']}),_0x1717cc['success']({'title':_0x3b0c93('0xb7e'),'msg':(_0xd3f7e1[_0x3b0c93('0x1da2')][_0x3b0c93('0x60a')]||_0x3b0c93('0x1da2'))+_0x3b0c93('0x194d')}),_0xdbee47(_0xd3f7e1[_0x3b0c93('0x1da2')]);})[_0x5cbd86('0x130a')](function(_0x4f7a33){const _0x4a7db7=_0x5cbd86;if(_0x4f7a33[_0x4a7db7('0x5a5')]&&_0x4f7a33[_0x4a7db7('0x5a5')][_0x4a7db7('0x17f')]&&_0x4f7a33[_0x4a7db7('0x5a5')]['errors'][_0x4a7db7('0x1564')]){_0xd3f7e1['errors']=_0x4f7a33[_0x4a7db7('0x5a5')]['errors']||[{'message':_0x4f7a33['toString'](),'type':'api.cmHopper.delete'}];for(let _0x57b48a=0x0;_0x57b48a<_0x4f7a33[_0x4a7db7('0x5a5')]['errors'][_0x4a7db7('0x1564')];_0x57b48a++){_0x1717cc[_0x4a7db7('0x52a')]({'title':_0x4f7a33[_0x4a7db7('0x5a5')][_0x4a7db7('0x17f')][_0x57b48a][_0x4a7db7('0xcf0')],'msg':_0x4f7a33['data'][_0x4a7db7('0x17f')][_0x57b48a]['message']});}}else _0x1717cc[_0x4a7db7('0x52a')]({'title':_0x4f7a33[_0x4a7db7('0x13ee')]?_0x4a7db7('0x2168')+_0x4f7a33[_0x4a7db7('0x13ee')]+_0x4a7db7('0xbf6')+_0x4f7a33[_0x4a7db7('0x24a9')]:_0x4a7db7('0x14fc'),'msg':_0x4f7a33['data']?JSON[_0x4a7db7('0x258a')](_0x4f7a33[_0x4a7db7('0x5a5')][_0x4a7db7('0x8c2')]):_0x4f7a33[_0x4a7db7('0x8c2')]||_0x4f7a33[_0x4a7db7('0x1ff0')]()});});},function(){});}function _0x20ea55(_0x3713cc){return _0x3713cc===null?undefined:new Date(_0x3713cc);}function _0xdbee47(_0x9ce104){const _0x5673a3=_0x3a7e46;_0x5b0c42[_0x5673a3('0x1715')](_0x9ce104);}}const _0xe66866=_0x1aae4e;_0x35cf16[_0x189033('0x14be')]=[_0x189033('0x56b'),'toasty'];function _0x35cf16(_0x1ff755,_0x4d8564){const _0x2e7357=_0x189033,_0x3eb0f8=this;_0x3eb0f8['ivrCampaign']={},_0x3eb0f8[_0x2e7357('0x12f3')]=_0x22afd5;function _0x22afd5(_0x25eddd){const _0x1f15a2=_0x2e7357;_0x3eb0f8[_0x1f15a2('0xaf6')]=_0x25eddd,_0x1ff755[_0x1f15a2('0x26cf')]['get']({'limit':0x0,'CampaignId':_0x25eddd['id']})['$promise'][_0x1f15a2('0x683')](function(_0x381725){const _0xdf850d=_0x1f15a2;return _0x3eb0f8[_0xdf850d('0x2263')]=_0x381725[_0xdf850d('0x50d')]||0x0,_0x1ff755[_0xdf850d('0x26cf')][_0xdf850d('0x1e6e')]({'limit':0x0,'CampaignId':_0x25eddd['id'],'active':![],'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0})['$promise'];})[_0x1f15a2('0x683')](function(_0x3c22d4){const _0x2e14d5=_0x1f15a2;return _0x3eb0f8['fresh']=_0x3c22d4[_0x2e14d5('0x50d')]||0x0,_0x1ff755[_0x2e14d5('0x163f')]['get']({'limit':0x0,'CampaignId':_0x25eddd['id']})[_0x2e14d5('0xe53')];})[_0x1f15a2('0x683')](function(_0x59aa6b){const _0x18a7f8=_0x1f15a2;_0x3eb0f8[_0x18a7f8('0xd8a')]=_0x59aa6b[_0x18a7f8('0x50d')]||0x0;})[_0x1f15a2('0x130a')](function(_0x4feaf8){const _0x55fd23=_0x1f15a2;_0x4d8564[_0x55fd23('0x52a')]({'title':_0x4feaf8[_0x55fd23('0x13ee')]?'API:'+_0x4feaf8[_0x55fd23('0x13ee')]+_0x55fd23('0xbf6')+_0x4feaf8['statusText']:_0x55fd23('0x10a4'),'msg':_0x4feaf8['data']?JSON[_0x55fd23('0x258a')](_0x4feaf8[_0x55fd23('0x5a5')]):_0x4feaf8[_0x55fd23('0x1ff0')]()});});}}const _0x4db171=_0x35cf16;_0x3632b5[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x56b'),'ivrCampaign',_0x189033('0x1d08'),_0x189033('0x2f9'),'Auth',_0x189033('0x1134')];function _0x3632b5(_0x7e32c8,_0x257be3,_0x437f2e,_0x3520d0,_0x1f1a98,_0x1f772b,_0x4d63c1,_0x376642,_0x1c58b8){const _0x12b8ad=_0x189033,_0x896647=this;_0x896647[_0x12b8ad('0x11ed')]=_0x376642['getCurrentUser'](),_0x896647['ivrCampaign']=_0x1f1a98,_0x896647[_0x12b8ad('0x1134')]=_0x1c58b8,_0x896647['apiRoute']=_0x12b8ad('0x6e9'),_0x896647[_0x12b8ad('0x578')]=_0x12b8ad('0x16c3'),_0x896647['addApi']=_0x12b8ad('0x11ef'),_0x896647['removeApi']=_0x12b8ad('0x8d2'),_0x896647[_0x12b8ad('0x1996')]=[],_0x896647[_0x12b8ad('0x1c47')]=[],_0x896647[_0x12b8ad('0x1378')]=[],_0x896647[_0x12b8ad('0x125e')]=[],_0x896647[_0x12b8ad('0x23a7')]=[],_0x896647[_0x12b8ad('0x2106')]=![],_0x896647[_0x12b8ad('0x2195')]=![],_0x896647[_0x12b8ad('0x169f')]={'readOnly':!_0x896647['crudPermissions'][_0x12b8ad('0x1978')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':![],'orderBy':'name','line1':_0x12b8ad('0x60a'),'line2':'','line3':'','labelAll':_0x1f772b['instant']('MOTIONDIALER.ALL_LISTS'),'labelSelected':_0x1f772b[_0x12b8ad('0x2728')](_0x12b8ad('0x577')),'transferCallback':function(){const _0x5bf1cf=_0x12b8ad,_0x5533d7=_0x2e3ca0()[_0x5bf1cf('0x25cb')](_0x896647[_0x5bf1cf('0x23a7')],_0x896647[_0x5bf1cf('0x1378')],'id');_0x896647[_0x5bf1cf('0x2106')]=_0x2e3ca0()['isEmpty'](_0x5533d7)?![]:!![];}},_0x896647['onInit']=_0x601814,_0x896647[_0x12b8ad('0x21fd')]=_0x1a0ed0,_0x896647[_0x12b8ad('0xf82')]=_0x54833d;function _0x601814(){const _0xdfe079=_0x12b8ad;return _0x376642[_0xdfe079('0xca1')]('admin')?_0x39c8b1()[_0xdfe079('0x130a')](function(_0x1e4ab7){const _0x4f97aa=_0xdfe079;_0x437f2e[_0x4f97aa('0x52a')]({'title':_0x1e4ab7[_0x4f97aa('0x13ee')]?_0x4f97aa('0x2168')+_0x1e4ab7['status']+_0x4f97aa('0xbf6')+_0x1e4ab7[_0x4f97aa('0x24a9')]:'SYSTEM:GETLISTS','msg':_0x1e4ab7[_0x4f97aa('0x13ee')]?JSON[_0x4f97aa('0x258a')](_0x1e4ab7[_0x4f97aa('0x5a5')]):_0x1e4ab7[_0x4f97aa('0x1ff0')]()});}):_0x4b1e04()[_0xdfe079('0x683')](function(_0x2c048a){const _0x6ef4cf=_0xdfe079;return _0x896647[_0x6ef4cf('0x1aa')]=_0x2c048a,_0x39c8b1();})['catch'](function(_0x59f755){const _0x27cbaa=_0xdfe079;_0x437f2e[_0x27cbaa('0x52a')]({'title':_0x59f755[_0x27cbaa('0x13ee')]?_0x27cbaa('0x2168')+_0x59f755[_0x27cbaa('0x13ee')]+_0x27cbaa('0xbf6')+_0x59f755[_0x27cbaa('0x24a9')]:_0x27cbaa('0xa2a'),'msg':_0x59f755[_0x27cbaa('0x13ee')]?JSON[_0x27cbaa('0x258a')](_0x59f755[_0x27cbaa('0x5a5')]):_0x59f755[_0x27cbaa('0x1ff0')]()});});}function _0x4b1e04(){return _0x257be3(function(_0x187e2b,_0x249c0d){const _0xbc5c34=a0_0x4e0a;_0x3520d0[_0xbc5c34('0x22df')]['get']({'userProfileId':_0x896647[_0xbc5c34('0x11ed')][_0xbc5c34('0x2f')],'name':'Lists'})[_0xbc5c34('0xe53')][_0xbc5c34('0x683')](function(_0x2b499a){const _0x4556b8=_0xbc5c34,_0x1d86a6=_0x2b499a&&_0x2b499a[_0x4556b8('0xf5d')]?_0x2b499a[_0x4556b8('0xf5d')][0x0]:null;_0x187e2b(_0x1d86a6);})[_0xbc5c34('0x130a')](function(_0x2b3a73){_0x249c0d(_0x2b3a73);});});}function _0x39c8b1(){return _0x257be3(function(_0x96b0ad,_0x332ba7){const _0x3684bf=a0_0x4e0a;return _0x529eda()['then'](function(_0x456ac9){const _0x5da999=a0_0x4e0a;return _0x896647[_0x5da999('0x1996')]=_0x456ac9['rows']?_0x456ac9[_0x5da999('0xf5d')]:[],_0x376642[_0x5da999('0xca1')](_0x5da999('0x20c2'))?_0x456ac9:_0x896647[_0x5da999('0x1aa')]?_0x896647['section'][_0x5da999('0x170')]?_0x456ac9:_0x22e836():null;})['then'](function(_0x18d07b){const _0x3bba5a=a0_0x4e0a,_0x5761ca=_0x18d07b&&_0x18d07b[_0x3bba5a('0xf5d')]?_0x18d07b[_0x3bba5a('0xf5d')]:[];return _0x896647['allowedItems']=_0x2e3ca0()[_0x3bba5a('0x386')](_0x5761ca,function(_0xfe6021){const _0x9fce5e=_0x3bba5a;return _0x2e3ca0()[_0x9fce5e('0x1c07')](_0x896647[_0x9fce5e('0x1996')],{'id':_0x376642[_0x9fce5e('0xca1')]('admin')||_0x896647[_0x9fce5e('0x1aa')][_0x9fce5e('0x170')]?_0xfe6021['id']:_0xfe6021[_0x9fce5e('0x832')]});}),_0x896647[_0x3bba5a('0x125e')]=angular['copy'](_0x896647['allowedItems']),_0x896647['items']['forEach'](function(_0x2f54a7){const _0x68ef70=_0x3bba5a,_0x572b56=_0x2e3ca0()[_0x68ef70('0x1c07')](_0x896647[_0x68ef70('0x1c47')],{'id':_0x2f54a7['id']});_0x896647['currentUser']['role']===_0x68ef70('0x20c2')?_0x2f54a7['isValid']=!![]:_0x2f54a7[_0x68ef70('0x24f4')]=typeof _0x572b56!==_0x68ef70('0x1867')?!![]:![];}),_0x5c6f23();})[_0x3684bf('0x683')](function(_0x32bc8d){const _0xc6ea09=_0x3684bf,_0x18a2e0=_0x32bc8d&&_0x32bc8d[_0xc6ea09('0xf5d')]?_0x32bc8d[_0xc6ea09('0xf5d')]:[];_0x896647['selectedItems']=_0x2e3ca0()[_0xc6ea09('0x386')](_0x18a2e0,function(_0x1ac590){const _0x1b4cdc=_0xc6ea09;return _0x2e3ca0()[_0x1b4cdc('0x1c07')](_0x896647['items'],{'id':_0x1ac590['id']});}),_0x896647[_0xc6ea09('0x23a7')]=angular[_0xc6ea09('0x1a86')](_0x896647[_0xc6ea09('0x1378')]),_0x896647[_0xc6ea09('0x169f')][_0xc6ea09('0x1378')]=_0x896647[_0xc6ea09('0x1378')],_0x896647[_0xc6ea09('0x169f')]['items']=_0x2e3ca0()[_0xc6ea09('0x461')](_0x896647[_0xc6ea09('0x1c47')],_0x896647[_0xc6ea09('0x169f')]['selectedItems'],'id'),_0x96b0ad();})['catch'](function(_0x4a6ce9){_0x332ba7(_0x4a6ce9);});});}function _0x22e836(){return _0x257be3(function(_0x287700,_0x5bc586){const _0x1e2d4e=a0_0x4e0a;return _0x3520d0[_0x1e2d4e('0xcf7')][_0x1e2d4e('0x1e6e')]({'sectionId':_0x896647['section']['id'],'nolimit':!![]})[_0x1e2d4e('0xe53')][_0x1e2d4e('0x683')](function(_0x53c244){_0x287700(_0x53c244);})[_0x1e2d4e('0x130a')](function(_0x706f44){_0x5bc586(_0x706f44);});});}function _0x5c6f23(){return _0x257be3(function(_0x4fd644,_0x1c38d1){const _0x3d2331=a0_0x4e0a,_0xabd3e=_0x3520d0[_0x896647[_0x3d2331('0x6d1')]];return _0xabd3e[_0x896647[_0x3d2331('0x578')]]({'id':_0x896647[_0x3d2331('0xaf6')]['id'],'fields':_0x3d2331('0xa10'),'nolimit':!![]})[_0x3d2331('0xe53')][_0x3d2331('0x683')](function(_0x101412){_0x4fd644(_0x101412);})[_0x3d2331('0x130a')](function(_0x36a565){_0x1c38d1(_0x36a565);});});}function _0x529eda(){return _0x257be3(function(_0x4b4a23,_0x5a3e45){const _0x5c40bc=a0_0x4e0a;return _0x3520d0[_0x5c40bc('0x259b')][_0x5c40bc('0x1e6e')]({'fields':_0x5c40bc('0xa10'),'nolimit':!![]})[_0x5c40bc('0xe53')]['then'](function(_0x29a395){_0x4b4a23(_0x29a395);})[_0x5c40bc('0x130a')](function(_0x47c70d){_0x5a3e45(_0x47c70d);});});}function _0xb66f56(_0x1ccd52){return _0x257be3(function(_0x57851a,_0x15c5df){const _0x24458f=a0_0x4e0a;if(_0x2e3ca0()[_0x24458f('0x173f')](_0x1ccd52))_0x57851a();else{const _0x47a738=_0x3520d0[_0x896647[_0x24458f('0x6d1')]];_0x47a738[_0x896647[_0x24458f('0x407')]]({'id':_0x896647[_0x24458f('0xaf6')]['id'],'ids':_0x2e3ca0()[_0x24458f('0x386')](_0x1ccd52,'id')})['$promise'][_0x24458f('0x683')](function(){_0x57851a();})[_0x24458f('0x130a')](function(_0x220578){_0x15c5df(_0x220578);});}});}function _0x3e0489(_0x7a3e20){return _0x257be3(function(_0x4a2a40,_0x3e0e67){const _0x1da1c6=a0_0x4e0a;if(_0x2e3ca0()[_0x1da1c6('0x173f')](_0x7a3e20))_0x4a2a40();else{const _0x356af4=_0x3520d0[_0x896647['apiRoute']];_0x356af4[_0x896647[_0x1da1c6('0x17e8')]]({'id':_0x896647[_0x1da1c6('0xaf6')]['id'],'ids':_0x2e3ca0()['map'](_0x7a3e20,'id')})[_0x1da1c6('0xe53')][_0x1da1c6('0x683')](function(){_0x4a2a40();})[_0x1da1c6('0x130a')](function(_0x2f191d){_0x3e0e67(_0x2f191d);});}});}function _0x1a0ed0(){const _0x458ccc=_0x12b8ad;_0x896647[_0x458ccc('0x2195')]=!![];const _0x3836b0=_0x2e3ca0()[_0x458ccc('0x461')](_0x896647['startingSelectedItems'],_0x896647[_0x458ccc('0x1378')],'id'),_0x51a1af=_0x2e3ca0()[_0x458ccc('0x461')](_0x896647[_0x458ccc('0x1378')],_0x896647['startingSelectedItems'],'id');return _0x3e0489(_0x3836b0)['then'](function(){return _0xb66f56(_0x51a1af);})['then'](function(){const _0x539479=_0x458ccc;_0x896647[_0x539479('0x2106')]=![],_0x896647[_0x539479('0x125e')]=angular[_0x539479('0x1a86')](_0x896647['allowedItems']),_0x896647[_0x539479('0x23a7')]=angular[_0x539479('0x1a86')](_0x896647[_0x539479('0x1378')]),_0x437f2e[_0x539479('0x53')]({'title':_0x539479('0xd28'),'msg':_0x539479('0x195b')});})[_0x458ccc('0x130a')](function(_0x3b497){const _0x306632=_0x458ccc;_0x437f2e[_0x306632('0x52a')]({'title':_0x3b497[_0x306632('0x13ee')]?_0x306632('0x2168')+_0x3b497[_0x306632('0x13ee')]+'\x20-\x20'+_0x3b497['statusText']:_0x306632('0x1b71'),'msg':_0x3b497['status']?JSON[_0x306632('0x258a')](_0x3b497['data']):_0x3b497[_0x306632('0x1ff0')]()});})[_0x458ccc('0x2874')](function(){_0x896647['loading']=![];});}function _0x54833d(){const _0x571690=_0x12b8ad;_0x7e32c8[_0x571690('0x1715')]();}}const _0x29c663=_0x3632b5;_0x289d7d[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xaf6'),'listsCampaign',_0x189033('0x238d'),'$q'];function _0x289d7d(_0x38cb4d,_0x372361,_0x3c8701,_0x438b36,_0x5a732e,_0x5a5042,_0x13a640,_0x348baf){const _0x230ad4=_0x189033,_0x42c8a7=this;_0x42c8a7[_0x230ad4('0x1939')]=[],_0x42c8a7[_0x230ad4('0x1996')]=_0x5a5042?_0x5a5042:[],_0x42c8a7['loading']=![],_0x42c8a7[_0x230ad4('0xf82')]=_0x26dc5d,_0x42c8a7[_0x230ad4('0x9dd')]=_0x2d2aca,_0x42c8a7[_0x230ad4('0x1b9a')]=_0x700701,_0x42c8a7[_0x230ad4('0x4f2')]=_0x240964,_0x42c8a7[_0x230ad4('0x972')]=_0x24897b,_0x42c8a7[_0x230ad4('0x2478')]=_0x49b3b8,_0x42c8a7[_0x230ad4('0x273c')]=_0x5c038c;function _0x700701(_0x37eb2b,_0x1d5691){const _0x2a3bf7=_0x230ad4,_0x5b2c82=_0x1d5691[_0x2a3bf7('0x824')](_0x37eb2b);_0x5b2c82>-0x1?_0x1d5691[_0x2a3bf7('0x2040')](_0x5b2c82,0x1):_0x1d5691[_0x2a3bf7('0x1fd0')](_0x37eb2b);}function _0x2d2aca(_0x1f15f0,_0xc9b885){const _0x499536=_0x230ad4;return _0xc9b885[_0x499536('0x824')](_0x1f15f0)>-0x1;}function _0x240964(){const _0x2a296b=_0x230ad4;return _0x42c8a7[_0x2a296b('0x1939')][_0x2a296b('0x1564')]!==0x0&&_0x42c8a7[_0x2a296b('0x1939')][_0x2a296b('0x1564')]!==_0x42c8a7[_0x2a296b('0x1996')][_0x2a296b('0x1564')];}function _0x24897b(){const _0x2ae174=_0x230ad4;return _0x42c8a7[_0x2ae174('0x1939')][_0x2ae174('0x1564')]===_0x42c8a7[_0x2ae174('0x1996')][_0x2ae174('0x1564')];}function _0x49b3b8(){const _0x49374e=_0x230ad4;if(_0x42c8a7[_0x49374e('0x1939')][_0x49374e('0x1564')]===_0x42c8a7['items'][_0x49374e('0x1564')])_0x42c8a7['selected']=[];else(_0x42c8a7[_0x49374e('0x1939')][_0x49374e('0x1564')]===0x0||_0x42c8a7[_0x49374e('0x1939')][_0x49374e('0x1564')]>0x0)&&(_0x42c8a7[_0x49374e('0x1939')]=_0x42c8a7[_0x49374e('0x1996')][_0x49374e('0x12c8')](0x0));}function _0x26dc5d(){const _0x22c455=_0x230ad4;_0x372361[_0x22c455('0x1715')]();}function _0x5c038c(){const _0x184c60=_0x230ad4;_0x42c8a7[_0x184c60('0x2195')]=!![];const _0x427842=_0x1b986b();_0x427842[_0x184c60('0x2874')](function(){const _0xf5b2ca=_0x184c60;_0x42c8a7[_0xf5b2ca('0x2195')]=![],_0x26dc5d();});}function _0x1b986b(){return _0x348baf(function(_0x4576d6){const _0x5e700c=a0_0x4e0a;for(let _0xb972ae=0x0;_0xb972ae<_0x42c8a7[_0x5e700c('0x1939')][_0x5e700c('0x1564')];_0xb972ae+=0x1){_0xcb232a(_0x5a732e['id'],_0x42c8a7[_0x5e700c('0x1939')][_0xb972ae]);}_0x3d28af(_0x4576d6);});}function _0xcb232a(_0x392a79,_0x3bc45e){const _0x378036=_0x230ad4,_0x51fb89=_0x3bc45e['id'];_0x13a640[_0x378036('0x105a')](function(){const _0x1538e4=_0x378036;return _0x438b36[_0x1538e4('0x6e9')][_0x1538e4('0x8d2')]({'id':_0x392a79,'ids':_0x51fb89})[_0x1538e4('0xe53')][_0x1538e4('0x683')](function(){const _0x5b41c2=_0x1538e4;return _0x438b36[_0x5b41c2('0x6e9')]['addLists']({'id':_0x392a79,'ids':_0x51fb89,'dialCheckDuplicateType':_0x5b41c2('0x649')})['$promise'];})[_0x1538e4('0x683')](function(){const _0x13fc69=_0x1538e4;_0x3c8701[_0x13fc69('0x53')]({'title':_0x13fc69('0x191'),'msg':_0x13fc69('0x1bb2')+_0x3bc45e[_0x13fc69('0x60a')]+'\x20has\x20been\x20reset'});})[_0x1538e4('0x130a')](function(_0x2cc610){const _0x3a7087=_0x1538e4;_0x3c8701[_0x3a7087('0x52a')]({'title':_0x2cc610[_0x3a7087('0x13ee')]?_0x3a7087('0x2168')+_0x2cc610[_0x3a7087('0x13ee')]+'\x20-\x20'+_0x2cc610[_0x3a7087('0x24a9')]:_0x3a7087('0x16c8'),'msg':_0x2cc610[_0x3a7087('0x13ee')]?JSON['stringify'](_0x2cc610[_0x3a7087('0x5a5')]):_0x2cc610[_0x3a7087('0x1ff0')]()});});});}function _0x3d28af(_0x363398){const _0x160b44=_0x230ad4;_0x13a640[_0x160b44('0x105a')](function(){return _0x363398();});}}const _0x38647b=_0x289d7d,_0x55e12b=_0x180212['p']+_0x189033('0x2586'),_0x2a94dc=_0x180212['p']+_0x189033('0x11ad'),_0x2c547b=_0x180212['p']+_0x189033('0x884'),_0x5acfa1=_0x180212['p']+_0x189033('0x27b');_0x300ce3[_0x189033('0x14be')]=[_0x189033('0x938'),'$location',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),'api',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xaf6'),_0x189033('0x22df')];function _0x300ce3(_0x58e729,_0x242e9a,_0x463372,_0xa30771,_0x8c3caa,_0x4a69b6,_0x3d8986,_0x283f3d,_0x282854,_0x3b801,_0x2d759c,_0x4d4264){const _0x334be1=_0x189033,_0x202d16=this;_0x202d16[_0x334be1('0x11ed')]=_0x3b801[_0x334be1('0x20b2')](),_0x202d16[_0x334be1('0xace')]=_0x4a69b6,_0x202d16[_0x334be1('0x260a')]=_0x3d8986,_0x202d16[_0x334be1('0x19b2')]=_0x202d16['setting']['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x202d16[_0x334be1('0x1224')]=_0x242e9a['protocol']()+_0x334be1('0x20de')+_0x242e9a['host'](),_0x202d16[_0x334be1('0xaf6')]=_0x2d759c||_0x58e729['params'][_0x334be1('0xaf6')]||{},_0x202d16[_0x334be1('0x22df')]=_0x4d4264&&_0x4d4264[_0x334be1('0x50d')]==0x1?_0x4d4264[_0x334be1('0xf5d')][0x0]:null,_0x202d16[_0x334be1('0x1134')]=_0x3b801[_0x334be1('0x142a')](_0x202d16[_0x334be1('0x22df')]?_0x202d16[_0x334be1('0x22df')][_0x334be1('0x1134')]:null),_0x202d16[_0x334be1('0x258d')]={},_0x202d16['selectedTab']=_0x58e729['params'][_0x334be1('0x1904')]||0x0,_0x202d16[_0x334be1('0x163d')]=_0x4600e0,_0x202d16[_0x334be1('0x1a50')]=_0x37c24e,_0x202d16[_0x334be1('0x277a')]=_0x568cfe,_0x202d16['resetlistdialog']=_0x332444,_0x202d16[_0x334be1('0x1a9f')]=_0x116fe1,_0x202d16[_0x334be1('0x2430')]=_0x282854[_0x334be1('0x2289')],_0x202d16[_0x334be1('0xef0')]=_0x3538b6,_0x202d16['saveIvrCampaign']=_0x5760d8,_0x3b801[_0x334be1('0xca1')]('admin')?_0x283f3d[_0x334be1('0x1a93')][_0x334be1('0x1e6e')]({'fields':'id,name','sort':_0x334be1('0x60a')})[_0x334be1('0xe53')][_0x334be1('0x683')](function(_0x1d6362){_0x202d16['trunks']=_0x1d6362['rows']||[];})[_0x334be1('0x130a')](function(_0x81599f){const _0x4912cd=_0x334be1;_0x282854[_0x4912cd('0x52a')]({'title':_0x81599f['status']?_0x4912cd('0x2168')+_0x81599f[_0x4912cd('0x13ee')]+'\x20-\x20'+_0x81599f[_0x4912cd('0x24a9')]:_0x4912cd('0xfd0'),'msg':_0x81599f[_0x4912cd('0x5a5')]?JSON['stringify'](_0x81599f[_0x4912cd('0x5a5')]):_0x81599f['toString']()});}):_0x283f3d[_0x334be1('0x1a93')]['get']({'fields':'id,name','sort':'name'})[_0x334be1('0xe53')][_0x334be1('0x683')](function(_0x100701){const _0x3b8327=_0x334be1;_0x202d16[_0x3b8327('0x20fe')]=_0x100701[_0x3b8327('0xf5d')]||[];})[_0x334be1('0x683')](function(){const _0x4bdbdc=_0x334be1;return _0x283f3d[_0x4bdbdc('0x22df')][_0x4bdbdc('0x1e6e')]({'userProfileId':_0x202d16['currentUser'][_0x4bdbdc('0x2f')],'sectionId':0x3f3})['$promise'];})[_0x334be1('0x683')](function(_0x4a5efc){const _0x12c141=_0x334be1,_0x5de554=_0x4a5efc&&_0x4a5efc['rows']?_0x4a5efc['rows'][0x0]:null;if(!_0x5de554)_0x202d16[_0x12c141('0x20fe')]=[];else{if(!_0x5de554[_0x12c141('0x170')])return _0x283f3d[_0x12c141('0xcf7')][_0x12c141('0x1e6e')]({'sectionId':_0x5de554['id']})[_0x12c141('0xe53')][_0x12c141('0x683')](function(_0x1a9768){const _0x82fe4f=_0x12c141,_0x223ebc=_0x2e3ca0()[_0x82fe4f('0x386')](_0x1a9768[_0x82fe4f('0xf5d')],function(_0x40bf00){const _0x3d0bb9=_0x82fe4f;return _0x2e3ca0()[_0x3d0bb9('0x1c07')](_0x202d16[_0x3d0bb9('0x20fe')],{'id':_0x40bf00[_0x3d0bb9('0x832')]});});_0x202d16['trunks'][_0x82fe4f('0x1299')](function(_0x4ef017){const _0x564422=_0x82fe4f;!_0x2e3ca0()['some'](_0x223ebc,['id',_0x4ef017['id']])&&(_0x4ef017[_0x564422('0x319')]=![]),_0x223ebc['push'](_0x4ef017);}),_0x202d16[_0x82fe4f('0x20fe')]=_0x223ebc;});}})[_0x334be1('0x130a')](function(_0x24baf9){const _0x2f295b=_0x334be1;_0x282854[_0x2f295b('0x52a')]({'title':_0x24baf9[_0x2f295b('0x13ee')]?'API:'+_0x24baf9[_0x2f295b('0x13ee')]+'\x20-\x20'+_0x24baf9[_0x2f295b('0x24a9')]:_0x2f295b('0x93'),'msg':_0x24baf9['data']?JSON['stringify'](_0x24baf9[_0x2f295b('0x5a5')]):_0x24baf9[_0x2f295b('0x1ff0')]()});}),_0x3b801[_0x334be1('0xca1')]('admin')?_0x283f3d[_0x334be1('0x27ea')][_0x334be1('0x1e6e')]({'fields':_0x334be1('0xa10'),'sort':_0x334be1('0x60a')})[_0x334be1('0xe53')][_0x334be1('0x683')](function(_0x1ee14e){const _0x3203dc=_0x334be1;_0x202d16[_0x3203dc('0x1248')]=_0x1ee14e[_0x3203dc('0xf5d')]||[];})['catch'](function(_0x3ed038){const _0x117673=_0x334be1;_0x282854[_0x117673('0x52a')]({'title':_0x3ed038[_0x117673('0x13ee')]?_0x117673('0x2168')+_0x3ed038['status']+'\x20-\x20'+_0x3ed038[_0x117673('0x24a9')]:_0x117673('0xd0e'),'msg':_0x3ed038['data']?JSON[_0x117673('0x258a')](_0x3ed038[_0x117673('0x5a5')]):_0x3ed038[_0x117673('0x1ff0')]()});}):_0x283f3d[_0x334be1('0x27ea')][_0x334be1('0x1e6e')]({'fields':_0x334be1('0xa10'),'sort':_0x334be1('0x60a')})['$promise'][_0x334be1('0x683')](function(_0x484f9d){const _0x4e9872=_0x334be1;_0x202d16['projects']=_0x484f9d[_0x4e9872('0xf5d')]||[];})[_0x334be1('0x683')](function(){const _0xa84480=_0x334be1;return _0x283f3d[_0xa84480('0x22df')][_0xa84480('0x1e6e')]({'userProfileId':_0x202d16[_0xa84480('0x11ed')]['userProfileId'],'sectionId':0x44f})['$promise'];})[_0x334be1('0x683')](function(_0x1bb59f){const _0x2974c1=_0x334be1,_0x2ee2bb=_0x1bb59f&&_0x1bb59f['rows']?_0x1bb59f[_0x2974c1('0xf5d')][0x0]:null;if(!_0x2ee2bb){const _0x2115d8=[];let _0x872536=null;_0x202d16[_0x2974c1('0xaf6')]&&(_0x872536=_0x2e3ca0()[_0x2974c1('0x1c07')](_0x202d16[_0x2974c1('0x1248')],{'id':Number(_0x202d16[_0x2974c1('0xaf6')][_0x2974c1('0x16a5')])}));for(let _0x5210d5=0x0;_0x5210d5<_0x202d16['projects']['length'];_0x5210d5++){_0x872536&&_0x202d16[_0x2974c1('0x1248')][_0x5210d5]['id']===_0x872536['id']&&(_0x202d16['projects'][_0x5210d5]['canSelect']=![],_0x2115d8[_0x2974c1('0x1fd0')](_0x202d16['projects'][_0x5210d5]));}_0x202d16[_0x2974c1('0x1248')]=_0x2115d8;}else{if(!_0x2ee2bb[_0x2974c1('0x170')])return _0x283f3d[_0x2974c1('0xcf7')][_0x2974c1('0x1e6e')]({'sectionId':_0x2ee2bb['id']})[_0x2974c1('0xe53')][_0x2974c1('0x683')](function(_0x1abd25){const _0x368b25=_0x2974c1,_0xac22a2=_0x2e3ca0()[_0x368b25('0x386')](_0x1abd25[_0x368b25('0xf5d')],function(_0x16c064){const _0x779a32=_0x368b25;return _0x2e3ca0()['find'](_0x202d16[_0x779a32('0x1248')],{'id':_0x16c064[_0x779a32('0x832')]});});let _0x5b4800=null;_0x202d16[_0x368b25('0xaf6')]&&(_0x5b4800=_0x2e3ca0()[_0x368b25('0x1c07')](_0x202d16[_0x368b25('0x1248')],{'id':Number(_0x202d16['ivrCampaign'][_0x368b25('0x16a5')])}));if(_0x5b4800&&!_0x2e3ca0()[_0x368b25('0x7a2')](_0xac22a2,['id',_0x5b4800['id']])){const _0x5257ef=_0x2e3ca0()[_0x368b25('0x1c07')](_0x202d16['projects'],{'id':_0x5b4800['id']});_0x5257ef[_0x368b25('0x319')]=![],_0xac22a2[_0x368b25('0x1fd0')](_0x5257ef);}_0x202d16[_0x368b25('0x1248')]=_0xac22a2;});}})['catch'](function(_0x5490a7){const _0x1aebae=_0x334be1;_0x282854[_0x1aebae('0x52a')]({'title':_0x5490a7[_0x1aebae('0x13ee')]?_0x1aebae('0x2168')+_0x5490a7[_0x1aebae('0x13ee')]+_0x1aebae('0xbf6')+_0x5490a7[_0x1aebae('0x24a9')]:_0x1aebae('0x616'),'msg':_0x5490a7[_0x1aebae('0x5a5')]?JSON['stringify'](_0x5490a7[_0x1aebae('0x5a5')]):_0x5490a7[_0x1aebae('0x1ff0')]()});}),_0x3b801[_0x334be1('0xca1')](_0x334be1('0x20c2'))?_0x283f3d['interval'][_0x334be1('0x1e6e')]({'fields':_0x334be1('0xa10'),'sort':_0x334be1('0x60a'),'IntervalId':_0x334be1('0x13c')})[_0x334be1('0xe53')]['then'](function(_0x408cf5){const _0x439fa6=_0x334be1;_0x202d16[_0x439fa6('0x115c')]=_0x408cf5[_0x439fa6('0xf5d')]||[];})[_0x334be1('0x130a')](function(_0x370ed3){const _0x249f3b=_0x334be1;_0x282854[_0x249f3b('0x52a')]({'title':_0x370ed3[_0x249f3b('0x13ee')]?_0x249f3b('0x2168')+_0x370ed3[_0x249f3b('0x13ee')]+_0x249f3b('0xbf6')+_0x370ed3[_0x249f3b('0x24a9')]:'SYSTEM:GET_INTERVAL','msg':_0x370ed3[_0x249f3b('0x5a5')]?JSON[_0x249f3b('0x258a')](_0x370ed3[_0x249f3b('0x5a5')]):_0x370ed3['toString']()});}):_0x283f3d['interval']['get']({'fields':_0x334be1('0xa10'),'sort':_0x334be1('0x60a'),'IntervalId':_0x334be1('0x13c')})[_0x334be1('0xe53')][_0x334be1('0x683')](function(_0x244c36){const _0x350721=_0x334be1;_0x202d16[_0x350721('0x115c')]=_0x244c36[_0x350721('0xf5d')]||[];})[_0x334be1('0x683')](function(){const _0x316b2e=_0x334be1;return _0x283f3d[_0x316b2e('0x22df')]['get']({'userProfileId':_0x202d16[_0x316b2e('0x11ed')]['userProfileId'],'sectionId':0x3ec})[_0x316b2e('0xe53')];})['then'](function(_0x11e88e){const _0x3864ce=_0x334be1,_0x21864a=_0x11e88e&&_0x11e88e[_0x3864ce('0xf5d')]?_0x11e88e[_0x3864ce('0xf5d')][0x0]:null;if(!_0x21864a){const _0x5a4c48=[];let _0x1c5baf=null;_0x202d16[_0x3864ce('0xaf6')]&&(_0x1c5baf=_0x2e3ca0()[_0x3864ce('0x1c07')](_0x202d16[_0x3864ce('0x115c')],{'id':Number(_0x202d16['ivrCampaign'][_0x3864ce('0x5ae')])}));for(let _0x1eabc4=0x0;_0x1eabc4<_0x202d16['interval']['length'];_0x1eabc4++){_0x1c5baf&&_0x202d16[_0x3864ce('0x115c')][_0x1eabc4]['id']===_0x1c5baf['id']&&(_0x202d16[_0x3864ce('0x115c')][_0x1eabc4]['canSelect']=![],_0x5a4c48[_0x3864ce('0x1fd0')](_0x202d16['interval'][_0x1eabc4]));}_0x202d16[_0x3864ce('0x115c')]=_0x5a4c48;}else{if(!_0x21864a['autoAssociation'])return _0x283f3d[_0x3864ce('0xcf7')][_0x3864ce('0x1e6e')]({'sectionId':_0x21864a['id']})[_0x3864ce('0xe53')][_0x3864ce('0x683')](function(_0x296a56){const _0x481a07=_0x3864ce,_0x569cf9=_0x2e3ca0()[_0x481a07('0x386')](_0x296a56['rows'],function(_0x137559){const _0x426e11=_0x481a07;return _0x2e3ca0()[_0x426e11('0x1c07')](_0x202d16['interval'],{'id':_0x137559[_0x426e11('0x832')]});});let _0x2f73e3=null;_0x202d16[_0x481a07('0xaf6')]&&(_0x2f73e3=_0x2e3ca0()[_0x481a07('0x1c07')](_0x202d16[_0x481a07('0x115c')],{'id':Number(_0x202d16[_0x481a07('0xaf6')]['IntervalId'])}));if(_0x2f73e3&&!_0x2e3ca0()['some'](_0x569cf9,['id',_0x2f73e3['id']])){const _0x5036b8=_0x2e3ca0()['find'](_0x202d16[_0x481a07('0x115c')],{'id':_0x2f73e3['id']});_0x5036b8[_0x481a07('0x319')]=![],_0x569cf9[_0x481a07('0x1fd0')](_0x5036b8);}_0x202d16['interval']=_0x569cf9;});}})[_0x334be1('0x130a')](function(_0x360a0c){const _0x2ddf5e=_0x334be1;_0x282854[_0x2ddf5e('0x52a')]({'title':_0x360a0c['status']?_0x2ddf5e('0x2168')+_0x360a0c['status']+'\x20-\x20'+_0x360a0c[_0x2ddf5e('0x24a9')]:_0x2ddf5e('0x203'),'msg':_0x360a0c[_0x2ddf5e('0x5a5')]?JSON['stringify'](_0x360a0c[_0x2ddf5e('0x5a5')]):_0x360a0c[_0x2ddf5e('0x1ff0')]()});});function _0x4600e0(_0x4e4dcb,_0x3162dc){const _0x5a9cce=_0x334be1;_0x463372['show']({'controller':_0x5a9cce('0x25c4'),'controllerAs':'vm','templateUrl':_0x55e12b,'parent':angular[_0x5a9cce('0x1fcc')](_0xa30771[_0x5a9cce('0x18e5')]),'targetEvent':_0x3162dc,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x4e4dcb,'ivrCampaigns':_0x202d16['ivrCampaigns']?_0x202d16[_0x5a9cce('0xf0e')]['rows']:[],'crudPermissions':_0x202d16[_0x5a9cce('0x1134')]}});}function _0x37c24e(_0xa37460,_0x10f895){const _0x2bb7f3=_0x334be1;_0x463372[_0x2bb7f3('0x1d4')]({'controller':_0x2bb7f3('0x34b'),'controllerAs':'vm','templateUrl':_0x2a94dc,'parent':angular[_0x2bb7f3('0x1fcc')](_0xa30771[_0x2bb7f3('0x18e5')]),'targetEvent':_0x10f895,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0xa37460,'ivrCampaigns':_0x202d16[_0x2bb7f3('0xf0e')]?_0x202d16[_0x2bb7f3('0xf0e')][_0x2bb7f3('0xf5d')]:[],'crudPermissions':_0x202d16[_0x2bb7f3('0x1134')]}});}function _0x568cfe(_0xa26191,_0x22a262){const _0x42728c=_0x334be1;_0x463372[_0x42728c('0x1d4')]({'controller':_0x42728c('0x1234'),'controllerAs':'vm','templateUrl':_0x2c547b,'parent':angular[_0x42728c('0x1fcc')](_0xa30771[_0x42728c('0x18e5')]),'targetEvent':_0x22a262,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0xa26191,'ivrCampaigns':_0x202d16[_0x42728c('0xf0e')]?_0x202d16[_0x42728c('0xf0e')][_0x42728c('0xf5d')]:[],'crudPermissions':_0x202d16[_0x42728c('0x1134')]}});}function _0x2c1f76(_0x312fe5,_0x5b4413){const _0x407d1a=_0x334be1,_0xb66db5=_0x5b4413['id'];_0x283f3d[_0x407d1a('0x6e9')][_0x407d1a('0x8d2')]({'id':_0x312fe5,'ids':_0xb66db5})['$promise'][_0x407d1a('0x683')](function(){const _0x4464cb=_0x407d1a;return _0x283f3d[_0x4464cb('0x6e9')][_0x4464cb('0x11ef')]({'id':_0x312fe5,'ids':_0xb66db5,'dialCheckDuplicateType':_0x4464cb('0x649')})['$promise'];})[_0x407d1a('0x683')](function(){const _0x192416=_0x407d1a;_0x282854[_0x192416('0x53')]({'title':'Reset\x20Succesfull','msg':_0x192416('0x1bb2')+_0x5b4413[_0x192416('0x60a')]+_0x192416('0x22e2')});})['catch'](function(_0x2f6cc8){const _0x352700=_0x407d1a;_0x282854[_0x352700('0x52a')]({'title':_0x2f6cc8['status']?_0x352700('0x2168')+_0x2f6cc8[_0x352700('0x13ee')]+'\x20-\x20'+_0x2f6cc8[_0x352700('0x24a9')]:_0x352700('0xf0b'),'msg':_0x2f6cc8[_0x352700('0x13ee')]?JSON['stringify'](_0x2f6cc8[_0x352700('0x5a5')]):_0x2f6cc8[_0x352700('0x1ff0')]()});});}function _0x332444(_0x551378,_0x5e0226){const _0x10407e=_0x334be1;_0x283f3d['campaign'][_0x10407e('0x16c3')]({'id':_0x551378['id'],'fields':_0x10407e('0xa10'),'nolimit':!![]})['$promise'][_0x10407e('0x683')](function(_0x28aa39){const _0x58cfd7=_0x10407e;if(_0x2e3ca0()[_0x58cfd7('0x8f2')](_0x28aa39[_0x58cfd7('0xf5d')])||_0x2e3ca0()[_0x58cfd7('0x173f')](_0x28aa39['rows']))_0x282854[_0x58cfd7('0x2289')]({'title':_0x58cfd7('0x174b')});else{if(_0x28aa39[_0x58cfd7('0xf5d')][_0x58cfd7('0x1564')]===0x1){const _0x2b9c36=_0x463372[_0x58cfd7('0x1c6f')]()[_0x58cfd7('0xf28')](_0x58cfd7('0x145e')+_0x28aa39[_0x58cfd7('0xf5d')][0x0][_0x58cfd7('0x60a')]+'\x20?')[_0x58cfd7('0x26e3')](''+_0x28aa39['rows'][0x0][_0x58cfd7('0x60a')]+''+'\x20will\x20be\x20reset.')[_0x58cfd7('0x1040')](_0x58cfd7('0x2530'))['targetEvent'](_0x5e0226)['ok']('OK')[_0x58cfd7('0x19fb')](_0x58cfd7('0x16b8'));_0x463372['show'](_0x2b9c36)[_0x58cfd7('0x683')](function(){const _0x789ab8=_0x58cfd7;_0x2c1f76(_0x202d16[_0x789ab8('0xaf6')]['id'],_0x28aa39['rows'][0x0]);});}else _0x463372[_0x58cfd7('0x1d4')]({'controller':_0x58cfd7('0xaae'),'controllerAs':'vm','templateUrl':_0x5acfa1,'parent':angular['element'](_0xa30771['body']),'targetEvent':_0x5e0226,'clickOutsideToClose':![],'locals':{'ivrCampaign':_0x551378,'listsCampaign':_0x28aa39?_0x28aa39['rows']:[]}});}})[_0x10407e('0x130a')](function(_0x3b3514){const _0x3344b3=_0x10407e;_0x282854[_0x3344b3('0x52a')]({'title':_0x3b3514[_0x3344b3('0x13ee')]?_0x3344b3('0x2168')+_0x3b3514[_0x3344b3('0x13ee')]+_0x3344b3('0xbf6')+_0x3b3514['statusText']:_0x3344b3('0x25b6'),'msg':_0x3b3514['status']?JSON[_0x3344b3('0x258a')](_0x3b3514[_0x3344b3('0x5a5')]):_0x3b3514['toString']()});});}function _0x116fe1(){const _0x5c539e=_0x334be1;if(_0x3b801[_0x5c539e('0xca1')](_0x5c539e('0x20c2')))_0x58e729['go'](_0x5c539e('0x1fc4'),{});else return _0x283f3d[_0x5c539e('0x22df')][_0x5c539e('0x1e6e')]({'userProfileId':_0x3b801['getCurrentUser']()[_0x5c539e('0x2f')],'sectionId':0x5e6})[_0x5c539e('0xe53')][_0x5c539e('0x683')](function(_0x3b129d){const _0x538671=_0x5c539e,_0x313e93=_0x3b129d&&_0x3b129d['rows']?_0x3b129d['rows'][0x0]:null;_0x313e93&&_0x313e93[_0x538671('0x1333')]?_0x58e729['go']('app.motiondialer.realtime.ivr_campaigns',{}):_0x282854[_0x538671('0x2289')]({'title':_0x8c3caa[_0x538671('0x2728')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0x8c3caa[_0x538671('0x2728')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_MESSAGE')});})[_0x5c539e('0x130a')](function(_0x5ac2b6){const _0x427749=_0x5c539e;_0x282854[_0x427749('0x52a')]({'title':_0x5ac2b6[_0x427749('0x13ee')]?_0x427749('0x2168')+_0x5ac2b6['status']+_0x427749('0xbf6')+_0x5ac2b6[_0x427749('0x24a9')]:_0x427749('0xf2a'),'msg':_0x5ac2b6[_0x427749('0x13ee')]?JSON[_0x427749('0x258a')](_0x5ac2b6[_0x427749('0x5a5')]):_0x5ac2b6[_0x427749('0x1ff0')]()});});}function _0x3538b6(){const _0x1dc73a=_0x334be1;_0x58e729['go'](_0x1dc73a('0xb4c'),{},{'reload':_0x1dc73a('0xb4c')});}function _0x5760d8(){const _0x56020a=_0x334be1;_0x283f3d[_0x56020a('0x6e9')][_0x56020a('0x2480')]({'id':_0x202d16[_0x56020a('0xaf6')]['id']},_0x202d16[_0x56020a('0xaf6')])[_0x56020a('0xe53')][_0x56020a('0x683')](function(){const _0x88fc53=_0x56020a;_0x282854[_0x88fc53('0x53')]({'title':'IvrCampaign\x20updated!','msg':_0x202d16['ivrCampaign'][_0x88fc53('0x60a')]?_0x202d16[_0x88fc53('0xaf6')][_0x88fc53('0x60a')]+_0x88fc53('0x96c'):''});})[_0x56020a('0x130a')](function(_0x5cf9f1){const _0x4e78d7=_0x56020a;_0x282854['error']({'title':_0x5cf9f1[_0x4e78d7('0x13ee')]?_0x4e78d7('0x2168')+_0x5cf9f1[_0x4e78d7('0x13ee')]+_0x4e78d7('0xbf6')+_0x5cf9f1[_0x4e78d7('0x24a9')]:_0x4e78d7('0x104'),'msg':_0x5cf9f1[_0x4e78d7('0x5a5')]?JSON[_0x4e78d7('0x258a')](_0x5cf9f1[_0x4e78d7('0x5a5')]):_0x5cf9f1['toString']()});});}}const _0x5b92ff=_0x300ce3;_0x298445[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0xf0e'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),'msUtils',_0x189033('0x1d70'),_0x189033('0xba1'),'license',_0x189033('0x260a')];function _0x298445(_0x24439e,_0x57fec3,_0xdb559e,_0x191e9b,_0x207a0a,_0x23d009,_0x3fea12,_0xbc5b5a,_0x4ca216,_0x528b86,_0x8ae4d0,_0x113532,_0x2005d0,_0x7ffc3c,_0x5e1976,_0x468a69,_0x210d60){const _0x227545=_0x189033,_0x3a58e=this;_0x3a58e[_0x227545('0xace')]=_0x468a69,_0x3a58e[_0x227545('0x260a')]=_0x210d60,_0x3a58e[_0x227545('0x11ed')]=_0x5e1976['getCurrentUser'](),_0x3a58e[_0x227545('0xf0e')]=_0x4ca216||{'count':0x0,'rows':[]},_0x3a58e[_0x227545('0x2a')]=_0x528b86,_0x3a58e['userProfileSection']=_0x8ae4d0&&_0x8ae4d0[_0x227545('0x50d')]==0x1?_0x8ae4d0['rows'][0x0]:null,_0x3a58e[_0x227545('0x1134')]=_0x5e1976[_0x227545('0x142a')](_0x3a58e[_0x227545('0x22df')]?_0x3a58e[_0x227545('0x22df')][_0x227545('0x1134')]:null),_0x3a58e[_0x227545('0x5c4')]=_0x227545('0xf0e'),_0x3a58e['listOrder']='',_0x3a58e[_0x227545('0x1ce2')]=null,_0x3a58e[_0x227545('0x1f84')]=[],_0x3a58e['query']={'fields':'createdAt,updatedAt,id,name,active,TrunkId,TrunkBackupId,type,IntervalId,dialCheckDuplicateType,dialCutDigit,SquareProjectId,limitCalls,description,dialOriginateCallerIdName,dialOriginateCallerIdNumber,dialRandomLastDigitCallerIdNumber,dialOriginateTimeout,dialGlobalMaxRetry,dialCongestionMaxRetry,dialCongestionRetryFrequency,dialBusyMaxRetry,dialBusyRetryFrequency,dialNoAnswerMaxRetry,dialNoAnswerRetryFrequency,dialNoSuchNumberMaxRetry,dialNoSuchNumberRetryFrequency,dialDropMaxRetry,dialDropRetryFrequency,dialAbandonedMaxRetry,dialAbandonedRetryFrequency,dialMachineMaxRetry,dialMachineRetryFrequency,dialAgentRejectMaxRetry,dialAgentRejectRetryFrequency,dialOrderByScheduledAt,dialGlobalInterval,dialTimezone,dialPrefix,dialAMDActive,dialAMDInitialSilence,dialAMDGreeting,dialAMDAfterGreetingSilence,dialAMDTotalAnalysisTime,dialAMDMinWordLength,dialAMDBetweenWordsSilence,dialAMDMaximumNumberOfWords,dialAMDSilenceThreshold,dialAMDMaximumWordLength','type':_0x227545('0x715'),'sort':_0x227545('0xc36'),'limit':0xa,'page':0x1},_0x3a58e['arraydialCheckDuplicateType']=_0x2e3ca0()[_0x227545('0x24db')]([{'option':_0x227545('0x126a'),'value':_0x227545('0x6c7')},{'option':_0x227545('0x21c3'),'value':'\x27never\x27'},{'option':_0x227545('0x1d12'),'value':_0x227545('0x1c71')}],function(_0x34b80b){return _0x2e3ca0()['replace'](_0x34b80b['value'],new RegExp('\x27','g'),'');}),_0x3a58e[_0x227545('0x7a9')]=_0x2e3ca0()[_0x227545('0x24db')]([{'option':'DESC','value':_0x227545('0x2496')},{'option':_0x227545('0xa0d'),'value':_0x227545('0x60c')}],function(_0x4c6723){const _0x1d8353=_0x227545;return _0x2e3ca0()[_0x1d8353('0x1725')](_0x4c6723[_0x1d8353('0x1c6b')],new RegExp('\x27','g'),'');}),_0x3a58e[_0x227545('0xc63')]=_0x6aa2eb,_0x3a58e[_0x227545('0x163d')]=_0x5c216f,_0x3a58e[_0x227545('0x1a50')]=_0x4e5d03,_0x3a58e[_0x227545('0x277a')]=_0x52af1d,_0x3a58e[_0x227545('0x194f')]=_0x259f22,_0x3a58e[_0x227545('0x213c')]=_0x2926dd,_0x3a58e[_0x227545('0x53')]=_0x1764d1,_0x3a58e[_0x227545('0x886')]=_0x4b7f03,_0x3a58e['createOrEditIvrCampaign']=_0x55cdd5,_0x3a58e['deleteIvrCampaign']=_0x4ea679,_0x3a58e['exportSelectedIvrCampaigns']=_0x1607f3,_0x3a58e[_0x227545('0xc8d')]=_0x3e4fe5,_0x3a58e[_0x227545('0x2189')]=_0x4270a7,_0x3a58e[_0x227545('0x1d93')]=_0x17ab24,_0x5e1976[_0x227545('0xca1')](_0x227545('0x20c2'))?_0x113532[_0x227545('0x1a93')][_0x227545('0x1e6e')]({'fields':_0x227545('0xa10'),'sort':'name','table':'true'})[_0x227545('0xe53')][_0x227545('0x683')](function(_0x43d5ff){const _0x298a9a=_0x227545;_0x3a58e['trunks']=_0x43d5ff[_0x298a9a('0xf5d')]||[];})[_0x227545('0x130a')](function(_0x44439a){const _0x3a057e=_0x227545;_0x7ffc3c['error']({'title':_0x44439a[_0x3a057e('0x13ee')]?_0x3a057e('0x2168')+_0x44439a[_0x3a057e('0x13ee')]+_0x3a057e('0xbf6')+_0x44439a[_0x3a057e('0x24a9')]:'SYSTEM:GET_TRUNKS','msg':_0x44439a[_0x3a057e('0x5a5')]?JSON[_0x3a057e('0x258a')](_0x44439a[_0x3a057e('0x5a5')]):_0x44439a[_0x3a057e('0x1ff0')]()});}):_0x113532[_0x227545('0x1a93')][_0x227545('0x1e6e')]({'fields':_0x227545('0xa10'),'sort':_0x227545('0x60a'),'table':_0x227545('0x26ac')})[_0x227545('0xe53')][_0x227545('0x683')](function(_0x33a067){const _0x522ad6=_0x227545;_0x3a58e[_0x522ad6('0x20fe')]=_0x33a067[_0x522ad6('0xf5d')]||[];})[_0x227545('0x683')](function(){const _0x2cfebe=_0x227545;return _0x113532[_0x2cfebe('0x22df')][_0x2cfebe('0x1e6e')]({'userProfileId':_0x3a58e['currentUser'][_0x2cfebe('0x2f')],'sectionId':0x3f3})[_0x2cfebe('0xe53')];})['then'](function(_0x261ded){const _0xec6100=_0x227545,_0x1a3755=_0x261ded&&_0x261ded[_0xec6100('0xf5d')]?_0x261ded[_0xec6100('0xf5d')][0x0]:null;if(!_0x1a3755)_0x3a58e['trunks']=[];else{if(!_0x1a3755[_0xec6100('0x170')])return _0x113532[_0xec6100('0xcf7')][_0xec6100('0x1e6e')]({'sectionId':_0x1a3755['id']})[_0xec6100('0xe53')][_0xec6100('0x683')](function(_0x43221a){const _0x151ca=_0xec6100,_0x5e31cf=_0x2e3ca0()[_0x151ca('0x386')](_0x43221a[_0x151ca('0xf5d')],function(_0x52ed26){const _0x262dd3=_0x151ca;return _0x2e3ca0()['find'](_0x3a58e['trunks'],{'id':_0x52ed26[_0x262dd3('0x832')]});});_0x3a58e[_0x151ca('0x20fe')][_0x151ca('0x1299')](function(_0x1a7269){const _0x1474c0=_0x151ca;!_0x2e3ca0()['some'](_0x5e31cf,['id',_0x1a7269['id']])&&(_0x1a7269[_0x1474c0('0x319')]=![]),_0x5e31cf['push'](_0x1a7269);}),_0x3a58e[_0x151ca('0x20fe')]=_0x5e31cf;});}})[_0x227545('0x130a')](function(_0x2d704a){const _0x2a67b0=_0x227545;_0x7ffc3c[_0x2a67b0('0x52a')]({'title':_0x2d704a[_0x2a67b0('0x13ee')]?'API:'+_0x2d704a[_0x2a67b0('0x13ee')]+'\x20-\x20'+_0x2d704a[_0x2a67b0('0x24a9')]:_0x2a67b0('0x93'),'msg':_0x2d704a[_0x2a67b0('0x5a5')]?JSON[_0x2a67b0('0x258a')](_0x2d704a[_0x2a67b0('0x5a5')]):_0x2d704a[_0x2a67b0('0x1ff0')]()});}),_0x5e1976[_0x227545('0xca1')](_0x227545('0x20c2'))?_0x113532[_0x227545('0x27ea')][_0x227545('0x1e6e')]({'fields':'id,name','sort':_0x227545('0x60a')})[_0x227545('0xe53')][_0x227545('0x683')](function(_0x8207e9){const _0x47f551=_0x227545;_0x3a58e[_0x47f551('0x1248')]=_0x8207e9[_0x47f551('0xf5d')]||[];})[_0x227545('0x130a')](function(_0x2b33c9){const _0x378a27=_0x227545;_0x7ffc3c[_0x378a27('0x52a')]({'title':_0x2b33c9[_0x378a27('0x13ee')]?_0x378a27('0x2168')+_0x2b33c9[_0x378a27('0x13ee')]+_0x378a27('0xbf6')+_0x2b33c9[_0x378a27('0x24a9')]:'SYSTEM:GET_PROJECTS','msg':_0x2b33c9['data']?JSON[_0x378a27('0x258a')](_0x2b33c9[_0x378a27('0x5a5')]):_0x2b33c9[_0x378a27('0x1ff0')]()});}):_0x113532[_0x227545('0x27ea')][_0x227545('0x1e6e')]({'fields':'id,name','sort':_0x227545('0x60a')})[_0x227545('0xe53')][_0x227545('0x683')](function(_0x3fa506){const _0x13e1ea=_0x227545;_0x3a58e[_0x13e1ea('0x1248')]=_0x3fa506[_0x13e1ea('0xf5d')]||[];})['then'](function(){const _0x28ba0a=_0x227545;return _0x113532[_0x28ba0a('0x22df')][_0x28ba0a('0x1e6e')]({'userProfileId':_0x3a58e['currentUser'][_0x28ba0a('0x2f')],'sectionId':0x44f})['$promise'];})['then'](function(_0x3da3fb){const _0x584a4b=_0x227545,_0x39f435=_0x3da3fb&&_0x3da3fb[_0x584a4b('0xf5d')]?_0x3da3fb[_0x584a4b('0xf5d')][0x0]:null;if(!_0x39f435){const _0x5393f7=[],_0x43f1ee=[];_0x3a58e[_0x584a4b('0xf0e')][_0x584a4b('0xf5d')][_0x584a4b('0x1299')](function(_0x5d2be0){const _0x50b357=_0x584a4b,_0x48ea9a=_0x2e3ca0()[_0x50b357('0x1c07')](_0x3a58e['projects'],{'id':Number(_0x5d2be0['SquareProjectId'])});_0x43f1ee[_0x50b357('0x1fd0')](_0x48ea9a);});for(let _0x5c4518=0x0;_0x5c4518<_0x3a58e['projects'][_0x584a4b('0x1564')];_0x5c4518++){const _0x110f85=_0x2e3ca0()['some'](_0x43f1ee,{'id':_0x3a58e['projects'][_0x5c4518]['id']});_0x110f85&&(_0x3a58e['projects'][_0x5c4518][_0x584a4b('0x319')]=![],_0x5393f7[_0x584a4b('0x1fd0')](_0x3a58e[_0x584a4b('0x1248')][_0x5c4518]));}_0x3a58e[_0x584a4b('0x1248')]=_0x5393f7;}else{if(!_0x39f435[_0x584a4b('0x170')])return _0x113532['userProfileResource'][_0x584a4b('0x1e6e')]({'sectionId':_0x39f435['id']})[_0x584a4b('0xe53')][_0x584a4b('0x683')](function(_0x2b9e7c){const _0xa6c0a6=_0x584a4b,_0x347ee5=_0x2e3ca0()['map'](_0x2b9e7c[_0xa6c0a6('0xf5d')],function(_0x5c42da){const _0x2da897=_0xa6c0a6;return _0x2e3ca0()[_0x2da897('0x1c07')](_0x3a58e['projects'],{'id':_0x5c42da['resourceId']});});let _0xf1a8f4=null;_0xf1a8f4=[],_0x3a58e[_0xa6c0a6('0xf0e')]['rows']['forEach'](function(_0x49210a){const _0x569e8b=_0xa6c0a6,_0x1232a4=_0x2e3ca0()['find'](_0x3a58e[_0x569e8b('0x1248')],{'id':Number(_0x49210a['SquareProjectId'])});_0xf1a8f4[_0x569e8b('0x1fd0')](_0x1232a4);}),!_0x2e3ca0()[_0xa6c0a6('0x173f')](_0xf1a8f4)&&_0xf1a8f4['forEach'](function(_0x2588a6){const _0x4d87fa=_0xa6c0a6;if(!_0x2e3ca0()[_0x4d87fa('0x7a2')](_0x347ee5,['id',_0x2588a6['id']])){const _0x4fca4b=_0x2e3ca0()[_0x4d87fa('0x1c07')](_0x3a58e[_0x4d87fa('0x1248')],{'id':_0x2588a6['id']});_0x4fca4b[_0x4d87fa('0x319')]=![],_0x347ee5[_0x4d87fa('0x1fd0')](_0x4fca4b);}}),_0x3a58e[_0xa6c0a6('0x1248')]=_0x347ee5;});}})['catch'](function(_0x1b9d83){const _0x1a572=_0x227545;_0x7ffc3c['error']({'title':_0x1b9d83[_0x1a572('0x13ee')]?'API:'+_0x1b9d83['status']+_0x1a572('0xbf6')+_0x1b9d83[_0x1a572('0x24a9')]:_0x1a572('0x616'),'msg':_0x1b9d83[_0x1a572('0x5a5')]?JSON[_0x1a572('0x258a')](_0x1b9d83[_0x1a572('0x5a5')]):_0x1b9d83[_0x1a572('0x1ff0')]()});}),_0x5e1976[_0x227545('0xca1')](_0x227545('0x20c2'))?_0x113532[_0x227545('0x115c')]['get']({'fields':'id,name','sort':_0x227545('0x60a'),'IntervalId':_0x227545('0x13c')})[_0x227545('0xe53')]['then'](function(_0x443f3e){_0x3a58e['interval']=_0x443f3e['rows']||[];})[_0x227545('0x130a')](function(_0x4287ef){const _0x55984b=_0x227545;_0x7ffc3c[_0x55984b('0x52a')]({'title':_0x4287ef[_0x55984b('0x13ee')]?_0x55984b('0x2168')+_0x4287ef[_0x55984b('0x13ee')]+_0x55984b('0xbf6')+_0x4287ef['statusText']:'SYSTEM:GET_INTERVAL','msg':_0x4287ef[_0x55984b('0x5a5')]?JSON['stringify'](_0x4287ef[_0x55984b('0x5a5')]):_0x4287ef['toString']()});}):_0x113532[_0x227545('0x115c')][_0x227545('0x1e6e')]({'fields':_0x227545('0xa10'),'sort':_0x227545('0x60a'),'IntervalId':_0x227545('0x13c')})[_0x227545('0xe53')][_0x227545('0x683')](function(_0x5a8029){const _0x4190e6=_0x227545;_0x3a58e['interval']=_0x5a8029[_0x4190e6('0xf5d')]||[];})[_0x227545('0x683')](function(){const _0x5284a6=_0x227545;return _0x113532[_0x5284a6('0x22df')][_0x5284a6('0x1e6e')]({'userProfileId':_0x3a58e['currentUser'][_0x5284a6('0x2f')],'sectionId':0x3ec})[_0x5284a6('0xe53')];})['then'](function(_0x56bb32){const _0x100352=_0x227545,_0x1c9f0d=_0x56bb32&&_0x56bb32[_0x100352('0xf5d')]?_0x56bb32[_0x100352('0xf5d')][0x0]:null;if(!_0x1c9f0d){const _0x1532d4=[];let _0x4fd0ff=null;_0x3a58e[_0x100352('0xaf6')]&&(_0x4fd0ff=_0x2e3ca0()[_0x100352('0x1c07')](_0x3a58e['interval'],{'id':Number(_0x3a58e[_0x100352('0xaf6')][_0x100352('0x5ae')])}));for(let _0x368287=0x0;_0x368287<_0x3a58e[_0x100352('0x115c')][_0x100352('0x1564')];_0x368287++){_0x4fd0ff&&_0x3a58e['interval'][_0x368287]['id']===_0x4fd0ff['id']&&(_0x3a58e[_0x100352('0x115c')][_0x368287]['canSelect']=![],_0x1532d4[_0x100352('0x1fd0')](_0x3a58e[_0x100352('0x115c')][_0x368287]));}_0x3a58e[_0x100352('0x115c')]=_0x1532d4;}else{if(!_0x1c9f0d[_0x100352('0x170')])return _0x113532['userProfileResource'][_0x100352('0x1e6e')]({'sectionId':_0x1c9f0d['id']})[_0x100352('0xe53')][_0x100352('0x683')](function(_0x3363da){const _0x174134=_0x100352,_0x49503e=_0x2e3ca0()['map'](_0x3363da[_0x174134('0xf5d')],function(_0x2e0bbd){const _0xef2d4a=_0x174134;return _0x2e3ca0()['find'](_0x3a58e[_0xef2d4a('0x115c')],{'id':_0x2e0bbd['resourceId']});});let _0x4a387c=null;_0x3a58e[_0x174134('0xaf6')]&&(_0x4a387c=_0x2e3ca0()[_0x174134('0x1c07')](_0x3a58e[_0x174134('0x115c')],{'id':Number(_0x3a58e['ivrCampaign']['IntervalId'])}));if(_0x4a387c&&!_0x2e3ca0()['some'](_0x49503e,['id',_0x4a387c['id']])){const _0x3bbf12=_0x2e3ca0()[_0x174134('0x1c07')](_0x3a58e[_0x174134('0x115c')],{'id':_0x4a387c['id']});_0x3bbf12['canSelect']=![],_0x49503e['push'](_0x3bbf12);}_0x3a58e[_0x174134('0x115c')]=_0x49503e;});}})[_0x227545('0x130a')](function(_0x2b1e20){const _0x7af73c=_0x227545;_0x7ffc3c[_0x7af73c('0x52a')]({'title':_0x2b1e20['status']?_0x7af73c('0x2168')+_0x2b1e20[_0x7af73c('0x13ee')]+'\x20-\x20'+_0x2b1e20[_0x7af73c('0x24a9')]:_0x7af73c('0x203'),'msg':_0x2b1e20['data']?JSON['stringify'](_0x2b1e20[_0x7af73c('0x5a5')]):_0x2b1e20[_0x7af73c('0x1ff0')]()});});function _0x6aa2eb(_0x4d744c){const _0x18420e=_0x227545;_0xdb559e['go'](_0x18420e('0x269'),{'id':_0x4d744c['id'],'ivrCampaign':_0x4d744c,'crudPermissions':_0x3a58e[_0x18420e('0x1134')]});}function _0x5c216f(_0x4bbdab,_0x59f3b0){const _0x3ae632=_0x227545;_0x207a0a[_0x3ae632('0x1d4')]({'controller':_0x3ae632('0x25c4'),'controllerAs':'vm','templateUrl':_0x55e12b,'parent':angular['element'](_0x23d009[_0x3ae632('0x18e5')]),'targetEvent':_0x59f3b0,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x4bbdab,'ivrCampaigns':_0x3a58e[_0x3ae632('0xf0e')]?_0x3a58e[_0x3ae632('0xf0e')][_0x3ae632('0xf5d')]:[],'crudPermissions':_0x3a58e['crudPermissions']}});}function _0x4e5d03(_0x45f734,_0x14c969){const _0x2cc4f8=_0x227545;_0x207a0a[_0x2cc4f8('0x1d4')]({'controller':'IvrCampaignlistaddController','controllerAs':'vm','templateUrl':_0x2a94dc,'parent':angular[_0x2cc4f8('0x1fcc')](_0x23d009[_0x2cc4f8('0x18e5')]),'targetEvent':_0x14c969,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x45f734,'ivrCampaigns':_0x3a58e[_0x2cc4f8('0xf0e')]?_0x3a58e[_0x2cc4f8('0xf0e')]['rows']:[],'crudPermissions':_0x3a58e[_0x2cc4f8('0x1134')]}});}function _0x52af1d(_0x1e2e68,_0x23f00f){const _0xa694b8=_0x227545;_0x207a0a[_0xa694b8('0x1d4')]({'controller':_0xa694b8('0x1234'),'controllerAs':'vm','templateUrl':_0x2c547b,'parent':angular[_0xa694b8('0x1fcc')](_0x23d009[_0xa694b8('0x18e5')]),'targetEvent':_0x23f00f,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x1e2e68,'ivrCampaigns':_0x3a58e[_0xa694b8('0xf0e')]?_0x3a58e[_0xa694b8('0xf0e')][_0xa694b8('0xf5d')]:[],'crudPermissions':_0x3a58e[_0xa694b8('0x1134')]}});}function _0x259f22(_0x5b6703,_0xeca06){const _0x2ef222=_0x227545,_0x23b9fc=_0x207a0a[_0x2ef222('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x2ef222('0x1e03')]('ivrCampaign')+'?')[_0x2ef222('0x26e3')](''+(_0x5b6703[_0x2ef222('0x60a')]||'ivrCampaign')+''+_0x2ef222('0x1ee7'))['ariaLabel'](_0x2ef222('0x288b'))[_0x2ef222('0xe42')](_0xeca06)['ok']('OK')[_0x2ef222('0x19fb')](_0x2ef222('0x16b8'));_0x207a0a[_0x2ef222('0x1d4')](_0x23b9fc)[_0x2ef222('0x683')](function(){_0x4ea679(_0x5b6703);},function(){console['log']('CANCEL');});}function _0x2926dd(){const _0x3c15c2=_0x227545;if(_0x5e1976[_0x3c15c2('0xca1')](_0x3c15c2('0x20c2')))_0xdb559e['go'](_0x3c15c2('0x1fc4'),{});else return _0x113532[_0x3c15c2('0x22df')][_0x3c15c2('0x1e6e')]({'userProfileId':_0x5e1976['getCurrentUser']()[_0x3c15c2('0x2f')],'sectionId':0x5e6})[_0x3c15c2('0xe53')]['then'](function(_0x303fd3){const _0x251707=_0x3c15c2,_0x2717ce=_0x303fd3&&_0x303fd3[_0x251707('0xf5d')]?_0x303fd3[_0x251707('0xf5d')][0x0]:null;_0x2717ce&&_0x2717ce['enabled']?_0xdb559e['go'](_0x251707('0x1fc4'),{}):_0x7ffc3c[_0x251707('0x2289')]({'title':_0xbc5b5a[_0x251707('0x2728')](_0x251707('0x213e')),'msg':_0xbc5b5a[_0x251707('0x2728')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_MESSAGE')});})[_0x3c15c2('0x130a')](function(_0x27de30){const _0x3d62cb=_0x3c15c2;_0x7ffc3c[_0x3d62cb('0x52a')]({'title':_0x27de30[_0x3d62cb('0x13ee')]?_0x3d62cb('0x2168')+_0x27de30[_0x3d62cb('0x13ee')]+_0x3d62cb('0xbf6')+_0x27de30[_0x3d62cb('0x24a9')]:_0x3d62cb('0xf2a'),'msg':_0x27de30[_0x3d62cb('0x13ee')]?JSON[_0x3d62cb('0x258a')](_0x27de30[_0x3d62cb('0x5a5')]):_0x27de30[_0x3d62cb('0x1ff0')]()});});}let _0x5e0fc5=!![],_0x43bc86=0x1;_0x24439e[_0x227545('0x186d')](_0x227545('0x1e1d'),function(_0x169985,_0x27a93e){const _0x5d0dc1=_0x227545;_0x5e0fc5?_0x3fea12(function(){_0x5e0fc5=![];}):(!_0x27a93e&&(_0x43bc86=_0x3a58e[_0x5d0dc1('0x23a2')][_0x5d0dc1('0xdf8')]),_0x169985!==_0x27a93e&&(_0x3a58e[_0x5d0dc1('0x23a2')][_0x5d0dc1('0xdf8')]=0x1),!_0x169985&&(_0x3a58e[_0x5d0dc1('0x23a2')][_0x5d0dc1('0xdf8')]=_0x43bc86),_0x3a58e[_0x5d0dc1('0x886')]());});function _0x1764d1(_0x3ca4d1){const _0x511ba1=_0x227545;_0x3a58e[_0x511ba1('0xf0e')]=_0x3ca4d1||{'count':0x0,'rows':[]};}function _0x4b7f03(){const _0x789ce7=_0x227545;_0x3a58e[_0x789ce7('0x23a2')][_0x789ce7('0x1cc8')]=(_0x3a58e['query'][_0x789ce7('0xdf8')]-0x1)*_0x3a58e[_0x789ce7('0x23a2')][_0x789ce7('0x6f0')],_0x5e1976['hasRole'](_0x789ce7('0x20c2'))?_0x3a58e[_0x789ce7('0x1883')]=_0x113532['campaign'][_0x789ce7('0x1e6e')](_0x3a58e[_0x789ce7('0x23a2')],_0x1764d1)[_0x789ce7('0xe53')]:(_0x3a58e['query']['id']=_0x3a58e['userProfile']['id'],_0x3a58e[_0x789ce7('0x23a2')][_0x789ce7('0x1aa')]=_0x789ce7('0x23db'),_0x3a58e[_0x789ce7('0x1883')]=_0x113532[_0x789ce7('0x2a')][_0x789ce7('0x241d')](_0x3a58e['query'],_0x1764d1)[_0x789ce7('0xe53')]);}function _0x55cdd5(_0x695cb2,_0x1fe43b){const _0x1fc7da=_0x227545;_0x207a0a[_0x1fc7da('0x1d4')]({'controller':_0x1fc7da('0x10cc'),'controllerAs':'vm','templateUrl':_0x44a61d,'parent':angular[_0x1fc7da('0x1fcc')](_0x23d009[_0x1fc7da('0x18e5')]),'targetEvent':_0x695cb2,'clickOutsideToClose':!![],'locals':{'ivrCampaign':_0x1fe43b,'ivrCampaigns':_0x3a58e[_0x1fc7da('0xf0e')]['rows'],'license':_0x3a58e['license'],'setting':_0x3a58e[_0x1fc7da('0x260a')],'crudPermissions':_0x3a58e[_0x1fc7da('0x1134')]}});}function _0x4ea679(_0x26ff97){const _0x26eadb=_0x227545;_0x113532[_0x26eadb('0x6e9')][_0x26eadb('0xd7e')]({'id':_0x26ff97['id']})[_0x26eadb('0xe53')][_0x26eadb('0x683')](function(){const _0x411d92=_0x26eadb;_0x2e3ca0()['remove'](_0x3a58e['ivrCampaigns'][_0x411d92('0xf5d')],{'id':_0x26ff97['id']}),_0x3a58e[_0x411d92('0xf0e')][_0x411d92('0x50d')]-=0x1,!_0x3a58e[_0x411d92('0xf0e')]['rows'][_0x411d92('0x1564')]&&_0x3a58e[_0x411d92('0x886')](),_0x7ffc3c[_0x411d92('0x53')]({'title':_0x2e3ca0()['startCase']('IvrCampaign')+_0x411d92('0xbfc'),'msg':_0x26ff97[_0x411d92('0x60a')]?_0x26ff97['name']+_0x411d92('0x194d'):''});})[_0x26eadb('0x130a')](function(_0x1bc4e2){const _0x4cc1ce=_0x26eadb;if(_0x1bc4e2[_0x4cc1ce('0x5a5')]&&_0x1bc4e2[_0x4cc1ce('0x5a5')]['errors']&&_0x1bc4e2['data'][_0x4cc1ce('0x17f')][_0x4cc1ce('0x1564')]){_0x3a58e[_0x4cc1ce('0x17f')]=_0x1bc4e2[_0x4cc1ce('0x5a5')]['errors']||[{'message':_0x1bc4e2[_0x4cc1ce('0x1ff0')](),'type':_0x4cc1ce('0x678')}];for(let _0x214014=0x0;_0x214014<_0x1bc4e2[_0x4cc1ce('0x5a5')]['errors'][_0x4cc1ce('0x1564')];_0x214014++){_0x7ffc3c[_0x4cc1ce('0x52a')]({'title':_0x1bc4e2[_0x4cc1ce('0x5a5')]['errors'][_0x214014][_0x4cc1ce('0xcf0')],'msg':_0x1bc4e2[_0x4cc1ce('0x5a5')][_0x4cc1ce('0x17f')][_0x214014]['message']});}}else _0x7ffc3c[_0x4cc1ce('0x52a')]({'title':_0x1bc4e2[_0x4cc1ce('0x13ee')]?_0x4cc1ce('0x2168')+_0x1bc4e2[_0x4cc1ce('0x13ee')]+_0x4cc1ce('0xbf6')+_0x1bc4e2[_0x4cc1ce('0x24a9')]:_0x4cc1ce('0x678'),'msg':_0x1bc4e2[_0x4cc1ce('0x5a5')]?JSON[_0x4cc1ce('0x258a')](_0x1bc4e2[_0x4cc1ce('0x5a5')][_0x4cc1ce('0x8c2')]):_0x1bc4e2['message']||_0x1bc4e2['toString']()});});}function _0x1607f3(){const _0x58bdc4=_0x227545,_0x8e1ef5=angular[_0x58bdc4('0x1a86')](_0x3a58e[_0x58bdc4('0x1f84')]);return _0x3a58e[_0x58bdc4('0x1f84')]=[],_0x8e1ef5;}function _0x3e4fe5(_0x429653){const _0x4db7ff=_0x227545,_0x3f1abd=_0x207a0a['confirm']()[_0x4db7ff('0xf28')](_0x4db7ff('0xe79'))[_0x4db7ff('0x26e3')](_0x4db7ff('0xed5')+_0x3a58e[_0x4db7ff('0x1f84')][_0x4db7ff('0x1564')]+'\x20selected'+_0x4db7ff('0x1ee7'))[_0x4db7ff('0x1040')](_0x4db7ff('0xef7'))[_0x4db7ff('0xe42')](_0x429653)['ok']('OK')['cancel'](_0x4db7ff('0x16b8'));_0x207a0a['show'](_0x3f1abd)[_0x4db7ff('0x683')](function(){const _0x4f0bdf=_0x4db7ff;_0x3a58e['selectedIvrCampaigns'][_0x4f0bdf('0x1299')](function(_0x49a4f5){_0x4ea679(_0x49a4f5);}),_0x3a58e[_0x4f0bdf('0x1f84')]=[];});}function _0x4270a7(){const _0x3a465c=_0x227545;_0x3a58e[_0x3a465c('0x1f84')]=[];}function _0x17ab24(){const _0x3fcec0=_0x227545;_0x3a58e['selectedIvrCampaigns']=_0x3a58e['ivrCampaigns'][_0x3fcec0('0xf5d')];}}const _0x53d3ad=_0x298445;_0xea50e4[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x2022'),'queueCampaign',_0x189033('0x56b'),_0x189033('0xba1'),'license','setting',_0x189033('0x1134')];function _0xea50e4(_0x2db11c,_0x3bf3ea,_0x12ebc2,_0x5d10ab,_0xe3eb98,_0x287896,_0x444c83,_0x2846fd,_0x39bce9,_0xaa787d,_0x4f643b,_0x539195,_0xd7f764,_0x249d27){const _0x49a3ba=_0x189033,_0x5f2004=this;_0x5f2004[_0x49a3ba('0x11ed')]=_0x4f643b[_0x49a3ba('0x20b2')](),_0x5f2004[_0x49a3ba('0x17f')]=[],_0x5f2004['setting']=_0xd7f764,_0x5f2004[_0x49a3ba('0xace')]=_0x539195,_0x5f2004[_0x49a3ba('0x1134')]=_0x249d27,_0x5f2004[_0x49a3ba('0x258d')]={},_0x5f2004[_0x49a3ba('0x19b2')]=_0x5f2004['setting']&&_0x5f2004[_0x49a3ba('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5f2004[_0x49a3ba('0xf28')]=_0x49a3ba('0x1a33'),_0x5f2004['queueCampaign']=angular[_0x49a3ba('0x1a86')](_0x39bce9),_0x5f2004[_0x49a3ba('0x2022')]=_0x2846fd,_0x5f2004[_0x49a3ba('0xe37')]=![];!_0x5f2004[_0x49a3ba('0x1bd9')]&&(_0x5f2004[_0x49a3ba('0x1bd9')]={'dialActive':!![],'type':_0x49a3ba('0x17cd'),'dialCheckDuplicateType':_0x49a3ba('0x10af'),'dialCutDigit':0x0,'autopause':'no','ringinuse':'no','timeoutrestart':'no','setinterfacevar':'no','setqueuevar':'no','setqueueentryvar':'no','dialOrderByScheduledAt':_0x49a3ba('0xa0d'),'dialGlobalInterval':_0x49a3ba('0x148a'),'dialAMDInitialSilence':0x9c4,'dialAMDGreeting':0x5dc,'dialAMDAfterGreetingSilence':0x320,'dialAMDTotalAnalysisTime':0x1388,'dialAMDMinWordLength':0x64,'dialAMDBetweenWordsSilence':0x32,'dialAMDMaximumNumberOfWords':0x3,'dialAMDSilenceThreshold':0x100,'dialAMDMaximumWordLength':0x1388,'dialMethod':_0x49a3ba('0x178c'),'dialPowerLevel':0x1,'dialPredictiveOptimization':_0x49a3ba('0x1b5d'),'dialPredictiveOptimizationPercentage':0x3,'dialPredictiveInterval':0xa,'dialLimitQueue':0x0,'dialRandomLastDigitCallerIdNumber':0x0,'dialOriginateTimeout':0x1e,'dialQueueOptions':'tTxX','dialQueueTimeout':0x3,'strategy':'rrmemory','timeout':0x3,'retry':0x3,'weight':0x1,'dialGlobalMaxRetry':0x4,'dialCongestionMaxRetry':0x3,'dialCongestionRetryFrequency':0x96,'dialBusyMaxRetry':0x3,'dialBusyRetryFrequency':0x96,'dialNoAnswerMaxRetry':0x3,'dialNoAnswerRetryFrequency':0x96,'dialNoSuchNumberMaxRetry':0x3,'dialNoSuchNumberRetryFrequency':0x96,'dialDropMaxRetry':0x3,'dialDropRetryFrequency':0x96,'dialAbandonedMaxRetry':0x3,'dialAbandonedRetryFrequency':0x96,'dialMachineMaxRetry':0x3,'dialMachineRetryFrequency':0x96,'dialAgentRejectMaxRetry':0x3,'dialAgentRejectRetryFrequency':0x96,'dialPredictiveIntervalMaxThreshold':0x14,'dialPredictiveIntervalMinThreshold':0xa},_0x5f2004[_0x49a3ba('0xf28')]=_0x49a3ba('0x1f5e'),_0x5f2004[_0x49a3ba('0xe37')]=!![]);_0x5f2004[_0x49a3ba('0x88e')]=_0x3491be,_0x5f2004[_0x49a3ba('0x1741')]=_0x37d791,_0x5f2004['deleteQueueCampaign']=_0x2126cc,_0x5f2004[_0x49a3ba('0x16b3')]=_0x5eae41,_0x5f2004[_0x49a3ba('0xf82')]=_0x12c2df,_0x4f643b['hasRole'](_0x49a3ba('0x20c2'))?_0xaa787d[_0x49a3ba('0x1a93')][_0x49a3ba('0x1e6e')]({'fields':_0x49a3ba('0xa10'),'sort':_0x49a3ba('0x60a')})['$promise'][_0x49a3ba('0x683')](function(_0x13655d){const _0x71a48c=_0x49a3ba;_0x5f2004[_0x71a48c('0x20fe')]=_0x13655d[_0x71a48c('0xf5d')]||[];})['catch'](function(_0x3454f5){const _0x2c5ea9=_0x49a3ba;_0x444c83[_0x2c5ea9('0x52a')]({'title':_0x3454f5[_0x2c5ea9('0x13ee')]?_0x2c5ea9('0x2168')+_0x3454f5['status']+_0x2c5ea9('0xbf6')+_0x3454f5[_0x2c5ea9('0x24a9')]:_0x2c5ea9('0xfd0'),'msg':_0x3454f5[_0x2c5ea9('0x5a5')]?JSON[_0x2c5ea9('0x258a')](_0x3454f5[_0x2c5ea9('0x5a5')]):_0x3454f5[_0x2c5ea9('0x1ff0')]()});}):_0xaa787d[_0x49a3ba('0x1a93')]['get']({'fields':'id,name','sort':'name'})[_0x49a3ba('0xe53')][_0x49a3ba('0x683')](function(_0x4ddbd2){const _0x18a030=_0x49a3ba;_0x5f2004[_0x18a030('0x20fe')]=_0x4ddbd2['rows']||[];})[_0x49a3ba('0x683')](function(){const _0xaa6e27=_0x49a3ba;return _0xaa787d[_0xaa6e27('0x22df')][_0xaa6e27('0x1e6e')]({'userProfileId':_0x5f2004[_0xaa6e27('0x11ed')][_0xaa6e27('0x2f')],'sectionId':0x3f3})[_0xaa6e27('0xe53')];})[_0x49a3ba('0x683')](function(_0x116100){const _0x3d4713=_0x49a3ba,_0x412558=_0x116100&&_0x116100[_0x3d4713('0xf5d')]?_0x116100[_0x3d4713('0xf5d')][0x0]:null;if(!_0x412558){const _0x4b0c65=[];let _0x2babac=null;_0x5f2004[_0x3d4713('0x1bd9')]&&(_0x2babac=_0x2e3ca0()[_0x3d4713('0x1c07')](_0x5f2004[_0x3d4713('0x20fe')],{'id':Number(_0x5f2004[_0x3d4713('0x1bd9')][_0x3d4713('0xf10')])}));for(let _0x549153=0x0;_0x549153<_0x5f2004[_0x3d4713('0x20fe')][_0x3d4713('0x1564')];_0x549153++){_0x2babac&&_0x5f2004[_0x3d4713('0x20fe')][_0x549153]['id']===_0x2babac['id']&&(_0x5f2004[_0x3d4713('0x20fe')][_0x549153][_0x3d4713('0x319')]=![],_0x4b0c65[_0x3d4713('0x1fd0')](_0x5f2004['trunks'][_0x549153]));}_0x5f2004[_0x3d4713('0x20fe')]=_0x4b0c65;}else{if(!_0x412558[_0x3d4713('0x170')])return _0xaa787d[_0x3d4713('0xcf7')][_0x3d4713('0x1e6e')]({'sectionId':_0x412558['id']})[_0x3d4713('0xe53')][_0x3d4713('0x683')](function(_0x899599){const _0x2f5e4b=_0x3d4713,_0x424c24=_0x2e3ca0()[_0x2f5e4b('0x386')](_0x899599[_0x2f5e4b('0xf5d')],function(_0x25ad50){const _0x5525aa=_0x2f5e4b;return _0x2e3ca0()[_0x5525aa('0x1c07')](_0x5f2004['trunks'],{'id':_0x25ad50[_0x5525aa('0x832')]});});let _0x13179c=null;_0x5f2004[_0x2f5e4b('0x1bd9')]&&(_0x13179c=_0x2e3ca0()['find'](_0x5f2004[_0x2f5e4b('0x20fe')],{'id':Number(_0x5f2004[_0x2f5e4b('0x1bd9')][_0x2f5e4b('0xf10')])}));if(_0x13179c&&!_0x2e3ca0()[_0x2f5e4b('0x7a2')](_0x424c24,['id',_0x13179c['id']])){const _0x1b5a0d=_0x2e3ca0()['find'](_0x5f2004[_0x2f5e4b('0x20fe')],{'id':_0x13179c['id']});_0x1b5a0d[_0x2f5e4b('0x319')]=![],_0x424c24['push'](_0x1b5a0d);}_0x5f2004[_0x2f5e4b('0x20fe')]=_0x424c24;});}})[_0x49a3ba('0x130a')](function(_0x1d77e1){const _0x51683e=_0x49a3ba;_0x444c83[_0x51683e('0x52a')]({'title':_0x1d77e1[_0x51683e('0x13ee')]?_0x51683e('0x2168')+_0x1d77e1[_0x51683e('0x13ee')]+_0x51683e('0xbf6')+_0x1d77e1[_0x51683e('0x24a9')]:_0x51683e('0x93'),'msg':_0x1d77e1[_0x51683e('0x5a5')]?JSON[_0x51683e('0x258a')](_0x1d77e1[_0x51683e('0x5a5')]):_0x1d77e1[_0x51683e('0x1ff0')]()});}),_0x4f643b[_0x49a3ba('0xca1')]('admin')?_0xaa787d[_0x49a3ba('0x115c')][_0x49a3ba('0x1e6e')]({'fields':_0x49a3ba('0xa10'),'sort':'name','IntervalId':_0x49a3ba('0x13c')})['$promise'][_0x49a3ba('0x683')](function(_0x3f912b){const _0x5842a9=_0x49a3ba;_0x5f2004[_0x5842a9('0x115c')]=_0x3f912b[_0x5842a9('0xf5d')]||[];})[_0x49a3ba('0x130a')](function(_0x294ab5){const _0x5733ab=_0x49a3ba;_0x444c83[_0x5733ab('0x52a')]({'title':_0x294ab5[_0x5733ab('0x13ee')]?_0x5733ab('0x2168')+_0x294ab5[_0x5733ab('0x13ee')]+'\x20-\x20'+_0x294ab5['statusText']:'SYSTEM:GET_INTERVAL','msg':_0x294ab5[_0x5733ab('0x5a5')]?JSON[_0x5733ab('0x258a')](_0x294ab5[_0x5733ab('0x5a5')]):_0x294ab5[_0x5733ab('0x1ff0')]()});}):_0xaa787d[_0x49a3ba('0x115c')][_0x49a3ba('0x1e6e')]({'fields':_0x49a3ba('0xa10'),'sort':_0x49a3ba('0x60a'),'IntervalId':_0x49a3ba('0x13c')})[_0x49a3ba('0xe53')][_0x49a3ba('0x683')](function(_0xafd528){const _0xe4a33a=_0x49a3ba;_0x5f2004[_0xe4a33a('0x115c')]=_0xafd528[_0xe4a33a('0xf5d')]||[];})[_0x49a3ba('0x683')](function(){const _0x3e4085=_0x49a3ba;return _0xaa787d[_0x3e4085('0x22df')][_0x3e4085('0x1e6e')]({'userProfileId':_0x5f2004[_0x3e4085('0x11ed')][_0x3e4085('0x2f')],'sectionId':0x3ec})[_0x3e4085('0xe53')];})[_0x49a3ba('0x683')](function(_0x48f803){const _0x2b305e=_0x49a3ba,_0xeaa35a=_0x48f803&&_0x48f803[_0x2b305e('0xf5d')]?_0x48f803[_0x2b305e('0xf5d')][0x0]:null;if(!_0xeaa35a){const _0x53c3f0=[];let _0x46cf29=null;_0x5f2004[_0x2b305e('0x1bd9')]&&(_0x46cf29=_0x2e3ca0()[_0x2b305e('0x1c07')](_0x5f2004[_0x2b305e('0x115c')],{'id':Number(_0x5f2004[_0x2b305e('0x1bd9')][_0x2b305e('0x5ae')])}));for(let _0x358bb0=0x0;_0x358bb0<_0x5f2004[_0x2b305e('0x115c')]['length'];_0x358bb0++){_0x46cf29&&_0x5f2004[_0x2b305e('0x115c')][_0x358bb0]['id']===_0x46cf29['id']&&(_0x5f2004[_0x2b305e('0x115c')][_0x358bb0]['canSelect']=![],_0x53c3f0[_0x2b305e('0x1fd0')](_0x5f2004[_0x2b305e('0x115c')][_0x358bb0]));}_0x5f2004[_0x2b305e('0x115c')]=_0x53c3f0;}else{if(!_0xeaa35a[_0x2b305e('0x170')])return _0xaa787d[_0x2b305e('0xcf7')][_0x2b305e('0x1e6e')]({'sectionId':_0xeaa35a['id']})['$promise'][_0x2b305e('0x683')](function(_0x208aca){const _0x214734=_0x2b305e,_0x38a1b4=_0x2e3ca0()[_0x214734('0x386')](_0x208aca[_0x214734('0xf5d')],function(_0x1f3d0b){const _0x557b79=_0x214734;return _0x2e3ca0()[_0x557b79('0x1c07')](_0x5f2004[_0x557b79('0x115c')],{'id':_0x1f3d0b['resourceId']});});let _0x1a3385=null;_0x5f2004[_0x214734('0x1bd9')]&&(_0x1a3385=_0x2e3ca0()[_0x214734('0x1c07')](_0x5f2004[_0x214734('0x115c')],{'id':Number(_0x5f2004[_0x214734('0x1bd9')][_0x214734('0x5ae')])}));if(_0x1a3385&&!_0x2e3ca0()[_0x214734('0x7a2')](_0x38a1b4,['id',_0x1a3385['id']])){const _0x137cb8=_0x2e3ca0()[_0x214734('0x1c07')](_0x5f2004[_0x214734('0x115c')],{'id':_0x1a3385['id']});_0x137cb8[_0x214734('0x319')]=![],_0x38a1b4['push'](_0x137cb8);}_0x5f2004[_0x214734('0x115c')]=_0x38a1b4;});}})[_0x49a3ba('0x130a')](function(_0x22cf64){const _0x478dc1=_0x49a3ba;_0x444c83[_0x478dc1('0x52a')]({'title':_0x22cf64[_0x478dc1('0x13ee')]?_0x478dc1('0x2168')+_0x22cf64[_0x478dc1('0x13ee')]+'\x20-\x20'+_0x22cf64[_0x478dc1('0x24a9')]:_0x478dc1('0x203'),'msg':_0x22cf64[_0x478dc1('0x5a5')]?JSON[_0x478dc1('0x258a')](_0x22cf64[_0x478dc1('0x5a5')]):_0x22cf64[_0x478dc1('0x1ff0')]()});});function _0x3491be(){const _0x43c195=_0x49a3ba;_0x5f2004['errors']=[],_0xaa787d[_0x43c195('0x204c')]['save'](_0x5f2004[_0x43c195('0x1bd9')])[_0x43c195('0xe53')][_0x43c195('0x683')](function(_0x5429fc){const _0x2a1c0d=_0x43c195;_0x5f2004[_0x2a1c0d('0x2022')][_0x2a1c0d('0x1167')](_0x5429fc[_0x2a1c0d('0x24e1')]()),_0x444c83[_0x2a1c0d('0x53')]({'title':_0x2a1c0d('0x16d4'),'msg':_0x5f2004['queueCampaign'][_0x2a1c0d('0x60a')]?_0x5f2004[_0x2a1c0d('0x1bd9')][_0x2a1c0d('0x60a')]+_0x2a1c0d('0x14b5'):''}),_0x12c2df(_0x5429fc);})['catch'](function(_0x3a83bc){const _0x5751a3=_0x43c195;if(_0x3a83bc['data']&&_0x3a83bc[_0x5751a3('0x5a5')][_0x5751a3('0x17f')]&&_0x3a83bc[_0x5751a3('0x5a5')][_0x5751a3('0x17f')]['length']){_0x5f2004[_0x5751a3('0x17f')]=_0x3a83bc[_0x5751a3('0x5a5')][_0x5751a3('0x17f')]||[{'message':_0x3a83bc[_0x5751a3('0x1ff0')](),'type':'api.voiceQueue.save'}];for(let _0x157d91=0x0;_0x157d91<_0x3a83bc[_0x5751a3('0x5a5')]['errors'][_0x5751a3('0x1564')];_0x157d91+=0x1){_0x444c83[_0x5751a3('0x52a')]({'title':_0x3a83bc[_0x5751a3('0x5a5')][_0x5751a3('0x17f')][_0x157d91][_0x5751a3('0xcf0')],'msg':_0x3a83bc['data'][_0x5751a3('0x17f')][_0x157d91][_0x5751a3('0x8c2')]});}}else _0x444c83[_0x5751a3('0x52a')]({'title':_0x3a83bc['status']?_0x5751a3('0x2168')+_0x3a83bc[_0x5751a3('0x13ee')]+_0x5751a3('0xbf6')+_0x3a83bc[_0x5751a3('0x24a9')]:_0x5751a3('0x1a5c'),'msg':_0x3a83bc[_0x5751a3('0x5a5')]?JSON[_0x5751a3('0x258a')](_0x3a83bc[_0x5751a3('0x5a5')]['message']):_0x3a83bc['toString']()});});}function _0x37d791(){const _0x2f7c41=_0x49a3ba;_0x5f2004[_0x2f7c41('0x17f')]=[],_0xaa787d[_0x2f7c41('0x204c')]['update']({'id':_0x5f2004[_0x2f7c41('0x1bd9')]['id']},_0x5f2004[_0x2f7c41('0x1bd9')])['$promise'][_0x2f7c41('0x683')](function(_0x4f2888){const _0x2990ea=_0x2f7c41,_0x13357b=_0x2e3ca0()[_0x2990ea('0x1c07')](_0x5f2004[_0x2990ea('0x2022')],{'id':_0x4f2888['id']});_0x13357b&&_0x2e3ca0()[_0x2990ea('0xf22')](_0x13357b,_0x2e3ca0()['pick'](_0x4f2888['toJSON'](),_0x2e3ca0()[_0x2990ea('0x55e')](_0x13357b))),_0x444c83[_0x2990ea('0x53')]({'title':'QueueCampaign\x20properly\x20saved!','msg':_0x5f2004[_0x2990ea('0x1bd9')][_0x2990ea('0x60a')]?_0x5f2004[_0x2990ea('0x1bd9')][_0x2990ea('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x12c2df(_0x4f2888);})[_0x2f7c41('0x130a')](function(_0x286697){const _0x3eba66=_0x2f7c41;if(_0x286697[_0x3eba66('0x5a5')]&&_0x286697[_0x3eba66('0x5a5')][_0x3eba66('0x17f')]&&_0x286697['data']['errors'][_0x3eba66('0x1564')]){_0x5f2004[_0x3eba66('0x17f')]=_0x286697[_0x3eba66('0x5a5')][_0x3eba66('0x17f')]||[{'message':_0x286697[_0x3eba66('0x1ff0')](),'type':_0x3eba66('0x1bf0')}];for(let _0x257848=0x0;_0x257848<_0x286697['data'][_0x3eba66('0x17f')][_0x3eba66('0x1564')];_0x257848++){_0x444c83[_0x3eba66('0x52a')]({'title':_0x286697[_0x3eba66('0x5a5')][_0x3eba66('0x17f')][_0x257848][_0x3eba66('0xcf0')],'msg':_0x286697[_0x3eba66('0x5a5')][_0x3eba66('0x17f')][_0x257848]['message']});}}else _0x444c83[_0x3eba66('0x52a')]({'title':_0x286697[_0x3eba66('0x13ee')]?_0x3eba66('0x2168')+_0x286697[_0x3eba66('0x13ee')]+_0x3eba66('0xbf6')+_0x286697[_0x3eba66('0x24a9')]:_0x3eba66('0x1bf0'),'msg':_0x286697[_0x3eba66('0x5a5')]?JSON[_0x3eba66('0x258a')](_0x286697['data'][_0x3eba66('0x8c2')]):_0x286697[_0x3eba66('0x1ff0')]()});});}function _0x2126cc(_0x1fafc7){const _0x1a3a63=_0x49a3ba;_0x5f2004[_0x1a3a63('0x17f')]=[];const _0x1e06a6=_0x5d10ab[_0x1a3a63('0x1c6f')]()[_0x1a3a63('0xf28')](_0x1a3a63('0x4d'))[_0x1a3a63('0xa6a')]('The\x20queueCampaign\x20will\x20be\x20deleted.')[_0x1a3a63('0x1040')]('Delete\x20QueueCampaign')['ok']('Delete')[_0x1a3a63('0x19fb')]('Cancel')[_0x1a3a63('0xe42')](_0x1fafc7);_0x5d10ab[_0x1a3a63('0x1d4')](_0x1e06a6)[_0x1a3a63('0x683')](function(){const _0x64d20d=_0x1a3a63;_0xaa787d[_0x64d20d('0x204c')]['delete']({'id':_0x5f2004[_0x64d20d('0x1bd9')]['id']})[_0x64d20d('0xe53')]['then'](function(){const _0x41a2c6=_0x64d20d;_0x2e3ca0()[_0x41a2c6('0x3ec')](_0x5f2004[_0x41a2c6('0x2022')],{'id':_0x5f2004[_0x41a2c6('0x1bd9')]['id']}),_0x444c83[_0x41a2c6('0x53')]({'title':_0x41a2c6('0x646'),'msg':(_0x5f2004['queueCampaign']['name']||_0x41a2c6('0x1bd9'))+_0x41a2c6('0x194d')}),_0x12c2df(_0x5f2004['queueCampaign']);})[_0x64d20d('0x130a')](function(_0x5e4404){const _0x502a32=_0x64d20d;if(_0x5e4404[_0x502a32('0x5a5')]&&_0x5e4404[_0x502a32('0x5a5')][_0x502a32('0x17f')]&&_0x5e4404[_0x502a32('0x5a5')][_0x502a32('0x17f')][_0x502a32('0x1564')]){_0x5f2004[_0x502a32('0x17f')]=_0x5e4404['data'][_0x502a32('0x17f')]||[{'message':_0x5e4404[_0x502a32('0x1ff0')](),'type':'api.voiceQueue.delete'}];for(let _0x47b8c6=0x0;_0x47b8c6<_0x5e4404[_0x502a32('0x5a5')][_0x502a32('0x17f')][_0x502a32('0x1564')];_0x47b8c6++){_0x444c83[_0x502a32('0x52a')]({'title':_0x5e4404[_0x502a32('0x5a5')][_0x502a32('0x17f')][_0x47b8c6]['type'],'msg':_0x5e4404[_0x502a32('0x5a5')][_0x502a32('0x17f')][_0x47b8c6][_0x502a32('0x8c2')]});}}else _0x444c83[_0x502a32('0x52a')]({'title':_0x5e4404[_0x502a32('0x13ee')]?_0x502a32('0x2168')+_0x5e4404[_0x502a32('0x13ee')]+_0x502a32('0xbf6')+_0x5e4404[_0x502a32('0x24a9')]:'api.voiceQueue.delete','msg':_0x5e4404[_0x502a32('0x5a5')]?JSON[_0x502a32('0x258a')](_0x5e4404[_0x502a32('0x5a5')]['message']):_0x5e4404['message']||_0x5e4404['toString']()});});},function(){});}function _0x5eae41(_0x105f4d){return _0x105f4d===null?undefined:new Date(_0x105f4d);}function _0x12c2df(_0x150c78){const _0x5d8e35=_0x49a3ba;_0x5d10ab[_0x5d8e35('0x1715')](_0x150c78);}}const _0x5ed28e=_0xea50e4;_0x123b21[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x1bd9'),_0x189033('0x2022'),_0x189033('0x2c9'),_0x189033('0x1d08'),'Auth',_0x189033('0x1134')];function _0x123b21(_0x5a12c7,_0x532008,_0x23354d,_0xf59af1,_0xab00e4,_0x1f8b62,_0x261374,_0xc324bf,_0x2079ef,_0x41dbc2){const _0x368af7=_0x189033,_0x216a21=this;_0x216a21[_0x368af7('0x11ed')]=_0x2079ef[_0x368af7('0x20b2')](),_0x216a21['queueCampaign']=_0xab00e4,_0x216a21['crudPermissions']=_0x41dbc2,_0x216a21[_0x368af7('0x1e2a')]=0x0,_0x216a21['realtime']=_0x261374,_0x216a21[_0x368af7('0x1996')]=[],_0x216a21[_0x368af7('0x1c47')]=[],_0x216a21[_0x368af7('0x1378')]=[],_0x216a21[_0x368af7('0x125e')]=[],_0x216a21[_0x368af7('0x23a7')]=[],_0x216a21[_0x368af7('0x2106')]=![],_0x216a21['onInit']=_0x57aacb,_0x216a21['saveAgents']=_0xd5e129,_0x216a21[_0x368af7('0xf82')]=_0x534ee2,_0x216a21[_0x368af7('0x169f')]={'readOnly':!_0x216a21[_0x368af7('0x1134')][_0x368af7('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':'fullname','line2':['name',_0x368af7('0x1d43')],'line3':_0x368af7('0x1e2a'),'labelAll':_0xc324bf[_0x368af7('0x2728')](_0x368af7('0x1163')),'labelSelected':_0xc324bf[_0x368af7('0x2728')]('MOTIONDIALER.SELECTED_AGENTS'),'transferCallback':function(_0x2ff6a0,_0x330a79){const _0x708171=_0x368af7;_0x330a79?_0x2ff6a0[_0x708171('0x1299')](function(_0x146ad8){_0x146ad8['penalty']=undefined;}):_0x2ff6a0['forEach'](function(_0x5879d9){const _0x4862b1=_0x708171;_0x5879d9[_0x4862b1('0x1e2a')]=_0x4862b1('0x23d0')+_0x216a21[_0x4862b1('0x1e2a')];});const _0x4c0128=_0x2e3ca0()[_0x708171('0x162c')](_0x216a21[_0x708171('0x23a7')],_0x216a21[_0x708171('0x1378')],function(_0x3a91f5,_0x490e52){const _0x15174b=_0x708171;return _0x3a91f5['id']===_0x490e52['id']&&_0x3a91f5[_0x15174b('0x1e2a')]===_0x490e52['penalty'];});_0x216a21[_0x708171('0x2106')]=_0x2e3ca0()[_0x708171('0x173f')](_0x4c0128)?![]:!![];}};function _0x57aacb(){const _0x1e098d=_0x368af7;return _0x2079ef[_0x1e098d('0xca1')](_0x1e098d('0x20c2'))?_0x1eef70()[_0x1e098d('0x130a')](function(_0x3b6044){const _0x4bf7eb=_0x1e098d;_0x23354d[_0x4bf7eb('0x52a')]({'title':_0x3b6044[_0x4bf7eb('0x13ee')]?_0x4bf7eb('0x2168')+_0x3b6044['status']+_0x4bf7eb('0xbf6')+_0x3b6044[_0x4bf7eb('0x24a9')]:'SYSTEM:GET_AGENTS','msg':_0x3b6044[_0x4bf7eb('0x13ee')]?JSON[_0x4bf7eb('0x258a')](_0x3b6044[_0x4bf7eb('0x5a5')]):_0x3b6044[_0x4bf7eb('0x1ff0')]()});}):_0x24a2c2()['then'](function(_0x332508){const _0x18ac65=_0x1e098d;return _0x216a21[_0x18ac65('0x1aa')]=_0x332508,_0x1eef70();})[_0x1e098d('0x130a')](function(_0x5c930b){const _0x2fc345=_0x1e098d;_0x23354d[_0x2fc345('0x52a')]({'title':_0x5c930b[_0x2fc345('0x13ee')]?'API:'+_0x5c930b[_0x2fc345('0x13ee')]+_0x2fc345('0xbf6')+_0x5c930b[_0x2fc345('0x24a9')]:_0x2fc345('0x144f'),'msg':_0x5c930b[_0x2fc345('0x13ee')]?JSON['stringify'](_0x5c930b[_0x2fc345('0x5a5')]):_0x5c930b['toString']()});});}function _0x24a2c2(){return _0x532008(function(_0x250a1b,_0x5e744f){const _0x21b93d=a0_0x4e0a;_0xf59af1[_0x21b93d('0x22df')][_0x21b93d('0x1e6e')]({'userProfileId':_0x216a21['currentUser'][_0x21b93d('0x2f')],'name':'Agents'})[_0x21b93d('0xe53')]['then'](function(_0x55c47b){const _0x5b92af=_0x21b93d,_0x22234e=_0x55c47b&&_0x55c47b[_0x5b92af('0xf5d')]?_0x55c47b[_0x5b92af('0xf5d')][0x0]:null;_0x250a1b(_0x22234e);})[_0x21b93d('0x130a')](function(_0x4cb13d){_0x5e744f(_0x4cb13d);});});}function _0x1eef70(){return _0x532008(function(_0x3dffe6,_0x237397){const _0x22c3f4=a0_0x4e0a;return _0x24d792()['then'](function(_0xff3218){const _0x2035a8=a0_0x4e0a;return _0x216a21[_0x2035a8('0x1996')]=_0xff3218[_0x2035a8('0xf5d')]?_0xff3218['rows']:[],_0x2079ef[_0x2035a8('0xca1')]('admin')?_0xff3218:_0x216a21[_0x2035a8('0x1aa')]?_0x216a21[_0x2035a8('0x1aa')][_0x2035a8('0x170')]?_0xff3218:_0xb964ea():null;})[_0x22c3f4('0x683')](function(_0x203a3e){const _0x1c446e=_0x22c3f4,_0x3dd56a=_0x203a3e&&_0x203a3e['rows']?_0x203a3e[_0x1c446e('0xf5d')]:[];return _0x216a21[_0x1c446e('0x1c47')]=_0x2e3ca0()[_0x1c446e('0x386')](_0x3dd56a,function(_0x2028c6){const _0x4fb667=_0x1c446e;return _0x2e3ca0()['find'](_0x216a21['items'],{'id':_0x2079ef[_0x4fb667('0xca1')]('admin')||_0x216a21['section']['autoAssociation']?_0x2028c6['id']:_0x2028c6[_0x4fb667('0x832')]});}),_0x216a21[_0x1c446e('0x125e')]=angular[_0x1c446e('0x1a86')](_0x216a21[_0x1c446e('0x1c47')]),_0x216a21[_0x1c446e('0x1996')]['forEach'](function(_0xd5d7e9){const _0x53bdaa=_0x1c446e,_0x120d08=_0x2e3ca0()['find'](_0x216a21['allowedItems'],{'id':_0xd5d7e9['id']});_0x2079ef[_0x53bdaa('0xca1')](_0x53bdaa('0x20c2'))?_0xd5d7e9['isValid']=!![]:_0xd5d7e9['isValid']=typeof _0x120d08!=='undefined'?!![]:![];}),_0xd99424();})[_0x22c3f4('0x683')](function(_0x3c1588){const _0x177749=_0x22c3f4,_0x2a5387=_0x3c1588&&_0x3c1588[_0x177749('0xf5d')]?_0x3c1588[_0x177749('0xf5d')]:[];_0x216a21[_0x177749('0x1378')]=_0x2e3ca0()['map'](_0x2a5387,function(_0x3f9929){const _0xcaf4a0=_0x177749,_0xdcde8b=_0x2e3ca0()[_0xcaf4a0('0x1c07')](_0x216a21[_0xcaf4a0('0x1996')],{'id':_0x3f9929['id']});return _0xdcde8b[_0xcaf4a0('0x1e2a')]=_0x3f9929[_0xcaf4a0('0x1901')]?_0xcaf4a0('0x23d0')+_0x3f9929[_0xcaf4a0('0x1901')][_0xcaf4a0('0x1e2a')]:'',_0xdcde8b[_0xcaf4a0('0x1d43')]=typeof _0x3f9929[_0xcaf4a0('0x1d43')]!==_0xcaf4a0('0x1867')?'<'+_0x3f9929[_0xcaf4a0('0x1d43')]+'>':'',_0xdcde8b;}),_0x216a21[_0x177749('0x23a7')]=angular['copy'](_0x216a21[_0x177749('0x1378')]),_0x216a21['dualMultiselectOptions']['selectedItems']=_0x216a21[_0x177749('0x1378')],_0x216a21[_0x177749('0x169f')]['items']=_0x2e3ca0()['differenceBy'](_0x216a21[_0x177749('0x1c47')],_0x216a21['dualMultiselectOptions'][_0x177749('0x1378')],'id'),_0x3dffe6();})[_0x22c3f4('0x130a')](function(_0x2b1029){_0x237397(_0x2b1029);});});}function _0xb964ea(){return _0x532008(function(_0x5fe36c,_0x43604d){const _0x172b27=a0_0x4e0a;return _0xf59af1['userProfileResource'][_0x172b27('0x1e6e')]({'sectionId':_0x216a21[_0x172b27('0x1aa')]['id'],'nolimit':!![]})[_0x172b27('0xe53')][_0x172b27('0x683')](function(_0x26b3a4){_0x5fe36c(_0x26b3a4);})[_0x172b27('0x130a')](function(_0x387e72){_0x43604d(_0x387e72);});});}function _0xd99424(){return _0x532008(function(_0x1d0905,_0x51e147){const _0x34a811=a0_0x4e0a;return _0xf59af1[_0x34a811('0x204c')][_0x34a811('0x8e7')]({'id':_0x216a21[_0x34a811('0x1bd9')]['id'],'fields':_0x34a811('0x72b'),'nolimit':!![],'role':_0x34a811('0x2327')})[_0x34a811('0xe53')][_0x34a811('0x683')](function(_0x37a750){_0x1d0905(_0x37a750);})[_0x34a811('0x130a')](function(_0x5c93cc){_0x51e147(_0x5c93cc);});});}function _0x24d792(){return _0x532008(function(_0x4e9881,_0x6a6a7a){const _0x2872b4=a0_0x4e0a;return _0xf59af1[_0x2872b4('0xc96')]['get']({'fields':'id,name,internal,fullname','nolimit':!![],'role':_0x2872b4('0x2327')})[_0x2872b4('0xe53')]['then'](function(_0x15eb87){_0x4e9881(_0x15eb87);})[_0x2872b4('0x130a')](function(_0xd97cd2){_0x6a6a7a(_0xd97cd2);});});}function _0xb0dd56(_0x498629){return _0x532008(function(_0x3473de,_0x2ffa89){const _0x1b3058=a0_0x4e0a;if(_0x2e3ca0()[_0x1b3058('0x173f')](_0x498629))_0x3473de();else{const _0x37ac52=[],_0x961a7d=_0x2e3ca0()[_0x1b3058('0x600')](_0x498629,'penalty');for(let _0x62b780=0x0;_0x62b780'+_0x25c7be[_0x4d8f9c('0x105c')][_0x4d8f9c('0x1564')]+_0x4d8f9c('0x93c')+'\x20will\x20be\x20deleted.')[_0x4d8f9c('0x1040')](_0x4d8f9c('0x1e52'))[_0x4d8f9c('0xe42')](_0x1cc723)['ok']('OK')['cancel'](_0x4d8f9c('0x16b8'));_0x1c4c03[_0x4d8f9c('0x1d4')](_0x27167a)[_0x4d8f9c('0x683')](function(){const _0x408d91=_0x4d8f9c;_0x25c7be['selectedQueueCampaignHopperBlacks'][_0x408d91('0x1299')](function(_0x469e42){_0x308820(_0x469e42);}),_0x25c7be[_0x408d91('0x105c')]=[];});}let _0x3af914=!![],_0x5deb49=0x1;_0x3b7b2c['$watch']('vm_dc.query.filter',function(_0x5b2031,_0x5c352b){const _0x5ccf6d=_0x226131;_0x3af914?_0x2df274(function(){_0x3af914=![];}):(!_0x5c352b&&(_0x5deb49=_0x25c7be[_0x5ccf6d('0x23a2')][_0x5ccf6d('0xdf8')]),_0x5b2031!==_0x5c352b&&(_0x25c7be[_0x5ccf6d('0x23a2')]['page']=0x1),!_0x5b2031&&(_0x25c7be[_0x5ccf6d('0x23a2')][_0x5ccf6d('0xdf8')]=_0x5deb49),_0x2fe8ad());});}const _0x22acb6=_0x40fed6;_0x77cd[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),'$state','$q',_0x189033('0x1d08'),'$timeout',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),'Auth'];function _0x77cd(_0x554d7b,_0xee8d10,_0xa7299a,_0x502239,_0x1ebe56,_0x13c21a,_0x396708,_0x63f857,_0x30c340,_0x1845e1,_0x343743){const _0x3d8865=_0x189033,_0x2ea83f=this;_0x2ea83f['currentUser']=_0x343743[_0x3d8865('0x20b2')](),_0x2ea83f[_0x3d8865('0x6d5')]={},_0x2ea83f[_0x3d8865('0x1bd9')]={},_0x2ea83f[_0x3d8865('0xd0b')]={'count':0x0,'rows':[]},_0x2ea83f[_0x3d8865('0x1217')]=[],_0x2ea83f[_0x3d8865('0x1134')],_0x2ea83f[_0x3d8865('0x23a2')]={'fields':_0x3d8865('0xf2b'),'sort':'-id','limit':0xa,'page':0x1},_0x2ea83f[_0x3d8865('0x12f3')]=_0x225cf6,_0x2ea83f['deleteConfirm']=_0x56909e,_0x2ea83f[_0x3d8865('0x53')]=_0x59ef6c,_0x2ea83f[_0x3d8865('0x24c4')]=_0x47903d,_0x2ea83f[_0x3d8865('0x23fb')]=_0x5b11e4,_0x2ea83f[_0x3d8865('0x1171')]=_0x1f4b7a,_0x2ea83f[_0x3d8865('0x22b4')]=_0x4256c7,_0x2ea83f['moveQueueCampaignHopperFinal']=_0x5c7e29,_0x2ea83f[_0x3d8865('0x913')]=_0x27b54f,_0x2ea83f[_0x3d8865('0x2099')]=_0x124a24,_0x2ea83f[_0x3d8865('0x1c49')]=_0x23e6f4,_0x2ea83f[_0x3d8865('0xa3e')]=_0x16698d;function _0x225cf6(_0x531e9d,_0x23a69c){const _0x183cf1=_0x3d8865;_0x2ea83f[_0x183cf1('0x1bd9')]=_0x531e9d,_0x2ea83f['crudPermissions']=typeof _0x23a69c!==_0x183cf1('0x1867')?_0x23a69c:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x2ea83f[_0x183cf1('0x23a2')][_0x183cf1('0x19ec')]=_0x2ea83f[_0x183cf1('0x1bd9')]['id'],_0x2ea83f[_0x183cf1('0x23a2')]['id']=_0x2ea83f[_0x183cf1('0x1bd9')]['id'],_0x47903d();}function _0x56909e(_0xd8880b,_0x3e3917){const _0x41b757=_0x3d8865,_0x5b6dcf=_0x396708[_0x41b757('0x1c6f')]()[_0x41b757('0xf28')](_0x41b757('0x1682'))[_0x41b757('0x26e3')](_0x41b757('0xed5')+(_0xd8880b[_0x41b757('0x60a')]||_0xd8880b['id']&&_0x2e3ca0()['upperFirst'](_0x41b757('0x943'))+_0xd8880b['id']||_0x41b757('0x2412'))+''+_0x41b757('0x1ee7'))[_0x41b757('0x1040')]('delete\x20hopperFinal')[_0x41b757('0xe42')](_0x3e3917)['ok']('OK')['cancel'](_0x41b757('0x16b8'));_0x396708[_0x41b757('0x1d4')](_0x5b6dcf)[_0x41b757('0x683')](function(){_0x1f4b7a(_0xd8880b);},function(){const _0x3e1d5b=_0x41b757;console['log'](_0x3e1d5b('0x16b8'));});}function _0x59ef6c(_0x2c2a94){const _0x1d9401=_0x3d8865;_0x2ea83f[_0x1d9401('0xd0b')]=_0x2c2a94||{'count':0x0,'rows':[]};}function _0x47903d(){const _0x520cdb=_0x3d8865;_0x2ea83f[_0x520cdb('0x23a2')][_0x520cdb('0x1cc8')]=(_0x2ea83f['query'][_0x520cdb('0xdf8')]-0x1)*_0x2ea83f[_0x520cdb('0x23a2')]['limit'],_0x2ea83f['promise']=_0x1845e1[_0x520cdb('0x204c')][_0x520cdb('0x77b')](_0x2ea83f[_0x520cdb('0x23a2')],_0x59ef6c)['$promise'];}function _0x1f4b7a(_0x478970){const _0x3fea43=_0x3d8865;_0x1845e1[_0x3fea43('0x2412')][_0x3fea43('0xd7e')]({'id':_0x478970['id']})[_0x3fea43('0xe53')][_0x3fea43('0x683')](function(){const _0x104730=_0x3fea43;_0x2e3ca0()[_0x104730('0x3ec')](_0x2ea83f[_0x104730('0xd0b')][_0x104730('0xf5d')],{'id':_0x478970['id']}),_0x2ea83f[_0x104730('0xd0b')][_0x104730('0x50d')]-=0x1,!_0x2ea83f[_0x104730('0xd0b')][_0x104730('0xf5d')][_0x104730('0x1564')]&&_0x47903d(),_0x30c340[_0x104730('0x53')]({'title':_0x104730('0x2382'),'msg':_0x478970[_0x104730('0x60a')]?_0x478970[_0x104730('0x60a')]+_0x104730('0x194d'):''});})[_0x3fea43('0x130a')](function(_0x40da60){const _0xb135a1=_0x3fea43;if(_0x40da60['data']&&_0x40da60[_0xb135a1('0x5a5')][_0xb135a1('0x17f')]&&_0x40da60['data'][_0xb135a1('0x17f')]['length']){_0x2ea83f['errors']=_0x40da60[_0xb135a1('0x5a5')][_0xb135a1('0x17f')]||[{'message':_0x40da60[_0xb135a1('0x1ff0')](),'type':_0xb135a1('0xa42')}];for(let _0x231ea1=0x0;_0x231ea1<_0x40da60[_0xb135a1('0x5a5')][_0xb135a1('0x17f')][_0xb135a1('0x1564')];_0x231ea1++){_0x30c340[_0xb135a1('0x52a')]({'title':_0x40da60[_0xb135a1('0x5a5')][_0xb135a1('0x17f')][_0x231ea1]['type'],'msg':_0x40da60[_0xb135a1('0x5a5')][_0xb135a1('0x17f')][_0x231ea1][_0xb135a1('0x8c2')]});}}else _0x30c340['error']({'title':_0x40da60[_0xb135a1('0x13ee')]?_0xb135a1('0x2168')+_0x40da60[_0xb135a1('0x13ee')]+_0xb135a1('0xbf6')+_0x40da60['statusText']:'SYSTEM:GETvoiceQueue','msg':_0x40da60[_0xb135a1('0x5a5')]?JSON[_0xb135a1('0x258a')](_0x40da60[_0xb135a1('0x5a5')][_0xb135a1('0x8c2')]):_0x40da60[_0xb135a1('0x8c2')]||_0x40da60[_0xb135a1('0x1ff0')]()});});}function _0x5b11e4(){const _0x56c7cd=_0x3d8865,_0x5523fe=angular['copy'](_0x2ea83f[_0x56c7cd('0x1217')]);return _0x2ea83f[_0x56c7cd('0x1217')]=[],_0x5523fe;}function _0x4256c7(_0x3fd7af){const _0x448b49=_0x3d8865,_0x1c1d8e=_0x396708[_0x448b49('0x1c6f')]()[_0x448b49('0xf28')](_0x448b49('0x2352'))[_0x448b49('0x26e3')](_0x448b49('0xed5')+_0x2ea83f[_0x448b49('0x1217')][_0x448b49('0x1564')]+'\x20selected'+_0x448b49('0x1ee7'))[_0x448b49('0x1040')](_0x448b49('0x1cd8'))[_0x448b49('0xe42')](_0x3fd7af)['ok']('OK')[_0x448b49('0x19fb')](_0x448b49('0x16b8'));_0x396708[_0x448b49('0x1d4')](_0x1c1d8e)['then'](function(){const _0x112a7f=_0x448b49;_0x2ea83f[_0x112a7f('0x1217')][_0x112a7f('0x1299')](function(_0x2141be){_0x1f4b7a(_0x2141be);}),_0x2ea83f[_0x112a7f('0x1217')]=[];});}function _0x27b54f(_0x491b46){const _0x417cba=_0x3d8865;_0x1845e1[_0x417cba('0x163f')][_0x417cba('0x913')]({'id':_0x2ea83f['query']['id'],'state':_0x491b46})[_0x417cba('0xe53')][_0x417cba('0x683')](function(_0x7019fc){const _0x18cbdc=_0x417cba;_0x2e3ca0()[_0x18cbdc('0x8f2')](_0x7019fc)&&_0x2e3ca0()[_0x18cbdc('0x8f2')](_0x7019fc[0x0])?_0x30c340[_0x18cbdc('0x2289')]({'title':_0x18cbdc('0x209f'),'msg':'0'}):_0x30c340[_0x18cbdc('0x2289')]({'title':_0x18cbdc('0x209f'),'msg':JSON[_0x18cbdc('0x258a')](_0x7019fc[0x0][_0x18cbdc('0x1dbf')])});})[_0x417cba('0x130a')](function(_0x211a81){const _0x3a20f4=_0x417cba;_0x30c340[_0x3a20f4('0x52a')]({'title':_0x211a81[_0x3a20f4('0x13ee')]?_0x3a20f4('0x2168')+_0x211a81[_0x3a20f4('0x13ee')]+'\x20-\x20'+_0x211a81[_0x3a20f4('0x24a9')]:_0x3a20f4('0xa42'),'msg':_0x211a81['data']?JSON[_0x3a20f4('0x258a')](_0x211a81[_0x3a20f4('0x5a5')][_0x3a20f4('0x8c2')]):_0x211a81[_0x3a20f4('0x8c2')]||_0x211a81[_0x3a20f4('0x1ff0')]()});});}function _0x124a24(_0x53cbd9){const _0x795d76=_0x3d8865;_0x1845e1[_0x795d76('0x163f')]['countContactsQueueCampaignHopperFinal']({'id':_0x53cbd9})[_0x795d76('0xe53')][_0x795d76('0x683')](function(_0x3ba9ad){const _0x536248=_0x795d76;_0x2e3ca0()[_0x536248('0xf22')](_0x2ea83f[_0x536248('0x6d5')],_0x3ba9ad[0x0]);})['catch'](function(_0x166832){const _0x131bcd=_0x795d76;_0x30c340[_0x131bcd('0x52a')]({'title':_0x166832[_0x131bcd('0x13ee')]?_0x131bcd('0x2168')+_0x166832[_0x131bcd('0x13ee')]+_0x131bcd('0xbf6')+_0x166832[_0x131bcd('0x24a9')]:_0x131bcd('0xa42'),'msg':_0x166832[_0x131bcd('0x5a5')]?JSON[_0x131bcd('0x258a')](_0x166832['data'][_0x131bcd('0x8c2')]):_0x166832[_0x131bcd('0x8c2')]||_0x166832[_0x131bcd('0x1ff0')]()});});}function _0x16698d(_0x1da7a2){const _0xdb0541=_0x3d8865,_0x33fb4e=_0x396708[_0xdb0541('0x1c6f')]()[_0xdb0541('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20restore\x20the\x20selected\x20contacts?')[_0xdb0541('0x26e3')]('\x20Contacts\x20selected'+_0xdb0541('0x44e'))['ariaLabel'](_0xdb0541('0x1b0d'))['targetEvent'](_0x1da7a2)['ok']('OK')[_0xdb0541('0x19fb')]('CANCEL');_0x396708[_0xdb0541('0x1d4')](_0x33fb4e)[_0xdb0541('0x683')](function(){const _0x566b5a=_0xdb0541;_0x2ea83f[_0x566b5a('0x1217')][_0x566b5a('0x1299')](function(_0x331e15){_0x5c7e29(_0x331e15);}),_0x2ea83f['selectedQueueCampaignHopperFinals']=[];});}function _0x23e6f4(_0x18ba4f,_0x4b7344){const _0x3031b4=_0x3d8865,_0x24a51c=_0x396708[_0x3031b4('0x1c6f')]()[_0x3031b4('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20restore\x20the\x20contact?')[_0x3031b4('0x26e3')](''+_0x3031b4('0x1309')+_0x3031b4('0x20f1')+_0x3031b4('0x44e'))['ariaLabel'](_0x3031b4('0xed9'))[_0x3031b4('0xe42')](_0x4b7344)['ok']('OK')['cancel'](_0x3031b4('0x16b8'));_0x396708[_0x3031b4('0x1d4')](_0x24a51c)[_0x3031b4('0x683')](function(){_0x5c7e29(_0x18ba4f);},function(){const _0x32c51c=_0x3031b4;console[_0x32c51c('0x1b2b')](_0x32c51c('0x16b8'));});}function _0xd5d37d(_0x3d50bb){const _0x45e31f=_0x3d8865,_0x23cee1={};return _0x23cee1[_0x45e31f('0xd31')]=_0x3d50bb[_0x45e31f('0x11a5')],_0x23cee1[_0x45e31f('0x1ff9')]=_0x1aaf93()()[_0x45e31f('0x26dd')]('YYYY-MM-DD\x20HH:mm:ss'),_0x23cee1[_0x45e31f('0x1e2c')]=0x0,_0x23cee1[_0x45e31f('0xbfb')]=0x0,_0x23cee1[_0x45e31f('0x284c')]=0x0,_0x23cee1['countglobal']=0x0,_0x23cee1['ContactId']=_0x3d50bb[_0x45e31f('0x670')],_0x23cee1['ListId']=_0x3d50bb[_0x45e31f('0x1e4f')],_0x23cee1[_0x45e31f('0x10c5')]=_0x3d50bb['deleted']?null:_0x3d50bb[_0x45e31f('0x10c5')],_0x23cee1['VoiceQueueId']=_0x3d50bb['VoiceQueueId'],_0x23cee1[_0x45e31f('0x11c')]=_0x3d50bb[_0x45e31f('0x11c')],_0x23cee1[_0x45e31f('0xe1e')]=_0x3d50bb['recallme']?0x3:0x2,_0x23cee1['recallme']=_0x3d50bb[_0x45e31f('0x202f')]?!![]:![],_0x23cee1;}function _0x255acc(_0x5ae286){const _0x4eebb8=_0x3d8865,_0x42e126={};return _0x42e126[_0x4eebb8('0x11a5')]=_0x5ae286[_0x4eebb8('0x11a5')],_0x42e126[_0x4eebb8('0x554')]=_0x5ae286['calleridname'],_0x42e126[_0x4eebb8('0x1ff9')]=_0x1aaf93()()[_0x4eebb8('0x26dd')](_0x4eebb8('0x865')),_0x42e126[_0x4eebb8('0x1e2c')]=_0x5ae286[_0x4eebb8('0x1e2c')],_0x42e126[_0x4eebb8('0xbfb')]=_0x5ae286['countcongestionretry'],_0x42e126['countnoanswerretry']=_0x5ae286['countnoanswerretry'],_0x42e126[_0x4eebb8('0x10d2')]=_0x5ae286[_0x4eebb8('0x10d2')],_0x42e126[_0x4eebb8('0x670')]=_0x5ae286[_0x4eebb8('0x670')],_0x42e126['ListId']=_0x5ae286[_0x4eebb8('0x1e4f')],_0x42e126[_0x4eebb8('0x10c5')]=_0x343743[_0x4eebb8('0x20b2')]()['id'],_0x42e126[_0x4eebb8('0x19ec')]=_0x5ae286['VoiceQueueId'],_0x42e126[_0x4eebb8('0x11c')]=_0x5ae286[_0x4eebb8('0x11c')],_0x42e126[_0x4eebb8('0xd26')]=_0x1aaf93()()['format'](_0x4eebb8('0x865')),_0x42e126[_0x4eebb8('0x1d1b')]=!![],_0x42e126[_0x4eebb8('0x2598')]=0x19,_0x42e126[_0x4eebb8('0x2419')]=_0x4eebb8('0x11e1'),_0x42e126[_0x4eebb8('0x6e9')]=_0x5ae286['campaign'],_0x42e126[_0x4eebb8('0x1bbf')]=_0x5ae286['VoiceQueueId']?_0x4eebb8('0x660'):_0x4eebb8('0x715'),_0x42e126;}function _0x5c7e29(_0x3d8e5a){_0x1845e1['cmHopperFinal']['checkContactHopper'](_0x3d8e5a)['$promise']['then'](function(_0x5c61cb){const _0x2b94fc=a0_0x4e0a;_0x30c340[_0x2b94fc('0x2289')]({'title':_0x2b94fc('0x1e8a'),'msg':_0x2b94fc('0x2a3')+_0x5c61cb['ContactId']});})['catch'](function(_0x888bd9){const _0x1e2291=a0_0x4e0a;_0x888bd9['data']===_0x1e2291('0x8cd')?_0x1845e1['cmHopper'][_0x1e2291('0xb0a')](_0xd5d37d(_0x3d8e5a))['$promise'][_0x1e2291('0x683')](function(_0x495182){const _0x32cd83=_0x1e2291;_0x30c340[_0x32cd83('0x2289')]({'title':'Restored\x20Contact','msg':'Contact\x20ID\x20'+_0x495182[_0x32cd83('0x670')]}),_0x495182[_0x32cd83('0x670')]&&_0x1845e1[_0x32cd83('0x2583')][_0x32cd83('0xb0a')](_0x255acc(_0x3d8e5a));})[_0x1e2291('0x130a')](function(_0x19ea23){const _0x70a5ce=_0x1e2291;!_0x2e3ca0()[_0x70a5ce('0x8f2')](_0x19ea23[_0x70a5ce('0x5a5')])&&_0x19ea23[_0x70a5ce('0x5a5')]['message']==='Validation\x20error'?_0x30c340['info']({'title':'The\x20contact\x20is\x20in\x20the\x20hopper','msg':_0x70a5ce('0x2a3')+_0x3d8e5a['ContactId']}):_0x30c340[_0x70a5ce('0x52a')]({'title':_0x19ea23[_0x70a5ce('0x13ee')]?_0x70a5ce('0x2168')+_0x19ea23['status']+_0x70a5ce('0xbf6')+_0x19ea23[_0x70a5ce('0x24a9')]:_0x70a5ce('0xa42'),'msg':_0x19ea23[_0x70a5ce('0x5a5')]?JSON[_0x70a5ce('0x258a')](_0x19ea23[_0x70a5ce('0x5a5')]['message']):_0x19ea23[_0x70a5ce('0x8c2')]||_0x19ea23[_0x70a5ce('0x1ff0')]()});}):_0x30c340['error']({'title':_0x888bd9[_0x1e2291('0x13ee')]?_0x1e2291('0x2168')+_0x888bd9['status']+_0x1e2291('0xbf6')+_0x888bd9['statusText']:_0x1e2291('0xa42'),'msg':_0x888bd9[_0x1e2291('0x5a5')]?JSON[_0x1e2291('0x258a')](_0x888bd9[_0x1e2291('0x5a5')]['message']):_0x888bd9[_0x1e2291('0x8c2')]||_0x888bd9[_0x1e2291('0x1ff0')]()});});}let _0x46c0bc=!![],_0x5bf2e7=0x1;_0xee8d10[_0x3d8865('0x186d')](_0x3d8865('0x229'),function(_0x5a8ede,_0xed05a6){const _0x59f9e2=_0x3d8865;_0x46c0bc?_0x13c21a(function(){_0x46c0bc=![];}):(!_0xed05a6&&(_0x5bf2e7=_0x2ea83f[_0x59f9e2('0x23a2')][_0x59f9e2('0xdf8')]),_0x5a8ede!==_0xed05a6&&(_0x2ea83f[_0x59f9e2('0x23a2')][_0x59f9e2('0xdf8')]=0x1),!_0x5a8ede&&(_0x2ea83f[_0x59f9e2('0x23a2')][_0x59f9e2('0xdf8')]=_0x5bf2e7),_0x47903d());});}const _0x5eef85=_0x77cd;_0x41a1eb[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),'$state','$q',_0x189033('0x1d08'),'$timeout','$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x41a1eb(_0x6b1449,_0x4f1142,_0x2770ae,_0x4c0ef6,_0x1dc645,_0xec055f,_0x316c7d,_0x22f654,_0x207599,_0x4d63cd,_0x549e76){const _0x2a2478=_0x189033,_0x3bb9be=this;_0x3bb9be[_0x2a2478('0x11ed')]=_0x549e76[_0x2a2478('0x20b2')](),_0x3bb9be['queueCampaign']={},_0x3bb9be[_0x2a2478('0x29e')]={'count':0x0,'rows':[]},_0x3bb9be[_0x2a2478('0x491')]=[],_0x3bb9be[_0x2a2478('0x1134')],_0x3bb9be['query']={'fields':_0x2a2478('0x583'),'sort':_0x2a2478('0x24aa'),'limit':0xa,'page':0x1},_0x3bb9be[_0x2a2478('0x12f3')]=_0x3c4c94,_0x3bb9be[_0x2a2478('0x26eb')]=_0x214dbd,_0x3bb9be[_0x2a2478('0x53')]=_0x9e417e,_0x3bb9be[_0x2a2478('0x170d')]=_0x471566,_0x3bb9be['exportSelectedQueueCampaignHopperHistories']=_0x165a55,_0x3bb9be['deleteQueueCampaignHopperHistory']=_0x49066c,_0x3bb9be['deleteSelectedQueueCampaignHopperHistories']=_0x89bb8b;function _0x3c4c94(_0xe2ab88,_0x38be3a){const _0x586c2a=_0x2a2478;_0x3bb9be[_0x586c2a('0x1bd9')]=_0xe2ab88,_0x3bb9be['crudPermissions']=typeof _0x38be3a!=='undefined'?_0x38be3a:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3bb9be[_0x586c2a('0x23a2')][_0x586c2a('0x19ec')]=_0x3bb9be['queueCampaign']['id'],_0x3bb9be[_0x586c2a('0x23a2')]['id']=_0x3bb9be['queueCampaign']['id'],_0x471566();}function _0x214dbd(_0x591429,_0x2ee4c2){const _0x5dce21=_0x2a2478,_0x1ddd77=_0x316c7d['confirm']()['title'](_0x5dce21('0x226e'))[_0x5dce21('0x26e3')](_0x5dce21('0xed5')+(_0x591429[_0x5dce21('0x60a')]||_0x591429['id']&&_0x2e3ca0()[_0x5dce21('0x2711')](_0x5dce21('0x100e'))+_0x591429['id']||_0x5dce21('0xd37'))+''+_0x5dce21('0x1ee7'))[_0x5dce21('0x1040')](_0x5dce21('0x11dc'))['targetEvent'](_0x2ee4c2)['ok']('OK')[_0x5dce21('0x19fb')](_0x5dce21('0x16b8'));_0x316c7d['show'](_0x1ddd77)['then'](function(){_0x49066c(_0x591429);},function(){const _0xbff340=_0x5dce21;console[_0xbff340('0x1b2b')]('CANCEL');});}function _0x9e417e(_0x291663){_0x3bb9be['queueCampaignHopperHistories']=_0x291663||{'count':0x0,'rows':[]};}function _0x471566(){const _0x1e81b7=_0x2a2478;_0x3bb9be[_0x1e81b7('0x23a2')]['offset']=(_0x3bb9be[_0x1e81b7('0x23a2')][_0x1e81b7('0xdf8')]-0x1)*_0x3bb9be[_0x1e81b7('0x23a2')][_0x1e81b7('0x6f0')],_0x3bb9be[_0x1e81b7('0x1883')]=_0x4d63cd[_0x1e81b7('0x204c')][_0x1e81b7('0x816')](_0x3bb9be[_0x1e81b7('0x23a2')],_0x9e417e)[_0x1e81b7('0xe53')];}function _0x49066c(_0x45961e){const _0x105100=_0x2a2478;_0x4d63cd[_0x105100('0xd37')][_0x105100('0xd7e')]({'id':_0x45961e['id']})[_0x105100('0xe53')][_0x105100('0x683')](function(){const _0x3774d5=_0x105100;_0x2e3ca0()['remove'](_0x3bb9be[_0x3774d5('0x29e')][_0x3774d5('0xf5d')],{'id':_0x45961e['id']}),_0x3bb9be[_0x3774d5('0x29e')]['count']-=0x1,!_0x3bb9be[_0x3774d5('0x29e')]['rows'][_0x3774d5('0x1564')]&&_0x471566(),_0x207599['success']({'title':'HopperHistory\x20deleted!','msg':_0x45961e[_0x3774d5('0x60a')]?_0x45961e[_0x3774d5('0x60a')]+_0x3774d5('0x194d'):''});})[_0x105100('0x130a')](function(_0x3c5adf){const _0x144596=_0x105100;if(_0x3c5adf['data']&&_0x3c5adf['data'][_0x144596('0x17f')]&&_0x3c5adf[_0x144596('0x5a5')][_0x144596('0x17f')][_0x144596('0x1564')]){_0x3bb9be[_0x144596('0x17f')]=_0x3c5adf[_0x144596('0x5a5')][_0x144596('0x17f')]||[{'message':_0x3c5adf[_0x144596('0x1ff0')](),'type':_0x144596('0xa42')}];for(let _0x3737b1=0x0;_0x3737b1<_0x3c5adf[_0x144596('0x5a5')][_0x144596('0x17f')][_0x144596('0x1564')];_0x3737b1++){_0x207599[_0x144596('0x52a')]({'title':_0x3c5adf[_0x144596('0x5a5')][_0x144596('0x17f')][_0x3737b1][_0x144596('0xcf0')],'msg':_0x3c5adf[_0x144596('0x5a5')][_0x144596('0x17f')][_0x3737b1][_0x144596('0x8c2')]});}}else _0x207599[_0x144596('0x52a')]({'title':_0x3c5adf[_0x144596('0x13ee')]?_0x144596('0x2168')+_0x3c5adf[_0x144596('0x13ee')]+_0x144596('0xbf6')+_0x3c5adf[_0x144596('0x24a9')]:_0x144596('0xa42'),'msg':_0x3c5adf[_0x144596('0x5a5')]?JSON[_0x144596('0x258a')](_0x3c5adf[_0x144596('0x5a5')][_0x144596('0x8c2')]):_0x3c5adf['message']||_0x3c5adf[_0x144596('0x1ff0')]()});});}function _0x165a55(){const _0x4db65f=_0x2a2478,_0x540ac7=angular[_0x4db65f('0x1a86')](_0x3bb9be['selectedQueueCampaignHopperHistories']);return _0x3bb9be['selectedQueueCampaignHopperHistories']=[],_0x540ac7;}function _0x89bb8b(_0x26c3bb){const _0x5d9b3f=_0x2a2478,_0x1161cf=_0x316c7d[_0x5d9b3f('0x1c6f')]()[_0x5d9b3f('0xf28')](_0x5d9b3f('0x14d1'))[_0x5d9b3f('0x26e3')](_0x5d9b3f('0xed5')+_0x3bb9be[_0x5d9b3f('0x491')][_0x5d9b3f('0x1564')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x5d9b3f('0x1040')](_0x5d9b3f('0x499'))['targetEvent'](_0x26c3bb)['ok']('OK')[_0x5d9b3f('0x19fb')](_0x5d9b3f('0x16b8'));_0x316c7d[_0x5d9b3f('0x1d4')](_0x1161cf)[_0x5d9b3f('0x683')](function(){const _0x31585c=_0x5d9b3f;_0x3bb9be[_0x31585c('0x491')][_0x31585c('0x1299')](function(_0x37b6a4){_0x49066c(_0x37b6a4);}),_0x3bb9be[_0x31585c('0x491')]=[];});}let _0x2e63d0=!![],_0x2fb407=0x1;_0x4f1142[_0x2a2478('0x186d')](_0x2a2478('0x229'),function(_0xf17370,_0x22e0f4){const _0x579bb6=_0x2a2478;_0x2e63d0?_0xec055f(function(){_0x2e63d0=![];}):(!_0x22e0f4&&(_0x2fb407=_0x3bb9be[_0x579bb6('0x23a2')][_0x579bb6('0xdf8')]),_0xf17370!==_0x22e0f4&&(_0x3bb9be['query'][_0x579bb6('0xdf8')]=0x1),!_0xf17370&&(_0x3bb9be['query']['page']=_0x2fb407),_0x471566());});}const _0x5b2fab=_0x41a1eb;_0x3f96f6[_0x189033('0x14be')]=['$cookies',_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x3f96f6(_0xf3019e,_0x50ab23,_0x52e86b,_0x238db6,_0x31294d,_0x34aa34,_0x117979,_0x2bd205,_0x2982c0,_0x8549e2,_0x1fb5ee){const _0x45e772=_0x189033,_0x3f6d20=this;_0x3f6d20[_0x45e772('0x11ed')]=_0x1fb5ee['getCurrentUser'](),_0x3f6d20[_0x45e772('0x1bd9')]={},_0x3f6d20['queueCampaignHoppers']={'count':0x0,'rows':[]},_0x3f6d20['selectedQueueCampaignHoppers']=[],_0x3f6d20[_0x45e772('0x1134')],_0x3f6d20[_0x45e772('0x23a2')]={'fields':'createdAt,updatedAt,id,ContactId,phone,countcongestionretry,countbusyretry,countnoanswerretry,countnosuchnumberretry,countdropretry,countabandonedretry,countmachineretry,countagentrejectretry,scheduledat,priority,recallme,UserId','sort':_0x45e772('0xc36'),'limit':0xa,'page':0x1},_0x3f6d20[_0x45e772('0x8a4')]=_0x2e3ca0()['keyBy']([{'option':_0x45e772('0x786'),'value':_0x45e772('0x2395')},{'option':_0x45e772('0x1526'),'value':'\x273\x27'},{'option':'Medium','value':_0x45e772('0x246f')},{'option':'Low','value':_0x45e772('0x1597')},{'option':'Lowest','value':'\x270\x27'}],function(_0xca21d1){const _0x3f0ee0=_0x45e772;return _0x2e3ca0()[_0x3f0ee0('0x1725')](_0xca21d1[_0x3f0ee0('0x1c6b')],new RegExp('\x27','g'),'');}),_0x3f6d20['init']=_0x5953f0,_0x3f6d20['deleteConfirm']=_0x5aa9d0,_0x3f6d20[_0x45e772('0x53')]=_0x2451a9,_0x3f6d20['getQueueCampaignHoppers']=_0x59a8e6,_0x3f6d20[_0x45e772('0x27d0')]=_0x121dd0,_0x3f6d20[_0x45e772('0xe3b')]=_0xf7155,_0x3f6d20['deleteQueueCampaignHopper']=_0x1c4f36,_0x3f6d20[_0x45e772('0x93b')]=_0x43f5ec,_0x1fb5ee[_0x45e772('0xca1')]('admin')?_0x8549e2[_0x45e772('0xc96')][_0x45e772('0x1e6e')]({'fields':_0x45e772('0xa10'),'role':_0x45e772('0x2327'),'sort':_0x45e772('0x60a'),'nolimit':_0x45e772('0x26ac')})[_0x45e772('0xe53')][_0x45e772('0x683')](function(_0x5e739d){const _0x4d82d8=_0x45e772;_0x3f6d20[_0x4d82d8('0x756')]=_0x5e739d[_0x4d82d8('0xf5d')]||[];})['catch'](function(_0x218df2){const _0x3883cd=_0x45e772;_0x2982c0['error']({'title':_0x218df2['status']?_0x3883cd('0x2168')+_0x218df2[_0x3883cd('0x13ee')]+_0x3883cd('0xbf6')+_0x218df2[_0x3883cd('0x24a9')]:'SYSTEM:GET_AGENTS','msg':_0x218df2['data']?JSON['stringify'](_0x218df2['data']):_0x218df2[_0x3883cd('0x1ff0')]()});}):_0x8549e2['user'][_0x45e772('0x1e6e')]({'fields':_0x45e772('0xa10'),'role':_0x45e772('0x2327'),'sort':_0x45e772('0x60a'),'nolimit':_0x45e772('0x26ac')})[_0x45e772('0xe53')][_0x45e772('0x683')](function(_0xf75796){const _0x292930=_0x45e772;_0x3f6d20[_0x292930('0x756')]=_0xf75796[_0x292930('0xf5d')]||[];})[_0x45e772('0x683')](function(){const _0x55bcac=_0x45e772;return _0x8549e2[_0x55bcac('0x22df')]['get']({'userProfileId':_0x3f6d20[_0x55bcac('0x11ed')][_0x55bcac('0x2f')],'sectionId':0xca})['$promise'];})[_0x45e772('0x683')](function(_0x330fdd){const _0xdad9d9=_0x45e772,_0x266f4d=_0x330fdd&&_0x330fdd[_0xdad9d9('0xf5d')]?_0x330fdd[_0xdad9d9('0xf5d')][0x0]:null;if(!_0x266f4d){const _0x3d8261=[];let _0x33e259=null;_0x3f6d20[_0xdad9d9('0x1bd9')]&&(_0x33e259=_0x2e3ca0()['find'](_0x3f6d20[_0xdad9d9('0x756')],{'id':Number(_0x3f6d20[_0xdad9d9('0x1bd9')]['UserId'])}));for(let _0xa6a36c=0x0;_0xa6a36c<_0x3f6d20[_0xdad9d9('0x756')]['length'];_0xa6a36c++){_0x33e259&&_0x3f6d20['agents'][_0xa6a36c]['id']===_0x33e259['id']&&(_0x3f6d20['agents'][_0xa6a36c][_0xdad9d9('0x319')]=![],_0x3d8261[_0xdad9d9('0x1fd0')](_0x3f6d20[_0xdad9d9('0x756')][_0xa6a36c]));}_0x3f6d20['agents']=_0x3d8261;}else{if(!_0x266f4d[_0xdad9d9('0x170')])return _0x8549e2[_0xdad9d9('0xcf7')][_0xdad9d9('0x1e6e')]({'sectionId':_0x266f4d['id']})[_0xdad9d9('0xe53')][_0xdad9d9('0x683')](function(_0x555e56){const _0x48e06f=_0xdad9d9,_0x1f9ad1=_0x2e3ca0()[_0x48e06f('0x386')](_0x555e56['rows'],function(_0x7ed42c){const _0x62d5fd=_0x48e06f;return _0x2e3ca0()['find'](_0x3f6d20['agents'],{'id':_0x7ed42c[_0x62d5fd('0x832')]});});let _0x3d9be4=null;_0x3f6d20[_0x48e06f('0x1bd9')]&&(_0x3d9be4=_0x2e3ca0()['find'](_0x3f6d20[_0x48e06f('0x756')],{'id':Number(_0x3f6d20[_0x48e06f('0x1bd9')][_0x48e06f('0x10c5')])}));if(_0x3d9be4&&!_0x2e3ca0()[_0x48e06f('0x7a2')](_0x1f9ad1,['id',_0x3d9be4['id']])){const _0x224283=_0x2e3ca0()[_0x48e06f('0x1c07')](_0x3f6d20[_0x48e06f('0x756')],{'id':_0x3d9be4['id']});_0x224283['canSelect']=![],_0x1f9ad1[_0x48e06f('0x1fd0')](_0x224283);}_0x3f6d20[_0x48e06f('0x756')]=_0x1f9ad1;});}})['catch'](function(_0x337a2){const _0x5cf33a=_0x45e772;_0x2982c0[_0x5cf33a('0x52a')]({'title':_0x337a2[_0x5cf33a('0x13ee')]?_0x5cf33a('0x2168')+_0x337a2[_0x5cf33a('0x13ee')]+_0x5cf33a('0xbf6')+_0x337a2['statusText']:'SYSTEM:GETagents','msg':_0x337a2['data']?JSON[_0x5cf33a('0x258a')](_0x337a2[_0x5cf33a('0x5a5')]):_0x337a2[_0x5cf33a('0x1ff0')]()});});function _0x5953f0(_0x8d3ffd,_0x2871ee){const _0x1dfbf2=_0x45e772;_0x3f6d20[_0x1dfbf2('0x1bd9')]=_0x8d3ffd,_0x3f6d20[_0x1dfbf2('0x1134')]=typeof _0x2871ee!==_0x1dfbf2('0x1867')?_0x2871ee:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x3f6d20[_0x1dfbf2('0x23a2')][_0x1dfbf2('0x19ec')]=_0x3f6d20[_0x1dfbf2('0x1bd9')]['id'],_0x3f6d20['query']['id']=_0x3f6d20[_0x1dfbf2('0x1bd9')]['id'],_0x59a8e6();}function _0x5aa9d0(_0x1972ea,_0x415583){const _0x283a9c=_0x45e772,_0x2a0de0=_0x117979[_0x283a9c('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20hopper?')[_0x283a9c('0x26e3')](_0x283a9c('0xed5')+(_0x1972ea['name']||_0x1972ea['id']&&_0x2e3ca0()[_0x283a9c('0x2711')](_0x283a9c('0x2ad'))+_0x1972ea['id']||_0x283a9c('0x1da2'))+_0x283a9c('0x20f1')+'\x20will\x20be\x20deleted.')[_0x283a9c('0x1040')](_0x283a9c('0x18fa'))[_0x283a9c('0xe42')](_0x415583)['ok']('OK')[_0x283a9c('0x19fb')]('CANCEL');_0x117979['show'](_0x2a0de0)[_0x283a9c('0x683')](function(){_0x1c4f36(_0x1972ea);},function(){const _0x5c0c45=_0x283a9c;console[_0x5c0c45('0x1b2b')](_0x5c0c45('0x16b8'));});}function _0x2451a9(_0x259e51){const _0x4e4c90=_0x45e772;_0x3f6d20[_0x4e4c90('0x1736')]=_0x259e51||{'count':0x0,'rows':[]};}function _0x59a8e6(){const _0x273fd4=_0x45e772;_0x3f6d20[_0x273fd4('0x23a2')][_0x273fd4('0x1cc8')]=(_0x3f6d20[_0x273fd4('0x23a2')][_0x273fd4('0xdf8')]-0x1)*_0x3f6d20[_0x273fd4('0x23a2')][_0x273fd4('0x6f0')],_0x3f6d20[_0x273fd4('0x1883')]=_0x8549e2[_0x273fd4('0x204c')][_0x273fd4('0x21f7')](_0x3f6d20[_0x273fd4('0x23a2')],_0x2451a9)[_0x273fd4('0xe53')];}function _0x121dd0(_0x42b670,_0x3f0bec){const _0x3e4260=_0x45e772;_0x117979[_0x3e4260('0x1d4')]({'controller':_0x3e4260('0x17f9'),'controllerAs':'vm','templateUrl':_0x46751f,'parent':angular[_0x3e4260('0x1fcc')](_0x2bd205[_0x3e4260('0x18e5')]),'targetEvent':_0x42b670,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x3f6d20[_0x3e4260('0x1bd9')],'hopper':_0x3f0bec,'hoppers':_0x3f6d20[_0x3e4260('0x1736')][_0x3e4260('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x3f6d20[_0x3e4260('0x1134')]}});}function _0x1c4f36(_0x59efcb){const _0x1ef2d1=_0x45e772;_0x8549e2['cmHopper'][_0x1ef2d1('0xd7e')]({'id':_0x59efcb['id']})[_0x1ef2d1('0xe53')]['then'](function(){const _0x1675e2=_0x1ef2d1;_0x2e3ca0()['remove'](_0x3f6d20[_0x1675e2('0x1736')][_0x1675e2('0xf5d')],{'id':_0x59efcb['id']}),_0x3f6d20[_0x1675e2('0x1736')]['count']-=0x1,!_0x3f6d20[_0x1675e2('0x1736')][_0x1675e2('0xf5d')][_0x1675e2('0x1564')]&&_0x59a8e6(),_0x2982c0[_0x1675e2('0x53')]({'title':'Hopper\x20deleted!','msg':_0x59efcb['name']?_0x59efcb['name']+_0x1675e2('0x194d'):''});})[_0x1ef2d1('0x130a')](function(_0xe41699){const _0x17fb54=_0x1ef2d1;if(_0xe41699[_0x17fb54('0x5a5')]&&_0xe41699['data']['errors']&&_0xe41699[_0x17fb54('0x5a5')][_0x17fb54('0x17f')][_0x17fb54('0x1564')]){_0x3f6d20[_0x17fb54('0x17f')]=_0xe41699[_0x17fb54('0x5a5')]['errors']||[{'message':_0xe41699[_0x17fb54('0x1ff0')](),'type':_0x17fb54('0xa42')}];for(let _0x4fb770=0x0;_0x4fb770<_0xe41699['data'][_0x17fb54('0x17f')][_0x17fb54('0x1564')];_0x4fb770++){_0x2982c0[_0x17fb54('0x52a')]({'title':_0xe41699[_0x17fb54('0x5a5')][_0x17fb54('0x17f')][_0x4fb770][_0x17fb54('0xcf0')],'msg':_0xe41699[_0x17fb54('0x5a5')][_0x17fb54('0x17f')][_0x4fb770][_0x17fb54('0x8c2')]});}}else _0x2982c0[_0x17fb54('0x52a')]({'title':_0xe41699['status']?_0x17fb54('0x2168')+_0xe41699['status']+_0x17fb54('0xbf6')+_0xe41699['statusText']:_0x17fb54('0xa42'),'msg':_0xe41699['data']?JSON[_0x17fb54('0x258a')](_0xe41699['data'][_0x17fb54('0x8c2')]):_0xe41699[_0x17fb54('0x8c2')]||_0xe41699[_0x17fb54('0x1ff0')]()});});}function _0xf7155(){const _0x4a727f=_0x45e772,_0x2f2049=angular[_0x4a727f('0x1a86')](_0x3f6d20[_0x4a727f('0x50b')]);return _0x3f6d20[_0x4a727f('0x50b')]=[],_0x2f2049;}function _0x43f5ec(_0x52455b){const _0x40f805=_0x45e772,_0x181b4c=_0x117979[_0x40f805('0x1c6f')]()[_0x40f805('0xf28')](_0x40f805('0x228e'))[_0x40f805('0x26e3')](_0x40f805('0xed5')+_0x3f6d20[_0x40f805('0x50b')][_0x40f805('0x1564')]+'\x20selected'+'\x20will\x20be\x20deleted.')[_0x40f805('0x1040')]('delete\x20hoppers')[_0x40f805('0xe42')](_0x52455b)['ok']('OK')[_0x40f805('0x19fb')](_0x40f805('0x16b8'));_0x117979[_0x40f805('0x1d4')](_0x181b4c)[_0x40f805('0x683')](function(){const _0x3ee52e=_0x40f805;_0x3f6d20[_0x3ee52e('0x50b')][_0x3ee52e('0x1299')](function(_0x565d6e){_0x1c4f36(_0x565d6e);}),_0x3f6d20['selectedQueueCampaignHoppers']=[];});}let _0x552c0a=!![],_0x9cbbff=0x1;_0x50ab23[_0x45e772('0x186d')]('vm_dc.query.filter',function(_0x4bb124,_0x4ce897){const _0x59eb4d=_0x45e772;_0x552c0a?_0x34aa34(function(){_0x552c0a=![];}):(!_0x4ce897&&(_0x9cbbff=_0x3f6d20[_0x59eb4d('0x23a2')][_0x59eb4d('0xdf8')]),_0x4bb124!==_0x4ce897&&(_0x3f6d20[_0x59eb4d('0x23a2')][_0x59eb4d('0xdf8')]=0x1),!_0x4bb124&&(_0x3f6d20[_0x59eb4d('0x23a2')]['page']=_0x9cbbff),_0x59a8e6());});}const _0x26e6af=_0x3f96f6;_0x4f9eb1[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$state','$location',_0x189033('0x1e48'),'$q','$translate','toasty',_0x189033('0x1c63'),_0x189033('0x1da2'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x4f9eb1(_0x55ca78,_0x334e8d,_0x5c6970,_0xba2d74,_0x487e2e,_0x5a182e,_0x48d107,_0x4bb83e,_0x181c14,_0x551c19,_0x4d1a88,_0xa3eb6d,_0x34234f,_0x258433){const _0x5b3dd0=_0x189033,_0x5a0b06=this;_0x5a0b06[_0x5b3dd0('0x11ed')]=_0x4d1a88[_0x5b3dd0('0x20b2')](),_0x5a0b06[_0x5b3dd0('0x17f')]=[],_0x5a0b06[_0x5b3dd0('0x260a')]=_0x34234f,_0x5a0b06[_0x5b3dd0('0xace')]=_0xa3eb6d,_0x5a0b06[_0x5b3dd0('0x1134')]=_0x258433,_0x5a0b06[_0x5b3dd0('0x258d')]={},_0x5a0b06[_0x5b3dd0('0x19b2')]=_0x5a0b06[_0x5b3dd0('0x260a')]&&_0x5a0b06[_0x5b3dd0('0x260a')][_0x5b3dd0('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x5a0b06[_0x5b3dd0('0xf28')]=_0x5b3dd0('0xbd0'),_0x5a0b06[_0x5b3dd0('0x1da2')]=angular['copy'](_0x181c14),_0x5a0b06[_0x5b3dd0('0x1c63')]=_0x4bb83e,_0x5a0b06[_0x5b3dd0('0x7b6')]=![];!_0x5a0b06[_0x5b3dd0('0x1da2')]&&(_0x5a0b06['hopper']={},_0x5a0b06[_0x5b3dd0('0xf28')]=_0x5b3dd0('0x26e4'),_0x5a0b06[_0x5b3dd0('0x7b6')]=!![]);_0x334e8d[_0x5b3dd0('0x7f2')]['id']&&(_0x5a0b06[_0x5b3dd0('0x1da2')][_0x5b3dd0('0x19ec')]=_0x334e8d['params']['id']);_0x5a0b06['addNewHopper']=_0x2d6304,_0x5a0b06[_0x5b3dd0('0xdab')]=_0x8fd2f0,_0x5a0b06[_0x5b3dd0('0x2391')]=_0x3d4088,_0x5a0b06[_0x5b3dd0('0x16b3')]=_0x2f271e,_0x5a0b06[_0x5b3dd0('0xf82')]=_0x5398b1,_0x4d1a88[_0x5b3dd0('0xca1')]('admin')?_0x551c19[_0x5b3dd0('0xc96')][_0x5b3dd0('0x1e6e')]({'fields':_0x5b3dd0('0xa10'),'role':_0x5b3dd0('0x2327'),'sort':'name','nolimit':_0x5b3dd0('0x26ac')})[_0x5b3dd0('0xe53')][_0x5b3dd0('0x683')](function(_0x366015){const _0x16f3e5=_0x5b3dd0;_0x5a0b06[_0x16f3e5('0x756')]=_0x366015[_0x16f3e5('0xf5d')]||[];})['catch'](function(_0x111430){const _0x454c34=_0x5b3dd0;_0x48d107[_0x454c34('0x52a')]({'title':_0x111430[_0x454c34('0x13ee')]?_0x454c34('0x2168')+_0x111430['status']+_0x454c34('0xbf6')+_0x111430['statusText']:'SYSTEM:GET_AGENTS','msg':_0x111430[_0x454c34('0x5a5')]?JSON[_0x454c34('0x258a')](_0x111430['data']):_0x111430['toString']()});}):_0x551c19[_0x5b3dd0('0xc96')][_0x5b3dd0('0x1e6e')]({'fields':_0x5b3dd0('0xa10'),'role':_0x5b3dd0('0x2327'),'sort':'name','nolimit':'true'})[_0x5b3dd0('0xe53')][_0x5b3dd0('0x683')](function(_0x2adceb){const _0x2bdea3=_0x5b3dd0;_0x5a0b06['agents']=_0x2adceb[_0x2bdea3('0xf5d')]||[];})[_0x5b3dd0('0x683')](function(){const _0x5e86b1=_0x5b3dd0;return _0x551c19[_0x5e86b1('0x22df')][_0x5e86b1('0x1e6e')]({'userProfileId':_0x5a0b06['currentUser'][_0x5e86b1('0x2f')],'sectionId':0xca})[_0x5e86b1('0xe53')];})[_0x5b3dd0('0x683')](function(_0x2927d4){const _0x4dc659=_0x5b3dd0,_0xc36752=_0x2927d4&&_0x2927d4[_0x4dc659('0xf5d')]?_0x2927d4['rows'][0x0]:null;if(!_0xc36752){const _0x21e8d0=[];let _0x1edb4a=null;_0x5a0b06[_0x4dc659('0x1da2')]&&(_0x1edb4a=_0x2e3ca0()[_0x4dc659('0x1c07')](_0x5a0b06['agents'],{'id':Number(_0x5a0b06['hopper'][_0x4dc659('0x10c5')])}));for(let _0xbc132f=0x0;_0xbc132f<_0x5a0b06[_0x4dc659('0x756')][_0x4dc659('0x1564')];_0xbc132f++){_0x1edb4a&&_0x5a0b06[_0x4dc659('0x756')][_0xbc132f]['id']===_0x1edb4a['id']&&(_0x5a0b06[_0x4dc659('0x756')][_0xbc132f]['canSelect']=![],_0x21e8d0['push'](_0x5a0b06[_0x4dc659('0x756')][_0xbc132f]));}_0x5a0b06['agents']=_0x21e8d0;}else{if(!_0xc36752[_0x4dc659('0x170')])return _0x551c19[_0x4dc659('0xcf7')]['get']({'sectionId':_0xc36752['id']})[_0x4dc659('0xe53')][_0x4dc659('0x683')](function(_0x345293){const _0x9d8e7c=_0x4dc659,_0x341cb4=_0x2e3ca0()['map'](_0x345293[_0x9d8e7c('0xf5d')],function(_0x32d4a5){const _0xa422ca=_0x9d8e7c;return _0x2e3ca0()[_0xa422ca('0x1c07')](_0x5a0b06[_0xa422ca('0x756')],{'id':_0x32d4a5[_0xa422ca('0x832')]});});let _0x9fe4c8=null;_0x5a0b06[_0x9d8e7c('0x1da2')]&&(_0x9fe4c8=_0x2e3ca0()['find'](_0x5a0b06[_0x9d8e7c('0x756')],{'id':Number(_0x5a0b06[_0x9d8e7c('0x1da2')][_0x9d8e7c('0x10c5')])}));if(_0x9fe4c8&&!_0x2e3ca0()[_0x9d8e7c('0x7a2')](_0x341cb4,['id',_0x9fe4c8['id']])){const _0x403701=_0x2e3ca0()[_0x9d8e7c('0x1c07')](_0x5a0b06[_0x9d8e7c('0x756')],{'id':_0x9fe4c8['id']});_0x403701[_0x9d8e7c('0x319')]=![],_0x341cb4[_0x9d8e7c('0x1fd0')](_0x403701);}_0x5a0b06[_0x9d8e7c('0x756')]=_0x341cb4;});}})[_0x5b3dd0('0x130a')](function(_0x47e50d){const _0x75d7a2=_0x5b3dd0;_0x48d107[_0x75d7a2('0x52a')]({'title':_0x47e50d[_0x75d7a2('0x13ee')]?'API:'+_0x47e50d[_0x75d7a2('0x13ee')]+_0x75d7a2('0xbf6')+_0x47e50d['statusText']:'SYSTEM:GETagents','msg':_0x47e50d[_0x75d7a2('0x5a5')]?JSON['stringify'](_0x47e50d[_0x75d7a2('0x5a5')]):_0x47e50d[_0x75d7a2('0x1ff0')]()});});function _0x2d6304(){const _0x2fbd64=_0x5b3dd0;_0x5a0b06['errors']=[],_0x551c19['cmHopper'][_0x2fbd64('0xb0a')](_0x5a0b06[_0x2fbd64('0x1da2')])[_0x2fbd64('0xe53')][_0x2fbd64('0x683')](function(_0x2f06e9){const _0x452f91=_0x2fbd64;_0x5a0b06[_0x452f91('0x1c63')][_0x452f91('0x1167')](_0x2f06e9[_0x452f91('0x24e1')]()),_0x48d107['success']({'title':_0x452f91('0x23d4'),'msg':_0x5a0b06[_0x452f91('0x1da2')][_0x452f91('0x60a')]?_0x5a0b06[_0x452f91('0x1da2')][_0x452f91('0x60a')]+_0x452f91('0x14b5'):''}),_0x5398b1(_0x2f06e9);})[_0x2fbd64('0x130a')](function(_0x10e084){const _0x3cf7dc=_0x2fbd64;if(_0x10e084[_0x3cf7dc('0x5a5')]&&_0x10e084[_0x3cf7dc('0x5a5')][_0x3cf7dc('0x17f')]&&_0x10e084['data']['errors']['length']){_0x5a0b06[_0x3cf7dc('0x17f')]=_0x10e084[_0x3cf7dc('0x5a5')][_0x3cf7dc('0x17f')]||[{'message':_0x10e084[_0x3cf7dc('0x1ff0')](),'type':_0x3cf7dc('0x1e1b')}];for(let _0x5b5677=0x0;_0x5b5677<_0x10e084[_0x3cf7dc('0x5a5')][_0x3cf7dc('0x17f')]['length'];_0x5b5677+=0x1){_0x48d107[_0x3cf7dc('0x52a')]({'title':_0x10e084[_0x3cf7dc('0x5a5')][_0x3cf7dc('0x17f')][_0x5b5677][_0x3cf7dc('0xcf0')],'msg':_0x10e084[_0x3cf7dc('0x5a5')][_0x3cf7dc('0x17f')][_0x5b5677][_0x3cf7dc('0x8c2')]});}}else _0x48d107['error']({'title':_0x10e084[_0x3cf7dc('0x13ee')]?'API:'+_0x10e084[_0x3cf7dc('0x13ee')]+'\x20-\x20'+_0x10e084['statusText']:_0x3cf7dc('0x1e1b'),'msg':_0x10e084['data']?JSON['stringify'](_0x10e084[_0x3cf7dc('0x5a5')][_0x3cf7dc('0x8c2')]):_0x10e084[_0x3cf7dc('0x1ff0')]()});});}function _0x8fd2f0(){const _0x3f57bd=_0x5b3dd0;_0x5a0b06['errors']=[];let _0x41aceb,_0x192f3c,_0x5d453a,_0xeb71ed;_0x5a0b06[_0x3f57bd('0x1da2')][_0x3f57bd('0x10c5')]=_0x5a0b06['hopper'][_0x3f57bd('0x202f')]?_0x5a0b06[_0x3f57bd('0x1da2')]['UserId']:null,_0x5a0b06[_0x3f57bd('0x1da2')][_0x3f57bd('0x1cb7')]=_0x4d1a88[_0x3f57bd('0x20b2')]()['id'],_0x551c19[_0x3f57bd('0x26cf')][_0x3f57bd('0x1e6e')]({'id':_0x5a0b06[_0x3f57bd('0x1da2')]['id'],'attributes':[_0x3f57bd('0x1ff9')]})['$promise'][_0x3f57bd('0x683')](function(_0x276494){const _0x490539=_0x3f57bd;_0x2e3ca0()[_0x490539('0x8f2')](_0x276494)||_0x2e3ca0()[_0x490539('0x173f')](_0x276494)?_0x41aceb=_0x1aaf93()()[_0x490539('0x26dd')](_0x490539('0x865')):_0x41aceb=_0x276494[_0x490539('0x1ff9')];})[_0x3f57bd('0x2874')](function(){const _0x20a642=_0x3f57bd;_0x551c19[_0x20a642('0x26cf')][_0x20a642('0x2480')]({'id':_0x5a0b06[_0x20a642('0x1da2')]['id']},_0x2e3ca0()[_0x20a642('0x8b5')](_0x5a0b06[_0x20a642('0x1da2')],[_0x20a642('0x19ec'),'CampaignId',_0x20a642('0x670'),'ListId']))[_0x20a642('0xe53')][_0x20a642('0x683')](function(_0x508f30){const _0x127059=_0x20a642;_0x192f3c=_0x508f30,_0x551c19[_0x127059('0x276e')][_0x127059('0x1e6e')]({'id':_0x192f3c[_0x127059('0x670')],'attributes':[_0x127059('0xeef'),_0x127059('0x510')]})[_0x127059('0xe53')][_0x127059('0x683')](function(_0x38be8f){const _0x203f1e=_0x127059;!_0x2e3ca0()['isNil'](_0x38be8f)&&!_0x2e3ca0()[_0x203f1e('0x8f2')](_0x38be8f[_0x203f1e('0xeef')])&&(_0x5d453a=_0x38be8f[_0x203f1e('0xeef')],!_0x2e3ca0()[_0x203f1e('0x8f2')](_0x38be8f[_0x203f1e('0x510')])&&(_0x5d453a+='\x20'+_0x38be8f[_0x203f1e('0x510')]));})['catch'](function(){_0x5d453a=undefined;})['finally'](function(){const _0xbc327b=_0x127059;_0x551c19['voiceQueue'][_0xbc327b('0x1e6e')]({'raw':![],'id':_0x192f3c[_0xbc327b('0x19ec')],'attributes':[_0xbc327b('0x60a')]})['$promise'][_0xbc327b('0x683')](function(_0x4526fe){const _0x1a11f0=_0xbc327b;_0xeb71ed=_0x4526fe[_0x1a11f0('0x60a')];})[_0xbc327b('0x130a')](function(){_0xeb71ed=undefined;})['finally'](function(){const _0x58dccd=_0xbc327b;_0x551c19[_0x58dccd('0x2583')][_0x58dccd('0xb0a')]({'state':0x18,'statedesc':_0x58dccd('0x99'),'scheduledat':_0x41aceb,'calleridnum':_0x192f3c[_0x58dccd('0xd31')],'calleridname':_0x5d453a,'campaigntype':_0x192f3c[_0x58dccd('0x19ec')]?_0x58dccd('0x660'):_0x58dccd('0x715'),'campaign':_0xeb71ed,'editedat':_0x1aaf93()()[_0x58dccd('0x26dd')](_0x58dccd('0x865')),'edited':!![],'ListId':_0x192f3c[_0x58dccd('0x1e4f')],'UserId':_0x4d1a88[_0x58dccd('0x20b2')]()['id'],'VoiceQueueId':_0x192f3c[_0x58dccd('0x19ec')],'CampaignId':_0x192f3c[_0x58dccd('0x11c')],'ContactId':_0x192f3c[_0x58dccd('0x670')],'callback':_0x192f3c[_0x58dccd('0x22b5')],'callbackuniqueid':_0x192f3c[_0x58dccd('0x8ce')],'countbusyretry':_0x192f3c[_0x58dccd('0x1e2c')],'countcongestionretry':_0x192f3c[_0x58dccd('0xbfb')],'countglobal':_0x192f3c['countglobal'],'countnoanswerretry':_0x192f3c[_0x58dccd('0x284c')],'followuptime':_0x192f3c[_0x58dccd('0x24d5')],'recallme':_0x192f3c[_0x58dccd('0x202f')]});});});const _0x4117c2=_0x2e3ca0()[_0x127059('0x1c07')](_0x5a0b06[_0x127059('0x1c63')],{'id':_0x508f30['id']});_0x4117c2&&_0x2e3ca0()[_0x127059('0xf22')](_0x4117c2,_0x2e3ca0()[_0x127059('0x24d0')](_0x508f30[_0x127059('0x24e1')](),_0x2e3ca0()[_0x127059('0x55e')](_0x4117c2))),_0x48d107[_0x127059('0x53')]({'title':_0x127059('0x16ac'),'msg':_0x5a0b06['hopper'][_0x127059('0x60a')]?_0x5a0b06[_0x127059('0x1da2')]['name']+_0x127059('0xf59'):''}),_0x5398b1(_0x508f30);})['catch'](function(_0x73f824){const _0x2b4442=_0x20a642;if(_0x73f824[_0x2b4442('0x5a5')]&&_0x73f824[_0x2b4442('0x5a5')][_0x2b4442('0x17f')]&&_0x73f824['data'][_0x2b4442('0x17f')][_0x2b4442('0x1564')]){_0x5a0b06['errors']=_0x73f824[_0x2b4442('0x5a5')]['errors']||[{'message':_0x73f824[_0x2b4442('0x1ff0')](),'type':'api.cmHopper.update'}];for(let _0x743940=0x0;_0x743940<_0x73f824[_0x2b4442('0x5a5')][_0x2b4442('0x17f')]['length'];_0x743940++){_0x48d107['error']({'title':_0x73f824[_0x2b4442('0x5a5')][_0x2b4442('0x17f')][_0x743940][_0x2b4442('0xcf0')],'msg':_0x73f824[_0x2b4442('0x5a5')][_0x2b4442('0x17f')][_0x743940][_0x2b4442('0x8c2')]});}}else _0x48d107['error']({'title':_0x73f824[_0x2b4442('0x13ee')]?'API:'+_0x73f824[_0x2b4442('0x13ee')]+_0x2b4442('0xbf6')+_0x73f824[_0x2b4442('0x24a9')]:_0x2b4442('0x83b'),'msg':_0x73f824[_0x2b4442('0x5a5')]?JSON[_0x2b4442('0x258a')](_0x73f824['data'][_0x2b4442('0x8c2')]):_0x73f824[_0x2b4442('0x1ff0')]()});});});}function _0x3d4088(_0x1159f6){const _0x2f772a=_0x5b3dd0;_0x5a0b06['errors']=[];const _0x2dd7c1=_0xba2d74[_0x2f772a('0x1c6f')]()[_0x2f772a('0xf28')](_0x2f772a('0x4d'))['content'](_0x2f772a('0x2130'))['ariaLabel'](_0x2f772a('0x7e4'))['ok']('Delete')[_0x2f772a('0x19fb')](_0x2f772a('0x253a'))[_0x2f772a('0xe42')](_0x1159f6);_0xba2d74[_0x2f772a('0x1d4')](_0x2dd7c1)[_0x2f772a('0x683')](function(){const _0x32ed7d=_0x2f772a;_0x551c19[_0x32ed7d('0x26cf')][_0x32ed7d('0xd7e')]({'id':_0x5a0b06[_0x32ed7d('0x1da2')]['id']})['$promise'][_0x32ed7d('0x683')](function(){const _0x496293=_0x32ed7d;_0x2e3ca0()[_0x496293('0x3ec')](_0x5a0b06[_0x496293('0x1c63')],{'id':_0x5a0b06[_0x496293('0x1da2')]['id']}),_0x48d107[_0x496293('0x53')]({'title':_0x496293('0xb7e'),'msg':(_0x5a0b06[_0x496293('0x1da2')]['name']||_0x496293('0x1da2'))+'\x20has\x20been\x20deleted!'}),_0x5398b1(_0x5a0b06[_0x496293('0x1da2')]);})[_0x32ed7d('0x130a')](function(_0x10d2dd){const _0x1f9613=_0x32ed7d;if(_0x10d2dd[_0x1f9613('0x5a5')]&&_0x10d2dd[_0x1f9613('0x5a5')]['errors']&&_0x10d2dd['data'][_0x1f9613('0x17f')]['length']){_0x5a0b06[_0x1f9613('0x17f')]=_0x10d2dd['data'][_0x1f9613('0x17f')]||[{'message':_0x10d2dd[_0x1f9613('0x1ff0')](),'type':'api.cmHopper.delete'}];for(let _0x28953e=0x0;_0x28953e<_0x10d2dd[_0x1f9613('0x5a5')][_0x1f9613('0x17f')][_0x1f9613('0x1564')];_0x28953e++){_0x48d107[_0x1f9613('0x52a')]({'title':_0x10d2dd[_0x1f9613('0x5a5')][_0x1f9613('0x17f')][_0x28953e][_0x1f9613('0xcf0')],'msg':_0x10d2dd[_0x1f9613('0x5a5')][_0x1f9613('0x17f')][_0x28953e][_0x1f9613('0x8c2')]});}}else _0x48d107[_0x1f9613('0x52a')]({'title':_0x10d2dd[_0x1f9613('0x13ee')]?_0x1f9613('0x2168')+_0x10d2dd[_0x1f9613('0x13ee')]+_0x1f9613('0xbf6')+_0x10d2dd[_0x1f9613('0x24a9')]:'api.cmHopper.delete','msg':_0x10d2dd['data']?JSON['stringify'](_0x10d2dd[_0x1f9613('0x5a5')][_0x1f9613('0x8c2')]):_0x10d2dd[_0x1f9613('0x8c2')]||_0x10d2dd['toString']()});});},function(){});}function _0x2f271e(_0x5a659c){return _0x5a659c===null?undefined:new Date(_0x5a659c);}function _0x5398b1(_0x35109a){_0xba2d74['hide'](_0x35109a);}}const _0x430314=_0x4f9eb1;_0x26af48['$inject']=[_0x189033('0x56b'),'toasty'];function _0x26af48(_0x61dfb1,_0x311619){const _0x99029c=_0x189033,_0x4af6b1=this;_0x4af6b1['queueCampaign']={},_0x4af6b1[_0x99029c('0x12f3')]=_0x283fe2;function _0x283fe2(_0x691ded){const _0x1f794e=_0x99029c;_0x4af6b1[_0x1f794e('0x1bd9')]=_0x691ded,_0x61dfb1[_0x1f794e('0x26cf')]['get']({'limit':0x0,'VoiceQueueId':_0x691ded['id']})[_0x1f794e('0xe53')][_0x1f794e('0x683')](function(_0x11ca2c){const _0x196484=_0x1f794e;return _0x4af6b1[_0x196484('0x2263')]=_0x11ca2c['count']||0x0,_0x61dfb1[_0x196484('0x26cf')][_0x196484('0x1e6e')]({'limit':0x0,'VoiceQueueId':_0x691ded['id'],'active':![],'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0})[_0x196484('0xe53')];})['then'](function(_0x2b1b68){const _0x3ac01c=_0x1f794e;return _0x4af6b1[_0x3ac01c('0x284b')]=_0x2b1b68[_0x3ac01c('0x50d')]||0x0,_0x61dfb1['cmHopperFinal'][_0x3ac01c('0x1e6e')]({'limit':0x0,'VoiceQueueId':_0x691ded['id']})[_0x3ac01c('0xe53')];})[_0x1f794e('0x683')](function(_0x2ffdf0){const _0x59b255=_0x1f794e;_0x4af6b1[_0x59b255('0xd8a')]=_0x2ffdf0['count']||0x0;})[_0x1f794e('0x130a')](function(_0xfec976){const _0x13d7f5=_0x1f794e;_0x311619[_0x13d7f5('0x52a')]({'title':_0xfec976[_0x13d7f5('0x13ee')]?_0x13d7f5('0x2168')+_0xfec976['status']+'\x20-\x20'+_0xfec976[_0x13d7f5('0x24a9')]:'SYSTEM:GETTAGS','msg':_0xfec976[_0x13d7f5('0x5a5')]?JSON[_0x13d7f5('0x258a')](_0xfec976[_0x13d7f5('0x5a5')]):_0xfec976[_0x13d7f5('0x1ff0')]()});});}}const _0x258f7e=_0x26af48;_0x4985df[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),'queueCampaign','$translate',_0x189033('0x2f9'),'Auth',_0x189033('0x1134')];function _0x4985df(_0x4da145,_0x210f29,_0x377177,_0x3d5e9b,_0x3f3f63,_0x460f5d,_0x2ba188,_0xd0f2fa,_0x24eec5){const _0x26a8d9=_0x189033,_0x15294c=this;_0x15294c[_0x26a8d9('0x11ed')]=_0xd0f2fa['getCurrentUser'](),_0x15294c['queueCampaign']=_0x3f3f63,_0x15294c['crudPermissions']=_0x24eec5,_0x15294c[_0x26a8d9('0x6d1')]=_0x26a8d9('0x204c'),_0x15294c[_0x26a8d9('0x578')]='getLists',_0x15294c['addApi']=_0x26a8d9('0x11ef'),_0x15294c[_0x26a8d9('0x17e8')]=_0x26a8d9('0x8d2'),_0x15294c[_0x26a8d9('0x1996')]=[],_0x15294c[_0x26a8d9('0x1c47')]=[],_0x15294c['selectedItems']=[],_0x15294c[_0x26a8d9('0x125e')]=[],_0x15294c[_0x26a8d9('0x23a7')]=[],_0x15294c[_0x26a8d9('0x2106')]=![],_0x15294c['loading']=![],_0x15294c[_0x26a8d9('0x169f')]={'readOnly':!_0x15294c['crudPermissions'][_0x26a8d9('0x1978')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':![],'orderBy':_0x26a8d9('0x60a'),'line1':'name','line2':'','line3':'','labelAll':_0x460f5d['instant'](_0x26a8d9('0x425')),'labelSelected':_0x460f5d[_0x26a8d9('0x2728')](_0x26a8d9('0x577')),'transferCallback':function(){const _0x11cd24=_0x26a8d9,_0x18c505=_0x2e3ca0()[_0x11cd24('0x25cb')](_0x15294c[_0x11cd24('0x23a7')],_0x15294c[_0x11cd24('0x1378')],'id');_0x15294c['pendingChanges']=_0x2e3ca0()['isEmpty'](_0x18c505)?![]:!![];}},_0x15294c[_0x26a8d9('0x1dd2')]=_0x2254dd,_0x15294c[_0x26a8d9('0x21fd')]=_0x2561cf,_0x15294c[_0x26a8d9('0xf82')]=_0x580fc2;function _0x2254dd(){const _0x3cafbb=_0x26a8d9;return _0xd0f2fa[_0x3cafbb('0xca1')]('admin')?_0x6e5e02()[_0x3cafbb('0x130a')](function(_0xc63ea0){const _0x3db6b1=_0x3cafbb;_0x377177[_0x3db6b1('0x52a')]({'title':_0xc63ea0['status']?_0x3db6b1('0x2168')+_0xc63ea0[_0x3db6b1('0x13ee')]+_0x3db6b1('0xbf6')+_0xc63ea0[_0x3db6b1('0x24a9')]:_0x3db6b1('0xa2a'),'msg':_0xc63ea0[_0x3db6b1('0x13ee')]?JSON['stringify'](_0xc63ea0[_0x3db6b1('0x5a5')]):_0xc63ea0[_0x3db6b1('0x1ff0')]()});}):_0x44b311()[_0x3cafbb('0x683')](function(_0x39bc1e){return _0x15294c['section']=_0x39bc1e,_0x6e5e02();})[_0x3cafbb('0x130a')](function(_0x47be85){const _0x4aa965=_0x3cafbb;_0x377177[_0x4aa965('0x52a')]({'title':_0x47be85['status']?_0x4aa965('0x2168')+_0x47be85[_0x4aa965('0x13ee')]+'\x20-\x20'+_0x47be85[_0x4aa965('0x24a9')]:'SYSTEM:GETLISTS','msg':_0x47be85[_0x4aa965('0x13ee')]?JSON[_0x4aa965('0x258a')](_0x47be85[_0x4aa965('0x5a5')]):_0x47be85['toString']()});});}function _0x44b311(){return _0x210f29(function(_0x486173,_0x131c3b){const _0x4d821b=a0_0x4e0a;_0x3d5e9b[_0x4d821b('0x22df')][_0x4d821b('0x1e6e')]({'userProfileId':_0x15294c[_0x4d821b('0x11ed')][_0x4d821b('0x2f')],'name':_0x4d821b('0x1114')})[_0x4d821b('0xe53')]['then'](function(_0x3bc815){const _0x5dc201=_0x4d821b,_0x3ccbe1=_0x3bc815&&_0x3bc815[_0x5dc201('0xf5d')]?_0x3bc815[_0x5dc201('0xf5d')][0x0]:null;_0x486173(_0x3ccbe1);})[_0x4d821b('0x130a')](function(_0x100e6f){_0x131c3b(_0x100e6f);});});}function _0x6e5e02(){return _0x210f29(function(_0x37e5ae,_0xa8a96b){const _0x2a8ad7=a0_0x4e0a;return _0x5809a4()['then'](function(_0x11d19f){const _0x22e54b=a0_0x4e0a;return _0x15294c['items']=_0x11d19f[_0x22e54b('0xf5d')]?_0x11d19f[_0x22e54b('0xf5d')]:[],_0xd0f2fa[_0x22e54b('0xca1')](_0x22e54b('0x20c2'))?_0x11d19f:_0x15294c[_0x22e54b('0x1aa')]?_0x15294c[_0x22e54b('0x1aa')][_0x22e54b('0x170')]?_0x11d19f:_0x491c75():null;})['then'](function(_0x24c72b){const _0xb0be9b=a0_0x4e0a,_0xac6f31=_0x24c72b&&_0x24c72b[_0xb0be9b('0xf5d')]?_0x24c72b[_0xb0be9b('0xf5d')]:[];return _0x15294c[_0xb0be9b('0x1c47')]=_0x2e3ca0()[_0xb0be9b('0x386')](_0xac6f31,function(_0x4e4e37){const _0x5dc821=_0xb0be9b;return _0x2e3ca0()[_0x5dc821('0x1c07')](_0x15294c[_0x5dc821('0x1996')],{'id':_0xd0f2fa[_0x5dc821('0xca1')]('admin')||_0x15294c['section'][_0x5dc821('0x170')]?_0x4e4e37['id']:_0x4e4e37['resourceId']});}),_0x15294c[_0xb0be9b('0x125e')]=angular[_0xb0be9b('0x1a86')](_0x15294c[_0xb0be9b('0x1c47')]),_0x15294c[_0xb0be9b('0x1996')]['forEach'](function(_0x2500ac){const _0x6266fa=_0xb0be9b,_0x51c174=_0x2e3ca0()[_0x6266fa('0x1c07')](_0x15294c['allowedItems'],{'id':_0x2500ac['id']});_0x15294c[_0x6266fa('0x11ed')][_0x6266fa('0xecb')]===_0x6266fa('0x20c2')?_0x2500ac['isValid']=!![]:_0x2500ac[_0x6266fa('0x24f4')]=typeof _0x51c174!==_0x6266fa('0x1867')?!![]:![];}),_0x38c409();})[_0x2a8ad7('0x683')](function(_0x358350){const _0x518952=_0x2a8ad7,_0x4e5fbf=_0x358350&&_0x358350[_0x518952('0xf5d')]?_0x358350['rows']:[];_0x15294c['selectedItems']=_0x2e3ca0()['map'](_0x4e5fbf,function(_0x4b9ea3){const _0xb41516=_0x518952;return _0x2e3ca0()[_0xb41516('0x1c07')](_0x15294c[_0xb41516('0x1996')],{'id':_0x4b9ea3['id']});}),_0x15294c[_0x518952('0x23a7')]=angular[_0x518952('0x1a86')](_0x15294c[_0x518952('0x1378')]),_0x15294c[_0x518952('0x169f')][_0x518952('0x1378')]=_0x15294c[_0x518952('0x1378')],_0x15294c['dualMultiselectOptions'][_0x518952('0x1996')]=_0x2e3ca0()['differenceBy'](_0x15294c[_0x518952('0x1c47')],_0x15294c[_0x518952('0x169f')][_0x518952('0x1378')],'id'),_0x37e5ae();})[_0x2a8ad7('0x130a')](function(_0x3af1d2){_0xa8a96b(_0x3af1d2);});});}function _0x491c75(){return _0x210f29(function(_0xf23bf9,_0x4ea042){const _0x4f85df=a0_0x4e0a;return _0x3d5e9b[_0x4f85df('0xcf7')][_0x4f85df('0x1e6e')]({'sectionId':_0x15294c[_0x4f85df('0x1aa')]['id'],'nolimit':!![]})[_0x4f85df('0xe53')][_0x4f85df('0x683')](function(_0x5b1093){_0xf23bf9(_0x5b1093);})[_0x4f85df('0x130a')](function(_0x269c4a){_0x4ea042(_0x269c4a);});});}function _0x38c409(){return _0x210f29(function(_0x34e5c5,_0x4d3e0d){const _0x3d127b=a0_0x4e0a,_0x20839f=_0x3d5e9b[_0x15294c[_0x3d127b('0x6d1')]];return _0x20839f[_0x15294c[_0x3d127b('0x578')]]({'id':_0x15294c['queueCampaign']['id'],'fields':_0x3d127b('0xa10'),'nolimit':!![]})['$promise'][_0x3d127b('0x683')](function(_0x186e72){_0x34e5c5(_0x186e72);})[_0x3d127b('0x130a')](function(_0x5f0c7b){_0x4d3e0d(_0x5f0c7b);});});}function _0x5809a4(){return _0x210f29(function(_0xdc6a75,_0x23aca3){const _0x391d10=a0_0x4e0a;return _0x3d5e9b[_0x391d10('0x259b')][_0x391d10('0x1e6e')]({'fields':_0x391d10('0xa10'),'nolimit':!![]})['$promise'][_0x391d10('0x683')](function(_0x5e710e){_0xdc6a75(_0x5e710e);})[_0x391d10('0x130a')](function(_0x27d302){_0x23aca3(_0x27d302);});});}function _0x4aa80b(_0x196573){return _0x210f29(function(_0x55714b,_0x5e9f7d){const _0x5a93db=a0_0x4e0a;if(_0x2e3ca0()['isEmpty'](_0x196573))_0x55714b();else{const _0x366f6a=_0x3d5e9b[_0x15294c[_0x5a93db('0x6d1')]];_0x366f6a[_0x15294c['addApi']]({'id':_0x15294c[_0x5a93db('0x1bd9')]['id'],'ids':_0x2e3ca0()[_0x5a93db('0x386')](_0x196573,'id')})['$promise'][_0x5a93db('0x683')](function(){_0x55714b();})[_0x5a93db('0x130a')](function(_0x1cebf6){_0x5e9f7d(_0x1cebf6);});}});}function _0x45e0e7(_0x1a09c4){return _0x210f29(function(_0x1efc7b,_0x123dc3){const _0x1db2ae=a0_0x4e0a;if(_0x2e3ca0()[_0x1db2ae('0x173f')](_0x1a09c4))_0x1efc7b();else{const _0x41cf18=_0x3d5e9b[_0x15294c['apiRoute']];_0x41cf18[_0x15294c[_0x1db2ae('0x17e8')]]({'id':_0x15294c['queueCampaign']['id'],'ids':_0x2e3ca0()[_0x1db2ae('0x386')](_0x1a09c4,'id')})['$promise'][_0x1db2ae('0x683')](function(){_0x1efc7b();})[_0x1db2ae('0x130a')](function(_0x2838fa){_0x123dc3(_0x2838fa);});}});}function _0x2561cf(){const _0x41f1cd=_0x26a8d9;_0x15294c['loading']=!![];const _0x328571=_0x2e3ca0()[_0x41f1cd('0x461')](_0x15294c[_0x41f1cd('0x23a7')],_0x15294c[_0x41f1cd('0x1378')],'id'),_0x24ef0a=_0x2e3ca0()[_0x41f1cd('0x461')](_0x15294c[_0x41f1cd('0x1378')],_0x15294c[_0x41f1cd('0x23a7')],'id');return _0x45e0e7(_0x328571)[_0x41f1cd('0x683')](function(){return _0x4aa80b(_0x24ef0a);})['then'](function(){const _0x240dfd=_0x41f1cd;_0x15294c['pendingChanges']=![],_0x15294c['startingAllowedItems']=angular[_0x240dfd('0x1a86')](_0x15294c[_0x240dfd('0x1c47')]),_0x15294c['startingSelectedItems']=angular[_0x240dfd('0x1a86')](_0x15294c[_0x240dfd('0x1378')]),_0x377177[_0x240dfd('0x53')]({'title':'SUCCESS','msg':'Lists\x20association\x20has\x20been\x20updated!'});})[_0x41f1cd('0x130a')](function(_0x5413ff){const _0x36a31f=_0x41f1cd;_0x377177[_0x36a31f('0x52a')]({'title':_0x5413ff[_0x36a31f('0x13ee')]?_0x36a31f('0x2168')+_0x5413ff[_0x36a31f('0x13ee')]+_0x36a31f('0xbf6')+_0x5413ff[_0x36a31f('0x24a9')]:_0x36a31f('0x1b71'),'msg':_0x5413ff[_0x36a31f('0x13ee')]?JSON['stringify'](_0x5413ff[_0x36a31f('0x5a5')]):_0x5413ff[_0x36a31f('0x1ff0')]()});})[_0x41f1cd('0x2874')](function(){const _0x41cbe8=_0x41f1cd;_0x15294c[_0x41cbe8('0x2195')]=![];});}function _0x580fc2(){const _0x43f263=_0x26a8d9;_0x4da145[_0x43f263('0x1715')]();}}const _0x2fb619=_0x4985df;_0x540653['$inject']=[_0x189033('0x7a5'),_0x189033('0x1e48'),'toasty',_0x189033('0x56b'),_0x189033('0x1bd9'),_0x189033('0x1422'),'Sequence','$q'];function _0x540653(_0x40d897,_0x512559,_0x1bbb92,_0x1ab005,_0xf7e7fa,_0x461abc,_0x602546,_0x194d13){const _0x3194f2=_0x189033,_0x27ce78=this;_0x27ce78[_0x3194f2('0x1939')]=[],_0x27ce78['items']=_0x461abc?_0x461abc:[],_0x27ce78[_0x3194f2('0x2195')]=![],_0x27ce78['closeDialog']=_0x3dd7eb,_0x27ce78[_0x3194f2('0x9dd')]=_0x16f43b,_0x27ce78['toggle']=_0x23cccd,_0x27ce78[_0x3194f2('0x4f2')]=_0x2d015e,_0x27ce78['isChecked']=_0x56d93c,_0x27ce78[_0x3194f2('0x2478')]=_0x5d416d,_0x27ce78[_0x3194f2('0x273c')]=_0x3cd3f3;function _0x23cccd(_0x454432,_0x21c24c){const _0x10eeac=_0x3194f2,_0x53b009=_0x21c24c[_0x10eeac('0x824')](_0x454432);_0x53b009>-0x1?_0x21c24c[_0x10eeac('0x2040')](_0x53b009,0x1):_0x21c24c[_0x10eeac('0x1fd0')](_0x454432);}function _0x16f43b(_0x2ca28f,_0xc4fdc2){const _0x4cdaf4=_0x3194f2;return _0xc4fdc2[_0x4cdaf4('0x824')](_0x2ca28f)>-0x1;}function _0x2d015e(){const _0x4e1203=_0x3194f2;return _0x27ce78[_0x4e1203('0x1939')][_0x4e1203('0x1564')]!==0x0&&_0x27ce78['selected'][_0x4e1203('0x1564')]!==_0x27ce78[_0x4e1203('0x1996')][_0x4e1203('0x1564')];}function _0x56d93c(){const _0x44d772=_0x3194f2;return _0x27ce78['selected'][_0x44d772('0x1564')]===_0x27ce78[_0x44d772('0x1996')][_0x44d772('0x1564')];}function _0x5d416d(){const _0x18fbfe=_0x3194f2;if(_0x27ce78[_0x18fbfe('0x1939')][_0x18fbfe('0x1564')]===_0x27ce78[_0x18fbfe('0x1996')][_0x18fbfe('0x1564')])_0x27ce78[_0x18fbfe('0x1939')]=[];else(_0x27ce78[_0x18fbfe('0x1939')][_0x18fbfe('0x1564')]===0x0||_0x27ce78[_0x18fbfe('0x1939')][_0x18fbfe('0x1564')]>0x0)&&(_0x27ce78[_0x18fbfe('0x1939')]=_0x27ce78['items']['slice'](0x0));}function _0x3dd7eb(){const _0x1f2455=_0x3194f2;_0x512559[_0x1f2455('0x1715')]();}function _0x3cd3f3(){const _0x14ffff=_0x3194f2;_0x27ce78[_0x14ffff('0x2195')]=!![];const _0x4afb31=_0x326370();_0x4afb31[_0x14ffff('0x2874')](function(){const _0x4e474d=_0x14ffff;_0x27ce78[_0x4e474d('0x2195')]=![],_0x3dd7eb();});}function _0x326370(){return _0x194d13(function(_0x26933b){const _0x3daeeb=a0_0x4e0a;for(let _0x48f033=0x0;_0x48f033<_0x27ce78[_0x3daeeb('0x1939')][_0x3daeeb('0x1564')];_0x48f033+=0x1){_0x5cd7a5(_0xf7e7fa['id'],_0x27ce78[_0x3daeeb('0x1939')][_0x48f033]);}_0x415554(_0x26933b);});}function _0x5cd7a5(_0x2cd994,_0x583d6c){const _0x4afafa=_0x3194f2,_0x366a89=_0x583d6c['id'];_0x602546[_0x4afafa('0x105a')](function(){const _0x320e79=_0x4afafa;return _0x1ab005['voiceQueue'][_0x320e79('0x8d2')]({'id':_0x2cd994,'ids':_0x366a89})[_0x320e79('0xe53')][_0x320e79('0x683')](function(){const _0xfd5b47=_0x320e79;return _0x1ab005[_0xfd5b47('0x204c')][_0xfd5b47('0x11ef')]({'id':_0x2cd994,'ids':_0x366a89,'dialCheckDuplicateType':_0xfd5b47('0x649')})[_0xfd5b47('0xe53')];})[_0x320e79('0x683')](function(){const _0x31ee3b=_0x320e79;_0x1bbb92['success']({'title':_0x31ee3b('0x191'),'msg':_0x31ee3b('0x1bb2')+_0x583d6c[_0x31ee3b('0x60a')]+_0x31ee3b('0x22e2')});})[_0x320e79('0x130a')](function(_0xbb9fca){const _0x480c47=_0x320e79;_0x1bbb92[_0x480c47('0x52a')]({'title':_0xbb9fca[_0x480c47('0x13ee')]?'API:'+_0xbb9fca[_0x480c47('0x13ee')]+_0x480c47('0xbf6')+_0xbb9fca['statusText']:_0x480c47('0x16c8'),'msg':_0xbb9fca['status']?JSON[_0x480c47('0x258a')](_0xbb9fca[_0x480c47('0x5a5')]):_0xbb9fca['toString']()});});});}function _0x415554(_0x36e124){_0x602546['enqueue'](function(){return _0x36e124();});}}const _0xb3ddc3=_0x540653;_0x4e7dee['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x1bd9'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x4e7dee(_0x32319f,_0x5e8e73,_0x4a582d,_0x232689,_0x5ac633,_0xc13d93,_0x4a6cf2,_0x5234c4){const _0x1b2bbb=_0x189033,_0x1649b5=this;_0x1649b5[_0x1b2bbb('0x11ed')]=_0x4a6cf2[_0x1b2bbb('0x20b2')](),_0x1649b5[_0x1b2bbb('0x1bd9')]=_0x5ac633,_0x1649b5['crudPermissions']=_0x5234c4,_0x1649b5['penalty']=0x0,_0x1649b5['items']=[],_0x1649b5[_0x1b2bbb('0x1c47')]=[],_0x1649b5[_0x1b2bbb('0x1378')]=[],_0x1649b5[_0x1b2bbb('0x125e')]=[],_0x1649b5['startingSelectedItems']=[],_0x1649b5[_0x1b2bbb('0x2106')]=![],_0x1649b5[_0x1b2bbb('0x169f')]={'readOnly':!_0x1649b5['crudPermissions'][_0x1b2bbb('0x1978')],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':_0x1b2bbb('0x60a'),'line1':_0x1b2bbb('0x60a'),'line2':'','line3':'','labelAll':_0xc13d93['instant'](_0x1b2bbb('0x1f2f')),'labelSelected':_0xc13d93[_0x1b2bbb('0x2728')](_0x1b2bbb('0x1099')),'transferCallback':function(_0xeb2976,_0x6288eb){const _0xe920bc=_0x1b2bbb;_0x6288eb?_0xeb2976[_0xe920bc('0x1299')](function(_0x5c9b4f){const _0xd7b46c=_0xe920bc;_0x5c9b4f[_0xd7b46c('0x1e2a')]=undefined;}):_0xeb2976['forEach'](function(_0xb08096){const _0x2c43a8=_0xe920bc;_0xb08096[_0x2c43a8('0x1e2a')]=_0x2c43a8('0x23d0')+_0x1649b5[_0x2c43a8('0x1e2a')];});const _0x165425=_0x2e3ca0()[_0xe920bc('0x25cb')](_0x1649b5[_0xe920bc('0x23a7')],_0x1649b5[_0xe920bc('0x1378')],'id');_0x1649b5[_0xe920bc('0x2106')]=_0x2e3ca0()['isEmpty'](_0x165425)?![]:!![];}},_0x1649b5[_0x1b2bbb('0x1dd2')]=_0x4e8e8a,_0x1649b5['saveTeams']=_0x4ec5cb,_0x1649b5[_0x1b2bbb('0xf82')]=_0x24f59d;function _0x4e8e8a(){const _0x5e2a1e=_0x1b2bbb;return _0x4a6cf2[_0x5e2a1e('0xca1')](_0x5e2a1e('0x20c2'))?_0x387b16()[_0x5e2a1e('0x130a')](function(_0x51653c){const _0x1a2672=_0x5e2a1e;_0x4a582d[_0x1a2672('0x52a')]({'title':_0x51653c[_0x1a2672('0x13ee')]?_0x1a2672('0x2168')+_0x51653c[_0x1a2672('0x13ee')]+'\x20-\x20'+_0x51653c[_0x1a2672('0x24a9')]:_0x1a2672('0x1820'),'msg':_0x51653c[_0x1a2672('0x13ee')]?JSON[_0x1a2672('0x258a')](_0x51653c[_0x1a2672('0x5a5')]):_0x51653c[_0x1a2672('0x1ff0')]()});}):_0x15fe33()[_0x5e2a1e('0x683')](function(_0xb5a69b){const _0x562ed8=_0x5e2a1e;return _0x1649b5[_0x562ed8('0x1aa')]=_0xb5a69b,_0x387b16();})[_0x5e2a1e('0x130a')](function(_0x4b9149){const _0x423435=_0x5e2a1e;_0x4a582d[_0x423435('0x52a')]({'title':_0x4b9149['status']?_0x423435('0x2168')+_0x4b9149[_0x423435('0x13ee')]+_0x423435('0xbf6')+_0x4b9149['statusText']:_0x423435('0x1820'),'msg':_0x4b9149[_0x423435('0x13ee')]?JSON['stringify'](_0x4b9149[_0x423435('0x5a5')]):_0x4b9149[_0x423435('0x1ff0')]()});});}function _0x15fe33(){return _0x5e8e73(function(_0x4f8390,_0xa514bc){const _0x308f52=a0_0x4e0a;_0x232689['userProfileSection'][_0x308f52('0x1e6e')]({'userProfileId':_0x1649b5['currentUser'][_0x308f52('0x2f')],'name':'Teams'})['$promise'][_0x308f52('0x683')](function(_0x31ef06){const _0x442918=_0x308f52,_0x56f592=_0x31ef06&&_0x31ef06[_0x442918('0xf5d')]?_0x31ef06[_0x442918('0xf5d')][0x0]:null;_0x4f8390(_0x56f592);})[_0x308f52('0x130a')](function(_0x252e44){_0xa514bc(_0x252e44);});});}function _0x387b16(){return _0x5e8e73(function(_0x12e14c,_0x8248f){const _0x56c390=a0_0x4e0a;return _0x4a6fcd()[_0x56c390('0x683')](function(_0x14719a){const _0x243a1c=_0x56c390;return _0x1649b5[_0x243a1c('0x1996')]=_0x14719a[_0x243a1c('0xf5d')]?_0x14719a['rows']:[],_0x4a6cf2[_0x243a1c('0xca1')](_0x243a1c('0x20c2'))?_0x14719a:_0x1649b5[_0x243a1c('0x1aa')]?_0x1649b5[_0x243a1c('0x1aa')][_0x243a1c('0x170')]?_0x14719a:_0x32547e():null;})[_0x56c390('0x683')](function(_0x31805f){const _0x3abba7=_0x56c390,_0x838c98=_0x31805f&&_0x31805f[_0x3abba7('0xf5d')]?_0x31805f[_0x3abba7('0xf5d')]:[];return _0x1649b5[_0x3abba7('0x1c47')]=_0x2e3ca0()[_0x3abba7('0x386')](_0x838c98,function(_0x2b7145){const _0x2c9f18=_0x3abba7;return _0x2e3ca0()['find'](_0x1649b5[_0x2c9f18('0x1996')],{'id':_0x4a6cf2['hasRole'](_0x2c9f18('0x20c2'))||_0x1649b5[_0x2c9f18('0x1aa')][_0x2c9f18('0x170')]?_0x2b7145['id']:_0x2b7145[_0x2c9f18('0x832')]});}),_0x1649b5[_0x3abba7('0x1996')]['forEach'](function(_0x193be9){const _0x27d992=_0x3abba7,_0x2505e6=_0x2e3ca0()[_0x27d992('0x1c07')](_0x1649b5[_0x27d992('0x1c47')],{'id':_0x193be9['id']});_0x4a6cf2[_0x27d992('0xca1')](_0x27d992('0x20c2'))?_0x193be9[_0x27d992('0x24f4')]=!![]:_0x193be9[_0x27d992('0x24f4')]=typeof _0x2505e6!==_0x27d992('0x1867')?!![]:![];}),_0x15a149();})['then'](function(_0x17239b){const _0x2ecfec=_0x56c390,_0x100a80=_0x17239b&&_0x17239b['rows']?_0x17239b[_0x2ecfec('0xf5d')]:[];_0x1649b5['selectedItems']=_0x2e3ca0()[_0x2ecfec('0x386')](_0x100a80,function(_0x4cd5e2){return _0x2e3ca0()['find'](_0x1649b5['items'],{'id':_0x4cd5e2['id']});}),_0x1649b5[_0x2ecfec('0x23a7')]=angular[_0x2ecfec('0x1a86')](_0x1649b5['selectedItems']),_0x1649b5[_0x2ecfec('0x169f')][_0x2ecfec('0x1378')]=_0x1649b5[_0x2ecfec('0x1378')],_0x1649b5[_0x2ecfec('0x169f')][_0x2ecfec('0x1996')]=_0x2e3ca0()[_0x2ecfec('0x461')](_0x1649b5[_0x2ecfec('0x1c47')],_0x1649b5[_0x2ecfec('0x169f')][_0x2ecfec('0x1378')],'id'),_0x12e14c();})[_0x56c390('0x130a')](function(_0x3da397){_0x8248f(_0x3da397);});});}function _0x32547e(){return _0x5e8e73(function(_0x57d2f4,_0x4ea2d1){const _0x5ac58d=a0_0x4e0a;return _0x232689[_0x5ac58d('0xcf7')][_0x5ac58d('0x1e6e')]({'sectionId':_0x1649b5[_0x5ac58d('0x1aa')]['id'],'nolimit':!![]})[_0x5ac58d('0xe53')][_0x5ac58d('0x683')](function(_0x4ac3da){_0x57d2f4(_0x4ac3da);})['catch'](function(_0x56ca80){_0x4ea2d1(_0x56ca80);});});}function _0x15a149(){return _0x5e8e73(function(_0x14ce3b,_0x2f9c08){const _0x187e75=a0_0x4e0a;return _0x232689[_0x187e75('0x204c')][_0x187e75('0xf90')]({'id':_0x1649b5[_0x187e75('0x1bd9')]['id'],'fields':_0x187e75('0xa10'),'nolimit':!![]})['$promise'][_0x187e75('0x683')](function(_0x4813a0){_0x14ce3b(_0x4813a0);})[_0x187e75('0x130a')](function(_0x1eb15b){_0x2f9c08(_0x1eb15b);});});}function _0x4a6fcd(){return _0x5e8e73(function(_0x337f89,_0x64e7f4){const _0x42b108=a0_0x4e0a;return _0x232689['team'][_0x42b108('0x1e6e')]({'fields':_0x42b108('0xa10'),'nolimit':!![]})[_0x42b108('0xe53')][_0x42b108('0x683')](function(_0x2ce945){_0x337f89(_0x2ce945);})[_0x42b108('0x130a')](function(_0x370f17){_0x64e7f4(_0x370f17);});});}function _0x2eb326(_0x45986e){return _0x5e8e73(function(_0x204027,_0x35b004){const _0xa42c0c=a0_0x4e0a;if(_0x2e3ca0()[_0xa42c0c('0x173f')](_0x45986e))_0x204027();else{const _0x2358cb=_0x2e3ca0()[_0xa42c0c('0x386')](_0x45986e,function(_0x43b6bc){const _0x1e2a5c=_0xa42c0c;return{'id':_0x43b6bc['id'],'penalty':_0x2e3ca0()[_0x1e2a5c('0x12ae')](_0x43b6bc[_0x1e2a5c('0x1e2a')],_0x1e2a5c('0x23d0'))};});return _0x232689[_0xa42c0c('0x204c')][_0xa42c0c('0x1558')]({'id':_0x1649b5[_0xa42c0c('0x1bd9')]['id'],'teams':_0x2358cb})[_0xa42c0c('0xe53')][_0xa42c0c('0x683')](function(){_0x204027();})[_0xa42c0c('0x130a')](function(_0x3913d5){_0x35b004(_0x3913d5);});}});}function _0x4a2f58(_0x2acab7){return _0x5e8e73(function(_0x15d15f,_0x21f9f9){const _0x19dc77=a0_0x4e0a;_0x2e3ca0()[_0x19dc77('0x173f')](_0x2acab7)?_0x15d15f():_0x232689[_0x19dc77('0x204c')]['removeTeams']({'id':_0x1649b5[_0x19dc77('0x1bd9')]['id'],'ids':_0x2e3ca0()[_0x19dc77('0x386')](_0x2acab7,'id')})[_0x19dc77('0xe53')][_0x19dc77('0x683')](function(){_0x15d15f();})[_0x19dc77('0x130a')](function(_0x3651f){_0x21f9f9(_0x3651f);});});}function _0x4ec5cb(){const _0x1e3490=_0x1b2bbb,_0x1b463d=_0x2e3ca0()['differenceBy'](_0x1649b5[_0x1e3490('0x23a7')],_0x1649b5['selectedItems'],'id'),_0x14ac83=_0x2e3ca0()[_0x1e3490('0x461')](_0x1649b5[_0x1e3490('0x1378')],_0x1649b5[_0x1e3490('0x23a7')],'id');return _0x4a2f58(_0x1b463d)['then'](function(){return _0x2eb326(_0x14ac83);})[_0x1e3490('0x683')](function(){const _0x421bdb=_0x1e3490;_0x1649b5[_0x421bdb('0x2106')]=![],_0x1649b5['startingAllowedItems']=angular[_0x421bdb('0x1a86')](_0x1649b5['allowedItems']),_0x1649b5['startingSelectedItems']=angular[_0x421bdb('0x1a86')](_0x1649b5[_0x421bdb('0x1378')]),_0x4a582d[_0x421bdb('0x53')]({'title':_0x421bdb('0xd28'),'msg':'Teams\x20association\x20has\x20been\x20updated!'});})['catch'](function(_0x3042bf){const _0x40677d=_0x1e3490;_0x4a582d[_0x40677d('0x52a')]({'title':_0x3042bf[_0x40677d('0x13ee')]?'API:'+_0x3042bf[_0x40677d('0x13ee')]+_0x40677d('0xbf6')+_0x3042bf[_0x40677d('0x24a9')]:_0x40677d('0x1b71'),'msg':_0x3042bf[_0x40677d('0x13ee')]?JSON[_0x40677d('0x258a')](_0x3042bf['data']):_0x3042bf[_0x40677d('0x1ff0')]()});});}function _0x24f59d(){const _0x2d63cb=_0x1b2bbb;_0x32319f[_0x2d63cb('0x1715')]();}}const _0x41afb0=_0x4e7dee,_0x4f4192=_0x180212['p']+'src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/clone/clone.html/clone.html',_0x267868=_0x180212['p']+_0x189033('0x23a'),_0x5b02e3=_0x180212['p']+_0x189033('0x3c2'),_0x2dcb14=_0x180212['p']+_0x189033('0x1c41'),_0x5eb39e=_0x180212['p']+'src/js/modules/main/apps/motiondialer/views/queueCampaigns/edit/resetlist/resetlist.html/resetlist.html';_0xb6939f[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),'Auth',_0x189033('0x1bd9'),_0x189033('0x22df')];function _0xb6939f(_0x53b02c,_0x3842e8,_0x5687ca,_0x55dd19,_0xb1329d,_0x25dc6f,_0x186f0a,_0x1fbdab,_0x1262ba,_0x424bcc,_0x26cf32,_0x5778d4){const _0x26c48b=_0x189033,_0x42c16d=this;_0x42c16d['currentUser']=_0x424bcc[_0x26c48b('0x20b2')](),_0x42c16d['license']=_0x25dc6f,_0x42c16d[_0x26c48b('0x260a')]=_0x186f0a,_0x42c16d['passwordPattern']=_0x42c16d[_0x26c48b('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x42c16d[_0x26c48b('0x1224')]=_0x3842e8[_0x26c48b('0x173e')]()+_0x26c48b('0x20de')+_0x3842e8[_0x26c48b('0x19ac')](),_0x42c16d[_0x26c48b('0x1bd9')]=_0x26cf32||_0x53b02c[_0x26c48b('0x7f2')][_0x26c48b('0x1bd9')]||{},_0x42c16d[_0x26c48b('0x22df')]=_0x5778d4&&_0x5778d4[_0x26c48b('0x50d')]==0x1?_0x5778d4[_0x26c48b('0xf5d')][0x0]:null,_0x42c16d[_0x26c48b('0x1134')]=_0x424bcc[_0x26c48b('0x142a')](_0x42c16d['userProfileSection']?_0x42c16d[_0x26c48b('0x22df')][_0x26c48b('0x1134')]:null),_0x42c16d[_0x26c48b('0x258d')]={},_0x42c16d['selectedTab']=_0x53b02c[_0x26c48b('0x7f2')][_0x26c48b('0x1904')]||0x0,_0x42c16d[_0x26c48b('0x163d')]=_0x3e3328,_0x42c16d[_0x26c48b('0x1a50')]=_0x4010f9,_0x42c16d['blacklistadddialog']=_0xddc432,_0x42c16d['teamadddialog']=_0x2070a3,_0x42c16d['agentadddialog']=_0x5d4142,_0x42c16d[_0x26c48b('0x167')]=_0x3317f8,_0x42c16d[_0x26c48b('0x1a9f')]=_0x1a50fd,_0x42c16d[_0x26c48b('0x2430')]=_0x1262ba[_0x26c48b('0x2289')],_0x42c16d[_0x26c48b('0x12ee')]=_0x542ee7,_0x42c16d['saveQueueCampaign']=_0x538f07,_0x424bcc[_0x26c48b('0xca1')]('admin')?_0x1fbdab[_0x26c48b('0x0')][_0x26c48b('0x1e6e')]({'fields':_0x26c48b('0xa10'),'nolimit':_0x26c48b('0x26ac')})['$promise'][_0x26c48b('0x683')](function(_0x3cef3a){const _0x23faf1=_0x26c48b;_0x42c16d['musiconholds']=_0x3cef3a[_0x23faf1('0xf5d')]||[];})['catch'](function(_0x26c2f4){const _0xa80d3e=_0x26c48b;_0x1262ba[_0xa80d3e('0x52a')]({'title':_0x26c2f4[_0xa80d3e('0x13ee')]?'API:'+_0x26c2f4[_0xa80d3e('0x13ee')]+_0xa80d3e('0xbf6')+_0x26c2f4[_0xa80d3e('0x24a9')]:'SYSTEM:GET_MUSICONHOLDS','msg':_0x26c2f4['data']?JSON[_0xa80d3e('0x258a')](_0x26c2f4[_0xa80d3e('0x5a5')]):_0x26c2f4[_0xa80d3e('0x1ff0')]()});}):_0x1fbdab[_0x26c48b('0x0')][_0x26c48b('0x1e6e')]({'fields':_0x26c48b('0xa10'),'nolimit':_0x26c48b('0x26ac')})[_0x26c48b('0xe53')]['then'](function(_0x42fead){const _0x398235=_0x26c48b;_0x42c16d[_0x398235('0xd89')]=_0x42fead[_0x398235('0xf5d')]||[];})['then'](function(){const _0x1b5b00=_0x26c48b;return _0x1fbdab['userProfileSection'][_0x1b5b00('0x1e6e')]({'userProfileId':_0x42c16d[_0x1b5b00('0x11ed')][_0x1b5b00('0x2f')],'sectionId':0x197})['$promise'];})[_0x26c48b('0x683')](function(_0x7e4ebc){const _0x39ad9f=_0x26c48b,_0x1a2c57=_0x7e4ebc&&_0x7e4ebc['rows']?_0x7e4ebc[_0x39ad9f('0xf5d')][0x0]:null;if(!_0x1a2c57)return _0x1fbdab[_0x39ad9f('0x0')][_0x39ad9f('0x1e6e')]({'fields':_0x39ad9f('0xa10'),'nolimit':_0x39ad9f('0x26ac'),'defaultEntry':0x1})[_0x39ad9f('0xe53')][_0x39ad9f('0x683')](function(_0x13b56d){const _0x2bd809=_0x39ad9f;_0x42c16d[_0x2bd809('0xd89')]=_0x13b56d['rows']||[];});else{if(!_0x1a2c57[_0x39ad9f('0x170')])return _0x1fbdab[_0x39ad9f('0xcf7')][_0x39ad9f('0x1e6e')]({'sectionId':_0x1a2c57['id']})[_0x39ad9f('0xe53')][_0x39ad9f('0x683')](function(_0x8814fa){const _0x12e84c=_0x39ad9f,_0x5566d2=_0x2e3ca0()[_0x12e84c('0x386')](_0x8814fa['rows'],function(_0x2d739d){const _0x182e4a=_0x12e84c;return _0x2e3ca0()[_0x182e4a('0x1c07')](_0x42c16d[_0x182e4a('0xd89')],{'id':_0x2d739d[_0x182e4a('0x832')]});});let _0x9e3a3a=null;_0x42c16d[_0x12e84c('0x1bd9')]&&(_0x9e3a3a=_0x2e3ca0()[_0x12e84c('0x1c07')](_0x42c16d[_0x12e84c('0xd89')],{'name':_0x42c16d[_0x12e84c('0x1bd9')][_0x12e84c('0x1ebc')]}));if(_0x9e3a3a&&!_0x2e3ca0()['some'](_0x5566d2,['id',_0x9e3a3a['id']])){const _0x350a45=_0x2e3ca0()[_0x12e84c('0x1c07')](_0x42c16d[_0x12e84c('0xd89')],{'id':_0x9e3a3a['id']});_0x350a45[_0x12e84c('0x319')]=![],_0x5566d2[_0x12e84c('0x1fd0')](_0x350a45);}_0x42c16d[_0x12e84c('0xd89')]=_0x5566d2;});}})['catch'](function(_0xdee075){const _0x35ef00=_0x26c48b;_0x1262ba['error']({'title':_0xdee075['status']?_0x35ef00('0x2168')+_0xdee075[_0x35ef00('0x13ee')]+_0x35ef00('0xbf6')+_0xdee075[_0x35ef00('0x24a9')]:'SYSTEM:GETmusiconholds','msg':_0xdee075['data']?JSON['stringify'](_0xdee075[_0x35ef00('0x5a5')]):_0xdee075[_0x35ef00('0x1ff0')]()});}),_0x424bcc['hasRole'](_0x26c48b('0x20c2'))?_0x1fbdab['trunk']['get']({'fields':_0x26c48b('0xa10'),'sort':_0x26c48b('0x60a')})[_0x26c48b('0xe53')][_0x26c48b('0x683')](function(_0x401682){const _0x57cd22=_0x26c48b;_0x42c16d['trunks']=_0x401682[_0x57cd22('0xf5d')]||[];})[_0x26c48b('0x130a')](function(_0x5f1f97){const _0x34f451=_0x26c48b;_0x1262ba['error']({'title':_0x5f1f97[_0x34f451('0x13ee')]?_0x34f451('0x2168')+_0x5f1f97[_0x34f451('0x13ee')]+'\x20-\x20'+_0x5f1f97[_0x34f451('0x24a9')]:_0x34f451('0xfd0'),'msg':_0x5f1f97[_0x34f451('0x5a5')]?JSON[_0x34f451('0x258a')](_0x5f1f97[_0x34f451('0x5a5')]):_0x5f1f97[_0x34f451('0x1ff0')]()});}):_0x1fbdab[_0x26c48b('0x1a93')]['get']({'fields':_0x26c48b('0xa10'),'sort':_0x26c48b('0x60a')})[_0x26c48b('0xe53')][_0x26c48b('0x683')](function(_0xc7b147){const _0x49a582=_0x26c48b;_0x42c16d[_0x49a582('0x20fe')]=_0xc7b147['rows']||[];})[_0x26c48b('0x683')](function(){const _0x2b1bbe=_0x26c48b;return _0x1fbdab[_0x2b1bbe('0x22df')][_0x2b1bbe('0x1e6e')]({'userProfileId':_0x42c16d[_0x2b1bbe('0x11ed')]['userProfileId'],'sectionId':0x3f3})[_0x2b1bbe('0xe53')];})[_0x26c48b('0x683')](function(_0x43a545){const _0x5e42dd=_0x26c48b,_0x21a42d=_0x43a545&&_0x43a545[_0x5e42dd('0xf5d')]?_0x43a545[_0x5e42dd('0xf5d')][0x0]:null;if(!_0x21a42d){const _0x4a5ed0=[];let _0x52525c=null;_0x42c16d['queueCampaign']&&(_0x52525c=_0x2e3ca0()[_0x5e42dd('0x1c07')](_0x42c16d[_0x5e42dd('0x20fe')],{'id':Number(_0x42c16d['queueCampaign'][_0x5e42dd('0xf10')])}));for(let _0x48de9c=0x0;_0x48de9c<_0x42c16d[_0x5e42dd('0x20fe')][_0x5e42dd('0x1564')];_0x48de9c++){_0x52525c&&_0x42c16d[_0x5e42dd('0x20fe')][_0x48de9c]['id']===_0x52525c['id']&&(_0x42c16d[_0x5e42dd('0x20fe')][_0x48de9c][_0x5e42dd('0x319')]=![],_0x4a5ed0['push'](_0x42c16d['trunks'][_0x48de9c]));}_0x42c16d[_0x5e42dd('0x20fe')]=_0x4a5ed0;}else{if(!_0x21a42d[_0x5e42dd('0x170')])return _0x1fbdab[_0x5e42dd('0xcf7')][_0x5e42dd('0x1e6e')]({'sectionId':_0x21a42d['id']})[_0x5e42dd('0xe53')]['then'](function(_0x4b125e){const _0x20ef80=_0x5e42dd,_0x1af440=_0x2e3ca0()[_0x20ef80('0x386')](_0x4b125e[_0x20ef80('0xf5d')],function(_0x43fe10){const _0xec571d=_0x20ef80;return _0x2e3ca0()[_0xec571d('0x1c07')](_0x42c16d['trunks'],{'id':_0x43fe10[_0xec571d('0x832')]});});let _0x2bf37c=null;_0x42c16d[_0x20ef80('0x1bd9')]&&(_0x2bf37c=_0x2e3ca0()[_0x20ef80('0x1c07')](_0x42c16d[_0x20ef80('0x20fe')],{'id':Number(_0x42c16d[_0x20ef80('0x1bd9')][_0x20ef80('0xf10')])}));if(_0x2bf37c&&!_0x2e3ca0()[_0x20ef80('0x7a2')](_0x1af440,['id',_0x2bf37c['id']])){const _0xb8846=_0x2e3ca0()['find'](_0x42c16d['trunks'],{'id':_0x2bf37c['id']});_0xb8846[_0x20ef80('0x319')]=![],_0x1af440['push'](_0xb8846);}_0x42c16d[_0x20ef80('0x20fe')]=_0x1af440;});}})[_0x26c48b('0x130a')](function(_0x32ad98){const _0x5c7935=_0x26c48b;_0x1262ba[_0x5c7935('0x52a')]({'title':_0x32ad98[_0x5c7935('0x13ee')]?_0x5c7935('0x2168')+_0x32ad98[_0x5c7935('0x13ee')]+_0x5c7935('0xbf6')+_0x32ad98['statusText']:'SYSTEM:GETtrunks','msg':_0x32ad98[_0x5c7935('0x5a5')]?JSON[_0x5c7935('0x258a')](_0x32ad98[_0x5c7935('0x5a5')]):_0x32ad98[_0x5c7935('0x1ff0')]()});}),_0x424bcc[_0x26c48b('0xca1')](_0x26c48b('0x20c2'))?_0x1fbdab[_0x26c48b('0x27ea')][_0x26c48b('0x1e6e')]({'fields':_0x26c48b('0xa10'),'sort':_0x26c48b('0x60a')})[_0x26c48b('0xe53')][_0x26c48b('0x683')](function(_0xa76b95){const _0x35249c=_0x26c48b;_0x42c16d[_0x35249c('0x1248')]=_0xa76b95['rows']||[];})[_0x26c48b('0x130a')](function(_0x18cce9){const _0x1072b2=_0x26c48b;_0x1262ba[_0x1072b2('0x52a')]({'title':_0x18cce9['status']?'API:'+_0x18cce9[_0x1072b2('0x13ee')]+_0x1072b2('0xbf6')+_0x18cce9['statusText']:'SYSTEM:GET_PROJECTS','msg':_0x18cce9[_0x1072b2('0x5a5')]?JSON['stringify'](_0x18cce9[_0x1072b2('0x5a5')]):_0x18cce9[_0x1072b2('0x1ff0')]()});}):_0x1fbdab['squareProject'][_0x26c48b('0x1e6e')]({'fields':_0x26c48b('0xa10'),'sort':'name'})[_0x26c48b('0xe53')][_0x26c48b('0x683')](function(_0x20fb23){const _0x287555=_0x26c48b;_0x42c16d[_0x287555('0x1248')]=_0x20fb23[_0x287555('0xf5d')]||[];})[_0x26c48b('0x683')](function(){const _0x1b3d48=_0x26c48b;return _0x1fbdab[_0x1b3d48('0x22df')]['get']({'userProfileId':_0x42c16d[_0x1b3d48('0x11ed')]['userProfileId'],'sectionId':0x44f})[_0x1b3d48('0xe53')];})[_0x26c48b('0x683')](function(_0x3819e7){const _0x33a20a=_0x26c48b,_0x4f6b47=_0x3819e7&&_0x3819e7['rows']?_0x3819e7[_0x33a20a('0xf5d')][0x0]:null;if(!_0x4f6b47){const _0x3c4910=[];let _0x4d23b0=null;_0x42c16d[_0x33a20a('0x1bd9')]&&(_0x4d23b0=_0x2e3ca0()[_0x33a20a('0x1c07')](_0x42c16d[_0x33a20a('0x1248')],{'name':_0x42c16d[_0x33a20a('0x1bd9')][_0x33a20a('0x1db8')]}));for(let _0x8549a7=0x0;_0x8549a7<_0x42c16d[_0x33a20a('0x1248')][_0x33a20a('0x1564')];_0x8549a7++){_0x4d23b0&&_0x42c16d[_0x33a20a('0x1248')][_0x8549a7]['id']===_0x4d23b0['id']&&(_0x42c16d[_0x33a20a('0x1248')][_0x8549a7][_0x33a20a('0x319')]=![],_0x3c4910['push'](_0x42c16d[_0x33a20a('0x1248')][_0x8549a7]));}_0x42c16d[_0x33a20a('0x1248')]=_0x3c4910;}else{if(!_0x4f6b47['autoAssociation'])return _0x1fbdab[_0x33a20a('0xcf7')][_0x33a20a('0x1e6e')]({'sectionId':_0x4f6b47['id']})[_0x33a20a('0xe53')][_0x33a20a('0x683')](function(_0x701d7){const _0x3685b4=_0x33a20a,_0x25f042=_0x2e3ca0()[_0x3685b4('0x386')](_0x701d7[_0x3685b4('0xf5d')],function(_0x25cab6){const _0x1fe6c3=_0x3685b4;return _0x2e3ca0()[_0x1fe6c3('0x1c07')](_0x42c16d['projects'],{'id':_0x25cab6['resourceId']});});let _0x568fa0=null;_0x42c16d[_0x3685b4('0x1bd9')]&&(_0x568fa0=_0x2e3ca0()[_0x3685b4('0x1c07')](_0x42c16d[_0x3685b4('0x1248')],{'name':_0x42c16d[_0x3685b4('0x1bd9')]['dialQueueProject']}));if(_0x568fa0&&!_0x2e3ca0()[_0x3685b4('0x7a2')](_0x25f042,['id',_0x568fa0['id']])){const _0x174ce5=_0x2e3ca0()[_0x3685b4('0x1c07')](_0x42c16d['projects'],{'id':_0x568fa0['id']});_0x174ce5[_0x3685b4('0x319')]=![],_0x25f042[_0x3685b4('0x1fd0')](_0x174ce5);}_0x42c16d[_0x3685b4('0x1248')]=_0x25f042;});}})['catch'](function(_0x207b99){const _0x556029=_0x26c48b;_0x1262ba['error']({'title':_0x207b99[_0x556029('0x13ee')]?_0x556029('0x2168')+_0x207b99[_0x556029('0x13ee')]+_0x556029('0xbf6')+_0x207b99[_0x556029('0x24a9')]:_0x556029('0x616'),'msg':_0x207b99['data']?JSON[_0x556029('0x258a')](_0x207b99[_0x556029('0x5a5')]):_0x207b99['toString']()});}),_0x424bcc[_0x26c48b('0xca1')](_0x26c48b('0x20c2'))?_0x1fbdab[_0x26c48b('0x115c')][_0x26c48b('0x1e6e')]({'fields':_0x26c48b('0xa10'),'sort':_0x26c48b('0x60a'),'IntervalId':_0x26c48b('0x13c')})[_0x26c48b('0xe53')][_0x26c48b('0x683')](function(_0xe2a750){const _0x1892b8=_0x26c48b;_0x42c16d[_0x1892b8('0x115c')]=_0xe2a750[_0x1892b8('0xf5d')]||[];})[_0x26c48b('0x130a')](function(_0x245864){const _0xf68476=_0x26c48b;_0x1262ba[_0xf68476('0x52a')]({'title':_0x245864[_0xf68476('0x13ee')]?_0xf68476('0x2168')+_0x245864[_0xf68476('0x13ee')]+_0xf68476('0xbf6')+_0x245864[_0xf68476('0x24a9')]:_0xf68476('0x27e3'),'msg':_0x245864[_0xf68476('0x5a5')]?JSON[_0xf68476('0x258a')](_0x245864[_0xf68476('0x5a5')]):_0x245864[_0xf68476('0x1ff0')]()});}):_0x1fbdab[_0x26c48b('0x115c')][_0x26c48b('0x1e6e')]({'fields':_0x26c48b('0xa10'),'sort':_0x26c48b('0x60a'),'IntervalId':_0x26c48b('0x13c')})[_0x26c48b('0xe53')][_0x26c48b('0x683')](function(_0x2c1007){const _0x3e0217=_0x26c48b;_0x42c16d[_0x3e0217('0x115c')]=_0x2c1007['rows']||[];})[_0x26c48b('0x683')](function(){const _0x478171=_0x26c48b;return _0x1fbdab[_0x478171('0x22df')][_0x478171('0x1e6e')]({'userProfileId':_0x42c16d['currentUser']['userProfileId'],'sectionId':0x3ec})[_0x478171('0xe53')];})[_0x26c48b('0x683')](function(_0x159ef1){const _0x4d87c5=_0x26c48b,_0x51eef3=_0x159ef1&&_0x159ef1[_0x4d87c5('0xf5d')]?_0x159ef1['rows'][0x0]:null;if(!_0x51eef3){const _0xbdd9be=[];let _0x45a70d=null;_0x42c16d[_0x4d87c5('0x1bd9')]&&(_0x45a70d=_0x2e3ca0()[_0x4d87c5('0x1c07')](_0x42c16d[_0x4d87c5('0x115c')],{'id':Number(_0x42c16d[_0x4d87c5('0x1bd9')]['IntervalId'])}));for(let _0x1835a2=0x0;_0x1835a2<_0x42c16d[_0x4d87c5('0x115c')][_0x4d87c5('0x1564')];_0x1835a2++){_0x45a70d&&_0x42c16d['interval'][_0x1835a2]['id']===_0x45a70d['id']&&(_0x42c16d['interval'][_0x1835a2][_0x4d87c5('0x319')]=![],_0xbdd9be['push'](_0x42c16d[_0x4d87c5('0x115c')][_0x1835a2]));}_0x42c16d[_0x4d87c5('0x115c')]=_0xbdd9be;}else{if(!_0x51eef3[_0x4d87c5('0x170')])return _0x1fbdab['userProfileResource'][_0x4d87c5('0x1e6e')]({'sectionId':_0x51eef3['id']})[_0x4d87c5('0xe53')][_0x4d87c5('0x683')](function(_0xf706bd){const _0x35d2b0=_0x4d87c5,_0x121a7f=_0x2e3ca0()[_0x35d2b0('0x386')](_0xf706bd['rows'],function(_0x264c9a){const _0x152355=_0x35d2b0;return _0x2e3ca0()['find'](_0x42c16d['interval'],{'id':_0x264c9a[_0x152355('0x832')]});});let _0x43ab3d=null;_0x42c16d[_0x35d2b0('0x1bd9')]&&(_0x43ab3d=_0x2e3ca0()['find'](_0x42c16d[_0x35d2b0('0x115c')],{'id':Number(_0x42c16d[_0x35d2b0('0x1bd9')][_0x35d2b0('0x5ae')])}));if(_0x43ab3d&&!_0x2e3ca0()[_0x35d2b0('0x7a2')](_0x121a7f,['id',_0x43ab3d['id']])){const _0x1ff3d9=_0x2e3ca0()[_0x35d2b0('0x1c07')](_0x42c16d[_0x35d2b0('0x115c')],{'id':_0x43ab3d['id']});_0x1ff3d9[_0x35d2b0('0x319')]=![],_0x121a7f[_0x35d2b0('0x1fd0')](_0x1ff3d9);}_0x42c16d[_0x35d2b0('0x115c')]=_0x121a7f;});}})[_0x26c48b('0x130a')](function(_0x108f0a){const _0x5d1d77=_0x26c48b;_0x1262ba['error']({'title':_0x108f0a[_0x5d1d77('0x13ee')]?_0x5d1d77('0x2168')+_0x108f0a[_0x5d1d77('0x13ee')]+_0x5d1d77('0xbf6')+_0x108f0a[_0x5d1d77('0x24a9')]:_0x5d1d77('0x203'),'msg':_0x108f0a[_0x5d1d77('0x5a5')]?JSON[_0x5d1d77('0x258a')](_0x108f0a[_0x5d1d77('0x5a5')]):_0x108f0a[_0x5d1d77('0x1ff0')]()});}),_0x424bcc[_0x26c48b('0xca1')](_0x26c48b('0x20c2'))?_0x1fbdab[_0x26c48b('0xa4')][_0x26c48b('0x1e6e')]({'fields':_0x26c48b('0x1688'),'sort':'name','nolimit':'true'})['$promise'][_0x26c48b('0x683')](function(_0x137349){const _0x19d8dc=_0x26c48b;_0x42c16d[_0x19d8dc('0x22ab')]=_0x137349[_0x19d8dc('0xf5d')]||[];})['catch'](function(_0x32f318){const _0x65079d=_0x26c48b;_0x1262ba[_0x65079d('0x52a')]({'title':_0x32f318[_0x65079d('0x13ee')]?_0x65079d('0x2168')+_0x32f318[_0x65079d('0x13ee')]+'\x20-\x20'+_0x32f318[_0x65079d('0x24a9')]:_0x65079d('0x4ba'),'msg':_0x32f318[_0x65079d('0x5a5')]?JSON[_0x65079d('0x258a')](_0x32f318[_0x65079d('0x5a5')]):_0x32f318[_0x65079d('0x1ff0')]()});}):_0x1fbdab[_0x26c48b('0xa4')][_0x26c48b('0x1e6e')]({'fields':'name,id','sort':_0x26c48b('0x60a'),'nolimit':'true'})[_0x26c48b('0xe53')][_0x26c48b('0x683')](function(_0x1444b6){_0x42c16d['pauses']=_0x1444b6['rows']||[];})['then'](function(){const _0x2d713b=_0x26c48b;return _0x1fbdab['userProfileSection'][_0x2d713b('0x1e6e')]({'userProfileId':_0x42c16d['currentUser'][_0x2d713b('0x2f')],'sectionId':0x3ed})['$promise'];})[_0x26c48b('0x683')](function(_0x64a36b){const _0x322986=_0x26c48b,_0x133319=_0x64a36b&&_0x64a36b[_0x322986('0xf5d')]?_0x64a36b[_0x322986('0xf5d')][0x0]:null;if(!_0x133319)_0x42c16d[_0x322986('0x22ab')]=[];else{if(!_0x133319[_0x322986('0x170')])return _0x1fbdab[_0x322986('0xcf7')][_0x322986('0x1e6e')]({'sectionId':_0x133319['id']})[_0x322986('0xe53')][_0x322986('0x683')](function(_0x1c096e){const _0x350bb9=_0x322986,_0xb34c97=_0x2e3ca0()[_0x350bb9('0x386')](_0x1c096e[_0x350bb9('0xf5d')],function(_0xa0ddf3){const _0x46aa9f=_0x350bb9;return _0x2e3ca0()[_0x46aa9f('0x1c07')](_0x42c16d[_0x46aa9f('0x22ab')],{'id':_0xa0ddf3['resourceId']});});_0x42c16d[_0x350bb9('0x22ab')]['forEach'](function(_0x5a1a19){const _0x1d9dac=_0x350bb9;!_0x2e3ca0()[_0x1d9dac('0x7a2')](_0xb34c97,['id',_0x5a1a19['id']])&&(_0x5a1a19['canSelect']=![]),_0xb34c97['push'](_0x5a1a19);}),_0x42c16d[_0x350bb9('0x22ab')]=_0xb34c97;});}})['catch'](function(_0x3d0e15){const _0x2ed398=_0x26c48b;_0x1262ba[_0x2ed398('0x52a')]({'title':_0x3d0e15[_0x2ed398('0x13ee')]?_0x2ed398('0x2168')+_0x3d0e15[_0x2ed398('0x13ee')]+_0x2ed398('0xbf6')+_0x3d0e15[_0x2ed398('0x24a9')]:'SYSTEM:GETpauses','msg':_0x3d0e15['data']?JSON[_0x2ed398('0x258a')](_0x3d0e15[_0x2ed398('0x5a5')]):_0x3d0e15[_0x2ed398('0x1ff0')]()});});function _0x3e3328(_0x62a78,_0x3a7267){const _0x2db05a=_0x26c48b;_0x5687ca[_0x2db05a('0x1d4')]({'controller':_0x2db05a('0x2ed'),'controllerAs':'vm','templateUrl':_0x4f4192,'parent':angular[_0x2db05a('0x1fcc')](_0x55dd19['body']),'targetEvent':_0x3a7267,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x62a78,'queueCampaigns':_0x42c16d[_0x2db05a('0x2022')]?_0x42c16d['queueCampaigns']['rows']:[],'crudPermissions':_0x42c16d[_0x2db05a('0x1134')]}});}function _0x4010f9(_0x1a64c4,_0x2c6e8d){const _0x54e5d3=_0x26c48b;_0x5687ca[_0x54e5d3('0x1d4')]({'controller':_0x54e5d3('0x216'),'controllerAs':'vm','templateUrl':_0x267868,'parent':angular['element'](_0x55dd19[_0x54e5d3('0x18e5')]),'targetEvent':_0x2c6e8d,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x1a64c4,'queueCampaigns':_0x42c16d[_0x54e5d3('0x2022')]?_0x42c16d[_0x54e5d3('0x2022')]['rows']:[],'crudPermissions':_0x42c16d[_0x54e5d3('0x1134')]}});}function _0xddc432(_0x4b19e4,_0x184fda){const _0x29f1b1=_0x26c48b;_0x5687ca[_0x29f1b1('0x1d4')]({'controller':_0x29f1b1('0x1a30'),'controllerAs':'vm','templateUrl':_0x5b02e3,'parent':angular[_0x29f1b1('0x1fcc')](_0x55dd19[_0x29f1b1('0x18e5')]),'targetEvent':_0x184fda,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x4b19e4,'queueCampaigns':_0x42c16d[_0x29f1b1('0x2022')]?_0x42c16d[_0x29f1b1('0x2022')][_0x29f1b1('0xf5d')]:[],'crudPermissions':_0x42c16d[_0x29f1b1('0x1134')]}});}function _0x2070a3(_0x2b2815,_0x4baf67){const _0x12fd72=_0x26c48b;_0x5687ca[_0x12fd72('0x1d4')]({'controller':_0x12fd72('0x2834'),'controllerAs':'vm','templateUrl':_0x2dcb14,'parent':angular[_0x12fd72('0x1fcc')](_0x55dd19[_0x12fd72('0x18e5')]),'targetEvent':_0x4baf67,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x2b2815,'queueCampaigns':_0x42c16d[_0x12fd72('0x2022')]?_0x42c16d[_0x12fd72('0x2022')][_0x12fd72('0xf5d')]:[],'crudPermissions':_0x42c16d['crudPermissions']}});}function _0x5d4142(_0x1de6b3,_0x57dc0f){const _0x3aa403=_0x26c48b;_0x5687ca[_0x3aa403('0x1d4')]({'controller':_0x3aa403('0x1283'),'controllerAs':'vm','templateUrl':_0x48dc5f,'parent':angular[_0x3aa403('0x1fcc')](_0x55dd19['body']),'targetEvent':_0x57dc0f,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x1de6b3,'queueCampaigns':_0x42c16d[_0x3aa403('0x2022')]?_0x42c16d[_0x3aa403('0x2022')][_0x3aa403('0xf5d')]:[],'crudPermissions':_0x42c16d[_0x3aa403('0x1134')],'realtime':![]}});}function _0x38560a(_0x3202da,_0xa1766){const _0x189f2b=_0x26c48b,_0x250302=_0xa1766['id'];_0x1fbdab[_0x189f2b('0x204c')][_0x189f2b('0x8d2')]({'id':_0x3202da,'ids':_0x250302})['$promise'][_0x189f2b('0x683')](function(){const _0x22db31=_0x189f2b;return _0x1fbdab[_0x22db31('0x204c')]['addLists']({'id':_0x3202da,'ids':_0x250302,'dialCheckDuplicateType':_0x22db31('0x649')})[_0x22db31('0xe53')];})['then'](function(){const _0x34a99b=_0x189f2b;_0x1262ba[_0x34a99b('0x53')]({'title':'Reset\x20Succesfull','msg':_0x34a99b('0x1bb2')+_0xa1766['name']+_0x34a99b('0x22e2')});})[_0x189f2b('0x130a')](function(_0x2f997d){const _0x4f72a7=_0x189f2b;_0x1262ba['error']({'title':_0x2f997d[_0x4f72a7('0x13ee')]?'API:'+_0x2f997d[_0x4f72a7('0x13ee')]+_0x4f72a7('0xbf6')+_0x2f997d[_0x4f72a7('0x24a9')]:_0x4f72a7('0x11fc'),'msg':_0x2f997d[_0x4f72a7('0x13ee')]?JSON[_0x4f72a7('0x258a')](_0x2f997d['data']):_0x2f997d['toString']()});});}function _0x3317f8(_0x2d5f30,_0x2cd4c1){const _0x1533c4=_0x26c48b;_0x1fbdab[_0x1533c4('0x204c')][_0x1533c4('0x16c3')]({'id':_0x2d5f30['id'],'fields':_0x1533c4('0xa10'),'nolimit':!![]})['$promise'][_0x1533c4('0x683')](function(_0x1e401a){const _0x5db148=_0x1533c4;if(_0x2e3ca0()[_0x5db148('0x8f2')](_0x1e401a[_0x5db148('0xf5d')])||_0x2e3ca0()[_0x5db148('0x173f')](_0x1e401a[_0x5db148('0xf5d')]))_0x1262ba[_0x5db148('0x2289')]({'title':'Campaign\x20Without\x20Lists'});else{if(_0x1e401a[_0x5db148('0xf5d')]['length']===0x1){const _0x1ec25e=_0x5687ca[_0x5db148('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20reset\x20the\x20list\x20'+_0x1e401a[_0x5db148('0xf5d')][0x0][_0x5db148('0x60a')]+'\x20?')['htmlContent'](_0x5db148('0xed5')+_0x1e401a[_0x5db148('0xf5d')][0x0][_0x5db148('0x60a')]+_0x5db148('0x20f1')+_0x5db148('0x181e'))[_0x5db148('0x1040')](_0x5db148('0x2530'))['targetEvent'](_0x2cd4c1)['ok']('OK')['cancel'](_0x5db148('0x16b8'));_0x5687ca[_0x5db148('0x1d4')](_0x1ec25e)[_0x5db148('0x683')](function(){const _0xa7fe42=_0x5db148;_0x38560a(_0x42c16d[_0xa7fe42('0x1bd9')]['id'],_0x1e401a['rows'][0x0]);});}else _0x5687ca['show']({'controller':_0x5db148('0x17b1'),'controllerAs':'vm','templateUrl':_0x5eb39e,'parent':angular[_0x5db148('0x1fcc')](_0x55dd19[_0x5db148('0x18e5')]),'targetEvent':_0x2cd4c1,'clickOutsideToClose':![],'locals':{'queueCampaign':_0x2d5f30,'listsCampaign':_0x1e401a?_0x1e401a['rows']:[]}});}})[_0x1533c4('0x130a')](function(_0x5eb23c){const _0x214a23=_0x1533c4;_0x1262ba[_0x214a23('0x52a')]({'title':_0x5eb23c['status']?_0x214a23('0x2168')+_0x5eb23c[_0x214a23('0x13ee')]+'\x20-\x20'+_0x5eb23c[_0x214a23('0x24a9')]:_0x214a23('0x25b6'),'msg':_0x5eb23c[_0x214a23('0x13ee')]?JSON[_0x214a23('0x258a')](_0x5eb23c[_0x214a23('0x5a5')]):_0x5eb23c[_0x214a23('0x1ff0')]()});});}function _0x1a50fd(){const _0x5ecdcf=_0x26c48b;if(_0x424bcc['hasRole'](_0x5ecdcf('0x20c2')))_0x53b02c['go']('app.motiondialer.realtime.queues',{});else return _0x1fbdab['userProfileSection'][_0x5ecdcf('0x1e6e')]({'userProfileId':_0x424bcc['getCurrentUser']()[_0x5ecdcf('0x2f')],'sectionId':0x5e6})['$promise']['then'](function(_0x50275e){const _0x3cbc24=_0x5ecdcf,_0x32ee51=_0x50275e&&_0x50275e[_0x3cbc24('0xf5d')]?_0x50275e[_0x3cbc24('0xf5d')][0x0]:null;_0x32ee51&&_0x32ee51[_0x3cbc24('0x1333')]?_0x53b02c['go'](_0x3cbc24('0x76c'),{}):_0x1262ba[_0x3cbc24('0x2289')]({'title':_0xb1329d[_0x3cbc24('0x2728')]('STAFF.PERMISSIONS_UNAUTHORIZED_REDIRECT_TITLE'),'msg':_0xb1329d[_0x3cbc24('0x2728')](_0x3cbc24('0xdba'))});})[_0x5ecdcf('0x130a')](function(_0x21e0f2){const _0x509c4f=_0x5ecdcf;_0x1262ba[_0x509c4f('0x52a')]({'title':_0x21e0f2[_0x509c4f('0x13ee')]?_0x509c4f('0x2168')+_0x21e0f2['status']+_0x509c4f('0xbf6')+_0x21e0f2[_0x509c4f('0x24a9')]:_0x509c4f('0xf2a'),'msg':_0x21e0f2['status']?JSON[_0x509c4f('0x258a')](_0x21e0f2[_0x509c4f('0x5a5')]):_0x21e0f2[_0x509c4f('0x1ff0')]()});});}function _0x542ee7(){const _0x4deff6=_0x26c48b;_0x53b02c['go'](_0x4deff6('0x25ae'),{},{'reload':'app.motiondialer.queueCampaigns'});}function _0x538f07(){const _0x131897=_0x26c48b;_0x1fbdab['voiceQueue'][_0x131897('0x2480')]({'id':_0x42c16d[_0x131897('0x1bd9')]['id']},_0x42c16d['queueCampaign'])[_0x131897('0xe53')][_0x131897('0x683')](function(){const _0x3e13c1=_0x131897;_0x1262ba[_0x3e13c1('0x53')]({'title':_0x3e13c1('0x21ed'),'msg':_0x42c16d[_0x3e13c1('0x1bd9')][_0x3e13c1('0x60a')]?_0x42c16d[_0x3e13c1('0x1bd9')][_0x3e13c1('0x60a')]+_0x3e13c1('0x96c'):''});})[_0x131897('0x130a')](function(_0x515a20){const _0x12c924=_0x131897;_0x1262ba[_0x12c924('0x52a')]({'title':_0x515a20[_0x12c924('0x13ee')]?_0x12c924('0x2168')+_0x515a20[_0x12c924('0x13ee')]+_0x12c924('0xbf6')+_0x515a20[_0x12c924('0x24a9')]:_0x12c924('0xa42'),'msg':_0x515a20[_0x12c924('0x5a5')]?JSON[_0x12c924('0x258a')](_0x515a20[_0x12c924('0x5a5')]):_0x515a20[_0x12c924('0x1ff0')]()});});}}const _0x3f56de=_0xb6939f;_0x14b42b[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$window','$state',_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0x2022'),'userProfile',_0x189033('0x22df'),'api',_0x189033('0x1cc2'),_0x189033('0x1d70'),_0x189033('0xba1'),'license',_0x189033('0x260a')];function _0x14b42b(_0x4ea296,_0x2caa71,_0x4b59c9,_0x3adb6b,_0x28101e,_0x296426,_0x1764b5,_0x2e0987,_0xad4ca2,_0x33c94f,_0xf4ecab,_0x49c6f6,_0x272117,_0x13e73d,_0x1ca92f,_0x301015,_0x505947){const _0xedd2e3=_0x189033,_0x245514=this;_0x245514[_0xedd2e3('0xace')]=_0x301015,_0x245514[_0xedd2e3('0x260a')]=_0x505947,_0x245514[_0xedd2e3('0x11ed')]=_0x1ca92f[_0xedd2e3('0x20b2')](),_0x245514[_0xedd2e3('0x2022')]=_0xad4ca2||{'count':0x0,'rows':[]},_0x245514['userProfile']=_0x33c94f,_0x245514[_0xedd2e3('0x22df')]=_0xf4ecab&&_0xf4ecab[_0xedd2e3('0x50d')]==0x1?_0xf4ecab[_0xedd2e3('0xf5d')][0x0]:null,_0x245514[_0xedd2e3('0x1134')]=_0x1ca92f['parseCrudPermissions'](_0x245514[_0xedd2e3('0x22df')]?_0x245514[_0xedd2e3('0x22df')][_0xedd2e3('0x1134')]:null),_0x245514[_0xedd2e3('0x5c4')]=_0xedd2e3('0x2022'),_0x245514['listOrder']='',_0x245514[_0xedd2e3('0x1ce2')]=null,_0x245514[_0xedd2e3('0x17e')]=[],_0x245514['query']={'fields':_0xedd2e3('0x11d8'),'type':_0xedd2e3('0x17cd'),'sort':'-updatedAt','channel':'voice','limit':0xa,'page':0x1},_0x245514['arraydialCheckDuplicateType']=_0x2e3ca0()['keyBy']([{'option':_0xedd2e3('0x126a'),'value':_0xedd2e3('0x6c7')},{'option':_0xedd2e3('0x21c3'),'value':_0xedd2e3('0xd77')},{'option':_0xedd2e3('0x1d12'),'value':_0xedd2e3('0x1c71')}],function(_0x216ebd){const _0x182188=_0xedd2e3;return _0x2e3ca0()[_0x182188('0x1725')](_0x216ebd['value'],new RegExp('\x27','g'),'');}),_0x245514[_0xedd2e3('0x103c')]=_0x2e3ca0()[_0xedd2e3('0x24db')]([{'option':_0xedd2e3('0xe76'),'value':_0xedd2e3('0x13d')},{'option':'No','value':_0xedd2e3('0x23ca')}],function(_0x3b4ac1){const _0x355262=_0xedd2e3;return _0x2e3ca0()['replace'](_0x3b4ac1[_0x355262('0x1c6b')],new RegExp('\x27','g'),'');}),_0x245514[_0xedd2e3('0x223d')]=_0x2e3ca0()['keyBy']([{'option':'Yes','value':_0xedd2e3('0x2036')},{'option':'No','value':_0xedd2e3('0x23ca')}],function(_0x42a503){const _0x476a91=_0xedd2e3;return _0x2e3ca0()['replace'](_0x42a503[_0x476a91('0x1c6b')],new RegExp('\x27','g'),'');}),_0x245514[_0xedd2e3('0x37e')]=_0x2e3ca0()[_0xedd2e3('0x24db')]([{'option':'Yes','value':_0xedd2e3('0x2036')},{'option':'No','value':_0xedd2e3('0x23ca')}],function(_0x510c4e){const _0xba91b9=_0xedd2e3;return _0x2e3ca0()[_0xba91b9('0x1725')](_0x510c4e['value'],new RegExp('\x27','g'),'');}),_0x245514[_0xedd2e3('0x5e2')]=_0x2e3ca0()[_0xedd2e3('0x24db')]([{'option':_0xedd2e3('0x3f9'),'value':'\x27\x27'},{'option':'wav','value':'\x27wav\x27'},{'option':_0xedd2e3('0x178'),'value':_0xedd2e3('0x22cc')},{'option':_0xedd2e3('0x1ac0'),'value':_0xedd2e3('0x1755')}],function(_0x4e3a15){const _0x32c9d6=_0xedd2e3;return _0x2e3ca0()[_0x32c9d6('0x1725')](_0x4e3a15['value'],new RegExp('\x27','g'),'');}),_0x245514[_0xedd2e3('0x532')]=_0x2e3ca0()[_0xedd2e3('0x24db')]([{'option':'Yes','value':_0xedd2e3('0x2036')},{'option':'No','value':_0xedd2e3('0x23ca')}],function(_0xaf74da){const _0x250d7b=_0xedd2e3;return _0x2e3ca0()[_0x250d7b('0x1725')](_0xaf74da[_0x250d7b('0x1c6b')],new RegExp('\x27','g'),'');}),_0x245514[_0xedd2e3('0x1b5a')]=_0x2e3ca0()['keyBy']([{'option':_0xedd2e3('0xe76'),'value':'\x27yes\x27'},{'option':'No','value':'\x27no\x27'}],function(_0x3d6f41){const _0x53e7a2=_0xedd2e3;return _0x2e3ca0()['replace'](_0x3d6f41[_0x53e7a2('0x1c6b')],new RegExp('\x27','g'),'');}),_0x245514[_0xedd2e3('0x20d8')]=_0x2e3ca0()[_0xedd2e3('0x24db')]([{'option':_0xedd2e3('0xe76'),'value':_0xedd2e3('0x2036')},{'option':'No','value':_0xedd2e3('0x23ca')}],function(_0x2d3048){const _0x31e71c=_0xedd2e3;return _0x2e3ca0()[_0x31e71c('0x1725')](_0x2d3048[_0x31e71c('0x1c6b')],new RegExp('\x27','g'),'');}),_0x245514['arraydialOrderByScheduledAt']=_0x2e3ca0()['keyBy']([{'option':_0xedd2e3('0xee8'),'value':'\x27DESC\x27'},{'option':_0xedd2e3('0xa0d'),'value':_0xedd2e3('0x60c')}],function(_0x5016b1){const _0x57096c=_0xedd2e3;return _0x2e3ca0()[_0x57096c('0x1725')](_0x5016b1[_0x57096c('0x1c6b')],new RegExp('\x27','g'),'');}),_0x245514['arraydialMethod']=_0x2e3ca0()[_0xedd2e3('0x24db')]([{'option':'Progressive','value':'\x27progressive\x27'},{'option':_0xedd2e3('0x1404'),'value':_0xedd2e3('0xff3')},{'option':'Predictive','value':_0xedd2e3('0x2838')},{'option':_0xedd2e3('0x4c8'),'value':_0xedd2e3('0xcd7')},{'option':_0xedd2e3('0x658'),'value':'\x27booked\x27'}],function(_0x3d74c0){const _0x58315d=_0xedd2e3;return _0x2e3ca0()[_0x58315d('0x1725')](_0x3d74c0[_0x58315d('0x1c6b')],new RegExp('\x27','g'),'');}),_0x245514['arraydialPredictiveOptimization']=_0x2e3ca0()[_0xedd2e3('0x24db')]([{'option':_0xedd2e3('0xefe'),'value':_0xedd2e3('0x1cef')},{'option':_0xedd2e3('0x4d5'),'value':_0xedd2e3('0x1870')}],function(_0x59bb99){const _0x38955f=_0xedd2e3;return _0x2e3ca0()[_0x38955f('0x1725')](_0x59bb99[_0x38955f('0x1c6b')],new RegExp('\x27','g'),'');}),_0x245514[_0xedd2e3('0x21de')]=_0x2e3ca0()[_0xedd2e3('0x24db')]([{'option':_0xedd2e3('0x141a'),'value':'\x27rrmemory\x27'},{'option':_0xedd2e3('0x2623'),'value':_0xedd2e3('0xa43'),'ngIf':_0xedd2e3('0x470')},{'option':_0xedd2e3('0x2669'),'value':'\x27leastrecent\x27','ngIf':'vm.queueCampaign.dialMethod\x20!==\x20\x27booked\x27'},{'option':_0xedd2e3('0x2257'),'value':_0xedd2e3('0x285b'),'ngIf':_0xedd2e3('0x137f')},{'option':_0xedd2e3('0x1f8d'),'value':_0xedd2e3('0x25f1'),'ngIf':_0xedd2e3('0x137f')},{'option':_0xedd2e3('0x1816'),'value':_0xedd2e3('0x1d6'),'ngIf':_0xedd2e3('0x137f')},{'option':_0xedd2e3('0x7e7'),'value':_0xedd2e3('0x999'),'ngIf':'vm.queueCampaign.dialMethod\x20!==\x20\x27booked\x27'}],function(_0x36eb13){return _0x2e3ca0()['replace'](_0x36eb13['value'],new RegExp('\x27','g'),'');}),_0x245514[_0xedd2e3('0xc63')]=_0x5016bd,_0x245514[_0xedd2e3('0x163d')]=_0xe049d4,_0x245514[_0xedd2e3('0x1a50')]=_0x4d2c33,_0x245514[_0xedd2e3('0x277a')]=_0x23d211,_0x245514[_0xedd2e3('0xe0e')]=_0x1a268e,_0x245514[_0xedd2e3('0x2814')]=_0x5098e9,_0x245514['deleteconfirm']=_0x51cd50,_0x245514[_0xedd2e3('0x213c')]=_0x66246f,_0x245514['success']=_0x533b97,_0x245514['getQueueCampaigns']=_0x32ab3a,_0x245514['createOrEditQueueCampaign']=_0x428e39,_0x245514[_0xedd2e3('0x2053')]=_0x2033c4,_0x245514[_0xedd2e3('0x1f0f')]=_0xb1d574,_0x245514[_0xedd2e3('0x21d9')]=_0x26aac7,_0x245514['deselectQueueCampaigns']=_0x37d962,_0x245514[_0xedd2e3('0xc87')]=_0x33638d,_0x1ca92f[_0xedd2e3('0xca1')]('admin')?_0x49c6f6['trunk'][_0xedd2e3('0x1e6e')]({'fields':_0xedd2e3('0xa10'),'sort':_0xedd2e3('0x60a')})[_0xedd2e3('0xe53')][_0xedd2e3('0x683')](function(_0x51c9de){const _0x2561f7=_0xedd2e3;_0x245514[_0x2561f7('0x20fe')]=_0x51c9de['rows']||[];})[_0xedd2e3('0x130a')](function(_0x2aa1c9){const _0x5172ea=_0xedd2e3;_0x13e73d['error']({'title':_0x2aa1c9[_0x5172ea('0x13ee')]?'API:'+_0x2aa1c9[_0x5172ea('0x13ee')]+_0x5172ea('0xbf6')+_0x2aa1c9[_0x5172ea('0x24a9')]:_0x5172ea('0xfd0'),'msg':_0x2aa1c9[_0x5172ea('0x5a5')]?JSON[_0x5172ea('0x258a')](_0x2aa1c9[_0x5172ea('0x5a5')]):_0x2aa1c9[_0x5172ea('0x1ff0')]()});}):_0x49c6f6[_0xedd2e3('0x1a93')][_0xedd2e3('0x1e6e')]({'fields':'id,name','sort':_0xedd2e3('0x60a')})['$promise']['then'](function(_0x187230){_0x245514['trunks']=_0x187230['rows']||[];})['then'](function(){const _0x258303=_0xedd2e3;return _0x49c6f6['userProfileSection'][_0x258303('0x1e6e')]({'userProfileId':_0x245514['currentUser'][_0x258303('0x2f')],'sectionId':0x3f3})[_0x258303('0xe53')];})[_0xedd2e3('0x683')](function(_0x3a6d5e){const _0x2eca30=_0xedd2e3,_0x524b9b=_0x3a6d5e&&_0x3a6d5e[_0x2eca30('0xf5d')]?_0x3a6d5e[_0x2eca30('0xf5d')][0x0]:null;if(!_0x524b9b){const _0x4624af=[],_0x49e343=[];_0x245514[_0x2eca30('0x2022')][_0x2eca30('0xf5d')][_0x2eca30('0x1299')](function(_0x4a9ae8){const _0x23674f=_0x2eca30,_0x45e17f=_0x2e3ca0()[_0x23674f('0x1c07')](_0x245514[_0x23674f('0x20fe')],{'id':Number(_0x4a9ae8['TrunkId'])});_0x49e343[_0x23674f('0x1fd0')](_0x45e17f);});for(let _0x3471d9=0x0;_0x3471d9<_0x245514['trunks']['length'];_0x3471d9++){const _0x175fbe=_0x2e3ca0()[_0x2eca30('0x7a2')](_0x49e343,{'id':_0x245514[_0x2eca30('0x20fe')][_0x3471d9]['id']});_0x175fbe&&(_0x245514[_0x2eca30('0x20fe')][_0x3471d9]['canSelect']=![],_0x4624af['push'](_0x245514['trunks'][_0x3471d9]));}_0x245514[_0x2eca30('0x20fe')]=_0x4624af;}else{if(!_0x524b9b[_0x2eca30('0x170')])return _0x49c6f6[_0x2eca30('0xcf7')][_0x2eca30('0x1e6e')]({'sectionId':_0x524b9b['id']})[_0x2eca30('0xe53')]['then'](function(_0x2e9b98){const _0x4b23a4=_0x2eca30,_0xa20a2b=_0x2e3ca0()[_0x4b23a4('0x386')](_0x2e9b98['rows'],function(_0x534b48){const _0x5616af=_0x4b23a4;return _0x2e3ca0()[_0x5616af('0x1c07')](_0x245514[_0x5616af('0x20fe')],{'id':_0x534b48[_0x5616af('0x832')]});});let _0x105948=null;_0x105948=[],_0x245514[_0x4b23a4('0x2022')][_0x4b23a4('0xf5d')][_0x4b23a4('0x1299')](function(_0x2de427){const _0x2f7c5f=_0x4b23a4,_0x3e2253=_0x2e3ca0()['find'](_0x245514[_0x2f7c5f('0x20fe')],{'id':Number(_0x2de427['TrunkId'])});_0x105948[_0x2f7c5f('0x1fd0')](_0x3e2253);}),!_0x2e3ca0()['isEmpty'](_0x105948)&&_0x105948[_0x4b23a4('0x1299')](function(_0x494535){const _0x38547a=_0x4b23a4;if(!_0x2e3ca0()[_0x38547a('0x7a2')](_0xa20a2b,['id',_0x494535['id']])){const _0x27f37d=_0x2e3ca0()[_0x38547a('0x1c07')](_0x245514[_0x38547a('0x20fe')],{'id':_0x494535['id']});_0x27f37d[_0x38547a('0x319')]=![],_0xa20a2b[_0x38547a('0x1fd0')](_0x27f37d);}}),_0x245514[_0x4b23a4('0x20fe')]=_0xa20a2b;});}})['catch'](function(_0x252fd4){const _0xf77a92=_0xedd2e3;_0x13e73d['error']({'title':_0x252fd4['status']?_0xf77a92('0x2168')+_0x252fd4[_0xf77a92('0x13ee')]+_0xf77a92('0xbf6')+_0x252fd4['statusText']:_0xf77a92('0x93'),'msg':_0x252fd4['data']?JSON['stringify'](_0x252fd4[_0xf77a92('0x5a5')]):_0x252fd4[_0xf77a92('0x1ff0')]()});}),_0x1ca92f[_0xedd2e3('0xca1')](_0xedd2e3('0x20c2'))?_0x49c6f6['interval'][_0xedd2e3('0x1e6e')]({'fields':_0xedd2e3('0xa10'),'sort':_0xedd2e3('0x60a'),'IntervalId':_0xedd2e3('0x13c')})[_0xedd2e3('0xe53')][_0xedd2e3('0x683')](function(_0x541a2f){const _0x50bf11=_0xedd2e3;_0x245514[_0x50bf11('0x115c')]=_0x541a2f[_0x50bf11('0xf5d')]||[];})[_0xedd2e3('0x130a')](function(_0x1ad635){const _0x2218c4=_0xedd2e3;_0x13e73d[_0x2218c4('0x52a')]({'title':_0x1ad635[_0x2218c4('0x13ee')]?'API:'+_0x1ad635[_0x2218c4('0x13ee')]+_0x2218c4('0xbf6')+_0x1ad635[_0x2218c4('0x24a9')]:_0x2218c4('0x27e3'),'msg':_0x1ad635[_0x2218c4('0x5a5')]?JSON[_0x2218c4('0x258a')](_0x1ad635['data']):_0x1ad635[_0x2218c4('0x1ff0')]()});}):_0x49c6f6[_0xedd2e3('0x115c')][_0xedd2e3('0x1e6e')]({'fields':_0xedd2e3('0xa10'),'sort':_0xedd2e3('0x60a'),'IntervalId':'null'})[_0xedd2e3('0xe53')][_0xedd2e3('0x683')](function(_0x25564e){const _0x14fa6d=_0xedd2e3;_0x245514[_0x14fa6d('0x115c')]=_0x25564e[_0x14fa6d('0xf5d')]||[];})['then'](function(){const _0x5e9325=_0xedd2e3;return _0x49c6f6[_0x5e9325('0x22df')]['get']({'userProfileId':_0x245514[_0x5e9325('0x11ed')][_0x5e9325('0x2f')],'sectionId':0x3ec})[_0x5e9325('0xe53')];})['then'](function(_0x3943fc){const _0x5cd78d=_0xedd2e3,_0x513045=_0x3943fc&&_0x3943fc[_0x5cd78d('0xf5d')]?_0x3943fc['rows'][0x0]:null;if(!_0x513045){const _0x477d4c=[];let _0x3c5762=null;_0x245514[_0x5cd78d('0x1bd9')]&&(_0x3c5762=_0x2e3ca0()[_0x5cd78d('0x1c07')](_0x245514[_0x5cd78d('0x115c')],{'id':Number(_0x245514[_0x5cd78d('0x1bd9')][_0x5cd78d('0x5ae')])}));for(let _0x728970=0x0;_0x728970<_0x245514[_0x5cd78d('0x115c')][_0x5cd78d('0x1564')];_0x728970++){_0x3c5762&&_0x245514[_0x5cd78d('0x115c')][_0x728970]['id']===_0x3c5762['id']&&(_0x245514['interval'][_0x728970]['canSelect']=![],_0x477d4c[_0x5cd78d('0x1fd0')](_0x245514[_0x5cd78d('0x115c')][_0x728970]));}_0x245514[_0x5cd78d('0x115c')]=_0x477d4c;}else{if(!_0x513045[_0x5cd78d('0x170')])return _0x49c6f6['userProfileResource']['get']({'sectionId':_0x513045['id']})[_0x5cd78d('0xe53')]['then'](function(_0x484bc2){const _0x22df3a=_0x5cd78d,_0x59a118=_0x2e3ca0()[_0x22df3a('0x386')](_0x484bc2[_0x22df3a('0xf5d')],function(_0x2a8153){const _0x235058=_0x22df3a;return _0x2e3ca0()[_0x235058('0x1c07')](_0x245514[_0x235058('0x115c')],{'id':_0x2a8153[_0x235058('0x832')]});});let _0x4c0e30=null;_0x245514[_0x22df3a('0x1bd9')]&&(_0x4c0e30=_0x2e3ca0()[_0x22df3a('0x1c07')](_0x245514[_0x22df3a('0x115c')],{'id':Number(_0x245514[_0x22df3a('0x1bd9')][_0x22df3a('0x5ae')])}));if(_0x4c0e30&&!_0x2e3ca0()[_0x22df3a('0x7a2')](_0x59a118,['id',_0x4c0e30['id']])){const _0x47ad98=_0x2e3ca0()[_0x22df3a('0x1c07')](_0x245514[_0x22df3a('0x115c')],{'id':_0x4c0e30['id']});_0x47ad98[_0x22df3a('0x319')]=![],_0x59a118['push'](_0x47ad98);}_0x245514[_0x22df3a('0x115c')]=_0x59a118;});}})[_0xedd2e3('0x130a')](function(_0x346972){const _0x2ca4fa=_0xedd2e3;_0x13e73d['error']({'title':_0x346972['status']?_0x2ca4fa('0x2168')+_0x346972[_0x2ca4fa('0x13ee')]+_0x2ca4fa('0xbf6')+_0x346972[_0x2ca4fa('0x24a9')]:'SYSTEM:GETinterval','msg':_0x346972[_0x2ca4fa('0x5a5')]?JSON['stringify'](_0x346972['data']):_0x346972[_0x2ca4fa('0x1ff0')]()});});function _0x5016bd(_0x17264d){const _0x252585=_0xedd2e3;_0x4b59c9['go'](_0x252585('0x13b9'),{'id':_0x17264d['id'],'queueCampaign':_0x17264d,'crudPermissions':_0x245514[_0x252585('0x1134')]});}function _0xe049d4(_0x5d67b0,_0x4acae0){const _0xc44de9=_0xedd2e3;_0x28101e[_0xc44de9('0x1d4')]({'controller':'QueueCampaigncloneController','controllerAs':'vm','templateUrl':_0x4f4192,'parent':angular[_0xc44de9('0x1fcc')](_0x296426[_0xc44de9('0x18e5')]),'targetEvent':_0x4acae0,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x5d67b0,'queueCampaigns':_0x245514[_0xc44de9('0x2022')]?_0x245514['queueCampaigns']['rows']:[],'crudPermissions':_0x245514[_0xc44de9('0x1134')]}});}function _0x4d2c33(_0xbe353c,_0xc60d0f){const _0x129b1e=_0xedd2e3;_0x28101e['show']({'controller':_0x129b1e('0x216'),'controllerAs':'vm','templateUrl':_0x267868,'parent':angular['element'](_0x296426[_0x129b1e('0x18e5')]),'targetEvent':_0xc60d0f,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0xbe353c,'queueCampaigns':_0x245514['queueCampaigns']?_0x245514[_0x129b1e('0x2022')][_0x129b1e('0xf5d')]:[],'crudPermissions':_0x245514[_0x129b1e('0x1134')]}});}function _0x23d211(_0x20734b,_0x508238){const _0x43b801=_0xedd2e3;_0x28101e['show']({'controller':'QueueCampaignblacklistaddController','controllerAs':'vm','templateUrl':_0x5b02e3,'parent':angular[_0x43b801('0x1fcc')](_0x296426[_0x43b801('0x18e5')]),'targetEvent':_0x508238,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x20734b,'queueCampaigns':_0x245514['queueCampaigns']?_0x245514[_0x43b801('0x2022')]['rows']:[],'crudPermissions':_0x245514[_0x43b801('0x1134')]}});}function _0x1a268e(_0x36f26f,_0x2d7fb7){const _0x3705d5=_0xedd2e3;_0x28101e[_0x3705d5('0x1d4')]({'controller':_0x3705d5('0x2834'),'controllerAs':'vm','templateUrl':_0x2dcb14,'parent':angular[_0x3705d5('0x1fcc')](_0x296426['body']),'targetEvent':_0x2d7fb7,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x36f26f,'queueCampaigns':_0x245514[_0x3705d5('0x2022')]?_0x245514[_0x3705d5('0x2022')][_0x3705d5('0xf5d')]:[],'crudPermissions':_0x245514[_0x3705d5('0x1134')]}});}function _0x5098e9(_0x1f846c,_0x4c7ac1){const _0x5e1d19=_0xedd2e3;_0x28101e[_0x5e1d19('0x1d4')]({'controller':_0x5e1d19('0x1283'),'controllerAs':'vm','templateUrl':_0x48dc5f,'parent':angular['element'](_0x296426[_0x5e1d19('0x18e5')]),'targetEvent':_0x4c7ac1,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x1f846c,'queueCampaigns':_0x245514['queueCampaigns']?_0x245514[_0x5e1d19('0x2022')][_0x5e1d19('0xf5d')]:[],'crudPermissions':_0x245514[_0x5e1d19('0x1134')],'realtime':![]}});}function _0x51cd50(_0x5305bb,_0xc47565){const _0x392e6e=_0xedd2e3,_0x39d177=_0x28101e['confirm']()[_0x392e6e('0xf28')](_0x392e6e('0x1b01')+_0x2e3ca0()[_0x392e6e('0x1e03')](_0x392e6e('0x1bd9'))+'?')['htmlContent'](_0x392e6e('0xed5')+(_0x5305bb[_0x392e6e('0x60a')]||_0x392e6e('0x1bd9'))+_0x392e6e('0x20f1')+_0x392e6e('0x1ee7'))[_0x392e6e('0x1040')](_0x392e6e('0x1708'))[_0x392e6e('0xe42')](_0xc47565)['ok']('OK')[_0x392e6e('0x19fb')](_0x392e6e('0x16b8'));_0x28101e[_0x392e6e('0x1d4')](_0x39d177)['then'](function(){_0x2033c4(_0x5305bb);},function(){const _0x1898db=_0x392e6e;console[_0x1898db('0x1b2b')]('CANCEL');});}function _0x66246f(){const _0x281b59=_0xedd2e3;if(_0x1ca92f[_0x281b59('0xca1')](_0x281b59('0x20c2')))_0x4b59c9['go'](_0x281b59('0x76c'),{});else return _0x49c6f6[_0x281b59('0x22df')]['get']({'userProfileId':_0x1ca92f[_0x281b59('0x20b2')]()[_0x281b59('0x2f')],'sectionId':0x5e6})[_0x281b59('0xe53')][_0x281b59('0x683')](function(_0x10ef81){const _0x4b2141=_0x281b59,_0x498f52=_0x10ef81&&_0x10ef81[_0x4b2141('0xf5d')]?_0x10ef81[_0x4b2141('0xf5d')][0x0]:null;_0x498f52&&_0x498f52[_0x4b2141('0x1333')]?_0x4b59c9['go'](_0x4b2141('0x76c'),{}):_0x13e73d[_0x4b2141('0x2289')]({'title':_0x2e0987[_0x4b2141('0x2728')](_0x4b2141('0x213e')),'msg':_0x2e0987[_0x4b2141('0x2728')](_0x4b2141('0xdba'))});})[_0x281b59('0x130a')](function(_0x172bf9){const _0x3c3746=_0x281b59;_0x13e73d['error']({'title':_0x172bf9[_0x3c3746('0x13ee')]?_0x3c3746('0x2168')+_0x172bf9[_0x3c3746('0x13ee')]+'\x20-\x20'+_0x172bf9[_0x3c3746('0x24a9')]:_0x3c3746('0xf2a'),'msg':_0x172bf9[_0x3c3746('0x13ee')]?JSON[_0x3c3746('0x258a')](_0x172bf9[_0x3c3746('0x5a5')]):_0x172bf9[_0x3c3746('0x1ff0')]()});});}let _0x5998b7=!![],_0x5e7491=0x1;_0x4ea296['$watch'](_0xedd2e3('0x1e1d'),function(_0x112a80,_0xbc81b4){const _0x34c323=_0xedd2e3;_0x5998b7?_0x1764b5(function(){_0x5998b7=![];}):(!_0xbc81b4&&(_0x5e7491=_0x245514[_0x34c323('0x23a2')][_0x34c323('0xdf8')]),_0x112a80!==_0xbc81b4&&(_0x245514['query']['page']=0x1),!_0x112a80&&(_0x245514[_0x34c323('0x23a2')][_0x34c323('0xdf8')]=_0x5e7491),_0x245514[_0x34c323('0x21b5')]());});function _0x533b97(_0x5838a0){const _0x53043c=_0xedd2e3;_0x245514[_0x53043c('0x2022')]=_0x5838a0||{'count':0x0,'rows':[]};}function _0x32ab3a(){const _0x50bf57=_0xedd2e3;_0x245514[_0x50bf57('0x23a2')]['offset']=(_0x245514[_0x50bf57('0x23a2')][_0x50bf57('0xdf8')]-0x1)*_0x245514['query'][_0x50bf57('0x6f0')],_0x1ca92f[_0x50bf57('0xca1')](_0x50bf57('0x20c2'))?_0x245514[_0x50bf57('0x1883')]=_0x49c6f6['voiceQueue'][_0x50bf57('0x1e6e')](_0x245514['query'],_0x533b97)[_0x50bf57('0xe53')]:(_0x245514[_0x50bf57('0x23a2')]['id']=_0x245514[_0x50bf57('0x2a')]['id'],_0x245514['query'][_0x50bf57('0x1aa')]='QueueCampaigns',_0x245514[_0x50bf57('0x1883')]=_0x49c6f6['userProfile']['getResources'](_0x245514[_0x50bf57('0x23a2')],_0x533b97)[_0x50bf57('0xe53')]);}function _0x428e39(_0x24b482,_0x341433){const _0x1710ed=_0xedd2e3;_0x28101e[_0x1710ed('0x1d4')]({'controller':_0x1710ed('0x15a3'),'controllerAs':'vm','templateUrl':_0x340822,'parent':angular[_0x1710ed('0x1fcc')](_0x296426[_0x1710ed('0x18e5')]),'targetEvent':_0x24b482,'clickOutsideToClose':!![],'locals':{'queueCampaign':_0x341433,'queueCampaigns':_0x245514[_0x1710ed('0x2022')][_0x1710ed('0xf5d')],'license':_0x245514['license'],'setting':_0x245514['setting'],'crudPermissions':_0x245514['crudPermissions']}});}function _0x2033c4(_0x6ec561){const _0x186fdf=_0xedd2e3;_0x49c6f6[_0x186fdf('0x204c')][_0x186fdf('0xd7e')]({'id':_0x6ec561['id']})[_0x186fdf('0xe53')][_0x186fdf('0x683')](function(){const _0x111a2d=_0x186fdf;_0x2e3ca0()['remove'](_0x245514['queueCampaigns'][_0x111a2d('0xf5d')],{'id':_0x6ec561['id']}),_0x245514['queueCampaigns'][_0x111a2d('0x50d')]-=0x1,!_0x245514[_0x111a2d('0x2022')][_0x111a2d('0xf5d')][_0x111a2d('0x1564')]&&_0x245514['getQueueCampaigns'](),_0x13e73d[_0x111a2d('0x53')]({'title':_0x2e3ca0()['startCase'](_0x111a2d('0x1323'))+_0x111a2d('0xbfc'),'msg':_0x6ec561[_0x111a2d('0x60a')]?_0x6ec561[_0x111a2d('0x60a')]+_0x111a2d('0x194d'):''});})[_0x186fdf('0x130a')](function(_0x458d5d){const _0x1455a3=_0x186fdf;if(_0x458d5d['data']&&_0x458d5d[_0x1455a3('0x5a5')]['errors']&&_0x458d5d[_0x1455a3('0x5a5')][_0x1455a3('0x17f')]['length']){_0x245514[_0x1455a3('0x17f')]=_0x458d5d[_0x1455a3('0x5a5')][_0x1455a3('0x17f')]||[{'message':_0x458d5d[_0x1455a3('0x1ff0')](),'type':'SYSTEM:DELETEvoiceQueue'}];for(let _0x480629=0x0;_0x480629<_0x458d5d[_0x1455a3('0x5a5')][_0x1455a3('0x17f')][_0x1455a3('0x1564')];_0x480629++){_0x13e73d[_0x1455a3('0x52a')]({'title':_0x458d5d[_0x1455a3('0x5a5')][_0x1455a3('0x17f')][_0x480629][_0x1455a3('0xcf0')],'msg':_0x458d5d[_0x1455a3('0x5a5')][_0x1455a3('0x17f')][_0x480629][_0x1455a3('0x8c2')]});}}else _0x13e73d[_0x1455a3('0x52a')]({'title':_0x458d5d[_0x1455a3('0x13ee')]?'API:'+_0x458d5d[_0x1455a3('0x13ee')]+_0x1455a3('0xbf6')+_0x458d5d['statusText']:_0x1455a3('0x1674'),'msg':_0x458d5d['data']?JSON[_0x1455a3('0x258a')](_0x458d5d[_0x1455a3('0x5a5')][_0x1455a3('0x8c2')]):_0x458d5d[_0x1455a3('0x8c2')]||_0x458d5d[_0x1455a3('0x1ff0')]()});});}function _0xb1d574(){const _0x30660e=angular['copy'](_0x245514['selectedQueueCampaigns']);return _0x245514['selectedQueueCampaigns']=[],_0x30660e;}function _0x26aac7(_0x1255c2){const _0x390062=_0xedd2e3,_0x2351b0=_0x28101e['confirm']()[_0x390062('0xf28')](_0x390062('0x1a0d'))['htmlContent'](_0x390062('0xed5')+_0x245514['selectedQueueCampaigns'][_0x390062('0x1564')]+'\x20selected'+'\x20will\x20be\x20deleted.')['ariaLabel'](_0x390062('0x2207'))[_0x390062('0xe42')](_0x1255c2)['ok']('OK')['cancel'](_0x390062('0x16b8'));_0x28101e[_0x390062('0x1d4')](_0x2351b0)[_0x390062('0x683')](function(){const _0xed7a5a=_0x390062;_0x245514[_0xed7a5a('0x17e')][_0xed7a5a('0x1299')](function(_0x4c02be){_0x2033c4(_0x4c02be);}),_0x245514[_0xed7a5a('0x17e')]=[];});}function _0x37d962(){const _0x261c49=_0xedd2e3;_0x245514[_0x261c49('0x17e')]=[];}function _0x33638d(){const _0x305721=_0xedd2e3;_0x245514[_0x305721('0x17e')]=_0x245514[_0x305721('0x2022')]['rows'];}}const _0x1d3bf6=_0x14b42b;_0x4c27e8[_0x189033('0x14be')]=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x4c27e8(_0x4c53a4,_0x2b3e2b){const _0x501a65=_0x189033;_0x4c53a4['state'](_0x501a65('0x134d'),{'abstract':!![],'url':_0x501a65('0x268b')})[_0x501a65('0x2598')](_0x501a65('0x25ae'),{'url':_0x501a65('0xdd8'),'views':{'content@app':{'templateUrl':_0x53ea58,'controller':_0x501a65('0x2134')}},'resolve':{'queueCampaigns':[_0x501a65('0x4b1'),_0x501a65('0xba1'),function(_0x3b8514,_0x2d1ffa){const _0x2c009b=_0x501a65;return _0x2d1ffa[_0x2c009b('0xca1')](_0x2c009b('0x20c2'))?_0x3b8514['resolve'](_0x2c009b('0x2730'),{'fields':_0x2c009b('0x11d8'),'type':_0x2c009b('0x17cd'),'sort':'-updatedAt','channel':_0x2c009b('0xcf2'),'limit':0xa,'offset':0x0}):_0x3b8514[_0x2c009b('0xed7')]('userProfile@getResources',{'id':_0x2d1ffa[_0x2c009b('0x20b2')]()[_0x2c009b('0x2f')],'section':'QueueCampaigns','fields':_0x2c009b('0x11d8'),'type':_0x2c009b('0x17cd'),'sort':_0x2c009b('0xc36'),'channel':'voice','limit':0xa,'offset':0x0});}],'userProfile':[_0x501a65('0x4b1'),'Auth',function(_0x1b62d8,_0x386e09){const _0xb66706=_0x501a65;return _0x386e09[_0xb66706('0xca1')](_0xb66706('0x20c2'))?null:_0x1b62d8['resolve'](_0xb66706('0x1464'),{'fields':_0xb66706('0x16f'),'id':_0x386e09[_0xb66706('0x20b2')]()[_0xb66706('0x2f')]});}],'userProfileSection':[_0x501a65('0x4b1'),_0x501a65('0xba1'),function(_0x4de5fe,_0x2dfb7f){const _0x328b07=_0x501a65;return _0x2dfb7f[_0x328b07('0xca1')](_0x328b07('0x20c2'))?null:_0x4de5fe['resolve']('userProfileSection@get',{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x2dfb7f[_0x328b07('0x20b2')]()[_0x328b07('0x2f')],'sectionId':0x5dd});}]},'authenticate':!![],'permissionId':0x5dd,'bodyClass':_0x501a65('0x1cd4')})[_0x501a65('0x2598')](_0x501a65('0x13b9'),{'url':_0x501a65('0x1560'),'params':{'queueCampaign':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x2fc384,'controller':_0x501a65('0x1570')}},'resolve':{'queueCampaign':[_0x501a65('0x4b1'),_0x501a65('0x8ea'),function(_0x522d92,_0x482683){const _0x592d55=_0x501a65;return _0x522d92['resolve'](_0x592d55('0x2730'),{'fields':_0x592d55('0x11d8'),'id':_0x482683['id']});}],'userProfileSection':[_0x501a65('0x4b1'),'Auth',function(_0x1d454c,_0x45d520){const _0x88880f=_0x501a65;return _0x1d454c[_0x88880f('0xed7')](_0x88880f('0x360'),{'fields':_0x88880f('0x1f47'),'userProfileId':_0x45d520['getCurrentUser']()[_0x88880f('0x2f')],'sectionId':0x5dd});}]},'authenticate':!![],'permissionId':0x5dd,'bodyClass':_0x501a65('0x1cd4')})['state'](_0x501a65('0xb4c'),{'url':_0x501a65('0x207f'),'views':{'content@app':{'templateUrl':_0xd59b02,'controller':_0x501a65('0x170f')}},'resolve':{'ivrCampaigns':[_0x501a65('0x4b1'),_0x501a65('0xba1'),function(_0x3ac01e,_0x31acb7){const _0x2a6139=_0x501a65;return _0x31acb7[_0x2a6139('0xca1')]('admin')?_0x3ac01e[_0x2a6139('0xed7')]('campaign@get',{'fields':_0x2a6139('0x1c6a'),'type':_0x2a6139('0x715'),'sort':_0x2a6139('0xc36'),'limit':0xa,'offset':0x0}):_0x3ac01e['resolve'](_0x2a6139('0x191b'),{'id':_0x31acb7[_0x2a6139('0x20b2')]()['userProfileId'],'section':_0x2a6139('0x23db'),'fields':'createdAt,updatedAt,id,name,active,TrunkId,TrunkBackupId,type,IntervalId,dialCheckDuplicateType,dialCutDigit,SquareProjectId,limitCalls,description,dialOriginateCallerIdName,dialOriginateCallerIdNumber,dialRandomLastDigitCallerIdNumber,dialOriginateTimeout,dialGlobalMaxRetry,dialCongestionMaxRetry,dialCongestionRetryFrequency,dialBusyMaxRetry,dialBusyRetryFrequency,dialNoAnswerMaxRetry,dialNoAnswerRetryFrequency,dialNoSuchNumberMaxRetry,dialNoSuchNumberRetryFrequency,dialDropMaxRetry,dialDropRetryFrequency,dialAbandonedMaxRetry,dialAbandonedRetryFrequency,dialMachineMaxRetry,dialMachineRetryFrequency,dialAgentRejectMaxRetry,dialAgentRejectRetryFrequency,dialOrderByScheduledAt,dialGlobalInterval,dialTimezone,dialPrefix,dialAMDActive,dialAMDInitialSilence,dialAMDGreeting,dialAMDAfterGreetingSilence,dialAMDTotalAnalysisTime,dialAMDMinWordLength,dialAMDBetweenWordsSilence,dialAMDMaximumNumberOfWords,dialAMDSilenceThreshold,dialAMDMaximumWordLength','type':'ivr','sort':_0x2a6139('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x501a65('0x4b1'),_0x501a65('0xba1'),function(_0x41343e,_0x42295e){const _0x2130a1=_0x501a65;return _0x42295e[_0x2130a1('0xca1')](_0x2130a1('0x20c2'))?null:_0x41343e[_0x2130a1('0xed7')](_0x2130a1('0x1464'),{'fields':_0x2130a1('0x16f'),'id':_0x42295e[_0x2130a1('0x20b2')]()['userProfileId']});}],'userProfileSection':['apiResolver',_0x501a65('0xba1'),function(_0x134893,_0x13cb4b){const _0x3d2d1a=_0x501a65;return _0x13cb4b[_0x3d2d1a('0xca1')](_0x3d2d1a('0x20c2'))?null:_0x134893[_0x3d2d1a('0xed7')](_0x3d2d1a('0x360'),{'fields':_0x3d2d1a('0x1f47'),'userProfileId':_0x13cb4b[_0x3d2d1a('0x20b2')]()[_0x3d2d1a('0x2f')],'sectionId':0x5de});}]},'authenticate':!![],'permissionId':0x5de,'bodyClass':_0x501a65('0x1cd4')})['state'](_0x501a65('0x269'),{'url':'/:id?tab','params':{'ivrCampaign':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x72e765,'controller':_0x501a65('0x1e88')}},'resolve':{'ivrCampaign':[_0x501a65('0x4b1'),_0x501a65('0x8ea'),function(_0x24b385,_0x372d8f){const _0x1db0bd=_0x501a65;return _0x24b385['resolve'](_0x1db0bd('0x1c32'),{'fields':_0x1db0bd('0x1c6a'),'id':_0x372d8f['id']});}],'userProfileSection':['apiResolver',_0x501a65('0xba1'),function(_0x4b93da,_0x127af2){const _0x51c144=_0x501a65;return _0x4b93da['resolve'](_0x51c144('0x360'),{'fields':_0x51c144('0x1f47'),'userProfileId':_0x127af2[_0x51c144('0x20b2')]()[_0x51c144('0x2f')],'sectionId':0x5de});}]},'authenticate':!![],'permissionId':0x5de,'bodyClass':_0x501a65('0x1cd4')}),_0x2b3e2b[_0x501a65('0x7d2')]('app/main/apps/motiondialer');}angular[_0x189033('0x1e26')](_0x189033('0x134d'),[_0x189033('0x6cf'),'ngPassword','md.data.table',_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),_0x189033('0x2609'),'ngAnimate',_0x189033('0x76'),_0x189033('0x516'),'mwFormViewer',_0x189033('0x197b'),_0x189033('0x3b5'),_0x189033('0x153a'),_0x189033('0x1447'),_0x189033('0x2645'),'material.components.expansionPanels',_0x189033('0x1566'),_0x189033('0x19da'),_0x189033('0xd4b')])[_0x189033('0x272d')](_0x4c27e8)[_0x189033('0x1da3')](_0x189033('0x10cc'),_0x206842)[_0x189033('0x1da3')](_0x189033('0x1234'),_0x1875bd)[_0x189033('0x1da3')](_0x189033('0x25c4'),_0x355c8c)['controller']('IvrCampaignHopperBlacksController',_0x57abff)[_0x189033('0x1da3')](_0x189033('0x184d'),_0x261006)[_0x189033('0x1da3')](_0x189033('0x501'),_0x3f776a)[_0x189033('0x1da3')](_0x189033('0x2206'),_0xbd5181)[_0x189033('0x1da3')](_0x189033('0x1b1f'),_0xe66866)['controller'](_0x189033('0x14f1'),_0x4db171)[_0x189033('0x1da3')](_0x189033('0x34b'),_0x29c663)[_0x189033('0x1da3')]('IvrCampaignresetlistController',_0x38647b)[_0x189033('0x1da3')]('IvrCampaignController',_0x5b92ff)['controller']('IvrCampaignsController',_0x53d3ad)['controller'](_0x189033('0x15a3'),_0x5ed28e)[_0x189033('0x1da3')](_0x189033('0x1283'),_0xfc42c3)['controller'](_0x189033('0x1a30'),_0x2e79fd)[_0x189033('0x1da3')](_0x189033('0x2ed'),_0x25fb61)['controller']('QueueCampaignHopperBlacksController',_0x22acb6)['controller'](_0x189033('0x1ba0'),_0x5eef85)[_0x189033('0x1da3')](_0x189033('0x11db'),_0x5b2fab)[_0x189033('0x1da3')]('QueueCampaignHoppersController',_0x26e6af)[_0x189033('0x1da3')](_0x189033('0x17f9'),_0x430314)[_0x189033('0x1da3')](_0x189033('0x309'),_0x258f7e)['controller'](_0x189033('0x216'),_0x2fb619)[_0x189033('0x1da3')](_0x189033('0x17b1'),_0xb3ddc3)[_0x189033('0x1da3')](_0x189033('0x2834'),_0x41afb0)[_0x189033('0x1da3')](_0x189033('0x243a'),_0x3f56de)[_0x189033('0x1da3')](_0x189033('0x1326'),_0x1d3bf6);const _0x8f8a6f=_0x180212['p']+_0x189033('0x1c83');_0x568203[_0x189033('0x14be')]=[_0x189033('0x2289'),_0x189033('0xace'),_0x189033('0x56b')];function _0x5e52e8(_0x192dc3){const _0x4b9eb0=_0x189033,_0x11ea3d=_0x1aaf93()(_0x192dc3);return _0x11ea3d['isValid']()?_0x11ea3d['format'](_0x4b9eb0('0x164b')):'';}function _0x568203(_0x4749a2,_0x344b1e,_0x100ab3){const _0xd4c9da=_0x189033,_0x545cc3=this;_0x545cc3[_0xd4c9da('0x2713')]=_0x100ab3[_0xd4c9da('0x2713')],_0x545cc3[_0xd4c9da('0x2289')]={..._0x4749a2,'buildDate':_0x5e52e8(_0x4749a2['buildDate']),'commitDate':_0x5e52e8(_0x4749a2[_0xd4c9da('0x1794')]),'client':{'name':_0xd4c9da('0x18a4'),'version':_0xd4c9da('0x876'),'shortHash':_0xd4c9da('0xe26'),'branch':_0xd4c9da('0x275d'),'tag':'','committedOn':'2020-11-12T18:54:25.000Z','buildDate':_0xd4c9da('0x2771')}},_0x545cc3[_0xd4c9da('0xace')]=_0x344b1e;}const _0x1da67d=_0x568203;_0x2f345c['$inject']=[_0x189033('0x1398')];function _0x2f345c(_0x15f83a){const _0xee4281=_0x189033;_0x15f83a[_0xee4281('0x2598')](_0xee4281('0x1580'),{'url':_0xee4281('0xbaf'),'views':{'content@app':{'templateUrl':_0x8f8a6f,'controller':_0xee4281('0x1945')}},'resolve':{'info':[_0xee4281('0x4b1'),function(_0x458af0){const _0xef424f=_0xee4281;return _0x458af0[_0xef424f('0xed7')](_0xef424f('0x6f4'));}]},'authenticate':!![],'permissionId':0x640,'bodyClass':'help'});}angular[_0x189033('0x1e26')](_0x189033('0x1580'),[])[_0x189033('0x272d')](_0x2f345c)[_0x189033('0x1da3')](_0x189033('0x833'),_0x1da67d),_0x4bfacd[_0x189033('0x14be')]=['$stateProvider',_0x189033('0x19ee')];function _0x4bfacd(_0x1cdb76,_0x404a26){const _0x4570bb=_0x189033;_0x1cdb76[_0x4570bb('0x2598')](_0x4570bb('0x2313'),{'abstract':!![],'url':_0x4570bb('0x220f')}),_0x404a26[_0x4570bb('0x7d2')](_0x4570bb('0x1430'));}angular[_0x189033('0x1e26')](_0x189033('0x2313'),[_0x189033('0x6cf'),'ngPassword',_0x189033('0x2290'),_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),'ngAria',_0x189033('0x273d'),'mdPickers',_0x189033('0x516'),'mwFormViewer',_0x189033('0x197b'),_0x189033('0x3b5'),_0x189033('0x153a'),_0x189033('0x1447'),_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da'),_0x189033('0x1580')])['config'](_0x4bfacd);const _0x320f46=_0x180212['p']+_0x189033('0x1ba8'),_0x3c9b80=_0x180212['p']+_0x189033('0x241');_0x1c8159['$inject']=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),'$mdDialog','$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x1248'),_0x189033('0x273a'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x1c8159(_0x5d6d24,_0x376ce1,_0x251ca4,_0x2de13a,_0x370028,_0x191d6a,_0x3a9c1f,_0x31659e,_0x41e10d,_0x3b193d,_0x5d7e03,_0x5f01ac,_0x2fb449,_0xec7ae5){const _0x17e308=_0x189033,_0x9e1a6a=this;_0x9e1a6a[_0x17e308('0x11ed')]=_0x5d7e03[_0x17e308('0x20b2')](),_0x9e1a6a[_0x17e308('0x17f')]=[],_0x9e1a6a['setting']=_0x2fb449,_0x9e1a6a[_0x17e308('0xace')]=_0x5f01ac,_0x9e1a6a['crudPermissions']=_0xec7ae5,_0x9e1a6a[_0x17e308('0x258d')]={},_0x9e1a6a[_0x17e308('0x19b2')]=_0x9e1a6a[_0x17e308('0x260a')]&&_0x9e1a6a[_0x17e308('0x260a')][_0x17e308('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x9e1a6a[_0x17e308('0xf28')]=_0x17e308('0x4c4'),_0x9e1a6a[_0x17e308('0x273a')]=angular[_0x17e308('0x1a86')](_0x41e10d),_0x9e1a6a['projects']=_0x31659e,_0x9e1a6a[_0x17e308('0x2228')]=![];!_0x9e1a6a[_0x17e308('0x273a')]&&(_0x9e1a6a[_0x17e308('0x273a')]={'enableUncompleteSave':!![],'sendUnpauseOnSubmit':!![]},_0x9e1a6a[_0x17e308('0xf28')]='JSCRIPTY.NEW_PROJECT',_0x9e1a6a[_0x17e308('0x2228')]=!![]);_0x9e1a6a[_0x17e308('0x1732')]=_0x8efb8f,_0x9e1a6a['saveProject']=_0xac8588,_0x9e1a6a[_0x17e308('0x15a4')]=_0x34d3cf,_0x9e1a6a[_0x17e308('0x16b3')]=_0x33c0c3,_0x9e1a6a['closeDialog']=_0x567e6f;function _0x8efb8f(){const _0x319cad=_0x17e308;_0x9e1a6a[_0x319cad('0x17f')]=[],_0x3b193d['jscriptyProject'][_0x319cad('0xb0a')](_0x9e1a6a[_0x319cad('0x273a')])['$promise']['then'](function(_0x36e850){const _0x1d10e0=_0x319cad;_0x9e1a6a[_0x1d10e0('0x1248')][_0x1d10e0('0x1167')](_0x36e850['toJSON']()),_0x3a9c1f[_0x1d10e0('0x53')]({'title':_0x1d10e0('0x610'),'msg':_0x9e1a6a['project'][_0x1d10e0('0x60a')]?_0x9e1a6a['project'][_0x1d10e0('0x60a')]+'\x20has\x20been\x20created!':''}),_0x567e6f(_0x36e850);})[_0x319cad('0x130a')](function(_0x16be01){const _0x44c94e=_0x319cad;if(_0x16be01[_0x44c94e('0x5a5')]&&_0x16be01[_0x44c94e('0x5a5')][_0x44c94e('0x17f')]&&_0x16be01['data'][_0x44c94e('0x17f')]['length']){_0x9e1a6a[_0x44c94e('0x17f')]=_0x16be01[_0x44c94e('0x5a5')][_0x44c94e('0x17f')]||[{'message':_0x16be01[_0x44c94e('0x1ff0')](),'type':'api.jscriptyProject.save'}];for(let _0xe97df5=0x0;_0xe97df5<_0x16be01[_0x44c94e('0x5a5')]['errors'][_0x44c94e('0x1564')];_0xe97df5+=0x1){_0x3a9c1f[_0x44c94e('0x52a')]({'title':_0x16be01[_0x44c94e('0x5a5')]['errors'][_0xe97df5]['type'],'msg':_0x16be01[_0x44c94e('0x5a5')][_0x44c94e('0x17f')][_0xe97df5][_0x44c94e('0x8c2')]});}}else _0x3a9c1f[_0x44c94e('0x52a')]({'title':_0x16be01[_0x44c94e('0x13ee')]?_0x44c94e('0x2168')+_0x16be01[_0x44c94e('0x13ee')]+_0x44c94e('0xbf6')+_0x16be01['statusText']:_0x44c94e('0xde'),'msg':_0x16be01[_0x44c94e('0x5a5')]?JSON['stringify'](_0x16be01[_0x44c94e('0x5a5')][_0x44c94e('0x8c2')]):_0x16be01[_0x44c94e('0x1ff0')]()});});}function _0xac8588(){const _0x470349=_0x17e308;_0x9e1a6a[_0x470349('0x17f')]=[],_0x3b193d[_0x470349('0xa8b')]['update']({'id':_0x9e1a6a['project']['id']},_0x9e1a6a[_0x470349('0x273a')])['$promise'][_0x470349('0x683')](function(_0x25bd4d){const _0x574bbd=_0x470349,_0x360247=_0x2e3ca0()[_0x574bbd('0x1c07')](_0x9e1a6a[_0x574bbd('0x1248')],{'id':_0x25bd4d['id']});_0x360247&&_0x2e3ca0()['merge'](_0x360247,_0x2e3ca0()[_0x574bbd('0x24d0')](_0x25bd4d['toJSON'](),_0x2e3ca0()[_0x574bbd('0x55e')](_0x360247))),_0x3a9c1f['success']({'title':_0x574bbd('0x630'),'msg':_0x9e1a6a[_0x574bbd('0x273a')]['name']?_0x9e1a6a[_0x574bbd('0x273a')][_0x574bbd('0x60a')]+'\x20has\x20been\x20saved!':''}),_0x567e6f(_0x25bd4d);})[_0x470349('0x130a')](function(_0x42e18d){const _0xd3b267=_0x470349;if(_0x42e18d[_0xd3b267('0x5a5')]&&_0x42e18d['data']['errors']&&_0x42e18d[_0xd3b267('0x5a5')]['errors']['length']){_0x9e1a6a[_0xd3b267('0x17f')]=_0x42e18d[_0xd3b267('0x5a5')][_0xd3b267('0x17f')]||[{'message':_0x42e18d['toString'](),'type':_0xd3b267('0x77c')}];for(let _0x2e62aa=0x0;_0x2e62aa<_0x42e18d[_0xd3b267('0x5a5')]['errors'][_0xd3b267('0x1564')];_0x2e62aa++){_0x3a9c1f[_0xd3b267('0x52a')]({'title':_0x42e18d['data'][_0xd3b267('0x17f')][_0x2e62aa][_0xd3b267('0xcf0')],'msg':_0x42e18d[_0xd3b267('0x5a5')][_0xd3b267('0x17f')][_0x2e62aa][_0xd3b267('0x8c2')]});}}else _0x3a9c1f[_0xd3b267('0x52a')]({'title':_0x42e18d[_0xd3b267('0x13ee')]?_0xd3b267('0x2168')+_0x42e18d[_0xd3b267('0x13ee')]+'\x20-\x20'+_0x42e18d[_0xd3b267('0x24a9')]:_0xd3b267('0x77c'),'msg':_0x42e18d[_0xd3b267('0x5a5')]?JSON[_0xd3b267('0x258a')](_0x42e18d[_0xd3b267('0x5a5')][_0xd3b267('0x8c2')]):_0x42e18d[_0xd3b267('0x1ff0')]()});});}function _0x34d3cf(_0x37fff9){const _0x3a38f1=_0x17e308;_0x9e1a6a[_0x3a38f1('0x17f')]=[];const _0x330db5=_0x2de13a[_0x3a38f1('0x1c6f')]()[_0x3a38f1('0xf28')](_0x3a38f1('0x4d'))[_0x3a38f1('0xa6a')](_0x3a38f1('0x35f'))['ariaLabel'](_0x3a38f1('0x860'))['ok'](_0x3a38f1('0x2307'))[_0x3a38f1('0x19fb')]('Cancel')['targetEvent'](_0x37fff9);_0x2de13a[_0x3a38f1('0x1d4')](_0x330db5)['then'](function(){const _0x7142a=_0x3a38f1;_0x3b193d[_0x7142a('0xa8b')][_0x7142a('0xd7e')]({'id':_0x9e1a6a[_0x7142a('0x273a')]['id']})[_0x7142a('0xe53')][_0x7142a('0x683')](function(){const _0x591006=_0x7142a;_0x2e3ca0()['remove'](_0x9e1a6a[_0x591006('0x1248')],{'id':_0x9e1a6a['project']['id']}),_0x3a9c1f['success']({'title':_0x591006('0x1663'),'msg':(_0x9e1a6a[_0x591006('0x273a')][_0x591006('0x60a')]||_0x591006('0x273a'))+_0x591006('0x194d')}),_0x567e6f(_0x9e1a6a['project']);})[_0x7142a('0x130a')](function(_0x48bb9c){const _0x580a85=_0x7142a;if(_0x48bb9c[_0x580a85('0x5a5')]&&_0x48bb9c[_0x580a85('0x5a5')][_0x580a85('0x17f')]&&_0x48bb9c[_0x580a85('0x5a5')]['errors'][_0x580a85('0x1564')]){_0x9e1a6a[_0x580a85('0x17f')]=_0x48bb9c[_0x580a85('0x5a5')]['errors']||[{'message':_0x48bb9c[_0x580a85('0x1ff0')](),'type':_0x580a85('0xb73')}];for(let _0x55ba63=0x0;_0x55ba63<_0x48bb9c['data'][_0x580a85('0x17f')][_0x580a85('0x1564')];_0x55ba63++){_0x3a9c1f['error']({'title':_0x48bb9c[_0x580a85('0x5a5')][_0x580a85('0x17f')][_0x55ba63][_0x580a85('0xcf0')],'msg':_0x48bb9c[_0x580a85('0x5a5')][_0x580a85('0x17f')][_0x55ba63][_0x580a85('0x8c2')]});}}else _0x3a9c1f['error']({'title':_0x48bb9c['status']?_0x580a85('0x2168')+_0x48bb9c[_0x580a85('0x13ee')]+'\x20-\x20'+_0x48bb9c[_0x580a85('0x24a9')]:_0x580a85('0xb73'),'msg':_0x48bb9c[_0x580a85('0x5a5')]?JSON[_0x580a85('0x258a')](_0x48bb9c[_0x580a85('0x5a5')][_0x580a85('0x8c2')]):_0x48bb9c['message']||_0x48bb9c[_0x580a85('0x1ff0')]()});});},function(){});}function _0x33c0c3(_0x247faf){return _0x247faf===null?undefined:new Date(_0x247faf);}function _0x567e6f(_0x1ebe3d){const _0x42dd2c=_0x17e308;_0x2de13a[_0x42dd2c('0x1715')](_0x1ebe3d);}}const _0x56ba5=_0x1c8159;_0x44de6e['$inject']=[_0x189033('0x1e48'),'$document',_0x189033('0x2063'),_0x189033('0x56b'),'toasty','dateFilterLocalizationFactory'];function _0x44de6e(_0x146973,_0x52e606,_0x2425d3,_0x2581d3,_0x1bafeb,_0x30be53){const _0x40010c=_0x189033,_0x14c256=this;_0x14c256[_0x40010c('0x273a')]={},_0x14c256[_0x40010c('0x2620')]=_0x30be53;const _0x1a33a9=new Date();_0x1a33a9[_0x40010c('0x2813')](0x0,0x0,0x0,0x0),_0x14c256['pickerModel']={'dateStart':new Date(_0x1a33a9[_0x40010c('0x6f7')](),_0x1a33a9[_0x40010c('0x110')](),0x1),'dateEnd':new Date(_0x1a33a9[_0x40010c('0x6f7')](),_0x1a33a9[_0x40010c('0x110')]()+0x1,0x0),'selectedTemplate':'TM'},_0x14c256[_0x40010c('0x12f3')]=_0x5b8eeb,_0x14c256['getSummary']=_0x436d0b,_0x14c256[_0x40010c('0x87f')]=_0x58d9d0;function _0x58d9d0(){const _0x31971b=_0x40010c;return _0x14c256[_0x31971b('0x2213')]=![],_0x2581d3[_0x31971b('0xa8b')][_0x31971b('0x87f')]({'id':_0x14c256[_0x31971b('0x273a')]['id'],'sort':'-createdAt,questionId','createdAt':{'$gte':_0x1aaf93()(_0x14c256[_0x31971b('0x1641')][_0x31971b('0x1830')])['add'](0x0,_0x31971b('0x624'))[_0x31971b('0x23c6')](0x0,'minutes')[_0x31971b('0x23c6')](0x0,_0x31971b('0x1b53'))['utcOffset'](0x0,!![])['format'](),'$lte':_0x1aaf93()(_0x14c256[_0x31971b('0x1641')][_0x31971b('0x13f3')])[_0x31971b('0x23c6')](0x17,_0x31971b('0x624'))['add'](0x3b,_0x31971b('0x25a6'))[_0x31971b('0x23c6')](0x3b,'seconds')[_0x31971b('0xb11')](0x0,!![])[_0x31971b('0x26dd')]()},'nolimit':!![]})[_0x31971b('0xe53')][_0x31971b('0x683')](function(_0x4733e9){const _0x3b68bd=_0x31971b;if(_0x4733e9&&_0x4733e9['rows']&&typeof _0x4733e9[_0x3b68bd('0x50d')]!==_0x3b68bd('0x1867')){_0x14c256['answers']={};for(let _0x7ae611=0x0,_0x3ed661=_0x4733e9[_0x3b68bd('0x50d')];_0x7ae611<_0x3ed661;_0x7ae611++){_0x4733e9[_0x3b68bd('0xf5d')][_0x7ae611][_0x3b68bd('0x1727')]&&(_0x14c256[_0x3b68bd('0x2213')]=!![],typeof _0x14c256['answers'][_0x4733e9['rows'][_0x7ae611][_0x3b68bd('0x1727')]]==='undefined'&&(_0x14c256[_0x3b68bd('0x1da1')][_0x4733e9[_0x3b68bd('0xf5d')][_0x7ae611][_0x3b68bd('0x1727')]]={'question':_0x4733e9['rows'][_0x7ae611][_0x3b68bd('0x1612')],'answers':{},'sum':0x0}),_0x4733e9['rows'][_0x7ae611][_0x3b68bd('0x1767')]===''&&(_0x4733e9['rows'][_0x7ae611]['answer']=_0x3b68bd('0x67')),_0x14c256[_0x3b68bd('0x1da1')][_0x4733e9[_0x3b68bd('0xf5d')][_0x7ae611]['questionId']][_0x3b68bd('0x1da1')][_0x4733e9['rows'][_0x7ae611][_0x3b68bd('0x1767')]]?_0x14c256[_0x3b68bd('0x1da1')][_0x4733e9['rows'][_0x7ae611]['questionId']][_0x3b68bd('0x1da1')][_0x4733e9[_0x3b68bd('0xf5d')][_0x7ae611]['answer']]+=0x1:_0x14c256[_0x3b68bd('0x1da1')][_0x4733e9[_0x3b68bd('0xf5d')][_0x7ae611][_0x3b68bd('0x1727')]]['answers'][_0x4733e9[_0x3b68bd('0xf5d')][_0x7ae611][_0x3b68bd('0x1767')]]=0x1,_0x14c256['answers'][_0x4733e9['rows'][_0x7ae611][_0x3b68bd('0x1727')]][_0x3b68bd('0x22a')]+=0x1);}}})['catch'](function(_0x2d77fc){const _0xbee004=_0x31971b;_0x1bafeb[_0xbee004('0x52a')]({'title':_0x2d77fc[_0xbee004('0x13ee')]?'API:'+_0x2d77fc[_0xbee004('0x13ee')]+_0xbee004('0xbf6')+_0x2d77fc[_0xbee004('0x24a9')]:'SYSTEM:GETANSWERS','msg':_0x2d77fc['data']?JSON[_0xbee004('0x258a')](_0x2d77fc['data']):_0x2d77fc['toString']()});});}function _0x5b8eeb(_0x1505be){const _0xe32f97=_0x40010c;_0x14c256[_0xe32f97('0x273a')]=_0x1505be,_0x14c256[_0xe32f97('0x87f')]();}function _0x436d0b(){const _0x4c4bc0=_0x40010c;return _0x2581d3[_0x4c4bc0('0xa8b')][_0x4c4bc0('0xccc')]({'id':_0x14c256[_0x4c4bc0('0x273a')]['id'],'startTime':{'$gte':_0x14c256[_0x4c4bc0('0x1641')][_0x4c4bc0('0x1830')],'$lte':_0x1aaf93()(_0x14c256[_0x4c4bc0('0x1641')][_0x4c4bc0('0x13f3')])[_0x4c4bc0('0x23c6')](0x17,_0x4c4bc0('0x624'))[_0x4c4bc0('0x23c6')](0x3b,'minutes')[_0x4c4bc0('0x23c6')](0x3b,_0x4c4bc0('0x1b53'))['format']()},'nolimit':!![]})[_0x4c4bc0('0xe53')][_0x4c4bc0('0x683')](function(_0x403d6e){const _0x18914e=_0x4c4bc0;if(typeof _0x403d6e[_0x18914e('0x1564')]!==_0x18914e('0x1867')){const _0x5afac5=[_0x403d6e[_0x18914e('0x1fb3')]],_0x3c1282=new Blob(_0x5afac5,{'type':_0x403d6e['type']}),_0x10adef=window[_0x18914e('0x12e1')]['createElement']('a');_0x10adef[_0x18914e('0x130f')](_0x18914e('0x2767'),URL[_0x18914e('0x2820')](_0x3c1282)),_0x10adef[_0x18914e('0x130f')](_0x18914e('0x18e8'),'jscriptyProjectSummary_'+_0x14c256[_0x18914e('0x273a')]['id']+'.csv'),_0x10adef[_0x18914e('0x1d42')]();}else _0x1bafeb['info']({'title':'EXPORT','msg':_0x18914e('0xf2c')});})[_0x4c4bc0('0x130a')](function(_0x48a43d){const _0x362600=_0x4c4bc0;_0x1bafeb[_0x362600('0x52a')]({'title':_0x48a43d[_0x362600('0x13ee')]?'API:'+_0x48a43d[_0x362600('0x13ee')]+_0x362600('0xbf6')+_0x48a43d[_0x362600('0x24a9')]:'api.jscriptyProject.getSummary','msg':_0x48a43d[_0x362600('0x5a5')]?JSON[_0x362600('0x258a')](_0x48a43d[_0x362600('0x5a5')]):_0x48a43d[_0x362600('0x1ff0')]()});});}}const _0x40ace0=_0x44de6e;;function _0x4f1f56(){const _0x3b0558=_0x189033,_0x2a2375=this;_0x2a2375[_0x3b0558('0x273a')]={},_0x2a2375[_0x3b0558('0xbd6')]={'questionTypes':[_0x3b0558('0x1bcd'),_0x3b0558('0x24be'),_0x3b0558('0xa5a'),_0x3b0558('0x49c'),_0x3b0558('0xb31'),_0x3b0558('0x121f'),_0x3b0558('0x270e'),_0x3b0558('0x147a'),'email','range',_0x3b0558('0x1284')],'elementTypes':[_0x3b0558('0x1612'),'paragraph']},_0x2a2375['init']=_0x5afba1,_0x2a2375[_0x3b0558('0x703')]=_0x2aa398;function _0x2aa398(_0x8ec673){const _0x164358=_0x3b0558;if(_0x2e3ca0()[_0x164358('0x8f2')](_0x8ec673))return![];try{JSON[_0x164358('0x1f34')](_0x8ec673);}catch(_0x5d06bd){return![];}return!![];}function _0x5afba1(_0x349112){const _0x5100fe=_0x3b0558;_0x2a2375[_0x5100fe('0x273a')]=_0x349112;if(_0x2e3ca0()[_0x5100fe('0x781')](_0x349112['formData']))_0x2a2375[_0x5100fe('0x273a')][_0x5100fe('0x4f5')]=_0x349112[_0x5100fe('0x4f5')];else _0x2a2375[_0x5100fe('0x703')](_0x349112[_0x5100fe('0x4f5')])?_0x2a2375[_0x5100fe('0x273a')][_0x5100fe('0x4f5')]=JSON[_0x5100fe('0x1f34')](_0x349112[_0x5100fe('0x4f5')]):_0x2a2375['project'][_0x5100fe('0x4f5')]={};}}const _0x10f9f5=_0x4f1f56;_0x276bdd[_0x189033('0x14be')]=[_0x189033('0x1e48'),_0x189033('0x938'),_0x189033('0x1d70'),'api',_0x189033('0x273a'),_0x189033('0x1248'),_0x189033('0x1d08')];function _0x276bdd(_0x95c664,_0x5b8566,_0x3d96be,_0x7a84ce,_0x38f869,_0x5bdd7f,_0x15a040){const _0x100ee0=_0x189033,_0x5cbb35=this;_0x5cbb35[_0x100ee0('0x2228')]=!![],_0x5cbb35[_0x100ee0('0x273a')]=angular['copy'](_0x38f869),_0x5cbb35[_0x100ee0('0x1248')]=_0x5bdd7f,_0x5cbb35[_0x100ee0('0xf28')]=_0x15a040[_0x100ee0('0x2728')]('JSCRIPTY.CLONE_PROJECT');_0x38f869&&_0x38f869[_0x100ee0('0x60a')]&&(_0x5cbb35['title']+=':\x20'+_0x38f869[_0x100ee0('0x60a')]);_0x5cbb35['cloneProject']=_0x2031c8,_0x5cbb35[_0x100ee0('0xf82')]=_0x154422;function _0x2031c8(){const _0x6a1827=_0x100ee0;return _0x7a84ce[_0x6a1827('0xa8b')][_0x6a1827('0x147f')]({'id':_0x38f869['id']},_0x5cbb35[_0x6a1827('0x273a')])['$promise'][_0x6a1827('0x683')](function(_0x50c9eb){const _0x4401e1=_0x6a1827;_0x5cbb35[_0x4401e1('0x1248')]['unshift'](_0x50c9eb['toJSON']()),_0x3d96be[_0x4401e1('0x53')]({'title':_0x4401e1('0xce5'),'msg':_0x5cbb35[_0x4401e1('0x273a')][_0x4401e1('0x60a')]?_0x5cbb35['project'][_0x4401e1('0x60a')]+_0x4401e1('0x640'):''}),_0x5b8566['go'](_0x4401e1('0xe29'),{'id':_0x50c9eb['id']}),_0x154422(_0x50c9eb);})[_0x6a1827('0x130a')](function(_0x297dd7){const _0x9ed234=_0x6a1827;if(_0x297dd7['data']&&_0x297dd7['data']['errors']&&_0x297dd7[_0x9ed234('0x5a5')][_0x9ed234('0x17f')]['length']){_0x5cbb35['errors']=_0x297dd7[_0x9ed234('0x5a5')][_0x9ed234('0x17f')]||[{'message':_0x297dd7['toString'](),'type':_0x9ed234('0x1a8c')}];for(let _0x5add12=0x0;_0x5add12<_0x297dd7[_0x9ed234('0x5a5')][_0x9ed234('0x17f')][_0x9ed234('0x1564')];_0x5add12+=0x1){_0x3d96be[_0x9ed234('0x52a')]({'title':_0x297dd7['data'][_0x9ed234('0x17f')][_0x5add12]['type'],'msg':_0x297dd7[_0x9ed234('0x5a5')][_0x9ed234('0x17f')][_0x5add12][_0x9ed234('0x8c2')]});}}else _0x3d96be['error']({'title':_0x297dd7[_0x9ed234('0x13ee')]?_0x9ed234('0x2168')+_0x297dd7[_0x9ed234('0x13ee')]+_0x9ed234('0xbf6')+_0x297dd7['statusText']:_0x9ed234('0x1a8c'),'msg':_0x297dd7[_0x9ed234('0x5a5')]?JSON[_0x9ed234('0x258a')](_0x297dd7['data'][_0x9ed234('0x8c2')]):_0x297dd7['toString']()});});}function _0x154422(_0x4e0272){const _0x3a1fef=_0x100ee0;_0x95c664[_0x3a1fef('0x1715')](_0x4e0272);}}const _0x53d8a4=_0x276bdd;_0x139be5[_0x189033('0x14be')]=['$q',_0x189033('0x1e48'),_0x189033('0x7a5')];function _0x139be5(_0x47d145,_0x2d8579,_0x329b2b){const _0x42088c=_0x189033,_0x550aae=this;_0x550aae[_0x42088c('0x273a')]={},_0x550aae[_0x42088c('0x15de')]={},_0x550aae[_0x42088c('0x991')]={},_0x550aae[_0x42088c('0x12f3')]=_0x4be53f,_0x550aae[_0x42088c('0x2685')]=_0xf009d8,_0x550aae[_0x42088c('0x1fd2')]=_0x10ead7;function _0x4be53f(_0x547971){const _0x4422f3=_0x42088c;_0x550aae[_0x4422f3('0x273a')]=_0x547971,_0x329b2b['$on'](_0x4422f3('0x1ee2'),function(_0x10e6b2,_0x243436){const _0x1a2280=_0x4422f3;if(_0x243436[_0x1a2280('0xa9')]&&_0x550aae[_0x1a2280('0x273a')][_0x1a2280('0x4f5')]&&_0x550aae[_0x1a2280('0x273a')]['formData'][_0x1a2280('0x2589')])for(let _0x3f5d8=0x0,_0x735da8=_0x550aae['project'][_0x1a2280('0x4f5')][_0x1a2280('0x2589')]['length'];_0x3f5d8<_0x735da8;_0x3f5d8++){if(_0x243436[_0x1a2280('0xa9')]['number']<_0x3f5d8+0x1&&_0x550aae[_0x1a2280('0x273a')]['formData'][_0x1a2280('0x2589')][_0x3f5d8][_0x1a2280('0x1700')])for(let _0x22b090=0x0,_0x483350=_0x550aae[_0x1a2280('0x273a')][_0x1a2280('0x4f5')][_0x1a2280('0x2589')][_0x3f5d8][_0x1a2280('0x1700')]['length'];_0x22b090<_0x483350;_0x22b090++){_0x550aae[_0x1a2280('0x273a')][_0x1a2280('0x4f5')][_0x1a2280('0x2589')][_0x3f5d8][_0x1a2280('0x1700')][_0x22b090]['type']==='question'&&_0x550aae['project'][_0x1a2280('0x4f5')]['pages'][_0x3f5d8]['elements'][_0x22b090]['question']&&delete _0x550aae[_0x1a2280('0x15de')][_0x550aae['project'][_0x1a2280('0x4f5')]['pages'][_0x3f5d8]['elements'][_0x22b090][_0x1a2280('0x1612')]['id']];}}});}function _0xf009d8(_0x91de8e){const _0x4a8851=_0x42088c,_0x12f081=_0x47d145[_0x4a8851('0x448')](),_0x154c8d=_0x2d8579[_0x4a8851('0x1c6f')]()[_0x4a8851('0xf28')](_0x4a8851('0x1585'))[_0x4a8851('0x1525')]('')[_0x4a8851('0x1040')](_0x4a8851('0x2c5'))[_0x4a8851('0xe42')](_0x91de8e)['ok']('SAVE')[_0x4a8851('0x19fb')]('CANCEL');return _0x2d8579['show'](_0x154c8d)['then'](function(){const _0x19f28e=_0x4a8851;_0x12f081[_0x19f28e('0xed7')](!![]);},function(){const _0x50457e=_0x4a8851;_0x12f081[_0x50457e('0xfae')]();}),_0x12f081[_0x4a8851('0x1883')];}function _0x10ead7(){const _0x58bd29=_0x42088c;_0x550aae[_0x58bd29('0x991')][_0x58bd29('0x1302')]&&_0x550aae[_0x58bd29('0x991')]['reset']();}}const _0x52837f=_0x139be5,_0x56d827=_0x180212['p']+'src/js/modules/main/apps/jscripty/views/projects/edit/sessions/dialog.html/dialog.html';_0x41553b[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),'$timeout',_0x189033('0x1e48'),'$document',_0x189033('0x1d70'),'api','Auth'];function _0x41553b(_0x3b36e7,_0x5360,_0xaf7dfa,_0x29e631,_0x2989c7,_0x5927da,_0x196e78,_0x1c9ee8,_0x104c37,_0x47c628,_0x5719fe){const _0x38ddea=_0x189033,_0x525504=this;_0x525504[_0x38ddea('0x11ed')]=_0x5719fe[_0x38ddea('0x20b2')](),_0x525504[_0x38ddea('0x273a')]={},_0x525504[_0x38ddea('0xfb9')]={'count':0x0,'rows':[]},_0x525504[_0x38ddea('0x151a')]=[],_0x525504['crudPermissions'],_0x525504[_0x38ddea('0x23a2')]={'fields':_0x38ddea('0x1d19'),'sort':_0x38ddea('0x231c'),'limit':0xa,'page':0x1},_0x525504[_0x38ddea('0x12f3')]=_0xe5198d,_0x525504[_0x38ddea('0x26eb')]=_0x1af5c1,_0x525504['success']=_0x39221a,_0x525504[_0x38ddea('0xd51')]=_0x3f4e2b,_0x525504[_0x38ddea('0xe66')]=_0x337eb4,_0x525504[_0x38ddea('0x1ae2')]=_0x329c97,_0x525504[_0x38ddea('0xf0d')]=_0x5d7911,_0x525504[_0x38ddea('0x20f5')]=_0x2e2fa6,_0x525504['deleteSelectedProjectSessions']=_0x4100b2;function _0xe5198d(_0x2c198e,_0x3ab46a){const _0x45a9ad=_0x38ddea;_0x525504[_0x45a9ad('0x273a')]=_0x2c198e,_0x525504[_0x45a9ad('0x1134')]=typeof _0x3ab46a!==_0x45a9ad('0x1867')?_0x3ab46a:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x525504['query']['id']=_0x525504['project']['id'],_0x3f4e2b();}function _0x1af5c1(_0x592087,_0x2679eb){const _0x4ef9c2=_0x38ddea,_0x2a866c=_0x196e78['confirm']()[_0x4ef9c2('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20session?')[_0x4ef9c2('0x26e3')](''+(_0x592087[_0x4ef9c2('0x60a')]||_0x592087['id']&&_0x2e3ca0()[_0x4ef9c2('0x2711')](_0x4ef9c2('0x1257'))+_0x592087['id']||_0x4ef9c2('0xd18'))+''+_0x4ef9c2('0x1ee7'))[_0x4ef9c2('0x1040')](_0x4ef9c2('0x27d6'))[_0x4ef9c2('0xe42')](_0x2679eb)['ok']('OK')[_0x4ef9c2('0x19fb')](_0x4ef9c2('0x16b8'));_0x196e78[_0x4ef9c2('0x1d4')](_0x2a866c)[_0x4ef9c2('0x683')](function(){_0x2e2fa6(_0x592087);},function(){const _0x319624=_0x4ef9c2;console[_0x319624('0x1b2b')](_0x319624('0x16b8'));});}function _0x39221a(_0x8cbef3){const _0x35bc58=_0x38ddea;_0x525504[_0x35bc58('0xfb9')]=_0x8cbef3||{'count':0x0,'rows':[]};}function _0x3f4e2b(){const _0x9d406c=_0x38ddea;_0x525504[_0x9d406c('0x23a2')]['offset']=(_0x525504[_0x9d406c('0x23a2')][_0x9d406c('0xdf8')]-0x1)*_0x525504[_0x9d406c('0x23a2')][_0x9d406c('0x6f0')],_0x525504['promise']=_0x47c628['jscriptyProject']['getSessions'](_0x525504['query'],_0x39221a)[_0x9d406c('0xe53')];}function _0x337eb4(_0x158164,_0x461c64){const _0x52c5fd=_0x38ddea;_0x196e78[_0x52c5fd('0x1d4')]({'controller':'CreateOrEditSessionDialogController','controllerAs':'vm','templateUrl':_0x56d827,'parent':angular[_0x52c5fd('0x1fcc')](_0x1c9ee8[_0x52c5fd('0x18e5')]),'targetEvent':_0x158164,'clickOutsideToClose':!![],'locals':{'project':_0x525504['project'],'session':_0x461c64,'sessions':_0x525504[_0x52c5fd('0xfb9')][_0x52c5fd('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x525504['crudPermissions']}});}function _0x329c97(_0x4c5950,_0x342b9f){const _0x4e5ba9=_0x38ddea;_0x196e78[_0x4e5ba9('0x1d4')]({'controller':_0x4e5ba9('0xd0f'),'controllerAs':'vm','templateUrl':_0x56d827,'parent':angular[_0x4e5ba9('0x1fcc')](_0x1c9ee8[_0x4e5ba9('0x18e5')]),'targetEvent':_0x4c5950,'clickOutsideToClose':!![],'resolve':{'questions':[_0x4e5ba9('0x4b1'),function(_0x4ec9cd){const _0x4a935a=_0x4e5ba9;return _0x4ec9cd[_0x4a935a('0xed7')](_0x4a935a('0x1b64'),{'fields':_0x4a935a('0x21c9'),'sort':'id','id':_0x342b9f['id']});}]},'locals':{'project':_0x525504[_0x4e5ba9('0x273a')],'session':_0x342b9f}});}function _0x2e2fa6(_0x32f1a9){const _0x41546e=_0x38ddea;_0x47c628[_0x41546e('0x1038')]['delete']({'id':_0x32f1a9['id']})['$promise']['then'](function(){const _0x2a32d8=_0x41546e;_0x2e3ca0()['remove'](_0x525504[_0x2a32d8('0xfb9')]['rows'],{'id':_0x32f1a9['id']}),_0x525504[_0x2a32d8('0xfb9')][_0x2a32d8('0x50d')]-=0x1,!_0x525504[_0x2a32d8('0xfb9')][_0x2a32d8('0xf5d')]['length']&&_0x3f4e2b(),_0x104c37['success']({'title':'Session\x20deleted!','msg':_0x32f1a9[_0x2a32d8('0x60a')]?_0x32f1a9[_0x2a32d8('0x60a')]+_0x2a32d8('0x194d'):''});})[_0x41546e('0x130a')](function(_0x5815f5){const _0x337985=_0x41546e;if(_0x5815f5['data']&&_0x5815f5[_0x337985('0x5a5')][_0x337985('0x17f')]&&_0x5815f5[_0x337985('0x5a5')]['errors'][_0x337985('0x1564')]){_0x525504['errors']=_0x5815f5[_0x337985('0x5a5')]['errors']||[{'message':_0x5815f5[_0x337985('0x1ff0')](),'type':'SYSTEM:GETjscriptyProject'}];for(let _0x443201=0x0;_0x443201<_0x5815f5[_0x337985('0x5a5')]['errors'][_0x337985('0x1564')];_0x443201++){_0x104c37[_0x337985('0x52a')]({'title':_0x5815f5[_0x337985('0x5a5')][_0x337985('0x17f')][_0x443201][_0x337985('0xcf0')],'msg':_0x5815f5[_0x337985('0x5a5')][_0x337985('0x17f')][_0x443201][_0x337985('0x8c2')]});}}else _0x104c37[_0x337985('0x52a')]({'title':_0x5815f5[_0x337985('0x13ee')]?'API:'+_0x5815f5[_0x337985('0x13ee')]+'\x20-\x20'+_0x5815f5[_0x337985('0x24a9')]:'SYSTEM:GETjscriptyProject','msg':_0x5815f5[_0x337985('0x5a5')]?JSON[_0x337985('0x258a')](_0x5815f5[_0x337985('0x5a5')][_0x337985('0x8c2')]):_0x5815f5[_0x337985('0x8c2')]||_0x5815f5['toString']()});});}function _0x5d7911(){const _0x541e75=_0x38ddea,_0x384f00=angular[_0x541e75('0x1a86')](_0x525504['selectedProjectSessions']);return _0x525504[_0x541e75('0x151a')]=[],_0x384f00;}function _0x4100b2(_0x16115d){const _0x135f1f=_0x38ddea,_0xed348e=_0x196e78[_0x135f1f('0x1c6f')]()[_0x135f1f('0xf28')](_0x135f1f('0xebb'))[_0x135f1f('0x26e3')](_0x135f1f('0xed5')+_0x525504['selectedProjectSessions'][_0x135f1f('0x1564')]+_0x135f1f('0x93c')+_0x135f1f('0x1ee7'))['ariaLabel'](_0x135f1f('0x13e6'))['targetEvent'](_0x16115d)['ok']('OK')[_0x135f1f('0x19fb')](_0x135f1f('0x16b8'));_0x196e78[_0x135f1f('0x1d4')](_0xed348e)[_0x135f1f('0x683')](function(){const _0x5550a5=_0x135f1f;_0x525504['selectedProjectSessions'][_0x5550a5('0x1299')](function(_0x24bdd2){_0x2e2fa6(_0x24bdd2);}),_0x525504[_0x5550a5('0x151a')]=[];});}let _0x20b7e6=!![],_0x5ac69f=0x1;_0x5360[_0x38ddea('0x186d')]('vm_dc.query.filter',function(_0x2c23bc,_0x40738b){const _0x2a41b0=_0x38ddea;_0x20b7e6?_0x5927da(function(){_0x20b7e6=![];}):(!_0x40738b&&(_0x5ac69f=_0x525504[_0x2a41b0('0x23a2')][_0x2a41b0('0xdf8')]),_0x2c23bc!==_0x40738b&&(_0x525504['query'][_0x2a41b0('0xdf8')]=0x1),!_0x2c23bc&&(_0x525504[_0x2a41b0('0x23a2')][_0x2a41b0('0xdf8')]=_0x5ac69f),_0x3f4e2b());});}const _0x47b7eb=_0x41553b;_0xb11aaa[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),'$location',_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0xd18'),_0x189033('0xa37'),_0x189033('0x273a')];function _0xb11aaa(_0x1c06c6,_0x548df8,_0x3ac72e,_0x17d79e,_0x4ddc9f,_0x5ee81c,_0x3921b7,_0x3ef284){const _0x195bf2=_0x189033,_0x2053ad=this;_0x2053ad[_0x195bf2('0xf28')]='JSCRIPTY.SESSION_RESULTS',_0x2053ad[_0x195bf2('0xd18')]=_0x5ee81c,_0x2053ad[_0x195bf2('0xa37')]=_0x3921b7,_0x2053ad[_0x195bf2('0x273a')]=_0x3ef284;function _0x1f607a(_0x1f1189){const _0x42a562=_0x195bf2;_0x17d79e[_0x42a562('0x1715')](_0x1f1189);}_0x2053ad[_0x195bf2('0xf82')]=_0x1f607a;}const _0x580527=_0xb11aaa,_0x551afb=_0x180212['p']+'src/js/modules/main/apps/jscripty/views/projects/edit/clone/clone.html/clone.html';_0x4a5cc9[_0x189033('0x14be')]=[_0x189033('0x938'),'$location',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),'toasty',_0x189033('0xba1'),_0x189033('0x273a'),_0x189033('0x22df')];function _0x4a5cc9(_0x269b3f,_0x25522f,_0x4bec61,_0x2577e2,_0xc69efb,_0x2218d6,_0x53e5b3,_0x2d796e,_0x3ecb74,_0x3d8222,_0x23057a,_0x3212aa){const _0x4ae4a7=_0x189033,_0x368275=this;_0x368275[_0x4ae4a7('0x11ed')]=_0x3d8222['getCurrentUser'](),_0x368275[_0x4ae4a7('0xace')]=_0x2218d6,_0x368275[_0x4ae4a7('0x260a')]=_0x53e5b3,_0x368275[_0x4ae4a7('0x19b2')]=_0x368275[_0x4ae4a7('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x368275[_0x4ae4a7('0x1224')]=_0x25522f[_0x4ae4a7('0x173e')]()+_0x4ae4a7('0x20de')+_0x25522f[_0x4ae4a7('0x19ac')](),_0x368275[_0x4ae4a7('0x273a')]=_0x23057a||_0x269b3f['params'][_0x4ae4a7('0x273a')]||{},_0x368275[_0x4ae4a7('0x22df')]=_0x3212aa&&_0x3212aa[_0x4ae4a7('0x50d')]==0x1?_0x3212aa[_0x4ae4a7('0xf5d')][0x0]:null,_0x368275[_0x4ae4a7('0x1134')]=_0x3d8222[_0x4ae4a7('0x142a')](_0x368275[_0x4ae4a7('0x22df')]?_0x368275[_0x4ae4a7('0x22df')][_0x4ae4a7('0x1134')]:null),_0x368275['hasModulePermissions']={},_0x368275[_0x4ae4a7('0x517')]=_0x269b3f['params']['tab']||0x0,_0x368275[_0x4ae4a7('0x163d')]=_0x27674e,_0x368275[_0x4ae4a7('0x2430')]=_0x3ecb74['info'],_0x368275['gotoProjects']=_0x5451cc,_0x368275[_0x4ae4a7('0x1fd')]=_0x314f55;function _0x27674e(_0x70d4bf,_0xfcca4b){const _0x2c0d13=_0x4ae4a7;_0x4bec61['show']({'controller':_0x2c0d13('0x222d'),'controllerAs':'vm','templateUrl':_0x551afb,'parent':angular[_0x2c0d13('0x1fcc')](_0x2577e2[_0x2c0d13('0x18e5')]),'targetEvent':_0xfcca4b,'clickOutsideToClose':!![],'locals':{'project':_0x70d4bf,'projects':_0x368275['projects']?_0x368275[_0x2c0d13('0x1248')][_0x2c0d13('0xf5d')]:[],'crudPermissions':_0x368275[_0x2c0d13('0x1134')]}});}function _0x5451cc(){const _0x4bdff1=_0x4ae4a7;_0x269b3f['go'](_0x4bdff1('0x1f07'),{},{'reload':_0x4bdff1('0x1f07')});}function _0x314f55(){const _0x3d6669=_0x4ae4a7;_0x2d796e[_0x3d6669('0xa8b')][_0x3d6669('0x2480')]({'id':_0x368275[_0x3d6669('0x273a')]['id']},_0x368275[_0x3d6669('0x273a')])['$promise']['then'](function(){const _0x18e0a1=_0x3d6669;_0x3ecb74[_0x18e0a1('0x53')]({'title':_0x18e0a1('0x335'),'msg':_0x368275[_0x18e0a1('0x273a')][_0x18e0a1('0x60a')]?_0x368275[_0x18e0a1('0x273a')][_0x18e0a1('0x60a')]+_0x18e0a1('0x96c'):''});})['catch'](function(_0x1ba738){const _0x3e2f63=_0x3d6669;_0x3ecb74[_0x3e2f63('0x52a')]({'title':_0x1ba738['status']?_0x3e2f63('0x2168')+_0x1ba738[_0x3e2f63('0x13ee')]+_0x3e2f63('0xbf6')+_0x1ba738[_0x3e2f63('0x24a9')]:_0x3e2f63('0x10ab'),'msg':_0x1ba738[_0x3e2f63('0x5a5')]?JSON[_0x3e2f63('0x258a')](_0x1ba738[_0x3e2f63('0x5a5')]):_0x1ba738[_0x3e2f63('0x1ff0')]()});});}}const _0x390ed0=_0x4a5cc9,_0x548f07=_0x180212['p']+_0x189033('0x5ef');_0x4306ba[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$window','$state',_0x189033('0x110c'),'$mdDialog',_0x189033('0x16ea'),'$timeout',_0x189033('0x1d08'),_0x189033('0x1248'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),'msUtils',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x4306ba(_0xbcf3b6,_0x4ab495,_0x3a1710,_0x4c2027,_0x4854ea,_0x1addea,_0x220639,_0x49aea1,_0x4a49ce,_0x16d684,_0x879ec5,_0x27a595,_0x204689,_0x3e41a1,_0x10e0fd,_0x1f975e,_0xce4808){const _0x162de6=_0x189033,_0x38fb01=this;_0x38fb01['license']=_0x1f975e,_0x38fb01[_0x162de6('0x260a')]=_0xce4808,_0x38fb01[_0x162de6('0x11ed')]=_0x10e0fd[_0x162de6('0x20b2')](),_0x38fb01[_0x162de6('0x1248')]=_0x4a49ce||{'count':0x0,'rows':[]},_0x38fb01['userProfile']=_0x16d684,_0x38fb01[_0x162de6('0x22df')]=_0x879ec5&&_0x879ec5['count']==0x1?_0x879ec5['rows'][0x0]:null,_0x38fb01[_0x162de6('0x1134')]=_0x10e0fd['parseCrudPermissions'](_0x38fb01[_0x162de6('0x22df')]?_0x38fb01[_0x162de6('0x22df')][_0x162de6('0x1134')]:null),_0x38fb01['table']='projects',_0x38fb01['listOrder']='',_0x38fb01[_0x162de6('0x1ce2')]=null,_0x38fb01['selectedProjects']=[],_0x38fb01['query']={'fields':_0x162de6('0x2519'),'sort':_0x162de6('0xc36'),'limit':0xa,'page':0x1},_0x38fb01[_0x162de6('0xc63')]=_0x27c28c,_0x38fb01[_0x162de6('0x163d')]=_0x464529,_0x38fb01['sessionsgoto']=_0x4e82fd,_0x38fb01['deleteconfirm']=_0x183165,_0x38fb01[_0x162de6('0x53')]=_0x5859bf,_0x38fb01[_0x162de6('0x20b8')]=_0x5162de,_0x38fb01['createOrEditProject']=_0x4e1abb,_0x38fb01[_0x162de6('0x15a4')]=_0x9d1b30,_0x38fb01[_0x162de6('0x1dd4')]=_0x30084c,_0x38fb01[_0x162de6('0x115b')]=_0x42684a,_0x38fb01[_0x162de6('0x14aa')]=_0x4b5c1d,_0x38fb01[_0x162de6('0x159b')]=_0x4ce7f3;function _0x27c28c(_0xdaf79f){const _0x472d7e=_0x162de6;_0x3a1710['go'](_0x472d7e('0xe29'),{'id':_0xdaf79f['id'],'project':_0xdaf79f,'crudPermissions':_0x38fb01[_0x472d7e('0x1134')]});}function _0x464529(_0x3db01d,_0x3c59a1){const _0x5dd186=_0x162de6;_0x4854ea[_0x5dd186('0x1d4')]({'controller':_0x5dd186('0x222d'),'controllerAs':'vm','templateUrl':_0x551afb,'parent':angular[_0x5dd186('0x1fcc')](_0x1addea[_0x5dd186('0x18e5')]),'targetEvent':_0x3c59a1,'clickOutsideToClose':!![],'locals':{'project':_0x3db01d,'projects':_0x38fb01[_0x5dd186('0x1248')]?_0x38fb01['projects'][_0x5dd186('0xf5d')]:[],'crudPermissions':_0x38fb01[_0x5dd186('0x1134')]}});}function _0x4e82fd(_0x31aa96){const _0x3e53b4=_0x162de6;_0x3a1710['go'](_0x3e53b4('0xe29'),{'id':_0x31aa96['id'],'tab':0x3});}function _0x183165(_0x140dad,_0x36b357){const _0x4e20ec=_0x162de6,_0xe85069=_0x4854ea[_0x4e20ec('0x1c6f')]()[_0x4e20ec('0xf28')](_0x4e20ec('0x1b01')+_0x2e3ca0()[_0x4e20ec('0x1e03')](_0x4e20ec('0x273a'))+'?')[_0x4e20ec('0x26e3')](''+(_0x140dad[_0x4e20ec('0x60a')]||_0x4e20ec('0x273a'))+''+_0x4e20ec('0x1ee7'))[_0x4e20ec('0x1040')]('delete\x20project')[_0x4e20ec('0xe42')](_0x36b357)['ok']('OK')[_0x4e20ec('0x19fb')](_0x4e20ec('0x16b8'));_0x4854ea['show'](_0xe85069)[_0x4e20ec('0x683')](function(){_0x9d1b30(_0x140dad);},function(){const _0x210022=_0x4e20ec;console['log'](_0x210022('0x16b8'));});}let _0x298840=!![],_0x2f10b3=0x1;_0xbcf3b6['$watch']('vm.query.filter',function(_0x43502c,_0x3f02e8){const _0x3f70e0=_0x162de6;_0x298840?_0x220639(function(){_0x298840=![];}):(!_0x3f02e8&&(_0x2f10b3=_0x38fb01['query']['page']),_0x43502c!==_0x3f02e8&&(_0x38fb01[_0x3f70e0('0x23a2')][_0x3f70e0('0xdf8')]=0x1),!_0x43502c&&(_0x38fb01['query'][_0x3f70e0('0xdf8')]=_0x2f10b3),_0x38fb01[_0x3f70e0('0x20b8')]());});function _0x5859bf(_0x80a3e2){const _0x4f8d6a=_0x162de6;_0x38fb01[_0x4f8d6a('0x1248')]=_0x80a3e2||{'count':0x0,'rows':[]};}function _0x5162de(){const _0x171562=_0x162de6;_0x38fb01[_0x171562('0x23a2')][_0x171562('0x1cc8')]=(_0x38fb01[_0x171562('0x23a2')]['page']-0x1)*_0x38fb01[_0x171562('0x23a2')][_0x171562('0x6f0')],_0x10e0fd['hasRole'](_0x171562('0x20c2'))?_0x38fb01[_0x171562('0x1883')]=_0x27a595[_0x171562('0xa8b')][_0x171562('0x1e6e')](_0x38fb01[_0x171562('0x23a2')],_0x5859bf)[_0x171562('0xe53')]:(_0x38fb01[_0x171562('0x23a2')]['id']=_0x38fb01[_0x171562('0x2a')]['id'],_0x38fb01[_0x171562('0x23a2')]['section']='Projects',_0x38fb01[_0x171562('0x1883')]=_0x27a595[_0x171562('0x2a')][_0x171562('0x241d')](_0x38fb01[_0x171562('0x23a2')],_0x5859bf)[_0x171562('0xe53')]);}function _0x4e1abb(_0x338f66,_0x46a582){const _0x484c40=_0x162de6;_0x4854ea[_0x484c40('0x1d4')]({'controller':_0x484c40('0x16a9'),'controllerAs':'vm','templateUrl':_0x548f07,'parent':angular[_0x484c40('0x1fcc')](_0x1addea[_0x484c40('0x18e5')]),'targetEvent':_0x338f66,'clickOutsideToClose':!![],'locals':{'project':_0x46a582,'projects':_0x38fb01['projects'][_0x484c40('0xf5d')],'license':_0x38fb01[_0x484c40('0xace')],'setting':_0x38fb01[_0x484c40('0x260a')],'crudPermissions':_0x38fb01[_0x484c40('0x1134')]}});}function _0x9d1b30(_0x59c15b){const _0x5d50c3=_0x162de6;_0x27a595[_0x5d50c3('0xa8b')][_0x5d50c3('0xd7e')]({'id':_0x59c15b['id']})[_0x5d50c3('0xe53')]['then'](function(){const _0x16fecb=_0x5d50c3;_0x2e3ca0()[_0x16fecb('0x3ec')](_0x38fb01[_0x16fecb('0x1248')][_0x16fecb('0xf5d')],{'id':_0x59c15b['id']}),_0x38fb01[_0x16fecb('0x1248')][_0x16fecb('0x50d')]-=0x1,!_0x38fb01[_0x16fecb('0x1248')][_0x16fecb('0xf5d')]['length']&&_0x38fb01[_0x16fecb('0x20b8')](),_0x3e41a1[_0x16fecb('0x53')]({'title':_0x2e3ca0()[_0x16fecb('0x1e03')](_0x16fecb('0x283'))+_0x16fecb('0xbfc'),'msg':_0x59c15b['name']?_0x59c15b[_0x16fecb('0x60a')]+_0x16fecb('0x194d'):''});})[_0x5d50c3('0x130a')](function(_0x2ef7f2){const _0x2d303d=_0x5d50c3;if(_0x2ef7f2[_0x2d303d('0x5a5')]&&_0x2ef7f2[_0x2d303d('0x5a5')][_0x2d303d('0x17f')]&&_0x2ef7f2[_0x2d303d('0x5a5')][_0x2d303d('0x17f')][_0x2d303d('0x1564')]){_0x38fb01[_0x2d303d('0x17f')]=_0x2ef7f2['data']['errors']||[{'message':_0x2ef7f2[_0x2d303d('0x1ff0')](),'type':_0x2d303d('0x1565')}];for(let _0x2a7fc6=0x0;_0x2a7fc6<_0x2ef7f2[_0x2d303d('0x5a5')][_0x2d303d('0x17f')][_0x2d303d('0x1564')];_0x2a7fc6++){_0x3e41a1[_0x2d303d('0x52a')]({'title':_0x2ef7f2[_0x2d303d('0x5a5')]['errors'][_0x2a7fc6][_0x2d303d('0xcf0')],'msg':_0x2ef7f2[_0x2d303d('0x5a5')][_0x2d303d('0x17f')][_0x2a7fc6][_0x2d303d('0x8c2')]});}}else _0x3e41a1[_0x2d303d('0x52a')]({'title':_0x2ef7f2['status']?'API:'+_0x2ef7f2[_0x2d303d('0x13ee')]+_0x2d303d('0xbf6')+_0x2ef7f2['statusText']:_0x2d303d('0x1565'),'msg':_0x2ef7f2[_0x2d303d('0x5a5')]?JSON[_0x2d303d('0x258a')](_0x2ef7f2[_0x2d303d('0x5a5')][_0x2d303d('0x8c2')]):_0x2ef7f2[_0x2d303d('0x8c2')]||_0x2ef7f2[_0x2d303d('0x1ff0')]()});});}function _0x30084c(){const _0x3c1c5a=_0x162de6,_0xba5051=angular[_0x3c1c5a('0x1a86')](_0x38fb01['selectedProjects']);return _0x38fb01['selectedProjects']=[],_0xba5051;}function _0x42684a(_0xe33500){const _0xa1f0a6=_0x162de6,_0x131d5d=_0x4854ea[_0xa1f0a6('0x1c6f')]()[_0xa1f0a6('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20projects?')[_0xa1f0a6('0x26e3')](''+_0x38fb01[_0xa1f0a6('0x25e3')]['length']+'\x20selected'+_0xa1f0a6('0x1ee7'))['ariaLabel']('delete\x20Projects')[_0xa1f0a6('0xe42')](_0xe33500)['ok']('OK')[_0xa1f0a6('0x19fb')](_0xa1f0a6('0x16b8'));_0x4854ea['show'](_0x131d5d)[_0xa1f0a6('0x683')](function(){const _0x3cded3=_0xa1f0a6;_0x38fb01['selectedProjects'][_0x3cded3('0x1299')](function(_0x58332a){_0x9d1b30(_0x58332a);}),_0x38fb01[_0x3cded3('0x25e3')]=[];});}function _0x4b5c1d(){const _0x189c60=_0x162de6;_0x38fb01[_0x189c60('0x25e3')]=[];}function _0x4ce7f3(){const _0x1717de=_0x162de6;_0x38fb01[_0x1717de('0x25e3')]=_0x38fb01['projects'][_0x1717de('0xf5d')];}}const _0x1b4c78=_0x4306ba;_0x5a1401[_0x189033('0x14be')]=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x5a1401(_0x110122,_0x86e83a){const _0x2db8db=_0x189033;_0x110122[_0x2db8db('0x2598')](_0x2db8db('0xa08'),{'abstract':!![],'url':_0x2db8db('0xb75')})['state'](_0x2db8db('0x1f07'),{'url':_0x2db8db('0x150a'),'views':{'content@app':{'templateUrl':_0x320f46,'controller':_0x2db8db('0x1b14')}},'resolve':{'projects':[_0x2db8db('0x4b1'),_0x2db8db('0xba1'),function(_0x364e4f,_0x4f5e33){const _0x30605f=_0x2db8db;return _0x4f5e33[_0x30605f('0xca1')](_0x30605f('0x20c2'))?_0x364e4f[_0x30605f('0xed7')](_0x30605f('0x1c12'),{'fields':_0x30605f('0x2519'),'sort':'-updatedAt','limit':0xa,'offset':0x0}):_0x364e4f[_0x30605f('0xed7')](_0x30605f('0x191b'),{'id':_0x4f5e33['getCurrentUser']()[_0x30605f('0x2f')],'section':_0x30605f('0x25c3'),'fields':_0x30605f('0x2519'),'sort':_0x30605f('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x2db8db('0x4b1'),_0x2db8db('0xba1'),function(_0x39d098,_0x5ea4be){const _0x306183=_0x2db8db;return _0x5ea4be[_0x306183('0xca1')](_0x306183('0x20c2'))?null:_0x39d098['resolve'](_0x306183('0x1464'),{'fields':_0x306183('0x16f'),'id':_0x5ea4be[_0x306183('0x20b2')]()[_0x306183('0x2f')]});}],'userProfileSection':[_0x2db8db('0x4b1'),'Auth',function(_0x2b9ca5,_0x5d5ce8){const _0x3702a7=_0x2db8db;return _0x5d5ce8[_0x3702a7('0xca1')](_0x3702a7('0x20c2'))?null:_0x2b9ca5[_0x3702a7('0xed7')](_0x3702a7('0x360'),{'fields':_0x3702a7('0x1f47'),'userProfileId':_0x5d5ce8[_0x3702a7('0x20b2')]()['userProfileId'],'sectionId':0x6a5});}]},'authenticate':!![],'permissionId':0x6a5,'bodyClass':_0x2db8db('0x18e6')})['state'](_0x2db8db('0xe29'),{'url':_0x2db8db('0x1560'),'params':{'project':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x3c9b80,'controller':'JscriptyProjectController\x20as\x20vm'}},'resolve':{'project':[_0x2db8db('0x4b1'),_0x2db8db('0x8ea'),function(_0x13133b,_0x468790){const _0x5639d3=_0x2db8db;return _0x13133b[_0x5639d3('0xed7')](_0x5639d3('0x1c12'),{'fields':_0x5639d3('0x2519'),'id':_0x468790['id']});}],'userProfileSection':[_0x2db8db('0x4b1'),'Auth',function(_0x379ec3,_0x3c4223){const _0x50328d=_0x2db8db;return _0x379ec3[_0x50328d('0xed7')](_0x50328d('0x360'),{'fields':_0x50328d('0x1f47'),'userProfileId':_0x3c4223[_0x50328d('0x20b2')]()[_0x50328d('0x2f')],'sectionId':0x6a5});}]},'authenticate':!![],'permissionId':0x6a5,'bodyClass':'jscripty'}),_0x86e83a[_0x2db8db('0x7d2')](_0x2db8db('0x1dbc'));}angular['module'](_0x189033('0xa08'),[_0x189033('0x6cf'),_0x189033('0x1ddb'),_0x189033('0x2290'),_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),_0x189033('0x2609'),_0x189033('0x273d'),'mdPickers','mwFormBuilder',_0x189033('0x7fa'),_0x189033('0x197b'),_0x189033('0x3b5'),_0x189033('0x153a'),'ngEmbed',_0x189033('0x2645'),_0x189033('0x20c7'),'chart.js','angular.filter'])[_0x189033('0x272d')](_0x5a1401)[_0x189033('0x1da3')]('CreateOrEditProjectDialogController',_0x56ba5)[_0x189033('0x1da3')](_0x189033('0x760'),_0x40ace0)[_0x189033('0x1da3')](_0x189033('0xc67'),_0x10f9f5)[_0x189033('0x1da3')](_0x189033('0x222d'),_0x53d8a4)[_0x189033('0x1da3')](_0x189033('0xbee'),_0x52837f)[_0x189033('0x1da3')](_0x189033('0x3d0'),_0x47b7eb)[_0x189033('0x1da3')]('ShowQuestionsSessionDialogController',_0x580527)[_0x189033('0x1da3')](_0x189033('0x13d6'),_0x390ed0)[_0x189033('0x1da3')](_0x189033('0x1bcc'),_0x1b4c78);const _0x1c4ea5=_0x180212['p']+_0x189033('0x2384'),_0x157241=_0x180212['p']+_0x189033('0x143');_0x231557[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),'plugins','plugin',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x1134')];function _0x231557(_0x3624ce,_0x1a18a7,_0x1c448f,_0x59658e,_0x1e70d9,_0x3cbd5a,_0x3d8873,_0x5f0cdb,_0x188397,_0x47e5da,_0x1688a7,_0x46b926,_0x17063f,_0x130b0c){const _0x5086d0=_0x189033,_0x3e2fc0=this;_0x3e2fc0['currentUser']=_0x1688a7[_0x5086d0('0x20b2')](),_0x3e2fc0[_0x5086d0('0x17f')]=[],_0x3e2fc0['setting']=_0x17063f,_0x3e2fc0[_0x5086d0('0xace')]=_0x46b926,_0x3e2fc0[_0x5086d0('0x1134')]=_0x130b0c,_0x3e2fc0['hasModulePermissions']={},_0x3e2fc0['passwordPattern']=_0x3e2fc0[_0x5086d0('0x260a')]&&_0x3e2fc0[_0x5086d0('0x260a')][_0x5086d0('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3e2fc0[_0x5086d0('0xf28')]=_0x5086d0('0x1cad'),_0x3e2fc0['plugin']=angular[_0x5086d0('0x1a86')](_0x188397),_0x3e2fc0[_0x5086d0('0x25f3')]=_0x5f0cdb,_0x3e2fc0[_0x5086d0('0x1df1')]=![];!_0x3e2fc0[_0x5086d0('0x1cd1')]&&(_0x3e2fc0[_0x5086d0('0x1cd1')]={},_0x3e2fc0[_0x5086d0('0xf28')]=_0x5086d0('0x140d'),_0x3e2fc0[_0x5086d0('0x1df1')]=!![]);_0x3e2fc0[_0x5086d0('0x60')]=_0x314469,_0x3e2fc0[_0x5086d0('0x1259')]=_0x509871,_0x3e2fc0[_0x5086d0('0x5cf')]=_0x193e9f,_0x3e2fc0[_0x5086d0('0x16b3')]=_0x3e8082,_0x3e2fc0['closeDialog']=_0x2c4f0d;function _0x314469(){const _0x2bde10=_0x5086d0;_0x3e2fc0[_0x2bde10('0x17f')]=[],_0x47e5da['plugin'][_0x2bde10('0xb0a')](_0x3e2fc0[_0x2bde10('0x1cd1')])[_0x2bde10('0xe53')]['then'](function(_0x27227e){const _0x33099d=_0x2bde10;_0x3e2fc0[_0x33099d('0x25f3')][_0x33099d('0x1167')](_0x27227e['toJSON']()),_0x3d8873[_0x33099d('0x53')]({'title':'Plugin\x20properly\x20created','msg':_0x3e2fc0[_0x33099d('0x1cd1')][_0x33099d('0x60a')]?_0x3e2fc0['plugin']['name']+_0x33099d('0x14b5'):''}),_0x2c4f0d(_0x27227e);})[_0x2bde10('0x130a')](function(_0xdba322){const _0x196de3=_0x2bde10;if(_0xdba322[_0x196de3('0x5a5')]&&_0xdba322['data']['errors']&&_0xdba322[_0x196de3('0x5a5')][_0x196de3('0x17f')]['length']){_0x3e2fc0[_0x196de3('0x17f')]=_0xdba322[_0x196de3('0x5a5')][_0x196de3('0x17f')]||[{'message':_0xdba322[_0x196de3('0x1ff0')](),'type':'api.plugin.save'}];for(let _0x388d87=0x0;_0x388d87<_0xdba322[_0x196de3('0x5a5')][_0x196de3('0x17f')][_0x196de3('0x1564')];_0x388d87+=0x1){_0x3d8873[_0x196de3('0x52a')]({'title':_0xdba322[_0x196de3('0x5a5')]['errors'][_0x388d87][_0x196de3('0xcf0')],'msg':_0xdba322['data'][_0x196de3('0x17f')][_0x388d87][_0x196de3('0x8c2')]});}}else _0x3d8873[_0x196de3('0x52a')]({'title':_0xdba322[_0x196de3('0x13ee')]?_0x196de3('0x2168')+_0xdba322[_0x196de3('0x13ee')]+'\x20-\x20'+_0xdba322[_0x196de3('0x24a9')]:_0x196de3('0x1c52'),'msg':_0xdba322[_0x196de3('0x5a5')]?JSON[_0x196de3('0x258a')](_0xdba322['data'][_0x196de3('0x8c2')]):_0xdba322['toString']()});});}function _0x509871(){const _0x881e59=_0x5086d0;_0x3e2fc0[_0x881e59('0x17f')]=[],_0x47e5da[_0x881e59('0x1cd1')][_0x881e59('0x2480')]({'id':_0x3e2fc0[_0x881e59('0x1cd1')]['id']},_0x3e2fc0['plugin'])['$promise'][_0x881e59('0x683')](function(_0x42e6b0){const _0x193b3d=_0x881e59,_0x1fc199=_0x2e3ca0()[_0x193b3d('0x1c07')](_0x3e2fc0['plugins'],{'id':_0x42e6b0['id']});_0x1fc199&&_0x2e3ca0()[_0x193b3d('0xf22')](_0x1fc199,_0x2e3ca0()[_0x193b3d('0x24d0')](_0x42e6b0[_0x193b3d('0x24e1')](),_0x2e3ca0()['keys'](_0x1fc199))),_0x3d8873[_0x193b3d('0x53')]({'title':_0x193b3d('0x662'),'msg':_0x3e2fc0[_0x193b3d('0x1cd1')][_0x193b3d('0x60a')]?_0x3e2fc0['plugin'][_0x193b3d('0x60a')]+_0x193b3d('0xf59'):''}),_0x2c4f0d(_0x42e6b0);})['catch'](function(_0x2ed0d9){const _0x58ad99=_0x881e59;if(_0x2ed0d9[_0x58ad99('0x5a5')]&&_0x2ed0d9[_0x58ad99('0x5a5')]['errors']&&_0x2ed0d9[_0x58ad99('0x5a5')][_0x58ad99('0x17f')]['length']){_0x3e2fc0[_0x58ad99('0x17f')]=_0x2ed0d9[_0x58ad99('0x5a5')]['errors']||[{'message':_0x2ed0d9[_0x58ad99('0x1ff0')](),'type':_0x58ad99('0x419')}];for(let _0x526078=0x0;_0x526078<_0x2ed0d9[_0x58ad99('0x5a5')][_0x58ad99('0x17f')]['length'];_0x526078++){_0x3d8873[_0x58ad99('0x52a')]({'title':_0x2ed0d9[_0x58ad99('0x5a5')]['errors'][_0x526078]['type'],'msg':_0x2ed0d9[_0x58ad99('0x5a5')][_0x58ad99('0x17f')][_0x526078][_0x58ad99('0x8c2')]});}}else _0x3d8873[_0x58ad99('0x52a')]({'title':_0x2ed0d9[_0x58ad99('0x13ee')]?_0x58ad99('0x2168')+_0x2ed0d9[_0x58ad99('0x13ee')]+_0x58ad99('0xbf6')+_0x2ed0d9['statusText']:_0x58ad99('0x419'),'msg':_0x2ed0d9['data']?JSON[_0x58ad99('0x258a')](_0x2ed0d9[_0x58ad99('0x5a5')][_0x58ad99('0x8c2')]):_0x2ed0d9['toString']()});});}function _0x193e9f(_0x48a595){const _0x542403=_0x5086d0;_0x3e2fc0['errors']=[];const _0x4c22c0=_0x59658e[_0x542403('0x1c6f')]()[_0x542403('0xf28')]('Are\x20you\x20sure?')[_0x542403('0xa6a')](_0x542403('0x4e4'))[_0x542403('0x1040')](_0x542403('0x1d5e'))['ok'](_0x542403('0x2307'))[_0x542403('0x19fb')](_0x542403('0x253a'))[_0x542403('0xe42')](_0x48a595);_0x59658e['show'](_0x4c22c0)[_0x542403('0x683')](function(){const _0x4b3333=_0x542403;_0x47e5da[_0x4b3333('0x1cd1')][_0x4b3333('0xd7e')]({'id':_0x3e2fc0[_0x4b3333('0x1cd1')]['id']})[_0x4b3333('0xe53')][_0x4b3333('0x683')](function(){const _0x41f929=_0x4b3333;_0x2e3ca0()['remove'](_0x3e2fc0[_0x41f929('0x25f3')],{'id':_0x3e2fc0[_0x41f929('0x1cd1')]['id']}),_0x3d8873[_0x41f929('0x53')]({'title':_0x41f929('0x694'),'msg':(_0x3e2fc0[_0x41f929('0x1cd1')][_0x41f929('0x60a')]||_0x41f929('0x1cd1'))+_0x41f929('0x194d')}),_0x2c4f0d(_0x3e2fc0[_0x41f929('0x1cd1')]);})['catch'](function(_0x3e3515){const _0x352f3d=_0x4b3333;if(_0x3e3515['data']&&_0x3e3515[_0x352f3d('0x5a5')]['errors']&&_0x3e3515[_0x352f3d('0x5a5')][_0x352f3d('0x17f')][_0x352f3d('0x1564')]){_0x3e2fc0[_0x352f3d('0x17f')]=_0x3e3515['data'][_0x352f3d('0x17f')]||[{'message':_0x3e3515['toString'](),'type':_0x352f3d('0x26c2')}];for(let _0x2d2c59=0x0;_0x2d2c59<_0x3e3515[_0x352f3d('0x5a5')]['errors']['length'];_0x2d2c59++){_0x3d8873[_0x352f3d('0x52a')]({'title':_0x3e3515[_0x352f3d('0x5a5')][_0x352f3d('0x17f')][_0x2d2c59][_0x352f3d('0xcf0')],'msg':_0x3e3515['data'][_0x352f3d('0x17f')][_0x2d2c59][_0x352f3d('0x8c2')]});}}else _0x3d8873['error']({'title':_0x3e3515['status']?_0x352f3d('0x2168')+_0x3e3515['status']+_0x352f3d('0xbf6')+_0x3e3515[_0x352f3d('0x24a9')]:'api.plugin.delete','msg':_0x3e3515[_0x352f3d('0x5a5')]?JSON[_0x352f3d('0x258a')](_0x3e3515[_0x352f3d('0x5a5')][_0x352f3d('0x8c2')]):_0x3e3515[_0x352f3d('0x8c2')]||_0x3e3515[_0x352f3d('0x1ff0')]()});});},function(){});}function _0x3e8082(_0x384226){return _0x384226===null?undefined:new Date(_0x384226);}function _0x2c4f0d(_0x310e1b){const _0x330b6d=_0x5086d0;_0x59658e[_0x330b6d('0x1715')](_0x310e1b);}}const _0x3d1747=_0x231557;_0x328b79[_0x189033('0x14be')]=[_0x189033('0x938'),'$location',_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1'),'plugin',_0x189033('0x22df')];function _0x328b79(_0x487999,_0x5d1562,_0x4e0752,_0x29545c,_0x316608,_0x1a0dde,_0x30a43d,_0x3f8919,_0x3e9674,_0x6146de,_0x4201c6,_0x7aaea2){const _0x378f6f=_0x189033,_0x168840=this;_0x168840[_0x378f6f('0x11ed')]=_0x6146de[_0x378f6f('0x20b2')](),_0x168840['license']=_0x1a0dde,_0x168840[_0x378f6f('0x260a')]=_0x30a43d,_0x168840[_0x378f6f('0x19b2')]=_0x168840[_0x378f6f('0x260a')][_0x378f6f('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x168840['location']=_0x5d1562[_0x378f6f('0x173e')]()+_0x378f6f('0x20de')+_0x5d1562[_0x378f6f('0x19ac')](),_0x168840[_0x378f6f('0x1cd1')]=_0x4201c6||_0x487999[_0x378f6f('0x7f2')][_0x378f6f('0x1cd1')]||{},_0x168840[_0x378f6f('0x22df')]=_0x7aaea2&&_0x7aaea2['count']==0x1?_0x7aaea2[_0x378f6f('0xf5d')][0x0]:null,_0x168840['crudPermissions']=_0x6146de[_0x378f6f('0x142a')](_0x168840[_0x378f6f('0x22df')]?_0x168840[_0x378f6f('0x22df')][_0x378f6f('0x1134')]:null),_0x168840[_0x378f6f('0x258d')]={},_0x168840[_0x378f6f('0x517')]=_0x487999['params'][_0x378f6f('0x1904')]||0x0,_0x168840[_0x378f6f('0x2430')]=_0x3e9674[_0x378f6f('0x2289')],_0x168840[_0x378f6f('0x3bc')]=_0x39c2b0,_0x168840[_0x378f6f('0x1259')]=_0x3afcb6;function _0x39c2b0(){const _0x558dc9=_0x378f6f;_0x487999['go'](_0x558dc9('0x1d1a'),{},{'reload':_0x558dc9('0x1d1a')});}function _0x3afcb6(){const _0x215d08=_0x378f6f;_0x3f8919[_0x215d08('0x1cd1')]['update']({'id':_0x168840['plugin']['id']},_0x168840['plugin'])[_0x215d08('0xe53')][_0x215d08('0x683')](function(){const _0x31c396=_0x215d08;_0x3e9674['success']({'title':'Plugin\x20updated!','msg':_0x168840[_0x31c396('0x1cd1')][_0x31c396('0x60a')]?_0x168840['plugin'][_0x31c396('0x60a')]+_0x31c396('0x96c'):''});})['catch'](function(_0x24b79b){const _0x16fa77=_0x215d08;_0x3e9674[_0x16fa77('0x52a')]({'title':_0x24b79b[_0x16fa77('0x13ee')]?_0x16fa77('0x2168')+_0x24b79b[_0x16fa77('0x13ee')]+'\x20-\x20'+_0x24b79b['statusText']:'SYSTEM:GETplugin','msg':_0x24b79b[_0x16fa77('0x5a5')]?JSON[_0x16fa77('0x258a')](_0x24b79b['data']):_0x24b79b[_0x16fa77('0x1ff0')]()});});}}const _0x1187a1=_0x328b79,_0x19d9b7=_0x180212['p']+'src/js/modules/main/apps/marketplace/views/plugins/create/dialog.html/dialog.html',_0x3d748e=_0x180212['p']+'src/js/modules/main/apps/marketplace/views/plugins/upload/dialog.html/dialog.html';_0x711077[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),'$mdSidenav','$mdDialog',_0x189033('0x16ea'),_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x25f3'),_0x189033('0x2a'),_0x189033('0x22df'),'api','msUtils',_0x189033('0x1d70'),'Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x711077(_0xdbecbb,_0x1e4962,_0x32e04f,_0x288f28,_0x4d074f,_0x3b4919,_0x1b2c97,_0x48a2e8,_0xede89d,_0x455d1a,_0xcc7b7f,_0x6916ca,_0x4a9528,_0x161c7e,_0x596c95,_0x217fac,_0x4d7830){const _0x31e017=_0x189033,_0x3ca738=this;_0x3ca738['license']=_0x217fac,_0x3ca738[_0x31e017('0x260a')]=_0x4d7830,_0x3ca738[_0x31e017('0x11ed')]=_0x596c95[_0x31e017('0x20b2')](),_0x3ca738[_0x31e017('0x25f3')]=_0xede89d||{'count':0x0,'rows':[]},_0x3ca738['userProfile']=_0x455d1a,_0x3ca738[_0x31e017('0x22df')]=_0xcc7b7f&&_0xcc7b7f['count']==0x1?_0xcc7b7f[_0x31e017('0xf5d')][0x0]:null,_0x3ca738[_0x31e017('0x1134')]=_0x596c95[_0x31e017('0x142a')](_0x3ca738[_0x31e017('0x22df')]?_0x3ca738['userProfileSection'][_0x31e017('0x1134')]:null),_0x3ca738[_0x31e017('0x5c4')]=_0x31e017('0x25f3'),_0x3ca738[_0x31e017('0x247')]='',_0x3ca738[_0x31e017('0x1ce2')]=null,_0x3ca738[_0x31e017('0xfcf')]=[],_0x3ca738[_0x31e017('0x23a2')]={'fields':'createdAt,updatedAt,id,name,type,active,description,icon,sidebar,path,adminUrl,agentUrl,scriptName,scriptPath,version','sort':'name','limit':0xa,'page':0x1},_0x3ca738[_0x31e017('0x1bc8')]=![],_0x3ca738[_0x31e017('0x16e1')]=_0x2e3ca0()['keyBy']([{'option':_0x31e017('0x1023'),'value':_0x31e017('0x6c7')},{'option':'Admin\x20Only','value':_0x31e017('0x2825')},{'option':_0x31e017('0x1b33'),'value':'\x27agentOnly\x27'},{'option':'Never','value':_0x31e017('0xd77')}],function(_0x4b632d){const _0x95db90=_0x31e017;return _0x2e3ca0()['replace'](_0x4b632d[_0x95db90('0x1c6b')],new RegExp('\x27','g'),'');}),_0x3ca738[_0x31e017('0x3b2')]=_0x3963c9,_0x3ca738['editstate']=_0xd55577,_0x3ca738[_0x31e017('0x22e4')]=_0x6e1e01,_0x3ca738[_0x31e017('0x1b7f')]=_0x4a9d0,_0x3ca738[_0x31e017('0x29d')]=_0x55d345,_0x3ca738[_0x31e017('0x9be')]=_0x14402f,_0x3ca738[_0x31e017('0x194f')]=_0x1211f3,_0x3ca738[_0x31e017('0x53')]=_0x22a3dd,_0x3ca738[_0x31e017('0x79a')]=_0x50a172,_0x3ca738[_0x31e017('0xc27')]=_0x137a14,_0x3ca738[_0x31e017('0x5cf')]=_0x16e94b,_0x3ca738[_0x31e017('0x158')]=_0x48efb1,_0x3ca738[_0x31e017('0x19d4')]=_0x5e0a01,_0x3ca738[_0x31e017('0x5df')]=_0x131b60,_0x3ca738['selectAllPlugins']=_0x2ef318,_0x3ca738[_0x31e017('0xdd3')]=_0x1a43e5;function _0x3963c9(_0x11c1c5){const _0x123724=_0x31e017;if(_0x11c1c5[_0x123724('0xcf0')]==='script')_0x3ca738[_0x123724('0x1bc8')]=!![],_0x6916ca[_0x123724('0x2c2')][_0x123724('0xb0a')]({'name':_0x11c1c5[_0x123724('0x88c')],'script':_0x11c1c5[_0x123724('0x210f')]+'/'+_0x11c1c5[_0x123724('0x277c')]})['$promise']['then'](function(){const _0x5a03dc=_0x123724;return _0x11c1c5['active']=!![],_0x6916ca[_0x5a03dc('0x1cd1')][_0x5a03dc('0x2480')]({'id':_0x11c1c5['id']},_0x11c1c5)[_0x5a03dc('0xe53')];})[_0x123724('0x683')](function(){const _0x35ed66=_0x123724;_0x3ca738['installing']=![],_0x161c7e[_0x35ed66('0x53')]({'title':'Plugin\x20installed!','msg':_0x11c1c5[_0x35ed66('0x60a')]?_0x11c1c5[_0x35ed66('0x60a')]+'\x20has\x20been\x20installed!':''});})[_0x123724('0x130a')](function(_0x24aaf7){const _0x419b73=_0x123724;if(_0x24aaf7[_0x419b73('0x5a5')]&&_0x24aaf7[_0x419b73('0x5a5')][_0x419b73('0x17f')]&&_0x24aaf7[_0x419b73('0x5a5')][_0x419b73('0x17f')][_0x419b73('0x1564')]){_0x3ca738[_0x419b73('0x17f')]=_0x24aaf7[_0x419b73('0x5a5')][_0x419b73('0x17f')]||[{'message':_0x24aaf7[_0x419b73('0x1ff0')](),'type':_0x419b73('0xdbc')}];for(let _0x308d83=0x0;_0x308d83<_0x24aaf7[_0x419b73('0x5a5')][_0x419b73('0x17f')]['length'];_0x308d83++){_0x161c7e[_0x419b73('0x52a')]({'title':_0x24aaf7[_0x419b73('0x5a5')][_0x419b73('0x17f')][_0x308d83]['type'],'msg':_0x24aaf7[_0x419b73('0x5a5')][_0x419b73('0x17f')][_0x308d83][_0x419b73('0x8c2')]});}}else _0x161c7e[_0x419b73('0x52a')]({'title':_0x24aaf7['status']?_0x419b73('0x2168')+_0x24aaf7['status']+_0x419b73('0xbf6')+_0x24aaf7['statusText']:'api.pm2.save','msg':_0x24aaf7[_0x419b73('0x5a5')]?JSON[_0x419b73('0x258a')](_0x24aaf7['data'][_0x419b73('0x8c2')]):_0x24aaf7['message']||_0x24aaf7[_0x419b73('0x1ff0')]()});});else return _0x11c1c5['active']=!![],_0x6916ca[_0x123724('0x1cd1')]['update']({'id':_0x11c1c5['id']},_0x11c1c5)['$promise'][_0x123724('0x683')](function(){const _0x580d53=_0x123724;_0x161c7e[_0x580d53('0x53')]({'title':_0x580d53('0x117f'),'msg':_0x11c1c5['name']?_0x11c1c5[_0x580d53('0x60a')]+_0x580d53('0x1a61'):''});})[_0x123724('0x130a')](function(_0xcec2d5){const _0x346e3c=_0x123724;if(_0xcec2d5[_0x346e3c('0x5a5')]&&_0xcec2d5[_0x346e3c('0x5a5')][_0x346e3c('0x17f')]&&_0xcec2d5[_0x346e3c('0x5a5')][_0x346e3c('0x17f')][_0x346e3c('0x1564')]){_0x3ca738[_0x346e3c('0x17f')]=_0xcec2d5['data']['errors']||[{'message':_0xcec2d5[_0x346e3c('0x1ff0')](),'type':'api.plugin.update'}];for(let _0x151e90=0x0;_0x151e90<_0xcec2d5[_0x346e3c('0x5a5')][_0x346e3c('0x17f')][_0x346e3c('0x1564')];_0x151e90++){_0x161c7e[_0x346e3c('0x52a')]({'title':_0xcec2d5['data']['errors'][_0x151e90]['type'],'msg':_0xcec2d5['data'][_0x346e3c('0x17f')][_0x151e90]['message']});}}else _0x161c7e[_0x346e3c('0x52a')]({'title':_0xcec2d5[_0x346e3c('0x13ee')]?_0x346e3c('0x2168')+_0xcec2d5[_0x346e3c('0x13ee')]+_0x346e3c('0xbf6')+_0xcec2d5[_0x346e3c('0x24a9')]:'api.plugin.update','msg':_0xcec2d5[_0x346e3c('0x5a5')]?JSON[_0x346e3c('0x258a')](_0xcec2d5[_0x346e3c('0x5a5')]['message']):_0xcec2d5[_0x346e3c('0x8c2')]||_0xcec2d5[_0x346e3c('0x1ff0')]()});});}function _0xd55577(_0x3b0e4f){const _0x52b863=_0x31e017;_0x32e04f['go']('app.marketplace.plugins.edit',{'id':_0x3b0e4f['id'],'plugin':_0x3b0e4f,'crudPermissions':_0x3ca738[_0x52b863('0x1134')]});}function _0x6e1e01(_0x4a06d6,_0x4b4838){const _0x5cf29f=_0x31e017,_0x5055a2=_0x4d074f[_0x5cf29f('0x1c6f')]()[_0x5cf29f('0xf28')](_0x5cf29f('0x1260'))[_0x5cf29f('0x26e3')](''+(_0x4a06d6[_0x5cf29f('0x60a')]||_0x5cf29f('0x1cd1'))+''+_0x5cf29f('0x1437'))[_0x5cf29f('0x1040')](_0x5cf29f('0x1140'))['targetEvent'](_0x4b4838)['ok']('OK')[_0x5cf29f('0x19fb')](_0x5cf29f('0x16b8'));_0x4d074f[_0x5cf29f('0x1d4')](_0x5055a2)[_0x5cf29f('0x683')](function(){_0x6a2f03(_0x4a06d6);},function(){const _0x57a491=_0x5cf29f;console[_0x57a491('0x1b2b')](_0x57a491('0x16b8'));});}function _0x6a2f03(_0x18fe79){const _0x36e583=_0x31e017;_0x6916ca[_0x36e583('0x2c2')][_0x36e583('0x1e6e')]()[_0x36e583('0xe53')][_0x36e583('0x683')](function(_0x4a43fb){const _0x51423f=_0x36e583;if(!_0x4a43fb||!_0x4a43fb[_0x51423f('0xf5d')])throw new Error(_0x51423f('0x3d'));const _0xc71753=_0x2e3ca0()[_0x51423f('0x1c07')](_0x4a43fb[_0x51423f('0xf5d')],{'name':_0x18fe79[_0x51423f('0x88c')]});if(!_0xc71753)throw new Error('No\x20corresponding\x20process\x20found');_0x6916ca[_0x51423f('0x2c2')][_0x51423f('0x2480')]({'id':_0xc71753[_0x51423f('0x2401')],'status':'stopped'})[_0x51423f('0xe53')][_0x51423f('0x683')](function(){const _0x19eab5=_0x51423f;_0x161c7e[_0x19eab5('0x53')]({'title':_0x19eab5('0x25fb'),'msg':_0x19eab5('0x160a')});});})['catch'](function(_0x1cbad3){const _0x5df066=_0x36e583;if(_0x1cbad3['data']&&_0x1cbad3[_0x5df066('0x5a5')]['errors']&&_0x1cbad3[_0x5df066('0x5a5')][_0x5df066('0x17f')][_0x5df066('0x1564')]){_0x3ca738[_0x5df066('0x17f')]=_0x1cbad3[_0x5df066('0x5a5')][_0x5df066('0x17f')]||[{'message':_0x1cbad3[_0x5df066('0x1ff0')](),'type':_0x5df066('0x2b8')}];for(let _0x1b7742=0x0;_0x1b7742<_0x1cbad3['data']['errors'][_0x5df066('0x1564')];_0x1b7742++){_0x161c7e[_0x5df066('0x52a')]({'title':_0x1cbad3[_0x5df066('0x5a5')][_0x5df066('0x17f')][_0x1b7742][_0x5df066('0xcf0')],'msg':_0x1cbad3[_0x5df066('0x5a5')]['errors'][_0x1b7742]['message']});}}else _0x161c7e['error']({'title':_0x1cbad3[_0x5df066('0x13ee')]?_0x5df066('0x2168')+_0x1cbad3[_0x5df066('0x13ee')]+_0x5df066('0xbf6')+_0x1cbad3['statusText']:_0x5df066('0x2b8'),'msg':_0x1cbad3[_0x5df066('0x5a5')]?JSON[_0x5df066('0x258a')](_0x1cbad3['data']['message']):_0x1cbad3['message']||_0x1cbad3[_0x5df066('0x1ff0')]()});});}function _0x4a9d0(_0x4d38d1,_0x50c5fa){const _0x4deeaf=_0x31e017,_0x33e919=_0x4d074f['confirm']()[_0x4deeaf('0xf28')](_0x4deeaf('0x2322'))[_0x4deeaf('0x26e3')](''+(_0x4d38d1['name']||_0x4deeaf('0x1cd1'))+_0x4deeaf('0x20f1')+_0x4deeaf('0x19cd'))[_0x4deeaf('0x1040')](_0x4deeaf('0x1fd9'))[_0x4deeaf('0xe42')](_0x50c5fa)['ok']('OK')[_0x4deeaf('0x19fb')](_0x4deeaf('0x16b8'));_0x4d074f[_0x4deeaf('0x1d4')](_0x33e919)['then'](function(){_0x1392d6(_0x4d38d1);},function(){const _0x49ec01=_0x4deeaf;console['log'](_0x49ec01('0x16b8'));});}function _0x1392d6(_0x1840a7){const _0xa165dc=_0x31e017;_0x6916ca[_0xa165dc('0x2c2')][_0xa165dc('0x1e6e')]()[_0xa165dc('0xe53')][_0xa165dc('0x683')](function(_0x57bcf8){const _0x52dc39=_0xa165dc;if(!_0x57bcf8||!_0x57bcf8['rows'])throw new Error('Failed\x20to\x20retrieve\x20pm2\x20processes');const _0x34b420=_0x2e3ca0()[_0x52dc39('0x1c07')](_0x57bcf8[_0x52dc39('0xf5d')],{'name':_0x1840a7[_0x52dc39('0x88c')]});if(!_0x34b420)throw new Error(_0x52dc39('0x1c7b'));_0x6916ca[_0x52dc39('0x2c2')][_0x52dc39('0x2480')]({'id':_0x34b420[_0x52dc39('0x2401')],'status':_0x52dc39('0x2309')})['$promise'][_0x52dc39('0x683')](function(){const _0xf28c6=_0x52dc39;_0x161c7e[_0xf28c6('0x53')]({'title':_0xf28c6('0x1173'),'msg':_0xf28c6('0xbdd')});});})[_0xa165dc('0x130a')](function(_0x209841){const _0x4bfcda=_0xa165dc;if(_0x209841[_0x4bfcda('0x5a5')]&&_0x209841[_0x4bfcda('0x5a5')][_0x4bfcda('0x17f')]&&_0x209841[_0x4bfcda('0x5a5')]['errors'][_0x4bfcda('0x1564')]){_0x3ca738[_0x4bfcda('0x17f')]=_0x209841[_0x4bfcda('0x5a5')]['errors']||[{'message':_0x209841[_0x4bfcda('0x1ff0')](),'type':_0x4bfcda('0x2b8')}];for(let _0x345575=0x0;_0x345575<_0x209841[_0x4bfcda('0x5a5')][_0x4bfcda('0x17f')][_0x4bfcda('0x1564')];_0x345575++){_0x161c7e['error']({'title':_0x209841[_0x4bfcda('0x5a5')][_0x4bfcda('0x17f')][_0x345575]['type'],'msg':_0x209841[_0x4bfcda('0x5a5')][_0x4bfcda('0x17f')][_0x345575][_0x4bfcda('0x8c2')]});}}else _0x161c7e['error']({'title':_0x209841[_0x4bfcda('0x13ee')]?_0x4bfcda('0x2168')+_0x209841[_0x4bfcda('0x13ee')]+_0x4bfcda('0xbf6')+_0x209841[_0x4bfcda('0x24a9')]:_0x4bfcda('0x2b8'),'msg':_0x209841[_0x4bfcda('0x5a5')]?JSON['stringify'](_0x209841[_0x4bfcda('0x5a5')][_0x4bfcda('0x8c2')]):_0x209841[_0x4bfcda('0x8c2')]||_0x209841['toString']()});});}function _0x55d345(_0x35e832){const _0x3b4e80=_0x31e017;return _0x6916ca[_0x3b4e80('0x1cd1')][_0x3b4e80('0x18e8')]({'id':_0x35e832['id']})[_0x3b4e80('0xe53')][_0x3b4e80('0x683')](function(_0x1d7116){const _0x4347c8=_0x3b4e80,_0x1077ab=[_0x1d7116[_0x4347c8('0x1fb3')]];let _0x594aa4=_0x4347c8('0x18e8');const _0x3bc1b2=new Blob(_0x1077ab,{'type':_0x1d7116[_0x4347c8('0xcf0')]});_0x594aa4=_0x35e832[_0x4347c8('0x60a')][_0x4347c8('0x1725')]('\x20','_')[_0x4347c8('0x93a')]()+'.zip';const _0x43db1b=window[_0x4347c8('0x12e1')]['createElement']('a');_0x43db1b['setAttribute']('href',URL['createObjectURL'](_0x3bc1b2)),_0x43db1b[_0x4347c8('0x130f')](_0x4347c8('0x18e8'),_0x594aa4),document[_0x4347c8('0x18e5')][_0x4347c8('0x1e43')](_0x43db1b),_0x43db1b[_0x4347c8('0x1d42')]();})[_0x3b4e80('0x130a')](function(_0x421311){const _0x45c643=_0x3b4e80;if(_0x421311[_0x45c643('0x5a5')]&&_0x421311['data']['errors']&&_0x421311['data']['errors'][_0x45c643('0x1564')])for(let _0xbd1acc=0x0;_0xbd1acc<_0x421311['data'][_0x45c643('0x17f')][_0x45c643('0x1564')];_0xbd1acc++){_0x161c7e['error']({'title':_0x421311[_0x45c643('0x5a5')][_0x45c643('0x17f')][_0xbd1acc][_0x45c643('0xcf0')],'msg':_0x421311[_0x45c643('0x5a5')][_0x45c643('0x17f')][_0xbd1acc][_0x45c643('0x8c2')]});}else _0x161c7e[_0x45c643('0x52a')]({'title':_0x421311[_0x45c643('0x13ee')]?'API:'+_0x421311[_0x45c643('0x13ee')]+_0x45c643('0xbf6')+_0x421311[_0x45c643('0x24a9')]:_0x45c643('0x1c52'),'msg':_0x421311['data']?JSON[_0x45c643('0x258a')](_0x421311[_0x45c643('0x5a5')][_0x45c643('0x8c2')]):_0x421311[_0x45c643('0x1ff0')]()});});}function _0x14402f(_0x5869b5,_0x512a47){const _0x5c9e07=_0x31e017,_0x4acdaf=_0x4d074f['confirm']()[_0x5c9e07('0xf28')](_0x5c9e07('0x380'))[_0x5c9e07('0x26e3')](_0x5c9e07('0xed5')+(_0x5869b5[_0x5c9e07('0x60a')]||_0x5c9e07('0x1cd1'))+_0x5c9e07('0x20f1')+'\x20will\x20be\x20uninstalled.')['ariaLabel']('uninstall\x20plugin')[_0x5c9e07('0xe42')](_0x512a47)['ok']('OK')[_0x5c9e07('0x19fb')]('CANCEL');_0x4d074f[_0x5c9e07('0x1d4')](_0x4acdaf)[_0x5c9e07('0x683')](function(){_0x52e286(_0x5869b5);},function(){const _0x22e7b7=_0x5c9e07;console[_0x22e7b7('0x1b2b')](_0x22e7b7('0x16b8'));});}function _0x52e286(_0x4c9863){const _0x5d5dda=_0x31e017;return _0x4c9863[_0x5d5dda('0xcf0')]===_0x5d5dda('0x149e')&&_0x6916ca[_0x5d5dda('0x2c2')][_0x5d5dda('0x1e6e')]()['$promise']['then'](function(_0x2ba7b4){const _0x23947a=_0x5d5dda;if(!_0x2ba7b4||!_0x2ba7b4['rows'])throw new Error(_0x23947a('0x3d'));const _0x58902f=_0x2e3ca0()['find'](_0x2ba7b4[_0x23947a('0xf5d')],{'name':_0x4c9863[_0x23947a('0x88c')]});if(!_0x58902f)throw new Error(_0x23947a('0x1c7b'));_0x6916ca['pm2'][_0x23947a('0xd7e')]({'id':_0x58902f[_0x23947a('0x2401')],'name':_0x4c9863[_0x23947a('0x88c')]})['$promise'];})[_0x5d5dda('0x130a')](function(_0x32a22e){const _0x125df6=_0x5d5dda;_0x161c7e[_0x125df6('0x52a')]({'title':_0x32a22e[_0x125df6('0x13ee')]?'API:'+_0x32a22e[_0x125df6('0x13ee')]+_0x125df6('0xbf6')+_0x32a22e['statusText']:'api.pm2.delete','msg':_0x32a22e[_0x125df6('0x5a5')]?JSON['stringify'](_0x32a22e[_0x125df6('0x5a5')]['message']):_0x32a22e['message']||_0x32a22e[_0x125df6('0x1ff0')]()});}),_0x4c9863[_0x5d5dda('0x357')]=![],_0x6916ca['plugin'][_0x5d5dda('0x2480')]({'id':_0x4c9863['id']},_0x4c9863)[_0x5d5dda('0xe53')]['then'](function(){const _0x3cff4d=_0x5d5dda;_0x161c7e[_0x3cff4d('0x53')]({'title':_0x3cff4d('0x1fef'),'msg':_0x4c9863['name']?_0x4c9863['name']+_0x3cff4d('0x279e'):''});})['catch'](function(_0x2d8b82){const _0x182c12=_0x5d5dda;if(_0x2d8b82[_0x182c12('0x5a5')]&&_0x2d8b82[_0x182c12('0x5a5')][_0x182c12('0x17f')]&&_0x2d8b82[_0x182c12('0x5a5')][_0x182c12('0x17f')][_0x182c12('0x1564')]){_0x3ca738[_0x182c12('0x17f')]=_0x2d8b82['data'][_0x182c12('0x17f')]||[{'message':_0x2d8b82[_0x182c12('0x1ff0')](),'type':'api.plugin.update'}];for(let _0x3bf3d6=0x0;_0x3bf3d6<_0x2d8b82[_0x182c12('0x5a5')][_0x182c12('0x17f')]['length'];_0x3bf3d6++){_0x161c7e['error']({'title':_0x2d8b82[_0x182c12('0x5a5')][_0x182c12('0x17f')][_0x3bf3d6]['type'],'msg':_0x2d8b82[_0x182c12('0x5a5')][_0x182c12('0x17f')][_0x3bf3d6][_0x182c12('0x8c2')]});}}else _0x161c7e[_0x182c12('0x52a')]({'title':_0x2d8b82[_0x182c12('0x13ee')]?_0x182c12('0x2168')+_0x2d8b82[_0x182c12('0x13ee')]+_0x182c12('0xbf6')+_0x2d8b82[_0x182c12('0x24a9')]:_0x182c12('0x419'),'msg':_0x2d8b82[_0x182c12('0x5a5')]?JSON[_0x182c12('0x258a')](_0x2d8b82[_0x182c12('0x5a5')][_0x182c12('0x8c2')]):_0x2d8b82[_0x182c12('0x8c2')]||_0x2d8b82[_0x182c12('0x1ff0')]()});});}function _0x1211f3(_0x26324,_0x55ade9){const _0x2614e1=_0x31e017,_0x3e5250=_0x4d074f[_0x2614e1('0x1c6f')]()[_0x2614e1('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x2614e1('0x1e03')](_0x2614e1('0x1cd1'))+'?')[_0x2614e1('0x26e3')](_0x2614e1('0xed5')+(_0x26324[_0x2614e1('0x60a')]||_0x2614e1('0x1cd1'))+_0x2614e1('0x20f1')+_0x2614e1('0x1ee7'))['ariaLabel']('delete\x20plugin')[_0x2614e1('0xe42')](_0x55ade9)['ok']('OK')[_0x2614e1('0x19fb')](_0x2614e1('0x16b8'));_0x4d074f[_0x2614e1('0x1d4')](_0x3e5250)[_0x2614e1('0x683')](function(){_0x16e94b(_0x26324);},function(){const _0x52242c=_0x2614e1;console[_0x52242c('0x1b2b')](_0x52242c('0x16b8'));});}let _0x32fa35=!![],_0x43b58b=0x1;_0xdbecbb[_0x31e017('0x186d')](_0x31e017('0x1e1d'),function(_0xf776ca,_0x1a1c0c){const _0x4f65c4=_0x31e017;_0x32fa35?_0x1b2c97(function(){_0x32fa35=![];}):(!_0x1a1c0c&&(_0x43b58b=_0x3ca738[_0x4f65c4('0x23a2')][_0x4f65c4('0xdf8')]),_0xf776ca!==_0x1a1c0c&&(_0x3ca738[_0x4f65c4('0x23a2')]['page']=0x1),!_0xf776ca&&(_0x3ca738[_0x4f65c4('0x23a2')][_0x4f65c4('0xdf8')]=_0x43b58b),_0x3ca738[_0x4f65c4('0x79a')]());});function _0x22a3dd(_0x166eb7){_0x3ca738['plugins']=_0x166eb7||{'count':0x0,'rows':[]};}function _0x50a172(){const _0x409d67=_0x31e017;_0x3ca738[_0x409d67('0x23a2')][_0x409d67('0x1cc8')]=(_0x3ca738[_0x409d67('0x23a2')][_0x409d67('0xdf8')]-0x1)*_0x3ca738[_0x409d67('0x23a2')][_0x409d67('0x6f0')],_0x596c95['hasRole'](_0x409d67('0x20c2'))?_0x3ca738['promise']=_0x6916ca['plugin'][_0x409d67('0x1e6e')](_0x3ca738[_0x409d67('0x23a2')],_0x22a3dd)[_0x409d67('0xe53')]:(_0x3ca738['query']['id']=_0x3ca738['userProfile']['id'],_0x3ca738['query']['section']=_0x409d67('0x145b'),_0x3ca738[_0x409d67('0x1883')]=_0x6916ca[_0x409d67('0x2a')][_0x409d67('0x241d')](_0x3ca738[_0x409d67('0x23a2')],_0x22a3dd)[_0x409d67('0xe53')]);}function _0x137a14(_0x5efeed,_0x8e0ea){const _0x5cf67f=_0x31e017;_0x4d074f[_0x5cf67f('0x1d4')]({'controller':_0x5cf67f('0x13e3'),'controllerAs':'vm','templateUrl':_0x19d9b7,'parent':angular[_0x5cf67f('0x1fcc')](_0x3b4919['body']),'targetEvent':_0x5efeed,'clickOutsideToClose':!![],'locals':{'plugin':_0x8e0ea,'plugins':_0x3ca738[_0x5cf67f('0x25f3')]['rows'],'license':_0x3ca738[_0x5cf67f('0xace')],'setting':_0x3ca738[_0x5cf67f('0x260a')],'crudPermissions':_0x3ca738[_0x5cf67f('0x1134')]}});}function _0x16e94b(_0x82854d){const _0x114d76=_0x31e017;_0x82854d[_0x114d76('0x357')]&&_0x82854d[_0x114d76('0xcf0')]==_0x114d76('0x149e')&&_0x6916ca[_0x114d76('0x2c2')][_0x114d76('0x1e6e')]()[_0x114d76('0xe53')][_0x114d76('0x683')](function(_0x42bad0){const _0x361fa4=_0x114d76;if(!_0x42bad0||!_0x42bad0[_0x361fa4('0xf5d')])return _0x161c7e[_0x361fa4('0x52a')]({'title':_0x361fa4('0x1871'),'msg':_0x361fa4('0x3d')});const _0x572762=_0x2e3ca0()['find'](_0x42bad0['rows'],{'name':_0x82854d[_0x361fa4('0x88c')]});if(!_0x572762){console[_0x361fa4('0x1b2b')](_0x361fa4('0x25fd'),_0x82854d[_0x361fa4('0x88c')]);return;}_0x6916ca[_0x361fa4('0x2c2')][_0x361fa4('0xd7e')]({'id':_0x572762[_0x361fa4('0x2401')],'name':_0x82854d[_0x361fa4('0x88c')]})['$promise'];})[_0x114d76('0x130a')](function(){const _0x5be3f0=_0x114d76;return _0x161c7e['error']({'title':_0x5be3f0('0x27e'),'msg':'Failed\x20to\x20delete\x20the\x20attached\x20pm2\x20process'});}),_0x6916ca['plugin'][_0x114d76('0xd7e')]({'id':_0x82854d['id']})[_0x114d76('0xe53')]['then'](function(){const _0x19509f=_0x114d76;_0x2e3ca0()['remove'](_0x3ca738[_0x19509f('0x25f3')]['rows'],{'id':_0x82854d['id']}),_0x3ca738[_0x19509f('0x25f3')][_0x19509f('0x50d')]-=0x1,!_0x3ca738['plugins'][_0x19509f('0xf5d')]['length']&&_0x3ca738[_0x19509f('0x79a')](),_0x161c7e[_0x19509f('0x53')]({'title':_0x2e3ca0()[_0x19509f('0x1e03')](_0x19509f('0x2019'))+_0x19509f('0xbfc'),'msg':_0x82854d['name']?_0x82854d[_0x19509f('0x60a')]+_0x19509f('0x194d'):''});})[_0x114d76('0x130a')](function(_0x333284){const _0x452bf3=_0x114d76;if(_0x333284[_0x452bf3('0x5a5')]&&_0x333284[_0x452bf3('0x5a5')][_0x452bf3('0x17f')]&&_0x333284['data']['errors']['length']){_0x3ca738[_0x452bf3('0x17f')]=_0x333284[_0x452bf3('0x5a5')][_0x452bf3('0x17f')]||[{'message':_0x333284[_0x452bf3('0x1ff0')](),'type':_0x452bf3('0x1b0f')}];for(let _0x282529=0x0;_0x282529<_0x333284[_0x452bf3('0x5a5')][_0x452bf3('0x17f')][_0x452bf3('0x1564')];_0x282529++){_0x161c7e[_0x452bf3('0x52a')]({'title':_0x333284[_0x452bf3('0x5a5')][_0x452bf3('0x17f')][_0x282529][_0x452bf3('0xcf0')],'msg':_0x333284[_0x452bf3('0x5a5')][_0x452bf3('0x17f')][_0x282529][_0x452bf3('0x8c2')]});}}else _0x161c7e[_0x452bf3('0x52a')]({'title':_0x333284[_0x452bf3('0x13ee')]?_0x452bf3('0x2168')+_0x333284[_0x452bf3('0x13ee')]+_0x452bf3('0xbf6')+_0x333284[_0x452bf3('0x24a9')]:'SYSTEM:DELETEplugin','msg':_0x333284[_0x452bf3('0x5a5')]?JSON[_0x452bf3('0x258a')](_0x333284['data'][_0x452bf3('0x8c2')]):_0x333284[_0x452bf3('0x8c2')]||_0x333284[_0x452bf3('0x1ff0')]()});});}function _0x48efb1(){const _0x1ef66f=_0x31e017,_0x2761b9=angular['copy'](_0x3ca738[_0x1ef66f('0xfcf')]);return _0x3ca738[_0x1ef66f('0xfcf')]=[],_0x2761b9;}function _0x5e0a01(_0x324edc){const _0x35d1e3=_0x31e017,_0xa2cb31=_0x4d074f[_0x35d1e3('0x1c6f')]()[_0x35d1e3('0xf28')](_0x35d1e3('0x1187'))[_0x35d1e3('0x26e3')](''+_0x3ca738[_0x35d1e3('0xfcf')][_0x35d1e3('0x1564')]+_0x35d1e3('0x93c')+_0x35d1e3('0x1ee7'))[_0x35d1e3('0x1040')](_0x35d1e3('0x20e9'))[_0x35d1e3('0xe42')](_0x324edc)['ok']('OK')['cancel']('CANCEL');_0x4d074f[_0x35d1e3('0x1d4')](_0xa2cb31)[_0x35d1e3('0x683')](function(){const _0x588eb8=_0x35d1e3;_0x3ca738[_0x588eb8('0xfcf')][_0x588eb8('0x1299')](function(_0xdfe1d9){_0x16e94b(_0xdfe1d9);}),_0x3ca738[_0x588eb8('0xfcf')]=[];});}function _0x131b60(){const _0x4a5261=_0x31e017;_0x3ca738[_0x4a5261('0xfcf')]=[];}function _0x2ef318(){const _0x15a1ad=_0x31e017;_0x3ca738['selectedPlugins']=_0x3ca738[_0x15a1ad('0x25f3')][_0x15a1ad('0xf5d')];}function _0x1a43e5(_0xb69367){const _0x12df0c=_0x31e017;_0x4d074f['show']({'controller':_0x12df0c('0x900'),'controllerAs':'vm','templateUrl':_0x3d748e,'parent':angular[_0x12df0c('0x1fcc')](_0x3b4919['body']),'targetEvent':_0xb69367,'clickOutsideToClose':!![],'locals':{'plugins':_0x3ca738[_0x12df0c('0x25f3')][_0x12df0c('0xf5d')]}});}}const _0x41e5cd=_0x711077;_0x848329[_0x189033('0x14be')]=[_0x189033('0x17e4'),_0x189033('0x1e48'),'toasty',_0x189033('0x25f3'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x848329(_0x29338e,_0x281238,_0x24558d,_0x884c1b,_0x7f50fd,_0x241296){const _0x2d5841=_0x189033,_0x68f0bb=this,_0x4ea5a2=0x2,_0x27af82=_0x4ea5a2*0x400*0x400;_0x68f0bb[_0x2d5841('0x11ed')]=_0x241296['getCurrentUser'](),_0x68f0bb['errors']=[],_0x68f0bb['title']=_0x2d5841('0x286b'),_0x68f0bb[_0x2d5841('0x25f3')]=_0x884c1b,_0x68f0bb['uploadPlugins']=[],_0x68f0bb[_0x2d5841('0x27d5')]='none',_0x68f0bb['plugin']={},_0x68f0bb['ngFlowOptions']={'maxChunkRetries':0x1,'chunkSize':_0x27af82,'simultaneousUploads':0x1,'testChunks':![],'progressCallbacksInterval':0x3e8,'allowDuplicateUploads':!![],'target':_0x2d5841('0x6c9')},_0x68f0bb['ngFlow']={'flow':{}},_0x68f0bb[_0x2d5841('0xfbe')]=![],_0x68f0bb[_0x2d5841('0x1aad')]=_0x21d786,_0x68f0bb['upload']=_0x377f43,_0x68f0bb[_0x2d5841('0x1152')]=_0x54724c,_0x68f0bb['uploadError']=_0x494ac8,_0x68f0bb[_0x2d5841('0xddc')]=_0x503854,_0x68f0bb[_0x2d5841('0xf82')]=_0x251bbb;function _0x21d786(_0x3cc543){const _0x1c51bf=_0x2d5841,_0x277087=['zip'];if(!_0x2e3ca0()[_0x1c51bf('0x2292')](_0x277087,_0x3cc543[_0x1c51bf('0x1197')]()))return _0x24558d[_0x1c51bf('0x52a')]({'title':'Invalid\x20extension:\x20'+_0x3cc543[_0x1c51bf('0x1197')](),'msg':_0x1c51bf('0x2560')+_0x277087[_0x1c51bf('0x1630')]()}),![];if(_0x3cc543[_0x1c51bf('0x1a41')]>_0x27af82)return _0x24558d[_0x1c51bf('0x52a')]({'title':'File\x20too\x20big','msg':_0x1c51bf('0x1622')+_0x4ea5a2+'MB'}),![];return _0x68f0bb['plugin']={'id':_0x3cc543[_0x1c51bf('0x2379')],'file':_0x3cc543},_0x68f0bb[_0x1c51bf('0x2ea')][_0x1c51bf('0x1167')](_0x68f0bb[_0x1c51bf('0x1cd1')]),!![];}function _0x377f43(){const _0x2f8d89=_0x2d5841;_0x68f0bb['uploadState']='uploading',_0x68f0bb[_0x2f8d89('0x1fa6')]['flow'][_0x2f8d89('0x2810')][_0x2f8d89('0xb7d')]={'X-Requested-With':'XMLHttpRequest','Authorization':_0x2f8d89('0x189e')+_0x29338e[_0x2f8d89('0x1e6e')]('motion.token')},_0x68f0bb[_0x2f8d89('0x1fa6')][_0x2f8d89('0x190a')][_0x2f8d89('0x2810')]['query']={'role':_0x68f0bb[_0x2f8d89('0x11ed')][_0x2f8d89('0xecb')],'userProfileId':_0x68f0bb['currentUser'][_0x2f8d89('0x2f')]},_0x68f0bb[_0x2f8d89('0x1fa6')][_0x2f8d89('0x190a')][_0x2f8d89('0xa03')]();}function _0x54724c(_0x262fd8,_0x502daf){const _0x2ceee3=_0x2d5841;_0x68f0bb['plugins'][_0x2ceee3('0x1167')](JSON['parse'](_0x502daf)),angular[_0x2ceee3('0x1299')](_0x68f0bb[_0x2ceee3('0x2ea')],function(_0x572599){const _0x41368d=_0x2ceee3;if(_0x572599['id']===_0x262fd8[_0x41368d('0x2379')]){const _0x41288a=new FileReader();_0x41288a['readAsDataURL'](_0x572599['file'][_0x41368d('0x21dd')]),_0x41288a['onload']=function(_0x2ac13a){const _0x3321a0=_0x41368d;_0x572599['url']=_0x2ac13a[_0x3321a0('0x568')][_0x3321a0('0x7c9')];};}});}function _0x494ac8(){const _0x9b460c=_0x2d5841;_0x68f0bb[_0x9b460c('0x1fa6')][_0x9b460c('0x190a')][_0x9b460c('0x19fb')](),_0x24558d[_0x9b460c('0x52a')]({'title':_0x9b460c('0x22fa'),'msg':_0x9b460c('0x62a')}),_0x68f0bb[_0x9b460c('0x27d5')]=_0x9b460c('0x1fb');}function _0x503854(){const _0x224515=_0x2d5841;_0x68f0bb['uploadState']!==_0x224515('0x1fb')&&(_0x68f0bb[_0x224515('0x27d5')]='completed',_0x24558d[_0x224515('0x53')]({'title':_0x224515('0x1e05'),'msg':_0x68f0bb['plugin']['file'][_0x224515('0x60a')]+_0x224515('0x1987')}));}function _0x251bbb(){_0x281238['hide']();}}const _0x4dedbc=_0x848329;_0x49708a[_0x189033('0x14be')]=['$stateProvider','$translatePartialLoaderProvider'];function _0x49708a(_0x2bd5e9,_0x27c82e){const _0x4200f5=_0x189033;_0x2bd5e9[_0x4200f5('0x2598')](_0x4200f5('0x1769'),{'abstract':!![],'url':_0x4200f5('0x830')})['state']('app.marketplace.plugins',{'url':_0x4200f5('0x1ca3'),'views':{'content@app':{'templateUrl':_0x1c4ea5,'controller':_0x4200f5('0x1640')}},'resolve':{'plugins':[_0x4200f5('0x4b1'),_0x4200f5('0xba1'),function(_0x18a27d,_0x1e1244){const _0x33917a=_0x4200f5;return _0x1e1244[_0x33917a('0xca1')](_0x33917a('0x20c2'))?_0x18a27d['resolve'](_0x33917a('0xe10'),{'fields':_0x33917a('0x668'),'sort':'name','limit':0xa,'offset':0x0}):_0x18a27d[_0x33917a('0xed7')](_0x33917a('0x191b'),{'id':_0x1e1244[_0x33917a('0x20b2')]()[_0x33917a('0x2f')],'section':'Plugins','fields':'createdAt,updatedAt,id,name,type,active,description,icon,sidebar,path,adminUrl,agentUrl,scriptName,scriptPath,version','sort':_0x33917a('0x60a'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver',_0x4200f5('0xba1'),function(_0x4ca6a0,_0x53de37){const _0x192a77=_0x4200f5;return _0x53de37[_0x192a77('0xca1')]('admin')?null:_0x4ca6a0[_0x192a77('0xed7')](_0x192a77('0x1464'),{'fields':'id,name,crudPermissions','id':_0x53de37[_0x192a77('0x20b2')]()[_0x192a77('0x2f')]});}],'userProfileSection':[_0x4200f5('0x4b1'),_0x4200f5('0xba1'),function(_0x106c97,_0x224d79){const _0x325d2e=_0x4200f5;return _0x224d79[_0x325d2e('0xca1')]('admin')?null:_0x106c97['resolve'](_0x325d2e('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x224d79['getCurrentUser']()[_0x325d2e('0x2f')],'sectionId':0x709});}]},'authenticate':!![],'permissionId':0x709,'bodyClass':'marketplace'})[_0x4200f5('0x2598')](_0x4200f5('0x25a8'),{'url':_0x4200f5('0x1560'),'params':{'plugin':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x157241,'controller':_0x4200f5('0x26a4')}},'resolve':{'plugin':[_0x4200f5('0x4b1'),_0x4200f5('0x8ea'),function(_0x49550a,_0x3e6d7b){const _0x217a54=_0x4200f5;return _0x49550a['resolve']('plugin@get',{'fields':_0x217a54('0x668'),'id':_0x3e6d7b['id']});}],'userProfileSection':['apiResolver',_0x4200f5('0xba1'),function(_0x1d2815,_0x15a517){const _0x5f468d=_0x4200f5;return _0x1d2815[_0x5f468d('0xed7')](_0x5f468d('0x360'),{'fields':_0x5f468d('0x1f47'),'userProfileId':_0x15a517[_0x5f468d('0x20b2')]()[_0x5f468d('0x2f')],'sectionId':0x709});}]},'authenticate':!![],'permissionId':0x709,'bodyClass':_0x4200f5('0x1089')}),_0x27c82e[_0x4200f5('0x7d2')](_0x4200f5('0x187c'));}angular[_0x189033('0x1e26')](_0x189033('0x1769'),[_0x189033('0x6cf'),_0x189033('0x1ddb'),_0x189033('0x2290'),_0x189033('0x190a'),_0x189033('0x25fc'),'ckeditor',_0x189033('0x1d9c'),_0x189033('0x2609'),'ngAnimate',_0x189033('0x76'),_0x189033('0x516'),_0x189033('0x7fa'),_0x189033('0x197b'),_0x189033('0x3b5'),_0x189033('0x153a'),'ngEmbed',_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da')])[_0x189033('0x272d')](_0x49708a)[_0x189033('0x1da3')](_0x189033('0x13e3'),_0x3d1747)[_0x189033('0x1da3')](_0x189033('0x2172'),_0x1187a1)['controller'](_0x189033('0x1db0'),_0x41e5cd)[_0x189033('0x1da3')]('UploadPluginDialogController',_0x4dedbc);const _0x3155b3=_0x180212['p']+_0x189033('0x173c');_0x5d87b1[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x7a5'),_0x189033('0x204d'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0xba1')];function _0x5d87b1(_0x1809de,_0x49f749,_0x1890d7,_0xa9ace6,_0x739abb,_0x5acbcb){const _0x25b45c=_0x189033,_0x5ceb17=this;_0x5ceb17[_0x25b45c('0x11ed')]=_0x5acbcb[_0x25b45c('0x20b2')](),_0x5ceb17['plugin']={},_0x5ceb17[_0x25b45c('0x2276')]=_0x1757fc,_0xa9ace6[_0x25b45c('0x1cd1')]['get']({'id':_0x1809de[_0x25b45c('0x7f2')]['id']})['$promise'][_0x25b45c('0x683')](function(_0x24e4ff){const _0x715f18=_0x25b45c;if(_0x24e4ff)return _0x5ceb17[_0x715f18('0x1cd1')]=_0x24e4ff,_0xa9ace6[_0x715f18('0x1cd1')][_0x715f18('0x1e6e')]({'id':_0x5ceb17[_0x715f18('0x1cd1')]['id']})[_0x715f18('0xe53')];})[_0x25b45c('0x130a')](function(){_0x5ceb17['plugin']=undefined;});function _0x1757fc(){const _0x2a041a=_0x25b45c;return _0x1890d7['trustAsResourceUrl'](_0x5ceb17[_0x2a041a('0x1cd1')][_0x2a041a('0x10c')]);}}const _0x5436c2=_0x5d87b1;_0x1b7da9[_0x189033('0x14be')]=[_0x189033('0x1398')];function _0x1b7da9(_0x2ed863){const _0xb9e34e=_0x189033;_0x2ed863[_0xb9e34e('0x2598')](_0xb9e34e('0x2394'),{'url':_0xb9e34e('0x15fe'),'views':{'content@app':{'templateUrl':_0x3155b3,'controller':_0xb9e34e('0x821')}},'resolve':{},'authenticate':!![],'bodyClass':'plugins'});}angular[_0x189033('0x1e26')](_0x189033('0x2394'),[])['config'](_0x1b7da9)['controller'](_0x189033('0x1c43'),_0x5436c2),_0x1524ca['$inject']=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x1524ca(_0x4aa42d,_0x36b560){const _0x460474=_0x189033;_0x4aa42d[_0x460474('0x2598')](_0x460474('0xf9e'),{'abstract':!![],'url':'/plugins'}),_0x36b560['addPart'](_0x460474('0x1fe'));}angular[_0x189033('0x1e26')](_0x189033('0xf9e'),['ngCsv',_0x189033('0x1ddb'),'md.data.table',_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),'ng-sortable',_0x189033('0x2609'),_0x189033('0x273d'),'mdPickers',_0x189033('0x516'),_0x189033('0x7fa'),_0x189033('0x197b'),_0x189033('0x3b5'),_0x189033('0x153a'),_0x189033('0x1447'),'angularMaterialFormBuilder',_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da'),'app.plugins.plugin'])[_0x189033('0x272d')](_0x1524ca);const _0x488ff5=_0x180212['p']+_0x189033('0x144e');_0x3f5d5c['$inject']=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate','toasty',_0x189033('0x1b50'),_0x189033('0x1f6c'),_0x189033('0x56b'),_0x189033('0xba1'),'license',_0x189033('0x260a'),'crudPermissions'];function _0x3f5d5c(_0xdff349,_0x4dc9dc,_0x2a8c7e,_0x3cc70,_0x29a784,_0x308f8d,_0x8cd04,_0x6d468a,_0x9356b3,_0x45195e,_0x3e6bf8,_0xc620ed,_0x31d58f,_0x4aa5d8){const _0x5e22e2=_0x189033,_0x4f2c47=this;_0x4f2c47['currentUser']=_0x3e6bf8['getCurrentUser'](),_0x4f2c47[_0x5e22e2('0x17f')]=[],_0x4f2c47['setting']=_0x31d58f,_0x4f2c47[_0x5e22e2('0xace')]=_0xc620ed,_0x4f2c47['crudPermissions']=_0x4aa5d8,_0x4f2c47[_0x5e22e2('0x258d')]={},_0x4f2c47[_0x5e22e2('0x19b2')]=_0x4f2c47[_0x5e22e2('0x260a')]&&_0x4f2c47[_0x5e22e2('0x260a')][_0x5e22e2('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4f2c47['title']=_0x5e22e2('0x728'),_0x4f2c47[_0x5e22e2('0x1f6c')]=angular[_0x5e22e2('0x1a86')](_0x9356b3),_0x4f2c47[_0x5e22e2('0x1b50')]=_0x6d468a,_0x4f2c47['newscreenRecording']=![];!_0x4f2c47[_0x5e22e2('0x1f6c')]&&(_0x4f2c47[_0x5e22e2('0x1f6c')]={},_0x4f2c47[_0x5e22e2('0xf28')]=_0x5e22e2('0x1bd3'),_0x4f2c47[_0x5e22e2('0x1b04')]=!![]);_0x4f2c47[_0x5e22e2('0x1be5')]=_0x32dff8,_0x4f2c47[_0x5e22e2('0x2774')]=_0x3d3747,_0x4f2c47[_0x5e22e2('0x142b')]=_0x180636,_0x4f2c47[_0x5e22e2('0x16b3')]=_0x2813ff,_0x4f2c47[_0x5e22e2('0xf82')]=_0x56b932,_0x45195e[_0x5e22e2('0xc96')]['get']({'fields':_0x5e22e2('0x2686'),'sort':'name','nolimit':'true'})['$promise']['then'](function(_0x1153d0){const _0x15e3de=_0x5e22e2;_0x4f2c47[_0x15e3de('0x3bf')]=_0x1153d0[_0x15e3de('0xf5d')]||[];})[_0x5e22e2('0x130a')](function(_0x3b6269){const _0x2ecfde=_0x5e22e2;_0x8cd04[_0x2ecfde('0x52a')]({'title':_0x3b6269[_0x2ecfde('0x13ee')]?_0x2ecfde('0x2168')+_0x3b6269[_0x2ecfde('0x13ee')]+'\x20-\x20'+_0x3b6269[_0x2ecfde('0x24a9')]:_0x2ecfde('0x8eb'),'msg':_0x3b6269['data']?JSON[_0x2ecfde('0x258a')](_0x3b6269[_0x2ecfde('0x5a5')]):_0x3b6269['toString']()});});function _0x32dff8(){const _0xbf3b8=_0x5e22e2;_0x4f2c47['errors']=[],_0x45195e[_0xbf3b8('0x1f6c')][_0xbf3b8('0xb0a')](_0x4f2c47[_0xbf3b8('0x1f6c')])[_0xbf3b8('0xe53')]['then'](function(_0x1e58d9){const _0x489104=_0xbf3b8;_0x4f2c47[_0x489104('0x1b50')]['unshift'](_0x1e58d9[_0x489104('0x24e1')]()),_0x8cd04[_0x489104('0x53')]({'title':_0x489104('0x1aed'),'msg':_0x4f2c47[_0x489104('0x1f6c')]['name']?_0x4f2c47[_0x489104('0x1f6c')][_0x489104('0x60a')]+_0x489104('0x14b5'):''}),_0x56b932(_0x1e58d9);})[_0xbf3b8('0x130a')](function(_0x5f3402){const _0x1ab92d=_0xbf3b8;if(_0x5f3402[_0x1ab92d('0x5a5')]&&_0x5f3402['data']['errors']&&_0x5f3402[_0x1ab92d('0x5a5')][_0x1ab92d('0x17f')]['length']){_0x4f2c47[_0x1ab92d('0x17f')]=_0x5f3402[_0x1ab92d('0x5a5')][_0x1ab92d('0x17f')]||[{'message':_0x5f3402['toString'](),'type':'api.screenRecording.save'}];for(let _0x583eaa=0x0;_0x583eaa<_0x5f3402[_0x1ab92d('0x5a5')]['errors'][_0x1ab92d('0x1564')];_0x583eaa+=0x1){_0x8cd04[_0x1ab92d('0x52a')]({'title':_0x5f3402['data']['errors'][_0x583eaa]['type'],'msg':_0x5f3402[_0x1ab92d('0x5a5')][_0x1ab92d('0x17f')][_0x583eaa]['message']});}}else _0x8cd04['error']({'title':_0x5f3402[_0x1ab92d('0x13ee')]?_0x1ab92d('0x2168')+_0x5f3402['status']+_0x1ab92d('0xbf6')+_0x5f3402[_0x1ab92d('0x24a9')]:_0x1ab92d('0x106a'),'msg':_0x5f3402[_0x1ab92d('0x5a5')]?JSON[_0x1ab92d('0x258a')](_0x5f3402['data'][_0x1ab92d('0x8c2')]):_0x5f3402['toString']()});});}function _0x3d3747(){const _0x50691d=_0x5e22e2;_0x4f2c47['errors']=[],_0x45195e[_0x50691d('0x1f6c')][_0x50691d('0x2480')]({'id':_0x4f2c47[_0x50691d('0x1f6c')]['id']},_0x4f2c47['screenRecording'])[_0x50691d('0xe53')]['then'](function(_0x1b750d){const _0x52b538=_0x50691d,_0x46740a=_0x2e3ca0()['find'](_0x4f2c47[_0x52b538('0x1b50')],{'id':_0x1b750d['id']});_0x46740a&&_0x2e3ca0()[_0x52b538('0xf22')](_0x46740a,_0x2e3ca0()[_0x52b538('0x24d0')](_0x1b750d[_0x52b538('0x24e1')](),_0x2e3ca0()['keys'](_0x46740a))),_0x8cd04['success']({'title':_0x52b538('0x155c'),'msg':_0x4f2c47[_0x52b538('0x1f6c')][_0x52b538('0x60a')]?_0x4f2c47[_0x52b538('0x1f6c')][_0x52b538('0x60a')]+_0x52b538('0xf59'):''}),_0x56b932(_0x1b750d);})['catch'](function(_0x18e063){const _0x1d3d6a=_0x50691d;if(_0x18e063[_0x1d3d6a('0x5a5')]&&_0x18e063[_0x1d3d6a('0x5a5')]['errors']&&_0x18e063[_0x1d3d6a('0x5a5')][_0x1d3d6a('0x17f')]['length']){_0x4f2c47[_0x1d3d6a('0x17f')]=_0x18e063[_0x1d3d6a('0x5a5')][_0x1d3d6a('0x17f')]||[{'message':_0x18e063[_0x1d3d6a('0x1ff0')](),'type':_0x1d3d6a('0xa5e')}];for(let _0x4d5124=0x0;_0x4d5124<_0x18e063[_0x1d3d6a('0x5a5')][_0x1d3d6a('0x17f')][_0x1d3d6a('0x1564')];_0x4d5124++){_0x8cd04['error']({'title':_0x18e063[_0x1d3d6a('0x5a5')]['errors'][_0x4d5124]['type'],'msg':_0x18e063['data'][_0x1d3d6a('0x17f')][_0x4d5124]['message']});}}else _0x8cd04[_0x1d3d6a('0x52a')]({'title':_0x18e063[_0x1d3d6a('0x13ee')]?_0x1d3d6a('0x2168')+_0x18e063[_0x1d3d6a('0x13ee')]+_0x1d3d6a('0xbf6')+_0x18e063[_0x1d3d6a('0x24a9')]:_0x1d3d6a('0xa5e'),'msg':_0x18e063[_0x1d3d6a('0x5a5')]?JSON[_0x1d3d6a('0x258a')](_0x18e063[_0x1d3d6a('0x5a5')][_0x1d3d6a('0x8c2')]):_0x18e063[_0x1d3d6a('0x1ff0')]()});});}function _0x180636(_0xd1ef5f){const _0x569467=_0x5e22e2;_0x4f2c47[_0x569467('0x17f')]=[];const _0x5b6348=_0x3cc70[_0x569467('0x1c6f')]()[_0x569467('0xf28')](_0x569467('0x4d'))[_0x569467('0xa6a')]('The\x20screenRecording\x20will\x20be\x20deleted.')[_0x569467('0x1040')]('Delete\x20screenRecording')['ok'](_0x569467('0x2307'))[_0x569467('0x19fb')](_0x569467('0x253a'))[_0x569467('0xe42')](_0xd1ef5f);_0x3cc70[_0x569467('0x1d4')](_0x5b6348)[_0x569467('0x683')](function(){const _0x2252d7=_0x569467;_0x45195e[_0x2252d7('0x1f6c')]['delete']({'id':_0x4f2c47['screenRecording']['id']})[_0x2252d7('0xe53')][_0x2252d7('0x683')](function(){const _0x2ea1c8=_0x2252d7;_0x2e3ca0()[_0x2ea1c8('0x3ec')](_0x4f2c47[_0x2ea1c8('0x1b50')],{'id':_0x4f2c47[_0x2ea1c8('0x1f6c')]['id']}),_0x8cd04[_0x2ea1c8('0x53')]({'title':_0x2ea1c8('0x67b'),'msg':(_0x4f2c47[_0x2ea1c8('0x1f6c')]['name']||_0x2ea1c8('0x1f6c'))+_0x2ea1c8('0x194d')}),_0x56b932(_0x4f2c47[_0x2ea1c8('0x1f6c')]);})[_0x2252d7('0x130a')](function(_0x38a3c3){const _0xc84d6c=_0x2252d7;if(_0x38a3c3['data']&&_0x38a3c3['data'][_0xc84d6c('0x17f')]&&_0x38a3c3[_0xc84d6c('0x5a5')][_0xc84d6c('0x17f')][_0xc84d6c('0x1564')]){_0x4f2c47[_0xc84d6c('0x17f')]=_0x38a3c3[_0xc84d6c('0x5a5')][_0xc84d6c('0x17f')]||[{'message':_0x38a3c3[_0xc84d6c('0x1ff0')](),'type':'api.screenRecording.delete'}];for(let _0x1ea117=0x0;_0x1ea117<_0x38a3c3[_0xc84d6c('0x5a5')][_0xc84d6c('0x17f')][_0xc84d6c('0x1564')];_0x1ea117++){_0x8cd04['error']({'title':_0x38a3c3[_0xc84d6c('0x5a5')][_0xc84d6c('0x17f')][_0x1ea117][_0xc84d6c('0xcf0')],'msg':_0x38a3c3[_0xc84d6c('0x5a5')][_0xc84d6c('0x17f')][_0x1ea117][_0xc84d6c('0x8c2')]});}}else _0x8cd04['error']({'title':_0x38a3c3['status']?_0xc84d6c('0x2168')+_0x38a3c3['status']+_0xc84d6c('0xbf6')+_0x38a3c3[_0xc84d6c('0x24a9')]:_0xc84d6c('0x1cde'),'msg':_0x38a3c3[_0xc84d6c('0x5a5')]?JSON[_0xc84d6c('0x258a')](_0x38a3c3[_0xc84d6c('0x5a5')][_0xc84d6c('0x8c2')]):_0x38a3c3[_0xc84d6c('0x8c2')]||_0x38a3c3['toString']()});});},function(){});}function _0x2813ff(_0x34ddd8){return _0x34ddd8===null?undefined:new Date(_0x34ddd8);}function _0x56b932(_0x844130){const _0x2d1c6a=_0x5e22e2;_0x3cc70[_0x2d1c6a('0x1715')](_0x844130);}}const _0x5d058f=_0x3f5d5c;_0x2fe998[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1e48'),_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x1e63'),'actionOptions',_0x189033('0xfc9'),_0x189033('0x67a'),_0x189033('0x1491'),'$q'];function _0x2fe998(_0xba08cf,_0x3d2266,_0x4d5357,_0x3b205d,_0x4176e7,_0x3090db,_0x36d931,_0x40e52f,_0x59d27b,_0xd08aeb){const _0x32888d=_0x189033,_0xc21db0=this;_0xc21db0[_0x32888d('0x2195')]=![],_0xc21db0[_0x32888d('0x1e63')]=Object[_0x32888d('0x196a')]({},_0x4176e7),_0xc21db0[_0x32888d('0x20ed')]=_0x32888d('0x1f6c'),_0xc21db0[_0x32888d('0x1fcc')]=_0x59d27b,_0xc21db0['actionOptions']=Object['assign']({},_0x3090db),_0xc21db0[_0x32888d('0x210f')]=_0x40e52f,_0xc21db0[_0x32888d('0xfc9')]=_0x36d931,_0xc21db0[_0x32888d('0x1d75')]=_0x32888d('0x12a3'),_0xc21db0['model']=_0x32888d('0x1f6c'),console[_0x32888d('0x1b2b')](_0x32888d('0x1728'),_0xc21db0[_0x32888d('0x210f')]),console[_0x32888d('0x1b2b')]('TCL:\x20vm.recording[vm.path]',_0xc21db0[_0x32888d('0x1e63')][_0xc21db0[_0x32888d('0x210f')]]),_0xc21db0[_0x32888d('0x1917')]=_0xc21db0[_0x32888d('0x1e63')][_0xc21db0[_0x32888d('0x210f')]][_0x32888d('0x824')]('/')>-0x1?_0xc21db0['recording'][_0xc21db0['path']]['substring'](_0xc21db0[_0x32888d('0x1e63')][_0xc21db0[_0x32888d('0x210f')]][_0x32888d('0xb77')]('/')+0x1):_0xc21db0['recording'][_0xc21db0[_0x32888d('0x210f')]][_0x32888d('0x824')]('\x5c')>-0x1?_0xc21db0[_0x32888d('0x1e63')][_0xc21db0[_0x32888d('0x210f')]]['substring'](_0xc21db0[_0x32888d('0x1e63')][_0xc21db0[_0x32888d('0x210f')]][_0x32888d('0xb77')]('\x5c')+0x1):_0xc21db0[_0x32888d('0x1e63')][_0xc21db0[_0x32888d('0x210f')]],_0xc21db0[_0x32888d('0x26dd')]=![];_0x2e3ca0()['isNil'](_0xc21db0[_0x32888d('0x1e63')]['format'])&&(_0xc21db0[_0x32888d('0x1e63')][_0x32888d('0x26dd')]=_0xc21db0['filename'][_0x32888d('0x12c8')](_0xc21db0[_0x32888d('0x1917')][_0x32888d('0xb77')]('.')));(_0xc21db0[_0x32888d('0x1e63')]['format']===_0x32888d('0x138a')&&_0xc21db0[_0x32888d('0x1fcc')]===_0x32888d('0x9b5')||_0xc21db0['recording'][_0x32888d('0x26dd')]===_0x32888d('0xc9')&&_0xc21db0[_0x32888d('0x1fcc')]===_0x32888d('0x12a3'))&&(_0xc21db0['format']=!![]);_0xc21db0[_0x32888d('0xa0')]=!![];_0xc21db0[_0x32888d('0x26dd')]&&_0x4eb9c5();function _0x4eb9c5(){const _0x4100ad=_0x32888d,_0x116b73=_0xd08aeb[_0x4100ad('0x448')]();return _0x3b205d[_0x4100ad('0x1f6c')][_0x4100ad('0x18e8')]({'id':_0xc21db0[_0x4100ad('0x1e63')]['id'],'path':String(_0xc21db0[_0x4100ad('0x210f')])})[_0x4100ad('0xe53')][_0x4100ad('0x683')](function(){const _0x977056=_0x4100ad;_0xc21db0[_0x977056('0x26dd')]=!![],_0xc21db0['found']=!![],_0x116b73['resolve']();})[_0x4100ad('0x130a')](function(){const _0x363fbd=_0x4100ad;console[_0x363fbd('0x1b2b')](_0x363fbd('0xd7a')),_0xc21db0[_0x363fbd('0x26dd')]=![],_0xc21db0['found']=![],_0x116b73[_0x363fbd('0xed7')]();}),_0x116b73[_0x4100ad('0x1883')];}if(!_0x2e3ca0()[_0x32888d('0x8f2')](_0x3090db[_0x32888d('0x1594')])&&_0x3090db['properties']){_0xc21db0[_0x32888d('0x1594')]=Object[_0x32888d('0x196a')]({},_0x4176e7);const _0x377676=Object[_0x32888d('0x55e')](_0x4176e7);_0x377676[_0x32888d('0x1299')](function(_0x37890f){const _0x45bec8=_0x32888d;String(_0x37890f[0x0]['toUpperCase']())===String(_0x37890f[0x0])&&delete _0xc21db0[_0x45bec8('0x1594')][_0x37890f];}),_0xc21db0[_0x32888d('0x23c7')]={};if(!_0x2e3ca0()['isNil'](_0x3090db[_0x32888d('0x60f')])&&_0x3090db[_0x32888d('0x60f')][_0x32888d('0x1564')]>0x0){_0xc21db0[_0x32888d('0x23c7')]=Object[_0x32888d('0x196a')]({},_0x4176e7);const _0x5cd20e=_0x3090db[_0x32888d('0x60f')],_0x4862e4=Object['keys'](_0x4176e7);let _0x293bbf=!![];_0x4862e4[_0x32888d('0x1299')](function(_0x346f58){const _0x37c2f3=_0x32888d;_0x293bbf=!![],_0x5cd20e['forEach'](function(_0xa0d083){String(_0x346f58)===String(_0xa0d083)&&(_0x293bbf=![]);}),_0x293bbf&&delete _0xc21db0[_0x37c2f3('0x23c7')][_0x346f58];}),_0xc21db0[_0x32888d('0x1594')]=_0xc21db0[_0x32888d('0x23c7')];}if(!_0x2e3ca0()[_0x32888d('0x8f2')](_0x3090db['extraData'])&&_0x3090db['extraData']['length']>0x0){_0xc21db0[_0x32888d('0x1af')]={};const _0x295466=_0x3090db[_0x32888d('0x10c4')];for(let _0x4637ee=0x0;_0x4637ee<_0x295466[_0x32888d('0x1564')];_0x4637ee++){const _0x24abec=_0x295466[_0x4637ee]['values'],_0x47283a=_0x295466[_0x4637ee]['model'];for(let _0x15bbc7=0x0;_0x15bbc7<_0x24abec[_0x32888d('0x1564')];_0x15bbc7++){_0xc21db0[_0x32888d('0x1af')][_0x24abec[_0x15bbc7]['text']]=_0x4176e7[_0x47283a][_0x24abec[_0x15bbc7][_0x32888d('0x1d46')]];}}_0xc21db0[_0x32888d('0x1594')]=Object[_0x32888d('0x196a')]({},_0xc21db0[_0x32888d('0x23c7')],_0xc21db0['propertiesExtra']);}}_0xc21db0[_0x32888d('0xf82')]=_0x3fd459;function _0x3fd459(){const _0x511183=_0x32888d;_0x3d2266[_0x511183('0x1715')]();}}const _0x577b4b=_0x2fe998,_0x3e36d8=_0x180212['p']+_0x189033('0x1bf5'),_0x12dc54=_0x180212['p']+'src/js/modules/main/apps/video/views/screenRecordings/partialViews/play.html/play.html';_0x27c7e4[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),'$document','$timeout',_0x189033('0x1d08'),_0x189033('0x1b50'),_0x189033('0x2a'),_0x189033('0x22df'),'api','msUtils','toasty','Auth',_0x189033('0xace'),_0x189033('0x260a')];function _0x27c7e4(_0x5a98cf,_0x2b2b8f,_0x53b675,_0x1d985a,_0x5bf5c2,_0x509734,_0x36353c,_0x347cd4,_0x1916a0,_0x5c551e,_0x41d919,_0x2c03ef,_0x22a446,_0x1eb43a,_0x1e1020,_0x1b391f,_0x3a1196){const _0x2b85d0=_0x189033,_0x25cc04=this;_0x25cc04['license']=_0x1b391f,_0x25cc04[_0x2b85d0('0x260a')]=_0x3a1196,_0x25cc04[_0x2b85d0('0x11ed')]=_0x1e1020['getCurrentUser'](),_0x25cc04[_0x2b85d0('0x1b50')]=_0x1916a0||{'count':0x0,'rows':[]},_0x25cc04['userProfile']=_0x5c551e,_0x25cc04[_0x2b85d0('0x22df')]=_0x41d919&&_0x41d919[_0x2b85d0('0x50d')]==0x1?_0x41d919[_0x2b85d0('0xf5d')][0x0]:null,_0x25cc04[_0x2b85d0('0x1134')]=_0x1e1020[_0x2b85d0('0x142a')](_0x25cc04[_0x2b85d0('0x22df')]?_0x25cc04[_0x2b85d0('0x22df')]['crudPermissions']:null),_0x25cc04[_0x2b85d0('0x5c4')]=_0x2b85d0('0x1b50'),_0x25cc04['listOrder']='',_0x25cc04[_0x2b85d0('0x1ce2')]=null,_0x25cc04[_0x2b85d0('0x101d')]=[],_0x25cc04[_0x2b85d0('0x23a2')]={'fields':_0x2b85d0('0x11f'),'createdAt':_0x2b85d0('0x67f'),'includeAll':_0x2b85d0('0x26ac'),'sort':_0x2b85d0('0xc36'),'limit':0xa,'page':0x1},_0x25cc04['query']['createdAt']=_0x22a446[_0x2b85d0('0x11c4')](),_0x25cc04[_0x2b85d0('0xc71')]=_0x31ca55();function _0x31ca55(){const _0x1d1729=_0x2b85d0;return[{'name':'Start\x20Date','key':'createdAt','type':_0x1d1729('0x270e'),'label':'DASHBOARDS.SELECT_DATE_RANGE'}];}_0x25cc04[_0x2b85d0('0xbe5')]=_0x4277f3,_0x25cc04[_0x2b85d0('0x29d')]=_0x2b15b1,_0x25cc04[_0x2b85d0('0x194f')]=_0x89043,_0x25cc04[_0x2b85d0('0x53')]=_0x43c42c,_0x25cc04[_0x2b85d0('0x27e4')]=_0x1475c9,_0x25cc04[_0x2b85d0('0x459')]=_0x551741,_0x25cc04[_0x2b85d0('0x142b')]=_0xa4542c,_0x25cc04[_0x2b85d0('0x1edf')]=_0x5859d0,_0x25cc04[_0x2b85d0('0x7e6')]=_0xbad9e1,_0x25cc04['deselectScreenRecordings']=_0x2f7c8e,_0x25cc04[_0x2b85d0('0x1ff')]=_0x144d45,_0x25cc04[_0x2b85d0('0xec6')]=_0x591bde,_0x2c03ef['user']['get']({'fields':_0x2b85d0('0x2686'),'sort':_0x2b85d0('0x60a'),'nolimit':'true'})['$promise'][_0x2b85d0('0x683')](function(_0x14b2d2){const _0x18e92f=_0x2b85d0;_0x25cc04[_0x18e92f('0x3bf')]=_0x14b2d2[_0x18e92f('0xf5d')]||[];})['catch'](function(_0x13548e){const _0x924556=_0x2b85d0;_0x1eb43a[_0x924556('0x52a')]({'title':_0x13548e[_0x924556('0x13ee')]?_0x924556('0x2168')+_0x13548e[_0x924556('0x13ee')]+'\x20-\x20'+_0x13548e[_0x924556('0x24a9')]:_0x924556('0x8eb'),'msg':_0x13548e[_0x924556('0x5a5')]?JSON[_0x924556('0x258a')](_0x13548e[_0x924556('0x5a5')]):_0x13548e[_0x924556('0x1ff0')]()});});function _0x4277f3(_0x8cabcb,_0x529b4a,_0x27e47c,_0x1ed969,_0x5c52a6){const _0x5ac6ec=_0x2b85d0,_0x51d5c4={'upperTitle':![],'lowerTitle':!![],'properties':!![],'propertiesIcon':_0x5ac6ec('0x1ae1'),'propertiesList':[_0x5ac6ec('0x26dd'),_0x5ac6ec('0xea1'),_0x5ac6ec('0xe60'),_0x5ac6ec('0x689'),_0x5ac6ec('0x1a19'),_0x5ac6ec('0x1a4')],'extraData':[{'model':_0x5ac6ec('0x1dad'),'values':[{'key':_0x5ac6ec('0x60a'),'text':_0x5ac6ec('0xfa4')}]}]},_0x23c544={};_0x23c544[_0x5ac6ec('0x20ed')]=_0x5ac6ec('0x1f6c'),_0x23c544[_0x5ac6ec('0x60a')]='screenRecordings',_0x23c544[_0x5ac6ec('0x2437')]=_0x5ac6ec('0x1f6c'),_0x23c544['singular']=_0x5ac6ec('0x1f6c'),_0x1ed969=String(_0x1ed969);const _0x1e284b=String(_0x27e47c);console[_0x5ac6ec('0x1b2b')](_0x5ac6ec('0x18d'),String(_0x27e47c)),_0x5bf5c2[_0x5ac6ec('0x1d4')]({'controller':'ScreenRecordingplayController','controllerAs':'vm','templateUrl':_0x12dc54,'parent':angular['element'](_0x509734[_0x5ac6ec('0x18e5')]),'targetEvent':_0x529b4a,'clickOutsideToClose':!![],'locals':{'recording':_0x8cabcb,'recordings':_0x25cc04[_0x5ac6ec('0x1b50')]['rows'],'license':_0x25cc04['license'],'setting':null,'item':_0x23c544,'actionOptions':_0x51d5c4,'label':_0x1ed969,'varPath':_0x1e284b,'elementTag':String(_0x5c52a6)}});}function _0x2b15b1(_0x47559e){const _0xc5ca49=_0x2b85d0;let _0x6bd7e0=![];const _0x68e6c5=!_0x2e3ca0()['isNil'](_0x47559e[_0xc5ca49('0x26dd')])?_0x47559e['format']:_0x47559e['value']['substring'](_0x47559e[_0xc5ca49('0x1c6b')][_0xc5ca49('0xb77')]('.'));_0x6bd7e0=_0x68e6c5===_0xc5ca49('0xc9')?!![]:![];const _0x3f847=_0x47559e['value'][_0xc5ca49('0xb77')]('/')>-0x1?_0x47559e[_0xc5ca49('0x1c6b')][_0xc5ca49('0x1735')](_0x47559e[_0xc5ca49('0x1c6b')][_0xc5ca49('0xb77')]('/')+0x1):_0x47559e[_0xc5ca49('0x1c6b')]['lastIndexOf']('\x5c')>-0x1?_0x47559e['value'][_0xc5ca49('0x1735')](_0x47559e[_0xc5ca49('0x1c6b')]['lastIndexOf']('\x5c')+0x1):_0x47559e[_0xc5ca49('0x1c6b')];return _0x2c03ef[_0xc5ca49('0x1f6c')][_0xc5ca49('0x18e8')]({'id':_0x47559e['id']})[_0xc5ca49('0xe53')]['then'](function(_0x32d78b){const _0x433165=_0xc5ca49,_0x5402ad=[_0x32d78b['buffer']];let _0x3f28ce='download';const _0x46b067=new Blob(_0x5402ad,{'type':_0x32d78b[_0x433165('0xcf0')]});_0x3f28ce=_0x3f847;const _0x137e25=window[_0x433165('0x12e1')][_0x433165('0x1ffa')]('a');_0x137e25['setAttribute'](_0x433165('0x2767'),URL[_0x433165('0x2820')](_0x46b067)),_0x137e25[_0x433165('0x130f')](_0x433165('0x18e8'),_0x3f28ce),document[_0x433165('0x18e5')]['appendChild'](_0x137e25),_0x137e25[_0x433165('0x1d42')]();})[_0xc5ca49('0x130a')](function(_0x16a96f){const _0x566865=_0xc5ca49;if(_0x16a96f[_0x566865('0x5a5')]&&_0x16a96f[_0x566865('0x5a5')]['errors']&&_0x16a96f[_0x566865('0x5a5')][_0x566865('0x17f')][_0x566865('0x1564')])for(let _0x5b8a7d=0x0;_0x5b8a7d<_0x16a96f[_0x566865('0x5a5')][_0x566865('0x17f')][_0x566865('0x1564')];_0x5b8a7d++){_0x1eb43a['error']({'title':_0x16a96f[_0x566865('0x5a5')][_0x566865('0x17f')][_0x5b8a7d]['type'],'msg':_0x16a96f['data'][_0x566865('0x17f')][_0x5b8a7d][_0x566865('0x8c2')]});}else{if(String(_0x16a96f[_0x566865('0x13ee')])===_0x566865('0x1bef')&&_0x6bd7e0===![])_0x1eb43a[_0x566865('0x2289')]({'title':_0x347cd4['instant']('VIDEO.CANT_DOWNLOAD_THIS_FILE'),'msg':_0x347cd4['instant'](_0x566865('0x1745'))});else String(_0x16a96f[_0x566865('0x13ee')])===_0x566865('0x1bef')?_0x1eb43a[_0x566865('0x2289')]({'title':_0x347cd4[_0x566865('0x2728')](_0x566865('0xee1')),'msg':_0x347cd4['instant'](_0x566865('0xab4'))}):_0x1eb43a['error']({'title':_0x16a96f[_0x566865('0x13ee')]?_0x566865('0x2168')+_0x16a96f[_0x566865('0x13ee')]+_0x566865('0xbf6')+_0x16a96f[_0x566865('0x24a9')]:_0x566865('0x106a'),'msg':_0x16a96f[_0x566865('0x5a5')]?JSON['stringify'](_0x16a96f[_0x566865('0x5a5')][_0x566865('0x8c2')]):_0x16a96f[_0x566865('0x1ff0')]()});}});}function _0x89043(_0x570d13,_0x2414a4){const _0x37808d=_0x2b85d0,_0x30592e=_0x5bf5c2['confirm']()[_0x37808d('0xf28')](_0x37808d('0x1b01')+_0x2e3ca0()[_0x37808d('0x1e03')]('screenRecording')+'?')[_0x37808d('0x26e3')](_0x37808d('0xed5')+(_0x570d13[_0x37808d('0x60a')]||'screenRecording')+''+'\x20will\x20be\x20deleted.')[_0x37808d('0x1040')]('delete\x20screenRecording')[_0x37808d('0xe42')](_0x2414a4)['ok']('OK')['cancel'](_0x37808d('0x16b8'));_0x5bf5c2[_0x37808d('0x1d4')](_0x30592e)['then'](function(){_0xa4542c(_0x570d13);},function(){console['log']('CANCEL');});}let _0x263fa1=!![],_0x3fc411=0x1;_0x5a98cf['$watch'](_0x2b85d0('0x1e1d'),function(_0x4e2149,_0x1ba9b0){const _0x428a10=_0x2b85d0;_0x263fa1?_0x36353c(function(){_0x263fa1=![];}):(!_0x1ba9b0&&(_0x3fc411=_0x25cc04[_0x428a10('0x23a2')]['page']),_0x4e2149!==_0x1ba9b0&&(_0x25cc04[_0x428a10('0x23a2')][_0x428a10('0xdf8')]=0x1),!_0x4e2149&&(_0x25cc04['query']['page']=_0x3fc411),_0x25cc04[_0x428a10('0x27e4')]());});function _0x591bde(_0x58a8eb){const _0x19a06c=_0x2b85d0,_0x50b194=Math[_0x19a06c('0x16c9')](_0x58a8eb/0x3e8%0x3c),_0x5433da=Math[_0x19a06c('0x16c9')](_0x58a8eb/(0x3e8*0x3c)%0x3c),_0x4b9cba=Math[_0x19a06c('0x16c9')](_0x58a8eb/(0x3e8*0x3c*0x3c)%0x18),_0x1d8b0b=_0x4b9cba<0xa?'0'+String(_0x4b9cba):String(_0x4b9cba),_0x5d3905=_0x5433da<0xa?'0'+String(_0x5433da):String(_0x5433da),_0xf823ce=_0x50b194<0xa?'0'+String(_0x50b194):String(_0x50b194);return _0x1d8b0b+':'+_0x5d3905+':'+_0xf823ce;}function _0x43c42c(_0x149add){const _0x17681a=_0x2b85d0;_0x25cc04[_0x17681a('0x1b50')]=_0x149add||{'count':0x0,'rows':[]};}function _0x1475c9(){const _0x558bd0=_0x2b85d0;_0x25cc04[_0x558bd0('0x23a2')][_0x558bd0('0x1cc8')]=(_0x25cc04[_0x558bd0('0x23a2')][_0x558bd0('0xdf8')]-0x1)*_0x25cc04[_0x558bd0('0x23a2')]['limit'],_0x1e1020[_0x558bd0('0xca1')](_0x558bd0('0x20c2'))?_0x25cc04[_0x558bd0('0x1883')]=_0x2c03ef[_0x558bd0('0x1f6c')][_0x558bd0('0x1e6e')](_0x25cc04['query'],_0x43c42c)['$promise']:(_0x25cc04[_0x558bd0('0x23a2')]['id']=_0x25cc04['userProfile']['id'],_0x25cc04['query'][_0x558bd0('0x1aa')]=_0x558bd0('0x227f'),_0x25cc04[_0x558bd0('0x1883')]=_0x2c03ef[_0x558bd0('0x2a')][_0x558bd0('0x241d')](_0x25cc04[_0x558bd0('0x23a2')],_0x43c42c)[_0x558bd0('0xe53')]);}function _0x551741(_0x1edbf0,_0x5657b8){const _0x590575=_0x2b85d0;_0x5bf5c2['show']({'controller':_0x590575('0x17c8'),'controllerAs':'vm','templateUrl':_0x3e36d8,'parent':angular[_0x590575('0x1fcc')](_0x509734['body']),'targetEvent':_0x1edbf0,'clickOutsideToClose':!![],'locals':{'screenRecording':_0x5657b8,'screenRecordings':_0x25cc04['screenRecordings'][_0x590575('0xf5d')],'license':_0x25cc04[_0x590575('0xace')],'setting':_0x25cc04[_0x590575('0x260a')],'crudPermissions':_0x25cc04['crudPermissions']}});}function _0xa4542c(_0x555759){const _0x3301c3=_0x2b85d0;_0x2c03ef[_0x3301c3('0x1f6c')][_0x3301c3('0xd7e')]({'id':_0x555759['id']})[_0x3301c3('0xe53')]['then'](function(){const _0xecfa7a=_0x3301c3;_0x2e3ca0()[_0xecfa7a('0x3ec')](_0x25cc04['screenRecordings']['rows'],{'id':_0x555759['id']}),_0x25cc04[_0xecfa7a('0x1b50')][_0xecfa7a('0x50d')]-=0x1,!_0x25cc04[_0xecfa7a('0x1b50')][_0xecfa7a('0xf5d')][_0xecfa7a('0x1564')]&&_0x25cc04[_0xecfa7a('0x27e4')](),_0x1eb43a[_0xecfa7a('0x53')]({'title':_0x2e3ca0()[_0xecfa7a('0x1e03')](_0xecfa7a('0x1f6c'))+_0xecfa7a('0xbfc'),'msg':_0x555759['name']?_0x555759['name']+_0xecfa7a('0x194d'):''});})['catch'](function(_0x34a7cc){const _0x39c189=_0x3301c3;if(_0x34a7cc['data']&&_0x34a7cc['data']['errors']&&_0x34a7cc[_0x39c189('0x5a5')][_0x39c189('0x17f')][_0x39c189('0x1564')]){_0x25cc04['errors']=_0x34a7cc['data'][_0x39c189('0x17f')]||[{'message':_0x34a7cc[_0x39c189('0x1ff0')](),'type':_0x39c189('0x1e6d')}];for(let _0x2b8b91=0x0;_0x2b8b91<_0x34a7cc[_0x39c189('0x5a5')]['errors'][_0x39c189('0x1564')];_0x2b8b91++){_0x1eb43a[_0x39c189('0x52a')]({'title':_0x34a7cc[_0x39c189('0x5a5')]['errors'][_0x2b8b91][_0x39c189('0xcf0')],'msg':_0x34a7cc['data'][_0x39c189('0x17f')][_0x2b8b91][_0x39c189('0x8c2')]});}}else _0x1eb43a['error']({'title':_0x34a7cc[_0x39c189('0x13ee')]?_0x39c189('0x2168')+_0x34a7cc['status']+_0x39c189('0xbf6')+_0x34a7cc[_0x39c189('0x24a9')]:_0x39c189('0x1e6d'),'msg':_0x34a7cc['data']?JSON[_0x39c189('0x258a')](_0x34a7cc[_0x39c189('0x5a5')][_0x39c189('0x8c2')]):_0x34a7cc[_0x39c189('0x8c2')]||_0x34a7cc['toString']()});});}function _0x5859d0(){const _0x5c84b5=_0x2b85d0,_0x405bc7=angular[_0x5c84b5('0x1a86')](_0x25cc04[_0x5c84b5('0x101d')]);return _0x25cc04[_0x5c84b5('0x101d')]=[],_0x405bc7;}function _0xbad9e1(_0x454fca){const _0x310f9b=_0x2b85d0,_0x33b148=_0x5bf5c2['confirm']()[_0x310f9b('0xf28')](_0x310f9b('0x12a5'))[_0x310f9b('0x26e3')](_0x310f9b('0xed5')+_0x25cc04['selectedScreenRecordings'][_0x310f9b('0x1564')]+_0x310f9b('0x93c')+'\x20will\x20be\x20deleted.')[_0x310f9b('0x1040')]('delete\x20screenRecordings')[_0x310f9b('0xe42')](_0x454fca)['ok']('OK')[_0x310f9b('0x19fb')](_0x310f9b('0x16b8'));_0x5bf5c2[_0x310f9b('0x1d4')](_0x33b148)['then'](function(){const _0x12c142=_0x310f9b;_0x25cc04[_0x12c142('0x101d')][_0x12c142('0x1299')](function(_0x3799a6){_0xa4542c(_0x3799a6);}),_0x25cc04[_0x12c142('0x101d')]=[];});}function _0x2f7c8e(){const _0x2821ab=_0x2b85d0;_0x25cc04[_0x2821ab('0x101d')]=[];}function _0x144d45(){const _0x91a13c=_0x2b85d0;_0x25cc04['selectedScreenRecordings']=_0x25cc04[_0x91a13c('0x1b50')][_0x91a13c('0xf5d')];}}const _0x29d517=_0x27c7e4;_0x50894e[_0x189033('0x14be')]=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x50894e(_0x3fb8c6,_0x4bcf05){const _0xa2e7f8=_0x189033;_0x3fb8c6['state'](_0xa2e7f8('0xde6'),{'abstract':!![],'url':_0xa2e7f8('0x1e9e')})['state']('app.video.screenRecordings',{'url':_0xa2e7f8('0x20ef'),'views':{'content@app':{'templateUrl':_0x488ff5,'controller':'ScreenRecordingsController\x20as\x20vm'}},'resolve':{'screenRecordings':[_0xa2e7f8('0x4b1'),_0xa2e7f8('0xba1'),_0xa2e7f8('0x1cc2'),function(_0x2fc68e,_0x2ee735,_0x336dd6){const _0x387b7a=_0xa2e7f8;return _0x2ee735[_0x387b7a('0xca1')](_0x387b7a('0x20c2'))?_0x2fc68e[_0x387b7a('0xed7')](_0x387b7a('0xeea'),{'fields':_0x387b7a('0x11f'),'createdAt':_0x336dd6['firstLastDayMonth'](),'includeAll':_0x387b7a('0x26ac'),'sort':_0x387b7a('0xc36'),'limit':0xa,'offset':0x0}):_0x2fc68e[_0x387b7a('0xed7')]('userProfile@getResources',{'id':_0x2ee735[_0x387b7a('0x20b2')]()[_0x387b7a('0x2f')],'section':_0x387b7a('0x227f'),'fields':'createdAt,updatedAt,id,interactionid,channel,format,value,rating,UserId,duration,startedAt,closedAt','createdAt':_0x336dd6[_0x387b7a('0x11c4')](),'includeAll':'true','sort':_0x387b7a('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0xa2e7f8('0x4b1'),_0xa2e7f8('0xba1'),function(_0x47c681,_0x2331cb){const _0x2f1e21=_0xa2e7f8;return _0x2331cb[_0x2f1e21('0xca1')]('admin')?null:_0x47c681[_0x2f1e21('0xed7')](_0x2f1e21('0x1464'),{'fields':_0x2f1e21('0x16f'),'id':_0x2331cb[_0x2f1e21('0x20b2')]()[_0x2f1e21('0x2f')]});}],'userProfileSection':['apiResolver',_0xa2e7f8('0xba1'),function(_0x144ba6,_0x3a7d8c){const _0x5667bc=_0xa2e7f8;return _0x3a7d8c[_0x5667bc('0xca1')](_0x5667bc('0x20c2'))?null:_0x144ba6[_0x5667bc('0xed7')]('userProfileSection@get',{'fields':_0x5667bc('0x1f47'),'userProfileId':_0x3a7d8c[_0x5667bc('0x20b2')]()[_0x5667bc('0x2f')],'sectionId':0x7d1});}]},'authenticate':!![],'permissionId':0x7d1,'bodyClass':_0xa2e7f8('0x12a3')}),_0x4bcf05[_0xa2e7f8('0x7d2')]('app/main/apps/video');}angular[_0x189033('0x1e26')](_0x189033('0xde6'),[_0x189033('0x6cf'),'ngPassword','md.data.table',_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),'ng-sortable',_0x189033('0x2609'),_0x189033('0x273d'),_0x189033('0x76'),'mwFormBuilder',_0x189033('0x7fa'),'mwFormUtils',_0x189033('0x3b5'),'angular-cron-jobs',_0x189033('0x1447'),_0x189033('0x2645'),_0x189033('0x20c7'),_0x189033('0x1566'),_0x189033('0x19da')])[_0x189033('0x272d')](_0x50894e)[_0x189033('0x1da3')]('CreateOrEditscreenRecordingDialogController',_0x5d058f)[_0x189033('0x1da3')]('ScreenRecordingplayController',_0x577b4b)['controller']('ScreenRecordingsController',_0x29d517);const _0x311ef5=_0x180212['p']+_0x189033('0x1a57'),_0x3e7213=_0x180212['p']+_0x189033('0x1935'),_0xab101f=_0x180212['p']+_0x189033('0x26ef');_0x23c3de[_0x189033('0x14be')]=[_0x189033('0x7a5'),'$q',_0x189033('0x2f9'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x241e'),'pauses',_0x189033('0x756'),_0x189033('0x127b'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),_0x189033('0xa72'),_0x189033('0x2a'),_0x189033('0x22df'),'Auth','license',_0x189033('0x1b27')];function _0x23c3de(_0x3c887b,_0x273d98,_0x523623,_0x45caa1,_0xc80cc5,_0x313cd7,_0x32b929,_0x4bc414,_0x330a09,_0x76aebe,_0x50cf48,_0x4cfbfa,_0x2c9856,_0x2b882f,_0x432d7b,_0x74341c,_0x46f4e8,_0x26ff4e){const _0x3bb9a3=_0x189033,_0x3775e9=this,_0x412080=['userpic',_0x3bb9a3('0x2309'),_0x3bb9a3('0x10f'),'lastPauseAt',_0x3bb9a3('0x17fe'),_0x3bb9a3('0x8cc'),_0x3bb9a3('0x1d43'),_0x3bb9a3('0x2050'),_0x3bb9a3('0x1938'),_0x3bb9a3('0x1a11'),_0x3bb9a3('0x774'),_0x3bb9a3('0x1b89'),_0x3bb9a3('0x185d'),_0x3bb9a3('0x716'),_0x3bb9a3('0x1431'),_0x3bb9a3('0xd2a'),_0x3bb9a3('0x218'),_0x3bb9a3('0x2409'),_0x3bb9a3('0x205'),_0x3bb9a3('0x1484'),_0x3bb9a3('0x1079'),_0x3bb9a3('0x153b'),_0x3bb9a3('0x1f9b'),'mailCurrentCapacity',_0x3bb9a3('0x1902'),_0x3bb9a3('0xaba'),_0x3bb9a3('0x157f'),'chatStatus','openchannelStatus',_0x3bb9a3('0xb90'),_0x3bb9a3('0x2787'),_0x3bb9a3('0x2512'),_0x3bb9a3('0x278b'),_0x3bb9a3('0x15e0'),_0x3bb9a3('0x1a03'),'openchannelStatusTime',_0x3bb9a3('0xc07'),_0x3bb9a3('0x1a70'),_0x3bb9a3('0x17c2'),_0x3bb9a3('0x21d1'),_0x3bb9a3('0x23b4'),_0x3bb9a3('0x660'),_0x3bb9a3('0x10f5'),'screenrecording',_0x3bb9a3('0xa31'),'phoneBarEnableAutomaticScreenRecording'],_0x39e970=[_0x3bb9a3('0x1938'),_0x3bb9a3('0x1a11'),_0x3bb9a3('0x774'),_0x3bb9a3('0x1b89'),'whatsappPause','faxPause','voicePause','online'];_0x3775e9['currentUser']=_0x74341c[_0x3bb9a3('0x20b2')](),_0x3775e9[_0x3bb9a3('0x24d2')]=['ringing',_0x3bb9a3('0x5d7'),_0x3bb9a3('0x63'),_0x3bb9a3('0x1026'),'not_inuse'],_0x3775e9[_0x3bb9a3('0x22ab')]=_0x32b929||{'count':0x0,'rows':[]},_0x3775e9[_0x3bb9a3('0xace')]=_0x46f4e8,_0x3775e9[_0x3bb9a3('0x2a')]=_0x2b882f,_0x3775e9[_0x3bb9a3('0x22df')]=_0x432d7b&&_0x432d7b[_0x3bb9a3('0x50d')]==0x1?_0x432d7b[_0x3bb9a3('0xf5d')][0x0]:null,_0x3775e9[_0x3bb9a3('0x1134')]=_0x74341c[_0x3bb9a3('0x142a')](_0x3775e9[_0x3bb9a3('0x22df')]?_0x3775e9[_0x3bb9a3('0x22df')][_0x3bb9a3('0x1134')]:null),_0x3775e9['agents']=_0x4bc414?_0x2e3ca0()[_0x3bb9a3('0x24db')](_0x4bc414[_0x3bb9a3('0xf5d')]?_0x4bc414[_0x3bb9a3('0xf5d')]:[],'id'):{},_0x3775e9[_0x3bb9a3('0x127b')]=_0x330a09?_0x2e3ca0()[_0x3bb9a3('0x24db')](_0x330a09[_0x3bb9a3('0xf5d')]?_0x330a09['rows']:[],'id'):{},_0x3775e9['paginatedAgents']={},_0x3775e9[_0x3bb9a3('0x182c')]=![],_0x3775e9[_0x3bb9a3('0x150d')]=[],_0x3775e9[_0x3bb9a3('0x7c6')]={};for(const _0xf9ee60 in _0x3775e9[_0x3bb9a3('0x756')]){typeof _0x3775e9[_0x3bb9a3('0x756')][_0xf9ee60]!=='undefined'&&(_0x3775e9['agents'][_0xf9ee60][_0x3bb9a3('0x12f3')]=!![]);}_0x3775e9['query']={'limit':0xa,'page':0x1,'order':_0x3bb9a3('0x11bc'),'globalStatusFilter':'','pauseTypeFilter':''},_0x3775e9[_0x3bb9a3('0x1999')]=_0x5a1934,_0x3775e9['queueAdd']=_0x3deedf,_0x3775e9[_0x3bb9a3('0xa4')]=_0x405f9b,_0x3775e9[_0x3bb9a3('0x70e')]=_0x42a0e5,_0x3775e9[_0x3bb9a3('0x411')]=_0x4cedd6,_0x3775e9['getAgentStatus']=_0x2c5d2c,_0x3775e9[_0x3bb9a3('0x1bf4')]=_0x5f596e,_0x3775e9['isPause']=_0x1fe01d,_0x3775e9['checkPause']=_0x4fa916,_0x3775e9[_0x3bb9a3('0x1f68')]=_0x403773,_0x3775e9['onSave']=_0x309a09,_0x3775e9['onUpdate']=_0x31bbfa,_0x3775e9[_0x3bb9a3('0x1dd2')]=_0x852185,_0x3775e9[_0x3bb9a3('0x16b6')]=_0x40aed0,_0x3775e9[_0x3bb9a3('0x2250')]=_0xc68a,_0x3775e9[_0x3bb9a3('0x1f6c')]=_0x400368,_0x50cf48['on']('user:save',_0x3775e9[_0x3bb9a3('0x2819')]),_0x50cf48['on'](_0x3bb9a3('0x2719'),_0x3775e9[_0x3bb9a3('0x1418')]),_0x50cf48['on'](_0x3bb9a3('0x216d'),_0x3775e9['onConnect']),_0x50cf48['on'](_0x3bb9a3('0x3b6'),_0x3775e9[_0x3bb9a3('0x2250')]),_0x852185();let _0x554ee9=_0x26ff4e(function(){const _0xa6e8b8=_0x3bb9a3;_0x3775e9[_0xa6e8b8('0x182c')]&&(_0x3775e9[_0xa6e8b8('0x182c')]=![],_0x852185());},0x3e7);function _0x852185(){const _0x14374e=_0x3bb9a3;_0x3775e9[_0x14374e('0x182c')]=![];const _0x5a373f=_0x273d98['defer']();_0x3775e9[_0x14374e('0x1883')]=_0x5a373f[_0x14374e('0x1883')],_0x3775e9[_0x14374e('0xdf9')]=[],_0x3775e9[_0x14374e('0x150d')]=[],_0x2e3ca0()[_0x14374e('0x15d0')](_0x3775e9[_0x14374e('0x756')],function(_0x441384,_0x5be7b0){const _0x337fc1=_0x14374e;_0x3775e9[_0x337fc1('0x127b')][_0x5be7b0]&&_0x2e3ca0()[_0x337fc1('0xf22')](_0x441384,_0x2e3ca0()['pick'](_0x2e3ca0()[_0x337fc1('0x8b5')](_0x3775e9[_0x337fc1('0x127b')][_0x5be7b0],_0x39e970),_0x412080)),_0x5f596e(_0x441384),_0x441384[_0x337fc1('0x2309')]?(_0x3775e9['filteredAgents'][_0x337fc1('0x1fd0')](_0x441384),_0x3775e9['agentInternal'][_0x441384[_0x337fc1('0x1d43')]]=_0x5be7b0):_0x441384[_0x337fc1('0x24d')]=_0x2e3ca0()[_0x337fc1('0xea3')](_0x1aaf93()()[_0x337fc1('0x26dd')]('x'));});_0x3775e9[_0x14374e('0x23a2')][_0x14374e('0x1102')]&&_0x2e3ca0()['remove'](_0x3775e9[_0x14374e('0xdf9')],function(_0x4ab421){const _0x1b79b6=_0x14374e;return _0x4ab421[_0x1b79b6('0x12fa')]!==_0x3775e9[_0x1b79b6('0x23a2')][_0x1b79b6('0x1102')];});_0x3775e9[_0x14374e('0x23a2')][_0x14374e('0x1606')]&&_0x2e3ca0()['remove'](_0x3775e9['filteredAgents'],function(_0x39493c){const _0x48abcb=_0x14374e;return _0x39493c[_0x48abcb('0x17fe')]!==_0x3775e9['query'][_0x48abcb('0x1606')];});_0x3775e9[_0x14374e('0x23a2')]['filter']&&_0x2e3ca0()[_0x14374e('0x3ec')](_0x3775e9[_0x14374e('0xdf9')],function(_0x524fec){const _0x4e3f2f=_0x14374e;return _0x524fec[_0x4e3f2f('0x11bc')]['toLowerCase']()['indexOf'](_0x3775e9['query']['filter'][_0x4e3f2f('0x93a')]())<0x0;});_0x3775e9[_0x14374e('0xdf9')]=_0x5965d0(_0x3775e9['filteredAgents']);const _0x294c7a=(_0x3775e9[_0x14374e('0x23a2')]['page']-0x1)*_0x3775e9[_0x14374e('0x23a2')][_0x14374e('0x6f0')];_0x3775e9['paginatedAgents']=_0x2e3ca0()[_0x14374e('0x16b7')](_0x3775e9['filteredAgents'],_0x294c7a)[_0x14374e('0x12c8')](0x0,_0x3775e9[_0x14374e('0x23a2')][_0x14374e('0x6f0')]);for(let _0x266817=0x0;_0x266817<_0x3775e9[_0x14374e('0x20d5')][_0x14374e('0x1564')];_0x266817+=0x1){_0x3775e9[_0x14374e('0x150d')][_0x14374e('0x1fd0')](_0x3775e9['paginatedAgents'][_0x266817]['id']);}_0x5a373f['resolve'](),_0x3775e9[_0x14374e('0x182c')]=!![];}function _0x309a09(_0x3781dd){const _0xc0e07a=_0x3bb9a3;_0x3775e9[_0xc0e07a('0x756')][_0x3781dd['id']]&&(_0x2e3ca0()[_0xc0e07a('0xf22')](_0x3775e9['agents'][_0x3781dd['id']],_0x2e3ca0()[_0xc0e07a('0x24d0')](_0x2e3ca0()[_0xc0e07a('0x8b5')](_0x3781dd,_0x39e970),_0x412080)),_0x2e3ca0()['merge'](_0x3775e9[_0xc0e07a('0x127b')][_0x3781dd['id']],_0x2e3ca0()[_0xc0e07a('0x24d0')](_0x2e3ca0()[_0xc0e07a('0x8b5')](_0x3781dd,_0x39e970),_0x412080)),_0x5f596e(_0x3775e9[_0xc0e07a('0x756')][_0x3781dd['id']]));}function _0x31bbfa(_0x1e7130){const _0x1bc792=_0x3bb9a3;_0x3775e9[_0x1bc792('0x756')][_0x1e7130['id']]&&(_0x2e3ca0()['merge'](_0x3775e9['agents'][_0x1e7130['id']],_0x2e3ca0()['pick'](_0x1e7130,_0x412080)),_0x2e3ca0()['merge'](_0x3775e9[_0x1bc792('0x127b')][_0x1e7130['id']],_0x2e3ca0()['pick'](_0x1e7130,_0x412080)),_0x1e7130['lastPauseAt']&&(_0x3775e9['agents'][_0x1e7130['id']][_0x1bc792('0x24d')]=_0x1e7130[_0x1bc792('0x8cc')],_0x3775e9['rpcAgents'][_0x1e7130['id']]['globalStatusTime']=_0x1e7130[_0x1bc792('0x8cc')]),_0x5f596e(_0x3775e9[_0x1bc792('0x756')][_0x1e7130['id']]));}function _0x40aed0(_0x4b0e99){const _0xa18d0=_0x3bb9a3;_0x3775e9[_0xa18d0('0x756')][_0x3775e9['agentInternal'][_0x4b0e99[_0xa18d0('0x1d79')]]]&&(_0x2e3ca0()[_0xa18d0('0xf22')](_0x3775e9[_0xa18d0('0x756')][_0x3775e9[_0xa18d0('0x7c6')][_0x4b0e99[_0xa18d0('0x1d79')]]],_0x2e3ca0()[_0xa18d0('0x24d0')](_0x4b0e99,[_0xa18d0('0x660'),_0xa18d0('0x10f5')])),_0x2e3ca0()[_0xa18d0('0xf22')](_0x3775e9[_0xa18d0('0x127b')][_0x3775e9[_0xa18d0('0x7c6')][_0x4b0e99[_0xa18d0('0x1d79')]]],_0x2e3ca0()[_0xa18d0('0x24d0')](_0x4b0e99,[_0xa18d0('0x660'),_0xa18d0('0x10f5')])));}function _0xc68a(_0x5e71fd){const _0x143fb9=_0x3bb9a3;_0x3775e9[_0x143fb9('0x756')][_0x3775e9[_0x143fb9('0x7c6')][_0x5e71fd[_0x143fb9('0x1d79')]]]&&(_0x3775e9['agents'][_0x3775e9['agentInternal'][_0x5e71fd[_0x143fb9('0x1d79')]]]=_0x2e3ca0()[_0x143fb9('0x8b5')](_0x3775e9[_0x143fb9('0x756')][_0x3775e9['agentInternal'][_0x5e71fd[_0x143fb9('0x1d79')]]],[_0x143fb9('0x660'),'destconnectedlinenum']),_0x3775e9['rpcAgents'][_0x3775e9[_0x143fb9('0x7c6')][_0x5e71fd[_0x143fb9('0x1d79')]]]=_0x2e3ca0()[_0x143fb9('0x8b5')](_0x3775e9[_0x143fb9('0x127b')][_0x3775e9[_0x143fb9('0x7c6')][_0x5e71fd['destaccountcode']]],[_0x143fb9('0x660'),_0x143fb9('0x10f5')]));}function _0x5a1934(_0xe8c2ef){const _0xc1bdc9=_0x3bb9a3;return _0x76aebe[_0xc1bdc9('0xc96')][_0xc1bdc9('0x1999')]({'id':_0xe8c2ef['id'],'device':_0xc1bdc9('0x2c9'),'agent_id':_0xe8c2ef['id'],'agent_name':_0xe8c2ef[_0xc1bdc9('0x60a')]})['$promise'][_0xc1bdc9('0x683')](function(){const _0x53f988=_0xc1bdc9;_0x4cfbfa[_0x53f988('0x53')]({'title':_0x53f988('0x1683'),'msg':_0xe8c2ef['fullname']+_0x53f988('0x2488')}),_0x3775e9[_0x53f988('0x756')][_0xe8c2ef['id']]&&(_0x3775e9[_0x53f988('0x756')][_0xe8c2ef['id']]['online']=![]),_0x3775e9[_0x53f988('0x127b')][_0xe8c2ef['id']]&&(_0x3775e9[_0x53f988('0x127b')][_0xe8c2ef['id']]['online']=![]),_0x852185();})['catch'](function(_0x4042ba){const _0x52a3b5=_0xc1bdc9;_0x4cfbfa[_0x52a3b5('0x52a')]({'title':_0x4042ba[_0x52a3b5('0x13ee')]?_0x52a3b5('0x2168')+_0x4042ba[_0x52a3b5('0x13ee')]+_0x52a3b5('0xbf6')+_0x4042ba[_0x52a3b5('0x24a9')]:_0x52a3b5('0x154f'),'msg':_0x4042ba[_0x52a3b5('0x5a5')]?JSON['stringify'](_0x4042ba[_0x52a3b5('0x5a5')]['message']):_0x4042ba[_0x52a3b5('0x1ff0')]()});});}function _0x405f9b(_0x411ae2,_0xcae4f){const _0x3d0eb2=_0x3bb9a3;return _0x76aebe[_0x3d0eb2('0xc96')][_0x3d0eb2('0xa4')]({'id':_0x411ae2['id'],'type':_0xcae4f})[_0x3d0eb2('0xe53')][_0x3d0eb2('0x683')](function(_0x196eb7){const _0x170b02=_0x3d0eb2;_0x3775e9[_0x170b02('0x756')][_0x411ae2['id']]&&_0x2e3ca0()[_0x170b02('0xf22')](_0x3775e9['agents'][_0x411ae2['id']],_0x2e3ca0()[_0x170b02('0x24d0')](_0x196eb7,_0x412080)),_0x3775e9[_0x170b02('0x127b')][_0x411ae2['id']]&&_0x2e3ca0()['merge'](_0x3775e9['rpcAgents'][_0x411ae2['id']],_0x2e3ca0()['pick'](_0x196eb7,_0x412080)),_0x5f596e(_0x3775e9[_0x170b02('0x756')][_0x411ae2['id']]);})[_0x3d0eb2('0x130a')](function(_0x2ef461){const _0x315f11=_0x3d0eb2;_0x4cfbfa[_0x315f11('0x52a')]({'title':_0x2ef461[_0x315f11('0x13ee')]?_0x315f11('0x2168')+_0x2ef461[_0x315f11('0x13ee')]+'\x20-\x20'+_0x2ef461['statusText']:'api.staff.save','msg':_0x2ef461[_0x315f11('0x5a5')]?JSON['stringify'](_0x2ef461[_0x315f11('0x5a5')][_0x315f11('0x8c2')]):_0x2ef461['toString']()});});}function _0x42a0e5(_0x5b3c2e){const _0x1525e5=_0x3bb9a3;return _0x76aebe[_0x1525e5('0xc96')][_0x1525e5('0x1778')]({'id':_0x5b3c2e['id']})['$promise']['then'](function(_0x3f97fe){const _0x17db56=_0x1525e5;_0x3775e9[_0x17db56('0x756')][_0x5b3c2e['id']]&&_0x2e3ca0()[_0x17db56('0xf22')](_0x3775e9['agents'][_0x5b3c2e['id']],_0x2e3ca0()[_0x17db56('0x24d0')](_0x3f97fe,_0x412080)),_0x3775e9[_0x17db56('0x127b')][_0x5b3c2e['id']]&&_0x2e3ca0()[_0x17db56('0xf22')](_0x3775e9[_0x17db56('0x127b')][_0x5b3c2e['id']],_0x2e3ca0()[_0x17db56('0x24d0')](_0x3f97fe,_0x412080)),_0x5f596e(_0x3775e9[_0x17db56('0x756')][_0x5b3c2e['id']]);})[_0x1525e5('0x130a')](function(_0x364296){const _0x5d3375=_0x1525e5;_0x4cfbfa[_0x5d3375('0x52a')]({'title':_0x364296['status']?'API:'+_0x364296[_0x5d3375('0x13ee')]+_0x5d3375('0xbf6')+_0x364296[_0x5d3375('0x24a9')]:_0x5d3375('0x154f'),'msg':_0x364296[_0x5d3375('0x5a5')]?JSON[_0x5d3375('0x258a')](_0x364296[_0x5d3375('0x5a5')][_0x5d3375('0x8c2')]):_0x364296['toString']()});});}function _0x4cedd6(_0x227031){const _0x49abf6=_0x3bb9a3;_0x45caa1[_0x49abf6('0x1d4')](_0x45caa1[_0x49abf6('0x2430')]()[_0x49abf6('0x188f')](!![])[_0x49abf6('0xf28')](_0x49abf6('0x71a'))[_0x49abf6('0x26e3')](_0x49abf6('0x1f0'))['ok']('Ok')['targetEvent'](_0x227031));}function _0x3deedf(_0x21a82b,_0x46138a){const _0x738381=_0x3bb9a3;_0x45caa1[_0x738381('0x1d4')]({'controller':'AgentqueueaddController','controllerAs':'vm','templateUrl':_0xf3687b,'parent':angular[_0x738381('0x1fcc')](_0xc80cc5[_0x738381('0x18e5')]),'targetEvent':_0x46138a,'clickOutsideToClose':!![],'locals':{'agent':_0x21a82b,'agents':[],'channel':_0x738381('0x16e7'),'direction':'inbound','crudPermissions':_0x3775e9['crudPermissions']}});}function _0x1fe01d(_0x36b2c8){const _0x5095f1=_0x3bb9a3;return _0x36b2c8==='pause'||_0x36b2c8===_0x5095f1('0x651');}function _0x4fa916(_0x5143ba){const _0x73acda=_0x3bb9a3;return _0x5143ba===_0x73acda('0xa4');}function _0x403773(_0xd0f5b9){const _0x218b4e=_0x3bb9a3;return _0xd0f5b9===_0x218b4e('0x651');}function _0x1beceb(_0x316ff1){const _0x263ec4=_0x3bb9a3;return _0x316ff1===_0x263ec4('0x1586')||_0x316ff1==='unknown'||_0x316ff1===_0x263ec4('0x19d2')||_0x316ff1===_0x263ec4('0x2727')||_0x2e3ca0()[_0x263ec4('0x8f2')](_0x316ff1);}function _0x2c5d2c(_0x4e4feb,_0x525273){const _0x38e776=_0x3bb9a3;if(_0x525273===_0x38e776('0xcf2')){if(_0x4e4feb[_0x525273+_0x38e776('0x1d9d')]!==_0x38e776('0x1586'))return _0x4e4feb[_0x525273+_0x38e776('0x1d9d')];if(_0x4e4feb[_0x525273+_0x38e776('0x2113')])return _0x4e4feb[_0x525273+'Status']=_0x38e776('0xa4'),'pause';return'idle';}else{if(_0x4e4feb[_0x525273+_0x38e776('0x2113')])return _0x4e4feb[_0x525273+_0x38e776('0x1d9d')]=_0x38e776('0xa4'),_0x38e776('0xa4');return _0x4e4feb[_0x525273+_0x38e776('0x1d9d')];}}function _0x5f596e(_0x3e6ec1){const _0x5ae179=_0x3bb9a3;let _0x1e3ed7=_0x5ae179('0xdd4');if(_0x2e3ca0()['every']([_0x2c5d2c(_0x3e6ec1,'voice'),_0x2c5d2c(_0x3e6ec1,'chat'),_0x2c5d2c(_0x3e6ec1,'mail'),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x1261')),_0x2c5d2c(_0x3e6ec1,'sms'),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x16e7')),_0x2c5d2c(_0x3e6ec1,'fax')],_0x1fe01d))_0x1e3ed7=_0x5ae179('0xa4');else{if(_0x2e3ca0()['some']([_0x2c5d2c(_0x3e6ec1,'voice'),_0x2c5d2c(_0x3e6ec1,'chat'),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x129f')),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x1261')),_0x2c5d2c(_0x3e6ec1,'sms'),_0x2c5d2c(_0x3e6ec1,'whatsapp'),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x23e9'))],_0x1fe01d))_0x1e3ed7='*pause';else _0x2e3ca0()[_0x5ae179('0x161')]([_0x2c5d2c(_0x3e6ec1,_0x5ae179('0xcf2')),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x24e')),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x129f')),_0x2c5d2c(_0x3e6ec1,'openchannel'),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x1285')),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x16e7')),_0x2c5d2c(_0x3e6ec1,_0x5ae179('0x23e9'))],_0x1beceb)?_0x1e3ed7=_0x5ae179('0x1586'):_0x1e3ed7=_0x5ae179('0x63');}_0x3e6ec1[_0x5ae179('0x12fa')]!==_0x1e3ed7&&(_0x3e6ec1[_0x5ae179('0x12fa')]=_0x1e3ed7,_0x3e6ec1[_0x5ae179('0x12f3')]?(_0x3e6ec1[_0x5ae179('0x12f3')]=![],_0x3e6ec1['globalStatusTime']=_0x1fe01d(_0x1e3ed7)?_0x2e3ca0()[_0x5ae179('0xea3')](_0x1aaf93()(_0x3e6ec1['lastPauseAt'])[_0x5ae179('0x26dd')]('x')):_0x2e3ca0()[_0x5ae179('0x69b')]([_0x3e6ec1[_0x5ae179('0x23b4')],_0x3e6ec1[_0x5ae179('0x1a03')],_0x3e6ec1['mailStatusTime'],_0x3e6ec1['smsStatusTime'],_0x3e6ec1['whatsappStatusTime'],_0x3e6ec1[_0x5ae179('0x15db')],_0x3e6ec1['faxStatusTime']])):_0x3e6ec1[_0x5ae179('0x24d')]=_0x2e3ca0()[_0x5ae179('0xea3')](_0x1aaf93()()[_0x5ae179('0x26dd')]('x')));}function _0x5965d0(_0x179698){const _0x4247d8=_0x3bb9a3,_0x21a15e=_0x2e3ca0()[_0x4247d8('0x18ad')](_0x3775e9[_0x4247d8('0x23a2')]['order'],'-')?_0x4247d8('0x1f5a'):_0x4247d8('0xe38');return _0x2e3ca0()[_0x4247d8('0x2ef')](_0x179698,[_0x3775e9[_0x4247d8('0x23a2')][_0x4247d8('0x150d')][_0x4247d8('0x1725')]('-','')],[_0x21a15e]);}function _0x21d8ce(){const _0x3cc942=_0x3bb9a3;_0x554ee9&&(_0x26ff4e[_0x3cc942('0x19fb')](_0x554ee9),_0x554ee9=null);}function _0x400368(_0x2061af,_0x256221){const _0x131c3d=_0x3bb9a3;return _0x76aebe[_0x131c3d('0xc96')][_0x131c3d('0x2480')]({'id':_0x2061af['id']},{'screenrecording':_0x256221})[_0x131c3d('0xe53')][_0x131c3d('0x130a')](function(_0x53a678){const _0x56673a=_0x131c3d;_0x4cfbfa['error']({'title':_0x53a678[_0x56673a('0x13ee')]?_0x56673a('0x2168')+_0x53a678[_0x56673a('0x13ee')]+'\x20-\x20'+_0x53a678[_0x56673a('0x24a9')]:_0x56673a('0x162b'),'msg':_0x53a678[_0x56673a('0x5a5')]?JSON[_0x56673a('0x258a')](_0x53a678['data'][_0x56673a('0x8c2')]):_0x53a678[_0x56673a('0x1ff0')]()});});}_0x3c887b['$on']('$destroy',function(){const _0x4ca76a=_0x3bb9a3;_0x50cf48['removeAllListeners'](_0x4ca76a('0x18f0')),_0x50cf48[_0x4ca76a('0x1b9e')](_0x4ca76a('0x2719')),_0x50cf48[_0x4ca76a('0x1b9e')](_0x4ca76a('0x216d')),_0x50cf48[_0x4ca76a('0x1b9e')](_0x4ca76a('0x3b6')),_0x21d8ce();});}const _0x13a224=_0x23c3de,_0x33b6fa=_0x180212['p']+_0x189033('0x190'),_0xd72f1d=_0x180212['p']+_0x189033('0x1b2d');_0x22a343[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2f9'),_0x189033('0x1e48'),'$q',_0x189033('0x16ea'),_0x189033('0x1b27'),_0x189033('0x2da'),_0x189033('0x1a10'),_0x189033('0x56b'),_0x189033('0x1556'),_0x189033('0x1d70'),'userProfile',_0x189033('0x22df'),_0x189033('0xba1')];function _0x22a343(_0x35c3ed,_0x2e52b2,_0xd7afe8,_0x6c4380,_0x357583,_0x5047ff,_0x3a3a42,_0x3a3102,_0x37cf95,_0x33ce22,_0xc6d5ea,_0x17553b,_0x503c2b,_0xa50168){const _0x1590e9=_0x189033,_0x245641=this,_0x22086c=[_0x1590e9('0x1506'),'available','waiting',_0x1590e9('0x7a4'),'pTalking',_0x1590e9('0x1a95'),_0x1590e9('0x8c2'),_0x1590e9('0x1455'),_0x1590e9('0x1091'),'Trunk','paused'];_0x245641[_0x1590e9('0x11ed')]=_0xa50168['getCurrentUser'](),_0x245641[_0x1590e9('0x50d')]=_0x3a3a42[_0x1590e9('0x50d')]?_0x3a3a42['count']:0x0,_0x245641[_0x1590e9('0x2da')]=_0x3a3a42?_0x2e3ca0()[_0x1590e9('0x24db')](_0x3a3a42[_0x1590e9('0xf5d')]?_0x3a3a42[_0x1590e9('0xf5d')]:[],'id'):{},_0x245641['rpcQueues']=_0x3a3102?_0x2e3ca0()['keyBy'](_0x3a3102['rows']?_0x3a3102[_0x1590e9('0xf5d')]:[],'id'):{},_0x245641[_0x1590e9('0x2a')]=_0x17553b,_0x245641['userProfileSection']=_0x503c2b&&_0x503c2b[_0x1590e9('0x50d')]==0x1?_0x503c2b[_0x1590e9('0xf5d')][0x0]:null,_0x245641['crudPermissions']=_0xa50168['parseCrudPermissions'](_0x245641[_0x1590e9('0x22df')]?_0x245641[_0x1590e9('0x22df')][_0x1590e9('0x1134')]:null);_0xa50168[_0x1590e9('0xca1')]('admin')?_0x245641['query']={'type':_0x1590e9('0x1535'),'sort':_0x1590e9('0xc36'),'limit':0xa,'page':0x1}:_0x245641[_0x1590e9('0x23a2')]={'id':_0x245641[_0x1590e9('0x11ed')]['id'],'channel':_0x1590e9('0x16e7'),'type':'inbound','sort':_0x1590e9('0xc36'),'limit':0xa,'page':0x1};_0x245641[_0x1590e9('0x53')]=_0x119b71,_0x245641[_0x1590e9('0x4c9')]=_0x57e5ae,_0x245641[_0x1590e9('0x1057')]=_0x112667,_0x245641[_0x1590e9('0x1a94')]=_0x2abd68,_0x245641[_0x1590e9('0x1f7c')]=_0x2a44e9,_0x245641[_0x1590e9('0x2819')]=_0x682197,_0x245641[_0x1590e9('0x3ae')]=_0x1ca49f,_0x245641[_0x1590e9('0x203e')]=_0x55f695,_0x245641[_0x1590e9('0x4a5')]=_0xbb2c37,_0x245641[_0x1590e9('0xd8b')]=_0x1c5d75,_0x245641[_0x1590e9('0xb2b')]=_0x26d5ca,_0x245641[_0x1590e9('0x3a8')]=_0x5a8e4c,_0x245641[_0x1590e9('0x150d')]=[],_0x2e3ca0()[_0x1590e9('0x15d0')](_0x245641[_0x1590e9('0x2da')],function(_0x3e8ca6){const _0x1173be=_0x1590e9;_0x245641[_0x1173be('0x150d')][_0x1173be('0x1fd0')](_0x3e8ca6['id']);}),_0x33ce22['on'](_0x1590e9('0x971'),_0x245641[_0x1590e9('0x2819')]),_0x33ce22['on'](_0x1590e9('0xcbf'),_0x245641['onSaveMember']),_0x33ce22['on'](_0x1590e9('0x15b'),_0x245641[_0x1590e9('0x203e')]),_0x33ce22['on'](_0x1590e9('0x2719'),_0x245641['onPause']),_0x33ce22['on'](_0x1590e9('0x56f'),_0x245641[_0x1590e9('0xb2b')]),_0x33ce22['on'](_0x1590e9('0x217c'),_0x245641['onLogin']);function _0x5a8e4c(){const _0x18a33e=_0x1590e9,_0x1a8305=[];return _0x2e3ca0()[_0x18a33e('0x15d0')](_0x245641[_0x18a33e('0x2da')],function(_0x4f2a52,_0x43b817){const _0x4ae158=_0x18a33e;_0x4f2a52[_0x4ae158('0x1a1d')]=0x0,_0x4f2a52[_0x4ae158('0x25a4')]=0x0,_0x245641['queues'][_0x43b817][_0x4ae158('0x756')]={},_0x1a8305['push'](_0x37cf95[_0x4ae158('0x25e5')][_0x4ae158('0x27cf')]({'id':_0x43b817})[_0x4ae158('0xe53')]),_0x245641[_0x4ae158('0x1a10')][_0x43b817]&&_0x2e3ca0()[_0x4ae158('0xf22')](_0x4f2a52,_0x2e3ca0()[_0x4ae158('0x24d0')](_0x245641[_0x4ae158('0x1a10')][_0x43b817],_0x22086c));}),_0x6c4380[_0x18a33e('0x252c')](_0x1a8305)[_0x18a33e('0x683')](function(_0x89c399){const _0x25223a=_0x18a33e;for(let _0x464d8e=0x0;_0x464d8e<_0x89c399[_0x25223a('0x1564')];_0x464d8e+=0x1){for(let _0x5ad437=0x0;_0x5ad437<_0x89c399[_0x464d8e]['rows']['length'];_0x5ad437++){_0x89c399[_0x464d8e]['rows'][_0x5ad437][_0x25223a('0x1a1d')]&&_0x245641[_0x25223a('0x2da')][_0x89c399[_0x464d8e][_0x25223a('0xf5d')][_0x5ad437][_0x25223a('0x1634')]][_0x25223a('0x1a1d')]++,_0x245641[_0x25223a('0x2da')][_0x89c399[_0x464d8e][_0x25223a('0xf5d')][_0x5ad437][_0x25223a('0x1634')]]['loggedInDb']++,_0x245641[_0x25223a('0x2da')][_0x89c399[_0x464d8e][_0x25223a('0xf5d')][_0x5ad437][_0x25223a('0x1634')]][_0x25223a('0x756')][_0x89c399[_0x464d8e]['rows'][_0x5ad437]['UserId']]=_0x89c399[_0x464d8e][_0x25223a('0xf5d')][_0x5ad437]['WhatsappQueueId'];}}})[_0x18a33e('0x130a')](function(_0x5be43e){console['error'](_0x5be43e);});}function _0x682197(_0x3a11ff){const _0x44ffff=_0x1590e9;_0x245641[_0x44ffff('0x2da')][_0x3a11ff['id']]&&_0x2e3ca0()[_0x44ffff('0xf22')](_0x245641['queues'][_0x3a11ff['id']],_0x2e3ca0()[_0x44ffff('0x24d0')](_0x3a11ff,_0x22086c));}function _0x1ca49f(_0x4877ec){const _0x3409fb=_0x1590e9;_0x245641[_0x3409fb('0x2da')][_0x4877ec[_0x3409fb('0x1634')]]&&_0x245641['queues'][_0x4877ec['WhatsappQueueId']][_0x3409fb('0x25a4')]++;}function _0x55f695(_0x237238){const _0x100eea=_0x1590e9;_0x245641[_0x100eea('0x2da')][_0x237238['WhatsappQueueId']]&&_0x245641[_0x100eea('0x2da')][_0x237238[_0x100eea('0x1634')]][_0x100eea('0x25a4')]--;}function _0xbb2c37(_0x467200){const _0x3e7e79=_0x1590e9;console[_0x3e7e79('0x1b2b')](_0x3e7e79('0x4a5'),_0x467200);if(_0x467200[_0x3e7e79('0x1431')])_0x2e3ca0()[_0x3e7e79('0x15d0')](_0x245641[_0x3e7e79('0x2da')],function(_0x56f246){const _0x130b07=_0x3e7e79;_0x56f246['agents'][_0x467200['id']]&&(_0x56f246[_0x130b07('0x1a1d')]+=0x1,console[_0x130b07('0x1b2b')](_0x130b07('0xa4')));});else!_0x467200[_0x3e7e79('0x1431')]&&_0x2e3ca0()[_0x3e7e79('0x15d0')](_0x245641[_0x3e7e79('0x2da')],function(_0x3d5d0f){const _0x57f0c4=_0x3e7e79;_0x3d5d0f[_0x57f0c4('0x756')][_0x467200['id']]&&(_0x3d5d0f['paused']>0x0&&(_0x3d5d0f[_0x57f0c4('0x1a1d')]-=0x1,console[_0x57f0c4('0x1b2b')](_0x57f0c4('0x1778'))));});}function _0x1c5d75(_0x436a95){const _0x3ca87f=_0x1590e9;console[_0x3ca87f('0x1b2b')](_0x3ca87f('0x16aa'),_0x436a95),_0x245641[_0x3ca87f('0x2da')][_0x436a95[_0x3ca87f('0x1634')]]&&(_0x245641['queues'][_0x436a95[_0x3ca87f('0x1634')]][_0x3ca87f('0x25a4')]+=0x1,_0x245641['queues'][_0x436a95[_0x3ca87f('0x1634')]]['agents'][_0x436a95[_0x3ca87f('0x10c5')]]=_0x436a95[_0x3ca87f('0x1634')]);}function _0x26d5ca(_0x4de6c6){const _0x12feda=_0x1590e9;console[_0x12feda('0x1b2b')](_0x12feda('0xb2b'),_0x4de6c6),_0x245641[_0x12feda('0x2da')][_0x4de6c6[_0x12feda('0x1634')]]&&_0x245641['queues'][_0x4de6c6[_0x12feda('0x1634')]][_0x12feda('0x25a4')]>0x0&&(_0x245641[_0x12feda('0x2da')][_0x4de6c6[_0x12feda('0x1634')]][_0x12feda('0x25a4')]-=0x1,delete _0x245641[_0x12feda('0x2da')][_0x4de6c6[_0x12feda('0x1634')]][_0x12feda('0x756')][_0x4de6c6[_0x12feda('0x10c5')]]);}let _0x4bae41=!![],_0x353fe6=0x1;_0x35c3ed[_0x1590e9('0x186d')](_0x1590e9('0x1e1d'),function(_0x52af2d,_0x5ddc3d){const _0xb71a1c=_0x1590e9;_0x4bae41?_0x2e52b2(function(){_0x4bae41=![];}):(!_0x5ddc3d&&(_0x353fe6=_0x245641[_0xb71a1c('0x23a2')][_0xb71a1c('0xdf8')]),_0x52af2d!==_0x5ddc3d&&(_0x245641[_0xb71a1c('0x23a2')]['page']=0x1),!_0x52af2d&&(_0x245641['query'][_0xb71a1c('0xdf8')]=_0x353fe6),_0x245641['getQueues']());});function _0x119b71(_0x3f16a7){const _0x25ee5a=_0x1590e9;_0x245641[_0x25ee5a('0x50d')]=_0x3f16a7[_0x25ee5a('0x50d')],_0x245641[_0x25ee5a('0x2da')]=_0x3f16a7?_0x2e3ca0()[_0x25ee5a('0x24db')](_0x3f16a7[_0x25ee5a('0xf5d')]?_0x3f16a7[_0x25ee5a('0xf5d')]:[],'id'):{};if(_0x3f16a7[_0x25ee5a('0xf5d')]){_0x245641['order']=[];for(let _0x4aa357=0x0;_0x4aa357<_0x3f16a7[_0x25ee5a('0xf5d')][_0x25ee5a('0x1564')];_0x4aa357++){_0x245641[_0x25ee5a('0x150d')][_0x25ee5a('0x1fd0')](_0x3f16a7[_0x25ee5a('0xf5d')][_0x4aa357]['id']);}}_0x5a8e4c();}function _0x57e5ae(){const _0x524c66=_0x1590e9;_0x245641['query'][_0x524c66('0x1cc8')]=(_0x245641[_0x524c66('0x23a2')]['page']-0x1)*_0x245641[_0x524c66('0x23a2')][_0x524c66('0x6f0')],_0xa50168[_0x524c66('0xca1')](_0x524c66('0x20c2'))?_0x245641['promise']=_0x37cf95['whatsappQueue'][_0x524c66('0x1e6e')](_0x245641[_0x524c66('0x23a2')],_0x119b71)[_0x524c66('0xe53')]:(_0x245641['query']['id']=_0x245641[_0x524c66('0x2a')]['id'],_0x245641[_0x524c66('0x23a2')]['section']=_0x524c66('0x20e4'),_0x245641[_0x524c66('0x1883')]=_0x37cf95[_0x524c66('0x2a')][_0x524c66('0x241d')](_0x245641[_0x524c66('0x23a2')],_0x119b71)[_0x524c66('0xe53')]);}function _0x112667(_0x37263f,_0x48df83){const _0x5c932=_0x1590e9;_0xd7afe8[_0x5c932('0x1d4')]({'controller':_0x5c932('0x248a'),'controllerAs':'vm','templateUrl':_0x33b6fa,'parent':angular[_0x5c932('0x1fcc')](_0x357583[_0x5c932('0x18e5')]),'targetEvent':_0x37263f,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x48df83,'whatsappQueues':_0x2e3ca0()['values'](_0x245641[_0x5c932('0x2da')]),'license':null,'setting':null,'crudPermissions':_0x245641[_0x5c932('0x1134')]}});}function _0x2abd68(_0x21acb1,_0x70c5df){const _0x2f4bea=_0x1590e9;_0xd7afe8[_0x2f4bea('0x1d4')]({'controller':_0x2f4bea('0xf81'),'controllerAs':'vm','templateUrl':_0xd72f1d,'parent':angular[_0x2f4bea('0x1fcc')](_0x357583[_0x2f4bea('0x18e5')]),'targetEvent':_0x21acb1,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x70c5df,'whatsappQueues':_0x245641[_0x2f4bea('0x2da')]?_0x245641[_0x2f4bea('0x2da')][_0x2f4bea('0xf5d')]:[],'realtime':![],'crudPermissions':_0x245641[_0x2f4bea('0x1134')]}});}function _0x2a44e9(_0x4f84ca){const _0x24bbc5=_0x1590e9;return _0x37cf95['whatsappQueue'][_0x24bbc5('0x2480')](_0x4f84ca)[_0x24bbc5('0xe53')][_0x24bbc5('0x683')](function(){const _0xd4895e=_0x24bbc5;_0xc6d5ea[_0xd4895e('0x53')]({'title':_0xd4895e('0x5c7'),'msg':_0x4f84ca[_0xd4895e('0x60a')]?_0x4f84ca[_0xd4895e('0x60a')]+_0xd4895e('0x96c'):''});})[_0x24bbc5('0x130a')](function(_0x2c9d09){const _0x45976a=_0x24bbc5;_0xc6d5ea[_0x45976a('0x52a')]({'title':_0x45976a('0xb4'),'msg':_0x2c9d09[_0x45976a('0x8c2')]});});}_0x35c3ed[_0x1590e9('0x26a2')](_0x1590e9('0x4b8'),function(){const _0x33ca24=_0x1590e9;_0x33ce22[_0x33ca24('0x1b9e')](_0x33ca24('0x971')),_0x33ce22[_0x33ca24('0x1b9e')]('userWhatsappQueue:remove'),_0x33ce22[_0x33ca24('0x1b9e')](_0x33ca24('0xcbf')),_0x33ce22[_0x33ca24('0x1b9e')]('user:update'),_0x33ce22[_0x33ca24('0x1b9e')]('userVoiceQueue:remove'),_0x33ce22[_0x33ca24('0x1b9e')](_0x33ca24('0x217c'));});}const _0x29d5ab=_0x22a343;function _0x46ff13(){const _0x62a7e0=_0x189033;return{'status':{'registered':_0x62a7e0('0x584'),'unregistered':_0x62a7e0('0x1da'),'lagged':_0x62a7e0('0x1da'),'reachable':_0x62a7e0('0x584'),'unreachable':'red-300-fg\x20icon-close-circle','unknown':_0x62a7e0('0xcb0')},'state':{'unknown':'grey-fg\x20icon-phone-hangup','not_inuse':_0x62a7e0('0x280d'),'inuse':_0x62a7e0('0x10c0'),'busy':_0x62a7e0('0x25ad'),'invalid':_0x62a7e0('0x27f9'),'unavailable':_0x62a7e0('0x27f9'),'ringing':'blue-300-fg\x20icon-phone-incoming','ringinuse':_0x62a7e0('0x20f0'),'onhold':_0x62a7e0('0x1a52')},'channelStatus':{'ring':_0x62a7e0('0x20f0'),'up':'green-300-fg\x20icon-phone-in-talk','hangup':_0x62a7e0('0x22be')},'channelStatusOut':{'ring':'blue-300-fg\x20icon-phone-outgoing','up':'green-300-fg\x20icon-phone-in-talk','hangup':_0x62a7e0('0x22be')}};}const _0x4670c6=_0x46ff13;_0x262427[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0x1556')];function _0x262427(_0xa9bb78,_0x551695,_0x112e01){const _0xff3ca6=_0x189033,_0x4aced4=this;_0x112e01[_0xff3ca6('0x1346')](),_0x112e01[_0xff3ca6('0x12ac')](),_0x4aced4[_0xff3ca6('0x517')]=0x0;switch(_0x551695[_0xff3ca6('0xb24')]['name']){case _0xff3ca6('0x12df'):_0x4aced4[_0xff3ca6('0x517')]=0x0;break;case _0xff3ca6('0x24c0'):_0x4aced4['selectedTab']=0x1;break;default:_0x4aced4[_0xff3ca6('0x517')]=0x0,_0x551695['go'](_0xff3ca6('0x12df'));}_0xa9bb78[_0xff3ca6('0x186d')](_0xff3ca6('0x9a4'),function(_0x2a71a5,_0x1ffcc3){const _0x315861=_0xff3ca6;if(_0x2a71a5!==_0x1ffcc3)switch(_0x2a71a5){case 0x0:_0x551695['go'](_0x315861('0x12df'));break;case 0x1:_0x551695['go'](_0x315861('0x24c0'));break;default:_0x551695['go'](_0x315861('0x12df'));break;}});}const _0x2ca7d0=_0x262427;_0x26ffc5[_0x189033('0x14be')]=[_0x189033('0x1398')];function _0x26ffc5(_0x5d36f5){const _0x47b702=_0x189033;_0x5d36f5[_0x47b702('0x2598')](_0x47b702('0x30c'),{'url':_0x47b702('0xf7c'),'views':{'content@app':{'templateUrl':_0x311ef5,'controller':_0x47b702('0x2f4')}},'resolve':{'userProfile':[_0x47b702('0x4b1'),_0x47b702('0xba1'),function(_0x21b5dc,_0x1b4420){const _0x4804af=_0x47b702;return _0x1b4420[_0x4804af('0xca1')]('admin')?null:_0x21b5dc[_0x4804af('0xed7')](_0x4804af('0x1464'),{'fields':'id,name,crudPermissions','id':_0x1b4420[_0x4804af('0x20b2')]()[_0x4804af('0x2f')]});}],'userProfileSection':[_0x47b702('0x4b1'),_0x47b702('0xba1'),function(_0x1c7ec2,_0x397cd7){const _0x144514=_0x47b702;return _0x397cd7['hasRole'](_0x144514('0x20c2'))?null:_0x1c7ec2['resolve'](_0x144514('0x360'),{'fields':_0x144514('0x1f47'),'userProfileId':_0x397cd7['getCurrentUser']()['userProfileId'],'sectionId':0x83e});}]},'authenticate':!![],'permissionId':0x83e})[_0x47b702('0x2598')](_0x47b702('0x12df'),{'url':_0x47b702('0xf1a'),'controller':_0x47b702('0x18b4'),'templateUrl':_0x3e7213,'resolve':{'pauses':[_0x47b702('0x4b1'),function(_0x502d70){const _0x25156e=_0x47b702;return _0x502d70[_0x25156e('0xed7')]('pause@get',{'nolimit':!![]});}],'agents':[_0x47b702('0x4b1'),_0x47b702('0xba1'),function(_0x4d33a0,_0x1989ed){const _0x157c62=_0x47b702;return _0x1989ed[_0x157c62('0xca1')](_0x157c62('0x20c2'))?_0x4d33a0[_0x157c62('0xed7')](_0x157c62('0x25c9'),{'fields':_0x157c62('0x174e'),'role':_0x157c62('0x2327'),'sort':_0x157c62('0x11bc'),'nolimit':!![]}):_0x4d33a0['resolve'](_0x157c62('0x191b'),{'id':_0x1989ed[_0x157c62('0x20b2')]()[_0x157c62('0x2f')],'section':'Agents','fields':_0x157c62('0x174e'),'role':'agent','sort':_0x157c62('0x11bc'),'nolimit':!![]});}],'userProfile':['apiResolver',_0x47b702('0xba1'),function(_0x15dd95,_0x1a7816){const _0x52816e=_0x47b702;return _0x1a7816[_0x52816e('0xca1')](_0x52816e('0x20c2'))?null:_0x15dd95[_0x52816e('0xed7')](_0x52816e('0x1464'),{'fields':_0x52816e('0x16f'),'id':_0x1a7816['getCurrentUser']()[_0x52816e('0x2f')]});}],'userProfileSection':['apiResolver',_0x47b702('0xba1'),function(_0x422de3,_0x2e1c35){const _0x1ca1e3=_0x47b702;return _0x2e1c35[_0x1ca1e3('0xca1')](_0x1ca1e3('0x20c2'))?null:_0x422de3[_0x1ca1e3('0xed7')](_0x1ca1e3('0x360'),{'fields':_0x1ca1e3('0x1f47'),'userProfileId':_0x2e1c35[_0x1ca1e3('0x20b2')]()[_0x1ca1e3('0x2f')],'sectionId':0xca});}],'rpcAgents':[_0x47b702('0x4b1'),function(_0x3189b3){const _0x4e2252=_0x47b702;return _0x3189b3['resolve'](_0x4e2252('0x36a'));}]},'authenticate':!![],'permissionId':0x83e})[_0x47b702('0x2598')](_0x47b702('0x24c0'),{'url':_0x47b702('0x14a4'),'controller':_0x47b702('0x1e37'),'templateUrl':_0xab101f,'resolve':{'queues':['apiResolver',_0x47b702('0xba1'),function(_0xe14e03,_0x45215f){const _0x4a2907=_0x47b702;return _0x45215f[_0x4a2907('0xca1')](_0x4a2907('0x20c2'))?_0xe14e03[_0x4a2907('0xed7')](_0x4a2907('0x138d'),{'type':'inbound','sort':_0x4a2907('0xc36'),'limit':0xa,'offset':0x0}):_0xe14e03[_0x4a2907('0xed7')](_0x4a2907('0x191b'),{'id':_0x45215f[_0x4a2907('0x20b2')]()['userProfileId'],'section':_0x4a2907('0x20e4'),'channel':'whatsapp','type':'inbound','sort':_0x4a2907('0xc36'),'limit':0xa,'page':0x1});}],'userProfile':[_0x47b702('0x4b1'),_0x47b702('0xba1'),function(_0x27c175,_0x5610af){const _0x27f6b6=_0x47b702;return _0x5610af['hasRole'](_0x27f6b6('0x20c2'))?null:_0x27c175['resolve'](_0x27f6b6('0x1464'),{'fields':_0x27f6b6('0x16f'),'id':_0x5610af[_0x27f6b6('0x20b2')]()[_0x27f6b6('0x2f')]});}],'userProfileSection':['apiResolver',_0x47b702('0xba1'),function(_0x2f3c79,_0xb6a616){const _0x393135=_0x47b702;return _0xb6a616[_0x393135('0xca1')]('admin')?null:_0x2f3c79[_0x393135('0xed7')](_0x393135('0x360'),{'fields':_0x393135('0x1f47'),'userProfileId':_0xb6a616[_0x393135('0x20b2')]()['userProfileId'],'sectionId':0x835});}],'rpcQueues':[_0x47b702('0x4b1'),function(_0x2d46d1){const _0xe873b2=_0x47b702;return _0x2d46d1[_0xe873b2('0xed7')]('rpc@getWhatsappQueues');}]},'authenticate':!![],'permissionId':0x83e});}angular[_0x189033('0x1e26')](_0x189033('0x30c'),[])['config'](_0x26ffc5)[_0x189033('0x1da3')]('AgentsWhatsappRealtimeController',_0x13a224)[_0x189033('0x1da3')](_0x189033('0x1306'),_0x29d5ab)[_0x189033('0x1f97')](_0x189033('0xa72'),_0x4670c6)[_0x189033('0x1da3')]('WhatsappRealtimeController',_0x2ca7d0);const _0x4ad2f9=_0x180212['p']+_0x189033('0x9e2'),_0x22966b=_0x180212['p']+_0x189033('0x2124'),_0x28e1a8=_0x180212['p']+_0x189033('0x1454'),_0x210243=_0x180212['p']+_0x189033('0x24e2');_0x1b6119[_0x189033('0x14be')]=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q',_0x189033('0x1d08'),_0x189033('0x1d70'),_0x189033('0x263c'),_0x189033('0x1990'),_0x189033('0x56b'),'Auth',_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x1b6119(_0xc1aaf6,_0x286df6,_0x3e9f35,_0xe3f56,_0x171558,_0x42c2c5,_0x235518,_0x6e4b16,_0x4542fd,_0x52023a,_0x3f0088,_0x454b3a,_0x3859c0,_0x4d3853){const _0x5ed92e=_0x189033,_0x3dc11e=this;_0x3dc11e[_0x5ed92e('0x11ed')]=_0x3f0088[_0x5ed92e('0x20b2')](),_0x3dc11e[_0x5ed92e('0x17f')]=[],_0x3dc11e[_0x5ed92e('0x260a')]=_0x3859c0,_0x3dc11e[_0x5ed92e('0xace')]=_0x454b3a,_0x3dc11e[_0x5ed92e('0x1134')]=_0x4d3853,_0x3dc11e[_0x5ed92e('0x258d')]={},_0x3dc11e['passwordPattern']=_0x3dc11e[_0x5ed92e('0x260a')]&&_0x3dc11e[_0x5ed92e('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x3dc11e[_0x5ed92e('0xf28')]=_0x5ed92e('0x201'),_0x3dc11e[_0x5ed92e('0x1990')]=angular[_0x5ed92e('0x1a86')](_0x4542fd),_0x3dc11e[_0x5ed92e('0x263c')]=_0x6e4b16,_0x3dc11e['newWhatsappAccount']=![];!_0x3dc11e[_0x5ed92e('0x1990')]&&(_0x3dc11e[_0x5ed92e('0x1990')]={'remote':_0x3e9f35[_0x5ed92e('0x173e')]()+'://'+_0x3e9f35[_0x5ed92e('0x19ac')]()+(_0x3e9f35[_0x5ed92e('0x4a2')]()?':'+_0x3e9f35[_0x5ed92e('0x4a2')]():''),'type':_0x5ed92e('0x1a9d'),'notificationSound':!![],'queueTransferTimeout':0x12c,'waitForTheAssignedAgent':0xa,'agentTransferTimeout':0x12c},_0x3dc11e[_0x5ed92e('0xf28')]=_0x5ed92e('0x3e'),_0x3dc11e[_0x5ed92e('0x15b7')]=!![]);_0x286df6[_0x5ed92e('0x7f2')]['id']&&(_0x3dc11e[_0x5ed92e('0x1990')][_0x5ed92e('0x1c35')]=_0x286df6[_0x5ed92e('0x7f2')]['id']);_0x3dc11e[_0x5ed92e('0x1321')]=_0x2c2829,_0x3dc11e[_0x5ed92e('0x21b1')]=_0x20eeb5,_0x3dc11e[_0x5ed92e('0x1008')]=_0x3b0381,_0x3dc11e[_0x5ed92e('0x16b3')]=_0xf18a5a,_0x3dc11e[_0x5ed92e('0xf82')]=_0xb82d9d,_0x3f0088[_0x5ed92e('0xca1')](_0x5ed92e('0x20c2'))?_0x52023a[_0x5ed92e('0x259b')]['get']({'fields':_0x5ed92e('0xa10'),'sort':_0x5ed92e('0x60a')})[_0x5ed92e('0xe53')][_0x5ed92e('0x683')](function(_0xa8bd72){const _0x2c282d=_0x5ed92e;_0x3dc11e['lists']=_0xa8bd72[_0x2c282d('0xf5d')]||[];})[_0x5ed92e('0x130a')](function(_0x28fd53){const _0xeba82e=_0x5ed92e;_0x235518[_0xeba82e('0x52a')]({'title':_0x28fd53[_0xeba82e('0x13ee')]?'API:'+_0x28fd53[_0xeba82e('0x13ee')]+_0xeba82e('0xbf6')+_0x28fd53[_0xeba82e('0x24a9')]:_0xeba82e('0x251b'),'msg':_0x28fd53['data']?JSON[_0xeba82e('0x258a')](_0x28fd53[_0xeba82e('0x5a5')]):_0x28fd53['toString']()});}):_0x52023a['cmList'][_0x5ed92e('0x1e6e')]({'fields':_0x5ed92e('0xa10'),'sort':_0x5ed92e('0x60a')})[_0x5ed92e('0xe53')][_0x5ed92e('0x683')](function(_0x1d3281){const _0x5aa984=_0x5ed92e;_0x3dc11e[_0x5aa984('0xe01')]=_0x1d3281['rows']||[];})['then'](function(){const _0x2bc2de=_0x5ed92e;return _0x52023a[_0x2bc2de('0x22df')][_0x2bc2de('0x1e6e')]({'userProfileId':_0x3dc11e[_0x2bc2de('0x11ed')][_0x2bc2de('0x2f')],'sectionId':0x12d})[_0x2bc2de('0xe53')];})['then'](function(_0x34ed36){const _0x262fbf=_0x5ed92e,_0x30750e=_0x34ed36&&_0x34ed36[_0x262fbf('0xf5d')]?_0x34ed36[_0x262fbf('0xf5d')][0x0]:null;if(!_0x30750e){const _0x3aa264=[];let _0x2306c4=null;_0x3dc11e[_0x262fbf('0x1990')]&&(_0x2306c4=_0x2e3ca0()[_0x262fbf('0x1c07')](_0x3dc11e['lists'],{'id':Number(_0x3dc11e[_0x262fbf('0x1990')]['ListId'])}));for(let _0x3d47b1=0x0;_0x3d47b1<_0x3dc11e['lists'][_0x262fbf('0x1564')];_0x3d47b1++){_0x2306c4&&_0x3dc11e['lists'][_0x3d47b1]['id']===_0x2306c4['id']&&(_0x3dc11e['lists'][_0x3d47b1][_0x262fbf('0x319')]=![],_0x3aa264[_0x262fbf('0x1fd0')](_0x3dc11e[_0x262fbf('0xe01')][_0x3d47b1]));}_0x3dc11e['lists']=_0x3aa264;}else{if(!_0x30750e['autoAssociation'])return _0x52023a[_0x262fbf('0xcf7')]['get']({'sectionId':_0x30750e['id']})['$promise']['then'](function(_0x5de2cf){const _0xc1dbe=_0x262fbf,_0x2fe2cc=_0x2e3ca0()[_0xc1dbe('0x386')](_0x5de2cf['rows'],function(_0x1d390d){const _0x4f7b1a=_0xc1dbe;return _0x2e3ca0()[_0x4f7b1a('0x1c07')](_0x3dc11e[_0x4f7b1a('0xe01')],{'id':_0x1d390d[_0x4f7b1a('0x832')]});});let _0x30b6d6=null;_0x3dc11e[_0xc1dbe('0x1990')]&&(_0x30b6d6=_0x2e3ca0()[_0xc1dbe('0x1c07')](_0x3dc11e[_0xc1dbe('0xe01')],{'id':Number(_0x3dc11e[_0xc1dbe('0x1990')]['ListId'])}));if(_0x30b6d6&&!_0x2e3ca0()[_0xc1dbe('0x7a2')](_0x2fe2cc,['id',_0x30b6d6['id']])){const _0x2f9aed=_0x2e3ca0()[_0xc1dbe('0x1c07')](_0x3dc11e[_0xc1dbe('0xe01')],{'id':_0x30b6d6['id']});_0x2f9aed['canSelect']=![],_0x2fe2cc[_0xc1dbe('0x1fd0')](_0x2f9aed);}_0x3dc11e[_0xc1dbe('0xe01')]=_0x2fe2cc;});}})[_0x5ed92e('0x130a')](function(_0x59952a){const _0x5a7860=_0x5ed92e;_0x235518[_0x5a7860('0x52a')]({'title':_0x59952a[_0x5a7860('0x13ee')]?_0x5a7860('0x2168')+_0x59952a[_0x5a7860('0x13ee')]+'\x20-\x20'+_0x59952a[_0x5a7860('0x24a9')]:_0x5a7860('0x11e3'),'msg':_0x59952a[_0x5a7860('0x5a5')]?JSON[_0x5a7860('0x258a')](_0x59952a[_0x5a7860('0x5a5')]):_0x59952a[_0x5a7860('0x1ff0')]()});}),_0x3f0088[_0x5ed92e('0xca1')](_0x5ed92e('0x20c2'))?_0x52023a[_0x5ed92e('0xa4')][_0x5ed92e('0x1e6e')]({'fields':'name,id','sort':_0x5ed92e('0x60a'),'nolimit':'true'})['$promise'][_0x5ed92e('0x683')](function(_0x53489a){const _0x416236=_0x5ed92e;_0x3dc11e[_0x416236('0x22ab')]=_0x53489a[_0x416236('0xf5d')]||[];})[_0x5ed92e('0x130a')](function(_0x522f98){const _0x1951a2=_0x5ed92e;_0x235518[_0x1951a2('0x52a')]({'title':_0x522f98[_0x1951a2('0x13ee')]?_0x1951a2('0x2168')+_0x522f98[_0x1951a2('0x13ee')]+_0x1951a2('0xbf6')+_0x522f98[_0x1951a2('0x24a9')]:_0x1951a2('0x4ba'),'msg':_0x522f98['data']?JSON['stringify'](_0x522f98[_0x1951a2('0x5a5')]):_0x522f98['toString']()});}):_0x52023a[_0x5ed92e('0xa4')][_0x5ed92e('0x1e6e')]({'fields':_0x5ed92e('0x1688'),'sort':_0x5ed92e('0x60a'),'nolimit':_0x5ed92e('0x26ac')})[_0x5ed92e('0xe53')][_0x5ed92e('0x683')](function(_0x563e20){const _0x219441=_0x5ed92e;_0x3dc11e[_0x219441('0x22ab')]=_0x563e20[_0x219441('0xf5d')]||[];})[_0x5ed92e('0x683')](function(){const _0xd8d376=_0x5ed92e;return _0x52023a[_0xd8d376('0x22df')][_0xd8d376('0x1e6e')]({'userProfileId':_0x3dc11e['currentUser'][_0xd8d376('0x2f')],'sectionId':0x3ed})[_0xd8d376('0xe53')];})[_0x5ed92e('0x683')](function(_0x231305){const _0x2599df=_0x5ed92e,_0xad90e7=_0x231305&&_0x231305['rows']?_0x231305['rows'][0x0]:null;if(!_0xad90e7)_0x3dc11e[_0x2599df('0x22ab')]=[];else{if(!_0xad90e7['autoAssociation'])return _0x52023a[_0x2599df('0xcf7')][_0x2599df('0x1e6e')]({'sectionId':_0xad90e7['id']})[_0x2599df('0xe53')]['then'](function(_0x5dda33){const _0x487b12=_0x2599df,_0x4b37cb=_0x2e3ca0()['map'](_0x5dda33[_0x487b12('0xf5d')],function(_0x22c0e9){const _0x3e7d12=_0x487b12;return _0x2e3ca0()[_0x3e7d12('0x1c07')](_0x3dc11e[_0x3e7d12('0x22ab')],{'id':_0x22c0e9[_0x3e7d12('0x832')]});});_0x3dc11e[_0x487b12('0x22ab')]['forEach'](function(_0x1789aa){const _0x41214e=_0x487b12;!_0x2e3ca0()[_0x41214e('0x7a2')](_0x4b37cb,['id',_0x1789aa['id']])&&(_0x1789aa[_0x41214e('0x319')]=![]),_0x4b37cb[_0x41214e('0x1fd0')](_0x1789aa);}),_0x3dc11e[_0x487b12('0x22ab')]=_0x4b37cb;});}})[_0x5ed92e('0x130a')](function(_0x397edd){const _0x267cbb=_0x5ed92e;_0x235518[_0x267cbb('0x52a')]({'title':_0x397edd['status']?_0x267cbb('0x2168')+_0x397edd[_0x267cbb('0x13ee')]+'\x20-\x20'+_0x397edd['statusText']:_0x267cbb('0xc45'),'msg':_0x397edd[_0x267cbb('0x5a5')]?JSON['stringify'](_0x397edd[_0x267cbb('0x5a5')]):_0x397edd[_0x267cbb('0x1ff0')]()});});function _0x2c2829(){const _0x38523c=_0x5ed92e;_0x3dc11e[_0x38523c('0x17f')]=[],_0x52023a[_0x38523c('0x1990')][_0x38523c('0xb0a')](_0x3dc11e['whatsappAccount'])[_0x38523c('0xe53')][_0x38523c('0x683')](function(_0x4f628c){const _0x330229=_0x38523c;_0x3dc11e['whatsappAccounts']['unshift'](_0x4f628c['toJSON']()),_0x235518[_0x330229('0x53')]({'title':'WhatsappAccount\x20properly\x20created','msg':_0x3dc11e[_0x330229('0x1990')][_0x330229('0x60a')]?_0x3dc11e['whatsappAccount'][_0x330229('0x60a')]+_0x330229('0x14b5'):''}),_0xb82d9d(_0x4f628c);})[_0x38523c('0x130a')](function(_0x2587c6){const _0x4d985a=_0x38523c;if(_0x2587c6['data']&&_0x2587c6[_0x4d985a('0x5a5')]['errors']&&_0x2587c6['data']['errors']['length']){_0x3dc11e[_0x4d985a('0x17f')]=_0x2587c6[_0x4d985a('0x5a5')]['errors']||[{'message':_0x2587c6[_0x4d985a('0x1ff0')](),'type':_0x4d985a('0x1fa2')}];for(let _0x349b03=0x0;_0x349b03<_0x2587c6[_0x4d985a('0x5a5')][_0x4d985a('0x17f')]['length'];_0x349b03+=0x1){_0x235518[_0x4d985a('0x52a')]({'title':_0x2587c6[_0x4d985a('0x5a5')][_0x4d985a('0x17f')][_0x349b03][_0x4d985a('0xcf0')],'msg':_0x2587c6[_0x4d985a('0x5a5')][_0x4d985a('0x17f')][_0x349b03][_0x4d985a('0x8c2')]});}}else _0x235518[_0x4d985a('0x52a')]({'title':_0x2587c6[_0x4d985a('0x13ee')]?_0x4d985a('0x2168')+_0x2587c6[_0x4d985a('0x13ee')]+_0x4d985a('0xbf6')+_0x2587c6[_0x4d985a('0x24a9')]:_0x4d985a('0x1fa2'),'msg':_0x2587c6[_0x4d985a('0x5a5')]?JSON[_0x4d985a('0x258a')](_0x2587c6['data'][_0x4d985a('0x8c2')]):_0x2587c6['toString']()});});}function _0x20eeb5(){const _0x26c3e2=_0x5ed92e;_0x3dc11e[_0x26c3e2('0x17f')]=[],_0x52023a[_0x26c3e2('0x1990')][_0x26c3e2('0x2480')]({'id':_0x3dc11e[_0x26c3e2('0x1990')]['id']},_0x3dc11e[_0x26c3e2('0x1990')])[_0x26c3e2('0xe53')][_0x26c3e2('0x683')](function(_0x340d9d){const _0x1c3e31=_0x26c3e2,_0x51d292=_0x2e3ca0()['find'](_0x3dc11e[_0x1c3e31('0x263c')],{'id':_0x340d9d['id']});_0x51d292&&_0x2e3ca0()[_0x1c3e31('0xf22')](_0x51d292,_0x2e3ca0()[_0x1c3e31('0x24d0')](_0x340d9d[_0x1c3e31('0x24e1')](),_0x2e3ca0()[_0x1c3e31('0x55e')](_0x51d292))),_0x235518[_0x1c3e31('0x53')]({'title':_0x1c3e31('0x2109'),'msg':_0x3dc11e[_0x1c3e31('0x1990')][_0x1c3e31('0x60a')]?_0x3dc11e[_0x1c3e31('0x1990')][_0x1c3e31('0x60a')]+_0x1c3e31('0xf59'):''}),_0xb82d9d(_0x340d9d);})[_0x26c3e2('0x130a')](function(_0x391055){const _0x42725b=_0x26c3e2;if(_0x391055[_0x42725b('0x5a5')]&&_0x391055[_0x42725b('0x5a5')][_0x42725b('0x17f')]&&_0x391055[_0x42725b('0x5a5')][_0x42725b('0x17f')][_0x42725b('0x1564')]){_0x3dc11e['errors']=_0x391055[_0x42725b('0x5a5')][_0x42725b('0x17f')]||[{'message':_0x391055[_0x42725b('0x1ff0')](),'type':_0x42725b('0x513')}];for(let _0x25f30a=0x0;_0x25f30a<_0x391055[_0x42725b('0x5a5')][_0x42725b('0x17f')][_0x42725b('0x1564')];_0x25f30a++){_0x235518[_0x42725b('0x52a')]({'title':_0x391055[_0x42725b('0x5a5')]['errors'][_0x25f30a][_0x42725b('0xcf0')],'msg':_0x391055[_0x42725b('0x5a5')]['errors'][_0x25f30a][_0x42725b('0x8c2')]});}}else _0x235518['error']({'title':_0x391055[_0x42725b('0x13ee')]?_0x42725b('0x2168')+_0x391055['status']+_0x42725b('0xbf6')+_0x391055['statusText']:_0x42725b('0x513'),'msg':_0x391055[_0x42725b('0x5a5')]?JSON[_0x42725b('0x258a')](_0x391055[_0x42725b('0x5a5')][_0x42725b('0x8c2')]):_0x391055['toString']()});});}function _0x3b0381(_0x533246){const _0x47a68b=_0x5ed92e;_0x3dc11e['errors']=[];const _0x49a836=_0xe3f56[_0x47a68b('0x1c6f')]()[_0x47a68b('0xf28')](_0x47a68b('0x4d'))[_0x47a68b('0xa6a')](_0x47a68b('0x1e7b'))[_0x47a68b('0x1040')](_0x47a68b('0xfad'))['ok']('Delete')[_0x47a68b('0x19fb')](_0x47a68b('0x253a'))[_0x47a68b('0xe42')](_0x533246);_0xe3f56['show'](_0x49a836)[_0x47a68b('0x683')](function(){const _0x5775e3=_0x47a68b;_0x52023a['whatsappAccount'][_0x5775e3('0xd7e')]({'id':_0x3dc11e['whatsappAccount']['id']})[_0x5775e3('0xe53')][_0x5775e3('0x683')](function(){const _0x1e6cf5=_0x5775e3;_0x2e3ca0()[_0x1e6cf5('0x3ec')](_0x3dc11e[_0x1e6cf5('0x263c')],{'id':_0x3dc11e[_0x1e6cf5('0x1990')]['id']}),_0x235518[_0x1e6cf5('0x53')]({'title':_0x1e6cf5('0xc15'),'msg':(_0x3dc11e[_0x1e6cf5('0x1990')]['name']||_0x1e6cf5('0x1990'))+_0x1e6cf5('0x194d')}),_0xb82d9d(_0x3dc11e[_0x1e6cf5('0x1990')]);})[_0x5775e3('0x130a')](function(_0x7c7c91){const _0x4ca3ee=_0x5775e3;if(_0x7c7c91['data']&&_0x7c7c91[_0x4ca3ee('0x5a5')][_0x4ca3ee('0x17f')]&&_0x7c7c91[_0x4ca3ee('0x5a5')][_0x4ca3ee('0x17f')][_0x4ca3ee('0x1564')]){_0x3dc11e['errors']=_0x7c7c91[_0x4ca3ee('0x5a5')][_0x4ca3ee('0x17f')]||[{'message':_0x7c7c91[_0x4ca3ee('0x1ff0')](),'type':'api.whatsappAccount.delete'}];for(let _0x37067f=0x0;_0x37067f<_0x7c7c91['data'][_0x4ca3ee('0x17f')][_0x4ca3ee('0x1564')];_0x37067f++){_0x235518[_0x4ca3ee('0x52a')]({'title':_0x7c7c91[_0x4ca3ee('0x5a5')][_0x4ca3ee('0x17f')][_0x37067f][_0x4ca3ee('0xcf0')],'msg':_0x7c7c91[_0x4ca3ee('0x5a5')]['errors'][_0x37067f][_0x4ca3ee('0x8c2')]});}}else _0x235518[_0x4ca3ee('0x52a')]({'title':_0x7c7c91[_0x4ca3ee('0x13ee')]?_0x4ca3ee('0x2168')+_0x7c7c91[_0x4ca3ee('0x13ee')]+_0x4ca3ee('0xbf6')+_0x7c7c91[_0x4ca3ee('0x24a9')]:'api.whatsappAccount.delete','msg':_0x7c7c91[_0x4ca3ee('0x5a5')]?JSON[_0x4ca3ee('0x258a')](_0x7c7c91[_0x4ca3ee('0x5a5')]['message']):_0x7c7c91[_0x4ca3ee('0x8c2')]||_0x7c7c91[_0x4ca3ee('0x1ff0')]()});});},function(){});}function _0xf18a5a(_0x5afd16){return _0x5afd16===null?undefined:new Date(_0x5afd16);}function _0xb82d9d(_0x298a9c){const _0x2b0e44=_0x5ed92e;_0xe3f56[_0x2b0e44('0x1715')](_0x298a9c);}}const _0x46ccab=_0x1b6119,_0x7e381c=_0x180212['p']+'src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/agent/dialog.html/dialog.html',_0x379719=_0x180212['p']+_0x189033('0x242d'),_0x460380=_0x180212['p']+_0x189033('0x1b52'),_0x3389a8=_0x180212['p']+_0x189033('0x21d4'),_0x35d6e6=_0x180212['p']+_0x189033('0x890'),_0x4550e7=_0x180212['p']+_0x189033('0x14e4'),_0x9c14df=_0x180212['p']+_0x189033('0x13'),_0x56f967=_0x180212['p']+'src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/interval/dialog.html/dialog.html',_0x28915e=_0x180212['p']+_0x189033('0x527'),_0x448195=_0x180212['p']+'src/js/modules/main/apps/whatsapp/views/whatsappAccounts/edit/apps/queue/dialog.html/dialog.html',_0x3b56ac=_0x180212['p']+_0x189033('0x12e6'),_0x50bb0a=_0x180212['p']+_0x189033('0x139b');_0x2bcf34[_0x189033('0x14be')]=[_0x189033('0x56b'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d70'),_0x189033('0xba1')];const _0x56cb25={'agent':_0x7e381c,'amazonlex':_0x379719,'autoreply':_0x460380,'close':_0x3389a8,'dialogflow':_0x35d6e6,'gotoif':_0x4550e7,'gotop':_0x9c14df,'interval':_0x56f967,'noop':_0x28915e,'queue':_0x448195,'system':_0x3b56ac,'tag':_0x50bb0a};function _0x2bcf34(_0x34cb3e,_0x15248c,_0x3e4aef,_0x13085c,_0x5341e7){const _0x2be533=_0x189033,_0x5ae04f=this;_0x5ae04f[_0x2be533('0x11ed')]=_0x5341e7[_0x2be533('0x20b2')](),_0x5ae04f[_0x2be533('0x1990')]={},_0x5ae04f[_0x2be533('0x787')]={'count':0x0,'rows':[]},_0x5ae04f[_0x2be533('0x276d')]=[],_0x5ae04f[_0x2be533('0x1134')],_0x5ae04f[_0x2be533('0x23a2')]={'sort':_0x2be533('0xe1e')},_0x5ae04f[_0x2be533('0x346')]=_0x2e3ca0()['reject'](_0x2e3ca0()[_0x2be533('0x742')]([{'app':_0x2be533('0x22ee'),'appType':'interval','types':['always',_0x2be533('0xbf0'),_0x2be533('0x2335')],'fields':[],'isApp':![]},{'app':'noop','appType':_0x2be533('0x1126'),'type':_0x2be533('0x1126'),'icon':_0x2be533('0x7ee'),'interval':_0x2be533('0x1b54'),'required':!![],'isApp':!![],'fields':[{'title':_0x2be533('0x75d'),'name':'value','type':_0x2be533('0x1bcd'),'param':0x0}]},{'app':'system','appType':_0x2be533('0x24f2'),'type':'system','icon':_0x2be533('0x7ee'),'interval':_0x2be533('0x1b54'),'required':!![],'isApp':!![],'extraApi':[{'name':_0x2be533('0x220b'),'field':{'name':_0x2be533('0x26e0'),'key':_0x2be533('0x60a')},'route':_0x2be533('0x26e0'),'filters':{'fields':_0x2be533('0xa10'),'sort':'name','nolimit':!![]},'permissions':{'section':0x3f4}}],'fields':[{'title':_0x2be533('0x256'),'name':_0x2be533('0x6db'),'type':_0x2be533('0x1bcd'),'required':!![],'param':0x0},{'title':_0x2be533('0xde7'),'name':_0x2be533('0x26e0'),'type':_0x2be533('0x1aae'),'values':_0x2be533('0x220b'),'value':_0x2be533('0x2277'),'option':_0x2be533('0x2277'),'defaultValues':[{'value':'\x27\x27','option':_0x2be533('0x2749')}],'defaultValue':'\x27\x27','param':0x1}]},{'app':_0x2be533('0x1da0'),'appType':_0x2be533('0x1da0'),'type':_0x2be533('0x27fe'),'icon':_0x2be533('0x7ee'),'interval':_0x2be533('0x1b54'),'isApp':!![],'fields':[{'title':_0x2be533('0x19b4'),'name':_0x2be533('0xe1e'),'type':_0x2be533('0x121f'),'required':!![],'min':0x0,'param':0x0}]},{'app':'gotoif','appType':'gotoif','type':_0x2be533('0xc33'),'icon':_0x2be533('0x7ee'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x2be533('0xe0d'),'name':'condition','type':_0x2be533('0x1bcd'),'required':!![],'param':0x0},{'title':_0x2be533('0x27e5'),'name':'truepriority','type':_0x2be533('0x121f'),'min':0x1,'required':!![],'param':0x1},{'title':'falsepriority','name':_0x2be533('0x1813'),'type':_0x2be533('0x121f'),'min':0x1,'required':!![],'param':0x2}]},{'app':_0x2be533('0x660'),'appType':'queue','foreignKey':_0x2be533('0x1634'),'type':_0x2be533('0x660'),'icon':_0x2be533('0x7ee'),'interval':_0x2be533('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x2be533('0x2da'),'field':{'name':_0x2be533('0x660'),'key':'name'},'route':'whatsappQueue','filters':{'fields':'id,name,type','sort':_0x2be533('0x60a'),'nolimit':!![]},'permissions':{'section':0x836}}],'fields':[{'title':'Queue','name':_0x2be533('0x660'),'type':_0x2be533('0x1aae'),'values':_0x2be533('0x2da'),'value':'queue.name','option':_0x2be533('0x2543'),'defaultValue':0x12c,'required':!![],'param':0x0},{'title':_0x2be533('0xa09'),'name':_0x2be533('0x1668'),'type':_0x2be533('0x121f'),'max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x12c,'param':0x1}]},{'app':_0x2be533('0x2327'),'appType':_0x2be533('0x2327'),'type':_0x2be533('0x2327'),'foreignKey':'UserId','icon':_0x2be533('0x7ee'),'interval':_0x2be533('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x2be533('0x756'),'field':{'name':'agent','key':_0x2be533('0x60a')},'route':_0x2be533('0xc96'),'filters':{'fields':'id,name','sort':_0x2be533('0x60a'),'nolimit':!![],'role':_0x2be533('0x2327')},'permissions':{'section':0xca}}],'fields':[{'title':_0x2be533('0x62c'),'name':'agent','type':_0x2be533('0x1aae'),'values':_0x2be533('0x756'),'value':_0x2be533('0x1ed0'),'option':_0x2be533('0x1ed0'),'required':!![],'param':0x0},{'title':_0x2be533('0xa09'),'name':_0x2be533('0x1668'),'type':'number','max':0x20c49b,'min':0x0,'required':!![],'defaultValue':0x1e,'param':0x1}]},{'app':_0x2be533('0x2408'),'appType':_0x2be533('0x2408'),'type':_0x2be533('0x2408'),'icon':'icon-apps','interval':_0x2be533('0x1b54'),'isApp':!![],'fields':[{'title':_0x2be533('0x35'),'name':'times','type':_0x2be533('0xb31'),'defaultValue':'1','values':[{'option':'One\x20Time','value':'1'},{'option':_0x2be533('0x1023'),'value':'0'}],'required':!![],'param':0x0},{'title':_0x2be533('0x1d8c'),'name':'text','type':_0x2be533('0x24be'),'required':!![],'param':0x1}]},{'app':_0x2be533('0x12b0'),'appType':'close','type':'close','icon':_0x2be533('0x7ee'),'interval':'*,*,*,*','isApp':!![],'fields':[{'title':_0x2be533('0x11d4'),'name':'disposition','type':'text','required':!![],'param':0x0}]},{'app':_0x2be533('0x270'),'appType':_0x2be533('0x270'),'type':_0x2be533('0x270'),'foreignKey':_0x2be533('0xb6d'),'icon':'icon-apps','interval':_0x2be533('0x1b54'),'isApp':!![],'extraApi':[{'name':_0x2be533('0x1ce6'),'field':{'name':_0x2be533('0x270'),'key':_0x2be533('0x60a')},'route':_0x2be533('0x270'),'filters':{'fields':'id,name','sort':'name','nolimit':!![]},'permissions':{'section':0x3f0}}],'fields':[{'title':_0x2be533('0x1e'),'name':_0x2be533('0x270'),'type':_0x2be533('0x1aae'),'values':_0x2be533('0x1ce6'),'value':_0x2be533('0x1402'),'option':_0x2be533('0x1402'),'required':!![],'param':0x0}]},{'app':_0x2be533('0x205c'),'appType':_0x2be533('0x205c'),'type':_0x2be533('0x205c'),'icon':'icon-apps','interval':_0x2be533('0x1b54'),'isApp':!![],'fields':[{'title':_0x2be533('0x429'),'name':'key','type':_0x2be533('0x1bcd'),'required':!![],'param':0x0},{'title':'language','name':_0x2be533('0x1a1c'),'type':_0x2be533('0xb31'),'defaultValue':_0x2be533('0x1adc'),'values':[{'option':_0x2be533('0x17d9'),'value':_0x2be533('0x1e18')},{'option':'English','value':_0x2be533('0x1adc')},{'option':_0x2be533('0x118e'),'value':_0x2be533('0x1e33')},{'option':_0x2be533('0x2217'),'value':_0x2be533('0x1955')},{'option':_0x2be533('0xbe9'),'value':'\x27es\x27'},{'option':_0x2be533('0x51a'),'value':_0x2be533('0x1869')},{'option':_0x2be533('0x9ec'),'value':_0x2be533('0x663')},{'option':_0x2be533('0x1abb'),'value':_0x2be533('0x1505')},{'option':'Korean\x20(South\x20Korea)','value':_0x2be533('0x9d3')},{'option':_0x2be533('0xe03'),'value':_0x2be533('0x730')},{'option':_0x2be533('0x1e53'),'value':_0x2be533('0x23ca')},{'option':'Portuguese\x20(European)','value':_0x2be533('0x432')},{'option':_0x2be533('0x521'),'value':_0x2be533('0xc58')},{'option':_0x2be533('0x103e'),'value':_0x2be533('0xb56')},{'option':_0x2be533('0x1ff5'),'value':_0x2be533('0xf1d')},{'option':'Thai','value':_0x2be533('0x15a8')},{'option':'Ukrainian','value':_0x2be533('0x2e0')},{'option':'Chinese\x20(Simplified)','value':_0x2be533('0x2562')},{'option':'Chinese\x20(Hong\x20Kong)','value':_0x2be533('0x1802')},{'option':_0x2be533('0x700'),'value':_0x2be533('0x1dc')}],'required':!![],'param':0x1},{'title':_0x2be533('0x6d9'),'name':_0x2be533('0x6d9'),'type':_0x2be533('0x24be'),'maxlength':0xff,'required':![],'param':0x2,'help':!![]}]},{'app':_0x2be533('0x1d62'),'appType':_0x2be533('0xd24'),'type':_0x2be533('0xd24'),'icon':'icon-apps','interval':_0x2be533('0x1b54'),'isApp':!![],'fields':[{'title':_0x2be533('0x1e7d'),'name':_0x2be533('0x2119'),'type':_0x2be533('0x1bcd'),'required':!![],'param':0x0},{'title':'ClientEmail','name':_0x2be533('0x38'),'type':'text','required':!![],'param':0x1},{'title':_0x2be533('0x216c'),'name':_0x2be533('0x406'),'type':_0x2be533('0x24be'),'required':!![],'param':0x2},{'title':_0x2be533('0x1a1c'),'name':'language','type':_0x2be533('0xb31'),'defaultValue':_0x2be533('0x1adc'),'values':[{'value':_0x2be533('0x1802'),'option':_0x2be533('0x1de6')},{'value':_0x2be533('0x2562'),'option':_0x2be533('0x277f')},{'value':_0x2be533('0x1dc'),'option':'Chinese\x20(Traditional)'},{'value':_0x2be533('0x1e18'),'option':_0x2be533('0x17d9')},{'value':_0x2be533('0x730'),'option':_0x2be533('0xe03')},{'value':_0x2be533('0x1adc'),'option':_0x2be533('0xf48')},{'value':_0x2be533('0x6dd'),'option':_0x2be533('0xbc1')},{'value':_0x2be533('0x196e'),'option':_0x2be533('0x6fa')},{'value':_0x2be533('0x23bd'),'option':_0x2be533('0x1e8')},{'value':_0x2be533('0x2303'),'option':_0x2be533('0xa57')},{'value':'\x27en-US\x27','option':_0x2be533('0x40b')},{'value':_0x2be533('0x1869'),'option':_0x2be533('0x51a')},{'value':_0x2be533('0x8df'),'option':_0x2be533('0x842')},{'value':_0x2be533('0x2371'),'option':_0x2be533('0xcad')},{'value':_0x2be533('0x1e33'),'option':_0x2be533('0x118e')},{'value':'\x27hi\x27','option':_0x2be533('0x81c')},{'value':'\x27id\x27','option':_0x2be533('0x9ec')},{'value':_0x2be533('0x1955'),'option':_0x2be533('0x2217')},{'value':_0x2be533('0x1505'),'option':_0x2be533('0x1abb')},{'value':'\x27ko\x27','option':_0x2be533('0x233a')},{'value':_0x2be533('0x23ca'),'option':'Norwegian'},{'value':_0x2be533('0x24cb'),'option':_0x2be533('0x10a7')},{'value':'\x27pt-BR\x27','option':_0x2be533('0x15b3')},{'value':_0x2be533('0x64c'),'option':_0x2be533('0x1876')},{'value':_0x2be533('0xb56'),'option':_0x2be533('0x103e')},{'value':_0x2be533('0xd34'),'option':'Spanish'},{'value':_0x2be533('0x2288'),'option':'Spanish\x20(Latin\x20America)'},{'value':'\x27es-ES\x27','option':_0x2be533('0x208e')},{'value':_0x2be533('0x2175'),'option':'Swedish'},{'value':'\x27th\x27','option':_0x2be533('0xbc')},{'value':_0x2be533('0x267f'),'option':_0x2be533('0x17b0')},{'value':'\x27uk\x27','option':_0x2be533('0x965')}],'required':!![],'param':0x3},{'title':_0x2be533('0x6d9'),'name':_0x2be533('0x6d9'),'type':_0x2be533('0x24be'),'maxlength':0xff,'param':0x4,'help':!![]}]},{'app':_0x2be533('0x1db1'),'appType':'amazonlex','type':_0x2be533('0x1db1'),'icon':_0x2be533('0x7ee'),'interval':_0x2be533('0x1b54'),'isApp':!![],'fields':[{'title':_0x2be533('0x7ae'),'name':_0x2be533('0x7ae'),'type':_0x2be533('0x1bcd'),'required':!![],'param':0x0},{'title':_0x2be533('0x204a'),'name':'secretaccesskey','type':'text','required':!![],'param':0x1},{'title':_0x2be533('0x5ba'),'name':_0x2be533('0x5ba'),'type':'select','defaultValue':_0x2be533('0x1924'),'values':[{'option':_0x2be533('0x260e'),'value':_0x2be533('0x1924')},{'option':_0x2be533('0xc2b'),'value':_0x2be533('0x1488')},{'option':_0x2be533('0x1e10'),'value':_0x2be533('0x17db')},{'option':_0x2be533('0x15b6'),'value':_0x2be533('0xc6')}],'required':!![],'param':0x2},{'title':'botname','name':_0x2be533('0x11a9'),'type':_0x2be533('0x1bcd'),'required':!![],'param':0x3},{'title':_0x2be533('0x6d9'),'name':'welcomemessage','type':_0x2be533('0x24be'),'maxlength':0xff,'required':![],'param':0x4,'help':!![]}]}],[_0x2be533('0x1d75')]),{'isApp':![]}),_0x5ae04f['list']={'group':{'name':_0x2be533('0x11bf'),'pull':'clone'},'animation':0x64,'sort':![]},_0x5ae04f[_0x2be533('0x2146')]={'group':{'name':'opt2','put':_0x2be533('0x11bf')},'animation':0x64,'onAdd':function(_0x3be231){const _0x5915e3=_0x2be533;_0x3254b2(_0x3be231,_0x3be231[_0x5915e3('0x1ce1')]);},'onSort':function(){_0x5b2bb8();}},_0x5ae04f[_0x2be533('0x12f3')]=_0x2758b1,_0x5ae04f[_0x2be533('0x26eb')]=_0x4a309c,_0x5ae04f[_0x2be533('0x408')]=_0x4c934b,_0x5ae04f[_0x2be533('0x906')]=_0x3254b2,_0x5ae04f[_0x2be533('0x24f7')]=_0x13fcba,_0x5ae04f[_0x2be533('0xa35')]=_0x3d82c9,_0x5ae04f[_0x2be533('0xa1a')]=_0x4533f4,_0x5ae04f['rewriteRouting']=_0x5b2bb8,_0x5ae04f[_0x2be533('0x14a')]=_0x53a351;function _0x2758b1(_0x1cc9c1,_0x2d5338){const _0x1bbaf9=_0x2be533;_0x5ae04f['whatsappAccount']=_0x1cc9c1,_0x5ae04f[_0x1bbaf9('0x1134')]=typeof _0x2d5338!==_0x1bbaf9('0x1867')?_0x2d5338:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x5ae04f[_0x1bbaf9('0x2146')]['disabled']=!_0x5ae04f[_0x1bbaf9('0x1134')][_0x1bbaf9('0x1978')]?!![]:![],_0x5ae04f['query']['id']=_0x1cc9c1['id'],_0x5ae04f[_0x1bbaf9('0x23a2')][_0x1bbaf9('0x12a8')]=!![],_0x5ae04f[_0x1bbaf9('0x23a2')][_0x1bbaf9('0x2088')]=!![],_0x5ae04f[_0x1bbaf9('0x408')](),_0x5ae04f['getIntervals']();}function _0x4a309c(_0x161084,_0x5843ea,_0x2a6662){const _0x3ccc8c=_0x2be533,_0x3ed9be=_0x15248c[_0x3ccc8c('0x1c6f')]()[_0x3ccc8c('0xf28')](_0x3ccc8c('0x421'))['htmlContent'](_0x3ccc8c('0xed5')+_0x161084[_0x3ccc8c('0x1d75')]+''+_0x3ccc8c('0x1ee7'))[_0x3ccc8c('0x1040')]('delete\x20application')[_0x3ccc8c('0xe42')](_0x2a6662)['ok']('OK')[_0x3ccc8c('0x19fb')](_0x3ccc8c('0x16b8'));_0x15248c[_0x3ccc8c('0x1d4')](_0x3ed9be)[_0x3ccc8c('0x683')](function(){const _0x5984f9=_0x3ccc8c;_0x5ae04f[_0x5984f9('0x787')][_0x5984f9('0xf5d')][_0x5984f9('0x2040')](_0x5843ea,0x1),_0x5b2bb8();},function(){const _0x3816d2=_0x3ccc8c;console[_0x3816d2('0x1b2b')](_0x3816d2('0x16b8'));});}function _0x3254b2(_0x28db05,_0x21fb3a){const _0x454b78=_0x2be533;if(_0x5ae04f[_0x454b78('0x787')][_0x454b78('0xf5d')][_0x454b78('0x1564')]){const _0x755d11=_0x5ae04f[_0x454b78('0x787')][_0x454b78('0xf5d')][_0x21fb3a]?_0x5ae04f[_0x454b78('0x787')][_0x454b78('0xf5d')][_0x21fb3a]:_0x5ae04f[_0x454b78('0x787')][_0x454b78('0xf5d')][0x0],_0x4bd5a1=(_0x755d11[_0x454b78('0x11f3')]||_0x755d11[_0x454b78('0x1d75')])['toLowerCase']();_0x15248c[_0x454b78('0x1d4')]({'controller':_0x454b78('0x1b25')+_0x4bd5a1+_0x454b78('0x9e4'),'controllerAs':'vm','templateUrl':_0x56cb25[_0x4bd5a1],'parent':angular[_0x454b78('0x1fcc')](_0x3e4aef[_0x454b78('0x18e5')]),'targetEvent':_0x28db05,'clickOutsideToClose':!![],'locals':{'whatsappAccountApp':_0x755d11,'whatsappAccount':_0x5ae04f['whatsappAccount'],'crudPermissions':_0x5ae04f[_0x454b78('0x1134')]}})['then'](function(_0x233ac8){const _0x2dbf89=_0x454b78;_0x233ac8&&(_0x233ac8['id']?_0x5ae04f['whatsappAccountApps'][_0x2dbf89('0xf5d')][_0x21fb3a]=_0x233ac8:_0x5ae04f[_0x2dbf89('0x787')][_0x2dbf89('0xf5d')]['splice'](_0x21fb3a,0x0,_0x233ac8),_0x5b2bb8());})[_0x454b78('0x130a')](function(_0x1f0fa8){const _0xc9837c=_0x454b78;_0x1f0fa8&&_0x13085c[_0xc9837c('0x52a')]({'title':_0x1f0fa8['status']?_0xc9837c('0x2168')+_0x1f0fa8[_0xc9837c('0x13ee')]+_0xc9837c('0xbf6')+_0x1f0fa8['statusText']:_0xc9837c('0xf1b'),'msg':_0x1f0fa8[_0xc9837c('0x5a5')]?JSON['stringify'](_0x1f0fa8[_0xc9837c('0x5a5')]):_0x1f0fa8[_0xc9837c('0x1ff0')]()});});}}function _0x13fcba(_0x469371,_0x2cb25a){const _0x482d12=_0x2be533;if(_0x5ae04f[_0x482d12('0x787')][_0x482d12('0xf5d')]['length']){const _0xd71a=_0x5ae04f[_0x482d12('0x787')][_0x482d12('0xf5d')][_0x2cb25a]?_0x5ae04f['whatsappAccountApps'][_0x482d12('0xf5d')][_0x2cb25a]:_0x5ae04f[_0x482d12('0x787')][_0x482d12('0xf5d')][0x0];_0x15248c[_0x482d12('0x1d4')]({'controller':_0x482d12('0x8ab'),'controllerAs':'vm','templateUrl':_0x56f967,'parent':angular[_0x482d12('0x1fcc')](_0x3e4aef[_0x482d12('0x18e5')]),'targetEvent':_0x469371,'clickOutsideToClose':!![],'locals':{'interval':{'interval':_0xd71a[_0x482d12('0x115c')],'IntervalId':_0xd71a[_0x482d12('0x5ae')],'application':!![]},'intervals':[],'crudPermissions':_0x5ae04f[_0x482d12('0x1134')]}})[_0x482d12('0x683')](function(_0x26a81e){const _0x6e7308=_0x482d12;_0x26a81e&&(_0xd71a[_0x6e7308('0x115c')]=_0x26a81e['interval']||_0x6e7308('0x1b54'),_0xd71a[_0x6e7308('0x5ae')]=_0x26a81e[_0x6e7308('0x5ae')]||null,_0x5b2bb8());});}}function _0x5b2bb8(){const _0x2f0334=_0x2be533;let _0x3f9f4f=0x1,_0x352edf=[];for(let _0x155be6=0x0;_0x155be6<_0x5ae04f[_0x2f0334('0x787')]['rows']['length'];_0x155be6++){const _0x43e6bc=_0x5ae04f[_0x2f0334('0x787')][_0x2f0334('0xf5d')][_0x155be6],_0xb40f66=[],_0x2d9e82=[];_0x43e6bc[_0x2f0334('0xe98')]=_0x43e6bc['interval']!==_0x2f0334('0x1b54')?[_0x43e6bc[_0x2f0334('0x115c')]]:_0x43e6bc[_0x2f0334('0x5ae')]?_0x2e3ca0()[_0x2f0334('0x386')](_0x2e3ca0()[_0x2f0334('0x25')](_0x5ae04f['intervals'][_0x2f0334('0xf5d')],{'IntervalId':_0x43e6bc[_0x2f0334('0x5ae')]}),_0x2f0334('0x115c')):[],_0x43e6bc['context']=_0x5ae04f[_0x2f0334('0x1990')][_0x2f0334('0x22d3')],_0x43e6bc[_0x2f0334('0x1a5b')]=_0x5ae04f[_0x2f0334('0x1990')]['exten'],_0x43e6bc['type']&&(_0x43e6bc[_0x2f0334('0xcf0')]=_0x43e6bc[_0x2f0334('0xcf0')][_0x2f0334('0x93a')]()),_0x43e6bc[_0x2f0334('0xe1e')]=_0xb40f66[_0x2f0334('0x1564')]?_0x2e3ca0()[_0x2f0334('0xc0f')](_0xb40f66)[_0x2f0334('0xe1e')]+0x1:_0x3f9f4f,_0x3f9f4f=(_0x2d9e82[_0x2f0334('0x1564')]?_0x2e3ca0()[_0x2f0334('0xc0f')](_0x2d9e82)[_0x2f0334('0xe1e')]:_0x43e6bc['priority'])+0x1,_0x352edf=_0x2e3ca0()['concat'](_0x352edf,_0xb40f66,[_0x43e6bc],_0x2d9e82);}_0x34cb3e['whatsappAccount'][_0x2f0334('0x10ef')]({'id':_0x5ae04f['whatsappAccount']['id']},_0x2e3ca0()['sortBy'](_0x352edf,_0x2f0334('0xe1e')))[_0x2f0334('0xe53')][_0x2f0334('0x683')](function(_0x21d58a){const _0x30b40b=_0x2f0334;_0x5ae04f['whatsappAccountApps'][_0x30b40b('0xf5d')]=_0x21d58a[_0x30b40b('0xf5d')];})['catch'](function(_0x2d5912){console['error'](_0x2d5912);});}function _0x44c54f(_0x269841){const _0x526ae4=_0x2be533;_0x5ae04f[_0x526ae4('0x787')]=_0x269841||{'count':0x0,'rows':[]};}function _0x53a351(){const _0x7f9f0e=_0x2be533;return _0x34cb3e[_0x7f9f0e('0x115c')]['get']({'fields':_0x7f9f0e('0x2072')})['$promise'][_0x7f9f0e('0x683')](function(_0x5c60a3){_0x5ae04f['intervals']=_0x5c60a3;})[_0x7f9f0e('0x130a')](function(_0x544d7a){console['error'](_0x544d7a);});}function _0x4c934b(){const _0x29bd69=_0x2be533;_0x5ae04f[_0x29bd69('0x1883')]=_0x34cb3e[_0x29bd69('0x1990')][_0x29bd69('0x13be')](_0x5ae04f['query'],_0x44c54f)[_0x29bd69('0xe53')];}function _0x3d82c9(_0x19ee9e){const _0x39aea5=_0x2be533;_0x2e3ca0()[_0x39aea5('0x3ec')](_0x5ae04f[_0x39aea5('0x787')]['rows'],{'id':_0x19ee9e['id']}),_0x5b2bb8(),_0x13085c[_0x39aea5('0x53')]({'title':'App\x20deleted!','msg':_0x19ee9e[_0x39aea5('0x1d75')]?_0x19ee9e[_0x39aea5('0x1d75')]+_0x39aea5('0x194d'):''});}function _0x4533f4(_0x53cb28){const _0x351c3a=_0x2be533,_0x317616=_0x15248c['confirm']()[_0x351c3a('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20applications?')[_0x351c3a('0x26e3')](_0x351c3a('0xed5')+_0x5ae04f['selectedWhatsappAccountApps'][_0x351c3a('0x1564')]+'\x20selected'+_0x351c3a('0x1ee7'))[_0x351c3a('0x1040')](_0x351c3a('0x1b94'))[_0x351c3a('0xe42')](_0x53cb28)['ok']('OK')[_0x351c3a('0x19fb')](_0x351c3a('0x16b8'));_0x15248c[_0x351c3a('0x1d4')](_0x317616)['then'](function(){const _0x45854e=_0x351c3a;_0x5ae04f[_0x45854e('0x276d')][_0x45854e('0x1299')](function(_0x42a919){const _0x24dd42=_0x45854e;_0x2e3ca0()['remove'](_0x5ae04f[_0x24dd42('0x787')][_0x24dd42('0xf5d')],{'id':_0x42a919['id']});}),_0x5ae04f['selectedWhatsappAccountApps']=[],_0x5b2bb8();});}}const _0x199e9c=_0x2bcf34;_0x3dc749[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x1990'),_0x189033('0x263c'),_0x189033('0x2c9'),_0x189033('0x1d08'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x3dc749(_0x59f311,_0x492d9c,_0x5701ee,_0x59f987,_0x53f0b2,_0x43a14e,_0x2a3741,_0x339ffd,_0x5afe42,_0x3ef1a2){const _0x33385c=_0x189033,_0x5d0220=this;_0x5d0220['currentUser']=_0x5afe42[_0x33385c('0x20b2')](),_0x5d0220[_0x33385c('0x1990')]=_0x53f0b2,_0x5d0220['crudPermissions']=_0x3ef1a2,_0x5d0220[_0x33385c('0x2c9')]=_0x2a3741,_0x5d0220['items']=[],_0x5d0220['allowedItems']=[],_0x5d0220[_0x33385c('0x1378')]=[],_0x5d0220[_0x33385c('0x125e')]=[],_0x5d0220['startingSelectedItems']=[],_0x5d0220[_0x33385c('0x2106')]=![],_0x5d0220[_0x33385c('0x1dd2')]=_0x487d4f,_0x5d0220[_0x33385c('0xa5f')]=_0x345d97,_0x5d0220[_0x33385c('0xf82')]=_0x377a77,_0x5d0220[_0x33385c('0x169f')]={'readOnly':!_0x5d0220['crudPermissions'][_0x33385c('0x1978')],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x33385c('0x11bc'),'line2':[_0x33385c('0x60a'),_0x33385c('0x1d43')],'line3':'','labelAll':_0x339ffd[_0x33385c('0x2728')]('WHATSAPP.ALL_AGENTS'),'labelSelected':_0x339ffd[_0x33385c('0x2728')](_0x33385c('0x2803')),'transferCallback':function(){const _0xadd0ea=_0x33385c,_0x1754ed=_0x2e3ca0()[_0xadd0ea('0x25cb')](_0x5d0220[_0xadd0ea('0x23a7')],_0x5d0220[_0xadd0ea('0x1378')],'id');_0x5d0220[_0xadd0ea('0x2106')]=_0x2e3ca0()[_0xadd0ea('0x173f')](_0x1754ed)?![]:!![];}};function _0x487d4f(){const _0xe61a16=_0x33385c;return _0x5afe42['hasRole']('admin')?_0x4e15be()[_0xe61a16('0x130a')](function(_0x3654f9){const _0xa10e97=_0xe61a16;_0x5701ee[_0xa10e97('0x52a')]({'title':_0x3654f9[_0xa10e97('0x13ee')]?_0xa10e97('0x2168')+_0x3654f9['status']+_0xa10e97('0xbf6')+_0x3654f9[_0xa10e97('0x24a9')]:'SYSTEM:GET_AGENTS','msg':_0x3654f9[_0xa10e97('0x13ee')]?JSON[_0xa10e97('0x258a')](_0x3654f9[_0xa10e97('0x5a5')]):_0x3654f9[_0xa10e97('0x1ff0')]()});}):_0x24461c()[_0xe61a16('0x683')](function(_0x1b3cc3){const _0x587ac7=_0xe61a16;return _0x5d0220[_0x587ac7('0x1aa')]=_0x1b3cc3,_0x4e15be();})[_0xe61a16('0x130a')](function(_0x23c51b){const _0x57a094=_0xe61a16;_0x5701ee[_0x57a094('0x52a')]({'title':_0x23c51b[_0x57a094('0x13ee')]?_0x57a094('0x2168')+_0x23c51b[_0x57a094('0x13ee')]+_0x57a094('0xbf6')+_0x23c51b[_0x57a094('0x24a9')]:'SYSTEM:GET_AGENTS','msg':_0x23c51b['status']?JSON['stringify'](_0x23c51b[_0x57a094('0x5a5')]):_0x23c51b[_0x57a094('0x1ff0')]()});});}function _0x24461c(){return _0x492d9c(function(_0x4c46c3,_0x50e35a){const _0x5adba2=a0_0x4e0a;_0x59f987[_0x5adba2('0x22df')]['get']({'userProfileId':_0x5d0220['currentUser']['userProfileId'],'name':_0x5adba2('0x1bc0')})[_0x5adba2('0xe53')][_0x5adba2('0x683')](function(_0x3bf2d4){const _0x2a2c8b=_0x5adba2,_0x5354e8=_0x3bf2d4&&_0x3bf2d4[_0x2a2c8b('0xf5d')]?_0x3bf2d4[_0x2a2c8b('0xf5d')][0x0]:null;_0x4c46c3(_0x5354e8);})[_0x5adba2('0x130a')](function(_0x8fafc8){_0x50e35a(_0x8fafc8);});});}function _0x4e15be(){return _0x492d9c(function(_0x439a9c,_0x2d3bb7){return _0x160a03()['then'](function(_0x6babfa){const _0x2fb0a7=a0_0x4e0a;return _0x5d0220['items']=_0x6babfa[_0x2fb0a7('0xf5d')]?_0x6babfa[_0x2fb0a7('0xf5d')]:[],_0x5afe42[_0x2fb0a7('0xca1')]('admin')?_0x6babfa:_0x5d0220[_0x2fb0a7('0x1aa')]?_0x5d0220['section'][_0x2fb0a7('0x170')]?_0x6babfa:_0x1ea49e():null;})['then'](function(_0x4755d4){const _0x12bf7e=a0_0x4e0a,_0x51e548=_0x4755d4&&_0x4755d4[_0x12bf7e('0xf5d')]?_0x4755d4[_0x12bf7e('0xf5d')]:[];return _0x5d0220[_0x12bf7e('0x1c47')]=_0x2e3ca0()['map'](_0x51e548,function(_0x19e8b4){const _0x2ba48c=_0x12bf7e;return _0x2e3ca0()[_0x2ba48c('0x1c07')](_0x5d0220[_0x2ba48c('0x1996')],{'id':_0x5afe42['hasRole'](_0x2ba48c('0x20c2'))||_0x5d0220[_0x2ba48c('0x1aa')][_0x2ba48c('0x170')]?_0x19e8b4['id']:_0x19e8b4[_0x2ba48c('0x832')]});}),_0x5d0220[_0x12bf7e('0x125e')]=angular[_0x12bf7e('0x1a86')](_0x5d0220[_0x12bf7e('0x1c47')]),_0x5d0220[_0x12bf7e('0x1996')][_0x12bf7e('0x1299')](function(_0x2f0dd0){const _0x4c8d3a=_0x12bf7e,_0x5de831=_0x2e3ca0()['find'](_0x5d0220[_0x4c8d3a('0x1c47')],{'id':_0x2f0dd0['id']});_0x5afe42[_0x4c8d3a('0xca1')](_0x4c8d3a('0x20c2'))?_0x2f0dd0[_0x4c8d3a('0x24f4')]=!![]:_0x2f0dd0[_0x4c8d3a('0x24f4')]=typeof _0x5de831!=='undefined'?!![]:![];}),_0x4a0314();})['then'](function(_0x543ea9){const _0x30c9e4=a0_0x4e0a,_0x2b4bc4=_0x543ea9&&_0x543ea9[_0x30c9e4('0xf5d')]?_0x543ea9[_0x30c9e4('0xf5d')]:[];_0x5d0220[_0x30c9e4('0x1378')]=_0x2e3ca0()[_0x30c9e4('0x386')](_0x2b4bc4,function(_0x4f95bd){const _0x488f4c=_0x30c9e4,_0x249de4=_0x2e3ca0()[_0x488f4c('0x1c07')](_0x5d0220['items'],{'id':_0x4f95bd['id']});return _0x249de4['penalty']=_0x4f95bd[_0x488f4c('0x1092')]?'penalty\x20'+_0x4f95bd[_0x488f4c('0x1092')][_0x488f4c('0x1e2a')]:'',_0x249de4[_0x488f4c('0x1d43')]=typeof _0x4f95bd['internal']!==_0x488f4c('0x1867')?'<'+_0x4f95bd[_0x488f4c('0x1d43')]+'>':'',_0x249de4;}),_0x5d0220['startingSelectedItems']=angular[_0x30c9e4('0x1a86')](_0x5d0220[_0x30c9e4('0x1378')]),_0x5d0220[_0x30c9e4('0x169f')]['selectedItems']=_0x5d0220[_0x30c9e4('0x1378')],_0x5d0220[_0x30c9e4('0x169f')][_0x30c9e4('0x1996')]=_0x2e3ca0()[_0x30c9e4('0x461')](_0x5d0220['allowedItems'],_0x5d0220[_0x30c9e4('0x169f')][_0x30c9e4('0x1378')],'id'),_0x439a9c();})['catch'](function(_0x438e2b){_0x2d3bb7(_0x438e2b);});});}function _0x1ea49e(){return _0x492d9c(function(_0x49bf90,_0x4ba106){const _0x5b5bdc=a0_0x4e0a;return _0x59f987[_0x5b5bdc('0xcf7')][_0x5b5bdc('0x1e6e')]({'sectionId':_0x5d0220[_0x5b5bdc('0x1aa')]['id'],'nolimit':!![]})[_0x5b5bdc('0xe53')][_0x5b5bdc('0x683')](function(_0x5106fb){_0x49bf90(_0x5106fb);})[_0x5b5bdc('0x130a')](function(_0x39f55b){_0x4ba106(_0x39f55b);});});}function _0x4a0314(){return _0x492d9c(function(_0x41be76,_0x1439aa){const _0xac3671=a0_0x4e0a;return _0x59f987['whatsappAccount']['getAgents']({'id':_0x5d0220[_0xac3671('0x1990')]['id'],'fields':_0xac3671('0x72b'),'nolimit':!![],'role':_0xac3671('0x2327')})[_0xac3671('0xe53')][_0xac3671('0x683')](function(_0xcc748e){_0x41be76(_0xcc748e);})[_0xac3671('0x130a')](function(_0x1cc866){_0x1439aa(_0x1cc866);});});}function _0x160a03(){return _0x492d9c(function(_0x3d00a0,_0x188465){const _0x1306f3=a0_0x4e0a;return _0x59f987['user'][_0x1306f3('0x1e6e')]({'fields':_0x1306f3('0x72b'),'nolimit':!![],'role':'agent'})[_0x1306f3('0xe53')][_0x1306f3('0x683')](function(_0x5e7cff){_0x3d00a0(_0x5e7cff);})[_0x1306f3('0x130a')](function(_0x239944){_0x188465(_0x239944);});});}function _0x2676e4(_0x1cf817){return _0x492d9c(function(_0x227316,_0x225fd1){const _0x1045e3=a0_0x4e0a;_0x2e3ca0()[_0x1045e3('0x173f')](_0x1cf817)?_0x227316():_0x59f987[_0x1045e3('0x1990')][_0x1045e3('0x2179')]({'id':_0x5d0220[_0x1045e3('0x1990')]['id'],'ids':_0x2e3ca0()[_0x1045e3('0x386')](_0x1cf817,'id')})[_0x1045e3('0xe53')][_0x1045e3('0x683')](function(){_0x227316();})[_0x1045e3('0x130a')](function(_0x2c44c4){_0x225fd1(_0x2c44c4);});});}function _0x569795(_0x26aed8){return _0x492d9c(function(_0x3da6a2,_0x3ca47a){const _0x6844f8=a0_0x4e0a;_0x2e3ca0()[_0x6844f8('0x173f')](_0x26aed8)?_0x3da6a2():_0x59f987[_0x6844f8('0x1990')]['removeAgents']({'id':_0x5d0220[_0x6844f8('0x1990')]['id'],'ids':_0x2e3ca0()[_0x6844f8('0x386')](_0x26aed8,'id')})[_0x6844f8('0xe53')][_0x6844f8('0x683')](function(){_0x3da6a2();})[_0x6844f8('0x130a')](function(_0x5813ff){_0x3ca47a(_0x5813ff);});});}function _0x345d97(){const _0x11ca25=_0x33385c,_0x3b27ff=_0x2e3ca0()[_0x11ca25('0x461')](_0x5d0220['startingSelectedItems'],_0x5d0220[_0x11ca25('0x1378')],'id'),_0x453f04=_0x2e3ca0()[_0x11ca25('0x461')](_0x5d0220[_0x11ca25('0x1378')],_0x5d0220[_0x11ca25('0x23a7')],'id');return _0x569795(_0x3b27ff)[_0x11ca25('0x683')](function(){return _0x2676e4(_0x453f04);})[_0x11ca25('0x683')](function(){const _0x3212fb=_0x11ca25;_0x5d0220[_0x3212fb('0x2106')]=![],_0x5d0220[_0x3212fb('0x125e')]=angular['copy'](_0x5d0220['allowedItems']),_0x5d0220['startingSelectedItems']=angular[_0x3212fb('0x1a86')](_0x5d0220[_0x3212fb('0x1378')]),_0x5701ee[_0x3212fb('0x53')]({'title':_0x3212fb('0xd28'),'msg':_0x3212fb('0x89d')});})[_0x11ca25('0x130a')](function(_0x5c437e){const _0x2b1b41=_0x11ca25;_0x5701ee[_0x2b1b41('0x52a')]({'title':_0x5c437e[_0x2b1b41('0x13ee')]?_0x2b1b41('0x2168')+_0x5c437e[_0x2b1b41('0x13ee')]+_0x2b1b41('0xbf6')+_0x5c437e[_0x2b1b41('0x24a9')]:_0x2b1b41('0x1b71'),'msg':_0x5c437e[_0x2b1b41('0x13ee')]?JSON[_0x2b1b41('0x258a')](_0x5c437e[_0x2b1b41('0x5a5')]):_0x5c437e[_0x2b1b41('0x1ff0')]()});});}function _0x377a77(){const _0x3e3239=_0x33385c;_0x59f311[_0x3e3239('0x1715')]();}}const _0x194f8d=_0x3dc749;_0x47f1da[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x144a'),_0x189033('0x1990'),_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0x47f1da(_0x1e1edb,_0x3d3b33,_0x42db72,_0x1b01ef,_0x507c3b,_0x101a8c,_0x172b03,_0x429d2e){const _0x124713=_0x189033,_0x21105d=this;_0x21105d['currentUser']=_0x172b03[_0x124713('0x20b2')](),_0x21105d[_0x124713('0x17f')]=[],_0x21105d['title']='WHATSAPP.EDIT_'+(_0x1b01ef[_0x124713('0x11f3')]||_0x1b01ef[_0x124713('0x1d75')])[_0x124713('0x80')](),_0x21105d[_0x124713('0x2327')]=angular[_0x124713('0x1a86')](_0x1b01ef),_0x21105d[_0x124713('0x1134')]=_0x429d2e,_0x21105d[_0x124713('0x258d')]={};if(_0x21105d['agent'][_0x124713('0x1407')])switch(_0x21105d[_0x124713('0x2327')][_0x124713('0x11f3')]?_0x21105d[_0x124713('0x2327')][_0x124713('0x11f3')][_0x124713('0x93a')]():_0x21105d['agent']['app'][_0x124713('0x93a')]()){case _0x124713('0xbf0'):break;case _0x124713('0x205c'):{const _0x3e1744=_0x21105d[_0x124713('0x2327')][_0x124713('0x1407')][_0x124713('0x1fc5')](',');_0x21105d[_0x124713('0x2327')][_0x124713('0x1d46')]=_0x3e1744[0x0],_0x21105d[_0x124713('0x2327')][_0x124713('0x1a1c')]=_0x3e1744[0x1],_0x21105d['agent']['welcomemessage']=_0x3e1744[_0x124713('0x12c8')](0x2,_0x3e1744['length'])[_0x124713('0x1630')](',');}break;case'dialogflowv2':{const _0x3dde2c=_0x21105d[_0x124713('0x2327')][_0x124713('0x1407')][_0x124713('0x1fc5')](',');_0x21105d['agent'][_0x124713('0x2119')]=_0x3dde2c[0x0],_0x21105d[_0x124713('0x2327')][_0x124713('0x38')]=_0x3dde2c[0x1],_0x21105d[_0x124713('0x2327')][_0x124713('0x406')]=_0x3dde2c[0x2],_0x21105d[_0x124713('0x2327')][_0x124713('0x1a1c')]=_0x3dde2c[0x3],_0x21105d[_0x124713('0x2327')][_0x124713('0x6d9')]=_0x3dde2c[_0x124713('0x12c8')](0x4,_0x3dde2c[_0x124713('0x1564')])['join'](',');}break;case'amazonlex':{const _0xeeaf04=_0x21105d[_0x124713('0x2327')][_0x124713('0x1407')][_0x124713('0x1fc5')](',');_0x21105d[_0x124713('0x2327')][_0x124713('0x7ae')]=_0xeeaf04[0x0],_0x21105d[_0x124713('0x2327')][_0x124713('0x204a')]=_0xeeaf04[0x1],_0x21105d[_0x124713('0x2327')][_0x124713('0x5ba')]=_0xeeaf04[0x2],_0x21105d['agent']['botname']=_0xeeaf04[0x3],_0x21105d[_0x124713('0x2327')]['welcomemessage']=_0xeeaf04[_0x124713('0x12c8')](0x4,_0xeeaf04['length'])['join'](',');}break;case _0x124713('0x2408'):{const _0x29135e=_0x21105d[_0x124713('0x2327')]['appdata'][_0x124713('0x1fc5')](',');_0x21105d['agent']['times']=isNaN(_0x29135e[0x0])?_0x29135e[0x0]:parseInt(_0x29135e[0x0],0xa),_0x21105d[_0x124713('0x2327')][_0x124713('0x1bcd')]=_0x29135e['slice'](0x1,_0x29135e[_0x124713('0x1564')])[_0x124713('0x1630')](',');}break;case _0x124713('0x8c2'):_0x21105d['agent'][_0x124713('0x1bcd')]=_0x21105d[_0x124713('0x2327')]['appdata'];break;case'set':_0x21105d[_0x124713('0x2327')][_0x124713('0x60a')]=_0x21105d[_0x124713('0x2327')][_0x124713('0x1407')][_0x124713('0x1fc5')]('=')[0x0],_0x21105d[_0x124713('0x2327')][_0x124713('0x1c6b')]=_0x21105d[_0x124713('0x2327')][_0x124713('0x1407')]['split']('=')[0x1];break;case'agi':_0x21105d['agent']['project']=_0x21105d[_0x124713('0x2327')][_0x124713('0x1407')];break;default:{const _0x4574dd=_0x21105d['agent']['appdata'][_0x124713('0x1fc5')](',');_0x21105d[_0x124713('0x2327')][_0x124713('0x2327')]=_0x2e3ca0()[_0x124713('0x173f')](_0x4574dd[0x0])?_0x4574dd[0x0]:isNaN(_0x4574dd[0x0])?_0x4574dd[0x0]:parseInt(_0x4574dd[0x0],0xa),_0x21105d[_0x124713('0x2327')][_0x124713('0x1668')]=_0x2e3ca0()[_0x124713('0x173f')](_0x4574dd[0x1])?_0x4574dd[0x1]:isNaN(_0x4574dd[0x1])?_0x4574dd[0x1]:parseInt(_0x4574dd[0x1],0xa);}break;}else _0x21105d['agent']['timeout']=0x1e;_0x21105d['agent']['type']&&_0x21105d[_0x124713('0x2327')][_0x124713('0xcf0')][_0x124713('0x93a')]()===_0x124713('0x17cd')&&_0x21105d[_0x124713('0x2327')]['appType'][_0x124713('0x93a')]()===_0x124713('0x659')&&(_0x21105d[_0x124713('0x2327')][_0x124713('0x24fa')]=_0x21105d['agent']['phone']?_0x21105d[_0x124713('0x2327')][_0x124713('0xd31')][_0x124713('0x1fc5')]('$')[0x0]:undefined,_0x21105d[_0x124713('0x2327')][_0x124713('0xabd')]=_0x21105d[_0x124713('0x2327')]['callerID']?_0x124713('0xac1')+_0x21105d[_0x124713('0x2327')]['callerID']:undefined);_0x21105d[_0x124713('0x1658')]=_0x29a58f,_0x21105d[_0x124713('0xf82')]=_0x53ef6e,_0x172b03[_0x124713('0xca1')](_0x124713('0x20c2'))?_0x101a8c[_0x124713('0xc96')][_0x124713('0x1e6e')]({'fields':_0x124713('0xa10'),'sort':_0x124713('0x60a'),'nolimit':'true','role':'agent'})['$promise']['then'](function(_0x4713fb){const _0x47d580=_0x124713;_0x21105d[_0x47d580('0x756')]=_0x4713fb[_0x47d580('0xf5d')]||[];})[_0x124713('0x130a')](function(_0x3883e2){const _0x3fd894=_0x124713;_0x42db72[_0x3fd894('0x52a')]({'title':_0x3883e2[_0x3fd894('0x13ee')]?_0x3fd894('0x2168')+_0x3883e2[_0x3fd894('0x13ee')]+'\x20-\x20'+_0x3883e2[_0x3fd894('0x24a9')]:'SYSTEM:GET_AGENTS','msg':_0x3883e2[_0x3fd894('0x5a5')]?JSON[_0x3fd894('0x258a')](_0x3883e2[_0x3fd894('0x5a5')]):_0x3883e2[_0x3fd894('0x1ff0')]()});}):_0x101a8c[_0x124713('0xc96')][_0x124713('0x1e6e')]({'fields':_0x124713('0xa10'),'sort':'name','nolimit':_0x124713('0x26ac'),'role':_0x124713('0x2327')})[_0x124713('0xe53')]['then'](function(_0x6c19a5){const _0x4efc5b=_0x124713;_0x21105d[_0x4efc5b('0x756')]=_0x6c19a5[_0x4efc5b('0xf5d')]||[];})[_0x124713('0x683')](function(){const _0x2b63b3=_0x124713;return _0x101a8c['userProfileSection'][_0x2b63b3('0x1e6e')]({'userProfileId':_0x21105d[_0x2b63b3('0x11ed')][_0x2b63b3('0x2f')],'sectionId':0xca})[_0x2b63b3('0xe53')];})[_0x124713('0x683')](function(_0x1750af){const _0x4c21e6=_0x124713,_0x41c7ae=_0x1750af&&_0x1750af[_0x4c21e6('0xf5d')]?_0x1750af[_0x4c21e6('0xf5d')][0x0]:null;if(!_0x41c7ae){const _0x1340d0=[];let _0x4318ff=null;_0x21105d[_0x4c21e6('0x2327')]&&(_0x4318ff=_0x2e3ca0()[_0x4c21e6('0x1c07')](_0x21105d[_0x4c21e6('0x756')],{'name':_0x21105d[_0x4c21e6('0x2327')]['agent']}));for(let _0x58cfd5=0x0;_0x58cfd5<_0x21105d[_0x4c21e6('0x756')]['length'];_0x58cfd5++){_0x4318ff&&_0x21105d['agents'][_0x58cfd5]['id']===_0x4318ff['id']&&(_0x21105d[_0x4c21e6('0x756')][_0x58cfd5][_0x4c21e6('0x319')]=![],_0x1340d0['push'](_0x21105d['agents'][_0x58cfd5]));}_0x21105d[_0x4c21e6('0x756')]=_0x1340d0;}else{if(!_0x41c7ae['autoAssociation'])return _0x101a8c[_0x4c21e6('0xcf7')]['get']({'sectionId':_0x41c7ae['id']})[_0x4c21e6('0xe53')][_0x4c21e6('0x683')](function(_0x1e1db2){const _0x1e99f7=_0x4c21e6,_0x5ba74f=_0x2e3ca0()[_0x1e99f7('0x386')](_0x1e1db2[_0x1e99f7('0xf5d')],function(_0x3e1081){const _0x4cc480=_0x1e99f7;return _0x2e3ca0()[_0x4cc480('0x1c07')](_0x21105d[_0x4cc480('0x756')],{'id':_0x3e1081[_0x4cc480('0x832')]});});let _0x243822=null;_0x21105d[_0x1e99f7('0x2327')]&&(_0x243822=_0x2e3ca0()[_0x1e99f7('0x1c07')](_0x21105d[_0x1e99f7('0x756')],{'name':_0x21105d[_0x1e99f7('0x2327')][_0x1e99f7('0x2327')]}));if(_0x243822&&!_0x2e3ca0()[_0x1e99f7('0x7a2')](_0x5ba74f,['id',_0x243822['id']])){const _0x2c5967=_0x2e3ca0()[_0x1e99f7('0x1c07')](_0x21105d[_0x1e99f7('0x756')],{'id':_0x243822['id']});_0x2c5967['canSelect']=![],_0x5ba74f['push'](_0x2c5967);}_0x21105d[_0x1e99f7('0x756')]=_0x5ba74f;});}})[_0x124713('0x130a')](function(_0x5bdbf5){const _0x290f06=_0x124713;_0x42db72['error']({'title':_0x5bdbf5['status']?_0x290f06('0x2168')+_0x5bdbf5['status']+'\x20-\x20'+_0x5bdbf5[_0x290f06('0x24a9')]:_0x290f06('0x391'),'msg':_0x5bdbf5[_0x290f06('0x5a5')]?JSON[_0x290f06('0x258a')](_0x5bdbf5['data']):_0x5bdbf5[_0x290f06('0x1ff0')]()});});function _0x29a58f(){const _0x2940bf=_0x124713;_0x21105d[_0x2940bf('0x17f')]=[];const _0x435edc=[];_0x21105d[_0x2940bf('0x2327')][_0x2940bf('0xcf0')]&&_0x21105d['agent'][_0x2940bf('0xcf0')][_0x2940bf('0x93a')]()===_0x2940bf('0x17cd')&&_0x21105d['agent'][_0x2940bf('0x11f3')]==='outboundDial'&&(_0x21105d['agent'][_0x2940bf('0xd31')]=_0x507c3b[_0x2940bf('0x145a')]?(_0x21105d[_0x2940bf('0x2327')]['prefix']||'')+_0x2940bf('0x249e')+_0x507c3b['cutdigits']+'}':(_0x21105d[_0x2940bf('0x2327')][_0x2940bf('0x24fa')]||'')+_0x2940bf('0x20cb'),_0x507c3b[_0x2940bf('0x75b')]!==_0x2940bf('0x925')?_0x21105d['agent'][_0x2940bf('0x158e')][_0x2940bf('0x824')](_0x2940bf('0x1b1'))<0x0&&(_0x21105d['agent'][_0x2940bf('0x158e')]+=_0x2940bf('0x1b1')):_0x21105d[_0x2940bf('0x2327')][_0x2940bf('0x158e')]=_0x21105d[_0x2940bf('0x2327')][_0x2940bf('0x158e')]['replace'](_0x2940bf('0x1b1'),''));const _0x2109f5=_0x2e3ca0()['find'](_0x21105d[_0x2940bf('0x756')],{'name':_0x21105d[_0x2940bf('0x2327')][_0x2940bf('0x2327')]});_0x2109f5&&(_0x21105d[_0x2940bf('0x2327')][_0x2940bf('0x10c5')]=_0x2109f5['id']);if(_0x21105d[_0x2940bf('0x2327')]['appType']&&_0x21105d['agent'][_0x2940bf('0x11f3')]===_0x2940bf('0xbf0')){}else switch((_0x21105d[_0x2940bf('0x2327')][_0x2940bf('0x1d75')]||_0x21105d[_0x2940bf('0x2327')]['appType'])[_0x2940bf('0x93a')]()){case _0x2940bf('0x877'):_0x21105d[_0x2940bf('0x2327')]['appdata']=_0x21105d[_0x2940bf('0x2327')]['name']+'='+_0x21105d[_0x2940bf('0x2327')]['value'];break;case _0x2940bf('0xbf0'):break;default:_0x435edc[0x0]=_0x21105d[_0x2940bf('0x2327')]['agent'],_0x435edc[0x1]=_0x21105d[_0x2940bf('0x2327')][_0x2940bf('0x1668')],_0x21105d[_0x2940bf('0x2327')][_0x2940bf('0x1407')]=_0x435edc[_0x2940bf('0x1630')](',');}_0x53ef6e(_0x21105d['agent']);}function _0x53ef6e(_0x3c2ace){const _0x41c623=_0x124713;_0x1e1edb[_0x41c623('0x1715')](_0x3c2ace);}}const _0x58a916=_0x47f1da;_0x1703dc[_0x189033('0x14be')]=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x144a'),_0x189033('0x1990'),_0x189033('0x56b'),_0x189033('0xba1'),'crudPermissions'];function _0x1703dc(_0x457cfa,_0x32feb1,_0x2ee9ff,_0x3a6612,_0x31740d,_0x452d00,_0x15195a,_0x1ccb0d){const _0x14e2b2=_0x189033,_0x2f1f5e=this;_0x2f1f5e[_0x14e2b2('0x11ed')]=_0x15195a[_0x14e2b2('0x20b2')](),_0x2f1f5e[_0x14e2b2('0x17f')]=[],_0x2f1f5e[_0x14e2b2('0xf28')]=_0x14e2b2('0x8cb')+(_0x3a6612[_0x14e2b2('0x11f3')]||_0x3a6612[_0x14e2b2('0x1d75')])[_0x14e2b2('0x80')](),_0x2f1f5e['amazonlex']=angular[_0x14e2b2('0x1a86')](_0x3a6612),_0x2f1f5e[_0x14e2b2('0x1134')]=_0x1ccb0d,_0x2f1f5e['hasModulePermissions']={};if(_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x1407')])switch(_0x2f1f5e[_0x14e2b2('0x1db1')]['appType']?_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x11f3')][_0x14e2b2('0x93a')]():_0x2f1f5e['amazonlex'][_0x14e2b2('0x1d75')][_0x14e2b2('0x93a')]()){case'custom':break;case _0x14e2b2('0x205c'):{const _0x447dad=_0x2f1f5e['amazonlex'][_0x14e2b2('0x1407')][_0x14e2b2('0x1fc5')](',');_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x1d46')]=_0x447dad[0x0],_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x1a1c')]=_0x447dad[0x1],_0x2f1f5e[_0x14e2b2('0x1db1')]['welcomemessage']=_0x447dad[_0x14e2b2('0x12c8')](0x2,_0x447dad[_0x14e2b2('0x1564')])['join'](',');}break;case _0x14e2b2('0xd24'):{const _0xdcc0b2=_0x2f1f5e['amazonlex'][_0x14e2b2('0x1407')][_0x14e2b2('0x1fc5')](',');_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x2119')]=_0xdcc0b2[0x0],_0x2f1f5e[_0x14e2b2('0x1db1')]['clientEmail']=_0xdcc0b2[0x1],_0x2f1f5e['amazonlex']['privateKey']=_0xdcc0b2[0x2],_0x2f1f5e[_0x14e2b2('0x1db1')]['language']=_0xdcc0b2[0x3],_0x2f1f5e[_0x14e2b2('0x1db1')]['welcomemessage']=_0xdcc0b2[_0x14e2b2('0x12c8')](0x4,_0xdcc0b2['length'])['join'](',');}break;case'amazonlex':{const _0x1a0e55=_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x1407')][_0x14e2b2('0x1fc5')](',');_0x2f1f5e['amazonlex']['accesskeyid']=_0x1a0e55[0x0],_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x204a')]=_0x1a0e55[0x1],_0x2f1f5e['amazonlex'][_0x14e2b2('0x5ba')]=_0x1a0e55[0x2],_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x11a9')]=_0x1a0e55[0x3],_0x2f1f5e['amazonlex'][_0x14e2b2('0x6d9')]=_0x1a0e55[_0x14e2b2('0x12c8')](0x4,_0x1a0e55['length'])[_0x14e2b2('0x1630')](',');}break;case _0x14e2b2('0x2408'):{const _0x25ee09=_0x2f1f5e['amazonlex'][_0x14e2b2('0x1407')][_0x14e2b2('0x1fc5')](',');_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x35')]=isNaN(_0x25ee09[0x0])?_0x25ee09[0x0]:parseInt(_0x25ee09[0x0],0xa),_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x1bcd')]=_0x25ee09['slice'](0x1,_0x25ee09[_0x14e2b2('0x1564')])[_0x14e2b2('0x1630')](',');}break;case _0x14e2b2('0x8c2'):_0x2f1f5e[_0x14e2b2('0x1db1')]['text']=_0x2f1f5e[_0x14e2b2('0x1db1')]['appdata'];break;case _0x14e2b2('0x877'):_0x2f1f5e[_0x14e2b2('0x1db1')]['name']=_0x2f1f5e[_0x14e2b2('0x1db1')]['appdata'][_0x14e2b2('0x1fc5')]('=')[0x0],_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x1c6b')]=_0x2f1f5e[_0x14e2b2('0x1db1')]['appdata'][_0x14e2b2('0x1fc5')]('=')[0x1];break;case'agi':_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x273a')]=_0x2f1f5e['amazonlex']['appdata'];break;default:{const _0x1575e4=_0x2f1f5e[_0x14e2b2('0x1db1')]['appdata'][_0x14e2b2('0x1fc5')](',');_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x7ae')]=_0x2e3ca0()[_0x14e2b2('0x173f')](_0x1575e4[0x0])?_0x1575e4[0x0]:isNaN(_0x1575e4[0x0])?_0x1575e4[0x0]:parseInt(_0x1575e4[0x0],0xa),_0x2f1f5e[_0x14e2b2('0x1db1')]['secretaccesskey']=_0x2e3ca0()['isEmpty'](_0x1575e4[0x1])?_0x1575e4[0x1]:isNaN(_0x1575e4[0x1])?_0x1575e4[0x1]:parseInt(_0x1575e4[0x1],0xa),_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x5ba')]=_0x2e3ca0()[_0x14e2b2('0x173f')](_0x1575e4[0x2])?_0x1575e4[0x2]:isNaN(_0x1575e4[0x2])?_0x1575e4[0x2]:parseInt(_0x1575e4[0x2],0xa),_0x2f1f5e['amazonlex']['botname']=_0x2e3ca0()[_0x14e2b2('0x173f')](_0x1575e4[0x3])?_0x1575e4[0x3]:isNaN(_0x1575e4[0x3])?_0x1575e4[0x3]:parseInt(_0x1575e4[0x3],0xa),_0x2f1f5e['amazonlex'][_0x14e2b2('0x6d9')]=_0x2e3ca0()[_0x14e2b2('0x173f')](_0x1575e4[0x4])?_0x1575e4[0x4]:isNaN(_0x1575e4[0x4])?_0x1575e4[0x4]:parseInt(_0x1575e4[0x4],0xa);}break;}else _0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x5ba')]=_0x14e2b2('0xfb5');_0x2f1f5e['amazonlex'][_0x14e2b2('0xcf0')]&&_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0xcf0')][_0x14e2b2('0x93a')]()===_0x14e2b2('0x17cd')&&_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x11f3')][_0x14e2b2('0x93a')]()===_0x14e2b2('0x659')&&(_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x24fa')]=_0x2f1f5e[_0x14e2b2('0x1db1')]['phone']?_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0xd31')]['split']('$')[0x0]:undefined,_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0xabd')]=_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x73c')]?_0x14e2b2('0xac1')+_0x2f1f5e[_0x14e2b2('0x1db1')][_0x14e2b2('0x73c')]:undefined);_0x2f1f5e[_0x14e2b2('0x1658')]=_0x2ebc72,_0x2f1f5e[_0x14e2b2('0xf82')]=_0x3d898e;function _0x2ebc72(){const _0x3fed7e=_0x14e2b2;_0x2f1f5e[_0x3fed7e('0x17f')]=[];const _0x122cb7=[];_0x2f1f5e['amazonlex'][_0x3fed7e('0xcf0')]&&_0x2f1f5e[_0x3fed7e('0x1db1')]['type'][_0x3fed7e('0x93a')]()==='outbound'&&_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x11f3')]===_0x3fed7e('0x4d2')&&(_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0xd31')]=_0x31740d[_0x3fed7e('0x145a')]?(_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x24fa')]||'')+_0x3fed7e('0x249e')+_0x31740d[_0x3fed7e('0x145a')]+'}':(_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x24fa')]||'')+_0x3fed7e('0x20cb'),_0x31740d[_0x3fed7e('0x75b')]!==_0x3fed7e('0x925')?_0x2f1f5e['amazonlex']['options'][_0x3fed7e('0x824')](_0x3fed7e('0x1b1'))<0x0&&(_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x158e')]+=_0x3fed7e('0x1b1')):_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x158e')]=_0x2f1f5e[_0x3fed7e('0x1db1')]['options'][_0x3fed7e('0x1725')]('U(xcally-mixmonitor-context)',''));if(_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x11f3')]&&_0x2f1f5e[_0x3fed7e('0x1db1')]['appType']===_0x3fed7e('0xbf0')){}else switch((_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x1d75')]||_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x11f3')])['toLowerCase']()){case _0x3fed7e('0x877'):_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x1407')]=_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x60a')]+'='+_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x1c6b')];break;case'custom':break;default:_0x122cb7[0x0]=_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x7ae')],_0x122cb7[0x1]=_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x204a')],_0x122cb7[0x2]=_0x2f1f5e['amazonlex'][_0x3fed7e('0x5ba')],_0x122cb7[0x3]=_0x2f1f5e[_0x3fed7e('0x1db1')]['botname'],_0x122cb7[0x4]=_0x2f1f5e[_0x3fed7e('0x1db1')]['welcomemessage'],_0x2f1f5e[_0x3fed7e('0x1db1')][_0x3fed7e('0x1407')]=_0x122cb7[_0x3fed7e('0x1630')](',');}_0x3d898e(_0x2f1f5e['amazonlex']);}function _0x3d898e(_0x24b193){const _0x3815d7=_0x14e2b2;_0x457cfa[_0x3815d7('0x1715')](_0x24b193);}}const _0x487e46=_0x1703dc;_0x50842f[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x144a'),_0x189033('0x1990'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x50842f(_0x2f79b0,_0x38cbaf,_0x558894,_0xc64d82,_0x715941,_0x46cfba,_0x5218a0,_0x2030f8){const _0x14561c=_0x189033,_0x42fbbe=this;_0x42fbbe[_0x14561c('0x11ed')]=_0x5218a0[_0x14561c('0x20b2')](),_0x42fbbe[_0x14561c('0x17f')]=[],_0x42fbbe['title']=_0x14561c('0x8cb')+(_0xc64d82[_0x14561c('0x11f3')]||_0xc64d82[_0x14561c('0x1d75')])[_0x14561c('0x80')](),_0x42fbbe['autoreply']=angular[_0x14561c('0x1a86')](_0xc64d82),_0x42fbbe['crudPermissions']=_0x2030f8,_0x42fbbe[_0x14561c('0x258d')]={};if(_0x42fbbe['autoreply'][_0x14561c('0x1407')])switch(_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x11f3')]?_0x42fbbe['autoreply'][_0x14561c('0x11f3')][_0x14561c('0x93a')]():_0x42fbbe[_0x14561c('0x2408')]['app'][_0x14561c('0x93a')]()){case'custom':break;case'dialogflow':{const _0x4be90f=_0x42fbbe['autoreply'][_0x14561c('0x1407')][_0x14561c('0x1fc5')](',');_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x1d46')]=_0x4be90f[0x0],_0x42fbbe[_0x14561c('0x2408')]['language']=_0x4be90f[0x1],_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x6d9')]=_0x4be90f[_0x14561c('0x12c8')](0x2,_0x4be90f[_0x14561c('0x1564')])[_0x14561c('0x1630')](',');}break;case _0x14561c('0xd24'):{const _0x415907=_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x1407')][_0x14561c('0x1fc5')](',');_0x42fbbe[_0x14561c('0x2408')]['projectId']=_0x415907[0x0],_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x38')]=_0x415907[0x1],_0x42fbbe[_0x14561c('0x2408')]['privateKey']=_0x415907[0x2],_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x1a1c')]=_0x415907[0x3],_0x42fbbe['autoreply'][_0x14561c('0x6d9')]=_0x415907[_0x14561c('0x12c8')](0x4,_0x415907[_0x14561c('0x1564')])[_0x14561c('0x1630')](',');}break;case _0x14561c('0x1db1'):{const _0x2ade16=_0x42fbbe['autoreply'][_0x14561c('0x1407')][_0x14561c('0x1fc5')](',');_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x7ae')]=_0x2ade16[0x0],_0x42fbbe['autoreply'][_0x14561c('0x204a')]=_0x2ade16[0x1],_0x42fbbe[_0x14561c('0x2408')]['lexregion']=_0x2ade16[0x2],_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x11a9')]=_0x2ade16[0x3],_0x42fbbe['autoreply']['welcomemessage']=_0x2ade16[_0x14561c('0x12c8')](0x4,_0x2ade16[_0x14561c('0x1564')])[_0x14561c('0x1630')](',');}break;case'autoreply':{const _0x87a178=_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x1407')][_0x14561c('0x1fc5')](',');_0x42fbbe['autoreply'][_0x14561c('0x35')]=isNaN(_0x87a178[0x0])?_0x87a178[0x0]:parseInt(_0x87a178[0x0],0xa),_0x42fbbe[_0x14561c('0x2408')]['text']=_0x87a178['slice'](0x1,_0x87a178[_0x14561c('0x1564')])['join'](',');}break;case _0x14561c('0x8c2'):_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x1bcd')]=_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x1407')];break;case'set':_0x42fbbe['autoreply']['name']=_0x42fbbe[_0x14561c('0x2408')]['appdata'][_0x14561c('0x1fc5')]('=')[0x0],_0x42fbbe['autoreply'][_0x14561c('0x1c6b')]=_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x1407')][_0x14561c('0x1fc5')]('=')[0x1];break;case _0x14561c('0x19ae'):_0x42fbbe[_0x14561c('0x2408')]['project']=_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x1407')];break;default:{const _0x1a4a57=_0x42fbbe[_0x14561c('0x2408')]['appdata'][_0x14561c('0x1fc5')](',');_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x35')]=_0x2e3ca0()[_0x14561c('0x173f')](_0x1a4a57[0x0])?_0x1a4a57[0x0]:isNaN(_0x1a4a57[0x0])?_0x1a4a57[0x0]:parseInt(_0x1a4a57[0x0],0xa),_0x42fbbe['autoreply']['text']=_0x2e3ca0()['isEmpty'](_0x1a4a57[0x1])?_0x1a4a57[0x1]:isNaN(_0x1a4a57[0x1])?_0x1a4a57[0x1]:parseInt(_0x1a4a57[0x1],0xa);}break;}else _0x42fbbe['autoreply'][_0x14561c('0x35')]=0x1;_0x42fbbe[_0x14561c('0x2408')]['type']&&_0x42fbbe[_0x14561c('0x2408')]['type'][_0x14561c('0x93a')]()===_0x14561c('0x17cd')&&_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x11f3')][_0x14561c('0x93a')]()===_0x14561c('0x659')&&(_0x42fbbe['autoreply'][_0x14561c('0x24fa')]=_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0xd31')]?_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0xd31')]['split']('$')[0x0]:undefined,_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0xabd')]=_0x42fbbe[_0x14561c('0x2408')][_0x14561c('0x73c')]?_0x14561c('0xac1')+_0x42fbbe[_0x14561c('0x2408')]['callerID']:undefined);_0x42fbbe[_0x14561c('0x1658')]=_0x14b67e,_0x42fbbe[_0x14561c('0xf82')]=_0x34b8fe;function _0x14b67e(){const _0x18c40d=_0x14561c;_0x42fbbe['errors']=[];const _0x1c627f=[];_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0xcf0')]&&_0x42fbbe[_0x18c40d('0x2408')]['type']['toLowerCase']()===_0x18c40d('0x17cd')&&_0x42fbbe['autoreply']['appType']===_0x18c40d('0x4d2')&&(_0x42fbbe['autoreply'][_0x18c40d('0xd31')]=_0x715941['cutdigits']?(_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0x24fa')]||'')+'${EXTEN:'+_0x715941['cutdigits']+'}':(_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0x24fa')]||'')+'${EXTEN}',_0x715941[_0x18c40d('0x75b')]!==_0x18c40d('0x925')?_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0x158e')][_0x18c40d('0x824')]('U(xcally-mixmonitor-context)')<0x0&&(_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0x158e')]+=_0x18c40d('0x1b1')):_0x42fbbe['autoreply'][_0x18c40d('0x158e')]=_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0x158e')]['replace'](_0x18c40d('0x1b1'),''));if(_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0x11f3')]&&_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0x11f3')]===_0x18c40d('0xbf0')){}else switch((_0x42fbbe[_0x18c40d('0x2408')]['app']||_0x42fbbe['autoreply'][_0x18c40d('0x11f3')])[_0x18c40d('0x93a')]()){case'set':_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0x1407')]=_0x42fbbe[_0x18c40d('0x2408')]['name']+'='+_0x42fbbe[_0x18c40d('0x2408')]['value'];break;case _0x18c40d('0xbf0'):break;default:_0x1c627f[0x0]=_0x42fbbe[_0x18c40d('0x2408')]['times'],_0x1c627f[0x1]=_0x42fbbe[_0x18c40d('0x2408')][_0x18c40d('0x1bcd')],_0x42fbbe['autoreply'][_0x18c40d('0x1407')]=_0x1c627f['join'](',');}_0x34b8fe(_0x42fbbe[_0x18c40d('0x2408')]);}function _0x34b8fe(_0x4b96e6){const _0x21781c=_0x14561c;_0x2f79b0[_0x21781c('0x1715')](_0x4b96e6);}}const _0x45bfc5=_0x50842f;_0x438d28[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x144a'),_0x189033('0x1990'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x438d28(_0x55ff39,_0x56fa22,_0x539a84,_0x443bbd,_0x36bd6c,_0x5944a1,_0x54f9f1,_0x45d459){const _0x5703ee=_0x189033,_0xe1de73=this;_0xe1de73[_0x5703ee('0x11ed')]=_0x54f9f1['getCurrentUser'](),_0xe1de73['errors']=[],_0xe1de73['title']=_0x5703ee('0x8cb')+(_0x443bbd[_0x5703ee('0x11f3')]||_0x443bbd[_0x5703ee('0x1d75')])['toUpperCase'](),_0xe1de73[_0x5703ee('0x12b0')]=angular['copy'](_0x443bbd),_0xe1de73[_0x5703ee('0x1134')]=_0x45d459,_0xe1de73[_0x5703ee('0x258d')]={};if(_0xe1de73[_0x5703ee('0x12b0')]['appdata'])switch(_0xe1de73['close']['appType']?_0xe1de73['close'][_0x5703ee('0x11f3')][_0x5703ee('0x93a')]():_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1d75')][_0x5703ee('0x93a')]()){case _0x5703ee('0xbf0'):break;case _0x5703ee('0x205c'):{const _0x4f48d6=_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1407')][_0x5703ee('0x1fc5')](',');_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1d46')]=_0x4f48d6[0x0],_0xe1de73['close'][_0x5703ee('0x1a1c')]=_0x4f48d6[0x1],_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x6d9')]=_0x4f48d6[_0x5703ee('0x12c8')](0x2,_0x4f48d6[_0x5703ee('0x1564')])[_0x5703ee('0x1630')](',');}break;case _0x5703ee('0xd24'):{const _0x4d5e39=_0xe1de73['close']['appdata']['split'](',');_0xe1de73['close']['projectId']=_0x4d5e39[0x0],_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x38')]=_0x4d5e39[0x1],_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x406')]=_0x4d5e39[0x2],_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1a1c')]=_0x4d5e39[0x3],_0xe1de73[_0x5703ee('0x12b0')]['welcomemessage']=_0x4d5e39[_0x5703ee('0x12c8')](0x4,_0x4d5e39[_0x5703ee('0x1564')])['join'](',');}break;case _0x5703ee('0x1db1'):{const _0x3bb465=_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1407')][_0x5703ee('0x1fc5')](',');_0xe1de73[_0x5703ee('0x12b0')]['accesskeyid']=_0x3bb465[0x0],_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x204a')]=_0x3bb465[0x1],_0xe1de73['close'][_0x5703ee('0x5ba')]=_0x3bb465[0x2],_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x11a9')]=_0x3bb465[0x3],_0xe1de73['close']['welcomemessage']=_0x3bb465['slice'](0x4,_0x3bb465[_0x5703ee('0x1564')])['join'](',');}break;case _0x5703ee('0x2408'):{const _0x112a71=_0xe1de73['close'][_0x5703ee('0x1407')][_0x5703ee('0x1fc5')](',');_0xe1de73[_0x5703ee('0x12b0')]['times']=isNaN(_0x112a71[0x0])?_0x112a71[0x0]:parseInt(_0x112a71[0x0],0xa),_0xe1de73['close'][_0x5703ee('0x1bcd')]=_0x112a71['slice'](0x1,_0x112a71[_0x5703ee('0x1564')])[_0x5703ee('0x1630')](',');}break;case _0x5703ee('0x8c2'):_0xe1de73['close'][_0x5703ee('0x1bcd')]=_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1407')];break;case _0x5703ee('0x877'):_0xe1de73['close']['name']=_0xe1de73[_0x5703ee('0x12b0')]['appdata'][_0x5703ee('0x1fc5')]('=')[0x0],_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1c6b')]=_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1407')]['split']('=')[0x1];break;case _0x5703ee('0x19ae'):_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x273a')]=_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1407')];break;default:{const _0x58d7ee=_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x1407')][_0x5703ee('0x1fc5')](',');_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x43f')]=_0x2e3ca0()['isEmpty'](_0x58d7ee[0x0])?_0x58d7ee[0x0]:isNaN(_0x58d7ee[0x0])?_0x58d7ee[0x0]:parseInt(_0x58d7ee[0x0],0xa);}break;}else{}_0xe1de73[_0x5703ee('0x12b0')]['type']&&_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0xcf0')][_0x5703ee('0x93a')]()===_0x5703ee('0x17cd')&&_0xe1de73['close'][_0x5703ee('0x11f3')][_0x5703ee('0x93a')]()===_0x5703ee('0x659')&&(_0xe1de73[_0x5703ee('0x12b0')]['prefix']=_0xe1de73['close'][_0x5703ee('0xd31')]?_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0xd31')]['split']('$')[0x0]:undefined,_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0xabd')]=_0xe1de73[_0x5703ee('0x12b0')][_0x5703ee('0x73c')]?_0x5703ee('0xac1')+_0xe1de73['close'][_0x5703ee('0x73c')]:undefined);_0xe1de73[_0x5703ee('0x1658')]=_0x4af360,_0xe1de73[_0x5703ee('0xf82')]=_0x56a066;function _0x4af360(){const _0x38321a=_0x5703ee;_0xe1de73['errors']=[];const _0x1e277d=[];_0xe1de73['close'][_0x38321a('0xcf0')]&&_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0xcf0')][_0x38321a('0x93a')]()===_0x38321a('0x17cd')&&_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x11f3')]==='outboundDial'&&(_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0xd31')]=_0x36bd6c[_0x38321a('0x145a')]?(_0xe1de73['close'][_0x38321a('0x24fa')]||'')+'${EXTEN:'+_0x36bd6c['cutdigits']+'}':(_0xe1de73[_0x38321a('0x12b0')]['prefix']||'')+'${EXTEN}',_0x36bd6c[_0x38321a('0x75b')]!=='none'?_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x158e')][_0x38321a('0x824')](_0x38321a('0x1b1'))<0x0&&(_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x158e')]+=_0x38321a('0x1b1')):_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x158e')]=_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x158e')][_0x38321a('0x1725')](_0x38321a('0x1b1'),''));if(_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x11f3')]&&_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x11f3')]===_0x38321a('0xbf0')){}else switch((_0xe1de73[_0x38321a('0x12b0')]['app']||_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x11f3')])['toLowerCase']()){case _0x38321a('0x877'):_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x1407')]=_0xe1de73[_0x38321a('0x12b0')]['name']+'='+_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x1c6b')];break;case _0x38321a('0xbf0'):break;default:_0x1e277d[0x0]=_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x43f')],_0xe1de73[_0x38321a('0x12b0')][_0x38321a('0x1407')]=_0x1e277d[_0x38321a('0x1630')](',');}_0x56a066(_0xe1de73[_0x38321a('0x12b0')]);}function _0x56a066(_0x52c818){_0x55ff39['hide'](_0x52c818);}}const _0x30f53a=_0x438d28;_0x31225e[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x144a'),_0x189033('0x1990'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x31225e(_0x1c064f,_0x31d778,_0x26ce0a,_0x5374b6,_0x5f4a4d,_0x1a035d,_0x6e4d1a,_0xe844d){const _0xa8fa99=_0x189033,_0xb32d55=this;_0xb32d55[_0xa8fa99('0x11ed')]=_0x6e4d1a[_0xa8fa99('0x20b2')](),_0xb32d55[_0xa8fa99('0x17f')]=[],_0xb32d55['title']=_0xa8fa99('0x8cb')+(_0x5374b6[_0xa8fa99('0x11f3')]||_0x5374b6[_0xa8fa99('0x1d75')])['toUpperCase'](),_0xb32d55[_0xa8fa99('0x205c')]=angular[_0xa8fa99('0x1a86')](_0x5374b6),_0xb32d55[_0xa8fa99('0x1134')]=_0xe844d,_0xb32d55[_0xa8fa99('0x258d')]={};if(_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x1407')])switch(_0xb32d55[_0xa8fa99('0x205c')]['appType']?_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x11f3')][_0xa8fa99('0x93a')]():_0xb32d55['dialogflow'][_0xa8fa99('0x1d75')][_0xa8fa99('0x93a')]()){case'custom':break;case _0xa8fa99('0x205c'):{const _0x1fb123=_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x1407')]['split'](',');_0xb32d55[_0xa8fa99('0x205c')]['key']=_0x1fb123[0x0],_0xb32d55['dialogflow']['language']=_0x1fb123[0x1],_0xb32d55[_0xa8fa99('0x205c')]['welcomemessage']=_0x1fb123[_0xa8fa99('0x12c8')](0x2,_0x1fb123[_0xa8fa99('0x1564')])[_0xa8fa99('0x1630')](',');}break;case'dialogflowv2':{const _0x56e6ed=_0xb32d55[_0xa8fa99('0x205c')]['appdata']['split'](',');_0xb32d55['dialogflow']['projectId']=_0x56e6ed[0x0],_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x38')]=_0x56e6ed[0x1],_0xb32d55[_0xa8fa99('0x205c')]['privateKey']=_0x56e6ed[0x2],_0xb32d55[_0xa8fa99('0x205c')]['language']=_0x56e6ed[0x3],_0xb32d55[_0xa8fa99('0x205c')]['welcomemessage']=_0x56e6ed[_0xa8fa99('0x12c8')](0x4,_0x56e6ed[_0xa8fa99('0x1564')])['join'](',');}break;case _0xa8fa99('0x1db1'):{const _0x2d474e=_0xb32d55['dialogflow'][_0xa8fa99('0x1407')][_0xa8fa99('0x1fc5')](',');_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x7ae')]=_0x2d474e[0x0],_0xb32d55[_0xa8fa99('0x205c')]['secretaccesskey']=_0x2d474e[0x1],_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x5ba')]=_0x2d474e[0x2],_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x11a9')]=_0x2d474e[0x3],_0xb32d55['dialogflow']['welcomemessage']=_0x2d474e[_0xa8fa99('0x12c8')](0x4,_0x2d474e[_0xa8fa99('0x1564')])[_0xa8fa99('0x1630')](',');}break;case _0xa8fa99('0x2408'):{const _0x575cb4=_0xb32d55['dialogflow'][_0xa8fa99('0x1407')][_0xa8fa99('0x1fc5')](',');_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x35')]=isNaN(_0x575cb4[0x0])?_0x575cb4[0x0]:parseInt(_0x575cb4[0x0],0xa),_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x1bcd')]=_0x575cb4[_0xa8fa99('0x12c8')](0x1,_0x575cb4['length'])[_0xa8fa99('0x1630')](',');}break;case _0xa8fa99('0x8c2'):_0xb32d55[_0xa8fa99('0x205c')]['text']=_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x1407')];break;case _0xa8fa99('0x877'):_0xb32d55[_0xa8fa99('0x205c')]['name']=_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x1407')][_0xa8fa99('0x1fc5')]('=')[0x0],_0xb32d55[_0xa8fa99('0x205c')]['value']=_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x1407')][_0xa8fa99('0x1fc5')]('=')[0x1];break;case _0xa8fa99('0x19ae'):_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x273a')]=_0xb32d55['dialogflow'][_0xa8fa99('0x1407')];break;default:{const _0x4c2a58=_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x1407')]['split'](',');_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x1d46')]=_0x2e3ca0()[_0xa8fa99('0x173f')](_0x4c2a58[0x0])?_0x4c2a58[0x0]:isNaN(_0x4c2a58[0x0])?_0x4c2a58[0x0]:parseInt(_0x4c2a58[0x0],0xa),_0xb32d55['dialogflow'][_0xa8fa99('0x1a1c')]=_0x2e3ca0()['isEmpty'](_0x4c2a58[0x1])?_0x4c2a58[0x1]:isNaN(_0x4c2a58[0x1])?_0x4c2a58[0x1]:parseInt(_0x4c2a58[0x1],0xa),_0xb32d55[_0xa8fa99('0x205c')]['welcomemessage']=_0x2e3ca0()[_0xa8fa99('0x173f')](_0x4c2a58[0x2])?_0x4c2a58[0x2]:isNaN(_0x4c2a58[0x2])?_0x4c2a58[0x2]:parseInt(_0x4c2a58[0x2],0xa);}break;}else _0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x1a1c')]='en';_0xb32d55['dialogflow'][_0xa8fa99('0xcf0')]&&_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0xcf0')][_0xa8fa99('0x93a')]()===_0xa8fa99('0x17cd')&&_0xb32d55['dialogflow'][_0xa8fa99('0x11f3')][_0xa8fa99('0x93a')]()==='outbounddial'&&(_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x24fa')]=_0xb32d55['dialogflow']['phone']?_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0xd31')]['split']('$')[0x0]:undefined,_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0xabd')]=_0xb32d55[_0xa8fa99('0x205c')]['callerID']?_0xa8fa99('0xac1')+_0xb32d55[_0xa8fa99('0x205c')][_0xa8fa99('0x73c')]:undefined);_0xb32d55[_0xa8fa99('0x1658')]=_0x4e11af,_0xb32d55[_0xa8fa99('0xf82')]=_0xf8f0c2;function _0x4e11af(){const _0x118d4e=_0xa8fa99;_0xb32d55['errors']=[];const _0x1c9c63=[];_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0xcf0')]&&_0xb32d55[_0x118d4e('0x205c')]['type'][_0x118d4e('0x93a')]()===_0x118d4e('0x17cd')&&_0xb32d55[_0x118d4e('0x205c')]['appType']===_0x118d4e('0x4d2')&&(_0xb32d55['dialogflow'][_0x118d4e('0xd31')]=_0x5f4a4d[_0x118d4e('0x145a')]?(_0xb32d55[_0x118d4e('0x205c')]['prefix']||'')+_0x118d4e('0x249e')+_0x5f4a4d['cutdigits']+'}':(_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x24fa')]||'')+_0x118d4e('0x20cb'),_0x5f4a4d[_0x118d4e('0x75b')]!==_0x118d4e('0x925')?_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x158e')][_0x118d4e('0x824')](_0x118d4e('0x1b1'))<0x0&&(_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x158e')]+='U(xcally-mixmonitor-context)'):_0xb32d55[_0x118d4e('0x205c')]['options']=_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x158e')][_0x118d4e('0x1725')](_0x118d4e('0x1b1'),''));if(_0xb32d55['dialogflow'][_0x118d4e('0x11f3')]&&_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x11f3')]==='custom'){}else switch((_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x1d75')]||_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x11f3')])[_0x118d4e('0x93a')]()){case _0x118d4e('0x877'):_0xb32d55['dialogflow'][_0x118d4e('0x1407')]=_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x60a')]+'='+_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x1c6b')];break;case _0x118d4e('0xbf0'):break;default:_0x1c9c63[0x0]=_0xb32d55['dialogflow'][_0x118d4e('0x1d46')],_0x1c9c63[0x1]=_0xb32d55['dialogflow'][_0x118d4e('0x1a1c')],_0x1c9c63[0x2]=_0xb32d55[_0x118d4e('0x205c')][_0x118d4e('0x6d9')],_0xb32d55[_0x118d4e('0x205c')]['appdata']=_0x1c9c63[_0x118d4e('0x1630')](',');}_0xf8f0c2(_0xb32d55[_0x118d4e('0x205c')]);}function _0xf8f0c2(_0x1b0b40){_0x1c064f['hide'](_0x1b0b40);}}const _0xb614a=_0x31225e;_0x577c9b['$inject']=['$mdDialog','$q',_0x189033('0x1d70'),_0x189033('0x144a'),_0x189033('0x1990'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x577c9b(_0x21cbb0,_0x556998,_0x38773c,_0x4f8f58,_0x1701b9,_0x271522,_0x1d49a0,_0x4f8375){const _0x3f2a3f=_0x189033,_0x5e900d=this;_0x5e900d['currentUser']=_0x1d49a0[_0x3f2a3f('0x20b2')](),_0x5e900d[_0x3f2a3f('0x17f')]=[],_0x5e900d['title']='WHATSAPP.EDIT_'+(_0x4f8f58[_0x3f2a3f('0x11f3')]||_0x4f8f58[_0x3f2a3f('0x1d75')])[_0x3f2a3f('0x80')](),_0x5e900d['gotoif']=angular[_0x3f2a3f('0x1a86')](_0x4f8f58),_0x5e900d[_0x3f2a3f('0x1134')]=_0x4f8375,_0x5e900d[_0x3f2a3f('0x258d')]={};if(_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1407')])switch(_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x11f3')]?_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x11f3')]['toLowerCase']():_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1d75')]['toLowerCase']()){case'custom':break;case'dialogflow':{const _0x27846f=_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1407')][_0x3f2a3f('0x1fc5')](',');_0x5e900d[_0x3f2a3f('0xc33')]['key']=_0x27846f[0x0],_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1a1c')]=_0x27846f[0x1],_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x6d9')]=_0x27846f[_0x3f2a3f('0x12c8')](0x2,_0x27846f[_0x3f2a3f('0x1564')])[_0x3f2a3f('0x1630')](',');}break;case'dialogflowv2':{const _0x4d7fd7=_0x5e900d['gotoif'][_0x3f2a3f('0x1407')][_0x3f2a3f('0x1fc5')](',');_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x2119')]=_0x4d7fd7[0x0],_0x5e900d['gotoif']['clientEmail']=_0x4d7fd7[0x1],_0x5e900d['gotoif'][_0x3f2a3f('0x406')]=_0x4d7fd7[0x2],_0x5e900d['gotoif'][_0x3f2a3f('0x1a1c')]=_0x4d7fd7[0x3],_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x6d9')]=_0x4d7fd7['slice'](0x4,_0x4d7fd7[_0x3f2a3f('0x1564')])[_0x3f2a3f('0x1630')](',');}break;case _0x3f2a3f('0x1db1'):{const _0x1d9a70=_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1407')][_0x3f2a3f('0x1fc5')](',');_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x7ae')]=_0x1d9a70[0x0],_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x204a')]=_0x1d9a70[0x1],_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x5ba')]=_0x1d9a70[0x2],_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x11a9')]=_0x1d9a70[0x3],_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x6d9')]=_0x1d9a70[_0x3f2a3f('0x12c8')](0x4,_0x1d9a70['length'])['join'](',');}break;case'autoreply':{const _0x1613de=_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1407')][_0x3f2a3f('0x1fc5')](',');_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x35')]=isNaN(_0x1613de[0x0])?_0x1613de[0x0]:parseInt(_0x1613de[0x0],0xa),_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1bcd')]=_0x1613de['slice'](0x1,_0x1613de[_0x3f2a3f('0x1564')])[_0x3f2a3f('0x1630')](',');}break;case _0x3f2a3f('0x8c2'):_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1bcd')]=_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1407')];break;case _0x3f2a3f('0x877'):_0x5e900d[_0x3f2a3f('0xc33')]['name']=_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1407')]['split']('=')[0x0],_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1c6b')]=_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1407')][_0x3f2a3f('0x1fc5')]('=')[0x1];break;case _0x3f2a3f('0x19ae'):_0x5e900d['gotoif'][_0x3f2a3f('0x273a')]=_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1407')];break;default:{const _0x23df6a=_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1407')][_0x3f2a3f('0x1fc5')](',');_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x168e')]=_0x2e3ca0()[_0x3f2a3f('0x173f')](_0x23df6a[0x0])?_0x23df6a[0x0]:isNaN(_0x23df6a[0x0])?_0x23df6a[0x0]:parseInt(_0x23df6a[0x0],0xa),_0x5e900d['gotoif'][_0x3f2a3f('0x27e5')]=_0x2e3ca0()[_0x3f2a3f('0x173f')](_0x23df6a[0x1])?_0x23df6a[0x1]:isNaN(_0x23df6a[0x1])?_0x23df6a[0x1]:parseInt(_0x23df6a[0x1],0xa),_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x1813')]=_0x2e3ca0()[_0x3f2a3f('0x173f')](_0x23df6a[0x2])?_0x23df6a[0x2]:isNaN(_0x23df6a[0x2])?_0x23df6a[0x2]:parseInt(_0x23df6a[0x2],0xa);}break;}else{}_0x5e900d['gotoif'][_0x3f2a3f('0xcf0')]&&_0x5e900d[_0x3f2a3f('0xc33')]['type'][_0x3f2a3f('0x93a')]()===_0x3f2a3f('0x17cd')&&_0x5e900d[_0x3f2a3f('0xc33')]['appType'][_0x3f2a3f('0x93a')]()===_0x3f2a3f('0x659')&&(_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0x24fa')]=_0x5e900d[_0x3f2a3f('0xc33')]['phone']?_0x5e900d[_0x3f2a3f('0xc33')][_0x3f2a3f('0xd31')]['split']('$')[0x0]:undefined,_0x5e900d['gotoif'][_0x3f2a3f('0xabd')]=_0x5e900d[_0x3f2a3f('0xc33')]['callerID']?'CALLERID(all)='+_0x5e900d[_0x3f2a3f('0xc33')]['callerID']:undefined);_0x5e900d[_0x3f2a3f('0x1658')]=_0x28bf5f,_0x5e900d[_0x3f2a3f('0xf82')]=_0xdeb8a5;function _0x28bf5f(){const _0x14d3f0=_0x3f2a3f;_0x5e900d[_0x14d3f0('0x17f')]=[];const _0x308a9e=[];_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0xcf0')]&&_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0xcf0')][_0x14d3f0('0x93a')]()==='outbound'&&_0x5e900d[_0x14d3f0('0xc33')]['appType']==='outboundDial'&&(_0x5e900d['gotoif'][_0x14d3f0('0xd31')]=_0x1701b9[_0x14d3f0('0x145a')]?(_0x5e900d[_0x14d3f0('0xc33')]['prefix']||'')+_0x14d3f0('0x249e')+_0x1701b9['cutdigits']+'}':(_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0x24fa')]||'')+'${EXTEN}',_0x1701b9['recordingFormat']!=='none'?_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0x158e')][_0x14d3f0('0x824')](_0x14d3f0('0x1b1'))<0x0&&(_0x5e900d['gotoif'][_0x14d3f0('0x158e')]+=_0x14d3f0('0x1b1')):_0x5e900d['gotoif'][_0x14d3f0('0x158e')]=_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0x158e')][_0x14d3f0('0x1725')](_0x14d3f0('0x1b1'),''));if(_0x5e900d['gotoif'][_0x14d3f0('0x11f3')]&&_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0x11f3')]===_0x14d3f0('0xbf0')){}else switch((_0x5e900d['gotoif'][_0x14d3f0('0x1d75')]||_0x5e900d['gotoif'][_0x14d3f0('0x11f3')])[_0x14d3f0('0x93a')]()){case _0x14d3f0('0x877'):_0x5e900d['gotoif'][_0x14d3f0('0x1407')]=_0x5e900d[_0x14d3f0('0xc33')]['name']+'='+_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0x1c6b')];break;case _0x14d3f0('0xbf0'):break;default:_0x308a9e[0x0]=_0x5e900d[_0x14d3f0('0xc33')]['condition'],_0x308a9e[0x1]=_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0x27e5')],_0x308a9e[0x2]=_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0x1813')],_0x5e900d[_0x14d3f0('0xc33')][_0x14d3f0('0x1407')]=_0x308a9e[_0x14d3f0('0x1630')](',');}_0xdeb8a5(_0x5e900d[_0x14d3f0('0xc33')]);}function _0xdeb8a5(_0x5cfe02){_0x21cbb0['hide'](_0x5cfe02);}}const _0x2d3662=_0x577c9b;_0x661d95['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),'whatsappAccountApp','whatsappAccount',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x661d95(_0x158e67,_0xde90f9,_0x325650,_0x423555,_0x4d812b,_0x144aa6,_0x18d6cf,_0x578fcd){const _0x3d700c=_0x189033,_0x3879a0=this;_0x3879a0[_0x3d700c('0x11ed')]=_0x18d6cf[_0x3d700c('0x20b2')](),_0x3879a0[_0x3d700c('0x17f')]=[],_0x3879a0[_0x3d700c('0xf28')]=_0x3d700c('0x8cb')+(_0x423555['appType']||_0x423555[_0x3d700c('0x1d75')])[_0x3d700c('0x80')](),_0x3879a0[_0x3d700c('0x1da0')]=angular[_0x3d700c('0x1a86')](_0x423555),_0x3879a0[_0x3d700c('0x1134')]=_0x578fcd,_0x3879a0[_0x3d700c('0x258d')]={};if(_0x3879a0[_0x3d700c('0x1da0')]['appdata'])switch(_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x11f3')]?_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x11f3')]['toLowerCase']():_0x3879a0['gotop'][_0x3d700c('0x1d75')][_0x3d700c('0x93a')]()){case _0x3d700c('0xbf0'):break;case _0x3d700c('0x205c'):{const _0x449beb=_0x3879a0['gotop'][_0x3d700c('0x1407')]['split'](',');_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x1d46')]=_0x449beb[0x0],_0x3879a0['gotop'][_0x3d700c('0x1a1c')]=_0x449beb[0x1],_0x3879a0[_0x3d700c('0x1da0')]['welcomemessage']=_0x449beb[_0x3d700c('0x12c8')](0x2,_0x449beb['length'])[_0x3d700c('0x1630')](',');}break;case _0x3d700c('0xd24'):{const _0x1f3594=_0x3879a0['gotop'][_0x3d700c('0x1407')][_0x3d700c('0x1fc5')](',');_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x2119')]=_0x1f3594[0x0],_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x38')]=_0x1f3594[0x1],_0x3879a0[_0x3d700c('0x1da0')]['privateKey']=_0x1f3594[0x2],_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x1a1c')]=_0x1f3594[0x3],_0x3879a0['gotop']['welcomemessage']=_0x1f3594[_0x3d700c('0x12c8')](0x4,_0x1f3594[_0x3d700c('0x1564')])['join'](',');}break;case _0x3d700c('0x1db1'):{const _0x25cee0=_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x1407')][_0x3d700c('0x1fc5')](',');_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x7ae')]=_0x25cee0[0x0],_0x3879a0['gotop'][_0x3d700c('0x204a')]=_0x25cee0[0x1],_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x5ba')]=_0x25cee0[0x2],_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x11a9')]=_0x25cee0[0x3],_0x3879a0[_0x3d700c('0x1da0')]['welcomemessage']=_0x25cee0[_0x3d700c('0x12c8')](0x4,_0x25cee0['length'])[_0x3d700c('0x1630')](',');}break;case _0x3d700c('0x2408'):{const _0x412254=_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x1407')][_0x3d700c('0x1fc5')](',');_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x35')]=isNaN(_0x412254[0x0])?_0x412254[0x0]:parseInt(_0x412254[0x0],0xa),_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x1bcd')]=_0x412254[_0x3d700c('0x12c8')](0x1,_0x412254[_0x3d700c('0x1564')])['join'](',');}break;case _0x3d700c('0x8c2'):_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x1bcd')]=_0x3879a0['gotop'][_0x3d700c('0x1407')];break;case _0x3d700c('0x877'):_0x3879a0['gotop'][_0x3d700c('0x60a')]=_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x1407')]['split']('=')[0x0],_0x3879a0['gotop']['value']=_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x1407')][_0x3d700c('0x1fc5')]('=')[0x1];break;case _0x3d700c('0x19ae'):_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x273a')]=_0x3879a0[_0x3d700c('0x1da0')]['appdata'];break;default:{const _0xd3622d=_0x3879a0['gotop']['appdata']['split'](',');_0x3879a0['gotop'][_0x3d700c('0xe1e')]=_0x2e3ca0()[_0x3d700c('0x173f')](_0xd3622d[0x0])?_0xd3622d[0x0]:isNaN(_0xd3622d[0x0])?_0xd3622d[0x0]:parseInt(_0xd3622d[0x0],0xa);}break;}else{}_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0xcf0')]&&_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0xcf0')]['toLowerCase']()===_0x3d700c('0x17cd')&&_0x3879a0[_0x3d700c('0x1da0')]['appType'][_0x3d700c('0x93a')]()===_0x3d700c('0x659')&&(_0x3879a0[_0x3d700c('0x1da0')]['prefix']=_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0xd31')]?_0x3879a0['gotop']['phone'][_0x3d700c('0x1fc5')]('$')[0x0]:undefined,_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0xabd')]=_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x73c')]?_0x3d700c('0xac1')+_0x3879a0[_0x3d700c('0x1da0')][_0x3d700c('0x73c')]:undefined);_0x3879a0['saveWhatsappAccountApp']=_0x3c63e4,_0x3879a0[_0x3d700c('0xf82')]=_0x4badae;function _0x3c63e4(){const _0x3044a0=_0x3d700c;_0x3879a0['errors']=[];const _0xfea007=[];_0x3879a0['gotop'][_0x3044a0('0xcf0')]&&_0x3879a0['gotop'][_0x3044a0('0xcf0')]['toLowerCase']()===_0x3044a0('0x17cd')&&_0x3879a0['gotop']['appType']===_0x3044a0('0x4d2')&&(_0x3879a0[_0x3044a0('0x1da0')]['phone']=_0x4d812b[_0x3044a0('0x145a')]?(_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x24fa')]||'')+_0x3044a0('0x249e')+_0x4d812b[_0x3044a0('0x145a')]+'}':(_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x24fa')]||'')+'${EXTEN}',_0x4d812b[_0x3044a0('0x75b')]!=='none'?_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x158e')]['indexOf'](_0x3044a0('0x1b1'))<0x0&&(_0x3879a0['gotop'][_0x3044a0('0x158e')]+=_0x3044a0('0x1b1')):_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x158e')]=_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x158e')][_0x3044a0('0x1725')](_0x3044a0('0x1b1'),''));if(_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x11f3')]&&_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x11f3')]==='custom'){}else switch((_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x1d75')]||_0x3879a0['gotop'][_0x3044a0('0x11f3')])['toLowerCase']()){case _0x3044a0('0x877'):_0x3879a0['gotop'][_0x3044a0('0x1407')]=_0x3879a0[_0x3044a0('0x1da0')]['name']+'='+_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x1c6b')];break;case _0x3044a0('0xbf0'):break;default:_0xfea007[0x0]=_0x3879a0[_0x3044a0('0x1da0')]['priority'],_0x3879a0[_0x3044a0('0x1da0')][_0x3044a0('0x1407')]=_0xfea007[_0x3044a0('0x1630')](',');}_0x4badae(_0x3879a0[_0x3044a0('0x1da0')]);}function _0x4badae(_0x4b9f5e){const _0x2f45b7=_0x3d700c;_0x158e67[_0x2f45b7('0x1715')](_0x4b9f5e);}}const _0x4e7272=_0x661d95;_0x1f8d36[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0x1e48'),_0x189033('0xb33'),_0x189033('0x844'),'interval',_0x189033('0xe98'),'toasty',_0x189033('0x56b'),'Auth',_0x189033('0x1134')];function _0x1f8d36(_0xeab5f0,_0x13f09a,_0x4b085d,_0x1ffb2b,_0x4844e3,_0xf54df4,_0x18876e,_0xa15fcd,_0x407c9e,_0xb0e5b1){const _0x5c26e0=_0x189033,_0x5f2016=this;_0x5f2016[_0x5c26e0('0x11ed')]=_0x407c9e[_0x5c26e0('0x20b2')](),_0x5f2016[_0x5c26e0('0x17f')]=[],_0x5f2016['title']='TOOLS.EDIT_INTERVAL',_0x5f2016[_0x5c26e0('0x115c')]=angular[_0x5c26e0('0x1a86')](_0x4844e3),_0x5f2016[_0x5c26e0('0xe98')]=_0xf54df4,_0x5f2016[_0x5c26e0('0x1470')]=![],_0x5f2016[_0x5c26e0('0x1de1')]=[_0x5c26e0('0x10af'),_0x5c26e0('0xbf0'),_0x5c26e0('0x2335')],_0x5f2016[_0x5c26e0('0x1134')]=_0xb0e5b1,_0x5f2016[_0x5c26e0('0x167a')]=_0x1ffb2b['getDaysOfWeek'](),_0x5f2016[_0x5c26e0('0x1dfd')]=_0x1ffb2b[_0x5c26e0('0x222e')](),_0x5f2016[_0x5c26e0('0x1e32')]=_0x1ffb2b[_0x5c26e0('0x1fe4')](),_0x5f2016[_0x5c26e0('0x13ce')]=_0x1ffb2b[_0x5c26e0('0x181b')]();if(!_0x5f2016[_0x5c26e0('0x115c')])_0x5f2016[_0x5c26e0('0x115c')]={'interval':'*,*,*,*'},_0x5f2016[_0x5c26e0('0xcf0')]=_0x5c26e0('0x10af'),_0x5f2016[_0x5c26e0('0xf28')]=_0x5c26e0('0x1e94'),_0x5f2016['newInterval']=!![];else{if(_0x5f2016[_0x5c26e0('0x115c')][_0x5c26e0('0x115c')]!==_0x5c26e0('0x1b54')){_0x5f2016[_0x5c26e0('0xcf0')]=_0x5c26e0('0xbf0');const _0xebc9b1=_0x5f2016[_0x5c26e0('0x115c')]['interval'][_0x5c26e0('0x1fc5')](','),_0x7dbaa6=_0xebc9b1[0x0],_0x18b1e4=_0xebc9b1[0x1],_0x3e800b=_0xebc9b1[0x2],_0x3eaea8=_0xebc9b1[0x3];if(_0x7dbaa6!=='*'){const _0xb0194b=_0x7dbaa6[_0x5c26e0('0x1fc5')]('-')[0x0],_0x5173b8=_0x7dbaa6['split']('-')[0x1];let _0x36d647;_0x36d647=new Date(),_0x36d647['setHours'](Number(_0xb0194b[_0x5c26e0('0x1fc5')](':')[0x0])),_0x36d647[_0x5c26e0('0x1fb7')](Number(_0xb0194b[_0x5c26e0('0x1fc5')](':')[0x1])),_0x5f2016[_0x5c26e0('0xc32')]=_0x36d647,_0x36d647=new Date(),_0x36d647['setHours'](Number(_0x5173b8['split'](':')[0x0])),_0x36d647[_0x5c26e0('0x1fb7')](Number(_0x5173b8[_0x5c26e0('0x1fc5')](':')[0x1])),_0x5f2016['timeRangeTo']=_0x36d647;}_0x18b1e4!=='*'&&(_0x5f2016[_0x5c26e0('0x232d')]=_0x18b1e4['split']('-')[0x0],_0x5f2016[_0x5c26e0('0x1269')]=_0x18b1e4['split']('-')[0x1]),_0x3e800b!=='*'&&(_0x5f2016[_0x5c26e0('0xf13')]=_0x3e800b[_0x5c26e0('0x1fc5')]('-')[0x0],_0x5f2016[_0x5c26e0('0xfe5')]=_0x3e800b['split']('-')[0x1]),_0x3eaea8!=='*'&&(_0x5f2016[_0x5c26e0('0x1690')]=_0x3eaea8['split']('-')[0x0],_0x5f2016[_0x5c26e0('0x1f12')]=_0x3eaea8[_0x5c26e0('0x1fc5')]('-')[0x1]);}else _0x5f2016[_0x5c26e0('0xcf0')]=_0x5c26e0('0x10af');}_0xeab5f0[_0x5c26e0('0x7f2')]['id']&&!_0x5f2016['interval']['application']&&(_0x5f2016[_0x5c26e0('0x115c')][_0x5c26e0('0x5ae')]=_0xeab5f0[_0x5c26e0('0x7f2')]['id']);_0x5f2016[_0x5c26e0('0x115c')]['IntervalId']&&_0x5f2016['interval']['application']&&(_0x5f2016[_0x5c26e0('0xcf0')]=_0x5c26e0('0x2335'));_0x5f2016[_0x5c26e0('0x1a4d')]=_0xe47ff1,_0x5f2016[_0x5c26e0('0x1807')]=_0x2f2e5c,_0x5f2016[_0x5c26e0('0xf82')]=_0x449a37;_0x5f2016['interval'][_0x5c26e0('0x121e')]&&(_0x407c9e[_0x5c26e0('0xca1')]('admin')?_0xa15fcd['interval'][_0x5c26e0('0x1e6e')]({'fields':_0x5c26e0('0x1e24'),'IntervalId':_0x5c26e0('0x13c'),'nolimit':!![]})[_0x5c26e0('0xe53')][_0x5c26e0('0x683')](function(_0x3afc9e){const _0x3376d7=_0x5c26e0;_0x5f2016['intervals']=_0x3afc9e[_0x3376d7('0xf5d')]||[];})[_0x5c26e0('0x130a')](function(_0x13894f){const _0x4a6075=_0x5c26e0;_0x18876e[_0x4a6075('0x52a')]({'title':_0x13894f[_0x4a6075('0x13ee')]?_0x4a6075('0x2168')+_0x13894f[_0x4a6075('0x13ee')]+'\x20-\x20'+_0x13894f[_0x4a6075('0x24a9')]:'SYSTEM:GET_INTERVALS','msg':_0x13894f[_0x4a6075('0x5a5')]?JSON['stringify'](_0x13894f[_0x4a6075('0x5a5')]):_0x13894f[_0x4a6075('0x1ff0')]()});}):_0xa15fcd[_0x5c26e0('0x115c')][_0x5c26e0('0x1e6e')]({'fields':_0x5c26e0('0x1e24'),'IntervalId':_0x5c26e0('0x13c'),'nolimit':!![]})[_0x5c26e0('0xe53')][_0x5c26e0('0x683')](function(_0x59d416){_0x5f2016['intervals']=_0x59d416['rows']||[];})[_0x5c26e0('0x683')](function(){const _0x445573=_0x5c26e0;return _0xa15fcd[_0x445573('0x22df')]['get']({'userProfileId':_0x5f2016[_0x445573('0x11ed')][_0x445573('0x2f')],'sectionId':0x3ec})['$promise'];})[_0x5c26e0('0x683')](function(_0x4c117a){const _0x5f07c3=_0x5c26e0,_0x28e419=_0x4c117a&&_0x4c117a[_0x5f07c3('0xf5d')]?_0x4c117a[_0x5f07c3('0xf5d')][0x0]:null;if(!_0x28e419)_0x5f2016['intervals']=[];else{if(!_0x28e419[_0x5f07c3('0x170')])return _0xa15fcd[_0x5f07c3('0xcf7')][_0x5f07c3('0x1e6e')]({'sectionId':_0x28e419['id']})[_0x5f07c3('0xe53')][_0x5f07c3('0x683')](function(_0x3f9ee0){const _0x3ba1ab=_0x5f07c3,_0x1b30ef=_0x3f9ee0&&_0x3f9ee0[_0x3ba1ab('0xf5d')]?_0x3f9ee0['rows']:[],_0x3c3282=[];let _0x3381ca=null;_0x5f2016[_0x3ba1ab('0x115c')]&&(_0x3381ca=_0x2e3ca0()['find'](_0x5f2016['intervals'],{'name':_0x5f2016[_0x3ba1ab('0x115c')][_0x3ba1ab('0x5ae')]})),_0x3381ca&&!_0x2e3ca0()[_0x3ba1ab('0x7a2')](_0x1b30ef,[_0x3ba1ab('0x832'),_0x3381ca['id']])&&_0x5f2016['intervals'][_0x3ba1ab('0x1299')](function(_0x40bd2a){const _0x21c6fd=_0x3ba1ab;_0x40bd2a['id']===_0x3381ca['id']&&(_0x40bd2a[_0x21c6fd('0x319')]=![],_0x3c3282[_0x21c6fd('0x1fd0')](_0x40bd2a));}),_0x5f2016['intervals']=_0x3c3282;});}})[_0x5c26e0('0x130a')](function(_0x290ec4){const _0x3d803f=_0x5c26e0;_0x18876e[_0x3d803f('0x52a')]({'title':_0x290ec4['status']?_0x3d803f('0x2168')+_0x290ec4[_0x3d803f('0x13ee')]+_0x3d803f('0xbf6')+_0x290ec4['statusText']:_0x3d803f('0x1e65'),'msg':_0x290ec4[_0x3d803f('0x5a5')]?JSON[_0x3d803f('0x258a')](_0x290ec4['data']):_0x290ec4[_0x3d803f('0x1ff0')]()});}));function _0x33a5d6(){const _0x535b9a=_0x5c26e0;switch(_0x5f2016[_0x535b9a('0xcf0')]){case _0x535b9a('0x10af'):case'list':return _0x535b9a('0x1b54');case'custom':{const _0x5217de=[];if(_0x5f2016[_0x535b9a('0xc32')]!=='*'&&_0x5f2016[_0x535b9a('0xc32')]&&_0x5f2016['timeRangeTo']){const _0x1fecf5=(_0x5f2016[_0x535b9a('0xc32')]['getHours']()<0xa?'0':'')+_0x5f2016[_0x535b9a('0xc32')][_0x535b9a('0x2575')]()+':'+((_0x5f2016[_0x535b9a('0xc32')][_0x535b9a('0x1b5b')]()<0xa?'0':'')+_0x5f2016[_0x535b9a('0xc32')][_0x535b9a('0x1b5b')]()),_0x88a8b5=(_0x5f2016[_0x535b9a('0xaa0')][_0x535b9a('0x2575')]()<0xa?'0':'')+_0x5f2016['timeRangeTo'][_0x535b9a('0x2575')]()+':'+((_0x5f2016[_0x535b9a('0xaa0')][_0x535b9a('0x1b5b')]()<0xa?'0':'')+_0x5f2016['timeRangeTo']['getMinutes']());_0x5217de[_0x535b9a('0x1fd0')](_0x1fecf5+'-'+_0x88a8b5);}else _0x5217de['push']('*');return _0x5f2016[_0x535b9a('0x232d')]?_0x5f2016[_0x535b9a('0x1269')]?_0x5217de[_0x535b9a('0x1fd0')](_0x5f2016[_0x535b9a('0x232d')]+'-'+_0x5f2016['dayOfWeekTo']):_0x5217de[_0x535b9a('0x1fd0')](_0x5f2016[_0x535b9a('0x232d')]):_0x5217de[_0x535b9a('0x1fd0')]('*'),_0x5f2016[_0x535b9a('0xf13')]?_0x5f2016[_0x535b9a('0xfe5')]?_0x5217de[_0x535b9a('0x1fd0')](_0x5f2016[_0x535b9a('0xf13')]+'-'+_0x5f2016['monthDayTo']):_0x5217de[_0x535b9a('0x1fd0')](_0x5f2016['monthDayFrom']):_0x5217de['push']('*'),_0x5f2016[_0x535b9a('0x1690')]?_0x5f2016[_0x535b9a('0x1f12')]?_0x5217de['push'](_0x5f2016[_0x535b9a('0x1690')]+'-'+_0x5f2016[_0x535b9a('0x1f12')]):_0x5217de[_0x535b9a('0x1fd0')](_0x5f2016[_0x535b9a('0x1690')]):_0x5217de['push']('*'),_0x5217de[_0x535b9a('0x1630')]();}}}function _0xe47ff1(){const _0x2b5f72=_0x5c26e0;_0x5f2016['errors']=[],_0x5f2016[_0x2b5f72('0x115c')]['interval']=_0x33a5d6(),_0xa15fcd[_0x2b5f72('0x115c')][_0x2b5f72('0xb0a')](_0x5f2016[_0x2b5f72('0x115c')])[_0x2b5f72('0xe53')][_0x2b5f72('0x683')](function(_0x5e465f){const _0xde8f24=_0x2b5f72;_0x5f2016[_0xde8f24('0xe98')][_0xde8f24('0x1fd0')](_0x5e465f),_0x18876e[_0xde8f24('0x53')]({'title':_0xde8f24('0x24b5'),'msg':_0x5f2016[_0xde8f24('0x115c')]['name']?_0x5f2016['interval'][_0xde8f24('0x60a')]+_0xde8f24('0x14b5'):''}),_0x449a37();})['catch'](function(_0x501fec){const _0x4dac71=_0x2b5f72;console[_0x4dac71('0x52a')](_0x501fec),_0x5f2016[_0x4dac71('0x17f')]=_0x501fec['data'][_0x4dac71('0x17f')]||[{'message':_0x501fec[_0x4dac71('0x1ff0')](),'type':_0x4dac71('0x1d24')}];});}function _0x2f2e5c(){const _0xa620ff=_0x5c26e0;_0x5f2016['errors']=[],_0x5f2016[_0xa620ff('0x115c')]['interval']=_0x33a5d6(),_0x5f2016[_0xa620ff('0x115c')]['application']?(_0x5f2016[_0xa620ff('0xcf0')]!==_0xa620ff('0x2335')&&(_0x5f2016[_0xa620ff('0x115c')][_0xa620ff('0x5ae')]=null),_0x449a37(_0x5f2016['interval'])):_0xa15fcd[_0xa620ff('0x115c')][_0xa620ff('0x2480')]({'id':_0x5f2016[_0xa620ff('0x115c')]['id']},_0x5f2016[_0xa620ff('0x115c')])[_0xa620ff('0xe53')]['then'](function(_0x28f962){const _0x5896a7=_0xa620ff,_0x47e1eb=_0x2e3ca0()['find'](_0x5f2016['intervals'],{'id':_0x28f962['id']});_0x47e1eb&&_0x2e3ca0()[_0x5896a7('0xf22')](_0x47e1eb,_0x28f962),_0x18876e[_0x5896a7('0x53')]({'title':_0x5896a7('0x18c3'),'msg':_0x5896a7('0x224')}),_0x449a37();})[_0xa620ff('0x130a')](function(_0x37bbf3){const _0x3644f7=_0xa620ff;console['error'](_0x37bbf3),_0x5f2016[_0x3644f7('0x17f')]=_0x37bbf3['data']['errors']||[{'message':_0x37bbf3[_0x3644f7('0x1ff0')](),'type':'api.interval.update'}];});}function _0x449a37(_0x55db8a){const _0x350fbb=_0x5c26e0;_0x13f09a[_0x350fbb('0x1715')](_0x55db8a);}}const _0x12c4ee=_0x1f8d36;_0x147cb3[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q','toasty',_0x189033('0x144a'),_0x189033('0x1990'),'api',_0x189033('0xba1'),'crudPermissions'];function _0x147cb3(_0x2064d6,_0x373018,_0x172b4e,_0x45ebf6,_0x47ec48,_0x1d6872,_0x1851fe,_0x340590){const _0xedd34f=_0x189033,_0x57a32d=this;_0x57a32d[_0xedd34f('0x11ed')]=_0x1851fe[_0xedd34f('0x20b2')](),_0x57a32d[_0xedd34f('0x17f')]=[],_0x57a32d[_0xedd34f('0xf28')]=_0xedd34f('0x8cb')+(_0x45ebf6[_0xedd34f('0x11f3')]||_0x45ebf6[_0xedd34f('0x1d75')])['toUpperCase'](),_0x57a32d[_0xedd34f('0x1126')]=angular[_0xedd34f('0x1a86')](_0x45ebf6),_0x57a32d['crudPermissions']=_0x340590,_0x57a32d[_0xedd34f('0x258d')]={};if(_0x57a32d['noop'][_0xedd34f('0x1407')])switch(_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x11f3')]?_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x11f3')][_0xedd34f('0x93a')]():_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1d75')][_0xedd34f('0x93a')]()){case'custom':break;case'dialogflow':{const _0x1014c8=_0x57a32d[_0xedd34f('0x1126')]['appdata'][_0xedd34f('0x1fc5')](',');_0x57a32d['noop'][_0xedd34f('0x1d46')]=_0x1014c8[0x0],_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1a1c')]=_0x1014c8[0x1],_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x6d9')]=_0x1014c8[_0xedd34f('0x12c8')](0x2,_0x1014c8[_0xedd34f('0x1564')])[_0xedd34f('0x1630')](',');}break;case _0xedd34f('0xd24'):{const _0x66cce6=_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1407')][_0xedd34f('0x1fc5')](',');_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x2119')]=_0x66cce6[0x0],_0x57a32d['noop'][_0xedd34f('0x38')]=_0x66cce6[0x1],_0x57a32d['noop'][_0xedd34f('0x406')]=_0x66cce6[0x2],_0x57a32d[_0xedd34f('0x1126')]['language']=_0x66cce6[0x3],_0x57a32d['noop'][_0xedd34f('0x6d9')]=_0x66cce6[_0xedd34f('0x12c8')](0x4,_0x66cce6['length'])[_0xedd34f('0x1630')](',');}break;case _0xedd34f('0x1db1'):{const _0x135106=_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1407')][_0xedd34f('0x1fc5')](',');_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x7ae')]=_0x135106[0x0],_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x204a')]=_0x135106[0x1],_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x5ba')]=_0x135106[0x2],_0x57a32d[_0xedd34f('0x1126')]['botname']=_0x135106[0x3],_0x57a32d[_0xedd34f('0x1126')]['welcomemessage']=_0x135106[_0xedd34f('0x12c8')](0x4,_0x135106[_0xedd34f('0x1564')])[_0xedd34f('0x1630')](',');}break;case _0xedd34f('0x2408'):{const _0x522472=_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1407')][_0xedd34f('0x1fc5')](',');_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x35')]=isNaN(_0x522472[0x0])?_0x522472[0x0]:parseInt(_0x522472[0x0],0xa),_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1bcd')]=_0x522472[_0xedd34f('0x12c8')](0x1,_0x522472[_0xedd34f('0x1564')])[_0xedd34f('0x1630')](',');}break;case _0xedd34f('0x8c2'):_0x57a32d[_0xedd34f('0x1126')]['text']=_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1407')];break;case _0xedd34f('0x877'):_0x57a32d[_0xedd34f('0x1126')]['name']=_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1407')]['split']('=')[0x0],_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1c6b')]=_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1407')][_0xedd34f('0x1fc5')]('=')[0x1];break;case'agi':_0x57a32d['noop'][_0xedd34f('0x273a')]=_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0x1407')];break;default:{const _0x5947d4=_0x57a32d[_0xedd34f('0x1126')]['appdata'][_0xedd34f('0x1fc5')](',');_0x57a32d['noop'][_0xedd34f('0x1c6b')]=_0x2e3ca0()[_0xedd34f('0x173f')](_0x5947d4[0x0])?_0x5947d4[0x0]:isNaN(_0x5947d4[0x0])?_0x5947d4[0x0]:parseInt(_0x5947d4[0x0],0xa);}break;}else{}_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0xcf0')]&&_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0xcf0')][_0xedd34f('0x93a')]()==='outbound'&&_0x57a32d['noop'][_0xedd34f('0x11f3')]['toLowerCase']()===_0xedd34f('0x659')&&(_0x57a32d[_0xedd34f('0x1126')]['prefix']=_0x57a32d['noop'][_0xedd34f('0xd31')]?_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0xd31')]['split']('$')[0x0]:undefined,_0x57a32d[_0xedd34f('0x1126')][_0xedd34f('0xabd')]=_0x57a32d['noop'][_0xedd34f('0x73c')]?_0xedd34f('0xac1')+_0x57a32d[_0xedd34f('0x1126')]['callerID']:undefined);_0x57a32d[_0xedd34f('0x1658')]=_0x3978f8,_0x57a32d['closeDialog']=_0xd2de12;function _0x3978f8(){const _0x13980b=_0xedd34f;_0x57a32d['errors']=[];const _0x17fd57=[];_0x57a32d[_0x13980b('0x1126')][_0x13980b('0xcf0')]&&_0x57a32d[_0x13980b('0x1126')][_0x13980b('0xcf0')][_0x13980b('0x93a')]()===_0x13980b('0x17cd')&&_0x57a32d['noop'][_0x13980b('0x11f3')]===_0x13980b('0x4d2')&&(_0x57a32d[_0x13980b('0x1126')]['phone']=_0x47ec48[_0x13980b('0x145a')]?(_0x57a32d[_0x13980b('0x1126')]['prefix']||'')+_0x13980b('0x249e')+_0x47ec48[_0x13980b('0x145a')]+'}':(_0x57a32d[_0x13980b('0x1126')][_0x13980b('0x24fa')]||'')+_0x13980b('0x20cb'),_0x47ec48[_0x13980b('0x75b')]!==_0x13980b('0x925')?_0x57a32d[_0x13980b('0x1126')][_0x13980b('0x158e')]['indexOf'](_0x13980b('0x1b1'))<0x0&&(_0x57a32d[_0x13980b('0x1126')]['options']+='U(xcally-mixmonitor-context)'):_0x57a32d['noop']['options']=_0x57a32d[_0x13980b('0x1126')][_0x13980b('0x158e')][_0x13980b('0x1725')](_0x13980b('0x1b1'),''));if(_0x57a32d['noop'][_0x13980b('0x11f3')]&&_0x57a32d[_0x13980b('0x1126')][_0x13980b('0x11f3')]===_0x13980b('0xbf0')){}else switch((_0x57a32d['noop'][_0x13980b('0x1d75')]||_0x57a32d[_0x13980b('0x1126')][_0x13980b('0x11f3')])['toLowerCase']()){case _0x13980b('0x877'):_0x57a32d[_0x13980b('0x1126')][_0x13980b('0x1407')]=_0x57a32d['noop'][_0x13980b('0x60a')]+'='+_0x57a32d['noop'][_0x13980b('0x1c6b')];break;case _0x13980b('0xbf0'):break;default:_0x17fd57[0x0]=_0x57a32d['noop'][_0x13980b('0x1c6b')],_0x57a32d[_0x13980b('0x1126')][_0x13980b('0x1407')]=_0x17fd57[_0x13980b('0x1630')](',');}_0xd2de12(_0x57a32d[_0x13980b('0x1126')]);}function _0xd2de12(_0x4a6a5b){const _0xd7de17=_0xedd34f;_0x2064d6[_0xd7de17('0x1715')](_0x4a6a5b);}}const _0x3debc4=_0x147cb3;_0x2f6b66['$inject']=['$mdDialog','$q',_0x189033('0x1d70'),'whatsappAccountApp',_0x189033('0x1990'),'api',_0x189033('0xba1'),_0x189033('0x1134')];function _0x2f6b66(_0x1b4e77,_0xe1f9e1,_0x4654f6,_0x358c59,_0x2b6ddc,_0x5b7342,_0x183b64,_0x5476be){const _0x43ca07=_0x189033,_0x1acdbb=this;_0x1acdbb[_0x43ca07('0x11ed')]=_0x183b64['getCurrentUser'](),_0x1acdbb[_0x43ca07('0x17f')]=[],_0x1acdbb[_0x43ca07('0xf28')]=_0x43ca07('0x8cb')+(_0x358c59[_0x43ca07('0x11f3')]||_0x358c59['app'])[_0x43ca07('0x80')](),_0x1acdbb[_0x43ca07('0x660')]=angular[_0x43ca07('0x1a86')](_0x358c59),_0x1acdbb['crudPermissions']=_0x5476be,_0x1acdbb['hasModulePermissions']={};if(_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1407')])switch(_0x1acdbb['queue'][_0x43ca07('0x11f3')]?_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x11f3')]['toLowerCase']():_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1d75')][_0x43ca07('0x93a')]()){case _0x43ca07('0xbf0'):break;case'dialogflow':{const _0x4c3c5a=_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1407')][_0x43ca07('0x1fc5')](',');_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1d46')]=_0x4c3c5a[0x0],_0x1acdbb['queue'][_0x43ca07('0x1a1c')]=_0x4c3c5a[0x1],_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x6d9')]=_0x4c3c5a[_0x43ca07('0x12c8')](0x2,_0x4c3c5a['length'])['join'](',');}break;case _0x43ca07('0xd24'):{const _0x5f2333=_0x1acdbb['queue']['appdata'][_0x43ca07('0x1fc5')](',');_0x1acdbb['queue'][_0x43ca07('0x2119')]=_0x5f2333[0x0],_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x38')]=_0x5f2333[0x1],_0x1acdbb[_0x43ca07('0x660')]['privateKey']=_0x5f2333[0x2],_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1a1c')]=_0x5f2333[0x3],_0x1acdbb[_0x43ca07('0x660')]['welcomemessage']=_0x5f2333[_0x43ca07('0x12c8')](0x4,_0x5f2333[_0x43ca07('0x1564')])[_0x43ca07('0x1630')](',');}break;case _0x43ca07('0x1db1'):{const _0x460c6b=_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1407')][_0x43ca07('0x1fc5')](',');_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x7ae')]=_0x460c6b[0x0],_0x1acdbb[_0x43ca07('0x660')]['secretaccesskey']=_0x460c6b[0x1],_0x1acdbb['queue'][_0x43ca07('0x5ba')]=_0x460c6b[0x2],_0x1acdbb['queue'][_0x43ca07('0x11a9')]=_0x460c6b[0x3],_0x1acdbb[_0x43ca07('0x660')]['welcomemessage']=_0x460c6b[_0x43ca07('0x12c8')](0x4,_0x460c6b[_0x43ca07('0x1564')])['join'](',');}break;case'autoreply':{const _0x48b81a=_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1407')][_0x43ca07('0x1fc5')](',');_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x35')]=isNaN(_0x48b81a[0x0])?_0x48b81a[0x0]:parseInt(_0x48b81a[0x0],0xa),_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1bcd')]=_0x48b81a['slice'](0x1,_0x48b81a[_0x43ca07('0x1564')])[_0x43ca07('0x1630')](',');}break;case _0x43ca07('0x8c2'):_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1bcd')]=_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1407')];break;case _0x43ca07('0x877'):_0x1acdbb[_0x43ca07('0x660')]['name']=_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1407')][_0x43ca07('0x1fc5')]('=')[0x0],_0x1acdbb[_0x43ca07('0x660')]['value']=_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1407')]['split']('=')[0x1];break;case _0x43ca07('0x19ae'):_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x273a')]=_0x1acdbb['queue'][_0x43ca07('0x1407')];break;default:{const _0x5470b2=_0x1acdbb[_0x43ca07('0x660')]['appdata'][_0x43ca07('0x1fc5')](',');_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x660')]=_0x2e3ca0()[_0x43ca07('0x173f')](_0x5470b2[0x0])?_0x5470b2[0x0]:isNaN(_0x5470b2[0x0])?_0x5470b2[0x0]:parseInt(_0x5470b2[0x0],0xa),_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1668')]=_0x2e3ca0()[_0x43ca07('0x173f')](_0x5470b2[0x1])?_0x5470b2[0x1]:isNaN(_0x5470b2[0x1])?_0x5470b2[0x1]:parseInt(_0x5470b2[0x1],0xa);}break;}else _0x1acdbb[_0x43ca07('0x660')]['queue']=0x12c,_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x1668')]=0x12c;_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0xcf0')]&&_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0xcf0')][_0x43ca07('0x93a')]()==='outbound'&&_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x11f3')][_0x43ca07('0x93a')]()===_0x43ca07('0x659')&&(_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x24fa')]=_0x1acdbb['queue'][_0x43ca07('0xd31')]?_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0xd31')]['split']('$')[0x0]:undefined,_0x1acdbb[_0x43ca07('0x660')]['callerId']=_0x1acdbb[_0x43ca07('0x660')][_0x43ca07('0x73c')]?_0x43ca07('0xac1')+_0x1acdbb[_0x43ca07('0x660')]['callerID']:undefined);_0x1acdbb[_0x43ca07('0x1658')]=_0x26b174,_0x1acdbb[_0x43ca07('0xf82')]=_0x5c6860,_0x183b64[_0x43ca07('0xca1')](_0x43ca07('0x20c2'))?_0x5b7342['whatsappQueue']['get']({'fields':'id,name,type','sort':_0x43ca07('0x60a'),'nolimit':'true'})['$promise'][_0x43ca07('0x683')](function(_0x3aa56b){const _0x39b26b=_0x43ca07;_0x1acdbb['queues']=_0x3aa56b[_0x39b26b('0xf5d')]||[];})['catch'](function(_0x26725c){const _0x164253=_0x43ca07;_0x4654f6[_0x164253('0x52a')]({'title':_0x26725c[_0x164253('0x13ee')]?'API:'+_0x26725c[_0x164253('0x13ee')]+_0x164253('0xbf6')+_0x26725c[_0x164253('0x24a9')]:_0x164253('0x22dc'),'msg':_0x26725c[_0x164253('0x5a5')]?JSON[_0x164253('0x258a')](_0x26725c[_0x164253('0x5a5')]):_0x26725c['toString']()});}):_0x5b7342['whatsappQueue'][_0x43ca07('0x1e6e')]({'fields':_0x43ca07('0x2035'),'sort':_0x43ca07('0x60a'),'nolimit':_0x43ca07('0x26ac')})[_0x43ca07('0xe53')][_0x43ca07('0x683')](function(_0x4f4852){const _0x3ec196=_0x43ca07;_0x1acdbb[_0x3ec196('0x2da')]=_0x4f4852[_0x3ec196('0xf5d')]||[];})[_0x43ca07('0x683')](function(){const _0x370be5=_0x43ca07;return _0x5b7342[_0x370be5('0x22df')][_0x370be5('0x1e6e')]({'userProfileId':_0x1acdbb[_0x370be5('0x11ed')][_0x370be5('0x2f')],'sectionId':0x836})[_0x370be5('0xe53')];})['then'](function(_0x13b59a){const _0x294838=_0x43ca07,_0x4b55ae=_0x13b59a&&_0x13b59a[_0x294838('0xf5d')]?_0x13b59a[_0x294838('0xf5d')][0x0]:null;if(!_0x4b55ae){const _0xa212cc=[];let _0x1bd79b=null;_0x1acdbb[_0x294838('0x660')]&&(_0x1bd79b=_0x2e3ca0()[_0x294838('0x1c07')](_0x1acdbb[_0x294838('0x2da')],{'name':_0x1acdbb[_0x294838('0x660')]['queue']}));for(let _0x149902=0x0;_0x149902<_0x1acdbb[_0x294838('0x2da')]['length'];_0x149902++){_0x1bd79b&&_0x1acdbb[_0x294838('0x2da')][_0x149902]['id']===_0x1bd79b['id']&&(_0x1acdbb[_0x294838('0x2da')][_0x149902][_0x294838('0x319')]=![],_0xa212cc[_0x294838('0x1fd0')](_0x1acdbb[_0x294838('0x2da')][_0x149902]));}_0x1acdbb[_0x294838('0x2da')]=_0xa212cc;}else{if(!_0x4b55ae[_0x294838('0x170')])return _0x5b7342[_0x294838('0xcf7')][_0x294838('0x1e6e')]({'sectionId':_0x4b55ae['id']})[_0x294838('0xe53')][_0x294838('0x683')](function(_0x50426c){const _0x1408e8=_0x294838,_0x230dfe=_0x2e3ca0()['map'](_0x50426c['rows'],function(_0x34cc82){const _0xb75cdb=a0_0x4e0a;return _0x2e3ca0()[_0xb75cdb('0x1c07')](_0x1acdbb[_0xb75cdb('0x2da')],{'id':_0x34cc82[_0xb75cdb('0x832')]});});let _0x44c272=null;_0x1acdbb[_0x1408e8('0x660')]&&(_0x44c272=_0x2e3ca0()[_0x1408e8('0x1c07')](_0x1acdbb[_0x1408e8('0x2da')],{'name':_0x1acdbb[_0x1408e8('0x660')][_0x1408e8('0x660')]}));if(_0x44c272&&!_0x2e3ca0()[_0x1408e8('0x7a2')](_0x230dfe,['id',_0x44c272['id']])){const _0x5d2cf9=_0x2e3ca0()[_0x1408e8('0x1c07')](_0x1acdbb[_0x1408e8('0x2da')],{'id':_0x44c272['id']});_0x5d2cf9['canSelect']=![],_0x230dfe['push'](_0x5d2cf9);}_0x1acdbb['queues']=_0x230dfe;});}})['catch'](function(_0x21717a){const _0x304a4a=_0x43ca07;_0x4654f6[_0x304a4a('0x52a')]({'title':_0x21717a['status']?'API:'+_0x21717a['status']+_0x304a4a('0xbf6')+_0x21717a[_0x304a4a('0x24a9')]:_0x304a4a('0x934'),'msg':_0x21717a['data']?JSON['stringify'](_0x21717a['data']):_0x21717a[_0x304a4a('0x1ff0')]()});});function _0x26b174(){const _0x422751=_0x43ca07;_0x1acdbb[_0x422751('0x17f')]=[];const _0x420ce5=[];_0x1acdbb[_0x422751('0x660')][_0x422751('0xcf0')]&&_0x1acdbb[_0x422751('0x660')][_0x422751('0xcf0')][_0x422751('0x93a')]()===_0x422751('0x17cd')&&_0x1acdbb['queue'][_0x422751('0x11f3')]===_0x422751('0x4d2')&&(_0x1acdbb[_0x422751('0x660')][_0x422751('0xd31')]=_0x2b6ddc['cutdigits']?(_0x1acdbb['queue']['prefix']||'')+_0x422751('0x249e')+_0x2b6ddc[_0x422751('0x145a')]+'}':(_0x1acdbb['queue'][_0x422751('0x24fa')]||'')+_0x422751('0x20cb'),_0x2b6ddc[_0x422751('0x75b')]!==_0x422751('0x925')?_0x1acdbb['queue'][_0x422751('0x158e')][_0x422751('0x824')](_0x422751('0x1b1'))<0x0&&(_0x1acdbb[_0x422751('0x660')]['options']+=_0x422751('0x1b1')):_0x1acdbb[_0x422751('0x660')]['options']=_0x1acdbb[_0x422751('0x660')][_0x422751('0x158e')]['replace'](_0x422751('0x1b1'),''));const _0x58f46d=_0x2e3ca0()[_0x422751('0x1c07')](_0x1acdbb[_0x422751('0x2da')],{'name':_0x1acdbb['queue'][_0x422751('0x660')]});_0x58f46d&&(_0x1acdbb[_0x422751('0x660')][_0x2e3ca0()[_0x422751('0x21ab')](_0x422751('0x16e7'))+_0x422751('0xd4')]=_0x58f46d['id']);if(_0x1acdbb[_0x422751('0x660')][_0x422751('0x11f3')]&&_0x1acdbb['queue'][_0x422751('0x11f3')]===_0x422751('0xbf0')){}else switch((_0x1acdbb[_0x422751('0x660')]['app']||_0x1acdbb['queue'][_0x422751('0x11f3')])['toLowerCase']()){case _0x422751('0x877'):_0x1acdbb[_0x422751('0x660')]['appdata']=_0x1acdbb['queue'][_0x422751('0x60a')]+'='+_0x1acdbb[_0x422751('0x660')][_0x422751('0x1c6b')];break;case _0x422751('0xbf0'):break;default:_0x420ce5[0x0]=_0x1acdbb[_0x422751('0x660')]['queue'],_0x420ce5[0x1]=_0x1acdbb['queue'][_0x422751('0x1668')],_0x1acdbb[_0x422751('0x660')][_0x422751('0x1407')]=_0x420ce5[_0x422751('0x1630')](',');}_0x5c6860(_0x1acdbb[_0x422751('0x660')]);}function _0x5c6860(_0x31d350){const _0x32bf55=_0x43ca07;_0x1b4e77[_0x32bf55('0x1715')](_0x31d350);}}const _0x5d973e=_0x2f6b66;_0x1dc42d['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x144a'),_0x189033('0x1990'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x1dc42d(_0xcdbb16,_0x14b28f,_0x50d65f,_0x445de4,_0x46944c,_0x54f8a6,_0x4ddbd8,_0x19ca5f){const _0x1ca26e=_0x189033,_0x1f0f28=this;_0x1f0f28[_0x1ca26e('0x11ed')]=_0x4ddbd8['getCurrentUser'](),_0x1f0f28[_0x1ca26e('0x17f')]=[],_0x1f0f28[_0x1ca26e('0xf28')]=_0x1ca26e('0x8cb')+(_0x445de4[_0x1ca26e('0x11f3')]||_0x445de4[_0x1ca26e('0x1d75')])[_0x1ca26e('0x80')](),_0x1f0f28[_0x1ca26e('0x24f2')]=angular[_0x1ca26e('0x1a86')](_0x445de4),_0x1f0f28[_0x1ca26e('0x1134')]=_0x19ca5f,_0x1f0f28[_0x1ca26e('0x258d')]={};if(_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1407')])switch(_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x11f3')]?_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x11f3')][_0x1ca26e('0x93a')]():_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1d75')][_0x1ca26e('0x93a')]()){case _0x1ca26e('0xbf0'):break;case'dialogflow':{const _0x2baa8b=_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1407')]['split'](',');_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1d46')]=_0x2baa8b[0x0],_0x1f0f28[_0x1ca26e('0x24f2')]['language']=_0x2baa8b[0x1],_0x1f0f28[_0x1ca26e('0x24f2')]['welcomemessage']=_0x2baa8b[_0x1ca26e('0x12c8')](0x2,_0x2baa8b[_0x1ca26e('0x1564')])[_0x1ca26e('0x1630')](',');}break;case _0x1ca26e('0xd24'):{const _0x58351b=_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1407')][_0x1ca26e('0x1fc5')](',');_0x1f0f28['system'][_0x1ca26e('0x2119')]=_0x58351b[0x0],_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x38')]=_0x58351b[0x1],_0x1f0f28['system']['privateKey']=_0x58351b[0x2],_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1a1c')]=_0x58351b[0x3],_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x6d9')]=_0x58351b['slice'](0x4,_0x58351b[_0x1ca26e('0x1564')])[_0x1ca26e('0x1630')](',');}break;case _0x1ca26e('0x1db1'):{const _0x516d8f=_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1407')][_0x1ca26e('0x1fc5')](',');_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x7ae')]=_0x516d8f[0x0],_0x1f0f28['system']['secretaccesskey']=_0x516d8f[0x1],_0x1f0f28[_0x1ca26e('0x24f2')]['lexregion']=_0x516d8f[0x2],_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x11a9')]=_0x516d8f[0x3],_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x6d9')]=_0x516d8f[_0x1ca26e('0x12c8')](0x4,_0x516d8f['length'])['join'](',');}break;case _0x1ca26e('0x2408'):{const _0x5ab62e=_0x1f0f28['system']['appdata'][_0x1ca26e('0x1fc5')](',');_0x1f0f28['system'][_0x1ca26e('0x35')]=isNaN(_0x5ab62e[0x0])?_0x5ab62e[0x0]:parseInt(_0x5ab62e[0x0],0xa),_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1bcd')]=_0x5ab62e[_0x1ca26e('0x12c8')](0x1,_0x5ab62e[_0x1ca26e('0x1564')])[_0x1ca26e('0x1630')](',');}break;case'message':_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1bcd')]=_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1407')];break;case _0x1ca26e('0x877'):_0x1f0f28['system'][_0x1ca26e('0x60a')]=_0x1f0f28[_0x1ca26e('0x24f2')]['appdata'][_0x1ca26e('0x1fc5')]('=')[0x0],_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1c6b')]=_0x1f0f28[_0x1ca26e('0x24f2')]['appdata']['split']('=')[0x1];break;case'agi':_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x273a')]=_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1407')];break;default:{const _0x55530c=_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x1407')][_0x1ca26e('0x1fc5')](',');_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x6db')]=_0x2e3ca0()[_0x1ca26e('0x173f')](_0x55530c[0x0])?_0x55530c[0x0]:isNaN(_0x55530c[0x0])?_0x55530c[0x0]:parseInt(_0x55530c[0x0],0xa),_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x26e0')]=_0x2e3ca0()[_0x1ca26e('0x173f')](_0x55530c[0x1])?_0x55530c[0x1]:isNaN(_0x55530c[0x1])?_0x55530c[0x1]:parseInt(_0x55530c[0x1],0xa);}break;}else _0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x26e0')]='';_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0xcf0')]&&_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0xcf0')][_0x1ca26e('0x93a')]()==='outbound'&&_0x1f0f28[_0x1ca26e('0x24f2')]['appType'][_0x1ca26e('0x93a')]()==='outbounddial'&&(_0x1f0f28[_0x1ca26e('0x24f2')]['prefix']=_0x1f0f28['system'][_0x1ca26e('0xd31')]?_0x1f0f28['system'][_0x1ca26e('0xd31')][_0x1ca26e('0x1fc5')]('$')[0x0]:undefined,_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0xabd')]=_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x73c')]?_0x1ca26e('0xac1')+_0x1f0f28[_0x1ca26e('0x24f2')][_0x1ca26e('0x73c')]:undefined);_0x1f0f28['saveWhatsappAccountApp']=_0x299d61,_0x1f0f28[_0x1ca26e('0xf82')]=_0x21846d,_0x4ddbd8[_0x1ca26e('0xca1')](_0x1ca26e('0x20c2'))?_0x54f8a6['variable'][_0x1ca26e('0x1e6e')]({'fields':_0x1ca26e('0xa10'),'sort':_0x1ca26e('0x60a'),'nolimit':_0x1ca26e('0x26ac')})[_0x1ca26e('0xe53')][_0x1ca26e('0x683')](function(_0x166c9c){const _0x356ad1=_0x1ca26e;_0x1f0f28[_0x356ad1('0x220b')]=_0x166c9c['rows']||[];})[_0x1ca26e('0x130a')](function(_0x3bb6b5){const _0x4a3db1=_0x1ca26e;_0x50d65f['error']({'title':_0x3bb6b5[_0x4a3db1('0x13ee')]?'API:'+_0x3bb6b5[_0x4a3db1('0x13ee')]+_0x4a3db1('0xbf6')+_0x3bb6b5['statusText']:_0x4a3db1('0x9a9'),'msg':_0x3bb6b5[_0x4a3db1('0x5a5')]?JSON[_0x4a3db1('0x258a')](_0x3bb6b5[_0x4a3db1('0x5a5')]):_0x3bb6b5[_0x4a3db1('0x1ff0')]()});}):_0x54f8a6[_0x1ca26e('0x26e0')][_0x1ca26e('0x1e6e')]({'fields':_0x1ca26e('0xa10'),'sort':_0x1ca26e('0x60a'),'nolimit':_0x1ca26e('0x26ac')})[_0x1ca26e('0xe53')]['then'](function(_0x106573){const _0xdfb769=_0x1ca26e;_0x1f0f28[_0xdfb769('0x220b')]=_0x106573[_0xdfb769('0xf5d')]||[];})['then'](function(){const _0x1e2e6a=_0x1ca26e;return _0x54f8a6[_0x1e2e6a('0x22df')]['get']({'userProfileId':_0x1f0f28[_0x1e2e6a('0x11ed')][_0x1e2e6a('0x2f')],'sectionId':0x3f4})['$promise'];})['then'](function(_0x1a8205){const _0xbb4f06=_0x1ca26e,_0xff5c66=_0x1a8205&&_0x1a8205[_0xbb4f06('0xf5d')]?_0x1a8205[_0xbb4f06('0xf5d')][0x0]:null;if(!_0xff5c66){const _0x5bd8d5=[];let _0xc03f23=null;_0x1f0f28['system']&&(_0xc03f23=_0x2e3ca0()[_0xbb4f06('0x1c07')](_0x1f0f28[_0xbb4f06('0x220b')],{'name':_0x1f0f28['system'][_0xbb4f06('0x26e0')]}));for(let _0x56ace7=0x0;_0x56ace7<_0x1f0f28['variables'][_0xbb4f06('0x1564')];_0x56ace7++){_0xc03f23&&_0x1f0f28[_0xbb4f06('0x220b')][_0x56ace7]['id']===_0xc03f23['id']&&(_0x1f0f28[_0xbb4f06('0x220b')][_0x56ace7][_0xbb4f06('0x319')]=![],_0x5bd8d5[_0xbb4f06('0x1fd0')](_0x1f0f28[_0xbb4f06('0x220b')][_0x56ace7]));}_0x1f0f28[_0xbb4f06('0x220b')]=_0x5bd8d5;}else{if(!_0xff5c66['autoAssociation'])return _0x54f8a6[_0xbb4f06('0xcf7')][_0xbb4f06('0x1e6e')]({'sectionId':_0xff5c66['id']})[_0xbb4f06('0xe53')][_0xbb4f06('0x683')](function(_0x475c43){const _0x30e0e2=_0xbb4f06,_0xba4019=_0x2e3ca0()[_0x30e0e2('0x386')](_0x475c43['rows'],function(_0x546344){const _0x179178=_0x30e0e2;return _0x2e3ca0()[_0x179178('0x1c07')](_0x1f0f28[_0x179178('0x220b')],{'id':_0x546344[_0x179178('0x832')]});});let _0x38b409=null;_0x1f0f28[_0x30e0e2('0x24f2')]&&(_0x38b409=_0x2e3ca0()[_0x30e0e2('0x1c07')](_0x1f0f28[_0x30e0e2('0x220b')],{'name':_0x1f0f28['system'][_0x30e0e2('0x26e0')]}));if(_0x38b409&&!_0x2e3ca0()[_0x30e0e2('0x7a2')](_0xba4019,['id',_0x38b409['id']])){const _0x38b913=_0x2e3ca0()[_0x30e0e2('0x1c07')](_0x1f0f28[_0x30e0e2('0x220b')],{'id':_0x38b409['id']});_0x38b913[_0x30e0e2('0x319')]=![],_0xba4019[_0x30e0e2('0x1fd0')](_0x38b913);}_0x1f0f28[_0x30e0e2('0x220b')]=_0xba4019;});}})[_0x1ca26e('0x130a')](function(_0x2f3e95){const _0x127240=_0x1ca26e;_0x50d65f[_0x127240('0x52a')]({'title':_0x2f3e95[_0x127240('0x13ee')]?_0x127240('0x2168')+_0x2f3e95[_0x127240('0x13ee')]+_0x127240('0xbf6')+_0x2f3e95[_0x127240('0x24a9')]:_0x127240('0x392'),'msg':_0x2f3e95[_0x127240('0x5a5')]?JSON[_0x127240('0x258a')](_0x2f3e95[_0x127240('0x5a5')]):_0x2f3e95['toString']()});});function _0x299d61(){const _0x5d0abc=_0x1ca26e;_0x1f0f28['errors']=[];const _0x110115=[];_0x1f0f28[_0x5d0abc('0x24f2')]['type']&&_0x1f0f28[_0x5d0abc('0x24f2')][_0x5d0abc('0xcf0')]['toLowerCase']()===_0x5d0abc('0x17cd')&&_0x1f0f28[_0x5d0abc('0x24f2')][_0x5d0abc('0x11f3')]==='outboundDial'&&(_0x1f0f28['system']['phone']=_0x46944c[_0x5d0abc('0x145a')]?(_0x1f0f28[_0x5d0abc('0x24f2')][_0x5d0abc('0x24fa')]||'')+_0x5d0abc('0x249e')+_0x46944c[_0x5d0abc('0x145a')]+'}':(_0x1f0f28['system']['prefix']||'')+'${EXTEN}',_0x46944c[_0x5d0abc('0x75b')]!==_0x5d0abc('0x925')?_0x1f0f28['system'][_0x5d0abc('0x158e')][_0x5d0abc('0x824')](_0x5d0abc('0x1b1'))<0x0&&(_0x1f0f28[_0x5d0abc('0x24f2')]['options']+='U(xcally-mixmonitor-context)'):_0x1f0f28[_0x5d0abc('0x24f2')]['options']=_0x1f0f28[_0x5d0abc('0x24f2')][_0x5d0abc('0x158e')][_0x5d0abc('0x1725')](_0x5d0abc('0x1b1'),''));if(_0x1f0f28[_0x5d0abc('0x24f2')]['appType']&&_0x1f0f28['system'][_0x5d0abc('0x11f3')]===_0x5d0abc('0xbf0')){}else switch((_0x1f0f28['system'][_0x5d0abc('0x1d75')]||_0x1f0f28['system'][_0x5d0abc('0x11f3')])[_0x5d0abc('0x93a')]()){case'set':_0x1f0f28[_0x5d0abc('0x24f2')][_0x5d0abc('0x1407')]=_0x1f0f28[_0x5d0abc('0x24f2')]['name']+'='+_0x1f0f28['system'][_0x5d0abc('0x1c6b')];break;case'custom':break;default:_0x110115[0x0]=_0x1f0f28['system']['command'],_0x110115[0x1]=_0x1f0f28[_0x5d0abc('0x24f2')][_0x5d0abc('0x26e0')],_0x1f0f28[_0x5d0abc('0x24f2')][_0x5d0abc('0x1407')]=_0x110115[_0x5d0abc('0x1630')](',');}_0x21846d(_0x1f0f28['system']);}function _0x21846d(_0x228414){_0xcdbb16['hide'](_0x228414);}}const _0x544c5b=_0x1dc42d;_0x47b02a['$inject']=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x144a'),'whatsappAccount',_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0x1134')];function _0x47b02a(_0x9273d7,_0x1f9efc,_0x9432dd,_0xbfa2f1,_0x181a43,_0x2cd35f,_0x31bae2,_0x3cda6c){const _0x48e5a0=_0x189033,_0x2c6d61=this;_0x2c6d61[_0x48e5a0('0x11ed')]=_0x31bae2[_0x48e5a0('0x20b2')](),_0x2c6d61[_0x48e5a0('0x17f')]=[],_0x2c6d61[_0x48e5a0('0xf28')]=_0x48e5a0('0x8cb')+(_0xbfa2f1[_0x48e5a0('0x11f3')]||_0xbfa2f1[_0x48e5a0('0x1d75')])['toUpperCase'](),_0x2c6d61[_0x48e5a0('0x270')]=angular[_0x48e5a0('0x1a86')](_0xbfa2f1),_0x2c6d61[_0x48e5a0('0x1134')]=_0x3cda6c,_0x2c6d61['hasModulePermissions']={};if(_0x2c6d61[_0x48e5a0('0x270')]['appdata'])switch(_0x2c6d61['tag']['appType']?_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x11f3')][_0x48e5a0('0x93a')]():_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1d75')][_0x48e5a0('0x93a')]()){case _0x48e5a0('0xbf0'):break;case _0x48e5a0('0x205c'):{const _0x2290a7=_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1407')][_0x48e5a0('0x1fc5')](',');_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1d46')]=_0x2290a7[0x0],_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1a1c')]=_0x2290a7[0x1],_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x6d9')]=_0x2290a7[_0x48e5a0('0x12c8')](0x2,_0x2290a7[_0x48e5a0('0x1564')])['join'](',');}break;case _0x48e5a0('0xd24'):{const _0x1a1707=_0x2c6d61[_0x48e5a0('0x270')]['appdata'][_0x48e5a0('0x1fc5')](',');_0x2c6d61['tag'][_0x48e5a0('0x2119')]=_0x1a1707[0x0],_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x38')]=_0x1a1707[0x1],_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x406')]=_0x1a1707[0x2],_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1a1c')]=_0x1a1707[0x3],_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x6d9')]=_0x1a1707['slice'](0x4,_0x1a1707[_0x48e5a0('0x1564')])[_0x48e5a0('0x1630')](',');}break;case _0x48e5a0('0x1db1'):{const _0x2d1ebd=_0x2c6d61[_0x48e5a0('0x270')]['appdata'][_0x48e5a0('0x1fc5')](',');_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x7ae')]=_0x2d1ebd[0x0],_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x204a')]=_0x2d1ebd[0x1],_0x2c6d61[_0x48e5a0('0x270')]['lexregion']=_0x2d1ebd[0x2],_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x11a9')]=_0x2d1ebd[0x3],_0x2c6d61['tag'][_0x48e5a0('0x6d9')]=_0x2d1ebd[_0x48e5a0('0x12c8')](0x4,_0x2d1ebd[_0x48e5a0('0x1564')])[_0x48e5a0('0x1630')](',');}break;case _0x48e5a0('0x2408'):{const _0x265b6b=_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1407')][_0x48e5a0('0x1fc5')](',');_0x2c6d61[_0x48e5a0('0x270')]['times']=isNaN(_0x265b6b[0x0])?_0x265b6b[0x0]:parseInt(_0x265b6b[0x0],0xa),_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1bcd')]=_0x265b6b[_0x48e5a0('0x12c8')](0x1,_0x265b6b[_0x48e5a0('0x1564')])[_0x48e5a0('0x1630')](',');}break;case _0x48e5a0('0x8c2'):_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1bcd')]=_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1407')];break;case _0x48e5a0('0x877'):_0x2c6d61['tag'][_0x48e5a0('0x60a')]=_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1407')][_0x48e5a0('0x1fc5')]('=')[0x0],_0x2c6d61['tag'][_0x48e5a0('0x1c6b')]=_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1407')][_0x48e5a0('0x1fc5')]('=')[0x1];break;case _0x48e5a0('0x19ae'):_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x273a')]=_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1407')];break;default:{const _0x311061=_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x1407')][_0x48e5a0('0x1fc5')](',');_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x270')]=_0x2e3ca0()[_0x48e5a0('0x173f')](_0x311061[0x0])?_0x311061[0x0]:isNaN(_0x311061[0x0])?_0x311061[0x0]:parseInt(_0x311061[0x0],0xa);}break;}else{}_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0xcf0')]&&_0x2c6d61[_0x48e5a0('0x270')]['type'][_0x48e5a0('0x93a')]()===_0x48e5a0('0x17cd')&&_0x2c6d61[_0x48e5a0('0x270')]['appType']['toLowerCase']()===_0x48e5a0('0x659')&&(_0x2c6d61['tag'][_0x48e5a0('0x24fa')]=_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0xd31')]?_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0xd31')][_0x48e5a0('0x1fc5')]('$')[0x0]:undefined,_0x2c6d61['tag'][_0x48e5a0('0xabd')]=_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x73c')]?_0x48e5a0('0xac1')+_0x2c6d61[_0x48e5a0('0x270')][_0x48e5a0('0x73c')]:undefined);_0x2c6d61['saveWhatsappAccountApp']=_0x23c693,_0x2c6d61[_0x48e5a0('0xf82')]=_0x2f05ff,_0x31bae2[_0x48e5a0('0xca1')](_0x48e5a0('0x20c2'))?_0x2cd35f['tag'][_0x48e5a0('0x1e6e')]({'fields':_0x48e5a0('0xa10'),'sort':'name','nolimit':_0x48e5a0('0x26ac')})['$promise'][_0x48e5a0('0x683')](function(_0x1d9212){const _0x54ac4f=_0x48e5a0;_0x2c6d61[_0x54ac4f('0x1ce6')]=_0x1d9212[_0x54ac4f('0xf5d')]||[];})[_0x48e5a0('0x130a')](function(_0x3cae9d){const _0x130731=_0x48e5a0;_0x9432dd[_0x130731('0x52a')]({'title':_0x3cae9d['status']?'API:'+_0x3cae9d[_0x130731('0x13ee')]+'\x20-\x20'+_0x3cae9d[_0x130731('0x24a9')]:'SYSTEM:GET_TAGS','msg':_0x3cae9d[_0x130731('0x5a5')]?JSON[_0x130731('0x258a')](_0x3cae9d[_0x130731('0x5a5')]):_0x3cae9d[_0x130731('0x1ff0')]()});}):_0x2cd35f[_0x48e5a0('0x270')][_0x48e5a0('0x1e6e')]({'fields':_0x48e5a0('0xa10'),'sort':'name','nolimit':'true'})[_0x48e5a0('0xe53')]['then'](function(_0x389aed){const _0x2450a9=_0x48e5a0;_0x2c6d61[_0x2450a9('0x1ce6')]=_0x389aed[_0x2450a9('0xf5d')]||[];})[_0x48e5a0('0x683')](function(){const _0x468b74=_0x48e5a0;return _0x2cd35f['userProfileSection'][_0x468b74('0x1e6e')]({'userProfileId':_0x2c6d61[_0x468b74('0x11ed')][_0x468b74('0x2f')],'sectionId':0x3f0})['$promise'];})['then'](function(_0x329273){const _0x4ec999=_0x48e5a0,_0x529564=_0x329273&&_0x329273[_0x4ec999('0xf5d')]?_0x329273[_0x4ec999('0xf5d')][0x0]:null;if(!_0x529564){const _0x202029=[];let _0x3aad95=null;_0x2c6d61['tag']&&(_0x3aad95=_0x2e3ca0()[_0x4ec999('0x1c07')](_0x2c6d61[_0x4ec999('0x1ce6')],{'name':_0x2c6d61[_0x4ec999('0x270')][_0x4ec999('0x270')]}));for(let _0x1dc7a2=0x0;_0x1dc7a2<_0x2c6d61['tags']['length'];_0x1dc7a2++){_0x3aad95&&_0x2c6d61[_0x4ec999('0x1ce6')][_0x1dc7a2]['id']===_0x3aad95['id']&&(_0x2c6d61[_0x4ec999('0x1ce6')][_0x1dc7a2][_0x4ec999('0x319')]=![],_0x202029[_0x4ec999('0x1fd0')](_0x2c6d61[_0x4ec999('0x1ce6')][_0x1dc7a2]));}_0x2c6d61[_0x4ec999('0x1ce6')]=_0x202029;}else{if(!_0x529564[_0x4ec999('0x170')])return _0x2cd35f[_0x4ec999('0xcf7')][_0x4ec999('0x1e6e')]({'sectionId':_0x529564['id']})['$promise'][_0x4ec999('0x683')](function(_0x560f2e){const _0x3b7ff9=_0x4ec999,_0x4bd027=_0x2e3ca0()[_0x3b7ff9('0x386')](_0x560f2e['rows'],function(_0x29dd11){const _0x38525b=_0x3b7ff9;return _0x2e3ca0()[_0x38525b('0x1c07')](_0x2c6d61[_0x38525b('0x1ce6')],{'id':_0x29dd11['resourceId']});});let _0x198bad=null;_0x2c6d61[_0x3b7ff9('0x270')]&&(_0x198bad=_0x2e3ca0()[_0x3b7ff9('0x1c07')](_0x2c6d61[_0x3b7ff9('0x1ce6')],{'name':_0x2c6d61[_0x3b7ff9('0x270')][_0x3b7ff9('0x270')]}));if(_0x198bad&&!_0x2e3ca0()[_0x3b7ff9('0x7a2')](_0x4bd027,['id',_0x198bad['id']])){const _0x512345=_0x2e3ca0()[_0x3b7ff9('0x1c07')](_0x2c6d61[_0x3b7ff9('0x1ce6')],{'id':_0x198bad['id']});_0x512345[_0x3b7ff9('0x319')]=![],_0x4bd027[_0x3b7ff9('0x1fd0')](_0x512345);}_0x2c6d61[_0x3b7ff9('0x1ce6')]=_0x4bd027;});}})[_0x48e5a0('0x130a')](function(_0x2ae238){const _0x27efdd=_0x48e5a0;_0x9432dd[_0x27efdd('0x52a')]({'title':_0x2ae238[_0x27efdd('0x13ee')]?'API:'+_0x2ae238['status']+_0x27efdd('0xbf6')+_0x2ae238[_0x27efdd('0x24a9')]:_0x27efdd('0x1118'),'msg':_0x2ae238[_0x27efdd('0x5a5')]?JSON[_0x27efdd('0x258a')](_0x2ae238['data']):_0x2ae238['toString']()});});function _0x23c693(){const _0x163cb2=_0x48e5a0;_0x2c6d61[_0x163cb2('0x17f')]=[];const _0x433627=[];_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0xcf0')]&&_0x2c6d61['tag'][_0x163cb2('0xcf0')][_0x163cb2('0x93a')]()===_0x163cb2('0x17cd')&&_0x2c6d61[_0x163cb2('0x270')]['appType']===_0x163cb2('0x4d2')&&(_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0xd31')]=_0x181a43[_0x163cb2('0x145a')]?(_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x24fa')]||'')+_0x163cb2('0x249e')+_0x181a43[_0x163cb2('0x145a')]+'}':(_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x24fa')]||'')+_0x163cb2('0x20cb'),_0x181a43[_0x163cb2('0x75b')]!==_0x163cb2('0x925')?_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x158e')][_0x163cb2('0x824')](_0x163cb2('0x1b1'))<0x0&&(_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x158e')]+=_0x163cb2('0x1b1')):_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x158e')]=_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x158e')][_0x163cb2('0x1725')](_0x163cb2('0x1b1'),''));const _0x302e7e=_0x2e3ca0()[_0x163cb2('0x1c07')](_0x2c6d61['tags'],{'name':_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x270')]});_0x302e7e&&(_0x2c6d61[_0x163cb2('0x270')]['TagId']=_0x302e7e['id']);if(_0x2c6d61[_0x163cb2('0x270')]['appType']&&_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x11f3')]==='custom'){}else switch((_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x1d75')]||_0x2c6d61['tag'][_0x163cb2('0x11f3')])[_0x163cb2('0x93a')]()){case _0x163cb2('0x877'):_0x2c6d61['tag'][_0x163cb2('0x1407')]=_0x2c6d61['tag'][_0x163cb2('0x60a')]+'='+_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x1c6b')];break;case _0x163cb2('0xbf0'):break;default:_0x433627[0x0]=_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x270')],_0x2c6d61[_0x163cb2('0x270')][_0x163cb2('0x1407')]=_0x433627[_0x163cb2('0x1630')](',');}_0x2f05ff(_0x2c6d61[_0x163cb2('0x270')]);}function _0x2f05ff(_0x5b3b49){_0x9273d7['hide'](_0x5b3b49);}}const _0x4ecb44=_0x47b02a;_0x1688eb[_0x189033('0x14be')]=['$cookies',_0x189033('0x7a5'),_0x189033('0x938'),'$q',_0x189033('0x1d08'),_0x189033('0x2f9'),'$mdDialog','$document',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0xba1')];function _0x1688eb(_0x37d6cc,_0x159f58,_0x385b66,_0x312a53,_0x490f29,_0x13fb18,_0x1713f0,_0x5df8ac,_0x186287,_0x921a81,_0x22acc0){const _0x7f811a=_0x189033,_0x33ac75=this;_0x33ac75[_0x7f811a('0x11ed')]=_0x22acc0[_0x7f811a('0x20b2')](),_0x33ac75[_0x7f811a('0x1990')]={},_0x33ac75[_0x7f811a('0x1b9d')]={'count':0x0,'rows':[]},_0x33ac75[_0x7f811a('0x23b7')]=[],_0x33ac75[_0x7f811a('0x1134')],_0x33ac75[_0x7f811a('0x23a2')]={'read':'null','closed':_0x7f811a('0x13c'),'sort':_0x7f811a('0xddd'),'includeAll':_0x7f811a('0x26ac'),'limit':0xa,'page':0x1},_0x33ac75['init']=_0x4dd650,_0x33ac75[_0x7f811a('0x26eb')]=_0x3e6151,_0x33ac75['whatsappInteractionDownload']=_0x13725f,_0x33ac75['success']=_0x1630be,_0x33ac75['getWhatsappAccountInteractions']=_0x2d9351,_0x33ac75['spywhatsappInteraction']=_0x5d9eeb,_0x33ac75[_0x7f811a('0x2121')]=_0x32ed9a,_0x33ac75['exportSelectedWhatsappAccountInteractions']=_0xa2832c,_0x33ac75[_0x7f811a('0x2291')]=_0x13ebed,_0x33ac75[_0x7f811a('0x129a')]=_0x4d9703;function _0x4dd650(_0x2fbcbb,_0x45cd3a){const _0x1a7309=_0x7f811a;_0x33ac75['whatsappAccount']=_0x2fbcbb,_0x33ac75[_0x1a7309('0x1134')]=typeof _0x45cd3a!==_0x1a7309('0x1867')?_0x45cd3a:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x33ac75[_0x1a7309('0x23a2')][_0x1a7309('0x1c35')]=_0x33ac75[_0x1a7309('0x1990')]['id'],_0x33ac75[_0x1a7309('0x19c9')]={'fields':_0xb44fac()},_0x3dbbc5();}function _0x3dbbc5(){const _0x525917=_0x7f811a;return _0x921a81[_0x525917('0x270')][_0x525917('0x1e6e')]()['$promise']['then'](function(_0xc70ce5){const _0x232d08=_0x525917;_0x33ac75[_0x232d08('0x1ce6')]=_0xc70ce5||{'count':0x0,'rows':[]};})[_0x525917('0x683')](function(){_0x33ac75['quickFilters']=_0x13a5ed();});}function _0x13a5ed(){const _0x364a03=_0x7f811a;return[{'name':'Start\x20Date','key':_0x364a03('0x1a4'),'type':_0x364a03('0x270e'),'label':_0x364a03('0x1006')},{'name':'Messages','key':_0x364a03('0x20db'),'type':_0x364a03('0xb31'),'label':_0x364a03('0x1866'),'customOptions':[{'value':0x0,'translate':_0x364a03('0x2226')},{'value':0x1,'translate':_0x364a03('0x38f')},{'value':null,'translate':_0x364a03('0x475')}]},{'name':'Status','key':_0x364a03('0xd8a'),'type':'select','label':'DASHBOARDS.SELECT_STATUS','customOptions':[{'value':0x0,'translate':_0x364a03('0x10b1')},{'value':0x1,'translate':_0x364a03('0x270a')},{'value':null,'translate':_0x364a03('0x475')}]},{'name':_0x364a03('0x62c'),'key':'UserId','type':_0x364a03('0xb31'),'label':_0x364a03('0x21fb'),'customOptions':[{'value':_0x364a03('0x13c'),'translate':'DASHBOARDS.NOT_ASSIGNED'},{'value':undefined,'translate':_0x364a03('0x475')}]},{'name':_0x364a03('0x1e'),'key':_0x364a03('0x270'),'type':'multiselect','label':'DASHBOARDS.SELECT_TAG','options':_0x33ac75[_0x364a03('0x1ce6')][_0x364a03('0xf5d')],'placeholder':_0x364a03('0x7cb')}];}function _0xb44fac(){const _0x3e7baa=_0x7f811a;return[{'name':'Id','column':'id','type':_0x3e7baa('0x121f')},{'name':_0x3e7baa('0x1309'),'column':_0x3e7baa('0x1309'),'type':_0x3e7baa('0xeb'),'options':{'searchFields':[_0x3e7baa('0xeef'),_0x3e7baa('0x510'),'email'],'route':{'model':'cmContact','action':_0x3e7baa('0x1e6e'),'params':{'fields':_0x3e7baa('0x8ff'),'Contact':_0x3e7baa('0xfd'),'nolimit':!![]}},'extraOperators':[_0x3e7baa('0xe55')],'excludedOperators':[_0x3e7baa('0x17ee')]}},{'name':_0x3e7baa('0x25a9'),'column':_0x3e7baa('0x1e66'),'type':_0x3e7baa('0x1bcd'),'options':{'excludedOperators':['$eq',_0x3e7baa('0x17ee')]}},{'name':_0x3e7baa('0x1765'),'column':_0x3e7baa('0x183b'),'type':'text','options':{'excludedOperators':[_0x3e7baa('0x393'),_0x3e7baa('0x17ee')]}},{'name':'Status','column':_0x3e7baa('0xd8a'),'type':_0x3e7baa('0xb31'),'values':[{'id':0x0,'translate':_0x3e7baa('0x10b1')},{'id':0x1,'translate':'DASHBOARDS.CLOSED'}],'options':{'excludedOperators':[_0x3e7baa('0x17ee')]}},{'name':_0x3e7baa('0x62c'),'column':_0x3e7baa('0x1dad'),'type':_0x3e7baa('0xeb'),'options':{'table':'i','route':{'model':_0x3e7baa('0xc96'),'action':_0x3e7baa('0x1e6e'),'params':{'role':'agent','fields':_0x3e7baa('0x2686'),'nolimit':!![]}},'searchFields':['fullname',_0x3e7baa('0x60a')],'extraOperators':[_0x3e7baa('0xe55')],'excludedOperators':[_0x3e7baa('0x17ee')]}},{'name':_0x3e7baa('0x198f'),'column':_0x3e7baa('0x1e'),'type':'multiselect','options':{'route':{'model':_0x3e7baa('0x270'),'action':_0x3e7baa('0x1e6e'),'params':{'nolimit':!![]}},'excludedOperators':[_0x3e7baa('0x1479')]}},{'name':_0x3e7baa('0x10c1'),'column':'createdAt','type':_0x3e7baa('0x270e'),'options':{'excludedOperators':[_0x3e7baa('0x17ee')]}},{'name':_0x3e7baa('0x1bb6'),'column':_0x3e7baa('0x122e'),'type':'select','values':[{'id':0x1,'translate':_0x3e7baa('0x38f')},{'id':0x0,'translate':_0x3e7baa('0x2226')}],'options':{'excludedOperators':[_0x3e7baa('0x17ee')]}}];}function _0x32ed9a(){const _0x153ee6=_0x7f811a;_0x1713f0[_0x153ee6('0x1d4')]({'controller':_0x153ee6('0x714'),'controllerAs':'vm','templateUrl':_0x3fe59f,'parent':angular[_0x153ee6('0x1fcc')](_0x5df8ac[_0x153ee6('0x18e5')]),'clickOutsideToClose':![],'locals':{'fields':_0x33ac75[_0x153ee6('0x19c9')][_0x153ee6('0x189a')],'color':undefined,'storagePath':_0x153ee6('0x312')},'fullscreen':!![]})['then'](function(_0xf95d54){const _0x3b9303=_0x153ee6;_0x33ac75[_0x3b9303('0x23a2')][_0x3b9303('0x19a4')]=_0xf95d54===![]?undefined:_0xf95d54;if(_0x33ac75['query']['search'])_0x2d9351();else _0xf95d54===![]&&_0x2d9351();})[_0x153ee6('0x130a')](function(_0x3fe49b){const _0x4d526c=_0x153ee6;_0x186287[_0x4d526c('0x52a')]({'title':_0x4d526c('0x1119'),'msg':_0x3fe49b[_0x4d526c('0x5a5')]?JSON[_0x4d526c('0x258a')](_0x3fe49b[_0x4d526c('0x5a5')][_0x4d526c('0x8c2')]):_0x3fe49b[_0x4d526c('0x1ff0')]()});});}function _0x13725f(_0x5b2b93,_0x17e01f,_0x1ddbdd){const _0x383fb9=_0x7f811a;return _0x921a81['whatsappInteraction'][_0x383fb9('0x18e8')]({'id':_0x5b2b93['id'],'exists':!![],'attachments':_0x1ddbdd})['$promise'][_0x383fb9('0x683')](function(_0x591175){const _0x2c7881=_0x383fb9,_0xeb823=[_0x591175[_0x2c7881('0x1fb3')]];let _0x6da3be=_0x2c7881('0xa98')+_0x5b2b93['id'];const _0x3af354=new Blob(_0xeb823,{'type':_0x591175['type']});_0x6da3be='whatsapp-interaction'+_0x5b2b93['id']+'.zip';const _0x53758f=window[_0x2c7881('0x12e1')][_0x2c7881('0x1ffa')]('a');_0x53758f[_0x2c7881('0x130f')](_0x2c7881('0x2767'),URL[_0x2c7881('0x2820')](_0x3af354)),_0x53758f['setAttribute']('download',_0x6da3be),document['body']['appendChild'](_0x53758f),_0x53758f[_0x2c7881('0x1d42')]();})['catch'](function(_0x28777c){const _0x29ccbb=_0x383fb9;if(_0x28777c[_0x29ccbb('0x5a5')]&&_0x28777c[_0x29ccbb('0x5a5')][_0x29ccbb('0x17f')]&&_0x28777c[_0x29ccbb('0x5a5')][_0x29ccbb('0x17f')][_0x29ccbb('0x1564')])for(let _0x12b130=0x0;_0x12b130<_0x28777c['data'][_0x29ccbb('0x17f')][_0x29ccbb('0x1564')];_0x12b130+=0x1){_0x186287[_0x29ccbb('0x52a')]({'title':_0x28777c[_0x29ccbb('0x5a5')][_0x29ccbb('0x17f')][_0x12b130][_0x29ccbb('0xcf0')],'msg':_0x28777c[_0x29ccbb('0x5a5')][_0x29ccbb('0x17f')][_0x12b130][_0x29ccbb('0x8c2')]});}else _0x186287['error']({'title':_0x28777c[_0x29ccbb('0x13ee')]?_0x29ccbb('0x2168')+_0x28777c[_0x29ccbb('0x13ee')]+_0x29ccbb('0xbf6')+_0x28777c[_0x29ccbb('0x24a9')]:_0x29ccbb('0x1fa2'),'msg':_0x28777c[_0x29ccbb('0x5a5')]?JSON['stringify'](_0x28777c[_0x29ccbb('0x5a5')]['message']):_0x28777c[_0x29ccbb('0x1ff0')]()});});}function _0x3e6151(_0x4c6bf1,_0x3bc3a5){const _0x11cf6e=_0x7f811a,_0xaf0c7b=_0x1713f0[_0x11cf6e('0x1c6f')]()['title']('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20interaction?')[_0x11cf6e('0x26e3')](_0x11cf6e('0xed5')+(_0x4c6bf1[_0x11cf6e('0x60a')]||_0x4c6bf1['id']&&_0x2e3ca0()['upperFirst'](_0x11cf6e('0x936'))+_0x4c6bf1['id']||_0x11cf6e('0xa98'))+''+'\x20will\x20be\x20deleted.')[_0x11cf6e('0x1040')](_0x11cf6e('0x19a8'))['targetEvent'](_0x3bc3a5)['ok']('OK')[_0x11cf6e('0x19fb')](_0x11cf6e('0x16b8'));_0x1713f0[_0x11cf6e('0x1d4')](_0xaf0c7b)['then'](function(){_0x13ebed(_0x4c6bf1);},function(){const _0x52b919=_0x11cf6e;console[_0x52b919('0x1b2b')](_0x52b919('0x16b8'));});}function _0x1630be(_0x587baf){const _0x55e088=_0x7f811a;_0x33ac75[_0x55e088('0x1b9d')]=_0x587baf||{'count':0x0,'rows':[]};for(let _0x20cd17=0x0;_0x20cd17<_0x33ac75[_0x55e088('0x1b9d')][_0x55e088('0xf5d')]['length'];_0x20cd17+=0x1){const _0x106abd=_0x33ac75[_0x55e088('0x1b9d')][_0x55e088('0xf5d')][_0x20cd17];_0x39f1be(_0x106abd),_0x106abd[_0x55e088('0x2464')]['name']=_0x401cc6(_0x106abd);}}function _0x2d9351(){const _0x1e99d1=_0x7f811a;_0x33ac75['query'][_0x1e99d1('0x1cc8')]=(_0x33ac75[_0x1e99d1('0x23a2')][_0x1e99d1('0xdf8')]-0x1)*_0x33ac75[_0x1e99d1('0x23a2')][_0x1e99d1('0x6f0')],_0x33ac75[_0x1e99d1('0x1883')]=_0x921a81[_0x1e99d1('0x1db7')][_0x1e99d1('0x1e6e')](_0x33ac75[_0x1e99d1('0x23a2')],_0x1630be)['$promise'];}function _0x5d9eeb(_0x502d15,_0x5121f6){const _0x5409b8=_0x7f811a;_0x1713f0[_0x5409b8('0x1d4')]({'controller':_0x5409b8('0x13ab'),'controllerAs':'vm','templateUrl':_0x37aa85,'parent':angular[_0x5409b8('0x1fcc')](_0x5df8ac[_0x5409b8('0x18e5')]),'targetEvent':_0x502d15,'clickOutsideToClose':!![],'onShowing':function(_0x58cba0){const _0x5c0c99=_0x5409b8;_0x58cba0['vm']['init']({'id':0x1,'channel':_0x5c0c99('0x16e7'),'interaction':_0x5121f6,'spy':!![]},_0x159f58[_0x5c0c99('0x1cd5')]['vm'][_0x5c0c99('0x260a')]);}});}function _0x13ebed(_0x248d68){const _0x246f32=_0x7f811a;_0x921a81[_0x246f32('0x1db7')][_0x246f32('0xd7e')]({'id':_0x248d68['id']})[_0x246f32('0xe53')][_0x246f32('0x683')](function(){const _0x367ab1=_0x246f32;_0x2e3ca0()['remove'](_0x33ac75[_0x367ab1('0x1b9d')][_0x367ab1('0xf5d')],{'id':_0x248d68['id']}),_0x33ac75[_0x367ab1('0x1b9d')][_0x367ab1('0x50d')]-=0x1,!_0x33ac75[_0x367ab1('0x1b9d')][_0x367ab1('0xf5d')]['length']&&_0x2d9351(),_0x186287[_0x367ab1('0x53')]({'title':'Interaction\x20deleted!','msg':_0x248d68[_0x367ab1('0x60a')]?_0x248d68[_0x367ab1('0x60a')]+_0x367ab1('0x194d'):''});})['catch'](function(_0x1531de){const _0x15ac4c=_0x246f32;if(_0x1531de[_0x15ac4c('0x5a5')]&&_0x1531de['data'][_0x15ac4c('0x17f')]&&_0x1531de[_0x15ac4c('0x5a5')][_0x15ac4c('0x17f')][_0x15ac4c('0x1564')]){_0x33ac75[_0x15ac4c('0x17f')]=_0x1531de[_0x15ac4c('0x5a5')]['errors']||[{'message':_0x1531de['toString'](),'type':'SYSTEM:GETwhatsappAccount'}];for(let _0x1928a2=0x0;_0x1928a2<_0x1531de[_0x15ac4c('0x5a5')][_0x15ac4c('0x17f')]['length'];_0x1928a2++){_0x186287[_0x15ac4c('0x52a')]({'title':_0x1531de[_0x15ac4c('0x5a5')][_0x15ac4c('0x17f')][_0x1928a2][_0x15ac4c('0xcf0')],'msg':_0x1531de[_0x15ac4c('0x5a5')][_0x15ac4c('0x17f')][_0x1928a2][_0x15ac4c('0x8c2')]});}}else _0x186287[_0x15ac4c('0x52a')]({'title':_0x1531de['status']?_0x15ac4c('0x2168')+_0x1531de[_0x15ac4c('0x13ee')]+'\x20-\x20'+_0x1531de[_0x15ac4c('0x24a9')]:_0x15ac4c('0x1e3d'),'msg':_0x1531de[_0x15ac4c('0x5a5')]?JSON['stringify'](_0x1531de[_0x15ac4c('0x5a5')]['message']):_0x1531de[_0x15ac4c('0x8c2')]||_0x1531de['toString']()});});}function _0xa2832c(){const _0xa828d=_0x7f811a,_0x331004=angular['copy'](_0x33ac75[_0xa828d('0x23b7')]);return _0x33ac75[_0xa828d('0x23b7')]=[],_0x331004;}function _0x4d9703(_0x22785e){const _0x5cdbc0=_0x7f811a,_0x59b80c=_0x1713f0[_0x5cdbc0('0x1c6f')]()[_0x5cdbc0('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20interactions?')[_0x5cdbc0('0x26e3')](''+_0x33ac75[_0x5cdbc0('0x23b7')]['length']+'\x20selected'+_0x5cdbc0('0x1ee7'))['ariaLabel'](_0x5cdbc0('0xe27'))[_0x5cdbc0('0xe42')](_0x22785e)['ok']('OK')['cancel'](_0x5cdbc0('0x16b8'));_0x1713f0[_0x5cdbc0('0x1d4')](_0x59b80c)['then'](function(){const _0x23e0e5=_0x5cdbc0;_0x33ac75[_0x23e0e5('0x23b7')][_0x23e0e5('0x1299')](function(_0x304952){_0x13ebed(_0x304952);}),_0x33ac75[_0x23e0e5('0x23b7')]=[];});}function _0x39f1be(_0x2d0f46){const _0x58c527=_0x7f811a;_0x2d0f46['Contact']?_0x2d0f46[_0x58c527('0x12b3')]=(_0x2d0f46[_0x58c527('0x1309')][_0x58c527('0xeef')]||'')+'\x20'+(_0x2d0f46['Contact'][_0x58c527('0x510')]||''):_0x2d0f46[_0x58c527('0x12b3')]=_0x490f29[_0x58c527('0x2728')]('DASHBOARDS.UNKNOWN');}function _0x401cc6(_0x46b1e4){const _0x455b4b=_0x7f811a;if(_0x46b1e4[_0x455b4b('0x10c5')])return _0x46b1e4[_0x455b4b('0x10c5')]===_0x33ac75[_0x455b4b('0x11ed')]['id']?_0x490f29[_0x455b4b('0x2728')](_0x455b4b('0x96a')):_0x46b1e4[_0x455b4b('0x2464')][_0x455b4b('0x11bc')]+'\x20<'+_0x46b1e4[_0x455b4b('0x2464')]['internal']+'>';return _0x490f29['instant'](_0x455b4b('0x2608'));}let _0x3a8c39=!![],_0x14d0cf=0x1;_0x159f58[_0x7f811a('0x186d')](_0x7f811a('0x229'),function(_0x1eef65,_0x540d86){const _0x39f5fa=_0x7f811a;_0x3a8c39?_0x13fb18(function(){_0x3a8c39=![];}):(!_0x540d86&&(_0x14d0cf=_0x33ac75[_0x39f5fa('0x23a2')][_0x39f5fa('0xdf8')]),_0x1eef65!==_0x540d86&&(_0x33ac75[_0x39f5fa('0x23a2')][_0x39f5fa('0xdf8')]=0x1),!_0x1eef65&&(_0x33ac75[_0x39f5fa('0x23a2')]['page']=_0x14d0cf),_0x2d9351());});}const _0x126951=_0x1688eb,_0x19f450=_0x180212['p']+_0x189033('0x232b');_0x5966ab[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x1d08'),_0x189033('0xace'),'setting',_0x189033('0x56b'),_0x189033('0x1d70'),'Auth',_0x189033('0x1990'),_0x189033('0x22df')];function _0x5966ab(_0x4accf6,_0x1861bf,_0x5ef0f9,_0xcf18a4,_0x56389b,_0x203318,_0x14bf27,_0x170f66,_0x22bfee,_0x264be2,_0x247916,_0x10a183){const _0x17b74b=_0x189033,_0x4b87f7=this;_0x4b87f7['currentUser']=_0x264be2['getCurrentUser'](),_0x4b87f7[_0x17b74b('0xace')]=_0x203318,_0x4b87f7[_0x17b74b('0x260a')]=_0x14bf27,_0x4b87f7[_0x17b74b('0x19b2')]=_0x4b87f7['setting'][_0x17b74b('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x4b87f7['location']=_0x1861bf[_0x17b74b('0x173e')]()+_0x17b74b('0x20de')+_0x1861bf[_0x17b74b('0x19ac')](),_0x4b87f7[_0x17b74b('0x1990')]=_0x247916||_0x4accf6['params']['whatsappAccount']||{},_0x4b87f7[_0x17b74b('0x22df')]=_0x10a183&&_0x10a183['count']==0x1?_0x10a183[_0x17b74b('0xf5d')][0x0]:null,_0x4b87f7['crudPermissions']=_0x264be2[_0x17b74b('0x142a')](_0x4b87f7['userProfileSection']?_0x4b87f7['userProfileSection'][_0x17b74b('0x1134')]:null),_0x4b87f7[_0x17b74b('0x258d')]={},_0x4b87f7['selectedTab']=_0x4accf6[_0x17b74b('0x7f2')][_0x17b74b('0x1904')]||0x0,_0x4b87f7[_0x17b74b('0x2814')]=_0x508258,_0x4b87f7[_0x17b74b('0x2430')]=_0x22bfee[_0x17b74b('0x2289')],_0x4b87f7[_0x17b74b('0x7af')]=_0x1e3fd8,_0x4b87f7[_0x17b74b('0x21b1')]=_0x483d81,_0x264be2[_0x17b74b('0xca1')](_0x17b74b('0x20c2'))?_0x170f66[_0x17b74b('0x259b')][_0x17b74b('0x1e6e')]({'fields':'id,name','sort':_0x17b74b('0x60a')})[_0x17b74b('0xe53')][_0x17b74b('0x683')](function(_0x5ba935){const _0xe038c0=_0x17b74b;_0x4b87f7[_0xe038c0('0xe01')]=_0x5ba935['rows']||[];})['catch'](function(_0x3fbd8b){const _0x131c11=_0x17b74b;_0x22bfee[_0x131c11('0x52a')]({'title':_0x3fbd8b[_0x131c11('0x13ee')]?_0x131c11('0x2168')+_0x3fbd8b[_0x131c11('0x13ee')]+_0x131c11('0xbf6')+_0x3fbd8b['statusText']:_0x131c11('0x251b'),'msg':_0x3fbd8b[_0x131c11('0x5a5')]?JSON['stringify'](_0x3fbd8b['data']):_0x3fbd8b['toString']()});}):_0x170f66[_0x17b74b('0x259b')][_0x17b74b('0x1e6e')]({'fields':'id,name','sort':_0x17b74b('0x60a')})[_0x17b74b('0xe53')][_0x17b74b('0x683')](function(_0x1a102f){const _0x2ceeea=_0x17b74b;_0x4b87f7[_0x2ceeea('0xe01')]=_0x1a102f[_0x2ceeea('0xf5d')]||[];})[_0x17b74b('0x683')](function(){const _0x1c2ae0=_0x17b74b;return _0x170f66[_0x1c2ae0('0x22df')][_0x1c2ae0('0x1e6e')]({'userProfileId':_0x4b87f7[_0x1c2ae0('0x11ed')]['userProfileId'],'sectionId':0x12d})[_0x1c2ae0('0xe53')];})[_0x17b74b('0x683')](function(_0xca0264){const _0x40bc16=_0x17b74b,_0x161d07=_0xca0264&&_0xca0264[_0x40bc16('0xf5d')]?_0xca0264[_0x40bc16('0xf5d')][0x0]:null;if(!_0x161d07){const _0x3fd988=[];let _0x5886a7=null;_0x4b87f7[_0x40bc16('0x1990')]&&(_0x5886a7=_0x2e3ca0()['find'](_0x4b87f7[_0x40bc16('0xe01')],{'id':Number(_0x4b87f7[_0x40bc16('0x1990')][_0x40bc16('0x1e4f')])}));for(let _0x4932b3=0x0;_0x4932b3<_0x4b87f7['lists'][_0x40bc16('0x1564')];_0x4932b3++){_0x5886a7&&_0x4b87f7[_0x40bc16('0xe01')][_0x4932b3]['id']===_0x5886a7['id']&&(_0x4b87f7[_0x40bc16('0xe01')][_0x4932b3][_0x40bc16('0x319')]=![],_0x3fd988['push'](_0x4b87f7[_0x40bc16('0xe01')][_0x4932b3]));}_0x4b87f7[_0x40bc16('0xe01')]=_0x3fd988;}else{if(!_0x161d07[_0x40bc16('0x170')])return _0x170f66['userProfileResource'][_0x40bc16('0x1e6e')]({'sectionId':_0x161d07['id']})[_0x40bc16('0xe53')][_0x40bc16('0x683')](function(_0xa9c103){const _0x3b8106=_0x40bc16,_0x2ddb8b=_0x2e3ca0()[_0x3b8106('0x386')](_0xa9c103[_0x3b8106('0xf5d')],function(_0x102d7c){const _0xd502ab=_0x3b8106;return _0x2e3ca0()['find'](_0x4b87f7['lists'],{'id':_0x102d7c[_0xd502ab('0x832')]});});let _0x476c74=null;_0x4b87f7[_0x3b8106('0x1990')]&&(_0x476c74=_0x2e3ca0()[_0x3b8106('0x1c07')](_0x4b87f7['lists'],{'id':Number(_0x4b87f7[_0x3b8106('0x1990')][_0x3b8106('0x1e4f')])}));if(_0x476c74&&!_0x2e3ca0()['some'](_0x2ddb8b,['id',_0x476c74['id']])){const _0x321010=_0x2e3ca0()[_0x3b8106('0x1c07')](_0x4b87f7[_0x3b8106('0xe01')],{'id':_0x476c74['id']});_0x321010[_0x3b8106('0x319')]=![],_0x2ddb8b['push'](_0x321010);}_0x4b87f7[_0x3b8106('0xe01')]=_0x2ddb8b;});}})['catch'](function(_0x54243e){const _0x470114=_0x17b74b;_0x22bfee[_0x470114('0x52a')]({'title':_0x54243e['status']?'API:'+_0x54243e[_0x470114('0x13ee')]+'\x20-\x20'+_0x54243e[_0x470114('0x24a9')]:_0x470114('0x11e3'),'msg':_0x54243e['data']?JSON[_0x470114('0x258a')](_0x54243e[_0x470114('0x5a5')]):_0x54243e[_0x470114('0x1ff0')]()});}),_0x264be2['hasRole'](_0x17b74b('0x20c2'))?_0x170f66[_0x17b74b('0xa4')][_0x17b74b('0x1e6e')]({'fields':'name,id','sort':_0x17b74b('0x60a'),'nolimit':_0x17b74b('0x26ac')})[_0x17b74b('0xe53')]['then'](function(_0x35905c){const _0xd55179=_0x17b74b;_0x4b87f7[_0xd55179('0x22ab')]=_0x35905c['rows']||[];})[_0x17b74b('0x130a')](function(_0xe28ba2){const _0x252030=_0x17b74b;_0x22bfee[_0x252030('0x52a')]({'title':_0xe28ba2['status']?_0x252030('0x2168')+_0xe28ba2[_0x252030('0x13ee')]+'\x20-\x20'+_0xe28ba2[_0x252030('0x24a9')]:'SYSTEM:GET_PAUSES','msg':_0xe28ba2['data']?JSON['stringify'](_0xe28ba2[_0x252030('0x5a5')]):_0xe28ba2[_0x252030('0x1ff0')]()});}):_0x170f66[_0x17b74b('0xa4')][_0x17b74b('0x1e6e')]({'fields':_0x17b74b('0x1688'),'sort':_0x17b74b('0x60a'),'nolimit':_0x17b74b('0x26ac')})[_0x17b74b('0xe53')][_0x17b74b('0x683')](function(_0xd63f5a){const _0x925c59=_0x17b74b;_0x4b87f7[_0x925c59('0x22ab')]=_0xd63f5a[_0x925c59('0xf5d')]||[];})[_0x17b74b('0x683')](function(){const _0x28e54d=_0x17b74b;return _0x170f66[_0x28e54d('0x22df')][_0x28e54d('0x1e6e')]({'userProfileId':_0x4b87f7[_0x28e54d('0x11ed')][_0x28e54d('0x2f')],'sectionId':0x3ed})[_0x28e54d('0xe53')];})[_0x17b74b('0x683')](function(_0x3aca75){const _0x3d5d53=_0x17b74b,_0xf66065=_0x3aca75&&_0x3aca75[_0x3d5d53('0xf5d')]?_0x3aca75[_0x3d5d53('0xf5d')][0x0]:null;if(!_0xf66065)_0x4b87f7[_0x3d5d53('0x22ab')]=[];else{if(!_0xf66065[_0x3d5d53('0x170')])return _0x170f66[_0x3d5d53('0xcf7')]['get']({'sectionId':_0xf66065['id']})['$promise'][_0x3d5d53('0x683')](function(_0xda97c7){const _0xfaff7e=_0x3d5d53,_0x4a4c60=_0x2e3ca0()['map'](_0xda97c7['rows'],function(_0x56a51f){const _0x44c980=a0_0x4e0a;return _0x2e3ca0()[_0x44c980('0x1c07')](_0x4b87f7[_0x44c980('0x22ab')],{'id':_0x56a51f['resourceId']});});_0x4b87f7[_0xfaff7e('0x22ab')][_0xfaff7e('0x1299')](function(_0x559a24){const _0x54c176=_0xfaff7e;!_0x2e3ca0()[_0x54c176('0x7a2')](_0x4a4c60,['id',_0x559a24['id']])&&(_0x559a24['canSelect']=![]),_0x4a4c60[_0x54c176('0x1fd0')](_0x559a24);}),_0x4b87f7[_0xfaff7e('0x22ab')]=_0x4a4c60;});}})[_0x17b74b('0x130a')](function(_0x149d7d){const _0x51313b=_0x17b74b;_0x22bfee[_0x51313b('0x52a')]({'title':_0x149d7d[_0x51313b('0x13ee')]?_0x51313b('0x2168')+_0x149d7d[_0x51313b('0x13ee')]+'\x20-\x20'+_0x149d7d[_0x51313b('0x24a9')]:_0x51313b('0xc45'),'msg':_0x149d7d[_0x51313b('0x5a5')]?JSON[_0x51313b('0x258a')](_0x149d7d['data']):_0x149d7d[_0x51313b('0x1ff0')]()});});function _0x508258(_0xadabe0,_0x26123c){const _0x400082=_0x17b74b;_0x5ef0f9[_0x400082('0x1d4')]({'controller':_0x400082('0x57e'),'controllerAs':'vm','templateUrl':_0x19f450,'parent':angular[_0x400082('0x1fcc')](_0xcf18a4[_0x400082('0x18e5')]),'targetEvent':_0x26123c,'clickOutsideToClose':!![],'locals':{'whatsappAccount':_0xadabe0,'whatsappAccounts':_0x4b87f7[_0x400082('0x263c')]?_0x4b87f7[_0x400082('0x263c')][_0x400082('0xf5d')]:[],'crudPermissions':_0x4b87f7[_0x400082('0x1134')],'realtime':![]}});}function _0x1e3fd8(){const _0x24df8f=_0x17b74b;_0x4accf6['go']('app.whatsapp.whatsappAccounts',{},{'reload':_0x24df8f('0x1774')});}function _0x483d81(){const _0x69e908=_0x17b74b;_0x170f66[_0x69e908('0x1990')][_0x69e908('0x2480')]({'id':_0x4b87f7['whatsappAccount']['id']},_0x4b87f7[_0x69e908('0x1990')])[_0x69e908('0xe53')][_0x69e908('0x683')](function(){const _0x4b6d76=_0x69e908;_0x22bfee[_0x4b6d76('0x53')]({'title':_0x4b6d76('0x287f'),'msg':_0x4b87f7[_0x4b6d76('0x1990')][_0x4b6d76('0x60a')]?_0x4b87f7[_0x4b6d76('0x1990')][_0x4b6d76('0x60a')]+_0x4b6d76('0x96c'):''});})['catch'](function(_0x34da9b){const _0x2eedb5=_0x69e908;_0x22bfee[_0x2eedb5('0x52a')]({'title':_0x34da9b['status']?_0x2eedb5('0x2168')+_0x34da9b[_0x2eedb5('0x13ee')]+_0x2eedb5('0xbf6')+_0x34da9b['statusText']:_0x2eedb5('0x1e3d'),'msg':_0x34da9b[_0x2eedb5('0x5a5')]?JSON[_0x2eedb5('0x258a')](_0x34da9b[_0x2eedb5('0x5a5')]):_0x34da9b[_0x2eedb5('0x1ff0')]()});});}}const _0x4b0750=_0x5966ab,_0x5d9ecc=_0x180212['p']+_0x189033('0x1cb9');_0x2e2a4a[_0x189033('0x14be')]=[_0x189033('0x17e4'),'$scope',_0x189033('0x938'),'$q',_0x189033('0x1d08'),'$timeout','$mdDialog',_0x189033('0x16ea'),_0x189033('0x1d70'),'api',_0x189033('0xba1')];function _0x2e2a4a(_0x104cad,_0x22c2ce,_0x4001ca,_0x34662c,_0x5bdc29,_0x3b6287,_0x290172,_0xd10314,_0x586cd7,_0x3a5c4b,_0x54d6b7){const _0x429d2a=_0x189033,_0x284760=this;_0x284760[_0x429d2a('0x11ed')]=_0x54d6b7[_0x429d2a('0x20b2')](),_0x284760[_0x429d2a('0x1990')]={},_0x284760[_0x429d2a('0x1f64')]={'count':0x0,'rows':[]},_0x284760[_0x429d2a('0x2760')]=[],_0x284760[_0x429d2a('0x1134')],_0x284760[_0x429d2a('0x23a2')]={'fields':_0x429d2a('0x8ee'),'limit':0xa,'page':0x1},_0x284760[_0x429d2a('0x12f3')]=_0x18e842,_0x284760[_0x429d2a('0x26eb')]=_0x1bce6d,_0x284760[_0x429d2a('0x53')]=_0x1f5349,_0x284760[_0x429d2a('0x139e')]=_0x35ea3a,_0x284760[_0x429d2a('0x9ed')]=_0x4f734c,_0x284760['exportSelectedWhatsappAccountWhatsappCannedAnswers']=_0x54d09d,_0x284760[_0x429d2a('0xec0')]=_0x572567,_0x284760[_0x429d2a('0x6d2')]=_0x4cbd00;function _0x18e842(_0x228c93,_0xaf4e31){const _0x2986c2=_0x429d2a;_0x284760['whatsappAccount']=_0x228c93,_0x284760[_0x2986c2('0x1134')]=typeof _0xaf4e31!==_0x2986c2('0x1867')?_0xaf4e31:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x284760['query'][_0x2986c2('0x1c35')]=_0x284760[_0x2986c2('0x1990')]['id'],_0x284760[_0x2986c2('0x23a2')]['id']=_0x284760[_0x2986c2('0x1990')]['id'],_0x35ea3a();}function _0x1bce6d(_0x2acf5a,_0x2d502d){const _0x52adfe=_0x429d2a,_0x3314bf=_0x290172[_0x52adfe('0x1c6f')]()[_0x52adfe('0xf28')](_0x52adfe('0x234d'))[_0x52adfe('0x26e3')](''+(_0x2acf5a[_0x52adfe('0x60a')]||_0x2acf5a['id']&&_0x2e3ca0()[_0x52adfe('0x2711')](_0x52adfe('0x464'))+_0x2acf5a['id']||'whatsappCannedAnswer')+_0x52adfe('0x20f1')+_0x52adfe('0x1ee7'))[_0x52adfe('0x1040')]('delete\x20whatsappCannedAnswer')[_0x52adfe('0xe42')](_0x2d502d)['ok']('OK')[_0x52adfe('0x19fb')]('CANCEL');_0x290172[_0x52adfe('0x1d4')](_0x3314bf)[_0x52adfe('0x683')](function(){_0x572567(_0x2acf5a);},function(){const _0x6e56=_0x52adfe;console[_0x6e56('0x1b2b')](_0x6e56('0x16b8'));});}function _0x1f5349(_0x35cfdd){const _0x9f94d3=_0x429d2a;_0x284760[_0x9f94d3('0x1f64')]=_0x35cfdd||{'count':0x0,'rows':[]};}function _0x35ea3a(){const _0xbc7f02=_0x429d2a;_0x284760['query']['offset']=(_0x284760[_0xbc7f02('0x23a2')][_0xbc7f02('0xdf8')]-0x1)*_0x284760[_0xbc7f02('0x23a2')][_0xbc7f02('0x6f0')],_0x284760[_0xbc7f02('0x1883')]=_0x3a5c4b['whatsappAccount'][_0xbc7f02('0x87f')](_0x284760[_0xbc7f02('0x23a2')],_0x1f5349)[_0xbc7f02('0xe53')];}function _0x4f734c(_0x5eb517,_0x40c6a8){const _0x35ecbe=_0x429d2a;_0x290172[_0x35ecbe('0x1d4')]({'controller':_0x35ecbe('0x1d8a'),'controllerAs':'vm','templateUrl':_0x5d9ecc,'parent':angular[_0x35ecbe('0x1fcc')](_0xd10314[_0x35ecbe('0x18e5')]),'targetEvent':_0x5eb517,'clickOutsideToClose':!![],'locals':{'whatsappAccount':_0x284760[_0x35ecbe('0x1990')],'whatsappCannedAnswer':_0x40c6a8,'whatsappCannedAnswers':_0x284760[_0x35ecbe('0x1f64')][_0x35ecbe('0xf5d')],'license':null,'setting':null,'crudPermissions':_0x284760[_0x35ecbe('0x1134')]}});}function _0x572567(_0x2699be){const _0x2d36b5=_0x429d2a;_0x3a5c4b[_0x2d36b5('0x136c')][_0x2d36b5('0xd7e')]({'id':_0x2699be['id']})[_0x2d36b5('0xe53')][_0x2d36b5('0x683')](function(){const _0x40f5b9=_0x2d36b5;_0x2e3ca0()[_0x40f5b9('0x3ec')](_0x284760['whatsappAccountWhatsappCannedAnswers'][_0x40f5b9('0xf5d')],{'id':_0x2699be['id']}),_0x284760[_0x40f5b9('0x1f64')]['count']-=0x1,!_0x284760[_0x40f5b9('0x1f64')]['rows']['length']&&_0x35ea3a(),_0x586cd7[_0x40f5b9('0x53')]({'title':_0x40f5b9('0x11c8'),'msg':_0x2699be[_0x40f5b9('0x60a')]?_0x2699be[_0x40f5b9('0x60a')]+_0x40f5b9('0x194d'):''});})[_0x2d36b5('0x130a')](function(_0x318826){const _0x375c1b=_0x2d36b5;if(_0x318826[_0x375c1b('0x5a5')]&&_0x318826[_0x375c1b('0x5a5')][_0x375c1b('0x17f')]&&_0x318826[_0x375c1b('0x5a5')]['errors'][_0x375c1b('0x1564')]){_0x284760[_0x375c1b('0x17f')]=_0x318826[_0x375c1b('0x5a5')][_0x375c1b('0x17f')]||[{'message':_0x318826[_0x375c1b('0x1ff0')](),'type':'SYSTEM:GETwhatsappAccount'}];for(let _0x23aaf6=0x0;_0x23aaf6<_0x318826[_0x375c1b('0x5a5')][_0x375c1b('0x17f')][_0x375c1b('0x1564')];_0x23aaf6++){_0x586cd7['error']({'title':_0x318826[_0x375c1b('0x5a5')]['errors'][_0x23aaf6]['type'],'msg':_0x318826['data'][_0x375c1b('0x17f')][_0x23aaf6][_0x375c1b('0x8c2')]});}}else _0x586cd7[_0x375c1b('0x52a')]({'title':_0x318826['status']?_0x375c1b('0x2168')+_0x318826['status']+_0x375c1b('0xbf6')+_0x318826[_0x375c1b('0x24a9')]:'SYSTEM:GETwhatsappAccount','msg':_0x318826[_0x375c1b('0x5a5')]?JSON['stringify'](_0x318826[_0x375c1b('0x5a5')][_0x375c1b('0x8c2')]):_0x318826[_0x375c1b('0x8c2')]||_0x318826['toString']()});});}function _0x54d09d(){const _0x2afb32=_0x429d2a,_0x398c6b=angular[_0x2afb32('0x1a86')](_0x284760[_0x2afb32('0x2760')]);return _0x284760[_0x2afb32('0x2760')]=[],_0x398c6b;}function _0x4cbd00(_0x27f710){const _0x2c4ab7=_0x429d2a,_0x57d8db=_0x290172['confirm']()['title'](_0x2c4ab7('0x2822'))[_0x2c4ab7('0x26e3')](''+_0x284760[_0x2c4ab7('0x2760')][_0x2c4ab7('0x1564')]+_0x2c4ab7('0x93c')+_0x2c4ab7('0x1ee7'))[_0x2c4ab7('0x1040')](_0x2c4ab7('0xc3b'))[_0x2c4ab7('0xe42')](_0x27f710)['ok']('OK')[_0x2c4ab7('0x19fb')](_0x2c4ab7('0x16b8'));_0x290172[_0x2c4ab7('0x1d4')](_0x57d8db)[_0x2c4ab7('0x683')](function(){const _0x5a52bb=_0x2c4ab7;_0x284760[_0x5a52bb('0x2760')][_0x5a52bb('0x1299')](function(_0x5205f7){_0x572567(_0x5205f7);}),_0x284760[_0x5a52bb('0x2760')]=[];});}let _0x252a38=!![],_0x38a33d=0x1;_0x22c2ce[_0x429d2a('0x186d')]('vm_dc.query.filter',function(_0x21bba8,_0x4a555b){const _0x3a6b30=_0x429d2a;_0x252a38?_0x3b6287(function(){_0x252a38=![];}):(!_0x4a555b&&(_0x38a33d=_0x284760[_0x3a6b30('0x23a2')]['page']),_0x21bba8!==_0x4a555b&&(_0x284760[_0x3a6b30('0x23a2')][_0x3a6b30('0xdf8')]=0x1),!_0x21bba8&&(_0x284760[_0x3a6b30('0x23a2')]['page']=_0x38a33d),_0x35ea3a());});}const _0x3b689c=_0x2e2a4a;_0x5c5138[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0x831'),_0x189033('0x5f8'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a'),'crudPermissions'];function _0x5c5138(_0x553316,_0x6d2d7c,_0x53768b,_0x1cc24a,_0x2d25d7,_0x3639e0,_0x1b26c3,_0x49ac85,_0x120a9e,_0x13f341,_0x906041,_0x417ee4,_0x56f342,_0x4c3b56){const _0xe38824=_0x189033,_0x2ff4d1=this;_0x2ff4d1['currentUser']=_0x906041[_0xe38824('0x20b2')](),_0x2ff4d1[_0xe38824('0x17f')]=[],_0x2ff4d1[_0xe38824('0x260a')]=_0x56f342,_0x2ff4d1[_0xe38824('0xace')]=_0x417ee4,_0x2ff4d1[_0xe38824('0x1134')]=_0x4c3b56,_0x2ff4d1[_0xe38824('0x258d')]={},_0x2ff4d1[_0xe38824('0x19b2')]=_0x2ff4d1['setting']&&_0x2ff4d1[_0xe38824('0x260a')]['securePassword']?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x2ff4d1[_0xe38824('0xf28')]=_0xe38824('0x17ec'),_0x2ff4d1[_0xe38824('0x5f8')]=angular['copy'](_0x120a9e),_0x2ff4d1[_0xe38824('0x831')]=_0x49ac85,_0x2ff4d1[_0xe38824('0x390')]=![];!_0x2ff4d1[_0xe38824('0x5f8')]&&(_0x2ff4d1['whatsappCannedAnswer']={},_0x2ff4d1[_0xe38824('0xf28')]=_0xe38824('0x114c'),_0x2ff4d1[_0xe38824('0x390')]=!![]);_0x6d2d7c[_0xe38824('0x7f2')]['id']&&(_0x2ff4d1[_0xe38824('0x5f8')][_0xe38824('0x1c35')]=_0x6d2d7c['params']['id']);_0x2ff4d1[_0xe38824('0x2426')]=_0x28da8d,_0x2ff4d1['saveWhatsappCannedAnswer']=_0x4f1e15,_0x2ff4d1[_0xe38824('0xff5')]=_0x7fb1ea,_0x2ff4d1['getDateFromString']=_0x33bf4e,_0x2ff4d1['closeDialog']=_0x519e46;function _0x28da8d(){const _0x25c0b5=_0xe38824;_0x2ff4d1[_0x25c0b5('0x17f')]=[],_0x13f341[_0x25c0b5('0x136c')][_0x25c0b5('0xb0a')](_0x2ff4d1['whatsappCannedAnswer'])[_0x25c0b5('0xe53')]['then'](function(_0xe25f2f){const _0x167928=_0x25c0b5;_0x2ff4d1[_0x167928('0x831')][_0x167928('0x1167')](_0xe25f2f['toJSON']()),_0x1b26c3[_0x167928('0x53')]({'title':_0x167928('0x13a9'),'msg':_0x2ff4d1['whatsappCannedAnswer'][_0x167928('0x60a')]?_0x2ff4d1[_0x167928('0x5f8')]['name']+'\x20has\x20been\x20created!':''}),_0x519e46(_0xe25f2f);})[_0x25c0b5('0x130a')](function(_0x546e9d){const _0x3a23ca=_0x25c0b5;if(_0x546e9d['data']&&_0x546e9d['data'][_0x3a23ca('0x17f')]&&_0x546e9d[_0x3a23ca('0x5a5')][_0x3a23ca('0x17f')][_0x3a23ca('0x1564')]){_0x2ff4d1[_0x3a23ca('0x17f')]=_0x546e9d['data'][_0x3a23ca('0x17f')]||[{'message':_0x546e9d[_0x3a23ca('0x1ff0')](),'type':_0x3a23ca('0x267b')}];for(let _0x555c3b=0x0;_0x555c3b<_0x546e9d[_0x3a23ca('0x5a5')]['errors']['length'];_0x555c3b+=0x1){_0x1b26c3[_0x3a23ca('0x52a')]({'title':_0x546e9d[_0x3a23ca('0x5a5')][_0x3a23ca('0x17f')][_0x555c3b][_0x3a23ca('0xcf0')],'msg':_0x546e9d[_0x3a23ca('0x5a5')][_0x3a23ca('0x17f')][_0x555c3b][_0x3a23ca('0x8c2')]});}}else _0x1b26c3[_0x3a23ca('0x52a')]({'title':_0x546e9d['status']?_0x3a23ca('0x2168')+_0x546e9d[_0x3a23ca('0x13ee')]+_0x3a23ca('0xbf6')+_0x546e9d[_0x3a23ca('0x24a9')]:_0x3a23ca('0x267b'),'msg':_0x546e9d[_0x3a23ca('0x5a5')]?JSON[_0x3a23ca('0x258a')](_0x546e9d[_0x3a23ca('0x5a5')][_0x3a23ca('0x8c2')]):_0x546e9d[_0x3a23ca('0x1ff0')]()});});}function _0x4f1e15(){const _0xb3fac9=_0xe38824;_0x2ff4d1[_0xb3fac9('0x17f')]=[],_0x13f341[_0xb3fac9('0x136c')][_0xb3fac9('0x2480')]({'id':_0x2ff4d1['whatsappCannedAnswer']['id']},_0x2ff4d1[_0xb3fac9('0x5f8')])[_0xb3fac9('0xe53')][_0xb3fac9('0x683')](function(_0x1a7d17){const _0x13359d=_0xb3fac9,_0x12d79a=_0x2e3ca0()[_0x13359d('0x1c07')](_0x2ff4d1[_0x13359d('0x831')],{'id':_0x1a7d17['id']});_0x12d79a&&_0x2e3ca0()[_0x13359d('0xf22')](_0x12d79a,_0x2e3ca0()[_0x13359d('0x24d0')](_0x1a7d17[_0x13359d('0x24e1')](),_0x2e3ca0()[_0x13359d('0x55e')](_0x12d79a))),_0x1b26c3['success']({'title':_0x13359d('0x1ab1'),'msg':_0x2ff4d1[_0x13359d('0x5f8')][_0x13359d('0x60a')]?_0x2ff4d1[_0x13359d('0x5f8')][_0x13359d('0x60a')]+_0x13359d('0xf59'):''}),_0x519e46(_0x1a7d17);})[_0xb3fac9('0x130a')](function(_0x349994){const _0x10bd4a=_0xb3fac9;if(_0x349994['data']&&_0x349994[_0x10bd4a('0x5a5')][_0x10bd4a('0x17f')]&&_0x349994[_0x10bd4a('0x5a5')][_0x10bd4a('0x17f')][_0x10bd4a('0x1564')]){_0x2ff4d1[_0x10bd4a('0x17f')]=_0x349994['data'][_0x10bd4a('0x17f')]||[{'message':_0x349994['toString'](),'type':_0x10bd4a('0x1301')}];for(let _0x76fd56=0x0;_0x76fd56<_0x349994[_0x10bd4a('0x5a5')][_0x10bd4a('0x17f')][_0x10bd4a('0x1564')];_0x76fd56++){_0x1b26c3['error']({'title':_0x349994['data'][_0x10bd4a('0x17f')][_0x76fd56][_0x10bd4a('0xcf0')],'msg':_0x349994[_0x10bd4a('0x5a5')][_0x10bd4a('0x17f')][_0x76fd56][_0x10bd4a('0x8c2')]});}}else _0x1b26c3['error']({'title':_0x349994[_0x10bd4a('0x13ee')]?_0x10bd4a('0x2168')+_0x349994[_0x10bd4a('0x13ee')]+_0x10bd4a('0xbf6')+_0x349994[_0x10bd4a('0x24a9')]:_0x10bd4a('0x1301'),'msg':_0x349994['data']?JSON[_0x10bd4a('0x258a')](_0x349994[_0x10bd4a('0x5a5')][_0x10bd4a('0x8c2')]):_0x349994['toString']()});});}function _0x7fb1ea(_0x50138e){const _0x2db629=_0xe38824;_0x2ff4d1['errors']=[];const _0x27e6e3=_0x1cc24a[_0x2db629('0x1c6f')]()[_0x2db629('0xf28')](_0x2db629('0x4d'))['content'](_0x2db629('0x22bb'))[_0x2db629('0x1040')](_0x2db629('0x249'))['ok'](_0x2db629('0x2307'))[_0x2db629('0x19fb')]('Cancel')[_0x2db629('0xe42')](_0x50138e);_0x1cc24a[_0x2db629('0x1d4')](_0x27e6e3)['then'](function(){const _0x180e33=_0x2db629;_0x13f341[_0x180e33('0x136c')][_0x180e33('0xd7e')]({'id':_0x2ff4d1['whatsappCannedAnswer']['id']})[_0x180e33('0xe53')][_0x180e33('0x683')](function(){const _0x435964=_0x180e33;_0x2e3ca0()[_0x435964('0x3ec')](_0x2ff4d1[_0x435964('0x831')],{'id':_0x2ff4d1[_0x435964('0x5f8')]['id']}),_0x1b26c3[_0x435964('0x53')]({'title':_0x435964('0x149c'),'msg':(_0x2ff4d1['whatsappCannedAnswer'][_0x435964('0x60a')]||'whatsappCannedAnswer')+_0x435964('0x194d')}),_0x519e46(_0x2ff4d1[_0x435964('0x5f8')]);})[_0x180e33('0x130a')](function(_0x1772f4){const _0x4a87ea=_0x180e33;if(_0x1772f4[_0x4a87ea('0x5a5')]&&_0x1772f4[_0x4a87ea('0x5a5')][_0x4a87ea('0x17f')]&&_0x1772f4[_0x4a87ea('0x5a5')]['errors'][_0x4a87ea('0x1564')]){_0x2ff4d1[_0x4a87ea('0x17f')]=_0x1772f4[_0x4a87ea('0x5a5')][_0x4a87ea('0x17f')]||[{'message':_0x1772f4[_0x4a87ea('0x1ff0')](),'type':'api.cannedAnswer.delete'}];for(let _0x346f3e=0x0;_0x346f3e<_0x1772f4[_0x4a87ea('0x5a5')][_0x4a87ea('0x17f')][_0x4a87ea('0x1564')];_0x346f3e++){_0x1b26c3[_0x4a87ea('0x52a')]({'title':_0x1772f4[_0x4a87ea('0x5a5')]['errors'][_0x346f3e][_0x4a87ea('0xcf0')],'msg':_0x1772f4[_0x4a87ea('0x5a5')][_0x4a87ea('0x17f')][_0x346f3e][_0x4a87ea('0x8c2')]});}}else _0x1b26c3['error']({'title':_0x1772f4[_0x4a87ea('0x13ee')]?_0x4a87ea('0x2168')+_0x1772f4[_0x4a87ea('0x13ee')]+_0x4a87ea('0xbf6')+_0x1772f4[_0x4a87ea('0x24a9')]:_0x4a87ea('0x253e'),'msg':_0x1772f4[_0x4a87ea('0x5a5')]?JSON['stringify'](_0x1772f4['data']['message']):_0x1772f4[_0x4a87ea('0x8c2')]||_0x1772f4[_0x4a87ea('0x1ff0')]()});});},function(){});}function _0x33bf4e(_0x583b6f){return _0x583b6f===null?undefined:new Date(_0x583b6f);}function _0x519e46(_0x87971a){const _0x4f5092=_0xe38824;_0x1cc24a[_0x4f5092('0x1715')](_0x87971a);}}const _0x10fc06=_0x5c5138;_0x2e3835[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x2063'),_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),'$timeout','$translate',_0x189033('0x56b'),_0x189033('0x1d70'),_0x189033('0xba1')];function _0x2e3835(_0x21b114,_0x5008a7,_0x236462,_0x134b79,_0x3370ff,_0x46e2e1,_0x58ee57,_0x3e3cb4,_0x55ce8e,_0x545d5c,_0x4254f9){const _0x44ed98=_0x189033,_0x59acbb=this;_0x59acbb[_0x44ed98('0x11ed')]=_0x4254f9[_0x44ed98('0x20b2')](),_0x59acbb['dispositions']={'count':0x0,'rows':[]},_0x59acbb['selectedDispositions']=[],_0x59acbb[_0x44ed98('0x1134')],_0x59acbb[_0x44ed98('0x1d01')]={'first':_0x44ed98('0x1fd1'),'second':'2nd','third':_0x44ed98('0x10ce')},_0x59acbb[_0x44ed98('0x23a2')]={'fields':_0x44ed98('0xadb'),'sort':_0x44ed98('0xc36'),'limit':0xa,'page':0x1},_0x59acbb[_0x44ed98('0x12f3')]=_0x3795db,_0x59acbb[_0x44ed98('0x26eb')]=_0x4cd4ee,_0x59acbb[_0x44ed98('0x53')]=_0x3b4390,_0x59acbb[_0x44ed98('0x13d9')]=_0x4a0baf,_0x59acbb['createOrEditDisposition']=_0x39c3f1,_0x59acbb['deleteDisposition']=_0x34de84,_0x59acbb['exportSelectedDispositions']=_0x249f1b,_0x59acbb[_0x44ed98('0x238e')]=_0x2c5e5b,_0x59acbb[_0x44ed98('0x268c')]=_0x197ea7,_0x59acbb[_0x44ed98('0x1801')]=_0x26ad55;function _0x3795db(_0x5e9566,_0x50537b){const _0x580d45=_0x44ed98;_0x59acbb['whatsappAccount']=_0x5e9566||{},_0x59acbb['crudPermissions']=typeof _0x50537b!==_0x580d45('0x1867')?_0x50537b:{'readOnly':!![],'canEdit':![],'canDelete':![]},_0x59acbb[_0x580d45('0x23a2')]['WhatsappAccountId']=_0x59acbb[_0x580d45('0x1990')]['id'],_0x59acbb[_0x580d45('0x23a2')]['id']=_0x59acbb[_0x580d45('0x1990')]['id'],_0x4a0baf();}function _0x39c3f1(_0x291f06,_0xceda5e){const _0x202cef=_0x44ed98;_0x3370ff[_0x202cef('0x1d4')]({'controller':'CreateOrEditDispositionDialogController','controllerAs':'vm','templateUrl':_0x32807f,'parent':angular[_0x202cef('0x1fcc')](_0x46e2e1['body']),'targetEvent':_0x291f06,'clickOutsideToClose':!![],'locals':{'disposition':_0xceda5e,'dispositions':_0x59acbb[_0x202cef('0x191e')][_0x202cef('0xf5d')],'model':{'id':_0x59acbb[_0x202cef('0x1990')]['id'],'field':_0x202cef('0x1c35')},'license':null,'setting':null,'crudPermissions':_0x59acbb[_0x202cef('0x1134')]}})[_0x202cef('0x683')](function(_0x2722ca){if(_0x2722ca)_0x4a0baf();});}function _0x4cd4ee(_0x5d0d08,_0x156aef){const _0x41bc89=_0x44ed98,_0x3ec1b0=_0x2e3ca0()[_0x41bc89('0x7a2')](_0x59acbb[_0x41bc89('0x191e')][_0x41bc89('0xf5d')],[_0x41bc89('0x1b62'),_0x5d0d08['id']]),_0x3638df=_0x3370ff[_0x41bc89('0x1c6f')]()[_0x41bc89('0xf28')](_0x3e3cb4[_0x41bc89('0x2728')](_0x41bc89('0x15d8')))[_0x41bc89('0xa6a')](_0x3e3cb4[_0x41bc89('0x2728')](_0x41bc89('0x13bf')+(_0x3ec1b0?_0x41bc89('0x2235'):_0x41bc89('0x106')),{'name':_0x5d0d08[_0x41bc89('0x60a')]}))['ariaLabel'](_0x41bc89('0x550'))[_0x41bc89('0xe42')](_0x156aef)['ok']('OK')[_0x41bc89('0x19fb')](_0x3e3cb4[_0x41bc89('0x2728')]('TOOLS.CANCEL'));_0x3370ff[_0x41bc89('0x1d4')](_0x3638df)[_0x41bc89('0x683')](function(){_0x34de84(_0x5d0d08);});}function _0x3b4390(_0x5d1ce3){_0x59acbb['dispositions']=_0x5d1ce3||{'count':0x0,'rows':[]};}function _0x4a0baf(){const _0x58074a=_0x44ed98;_0x59acbb['query'][_0x58074a('0x1cc8')]=(_0x59acbb['query'][_0x58074a('0xdf8')]-0x1)*_0x59acbb['query'][_0x58074a('0x6f0')],_0x59acbb['promise']=_0x55ce8e[_0x58074a('0x1990')][_0x58074a('0x13d9')](_0x59acbb[_0x58074a('0x23a2')],_0x3b4390)['$promise'];}function _0x34de84(_0x345de9){const _0x20b0c4=_0x44ed98;_0x55ce8e[_0x20b0c4('0x43f')]['delete']({'id':_0x345de9['id']})[_0x20b0c4('0xe53')][_0x20b0c4('0x683')](function(){const _0x17da62=_0x20b0c4;_0x4a0baf(),_0x545d5c[_0x17da62('0x53')]({'title':_0x3e3cb4['instant'](_0x17da62('0x210b'))});})[_0x20b0c4('0x130a')](function(_0x1b8ecc){const _0x21a421=_0x20b0c4;if(_0x1b8ecc[_0x21a421('0x5a5')]&&_0x1b8ecc['data'][_0x21a421('0x17f')]&&_0x1b8ecc[_0x21a421('0x5a5')][_0x21a421('0x17f')][_0x21a421('0x1564')]){_0x59acbb['errors']=_0x1b8ecc[_0x21a421('0x5a5')][_0x21a421('0x17f')]||[{'message':_0x1b8ecc[_0x21a421('0x1ff0')](),'type':_0x21a421('0x189b')}];for(let _0x5db377=0x0;_0x5db377<_0x1b8ecc[_0x21a421('0x5a5')][_0x21a421('0x17f')]['length'];_0x5db377++){_0x545d5c[_0x21a421('0x52a')]({'title':_0x1b8ecc[_0x21a421('0x5a5')]['errors'][_0x5db377][_0x21a421('0xcf0')],'msg':_0x1b8ecc[_0x21a421('0x5a5')][_0x21a421('0x17f')][_0x5db377][_0x21a421('0x8c2')]});}}else _0x545d5c[_0x21a421('0x52a')]({'title':_0x1b8ecc[_0x21a421('0x13ee')]?_0x21a421('0x2168')+_0x1b8ecc[_0x21a421('0x13ee')]+_0x21a421('0xbf6')+_0x1b8ecc[_0x21a421('0x24a9')]:_0x21a421('0x189b'),'msg':_0x1b8ecc[_0x21a421('0x5a5')]?JSON[_0x21a421('0x258a')](_0x1b8ecc['data'][_0x21a421('0x8c2')]):_0x1b8ecc['message']||_0x1b8ecc[_0x21a421('0x1ff0')]()});});}function _0x249f1b(){const _0x170352=_0x44ed98,_0x3aa373=angular[_0x170352('0x1a86')](_0x59acbb['selectedDispositions']);return _0x59acbb[_0x170352('0x17')]=[],_0x3aa373;}function _0x2c5e5b(_0x336ee8){const _0xa8c864=_0x44ed98,_0x22b72e=_0x3370ff['confirm']()[_0xa8c864('0xf28')](_0x3e3cb4['instant'](_0xa8c864('0xfa')))[_0xa8c864('0xa6a')](_0x3e3cb4[_0xa8c864('0x2728')](_0xa8c864('0x1ebe'),{'total':_0x59acbb[_0xa8c864('0x17')][_0xa8c864('0x1564')]}))[_0xa8c864('0x1040')](_0xa8c864('0xb49'))[_0xa8c864('0xe42')](_0x336ee8)['ok']('OK')[_0xa8c864('0x19fb')](_0x3e3cb4[_0xa8c864('0x2728')]('TOOLS.CANCEL'));_0x3370ff[_0xa8c864('0x1d4')](_0x22b72e)['then'](function(){const _0x2e9235=_0xa8c864;_0x59acbb[_0x2e9235('0x17')][_0x2e9235('0x1299')](function(_0x3d388b){_0x34de84(_0x3d388b);}),_0x59acbb[_0x2e9235('0x17')]=[];});}function _0x197ea7(){const _0x5832a2=_0x44ed98;_0x59acbb[_0x5832a2('0x17')]=[];}function _0x26ad55(){const _0x37381f=_0x44ed98;_0x59acbb[_0x37381f('0x17')]=_0x59acbb[_0x37381f('0x191e')][_0x37381f('0xf5d')];}let _0x39de46=!![],_0xc64f7f=0x1;_0x21b114[_0x44ed98('0x186d')](_0x44ed98('0x229'),function(_0x4bb66a,_0x164c49){const _0x1d8b30=_0x44ed98;_0x39de46?_0x58ee57(function(){_0x39de46=![];}):(!_0x164c49&&(_0xc64f7f=_0x59acbb[_0x1d8b30('0x23a2')][_0x1d8b30('0xdf8')]),_0x4bb66a!==_0x164c49&&(_0x59acbb[_0x1d8b30('0x23a2')]['page']=0x1),!_0x4bb66a&&(_0x59acbb[_0x1d8b30('0x23a2')][_0x1d8b30('0xdf8')]=_0xc64f7f),_0x4a0baf());});}const _0x4044db=_0x2e3835,_0x5e1fca=_0x180212['p']+'src/js/modules/main/apps/whatsapp/views/whatsappAccounts/create/dialog.html/dialog.html';_0x30d28b['$inject']=[_0x189033('0x7a5'),'$window',_0x189033('0x938'),'$mdSidenav',_0x189033('0x1e48'),'$document',_0x189033('0x2f9'),_0x189033('0x1d08'),_0x189033('0x263c'),'userProfile',_0x189033('0x22df'),_0x189033('0x56b'),'msUtils','toasty',_0x189033('0xba1'),_0x189033('0xace'),_0x189033('0x260a')];function _0x30d28b(_0x32134e,_0x474bff,_0x36888b,_0x1eb6c2,_0x50770e,_0x28b126,_0x26ad1c,_0x42d251,_0x2761f4,_0x4c6055,_0x524dee,_0x32e5f3,_0x5b49f8,_0x2f4aad,_0x16a301,_0x2c973b,_0x14db1a){const _0xf8a295=_0x189033,_0x2fc771=this;_0x2fc771['license']=_0x2c973b,_0x2fc771[_0xf8a295('0x260a')]=_0x14db1a,_0x2fc771[_0xf8a295('0x11ed')]=_0x16a301[_0xf8a295('0x20b2')](),_0x2fc771['whatsappAccounts']=_0x2761f4||{'count':0x0,'rows':[]},_0x2fc771[_0xf8a295('0x2a')]=_0x4c6055,_0x2fc771[_0xf8a295('0x22df')]=_0x524dee&&_0x524dee['count']==0x1?_0x524dee[_0xf8a295('0xf5d')][0x0]:null,_0x2fc771[_0xf8a295('0x1134')]=_0x16a301[_0xf8a295('0x142a')](_0x2fc771[_0xf8a295('0x22df')]?_0x2fc771[_0xf8a295('0x22df')][_0xf8a295('0x1134')]:null),_0x2fc771['table']='whatsappAccounts',_0x2fc771[_0xf8a295('0x247')]='',_0x2fc771['listOrderAsc']=null,_0x2fc771[_0xf8a295('0x1f00')]=[],_0x2fc771[_0xf8a295('0x23a2')]={'fields':_0xf8a295('0x1639'),'sort':_0xf8a295('0xc36'),'limit':0xa,'page':0x1},_0x2fc771['arraytype']=_0x2e3ca0()[_0xf8a295('0x24db')]([{'option':_0xf8a295('0x20e5'),'value':'\x27twilio\x27'}],function(_0x40c565){const _0x531ae1=_0xf8a295;return _0x2e3ca0()[_0x531ae1('0x1725')](_0x40c565[_0x531ae1('0x1c6b')],new RegExp('\x27','g'),'');}),_0x2fc771[_0xf8a295('0xc63')]=_0x474526,_0x2fc771['interactionsgoto']=_0x8c7bec,_0x2fc771[_0xf8a295('0x2814')]=_0x5b72ce,_0x2fc771[_0xf8a295('0x194f')]=_0x5f36f1,_0x2fc771['success']=_0x342731,_0x2fc771[_0xf8a295('0x1fb9')]=_0x15bfb0,_0x2fc771['createOrEditWhatsappAccount']=_0x4e1930,_0x2fc771[_0xf8a295('0x1008')]=_0x8c1435,_0x2fc771[_0xf8a295('0x250f')]=_0xb43c93,_0x2fc771[_0xf8a295('0x18fe')]=_0x33eb08,_0x2fc771['deselectWhatsappAccounts']=_0x27aa69,_0x2fc771[_0xf8a295('0x17ef')]=_0x5b8f87,_0x16a301[_0xf8a295('0xca1')](_0xf8a295('0x20c2'))?_0x32e5f3['cmList'][_0xf8a295('0x1e6e')]({'fields':_0xf8a295('0xa10'),'sort':'name'})[_0xf8a295('0xe53')]['then'](function(_0x2e7c1e){const _0x3045ae=_0xf8a295;_0x2fc771[_0x3045ae('0xe01')]=_0x2e7c1e[_0x3045ae('0xf5d')]||[];})['catch'](function(_0x2ae18f){const _0x56f07d=_0xf8a295;_0x2f4aad[_0x56f07d('0x52a')]({'title':_0x2ae18f['status']?_0x56f07d('0x2168')+_0x2ae18f['status']+_0x56f07d('0xbf6')+_0x2ae18f['statusText']:_0x56f07d('0x251b'),'msg':_0x2ae18f[_0x56f07d('0x5a5')]?JSON[_0x56f07d('0x258a')](_0x2ae18f['data']):_0x2ae18f[_0x56f07d('0x1ff0')]()});}):_0x32e5f3[_0xf8a295('0x259b')][_0xf8a295('0x1e6e')]({'fields':_0xf8a295('0xa10'),'sort':_0xf8a295('0x60a')})[_0xf8a295('0xe53')][_0xf8a295('0x683')](function(_0x10c9b0){const _0x37016a=_0xf8a295;_0x2fc771[_0x37016a('0xe01')]=_0x10c9b0[_0x37016a('0xf5d')]||[];})['then'](function(){const _0x2def17=_0xf8a295;return _0x32e5f3[_0x2def17('0x22df')]['get']({'userProfileId':_0x2fc771[_0x2def17('0x11ed')][_0x2def17('0x2f')],'sectionId':0x12d})[_0x2def17('0xe53')];})[_0xf8a295('0x683')](function(_0x52a391){const _0x55d9ea=_0xf8a295,_0x2e36d7=_0x52a391&&_0x52a391[_0x55d9ea('0xf5d')]?_0x52a391[_0x55d9ea('0xf5d')][0x0]:null;if(!_0x2e36d7){const _0x92d3bf=[];let _0x515beb=null;_0x2fc771[_0x55d9ea('0x1990')]&&(_0x515beb=_0x2e3ca0()['find'](_0x2fc771['lists'],{'id':Number(_0x2fc771['whatsappAccount']['ListId'])}));for(let _0x272e41=0x0;_0x272e41<_0x2fc771[_0x55d9ea('0xe01')][_0x55d9ea('0x1564')];_0x272e41++){_0x515beb&&_0x2fc771['lists'][_0x272e41]['id']===_0x515beb['id']&&(_0x2fc771[_0x55d9ea('0xe01')][_0x272e41][_0x55d9ea('0x319')]=![],_0x92d3bf[_0x55d9ea('0x1fd0')](_0x2fc771['lists'][_0x272e41]));}_0x2fc771[_0x55d9ea('0xe01')]=_0x92d3bf;}else{if(!_0x2e36d7[_0x55d9ea('0x170')])return _0x32e5f3[_0x55d9ea('0xcf7')][_0x55d9ea('0x1e6e')]({'sectionId':_0x2e36d7['id']})[_0x55d9ea('0xe53')][_0x55d9ea('0x683')](function(_0x125c80){const _0x291c3b=_0x55d9ea,_0x321630=_0x2e3ca0()[_0x291c3b('0x386')](_0x125c80['rows'],function(_0x2ffa56){const _0x155684=_0x291c3b;return _0x2e3ca0()[_0x155684('0x1c07')](_0x2fc771[_0x155684('0xe01')],{'id':_0x2ffa56['resourceId']});});let _0x49ef94=null;_0x2fc771['whatsappAccount']&&(_0x49ef94=_0x2e3ca0()[_0x291c3b('0x1c07')](_0x2fc771[_0x291c3b('0xe01')],{'id':Number(_0x2fc771[_0x291c3b('0x1990')][_0x291c3b('0x1e4f')])}));if(_0x49ef94&&!_0x2e3ca0()['some'](_0x321630,['id',_0x49ef94['id']])){const _0x970dd3=_0x2e3ca0()['find'](_0x2fc771['lists'],{'id':_0x49ef94['id']});_0x970dd3[_0x291c3b('0x319')]=![],_0x321630[_0x291c3b('0x1fd0')](_0x970dd3);}_0x2fc771['lists']=_0x321630;});}})['catch'](function(_0x4edca0){const _0x177d70=_0xf8a295;_0x2f4aad['error']({'title':_0x4edca0[_0x177d70('0x13ee')]?_0x177d70('0x2168')+_0x4edca0['status']+'\x20-\x20'+_0x4edca0[_0x177d70('0x24a9')]:_0x177d70('0x11e3'),'msg':_0x4edca0[_0x177d70('0x5a5')]?JSON[_0x177d70('0x258a')](_0x4edca0['data']):_0x4edca0[_0x177d70('0x1ff0')]()});}),_0x16a301[_0xf8a295('0xca1')](_0xf8a295('0x20c2'))?_0x32e5f3['pause']['get']({'fields':_0xf8a295('0x1688'),'sort':'name','nolimit':_0xf8a295('0x26ac')})[_0xf8a295('0xe53')][_0xf8a295('0x683')](function(_0x30066b){const _0x5d598f=_0xf8a295;_0x2fc771[_0x5d598f('0x22ab')]=_0x30066b[_0x5d598f('0xf5d')]||[];})['catch'](function(_0x392ea5){const _0x46f368=_0xf8a295;_0x2f4aad['error']({'title':_0x392ea5[_0x46f368('0x13ee')]?_0x46f368('0x2168')+_0x392ea5[_0x46f368('0x13ee')]+_0x46f368('0xbf6')+_0x392ea5[_0x46f368('0x24a9')]:_0x46f368('0x4ba'),'msg':_0x392ea5[_0x46f368('0x5a5')]?JSON[_0x46f368('0x258a')](_0x392ea5[_0x46f368('0x5a5')]):_0x392ea5[_0x46f368('0x1ff0')]()});}):_0x32e5f3[_0xf8a295('0xa4')][_0xf8a295('0x1e6e')]({'fields':_0xf8a295('0x1688'),'sort':'name','nolimit':_0xf8a295('0x26ac')})[_0xf8a295('0xe53')][_0xf8a295('0x683')](function(_0x6b9072){const _0x49617c=_0xf8a295;_0x2fc771[_0x49617c('0x22ab')]=_0x6b9072[_0x49617c('0xf5d')]||[];})[_0xf8a295('0x683')](function(){const _0x3c9f46=_0xf8a295;return _0x32e5f3['userProfileSection']['get']({'userProfileId':_0x2fc771[_0x3c9f46('0x11ed')][_0x3c9f46('0x2f')],'sectionId':0x3ed})['$promise'];})[_0xf8a295('0x683')](function(_0x28a9b4){const _0x276b0a=_0xf8a295,_0xb0ae83=_0x28a9b4&&_0x28a9b4[_0x276b0a('0xf5d')]?_0x28a9b4[_0x276b0a('0xf5d')][0x0]:null;if(!_0xb0ae83)_0x2fc771[_0x276b0a('0x22ab')]=[];else{if(!_0xb0ae83[_0x276b0a('0x170')])return _0x32e5f3['userProfileResource']['get']({'sectionId':_0xb0ae83['id']})[_0x276b0a('0xe53')][_0x276b0a('0x683')](function(_0x14d52c){const _0x1c08cd=_0x276b0a,_0x1c58b2=_0x2e3ca0()[_0x1c08cd('0x386')](_0x14d52c[_0x1c08cd('0xf5d')],function(_0x1ca30d){const _0x71b957=_0x1c08cd;return _0x2e3ca0()[_0x71b957('0x1c07')](_0x2fc771[_0x71b957('0x22ab')],{'id':_0x1ca30d[_0x71b957('0x832')]});});_0x2fc771['pauses'][_0x1c08cd('0x1299')](function(_0x4e71a1){const _0x57f75e=_0x1c08cd;!_0x2e3ca0()[_0x57f75e('0x7a2')](_0x1c58b2,['id',_0x4e71a1['id']])&&(_0x4e71a1[_0x57f75e('0x319')]=![]),_0x1c58b2[_0x57f75e('0x1fd0')](_0x4e71a1);}),_0x2fc771[_0x1c08cd('0x22ab')]=_0x1c58b2;});}})[_0xf8a295('0x130a')](function(_0x4bb4cf){const _0x56475f=_0xf8a295;_0x2f4aad[_0x56475f('0x52a')]({'title':_0x4bb4cf[_0x56475f('0x13ee')]?_0x56475f('0x2168')+_0x4bb4cf[_0x56475f('0x13ee')]+_0x56475f('0xbf6')+_0x4bb4cf[_0x56475f('0x24a9')]:_0x56475f('0xc45'),'msg':_0x4bb4cf[_0x56475f('0x5a5')]?JSON[_0x56475f('0x258a')](_0x4bb4cf[_0x56475f('0x5a5')]):_0x4bb4cf[_0x56475f('0x1ff0')]()});});function _0x474526(_0x27833b){const _0x36d923=_0xf8a295;_0x36888b['go'](_0x36d923('0xa29'),{'id':_0x27833b['id'],'whatsappAccount':_0x27833b,'crudPermissions':_0x2fc771[_0x36d923('0x1134')]});}function _0x8c7bec(_0x10c787){const _0x393284=_0xf8a295;_0x36888b['go'](_0x393284('0xa29'),{'id':_0x10c787['id'],'tab':0x5});}function _0x5b72ce(_0x41e626,_0x4f22e4){const _0x326096=_0xf8a295;_0x50770e['show']({'controller':_0x326096('0x57e'),'controllerAs':'vm','templateUrl':_0x19f450,'parent':angular[_0x326096('0x1fcc')](_0x28b126[_0x326096('0x18e5')]),'targetEvent':_0x4f22e4,'clickOutsideToClose':!![],'locals':{'whatsappAccount':_0x41e626,'whatsappAccounts':_0x2fc771[_0x326096('0x263c')]?_0x2fc771['whatsappAccounts'][_0x326096('0xf5d')]:[],'crudPermissions':_0x2fc771['crudPermissions'],'realtime':![]}});}function _0x5f36f1(_0x2ed52f,_0x4d4e39){const _0x260b7e=_0xf8a295,_0x42c22b=_0x50770e['confirm']()[_0x260b7e('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()[_0x260b7e('0x1e03')](_0x260b7e('0x1990'))+'?')[_0x260b7e('0x26e3')](''+(_0x2ed52f['name']||'whatsappAccount')+_0x260b7e('0x20f1')+_0x260b7e('0x1ee7'))['ariaLabel'](_0x260b7e('0x1887'))[_0x260b7e('0xe42')](_0x4d4e39)['ok']('OK')['cancel'](_0x260b7e('0x16b8'));_0x50770e[_0x260b7e('0x1d4')](_0x42c22b)[_0x260b7e('0x683')](function(){_0x8c1435(_0x2ed52f);},function(){const _0x4f932e=_0x260b7e;console[_0x4f932e('0x1b2b')](_0x4f932e('0x16b8'));});}let _0x392069=!![],_0x3bbf74=0x1;_0x32134e[_0xf8a295('0x186d')](_0xf8a295('0x1e1d'),function(_0x486dd9,_0x2b8d09){const _0x596dcd=_0xf8a295;_0x392069?_0x26ad1c(function(){_0x392069=![];}):(!_0x2b8d09&&(_0x3bbf74=_0x2fc771['query']['page']),_0x486dd9!==_0x2b8d09&&(_0x2fc771['query']['page']=0x1),!_0x486dd9&&(_0x2fc771[_0x596dcd('0x23a2')][_0x596dcd('0xdf8')]=_0x3bbf74),_0x2fc771[_0x596dcd('0x1fb9')]());});function _0x342731(_0x460ef0){const _0x58b447=_0xf8a295;_0x2fc771[_0x58b447('0x263c')]=_0x460ef0||{'count':0x0,'rows':[]};}function _0x15bfb0(){const _0x23e61e=_0xf8a295;_0x2fc771[_0x23e61e('0x23a2')][_0x23e61e('0x1cc8')]=(_0x2fc771['query'][_0x23e61e('0xdf8')]-0x1)*_0x2fc771[_0x23e61e('0x23a2')]['limit'],_0x16a301[_0x23e61e('0xca1')]('admin')?_0x2fc771[_0x23e61e('0x1883')]=_0x32e5f3['whatsappAccount']['get'](_0x2fc771[_0x23e61e('0x23a2')],_0x342731)['$promise']:(_0x2fc771[_0x23e61e('0x23a2')]['id']=_0x2fc771[_0x23e61e('0x2a')]['id'],_0x2fc771[_0x23e61e('0x23a2')][_0x23e61e('0x1aa')]=_0x23e61e('0x239b'),_0x2fc771['promise']=_0x32e5f3[_0x23e61e('0x2a')][_0x23e61e('0x241d')](_0x2fc771[_0x23e61e('0x23a2')],_0x342731)[_0x23e61e('0xe53')]);}function _0x4e1930(_0x59c30c,_0x3736b0){const _0x4d71b9=_0xf8a295;_0x50770e[_0x4d71b9('0x1d4')]({'controller':_0x4d71b9('0x1348'),'controllerAs':'vm','templateUrl':_0x5e1fca,'parent':angular[_0x4d71b9('0x1fcc')](_0x28b126[_0x4d71b9('0x18e5')]),'targetEvent':_0x59c30c,'clickOutsideToClose':!![],'locals':{'whatsappAccount':_0x3736b0,'whatsappAccounts':_0x2fc771['whatsappAccounts'][_0x4d71b9('0xf5d')],'license':_0x2fc771['license'],'setting':_0x2fc771[_0x4d71b9('0x260a')],'crudPermissions':_0x2fc771[_0x4d71b9('0x1134')]}});}function _0x8c1435(_0x13023a){const _0x5882b1=_0xf8a295;_0x32e5f3[_0x5882b1('0x1990')][_0x5882b1('0xd7e')]({'id':_0x13023a['id']})['$promise']['then'](function(){const _0x355578=_0x5882b1;_0x2e3ca0()[_0x355578('0x3ec')](_0x2fc771[_0x355578('0x263c')][_0x355578('0xf5d')],{'id':_0x13023a['id']}),_0x2fc771[_0x355578('0x263c')][_0x355578('0x50d')]-=0x1,!_0x2fc771[_0x355578('0x263c')][_0x355578('0xf5d')]['length']&&_0x2fc771[_0x355578('0x1fb9')](),_0x2f4aad['success']({'title':_0x2e3ca0()[_0x355578('0x1e03')]('WhatsappAccount')+_0x355578('0xbfc'),'msg':_0x13023a[_0x355578('0x60a')]?_0x13023a[_0x355578('0x60a')]+_0x355578('0x194d'):''});})[_0x5882b1('0x130a')](function(_0x110c76){const _0x2385b5=_0x5882b1;if(_0x110c76[_0x2385b5('0x5a5')]&&_0x110c76[_0x2385b5('0x5a5')][_0x2385b5('0x17f')]&&_0x110c76[_0x2385b5('0x5a5')][_0x2385b5('0x17f')][_0x2385b5('0x1564')]){_0x2fc771[_0x2385b5('0x17f')]=_0x110c76[_0x2385b5('0x5a5')][_0x2385b5('0x17f')]||[{'message':_0x110c76[_0x2385b5('0x1ff0')](),'type':_0x2385b5('0x285c')}];for(let _0x3f814a=0x0;_0x3f814a<_0x110c76[_0x2385b5('0x5a5')][_0x2385b5('0x17f')][_0x2385b5('0x1564')];_0x3f814a++){_0x2f4aad[_0x2385b5('0x52a')]({'title':_0x110c76['data'][_0x2385b5('0x17f')][_0x3f814a][_0x2385b5('0xcf0')],'msg':_0x110c76['data'][_0x2385b5('0x17f')][_0x3f814a]['message']});}}else _0x2f4aad[_0x2385b5('0x52a')]({'title':_0x110c76[_0x2385b5('0x13ee')]?_0x2385b5('0x2168')+_0x110c76['status']+_0x2385b5('0xbf6')+_0x110c76[_0x2385b5('0x24a9')]:_0x2385b5('0x285c'),'msg':_0x110c76['data']?JSON[_0x2385b5('0x258a')](_0x110c76[_0x2385b5('0x5a5')][_0x2385b5('0x8c2')]):_0x110c76[_0x2385b5('0x8c2')]||_0x110c76[_0x2385b5('0x1ff0')]()});});}function _0xb43c93(){const _0x2df4fc=_0xf8a295,_0x1ce4cb=angular[_0x2df4fc('0x1a86')](_0x2fc771[_0x2df4fc('0x1f00')]);return _0x2fc771['selectedWhatsappAccounts']=[],_0x1ce4cb;}function _0x33eb08(_0x52ff47){const _0x13aa8e=_0xf8a295,_0xe33a9e=_0x50770e['confirm']()[_0x13aa8e('0xf28')](_0x13aa8e('0x283e'))[_0x13aa8e('0x26e3')](_0x13aa8e('0xed5')+_0x2fc771[_0x13aa8e('0x1f00')][_0x13aa8e('0x1564')]+_0x13aa8e('0x93c')+'\x20will\x20be\x20deleted.')[_0x13aa8e('0x1040')](_0x13aa8e('0xb29'))[_0x13aa8e('0xe42')](_0x52ff47)['ok']('OK')[_0x13aa8e('0x19fb')](_0x13aa8e('0x16b8'));_0x50770e[_0x13aa8e('0x1d4')](_0xe33a9e)[_0x13aa8e('0x683')](function(){const _0x57ab22=_0x13aa8e;_0x2fc771['selectedWhatsappAccounts']['forEach'](function(_0x482543){_0x8c1435(_0x482543);}),_0x2fc771[_0x57ab22('0x1f00')]=[];});}function _0x27aa69(){const _0x240b34=_0xf8a295;_0x2fc771[_0x240b34('0x1f00')]=[];}function _0x5b8f87(){const _0x4456bc=_0xf8a295;_0x2fc771[_0x4456bc('0x1f00')]=_0x2fc771['whatsappAccounts'][_0x4456bc('0xf5d')];}}const _0x2a07d1=_0x30d28b;_0x2d875b['$inject']=['$scope',_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$q','$translate',_0x189033('0x1d70'),_0x189033('0xa4f'),_0x189033('0x25e5'),_0x189033('0x56b'),_0x189033('0xba1'),_0x189033('0xace'),'setting',_0x189033('0x1134')];function _0x2d875b(_0x2ce189,_0x9ebcec,_0xabdcff,_0x1d728b,_0x184a44,_0x182c9e,_0x40283c,_0x478dc0,_0xb8955f,_0x3a7567,_0x1ec496,_0x61676c,_0x78ad4,_0x1d4880){const _0x410ebb=_0x189033,_0x48ad7a=this;_0x48ad7a[_0x410ebb('0x11ed')]=_0x1ec496['getCurrentUser'](),_0x48ad7a[_0x410ebb('0x17f')]=[],_0x48ad7a[_0x410ebb('0x260a')]=_0x78ad4,_0x48ad7a[_0x410ebb('0xace')]=_0x61676c,_0x48ad7a[_0x410ebb('0x1134')]=_0x1d4880,_0x48ad7a[_0x410ebb('0x258d')]={},_0x48ad7a['passwordPattern']=_0x48ad7a[_0x410ebb('0x260a')]&&_0x48ad7a[_0x410ebb('0x260a')][_0x410ebb('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x48ad7a['title']=_0x410ebb('0x558'),_0x48ad7a[_0x410ebb('0x25e5')]=angular['copy'](_0xb8955f),_0x48ad7a['whatsappQueues']=_0x478dc0,_0x48ad7a[_0x410ebb('0x25ac')]=![];!_0x48ad7a[_0x410ebb('0x25e5')]&&(_0x48ad7a[_0x410ebb('0x25e5')]={'strategy':_0x410ebb('0x25ee'),'timeout':0xa},_0x48ad7a['title']=_0x410ebb('0x18b5'),_0x48ad7a[_0x410ebb('0x25ac')]=!![]);_0x48ad7a[_0x410ebb('0x2025')]=_0x13198b,_0x48ad7a[_0x410ebb('0x484')]=_0x2c6255,_0x48ad7a[_0x410ebb('0x1022')]=_0x44afda,_0x48ad7a['getDateFromString']=_0x2103c6,_0x48ad7a[_0x410ebb('0xf82')]=_0x2a69cc;function _0x13198b(){const _0x225baa=_0x410ebb;_0x48ad7a[_0x225baa('0x17f')]=[],_0x3a7567['whatsappQueue'][_0x225baa('0xb0a')](_0x48ad7a[_0x225baa('0x25e5')])[_0x225baa('0xe53')][_0x225baa('0x683')](function(_0x507a20){const _0x56bbc2=_0x225baa;_0x48ad7a['whatsappQueues']['unshift'](_0x507a20[_0x56bbc2('0x24e1')]()),_0x40283c[_0x56bbc2('0x53')]({'title':_0x56bbc2('0x2869'),'msg':_0x48ad7a[_0x56bbc2('0x25e5')][_0x56bbc2('0x60a')]?_0x48ad7a[_0x56bbc2('0x25e5')][_0x56bbc2('0x60a')]+'\x20has\x20been\x20created!':''}),_0x2a69cc(_0x507a20);})[_0x225baa('0x130a')](function(_0x5a2fdb){const _0x98e4e2=_0x225baa;if(_0x5a2fdb['data']&&_0x5a2fdb['data'][_0x98e4e2('0x17f')]&&_0x5a2fdb[_0x98e4e2('0x5a5')][_0x98e4e2('0x17f')][_0x98e4e2('0x1564')]){_0x48ad7a[_0x98e4e2('0x17f')]=_0x5a2fdb['data'][_0x98e4e2('0x17f')]||[{'message':_0x5a2fdb[_0x98e4e2('0x1ff0')](),'type':_0x98e4e2('0xcce')}];for(let _0x59f4b4=0x0;_0x59f4b4<_0x5a2fdb[_0x98e4e2('0x5a5')]['errors']['length'];_0x59f4b4+=0x1){_0x40283c['error']({'title':_0x5a2fdb['data'][_0x98e4e2('0x17f')][_0x59f4b4][_0x98e4e2('0xcf0')],'msg':_0x5a2fdb[_0x98e4e2('0x5a5')][_0x98e4e2('0x17f')][_0x59f4b4][_0x98e4e2('0x8c2')]});}}else _0x40283c[_0x98e4e2('0x52a')]({'title':_0x5a2fdb[_0x98e4e2('0x13ee')]?_0x98e4e2('0x2168')+_0x5a2fdb[_0x98e4e2('0x13ee')]+_0x98e4e2('0xbf6')+_0x5a2fdb[_0x98e4e2('0x24a9')]:_0x98e4e2('0xcce'),'msg':_0x5a2fdb[_0x98e4e2('0x5a5')]?JSON['stringify'](_0x5a2fdb[_0x98e4e2('0x5a5')][_0x98e4e2('0x8c2')]):_0x5a2fdb[_0x98e4e2('0x1ff0')]()});});}function _0x2c6255(){const _0x19e883=_0x410ebb;_0x48ad7a[_0x19e883('0x17f')]=[],_0x3a7567[_0x19e883('0x25e5')][_0x19e883('0x2480')]({'id':_0x48ad7a['whatsappQueue']['id']},_0x48ad7a['whatsappQueue'])[_0x19e883('0xe53')][_0x19e883('0x683')](function(_0xf6cf7d){const _0xf1721a=_0x19e883,_0x47ec93=_0x2e3ca0()[_0xf1721a('0x1c07')](_0x48ad7a[_0xf1721a('0xa4f')],{'id':_0xf6cf7d['id']});_0x47ec93&&_0x2e3ca0()[_0xf1721a('0xf22')](_0x47ec93,_0x2e3ca0()[_0xf1721a('0x24d0')](_0xf6cf7d['toJSON'](),_0x2e3ca0()[_0xf1721a('0x55e')](_0x47ec93))),_0x40283c['success']({'title':'WhatsappQueue\x20properly\x20saved!','msg':_0x48ad7a[_0xf1721a('0x25e5')][_0xf1721a('0x60a')]?_0x48ad7a[_0xf1721a('0x25e5')][_0xf1721a('0x60a')]+_0xf1721a('0xf59'):''}),_0x2a69cc(_0xf6cf7d);})['catch'](function(_0x14a004){const _0x4b6d12=_0x19e883;if(_0x14a004[_0x4b6d12('0x5a5')]&&_0x14a004['data'][_0x4b6d12('0x17f')]&&_0x14a004[_0x4b6d12('0x5a5')][_0x4b6d12('0x17f')][_0x4b6d12('0x1564')]){_0x48ad7a[_0x4b6d12('0x17f')]=_0x14a004['data'][_0x4b6d12('0x17f')]||[{'message':_0x14a004[_0x4b6d12('0x1ff0')](),'type':_0x4b6d12('0x7ba')}];for(let _0x2e8e7f=0x0;_0x2e8e7f<_0x14a004['data'][_0x4b6d12('0x17f')]['length'];_0x2e8e7f++){_0x40283c[_0x4b6d12('0x52a')]({'title':_0x14a004[_0x4b6d12('0x5a5')][_0x4b6d12('0x17f')][_0x2e8e7f][_0x4b6d12('0xcf0')],'msg':_0x14a004['data']['errors'][_0x2e8e7f]['message']});}}else _0x40283c[_0x4b6d12('0x52a')]({'title':_0x14a004[_0x4b6d12('0x13ee')]?_0x4b6d12('0x2168')+_0x14a004[_0x4b6d12('0x13ee')]+_0x4b6d12('0xbf6')+_0x14a004['statusText']:_0x4b6d12('0x7ba'),'msg':_0x14a004['data']?JSON[_0x4b6d12('0x258a')](_0x14a004[_0x4b6d12('0x5a5')]['message']):_0x14a004['toString']()});});}function _0x44afda(_0x42b73f){const _0x8cf552=_0x410ebb;_0x48ad7a[_0x8cf552('0x17f')]=[];const _0x57d360=_0x1d728b[_0x8cf552('0x1c6f')]()['title'](_0x8cf552('0x4d'))[_0x8cf552('0xa6a')](_0x8cf552('0x603'))[_0x8cf552('0x1040')]('Delete\x20WhatsappQueue')['ok'](_0x8cf552('0x2307'))['cancel']('Cancel')[_0x8cf552('0xe42')](_0x42b73f);_0x1d728b[_0x8cf552('0x1d4')](_0x57d360)[_0x8cf552('0x683')](function(){const _0x324cc6=_0x8cf552;_0x3a7567[_0x324cc6('0x25e5')][_0x324cc6('0xd7e')]({'id':_0x48ad7a[_0x324cc6('0x25e5')]['id']})[_0x324cc6('0xe53')][_0x324cc6('0x683')](function(){const _0x5e5475=_0x324cc6;_0x2e3ca0()['remove'](_0x48ad7a[_0x5e5475('0xa4f')],{'id':_0x48ad7a[_0x5e5475('0x25e5')]['id']}),_0x40283c[_0x5e5475('0x53')]({'title':_0x5e5475('0x1a38'),'msg':(_0x48ad7a[_0x5e5475('0x25e5')][_0x5e5475('0x60a')]||_0x5e5475('0x25e5'))+'\x20has\x20been\x20deleted!'}),_0x2a69cc(_0x48ad7a[_0x5e5475('0x25e5')]);})[_0x324cc6('0x130a')](function(_0x44c9d4){const _0x5a0db8=_0x324cc6;if(_0x44c9d4[_0x5a0db8('0x5a5')]&&_0x44c9d4['data'][_0x5a0db8('0x17f')]&&_0x44c9d4['data'][_0x5a0db8('0x17f')][_0x5a0db8('0x1564')]){_0x48ad7a[_0x5a0db8('0x17f')]=_0x44c9d4[_0x5a0db8('0x5a5')][_0x5a0db8('0x17f')]||[{'message':_0x44c9d4['toString'](),'type':'api.whatsappQueue.delete'}];for(let _0x37c409=0x0;_0x37c409<_0x44c9d4[_0x5a0db8('0x5a5')][_0x5a0db8('0x17f')][_0x5a0db8('0x1564')];_0x37c409++){_0x40283c['error']({'title':_0x44c9d4['data']['errors'][_0x37c409][_0x5a0db8('0xcf0')],'msg':_0x44c9d4[_0x5a0db8('0x5a5')][_0x5a0db8('0x17f')][_0x37c409][_0x5a0db8('0x8c2')]});}}else _0x40283c['error']({'title':_0x44c9d4[_0x5a0db8('0x13ee')]?_0x5a0db8('0x2168')+_0x44c9d4[_0x5a0db8('0x13ee')]+_0x5a0db8('0xbf6')+_0x44c9d4[_0x5a0db8('0x24a9')]:_0x5a0db8('0x25aa'),'msg':_0x44c9d4[_0x5a0db8('0x5a5')]?JSON[_0x5a0db8('0x258a')](_0x44c9d4['data'][_0x5a0db8('0x8c2')]):_0x44c9d4[_0x5a0db8('0x8c2')]||_0x44c9d4[_0x5a0db8('0x1ff0')]()});});},function(){});}function _0x2103c6(_0x53079a){return _0x53079a===null?undefined:new Date(_0x53079a);}function _0x2a69cc(_0x3093dc){const _0x4e3fd3=_0x410ebb;_0x1d728b[_0x4e3fd3('0x1715')](_0x3093dc);}}const _0x3119ed=_0x2d875b;_0x90f2d4['$inject']=['$mdDialog','$q',_0x189033('0x1d70'),'api',_0x189033('0x25e5'),_0x189033('0xa4f'),_0x189033('0x2c9'),_0x189033('0x1d08'),'Auth',_0x189033('0x1134')];function _0x90f2d4(_0x3054e6,_0x4288d8,_0x31b96e,_0x2ab9d8,_0x395b90,_0x35088b,_0x1584ee,_0x5074ef,_0x223e87,_0x48e0f2){const _0x3ea8b4=_0x189033,_0x264372=this;_0x264372[_0x3ea8b4('0x11ed')]=_0x223e87[_0x3ea8b4('0x20b2')](),_0x264372[_0x3ea8b4('0x25e5')]=_0x395b90,_0x264372[_0x3ea8b4('0x1134')]=_0x48e0f2,_0x264372[_0x3ea8b4('0x2c9')]=_0x1584ee,_0x264372[_0x3ea8b4('0x1996')]=[],_0x264372[_0x3ea8b4('0x1c47')]=[],_0x264372[_0x3ea8b4('0x1378')]=[],_0x264372[_0x3ea8b4('0x125e')]=[],_0x264372[_0x3ea8b4('0x23a7')]=[],_0x264372['pendingChanges']=![],_0x264372[_0x3ea8b4('0x1dd2')]=_0x52a0cf,_0x264372[_0x3ea8b4('0xa5f')]=_0x2c2722,_0x264372[_0x3ea8b4('0xf82')]=_0xcd6fb,_0x264372[_0x3ea8b4('0x169f')]={'readOnly':!_0x264372[_0x3ea8b4('0x1134')]['canEdit'],'items':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x3ea8b4('0x11bc'),'line2':[_0x3ea8b4('0x60a'),_0x3ea8b4('0x1d43')],'line3':'','labelAll':_0x5074ef[_0x3ea8b4('0x2728')](_0x3ea8b4('0x1e5a')),'labelSelected':_0x5074ef[_0x3ea8b4('0x2728')](_0x3ea8b4('0x2803')),'transferCallback':function(){const _0x4204ea=_0x3ea8b4,_0x177ecc=_0x2e3ca0()[_0x4204ea('0x25cb')](_0x264372[_0x4204ea('0x23a7')],_0x264372[_0x4204ea('0x1378')],'id');_0x264372[_0x4204ea('0x2106')]=_0x2e3ca0()[_0x4204ea('0x173f')](_0x177ecc)?![]:!![];}};function _0x52a0cf(){const _0x1da62a=_0x3ea8b4;return _0x223e87['hasRole'](_0x1da62a('0x20c2'))?_0x137705()['catch'](function(_0x8de744){const _0x26efce=_0x1da62a;_0x31b96e[_0x26efce('0x52a')]({'title':_0x8de744[_0x26efce('0x13ee')]?_0x26efce('0x2168')+_0x8de744['status']+_0x26efce('0xbf6')+_0x8de744[_0x26efce('0x24a9')]:_0x26efce('0x144f'),'msg':_0x8de744[_0x26efce('0x13ee')]?JSON[_0x26efce('0x258a')](_0x8de744[_0x26efce('0x5a5')]):_0x8de744[_0x26efce('0x1ff0')]()});}):_0x3beff3()[_0x1da62a('0x683')](function(_0x1adeb9){const _0x58c199=_0x1da62a;return _0x264372[_0x58c199('0x1aa')]=_0x1adeb9,_0x137705();})[_0x1da62a('0x130a')](function(_0x3b0527){const _0x1bea69=_0x1da62a;_0x31b96e['error']({'title':_0x3b0527[_0x1bea69('0x13ee')]?_0x1bea69('0x2168')+_0x3b0527[_0x1bea69('0x13ee')]+_0x1bea69('0xbf6')+_0x3b0527['statusText']:_0x1bea69('0x144f'),'msg':_0x3b0527[_0x1bea69('0x13ee')]?JSON['stringify'](_0x3b0527[_0x1bea69('0x5a5')]):_0x3b0527[_0x1bea69('0x1ff0')]()});});}function _0x3beff3(){return _0x4288d8(function(_0x5bf01f,_0x48a42b){const _0x1ff905=a0_0x4e0a;_0x2ab9d8[_0x1ff905('0x22df')][_0x1ff905('0x1e6e')]({'userProfileId':_0x264372[_0x1ff905('0x11ed')][_0x1ff905('0x2f')],'name':_0x1ff905('0x1bc0')})['$promise'][_0x1ff905('0x683')](function(_0x26a340){const _0x55067d=_0x1ff905,_0x1737aa=_0x26a340&&_0x26a340[_0x55067d('0xf5d')]?_0x26a340['rows'][0x0]:null;_0x5bf01f(_0x1737aa);})['catch'](function(_0x13408e){_0x48a42b(_0x13408e);});});}function _0x137705(){return _0x4288d8(function(_0x4e5995,_0x1069d7){const _0x335ffe=a0_0x4e0a;return _0x2ba62e()['then'](function(_0x43bbdb){const _0x2526df=a0_0x4e0a;return _0x264372[_0x2526df('0x1996')]=_0x43bbdb['rows']?_0x43bbdb['rows']:[],_0x223e87['hasRole']('admin')?_0x43bbdb:_0x264372['section']?_0x264372['section'][_0x2526df('0x170')]?_0x43bbdb:_0x32126b():null;})[_0x335ffe('0x683')](function(_0x3a7dff){const _0x753005=_0x335ffe,_0x1a9743=_0x3a7dff&&_0x3a7dff[_0x753005('0xf5d')]?_0x3a7dff[_0x753005('0xf5d')]:[];return _0x264372[_0x753005('0x1c47')]=_0x2e3ca0()[_0x753005('0x386')](_0x1a9743,function(_0x11e374){const _0x244a79=_0x753005;return _0x2e3ca0()[_0x244a79('0x1c07')](_0x264372[_0x244a79('0x1996')],{'id':_0x223e87[_0x244a79('0xca1')](_0x244a79('0x20c2'))||_0x264372[_0x244a79('0x1aa')][_0x244a79('0x170')]?_0x11e374['id']:_0x11e374[_0x244a79('0x832')]});}),_0x264372['startingAllowedItems']=angular[_0x753005('0x1a86')](_0x264372['allowedItems']),_0x264372['items'][_0x753005('0x1299')](function(_0x1cba92){const _0x45769b=_0x753005,_0x4cf227=_0x2e3ca0()[_0x45769b('0x1c07')](_0x264372['allowedItems'],{'id':_0x1cba92['id']});_0x223e87[_0x45769b('0xca1')](_0x45769b('0x20c2'))?_0x1cba92[_0x45769b('0x24f4')]=!![]:_0x1cba92[_0x45769b('0x24f4')]=typeof _0x4cf227!==_0x45769b('0x1867')?!![]:![];}),_0x2f0262();})[_0x335ffe('0x683')](function(_0x2a3063){const _0x5678ea=_0x335ffe,_0x31b11d=_0x2a3063&&_0x2a3063[_0x5678ea('0xf5d')]?_0x2a3063['rows']:[];_0x264372[_0x5678ea('0x1378')]=_0x2e3ca0()[_0x5678ea('0x386')](_0x31b11d,function(_0x401324){const _0x560318=_0x5678ea,_0x43d622=_0x2e3ca0()[_0x560318('0x1c07')](_0x264372[_0x560318('0x1996')],{'id':_0x401324['id']});return _0x43d622[_0x560318('0x1e2a')]=_0x401324[_0x560318('0xcb2')]?_0x560318('0x23d0')+_0x401324[_0x560318('0xcb2')][_0x560318('0x1e2a')]:'',_0x43d622[_0x560318('0x1d43')]=typeof _0x401324[_0x560318('0x1d43')]!==_0x560318('0x1867')?'<'+_0x401324[_0x560318('0x1d43')]+'>':'',_0x43d622;}),_0x264372[_0x5678ea('0x23a7')]=angular[_0x5678ea('0x1a86')](_0x264372[_0x5678ea('0x1378')]),_0x264372[_0x5678ea('0x169f')]['selectedItems']=_0x264372[_0x5678ea('0x1378')],_0x264372[_0x5678ea('0x169f')][_0x5678ea('0x1996')]=_0x2e3ca0()[_0x5678ea('0x461')](_0x264372[_0x5678ea('0x1c47')],_0x264372[_0x5678ea('0x169f')][_0x5678ea('0x1378')],'id'),_0x4e5995();})['catch'](function(_0xa171f7){_0x1069d7(_0xa171f7);});});}function _0x32126b(){return _0x4288d8(function(_0x3b1181,_0x3f94f7){const _0x3f2fb6=a0_0x4e0a;return _0x2ab9d8[_0x3f2fb6('0xcf7')][_0x3f2fb6('0x1e6e')]({'sectionId':_0x264372[_0x3f2fb6('0x1aa')]['id'],'nolimit':!![]})[_0x3f2fb6('0xe53')][_0x3f2fb6('0x683')](function(_0x561f0e){_0x3b1181(_0x561f0e);})[_0x3f2fb6('0x130a')](function(_0x29850b){_0x3f94f7(_0x29850b);});});}function _0x2f0262(){return _0x4288d8(function(_0x147fac,_0x16f576){const _0x323c66=a0_0x4e0a;return _0x2ab9d8[_0x323c66('0x25e5')]['getAgents']({'id':_0x264372['whatsappQueue']['id'],'fields':'id,name,internal,fullname','nolimit':!![],'role':'agent'})['$promise'][_0x323c66('0x683')](function(_0x185f60){_0x147fac(_0x185f60);})[_0x323c66('0x130a')](function(_0x2c5509){_0x16f576(_0x2c5509);});});}function _0x2ba62e(){return _0x4288d8(function(_0x2ee309,_0x255ad9){const _0x2bb4b1=a0_0x4e0a;return _0x2ab9d8[_0x2bb4b1('0xc96')][_0x2bb4b1('0x1e6e')]({'fields':_0x2bb4b1('0x72b'),'nolimit':!![],'role':'agent'})[_0x2bb4b1('0xe53')][_0x2bb4b1('0x683')](function(_0x1c4e76){_0x2ee309(_0x1c4e76);})[_0x2bb4b1('0x130a')](function(_0x1a8538){_0x255ad9(_0x1a8538);});});}function _0x1a798b(_0x11afbd){return _0x4288d8(function(_0x3aaaac,_0x1d240f){const _0x55dfc6=a0_0x4e0a;_0x2e3ca0()[_0x55dfc6('0x173f')](_0x11afbd)?_0x3aaaac():_0x2ab9d8[_0x55dfc6('0x25e5')][_0x55dfc6('0x2179')]({'id':_0x264372[_0x55dfc6('0x25e5')]['id'],'ids':_0x2e3ca0()[_0x55dfc6('0x386')](_0x11afbd,'id')})[_0x55dfc6('0xe53')][_0x55dfc6('0x683')](function(){_0x3aaaac();})[_0x55dfc6('0x130a')](function(_0x4901dd){_0x1d240f(_0x4901dd);});});}function _0x48f7e8(_0x15980c){return _0x4288d8(function(_0x2326ba,_0xbd8e12){const _0x33b4c2=a0_0x4e0a;_0x2e3ca0()[_0x33b4c2('0x173f')](_0x15980c)?_0x2326ba():_0x2ab9d8[_0x33b4c2('0x25e5')][_0x33b4c2('0xf9')]({'id':_0x264372[_0x33b4c2('0x25e5')]['id'],'ids':_0x2e3ca0()[_0x33b4c2('0x386')](_0x15980c,'id')})[_0x33b4c2('0xe53')][_0x33b4c2('0x683')](function(){_0x2326ba();})['catch'](function(_0x43a6da){_0xbd8e12(_0x43a6da);});});}function _0x2c2722(){const _0x5a74df=_0x3ea8b4,_0x3ae9fc=_0x2e3ca0()['differenceBy'](_0x264372['startingSelectedItems'],_0x264372[_0x5a74df('0x1378')],'id'),_0x3d2dce=_0x2e3ca0()['differenceBy'](_0x264372[_0x5a74df('0x1378')],_0x264372[_0x5a74df('0x23a7')],'id');return _0x48f7e8(_0x3ae9fc)[_0x5a74df('0x683')](function(){return _0x1a798b(_0x3d2dce);})[_0x5a74df('0x683')](function(){const _0x40e0cd=_0x5a74df;_0x264372[_0x40e0cd('0x2106')]=![],_0x264372[_0x40e0cd('0x125e')]=angular[_0x40e0cd('0x1a86')](_0x264372[_0x40e0cd('0x1c47')]),_0x264372['startingSelectedItems']=angular[_0x40e0cd('0x1a86')](_0x264372['selectedItems']),_0x31b96e[_0x40e0cd('0x53')]({'title':_0x40e0cd('0xd28'),'msg':_0x40e0cd('0x89d')});})[_0x5a74df('0x130a')](function(_0xf2da37){const _0x53c7c7=_0x5a74df;_0x31b96e[_0x53c7c7('0x52a')]({'title':_0xf2da37[_0x53c7c7('0x13ee')]?_0x53c7c7('0x2168')+_0xf2da37[_0x53c7c7('0x13ee')]+'\x20-\x20'+_0xf2da37[_0x53c7c7('0x24a9')]:_0x53c7c7('0x1b71'),'msg':_0xf2da37[_0x53c7c7('0x13ee')]?JSON[_0x53c7c7('0x258a')](_0xf2da37['data']):_0xf2da37[_0x53c7c7('0x1ff0')]()});});}function _0xcd6fb(){const _0x2abaf9=_0x3ea8b4;_0x3054e6[_0x2abaf9('0x1715')]();}}const _0x25d608=_0x90f2d4;_0x9f2c6d[_0x189033('0x14be')]=[_0x189033('0x1e48'),'$q',_0x189033('0x1d70'),_0x189033('0x56b'),_0x189033('0x25e5'),_0x189033('0x1d08'),_0x189033('0xba1'),'crudPermissions'];function _0x9f2c6d(_0x5b44c8,_0x4ccd08,_0x3d3fc3,_0x5ecde3,_0x3e56ee,_0x6a6b43,_0x469807,_0x1cc290){const _0x59a3c2=_0x189033,_0x3049eb=this;_0x3049eb['currentUser']=_0x469807[_0x59a3c2('0x20b2')](),_0x3049eb['whatsappQueue']=_0x3e56ee,_0x3049eb[_0x59a3c2('0x1134')]=_0x1cc290,_0x3049eb[_0x59a3c2('0x1996')]=[],_0x3049eb['allowedItems']=[],_0x3049eb['selectedItems']=[],_0x3049eb[_0x59a3c2('0x125e')]=[],_0x3049eb['startingSelectedItems']=[],_0x3049eb[_0x59a3c2('0x2106')]=![],_0x3049eb[_0x59a3c2('0x169f')]={'readOnly':!_0x3049eb[_0x59a3c2('0x1134')]['canEdit'],'allowedItems':[],'selectedItems':[],'showSelectAndDeselectAll':!![],'orderBy':'name','line1':_0x59a3c2('0x60a'),'line2':'','line3':'','labelAll':_0x6a6b43[_0x59a3c2('0x2728')]('WHATSAPP.ALL_TEAMS'),'labelSelected':_0x6a6b43[_0x59a3c2('0x2728')](_0x59a3c2('0x1f22')),'transferCallback':function(){const _0x58f629=_0x59a3c2,_0xa8d46f=_0x2e3ca0()[_0x58f629('0x25cb')](_0x3049eb['startingSelectedItems'],_0x3049eb['selectedItems'],'id');_0x3049eb[_0x58f629('0x2106')]=_0x2e3ca0()['isEmpty'](_0xa8d46f)?![]:!![];}},_0x3049eb[_0x59a3c2('0x1dd2')]=_0xba6dfe,_0x3049eb[_0x59a3c2('0x1a89')]=_0x5acafd,_0x3049eb[_0x59a3c2('0xf82')]=_0x199efc;function _0xba6dfe(){const _0xda9b20=_0x59a3c2;return _0x469807[_0xda9b20('0xca1')](_0xda9b20('0x20c2'))?_0x583018()['catch'](function(_0x1f8266){const _0x49f61c=_0xda9b20;_0x3d3fc3['error']({'title':_0x1f8266['status']?'API:'+_0x1f8266['status']+_0x49f61c('0xbf6')+_0x1f8266[_0x49f61c('0x24a9')]:_0x49f61c('0x1820'),'msg':_0x1f8266[_0x49f61c('0x13ee')]?JSON['stringify'](_0x1f8266[_0x49f61c('0x5a5')]):_0x1f8266[_0x49f61c('0x1ff0')]()});}):_0x53f69e()[_0xda9b20('0x683')](function(_0x3857a7){const _0x3a269c=_0xda9b20;return _0x3049eb[_0x3a269c('0x1aa')]=_0x3857a7,_0x583018();})[_0xda9b20('0x130a')](function(_0x4968b6){const _0x2abd9e=_0xda9b20;_0x3d3fc3[_0x2abd9e('0x52a')]({'title':_0x4968b6[_0x2abd9e('0x13ee')]?_0x2abd9e('0x2168')+_0x4968b6['status']+_0x2abd9e('0xbf6')+_0x4968b6[_0x2abd9e('0x24a9')]:_0x2abd9e('0x1820'),'msg':_0x4968b6['status']?JSON[_0x2abd9e('0x258a')](_0x4968b6['data']):_0x4968b6[_0x2abd9e('0x1ff0')]()});});}function _0x53f69e(){return _0x4ccd08(function(_0x88eea,_0x291cb2){const _0x38d282=a0_0x4e0a;_0x5ecde3['userProfileSection'][_0x38d282('0x1e6e')]({'userProfileId':_0x3049eb[_0x38d282('0x11ed')][_0x38d282('0x2f')],'name':'Teams'})['$promise']['then'](function(_0x2c6863){const _0x1cbe41=_0x38d282,_0x30d4b7=_0x2c6863&&_0x2c6863[_0x1cbe41('0xf5d')]?_0x2c6863[_0x1cbe41('0xf5d')][0x0]:null;_0x88eea(_0x30d4b7);})[_0x38d282('0x130a')](function(_0xb87041){_0x291cb2(_0xb87041);});});}function _0x583018(){return _0x4ccd08(function(_0x1dd83d,_0x3974e8){const _0x29efc3=a0_0x4e0a;return _0x304aee()[_0x29efc3('0x683')](function(_0x235541){const _0x5693fa=_0x29efc3;return _0x3049eb['items']=_0x235541[_0x5693fa('0xf5d')]?_0x235541['rows']:[],_0x469807[_0x5693fa('0xca1')]('admin')?_0x235541:_0x3049eb[_0x5693fa('0x1aa')]?_0x3049eb[_0x5693fa('0x1aa')]['autoAssociation']?_0x235541:_0x2fd41f():null;})[_0x29efc3('0x683')](function(_0x480515){const _0x5efe28=_0x29efc3,_0xec21b7=_0x480515&&_0x480515[_0x5efe28('0xf5d')]?_0x480515[_0x5efe28('0xf5d')]:[];return _0x3049eb[_0x5efe28('0x1c47')]=_0x2e3ca0()[_0x5efe28('0x386')](_0xec21b7,function(_0x3b36d6){const _0x3289bb=_0x5efe28;return _0x2e3ca0()['find'](_0x3049eb['items'],{'id':_0x469807[_0x3289bb('0xca1')]('admin')||_0x3049eb[_0x3289bb('0x1aa')][_0x3289bb('0x170')]?_0x3b36d6['id']:_0x3b36d6[_0x3289bb('0x832')]});}),_0x3049eb['items'][_0x5efe28('0x1299')](function(_0x1b4750){const _0x293db3=_0x5efe28,_0x5466d2=_0x2e3ca0()['find'](_0x3049eb[_0x293db3('0x1c47')],{'id':_0x1b4750['id']});_0x469807[_0x293db3('0xca1')](_0x293db3('0x20c2'))?_0x1b4750[_0x293db3('0x24f4')]=!![]:_0x1b4750[_0x293db3('0x24f4')]=typeof _0x5466d2!==_0x293db3('0x1867')?!![]:![];}),_0x4d00d8();})[_0x29efc3('0x683')](function(_0x3be981){const _0xe57565=_0x29efc3,_0x195c30=_0x3be981&&_0x3be981[_0xe57565('0xf5d')]?_0x3be981[_0xe57565('0xf5d')]:[];_0x3049eb[_0xe57565('0x1378')]=_0x2e3ca0()[_0xe57565('0x386')](_0x195c30,function(_0x318703){const _0x276287=_0xe57565;return _0x2e3ca0()[_0x276287('0x1c07')](_0x3049eb[_0x276287('0x1996')],{'id':_0x318703['id']});}),_0x3049eb['startingSelectedItems']=angular['copy'](_0x3049eb[_0xe57565('0x1378')]),_0x3049eb[_0xe57565('0x169f')]['selectedItems']=_0x3049eb[_0xe57565('0x1378')],_0x3049eb[_0xe57565('0x169f')][_0xe57565('0x1996')]=_0x2e3ca0()[_0xe57565('0x461')](_0x3049eb['allowedItems'],_0x3049eb[_0xe57565('0x169f')][_0xe57565('0x1378')],'id'),_0x1dd83d();})['catch'](function(_0x2b4779){_0x3974e8(_0x2b4779);});});}function _0x2fd41f(){return _0x4ccd08(function(_0x5d8a0d,_0x360f6d){const _0x1c86f4=a0_0x4e0a;return _0x5ecde3[_0x1c86f4('0xcf7')][_0x1c86f4('0x1e6e')]({'sectionId':_0x3049eb[_0x1c86f4('0x1aa')]['id'],'nolimit':!![]})[_0x1c86f4('0xe53')]['then'](function(_0x572d1d){_0x5d8a0d(_0x572d1d);})[_0x1c86f4('0x130a')](function(_0x457aff){_0x360f6d(_0x457aff);});});}function _0x4d00d8(){return _0x4ccd08(function(_0x11d415,_0x3ee32d){const _0x2336fe=a0_0x4e0a;return _0x5ecde3[_0x2336fe('0x25e5')][_0x2336fe('0xf90')]({'id':_0x3049eb[_0x2336fe('0x25e5')]['id'],'fields':_0x2336fe('0xa10'),'nolimit':!![]})[_0x2336fe('0xe53')]['then'](function(_0x51bb46){_0x11d415(_0x51bb46);})[_0x2336fe('0x130a')](function(_0x13bdb4){_0x3ee32d(_0x13bdb4);});});}function _0x304aee(){return _0x4ccd08(function(_0x2bd279,_0x180961){const _0x4e2733=a0_0x4e0a;return _0x5ecde3[_0x4e2733('0xd88')]['get']({'fields':_0x4e2733('0xa10'),'nolimit':!![]})[_0x4e2733('0xe53')][_0x4e2733('0x683')](function(_0x18cc09){_0x2bd279(_0x18cc09);})['catch'](function(_0x5e69ee){_0x180961(_0x5e69ee);});});}function _0x5e5bf7(_0x1065d9){return _0x4ccd08(function(_0x50090f,_0x29d61b){const _0x197dfe=a0_0x4e0a;_0x2e3ca0()[_0x197dfe('0x173f')](_0x1065d9)?_0x50090f():_0x5ecde3['whatsappQueue'][_0x197dfe('0x1558')]({'id':_0x3049eb[_0x197dfe('0x25e5')]['id'],'ids':_0x2e3ca0()[_0x197dfe('0x386')](_0x1065d9,'id')})['$promise']['then'](function(){_0x50090f();})[_0x197dfe('0x130a')](function(_0x1188dd){_0x29d61b(_0x1188dd);});});}function _0x550116(_0x549402){return _0x4ccd08(function(_0x342a0c,_0x4da373){const _0x1a1d88=a0_0x4e0a;_0x2e3ca0()[_0x1a1d88('0x173f')](_0x549402)?_0x342a0c():_0x5ecde3[_0x1a1d88('0x25e5')][_0x1a1d88('0x2521')]({'id':_0x3049eb['whatsappQueue']['id'],'ids':_0x2e3ca0()[_0x1a1d88('0x386')](_0x549402,'id')})[_0x1a1d88('0xe53')][_0x1a1d88('0x683')](function(){_0x342a0c();})[_0x1a1d88('0x130a')](function(_0x4843d8){_0x4da373(_0x4843d8);});});}function _0x5acafd(){const _0x15ff89=_0x59a3c2,_0x175391=_0x2e3ca0()['differenceBy'](_0x3049eb[_0x15ff89('0x23a7')],_0x3049eb[_0x15ff89('0x1378')],'id'),_0x2a261c=_0x2e3ca0()[_0x15ff89('0x461')](_0x3049eb['selectedItems'],_0x3049eb[_0x15ff89('0x23a7')],'id');return _0x550116(_0x175391)[_0x15ff89('0x683')](function(){return _0x5e5bf7(_0x2a261c);})['then'](function(){const _0x57d3b4=_0x15ff89;_0x3049eb[_0x57d3b4('0x2106')]=![],_0x3049eb[_0x57d3b4('0x125e')]=angular[_0x57d3b4('0x1a86')](_0x3049eb[_0x57d3b4('0x1c47')]),_0x3049eb['startingSelectedItems']=angular[_0x57d3b4('0x1a86')](_0x3049eb[_0x57d3b4('0x1378')]),_0x3d3fc3['success']({'title':_0x57d3b4('0xd28'),'msg':_0x57d3b4('0x476')});})[_0x15ff89('0x130a')](function(_0x128001){const _0x1dbb53=_0x15ff89;_0x3d3fc3[_0x1dbb53('0x52a')]({'title':_0x128001[_0x1dbb53('0x13ee')]?_0x1dbb53('0x2168')+_0x128001[_0x1dbb53('0x13ee')]+'\x20-\x20'+_0x128001[_0x1dbb53('0x24a9')]:_0x1dbb53('0x1b71'),'msg':_0x128001[_0x1dbb53('0x13ee')]?JSON[_0x1dbb53('0x258a')](_0x128001[_0x1dbb53('0x5a5')]):_0x128001[_0x1dbb53('0x1ff0')]()});});}function _0x199efc(){const _0x13c6e7=_0x59a3c2;_0x5b44c8[_0x13c6e7('0x1715')]();}}const _0x1855a6=_0x9f2c6d,_0x52d491=_0x180212['p']+_0x189033('0x284');_0x5ee8b1[_0x189033('0x14be')]=[_0x189033('0x938'),_0x189033('0xb8d'),_0x189033('0x1e48'),'$document',_0x189033('0x1d08'),_0x189033('0xace'),_0x189033('0x260a'),_0x189033('0x56b'),'toasty','Auth','whatsappQueue',_0x189033('0x22df')];function _0x5ee8b1(_0x15893b,_0x39d763,_0x4a2069,_0x426f1c,_0x5ec738,_0x5eb448,_0x15bc2a,_0x2da4e3,_0x14acc7,_0x365145,_0x358057,_0x164b9c){const _0x3b3b87=_0x189033,_0x1d309a=this;_0x1d309a[_0x3b3b87('0x11ed')]=_0x365145['getCurrentUser'](),_0x1d309a['license']=_0x5eb448,_0x1d309a['setting']=_0x15bc2a,_0x1d309a[_0x3b3b87('0x19b2')]=_0x1d309a['setting'][_0x3b3b87('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'',_0x1d309a[_0x3b3b87('0x1224')]=_0x39d763[_0x3b3b87('0x173e')]()+_0x3b3b87('0x20de')+_0x39d763['host'](),_0x1d309a[_0x3b3b87('0x25e5')]=_0x358057||_0x15893b['params'][_0x3b3b87('0x25e5')]||{},_0x1d309a[_0x3b3b87('0x22df')]=_0x164b9c&&_0x164b9c['count']==0x1?_0x164b9c['rows'][0x0]:null,_0x1d309a[_0x3b3b87('0x1134')]=_0x365145[_0x3b3b87('0x142a')](_0x1d309a[_0x3b3b87('0x22df')]?_0x1d309a[_0x3b3b87('0x22df')][_0x3b3b87('0x1134')]:null),_0x1d309a[_0x3b3b87('0x258d')]={},_0x1d309a[_0x3b3b87('0x517')]=_0x15893b[_0x3b3b87('0x7f2')][_0x3b3b87('0x1904')]||0x0,_0x1d309a[_0x3b3b87('0xe0e')]=_0x4181f8,_0x1d309a[_0x3b3b87('0x2814')]=_0x275479,_0x1d309a['alert']=_0x14acc7[_0x3b3b87('0x2289')],_0x1d309a[_0x3b3b87('0x129c')]=_0x45ec5e,_0x1d309a['saveWhatsappQueue']=_0xcf8f02;function _0x4181f8(_0x4ee228,_0x461d47){const _0x5a0125=_0x3b3b87;_0x4a2069[_0x5a0125('0x1d4')]({'controller':_0x5a0125('0x16b1'),'controllerAs':'vm','templateUrl':_0x52d491,'parent':angular[_0x5a0125('0x1fcc')](_0x426f1c[_0x5a0125('0x18e5')]),'targetEvent':_0x461d47,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x4ee228,'whatsappQueues':_0x1d309a[_0x5a0125('0xa4f')]?_0x1d309a[_0x5a0125('0xa4f')][_0x5a0125('0xf5d')]:[],'crudPermissions':_0x1d309a[_0x5a0125('0x1134')]}});}function _0x275479(_0x3bd2f5,_0x206f26){const _0x238f90=_0x3b3b87;_0x4a2069['show']({'controller':_0x238f90('0xf81'),'controllerAs':'vm','templateUrl':_0xd72f1d,'parent':angular[_0x238f90('0x1fcc')](_0x426f1c[_0x238f90('0x18e5')]),'targetEvent':_0x206f26,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x3bd2f5,'whatsappQueues':_0x1d309a[_0x238f90('0xa4f')]?_0x1d309a[_0x238f90('0xa4f')][_0x238f90('0xf5d')]:[],'crudPermissions':_0x1d309a[_0x238f90('0x1134')],'realtime':![]}});}function _0x45ec5e(){const _0x16658f=_0x3b3b87;_0x15893b['go'](_0x16658f('0x73f'),{},{'reload':_0x16658f('0x73f')});}function _0xcf8f02(){const _0x3c8c8c=_0x3b3b87;_0x2da4e3[_0x3c8c8c('0x25e5')][_0x3c8c8c('0x2480')]({'id':_0x1d309a[_0x3c8c8c('0x25e5')]['id']},_0x1d309a['whatsappQueue'])[_0x3c8c8c('0xe53')][_0x3c8c8c('0x683')](function(){const _0x1e69f9=_0x3c8c8c;_0x14acc7['success']({'title':_0x1e69f9('0x2004'),'msg':_0x1d309a[_0x1e69f9('0x25e5')][_0x1e69f9('0x60a')]?_0x1d309a[_0x1e69f9('0x25e5')][_0x1e69f9('0x60a')]+_0x1e69f9('0x96c'):''});})['catch'](function(_0x84554e){const _0x33aed4=_0x3c8c8c;_0x14acc7[_0x33aed4('0x52a')]({'title':_0x84554e[_0x33aed4('0x13ee')]?_0x33aed4('0x2168')+_0x84554e['status']+_0x33aed4('0xbf6')+_0x84554e[_0x33aed4('0x24a9')]:_0x33aed4('0x269d'),'msg':_0x84554e[_0x33aed4('0x5a5')]?JSON[_0x33aed4('0x258a')](_0x84554e[_0x33aed4('0x5a5')]):_0x84554e[_0x33aed4('0x1ff0')]()});});}}const _0x29a6d3=_0x5ee8b1;_0x1c611c['$inject']=['$scope','$window',_0x189033('0x938'),_0x189033('0x110c'),_0x189033('0x1e48'),_0x189033('0x16ea'),_0x189033('0x2f9'),'$translate',_0x189033('0xa4f'),_0x189033('0x2a'),_0x189033('0x22df'),_0x189033('0x56b'),'msUtils',_0x189033('0x1d70'),_0x189033('0xba1'),_0x189033('0xace'),'setting'];function _0x1c611c(_0x17b4c0,_0x264d68,_0x2c590d,_0x452db1,_0x518bae,_0x2b2a2b,_0x35767a,_0x2d5301,_0x132f63,_0xe466a8,_0x17e5d0,_0xb6eb6b,_0x17f723,_0x3ef1ed,_0x2675d5,_0x4d2801,_0x45503e){const _0x37e634=_0x189033,_0x89bcb2=this;_0x89bcb2[_0x37e634('0xace')]=_0x4d2801,_0x89bcb2['setting']=_0x45503e,_0x89bcb2[_0x37e634('0x11ed')]=_0x2675d5[_0x37e634('0x20b2')](),_0x89bcb2[_0x37e634('0xa4f')]=_0x132f63||{'count':0x0,'rows':[]},_0x89bcb2[_0x37e634('0x2a')]=_0xe466a8,_0x89bcb2['userProfileSection']=_0x17e5d0&&_0x17e5d0['count']==0x1?_0x17e5d0[_0x37e634('0xf5d')][0x0]:null,_0x89bcb2[_0x37e634('0x1134')]=_0x2675d5[_0x37e634('0x142a')](_0x89bcb2[_0x37e634('0x22df')]?_0x89bcb2[_0x37e634('0x22df')]['crudPermissions']:null),_0x89bcb2[_0x37e634('0x5c4')]=_0x37e634('0xa4f'),_0x89bcb2['listOrder']='',_0x89bcb2[_0x37e634('0x1ce2')]=null,_0x89bcb2[_0x37e634('0x83d')]=[],_0x89bcb2[_0x37e634('0x23a2')]={'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','sort':_0x37e634('0xc36'),'channel':'whatsapp','limit':0xa,'page':0x1},_0x89bcb2[_0x37e634('0x21de')]=_0x2e3ca0()[_0x37e634('0x24db')]([{'option':_0x37e634('0x953'),'value':_0x37e634('0x185b')},{'option':_0x37e634('0x15cd'),'value':_0x37e634('0x4ab')}],function(_0x39163a){return _0x2e3ca0()['replace'](_0x39163a['value'],new RegExp('\x27','g'),'');}),_0x89bcb2[_0x37e634('0xc63')]=_0x10f011,_0x89bcb2[_0x37e634('0xe0e')]=_0xf67cf7,_0x89bcb2['agentadddialog']=_0x12acbc,_0x89bcb2[_0x37e634('0x194f')]=_0x14acb6,_0x89bcb2[_0x37e634('0x213c')]=_0x14048d,_0x89bcb2[_0x37e634('0x53')]=_0x4d4180,_0x89bcb2[_0x37e634('0x2676')]=_0x2a827f,_0x89bcb2[_0x37e634('0x1057')]=_0x3ec066,_0x89bcb2['deleteWhatsappQueue']=_0x44b46e,_0x89bcb2[_0x37e634('0x116e')]=_0x839b68,_0x89bcb2[_0x37e634('0x1a77')]=_0x3aa998,_0x89bcb2[_0x37e634('0x5b')]=_0xe4be89,_0x89bcb2[_0x37e634('0x17a3')]=_0x116298;function _0x10f011(_0x55cceb){const _0x258293=_0x37e634;_0x2c590d['go']('app.whatsapp.whatsappQueues.edit',{'id':_0x55cceb['id'],'whatsappQueue':_0x55cceb,'crudPermissions':_0x89bcb2[_0x258293('0x1134')]});}function _0xf67cf7(_0x37948d,_0x565e5a){const _0x51a7bf=_0x37e634;_0x518bae[_0x51a7bf('0x1d4')]({'controller':'WhatsappQueueteamaddController','controllerAs':'vm','templateUrl':_0x52d491,'parent':angular[_0x51a7bf('0x1fcc')](_0x2b2a2b['body']),'targetEvent':_0x565e5a,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x37948d,'whatsappQueues':_0x89bcb2[_0x51a7bf('0xa4f')]?_0x89bcb2[_0x51a7bf('0xa4f')]['rows']:[],'crudPermissions':_0x89bcb2[_0x51a7bf('0x1134')]}});}function _0x12acbc(_0x51e9ac,_0x50c8ed){const _0x1dc531=_0x37e634;_0x518bae[_0x1dc531('0x1d4')]({'controller':_0x1dc531('0xf81'),'controllerAs':'vm','templateUrl':_0xd72f1d,'parent':angular[_0x1dc531('0x1fcc')](_0x2b2a2b[_0x1dc531('0x18e5')]),'targetEvent':_0x50c8ed,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x51e9ac,'whatsappQueues':_0x89bcb2[_0x1dc531('0xa4f')]?_0x89bcb2['whatsappQueues'][_0x1dc531('0xf5d')]:[],'crudPermissions':_0x89bcb2[_0x1dc531('0x1134')],'realtime':![]}});}function _0x14acb6(_0x4d8f8b,_0x382696){const _0x2b6dfb=_0x37e634,_0x12129d=_0x518bae[_0x2b6dfb('0x1c6f')]()[_0x2b6dfb('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20'+_0x2e3ca0()['startCase']('whatsappQueue')+'?')[_0x2b6dfb('0x26e3')](_0x2b6dfb('0xed5')+(_0x4d8f8b[_0x2b6dfb('0x60a')]||'whatsappQueue')+_0x2b6dfb('0x20f1')+'\x20will\x20be\x20deleted.')[_0x2b6dfb('0x1040')](_0x2b6dfb('0xd25'))[_0x2b6dfb('0xe42')](_0x382696)['ok']('OK')['cancel']('CANCEL');_0x518bae[_0x2b6dfb('0x1d4')](_0x12129d)[_0x2b6dfb('0x683')](function(){_0x44b46e(_0x4d8f8b);},function(){const _0x1b901d=_0x2b6dfb;console[_0x1b901d('0x1b2b')](_0x1b901d('0x16b8'));});}function _0x14048d(){const _0x2c9310=_0x37e634;if(_0x2675d5[_0x2c9310('0xca1')](_0x2c9310('0x20c2')))_0x2c590d['go'](_0x2c9310('0x24c0'),{});else return _0xb6eb6b[_0x2c9310('0x22df')][_0x2c9310('0x1e6e')]({'userProfileId':_0x2675d5[_0x2c9310('0x20b2')]()['userProfileId'],'sectionId':0x83e})[_0x2c9310('0xe53')][_0x2c9310('0x683')](function(_0x46fac6){const _0x15ff14=_0x2c9310,_0x1e8434=_0x46fac6&&_0x46fac6[_0x15ff14('0xf5d')]?_0x46fac6[_0x15ff14('0xf5d')][0x0]:null;_0x1e8434&&_0x1e8434[_0x15ff14('0x1333')]?_0x2c590d['go'](_0x15ff14('0x24c0'),{}):_0x3ef1ed[_0x15ff14('0x2289')]({'title':_0x2d5301[_0x15ff14('0x2728')](_0x15ff14('0x213e')),'msg':_0x2d5301[_0x15ff14('0x2728')](_0x15ff14('0xdba'))});})['catch'](function(_0x225458){const _0x2b3e77=_0x2c9310;_0x3ef1ed['error']({'title':_0x225458[_0x2b3e77('0x13ee')]?'API:'+_0x225458[_0x2b3e77('0x13ee')]+_0x2b3e77('0xbf6')+_0x225458['statusText']:_0x2b3e77('0xf2a'),'msg':_0x225458[_0x2b3e77('0x13ee')]?JSON['stringify'](_0x225458[_0x2b3e77('0x5a5')]):_0x225458[_0x2b3e77('0x1ff0')]()});});}let _0x1b7587=!![],_0x43a241=0x1;_0x17b4c0[_0x37e634('0x186d')](_0x37e634('0x1e1d'),function(_0x6357b3,_0x40b6bc){const _0x3bf1a8=_0x37e634;_0x1b7587?_0x35767a(function(){_0x1b7587=![];}):(!_0x40b6bc&&(_0x43a241=_0x89bcb2['query'][_0x3bf1a8('0xdf8')]),_0x6357b3!==_0x40b6bc&&(_0x89bcb2['query'][_0x3bf1a8('0xdf8')]=0x1),!_0x6357b3&&(_0x89bcb2[_0x3bf1a8('0x23a2')][_0x3bf1a8('0xdf8')]=_0x43a241),_0x89bcb2[_0x3bf1a8('0x2676')]());});function _0x4d4180(_0x2ddd47){const _0x126485=_0x37e634;_0x89bcb2[_0x126485('0xa4f')]=_0x2ddd47||{'count':0x0,'rows':[]};}function _0x2a827f(){const _0x42c6d3=_0x37e634;_0x89bcb2[_0x42c6d3('0x23a2')][_0x42c6d3('0x1cc8')]=(_0x89bcb2[_0x42c6d3('0x23a2')][_0x42c6d3('0xdf8')]-0x1)*_0x89bcb2[_0x42c6d3('0x23a2')][_0x42c6d3('0x6f0')],_0x2675d5['hasRole']('admin')?_0x89bcb2['promise']=_0xb6eb6b[_0x42c6d3('0x25e5')][_0x42c6d3('0x1e6e')](_0x89bcb2['query'],_0x4d4180)[_0x42c6d3('0xe53')]:(_0x89bcb2['query']['id']=_0x89bcb2[_0x42c6d3('0x2a')]['id'],_0x89bcb2[_0x42c6d3('0x23a2')]['section']=_0x42c6d3('0x20e4'),_0x89bcb2[_0x42c6d3('0x1883')]=_0xb6eb6b['userProfile'][_0x42c6d3('0x241d')](_0x89bcb2['query'],_0x4d4180)[_0x42c6d3('0xe53')]);}function _0x3ec066(_0x580cbe,_0x1ace02){const _0x4ba447=_0x37e634;_0x518bae[_0x4ba447('0x1d4')]({'controller':_0x4ba447('0x248a'),'controllerAs':'vm','templateUrl':_0x33b6fa,'parent':angular[_0x4ba447('0x1fcc')](_0x2b2a2b['body']),'targetEvent':_0x580cbe,'clickOutsideToClose':!![],'locals':{'whatsappQueue':_0x1ace02,'whatsappQueues':_0x89bcb2['whatsappQueues'][_0x4ba447('0xf5d')],'license':_0x89bcb2[_0x4ba447('0xace')],'setting':_0x89bcb2[_0x4ba447('0x260a')],'crudPermissions':_0x89bcb2[_0x4ba447('0x1134')]}});}function _0x44b46e(_0x59e100){const _0x19b306=_0x37e634;_0xb6eb6b[_0x19b306('0x25e5')][_0x19b306('0xd7e')]({'id':_0x59e100['id']})[_0x19b306('0xe53')]['then'](function(){const _0x43c975=_0x19b306;_0x2e3ca0()[_0x43c975('0x3ec')](_0x89bcb2[_0x43c975('0xa4f')][_0x43c975('0xf5d')],{'id':_0x59e100['id']}),_0x89bcb2['whatsappQueues'][_0x43c975('0x50d')]-=0x1,!_0x89bcb2[_0x43c975('0xa4f')][_0x43c975('0xf5d')][_0x43c975('0x1564')]&&_0x89bcb2[_0x43c975('0x2676')](),_0x3ef1ed['success']({'title':_0x2e3ca0()[_0x43c975('0x1e03')](_0x43c975('0x167e'))+'\x20deleted!','msg':_0x59e100['name']?_0x59e100[_0x43c975('0x60a')]+_0x43c975('0x194d'):''});})['catch'](function(_0x4c0c43){const _0x52e4df=_0x19b306;if(_0x4c0c43[_0x52e4df('0x5a5')]&&_0x4c0c43[_0x52e4df('0x5a5')][_0x52e4df('0x17f')]&&_0x4c0c43['data']['errors'][_0x52e4df('0x1564')]){_0x89bcb2[_0x52e4df('0x17f')]=_0x4c0c43[_0x52e4df('0x5a5')][_0x52e4df('0x17f')]||[{'message':_0x4c0c43['toString'](),'type':_0x52e4df('0xde3')}];for(let _0x31682d=0x0;_0x31682d<_0x4c0c43[_0x52e4df('0x5a5')][_0x52e4df('0x17f')][_0x52e4df('0x1564')];_0x31682d++){_0x3ef1ed[_0x52e4df('0x52a')]({'title':_0x4c0c43[_0x52e4df('0x5a5')][_0x52e4df('0x17f')][_0x31682d][_0x52e4df('0xcf0')],'msg':_0x4c0c43[_0x52e4df('0x5a5')][_0x52e4df('0x17f')][_0x31682d][_0x52e4df('0x8c2')]});}}else _0x3ef1ed[_0x52e4df('0x52a')]({'title':_0x4c0c43[_0x52e4df('0x13ee')]?'API:'+_0x4c0c43[_0x52e4df('0x13ee')]+_0x52e4df('0xbf6')+_0x4c0c43[_0x52e4df('0x24a9')]:_0x52e4df('0xde3'),'msg':_0x4c0c43[_0x52e4df('0x5a5')]?JSON[_0x52e4df('0x258a')](_0x4c0c43[_0x52e4df('0x5a5')]['message']):_0x4c0c43[_0x52e4df('0x8c2')]||_0x4c0c43[_0x52e4df('0x1ff0')]()});});}function _0x839b68(){const _0x43a2e6=_0x37e634,_0x37a42f=angular['copy'](_0x89bcb2[_0x43a2e6('0x83d')]);return _0x89bcb2[_0x43a2e6('0x83d')]=[],_0x37a42f;}function _0x3aa998(_0x4bd126){const _0x59f74a=_0x37e634,_0x45e001=_0x518bae[_0x59f74a('0x1c6f')]()[_0x59f74a('0xf28')]('Are\x20you\x20sure\x20want\x20to\x20delete\x20the\x20selected\x20whatsappQueues?')[_0x59f74a('0x26e3')](''+_0x89bcb2['selectedWhatsappQueues'][_0x59f74a('0x1564')]+'\x20selected'+_0x59f74a('0x1ee7'))['ariaLabel'](_0x59f74a('0x677'))[_0x59f74a('0xe42')](_0x4bd126)['ok']('OK')['cancel'](_0x59f74a('0x16b8'));_0x518bae[_0x59f74a('0x1d4')](_0x45e001)[_0x59f74a('0x683')](function(){const _0x4953b3=_0x59f74a;_0x89bcb2[_0x4953b3('0x83d')][_0x4953b3('0x1299')](function(_0x1fa3cc){_0x44b46e(_0x1fa3cc);}),_0x89bcb2[_0x4953b3('0x83d')]=[];});}function _0xe4be89(){_0x89bcb2['selectedWhatsappQueues']=[];}function _0x116298(){const _0x4a8d05=_0x37e634;_0x89bcb2[_0x4a8d05('0x83d')]=_0x89bcb2['whatsappQueues'][_0x4a8d05('0xf5d')];}}const _0x2b6d07=_0x1c611c;_0x27a5bf[_0x189033('0x14be')]=['$stateProvider',_0x189033('0x19ee')];function _0x27a5bf(_0x365f32,_0x2dc0c8){const _0x31b7a2=_0x189033;_0x365f32[_0x31b7a2('0x2598')](_0x31b7a2('0xb0c'),{'abstract':!![],'url':_0x31b7a2('0x1be6')})[_0x31b7a2('0x2598')](_0x31b7a2('0x73f'),{'url':_0x31b7a2('0xac4'),'views':{'content@app':{'templateUrl':_0x4ad2f9,'controller':_0x31b7a2('0x1595')}},'resolve':{'whatsappQueues':[_0x31b7a2('0x4b1'),_0x31b7a2('0xba1'),function(_0x4b7074,_0x27a9e0){const _0x56c075=_0x31b7a2;return _0x27a9e0[_0x56c075('0xca1')](_0x56c075('0x20c2'))?_0x4b7074[_0x56c075('0xed7')](_0x56c075('0x138d'),{'fields':'createdAt,updatedAt,id,name,strategy,timeout,description','sort':_0x56c075('0xc36'),'channel':'whatsapp','limit':0xa,'offset':0x0}):_0x4b7074['resolve'](_0x56c075('0x191b'),{'id':_0x27a9e0[_0x56c075('0x20b2')]()[_0x56c075('0x2f')],'section':_0x56c075('0x20e4'),'fields':_0x56c075('0x1b67'),'sort':_0x56c075('0xc36'),'channel':_0x56c075('0x16e7'),'limit':0xa,'offset':0x0});}],'userProfile':['apiResolver','Auth',function(_0x14c336,_0xdc0b3b){const _0x169cda=_0x31b7a2;return _0xdc0b3b[_0x169cda('0xca1')]('admin')?null:_0x14c336[_0x169cda('0xed7')](_0x169cda('0x1464'),{'fields':_0x169cda('0x16f'),'id':_0xdc0b3b[_0x169cda('0x20b2')]()['userProfileId']});}],'userProfileSection':[_0x31b7a2('0x4b1'),_0x31b7a2('0xba1'),function(_0x244dac,_0x282116){const _0x1f1d3e=_0x31b7a2;return _0x282116['hasRole'](_0x1f1d3e('0x20c2'))?null:_0x244dac[_0x1f1d3e('0xed7')]('userProfileSection@get',{'fields':_0x1f1d3e('0x1f47'),'userProfileId':_0x282116[_0x1f1d3e('0x20b2')]()[_0x1f1d3e('0x2f')],'sectionId':0x835});}]},'authenticate':!![],'permissionId':0x835,'bodyClass':_0x31b7a2('0x16e7')})[_0x31b7a2('0x2598')]('app.whatsapp.whatsappQueues.edit',{'url':'/:id?tab','params':{'whatsappQueue':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x22966b,'controller':'WhatsappQueueController\x20as\x20vm'}},'resolve':{'whatsappQueue':[_0x31b7a2('0x4b1'),_0x31b7a2('0x8ea'),function(_0x5deeeb,_0x2389de){const _0x2c593e=_0x31b7a2;return _0x5deeeb[_0x2c593e('0xed7')](_0x2c593e('0x138d'),{'fields':_0x2c593e('0x1b67'),'id':_0x2389de['id']});}],'userProfileSection':[_0x31b7a2('0x4b1'),_0x31b7a2('0xba1'),function(_0x47cbc9,_0x1481a3){const _0x591bcf=_0x31b7a2;return _0x47cbc9['resolve'](_0x591bcf('0x360'),{'fields':_0x591bcf('0x1f47'),'userProfileId':_0x1481a3[_0x591bcf('0x20b2')]()[_0x591bcf('0x2f')],'sectionId':0x835});}]},'authenticate':!![],'permissionId':0x835,'bodyClass':_0x31b7a2('0x16e7')})['state'](_0x31b7a2('0x1774'),{'url':_0x31b7a2('0x66c'),'views':{'content@app':{'templateUrl':_0x28e1a8,'controller':_0x31b7a2('0x2345')}},'resolve':{'whatsappAccounts':[_0x31b7a2('0x4b1'),'Auth',function(_0x85ae1a,_0x32d0b1){const _0x2f8169=_0x31b7a2;return _0x32d0b1[_0x2f8169('0xca1')](_0x2f8169('0x20c2'))?_0x85ae1a[_0x2f8169('0xed7')](_0x2f8169('0x111b'),{'fields':_0x2f8169('0x1639'),'sort':_0x2f8169('0xc36'),'limit':0xa,'offset':0x0}):_0x85ae1a[_0x2f8169('0xed7')]('userProfile@getResources',{'id':_0x32d0b1[_0x2f8169('0x20b2')]()['userProfileId'],'section':_0x2f8169('0x239b'),'fields':'createdAt,updatedAt,id,name,key,ListId,remote,token,type,accountSid,authToken,phone,receiveUrl,deliveryReportUrl,notificationShake,notificationSound,notificationTemplate,queueTransfer,queueTransferTimeout,waitForTheAssignedAgent,mandatoryDisposition,mandatoryDispositionPauseId,agentTransfer,agentTransferTimeout,description','sort':_0x2f8169('0xc36'),'limit':0xa,'offset':0x0});}],'userProfile':[_0x31b7a2('0x4b1'),_0x31b7a2('0xba1'),function(_0x5227cd,_0x4ff562){const _0x1b6464=_0x31b7a2;return _0x4ff562['hasRole'](_0x1b6464('0x20c2'))?null:_0x5227cd[_0x1b6464('0xed7')](_0x1b6464('0x1464'),{'fields':_0x1b6464('0x16f'),'id':_0x4ff562[_0x1b6464('0x20b2')]()[_0x1b6464('0x2f')]});}],'userProfileSection':[_0x31b7a2('0x4b1'),_0x31b7a2('0xba1'),function(_0x260b99,_0x53ada1){const _0x59cf76=_0x31b7a2;return _0x53ada1[_0x59cf76('0xca1')](_0x59cf76('0x20c2'))?null:_0x260b99[_0x59cf76('0xed7')]('userProfileSection@get',{'fields':_0x59cf76('0x1f47'),'userProfileId':_0x53ada1['getCurrentUser']()['userProfileId'],'sectionId':0x836});}]},'authenticate':!![],'permissionId':0x836,'bodyClass':_0x31b7a2('0x16e7')})[_0x31b7a2('0x2598')](_0x31b7a2('0xa29'),{'url':'/:id?tab','params':{'whatsappAccount':undefined,'crudPermissions':undefined},'views':{'content@app':{'templateUrl':_0x210243,'controller':_0x31b7a2('0x1bd0')}},'resolve':{'whatsappAccount':['apiResolver',_0x31b7a2('0x8ea'),function(_0x2f39c0,_0x47fa9f){const _0x1ae50d=_0x31b7a2;return _0x2f39c0[_0x1ae50d('0xed7')](_0x1ae50d('0x111b'),{'fields':_0x1ae50d('0x1639'),'id':_0x47fa9f['id']});}],'userProfileSection':['apiResolver',_0x31b7a2('0xba1'),function(_0x480e8c,_0x47c004){const _0x552c55=_0x31b7a2;return _0x480e8c[_0x552c55('0xed7')](_0x552c55('0x360'),{'fields':'id,name,enabled,includeAll,autoAssociation,crudPermissions','userProfileId':_0x47c004[_0x552c55('0x20b2')]()[_0x552c55('0x2f')],'sectionId':0x836});}]},'authenticate':!![],'permissionId':0x836,'bodyClass':'whatsapp'}),_0x2dc0c8[_0x31b7a2('0x7d2')](_0x31b7a2('0xea2'));}angular[_0x189033('0x1e26')](_0x189033('0xb0c'),[_0x189033('0x6cf'),_0x189033('0x1ddb'),_0x189033('0x2290'),_0x189033('0x190a'),_0x189033('0x25fc'),_0x189033('0x2835'),_0x189033('0x1d9c'),_0x189033('0x2609'),_0x189033('0x273d'),_0x189033('0x76'),'mwFormBuilder',_0x189033('0x7fa'),'mwFormUtils',_0x189033('0x3b5'),_0x189033('0x153a'),'ngEmbed',_0x189033('0x2645'),'material.components.expansionPanels',_0x189033('0x1566'),_0x189033('0x19da'),_0x189033('0x30c')])[_0x189033('0x272d')](_0x27a5bf)['controller'](_0x189033('0x1348'),_0x46ccab)[_0x189033('0x1da3')]('WhatsappAccountActionsController',_0x199e9c)[_0x189033('0x1da3')]('WhatsappAccountagentaddController',_0x194f8d)[_0x189033('0x1da3')]('EditWhatsappAccountAppagentDialogController',_0x58a916)['controller'](_0x189033('0x2363'),_0x487e46)['controller'](_0x189033('0x1394'),_0x45bfc5)['controller'](_0x189033('0x15d7'),_0x30f53a)[_0x189033('0x1da3')](_0x189033('0x777'),_0xb614a)[_0x189033('0x1da3')](_0x189033('0x2574'),_0x2d3662)[_0x189033('0x1da3')](_0x189033('0x10'),_0x4e7272)[_0x189033('0x1da3')](_0x189033('0x8ab'),_0x12c4ee)['controller'](_0x189033('0x2233'),_0x3debc4)['controller'](_0x189033('0x14d8'),_0x5d973e)['controller'](_0x189033('0x2351'),_0x544c5b)[_0x189033('0x1da3')]('EditWhatsappAccountApptagDialogController',_0x4ecb44)[_0x189033('0x1da3')](_0x189033('0x1544'),_0x126951)[_0x189033('0x1da3')](_0x189033('0xaa3'),_0x4b0750)[_0x189033('0x1da3')]('WhatsappAccountWhatsappCannedAnswersController',_0x3b689c)['controller'](_0x189033('0x1d8a'),_0x10fc06)['controller']('WhatsappAccountDispositionsController',_0x4044db)[_0x189033('0x1da3')](_0x189033('0x138e'),_0x2a07d1)['controller']('CreateOrEditWhatsappQueueDialogController',_0x3119ed)[_0x189033('0x1da3')]('WhatsappQueueagentaddController',_0x25d608)['controller']('WhatsappQueueteamaddController',_0x1855a6)[_0x189033('0x1da3')]('WhatsappQueueController',_0x29a6d3)[_0x189033('0x1da3')](_0x189033('0x247b'),_0x2b6d07);const _0x48dad7=_0x180212['p']+_0x189033('0x1bb3'),_0x568ca3=_0x180212['p']+_0x189033('0x25ea'),_0xc244c3=_0x180212['p']+'src/js/modules/core/layouts/content-with-toolbar.html/content-with-toolbar.html',_0x28db1f=_0x180212['p']+_0x189033('0x133f'),_0x2c9abe=_0x180212['p']+'src/js/modules/core/layouts/vertical-navigation-fullwidth-toolbar-2.html/vertical-navigation-fullwidth-toolbar-2.html',_0x43564=_0x180212['p']+_0x189033('0x13c3'),_0x222444=_0x180212['p']+_0x189033('0x2056');_0x2f5c73['$inject']=['$state',_0x189033('0x2063'),_0x189033('0x17e4'),'$timeout',_0x189033('0x56b'),_0x189033('0xba1'),'setting'];function _0x2f5c73(_0x4599dc,_0x39fda7,_0x584e44,_0x4aa3ef,_0x1c438c,_0x473810,_0x29efb6){const _0x119c68=_0x189033,_0x3488c2=this;_0x3488c2[_0x119c68('0xd1d')]=![],_0x3488c2[_0x119c68('0x22a3')]=![],_0x3488c2[_0x119c68('0x2713')]=_0x1c438c[_0x119c68('0x2713')];function _0x52ac94(){const _0x408e25=_0x119c68;if(_0x4599dc['params']['token']&&_0x4599dc[_0x408e25('0x7f2')][_0x408e25('0x1eb8')])return _0x473810[_0x408e25('0x3f0')](),_0x3488c2['progresslogin']=!![],_0x584e44[_0x408e25('0x137e')](_0x408e25('0x555'),_0x4599dc[_0x408e25('0x7f2')]['token']),_0x1c438c[_0x408e25('0xc96')][_0x408e25('0x1e6e')]({'id':_0x4599dc[_0x408e25('0x7f2')][_0x408e25('0x1eb8')]})[_0x408e25('0xe53')][_0x408e25('0x683')](function(_0x2d3ebb){const _0x7c5015=_0x408e25;_0x2d3ebb&&(_0x473810[_0x7c5015('0x283b')](_0x2d3ebb),_0x4599dc['go'](_0x7c5015('0x279d')));})[_0x408e25('0x2874')](function(){_0x3488c2['progresslogin']=![];});else _0x473810[_0x408e25('0x1088')]()&&_0x4599dc['go'](_0x408e25('0x279d'));_0x3488c2['googleSsoEnabled']=_0x29efb6[_0x408e25('0x22a3')];}function _0x53b15e(){const _0x3c70cb=_0x119c68;return _0x3488c2[_0x3c70cb('0xd1d')]=!![],_0x3488c2[_0x3c70cb('0x8c2')]='',_0x473810['login'](_0x3488c2['form'])[_0x3c70cb('0x683')](function(){const _0x4cb751=_0x3c70cb;return _0x4599dc['go'](_0x4cb751('0x279d'));})[_0x3c70cb('0x130a')](function(_0x540e55){const _0x4b19d4=_0x3c70cb;_0x3488c2[_0x4b19d4('0x8c2')]=_0x540e55['data']?_0x540e55[_0x4b19d4('0x5a5')][_0x4b19d4('0x8c2')]:_0x540e55['message'];})[_0x3c70cb('0x2874')](function(){const _0x230e78=_0x3c70cb;_0x3488c2[_0x230e78('0xd1d')]=![];});}function _0x2d102c(_0xe44152){const _0x3afad9=_0x119c68;_0x3488c2[_0x3afad9('0x8c2')]='',_0x39fda7[_0x3afad9('0x1224')][_0x3afad9('0x2767')]=_0x473810[_0x3afad9('0xaa7')](_0xe44152);}_0x3488c2[_0x119c68('0x125')]=_0x53b15e,_0x3488c2[_0x119c68('0x1aaa')]=_0x2d102c,_0x3488c2[_0x119c68('0x1dd2')]=_0x52ac94,_0x3488c2[_0x119c68('0x1dd2')]();}const _0x5d8766=_0x2f5c73;_0x4b4845[_0x189033('0x14be')]=[_0x189033('0x1398'),'$translatePartialLoaderProvider'];function _0x4b4845(_0x3fa9f9,_0x2e6dc6){const _0x568e61=_0x189033;_0x3fa9f9[_0x568e61('0x2598')]('app.login',{'url':_0x568e61('0x215f'),'views':{'main@':{'templateUrl':_0x568ca3,'controller':_0x568e61('0xaa2')},'content@app.login':{'templateUrl':_0x48dad7,'controller':_0x568e61('0xeaa')}},'bodyClass':'login'}),_0x2e6dc6[_0x568e61('0x7d2')](_0x568e61('0x18bd'));}angular[_0x189033('0x1e26')]('app.login',[])['config'](_0x4b4845)['controller'](_0x189033('0x2493'),_0x5d8766);const _0x566d33=_0x180212['p']+_0x189033('0x841');_0x51d0cd[_0x189033('0x14be')]=['Auth',_0x189033('0x1d70'),'$translate',_0x189033('0x938'),_0x189033('0x56b')];function _0x51d0cd(_0x334597,_0x1ce6b0,_0x1d5c16,_0x15b2cc,_0x80a9a7){const _0x26c6f0=_0x189033,_0x1f7c84=this;_0x1f7c84[_0x26c6f0('0x2744')]={},_0x1f7c84[_0x26c6f0('0x2713')]=_0x80a9a7[_0x26c6f0('0x2713')];function _0x28a728(){const _0x4f7e7e=_0x26c6f0;_0x334597[_0x4f7e7e('0x1088')]()&&_0x15b2cc['go']('app.dashboards.general');}function _0x4998ad(){const _0x4dd598=_0x26c6f0;return _0x80a9a7[_0x4dd598('0x69f')]['forgot'](_0x1f7c84[_0x4dd598('0x2744')])[_0x4dd598('0xe53')][_0x4dd598('0x683')](function(){const _0x10b864=_0x4dd598;_0x1ce6b0['success']({'title':_0x1d5c16[_0x10b864('0x2728')](_0x10b864('0x11df')),'msg':_0x1d5c16[_0x10b864('0x2728')](_0x10b864('0x274e'))});})[_0x4dd598('0x130a')](function(_0x20583f){const _0x28ee93=_0x4dd598;_0x20583f&&_0x1ce6b0['error']({'title':_0x1d5c16['instant'](_0x28ee93('0x23c')),'msg':_0x20583f[_0x28ee93('0x5a5')]?_0x20583f[_0x28ee93('0x5a5')][_0x28ee93('0x8c2')]||_0x20583f[_0x28ee93('0x8c2')]||_0x20583f:_0x20583f[_0x28ee93('0x8c2')]||_0x20583f});});}_0x1f7c84[_0x26c6f0('0x1411')]=_0x4998ad,_0x1f7c84[_0x26c6f0('0x1dd2')]=_0x28a728;}const _0x562d43=_0x51d0cd;_0x30681[_0x189033('0x14be')]=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x30681(_0x3f39ea,_0x181ac8){const _0x311c79=_0x189033;_0x3f39ea[_0x311c79('0x2598')](_0x311c79('0x22fc'),{'url':_0x311c79('0x6cc'),'views':{'main@':{'templateUrl':_0x568ca3,'controller':_0x311c79('0xaa2')},'content@app.forgot':{'templateUrl':_0x566d33,'controller':_0x311c79('0x225e')}},'bodyClass':'forgot'}),_0x181ac8[_0x311c79('0x7d2')]('app/forgot');}angular[_0x189033('0x1e26')]('app.forgot',[])[_0x189033('0x272d')](_0x30681)['controller'](_0x189033('0x19f7'),_0x562d43);const _0x277c9e=_0x180212['p']+_0x189033('0x22d1');_0xfb6f60[_0x189033('0x14be')]=[_0x189033('0xba1'),'toasty',_0x189033('0x1d08'),_0x189033('0x938'),_0x189033('0x56b'),_0x189033('0x8ea')];function _0xfb6f60(_0x8493da,_0x280c30,_0x24ff70,_0x2db3fc,_0x7eb947,_0xdcb7b5){const _0x2d4749=_0x189033,_0x41d448=this;_0x41d448[_0x2d4749('0x2744')]={'token':_0xdcb7b5[_0x2d4749('0x25da')]},_0x41d448[_0x2d4749('0x260a')]={},_0x41d448[_0x2d4749('0x2713')]=_0x7eb947[_0x2d4749('0x2713')];function _0x4e9445(){const _0x473860=_0x2d4749;return _0x8493da[_0x473860('0x1088')]()&&_0x2db3fc['go'](_0x473860('0x279d')),_0x7eb947[_0x473860('0x260a')][_0x473860('0xe6f')]({'id':0x1})[_0x473860('0xe53')][_0x473860('0x683')](function(_0xbd2c19){const _0x291ff0=_0x473860;_0x41d448['setting']=_0xbd2c19,_0x41d448[_0x291ff0('0x19b2')]=_0x41d448[_0x291ff0('0x260a')][_0x291ff0('0x1cc3')]?/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/:'';})[_0x473860('0x130a')](function(_0x5484a0){const _0x120475=_0x473860;_0x5484a0&&_0x280c30['error']({'title':_0x120475('0x85b'),'msg':_0x5484a0[_0x120475('0x5a5')]?_0x5484a0[_0x120475('0x5a5')][_0x120475('0x8c2')]||_0x5484a0[_0x120475('0x8c2')]||_0x5484a0:_0x5484a0[_0x120475('0x8c2')]||_0x5484a0});});}function _0x564b80(){const _0x1a2721=_0x2d4749;return _0x7eb947['auth'][_0x1a2721('0x1302')](_0x41d448[_0x1a2721('0x2744')])[_0x1a2721('0xe53')][_0x1a2721('0x683')](function(){const _0xe4fc20=_0x1a2721;_0x280c30[_0xe4fc20('0x53')]({'title':_0x24ff70['instant'](_0xe4fc20('0x14a6')),'msg':_0x24ff70[_0xe4fc20('0x2728')](_0xe4fc20('0x14ee'))}),_0x2db3fc['go'](_0xe4fc20('0x8a0'));})['catch'](function(_0x236c30){const _0x2e0f0d=_0x1a2721;_0x236c30&&_0x280c30[_0x2e0f0d('0x52a')]({'title':_0x24ff70[_0x2e0f0d('0x2728')]('RESETPASSWORD.PASSWORD_RESET_ERROR'),'msg':_0x236c30[_0x2e0f0d('0x5a5')]?_0x236c30[_0x2e0f0d('0x5a5')][_0x2e0f0d('0x8c2')]||_0x236c30[_0x2e0f0d('0x8c2')]||_0x236c30:_0x236c30[_0x2e0f0d('0x8c2')]||_0x236c30});});}_0x41d448['resetPassword']=_0x564b80,_0x41d448['onInit']=_0x4e9445;}const _0x1ddeec=_0xfb6f60;_0x5be557[_0x189033('0x14be')]=['$stateProvider',_0x189033('0x19ee')];function _0x5be557(_0x51f158,_0x403b1c){const _0x4b0c60=_0x189033;_0x51f158[_0x4b0c60('0x2598')](_0x4b0c60('0x1389'),{'url':_0x4b0c60('0x21a2'),'views':{'main@':{'templateUrl':_0x568ca3,'controller':'MainController\x20as\x20vm'},'content@app.reset':{'templateUrl':_0x277c9e,'controller':_0x4b0c60('0x18c5')}},'bodyClass':'reset'}),_0x403b1c[_0x4b0c60('0x7d2')](_0x4b0c60('0x707'));}angular[_0x189033('0x1e26')]('app.reset',[])['config'](_0x5be557)['controller'](_0x189033('0xa02'),_0x1ddeec);const _0xec39ca=_0x180212['p']+_0x189033('0x21d0');_0x1a0a18[_0x189033('0x14be')]=[_0x189033('0x938'),'$timeout','$q',_0x189033('0x27c0')];function _0x1a0a18(_0x1553bb,_0x49420f,_0x538b48,_0x407f5e){const _0x3b8ee3=_0x189033,_0x577206=this;function _0x33a305(_0x464a5c){const _0x460d25=a0_0x4e0a;let _0x129bed=[];const _0x4d8339=_0x407f5e[_0x460d25('0x14bd')](),_0x2c3844=_0x538b48['defer']();for(let _0x52627d=0x0;_0x52627d<_0x4d8339[_0x460d25('0x1564')];_0x52627d+=0x1){_0x4d8339[_0x52627d][_0x460d25('0x171')]&&_0x129bed['push'](_0x4d8339[_0x52627d]);}return _0x464a5c&&(_0x129bed=_0x129bed[_0x460d25('0x25')](function(_0x48d88e){const _0x19770f=_0x460d25;if(_0x48d88e[_0x19770f('0xf28')][_0x19770f('0x93a')]()[_0x19770f('0x2292')](_0x464a5c[_0x19770f('0x93a')]()))return!![];})),_0x49420f(function(){const _0x1f284d=_0x460d25;_0x2c3844[_0x1f284d('0xed7')](_0x129bed);},0x3e8),_0x2c3844[_0x460d25('0x1883')];}function _0x5340cf(_0x44a77d){const _0x2f1f74=a0_0x4e0a;_0x44a77d[_0x2f1f74('0x171')]&&(_0x44a77d[_0x2f1f74('0x230a')]?_0x1553bb['go'](_0x44a77d[_0x2f1f74('0x2598')],_0x44a77d[_0x2f1f74('0x230a')]):_0x1553bb['go'](_0x44a77d[_0x2f1f74('0x2598')]));}_0x577206[_0x3b8ee3('0x19a4')]=_0x33a305,_0x577206[_0x3b8ee3('0x9f4')]=_0x5340cf;}const _0x101e45=_0x1a0a18;_0x34cb25[_0x189033('0x14be')]=[_0x189033('0x1398'),'$translatePartialLoaderProvider'];function _0x34cb25(_0x139220,_0x7b544c){const _0x553611=_0x189033;_0x139220['state'](_0x553611('0xc86'),{'url':_0x553611('0x2062'),'views':{'main@':{'templateUrl':_0x568ca3,'controller':_0x553611('0xaa2')},'content@app.errors_error-404':{'templateUrl':_0xec39ca,'controller':'Error404Controller\x20as\x20vm'}},'params':{'status':0x194,'statusText':'','data':{},'config':{}},'bodyClass':_0x553611('0x11f1')}),_0x7b544c[_0x553611('0x7d2')]('app/errors/404');}angular[_0x189033('0x1e26')](_0x189033('0x245'),[])[_0x189033('0x272d')](_0x34cb25)['controller'](_0x189033('0xf66'),_0x101e45);const _0x37c9d3=_0x180212['p']+_0x189033('0x15b2');_0x39eed9[_0x189033('0x14be')]=['$state','$http'];function _0x39eed9(_0x503597,_0xfd9c7e){const _0x31d0d0=_0x189033,_0x73b543=this;function _0x388c6e(){const _0x214b03=a0_0x4e0a;_0xfd9c7e[_0x214b03('0x21df')](_0x214b03('0x234c'),_0x73b543[_0x214b03('0x52a')])[_0x214b03('0x683')](function(_0x394da7){const _0x4f877c=_0x214b03;_0x73b543[_0x4f877c('0x1503')]=!![],_0x394da7[_0x4f877c('0x5a5')]&&(_0x73b543[_0x4f877c('0x1245')]=_0x394da7[_0x4f877c('0x5a5')]['id']);},function(){const _0x2a2b96=_0x214b03;_0x73b543[_0x2a2b96('0x1503')]=![];});}_0x73b543[_0x31d0d0('0x1245')]='',_0x73b543['send']=![],_0x73b543[_0x31d0d0('0x52a')]=_0x503597['params'],_0x73b543[_0x31d0d0('0x2556')]=_0x388c6e;}const _0x6ccfd8=_0x39eed9;_0x365e00[_0x189033('0x14be')]=[_0x189033('0x1398'),_0x189033('0x19ee')];function _0x365e00(_0x188681,_0x5d4e14){const _0x159096=_0x189033;_0x188681['state'](_0x159096('0x2386'),{'url':'/errors/error-500','views':{'main@':{'templateUrl':_0x568ca3,'controller':_0x159096('0xaa2')},'content@app.errors_error-500':{'templateUrl':_0x37c9d3,'controller':_0x159096('0x189')}},'params':{'status':0x1f4,'statusText':'','data':{},'config':{}},'bodyClass':_0x159096('0x1fb0')}),_0x5d4e14[_0x159096('0x7d2')](_0x159096('0x1ad3'));}angular[_0x189033('0x1e26')](_0x189033('0x9ea'),[])[_0x189033('0x272d')](_0x365e00)[_0x189033('0x1da3')]('Error500Controller',_0x6ccfd8);;angular['module']('app.errors',[_0x189033('0x245'),_0x189033('0x9ea')]),_0x9f2481[_0x189033('0x14be')]=[_0x189033('0xdbd')];function _0x9f2481(_0x230ea2){const _0x4ac86a=_0x189033,_0x2e7042={};return _0x2e7042[_0x4ac86a('0x2713')]=!![]?_0x4ac86a('0x1331'):0x0,_0x2e7042[_0x4ac86a('0x69f')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1da6'),{},{'local':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1da6')},'forgot':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1195')},'reset':{'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x1271'),'params':{'token':_0x4ac86a('0x15d5')}},'user':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2396'),'params':{'token':_0x4ac86a('0x15d5')}},'google':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1bed')}}),_0x2e7042[_0x4ac86a('0x2891')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2891')),_0x2e7042[_0x4ac86a('0x1b1b')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1b1b'),{},{'startMonitor':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1b3e'),'params':{'uniqueid':'@uniqueid'}},'stopMonitor':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xe24'),'params':{'uniqueid':_0x4ac86a('0x7b1')}},'getVoiceChannels':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xaa4')},'getVoiceQueues':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'rpc/voice/queues'},'getChatQueues':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xb34')},'getMailQueues':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f82')},'getSmsQueues':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'rpc/sms/queues'},'getWhatsappQueues':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1723')},'getOpenchannelQueues':{'method':'get','url':_0x2e7042['baseUrl']+'rpc/openchannel/queues'},'getFaxQueues':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1194')},'getVoiceQueuesPreview':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'rpc/voice/queues/preview/:id'},'getVoiceQueuesChannels':{'method':'get','url':_0x2e7042['baseUrl']+'rpc/voice/queues/channels'},'getVoiceQueuesChannel':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1cf0')},'getVoiceQueuesChannelHangup':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x20e1')},'getVoiceQueuesChannelRedirect':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd30')},'getOutbound':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x14e5')},'getOutboundChannels':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2399')},'getAgents':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1101')},'setAgentCapacity':{'method':_0x4ac86a('0x137e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x158b'),'params':{'id':_0x4ac86a('0x146c')}},'getTelephones':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1eeb')},'getTrunks':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x150e')},'getCampaigns':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x259c')},'getMailAccounts':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xe41')},'getFaxAccounts':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xb0b')},'getChatQueuesWaitingInteractions':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x9bb')},'getMailQueuesWaitingInteractions':{'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x139c')},'getOpenchannelQueuesWaitingInteractions':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1177')},'getOpenchannelQueuesIdWaitingInteractions':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x13a4')},'getSmsQueuesWaitingInteractions':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'rpc/sms/queues/waitinginteractions'},'getFaxQueuesWaitingInteractions':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x14e1')},'getWhatsappQueuesWaitingInteractions':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xefa')},'mailQueueNotify':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa90'),'params':{'id':_0x4ac86a('0x146c')}},'chatQueueNotify':{'method':'post','url':_0x2e7042['baseUrl']+'rpc/chat/queues/:id/notify','params':{'id':'@id'}},'faxQueueNotify':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1b8a'),'params':{'id':'@id'}},'smsQueueNotify':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x7ec'),'params':{'id':_0x4ac86a('0x146c')}},'openchannelQueueNotify':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x15fa'),'params':{'id':_0x4ac86a('0x146c')}},'agentNotify':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2709'),'params':{'id':_0x4ac86a('0x146c')}}}),_0x2e7042[_0x4ac86a('0x729')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x729'),{},{'fetch':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x152a')},'reset':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x24c')},'pull':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'version/pull'},'restart':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'version/restart'},'migrations':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'version/migrations'}}),_0x2e7042[_0x4ac86a('0x24f2')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x24f2'),{},{'killProcess':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'system/process/:pid/kill','params':{'pid':_0x4ac86a('0xcdb')}}}),_0x2e7042[_0x4ac86a('0x2c2')]=_0x230ea2(_0x2e7042['baseUrl']+'pm2/:id',{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e'),'isArray':!![]}}),_0x2e7042['user']=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x190c'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+'users/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'bulkCreate':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1478'),'isArray':!![]},'addContacts':{'isArray':!![],'method':'post','url':_0x2e7042['baseUrl']+'users/:id/contacts'},'changePassword':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x94c')},'addQueues':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x11c0')},'removeQueues':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/queues'},'addAvatar':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x37c')},'getAvatar':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x37c')},'getContacts':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/contacts'},'getQueues':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x11c0')},'getVoiceQueuesRt':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x19ef')},'getGroups':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/groups'},'getRecordings':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/recordings'},'getScreenRecordings':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1e36')},'getChatInteractions':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+'users/:id/chat/interactions'},'getOpenchannelInteractions':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1e77')},'getMailInteractions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/mail/interactions'},'getSmsInteractions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xc35')},'getFaxInteractions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1650')},'getWhatsappInteractions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c3')},'login':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1707')},'logout':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/logout'},'pause':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/pause'},'unpause':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/unpause'},'getTeams':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x224f')},'addTeams':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x224f')},'removeTeams':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/teams'},'getLists':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ed3')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/agents'},'addChatInteractions':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2137')},'removeChatInteractions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/chat_interactions'},'addMailInteractions':{'isArray':!![],'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x1bea')},'removeMailInteractions':{'isArray':![],'method':'delete','url':_0x2e7042['baseUrl']+'users/:id/mail_interactions'},'addFaxInteractions':{'isArray':!![],'method':'post','url':_0x2e7042['baseUrl']+'users/:id/fax_interactions'},'removeFaxInteractions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xca0')},'addSmsInteractions':{'isArray':!![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x100a')},'removeSmsInteractions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/sms_interactions'},'addOpenchannelInteractions':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x982')},'removeOpenchannelInteractions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x982')},'addWhatsappInteractions':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x166')},'removeWhatsappInteractions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x166')},'getVoicePrefixes':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2143')},'getFaxAccounts':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+'users/:id/fax_accounts'},'addFaxAccounts':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x112c')},'removeFaxAccounts':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/fax_accounts'},'getMailAccounts':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2120')},'addMailAccounts':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2120')},'removeMailAccounts':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2120')},'getOpenchannelAccounts':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x699')},'addOpenchannelAccounts':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x699')},'removeOpenchannelAccounts':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x699')},'getSmsAccounts':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/sms_accounts'},'addSmsAccounts':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1dd0')},'removeSmsAccounts':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1dd0')},'getChatWebsites':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x17c5')},'addChatWebsites':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x17c5')},'removeChatWebsites':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x17c5')},'getWhatsappAccounts':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2503')},'addWhatsappAccounts':{'isArray':!![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'users/:id/whatsapp_accounts'},'removeWhatsappAccounts':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2503')},'getSquareProjects':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x165b')},'addSquareProjects':{'isArray':!![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x165b')},'removeSquareProjects':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x165b')},'getScheduledCalls':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1eba')},'getApiKey':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1d5a')},'createApiKey':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d5a')},'removeApiKey':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1d5a')},'whoami':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'users/whoami'}}),_0x2e7042[_0x4ac86a('0x1c5f')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0xa67'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'voice/chanspy/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'voice/chanspy/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['voiceContext']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x154e'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1da8')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2641'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x14cb')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x250a'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x941')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'voice/extensions/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'addApplications':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xf46')}}),_0x2e7042[_0x4ac86a('0x0')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x20'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'voice/mohs/describe'},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'voice/mohs/:id/clone','params':{'includeAll':'@includeAll'}},'addSound':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xabe')},'removeSound':{'isArray':![],'method':'delete','url':_0x2e7042['baseUrl']+_0x4ac86a('0x41e')},'getSounds':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xabe')}}),_0x2e7042[_0x4ac86a('0x204c')]=_0x230ea2(_0x2e7042['baseUrl']+'voice/queues/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1362')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'voice/queues/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'getHoppers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'voice/queues/:id/hoppers'},'getHopperHistories':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2447')},'getHopperFinals':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2369')},'getHopperBlacks':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1960')},'getTeams':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1409')},'addTeams':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1409')},'removeTeams':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1409')},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'voice/queues/:id/users'},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1fce')},'getAgents':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x1fce')},'getMembers':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0xcbd')},'getLists':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xdaf')},'addLists':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xdaf')},'removeLists':{'isArray':!![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xdaf')},'getBlackLists':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'voice/queues/:id/blacklists'},'addBlackLists':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x7c8')},'removeBlackLists':{'isArray':!![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x7c8')}}),_0x2e7042[_0x4ac86a('0x52f')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x162e'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+'voice/recordings/describe'},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xbff'),'params':{'includeAll':_0x4ac86a('0x210e')}},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xebe'),'responseType':'arraybuffer','cache':![],'transformResponse':function(_0x41353b,_0x3e7ff9){const _0x3a7d2b=_0x4ac86a,_0x1619ce=_0x3e7ff9();return{'type':_0x1619ce[_0x3a7d2b('0xe51')],'length':_0x1619ce['content-length'],'buffer':_0x41353b};}},'downloads':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2092')},'runTranscribe':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2174')},'downloadTranscribe':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'voice/recordings/:id/transcribe','responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x4d25c9,_0x391e42){const _0x209b1a=_0x4ac86a,_0x1dae49=_0x391e42();return{'type':_0x1dae49['content-type'],'length':_0x1dae49[_0x209b1a('0x17e2')],'buffer':_0x4d25c9};}}}),_0x2e7042['screenRecording']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x13e5'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2509')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x9ab'),'params':{'includeAll':_0x4ac86a('0x210e')}},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'screen/recordings/:id/download','responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x2c0230,_0x12c43a){const _0x3a02a0=_0x4ac86a,_0x268c8d=_0x12c43a();return{'type':_0x268c8d[_0x3a02a0('0xe51')],'length':_0x268c8d[_0x3a02a0('0x17e2')],'buffer':_0x2c0230};}}}),_0x2e7042[_0x4ac86a('0x1a6b')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1681'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'voice/mails/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1154'),'params':{'includeAll':'@includeAll'}},'getMessages':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x77e')}}),_0x2e7042[_0x4ac86a('0xed8')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x114b'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x859')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1aec'),'params':{'includeAll':_0x4ac86a('0x210e')}},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa2b'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x47ba8b,_0x3ba228){const _0x5dc680=_0x4ac86a,_0x2d1b78=_0x3ba228();return{'type':_0x2d1b78[_0x5dc680('0xe51')],'length':_0x2d1b78['content-length'],'buffer':_0x47ba8b};}}}),_0x2e7042[_0x4ac86a('0x337')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x2705'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xbdf')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x19c5'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1793')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'voice/dials/reports/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2662')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2473'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0xf53')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'voice/agents/reports/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x494')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'voice/agents/reports/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x243')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'voice/queues/reports/:id',{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1be8')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'voice/queues/reports/:id/clone','params':{'includeAll':'@includeAll'}},'getVoiceQueuesReport':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x7fc')}}),_0x2e7042[_0x4ac86a('0x48c')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1f21'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'members/reports/describe'},'clone':{'method':'post','url':_0x2e7042['baseUrl']+'members/reports/:id/clone','params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0x1a93')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x27c8'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x118d')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x5b4'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['voiceTransferReport']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x156'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x242c')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x26e6'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0x1543')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c9d'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'mail/out_servers/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c1f'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0xb87')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x27bc'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+'mail/accounts/describe'},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x68e'),'params':{'includeAll':'@includeAll'}},'addDisposition':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x223')},'getDispositions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x223')},'removeDispositions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'mail/accounts/:id/dispositions'},'addAnswer':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x957')},'getAnswers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x957')},'removeAnswers':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x957')},'getImap':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x43d')},'addImap':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x43d')},'removeImap':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x43d')},'getSmtp':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1dfb')},'addSmtp':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1dfb')},'removeSmtp':{'isArray':![],'method':'delete','url':_0x2e7042['baseUrl']+_0x4ac86a('0x1dfb')},'addInteraction':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2281')},'getInteractions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2281')},'addApplications':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x21b4')},'getApplications':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'mail/accounts/:id/applications'},'getMessages':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ec6')},'send':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'mail/accounts/:id/send'},'verifySmtp':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x12c4')},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'mail/accounts/:id/users'},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd69')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd69')}}),_0x2e7042['mailQueue']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1efc'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x7c4')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x191f'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getMembers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'mail/queues/:id/members'},'getTeams':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x22ad')},'addTeams':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x22ad')},'removeTeams':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x22ad')},'addAgents':{'isArray':!![],'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x15e4')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x15e4')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x15e4')}}),_0x2e7042['mailSubstatus']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xda1'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2402')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x24ab'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0x95a')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c6e'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x12aa')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ea4'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addMessage':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'mail/interactions/:id/messages'},'getMessages':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa19')},'addTags':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x19ca')},'removeTags':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x19ca')},'download':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x24ef'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x1c1cf2,_0x573db3){const _0x3dcada=_0x4ac86a,_0x59fb9d=_0x573db3();return{'type':_0x59fb9d[_0x3dcada('0xe51')],'length':_0x59fb9d[_0x3dcada('0x17e2')],'buffer':_0x1c1cf2};}}}),_0x2e7042['mailMessage']=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x2305'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'mail/messages/describe'},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ac9'),'params':{'includeAll':_0x4ac86a('0x210e')}},'accept':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x3e7')},'reject':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042['baseUrl']+'mail/messages/:id/reject'},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xade'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x25aa80,_0x360160){const _0x522e76=_0x4ac86a,_0x36faa6=_0x360160();return{'type':_0x36faa6[_0x522e76('0xe51')],'length':_0x36faa6['content-length'],'buffer':_0x25aa80};}}}),_0x2e7042[_0x4ac86a('0xcde')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xb52'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x939')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xae3'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0x21f6')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0xb2a'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x136d')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x272b'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042['dashboard']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x17e1'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1b03')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1174'),'params':{'includeAll':'@includeAll'}},'addItem':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x55c')},'getItems':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x55c')}}),_0x2e7042[_0x4ac86a('0x2565')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'dashboards/items/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x6f6')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1936'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['faxAccount']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2163'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x8d')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1e6a'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addDisposition':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f90')},'getDispositions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f90')},'removeDispositions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f90')},'addAnswer':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'fax/accounts/:id/canned_answers'},'getAnswers':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'fax/accounts/:id/canned_answers'},'removeAnswers':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2441')},'addInteraction':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xdc9')},'getInteractions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xdc9')},'addApplications':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x161c')},'getApplications':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x161c')},'addAccountApplications':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x15a2')},'updateAccountApplications':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xccb')},'getMessages':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2222')},'send':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2368')},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1b1a')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1b1a')},'getAgents':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'fax/accounts/:id/users'}}),_0x2e7042['faxApplication']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x23be'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x674')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x28a'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['faxInteraction']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'fax/interactions/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x155d')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2664'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addMessage':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x6e0')},'getMessages':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'fax/interactions/:id/messages'},'addTags':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xa9a')},'removeTags':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa9a')},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x585'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x382037,_0x1cb5fd){const _0x478d7c=_0x1cb5fd();return{'type':_0x478d7c['content-type'],'length':_0x478d7c['content-length'],'buffer':_0x382037};}}}),_0x2e7042[_0x4ac86a('0x1cc')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'fax/messages/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x198c')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1676'),'params':{'includeAll':'@includeAll'}},'accept':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xf42')},'reject':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a26')},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x20ce'),'responseType':'arraybuffer','cache':![],'transformResponse':function(_0x531e8e,_0x2cfe25){const _0x4eec1b=_0x4ac86a,_0x2439aa=_0x2cfe25();return{'type':_0x2439aa[_0x4eec1b('0xe51')],'length':_0x2439aa[_0x4eec1b('0x17e2')],'buffer':_0x531e8e};}}}),_0x2e7042[_0x4ac86a('0x209c')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'fax/queues/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x14b6')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'fax/queues/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'getMembers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2434')},'getTeams':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x24dd')},'addTeams':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x24dd')},'removeTeams':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'fax/queues/:id/teams'},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x912')},'removeAgents':{'isArray':![],'method':'delete','url':_0x2e7042['baseUrl']+_0x4ac86a('0x912')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x912')}}),_0x2e7042[_0x4ac86a('0xf15')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1490'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1a49')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xbdb'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['smsAccount']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1de9'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xbb5')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'sms/accounts/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'addDisposition':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2118')},'getDispositions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2118')},'removeDispositions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2118')},'addAnswer':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'sms/accounts/:id/canned_answers'},'getAnswers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x161b')},'removeAnswers':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x161b')},'notify':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x15d3')},'addApplications':{'isArray':![],'method':'post','url':_0x2e7042['baseUrl']+'sms/accounts/:id/applications'},'getApplications':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x72e')},'getInteractions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x9bc')},'send':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1502')},'status':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1482')},'statusGet':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1482')},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d1c')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1d1c')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'sms/accounts/:id/users'}}),_0x2e7042[_0x4ac86a('0x59c')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x27ef'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'sms/applications/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x182e'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x22d8')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ca8'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c17')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x3d5'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addMessage':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'sms/interactions/:id/messages'},'getMessages':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x12fb')},'addTags':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'sms/interactions/:id/tags'},'removeTags':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2576')},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2431'),'responseType':'arraybuffer','cache':![],'transformResponse':function(_0x175bf8,_0x530180){const _0x283140=_0x4ac86a,_0xa2fdcd=_0x530180();return{'type':_0xa2fdcd['content-type'],'length':_0xa2fdcd[_0x283140('0x17e2')],'buffer':_0x175bf8};}}}),_0x2e7042[_0x4ac86a('0x1a45')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x41a'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x146e')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1976'),'params':{'includeAll':_0x4ac86a('0x210e')}},'accept':{'isArray':![],'method':'put','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2020')},'reject':{'isArray':![],'method':'put','url':_0x2e7042['baseUrl']+'sms/messages/:id/reject'},'status':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x657')}}),_0x2e7042[_0x4ac86a('0x193f')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'sms/queues/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'sms/queues/describe'},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x150c'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getMembers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1835')},'getTeams':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x14fa')},'addTeams':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x14fa')},'removeTeams':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x14fa')},'addAgents':{'isArray':!![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ab3')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ab3')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ab3')}}),_0x2e7042[_0x4ac86a('0x1963')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1adf'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x687')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'openchannel/accounts/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'addDisposition':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a65')},'getDispositions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a65')},'removeDispositions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a65')},'addAnswer':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x25f5')},'getAnswers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'openchannel/accounts/:id/canned_answers'},'removeAnswers':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'openchannel/accounts/:id/canned_answers'},'notify':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2799')},'addApplications':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'openchannel/accounts/:id/applications'},'getApplications':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x214c')},'getInteractions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c10')},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2110')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'openchannel/accounts/:id/users'},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2110')},'send':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x460')}}),_0x2e7042[_0x4ac86a('0x873')]=_0x230ea2(_0x2e7042['baseUrl']+'openchannel/applications/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'openchannel/applications/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x950'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x17ff')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xc3'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+'openchannel/interactions/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x102b'),'params':{'includeAll':'@includeAll'}},'addMessage':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'openchannel/interactions/:id/messages'},'getMessages':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1496')},'addTags':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x148d')},'removeTags':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x148d')},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1444'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x375d53,_0x4146ad){const _0x48c842=_0x4146ad();return{'type':_0x48c842['content-type'],'length':_0x48c842['content-length'],'buffer':_0x375d53};}}}),_0x2e7042[_0x4ac86a('0x18c1')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'openchannel/messages/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x1efe')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1fdf'),'params':{'includeAll':'@includeAll'}},'accept':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2155')},'reject':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xe58')}}),_0x2e7042[_0x4ac86a('0x20a1')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x236b'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x6b0')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xfca'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getMembers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1a58')},'getTeams':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'openchannel/queues/:id/teams'},'addTeams':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2859')},'removeTeams':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2859')},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x533')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x533')},'getAgents':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x533')}}),_0x2e7042[_0x4ac86a('0x2681')]=_0x230ea2(_0x2e7042['baseUrl']+'chat/websites/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/websites/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x14f2'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addDisposition':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d39')},'getDispositions':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x1d39')},'removeDispositions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d39')},'addAnswer':{'isArray':![],'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x4b9')},'getAnswers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x4b9')},'removeAnswers':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x4b9')},'addLogo':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/websites/:id/logo'},'addAvatar':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xc8c')},'addCustomerAvatar':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x990')},'addSystemAvatar':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/websites/:id/system_avatar'},'getLogo':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1420')},'getAvatar':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xc8c')},'getCustomerAvatar':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x990')},'getSystemAvatar':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x961')},'notify':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/websites/:id/notify'},'offline':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/websites/:id/offline'},'addInteraction':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xf56')},'getInteractions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xf56')},'getSnippet':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1d9b')},'addApplications':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1ab8')},'getApplications':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1ab8')},'addProactiveActions':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1f25')},'getProactiveActions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f25')},'getFields':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x10fe')},'getOfflineMessages':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xec7')},'addAgents':{'isArray':!![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/websites/:id/users'},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xc30')},'getAgents':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/websites/:id/users'}}),_0x2e7042[_0x4ac86a('0x265f')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xe85'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2867')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd81'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0x4f6')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a37'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1276')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x75'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1809')]=_0x230ea2(_0x2e7042['baseUrl']+'chat/interactions/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xfd8')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/interactions/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'createVidaooSession':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/interactions/:id/vidaoo'},'customUpdate':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2854')},'abandon':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x8d7')},'attachmentUpload':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/interactions/:id/attachment_upload'},'attachmentDownload':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ceb')},'close':{'isArray':![],'method':'put','url':_0x2e7042['baseUrl']+_0x4ac86a('0x1360')},'addMessage':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2640')},'getMessages':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2640')},'getMyMessages':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1bee')},'addTags':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/interactions/:id/tags'},'removeTags':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1117')},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'chat/interactions/:id/download','responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x37595d,_0x5e2da0){const _0x1fa323=_0x4ac86a,_0x580033=_0x5e2da0();return{'type':_0x580033[_0x1fa323('0xe51')],'length':_0x580033['content-length'],'buffer':_0x37595d};}}}),_0x2e7042[_0x4ac86a('0x1203')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1726'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1da5')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/messages/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'accept':{'isArray':![],'method':'put','url':_0x2e7042['baseUrl']+'chat/messages/:id/accept'},'reject':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xbcb')}}),_0x2e7042['chatOfflineMessage']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x19d3'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2486')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/offline_messages/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['chatQueue']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x46a'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x157c')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x14b8'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getMembers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x838')},'getTeams':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1fde')},'addTeams':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/queues/:id/teams'},'removeTeams':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/queues/:id/teams'},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2199')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/queues/:id/users'},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2199')}}),_0x2e7042[_0x4ac86a('0x1278')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1bff'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x64d')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xfa6'),'params':{'includeAll':'@includeAll'}},'getUnread':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x109c')},'addMembers':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x202d')},'getMembers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/groups/:id/members'},'removeMembers':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x202d')},'addMessage':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x798')},'getMessages':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x798')}}),_0x2e7042[_0x4ac86a('0x2407')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'chat/proactive_actions/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/proactive_actions/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/proactive_actions/:id/clone','params':{'includeAll':'@includeAll'}}}),_0x2e7042['cmCompany']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xff7'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x97a')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x278f'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addContacts':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'cm/companies/:id/contacts'},'getContacts':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'cm/companies/:id/contacts'}}),_0x2e7042[_0x4ac86a('0x276e')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x23b8'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1d07')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x42a'),'params':{'includeAll':_0x4ac86a('0x210e')}},'merge':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x82a')},'bulkCreate':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2712')},'getTags':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x13c7')},'setTags':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'cm/contacts/:id/tags'},'getHoppers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x8a')},'getHopperHistories':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x997')},'getHopperFinals':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x125b')},'getJscriptySessions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1a54')},'uploadCsv':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'cm/contacts/csv'},'upload':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xf3')},'import':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'cm/contacts/upload/:id'}}),_0x2e7042[_0x4ac86a('0x26cf')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1583'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2153')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1954'),'params':{'includeAll':'@includeAll'}},'getPreview':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1176')},'getOpenContacts':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1fed')}}),_0x2e7042['cmHopperBlack']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'cm/hopper_black/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a1')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2de'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x163f')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0xbe7'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x10be')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1cae'),'params':{'includeAll':_0x4ac86a('0x210e')}},'countContactsQueueCampaignHopperFinal':{'isArray':!![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2011')},'countContactsIvrCampaignHopperFinal':{'isArray':!![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1659')},'moveContactsQueueCampaignHopperFinal':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'cm/hopper_final/voice/queue/moveContacts/:id'},'moveContactsIvrCampaignHopperFinal':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1af5')},'checkContactHopper':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x11da')}}),_0x2e7042[_0x4ac86a('0x2583')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'cm/hopper_history/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1b41')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x238b'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0xf57')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xfd7'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xe33')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'cm/custom_fields/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1f0e')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'actions/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x16f1')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2254'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x16cf')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x17e3'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f6a')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'automations/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'addConditions':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'automations/:id/conditions'},'getConditions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd43')},'addActions':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'automations/:id/actions'},'getActions':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1e57')}}),_0x2e7042[_0x4ac86a('0x136c')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'canned_answers/:id',{'id':'@id'},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x74a')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xed0'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x43f')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1672'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x13ec')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1b05'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['condition']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'conditions/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2625')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x10dc'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['interval']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'intervals/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xced')},'clone':{'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0xe81'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addInterval':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xdc7')},'getIntervals':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'intervals/:id/sub_intervals'},'addIntervals':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xcfc')}}),_0x2e7042['pause']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c7a'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'pauses/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x7bf'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x2845')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'cdr/:id',{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f65')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x718'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1339')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x285a'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'voiceQueuesLog/describe'},'clone':{'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x732'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x8ae')]=_0x230ea2(_0x2e7042['baseUrl']+'schedules/:id',{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'schedules/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2878'),'params':{'includeAll':_0x4ac86a('0x210e')}},'run':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x4c5')}}),_0x2e7042['sound']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'sounds/:id',{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x12e2')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1529'),'params':{'includeAll':_0x4ac86a('0x210e')}},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'sounds/:id/download','responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x18dd36,_0x4204bc){const _0x4c7fda=_0x4ac86a,_0x5c8031=_0x4204bc();return{'type':_0x5c8031[_0x4c7fda('0xe51')],'length':_0x5c8031[_0x4c7fda('0x17e2')],'buffer':_0x18dd36};}},'delete':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2778')}}),_0x2e7042[_0x4ac86a('0x270')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1e04'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xf05')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'tags/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1cc6')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1ece'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x114d')},'clone':{'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0xcb5'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x25e2')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'triggers/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x784')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x26ce'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addAllCondition':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x209d')},'addAnyCondition':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'triggers/:id/any_conditions'},'getAllConditions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'triggers/:id/all_conditions'},'getAnyConditions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x128a')},'addAction':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1545')},'getActions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1545')}}),_0x2e7042[_0x4ac86a('0x26e0')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x586'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x228b')},'clone':{'method':'post','url':_0x2e7042['baseUrl']+'variables/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x3e8')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x227e'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x12a2')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2752'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0xbc0')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1fe7'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1380')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'integrations/reports/:id/clone','params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0x197f')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'analytics/custom_reports/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xaed')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x15fd'),'params':{'includeAll':'@includeAll'}},'preview':{'isArray':!![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1541')},'run':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'analytics/custom_reports/:id/run'},'query':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x137c')}}),_0x2e7042[_0x4ac86a('0x20ec')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1462'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1e00')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'analytics/default_reports/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'preview':{'isArray':!![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1dd')},'run':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1e99')},'query':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x219e')}}),_0x2e7042[_0x4ac86a('0x1911')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x15af'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x983')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'analytics/extracted_reports/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x4e3'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x3c5190,_0x3f6553){const _0x62636a=_0x3f6553();return{'type':_0x62636a['content-type'],'length':_0x62636a['content-length'],'buffer':_0x3c5190};}}}),_0x2e7042[_0x4ac86a('0x1c97')]=_0x230ea2(_0x2e7042['baseUrl']+'analytics/metrics/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1833')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xb15'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['analyticFieldReport']=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x236a'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'analytics/field_reports/describe'},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x22a8'),'params':{'includeAll':'@includeAll'}},'bulkCreate':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x53f'),'isArray':!![]},'bulkDestroy':{'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa13'),'isArray':!![]},'addFields':{'isArray':!![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x17fc')}}),_0x2e7042[_0x4ac86a('0x1aaf')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'analytics/tree_reports/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'analytics/tree_reports/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2044'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0xf30')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x234'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd40')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x251a'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getConfigurations':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x284f')},'addConfiguration':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x284f')},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1076')}}),_0x2e7042[_0x4ac86a('0x161f')]=_0x230ea2(_0x2e7042['baseUrl']+'integrations/salesforce/configurations/:id',{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/salesforce/configurations/describe'},'clone':{'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0xad3'),'params':{'includeAll':'@includeAll'}},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x3e2')},'getSubjects':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/salesforce/configurations/:id/subjects'},'getDescriptions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ff2')}}),_0x2e7042[_0x4ac86a('0x73e')]=_0x230ea2(_0x2e7042['baseUrl']+'integrations/salesforce/fields/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/salesforce/fields/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1bae'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['intSugarcrmAccount']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x269e'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x72')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x8fe'),'params':{'includeAll':'@includeAll'}},'getConfigurations':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'integrations/sugarcrm/accounts/:id/configurations'},'addConfiguration':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/sugarcrm/accounts/:id/configurations'},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xc0c')}}),_0x2e7042['intSugarcrmConfiguration']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'integrations/sugarcrm/configurations/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/sugarcrm/configurations/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'integrations/sugarcrm/configurations/:id/clone','params':{'includeAll':'@includeAll'}},'getFields':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x295')},'getSubjects':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x74c')},'getDescriptions':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x23f2')}}),_0x2e7042[_0x4ac86a('0x1007')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x73b'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1712')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd91'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0xe2b')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x19c1'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1748')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xc2d'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getConfigurations':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'integrations/desk/accounts/:id/configurations'},'addConfiguration':{'isArray':![],'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x87d')},'getFields':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x313')}}),_0x2e7042[_0x4ac86a('0x2451')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ac2'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1350')},'clone':{'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x14f3'),'params':{'includeAll':'@includeAll'}},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1bca')},'getSubjects':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/desk/configurations/:id/subjects'},'getDescriptions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'integrations/desk/configurations/:id/descriptions'},'getTags':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x248e')},'setTags':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x248e')}}),_0x2e7042[_0x4ac86a('0x24ec')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2318'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x21a7')},'clone':{'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x202'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0xb6c')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'integrations/zoho/accounts/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa53')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1374'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getConfigurations':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x572')},'addConfiguration':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'integrations/zoho/accounts/:id/configurations'},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/zoho/accounts/:id/fields'}}),_0x2e7042[_0x4ac86a('0x8d1')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xcdd'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x107a')},'clone':{'method':'post','url':_0x2e7042['baseUrl']+'integrations/zoho/configurations/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2528')},'getSubjects':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2670')},'getDescriptions':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x8f0')}}),_0x2e7042[_0x4ac86a('0x1ec1')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2069'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/zoho/fields/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/zoho/fields/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1a0')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1b8d'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/zendesk/accounts/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1f8a'),'params':{'includeAll':'@includeAll'}},'getConfigurations':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1452')},'addConfiguration':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1452')},'getFields':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f95')}}),_0x2e7042[_0x4ac86a('0xeeb')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1138'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1192')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x17d'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d64')},'getSubjects':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/zendesk/configurations/:id/subjects'},'getDescriptions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/zendesk/configurations/:id/descriptions'},'getTags':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+'integrations/zendesk/configurations/:id/tags'},'setTags':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xe80')}}),_0x2e7042[_0x4ac86a('0xb26')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x281a'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xf98')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/zendesk/fields/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x15dc')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x27f3'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/freshdesk/accounts/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x14c7'),'params':{'includeAll':'@includeAll'}},'getConfigurations':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa5d')},'addConfiguration':{'isArray':![],'method':'post','url':_0x2e7042['baseUrl']+'integrations/freshdesk/accounts/:id/configurations'},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1349')}}),_0x2e7042['intFreshdeskConfiguration']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'integrations/freshdesk/configurations/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x23da')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x155'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1dee')},'getSubjects':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2221')},'getDescriptions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x214b')},'getTags':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x2567')},'setTags':{'isArray':!![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2567')}}),_0x2e7042[_0x4ac86a('0x847')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xfe2'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2cc')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xe6'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042['intVtigerAccount']=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0xf54'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/vtiger/accounts/describe'},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/vtiger/accounts/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'getConfigurations':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x3ca')},'addConfiguration':{'isArray':![],'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x3ca')},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1532')}}),_0x2e7042[_0x4ac86a('0x25dd')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1307'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042['baseUrl']+'integrations/vtiger/configurations/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/vtiger/configurations/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}},'getFields':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/vtiger/configurations/:id/fields'},'getSubjects':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x164e')},'getDescriptions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xffb')}}),_0x2e7042['intVtigerField']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x19cb'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x153')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x71f'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x2169')]=_0x230ea2(_0x2e7042['baseUrl']+'integrations/servicenow/accounts/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/servicenow/accounts/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x269c'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getConfigurations':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2a2')},'addConfiguration':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2a2')},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x15f5')}}),_0x2e7042[_0x4ac86a('0x11e5')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'integrations/servicenow/configurations/:id',{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xc20')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f35'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/servicenow/configurations/:id/fields'},'getSubjects':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x104c')},'getDescriptions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1805')}}),_0x2e7042[_0x4ac86a('0x1c55')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'integrations/servicenow/fields/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/servicenow/fields/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1030'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042['intDynamics365Account']=_0x230ea2(_0x2e7042['baseUrl']+'integrations/dynamics365/accounts/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xcfd')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1e7a'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getConfigurations':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xf7a')},'addConfiguration':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xf7a')},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/dynamics365/accounts/:id/fields'}}),_0x2e7042[_0x4ac86a('0x1f08')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x21ce'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/dynamics365/configurations/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xdf'),'params':{'includeAll':'@includeAll'}},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x276a')},'getSubjects':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xfdf')},'getDescriptions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2098')}}),_0x2e7042[_0x4ac86a('0x130b')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x2786'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x10ff')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xf65'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0xa71')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'integrations/freshsales/accounts/:id',{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'integrations/freshsales/accounts/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x23eb'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getConfigurations':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x353')},'addConfiguration':{'isArray':![],'method':'post','url':_0x2e7042['baseUrl']+'integrations/freshsales/accounts/:id/configurations'},'getFields':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x27d3')}}),_0x2e7042['intFreshsalesConfiguration']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x39f'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x136')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1b82'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getSubjects':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1e0c')},'getDescriptions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a32')},'getFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xb00')}}),_0x2e7042[_0x4ac86a('0xddb')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x23a9'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xee')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1538'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042['network']=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1653'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'networks/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x64'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['chatQueueReport']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1031'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2855')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'chat/reports/queue/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1a73')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'chat/internal/messages/:id',{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1605')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x5bb'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getUsers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'chat/internal/messages/users'}}),_0x2e7042[_0x4ac86a('0x1c08')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'jscripty/answers/reports/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'jscripty/answers/reports/describe'},'clone':{'method':'post','url':_0x2e7042['baseUrl']+'jscripty/answers/reports/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1015')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa1d'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'jscripty/questions/reports/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x54b'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['jscriptySessionReport']=_0x230ea2(_0x2e7042['baseUrl']+'jscripty/sessions/reports/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xab6')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f3a'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getQuestions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a8a')}}),_0x2e7042['smsQueueReport']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x67d'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'sms/reports/queue/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'sms/reports/queue/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['squareReport']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'square/reports/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x275b')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c28'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1497')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x21a6'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x15ad')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2417'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0xa8b')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x976'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'jscripty/projects/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1480'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getSessions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'jscripty/projects/:id/sessions'},'getAnswers':{'isArray':![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+'jscripty/projects/:id/answers'},'getSummary':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x15b9'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0xdf2eca,_0x448e52){const _0x3b10ec=_0x4ac86a,_0x152eef=_0x448e52();return{'type':_0x152eef[_0x3b10ec('0xe51')],'length':_0x152eef[_0x3b10ec('0x17e2')],'buffer':_0xdf2eca};}}}),_0x2e7042['setting']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x6a9'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x748')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2492'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addLogo':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xab8')},'addLogoLogin':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x21b7')},'getLogo':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xab8')},'getLogoLogin':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x21b7')},'gdpr':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x258f')},'addPreferred':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x13b5')},'getPreferred':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x13b5')},'addFavicon':{'isArray':![],'method':'post','url':_0x2e7042['baseUrl']+'settings/:id/favicon'},'getFavicon':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2366')}}),_0x2e7042[_0x4ac86a('0x39a')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x23d6'),{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1569')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x31d'),'params':{'includeAll':_0x4ac86a('0x210e')}},'test':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1bad')}}),_0x2e7042[_0x4ac86a('0x27ea')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'square/projects/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x7ef')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2042'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addUsers':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'square/projects/:id/users'},'removeUsers':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xf5f')},'getUsers':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0xf5f')}}),_0x2e7042[_0x4ac86a('0x823')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1d35'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x176d')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xc81'),'params':{'includeAll':_0x4ac86a('0x210e')}},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xb4b'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x471593,_0x4d07a5){const _0x363e1d=_0x4ac86a,_0x2965dd=_0x4d07a5();return{'type':_0x2965dd[_0x363e1d('0xe51')],'length':_0x2965dd[_0x363e1d('0x17e2')],'buffer':_0x471593};}}}),_0x2e7042[_0x4ac86a('0x1f1b')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f57'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'square/messages/describe'},'clone':{'method':'post','url':_0x2e7042['baseUrl']+'square/messages/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0xd88')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'teams/:id',{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd7c')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x405'),'params':{'includeAll':'@includeAll'}},'getQueues':{'isArray':!![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2346')},'addQueues':{'isArray':!![],'method':'post','url':_0x2e7042['baseUrl']+_0x4ac86a('0x2346')},'removeQueues':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2346')},'addAgents':{'isArray':!![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'teams/:id/users'},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x157b')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x157b')}}),_0x2e7042[_0x4ac86a('0xace')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f2c'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042['baseUrl']+'license/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a09'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x6e9')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x23e8'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x6a0')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xe5b'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getHoppers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x18e9')},'getHopperHistories':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x21fa')},'getHopperFinals':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'campaigns/:id/hopper_finals'},'getHopperBlacks':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+'campaigns/:id/hopper_black'},'getLists':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'campaigns/:id/lists'},'addLists':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x195f')},'removeLists':{'isArray':!![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x195f')},'getBlackLists':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1785')},'addBlackLists':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'campaigns/:id/blacklists'},'removeBlackLists':{'isArray':!![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1785')}}),_0x2e7042[_0x4ac86a('0x815')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2742'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c79')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xc6a'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x34')]=_0x230ea2(_0x2e7042['baseUrl']+'attachments/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd19')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x500'),'params':{'includeAll':_0x4ac86a('0x210e')}},'download':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+'attachments/:id/download','responseType':'arraybuffer','cache':![],'transformResponse':function(_0x265d6d,_0x17b384){const _0x2e06a3=_0x4ac86a,_0x4428ae=_0x17b384();return{'type':_0x4428ae[_0x2e06a3('0xe51')],'length':_0x4428ae[_0x2e06a3('0x17e2')],'buffer':_0x265d6d};}}}),_0x2e7042[_0x4ac86a('0x1cd1')]=_0x230ea2(_0x2e7042['baseUrl']+'plugins/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x20e2')},'clone':{'method':'post','url':_0x2e7042['baseUrl']+'plugins/:id/clone','params':{'includeAll':'@includeAll'}},'download':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xdf2'),'responseType':'arraybuffer','cache':![],'transformResponse':function(_0x340735,_0x5a00f8){const _0x41befe=_0x4ac86a,_0x380771=_0x5a00f8();return{'type':_0x380771[_0x41befe('0xe51')],'length':_0x380771[_0x41befe('0x17e2')],'buffer':_0x340735};}},'upload':{'isArray':![],'method':'post','url':_0x2e7042['baseUrl']+'plugins/'},'delete':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x27be')},'webhookGet':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x1ba2')},'webhookPost':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1ba2')}}),_0x2e7042['mailTransferReport']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'mail/reports/transfer/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'mail/reports/transfer/describe'},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d38'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x268e')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd79'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1b9')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1814'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0x21e0')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d74'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1d7f')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1aa3'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x19')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'openchannel/reports/transfer/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1457')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x13e8'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x280e')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+'sms/reports/transfer/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'sms/reports/transfer/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'sms/reports/transfer/:id/clone','params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x259b')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1645'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1e9d')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1cfa'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addDisposition':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'cm/lists/:id/dispositions'},'getDispositions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x9cc')},'removeDispositions':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x9cc')},'addContacts':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1533')},'getContacts':{'isArray':!![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1533')},'getContactsCsv':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1b75'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x5bb064,_0x21acfe){const _0x40ac71=_0x4ac86a,_0x16cdca=_0x21acfe();return{'type':_0x16cdca[_0x40ac71('0xe51')],'length':_0x16cdca['content-length'],'buffer':_0x5bb064};}},'addCustomField':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x82c')},'getCustomFields':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x82c')},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xead')},'removeAgents':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xead')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xead')}}),_0x2e7042[_0x4ac86a('0x110a')]=_0x230ea2(_0x2e7042['baseUrl']+'voice/prefixes/:id',{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa04')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1f05'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2554')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2554')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2554')}}),_0x2e7042[_0x4ac86a('0x2a')]=_0x230ea2(_0x2e7042['baseUrl']+'userProfiles/:id',{'id':'@id'},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1308')},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d67'),'params':{'includeAll':'@includeAll'}},'addSections':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'userProfiles/:id/sections'},'removeSections':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x3e0')},'getSections':{'isArray':!![],'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x3e0')},'addResources':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'userProfiles/:id/resources'},'removeResources':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2028')},'getResources':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2028')}}),_0x2e7042[_0x4ac86a('0x22df')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x725'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xd83')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2781'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042['userProfileResource']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1bcb'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'userProfile/resources/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x22ac'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0x1290')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1bec'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'notifications/describe'},'clone':{'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d26'),'params':{'includeAll':_0x4ac86a('0x210e')}},'sendNotification':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'notifications/'}}),_0x2e7042['whatsappAccount']=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x16bd'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xa88')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x101e'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addDisposition':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2c0')},'getDispositions':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2c0')},'removeDispositions':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2c0')},'addAnswer':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1a13')},'getAnswers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'whatsapp/accounts/:id/canned_answers'},'removeAnswers':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1a13')},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1c0b')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c0b')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1c0b')},'addApplications':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'whatsapp/accounts/:id/applications'},'getApplications':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x101a')},'notify':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x1e13')},'send':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+'whatsapp/accounts/:id/send'}}),_0x2e7042[_0x4ac86a('0x588')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x535'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x150')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x11e'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x1db7')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0xe12'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'whatsapp/interactions/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2294'),'params':{'includeAll':_0x4ac86a('0x210e')}},'addMessage':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x12f5')},'getMessages':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x12f5')},'addTags':{'isArray':![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+'whatsapp/interactions/:id/tags'},'removeTags':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x23ea')},'download':{'isArray':![],'method':'get','url':_0x2e7042['baseUrl']+_0x4ac86a('0x1105'),'responseType':_0x4ac86a('0x1fd7'),'cache':![],'transformResponse':function(_0x5a2aaf,_0x58ed43){const _0x500aa6=_0x4ac86a,_0x368f49=_0x58ed43();return{'type':_0x368f49[_0x500aa6('0xe51')],'length':_0x368f49[_0x500aa6('0x17e2')],'buffer':_0x5a2aaf};}}}),_0x2e7042[_0x4ac86a('0xd01')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0x1ba1'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'whatsapp/messages/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0xa55'),'params':{'includeAll':_0x4ac86a('0x210e')}},'accept':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x16a6')},'reject':{'isArray':![],'method':_0x4ac86a('0x137e'),'url':_0x2e7042['baseUrl']+'whatsapp/messages/:id/reject'},'status':{'isArray':![],'method':'post','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x256d')}}),_0x2e7042['whatsappQueueReport']=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x14c8'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+'whatsapp/reports/queue/describe'},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+'whatsapp/reports/queue/:id/clone','params':{'includeAll':'@includeAll'}}}),_0x2e7042[_0x4ac86a('0x93d')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xc6c'),{'id':'@id'},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1f23')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1220'),'params':{'includeAll':_0x4ac86a('0x210e')}}}),_0x2e7042[_0x4ac86a('0x25e5')]=_0x230ea2(_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1250'),{'id':_0x4ac86a('0x146c')},{'update':{'method':_0x4ac86a('0x137e')},'describe':{'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x287c')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0xbd1'),'params':{'includeAll':_0x4ac86a('0x210e')}},'getMembers':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x2b1')},'getTeams':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042['baseUrl']+_0x4ac86a('0x270f')},'addTeams':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x270f')},'removeTeams':{'isArray':![],'method':'delete','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x270f')},'addAgents':{'isArray':!![],'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d3f')},'removeAgents':{'isArray':![],'method':_0x4ac86a('0xd7e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d3f')},'getAgents':{'isArray':![],'method':_0x4ac86a('0x1e6e'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x1d3f')}}),_0x2e7042[_0x4ac86a('0x44')]=_0x230ea2(_0x2e7042['baseUrl']+_0x4ac86a('0xfe8'),{'id':_0x4ac86a('0x146c')},{'update':{'method':'put'},'describe':{'method':'get','url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x2311')},'clone':{'method':_0x4ac86a('0x21df'),'url':_0x2e7042[_0x4ac86a('0x2713')]+_0x4ac86a('0x440'),'params':{'includeAll':'@includeAll'}}}),_0x2e7042;}const _0xf23928=_0x9f2481;_0x473e6e[_0x189033('0x14be')]=[_0x189033('0xd2e'),'toastyConfigProvider'];function _0x473e6e(_0x526c2f,_0x1defe5){const _0x308c0f=_0x189033;_0x1defe5[_0x308c0f('0x2457')]({'position':_0x308c0f('0x95'),'sound':![],'html':!![],'theme':'material'}),_0x526c2f[_0x308c0f('0x1ad4')](_0x308c0f('0xa93'),{'urlTemplate':'{part}/i18n/{lang}.json'}),_0x526c2f[_0x308c0f('0x12b8')]('en'),_0x526c2f[_0x308c0f('0x1624')](null);}const _0x11dfc8=_0x473e6e;_0x142f98['$inject']=[_0x189033('0x1d7c'),'$translate',_0x189033('0x17e4'),_0x189033('0x56b'),'toasty'];function _0x142f98(_0xdd2f32,_0x3aa037,_0x2fd1f1,_0x115fcc,_0x5437e7){const _0x4e72e4=_0x189033,_0x485aa0=this;_0x485aa0[_0x4e72e4('0xdb5')]=_0xdd2f32[_0x4e72e4('0xdb5')],_0x485aa0[_0x4e72e4('0x2655')]='ltr';const _0x4b41b5=['ar','fa','he'],_0x1672a8=_0x2fd1f1['get'](_0x4e72e4('0x2772'));_0x1672a8&&(_0x3aa037[_0x4e72e4('0x2775')](_0x1672a8),_0x4b41b5[_0x4e72e4('0x824')](_0x1672a8)>=0x0&&_0x115fcc['setting'][_0x4e72e4('0x1e6e')]({'id':0x1})[_0x4e72e4('0xe53')]['then'](function(_0x32d2be){const _0x512961=_0x4e72e4;_0x32d2be&&_0x32d2be[_0x512961('0x1d2e')]&&(_0x485aa0[_0x512961('0x2655')]=_0x512961('0x882'));})[_0x4e72e4('0x130a')](function(_0x2b7760){const _0x12969e=_0x4e72e4;_0x2b7760&&_0x5437e7[_0x12969e('0x52a')]({'title':_0x12969e('0x85b'),'msg':_0x2b7760[_0x12969e('0x5a5')]?_0x2b7760['data'][_0x12969e('0x8c2')]||_0x2b7760['message']||_0x2b7760:_0x2b7760[_0x12969e('0x8c2')]||_0x2b7760});}));}const _0x27779a=_0x142f98;_0x114a96['$inject']=[_0x189033('0x1d08')],_0x3a7c53[_0x189033('0x14be')]=[_0x189033('0x241e'),_0x189033('0x1d08')];function _0x3a7c53(_0x4d11f0,_0x4860bd){return function(_0x39f6e7){const _0x4fd321=a0_0x4e0a,_0x46d28e=new Date(),_0x2857d6=new Date(_0x39f6e7);if(_0x2857d6[_0x4fd321('0x260f')]()===_0x46d28e[_0x4fd321('0x260f')]()&&_0x2857d6[_0x4fd321('0x110')]()===_0x46d28e[_0x4fd321('0x110')]()&&_0x2857d6[_0x4fd321('0x6f7')]()===_0x46d28e[_0x4fd321('0x6f7')]())return _0x4d11f0(_0x4fd321('0x270e'))(_0x2857d6['getTime'](),'shortTime');if(_0x2857d6[_0x4fd321('0x260f')]()===_0x46d28e['getDate']()-0x1&&_0x2857d6[_0x4fd321('0x110')]()===_0x46d28e[_0x4fd321('0x110')]()&&_0x2857d6['getFullYear']()===_0x46d28e['getFullYear']())return _0x4860bd[_0x4fd321('0x2728')](_0x4fd321('0xeb5'))+'\x20'+_0x4d11f0(_0x4fd321('0x270e'))(_0x2857d6[_0x4fd321('0x140c')](),_0x4fd321('0x118'));return _0x4d11f0(_0x4fd321('0x270e'))(_0x2857d6['getTime'](),_0x4fd321('0x1d0a'));};}function _0x290511(){return function(_0x442922,_0x3578b7,_0x29cc63){const _0x455e42={};let _0x12e851=0x0,_0x307bb0;for(_0x307bb0 in _0x442922){_0x12e851>=_0x29cc63&&(_0x455e42[_0x307bb0]=_0x442922[_0x307bb0]);if(++_0x12e851===_0x29cc63+_0x3578b7)break;}return _0x455e42;};}function _0x517340(){const _0x406969=_0x189033,_0x264445=[{'value':_0x406969('0x194a')},{'value':'feb'},{'value':_0x406969('0x2079')},{'value':_0x406969('0x442')},{'value':_0x406969('0x11f8')},{'value':_0x406969('0x18ae')},{'value':'jul'},{'value':_0x406969('0xa69')},{'value':_0x406969('0x1910')},{'value':_0x406969('0x22d7')},{'value':_0x406969('0x1021')},{'value':_0x406969('0x19f9')}],_0x58bbab=[{'value':'1'},{'value':'2'},{'value':'3'},{'value':'4'},{'value':'5'},{'value':'6'},{'value':'7'},{'value':'8'},{'value':'9'},{'value':'10'},{'value':'11'},{'value':'12'}],_0x2ae15b=[{'value':_0x406969('0x203d')},{'value':_0x406969('0x75c')},{'value':_0x406969('0x192b')},{'value':_0x406969('0xd49')},{'value':_0x406969('0x1a34')},{'value':_0x406969('0x7f')},{'value':'sun'}],_0x4e1d29=[0x1,0x2,0x3,0x4,0x5,0x6,0x7,0x8,0x9,0xa,0xb,0xc,0xd,0xe,0xf,0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f];return{'getMonthName':function(){return _0x264445;},'getMonthNumber':function(){return _0x58bbab;},'getDaysOfWeek':function(){return _0x2ae15b;},'getDaysOfMonth':function(){return _0x4e1d29;}};}function _0x114a96(_0x65332b){const _0x33534b=_0x189033;return{'Today':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x3b')),'Yesterday':_0x65332b['instant'](_0x33534b('0xeb5')),'This\x20Week':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x242b')),'Last\x20Week':_0x65332b['instant'](_0x33534b('0x1507')),'This\x20Month':_0x65332b['instant'](_0x33534b('0x2750')),'Last\x20Month':_0x65332b['instant'](_0x33534b('0x1c4f')),'This\x20Year':_0x65332b[_0x33534b('0x2728')]('DASHBOARDS.THIS_YEAR'),'Last\x20Year':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x18a0')),'January':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x1b1d')),'February':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x180')),'March':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x1790')),'April':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x129e')),'May':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x11e8')),'June':_0x65332b[_0x33534b('0x2728')]('DASHBOARDS.JUNE'),'July':_0x65332b[_0x33534b('0x2728')](_0x33534b('0xdde')),'August':_0x65332b[_0x33534b('0x2728')]('DASHBOARDS.AUGUST'),'September':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x1c2a')),'October':_0x65332b[_0x33534b('0x2728')](_0x33534b('0xb8c')),'November':_0x65332b[_0x33534b('0x2728')](_0x33534b('0xb7b')),'December':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x590')),'Mon':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x282')),'Tue':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x13b4')),'Wed':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x13cb')),'Thu':_0x65332b[_0x33534b('0x2728')](_0x33534b('0x194b')),'Fri':_0x65332b[_0x33534b('0x2728')]('DASHBOARDS.FRI'),'Sat':_0x65332b[_0x33534b('0x2728')]('DASHBOARDS.SAT'),'Sun':_0x65332b[_0x33534b('0x2728')]('DASHBOARDS.SUN')};}function _0x3b6d82(){return{'enqueue':function(_0x13d7c5){const _0x4b5c45=a0_0x4e0a;this['tail']=this['tail']?this[_0x4b5c45('0xb8')]['finally'](_0x13d7c5):_0x13d7c5();}};}const _0x33a0ec=_0x180212['p']+_0x189033('0x1589'),_0x18d2eb=_0x180212['p']+_0x189033('0x1625'),_0x593e21=_0x180212['p']+_0x189033('0x73'),_0x29e770=_0x180212['p']+_0x189033('0x8d3'),_0xfb691=_0x180212['p']+_0x189033('0x263'),_0x4d974c=_0x180212['p']+'src/js/modules/footer/layouts/vertical-navigation/footer.html/footer.html',_0x47ef83=_0x180212['p']+_0x189033('0x2527');_0x3a12ce['$inject']=[_0x189033('0x1398'),'$urlRouterProvider',_0x189033('0x355')];function _0x3a12ce(_0x2ce077,_0x3f39da,_0x4b42ec){const _0x1a6923=_0x189033;_0x4b42ec[_0x1a6923('0x23d9')](!![]),_0x3f39da[_0x1a6923('0x2831')](_0x1a6923('0x2776'));let _0x53b2f0;angular[_0x1a6923('0xfc0')]([_0x1a6923('0x1d78')])[_0x1a6923('0x85')]([_0x1a6923('0x17e4'),function(_0x2ffd68){_0x53b2f0=_0x2ffd68;}]);const _0x1d5168=_0x53b2f0['get'](_0x1a6923('0x2367'))||_0x1a6923('0x1d2'),_0x241b93={'verticalNavigation':{'main':_0x222444,'toolbar':_0x33a0ec,'navigation':_0x593e21,'header':_0xfb691,'footer':_0x4d974c},'verticalNavigationFullwidthToolbar':{'main':_0x43564,'toolbar':'','navigation':_0x593e21},'verticalNavigationFullwidthToolbar2':{'main':_0x2c9abe,'toolbar':'','navigation':_0x29e770},'horizontalNavigation':{'main':_0x28db1f,'toolbar':'','navigation':_0x18d2eb},'contentOnly':{'main':_0x568ca3,'toolbar':'','navigation':''},'contentWithToolbar':{'main':_0xc244c3,'toolbar':'','navigation':''}};_0x2ce077[_0x1a6923('0x2598')](_0x1a6923('0x1d75'),{'abstract':!![],'views':{'main@':{'templateUrl':_0x241b93[_0x1d5168][_0x1a6923('0xe64')],'controller':_0x1a6923('0xaa2')},'toolbar@app':{'templateUrl':_0x241b93[_0x1d5168][_0x1a6923('0x95f')],'controller':_0x1a6923('0x1cd2')},'navigation@app':{'templateUrl':_0x241b93[_0x1d5168]['navigation'],'controller':_0x1a6923('0x10b5')},'quickPanel@app':{'templateUrl':_0x47ef83,'controller':_0x1a6923('0x1c04')},'header@app':{'templateUrl':_0x241b93[_0x1d5168][_0x1a6923('0x2034')],'controller':_0x1a6923('0x2885')},'footer@app':{'templateUrl':_0x241b93[_0x1d5168]['footer'],'controller':_0x1a6923('0x1776')}},'resolve':{'license':[_0x1a6923('0x4b1'),function(_0x133a6a){const _0x39be89=_0x1a6923;return _0x133a6a[_0x39be89('0xed7')](_0x39be89('0x12e5'));}],'setting':[_0x1a6923('0x4b1'),function(_0x21c5d2){const _0x5bb8c1=_0x1a6923;return _0x21c5d2['resolve'](_0x5bb8c1('0x271'),{'id':0x1});}]}});}const _0x4e4051=_0x3a12ce;_0x561adc['$inject']=['$transitions','LoadingIndicatorService'];function _0x561adc(_0x275f9f,_0x2c82bc){const _0x23f0df=_0x189033;_0x275f9f[_0x23f0df('0x38a')]({},_0x2c82bc[_0x23f0df('0x26aa')]),_0x275f9f['onFinish']({},_0x2c82bc[_0x23f0df('0xa1c')]);}const _0xd57c17=_0x561adc;var _0x11729d=_0x180212(0x15ef);_0x5254e3[_0x189033('0x14be')]=['$rootScope',_0x189033('0xba1')];function _0x5254e3(_0x3eedb5,_0x3100a2){let _0x1c57a0;function _0x495db8(){const _0x13fe0e=a0_0x4e0a,_0x12669c=!![]?window['io']:0x0,_0x317abd={'query':_0x13fe0e('0x9')+_0x3100a2[_0x13fe0e('0x20b2')]()['id'],'transports':[_0x13fe0e('0x27c9'),_0x13fe0e('0x416')]};_0x1c57a0=!![]?_0x12669c(_0x317abd):0x0;}return{'connect':_0x495db8,'on':function(_0x3c3388,_0x42a057){_0x42a057=_0x42a057||angular['noop'],!_0x1c57a0&&_0x495db8(),_0x1c57a0['on'](_0x3c3388,function(){const _0x41ca38=a0_0x4e0a,_0x3bdfd9=arguments;_0x3eedb5[_0x41ca38('0x2b0')](function(){_0x42a057['apply'](_0x1c57a0,_0x3bdfd9);});});},'onWithoutApply':function(_0x5bf385,_0x1b697a){const _0x497646=a0_0x4e0a;_0x1b697a=_0x1b697a||angular[_0x497646('0x1126')],!_0x1c57a0&&_0x495db8(),_0x1c57a0['on'](_0x5bf385,function(){_0x1b697a['apply'](_0x1c57a0,arguments);});},'emit':function(_0x2362cb,_0x59b799,_0x1a33fe){const _0x117557=a0_0x4e0a;_0x1a33fe=_0x1a33fe||angular[_0x117557('0x1126')],!_0x1c57a0&&_0x495db8(),_0x1c57a0['emit'](_0x2362cb,_0x59b799,function(){const _0x2c86b7=_0x117557,_0x404aff=arguments;_0x3eedb5[_0x2c86b7('0x2b0')](function(){const _0xef740e=_0x2c86b7;_0x1a33fe[_0xef740e('0x1dd8')](_0x1c57a0,_0x404aff);});});},'removeAllListeners':function(_0xe2a1f0){const _0x1d073f=a0_0x4e0a;!_0x1c57a0&&_0x495db8(),_0x1c57a0[_0x1d073f('0x1b9e')](_0xe2a1f0);},'removeListener':function(_0x2c84d3,_0x2211d3){!_0x1c57a0&&_0x495db8(),_0x1c57a0['removeListener'](_0x2c84d3,_0x2211d3);},'disconnect':function(){const _0x380fc3=a0_0x4e0a;!_0x1c57a0&&_0x495db8(),_0x1c57a0[_0x380fc3('0x1346')]();}};}const _0x5c751f=_0x5254e3;_0x5000fb[_0x189033('0x14be')]=[_0x189033('0x7a5'),_0x189033('0x1b'),_0x189033('0x1d08'),'msNavigationService',_0x189033('0x2066'),'Auth',_0x189033('0x1d70'),_0x189033('0xace'),_0x189033('0x56b'),_0x189033('0x260a')];function _0x5000fb(_0x50fefe,_0x339e1a,_0x32f50f,_0x420df6,_0x171f49,_0x34c4c3,_0x287339,_0x601867,_0x4d7836,_0xe5ca17){const _0x28fd8e=_0x189033,_0x2dff49=this;_0x287339[_0x28fd8e('0x1045')]();function _0x44506f(){const _0x3d67a3=_0x28fd8e;return _0x34c4c3[_0x3d67a3('0x20b2')]()&&_0x34c4c3[_0x3d67a3('0xca1')](_0x3d67a3('0x2327'));}_0x2dff49['isAgent']=_0x44506f;function _0x24fe70(_0x938ccb,_0x1b7c7f){const _0x5e47f6=_0x28fd8e;return{'id':_0x938ccb,'title':_0x1b7c7f[_0x5e47f6('0x60a')]||_0x5e47f6('0x2688'),'state':'app.dashboards.custom','stateParams':_0x1b7c7f,'weight':0x2,'hidden':function(){const _0x18f444=_0x5e47f6;return _0x34c4c3[_0x18f444('0xca1')]('agent')||!_0x34c4c3[_0x18f444('0x5e3')](_0x938ccb)&&!_0x34c4c3[_0x18f444('0xca1')](_0x18f444('0x20c2'));}};}function _0x440d21(_0x10c818,_0x29bc67){const _0xf04c0=_0x28fd8e;return{'id':_0x10c818,'title':_0x29bc67['name']||_0xf04c0('0x2688'),'state':_0xf04c0('0x2394'),'stateParams':_0x29bc67,'weight':0x2,'hidden':function(){const _0x2462e2=_0xf04c0;return _0x34c4c3[_0x2462e2('0xca1')](_0x2462e2('0x2327'))||!_0x34c4c3[_0x2462e2('0x5e3')](_0x10c818)&&!_0x34c4c3[_0x2462e2('0xca1')](_0x2462e2('0x20c2'));}};}function _0x17b00e(_0x218ff0,_0x39d58c){const _0x1930b1=_0x28fd8e,_0x7eb9df={'user':_0x2e3ca0()[_0x1930b1('0x24d0')](_0x34c4c3[_0x1930b1('0x20b2')](),['id',_0x1930b1('0x60a'),_0x1930b1('0x11bc'),_0x1930b1('0x1c92'),_0x1930b1('0xecb'),_0x1930b1('0x1d43'),_0x1930b1('0x11f0')])};_0x39d58c[_0x1930b1('0x480')]=_0x19c0ff()['render'](_0x39d58c[_0x1930b1('0x480')],_0x7eb9df),_0x171f49[_0x1930b1('0x2716')](_0x1930b1('0x26bf')+_0x218ff0,{'id':_0x218ff0,'title':_0x39d58c['name'],'translate':_0x39d58c[_0x1930b1('0x60a')],'state':_0x1930b1('0x34c')+_0x39d58c['id'],'stateParams':_0x39d58c,'view':_0x1930b1('0x1cd1'),'icon':_0x39d58c[_0x1930b1('0x21bf')],'weight':0xc,'hidden':function(){return!_0x34c4c3['hasPermission'](_0x218ff0);}});}_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x346'),{'title':_0x28fd8e('0x1c9b'),'group':!![],'weight':0x1,'hidden':function(){const _0x104eb6=_0x28fd8e;return _0x34c4c3[_0x104eb6('0xca1')](_0x104eb6('0x2327'));}}),_0x4d7836[_0x28fd8e('0x729')][_0x28fd8e('0x1e6e')]()[_0x28fd8e('0xe53')][_0x28fd8e('0x683')](function(_0x2ae812){const _0x57084d=_0x28fd8e;_0x2dff49[_0x57084d('0x729')]=_0x2ae812&&_0x2ae812['current']?_0x2ae812[_0x57084d('0xb24')]:_0x57084d('0x20c');})[_0x28fd8e('0x130a')](function(){const _0x35d6e3=_0x28fd8e;_0x2dff49[_0x35d6e3('0x729')]=_0x35d6e3('0x20c');})[_0x28fd8e('0x2874')](function(){const _0x3145db=_0x28fd8e;_0x420df6['saveItem'](_0x3145db('0x729'),{'title':_0x3145db('0xc19')+_0x2dff49[_0x3145db('0x729')],'group':!![],'weight':0x2,'hidden':function(){const _0x544056=_0x3145db;return _0x34c4c3[_0x544056('0xca1')](_0x544056('0x2327'));}});});function _0x8cfa58(_0x5c2bd0){return _0x2e3ca0()['map'](_0x5c2bd0['children'],function(_0x12fc55){return _0x12fc55['id'];});}_0x34c4c3['isLoggedIn']()&&(_0x601867['gray']&&_0x287339[_0x28fd8e('0xd33')]({'msg':_0x32f50f[_0x28fd8e('0x2728')](_0x28fd8e('0x2388')),'showClose':!![],'timeout':![]}),_0x4d7836[_0x28fd8e('0x1a6')]['get']()[_0x28fd8e('0xe53')][_0x28fd8e('0x683')](function(_0x35ac7e){const _0x7b9cce=_0x28fd8e;let _0x4094c7=0x0;for(let _0x44fa6c=0x0;_0x44fa6c<_0x35ac7e[_0x7b9cce('0xf5d')]['length'];_0x44fa6c+=0x1){_0x4094c7=0x1869f+_0x35ac7e['rows'][_0x44fa6c]['id'],_0x420df6[_0x7b9cce('0x2716')]('apps.dashboards.custom_'+_0x4094c7,_0x24fe70(_0x4094c7,_0x35ac7e[_0x7b9cce('0xf5d')][_0x44fa6c]));}}),_0x4d7836[_0x28fd8e('0x1cd1')][_0x28fd8e('0x1e6e')]({'active':!![]})[_0x28fd8e('0xe53')]['then'](function(_0x597324){const _0x1dc37f=_0x28fd8e;let _0x48efe9=0x0;if(_0x597324[_0x1dc37f('0x50d')]){const _0x108a95=_0x2e3ca0()[_0x1dc37f('0x25')](_0x597324[_0x1dc37f('0xf5d')],function(_0x34004){const _0x342a6a=_0x1dc37f;return _0x34004['sidebar']!=_0x342a6a('0x649')&&_0x34004['sidebar']!=_0x342a6a('0x1d1d');});if(_0x108a95[_0x1dc37f('0x1564')]>0x0){_0x420df6['saveItem'](_0x1dc37f('0x1fca'),{'id':0x76c,'title':_0x1dc37f('0x145b'),'translate':'PLUGINS.PLUGINS','icon':'icon-apps','permissions':{'hidden':!![]},'weight':0x11,'hidden':function(){const _0xa7ff94=_0x1dc37f;return _0x34c4c3[_0xa7ff94('0xca1')](_0xa7ff94('0x2327'))||!_0x34c4c3[_0xa7ff94('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0xa7ff94('0xca1')](_0xa7ff94('0x20c2'));}});for(let _0x251324=0x0;_0x251324<_0x108a95[_0x1dc37f('0x1564')];_0x251324+=0x1){_0x48efe9=0x15b38+_0x108a95[_0x251324]['id'],_0x420df6['saveItem'](_0x1dc37f('0x497')+_0x48efe9,_0x440d21(_0x48efe9,_0x108a95[_0x251324]));}_0x420df6[_0x1dc37f('0x671')]();}const _0x1a6f7d=_0x2e3ca0()[_0x1dc37f('0x25')](_0x597324[_0x1dc37f('0xf5d')],function(_0x584467){const _0x5041c7=_0x1dc37f;return _0x584467['sidebar']!=_0x5041c7('0x649')&&_0x584467[_0x5041c7('0x12f')]!=_0x5041c7('0x2514');});if(_0x1a6f7d[_0x1dc37f('0x1564')]>0x0)for(let _0x2b3145=0x0;_0x2b3145<_0x1a6f7d['length'];_0x2b3145+=0x1){_0x48efe9=0x15b38+_0x1a6f7d[_0x2b3145]['id'],_0x17b00e(_0x48efe9,_0x1a6f7d[_0x2b3145]);}}})),_0x601867['custom']&&!_0xe5ca17[_0x28fd8e('0x6d4')]&&_0xe5ca17[_0x28fd8e('0xa82')]&&angular[_0x28fd8e('0x1fcc')](_0x28fd8e('0x1390'))['html'](_0xe5ca17[_0x28fd8e('0xa82')]),_0x420df6[_0x28fd8e('0x2716')]('apps.dashboards',{'id':0x64,'title':'Dashboards','translate':_0x28fd8e('0x151f'),'icon':_0x28fd8e('0x1e64'),'weight':0x2,'hidden':function(){const _0x18aa29=_0x28fd8e;return _0x34c4c3[_0x18aa29('0xca1')](_0x18aa29('0x2327'))||!_0x34c4c3[_0x18aa29('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0x18aa29('0xca1')](_0x18aa29('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.dashboards.general',{'id':0x65,'title':_0x28fd8e('0x22f'),'route':'','translate':_0x28fd8e('0x13bb'),'state':'app.dashboards.general','weight':0x1,'hidden':function(){const _0x3c6bbd=_0x28fd8e;return _0x34c4c3[_0x3c6bbd('0xca1')](_0x3c6bbd('0x2327'))||!_0x34c4c3[_0x3c6bbd('0x5e3')](0x65)&&!_0x34c4c3['hasRole'](_0x3c6bbd('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1983'),{'id':0xc8,'title':_0x28fd8e('0x22cd'),'translate':_0x28fd8e('0x1885'),'icon':'icon-account-multiple','weight':0x3,'hidden':function(){const _0x3c07b6=_0x28fd8e;return _0x34c4c3['hasRole'](_0x3c07b6('0x2327'))||!_0x34c4c3['hasChildrenPermissions'](_0x8cfa58(this))&&!_0x34c4c3[_0x3c07b6('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1ca'),{'id':0xc9,'title':_0x28fd8e('0x2139'),'route':'user','translate':_0x28fd8e('0x19b5'),'state':_0x28fd8e('0x1e7e'),'weight':0x1,'permissions':{'hidden':!![]},'hidden':function(){const _0x37f445=_0x28fd8e;return _0x34c4c3['hasRole'](_0x37f445('0x2327'))||_0x34c4c3[_0x37f445('0xca1')]('user')||!_0x34c4c3[_0x37f445('0x5e3')](0xc9)&&!_0x34c4c3[_0x37f445('0xca1')](_0x37f445('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x207a'),{'id':0xca,'title':_0x28fd8e('0x1bc0'),'route':'user','translate':_0x28fd8e('0x1169'),'state':_0x28fd8e('0x1550'),'weight':0x1,'hidden':function(){const _0x2186e9=_0x28fd8e;return _0x34c4c3[_0x2186e9('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0xca)&&!_0x34c4c3[_0x2186e9('0xca1')](_0x2186e9('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.staff.telephones',{'id':0xcb,'title':'Telephones','route':_0x28fd8e('0xc96'),'translate':_0x28fd8e('0x1b7a'),'state':_0x28fd8e('0x1bde'),'weight':0x1,'hidden':function(){const _0x263676=_0x28fd8e;return _0x34c4c3[_0x263676('0xca1')]('agent')||!_0x34c4c3[_0x263676('0x5e3')](0xcb)&&!_0x34c4c3[_0x263676('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')]('apps.staff.teams',{'id':0xcc,'title':_0x28fd8e('0x15bc'),'route':_0x28fd8e('0xd88'),'translate':_0x28fd8e('0xa70'),'state':_0x28fd8e('0x2326'),'weight':0x1,'hidden':function(){const _0x42a6d6=_0x28fd8e;return _0x34c4c3[_0x42a6d6('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0xcc)&&!_0x34c4c3['hasRole'](_0x42a6d6('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x159a'),{'id':0xcd,'title':_0x28fd8e('0x1e39'),'route':_0x28fd8e('0x2a'),'translate':_0x28fd8e('0x1a39'),'state':_0x28fd8e('0x1d5d'),'weight':0x1,'permissions':{'hidden':!![]},'hidden':function(){const _0x238c6b=_0x28fd8e;return _0x34c4c3[_0x238c6b('0xca1')](_0x238c6b('0x2327'))||!_0x34c4c3['hasPermission'](0xcd)&&!_0x34c4c3['hasRole'](_0x238c6b('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x23de'),{'id':0x12c,'title':_0x28fd8e('0x6a1'),'translate':'CONTACTMANAGER.CONTACTMANAGER','icon':'icon-account-circle','weight':0x4,'license':'cm','hidden':function(){const _0x1739a9=_0x28fd8e;return!_0x601867['cm']||_0x34c4c3['hasRole'](_0x1739a9('0x2327'))||!_0x34c4c3['hasChildrenPermissions'](_0x8cfa58(this))&&!_0x34c4c3['hasRole'](_0x1739a9('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.contactmanager.lists',{'id':0x12d,'title':'Lists','route':'cmList','translate':_0x28fd8e('0x1a9e'),'state':_0x28fd8e('0x147b'),'weight':0x2,'hidden':function(){const _0x51cae8=_0x28fd8e;return _0x34c4c3[_0x51cae8('0xca1')](_0x51cae8('0x2327'))||!_0x34c4c3[_0x51cae8('0x5e3')](0x12d)&&!_0x34c4c3['hasRole']('admin');}}),_0x420df6[_0x28fd8e('0x2716')]('apps.contactmanager.companies',{'id':0x12e,'title':_0x28fd8e('0x2229'),'route':_0x28fd8e('0x27db'),'translate':_0x28fd8e('0xb3e'),'state':'app.contactmanager.companies','weight':0x3,'hidden':function(){const _0x3d8dc9=_0x28fd8e;return _0x34c4c3[_0x3d8dc9('0xca1')](_0x3d8dc9('0x2327'))||!_0x34c4c3[_0x3d8dc9('0x5e3')](0x12e)&&!_0x34c4c3[_0x3d8dc9('0xca1')](_0x3d8dc9('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.contactmanager.globalCustomFields',{'id':0x130,'title':_0x28fd8e('0x2ac'),'route':_0x28fd8e('0xf57'),'translate':_0x28fd8e('0x2c7'),'state':_0x28fd8e('0x16da'),'weight':0x4,'permissions':{'association':![]},'hidden':function(){const _0x446795=_0x28fd8e;return _0x34c4c3[_0x446795('0xca1')](_0x446795('0x2327'))||!_0x34c4c3[_0x446795('0x5e3')](0x130)&&!_0x34c4c3['hasRole']('admin');}}),_0x420df6['saveItem'](_0x28fd8e('0x11a3'),{'id':0x12f,'title':_0x28fd8e('0xdb2'),'route':'','translate':_0x28fd8e('0x192c'),'state':_0x28fd8e('0x1e45'),'weight':0x1,'permissions':{'association':![]},'hidden':function(){const _0x34c687=_0x28fd8e;return _0x34c4c3[_0x34c687('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0x12f)&&!_0x34c4c3[_0x34c687('0xca1')](_0x34c687('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0xf39'),{'id':0x190,'title':_0x28fd8e('0x378'),'translate':_0x28fd8e('0x18b2'),'icon':'icon-phone','weight':0x5,'license':_0x28fd8e('0xcf2'),'hidden':function(){const _0x4f891a=_0x28fd8e;return!_0x601867[_0x4f891a('0xcf2')]||_0x34c4c3[_0x4f891a('0xca1')](_0x4f891a('0x2327'))||!_0x34c4c3[_0x4f891a('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0x4f891a('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x15e5'),{'id':0x191,'title':_0x28fd8e('0x88d'),'route':_0x28fd8e('0x204c'),'translate':_0x28fd8e('0x224c'),'state':'app.voice.voiceQueues','weight':0x1,'channel':_0x28fd8e('0xcf2'),'hidden':function(){const _0x3fea0e=_0x28fd8e;return _0x34c4c3['hasRole']('agent')||!_0x34c4c3[_0x3fea0e('0x5e3')](0x191)&&!_0x34c4c3[_0x3fea0e('0xca1')](_0x3fea0e('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0x5f0'),{'id':0x192,'title':_0x28fd8e('0x1b63'),'route':_0x28fd8e('0x14cb'),'translate':_0x28fd8e('0x6a6'),'state':_0x28fd8e('0x2202'),'weight':0x1,'hidden':function(){const _0x59954a=_0x28fd8e;return _0x34c4c3[_0x59954a('0xca1')](_0x59954a('0x2327'))||!_0x34c4c3[_0x59954a('0x5e3')](0x192)&&!_0x34c4c3[_0x59954a('0xca1')](_0x59954a('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1a21'),{'id':0x193,'title':_0x28fd8e('0x2e3'),'route':_0x28fd8e('0x14cb'),'translate':_0x28fd8e('0x2722'),'state':_0x28fd8e('0x10c7'),'weight':0x1,'hidden':function(){const _0x7f837e=_0x28fd8e;return _0x34c4c3[_0x7f837e('0xca1')](_0x7f837e('0x2327'))||!_0x34c4c3['hasPermission'](0x193)&&!_0x34c4c3[_0x7f837e('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x287a'),{'id':0x194,'title':_0x28fd8e('0x26c8'),'route':_0x28fd8e('0x14cb'),'translate':'VOICE.INTERNALROUTES','state':_0x28fd8e('0x1d76'),'weight':0x1,'hidden':function(){const _0x33dd83=_0x28fd8e;return _0x34c4c3['hasRole'](_0x33dd83('0x2327'))||!_0x34c4c3[_0x33dd83('0x5e3')](0x194)&&!_0x34c4c3['hasRole'](_0x33dd83('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x2622'),{'id':0x195,'title':'Contexts','route':_0x28fd8e('0x1e4d'),'translate':_0x28fd8e('0x84c'),'state':'app.voice.contexts','weight':0x1,'hidden':function(){const _0x4b5c02=_0x28fd8e;return _0x34c4c3['hasRole'](_0x4b5c02('0x2327'))||!_0x34c4c3[_0x4b5c02('0x5e3')](0x195)&&!_0x34c4c3[_0x4b5c02('0xca1')](_0x4b5c02('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0x1bf1'),{'id':0x196,'title':_0x28fd8e('0x1a4a'),'route':_0x28fd8e('0x1a6b'),'translate':_0x28fd8e('0x199b'),'state':_0x28fd8e('0x238a'),'weight':0x1,'hidden':function(){const _0x2b41c0=_0x28fd8e;return _0x34c4c3[_0x2b41c0('0xca1')](_0x2b41c0('0x2327'))||!_0x34c4c3[_0x2b41c0('0x5e3')](0x196)&&!_0x34c4c3['hasRole'](_0x2b41c0('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1387'),{'id':0x197,'title':_0x28fd8e('0x27d2'),'route':_0x28fd8e('0x0'),'translate':_0x28fd8e('0x21cf'),'state':_0x28fd8e('0x1472'),'weight':0x1,'hidden':function(){const _0x3fab8d=_0x28fd8e;return _0x34c4c3[_0x3fab8d('0xca1')](_0x3fab8d('0x2327'))||!_0x34c4c3[_0x3fab8d('0x5e3')](0x197)&&!_0x34c4c3['hasRole'](_0x3fab8d('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xcb8'),{'id':0x198,'title':_0x28fd8e('0x1b76'),'route':_0x28fd8e('0x52f'),'translate':_0x28fd8e('0x27c7'),'state':'app.voice.voiceRecordings','weight':0x1,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x4e204b=_0x28fd8e;return _0x34c4c3['hasRole']('agent')||!_0x34c4c3[_0x4e204b('0x5e3')](0x198)&&!_0x34c4c3['hasRole']('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1c69'),{'id':0x199,'title':_0x28fd8e('0x1a6d'),'route':_0x28fd8e('0x1c5f'),'translate':_0x28fd8e('0x2161'),'state':_0x28fd8e('0x254'),'weight':0x1,'hidden':function(){const _0x1dbe01=_0x28fd8e;return _0x34c4c3[_0x1dbe01('0xca1')](_0x1dbe01('0x2327'))||!_0x34c4c3[_0x1dbe01('0x5e3')](0x199)&&!_0x34c4c3[_0x1dbe01('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x22ec'),{'id':0x19a,'title':_0x28fd8e('0x2770'),'route':'voicePrefix','translate':_0x28fd8e('0x1aa4'),'state':_0x28fd8e('0x204'),'weight':0x1,'hidden':function(){const _0x5ebdc1=_0x28fd8e;return _0x34c4c3[_0x5ebdc1('0xca1')](_0x5ebdc1('0x2327'))||!_0x34c4c3[_0x5ebdc1('0x5e3')](0x19a)&&!_0x34c4c3[_0x5ebdc1('0xca1')](_0x5ebdc1('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0xc91'),{'id':0x19b,'title':'Realtime','route':'','translate':_0x28fd8e('0xe6c'),'state':_0x28fd8e('0x170b'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x1bd925=_0x28fd8e;return _0x34c4c3[_0x1bd925('0xca1')](_0x1bd925('0x2327'))||!_0x34c4c3[_0x1bd925('0x5e3')](0x19b)&&!_0x34c4c3['hasRole'](_0x1bd925('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xb36'),{'id':0x1f4,'title':_0x28fd8e('0x2071'),'translate':'CHAT.CHAT','icon':_0x28fd8e('0xa46'),'weight':0x6,'license':_0x28fd8e('0x24e'),'hidden':function(){const _0x4b9e3d=_0x28fd8e;return!_0x601867[_0x4b9e3d('0x24e')]||_0x34c4c3[_0x4b9e3d('0xca1')]('agent')||!_0x34c4c3[_0x4b9e3d('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0x4b9e3d('0xca1')](_0x4b9e3d('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x467'),{'id':0x1f5,'title':_0x28fd8e('0x507'),'route':'chatQueue','translate':_0x28fd8e('0x2218'),'state':'app.chat.chatQueues','weight':0x1,'channel':_0x28fd8e('0x24e'),'hidden':function(){const _0x5d8168=_0x28fd8e;return _0x34c4c3[_0x5d8168('0xca1')](_0x5d8168('0x2327'))||!_0x34c4c3[_0x5d8168('0x5e3')](0x1f5)&&!_0x34c4c3[_0x5d8168('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x10ea'),{'id':0x1f6,'title':_0x28fd8e('0x1a18'),'route':_0x28fd8e('0x2681'),'translate':_0x28fd8e('0xa8d'),'state':_0x28fd8e('0x1a78'),'weight':0x1,'channel':_0x28fd8e('0x24e'),'hidden':function(){const _0x3564b4=_0x28fd8e;return _0x34c4c3['hasRole']('agent')||!_0x34c4c3[_0x3564b4('0x5e3')](0x1f6)&&!_0x34c4c3[_0x3564b4('0xca1')](_0x3564b4('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x141c'),{'id':0x1fe,'title':'Realtime','route':'','translate':_0x28fd8e('0x2445'),'state':_0x28fd8e('0x10ee'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x20ef52=_0x28fd8e;return _0x34c4c3['hasRole'](_0x20ef52('0x2327'))||!_0x34c4c3['hasPermission'](0x1fe)&&!_0x34c4c3[_0x20ef52('0xca1')](_0x20ef52('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xd93'),{'id':0x258,'title':_0x28fd8e('0x24f1'),'translate':_0x28fd8e('0x18f'),'icon':_0x28fd8e('0x2420'),'weight':0x7,'license':'mail','hidden':function(){const _0x5c2f19=_0x28fd8e;return!_0x601867[_0x5c2f19('0x129f')]||_0x34c4c3[_0x5c2f19('0xca1')](_0x5c2f19('0x2327'))||!_0x34c4c3[_0x5c2f19('0x1522')](_0x8cfa58(this))&&!_0x34c4c3['hasRole'](_0x5c2f19('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.mail.mailQueues',{'id':0x259,'title':'MailQueues','route':_0x28fd8e('0x2160'),'translate':_0x28fd8e('0x1989'),'state':_0x28fd8e('0x2b'),'weight':0x1,'channel':'mail','hidden':function(){const _0x1bf97a=_0x28fd8e;return _0x34c4c3[_0x1bf97a('0xca1')](_0x1bf97a('0x2327'))||!_0x34c4c3[_0x1bf97a('0x5e3')](0x259)&&!_0x34c4c3[_0x1bf97a('0xca1')](_0x1bf97a('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xb03'),{'id':0x25a,'title':_0x28fd8e('0x2672'),'route':_0x28fd8e('0xb87'),'translate':_0x28fd8e('0x15f'),'state':_0x28fd8e('0x1b93'),'weight':0x1,'channel':_0x28fd8e('0x129f'),'hidden':function(){const _0x3606b2=_0x28fd8e;return _0x34c4c3[_0x3606b2('0xca1')]('agent')||!_0x34c4c3[_0x3606b2('0x5e3')](0x25a)&&!_0x34c4c3[_0x3606b2('0xca1')](_0x3606b2('0x20c2'));}}),_0x420df6['saveItem']('apps.mail.mailSubtatuses',{'id':0x25b,'title':'MailSubstatuses','route':_0x28fd8e('0x1577'),'translate':'MAIL.MAILSUBSTATUSES','state':_0x28fd8e('0x87b'),'weight':0x1,'channel':_0x28fd8e('0x129f'),'permissions':{'association':![]},'hidden':function(){const _0x4803fb=_0x28fd8e;return _0x34c4c3[_0x4803fb('0xca1')](_0x4803fb('0x2327'))||!_0x34c4c3[_0x4803fb('0x5e3')](0x25b)&&!_0x34c4c3[_0x4803fb('0xca1')](_0x4803fb('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.mail.realtime',{'id':0x262,'title':'Realtime','route':'','translate':_0x28fd8e('0x13b8'),'state':'app.mail.realtime','weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x5b03c2=_0x28fd8e;return _0x34c4c3[_0x5b03c2('0xca1')]('agent')||!_0x34c4c3[_0x5b03c2('0x5e3')](0x262)&&!_0x34c4c3[_0x5b03c2('0xca1')](_0x5b03c2('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xbe2'),{'id':0x2bc,'title':'Sms','translate':_0x28fd8e('0x1b2'),'icon':_0x28fd8e('0x1a87'),'weight':0x8,'license':'messaging','hidden':function(){return!_0x601867['messaging']||_0x34c4c3['hasRole']('agent')||!_0x34c4c3['hasChildrenPermissions'](_0x8cfa58(this))&&!_0x34c4c3['hasRole']('admin');}}),_0x420df6[_0x28fd8e('0x2716')]('apps.sms.smsQueues',{'id':0x2bd,'title':_0x28fd8e('0xd0d'),'route':_0x28fd8e('0x193f'),'translate':'SMS.SMSQUEUES','state':_0x28fd8e('0x2571'),'weight':0x1,'channel':_0x28fd8e('0x1285'),'hidden':function(){const _0x4b12e9=_0x28fd8e;return _0x34c4c3[_0x4b12e9('0xca1')](_0x4b12e9('0x2327'))||!_0x34c4c3[_0x4b12e9('0x5e3')](0x2bd)&&!_0x34c4c3[_0x4b12e9('0xca1')](_0x4b12e9('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0xee6'),{'id':0x2be,'title':_0x28fd8e('0x334'),'route':_0x28fd8e('0xa0e'),'translate':_0x28fd8e('0x187f'),'state':_0x28fd8e('0x16'),'weight':0x1,'channel':_0x28fd8e('0x1285'),'hidden':function(){const _0x4b316a=_0x28fd8e;return _0x34c4c3[_0x4b316a('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0x2be)&&!_0x34c4c3[_0x4b316a('0xca1')](_0x4b316a('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1f4d'),{'id':0x2c6,'title':'Realtime','route':'','translate':'SMS.REALTIME','state':_0x28fd8e('0x2535'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x2a1e24=_0x28fd8e;return _0x34c4c3[_0x2a1e24('0xca1')]('agent')||!_0x34c4c3[_0x2a1e24('0x5e3')](0x2c6)&&!_0x34c4c3['hasRole'](_0x2a1e24('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x280c'),{'id':0x320,'title':'Openchannel','translate':_0x28fd8e('0x1294'),'icon':_0x28fd8e('0x13f1'),'weight':0x9,'license':_0x28fd8e('0x1261'),'hidden':function(){const _0x391253=_0x28fd8e;return!_0x601867[_0x391253('0x1261')]||_0x34c4c3['hasRole'](_0x391253('0x2327'))||!_0x34c4c3[_0x391253('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0x391253('0xca1')](_0x391253('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.openchannel.openchannelQueues',{'id':0x321,'title':_0x28fd8e('0x3da'),'route':_0x28fd8e('0x20a1'),'translate':_0x28fd8e('0x1363'),'state':_0x28fd8e('0x2200'),'weight':0x1,'channel':'openChannel','hidden':function(){const _0x40db62=_0x28fd8e;return _0x34c4c3[_0x40db62('0xca1')]('agent')||!_0x34c4c3[_0x40db62('0x5e3')](0x321)&&!_0x34c4c3[_0x40db62('0xca1')](_0x40db62('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x195a'),{'id':0x322,'title':_0x28fd8e('0x1e08'),'route':_0x28fd8e('0x1963'),'translate':_0x28fd8e('0x1a5f'),'state':_0x28fd8e('0x225d'),'weight':0x1,'channel':'openChannel','hidden':function(){const _0x56df85=_0x28fd8e;return _0x34c4c3[_0x56df85('0xca1')](_0x56df85('0x2327'))||!_0x34c4c3[_0x56df85('0x5e3')](0x322)&&!_0x34c4c3['hasRole'](_0x56df85('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x276f'),{'id':0x32a,'title':'Realtime','route':'','translate':_0x28fd8e('0x90b'),'state':_0x28fd8e('0x1ab0'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x41e7ee=_0x28fd8e;return _0x34c4c3[_0x41e7ee('0xca1')](_0x41e7ee('0x2327'))||!_0x34c4c3[_0x41e7ee('0x5e3')](0x32a)&&!_0x34c4c3[_0x41e7ee('0xca1')](_0x41e7ee('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x76f'),{'id':0x384,'title':_0x28fd8e('0xb8a'),'translate':'FAX.FAX','icon':_0x28fd8e('0x8e9'),'weight':0xa,'license':'fax','hidden':function(){const _0x7f7d6e=_0x28fd8e;return!_0x601867[_0x7f7d6e('0x23e9')]||_0x34c4c3[_0x7f7d6e('0xca1')](_0x7f7d6e('0x2327'))||!_0x34c4c3[_0x7f7d6e('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0x7f7d6e('0xca1')](_0x7f7d6e('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.fax.faxQueues',{'id':0x385,'title':_0x28fd8e('0x22cb'),'route':_0x28fd8e('0x209c'),'translate':_0x28fd8e('0x2469'),'state':_0x28fd8e('0xb2e'),'weight':0x1,'channel':'fax','hidden':function(){const _0x2064d5=_0x28fd8e;return _0x34c4c3['hasRole'](_0x2064d5('0x2327'))||!_0x34c4c3['hasPermission'](0x385)&&!_0x34c4c3[_0x2064d5('0xca1')](_0x2064d5('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x579'),{'id':0x386,'title':'FaxAccounts','route':_0x28fd8e('0x244a'),'translate':_0x28fd8e('0x383'),'state':_0x28fd8e('0x2875'),'weight':0x1,'channel':_0x28fd8e('0x23e9'),'hidden':function(){const _0x21e72a=_0x28fd8e;return _0x34c4c3[_0x21e72a('0xca1')](_0x21e72a('0x2327'))||!_0x34c4c3[_0x21e72a('0x5e3')](0x386)&&!_0x34c4c3['hasRole'](_0x21e72a('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.fax.realtime',{'id':0x38e,'title':_0x28fd8e('0x2e1'),'route':'','translate':_0x28fd8e('0x1f27'),'state':'app.fax.realtime','weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x4a537b=_0x28fd8e;return _0x34c4c3[_0x4a537b('0xca1')]('agent')||!_0x34c4c3[_0x4a537b('0x5e3')](0x38e)&&!_0x34c4c3[_0x4a537b('0xca1')](_0x4a537b('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0xf2'),{'id':0x3e8,'title':_0x28fd8e('0x455'),'translate':'TOOLS.TOOLS','icon':'icon-auto-fix','weight':0xf,'hidden':function(){const _0x308985=_0x28fd8e;return _0x34c4c3[_0x308985('0xca1')](_0x308985('0x2327'))||!_0x34c4c3[_0x308985('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0x308985('0xca1')](_0x308985('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.tools.cannedAnswers',{'id':0x3e9,'title':_0x28fd8e('0x14f6'),'route':'cannedAnswer','translate':_0x28fd8e('0x262f'),'state':_0x28fd8e('0x25cf'),'weight':0x1,'hidden':function(){const _0x5add1a=_0x28fd8e;return _0x34c4c3[_0x5add1a('0xca1')](_0x5add1a('0x2327'))||!_0x34c4c3[_0x5add1a('0x5e3')](0x3e9)&&!_0x34c4c3['hasRole']('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x156e'),{'id':0x3eb,'title':_0x28fd8e('0x6fe'),'route':_0x28fd8e('0x1a6'),'translate':_0x28fd8e('0x1592'),'state':'app.tools.customDashboards','weight':0x3,'hidden':function(){const _0x1776b6=_0x28fd8e;return _0x34c4c3[_0x1776b6('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0x3eb)&&!_0x34c4c3[_0x1776b6('0xca1')](_0x1776b6('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.tools.intervals',{'id':0x3ec,'title':_0x28fd8e('0xb38'),'route':_0x28fd8e('0x115c'),'translate':_0x28fd8e('0x676'),'state':_0x28fd8e('0xca7'),'weight':0x4,'hidden':function(){const _0x4cbc1a=_0x28fd8e;return _0x34c4c3[_0x4cbc1a('0xca1')](_0x4cbc1a('0x2327'))||!_0x34c4c3[_0x4cbc1a('0x5e3')](0x3ec)&&!_0x34c4c3[_0x4cbc1a('0xca1')](_0x4cbc1a('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x24b2'),{'id':0x3ed,'title':'Pauses','route':'pause','translate':_0x28fd8e('0x1e09'),'state':_0x28fd8e('0x259e'),'weight':0x5,'hidden':function(){const _0x2dcda5=_0x28fd8e;return _0x34c4c3[_0x2dcda5('0xca1')]('agent')||!_0x34c4c3[_0x2dcda5('0x5e3')](0x3ed)&&!_0x34c4c3[_0x2dcda5('0xca1')](_0x2dcda5('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x59f'),{'id':0x3ee,'title':_0x28fd8e('0x2147'),'route':'schedule','translate':_0x28fd8e('0x12f1'),'state':_0x28fd8e('0xd3e'),'weight':0x6,'hidden':function(){const _0xcbd191=_0x28fd8e;return _0x34c4c3[_0xcbd191('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0x3ee)&&!_0x34c4c3['hasRole'](_0xcbd191('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1c9c'),{'id':0x3ef,'title':_0x28fd8e('0x628'),'route':_0x28fd8e('0x1638'),'translate':_0x28fd8e('0x1873'),'state':'app.tools.sounds','weight':0x7,'hidden':function(){const _0x2c0e58=_0x28fd8e;return _0x34c4c3[_0x2c0e58('0xca1')](_0x2c0e58('0x2327'))||!_0x34c4c3[_0x2c0e58('0x5e3')](0x3ef)&&!_0x34c4c3['hasRole'](_0x2c0e58('0x20c2'));}}),_0x420df6['saveItem']('apps.tools.tags',{'id':0x3f0,'title':'Tags','route':_0x28fd8e('0x270'),'translate':'TOOLS.TAGS','state':_0x28fd8e('0x109b'),'weight':0x8,'hidden':function(){const _0x48f45d=_0x28fd8e;return _0x34c4c3[_0x48f45d('0xca1')](_0x48f45d('0x2327'))||!_0x34c4c3[_0x48f45d('0x5e3')](0x3f0)&&!_0x34c4c3['hasRole']('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x875'),{'id':0x3f1,'title':_0x28fd8e('0x161d'),'route':'template','translate':_0x28fd8e('0xbb1'),'state':'app.tools.templates','weight':0x9,'hidden':function(){const _0x376814=_0x28fd8e;return _0x34c4c3[_0x376814('0xca1')]('agent')||!_0x34c4c3[_0x376814('0x5e3')](0x3f1)&&!_0x34c4c3[_0x376814('0xca1')](_0x376814('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x24a3'),{'id':0x3f3,'title':_0x28fd8e('0x485'),'route':_0x28fd8e('0x1a93'),'translate':_0x28fd8e('0x1de2'),'state':_0x28fd8e('0x222b'),'weight':0xb,'hidden':function(){const _0x40b3f9=_0x28fd8e;return _0x34c4c3[_0x40b3f9('0xca1')](_0x40b3f9('0x2327'))||!_0x34c4c3['hasPermission'](0x3f3)&&!_0x34c4c3['hasRole'](_0x40b3f9('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.tools.variables',{'id':0x3f4,'title':'Variables','route':_0x28fd8e('0x26e0'),'translate':_0x28fd8e('0xa75'),'state':_0x28fd8e('0x26e9'),'weight':0xc,'hidden':function(){const _0x46d509=_0x28fd8e;return _0x34c4c3[_0x46d509('0xca1')](_0x46d509('0x2327'))||!_0x34c4c3[_0x46d509('0x5e3')](0x3f4)&&!_0x34c4c3[_0x46d509('0xca1')]('admin');}}),_0x420df6['saveItem'](_0x28fd8e('0x19df'),{'id':0x3ea,'title':_0x28fd8e('0xf09'),'route':_0x28fd8e('0x43f'),'translate':_0x28fd8e('0x1e3'),'state':_0x28fd8e('0x15ed'),'weight':0x2,'hidden':function(){const _0x3bb84a=_0x28fd8e;return _0x34c4c3[_0x3bb84a('0xca1')](_0x3bb84a('0x2327'))||!_0x34c4c3[_0x3bb84a('0x5e3')](0x3ea)&&!_0x34c4c3[_0x3bb84a('0xca1')](_0x3bb84a('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0xc1b'),{'id':0x3f2,'title':'Triggers','route':'','translate':_0x28fd8e('0xdee'),'state':_0x28fd8e('0x27c5'),'weight':0xa,'hidden':function(){const _0x255ddf=_0x28fd8e;return _0x34c4c3['hasRole'](_0x255ddf('0x2327'))||!_0x34c4c3[_0x255ddf('0x5e3')](0x3f2)&&!_0x34c4c3[_0x255ddf('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')]('apps.callysquare',{'id':0x44c,'title':_0x28fd8e('0x4ef'),'translate':_0x28fd8e('0x21f3'),'icon':_0x28fd8e('0xd65'),'weight':0xd,'license':_0x28fd8e('0xcf2'),'hidden':function(){const _0x19a233=_0x28fd8e;return!_0x601867[_0x19a233('0xcf2')]||_0x34c4c3['hasRole']('agent')||!_0x34c4c3[_0x19a233('0x1522')](_0x8cfa58(this))&&!_0x34c4c3['hasRole'](_0x19a233('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0x1ec4'),{'id':0x44d,'title':_0x28fd8e('0x26fe'),'route':_0x28fd8e('0x39a'),'translate':_0x28fd8e('0x1db3'),'state':_0x28fd8e('0x399'),'weight':0x2,'hidden':function(){const _0x1ab8b2=_0x28fd8e;return _0x34c4c3['hasRole'](_0x1ab8b2('0x2327'))||!_0x34c4c3[_0x1ab8b2('0x5e3')](0x44d)&&!_0x34c4c3[_0x1ab8b2('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x22d0'),{'id':0x44e,'title':_0x28fd8e('0x1dcb'),'route':'squareRecording','translate':_0x28fd8e('0xb20'),'state':_0x28fd8e('0x1bb8'),'weight':0x3,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x33d04b=_0x28fd8e;return _0x34c4c3[_0x33d04b('0xca1')](_0x33d04b('0x2327'))||!_0x34c4c3['hasPermission'](0x44e)&&!_0x34c4c3[_0x33d04b('0xca1')](_0x33d04b('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x22b9'),{'id':0x44f,'title':_0x28fd8e('0x25c3'),'route':_0x28fd8e('0x27ea'),'translate':'CALLYSQUARE.PROJECTS','state':_0x28fd8e('0x24ed'),'weight':0x1,'hidden':function(){const _0x53a0c5=_0x28fd8e;return _0x34c4c3[_0x53a0c5('0xca1')]('agent')||!_0x34c4c3[_0x53a0c5('0x5e3')](0x44f)&&!_0x34c4c3['hasRole']('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x9a3'),{'id':0x4b0,'title':'Analytics','translate':_0x28fd8e('0xc3a'),'icon':_0x28fd8e('0xe87'),'weight':0x10,'hidden':function(){const _0x3fc609=_0x28fd8e;return _0x34c4c3['hasRole'](_0x3fc609('0x2327'))||!_0x34c4c3[_0x3fc609('0x1522')](_0x8cfa58(this))&&!_0x34c4c3['hasRole']('admin');}}),_0x420df6[_0x28fd8e('0x2716')]('apps.analytics.metrics',{'id':0x4b1,'title':_0x28fd8e('0x264d'),'route':_0x28fd8e('0x1c97'),'translate':_0x28fd8e('0x11b6'),'state':_0x28fd8e('0x1dc5'),'weight':0x3,'hidden':function(){const _0x5a2ac5=_0x28fd8e;return _0x34c4c3[_0x5a2ac5('0xca1')](_0x5a2ac5('0x2327'))||!_0x34c4c3['hasPermission'](0x4b1)&&!_0x34c4c3[_0x5a2ac5('0xca1')](_0x5a2ac5('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x441'),{'id':0x4b2,'title':_0x28fd8e('0x14ec'),'route':'analyticExtractedReport','translate':_0x28fd8e('0x39c'),'state':_0x28fd8e('0x5c8'),'weight':0x2,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x37f0d2=_0x28fd8e;return _0x34c4c3[_0x37f0d2('0xca1')](_0x37f0d2('0x2327'))||!_0x34c4c3[_0x37f0d2('0x5e3')](0x4b2)&&!_0x34c4c3[_0x37f0d2('0xca1')](_0x37f0d2('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1288'),{'id':0x4b3,'title':'Reports','route':'','translate':_0x28fd8e('0x37f'),'state':_0x28fd8e('0x2721'),'weight':0x1,'hidden':function(){const _0xefcc2f=_0x28fd8e;return _0x34c4c3[_0xefcc2f('0xca1')](_0xefcc2f('0x2327'))||!_0x34c4c3[_0xefcc2f('0x5e3')](0x4b3)&&!_0x34c4c3['hasRole'](_0xefcc2f('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xb80'),{'id':0x514,'title':_0x28fd8e('0x1c22'),'translate':_0x28fd8e('0x57b'),'icon':_0x28fd8e('0x1a28'),'weight':0x11,'hidden':function(){const _0x571e47=_0x28fd8e;return _0x34c4c3['hasRole'](_0x571e47('0x2327'))||!_0x34c4c3['hasChildrenPermissions'](_0x8cfa58(this))&&!_0x34c4c3['hasRole'](_0x571e47('0x20c2'));}}),_0x420df6['saveItem']('apps.integrations.zendeskAccounts',{'id':0x515,'title':_0x28fd8e('0x21aa'),'route':_0x28fd8e('0x1a0'),'translate':_0x28fd8e('0x130c'),'state':_0x28fd8e('0x6ff'),'weight':0x1,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0xdb0c74=_0x28fd8e;return _0x34c4c3[_0xdb0c74('0xca1')](_0xdb0c74('0x2327'))||!_0x34c4c3[_0xdb0c74('0x5e3')](0x515)&&!_0x34c4c3[_0xdb0c74('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x2851'),{'id':0x516,'title':_0x28fd8e('0x613'),'route':_0x28fd8e('0xf30'),'translate':'INTEGRATIONS.SALESFORCEACCOUNTS','state':_0x28fd8e('0x1eb6'),'weight':0x2,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x571834=_0x28fd8e;return _0x34c4c3[_0x571834('0xca1')](_0x571834('0x2327'))||!_0x34c4c3[_0x571834('0x5e3')](0x516)&&!_0x34c4c3[_0x571834('0xca1')](_0x571834('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1112'),{'id':0x517,'title':'FreshdeskAccounts','route':_0x28fd8e('0x15dc'),'translate':'INTEGRATIONS.FRESHDESKACCOUNTS','state':_0x28fd8e('0x1982'),'weight':0x3,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x18d2dc=_0x28fd8e;return _0x34c4c3[_0x18d2dc('0xca1')](_0x18d2dc('0x2327'))||!_0x34c4c3[_0x18d2dc('0x5e3')](0x517)&&!_0x34c4c3[_0x18d2dc('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x48d'),{'id':0x519,'title':_0x28fd8e('0x1e70'),'route':_0x28fd8e('0x26f5'),'translate':_0x28fd8e('0x431'),'state':_0x28fd8e('0xec1'),'weight':0x4,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x451a32=_0x28fd8e;return _0x34c4c3['hasRole'](_0x451a32('0x2327'))||!_0x34c4c3[_0x451a32('0x5e3')](0x519)&&!_0x34c4c3[_0x451a32('0xca1')](_0x451a32('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.integrations.deskAccounts',{'id':0x51a,'title':_0x28fd8e('0x6a8'),'route':_0x28fd8e('0xe2b'),'translate':_0x28fd8e('0x127d'),'state':_0x28fd8e('0x1442'),'weight':0x5,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x33bc76=_0x28fd8e;return _0x34c4c3[_0x33bc76('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0x51a)&&!_0x34c4c3[_0x33bc76('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x130e'),{'id':0x51b,'title':_0x28fd8e('0x21ca'),'route':'intZohoAccount','translate':_0x28fd8e('0x164'),'state':_0x28fd8e('0x1ef4'),'weight':0x6,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x1a2339=_0x28fd8e;return _0x34c4c3[_0x1a2339('0xca1')]('agent')||!_0x34c4c3[_0x1a2339('0x5e3')](0x51b)&&!_0x34c4c3[_0x1a2339('0xca1')](_0x1a2339('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x11a1'),{'id':0x51c,'title':_0x28fd8e('0x1392'),'route':_0x28fd8e('0x26cb'),'translate':_0x28fd8e('0x21ba'),'state':_0x28fd8e('0x1dca'),'weight':0x7,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0xabc2fe=_0x28fd8e;return _0x34c4c3[_0xabc2fe('0xca1')](_0xabc2fe('0x2327'))||!_0x34c4c3[_0xabc2fe('0x5e3')](0x51c)&&!_0x34c4c3[_0xabc2fe('0xca1')](_0xabc2fe('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x27f2'),{'id':0x51d,'title':_0x28fd8e('0xa0a'),'route':_0x28fd8e('0x2601'),'translate':_0x28fd8e('0xbb0'),'state':_0x28fd8e('0x2201'),'weight':0x8,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x2d054c=_0x28fd8e;return _0x34c4c3[_0x2d054c('0xca1')](_0x2d054c('0x2327'))||!_0x34c4c3[_0x2d054c('0x5e3')](0x51d)&&!_0x34c4c3[_0x2d054c('0xca1')](_0x2d054c('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0xe89'),{'id':0x51e,'title':_0x28fd8e('0x201e'),'route':_0x28fd8e('0x2169'),'translate':'INTEGRATIONS.SERVICENOWACCOUNTS','state':_0x28fd8e('0x2847'),'weight':0x9,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x3b2411=_0x28fd8e;return _0x34c4c3[_0x3b2411('0xca1')](_0x3b2411('0x2327'))||!_0x34c4c3[_0x3b2411('0x5e3')](0x51e)&&!_0x34c4c3[_0x3b2411('0xca1')](_0x3b2411('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0x18ce'),{'id':0x518,'title':_0x28fd8e('0x94f'),'route':_0x28fd8e('0xa71'),'translate':_0x28fd8e('0x1426'),'state':'app.integrations.freshsalesAccounts','weight':0xa,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x4584ec=_0x28fd8e;return _0x34c4c3[_0x4584ec('0xca1')](_0x4584ec('0x2327'))||!_0x34c4c3[_0x4584ec('0x5e3')](0x518)&&!_0x34c4c3['hasRole'](_0x4584ec('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xd1c'),{'id':0x578,'title':_0x28fd8e('0x1fc9'),'translate':_0x28fd8e('0xcae'),'icon':_0x28fd8e('0x12e4'),'weight':0x14,'permissions':{'hidden':!![]},'hidden':function(){const _0x1c2bd8=_0x28fd8e;return _0x34c4c3['hasRole'](_0x1c2bd8('0x2327'))||!_0x34c4c3[_0x1c2bd8('0x5e3')](0x578)&&!_0x34c4c3[_0x1c2bd8('0xca1')](_0x1c2bd8('0x20c2'))||_0x34c4c3[_0x1c2bd8('0xca1')](_0x1c2bd8('0x20c2'))&&!_0x34c4c3[_0x1c2bd8('0x20b2')]()['settingsEnabled'];}}),_0x420df6[_0x28fd8e('0x2716')]('apps.settings.generals',{'id':0x579,'title':'General','route':_0x28fd8e('0x260a'),'translate':_0x28fd8e('0xd05'),'state':'app.settings.generals','weight':0x1,'hidden':function(){const _0x326757=_0x28fd8e;return _0x34c4c3['hasRole']('agent')||!_0x34c4c3[_0x326757('0x5e3')](0x578)&&!_0x34c4c3[_0x326757('0xca1')](_0x326757('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.settings.smtps',{'id':0x57a,'title':_0x28fd8e('0x163'),'route':'mailAccount','translate':_0x28fd8e('0xf3d'),'state':_0x28fd8e('0x2d6'),'weight':0x1,'hidden':function(){const _0x103a19=_0x28fd8e;return _0x34c4c3['hasRole'](_0x103a19('0x2327'))||!_0x34c4c3[_0x103a19('0x5e3')](0x578)&&!_0x34c4c3[_0x103a19('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1fbe'),{'id':0x57b,'title':_0x28fd8e('0x1a46'),'route':_0x28fd8e('0x18f6'),'translate':_0x28fd8e('0x1889'),'state':_0x28fd8e('0x835'),'weight':0x1,'hidden':function(){const _0x63dae8=_0x28fd8e;return _0x34c4c3[_0x63dae8('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0x578)&&!_0x34c4c3[_0x63dae8('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xea7'),{'id':0x57f,'title':'Customizations','route':_0x28fd8e('0x260a'),'translate':_0x28fd8e('0x15c8'),'state':_0x28fd8e('0x9a0'),'weight':0x1,'hidden':function(){const _0xd30e42=_0x28fd8e;return!_0x601867[_0xd30e42('0xbf0')]||_0x34c4c3['hasRole']('agent')||!_0x34c4c3['hasPermission'](0x578)&&!_0x34c4c3[_0xd30e42('0xca1')](_0xd30e42('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0xcd6'),{'id':0x580,'title':_0x28fd8e('0x221d'),'route':_0x28fd8e('0x44'),'translate':_0x28fd8e('0x1109'),'state':_0x28fd8e('0x6c8'),'weight':0x1,'hidden':function(){const _0x9e10c1=_0x28fd8e;return!_0x601867['ai']||_0x34c4c3[_0x9e10c1('0xca1')](_0x9e10c1('0x2327'))||!_0x34c4c3[_0x9e10c1('0x5e3')](0x578)&&!_0x34c4c3['hasRole'](_0x9e10c1('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.settings.updates',{'id':0x57c,'title':_0x28fd8e('0x1e9c'),'route':'','translate':'SETTINGS.UPDATES','state':'app.settings.updates','weight':0x1,'hidden':function(){const _0x2461ab=_0x28fd8e;return!_0x601867[_0x2461ab('0x2480')]||_0x34c4c3['hasRole'](_0x2461ab('0x2327'))||!_0x34c4c3['hasPermission'](0x578)&&!_0x34c4c3['hasRole'](_0x2461ab('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0x265a'),{'id':0x57d,'title':'License','route':'','translate':_0x28fd8e('0xc31'),'state':_0x28fd8e('0x2024'),'weight':0x1,'hidden':function(){const _0x2a5c81=_0x28fd8e;return _0x34c4c3[_0x2a5c81('0xca1')](_0x2a5c81('0x2327'))||!_0x34c4c3['hasPermission'](0x578)&&!_0x34c4c3[_0x2a5c81('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')]('apps.settings.system',{'id':0x57e,'title':'System','route':'','translate':_0x28fd8e('0xb89'),'state':_0x28fd8e('0xbd3'),'weight':0x1,'hidden':function(){const _0x3edf29=_0x28fd8e;return _0x34c4c3[_0x3edf29('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0x578)&&!_0x34c4c3['hasRole'](_0x3edf29('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x10f4'),{'id':0x5dc,'title':_0x28fd8e('0x1230'),'translate':_0x28fd8e('0x1878'),'icon':_0x28fd8e('0x556'),'weight':0x5,'license':'dialer','hidden':function(){const _0x16e8e3=_0x28fd8e;return!_0x601867[_0x16e8e3('0x228a')]||_0x34c4c3[_0x16e8e3('0xca1')]('agent')||!_0x34c4c3[_0x16e8e3('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0x16e8e3('0xca1')](_0x16e8e3('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x24c1'),{'id':0x5dd,'title':_0x28fd8e('0x1a4c'),'route':'voiceQueue','translate':_0x28fd8e('0xcff'),'state':_0x28fd8e('0x25ae'),'weight':0x1,'channel':_0x28fd8e('0x5d9'),'hidden':function(){const _0x2e9b46=_0x28fd8e;return _0x34c4c3[_0x2e9b46('0xca1')](_0x2e9b46('0x2327'))||!_0x34c4c3[_0x2e9b46('0x5e3')](0x5dd)&&!_0x34c4c3['hasRole'](_0x2e9b46('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0x26b9'),{'id':0x5de,'title':'IvrCampaigns','route':_0x28fd8e('0x6e9'),'translate':_0x28fd8e('0x1ff8'),'state':'app.motiondialer.ivrCampaigns','weight':0x1,'hidden':function(){const _0x3fc1e6=_0x28fd8e;return _0x34c4c3['hasRole'](_0x3fc1e6('0x2327'))||!_0x34c4c3[_0x3fc1e6('0x5e3')](0x5de)&&!_0x34c4c3[_0x3fc1e6('0xca1')](_0x3fc1e6('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x16b4'),{'id':0x5e6,'title':_0x28fd8e('0x2e1'),'route':'','translate':'MOTIONDIALER.REALTIME','state':_0x28fd8e('0xd4b'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x50a337=_0x28fd8e;return _0x34c4c3[_0x50a337('0xca1')](_0x50a337('0x2327'))||!_0x34c4c3[_0x50a337('0x5e3')](0x5e6)&&!_0x34c4c3[_0x50a337('0xca1')](_0x50a337('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.help',{'id':0x640,'title':_0x28fd8e('0x151e'),'translate':_0x28fd8e('0xfcd'),'icon':'icon-help','weight':0x15,'permissions':{'association':![]},'hidden':function(){const _0x5e3915=_0x28fd8e;return _0x34c4c3[_0x5e3915('0xca1')](_0x5e3915('0x2327'))||!_0x34c4c3[_0x5e3915('0x5e3')](0x640)&&!_0x34c4c3[_0x5e3915('0xca1')](_0x5e3915('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1f09'),{'id':0x641,'title':_0x28fd8e('0xd29'),'route':'','translate':'HELP.ABOUT','state':_0x28fd8e('0x1580'),'weight':0x1,'hidden':function(){const _0x5729e6=_0x28fd8e;return _0x34c4c3['hasRole'](_0x5729e6('0x2327'))||!_0x34c4c3[_0x5729e6('0x5e3')](0x640)&&!_0x34c4c3[_0x5729e6('0xca1')](_0x5729e6('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xc40'),{'id':0x6a4,'title':_0x28fd8e('0x18e6'),'translate':_0x28fd8e('0x1c4a'),'icon':_0x28fd8e('0xf7d'),'weight':0xe,'license':_0x28fd8e('0x18e6'),'hidden':function(){const _0x2621c9=_0x28fd8e;return!_0x601867[_0x2621c9('0x18e6')]||_0x34c4c3['hasRole']('agent')||!_0x34c4c3['hasChildrenPermissions'](_0x8cfa58(this))&&!_0x34c4c3['hasRole'](_0x2621c9('0x20c2'));}}),_0x420df6['saveItem']('apps.jscripty.projects',{'id':0x6a5,'title':_0x28fd8e('0x25c3'),'route':_0x28fd8e('0xa8b'),'translate':_0x28fd8e('0x1303'),'state':_0x28fd8e('0x1f07'),'weight':0x1,'hidden':function(){const _0x5c1ee4=_0x28fd8e;return _0x34c4c3['hasRole'](_0x5c1ee4('0x2327'))||!_0x34c4c3['hasPermission'](0x6a5)&&!_0x34c4c3[_0x5c1ee4('0xca1')](_0x5c1ee4('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0xa73'),{'id':0x708,'title':'Marketplace','translate':'MARKETPLACE.MARKETPLACE','icon':_0x28fd8e('0x1359'),'weight':0x12,'hidden':function(){const _0x26ef68=_0x28fd8e;return _0x34c4c3['hasRole'](_0x26ef68('0x2327'))||!_0x34c4c3[_0x26ef68('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0x26ef68('0xca1')](_0x26ef68('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x9de'),{'id':0x709,'title':_0x28fd8e('0x145b'),'route':_0x28fd8e('0x1cd1'),'translate':_0x28fd8e('0x17bd'),'state':_0x28fd8e('0x1d1a'),'weight':0x1,'hidden':function(){const _0x26315e=_0x28fd8e;return _0x34c4c3[_0x26315e('0xca1')]('agent')||!_0x34c4c3[_0x26315e('0x5e3')](0x709)&&!_0x34c4c3[_0x26315e('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x945'),{'id':0x7d0,'title':'Video','translate':_0x28fd8e('0xb21'),'icon':_0x28fd8e('0x1ae1'),'weight':0xc,'license':_0x28fd8e('0xd70'),'hidden':function(){const _0x108634=_0x28fd8e;return!_0x601867[_0x108634('0xd70')]||_0x34c4c3['hasRole'](_0x108634('0x2327'))||!_0x34c4c3[_0x108634('0x1522')](_0x8cfa58(this))&&!_0x34c4c3[_0x108634('0xca1')](_0x108634('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')]('apps.video.screenRecordings',{'id':0x7d1,'title':'ScreenRecordings','route':'screenRecording','translate':_0x28fd8e('0xc3d'),'state':_0x28fd8e('0x1951'),'weight':0x1,'permissions':{'association':![],'loading':!![]},'hidden':function(){const _0x343775=_0x28fd8e;return _0x34c4c3['hasRole'](_0x343775('0x2327'))||!_0x34c4c3[_0x343775('0x5e3')](0x7d1)&&!_0x34c4c3[_0x343775('0xca1')](_0x343775('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x1074'),{'id':0x834,'title':_0x28fd8e('0x26b3'),'translate':_0x28fd8e('0x1137'),'icon':_0x28fd8e('0x1b55'),'weight':0xb,'license':_0x28fd8e('0x16e7'),'hidden':function(){const _0x583e73=_0x28fd8e;return!_0x601867['whatsapp']||_0x34c4c3[_0x583e73('0xca1')](_0x583e73('0x2327'))||!_0x34c4c3[_0x583e73('0x1522')](_0x8cfa58(this))&&!_0x34c4c3['hasRole'](_0x583e73('0x20c2'));}}),_0x420df6[_0x28fd8e('0x2716')](_0x28fd8e('0x551'),{'id':0x835,'title':_0x28fd8e('0x20e4'),'route':'whatsappQueue','translate':_0x28fd8e('0xb06'),'state':_0x28fd8e('0x73f'),'weight':0x1,'channel':_0x28fd8e('0x16e7'),'hidden':function(){const _0x1e92f5=_0x28fd8e;return _0x34c4c3['hasRole']('agent')||!_0x34c4c3[_0x1e92f5('0x5e3')](0x835)&&!_0x34c4c3['hasRole'](_0x1e92f5('0x20c2'));}}),_0x420df6['saveItem']('apps.whatsapp.whatsappAccounts',{'id':0x836,'title':_0x28fd8e('0x239b'),'route':_0x28fd8e('0x1990'),'translate':_0x28fd8e('0x2564'),'state':_0x28fd8e('0x1774'),'weight':0x1,'channel':_0x28fd8e('0x16e7'),'hidden':function(){const _0x3572bb=_0x28fd8e;return _0x34c4c3[_0x3572bb('0xca1')]('agent')||!_0x34c4c3[_0x3572bb('0x5e3')](0x836)&&!_0x34c4c3['hasRole'](_0x3572bb('0x20c2'));}}),_0x420df6['saveItem'](_0x28fd8e('0x7ab'),{'id':0x83e,'title':_0x28fd8e('0x2e1'),'route':'','translate':_0x28fd8e('0x2696'),'state':_0x28fd8e('0x30c'),'weight':0x1,'permissions':{'association':![],'crud':![]},'hidden':function(){const _0x49f50a=_0x28fd8e;return _0x34c4c3[_0x49f50a('0xca1')]('agent')||!_0x34c4c3['hasPermission'](0x83e)&&!_0x34c4c3[_0x49f50a('0xca1')]('admin');}}),_0x420df6[_0x28fd8e('0x671')](),_0x171f49[_0x28fd8e('0x2716')]('apps',{'title':_0x28fd8e('0x1c9b'),'group':!![],'weight':0x1}),_0x171f49[_0x28fd8e('0x2716')]('apps.home',{'id':0x64,'title':_0x28fd8e('0xa79'),'translate':_0x28fd8e('0x1cf5'),'icon':'icon-home','weight':0x1}),_0x171f49[_0x28fd8e('0x2716')](_0x28fd8e('0x5a4'),{'id':0x65,'title':_0x28fd8e('0x10e6'),'translate':'DASHBOARDS.DASHBOARD','state':_0x28fd8e('0x1a6'),'view':_0x28fd8e('0x1a6'),'icon':_0x28fd8e('0x1e64'),'iconClass':'cyan-500-fg','weight':0x1,'hidden':function(){const _0x5ba5f8=_0x28fd8e;return!_0x34c4c3[_0x5ba5f8('0x5e3')](0x65);}}),_0x171f49[_0x28fd8e('0x2716')](_0x28fd8e('0x13e7'),{'id':0x66,'title':'Contacts','translate':'DASHBOARDS.CONTACTS','state':_0x28fd8e('0x6d5'),'view':_0x28fd8e('0x6d5'),'icon':'icon-account-circle','iconClass':_0x28fd8e('0xa7f'),'weight':0x2,'hidden':function(){return!_0x601867['cm']||!_0x34c4c3['hasPermission'](0x66);}}),_0x171f49['saveItem']('apps.home.mycontacts',{'id':0x67,'title':_0x28fd8e('0xdb2'),'translate':_0x28fd8e('0x8d6'),'state':_0x28fd8e('0x2632'),'view':_0x28fd8e('0x2632'),'icon':_0x28fd8e('0x27d'),'iconClass':_0x28fd8e('0xa7f'),'weight':0x3,'hidden':function(){const _0x4fd495=_0x28fd8e;return!_0x601867['cm']||!_0x34c4c3[_0x4fd495('0x5e3')](0x67);}}),_0x171f49[_0x28fd8e('0x2716')](_0x28fd8e('0x234f'),{'id':0x71,'title':_0x28fd8e('0x5fe'),'translate':'DASHBOARDS.SCHEDULED_CALLS','state':_0x28fd8e('0x1a79'),'view':_0x28fd8e('0x1a79'),'icon':_0x28fd8e('0x4c1'),'iconClass':'blue-grey-fg','weight':0x3,'hidden':function(){const _0x4a07f0=_0x28fd8e;return!_0x601867[_0x4a07f0('0x228a')]||!_0x34c4c3[_0x4a07f0('0x5e3')](0x71);}}),_0x171f49[_0x28fd8e('0x2716')]('apps.home.voice',{'id':0x6e,'title':_0x28fd8e('0x378'),'translate':_0x28fd8e('0x1e5c'),'state':_0x28fd8e('0xcf2'),'view':'voice','icon':_0x28fd8e('0xd73'),'iconClass':_0x28fd8e('0xbd9'),'weight':0x4,'hidden':function(){const _0x18bfd1=_0x28fd8e;return!_0x601867[_0x18bfd1('0xcf2')]||!_0x34c4c3['hasPermission'](0x6e);}}),_0x171f49[_0x28fd8e('0x2716')](_0x28fd8e('0x11bb'),{'id':0x6f,'title':_0x28fd8e('0x180b'),'translate':'DASHBOARDS.ABANDONED','state':'abandoned','view':'abandoned','icon':_0x28fd8e('0x2605'),'iconClass':_0x28fd8e('0x2864'),'weight':0x5,'hidden':function(){const _0xa146a6=_0x28fd8e;return!_0x601867[_0xa146a6('0xcf2')]||!_0x34c4c3[_0xa146a6('0x5e3')](0x6f);}}),_0x171f49['saveItem'](_0x28fd8e('0x173b'),{'id':0x68,'title':'Recordings','translate':_0x28fd8e('0x1d3c'),'state':'recordings','view':'recordings','icon':_0x28fd8e('0x10eb'),'iconClass':_0x28fd8e('0x1834'),'weight':0x6,'hidden':function(){const _0x1084ff=_0x28fd8e;return!_0x601867[_0x1084ff('0xcf2')]||!_0x34c4c3['hasPermission'](0x68);}}),_0x171f49[_0x28fd8e('0x2716')](_0x28fd8e('0x291'),{'id':0x69,'title':_0x28fd8e('0x2071'),'translate':_0x28fd8e('0xd2d'),'state':'chat','view':_0x28fd8e('0x24e'),'icon':_0x28fd8e('0xa46'),'iconClass':_0x28fd8e('0x8e2'),'weight':0x7,'hidden':function(){return!_0x601867['chat']||!_0x34c4c3['hasPermission'](0x69);}}),_0x171f49['saveItem'](_0x28fd8e('0x2293'),{'id':0x6a,'title':_0x28fd8e('0x24f1'),'translate':_0x28fd8e('0x15e3'),'state':_0x28fd8e('0x129f'),'view':_0x28fd8e('0x129f'),'icon':'icon-email','iconClass':_0x28fd8e('0xbae'),'weight':0x8,'hidden':function(){const _0x52ae5c=_0x28fd8e;return!_0x601867[_0x52ae5c('0x129f')]||!_0x34c4c3[_0x52ae5c('0x5e3')](0x6a);}}),_0x171f49[_0x28fd8e('0x2716')](_0x28fd8e('0x1d2d'),{'id':0x6b,'title':_0x28fd8e('0xdaa'),'translate':'DASHBOARDS.SMS','state':_0x28fd8e('0x1285'),'view':'sms','icon':_0x28fd8e('0x1a87'),'iconClass':_0x28fd8e('0x1823'),'weight':0x9,'hidden':function(){const _0x5ebab0=_0x28fd8e;return!_0x601867[_0x5ebab0('0xf9d')]||!_0x34c4c3['hasPermission'](0x6b);}}),_0x171f49[_0x28fd8e('0x2716')](_0x28fd8e('0x1b99'),{'id':0x6c,'title':_0x28fd8e('0x1d4f'),'translate':_0x28fd8e('0x1705'),'state':_0x28fd8e('0x1261'),'view':_0x28fd8e('0x1261'),'icon':_0x28fd8e('0x13f1'),'iconClass':_0x28fd8e('0x62d'),'weight':0xa,'hidden':function(){const _0x474381=_0x28fd8e;return!_0x601867[_0x474381('0x1261')]||!_0x34c4c3[_0x474381('0x5e3')](0x6c);}}),_0x171f49[_0x28fd8e('0x2716')](_0x28fd8e('0x1ccf'),{'id':0x6d,'title':_0x28fd8e('0xb8a'),'translate':_0x28fd8e('0x90d'),'state':_0x28fd8e('0x23e9'),'view':_0x28fd8e('0x23e9'),'icon':'icon-deskphone','iconClass':_0x28fd8e('0x253f'),'weight':0xb,'hidden':function(){const _0x2d5dc7=_0x28fd8e;return!_0x601867[_0x2d5dc7('0x23e9')]||!_0x34c4c3[_0x2d5dc7('0x5e3')](0x6d);}}),_0x171f49[_0x28fd8e('0x2716')](_0x28fd8e('0x1764'),{'id':0x72,'title':_0x28fd8e('0x26b3'),'translate':'DASHBOARDS.WHATSAPP','state':_0x28fd8e('0x16e7'),'view':'whatsapp','icon':'icon-whatsapp','iconClass':'lime-A700-fg','weight':0xc,'hidden':function(){const _0x302516=_0x28fd8e;return!_0x601867[_0x302516('0x16e7')]||!_0x34c4c3[_0x302516('0x5e3')](0x72);}}),_0x50fefe['$on'](_0x28fd8e('0x1cea'),function(_0x3a43f1){const _0x2b70dc=_0x28fd8e;_0x3a43f1[_0x2b70dc('0x608')][_0x2b70dc('0x361')]===_0x50fefe[_0x2b70dc('0x361')]&&_0x339e1a['$broadcast'](_0x2b70dc('0x2208'));});}const _0x4c138a=_0x5000fb;;const _0x544306=[_0x189033('0x2db'),_0x189033('0x1345'),_0x189033('0x2177'),_0x189033('0x6e2'),_0x189033('0x21e4'),_0x189033('0x3eb'),_0x189033('0x2285'),_0x189033('0x5f5'),_0x189033('0x1803'),'app.staff',_0x189033('0x1f51'),_0x189033('0xa'),_0x189033('0xb14'),'app.mail',_0x189033('0x1263'),_0x189033('0x17a8'),'app.fax',_0x189033('0x16ee'),'app.callysquare',_0x189033('0x452'),_0x189033('0xfbf'),_0x189033('0x1ae'),_0x189033('0x134d'),'app.help',_0x189033('0xa08'),'app.marketplace','app.plugins',_0x189033('0xde6'),_0x189033('0xb0c'),_0x189033('0x8a0'),_0x189033('0x22fc'),_0x189033('0x1389'),_0x189033('0x1207')];angular[_0x189033('0x1e26')](_0x189033('0xe83'),_0x544306)['factory'](_0x189033('0x56b'),_0xf23928)[_0x189033('0x272d')](_0x11dfc8)['controller'](_0x189033('0x33c'),_0x27779a)[_0x189033('0x25')](_0x189033('0x1f42'),_0x290511)[_0x189033('0x25')](_0x189033('0x102a'),_0x3a7c53)[_0x189033('0x1f97')](_0x189033('0x844'),_0x517340)[_0x189033('0x1f97')]('dateFilterLocalizationFactory',_0x114a96)[_0x189033('0x1f97')](_0x189033('0x238d'),_0x3b6d82)[_0x189033('0x272d')](_0x4e4051)[_0x189033('0x11a0')](_0xd57c17)['factory'](_0x189033('0x1556'),_0x5c751f)[_0x189033('0x1da3')]('MainController',_0x4c138a);},0x1a2c:(_0x237c23,_0x51b6b6,_0x4c1e34)=>{const _0x19ad23=_0x26a114;var _0x2446e5={'./af':0xae2,'./af.js':0xae2,'./ar':0x363,'./ar-dz':0x1022,'./ar-dz.js':0x1022,'./ar-kw':0x17f7,'./ar-kw.js':0x17f7,'./ar-ly':0x1928,'./ar-ly.js':0x1928,'./ar-ma':0x1e16,'./ar-ma.js':0x1e16,'./ar-sa':0x1798,'./ar-sa.js':0x1798,'./ar-tn':0x1bbc,'./ar-tn.js':0x1bbc,'./ar.js':0x363,'./az':0x43b,'./az.js':0x43b,'./be':0x2650,'./be.js':0x2650,'./bg':0x2092,'./bg.js':0x2092,'./bm':0x1d0e,'./bm.js':0x1d0e,'./bn':0x22c9,'./bn-bd':0x1851,'./bn-bd.js':0x1851,'./bn.js':0x22c9,'./bo':0x618,'./bo.js':0x618,'./br':0x4fe,'./br.js':0x4fe,'./bs':0x26e,'./bs.js':0x26e,'./ca':0x9a4,'./ca.js':0x9a4,'./cs':0x16be,'./cs.js':0x16be,'./cv':0x36d,'./cv.js':0x36d,'./cy':0x1ccd,'./cy.js':0x1ccd,'./da':0x12ac,'./da.js':0x12ac,'./de':0x260c,'./de-at':0xd9,'./de-at.js':0xd9,'./de-ch':0x37e,'./de-ch.js':0x37e,'./de.js':0x260c,'./dv':0x14b4,'./dv.js':0x14b4,'./el':0x345,'./el.js':0x345,'./en-au':0x209c,'./en-au.js':0x209c,'./en-ca':0x1ef5,'./en-ca.js':0x1ef5,'./en-gb':0x8c3,'./en-gb.js':0x8c3,'./en-ie':0x1924,'./en-ie.js':0x1924,'./en-il':0x1c27,'./en-il.js':0x1c27,'./en-in':0x104f,'./en-in.js':0x104f,'./en-nz':0x18af,'./en-nz.js':0x18af,'./en-sg':0x67e,'./en-sg.js':0x67e,'./eo':0xb63,'./eo.js':0xb63,'./es':0x1617,'./es-do':0x1483,'./es-do.js':0x1483,'./es-mx':0x17e0,'./es-mx.js':0x17e0,'./es-us':0x47a,'./es-us.js':0x47a,'./es.js':0x1617,'./et':0x15e3,'./et.js':0x15e3,'./eu':0x1e53,'./eu.js':0x1e53,'./fa':0x1b2f,'./fa.js':0x1b2f,'./fi':0x769,'./fi.js':0x769,'./fil':0x9f5,'./fil.js':0x9f5,'./fo':0x1256,'./fo.js':0x1256,'./fr':0x1176,'./fr-ca':0xbe9,'./fr-ca.js':0xbe9,'./fr-ch':0x91a,'./fr-ch.js':0x91a,'./fr.js':0x1176,'./fy':0x13b4,'./fy.js':0x13b4,'./ga':0x244f,'./ga.js':0x244f,'./gd':0x835,'./gd.js':0x835,'./gl':0x225a,'./gl.js':0x225a,'./gom-deva':0x1ecc,'./gom-deva.js':0x1ecc,'./gom-latn':0xc60,'./gom-latn.js':0xc60,'./gu':0x14e5,'./gu.js':0x14e5,'./he':0x106e,'./he.js':0x106e,'./hi':0x5e,'./hi.js':0x5e,'./hr':0x13c,'./hr.js':0x13c,'./hu':0x85a,'./hu.js':0x85a,'./hy-am':0x58f,'./hy-am.js':0x58f,'./id':0x2402,'./id.js':0x2402,'./is':0x87,'./is.js':0x87,'./it':0x272,'./it-ch':0x96,'./it-ch.js':0x96,'./it.js':0x272,'./ja':0x23df,'./ja.js':0x23df,'./jv':0x10be,'./jv.js':0x10be,'./ka':0x839,'./ka.js':0x839,'./kk':0x1e5c,'./kk.js':0x1e5c,'./km':0x2236,'./km.js':0x2236,'./kn':0x2442,'./kn.js':0x2442,'./ko':0xe92,'./ko.js':0xe92,'./ku':0x580,'./ku.js':0x580,'./ky':0xcdb,'./ky.js':0xcdb,'./lb':0x1ab9,'./lb.js':0x1ab9,'./lo':0x155a,'./lo.js':0x155a,'./lt':0x1b62,'./lt.js':0x1b62,'./lv':0x1dab,'./lv.js':0x1dab,'./me':0x2685,'./me.js':0x2685,'./mi':0x1575,'./mi.js':0x1575,'./mk':0x174e,'./mk.js':0x174e,'./ml':0x1cad,'./ml.js':0x1cad,'./mn':0x13fb,'./mn.js':0x13fb,'./mr':0x172,'./mr.js':0x172,'./ms':0x2677,'./ms-my':0x4d5,'./ms-my.js':0x4d5,'./ms.js':0x2677,'./mt':0x84e,'./mt.js':0x84e,'./my':0x1815,'./my.js':0x1815,'./nb':0x133c,'./nb.js':0x133c,'./ne':0x1a58,'./ne.js':0x1a58,'./nl':0xf3d,'./nl-be':0x2656,'./nl-be.js':0x2656,'./nl.js':0xf3d,'./nn':0xf25,'./nn.js':0xf25,'./oc-lnc':0x857,'./oc-lnc.js':0x857,'./pa-in':0x16e2,'./pa-in.js':0x16e2,'./pl':0x118f,'./pl.js':0x118f,'./pt':0x2530,'./pt-br':0x1f23,'./pt-br.js':0x1f23,'./pt.js':0x2530,'./ro':0x193b,'./ro.js':0x193b,'./ru':0x701,'./ru.js':0x701,'./sd':0x3b6,'./sd.js':0x3b6,'./se':0x1ea,'./se.js':0x1ea,'./si':0x7c,'./si.js':0x7c,'./sk':0x1099,'./sk.js':0x1099,'./sl':0x1379,'./sl.js':0x1379,'./sq':0x450,'./sq.js':0x450,'./sr':0x23ab,'./sr-cyrl':0x26bb,'./sr-cyrl.js':0x26bb,'./sr.js':0x23ab,'./ss':0x1705,'./ss.js':0x1705,'./sv':0x2238,'./sv.js':0x2238,'./sw':0x494,'./sw.js':0x494,'./ta':0x1ca5,'./ta.js':0x1ca5,'./te':0xc26,'./te.js':0xc26,'./tet':0x82f,'./tet.js':0x82f,'./tg':0x1c99,'./tg.js':0x1c99,'./th':0x2351,'./th.js':0x2351,'./tk':0x232d,'./tk.js':0x232d,'./tl-ph':0x1688,'./tl-ph.js':0x1688,'./tlh':0x24e4,'./tlh.js':0x24e4,'./tr':0x95d,'./tr.js':0x95d,'./tzl':0x203e,'./tzl.js':0x203e,'./tzm':0x452,'./tzm-latn':0x2bb,'./tzm-latn.js':0x2bb,'./tzm.js':0x452,'./ug-cn':0x2448,'./ug-cn.js':0x2448,'./uk':0x1e0b,'./uk.js':0x1e0b,'./ur':0xed3,'./ur.js':0xed3,'./uz':0x1a87,'./uz-latn':0x24c,'./uz-latn.js':0x24c,'./uz.js':0x1a87,'./vi':0x1622,'./vi.js':0x1622,'./x-pseudo':0x111a,'./x-pseudo.js':0x111a,'./yo':0x16ad,'./yo.js':0x16ad,'./zh-cn':0xeff,'./zh-cn.js':0xeff,'./zh-hk':0x165e,'./zh-hk.js':0x165e,'./zh-mo':0x264f,'./zh-mo.js':0x264f,'./zh-tw':0x1038,'./zh-tw.js':0x1038};function _0x3c22cd(_0x2984f9){var _0x4dec65=_0x29953d(_0x2984f9);return _0x4c1e34(_0x4dec65);}function _0x29953d(_0x3361f0){const _0x33dec5=a0_0x4e0a;if(!_0x4c1e34['o'](_0x2446e5,_0x3361f0)){var _0x56267f=new Error(_0x33dec5('0x12d7')+_0x3361f0+'\x27');_0x56267f[_0x33dec5('0x1245')]='MODULE_NOT_FOUND';throw _0x56267f;}return _0x2446e5[_0x3361f0];}_0x3c22cd[_0x19ad23('0x55e')]=function _0x5c10bd(){const _0x3cfd03=_0x19ad23;return Object[_0x3cfd03('0x55e')](_0x2446e5);},_0x3c22cd[_0x19ad23('0xed7')]=_0x29953d,_0x237c23[_0x19ad23('0x6e7')]=_0x3c22cd,_0x3c22cd['id']=0x1a2c;},0x1666:_0x5eafe4=>{'use strict';_0x5eafe4['exports']=angular;}},0x0,[[0x2069,0x29a,0x301]]]); \ No newline at end of file diff --git a/public/index.html b/public/index.html index 5c989ef..00b626e 100644 --- a/public/index.html +++ b/public/index.html @@ -1,7 +1,7 @@ -xCALLY Motion
\ No newline at end of file +
\ No newline at end of file diff --git a/public/runtime-472ac7a6568b98562237.js b/public/runtime-472ac7a6568b98562237.js index 6e6d6d1..ff6ac34 100644 --- a/public/runtime-472ac7a6568b98562237.js +++ b/public/runtime-472ac7a6568b98562237.js @@ -1 +1 @@ -var a1_0x41b8=["splice","return this","exports","length","shift","apply","children","amdD","default","hasOwnProperty","object","call","push","define cannot be used indirect","webpackChunkmotion_client","loaded","defineProperty","paths","slice"];!function(r,e){!function(e){for(;--e;)r.push(r.shift())}(++e)}(a1_0x41b8,182);var a1_0x117e=function(r,e){return a1_0x41b8[r-=0]};(()=>{"use strict";var r,e,x={},a={};function t(r){var e=a1_0x117e;if(a[r])return a[r][e("0xa")];var n=a[r]={id:r,loaded:!1,exports:{}};return x[r][e("0x0")](n.exports,n,n[e("0xa")],t),n[e("0x4")]=!0,n.exports}t.m=x,t[(e=a1_0x117e)("0xf")]=function(){throw new Error(e("0x2"))},t.n=r=>{var e=a1_0x117e,x=r&&r.__esModule?()=>r[e("0x10")]:()=>r;return t.d(x,{a:x}),x},t.d=(r,e)=>{var x=a1_0x117e;for(var a in e)t.o(e,a)&&!t.o(r,a)&&Object[x("0x5")](r,a,{enumerable:!0,get:e[a]})},t.g=function(){var r=a1_0x117e;if(typeof globalThis===r("0x12"))return globalThis;try{return this||new Function(r("0x9"))()}catch(e){if(typeof window===r("0x12"))return window}}(),r=a1_0x117e,t.o=(e,x)=>Object.prototype[r("0x11")].call(e,x),t.nmd=r=>{var e=a1_0x117e;return r[e("0x6")]=[],r[e("0xe")]||(r[e("0xe")]=[]),r},t.p="/",(()=>{var r=a1_0x117e,e={666:0},x=[],a=()=>{};function n(){for(var r,a=a1_0x117e,n=0;n{}),r}t.x=()=>{var r=a1_0x117e;t.x=()=>{},i=i[r("0x7")]();for(var e=0;e{for(var n,o,i=a1_0x117e,[f,c,s,l]=r,d=0,p=[];d{"use strict";var r,e,n={},t={};function x(r){var e=a1_0x52e7;if(t[r])return t[r][e("0xb")];var a=t[r]={id:r,loaded:!1,exports:{}};return n[r][e("0xe")](a.exports,a,a.exports,x),a[e("0xc")]=!0,a[e("0xb")]}x.m=n,x[(e=a1_0x52e7)("0x10")]=function(){throw new Error(e("0x13"))},x.n=r=>{var e=a1_0x52e7,n=r&&r[e("0x12")]?()=>r[e("0x7")]:()=>r;return x.d(n,{a:n}),n},x.d=(r,e)=>{var n=a1_0x52e7;for(var t in e)x.o(e,t)&&!x.o(r,t)&&Object[n("0xa")](r,t,{enumerable:!0,get:e[t]})},x.g=function(){var r=a1_0x52e7;if(typeof globalThis===r("0x9"))return globalThis;try{return this||new Function(r("0x1"))()}catch(e){if(typeof window===r("0x9"))return window}}(),r=a1_0x52e7,x.o=(e,n)=>Object[r("0x0")][r("0xd")].call(e,n),x.nmd=r=>{var e=a1_0x52e7;return r[e("0x2")]=[],r[e("0x14")]||(r.children=[]),r},x.p="/",(()=>{var r=a1_0x52e7,e={666:0},n=[],t=()=>{};function a(){for(var r,t=a1_0x52e7,a=0;a{}),r}x.x=()=>{var r=a1_0x52e7;x.x=()=>{},i=i[r("0x6")]();for(var e=0;e{for(var a,o,i=a1_0x52e7,[u,c,d,l]=r,s=0,p=[];s{"use strict";var e={913:()=>{try{self["workbox:core:6.0.0-alpha.2"]&&_()}catch(e){}},977:()=>{try{self["workbox:precaching:6.0.0-alpha.2"]&&_()}catch(e){}},80:()=>{try{self["workbox:routing:6.0.0-alpha.2"]&&_()}catch(e){}},873:()=>{try{self["workbox:strategies:6.0.0-alpha.2"]&&_()}catch(e){}}},t={};function s(n){if(t[n])return t[n].exports;var a=t[n]={exports:{}};return e[n](a,a.exports,s),a.exports}(()=>{s(913);const e=(e,...t)=>{let s=e;return t.length>0&&(s+=" :: "+JSON.stringify(t)),s};class t extends Error{constructor(t,s){super(e(t,s)),this.name=t,this.details=s}}const n=new Set;const a={googleAnalytics:"googleAnalytics",precache:"precache-v2",prefix:"workbox",runtime:"runtime",suffix:"undefined"!=typeof registration?registration.scope:""},r=e=>[a.prefix,e,a.suffix].filter((e=>e&&e.length>0)).join("-"),i=e=>e||r(a.precache),o=e=>e||r(a.runtime);function c(e,t){const s=new URL(e);for(const e of t)s.searchParams.delete(e);return s.href}let h;class l{constructor(e,t,{onupgradeneeded:s,onversionchange:n}={}){this._db=null,this._name=e,this._version=t,this._onupgradeneeded=s,this._onversionchange=n||(()=>this.close())}get db(){return this._db}async open(){if(!this._db)return this._db=await new Promise(((e,t)=>{let s=!1;setTimeout((()=>{s=!0,t(new Error("The open request was blocked and timed out"))}),this.OPEN_TIMEOUT);const n=indexedDB.open(this._name,this._version);n.onerror=()=>t(n.error),n.onupgradeneeded=e=>{s?(n.transaction.abort(),n.result.close()):"function"==typeof this._onupgradeneeded&&this._onupgradeneeded(e)},n.onsuccess=()=>{const t=n.result;s?t.close():(t.onversionchange=this._onversionchange.bind(this),e(t))}})),this}async getKey(e,t){return(await this.getAllKeys(e,t,1))[0]}async getAll(e,t,s){return await this.getAllMatching(e,{query:t,count:s})}async getAllKeys(e,t,s){return(await this.getAllMatching(e,{query:t,count:s,includeKeys:!0})).map((e=>e.key))}async getAllMatching(e,{index:t,query:s=null,direction:n="next",count:a,includeKeys:r=!1}={}){return await this.transaction([e],"readonly",((i,o)=>{const c=i.objectStore(e),h=t?c.index(t):c,l=[],u=h.openCursor(s,n);u.onsuccess=()=>{const e=u.result;e?(l.push(r?e:e.value),a&&l.length>=a?o(l):e.continue()):o(l)}}))}async transaction(e,t,s){return await this.open(),await new Promise(((n,a)=>{const r=this._db.transaction(e,t);r.onabort=()=>a(r.error),r.oncomplete=()=>n(),s(r,(e=>n(e)))}))}async _call(e,t,s,...n){return await this.transaction([t],s,((s,a)=>{const r=s.objectStore(t),i=r[e].apply(r,n);i.onsuccess=()=>a(i.result)}))}close(){this._db&&(this._db.close(),this._db=null)}}l.prototype.OPEN_TIMEOUT=2e3;const u={readonly:["get","count","getKey","getAll","getAllKeys"],readwrite:["add","put","clear","delete"]};for(const[e,t]of Object.entries(u))for(const s of t)s in IDBObjectStore.prototype&&(l.prototype[s]=async function(t,...n){return await this._call(s,t,e,...n)});class d{constructor(){this.promise=new Promise(((e,t)=>{this.resolve=e,this.reject=t}))}}function f(e,t){const s=t();return e.waitUntil(s),s}async function p(e,s){let n=null;if(e.url){n=new URL(e.url).origin}if(n!==self.location.origin)throw new t("cross-origin-copy-response",{origin:n});const a=e.clone(),r={headers:new Headers(a.headers),status:a.status,statusText:a.statusText},i=s?s(r):r,o=function(){if(void 0===h){const e=new Response("");if("body"in e)try{new Response(e.body),h=!0}catch(e){h=!1}h=!1}return h}()?a.body:await a.blob();return new Response(o,i)}s(977);function y(e){if(!e)throw new t("add-to-cache-list-unexpected-type",{entry:e});if("string"==typeof e){const t=new URL(e,location.href);return{cacheKey:t.href,url:t.href}}const{revision:s,url:n}=e;if(!n)throw new t("add-to-cache-list-unexpected-type",{entry:e});if(!s){const e=new URL(n,location.href);return{cacheKey:e.href,url:e.href}}const a=new URL(n,location.href),r=new URL(n,location.href);return a.searchParams.set("__WB_REVISION__",s),{cacheKey:a.href,url:r.href}}class w{constructor(){this.updatedURLs=[],this.notUpdatedURLs=[],this.handlerWillStart=async({request:e,state:t})=>{t&&(t.originalRequest=e)},this.cachedResponseWillBeUsed=async({event:e,state:t,cachedResponse:s})=>{if("install"===e.type){const e=t.originalRequest.url;s?this.notUpdatedURLs.push(e):this.updatedURLs.push(e)}return s}}}class g{constructor({precacheController:e}){this.cacheKeyWillBeUsed=async({request:e,params:t})=>{const s=t&&t.cacheKey||this._precacheController.getCacheKeyForURL(e.url);return s?new Request(s):e},this._precacheController=e}}s(873);function _(e){return"string"==typeof e?new Request(e):e}class m{constructor(e,t){this._cacheKeys={},Object.assign(this,t),this.event=t.event,this._strategy=e,this._handlerDeferred=new d,this._extendLifetimePromises=[],this._plugins=[...e.plugins],this._pluginStateMap=new Map;for(const e of this._plugins)this._pluginStateMap.set(e,{});this.event.waitUntil(this._handlerDeferred.promise)}fetch(e){return this.waitUntil((async()=>{const{event:s}=this;let n=_(e);if("navigate"===n.mode&&s instanceof FetchEvent&&s.preloadResponse){const e=await s.preloadResponse;if(e)return e}const a=this.hasCallback("fetchDidFail")?n.clone():null;try{for(const e of this.iterateCallbacks("requestWillFetch"))n=await e({request:n.clone(),event:s})}catch(e){throw new t("plugin-error-request-will-fetch",{thrownError:e})}const r=n.clone();try{let e;e=await fetch(n,"navigate"===n.mode?void 0:this._strategy.fetchOptions);for(const t of this.iterateCallbacks("fetchDidSucceed"))e=await t({event:s,request:r,response:e});return e}catch(e){throw a&&await this.runCallbacks("fetchDidFail",{error:e,event:s,originalRequest:a.clone(),request:r.clone()}),e}})())}async fetchAndCachePut(e){const t=await this.fetch(e),s=t.clone();return this.waitUntil(this.cachePut(e,s)),t}cacheMatch(e){return this.waitUntil((async()=>{const t=_(e);let s;const{cacheName:n,matchOptions:a}=this._strategy,r=await this.getCacheKey(t,"read"),i={...a,cacheName:n};s=await caches.match(r,i);for(const e of this.iterateCallbacks("cachedResponseWillBeUsed"))s=await e({cacheName:n,matchOptions:a,cachedResponse:s,request:r,event:this.event})||void 0;return s})())}async cachePut(e,s){const a=_(e);var r;await(r=0,new Promise((e=>setTimeout(e,r))));const i=await this.getCacheKey(a,"write");if(!s)throw new t("cache-put-with-no-response",{url:(o=i.url,new URL(String(o),location.href).href.replace(new RegExp("^"+location.origin),""))});var o;const h=await this._ensureResponseSafeToCache(s);if(!h)return void 0;const{cacheName:l,matchOptions:u}=this._strategy,d=await self.caches.open(l),f=this.hasCallback("cacheDidUpdate"),p=f?await async function(e,t,s,n){const a=c(t.url,s);if(t.url===a)return e.match(t,n);const r={...n,ignoreSearch:!0},i=await e.keys(t,r);for(const t of i)if(a===c(t.url,s))return e.match(t,n)}(d,i.clone(),["__WB_REVISION__"],u):null;try{await d.put(i,f?h.clone():h)}catch(e){throw"QuotaExceededError"===e.name&&await async function(){for(const e of n)await e()}(),e}for(const e of this.iterateCallbacks("cacheDidUpdate"))await e({cacheName:l,oldResponse:p,newResponse:h.clone(),request:i,event:this.event})}async getCacheKey(e,t){if(!this._cacheKeys[t]){let s=e;for(const e of this.iterateCallbacks("cacheKeyWillBeUsed"))s=_(await e({mode:t,request:s,event:this.event,params:this.params}));this._cacheKeys[t]=s}return this._cacheKeys[t]}hasCallback(e){for(const t of this._strategy.plugins)if(e in t)return!0;return!1}async runCallbacks(e,t){for(const s of this.iterateCallbacks(e))await s(t)}*iterateCallbacks(e){for(const t of this._strategy.plugins)if("function"==typeof t[e]){const s=this._pluginStateMap.get(t),n=n=>{const a={...n,state:s};return t[e](a)};yield n}}waitUntil(e){return this._extendLifetimePromises.push(e),e}async doneWaiting(){let e;for(;e=this._extendLifetimePromises.shift();)await e}destroy(){this._handlerDeferred.resolve()}async _ensureResponseSafeToCache(e){let t=e,s=!1;for(const e of this.iterateCallbacks("cacheWillUpdate"))if(t=await e({request:this.request,response:t,event:this.event})||void 0,s=!0,!t)break;return s||t&&200!==t.status&&(t=void 0),t}}const v={cacheWillUpdate:async({response:e})=>e.redirected?await p(e):e};class R extends class{constructor(e={}){this.cacheName=o(e.cacheName),this.plugins=e.plugins||[],this.fetchOptions=e.fetchOptions,this.matchOptions=e.matchOptions}handle(e){const[t]=this.handleAll(e);return t}handleAll(e){e instanceof FetchEvent&&(e={event:e,request:e.request});const t=e.event,s="string"==typeof e.request?new Request(e.request):e.request,n="params"in e?e.params:void 0,a=new m(this,{event:t,request:s,params:n}),r=this._getResponse(a,s,t);return[r,this._awaitComplete(r,a,s,t)]}async _getResponse(e,s,n){await e.runCallbacks("handlerWillStart",{event:n,request:s});let a=void 0;try{if(a=await this._handle(s,e),!a||"error"===a.type)throw new t("no-response",{url:s.url})}catch(t){for(const r of e.iterateCallbacks("handlerDidError"))if(a=await r({error:t,event:n,request:s}),a)break;if(!a)throw t}for(const t of e.iterateCallbacks("handlerWillRespond"))a=await t({event:n,request:s,response:a});return a}async _awaitComplete(e,t,s,n){let a,r;try{a=await e}catch(r){}try{await t.runCallbacks("handlerDidRespond",{event:n,request:s,response:a}),await t.doneWaiting()}catch(e){r=e}if(await t.runCallbacks("handlerDidComplete",{event:n,request:s,response:a,error:r}),t.destroy(),r)throw r}}{constructor(e={}){e.cacheName=i(e.cacheName),super(e),this._fallbackToNetwork=!1!==e.fallbackToNetwork,this.plugins.push(v)}async _handle(e,t){const s=await t.cacheMatch(e);return s||(t.event&&"install"===t.event.type?await this._handleInstall(e,t):await this._handleFetch(e,t))}async _handleFetch(e,s){let n;if(!this._fallbackToNetwork)throw new t("missing-precache-entry",{cacheName:this.cacheName,url:e.url});return n=await s.fetch(e),n}async _handleInstall(e,s){const n=await s.fetchAndCachePut(e);let a=Boolean(n);if(n&&n.status>=400&&!this._usesCustomCacheableResponseLogic()&&(a=!1),!a)throw new t("bad-precaching-response",{url:e.url,status:n.status});return n}_usesCustomCacheableResponseLogic(){return this.plugins.some((e=>e.cacheWillUpdate&&e!==v))}}class b{constructor({cacheName:e,plugins:t=[],fallbackToNetwork:s=!0}={}){this._urlsToCacheKeys=new Map,this._urlsToCacheModes=new Map,this._cacheKeysToIntegrities=new Map,this._strategy=new R({cacheName:i(e),plugins:[...t,new g({precacheController:this})],fallbackToNetwork:s}),this.install=this.install.bind(this),this.activate=this.activate.bind(this)}get strategy(){return this._strategy}precache(e){this.addToCacheList(e),this._installAndActiveListenersAdded||(self.addEventListener("install",this.install),self.addEventListener("activate",this.activate),this._installAndActiveListenersAdded=!0)}addToCacheList(e){const s=[];for(const n of e){"string"==typeof n?s.push(n):n&&void 0===n.revision&&s.push(n.url);const{cacheKey:e,url:a}=y(n),r="string"!=typeof n&&n.revision?"reload":"default";if(this._urlsToCacheKeys.has(a)&&this._urlsToCacheKeys.get(a)!==e)throw new t("add-to-cache-list-conflicting-entries",{firstEntry:this._urlsToCacheKeys.get(a),secondEntry:e});if("string"!=typeof n&&n.integrity){if(this._cacheKeysToIntegrities.has(e)&&this._cacheKeysToIntegrities.get(e)!==n.integrity)throw new t("add-to-cache-list-conflicting-integrities",{url:a});this._cacheKeysToIntegrities.set(e,n.integrity)}if(this._urlsToCacheKeys.set(a,e),this._urlsToCacheModes.set(a,r),s.length>0){const e=`Workbox is precaching URLs without revision info: ${s.join(", ")}\nThis is generally NOT safe. Learn more at https://bit.ly/wb-precache`;console.warn(e)}}}install(e){return f(e,(async()=>{const t=new w;this.strategy.plugins.push(t);for(const[t,s]of this._urlsToCacheKeys){const n=this._cacheKeysToIntegrities.get(s),a=this._urlsToCacheModes.get(t),r=new Request(t,{integrity:n,cache:a,credentials:"same-origin"});await Promise.all(this.strategy.handleAll({params:{cacheKey:s},request:r,event:e}))}const{updatedURLs:s,notUpdatedURLs:n}=t;return{updatedURLs:s,notUpdatedURLs:n}}))}activate(e){return f(e,(async()=>{const e=await self.caches.open(this.strategy.cacheName),t=await e.keys(),s=new Set(this._urlsToCacheKeys.values()),n=[];for(const a of t)s.has(a.url)||(await e.delete(a),n.push(a.url));return{deletedURLs:n}}))}getURLsToCacheKeys(){return this._urlsToCacheKeys}getCachedURLs(){return[...this._urlsToCacheKeys.keys()]}getCacheKeyForURL(e){const t=new URL(e,location.href);return this._urlsToCacheKeys.get(t.href)}async matchPrecache(e){const t=e instanceof Request?e.url:e,s=this.getCacheKeyForURL(t);if(s){return(await self.caches.open(this.strategy.cacheName)).match(s)}}createHandlerBoundToURL(e){const s=this.getCacheKeyForURL(e);if(!s)throw new t("non-precached-url",{url:e});return t=>(t.request=new Request(e),t.params={cacheKey:s,...t.params},this.strategy.handle(t))}}let C;const U=()=>(C||(C=new b),C);s(80);const L=e=>e&&"object"==typeof e?e:{handle:e};class q{constructor(e,t,s="GET"){this.handler=L(t),this.match=e,this.method=s}}class k extends q{constructor(e,t,s){super((({url:t})=>{const s=e.exec(t.href);if(s&&(t.origin===location.origin||0===s.index))return s.slice(1)}),t,s)}}class K{constructor(){this._routes=new Map,this._defaultHandlerMap=new Map}get routes(){return this._routes}addFetchListener(){self.addEventListener("fetch",(e=>{const{request:t}=e,s=this.handleRequest({request:t,event:e});s&&e.respondWith(s)}))}addCacheListener(){self.addEventListener("message",(e=>{if(e.data&&"CACHE_URLS"===e.data.type){const{payload:t}=e.data;0;const s=Promise.all(t.urlsToCache.map((t=>{"string"==typeof t&&(t=[t]);const s=new Request(...t);return this.handleRequest({request:s,event:e})})));e.waitUntil(s),e.ports&&e.ports[0]&&s.then((()=>e.ports[0].postMessage(!0)))}}))}handleRequest({request:e,event:t}){const s=new URL(e.url,location.href);if(!s.protocol.startsWith("http"))return void 0;const n=s.origin===location.origin,{params:a,route:r}=this.findMatchingRoute({event:t,request:e,sameOrigin:n,url:s});let i=r&&r.handler;const o=e.method;if(!i&&this._defaultHandlerMap.has(o)&&(i=this._defaultHandlerMap.get(o)),!i)return void 0;let c;try{c=i.handle({url:s,request:e,event:t,params:a})}catch(e){c=Promise.reject(e)}return c instanceof Promise&&this._catchHandler&&(c=c.catch((n=>this._catchHandler.handle({url:s,request:e,event:t})))),c}findMatchingRoute({url:e,sameOrigin:t,request:s,event:n}){const a=this._routes.get(s.method)||[];for(const r of a){let a;const i=r.match({url:e,sameOrigin:t,request:s,event:n});if(i)return a=i,(Array.isArray(i)&&0===i.length||i.constructor===Object&&0===Object.keys(i).length||"boolean"==typeof i)&&(a=void 0),{route:r,params:a}}return{}}setDefaultHandler(e,t="GET"){this._defaultHandlerMap.set(t,L(e))}setCatchHandler(e){this._catchHandler=L(e)}registerRoute(e){this._routes.has(e.method)||this._routes.set(e.method,[]),this._routes.get(e.method).push(e)}unregisterRoute(e){if(!this._routes.has(e.method))throw new t("unregister-route-but-not-found-with-method",{method:e.method});const s=this._routes.get(e.method).indexOf(e);if(!(s>-1))throw new t("unregister-route-route-not-registered");this._routes.get(e.method).splice(s,1)}}let T;class x extends q{constructor(e,t){super((({request:s})=>{const n=e.getURLsToCacheKeys();for(const e of function*(e,{ignoreURLParametersMatching:t=[/^utm_/,/^fbclid$/],directoryIndex:s="index.html",cleanURLs:n=!0,urlManipulation:a}={}){const r=new URL(e,location.href);r.hash="",yield r.href;const i=function(e,t=[]){for(const s of[...e.searchParams.keys()])t.some((e=>e.test(s)))&&e.searchParams.delete(s);return e}(r,t);if(yield i.href,s&&i.pathname.endsWith("/")){const e=new URL(i.href);e.pathname+=s,yield e.href}if(n){const e=new URL(i.href);e.pathname+=".html",yield e.href}if(a){const e=a({url:r});for(const t of e)yield t.href}}(s.url,t)){const t=n.get(e);if(t)return{cacheKey:t}}}),e.strategy)}}function M(e){const s=U();!function(e,s,n){let a;if("string"==typeof e){const t=new URL(e,location.href);a=new q((({url:e})=>e.href===t.href),s,n)}else if(e instanceof RegExp)a=new k(e,s,n);else if("function"==typeof e)a=new q(e,s,n);else{if(!(e instanceof q))throw new t("unsupported-route-type",{moduleName:"workbox-routing",funcName:"registerRoute",paramName:"capture"});a=e}(T||(T=new K,T.addFetchListener(),T.addCacheListener()),T).registerRoute(a)}(new x(s,e))}const N=self;var E,A;N.skipWaiting(),self.addEventListener("activate",(()=>self.clients.claim())),N.addEventListener("notificationclick",(function(e){const t=e.notification,s=e.action;switch(s){case"accept":case"reject":t.close(),e.waitUntil(N.clients.matchAll({includeUncontrolled:!0,type:"window"}).then((function(e){for(let n=0;n{"use strict";var e={913:()=>{try{self["workbox:core:6.0.0-alpha.2"]&&_()}catch(e){}},977:()=>{try{self["workbox:precaching:6.0.0-alpha.2"]&&_()}catch(e){}},80:()=>{try{self["workbox:routing:6.0.0-alpha.2"]&&_()}catch(e){}},873:()=>{try{self["workbox:strategies:6.0.0-alpha.2"]&&_()}catch(e){}}},t={};function s(n){if(t[n])return t[n].exports;var a=t[n]={exports:{}};return e[n](a,a.exports,s),a.exports}(()=>{s(913);const e=(e,...t)=>{let s=e;return t.length>0&&(s+=" :: "+JSON.stringify(t)),s};class t extends Error{constructor(t,s){super(e(t,s)),this.name=t,this.details=s}}const n=new Set;const a={googleAnalytics:"googleAnalytics",precache:"precache-v2",prefix:"workbox",runtime:"runtime",suffix:"undefined"!=typeof registration?registration.scope:""},r=e=>[a.prefix,e,a.suffix].filter((e=>e&&e.length>0)).join("-"),i=e=>e||r(a.precache),o=e=>e||r(a.runtime);function c(e,t){const s=new URL(e);for(const e of t)s.searchParams.delete(e);return s.href}let h;class l{constructor(e,t,{onupgradeneeded:s,onversionchange:n}={}){this._db=null,this._name=e,this._version=t,this._onupgradeneeded=s,this._onversionchange=n||(()=>this.close())}get db(){return this._db}async open(){if(!this._db)return this._db=await new Promise(((e,t)=>{let s=!1;setTimeout((()=>{s=!0,t(new Error("The open request was blocked and timed out"))}),this.OPEN_TIMEOUT);const n=indexedDB.open(this._name,this._version);n.onerror=()=>t(n.error),n.onupgradeneeded=e=>{s?(n.transaction.abort(),n.result.close()):"function"==typeof this._onupgradeneeded&&this._onupgradeneeded(e)},n.onsuccess=()=>{const t=n.result;s?t.close():(t.onversionchange=this._onversionchange.bind(this),e(t))}})),this}async getKey(e,t){return(await this.getAllKeys(e,t,1))[0]}async getAll(e,t,s){return await this.getAllMatching(e,{query:t,count:s})}async getAllKeys(e,t,s){return(await this.getAllMatching(e,{query:t,count:s,includeKeys:!0})).map((e=>e.key))}async getAllMatching(e,{index:t,query:s=null,direction:n="next",count:a,includeKeys:r=!1}={}){return await this.transaction([e],"readonly",((i,o)=>{const c=i.objectStore(e),h=t?c.index(t):c,l=[],u=h.openCursor(s,n);u.onsuccess=()=>{const e=u.result;e?(l.push(r?e:e.value),a&&l.length>=a?o(l):e.continue()):o(l)}}))}async transaction(e,t,s){return await this.open(),await new Promise(((n,a)=>{const r=this._db.transaction(e,t);r.onabort=()=>a(r.error),r.oncomplete=()=>n(),s(r,(e=>n(e)))}))}async _call(e,t,s,...n){return await this.transaction([t],s,((s,a)=>{const r=s.objectStore(t),i=r[e].apply(r,n);i.onsuccess=()=>a(i.result)}))}close(){this._db&&(this._db.close(),this._db=null)}}l.prototype.OPEN_TIMEOUT=2e3;const u={readonly:["get","count","getKey","getAll","getAllKeys"],readwrite:["add","put","clear","delete"]};for(const[e,t]of Object.entries(u))for(const s of t)s in IDBObjectStore.prototype&&(l.prototype[s]=async function(t,...n){return await this._call(s,t,e,...n)});class d{constructor(){this.promise=new Promise(((e,t)=>{this.resolve=e,this.reject=t}))}}function f(e,t){const s=t();return e.waitUntil(s),s}async function p(e,s){let n=null;if(e.url){n=new URL(e.url).origin}if(n!==self.location.origin)throw new t("cross-origin-copy-response",{origin:n});const a=e.clone(),r={headers:new Headers(a.headers),status:a.status,statusText:a.statusText},i=s?s(r):r,o=function(){if(void 0===h){const e=new Response("");if("body"in e)try{new Response(e.body),h=!0}catch(e){h=!1}h=!1}return h}()?a.body:await a.blob();return new Response(o,i)}s(977);function y(e){if(!e)throw new t("add-to-cache-list-unexpected-type",{entry:e});if("string"==typeof e){const t=new URL(e,location.href);return{cacheKey:t.href,url:t.href}}const{revision:s,url:n}=e;if(!n)throw new t("add-to-cache-list-unexpected-type",{entry:e});if(!s){const e=new URL(n,location.href);return{cacheKey:e.href,url:e.href}}const a=new URL(n,location.href),r=new URL(n,location.href);return a.searchParams.set("__WB_REVISION__",s),{cacheKey:a.href,url:r.href}}class w{constructor(){this.updatedURLs=[],this.notUpdatedURLs=[],this.handlerWillStart=async({request:e,state:t})=>{t&&(t.originalRequest=e)},this.cachedResponseWillBeUsed=async({event:e,state:t,cachedResponse:s})=>{if("install"===e.type){const e=t.originalRequest.url;s?this.notUpdatedURLs.push(e):this.updatedURLs.push(e)}return s}}}class g{constructor({precacheController:e}){this.cacheKeyWillBeUsed=async({request:e,params:t})=>{const s=t&&t.cacheKey||this._precacheController.getCacheKeyForURL(e.url);return s?new Request(s):e},this._precacheController=e}}s(873);function _(e){return"string"==typeof e?new Request(e):e}class m{constructor(e,t){this._cacheKeys={},Object.assign(this,t),this.event=t.event,this._strategy=e,this._handlerDeferred=new d,this._extendLifetimePromises=[],this._plugins=[...e.plugins],this._pluginStateMap=new Map;for(const e of this._plugins)this._pluginStateMap.set(e,{});this.event.waitUntil(this._handlerDeferred.promise)}fetch(e){return this.waitUntil((async()=>{const{event:s}=this;let n=_(e);if("navigate"===n.mode&&s instanceof FetchEvent&&s.preloadResponse){const e=await s.preloadResponse;if(e)return e}const a=this.hasCallback("fetchDidFail")?n.clone():null;try{for(const e of this.iterateCallbacks("requestWillFetch"))n=await e({request:n.clone(),event:s})}catch(e){throw new t("plugin-error-request-will-fetch",{thrownError:e})}const r=n.clone();try{let e;e=await fetch(n,"navigate"===n.mode?void 0:this._strategy.fetchOptions);for(const t of this.iterateCallbacks("fetchDidSucceed"))e=await t({event:s,request:r,response:e});return e}catch(e){throw a&&await this.runCallbacks("fetchDidFail",{error:e,event:s,originalRequest:a.clone(),request:r.clone()}),e}})())}async fetchAndCachePut(e){const t=await this.fetch(e),s=t.clone();return this.waitUntil(this.cachePut(e,s)),t}cacheMatch(e){return this.waitUntil((async()=>{const t=_(e);let s;const{cacheName:n,matchOptions:a}=this._strategy,r=await this.getCacheKey(t,"read"),i={...a,cacheName:n};s=await caches.match(r,i);for(const e of this.iterateCallbacks("cachedResponseWillBeUsed"))s=await e({cacheName:n,matchOptions:a,cachedResponse:s,request:r,event:this.event})||void 0;return s})())}async cachePut(e,s){const a=_(e);var r;await(r=0,new Promise((e=>setTimeout(e,r))));const i=await this.getCacheKey(a,"write");if(!s)throw new t("cache-put-with-no-response",{url:(o=i.url,new URL(String(o),location.href).href.replace(new RegExp("^"+location.origin),""))});var o;const h=await this._ensureResponseSafeToCache(s);if(!h)return void 0;const{cacheName:l,matchOptions:u}=this._strategy,d=await self.caches.open(l),f=this.hasCallback("cacheDidUpdate"),p=f?await async function(e,t,s,n){const a=c(t.url,s);if(t.url===a)return e.match(t,n);const r={...n,ignoreSearch:!0},i=await e.keys(t,r);for(const t of i)if(a===c(t.url,s))return e.match(t,n)}(d,i.clone(),["__WB_REVISION__"],u):null;try{await d.put(i,f?h.clone():h)}catch(e){throw"QuotaExceededError"===e.name&&await async function(){for(const e of n)await e()}(),e}for(const e of this.iterateCallbacks("cacheDidUpdate"))await e({cacheName:l,oldResponse:p,newResponse:h.clone(),request:i,event:this.event})}async getCacheKey(e,t){if(!this._cacheKeys[t]){let s=e;for(const e of this.iterateCallbacks("cacheKeyWillBeUsed"))s=_(await e({mode:t,request:s,event:this.event,params:this.params}));this._cacheKeys[t]=s}return this._cacheKeys[t]}hasCallback(e){for(const t of this._strategy.plugins)if(e in t)return!0;return!1}async runCallbacks(e,t){for(const s of this.iterateCallbacks(e))await s(t)}*iterateCallbacks(e){for(const t of this._strategy.plugins)if("function"==typeof t[e]){const s=this._pluginStateMap.get(t),n=n=>{const a={...n,state:s};return t[e](a)};yield n}}waitUntil(e){return this._extendLifetimePromises.push(e),e}async doneWaiting(){let e;for(;e=this._extendLifetimePromises.shift();)await e}destroy(){this._handlerDeferred.resolve()}async _ensureResponseSafeToCache(e){let t=e,s=!1;for(const e of this.iterateCallbacks("cacheWillUpdate"))if(t=await e({request:this.request,response:t,event:this.event})||void 0,s=!0,!t)break;return s||t&&200!==t.status&&(t=void 0),t}}const v={cacheWillUpdate:async({response:e})=>e.redirected?await p(e):e};class R extends class{constructor(e={}){this.cacheName=o(e.cacheName),this.plugins=e.plugins||[],this.fetchOptions=e.fetchOptions,this.matchOptions=e.matchOptions}handle(e){const[t]=this.handleAll(e);return t}handleAll(e){e instanceof FetchEvent&&(e={event:e,request:e.request});const t=e.event,s="string"==typeof e.request?new Request(e.request):e.request,n="params"in e?e.params:void 0,a=new m(this,{event:t,request:s,params:n}),r=this._getResponse(a,s,t);return[r,this._awaitComplete(r,a,s,t)]}async _getResponse(e,s,n){await e.runCallbacks("handlerWillStart",{event:n,request:s});let a=void 0;try{if(a=await this._handle(s,e),!a||"error"===a.type)throw new t("no-response",{url:s.url})}catch(t){for(const r of e.iterateCallbacks("handlerDidError"))if(a=await r({error:t,event:n,request:s}),a)break;if(!a)throw t}for(const t of e.iterateCallbacks("handlerWillRespond"))a=await t({event:n,request:s,response:a});return a}async _awaitComplete(e,t,s,n){let a,r;try{a=await e}catch(r){}try{await t.runCallbacks("handlerDidRespond",{event:n,request:s,response:a}),await t.doneWaiting()}catch(e){r=e}if(await t.runCallbacks("handlerDidComplete",{event:n,request:s,response:a,error:r}),t.destroy(),r)throw r}}{constructor(e={}){e.cacheName=i(e.cacheName),super(e),this._fallbackToNetwork=!1!==e.fallbackToNetwork,this.plugins.push(v)}async _handle(e,t){const s=await t.cacheMatch(e);return s||(t.event&&"install"===t.event.type?await this._handleInstall(e,t):await this._handleFetch(e,t))}async _handleFetch(e,s){let n;if(!this._fallbackToNetwork)throw new t("missing-precache-entry",{cacheName:this.cacheName,url:e.url});return n=await s.fetch(e),n}async _handleInstall(e,s){const n=await s.fetchAndCachePut(e);let a=Boolean(n);if(n&&n.status>=400&&!this._usesCustomCacheableResponseLogic()&&(a=!1),!a)throw new t("bad-precaching-response",{url:e.url,status:n.status});return n}_usesCustomCacheableResponseLogic(){return this.plugins.some((e=>e.cacheWillUpdate&&e!==v))}}class b{constructor({cacheName:e,plugins:t=[],fallbackToNetwork:s=!0}={}){this._urlsToCacheKeys=new Map,this._urlsToCacheModes=new Map,this._cacheKeysToIntegrities=new Map,this._strategy=new R({cacheName:i(e),plugins:[...t,new g({precacheController:this})],fallbackToNetwork:s}),this.install=this.install.bind(this),this.activate=this.activate.bind(this)}get strategy(){return this._strategy}precache(e){this.addToCacheList(e),this._installAndActiveListenersAdded||(self.addEventListener("install",this.install),self.addEventListener("activate",this.activate),this._installAndActiveListenersAdded=!0)}addToCacheList(e){const s=[];for(const n of e){"string"==typeof n?s.push(n):n&&void 0===n.revision&&s.push(n.url);const{cacheKey:e,url:a}=y(n),r="string"!=typeof n&&n.revision?"reload":"default";if(this._urlsToCacheKeys.has(a)&&this._urlsToCacheKeys.get(a)!==e)throw new t("add-to-cache-list-conflicting-entries",{firstEntry:this._urlsToCacheKeys.get(a),secondEntry:e});if("string"!=typeof n&&n.integrity){if(this._cacheKeysToIntegrities.has(e)&&this._cacheKeysToIntegrities.get(e)!==n.integrity)throw new t("add-to-cache-list-conflicting-integrities",{url:a});this._cacheKeysToIntegrities.set(e,n.integrity)}if(this._urlsToCacheKeys.set(a,e),this._urlsToCacheModes.set(a,r),s.length>0){const e=`Workbox is precaching URLs without revision info: ${s.join(", ")}\nThis is generally NOT safe. Learn more at https://bit.ly/wb-precache`;console.warn(e)}}}install(e){return f(e,(async()=>{const t=new w;this.strategy.plugins.push(t);for(const[t,s]of this._urlsToCacheKeys){const n=this._cacheKeysToIntegrities.get(s),a=this._urlsToCacheModes.get(t),r=new Request(t,{integrity:n,cache:a,credentials:"same-origin"});await Promise.all(this.strategy.handleAll({params:{cacheKey:s},request:r,event:e}))}const{updatedURLs:s,notUpdatedURLs:n}=t;return{updatedURLs:s,notUpdatedURLs:n}}))}activate(e){return f(e,(async()=>{const e=await self.caches.open(this.strategy.cacheName),t=await e.keys(),s=new Set(this._urlsToCacheKeys.values()),n=[];for(const a of t)s.has(a.url)||(await e.delete(a),n.push(a.url));return{deletedURLs:n}}))}getURLsToCacheKeys(){return this._urlsToCacheKeys}getCachedURLs(){return[...this._urlsToCacheKeys.keys()]}getCacheKeyForURL(e){const t=new URL(e,location.href);return this._urlsToCacheKeys.get(t.href)}async matchPrecache(e){const t=e instanceof Request?e.url:e,s=this.getCacheKeyForURL(t);if(s){return(await self.caches.open(this.strategy.cacheName)).match(s)}}createHandlerBoundToURL(e){const s=this.getCacheKeyForURL(e);if(!s)throw new t("non-precached-url",{url:e});return t=>(t.request=new Request(e),t.params={cacheKey:s,...t.params},this.strategy.handle(t))}}let C;const U=()=>(C||(C=new b),C);s(80);const L=e=>e&&"object"==typeof e?e:{handle:e};class q{constructor(e,t,s="GET"){this.handler=L(t),this.match=e,this.method=s}}class k extends q{constructor(e,t,s){super((({url:t})=>{const s=e.exec(t.href);if(s&&(t.origin===location.origin||0===s.index))return s.slice(1)}),t,s)}}class K{constructor(){this._routes=new Map,this._defaultHandlerMap=new Map}get routes(){return this._routes}addFetchListener(){self.addEventListener("fetch",(e=>{const{request:t}=e,s=this.handleRequest({request:t,event:e});s&&e.respondWith(s)}))}addCacheListener(){self.addEventListener("message",(e=>{if(e.data&&"CACHE_URLS"===e.data.type){const{payload:t}=e.data;0;const s=Promise.all(t.urlsToCache.map((t=>{"string"==typeof t&&(t=[t]);const s=new Request(...t);return this.handleRequest({request:s,event:e})})));e.waitUntil(s),e.ports&&e.ports[0]&&s.then((()=>e.ports[0].postMessage(!0)))}}))}handleRequest({request:e,event:t}){const s=new URL(e.url,location.href);if(!s.protocol.startsWith("http"))return void 0;const n=s.origin===location.origin,{params:a,route:r}=this.findMatchingRoute({event:t,request:e,sameOrigin:n,url:s});let i=r&&r.handler;const o=e.method;if(!i&&this._defaultHandlerMap.has(o)&&(i=this._defaultHandlerMap.get(o)),!i)return void 0;let c;try{c=i.handle({url:s,request:e,event:t,params:a})}catch(e){c=Promise.reject(e)}return c instanceof Promise&&this._catchHandler&&(c=c.catch((n=>this._catchHandler.handle({url:s,request:e,event:t})))),c}findMatchingRoute({url:e,sameOrigin:t,request:s,event:n}){const a=this._routes.get(s.method)||[];for(const r of a){let a;const i=r.match({url:e,sameOrigin:t,request:s,event:n});if(i)return a=i,(Array.isArray(i)&&0===i.length||i.constructor===Object&&0===Object.keys(i).length||"boolean"==typeof i)&&(a=void 0),{route:r,params:a}}return{}}setDefaultHandler(e,t="GET"){this._defaultHandlerMap.set(t,L(e))}setCatchHandler(e){this._catchHandler=L(e)}registerRoute(e){this._routes.has(e.method)||this._routes.set(e.method,[]),this._routes.get(e.method).push(e)}unregisterRoute(e){if(!this._routes.has(e.method))throw new t("unregister-route-but-not-found-with-method",{method:e.method});const s=this._routes.get(e.method).indexOf(e);if(!(s>-1))throw new t("unregister-route-route-not-registered");this._routes.get(e.method).splice(s,1)}}let T;class x extends q{constructor(e,t){super((({request:s})=>{const n=e.getURLsToCacheKeys();for(const e of function*(e,{ignoreURLParametersMatching:t=[/^utm_/,/^fbclid$/],directoryIndex:s="index.html",cleanURLs:n=!0,urlManipulation:a}={}){const r=new URL(e,location.href);r.hash="",yield r.href;const i=function(e,t=[]){for(const s of[...e.searchParams.keys()])t.some((e=>e.test(s)))&&e.searchParams.delete(s);return e}(r,t);if(yield i.href,s&&i.pathname.endsWith("/")){const e=new URL(i.href);e.pathname+=s,yield e.href}if(n){const e=new URL(i.href);e.pathname+=".html",yield e.href}if(a){const e=a({url:r});for(const t of e)yield t.href}}(s.url,t)){const t=n.get(e);if(t)return{cacheKey:t}}}),e.strategy)}}function M(e){const s=U();!function(e,s,n){let a;if("string"==typeof e){const t=new URL(e,location.href);a=new q((({url:e})=>e.href===t.href),s,n)}else if(e instanceof RegExp)a=new k(e,s,n);else if("function"==typeof e)a=new q(e,s,n);else{if(!(e instanceof q))throw new t("unsupported-route-type",{moduleName:"workbox-routing",funcName:"registerRoute",paramName:"capture"});a=e}(T||(T=new K,T.addFetchListener(),T.addCacheListener()),T).registerRoute(a)}(new x(s,e))}const N=self;var E,A;N.skipWaiting(),self.addEventListener("activate",(()=>self.clients.claim())),N.addEventListener("notificationclick",(function(e){const t=e.notification,s=e.action;switch(s){case"accept":case"reject":t.close(),e.waitUntil(N.clients.matchAll({includeUncontrolled:!0,type:"window"}).then((function(e){for(let n=0;n=_0x263a16?(_0xcfa9f2=_0x263a16,_0x5f69fb=0xc8):_0x5f69fb=0xce,_0x2e2efb[_0x232f03('0x42')](_0x5f69fb),_0x2e2efb['set'](_0x232f03('0x2a'),_0x2a62bc+'-'+_0xcfa9f2+'/'+_0x263a16)['json'](_0x30137c);}return null;};}function saveUpdates(_0x17396d){return function(_0x44d454){const _0x460fbf=a5_0x31e8;if(_0x44d454)return _0x44d454[_0x460fbf('0x74')](_0x17396d)['then'](function(_0x5dab4e){return _0x5dab4e;});return null;};}function removeEntity(_0x19ccfc){return function(_0xd524c3){const _0x137801=a5_0x31e8;if(_0xd524c3)return _0xd524c3[_0x137801('0x6')]()[_0x137801('0x29')](function(){const _0x47ccaf=_0x137801,_0x1bc75d=_0xd524c3['get']({'plain':!![]}),_0x31eaf7=_0x47ccaf('0x69');return db[_0x47ccaf('0x84')][_0x47ccaf('0x6')]({'where':{'type':_0x31eaf7,'resourceId':_0x1bc75d['id']}})[_0x47ccaf('0x29')](function(){return _0xd524c3;});})[_0x137801('0x29')](function(){const _0x541c95=_0x137801;_0x19ccfc[_0x541c95('0x42')](0xcc)[_0x541c95('0x3b')]();});};}function handleEntityNotFound(_0x17c786){return function(_0x501a37){const _0xa80a0c=a5_0x31e8;return!_0x501a37&&_0x17c786[_0xa80a0c('0x48')](0x194),_0x501a37;};}function handleError(_0x5592c4,_0x3862b0){return _0x3862b0=_0x3862b0||0x1f4,function(_0x19e3b3){const _0x1aa118=a5_0x31e8;logger[_0x1aa118('0x10')](_0x19e3b3[_0x1aa118('0x67')]),_0x19e3b3[_0x1aa118('0x66')]&&delete _0x19e3b3[_0x1aa118('0x66')],_0x5592c4['status'](_0x3862b0)[_0x1aa118('0x19')](_0x19e3b3);};}exports[_0x261047('0x8c')]=function(_0x2d6503,_0x85aaa2){const _0x17fcdb=_0x261047;let _0x4354f9={};const _0x20415f={},_0x10f0d6={'count':0x0,'rows':[]},_0x5c1a8f=_['map'](db[_0x17fcdb('0x21')][_0x17fcdb('0x53')],function(_0x449f6b){const _0x5e629d=_0x17fcdb;return{'name':_0x449f6b['fieldName'],'type':_0x449f6b[_0x5e629d('0x5b')][_0x5e629d('0x75')]};});_0x20415f[_0x17fcdb('0x8e')]=_[_0x17fcdb('0xb')](_0x5c1a8f,_0x17fcdb('0x66')),_0x20415f['query']=_[_0x17fcdb('0x12')](_0x2d6503[_0x17fcdb('0x90')]),_0x20415f[_0x17fcdb('0x16')]=_[_0x17fcdb('0x8')](_0x20415f[_0x17fcdb('0x8e')],_0x20415f['query']),_0x4354f9['attributes']=_[_0x17fcdb('0x8')](_0x20415f[_0x17fcdb('0x8e')],qs['fields'](_0x2d6503[_0x17fcdb('0x90')][_0x17fcdb('0x6e')])),_0x4354f9['attributes']=_0x4354f9[_0x17fcdb('0x7')][_0x17fcdb('0x4d')]?_0x4354f9['attributes']:_0x20415f[_0x17fcdb('0x8e')];typeof _0x2d6503[_0x17fcdb('0x90')][_0x17fcdb('0x14')]===_0x17fcdb('0x24')&&(_0x4354f9[_0x17fcdb('0x88')]=qs[_0x17fcdb('0x88')](_0x2d6503[_0x17fcdb('0x90')]['limit']),_0x4354f9[_0x17fcdb('0x55')]=qs['offset'](_0x2d6503['query'][_0x17fcdb('0x55')]));_0x4354f9[_0x17fcdb('0x4c')]=qs['sort'](_0x2d6503[_0x17fcdb('0x90')][_0x17fcdb('0x18')]),_0x4354f9['where']=qs[_0x17fcdb('0x16')](_[_0x17fcdb('0x76')](_0x2d6503[_0x17fcdb('0x90')],_0x20415f[_0x17fcdb('0x16')]),_0x5c1a8f);_0x2d6503[_0x17fcdb('0x90')][_0x17fcdb('0x6d')]&&(_0x4354f9[_0x17fcdb('0x50')]=_[_0x17fcdb('0x47')](_0x4354f9[_0x17fcdb('0x50')],{[Op['or']]:_[_0x17fcdb('0xb')](_0x5c1a8f,function(_0xc68ebc){const _0x1ef6bd=_0x17fcdb;if(_0xc68ebc[_0x1ef6bd('0x5b')]!==_0x1ef6bd('0x33')){const _0x45a435={};return _0x45a435[_0xc68ebc[_0x1ef6bd('0x66')]]={[Op[_0x1ef6bd('0x1e')]]:'%'+_0x2d6503[_0x1ef6bd('0x90')][_0x1ef6bd('0x6d')]+'%'},_0x45a435;}})}));_0x4354f9=_['merge']({},_0x4354f9,_0x2d6503['options']);const _0x37590a={'where':_0x4354f9['where']};return db[_0x17fcdb('0x21')][_0x17fcdb('0x17')](_0x37590a)[_0x17fcdb('0x29')](function(_0x10396c){const _0x5850c5=_0x17fcdb;return _0x10f0d6[_0x5850c5('0x17')]=_0x10396c,_0x2d6503[_0x5850c5('0x90')][_0x5850c5('0x43')]&&(_0x4354f9[_0x5850c5('0x71')]=[{'all':!![]}]),db['AnalyticCustomReport'][_0x5850c5('0x6b')](_0x4354f9);})[_0x17fcdb('0x29')](function(_0x24b2b5){const _0x521684=_0x17fcdb;return _0x10f0d6[_0x521684('0x9')]=_0x24b2b5,_0x10f0d6;})[_0x17fcdb('0x29')](respondWithFilteredResult(_0x85aaa2,_0x4354f9))[_0x17fcdb('0x3f')](handleError(_0x85aaa2,null));},exports[_0x261047('0x7c')]=function(_0x3f311b,_0x3e667e){const _0x1ebcf0=_0x261047;let _0xc7842f={'raw':![],'where':{'id':_0x3f311b['params']['id']}};const _0x42f2d0={};return _0x42f2d0['model']=_[_0x1ebcf0('0x12')](db[_0x1ebcf0('0x21')]['rawAttributes']),_0x42f2d0[_0x1ebcf0('0x90')]=_[_0x1ebcf0('0x12')](_0x3f311b[_0x1ebcf0('0x90')]),_0x42f2d0[_0x1ebcf0('0x16')]=_[_0x1ebcf0('0x8')](_0x42f2d0[_0x1ebcf0('0x8e')],_0x42f2d0[_0x1ebcf0('0x90')]),_0xc7842f[_0x1ebcf0('0x7')]=_[_0x1ebcf0('0x8')](_0x42f2d0[_0x1ebcf0('0x8e')],qs[_0x1ebcf0('0x6e')](_0x3f311b[_0x1ebcf0('0x90')]['fields'])),_0xc7842f[_0x1ebcf0('0x7')]=_0xc7842f[_0x1ebcf0('0x7')][_0x1ebcf0('0x4d')]?_0xc7842f['attributes']:_0x42f2d0[_0x1ebcf0('0x8e')],_0x3f311b[_0x1ebcf0('0x90')][_0x1ebcf0('0x43')]&&(_0xc7842f[_0x1ebcf0('0x71')]=[{'all':!![]}]),_0xc7842f=_[_0x1ebcf0('0x47')]({},_0xc7842f,_0x3f311b['options']),db[_0x1ebcf0('0x21')][_0x1ebcf0('0x52')](_0xc7842f)[_0x1ebcf0('0x29')](handleEntityNotFound(_0x3e667e,null))[_0x1ebcf0('0x29')](respondWithResult(_0x3e667e,null))['catch'](handleError(_0x3e667e,null));},exports[_0x261047('0x38')]=function(_0x3eefc8,_0x4ba7bf){const _0x1e9fbf=_0x261047;return db[_0x1e9fbf('0x21')][_0x1e9fbf('0x38')](_0x3eefc8[_0x1e9fbf('0x11')],{})[_0x1e9fbf('0x29')](function(_0x5e3409){const _0x303537=_0x1e9fbf,_0x9694bc=_0x3eefc8['user'][_0x303537('0x57')]({'plain':!![]});if(!_0x9694bc)throw new Error(_0x303537('0x41'));if(_0x9694bc[_0x303537('0x46')]===_0x303537('0x40')){const _0x2610f3=_0x5e3409[_0x303537('0x57')]({'plain':!![]}),_0x257cd2=_0x303537('0xe');return db[_0x303537('0x70')][_0x303537('0x52')]({'where':{'name':_0x257cd2,'userProfileId':_0x9694bc[_0x303537('0x28')]},'raw':!![]})[_0x303537('0x29')](function(_0x2d19ca){const _0x5d53be=_0x303537;return _0x2d19ca&&_0x2d19ca[_0x5d53be('0x13')]===0x0?db[_0x5d53be('0x84')][_0x5d53be('0x38')]({'name':_0x2610f3[_0x5d53be('0x66')],'resourceId':_0x2610f3['id'],'type':'CustomReports','sectionId':_0x2d19ca['id']},{})[_0x5d53be('0x29')](function(){return _0x5e3409;}):_0x5e3409;})[_0x303537('0x3f')](function(_0x1dfc77){const _0x2916d8=_0x303537;logger[_0x2916d8('0x10')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x1dfc77);throw _0x1dfc77;});}return _0x5e3409;})[_0x1e9fbf('0x29')](respondWithResult(_0x4ba7bf,0xc9))[_0x1e9fbf('0x3f')](handleError(_0x4ba7bf,null));},exports['update']=function(_0x68cd52,_0xcbfc3c){const _0x157beb=_0x261047;return _0x68cd52[_0x157beb('0x11')]['id']&&delete _0x68cd52[_0x157beb('0x11')]['id'],db[_0x157beb('0x21')][_0x157beb('0x52')]({'where':{'id':_0x68cd52[_0x157beb('0x56')]['id']}})['then'](handleEntityNotFound(_0xcbfc3c,null))[_0x157beb('0x29')](saveUpdates(_0x68cd52[_0x157beb('0x11')],null))['then'](respondWithResult(_0xcbfc3c,null))[_0x157beb('0x3f')](handleError(_0xcbfc3c,null));},exports[_0x261047('0x6')]=function(_0xd10179,_0x55103c){const _0x54e79c=_0x261047;return db['AnalyticCustomReport'][_0x54e79c('0x52')]({'where':{'id':_0xd10179[_0x54e79c('0x56')]['id']}})[_0x54e79c('0x29')](handleEntityNotFound(_0x55103c,null))[_0x54e79c('0x29')](removeEntity(_0x55103c,null))[_0x54e79c('0x3f')](handleError(_0x55103c,null));},exports[_0x261047('0x49')]=function(_0x8ae174,_0x3d4e30){const _0x52ba7d=_0x261047,_0x4353a8=0xa,_0x2c64cc=[_0x52ba7d('0x8f'),_0x52ba7d('0x4'),_0x52ba7d('0x1d'),'cross_join'],_0xc6e64b={'SUM':_0x52ba7d('0x20'),'COUNT':_0x52ba7d('0x7d'),'COUNT\x20DISTINCT':_0x52ba7d('0x61'),'MAX':_0x52ba7d('0x65'),'MIN':_0x52ba7d('0x62'),'AVG':_0x52ba7d('0x26'),'GROUP_CONCAT':_0x52ba7d('0x81'),'GROUP_CONCAT\x20ASC':_0x52ba7d('0x7e'),'GROUP_CONCAT\x20DESC':_0x52ba7d('0x32')},_0x3b0702={'SEC_TO_TIME':_0x52ba7d('0x31'),'DATE':_0x52ba7d('0xf'),'HOUR':_0x52ba7d('0x5c'),'ROUND':'ROUND(%s)','UNIX_TIMESTAMP':_0x52ba7d('0x30')},_0x6ce6a=function(_0x31a471){const _0x3d1e72=_0x52ba7d;return!_['includes']([_0x3d1e72('0x77'),_0x3d1e72('0x2e'),'IS\x20EMPTY','IS\x20NOT\x20EMPTY'],_0x31a471);},_0x165073=function(_0x1290e5){const _0x2af1f8=_0x52ba7d;if(!_0x1290e5||!_0x1290e5['rules'][_0x2af1f8('0x4d')])return'';let _0x1e4662='(';for(let _0x4bbb91=0x0;_0x4bbb91<_0x1290e5[_0x2af1f8('0x22')][_0x2af1f8('0x4d')];_0x4bbb91+=0x1){_0x4bbb91>0x0&&(_0x1e4662+='\x20'+_0x1290e5[_0x2af1f8('0x5d')]+'\x20'),_0x1e4662+=_0x1290e5[_0x2af1f8('0x22')][_0x4bbb91][_0x2af1f8('0x7a')]?_0x165073(_0x1290e5[_0x2af1f8('0x22')][_0x4bbb91][_0x2af1f8('0x7a')]):_0x1290e5[_0x2af1f8('0x22')][_0x4bbb91][_0x2af1f8('0x37')]+'\x20'+_0x1290e5[_0x2af1f8('0x22')][_0x4bbb91][_0x2af1f8('0x1')]+(_0x6ce6a(_0x1290e5['rules'][_0x4bbb91][_0x2af1f8('0x1')])?'\x20'+_0x1290e5[_0x2af1f8('0x22')][_0x4bbb91][_0x2af1f8('0x23')]:'');}return _0x1e4662+')';};let _0x125188={'where':{'id':_0x8ae174[_0x52ba7d('0x56')]['id']}},_0x29a2a5,_0x1d2424,_0x2755f3;return _0x125188=_[_0x52ba7d('0x47')]({},_0x125188,_0x8ae174[_0x52ba7d('0x89')]),db[_0x52ba7d('0x21')][_0x52ba7d('0x52')](_0x125188)[_0x52ba7d('0x29')](function(_0x31aa89){const _0x4b379a=_0x52ba7d;if(_0x31aa89)return _0x29a2a5=_0x31aa89,_0x31aa89[_0x4b379a('0xa')]();return null;})['then'](function(_0x409864){const _0xe0e76b=_0x52ba7d;if(_0x409864){if(!_0x409864[_0xe0e76b('0x4d')])throw new ValidationErrorItem(_0xe0e76b('0x4e'),0x193);return _0x1d2424=_0x409864,db[_0xe0e76b('0x82')][_0xe0e76b('0x6b')]({'raw':!![]});}return null;})[_0x52ba7d('0x29')](function(_0x567e5b){const _0x5f2d7b=_0x52ba7d;if(_0x567e5b){_0x2755f3=_[_0x5f2d7b('0x54')](_0x567e5b,'id');let _0x244536;const _0x2c07cf=squel[_0x5f2d7b('0x83')]();_0x2c07cf['from'](_0x29a2a5[_0x5f2d7b('0x3')]);for(let _0x357f98=0x0;_0x357f98<_0x1d2424[_0x5f2d7b('0x4d')];_0x357f98+=0x1){_0x244536=_0x1d2424[_0x357f98]['MetricId']?_0x2755f3[_0x1d2424[_0x357f98]['MetricId']][_0x5f2d7b('0x4b')]:_0x1d2424[_0x357f98][_0x5f2d7b('0x37')],_0x244536=_0x1d2424[_0x357f98]['function']?_['replace'](_0xc6e64b[_0x1d2424[_0x357f98][_0x5f2d7b('0x87')]],'%s',_0x244536):_0x244536,_0x244536=_0x1d2424[_0x357f98][_0x5f2d7b('0x3c')]?_[_0x5f2d7b('0x45')](_0x3b0702[_0x1d2424[_0x357f98][_0x5f2d7b('0x3c')]],'%s',_0x244536):_0x244536,_0x1d2424[_0x357f98][_0x5f2d7b('0x8d')]&&_0x2c07cf[_0x5f2d7b('0x7a')](_0x244536),_0x1d2424[_0x357f98][_0x5f2d7b('0xd')]&&_0x2c07cf[_0x5f2d7b('0x4c')](_0x244536,_0x1d2424[_0x357f98]['orderBy']==='DESC'?![]:!![]),_0x2c07cf['field'](_0x244536,_0x1d2424[_0x357f98]['alias']||_0x244536);}if(_0x29a2a5[_0x5f2d7b('0x4a')]){_0x29a2a5[_0x5f2d7b('0x4a')]=JSON['parse'](_0x29a2a5[_0x5f2d7b('0x4a')]);for(let _0x28aa68=0x0;_0x28aa68<_0x29a2a5['joins']['length'];_0x28aa68+=0x1){_0x29a2a5[_0x5f2d7b('0x4a')][_0x28aa68][_0x5f2d7b('0x5b')]&&_[_0x5f2d7b('0x59')](_0x2c64cc,_0x29a2a5[_0x5f2d7b('0x4a')][_0x28aa68][_0x5f2d7b('0x5b')])&&_0x29a2a5[_0x5f2d7b('0x4a')][_0x28aa68][_0x5f2d7b('0x2c')]&&_0x29a2a5[_0x5f2d7b('0x4a')][_0x28aa68][_0x5f2d7b('0x3d')]&&_0x29a2a5[_0x5f2d7b('0x4a')][_0x28aa68]['foreignKey']&&_0x2c07cf[_0x29a2a5[_0x5f2d7b('0x4a')][_0x28aa68][_0x5f2d7b('0x5b')]](_0x29a2a5[_0x5f2d7b('0x4a')][_0x28aa68][_0x5f2d7b('0x3d')],null,util[_0x5f2d7b('0x3c')](_0x5f2d7b('0x86'),_0x29a2a5[_0x5f2d7b('0x3')],_0x29a2a5[_0x5f2d7b('0x4a')][_0x28aa68]['parentKey'],_0x29a2a5['joins'][_0x28aa68][_0x5f2d7b('0x3d')],_0x29a2a5[_0x5f2d7b('0x4a')][_0x28aa68][_0x5f2d7b('0x5e')]));}}return _0x29a2a5[_0x5f2d7b('0x72')]&&(_0x29a2a5[_0x5f2d7b('0x72')]=JSON['parse'](_0x29a2a5[_0x5f2d7b('0x72')]),_0x2c07cf[_0x5f2d7b('0x50')](_0x165073(_0x29a2a5[_0x5f2d7b('0x72')][_0x5f2d7b('0x7a')]))),_0x2c07cf[_0x5f2d7b('0x88')](_0x4353a8),_0x2c07cf['offset'](0x0),logger[_0x5f2d7b('0x8b')]('Limited\x20Query:',_0x2c07cf[_0x5f2d7b('0x3e')]()),db[_0x5f2d7b('0x6c')][_0x5f2d7b('0x90')](_0x2c07cf[_0x5f2d7b('0x3e')](),{'type':QueryTypes[_0x5f2d7b('0x44')]});}})['then'](respondWithResult(_0x3d4e30,null))[_0x52ba7d('0x3f')](handleError(_0x3d4e30,null));};function runReport(_0x42b559,_0x1ef442,_0x6de5d0){const _0x560031=_0x261047,_0x2be0ba=_0x1ef442['name'],_0x255fe7=0xa,_0x4f0ac4=[_0x560031('0x8f'),_0x560031('0x4'),_0x560031('0x1d'),_0x560031('0x1b')],_0x5de14e={'SUM':_0x560031('0x20'),'COUNT':'COUNT(%s)','COUNT\x20DISTINCT':'COUNT(DISTINCT\x20%s)','MAX':'MAX(%s)','MIN':'MIN(%s)','AVG':_0x560031('0x26'),'GROUP_CONCAT':'GROUP_CONCAT(%s)','GROUP_CONCAT\x20ASC':_0x560031('0x7e'),'GROUP_CONCAT\x20DESC':_0x560031('0x32')},_0x75a14c={'SEC_TO_TIME':'SEC_TO_TIME(%s)','DATE':_0x560031('0xf'),'HOUR':_0x560031('0x5c'),'ROUND':_0x560031('0x63'),'UNIX_TIMESTAMP':_0x560031('0x30')},_0x38d652=function(_0x5c2560){const _0x261ec1=_0x560031;return!_['includes']([_0x261ec1('0x77'),_0x261ec1('0x2e'),'IS\x20EMPTY',_0x261ec1('0x85')],_0x5c2560);},_0x532774=function(_0x626f43){const _0x31a329=_0x560031;if(!_0x626f43||!_0x626f43[_0x31a329('0x22')][_0x31a329('0x4d')])return'';let _0x1b31a6='(';for(let _0x4a0d88=0x0;_0x4a0d88<_0x626f43[_0x31a329('0x22')][_0x31a329('0x4d')];_0x4a0d88+=0x1){_0x4a0d88>0x0&&(_0x1b31a6+='\x20'+_0x626f43['operator']+'\x20'),_0x1b31a6+=_0x626f43['rules'][_0x4a0d88][_0x31a329('0x7a')]?_0x532774(_0x626f43[_0x31a329('0x22')][_0x4a0d88]['group']):_0x626f43[_0x31a329('0x22')][_0x4a0d88]['field']+'\x20'+_0x626f43[_0x31a329('0x22')][_0x4a0d88][_0x31a329('0x1')]+(_0x38d652(_0x626f43[_0x31a329('0x22')][_0x4a0d88][_0x31a329('0x1')])?'\x20'+_0x626f43[_0x31a329('0x22')][_0x4a0d88][_0x31a329('0x23')]:'');}return _0x1b31a6+')';};let _0x1f948c={'where':{'id':_0x42b559['id']}},_0x55ddd9,_0x133c21,_0x35cb42,_0x1e075e,_0x86f735;return _0x1f948c=_[_0x560031('0x47')]({},_0x1f948c,_0x6de5d0),db['AnalyticCustomReport'][_0x560031('0x52')](_0x1f948c)['then'](function(_0x5aed0b){const _0x4be447=_0x560031;if(_0x5aed0b)return _0x55ddd9=_0x5aed0b,_0x5aed0b[_0x4be447('0xa')]();return null;})[_0x560031('0x29')](function(_0x145645){const _0x2c7866=_0x560031;if(_0x145645){if(!_0x145645[_0x2c7866('0x4d')])throw new ValidationErrorItem(_0x2c7866('0x4e'),0x193);return _0x133c21=_0x145645,db['AnalyticMetric'][_0x2c7866('0x6b')]({'raw':!![]});}return null;})[_0x560031('0x29')](function(_0x360d08){const _0x2a0e53=_0x560031;if(_0x360d08){_0x35cb42=_[_0x2a0e53('0x54')](_0x360d08,'id');let _0xff5537;const _0x53b83c=squel['select']();_0x53b83c['from'](_0x55ddd9[_0x2a0e53('0x3')]);for(let _0xecc0a9=0x0;_0xecc0a9<_0x133c21[_0x2a0e53('0x4d')];_0xecc0a9+=0x1){_0xff5537=_0x133c21[_0xecc0a9][_0x2a0e53('0x15')]?_0x35cb42[_0x133c21[_0xecc0a9][_0x2a0e53('0x15')]][_0x2a0e53('0x4b')]:_0x133c21[_0xecc0a9][_0x2a0e53('0x37')],_0xff5537=_0x133c21[_0xecc0a9]['function']?_[_0x2a0e53('0x45')](_0x5de14e[_0x133c21[_0xecc0a9][_0x2a0e53('0x87')]],'%s',_0xff5537):_0xff5537,_0xff5537=_0x133c21[_0xecc0a9][_0x2a0e53('0x3c')]?_['replace'](_0x75a14c[_0x133c21[_0xecc0a9][_0x2a0e53('0x3c')]],'%s',_0xff5537):_0xff5537,_0x133c21[_0xecc0a9][_0x2a0e53('0x8d')]&&_0x53b83c[_0x2a0e53('0x7a')](_0xff5537),_0x133c21[_0xecc0a9][_0x2a0e53('0xd')]&&_0x53b83c['order'](_0xff5537,_0x133c21[_0xecc0a9][_0x2a0e53('0xd')]===_0x2a0e53('0x60')?![]:!![]),_0x53b83c['field'](_0xff5537,_0x133c21[_0xecc0a9][_0x2a0e53('0x5a')]||_0xff5537);}if(_0x55ddd9['joins']){_0x55ddd9['joins']=JSON[_0x2a0e53('0x36')](_0x55ddd9[_0x2a0e53('0x4a')]);for(let _0x3030d4=0x0;_0x3030d4<_0x55ddd9[_0x2a0e53('0x4a')][_0x2a0e53('0x4d')];_0x3030d4+=0x1){_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4][_0x2a0e53('0x5b')]&&_[_0x2a0e53('0x59')](_0x4f0ac4,_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4][_0x2a0e53('0x5b')])&&_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4][_0x2a0e53('0x2c')]&&_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4]['foreignTable']&&_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4][_0x2a0e53('0x5e')]&&_0x53b83c[_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4][_0x2a0e53('0x5b')]](_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4][_0x2a0e53('0x3d')],null,util[_0x2a0e53('0x3c')](_0x2a0e53('0x86'),_0x55ddd9[_0x2a0e53('0x3')],_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4][_0x2a0e53('0x2c')],_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4][_0x2a0e53('0x3d')],_0x55ddd9[_0x2a0e53('0x4a')][_0x3030d4]['foreignKey']));}}return _0x55ddd9[_0x2a0e53('0x72')]&&(_0x55ddd9[_0x2a0e53('0x72')]=JSON[_0x2a0e53('0x36')](_0x55ddd9[_0x2a0e53('0x72')]),_0x53b83c[_0x2a0e53('0x50')](_0x532774(_0x55ddd9['conditions'][_0x2a0e53('0x7a')]))),_0x86f735=_0x53b83c[_0x2a0e53('0x4f')](),_0x53b83c[_0x2a0e53('0x88')](_0x255fe7),_0x53b83c[_0x2a0e53('0x55')](0x0),logger['debug']('Limited\x20Query:',_0x53b83c['toString']()),db[_0x2a0e53('0x6c')]['query'](_0x53b83c['toString'](),{'type':QueryTypes[_0x2a0e53('0x44')]});}})[_0x560031('0x29')](function(_0x29fac3){const _0x21e513=_0x560031;if(!_0x29fac3['length'])throw new ValidationErrorItem(_0x21e513('0x73'),0xcc);if(_0x1ef442['output']===_0x21e513('0x1a'))return null;const _0x311f6e=_[_0x21e513('0x47')](_0x1ef442,{'name':_0x1ef442['fullPath']||_0x1ef442['name']||_0x55ddd9[_0x21e513('0x66')],'basename':_0x2be0ba,'savename':util['format'](_0x21e513('0x79'),_0x1ef442['name']||_0x55ddd9[_0x21e513('0x66')],require(_0x21e513('0x5'))[_0x21e513('0x1f')](0x4),_0x1ef442[_0x21e513('0x27')]||'csv'),'reportId':_0x55ddd9['id'],'reportType':_0x21e513('0x5f')});return db['AnalyticExtractedReport'][_0x21e513('0x38')](_0x311f6e,{'raw':!![]});})[_0x560031('0x29')](function(_0x5d9205){const _0x390462=_0x560031;_0x55ddd9['table']===_0x390462('0x2')?_0x86f735[_0x390462('0x50')](_0x55ddd9[_0x390462('0x3')]+_0x390462('0x68'),_0x1ef442[_0x390462('0x80')],_0x1ef442[_0x390462('0x58')]):_0x86f735[_0x390462('0x50')](_0x55ddd9[_0x390462('0x3')]+_0x390462('0x6f'),_0x1ef442[_0x390462('0x80')],_0x1ef442['endDate']);if(_0x5d9205)return logger[_0x390462('0x7f')](_0x390462('0x64'),_0x86f735[_0x390462('0x3e')]()),require(_0x390462('0x51'))['fork'](path[_0x390462('0x8f')](__dirname,_0x390462('0x25'),_0x5d9205['output']),[_0x5d9205['id'],_0x86f735['toString'](),path[_0x390462('0x8f')](__dirname,_0x390462('0x2b'),_0x5d9205['savename']),_0x2be0ba]),_0x5d9205;else{const _0x3a9646=squel[_0x390462('0x83')]();return _0x3a9646['from']('('+_0x86f735['toString']()+')','countTable'),_0x3a9646[_0x390462('0x37')]('COUNT(*)','count'),_0x86f735[_0x390462('0x88')](_0x1ef442[_0x390462('0x88')]||_0x255fe7),_0x86f735[_0x390462('0x55')](_0x1ef442[_0x390462('0x55')]||0x0),dbH[_0x390462('0x6c')][_0x390462('0x90')](_0x3a9646[_0x390462('0x3e')](),{'type':dbH['sequelize'][_0x390462('0x6a')][_0x390462('0x44')]})[_0x390462('0x29')](function(_0x5f60fb){const _0x34fee3=_0x390462;return!_0x5f60fb['length']?_0x1e075e=0x0:_0x1e075e=_0x5f60fb[0x0][_0x34fee3('0x17')]||0x0,dbH[_0x34fee3('0x6c')]['query'](_0x86f735['toString'](),{'type':dbH[_0x34fee3('0x6c')][_0x34fee3('0x6a')][_0x34fee3('0x44')]});})[_0x390462('0x29')](function(_0x31f961){return{'rows':_0x31f961||[],'count':_0x1e075e};});}});}exports['run']=function(_0x18fee2,_0x494ef9){const _0x21969b=_0x261047;return runReport(_0x18fee2[_0x21969b('0x56')],_0x18fee2[_0x21969b('0x90')],_0x18fee2['options'])[_0x21969b('0x29')](respondWithResult(_0x494ef9,null))['catch'](handleError(_0x494ef9,null));},exports[_0x261047('0xc')]=runReport,exports['query']=function(_0x1bc2f6,_0x23b4d6){const _0x561e4e=_0x261047,_0x54acd8=0xa,_0x577071=[_0x561e4e('0x8f'),_0x561e4e('0x4'),_0x561e4e('0x1d'),_0x561e4e('0x1b')],_0x5b1762={'SUM':_0x561e4e('0x20'),'COUNT':_0x561e4e('0x7d'),'COUNT\x20DISTINCT':_0x561e4e('0x61'),'MAX':_0x561e4e('0x65'),'MIN':_0x561e4e('0x62'),'AVG':_0x561e4e('0x26'),'GROUP_CONCAT':_0x561e4e('0x81'),'GROUP_CONCAT\x20ASC':_0x561e4e('0x7e'),'GROUP_CONCAT\x20DESC':'GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20DESC)'},_0x58d2db={'SEC_TO_TIME':_0x561e4e('0x31'),'DATE':'DATE(%s)','HOUR':_0x561e4e('0x5c'),'ROUND':_0x561e4e('0x63'),'UNIX_TIMESTAMP':_0x561e4e('0x30')},_0x4ca26=function(_0x2e2819){const _0x2dda6a=_0x561e4e;return!_[_0x2dda6a('0x59')]([_0x2dda6a('0x77'),'IS\x20NOT\x20NULL',_0x2dda6a('0x0'),_0x2dda6a('0x85')],_0x2e2819);},_0x27525a=function(_0x206aea){const _0x434e7c=_0x561e4e;if(!_0x206aea||!_0x206aea[_0x434e7c('0x22')][_0x434e7c('0x4d')])return'';let _0x422c52='(';for(let _0x58538=0x0;_0x58538<_0x206aea[_0x434e7c('0x22')][_0x434e7c('0x4d')];_0x58538+=0x1){_0x58538>0x0&&(_0x422c52+='\x20'+_0x206aea[_0x434e7c('0x5d')]+'\x20'),_0x422c52+=_0x206aea['rules'][_0x58538][_0x434e7c('0x7a')]?_0x27525a(_0x206aea[_0x434e7c('0x22')][_0x58538]['group']):_0x206aea[_0x434e7c('0x22')][_0x58538][_0x434e7c('0x37')]+'\x20'+_0x206aea[_0x434e7c('0x22')][_0x58538][_0x434e7c('0x1')]+(_0x4ca26(_0x206aea[_0x434e7c('0x22')][_0x58538][_0x434e7c('0x1')])?'\x20'+_0x206aea[_0x434e7c('0x22')][_0x58538][_0x434e7c('0x23')]:'');}return _0x422c52+')';};let _0x374a96={'where':{'id':_0x1bc2f6[_0x561e4e('0x56')]['id']}},_0x4d44be,_0x213c5d,_0x4505d8,_0x3f3d6d;return _0x374a96=_['merge']({},_0x374a96,_0x1bc2f6[_0x561e4e('0x89')]),db[_0x561e4e('0x21')]['findOne'](_0x374a96)[_0x561e4e('0x29')](function(_0x58ec18){const _0x5f05c4=_0x561e4e;if(_0x58ec18)return _0x4d44be=_0x58ec18,_0x58ec18[_0x5f05c4('0xa')]();return null;})[_0x561e4e('0x29')](function(_0x468bd7){const _0x28daed=_0x561e4e;if(_0x468bd7){if(!_0x468bd7['length'])throw new ValidationErrorItem(_0x28daed('0x4e'),0x193);return _0x213c5d=_0x468bd7,db[_0x28daed('0x82')][_0x28daed('0x6b')]({'raw':!![]});}return null;})[_0x561e4e('0x29')](function(_0x287406){const _0x5d5663=_0x561e4e;if(_0x287406){_0x4505d8=_[_0x5d5663('0x54')](_0x287406,'id');let _0x563366;const _0x2d4873=squel[_0x5d5663('0x83')]();_0x2d4873[_0x5d5663('0x2d')](_0x4d44be[_0x5d5663('0x3')]);for(let _0x1d9e1a=0x0;_0x1d9e1a<_0x213c5d[_0x5d5663('0x4d')];_0x1d9e1a+=0x1){_0x563366=_0x213c5d[_0x1d9e1a][_0x5d5663('0x15')]?_0x4505d8[_0x213c5d[_0x1d9e1a][_0x5d5663('0x15')]][_0x5d5663('0x4b')]:_0x213c5d[_0x1d9e1a][_0x5d5663('0x37')],_0x563366=_0x213c5d[_0x1d9e1a][_0x5d5663('0x87')]?_[_0x5d5663('0x45')](_0x5b1762[_0x213c5d[_0x1d9e1a][_0x5d5663('0x87')]],'%s',_0x563366):_0x563366,_0x563366=_0x213c5d[_0x1d9e1a][_0x5d5663('0x3c')]?_[_0x5d5663('0x45')](_0x58d2db[_0x213c5d[_0x1d9e1a]['format']],'%s',_0x563366):_0x563366,_0x213c5d[_0x1d9e1a][_0x5d5663('0x8d')]&&_0x2d4873['group'](_0x563366),_0x213c5d[_0x1d9e1a][_0x5d5663('0xd')]&&_0x2d4873['order'](_0x563366,_0x213c5d[_0x1d9e1a][_0x5d5663('0xd')]===_0x5d5663('0x60')?![]:!![]),_0x2d4873['field'](_0x563366,_0x213c5d[_0x1d9e1a][_0x5d5663('0x5a')]||_0x563366);}if(_0x4d44be['joins']){_0x4d44be[_0x5d5663('0x4a')]=JSON[_0x5d5663('0x36')](_0x4d44be[_0x5d5663('0x4a')]);for(let _0x188b50=0x0;_0x188b50<_0x4d44be[_0x5d5663('0x4a')][_0x5d5663('0x4d')];_0x188b50+=0x1){_0x4d44be[_0x5d5663('0x4a')][_0x188b50][_0x5d5663('0x5b')]&&_[_0x5d5663('0x59')](_0x577071,_0x4d44be['joins'][_0x188b50][_0x5d5663('0x5b')])&&_0x4d44be[_0x5d5663('0x4a')][_0x188b50][_0x5d5663('0x2c')]&&_0x4d44be[_0x5d5663('0x4a')][_0x188b50]['foreignTable']&&_0x4d44be[_0x5d5663('0x4a')][_0x188b50][_0x5d5663('0x5e')]&&_0x2d4873[_0x4d44be[_0x5d5663('0x4a')][_0x188b50]['type']](_0x4d44be[_0x5d5663('0x4a')][_0x188b50][_0x5d5663('0x3d')],null,util[_0x5d5663('0x3c')](_0x5d5663('0x86'),_0x4d44be[_0x5d5663('0x3')],_0x4d44be['joins'][_0x188b50][_0x5d5663('0x2c')],_0x4d44be['joins'][_0x188b50][_0x5d5663('0x3d')],_0x4d44be['joins'][_0x188b50][_0x5d5663('0x5e')]));}}return _0x4d44be[_0x5d5663('0x72')]&&(_0x4d44be[_0x5d5663('0x72')]=JSON[_0x5d5663('0x36')](_0x4d44be[_0x5d5663('0x72')]),_0x2d4873[_0x5d5663('0x50')](_0x27525a(_0x4d44be[_0x5d5663('0x72')]['group']))),_0x3f3d6d=_0x2d4873[_0x5d5663('0x4f')](),_0x2d4873[_0x5d5663('0x88')](_0x54acd8),_0x2d4873[_0x5d5663('0x55')](0x0),logger[_0x5d5663('0x8b')](_0x5d5663('0x34'),_0x2d4873['toString']()),db[_0x5d5663('0x6c')][_0x5d5663('0x90')](_0x2d4873[_0x5d5663('0x3e')](),{'type':QueryTypes[_0x5d5663('0x44')]});}})[_0x561e4e('0x29')](function(){const _0xcf6c03=_0x561e4e;return{'sql':_0x3f3d6d[_0xcf6c03('0x3e')]()};})[_0x561e4e('0x29')](respondWithResult(_0x23b4d6,null))[_0x561e4e('0x3f')](handleError(_0x23b4d6,null));}; \ No newline at end of file +const a5_0x500d=['Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','foreignTable','ROUND(%s)','select','toString','key','HOUR(%s)','update','filters','nolimit','map','startDate','sequelize','keys','findAll','order','includeAll','intersection','clone','replace','MIN(%s)','value','right_join','keyBy','Unable\x20to\x20retrieve\x20the\x20current\x20user','Please\x20insert\x20at\x20least\x20one\x20field','info','util','then','join','operator','options','IS\x20NOT\x20NULL','savename','fieldName','include','type','web','AnalyticCustomReport','model','table','endDate','end','IS\x20NULL','body','metric','error','destroy','dbH','Content-Range','findOne','joins','role','length','function','COUNT(%s)','getFields','send','rawAttributes','format','run','COUNT(*)','user','limit','GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20DESC)','SELECT','SEC_TO_TIME(%s)','UserProfileResource','conditions','squel','offset','DESC','../../components/parsers/qs','pick','count','lodash','name','includes','%s-%s.%s','orderBy','MetricId','set','path','COUNT(DISTINCT\x20%s)','create','where','field','merge','debug','DATE(%s)','IS\x20EMPTY','attributes','show','QueryTypes','parentKey','get','Limited\x20Query:','condition','filter','AVG(%s)','SUM(%s)','like','params','../../components/export/','Run\x20Query:','%s.%s\x20=\x20%s.%s','AnalyticMetric','UNIX_TIMESTAMP(%s)','GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20ASC)','from','left_join','stack','parse','../../config/logger','foreignKey','randomstring','No\x20available\x20data','cross_join','../../files/reports','AnalyticExtractedReport','status','GROUP_CONCAT(%s)','CustomReports','MAX(%s)','.calldate\x20BETWEEN\x20?\x20AND\x20?','query','rules','UserProfileSection','json','IS\x20NOT\x20EMPTY','runReport','userProfileId','groupBy','.createdAt\x20BETWEEN\x20?\x20AND\x20?','autoAssociation','fields','countTable','alias','group','../../mysqldb','catch'];(function(_0x446c25,_0x500ddf){const _0x58b19d=function(_0x3e13aa){while(--_0x3e13aa){_0x446c25['push'](_0x446c25['shift']());}};_0x58b19d(++_0x500ddf);}(a5_0x500d,0x169));const a5_0x58b1=function(_0x446c25,_0x500ddf){_0x446c25=_0x446c25-0x0;let _0x58b19d=a5_0x500d[_0x446c25];return _0x58b19d;};const _0x12d3a5=a5_0x58b1;'use strict';const util=require(_0x12d3a5('0x59')),path=require(_0x12d3a5('0x3')),_=require(_0x12d3a5('0x89')),squel=require(_0x12d3a5('0x83')),qs=require(_0x12d3a5('0x86')),logger=require(_0x12d3a5('0x22'))('api'),db=require(_0x12d3a5('0x3c'))['db'],dbH=require('../../mysqldb')[_0x12d3a5('0x6e')],{Op,ValidationErrorItem,QueryTypes}=require('sequelize');function respondWithResult(_0x3e13aa,_0x5000fa){return _0x5000fa=_0x5000fa||0xc8,function(_0x2f61db){const _0x119b35=a5_0x58b1;if(_0x2f61db)return _0x3e13aa[_0x119b35('0x29')](_0x5000fa)[_0x119b35('0x31')](_0x2f61db);};}function respondWithFilteredResult(_0x5c425d,_0x1c1808){return function(_0x3b2a22){const _0x146cc8=a5_0x58b1;if(_0x3b2a22){const _0x4d5467=_0x3b2a22[_0x146cc8('0x88')],_0x429286=_0x1c1808['offset'];let _0x278ba2=_0x1c1808[_0x146cc8('0x84')]+_0x1c1808[_0x146cc8('0x7d')],_0x1cef88;return _0x278ba2>=_0x4d5467?(_0x278ba2=_0x4d5467,_0x1cef88=0xc8):_0x1cef88=0xce,_0x5c425d['status'](_0x1cef88),_0x5c425d[_0x146cc8('0x2')](_0x146cc8('0x6f'),_0x429286+'-'+_0x278ba2+'/'+_0x4d5467)['json'](_0x3b2a22);}return null;};}function saveUpdates(_0xfe8ab0){return function(_0x135608){const _0x2832e2=a5_0x58b1;if(_0x135608)return _0x135608[_0x2832e2('0x45')](_0xfe8ab0)[_0x2832e2('0x5a')](function(_0x17b856){return _0x17b856;});return null;};}function removeEntity(_0x42ad2d){return function(_0x49ba3a){const _0x3bda78=a5_0x58b1;if(_0x49ba3a)return _0x49ba3a[_0x3bda78('0x6d')]()[_0x3bda78('0x5a')](function(){const _0x815da0=_0x3bda78,_0x1c3f39=_0x49ba3a['get']({'plain':!![]}),_0x4b6c54=_0x815da0('0x2b');return db[_0x815da0('0x81')][_0x815da0('0x6d')]({'where':{'type':_0x4b6c54,'resourceId':_0x1c3f39['id']}})[_0x815da0('0x5a')](function(){return _0x49ba3a;});})['then'](function(){const _0x2ffa5a=_0x3bda78;_0x42ad2d[_0x2ffa5a('0x29')](0xcc)[_0x2ffa5a('0x68')]();});};}function handleEntityNotFound(_0x2694b5){return function(_0x1cc55b){return!_0x1cc55b&&_0x2694b5['sendStatus'](0x194),_0x1cc55b;};}function handleError(_0x2ef669,_0x3a5ed4){return _0x3a5ed4=_0x3a5ed4||0x1f4,function(_0x59f444){const _0x328150=a5_0x58b1;logger[_0x328150('0x6c')](_0x59f444[_0x328150('0x20')]),_0x59f444[_0x328150('0x8a')]&&delete _0x59f444[_0x328150('0x8a')],_0x2ef669[_0x328150('0x29')](_0x3a5ed4)[_0x328150('0x77')](_0x59f444);};}exports['index']=function(_0x4c9b4f,_0x5ef606){const _0x1c51b2=_0x12d3a5;let _0x535664={};const _0x411f8c={},_0x236d12={'count':0x0,'rows':[]},_0x40a86f=_[_0x1c51b2('0x48')](db['AnalyticCustomReport']['rawAttributes'],function(_0x4d475c){const _0x2a6916=_0x1c51b2;return{'name':_0x4d475c[_0x2a6916('0x60')],'type':_0x4d475c[_0x2a6916('0x62')][_0x2a6916('0x43')]};});_0x411f8c[_0x1c51b2('0x65')]=_['map'](_0x40a86f,_0x1c51b2('0x8a')),_0x411f8c['query']=_[_0x1c51b2('0x4b')](_0x4c9b4f[_0x1c51b2('0x2e')]),_0x411f8c[_0x1c51b2('0x46')]=_['intersection'](_0x411f8c['model'],_0x411f8c[_0x1c51b2('0x2e')]),_0x535664[_0x1c51b2('0xc')]=_['intersection'](_0x411f8c[_0x1c51b2('0x65')],qs[_0x1c51b2('0x38')](_0x4c9b4f[_0x1c51b2('0x2e')][_0x1c51b2('0x38')])),_0x535664[_0x1c51b2('0xc')]=_0x535664[_0x1c51b2('0xc')][_0x1c51b2('0x73')]?_0x535664[_0x1c51b2('0xc')]:_0x411f8c[_0x1c51b2('0x65')];typeof _0x4c9b4f['query'][_0x1c51b2('0x47')]==='undefined'&&(_0x535664[_0x1c51b2('0x7d')]=qs['limit'](_0x4c9b4f[_0x1c51b2('0x2e')][_0x1c51b2('0x7d')]),_0x535664[_0x1c51b2('0x84')]=qs[_0x1c51b2('0x84')](_0x4c9b4f[_0x1c51b2('0x2e')][_0x1c51b2('0x84')]));_0x535664['order']=qs['sort'](_0x4c9b4f['query']['sort']),_0x535664['where']=qs[_0x1c51b2('0x46')](_[_0x1c51b2('0x87')](_0x4c9b4f['query'],_0x411f8c[_0x1c51b2('0x46')]),_0x40a86f);_0x4c9b4f[_0x1c51b2('0x2e')]['filter']&&(_0x535664[_0x1c51b2('0x6')]=_[_0x1c51b2('0x8')](_0x535664['where'],{[Op['or']]:_['map'](_0x40a86f,function(_0x3418f8){const _0x17e25d=_0x1c51b2;if(_0x3418f8[_0x17e25d('0x62')]!=='VIRTUAL'){const _0x446cc3={};return _0x446cc3[_0x3418f8[_0x17e25d('0x8a')]]={[Op[_0x17e25d('0x16')]]:'%'+_0x4c9b4f[_0x17e25d('0x2e')][_0x17e25d('0x13')]+'%'},_0x446cc3;}})}));_0x535664=_[_0x1c51b2('0x8')]({},_0x535664,_0x4c9b4f[_0x1c51b2('0x5d')]);const _0x39013a={'where':_0x535664[_0x1c51b2('0x6')]};return db[_0x1c51b2('0x64')][_0x1c51b2('0x88')](_0x39013a)[_0x1c51b2('0x5a')](function(_0x4d07c7){const _0x46856d=_0x1c51b2;return _0x236d12[_0x46856d('0x88')]=_0x4d07c7,_0x4c9b4f['query'][_0x46856d('0x4e')]&&(_0x535664[_0x46856d('0x61')]=[{'all':!![]}]),db[_0x46856d('0x64')][_0x46856d('0x4c')](_0x535664);})[_0x1c51b2('0x5a')](function(_0x1278a8){return _0x236d12['rows']=_0x1278a8,_0x236d12;})['then'](respondWithFilteredResult(_0x5ef606,_0x535664))[_0x1c51b2('0x3d')](handleError(_0x5ef606,null));},exports[_0x12d3a5('0xd')]=function(_0x5c475e,_0x88d019){const _0x11246a=_0x12d3a5;let _0xb7a809={'raw':![],'where':{'id':_0x5c475e[_0x11246a('0x17')]['id']}};const _0x12b2fd={};return _0x12b2fd['model']=_[_0x11246a('0x4b')](db[_0x11246a('0x64')][_0x11246a('0x78')]),_0x12b2fd[_0x11246a('0x2e')]=_[_0x11246a('0x4b')](_0x5c475e[_0x11246a('0x2e')]),_0x12b2fd['filters']=_[_0x11246a('0x4f')](_0x12b2fd[_0x11246a('0x65')],_0x12b2fd[_0x11246a('0x2e')]),_0xb7a809['attributes']=_['intersection'](_0x12b2fd[_0x11246a('0x65')],qs[_0x11246a('0x38')](_0x5c475e['query']['fields'])),_0xb7a809[_0x11246a('0xc')]=_0xb7a809['attributes'][_0x11246a('0x73')]?_0xb7a809[_0x11246a('0xc')]:_0x12b2fd[_0x11246a('0x65')],_0x5c475e['query'][_0x11246a('0x4e')]&&(_0xb7a809[_0x11246a('0x61')]=[{'all':!![]}]),_0xb7a809=_[_0x11246a('0x8')]({},_0xb7a809,_0x5c475e[_0x11246a('0x5d')]),db['AnalyticCustomReport'][_0x11246a('0x70')](_0xb7a809)[_0x11246a('0x5a')](handleEntityNotFound(_0x88d019,null))['then'](respondWithResult(_0x88d019,null))[_0x11246a('0x3d')](handleError(_0x88d019,null));},exports[_0x12d3a5('0x5')]=function(_0x18eb44,_0x40a3ca){const _0x5a3954=_0x12d3a5;return db[_0x5a3954('0x64')][_0x5a3954('0x5')](_0x18eb44[_0x5a3954('0x6a')],{})[_0x5a3954('0x5a')](function(_0x1d33a8){const _0x9dba8b=_0x5a3954,_0x34b4ba=_0x18eb44['user']['get']({'plain':!![]});if(!_0x34b4ba)throw new Error(_0x9dba8b('0x56'));if(_0x34b4ba[_0x9dba8b('0x72')]===_0x9dba8b('0x7c')){const _0x27eabb=_0x1d33a8[_0x9dba8b('0x10')]({'plain':!![]}),_0x17f3bf='Reports';return db[_0x9dba8b('0x30')]['findOne']({'where':{'name':_0x17f3bf,'userProfileId':_0x34b4ba[_0x9dba8b('0x34')]},'raw':!![]})['then'](function(_0x2ef788){const _0x40b3ca=_0x9dba8b;return _0x2ef788&&_0x2ef788[_0x40b3ca('0x37')]===0x0?db[_0x40b3ca('0x81')][_0x40b3ca('0x5')]({'name':_0x27eabb[_0x40b3ca('0x8a')],'resourceId':_0x27eabb['id'],'type':_0x40b3ca('0x2b'),'sectionId':_0x2ef788['id']},{})[_0x40b3ca('0x5a')](function(){return _0x1d33a8;}):_0x1d33a8;})[_0x9dba8b('0x3d')](function(_0x1de2d2){const _0x682a7b=_0x9dba8b;logger[_0x682a7b('0x6c')](_0x682a7b('0x3e'),_0x1de2d2);throw _0x1de2d2;});}return _0x1d33a8;})['then'](respondWithResult(_0x40a3ca,0xc9))[_0x5a3954('0x3d')](handleError(_0x40a3ca,null));},exports[_0x12d3a5('0x45')]=function(_0x455c13,_0x272c39){const _0x4533d0=_0x12d3a5;return _0x455c13[_0x4533d0('0x6a')]['id']&&delete _0x455c13[_0x4533d0('0x6a')]['id'],db[_0x4533d0('0x64')]['findOne']({'where':{'id':_0x455c13[_0x4533d0('0x17')]['id']}})[_0x4533d0('0x5a')](handleEntityNotFound(_0x272c39,null))[_0x4533d0('0x5a')](saveUpdates(_0x455c13['body'],null))[_0x4533d0('0x5a')](respondWithResult(_0x272c39,null))['catch'](handleError(_0x272c39,null));},exports['destroy']=function(_0x2f34b6,_0x3238a8){const _0x7c2540=_0x12d3a5;return db['AnalyticCustomReport']['findOne']({'where':{'id':_0x2f34b6[_0x7c2540('0x17')]['id']}})[_0x7c2540('0x5a')](handleEntityNotFound(_0x3238a8,null))[_0x7c2540('0x5a')](removeEntity(_0x3238a8,null))['catch'](handleError(_0x3238a8,null));},exports['preview']=function(_0x4b01e1,_0x4c69ca){const _0xb19a53=_0x12d3a5,_0x67a06c=0xa,_0x2fc592=[_0xb19a53('0x5b'),_0xb19a53('0x1f'),_0xb19a53('0x54'),_0xb19a53('0x26')],_0x54a1b8={'SUM':_0xb19a53('0x15'),'COUNT':_0xb19a53('0x75'),'COUNT\x20DISTINCT':_0xb19a53('0x4'),'MAX':'MAX(%s)','MIN':'MIN(%s)','AVG':_0xb19a53('0x14'),'GROUP_CONCAT':_0xb19a53('0x2a'),'GROUP_CONCAT\x20ASC':_0xb19a53('0x1d'),'GROUP_CONCAT\x20DESC':_0xb19a53('0x7e')},_0x3cdee2={'SEC_TO_TIME':_0xb19a53('0x80'),'DATE':'DATE(%s)','HOUR':_0xb19a53('0x44'),'ROUND':'ROUND(%s)','UNIX_TIMESTAMP':_0xb19a53('0x1c')},_0xd40fae=function(_0x6acef9){const _0x36873a=_0xb19a53;return!_['includes']([_0x36873a('0x69'),'IS\x20NOT\x20NULL',_0x36873a('0xb'),_0x36873a('0x32')],_0x6acef9);},_0x8a73a0=function(_0x177942){const _0x51f6e2=_0xb19a53;if(!_0x177942||!_0x177942[_0x51f6e2('0x2f')][_0x51f6e2('0x73')])return'';let _0x1203de='(';for(let _0x1e1e4c=0x0;_0x1e1e4c<_0x177942['rules'][_0x51f6e2('0x73')];_0x1e1e4c+=0x1){_0x1e1e4c>0x0&&(_0x1203de+='\x20'+_0x177942[_0x51f6e2('0x5c')]+'\x20'),_0x1203de+=_0x177942[_0x51f6e2('0x2f')][_0x1e1e4c][_0x51f6e2('0x3b')]?_0x8a73a0(_0x177942[_0x51f6e2('0x2f')][_0x1e1e4c][_0x51f6e2('0x3b')]):_0x177942['rules'][_0x1e1e4c][_0x51f6e2('0x7')]+'\x20'+_0x177942[_0x51f6e2('0x2f')][_0x1e1e4c][_0x51f6e2('0x12')]+(_0xd40fae(_0x177942[_0x51f6e2('0x2f')][_0x1e1e4c][_0x51f6e2('0x12')])?'\x20'+_0x177942['rules'][_0x1e1e4c][_0x51f6e2('0x53')]:'');}return _0x1203de+')';};let _0x349ff1={'where':{'id':_0x4b01e1[_0xb19a53('0x17')]['id']}},_0x2d06e6,_0x4b45bd,_0x5d77ff;return _0x349ff1=_['merge']({},_0x349ff1,_0x4b01e1[_0xb19a53('0x5d')]),db[_0xb19a53('0x64')]['findOne'](_0x349ff1)[_0xb19a53('0x5a')](function(_0x301251){const _0x45f99f=_0xb19a53;if(_0x301251)return _0x2d06e6=_0x301251,_0x301251[_0x45f99f('0x76')]();return null;})[_0xb19a53('0x5a')](function(_0x58b293){const _0x41bbca=_0xb19a53;if(_0x58b293){if(!_0x58b293['length'])throw new ValidationErrorItem('Please\x20insert\x20at\x20least\x20one\x20field',0x193);return _0x4b45bd=_0x58b293,db[_0x41bbca('0x1b')][_0x41bbca('0x4c')]({'raw':!![]});}return null;})[_0xb19a53('0x5a')](function(_0x32768a){const _0x1ae73b=_0xb19a53;if(_0x32768a){_0x5d77ff=_[_0x1ae73b('0x55')](_0x32768a,'id');let _0x16f223;const _0x494d7a=squel[_0x1ae73b('0x41')]();_0x494d7a[_0x1ae73b('0x1e')](_0x2d06e6[_0x1ae73b('0x66')]);for(let _0x2ce21b=0x0;_0x2ce21b<_0x4b45bd['length'];_0x2ce21b+=0x1){_0x16f223=_0x4b45bd[_0x2ce21b][_0x1ae73b('0x1')]?_0x5d77ff[_0x4b45bd[_0x2ce21b]['MetricId']][_0x1ae73b('0x6b')]:_0x4b45bd[_0x2ce21b][_0x1ae73b('0x7')],_0x16f223=_0x4b45bd[_0x2ce21b][_0x1ae73b('0x74')]?_[_0x1ae73b('0x51')](_0x54a1b8[_0x4b45bd[_0x2ce21b][_0x1ae73b('0x74')]],'%s',_0x16f223):_0x16f223,_0x16f223=_0x4b45bd[_0x2ce21b][_0x1ae73b('0x79')]?_[_0x1ae73b('0x51')](_0x3cdee2[_0x4b45bd[_0x2ce21b]['format']],'%s',_0x16f223):_0x16f223,_0x4b45bd[_0x2ce21b][_0x1ae73b('0x35')]&&_0x494d7a[_0x1ae73b('0x3b')](_0x16f223),_0x4b45bd[_0x2ce21b][_0x1ae73b('0x0')]&&_0x494d7a[_0x1ae73b('0x4d')](_0x16f223,_0x4b45bd[_0x2ce21b][_0x1ae73b('0x0')]===_0x1ae73b('0x85')?![]:!![]),_0x494d7a[_0x1ae73b('0x7')](_0x16f223,_0x4b45bd[_0x2ce21b][_0x1ae73b('0x3a')]||_0x16f223);}if(_0x2d06e6[_0x1ae73b('0x71')]){_0x2d06e6[_0x1ae73b('0x71')]=JSON[_0x1ae73b('0x21')](_0x2d06e6[_0x1ae73b('0x71')]);for(let _0x1bcf23=0x0;_0x1bcf23<_0x2d06e6[_0x1ae73b('0x71')][_0x1ae73b('0x73')];_0x1bcf23+=0x1){_0x2d06e6['joins'][_0x1bcf23][_0x1ae73b('0x62')]&&_[_0x1ae73b('0x8b')](_0x2fc592,_0x2d06e6[_0x1ae73b('0x71')][_0x1bcf23][_0x1ae73b('0x62')])&&_0x2d06e6['joins'][_0x1bcf23][_0x1ae73b('0xf')]&&_0x2d06e6[_0x1ae73b('0x71')][_0x1bcf23][_0x1ae73b('0x3f')]&&_0x2d06e6[_0x1ae73b('0x71')][_0x1bcf23][_0x1ae73b('0x23')]&&_0x494d7a[_0x2d06e6[_0x1ae73b('0x71')][_0x1bcf23][_0x1ae73b('0x62')]](_0x2d06e6[_0x1ae73b('0x71')][_0x1bcf23][_0x1ae73b('0x3f')],null,util[_0x1ae73b('0x79')](_0x1ae73b('0x1a'),_0x2d06e6[_0x1ae73b('0x66')],_0x2d06e6['joins'][_0x1bcf23]['parentKey'],_0x2d06e6[_0x1ae73b('0x71')][_0x1bcf23][_0x1ae73b('0x3f')],_0x2d06e6['joins'][_0x1bcf23][_0x1ae73b('0x23')]));}}return _0x2d06e6[_0x1ae73b('0x82')]&&(_0x2d06e6['conditions']=JSON['parse'](_0x2d06e6['conditions']),_0x494d7a[_0x1ae73b('0x6')](_0x8a73a0(_0x2d06e6[_0x1ae73b('0x82')][_0x1ae73b('0x3b')]))),_0x494d7a[_0x1ae73b('0x7d')](_0x67a06c),_0x494d7a[_0x1ae73b('0x84')](0x0),logger[_0x1ae73b('0x9')](_0x1ae73b('0x11'),_0x494d7a[_0x1ae73b('0x42')]()),db[_0x1ae73b('0x4a')]['query'](_0x494d7a[_0x1ae73b('0x42')](),{'type':QueryTypes[_0x1ae73b('0x7f')]});}})[_0xb19a53('0x5a')](respondWithResult(_0x4c69ca,null))[_0xb19a53('0x3d')](handleError(_0x4c69ca,null));};function runReport(_0x539adc,_0x176d0e,_0x41aa9d){const _0x1d1c21=_0x12d3a5,_0x1533db=_0x176d0e[_0x1d1c21('0x8a')],_0x31e1f6=0xa,_0x35f6e8=['join','left_join',_0x1d1c21('0x54'),'cross_join'],_0x4b6928={'SUM':_0x1d1c21('0x15'),'COUNT':_0x1d1c21('0x75'),'COUNT\x20DISTINCT':_0x1d1c21('0x4'),'MAX':_0x1d1c21('0x2c'),'MIN':_0x1d1c21('0x52'),'AVG':_0x1d1c21('0x14'),'GROUP_CONCAT':_0x1d1c21('0x2a'),'GROUP_CONCAT\x20ASC':_0x1d1c21('0x1d'),'GROUP_CONCAT\x20DESC':_0x1d1c21('0x7e')},_0x1c950a={'SEC_TO_TIME':_0x1d1c21('0x80'),'DATE':_0x1d1c21('0xa'),'HOUR':_0x1d1c21('0x44'),'ROUND':_0x1d1c21('0x40'),'UNIX_TIMESTAMP':'UNIX_TIMESTAMP(%s)'},_0x29b9cb=function(_0x101922){const _0xb18568=_0x1d1c21;return!_[_0xb18568('0x8b')]([_0xb18568('0x69'),'IS\x20NOT\x20NULL','IS\x20EMPTY',_0xb18568('0x32')],_0x101922);},_0x159a1a=function(_0x4e6668){const _0x31866c=_0x1d1c21;if(!_0x4e6668||!_0x4e6668[_0x31866c('0x2f')][_0x31866c('0x73')])return'';let _0xea6c40='(';for(let _0xf46282=0x0;_0xf46282<_0x4e6668['rules']['length'];_0xf46282+=0x1){_0xf46282>0x0&&(_0xea6c40+='\x20'+_0x4e6668[_0x31866c('0x5c')]+'\x20'),_0xea6c40+=_0x4e6668[_0x31866c('0x2f')][_0xf46282][_0x31866c('0x3b')]?_0x159a1a(_0x4e6668[_0x31866c('0x2f')][_0xf46282][_0x31866c('0x3b')]):_0x4e6668[_0x31866c('0x2f')][_0xf46282]['field']+'\x20'+_0x4e6668['rules'][_0xf46282][_0x31866c('0x12')]+(_0x29b9cb(_0x4e6668[_0x31866c('0x2f')][_0xf46282][_0x31866c('0x12')])?'\x20'+_0x4e6668['rules'][_0xf46282][_0x31866c('0x53')]:'');}return _0xea6c40+')';};let _0x1e5502={'where':{'id':_0x539adc['id']}},_0x36f58a,_0x3726af,_0x4cb6d7,_0x5f35bb,_0x5a8946;return _0x1e5502=_[_0x1d1c21('0x8')]({},_0x1e5502,_0x41aa9d),db[_0x1d1c21('0x64')][_0x1d1c21('0x70')](_0x1e5502)['then'](function(_0x100db7){const _0x54f81a=_0x1d1c21;if(_0x100db7)return _0x36f58a=_0x100db7,_0x100db7[_0x54f81a('0x76')]();return null;})['then'](function(_0x2c3cad){const _0x31f72b=_0x1d1c21;if(_0x2c3cad){if(!_0x2c3cad[_0x31f72b('0x73')])throw new ValidationErrorItem(_0x31f72b('0x57'),0x193);return _0x3726af=_0x2c3cad,db['AnalyticMetric'][_0x31f72b('0x4c')]({'raw':!![]});}return null;})['then'](function(_0x281377){const _0x1170c4=_0x1d1c21;if(_0x281377){_0x4cb6d7=_[_0x1170c4('0x55')](_0x281377,'id');let _0x1292b0;const _0x479e35=squel[_0x1170c4('0x41')]();_0x479e35['from'](_0x36f58a[_0x1170c4('0x66')]);for(let _0x3cb6e6=0x0;_0x3cb6e6<_0x3726af['length'];_0x3cb6e6+=0x1){_0x1292b0=_0x3726af[_0x3cb6e6][_0x1170c4('0x1')]?_0x4cb6d7[_0x3726af[_0x3cb6e6][_0x1170c4('0x1')]][_0x1170c4('0x6b')]:_0x3726af[_0x3cb6e6][_0x1170c4('0x7')],_0x1292b0=_0x3726af[_0x3cb6e6]['function']?_['replace'](_0x4b6928[_0x3726af[_0x3cb6e6][_0x1170c4('0x74')]],'%s',_0x1292b0):_0x1292b0,_0x1292b0=_0x3726af[_0x3cb6e6][_0x1170c4('0x79')]?_['replace'](_0x1c950a[_0x3726af[_0x3cb6e6]['format']],'%s',_0x1292b0):_0x1292b0,_0x3726af[_0x3cb6e6][_0x1170c4('0x35')]&&_0x479e35[_0x1170c4('0x3b')](_0x1292b0),_0x3726af[_0x3cb6e6]['orderBy']&&_0x479e35[_0x1170c4('0x4d')](_0x1292b0,_0x3726af[_0x3cb6e6]['orderBy']===_0x1170c4('0x85')?![]:!![]),_0x479e35['field'](_0x1292b0,_0x3726af[_0x3cb6e6][_0x1170c4('0x3a')]||_0x1292b0);}if(_0x36f58a[_0x1170c4('0x71')]){_0x36f58a['joins']=JSON[_0x1170c4('0x21')](_0x36f58a[_0x1170c4('0x71')]);for(let _0x3b951e=0x0;_0x3b951e<_0x36f58a[_0x1170c4('0x71')]['length'];_0x3b951e+=0x1){_0x36f58a[_0x1170c4('0x71')][_0x3b951e][_0x1170c4('0x62')]&&_[_0x1170c4('0x8b')](_0x35f6e8,_0x36f58a[_0x1170c4('0x71')][_0x3b951e]['type'])&&_0x36f58a['joins'][_0x3b951e]['parentKey']&&_0x36f58a[_0x1170c4('0x71')][_0x3b951e][_0x1170c4('0x3f')]&&_0x36f58a['joins'][_0x3b951e][_0x1170c4('0x23')]&&_0x479e35[_0x36f58a[_0x1170c4('0x71')][_0x3b951e][_0x1170c4('0x62')]](_0x36f58a[_0x1170c4('0x71')][_0x3b951e][_0x1170c4('0x3f')],null,util[_0x1170c4('0x79')](_0x1170c4('0x1a'),_0x36f58a[_0x1170c4('0x66')],_0x36f58a[_0x1170c4('0x71')][_0x3b951e]['parentKey'],_0x36f58a['joins'][_0x3b951e][_0x1170c4('0x3f')],_0x36f58a[_0x1170c4('0x71')][_0x3b951e][_0x1170c4('0x23')]));}}return _0x36f58a[_0x1170c4('0x82')]&&(_0x36f58a[_0x1170c4('0x82')]=JSON[_0x1170c4('0x21')](_0x36f58a[_0x1170c4('0x82')]),_0x479e35['where'](_0x159a1a(_0x36f58a[_0x1170c4('0x82')][_0x1170c4('0x3b')]))),_0x5a8946=_0x479e35[_0x1170c4('0x50')](),_0x479e35[_0x1170c4('0x7d')](_0x31e1f6),_0x479e35[_0x1170c4('0x84')](0x0),logger[_0x1170c4('0x9')](_0x1170c4('0x11'),_0x479e35[_0x1170c4('0x42')]()),db[_0x1170c4('0x4a')][_0x1170c4('0x2e')](_0x479e35['toString'](),{'type':QueryTypes[_0x1170c4('0x7f')]});}})[_0x1d1c21('0x5a')](function(_0xc5085){const _0x27a7eb=_0x1d1c21;if(!_0xc5085[_0x27a7eb('0x73')])throw new ValidationErrorItem(_0x27a7eb('0x25'),0xcc);if(_0x176d0e['output']===_0x27a7eb('0x63'))return null;const _0x2305cf=_[_0x27a7eb('0x8')](_0x176d0e,{'name':_0x176d0e['fullPath']||_0x176d0e[_0x27a7eb('0x8a')]||_0x36f58a[_0x27a7eb('0x8a')],'basename':_0x1533db,'savename':util[_0x27a7eb('0x79')](_0x27a7eb('0x8c'),_0x176d0e[_0x27a7eb('0x8a')]||_0x36f58a[_0x27a7eb('0x8a')],require(_0x27a7eb('0x24'))['generate'](0x4),_0x176d0e['output']||'csv'),'reportId':_0x36f58a['id'],'reportType':'custom'});return db[_0x27a7eb('0x28')][_0x27a7eb('0x5')](_0x2305cf,{'raw':!![]});})[_0x1d1c21('0x5a')](function(_0xa0bd45){const _0x18598c=_0x1d1c21;_0x36f58a[_0x18598c('0x66')]==='cdr'?_0x5a8946[_0x18598c('0x6')](_0x36f58a['table']+_0x18598c('0x2d'),_0x176d0e['startDate'],_0x176d0e[_0x18598c('0x67')]):_0x5a8946[_0x18598c('0x6')](_0x36f58a['table']+_0x18598c('0x36'),_0x176d0e[_0x18598c('0x49')],_0x176d0e[_0x18598c('0x67')]);if(_0xa0bd45)return logger[_0x18598c('0x58')](_0x18598c('0x19'),_0x5a8946[_0x18598c('0x42')]()),require('child_process')['fork'](path[_0x18598c('0x5b')](__dirname,_0x18598c('0x18'),_0xa0bd45['output']),[_0xa0bd45['id'],_0x5a8946['toString'](),path[_0x18598c('0x5b')](__dirname,_0x18598c('0x27'),_0xa0bd45[_0x18598c('0x5f')]),_0x1533db]),_0xa0bd45;else{const _0x51454a=squel[_0x18598c('0x41')]();return _0x51454a[_0x18598c('0x1e')]('('+_0x5a8946[_0x18598c('0x42')]()+')',_0x18598c('0x39')),_0x51454a[_0x18598c('0x7')](_0x18598c('0x7b'),_0x18598c('0x88')),_0x5a8946[_0x18598c('0x7d')](_0x176d0e[_0x18598c('0x7d')]||_0x31e1f6),_0x5a8946[_0x18598c('0x84')](_0x176d0e[_0x18598c('0x84')]||0x0),dbH[_0x18598c('0x4a')][_0x18598c('0x2e')](_0x51454a[_0x18598c('0x42')](),{'type':dbH['sequelize'][_0x18598c('0xe')]['SELECT']})['then'](function(_0x15b21f){const _0xc33a8e=_0x18598c;return!_0x15b21f[_0xc33a8e('0x73')]?_0x5f35bb=0x0:_0x5f35bb=_0x15b21f[0x0][_0xc33a8e('0x88')]||0x0,dbH[_0xc33a8e('0x4a')][_0xc33a8e('0x2e')](_0x5a8946[_0xc33a8e('0x42')](),{'type':dbH[_0xc33a8e('0x4a')][_0xc33a8e('0xe')]['SELECT']});})[_0x18598c('0x5a')](function(_0xf11ee0){return{'rows':_0xf11ee0||[],'count':_0x5f35bb};});}});}exports[_0x12d3a5('0x7a')]=function(_0x47a420,_0x3409bd){const _0x42f642=_0x12d3a5;return runReport(_0x47a420[_0x42f642('0x17')],_0x47a420[_0x42f642('0x2e')],_0x47a420[_0x42f642('0x5d')])[_0x42f642('0x5a')](respondWithResult(_0x3409bd,null))['catch'](handleError(_0x3409bd,null));},exports[_0x12d3a5('0x33')]=runReport,exports[_0x12d3a5('0x2e')]=function(_0x3d3cfc,_0x27db60){const _0x54ae5f=_0x12d3a5,_0x16f468=0xa,_0x2bde60=[_0x54ae5f('0x5b'),_0x54ae5f('0x1f'),_0x54ae5f('0x54'),_0x54ae5f('0x26')],_0x4e01a8={'SUM':_0x54ae5f('0x15'),'COUNT':_0x54ae5f('0x75'),'COUNT\x20DISTINCT':_0x54ae5f('0x4'),'MAX':_0x54ae5f('0x2c'),'MIN':'MIN(%s)','AVG':_0x54ae5f('0x14'),'GROUP_CONCAT':'GROUP_CONCAT(%s)','GROUP_CONCAT\x20ASC':_0x54ae5f('0x1d'),'GROUP_CONCAT\x20DESC':_0x54ae5f('0x7e')},_0x37a857={'SEC_TO_TIME':_0x54ae5f('0x80'),'DATE':_0x54ae5f('0xa'),'HOUR':_0x54ae5f('0x44'),'ROUND':_0x54ae5f('0x40'),'UNIX_TIMESTAMP':_0x54ae5f('0x1c')},_0x8669a2=function(_0x54f4f7){const _0x42de1d=_0x54ae5f;return!_[_0x42de1d('0x8b')]([_0x42de1d('0x69'),_0x42de1d('0x5e'),_0x42de1d('0xb'),'IS\x20NOT\x20EMPTY'],_0x54f4f7);},_0x20bc85=function(_0x1b4268){const _0x8f7d56=_0x54ae5f;if(!_0x1b4268||!_0x1b4268[_0x8f7d56('0x2f')][_0x8f7d56('0x73')])return'';let _0x1d6db9='(';for(let _0x4790ae=0x0;_0x4790ae<_0x1b4268['rules'][_0x8f7d56('0x73')];_0x4790ae+=0x1){_0x4790ae>0x0&&(_0x1d6db9+='\x20'+_0x1b4268['operator']+'\x20'),_0x1d6db9+=_0x1b4268[_0x8f7d56('0x2f')][_0x4790ae][_0x8f7d56('0x3b')]?_0x20bc85(_0x1b4268[_0x8f7d56('0x2f')][_0x4790ae][_0x8f7d56('0x3b')]):_0x1b4268['rules'][_0x4790ae]['field']+'\x20'+_0x1b4268['rules'][_0x4790ae][_0x8f7d56('0x12')]+(_0x8669a2(_0x1b4268[_0x8f7d56('0x2f')][_0x4790ae][_0x8f7d56('0x12')])?'\x20'+_0x1b4268[_0x8f7d56('0x2f')][_0x4790ae][_0x8f7d56('0x53')]:'');}return _0x1d6db9+')';};let _0x423f6b={'where':{'id':_0x3d3cfc['params']['id']}},_0x3bf988,_0x10ffc4,_0x5936d3,_0x1b1b69;return _0x423f6b=_['merge']({},_0x423f6b,_0x3d3cfc['options']),db[_0x54ae5f('0x64')][_0x54ae5f('0x70')](_0x423f6b)['then'](function(_0x538723){const _0x39b143=_0x54ae5f;if(_0x538723)return _0x3bf988=_0x538723,_0x538723[_0x39b143('0x76')]();return null;})['then'](function(_0x38b055){const _0x4b6023=_0x54ae5f;if(_0x38b055){if(!_0x38b055[_0x4b6023('0x73')])throw new ValidationErrorItem(_0x4b6023('0x57'),0x193);return _0x10ffc4=_0x38b055,db[_0x4b6023('0x1b')][_0x4b6023('0x4c')]({'raw':!![]});}return null;})[_0x54ae5f('0x5a')](function(_0x415f9c){const _0x206339=_0x54ae5f;if(_0x415f9c){_0x5936d3=_[_0x206339('0x55')](_0x415f9c,'id');let _0x28e466;const _0x4bfc9a=squel['select']();_0x4bfc9a[_0x206339('0x1e')](_0x3bf988['table']);for(let _0x16c7ca=0x0;_0x16c7ca<_0x10ffc4[_0x206339('0x73')];_0x16c7ca+=0x1){_0x28e466=_0x10ffc4[_0x16c7ca][_0x206339('0x1')]?_0x5936d3[_0x10ffc4[_0x16c7ca][_0x206339('0x1')]][_0x206339('0x6b')]:_0x10ffc4[_0x16c7ca][_0x206339('0x7')],_0x28e466=_0x10ffc4[_0x16c7ca]['function']?_['replace'](_0x4e01a8[_0x10ffc4[_0x16c7ca][_0x206339('0x74')]],'%s',_0x28e466):_0x28e466,_0x28e466=_0x10ffc4[_0x16c7ca][_0x206339('0x79')]?_[_0x206339('0x51')](_0x37a857[_0x10ffc4[_0x16c7ca]['format']],'%s',_0x28e466):_0x28e466,_0x10ffc4[_0x16c7ca][_0x206339('0x35')]&&_0x4bfc9a[_0x206339('0x3b')](_0x28e466),_0x10ffc4[_0x16c7ca][_0x206339('0x0')]&&_0x4bfc9a[_0x206339('0x4d')](_0x28e466,_0x10ffc4[_0x16c7ca][_0x206339('0x0')]==='DESC'?![]:!![]),_0x4bfc9a[_0x206339('0x7')](_0x28e466,_0x10ffc4[_0x16c7ca]['alias']||_0x28e466);}if(_0x3bf988['joins']){_0x3bf988[_0x206339('0x71')]=JSON[_0x206339('0x21')](_0x3bf988['joins']);for(let _0xf6151a=0x0;_0xf6151a<_0x3bf988['joins'][_0x206339('0x73')];_0xf6151a+=0x1){_0x3bf988[_0x206339('0x71')][_0xf6151a][_0x206339('0x62')]&&_[_0x206339('0x8b')](_0x2bde60,_0x3bf988['joins'][_0xf6151a]['type'])&&_0x3bf988[_0x206339('0x71')][_0xf6151a][_0x206339('0xf')]&&_0x3bf988['joins'][_0xf6151a]['foreignTable']&&_0x3bf988['joins'][_0xf6151a][_0x206339('0x23')]&&_0x4bfc9a[_0x3bf988[_0x206339('0x71')][_0xf6151a]['type']](_0x3bf988[_0x206339('0x71')][_0xf6151a][_0x206339('0x3f')],null,util['format'](_0x206339('0x1a'),_0x3bf988[_0x206339('0x66')],_0x3bf988[_0x206339('0x71')][_0xf6151a][_0x206339('0xf')],_0x3bf988[_0x206339('0x71')][_0xf6151a][_0x206339('0x3f')],_0x3bf988['joins'][_0xf6151a]['foreignKey']));}}return _0x3bf988[_0x206339('0x82')]&&(_0x3bf988['conditions']=JSON['parse'](_0x3bf988['conditions']),_0x4bfc9a['where'](_0x20bc85(_0x3bf988[_0x206339('0x82')][_0x206339('0x3b')]))),_0x1b1b69=_0x4bfc9a['clone'](),_0x4bfc9a[_0x206339('0x7d')](_0x16f468),_0x4bfc9a['offset'](0x0),logger['debug'](_0x206339('0x11'),_0x4bfc9a[_0x206339('0x42')]()),db['sequelize']['query'](_0x4bfc9a[_0x206339('0x42')](),{'type':QueryTypes['SELECT']});}})['then'](function(){const _0x26cac7=_0x54ae5f;return{'sql':_0x1b1b69[_0x26cac7('0x42')]()};})['then'](respondWithResult(_0x27db60,null))[_0x54ae5f('0x3d')](handleError(_0x27db60,null));}; \ No newline at end of file diff --git a/server/api/analyticCustomReport/analyticCustomReport.model.js b/server/api/analyticCustomReport/analyticCustomReport.model.js index d530d23..985b98e 100644 --- a/server/api/analyticCustomReport/analyticCustomReport.model.js +++ b/server/api/analyticCustomReport/analyticCustomReport.model.js @@ -1 +1 @@ -const a6_0x18b1=['./analyticCustomReport.attributes','analytics_custom_reports','define','AnalyticCustomReport'];(function(_0xe1fc91,_0x18b175){const _0x3eda0f=function(_0x42d69d){while(--_0x42d69d){_0xe1fc91['push'](_0xe1fc91['shift']());}};_0x3eda0f(++_0x18b175);}(a6_0x18b1,0x64));const a6_0x3eda=function(_0xe1fc91,_0x18b175){_0xe1fc91=_0xe1fc91-0x0;let _0x3eda0f=a6_0x18b1[_0xe1fc91];return _0x3eda0f;};const _0x1442a0=a6_0x3eda;'use strict';const attributes=require(_0x1442a0('0x0'));module['exports']=function(_0x42d69d){const _0x18c8b1=_0x1442a0,_0xce4415=_0x42d69d[_0x18c8b1('0x2')](_0x18c8b1('0x3'),attributes,{'tableName':_0x18c8b1('0x1'),'paranoid':!![],'indexes':[],'timestamps':!![]});return _0xce4415;}; \ No newline at end of file +const a6_0x4266=['define','exports','AnalyticCustomReport','analytics_custom_reports'];(function(_0x5d46de,_0x4266b1){const _0x2bf913=function(_0x20a397){while(--_0x20a397){_0x5d46de['push'](_0x5d46de['shift']());}};_0x2bf913(++_0x4266b1);}(a6_0x4266,0xe0));const a6_0x2bf9=function(_0x5d46de,_0x4266b1){_0x5d46de=_0x5d46de-0x0;let _0x2bf913=a6_0x4266[_0x5d46de];return _0x2bf913;};const _0x339a4f=a6_0x2bf9;'use strict';const attributes=require('./analyticCustomReport.attributes');module[_0x339a4f('0x1')]=function(_0x20a397){const _0x2a9219=_0x339a4f,_0x348bce=_0x20a397[_0x2a9219('0x0')](_0x2a9219('0x2'),attributes,{'tableName':_0x2a9219('0x3'),'paranoid':!![],'indexes':[],'timestamps':!![]});return _0x348bce;}; \ No newline at end of file diff --git a/server/api/analyticCustomReport/index.js b/server/api/analyticCustomReport/index.js index 4d43f46..d299226 100644 --- a/server/api/analyticCustomReport/index.js +++ b/server/api/analyticCustomReport/index.js @@ -1 +1 @@ -const a7_0x20f6=['create','query','isAuthenticated','express','/:id','run','index','destroy','get','delete','/:id/preview','show','/:id/query','./analyticCustomReport.controller','Router','../../components/auth/service','preview','post'];(function(_0x4225a3,_0x20f68e){const _0x17f4a6=function(_0x42afeb){while(--_0x42afeb){_0x4225a3['push'](_0x4225a3['shift']());}};_0x17f4a6(++_0x20f68e);}(a7_0x20f6,0x12c));const a7_0x17f4=function(_0x4225a3,_0x20f68e){_0x4225a3=_0x4225a3-0x0;let _0x17f4a6=a7_0x20f6[_0x4225a3];return _0x17f4a6;};const _0xa6683d=a7_0x17f4;'use strict';const express=require(_0xa6683d('0x9')),router=express[_0xa6683d('0x2')](),auth=require(_0xa6683d('0x3')),controller=require(_0xa6683d('0x1'));router['get']('/',auth['isAuthenticated'](),controller[_0xa6683d('0xc')]),router[_0xa6683d('0xe')](_0xa6683d('0xa'),auth[_0xa6683d('0x8')](),controller[_0xa6683d('0x11')]),router['get'](_0xa6683d('0x10'),auth['isAuthenticated'](),controller[_0xa6683d('0x4')]),router[_0xa6683d('0xe')]('/:id/run',auth[_0xa6683d('0x8')](),controller[_0xa6683d('0xb')]),router[_0xa6683d('0xe')](_0xa6683d('0x0'),auth['isAuthenticated'](),controller[_0xa6683d('0x7')]),router[_0xa6683d('0x5')]('/',auth['isAuthenticated'](),controller[_0xa6683d('0x6')]),router['put'](_0xa6683d('0xa'),auth[_0xa6683d('0x8')](),controller['update']),router[_0xa6683d('0xf')]('/:id',auth[_0xa6683d('0x8')](),controller[_0xa6683d('0xd')]),module['exports']=router; \ No newline at end of file +const a7_0x5c28=['show','Router','get','exports','update','destroy','/:id/preview','/:id','index','run','create','/:id/query','delete','preview','post','put','../../components/auth/service','isAuthenticated'];(function(_0x1d0cf,_0x5c28b3){const _0xf7f988=function(_0x56bea6){while(--_0x56bea6){_0x1d0cf['push'](_0x1d0cf['shift']());}};_0xf7f988(++_0x5c28b3);}(a7_0x5c28,0xe6));const a7_0xf7f9=function(_0x1d0cf,_0x5c28b3){_0x1d0cf=_0x1d0cf-0x0;let _0xf7f988=a7_0x5c28[_0x1d0cf];return _0xf7f988;};const _0x175a88=a7_0xf7f9;'use strict';const express=require('express'),router=express[_0x175a88('0x5')](),auth=require(_0x175a88('0x2')),controller=require('./analyticCustomReport.controller');router[_0x175a88('0x6')]('/',auth['isAuthenticated'](),controller[_0x175a88('0xc')]),router['get'](_0x175a88('0xb'),auth['isAuthenticated'](),controller[_0x175a88('0x4')]),router[_0x175a88('0x6')](_0x175a88('0xa'),auth[_0x175a88('0x3')](),controller[_0x175a88('0x11')]),router[_0x175a88('0x6')]('/:id/run',auth[_0x175a88('0x3')](),controller[_0x175a88('0xd')]),router[_0x175a88('0x6')](_0x175a88('0xf'),auth[_0x175a88('0x3')](),controller['query']),router[_0x175a88('0x0')]('/',auth[_0x175a88('0x3')](),controller[_0x175a88('0xe')]),router[_0x175a88('0x1')](_0x175a88('0xb'),auth[_0x175a88('0x3')](),controller[_0x175a88('0x8')]),router[_0x175a88('0x10')](_0x175a88('0xb'),auth[_0x175a88('0x3')](),controller[_0x175a88('0x9')]),module[_0x175a88('0x7')]=router; \ No newline at end of file diff --git a/server/api/analyticDefaultReport/analyticDefaultReport.attributes.js b/server/api/analyticDefaultReport/analyticDefaultReport.attributes.js index 51400e1..fc20ab4 100644 --- a/server/api/analyticDefaultReport/analyticDefaultReport.attributes.js +++ b/server/api/analyticDefaultReport/analyticDefaultReport.attributes.js @@ -1 +1 @@ -const a8_0x5bb5=['TEXT','sequelize','exports','STRING'];(function(_0x4e1ca4,_0x5bb5c8){const _0x46ed54=function(_0x282397){while(--_0x282397){_0x4e1ca4['push'](_0x4e1ca4['shift']());}};_0x46ed54(++_0x5bb5c8);}(a8_0x5bb5,0x1d3));const a8_0x46ed=function(_0x4e1ca4,_0x5bb5c8){_0x4e1ca4=_0x4e1ca4-0x0;let _0x46ed54=a8_0x5bb5[_0x4e1ca4];return _0x46ed54;};const _0x5cb1db=a8_0x46ed;'use strict';const Sequelize=require(_0x5cb1db('0x2'));module[_0x5cb1db('0x3')]={'name':{'type':Sequelize[_0x5cb1db('0x0')],'allowNull':![]},'description':{'type':Sequelize[_0x5cb1db('0x0')]},'parent':{'type':Sequelize[_0x5cb1db('0x0')]},'table':{'type':Sequelize[_0x5cb1db('0x0')]},'conditions':{'type':Sequelize[_0x5cb1db('0x1')]},'joins':{'type':Sequelize['TEXT']}}; \ No newline at end of file +const a8_0xfd34=['sequelize','STRING','TEXT'];(function(_0x550200,_0xfd34aa){const _0x12d246=function(_0x3e8d4c){while(--_0x3e8d4c){_0x550200['push'](_0x550200['shift']());}};_0x12d246(++_0xfd34aa);}(a8_0xfd34,0x8b));const a8_0x12d2=function(_0x550200,_0xfd34aa){_0x550200=_0x550200-0x0;let _0x12d246=a8_0xfd34[_0x550200];return _0x12d246;};const _0x25168f=a8_0x12d2;'use strict';const Sequelize=require(_0x25168f('0x2'));module['exports']={'name':{'type':Sequelize[_0x25168f('0x0')],'allowNull':![]},'description':{'type':Sequelize[_0x25168f('0x0')]},'parent':{'type':Sequelize[_0x25168f('0x0')]},'table':{'type':Sequelize[_0x25168f('0x0')]},'conditions':{'type':Sequelize[_0x25168f('0x1')]},'joins':{'type':Sequelize[_0x25168f('0x1')]}}; \ No newline at end of file diff --git a/server/api/analyticDefaultReport/analyticDefaultReport.controller.js b/server/api/analyticDefaultReport/analyticDefaultReport.controller.js index b7dbc0c..08e704a 100644 --- a/server/api/analyticDefaultReport/analyticDefaultReport.controller.js +++ b/server/api/analyticDefaultReport/analyticDefaultReport.controller.js @@ -1 +1 @@ -const a9_0x54fd=['replace','merge','child_process','group','.calldate\x20BETWEEN\x20?\x20AND\x20?','AnalyticExtractedReport','fields','runReport','pick','Please\x20insert\x20at\x20least\x20one\x20field','map','conditions','IS\x20NOT\x20EMPTY','run','type','sort','catch','../../components/parsers/qs','update','MAX(%s)','../../components/export/','user','Unable\x20to\x20retrieve\x20the\x20current\x20user','like','../../config/logger','params','groupBy','UserProfileResource','sequelize','savename','UNIX_TIMESTAMP(%s)','from','squel','format','Limited\x20Query:','SEC_TO_TIME(%s)','keys','role','select','query','AVG(%s)','then','%s.%s\x20=\x20%s.%s','includeAll','function','index','fieldName','randomstring','api','GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20DESC)','GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20ASC)','DESC','lodash','Run\x20Query:','SELECT','count','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','default','QueryTypes','attributes','endDate','model','fullPath','metric','left_join','cdr','MetricId','userProfileId','set','Reports','IS\x20EMPTY','json','operator','includes','cross_join','SUM(%s)','HOUR(%s)','show','countTable','send','parse','key','create','findAll','filter','parentKey','where','IS\x20NOT\x20NULL','join','AnalyticDefaultReport','status','VIRTUAL','offset','web','field','output','foreignKey','error','table','include','clone','ROUND(%s)','COUNT(%s)','No\x20available\x20data','startDate','COUNT(*)','rawAttributes','body','limit','rules','joins','options','DefaultReports','stack','getFields','order','preview','COUNT(DISTINCT\x20%s)','orderBy','toString','condition','get','value','rows','length','generate','DATE(%s)','undefined','keyBy','findOne','IS\x20NULL','GROUP_CONCAT(%s)','info','alias','intersection','destroy','MIN(%s)','end','foreignTable','name','autoAssociation','filters','debug'];(function(_0x5476d6,_0x54fde3){const _0x3704b6=function(_0x7b5557){while(--_0x7b5557){_0x5476d6['push'](_0x5476d6['shift']());}};_0x3704b6(++_0x54fde3);}(a9_0x54fd,0x15c));const a9_0x3704=function(_0x5476d6,_0x54fde3){_0x5476d6=_0x5476d6-0x0;let _0x3704b6=a9_0x54fd[_0x5476d6];return _0x3704b6;};const _0x292f61=a9_0x3704;'use strict';const util=require('util'),path=require('path'),_=require(_0x292f61('0x85')),squel=require(_0x292f61('0x71')),qs=require(_0x292f61('0x62')),logger=require(_0x292f61('0x69'))(_0x292f61('0x81')),db=require('../../mysqldb')['db'],dbH=require('../../mysqldb')['dbH'],{Op,ValidationErrorItem,QueryTypes}=require(_0x292f61('0x6d'));function respondWithResult(_0x7b5557,_0x519251){return _0x519251=_0x519251||0xc8,function(_0x38d6b1){const _0x37afbd=a9_0x3704;if(_0x38d6b1)return _0x7b5557[_0x37afbd('0x1c')](_0x519251)[_0x37afbd('0x9')](_0x38d6b1);};}function respondWithFilteredResult(_0x42f36e,_0x188c0c){return function(_0x3fc16d){const _0x109244=a9_0x3704;if(_0x3fc16d){const _0x57376e=_0x3fc16d[_0x109244('0x88')],_0x578311=_0x188c0c['offset'];let _0x33761c=_0x188c0c['offset']+_0x188c0c[_0x109244('0x2e')],_0x153c9b;return _0x33761c>=_0x57376e?(_0x33761c=_0x57376e,_0x153c9b=0xc8):_0x153c9b=0xce,_0x42f36e[_0x109244('0x1c')](_0x153c9b),_0x42f36e[_0x109244('0x6')]('Content-Range',_0x578311+'-'+_0x33761c+'/'+_0x57376e)[_0x109244('0x9')](_0x3fc16d);}return null;};}function saveUpdates(_0x187890){return function(_0xef1cdb){const _0x26c043=a9_0x3704;if(_0xef1cdb)return _0xef1cdb[_0x26c043('0x63')](_0x187890)['then'](function(_0x44363e){return _0x44363e;});return null;};}function removeEntity(_0x3dd5b4){return function(_0x16494d){const _0x5c2064=a9_0x3704;if(_0x16494d)return _0x16494d[_0x5c2064('0x49')]()[_0x5c2064('0x7a')](function(){const _0x338b01=_0x5c2064,_0x2fb58f=_0x16494d[_0x338b01('0x3b')]({'plain':!![]}),_0x4f2939=_0x338b01('0x32');return db[_0x338b01('0x6c')][_0x338b01('0x49')]({'where':{'type':_0x4f2939,'resourceId':_0x2fb58f['id']}})[_0x338b01('0x7a')](function(){return _0x16494d;});})[_0x5c2064('0x7a')](function(){const _0x29025e=_0x5c2064;_0x3dd5b4[_0x29025e('0x1c')](0xcc)[_0x29025e('0x4b')]();});};}function handleEntityNotFound(_0x295676){return function(_0x5a5cf1){return!_0x5a5cf1&&_0x295676['sendStatus'](0x194),_0x5a5cf1;};}function handleError(_0x5e9831,_0x4ce85d){return _0x4ce85d=_0x4ce85d||0x1f4,function(_0x36b9e6){const _0x40a1ac=a9_0x3704;logger[_0x40a1ac('0x23')](_0x36b9e6[_0x40a1ac('0x33')]),_0x36b9e6['name']&&delete _0x36b9e6[_0x40a1ac('0x4d')],_0x5e9831['status'](_0x4ce85d)[_0x40a1ac('0x11')](_0x36b9e6);};}exports[_0x292f61('0x7e')]=function(_0x2d9b20,_0x2152bd){const _0x28d46e=_0x292f61;let _0x4184bf={};const _0x2f998b={},_0x16ba22={'count':0x0,'rows':[]},_0x3b240d=_[_0x28d46e('0x5b')](db[_0x28d46e('0x1b')][_0x28d46e('0x2c')],function(_0x346d1b){const _0x5ab161=_0x28d46e;return{'name':_0x346d1b[_0x5ab161('0x7f')],'type':_0x346d1b[_0x5ab161('0x5f')][_0x5ab161('0x13')]};});_0x2f998b[_0x28d46e('0x8e')]=_[_0x28d46e('0x5b')](_0x3b240d,_0x28d46e('0x4d')),_0x2f998b[_0x28d46e('0x78')]=_[_0x28d46e('0x75')](_0x2d9b20[_0x28d46e('0x78')]),_0x2f998b[_0x28d46e('0x4f')]=_['intersection'](_0x2f998b[_0x28d46e('0x8e')],_0x2f998b[_0x28d46e('0x78')]),_0x4184bf[_0x28d46e('0x8c')]=_[_0x28d46e('0x48')](_0x2f998b[_0x28d46e('0x8e')],qs[_0x28d46e('0x57')](_0x2d9b20[_0x28d46e('0x78')][_0x28d46e('0x57')])),_0x4184bf['attributes']=_0x4184bf['attributes']['length']?_0x4184bf[_0x28d46e('0x8c')]:_0x2f998b['model'];typeof _0x2d9b20[_0x28d46e('0x78')]['nolimit']===_0x28d46e('0x41')&&(_0x4184bf[_0x28d46e('0x2e')]=qs['limit'](_0x2d9b20['query'][_0x28d46e('0x2e')]),_0x4184bf[_0x28d46e('0x1e')]=qs[_0x28d46e('0x1e')](_0x2d9b20[_0x28d46e('0x78')][_0x28d46e('0x1e')]));_0x4184bf[_0x28d46e('0x35')]=qs[_0x28d46e('0x60')](_0x2d9b20[_0x28d46e('0x78')][_0x28d46e('0x60')]),_0x4184bf[_0x28d46e('0x18')]=qs[_0x28d46e('0x4f')](_[_0x28d46e('0x59')](_0x2d9b20[_0x28d46e('0x78')],_0x2f998b[_0x28d46e('0x4f')]),_0x3b240d);_0x2d9b20[_0x28d46e('0x78')][_0x28d46e('0x16')]&&(_0x4184bf['where']=_[_0x28d46e('0x52')](_0x4184bf['where'],{[Op['or']]:_[_0x28d46e('0x5b')](_0x3b240d,function(_0x364fef){const _0x4c4f4a=_0x28d46e;if(_0x364fef[_0x4c4f4a('0x5f')]!==_0x4c4f4a('0x1d')){const _0x1fafec={};return _0x1fafec[_0x364fef[_0x4c4f4a('0x4d')]]={[Op[_0x4c4f4a('0x68')]]:'%'+_0x2d9b20[_0x4c4f4a('0x78')][_0x4c4f4a('0x16')]+'%'},_0x1fafec;}})}));_0x4184bf=_[_0x28d46e('0x52')]({},_0x4184bf,_0x2d9b20['options']);const _0x8e1ed6={'where':_0x4184bf[_0x28d46e('0x18')]};return db[_0x28d46e('0x1b')][_0x28d46e('0x88')](_0x8e1ed6)[_0x28d46e('0x7a')](function(_0x40c534){const _0x484c9f=_0x28d46e;return _0x16ba22[_0x484c9f('0x88')]=_0x40c534,_0x2d9b20[_0x484c9f('0x78')][_0x484c9f('0x7c')]&&(_0x4184bf[_0x484c9f('0x25')]=[{'all':!![]}]),db[_0x484c9f('0x1b')][_0x484c9f('0x15')](_0x4184bf);})[_0x28d46e('0x7a')](function(_0x3549e7){const _0xd5af7b=_0x28d46e;return _0x16ba22[_0xd5af7b('0x3d')]=_0x3549e7,_0x16ba22;})[_0x28d46e('0x7a')](respondWithFilteredResult(_0x2152bd,_0x4184bf))[_0x28d46e('0x61')](handleError(_0x2152bd,null));},exports[_0x292f61('0xf')]=function(_0x449c4b,_0x176c7b){const _0x2a0163=_0x292f61;let _0x5133cd={'raw':!![],'where':{'id':_0x449c4b[_0x2a0163('0x6a')]['id']}};const _0x17676d={};return _0x17676d[_0x2a0163('0x8e')]=_[_0x2a0163('0x75')](db['AnalyticDefaultReport'][_0x2a0163('0x2c')]),_0x17676d[_0x2a0163('0x78')]=_[_0x2a0163('0x75')](_0x449c4b['query']),_0x17676d['filters']=_[_0x2a0163('0x48')](_0x17676d[_0x2a0163('0x8e')],_0x17676d[_0x2a0163('0x78')]),_0x5133cd['attributes']=_['intersection'](_0x17676d[_0x2a0163('0x8e')],qs[_0x2a0163('0x57')](_0x449c4b[_0x2a0163('0x78')]['fields'])),_0x5133cd['attributes']=_0x5133cd[_0x2a0163('0x8c')][_0x2a0163('0x3e')]?_0x5133cd['attributes']:_0x17676d[_0x2a0163('0x8e')],_0x449c4b[_0x2a0163('0x78')]['includeAll']&&(_0x5133cd[_0x2a0163('0x25')]=[{'all':!![]}]),_0x5133cd=_['merge']({},_0x5133cd,_0x449c4b[_0x2a0163('0x31')]),db[_0x2a0163('0x1b')][_0x2a0163('0x43')](_0x5133cd)[_0x2a0163('0x7a')](handleEntityNotFound(_0x176c7b,null))['then'](respondWithResult(_0x176c7b,null))['catch'](handleError(_0x176c7b,null));},exports['create']=function(_0x255e4a,_0x15d71e){const _0x3ee2f3=_0x292f61;return db['AnalyticDefaultReport'][_0x3ee2f3('0x14')](_0x255e4a[_0x3ee2f3('0x2d')],{})[_0x3ee2f3('0x7a')](function(_0x53c328){const _0x464fbb=_0x3ee2f3,_0x38f7c1=_0x255e4a[_0x464fbb('0x66')][_0x464fbb('0x3b')]({'plain':!![]});if(!_0x38f7c1)throw new Error(_0x464fbb('0x67'));if(_0x38f7c1[_0x464fbb('0x76')]===_0x464fbb('0x66')){const _0x2f7014=_0x53c328[_0x464fbb('0x3b')]({'plain':!![]}),_0x2028aa=_0x464fbb('0x7');return db['UserProfileSection'][_0x464fbb('0x43')]({'where':{'name':_0x2028aa,'userProfileId':_0x38f7c1[_0x464fbb('0x5')]},'raw':!![]})[_0x464fbb('0x7a')](function(_0x11efda){const _0x16ea31=_0x464fbb;return _0x11efda&&_0x11efda[_0x16ea31('0x4e')]===0x0?db['UserProfileResource'][_0x16ea31('0x14')]({'name':_0x2f7014[_0x16ea31('0x4d')],'resourceId':_0x2f7014['id'],'type':_0x16ea31('0x32'),'sectionId':_0x11efda['id']},{})[_0x16ea31('0x7a')](function(){return _0x53c328;}):_0x53c328;})[_0x464fbb('0x61')](function(_0x4d05d5){const _0x51d04a=_0x464fbb;logger['error'](_0x51d04a('0x89'),_0x4d05d5);throw _0x4d05d5;});}return _0x53c328;})[_0x3ee2f3('0x7a')](respondWithResult(_0x15d71e,0xc9))[_0x3ee2f3('0x61')](handleError(_0x15d71e,null));},exports[_0x292f61('0x63')]=function(_0x27420a,_0x34ac17){const _0x3d8228=_0x292f61;return _0x27420a[_0x3d8228('0x2d')]['id']&&delete _0x27420a['body']['id'],db['AnalyticDefaultReport'][_0x3d8228('0x43')]({'where':{'id':_0x27420a[_0x3d8228('0x6a')]['id']}})[_0x3d8228('0x7a')](handleEntityNotFound(_0x34ac17,null))[_0x3d8228('0x7a')](saveUpdates(_0x27420a['body'],null))[_0x3d8228('0x7a')](respondWithResult(_0x34ac17,null))[_0x3d8228('0x61')](handleError(_0x34ac17,null));},exports['destroy']=function(_0x8990b,_0x30be58){const _0x3c4b36=_0x292f61;return db['AnalyticDefaultReport'][_0x3c4b36('0x43')]({'where':{'id':_0x8990b[_0x3c4b36('0x6a')]['id']}})['then'](handleEntityNotFound(_0x30be58,null))[_0x3c4b36('0x7a')](removeEntity(_0x30be58,null))[_0x3c4b36('0x61')](handleError(_0x30be58,null));},exports[_0x292f61('0x36')]=function(_0x49bdc9,_0xf90310){const _0x2b7d49=_0x292f61,_0x1a18b4=0xa,_0x22a6e9=['join','left_join','right_join','cross_join'],_0x3b6d7={'SUM':_0x2b7d49('0xd'),'COUNT':'COUNT(%s)','COUNT\x20DISTINCT':_0x2b7d49('0x37'),'MAX':_0x2b7d49('0x64'),'MIN':_0x2b7d49('0x4a'),'AVG':'AVG(%s)','GROUP_CONCAT':_0x2b7d49('0x45'),'GROUP_CONCAT\x20ASC':_0x2b7d49('0x83'),'GROUP_CONCAT\x20DESC':_0x2b7d49('0x82')},_0x4ede64={'SEC_TO_TIME':'SEC_TO_TIME(%s)','DATE':_0x2b7d49('0x40'),'HOUR':_0x2b7d49('0xe'),'ROUND':_0x2b7d49('0x27'),'UNIX_TIMESTAMP':_0x2b7d49('0x6f')},_0x48ebad=function(_0x4fee3f){const _0x177ea4=_0x2b7d49;return!_[_0x177ea4('0xb')]([_0x177ea4('0x44'),'IS\x20NOT\x20NULL','IS\x20EMPTY',_0x177ea4('0x5d')],_0x4fee3f);},_0x25daf5=function(_0x17eb84){const _0x18cd09=_0x2b7d49;if(!_0x17eb84||!_0x17eb84[_0x18cd09('0x2f')]['length'])return'';let _0x2dae54='(';for(let _0x686094=0x0;_0x686094<_0x17eb84[_0x18cd09('0x2f')][_0x18cd09('0x3e')];_0x686094+=0x1){_0x686094>0x0&&(_0x2dae54+='\x20'+_0x17eb84[_0x18cd09('0xa')]+'\x20'),_0x2dae54+=_0x17eb84['rules'][_0x686094][_0x18cd09('0x54')]?_0x25daf5(_0x17eb84[_0x18cd09('0x2f')][_0x686094][_0x18cd09('0x54')]):_0x17eb84['rules'][_0x686094][_0x18cd09('0x20')]+'\x20'+_0x17eb84['rules'][_0x686094][_0x18cd09('0x3a')]+(_0x48ebad(_0x17eb84[_0x18cd09('0x2f')][_0x686094][_0x18cd09('0x3a')])?'\x20'+_0x17eb84[_0x18cd09('0x2f')][_0x686094][_0x18cd09('0x3c')]:'');}return _0x2dae54+')';};let _0x35575f={'where':{'id':_0x49bdc9[_0x2b7d49('0x6a')]['id']}},_0x4e2110,_0x44bd01,_0x2c6598;return _0x35575f=_['merge']({},_0x35575f,_0x49bdc9[_0x2b7d49('0x31')]),db[_0x2b7d49('0x1b')]['findOne'](_0x35575f)[_0x2b7d49('0x7a')](function(_0x582f1d){const _0x1f0a11=_0x2b7d49;if(_0x582f1d)return _0x4e2110=_0x582f1d,_0x582f1d[_0x1f0a11('0x34')]();return null;})[_0x2b7d49('0x7a')](function(_0x4db434){const _0x176bd9=_0x2b7d49;if(_0x4db434){if(!_0x4db434[_0x176bd9('0x3e')])throw new ValidationErrorItem(_0x176bd9('0x5a'),0x193);return _0x44bd01=_0x4db434,db['AnalyticMetric'][_0x176bd9('0x15')]({'raw':!![]});}return null;})[_0x2b7d49('0x7a')](function(_0x46d171){const _0x3cb99e=_0x2b7d49;if(_0x46d171){_0x2c6598=_['keyBy'](_0x46d171,'id');let _0xe5cb5e;const _0x44ab65=squel[_0x3cb99e('0x77')]();_0x44ab65[_0x3cb99e('0x70')](_0x4e2110[_0x3cb99e('0x24')]);for(let _0x1b9d7a=0x0;_0x1b9d7a<_0x44bd01[_0x3cb99e('0x3e')];_0x1b9d7a+=0x1){_0xe5cb5e=_0x44bd01[_0x1b9d7a][_0x3cb99e('0x4')]?_0x2c6598[_0x44bd01[_0x1b9d7a][_0x3cb99e('0x4')]][_0x3cb99e('0x1')]:_0x44bd01[_0x1b9d7a][_0x3cb99e('0x20')],_0xe5cb5e=_0x44bd01[_0x1b9d7a]['function']?_[_0x3cb99e('0x51')](_0x3b6d7[_0x44bd01[_0x1b9d7a][_0x3cb99e('0x7d')]],'%s',_0xe5cb5e):_0xe5cb5e,_0xe5cb5e=_0x44bd01[_0x1b9d7a]['format']?_['replace'](_0x4ede64[_0x44bd01[_0x1b9d7a][_0x3cb99e('0x72')]],'%s',_0xe5cb5e):_0xe5cb5e,_0x44bd01[_0x1b9d7a][_0x3cb99e('0x6b')]&&_0x44ab65['group'](_0xe5cb5e),_0x44bd01[_0x1b9d7a][_0x3cb99e('0x38')]&&_0x44ab65[_0x3cb99e('0x35')](_0xe5cb5e,_0x44bd01[_0x1b9d7a][_0x3cb99e('0x38')]===_0x3cb99e('0x84')?![]:!![]),_0x44ab65[_0x3cb99e('0x20')](_0xe5cb5e,_0x44bd01[_0x1b9d7a][_0x3cb99e('0x47')]||_0xe5cb5e);}if(_0x4e2110[_0x3cb99e('0x30')]){_0x4e2110[_0x3cb99e('0x30')]=JSON['parse'](_0x4e2110[_0x3cb99e('0x30')]);for(let _0x4ef1c3=0x0;_0x4ef1c3<_0x4e2110[_0x3cb99e('0x30')][_0x3cb99e('0x3e')];_0x4ef1c3+=0x1){_0x4e2110[_0x3cb99e('0x30')][_0x4ef1c3][_0x3cb99e('0x5f')]&&_[_0x3cb99e('0xb')](_0x22a6e9,_0x4e2110[_0x3cb99e('0x30')][_0x4ef1c3]['type'])&&_0x4e2110[_0x3cb99e('0x30')][_0x4ef1c3][_0x3cb99e('0x17')]&&_0x4e2110['joins'][_0x4ef1c3][_0x3cb99e('0x4c')]&&_0x4e2110[_0x3cb99e('0x30')][_0x4ef1c3][_0x3cb99e('0x22')]&&_0x44ab65[_0x4e2110[_0x3cb99e('0x30')][_0x4ef1c3][_0x3cb99e('0x5f')]](_0x4e2110[_0x3cb99e('0x30')][_0x4ef1c3][_0x3cb99e('0x4c')],null,util[_0x3cb99e('0x72')](_0x3cb99e('0x7b'),_0x4e2110[_0x3cb99e('0x24')],_0x4e2110[_0x3cb99e('0x30')][_0x4ef1c3][_0x3cb99e('0x17')],_0x4e2110[_0x3cb99e('0x30')][_0x4ef1c3]['foreignTable'],_0x4e2110['joins'][_0x4ef1c3][_0x3cb99e('0x22')]));}}return _0x4e2110[_0x3cb99e('0x5c')]&&(_0x4e2110[_0x3cb99e('0x5c')]=JSON[_0x3cb99e('0x12')](_0x4e2110[_0x3cb99e('0x5c')]),_0x44ab65['where'](_0x25daf5(_0x4e2110['conditions']['group']))),_0x44ab65[_0x3cb99e('0x2e')](_0x1a18b4),_0x44ab65[_0x3cb99e('0x1e')](0x0),logger[_0x3cb99e('0x50')](_0x3cb99e('0x73'),_0x44ab65['toString']()),db['sequelize'][_0x3cb99e('0x78')](_0x44ab65['toString'](),{'type':QueryTypes[_0x3cb99e('0x87')]});}})[_0x2b7d49('0x7a')](respondWithResult(_0xf90310,null))['catch'](handleError(_0xf90310,null));};function runReport(_0x1de247,_0x62ca93,_0x50657f){const _0xe2f176=_0x292f61,_0x16f642=_0x62ca93[_0xe2f176('0x4d')],_0x1ffc57=0xa,_0x56dfb8=['join',_0xe2f176('0x2'),'right_join',_0xe2f176('0xc')],_0x1d07cb={'SUM':_0xe2f176('0xd'),'COUNT':_0xe2f176('0x28'),'COUNT\x20DISTINCT':_0xe2f176('0x37'),'MAX':'MAX(%s)','MIN':'MIN(%s)','AVG':_0xe2f176('0x79'),'GROUP_CONCAT':_0xe2f176('0x45'),'GROUP_CONCAT\x20ASC':_0xe2f176('0x83'),'GROUP_CONCAT\x20DESC':_0xe2f176('0x82')},_0x220f36={'SEC_TO_TIME':'SEC_TO_TIME(%s)','DATE':_0xe2f176('0x40'),'HOUR':_0xe2f176('0xe'),'ROUND':'ROUND(%s)','UNIX_TIMESTAMP':'UNIX_TIMESTAMP(%s)'},_0x573aba=function(_0x1aaf1f){const _0xc8d254=_0xe2f176;return!_[_0xc8d254('0xb')]([_0xc8d254('0x44'),'IS\x20NOT\x20NULL',_0xc8d254('0x8'),_0xc8d254('0x5d')],_0x1aaf1f);},_0x1e6952=function(_0x4da676){const _0x3c5e99=_0xe2f176;if(!_0x4da676||!_0x4da676[_0x3c5e99('0x2f')]['length'])return'';let _0x152d60='(';for(let _0x2bab67=0x0;_0x2bab67<_0x4da676[_0x3c5e99('0x2f')][_0x3c5e99('0x3e')];_0x2bab67+=0x1){_0x2bab67>0x0&&(_0x152d60+='\x20'+_0x4da676[_0x3c5e99('0xa')]+'\x20'),_0x152d60+=_0x4da676['rules'][_0x2bab67][_0x3c5e99('0x54')]?_0x1e6952(_0x4da676[_0x3c5e99('0x2f')][_0x2bab67][_0x3c5e99('0x54')]):_0x4da676[_0x3c5e99('0x2f')][_0x2bab67]['field']+'\x20'+_0x4da676[_0x3c5e99('0x2f')][_0x2bab67]['condition']+(_0x573aba(_0x4da676[_0x3c5e99('0x2f')][_0x2bab67]['condition'])?'\x20'+_0x4da676['rules'][_0x2bab67][_0x3c5e99('0x3c')]:'');}return _0x152d60+')';};let _0x181248={'where':{'id':_0x1de247['id']}},_0x71cdae,_0x248803,_0x26041d,_0x563efe,_0x2c8fdc;return _0x181248=_['merge']({},_0x181248,_0x50657f),db['AnalyticDefaultReport'][_0xe2f176('0x43')](_0x181248)[_0xe2f176('0x7a')](function(_0x2d69e5){const _0xf6b775=_0xe2f176;if(_0x2d69e5)return _0x71cdae=_0x2d69e5,_0x2d69e5[_0xf6b775('0x34')]();return null;})[_0xe2f176('0x7a')](function(_0x3508a3){const _0x2ed143=_0xe2f176;if(_0x3508a3){if(!_0x3508a3[_0x2ed143('0x3e')])throw new ValidationErrorItem('Please\x20insert\x20at\x20least\x20one\x20field',0x193);return _0x248803=_0x3508a3,db['AnalyticMetric'][_0x2ed143('0x15')]({'raw':!![]});}return null;})[_0xe2f176('0x7a')](function(_0x3a997d){const _0x40aa9b=_0xe2f176;if(_0x3a997d){_0x26041d=_[_0x40aa9b('0x42')](_0x3a997d,'id');let _0x467d78;const _0x3e3469=squel[_0x40aa9b('0x77')]();_0x3e3469[_0x40aa9b('0x70')](_0x71cdae['table']);for(let _0x2eef27=0x0;_0x2eef27<_0x248803[_0x40aa9b('0x3e')];_0x2eef27+=0x1){_0x467d78=_0x248803[_0x2eef27]['MetricId']?_0x26041d[_0x248803[_0x2eef27][_0x40aa9b('0x4')]]['metric']:_0x248803[_0x2eef27][_0x40aa9b('0x20')],_0x467d78=_0x248803[_0x2eef27][_0x40aa9b('0x7d')]?_[_0x40aa9b('0x51')](_0x1d07cb[_0x248803[_0x2eef27][_0x40aa9b('0x7d')]],'%s',_0x467d78):_0x467d78,_0x467d78=_0x248803[_0x2eef27]['format']?_[_0x40aa9b('0x51')](_0x220f36[_0x248803[_0x2eef27]['format']],'%s',_0x467d78):_0x467d78,_0x248803[_0x2eef27][_0x40aa9b('0x6b')]&&_0x3e3469[_0x40aa9b('0x54')](_0x467d78),_0x248803[_0x2eef27][_0x40aa9b('0x38')]&&_0x3e3469[_0x40aa9b('0x35')](_0x467d78,_0x248803[_0x2eef27][_0x40aa9b('0x38')]===_0x40aa9b('0x84')?![]:!![]),_0x3e3469[_0x40aa9b('0x20')](_0x467d78,_0x248803[_0x2eef27]['alias']||_0x467d78);}if(_0x71cdae[_0x40aa9b('0x30')]){_0x71cdae['joins']=JSON[_0x40aa9b('0x12')](_0x71cdae[_0x40aa9b('0x30')]);for(let _0x201a3c=0x0;_0x201a3c<_0x71cdae[_0x40aa9b('0x30')][_0x40aa9b('0x3e')];_0x201a3c+=0x1){_0x71cdae[_0x40aa9b('0x30')][_0x201a3c][_0x40aa9b('0x5f')]&&_['includes'](_0x56dfb8,_0x71cdae[_0x40aa9b('0x30')][_0x201a3c][_0x40aa9b('0x5f')])&&_0x71cdae[_0x40aa9b('0x30')][_0x201a3c]['parentKey']&&_0x71cdae[_0x40aa9b('0x30')][_0x201a3c][_0x40aa9b('0x4c')]&&_0x71cdae[_0x40aa9b('0x30')][_0x201a3c][_0x40aa9b('0x22')]&&_0x3e3469[_0x71cdae[_0x40aa9b('0x30')][_0x201a3c][_0x40aa9b('0x5f')]](_0x71cdae[_0x40aa9b('0x30')][_0x201a3c][_0x40aa9b('0x4c')],null,util[_0x40aa9b('0x72')](_0x40aa9b('0x7b'),_0x71cdae[_0x40aa9b('0x24')],_0x71cdae[_0x40aa9b('0x30')][_0x201a3c]['parentKey'],_0x71cdae[_0x40aa9b('0x30')][_0x201a3c]['foreignTable'],_0x71cdae[_0x40aa9b('0x30')][_0x201a3c][_0x40aa9b('0x22')]));}}return _0x71cdae[_0x40aa9b('0x5c')]&&(_0x71cdae['conditions']=JSON[_0x40aa9b('0x12')](_0x71cdae[_0x40aa9b('0x5c')]),_0x3e3469[_0x40aa9b('0x18')](_0x1e6952(_0x71cdae[_0x40aa9b('0x5c')][_0x40aa9b('0x54')]))),_0x2c8fdc=_0x3e3469[_0x40aa9b('0x26')](),_0x3e3469['limit'](_0x1ffc57),_0x3e3469[_0x40aa9b('0x1e')](0x0),logger[_0x40aa9b('0x50')](_0x40aa9b('0x73'),_0x3e3469[_0x40aa9b('0x39')]()),db[_0x40aa9b('0x6d')][_0x40aa9b('0x78')](_0x3e3469[_0x40aa9b('0x39')](),{'type':QueryTypes[_0x40aa9b('0x87')]});}})[_0xe2f176('0x7a')](function(_0x1a2692){const _0x8f249b=_0xe2f176;if(!_0x1a2692[_0x8f249b('0x3e')])throw new ValidationErrorItem(_0x8f249b('0x29'),0xcc);if(_0x62ca93[_0x8f249b('0x21')]===_0x8f249b('0x1f'))return null;const _0x7a8bbd=_[_0x8f249b('0x52')](_0x62ca93,{'name':_0x62ca93[_0x8f249b('0x0')]||_0x62ca93[_0x8f249b('0x4d')]||_0x71cdae[_0x8f249b('0x4d')],'basename':_0x16f642,'savename':util[_0x8f249b('0x72')]('%s-%s.%s',_0x62ca93['name']||_0x71cdae[_0x8f249b('0x4d')],require(_0x8f249b('0x80'))[_0x8f249b('0x3f')](0x4),_0x62ca93[_0x8f249b('0x21')]||'csv'),'reportId':_0x71cdae['id'],'reportType':_0x8f249b('0x8a')});return db[_0x8f249b('0x56')]['create'](_0x7a8bbd,{'raw':!![]});})[_0xe2f176('0x7a')](function(_0x3f4f02){const _0x46d49c=_0xe2f176;_0x71cdae[_0x46d49c('0x24')]===_0x46d49c('0x3')?_0x2c8fdc['where'](_0x71cdae[_0x46d49c('0x24')]+_0x46d49c('0x55'),_0x62ca93['startDate'],_0x62ca93['endDate']):_0x2c8fdc[_0x46d49c('0x18')](_0x71cdae[_0x46d49c('0x24')]+'.createdAt\x20BETWEEN\x20?\x20AND\x20?',_0x62ca93[_0x46d49c('0x2a')],_0x62ca93[_0x46d49c('0x8d')]);if(_0x3f4f02)return logger[_0x46d49c('0x46')](_0x46d49c('0x86'),_0x2c8fdc[_0x46d49c('0x39')]()),require(_0x46d49c('0x53'))['fork'](path[_0x46d49c('0x1a')](__dirname,_0x46d49c('0x65'),_0x3f4f02[_0x46d49c('0x21')]),[_0x3f4f02['id'],_0x2c8fdc[_0x46d49c('0x39')](),path[_0x46d49c('0x1a')](__dirname,'../../files/reports',_0x3f4f02[_0x46d49c('0x6e')]),_0x16f642]),_0x3f4f02;else{const _0x7d9f2a=squel[_0x46d49c('0x77')]();return _0x7d9f2a['from']('('+_0x2c8fdc[_0x46d49c('0x39')]()+')',_0x46d49c('0x10')),_0x7d9f2a[_0x46d49c('0x20')](_0x46d49c('0x2b'),_0x46d49c('0x88')),_0x2c8fdc['limit'](_0x62ca93[_0x46d49c('0x2e')]||_0x1ffc57),_0x2c8fdc[_0x46d49c('0x1e')](_0x62ca93[_0x46d49c('0x1e')]||0x0),dbH[_0x46d49c('0x6d')]['query'](_0x7d9f2a[_0x46d49c('0x39')](),{'type':dbH['sequelize'][_0x46d49c('0x8b')][_0x46d49c('0x87')]})[_0x46d49c('0x7a')](function(_0x2e02ca){const _0x38640b=_0x46d49c;return!_0x2e02ca[_0x38640b('0x3e')]?_0x563efe=0x0:_0x563efe=_0x2e02ca[0x0][_0x38640b('0x88')]||0x0,dbH[_0x38640b('0x6d')][_0x38640b('0x78')](_0x2c8fdc[_0x38640b('0x39')](),{'type':dbH[_0x38640b('0x6d')]['QueryTypes'][_0x38640b('0x87')]});})['then'](function(_0x566658){return{'rows':_0x566658||[],'count':_0x563efe};});}});}exports[_0x292f61('0x5e')]=function(_0x54df91,_0x258d83){const _0x52d3fe=_0x292f61;return runReport(_0x54df91[_0x52d3fe('0x6a')],_0x54df91['query'],_0x54df91[_0x52d3fe('0x31')])[_0x52d3fe('0x7a')](respondWithResult(_0x258d83,null))[_0x52d3fe('0x61')](handleError(_0x258d83,null));},exports[_0x292f61('0x58')]=runReport,exports['query']=function(_0x186d3f,_0x2fa0d4){const _0x34e8aa=_0x292f61,_0x8df62c=0xa,_0x183da7=[_0x34e8aa('0x1a'),_0x34e8aa('0x2'),'right_join',_0x34e8aa('0xc')],_0x2be0d2={'SUM':_0x34e8aa('0xd'),'COUNT':_0x34e8aa('0x28'),'COUNT\x20DISTINCT':_0x34e8aa('0x37'),'MAX':_0x34e8aa('0x64'),'MIN':_0x34e8aa('0x4a'),'AVG':_0x34e8aa('0x79'),'GROUP_CONCAT':_0x34e8aa('0x45'),'GROUP_CONCAT\x20ASC':_0x34e8aa('0x83'),'GROUP_CONCAT\x20DESC':'GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20DESC)'},_0x1f49a7={'SEC_TO_TIME':_0x34e8aa('0x74'),'DATE':_0x34e8aa('0x40'),'HOUR':_0x34e8aa('0xe'),'ROUND':'ROUND(%s)','UNIX_TIMESTAMP':'UNIX_TIMESTAMP(%s)'},_0x560e17=function(_0x500016){const _0x3bb08d=_0x34e8aa;return!_[_0x3bb08d('0xb')]([_0x3bb08d('0x44'),_0x3bb08d('0x19'),_0x3bb08d('0x8'),_0x3bb08d('0x5d')],_0x500016);},_0x238375=function(_0xdbdb11){const _0x2b89bf=_0x34e8aa;if(!_0xdbdb11||!_0xdbdb11[_0x2b89bf('0x2f')][_0x2b89bf('0x3e')])return'';let _0x39e5ea='(';for(let _0x3b5150=0x0;_0x3b5150<_0xdbdb11[_0x2b89bf('0x2f')][_0x2b89bf('0x3e')];_0x3b5150+=0x1){_0x3b5150>0x0&&(_0x39e5ea+='\x20'+_0xdbdb11[_0x2b89bf('0xa')]+'\x20'),_0x39e5ea+=_0xdbdb11[_0x2b89bf('0x2f')][_0x3b5150]['group']?_0x238375(_0xdbdb11[_0x2b89bf('0x2f')][_0x3b5150][_0x2b89bf('0x54')]):_0xdbdb11[_0x2b89bf('0x2f')][_0x3b5150][_0x2b89bf('0x20')]+'\x20'+_0xdbdb11[_0x2b89bf('0x2f')][_0x3b5150][_0x2b89bf('0x3a')]+(_0x560e17(_0xdbdb11[_0x2b89bf('0x2f')][_0x3b5150][_0x2b89bf('0x3a')])?'\x20'+_0xdbdb11[_0x2b89bf('0x2f')][_0x3b5150][_0x2b89bf('0x3c')]:'');}return _0x39e5ea+')';};let _0x133d7b={'where':{'id':_0x186d3f['params']['id']}},_0x65d272,_0x3d7ed7,_0x125771,_0x24275f;return _0x133d7b=_['merge']({},_0x133d7b,_0x186d3f['options']),db[_0x34e8aa('0x1b')]['findOne'](_0x133d7b)[_0x34e8aa('0x7a')](function(_0x2fbf56){const _0x1a5727=_0x34e8aa;if(_0x2fbf56)return _0x65d272=_0x2fbf56,_0x2fbf56[_0x1a5727('0x34')]();return null;})['then'](function(_0x5ec370){const _0x5f48d0=_0x34e8aa;if(_0x5ec370){if(!_0x5ec370[_0x5f48d0('0x3e')])throw new ValidationErrorItem('Please\x20insert\x20at\x20least\x20one\x20field',0x193);return _0x3d7ed7=_0x5ec370,db['AnalyticMetric']['findAll']({'raw':!![]});}return null;})[_0x34e8aa('0x7a')](function(_0x1f6ec5){const _0x44417e=_0x34e8aa;if(_0x1f6ec5){_0x125771=_['keyBy'](_0x1f6ec5,'id');let _0xb1b66f;const _0x5a3806=squel[_0x44417e('0x77')]();_0x5a3806['from'](_0x65d272['table']);for(let _0x1eaa94=0x0;_0x1eaa94<_0x3d7ed7[_0x44417e('0x3e')];_0x1eaa94+=0x1){_0xb1b66f=_0x3d7ed7[_0x1eaa94][_0x44417e('0x4')]?_0x125771[_0x3d7ed7[_0x1eaa94][_0x44417e('0x4')]]['metric']:_0x3d7ed7[_0x1eaa94]['field'],_0xb1b66f=_0x3d7ed7[_0x1eaa94][_0x44417e('0x7d')]?_[_0x44417e('0x51')](_0x2be0d2[_0x3d7ed7[_0x1eaa94][_0x44417e('0x7d')]],'%s',_0xb1b66f):_0xb1b66f,_0xb1b66f=_0x3d7ed7[_0x1eaa94]['format']?_[_0x44417e('0x51')](_0x1f49a7[_0x3d7ed7[_0x1eaa94]['format']],'%s',_0xb1b66f):_0xb1b66f,_0x3d7ed7[_0x1eaa94][_0x44417e('0x6b')]&&_0x5a3806[_0x44417e('0x54')](_0xb1b66f),_0x3d7ed7[_0x1eaa94][_0x44417e('0x38')]&&_0x5a3806[_0x44417e('0x35')](_0xb1b66f,_0x3d7ed7[_0x1eaa94][_0x44417e('0x38')]===_0x44417e('0x84')?![]:!![]),_0x5a3806[_0x44417e('0x20')](_0xb1b66f,_0x3d7ed7[_0x1eaa94][_0x44417e('0x47')]||_0xb1b66f);}if(_0x65d272[_0x44417e('0x30')]){_0x65d272['joins']=JSON[_0x44417e('0x12')](_0x65d272[_0x44417e('0x30')]);for(let _0x8dbd16=0x0;_0x8dbd16<_0x65d272[_0x44417e('0x30')][_0x44417e('0x3e')];_0x8dbd16+=0x1){_0x65d272[_0x44417e('0x30')][_0x8dbd16][_0x44417e('0x5f')]&&_[_0x44417e('0xb')](_0x183da7,_0x65d272['joins'][_0x8dbd16]['type'])&&_0x65d272[_0x44417e('0x30')][_0x8dbd16][_0x44417e('0x17')]&&_0x65d272[_0x44417e('0x30')][_0x8dbd16][_0x44417e('0x4c')]&&_0x65d272[_0x44417e('0x30')][_0x8dbd16][_0x44417e('0x22')]&&_0x5a3806[_0x65d272[_0x44417e('0x30')][_0x8dbd16]['type']](_0x65d272[_0x44417e('0x30')][_0x8dbd16][_0x44417e('0x4c')],null,util[_0x44417e('0x72')](_0x44417e('0x7b'),_0x65d272[_0x44417e('0x24')],_0x65d272[_0x44417e('0x30')][_0x8dbd16][_0x44417e('0x17')],_0x65d272[_0x44417e('0x30')][_0x8dbd16][_0x44417e('0x4c')],_0x65d272[_0x44417e('0x30')][_0x8dbd16][_0x44417e('0x22')]));}}return _0x65d272[_0x44417e('0x5c')]&&(_0x65d272['conditions']=JSON['parse'](_0x65d272[_0x44417e('0x5c')]),_0x5a3806['where'](_0x238375(_0x65d272[_0x44417e('0x5c')][_0x44417e('0x54')]))),_0x24275f=_0x5a3806[_0x44417e('0x26')](),_0x5a3806[_0x44417e('0x2e')](_0x8df62c),_0x5a3806['offset'](0x0),logger[_0x44417e('0x50')](_0x44417e('0x73'),_0x5a3806[_0x44417e('0x39')]()),db[_0x44417e('0x6d')][_0x44417e('0x78')](_0x5a3806[_0x44417e('0x39')](),{'type':QueryTypes['SELECT']});}})[_0x34e8aa('0x7a')](function(){const _0x459249=_0x34e8aa;return{'sql':_0x24275f[_0x459249('0x39')]()};})[_0x34e8aa('0x7a')](respondWithResult(_0x2fa0d4,null))[_0x34e8aa('0x61')](handleError(_0x2fa0d4,null));}; \ No newline at end of file +const a9_0x34dd=['DATE(%s)','rawAttributes','sort','format','type','GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20DESC)','select','create','foreignTable','condition','offset','error','operator','fork','merge','undefined','include','show','includeAll','SEC_TO_TIME(%s)','parse','Please\x20insert\x20at\x20least\x20one\x20field','field','%s-%s.%s','rules','role','filters','table','cross_join','count','options','%s.%s\x20=\x20%s.%s','path','body','COUNT(%s)','UserProfileResource','userProfileId','Unable\x20to\x20retrieve\x20the\x20current\x20user','../../components/parsers/qs','../../config/logger','csv','MIN(%s)','foreignKey','destroy','HOUR(%s)','intersection','group','query','MetricId','get','GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20ASC)','cdr','from','metric','attributes','set','length','model','info','AVG(%s)','DESC','startDate','limit','send','debug','map','IS\x20NOT\x20EMPTY','rows','key','then','catch','randomstring','COUNT(DISTINCT\x20%s)','alias','sequelize','../../files/reports','IS\x20NOT\x20NULL','run','savename','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','replace','COUNT(*)','right_join','update','endDate','orderBy','DefaultReports','VIRTUAL','keys','left_join','stack','api','Content-Range','filter','json','join','where','AnalyticDefaultReport','clone','findAll','order','Reports','generate','function','toString','IS\x20NULL','parentKey','fieldName','output','../../components/export/','AnalyticExtractedReport','getFields','web','Limited\x20Query:','fullPath','IS\x20EMPTY','default','params','groupBy','findOne','sendStatus','conditions','joins','Run\x20Query:','fields','dbH','keyBy','QueryTypes','ROUND(%s)','util','MAX(%s)','status','name','user','value','includes','SELECT','GROUP_CONCAT(%s)','countTable','SUM(%s)'];(function(_0x2c8e9b,_0x34dd8e){const _0x161746=function(_0x3f3298){while(--_0x3f3298){_0x2c8e9b['push'](_0x2c8e9b['shift']());}};_0x161746(++_0x34dd8e);}(a9_0x34dd,0xba));const a9_0x1617=function(_0x2c8e9b,_0x34dd8e){_0x2c8e9b=_0x2c8e9b-0x0;let _0x161746=a9_0x34dd[_0x2c8e9b];return _0x161746;};const _0x59e700=a9_0x1617;'use strict';const util=require(_0x59e700('0x53')),path=require(_0x59e700('0x7e')),_=require('lodash'),squel=require('squel'),qs=require(_0x59e700('0x84')),logger=require(_0x59e700('0x85'))(_0x59e700('0x2d')),db=require('../../mysqldb')['db'],dbH=require('../../mysqldb')[_0x59e700('0x4f')],{Op,ValidationErrorItem,QueryTypes}=require(_0x59e700('0x1c'));function respondWithResult(_0x3f3298,_0x58c398){return _0x58c398=_0x58c398||0xc8,function(_0x6b7c80){const _0x291fdb=a9_0x1617;if(_0x6b7c80)return _0x3f3298[_0x291fdb('0x55')](_0x58c398)['json'](_0x6b7c80);};}function respondWithFilteredResult(_0x2152fe,_0x17fbf8){return function(_0x4f218b){const _0x4d52a6=a9_0x1617;if(_0x4f218b){const _0x4cfa72=_0x4f218b[_0x4d52a6('0x7b')],_0x56fa0b=_0x17fbf8[_0x4d52a6('0x68')];let _0xbb89fd=_0x17fbf8[_0x4d52a6('0x68')]+_0x17fbf8[_0x4d52a6('0x10')],_0x2f247f;return _0xbb89fd>=_0x4cfa72?(_0xbb89fd=_0x4cfa72,_0x2f247f=0xc8):_0x2f247f=0xce,_0x2152fe[_0x4d52a6('0x55')](_0x2f247f),_0x2152fe[_0x4d52a6('0x9')](_0x4d52a6('0x2e'),_0x56fa0b+'-'+_0xbb89fd+'/'+_0x4cfa72)[_0x4d52a6('0x30')](_0x4f218b);}return null;};}function saveUpdates(_0x6aad06){return function(_0x236485){const _0x1cfb9d=a9_0x1617;if(_0x236485)return _0x236485[_0x1cfb9d('0x25')](_0x6aad06)[_0x1cfb9d('0x17')](function(_0x5c43d1){return _0x5c43d1;});return null;};}function removeEntity(_0x1957ac){return function(_0x344957){const _0x264679=a9_0x1617;if(_0x344957)return _0x344957['destroy']()[_0x264679('0x17')](function(){const _0xb8fe3b=_0x264679,_0x2c90bc=_0x344957['get']({'plain':!![]}),_0x2a6935=_0xb8fe3b('0x28');return db[_0xb8fe3b('0x81')][_0xb8fe3b('0x89')]({'where':{'type':_0x2a6935,'resourceId':_0x2c90bc['id']}})[_0xb8fe3b('0x17')](function(){return _0x344957;});})[_0x264679('0x17')](function(){const _0x2d7198=_0x264679;_0x1957ac[_0x2d7198('0x55')](0xcc)['end']();});};}function handleEntityNotFound(_0x46a050){return function(_0x5d3c75){const _0x31aaff=a9_0x1617;return!_0x5d3c75&&_0x46a050[_0x31aaff('0x4a')](0x194),_0x5d3c75;};}function handleError(_0x5c920d,_0x3675b3){return _0x3675b3=_0x3675b3||0x1f4,function(_0x48cb28){const _0x3b80e7=a9_0x1617;logger[_0x3b80e7('0x69')](_0x48cb28[_0x3b80e7('0x2c')]),_0x48cb28[_0x3b80e7('0x56')]&&delete _0x48cb28[_0x3b80e7('0x56')],_0x5c920d[_0x3b80e7('0x55')](_0x3675b3)[_0x3b80e7('0x11')](_0x48cb28);};}exports['index']=function(_0x1c3b24,_0x5382c5){const _0x427256=_0x59e700;let _0x3305d8={};const _0x4423b5={},_0x3d96e4={'count':0x0,'rows':[]},_0x42e5cc=_[_0x427256('0x13')](db[_0x427256('0x33')][_0x427256('0x5f')],function(_0x5f5bf2){const _0x1adfc7=_0x427256;return{'name':_0x5f5bf2[_0x1adfc7('0x3d')],'type':_0x5f5bf2['type'][_0x1adfc7('0x16')]};});_0x4423b5[_0x427256('0xb')]=_[_0x427256('0x13')](_0x42e5cc,'name'),_0x4423b5['query']=_[_0x427256('0x2a')](_0x1c3b24[_0x427256('0x1')]),_0x4423b5['filters']=_[_0x427256('0x8b')](_0x4423b5[_0x427256('0xb')],_0x4423b5[_0x427256('0x1')]),_0x3305d8[_0x427256('0x8')]=_[_0x427256('0x8b')](_0x4423b5[_0x427256('0xb')],qs[_0x427256('0x4e')](_0x1c3b24[_0x427256('0x1')][_0x427256('0x4e')])),_0x3305d8[_0x427256('0x8')]=_0x3305d8[_0x427256('0x8')][_0x427256('0xa')]?_0x3305d8[_0x427256('0x8')]:_0x4423b5[_0x427256('0xb')];typeof _0x1c3b24[_0x427256('0x1')]['nolimit']===_0x427256('0x6d')&&(_0x3305d8['limit']=qs[_0x427256('0x10')](_0x1c3b24[_0x427256('0x1')][_0x427256('0x10')]),_0x3305d8[_0x427256('0x68')]=qs['offset'](_0x1c3b24[_0x427256('0x1')]['offset']));_0x3305d8['order']=qs[_0x427256('0x60')](_0x1c3b24[_0x427256('0x1')][_0x427256('0x60')]),_0x3305d8['where']=qs[_0x427256('0x78')](_['pick'](_0x1c3b24[_0x427256('0x1')],_0x4423b5['filters']),_0x42e5cc);_0x1c3b24['query']['filter']&&(_0x3305d8['where']=_[_0x427256('0x6c')](_0x3305d8[_0x427256('0x32')],{[Op['or']]:_[_0x427256('0x13')](_0x42e5cc,function(_0x501cf6){const _0x58adc7=_0x427256;if(_0x501cf6[_0x58adc7('0x62')]!==_0x58adc7('0x29')){const _0x391dab={};return _0x391dab[_0x501cf6['name']]={[Op['like']]:'%'+_0x1c3b24['query'][_0x58adc7('0x2f')]+'%'},_0x391dab;}})}));_0x3305d8=_[_0x427256('0x6c')]({},_0x3305d8,_0x1c3b24[_0x427256('0x7c')]);const _0x186781={'where':_0x3305d8[_0x427256('0x32')]};return db[_0x427256('0x33')][_0x427256('0x7b')](_0x186781)[_0x427256('0x17')](function(_0x1a173f){const _0x96ebf7=_0x427256;return _0x3d96e4[_0x96ebf7('0x7b')]=_0x1a173f,_0x1c3b24['query'][_0x96ebf7('0x70')]&&(_0x3305d8[_0x96ebf7('0x6e')]=[{'all':!![]}]),db[_0x96ebf7('0x33')][_0x96ebf7('0x35')](_0x3305d8);})['then'](function(_0x4d302f){const _0xaeabf2=_0x427256;return _0x3d96e4[_0xaeabf2('0x15')]=_0x4d302f,_0x3d96e4;})[_0x427256('0x17')](respondWithFilteredResult(_0x5382c5,_0x3305d8))['catch'](handleError(_0x5382c5,null));},exports[_0x59e700('0x6f')]=function(_0x21e16e,_0x3a517f){const _0x2e4996=_0x59e700;let _0x231a3d={'raw':!![],'where':{'id':_0x21e16e[_0x2e4996('0x47')]['id']}};const _0xd7477a={};return _0xd7477a[_0x2e4996('0xb')]=_[_0x2e4996('0x2a')](db[_0x2e4996('0x33')][_0x2e4996('0x5f')]),_0xd7477a[_0x2e4996('0x1')]=_['keys'](_0x21e16e[_0x2e4996('0x1')]),_0xd7477a[_0x2e4996('0x78')]=_[_0x2e4996('0x8b')](_0xd7477a[_0x2e4996('0xb')],_0xd7477a[_0x2e4996('0x1')]),_0x231a3d['attributes']=_[_0x2e4996('0x8b')](_0xd7477a[_0x2e4996('0xb')],qs[_0x2e4996('0x4e')](_0x21e16e[_0x2e4996('0x1')][_0x2e4996('0x4e')])),_0x231a3d[_0x2e4996('0x8')]=_0x231a3d[_0x2e4996('0x8')][_0x2e4996('0xa')]?_0x231a3d[_0x2e4996('0x8')]:_0xd7477a['model'],_0x21e16e[_0x2e4996('0x1')][_0x2e4996('0x70')]&&(_0x231a3d[_0x2e4996('0x6e')]=[{'all':!![]}]),_0x231a3d=_[_0x2e4996('0x6c')]({},_0x231a3d,_0x21e16e[_0x2e4996('0x7c')]),db['AnalyticDefaultReport'][_0x2e4996('0x49')](_0x231a3d)[_0x2e4996('0x17')](handleEntityNotFound(_0x3a517f,null))['then'](respondWithResult(_0x3a517f,null))['catch'](handleError(_0x3a517f,null));},exports['create']=function(_0x488b2e,_0x572b45){const _0x4a0e46=_0x59e700;return db[_0x4a0e46('0x33')][_0x4a0e46('0x65')](_0x488b2e[_0x4a0e46('0x7f')],{})[_0x4a0e46('0x17')](function(_0x6752f8){const _0x2845ba=_0x4a0e46,_0x3899ed=_0x488b2e[_0x2845ba('0x57')][_0x2845ba('0x3')]({'plain':!![]});if(!_0x3899ed)throw new Error(_0x2845ba('0x83'));if(_0x3899ed[_0x2845ba('0x77')]===_0x2845ba('0x57')){const _0x7a19a=_0x6752f8['get']({'plain':!![]}),_0x21a10e=_0x2845ba('0x37');return db['UserProfileSection'][_0x2845ba('0x49')]({'where':{'name':_0x21a10e,'userProfileId':_0x3899ed[_0x2845ba('0x82')]},'raw':!![]})[_0x2845ba('0x17')](function(_0xe07446){const _0x3e9f13=_0x2845ba;return _0xe07446&&_0xe07446['autoAssociation']===0x0?db[_0x3e9f13('0x81')][_0x3e9f13('0x65')]({'name':_0x7a19a[_0x3e9f13('0x56')],'resourceId':_0x7a19a['id'],'type':_0x3e9f13('0x28'),'sectionId':_0xe07446['id']},{})['then'](function(){return _0x6752f8;}):_0x6752f8;})[_0x2845ba('0x18')](function(_0x1da169){const _0x4e2fa2=_0x2845ba;logger[_0x4e2fa2('0x69')](_0x4e2fa2('0x21'),_0x1da169);throw _0x1da169;});}return _0x6752f8;})['then'](respondWithResult(_0x572b45,0xc9))['catch'](handleError(_0x572b45,null));},exports[_0x59e700('0x25')]=function(_0xb5036f,_0x1fbcd8){const _0x15f1e9=_0x59e700;return _0xb5036f[_0x15f1e9('0x7f')]['id']&&delete _0xb5036f[_0x15f1e9('0x7f')]['id'],db[_0x15f1e9('0x33')][_0x15f1e9('0x49')]({'where':{'id':_0xb5036f['params']['id']}})['then'](handleEntityNotFound(_0x1fbcd8,null))['then'](saveUpdates(_0xb5036f[_0x15f1e9('0x7f')],null))[_0x15f1e9('0x17')](respondWithResult(_0x1fbcd8,null))['catch'](handleError(_0x1fbcd8,null));},exports[_0x59e700('0x89')]=function(_0x40d01b,_0xb848e6){const _0x30cf27=_0x59e700;return db[_0x30cf27('0x33')][_0x30cf27('0x49')]({'where':{'id':_0x40d01b[_0x30cf27('0x47')]['id']}})[_0x30cf27('0x17')](handleEntityNotFound(_0xb848e6,null))[_0x30cf27('0x17')](removeEntity(_0xb848e6,null))[_0x30cf27('0x18')](handleError(_0xb848e6,null));},exports['preview']=function(_0x2d6817,_0x316b05){const _0xf11b95=_0x59e700,_0x562ab0=0xa,_0x4ec28f=['join',_0xf11b95('0x2b'),_0xf11b95('0x24'),_0xf11b95('0x7a')],_0x236009={'SUM':_0xf11b95('0x5d'),'COUNT':_0xf11b95('0x80'),'COUNT\x20DISTINCT':_0xf11b95('0x1a'),'MAX':_0xf11b95('0x54'),'MIN':_0xf11b95('0x87'),'AVG':_0xf11b95('0xd'),'GROUP_CONCAT':'GROUP_CONCAT(%s)','GROUP_CONCAT\x20ASC':_0xf11b95('0x4'),'GROUP_CONCAT\x20DESC':'GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20DESC)'},_0x4b3410={'SEC_TO_TIME':_0xf11b95('0x71'),'DATE':_0xf11b95('0x5e'),'HOUR':_0xf11b95('0x8a'),'ROUND':_0xf11b95('0x52'),'UNIX_TIMESTAMP':'UNIX_TIMESTAMP(%s)'},_0xf1ecb3=function(_0x5719b0){const _0x53df89=_0xf11b95;return!_['includes'](['IS\x20NULL',_0x53df89('0x1e'),_0x53df89('0x45'),_0x53df89('0x14')],_0x5719b0);},_0x4bc05a=function(_0x53cdaf){const _0x1c262c=_0xf11b95;if(!_0x53cdaf||!_0x53cdaf[_0x1c262c('0x76')][_0x1c262c('0xa')])return'';let _0x7e77bf='(';for(let _0x2df999=0x0;_0x2df999<_0x53cdaf['rules'][_0x1c262c('0xa')];_0x2df999+=0x1){_0x2df999>0x0&&(_0x7e77bf+='\x20'+_0x53cdaf[_0x1c262c('0x6a')]+'\x20'),_0x7e77bf+=_0x53cdaf[_0x1c262c('0x76')][_0x2df999][_0x1c262c('0x0')]?_0x4bc05a(_0x53cdaf[_0x1c262c('0x76')][_0x2df999][_0x1c262c('0x0')]):_0x53cdaf[_0x1c262c('0x76')][_0x2df999][_0x1c262c('0x74')]+'\x20'+_0x53cdaf[_0x1c262c('0x76')][_0x2df999][_0x1c262c('0x67')]+(_0xf1ecb3(_0x53cdaf[_0x1c262c('0x76')][_0x2df999]['condition'])?'\x20'+_0x53cdaf['rules'][_0x2df999][_0x1c262c('0x58')]:'');}return _0x7e77bf+')';};let _0x462f63={'where':{'id':_0x2d6817[_0xf11b95('0x47')]['id']}},_0x1816ba,_0x3f4a05,_0x3bdb2f;return _0x462f63=_[_0xf11b95('0x6c')]({},_0x462f63,_0x2d6817[_0xf11b95('0x7c')]),db[_0xf11b95('0x33')][_0xf11b95('0x49')](_0x462f63)[_0xf11b95('0x17')](function(_0x1fe1c3){const _0x37ee69=_0xf11b95;if(_0x1fe1c3)return _0x1816ba=_0x1fe1c3,_0x1fe1c3[_0x37ee69('0x41')]();return null;})[_0xf11b95('0x17')](function(_0x1b7427){const _0x3d852d=_0xf11b95;if(_0x1b7427){if(!_0x1b7427[_0x3d852d('0xa')])throw new ValidationErrorItem('Please\x20insert\x20at\x20least\x20one\x20field',0x193);return _0x3f4a05=_0x1b7427,db['AnalyticMetric'][_0x3d852d('0x35')]({'raw':!![]});}return null;})['then'](function(_0x317a3b){const _0x43ead7=_0xf11b95;if(_0x317a3b){_0x3bdb2f=_[_0x43ead7('0x50')](_0x317a3b,'id');let _0xb309f9;const _0x1ecb97=squel['select']();_0x1ecb97[_0x43ead7('0x6')](_0x1816ba[_0x43ead7('0x79')]);for(let _0x30a835=0x0;_0x30a835<_0x3f4a05[_0x43ead7('0xa')];_0x30a835+=0x1){_0xb309f9=_0x3f4a05[_0x30a835][_0x43ead7('0x2')]?_0x3bdb2f[_0x3f4a05[_0x30a835][_0x43ead7('0x2')]][_0x43ead7('0x7')]:_0x3f4a05[_0x30a835][_0x43ead7('0x74')],_0xb309f9=_0x3f4a05[_0x30a835]['function']?_[_0x43ead7('0x22')](_0x236009[_0x3f4a05[_0x30a835]['function']],'%s',_0xb309f9):_0xb309f9,_0xb309f9=_0x3f4a05[_0x30a835]['format']?_[_0x43ead7('0x22')](_0x4b3410[_0x3f4a05[_0x30a835][_0x43ead7('0x61')]],'%s',_0xb309f9):_0xb309f9,_0x3f4a05[_0x30a835][_0x43ead7('0x48')]&&_0x1ecb97[_0x43ead7('0x0')](_0xb309f9),_0x3f4a05[_0x30a835][_0x43ead7('0x27')]&&_0x1ecb97[_0x43ead7('0x36')](_0xb309f9,_0x3f4a05[_0x30a835][_0x43ead7('0x27')]==='DESC'?![]:!![]),_0x1ecb97[_0x43ead7('0x74')](_0xb309f9,_0x3f4a05[_0x30a835][_0x43ead7('0x1b')]||_0xb309f9);}if(_0x1816ba[_0x43ead7('0x4c')]){_0x1816ba['joins']=JSON[_0x43ead7('0x72')](_0x1816ba[_0x43ead7('0x4c')]);for(let _0x2969c5=0x0;_0x2969c5<_0x1816ba[_0x43ead7('0x4c')][_0x43ead7('0xa')];_0x2969c5+=0x1){_0x1816ba[_0x43ead7('0x4c')][_0x2969c5]['type']&&_[_0x43ead7('0x59')](_0x4ec28f,_0x1816ba['joins'][_0x2969c5][_0x43ead7('0x62')])&&_0x1816ba[_0x43ead7('0x4c')][_0x2969c5][_0x43ead7('0x3c')]&&_0x1816ba[_0x43ead7('0x4c')][_0x2969c5]['foreignTable']&&_0x1816ba['joins'][_0x2969c5][_0x43ead7('0x88')]&&_0x1ecb97[_0x1816ba[_0x43ead7('0x4c')][_0x2969c5][_0x43ead7('0x62')]](_0x1816ba[_0x43ead7('0x4c')][_0x2969c5]['foreignTable'],null,util[_0x43ead7('0x61')](_0x43ead7('0x7d'),_0x1816ba[_0x43ead7('0x79')],_0x1816ba[_0x43ead7('0x4c')][_0x2969c5][_0x43ead7('0x3c')],_0x1816ba[_0x43ead7('0x4c')][_0x2969c5]['foreignTable'],_0x1816ba[_0x43ead7('0x4c')][_0x2969c5][_0x43ead7('0x88')]));}}return _0x1816ba[_0x43ead7('0x4b')]&&(_0x1816ba[_0x43ead7('0x4b')]=JSON[_0x43ead7('0x72')](_0x1816ba[_0x43ead7('0x4b')]),_0x1ecb97[_0x43ead7('0x32')](_0x4bc05a(_0x1816ba[_0x43ead7('0x4b')][_0x43ead7('0x0')]))),_0x1ecb97['limit'](_0x562ab0),_0x1ecb97[_0x43ead7('0x68')](0x0),logger[_0x43ead7('0x12')](_0x43ead7('0x43'),_0x1ecb97['toString']()),db[_0x43ead7('0x1c')][_0x43ead7('0x1')](_0x1ecb97[_0x43ead7('0x3a')](),{'type':QueryTypes[_0x43ead7('0x5a')]});}})['then'](respondWithResult(_0x316b05,null))[_0xf11b95('0x18')](handleError(_0x316b05,null));};function runReport(_0x17ce37,_0x4c5ad2,_0x3fe398){const _0x570eb4=_0x59e700,_0x16f424=_0x4c5ad2['name'],_0x4c385b=0xa,_0x5ad830=[_0x570eb4('0x31'),'left_join','right_join','cross_join'],_0x226957={'SUM':_0x570eb4('0x5d'),'COUNT':_0x570eb4('0x80'),'COUNT\x20DISTINCT':_0x570eb4('0x1a'),'MAX':_0x570eb4('0x54'),'MIN':_0x570eb4('0x87'),'AVG':_0x570eb4('0xd'),'GROUP_CONCAT':_0x570eb4('0x5b'),'GROUP_CONCAT\x20ASC':'GROUP_CONCAT(%s\x20ORDER\x20BY\x20%s\x20ASC)','GROUP_CONCAT\x20DESC':_0x570eb4('0x63')},_0x5e94b4={'SEC_TO_TIME':_0x570eb4('0x71'),'DATE':_0x570eb4('0x5e'),'HOUR':_0x570eb4('0x8a'),'ROUND':_0x570eb4('0x52'),'UNIX_TIMESTAMP':'UNIX_TIMESTAMP(%s)'},_0x59887c=function(_0x1483a2){const _0x2b0a5e=_0x570eb4;return!_[_0x2b0a5e('0x59')]([_0x2b0a5e('0x3b'),_0x2b0a5e('0x1e'),_0x2b0a5e('0x45'),_0x2b0a5e('0x14')],_0x1483a2);},_0x195e22=function(_0x38c107){const _0x5a45f6=_0x570eb4;if(!_0x38c107||!_0x38c107[_0x5a45f6('0x76')][_0x5a45f6('0xa')])return'';let _0x1be229='(';for(let _0x504274=0x0;_0x504274<_0x38c107[_0x5a45f6('0x76')][_0x5a45f6('0xa')];_0x504274+=0x1){_0x504274>0x0&&(_0x1be229+='\x20'+_0x38c107[_0x5a45f6('0x6a')]+'\x20'),_0x1be229+=_0x38c107[_0x5a45f6('0x76')][_0x504274]['group']?_0x195e22(_0x38c107[_0x5a45f6('0x76')][_0x504274]['group']):_0x38c107[_0x5a45f6('0x76')][_0x504274][_0x5a45f6('0x74')]+'\x20'+_0x38c107[_0x5a45f6('0x76')][_0x504274][_0x5a45f6('0x67')]+(_0x59887c(_0x38c107['rules'][_0x504274]['condition'])?'\x20'+_0x38c107[_0x5a45f6('0x76')][_0x504274][_0x5a45f6('0x58')]:'');}return _0x1be229+')';};let _0x17a2c0={'where':{'id':_0x17ce37['id']}},_0x4e00e9,_0x3ee63c,_0x4bfbdb,_0x4cc1d0,_0x2440ef;return _0x17a2c0=_[_0x570eb4('0x6c')]({},_0x17a2c0,_0x3fe398),db[_0x570eb4('0x33')][_0x570eb4('0x49')](_0x17a2c0)[_0x570eb4('0x17')](function(_0x130791){if(_0x130791)return _0x4e00e9=_0x130791,_0x130791['getFields']();return null;})['then'](function(_0x476657){const _0x580d4b=_0x570eb4;if(_0x476657){if(!_0x476657[_0x580d4b('0xa')])throw new ValidationErrorItem(_0x580d4b('0x73'),0x193);return _0x3ee63c=_0x476657,db['AnalyticMetric'][_0x580d4b('0x35')]({'raw':!![]});}return null;})[_0x570eb4('0x17')](function(_0x399ce5){const _0x36c531=_0x570eb4;if(_0x399ce5){_0x4bfbdb=_['keyBy'](_0x399ce5,'id');let _0x44cec4;const _0x45ab11=squel[_0x36c531('0x64')]();_0x45ab11[_0x36c531('0x6')](_0x4e00e9[_0x36c531('0x79')]);for(let _0x31efe4=0x0;_0x31efe4<_0x3ee63c[_0x36c531('0xa')];_0x31efe4+=0x1){_0x44cec4=_0x3ee63c[_0x31efe4]['MetricId']?_0x4bfbdb[_0x3ee63c[_0x31efe4][_0x36c531('0x2')]][_0x36c531('0x7')]:_0x3ee63c[_0x31efe4]['field'],_0x44cec4=_0x3ee63c[_0x31efe4][_0x36c531('0x39')]?_[_0x36c531('0x22')](_0x226957[_0x3ee63c[_0x31efe4][_0x36c531('0x39')]],'%s',_0x44cec4):_0x44cec4,_0x44cec4=_0x3ee63c[_0x31efe4][_0x36c531('0x61')]?_[_0x36c531('0x22')](_0x5e94b4[_0x3ee63c[_0x31efe4][_0x36c531('0x61')]],'%s',_0x44cec4):_0x44cec4,_0x3ee63c[_0x31efe4]['groupBy']&&_0x45ab11[_0x36c531('0x0')](_0x44cec4),_0x3ee63c[_0x31efe4][_0x36c531('0x27')]&&_0x45ab11['order'](_0x44cec4,_0x3ee63c[_0x31efe4]['orderBy']===_0x36c531('0xe')?![]:!![]),_0x45ab11['field'](_0x44cec4,_0x3ee63c[_0x31efe4][_0x36c531('0x1b')]||_0x44cec4);}if(_0x4e00e9['joins']){_0x4e00e9[_0x36c531('0x4c')]=JSON[_0x36c531('0x72')](_0x4e00e9[_0x36c531('0x4c')]);for(let _0x28a738=0x0;_0x28a738<_0x4e00e9['joins'][_0x36c531('0xa')];_0x28a738+=0x1){_0x4e00e9['joins'][_0x28a738]['type']&&_[_0x36c531('0x59')](_0x5ad830,_0x4e00e9[_0x36c531('0x4c')][_0x28a738]['type'])&&_0x4e00e9[_0x36c531('0x4c')][_0x28a738][_0x36c531('0x3c')]&&_0x4e00e9[_0x36c531('0x4c')][_0x28a738][_0x36c531('0x66')]&&_0x4e00e9[_0x36c531('0x4c')][_0x28a738][_0x36c531('0x88')]&&_0x45ab11[_0x4e00e9['joins'][_0x28a738][_0x36c531('0x62')]](_0x4e00e9[_0x36c531('0x4c')][_0x28a738][_0x36c531('0x66')],null,util[_0x36c531('0x61')](_0x36c531('0x7d'),_0x4e00e9[_0x36c531('0x79')],_0x4e00e9[_0x36c531('0x4c')][_0x28a738][_0x36c531('0x3c')],_0x4e00e9['joins'][_0x28a738][_0x36c531('0x66')],_0x4e00e9['joins'][_0x28a738]['foreignKey']));}}return _0x4e00e9[_0x36c531('0x4b')]&&(_0x4e00e9[_0x36c531('0x4b')]=JSON[_0x36c531('0x72')](_0x4e00e9[_0x36c531('0x4b')]),_0x45ab11[_0x36c531('0x32')](_0x195e22(_0x4e00e9[_0x36c531('0x4b')][_0x36c531('0x0')]))),_0x2440ef=_0x45ab11['clone'](),_0x45ab11[_0x36c531('0x10')](_0x4c385b),_0x45ab11[_0x36c531('0x68')](0x0),logger[_0x36c531('0x12')](_0x36c531('0x43'),_0x45ab11[_0x36c531('0x3a')]()),db['sequelize'][_0x36c531('0x1')](_0x45ab11[_0x36c531('0x3a')](),{'type':QueryTypes['SELECT']});}})['then'](function(_0x3b8513){const _0x58d2bd=_0x570eb4;if(!_0x3b8513[_0x58d2bd('0xa')])throw new ValidationErrorItem('No\x20available\x20data',0xcc);if(_0x4c5ad2[_0x58d2bd('0x3e')]===_0x58d2bd('0x42'))return null;const _0x3a353b=_[_0x58d2bd('0x6c')](_0x4c5ad2,{'name':_0x4c5ad2[_0x58d2bd('0x44')]||_0x4c5ad2['name']||_0x4e00e9[_0x58d2bd('0x56')],'basename':_0x16f424,'savename':util[_0x58d2bd('0x61')](_0x58d2bd('0x75'),_0x4c5ad2['name']||_0x4e00e9['name'],require(_0x58d2bd('0x19'))[_0x58d2bd('0x38')](0x4),_0x4c5ad2['output']||_0x58d2bd('0x86')),'reportId':_0x4e00e9['id'],'reportType':_0x58d2bd('0x46')});return db[_0x58d2bd('0x40')][_0x58d2bd('0x65')](_0x3a353b,{'raw':!![]});})['then'](function(_0x1d6670){const _0x23e021=_0x570eb4;_0x4e00e9[_0x23e021('0x79')]===_0x23e021('0x5')?_0x2440ef[_0x23e021('0x32')](_0x4e00e9[_0x23e021('0x79')]+'.calldate\x20BETWEEN\x20?\x20AND\x20?',_0x4c5ad2['startDate'],_0x4c5ad2[_0x23e021('0x26')]):_0x2440ef[_0x23e021('0x32')](_0x4e00e9[_0x23e021('0x79')]+'.createdAt\x20BETWEEN\x20?\x20AND\x20?',_0x4c5ad2[_0x23e021('0xf')],_0x4c5ad2[_0x23e021('0x26')]);if(_0x1d6670)return logger[_0x23e021('0xc')](_0x23e021('0x4d'),_0x2440ef['toString']()),require('child_process')[_0x23e021('0x6b')](path[_0x23e021('0x31')](__dirname,_0x23e021('0x3f'),_0x1d6670[_0x23e021('0x3e')]),[_0x1d6670['id'],_0x2440ef[_0x23e021('0x3a')](),path[_0x23e021('0x31')](__dirname,_0x23e021('0x1d'),_0x1d6670[_0x23e021('0x20')]),_0x16f424]),_0x1d6670;else{const _0xf73f8=squel[_0x23e021('0x64')]();return _0xf73f8[_0x23e021('0x6')]('('+_0x2440ef[_0x23e021('0x3a')]()+')',_0x23e021('0x5c')),_0xf73f8[_0x23e021('0x74')](_0x23e021('0x23'),_0x23e021('0x7b')),_0x2440ef[_0x23e021('0x10')](_0x4c5ad2[_0x23e021('0x10')]||_0x4c385b),_0x2440ef['offset'](_0x4c5ad2['offset']||0x0),dbH[_0x23e021('0x1c')][_0x23e021('0x1')](_0xf73f8[_0x23e021('0x3a')](),{'type':dbH[_0x23e021('0x1c')][_0x23e021('0x51')][_0x23e021('0x5a')]})['then'](function(_0x2c8020){const _0x367869=_0x23e021;return!_0x2c8020['length']?_0x4cc1d0=0x0:_0x4cc1d0=_0x2c8020[0x0][_0x367869('0x7b')]||0x0,dbH[_0x367869('0x1c')][_0x367869('0x1')](_0x2440ef[_0x367869('0x3a')](),{'type':dbH[_0x367869('0x1c')][_0x367869('0x51')][_0x367869('0x5a')]});})[_0x23e021('0x17')](function(_0x4fb2a5){return{'rows':_0x4fb2a5||[],'count':_0x4cc1d0};});}});}exports[_0x59e700('0x1f')]=function(_0x2070f5,_0x1afbc6){const _0x47a7ed=_0x59e700;return runReport(_0x2070f5[_0x47a7ed('0x47')],_0x2070f5[_0x47a7ed('0x1')],_0x2070f5[_0x47a7ed('0x7c')])[_0x47a7ed('0x17')](respondWithResult(_0x1afbc6,null))[_0x47a7ed('0x18')](handleError(_0x1afbc6,null));},exports['runReport']=runReport,exports['query']=function(_0x39d439,_0x15060f){const _0x173c24=_0x59e700,_0x96f6ef=0xa,_0xc3f1e4=['join',_0x173c24('0x2b'),_0x173c24('0x24'),'cross_join'],_0x3d9559={'SUM':_0x173c24('0x5d'),'COUNT':_0x173c24('0x80'),'COUNT\x20DISTINCT':_0x173c24('0x1a'),'MAX':_0x173c24('0x54'),'MIN':_0x173c24('0x87'),'AVG':_0x173c24('0xd'),'GROUP_CONCAT':_0x173c24('0x5b'),'GROUP_CONCAT\x20ASC':_0x173c24('0x4'),'GROUP_CONCAT\x20DESC':_0x173c24('0x63')},_0x4ae6a7={'SEC_TO_TIME':_0x173c24('0x71'),'DATE':_0x173c24('0x5e'),'HOUR':'HOUR(%s)','ROUND':_0x173c24('0x52'),'UNIX_TIMESTAMP':'UNIX_TIMESTAMP(%s)'},_0x4a4bcd=function(_0x1f7392){const _0x1fe637=_0x173c24;return!_[_0x1fe637('0x59')]([_0x1fe637('0x3b'),_0x1fe637('0x1e'),'IS\x20EMPTY',_0x1fe637('0x14')],_0x1f7392);},_0x58270b=function(_0x4c1e32){const _0x103dac=_0x173c24;if(!_0x4c1e32||!_0x4c1e32[_0x103dac('0x76')][_0x103dac('0xa')])return'';let _0x47b4d9='(';for(let _0x53feff=0x0;_0x53feff<_0x4c1e32[_0x103dac('0x76')][_0x103dac('0xa')];_0x53feff+=0x1){_0x53feff>0x0&&(_0x47b4d9+='\x20'+_0x4c1e32[_0x103dac('0x6a')]+'\x20'),_0x47b4d9+=_0x4c1e32[_0x103dac('0x76')][_0x53feff][_0x103dac('0x0')]?_0x58270b(_0x4c1e32[_0x103dac('0x76')][_0x53feff][_0x103dac('0x0')]):_0x4c1e32[_0x103dac('0x76')][_0x53feff]['field']+'\x20'+_0x4c1e32[_0x103dac('0x76')][_0x53feff][_0x103dac('0x67')]+(_0x4a4bcd(_0x4c1e32[_0x103dac('0x76')][_0x53feff][_0x103dac('0x67')])?'\x20'+_0x4c1e32[_0x103dac('0x76')][_0x53feff][_0x103dac('0x58')]:'');}return _0x47b4d9+')';};let _0x436566={'where':{'id':_0x39d439[_0x173c24('0x47')]['id']}},_0x2df5af,_0x3b81f6,_0x28e469,_0x1a29f3;return _0x436566=_[_0x173c24('0x6c')]({},_0x436566,_0x39d439[_0x173c24('0x7c')]),db[_0x173c24('0x33')][_0x173c24('0x49')](_0x436566)[_0x173c24('0x17')](function(_0x4b6214){const _0x4aa544=_0x173c24;if(_0x4b6214)return _0x2df5af=_0x4b6214,_0x4b6214[_0x4aa544('0x41')]();return null;})[_0x173c24('0x17')](function(_0x398278){const _0x8fd7c9=_0x173c24;if(_0x398278){if(!_0x398278[_0x8fd7c9('0xa')])throw new ValidationErrorItem('Please\x20insert\x20at\x20least\x20one\x20field',0x193);return _0x3b81f6=_0x398278,db['AnalyticMetric']['findAll']({'raw':!![]});}return null;})[_0x173c24('0x17')](function(_0x1829dc){const _0x435dd6=_0x173c24;if(_0x1829dc){_0x28e469=_[_0x435dd6('0x50')](_0x1829dc,'id');let _0x17d34c;const _0xa7a256=squel[_0x435dd6('0x64')]();_0xa7a256['from'](_0x2df5af[_0x435dd6('0x79')]);for(let _0x4b3f95=0x0;_0x4b3f95<_0x3b81f6['length'];_0x4b3f95+=0x1){_0x17d34c=_0x3b81f6[_0x4b3f95][_0x435dd6('0x2')]?_0x28e469[_0x3b81f6[_0x4b3f95]['MetricId']]['metric']:_0x3b81f6[_0x4b3f95]['field'],_0x17d34c=_0x3b81f6[_0x4b3f95][_0x435dd6('0x39')]?_['replace'](_0x3d9559[_0x3b81f6[_0x4b3f95]['function']],'%s',_0x17d34c):_0x17d34c,_0x17d34c=_0x3b81f6[_0x4b3f95][_0x435dd6('0x61')]?_[_0x435dd6('0x22')](_0x4ae6a7[_0x3b81f6[_0x4b3f95][_0x435dd6('0x61')]],'%s',_0x17d34c):_0x17d34c,_0x3b81f6[_0x4b3f95][_0x435dd6('0x48')]&&_0xa7a256[_0x435dd6('0x0')](_0x17d34c),_0x3b81f6[_0x4b3f95][_0x435dd6('0x27')]&&_0xa7a256['order'](_0x17d34c,_0x3b81f6[_0x4b3f95][_0x435dd6('0x27')]==='DESC'?![]:!![]),_0xa7a256['field'](_0x17d34c,_0x3b81f6[_0x4b3f95][_0x435dd6('0x1b')]||_0x17d34c);}if(_0x2df5af[_0x435dd6('0x4c')]){_0x2df5af[_0x435dd6('0x4c')]=JSON[_0x435dd6('0x72')](_0x2df5af[_0x435dd6('0x4c')]);for(let _0x3ade6d=0x0;_0x3ade6d<_0x2df5af[_0x435dd6('0x4c')][_0x435dd6('0xa')];_0x3ade6d+=0x1){_0x2df5af['joins'][_0x3ade6d][_0x435dd6('0x62')]&&_[_0x435dd6('0x59')](_0xc3f1e4,_0x2df5af[_0x435dd6('0x4c')][_0x3ade6d][_0x435dd6('0x62')])&&_0x2df5af['joins'][_0x3ade6d][_0x435dd6('0x3c')]&&_0x2df5af[_0x435dd6('0x4c')][_0x3ade6d][_0x435dd6('0x66')]&&_0x2df5af[_0x435dd6('0x4c')][_0x3ade6d]['foreignKey']&&_0xa7a256[_0x2df5af['joins'][_0x3ade6d][_0x435dd6('0x62')]](_0x2df5af[_0x435dd6('0x4c')][_0x3ade6d][_0x435dd6('0x66')],null,util[_0x435dd6('0x61')]('%s.%s\x20=\x20%s.%s',_0x2df5af[_0x435dd6('0x79')],_0x2df5af[_0x435dd6('0x4c')][_0x3ade6d]['parentKey'],_0x2df5af[_0x435dd6('0x4c')][_0x3ade6d][_0x435dd6('0x66')],_0x2df5af[_0x435dd6('0x4c')][_0x3ade6d]['foreignKey']));}}return _0x2df5af[_0x435dd6('0x4b')]&&(_0x2df5af[_0x435dd6('0x4b')]=JSON['parse'](_0x2df5af['conditions']),_0xa7a256[_0x435dd6('0x32')](_0x58270b(_0x2df5af[_0x435dd6('0x4b')][_0x435dd6('0x0')]))),_0x1a29f3=_0xa7a256[_0x435dd6('0x34')](),_0xa7a256['limit'](_0x96f6ef),_0xa7a256[_0x435dd6('0x68')](0x0),logger[_0x435dd6('0x12')]('Limited\x20Query:',_0xa7a256[_0x435dd6('0x3a')]()),db[_0x435dd6('0x1c')][_0x435dd6('0x1')](_0xa7a256['toString'](),{'type':QueryTypes[_0x435dd6('0x5a')]});}})[_0x173c24('0x17')](function(){return{'sql':_0x1a29f3['toString']()};})[_0x173c24('0x17')](respondWithResult(_0x15060f,null))[_0x173c24('0x18')](handleError(_0x15060f,null));}; \ No newline at end of file diff --git a/server/api/analyticDefaultReport/analyticDefaultReport.model.js b/server/api/analyticDefaultReport/analyticDefaultReport.model.js index d075e1f..a44a5b2 100644 --- a/server/api/analyticDefaultReport/analyticDefaultReport.model.js +++ b/server/api/analyticDefaultReport/analyticDefaultReport.model.js @@ -1 +1 @@ -const a10_0x32b0=['analytics_default_reports','./analyticDefaultReport.attributes','define','exports','AnalyticDefaultReport'];(function(_0x4878f7,_0x32b0c3){const _0x40cb10=function(_0x2b3d24){while(--_0x2b3d24){_0x4878f7['push'](_0x4878f7['shift']());}};_0x40cb10(++_0x32b0c3);}(a10_0x32b0,0x199));const a10_0x40cb=function(_0x4878f7,_0x32b0c3){_0x4878f7=_0x4878f7-0x0;let _0x40cb10=a10_0x32b0[_0x4878f7];return _0x40cb10;};const _0x2287a5=a10_0x40cb;'use strict';const attributes=require(_0x2287a5('0x2'));module[_0x2287a5('0x4')]=function(_0x2b3d24){const _0x26e58c=_0x2287a5,_0xce77ca=_0x2b3d24[_0x26e58c('0x3')](_0x26e58c('0x0'),attributes,{'tableName':_0x26e58c('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xce77ca;}; \ No newline at end of file +const a10_0x4be6=['./analyticDefaultReport.attributes','AnalyticDefaultReport','define','analytics_default_reports','exports'];(function(_0x4d964e,_0x4be617){const _0x4bcb2d=function(_0x1402e0){while(--_0x1402e0){_0x4d964e['push'](_0x4d964e['shift']());}};_0x4bcb2d(++_0x4be617);}(a10_0x4be6,0xc4));const a10_0x4bcb=function(_0x4d964e,_0x4be617){_0x4d964e=_0x4d964e-0x0;let _0x4bcb2d=a10_0x4be6[_0x4d964e];return _0x4bcb2d;};const _0x556b14=a10_0x4bcb;'use strict';const attributes=require(_0x556b14('0x4'));module[_0x556b14('0x3')]=function(_0x1402e0){const _0x3953b9=_0x556b14,_0x127357=_0x1402e0[_0x3953b9('0x1')](_0x3953b9('0x0'),attributes,{'tableName':_0x3953b9('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x127357;}; \ No newline at end of file diff --git a/server/api/analyticDefaultReport/index.js b/server/api/analyticDefaultReport/index.js index e2717f6..a6fdbc7 100644 --- a/server/api/analyticDefaultReport/index.js +++ b/server/api/analyticDefaultReport/index.js @@ -1 +1 @@ -const a11_0x434e=['exports','show','post','express','query','isAuthenticated','delete','/:id','preview','get','./analyticDefaultReport.controller','/:id/query','put','run','../../components/auth/service','/:id/preview','update','create'];(function(_0x2d83c1,_0x434ed2){const _0x5778ec=function(_0x35939d){while(--_0x35939d){_0x2d83c1['push'](_0x2d83c1['shift']());}};_0x5778ec(++_0x434ed2);}(a11_0x434e,0x15b));const a11_0x5778=function(_0x2d83c1,_0x434ed2){_0x2d83c1=_0x2d83c1-0x0;let _0x5778ec=a11_0x434e[_0x2d83c1];return _0x5778ec;};const _0x21cb25=a11_0x5778;'use strict';const express=require(_0x21cb25('0x10')),router=express['Router'](),auth=require(_0x21cb25('0x9')),controller=require(_0x21cb25('0x5'));router[_0x21cb25('0x4')]('/',auth[_0x21cb25('0x0')](),controller['index']),router[_0x21cb25('0x4')](_0x21cb25('0x2'),auth['isAuthenticated'](),controller[_0x21cb25('0xe')]),router[_0x21cb25('0x4')](_0x21cb25('0xa'),auth['isAuthenticated'](),controller[_0x21cb25('0x3')]),router[_0x21cb25('0x4')]('/:id/run',auth[_0x21cb25('0x0')](),controller[_0x21cb25('0x8')]),router[_0x21cb25('0x4')](_0x21cb25('0x6'),auth['isAuthenticated'](),controller[_0x21cb25('0x11')]),router[_0x21cb25('0xf')]('/',auth[_0x21cb25('0x0')](),controller[_0x21cb25('0xc')]),router[_0x21cb25('0x7')](_0x21cb25('0x2'),auth[_0x21cb25('0x0')](),controller[_0x21cb25('0xb')]),router[_0x21cb25('0x1')](_0x21cb25('0x2'),auth['isAuthenticated'](),controller['destroy']),module[_0x21cb25('0xd')]=router; \ No newline at end of file +const a11_0x49b5=['show','get','/:id/run','put','create','run','exports','destroy','isAuthenticated','express','update','../../components/auth/service','post','delete','preview','/:id/query','Router','index'];(function(_0x31ff6b,_0x49b55a){const _0x41d5d5=function(_0x368749){while(--_0x368749){_0x31ff6b['push'](_0x31ff6b['shift']());}};_0x41d5d5(++_0x49b55a);}(a11_0x49b5,0x83));const a11_0x41d5=function(_0x31ff6b,_0x49b55a){_0x31ff6b=_0x31ff6b-0x0;let _0x41d5d5=a11_0x49b5[_0x31ff6b];return _0x41d5d5;};const _0x2f11ab=a11_0x41d5;'use strict';const express=require(_0x2f11ab('0x4')),router=express[_0x2f11ab('0xb')](),auth=require(_0x2f11ab('0x6')),controller=require('./analyticDefaultReport.controller');router['get']('/',auth[_0x2f11ab('0x3')](),controller[_0x2f11ab('0xc')]),router[_0x2f11ab('0xe')]('/:id',auth[_0x2f11ab('0x3')](),controller[_0x2f11ab('0xd')]),router[_0x2f11ab('0xe')]('/:id/preview',auth[_0x2f11ab('0x3')](),controller[_0x2f11ab('0x9')]),router['get'](_0x2f11ab('0xf'),auth[_0x2f11ab('0x3')](),controller[_0x2f11ab('0x0')]),router['get'](_0x2f11ab('0xa'),auth[_0x2f11ab('0x3')](),controller['query']),router[_0x2f11ab('0x7')]('/',auth[_0x2f11ab('0x3')](),controller[_0x2f11ab('0x11')]),router[_0x2f11ab('0x10')]('/:id',auth[_0x2f11ab('0x3')](),controller[_0x2f11ab('0x5')]),router[_0x2f11ab('0x8')]('/:id',auth[_0x2f11ab('0x3')](),controller[_0x2f11ab('0x2')]),module[_0x2f11ab('0x1')]=router; \ No newline at end of file diff --git a/server/api/analyticExtractedReport/analyticExtractedReport.attributes.js b/server/api/analyticExtractedReport/analyticExtractedReport.attributes.js index f2d4fac..bca67d6 100644 --- a/server/api/analyticExtractedReport/analyticExtractedReport.attributes.js +++ b/server/api/analyticExtractedReport/analyticExtractedReport.attributes.js @@ -1 +1 @@ -const a12_0x31e3=['sequelize','csv','ENUM','STRING','DATE','exports','INTEGER','UNSIGNED','pdf','manual','scheduled'];(function(_0x225a80,_0x31e376){const _0x9341d2=function(_0x2925aa){while(--_0x2925aa){_0x225a80['push'](_0x225a80['shift']());}};_0x9341d2(++_0x31e376);}(a12_0x31e3,0xc0));const a12_0x9341=function(_0x225a80,_0x31e376){_0x225a80=_0x225a80-0x0;let _0x9341d2=a12_0x31e3[_0x225a80];return _0x9341d2;};const _0x188e28=a12_0x9341;'use strict';const Sequelize=require(_0x188e28('0x6'));module[_0x188e28('0x0')]={'name':{'type':Sequelize[_0x188e28('0x9')],'allowNull':![]},'basename':{'type':Sequelize[_0x188e28('0x9')],'allowNull':![]},'output':{'type':Sequelize[_0x188e28('0x8')](_0x188e28('0x7'),_0x188e28('0x3'),'xlsx'),'allowNull':![],'defaultValue':_0x188e28('0x7')},'savename':{'type':Sequelize['STRING'],'allowNull':![]},'startDate':{'type':Sequelize['DATE']},'endDate':{'type':Sequelize[_0x188e28('0xa')]},'status':{'type':Sequelize['STRING'],'defaultValue':'Loading'},'type':{'type':Sequelize['ENUM'](_0x188e28('0x4'),_0x188e28('0x5')),'allowNull':![],'defaultValue':_0x188e28('0x4')},'reportId':{'type':Sequelize[_0x188e28('0x1')](0xb)[_0x188e28('0x2')]},'reportType':{'type':Sequelize[_0x188e28('0x9')]}}; \ No newline at end of file +const a12_0x50ae=['UNSIGNED','csv','pdf','manual','ENUM','scheduled','INTEGER','Loading','STRING','DATE','exports'];(function(_0x28352d,_0x50aee3){const _0x4aff86=function(_0x4c5b3c){while(--_0x4c5b3c){_0x28352d['push'](_0x28352d['shift']());}};_0x4aff86(++_0x50aee3);}(a12_0x50ae,0x108));const a12_0x4aff=function(_0x28352d,_0x50aee3){_0x28352d=_0x28352d-0x0;let _0x4aff86=a12_0x50ae[_0x28352d];return _0x4aff86;};const _0x14473c=a12_0x4aff;'use strict';const Sequelize=require('sequelize');module[_0x14473c('0xa')]={'name':{'type':Sequelize['STRING'],'allowNull':![]},'basename':{'type':Sequelize[_0x14473c('0x8')],'allowNull':![]},'output':{'type':Sequelize['ENUM'](_0x14473c('0x1'),_0x14473c('0x2'),'xlsx'),'allowNull':![],'defaultValue':'csv'},'savename':{'type':Sequelize[_0x14473c('0x8')],'allowNull':![]},'startDate':{'type':Sequelize[_0x14473c('0x9')]},'endDate':{'type':Sequelize['DATE']},'status':{'type':Sequelize[_0x14473c('0x8')],'defaultValue':_0x14473c('0x7')},'type':{'type':Sequelize[_0x14473c('0x4')](_0x14473c('0x3'),_0x14473c('0x5')),'allowNull':![],'defaultValue':_0x14473c('0x3')},'reportId':{'type':Sequelize[_0x14473c('0x6')](0xb)[_0x14473c('0x0')]},'reportType':{'type':Sequelize[_0x14473c('0x8')]}}; \ No newline at end of file diff --git a/server/api/analyticExtractedReport/analyticExtractedReport.controller.js b/server/api/analyticExtractedReport/analyticExtractedReport.controller.js index fe16325..a27a71f 100644 --- a/server/api/analyticExtractedReport/analyticExtractedReport.controller.js +++ b/server/api/analyticExtractedReport/analyticExtractedReport.controller.js @@ -1 +1 @@ -const a13_0x2c74=['UserProfileSection','sendStatus','include','merge','basename','error','then','filter','includeAll','offset','query','exists','order','findAll','end','destroy','keys','../../config/logger','filters','limit','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','autoAssociation','set','root','download','show','output','name','get','status','create','params','Unable\x20to\x20retrieve\x20the\x20current\x20user','attributes','options','../../config/environment','like','%s.%s','Report\x20not\x20found\x20or\x20empty','update','send','body','AnalyticExtractedReport','rawAttributes','intersection','../../components/parsers/qs','path','type','map','ExtractedReports','userProfileId','fields','key','files/reports','nolimit','where','count','UserProfileResource','length','api','model','existsSync','../../mysqldb','savename','json','join','undefined','catch','Content-Range','findOne','format'];(function(_0x3a8b11,_0x2c74f2){const _0x268649=function(_0x2f3ae0){while(--_0x2f3ae0){_0x3a8b11['push'](_0x3a8b11['shift']());}};_0x268649(++_0x2c74f2);}(a13_0x2c74,0x1cc));const a13_0x2686=function(_0x3a8b11,_0x2c74f2){_0x3a8b11=_0x3a8b11-0x0;let _0x268649=a13_0x2c74[_0x3a8b11];return _0x268649;};const _0x1a111c=a13_0x2686;'use strict';const util=require('util'),path=require(_0x1a111c('0xc')),fs=require('fs'),_=require('lodash'),qs=require(_0x1a111c('0xb')),logger=require(_0x1a111c('0x36'))(_0x1a111c('0x19')),config=require(_0x1a111c('0x1')),db=require(_0x1a111c('0x1c'))['db'],{Op,ValidationError}=require('sequelize');function respondWithResult(_0x2f3ae0,_0x43da83){return _0x43da83=_0x43da83||0xc8,function(_0x4b72ce){const _0xc0627c=a13_0x2686;if(_0x4b72ce)return _0x2f3ae0['status'](_0x43da83)[_0xc0627c('0x1e')](_0x4b72ce);};}function respondWithFilteredResult(_0x529f7b,_0x3e779c){return function(_0xc258d){const _0xf717ea=a13_0x2686;if(_0xc258d){const _0x1cae90=_0xc258d[_0xf717ea('0x16')],_0x3f4526=_0x3e779c[_0xf717ea('0x2e')];let _0x383cc3=_0x3e779c['offset']+_0x3e779c[_0xf717ea('0x38')],_0x4e8d3f;return _0x383cc3>=_0x1cae90?(_0x383cc3=_0x1cae90,_0x4e8d3f=0xc8):_0x4e8d3f=0xce,_0x529f7b['status'](_0x4e8d3f),_0x529f7b[_0xf717ea('0x3b')](_0xf717ea('0x22'),_0x3f4526+'-'+_0x383cc3+'/'+_0x1cae90)['json'](_0xc258d);}return null;};}function saveUpdates(_0x4f89d0){return function(_0x56ef85){const _0x3a6cd9=a13_0x2686;if(_0x56ef85)return _0x56ef85[_0x3a6cd9('0x5')](_0x4f89d0)[_0x3a6cd9('0x2b')](function(_0x3c2b35){return _0x3c2b35;});return null;};}function removeEntity(_0x20f3f0){return function(_0x337afe){const _0x8bee43=a13_0x2686;if(_0x337afe)return _0x337afe['destroy']()['then'](function(){const _0x3e2595=a13_0x2686,_0x196944=_0x337afe[_0x3e2595('0x41')]({'plain':!![]}),_0x251b47=_0x3e2595('0xf');return db['UserProfileResource']['destroy']({'where':{'type':_0x251b47,'resourceId':_0x196944['id']}})[_0x3e2595('0x2b')](function(){return _0x337afe;});})[_0x8bee43('0x2b')](function(){const _0x137efa=_0x8bee43;_0x20f3f0[_0x137efa('0x42')](0xcc)[_0x137efa('0x33')]();});};}function handleEntityNotFound(_0x38d0ae){return function(_0x201752){return!_0x201752&&_0x38d0ae['sendStatus'](0x194),_0x201752;};}function handleError(_0x1ec055,_0x53f703){return _0x53f703=_0x53f703||0x1f4,function(_0x5339e0){const _0x4eca20=a13_0x2686;logger['error'](_0x5339e0['stack']),_0x5339e0[_0x4eca20('0x40')]&&delete _0x5339e0[_0x4eca20('0x40')],_0x1ec055['status'](_0x53f703)[_0x4eca20('0x6')](_0x5339e0);};}exports['index']=function(_0x1be202,_0x3cafdb){const _0xf50ef9=_0x1a111c;let _0x5c2fa3={};const _0x3ccf1d={},_0x20eddd={'count':0x0,'rows':[]},_0x4f9c42=_[_0xf50ef9('0xe')](db['AnalyticExtractedReport'][_0xf50ef9('0x9')],function(_0xd10277){const _0x395735=_0xf50ef9;return{'name':_0xd10277['fieldName'],'type':_0xd10277[_0x395735('0xd')][_0x395735('0x12')]};});_0x3ccf1d[_0xf50ef9('0x1a')]=_[_0xf50ef9('0xe')](_0x4f9c42,'name'),_0x3ccf1d[_0xf50ef9('0x2f')]=_[_0xf50ef9('0x35')](_0x1be202['query']),_0x3ccf1d['filters']=_['intersection'](_0x3ccf1d['model'],_0x3ccf1d[_0xf50ef9('0x2f')]),_0x5c2fa3['attributes']=_[_0xf50ef9('0xa')](_0x3ccf1d[_0xf50ef9('0x1a')],qs['fields'](_0x1be202[_0xf50ef9('0x2f')]['fields'])),_0x5c2fa3[_0xf50ef9('0x46')]=_0x5c2fa3[_0xf50ef9('0x46')][_0xf50ef9('0x18')]?_0x5c2fa3[_0xf50ef9('0x46')]:_0x3ccf1d[_0xf50ef9('0x1a')];typeof _0x1be202[_0xf50ef9('0x2f')][_0xf50ef9('0x14')]===_0xf50ef9('0x20')&&(_0x5c2fa3[_0xf50ef9('0x38')]=qs[_0xf50ef9('0x38')](_0x1be202[_0xf50ef9('0x2f')][_0xf50ef9('0x38')]),_0x5c2fa3[_0xf50ef9('0x2e')]=qs['offset'](_0x1be202[_0xf50ef9('0x2f')][_0xf50ef9('0x2e')]));_0x5c2fa3[_0xf50ef9('0x31')]=qs['sort'](_0x1be202[_0xf50ef9('0x2f')]['sort']),_0x5c2fa3[_0xf50ef9('0x15')]=qs[_0xf50ef9('0x37')](_['pick'](_0x1be202[_0xf50ef9('0x2f')],_0x3ccf1d[_0xf50ef9('0x37')]),_0x4f9c42);_0x1be202[_0xf50ef9('0x2f')]['filter']&&(_0x5c2fa3[_0xf50ef9('0x15')]=_[_0xf50ef9('0x28')](_0x5c2fa3[_0xf50ef9('0x15')],{[Op['or']]:_[_0xf50ef9('0xe')](_0x4f9c42,function(_0x49bd61){const _0x2f365e=_0xf50ef9;if(_0x49bd61[_0x2f365e('0xd')]!=='VIRTUAL'){const _0x1c5f21={};return _0x1c5f21[_0x49bd61[_0x2f365e('0x40')]]={[Op[_0x2f365e('0x2')]]:'%'+_0x1be202[_0x2f365e('0x2f')][_0x2f365e('0x2c')]+'%'},_0x1c5f21;}})}));_0x5c2fa3=_[_0xf50ef9('0x28')]({},_0x5c2fa3,_0x1be202[_0xf50ef9('0x0')]);const _0x5aaa69={'where':_0x5c2fa3['where']};return db[_0xf50ef9('0x8')][_0xf50ef9('0x16')](_0x5aaa69)[_0xf50ef9('0x2b')](function(_0x3360cc){const _0x385fb9=_0xf50ef9;return _0x20eddd[_0x385fb9('0x16')]=_0x3360cc,_0x1be202['query'][_0x385fb9('0x2d')]&&(_0x5c2fa3[_0x385fb9('0x27')]=[{'all':!![]}]),db['AnalyticExtractedReport'][_0x385fb9('0x32')](_0x5c2fa3);})[_0xf50ef9('0x2b')](function(_0x3d5178){return _0x20eddd['rows']=_0x3d5178,_0x20eddd;})['then'](respondWithFilteredResult(_0x3cafdb,_0x5c2fa3))['catch'](handleError(_0x3cafdb,null));},exports[_0x1a111c('0x3e')]=function(_0x3dbfae,_0x3a408d){const _0x1c6e0b=_0x1a111c;let _0x21751c={'raw':!![],'where':{'id':_0x3dbfae[_0x1c6e0b('0x44')]['id']}};const _0x4c28b7={};return _0x4c28b7['model']=_[_0x1c6e0b('0x35')](db[_0x1c6e0b('0x8')][_0x1c6e0b('0x9')]),_0x4c28b7[_0x1c6e0b('0x2f')]=_[_0x1c6e0b('0x35')](_0x3dbfae[_0x1c6e0b('0x2f')]),_0x4c28b7[_0x1c6e0b('0x37')]=_['intersection'](_0x4c28b7['model'],_0x4c28b7[_0x1c6e0b('0x2f')]),_0x21751c[_0x1c6e0b('0x46')]=_['intersection'](_0x4c28b7[_0x1c6e0b('0x1a')],qs['fields'](_0x3dbfae[_0x1c6e0b('0x2f')][_0x1c6e0b('0x11')])),_0x21751c['attributes']=_0x21751c[_0x1c6e0b('0x46')]['length']?_0x21751c[_0x1c6e0b('0x46')]:_0x4c28b7['model'],_0x3dbfae[_0x1c6e0b('0x2f')][_0x1c6e0b('0x2d')]&&(_0x21751c['include']=[{'all':!![]}]),_0x21751c=_['merge']({},_0x21751c,_0x3dbfae['options']),db[_0x1c6e0b('0x8')][_0x1c6e0b('0x23')](_0x21751c)[_0x1c6e0b('0x2b')](handleEntityNotFound(_0x3a408d,null))[_0x1c6e0b('0x2b')](respondWithResult(_0x3a408d,null))[_0x1c6e0b('0x21')](handleError(_0x3a408d,null));},exports[_0x1a111c('0x43')]=function(_0x5026ec,_0x1389d0){const _0x34409f=_0x1a111c;return db[_0x34409f('0x8')][_0x34409f('0x43')](_0x5026ec[_0x34409f('0x7')],{})[_0x34409f('0x2b')](function(_0x5a9cc8){const _0x4023a4=_0x34409f,_0x5741a8=_0x5026ec['user'][_0x4023a4('0x41')]({'plain':!![]});if(!_0x5741a8)throw new Error(_0x4023a4('0x45'));if(_0x5741a8['role']==='user'){const _0x4ac871=_0x5a9cc8['get']({'plain':!![]}),_0x16f191=_0x4023a4('0xf');return db[_0x4023a4('0x25')]['findOne']({'where':{'name':_0x16f191,'userProfileId':_0x5741a8[_0x4023a4('0x10')]},'raw':!![]})[_0x4023a4('0x2b')](function(_0x4ea5c5){const _0x9f24c1=_0x4023a4;return _0x4ea5c5&&_0x4ea5c5[_0x9f24c1('0x3a')]===0x0?db[_0x9f24c1('0x17')]['create']({'name':_0x4ac871['name'],'resourceId':_0x4ac871['id'],'type':_0x4ea5c5[_0x9f24c1('0x40')],'sectionId':_0x4ea5c5['id']},{})[_0x9f24c1('0x2b')](function(){return _0x5a9cc8;}):_0x5a9cc8;})[_0x4023a4('0x21')](function(_0x6dbe85){const _0x357667=_0x4023a4;logger[_0x357667('0x2a')](_0x357667('0x39'),_0x6dbe85);throw _0x6dbe85;});}return _0x5a9cc8;})['then'](respondWithResult(_0x1389d0,0xc9))[_0x34409f('0x21')](handleError(_0x1389d0,null));},exports[_0x1a111c('0x5')]=function(_0x116db9,_0x3b2e63){const _0x250607=_0x1a111c;return _0x116db9[_0x250607('0x7')]['id']&&delete _0x116db9[_0x250607('0x7')]['id'],db[_0x250607('0x8')]['findOne']({'where':{'id':_0x116db9[_0x250607('0x44')]['id']}})[_0x250607('0x2b')](handleEntityNotFound(_0x3b2e63,null))['then'](saveUpdates(_0x116db9[_0x250607('0x7')],null))[_0x250607('0x2b')](respondWithResult(_0x3b2e63,null))[_0x250607('0x21')](handleError(_0x3b2e63,null));},exports[_0x1a111c('0x34')]=function(_0x237cca,_0x565e4d){const _0x25b134=_0x1a111c;return db[_0x25b134('0x8')][_0x25b134('0x23')]({'where':{'id':_0x237cca[_0x25b134('0x44')]['id']}})[_0x25b134('0x2b')](handleEntityNotFound(_0x565e4d,null))['then'](removeEntity(_0x565e4d,null))[_0x25b134('0x21')](handleError(_0x565e4d,null));},exports[_0x1a111c('0x3d')]=function(_0x1f53bb,_0x2803f6){const _0x5cbb48=_0x1a111c;return db[_0x5cbb48('0x8')]['findOne']({'where':{'id':_0x1f53bb[_0x5cbb48('0x44')]['id']},'attributes':[_0x5cbb48('0x40'),'basename',_0x5cbb48('0x1d'),_0x5cbb48('0x3f')],'raw':!![]})[_0x5cbb48('0x2b')](handleEntityNotFound(_0x2803f6,null))[_0x5cbb48('0x2b')](function(_0x166873){const _0x254b67=_0x5cbb48;if(_0x166873){if(!fs[_0x254b67('0x1b')](path[_0x254b67('0x1f')](config['root'],_0x254b67('0x13'),_0x166873['savename'])))throw new ValidationError(_0x254b67('0x4'));if(_0x1f53bb['query'][_0x254b67('0x30')])return _0x2803f6[_0x254b67('0x26')](0xc8);return _0x2803f6['download'](path[_0x254b67('0x1f')](config[_0x254b67('0x3c')],_0x254b67('0x13'),_0x166873[_0x254b67('0x1d')]),util[_0x254b67('0x24')](_0x254b67('0x3'),_0x166873[_0x254b67('0x29')]||_0x166873[_0x254b67('0x40')],_0x166873[_0x254b67('0x3f')]['toLowerCase']()));}})[_0x5cbb48('0x21')](handleError(_0x2803f6,null));}; \ No newline at end of file +const a13_0x234e=['output','util','options','rawAttributes','count','status','UserProfileResource','attributes','fieldName','then','filter','fields','download','create','params','../../components/parsers/qs','end','exists','like','body','basename','ExtractedReports','VIRTUAL','merge','Unable\x20to\x20retrieve\x20the\x20current\x20user','api','error','files/reports','findOne','AnalyticExtractedReport','catch','include','json','format','Report\x20not\x20found\x20or\x20empty','undefined','limit','role','order','length','sendStatus','set','findAll','root','user','filters','sequelize','UserProfileSection','type','show','update','keys','offset','savename','intersection','nolimit','../../config/logger','stack','join','query','model','map','sort','name','destroy','existsSync','get','key','where','autoAssociation','lodash'];(function(_0x365a9d,_0x234e4b){const _0x1a81f3=function(_0x2d4db2){while(--_0x2d4db2){_0x365a9d['push'](_0x365a9d['shift']());}};_0x1a81f3(++_0x234e4b);}(a13_0x234e,0x9c));const a13_0x1a81=function(_0x365a9d,_0x234e4b){_0x365a9d=_0x365a9d-0x0;let _0x1a81f3=a13_0x234e[_0x365a9d];return _0x1a81f3;};const _0x3e6e2c=a13_0x1a81;'use strict';const util=require(_0x3e6e2c('0x3a')),path=require('path'),fs=require('fs'),_=require(_0x3e6e2c('0x38')),qs=require(_0x3e6e2c('0x1')),logger=require(_0x3e6e2c('0x2a'))(_0x3e6e2c('0xb')),config=require('../../config/environment'),db=require('../../mysqldb')['db'],{Op,ValidationError}=require(_0x3e6e2c('0x20'));function respondWithResult(_0x2d4db2,_0x5c6278){return _0x5c6278=_0x5c6278||0xc8,function(_0x348058){const _0x3da36c=a13_0x1a81;if(_0x348058)return _0x2d4db2[_0x3da36c('0x3e')](_0x5c6278)[_0x3da36c('0x12')](_0x348058);};}function respondWithFilteredResult(_0x465747,_0x788823){return function(_0xe400bf){const _0x5ed8dc=a13_0x1a81;if(_0xe400bf){const _0x11d957=_0xe400bf[_0x5ed8dc('0x3d')],_0x43e7aa=_0x788823['offset'];let _0x232597=_0x788823[_0x5ed8dc('0x26')]+_0x788823['limit'],_0x3151c8;return _0x232597>=_0x11d957?(_0x232597=_0x11d957,_0x3151c8=0xc8):_0x3151c8=0xce,_0x465747[_0x5ed8dc('0x3e')](_0x3151c8),_0x465747[_0x5ed8dc('0x1b')]('Content-Range',_0x43e7aa+'-'+_0x232597+'/'+_0x11d957)[_0x5ed8dc('0x12')](_0xe400bf);}return null;};}function saveUpdates(_0xd671e7){return function(_0x2569cb){const _0x1260d8=a13_0x1a81;if(_0x2569cb)return _0x2569cb[_0x1260d8('0x24')](_0xd671e7)[_0x1260d8('0x42')](function(_0x19ea57){return _0x19ea57;});return null;};}function removeEntity(_0xff879f){return function(_0x5b6abd){const _0x4d7b70=a13_0x1a81;if(_0x5b6abd)return _0x5b6abd[_0x4d7b70('0x32')]()['then'](function(){const _0x1cdd82=_0x4d7b70,_0x55d6cf=_0x5b6abd[_0x1cdd82('0x34')]({'plain':!![]}),_0x2976fb=_0x1cdd82('0x7');return db[_0x1cdd82('0x3f')][_0x1cdd82('0x32')]({'where':{'type':_0x2976fb,'resourceId':_0x55d6cf['id']}})[_0x1cdd82('0x42')](function(){return _0x5b6abd;});})[_0x4d7b70('0x42')](function(){const _0x2cc6ff=_0x4d7b70;_0xff879f[_0x2cc6ff('0x3e')](0xcc)[_0x2cc6ff('0x2')]();});};}function handleEntityNotFound(_0x3a2af1){return function(_0x2dfb04){const _0xa2adb0=a13_0x1a81;return!_0x2dfb04&&_0x3a2af1[_0xa2adb0('0x1a')](0x194),_0x2dfb04;};}function handleError(_0x4e3bb5,_0x380231){return _0x380231=_0x380231||0x1f4,function(_0x42b158){const _0x1d80a6=a13_0x1a81;logger[_0x1d80a6('0xc')](_0x42b158[_0x1d80a6('0x2b')]),_0x42b158[_0x1d80a6('0x31')]&&delete _0x42b158[_0x1d80a6('0x31')],_0x4e3bb5['status'](_0x380231)['send'](_0x42b158);};}exports['index']=function(_0x4965d5,_0x1e45d1){const _0x161396=_0x3e6e2c;let _0x27fe5a={};const _0x4db19a={},_0x5b27a5={'count':0x0,'rows':[]},_0x493a86=_['map'](db[_0x161396('0xf')][_0x161396('0x3c')],function(_0x58b16d){const _0x5c8d33=_0x161396;return{'name':_0x58b16d[_0x5c8d33('0x41')],'type':_0x58b16d['type'][_0x5c8d33('0x35')]};});_0x4db19a[_0x161396('0x2e')]=_['map'](_0x493a86,_0x161396('0x31')),_0x4db19a[_0x161396('0x2d')]=_[_0x161396('0x25')](_0x4965d5[_0x161396('0x2d')]),_0x4db19a[_0x161396('0x1f')]=_[_0x161396('0x28')](_0x4db19a['model'],_0x4db19a['query']),_0x27fe5a[_0x161396('0x40')]=_[_0x161396('0x28')](_0x4db19a[_0x161396('0x2e')],qs[_0x161396('0x44')](_0x4965d5[_0x161396('0x2d')][_0x161396('0x44')])),_0x27fe5a[_0x161396('0x40')]=_0x27fe5a[_0x161396('0x40')][_0x161396('0x19')]?_0x27fe5a['attributes']:_0x4db19a['model'];typeof _0x4965d5['query'][_0x161396('0x29')]===_0x161396('0x15')&&(_0x27fe5a[_0x161396('0x16')]=qs['limit'](_0x4965d5[_0x161396('0x2d')]['limit']),_0x27fe5a[_0x161396('0x26')]=qs[_0x161396('0x26')](_0x4965d5[_0x161396('0x2d')][_0x161396('0x26')]));_0x27fe5a[_0x161396('0x18')]=qs[_0x161396('0x30')](_0x4965d5[_0x161396('0x2d')][_0x161396('0x30')]),_0x27fe5a[_0x161396('0x36')]=qs[_0x161396('0x1f')](_['pick'](_0x4965d5[_0x161396('0x2d')],_0x4db19a[_0x161396('0x1f')]),_0x493a86);_0x4965d5[_0x161396('0x2d')]['filter']&&(_0x27fe5a[_0x161396('0x36')]=_[_0x161396('0x9')](_0x27fe5a['where'],{[Op['or']]:_[_0x161396('0x2f')](_0x493a86,function(_0x20cca9){const _0x5501e9=_0x161396;if(_0x20cca9[_0x5501e9('0x22')]!==_0x5501e9('0x8')){const _0x45830d={};return _0x45830d[_0x20cca9[_0x5501e9('0x31')]]={[Op[_0x5501e9('0x4')]]:'%'+_0x4965d5[_0x5501e9('0x2d')][_0x5501e9('0x43')]+'%'},_0x45830d;}})}));_0x27fe5a=_['merge']({},_0x27fe5a,_0x4965d5[_0x161396('0x3b')]);const _0x3ae80d={'where':_0x27fe5a[_0x161396('0x36')]};return db[_0x161396('0xf')]['count'](_0x3ae80d)[_0x161396('0x42')](function(_0x513a6e){const _0x57401d=_0x161396;return _0x5b27a5['count']=_0x513a6e,_0x4965d5[_0x57401d('0x2d')]['includeAll']&&(_0x27fe5a['include']=[{'all':!![]}]),db['AnalyticExtractedReport'][_0x57401d('0x1c')](_0x27fe5a);})[_0x161396('0x42')](function(_0x116991){return _0x5b27a5['rows']=_0x116991,_0x5b27a5;})[_0x161396('0x42')](respondWithFilteredResult(_0x1e45d1,_0x27fe5a))[_0x161396('0x10')](handleError(_0x1e45d1,null));},exports[_0x3e6e2c('0x23')]=function(_0x38abf5,_0x13c2c5){const _0x18aea8=_0x3e6e2c;let _0x5a1e84={'raw':!![],'where':{'id':_0x38abf5[_0x18aea8('0x0')]['id']}};const _0x5388ed={};return _0x5388ed[_0x18aea8('0x2e')]=_['keys'](db[_0x18aea8('0xf')][_0x18aea8('0x3c')]),_0x5388ed[_0x18aea8('0x2d')]=_['keys'](_0x38abf5['query']),_0x5388ed[_0x18aea8('0x1f')]=_[_0x18aea8('0x28')](_0x5388ed[_0x18aea8('0x2e')],_0x5388ed[_0x18aea8('0x2d')]),_0x5a1e84[_0x18aea8('0x40')]=_[_0x18aea8('0x28')](_0x5388ed[_0x18aea8('0x2e')],qs[_0x18aea8('0x44')](_0x38abf5['query'][_0x18aea8('0x44')])),_0x5a1e84['attributes']=_0x5a1e84[_0x18aea8('0x40')]['length']?_0x5a1e84[_0x18aea8('0x40')]:_0x5388ed[_0x18aea8('0x2e')],_0x38abf5[_0x18aea8('0x2d')]['includeAll']&&(_0x5a1e84[_0x18aea8('0x11')]=[{'all':!![]}]),_0x5a1e84=_[_0x18aea8('0x9')]({},_0x5a1e84,_0x38abf5['options']),db['AnalyticExtractedReport'][_0x18aea8('0xe')](_0x5a1e84)[_0x18aea8('0x42')](handleEntityNotFound(_0x13c2c5,null))[_0x18aea8('0x42')](respondWithResult(_0x13c2c5,null))[_0x18aea8('0x10')](handleError(_0x13c2c5,null));},exports[_0x3e6e2c('0x46')]=function(_0x4ad54d,_0x3159a4){const _0x45837a=_0x3e6e2c;return db[_0x45837a('0xf')][_0x45837a('0x46')](_0x4ad54d[_0x45837a('0x5')],{})[_0x45837a('0x42')](function(_0x361cc0){const _0x52f657=_0x45837a,_0xd50016=_0x4ad54d[_0x52f657('0x1e')]['get']({'plain':!![]});if(!_0xd50016)throw new Error(_0x52f657('0xa'));if(_0xd50016[_0x52f657('0x17')]==='user'){const _0x14e8d5=_0x361cc0[_0x52f657('0x34')]({'plain':!![]}),_0x21f78b=_0x52f657('0x7');return db[_0x52f657('0x21')][_0x52f657('0xe')]({'where':{'name':_0x21f78b,'userProfileId':_0xd50016['userProfileId']},'raw':!![]})[_0x52f657('0x42')](function(_0x36d471){const _0x54bb76=_0x52f657;return _0x36d471&&_0x36d471[_0x54bb76('0x37')]===0x0?db[_0x54bb76('0x3f')]['create']({'name':_0x14e8d5[_0x54bb76('0x31')],'resourceId':_0x14e8d5['id'],'type':_0x36d471['name'],'sectionId':_0x36d471['id']},{})[_0x54bb76('0x42')](function(){return _0x361cc0;}):_0x361cc0;})[_0x52f657('0x10')](function(_0x47363f){const _0x138aec=_0x52f657;logger[_0x138aec('0xc')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x47363f);throw _0x47363f;});}return _0x361cc0;})['then'](respondWithResult(_0x3159a4,0xc9))[_0x45837a('0x10')](handleError(_0x3159a4,null));},exports[_0x3e6e2c('0x24')]=function(_0x1442ee,_0x4858d6){const _0x2ac049=_0x3e6e2c;return _0x1442ee[_0x2ac049('0x5')]['id']&&delete _0x1442ee['body']['id'],db[_0x2ac049('0xf')][_0x2ac049('0xe')]({'where':{'id':_0x1442ee[_0x2ac049('0x0')]['id']}})[_0x2ac049('0x42')](handleEntityNotFound(_0x4858d6,null))[_0x2ac049('0x42')](saveUpdates(_0x1442ee['body'],null))[_0x2ac049('0x42')](respondWithResult(_0x4858d6,null))['catch'](handleError(_0x4858d6,null));},exports[_0x3e6e2c('0x32')]=function(_0x2a41e2,_0x2148cf){const _0x5a299c=_0x3e6e2c;return db['AnalyticExtractedReport'][_0x5a299c('0xe')]({'where':{'id':_0x2a41e2[_0x5a299c('0x0')]['id']}})[_0x5a299c('0x42')](handleEntityNotFound(_0x2148cf,null))[_0x5a299c('0x42')](removeEntity(_0x2148cf,null))[_0x5a299c('0x10')](handleError(_0x2148cf,null));},exports[_0x3e6e2c('0x45')]=function(_0x53afcf,_0xf7753a){const _0x12c7d5=_0x3e6e2c;return db[_0x12c7d5('0xf')][_0x12c7d5('0xe')]({'where':{'id':_0x53afcf[_0x12c7d5('0x0')]['id']},'attributes':[_0x12c7d5('0x31'),_0x12c7d5('0x6'),'savename',_0x12c7d5('0x39')],'raw':!![]})['then'](handleEntityNotFound(_0xf7753a,null))[_0x12c7d5('0x42')](function(_0x248785){const _0x51ca8b=_0x12c7d5;if(_0x248785){if(!fs[_0x51ca8b('0x33')](path[_0x51ca8b('0x2c')](config['root'],_0x51ca8b('0xd'),_0x248785[_0x51ca8b('0x27')])))throw new ValidationError(_0x51ca8b('0x14'));if(_0x53afcf[_0x51ca8b('0x2d')][_0x51ca8b('0x3')])return _0xf7753a[_0x51ca8b('0x1a')](0xc8);return _0xf7753a[_0x51ca8b('0x45')](path[_0x51ca8b('0x2c')](config[_0x51ca8b('0x1d')],_0x51ca8b('0xd'),_0x248785['savename']),util[_0x51ca8b('0x13')]('%s.%s',_0x248785['basename']||_0x248785[_0x51ca8b('0x31')],_0x248785[_0x51ca8b('0x39')]['toLowerCase']()));}})[_0x12c7d5('0x10')](handleError(_0xf7753a,null));}; \ No newline at end of file diff --git a/server/api/analyticExtractedReport/analyticExtractedReport.model.js b/server/api/analyticExtractedReport/analyticExtractedReport.model.js index edcda4d..4a9573e 100644 --- a/server/api/analyticExtractedReport/analyticExtractedReport.model.js +++ b/server/api/analyticExtractedReport/analyticExtractedReport.model.js @@ -1 +1 @@ -const a14_0xd4c2=['./analyticExtractedReport.attributes','AnalyticExtractedReport'];(function(_0x293c95,_0xd4c2ed){const _0xe1828=function(_0x313492){while(--_0x313492){_0x293c95['push'](_0x293c95['shift']());}};_0xe1828(++_0xd4c2ed);}(a14_0xd4c2,0x169));const a14_0xe182=function(_0x293c95,_0xd4c2ed){_0x293c95=_0x293c95-0x0;let _0xe1828=a14_0xd4c2[_0x293c95];return _0xe1828;};const _0x5007fa=a14_0xe182;'use strict';const attributes=require(_0x5007fa('0x1'));module['exports']=function(_0x313492){const _0x521ba7=_0x5007fa,_0x2b0ac1=_0x313492['define'](_0x521ba7('0x0'),attributes,{'tableName':'analytics_extracted_reports','paranoid':![],'indexes':[],'timestamps':!![]});return _0x2b0ac1;}; \ No newline at end of file +const a14_0x5a87=['exports','./analyticExtractedReport.attributes','AnalyticExtractedReport','define','analytics_extracted_reports'];(function(_0x339526,_0x5a87a8){const _0x6da044=function(_0x4c76d8){while(--_0x4c76d8){_0x339526['push'](_0x339526['shift']());}};_0x6da044(++_0x5a87a8);}(a14_0x5a87,0x1bd));const a14_0x6da0=function(_0x339526,_0x5a87a8){_0x339526=_0x339526-0x0;let _0x6da044=a14_0x5a87[_0x339526];return _0x6da044;};const _0x253d4f=a14_0x6da0;'use strict';const attributes=require(_0x253d4f('0x1'));module[_0x253d4f('0x0')]=function(_0x4c76d8){const _0x177abf=_0x253d4f,_0xf56bb4=_0x4c76d8[_0x177abf('0x3')](_0x177abf('0x2'),attributes,{'tableName':_0x177abf('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xf56bb4;}; \ No newline at end of file diff --git a/server/api/analyticExtractedReport/index.js b/server/api/analyticExtractedReport/index.js index 91991c1..b2245db 100644 --- a/server/api/analyticExtractedReport/index.js +++ b/server/api/analyticExtractedReport/index.js @@ -1 +1 @@ -const a15_0x4098=['exports','get','Router','create','index','post','destroy','/:id','put','./analyticExtractedReport.controller','isAuthenticated','../../components/auth/service','show','express','update'];(function(_0x1535bc,_0x40988f){const _0x293d5c=function(_0x111c1c){while(--_0x111c1c){_0x1535bc['push'](_0x1535bc['shift']());}};_0x293d5c(++_0x40988f);}(a15_0x4098,0x198));const a15_0x293d=function(_0x1535bc,_0x40988f){_0x1535bc=_0x1535bc-0x0;let _0x293d5c=a15_0x4098[_0x1535bc];return _0x293d5c;};const _0x147524=a15_0x293d;'use strict';const express=require(_0x147524('0xa')),router=express[_0x147524('0xe')](),auth=require(_0x147524('0x8')),controller=require(_0x147524('0x6'));router[_0x147524('0xd')]('/',auth[_0x147524('0x7')](),controller[_0x147524('0x1')]),router['get']('/:id',auth[_0x147524('0x7')](),controller[_0x147524('0x9')]),router[_0x147524('0xd')]('/:id/download',auth[_0x147524('0x7')](),controller['download']),router[_0x147524('0x2')]('/',auth[_0x147524('0x7')](),controller[_0x147524('0x0')]),router[_0x147524('0x5')](_0x147524('0x4'),auth[_0x147524('0x7')](),controller[_0x147524('0xb')]),router['delete']('/:id',auth[_0x147524('0x7')](),controller[_0x147524('0x3')]),module[_0x147524('0xc')]=router; \ No newline at end of file +const a15_0x444f=['put','index','isAuthenticated','destroy','download','update','exports','Router','post','delete','get','./analyticExtractedReport.controller','show','/:id/download','create','/:id','express'];(function(_0x23873c,_0x444f91){const _0x5f350b=function(_0x1fb71e){while(--_0x1fb71e){_0x23873c['push'](_0x23873c['shift']());}};_0x5f350b(++_0x444f91);}(a15_0x444f,0x1d1));const a15_0x5f35=function(_0x23873c,_0x444f91){_0x23873c=_0x23873c-0x0;let _0x5f350b=a15_0x444f[_0x23873c];return _0x5f350b;};const _0x11957a=a15_0x5f35;'use strict';const express=require(_0x11957a('0xa')),router=express[_0x11957a('0x1')](),auth=require('../../components/auth/service'),controller=require(_0x11957a('0x5'));router[_0x11957a('0x4')]('/',auth[_0x11957a('0xd')](),controller[_0x11957a('0xc')]),router['get'](_0x11957a('0x9'),auth[_0x11957a('0xd')](),controller[_0x11957a('0x6')]),router[_0x11957a('0x4')](_0x11957a('0x7'),auth['isAuthenticated'](),controller[_0x11957a('0xf')]),router[_0x11957a('0x2')]('/',auth[_0x11957a('0xd')](),controller[_0x11957a('0x8')]),router[_0x11957a('0xb')](_0x11957a('0x9'),auth[_0x11957a('0xd')](),controller[_0x11957a('0x10')]),router[_0x11957a('0x3')]('/:id',auth[_0x11957a('0xd')](),controller[_0x11957a('0xe')]),module[_0x11957a('0x0')]=router; \ No newline at end of file diff --git a/server/api/analyticFieldReport/analyticFieldReport.attributes.js b/server/api/analyticFieldReport/analyticFieldReport.attributes.js index 4cbfb03..be57af0 100644 --- a/server/api/analyticFieldReport/analyticFieldReport.attributes.js +++ b/server/api/analyticFieldReport/analyticFieldReport.attributes.js @@ -1 +1 @@ -const a16_0x2278=['sequelize','BOOLEAN','STRING','exports'];(function(_0x3d45e3,_0x227871){const _0xd6155b=function(_0x469cbd){while(--_0x469cbd){_0x3d45e3['push'](_0x3d45e3['shift']());}};_0xd6155b(++_0x227871);}(a16_0x2278,0x118));const a16_0xd615=function(_0x3d45e3,_0x227871){_0x3d45e3=_0x3d45e3-0x0;let _0xd6155b=a16_0x2278[_0x3d45e3];return _0xd6155b;};const _0x4bbb26=a16_0xd615;'use strict';const Sequelize=require(_0x4bbb26('0x0'));module[_0x4bbb26('0x3')]={'field':{'type':Sequelize['TEXT']},'alias':{'type':Sequelize['STRING']},'function':{'type':Sequelize[_0x4bbb26('0x2')]},'format':{'type':Sequelize['STRING']},'groupBy':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'orderBy':{'type':Sequelize[_0x4bbb26('0x2')]},'custom':{'type':Sequelize[_0x4bbb26('0x1')],'defaultValue':![]}}; \ No newline at end of file +const a16_0x1fba=['STRING','BOOLEAN','sequelize','exports'];(function(_0x3b14d1,_0x1fba2d){const _0x1a2a3e=function(_0x1a082c){while(--_0x1a082c){_0x3b14d1['push'](_0x3b14d1['shift']());}};_0x1a2a3e(++_0x1fba2d);}(a16_0x1fba,0xb2));const a16_0x1a2a=function(_0x3b14d1,_0x1fba2d){_0x3b14d1=_0x3b14d1-0x0;let _0x1a2a3e=a16_0x1fba[_0x3b14d1];return _0x1a2a3e;};const _0x2d439a=a16_0x1a2a;'use strict';const Sequelize=require(_0x2d439a('0x0'));module[_0x2d439a('0x1')]={'field':{'type':Sequelize['TEXT']},'alias':{'type':Sequelize[_0x2d439a('0x2')]},'function':{'type':Sequelize[_0x2d439a('0x2')]},'format':{'type':Sequelize['STRING']},'groupBy':{'type':Sequelize[_0x2d439a('0x3')],'defaultValue':![]},'orderBy':{'type':Sequelize[_0x2d439a('0x2')]},'custom':{'type':Sequelize[_0x2d439a('0x3')],'defaultValue':![]}}; \ No newline at end of file diff --git a/server/api/analyticFieldReport/analyticFieldReport.controller.js b/server/api/analyticFieldReport/analyticFieldReport.controller.js index 9652e8d..70218b0 100644 --- a/server/api/analyticFieldReport/analyticFieldReport.controller.js +++ b/server/api/analyticFieldReport/analyticFieldReport.controller.js @@ -1 +1 @@ -const a17_0x14c9=['sequelize','rows','rawAttributes','count','key','model','where','findOne','update','undefined','intersection','params','nolimit','index','sendStatus','options','AnalyticCustomReport','pick','filters','set','query','destroy','Content-Range','catch','sort','create','lodash','api','status','attributes','bulkCreate','json','../../mysqldb','addFields','offset','body','length','name','AnalyticFieldReport','then','../../components/parsers/qs','show','../../config/logger','merge','end','map','findAll','CustomReportId','ids','keys','type','filter','VIRTUAL','limit','fields','include'];(function(_0x5d8d4e,_0x14c9d2){const _0x5576bf=function(_0x59bd67){while(--_0x59bd67){_0x5d8d4e['push'](_0x5d8d4e['shift']());}};_0x5576bf(++_0x14c9d2);}(a17_0x14c9,0x1b6));const a17_0x5576=function(_0x5d8d4e,_0x14c9d2){_0x5d8d4e=_0x5d8d4e-0x0;let _0x5576bf=a17_0x14c9[_0x5d8d4e];return _0x5576bf;};const _0x85b1f=a17_0x5576;'use strict';const _=require(_0x85b1f('0x24')),qs=require(_0x85b1f('0x32')),logger=require(_0x85b1f('0x34'))(_0x85b1f('0x25')),db=require(_0x85b1f('0x2a'))['db'],{Op}=require(_0x85b1f('0xa'));function respondWithResult(_0x59bd67,_0x14be7b){return _0x14be7b=_0x14be7b||0xc8,function(_0x1d95d5){const _0x992a22=a17_0x5576;if(_0x1d95d5)return _0x59bd67['status'](_0x14be7b)[_0x992a22('0x29')](_0x1d95d5);};}function respondWithFilteredResult(_0x5a10a1,_0x5425e0){return function(_0x3bb09a){const _0x1dbc34=a17_0x5576;if(_0x3bb09a){const _0x5727ae=_0x3bb09a[_0x1dbc34('0xd')],_0x40a881=_0x5425e0['offset'];let _0x278279=_0x5425e0[_0x1dbc34('0x2c')]+_0x5425e0['limit'],_0x33612c;return _0x278279>=_0x5727ae?(_0x278279=_0x5727ae,_0x33612c=0xc8):_0x33612c=0xce,_0x5a10a1[_0x1dbc34('0x26')](_0x33612c),_0x5a10a1[_0x1dbc34('0x1d')](_0x1dbc34('0x20'),_0x40a881+'-'+_0x278279+'/'+_0x5727ae)[_0x1dbc34('0x29')](_0x3bb09a);}return null;};}function saveUpdates(_0x60f03d){return function(_0x4af6ae){const _0x28806e=a17_0x5576;if(_0x4af6ae)return _0x4af6ae[_0x28806e('0x12')](_0x60f03d)['then'](function(_0x2f4c33){return _0x2f4c33;});return null;};}function removeEntity(_0x260163){return function(_0x173d4e){const _0x41dd84=a17_0x5576;if(_0x173d4e)return _0x173d4e[_0x41dd84('0x1f')]()[_0x41dd84('0x31')](function(){const _0x57ee14=_0x41dd84;_0x260163[_0x57ee14('0x26')](0xcc)[_0x57ee14('0x36')]();});};}function handleEntityNotFound(_0x2f9cc1){return function(_0x90c618){const _0x353d47=a17_0x5576;return!_0x90c618&&_0x2f9cc1[_0x353d47('0x18')](0x194),_0x90c618;};}function handleError(_0x4fa51e,_0x47ea69){return _0x47ea69=_0x47ea69||0x1f4,function(_0x58abfd){const _0x3368f8=a17_0x5576;logger['error'](_0x58abfd['stack']),_0x58abfd[_0x3368f8('0x2f')]&&delete _0x58abfd[_0x3368f8('0x2f')],_0x4fa51e[_0x3368f8('0x26')](_0x47ea69)['send'](_0x58abfd);};}exports[_0x85b1f('0x17')]=function(_0x41dbb2,_0x43a4e6){const _0x3662a9=_0x85b1f;let _0x5948c4={};const _0x36a25d={},_0x2bdf2c={'count':0x0,'rows':[]},_0xf58113=_[_0x3662a9('0x37')](db[_0x3662a9('0x30')]['rawAttributes'],function(_0x101e0d){const _0xfdb3ea=_0x3662a9;return{'name':_0x101e0d['fieldName'],'type':_0x101e0d[_0xfdb3ea('0x4')][_0xfdb3ea('0xe')]};});_0x36a25d[_0x3662a9('0xf')]=_[_0x3662a9('0x37')](_0xf58113,_0x3662a9('0x2f')),_0x36a25d[_0x3662a9('0x1e')]=_[_0x3662a9('0x3')](_0x41dbb2[_0x3662a9('0x1e')]),_0x36a25d[_0x3662a9('0x1c')]=_[_0x3662a9('0x14')](_0x36a25d['model'],_0x36a25d[_0x3662a9('0x1e')]),_0x5948c4[_0x3662a9('0x27')]=_[_0x3662a9('0x14')](_0x36a25d[_0x3662a9('0xf')],qs['fields'](_0x41dbb2[_0x3662a9('0x1e')][_0x3662a9('0x8')])),_0x5948c4[_0x3662a9('0x27')]=_0x5948c4['attributes']['length']?_0x5948c4[_0x3662a9('0x27')]:_0x36a25d['model'];typeof _0x41dbb2[_0x3662a9('0x1e')][_0x3662a9('0x16')]===_0x3662a9('0x13')&&(_0x5948c4[_0x3662a9('0x7')]=qs['limit'](_0x41dbb2['query'][_0x3662a9('0x7')]),_0x5948c4[_0x3662a9('0x2c')]=qs['offset'](_0x41dbb2[_0x3662a9('0x1e')]['offset']));_0x5948c4['order']=qs[_0x3662a9('0x22')](_0x41dbb2['query'][_0x3662a9('0x22')]),_0x5948c4[_0x3662a9('0x10')]=qs[_0x3662a9('0x1c')](_[_0x3662a9('0x1b')](_0x41dbb2['query'],_0x36a25d[_0x3662a9('0x1c')]),_0xf58113);_0x41dbb2[_0x3662a9('0x1e')][_0x3662a9('0x5')]&&(_0x5948c4['where']=_[_0x3662a9('0x35')](_0x5948c4[_0x3662a9('0x10')],{[Op['or']]:_[_0x3662a9('0x37')](_0xf58113,function(_0x2630cd){const _0x148fa9=_0x3662a9;if(_0x2630cd['type']!==_0x148fa9('0x6')){const _0x4e81ed={};return _0x4e81ed[_0x2630cd[_0x148fa9('0x2f')]]={[Op['like']]:'%'+_0x41dbb2['query'][_0x148fa9('0x5')]+'%'},_0x4e81ed;}})}));_0x5948c4=_['merge']({},_0x5948c4,_0x41dbb2[_0x3662a9('0x19')]);const _0x42a806={'where':_0x5948c4[_0x3662a9('0x10')]};return db[_0x3662a9('0x30')][_0x3662a9('0xd')](_0x42a806)[_0x3662a9('0x31')](function(_0x3d65db){const _0x17df60=_0x3662a9;return _0x2bdf2c[_0x17df60('0xd')]=_0x3d65db,_0x41dbb2[_0x17df60('0x1e')]['includeAll']&&(_0x5948c4[_0x17df60('0x9')]=[{'all':!![]}]),db[_0x17df60('0x30')][_0x17df60('0x0')](_0x5948c4);})[_0x3662a9('0x31')](function(_0x26ef62){const _0xfe13a2=_0x3662a9;return _0x2bdf2c[_0xfe13a2('0xb')]=_0x26ef62,_0x2bdf2c;})[_0x3662a9('0x31')](respondWithFilteredResult(_0x43a4e6,_0x5948c4))[_0x3662a9('0x21')](handleError(_0x43a4e6,null));},exports[_0x85b1f('0x33')]=function(_0x243326,_0x20ffd1){const _0x488982=_0x85b1f;let _0x2e4b1b={'raw':![],'where':{'id':_0x243326['params']['id']}};const _0x49d387={};return _0x49d387[_0x488982('0xf')]=_['keys'](db['AnalyticFieldReport'][_0x488982('0xc')]),_0x49d387[_0x488982('0x1e')]=_['keys'](_0x243326['query']),_0x49d387[_0x488982('0x1c')]=_['intersection'](_0x49d387[_0x488982('0xf')],_0x49d387[_0x488982('0x1e')]),_0x2e4b1b[_0x488982('0x27')]=_[_0x488982('0x14')](_0x49d387[_0x488982('0xf')],qs[_0x488982('0x8')](_0x243326['query']['fields'])),_0x2e4b1b[_0x488982('0x27')]=_0x2e4b1b[_0x488982('0x27')][_0x488982('0x2e')]?_0x2e4b1b['attributes']:_0x49d387[_0x488982('0xf')],_0x243326[_0x488982('0x1e')]['includeAll']&&(_0x2e4b1b['include']=[{'all':!![]}]),_0x2e4b1b=_[_0x488982('0x35')]({},_0x2e4b1b,_0x243326[_0x488982('0x19')]),db[_0x488982('0x30')][_0x488982('0x11')](_0x2e4b1b)[_0x488982('0x31')](handleEntityNotFound(_0x20ffd1,null))['then'](respondWithResult(_0x20ffd1,null))[_0x488982('0x21')](handleError(_0x20ffd1,null));},exports[_0x85b1f('0x23')]=function(_0x466017,_0xcdd75){const _0x26a118=_0x85b1f;return db[_0x26a118('0x30')][_0x26a118('0x23')](_0x466017['body'],{})[_0x26a118('0x31')](respondWithResult(_0xcdd75,0xc9))['catch'](handleError(_0xcdd75,null));},exports[_0x85b1f('0x28')]=function(_0xa668fa,_0x2cf3fe){const _0x383f93=_0x85b1f;return db[_0x383f93('0x30')][_0x383f93('0x28')](_0xa668fa[_0x383f93('0x2d')],{'raw':![],'individualHooks':!![]})[_0x383f93('0x31')](respondWithResult(_0x2cf3fe,0xc9))[_0x383f93('0x21')](handleError(_0x2cf3fe,null));},exports['update']=function(_0x56441e,_0x5d52ed){const _0x51123a=_0x85b1f;return _0x56441e[_0x51123a('0x2d')]['id']&&delete _0x56441e[_0x51123a('0x2d')]['id'],db['AnalyticFieldReport'][_0x51123a('0x11')]({'where':{'id':_0x56441e['params']['id']}})[_0x51123a('0x31')](handleEntityNotFound(_0x5d52ed,null))[_0x51123a('0x31')](saveUpdates(_0x56441e[_0x51123a('0x2d')],null))[_0x51123a('0x31')](respondWithResult(_0x5d52ed,null))[_0x51123a('0x21')](handleError(_0x5d52ed,null));},exports[_0x85b1f('0x1f')]=function(_0x351d8b,_0xb3650f){const _0x1b7a65=_0x85b1f;return db[_0x1b7a65('0x30')][_0x1b7a65('0x11')]({'where':{'id':_0x351d8b['params']['id']}})[_0x1b7a65('0x31')](handleEntityNotFound(_0xb3650f,null))['then'](removeEntity(_0xb3650f,null))[_0x1b7a65('0x21')](handleError(_0xb3650f,null));},exports['bulkDestroy']=function(_0x3737f1,_0x26043e){const _0x483632=_0x85b1f;return db[_0x483632('0x30')][_0x483632('0x1f')]({'where':{'id':_0x3737f1[_0x483632('0x1e')][_0x483632('0x2')]||[]},'raw':![],'individualHooks':!![]})['then'](respondWithResult(_0x26043e,0xcc))['catch'](handleError(_0x26043e,null));},exports[_0x85b1f('0x2b')]=function(_0x3ac7f6,_0x3a5eb7){const _0x4591fc=_0x85b1f;return db[_0x4591fc('0x1a')]['findOne']({'where':{'id':_0x3ac7f6[_0x4591fc('0x15')]['id']}})[_0x4591fc('0x31')](handleEntityNotFound(_0x3a5eb7,null))[_0x4591fc('0x31')](function(_0x1b0dc1){const _0x122836=_0x4591fc;if(_0x1b0dc1)return db[_0x122836('0xa')]['transaction'](function(_0x16886a){const _0x1f0e69=_0x122836;return db['AnalyticFieldReport'][_0x1f0e69('0x1f')]({'where':{'CustomReportId':_0x3ac7f6[_0x1f0e69('0x15')]['id']},'transaction':_0x16886a})[_0x1f0e69('0x31')](function(){const _0x205ac1=_0x1f0e69,_0x59ba3d=_[_0x205ac1('0x37')](_0x3ac7f6['body'],function(_0x339880){const _0x1bbc2c=_0x205ac1;return delete _0x339880['id'],_0x339880[_0x1bbc2c('0x1')]=_0x3ac7f6['params']['id'],_0x339880;});return db['AnalyticFieldReport']['bulkCreate'](_0x59ba3d,{'transaction':_0x16886a});});})[_0x122836('0x31')](function(){const _0x439bc8=_0x122836;return db[_0x439bc8('0x30')][_0x439bc8('0x0')]({'where':{'CustomReportId':_0x3ac7f6[_0x439bc8('0x15')]['id']}});});})['then'](respondWithResult(_0x3a5eb7,null))[_0x4591fc('0x21')](handleError(_0x3a5eb7,null));}; \ No newline at end of file +const a17_0x4413=['sequelize','CustomReportId','like','send','filters','findAll','fieldName','catch','set','update','length','intersection','name','json','AnalyticCustomReport','error','../../config/logger','model','create','where','ids','undefined','type','keys','filter','count','fields','include','sort','rawAttributes','offset','body','options','bulkCreate','../../mysqldb','status','map','findOne','pick','params','index','VIRTUAL','rows','Content-Range','AnalyticFieldReport','then','../../components/parsers/qs','includeAll','stack','end','attributes','merge','destroy','lodash','key','bulkDestroy','query','limit'];(function(_0x16d7b1,_0x441374){const _0x3cb3a3=function(_0x1c26a7){while(--_0x1c26a7){_0x16d7b1['push'](_0x16d7b1['shift']());}};_0x3cb3a3(++_0x441374);}(a17_0x4413,0x1c2));const a17_0x3cb3=function(_0x16d7b1,_0x441374){_0x16d7b1=_0x16d7b1-0x0;let _0x3cb3a3=a17_0x4413[_0x16d7b1];return _0x3cb3a3;};const _0x43896a=a17_0x3cb3;'use strict';const _=require(_0x43896a('0x9')),qs=require(_0x43896a('0x2')),logger=require(_0x43896a('0x1e'))('api'),db=require(_0x43896a('0x30'))['db'],{Op}=require(_0x43896a('0xe'));function respondWithResult(_0x1c26a7,_0x3bf775){return _0x3bf775=_0x3bf775||0xc8,function(_0x1be007){const _0x48f924=a17_0x3cb3;if(_0x1be007)return _0x1c26a7['status'](_0x3bf775)[_0x48f924('0x1b')](_0x1be007);};}function respondWithFilteredResult(_0x27f9bc,_0x443454){return function(_0x4bc0f6){const _0x4c7899=a17_0x3cb3;if(_0x4bc0f6){const _0x52dcdf=_0x4bc0f6[_0x4c7899('0x27')],_0x28e522=_0x443454[_0x4c7899('0x2c')];let _0x4b5d50=_0x443454[_0x4c7899('0x2c')]+_0x443454[_0x4c7899('0xd')],_0x108e54;return _0x4b5d50>=_0x52dcdf?(_0x4b5d50=_0x52dcdf,_0x108e54=0xc8):_0x108e54=0xce,_0x27f9bc['status'](_0x108e54),_0x27f9bc[_0x4c7899('0x16')](_0x4c7899('0x39'),_0x28e522+'-'+_0x4b5d50+'/'+_0x52dcdf)[_0x4c7899('0x1b')](_0x4bc0f6);}return null;};}function saveUpdates(_0x4f6407){return function(_0x228d4a){const _0x2fbf7d=a17_0x3cb3;if(_0x228d4a)return _0x228d4a[_0x2fbf7d('0x17')](_0x4f6407)[_0x2fbf7d('0x1')](function(_0x1ef01e){return _0x1ef01e;});return null;};}function removeEntity(_0x188842){return function(_0x1fb848){const _0x34b4ad=a17_0x3cb3;if(_0x1fb848)return _0x1fb848[_0x34b4ad('0x8')]()[_0x34b4ad('0x1')](function(){const _0x45de2b=_0x34b4ad;_0x188842[_0x45de2b('0x31')](0xcc)[_0x45de2b('0x5')]();});};}function handleEntityNotFound(_0x5e95d1){return function(_0x419106){return!_0x419106&&_0x5e95d1['sendStatus'](0x194),_0x419106;};}function handleError(_0x111a62,_0x1d2662){return _0x1d2662=_0x1d2662||0x1f4,function(_0x4b93d9){const _0x4c77ba=a17_0x3cb3;logger[_0x4c77ba('0x1d')](_0x4b93d9[_0x4c77ba('0x4')]),_0x4b93d9['name']&&delete _0x4b93d9[_0x4c77ba('0x1a')],_0x111a62[_0x4c77ba('0x31')](_0x1d2662)[_0x4c77ba('0x11')](_0x4b93d9);};}exports[_0x43896a('0x36')]=function(_0x2b7e0e,_0x26b715){const _0x16dd15=_0x43896a;let _0xbe728e={};const _0x51f37b={},_0x52c44b={'count':0x0,'rows':[]},_0x32b015=_['map'](db[_0x16dd15('0x0')][_0x16dd15('0x2b')],function(_0x1bbd45){const _0x17d278=_0x16dd15;return{'name':_0x1bbd45[_0x17d278('0x14')],'type':_0x1bbd45['type'][_0x17d278('0xa')]};});_0x51f37b['model']=_[_0x16dd15('0x32')](_0x32b015,_0x16dd15('0x1a')),_0x51f37b['query']=_[_0x16dd15('0x25')](_0x2b7e0e[_0x16dd15('0xc')]),_0x51f37b[_0x16dd15('0x12')]=_[_0x16dd15('0x19')](_0x51f37b[_0x16dd15('0x1f')],_0x51f37b[_0x16dd15('0xc')]),_0xbe728e[_0x16dd15('0x6')]=_['intersection'](_0x51f37b['model'],qs[_0x16dd15('0x28')](_0x2b7e0e['query'][_0x16dd15('0x28')])),_0xbe728e[_0x16dd15('0x6')]=_0xbe728e[_0x16dd15('0x6')][_0x16dd15('0x18')]?_0xbe728e[_0x16dd15('0x6')]:_0x51f37b[_0x16dd15('0x1f')];typeof _0x2b7e0e[_0x16dd15('0xc')]['nolimit']===_0x16dd15('0x23')&&(_0xbe728e['limit']=qs[_0x16dd15('0xd')](_0x2b7e0e[_0x16dd15('0xc')][_0x16dd15('0xd')]),_0xbe728e[_0x16dd15('0x2c')]=qs[_0x16dd15('0x2c')](_0x2b7e0e[_0x16dd15('0xc')][_0x16dd15('0x2c')]));_0xbe728e['order']=qs[_0x16dd15('0x2a')](_0x2b7e0e[_0x16dd15('0xc')][_0x16dd15('0x2a')]),_0xbe728e[_0x16dd15('0x21')]=qs['filters'](_[_0x16dd15('0x34')](_0x2b7e0e[_0x16dd15('0xc')],_0x51f37b[_0x16dd15('0x12')]),_0x32b015);_0x2b7e0e[_0x16dd15('0xc')][_0x16dd15('0x26')]&&(_0xbe728e['where']=_[_0x16dd15('0x7')](_0xbe728e[_0x16dd15('0x21')],{[Op['or']]:_[_0x16dd15('0x32')](_0x32b015,function(_0x577412){const _0x4cb4ff=_0x16dd15;if(_0x577412[_0x4cb4ff('0x24')]!==_0x4cb4ff('0x37')){const _0x8868fe={};return _0x8868fe[_0x577412[_0x4cb4ff('0x1a')]]={[Op[_0x4cb4ff('0x10')]]:'%'+_0x2b7e0e[_0x4cb4ff('0xc')][_0x4cb4ff('0x26')]+'%'},_0x8868fe;}})}));_0xbe728e=_[_0x16dd15('0x7')]({},_0xbe728e,_0x2b7e0e[_0x16dd15('0x2e')]);const _0xb38022={'where':_0xbe728e[_0x16dd15('0x21')]};return db[_0x16dd15('0x0')][_0x16dd15('0x27')](_0xb38022)[_0x16dd15('0x1')](function(_0x2fe7f0){const _0x27694a=_0x16dd15;return _0x52c44b['count']=_0x2fe7f0,_0x2b7e0e[_0x27694a('0xc')][_0x27694a('0x3')]&&(_0xbe728e[_0x27694a('0x29')]=[{'all':!![]}]),db[_0x27694a('0x0')][_0x27694a('0x13')](_0xbe728e);})[_0x16dd15('0x1')](function(_0x24d9a0){const _0x41f14c=_0x16dd15;return _0x52c44b[_0x41f14c('0x38')]=_0x24d9a0,_0x52c44b;})[_0x16dd15('0x1')](respondWithFilteredResult(_0x26b715,_0xbe728e))[_0x16dd15('0x15')](handleError(_0x26b715,null));},exports['show']=function(_0x4fd686,_0x239daf){const _0x2715b1=_0x43896a;let _0x257e0c={'raw':![],'where':{'id':_0x4fd686[_0x2715b1('0x35')]['id']}};const _0x17e0c8={};return _0x17e0c8[_0x2715b1('0x1f')]=_['keys'](db[_0x2715b1('0x0')][_0x2715b1('0x2b')]),_0x17e0c8[_0x2715b1('0xc')]=_[_0x2715b1('0x25')](_0x4fd686['query']),_0x17e0c8[_0x2715b1('0x12')]=_[_0x2715b1('0x19')](_0x17e0c8[_0x2715b1('0x1f')],_0x17e0c8['query']),_0x257e0c[_0x2715b1('0x6')]=_['intersection'](_0x17e0c8[_0x2715b1('0x1f')],qs[_0x2715b1('0x28')](_0x4fd686[_0x2715b1('0xc')][_0x2715b1('0x28')])),_0x257e0c['attributes']=_0x257e0c[_0x2715b1('0x6')][_0x2715b1('0x18')]?_0x257e0c[_0x2715b1('0x6')]:_0x17e0c8[_0x2715b1('0x1f')],_0x4fd686[_0x2715b1('0xc')][_0x2715b1('0x3')]&&(_0x257e0c['include']=[{'all':!![]}]),_0x257e0c=_[_0x2715b1('0x7')]({},_0x257e0c,_0x4fd686[_0x2715b1('0x2e')]),db[_0x2715b1('0x0')]['findOne'](_0x257e0c)['then'](handleEntityNotFound(_0x239daf,null))[_0x2715b1('0x1')](respondWithResult(_0x239daf,null))[_0x2715b1('0x15')](handleError(_0x239daf,null));},exports['create']=function(_0x339492,_0x17b6f7){const _0x37f7b3=_0x43896a;return db[_0x37f7b3('0x0')][_0x37f7b3('0x20')](_0x339492[_0x37f7b3('0x2d')],{})[_0x37f7b3('0x1')](respondWithResult(_0x17b6f7,0xc9))[_0x37f7b3('0x15')](handleError(_0x17b6f7,null));},exports[_0x43896a('0x2f')]=function(_0x9ff361,_0x3ff819){const _0x49cd1d=_0x43896a;return db[_0x49cd1d('0x0')][_0x49cd1d('0x2f')](_0x9ff361['body'],{'raw':![],'individualHooks':!![]})[_0x49cd1d('0x1')](respondWithResult(_0x3ff819,0xc9))[_0x49cd1d('0x15')](handleError(_0x3ff819,null));},exports['update']=function(_0x589edd,_0x4b8652){const _0xed8512=_0x43896a;return _0x589edd[_0xed8512('0x2d')]['id']&&delete _0x589edd[_0xed8512('0x2d')]['id'],db['AnalyticFieldReport'][_0xed8512('0x33')]({'where':{'id':_0x589edd[_0xed8512('0x35')]['id']}})[_0xed8512('0x1')](handleEntityNotFound(_0x4b8652,null))[_0xed8512('0x1')](saveUpdates(_0x589edd[_0xed8512('0x2d')],null))[_0xed8512('0x1')](respondWithResult(_0x4b8652,null))['catch'](handleError(_0x4b8652,null));},exports[_0x43896a('0x8')]=function(_0x1d7648,_0x202a22){const _0x119937=_0x43896a;return db[_0x119937('0x0')][_0x119937('0x33')]({'where':{'id':_0x1d7648['params']['id']}})[_0x119937('0x1')](handleEntityNotFound(_0x202a22,null))['then'](removeEntity(_0x202a22,null))[_0x119937('0x15')](handleError(_0x202a22,null));},exports[_0x43896a('0xb')]=function(_0x2bc02a,_0x5cf556){const _0x429efa=_0x43896a;return db[_0x429efa('0x0')][_0x429efa('0x8')]({'where':{'id':_0x2bc02a[_0x429efa('0xc')][_0x429efa('0x22')]||[]},'raw':![],'individualHooks':!![]})[_0x429efa('0x1')](respondWithResult(_0x5cf556,0xcc))['catch'](handleError(_0x5cf556,null));},exports['addFields']=function(_0x330366,_0xa025e8){const _0x1fc0fd=_0x43896a;return db[_0x1fc0fd('0x1c')][_0x1fc0fd('0x33')]({'where':{'id':_0x330366['params']['id']}})['then'](handleEntityNotFound(_0xa025e8,null))['then'](function(_0x36de41){const _0x5adf93=_0x1fc0fd;if(_0x36de41)return db[_0x5adf93('0xe')]['transaction'](function(_0x12a477){const _0x6ff37c=_0x5adf93;return db[_0x6ff37c('0x0')]['destroy']({'where':{'CustomReportId':_0x330366[_0x6ff37c('0x35')]['id']},'transaction':_0x12a477})[_0x6ff37c('0x1')](function(){const _0x57118e=_0x6ff37c,_0x36d5bd=_[_0x57118e('0x32')](_0x330366['body'],function(_0x3ab0e4){const _0x49ffc0=_0x57118e;return delete _0x3ab0e4['id'],_0x3ab0e4[_0x49ffc0('0xf')]=_0x330366['params']['id'],_0x3ab0e4;});return db[_0x57118e('0x0')]['bulkCreate'](_0x36d5bd,{'transaction':_0x12a477});});})[_0x5adf93('0x1')](function(){const _0x53c566=_0x5adf93;return db[_0x53c566('0x0')][_0x53c566('0x13')]({'where':{'CustomReportId':_0x330366[_0x53c566('0x35')]['id']}});});})['then'](respondWithResult(_0xa025e8,null))[_0x1fc0fd('0x15')](handleError(_0xa025e8,null));}; \ No newline at end of file diff --git a/server/api/analyticFieldReport/analyticFieldReport.model.js b/server/api/analyticFieldReport/analyticFieldReport.model.js index 9d5247c..42c43a6 100644 --- a/server/api/analyticFieldReport/analyticFieldReport.model.js +++ b/server/api/analyticFieldReport/analyticFieldReport.model.js @@ -1 +1 @@ -const a18_0x3b00=['./analyticFieldReport.attributes','define','exports','analytics_report_fields'];(function(_0x5e1643,_0x3b0024){const _0x1420d0=function(_0x4aa8e3){while(--_0x4aa8e3){_0x5e1643['push'](_0x5e1643['shift']());}};_0x1420d0(++_0x3b0024);}(a18_0x3b00,0x1ce));const a18_0x1420=function(_0x5e1643,_0x3b0024){_0x5e1643=_0x5e1643-0x0;let _0x1420d0=a18_0x3b00[_0x5e1643];return _0x1420d0;};const _0x163baf=a18_0x1420;'use strict';const attributes=require(_0x163baf('0x2'));module[_0x163baf('0x0')]=function(_0x4aa8e3){const _0x1e3937=_0x163baf,_0x590d85=_0x4aa8e3[_0x1e3937('0x3')]('AnalyticFieldReport',attributes,{'tableName':_0x1e3937('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x590d85;}; \ No newline at end of file +const a18_0x467f=['exports','AnalyticFieldReport','define','./analyticFieldReport.attributes','analytics_report_fields'];(function(_0x5e2e79,_0x467f82){const _0x395e47=function(_0x2d31d9){while(--_0x2d31d9){_0x5e2e79['push'](_0x5e2e79['shift']());}};_0x395e47(++_0x467f82);}(a18_0x467f,0xaf));const a18_0x395e=function(_0x5e2e79,_0x467f82){_0x5e2e79=_0x5e2e79-0x0;let _0x395e47=a18_0x467f[_0x5e2e79];return _0x395e47;};const _0x464280=a18_0x395e;'use strict';const attributes=require(_0x464280('0x3'));module[_0x464280('0x0')]=function(_0x2d31d9){const _0x33b724=_0x464280,_0x2d4e6a=_0x2d31d9[_0x33b724('0x2')](_0x33b724('0x1'),attributes,{'tableName':_0x33b724('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2d4e6a;}; \ No newline at end of file diff --git a/server/api/analyticFieldReport/index.js b/server/api/analyticFieldReport/index.js index 8988e14..2b2f99f 100644 --- a/server/api/analyticFieldReport/index.js +++ b/server/api/analyticFieldReport/index.js @@ -1 +1 @@ -const a19_0x4084=['bulkDestroy','./analyticFieldReport.controller','isAuthenticated','post','express','update','destroy','delete','bulkCreate','get','exports','index','show','put','/create_many','/destroy_many','/:id'];(function(_0x4fb2cf,_0x408402){const _0x2dd110=function(_0x12942e){while(--_0x12942e){_0x4fb2cf['push'](_0x4fb2cf['shift']());}};_0x2dd110(++_0x408402);}(a19_0x4084,0xe3));const a19_0x2dd1=function(_0x4fb2cf,_0x408402){_0x4fb2cf=_0x4fb2cf-0x0;let _0x2dd110=a19_0x4084[_0x4fb2cf];return _0x2dd110;};const _0x23d638=a19_0x2dd1;'use strict';const express=require(_0x23d638('0xf')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x23d638('0xc'));router[_0x23d638('0x3')]('/',auth[_0x23d638('0xd')](),controller[_0x23d638('0x5')]),router[_0x23d638('0x3')]('/:id',auth['isAuthenticated'](),controller[_0x23d638('0x6')]),router['post']('/',auth[_0x23d638('0xd')](),controller['create']),router[_0x23d638('0xe')](_0x23d638('0x8'),auth['isAuthenticated'](),controller[_0x23d638('0x2')]),router[_0x23d638('0xe')]('/:id/create_many',auth[_0x23d638('0xd')](),controller['addFields']),router[_0x23d638('0x7')](_0x23d638('0xa'),auth['isAuthenticated'](),controller[_0x23d638('0x10')]),router['delete'](_0x23d638('0x9'),auth[_0x23d638('0xd')](),controller[_0x23d638('0xb')]),router[_0x23d638('0x1')]('/:id',auth['isAuthenticated'](),controller[_0x23d638('0x0')]),module[_0x23d638('0x4')]=router; \ No newline at end of file +const a19_0x5a51=['addFields','./analyticFieldReport.controller','post','/destroy_many','express','delete','isAuthenticated','../../components/auth/service','put','update','create','Router','show','index','exports','get','bulkCreate','bulkDestroy','/:id'];(function(_0x4d390b,_0x5a5193){const _0xaf8eab=function(_0xcd38a4){while(--_0xcd38a4){_0x4d390b['push'](_0x4d390b['shift']());}};_0xaf8eab(++_0x5a5193);}(a19_0x5a51,0xd1));const a19_0xaf8e=function(_0x4d390b,_0x5a5193){_0x4d390b=_0x4d390b-0x0;let _0xaf8eab=a19_0x5a51[_0x4d390b];return _0xaf8eab;};const _0xf3c018=a19_0xaf8e;'use strict';const express=require(_0xf3c018('0x4')),router=express[_0xf3c018('0xb')](),auth=require(_0xf3c018('0x7')),controller=require(_0xf3c018('0x1'));router[_0xf3c018('0xf')]('/',auth['isAuthenticated'](),controller[_0xf3c018('0xd')]),router[_0xf3c018('0xf')](_0xf3c018('0x12'),auth[_0xf3c018('0x6')](),controller[_0xf3c018('0xc')]),router[_0xf3c018('0x2')]('/',auth[_0xf3c018('0x6')](),controller[_0xf3c018('0xa')]),router[_0xf3c018('0x2')]('/create_many',auth[_0xf3c018('0x6')](),controller[_0xf3c018('0x10')]),router[_0xf3c018('0x2')]('/:id/create_many',auth[_0xf3c018('0x6')](),controller[_0xf3c018('0x0')]),router[_0xf3c018('0x8')](_0xf3c018('0x12'),auth[_0xf3c018('0x6')](),controller[_0xf3c018('0x9')]),router[_0xf3c018('0x5')](_0xf3c018('0x3'),auth[_0xf3c018('0x6')](),controller[_0xf3c018('0x11')]),router[_0xf3c018('0x5')](_0xf3c018('0x12'),auth[_0xf3c018('0x6')](),controller['destroy']),module[_0xf3c018('0xe')]=router; \ No newline at end of file diff --git a/server/api/analyticMetric/analyticMetric.attributes.js b/server/api/analyticMetric/analyticMetric.attributes.js index ba75aa2..19e56cc 100644 --- a/server/api/analyticMetric/analyticMetric.attributes.js +++ b/server/api/analyticMetric/analyticMetric.attributes.js @@ -1 +1 @@ -const a20_0x31e2=['name','STRING','sequelize','exports'];(function(_0x3d65e7,_0x31e2ee){const _0x1df6d4=function(_0x26f412){while(--_0x26f412){_0x3d65e7['push'](_0x3d65e7['shift']());}};_0x1df6d4(++_0x31e2ee);}(a20_0x31e2,0x108));const a20_0x1df6=function(_0x3d65e7,_0x31e2ee){_0x3d65e7=_0x3d65e7-0x0;let _0x1df6d4=a20_0x31e2[_0x3d65e7];return _0x1df6d4;};const _0x48503f=a20_0x1df6;'use strict';const Sequelize=require(_0x48503f('0x2'));module[_0x48503f('0x3')]={'name':{'type':Sequelize['STRING'],'allowNull':![],'unique':_0x48503f('0x0')},'table':{'type':Sequelize[_0x48503f('0x1')]},'metric':{'type':Sequelize['TEXT']},'description':{'type':Sequelize[_0x48503f('0x1')]}}; \ No newline at end of file +const a20_0x1667=['sequelize','name','exports','STRING'];(function(_0x4ecf93,_0x1667f8){const _0x2fe82a=function(_0x10ab70){while(--_0x10ab70){_0x4ecf93['push'](_0x4ecf93['shift']());}};_0x2fe82a(++_0x1667f8);}(a20_0x1667,0x101));const a20_0x2fe8=function(_0x4ecf93,_0x1667f8){_0x4ecf93=_0x4ecf93-0x0;let _0x2fe82a=a20_0x1667[_0x4ecf93];return _0x2fe82a;};const _0xc99224=a20_0x2fe8;'use strict';const Sequelize=require(_0xc99224('0x3'));module[_0xc99224('0x1')]={'name':{'type':Sequelize[_0xc99224('0x2')],'allowNull':![],'unique':_0xc99224('0x0')},'table':{'type':Sequelize[_0xc99224('0x2')]},'metric':{'type':Sequelize['TEXT']},'description':{'type':Sequelize[_0xc99224('0x2')]}}; \ No newline at end of file diff --git a/server/api/analyticMetric/analyticMetric.controller.js b/server/api/analyticMetric/analyticMetric.controller.js index 0c7ddd7..5788912 100644 --- a/server/api/analyticMetric/analyticMetric.controller.js +++ b/server/api/analyticMetric/analyticMetric.controller.js @@ -1 +1 @@ -const a21_0x6086=['length','pick','offset','error','filters','undefined','get','status','autoAssociation','set','map','count','type','merge','lodash','catch','intersection','sort','stack','update','send','name','attributes','findOne','like','limit','includeAll','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','rawAttributes','UserProfileResource','end','sendStatus','sequelize','where','query','Content-Range','AnalyticMetric','body','filter','json','keys','api','rows','key','index','include','user','params','nolimit','VIRTUAL','options','fields','Metrics','then','model','create','order','destroy','../../mysqldb'];(function(_0x12a100,_0x6086b8){const _0x5a5b66=function(_0x481623){while(--_0x481623){_0x12a100['push'](_0x12a100['shift']());}};_0x5a5b66(++_0x6086b8);}(a21_0x6086,0x196));const a21_0x5a5b=function(_0x12a100,_0x6086b8){_0x12a100=_0x12a100-0x0;let _0x5a5b66=a21_0x6086[_0x12a100];return _0x5a5b66;};const _0x29c709=a21_0x5a5b;'use strict';const _=require(_0x29c709('0x15')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x29c709('0x30')),db=require(_0x29c709('0x6'))['db'],{Op}=require(_0x29c709('0x27'));function respondWithResult(_0x481623,_0x49c9de){return _0x49c9de=_0x49c9de||0xc8,function(_0x1a8ca9){const _0x34ee01=a21_0x5a5b;if(_0x1a8ca9)return _0x481623[_0x34ee01('0xe')](_0x49c9de)[_0x34ee01('0x2e')](_0x1a8ca9);};}function respondWithFilteredResult(_0x200922,_0x32284a){return function(_0x143b3f){const _0x43a01d=a21_0x5a5b;if(_0x143b3f){const _0x306837=_0x143b3f['count'],_0x510e85=_0x32284a[_0x43a01d('0x9')];let _0x112ab6=_0x32284a[_0x43a01d('0x9')]+_0x32284a[_0x43a01d('0x20')],_0x31fb44;return _0x112ab6>=_0x306837?(_0x112ab6=_0x306837,_0x31fb44=0xc8):_0x31fb44=0xce,_0x200922[_0x43a01d('0xe')](_0x31fb44),_0x200922[_0x43a01d('0x10')](_0x43a01d('0x2a'),_0x510e85+'-'+_0x112ab6+'/'+_0x306837)[_0x43a01d('0x2e')](_0x143b3f);}return null;};}function saveUpdates(_0x3beec2){return function(_0x15d782){const _0x5aed9e=a21_0x5a5b;if(_0x15d782)return _0x15d782[_0x5aed9e('0x1a')](_0x3beec2)[_0x5aed9e('0x1')](function(_0x3d0c83){return _0x3d0c83;});return null;};}function removeEntity(_0x57a53f){return function(_0x1a0a3f){const _0x243da4=a21_0x5a5b;if(_0x1a0a3f)return _0x1a0a3f[_0x243da4('0x5')]()[_0x243da4('0x1')](function(){const _0x5950a5=_0x243da4,_0x57fe59=_0x1a0a3f['get']({'plain':!![]}),_0x2ff27f=_0x5950a5('0x0');return db['UserProfileResource'][_0x5950a5('0x5')]({'where':{'type':_0x2ff27f,'resourceId':_0x57fe59['id']}})['then'](function(){return _0x1a0a3f;});})[_0x243da4('0x1')](function(){const _0x5050a4=_0x243da4;_0x57a53f[_0x5050a4('0xe')](0xcc)[_0x5050a4('0x25')]();});};}function handleEntityNotFound(_0xad5293){return function(_0x111381){const _0x465208=a21_0x5a5b;return!_0x111381&&_0xad5293[_0x465208('0x26')](0x194),_0x111381;};}function handleError(_0x1e3d63,_0x2abf0b){return _0x2abf0b=_0x2abf0b||0x1f4,function(_0x931080){const _0x38bb18=a21_0x5a5b;logger['error'](_0x931080[_0x38bb18('0x19')]),_0x931080['name']&&delete _0x931080[_0x38bb18('0x1c')],_0x1e3d63['status'](_0x2abf0b)[_0x38bb18('0x1b')](_0x931080);};}exports[_0x29c709('0x33')]=function(_0x3b40df,_0x28a799){const _0x4dcbb0=_0x29c709;let _0x3267cd={};const _0x51e732={},_0x4c962a={'count':0x0,'rows':[]},_0x59d242=_[_0x4dcbb0('0x11')](db[_0x4dcbb0('0x2b')][_0x4dcbb0('0x23')],function(_0x41c312){const _0x9e6da4=_0x4dcbb0;return{'name':_0x41c312['fieldName'],'type':_0x41c312['type'][_0x9e6da4('0x32')]};});_0x51e732[_0x4dcbb0('0x2')]=_[_0x4dcbb0('0x11')](_0x59d242,_0x4dcbb0('0x1c')),_0x51e732[_0x4dcbb0('0x29')]=_['keys'](_0x3b40df['query']),_0x51e732[_0x4dcbb0('0xb')]=_[_0x4dcbb0('0x17')](_0x51e732['model'],_0x51e732['query']),_0x3267cd[_0x4dcbb0('0x1d')]=_[_0x4dcbb0('0x17')](_0x51e732['model'],qs[_0x4dcbb0('0x3a')](_0x3b40df[_0x4dcbb0('0x29')]['fields'])),_0x3267cd[_0x4dcbb0('0x1d')]=_0x3267cd['attributes'][_0x4dcbb0('0x7')]?_0x3267cd[_0x4dcbb0('0x1d')]:_0x51e732[_0x4dcbb0('0x2')];typeof _0x3b40df[_0x4dcbb0('0x29')][_0x4dcbb0('0x37')]===_0x4dcbb0('0xc')&&(_0x3267cd[_0x4dcbb0('0x20')]=qs[_0x4dcbb0('0x20')](_0x3b40df[_0x4dcbb0('0x29')][_0x4dcbb0('0x20')]),_0x3267cd[_0x4dcbb0('0x9')]=qs[_0x4dcbb0('0x9')](_0x3b40df[_0x4dcbb0('0x29')][_0x4dcbb0('0x9')]));_0x3267cd[_0x4dcbb0('0x4')]=qs[_0x4dcbb0('0x18')](_0x3b40df[_0x4dcbb0('0x29')]['sort']),_0x3267cd['where']=qs[_0x4dcbb0('0xb')](_[_0x4dcbb0('0x8')](_0x3b40df[_0x4dcbb0('0x29')],_0x51e732['filters']),_0x59d242);_0x3b40df['query'][_0x4dcbb0('0x2d')]&&(_0x3267cd[_0x4dcbb0('0x28')]=_[_0x4dcbb0('0x14')](_0x3267cd[_0x4dcbb0('0x28')],{[Op['or']]:_['map'](_0x59d242,function(_0xc32cdc){const _0x306cea=_0x4dcbb0;if(_0xc32cdc[_0x306cea('0x13')]!==_0x306cea('0x38')){const _0x287c74={};return _0x287c74[_0xc32cdc[_0x306cea('0x1c')]]={[Op[_0x306cea('0x1f')]]:'%'+_0x3b40df['query']['filter']+'%'},_0x287c74;}})}));_0x3267cd=_[_0x4dcbb0('0x14')]({},_0x3267cd,_0x3b40df[_0x4dcbb0('0x39')]);const _0x249d8a={'where':_0x3267cd[_0x4dcbb0('0x28')]};return db[_0x4dcbb0('0x2b')]['count'](_0x249d8a)[_0x4dcbb0('0x1')](function(_0x381280){const _0x277ca7=_0x4dcbb0;return _0x4c962a[_0x277ca7('0x12')]=_0x381280,_0x3b40df[_0x277ca7('0x29')][_0x277ca7('0x21')]&&(_0x3267cd[_0x277ca7('0x34')]=[{'all':!![]}]),db[_0x277ca7('0x2b')]['findAll'](_0x3267cd);})[_0x4dcbb0('0x1')](function(_0x4011a0){const _0x497f1e=_0x4dcbb0;return _0x4c962a[_0x497f1e('0x31')]=_0x4011a0,_0x4c962a;})[_0x4dcbb0('0x1')](respondWithFilteredResult(_0x28a799,_0x3267cd))[_0x4dcbb0('0x16')](handleError(_0x28a799,null));},exports['show']=function(_0x565014,_0x492774){const _0x37a676=_0x29c709;let _0x5567bf={'raw':!![],'where':{'id':_0x565014[_0x37a676('0x36')]['id']}};const _0x5e0312={};return _0x5e0312[_0x37a676('0x2')]=_['keys'](db[_0x37a676('0x2b')][_0x37a676('0x23')]),_0x5e0312[_0x37a676('0x29')]=_[_0x37a676('0x2f')](_0x565014[_0x37a676('0x29')]),_0x5e0312[_0x37a676('0xb')]=_[_0x37a676('0x17')](_0x5e0312[_0x37a676('0x2')],_0x5e0312[_0x37a676('0x29')]),_0x5567bf['attributes']=_[_0x37a676('0x17')](_0x5e0312[_0x37a676('0x2')],qs[_0x37a676('0x3a')](_0x565014[_0x37a676('0x29')]['fields'])),_0x5567bf[_0x37a676('0x1d')]=_0x5567bf[_0x37a676('0x1d')][_0x37a676('0x7')]?_0x5567bf[_0x37a676('0x1d')]:_0x5e0312[_0x37a676('0x2')],_0x565014[_0x37a676('0x29')][_0x37a676('0x21')]&&(_0x5567bf[_0x37a676('0x34')]=[{'all':!![]}]),_0x5567bf=_[_0x37a676('0x14')]({},_0x5567bf,_0x565014[_0x37a676('0x39')]),db[_0x37a676('0x2b')]['findOne'](_0x5567bf)['then'](handleEntityNotFound(_0x492774,null))['then'](respondWithResult(_0x492774,null))[_0x37a676('0x16')](handleError(_0x492774,null));},exports[_0x29c709('0x3')]=function(_0x3823e9,_0x15268d){const _0x3dbdb2=_0x29c709;return db[_0x3dbdb2('0x2b')]['create'](_0x3823e9['body'],{})[_0x3dbdb2('0x1')](function(_0x433a05){const _0xfb74af=_0x3dbdb2,_0x5b5f8e=_0x3823e9['user'][_0xfb74af('0xd')]({'plain':!![]});if(!_0x5b5f8e)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x5b5f8e['role']===_0xfb74af('0x35')){const _0x5e39db=_0x433a05[_0xfb74af('0xd')]({'plain':!![]}),_0x12c915=_0xfb74af('0x0');return db['UserProfileSection'][_0xfb74af('0x1e')]({'where':{'name':_0x12c915,'userProfileId':_0x5b5f8e['userProfileId']},'raw':!![]})['then'](function(_0x121771){const _0x4e0909=_0xfb74af;return _0x121771&&_0x121771[_0x4e0909('0xf')]===0x0?db[_0x4e0909('0x24')][_0x4e0909('0x3')]({'name':_0x5e39db['name'],'resourceId':_0x5e39db['id'],'type':_0x121771[_0x4e0909('0x1c')],'sectionId':_0x121771['id']},{})[_0x4e0909('0x1')](function(){return _0x433a05;}):_0x433a05;})[_0xfb74af('0x16')](function(_0x44af31){const _0x542dff=_0xfb74af;logger[_0x542dff('0xa')](_0x542dff('0x22'),_0x44af31);throw _0x44af31;});}return _0x433a05;})[_0x3dbdb2('0x1')](respondWithResult(_0x15268d,0xc9))['catch'](handleError(_0x15268d,null));},exports[_0x29c709('0x1a')]=function(_0x54f8cb,_0x3f23ff){const _0x1988c3=_0x29c709;return _0x54f8cb['body']['id']&&delete _0x54f8cb[_0x1988c3('0x2c')]['id'],db[_0x1988c3('0x2b')][_0x1988c3('0x1e')]({'where':{'id':_0x54f8cb[_0x1988c3('0x36')]['id']}})[_0x1988c3('0x1')](handleEntityNotFound(_0x3f23ff,null))[_0x1988c3('0x1')](saveUpdates(_0x54f8cb[_0x1988c3('0x2c')],null))[_0x1988c3('0x1')](respondWithResult(_0x3f23ff,null))[_0x1988c3('0x16')](handleError(_0x3f23ff,null));},exports['destroy']=function(_0x308595,_0x239607){const _0x4d1899=_0x29c709;return db[_0x4d1899('0x2b')]['findOne']({'where':{'id':_0x308595[_0x4d1899('0x36')]['id']}})['then'](handleEntityNotFound(_0x239607,null))[_0x4d1899('0x1')](removeEntity(_0x239607,null))['catch'](handleError(_0x239607,null));}; \ No newline at end of file +const a21_0x5bbc=['query','api','status','show','UserProfileSection','AnalyticMetric','attributes','fields','UserProfileResource','where','set','end','../../config/logger','fieldName','then','create','update','includeAll','Unable\x20to\x20retrieve\x20the\x20current\x20user','offset','order','keys','intersection','catch','json','VIRTUAL','pick','user','include','sequelize','merge','length','key','limit','count','type','send','undefined','findOne','index','model','params','destroy','rows','error','Metrics','sort','filter','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','options','map','../../components/parsers/qs','filters','role','get','body','like','name','../../mysqldb'];(function(_0x5cef3e,_0x5bbcf5){const _0x380b40=function(_0x51c4a0){while(--_0x51c4a0){_0x5cef3e['push'](_0x5cef3e['shift']());}};_0x380b40(++_0x5bbcf5);}(a21_0x5bbc,0xb1));const a21_0x380b=function(_0x5cef3e,_0x5bbcf5){_0x5cef3e=_0x5cef3e-0x0;let _0x380b40=a21_0x5bbc[_0x5cef3e];return _0x380b40;};const _0x4c1005=a21_0x380b;'use strict';const _=require('lodash'),qs=require(_0x4c1005('0x33')),logger=require(_0x4c1005('0xc'))(_0x4c1005('0x1')),db=require(_0x4c1005('0x3a'))['db'],{Op}=require(_0x4c1005('0x1d'));function respondWithResult(_0x51c4a0,_0x3d6050){return _0x3d6050=_0x3d6050||0xc8,function(_0x364130){const _0x4f3acc=a21_0x380b;if(_0x364130)return _0x51c4a0[_0x4f3acc('0x2')](_0x3d6050)[_0x4f3acc('0x18')](_0x364130);};}function respondWithFilteredResult(_0x22b7d2,_0x3e23e0){return function(_0x1c1722){const _0x3ede1b=a21_0x380b;if(_0x1c1722){const _0x2fcbc2=_0x1c1722[_0x3ede1b('0x22')],_0x5478d3=_0x3e23e0['offset'];let _0x5143f4=_0x3e23e0['offset']+_0x3e23e0[_0x3ede1b('0x21')],_0x316bf4;return _0x5143f4>=_0x2fcbc2?(_0x5143f4=_0x2fcbc2,_0x316bf4=0xc8):_0x316bf4=0xce,_0x22b7d2[_0x3ede1b('0x2')](_0x316bf4),_0x22b7d2[_0x3ede1b('0xa')]('Content-Range',_0x5478d3+'-'+_0x5143f4+'/'+_0x2fcbc2)[_0x3ede1b('0x18')](_0x1c1722);}return null;};}function saveUpdates(_0x4fa085){return function(_0x5c9ac5){const _0x203cae=a21_0x380b;if(_0x5c9ac5)return _0x5c9ac5[_0x203cae('0x10')](_0x4fa085)[_0x203cae('0xe')](function(_0x4c1cf1){return _0x4c1cf1;});return null;};}function removeEntity(_0x41a0dc){return function(_0x5ce3be){const _0x4c3d66=a21_0x380b;if(_0x5ce3be)return _0x5ce3be['destroy']()[_0x4c3d66('0xe')](function(){const _0xc88836=_0x4c3d66,_0x3a1d3e=_0x5ce3be[_0xc88836('0x36')]({'plain':!![]}),_0x12cb2d=_0xc88836('0x2d');return db[_0xc88836('0x8')][_0xc88836('0x2a')]({'where':{'type':_0x12cb2d,'resourceId':_0x3a1d3e['id']}})[_0xc88836('0xe')](function(){return _0x5ce3be;});})[_0x4c3d66('0xe')](function(){const _0x4ed855=_0x4c3d66;_0x41a0dc[_0x4ed855('0x2')](0xcc)[_0x4ed855('0xb')]();});};}function handleEntityNotFound(_0x5bfdcb){return function(_0x5904b6){return!_0x5904b6&&_0x5bfdcb['sendStatus'](0x194),_0x5904b6;};}function handleError(_0x2d138a,_0xf5ac7d){return _0xf5ac7d=_0xf5ac7d||0x1f4,function(_0x145db1){const _0x111e81=a21_0x380b;logger[_0x111e81('0x2c')](_0x145db1['stack']),_0x145db1[_0x111e81('0x39')]&&delete _0x145db1['name'],_0x2d138a[_0x111e81('0x2')](_0xf5ac7d)[_0x111e81('0x24')](_0x145db1);};}exports[_0x4c1005('0x27')]=function(_0x9ef4d0,_0x5593e6){const _0x2a11ae=_0x4c1005;let _0x3ea947={};const _0x223e1e={},_0x489a96={'count':0x0,'rows':[]},_0x198768=_['map'](db[_0x2a11ae('0x5')]['rawAttributes'],function(_0x462032){const _0x18b155=_0x2a11ae;return{'name':_0x462032[_0x18b155('0xd')],'type':_0x462032[_0x18b155('0x23')][_0x18b155('0x20')]};});_0x223e1e[_0x2a11ae('0x28')]=_[_0x2a11ae('0x32')](_0x198768,_0x2a11ae('0x39')),_0x223e1e[_0x2a11ae('0x0')]=_[_0x2a11ae('0x15')](_0x9ef4d0[_0x2a11ae('0x0')]),_0x223e1e[_0x2a11ae('0x34')]=_[_0x2a11ae('0x16')](_0x223e1e[_0x2a11ae('0x28')],_0x223e1e['query']),_0x3ea947['attributes']=_['intersection'](_0x223e1e[_0x2a11ae('0x28')],qs[_0x2a11ae('0x7')](_0x9ef4d0['query'][_0x2a11ae('0x7')])),_0x3ea947[_0x2a11ae('0x6')]=_0x3ea947[_0x2a11ae('0x6')][_0x2a11ae('0x1f')]?_0x3ea947[_0x2a11ae('0x6')]:_0x223e1e['model'];typeof _0x9ef4d0[_0x2a11ae('0x0')]['nolimit']===_0x2a11ae('0x25')&&(_0x3ea947[_0x2a11ae('0x21')]=qs[_0x2a11ae('0x21')](_0x9ef4d0[_0x2a11ae('0x0')][_0x2a11ae('0x21')]),_0x3ea947[_0x2a11ae('0x13')]=qs[_0x2a11ae('0x13')](_0x9ef4d0[_0x2a11ae('0x0')][_0x2a11ae('0x13')]));_0x3ea947[_0x2a11ae('0x14')]=qs[_0x2a11ae('0x2e')](_0x9ef4d0['query'][_0x2a11ae('0x2e')]),_0x3ea947[_0x2a11ae('0x9')]=qs[_0x2a11ae('0x34')](_[_0x2a11ae('0x1a')](_0x9ef4d0[_0x2a11ae('0x0')],_0x223e1e[_0x2a11ae('0x34')]),_0x198768);_0x9ef4d0[_0x2a11ae('0x0')]['filter']&&(_0x3ea947[_0x2a11ae('0x9')]=_[_0x2a11ae('0x1e')](_0x3ea947['where'],{[Op['or']]:_[_0x2a11ae('0x32')](_0x198768,function(_0x971c94){const _0x558fcc=_0x2a11ae;if(_0x971c94[_0x558fcc('0x23')]!==_0x558fcc('0x19')){const _0x111987={};return _0x111987[_0x971c94['name']]={[Op[_0x558fcc('0x38')]]:'%'+_0x9ef4d0[_0x558fcc('0x0')][_0x558fcc('0x2f')]+'%'},_0x111987;}})}));_0x3ea947=_[_0x2a11ae('0x1e')]({},_0x3ea947,_0x9ef4d0[_0x2a11ae('0x31')]);const _0x33d5f2={'where':_0x3ea947['where']};return db[_0x2a11ae('0x5')]['count'](_0x33d5f2)[_0x2a11ae('0xe')](function(_0x21a7cd){const _0x179e3d=_0x2a11ae;return _0x489a96['count']=_0x21a7cd,_0x9ef4d0['query'][_0x179e3d('0x11')]&&(_0x3ea947[_0x179e3d('0x1c')]=[{'all':!![]}]),db[_0x179e3d('0x5')]['findAll'](_0x3ea947);})['then'](function(_0x57f72b){const _0x684a71=_0x2a11ae;return _0x489a96[_0x684a71('0x2b')]=_0x57f72b,_0x489a96;})[_0x2a11ae('0xe')](respondWithFilteredResult(_0x5593e6,_0x3ea947))[_0x2a11ae('0x17')](handleError(_0x5593e6,null));},exports[_0x4c1005('0x3')]=function(_0x48bdd3,_0x167f83){const _0x862fbd=_0x4c1005;let _0x5d18ab={'raw':!![],'where':{'id':_0x48bdd3['params']['id']}};const _0x451873={};return _0x451873[_0x862fbd('0x28')]=_[_0x862fbd('0x15')](db[_0x862fbd('0x5')]['rawAttributes']),_0x451873[_0x862fbd('0x0')]=_[_0x862fbd('0x15')](_0x48bdd3[_0x862fbd('0x0')]),_0x451873[_0x862fbd('0x34')]=_[_0x862fbd('0x16')](_0x451873[_0x862fbd('0x28')],_0x451873['query']),_0x5d18ab[_0x862fbd('0x6')]=_[_0x862fbd('0x16')](_0x451873[_0x862fbd('0x28')],qs[_0x862fbd('0x7')](_0x48bdd3['query']['fields'])),_0x5d18ab['attributes']=_0x5d18ab[_0x862fbd('0x6')][_0x862fbd('0x1f')]?_0x5d18ab[_0x862fbd('0x6')]:_0x451873[_0x862fbd('0x28')],_0x48bdd3[_0x862fbd('0x0')][_0x862fbd('0x11')]&&(_0x5d18ab['include']=[{'all':!![]}]),_0x5d18ab=_[_0x862fbd('0x1e')]({},_0x5d18ab,_0x48bdd3[_0x862fbd('0x31')]),db[_0x862fbd('0x5')][_0x862fbd('0x26')](_0x5d18ab)[_0x862fbd('0xe')](handleEntityNotFound(_0x167f83,null))['then'](respondWithResult(_0x167f83,null))['catch'](handleError(_0x167f83,null));},exports['create']=function(_0x30ee44,_0x12b38c){const _0x1a5554=_0x4c1005;return db[_0x1a5554('0x5')]['create'](_0x30ee44[_0x1a5554('0x37')],{})[_0x1a5554('0xe')](function(_0x135418){const _0x3b41b5=_0x1a5554,_0x424e39=_0x30ee44[_0x3b41b5('0x1b')][_0x3b41b5('0x36')]({'plain':!![]});if(!_0x424e39)throw new Error(_0x3b41b5('0x12'));if(_0x424e39[_0x3b41b5('0x35')]===_0x3b41b5('0x1b')){const _0x51b19a=_0x135418['get']({'plain':!![]}),_0x1b508f=_0x3b41b5('0x2d');return db[_0x3b41b5('0x4')][_0x3b41b5('0x26')]({'where':{'name':_0x1b508f,'userProfileId':_0x424e39['userProfileId']},'raw':!![]})['then'](function(_0x1fcf04){const _0x30ecbf=_0x3b41b5;return _0x1fcf04&&_0x1fcf04['autoAssociation']===0x0?db[_0x30ecbf('0x8')][_0x30ecbf('0xf')]({'name':_0x51b19a[_0x30ecbf('0x39')],'resourceId':_0x51b19a['id'],'type':_0x1fcf04[_0x30ecbf('0x39')],'sectionId':_0x1fcf04['id']},{})['then'](function(){return _0x135418;}):_0x135418;})['catch'](function(_0x1a35c1){const _0x269ffd=_0x3b41b5;logger[_0x269ffd('0x2c')](_0x269ffd('0x30'),_0x1a35c1);throw _0x1a35c1;});}return _0x135418;})[_0x1a5554('0xe')](respondWithResult(_0x12b38c,0xc9))[_0x1a5554('0x17')](handleError(_0x12b38c,null));},exports[_0x4c1005('0x10')]=function(_0x538c20,_0x53f713){const _0x272227=_0x4c1005;return _0x538c20[_0x272227('0x37')]['id']&&delete _0x538c20[_0x272227('0x37')]['id'],db[_0x272227('0x5')][_0x272227('0x26')]({'where':{'id':_0x538c20[_0x272227('0x29')]['id']}})[_0x272227('0xe')](handleEntityNotFound(_0x53f713,null))[_0x272227('0xe')](saveUpdates(_0x538c20[_0x272227('0x37')],null))[_0x272227('0xe')](respondWithResult(_0x53f713,null))['catch'](handleError(_0x53f713,null));},exports[_0x4c1005('0x2a')]=function(_0x362d3d,_0x3fdec2){const _0x11a942=_0x4c1005;return db['AnalyticMetric']['findOne']({'where':{'id':_0x362d3d[_0x11a942('0x29')]['id']}})['then'](handleEntityNotFound(_0x3fdec2,null))[_0x11a942('0xe')](removeEntity(_0x3fdec2,null))[_0x11a942('0x17')](handleError(_0x3fdec2,null));}; \ No newline at end of file diff --git a/server/api/analyticMetric/analyticMetric.model.js b/server/api/analyticMetric/analyticMetric.model.js index e3ba0fc..bb229e3 100644 --- a/server/api/analyticMetric/analyticMetric.model.js +++ b/server/api/analyticMetric/analyticMetric.model.js @@ -1 +1 @@ -const a22_0x48de=['AnalyticMetric','./analyticMetric.attributes','exports','define','analytics_metrics'];(function(_0x5f0069,_0x48de9f){const _0x30d0f6=function(_0x3db7b4){while(--_0x3db7b4){_0x5f0069['push'](_0x5f0069['shift']());}};_0x30d0f6(++_0x48de9f);}(a22_0x48de,0x105));const a22_0x30d0=function(_0x5f0069,_0x48de9f){_0x5f0069=_0x5f0069-0x0;let _0x30d0f6=a22_0x48de[_0x5f0069];return _0x30d0f6;};const _0x1c4bec=a22_0x30d0;'use strict';const attributes=require(_0x1c4bec('0x0'));module[_0x1c4bec('0x1')]=function(_0x3db7b4){const _0x1edc6d=_0x1c4bec,_0x520a84=_0x3db7b4[_0x1edc6d('0x2')](_0x1edc6d('0x4'),attributes,{'tableName':_0x1edc6d('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x520a84;}; \ No newline at end of file +const a22_0x36ff=['analytics_metrics','./analyticMetric.attributes','exports'];(function(_0x254b82,_0x36ffc6){const _0x5d7ad7=function(_0x4cc6ec){while(--_0x4cc6ec){_0x254b82['push'](_0x254b82['shift']());}};_0x5d7ad7(++_0x36ffc6);}(a22_0x36ff,0x1be));const a22_0x5d7a=function(_0x254b82,_0x36ffc6){_0x254b82=_0x254b82-0x0;let _0x5d7ad7=a22_0x36ff[_0x254b82];return _0x5d7ad7;};const _0x28cc32=a22_0x5d7a;'use strict';const attributes=require(_0x28cc32('0x2'));module[_0x28cc32('0x0')]=function(_0x4cc6ec){const _0x41b291=_0x28cc32,_0x29e337=_0x4cc6ec['define']('AnalyticMetric',attributes,{'tableName':_0x41b291('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x29e337;}; \ No newline at end of file diff --git a/server/api/analyticMetric/index.js b/server/api/analyticMetric/index.js index b00aac8..88f475c 100644 --- a/server/api/analyticMetric/index.js +++ b/server/api/analyticMetric/index.js @@ -1 +1 @@ -const a23_0x1880=['destroy','exports','express','/:id','isAuthenticated','create','put','get','update','Router','index','post','show','../../components/auth/service'];(function(_0x529ac6,_0x18804b){const _0x5dab22=function(_0x450e98){while(--_0x450e98){_0x529ac6['push'](_0x529ac6['shift']());}};_0x5dab22(++_0x18804b);}(a23_0x1880,0x13a));const a23_0x5dab=function(_0x529ac6,_0x18804b){_0x529ac6=_0x529ac6-0x0;let _0x5dab22=a23_0x1880[_0x529ac6];return _0x5dab22;};const _0x4bd557=a23_0x5dab;'use strict';const express=require(_0x4bd557('0xa')),router=express[_0x4bd557('0x3')](),auth=require(_0x4bd557('0x7')),controller=require('./analyticMetric.controller');router[_0x4bd557('0x1')]('/',auth[_0x4bd557('0xc')](),controller[_0x4bd557('0x4')]),router[_0x4bd557('0x1')](_0x4bd557('0xb'),auth[_0x4bd557('0xc')](),controller[_0x4bd557('0x6')]),router[_0x4bd557('0x5')]('/',auth[_0x4bd557('0xc')](),controller[_0x4bd557('0xd')]),router[_0x4bd557('0x0')]('/:id',auth[_0x4bd557('0xc')](),controller[_0x4bd557('0x2')]),router['delete']('/:id',auth[_0x4bd557('0xc')](),controller[_0x4bd557('0x8')]),module[_0x4bd557('0x9')]=router; \ No newline at end of file +const a23_0x5429=['index','create','post','get','exports','isAuthenticated','put','./analyticMetric.controller','update','express','show','/:id'];(function(_0x89a769,_0x5429e9){const _0xfe9506=function(_0x44b41e){while(--_0x44b41e){_0x89a769['push'](_0x89a769['shift']());}};_0xfe9506(++_0x5429e9);}(a23_0x5429,0x67));const a23_0xfe95=function(_0x89a769,_0x5429e9){_0x89a769=_0x89a769-0x0;let _0xfe9506=a23_0x5429[_0x89a769];return _0xfe9506;};const _0x221a8f=a23_0xfe95;'use strict';const express=require(_0x221a8f('0x2')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x221a8f('0x0'));router[_0x221a8f('0x8')]('/',auth[_0x221a8f('0xa')](),controller[_0x221a8f('0x5')]),router['get'](_0x221a8f('0x4'),auth['isAuthenticated'](),controller[_0x221a8f('0x3')]),router[_0x221a8f('0x7')]('/',auth[_0x221a8f('0xa')](),controller[_0x221a8f('0x6')]),router[_0x221a8f('0xb')](_0x221a8f('0x4'),auth[_0x221a8f('0xa')](),controller[_0x221a8f('0x1')]),router['delete'](_0x221a8f('0x4'),auth[_0x221a8f('0xa')](),controller['destroy']),module[_0x221a8f('0x9')]=router; \ No newline at end of file diff --git a/server/api/analyticTreeReport/analyticTreeReport.attributes.js b/server/api/analyticTreeReport/analyticTreeReport.attributes.js index 787aac3..c3973a3 100644 --- a/server/api/analyticTreeReport/analyticTreeReport.attributes.js +++ b/server/api/analyticTreeReport/analyticTreeReport.attributes.js @@ -1 +1 @@ -const a24_0x113d=['exports','sequelize','TEXT'];(function(_0x21c03d,_0x113dc5){const _0x1028aa=function(_0xb30439){while(--_0xb30439){_0x21c03d['push'](_0x21c03d['shift']());}};_0x1028aa(++_0x113dc5);}(a24_0x113d,0x152));const a24_0x1028=function(_0x21c03d,_0x113dc5){_0x21c03d=_0x21c03d-0x0;let _0x1028aa=a24_0x113d[_0x21c03d];return _0x1028aa;};const _0x3a587d=a24_0x1028;'use strict';const Sequelize=require(_0x3a587d('0x2'));module[_0x3a587d('0x1')]={'tree':{'type':Sequelize[_0x3a587d('0x0')],'allowNull':![]}}; \ No newline at end of file +const a24_0x7419=['exports','sequelize'];(function(_0x371364,_0x7419f1){const _0xaf6810=function(_0x2b1813){while(--_0x2b1813){_0x371364['push'](_0x371364['shift']());}};_0xaf6810(++_0x7419f1);}(a24_0x7419,0x1b1));const a24_0xaf68=function(_0x371364,_0x7419f1){_0x371364=_0x371364-0x0;let _0xaf6810=a24_0x7419[_0x371364];return _0xaf6810;};const _0x14796c=a24_0xaf68;'use strict';const Sequelize=require(_0x14796c('0x0'));module[_0x14796c('0x1')]={'tree':{'type':Sequelize['TEXT'],'allowNull':![]}}; \ No newline at end of file diff --git a/server/api/analyticTreeReport/analyticTreeReport.controller.js b/server/api/analyticTreeReport/analyticTreeReport.controller.js index 2b5daf1..eec53b4 100644 --- a/server/api/analyticTreeReport/analyticTreeReport.controller.js +++ b/server/api/analyticTreeReport/analyticTreeReport.controller.js @@ -1 +1 @@ -const a25_0x2726=['json','fieldName','order','key','nolimit','stack','error','pick','name','where','body','sequelize','findAll','status','update','query','send','map','destroy','options','../../mysqldb','includeAll','count','like','offset','intersection','catch','findOne','keys','include','merge','fields','sort','create','lodash','filters','model','params','then','limit','AnalyticTreeReport','set','type','rawAttributes','Content-Range','filter','attributes','show','../../components/parsers/qs'];(function(_0x3c5988,_0x2726a1){const _0x366603=function(_0x5ea575){while(--_0x5ea575){_0x3c5988['push'](_0x3c5988['shift']());}};_0x366603(++_0x2726a1);}(a25_0x2726,0x90));const a25_0x3666=function(_0x3c5988,_0x2726a1){_0x3c5988=_0x3c5988-0x0;let _0x366603=a25_0x2726[_0x3c5988];return _0x366603;};const _0x57f15c=a25_0x3666;'use strict';const _=require(_0x57f15c('0x25')),qs=require(_0x57f15c('0x2')),logger=require('../../config/logger')('api'),db=require(_0x57f15c('0x17'))['db'],{Op}=require(_0x57f15c('0xe'));function respondWithResult(_0x5ea575,_0x2e4f1d){return _0x2e4f1d=_0x2e4f1d||0xc8,function(_0x1339b0){const _0x333727=a25_0x3666;if(_0x1339b0)return _0x5ea575[_0x333727('0x10')](_0x2e4f1d)[_0x333727('0x3')](_0x1339b0);};}function respondWithFilteredResult(_0x5a4e07,_0x33f618){return function(_0x13c96c){const _0x2ed94b=a25_0x3666;if(_0x13c96c){const _0x1fc566=_0x13c96c[_0x2ed94b('0x19')],_0x2a1862=_0x33f618['offset'];let _0x5afc83=_0x33f618[_0x2ed94b('0x1b')]+_0x33f618[_0x2ed94b('0x2a')],_0x44fc23;return _0x5afc83>=_0x1fc566?(_0x5afc83=_0x1fc566,_0x44fc23=0xc8):_0x44fc23=0xce,_0x5a4e07[_0x2ed94b('0x10')](_0x44fc23),_0x5a4e07[_0x2ed94b('0x2c')](_0x2ed94b('0x2f'),_0x2a1862+'-'+_0x5afc83+'/'+_0x1fc566)[_0x2ed94b('0x3')](_0x13c96c);}return null;};}function saveUpdates(_0x11f4d5){return function(_0x40936e){const _0x1993a0=a25_0x3666;if(_0x40936e)return _0x40936e[_0x1993a0('0x11')](_0x11f4d5)[_0x1993a0('0x29')](function(_0x45484e){return _0x45484e;});return null;};}function removeEntity(_0x335d13){return function(_0x161ec6){if(_0x161ec6)return _0x161ec6['destroy']()['then'](function(){const _0x320946=a25_0x3666;_0x335d13[_0x320946('0x10')](0xcc)['end']();});};}function handleEntityNotFound(_0x49c773){return function(_0x5f1a8e){return!_0x5f1a8e&&_0x49c773['sendStatus'](0x194),_0x5f1a8e;};}function handleError(_0x259b90,_0x5c2e3a){return _0x5c2e3a=_0x5c2e3a||0x1f4,function(_0x3949e1){const _0x575459=a25_0x3666;logger[_0x575459('0x9')](_0x3949e1[_0x575459('0x8')]),_0x3949e1[_0x575459('0xb')]&&delete _0x3949e1[_0x575459('0xb')],_0x259b90[_0x575459('0x10')](_0x5c2e3a)[_0x575459('0x13')](_0x3949e1);};}exports['index']=function(_0x230a32,_0x7105b3){const _0x49d448=_0x57f15c;let _0x35c99d={};const _0xc9832={},_0x336929={'count':0x0,'rows':[]},_0x413a00=_[_0x49d448('0x14')](db[_0x49d448('0x2b')]['rawAttributes'],function(_0xde91ba){const _0x13f90b=_0x49d448;return{'name':_0xde91ba[_0x13f90b('0x4')],'type':_0xde91ba[_0x13f90b('0x2d')][_0x13f90b('0x6')]};});_0xc9832[_0x49d448('0x27')]=_['map'](_0x413a00,_0x49d448('0xb')),_0xc9832[_0x49d448('0x12')]=_[_0x49d448('0x1f')](_0x230a32[_0x49d448('0x12')]),_0xc9832[_0x49d448('0x26')]=_[_0x49d448('0x1c')](_0xc9832[_0x49d448('0x27')],_0xc9832[_0x49d448('0x12')]),_0x35c99d[_0x49d448('0x0')]=_[_0x49d448('0x1c')](_0xc9832['model'],qs['fields'](_0x230a32[_0x49d448('0x12')][_0x49d448('0x22')])),_0x35c99d[_0x49d448('0x0')]=_0x35c99d[_0x49d448('0x0')]['length']?_0x35c99d[_0x49d448('0x0')]:_0xc9832[_0x49d448('0x27')];typeof _0x230a32[_0x49d448('0x12')][_0x49d448('0x7')]==='undefined'&&(_0x35c99d[_0x49d448('0x2a')]=qs['limit'](_0x230a32['query']['limit']),_0x35c99d[_0x49d448('0x1b')]=qs[_0x49d448('0x1b')](_0x230a32[_0x49d448('0x12')][_0x49d448('0x1b')]));_0x35c99d[_0x49d448('0x5')]=qs[_0x49d448('0x23')](_0x230a32[_0x49d448('0x12')][_0x49d448('0x23')]),_0x35c99d[_0x49d448('0xc')]=qs[_0x49d448('0x26')](_[_0x49d448('0xa')](_0x230a32[_0x49d448('0x12')],_0xc9832[_0x49d448('0x26')]),_0x413a00);_0x230a32[_0x49d448('0x12')][_0x49d448('0x30')]&&(_0x35c99d[_0x49d448('0xc')]=_[_0x49d448('0x21')](_0x35c99d['where'],{[Op['or']]:_[_0x49d448('0x14')](_0x413a00,function(_0xc38405){const _0x15e3cc=_0x49d448;if(_0xc38405[_0x15e3cc('0x2d')]!=='VIRTUAL'){const _0x15e810={};return _0x15e810[_0xc38405[_0x15e3cc('0xb')]]={[Op[_0x15e3cc('0x1a')]]:'%'+_0x230a32['query'][_0x15e3cc('0x30')]+'%'},_0x15e810;}})}));_0x35c99d=_[_0x49d448('0x21')]({},_0x35c99d,_0x230a32[_0x49d448('0x16')]);const _0x5d239b={'where':_0x35c99d[_0x49d448('0xc')]};return db[_0x49d448('0x2b')][_0x49d448('0x19')](_0x5d239b)['then'](function(_0x404011){const _0x5d9ed5=_0x49d448;return _0x336929[_0x5d9ed5('0x19')]=_0x404011,_0x230a32['query'][_0x5d9ed5('0x18')]&&(_0x35c99d[_0x5d9ed5('0x20')]=[{'all':!![]}]),db[_0x5d9ed5('0x2b')][_0x5d9ed5('0xf')](_0x35c99d);})[_0x49d448('0x29')](function(_0x3718f6){return _0x336929['rows']=_0x3718f6,_0x336929;})[_0x49d448('0x29')](respondWithFilteredResult(_0x7105b3,_0x35c99d))[_0x49d448('0x1d')](handleError(_0x7105b3,null));},exports[_0x57f15c('0x1')]=function(_0x4f0216,_0x4b8469){const _0x38a544=_0x57f15c;let _0x4cfede={'raw':!![],'where':{'id':_0x4f0216[_0x38a544('0x28')]['id']}};const _0x32b662={};return _0x32b662['model']=_['keys'](db['AnalyticTreeReport'][_0x38a544('0x2e')]),_0x32b662[_0x38a544('0x12')]=_[_0x38a544('0x1f')](_0x4f0216[_0x38a544('0x12')]),_0x32b662[_0x38a544('0x26')]=_[_0x38a544('0x1c')](_0x32b662[_0x38a544('0x27')],_0x32b662[_0x38a544('0x12')]),_0x4cfede['attributes']=_[_0x38a544('0x1c')](_0x32b662[_0x38a544('0x27')],qs['fields'](_0x4f0216[_0x38a544('0x12')][_0x38a544('0x22')])),_0x4cfede[_0x38a544('0x0')]=_0x4cfede[_0x38a544('0x0')]['length']?_0x4cfede[_0x38a544('0x0')]:_0x32b662[_0x38a544('0x27')],_0x4f0216[_0x38a544('0x12')][_0x38a544('0x18')]&&(_0x4cfede[_0x38a544('0x20')]=[{'all':!![]}]),_0x4cfede=_[_0x38a544('0x21')]({},_0x4cfede,_0x4f0216[_0x38a544('0x16')]),db[_0x38a544('0x2b')][_0x38a544('0x1e')](_0x4cfede)[_0x38a544('0x29')](handleEntityNotFound(_0x4b8469,null))[_0x38a544('0x29')](respondWithResult(_0x4b8469,null))[_0x38a544('0x1d')](handleError(_0x4b8469,null));},exports[_0x57f15c('0x24')]=function(_0x1d1ea2,_0x30fad9){const _0x4addfc=_0x57f15c;return db[_0x4addfc('0x2b')][_0x4addfc('0x24')](_0x1d1ea2[_0x4addfc('0xd')],{})[_0x4addfc('0x29')](respondWithResult(_0x30fad9,0xc9))[_0x4addfc('0x1d')](handleError(_0x30fad9,null));},exports[_0x57f15c('0x11')]=function(_0x2278dc,_0x209a20){const _0x1144e3=_0x57f15c;return _0x2278dc[_0x1144e3('0xd')]['id']&&delete _0x2278dc[_0x1144e3('0xd')]['id'],db['AnalyticTreeReport'][_0x1144e3('0x1e')]({'where':{'id':_0x2278dc['params']['id']}})['then'](handleEntityNotFound(_0x209a20,null))['then'](saveUpdates(_0x2278dc[_0x1144e3('0xd')],null))[_0x1144e3('0x29')](respondWithResult(_0x209a20,null))[_0x1144e3('0x1d')](handleError(_0x209a20,null));},exports[_0x57f15c('0x15')]=function(_0x76ca6a,_0x57d6a3){const _0x559f02=_0x57f15c;return db[_0x559f02('0x2b')][_0x559f02('0x1e')]({'where':{'id':_0x76ca6a[_0x559f02('0x28')]['id']}})[_0x559f02('0x29')](handleEntityNotFound(_0x57d6a3,null))[_0x559f02('0x29')](removeEntity(_0x57d6a3,null))[_0x559f02('0x1d')](handleError(_0x57d6a3,null));}; \ No newline at end of file +const a25_0x513f=['where','rows','offset','keys','include','params','body','findAll','limit','query','Content-Range','status','index','attributes','nolimit','sequelize','AnalyticTreeReport','update','catch','count','map','../../mysqldb','error','then','merge','type','filters','model','json','show','rawAttributes','findOne','send','VIRTUAL','end','set','sort','fields','includeAll','create','filter','name','intersection','undefined','stack','order','key','../../config/logger'];(function(_0x3fb295,_0x513fa2){const _0x594b10=function(_0xed9031){while(--_0xed9031){_0x3fb295['push'](_0x3fb295['shift']());}};_0x594b10(++_0x513fa2);}(a25_0x513f,0x182));const a25_0x594b=function(_0x3fb295,_0x513fa2){_0x3fb295=_0x3fb295-0x0;let _0x594b10=a25_0x513f[_0x3fb295];return _0x594b10;};const _0x1df59c=a25_0x594b;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x1df59c('0x2d'))('api'),db=require(_0x1df59c('0x13'))['db'],{Op}=require(_0x1df59c('0xd'));function respondWithResult(_0xed9031,_0x40bf2b){return _0x40bf2b=_0x40bf2b||0xc8,function(_0x267379){const _0x257f70=a25_0x594b;if(_0x267379)return _0xed9031['status'](_0x40bf2b)[_0x257f70('0x1a')](_0x267379);};}function respondWithFilteredResult(_0xab840c,_0x3ec78b){return function(_0x554c40){const _0x145e39=a25_0x594b;if(_0x554c40){const _0x3606be=_0x554c40['count'],_0x4a4920=_0x3ec78b['offset'];let _0x12e6f0=_0x3ec78b['offset']+_0x3ec78b[_0x145e39('0x6')],_0x26ba2d;return _0x12e6f0>=_0x3606be?(_0x12e6f0=_0x3606be,_0x26ba2d=0xc8):_0x26ba2d=0xce,_0xab840c['status'](_0x26ba2d),_0xab840c[_0x145e39('0x21')](_0x145e39('0x8'),_0x4a4920+'-'+_0x12e6f0+'/'+_0x3606be)[_0x145e39('0x1a')](_0x554c40);}return null;};}function saveUpdates(_0x51113f){return function(_0x3f5367){const _0x2d4b67=a25_0x594b;if(_0x3f5367)return _0x3f5367[_0x2d4b67('0xf')](_0x51113f)[_0x2d4b67('0x15')](function(_0x4928a4){return _0x4928a4;});return null;};}function removeEntity(_0x3a0960){return function(_0x5d63f9){const _0x4e085f=a25_0x594b;if(_0x5d63f9)return _0x5d63f9['destroy']()[_0x4e085f('0x15')](function(){const _0x2b00c1=_0x4e085f;_0x3a0960[_0x2b00c1('0x9')](0xcc)[_0x2b00c1('0x20')]();});};}function handleEntityNotFound(_0x5f2f79){return function(_0x3db32a){return!_0x3db32a&&_0x5f2f79['sendStatus'](0x194),_0x3db32a;};}function handleError(_0x4b617f,_0x43dc4d){return _0x43dc4d=_0x43dc4d||0x1f4,function(_0x723094){const _0x18ce43=a25_0x594b;logger[_0x18ce43('0x14')](_0x723094[_0x18ce43('0x2a')]),_0x723094[_0x18ce43('0x27')]&&delete _0x723094[_0x18ce43('0x27')],_0x4b617f['status'](_0x43dc4d)[_0x18ce43('0x1e')](_0x723094);};}exports[_0x1df59c('0xa')]=function(_0x115352,_0x15b06b){const _0x3ca0cd=_0x1df59c;let _0x3376d8={};const _0x40abe8={},_0x112719={'count':0x0,'rows':[]},_0x492a9e=_[_0x3ca0cd('0x12')](db[_0x3ca0cd('0xe')][_0x3ca0cd('0x1c')],function(_0x5f25b4){const _0x2e90b0=_0x3ca0cd;return{'name':_0x5f25b4['fieldName'],'type':_0x5f25b4[_0x2e90b0('0x17')][_0x2e90b0('0x2c')]};});_0x40abe8[_0x3ca0cd('0x19')]=_[_0x3ca0cd('0x12')](_0x492a9e,_0x3ca0cd('0x27')),_0x40abe8[_0x3ca0cd('0x7')]=_[_0x3ca0cd('0x1')](_0x115352[_0x3ca0cd('0x7')]),_0x40abe8[_0x3ca0cd('0x18')]=_[_0x3ca0cd('0x28')](_0x40abe8[_0x3ca0cd('0x19')],_0x40abe8['query']),_0x3376d8[_0x3ca0cd('0xb')]=_[_0x3ca0cd('0x28')](_0x40abe8['model'],qs['fields'](_0x115352[_0x3ca0cd('0x7')][_0x3ca0cd('0x23')])),_0x3376d8[_0x3ca0cd('0xb')]=_0x3376d8[_0x3ca0cd('0xb')]['length']?_0x3376d8['attributes']:_0x40abe8[_0x3ca0cd('0x19')];typeof _0x115352[_0x3ca0cd('0x7')][_0x3ca0cd('0xc')]===_0x3ca0cd('0x29')&&(_0x3376d8[_0x3ca0cd('0x6')]=qs[_0x3ca0cd('0x6')](_0x115352[_0x3ca0cd('0x7')][_0x3ca0cd('0x6')]),_0x3376d8[_0x3ca0cd('0x0')]=qs[_0x3ca0cd('0x0')](_0x115352[_0x3ca0cd('0x7')][_0x3ca0cd('0x0')]));_0x3376d8[_0x3ca0cd('0x2b')]=qs[_0x3ca0cd('0x22')](_0x115352['query'][_0x3ca0cd('0x22')]),_0x3376d8[_0x3ca0cd('0x2e')]=qs[_0x3ca0cd('0x18')](_['pick'](_0x115352[_0x3ca0cd('0x7')],_0x40abe8['filters']),_0x492a9e);_0x115352[_0x3ca0cd('0x7')]['filter']&&(_0x3376d8[_0x3ca0cd('0x2e')]=_[_0x3ca0cd('0x16')](_0x3376d8[_0x3ca0cd('0x2e')],{[Op['or']]:_['map'](_0x492a9e,function(_0x5395b2){const _0x59b5a2=_0x3ca0cd;if(_0x5395b2['type']!==_0x59b5a2('0x1f')){const _0x4d63e6={};return _0x4d63e6[_0x5395b2['name']]={[Op['like']]:'%'+_0x115352[_0x59b5a2('0x7')][_0x59b5a2('0x26')]+'%'},_0x4d63e6;}})}));_0x3376d8=_[_0x3ca0cd('0x16')]({},_0x3376d8,_0x115352['options']);const _0x412395={'where':_0x3376d8[_0x3ca0cd('0x2e')]};return db['AnalyticTreeReport'][_0x3ca0cd('0x11')](_0x412395)[_0x3ca0cd('0x15')](function(_0x69e04c){const _0x1953e1=_0x3ca0cd;return _0x112719[_0x1953e1('0x11')]=_0x69e04c,_0x115352['query'][_0x1953e1('0x24')]&&(_0x3376d8[_0x1953e1('0x2')]=[{'all':!![]}]),db[_0x1953e1('0xe')][_0x1953e1('0x5')](_0x3376d8);})[_0x3ca0cd('0x15')](function(_0x5a31b1){const _0x3cde16=_0x3ca0cd;return _0x112719[_0x3cde16('0x2f')]=_0x5a31b1,_0x112719;})[_0x3ca0cd('0x15')](respondWithFilteredResult(_0x15b06b,_0x3376d8))['catch'](handleError(_0x15b06b,null));},exports[_0x1df59c('0x1b')]=function(_0x1d142a,_0x41404e){const _0x2d4b87=_0x1df59c;let _0x36da58={'raw':!![],'where':{'id':_0x1d142a[_0x2d4b87('0x3')]['id']}};const _0x1ce7dc={};return _0x1ce7dc[_0x2d4b87('0x19')]=_['keys'](db[_0x2d4b87('0xe')][_0x2d4b87('0x1c')]),_0x1ce7dc['query']=_[_0x2d4b87('0x1')](_0x1d142a['query']),_0x1ce7dc[_0x2d4b87('0x18')]=_[_0x2d4b87('0x28')](_0x1ce7dc[_0x2d4b87('0x19')],_0x1ce7dc['query']),_0x36da58[_0x2d4b87('0xb')]=_['intersection'](_0x1ce7dc[_0x2d4b87('0x19')],qs[_0x2d4b87('0x23')](_0x1d142a['query']['fields'])),_0x36da58[_0x2d4b87('0xb')]=_0x36da58[_0x2d4b87('0xb')]['length']?_0x36da58[_0x2d4b87('0xb')]:_0x1ce7dc[_0x2d4b87('0x19')],_0x1d142a[_0x2d4b87('0x7')][_0x2d4b87('0x24')]&&(_0x36da58[_0x2d4b87('0x2')]=[{'all':!![]}]),_0x36da58=_[_0x2d4b87('0x16')]({},_0x36da58,_0x1d142a['options']),db[_0x2d4b87('0xe')][_0x2d4b87('0x1d')](_0x36da58)[_0x2d4b87('0x15')](handleEntityNotFound(_0x41404e,null))[_0x2d4b87('0x15')](respondWithResult(_0x41404e,null))[_0x2d4b87('0x10')](handleError(_0x41404e,null));},exports['create']=function(_0x4e19f5,_0x3e4ef0){const _0x11be87=_0x1df59c;return db['AnalyticTreeReport'][_0x11be87('0x25')](_0x4e19f5[_0x11be87('0x4')],{})[_0x11be87('0x15')](respondWithResult(_0x3e4ef0,0xc9))['catch'](handleError(_0x3e4ef0,null));},exports['update']=function(_0x207062,_0x5a222f){const _0x505234=_0x1df59c;return _0x207062[_0x505234('0x4')]['id']&&delete _0x207062[_0x505234('0x4')]['id'],db[_0x505234('0xe')][_0x505234('0x1d')]({'where':{'id':_0x207062[_0x505234('0x3')]['id']}})[_0x505234('0x15')](handleEntityNotFound(_0x5a222f,null))[_0x505234('0x15')](saveUpdates(_0x207062['body'],null))[_0x505234('0x15')](respondWithResult(_0x5a222f,null))[_0x505234('0x10')](handleError(_0x5a222f,null));},exports['destroy']=function(_0x1245e8,_0x2248e4){const _0x4c1a62=_0x1df59c;return db[_0x4c1a62('0xe')]['findOne']({'where':{'id':_0x1245e8['params']['id']}})[_0x4c1a62('0x15')](handleEntityNotFound(_0x2248e4,null))[_0x4c1a62('0x15')](removeEntity(_0x2248e4,null))[_0x4c1a62('0x10')](handleError(_0x2248e4,null));}; \ No newline at end of file diff --git a/server/api/analyticTreeReport/analyticTreeReport.model.js b/server/api/analyticTreeReport/analyticTreeReport.model.js index 7bde37f..fd0c103 100644 --- a/server/api/analyticTreeReport/analyticTreeReport.model.js +++ b/server/api/analyticTreeReport/analyticTreeReport.model.js @@ -1 +1 @@ -const a26_0x4490=['./analyticTreeReport.attributes','AnalyticTreeReport','exports','analytics_report_trees'];(function(_0x17144b,_0x4490fb){const _0x4c9973=function(_0x4ec175){while(--_0x4ec175){_0x17144b['push'](_0x17144b['shift']());}};_0x4c9973(++_0x4490fb);}(a26_0x4490,0x6c));const a26_0x4c99=function(_0x17144b,_0x4490fb){_0x17144b=_0x17144b-0x0;let _0x4c9973=a26_0x4490[_0x17144b];return _0x4c9973;};const _0x2780f4=a26_0x4c99;'use strict';const attributes=require(_0x2780f4('0x0'));module[_0x2780f4('0x2')]=function(_0x4ec175){const _0x43175f=_0x2780f4,_0x1024da=_0x4ec175['define'](_0x43175f('0x1'),attributes,{'tableName':_0x43175f('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1024da;}; \ No newline at end of file +const a26_0x4332=['AnalyticTreeReport','./analyticTreeReport.attributes'];(function(_0x36067d,_0x433202){const _0x13c251=function(_0x1c55a5){while(--_0x1c55a5){_0x36067d['push'](_0x36067d['shift']());}};_0x13c251(++_0x433202);}(a26_0x4332,0x180));const a26_0x13c2=function(_0x36067d,_0x433202){_0x36067d=_0x36067d-0x0;let _0x13c251=a26_0x4332[_0x36067d];return _0x13c251;};const _0x6b1e4b=a26_0x13c2;'use strict';const attributes=require(_0x6b1e4b('0x1'));module['exports']=function(_0x1c55a5){const _0x359012=_0x6b1e4b,_0x32033a=_0x1c55a5['define'](_0x359012('0x0'),attributes,{'tableName':'analytics_report_trees','paranoid':![],'indexes':[],'timestamps':!![]});return _0x32033a;}; \ No newline at end of file diff --git a/server/api/analyticTreeReport/index.js b/server/api/analyticTreeReport/index.js index 7aa429a..919e3a1 100644 --- a/server/api/analyticTreeReport/index.js +++ b/server/api/analyticTreeReport/index.js @@ -1 +1 @@ -const a27_0x107c=['delete','index','get','isAuthenticated','express','destroy','Router','create','./analyticTreeReport.controller','/:id'];(function(_0x11d711,_0x107c2a){const _0x41492a=function(_0x24675a){while(--_0x24675a){_0x11d711['push'](_0x11d711['shift']());}};_0x41492a(++_0x107c2a);}(a27_0x107c,0xcb));const a27_0x4149=function(_0x11d711,_0x107c2a){_0x11d711=_0x11d711-0x0;let _0x41492a=a27_0x107c[_0x11d711];return _0x41492a;};const _0x44b065=a27_0x4149;'use strict';const express=require(_0x44b065('0x1')),router=express[_0x44b065('0x3')](),auth=require('../../components/auth/service'),controller=require(_0x44b065('0x5'));router[_0x44b065('0x9')]('/',auth[_0x44b065('0x0')](),controller[_0x44b065('0x8')]),router[_0x44b065('0x9')](_0x44b065('0x6'),auth[_0x44b065('0x0')](),controller['show']),router['post']('/',auth[_0x44b065('0x0')](),controller[_0x44b065('0x4')]),router['put'](_0x44b065('0x6'),auth[_0x44b065('0x0')](),controller['update']),router[_0x44b065('0x7')](_0x44b065('0x6'),auth[_0x44b065('0x0')](),controller[_0x44b065('0x2')]),module['exports']=router; \ No newline at end of file +const a27_0x1e23=['../../components/auth/service','put','/:id','get','destroy','./analyticTreeReport.controller','index','create','exports','express','show','isAuthenticated','Router','update'];(function(_0x41da54,_0x1e2352){const _0x47bd9f=function(_0x3ebc2d){while(--_0x3ebc2d){_0x41da54['push'](_0x41da54['shift']());}};_0x47bd9f(++_0x1e2352);}(a27_0x1e23,0x19d));const a27_0x47bd=function(_0x41da54,_0x1e2352){_0x41da54=_0x41da54-0x0;let _0x47bd9f=a27_0x1e23[_0x41da54];return _0x47bd9f;};const _0x1913cb=a27_0x47bd;'use strict';const express=require(_0x1913cb('0x2')),router=express[_0x1913cb('0x5')](),auth=require(_0x1913cb('0x7')),controller=require(_0x1913cb('0xc'));router['get']('/',auth[_0x1913cb('0x4')](),controller[_0x1913cb('0xd')]),router[_0x1913cb('0xa')]('/:id',auth[_0x1913cb('0x4')](),controller[_0x1913cb('0x3')]),router['post']('/',auth[_0x1913cb('0x4')](),controller[_0x1913cb('0x0')]),router[_0x1913cb('0x8')](_0x1913cb('0x9'),auth[_0x1913cb('0x4')](),controller[_0x1913cb('0x6')]),router['delete'](_0x1913cb('0x9'),auth[_0x1913cb('0x4')](),controller[_0x1913cb('0xb')]),module[_0x1913cb('0x1')]=router; \ No newline at end of file diff --git a/server/api/attachment/attachment.attributes.js b/server/api/attachment/attachment.attributes.js index e538b5a..e24359e 100644 --- a/server/api/attachment/attachment.attributes.js +++ b/server/api/attachment/attachment.attributes.js @@ -1 +1 @@ -const a28_0x3816=['sequelize','STRING'];(function(_0x5f104b,_0x381601){const _0x203104=function(_0x39011b){while(--_0x39011b){_0x5f104b['push'](_0x5f104b['shift']());}};_0x203104(++_0x381601);}(a28_0x3816,0x140));const a28_0x2031=function(_0x5f104b,_0x381601){_0x5f104b=_0x5f104b-0x0;let _0x203104=a28_0x3816[_0x5f104b];return _0x203104;};const _0x581953=a28_0x2031;'use strict';const Sequelize=require(_0x581953('0x0'));module['exports']={'name':{'type':Sequelize[_0x581953('0x1')]},'basename':{'type':Sequelize[_0x581953('0x1')]},'type':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a28_0x5126=['STRING','sequelize','exports'];(function(_0x1df65e,_0x512641){const _0x4883b6=function(_0x305c7d){while(--_0x305c7d){_0x1df65e['push'](_0x1df65e['shift']());}};_0x4883b6(++_0x512641);}(a28_0x5126,0x13f));const a28_0x4883=function(_0x1df65e,_0x512641){_0x1df65e=_0x1df65e-0x0;let _0x4883b6=a28_0x5126[_0x1df65e];return _0x4883b6;};const _0x1f87a1=a28_0x4883;'use strict';const Sequelize=require(_0x1f87a1('0x0'));module[_0x1f87a1('0x1')]={'name':{'type':Sequelize[_0x1f87a1('0x2')]},'basename':{'type':Sequelize['STRING']},'type':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/attachment/attachment.controller.js b/server/api/attachment/attachment.controller.js index dfbede5..2609721 100644 --- a/server/api/attachment/attachment.controller.js +++ b/server/api/attachment/attachment.controller.js @@ -1 +1 @@ -const a29_0x5612=['rawAttributes','offset','query','Content-Range','include','sequelize','path','params','length','../../components/parsers/qs','catch','key','keys','omit','sort','VIRTUAL','end','order','nolimit','download','Attachment','create','fields','includeAll','clone','index','filters','mimetype','limit','lodash','error','destroy','findOne','updatedAt','merge','files/attachments/','map','createdAt','basename','api','stack','get','name','file','model','set','like','attributes','status','intersection','update','join','undefined','filter','../../mysqldb','count','sendStatus','findAll','then','type','options','body'];(function(_0x2e15a2,_0x5612a8){const _0x34177a=function(_0x43fc95){while(--_0x43fc95){_0x2e15a2['push'](_0x2e15a2['shift']());}};_0x34177a(++_0x5612a8);}(a29_0x5612,0xc3));const a29_0x3417=function(_0x2e15a2,_0x5612a8){_0x2e15a2=_0x2e15a2-0x0;let _0x34177a=a29_0x5612[_0x2e15a2];return _0x34177a;};const _0x41c875=a29_0x3417;'use strict';const path=require(_0x41c875('0x3b')),_=require(_0x41c875('0x14')),qs=require(_0x41c875('0x0')),logger=require('../../config/logger')(_0x41c875('0x1e')),config=require('../../config/environment'),db=require(_0x41c875('0x2d'))['db'],{Op}=require(_0x41c875('0x3a'));function respondWithResult(_0x43fc95,_0x5bdc15){return _0x5bdc15=_0x5bdc15||0xc8,function(_0x15b4ab){const _0x269982=a29_0x3417;if(_0x15b4ab)return _0x43fc95[_0x269982('0x27')](_0x5bdc15)['json'](_0x15b4ab);};}function respondWithFilteredResult(_0x2e8f47,_0x11fe6f){return function(_0x3ebf90){const _0x200349=a29_0x3417;if(_0x3ebf90){const _0x54c180=_0x3ebf90['count'],_0x1e8682=_0x11fe6f[_0x200349('0x36')];let _0x1cabe5=_0x11fe6f[_0x200349('0x36')]+_0x11fe6f[_0x200349('0x13')],_0x3f71bb;return _0x1cabe5>=_0x54c180?(_0x1cabe5=_0x54c180,_0x3f71bb=0xc8):_0x3f71bb=0xce,_0x2e8f47[_0x200349('0x27')](_0x3f71bb),_0x2e8f47[_0x200349('0x24')](_0x200349('0x38'),_0x1e8682+'-'+_0x1cabe5+'/'+_0x54c180)['json'](_0x3ebf90);}return null;};}function saveUpdates(_0xbf8d78){return function(_0x1cea27){const _0xcc2d7b=a29_0x3417;if(_0x1cea27)return _0x1cea27[_0xcc2d7b('0x29')](_0xbf8d78)[_0xcc2d7b('0x31')](function(_0x5ecb79){return _0x5ecb79;});return null;};}function removeEntity(_0x37f8fb){return function(_0x3ea2ae){const _0x3b0c1c=a29_0x3417;if(_0x3ea2ae)return _0x3ea2ae['destroy']()[_0x3b0c1c('0x31')](function(){const _0x2088fc=_0x3b0c1c;_0x37f8fb[_0x2088fc('0x27')](0xcc)[_0x2088fc('0x7')]();});};}function handleEntityNotFound(_0x232658){return function(_0x24e492){const _0x5385fc=a29_0x3417;return!_0x24e492&&_0x232658[_0x5385fc('0x2f')](0x194),_0x24e492;};}function handleError(_0x13845c,_0x972f7b){return _0x972f7b=_0x972f7b||0x1f4,function(_0xf2aa12){const _0x18908d=a29_0x3417;logger[_0x18908d('0x15')](_0xf2aa12[_0x18908d('0x1f')]),_0xf2aa12[_0x18908d('0x21')]&&delete _0xf2aa12[_0x18908d('0x21')],_0x13845c[_0x18908d('0x27')](_0x972f7b)['send'](_0xf2aa12);};}exports[_0x41c875('0x10')]=function(_0x431dbb,_0x45fba8){const _0x380005=_0x41c875;let _0x5bb701={};const _0x452c0d={},_0x3af4aa={'count':0x0,'rows':[]},_0x1c3e6c=_['map'](db[_0x380005('0xb')][_0x380005('0x35')],function(_0x3e9adc){const _0x4721cf=_0x380005;return{'name':_0x3e9adc['fieldName'],'type':_0x3e9adc[_0x4721cf('0x32')][_0x4721cf('0x2')]};});_0x452c0d[_0x380005('0x23')]=_[_0x380005('0x1b')](_0x1c3e6c,_0x380005('0x21')),_0x452c0d[_0x380005('0x37')]=_[_0x380005('0x3')](_0x431dbb[_0x380005('0x37')]),_0x452c0d[_0x380005('0x11')]=_[_0x380005('0x28')](_0x452c0d[_0x380005('0x23')],_0x452c0d['query']),_0x5bb701[_0x380005('0x26')]=_[_0x380005('0x28')](_0x452c0d[_0x380005('0x23')],qs[_0x380005('0xd')](_0x431dbb['query'][_0x380005('0xd')])),_0x5bb701['attributes']=_0x5bb701[_0x380005('0x26')]['length']?_0x5bb701[_0x380005('0x26')]:_0x452c0d['model'];typeof _0x431dbb[_0x380005('0x37')][_0x380005('0x9')]===_0x380005('0x2b')&&(_0x5bb701[_0x380005('0x13')]=qs[_0x380005('0x13')](_0x431dbb[_0x380005('0x37')][_0x380005('0x13')]),_0x5bb701[_0x380005('0x36')]=qs[_0x380005('0x36')](_0x431dbb[_0x380005('0x37')][_0x380005('0x36')]));_0x5bb701[_0x380005('0x8')]=qs[_0x380005('0x5')](_0x431dbb['query'][_0x380005('0x5')]),_0x5bb701['where']=qs[_0x380005('0x11')](_['pick'](_0x431dbb[_0x380005('0x37')],_0x452c0d[_0x380005('0x11')]),_0x1c3e6c);_0x431dbb['query'][_0x380005('0x2c')]&&(_0x5bb701['where']=_[_0x380005('0x19')](_0x5bb701['where'],{[Op['or']]:_[_0x380005('0x1b')](_0x1c3e6c,function(_0x30d087){const _0x505a72=_0x380005;if(_0x30d087['type']!==_0x505a72('0x6')){const _0x25e0fd={};return _0x25e0fd[_0x30d087[_0x505a72('0x21')]]={[Op[_0x505a72('0x25')]]:'%'+_0x431dbb['query'][_0x505a72('0x2c')]+'%'},_0x25e0fd;}})}));_0x5bb701=_[_0x380005('0x19')]({},_0x5bb701,_0x431dbb[_0x380005('0x33')]);const _0x198aee={'where':_0x5bb701['where']};return db[_0x380005('0xb')][_0x380005('0x2e')](_0x198aee)[_0x380005('0x31')](function(_0x2889f0){const _0x4d5883=_0x380005;return _0x3af4aa[_0x4d5883('0x2e')]=_0x2889f0,_0x431dbb[_0x4d5883('0x37')]['includeAll']&&(_0x5bb701['include']=[{'all':!![]}]),db[_0x4d5883('0xb')][_0x4d5883('0x30')](_0x5bb701);})[_0x380005('0x31')](function(_0x15d863){return _0x3af4aa['rows']=_0x15d863,_0x3af4aa;})[_0x380005('0x31')](respondWithFilteredResult(_0x45fba8,_0x5bb701))[_0x380005('0x1')](handleError(_0x45fba8,null));},exports['show']=function(_0xfd5e6b,_0x5aef77){const _0x442306=_0x41c875;let _0x145cf1={'raw':!![],'where':{'id':_0xfd5e6b[_0x442306('0x3c')]['id']}};const _0x44f500={};return _0x44f500[_0x442306('0x23')]=_[_0x442306('0x3')](db[_0x442306('0xb')][_0x442306('0x35')]),_0x44f500[_0x442306('0x37')]=_[_0x442306('0x3')](_0xfd5e6b['query']),_0x44f500[_0x442306('0x11')]=_[_0x442306('0x28')](_0x44f500[_0x442306('0x23')],_0x44f500['query']),_0x145cf1[_0x442306('0x26')]=_[_0x442306('0x28')](_0x44f500['model'],qs[_0x442306('0xd')](_0xfd5e6b[_0x442306('0x37')]['fields'])),_0x145cf1['attributes']=_0x145cf1[_0x442306('0x26')]['length']?_0x145cf1['attributes']:_0x44f500[_0x442306('0x23')],_0xfd5e6b[_0x442306('0x37')][_0x442306('0xe')]&&(_0x145cf1[_0x442306('0x39')]=[{'all':!![]}]),_0x145cf1=_[_0x442306('0x19')]({},_0x145cf1,_0xfd5e6b[_0x442306('0x33')]),db[_0x442306('0xb')][_0x442306('0x17')](_0x145cf1)[_0x442306('0x31')](handleEntityNotFound(_0x5aef77,null))['then'](respondWithResult(_0x5aef77,null))[_0x442306('0x1')](handleError(_0x5aef77,null));},exports[_0x41c875('0xf')]=function(_0x3514cb,_0x1e7b99){const _0x291c55=_0x41c875;let _0x2561ac={'where':{'id':_0x3514cb[_0x291c55('0x3c')]['id']}};const _0x5b6a06={};return _0x5b6a06['model']=_['keys'](db[_0x291c55('0xb')][_0x291c55('0x35')]),_0x2561ac[_0x291c55('0x26')]=_[_0x291c55('0x28')](_0x5b6a06[_0x291c55('0x23')],qs[_0x291c55('0xd')](_0x3514cb[_0x291c55('0x37')][_0x291c55('0xd')])),_0x2561ac[_0x291c55('0x26')]=_0x2561ac[_0x291c55('0x26')][_0x291c55('0x3d')]?_0x2561ac['attributes']:_0x5b6a06[_0x291c55('0x23')],_0x3514cb['query']['includeAll']&&(_0x2561ac[_0x291c55('0x39')]=[{'all':!![]}]),_0x2561ac=_[_0x291c55('0x19')]({},_0x2561ac,_0x3514cb['options']),db['Attachment']['findOne'](_0x2561ac)[_0x291c55('0x31')](handleEntityNotFound(_0x1e7b99,null))[_0x291c55('0x31')](function(_0x4a66f8){const _0x36ca99=_0x291c55;if(_0x4a66f8){let _0x14f049=_0x4a66f8[_0x36ca99('0x20')]({'plain':!![]});return _0x14f049=qs['omit'](_0x14f049,['id',_0x36ca99('0x1c'),_0x36ca99('0x18')]),_0x3514cb[_0x36ca99('0x34')]=_[_0x36ca99('0x4')](_0x3514cb['body'],['id',_0x36ca99('0x1c'),_0x36ca99('0x18')]),db['Attachment']['create'](_[_0x36ca99('0x19')](_0x14f049,_0x3514cb[_0x36ca99('0x34')]),{'include':_0x3514cb['query'][_0x36ca99('0xe')]?[{'all':!![]}]:undefined});}})['then'](respondWithResult(_0x1e7b99,0xc9))[_0x291c55('0x1')](handleError(_0x1e7b99,null));},exports[_0x41c875('0x29')]=function(_0x3021af,_0x5037a1){const _0x161073=_0x41c875;return _0x3021af[_0x161073('0x34')]['id']&&delete _0x3021af['body']['id'],db[_0x161073('0xb')][_0x161073('0x17')]({'where':{'id':_0x3021af['params']['id']}})['then'](handleEntityNotFound(_0x5037a1,null))['then'](saveUpdates(_0x3021af[_0x161073('0x34')],null))[_0x161073('0x31')](respondWithResult(_0x5037a1,null))[_0x161073('0x1')](handleError(_0x5037a1,null));},exports[_0x41c875('0x16')]=function(_0x7ea905,_0x5c3a7c){const _0x39be18=_0x41c875;return db[_0x39be18('0xb')][_0x39be18('0x17')]({'where':{'id':_0x7ea905[_0x39be18('0x3c')]['id']}})[_0x39be18('0x31')](handleEntityNotFound(_0x5c3a7c,null))[_0x39be18('0x31')](removeEntity(_0x5c3a7c,null))[_0x39be18('0x1')](handleError(_0x5c3a7c,null));},exports['create']=function(_0x277132,_0x2b9132){const _0x26967e=_0x41c875;return _0x277132['body'][_0x26967e('0x21')]=_0x277132[_0x26967e('0x22')]['originalname'],_0x277132['body'][_0x26967e('0x1d')]=_0x277132[_0x26967e('0x22')]['filename'],_0x277132[_0x26967e('0x34')][_0x26967e('0x32')]=_0x277132['file'][_0x26967e('0x12')],db[_0x26967e('0xb')][_0x26967e('0xc')](_0x277132['body'])['then'](respondWithResult(_0x2b9132,0xc9))[_0x26967e('0x1')](handleError(_0x2b9132,null));},exports[_0x41c875('0xa')]=function(_0x31e320,_0x580a06){const _0x212e1d=_0x41c875;return db[_0x212e1d('0xb')][_0x212e1d('0x17')]({'where':{'id':_0x31e320[_0x212e1d('0x3c')]['id']},'raw':!![]})[_0x212e1d('0x31')](handleEntityNotFound(_0x580a06,null))[_0x212e1d('0x31')](function(_0x5b2fc0){const _0x135ab6=_0x212e1d;if(_0x5b2fc0)return _0x580a06[_0x135ab6('0xa')](path[_0x135ab6('0x2a')](config['root'],_0x135ab6('0x1a'),_0x5b2fc0['basename']));})['catch'](handleError(_0x580a06,null));}; \ No newline at end of file +const a29_0x2209=['intersection','set','lodash','fields','file','path','attributes','offset','rows','options','fieldName','length','pick','update','show','merge','name','rawAttributes','findAll','basename','findOne','limit','sendStatus','where','map','body','Content-Range','download','key','keys','omit','query','get','count','status','originalname','undefined','updatedAt','json','params','Attachment','api','filters','index','../../mysqldb','includeAll','then','VIRTUAL','../../config/environment','files/attachments/','stack','../../components/parsers/qs','create','send','filter','sequelize','model','join','../../config/logger','catch'];(function(_0x3befe7,_0x2209e9){const _0x59ba2e=function(_0x2d9c0b){while(--_0x2d9c0b){_0x3befe7['push'](_0x3befe7['shift']());}};_0x59ba2e(++_0x2209e9);}(a29_0x2209,0xd2));const a29_0x59ba=function(_0x3befe7,_0x2209e9){_0x3befe7=_0x3befe7-0x0;let _0x59ba2e=a29_0x2209[_0x3befe7];return _0x59ba2e;};const _0x3f9602=a29_0x59ba;'use strict';const path=require(_0x3f9602('0x23')),_=require(_0x3f9602('0x20')),qs=require(_0x3f9602('0x15')),logger=require(_0x3f9602('0x1c'))(_0x3f9602('0xb')),config=require(_0x3f9602('0x12')),db=require(_0x3f9602('0xe'))['db'],{Op}=require(_0x3f9602('0x19'));function respondWithResult(_0x2d9c0b,_0x25def1){return _0x25def1=_0x25def1||0xc8,function(_0x8aa98f){const _0x17254b=a29_0x59ba;if(_0x8aa98f)return _0x2d9c0b[_0x17254b('0x4')](_0x25def1)[_0x17254b('0x8')](_0x8aa98f);};}function respondWithFilteredResult(_0x405197,_0x43e2d2){return function(_0x3d5107){const _0x38338f=a29_0x59ba;if(_0x3d5107){const _0x29ce26=_0x3d5107[_0x38338f('0x3')],_0x5d457d=_0x43e2d2[_0x38338f('0x25')];let _0x4fd25d=_0x43e2d2[_0x38338f('0x25')]+_0x43e2d2[_0x38338f('0x33')],_0x281dc5;return _0x4fd25d>=_0x29ce26?(_0x4fd25d=_0x29ce26,_0x281dc5=0xc8):_0x281dc5=0xce,_0x405197[_0x38338f('0x4')](_0x281dc5),_0x405197[_0x38338f('0x1f')](_0x38338f('0x38'),_0x5d457d+'-'+_0x4fd25d+'/'+_0x29ce26)[_0x38338f('0x8')](_0x3d5107);}return null;};}function saveUpdates(_0x2212a0){return function(_0x41824d){const _0x3c8f0c=a29_0x59ba;if(_0x41824d)return _0x41824d[_0x3c8f0c('0x2b')](_0x2212a0)[_0x3c8f0c('0x10')](function(_0x2c22b4){return _0x2c22b4;});return null;};}function removeEntity(_0x19c7b1){return function(_0x14659c){if(_0x14659c)return _0x14659c['destroy']()['then'](function(){const _0x242beb=a29_0x59ba;_0x19c7b1[_0x242beb('0x4')](0xcc)['end']();});};}function handleEntityNotFound(_0x1c4013){return function(_0x1a4acd){const _0x1d5756=a29_0x59ba;return!_0x1a4acd&&_0x1c4013[_0x1d5756('0x34')](0x194),_0x1a4acd;};}function handleError(_0x4dd76f,_0x5ab069){return _0x5ab069=_0x5ab069||0x1f4,function(_0x3163df){const _0x1a02ca=a29_0x59ba;logger['error'](_0x3163df[_0x1a02ca('0x14')]),_0x3163df[_0x1a02ca('0x2e')]&&delete _0x3163df['name'],_0x4dd76f['status'](_0x5ab069)[_0x1a02ca('0x17')](_0x3163df);};}exports[_0x3f9602('0xd')]=function(_0x3c27a9,_0x475cc3){const _0x51e485=_0x3f9602;let _0x5189ea={};const _0x378d86={},_0x2571f8={'count':0x0,'rows':[]},_0x36d650=_['map'](db[_0x51e485('0xa')][_0x51e485('0x2f')],function(_0x2d9c91){const _0x1d73b6=_0x51e485;return{'name':_0x2d9c91[_0x1d73b6('0x28')],'type':_0x2d9c91['type'][_0x1d73b6('0x3a')]};});_0x378d86[_0x51e485('0x1a')]=_['map'](_0x36d650,_0x51e485('0x2e')),_0x378d86[_0x51e485('0x1')]=_['keys'](_0x3c27a9[_0x51e485('0x1')]),_0x378d86['filters']=_[_0x51e485('0x1e')](_0x378d86[_0x51e485('0x1a')],_0x378d86[_0x51e485('0x1')]),_0x5189ea[_0x51e485('0x24')]=_[_0x51e485('0x1e')](_0x378d86[_0x51e485('0x1a')],qs['fields'](_0x3c27a9[_0x51e485('0x1')][_0x51e485('0x21')])),_0x5189ea['attributes']=_0x5189ea[_0x51e485('0x24')][_0x51e485('0x29')]?_0x5189ea['attributes']:_0x378d86[_0x51e485('0x1a')];typeof _0x3c27a9[_0x51e485('0x1')]['nolimit']===_0x51e485('0x6')&&(_0x5189ea[_0x51e485('0x33')]=qs[_0x51e485('0x33')](_0x3c27a9[_0x51e485('0x1')]['limit']),_0x5189ea['offset']=qs[_0x51e485('0x25')](_0x3c27a9[_0x51e485('0x1')][_0x51e485('0x25')]));_0x5189ea['order']=qs['sort'](_0x3c27a9[_0x51e485('0x1')]['sort']),_0x5189ea[_0x51e485('0x35')]=qs[_0x51e485('0xc')](_[_0x51e485('0x2a')](_0x3c27a9[_0x51e485('0x1')],_0x378d86['filters']),_0x36d650);_0x3c27a9[_0x51e485('0x1')][_0x51e485('0x18')]&&(_0x5189ea['where']=_['merge'](_0x5189ea[_0x51e485('0x35')],{[Op['or']]:_[_0x51e485('0x36')](_0x36d650,function(_0x3bcec1){const _0x1cb808=_0x51e485;if(_0x3bcec1['type']!==_0x1cb808('0x11')){const _0x48d3d8={};return _0x48d3d8[_0x3bcec1['name']]={[Op['like']]:'%'+_0x3c27a9['query']['filter']+'%'},_0x48d3d8;}})}));_0x5189ea=_[_0x51e485('0x2d')]({},_0x5189ea,_0x3c27a9[_0x51e485('0x27')]);const _0x5f7947={'where':_0x5189ea[_0x51e485('0x35')]};return db['Attachment']['count'](_0x5f7947)['then'](function(_0x5e3db0){const _0x274005=_0x51e485;return _0x2571f8[_0x274005('0x3')]=_0x5e3db0,_0x3c27a9['query'][_0x274005('0xf')]&&(_0x5189ea['include']=[{'all':!![]}]),db['Attachment'][_0x274005('0x30')](_0x5189ea);})['then'](function(_0x53ab1b){const _0x196d80=_0x51e485;return _0x2571f8[_0x196d80('0x26')]=_0x53ab1b,_0x2571f8;})[_0x51e485('0x10')](respondWithFilteredResult(_0x475cc3,_0x5189ea))[_0x51e485('0x1d')](handleError(_0x475cc3,null));},exports[_0x3f9602('0x2c')]=function(_0xad1d61,_0xdb8921){const _0x516e90=_0x3f9602;let _0x43399d={'raw':!![],'where':{'id':_0xad1d61[_0x516e90('0x9')]['id']}};const _0x3819b5={};return _0x3819b5[_0x516e90('0x1a')]=_['keys'](db[_0x516e90('0xa')][_0x516e90('0x2f')]),_0x3819b5[_0x516e90('0x1')]=_[_0x516e90('0x3b')](_0xad1d61[_0x516e90('0x1')]),_0x3819b5[_0x516e90('0xc')]=_['intersection'](_0x3819b5[_0x516e90('0x1a')],_0x3819b5[_0x516e90('0x1')]),_0x43399d[_0x516e90('0x24')]=_[_0x516e90('0x1e')](_0x3819b5[_0x516e90('0x1a')],qs[_0x516e90('0x21')](_0xad1d61[_0x516e90('0x1')][_0x516e90('0x21')])),_0x43399d['attributes']=_0x43399d[_0x516e90('0x24')][_0x516e90('0x29')]?_0x43399d['attributes']:_0x3819b5[_0x516e90('0x1a')],_0xad1d61[_0x516e90('0x1')][_0x516e90('0xf')]&&(_0x43399d['include']=[{'all':!![]}]),_0x43399d=_['merge']({},_0x43399d,_0xad1d61['options']),db[_0x516e90('0xa')][_0x516e90('0x32')](_0x43399d)[_0x516e90('0x10')](handleEntityNotFound(_0xdb8921,null))[_0x516e90('0x10')](respondWithResult(_0xdb8921,null))[_0x516e90('0x1d')](handleError(_0xdb8921,null));},exports['clone']=function(_0x143bef,_0x3cbb7e){const _0x505d8c=_0x3f9602;let _0x3f60e7={'where':{'id':_0x143bef[_0x505d8c('0x9')]['id']}};const _0x120197={};return _0x120197['model']=_[_0x505d8c('0x3b')](db['Attachment']['rawAttributes']),_0x3f60e7[_0x505d8c('0x24')]=_[_0x505d8c('0x1e')](_0x120197[_0x505d8c('0x1a')],qs[_0x505d8c('0x21')](_0x143bef[_0x505d8c('0x1')][_0x505d8c('0x21')])),_0x3f60e7[_0x505d8c('0x24')]=_0x3f60e7[_0x505d8c('0x24')][_0x505d8c('0x29')]?_0x3f60e7['attributes']:_0x120197[_0x505d8c('0x1a')],_0x143bef[_0x505d8c('0x1')][_0x505d8c('0xf')]&&(_0x3f60e7['include']=[{'all':!![]}]),_0x3f60e7=_['merge']({},_0x3f60e7,_0x143bef['options']),db[_0x505d8c('0xa')]['findOne'](_0x3f60e7)[_0x505d8c('0x10')](handleEntityNotFound(_0x3cbb7e,null))['then'](function(_0x21aed1){const _0x39d679=_0x505d8c;if(_0x21aed1){let _0x24f1ac=_0x21aed1[_0x39d679('0x2')]({'plain':!![]});return _0x24f1ac=qs[_0x39d679('0x0')](_0x24f1ac,['id','createdAt',_0x39d679('0x7')]),_0x143bef[_0x39d679('0x37')]=_['omit'](_0x143bef[_0x39d679('0x37')],['id','createdAt',_0x39d679('0x7')]),db[_0x39d679('0xa')]['create'](_['merge'](_0x24f1ac,_0x143bef[_0x39d679('0x37')]),{'include':_0x143bef[_0x39d679('0x1')][_0x39d679('0xf')]?[{'all':!![]}]:undefined});}})[_0x505d8c('0x10')](respondWithResult(_0x3cbb7e,0xc9))['catch'](handleError(_0x3cbb7e,null));},exports[_0x3f9602('0x2b')]=function(_0xb0a416,_0x3bd8f6){const _0x45d562=_0x3f9602;return _0xb0a416[_0x45d562('0x37')]['id']&&delete _0xb0a416[_0x45d562('0x37')]['id'],db['Attachment'][_0x45d562('0x32')]({'where':{'id':_0xb0a416[_0x45d562('0x9')]['id']}})[_0x45d562('0x10')](handleEntityNotFound(_0x3bd8f6,null))[_0x45d562('0x10')](saveUpdates(_0xb0a416[_0x45d562('0x37')],null))[_0x45d562('0x10')](respondWithResult(_0x3bd8f6,null))['catch'](handleError(_0x3bd8f6,null));},exports['destroy']=function(_0x11783d,_0x16bf9d){const _0x2fccd2=_0x3f9602;return db[_0x2fccd2('0xa')][_0x2fccd2('0x32')]({'where':{'id':_0x11783d[_0x2fccd2('0x9')]['id']}})[_0x2fccd2('0x10')](handleEntityNotFound(_0x16bf9d,null))[_0x2fccd2('0x10')](removeEntity(_0x16bf9d,null))['catch'](handleError(_0x16bf9d,null));},exports[_0x3f9602('0x16')]=function(_0xa2e01b,_0x122671){const _0x28a9f4=_0x3f9602;return _0xa2e01b[_0x28a9f4('0x37')][_0x28a9f4('0x2e')]=_0xa2e01b[_0x28a9f4('0x22')][_0x28a9f4('0x5')],_0xa2e01b[_0x28a9f4('0x37')][_0x28a9f4('0x31')]=_0xa2e01b[_0x28a9f4('0x22')]['filename'],_0xa2e01b['body']['type']=_0xa2e01b[_0x28a9f4('0x22')]['mimetype'],db[_0x28a9f4('0xa')][_0x28a9f4('0x16')](_0xa2e01b[_0x28a9f4('0x37')])[_0x28a9f4('0x10')](respondWithResult(_0x122671,0xc9))[_0x28a9f4('0x1d')](handleError(_0x122671,null));},exports['download']=function(_0x541462,_0x50ce1a){const _0x5ec32e=_0x3f9602;return db[_0x5ec32e('0xa')][_0x5ec32e('0x32')]({'where':{'id':_0x541462[_0x5ec32e('0x9')]['id']},'raw':!![]})['then'](handleEntityNotFound(_0x50ce1a,null))[_0x5ec32e('0x10')](function(_0x39ddab){const _0x2fe043=_0x5ec32e;if(_0x39ddab)return _0x50ce1a[_0x2fe043('0x39')](path[_0x2fe043('0x1b')](config['root'],_0x2fe043('0x13'),_0x39ddab['basename']));})['catch'](handleError(_0x50ce1a,null));}; \ No newline at end of file diff --git a/server/api/attachment/attachment.model.js b/server/api/attachment/attachment.model.js index 2170da6..4ca96ca 100644 --- a/server/api/attachment/attachment.model.js +++ b/server/api/attachment/attachment.model.js @@ -1 +1 @@ -const a30_0x1443=['./attachment.attributes','Attachment','define','attachments'];(function(_0x1a4c96,_0x1443d5){const _0x5cdd10=function(_0x3635f4){while(--_0x3635f4){_0x1a4c96['push'](_0x1a4c96['shift']());}};_0x5cdd10(++_0x1443d5);}(a30_0x1443,0x1b6));const a30_0x5cdd=function(_0x1a4c96,_0x1443d5){_0x1a4c96=_0x1a4c96-0x0;let _0x5cdd10=a30_0x1443[_0x1a4c96];return _0x5cdd10;};const _0x3d27ca=a30_0x5cdd;'use strict';const attributes=require(_0x3d27ca('0x2'));module['exports']=function(_0x3635f4){const _0xdef27=_0x3d27ca,_0x4739c4=_0x3635f4[_0xdef27('0x0')](_0xdef27('0x3'),attributes,{'tableName':_0xdef27('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x4739c4;}; \ No newline at end of file +const a30_0xf443=['define','Attachment','exports','attachments','./attachment.attributes'];(function(_0x2efd6d,_0xf443d2){const _0x541599=function(_0x410c53){while(--_0x410c53){_0x2efd6d['push'](_0x2efd6d['shift']());}};_0x541599(++_0xf443d2);}(a30_0xf443,0xfd));const a30_0x5415=function(_0x2efd6d,_0xf443d2){_0x2efd6d=_0x2efd6d-0x0;let _0x541599=a30_0xf443[_0x2efd6d];return _0x541599;};const _0x42579c=a30_0x5415;'use strict';const attributes=require(_0x42579c('0x1'));module[_0x42579c('0x4')]=function(_0x410c53){const _0x26ae00=_0x42579c,_0x5bb159=_0x410c53[_0x26ae00('0x2')](_0x26ae00('0x3'),attributes,{'tableName':_0x26ae00('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5bb159;}; \ No newline at end of file diff --git a/server/api/attachment/attachment.rpc.js b/server/api/attachment/attachment.rpc.js index cae1bcb..b9f3090 100644 --- a/server/api/attachment/attachment.rpc.js +++ b/server/api/attachment/attachment.rpc.js @@ -1 +1 @@ -const a31_0x3e30=['error','raw','../../mysqldb','stringify','create','then','options','message','info','body','CreateAttachment'];(function(_0x6f9b50,_0x3e30b6){const _0x58d17b=function(_0x1bba94){while(--_0x1bba94){_0x6f9b50['push'](_0x6f9b50['shift']());}};_0x58d17b(++_0x3e30b6);}(a31_0x3e30,0x134));const a31_0x58d1=function(_0x6f9b50,_0x3e30b6){_0x6f9b50=_0x6f9b50-0x0;let _0x58d17b=a31_0x3e30[_0x6f9b50];return _0x58d17b;};const _0x4b2b01=a31_0x58d1;'use strict';const db=require(_0x4b2b01('0x2'))['db'],logger=require('../../config/logger')('rpc');exports['CreateAttachment']=function(_0x1bba94){const _0x4b2c46=this;return new Promise(function(_0xe57ccb,_0x361f70){const _0x203876=a31_0x58d1;return db['Attachment'][_0x203876('0x4')](_0x1bba94[_0x203876('0x9')],{'raw':_0x1bba94[_0x203876('0x6')]?_0x1bba94[_0x203876('0x6')][_0x203876('0x1')]===undefined?!![]:![]:!![]})[_0x203876('0x5')](function(_0x28a815){const _0x23ebda=_0x203876;logger[_0x23ebda('0x8')](_0x23ebda('0xa'),_0x1bba94),logger['debug'](_0x23ebda('0xa'),_0x1bba94,JSON[_0x23ebda('0x3')](_0x28a815)),_0xe57ccb(_0x28a815);})['catch'](function(_0x15b899){const _0x2414ff=_0x203876;logger[_0x2414ff('0x0')](_0x2414ff('0xa'),_0x15b899[_0x2414ff('0x7')],_0x1bba94),_0x361f70(_0x4b2c46[_0x2414ff('0x0')](0x1f4,_0x15b899[_0x2414ff('0x7')]));});});}; \ No newline at end of file +const a31_0x5610=['rpc','catch','stringify','message','../../mysqldb','create','options','../../config/logger','body','Attachment','then','CreateAttachment','error'];(function(_0x2cd832,_0x56103a){const _0x17dad6=function(_0x493200){while(--_0x493200){_0x2cd832['push'](_0x2cd832['shift']());}};_0x17dad6(++_0x56103a);}(a31_0x5610,0xc6));const a31_0x17da=function(_0x2cd832,_0x56103a){_0x2cd832=_0x2cd832-0x0;let _0x17dad6=a31_0x5610[_0x2cd832];return _0x17dad6;};const _0x4f6e65=a31_0x17da;'use strict';const db=require(_0x4f6e65('0x1'))['db'],logger=require(_0x4f6e65('0x4'))(_0x4f6e65('0xa'));exports[_0x4f6e65('0x8')]=function(_0x493200){const _0x2d60eb=this;return new Promise(function(_0x1a6250,_0x196f19){const _0x263d28=a31_0x17da;return db[_0x263d28('0x6')][_0x263d28('0x2')](_0x493200[_0x263d28('0x5')],{'raw':_0x493200[_0x263d28('0x3')]?_0x493200['options']['raw']===undefined?!![]:![]:!![]})[_0x263d28('0x7')](function(_0x258ad8){const _0xe7bdb6=_0x263d28;logger['info'](_0xe7bdb6('0x8'),_0x493200),logger['debug'](_0xe7bdb6('0x8'),_0x493200,JSON[_0xe7bdb6('0xc')](_0x258ad8)),_0x1a6250(_0x258ad8);})[_0x263d28('0xb')](function(_0x49a6c0){const _0x1046b6=_0x263d28;logger['error'](_0x1046b6('0x8'),_0x49a6c0[_0x1046b6('0x0')],_0x493200),_0x196f19(_0x2d60eb[_0x1046b6('0x9')](0x1f4,_0x49a6c0[_0x1046b6('0x0')]));});});}; \ No newline at end of file diff --git a/server/api/attachment/index.js b/server/api/attachment/index.js index 90ff19a..38991f2 100644 --- a/server/api/attachment/index.js +++ b/server/api/attachment/index.js @@ -1 +1 @@ -const a32_0x49e1=['/:id/clone','exports','put','join','isAuthenticated','multer','../../config/environment','path','file','files/attachments/','delete','now','./attachment.controller','Router','show','post','root','update','download','clone','%s-%s','create','/:id','util','/:id/download','get'];(function(_0x11f6b7,_0x49e17c){const _0x3716ac=function(_0x43154c){while(--_0x43154c){_0x11f6b7['push'](_0x11f6b7['shift']());}};_0x3716ac(++_0x49e17c);}(a32_0x49e1,0xe3));const a32_0x3716=function(_0x11f6b7,_0x49e17c){_0x11f6b7=_0x11f6b7-0x0;let _0x3716ac=a32_0x49e1[_0x11f6b7];return _0x3716ac;};const _0x24624f=a32_0x3716;'use strict';const multer=require(_0x24624f('0xc')),util=require(_0x24624f('0x4')),path=require(_0x24624f('0xe')),express=require('express'),router=express[_0x24624f('0x14')](),auth=require('../../components/auth/service'),config=require(_0x24624f('0xd')),controller=require(_0x24624f('0x13'));router[_0x24624f('0x6')]('/',auth[_0x24624f('0xb')](),controller['index']),router[_0x24624f('0x6')](_0x24624f('0x3'),auth[_0x24624f('0xb')](),controller[_0x24624f('0x15')]),router[_0x24624f('0x6')](_0x24624f('0x5'),auth[_0x24624f('0xb')](),controller[_0x24624f('0x19')]),router[_0x24624f('0x16')](_0x24624f('0x7'),auth[_0x24624f('0xb')](),controller[_0x24624f('0x0')]);const upload=multer({'storage':multer['diskStorage']({'destination':function(_0x43154c,_0x1c8c40,_0x2c5f25){const _0x358046=_0x24624f;_0x2c5f25(null,path[_0x358046('0xa')](config[_0x358046('0x17')],_0x358046('0x10')));},'filename':function(_0x110d1b,_0x5e08ba,_0x5d3c74){const _0x27fa3a=_0x24624f;_0x5d3c74(null,util['format'](_0x27fa3a('0x1'),Date[_0x27fa3a('0x12')](),_0x5e08ba['originalname']['replace'](/[+@&/\\#,+()$~%'":*?<>{}\s\\|]/g,'-')));}})});router[_0x24624f('0x16')]('/',upload['single'](_0x24624f('0xf')),controller[_0x24624f('0x2')]),router[_0x24624f('0x9')](_0x24624f('0x3'),auth[_0x24624f('0xb')](),controller[_0x24624f('0x18')]),router[_0x24624f('0x11')]('/:id',auth[_0x24624f('0xb')](),controller['destroy']),module[_0x24624f('0x8')]=router; \ No newline at end of file +const a32_0x4e1c=['get','%s-%s','post','files/attachments/','create','delete','/:id/clone','./attachment.controller','file','index','now','isAuthenticated','show','destroy','/:id','path','single','express','/:id/download','exports','format','multer','replace','Router','diskStorage','put','../../components/auth/service','../../config/environment'];(function(_0x5c55ea,_0x4e1cee){const _0x3efb00=function(_0x3cb526){while(--_0x3cb526){_0x5c55ea['push'](_0x5c55ea['shift']());}};_0x3efb00(++_0x4e1cee);}(a32_0x4e1c,0x10b));const a32_0x3efb=function(_0x5c55ea,_0x4e1cee){_0x5c55ea=_0x5c55ea-0x0;let _0x3efb00=a32_0x4e1c[_0x5c55ea];return _0x3efb00;};const _0xc0d8f1=a32_0x3efb;'use strict';const multer=require(_0xc0d8f1('0x6')),util=require('util'),path=require(_0xc0d8f1('0x0')),express=require(_0xc0d8f1('0x2')),router=express[_0xc0d8f1('0x8')](),auth=require(_0xc0d8f1('0xb')),config=require(_0xc0d8f1('0xc')),controller=require(_0xc0d8f1('0x14'));router[_0xc0d8f1('0xd')]('/',auth[_0xc0d8f1('0x18')](),controller[_0xc0d8f1('0x16')]),router[_0xc0d8f1('0xd')]('/:id',auth[_0xc0d8f1('0x18')](),controller[_0xc0d8f1('0x19')]),router[_0xc0d8f1('0xd')](_0xc0d8f1('0x3'),auth['isAuthenticated'](),controller['download']),router['post'](_0xc0d8f1('0x13'),auth[_0xc0d8f1('0x18')](),controller['clone']);const upload=multer({'storage':multer[_0xc0d8f1('0x9')]({'destination':function(_0x3cb526,_0x50a128,_0x161fe1){const _0x571f59=_0xc0d8f1;_0x161fe1(null,path['join'](config['root'],_0x571f59('0x10')));},'filename':function(_0x481e98,_0x4d0934,_0x1cc543){const _0x276091=_0xc0d8f1;_0x1cc543(null,util[_0x276091('0x5')](_0x276091('0xe'),Date[_0x276091('0x17')](),_0x4d0934['originalname'][_0x276091('0x7')](/[+@&/\\#,+()$~%'":*?<>{}\s\\|]/g,'-')));}})});router[_0xc0d8f1('0xf')]('/',upload[_0xc0d8f1('0x1')](_0xc0d8f1('0x15')),controller[_0xc0d8f1('0x11')]),router[_0xc0d8f1('0xa')]('/:id',auth[_0xc0d8f1('0x18')](),controller['update']),router[_0xc0d8f1('0x12')](_0xc0d8f1('0x1b'),auth[_0xc0d8f1('0x18')](),controller[_0xc0d8f1('0x1a')]),module[_0xc0d8f1('0x4')]=router; \ No newline at end of file diff --git a/server/api/authGoogle/authGoogle.controller.js b/server/api/authGoogle/authGoogle.controller.js index d905fe4..53abbb4 100644 --- a/server/api/authGoogle/authGoogle.controller.js +++ b/server/api/authGoogle/authGoogle.controller.js @@ -1 +1 @@ -const a33_0xc783=['../../config/utils','blockedAt','then','clearBlockUser','../../mysqldb','use','minutes','/login','user','callback','Setting','disabled','catch','sequelize','findOne','getLicense','authenticate','admin','clientSecret','agent','allowedLoginAttempts','add','../../config/environment','google','profile','blocked','login','Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.','blockDuration','lodash','emails','moment'];(function(_0x508e59,_0xc783db){const _0x249926=function(_0x464c8e){while(--_0x464c8e){_0x508e59['push'](_0x508e59['shift']());}};_0x249926(++_0xc783db);}(a33_0xc783,0x15f));const a33_0x2499=function(_0x508e59,_0xc783db){_0x508e59=_0x508e59-0x0;let _0x249926=a33_0xc783[_0x508e59];return _0x249926;};const _0x2943fa=a33_0x2499;'use strict';const _=require(_0x2943fa('0x1e')),passport=require('passport'),GoogleStrategy=require('passport-google-oauth20')['Strategy'],moment=require(_0x2943fa('0x0')),db=require(_0x2943fa('0x5'))['db'],config=require(_0x2943fa('0x17')),utils=require(_0x2943fa('0x1')),{Op}=require(_0x2943fa('0xe'));exports[_0x2943fa('0x1b')]=passport[_0x2943fa('0x11')](_0x2943fa('0x18'),{'failureRedirect':_0x2943fa('0x8'),'scope':[_0x2943fa('0x19'),'email'],'session':![]}),exports[_0x2943fa('0xa')]=passport[_0x2943fa('0x11')](_0x2943fa('0x18'),{'failureRedirect':_0x2943fa('0x8'),'session':![]}),passport[_0x2943fa('0x6')](new GoogleStrategy({'clientID':config[_0x2943fa('0x18')]?config[_0x2943fa('0x18')]['clientID']:'id','clientSecret':config[_0x2943fa('0x18')]?config['google'][_0x2943fa('0x13')]:'secret','callbackURL':config[_0x2943fa('0x18')]?config[_0x2943fa('0x18')]['callbackURL']:''},function(_0x464c8e,_0x348d85,_0x4094d9,_0x2ed864){const _0x250617=_0x2943fa;let _0x35e06c,_0x1b891f;return db[_0x250617('0xb')][_0x250617('0xf')]({'where':{'id':0x1},'attributes':[_0x250617('0x15'),'blockDuration'],'raw':!![]})['then'](function(_0x409b85){const _0x850dcc=_0x250617;return _0x35e06c=_0x409b85,db['Use'][_0x850dcc('0xf')]({'where':{'email':_['map'](_0x4094d9[_0x850dcc('0x1f')],'value'),'role':{[Op['or']]:[_0x850dcc('0x12'),_0x850dcc('0x9'),_0x850dcc('0x14')]}}});})['then'](function(_0x1a6483){const _0x59206a=_0x250617;_0x1b891f=_0x1a6483;if(_0x1b891f){if(_0x1b891f[_0x59206a('0xc')])return _0x2ed864(_0x59206a('0x1c'));else return _0x35e06c[_0x59206a('0x1d')]>0x0?_0x1b891f[_0x59206a('0x1a')]?moment(_0x1b891f[_0x59206a('0x2')])[_0x59206a('0x16')](_0x35e06c['blockDuration'],_0x59206a('0x7'))>moment()?_0x2ed864(_0x59206a('0x1c')):utils[_0x59206a('0x4')](_0x1b891f,0x0,![],null)[_0x59206a('0x3')](function(){const _0x76046a=_0x59206a;return utils[_0x76046a('0x10')](_0x1b891f);})[_0x59206a('0x3')](function(){return _0x2ed864(null,_0x1b891f);}):utils[_0x59206a('0x10')](_0x1b891f)[_0x59206a('0x3')](function(){return _0x2ed864(null,_0x1b891f);}):utils[_0x59206a('0x10')](_0x1b891f)[_0x59206a('0x3')](function(){return _0x2ed864(null,_0x1b891f);});}return _0x2ed864(_0x59206a('0x1c'));})[_0x250617('0xd')](function(_0x108202){_0x2ed864(_0x108202);});})); \ No newline at end of file +const a33_0x50ad=['sequelize','Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.','getLicense','google','findOne','Strategy','minutes','blockDuration','emails','lodash','agent','login','add','moment','callbackURL','email','blocked','/login','user','passport','then','authenticate','clientSecret','../../config/utils','../../mysqldb','passport-google-oauth20','Setting','callback','Use','allowedLoginAttempts','clearBlockUser','map','value','profile','use'];(function(_0x34199a,_0x50ad4f){const _0x2c6248=function(_0x46bdf4){while(--_0x46bdf4){_0x34199a['push'](_0x34199a['shift']());}};_0x2c6248(++_0x50ad4f);}(a33_0x50ad,0x1d4));const a33_0x2c62=function(_0x34199a,_0x50ad4f){_0x34199a=_0x34199a-0x0;let _0x2c6248=a33_0x50ad[_0x34199a];return _0x2c6248;};const _0x4d0736=a33_0x2c62;'use strict';const _=require(_0x4d0736('0x1f')),passport=require(_0x4d0736('0x6')),GoogleStrategy=require(_0x4d0736('0xc'))[_0x4d0736('0x1b')],moment=require(_0x4d0736('0x0')),db=require(_0x4d0736('0xb'))['db'],config=require('../../config/environment'),utils=require(_0x4d0736('0xa')),{Op}=require(_0x4d0736('0x16'));exports[_0x4d0736('0x21')]=passport[_0x4d0736('0x8')](_0x4d0736('0x19'),{'failureRedirect':'/login','scope':[_0x4d0736('0x14'),_0x4d0736('0x2')],'session':![]}),exports[_0x4d0736('0xe')]=passport[_0x4d0736('0x8')](_0x4d0736('0x19'),{'failureRedirect':_0x4d0736('0x4'),'session':![]}),passport[_0x4d0736('0x15')](new GoogleStrategy({'clientID':config[_0x4d0736('0x19')]?config[_0x4d0736('0x19')]['clientID']:'id','clientSecret':config[_0x4d0736('0x19')]?config[_0x4d0736('0x19')][_0x4d0736('0x9')]:'secret','callbackURL':config[_0x4d0736('0x19')]?config['google'][_0x4d0736('0x1')]:''},function(_0x46bdf4,_0x2bfd0c,_0x3610df,_0x4fe05d){const _0x22690e=_0x4d0736;let _0x4a9e70,_0x2c3130;return db[_0x22690e('0xd')][_0x22690e('0x1a')]({'where':{'id':0x1},'attributes':[_0x22690e('0x10'),_0x22690e('0x1d')],'raw':!![]})[_0x22690e('0x7')](function(_0xfce260){const _0x3ad9e3=_0x22690e;return _0x4a9e70=_0xfce260,db[_0x3ad9e3('0xf')][_0x3ad9e3('0x1a')]({'where':{'email':_[_0x3ad9e3('0x12')](_0x3610df[_0x3ad9e3('0x1e')],_0x3ad9e3('0x13')),'role':{[Op['or']]:['admin',_0x3ad9e3('0x5'),_0x3ad9e3('0x20')]}}});})[_0x22690e('0x7')](function(_0x1250e5){const _0x2c5524=_0x22690e;_0x2c3130=_0x1250e5;if(_0x2c3130){if(_0x2c3130['disabled'])return _0x4fe05d(_0x2c5524('0x17'));else return _0x4a9e70['blockDuration']>0x0?_0x2c3130[_0x2c5524('0x3')]?moment(_0x2c3130['blockedAt'])[_0x2c5524('0x22')](_0x4a9e70[_0x2c5524('0x1d')],_0x2c5524('0x1c'))>moment()?_0x4fe05d(_0x2c5524('0x17')):utils[_0x2c5524('0x11')](_0x2c3130,0x0,![],null)['then'](function(){const _0x5a2653=_0x2c5524;return utils[_0x5a2653('0x18')](_0x2c3130);})['then'](function(){return _0x4fe05d(null,_0x2c3130);}):utils[_0x2c5524('0x18')](_0x2c3130)[_0x2c5524('0x7')](function(){return _0x4fe05d(null,_0x2c3130);}):utils[_0x2c5524('0x18')](_0x2c3130)['then'](function(){return _0x4fe05d(null,_0x2c3130);});}return _0x4fe05d(_0x2c5524('0x17'));})['catch'](function(_0x10b1a8){_0x4fe05d(_0x10b1a8);});})); \ No newline at end of file diff --git a/server/api/authGoogle/index.js b/server/api/authGoogle/index.js index 68bb084..e9c00a4 100644 --- a/server/api/authGoogle/index.js +++ b/server/api/authGoogle/index.js @@ -1 +1 @@ -const a34_0x1105=['setTokenCookie','express','/callback','../user/user.controller.js','isMiddleware','exports','login','Router','../../components/auth/service','get','./authGoogle.controller','callback'];(function(_0x21ceae,_0x110538){const _0x58d36c=function(_0x124087){while(--_0x124087){_0x21ceae['push'](_0x21ceae['shift']());}};_0x58d36c(++_0x110538);}(a34_0x1105,0x15e));const a34_0x58d3=function(_0x21ceae,_0x110538){_0x21ceae=_0x21ceae-0x0;let _0x58d36c=a34_0x1105[_0x21ceae];return _0x58d36c;};const _0x37c86f=a34_0x58d3;'use strict';const express=require(_0x37c86f('0xb')),router=express[_0x37c86f('0x5')](),controller=require(_0x37c86f('0x8')),userController=require(_0x37c86f('0x1')),authService=require(_0x37c86f('0x6'));router[_0x37c86f('0x7')]('/',controller[_0x37c86f('0x4')]),router[_0x37c86f('0x7')](_0x37c86f('0x0'),controller[_0x37c86f('0x9')],authService[_0x37c86f('0x2')],userController[_0x37c86f('0x4')],authService[_0x37c86f('0xa')]),module[_0x37c86f('0x3')]=router; \ No newline at end of file +const a34_0x5121=['../../components/auth/service','./authGoogle.controller','isMiddleware','/callback','Router','get','exports','../user/user.controller.js','login','setTokenCookie'];(function(_0x440b05,_0x51217e){const _0x122e64=function(_0x4a6a16){while(--_0x4a6a16){_0x440b05['push'](_0x440b05['shift']());}};_0x122e64(++_0x51217e);}(a34_0x5121,0x1c6));const a34_0x122e=function(_0x440b05,_0x51217e){_0x440b05=_0x440b05-0x0;let _0x122e64=a34_0x5121[_0x440b05];return _0x122e64;};const _0xd53e6b=a34_0x122e;'use strict';const express=require('express'),router=express[_0xd53e6b('0x0')](),controller=require(_0xd53e6b('0x7')),userController=require(_0xd53e6b('0x3')),authService=require(_0xd53e6b('0x6'));router['get']('/',controller[_0xd53e6b('0x4')]),router[_0xd53e6b('0x1')](_0xd53e6b('0x9'),controller['callback'],authService[_0xd53e6b('0x8')],userController[_0xd53e6b('0x4')],authService[_0xd53e6b('0x5')]),module[_0xd53e6b('0x2')]=router; \ No newline at end of file diff --git a/server/api/authLocal/authLocal.controller.js b/server/api/authLocal/authLocal.controller.js index 477385e..b737e91 100644 --- a/server/api/authLocal/authLocal.controller.js +++ b/server/api/authLocal/authLocal.controller.js @@ -1 +1 @@ -const a35_0x4ddd=['../../components/auth/service','Please\x20click\x20on\x20the\x20following\x20link,\x20or\x20paste\x20this\x20into\x20your\x20browser\x20to\x20complete\x20the\x20process:\x0a\x0a','Smtp','body','authenticate','blockedAt','pass','blockDuration','minutes','You\x20are\x20receiving\x20this\x20because\x20you\x20(or\x20someone\x20else)\x20have\x20requested\x20the\x20reset\x20of\x20the\x20password\x20for\x20your\x20account.\x0a\x0a','sequelize','xCally\x20Motion\x20Password\x20Reset','token','blocked','allowedLoginAttempts','status','previousPasswords','Reset\x20Email\x20sent!','message','email','passport','client','\x22%s\x22\x20<%s>','authentication','validatePasswordPattern','password','port','MailServerOut','User','json','findOne','moment','params','../../config/utils','user','getLicense','login','randomstring','The\x20user\x20is\x20disabled.\x20Please\x20contact\x20the\x20administrator.','catch','Strategy','host','local','admin','http://','role','reset','service','../../mysqldb','request','resetPasswordExpires','Setting','loginAttempts','Password\x20reset!','disabled','passwordHistoryLimit','forgot','Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.','securePassword','This\x20email\x20is\x20not\x20registered.','now','then','http','merge','Email\x20parameter\x20is\x20missing','Password\x20reset\x20token\x20is\x20invalid\x20or\x20has\x20expired.','name','If\x20you\x20did\x20not\x20request\x20this,\x20please\x20ignore\x20this\x20email\x20and\x20your\x20password\x20will\x20remain\x20unchanged.\x0a','secure','generate','save','format','resetPasswordToken','MailAccount','SendMail','clearBlockUser','error','salt','add','send','headers','/reset/','stringify'];(function(_0x21490c,_0x4dddcc){const _0x3004a5=function(_0x53c893){while(--_0x53c893){_0x21490c['push'](_0x21490c['shift']());}};_0x3004a5(++_0x4dddcc);}(a35_0x4ddd,0x15f));const a35_0x3004=function(_0x21490c,_0x4dddcc){_0x21490c=_0x21490c-0x0;let _0x3004a5=a35_0x4ddd[_0x21490c];return _0x3004a5;};const _0x4f7c6b=a35_0x3004;'use strict';const util=require('util'),passport=require(_0x4f7c6b('0x1')),LocalStrategy=require('passport-local')[_0x4f7c6b('0x15')],jayson=require('jayson/promise'),_=require('lodash'),rs=require(_0x4f7c6b('0x12')),moment=require(_0x4f7c6b('0xc')),db=require(_0x4f7c6b('0x1d'))['db'],{Op}=require(_0x4f7c6b('0x4a')),authService=require(_0x4f7c6b('0x40')),utils=require(_0x4f7c6b('0xe')),client=jayson[_0x4f7c6b('0x2')][_0x4f7c6b('0x2b')]({'port':0x232b});function localAuthenticate(_0x53c893,_0x3c5808,_0x4500ad,_0x271470){const _0x647a68=_0x4f7c6b;let _0x39ab9b,_0x20faeb;return db[_0x647a68('0x20')][_0x647a68('0xb')]({'where':{'id':0x1},'attributes':['allowedLoginAttempts',_0x647a68('0x47')],'raw':!![]})[_0x647a68('0x2a')](function(_0x45343f){const _0x805c4f=_0x647a68;return _0x39ab9b=_0x45343f,_0x53c893[_0x805c4f('0xb')]({'attributes':['id',_0x805c4f('0x2f'),_0x805c4f('0x6'),_0x805c4f('0x3a'),_0x805c4f('0x1a'),_0x805c4f('0x23'),_0x805c4f('0x4d'),'blockedAt',_0x805c4f('0x21')],'where':{'name':_0x3c5808,'role':{[Op['or']]:[_0x805c4f('0x18'),'user','agent']}}});})[_0x647a68('0x2a')](function(_0x329fdb){const _0x418a52=_0x647a68;if(!_0x329fdb||_0x329fdb&&_0x329fdb['name']!==_0x3c5808)throw new Error(_0x418a52('0x26'));else return _0x20faeb=_0x329fdb,_0x20faeb;})[_0x647a68('0x2a')](function(){_0x20faeb['authenticate'](_0x4500ad,function(_0x5d84b9,_0x989cf0){const _0x3e5dbd=a35_0x3004,_0x58e035=_0x20faeb[_0x3e5dbd('0x21')]+0x1;if(_0x5d84b9)return _0x271470(_0x5d84b9);else{if(!_0x989cf0){if(_0x20faeb[_0x3e5dbd('0x23')])return _0x271470(null,![],{'message':_0x3e5dbd('0x26')});else return _0x39ab9b['allowedLoginAttempts']>0x0?_0x20faeb[_0x3e5dbd('0x4d')]?_0x39ab9b[_0x3e5dbd('0x47')]>0x0?moment(_0x20faeb['blockedAt'])[_0x3e5dbd('0x3b')](_0x39ab9b[_0x3e5dbd('0x47')],_0x3e5dbd('0x48'))>moment()?_0x271470(null,![],{'message':'Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.'}):utils[_0x3e5dbd('0x38')](_0x20faeb,_0x58e035,![],null)[_0x3e5dbd('0x2a')](function(){const _0x40e779=_0x3e5dbd;return _0x271470(null,![],{'message':_0x40e779('0x26')});}):_0x271470(null,![],{'message':'Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.'}):_0x58e035>=_0x39ab9b[_0x3e5dbd('0x4e')]?utils[_0x3e5dbd('0x38')](_0x20faeb,0x0,!![],moment())['then'](function(){const _0x2cdd53=_0x3e5dbd;return _0x271470(null,![],{'message':_0x2cdd53('0x26')});}):utils['clearBlockUser'](_0x20faeb,_0x58e035,![],null)['then'](function(){const _0xa23434=_0x3e5dbd;return _0x271470(null,![],{'message':_0xa23434('0x26')});}):_0x271470(null,![],{'message':_0x3e5dbd('0x26')});}else{if(_0x20faeb[_0x3e5dbd('0x23')])return _0x271470(null,![],{'message':_0x3e5dbd('0x26')});else return _0x39ab9b['allowedLoginAttempts']>0x0?_0x20faeb[_0x3e5dbd('0x4d')]?_0x39ab9b[_0x3e5dbd('0x47')]>0x0?moment(_0x20faeb['blockedAt'])[_0x3e5dbd('0x3b')](_0x39ab9b[_0x3e5dbd('0x47')],_0x3e5dbd('0x48'))>moment()?_0x271470(null,![],{'message':_0x3e5dbd('0x26')}):utils[_0x3e5dbd('0x38')](_0x20faeb,0x0,![],null)['then'](function(){const _0x2e9ecf=_0x3e5dbd;return utils[_0x2e9ecf('0x10')](_0x20faeb);})[_0x3e5dbd('0x2a')](function(){return _0x271470(null,_0x20faeb);}):_0x271470(null,![],{'message':'Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.'}):utils[_0x3e5dbd('0x38')](_0x20faeb,0x0,![],null)[_0x3e5dbd('0x2a')](function(){return utils['getLicense'](_0x20faeb);})[_0x3e5dbd('0x2a')](function(){return _0x271470(null,_0x20faeb);})['catch'](function(_0x4a34b0){return _0x271470(null,![],_0x4a34b0);}):_0x20faeb[_0x3e5dbd('0x4d')]?_0x271470(null,![],{'message':'Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.'}):utils[_0x3e5dbd('0x10')](_0x20faeb)[_0x3e5dbd('0x2a')](function(){return _0x271470(null,_0x20faeb);});}}});})['catch'](function(_0x48d004){return _0x271470(null,![],_0x48d004);});}function sendServiceMail(_0x2e37dd){const _0x79ed66=_0x4f7c6b;return db[_0x79ed66('0x36')][_0x79ed66('0xb')]({'where':{'service':!![]},'attributes':['id',_0x79ed66('0x2f'),'email'],'include':[{'model':db[_0x79ed66('0x8')],'as':_0x79ed66('0x42')}]})['then'](function(_0x49626c){const _0xc7f8f1=_0x79ed66;if(!_0x49626c)throw new Error('Unable\x20to\x20find\x20a\x20configured\x20SMTP\x20service!');const _0x340a9f={'tls':{'rejectUnauthorized':![]}};_0x49626c[_0xc7f8f1('0x42')][_0xc7f8f1('0x1c')]?_0x340a9f[_0xc7f8f1('0x1c')]=_0x49626c[_0xc7f8f1('0x42')][_0xc7f8f1('0x1c')]:(_0x340a9f['host']=_0x49626c[_0xc7f8f1('0x42')]['host'],_0x340a9f['port']=_0x49626c[_0xc7f8f1('0x42')][_0xc7f8f1('0x7')],_0x340a9f['secure']=_0x49626c[_0xc7f8f1('0x42')][_0xc7f8f1('0x31')]);_0x49626c['Smtp'][_0xc7f8f1('0x4')]&&(_0x340a9f['auth']={'user':_0x49626c[_0xc7f8f1('0x42')][_0xc7f8f1('0xf')],'pass':_0x49626c[_0xc7f8f1('0x42')][_0xc7f8f1('0x46')]});const _0x2da9bc={'account':_0x340a9f,'message':_[_0xc7f8f1('0x2c')]({'from':util['format'](_0xc7f8f1('0x3'),_0x49626c[_0xc7f8f1('0x2f')],_0x49626c['email']||_0x49626c[_0xc7f8f1('0x42')][_0xc7f8f1('0xf')])},_0x2e37dd)};return client[_0xc7f8f1('0x1e')](_0xc7f8f1('0x37'),_0x2da9bc);})[_0x79ed66('0x2a')](function(_0x556898){const _0x4c868a=_0x79ed66;if(_0x556898[_0x4c868a('0x39')])throw new Error(util[_0x4c868a('0x34')]('SendMail\x20error:\x20%s.\x20Please\x20contact\x20your\x20Administrator!',_0x556898[_0x4c868a('0x39')]['message']||JSON[_0x4c868a('0x3f')](_0x556898[_0x4c868a('0x39')])));return!![];});}function handleError(_0x2d17e0,_0x42fe3e,_0x304386){const _0x4287f4=_0x4f7c6b;return _0x2d17e0[_0x4287f4('0x4f')](_0x42fe3e||0x1f4)['send']({'message':_0x304386?_0x304386[_0x4287f4('0x52')]||_0x304386:''});}exports[_0x4f7c6b('0x11')]=function(_0x53708c,_0x36484f,_0x59baa9){const _0xdf68e3=_0x4f7c6b;passport[_0xdf68e3('0x44')](_0xdf68e3('0x17'),function(_0x17790e,_0x49d104,_0x29f54d){const _0x3dcdd1=_0x17790e||_0x29f54d;if(_0x3dcdd1)return handleError(_0x36484f,0x191,_0x3dcdd1);if(!_0x49d104)return handleError(_0x36484f,0x194,{'message':'Something\x20went\x20wrong,\x20please\x20try\x20again.'});else{const _0x408543={'payload':{'id':_0x49d104['id'],'role':_0x49d104['role']},'options':{'expiresIn':0x15180}};return authService['signToken'](_0x408543)['then'](function(_0x582807){const _0xa90401=a35_0x3004;_0x36484f[_0xa90401('0xa')]({'id':_0x49d104['id'],'token':_0x582807,'statusCall':'','isAlreadyLogged':_0x49d104['online']});});}})(_0x53708c,_0x36484f,_0x59baa9);},exports[_0x4f7c6b('0x25')]=function(_0x279124,_0x66437e){const _0x3fec23=_0x4f7c6b;if(!_0x279124[_0x3fec23('0x43')][_0x3fec23('0x0')])return handleError(_0x66437e,0x1f4,{'message':_0x3fec23('0x2d')});const _0x23f5bd=rs[_0x3fec23('0x32')]();_0x279124[_0x3fec23('0x43')][_0x3fec23('0x0')]=_0x279124['body']['email']['trim']()['toLowerCase']();let _0x40ac63;return db[_0x3fec23('0x20')][_0x3fec23('0xb')]({'where':{'id':0x1},'attributes':[_0x3fec23('0x4e'),_0x3fec23('0x47')],'raw':!![]})['then'](function(_0x88f52c){const _0x569c4a=_0x3fec23;return _0x40ac63=_0x88f52c,db['Use'][_0x569c4a('0xb')]({'where':{'email':_0x279124[_0x569c4a('0x43')][_0x569c4a('0x0')]}});})['then'](function(_0x3127ef){const _0x50bafd=_0x3fec23;if(!_0x3127ef)throw new Error(_0x50bafd('0x28'));if(_0x3127ef['disabled'])throw new Error(_0x50bafd('0x13'));if(_0x3127ef[_0x50bafd('0x4d')]){if(moment(_0x3127ef[_0x50bafd('0x45')])['add'](_0x40ac63[_0x50bafd('0x47')],'minutes')>moment())throw new Error('The\x20user\x20is\x20blocked.\x20Please\x20contact\x20the\x20administrator.');else _0x3127ef['blocked']=![],_0x3127ef[_0x50bafd('0x45')]=null;}return _0x3127ef[_0x50bafd('0x35')]=_0x23f5bd,_0x3127ef[_0x50bafd('0x1f')]=Date[_0x50bafd('0x29')]()+0x36ee80,_0x3127ef[_0x50bafd('0x33')]();})['then'](function(){const _0x128338=_0x3fec23;return sendServiceMail({'to':_0x279124[_0x128338('0x43')][_0x128338('0x0')],'subject':_0x128338('0x4b'),'text':_0x128338('0x49')+_0x128338('0x41')+_0x128338('0x19')+_0x279124[_0x128338('0x3d')][_0x128338('0x16')]+_0x128338('0x3e')+_0x23f5bd+'\x0a\x0a'+_0x128338('0x30')});})[_0x3fec23('0x2a')](function(){const _0x2ea162=_0x3fec23;_0x66437e['status'](0xc8)[_0x2ea162('0x3c')]({'message':_0x2ea162('0x51')});})[_0x3fec23('0x14')](function(_0x185439){return handleError(_0x66437e,0x1f4,_0x185439);});},exports[_0x4f7c6b('0x1b')]=function(_0x205fff,_0x4f179b){const _0x3db785=_0x4f7c6b;return db[_0x3db785('0x9')]['findOne']({'where':{'resetPasswordToken':_0x205fff[_0x3db785('0xd')][_0x3db785('0x4c')],'resetPasswordExpires':{[Op['gt']]:Date['now']()}}})[_0x3db785('0x2a')](function(_0x4ed7a2){const _0x1885d0=_0x3db785;if(!_0x4ed7a2)throw new Error(_0x1885d0('0x2e'));return db[_0x1885d0('0x20')]['findOne']({'attributes':['id',_0x1885d0('0x27'),'enforcePasswordHistory',_0x1885d0('0x24')]})[_0x1885d0('0x2a')](function(_0x5eea6b){const _0x3e4dac=_0x1885d0;if(_0x5eea6b['securePassword'])authService[_0x3e4dac('0x5')](_0x205fff['body'][_0x3e4dac('0x6')]);if(!_0x5eea6b['enforcePasswordHistory']||!_0x4ed7a2[_0x3e4dac('0x50')])return _0x4ed7a2;return authService['validatePasswordHistory'](_0x205fff[_0x3e4dac('0x43')][_0x3e4dac('0x6')],_0x4ed7a2[_0x3e4dac('0x50')],_0x5eea6b[_0x3e4dac('0x24')]),_0x4ed7a2;})['then'](function(){const _0xa29980=_0x1885d0;return _0x4ed7a2[_0xa29980('0x6')]=_0x205fff[_0xa29980('0x43')]['password'],_0x4ed7a2['resetPasswordToken']=null,_0x4ed7a2['resetPasswordExpires']=null,_0x4ed7a2['save']();});})['then'](function(){const _0x32e21b=_0x3db785;_0x4f179b['status'](0xc8)[_0x32e21b('0x3c')]({'message':_0x32e21b('0x22')});})[_0x3db785('0x14')](function(_0x143074){return handleError(_0x4f179b,0x1f4,_0x143074);});},passport['use'](new LocalStrategy({'usernameField':_0x4f7c6b('0x2f'),'passwordField':_0x4f7c6b('0x6')},function(_0x51afad,_0xa6fea,_0x579865){const _0x26c18e=_0x4f7c6b;return localAuthenticate(db[_0x26c18e('0x9')],_0x51afad,_0xa6fea,_0x579865);})); \ No newline at end of file +const a35_0x440b=['Use','agent','/reset/','loginAttempts','previousPasswords','admin','passport','authentication','blocked','MailServerOut','Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.','now','Strategy','service','save','Password\x20reset\x20token\x20is\x20invalid\x20or\x20has\x20expired.','error','../../config/utils','generate','Setting','disabled','http','format','../../mysqldb','authenticate','send','blockedAt','passport-local','body','Reset\x20Email\x20sent!','catch','reset','Email\x20parameter\x20is\x20missing','host','merge','blockDuration','port','then','password','Password\x20reset!','Something\x20went\x20wrong,\x20please\x20try\x20again.','Unable\x20to\x20find\x20a\x20configured\x20SMTP\x20service!','resetPasswordToken','securePassword','add','toLowerCase','name','clearBlockUser','message','headers','User','login','local','SendMail\x20error:\x20%s.\x20Please\x20contact\x20your\x20Administrator!','http://','trim','Smtp','allowedLoginAttempts','client','pass','lodash','getLicense','minutes','signToken','use','The\x20user\x20is\x20blocked.\x20Please\x20contact\x20the\x20administrator.','request','role','findOne','validatePasswordHistory','user','online','jayson/promise','params','forgot','validatePasswordPattern','status','If\x20you\x20did\x20not\x20request\x20this,\x20please\x20ignore\x20this\x20email\x20and\x20your\x20password\x20will\x20remain\x20unchanged.\x0a','enforcePasswordHistory','email','resetPasswordExpires'];(function(_0x59ee1d,_0x440b36){const _0x4f8c63=function(_0x12d44d){while(--_0x12d44d){_0x59ee1d['push'](_0x59ee1d['shift']());}};_0x4f8c63(++_0x440b36);}(a35_0x440b,0x8b));const a35_0x4f8c=function(_0x59ee1d,_0x440b36){_0x59ee1d=_0x59ee1d-0x0;let _0x4f8c63=a35_0x440b[_0x59ee1d];return _0x4f8c63;};const _0x2f5f80=a35_0x4f8c;'use strict';const util=require('util'),passport=require(_0x2f5f80('0x1d')),LocalStrategy=require(_0x2f5f80('0x32'))[_0x2f5f80('0x23')],jayson=require(_0x2f5f80('0xe')),_=require(_0x2f5f80('0x2')),rs=require('randomstring'),moment=require('moment'),db=require(_0x2f5f80('0x2e'))['db'],{Op}=require('sequelize'),authService=require('../../components/auth/service'),utils=require(_0x2f5f80('0x28')),client=jayson[_0x2f5f80('0x0')][_0x2f5f80('0x2c')]({'port':0x232b});function localAuthenticate(_0x12d44d,_0x20802f,_0x38230b,_0x1a0151){const _0x554a5b=_0x2f5f80;let _0x2b1652,_0x2c6596;return db['Setting'][_0x554a5b('0xa')]({'where':{'id':0x1},'attributes':[_0x554a5b('0x50'),'blockDuration'],'raw':!![]})['then'](function(_0x261757){const _0x22ddfa=_0x554a5b;return _0x2b1652=_0x261757,_0x12d44d[_0x22ddfa('0xa')]({'attributes':['id','name','password','salt',_0x22ddfa('0x9'),_0x22ddfa('0x2b'),_0x22ddfa('0x1f'),_0x22ddfa('0x31'),'loginAttempts'],'where':{'name':_0x20802f,'role':{[Op['or']]:[_0x22ddfa('0x1c'),_0x22ddfa('0xc'),_0x22ddfa('0x18')]}}});})['then'](function(_0x19e758){const _0x58f9c6=_0x554a5b;if(!_0x19e758||_0x19e758&&_0x19e758['name']!==_0x20802f)throw new Error(_0x58f9c6('0x21'));else return _0x2c6596=_0x19e758,_0x2c6596;})['then'](function(){const _0x5df9e1=_0x554a5b;_0x2c6596[_0x5df9e1('0x2f')](_0x38230b,function(_0x5425f7,_0x25b5ab){const _0x4dac5b=_0x5df9e1,_0x339bf3=_0x2c6596[_0x4dac5b('0x1a')]+0x1;if(_0x5425f7)return _0x1a0151(_0x5425f7);else{if(!_0x25b5ab){if(_0x2c6596[_0x4dac5b('0x2b')])return _0x1a0151(null,![],{'message':'Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.'});else return _0x2b1652[_0x4dac5b('0x50')]>0x0?_0x2c6596['blocked']?_0x2b1652[_0x4dac5b('0x3a')]>0x0?moment(_0x2c6596[_0x4dac5b('0x31')])['add'](_0x2b1652['blockDuration'],_0x4dac5b('0x4'))>moment()?_0x1a0151(null,![],{'message':_0x4dac5b('0x21')}):utils['clearBlockUser'](_0x2c6596,_0x339bf3,![],null)[_0x4dac5b('0x3c')](function(){const _0x349519=_0x4dac5b;return _0x1a0151(null,![],{'message':_0x349519('0x21')});}):_0x1a0151(null,![],{'message':_0x4dac5b('0x21')}):_0x339bf3>=_0x2b1652[_0x4dac5b('0x50')]?utils[_0x4dac5b('0x46')](_0x2c6596,0x0,!![],moment())[_0x4dac5b('0x3c')](function(){return _0x1a0151(null,![],{'message':'Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.'});}):utils[_0x4dac5b('0x46')](_0x2c6596,_0x339bf3,![],null)['then'](function(){const _0x3afa8d=_0x4dac5b;return _0x1a0151(null,![],{'message':_0x3afa8d('0x21')});}):_0x1a0151(null,![],{'message':_0x4dac5b('0x21')});}else{if(_0x2c6596[_0x4dac5b('0x2b')])return _0x1a0151(null,![],{'message':'Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.'});else return _0x2b1652['allowedLoginAttempts']>0x0?_0x2c6596[_0x4dac5b('0x1f')]?_0x2b1652[_0x4dac5b('0x3a')]>0x0?moment(_0x2c6596['blockedAt'])['add'](_0x2b1652[_0x4dac5b('0x3a')],_0x4dac5b('0x4'))>moment()?_0x1a0151(null,![],{'message':'Incorrect\x20username\x20and/or\x20password.\x20Please\x20retry\x20again\x20or\x20contact\x20the\x20administrator.'}):utils['clearBlockUser'](_0x2c6596,0x0,![],null)[_0x4dac5b('0x3c')](function(){const _0x3ba5c5=_0x4dac5b;return utils[_0x3ba5c5('0x3')](_0x2c6596);})[_0x4dac5b('0x3c')](function(){return _0x1a0151(null,_0x2c6596);}):_0x1a0151(null,![],{'message':_0x4dac5b('0x21')}):utils[_0x4dac5b('0x46')](_0x2c6596,0x0,![],null)[_0x4dac5b('0x3c')](function(){const _0x33b8b6=_0x4dac5b;return utils[_0x33b8b6('0x3')](_0x2c6596);})[_0x4dac5b('0x3c')](function(){return _0x1a0151(null,_0x2c6596);})[_0x4dac5b('0x35')](function(_0x53a9de){return _0x1a0151(null,![],_0x53a9de);}):_0x2c6596[_0x4dac5b('0x1f')]?_0x1a0151(null,![],{'message':_0x4dac5b('0x21')}):utils[_0x4dac5b('0x3')](_0x2c6596)[_0x4dac5b('0x3c')](function(){return _0x1a0151(null,_0x2c6596);});}}});})[_0x554a5b('0x35')](function(_0x513477){return _0x1a0151(null,![],_0x513477);});}function sendServiceMail(_0x5f55a4){const _0x24e350=_0x2f5f80;return db['MailAccount'][_0x24e350('0xa')]({'where':{'service':!![]},'attributes':['id','name',_0x24e350('0x15')],'include':[{'model':db[_0x24e350('0x20')],'as':_0x24e350('0x4f')}]})[_0x24e350('0x3c')](function(_0x2c5cb6){const _0x84b072=_0x24e350;if(!_0x2c5cb6)throw new Error(_0x84b072('0x40'));const _0x5a1b0a={'tls':{'rejectUnauthorized':![]}};_0x2c5cb6[_0x84b072('0x4f')]['service']?_0x5a1b0a[_0x84b072('0x24')]=_0x2c5cb6['Smtp'][_0x84b072('0x24')]:(_0x5a1b0a['host']=_0x2c5cb6[_0x84b072('0x4f')][_0x84b072('0x38')],_0x5a1b0a[_0x84b072('0x3b')]=_0x2c5cb6[_0x84b072('0x4f')]['port'],_0x5a1b0a['secure']=_0x2c5cb6[_0x84b072('0x4f')]['secure']);_0x2c5cb6[_0x84b072('0x4f')][_0x84b072('0x1e')]&&(_0x5a1b0a['auth']={'user':_0x2c5cb6['Smtp'][_0x84b072('0xc')],'pass':_0x2c5cb6['Smtp'][_0x84b072('0x1')]});const _0x4b7fd2={'account':_0x5a1b0a,'message':_[_0x84b072('0x39')]({'from':util[_0x84b072('0x2d')]('\x22%s\x22\x20<%s>',_0x2c5cb6['name'],_0x2c5cb6[_0x84b072('0x15')]||_0x2c5cb6[_0x84b072('0x4f')][_0x84b072('0xc')])},_0x5f55a4)};return client[_0x84b072('0x8')]('SendMail',_0x4b7fd2);})['then'](function(_0x25c207){const _0x3c5b88=_0x24e350;if(_0x25c207['error'])throw new Error(util[_0x3c5b88('0x2d')](_0x3c5b88('0x4c'),_0x25c207[_0x3c5b88('0x27')][_0x3c5b88('0x47')]||JSON['stringify'](_0x25c207['error'])));return!![];});}function handleError(_0x17fde6,_0x10124a,_0x2ef975){const _0x26b4ec=_0x2f5f80;return _0x17fde6[_0x26b4ec('0x12')](_0x10124a||0x1f4)[_0x26b4ec('0x30')]({'message':_0x2ef975?_0x2ef975['message']||_0x2ef975:''});}exports[_0x2f5f80('0x4a')]=function(_0x35f7e6,_0xb7e5b7,_0x499a22){const _0x57e0cd=_0x2f5f80;passport[_0x57e0cd('0x2f')](_0x57e0cd('0x4b'),function(_0x2c7f8b,_0x9e1a52,_0xdcac12){const _0x5a99b2=_0x57e0cd,_0x489375=_0x2c7f8b||_0xdcac12;if(_0x489375)return handleError(_0xb7e5b7,0x191,_0x489375);if(!_0x9e1a52)return handleError(_0xb7e5b7,0x194,{'message':_0x5a99b2('0x3f')});else{const _0x5cc94e={'payload':{'id':_0x9e1a52['id'],'role':_0x9e1a52[_0x5a99b2('0x9')]},'options':{'expiresIn':0x15180}};return authService[_0x5a99b2('0x5')](_0x5cc94e)['then'](function(_0x17516f){const _0x5d0ccc=_0x5a99b2;_0xb7e5b7['json']({'id':_0x9e1a52['id'],'token':_0x17516f,'statusCall':'','isAlreadyLogged':_0x9e1a52[_0x5d0ccc('0xd')]});});}})(_0x35f7e6,_0xb7e5b7,_0x499a22);},exports[_0x2f5f80('0x10')]=function(_0x2357ec,_0x54b8f2){const _0x22a0f7=_0x2f5f80;if(!_0x2357ec['body']['email'])return handleError(_0x54b8f2,0x1f4,{'message':_0x22a0f7('0x37')});const _0x60d12c=rs[_0x22a0f7('0x29')]();_0x2357ec[_0x22a0f7('0x33')][_0x22a0f7('0x15')]=_0x2357ec[_0x22a0f7('0x33')][_0x22a0f7('0x15')][_0x22a0f7('0x4e')]()[_0x22a0f7('0x44')]();let _0x1245cd;return db[_0x22a0f7('0x2a')][_0x22a0f7('0xa')]({'where':{'id':0x1},'attributes':[_0x22a0f7('0x50'),_0x22a0f7('0x3a')],'raw':!![]})[_0x22a0f7('0x3c')](function(_0x5eb038){const _0x4869af=_0x22a0f7;return _0x1245cd=_0x5eb038,db[_0x4869af('0x17')][_0x4869af('0xa')]({'where':{'email':_0x2357ec[_0x4869af('0x33')]['email']}});})[_0x22a0f7('0x3c')](function(_0x1501f2){const _0x29b508=_0x22a0f7;if(!_0x1501f2)throw new Error('This\x20email\x20is\x20not\x20registered.');if(_0x1501f2['disabled'])throw new Error('The\x20user\x20is\x20disabled.\x20Please\x20contact\x20the\x20administrator.');if(_0x1501f2[_0x29b508('0x1f')]){if(moment(_0x1501f2['blockedAt'])[_0x29b508('0x43')](_0x1245cd[_0x29b508('0x3a')],_0x29b508('0x4'))>moment())throw new Error(_0x29b508('0x7'));else _0x1501f2[_0x29b508('0x1f')]=![],_0x1501f2[_0x29b508('0x31')]=null;}return _0x1501f2['resetPasswordToken']=_0x60d12c,_0x1501f2[_0x29b508('0x16')]=Date[_0x29b508('0x22')]()+0x36ee80,_0x1501f2[_0x29b508('0x25')]();})[_0x22a0f7('0x3c')](function(){const _0xf16b6d=_0x22a0f7;return sendServiceMail({'to':_0x2357ec[_0xf16b6d('0x33')][_0xf16b6d('0x15')],'subject':'xCally\x20Motion\x20Password\x20Reset','text':'You\x20are\x20receiving\x20this\x20because\x20you\x20(or\x20someone\x20else)\x20have\x20requested\x20the\x20reset\x20of\x20the\x20password\x20for\x20your\x20account.\x0a\x0a'+'Please\x20click\x20on\x20the\x20following\x20link,\x20or\x20paste\x20this\x20into\x20your\x20browser\x20to\x20complete\x20the\x20process:\x0a\x0a'+_0xf16b6d('0x4d')+_0x2357ec[_0xf16b6d('0x48')][_0xf16b6d('0x38')]+_0xf16b6d('0x19')+_0x60d12c+'\x0a\x0a'+_0xf16b6d('0x13')});})[_0x22a0f7('0x3c')](function(){const _0x335d66=_0x22a0f7;_0x54b8f2['status'](0xc8)[_0x335d66('0x30')]({'message':_0x335d66('0x34')});})['catch'](function(_0xc9e63b){return handleError(_0x54b8f2,0x1f4,_0xc9e63b);});},exports[_0x2f5f80('0x36')]=function(_0x4dd241,_0x5406b2){const _0x1fc248=_0x2f5f80;return db[_0x1fc248('0x49')][_0x1fc248('0xa')]({'where':{'resetPasswordToken':_0x4dd241[_0x1fc248('0xf')]['token'],'resetPasswordExpires':{[Op['gt']]:Date[_0x1fc248('0x22')]()}}})[_0x1fc248('0x3c')](function(_0x571dfc){const _0x5c1798=_0x1fc248;if(!_0x571dfc)throw new Error(_0x5c1798('0x26'));return db[_0x5c1798('0x2a')][_0x5c1798('0xa')]({'attributes':['id',_0x5c1798('0x42'),_0x5c1798('0x14'),'passwordHistoryLimit']})['then'](function(_0x1a88a6){const _0x5537a1=_0x5c1798;if(_0x1a88a6[_0x5537a1('0x42')])authService[_0x5537a1('0x11')](_0x4dd241[_0x5537a1('0x33')][_0x5537a1('0x3d')]);if(!_0x1a88a6[_0x5537a1('0x14')]||!_0x571dfc[_0x5537a1('0x1b')])return _0x571dfc;return authService[_0x5537a1('0xb')](_0x4dd241['body']['password'],_0x571dfc[_0x5537a1('0x1b')],_0x1a88a6['passwordHistoryLimit']),_0x571dfc;})[_0x5c1798('0x3c')](function(){const _0x2f37e8=_0x5c1798;return _0x571dfc['password']=_0x4dd241['body'][_0x2f37e8('0x3d')],_0x571dfc[_0x2f37e8('0x41')]=null,_0x571dfc[_0x2f37e8('0x16')]=null,_0x571dfc[_0x2f37e8('0x25')]();});})[_0x1fc248('0x3c')](function(){const _0x35cc81=_0x1fc248;_0x5406b2[_0x35cc81('0x12')](0xc8)[_0x35cc81('0x30')]({'message':_0x35cc81('0x3e')});})[_0x1fc248('0x35')](function(_0x1a6923){return handleError(_0x5406b2,0x1f4,_0x1a6923);});},passport[_0x2f5f80('0x6')](new LocalStrategy({'usernameField':_0x2f5f80('0x45'),'passwordField':_0x2f5f80('0x3d')},function(_0x1cb2b1,_0x16702f,_0x238c6e){const _0x4afe76=_0x2f5f80;return localAuthenticate(db[_0x4afe76('0x49')],_0x1cb2b1,_0x16702f,_0x238c6e);})); \ No newline at end of file diff --git a/server/api/authLocal/index.js b/server/api/authLocal/index.js index ace297b..d60c6a9 100644 --- a/server/api/authLocal/index.js +++ b/server/api/authLocal/index.js @@ -1 +1 @@ -const a36_0x3dbe=['./authLocal.controller','login','post','/reset/:token','forgot','Router','express'];(function(_0x2d1003,_0x3dbe63){const _0x2fb9ff=function(_0x329a25){while(--_0x329a25){_0x2d1003['push'](_0x2d1003['shift']());}};_0x2fb9ff(++_0x3dbe63);}(a36_0x3dbe,0x176));const a36_0x2fb9=function(_0x2d1003,_0x3dbe63){_0x2d1003=_0x2d1003-0x0;let _0x2fb9ff=a36_0x3dbe[_0x2d1003];return _0x2fb9ff;};const _0x562a5a=a36_0x2fb9;'use strict';const express=require(_0x562a5a('0x3')),router=express[_0x562a5a('0x2')](),controller=require(_0x562a5a('0x4'));router['post']('/',controller[_0x562a5a('0x5')]),router[_0x562a5a('0x6')]('/forgot',controller[_0x562a5a('0x1')]),router[_0x562a5a('0x6')](_0x562a5a('0x0'),controller['reset']),module['exports']=router; \ No newline at end of file +const a36_0x2772=['exports','Router','login','./authLocal.controller','post','/forgot','/reset/:token'];(function(_0x509fc9,_0x27725d){const _0x32dbea=function(_0x5e3670){while(--_0x5e3670){_0x509fc9['push'](_0x509fc9['shift']());}};_0x32dbea(++_0x27725d);}(a36_0x2772,0x1d3));const a36_0x32db=function(_0x509fc9,_0x27725d){_0x509fc9=_0x509fc9-0x0;let _0x32dbea=a36_0x2772[_0x509fc9];return _0x32dbea;};const _0x5e9eee=a36_0x32db;'use strict';const express=require('express'),router=express[_0x5e9eee('0x3')](),controller=require(_0x5e9eee('0x5'));router[_0x5e9eee('0x6')]('/',controller[_0x5e9eee('0x4')]),router[_0x5e9eee('0x6')](_0x5e9eee('0x0'),controller['forgot']),router['post'](_0x5e9eee('0x1'),controller['reset']),module[_0x5e9eee('0x2')]=router; \ No newline at end of file diff --git a/server/api/automation/automation.attributes.js b/server/api/automation/automation.attributes.js index 5106bf2..48ea2da 100644 --- a/server/api/automation/automation.attributes.js +++ b/server/api/automation/automation.attributes.js @@ -1 +1 @@ -const a37_0x4eb3=['INTEGER','exports','STRING'];(function(_0x1d6f13,_0x4eb362){const _0x17b5dc=function(_0x4f3843){while(--_0x4f3843){_0x1d6f13['push'](_0x1d6f13['shift']());}};_0x17b5dc(++_0x4eb362);}(a37_0x4eb3,0x197));const a37_0x17b5=function(_0x1d6f13,_0x4eb362){_0x1d6f13=_0x1d6f13-0x0;let _0x17b5dc=a37_0x4eb3[_0x1d6f13];return _0x17b5dc;};const _0x1569b7=a37_0x17b5;'use strict';const Sequelize=require('sequelize');module[_0x1569b7('0x2')]={'name':{'type':Sequelize[_0x1569b7('0x0')],'allowNull':![]},'channel':{'type':Sequelize[_0x1569b7('0x0')]},'description':{'type':Sequelize[_0x1569b7('0x0')]},'status':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'timeout':{'type':Sequelize[_0x1569b7('0x1')],'defaultValue':0xa}}; \ No newline at end of file +const a37_0x42e6=['exports','STRING','INTEGER','BOOLEAN'];(function(_0x40333d,_0x42e682){const _0x41d5d2=function(_0x508791){while(--_0x508791){_0x40333d['push'](_0x40333d['shift']());}};_0x41d5d2(++_0x42e682);}(a37_0x42e6,0x144));const a37_0x41d5=function(_0x40333d,_0x42e682){_0x40333d=_0x40333d-0x0;let _0x41d5d2=a37_0x42e6[_0x40333d];return _0x41d5d2;};const _0x5962d4=a37_0x41d5;'use strict';const Sequelize=require('sequelize');module[_0x5962d4('0x0')]={'name':{'type':Sequelize[_0x5962d4('0x1')],'allowNull':![]},'channel':{'type':Sequelize['STRING']},'description':{'type':Sequelize[_0x5962d4('0x1')]},'status':{'type':Sequelize[_0x5962d4('0x3')],'defaultValue':![]},'timeout':{'type':Sequelize[_0x5962d4('0x2')],'defaultValue':0xa}}; \ No newline at end of file diff --git a/server/api/automation/automation.controller.js b/server/api/automation/automation.controller.js index 26eabb6..9ea07e0 100644 --- a/server/api/automation/automation.controller.js +++ b/server/api/automation/automation.controller.js @@ -1 +1 @@ -const a38_0x10a0=['key','send','order','Automation','addActions','undefined','like','length','getActions','body','sequelize','where','options','filters','sendStatus','json','set','catch','name','include','destroy','create','Content-Range','keys','Condition','findAll','offset','nolimit','findOne','attributes','type','model','api','pick','limit','end','intersection','stack','query','rows','fieldName','merge','status','omit','rawAttributes','params','filter','getConditions','show','error','Action','ids','then','VIRTUAL','sort','fields','addConditions','map','update','count','../../mysqldb'];(function(_0x55214b,_0x10a08b){const _0x2a8d6a=function(_0x3a3c94){while(--_0x3a3c94){_0x55214b['push'](_0x55214b['shift']());}};_0x2a8d6a(++_0x10a08b);}(a38_0x10a0,0x86));const a38_0x2a8d=function(_0x55214b,_0x10a08b){_0x55214b=_0x55214b-0x0;let _0x2a8d6a=a38_0x10a0[_0x55214b];return _0x2a8d6a;};const _0x2f5074=a38_0x2a8d;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x2f5074('0x14')),db=require(_0x2f5074('0x30'))['db'],{Op}=require(_0x2f5074('0x3b'));function respondWithResult(_0x3a3c94,_0x5ddc34){return _0x5ddc34=_0x5ddc34||0xc8,function(_0x570eec){const _0x1b0b37=a38_0x2a8d;if(_0x570eec)return _0x3a3c94[_0x1b0b37('0x1e')](_0x5ddc34)['json'](_0x570eec);};}function respondWithFilteredResult(_0x40a945,_0x2ad2ec){return function(_0x2d05e2){const _0xab3335=a38_0x2a8d;if(_0x2d05e2){const _0x474b1f=_0x2d05e2[_0xab3335('0x2f')],_0x27ad92=_0x2ad2ec[_0xab3335('0xe')];let _0x57b7cf=_0x2ad2ec[_0xab3335('0xe')]+_0x2ad2ec[_0xab3335('0x16')],_0x54a716;return _0x57b7cf>=_0x474b1f?(_0x57b7cf=_0x474b1f,_0x54a716=0xc8):_0x54a716=0xce,_0x40a945['status'](_0x54a716),_0x40a945[_0xab3335('0x4')](_0xab3335('0xa'),_0x27ad92+'-'+_0x57b7cf+'/'+_0x474b1f)[_0xab3335('0x3')](_0x2d05e2);}return null;};}function saveUpdates(_0x7727c3){return function(_0x18cf90){const _0x442229=a38_0x2a8d;if(_0x18cf90)return _0x18cf90[_0x442229('0x2e')](_0x7727c3)[_0x442229('0x28')](function(_0x113dcd){return _0x113dcd;});return null;};}function removeEntity(_0x2ecc2e){return function(_0x7bd656){const _0x443021=a38_0x2a8d;if(_0x7bd656)return _0x7bd656['destroy']()[_0x443021('0x28')](function(){const _0x9aa821=_0x443021;_0x2ecc2e['status'](0xcc)[_0x9aa821('0x17')]();});};}function handleEntityNotFound(_0x2ba191){return function(_0x51db23){const _0x3c5727=a38_0x2a8d;return!_0x51db23&&_0x2ba191[_0x3c5727('0x2')](0x194),_0x51db23;};}function handleError(_0x5e7988,_0x2936e5){return _0x2936e5=_0x2936e5||0x1f4,function(_0x3b5528){const _0x5b4f1d=a38_0x2a8d;logger[_0x5b4f1d('0x25')](_0x3b5528[_0x5b4f1d('0x19')]),_0x3b5528[_0x5b4f1d('0x6')]&&delete _0x3b5528['name'],_0x5e7988['status'](_0x2936e5)[_0x5b4f1d('0x32')](_0x3b5528);};}exports['index']=function(_0x171ab9,_0x5ad4d2){const _0x12ea4f=_0x2f5074;let _0x5c24b5={};const _0x2d82c1={},_0x16f603={'count':0x0,'rows':[]},_0x258213=_[_0x12ea4f('0x2d')](db[_0x12ea4f('0x34')]['rawAttributes'],function(_0x303a49){const _0x44ebec=_0x12ea4f;return{'name':_0x303a49[_0x44ebec('0x1c')],'type':_0x303a49[_0x44ebec('0x12')][_0x44ebec('0x31')]};});_0x2d82c1[_0x12ea4f('0x13')]=_[_0x12ea4f('0x2d')](_0x258213,_0x12ea4f('0x6')),_0x2d82c1[_0x12ea4f('0x1a')]=_[_0x12ea4f('0xb')](_0x171ab9[_0x12ea4f('0x1a')]),_0x2d82c1['filters']=_[_0x12ea4f('0x18')](_0x2d82c1['model'],_0x2d82c1['query']),_0x5c24b5[_0x12ea4f('0x11')]=_[_0x12ea4f('0x18')](_0x2d82c1['model'],qs[_0x12ea4f('0x2b')](_0x171ab9[_0x12ea4f('0x1a')][_0x12ea4f('0x2b')])),_0x5c24b5[_0x12ea4f('0x11')]=_0x5c24b5[_0x12ea4f('0x11')][_0x12ea4f('0x38')]?_0x5c24b5[_0x12ea4f('0x11')]:_0x2d82c1[_0x12ea4f('0x13')];typeof _0x171ab9[_0x12ea4f('0x1a')][_0x12ea4f('0xf')]===_0x12ea4f('0x36')&&(_0x5c24b5[_0x12ea4f('0x16')]=qs[_0x12ea4f('0x16')](_0x171ab9[_0x12ea4f('0x1a')]['limit']),_0x5c24b5[_0x12ea4f('0xe')]=qs[_0x12ea4f('0xe')](_0x171ab9['query'][_0x12ea4f('0xe')]));_0x5c24b5[_0x12ea4f('0x33')]=qs[_0x12ea4f('0x2a')](_0x171ab9[_0x12ea4f('0x1a')]['sort']),_0x5c24b5['where']=qs['filters'](_[_0x12ea4f('0x15')](_0x171ab9[_0x12ea4f('0x1a')],_0x2d82c1[_0x12ea4f('0x1')]),_0x258213);_0x171ab9['query'][_0x12ea4f('0x22')]&&(_0x5c24b5[_0x12ea4f('0x3c')]=_[_0x12ea4f('0x1d')](_0x5c24b5[_0x12ea4f('0x3c')],{[Op['or']]:_['map'](_0x258213,function(_0x498c51){const _0x224aeb=_0x12ea4f;if(_0x498c51[_0x224aeb('0x12')]!==_0x224aeb('0x29')){const _0x112878={};return _0x112878[_0x498c51[_0x224aeb('0x6')]]={[Op[_0x224aeb('0x37')]]:'%'+_0x171ab9['query'][_0x224aeb('0x22')]+'%'},_0x112878;}})}));_0x5c24b5=_['merge']({},_0x5c24b5,_0x171ab9[_0x12ea4f('0x0')]);const _0x57b754={'where':_0x5c24b5[_0x12ea4f('0x3c')]};return db[_0x12ea4f('0x34')][_0x12ea4f('0x2f')](_0x57b754)[_0x12ea4f('0x28')](function(_0x43247e){const _0x36ea31=_0x12ea4f;return _0x16f603[_0x36ea31('0x2f')]=_0x43247e,_0x171ab9[_0x36ea31('0x1a')]['includeAll']&&(_0x5c24b5[_0x36ea31('0x7')]=[{'all':!![]}]),db[_0x36ea31('0x34')][_0x36ea31('0xd')](_0x5c24b5);})[_0x12ea4f('0x28')](function(_0x4da83d){const _0x287832=_0x12ea4f;return _0x16f603[_0x287832('0x1b')]=_0x4da83d,_0x16f603;})[_0x12ea4f('0x28')](respondWithFilteredResult(_0x5ad4d2,_0x5c24b5))['catch'](handleError(_0x5ad4d2,null));},exports[_0x2f5074('0x24')]=function(_0xde5cf2,_0x3f2432){const _0x1d1b91=_0x2f5074;let _0x4956c9={'raw':![],'where':{'id':_0xde5cf2[_0x1d1b91('0x21')]['id']}};const _0x3f4a71={};return _0x3f4a71[_0x1d1b91('0x13')]=_[_0x1d1b91('0xb')](db[_0x1d1b91('0x34')][_0x1d1b91('0x20')]),_0x3f4a71['query']=_['keys'](_0xde5cf2[_0x1d1b91('0x1a')]),_0x3f4a71[_0x1d1b91('0x1')]=_[_0x1d1b91('0x18')](_0x3f4a71[_0x1d1b91('0x13')],_0x3f4a71['query']),_0x4956c9[_0x1d1b91('0x11')]=_[_0x1d1b91('0x18')](_0x3f4a71[_0x1d1b91('0x13')],qs[_0x1d1b91('0x2b')](_0xde5cf2[_0x1d1b91('0x1a')][_0x1d1b91('0x2b')])),_0x4956c9[_0x1d1b91('0x11')]=_0x4956c9['attributes'][_0x1d1b91('0x38')]?_0x4956c9['attributes']:_0x3f4a71[_0x1d1b91('0x13')],_0xde5cf2['query']['includeAll']&&(_0x4956c9[_0x1d1b91('0x7')]=[{'all':!![]}]),_0x4956c9=_[_0x1d1b91('0x1d')]({},_0x4956c9,_0xde5cf2[_0x1d1b91('0x0')]),db['Automation'][_0x1d1b91('0x10')](_0x4956c9)['then'](handleEntityNotFound(_0x3f2432,null))['then'](respondWithResult(_0x3f2432,null))[_0x1d1b91('0x5')](handleError(_0x3f2432,null));},exports[_0x2f5074('0x9')]=function(_0x50b674,_0x5acd0a){const _0x29e568=_0x2f5074;return db[_0x29e568('0x34')][_0x29e568('0x9')](_0x50b674[_0x29e568('0x3a')],{})[_0x29e568('0x28')](respondWithResult(_0x5acd0a,0xc9))[_0x29e568('0x5')](handleError(_0x5acd0a,null));},exports[_0x2f5074('0x2e')]=function(_0x37c0d8,_0x4bf84b){const _0x4de70f=_0x2f5074;return _0x37c0d8[_0x4de70f('0x3a')]['id']&&delete _0x37c0d8['body']['id'],db['Automation'][_0x4de70f('0x10')]({'where':{'id':_0x37c0d8[_0x4de70f('0x21')]['id']}})[_0x4de70f('0x28')](handleEntityNotFound(_0x4bf84b,null))[_0x4de70f('0x28')](saveUpdates(_0x37c0d8[_0x4de70f('0x3a')],null))['then'](respondWithResult(_0x4bf84b,null))['catch'](handleError(_0x4bf84b,null));},exports[_0x2f5074('0x8')]=function(_0x2e94ab,_0x16fece){const _0x464e74=_0x2f5074;return db['Automation'][_0x464e74('0x10')]({'where':{'id':_0x2e94ab[_0x464e74('0x21')]['id']}})['then'](handleEntityNotFound(_0x16fece,null))['then'](removeEntity(_0x16fece,null))[_0x464e74('0x5')](handleError(_0x16fece,null));},exports['addConditions']=function(_0x34ba2d,_0xf7cdb0){const _0x5cd6c9=_0x2f5074;return db[_0x5cd6c9('0xc')][_0x5cd6c9('0x10')]({'where':{'id':_0x34ba2d[_0x5cd6c9('0x21')]['id']}})[_0x5cd6c9('0x28')](function(_0x49b5f9){const _0x100ecc=_0x5cd6c9;if(_0x49b5f9)return _0x49b5f9[_0x100ecc('0x2c')](_0x34ba2d['body'][_0x100ecc('0x27')],{'through':_[_0x100ecc('0x1f')](_0x34ba2d[_0x100ecc('0x3a')],[_0x100ecc('0x27'),'id'])});})['then'](respondWithResult(_0xf7cdb0,null))[_0x5cd6c9('0x5')](handleError(_0xf7cdb0,null));},exports['getConditions']=function(_0x53a2b6,_0x1c111f){const _0x577cc3=_0x2f5074;let _0x4354c1={};const _0x39dc7c={};let _0x11e95b,_0x520be0;return db[_0x577cc3('0x34')][_0x577cc3('0x10')]({'where':{'id':_0x53a2b6[_0x577cc3('0x21')]['id']}})[_0x577cc3('0x28')](handleEntityNotFound(_0x1c111f,null))['then'](function(_0x3888a1){const _0x3b758b=_0x577cc3;if(_0x3888a1)return _0x11e95b=_0x3888a1,_0x39dc7c[_0x3b758b('0x13')]=_[_0x3b758b('0xb')](db[_0x3b758b('0xc')]['rawAttributes']),_0x39dc7c[_0x3b758b('0x1a')]=_[_0x3b758b('0xb')](_0x53a2b6[_0x3b758b('0x1a')]),_0x39dc7c[_0x3b758b('0x1')]=_[_0x3b758b('0x18')](_0x39dc7c[_0x3b758b('0x13')],_0x39dc7c['query']),_0x4354c1['attributes']=_[_0x3b758b('0x18')](_0x39dc7c['model'],qs[_0x3b758b('0x2b')](_0x53a2b6['query'][_0x3b758b('0x2b')])),_0x4354c1[_0x3b758b('0x11')]=_0x4354c1[_0x3b758b('0x11')]['length']?_0x4354c1[_0x3b758b('0x11')]:_0x39dc7c[_0x3b758b('0x13')],_0x4354c1[_0x3b758b('0x33')]=qs[_0x3b758b('0x2a')](_0x53a2b6[_0x3b758b('0x1a')]['sort']),_0x4354c1[_0x3b758b('0x3c')]=qs[_0x3b758b('0x1')](_[_0x3b758b('0x15')](_0x53a2b6['query'],_0x39dc7c[_0x3b758b('0x1')])),_0x53a2b6['query'][_0x3b758b('0x22')]&&(_0x4354c1['where']=_[_0x3b758b('0x1d')](_0x4354c1[_0x3b758b('0x3c')],{[Op['or']]:_[_0x3b758b('0x2d')](_0x4354c1['attributes'],function(_0x5ac19f){const _0x13ebf1=_0x3b758b,_0x59c1e0={};return _0x59c1e0[_0x5ac19f]={[Op[_0x13ebf1('0x37')]]:'%'+_0x53a2b6[_0x13ebf1('0x1a')][_0x13ebf1('0x22')]+'%'},_0x59c1e0;})})),_0x4354c1=_[_0x3b758b('0x1d')]({},_0x4354c1,_0x53a2b6[_0x3b758b('0x0')]),_0x11e95b[_0x3b758b('0x23')](_0x4354c1);})[_0x577cc3('0x28')](function(_0x479e91){const _0x5bd6a9=_0x577cc3;if(_0x479e91)return _0x520be0=_0x479e91['length'],typeof _0x53a2b6[_0x5bd6a9('0x1a')]['nolimit']===_0x5bd6a9('0x36')&&(_0x4354c1[_0x5bd6a9('0x16')]=qs[_0x5bd6a9('0x16')](_0x53a2b6['query']['limit']),_0x4354c1[_0x5bd6a9('0xe')]=qs[_0x5bd6a9('0xe')](_0x53a2b6[_0x5bd6a9('0x1a')]['offset'])),_0x11e95b[_0x5bd6a9('0x23')](_0x4354c1);})[_0x577cc3('0x28')](function(_0x41ef3c){if(_0x41ef3c)return _0x41ef3c?{'count':_0x520be0,'rows':_0x41ef3c}:null;})[_0x577cc3('0x28')](respondWithResult(_0x1c111f,null))['catch'](handleError(_0x1c111f,null));},exports[_0x2f5074('0x35')]=function(_0xe368a1,_0x1343cf){const _0x5c8908=_0x2f5074;return db[_0x5c8908('0x26')][_0x5c8908('0x10')]({'where':{'id':_0xe368a1[_0x5c8908('0x21')]['id']}})['then'](function(_0x2441ca){const _0x5101bd=_0x5c8908;if(_0x2441ca)return _0x2441ca[_0x5101bd('0x35')](_0xe368a1[_0x5101bd('0x3a')]['ids'],{'through':_[_0x5101bd('0x1f')](_0xe368a1[_0x5101bd('0x3a')],[_0x5101bd('0x27'),'id'])});})[_0x5c8908('0x28')](respondWithResult(_0x1343cf,null))[_0x5c8908('0x5')](handleError(_0x1343cf,null));},exports[_0x2f5074('0x39')]=function(_0xe6fde3,_0x52a306){const _0x463143=_0x2f5074;let _0x4ccd30={};const _0x4a7612={};let _0x211c83,_0x2adbcd;return db[_0x463143('0x34')][_0x463143('0x10')]({'where':{'id':_0xe6fde3[_0x463143('0x21')]['id']}})[_0x463143('0x28')](handleEntityNotFound(_0x52a306,null))[_0x463143('0x28')](function(_0x43a5b3){const _0x159155=_0x463143;if(_0x43a5b3)return _0x211c83=_0x43a5b3,_0x4a7612[_0x159155('0x13')]=_[_0x159155('0xb')](db[_0x159155('0x26')][_0x159155('0x20')]),_0x4a7612[_0x159155('0x1a')]=_[_0x159155('0xb')](_0xe6fde3[_0x159155('0x1a')]),_0x4a7612['filters']=_[_0x159155('0x18')](_0x4a7612[_0x159155('0x13')],_0x4a7612['query']),_0x4ccd30[_0x159155('0x11')]=_[_0x159155('0x18')](_0x4a7612[_0x159155('0x13')],qs[_0x159155('0x2b')](_0xe6fde3['query'][_0x159155('0x2b')])),_0x4ccd30[_0x159155('0x11')]=_0x4ccd30[_0x159155('0x11')]['length']?_0x4ccd30[_0x159155('0x11')]:_0x4a7612['model'],_0x4ccd30[_0x159155('0x33')]=qs[_0x159155('0x2a')](_0xe6fde3['query']['sort']),_0x4ccd30[_0x159155('0x3c')]=qs['filters'](_[_0x159155('0x15')](_0xe6fde3[_0x159155('0x1a')],_0x4a7612[_0x159155('0x1')])),_0xe6fde3['query'][_0x159155('0x22')]&&(_0x4ccd30[_0x159155('0x3c')]=_['merge'](_0x4ccd30['where'],{[Op['or']]:_[_0x159155('0x2d')](_0x4ccd30[_0x159155('0x11')],function(_0x2f9ff2){const _0x33baad=_0x159155,_0x4ec707={};return _0x4ec707[_0x2f9ff2]={[Op['like']]:'%'+_0xe6fde3[_0x33baad('0x1a')][_0x33baad('0x22')]+'%'},_0x4ec707;})})),_0x4ccd30=_[_0x159155('0x1d')]({},_0x4ccd30,_0xe6fde3[_0x159155('0x0')]),_0x211c83[_0x159155('0x39')](_0x4ccd30);})[_0x463143('0x28')](function(_0x446c32){const _0x3035b9=_0x463143;if(_0x446c32)return _0x2adbcd=_0x446c32[_0x3035b9('0x38')],typeof _0xe6fde3[_0x3035b9('0x1a')][_0x3035b9('0xf')]==='undefined'&&(_0x4ccd30[_0x3035b9('0x16')]=qs['limit'](_0xe6fde3[_0x3035b9('0x1a')][_0x3035b9('0x16')]),_0x4ccd30[_0x3035b9('0xe')]=qs[_0x3035b9('0xe')](_0xe6fde3[_0x3035b9('0x1a')][_0x3035b9('0xe')])),_0x211c83[_0x3035b9('0x39')](_0x4ccd30);})['then'](function(_0x5621e1){if(_0x5621e1)return _0x5621e1?{'count':_0x2adbcd,'rows':_0x5621e1}:null;})[_0x463143('0x28')](respondWithResult(_0x52a306,null))[_0x463143('0x5')](handleError(_0x52a306,null));}; \ No newline at end of file +const a38_0x2420=['end','like','Automation','include','name','update','addConditions','send','sendStatus','undefined','VIRTUAL','model','map','omit','pick','getActions','findAll','stack','intersection','addActions','index','nolimit','where','attributes','fieldName','filters','error','../../components/parsers/qs','show','Condition','length','count','findOne','lodash','status','create','Content-Range','sort','getConditions','set','body','merge','keys','json','api','key','catch','offset','destroy','rows','type','query','then','filter','Action','../../mysqldb','limit','../../config/logger','options','fields','ids','rawAttributes','order','includeAll','params'];(function(_0x3d2276,_0x2420eb){const _0x1b2e01=function(_0x489c87){while(--_0x489c87){_0x3d2276['push'](_0x3d2276['shift']());}};_0x1b2e01(++_0x2420eb);}(a38_0x2420,0x132));const a38_0x1b2e=function(_0x3d2276,_0x2420eb){_0x3d2276=_0x3d2276-0x0;let _0x1b2e01=a38_0x2420[_0x3d2276];return _0x1b2e01;};const _0x5095cb=a38_0x1b2e;'use strict';const _=require(_0x5095cb('0x34')),qs=require(_0x5095cb('0x2e')),logger=require(_0x5095cb('0xb'))(_0x5095cb('0x3f')),db=require(_0x5095cb('0x9'))['db'],{Op}=require('sequelize');function respondWithResult(_0x489c87,_0x589c93){return _0x589c93=_0x589c93||0xc8,function(_0x1aa88e){const _0xc9df0b=a38_0x1b2e;if(_0x1aa88e)return _0x489c87['status'](_0x589c93)[_0xc9df0b('0x3e')](_0x1aa88e);};}function respondWithFilteredResult(_0x3912ff,_0x46b52d){return function(_0x3518df){const _0x301ab0=a38_0x1b2e;if(_0x3518df){const _0x4fb58b=_0x3518df[_0x301ab0('0x32')],_0x4181c0=_0x46b52d[_0x301ab0('0x1')];let _0x40edf6=_0x46b52d['offset']+_0x46b52d[_0x301ab0('0xa')],_0x4718f2;return _0x40edf6>=_0x4fb58b?(_0x40edf6=_0x4fb58b,_0x4718f2=0xc8):_0x4718f2=0xce,_0x3912ff['status'](_0x4718f2),_0x3912ff[_0x301ab0('0x3a')](_0x301ab0('0x37'),_0x4181c0+'-'+_0x40edf6+'/'+_0x4fb58b)['json'](_0x3518df);}return null;};}function saveUpdates(_0x3b5a14){return function(_0x33d8f0){const _0x5f42a1=a38_0x1b2e;if(_0x33d8f0)return _0x33d8f0[_0x5f42a1('0x18')](_0x3b5a14)['then'](function(_0x1430c4){return _0x1430c4;});return null;};}function removeEntity(_0x43ab83){return function(_0x17bff6){const _0xb973cd=a38_0x1b2e;if(_0x17bff6)return _0x17bff6[_0xb973cd('0x2')]()[_0xb973cd('0x6')](function(){const _0x1a4630=_0xb973cd;_0x43ab83['status'](0xcc)[_0x1a4630('0x13')]();});};}function handleEntityNotFound(_0x593621){return function(_0x2c0e17){const _0x58445=a38_0x1b2e;return!_0x2c0e17&&_0x593621[_0x58445('0x1b')](0x194),_0x2c0e17;};}function handleError(_0x51ed5e,_0x137a50){return _0x137a50=_0x137a50||0x1f4,function(_0x554137){const _0x23b618=a38_0x1b2e;logger[_0x23b618('0x2d')](_0x554137[_0x23b618('0x24')]),_0x554137['name']&&delete _0x554137[_0x23b618('0x17')],_0x51ed5e[_0x23b618('0x35')](_0x137a50)[_0x23b618('0x1a')](_0x554137);};}exports[_0x5095cb('0x27')]=function(_0x1a23c8,_0x478e95){const _0x410c49=_0x5095cb;let _0xba57b9={};const _0x88e3ee={},_0x18e5b7={'count':0x0,'rows':[]},_0x353039=_[_0x410c49('0x1f')](db[_0x410c49('0x15')][_0x410c49('0xf')],function(_0x120deb){const _0x1bcb01=_0x410c49;return{'name':_0x120deb[_0x1bcb01('0x2b')],'type':_0x120deb[_0x1bcb01('0x4')][_0x1bcb01('0x40')]};});_0x88e3ee[_0x410c49('0x1e')]=_[_0x410c49('0x1f')](_0x353039,_0x410c49('0x17')),_0x88e3ee['query']=_[_0x410c49('0x3d')](_0x1a23c8[_0x410c49('0x5')]),_0x88e3ee[_0x410c49('0x2c')]=_[_0x410c49('0x25')](_0x88e3ee[_0x410c49('0x1e')],_0x88e3ee[_0x410c49('0x5')]),_0xba57b9['attributes']=_[_0x410c49('0x25')](_0x88e3ee[_0x410c49('0x1e')],qs[_0x410c49('0xd')](_0x1a23c8[_0x410c49('0x5')][_0x410c49('0xd')])),_0xba57b9[_0x410c49('0x2a')]=_0xba57b9[_0x410c49('0x2a')][_0x410c49('0x31')]?_0xba57b9[_0x410c49('0x2a')]:_0x88e3ee[_0x410c49('0x1e')];typeof _0x1a23c8['query'][_0x410c49('0x28')]===_0x410c49('0x1c')&&(_0xba57b9['limit']=qs[_0x410c49('0xa')](_0x1a23c8['query'][_0x410c49('0xa')]),_0xba57b9[_0x410c49('0x1')]=qs['offset'](_0x1a23c8[_0x410c49('0x5')][_0x410c49('0x1')]));_0xba57b9[_0x410c49('0x10')]=qs[_0x410c49('0x38')](_0x1a23c8[_0x410c49('0x5')][_0x410c49('0x38')]),_0xba57b9['where']=qs[_0x410c49('0x2c')](_[_0x410c49('0x21')](_0x1a23c8[_0x410c49('0x5')],_0x88e3ee[_0x410c49('0x2c')]),_0x353039);_0x1a23c8[_0x410c49('0x5')]['filter']&&(_0xba57b9[_0x410c49('0x29')]=_[_0x410c49('0x3c')](_0xba57b9[_0x410c49('0x29')],{[Op['or']]:_[_0x410c49('0x1f')](_0x353039,function(_0x81713b){const _0x2fab3a=_0x410c49;if(_0x81713b[_0x2fab3a('0x4')]!==_0x2fab3a('0x1d')){const _0x48d556={};return _0x48d556[_0x81713b[_0x2fab3a('0x17')]]={[Op[_0x2fab3a('0x14')]]:'%'+_0x1a23c8[_0x2fab3a('0x5')][_0x2fab3a('0x7')]+'%'},_0x48d556;}})}));_0xba57b9=_[_0x410c49('0x3c')]({},_0xba57b9,_0x1a23c8[_0x410c49('0xc')]);const _0x25d8e3={'where':_0xba57b9['where']};return db['Automation']['count'](_0x25d8e3)[_0x410c49('0x6')](function(_0x5d24f3){const _0x3f1ad1=_0x410c49;return _0x18e5b7['count']=_0x5d24f3,_0x1a23c8[_0x3f1ad1('0x5')][_0x3f1ad1('0x11')]&&(_0xba57b9[_0x3f1ad1('0x16')]=[{'all':!![]}]),db[_0x3f1ad1('0x15')][_0x3f1ad1('0x23')](_0xba57b9);})[_0x410c49('0x6')](function(_0x2880bb){const _0x19692d=_0x410c49;return _0x18e5b7[_0x19692d('0x3')]=_0x2880bb,_0x18e5b7;})['then'](respondWithFilteredResult(_0x478e95,_0xba57b9))[_0x410c49('0x0')](handleError(_0x478e95,null));},exports[_0x5095cb('0x2f')]=function(_0x375b05,_0x35f329){const _0x48d14c=_0x5095cb;let _0x3a5b0b={'raw':![],'where':{'id':_0x375b05['params']['id']}};const _0x3ae539={};return _0x3ae539['model']=_['keys'](db[_0x48d14c('0x15')][_0x48d14c('0xf')]),_0x3ae539['query']=_[_0x48d14c('0x3d')](_0x375b05[_0x48d14c('0x5')]),_0x3ae539['filters']=_[_0x48d14c('0x25')](_0x3ae539[_0x48d14c('0x1e')],_0x3ae539[_0x48d14c('0x5')]),_0x3a5b0b[_0x48d14c('0x2a')]=_['intersection'](_0x3ae539[_0x48d14c('0x1e')],qs['fields'](_0x375b05[_0x48d14c('0x5')][_0x48d14c('0xd')])),_0x3a5b0b['attributes']=_0x3a5b0b['attributes'][_0x48d14c('0x31')]?_0x3a5b0b[_0x48d14c('0x2a')]:_0x3ae539[_0x48d14c('0x1e')],_0x375b05[_0x48d14c('0x5')][_0x48d14c('0x11')]&&(_0x3a5b0b[_0x48d14c('0x16')]=[{'all':!![]}]),_0x3a5b0b=_['merge']({},_0x3a5b0b,_0x375b05[_0x48d14c('0xc')]),db[_0x48d14c('0x15')][_0x48d14c('0x33')](_0x3a5b0b)[_0x48d14c('0x6')](handleEntityNotFound(_0x35f329,null))['then'](respondWithResult(_0x35f329,null))[_0x48d14c('0x0')](handleError(_0x35f329,null));},exports[_0x5095cb('0x36')]=function(_0x37c025,_0x4a5ef9){const _0x197ad6=_0x5095cb;return db['Automation'][_0x197ad6('0x36')](_0x37c025[_0x197ad6('0x3b')],{})[_0x197ad6('0x6')](respondWithResult(_0x4a5ef9,0xc9))[_0x197ad6('0x0')](handleError(_0x4a5ef9,null));},exports['update']=function(_0x2f222c,_0x443003){const _0x12480e=_0x5095cb;return _0x2f222c[_0x12480e('0x3b')]['id']&&delete _0x2f222c['body']['id'],db[_0x12480e('0x15')][_0x12480e('0x33')]({'where':{'id':_0x2f222c[_0x12480e('0x12')]['id']}})['then'](handleEntityNotFound(_0x443003,null))[_0x12480e('0x6')](saveUpdates(_0x2f222c[_0x12480e('0x3b')],null))[_0x12480e('0x6')](respondWithResult(_0x443003,null))[_0x12480e('0x0')](handleError(_0x443003,null));},exports[_0x5095cb('0x2')]=function(_0x1e71bc,_0x24ac8b){const _0x5927c3=_0x5095cb;return db[_0x5927c3('0x15')][_0x5927c3('0x33')]({'where':{'id':_0x1e71bc['params']['id']}})[_0x5927c3('0x6')](handleEntityNotFound(_0x24ac8b,null))[_0x5927c3('0x6')](removeEntity(_0x24ac8b,null))[_0x5927c3('0x0')](handleError(_0x24ac8b,null));},exports[_0x5095cb('0x19')]=function(_0x28f6c5,_0xa21c16){const _0x481a19=_0x5095cb;return db['Condition'][_0x481a19('0x33')]({'where':{'id':_0x28f6c5[_0x481a19('0x12')]['id']}})[_0x481a19('0x6')](function(_0x4e121f){const _0x4fc2a8=_0x481a19;if(_0x4e121f)return _0x4e121f['addConditions'](_0x28f6c5[_0x4fc2a8('0x3b')]['ids'],{'through':_[_0x4fc2a8('0x20')](_0x28f6c5[_0x4fc2a8('0x3b')],[_0x4fc2a8('0xe'),'id'])});})['then'](respondWithResult(_0xa21c16,null))[_0x481a19('0x0')](handleError(_0xa21c16,null));},exports[_0x5095cb('0x39')]=function(_0x4abb03,_0x43cb71){const _0x5f3365=_0x5095cb;let _0x3cf22d={};const _0x5506db={};let _0x42ac77,_0x528954;return db[_0x5f3365('0x15')][_0x5f3365('0x33')]({'where':{'id':_0x4abb03[_0x5f3365('0x12')]['id']}})[_0x5f3365('0x6')](handleEntityNotFound(_0x43cb71,null))[_0x5f3365('0x6')](function(_0x3bca13){const _0x46735f=_0x5f3365;if(_0x3bca13)return _0x42ac77=_0x3bca13,_0x5506db[_0x46735f('0x1e')]=_['keys'](db[_0x46735f('0x30')]['rawAttributes']),_0x5506db['query']=_[_0x46735f('0x3d')](_0x4abb03['query']),_0x5506db['filters']=_[_0x46735f('0x25')](_0x5506db['model'],_0x5506db['query']),_0x3cf22d['attributes']=_[_0x46735f('0x25')](_0x5506db[_0x46735f('0x1e')],qs['fields'](_0x4abb03['query']['fields'])),_0x3cf22d[_0x46735f('0x2a')]=_0x3cf22d[_0x46735f('0x2a')][_0x46735f('0x31')]?_0x3cf22d[_0x46735f('0x2a')]:_0x5506db[_0x46735f('0x1e')],_0x3cf22d[_0x46735f('0x10')]=qs[_0x46735f('0x38')](_0x4abb03[_0x46735f('0x5')][_0x46735f('0x38')]),_0x3cf22d[_0x46735f('0x29')]=qs[_0x46735f('0x2c')](_['pick'](_0x4abb03[_0x46735f('0x5')],_0x5506db[_0x46735f('0x2c')])),_0x4abb03[_0x46735f('0x5')][_0x46735f('0x7')]&&(_0x3cf22d[_0x46735f('0x29')]=_[_0x46735f('0x3c')](_0x3cf22d['where'],{[Op['or']]:_[_0x46735f('0x1f')](_0x3cf22d[_0x46735f('0x2a')],function(_0x18a352){const _0x2c72b6=_0x46735f,_0x4eb148={};return _0x4eb148[_0x18a352]={[Op[_0x2c72b6('0x14')]]:'%'+_0x4abb03[_0x2c72b6('0x5')][_0x2c72b6('0x7')]+'%'},_0x4eb148;})})),_0x3cf22d=_[_0x46735f('0x3c')]({},_0x3cf22d,_0x4abb03['options']),_0x42ac77[_0x46735f('0x39')](_0x3cf22d);})[_0x5f3365('0x6')](function(_0x473448){const _0x4bab58=_0x5f3365;if(_0x473448)return _0x528954=_0x473448[_0x4bab58('0x31')],typeof _0x4abb03['query']['nolimit']===_0x4bab58('0x1c')&&(_0x3cf22d[_0x4bab58('0xa')]=qs['limit'](_0x4abb03['query']['limit']),_0x3cf22d['offset']=qs[_0x4bab58('0x1')](_0x4abb03[_0x4bab58('0x5')][_0x4bab58('0x1')])),_0x42ac77[_0x4bab58('0x39')](_0x3cf22d);})[_0x5f3365('0x6')](function(_0x453ae1){if(_0x453ae1)return _0x453ae1?{'count':_0x528954,'rows':_0x453ae1}:null;})[_0x5f3365('0x6')](respondWithResult(_0x43cb71,null))[_0x5f3365('0x0')](handleError(_0x43cb71,null));},exports[_0x5095cb('0x26')]=function(_0x259578,_0x5e7e1b){const _0x1aaa80=_0x5095cb;return db['Action'][_0x1aaa80('0x33')]({'where':{'id':_0x259578[_0x1aaa80('0x12')]['id']}})[_0x1aaa80('0x6')](function(_0x23821b){const _0x372451=_0x1aaa80;if(_0x23821b)return _0x23821b[_0x372451('0x26')](_0x259578[_0x372451('0x3b')]['ids'],{'through':_[_0x372451('0x20')](_0x259578[_0x372451('0x3b')],[_0x372451('0xe'),'id'])});})[_0x1aaa80('0x6')](respondWithResult(_0x5e7e1b,null))[_0x1aaa80('0x0')](handleError(_0x5e7e1b,null));},exports['getActions']=function(_0x42cc6b,_0x1ea5d7){const _0x4183a1=_0x5095cb;let _0x788152={};const _0xfd6c1c={};let _0x2d7492,_0x49c624;return db['Automation'][_0x4183a1('0x33')]({'where':{'id':_0x42cc6b['params']['id']}})[_0x4183a1('0x6')](handleEntityNotFound(_0x1ea5d7,null))['then'](function(_0x3cade3){const _0x27c4dc=_0x4183a1;if(_0x3cade3)return _0x2d7492=_0x3cade3,_0xfd6c1c['model']=_[_0x27c4dc('0x3d')](db[_0x27c4dc('0x8')]['rawAttributes']),_0xfd6c1c[_0x27c4dc('0x5')]=_[_0x27c4dc('0x3d')](_0x42cc6b['query']),_0xfd6c1c[_0x27c4dc('0x2c')]=_[_0x27c4dc('0x25')](_0xfd6c1c[_0x27c4dc('0x1e')],_0xfd6c1c[_0x27c4dc('0x5')]),_0x788152[_0x27c4dc('0x2a')]=_[_0x27c4dc('0x25')](_0xfd6c1c['model'],qs[_0x27c4dc('0xd')](_0x42cc6b['query']['fields'])),_0x788152['attributes']=_0x788152[_0x27c4dc('0x2a')]['length']?_0x788152['attributes']:_0xfd6c1c[_0x27c4dc('0x1e')],_0x788152[_0x27c4dc('0x10')]=qs[_0x27c4dc('0x38')](_0x42cc6b[_0x27c4dc('0x5')][_0x27c4dc('0x38')]),_0x788152[_0x27c4dc('0x29')]=qs['filters'](_[_0x27c4dc('0x21')](_0x42cc6b[_0x27c4dc('0x5')],_0xfd6c1c[_0x27c4dc('0x2c')])),_0x42cc6b[_0x27c4dc('0x5')][_0x27c4dc('0x7')]&&(_0x788152['where']=_[_0x27c4dc('0x3c')](_0x788152[_0x27c4dc('0x29')],{[Op['or']]:_[_0x27c4dc('0x1f')](_0x788152[_0x27c4dc('0x2a')],function(_0x52abcf){const _0x49665d=_0x27c4dc,_0x2f6e6b={};return _0x2f6e6b[_0x52abcf]={[Op[_0x49665d('0x14')]]:'%'+_0x42cc6b[_0x49665d('0x5')]['filter']+'%'},_0x2f6e6b;})})),_0x788152=_[_0x27c4dc('0x3c')]({},_0x788152,_0x42cc6b[_0x27c4dc('0xc')]),_0x2d7492[_0x27c4dc('0x22')](_0x788152);})[_0x4183a1('0x6')](function(_0x440153){const _0x58bd28=_0x4183a1;if(_0x440153)return _0x49c624=_0x440153[_0x58bd28('0x31')],typeof _0x42cc6b['query']['nolimit']===_0x58bd28('0x1c')&&(_0x788152[_0x58bd28('0xa')]=qs[_0x58bd28('0xa')](_0x42cc6b[_0x58bd28('0x5')][_0x58bd28('0xa')]),_0x788152[_0x58bd28('0x1')]=qs[_0x58bd28('0x1')](_0x42cc6b[_0x58bd28('0x5')][_0x58bd28('0x1')])),_0x2d7492[_0x58bd28('0x22')](_0x788152);})['then'](function(_0x5d89a4){if(_0x5d89a4)return _0x5d89a4?{'count':_0x49c624,'rows':_0x5d89a4}:null;})['then'](respondWithResult(_0x1ea5d7,null))[_0x4183a1('0x0')](handleError(_0x1ea5d7,null));}; \ No newline at end of file diff --git a/server/api/automation/automation.model.js b/server/api/automation/automation.model.js index dda7674..58e6d6f 100644 --- a/server/api/automation/automation.model.js +++ b/server/api/automation/automation.model.js @@ -1 +1 @@ -const a39_0x2364=['./automation.attributes','define','exports','Automation'];(function(_0x4535d9,_0x236424){const _0x427a3c=function(_0x290b6b){while(--_0x290b6b){_0x4535d9['push'](_0x4535d9['shift']());}};_0x427a3c(++_0x236424);}(a39_0x2364,0xfd));const a39_0x427a=function(_0x4535d9,_0x236424){_0x4535d9=_0x4535d9-0x0;let _0x427a3c=a39_0x2364[_0x4535d9];return _0x427a3c;};const _0x2b5de9=a39_0x427a;'use strict';const attributes=require(_0x2b5de9('0x3'));module[_0x2b5de9('0x1')]=function(_0x290b6b){const _0x2d22ca=_0x2b5de9,_0x5576a5=_0x290b6b[_0x2d22ca('0x0')](_0x2d22ca('0x2'),attributes,{'tableName':'tools_automations','paranoid':![],'indexes':[],'timestamps':!![]});return _0x5576a5;}; \ No newline at end of file +const a39_0x1713=['tools_automations','define','exports'];(function(_0xc1fa30,_0x17132a){const _0x42bb49=function(_0x1de003){while(--_0x1de003){_0xc1fa30['push'](_0xc1fa30['shift']());}};_0x42bb49(++_0x17132a);}(a39_0x1713,0x1c0));const a39_0x42bb=function(_0xc1fa30,_0x17132a){_0xc1fa30=_0xc1fa30-0x0;let _0x42bb49=a39_0x1713[_0xc1fa30];return _0x42bb49;};const _0x5ba627=a39_0x42bb;'use strict';const attributes=require('./automation.attributes');module[_0x5ba627('0x1')]=function(_0x1de003){const _0xadc85b=_0x5ba627,_0x483188=_0x1de003[_0xadc85b('0x0')]('Automation',attributes,{'tableName':_0xadc85b('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x483188;}; \ No newline at end of file diff --git a/server/api/automation/index.js b/server/api/automation/index.js index ab3a11a..17a7abd 100644 --- a/server/api/automation/index.js +++ b/server/api/automation/index.js @@ -1 +1 @@ -const a40_0x4f6d=['/:id','create','put','/:id/actions','./automation.controller','express','exports','get','addConditions','destroy','update','Router','/:id/conditions','delete','addActions','isAuthenticated','index','post','getConditions'];(function(_0x559943,_0x4f6dc9){const _0xd8114d=function(_0x2e5c5d){while(--_0x2e5c5d){_0x559943['push'](_0x559943['shift']());}};_0xd8114d(++_0x4f6dc9);}(a40_0x4f6d,0x177));const a40_0xd811=function(_0x559943,_0x4f6dc9){_0x559943=_0x559943-0x0;let _0xd8114d=a40_0x4f6d[_0x559943];return _0xd8114d;};const _0x153e60=a40_0xd811;'use strict';const express=require(_0x153e60('0xa')),router=express[_0x153e60('0x10')](),auth=require('../../components/auth/service'),controller=require(_0x153e60('0x9'));router['get']('/',auth['isAuthenticated'](),controller[_0x153e60('0x2')]),router[_0x153e60('0xc')](_0x153e60('0x5'),auth[_0x153e60('0x1')](),controller['show']),router[_0x153e60('0xc')]('/:id/conditions',auth['isAuthenticated'](),controller[_0x153e60('0x4')]),router[_0x153e60('0xc')]('/:id/actions',auth[_0x153e60('0x1')](),controller['getActions']),router['post']('/',auth[_0x153e60('0x1')](),controller[_0x153e60('0x6')]),router[_0x153e60('0x3')](_0x153e60('0x11'),auth[_0x153e60('0x1')](),controller[_0x153e60('0xd')]),router[_0x153e60('0x3')](_0x153e60('0x8'),auth[_0x153e60('0x1')](),controller[_0x153e60('0x0')]),router[_0x153e60('0x7')](_0x153e60('0x5'),auth[_0x153e60('0x1')](),controller[_0x153e60('0xf')]),router[_0x153e60('0x12')]('/:id',auth[_0x153e60('0x1')](),controller[_0x153e60('0xe')]),module[_0x153e60('0xb')]=router; \ No newline at end of file +const a40_0x48f6=['isAuthenticated','/:id/actions','getConditions','/:id/conditions','get','/:id','../../components/auth/service','show','index','update','delete','getActions','put','post','express','destroy','addConditions','exports','create'];(function(_0x572ad1,_0x48f626){const _0x44c18f=function(_0x3ead31){while(--_0x3ead31){_0x572ad1['push'](_0x572ad1['shift']());}};_0x44c18f(++_0x48f626);}(a40_0x48f6,0x18d));const a40_0x44c1=function(_0x572ad1,_0x48f626){_0x572ad1=_0x572ad1-0x0;let _0x44c18f=a40_0x48f6[_0x572ad1];return _0x44c18f;};const _0x9bd76d=a40_0x44c1;'use strict';const express=require(_0x9bd76d('0x10')),router=express['Router'](),auth=require(_0x9bd76d('0x8')),controller=require('./automation.controller');router['get']('/',auth[_0x9bd76d('0x2')](),controller[_0x9bd76d('0xa')]),router['get'](_0x9bd76d('0x7'),auth[_0x9bd76d('0x2')](),controller[_0x9bd76d('0x9')]),router[_0x9bd76d('0x6')](_0x9bd76d('0x5'),auth['isAuthenticated'](),controller[_0x9bd76d('0x4')]),router[_0x9bd76d('0x6')](_0x9bd76d('0x3'),auth[_0x9bd76d('0x2')](),controller[_0x9bd76d('0xd')]),router[_0x9bd76d('0xf')]('/',auth[_0x9bd76d('0x2')](),controller[_0x9bd76d('0x1')]),router[_0x9bd76d('0xf')](_0x9bd76d('0x5'),auth[_0x9bd76d('0x2')](),controller[_0x9bd76d('0x12')]),router['post'](_0x9bd76d('0x3'),auth['isAuthenticated'](),controller['addActions']),router[_0x9bd76d('0xe')](_0x9bd76d('0x7'),auth[_0x9bd76d('0x2')](),controller[_0x9bd76d('0xb')]),router[_0x9bd76d('0xc')](_0x9bd76d('0x7'),auth[_0x9bd76d('0x2')](),controller[_0x9bd76d('0x11')]),module[_0x9bd76d('0x0')]=router; \ No newline at end of file diff --git a/server/api/campaign/campaign.attributes.js b/server/api/campaign/campaign.attributes.js index fe0ca7c..b8c5647 100644 --- a/server/api/campaign/campaign.attributes.js +++ b/server/api/campaign/campaign.attributes.js @@ -1 +1 @@ -const a41_0x594a=['never','UNSIGNED','Machine\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','Originate\x20Timeout\x20Seconds\x20(min:1,\x20max:999)','name','AgentReject\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','NoAnswer\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','STRING','#AMD\x20Greeting','#NoSuchNumber\x20Retry\x20(min:1,\x20max:999)','Abandoned\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','Active/Disactive\x20AMD','#AMD\x20Min\x20Word\x20Length','ENUM','Busy\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','onlyIfOpen','Random\x20Last\x20Digit\x20(min:1,\x20max:15)','#Drop\x20Retry\x20(min:1,\x20max:999)','INTEGER','ivr','#NoAnswer\x20Retry\x20(min:1,\x20max:999)','DESC','Active/Disactive\x20Campaign','#Global\x20Max\x20Retry\x20(min:1,\x20max:999)','#Machine\x20Retry\x20(min:1,\x20max:999)','BOOLEAN','Cut\x20Digit\x20(min:1,\x20max:15)','#AMD\x20Maximum\x20Number\x20Of\x20Words','exports','#AMD\x20Silence\x20Threshold\x20(min:0,\x20max:32767)','#AgentReject\x20Retry\x20(min:1,\x20max:999)','Drop\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','#Congestion\x20Retry\x20(min:1,\x20max:999)','07:00-22:00,*,*,*','Congestion\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','#AMD\x20Maximum\x20Word\x20Length'];(function(_0x297d4d,_0x594a6d){const _0x1ebfb9=function(_0x49bb49){while(--_0x49bb49){_0x297d4d['push'](_0x297d4d['shift']());}};_0x1ebfb9(++_0x594a6d);}(a41_0x594a,0x19c));const a41_0x1ebf=function(_0x297d4d,_0x594a6d){_0x297d4d=_0x297d4d-0x0;let _0x1ebfb9=a41_0x594a[_0x297d4d];return _0x1ebfb9;};const _0x52b5a0=a41_0x1ebf;'use strict';const Sequelize=require('sequelize');module[_0x52b5a0('0xc')]={'name':{'type':Sequelize[_0x52b5a0('0x1b')],'unique':_0x52b5a0('0x18'),'allowNull':![],'validate':{'is':/[A-Za-z0-9._\\+*!-]+/,'notEmpty':!![]}},'type':{'type':Sequelize[_0x52b5a0('0x21')]('ivr'),'allowNull':![],'defaultValue':_0x52b5a0('0x3')},'description':{'type':Sequelize[_0x52b5a0('0x1b')]},'active':{'type':Sequelize[_0x52b5a0('0x9')],'defaultValue':0x0,'comment':_0x52b5a0('0x6')},'limitCalls':{'type':Sequelize[_0x52b5a0('0x2')](0x4)['UNSIGNED'],'defaultValue':0x1e,'validate':{'min':0x1,'max':0xc8},'comment':'Max\x20200\x20calls.'},'dialOriginateCallerIdName':{'type':Sequelize[_0x52b5a0('0x1b')]},'dialOriginateCallerIdNumber':{'type':Sequelize['STRING']},'dialOriginateTimeout':{'type':Sequelize[_0x52b5a0('0x2')](0x3)['UNSIGNED'],'defaultValue':0x1e,'validate':{'min':0x1,'max':0x3e7},'comment':_0x52b5a0('0x17')},'dialCongestionMaxRetry':{'type':Sequelize[_0x52b5a0('0x2')](0x3)[_0x52b5a0('0x15')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x52b5a0('0x10')},'dialCongestionRetryFrequency':{'type':Sequelize[_0x52b5a0('0x2')](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x52b5a0('0x12')},'dialBusyMaxRetry':{'type':Sequelize['INTEGER'](0x3)[_0x52b5a0('0x15')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':'#Busy\x20Retry\x20(min:1,\x20max:999)'},'dialBusyRetryFrequency':{'type':Sequelize[_0x52b5a0('0x2')](0x5)[_0x52b5a0('0x15')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x52b5a0('0x22')},'dialNoAnswerMaxRetry':{'type':Sequelize[_0x52b5a0('0x2')](0x3)[_0x52b5a0('0x15')],'defaultValue':0x3,'comment':_0x52b5a0('0x4')},'dialNoAnswerRetryFrequency':{'type':Sequelize[_0x52b5a0('0x2')](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x52b5a0('0x1a')},'dialGlobalMaxRetry':{'type':Sequelize['INTEGER'](0x3)[_0x52b5a0('0x15')],'validate':{'min':0x1,'max':0x3e7},'defaultValue':0x4,'comment':_0x52b5a0('0x7')},'dialTimezone':{'type':Sequelize[_0x52b5a0('0x1b')],'defaultValue':null},'dialGlobalInterval':{'type':Sequelize[_0x52b5a0('0x1b')],'defaultValue':_0x52b5a0('0x11')},'dialCheckDuplicateType':{'type':Sequelize['ENUM']('always',_0x52b5a0('0x14'),_0x52b5a0('0x23')),'defaultValue':'always'},'dialAMDActive':{'type':Sequelize['BOOLEAN'],'defaultValue':0x0,'comment':_0x52b5a0('0x1f')},'dialAMDInitialSilence':{'type':Sequelize['INTEGER'](0x9)[_0x52b5a0('0x15')],'defaultValue':0x9c4,'validate':{'min':0x0},'comment':'#AMD\x20Initial\x20Silence'},'dialAMDGreeting':{'type':Sequelize['INTEGER'](0x9)[_0x52b5a0('0x15')],'defaultValue':0x5dc,'validate':{'min':0x0},'comment':_0x52b5a0('0x1c')},'dialAMDAfterGreetingSilence':{'type':Sequelize[_0x52b5a0('0x2')](0x9)[_0x52b5a0('0x15')],'defaultValue':0x320,'validate':{'min':0x0},'comment':'#AMD\x20After\x20Greeting\x20Silence'},'dialAMDTotalAnalysisTime':{'type':Sequelize[_0x52b5a0('0x2')](0x9)[_0x52b5a0('0x15')],'defaultValue':0x1388,'validate':{'min':0x0},'comment':'#AMD\x20Total\x20Analysis\x20Time'},'dialAMDMinWordLength':{'type':Sequelize[_0x52b5a0('0x2')](0x9)[_0x52b5a0('0x15')],'defaultValue':0x64,'validate':{'min':0x0},'comment':_0x52b5a0('0x20')},'dialAMDBetweenWordsSilence':{'type':Sequelize[_0x52b5a0('0x2')](0x9)[_0x52b5a0('0x15')],'defaultValue':0x32,'validate':{'min':0x0},'comment':'#AMD\x20Between\x20Words\x20Silence'},'dialAMDMaximumNumberOfWords':{'type':Sequelize[_0x52b5a0('0x2')](0x9)[_0x52b5a0('0x15')],'defaultValue':0x3,'validate':{'min':0x0},'comment':_0x52b5a0('0xb')},'dialAMDSilenceThreshold':{'type':Sequelize[_0x52b5a0('0x2')](0x5)[_0x52b5a0('0x15')],'validate':{'min':0x0,'max':0x7fff},'defaultValue':0x100,'comment':_0x52b5a0('0xd')},'dialAMDMaximumWordLength':{'type':Sequelize[_0x52b5a0('0x2')](0x9)[_0x52b5a0('0x15')],'defaultValue':0x1388,'validate':{'min':0x0},'comment':_0x52b5a0('0x13')},'dialOrderByScheduledAt':{'type':Sequelize['ENUM']('DESC','ASC'),'defaultValue':_0x52b5a0('0x5')},'dialPrefix':{'type':Sequelize['STRING'],'defaultValue':null},'dialRandomLastDigitCallerIdNumber':{'type':Sequelize['INTEGER'](0x3)[_0x52b5a0('0x15')],'validate':{'min':0x0,'max':0xf},'defaultValue':0x0,'comment':_0x52b5a0('0x0')},'dialCutDigit':{'type':Sequelize[_0x52b5a0('0x2')](0x3)[_0x52b5a0('0x15')],'validate':{'min':0x0,'max':0xf},'defaultValue':0x0,'comment':_0x52b5a0('0xa')},'dialNoSuchNumberMaxRetry':{'type':Sequelize[_0x52b5a0('0x2')](0x3)[_0x52b5a0('0x15')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x52b5a0('0x1d')},'dialNoSuchNumberRetryFrequency':{'type':Sequelize['INTEGER'](0x5)[_0x52b5a0('0x15')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':'NoSuchNumber\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)'},'dialDropMaxRetry':{'type':Sequelize[_0x52b5a0('0x2')](0x3)[_0x52b5a0('0x15')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x52b5a0('0x1')},'dialDropRetryFrequency':{'type':Sequelize[_0x52b5a0('0x2')](0x5)[_0x52b5a0('0x15')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x52b5a0('0xf')},'dialAbandonedMaxRetry':{'type':Sequelize[_0x52b5a0('0x2')](0x3)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':'#Abandoned\x20Retry\x20(min:1,\x20max:999)'},'dialAbandonedRetryFrequency':{'type':Sequelize['INTEGER'](0x5)[_0x52b5a0('0x15')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x52b5a0('0x1e')},'dialMachineMaxRetry':{'type':Sequelize[_0x52b5a0('0x2')](0x3)[_0x52b5a0('0x15')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x52b5a0('0x8')},'dialMachineRetryFrequency':{'type':Sequelize[_0x52b5a0('0x2')](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x52b5a0('0x16')},'dialAgentRejectMaxRetry':{'type':Sequelize[_0x52b5a0('0x2')](0x3)[_0x52b5a0('0x15')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x52b5a0('0xe')},'dialAgentRejectRetryFrequency':{'type':Sequelize[_0x52b5a0('0x2')](0x5)[_0x52b5a0('0x15')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x52b5a0('0x19')}}; \ No newline at end of file +const a41_0x5b49=['Abandoned\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','NoAnswer\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','#AgentReject\x20Retry\x20(min:1,\x20max:999)','sequelize','UNSIGNED','#Drop\x20Retry\x20(min:1,\x20max:999)','Busy\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','name','Active/Disactive\x20Campaign','#AMD\x20Maximum\x20Number\x20Of\x20Words','#Congestion\x20Retry\x20(min:1,\x20max:999)','Active/Disactive\x20AMD','Congestion\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','Machine\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','always','NoSuchNumber\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','DESC','INTEGER','ivr','Cut\x20Digit\x20(min:1,\x20max:15)','#AMD\x20Greeting','Max\x20200\x20calls.','#AMD\x20Min\x20Word\x20Length','Originate\x20Timeout\x20Seconds\x20(min:1,\x20max:999)','#AMD\x20Initial\x20Silence','07:00-22:00,*,*,*','STRING','#AMD\x20Total\x20Analysis\x20Time','#Global\x20Max\x20Retry\x20(min:1,\x20max:999)','#Machine\x20Retry\x20(min:1,\x20max:999)','never','#AMD\x20Between\x20Words\x20Silence','BOOLEAN','#AMD\x20Maximum\x20Word\x20Length','#NoSuchNumber\x20Retry\x20(min:1,\x20max:999)','#AMD\x20Silence\x20Threshold\x20(min:0,\x20max:32767)','ENUM','AgentReject\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','#Abandoned\x20Retry\x20(min:1,\x20max:999)','Random\x20Last\x20Digit\x20(min:1,\x20max:15)','ASC'];(function(_0x33dc78,_0x5b49e3){const _0x122830=function(_0x11bb97){while(--_0x11bb97){_0x33dc78['push'](_0x33dc78['shift']());}};_0x122830(++_0x5b49e3);}(a41_0x5b49,0x1d4));const a41_0x1228=function(_0x33dc78,_0x5b49e3){_0x33dc78=_0x33dc78-0x0;let _0x122830=a41_0x5b49[_0x33dc78];return _0x122830;};const _0x183101=a41_0x1228;'use strict';const Sequelize=require(_0x183101('0x1b'));module['exports']={'name':{'type':Sequelize[_0x183101('0x9')],'unique':_0x183101('0x1f'),'allowNull':![],'validate':{'is':/[A-Za-z0-9._\\+*!-]+/,'notEmpty':!![]}},'type':{'type':Sequelize[_0x183101('0x13')](_0x183101('0x1')),'allowNull':![],'defaultValue':_0x183101('0x1')},'description':{'type':Sequelize[_0x183101('0x9')]},'active':{'type':Sequelize['BOOLEAN'],'defaultValue':0x0,'comment':_0x183101('0x20')},'limitCalls':{'type':Sequelize[_0x183101('0x0')](0x4)[_0x183101('0x1c')],'defaultValue':0x1e,'validate':{'min':0x1,'max':0xc8},'comment':_0x183101('0x4')},'dialOriginateCallerIdName':{'type':Sequelize[_0x183101('0x9')]},'dialOriginateCallerIdNumber':{'type':Sequelize[_0x183101('0x9')]},'dialOriginateTimeout':{'type':Sequelize[_0x183101('0x0')](0x3)['UNSIGNED'],'defaultValue':0x1e,'validate':{'min':0x1,'max':0x3e7},'comment':_0x183101('0x6')},'dialCongestionMaxRetry':{'type':Sequelize[_0x183101('0x0')](0x3)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x183101('0x22')},'dialCongestionRetryFrequency':{'type':Sequelize[_0x183101('0x0')](0x5)[_0x183101('0x1c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x183101('0x24')},'dialBusyMaxRetry':{'type':Sequelize[_0x183101('0x0')](0x3)[_0x183101('0x1c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':'#Busy\x20Retry\x20(min:1,\x20max:999)'},'dialBusyRetryFrequency':{'type':Sequelize[_0x183101('0x0')](0x5)[_0x183101('0x1c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x183101('0x1e')},'dialNoAnswerMaxRetry':{'type':Sequelize[_0x183101('0x0')](0x3)[_0x183101('0x1c')],'defaultValue':0x3,'comment':'#NoAnswer\x20Retry\x20(min:1,\x20max:999)'},'dialNoAnswerRetryFrequency':{'type':Sequelize[_0x183101('0x0')](0x5)[_0x183101('0x1c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x183101('0x19')},'dialGlobalMaxRetry':{'type':Sequelize[_0x183101('0x0')](0x3)[_0x183101('0x1c')],'validate':{'min':0x1,'max':0x3e7},'defaultValue':0x4,'comment':_0x183101('0xb')},'dialTimezone':{'type':Sequelize[_0x183101('0x9')],'defaultValue':null},'dialGlobalInterval':{'type':Sequelize[_0x183101('0x9')],'defaultValue':_0x183101('0x8')},'dialCheckDuplicateType':{'type':Sequelize[_0x183101('0x13')](_0x183101('0x26'),_0x183101('0xd'),'onlyIfOpen'),'defaultValue':_0x183101('0x26')},'dialAMDActive':{'type':Sequelize[_0x183101('0xf')],'defaultValue':0x0,'comment':_0x183101('0x23')},'dialAMDInitialSilence':{'type':Sequelize[_0x183101('0x0')](0x9)[_0x183101('0x1c')],'defaultValue':0x9c4,'validate':{'min':0x0},'comment':_0x183101('0x7')},'dialAMDGreeting':{'type':Sequelize['INTEGER'](0x9)[_0x183101('0x1c')],'defaultValue':0x5dc,'validate':{'min':0x0},'comment':_0x183101('0x3')},'dialAMDAfterGreetingSilence':{'type':Sequelize['INTEGER'](0x9)[_0x183101('0x1c')],'defaultValue':0x320,'validate':{'min':0x0},'comment':'#AMD\x20After\x20Greeting\x20Silence'},'dialAMDTotalAnalysisTime':{'type':Sequelize[_0x183101('0x0')](0x9)[_0x183101('0x1c')],'defaultValue':0x1388,'validate':{'min':0x0},'comment':_0x183101('0xa')},'dialAMDMinWordLength':{'type':Sequelize['INTEGER'](0x9)[_0x183101('0x1c')],'defaultValue':0x64,'validate':{'min':0x0},'comment':_0x183101('0x5')},'dialAMDBetweenWordsSilence':{'type':Sequelize[_0x183101('0x0')](0x9)[_0x183101('0x1c')],'defaultValue':0x32,'validate':{'min':0x0},'comment':_0x183101('0xe')},'dialAMDMaximumNumberOfWords':{'type':Sequelize[_0x183101('0x0')](0x9)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x0},'comment':_0x183101('0x21')},'dialAMDSilenceThreshold':{'type':Sequelize[_0x183101('0x0')](0x5)[_0x183101('0x1c')],'validate':{'min':0x0,'max':0x7fff},'defaultValue':0x100,'comment':_0x183101('0x12')},'dialAMDMaximumWordLength':{'type':Sequelize[_0x183101('0x0')](0x9)['UNSIGNED'],'defaultValue':0x1388,'validate':{'min':0x0},'comment':_0x183101('0x10')},'dialOrderByScheduledAt':{'type':Sequelize[_0x183101('0x13')]('DESC',_0x183101('0x17')),'defaultValue':_0x183101('0x28')},'dialPrefix':{'type':Sequelize[_0x183101('0x9')],'defaultValue':null},'dialRandomLastDigitCallerIdNumber':{'type':Sequelize[_0x183101('0x0')](0x3)[_0x183101('0x1c')],'validate':{'min':0x0,'max':0xf},'defaultValue':0x0,'comment':_0x183101('0x16')},'dialCutDigit':{'type':Sequelize[_0x183101('0x0')](0x3)[_0x183101('0x1c')],'validate':{'min':0x0,'max':0xf},'defaultValue':0x0,'comment':_0x183101('0x2')},'dialNoSuchNumberMaxRetry':{'type':Sequelize['INTEGER'](0x3)[_0x183101('0x1c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x183101('0x11')},'dialNoSuchNumberRetryFrequency':{'type':Sequelize['INTEGER'](0x5)[_0x183101('0x1c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x183101('0x27')},'dialDropMaxRetry':{'type':Sequelize['INTEGER'](0x3)[_0x183101('0x1c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x183101('0x1d')},'dialDropRetryFrequency':{'type':Sequelize[_0x183101('0x0')](0x5)[_0x183101('0x1c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':'Drop\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)'},'dialAbandonedMaxRetry':{'type':Sequelize[_0x183101('0x0')](0x3)[_0x183101('0x1c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x183101('0x15')},'dialAbandonedRetryFrequency':{'type':Sequelize[_0x183101('0x0')](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x183101('0x18')},'dialMachineMaxRetry':{'type':Sequelize[_0x183101('0x0')](0x3)[_0x183101('0x1c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x183101('0xc')},'dialMachineRetryFrequency':{'type':Sequelize[_0x183101('0x0')](0x5)[_0x183101('0x1c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x183101('0x25')},'dialAgentRejectMaxRetry':{'type':Sequelize['INTEGER'](0x3)[_0x183101('0x1c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x183101('0x1a')},'dialAgentRejectRetryFrequency':{'type':Sequelize['INTEGER'](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x183101('0x14')}}; \ No newline at end of file diff --git a/server/api/campaign/campaign.controller.js b/server/api/campaign/campaign.controller.js index 1268736..9e991f7 100644 --- a/server/api/campaign/campaign.controller.js +++ b/server/api/campaign/campaign.controller.js @@ -1 +1 @@ -const a42_0x5165=['../../mysqldb','get','status','destroy','stack','UserProfileSection','COALESCE(phone,\x27\x27)','CampaignId\x20=\x20?','CmList','updatedAt','createdAt','NOW()','CmHopperBlack','getHopperBlacks','then','attributes','ContactId','CmHopperHistory','filters','fields','getBlackLists','toString','update','userProfileId','role','set','phone','cm_hopper_black','keys','findOne','lodash','body','removeBlackLists','insert','end','CampaignId','CmListId','index','all','findAll','sort','length','where','field','merge','phone\x20IS\x20NOT\x20NULL','type','user','into','nolimit','json','intersection','key','ids','includeAll','removeLists','options','Unable\x20to\x20retrieve\x20the\x20current\x20user','like','IvrCampaigns','squel','Campaign','addLists','name','undefined','omit','UserProfileResource','getHoppers','ListId\x20=\x20?','always','dialCheckDuplicateType','cm_hopper','filter','onlyIfOpen','autoAssociation','error','CmHopperFinal','Content-Range','rows','../../components/parsers/qs','limit','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','from','cm_contacts','ListId','pick','send','getLists','CmHopper','clone','push','count','params','../../config/logger','catch','include','map','scheduledAt','show','addBlackLists','sequelize','select','model','offset','create','deletedAt\x20IS\x20NULL','rawAttributes','getHopperHistories','order','query','fromQuery','phone\x20NOT\x20IN\x20(?)','getHopperFinals'];(function(_0x376f36,_0x51650d){const _0x196650=function(_0x599a01){while(--_0x599a01){_0x376f36['push'](_0x376f36['shift']());}};_0x196650(++_0x51650d);}(a42_0x5165,0x153));const a42_0x1966=function(_0x376f36,_0x51650d){_0x376f36=_0x376f36-0x0;let _0x196650=a42_0x5165[_0x376f36];return _0x196650;};const _0x4ea7bb=a42_0x1966;'use strict';const _=require(_0x4ea7bb('0x1e')),squel=require(_0x4ea7bb('0x3c')),qs=require(_0x4ea7bb('0x4f')),logger=require(_0x4ea7bb('0x5d'))('api'),db=require(_0x4ea7bb('0x0'))['db'],{Op}=require(_0x4ea7bb('0x64'));function respondWithStatusCode(_0x599a01,_0x22efe7){return _0x22efe7=_0x22efe7||0xcc,function(_0x542acc){const _0x216b46=a42_0x1966;if(_0x542acc)return _0x599a01['sendStatus'](_0x22efe7);return _0x599a01[_0x216b46('0x2')](_0x22efe7)[_0x216b46('0x22')]();};}function respondWithResult(_0x291209,_0x539f26){return _0x539f26=_0x539f26||0xc8,function(_0x4b72a0){const _0xbd2525=a42_0x1966;if(_0x4b72a0)return _0x291209[_0xbd2525('0x2')](_0x539f26)[_0xbd2525('0x32')](_0x4b72a0);};}function respondWithFilteredResult(_0x1c4883,_0xd95a26){return function(_0x458854){const _0x450f9a=a42_0x1966;if(_0x458854){const _0x487a1f=_0x458854[_0x450f9a('0x5b')],_0x5c59fd=_0xd95a26[_0x450f9a('0x67')];let _0x269fef=_0xd95a26[_0x450f9a('0x67')]+_0xd95a26[_0x450f9a('0x50')],_0x462788;return _0x269fef>=_0x487a1f?(_0x269fef=_0x487a1f,_0x462788=0xc8):_0x462788=0xce,_0x1c4883[_0x450f9a('0x2')](_0x462788),_0x1c4883[_0x450f9a('0x19')](_0x450f9a('0x4d'),_0x5c59fd+'-'+_0x269fef+'/'+_0x487a1f)[_0x450f9a('0x32')](_0x458854);}return null;};}function saveUpdates(_0x1a9fe5){return function(_0x1becd8){const _0x5bf6af=a42_0x1966;if(_0x1becd8)return _0x1becd8[_0x5bf6af('0x16')](_0x1a9fe5)[_0x5bf6af('0xe')](function(_0x370c3f){return _0x370c3f;});return null;};}function removeEntity(_0x187df0){return function(_0x73485){if(_0x73485)return _0x73485['destroy']()['then'](function(){const _0x3178cf=a42_0x1966,_0x472a9f=_0x73485[_0x3178cf('0x1')]({'plain':!![]}),_0x59489b=_0x3178cf('0x3b');return db[_0x3178cf('0x42')][_0x3178cf('0x3')]({'where':{'type':_0x59489b,'resourceId':_0x472a9f['id']}})[_0x3178cf('0xe')](function(){return _0x73485;});})['then'](function(){const _0x53ea6f=a42_0x1966;_0x187df0['status'](0xcc)[_0x53ea6f('0x22')]();});};}function handleEntityNotFound(_0x4d0689){return function(_0x313091){return!_0x313091&&_0x4d0689['sendStatus'](0x194),_0x313091;};}function handleError(_0x3c1245,_0x8e76db){return _0x8e76db=_0x8e76db||0x1f4,function(_0x3216cb){const _0x3a1717=a42_0x1966;logger[_0x3a1717('0x4b')](_0x3216cb[_0x3a1717('0x4')]),_0x3216cb[_0x3a1717('0x3f')]&&delete _0x3216cb[_0x3a1717('0x3f')],_0x3c1245[_0x3a1717('0x2')](_0x8e76db)[_0x3a1717('0x56')](_0x3216cb);};}exports[_0x4ea7bb('0x25')]=function(_0x23daf7,_0x483aec){const _0x4c3537=_0x4ea7bb;let _0x22e1e5={};const _0x170e9d={},_0x37ace8={'count':0x0,'rows':[]},_0x3acfee=_[_0x4c3537('0x60')](db[_0x4c3537('0x3d')][_0x4c3537('0x6a')],function(_0x4d9ab0){const _0x5cc401=_0x4c3537;return{'name':_0x4d9ab0['fieldName'],'type':_0x4d9ab0['type'][_0x5cc401('0x34')]};});_0x170e9d[_0x4c3537('0x66')]=_[_0x4c3537('0x60')](_0x3acfee,_0x4c3537('0x3f')),_0x170e9d[_0x4c3537('0x6d')]=_['keys'](_0x23daf7[_0x4c3537('0x6d')]),_0x170e9d['filters']=_[_0x4c3537('0x33')](_0x170e9d[_0x4c3537('0x66')],_0x170e9d[_0x4c3537('0x6d')]),_0x22e1e5[_0x4c3537('0xf')]=_['intersection'](_0x170e9d[_0x4c3537('0x66')],qs[_0x4c3537('0x13')](_0x23daf7[_0x4c3537('0x6d')]['fields'])),_0x22e1e5[_0x4c3537('0xf')]=_0x22e1e5[_0x4c3537('0xf')][_0x4c3537('0x29')]?_0x22e1e5[_0x4c3537('0xf')]:_0x170e9d[_0x4c3537('0x66')];typeof _0x23daf7[_0x4c3537('0x6d')][_0x4c3537('0x31')]===_0x4c3537('0x40')&&(_0x22e1e5['limit']=qs[_0x4c3537('0x50')](_0x23daf7[_0x4c3537('0x6d')]['limit']),_0x22e1e5[_0x4c3537('0x67')]=qs['offset'](_0x23daf7[_0x4c3537('0x6d')][_0x4c3537('0x67')]));_0x22e1e5[_0x4c3537('0x6c')]=qs[_0x4c3537('0x28')](_0x23daf7[_0x4c3537('0x6d')][_0x4c3537('0x28')]),_0x22e1e5[_0x4c3537('0x2a')]=qs[_0x4c3537('0x12')](_[_0x4c3537('0x55')](_0x23daf7[_0x4c3537('0x6d')],_0x170e9d['filters']),_0x3acfee);_0x23daf7[_0x4c3537('0x6d')][_0x4c3537('0x48')]&&(_0x22e1e5['where']=_[_0x4c3537('0x2c')](_0x22e1e5[_0x4c3537('0x2a')],{[Op['or']]:_[_0x4c3537('0x60')](_0x3acfee,function(_0x4cdf6b){const _0xe4a944=_0x4c3537;if(_0x4cdf6b[_0xe4a944('0x2e')]!=='VIRTUAL'){const _0x1e2945={};return _0x1e2945[_0x4cdf6b['name']]={[Op[_0xe4a944('0x3a')]]:'%'+_0x23daf7[_0xe4a944('0x6d')][_0xe4a944('0x48')]+'%'},_0x1e2945;}})}));_0x22e1e5=_['merge']({},_0x22e1e5,_0x23daf7[_0x4c3537('0x38')]);const _0x217b7f={'where':_0x22e1e5['where']};return db[_0x4c3537('0x3d')][_0x4c3537('0x5b')](_0x217b7f)[_0x4c3537('0xe')](function(_0x4aca5c){const _0x1464c9=_0x4c3537;return _0x37ace8[_0x1464c9('0x5b')]=_0x4aca5c,_0x23daf7[_0x1464c9('0x6d')][_0x1464c9('0x36')]&&(_0x22e1e5['include']=[{'all':!![]}]),db['Campaign'][_0x1464c9('0x27')](_0x22e1e5);})[_0x4c3537('0xe')](function(_0xe5b0f9){const _0x5d7b10=_0x4c3537;return _0x37ace8[_0x5d7b10('0x4e')]=_0xe5b0f9,_0x37ace8;})[_0x4c3537('0xe')](respondWithFilteredResult(_0x483aec,_0x22e1e5))[_0x4c3537('0x5e')](handleError(_0x483aec,null));},exports[_0x4ea7bb('0x62')]=function(_0x2e38b5,_0x42f682){const _0x343c5b=_0x4ea7bb;let _0x157660={'raw':![],'where':{'id':_0x2e38b5['params']['id']}};const _0x533867={};return _0x533867[_0x343c5b('0x66')]=_[_0x343c5b('0x1c')](db['Campaign']['rawAttributes']),_0x533867[_0x343c5b('0x6d')]=_[_0x343c5b('0x1c')](_0x2e38b5[_0x343c5b('0x6d')]),_0x533867[_0x343c5b('0x12')]=_[_0x343c5b('0x33')](_0x533867[_0x343c5b('0x66')],_0x533867[_0x343c5b('0x6d')]),_0x157660[_0x343c5b('0xf')]=_[_0x343c5b('0x33')](_0x533867['model'],qs[_0x343c5b('0x13')](_0x2e38b5['query'][_0x343c5b('0x13')])),_0x157660[_0x343c5b('0xf')]=_0x157660[_0x343c5b('0xf')][_0x343c5b('0x29')]?_0x157660[_0x343c5b('0xf')]:_0x533867[_0x343c5b('0x66')],_0x2e38b5[_0x343c5b('0x6d')]['includeAll']&&(_0x157660['include']=[{'all':!![]}]),_0x157660=_['merge']({},_0x157660,_0x2e38b5['options']),db[_0x343c5b('0x3d')][_0x343c5b('0x1d')](_0x157660)[_0x343c5b('0xe')](handleEntityNotFound(_0x42f682,null))[_0x343c5b('0xe')](respondWithResult(_0x42f682,null))['catch'](handleError(_0x42f682,null));},exports[_0x4ea7bb('0x68')]=function(_0x2bca33,_0x26b56f){const _0xd70f9d=_0x4ea7bb;return db[_0xd70f9d('0x3d')]['create'](_0x2bca33[_0xd70f9d('0x1f')],{})['then'](function(_0x269c5c){const _0x387085=_0xd70f9d,_0x3b47cd=_0x2bca33['user']['get']({'plain':!![]});if(!_0x3b47cd)throw new Error(_0x387085('0x39'));if(_0x3b47cd[_0x387085('0x18')]===_0x387085('0x2f')){const _0x35407c=_0x269c5c['get']({'plain':!![]}),_0x9d833b=_0x387085('0x3b');return db[_0x387085('0x5')][_0x387085('0x1d')]({'where':{'name':_0x9d833b,'userProfileId':_0x3b47cd[_0x387085('0x17')]},'raw':!![]})[_0x387085('0xe')](function(_0x36b930){const _0x41a1b6=_0x387085;return _0x36b930&&_0x36b930[_0x41a1b6('0x4a')]===0x0?db['UserProfileResource'][_0x41a1b6('0x68')]({'name':_0x35407c[_0x41a1b6('0x3f')],'resourceId':_0x35407c['id'],'type':_0x36b930[_0x41a1b6('0x3f')],'sectionId':_0x36b930['id']},{})['then'](function(){return _0x269c5c;}):_0x269c5c;})['catch'](function(_0xfd31bb){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0xfd31bb);throw _0xfd31bb;});}return _0x269c5c;})[_0xd70f9d('0xe')](respondWithResult(_0x26b56f,0xc9))['catch'](handleError(_0x26b56f,null));},exports[_0x4ea7bb('0x59')]=function(_0x359d3a,_0x45f12a){const _0x384223=_0x4ea7bb;let _0x1fc6a5={'where':{'id':_0x359d3a[_0x384223('0x5c')]['id']}};const _0x4fe031={};return _0x4fe031[_0x384223('0x66')]=_[_0x384223('0x1c')](db[_0x384223('0x3d')][_0x384223('0x6a')]),_0x1fc6a5[_0x384223('0xf')]=_[_0x384223('0x33')](_0x4fe031[_0x384223('0x66')],qs[_0x384223('0x13')](_0x359d3a[_0x384223('0x6d')]['fields'])),_0x1fc6a5[_0x384223('0xf')]=_0x1fc6a5['attributes']['length']?_0x1fc6a5[_0x384223('0xf')]:_0x4fe031['model'],_0x359d3a[_0x384223('0x6d')][_0x384223('0x36')]&&(_0x1fc6a5['include']=[{'all':!![]}]),_0x1fc6a5=_[_0x384223('0x2c')]({},_0x1fc6a5,_0x359d3a[_0x384223('0x38')]),db[_0x384223('0x3d')][_0x384223('0x1d')](_0x1fc6a5)['then'](handleEntityNotFound(_0x45f12a,null))['then'](function(_0x46e318){const _0x12f99b=_0x384223;if(_0x46e318){let _0x55db9e=_0x46e318['get']({'plain':!![]});return _0x55db9e=qs[_0x12f99b('0x41')](_0x55db9e,['id',_0x12f99b('0xa'),'updatedAt']),_0x359d3a['body']=_[_0x12f99b('0x41')](_0x359d3a[_0x12f99b('0x1f')],['id',_0x12f99b('0xa'),_0x12f99b('0x9')]),db[_0x12f99b('0x3d')][_0x12f99b('0x68')](_[_0x12f99b('0x2c')](_0x55db9e,_0x359d3a[_0x12f99b('0x1f')]),{'include':_0x359d3a[_0x12f99b('0x6d')]['includeAll']?[{'all':!![]}]:undefined})['then'](function(_0x1e6ffe){const _0x1c87aa=_0x12f99b,_0x5b1e37=_0x359d3a[_0x1c87aa('0x2f')][_0x1c87aa('0x1')]({'plain':!![]});if(!_0x5b1e37)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x5b1e37[_0x1c87aa('0x18')]==='user'){const _0x28402c=_0x1e6ffe[_0x1c87aa('0x1')]({'plain':!![]}),_0x45cba8=_0x1c87aa('0x3b');return db['UserProfileSection'][_0x1c87aa('0x1d')]({'where':{'name':_0x45cba8,'userProfileId':_0x5b1e37[_0x1c87aa('0x17')]},'raw':!![]})[_0x1c87aa('0xe')](function(_0x7a520d){const _0x6793a0=_0x1c87aa;return _0x7a520d&&_0x7a520d['autoAssociation']===0x0?db[_0x6793a0('0x42')][_0x6793a0('0x68')]({'name':_0x28402c[_0x6793a0('0x3f')],'resourceId':_0x28402c['id'],'type':_0x7a520d[_0x6793a0('0x3f')],'sectionId':_0x7a520d['id']},{})[_0x6793a0('0xe')](function(){return _0x1e6ffe;}):_0x1e6ffe;})[_0x1c87aa('0x5e')](function(_0x51dd96){const _0x4576ca=_0x1c87aa;logger['error'](_0x4576ca('0x51'),_0x51dd96);throw _0x51dd96;});}return _0x1e6ffe;});}})[_0x384223('0xe')](respondWithResult(_0x45f12a,0xc9))['catch'](handleError(_0x45f12a,null));},exports[_0x4ea7bb('0x16')]=function(_0xedec49,_0xef3532){const _0x2ca706=_0x4ea7bb;return _0xedec49[_0x2ca706('0x1f')]['id']&&delete _0xedec49['body']['id'],db[_0x2ca706('0x3d')][_0x2ca706('0x1d')]({'where':{'id':_0xedec49[_0x2ca706('0x5c')]['id']}})[_0x2ca706('0xe')](handleEntityNotFound(_0xef3532,null))[_0x2ca706('0xe')](saveUpdates(_0xedec49[_0x2ca706('0x1f')],null))['then'](respondWithResult(_0xef3532,null))[_0x2ca706('0x5e')](handleError(_0xef3532,null));},exports[_0x4ea7bb('0x3')]=function(_0x5b7eef,_0x78523){const _0x2a099d=_0x4ea7bb;return db[_0x2a099d('0x3d')][_0x2a099d('0x1d')]({'where':{'id':_0x5b7eef[_0x2a099d('0x5c')]['id']}})['then'](handleEntityNotFound(_0x78523,null))[_0x2a099d('0xe')](removeEntity(_0x78523,null))[_0x2a099d('0x5e')](handleError(_0x78523,null));},exports[_0x4ea7bb('0x43')]=function(_0x156246,_0x350481){const _0x55ef18=_0x4ea7bb;let _0x2ead94={'raw':!![],'where':{}};const _0x237a74={},_0x47e128={'count':0x0,'rows':[]};return db[_0x55ef18('0x3d')][_0x55ef18('0x1d')]({'where':{'id':_0x156246[_0x55ef18('0x5c')]['id']}})['then'](handleEntityNotFound(_0x350481,null))['then'](function(_0x589934){const _0x44b3b7=_0x55ef18;if(_0x589934)return _0x237a74[_0x44b3b7('0x66')]=_[_0x44b3b7('0x1c')](db[_0x44b3b7('0x58')]['rawAttributes']),_0x237a74[_0x44b3b7('0x6d')]=_[_0x44b3b7('0x1c')](_0x156246[_0x44b3b7('0x6d')]),_0x237a74[_0x44b3b7('0x12')]=_[_0x44b3b7('0x33')](_0x237a74['model'],_0x237a74['query']),_0x2ead94[_0x44b3b7('0xf')]=_[_0x44b3b7('0x33')](_0x237a74['model'],qs[_0x44b3b7('0x13')](_0x156246['query']['fields'])),_0x2ead94[_0x44b3b7('0xf')]=_0x2ead94[_0x44b3b7('0xf')][_0x44b3b7('0x29')]?_0x2ead94[_0x44b3b7('0xf')]:_0x237a74[_0x44b3b7('0x66')],typeof _0x156246[_0x44b3b7('0x6d')][_0x44b3b7('0x31')]===_0x44b3b7('0x40')&&(_0x2ead94[_0x44b3b7('0x50')]=qs[_0x44b3b7('0x50')](_0x156246[_0x44b3b7('0x6d')]['limit']),_0x2ead94[_0x44b3b7('0x67')]=qs[_0x44b3b7('0x67')](_0x156246[_0x44b3b7('0x6d')]['offset'])),_0x2ead94['order']=qs[_0x44b3b7('0x28')](_0x156246[_0x44b3b7('0x6d')][_0x44b3b7('0x28')]),_0x2ead94[_0x44b3b7('0x2a')]=qs['filters'](_[_0x44b3b7('0x55')](_0x156246[_0x44b3b7('0x6d')],_0x237a74[_0x44b3b7('0x12')])),_0x2ead94[_0x44b3b7('0x2a')]['CampaignId']=_0x589934['id'],_0x156246['query']['filter']&&(_0x2ead94[_0x44b3b7('0x2a')]=_[_0x44b3b7('0x2c')](_0x2ead94['where'],{[Op['or']]:_[_0x44b3b7('0x60')](_0x2ead94[_0x44b3b7('0xf')],function(_0x3c7830){const _0xf69fd6=_0x44b3b7,_0x43b61b={};return _0x43b61b[_0x3c7830]={[Op[_0xf69fd6('0x3a')]]:'%'+_0x156246[_0xf69fd6('0x6d')][_0xf69fd6('0x48')]+'%'},_0x43b61b;})})),_0x2ead94=_[_0x44b3b7('0x2c')]({},_0x2ead94,_0x156246[_0x44b3b7('0x38')]),db['CmHopper'][_0x44b3b7('0x5b')]({'where':_0x2ead94['where']})['then'](function(_0x21fc59){const _0x1e1212=_0x44b3b7;return _0x47e128[_0x1e1212('0x5b')]=_0x21fc59,_0x156246[_0x1e1212('0x6d')][_0x1e1212('0x36')]&&(_0x2ead94['include']=[{'all':!![]}]),db[_0x1e1212('0x58')][_0x1e1212('0x27')](_0x2ead94);})[_0x44b3b7('0xe')](function(_0xb98c11){const _0x49a659=_0x44b3b7;return _0x47e128[_0x49a659('0x4e')]=_0xb98c11,_0x47e128;});})[_0x55ef18('0xe')](respondWithFilteredResult(_0x350481,_0x2ead94))['catch'](handleError(_0x350481,null));},exports[_0x4ea7bb('0x6b')]=function(_0x3ea3b1,_0x537466){const _0x4cc790=_0x4ea7bb;let _0x4f5e6e={'raw':!![],'where':{}};const _0x129e05={},_0x379587={'count':0x0,'rows':[]};return db[_0x4cc790('0x3d')][_0x4cc790('0x1d')]({'where':{'id':_0x3ea3b1[_0x4cc790('0x5c')]['id']}})['then'](handleEntityNotFound(_0x537466,null))[_0x4cc790('0xe')](function(_0x462c11){const _0x2f7284=_0x4cc790;if(_0x462c11)return _0x129e05[_0x2f7284('0x66')]=_[_0x2f7284('0x1c')](db['CmHopperHistory'][_0x2f7284('0x6a')]),_0x129e05[_0x2f7284('0x6d')]=_[_0x2f7284('0x1c')](_0x3ea3b1['query']),_0x129e05[_0x2f7284('0x12')]=_['intersection'](_0x129e05[_0x2f7284('0x66')],_0x129e05[_0x2f7284('0x6d')]),_0x4f5e6e[_0x2f7284('0xf')]=_[_0x2f7284('0x33')](_0x129e05[_0x2f7284('0x66')],qs[_0x2f7284('0x13')](_0x3ea3b1[_0x2f7284('0x6d')][_0x2f7284('0x13')])),_0x4f5e6e[_0x2f7284('0xf')]=_0x4f5e6e['attributes'][_0x2f7284('0x29')]?_0x4f5e6e['attributes']:_0x129e05[_0x2f7284('0x66')],typeof _0x3ea3b1[_0x2f7284('0x6d')][_0x2f7284('0x31')]===_0x2f7284('0x40')&&(_0x4f5e6e['limit']=qs[_0x2f7284('0x50')](_0x3ea3b1['query']['limit']),_0x4f5e6e[_0x2f7284('0x67')]=qs['offset'](_0x3ea3b1[_0x2f7284('0x6d')][_0x2f7284('0x67')])),_0x4f5e6e[_0x2f7284('0x6c')]=qs[_0x2f7284('0x28')](_0x3ea3b1[_0x2f7284('0x6d')]['sort']),_0x4f5e6e['where']=qs[_0x2f7284('0x12')](_['pick'](_0x3ea3b1[_0x2f7284('0x6d')],_0x129e05[_0x2f7284('0x12')])),_0x4f5e6e[_0x2f7284('0x2a')][_0x2f7284('0x23')]=_0x462c11['id'],_0x3ea3b1[_0x2f7284('0x6d')][_0x2f7284('0x48')]&&(_0x4f5e6e['where']=_[_0x2f7284('0x2c')](_0x4f5e6e[_0x2f7284('0x2a')],{[Op['or']]:_[_0x2f7284('0x60')](_0x4f5e6e[_0x2f7284('0xf')],function(_0x4305a6){const _0xb3f6d6=_0x2f7284,_0x3c0586={};return _0x3c0586[_0x4305a6]={[Op[_0xb3f6d6('0x3a')]]:'%'+_0x3ea3b1[_0xb3f6d6('0x6d')][_0xb3f6d6('0x48')]+'%'},_0x3c0586;})})),_0x4f5e6e=_[_0x2f7284('0x2c')]({},_0x4f5e6e,_0x3ea3b1[_0x2f7284('0x38')]),db['CmHopperHistory'][_0x2f7284('0x5b')]({'where':_0x4f5e6e[_0x2f7284('0x2a')]})[_0x2f7284('0xe')](function(_0x1d974a){const _0x30f2d2=_0x2f7284;return _0x379587[_0x30f2d2('0x5b')]=_0x1d974a,_0x3ea3b1[_0x30f2d2('0x6d')][_0x30f2d2('0x36')]&&(_0x4f5e6e[_0x30f2d2('0x5f')]=[{'all':!![]}]),db[_0x30f2d2('0x11')][_0x30f2d2('0x27')](_0x4f5e6e);})['then'](function(_0x488c90){return _0x379587['rows']=_0x488c90,_0x379587;});})[_0x4cc790('0xe')](respondWithFilteredResult(_0x537466,_0x4f5e6e))['catch'](handleError(_0x537466,null));},exports[_0x4ea7bb('0x70')]=function(_0xc439af,_0x1bce39){const _0x1d6b2c=_0x4ea7bb;let _0x47bf0b={'raw':!![],'where':{}};const _0x2d3dc6={},_0x1a52f7={'count':0x0,'rows':[]};return db[_0x1d6b2c('0x3d')]['findOne']({'where':{'id':_0xc439af[_0x1d6b2c('0x5c')]['id']}})[_0x1d6b2c('0xe')](handleEntityNotFound(_0x1bce39,null))[_0x1d6b2c('0xe')](function(_0x5a20ee){const _0x31ce6a=_0x1d6b2c;if(_0x5a20ee)return _0x2d3dc6[_0x31ce6a('0x66')]=_[_0x31ce6a('0x1c')](db[_0x31ce6a('0x4c')]['rawAttributes']),_0x2d3dc6[_0x31ce6a('0x6d')]=_[_0x31ce6a('0x1c')](_0xc439af[_0x31ce6a('0x6d')]),_0x2d3dc6['filters']=_[_0x31ce6a('0x33')](_0x2d3dc6[_0x31ce6a('0x66')],_0x2d3dc6[_0x31ce6a('0x6d')]),_0x47bf0b[_0x31ce6a('0xf')]=_[_0x31ce6a('0x33')](_0x2d3dc6[_0x31ce6a('0x66')],qs['fields'](_0xc439af[_0x31ce6a('0x6d')][_0x31ce6a('0x13')])),_0x47bf0b[_0x31ce6a('0xf')]=_0x47bf0b['attributes'][_0x31ce6a('0x29')]?_0x47bf0b['attributes']:_0x2d3dc6[_0x31ce6a('0x66')],typeof _0xc439af[_0x31ce6a('0x6d')][_0x31ce6a('0x31')]===_0x31ce6a('0x40')&&(_0x47bf0b[_0x31ce6a('0x50')]=qs[_0x31ce6a('0x50')](_0xc439af[_0x31ce6a('0x6d')][_0x31ce6a('0x50')]),_0x47bf0b[_0x31ce6a('0x67')]=qs[_0x31ce6a('0x67')](_0xc439af[_0x31ce6a('0x6d')][_0x31ce6a('0x67')])),_0x47bf0b[_0x31ce6a('0x6c')]=qs[_0x31ce6a('0x28')](_0xc439af[_0x31ce6a('0x6d')][_0x31ce6a('0x28')]),_0x47bf0b[_0x31ce6a('0x2a')]=qs[_0x31ce6a('0x12')](_[_0x31ce6a('0x55')](_0xc439af['query'],_0x2d3dc6[_0x31ce6a('0x12')])),_0x47bf0b[_0x31ce6a('0x2a')][_0x31ce6a('0x23')]=_0x5a20ee['id'],_0xc439af['query'][_0x31ce6a('0x48')]&&(_0x47bf0b['where']=_['merge'](_0x47bf0b[_0x31ce6a('0x2a')],{[Op['or']]:_[_0x31ce6a('0x60')](_0x47bf0b['attributes'],function(_0x5077fc){const _0x24c1a3=_0x31ce6a,_0x3eb836={};return _0x3eb836[_0x5077fc]={[Op['like']]:'%'+_0xc439af[_0x24c1a3('0x6d')]['filter']+'%'},_0x3eb836;})})),_0x47bf0b=_[_0x31ce6a('0x2c')]({},_0x47bf0b,_0xc439af[_0x31ce6a('0x38')]),db[_0x31ce6a('0x4c')]['count']({'where':_0x47bf0b['where']})[_0x31ce6a('0xe')](function(_0x18fa4d){const _0x2c2369=_0x31ce6a;return _0x1a52f7[_0x2c2369('0x5b')]=_0x18fa4d,_0xc439af[_0x2c2369('0x6d')][_0x2c2369('0x36')]&&(_0x47bf0b[_0x2c2369('0x5f')]=[{'all':!![]}]),db[_0x2c2369('0x4c')][_0x2c2369('0x27')](_0x47bf0b);})[_0x31ce6a('0xe')](function(_0x3bf85f){return _0x1a52f7['rows']=_0x3bf85f,_0x1a52f7;});})[_0x1d6b2c('0xe')](respondWithFilteredResult(_0x1bce39,_0x47bf0b))[_0x1d6b2c('0x5e')](handleError(_0x1bce39,null));},exports[_0x4ea7bb('0xd')]=function(_0x33689f,_0x141c3e){const _0x51dd0a=_0x4ea7bb;let _0x55b817={'raw':!![],'where':{}};const _0x1d6c19={},_0x53f4d7={'count':0x0,'rows':[]};return db['Campaign']['findOne']({'where':{'id':_0x33689f['params']['id']}})[_0x51dd0a('0xe')](handleEntityNotFound(_0x141c3e,null))[_0x51dd0a('0xe')](function(_0x1207d1){const _0x48fe97=_0x51dd0a;if(_0x1207d1)return _0x1d6c19['model']=_[_0x48fe97('0x1c')](db[_0x48fe97('0xc')][_0x48fe97('0x6a')]),_0x1d6c19['query']=_[_0x48fe97('0x1c')](_0x33689f['query']),_0x1d6c19[_0x48fe97('0x12')]=_[_0x48fe97('0x33')](_0x1d6c19[_0x48fe97('0x66')],_0x1d6c19[_0x48fe97('0x6d')]),_0x55b817[_0x48fe97('0xf')]=_[_0x48fe97('0x33')](_0x1d6c19[_0x48fe97('0x66')],qs[_0x48fe97('0x13')](_0x33689f[_0x48fe97('0x6d')]['fields'])),_0x55b817['attributes']=_0x55b817[_0x48fe97('0xf')][_0x48fe97('0x29')]?_0x55b817[_0x48fe97('0xf')]:_0x1d6c19[_0x48fe97('0x66')],typeof _0x33689f['query'][_0x48fe97('0x31')]===_0x48fe97('0x40')&&(_0x55b817[_0x48fe97('0x50')]=qs[_0x48fe97('0x50')](_0x33689f[_0x48fe97('0x6d')][_0x48fe97('0x50')]),_0x55b817['offset']=qs['offset'](_0x33689f[_0x48fe97('0x6d')][_0x48fe97('0x67')])),_0x55b817[_0x48fe97('0x6c')]=qs['sort'](_0x33689f[_0x48fe97('0x6d')][_0x48fe97('0x28')]),_0x55b817[_0x48fe97('0x2a')]=qs['filters'](_[_0x48fe97('0x55')](_0x33689f[_0x48fe97('0x6d')],_0x1d6c19[_0x48fe97('0x12')])),_0x55b817[_0x48fe97('0x2a')][_0x48fe97('0x23')]=_0x1207d1['id'],_0x33689f[_0x48fe97('0x6d')][_0x48fe97('0x48')]&&(_0x55b817[_0x48fe97('0x2a')]=_[_0x48fe97('0x2c')](_0x55b817[_0x48fe97('0x2a')],{[Op['or']]:_[_0x48fe97('0x60')](_0x55b817[_0x48fe97('0xf')],function(_0x396091){const _0x2268d9=_0x48fe97,_0x57ad12={};return _0x57ad12[_0x396091]={[Op['like']]:'%'+_0x33689f[_0x2268d9('0x6d')][_0x2268d9('0x48')]+'%'},_0x57ad12;})})),_0x55b817=_[_0x48fe97('0x2c')]({},_0x55b817,_0x33689f[_0x48fe97('0x38')]),db[_0x48fe97('0xc')]['count']({'where':_0x55b817[_0x48fe97('0x2a')]})[_0x48fe97('0xe')](function(_0x474b86){const _0x480fe7=_0x48fe97;return _0x53f4d7['count']=_0x474b86,_0x33689f[_0x480fe7('0x6d')][_0x480fe7('0x36')]&&(_0x55b817[_0x480fe7('0x5f')]=[{'all':!![]}]),db[_0x480fe7('0xc')]['findAll'](_0x55b817);})['then'](function(_0x3762d6){const _0x480a1e=_0x48fe97;return _0x53f4d7[_0x480a1e('0x4e')]=_0x3762d6,_0x53f4d7;});})[_0x51dd0a('0xe')](respondWithFilteredResult(_0x141c3e,_0x55b817))[_0x51dd0a('0x5e')](handleError(_0x141c3e,null));},exports[_0x4ea7bb('0x57')]=function(_0x2d6245,_0x1dbdc7){const _0x459e4b=_0x4ea7bb;let _0x476c01={};const _0x19700c={};let _0x4bd62e,_0x154f70;return db[_0x459e4b('0x3d')]['findOne']({'where':{'id':_0x2d6245[_0x459e4b('0x5c')]['id']}})[_0x459e4b('0xe')](handleEntityNotFound(_0x1dbdc7,null))[_0x459e4b('0xe')](function(_0x5779f3){const _0x4a5037=_0x459e4b;if(_0x5779f3)return _0x4bd62e=_0x5779f3,_0x19700c[_0x4a5037('0x66')]=_[_0x4a5037('0x1c')](db[_0x4a5037('0x8')][_0x4a5037('0x6a')]),_0x19700c[_0x4a5037('0x6d')]=_[_0x4a5037('0x1c')](_0x2d6245['query']),_0x19700c[_0x4a5037('0x12')]=_[_0x4a5037('0x33')](_0x19700c[_0x4a5037('0x66')],_0x19700c[_0x4a5037('0x6d')]),_0x476c01['attributes']=_[_0x4a5037('0x33')](_0x19700c[_0x4a5037('0x66')],qs[_0x4a5037('0x13')](_0x2d6245[_0x4a5037('0x6d')]['fields'])),_0x476c01['attributes']=_0x476c01[_0x4a5037('0xf')]['length']?_0x476c01[_0x4a5037('0xf')]:_0x19700c['model'],_0x476c01[_0x4a5037('0x6c')]=qs['sort'](_0x2d6245[_0x4a5037('0x6d')][_0x4a5037('0x28')]),_0x476c01[_0x4a5037('0x2a')]=qs[_0x4a5037('0x12')](_[_0x4a5037('0x55')](_0x2d6245[_0x4a5037('0x6d')],_0x19700c[_0x4a5037('0x12')])),_0x2d6245[_0x4a5037('0x6d')][_0x4a5037('0x48')]&&(_0x476c01[_0x4a5037('0x2a')]=_[_0x4a5037('0x2c')](_0x476c01[_0x4a5037('0x2a')],{[Op['or']]:_[_0x4a5037('0x60')](_0x476c01[_0x4a5037('0xf')],function(_0x3cb051){const _0x4a0b43=_0x4a5037,_0x5bd38d={};return _0x5bd38d[_0x3cb051]={[Op[_0x4a0b43('0x3a')]]:'%'+_0x2d6245[_0x4a0b43('0x6d')]['filter']+'%'},_0x5bd38d;})})),_0x476c01=_['merge']({},_0x476c01,_0x2d6245[_0x4a5037('0x38')]),_0x4bd62e[_0x4a5037('0x57')](_0x476c01);})[_0x459e4b('0xe')](function(_0x55993e){const _0x3b50d5=_0x459e4b;if(_0x55993e)return _0x154f70=_0x55993e[_0x3b50d5('0x29')],typeof _0x2d6245[_0x3b50d5('0x6d')][_0x3b50d5('0x31')]==='undefined'&&(_0x476c01[_0x3b50d5('0x50')]=qs['limit'](_0x2d6245[_0x3b50d5('0x6d')][_0x3b50d5('0x50')]),_0x476c01[_0x3b50d5('0x67')]=qs[_0x3b50d5('0x67')](_0x2d6245[_0x3b50d5('0x6d')][_0x3b50d5('0x67')])),_0x4bd62e[_0x3b50d5('0x57')](_0x476c01);})['then'](function(_0x454721){if(_0x454721)return _0x454721?{'count':_0x154f70,'rows':_0x454721}:null;})[_0x459e4b('0xe')](respondWithResult(_0x1dbdc7,null))[_0x459e4b('0x5e')](handleError(_0x1dbdc7,null));},exports[_0x4ea7bb('0x3e')]=function(_0x223340,_0x52f75d){const _0x1cbaed=_0x4ea7bb;let _0x4e84a5,_0x51bf23;return db[_0x1cbaed('0x3d')][_0x1cbaed('0x1d')]({'where':{'id':_0x223340[_0x1cbaed('0x5c')]['id']}})['then'](handleEntityNotFound(_0x52f75d,null))[_0x1cbaed('0xe')](function(_0x5f1bdb){const _0xcae45b=_0x1cbaed;if(_0x5f1bdb)return _0x51bf23=_0x5f1bdb,_0x5f1bdb[_0xcae45b('0x3e')](_0x223340[_0xcae45b('0x1f')][_0xcae45b('0x35')],{'through':_[_0xcae45b('0x41')](_0x223340[_0xcae45b('0x1f')],['ids','id'])});return null;})[_0x1cbaed('0xe')](function(_0x53b07b){const _0x5b67a6=_0x1cbaed;let _0x1cd94e;_0x4e84a5=_0x53b07b||[];const _0x566bc3=[];if(_0x53b07b){for(let _0x308d71=0x0;_0x308d71<_0x53b07b[_0x5b67a6('0x29')];_0x308d71+=0x1){const _0x7933fa=_0x53b07b[_0x308d71][_0x5b67a6('0x1')]({'plain':!![]});_0x51bf23[_0x5b67a6('0x46')]=_0x223340[_0x5b67a6('0x1f')][_0x5b67a6('0x46')]?_0x223340[_0x5b67a6('0x1f')]['dialCheckDuplicateType']:_0x51bf23[_0x5b67a6('0x46')];switch(_0x51bf23[_0x5b67a6('0x46')]){case _0x5b67a6('0x45'):_0x1cd94e=squel[_0x5b67a6('0x21')]()[_0x5b67a6('0x30')](_0x5b67a6('0x47'))[_0x5b67a6('0x6e')]([_0x5b67a6('0x1a'),_0x5b67a6('0x61'),_0x5b67a6('0x10'),_0x5b67a6('0x54'),_0x5b67a6('0x23'),'createdAt',_0x5b67a6('0x9')],squel['select']()[_0x5b67a6('0x2b')](_0x5b67a6('0x1a'),_0x5b67a6('0x1a'))[_0x5b67a6('0x2b')](_0x5b67a6('0xb'),_0x5b67a6('0x61'))[_0x5b67a6('0x2b')]('id','ContactId')[_0x5b67a6('0x2b')](_0x7933fa[_0x5b67a6('0x24')][_0x5b67a6('0x15')](),_0x5b67a6('0x54'))[_0x5b67a6('0x2b')](_0x223340['params']['id'][_0x5b67a6('0x15')](),'CampaignId')[_0x5b67a6('0x2b')](_0x5b67a6('0xb'),_0x5b67a6('0xa'))[_0x5b67a6('0x2b')]('NOW()',_0x5b67a6('0x9'))[_0x5b67a6('0x52')](_0x5b67a6('0x53'))['where'](_0x5b67a6('0x69'))[_0x5b67a6('0x2a')]('ListId\x20=\x20?',_0x7933fa['CmListId']['toString']())[_0x5b67a6('0x2a')](_0x5b67a6('0x2d'))[_0x5b67a6('0x2a')](_0x5b67a6('0x6f'),squel[_0x5b67a6('0x65')]()[_0x5b67a6('0x2b')]('COALESCE(calleridnum,\x27\x27)')[_0x5b67a6('0x52')]('cm_hopper_final')[_0x5b67a6('0x2a')](_0x5b67a6('0x7'),_0x223340['params']['id'][_0x5b67a6('0x15')]()))[_0x5b67a6('0x2a')](_0x5b67a6('0x6f'),squel[_0x5b67a6('0x65')]()[_0x5b67a6('0x2b')](_0x5b67a6('0x6'))[_0x5b67a6('0x52')](_0x5b67a6('0x47'))['where'](_0x5b67a6('0x7'),_0x223340[_0x5b67a6('0x5c')]['id']['toString']())))[_0x5b67a6('0x15')]();break;case _0x5b67a6('0x49'):_0x1cd94e=squel[_0x5b67a6('0x21')]()[_0x5b67a6('0x30')]('cm_hopper')[_0x5b67a6('0x6e')]([_0x5b67a6('0x1a'),_0x5b67a6('0x61'),_0x5b67a6('0x10'),'ListId',_0x5b67a6('0x23'),'createdAt',_0x5b67a6('0x9')],squel[_0x5b67a6('0x65')]()[_0x5b67a6('0x2b')]('phone',_0x5b67a6('0x1a'))['field']('NOW()',_0x5b67a6('0x61'))[_0x5b67a6('0x2b')]('id','ContactId')[_0x5b67a6('0x2b')](_0x7933fa[_0x5b67a6('0x24')][_0x5b67a6('0x15')](),_0x5b67a6('0x54'))[_0x5b67a6('0x2b')](_0x223340['params']['id'][_0x5b67a6('0x15')](),_0x5b67a6('0x23'))[_0x5b67a6('0x2b')](_0x5b67a6('0xb'),_0x5b67a6('0xa'))[_0x5b67a6('0x2b')](_0x5b67a6('0xb'),'updatedAt')[_0x5b67a6('0x52')](_0x5b67a6('0x53'))[_0x5b67a6('0x2a')](_0x5b67a6('0x69'))['where'](_0x5b67a6('0x44'),_0x7933fa[_0x5b67a6('0x24')]['toString']())[_0x5b67a6('0x2a')](_0x5b67a6('0x2d'))[_0x5b67a6('0x2a')](_0x5b67a6('0x6f'),squel['select']()['field'](_0x5b67a6('0x6'))['from'](_0x5b67a6('0x47'))[_0x5b67a6('0x2a')]('CampaignId\x20=\x20?',_0x223340[_0x5b67a6('0x5c')]['id'][_0x5b67a6('0x15')]())))['toString']();break;default:_0x1cd94e=squel['insert']()[_0x5b67a6('0x30')]('cm_hopper')[_0x5b67a6('0x6e')]([_0x5b67a6('0x1a'),_0x5b67a6('0x61'),_0x5b67a6('0x10'),'ListId',_0x5b67a6('0x23'),_0x5b67a6('0xa'),_0x5b67a6('0x9')],squel['select']()[_0x5b67a6('0x2b')]('phone',_0x5b67a6('0x1a'))['field'](_0x5b67a6('0xb'),_0x5b67a6('0x61'))[_0x5b67a6('0x2b')]('id',_0x5b67a6('0x10'))[_0x5b67a6('0x2b')](_0x7933fa[_0x5b67a6('0x24')][_0x5b67a6('0x15')](),_0x5b67a6('0x54'))['field'](_0x223340['params']['id'][_0x5b67a6('0x15')](),_0x5b67a6('0x23'))[_0x5b67a6('0x2b')](_0x5b67a6('0xb'),_0x5b67a6('0xa'))['field'](_0x5b67a6('0xb'),'updatedAt')[_0x5b67a6('0x52')](_0x5b67a6('0x53'))['where'](_0x5b67a6('0x69'))['where']('ListId\x20=\x20?',_0x7933fa[_0x5b67a6('0x24')][_0x5b67a6('0x15')]())['where'](_0x5b67a6('0x2d')))['toString']();}_0x566bc3[_0x5b67a6('0x5a')](db[_0x5b67a6('0x64')][_0x5b67a6('0x6d')](_0x1cd94e));}return Promise[_0x5b67a6('0x26')](_0x566bc3);}})['then'](function(){return _0x4e84a5;})[_0x1cbaed('0xe')](respondWithResult(_0x52f75d,null))[_0x1cbaed('0x5e')](handleError(_0x52f75d,null));},exports[_0x4ea7bb('0x37')]=function(_0x3fc73f,_0x3fb52f){const _0x4e6795=_0x4ea7bb;return db[_0x4e6795('0x3d')]['findOne']({'where':{'id':_0x3fc73f['params']['id']}})[_0x4e6795('0xe')](handleEntityNotFound(_0x3fb52f,null))[_0x4e6795('0xe')](function(_0x3d4025){const _0x4f6d94=_0x4e6795;if(_0x3d4025)return _0x3d4025[_0x4f6d94('0x37')](_0x3fc73f[_0x4f6d94('0x6d')][_0x4f6d94('0x35')]);})[_0x4e6795('0xe')](function(_0x5274d3){const _0x170719=_0x4e6795;if(_0x5274d3)return db[_0x170719('0x58')]['destroy']({'where':{'ListId':_0x3fc73f[_0x170719('0x6d')][_0x170719('0x35')],'CampaignId':_0x3fc73f[_0x170719('0x5c')]['id']}})[_0x170719('0xe')](function(){return _0x5274d3;});})['then'](respondWithStatusCode(_0x3fb52f,null))[_0x4e6795('0x5e')](handleError(_0x3fb52f,null));},exports[_0x4ea7bb('0x14')]=function(_0x2210c1,_0x1bee77){const _0xf0487b=_0x4ea7bb;let _0x17837b={'raw':!![],'where':{}};const _0x57e7f9={},_0x1e53b5={'count':0x0,'rows':[]};return db[_0xf0487b('0x3d')][_0xf0487b('0x1d')]({'where':{'id':_0x2210c1['params']['id']}})[_0xf0487b('0xe')](handleEntityNotFound(_0x1bee77,null))['then'](function(_0x57d977){const _0x53add8=_0xf0487b;if(_0x57d977)return _0x57e7f9[_0x53add8('0x66')]=_['keys'](db[_0x53add8('0x8')][_0x53add8('0x6a')]),_0x57e7f9[_0x53add8('0x6d')]=_[_0x53add8('0x1c')](_0x2210c1[_0x53add8('0x6d')]),_0x57e7f9[_0x53add8('0x12')]=_[_0x53add8('0x33')](_0x57e7f9[_0x53add8('0x66')],_0x57e7f9['query']),_0x17837b['attributes']=_[_0x53add8('0x33')](_0x57e7f9[_0x53add8('0x66')],qs[_0x53add8('0x13')](_0x2210c1[_0x53add8('0x6d')][_0x53add8('0x13')])),_0x17837b[_0x53add8('0xf')]=_0x17837b[_0x53add8('0xf')][_0x53add8('0x29')]?_0x17837b[_0x53add8('0xf')]:_0x57e7f9['model'],typeof _0x2210c1[_0x53add8('0x6d')][_0x53add8('0x31')]===_0x53add8('0x40')&&(_0x17837b[_0x53add8('0x50')]=qs['limit'](_0x2210c1[_0x53add8('0x6d')][_0x53add8('0x50')]),_0x17837b['offset']=qs[_0x53add8('0x67')](_0x2210c1[_0x53add8('0x6d')][_0x53add8('0x67')])),_0x17837b[_0x53add8('0x6c')]=qs['sort'](_0x2210c1[_0x53add8('0x6d')]['sort']),_0x17837b[_0x53add8('0x2a')]=qs[_0x53add8('0x12')](_[_0x53add8('0x55')](_0x2210c1[_0x53add8('0x6d')],_0x57e7f9[_0x53add8('0x12')])),_0x17837b[_0x53add8('0x2a')][_0x53add8('0x23')]=_0x57d977['id'],_0x2210c1[_0x53add8('0x6d')][_0x53add8('0x48')]&&(_0x17837b[_0x53add8('0x2a')]=_['merge'](_0x17837b[_0x53add8('0x2a')],{[Op['or']]:_[_0x53add8('0x60')](_0x17837b[_0x53add8('0xf')],function(_0x4a8748){const _0x3e1768=_0x53add8,_0x56387c={};return _0x56387c[_0x4a8748]={[Op['like']]:'%'+_0x2210c1[_0x3e1768('0x6d')][_0x3e1768('0x48')]+'%'},_0x56387c;})})),_0x17837b=_[_0x53add8('0x2c')]({},_0x17837b,_0x2210c1[_0x53add8('0x38')]),db[_0x53add8('0x8')]['count']({'where':_0x17837b['where']})[_0x53add8('0xe')](function(_0x1d2aed){const _0x4556fb=_0x53add8;return _0x1e53b5[_0x4556fb('0x5b')]=_0x1d2aed,_0x2210c1[_0x4556fb('0x6d')][_0x4556fb('0x36')]&&(_0x17837b[_0x4556fb('0x5f')]=[{'all':!![]}]),db[_0x4556fb('0x8')][_0x4556fb('0x27')](_0x17837b);})[_0x53add8('0xe')](function(_0x2673b8){const _0x637931=_0x53add8;return _0x1e53b5[_0x637931('0x4e')]=_0x2673b8,_0x1e53b5;});})[_0xf0487b('0xe')](respondWithFilteredResult(_0x1bee77,_0x17837b))[_0xf0487b('0x5e')](handleError(_0x1bee77,null));},exports[_0x4ea7bb('0x63')]=function(_0x23e55b,_0x4c113c){const _0xd3770f=_0x4ea7bb;let _0x3a84e5;return db[_0xd3770f('0x3d')][_0xd3770f('0x1d')]({'where':{'id':_0x23e55b[_0xd3770f('0x5c')]['id']}})[_0xd3770f('0xe')](handleEntityNotFound(_0x4c113c,null))[_0xd3770f('0xe')](function(_0x5ec591){const _0x267686=_0xd3770f;if(_0x5ec591)return _0x5ec591[_0x267686('0x63')](_0x23e55b['body'][_0x267686('0x35')],{'through':_[_0x267686('0x41')](_0x23e55b[_0x267686('0x1f')],[_0x267686('0x35'),'id'])});return null;})[_0xd3770f('0xe')](function(_0x2268d1){const _0x35bf8c=_0xd3770f;let _0x3df7fd;_0x3a84e5=_0x2268d1||[];const _0x2386ba=[];if(_0x2268d1){for(let _0x1cf54f=0x0;_0x1cf54f<_0x2268d1[_0x35bf8c('0x29')];_0x1cf54f+=0x1){const _0x4b1c76=_0x2268d1[_0x1cf54f][_0x35bf8c('0x1')]({'plain':!![]});_0x3df7fd=squel[_0x35bf8c('0x21')]()[_0x35bf8c('0x30')](_0x35bf8c('0x1b'))[_0x35bf8c('0x6e')]([_0x35bf8c('0x1a'),_0x35bf8c('0x10'),_0x35bf8c('0x54'),_0x35bf8c('0x23'),_0x35bf8c('0xa'),_0x35bf8c('0x9')],squel[_0x35bf8c('0x65')]()[_0x35bf8c('0x2b')](_0x35bf8c('0x1a'),'phone')['field']('id',_0x35bf8c('0x10'))[_0x35bf8c('0x2b')](_0x4b1c76['CmListId'][_0x35bf8c('0x15')](),'ListId')[_0x35bf8c('0x2b')](_0x23e55b[_0x35bf8c('0x5c')]['id']['toString'](),_0x35bf8c('0x23'))[_0x35bf8c('0x2b')](_0x35bf8c('0xb'),_0x35bf8c('0xa'))[_0x35bf8c('0x2b')](_0x35bf8c('0xb'),_0x35bf8c('0x9'))[_0x35bf8c('0x52')](_0x35bf8c('0x53'))[_0x35bf8c('0x2a')]('deletedAt\x20IS\x20NULL')['where'](_0x35bf8c('0x44'),_0x4b1c76[_0x35bf8c('0x24')][_0x35bf8c('0x15')]())[_0x35bf8c('0x2a')](_0x35bf8c('0x2d')))[_0x35bf8c('0x15')](),_0x2386ba[_0x35bf8c('0x5a')](db[_0x35bf8c('0x64')][_0x35bf8c('0x6d')](_0x3df7fd));}return Promise[_0x35bf8c('0x26')](_0x2386ba);}})[_0xd3770f('0xe')](function(){return _0x3a84e5;})['then'](respondWithResult(_0x4c113c,null))[_0xd3770f('0x5e')](handleError(_0x4c113c,null));},exports[_0x4ea7bb('0x20')]=function(_0x1da494,_0x879a){const _0x5d35aa=_0x4ea7bb;return db[_0x5d35aa('0x3d')]['findOne']({'where':{'id':_0x1da494[_0x5d35aa('0x5c')]['id']}})[_0x5d35aa('0xe')](handleEntityNotFound(_0x879a,null))[_0x5d35aa('0xe')](function(_0x3ac51a){const _0x1abd8c=_0x5d35aa;if(_0x3ac51a)return _0x3ac51a[_0x1abd8c('0x20')](_0x1da494[_0x1abd8c('0x6d')][_0x1abd8c('0x35')]);})[_0x5d35aa('0xe')](function(_0x30ffee){const _0x5ef224=_0x5d35aa;if(_0x30ffee)return db['CmHopperBlack'][_0x5ef224('0x3')]({'where':{'ListId':_0x1da494['query']['ids'],'CampaignId':_0x1da494[_0x5ef224('0x5c')]['id']}})[_0x5ef224('0xe')](function(){return _0x30ffee;});})[_0x5d35aa('0xe')](respondWithStatusCode(_0x879a,null))[_0x5d35aa('0x5e')](handleError(_0x879a,null));}; \ No newline at end of file +const a42_0x55dd=['removeLists','count','error','scheduledAt','rawAttributes','status','getBlackLists','Content-Range','NOW()','pick','catch','update','rows','api','addBlackLists','destroy','type','from','CmHopperFinal','dialCheckDuplicateType','findOne','query','../../config/logger','fromQuery','phone','map','role','CampaignId\x20=\x20?','limit','removeBlackLists','field','IvrCampaigns','getHoppers','body','lodash','ListId','fieldName','keys','UserProfileSection','cm_contacts','stack','push','getHopperHistories','includeAll','options','userProfileId','ContactId','where','like','cm_hopper_final','params','sequelize','fields','CampaignId','addLists','ids','findAll','squel','filters','Campaign','get','create','index','CmListId','VIRTUAL','then','end','sendStatus','json','UserProfileResource','model','phone\x20NOT\x20IN\x20(?)','ListId\x20=\x20?','CmHopper','CmList','createdAt','updatedAt','select','cm_hopper','send','COALESCE(phone,\x27\x27)','key','sort','insert','undefined','include','set','CmHopperBlack','Unable\x20to\x20retrieve\x20the\x20current\x20user','length','cm_hopper_black','filter','into','order','offset','phone\x20IS\x20NOT\x20NULL','show','CmHopperHistory','name','toString','all','omit','user','autoAssociation','attributes','merge','onlyIfOpen','nolimit','intersection','deletedAt\x20IS\x20NULL'];(function(_0x18bd29,_0x55dd92){const _0x239a7c=function(_0x567b39){while(--_0x567b39){_0x18bd29['push'](_0x18bd29['shift']());}};_0x239a7c(++_0x55dd92);}(a42_0x55dd,0x1c0));const a42_0x239a=function(_0x18bd29,_0x55dd92){_0x18bd29=_0x18bd29-0x0;let _0x239a7c=a42_0x55dd[_0x18bd29];return _0x239a7c;};const _0x5021dd=a42_0x239a;'use strict';const _=require(_0x5021dd('0x1a')),squel=require(_0x5021dd('0x31')),qs=require('../../components/parsers/qs'),logger=require(_0x5021dd('0xe'))(_0x5021dd('0x5')),db=require('../../mysqldb')['db'],{Op}=require('sequelize');function respondWithStatusCode(_0x567b39,_0x29e958){return _0x29e958=_0x29e958||0xcc,function(_0x18632d){if(_0x18632d)return _0x567b39['sendStatus'](_0x29e958);return _0x567b39['status'](_0x29e958)['end']();};}function respondWithResult(_0x5a53fe,_0x3dc460){return _0x3dc460=_0x3dc460||0xc8,function(_0x469049){const _0x54323d=a42_0x239a;if(_0x469049)return _0x5a53fe[_0x54323d('0x6b')](_0x3dc460)[_0x54323d('0x3c')](_0x469049);};}function respondWithFilteredResult(_0x2e2fa9,_0x207095){return function(_0x359319){const _0x27d6f0=a42_0x239a;if(_0x359319){const _0x3c6331=_0x359319[_0x27d6f0('0x67')],_0x4d7864=_0x207095['offset'];let _0x236bcc=_0x207095[_0x27d6f0('0x56')]+_0x207095[_0x27d6f0('0x14')],_0x5cb8f0;return _0x236bcc>=_0x3c6331?(_0x236bcc=_0x3c6331,_0x5cb8f0=0xc8):_0x5cb8f0=0xce,_0x2e2fa9['status'](_0x5cb8f0),_0x2e2fa9[_0x27d6f0('0x4e')](_0x27d6f0('0x6d'),_0x4d7864+'-'+_0x236bcc+'/'+_0x3c6331)[_0x27d6f0('0x3c')](_0x359319);}return null;};}function saveUpdates(_0x43ef10){return function(_0x30c5e9){const _0x16aeee=a42_0x239a;if(_0x30c5e9)return _0x30c5e9[_0x16aeee('0x3')](_0x43ef10)[_0x16aeee('0x39')](function(_0x5715bc){return _0x5715bc;});return null;};}function removeEntity(_0x5a1d7c){return function(_0x4df07c){const _0x3ee1a5=a42_0x239a;if(_0x4df07c)return _0x4df07c[_0x3ee1a5('0x7')]()[_0x3ee1a5('0x39')](function(){const _0x21c981=_0x3ee1a5,_0x5a65a3=_0x4df07c[_0x21c981('0x34')]({'plain':!![]}),_0xfb99c1=_0x21c981('0x17');return db[_0x21c981('0x3d')][_0x21c981('0x7')]({'where':{'type':_0xfb99c1,'resourceId':_0x5a65a3['id']}})[_0x21c981('0x39')](function(){return _0x4df07c;});})[_0x3ee1a5('0x39')](function(){const _0x3dded8=_0x3ee1a5;_0x5a1d7c[_0x3dded8('0x6b')](0xcc)[_0x3dded8('0x3a')]();});};}function handleEntityNotFound(_0x328f33){return function(_0x581413){const _0x5a8828=a42_0x239a;return!_0x581413&&_0x328f33[_0x5a8828('0x3b')](0x194),_0x581413;};}function handleError(_0x2f41dd,_0x2d3bc7){return _0x2d3bc7=_0x2d3bc7||0x1f4,function(_0x2c3b2b){const _0x5b0bda=a42_0x239a;logger[_0x5b0bda('0x68')](_0x2c3b2b[_0x5b0bda('0x20')]),_0x2c3b2b['name']&&delete _0x2c3b2b[_0x5b0bda('0x5a')],_0x2f41dd[_0x5b0bda('0x6b')](_0x2d3bc7)[_0x5b0bda('0x47')](_0x2c3b2b);};}exports[_0x5021dd('0x36')]=function(_0x26aca8,_0x5aaefe){const _0x552d2b=_0x5021dd;let _0x57a158={};const _0x50de8b={},_0x1d45ed={'count':0x0,'rows':[]},_0x13ecad=_[_0x552d2b('0x11')](db[_0x552d2b('0x33')][_0x552d2b('0x6a')],function(_0x16f180){const _0x264f7f=_0x552d2b;return{'name':_0x16f180[_0x264f7f('0x1c')],'type':_0x16f180[_0x264f7f('0x8')][_0x264f7f('0x49')]};});_0x50de8b[_0x552d2b('0x3e')]=_['map'](_0x13ecad,_0x552d2b('0x5a')),_0x50de8b[_0x552d2b('0xd')]=_[_0x552d2b('0x1d')](_0x26aca8[_0x552d2b('0xd')]),_0x50de8b[_0x552d2b('0x32')]=_[_0x552d2b('0x64')](_0x50de8b[_0x552d2b('0x3e')],_0x50de8b[_0x552d2b('0xd')]),_0x57a158['attributes']=_[_0x552d2b('0x64')](_0x50de8b[_0x552d2b('0x3e')],qs[_0x552d2b('0x2c')](_0x26aca8[_0x552d2b('0xd')][_0x552d2b('0x2c')])),_0x57a158[_0x552d2b('0x60')]=_0x57a158[_0x552d2b('0x60')][_0x552d2b('0x51')]?_0x57a158[_0x552d2b('0x60')]:_0x50de8b[_0x552d2b('0x3e')];typeof _0x26aca8[_0x552d2b('0xd')]['nolimit']===_0x552d2b('0x4c')&&(_0x57a158[_0x552d2b('0x14')]=qs['limit'](_0x26aca8[_0x552d2b('0xd')][_0x552d2b('0x14')]),_0x57a158[_0x552d2b('0x56')]=qs[_0x552d2b('0x56')](_0x26aca8[_0x552d2b('0xd')][_0x552d2b('0x56')]));_0x57a158['order']=qs[_0x552d2b('0x4a')](_0x26aca8['query']['sort']),_0x57a158[_0x552d2b('0x27')]=qs[_0x552d2b('0x32')](_[_0x552d2b('0x1')](_0x26aca8[_0x552d2b('0xd')],_0x50de8b[_0x552d2b('0x32')]),_0x13ecad);_0x26aca8[_0x552d2b('0xd')][_0x552d2b('0x53')]&&(_0x57a158['where']=_['merge'](_0x57a158[_0x552d2b('0x27')],{[Op['or']]:_['map'](_0x13ecad,function(_0xb59881){const _0x1eb63f=_0x552d2b;if(_0xb59881[_0x1eb63f('0x8')]!==_0x1eb63f('0x38')){const _0x1adaaf={};return _0x1adaaf[_0xb59881['name']]={[Op[_0x1eb63f('0x28')]]:'%'+_0x26aca8[_0x1eb63f('0xd')][_0x1eb63f('0x53')]+'%'},_0x1adaaf;}})}));_0x57a158=_[_0x552d2b('0x61')]({},_0x57a158,_0x26aca8[_0x552d2b('0x24')]);const _0x4340e0={'where':_0x57a158['where']};return db[_0x552d2b('0x33')][_0x552d2b('0x67')](_0x4340e0)[_0x552d2b('0x39')](function(_0x3250a0){const _0x47653a=_0x552d2b;return _0x1d45ed[_0x47653a('0x67')]=_0x3250a0,_0x26aca8[_0x47653a('0xd')][_0x47653a('0x23')]&&(_0x57a158[_0x47653a('0x4d')]=[{'all':!![]}]),db[_0x47653a('0x33')]['findAll'](_0x57a158);})[_0x552d2b('0x39')](function(_0x4effac){return _0x1d45ed['rows']=_0x4effac,_0x1d45ed;})[_0x552d2b('0x39')](respondWithFilteredResult(_0x5aaefe,_0x57a158))['catch'](handleError(_0x5aaefe,null));},exports[_0x5021dd('0x58')]=function(_0x3a7754,_0x375dca){const _0x14ca62=_0x5021dd;let _0x408a75={'raw':![],'where':{'id':_0x3a7754[_0x14ca62('0x2a')]['id']}};const _0x1b693a={};return _0x1b693a['model']=_[_0x14ca62('0x1d')](db[_0x14ca62('0x33')]['rawAttributes']),_0x1b693a[_0x14ca62('0xd')]=_[_0x14ca62('0x1d')](_0x3a7754[_0x14ca62('0xd')]),_0x1b693a[_0x14ca62('0x32')]=_[_0x14ca62('0x64')](_0x1b693a[_0x14ca62('0x3e')],_0x1b693a['query']),_0x408a75[_0x14ca62('0x60')]=_['intersection'](_0x1b693a[_0x14ca62('0x3e')],qs[_0x14ca62('0x2c')](_0x3a7754['query'][_0x14ca62('0x2c')])),_0x408a75[_0x14ca62('0x60')]=_0x408a75[_0x14ca62('0x60')]['length']?_0x408a75[_0x14ca62('0x60')]:_0x1b693a[_0x14ca62('0x3e')],_0x3a7754[_0x14ca62('0xd')][_0x14ca62('0x23')]&&(_0x408a75[_0x14ca62('0x4d')]=[{'all':!![]}]),_0x408a75=_[_0x14ca62('0x61')]({},_0x408a75,_0x3a7754[_0x14ca62('0x24')]),db[_0x14ca62('0x33')][_0x14ca62('0xc')](_0x408a75)['then'](handleEntityNotFound(_0x375dca,null))[_0x14ca62('0x39')](respondWithResult(_0x375dca,null))[_0x14ca62('0x2')](handleError(_0x375dca,null));},exports[_0x5021dd('0x35')]=function(_0x21a5bc,_0x43803a){const _0x234c15=_0x5021dd;return db['Campaign']['create'](_0x21a5bc['body'],{})['then'](function(_0x236cb0){const _0xf558ee=a42_0x239a,_0x329b5e=_0x21a5bc[_0xf558ee('0x5e')]['get']({'plain':!![]});if(!_0x329b5e)throw new Error(_0xf558ee('0x50'));if(_0x329b5e[_0xf558ee('0x12')]===_0xf558ee('0x5e')){const _0x3be531=_0x236cb0[_0xf558ee('0x34')]({'plain':!![]}),_0x24f314=_0xf558ee('0x17');return db['UserProfileSection'][_0xf558ee('0xc')]({'where':{'name':_0x24f314,'userProfileId':_0x329b5e[_0xf558ee('0x25')]},'raw':!![]})[_0xf558ee('0x39')](function(_0x28ac5e){const _0x235a25=_0xf558ee;return _0x28ac5e&&_0x28ac5e['autoAssociation']===0x0?db[_0x235a25('0x3d')][_0x235a25('0x35')]({'name':_0x3be531[_0x235a25('0x5a')],'resourceId':_0x3be531['id'],'type':_0x28ac5e[_0x235a25('0x5a')],'sectionId':_0x28ac5e['id']},{})[_0x235a25('0x39')](function(){return _0x236cb0;}):_0x236cb0;})[_0xf558ee('0x2')](function(_0x1bda96){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x1bda96);throw _0x1bda96;});}return _0x236cb0;})[_0x234c15('0x39')](respondWithResult(_0x43803a,0xc9))[_0x234c15('0x2')](handleError(_0x43803a,null));},exports['clone']=function(_0x4b540f,_0x316d86){const _0x62d528=_0x5021dd;let _0x2ccaf7={'where':{'id':_0x4b540f[_0x62d528('0x2a')]['id']}};const _0x864721={};return _0x864721[_0x62d528('0x3e')]=_[_0x62d528('0x1d')](db[_0x62d528('0x33')][_0x62d528('0x6a')]),_0x2ccaf7[_0x62d528('0x60')]=_['intersection'](_0x864721['model'],qs['fields'](_0x4b540f[_0x62d528('0xd')][_0x62d528('0x2c')])),_0x2ccaf7[_0x62d528('0x60')]=_0x2ccaf7[_0x62d528('0x60')][_0x62d528('0x51')]?_0x2ccaf7[_0x62d528('0x60')]:_0x864721[_0x62d528('0x3e')],_0x4b540f['query'][_0x62d528('0x23')]&&(_0x2ccaf7[_0x62d528('0x4d')]=[{'all':!![]}]),_0x2ccaf7=_[_0x62d528('0x61')]({},_0x2ccaf7,_0x4b540f[_0x62d528('0x24')]),db[_0x62d528('0x33')][_0x62d528('0xc')](_0x2ccaf7)['then'](handleEntityNotFound(_0x316d86,null))['then'](function(_0x4aeed2){const _0x501922=_0x62d528;if(_0x4aeed2){let _0xecc653=_0x4aeed2[_0x501922('0x34')]({'plain':!![]});return _0xecc653=qs[_0x501922('0x5d')](_0xecc653,['id','createdAt',_0x501922('0x44')]),_0x4b540f[_0x501922('0x19')]=_[_0x501922('0x5d')](_0x4b540f[_0x501922('0x19')],['id',_0x501922('0x43'),'updatedAt']),db[_0x501922('0x33')][_0x501922('0x35')](_[_0x501922('0x61')](_0xecc653,_0x4b540f[_0x501922('0x19')]),{'include':_0x4b540f['query']['includeAll']?[{'all':!![]}]:undefined})[_0x501922('0x39')](function(_0x1601c3){const _0x1800c7=_0x501922,_0x4ae3a8=_0x4b540f[_0x1800c7('0x5e')][_0x1800c7('0x34')]({'plain':!![]});if(!_0x4ae3a8)throw new Error(_0x1800c7('0x50'));if(_0x4ae3a8['role']===_0x1800c7('0x5e')){const _0x20c620=_0x1601c3['get']({'plain':!![]}),_0x18de09=_0x1800c7('0x17');return db[_0x1800c7('0x1e')]['findOne']({'where':{'name':_0x18de09,'userProfileId':_0x4ae3a8[_0x1800c7('0x25')]},'raw':!![]})[_0x1800c7('0x39')](function(_0x449c36){const _0x3d2091=_0x1800c7;return _0x449c36&&_0x449c36[_0x3d2091('0x5f')]===0x0?db[_0x3d2091('0x3d')][_0x3d2091('0x35')]({'name':_0x20c620['name'],'resourceId':_0x20c620['id'],'type':_0x449c36[_0x3d2091('0x5a')],'sectionId':_0x449c36['id']},{})[_0x3d2091('0x39')](function(){return _0x1601c3;}):_0x1601c3;})[_0x1800c7('0x2')](function(_0x5ef27d){const _0x2a9f7e=_0x1800c7;logger[_0x2a9f7e('0x68')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x5ef27d);throw _0x5ef27d;});}return _0x1601c3;});}})[_0x62d528('0x39')](respondWithResult(_0x316d86,0xc9))[_0x62d528('0x2')](handleError(_0x316d86,null));},exports['update']=function(_0x3250e7,_0x1d816a){const _0x55cfcb=_0x5021dd;return _0x3250e7['body']['id']&&delete _0x3250e7[_0x55cfcb('0x19')]['id'],db[_0x55cfcb('0x33')][_0x55cfcb('0xc')]({'where':{'id':_0x3250e7[_0x55cfcb('0x2a')]['id']}})[_0x55cfcb('0x39')](handleEntityNotFound(_0x1d816a,null))['then'](saveUpdates(_0x3250e7[_0x55cfcb('0x19')],null))['then'](respondWithResult(_0x1d816a,null))[_0x55cfcb('0x2')](handleError(_0x1d816a,null));},exports['destroy']=function(_0x5e0274,_0x542b57){const _0x31c53c=_0x5021dd;return db[_0x31c53c('0x33')]['findOne']({'where':{'id':_0x5e0274[_0x31c53c('0x2a')]['id']}})[_0x31c53c('0x39')](handleEntityNotFound(_0x542b57,null))[_0x31c53c('0x39')](removeEntity(_0x542b57,null))[_0x31c53c('0x2')](handleError(_0x542b57,null));},exports[_0x5021dd('0x18')]=function(_0x47c483,_0x374769){const _0x2dd64e=_0x5021dd;let _0x4d836d={'raw':!![],'where':{}};const _0x422cef={},_0x25b180={'count':0x0,'rows':[]};return db['Campaign'][_0x2dd64e('0xc')]({'where':{'id':_0x47c483[_0x2dd64e('0x2a')]['id']}})[_0x2dd64e('0x39')](handleEntityNotFound(_0x374769,null))[_0x2dd64e('0x39')](function(_0x11a5d0){const _0x20820f=_0x2dd64e;if(_0x11a5d0)return _0x422cef['model']=_[_0x20820f('0x1d')](db[_0x20820f('0x41')]['rawAttributes']),_0x422cef[_0x20820f('0xd')]=_['keys'](_0x47c483['query']),_0x422cef[_0x20820f('0x32')]=_['intersection'](_0x422cef[_0x20820f('0x3e')],_0x422cef[_0x20820f('0xd')]),_0x4d836d[_0x20820f('0x60')]=_['intersection'](_0x422cef['model'],qs[_0x20820f('0x2c')](_0x47c483['query'][_0x20820f('0x2c')])),_0x4d836d['attributes']=_0x4d836d[_0x20820f('0x60')][_0x20820f('0x51')]?_0x4d836d[_0x20820f('0x60')]:_0x422cef['model'],typeof _0x47c483[_0x20820f('0xd')][_0x20820f('0x63')]===_0x20820f('0x4c')&&(_0x4d836d[_0x20820f('0x14')]=qs[_0x20820f('0x14')](_0x47c483[_0x20820f('0xd')][_0x20820f('0x14')]),_0x4d836d['offset']=qs[_0x20820f('0x56')](_0x47c483[_0x20820f('0xd')][_0x20820f('0x56')])),_0x4d836d[_0x20820f('0x55')]=qs['sort'](_0x47c483[_0x20820f('0xd')][_0x20820f('0x4a')]),_0x4d836d[_0x20820f('0x27')]=qs[_0x20820f('0x32')](_['pick'](_0x47c483['query'],_0x422cef[_0x20820f('0x32')])),_0x4d836d['where'][_0x20820f('0x2d')]=_0x11a5d0['id'],_0x47c483['query']['filter']&&(_0x4d836d[_0x20820f('0x27')]=_[_0x20820f('0x61')](_0x4d836d[_0x20820f('0x27')],{[Op['or']]:_[_0x20820f('0x11')](_0x4d836d['attributes'],function(_0x20533e){const _0x450655=_0x20820f,_0x49660c={};return _0x49660c[_0x20533e]={[Op['like']]:'%'+_0x47c483[_0x450655('0xd')]['filter']+'%'},_0x49660c;})})),_0x4d836d=_['merge']({},_0x4d836d,_0x47c483[_0x20820f('0x24')]),db['CmHopper']['count']({'where':_0x4d836d[_0x20820f('0x27')]})[_0x20820f('0x39')](function(_0x5dc11d){const _0x139f60=_0x20820f;return _0x25b180[_0x139f60('0x67')]=_0x5dc11d,_0x47c483[_0x139f60('0xd')][_0x139f60('0x23')]&&(_0x4d836d[_0x139f60('0x4d')]=[{'all':!![]}]),db[_0x139f60('0x41')][_0x139f60('0x30')](_0x4d836d);})[_0x20820f('0x39')](function(_0x1935f5){const _0x4d201d=_0x20820f;return _0x25b180[_0x4d201d('0x4')]=_0x1935f5,_0x25b180;});})[_0x2dd64e('0x39')](respondWithFilteredResult(_0x374769,_0x4d836d))[_0x2dd64e('0x2')](handleError(_0x374769,null));},exports[_0x5021dd('0x22')]=function(_0x2fb4b0,_0x3a52eb){const _0x4c767c=_0x5021dd;let _0x45332d={'raw':!![],'where':{}};const _0x4f39e1={},_0x369897={'count':0x0,'rows':[]};return db[_0x4c767c('0x33')][_0x4c767c('0xc')]({'where':{'id':_0x2fb4b0['params']['id']}})['then'](handleEntityNotFound(_0x3a52eb,null))[_0x4c767c('0x39')](function(_0x3a3bc3){const _0x48aa7b=_0x4c767c;if(_0x3a3bc3)return _0x4f39e1[_0x48aa7b('0x3e')]=_['keys'](db['CmHopperHistory'][_0x48aa7b('0x6a')]),_0x4f39e1[_0x48aa7b('0xd')]=_[_0x48aa7b('0x1d')](_0x2fb4b0[_0x48aa7b('0xd')]),_0x4f39e1[_0x48aa7b('0x32')]=_['intersection'](_0x4f39e1['model'],_0x4f39e1[_0x48aa7b('0xd')]),_0x45332d['attributes']=_[_0x48aa7b('0x64')](_0x4f39e1['model'],qs[_0x48aa7b('0x2c')](_0x2fb4b0[_0x48aa7b('0xd')][_0x48aa7b('0x2c')])),_0x45332d['attributes']=_0x45332d[_0x48aa7b('0x60')]['length']?_0x45332d[_0x48aa7b('0x60')]:_0x4f39e1[_0x48aa7b('0x3e')],typeof _0x2fb4b0[_0x48aa7b('0xd')][_0x48aa7b('0x63')]===_0x48aa7b('0x4c')&&(_0x45332d[_0x48aa7b('0x14')]=qs[_0x48aa7b('0x14')](_0x2fb4b0['query'][_0x48aa7b('0x14')]),_0x45332d[_0x48aa7b('0x56')]=qs[_0x48aa7b('0x56')](_0x2fb4b0['query'][_0x48aa7b('0x56')])),_0x45332d[_0x48aa7b('0x55')]=qs[_0x48aa7b('0x4a')](_0x2fb4b0[_0x48aa7b('0xd')]['sort']),_0x45332d[_0x48aa7b('0x27')]=qs[_0x48aa7b('0x32')](_[_0x48aa7b('0x1')](_0x2fb4b0['query'],_0x4f39e1[_0x48aa7b('0x32')])),_0x45332d[_0x48aa7b('0x27')][_0x48aa7b('0x2d')]=_0x3a3bc3['id'],_0x2fb4b0['query'][_0x48aa7b('0x53')]&&(_0x45332d[_0x48aa7b('0x27')]=_['merge'](_0x45332d['where'],{[Op['or']]:_[_0x48aa7b('0x11')](_0x45332d[_0x48aa7b('0x60')],function(_0x1d4860){const _0x22503f=_0x48aa7b,_0x3be380={};return _0x3be380[_0x1d4860]={[Op[_0x22503f('0x28')]]:'%'+_0x2fb4b0[_0x22503f('0xd')]['filter']+'%'},_0x3be380;})})),_0x45332d=_[_0x48aa7b('0x61')]({},_0x45332d,_0x2fb4b0[_0x48aa7b('0x24')]),db[_0x48aa7b('0x59')][_0x48aa7b('0x67')]({'where':_0x45332d['where']})[_0x48aa7b('0x39')](function(_0x98ec4f){const _0x10f0f8=_0x48aa7b;return _0x369897[_0x10f0f8('0x67')]=_0x98ec4f,_0x2fb4b0['query'][_0x10f0f8('0x23')]&&(_0x45332d[_0x10f0f8('0x4d')]=[{'all':!![]}]),db[_0x10f0f8('0x59')]['findAll'](_0x45332d);})[_0x48aa7b('0x39')](function(_0x5901c8){const _0x416c47=_0x48aa7b;return _0x369897[_0x416c47('0x4')]=_0x5901c8,_0x369897;});})[_0x4c767c('0x39')](respondWithFilteredResult(_0x3a52eb,_0x45332d))['catch'](handleError(_0x3a52eb,null));},exports['getHopperFinals']=function(_0xf4eb50,_0x56bf44){const _0x515d12=_0x5021dd;let _0x1c7fb6={'raw':!![],'where':{}};const _0x3c9256={},_0x3340bc={'count':0x0,'rows':[]};return db[_0x515d12('0x33')][_0x515d12('0xc')]({'where':{'id':_0xf4eb50[_0x515d12('0x2a')]['id']}})[_0x515d12('0x39')](handleEntityNotFound(_0x56bf44,null))['then'](function(_0x21e67a){const _0x27a052=_0x515d12;if(_0x21e67a)return _0x3c9256[_0x27a052('0x3e')]=_[_0x27a052('0x1d')](db[_0x27a052('0xa')][_0x27a052('0x6a')]),_0x3c9256[_0x27a052('0xd')]=_[_0x27a052('0x1d')](_0xf4eb50['query']),_0x3c9256['filters']=_[_0x27a052('0x64')](_0x3c9256[_0x27a052('0x3e')],_0x3c9256[_0x27a052('0xd')]),_0x1c7fb6[_0x27a052('0x60')]=_['intersection'](_0x3c9256[_0x27a052('0x3e')],qs[_0x27a052('0x2c')](_0xf4eb50[_0x27a052('0xd')]['fields'])),_0x1c7fb6[_0x27a052('0x60')]=_0x1c7fb6[_0x27a052('0x60')][_0x27a052('0x51')]?_0x1c7fb6[_0x27a052('0x60')]:_0x3c9256['model'],typeof _0xf4eb50[_0x27a052('0xd')][_0x27a052('0x63')]==='undefined'&&(_0x1c7fb6[_0x27a052('0x14')]=qs[_0x27a052('0x14')](_0xf4eb50['query'][_0x27a052('0x14')]),_0x1c7fb6[_0x27a052('0x56')]=qs['offset'](_0xf4eb50[_0x27a052('0xd')][_0x27a052('0x56')])),_0x1c7fb6[_0x27a052('0x55')]=qs[_0x27a052('0x4a')](_0xf4eb50[_0x27a052('0xd')][_0x27a052('0x4a')]),_0x1c7fb6['where']=qs[_0x27a052('0x32')](_[_0x27a052('0x1')](_0xf4eb50['query'],_0x3c9256[_0x27a052('0x32')])),_0x1c7fb6[_0x27a052('0x27')][_0x27a052('0x2d')]=_0x21e67a['id'],_0xf4eb50[_0x27a052('0xd')][_0x27a052('0x53')]&&(_0x1c7fb6['where']=_[_0x27a052('0x61')](_0x1c7fb6[_0x27a052('0x27')],{[Op['or']]:_[_0x27a052('0x11')](_0x1c7fb6[_0x27a052('0x60')],function(_0x49478f){const _0x349d9f=_0x27a052,_0x262ca6={};return _0x262ca6[_0x49478f]={[Op[_0x349d9f('0x28')]]:'%'+_0xf4eb50[_0x349d9f('0xd')][_0x349d9f('0x53')]+'%'},_0x262ca6;})})),_0x1c7fb6=_[_0x27a052('0x61')]({},_0x1c7fb6,_0xf4eb50[_0x27a052('0x24')]),db[_0x27a052('0xa')]['count']({'where':_0x1c7fb6[_0x27a052('0x27')]})['then'](function(_0x4cb1a2){const _0x405093=_0x27a052;return _0x3340bc[_0x405093('0x67')]=_0x4cb1a2,_0xf4eb50[_0x405093('0xd')]['includeAll']&&(_0x1c7fb6[_0x405093('0x4d')]=[{'all':!![]}]),db[_0x405093('0xa')][_0x405093('0x30')](_0x1c7fb6);})[_0x27a052('0x39')](function(_0x417cf6){const _0x440431=_0x27a052;return _0x3340bc[_0x440431('0x4')]=_0x417cf6,_0x3340bc;});})['then'](respondWithFilteredResult(_0x56bf44,_0x1c7fb6))[_0x515d12('0x2')](handleError(_0x56bf44,null));},exports['getHopperBlacks']=function(_0x6fb121,_0x27d14d){const _0x3b3e94=_0x5021dd;let _0x26b749={'raw':!![],'where':{}};const _0x3348fe={},_0xd76064={'count':0x0,'rows':[]};return db[_0x3b3e94('0x33')][_0x3b3e94('0xc')]({'where':{'id':_0x6fb121['params']['id']}})['then'](handleEntityNotFound(_0x27d14d,null))['then'](function(_0x309d2c){const _0x4161aa=_0x3b3e94;if(_0x309d2c)return _0x3348fe[_0x4161aa('0x3e')]=_[_0x4161aa('0x1d')](db['CmHopperBlack'][_0x4161aa('0x6a')]),_0x3348fe[_0x4161aa('0xd')]=_['keys'](_0x6fb121['query']),_0x3348fe['filters']=_[_0x4161aa('0x64')](_0x3348fe[_0x4161aa('0x3e')],_0x3348fe[_0x4161aa('0xd')]),_0x26b749['attributes']=_['intersection'](_0x3348fe['model'],qs[_0x4161aa('0x2c')](_0x6fb121[_0x4161aa('0xd')][_0x4161aa('0x2c')])),_0x26b749[_0x4161aa('0x60')]=_0x26b749[_0x4161aa('0x60')]['length']?_0x26b749[_0x4161aa('0x60')]:_0x3348fe[_0x4161aa('0x3e')],typeof _0x6fb121[_0x4161aa('0xd')]['nolimit']==='undefined'&&(_0x26b749['limit']=qs[_0x4161aa('0x14')](_0x6fb121[_0x4161aa('0xd')]['limit']),_0x26b749['offset']=qs[_0x4161aa('0x56')](_0x6fb121[_0x4161aa('0xd')][_0x4161aa('0x56')])),_0x26b749['order']=qs[_0x4161aa('0x4a')](_0x6fb121[_0x4161aa('0xd')][_0x4161aa('0x4a')]),_0x26b749['where']=qs[_0x4161aa('0x32')](_[_0x4161aa('0x1')](_0x6fb121[_0x4161aa('0xd')],_0x3348fe['filters'])),_0x26b749['where'][_0x4161aa('0x2d')]=_0x309d2c['id'],_0x6fb121[_0x4161aa('0xd')]['filter']&&(_0x26b749[_0x4161aa('0x27')]=_[_0x4161aa('0x61')](_0x26b749[_0x4161aa('0x27')],{[Op['or']]:_[_0x4161aa('0x11')](_0x26b749['attributes'],function(_0x505cb2){const _0x2e8a19=_0x4161aa,_0x422911={};return _0x422911[_0x505cb2]={[Op['like']]:'%'+_0x6fb121[_0x2e8a19('0xd')]['filter']+'%'},_0x422911;})})),_0x26b749=_[_0x4161aa('0x61')]({},_0x26b749,_0x6fb121[_0x4161aa('0x24')]),db[_0x4161aa('0x4f')][_0x4161aa('0x67')]({'where':_0x26b749['where']})['then'](function(_0x3fb41d){const _0x14433b=_0x4161aa;return _0xd76064[_0x14433b('0x67')]=_0x3fb41d,_0x6fb121['query'][_0x14433b('0x23')]&&(_0x26b749[_0x14433b('0x4d')]=[{'all':!![]}]),db['CmHopperBlack'][_0x14433b('0x30')](_0x26b749);})[_0x4161aa('0x39')](function(_0x2471b8){const _0x28ca57=_0x4161aa;return _0xd76064[_0x28ca57('0x4')]=_0x2471b8,_0xd76064;});})[_0x3b3e94('0x39')](respondWithFilteredResult(_0x27d14d,_0x26b749))[_0x3b3e94('0x2')](handleError(_0x27d14d,null));},exports['getLists']=function(_0xd15f3e,_0x20ddb1){const _0x21b5af=_0x5021dd;let _0x1d5625={};const _0x36f7f2={};let _0x34c4ab,_0x1ba5d8;return db['Campaign']['findOne']({'where':{'id':_0xd15f3e[_0x21b5af('0x2a')]['id']}})['then'](handleEntityNotFound(_0x20ddb1,null))[_0x21b5af('0x39')](function(_0x5bce91){const _0x37ecde=_0x21b5af;if(_0x5bce91)return _0x34c4ab=_0x5bce91,_0x36f7f2[_0x37ecde('0x3e')]=_[_0x37ecde('0x1d')](db[_0x37ecde('0x42')]['rawAttributes']),_0x36f7f2['query']=_['keys'](_0xd15f3e[_0x37ecde('0xd')]),_0x36f7f2[_0x37ecde('0x32')]=_['intersection'](_0x36f7f2[_0x37ecde('0x3e')],_0x36f7f2[_0x37ecde('0xd')]),_0x1d5625[_0x37ecde('0x60')]=_['intersection'](_0x36f7f2[_0x37ecde('0x3e')],qs['fields'](_0xd15f3e['query']['fields'])),_0x1d5625[_0x37ecde('0x60')]=_0x1d5625[_0x37ecde('0x60')]['length']?_0x1d5625[_0x37ecde('0x60')]:_0x36f7f2['model'],_0x1d5625['order']=qs[_0x37ecde('0x4a')](_0xd15f3e[_0x37ecde('0xd')][_0x37ecde('0x4a')]),_0x1d5625['where']=qs['filters'](_[_0x37ecde('0x1')](_0xd15f3e[_0x37ecde('0xd')],_0x36f7f2[_0x37ecde('0x32')])),_0xd15f3e[_0x37ecde('0xd')][_0x37ecde('0x53')]&&(_0x1d5625[_0x37ecde('0x27')]=_['merge'](_0x1d5625[_0x37ecde('0x27')],{[Op['or']]:_[_0x37ecde('0x11')](_0x1d5625[_0x37ecde('0x60')],function(_0x347eb1){const _0x8511c5=_0x37ecde,_0x5e7441={};return _0x5e7441[_0x347eb1]={[Op[_0x8511c5('0x28')]]:'%'+_0xd15f3e['query'][_0x8511c5('0x53')]+'%'},_0x5e7441;})})),_0x1d5625=_[_0x37ecde('0x61')]({},_0x1d5625,_0xd15f3e[_0x37ecde('0x24')]),_0x34c4ab['getLists'](_0x1d5625);})[_0x21b5af('0x39')](function(_0x91fdcc){const _0x2913bf=_0x21b5af;if(_0x91fdcc)return _0x1ba5d8=_0x91fdcc['length'],typeof _0xd15f3e[_0x2913bf('0xd')]['nolimit']===_0x2913bf('0x4c')&&(_0x1d5625[_0x2913bf('0x14')]=qs[_0x2913bf('0x14')](_0xd15f3e[_0x2913bf('0xd')][_0x2913bf('0x14')]),_0x1d5625[_0x2913bf('0x56')]=qs[_0x2913bf('0x56')](_0xd15f3e['query'][_0x2913bf('0x56')])),_0x34c4ab['getLists'](_0x1d5625);})['then'](function(_0x254827){if(_0x254827)return _0x254827?{'count':_0x1ba5d8,'rows':_0x254827}:null;})[_0x21b5af('0x39')](respondWithResult(_0x20ddb1,null))[_0x21b5af('0x2')](handleError(_0x20ddb1,null));},exports[_0x5021dd('0x2e')]=function(_0x33c423,_0x40d67b){const _0x171978=_0x5021dd;let _0x495173,_0x1e3f5d;return db[_0x171978('0x33')][_0x171978('0xc')]({'where':{'id':_0x33c423[_0x171978('0x2a')]['id']}})[_0x171978('0x39')](handleEntityNotFound(_0x40d67b,null))['then'](function(_0xa93a94){const _0x291628=_0x171978;if(_0xa93a94)return _0x1e3f5d=_0xa93a94,_0xa93a94[_0x291628('0x2e')](_0x33c423[_0x291628('0x19')][_0x291628('0x2f')],{'through':_['omit'](_0x33c423['body'],[_0x291628('0x2f'),'id'])});return null;})[_0x171978('0x39')](function(_0x2853ef){const _0x2c9eb6=_0x171978;let _0xc86a85;_0x495173=_0x2853ef||[];const _0x276570=[];if(_0x2853ef){for(let _0x2a022d=0x0;_0x2a022d<_0x2853ef['length'];_0x2a022d+=0x1){const _0x50fba3=_0x2853ef[_0x2a022d][_0x2c9eb6('0x34')]({'plain':!![]});_0x1e3f5d[_0x2c9eb6('0xb')]=_0x33c423[_0x2c9eb6('0x19')]['dialCheckDuplicateType']?_0x33c423['body'][_0x2c9eb6('0xb')]:_0x1e3f5d[_0x2c9eb6('0xb')];switch(_0x1e3f5d[_0x2c9eb6('0xb')]){case'always':_0xc86a85=squel[_0x2c9eb6('0x4b')]()[_0x2c9eb6('0x54')](_0x2c9eb6('0x46'))[_0x2c9eb6('0xf')]([_0x2c9eb6('0x10'),_0x2c9eb6('0x69'),_0x2c9eb6('0x26'),_0x2c9eb6('0x1b'),_0x2c9eb6('0x2d'),_0x2c9eb6('0x43'),_0x2c9eb6('0x44')],squel[_0x2c9eb6('0x45')]()[_0x2c9eb6('0x16')](_0x2c9eb6('0x10'),_0x2c9eb6('0x10'))[_0x2c9eb6('0x16')](_0x2c9eb6('0x0'),'scheduledAt')[_0x2c9eb6('0x16')]('id','ContactId')[_0x2c9eb6('0x16')](_0x50fba3[_0x2c9eb6('0x37')][_0x2c9eb6('0x5b')](),_0x2c9eb6('0x1b'))['field'](_0x33c423[_0x2c9eb6('0x2a')]['id'][_0x2c9eb6('0x5b')](),_0x2c9eb6('0x2d'))['field'](_0x2c9eb6('0x0'),_0x2c9eb6('0x43'))['field'](_0x2c9eb6('0x0'),_0x2c9eb6('0x44'))[_0x2c9eb6('0x9')](_0x2c9eb6('0x1f'))[_0x2c9eb6('0x27')](_0x2c9eb6('0x65'))[_0x2c9eb6('0x27')](_0x2c9eb6('0x40'),_0x50fba3[_0x2c9eb6('0x37')]['toString']())[_0x2c9eb6('0x27')](_0x2c9eb6('0x57'))[_0x2c9eb6('0x27')](_0x2c9eb6('0x3f'),squel['select']()[_0x2c9eb6('0x16')]('COALESCE(calleridnum,\x27\x27)')[_0x2c9eb6('0x9')](_0x2c9eb6('0x29'))[_0x2c9eb6('0x27')](_0x2c9eb6('0x13'),_0x33c423[_0x2c9eb6('0x2a')]['id'][_0x2c9eb6('0x5b')]()))[_0x2c9eb6('0x27')](_0x2c9eb6('0x3f'),squel[_0x2c9eb6('0x45')]()[_0x2c9eb6('0x16')](_0x2c9eb6('0x48'))[_0x2c9eb6('0x9')](_0x2c9eb6('0x46'))['where'](_0x2c9eb6('0x13'),_0x33c423[_0x2c9eb6('0x2a')]['id'][_0x2c9eb6('0x5b')]())))[_0x2c9eb6('0x5b')]();break;case _0x2c9eb6('0x62'):_0xc86a85=squel['insert']()[_0x2c9eb6('0x54')](_0x2c9eb6('0x46'))['fromQuery']([_0x2c9eb6('0x10'),'scheduledAt',_0x2c9eb6('0x26'),_0x2c9eb6('0x1b'),_0x2c9eb6('0x2d'),'createdAt','updatedAt'],squel[_0x2c9eb6('0x45')]()[_0x2c9eb6('0x16')](_0x2c9eb6('0x10'),_0x2c9eb6('0x10'))[_0x2c9eb6('0x16')](_0x2c9eb6('0x0'),_0x2c9eb6('0x69'))['field']('id',_0x2c9eb6('0x26'))[_0x2c9eb6('0x16')](_0x50fba3['CmListId'][_0x2c9eb6('0x5b')](),_0x2c9eb6('0x1b'))[_0x2c9eb6('0x16')](_0x33c423[_0x2c9eb6('0x2a')]['id'][_0x2c9eb6('0x5b')](),_0x2c9eb6('0x2d'))['field'](_0x2c9eb6('0x0'),'createdAt')[_0x2c9eb6('0x16')](_0x2c9eb6('0x0'),_0x2c9eb6('0x44'))[_0x2c9eb6('0x9')](_0x2c9eb6('0x1f'))[_0x2c9eb6('0x27')](_0x2c9eb6('0x65'))[_0x2c9eb6('0x27')](_0x2c9eb6('0x40'),_0x50fba3[_0x2c9eb6('0x37')]['toString']())[_0x2c9eb6('0x27')]('phone\x20IS\x20NOT\x20NULL')[_0x2c9eb6('0x27')](_0x2c9eb6('0x3f'),squel[_0x2c9eb6('0x45')]()[_0x2c9eb6('0x16')](_0x2c9eb6('0x48'))[_0x2c9eb6('0x9')](_0x2c9eb6('0x46'))[_0x2c9eb6('0x27')](_0x2c9eb6('0x13'),_0x33c423[_0x2c9eb6('0x2a')]['id'][_0x2c9eb6('0x5b')]())))[_0x2c9eb6('0x5b')]();break;default:_0xc86a85=squel['insert']()['into'](_0x2c9eb6('0x46'))[_0x2c9eb6('0xf')](['phone',_0x2c9eb6('0x69'),'ContactId','ListId',_0x2c9eb6('0x2d'),_0x2c9eb6('0x43'),'updatedAt'],squel['select']()['field'](_0x2c9eb6('0x10'),_0x2c9eb6('0x10'))[_0x2c9eb6('0x16')](_0x2c9eb6('0x0'),_0x2c9eb6('0x69'))[_0x2c9eb6('0x16')]('id',_0x2c9eb6('0x26'))[_0x2c9eb6('0x16')](_0x50fba3[_0x2c9eb6('0x37')][_0x2c9eb6('0x5b')](),_0x2c9eb6('0x1b'))[_0x2c9eb6('0x16')](_0x33c423['params']['id'][_0x2c9eb6('0x5b')](),_0x2c9eb6('0x2d'))[_0x2c9eb6('0x16')](_0x2c9eb6('0x0'),_0x2c9eb6('0x43'))[_0x2c9eb6('0x16')](_0x2c9eb6('0x0'),_0x2c9eb6('0x44'))[_0x2c9eb6('0x9')](_0x2c9eb6('0x1f'))['where'](_0x2c9eb6('0x65'))[_0x2c9eb6('0x27')]('ListId\x20=\x20?',_0x50fba3[_0x2c9eb6('0x37')][_0x2c9eb6('0x5b')]())['where']('phone\x20IS\x20NOT\x20NULL'))[_0x2c9eb6('0x5b')]();}_0x276570['push'](db[_0x2c9eb6('0x2b')][_0x2c9eb6('0xd')](_0xc86a85));}return Promise[_0x2c9eb6('0x5c')](_0x276570);}})[_0x171978('0x39')](function(){return _0x495173;})[_0x171978('0x39')](respondWithResult(_0x40d67b,null))[_0x171978('0x2')](handleError(_0x40d67b,null));},exports['removeLists']=function(_0x1214d0,_0xb8ef33){const _0x3475f2=_0x5021dd;return db[_0x3475f2('0x33')]['findOne']({'where':{'id':_0x1214d0[_0x3475f2('0x2a')]['id']}})[_0x3475f2('0x39')](handleEntityNotFound(_0xb8ef33,null))[_0x3475f2('0x39')](function(_0x272138){const _0x1b131e=_0x3475f2;if(_0x272138)return _0x272138[_0x1b131e('0x66')](_0x1214d0[_0x1b131e('0xd')][_0x1b131e('0x2f')]);})[_0x3475f2('0x39')](function(_0x1a5e1d){const _0x1eab36=_0x3475f2;if(_0x1a5e1d)return db[_0x1eab36('0x41')][_0x1eab36('0x7')]({'where':{'ListId':_0x1214d0['query'][_0x1eab36('0x2f')],'CampaignId':_0x1214d0[_0x1eab36('0x2a')]['id']}})[_0x1eab36('0x39')](function(){return _0x1a5e1d;});})['then'](respondWithStatusCode(_0xb8ef33,null))[_0x3475f2('0x2')](handleError(_0xb8ef33,null));},exports[_0x5021dd('0x6c')]=function(_0x2260c8,_0x5772d1){const _0x36f4dd=_0x5021dd;let _0x1ca0b0={'raw':!![],'where':{}};const _0x4b4445={},_0x2f5de1={'count':0x0,'rows':[]};return db[_0x36f4dd('0x33')][_0x36f4dd('0xc')]({'where':{'id':_0x2260c8[_0x36f4dd('0x2a')]['id']}})[_0x36f4dd('0x39')](handleEntityNotFound(_0x5772d1,null))['then'](function(_0x39b9be){const _0x1a45a1=_0x36f4dd;if(_0x39b9be)return _0x4b4445[_0x1a45a1('0x3e')]=_[_0x1a45a1('0x1d')](db[_0x1a45a1('0x42')]['rawAttributes']),_0x4b4445['query']=_[_0x1a45a1('0x1d')](_0x2260c8[_0x1a45a1('0xd')]),_0x4b4445[_0x1a45a1('0x32')]=_[_0x1a45a1('0x64')](_0x4b4445[_0x1a45a1('0x3e')],_0x4b4445['query']),_0x1ca0b0[_0x1a45a1('0x60')]=_[_0x1a45a1('0x64')](_0x4b4445[_0x1a45a1('0x3e')],qs[_0x1a45a1('0x2c')](_0x2260c8['query'][_0x1a45a1('0x2c')])),_0x1ca0b0[_0x1a45a1('0x60')]=_0x1ca0b0['attributes'][_0x1a45a1('0x51')]?_0x1ca0b0[_0x1a45a1('0x60')]:_0x4b4445['model'],typeof _0x2260c8[_0x1a45a1('0xd')][_0x1a45a1('0x63')]===_0x1a45a1('0x4c')&&(_0x1ca0b0['limit']=qs['limit'](_0x2260c8[_0x1a45a1('0xd')][_0x1a45a1('0x14')]),_0x1ca0b0[_0x1a45a1('0x56')]=qs[_0x1a45a1('0x56')](_0x2260c8[_0x1a45a1('0xd')][_0x1a45a1('0x56')])),_0x1ca0b0[_0x1a45a1('0x55')]=qs[_0x1a45a1('0x4a')](_0x2260c8[_0x1a45a1('0xd')][_0x1a45a1('0x4a')]),_0x1ca0b0[_0x1a45a1('0x27')]=qs['filters'](_[_0x1a45a1('0x1')](_0x2260c8[_0x1a45a1('0xd')],_0x4b4445['filters'])),_0x1ca0b0[_0x1a45a1('0x27')][_0x1a45a1('0x2d')]=_0x39b9be['id'],_0x2260c8[_0x1a45a1('0xd')][_0x1a45a1('0x53')]&&(_0x1ca0b0['where']=_[_0x1a45a1('0x61')](_0x1ca0b0['where'],{[Op['or']]:_[_0x1a45a1('0x11')](_0x1ca0b0[_0x1a45a1('0x60')],function(_0x4ac33a){const _0x2cc6da=_0x1a45a1,_0x419f3b={};return _0x419f3b[_0x4ac33a]={[Op[_0x2cc6da('0x28')]]:'%'+_0x2260c8[_0x2cc6da('0xd')][_0x2cc6da('0x53')]+'%'},_0x419f3b;})})),_0x1ca0b0=_[_0x1a45a1('0x61')]({},_0x1ca0b0,_0x2260c8['options']),db[_0x1a45a1('0x42')][_0x1a45a1('0x67')]({'where':_0x1ca0b0['where']})['then'](function(_0x4ee910){const _0x34696d=_0x1a45a1;return _0x2f5de1[_0x34696d('0x67')]=_0x4ee910,_0x2260c8['query'][_0x34696d('0x23')]&&(_0x1ca0b0['include']=[{'all':!![]}]),db[_0x34696d('0x42')]['findAll'](_0x1ca0b0);})[_0x1a45a1('0x39')](function(_0x42b96d){return _0x2f5de1['rows']=_0x42b96d,_0x2f5de1;});})['then'](respondWithFilteredResult(_0x5772d1,_0x1ca0b0))[_0x36f4dd('0x2')](handleError(_0x5772d1,null));},exports[_0x5021dd('0x6')]=function(_0xd56a80,_0x43bae1){const _0xa3884b=_0x5021dd;let _0x143e0f;return db['Campaign'][_0xa3884b('0xc')]({'where':{'id':_0xd56a80['params']['id']}})[_0xa3884b('0x39')](handleEntityNotFound(_0x43bae1,null))[_0xa3884b('0x39')](function(_0x2e3bad){const _0x32c441=_0xa3884b;if(_0x2e3bad)return _0x2e3bad['addBlackLists'](_0xd56a80['body'][_0x32c441('0x2f')],{'through':_[_0x32c441('0x5d')](_0xd56a80[_0x32c441('0x19')],['ids','id'])});return null;})['then'](function(_0x17dbd3){const _0x491111=_0xa3884b;let _0x3f67da;_0x143e0f=_0x17dbd3||[];const _0x3e8575=[];if(_0x17dbd3){for(let _0x210881=0x0;_0x210881<_0x17dbd3[_0x491111('0x51')];_0x210881+=0x1){const _0x30069d=_0x17dbd3[_0x210881][_0x491111('0x34')]({'plain':!![]});_0x3f67da=squel['insert']()['into'](_0x491111('0x52'))[_0x491111('0xf')](['phone',_0x491111('0x26'),'ListId',_0x491111('0x2d'),_0x491111('0x43'),'updatedAt'],squel['select']()[_0x491111('0x16')](_0x491111('0x10'),'phone')[_0x491111('0x16')]('id','ContactId')[_0x491111('0x16')](_0x30069d[_0x491111('0x37')][_0x491111('0x5b')](),_0x491111('0x1b'))[_0x491111('0x16')](_0xd56a80[_0x491111('0x2a')]['id'][_0x491111('0x5b')](),_0x491111('0x2d'))[_0x491111('0x16')]('NOW()',_0x491111('0x43'))['field'](_0x491111('0x0'),_0x491111('0x44'))[_0x491111('0x9')](_0x491111('0x1f'))['where'](_0x491111('0x65'))[_0x491111('0x27')](_0x491111('0x40'),_0x30069d[_0x491111('0x37')][_0x491111('0x5b')]())[_0x491111('0x27')]('phone\x20IS\x20NOT\x20NULL'))[_0x491111('0x5b')](),_0x3e8575[_0x491111('0x21')](db[_0x491111('0x2b')][_0x491111('0xd')](_0x3f67da));}return Promise[_0x491111('0x5c')](_0x3e8575);}})[_0xa3884b('0x39')](function(){return _0x143e0f;})[_0xa3884b('0x39')](respondWithResult(_0x43bae1,null))[_0xa3884b('0x2')](handleError(_0x43bae1,null));},exports[_0x5021dd('0x15')]=function(_0x380150,_0x1644b0){const _0x1264af=_0x5021dd;return db[_0x1264af('0x33')][_0x1264af('0xc')]({'where':{'id':_0x380150[_0x1264af('0x2a')]['id']}})['then'](handleEntityNotFound(_0x1644b0,null))['then'](function(_0x5cc9f3){const _0x250ab0=_0x1264af;if(_0x5cc9f3)return _0x5cc9f3['removeBlackLists'](_0x380150[_0x250ab0('0xd')][_0x250ab0('0x2f')]);})[_0x1264af('0x39')](function(_0xb4d853){const _0x29e359=_0x1264af;if(_0xb4d853)return db['CmHopperBlack'][_0x29e359('0x7')]({'where':{'ListId':_0x380150[_0x29e359('0xd')][_0x29e359('0x2f')],'CampaignId':_0x380150['params']['id']}})[_0x29e359('0x39')](function(){return _0xb4d853;});})[_0x1264af('0x39')](respondWithStatusCode(_0x1644b0,null))[_0x1264af('0x2')](handleError(_0x1644b0,null));}; \ No newline at end of file diff --git a/server/api/campaign/campaign.model.js b/server/api/campaign/campaign.model.js index fe4dc08..52db39d 100644 --- a/server/api/campaign/campaign.model.js +++ b/server/api/campaign/campaign.model.js @@ -1 +1 @@ -const a43_0x1479=['./campaign.attributes','campaigns','define'];(function(_0x4c42a4,_0x14791b){const _0x5772f2=function(_0x242d5e){while(--_0x242d5e){_0x4c42a4['push'](_0x4c42a4['shift']());}};_0x5772f2(++_0x14791b);}(a43_0x1479,0xbb));const a43_0x5772=function(_0x4c42a4,_0x14791b){_0x4c42a4=_0x4c42a4-0x0;let _0x5772f2=a43_0x1479[_0x4c42a4];return _0x5772f2;};const _0x99fc79=a43_0x5772;'use strict';const attributes=require(_0x99fc79('0x2'));module['exports']=function(_0x242d5e){const _0x3bf11d=_0x99fc79,_0x276259=_0x242d5e[_0x3bf11d('0x1')]('Campaign',attributes,{'tableName':_0x3bf11d('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x276259;}; \ No newline at end of file +const a43_0x31b6=['./campaign.attributes','define','campaigns'];(function(_0x2af179,_0x31b6a1){const _0x4a3ae3=function(_0x49fe14){while(--_0x49fe14){_0x2af179['push'](_0x2af179['shift']());}};_0x4a3ae3(++_0x31b6a1);}(a43_0x31b6,0x94));const a43_0x4a3a=function(_0x2af179,_0x31b6a1){_0x2af179=_0x2af179-0x0;let _0x4a3ae3=a43_0x31b6[_0x2af179];return _0x4a3ae3;};const _0x301953=a43_0x4a3a;'use strict';const attributes=require(_0x301953('0x2'));module['exports']=function(_0x49fe14){const _0x14607a=_0x301953,_0x16aab1=_0x49fe14[_0x14607a('0x0')]('Campaign',attributes,{'tableName':_0x14607a('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x16aab1;}; \ No newline at end of file diff --git a/server/api/campaign/campaign.rpc.js b/server/api/campaign/campaign.rpc.js index ba973bc..44a0562 100644 --- a/server/api/campaign/campaign.rpc.js +++ b/server/api/campaign/campaign.rpc.js @@ -1 +1 @@ -const a44_0x2aac=['../../config/logger','attributes','Campaign','map','message','GetCampaign','model','stringify','raw','error','catch','limit','rpc','then','findAll','include','../../mysqldb','options','lodash','info','debug'];(function(_0xc2e517,_0x2aace7){const _0x112ae1=function(_0x43aaff){while(--_0x43aaff){_0xc2e517['push'](_0xc2e517['shift']());}};_0x112ae1(++_0x2aace7);}(a44_0x2aac,0x1cb));const a44_0x112a=function(_0xc2e517,_0x2aace7){_0xc2e517=_0xc2e517-0x0;let _0x112ae1=a44_0x2aac[_0xc2e517];return _0x112ae1;};const _0x2e8659=a44_0x112a;'use strict';const _=require(_0x2e8659('0x0')),db=require(_0x2e8659('0x13'))['db'],logger=require(_0x2e8659('0x3'))(_0x2e8659('0xf'));exports[_0x2e8659('0x8')]=function(_0x43aaff){const _0x188dcb=this;return new Promise(function(_0x28cd6b,_0x25c1c1){const _0x4c34b5=a44_0x112a;return db[_0x4c34b5('0x5')][_0x4c34b5('0x11')]({'raw':_0x43aaff[_0x4c34b5('0x14')]?_0x43aaff[_0x4c34b5('0x14')][_0x4c34b5('0xb')]===undefined?!![]:![]:!![],'where':_0x43aaff['options']?_0x43aaff[_0x4c34b5('0x14')]['where']||null:null,'attributes':_0x43aaff[_0x4c34b5('0x14')]?_0x43aaff[_0x4c34b5('0x14')][_0x4c34b5('0x4')]||null:null,'limit':_0x43aaff[_0x4c34b5('0x14')]?_0x43aaff['options'][_0x4c34b5('0xe')]||null:null,'include':_0x43aaff[_0x4c34b5('0x14')]?_0x43aaff[_0x4c34b5('0x14')]['include']?_['map'](_0x43aaff[_0x4c34b5('0x14')][_0x4c34b5('0x12')],function(_0x3a7b72){const _0x150ac3=_0x4c34b5;return{'model':db[_0x3a7b72[_0x150ac3('0x9')]],'as':_0x3a7b72['as'],'attributes':_0x3a7b72[_0x150ac3('0x4')],'include':_0x3a7b72[_0x150ac3('0x12')]?_[_0x150ac3('0x6')](_0x3a7b72[_0x150ac3('0x12')],function(_0x41827b){const _0x4f7f1e=_0x150ac3;return{'model':db[_0x41827b[_0x4f7f1e('0x9')]],'as':_0x41827b['as'],'attributes':_0x41827b[_0x4f7f1e('0x4')],'include':_0x41827b[_0x4f7f1e('0x12')]?_[_0x4f7f1e('0x6')](_0x41827b['include'],function(_0x1985e1){const _0x104814=_0x4f7f1e;return{'model':db[_0x1985e1[_0x104814('0x9')]],'as':_0x1985e1['as'],'attributes':_0x1985e1[_0x104814('0x4')]};}):[]};}):[]};}):[]:[]})[_0x4c34b5('0x10')](function(_0x9f3e56){const _0x26ea23=_0x4c34b5;logger[_0x26ea23('0x1')](_0x26ea23('0x8'),_0x43aaff),logger[_0x26ea23('0x2')]('GetCampaign',_0x43aaff,JSON[_0x26ea23('0xa')](_0x9f3e56)),_0x28cd6b(_0x9f3e56);})[_0x4c34b5('0xd')](function(_0x94d27c){const _0x16c0cc=_0x4c34b5;logger[_0x16c0cc('0xc')](_0x16c0cc('0x8'),_0x94d27c['message'],_0x43aaff),_0x25c1c1(_0x188dcb['error'](0x1f4,_0x94d27c[_0x16c0cc('0x7')]));});});}; \ No newline at end of file +const a44_0x45df=['info','map','../../mysqldb','where','then','findAll','message','GetCampaign','options','Campaign','attributes','raw','include','../../config/logger','model','debug','stringify','error','catch'];(function(_0x439c8e,_0x45dfe9){const _0x29aa70=function(_0x11f98d){while(--_0x11f98d){_0x439c8e['push'](_0x439c8e['shift']());}};_0x29aa70(++_0x45dfe9);}(a44_0x45df,0x111));const a44_0x29aa=function(_0x439c8e,_0x45dfe9){_0x439c8e=_0x439c8e-0x0;let _0x29aa70=a44_0x45df[_0x439c8e];return _0x29aa70;};const _0x3d5be9=a44_0x29aa;'use strict';const _=require('lodash'),db=require(_0x3d5be9('0xe'))['db'],logger=require(_0x3d5be9('0x6'))('rpc');exports[_0x3d5be9('0x0')]=function(_0x11f98d){const _0x4a0fd3=this;return new Promise(function(_0x33240e,_0x178444){const _0x3e7615=a44_0x29aa;return db[_0x3e7615('0x2')][_0x3e7615('0x11')]({'raw':_0x11f98d[_0x3e7615('0x1')]?_0x11f98d['options'][_0x3e7615('0x4')]===undefined?!![]:![]:!![],'where':_0x11f98d[_0x3e7615('0x1')]?_0x11f98d['options'][_0x3e7615('0xf')]||null:null,'attributes':_0x11f98d[_0x3e7615('0x1')]?_0x11f98d[_0x3e7615('0x1')][_0x3e7615('0x3')]||null:null,'limit':_0x11f98d[_0x3e7615('0x1')]?_0x11f98d[_0x3e7615('0x1')]['limit']||null:null,'include':_0x11f98d[_0x3e7615('0x1')]?_0x11f98d[_0x3e7615('0x1')][_0x3e7615('0x5')]?_[_0x3e7615('0xd')](_0x11f98d[_0x3e7615('0x1')][_0x3e7615('0x5')],function(_0x5bb7df){const _0x2ccd4e=_0x3e7615;return{'model':db[_0x5bb7df[_0x2ccd4e('0x7')]],'as':_0x5bb7df['as'],'attributes':_0x5bb7df['attributes'],'include':_0x5bb7df['include']?_[_0x2ccd4e('0xd')](_0x5bb7df[_0x2ccd4e('0x5')],function(_0x91da84){const _0x6c4a9b=_0x2ccd4e;return{'model':db[_0x91da84['model']],'as':_0x91da84['as'],'attributes':_0x91da84[_0x6c4a9b('0x3')],'include':_0x91da84[_0x6c4a9b('0x5')]?_['map'](_0x91da84[_0x6c4a9b('0x5')],function(_0x19a16c){const _0x2a3297=_0x6c4a9b;return{'model':db[_0x19a16c[_0x2a3297('0x7')]],'as':_0x19a16c['as'],'attributes':_0x19a16c[_0x2a3297('0x3')]};}):[]};}):[]};}):[]:[]})[_0x3e7615('0x10')](function(_0x39caae){const _0x170d81=_0x3e7615;logger[_0x170d81('0xc')](_0x170d81('0x0'),_0x11f98d),logger[_0x170d81('0x8')](_0x170d81('0x0'),_0x11f98d,JSON[_0x170d81('0x9')](_0x39caae)),_0x33240e(_0x39caae);})[_0x3e7615('0xb')](function(_0x5d2dfd){const _0x1d7814=_0x3e7615;logger[_0x1d7814('0xa')](_0x1d7814('0x0'),_0x5d2dfd[_0x1d7814('0x12')],_0x11f98d),_0x178444(_0x4a0fd3[_0x1d7814('0xa')](0x1f4,_0x5d2dfd[_0x1d7814('0x12')]));});});}; \ No newline at end of file diff --git a/server/api/campaign/index.js b/server/api/campaign/index.js index 08b8eaf..d62a65a 100644 --- a/server/api/campaign/index.js +++ b/server/api/campaign/index.js @@ -1 +1 @@ -const a45_0x42e2=['getLists','show','clone','/:id','isAuthenticated','destroy','addBlackLists','get','getHoppers','getHopperFinals','index','getHopperHistories','/:id/lists','/:id/hopper_black','create','/:id/hopper_finals','exports','removeLists','delete','../../components/auth/service','express','/:id/clone','./campaign.controller','post','/:id/hoppers','/:id/blacklists'];(function(_0x27113b,_0x42e294){const _0xe5f305=function(_0x11aa80){while(--_0x11aa80){_0x27113b['push'](_0x27113b['shift']());}};_0xe5f305(++_0x42e294);}(a45_0x42e2,0x8c));const a45_0xe5f3=function(_0x27113b,_0x42e294){_0x27113b=_0x27113b-0x0;let _0xe5f305=a45_0x42e2[_0x27113b];return _0xe5f305;};const _0x57763f=a45_0xe5f3;'use strict';const express=require(_0x57763f('0xa')),router=express['Router'](),auth=require(_0x57763f('0x9')),controller=require(_0x57763f('0xc'));router[_0x57763f('0x17')]('/',auth['isAuthenticated'](),controller[_0x57763f('0x0')]),router[_0x57763f('0x17')](_0x57763f('0x13'),auth[_0x57763f('0x14')](),controller[_0x57763f('0x11')]),router[_0x57763f('0x17')](_0x57763f('0xe'),auth['isAuthenticated'](),controller[_0x57763f('0x18')]),router['get']('/:id/hopper_histories',auth[_0x57763f('0x14')](),controller[_0x57763f('0x1')]),router['get'](_0x57763f('0x5'),auth[_0x57763f('0x14')](),controller[_0x57763f('0x19')]),router[_0x57763f('0x17')](_0x57763f('0x3'),auth['isAuthenticated'](),controller['getHopperBlacks']),router[_0x57763f('0x17')](_0x57763f('0x2'),auth['isAuthenticated'](),controller[_0x57763f('0x10')]),router[_0x57763f('0x17')](_0x57763f('0xf'),auth[_0x57763f('0x14')](),controller['getBlackLists']),router['post']('/',auth['isAuthenticated'](),controller[_0x57763f('0x4')]),router[_0x57763f('0xd')](_0x57763f('0xb'),auth[_0x57763f('0x14')](),controller[_0x57763f('0x12')]),router['post'](_0x57763f('0x2'),auth['isAuthenticated'](),controller['addLists']),router[_0x57763f('0xd')](_0x57763f('0xf'),auth[_0x57763f('0x14')](),controller[_0x57763f('0x16')]),router['put'](_0x57763f('0x13'),auth[_0x57763f('0x14')](),controller['update']),router['delete'](_0x57763f('0x13'),auth[_0x57763f('0x14')](),controller[_0x57763f('0x15')]),router[_0x57763f('0x8')](_0x57763f('0x2'),auth[_0x57763f('0x14')](),controller[_0x57763f('0x7')]),router[_0x57763f('0x8')](_0x57763f('0xf'),auth[_0x57763f('0x14')](),controller['removeBlackLists']),module[_0x57763f('0x6')]=router; \ No newline at end of file +const a45_0x2f03=['put','getBlackLists','post','getHopperFinals','/:id/hoppers','isAuthenticated','../../components/auth/service','show','/:id','removeLists','/:id/blacklists','clone','/:id/clone','exports','create','/:id/hopper_histories','addBlackLists','get','/:id/lists','/:id/hopper_finals','addLists','delete','update','getLists','getHopperBlacks','./campaign.controller'];(function(_0x423e57,_0x2f03ed){const _0x1c6ef9=function(_0x509edf){while(--_0x509edf){_0x423e57['push'](_0x423e57['shift']());}};_0x1c6ef9(++_0x2f03ed);}(a45_0x2f03,0x178));const a45_0x1c6e=function(_0x423e57,_0x2f03ed){_0x423e57=_0x423e57-0x0;let _0x1c6ef9=a45_0x2f03[_0x423e57];return _0x1c6ef9;};const _0x219c26=a45_0x1c6e;'use strict';const express=require('express'),router=express['Router'](),auth=require(_0x219c26('0x14')),controller=require(_0x219c26('0xd'));router[_0x219c26('0x5')]('/',auth[_0x219c26('0x13')](),controller['index']),router['get']('/:id',auth[_0x219c26('0x13')](),controller[_0x219c26('0x15')]),router[_0x219c26('0x5')](_0x219c26('0x12'),auth[_0x219c26('0x13')](),controller['getHoppers']),router[_0x219c26('0x5')](_0x219c26('0x3'),auth[_0x219c26('0x13')](),controller['getHopperHistories']),router[_0x219c26('0x5')](_0x219c26('0x7'),auth[_0x219c26('0x13')](),controller[_0x219c26('0x11')]),router[_0x219c26('0x5')]('/:id/hopper_black',auth[_0x219c26('0x13')](),controller[_0x219c26('0xc')]),router[_0x219c26('0x5')](_0x219c26('0x6'),auth[_0x219c26('0x13')](),controller[_0x219c26('0xb')]),router[_0x219c26('0x5')](_0x219c26('0x18'),auth[_0x219c26('0x13')](),controller[_0x219c26('0xf')]),router[_0x219c26('0x10')]('/',auth[_0x219c26('0x13')](),controller[_0x219c26('0x2')]),router[_0x219c26('0x10')](_0x219c26('0x0'),auth['isAuthenticated'](),controller[_0x219c26('0x19')]),router[_0x219c26('0x10')](_0x219c26('0x6'),auth[_0x219c26('0x13')](),controller[_0x219c26('0x8')]),router[_0x219c26('0x10')]('/:id/blacklists',auth[_0x219c26('0x13')](),controller[_0x219c26('0x4')]),router[_0x219c26('0xe')]('/:id',auth[_0x219c26('0x13')](),controller[_0x219c26('0xa')]),router[_0x219c26('0x9')](_0x219c26('0x16'),auth[_0x219c26('0x13')](),controller['destroy']),router['delete'](_0x219c26('0x6'),auth[_0x219c26('0x13')](),controller[_0x219c26('0x17')]),router[_0x219c26('0x9')]('/:id/blacklists',auth['isAuthenticated'](),controller['removeBlackLists']),module[_0x219c26('0x1')]=router; \ No newline at end of file diff --git a/server/api/cannedAnswer/cannedAnswer.attributes.js b/server/api/cannedAnswer/cannedAnswer.attributes.js index 17a8669..8b8523d 100644 --- a/server/api/cannedAnswer/cannedAnswer.attributes.js +++ b/server/api/cannedAnswer/cannedAnswer.attributes.js @@ -1 +1 @@ -const a46_0x1ce3=['getDataValue','key','STRING','exports','TEXT'];(function(_0x13c1c1,_0x1ce312){const _0x2cb563=function(_0x4e1f88){while(--_0x4e1f88){_0x13c1c1['push'](_0x13c1c1['shift']());}};_0x2cb563(++_0x1ce312);}(a46_0x1ce3,0x10b));const a46_0x2cb5=function(_0x13c1c1,_0x1ce312){_0x13c1c1=_0x13c1c1-0x0;let _0x2cb563=a46_0x1ce3[_0x13c1c1];return _0x2cb563;};const _0x3d32e4=a46_0x2cb5;'use strict';const Sequelize=require('sequelize');module[_0x3d32e4('0x1')]={'key':{'type':Sequelize[_0x3d32e4('0x0')],'allowNull':![]},'value':{'type':Sequelize[_0x3d32e4('0x2')],'allowNull':![]},'description':{'type':Sequelize[_0x3d32e4('0x0')]},'name':{'type':Sequelize['VIRTUAL'],'get':function(){const _0x3b31b5=_0x3d32e4;return this[_0x3b31b5('0x3')](_0x3b31b5('0x4'));}}}; \ No newline at end of file +const a46_0x3eae=['sequelize','STRING','TEXT','exports','VIRTUAL','getDataValue','key'];(function(_0x4e0e38,_0x3eae93){const _0x2690a2=function(_0x147e2d){while(--_0x147e2d){_0x4e0e38['push'](_0x4e0e38['shift']());}};_0x2690a2(++_0x3eae93);}(a46_0x3eae,0x14a));const a46_0x2690=function(_0x4e0e38,_0x3eae93){_0x4e0e38=_0x4e0e38-0x0;let _0x2690a2=a46_0x3eae[_0x4e0e38];return _0x2690a2;};const _0x2d238c=a46_0x2690;'use strict';const Sequelize=require(_0x2d238c('0x6'));module[_0x2d238c('0x2')]={'key':{'type':Sequelize[_0x2d238c('0x0')],'allowNull':![]},'value':{'type':Sequelize[_0x2d238c('0x1')],'allowNull':![]},'description':{'type':Sequelize[_0x2d238c('0x0')]},'name':{'type':Sequelize[_0x2d238c('0x3')],'get':function(){const _0x5e0592=_0x2d238c;return this[_0x5e0592('0x4')](_0x5e0592('0x5'));}}}; \ No newline at end of file diff --git a/server/api/cannedAnswer/cannedAnswer.controller.js b/server/api/cannedAnswer/cannedAnswer.controller.js index a420b50..a1d9454 100644 --- a/server/api/cannedAnswer/cannedAnswer.controller.js +++ b/server/api/cannedAnswer/cannedAnswer.controller.js @@ -1 +1 @@ -const a47_0x13b8=['role','ChatWebsiteId','findOne','offset','set','type','fields','api','query','CannedAnswer','nolimit','end','length','userProfileId','status','where','params','rawAttributes','rows','body','count','like','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','fieldName','create','error','../../components/parsers/qs','model','sort','send','merge','options','Content-Range','json','include','CannedAnswers','show','update','../../config/logger','stack','key','includeAll','attributes','SmsAccountId','../../mysqldb','catch','then','VIRTUAL','autoAssociation','destroy','filter','filters','intersection','get','map','MailAccountId','keys','index','order','name','limit','UserProfileResource','user'];(function(_0x10ceb3,_0x13b826){const _0x243a02=function(_0x5a5227){while(--_0x5a5227){_0x10ceb3['push'](_0x10ceb3['shift']());}};_0x243a02(++_0x13b826);}(a47_0x13b8,0x198));const a47_0x243a=function(_0x10ceb3,_0x13b826){_0x10ceb3=_0x10ceb3-0x0;let _0x243a02=a47_0x13b8[_0x10ceb3];return _0x243a02;};const _0x11d1b8=a47_0x243a;'use strict';const _=require('lodash'),qs=require(_0x11d1b8('0x3b')),logger=require(_0x11d1b8('0x8'))(_0x11d1b8('0x28')),db=require(_0x11d1b8('0xe'))['db'],{Op,ValidationError}=require('sequelize');function respondWithResult(_0x5a5227,_0x3f2d1c){return _0x3f2d1c=_0x3f2d1c||0xc8,function(_0x4dc776){const _0x31737c=a47_0x243a;if(_0x4dc776)return _0x5a5227[_0x31737c('0x2f')](_0x3f2d1c)[_0x31737c('0x3')](_0x4dc776);};}function respondWithFilteredResult(_0x371462,_0x547de1){return function(_0x3f0388){const _0x4add99=a47_0x243a;if(_0x3f0388){const _0x489e57=_0x3f0388[_0x4add99('0x35')],_0xe79c17=_0x547de1[_0x4add99('0x24')];let _0x57a300=_0x547de1[_0x4add99('0x24')]+_0x547de1[_0x4add99('0x1e')],_0x3e79aa;return _0x57a300>=_0x489e57?(_0x57a300=_0x489e57,_0x3e79aa=0xc8):_0x3e79aa=0xce,_0x371462['status'](_0x3e79aa),_0x371462[_0x4add99('0x25')](_0x4add99('0x2'),_0xe79c17+'-'+_0x57a300+'/'+_0x489e57)['json'](_0x3f0388);}return null;};}function saveUpdates(_0x1779ef){return function(_0xada649){const _0x29070e=a47_0x243a;if(_0xada649)return _0xada649[_0x29070e('0x7')](_0x1779ef)['then'](function(_0x5b0bf4){return _0x5b0bf4;});return null;};}function removeEntity(_0xe72c96){return function(_0x4944aa){const _0x5aa8ae=a47_0x243a;if(_0x4944aa)return _0x4944aa[_0x5aa8ae('0x13')]()[_0x5aa8ae('0x10')](function(){const _0x5881f0=_0x5aa8ae,_0x145d95=_0x4944aa[_0x5881f0('0x17')]({'plain':!![]}),_0x4f72ec=_0x5881f0('0x5');return db['UserProfileResource']['destroy']({'where':{'type':_0x4f72ec,'resourceId':_0x145d95['id']}})['then'](function(){return _0x4944aa;});})[_0x5aa8ae('0x10')](function(){const _0x7e65db=_0x5aa8ae;_0xe72c96[_0x7e65db('0x2f')](0xcc)[_0x7e65db('0x2c')]();});};}function handleEntityNotFound(_0x187170){return function(_0x831b59){return!_0x831b59&&_0x187170['sendStatus'](0x194),_0x831b59;};}function handleError(_0x3a3f2d,_0xcd0e4c){return _0xcd0e4c=_0xcd0e4c||0x1f4,function(_0x46b8f5){const _0x3db2d3=a47_0x243a;logger[_0x3db2d3('0x3a')](_0x46b8f5[_0x3db2d3('0x9')]),_0x46b8f5['name']&&delete _0x46b8f5['name'],_0x3a3f2d[_0x3db2d3('0x2f')](_0xcd0e4c)[_0x3db2d3('0x3e')](_0x46b8f5);};}exports[_0x11d1b8('0x1b')]=function(_0x463b93,_0x3860f0){const _0x1d6975=_0x11d1b8;let _0x5e5393={};const _0x21d5ac={},_0x2eb935={'count':0x0,'rows':[]},_0x1b7d68=_[_0x1d6975('0x18')](db[_0x1d6975('0x2a')][_0x1d6975('0x32')],function(_0x4da1a6){const _0x49590e=_0x1d6975;return{'name':_0x4da1a6[_0x49590e('0x38')],'type':_0x4da1a6[_0x49590e('0x26')][_0x49590e('0xa')]};});_0x21d5ac[_0x1d6975('0x3c')]=_[_0x1d6975('0x18')](_0x1b7d68,_0x1d6975('0x1d')),_0x21d5ac[_0x1d6975('0x29')]=_[_0x1d6975('0x1a')](_0x463b93[_0x1d6975('0x29')]),_0x21d5ac['filters']=_[_0x1d6975('0x16')](_0x21d5ac[_0x1d6975('0x3c')],_0x21d5ac[_0x1d6975('0x29')]),_0x5e5393['attributes']=_[_0x1d6975('0x16')](_0x21d5ac['model'],qs[_0x1d6975('0x27')](_0x463b93[_0x1d6975('0x29')][_0x1d6975('0x27')])),_0x5e5393['attributes']=_0x5e5393[_0x1d6975('0xc')]['length']?_0x5e5393[_0x1d6975('0xc')]:_0x21d5ac[_0x1d6975('0x3c')];typeof _0x463b93[_0x1d6975('0x29')][_0x1d6975('0x2b')]==='undefined'&&(_0x5e5393[_0x1d6975('0x1e')]=qs[_0x1d6975('0x1e')](_0x463b93[_0x1d6975('0x29')][_0x1d6975('0x1e')]),_0x5e5393[_0x1d6975('0x24')]=qs[_0x1d6975('0x24')](_0x463b93['query']['offset']));_0x5e5393[_0x1d6975('0x1c')]=qs[_0x1d6975('0x3d')](_0x463b93[_0x1d6975('0x29')][_0x1d6975('0x3d')]),_0x5e5393['where']=qs[_0x1d6975('0x15')](_['pick'](_0x463b93['query'],_0x21d5ac[_0x1d6975('0x15')]),_0x1b7d68);_0x463b93[_0x1d6975('0x29')][_0x1d6975('0x14')]&&(_0x5e5393[_0x1d6975('0x30')]=_[_0x1d6975('0x0')](_0x5e5393['where'],{[Op['or']]:_['map'](_0x1b7d68,function(_0x2011c2){const _0x585c52=_0x1d6975;if(_0x2011c2['type']!==_0x585c52('0x11')){const _0x105504={};return _0x105504[_0x2011c2['name']]={[Op[_0x585c52('0x36')]]:'%'+_0x463b93[_0x585c52('0x29')][_0x585c52('0x14')]+'%'},_0x105504;}})}));_0x5e5393=_[_0x1d6975('0x0')]({},_0x5e5393,_0x463b93[_0x1d6975('0x1')]);const _0xbbf27a={'where':_0x5e5393['where']};return db['CannedAnswer'][_0x1d6975('0x35')](_0xbbf27a)['then'](function(_0x4b180d){const _0x4d473d=_0x1d6975;return _0x2eb935[_0x4d473d('0x35')]=_0x4b180d,_0x463b93['query'][_0x4d473d('0xb')]&&(_0x5e5393[_0x4d473d('0x4')]=[{'all':!![]}]),db['CannedAnswer']['findAll'](_0x5e5393);})['then'](function(_0x15f02b){const _0x2b1a55=_0x1d6975;return _0x2eb935[_0x2b1a55('0x33')]=_0x15f02b,_0x2eb935;})[_0x1d6975('0x10')](respondWithFilteredResult(_0x3860f0,_0x5e5393))[_0x1d6975('0xf')](handleError(_0x3860f0,null));},exports[_0x11d1b8('0x6')]=function(_0x2652ba,_0x60105c){const _0x162342=_0x11d1b8;let _0x1d7d3b={'raw':!![],'where':{'id':_0x2652ba['params']['id']}};const _0x3488bd={};return _0x3488bd['model']=_['keys'](db[_0x162342('0x2a')][_0x162342('0x32')]),_0x3488bd[_0x162342('0x29')]=_[_0x162342('0x1a')](_0x2652ba['query']),_0x3488bd[_0x162342('0x15')]=_[_0x162342('0x16')](_0x3488bd[_0x162342('0x3c')],_0x3488bd[_0x162342('0x29')]),_0x1d7d3b['attributes']=_['intersection'](_0x3488bd[_0x162342('0x3c')],qs[_0x162342('0x27')](_0x2652ba[_0x162342('0x29')]['fields'])),_0x1d7d3b[_0x162342('0xc')]=_0x1d7d3b[_0x162342('0xc')][_0x162342('0x2d')]?_0x1d7d3b['attributes']:_0x3488bd[_0x162342('0x3c')],_0x2652ba[_0x162342('0x29')][_0x162342('0xb')]&&(_0x1d7d3b[_0x162342('0x4')]=[{'all':!![]}]),_0x1d7d3b=_[_0x162342('0x0')]({},_0x1d7d3b,_0x2652ba[_0x162342('0x1')]),db[_0x162342('0x2a')]['findOne'](_0x1d7d3b)['then'](handleEntityNotFound(_0x60105c,null))[_0x162342('0x10')](respondWithResult(_0x60105c,null))['catch'](handleError(_0x60105c,null));},exports[_0x11d1b8('0x7')]=function(_0x392c61,_0xf29943){const _0x20c42b=_0x11d1b8;return _0x392c61[_0x20c42b('0x34')]['id']&&delete _0x392c61['body']['id'],db['CannedAnswer'][_0x20c42b('0x23')]({'where':{'id':_0x392c61[_0x20c42b('0x31')]['id']}})[_0x20c42b('0x10')](handleEntityNotFound(_0xf29943,null))[_0x20c42b('0x10')](saveUpdates(_0x392c61[_0x20c42b('0x34')],null))[_0x20c42b('0x10')](respondWithResult(_0xf29943,null))[_0x20c42b('0xf')](handleError(_0xf29943,null));},exports[_0x11d1b8('0x13')]=function(_0x380980,_0x498ccd){const _0x5ad885=_0x11d1b8;return db[_0x5ad885('0x2a')][_0x5ad885('0x23')]({'where':{'id':_0x380980[_0x5ad885('0x31')]['id']}})['then'](handleEntityNotFound(_0x498ccd,null))[_0x5ad885('0x10')](removeEntity(_0x498ccd,null))['catch'](handleError(_0x498ccd,null));},exports['create']=function(_0x500b73,_0x2e9c28){const _0x497b04=_0x11d1b8,_0x786e9f={'key':_0x500b73['body'][_0x497b04('0xa')]};if(_0x500b73[_0x497b04('0x34')]['MailAccountId'])_0x786e9f['MailAccountId']=_0x500b73[_0x497b04('0x34')][_0x497b04('0x19')];else{if(_0x500b73['body']['SmsAccountId'])_0x786e9f[_0x497b04('0xd')]=_0x500b73['body'][_0x497b04('0xd')];else{if(_0x500b73[_0x497b04('0x34')]['OpenchannelAccountId'])_0x786e9f['OpenchannelAccountId']=_0x500b73[_0x497b04('0x34')]['OpenchannelAccountId'];else _0x500b73[_0x497b04('0x34')]['ChatWebsiteId']&&(_0x786e9f['ChatWebsiteId']=_0x500b73['body'][_0x497b04('0x22')]);}}return db[_0x497b04('0x2a')][_0x497b04('0x23')]({'where':_0x786e9f})[_0x497b04('0x10')](function(_0x10ce64){const _0x14f740=_0x497b04;if(_0x10ce64)throw new ValidationError('The\x20inserted\x20key\x20already\x20exists.');return db[_0x14f740('0x2a')]['create'](_0x500b73['body']);})[_0x497b04('0x10')](function(_0x3f2a70){const _0x19d247=_0x497b04,_0x4c4d85=_0x500b73[_0x19d247('0x20')][_0x19d247('0x17')]({'plain':!![]});if(!_0x4c4d85)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x4c4d85[_0x19d247('0x21')]===_0x19d247('0x20')){const _0x3f4583=_0x3f2a70[_0x19d247('0x17')]({'plain':!![]});return db['UserProfileSection'][_0x19d247('0x23')]({'where':{'name':_0x19d247('0x5'),'userProfileId':_0x4c4d85[_0x19d247('0x2e')]},'raw':!![]})[_0x19d247('0x10')](function(_0x11985b){const _0x37f22f=_0x19d247;return _0x11985b&&_0x11985b[_0x37f22f('0x12')]===0x0?db[_0x37f22f('0x1f')][_0x37f22f('0x39')]({'name':_0x3f4583[_0x37f22f('0x1d')],'resourceId':_0x3f4583['id'],'type':_0x11985b[_0x37f22f('0x1d')],'sectionId':_0x11985b['id']},{})['then'](function(){return _0x3f2a70;}):_0x3f2a70;})[_0x19d247('0xf')](function(_0x4f5ee0){const _0x159449=_0x19d247;logger['error'](_0x159449('0x37'),_0x4f5ee0);throw _0x4f5ee0;});}return _0x3f2a70;})[_0x497b04('0x10')](respondWithResult(_0x2e9c28,0xc9))[_0x497b04('0xf')](handleError(_0x2e9c28,null));}; \ No newline at end of file +const a47_0x50fc=['SmsAccountId','UserProfileResource','lodash','keys','sendStatus','MailAccountId','show','filter','end','filters','key','findOne','get','sort','json','api','CannedAnswers','error','userProfileId','body','merge','limit','rows','OpenchannelAccountId','length','offset','order','undefined','../../mysqldb','catch','include','Unable\x20to\x20retrieve\x20the\x20current\x20user','includeAll','VIRTUAL','query','send','count','intersection','CannedAnswer','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','where','like','set','options','model','destroy','type','create','ChatWebsiteId','params','autoAssociation','name','stack','map','rawAttributes','status','fields','UserProfileSection','then','update','pick','attributes'];(function(_0x4a005e,_0x50fcbc){const _0x3c66ae=function(_0x1000e4){while(--_0x1000e4){_0x4a005e['push'](_0x4a005e['shift']());}};_0x3c66ae(++_0x50fcbc);}(a47_0x50fc,0x167));const a47_0x3c66=function(_0x4a005e,_0x50fcbc){_0x4a005e=_0x4a005e-0x0;let _0x3c66ae=a47_0x50fc[_0x4a005e];return _0x3c66ae;};const _0x2c183c=a47_0x3c66;'use strict';const _=require(_0x2c183c('0xf')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x2c183c('0x1c')),db=require(_0x2c183c('0x29'))['db'],{Op,ValidationError}=require('sequelize');function respondWithResult(_0x1000e4,_0x58e58d){return _0x58e58d=_0x58e58d||0xc8,function(_0x151f02){const _0x5a360f=a47_0x3c66;if(_0x151f02)return _0x1000e4[_0x5a360f('0x6')](_0x58e58d)[_0x5a360f('0x1b')](_0x151f02);};}function respondWithFilteredResult(_0x4f1bd2,_0x54e11f){return function(_0x216901){const _0x2aad49=a47_0x3c66;if(_0x216901){const _0x2f56f3=_0x216901[_0x2aad49('0x31')],_0x2132d2=_0x54e11f[_0x2aad49('0x26')];let _0x1e4e42=_0x54e11f[_0x2aad49('0x26')]+_0x54e11f[_0x2aad49('0x22')],_0x3026f7;return _0x1e4e42>=_0x2f56f3?(_0x1e4e42=_0x2f56f3,_0x3026f7=0xc8):_0x3026f7=0xce,_0x4f1bd2['status'](_0x3026f7),_0x4f1bd2[_0x2aad49('0x37')]('Content-Range',_0x2132d2+'-'+_0x1e4e42+'/'+_0x2f56f3)[_0x2aad49('0x1b')](_0x216901);}return null;};}function saveUpdates(_0x54adad){return function(_0x4500a4){const _0x46fc9d=a47_0x3c66;if(_0x4500a4)return _0x4500a4[_0x46fc9d('0xa')](_0x54adad)[_0x46fc9d('0x9')](function(_0x23f0ab){return _0x23f0ab;});return null;};}function removeEntity(_0x4c6f9b){return function(_0xf917d6){const _0x794bf2=a47_0x3c66;if(_0xf917d6)return _0xf917d6[_0x794bf2('0x3a')]()[_0x794bf2('0x9')](function(){const _0x535d3b=_0x794bf2,_0x298f81=_0xf917d6[_0x535d3b('0x19')]({'plain':!![]}),_0x334796=_0x535d3b('0x1d');return db[_0x535d3b('0xe')]['destroy']({'where':{'type':_0x334796,'resourceId':_0x298f81['id']}})[_0x535d3b('0x9')](function(){return _0xf917d6;});})[_0x794bf2('0x9')](function(){const _0x5544f3=_0x794bf2;_0x4c6f9b[_0x5544f3('0x6')](0xcc)[_0x5544f3('0x15')]();});};}function handleEntityNotFound(_0x268e90){return function(_0x496feb){const _0x275718=a47_0x3c66;return!_0x496feb&&_0x268e90[_0x275718('0x11')](0x194),_0x496feb;};}function handleError(_0x342cef,_0x5f3165){return _0x5f3165=_0x5f3165||0x1f4,function(_0x3647cf){const _0x35ecc7=a47_0x3c66;logger[_0x35ecc7('0x1e')](_0x3647cf[_0x35ecc7('0x3')]),_0x3647cf[_0x35ecc7('0x2')]&&delete _0x3647cf[_0x35ecc7('0x2')],_0x342cef[_0x35ecc7('0x6')](_0x5f3165)[_0x35ecc7('0x30')](_0x3647cf);};}exports['index']=function(_0x57364e,_0x59e040){const _0xb0424a=_0x2c183c;let _0x345a6e={};const _0x304502={},_0x41f623={'count':0x0,'rows':[]},_0x3272c8=_[_0xb0424a('0x4')](db[_0xb0424a('0x33')][_0xb0424a('0x5')],function(_0x4c7dcd){const _0x984b6d=_0xb0424a;return{'name':_0x4c7dcd['fieldName'],'type':_0x4c7dcd[_0x984b6d('0x3b')][_0x984b6d('0x17')]};});_0x304502[_0xb0424a('0x39')]=_[_0xb0424a('0x4')](_0x3272c8,_0xb0424a('0x2')),_0x304502[_0xb0424a('0x2f')]=_[_0xb0424a('0x10')](_0x57364e[_0xb0424a('0x2f')]),_0x304502[_0xb0424a('0x16')]=_[_0xb0424a('0x32')](_0x304502[_0xb0424a('0x39')],_0x304502['query']),_0x345a6e[_0xb0424a('0xc')]=_['intersection'](_0x304502['model'],qs[_0xb0424a('0x7')](_0x57364e[_0xb0424a('0x2f')][_0xb0424a('0x7')])),_0x345a6e[_0xb0424a('0xc')]=_0x345a6e[_0xb0424a('0xc')][_0xb0424a('0x25')]?_0x345a6e[_0xb0424a('0xc')]:_0x304502[_0xb0424a('0x39')];typeof _0x57364e['query']['nolimit']===_0xb0424a('0x28')&&(_0x345a6e[_0xb0424a('0x22')]=qs[_0xb0424a('0x22')](_0x57364e[_0xb0424a('0x2f')][_0xb0424a('0x22')]),_0x345a6e[_0xb0424a('0x26')]=qs[_0xb0424a('0x26')](_0x57364e[_0xb0424a('0x2f')][_0xb0424a('0x26')]));_0x345a6e[_0xb0424a('0x27')]=qs[_0xb0424a('0x1a')](_0x57364e[_0xb0424a('0x2f')][_0xb0424a('0x1a')]),_0x345a6e['where']=qs[_0xb0424a('0x16')](_[_0xb0424a('0xb')](_0x57364e[_0xb0424a('0x2f')],_0x304502['filters']),_0x3272c8);_0x57364e[_0xb0424a('0x2f')]['filter']&&(_0x345a6e[_0xb0424a('0x35')]=_[_0xb0424a('0x21')](_0x345a6e[_0xb0424a('0x35')],{[Op['or']]:_['map'](_0x3272c8,function(_0x2cf25c){const _0x4cc559=_0xb0424a;if(_0x2cf25c[_0x4cc559('0x3b')]!==_0x4cc559('0x2e')){const _0x3aedf8={};return _0x3aedf8[_0x2cf25c[_0x4cc559('0x2')]]={[Op[_0x4cc559('0x36')]]:'%'+_0x57364e[_0x4cc559('0x2f')][_0x4cc559('0x14')]+'%'},_0x3aedf8;}})}));_0x345a6e=_[_0xb0424a('0x21')]({},_0x345a6e,_0x57364e[_0xb0424a('0x38')]);const _0x4715d5={'where':_0x345a6e[_0xb0424a('0x35')]};return db[_0xb0424a('0x33')][_0xb0424a('0x31')](_0x4715d5)['then'](function(_0x356194){const _0x2dfdf4=_0xb0424a;return _0x41f623[_0x2dfdf4('0x31')]=_0x356194,_0x57364e[_0x2dfdf4('0x2f')][_0x2dfdf4('0x2d')]&&(_0x345a6e[_0x2dfdf4('0x2b')]=[{'all':!![]}]),db[_0x2dfdf4('0x33')]['findAll'](_0x345a6e);})[_0xb0424a('0x9')](function(_0x591206){const _0x906486=_0xb0424a;return _0x41f623[_0x906486('0x23')]=_0x591206,_0x41f623;})[_0xb0424a('0x9')](respondWithFilteredResult(_0x59e040,_0x345a6e))[_0xb0424a('0x2a')](handleError(_0x59e040,null));},exports[_0x2c183c('0x13')]=function(_0x2564e4,_0xb22c9a){const _0x5513fe=_0x2c183c;let _0x8b169c={'raw':!![],'where':{'id':_0x2564e4['params']['id']}};const _0x2b7369={};return _0x2b7369['model']=_['keys'](db[_0x5513fe('0x33')]['rawAttributes']),_0x2b7369[_0x5513fe('0x2f')]=_['keys'](_0x2564e4[_0x5513fe('0x2f')]),_0x2b7369[_0x5513fe('0x16')]=_[_0x5513fe('0x32')](_0x2b7369[_0x5513fe('0x39')],_0x2b7369['query']),_0x8b169c['attributes']=_['intersection'](_0x2b7369[_0x5513fe('0x39')],qs[_0x5513fe('0x7')](_0x2564e4[_0x5513fe('0x2f')][_0x5513fe('0x7')])),_0x8b169c[_0x5513fe('0xc')]=_0x8b169c['attributes'][_0x5513fe('0x25')]?_0x8b169c[_0x5513fe('0xc')]:_0x2b7369['model'],_0x2564e4['query'][_0x5513fe('0x2d')]&&(_0x8b169c['include']=[{'all':!![]}]),_0x8b169c=_['merge']({},_0x8b169c,_0x2564e4[_0x5513fe('0x38')]),db[_0x5513fe('0x33')][_0x5513fe('0x18')](_0x8b169c)[_0x5513fe('0x9')](handleEntityNotFound(_0xb22c9a,null))['then'](respondWithResult(_0xb22c9a,null))[_0x5513fe('0x2a')](handleError(_0xb22c9a,null));},exports[_0x2c183c('0xa')]=function(_0x161aaf,_0x5624e7){const _0x44b434=_0x2c183c;return _0x161aaf[_0x44b434('0x20')]['id']&&delete _0x161aaf['body']['id'],db['CannedAnswer'][_0x44b434('0x18')]({'where':{'id':_0x161aaf[_0x44b434('0x0')]['id']}})['then'](handleEntityNotFound(_0x5624e7,null))[_0x44b434('0x9')](saveUpdates(_0x161aaf[_0x44b434('0x20')],null))[_0x44b434('0x9')](respondWithResult(_0x5624e7,null))[_0x44b434('0x2a')](handleError(_0x5624e7,null));},exports['destroy']=function(_0x5d5cfb,_0x20b814){const _0x273e03=_0x2c183c;return db[_0x273e03('0x33')]['findOne']({'where':{'id':_0x5d5cfb[_0x273e03('0x0')]['id']}})[_0x273e03('0x9')](handleEntityNotFound(_0x20b814,null))['then'](removeEntity(_0x20b814,null))['catch'](handleError(_0x20b814,null));},exports[_0x2c183c('0x3c')]=function(_0x58ef4e,_0x192a87){const _0x361495=_0x2c183c,_0x368ba6={'key':_0x58ef4e[_0x361495('0x20')][_0x361495('0x17')]};if(_0x58ef4e[_0x361495('0x20')][_0x361495('0x12')])_0x368ba6[_0x361495('0x12')]=_0x58ef4e[_0x361495('0x20')][_0x361495('0x12')];else{if(_0x58ef4e[_0x361495('0x20')][_0x361495('0xd')])_0x368ba6[_0x361495('0xd')]=_0x58ef4e[_0x361495('0x20')][_0x361495('0xd')];else{if(_0x58ef4e[_0x361495('0x20')][_0x361495('0x24')])_0x368ba6[_0x361495('0x24')]=_0x58ef4e[_0x361495('0x20')]['OpenchannelAccountId'];else _0x58ef4e[_0x361495('0x20')][_0x361495('0x3d')]&&(_0x368ba6[_0x361495('0x3d')]=_0x58ef4e['body'][_0x361495('0x3d')]);}}return db[_0x361495('0x33')][_0x361495('0x18')]({'where':_0x368ba6})[_0x361495('0x9')](function(_0x4d16fc){if(_0x4d16fc)throw new ValidationError('The\x20inserted\x20key\x20already\x20exists.');return db['CannedAnswer']['create'](_0x58ef4e['body']);})[_0x361495('0x9')](function(_0x4765c9){const _0xd4dde1=_0x361495,_0x353d00=_0x58ef4e['user'][_0xd4dde1('0x19')]({'plain':!![]});if(!_0x353d00)throw new Error(_0xd4dde1('0x2c'));if(_0x353d00['role']==='user'){const _0xa6bcfd=_0x4765c9[_0xd4dde1('0x19')]({'plain':!![]});return db[_0xd4dde1('0x8')]['findOne']({'where':{'name':_0xd4dde1('0x1d'),'userProfileId':_0x353d00[_0xd4dde1('0x1f')]},'raw':!![]})[_0xd4dde1('0x9')](function(_0x34e5ea){const _0x326a96=_0xd4dde1;return _0x34e5ea&&_0x34e5ea[_0x326a96('0x1')]===0x0?db['UserProfileResource'][_0x326a96('0x3c')]({'name':_0xa6bcfd[_0x326a96('0x2')],'resourceId':_0xa6bcfd['id'],'type':_0x34e5ea[_0x326a96('0x2')],'sectionId':_0x34e5ea['id']},{})['then'](function(){return _0x4765c9;}):_0x4765c9;})['catch'](function(_0x25c5f6){const _0x3235f6=_0xd4dde1;logger['error'](_0x3235f6('0x34'),_0x25c5f6);throw _0x25c5f6;});}return _0x4765c9;})[_0x361495('0x9')](respondWithResult(_0x192a87,0xc9))[_0x361495('0x2a')](handleError(_0x192a87,null));}; \ No newline at end of file diff --git a/server/api/cannedAnswer/cannedAnswer.model.js b/server/api/cannedAnswer/cannedAnswer.model.js index 46cacb4..0bdf0d9 100644 --- a/server/api/cannedAnswer/cannedAnswer.model.js +++ b/server/api/cannedAnswer/cannedAnswer.model.js @@ -1 +1 @@ -const a48_0x2152=['tools_canned_answers','define','CannedAnswer','./cannedAnswer.attributes','utf8mb4_unicode_ci'];(function(_0x5f507f,_0x215289){const _0x5e7afa=function(_0xa2b29a){while(--_0xa2b29a){_0x5f507f['push'](_0x5f507f['shift']());}};_0x5e7afa(++_0x215289);}(a48_0x2152,0x12c));const a48_0x5e7a=function(_0x5f507f,_0x215289){_0x5f507f=_0x5f507f-0x0;let _0x5e7afa=a48_0x2152[_0x5f507f];return _0x5e7afa;};const _0xd0e19=a48_0x5e7a;'use strict';const attributes=require(_0xd0e19('0x3'));module['exports']=function(_0xa2b29a){const _0x4fd1db=_0xd0e19,_0x1ccc6f=_0xa2b29a[_0x4fd1db('0x1')](_0x4fd1db('0x2'),attributes,{'tableName':_0x4fd1db('0x0'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':'utf8mb4','collate':_0x4fd1db('0x4')});return _0x1ccc6f;}; \ No newline at end of file +const a48_0x3f4f=['utf8mb4_unicode_ci','tools_canned_answers','./cannedAnswer.attributes','utf8mb4','define'];(function(_0x181ad5,_0x3f4f28){const _0x3b616c=function(_0x2bde81){while(--_0x2bde81){_0x181ad5['push'](_0x181ad5['shift']());}};_0x3b616c(++_0x3f4f28);}(a48_0x3f4f,0x1b1));const a48_0x3b61=function(_0x181ad5,_0x3f4f28){_0x181ad5=_0x181ad5-0x0;let _0x3b616c=a48_0x3f4f[_0x181ad5];return _0x3b616c;};const _0x342ccd=a48_0x3b61;'use strict';const attributes=require(_0x342ccd('0x4'));module['exports']=function(_0x2bde81){const _0x4013fa=_0x342ccd,_0x1c1bb4=_0x2bde81[_0x4013fa('0x1')]('CannedAnswer',attributes,{'tableName':_0x4013fa('0x3'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x4013fa('0x0'),'collate':_0x4013fa('0x2')});return _0x1c1bb4;}; \ No newline at end of file diff --git a/server/api/cannedAnswer/index.js b/server/api/cannedAnswer/index.js index 03e259b..15f209e 100644 --- a/server/api/cannedAnswer/index.js +++ b/server/api/cannedAnswer/index.js @@ -1 +1 @@ -const a49_0xf608=['put','/:id','delete','isAuthenticated','exports','index','show','create','express','update','../../components/auth/service'];(function(_0x43bbb9,_0xf60861){const _0xcc4fae=function(_0x2cdf75){while(--_0x2cdf75){_0x43bbb9['push'](_0x43bbb9['shift']());}};_0xcc4fae(++_0xf60861);}(a49_0xf608,0x160));const a49_0xcc4f=function(_0x43bbb9,_0xf60861){_0x43bbb9=_0x43bbb9-0x0;let _0xcc4fae=a49_0xf608[_0x43bbb9];return _0xcc4fae;};const _0x5a6696=a49_0xcc4f;'use strict';const express=require(_0x5a6696('0x8')),router=express['Router'](),auth=require(_0x5a6696('0xa')),controller=require('./cannedAnswer.controller');router['get']('/',auth[_0x5a6696('0x3')](),controller[_0x5a6696('0x5')]),router['get']('/:id',auth[_0x5a6696('0x3')](),controller[_0x5a6696('0x6')]),router['post']('/',auth[_0x5a6696('0x3')](),controller[_0x5a6696('0x7')]),router[_0x5a6696('0x0')](_0x5a6696('0x1'),auth[_0x5a6696('0x3')](),controller[_0x5a6696('0x9')]),router[_0x5a6696('0x2')](_0x5a6696('0x1'),auth['isAuthenticated'](),controller['destroy']),module[_0x5a6696('0x4')]=router; \ No newline at end of file +const a49_0x5cec=['./cannedAnswer.controller','update','/:id','create','../../components/auth/service','put','isAuthenticated','Router','post','index','get'];(function(_0xf77d82,_0x5cec3c){const _0x5dd566=function(_0x5b0774){while(--_0x5b0774){_0xf77d82['push'](_0xf77d82['shift']());}};_0x5dd566(++_0x5cec3c);}(a49_0x5cec,0xe7));const a49_0x5dd5=function(_0xf77d82,_0x5cec3c){_0xf77d82=_0xf77d82-0x0;let _0x5dd566=a49_0x5cec[_0xf77d82];return _0x5dd566;};const _0x30c916=a49_0x5dd5;'use strict';const express=require('express'),router=express[_0x30c916('0x7')](),auth=require(_0x30c916('0x4')),controller=require(_0x30c916('0x0'));router[_0x30c916('0xa')]('/',auth[_0x30c916('0x6')](),controller[_0x30c916('0x9')]),router['get'](_0x30c916('0x2'),auth[_0x30c916('0x6')](),controller['show']),router[_0x30c916('0x8')]('/',auth[_0x30c916('0x6')](),controller[_0x30c916('0x3')]),router[_0x30c916('0x5')](_0x30c916('0x2'),auth[_0x30c916('0x6')](),controller[_0x30c916('0x1')]),router['delete'](_0x30c916('0x2'),auth[_0x30c916('0x6')](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/cdr/cdr.attributes.js b/server/api/cdr/cdr.attributes.js index 998d382..9eecbe8 100644 --- a/server/api/cdr/cdr.attributes.js +++ b/server/api/cdr/cdr.attributes.js @@ -1 +1 @@ -const a50_0x312e=['exports','sequelize','STRING','1970-01-01\x2000:00:01','INTEGER'];(function(_0x3ba319,_0x312ea8){const _0x183a21=function(_0x11420e){while(--_0x11420e){_0x3ba319['push'](_0x3ba319['shift']());}};_0x183a21(++_0x312ea8);}(a50_0x312e,0x7d));const a50_0x183a=function(_0x3ba319,_0x312ea8){_0x3ba319=_0x3ba319-0x0;let _0x183a21=a50_0x312e[_0x3ba319];return _0x183a21;};const _0x5e986c=a50_0x183a;'use strict';const Sequelize=require(_0x5e986c('0x1'));module[_0x5e986c('0x0')]={'calldate':{'type':Sequelize['DATE'],'allowNull':![],'defaultValue':_0x5e986c('0x3')},'clid':{'type':Sequelize[_0x5e986c('0x2')]},'src':{'type':Sequelize[_0x5e986c('0x2')]},'dst':{'type':Sequelize['STRING']},'dcontext':{'type':Sequelize['STRING']},'channel':{'type':Sequelize['STRING']},'dstchannel':{'type':Sequelize['STRING']},'lastapp':{'type':Sequelize[_0x5e986c('0x2')]},'lastdata':{'type':Sequelize[_0x5e986c('0x2')]},'duration':{'type':Sequelize[_0x5e986c('0x4')],'allowNull':![],'defaultValue':0x0},'billsec':{'type':Sequelize[_0x5e986c('0x4')],'allowNull':![],'defaultValue':0x0},'disposition':{'type':Sequelize[_0x5e986c('0x2')]},'amaflags':{'type':Sequelize['INTEGER'],'allowNull':![],'defaultValue':0x0},'accountcode':{'type':Sequelize['STRING']},'userfield':{'type':Sequelize[_0x5e986c('0x2')]},'uniqueid':{'type':Sequelize['STRING']},'linkedid':{'type':Sequelize[_0x5e986c('0x2')]},'sequence':{'type':Sequelize[_0x5e986c('0x2')]},'peeraccount':{'type':Sequelize['STRING']},'type':{'type':Sequelize[_0x5e986c('0x2')]},'tag':{'type':Sequelize[_0x5e986c('0x2')]}}; \ No newline at end of file +const a50_0x1059=['exports','STRING','sequelize','DATE','INTEGER'];(function(_0x2f6b8b,_0x10594f){const _0x152315=function(_0x3c42db){while(--_0x3c42db){_0x2f6b8b['push'](_0x2f6b8b['shift']());}};_0x152315(++_0x10594f);}(a50_0x1059,0x116));const a50_0x1523=function(_0x2f6b8b,_0x10594f){_0x2f6b8b=_0x2f6b8b-0x0;let _0x152315=a50_0x1059[_0x2f6b8b];return _0x152315;};const _0x2507a4=a50_0x1523;'use strict';const Sequelize=require(_0x2507a4('0x4'));module[_0x2507a4('0x2')]={'calldate':{'type':Sequelize[_0x2507a4('0x0')],'allowNull':![],'defaultValue':'1970-01-01\x2000:00:01'},'clid':{'type':Sequelize[_0x2507a4('0x3')]},'src':{'type':Sequelize[_0x2507a4('0x3')]},'dst':{'type':Sequelize['STRING']},'dcontext':{'type':Sequelize[_0x2507a4('0x3')]},'channel':{'type':Sequelize[_0x2507a4('0x3')]},'dstchannel':{'type':Sequelize[_0x2507a4('0x3')]},'lastapp':{'type':Sequelize['STRING']},'lastdata':{'type':Sequelize[_0x2507a4('0x3')]},'duration':{'type':Sequelize[_0x2507a4('0x1')],'allowNull':![],'defaultValue':0x0},'billsec':{'type':Sequelize[_0x2507a4('0x1')],'allowNull':![],'defaultValue':0x0},'disposition':{'type':Sequelize['STRING']},'amaflags':{'type':Sequelize[_0x2507a4('0x1')],'allowNull':![],'defaultValue':0x0},'accountcode':{'type':Sequelize[_0x2507a4('0x3')]},'userfield':{'type':Sequelize['STRING']},'uniqueid':{'type':Sequelize['STRING']},'linkedid':{'type':Sequelize['STRING']},'sequence':{'type':Sequelize[_0x2507a4('0x3')]},'peeraccount':{'type':Sequelize[_0x2507a4('0x3')]},'type':{'type':Sequelize[_0x2507a4('0x3')]},'tag':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/cdr/cdr.controller.js b/server/api/cdr/cdr.controller.js index bab118f..1adb801 100644 --- a/server/api/cdr/cdr.controller.js +++ b/server/api/cdr/cdr.controller.js @@ -1 +1 @@ -const a51_0x1279=['end','index','length','limit','error','then','fields','findOne','Cdr','model','attributes','intersection','keys','pick','offset','../../config/logger','count','fieldName','filter','order','includeAll','type','show','name','catch','like','stack','set','update','undefined','destroy','api','Content-Range','findAll','rows','query','create','merge','filters','options','VIRTUAL','body','../../components/parsers/qs','where','include','status','map','params','describe','send','key','lodash'];(function(_0xd9bd65,_0x127981){const _0x72b19c=function(_0x51d545){while(--_0x51d545){_0xd9bd65['push'](_0xd9bd65['shift']());}};_0x72b19c(++_0x127981);}(a51_0x1279,0xf2));const a51_0x72b1=function(_0xd9bd65,_0x127981){_0xd9bd65=_0xd9bd65-0x0;let _0x72b19c=a51_0x1279[_0xd9bd65];return _0x72b19c;};const _0x200bb5=a51_0x72b1;'use strict';const _=require(_0x200bb5('0x11')),qs=require(_0x200bb5('0x8')),logger=require(_0x200bb5('0x21'))(_0x200bb5('0x31')),db=require('../../mysqldb')['db'],{Op}=require('sequelize');function respondWithResult(_0x51d545,_0x5874a2){return _0x5874a2=_0x5874a2||0xc8,function(_0x153aae){const _0x5150bf=a51_0x72b1;if(_0x153aae)return _0x51d545[_0x5150bf('0xb')](_0x5874a2)['json'](_0x153aae);};}function respondWithFilteredResult(_0x2fe282,_0x44fa74){return function(_0x813d02){const _0x42eccd=a51_0x72b1;if(_0x813d02){const _0x5ac086=_0x813d02['count'],_0x2415da=_0x44fa74[_0x42eccd('0x20')];let _0xcdc941=_0x44fa74[_0x42eccd('0x20')]+_0x44fa74['limit'],_0xe1c1b9;return _0xcdc941>=_0x5ac086?(_0xcdc941=_0x5ac086,_0xe1c1b9=0xc8):_0xe1c1b9=0xce,_0x2fe282['status'](_0xe1c1b9),_0x2fe282[_0x42eccd('0x2d')](_0x42eccd('0x32'),_0x2415da+'-'+_0xcdc941+'/'+_0x5ac086)['json'](_0x813d02);}return null;};}function saveUpdates(_0x79d333){return function(_0x3b0ed8){const _0x5e9358=a51_0x72b1;if(_0x3b0ed8)return _0x3b0ed8['update'](_0x79d333)[_0x5e9358('0x17')](function(_0x2c74d5){return _0x2c74d5;});return null;};}function removeEntity(_0x5324c5){return function(_0xeffbe7){const _0xa5b540=a51_0x72b1;if(_0xeffbe7)return _0xeffbe7[_0xa5b540('0x30')]()[_0xa5b540('0x17')](function(){const _0x40f1ed=_0xa5b540;_0x5324c5['status'](0xcc)[_0x40f1ed('0x12')]();});};}function handleEntityNotFound(_0x1b3b05){return function(_0x471f7b){return!_0x471f7b&&_0x1b3b05['sendStatus'](0x194),_0x471f7b;};}function handleError(_0x434115,_0x46d0b7){return _0x46d0b7=_0x46d0b7||0x1f4,function(_0x2fe6dd){const _0x205e81=a51_0x72b1;logger[_0x205e81('0x16')](_0x2fe6dd[_0x205e81('0x2c')]),_0x2fe6dd[_0x205e81('0x29')]&&delete _0x2fe6dd[_0x205e81('0x29')],_0x434115[_0x205e81('0xb')](_0x46d0b7)[_0x205e81('0xf')](_0x2fe6dd);};}exports[_0x200bb5('0x13')]=function(_0x15f058,_0x102705){const _0x2a4cf1=_0x200bb5;let _0x5eab57={};const _0x515301={},_0x311aad={'count':0x0,'rows':[]},_0x1ee39c=_['map'](db[_0x2a4cf1('0x1a')]['rawAttributes'],function(_0x502f3d){const _0xf1b082=_0x2a4cf1;return{'name':_0x502f3d[_0xf1b082('0x23')],'type':_0x502f3d[_0xf1b082('0x27')][_0xf1b082('0x10')]};});_0x515301[_0x2a4cf1('0x1b')]=_[_0x2a4cf1('0xc')](_0x1ee39c,_0x2a4cf1('0x29')),_0x515301[_0x2a4cf1('0x1')]=_[_0x2a4cf1('0x1e')](_0x15f058['query']),_0x515301[_0x2a4cf1('0x4')]=_[_0x2a4cf1('0x1d')](_0x515301[_0x2a4cf1('0x1b')],_0x515301[_0x2a4cf1('0x1')]),_0x5eab57[_0x2a4cf1('0x1c')]=_[_0x2a4cf1('0x1d')](_0x515301[_0x2a4cf1('0x1b')],qs[_0x2a4cf1('0x18')](_0x15f058[_0x2a4cf1('0x1')][_0x2a4cf1('0x18')])),_0x5eab57['attributes']=_0x5eab57[_0x2a4cf1('0x1c')][_0x2a4cf1('0x14')]?_0x5eab57[_0x2a4cf1('0x1c')]:_0x515301[_0x2a4cf1('0x1b')];typeof _0x15f058[_0x2a4cf1('0x1')]['nolimit']===_0x2a4cf1('0x2f')&&(_0x5eab57[_0x2a4cf1('0x15')]=qs['limit'](_0x15f058[_0x2a4cf1('0x1')][_0x2a4cf1('0x15')]),_0x5eab57['offset']=qs[_0x2a4cf1('0x20')](_0x15f058[_0x2a4cf1('0x1')][_0x2a4cf1('0x20')]));_0x5eab57[_0x2a4cf1('0x25')]=qs['sort'](_0x15f058[_0x2a4cf1('0x1')]['sort']),_0x5eab57[_0x2a4cf1('0x9')]=qs[_0x2a4cf1('0x4')](_[_0x2a4cf1('0x1f')](_0x15f058['query'],_0x515301[_0x2a4cf1('0x4')]),_0x1ee39c);_0x15f058[_0x2a4cf1('0x1')][_0x2a4cf1('0x24')]&&(_0x5eab57['where']=_['merge'](_0x5eab57[_0x2a4cf1('0x9')],{[Op['or']]:_[_0x2a4cf1('0xc')](_0x1ee39c,function(_0x1cc6d5){const _0x3cc76d=_0x2a4cf1;if(_0x1cc6d5['type']!==_0x3cc76d('0x6')){const _0x20512b={};return _0x20512b[_0x1cc6d5[_0x3cc76d('0x29')]]={[Op[_0x3cc76d('0x2b')]]:'%'+_0x15f058[_0x3cc76d('0x1')][_0x3cc76d('0x24')]+'%'},_0x20512b;}})}));_0x5eab57=_['merge']({},_0x5eab57,_0x15f058[_0x2a4cf1('0x5')]);const _0x241c1a={'where':_0x5eab57[_0x2a4cf1('0x9')]};return db[_0x2a4cf1('0x1a')]['count'](_0x241c1a)['then'](function(_0x1ef784){const _0x3902d0=_0x2a4cf1;return _0x311aad[_0x3902d0('0x22')]=_0x1ef784,_0x15f058[_0x3902d0('0x1')][_0x3902d0('0x26')]&&(_0x5eab57[_0x3902d0('0xa')]=[{'all':!![]}]),db[_0x3902d0('0x1a')][_0x3902d0('0x33')](_0x5eab57);})[_0x2a4cf1('0x17')](function(_0x12fe3d){const _0x5d4b43=_0x2a4cf1;return _0x311aad[_0x5d4b43('0x0')]=_0x12fe3d,_0x311aad;})[_0x2a4cf1('0x17')](respondWithFilteredResult(_0x102705,_0x5eab57))[_0x2a4cf1('0x2a')](handleError(_0x102705,null));},exports[_0x200bb5('0x28')]=function(_0x17b20b,_0x2d27c2){const _0x1eb23f=_0x200bb5;let _0x5389cd={'raw':!![],'where':{'id':_0x17b20b['params']['id']}};const _0x3c6af8={};return _0x3c6af8[_0x1eb23f('0x1b')]=_[_0x1eb23f('0x1e')](db[_0x1eb23f('0x1a')]['rawAttributes']),_0x3c6af8[_0x1eb23f('0x1')]=_[_0x1eb23f('0x1e')](_0x17b20b[_0x1eb23f('0x1')]),_0x3c6af8[_0x1eb23f('0x4')]=_[_0x1eb23f('0x1d')](_0x3c6af8['model'],_0x3c6af8[_0x1eb23f('0x1')]),_0x5389cd['attributes']=_[_0x1eb23f('0x1d')](_0x3c6af8[_0x1eb23f('0x1b')],qs[_0x1eb23f('0x18')](_0x17b20b[_0x1eb23f('0x1')][_0x1eb23f('0x18')])),_0x5389cd[_0x1eb23f('0x1c')]=_0x5389cd[_0x1eb23f('0x1c')]['length']?_0x5389cd[_0x1eb23f('0x1c')]:_0x3c6af8['model'],_0x17b20b[_0x1eb23f('0x1')][_0x1eb23f('0x26')]&&(_0x5389cd[_0x1eb23f('0xa')]=[{'all':!![]}]),_0x5389cd=_[_0x1eb23f('0x3')]({},_0x5389cd,_0x17b20b['options']),db[_0x1eb23f('0x1a')][_0x1eb23f('0x19')](_0x5389cd)[_0x1eb23f('0x17')](handleEntityNotFound(_0x2d27c2,null))[_0x1eb23f('0x17')](respondWithResult(_0x2d27c2,null))[_0x1eb23f('0x2a')](handleError(_0x2d27c2,null));},exports[_0x200bb5('0x2')]=function(_0x483803,_0x898a7c){const _0x25d062=_0x200bb5;return db[_0x25d062('0x1a')][_0x25d062('0x2')](_0x483803[_0x25d062('0x7')],{})[_0x25d062('0x17')](respondWithResult(_0x898a7c,0xc9))[_0x25d062('0x2a')](handleError(_0x898a7c,null));},exports[_0x200bb5('0x2e')]=function(_0x4a3514,_0x2b3877){const _0x4ea536=_0x200bb5;return _0x4a3514[_0x4ea536('0x7')]['id']&&delete _0x4a3514['body']['id'],db[_0x4ea536('0x1a')][_0x4ea536('0x19')]({'where':{'id':_0x4a3514[_0x4ea536('0xd')]['id']}})['then'](handleEntityNotFound(_0x2b3877,null))[_0x4ea536('0x17')](saveUpdates(_0x4a3514[_0x4ea536('0x7')],null))[_0x4ea536('0x17')](respondWithResult(_0x2b3877,null))[_0x4ea536('0x2a')](handleError(_0x2b3877,null));},exports[_0x200bb5('0x30')]=function(_0x241a51,_0x5c0ee8){const _0x55c4b6=_0x200bb5;return db[_0x55c4b6('0x1a')][_0x55c4b6('0x19')]({'where':{'id':_0x241a51[_0x55c4b6('0xd')]['id']}})[_0x55c4b6('0x17')](handleEntityNotFound(_0x5c0ee8,null))[_0x55c4b6('0x17')](removeEntity(_0x5c0ee8,null))[_0x55c4b6('0x2a')](handleError(_0x5c0ee8,null));},exports['describe']=function(_0xbe37f,_0x374374){const _0x58219d=_0x200bb5;return db['Cdr'][_0x58219d('0xe')]()[_0x58219d('0x17')](respondWithResult(_0x374374,null))[_0x58219d('0x2a')](handleError(_0x374374,null));}; \ No newline at end of file +const a51_0x2785=['count','intersection','catch','fields','sort','merge','sendStatus','error','end','attributes','Content-Range','nolimit','destroy','filters','keys','map','query','includeAll','sequelize','rows','include','../../components/parsers/qs','rawAttributes','then','name','offset','like','status','describe','lodash','options','pick','filter','type','limit','fieldName','index','params','order','stack','Cdr','where','create','undefined','body','key','length','model','api','update','findOne','../../config/logger','VIRTUAL'];(function(_0x2e23b2,_0x27857a){const _0x2020c2=function(_0x142d1a){while(--_0x142d1a){_0x2e23b2['push'](_0x2e23b2['shift']());}};_0x2020c2(++_0x27857a);}(a51_0x2785,0x147));const a51_0x2020=function(_0x2e23b2,_0x27857a){_0x2e23b2=_0x2e23b2-0x0;let _0x2020c2=a51_0x2785[_0x2e23b2];return _0x2020c2;};const _0x2f3b1c=a51_0x2020;'use strict';const _=require(_0x2f3b1c('0x14')),qs=require(_0x2f3b1c('0xc')),logger=require(_0x2f3b1c('0x2a'))(_0x2f3b1c('0x27')),db=require('../../mysqldb')['db'],{Op}=require(_0x2f3b1c('0x9'));function respondWithResult(_0x142d1a,_0x8f0604){return _0x8f0604=_0x8f0604||0xc8,function(_0x19cbf1){const _0x5904f5=a51_0x2020;if(_0x19cbf1)return _0x142d1a[_0x5904f5('0x12')](_0x8f0604)['json'](_0x19cbf1);};}function respondWithFilteredResult(_0x3be361,_0x161cf0){return function(_0x3cba52){const _0x14cdf4=a51_0x2020;if(_0x3cba52){const _0x4117e7=_0x3cba52[_0x14cdf4('0x2c')],_0x1f39ae=_0x161cf0[_0x14cdf4('0x10')];let _0x185eb4=_0x161cf0[_0x14cdf4('0x10')]+_0x161cf0[_0x14cdf4('0x19')],_0x189d54;return _0x185eb4>=_0x4117e7?(_0x185eb4=_0x4117e7,_0x189d54=0xc8):_0x189d54=0xce,_0x3be361['status'](_0x189d54),_0x3be361['set'](_0x14cdf4('0x1'),_0x1f39ae+'-'+_0x185eb4+'/'+_0x4117e7)['json'](_0x3cba52);}return null;};}function saveUpdates(_0x36d2ab){return function(_0x5032a8){const _0x332b38=a51_0x2020;if(_0x5032a8)return _0x5032a8[_0x332b38('0x28')](_0x36d2ab)[_0x332b38('0xe')](function(_0x4ebd63){return _0x4ebd63;});return null;};}function removeEntity(_0x56e7bc){return function(_0x1aa526){const _0x24eafc=a51_0x2020;if(_0x1aa526)return _0x1aa526['destroy']()[_0x24eafc('0xe')](function(){const _0x4cf0cd=_0x24eafc;_0x56e7bc['status'](0xcc)[_0x4cf0cd('0x34')]();});};}function handleEntityNotFound(_0x116eac){return function(_0x4ce3ef){const _0xef6103=a51_0x2020;return!_0x4ce3ef&&_0x116eac[_0xef6103('0x32')](0x194),_0x4ce3ef;};}function handleError(_0x40f56c,_0x3885cc){return _0x3885cc=_0x3885cc||0x1f4,function(_0x5bef13){const _0xd30dfb=a51_0x2020;logger[_0xd30dfb('0x33')](_0x5bef13[_0xd30dfb('0x1e')]),_0x5bef13['name']&&delete _0x5bef13[_0xd30dfb('0xf')],_0x40f56c[_0xd30dfb('0x12')](_0x3885cc)['send'](_0x5bef13);};}exports[_0x2f3b1c('0x1b')]=function(_0x3c322c,_0x5a39b1){const _0x18d531=_0x2f3b1c;let _0xe1a7ba={};const _0x29fa07={},_0x2b28e2={'count':0x0,'rows':[]},_0x280414=_[_0x18d531('0x6')](db['Cdr'][_0x18d531('0xd')],function(_0x5ec344){const _0x1a0695=_0x18d531;return{'name':_0x5ec344[_0x1a0695('0x1a')],'type':_0x5ec344[_0x1a0695('0x18')][_0x1a0695('0x24')]};});_0x29fa07[_0x18d531('0x26')]=_[_0x18d531('0x6')](_0x280414,'name'),_0x29fa07['query']=_['keys'](_0x3c322c[_0x18d531('0x7')]),_0x29fa07[_0x18d531('0x4')]=_[_0x18d531('0x2d')](_0x29fa07[_0x18d531('0x26')],_0x29fa07[_0x18d531('0x7')]),_0xe1a7ba[_0x18d531('0x0')]=_[_0x18d531('0x2d')](_0x29fa07['model'],qs['fields'](_0x3c322c['query']['fields'])),_0xe1a7ba[_0x18d531('0x0')]=_0xe1a7ba[_0x18d531('0x0')][_0x18d531('0x25')]?_0xe1a7ba[_0x18d531('0x0')]:_0x29fa07['model'];typeof _0x3c322c[_0x18d531('0x7')][_0x18d531('0x2')]===_0x18d531('0x22')&&(_0xe1a7ba['limit']=qs[_0x18d531('0x19')](_0x3c322c[_0x18d531('0x7')]['limit']),_0xe1a7ba[_0x18d531('0x10')]=qs[_0x18d531('0x10')](_0x3c322c['query']['offset']));_0xe1a7ba[_0x18d531('0x1d')]=qs['sort'](_0x3c322c[_0x18d531('0x7')][_0x18d531('0x30')]),_0xe1a7ba['where']=qs[_0x18d531('0x4')](_[_0x18d531('0x16')](_0x3c322c[_0x18d531('0x7')],_0x29fa07[_0x18d531('0x4')]),_0x280414);_0x3c322c[_0x18d531('0x7')][_0x18d531('0x17')]&&(_0xe1a7ba['where']=_[_0x18d531('0x31')](_0xe1a7ba[_0x18d531('0x20')],{[Op['or']]:_[_0x18d531('0x6')](_0x280414,function(_0xb617d1){const _0x218dc3=_0x18d531;if(_0xb617d1[_0x218dc3('0x18')]!==_0x218dc3('0x2b')){const _0x209009={};return _0x209009[_0xb617d1['name']]={[Op[_0x218dc3('0x11')]]:'%'+_0x3c322c[_0x218dc3('0x7')][_0x218dc3('0x17')]+'%'},_0x209009;}})}));_0xe1a7ba=_['merge']({},_0xe1a7ba,_0x3c322c[_0x18d531('0x15')]);const _0x2b6b9e={'where':_0xe1a7ba[_0x18d531('0x20')]};return db[_0x18d531('0x1f')][_0x18d531('0x2c')](_0x2b6b9e)['then'](function(_0x252cb6){const _0x481c64=_0x18d531;return _0x2b28e2['count']=_0x252cb6,_0x3c322c[_0x481c64('0x7')][_0x481c64('0x8')]&&(_0xe1a7ba[_0x481c64('0xb')]=[{'all':!![]}]),db['Cdr']['findAll'](_0xe1a7ba);})[_0x18d531('0xe')](function(_0x2c3d85){const _0x46806c=_0x18d531;return _0x2b28e2[_0x46806c('0xa')]=_0x2c3d85,_0x2b28e2;})[_0x18d531('0xe')](respondWithFilteredResult(_0x5a39b1,_0xe1a7ba))[_0x18d531('0x2e')](handleError(_0x5a39b1,null));},exports['show']=function(_0x14bf43,_0x43dff7){const _0x5a2887=_0x2f3b1c;let _0x24e388={'raw':!![],'where':{'id':_0x14bf43['params']['id']}};const _0x174b46={};return _0x174b46['model']=_[_0x5a2887('0x5')](db[_0x5a2887('0x1f')][_0x5a2887('0xd')]),_0x174b46['query']=_[_0x5a2887('0x5')](_0x14bf43['query']),_0x174b46[_0x5a2887('0x4')]=_[_0x5a2887('0x2d')](_0x174b46[_0x5a2887('0x26')],_0x174b46['query']),_0x24e388[_0x5a2887('0x0')]=_[_0x5a2887('0x2d')](_0x174b46['model'],qs['fields'](_0x14bf43[_0x5a2887('0x7')][_0x5a2887('0x2f')])),_0x24e388[_0x5a2887('0x0')]=_0x24e388[_0x5a2887('0x0')][_0x5a2887('0x25')]?_0x24e388['attributes']:_0x174b46['model'],_0x14bf43[_0x5a2887('0x7')][_0x5a2887('0x8')]&&(_0x24e388[_0x5a2887('0xb')]=[{'all':!![]}]),_0x24e388=_[_0x5a2887('0x31')]({},_0x24e388,_0x14bf43[_0x5a2887('0x15')]),db['Cdr']['findOne'](_0x24e388)['then'](handleEntityNotFound(_0x43dff7,null))[_0x5a2887('0xe')](respondWithResult(_0x43dff7,null))[_0x5a2887('0x2e')](handleError(_0x43dff7,null));},exports[_0x2f3b1c('0x21')]=function(_0x40541,_0x1b4adf){const _0x1afdd9=_0x2f3b1c;return db['Cdr'][_0x1afdd9('0x21')](_0x40541[_0x1afdd9('0x23')],{})[_0x1afdd9('0xe')](respondWithResult(_0x1b4adf,0xc9))[_0x1afdd9('0x2e')](handleError(_0x1b4adf,null));},exports[_0x2f3b1c('0x28')]=function(_0x4fc79f,_0x453d4d){const _0xfb0536=_0x2f3b1c;return _0x4fc79f[_0xfb0536('0x23')]['id']&&delete _0x4fc79f[_0xfb0536('0x23')]['id'],db[_0xfb0536('0x1f')]['findOne']({'where':{'id':_0x4fc79f['params']['id']}})[_0xfb0536('0xe')](handleEntityNotFound(_0x453d4d,null))[_0xfb0536('0xe')](saveUpdates(_0x4fc79f[_0xfb0536('0x23')],null))[_0xfb0536('0xe')](respondWithResult(_0x453d4d,null))['catch'](handleError(_0x453d4d,null));},exports[_0x2f3b1c('0x3')]=function(_0x2140e4,_0x333064){const _0x4e2524=_0x2f3b1c;return db[_0x4e2524('0x1f')][_0x4e2524('0x29')]({'where':{'id':_0x2140e4[_0x4e2524('0x1c')]['id']}})[_0x4e2524('0xe')](handleEntityNotFound(_0x333064,null))[_0x4e2524('0xe')](removeEntity(_0x333064,null))[_0x4e2524('0x2e')](handleError(_0x333064,null));},exports[_0x2f3b1c('0x13')]=function(_0x2b5d86,_0x508c0b){const _0x17a2ad=_0x2f3b1c;return db['Cdr'][_0x17a2ad('0x13')]()[_0x17a2ad('0xe')](respondWithResult(_0x508c0b,null))[_0x17a2ad('0x2e')](handleError(_0x508c0b,null));}; \ No newline at end of file diff --git a/server/api/cdr/cdr.model.js b/server/api/cdr/cdr.model.js index de2bef1..89840c2 100644 --- a/server/api/cdr/cdr.model.js +++ b/server/api/cdr/cdr.model.js @@ -1 +1 @@ -const a52_0x5b32=['disposition','dst','define','exports','./cdr.attributes','uniqueid','src'];(function(_0x3bcf10,_0x5b3230){const _0x4e89ab=function(_0x49caa0){while(--_0x49caa0){_0x3bcf10['push'](_0x3bcf10['shift']());}};_0x4e89ab(++_0x5b3230);}(a52_0x5b32,0xee));const a52_0x4e89=function(_0x3bcf10,_0x5b3230){_0x3bcf10=_0x3bcf10-0x0;let _0x4e89ab=a52_0x5b32[_0x3bcf10];return _0x4e89ab;};const _0x126937=a52_0x4e89;'use strict';const attributes=require(_0x126937('0x4'));module[_0x126937('0x3')]=function(_0x49caa0){const _0x2ba571=_0x126937,_0x14abf9=_0x49caa0[_0x2ba571('0x2')]('Cdr',attributes,{'tableName':'cdr','paranoid':![],'indexes':[{'name':'accountcode','fields':['accountcode']},{'name':'calldate','fields':['calldate']},{'name':_0x2ba571('0x0'),'fields':[_0x2ba571('0x0')]},{'name':_0x2ba571('0x1'),'fields':[_0x2ba571('0x1')]},{'name':_0x2ba571('0x6'),'fields':[_0x2ba571('0x6')]},{'name':_0x2ba571('0x5'),'fields':[_0x2ba571('0x5')]}],'timestamps':![]});return _0x14abf9;}; \ No newline at end of file +const a52_0x2d0b=['dst','exports','accountcode','calldate','Cdr','cdr','uniqueid','src','disposition','define'];(function(_0x540165,_0x2d0b1){const _0x39fb2e=function(_0x2580a0){while(--_0x2580a0){_0x540165['push'](_0x540165['shift']());}};_0x39fb2e(++_0x2d0b1);}(a52_0x2d0b,0x1a2));const a52_0x39fb=function(_0x540165,_0x2d0b1){_0x540165=_0x540165-0x0;let _0x39fb2e=a52_0x2d0b[_0x540165];return _0x39fb2e;};const _0x5f0518=a52_0x39fb;'use strict';const attributes=require('./cdr.attributes');module[_0x5f0518('0x3')]=function(_0x2580a0){const _0xa67f79=_0x5f0518,_0x1bb39d=_0x2580a0[_0xa67f79('0x1')](_0xa67f79('0x6'),attributes,{'tableName':_0xa67f79('0x7'),'paranoid':![],'indexes':[{'name':_0xa67f79('0x4'),'fields':[_0xa67f79('0x4')]},{'name':_0xa67f79('0x5'),'fields':[_0xa67f79('0x5')]},{'name':_0xa67f79('0x0'),'fields':[_0xa67f79('0x0')]},{'name':_0xa67f79('0x2'),'fields':[_0xa67f79('0x2')]},{'name':_0xa67f79('0x9'),'fields':['src']},{'name':_0xa67f79('0x8'),'fields':[_0xa67f79('0x8')]}],'timestamps':![]});return _0x1bb39d;}; \ No newline at end of file diff --git a/server/api/cdr/index.js b/server/api/cdr/index.js index dc3e1ed..b46e095 100644 --- a/server/api/cdr/index.js +++ b/server/api/cdr/index.js @@ -1 +1 @@ -const a53_0x5b22=['exports','update','get','./cdr.controller','delete','/:id','index','/describe','show','destroy','express','isAuthenticated','Router','../../components/auth/service','describe'];(function(_0x15dd2a,_0x5b2236){const _0x5ee53b=function(_0x459491){while(--_0x459491){_0x15dd2a['push'](_0x15dd2a['shift']());}};_0x5ee53b(++_0x5b2236);}(a53_0x5b22,0x178));const a53_0x5ee5=function(_0x15dd2a,_0x5b2236){_0x15dd2a=_0x15dd2a-0x0;let _0x5ee53b=a53_0x5b22[_0x15dd2a];return _0x5ee53b;};const _0x355cb6=a53_0x5ee5;'use strict';const express=require(_0x355cb6('0x9')),router=express[_0x355cb6('0xb')](),auth=require(_0x355cb6('0xc')),controller=require(_0x355cb6('0x2'));router['get']('/',auth[_0x355cb6('0xa')](),controller[_0x355cb6('0x5')]),router[_0x355cb6('0x1')](_0x355cb6('0x6'),auth[_0x355cb6('0xa')](),controller[_0x355cb6('0xd')]),router[_0x355cb6('0x1')](_0x355cb6('0x4'),auth[_0x355cb6('0xa')](),controller[_0x355cb6('0x7')]),router['post']('/',auth['isAuthenticated'](),controller['create']),router['put'](_0x355cb6('0x4'),auth[_0x355cb6('0xa')](),controller[_0x355cb6('0x0')]),router[_0x355cb6('0x3')](_0x355cb6('0x4'),auth[_0x355cb6('0xa')](),controller[_0x355cb6('0x8')]),module[_0x355cb6('0xe')]=router; \ No newline at end of file +const a53_0x1ce0=['create','describe','./cdr.controller','show','put','../../components/auth/service','destroy','get','express','/describe','Router','/:id','isAuthenticated'];(function(_0x2e0580,_0x1ce08f){const _0x4d6518=function(_0x3ab86b){while(--_0x3ab86b){_0x2e0580['push'](_0x2e0580['shift']());}};_0x4d6518(++_0x1ce08f);}(a53_0x1ce0,0x15e));const a53_0x4d65=function(_0x2e0580,_0x1ce08f){_0x2e0580=_0x2e0580-0x0;let _0x4d6518=a53_0x1ce0[_0x2e0580];return _0x4d6518;};const _0xcd1177=a53_0x4d65;'use strict';const express=require(_0xcd1177('0x9')),router=express[_0xcd1177('0xb')](),auth=require(_0xcd1177('0x6')),controller=require(_0xcd1177('0x3'));router[_0xcd1177('0x8')]('/',auth[_0xcd1177('0x0')](),controller['index']),router[_0xcd1177('0x8')](_0xcd1177('0xa'),auth[_0xcd1177('0x0')](),controller[_0xcd1177('0x2')]),router['get'](_0xcd1177('0xc'),auth['isAuthenticated'](),controller[_0xcd1177('0x4')]),router['post']('/',auth[_0xcd1177('0x0')](),controller[_0xcd1177('0x1')]),router[_0xcd1177('0x5')](_0xcd1177('0xc'),auth[_0xcd1177('0x0')](),controller['update']),router['delete'](_0xcd1177('0xc'),auth[_0xcd1177('0x0')](),controller[_0xcd1177('0x7')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/chatApplication/chatApplication.attributes.js b/server/api/chatApplication/chatApplication.attributes.js index 88e42e6..fa69126 100644 --- a/server/api/chatApplication/chatApplication.attributes.js +++ b/server/api/chatApplication/chatApplication.attributes.js @@ -1 +1 @@ -const a54_0x2b7f=['STRING','noop','exports','TEXT','INTEGER'];(function(_0x117408,_0x2b7f27){const _0xe7c2ef=function(_0x53eea5){while(--_0x53eea5){_0x117408['push'](_0x117408['shift']());}};_0xe7c2ef(++_0x2b7f27);}(a54_0x2b7f,0xd9));const a54_0xe7c2=function(_0x117408,_0x2b7f27){_0x117408=_0x117408-0x0;let _0xe7c2ef=a54_0x2b7f[_0x117408];return _0xe7c2ef;};const _0x282fce=a54_0xe7c2;'use strict';const Sequelize=require('sequelize');module[_0x282fce('0x0')]={'priority':{'type':Sequelize[_0x282fce('0x2')],'allowNull':![]},'app':{'type':Sequelize[_0x282fce('0x3')],'allowNull':![],'defaultValue':_0x282fce('0x4')},'appdata':{'type':Sequelize[_0x282fce('0x1')]()},'description':{'type':Sequelize[_0x282fce('0x3')]},'interval':{'type':Sequelize['STRING'],'defaultValue':'*,*,*,*'}}; \ No newline at end of file +const a54_0xf01b=['INTEGER','sequelize','noop','STRING','exports'];(function(_0x3d41b3,_0xf01b7d){const _0xc2bb6e=function(_0x71451b){while(--_0x71451b){_0x3d41b3['push'](_0x3d41b3['shift']());}};_0xc2bb6e(++_0xf01b7d);}(a54_0xf01b,0x1d4));const a54_0xc2bb=function(_0x3d41b3,_0xf01b7d){_0x3d41b3=_0x3d41b3-0x0;let _0xc2bb6e=a54_0xf01b[_0x3d41b3];return _0xc2bb6e;};const _0x10180a=a54_0xc2bb;'use strict';const Sequelize=require(_0x10180a('0x3'));module[_0x10180a('0x1')]={'priority':{'type':Sequelize[_0x10180a('0x2')],'allowNull':![]},'app':{'type':Sequelize[_0x10180a('0x0')],'allowNull':![],'defaultValue':_0x10180a('0x4')},'appdata':{'type':Sequelize['TEXT']()},'description':{'type':Sequelize[_0x10180a('0x0')]},'interval':{'type':Sequelize[_0x10180a('0x0')],'defaultValue':'*,*,*,*'}}; \ No newline at end of file diff --git a/server/api/chatApplication/chatApplication.controller.js b/server/api/chatApplication/chatApplication.controller.js index 1bd1f25..0cb4032 100644 --- a/server/api/chatApplication/chatApplication.controller.js +++ b/server/api/chatApplication/chatApplication.controller.js @@ -1 +1 @@ -const a55_0x3465=['catch','../../mysqldb','update','then','include','rawAttributes','api','sendStatus','ChatApplication','stack','body','options','destroy','json','show','name','keys','query','fields','intersection','findOne','../../config/logger','model','attributes','status','includeAll','send','lodash'];(function(_0x468d28,_0x346516){const _0x3566ac=function(_0x4df831){while(--_0x4df831){_0x468d28['push'](_0x468d28['shift']());}};_0x3566ac(++_0x346516);}(a55_0x3465,0x177));const a55_0x3566=function(_0x468d28,_0x346516){_0x468d28=_0x468d28-0x0;let _0x3566ac=a55_0x3465[_0x468d28];return _0x3566ac;};const _0x326ea9=a55_0x3566;'use strict';const _=require(_0x326ea9('0x10')),qs=require('../../components/parsers/qs'),logger=require(_0x326ea9('0xa'))(_0x326ea9('0x17')),db=require(_0x326ea9('0x12'))['db'];function respondWithResult(_0x4df831,_0x289dd4){return _0x289dd4=_0x289dd4||0xc8,function(_0x4289ca){const _0x2264e0=a55_0x3566;if(_0x4289ca)return _0x4df831[_0x2264e0('0xd')](_0x289dd4)[_0x2264e0('0x2')](_0x4289ca);};}function saveUpdates(_0x246194){return function(_0x299b5d){const _0x5e6d77=a55_0x3566;if(_0x299b5d)return _0x299b5d[_0x5e6d77('0x13')](_0x246194)['then'](function(_0x13ab62){return _0x13ab62;});return null;};}function removeEntity(_0x351aaa){return function(_0x23ee40){const _0x317338=a55_0x3566;if(_0x23ee40)return _0x23ee40[_0x317338('0x1')]()['then'](function(){const _0x2dae1c=_0x317338;_0x351aaa[_0x2dae1c('0xd')](0xcc)['end']();});};}function handleEntityNotFound(_0x475140){return function(_0x29ebad){const _0xb613ac=a55_0x3566;return!_0x29ebad&&_0x475140[_0xb613ac('0x18')](0x194),_0x29ebad;};}function handleError(_0x22d730,_0x16fa3a){return _0x16fa3a=_0x16fa3a||0x1f4,function(_0x957da0){const _0x9558b3=a55_0x3566;logger['error'](_0x957da0[_0x9558b3('0x1a')]),_0x957da0[_0x9558b3('0x4')]&&delete _0x957da0['name'],_0x22d730[_0x9558b3('0xd')](_0x16fa3a)[_0x9558b3('0xf')](_0x957da0);};}exports[_0x326ea9('0x3')]=function(_0x51e36d,_0x5bcec5){const _0x2ecb2e=_0x326ea9;let _0x2e6f2e={'raw':!![],'where':{'id':_0x51e36d['params']['id']}};const _0x1711d6={};return _0x1711d6[_0x2ecb2e('0xb')]=_[_0x2ecb2e('0x5')](db[_0x2ecb2e('0x19')][_0x2ecb2e('0x16')]),_0x1711d6[_0x2ecb2e('0x6')]=_['keys'](_0x51e36d[_0x2ecb2e('0x6')]),_0x1711d6['filters']=_['intersection'](_0x1711d6[_0x2ecb2e('0xb')],_0x1711d6[_0x2ecb2e('0x6')]),_0x2e6f2e['attributes']=_[_0x2ecb2e('0x8')](_0x1711d6[_0x2ecb2e('0xb')],qs['fields'](_0x51e36d[_0x2ecb2e('0x6')][_0x2ecb2e('0x7')])),_0x2e6f2e[_0x2ecb2e('0xc')]=_0x2e6f2e['attributes']['length']?_0x2e6f2e[_0x2ecb2e('0xc')]:_0x1711d6['model'],_0x51e36d['query'][_0x2ecb2e('0xe')]&&(_0x2e6f2e[_0x2ecb2e('0x15')]=[{'all':!![]}]),_0x2e6f2e=_['merge']({},_0x2e6f2e,_0x51e36d[_0x2ecb2e('0x0')]),db[_0x2ecb2e('0x19')][_0x2ecb2e('0x9')](_0x2e6f2e)[_0x2ecb2e('0x14')](handleEntityNotFound(_0x5bcec5,null))[_0x2ecb2e('0x14')](respondWithResult(_0x5bcec5,null))[_0x2ecb2e('0x11')](handleError(_0x5bcec5,null));},exports[_0x326ea9('0x13')]=function(_0x3ddb5a,_0x1068c7){const _0x17c13a=_0x326ea9;return _0x3ddb5a[_0x17c13a('0x1b')]['id']&&delete _0x3ddb5a[_0x17c13a('0x1b')]['id'],db[_0x17c13a('0x19')][_0x17c13a('0x9')]({'where':{'id':_0x3ddb5a['params']['id']}})[_0x17c13a('0x14')](handleEntityNotFound(_0x1068c7,null))[_0x17c13a('0x14')](saveUpdates(_0x3ddb5a[_0x17c13a('0x1b')],null))['then'](respondWithResult(_0x1068c7,null))[_0x17c13a('0x11')](handleError(_0x1068c7,null));},exports[_0x326ea9('0x1')]=function(_0x22d108,_0x37996d){const _0xa0e5c2=_0x326ea9;return db[_0xa0e5c2('0x19')][_0xa0e5c2('0x9')]({'where':{'id':_0x22d108['params']['id']}})['then'](handleEntityNotFound(_0x37996d,null))['then'](removeEntity(_0x37996d,null))[_0xa0e5c2('0x11')](handleError(_0x37996d,null));}; \ No newline at end of file +const a55_0x4bce=['json','body','options','keys','name','params','lodash','query','ChatApplication','../../components/parsers/qs','show','api','then','attributes','catch','error','model','intersection','length','filters','merge','status','send','stack','fields','../../config/logger','../../mysqldb'];(function(_0x5d5fb9,_0x4bce3b){const _0x8cd21c=function(_0x4411be){while(--_0x4411be){_0x5d5fb9['push'](_0x5d5fb9['shift']());}};_0x8cd21c(++_0x4bce3b);}(a55_0x4bce,0x1c1));const a55_0x8cd2=function(_0x5d5fb9,_0x4bce3b){_0x5d5fb9=_0x5d5fb9-0x0;let _0x8cd21c=a55_0x4bce[_0x5d5fb9];return _0x8cd21c;};const _0x5aaed5=a55_0x8cd2;'use strict';const _=require(_0x5aaed5('0x10')),qs=require(_0x5aaed5('0x13')),logger=require(_0x5aaed5('0x8'))(_0x5aaed5('0x15')),db=require(_0x5aaed5('0x9'))['db'];function respondWithResult(_0x4411be,_0x190366){return _0x190366=_0x190366||0xc8,function(_0x270a9f){const _0x49c24e=a55_0x8cd2;if(_0x270a9f)return _0x4411be[_0x49c24e('0x4')](_0x190366)[_0x49c24e('0xa')](_0x270a9f);};}function saveUpdates(_0x1c74ba){return function(_0x277ea5){if(_0x277ea5)return _0x277ea5['update'](_0x1c74ba)['then'](function(_0x354113){return _0x354113;});return null;};}function removeEntity(_0x2a9756){return function(_0x1948f3){const _0x48129=a55_0x8cd2;if(_0x1948f3)return _0x1948f3['destroy']()[_0x48129('0x16')](function(){_0x2a9756['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x1a65be){return function(_0x2eed3b){return!_0x2eed3b&&_0x1a65be['sendStatus'](0x194),_0x2eed3b;};}function handleError(_0x42605b,_0x5d07f4){return _0x5d07f4=_0x5d07f4||0x1f4,function(_0x4f0508){const _0x255252=a55_0x8cd2;logger[_0x255252('0x19')](_0x4f0508[_0x255252('0x6')]),_0x4f0508[_0x255252('0xe')]&&delete _0x4f0508[_0x255252('0xe')],_0x42605b['status'](_0x5d07f4)[_0x255252('0x5')](_0x4f0508);};}exports[_0x5aaed5('0x14')]=function(_0x4a746b,_0x208172){const _0x536dad=_0x5aaed5;let _0x4aede5={'raw':!![],'where':{'id':_0x4a746b['params']['id']}};const _0x69394c={};return _0x69394c[_0x536dad('0x1a')]=_[_0x536dad('0xd')](db[_0x536dad('0x12')]['rawAttributes']),_0x69394c[_0x536dad('0x11')]=_[_0x536dad('0xd')](_0x4a746b[_0x536dad('0x11')]),_0x69394c[_0x536dad('0x2')]=_['intersection'](_0x69394c[_0x536dad('0x1a')],_0x69394c[_0x536dad('0x11')]),_0x4aede5[_0x536dad('0x17')]=_[_0x536dad('0x0')](_0x69394c[_0x536dad('0x1a')],qs[_0x536dad('0x7')](_0x4a746b[_0x536dad('0x11')]['fields'])),_0x4aede5[_0x536dad('0x17')]=_0x4aede5[_0x536dad('0x17')][_0x536dad('0x1')]?_0x4aede5[_0x536dad('0x17')]:_0x69394c['model'],_0x4a746b[_0x536dad('0x11')]['includeAll']&&(_0x4aede5['include']=[{'all':!![]}]),_0x4aede5=_[_0x536dad('0x3')]({},_0x4aede5,_0x4a746b[_0x536dad('0xc')]),db[_0x536dad('0x12')]['findOne'](_0x4aede5)[_0x536dad('0x16')](handleEntityNotFound(_0x208172,null))[_0x536dad('0x16')](respondWithResult(_0x208172,null))[_0x536dad('0x18')](handleError(_0x208172,null));},exports['update']=function(_0x423c3f,_0x34d777){const _0x271f47=_0x5aaed5;return _0x423c3f[_0x271f47('0xb')]['id']&&delete _0x423c3f['body']['id'],db[_0x271f47('0x12')]['findOne']({'where':{'id':_0x423c3f['params']['id']}})[_0x271f47('0x16')](handleEntityNotFound(_0x34d777,null))['then'](saveUpdates(_0x423c3f['body'],null))['then'](respondWithResult(_0x34d777,null))['catch'](handleError(_0x34d777,null));},exports['destroy']=function(_0x48cd1b,_0x1b2bbb){const _0x496981=_0x5aaed5;return db[_0x496981('0x12')]['findOne']({'where':{'id':_0x48cd1b[_0x496981('0xf')]['id']}})['then'](handleEntityNotFound(_0x1b2bbb,null))[_0x496981('0x16')](removeEntity(_0x1b2bbb,null))['catch'](handleError(_0x1b2bbb,null));}; \ No newline at end of file diff --git a/server/api/chatApplication/chatApplication.model.js b/server/api/chatApplication/chatApplication.model.js index b5a8759..552c896 100644 --- a/server/api/chatApplication/chatApplication.model.js +++ b/server/api/chatApplication/chatApplication.model.js @@ -1 +1 @@ -const a56_0x2a83=['chat_applications','exports','./chatApplication.attributes','utf8mb4_unicode_ci'];(function(_0x4eed71,_0x2a8322){const _0x16d2a1=function(_0x2f3521){while(--_0x2f3521){_0x4eed71['push'](_0x4eed71['shift']());}};_0x16d2a1(++_0x2a8322);}(a56_0x2a83,0x9c));const a56_0x16d2=function(_0x4eed71,_0x2a8322){_0x4eed71=_0x4eed71-0x0;let _0x16d2a1=a56_0x2a83[_0x4eed71];return _0x16d2a1;};const _0xe40930=a56_0x16d2;'use strict';const attributes=require(_0xe40930('0x2'));module[_0xe40930('0x1')]=function(_0x2f3521){const _0x1bc351=_0xe40930,_0xd85b98=_0x2f3521['define']('ChatApplication',attributes,{'tableName':_0x1bc351('0x0'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':'utf8mb4','collate':_0x1bc351('0x3')});return _0xd85b98;}; \ No newline at end of file +const a56_0x1658=['define','chat_applications','utf8mb4','exports','./chatApplication.attributes','ChatApplication'];(function(_0x4a2927,_0x165872){const _0x1930fe=function(_0x580536){while(--_0x580536){_0x4a2927['push'](_0x4a2927['shift']());}};_0x1930fe(++_0x165872);}(a56_0x1658,0x132));const a56_0x1930=function(_0x4a2927,_0x165872){_0x4a2927=_0x4a2927-0x0;let _0x1930fe=a56_0x1658[_0x4a2927];return _0x1930fe;};const _0x36d801=a56_0x1930;'use strict';const attributes=require(_0x36d801('0x4'));module[_0x36d801('0x3')]=function(_0x580536){const _0x28c3e2=_0x36d801,_0x1b3066=_0x580536[_0x28c3e2('0x0')](_0x28c3e2('0x5'),attributes,{'tableName':_0x28c3e2('0x1'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x28c3e2('0x2'),'collate':'utf8mb4_unicode_ci'});return _0x1b3066;}; \ No newline at end of file diff --git a/server/api/chatApplication/index.js b/server/api/chatApplication/index.js index 60ac1ff..6f50540 100644 --- a/server/api/chatApplication/index.js +++ b/server/api/chatApplication/index.js @@ -1 +1 @@ -const a57_0x1b2c=['destroy','express','get','../../components/auth/service','isAuthenticated','update','delete','./chatApplication.controller','put','exports','Router','/:id'];(function(_0x884e1b,_0x1b2c19){const _0x45a854=function(_0x12d7b6){while(--_0x12d7b6){_0x884e1b['push'](_0x884e1b['shift']());}};_0x45a854(++_0x1b2c19);}(a57_0x1b2c,0x1a7));const a57_0x45a8=function(_0x884e1b,_0x1b2c19){_0x884e1b=_0x884e1b-0x0;let _0x45a854=a57_0x1b2c[_0x884e1b];return _0x45a854;};const _0x47ebe4=a57_0x45a8;'use strict';const express=require(_0x47ebe4('0xa')),router=express[_0x47ebe4('0x7')](),auth=require(_0x47ebe4('0x0')),controller=require(_0x47ebe4('0x4'));router[_0x47ebe4('0xb')]('/:id',auth[_0x47ebe4('0x1')](),controller['show']),router[_0x47ebe4('0x5')](_0x47ebe4('0x8'),auth['isAuthenticated'](),controller[_0x47ebe4('0x2')]),router[_0x47ebe4('0x3')](_0x47ebe4('0x8'),auth[_0x47ebe4('0x1')](),controller[_0x47ebe4('0x9')]),module[_0x47ebe4('0x6')]=router; \ No newline at end of file +const a57_0x59ad=['get','/:id','show','Router','put','destroy','../../components/auth/service','isAuthenticated'];(function(_0x5998fa,_0x59adf0){const _0x19efc7=function(_0x481879){while(--_0x481879){_0x5998fa['push'](_0x5998fa['shift']());}};_0x19efc7(++_0x59adf0);}(a57_0x59ad,0xb6));const a57_0x19ef=function(_0x5998fa,_0x59adf0){_0x5998fa=_0x5998fa-0x0;let _0x19efc7=a57_0x59ad[_0x5998fa];return _0x19efc7;};const _0x426323=a57_0x19ef;'use strict';const express=require('express'),router=express[_0x426323('0x5')](),auth=require(_0x426323('0x0')),controller=require('./chatApplication.controller');router[_0x426323('0x2')](_0x426323('0x3'),auth[_0x426323('0x1')](),controller[_0x426323('0x4')]),router[_0x426323('0x6')](_0x426323('0x3'),auth[_0x426323('0x1')](),controller['update']),router['delete'](_0x426323('0x3'),auth[_0x426323('0x1')](),controller[_0x426323('0x7')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/chatGroup/chatGroup.attributes.js b/server/api/chatGroup/chatGroup.attributes.js index a6ab3fd..ffbb343 100644 --- a/server/api/chatGroup/chatGroup.attributes.js +++ b/server/api/chatGroup/chatGroup.attributes.js @@ -1 +1 @@ -const a58_0x3f18=['exports','BOOLEAN','STRING'];(function(_0x3592f7,_0x3f18fd){const _0x564d11=function(_0x4fde98){while(--_0x4fde98){_0x3592f7['push'](_0x3592f7['shift']());}};_0x564d11(++_0x3f18fd);}(a58_0x3f18,0xd1));const a58_0x564d=function(_0x3592f7,_0x3f18fd){_0x3592f7=_0x3592f7-0x0;let _0x564d11=a58_0x3f18[_0x3592f7];return _0x564d11;};const _0x8c3e6c=a58_0x564d;'use strict';const Sequelize=require('sequelize');module[_0x8c3e6c('0x1')]={'name':{'type':Sequelize[_0x8c3e6c('0x0')],'allowNull':![]},'description':{'type':Sequelize['STRING']},'write':{'type':Sequelize[_0x8c3e6c('0x2')],'defaultValue':!![]}}; \ No newline at end of file +const a58_0x28c6=['exports','STRING','BOOLEAN'];(function(_0x7f1b74,_0x28c684){const _0x14d6c0=function(_0x4f90b4){while(--_0x4f90b4){_0x7f1b74['push'](_0x7f1b74['shift']());}};_0x14d6c0(++_0x28c684);}(a58_0x28c6,0x194));const a58_0x14d6=function(_0x7f1b74,_0x28c684){_0x7f1b74=_0x7f1b74-0x0;let _0x14d6c0=a58_0x28c6[_0x7f1b74];return _0x14d6c0;};const _0x555e2a=a58_0x14d6;'use strict';const Sequelize=require('sequelize');module[_0x555e2a('0x1')]={'name':{'type':Sequelize['STRING'],'allowNull':![]},'description':{'type':Sequelize[_0x555e2a('0x2')]},'write':{'type':Sequelize[_0x555e2a('0x0')],'defaultValue':!![]}}; \ No newline at end of file diff --git a/server/api/chatGroup/chatGroup.controller.js b/server/api/chatGroup/chatGroup.controller.js index c186b1e..15ef608 100644 --- a/server/api/chatGroup/chatGroup.controller.js +++ b/server/api/chatGroup/chatGroup.controller.js @@ -1 +1 @@ -const a59_0x32b0=['body','split','key','destroy','getUnread','index','lodash','sendStatus','stack','json','rawAttributes','include','options','end','moment','findAll','update','getMembers','fieldName','error','api','register','describe','create','model','user','query','VIRTUAL','../../rediscache','format','filter','Content-Range','name','then','length','getMessages','nolimit','params','includeAll','addMembers','type','filters','removeMembers','send','attributes','like','where','omit','catch','count','ChatGroup','ChatGroupId','../../components/parsers/qs','../../mysqldb','order','addMessage','intersection','fields','gte','findOne','ChatInternalMessage','merge','YYYY-MM-DD\x20HH:mm:ss','keys','status','undefined','sequelize','ids','pick','offset','sort','limit','$gte','toInteger'];(function(_0x334e12,_0x32b0dd){const _0x27babb=function(_0x4ea846){while(--_0x4ea846){_0x334e12['push'](_0x334e12['shift']());}};_0x27babb(++_0x32b0dd);}(a59_0x32b0,0x1dc));const a59_0x27ba=function(_0x334e12,_0x32b0dd){_0x334e12=_0x334e12-0x0;let _0x27babb=a59_0x32b0[_0x334e12];return _0x27babb;};const _0x2c18cd=a59_0x27ba;'use strict';const moment=require(_0x2c18cd('0x38')),_=require(_0x2c18cd('0x30')),{getSocket}=require(_0x2c18cd('0x46')),qs=require(_0x2c18cd('0x14')),logger=require('../../config/logger')(_0x2c18cd('0x3e')),db=require(_0x2c18cd('0x15'))['db'],{Op}=require(_0x2c18cd('0x22')),socket=getSocket();require('./chatGroup.socket')[_0x2c18cd('0x3f')](socket);function respondWithStatusCode(_0x4ea846,_0x5660a4){return _0x5660a4=_0x5660a4||0xcc,function(_0x16d0b3){const _0x58861f=a59_0x27ba;if(_0x16d0b3)return _0x4ea846[_0x58861f('0x31')](_0x5660a4);return _0x4ea846[_0x58861f('0x20')](_0x5660a4)[_0x58861f('0x37')]();};}function respondWithResult(_0x590069,_0x59e10a){return _0x59e10a=_0x59e10a||0xc8,function(_0x3401d0){const _0xde92e7=a59_0x27ba;if(_0x3401d0)return _0x590069[_0xde92e7('0x20')](_0x59e10a)[_0xde92e7('0x33')](_0x3401d0);};}function respondWithFilteredResult(_0xd48767,_0x1af6a1){return function(_0x1e5602){const _0x36b981=a59_0x27ba;if(_0x1e5602){const _0x4b3593=_0x1e5602['count'],_0xc6422=_0x1af6a1[_0x36b981('0x25')];let _0x241134=_0x1af6a1[_0x36b981('0x25')]+_0x1af6a1['limit'],_0x280933;return _0x241134>=_0x4b3593?(_0x241134=_0x4b3593,_0x280933=0xc8):_0x280933=0xce,_0xd48767[_0x36b981('0x20')](_0x280933),_0xd48767['set'](_0x36b981('0x49'),_0xc6422+'-'+_0x241134+'/'+_0x4b3593)[_0x36b981('0x33')](_0x1e5602);}return null;};}function saveUpdates(_0x37636c){return function(_0x1c39ca){const _0x483aa1=a59_0x27ba;if(_0x1c39ca)return _0x1c39ca[_0x483aa1('0x3a')](_0x37636c)['then'](function(_0x788e77){return _0x788e77;});return null;};}function removeEntity(_0x1bdbe2){return function(_0xffd956){const _0x223966=a59_0x27ba;if(_0xffd956)return _0xffd956[_0x223966('0x2d')]()[_0x223966('0x1')](function(){const _0x277eda=_0x223966;_0x1bdbe2[_0x277eda('0x20')](0xcc)[_0x277eda('0x37')]();});};}function handleEntityNotFound(_0x463d13){return function(_0x26171e){return!_0x26171e&&_0x463d13['sendStatus'](0x194),_0x26171e;};}function handleError(_0x1049b7,_0x4a99be){return _0x4a99be=_0x4a99be||0x1f4,function(_0x395658){const _0x31af64=a59_0x27ba;logger[_0x31af64('0x3d')](_0x395658[_0x31af64('0x32')]),_0x395658[_0x31af64('0x0')]&&delete _0x395658['name'],_0x1049b7[_0x31af64('0x20')](_0x4a99be)[_0x31af64('0xb')](_0x395658);};}exports[_0x2c18cd('0x2f')]=function(_0x167184,_0x323850){const _0x4a9cbf=_0x2c18cd;let _0x59ff11={};const _0x50d3fa={},_0x267b43={'count':0x0,'rows':[]},_0x273a82=_['map'](db[_0x4a9cbf('0x12')][_0x4a9cbf('0x34')],function(_0x246d7c){const _0x1420c3=_0x4a9cbf;return{'name':_0x246d7c[_0x1420c3('0x3c')],'type':_0x246d7c[_0x1420c3('0x8')][_0x1420c3('0x2c')]};});_0x50d3fa[_0x4a9cbf('0x42')]=_['map'](_0x273a82,_0x4a9cbf('0x0')),_0x50d3fa[_0x4a9cbf('0x44')]=_[_0x4a9cbf('0x1f')](_0x167184[_0x4a9cbf('0x44')]),_0x50d3fa[_0x4a9cbf('0x9')]=_[_0x4a9cbf('0x18')](_0x50d3fa[_0x4a9cbf('0x42')],_0x50d3fa[_0x4a9cbf('0x44')]),_0x59ff11[_0x4a9cbf('0xc')]=_['intersection'](_0x50d3fa[_0x4a9cbf('0x42')],qs[_0x4a9cbf('0x19')](_0x167184[_0x4a9cbf('0x44')][_0x4a9cbf('0x19')])),_0x59ff11[_0x4a9cbf('0xc')]=_0x59ff11[_0x4a9cbf('0xc')][_0x4a9cbf('0x2')]?_0x59ff11[_0x4a9cbf('0xc')]:_0x50d3fa['model'];typeof _0x167184[_0x4a9cbf('0x44')][_0x4a9cbf('0x4')]===_0x4a9cbf('0x21')&&(_0x59ff11[_0x4a9cbf('0x27')]=qs[_0x4a9cbf('0x27')](_0x167184['query'][_0x4a9cbf('0x27')]),_0x59ff11['offset']=qs['offset'](_0x167184[_0x4a9cbf('0x44')]['offset']));_0x59ff11[_0x4a9cbf('0x16')]=qs[_0x4a9cbf('0x26')](_0x167184[_0x4a9cbf('0x44')][_0x4a9cbf('0x26')]),_0x59ff11['where']=qs[_0x4a9cbf('0x9')](_[_0x4a9cbf('0x24')](_0x167184['query'],_0x50d3fa[_0x4a9cbf('0x9')]),_0x273a82);_0x167184[_0x4a9cbf('0x44')]['filter']&&(_0x59ff11[_0x4a9cbf('0xe')]=_['merge'](_0x59ff11[_0x4a9cbf('0xe')],{[Op['or']]:_['map'](_0x273a82,function(_0x515da0){const _0x2ad7ad=_0x4a9cbf;if(_0x515da0['type']!==_0x2ad7ad('0x45')){const _0x830dce={};return _0x830dce[_0x515da0[_0x2ad7ad('0x0')]]={[Op['like']]:'%'+_0x167184[_0x2ad7ad('0x44')]['filter']+'%'},_0x830dce;}})}));_0x59ff11=_[_0x4a9cbf('0x1d')]({},_0x59ff11,_0x167184[_0x4a9cbf('0x36')]);const _0x33c994={'where':_0x59ff11[_0x4a9cbf('0xe')]};return db[_0x4a9cbf('0x12')]['count'](_0x33c994)[_0x4a9cbf('0x1')](function(_0x6853f9){const _0x4a6700=_0x4a9cbf;return _0x267b43['count']=_0x6853f9,_0x167184['query'][_0x4a6700('0x6')]&&(_0x59ff11[_0x4a6700('0x35')]=[{'all':!![]}]),db[_0x4a6700('0x12')][_0x4a6700('0x39')](_0x59ff11);})[_0x4a9cbf('0x1')](function(_0x32a1ac){return _0x267b43['rows']=_0x32a1ac,_0x267b43;})[_0x4a9cbf('0x1')](respondWithFilteredResult(_0x323850,_0x59ff11))[_0x4a9cbf('0x10')](handleError(_0x323850,null));},exports['show']=function(_0x59c41a,_0x426e8c){const _0x2af5cf=_0x2c18cd;let _0x1a5283={'raw':!![],'where':{'id':_0x59c41a[_0x2af5cf('0x5')]['id']}};const _0x54cd6f={};return _0x54cd6f[_0x2af5cf('0x42')]=_[_0x2af5cf('0x1f')](db[_0x2af5cf('0x12')][_0x2af5cf('0x34')]),_0x54cd6f[_0x2af5cf('0x44')]=_['keys'](_0x59c41a[_0x2af5cf('0x44')]),_0x54cd6f[_0x2af5cf('0x9')]=_[_0x2af5cf('0x18')](_0x54cd6f[_0x2af5cf('0x42')],_0x54cd6f['query']),_0x1a5283[_0x2af5cf('0xc')]=_['intersection'](_0x54cd6f['model'],qs['fields'](_0x59c41a[_0x2af5cf('0x44')][_0x2af5cf('0x19')])),_0x1a5283[_0x2af5cf('0xc')]=_0x1a5283[_0x2af5cf('0xc')][_0x2af5cf('0x2')]?_0x1a5283[_0x2af5cf('0xc')]:_0x54cd6f[_0x2af5cf('0x42')],_0x59c41a['query'][_0x2af5cf('0x6')]&&(_0x1a5283[_0x2af5cf('0x35')]=[{'all':!![]}]),_0x1a5283=_[_0x2af5cf('0x1d')]({},_0x1a5283,_0x59c41a[_0x2af5cf('0x36')]),db['ChatGroup']['findOne'](_0x1a5283)[_0x2af5cf('0x1')](handleEntityNotFound(_0x426e8c,null))['then'](respondWithResult(_0x426e8c,null))[_0x2af5cf('0x10')](handleError(_0x426e8c,null));},exports['create']=function(_0xe5fe4b,_0x3c4679){const _0xbec1be=_0x2c18cd;return db[_0xbec1be('0x12')][_0xbec1be('0x41')](_0xe5fe4b[_0xbec1be('0x2a')],{})[_0xbec1be('0x1')](respondWithResult(_0x3c4679,0xc9))[_0xbec1be('0x10')](handleError(_0x3c4679,null));},exports[_0x2c18cd('0x3a')]=function(_0x20a9da,_0x17d556){const _0x5ea3ae=_0x2c18cd;return _0x20a9da['body']['id']&&delete _0x20a9da[_0x5ea3ae('0x2a')]['id'],db['ChatGroup'][_0x5ea3ae('0x1b')]({'where':{'id':_0x20a9da[_0x5ea3ae('0x5')]['id']}})['then'](handleEntityNotFound(_0x17d556,null))['then'](saveUpdates(_0x20a9da[_0x5ea3ae('0x2a')],null))[_0x5ea3ae('0x1')](respondWithResult(_0x17d556,null))['catch'](handleError(_0x17d556,null));},exports[_0x2c18cd('0x2d')]=function(_0x1285e6,_0x51ac57){const _0x4a7986=_0x2c18cd;return db['ChatGroup'][_0x4a7986('0x1b')]({'where':{'id':_0x1285e6[_0x4a7986('0x5')]['id']}})['then'](handleEntityNotFound(_0x51ac57,null))[_0x4a7986('0x1')](removeEntity(_0x51ac57,null))[_0x4a7986('0x10')](handleError(_0x51ac57,null));},exports[_0x2c18cd('0x40')]=function(_0x2732ce,_0x2ea44f){const _0x42a09d=_0x2c18cd;return db[_0x42a09d('0x12')][_0x42a09d('0x40')]()[_0x42a09d('0x1')](respondWithResult(_0x2ea44f,null))[_0x42a09d('0x10')](handleError(_0x2ea44f,null));},exports[_0x2c18cd('0x2e')]=function(_0x185c80,_0x22eaff){const _0x173ce7=_0x2c18cd;return db['ChatInternalMessage'][_0x173ce7('0x11')]({'where':{'ChatGroupId':_0x185c80[_0x173ce7('0x5')]['id'],'ToId':_0x185c80[_0x173ce7('0x43')]['id'],'read':![]}})[_0x173ce7('0x1')](function(_0x535e3a){const _0x34254f=_0x173ce7;return{'id':_[_0x34254f('0x29')](_0x185c80[_0x34254f('0x5')]['id']),'count':_0x535e3a};})['then'](respondWithResult(_0x22eaff,null))[_0x173ce7('0x10')](handleError(_0x22eaff,null));},exports['addMembers']=function(_0x37173b,_0x38926f){const _0x4bcdf5=_0x2c18cd;return db['ChatGroup'][_0x4bcdf5('0x1b')]({'where':{'id':_0x37173b[_0x4bcdf5('0x5')]['id']}})['then'](function(_0x4390f9){const _0x5d06c6=_0x4bcdf5;if(_0x4390f9)return _0x4390f9[_0x5d06c6('0x7')](_0x37173b[_0x5d06c6('0x2a')][_0x5d06c6('0x23')],{'through':_[_0x5d06c6('0xf')](_0x37173b[_0x5d06c6('0x2a')],[_0x5d06c6('0x23'),'id'])});})[_0x4bcdf5('0x1')](respondWithResult(_0x38926f,null))[_0x4bcdf5('0x10')](handleError(_0x38926f,null));},exports['getMembers']=function(_0x3028fd,_0x58f13b){const _0x3b9aa4=_0x2c18cd;let _0x4f2765={};const _0x4704b7={};let _0x16d0c4,_0x237bc0;return db['ChatGroup'][_0x3b9aa4('0x1b')]({'where':{'id':_0x3028fd[_0x3b9aa4('0x5')]['id']}})[_0x3b9aa4('0x1')](handleEntityNotFound(_0x58f13b,null))[_0x3b9aa4('0x1')](function(_0x3825c4){const _0x4b9e18=_0x3b9aa4;if(_0x3825c4)return _0x16d0c4=_0x3825c4,_0x4704b7[_0x4b9e18('0x42')]=_[_0x4b9e18('0x1f')](db['User']['rawAttributes']),_0x4704b7[_0x4b9e18('0x44')]=_[_0x4b9e18('0x1f')](_0x3028fd[_0x4b9e18('0x44')]),_0x4704b7['filters']=_['intersection'](_0x4704b7['model'],_0x4704b7[_0x4b9e18('0x44')]),_0x4f2765[_0x4b9e18('0xc')]=_[_0x4b9e18('0x18')](_0x4704b7[_0x4b9e18('0x42')],qs[_0x4b9e18('0x19')](_0x3028fd[_0x4b9e18('0x44')][_0x4b9e18('0x19')])),_0x4f2765[_0x4b9e18('0xc')]=_0x4f2765['attributes'][_0x4b9e18('0x2')]?_0x4f2765[_0x4b9e18('0xc')]:_0x4704b7['model'],_0x4f2765[_0x4b9e18('0x16')]=qs[_0x4b9e18('0x26')](_0x3028fd[_0x4b9e18('0x44')][_0x4b9e18('0x26')]),_0x4f2765[_0x4b9e18('0xe')]=qs['filters'](_[_0x4b9e18('0x24')](_0x3028fd[_0x4b9e18('0x44')],_0x4704b7[_0x4b9e18('0x9')])),_0x3028fd[_0x4b9e18('0x44')][_0x4b9e18('0x48')]&&(_0x4f2765[_0x4b9e18('0xe')]=_[_0x4b9e18('0x1d')](_0x4f2765[_0x4b9e18('0xe')],{[Op['or']]:_['map'](_0x4f2765['attributes'],function(_0x2c9134){const _0x1985dd=_0x4b9e18,_0x239658={};return _0x239658[_0x2c9134]={[Op[_0x1985dd('0xd')]]:'%'+_0x3028fd[_0x1985dd('0x44')][_0x1985dd('0x48')]+'%'},_0x239658;})})),_0x4f2765=_[_0x4b9e18('0x1d')]({},_0x4f2765,_0x3028fd[_0x4b9e18('0x36')]),_0x16d0c4[_0x4b9e18('0x3b')](_0x4f2765);})[_0x3b9aa4('0x1')](function(_0xb402){const _0x1e810b=_0x3b9aa4;if(_0xb402)return _0x237bc0=_0xb402[_0x1e810b('0x2')],typeof _0x3028fd['query'][_0x1e810b('0x4')]===_0x1e810b('0x21')&&(_0x4f2765[_0x1e810b('0x27')]=qs['limit'](_0x3028fd[_0x1e810b('0x44')][_0x1e810b('0x27')]),_0x4f2765['offset']=qs[_0x1e810b('0x25')](_0x3028fd[_0x1e810b('0x44')]['offset'])),_0x16d0c4[_0x1e810b('0x3b')](_0x4f2765);})['then'](function(_0x544e6e){if(_0x544e6e)return _0x544e6e?{'count':_0x237bc0,'rows':_0x544e6e}:null;})[_0x3b9aa4('0x1')](respondWithResult(_0x58f13b,null))[_0x3b9aa4('0x10')](handleError(_0x58f13b,null));},exports['removeMembers']=function(_0xd3829c,_0x7b9b04){const _0x836f1f=_0x2c18cd;return db[_0x836f1f('0x12')][_0x836f1f('0x1b')]({'where':{'id':_0xd3829c[_0x836f1f('0x5')]['id']}})[_0x836f1f('0x1')](handleEntityNotFound(_0x7b9b04,null))[_0x836f1f('0x1')](function(_0x27d7be){const _0x3ed33d=_0x836f1f;if(_0x27d7be)return _0x27d7be[_0x3ed33d('0xa')](_0xd3829c[_0x3ed33d('0x44')]['ids']);})[_0x836f1f('0x1')](respondWithStatusCode(_0x7b9b04,null))[_0x836f1f('0x10')](handleError(_0x7b9b04,null));},exports[_0x2c18cd('0x17')]=function(_0x4383a3,_0x1b96a0){const _0x4112ad=_0x2c18cd;return _0x4383a3[_0x4112ad('0x2a')]['id']&&delete _0x4383a3[_0x4112ad('0x2a')]['id'],db[_0x4112ad('0x12')][_0x4112ad('0x1b')]({'where':{'id':_0x4383a3[_0x4112ad('0x5')]['id']}})[_0x4112ad('0x1')](handleEntityNotFound(_0x1b96a0,null))[_0x4112ad('0x1')](function(_0x1da81a){const _0x51d5f0=_0x4112ad;if(_0x1da81a)return _0x4383a3[_0x51d5f0('0x2a')][_0x51d5f0('0x13')]=_0x1da81a['id'],db[_0x51d5f0('0x1c')][_0x51d5f0('0x41')](_0x4383a3[_0x51d5f0('0x2a')]);})[_0x4112ad('0x1')](respondWithResult(_0x1b96a0,null))[_0x4112ad('0x10')](handleError(_0x1b96a0,null));},exports[_0x2c18cd('0x3')]=function(_0x27f97c,_0x49e9ec){const _0x1e60b1=_0x2c18cd;let _0x518655={};const _0x480f5a={};let _0x58a4f7,_0x4f27ad;return db[_0x1e60b1('0x12')][_0x1e60b1('0x1b')]({'where':{'id':_0x27f97c[_0x1e60b1('0x5')]['id']}})[_0x1e60b1('0x1')](handleEntityNotFound(_0x49e9ec,null))['then'](function(_0x364e3c){const _0x2c1659=_0x1e60b1;if(_0x364e3c){_0x58a4f7=_0x364e3c,_0x480f5a[_0x2c1659('0x42')]=_[_0x2c1659('0x1f')](db[_0x2c1659('0x1c')][_0x2c1659('0x34')]),_0x480f5a[_0x2c1659('0x44')]=_['keys'](_0x27f97c[_0x2c1659('0x44')]),_0x480f5a['filters']=_[_0x2c1659('0x18')](_0x480f5a['model'],_0x480f5a[_0x2c1659('0x44')]),_0x518655['attributes']=_[_0x2c1659('0x18')](_0x480f5a[_0x2c1659('0x42')],qs['fields'](_0x27f97c[_0x2c1659('0x44')][_0x2c1659('0x19')])),_0x518655['attributes']=_0x518655['attributes']['length']?_0x518655[_0x2c1659('0xc')]:_0x480f5a['model'],_0x518655[_0x2c1659('0x16')]=qs[_0x2c1659('0x26')](_0x27f97c['query'][_0x2c1659('0x26')]),_0x518655[_0x2c1659('0xe')]=qs[_0x2c1659('0x9')](_[_0x2c1659('0x24')](_0x27f97c[_0x2c1659('0x44')],_0x480f5a[_0x2c1659('0x9')]));_0x27f97c[_0x2c1659('0x44')][_0x2c1659('0x48')]&&(_0x518655[_0x2c1659('0xe')]=_[_0x2c1659('0x1d')](_0x518655[_0x2c1659('0xe')],{[Op['or']]:_['map'](_0x518655['attributes'],function(_0x484c39){const _0x1ae043=_0x2c1659,_0x1d4cbc={};return _0x1d4cbc[_0x484c39]={[Op[_0x1ae043('0xd')]]:'%'+_0x27f97c['query'][_0x1ae043('0x48')]+'%'},_0x1d4cbc;})}));if(_0x27f97c[_0x2c1659('0x44')][_0x2c1659('0x28')]){const _0x5d102b=_0x27f97c['query'][_0x2c1659('0x28')][_0x2c1659('0x2b')](','),_0x37c5c5={};_0x37c5c5[_0x5d102b[0x0]]={[Op[_0x2c1659('0x1a')]]:moment(_0x5d102b[0x1])[_0x2c1659('0x47')](_0x2c1659('0x1e'))},_0x518655[_0x2c1659('0xe')]=_[_0x2c1659('0x1d')](_0x518655[_0x2c1659('0xe')],_0x37c5c5);}return _0x518655=_[_0x2c1659('0x1d')]({},_0x518655,_0x27f97c['options']),_0x58a4f7['getMessages'](_0x518655);}})['then'](function(_0x13e865){const _0xca12f6=_0x1e60b1;if(_0x13e865)return _0x4f27ad=_0x13e865['length'],typeof _0x27f97c[_0xca12f6('0x44')][_0xca12f6('0x4')]===_0xca12f6('0x21')&&(_0x518655[_0xca12f6('0x27')]=qs[_0xca12f6('0x27')](_0x27f97c['query']['limit']),_0x518655[_0xca12f6('0x25')]=qs['offset'](_0x27f97c[_0xca12f6('0x44')][_0xca12f6('0x25')])),_0x58a4f7[_0xca12f6('0x3')](_0x518655);})[_0x1e60b1('0x1')](function(_0x1c77cc){if(_0x1c77cc)return _0x1c77cc?{'count':_0x4f27ad,'rows':_0x1c77cc}:null;})[_0x1e60b1('0x1')](respondWithResult(_0x49e9ec,null))[_0x1e60b1('0x10')](handleError(_0x49e9ec,null));}; \ No newline at end of file +const a59_0x46f0=['create','keys','api','intersection','name','index','json','map','../../components/parsers/qs','options','fields','findOne','filters','length','ChatGroupId','error','findAll','fieldName','send','$gte','Content-Range','moment','getMessages','register','stack','order','./chatGroup.socket','attributes','sort','../../rediscache','nolimit','key','offset','omit','set','getUnread','ids','describe','removeMembers','addMessage','rawAttributes','filter','undefined','params','catch','ChatGroup','getMembers','body','update','destroy','pick','../../mysqldb','user','rows','includeAll','format','lodash','model','sendStatus','where','limit','type','include','count','addMembers','merge','then','status','like','gte','end','ChatInternalMessage','query'];(function(_0x5251e2,_0x46f081){const _0x2cd194=function(_0x33dc12){while(--_0x33dc12){_0x5251e2['push'](_0x5251e2['shift']());}};_0x2cd194(++_0x46f081);}(a59_0x46f0,0x1eb));const a59_0x2cd1=function(_0x5251e2,_0x46f081){_0x5251e2=_0x5251e2-0x0;let _0x2cd194=a59_0x46f0[_0x5251e2];return _0x2cd194;};const _0x4b376c=a59_0x2cd1;'use strict';const moment=require(_0x4b376c('0x29')),_=require(_0x4b376c('0x3')),{getSocket}=require(_0x4b376c('0x31')),qs=require(_0x4b376c('0x1c')),logger=require('../../config/logger')(_0x4b376c('0x16')),db=require(_0x4b376c('0x47'))['db'],{Op}=require('sequelize'),socket=getSocket();require(_0x4b376c('0x2e'))[_0x4b376c('0x2b')](socket);function respondWithStatusCode(_0x33dc12,_0x33d4af){return _0x33d4af=_0x33d4af||0xcc,function(_0x435db3){const _0x5aa187=a59_0x2cd1;if(_0x435db3)return _0x33dc12['sendStatus'](_0x33d4af);return _0x33dc12[_0x5aa187('0xe')](_0x33d4af)[_0x5aa187('0x11')]();};}function respondWithResult(_0x1027f3,_0x45543c){return _0x45543c=_0x45543c||0xc8,function(_0x20e1b){const _0x5914ec=a59_0x2cd1;if(_0x20e1b)return _0x1027f3[_0x5914ec('0xe')](_0x45543c)[_0x5914ec('0x1a')](_0x20e1b);};}function respondWithFilteredResult(_0xe06512,_0x59bb3d){return function(_0x22fd55){const _0x231b0e=a59_0x2cd1;if(_0x22fd55){const _0x558d85=_0x22fd55[_0x231b0e('0xa')],_0x55d627=_0x59bb3d[_0x231b0e('0x34')];let _0x22fe77=_0x59bb3d[_0x231b0e('0x34')]+_0x59bb3d[_0x231b0e('0x7')],_0x3188d9;return _0x22fe77>=_0x558d85?(_0x22fe77=_0x558d85,_0x3188d9=0xc8):_0x3188d9=0xce,_0xe06512[_0x231b0e('0xe')](_0x3188d9),_0xe06512[_0x231b0e('0x36')](_0x231b0e('0x28'),_0x55d627+'-'+_0x22fe77+'/'+_0x558d85)[_0x231b0e('0x1a')](_0x22fd55);}return null;};}function saveUpdates(_0x18e7e7){return function(_0xa377ec){const _0x5e138e=a59_0x2cd1;if(_0xa377ec)return _0xa377ec['update'](_0x18e7e7)[_0x5e138e('0xd')](function(_0x56c441){return _0x56c441;});return null;};}function removeEntity(_0x451e9b){return function(_0x57afb5){const _0x131a37=a59_0x2cd1;if(_0x57afb5)return _0x57afb5[_0x131a37('0x45')]()['then'](function(){const _0x155dd9=_0x131a37;_0x451e9b[_0x155dd9('0xe')](0xcc)[_0x155dd9('0x11')]();});};}function handleEntityNotFound(_0x1e095b){return function(_0x2d9f43){const _0x44fc07=a59_0x2cd1;return!_0x2d9f43&&_0x1e095b[_0x44fc07('0x5')](0x194),_0x2d9f43;};}function handleError(_0x50d187,_0x557d72){return _0x557d72=_0x557d72||0x1f4,function(_0x5c8b02){const _0x3b2525=a59_0x2cd1;logger[_0x3b2525('0x23')](_0x5c8b02[_0x3b2525('0x2c')]),_0x5c8b02[_0x3b2525('0x18')]&&delete _0x5c8b02['name'],_0x50d187['status'](_0x557d72)[_0x3b2525('0x26')](_0x5c8b02);};}exports[_0x4b376c('0x19')]=function(_0x5a14c9,_0x60f703){const _0x2bb095=_0x4b376c;let _0x34d7c0={};const _0x444202={},_0x2c7142={'count':0x0,'rows':[]},_0x1e0c7b=_[_0x2bb095('0x1b')](db[_0x2bb095('0x41')][_0x2bb095('0x3c')],function(_0x30b660){const _0x434952=_0x2bb095;return{'name':_0x30b660[_0x434952('0x25')],'type':_0x30b660[_0x434952('0x8')][_0x434952('0x33')]};});_0x444202['model']=_['map'](_0x1e0c7b,_0x2bb095('0x18')),_0x444202[_0x2bb095('0x13')]=_[_0x2bb095('0x15')](_0x5a14c9[_0x2bb095('0x13')]),_0x444202[_0x2bb095('0x20')]=_[_0x2bb095('0x17')](_0x444202['model'],_0x444202[_0x2bb095('0x13')]),_0x34d7c0[_0x2bb095('0x2f')]=_[_0x2bb095('0x17')](_0x444202[_0x2bb095('0x4')],qs['fields'](_0x5a14c9[_0x2bb095('0x13')][_0x2bb095('0x1e')])),_0x34d7c0[_0x2bb095('0x2f')]=_0x34d7c0[_0x2bb095('0x2f')][_0x2bb095('0x21')]?_0x34d7c0[_0x2bb095('0x2f')]:_0x444202[_0x2bb095('0x4')];typeof _0x5a14c9[_0x2bb095('0x13')][_0x2bb095('0x32')]==='undefined'&&(_0x34d7c0[_0x2bb095('0x7')]=qs['limit'](_0x5a14c9['query'][_0x2bb095('0x7')]),_0x34d7c0[_0x2bb095('0x34')]=qs[_0x2bb095('0x34')](_0x5a14c9[_0x2bb095('0x13')][_0x2bb095('0x34')]));_0x34d7c0[_0x2bb095('0x2d')]=qs[_0x2bb095('0x30')](_0x5a14c9[_0x2bb095('0x13')][_0x2bb095('0x30')]),_0x34d7c0[_0x2bb095('0x6')]=qs[_0x2bb095('0x20')](_[_0x2bb095('0x46')](_0x5a14c9[_0x2bb095('0x13')],_0x444202[_0x2bb095('0x20')]),_0x1e0c7b);_0x5a14c9[_0x2bb095('0x13')][_0x2bb095('0x3d')]&&(_0x34d7c0[_0x2bb095('0x6')]=_[_0x2bb095('0xc')](_0x34d7c0['where'],{[Op['or']]:_[_0x2bb095('0x1b')](_0x1e0c7b,function(_0x327808){const _0x38df91=_0x2bb095;if(_0x327808[_0x38df91('0x8')]!=='VIRTUAL'){const _0x384b94={};return _0x384b94[_0x327808[_0x38df91('0x18')]]={[Op['like']]:'%'+_0x5a14c9[_0x38df91('0x13')][_0x38df91('0x3d')]+'%'},_0x384b94;}})}));_0x34d7c0=_[_0x2bb095('0xc')]({},_0x34d7c0,_0x5a14c9[_0x2bb095('0x1d')]);const _0x925e77={'where':_0x34d7c0[_0x2bb095('0x6')]};return db[_0x2bb095('0x41')][_0x2bb095('0xa')](_0x925e77)['then'](function(_0x111004){const _0x311406=_0x2bb095;return _0x2c7142[_0x311406('0xa')]=_0x111004,_0x5a14c9[_0x311406('0x13')][_0x311406('0x1')]&&(_0x34d7c0[_0x311406('0x9')]=[{'all':!![]}]),db[_0x311406('0x41')][_0x311406('0x24')](_0x34d7c0);})[_0x2bb095('0xd')](function(_0x262670){const _0x180932=_0x2bb095;return _0x2c7142[_0x180932('0x0')]=_0x262670,_0x2c7142;})[_0x2bb095('0xd')](respondWithFilteredResult(_0x60f703,_0x34d7c0))['catch'](handleError(_0x60f703,null));},exports['show']=function(_0x5a0121,_0x147ee3){const _0x24523d=_0x4b376c;let _0x46f983={'raw':!![],'where':{'id':_0x5a0121[_0x24523d('0x3f')]['id']}};const _0x5842c0={};return _0x5842c0[_0x24523d('0x4')]=_['keys'](db[_0x24523d('0x41')][_0x24523d('0x3c')]),_0x5842c0['query']=_[_0x24523d('0x15')](_0x5a0121['query']),_0x5842c0[_0x24523d('0x20')]=_[_0x24523d('0x17')](_0x5842c0[_0x24523d('0x4')],_0x5842c0['query']),_0x46f983['attributes']=_[_0x24523d('0x17')](_0x5842c0['model'],qs[_0x24523d('0x1e')](_0x5a0121[_0x24523d('0x13')][_0x24523d('0x1e')])),_0x46f983[_0x24523d('0x2f')]=_0x46f983['attributes'][_0x24523d('0x21')]?_0x46f983[_0x24523d('0x2f')]:_0x5842c0[_0x24523d('0x4')],_0x5a0121['query'][_0x24523d('0x1')]&&(_0x46f983[_0x24523d('0x9')]=[{'all':!![]}]),_0x46f983=_[_0x24523d('0xc')]({},_0x46f983,_0x5a0121[_0x24523d('0x1d')]),db[_0x24523d('0x41')]['findOne'](_0x46f983)[_0x24523d('0xd')](handleEntityNotFound(_0x147ee3,null))[_0x24523d('0xd')](respondWithResult(_0x147ee3,null))['catch'](handleError(_0x147ee3,null));},exports['create']=function(_0x34c897,_0x4c09b7){const _0x370a7b=_0x4b376c;return db[_0x370a7b('0x41')][_0x370a7b('0x14')](_0x34c897[_0x370a7b('0x43')],{})[_0x370a7b('0xd')](respondWithResult(_0x4c09b7,0xc9))[_0x370a7b('0x40')](handleError(_0x4c09b7,null));},exports[_0x4b376c('0x44')]=function(_0x2d0ad8,_0x10017f){const _0x4775c2=_0x4b376c;return _0x2d0ad8[_0x4775c2('0x43')]['id']&&delete _0x2d0ad8[_0x4775c2('0x43')]['id'],db[_0x4775c2('0x41')][_0x4775c2('0x1f')]({'where':{'id':_0x2d0ad8['params']['id']}})[_0x4775c2('0xd')](handleEntityNotFound(_0x10017f,null))[_0x4775c2('0xd')](saveUpdates(_0x2d0ad8[_0x4775c2('0x43')],null))[_0x4775c2('0xd')](respondWithResult(_0x10017f,null))[_0x4775c2('0x40')](handleError(_0x10017f,null));},exports[_0x4b376c('0x45')]=function(_0x18f761,_0x1ea233){const _0x2f1131=_0x4b376c;return db[_0x2f1131('0x41')][_0x2f1131('0x1f')]({'where':{'id':_0x18f761[_0x2f1131('0x3f')]['id']}})[_0x2f1131('0xd')](handleEntityNotFound(_0x1ea233,null))['then'](removeEntity(_0x1ea233,null))[_0x2f1131('0x40')](handleError(_0x1ea233,null));},exports[_0x4b376c('0x39')]=function(_0x56d4e2,_0x47b404){const _0x2c8bbb=_0x4b376c;return db[_0x2c8bbb('0x41')][_0x2c8bbb('0x39')]()[_0x2c8bbb('0xd')](respondWithResult(_0x47b404,null))['catch'](handleError(_0x47b404,null));},exports[_0x4b376c('0x37')]=function(_0x5e2c55,_0x2a0686){const _0x151563=_0x4b376c;return db[_0x151563('0x12')]['count']({'where':{'ChatGroupId':_0x5e2c55[_0x151563('0x3f')]['id'],'ToId':_0x5e2c55[_0x151563('0x48')]['id'],'read':![]}})[_0x151563('0xd')](function(_0x26a802){return{'id':_['toInteger'](_0x5e2c55['params']['id']),'count':_0x26a802};})[_0x151563('0xd')](respondWithResult(_0x2a0686,null))[_0x151563('0x40')](handleError(_0x2a0686,null));},exports[_0x4b376c('0xb')]=function(_0x22340f,_0x37b884){const _0x13aa78=_0x4b376c;return db[_0x13aa78('0x41')][_0x13aa78('0x1f')]({'where':{'id':_0x22340f[_0x13aa78('0x3f')]['id']}})[_0x13aa78('0xd')](function(_0x4a4ca5){const _0x138560=_0x13aa78;if(_0x4a4ca5)return _0x4a4ca5[_0x138560('0xb')](_0x22340f['body'][_0x138560('0x38')],{'through':_[_0x138560('0x35')](_0x22340f['body'],['ids','id'])});})['then'](respondWithResult(_0x37b884,null))[_0x13aa78('0x40')](handleError(_0x37b884,null));},exports['getMembers']=function(_0x5b0b75,_0x4b5ff2){const _0x5eeca0=_0x4b376c;let _0x2f4a2a={};const _0x4c9bb5={};let _0x580ca7,_0x53818d;return db[_0x5eeca0('0x41')][_0x5eeca0('0x1f')]({'where':{'id':_0x5b0b75[_0x5eeca0('0x3f')]['id']}})['then'](handleEntityNotFound(_0x4b5ff2,null))['then'](function(_0x67717e){const _0x3568db=_0x5eeca0;if(_0x67717e)return _0x580ca7=_0x67717e,_0x4c9bb5[_0x3568db('0x4')]=_[_0x3568db('0x15')](db['User'][_0x3568db('0x3c')]),_0x4c9bb5[_0x3568db('0x13')]=_[_0x3568db('0x15')](_0x5b0b75[_0x3568db('0x13')]),_0x4c9bb5[_0x3568db('0x20')]=_[_0x3568db('0x17')](_0x4c9bb5[_0x3568db('0x4')],_0x4c9bb5[_0x3568db('0x13')]),_0x2f4a2a['attributes']=_[_0x3568db('0x17')](_0x4c9bb5[_0x3568db('0x4')],qs[_0x3568db('0x1e')](_0x5b0b75['query'][_0x3568db('0x1e')])),_0x2f4a2a[_0x3568db('0x2f')]=_0x2f4a2a[_0x3568db('0x2f')][_0x3568db('0x21')]?_0x2f4a2a[_0x3568db('0x2f')]:_0x4c9bb5[_0x3568db('0x4')],_0x2f4a2a['order']=qs[_0x3568db('0x30')](_0x5b0b75[_0x3568db('0x13')][_0x3568db('0x30')]),_0x2f4a2a[_0x3568db('0x6')]=qs[_0x3568db('0x20')](_[_0x3568db('0x46')](_0x5b0b75[_0x3568db('0x13')],_0x4c9bb5[_0x3568db('0x20')])),_0x5b0b75[_0x3568db('0x13')][_0x3568db('0x3d')]&&(_0x2f4a2a['where']=_[_0x3568db('0xc')](_0x2f4a2a[_0x3568db('0x6')],{[Op['or']]:_['map'](_0x2f4a2a['attributes'],function(_0x50c72d){const _0x1df373=_0x3568db,_0x3a17b6={};return _0x3a17b6[_0x50c72d]={[Op[_0x1df373('0xf')]]:'%'+_0x5b0b75[_0x1df373('0x13')][_0x1df373('0x3d')]+'%'},_0x3a17b6;})})),_0x2f4a2a=_['merge']({},_0x2f4a2a,_0x5b0b75[_0x3568db('0x1d')]),_0x580ca7[_0x3568db('0x42')](_0x2f4a2a);})[_0x5eeca0('0xd')](function(_0x37019e){const _0x2b8651=_0x5eeca0;if(_0x37019e)return _0x53818d=_0x37019e[_0x2b8651('0x21')],typeof _0x5b0b75[_0x2b8651('0x13')][_0x2b8651('0x32')]===_0x2b8651('0x3e')&&(_0x2f4a2a[_0x2b8651('0x7')]=qs[_0x2b8651('0x7')](_0x5b0b75[_0x2b8651('0x13')][_0x2b8651('0x7')]),_0x2f4a2a['offset']=qs[_0x2b8651('0x34')](_0x5b0b75[_0x2b8651('0x13')][_0x2b8651('0x34')])),_0x580ca7[_0x2b8651('0x42')](_0x2f4a2a);})[_0x5eeca0('0xd')](function(_0x1ed5c1){if(_0x1ed5c1)return _0x1ed5c1?{'count':_0x53818d,'rows':_0x1ed5c1}:null;})[_0x5eeca0('0xd')](respondWithResult(_0x4b5ff2,null))[_0x5eeca0('0x40')](handleError(_0x4b5ff2,null));},exports[_0x4b376c('0x3a')]=function(_0x5dd291,_0x513116){const _0x58beff=_0x4b376c;return db[_0x58beff('0x41')][_0x58beff('0x1f')]({'where':{'id':_0x5dd291[_0x58beff('0x3f')]['id']}})[_0x58beff('0xd')](handleEntityNotFound(_0x513116,null))[_0x58beff('0xd')](function(_0x285566){const _0x2e0341=_0x58beff;if(_0x285566)return _0x285566[_0x2e0341('0x3a')](_0x5dd291[_0x2e0341('0x13')][_0x2e0341('0x38')]);})[_0x58beff('0xd')](respondWithStatusCode(_0x513116,null))[_0x58beff('0x40')](handleError(_0x513116,null));},exports[_0x4b376c('0x3b')]=function(_0x144f8a,_0x2b7ee0){const _0x1450bd=_0x4b376c;return _0x144f8a['body']['id']&&delete _0x144f8a['body']['id'],db[_0x1450bd('0x41')][_0x1450bd('0x1f')]({'where':{'id':_0x144f8a[_0x1450bd('0x3f')]['id']}})[_0x1450bd('0xd')](handleEntityNotFound(_0x2b7ee0,null))[_0x1450bd('0xd')](function(_0x5c43de){const _0x2eb0f1=_0x1450bd;if(_0x5c43de)return _0x144f8a[_0x2eb0f1('0x43')][_0x2eb0f1('0x22')]=_0x5c43de['id'],db[_0x2eb0f1('0x12')][_0x2eb0f1('0x14')](_0x144f8a['body']);})[_0x1450bd('0xd')](respondWithResult(_0x2b7ee0,null))[_0x1450bd('0x40')](handleError(_0x2b7ee0,null));},exports[_0x4b376c('0x2a')]=function(_0x27d641,_0x18a08d){const _0x34bd5b=_0x4b376c;let _0x3779e8={};const _0x2de110={};let _0x4e75b8,_0xebf419;return db[_0x34bd5b('0x41')][_0x34bd5b('0x1f')]({'where':{'id':_0x27d641[_0x34bd5b('0x3f')]['id']}})[_0x34bd5b('0xd')](handleEntityNotFound(_0x18a08d,null))[_0x34bd5b('0xd')](function(_0x222e5e){const _0xf437d=_0x34bd5b;if(_0x222e5e){_0x4e75b8=_0x222e5e,_0x2de110[_0xf437d('0x4')]=_['keys'](db[_0xf437d('0x12')][_0xf437d('0x3c')]),_0x2de110[_0xf437d('0x13')]=_[_0xf437d('0x15')](_0x27d641[_0xf437d('0x13')]),_0x2de110['filters']=_['intersection'](_0x2de110['model'],_0x2de110['query']),_0x3779e8[_0xf437d('0x2f')]=_[_0xf437d('0x17')](_0x2de110['model'],qs[_0xf437d('0x1e')](_0x27d641[_0xf437d('0x13')][_0xf437d('0x1e')])),_0x3779e8[_0xf437d('0x2f')]=_0x3779e8['attributes'][_0xf437d('0x21')]?_0x3779e8[_0xf437d('0x2f')]:_0x2de110[_0xf437d('0x4')],_0x3779e8[_0xf437d('0x2d')]=qs[_0xf437d('0x30')](_0x27d641[_0xf437d('0x13')][_0xf437d('0x30')]),_0x3779e8[_0xf437d('0x6')]=qs[_0xf437d('0x20')](_[_0xf437d('0x46')](_0x27d641[_0xf437d('0x13')],_0x2de110[_0xf437d('0x20')]));_0x27d641[_0xf437d('0x13')][_0xf437d('0x3d')]&&(_0x3779e8[_0xf437d('0x6')]=_[_0xf437d('0xc')](_0x3779e8[_0xf437d('0x6')],{[Op['or']]:_[_0xf437d('0x1b')](_0x3779e8[_0xf437d('0x2f')],function(_0x4119ab){const _0x28c00a=_0xf437d,_0x15b94a={};return _0x15b94a[_0x4119ab]={[Op[_0x28c00a('0xf')]]:'%'+_0x27d641['query'][_0x28c00a('0x3d')]+'%'},_0x15b94a;})}));if(_0x27d641[_0xf437d('0x13')][_0xf437d('0x27')]){const _0x2117fb=_0x27d641[_0xf437d('0x13')]['$gte']['split'](','),_0x2c5839={};_0x2c5839[_0x2117fb[0x0]]={[Op[_0xf437d('0x10')]]:moment(_0x2117fb[0x1])[_0xf437d('0x2')]('YYYY-MM-DD\x20HH:mm:ss')},_0x3779e8[_0xf437d('0x6')]=_[_0xf437d('0xc')](_0x3779e8['where'],_0x2c5839);}return _0x3779e8=_['merge']({},_0x3779e8,_0x27d641['options']),_0x4e75b8[_0xf437d('0x2a')](_0x3779e8);}})[_0x34bd5b('0xd')](function(_0x3a4e09){const _0x315270=_0x34bd5b;if(_0x3a4e09)return _0xebf419=_0x3a4e09[_0x315270('0x21')],typeof _0x27d641['query'][_0x315270('0x32')]==='undefined'&&(_0x3779e8[_0x315270('0x7')]=qs[_0x315270('0x7')](_0x27d641['query'][_0x315270('0x7')]),_0x3779e8['offset']=qs[_0x315270('0x34')](_0x27d641[_0x315270('0x13')][_0x315270('0x34')])),_0x4e75b8['getMessages'](_0x3779e8);})[_0x34bd5b('0xd')](function(_0x16d66f){if(_0x16d66f)return _0x16d66f?{'count':_0xebf419,'rows':_0x16d66f}:null;})['then'](respondWithResult(_0x18a08d,null))[_0x34bd5b('0x40')](handleError(_0x18a08d,null));}; \ No newline at end of file diff --git a/server/api/chatGroup/chatGroup.events.js b/server/api/chatGroup/chatGroup.events.js index dbe4e24..dab18a0 100644 --- a/server/api/chatGroup/chatGroup.events.js +++ b/server/api/chatGroup/chatGroup.events.js @@ -1 +1 @@ -const a60_0x34da=['undefined','setMaxListeners','remove','save','../../mysqldb','events','exports','ChatGroup','emit'];(function(_0x23ea59,_0x34da3e){const _0x5f4752=function(_0x2c48d2){while(--_0x2c48d2){_0x23ea59['push'](_0x23ea59['shift']());}};_0x5f4752(++_0x34da3e);}(a60_0x34da,0x1a4));const a60_0x5f47=function(_0x23ea59,_0x34da3e){_0x23ea59=_0x23ea59-0x0;let _0x5f4752=a60_0x34da[_0x23ea59];return _0x5f4752;};const _0x4ea1fb=a60_0x5f47;'use strict';const EventEmitter=require(_0x4ea1fb('0x8')),ChatGroup=require(_0x4ea1fb('0x7'))['db'][_0x4ea1fb('0x1')],ChatGroupEvents=new EventEmitter();ChatGroupEvents[_0x4ea1fb('0x4')](0x0);const events={'afterCreate':_0x4ea1fb('0x6'),'afterUpdate':'update','afterDestroy':_0x4ea1fb('0x5')};function emitEvent(_0x2c48d2){return function(_0x226215){const _0x5353f3=a60_0x5f47;ChatGroupEvents[_0x5353f3('0x2')](_0x2c48d2+':'+_0x226215['id'],_0x226215),ChatGroupEvents['emit'](_0x2c48d2,_0x226215);};}for(const e in events){if(typeof events[e]!==_0x4ea1fb('0x3')){const event=events[e];ChatGroup['addHook'](e,emitEvent(event));}}module[_0x4ea1fb('0x0')]=ChatGroupEvents; \ No newline at end of file +const a60_0x308c=['addHook','undefined','events','emit','save','ChatGroup','remove','setMaxListeners','update'];(function(_0x1f022f,_0x308cb0){const _0x34ac6f=function(_0x499c03){while(--_0x499c03){_0x1f022f['push'](_0x1f022f['shift']());}};_0x34ac6f(++_0x308cb0);}(a60_0x308c,0x18f));const a60_0x34ac=function(_0x1f022f,_0x308cb0){_0x1f022f=_0x1f022f-0x0;let _0x34ac6f=a60_0x308c[_0x1f022f];return _0x34ac6f;};const _0x532e7d=a60_0x34ac;'use strict';const EventEmitter=require(_0x532e7d('0x8')),ChatGroup=require('../../mysqldb')['db'][_0x532e7d('0x2')],ChatGroupEvents=new EventEmitter();ChatGroupEvents[_0x532e7d('0x4')](0x0);const events={'afterCreate':_0x532e7d('0x1'),'afterUpdate':_0x532e7d('0x5'),'afterDestroy':_0x532e7d('0x3')};function emitEvent(_0x499c03){return function(_0x1aa4df){const _0x46bf3e=a60_0x34ac;ChatGroupEvents[_0x46bf3e('0x0')](_0x499c03+':'+_0x1aa4df['id'],_0x1aa4df),ChatGroupEvents[_0x46bf3e('0x0')](_0x499c03,_0x1aa4df);};}for(const e in events){if(typeof events[e]!==_0x532e7d('0x7')){const event=events[e];ChatGroup[_0x532e7d('0x6')](e,emitEvent(event));}}module['exports']=ChatGroupEvents; \ No newline at end of file diff --git a/server/api/chatGroup/chatGroup.model.js b/server/api/chatGroup/chatGroup.model.js index 162f4e1..3a61b45 100644 --- a/server/api/chatGroup/chatGroup.model.js +++ b/server/api/chatGroup/chatGroup.model.js @@ -1 +1 @@ -const a61_0x3576=['ChatGroup','define','exports','./chatGroup.attributes','chat_groups'];(function(_0x107698,_0x357661){const _0x310529=function(_0x371723){while(--_0x371723){_0x107698['push'](_0x107698['shift']());}};_0x310529(++_0x357661);}(a61_0x3576,0x182));const a61_0x3105=function(_0x107698,_0x357661){_0x107698=_0x107698-0x0;let _0x310529=a61_0x3576[_0x107698];return _0x310529;};const _0x183f35=a61_0x3105;'use strict';const attributes=require(_0x183f35('0x2'));module[_0x183f35('0x1')]=function(_0x371723){const _0x444999=_0x183f35,_0x333f71=_0x371723[_0x444999('0x0')](_0x444999('0x4'),attributes,{'tableName':_0x444999('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x333f71;}; \ No newline at end of file +const a61_0x5ac4=['ChatGroup','define','chat_groups','./chatGroup.attributes','exports'];(function(_0x39fbe2,_0x5ac4b1){const _0x5b971d=function(_0x342873){while(--_0x342873){_0x39fbe2['push'](_0x39fbe2['shift']());}};_0x5b971d(++_0x5ac4b1);}(a61_0x5ac4,0x1d9));const a61_0x5b97=function(_0x39fbe2,_0x5ac4b1){_0x39fbe2=_0x39fbe2-0x0;let _0x5b971d=a61_0x5ac4[_0x39fbe2];return _0x5b971d;};const _0x539d59=a61_0x5b97;'use strict';const attributes=require(_0x539d59('0x0'));module[_0x539d59('0x1')]=function(_0x342873){const _0x3ee307=_0x539d59,_0x275095=_0x342873[_0x3ee307('0x3')](_0x3ee307('0x2'),attributes,{'tableName':_0x3ee307('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x275095;}; \ No newline at end of file diff --git a/server/api/chatGroup/chatGroup.rpc.js b/server/api/chatGroup/chatGroup.rpc.js index f45ba37..f556b9a 100644 --- a/server/api/chatGroup/chatGroup.rpc.js +++ b/server/api/chatGroup/chatGroup.rpc.js @@ -1 +1 @@ -const a62_0x24f9=['../../rediscache','register','./chatGroup.socket'];(function(_0x557b66,_0x24f936){const _0x27f647=function(_0x1b3b72){while(--_0x1b3b72){_0x557b66['push'](_0x557b66['shift']());}};_0x27f647(++_0x24f936);}(a62_0x24f9,0x1b7));const a62_0x27f6=function(_0x557b66,_0x24f936){_0x557b66=_0x557b66-0x0;let _0x27f647=a62_0x24f9[_0x557b66];return _0x27f647;};const _0x49b2d9=a62_0x27f6;'use strict';const {getSocket}=require(_0x49b2d9('0x2')),socket=getSocket();require(_0x49b2d9('0x1'))[_0x49b2d9('0x0')](socket); \ No newline at end of file +const a62_0x37d8=['../../rediscache','register','./chatGroup.socket'];(function(_0x2a1d26,_0x37d85d){const _0x381084=function(_0x1d652a){while(--_0x1d652a){_0x2a1d26['push'](_0x2a1d26['shift']());}};_0x381084(++_0x37d85d);}(a62_0x37d8,0x19c));const a62_0x3810=function(_0x2a1d26,_0x37d85d){_0x2a1d26=_0x2a1d26-0x0;let _0x381084=a62_0x37d8[_0x2a1d26];return _0x381084;};const _0x3cd5d9=a62_0x3810;'use strict';const {getSocket}=require(_0x3cd5d9('0x2')),socket=getSocket();require(_0x3cd5d9('0x1'))[_0x3cd5d9('0x0')](socket); \ No newline at end of file diff --git a/server/api/chatGroup/chatGroup.socket.js b/server/api/chatGroup/chatGroup.socket.js index 928d024..4dec780 100644 --- a/server/api/chatGroup/chatGroup.socket.js +++ b/server/api/chatGroup/chatGroup.socket.js @@ -1 +1 @@ -const a63_0x3acb=['length','register','emit','chatGroup:'];(function(_0x23b95a,_0x3acb70){const _0xfde3df=function(_0x356792){while(--_0x356792){_0x23b95a['push'](_0x23b95a['shift']());}};_0xfde3df(++_0x3acb70);}(a63_0x3acb,0xc8));const a63_0xfde3=function(_0x23b95a,_0x3acb70){_0x23b95a=_0x23b95a-0x0;let _0xfde3df=a63_0x3acb[_0x23b95a];return _0xfde3df;};const _0x2d0ff1=a63_0xfde3;'use strict';const ChatGroupEvents=require('./chatGroup.events'),events=['save','remove','update'];function createListener(_0x356792,_0x4be1d6){return function(_0x3b469a){const _0x8bff56=a63_0xfde3;_0x4be1d6[_0x8bff56('0x2')](_0x356792,_0x3b469a);};}exports[_0x2d0ff1('0x1')]=function(_0x2038b8){const _0x31fe70=_0x2d0ff1;for(let _0x2a440d=0x0,_0x9e2841=events[_0x31fe70('0x0')];_0x2a440d<_0x9e2841;_0x2a440d++){const _0x2ce86f=events[_0x2a440d],_0x4236ff=createListener(_0x31fe70('0x3')+_0x2ce86f,_0x2038b8);ChatGroupEvents['on'](_0x2ce86f,_0x4236ff);}}; \ No newline at end of file +const a63_0x5665=['register','save','remove','emit','update','chatGroup:','length','./chatGroup.events'];(function(_0x486261,_0x5665ef){const _0x560b14=function(_0x162755){while(--_0x162755){_0x486261['push'](_0x486261['shift']());}};_0x560b14(++_0x5665ef);}(a63_0x5665,0xaf));const a63_0x560b=function(_0x486261,_0x5665ef){_0x486261=_0x486261-0x0;let _0x560b14=a63_0x5665[_0x486261];return _0x560b14;};const _0xdc980=a63_0x560b;'use strict';const ChatGroupEvents=require(_0xdc980('0x0')),events=[_0xdc980('0x2'),_0xdc980('0x3'),_0xdc980('0x5')];function createListener(_0x162755,_0x3fb332){return function(_0x494c4a){const _0x39ac3d=a63_0x560b;_0x3fb332[_0x39ac3d('0x4')](_0x162755,_0x494c4a);};}exports[_0xdc980('0x1')]=function(_0x508ad4){const _0x477be9=_0xdc980;for(let _0x647e4e=0x0,_0x492faf=events[_0x477be9('0x7')];_0x647e4e<_0x492faf;_0x647e4e++){const _0x55d5c1=events[_0x647e4e],_0x5ad8ce=createListener(_0x477be9('0x6')+_0x55d5c1,_0x508ad4);ChatGroupEvents['on'](_0x55d5c1,_0x5ad8ce);}}; \ No newline at end of file diff --git a/server/api/chatGroup/index.js b/server/api/chatGroup/index.js index 1107a99..9e91c7d 100644 --- a/server/api/chatGroup/index.js +++ b/server/api/chatGroup/index.js @@ -1 +1 @@ -const a64_0x1ec0=['describe','put','addMessage','/:id/messages','update','getMessages','addMembers','Router','create','show','delete','/:id','/:id/members','getUnread','./chatGroup.controller','get','/:id/unread','/describe','exports','removeMembers','express','index','isAuthenticated','post'];(function(_0x3526a2,_0x1ec01c){const _0xb2deb5=function(_0xedb05a){while(--_0xedb05a){_0x3526a2['push'](_0x3526a2['shift']());}};_0xb2deb5(++_0x1ec01c);}(a64_0x1ec0,0x7d));const a64_0xb2de=function(_0x3526a2,_0x1ec01c){_0x3526a2=_0x3526a2-0x0;let _0xb2deb5=a64_0x1ec0[_0x3526a2];return _0xb2deb5;};const _0x57e802=a64_0xb2de;'use strict';const express=require(_0x57e802('0xf')),router=express[_0x57e802('0x2')](),auth=require('../../components/auth/service'),controller=require(_0x57e802('0x9'));router[_0x57e802('0xa')]('/',auth[_0x57e802('0x11')](),controller[_0x57e802('0x10')]),router[_0x57e802('0xa')](_0x57e802('0xc'),auth['isAuthenticated'](),controller[_0x57e802('0x13')]),router[_0x57e802('0xa')](_0x57e802('0x6'),auth[_0x57e802('0x11')](),controller[_0x57e802('0x4')]),router[_0x57e802('0xa')](_0x57e802('0xb'),auth[_0x57e802('0x11')](),controller[_0x57e802('0x8')]),router[_0x57e802('0xa')](_0x57e802('0x7'),auth[_0x57e802('0x11')](),controller['getMembers']),router[_0x57e802('0xa')](_0x57e802('0x16'),auth[_0x57e802('0x11')](),controller[_0x57e802('0x0')]),router[_0x57e802('0x12')]('/',auth[_0x57e802('0x11')](),controller[_0x57e802('0x3')]),router[_0x57e802('0x12')](_0x57e802('0x7'),auth[_0x57e802('0x11')](),controller[_0x57e802('0x1')]),router[_0x57e802('0x12')](_0x57e802('0x16'),auth['isAuthenticated'](),controller[_0x57e802('0x15')]),router[_0x57e802('0x14')](_0x57e802('0x6'),auth['isAuthenticated'](),controller[_0x57e802('0x17')]),router[_0x57e802('0x5')]('/:id',auth[_0x57e802('0x11')](),controller['destroy']),router[_0x57e802('0x5')](_0x57e802('0x7'),auth['isAuthenticated'](),controller[_0x57e802('0xe')]),module[_0x57e802('0xd')]=router; \ No newline at end of file +const a64_0x2f55=['put','./chatGroup.controller','removeMembers','index','isAuthenticated','/:id/messages','delete','express','addMembers','show','post','/:id','/:id/members','create','getMessages','describe','Router','get','/describe','/:id/unread','addMessage','exports','destroy'];(function(_0x1d1d58,_0x2f551b){const _0x20a520=function(_0x3d6e4a){while(--_0x3d6e4a){_0x1d1d58['push'](_0x1d1d58['shift']());}};_0x20a520(++_0x2f551b);}(a64_0x2f55,0x11a));const a64_0x20a5=function(_0x1d1d58,_0x2f551b){_0x1d1d58=_0x1d1d58-0x0;let _0x20a520=a64_0x2f55[_0x1d1d58];return _0x20a520;};const _0x3e8eaf=a64_0x20a5;'use strict';const express=require(_0x3e8eaf('0x1')),router=express[_0x3e8eaf('0xa')](),auth=require('../../components/auth/service'),controller=require(_0x3e8eaf('0x12'));router[_0x3e8eaf('0xb')]('/',auth[_0x3e8eaf('0x15')](),controller[_0x3e8eaf('0x14')]),router[_0x3e8eaf('0xb')](_0x3e8eaf('0xc'),auth[_0x3e8eaf('0x15')](),controller[_0x3e8eaf('0x9')]),router[_0x3e8eaf('0xb')](_0x3e8eaf('0x5'),auth[_0x3e8eaf('0x15')](),controller[_0x3e8eaf('0x3')]),router[_0x3e8eaf('0xb')](_0x3e8eaf('0xd'),auth[_0x3e8eaf('0x15')](),controller['getUnread']),router[_0x3e8eaf('0xb')](_0x3e8eaf('0x6'),auth[_0x3e8eaf('0x15')](),controller['getMembers']),router[_0x3e8eaf('0xb')](_0x3e8eaf('0x16'),auth[_0x3e8eaf('0x15')](),controller[_0x3e8eaf('0x8')]),router[_0x3e8eaf('0x4')]('/',auth['isAuthenticated'](),controller[_0x3e8eaf('0x7')]),router[_0x3e8eaf('0x4')](_0x3e8eaf('0x6'),auth['isAuthenticated'](),controller[_0x3e8eaf('0x2')]),router[_0x3e8eaf('0x4')]('/:id/messages',auth['isAuthenticated'](),controller[_0x3e8eaf('0xe')]),router[_0x3e8eaf('0x11')](_0x3e8eaf('0x5'),auth['isAuthenticated'](),controller['update']),router['delete']('/:id',auth['isAuthenticated'](),controller[_0x3e8eaf('0x10')]),router[_0x3e8eaf('0x0')](_0x3e8eaf('0x6'),auth[_0x3e8eaf('0x15')](),controller[_0x3e8eaf('0x13')]),module[_0x3e8eaf('0xf')]=router; \ No newline at end of file diff --git a/server/api/chatInteraction/chatInteraction.attributes.js b/server/api/chatInteraction/chatInteraction.attributes.js index e63b453..47f5e85 100644 --- a/server/api/chatInteraction/chatInteraction.attributes.js +++ b/server/api/chatInteraction/chatInteraction.attributes.js @@ -1 +1 @@ -const a65_0x1a6c=['DATE','TEXT','ENUM','BOOLEAN','STRING','star','out','thumb','exports'];(function(_0x434ca5,_0x1a6c9b){const _0x42145d=function(_0x5d7bc2){while(--_0x5d7bc2){_0x434ca5['push'](_0x434ca5['shift']());}};_0x42145d(++_0x1a6c9b);}(a65_0x1a6c,0x19f));const a65_0x4214=function(_0x434ca5,_0x1a6c9b){_0x434ca5=_0x434ca5-0x0;let _0x42145d=a65_0x1a6c[_0x434ca5];return _0x42145d;};const _0x56e915=a65_0x4214;'use strict';const Sequelize=require('sequelize');module[_0x56e915('0x7')]={'closed':{'type':Sequelize[_0x56e915('0x2')],'defaultValue':![]},'ratingValue':{'type':Sequelize['INTEGER']},'ratingType':{'type':Sequelize[_0x56e915('0x1')]('star',_0x56e915('0x6')),'defaultValue':_0x56e915('0x4')},'ratingMessage':{'type':Sequelize[_0x56e915('0x0')]},'pathTranscript':{'type':Sequelize[_0x56e915('0x0')]},'mailTranscript':{'type':Sequelize['STRING'],'validate':{'isEmail':!![]}},'closedAt':{'type':Sequelize[_0x56e915('0x8')]},'disposition':{'type':Sequelize[_0x56e915('0x3')]},'secondDisposition':{'type':Sequelize[_0x56e915('0x3')]},'thirdDisposition':{'type':Sequelize[_0x56e915('0x3')]},'note':{'type':Sequelize['STRING']},'browserName':{'type':Sequelize[_0x56e915('0x3')]},'browserVersion':{'type':Sequelize['STRING']},'osName':{'type':Sequelize[_0x56e915('0x3')]},'osVersion':{'type':Sequelize[_0x56e915('0x3')]},'deviceModel':{'type':Sequelize['STRING']},'deviceVendor':{'type':Sequelize[_0x56e915('0x3')]},'deviceType':{'type':Sequelize[_0x56e915('0x3')]},'referer':{'type':Sequelize[_0x56e915('0x0')]},'customerIp':{'type':Sequelize['STRING']},'formData':{'type':Sequelize[_0x56e915('0x0')]('long')},'read1stAt':{'type':Sequelize['DATE']},'lastMsgAt':{'type':Sequelize[_0x56e915('0x8')]},'lastMsgDirection':{'type':Sequelize['ENUM']('in',_0x56e915('0x5')),'defaultValue':'in','allowNull':![]},'closeReason':{'type':Sequelize[_0x56e915('0x3')]},'customerPort':{'type':Sequelize['STRING']},'vidaooSessionId':{'type':Sequelize['TEXT']}}; \ No newline at end of file +const a65_0x2ebe=['long','INTEGER','BOOLEAN','DATE','ENUM','STRING','star','out','thumb','exports','TEXT'];(function(_0x3a488f,_0x2ebefc){const _0x599a54=function(_0x4f2538){while(--_0x4f2538){_0x3a488f['push'](_0x3a488f['shift']());}};_0x599a54(++_0x2ebefc);}(a65_0x2ebe,0xbb));const a65_0x599a=function(_0x3a488f,_0x2ebefc){_0x3a488f=_0x3a488f-0x0;let _0x599a54=a65_0x2ebe[_0x3a488f];return _0x599a54;};const _0x2dc5bb=a65_0x599a;'use strict';const Sequelize=require('sequelize');module[_0x2dc5bb('0x9')]={'closed':{'type':Sequelize[_0x2dc5bb('0x2')],'defaultValue':![]},'ratingValue':{'type':Sequelize[_0x2dc5bb('0x1')]},'ratingType':{'type':Sequelize['ENUM'](_0x2dc5bb('0x6'),_0x2dc5bb('0x8')),'defaultValue':'star'},'ratingMessage':{'type':Sequelize[_0x2dc5bb('0xa')]},'pathTranscript':{'type':Sequelize[_0x2dc5bb('0xa')]},'mailTranscript':{'type':Sequelize['STRING'],'validate':{'isEmail':!![]}},'closedAt':{'type':Sequelize[_0x2dc5bb('0x3')]},'disposition':{'type':Sequelize[_0x2dc5bb('0x5')]},'secondDisposition':{'type':Sequelize[_0x2dc5bb('0x5')]},'thirdDisposition':{'type':Sequelize[_0x2dc5bb('0x5')]},'note':{'type':Sequelize['STRING']},'browserName':{'type':Sequelize[_0x2dc5bb('0x5')]},'browserVersion':{'type':Sequelize['STRING']},'osName':{'type':Sequelize[_0x2dc5bb('0x5')]},'osVersion':{'type':Sequelize[_0x2dc5bb('0x5')]},'deviceModel':{'type':Sequelize['STRING']},'deviceVendor':{'type':Sequelize[_0x2dc5bb('0x5')]},'deviceType':{'type':Sequelize[_0x2dc5bb('0x5')]},'referer':{'type':Sequelize['TEXT']},'customerIp':{'type':Sequelize[_0x2dc5bb('0x5')]},'formData':{'type':Sequelize[_0x2dc5bb('0xa')](_0x2dc5bb('0x0'))},'read1stAt':{'type':Sequelize[_0x2dc5bb('0x3')]},'lastMsgAt':{'type':Sequelize[_0x2dc5bb('0x3')]},'lastMsgDirection':{'type':Sequelize[_0x2dc5bb('0x4')]('in',_0x2dc5bb('0x7')),'defaultValue':'in','allowNull':![]},'closeReason':{'type':Sequelize['STRING']},'customerPort':{'type':Sequelize['STRING']},'vidaooSessionId':{'type':Sequelize[_0x2dc5bb('0xa')]}}; \ No newline at end of file diff --git a/server/api/chatInteraction/chatInteraction.controller.js b/server/api/chatInteraction/chatInteraction.controller.js index c4276c7..d9c36df 100644 --- a/server/api/chatInteraction/chatInteraction.controller.js +++ b/server/api/chatInteraction/chatInteraction.controller.js @@ -1 +1 @@ -const a66_0x4869=['appendFileSync','undefined','keyBy','closedAt','server','findOne','ChatInteraction','color','Mail\x20Transcript','YYYY-MM-DD','isNumeric','conditions','unix','message','attachId','Tag','include','i.ChatWebsiteId\x20IS\x20NULL','select','tmp','Error\x20in\x20Vidaoo\x20configuration','log','follow','where','rawAttributes','filter','pathTranscript','operator','abandon','views','i.createdAt\x20BETWEEN\x20?\x20AND\x20?','cm_contacts','pick','customerPort','options','buildExpression','.pdf','nolimit','Account','info','attachments','30px','o.id\x20=\x20i.UserId','Owner.fullname','describe','auth','download','YYYY-MM-DD\x20HH:mm:ss','emit','c.firstName','chat_interactions','closed','join','authentication','update','c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?','attributes','u.id\x20=\x20ui.UserId','i.*','User','agentAlias','request','users','Contact.phone','abandonInteraction,\x20%s,\x20%s,\x20%s','../../config/logger','Smtp','expr','a.id\x20=\x20i.ChatWebsiteId','Contact','Interaction\x20already\x20assigned','c.fax','alias','sqlOperator','format','request\x20sent','chat_messages','i.id\x20LIKE\x20?','basename','filters','create','lastName','ejs','port','includeAgent','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','agent_alias','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','rows','get','files','removeTags','type','name','Account.mandatoryDisposition','`unreadMessages`\x20>\x200','compact','user','Tags','omit','query','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','i.ChatWebsiteId\x20IS\x20NOT\x20NULL','value','model','fieldName','Visitor','$gte','root','tag','status','MM/DD/YYYY\x20HH:mm:ss','browserName','ChatInteractionId','getFullTextValue','createReadStream','getMessages','Contact.fax','json','o.fullname','../../rediscache','offset','isArray','./chatInteraction.socket','existsSync','attachmentDownload','c.email','stringify','POST','\x20=\x20?','send','debug','Unauthorized','SELECT','count','i.ChatWebsiteId\x20IN\x20?','customUpdate','join_url','\x27\x27\x27\x27','toFile','like','client','request-promise-native','files/attachments/','entity\x20not\x20found','find','direction','40px','CmContact','merge','createWriteStream','Owner.internal','out','findAll','N.A.','$lte','Hi\x20%s,\x20attached\x20you\x20can\x20find\x20your\x20transcript\x20file.\x20\x0a\x0aRegards.\x20\x0a\x0a','vidaooEscalation','10px','unreadMessages','includeAll','email','push','from','tail','index','attachmentUpload','it.ChatInteractionId\x20=\x20i.id','service','Contact.mobile','firstName','u.id','left_join','length','Account.key','moment','mkdirSync','customerIp','search','transcript-','http','register','intersection','body','start','tools_tags','rimraf','clone','\x22%s\x22\x20<%s>','ChatWebsite','ContactId','[%s]\x20%s:\x20%s\x0a','ChatMessage','read','ChatWebsiteId','all','System','file','Attachment','journey','user_has_chat_interactions','MailServerOut','then','toString','u.fullname','addMessage','field','order','c.phone','host','Users','../../config/environment','ChatInteraction,\x20%s,\x20%s','parse','mailTranscript','sendStatus','secret','some','split','sort','sequelize','map','../../components/parsers/qs','vidaooApiKey','limit','originalname','Messages','concat','ids','destroy','i.id','MailAccount','squel','lodash','\x20IS\x20NULL','path','replace','params','fields','isEmpty','error','html-pdf','catch','`unreadMessages`\x20=\x200','err','$substring','forEach','`\x20>\x200','filename','gte','close','secure','disposition','`\x20=\x200','getChatWebsites','text','zip-dir','UserId','mimetype','end','having','Chat','fullname','groupBy','createdAt','pipe','GROUP_CONCAT(DISTINCT\x20t.id)','show','ui.ChatInteractionId\x20IN\x20?','agent_fullname','%s%d','keys'];(function(_0x35059e,_0x48690f){const _0x20dc89=function(_0x528d68){while(--_0x528d68){_0x35059e['push'](_0x35059e['shift']());}};_0x20dc89(++_0x48690f);}(a66_0x4869,0x9d));const a66_0x20dc=function(_0x35059e,_0x48690f){_0x35059e=_0x35059e-0x0;let _0x20dc89=a66_0x4869[_0x35059e];return _0x20dc89;};const _0x4b28f7=a66_0x20dc;'use strict';const pdf=require(_0x4b28f7('0x54')),rimraf=require(_0x4b28f7('0x1d')),zipdir=require(_0x4b28f7('0x63')),rp=require(_0x4b28f7('0x101')),moment=require(_0x4b28f7('0x12')),util=require('util'),path=require(_0x4b28f7('0x4e')),ejs=require(_0x4b28f7('0xc5')),fs=require('fs'),_=require(_0x4b28f7('0x4c')),squel=require(_0x4b28f7('0x4b')),{getSocket}=require(_0x4b28f7('0xeb')),qs=require(_0x4b28f7('0x41')),as=require('../../components/parsers/advancedSearch'),logger=require(_0x4b28f7('0xb4'))('api'),config=require(_0x4b28f7('0x36')),db=require('../../mysqldb')['db'],{Op,ValidationError,QueryTypes}=require(_0x4b28f7('0x3f')),socket=getSocket();require(_0x4b28f7('0xee'))[_0x4b28f7('0x18')](socket);const jayson=require('jayson/promise'),client=jayson[_0x4b28f7('0x100')]['http']({'port':0x232b}),client9004=jayson[_0x4b28f7('0x100')][_0x4b28f7('0x17')]({'port':0x232c});function respondWithRpcPromise(_0x528d68,_0x3092ef,_0x1061fb,_0x863419){return new Promise(function(_0x5ce490,_0x452db8){const _0x38a15a=a66_0x20dc,_0x78927f=_0x863419||client;return _0x78927f[_0x38a15a('0xb0')](_0x528d68,_0x1061fb)['then'](function(_0xc16762){const _0x17a100=_0x38a15a;logger['info'](_0x17a100('0x37'),_0x3092ef,_0x17a100('0xbe')),logger[_0x17a100('0xf6')]('ChatInteraction,\x20%s,\x20%s,\x20%s',_0x3092ef,_0x17a100('0xbe'),JSON[_0x17a100('0xf2')](_0xc16762));if(_0xc16762[_0x17a100('0x53')]){if(_0xc16762[_0x17a100('0x53')]['code']===0x1f4)return logger[_0x17a100('0x53')]('ChatInteraction,\x20%s,\x20%s',_0x3092ef,_0xc16762[_0x17a100('0x53')][_0x17a100('0x80')]),_0x452db8(_0xc16762['error'][_0x17a100('0x80')]);return logger[_0x17a100('0x53')]('ChatInteraction,\x20%s,\x20%s',_0x3092ef,_0xc16762[_0x17a100('0x53')][_0x17a100('0x80')]),_0x5ce490(_0xc16762[_0x17a100('0x53')]['message']);}else logger[_0x17a100('0x9a')](_0x17a100('0x37'),_0x3092ef,_0x17a100('0xbe')),_0x5ce490(_0xc16762['result'][_0x17a100('0x80')]);})['catch'](function(_0x45d6e4){const _0xc66b4d=_0x38a15a;logger[_0xc66b4d('0x53')]('ChatInteraction,\x20%s,\x20%s',_0x3092ef,_0x45d6e4),_0x452db8(_0x45d6e4);});});}function respondWithStatusCode(_0x2417c3,_0x43b78f){return _0x43b78f=_0x43b78f||0xcc,function(_0x1e01ec){const _0x15f6c5=a66_0x20dc;if(_0x1e01ec)return _0x2417c3[_0x15f6c5('0x3a')](_0x43b78f);return _0x2417c3[_0x15f6c5('0xe1')](_0x43b78f)[_0x15f6c5('0x66')]();};}function respondWithResult(_0x3b931e,_0x497c1e){return _0x497c1e=_0x497c1e||0xc8,function(_0x7793e9){const _0x1d8214=a66_0x20dc;if(_0x7793e9)return _0x3b931e[_0x1d8214('0xe1')](_0x497c1e)['json'](_0x7793e9);};}function respondWithFilteredResult(_0x1e89f7,_0x13ca1e){return function(_0x5def68){const _0x1ab5d8=a66_0x20dc;if(_0x5def68){const _0x1ecced=_0x5def68[_0x1ab5d8('0xf9')],_0x17544b=_0x13ca1e[_0x1ab5d8('0xec')];let _0x2e2d81=_0x13ca1e['offset']+_0x13ca1e[_0x1ab5d8('0x43')],_0x10948f;return _0x2e2d81>=_0x1ecced?(_0x2e2d81=_0x1ecced,_0x10948f=0xc8):_0x10948f=0xce,_0x1e89f7['status'](_0x10948f),_0x1e89f7['set']('Content-Range',_0x17544b+'-'+_0x2e2d81+'/'+_0x1ecced)[_0x1ab5d8('0xe9')](_0x5def68);}return null;};}function saveUpdates(_0xaf7e97){return function(_0x303684){const _0x5c6efb=a66_0x20dc;if(_0x303684)return _0x303684[_0x5c6efb('0xa9')](_0xaf7e97)['then'](function(_0x4bd10e){return _0x4bd10e;});return null;};}function removeEntity(_0x4b6124){return function(_0x45e7ba){const _0x5cebfe=a66_0x20dc;if(_0x45e7ba)return _0x45e7ba[_0x5cebfe('0x48')]()['then'](function(){const _0x5809cb=_0x5cebfe;_0x4b6124[_0x5809cb('0xe1')](0xcc)[_0x5809cb('0x66')]();});};}function handleEntityNotFound(_0xc8c50d){return function(_0x597883){return!_0x597883&&_0xc8c50d['sendStatus'](0x194),_0x597883;};}function handleError(_0x3de92e,_0x9559d1){return _0x9559d1=_0x9559d1||0x1f4,function(_0x407e8d){const _0x23de50=a66_0x20dc;logger[_0x23de50('0x53')](_0x407e8d['stack']),_0x407e8d['name']&&delete _0x407e8d['name'],_0x3de92e[_0x23de50('0xe1')](_0x9559d1)[_0x23de50('0xf5')](_0x407e8d);};}function getInteractionUsers(_0x53ad1e,_0x111473){return new Promise(function(_0x4803df,_0x5f278d){const _0x5020e0=a66_0x20dc;try{_0x111473[_0x53ad1e['id']]&&(_0x53ad1e[_0x5020e0('0x35')]=_[_0x5020e0('0x40')](_0x111473[_0x53ad1e['id']],function(_0x5b42b9){const _0x1f71e2=_0x5020e0;return{'id':_0x5b42b9['id'],'fullname':_0x5b42b9[_0x1f71e2('0x69')]};}));}catch(_0x5cf6bc){_0x5f278d(_0x5cf6bc);}_0x4803df(_0x53ad1e);});}function getInteractionTags(_0x55fe2a,_0x1c51c7){return new Promise(function(_0x299d1c,_0x6b3f10){const _0x28a440=a66_0x20dc;try{_0x55fe2a['TagIds']&&(_0x55fe2a['Tags']=[],_0x55fe2a['TagIds']['split'](',')[_0x28a440('0x59')](function(_0x2be48c){const _0x48a73b=_0x28a440;_0x55fe2a[_0x48a73b('0xd5')][_0x48a73b('0x5')](_0x1c51c7[_0x2be48c]);})),delete _0x55fe2a['TagIds'];}catch(_0x37e5e3){_0x6b3f10(_0x37e5e3);}_0x299d1c(_0x55fe2a);});}function updateChatInteraction(_0x923f3c,_0x51d4f6,_0x51c89f){return new Promise(function(_0x548633,_0x29b69b){const _0x1381b1=a66_0x20dc;return getInteractionUsers(_0x923f3c,_0x51c89f)['then'](function(_0x155a8b){return getInteractionTags(_0x155a8b,_0x51d4f6);})[_0x1381b1('0x2d')](function(_0x4b747d){_0x548633(_0x4b747d);})[_0x1381b1('0x55')](function(_0x4c1d66){_0x29b69b(_0x4c1d66);});});}exports[_0x4b28f7('0x8')]=function(_0x157b94,_0x3e6137){const _0x2d2efd=_0x4b28f7,_0x50d439={},_0x22fc77={},_0x3e5a71={'count':0x0,'rows':[]},_0x58cfec=_[_0x2d2efd('0x40')](db[_0x2d2efd('0x79')][_0x2d2efd('0x8b')],function(_0x36bb6e){const _0x3884d0=_0x2d2efd;return{'name':_0x36bb6e[_0x3884d0('0xdc')],'type':_0x36bb6e[_0x3884d0('0xcf')]['key']};});_0x22fc77['model']=_[_0x2d2efd('0x40')](_0x58cfec,'name'),_0x22fc77[_0x2d2efd('0xd7')]=_[_0x2d2efd('0x72')](_0x157b94[_0x2d2efd('0xd7')]),_0x22fc77[_0x2d2efd('0xc2')]=_[_0x2d2efd('0x19')](_0x22fc77['model'],_0x22fc77[_0x2d2efd('0xd7')]),_0x50d439[_0x2d2efd('0xab')]=_[_0x2d2efd('0x19')](_0x22fc77[_0x2d2efd('0xdb')],qs[_0x2d2efd('0x51')](_0x157b94[_0x2d2efd('0xd7')][_0x2d2efd('0x51')])),_0x50d439[_0x2d2efd('0xab')]=_0x50d439[_0x2d2efd('0xab')]['length']?_0x50d439['attributes']:_0x22fc77[_0x2d2efd('0xdb')];typeof _0x157b94['query'][_0x2d2efd('0x98')]===_0x2d2efd('0x74')&&(_0x50d439[_0x2d2efd('0x43')]=qs[_0x2d2efd('0x43')](_0x157b94[_0x2d2efd('0xd7')]['limit']),_0x50d439['offset']=qs[_0x2d2efd('0xec')](_0x157b94['query']['offset']));_0x50d439[_0x2d2efd('0x32')]=qs[_0x2d2efd('0x3e')](_0x157b94['query'][_0x2d2efd('0x3e')]),_0x50d439[_0x2d2efd('0x8a')]=qs[_0x2d2efd('0xc2')](_[_0x2d2efd('0x93')](_0x157b94[_0x2d2efd('0xd7')],_0x22fc77['filters']),_0x58cfec);let _0x1d4d49=[];const _0x56a924=squel['select']()[_0x2d2efd('0x31')]('id')[_0x2d2efd('0x31')]('name')[_0x2d2efd('0x31')](_0x2d2efd('0x7a'))[_0x2d2efd('0x6')](_0x2d2efd('0x1c')),_0x5ec977=squel['select']()['field'](_0x2d2efd('0xe'))[_0x2d2efd('0x31')](_0x2d2efd('0x2f'))[_0x2d2efd('0x31')]('ui.ChatInteractionId')[_0x2d2efd('0x6')](_0x2d2efd('0x2b'),'ui')[_0x2d2efd('0xf')](_0x2d2efd('0xb1'),'u',_0x2d2efd('0xac')),_0x53994c=squel[_0x2d2efd('0x85')]()[_0x2d2efd('0x6')](_0x2d2efd('0xa5'),'i')[_0x2d2efd('0xf')](_0x2d2efd('0x92'),'c','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL')[_0x2d2efd('0xf')]('users','o',_0x2d2efd('0x9d'))[_0x2d2efd('0xf')]('chat_websites','a',_0x2d2efd('0xb7'))[_0x2d2efd('0xf')](_0x2d2efd('0xbf'),'me','me.ChatInteractionId\x20=\x20i.id')['left_join']('chat_interaction_has_tags','it',_0x2d2efd('0xa'))[_0x2d2efd('0xf')](_0x2d2efd('0x1c'),'t','t.id\x20=\x20it.TagId'),_0x3856ff=squel['expr']();let _0x5a77ab=[];const _0x10f3a4=squel[_0x2d2efd('0xb6')]();let _0x305134;if(_0x157b94[_0x2d2efd('0xd7')][_0x2d2efd('0x15')]){_0x305134=as['parseSearch'](_0x157b94[_0x2d2efd('0xd7')][_0x2d2efd('0x15')]);const _0x396c3a=_0x305134[_0x2d2efd('0xbc')];for(let _0x23e256=0x0;_0x23e256<_0x305134[_0x2d2efd('0x7e')][_0x2d2efd('0x10')];_0x23e256++){const _0x4e5204=_0x305134[_0x2d2efd('0x7e')][_0x23e256],_0x1dcac3='i';let _0x14847f,_0x1be8b9=_['find'](_0x58cfec,['name',_0x4e5204['field']]);if(!_0x1be8b9)switch(_0x4e5204['field']){case _0x2d2efd('0x2'):_0x4e5204[_0x2d2efd('0xda')]==0x1?_0x53994c[_0x2d2efd('0x67')]('`'+_0x4e5204[_0x2d2efd('0x31')]+_0x2d2efd('0x60')):_0x53994c['having']('`'+_0x4e5204[_0x2d2efd('0x31')]+_0x2d2efd('0x5a'));break;case _0x2d2efd('0xb8'):if(_0x4e5204['operator']===_0x2d2efd('0x58')){if(_0x4e5204[_0x2d2efd('0xda')][_0x2d2efd('0x3d')]('\x20')[_0x2d2efd('0x10')]>0x1)_0x3856ff[_0x396c3a]('MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs[_0x2d2efd('0xe5')](_0x4e5204[_0x2d2efd('0xda')]),null);else{const _0x4dd177='%'+_0x4e5204[_0x2d2efd('0xda')]+'%';_0x3856ff[_0x396c3a](_0x2d2efd('0xaa'),_0x4dd177,_0x4dd177,_0x4dd177);}}else _0x1be8b9=_[_0x2d2efd('0x104')](_0x58cfec,[_0x2d2efd('0xd0'),_0x2d2efd('0x21')]),_0x4e5204['field']=_0x2d2efd('0x21'),_0x14847f=as['buildExpression'](_0x1dcac3,_0x1be8b9['type'],_0x4e5204),_0x3856ff[_0x396c3a](_0x14847f[_0x2d2efd('0x62')],_0x14847f['value'][_0x2d2efd('0x1b')],_0x14847f['value'][_0x2d2efd('0x66')]);break;case'Tag':{const _0x968d07=_0x4e5204['value'][_0x2d2efd('0x3d')](',')[_0x2d2efd('0x40')](function(_0x2fa199){return Number(_0x2fa199);});_0x968d07['forEach'](function(_0xdc0de2){const _0x54ac37=_0x2d2efd;_0x10f3a4['or'](_0x54ac37('0xc8'),'%,'+_0xdc0de2+',%');}),_0x5a77ab=_['union'](_0x5a77ab,_0x968d07);}break;case _0x2d2efd('0xae'):_0x4e5204[_0x2d2efd('0x8e')]==='$substring'?_0x3856ff[_0x396c3a](_0x2d2efd('0xca'),'%'+_0x4e5204[_0x2d2efd('0xda')]+'%',null):(_0x1be8b9=_[_0x2d2efd('0x104')](_0x58cfec,['name',_0x2d2efd('0x64')]),_0x4e5204['field']=_0x2d2efd('0x64'),_0x14847f=as[_0x2d2efd('0x96')](_0x1dcac3,_0x1be8b9[_0x2d2efd('0xcf')],_0x4e5204),_0x3856ff[_0x396c3a](_0x14847f[_0x2d2efd('0x62')],_0x14847f[_0x2d2efd('0xda')][_0x2d2efd('0x1b')],_0x14847f[_0x2d2efd('0xda')][_0x2d2efd('0x66')]));break;case _0x2d2efd('0x1a'):_0x14847f=as['buildExpression']('me',null,_0x4e5204),_0x3856ff[_0x396c3a](_0x14847f['text'],_0x14847f[_0x2d2efd('0xda')][_0x2d2efd('0x1b')],_0x14847f[_0x2d2efd('0xda')]['end']);break;}else _0x14847f=as[_0x2d2efd('0x96')](_0x1dcac3,_0x1be8b9[_0x2d2efd('0xcf')],_0x4e5204),_0x3856ff[_0x396c3a](_0x14847f[_0x2d2efd('0x62')],_0x14847f[_0x2d2efd('0xda')][_0x2d2efd('0x1b')],_0x14847f[_0x2d2efd('0xda')][_0x2d2efd('0x66')]);}}else{const _0x43912f=_(_0x157b94['query'])[_0x2d2efd('0x72')]()[_0x2d2efd('0x40')](function(_0x32e7ca){const _0x343b10=_0x2d2efd;return _[_0x343b10('0x3c')](_0x58cfec,['name',_0x32e7ca])?_0x32e7ca:undefined;})[_0x2d2efd('0xd3')]()['value']();!_['isEmpty'](_0x43912f)&&_0x43912f[_0x2d2efd('0x59')](function(_0x16519f){const _0x1c51ce=_0x2d2efd;if(_0x16519f==='ChatWebsiteId')_0x53994c[_0x1c51ce('0x8a')](_0x1c51ce('0xfa'),[][_0x1c51ce('0x46')](_0x157b94[_0x1c51ce('0xd7')][_0x16519f]));else{if(_0x16519f===_0x1c51ce('0x6b')){const _0x67c573=JSON[_0x1c51ce('0x38')](_0x157b94[_0x1c51ce('0xd7')][_0x16519f])['$gte'],_0x211af8=JSON[_0x1c51ce('0x38')](_0x157b94['query'][_0x16519f])[_0x1c51ce('0x10e')];_0x53994c[_0x1c51ce('0x8a')](_0x1c51ce('0x91'),_0x67c573,_0x211af8);}else _0x157b94[_0x1c51ce('0xd7')][_0x16519f]==='null'?_0x53994c[_0x1c51ce('0x8a')]('i.'+_0x16519f+_0x1c51ce('0x4d')):_0x53994c[_0x1c51ce('0x8a')]('i.'+_0x16519f+_0x1c51ce('0xf4'),_0x157b94[_0x1c51ce('0xd7')][_0x16519f]);}});_0x157b94[_0x2d2efd('0xd7')][_0x2d2efd('0x24')]&&(_0x157b94[_0x2d2efd('0xd7')]['read']==0x1?_0x53994c[_0x2d2efd('0x67')](_0x2d2efd('0x56')):_0x53994c[_0x2d2efd('0x67')](_0x2d2efd('0xd2')));_0x157b94[_0x2d2efd('0xd7')][_0x2d2efd('0xe0')]&&(_0x5a77ab=_[_0x2d2efd('0xed')](_0x157b94['query'][_0x2d2efd('0xe0')])?_0x157b94[_0x2d2efd('0xd7')][_0x2d2efd('0xe0')]:new Array(_0x157b94['query'][_0x2d2efd('0xe0')]),_0x5a77ab['forEach'](function(_0x1029c5){_0x10f3a4['or']('CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','%,'+_0x1029c5+',%');}));if(_0x157b94[_0x2d2efd('0xd7')][_0x2d2efd('0x8c')]){const _0x335d21=_0x157b94[_0x2d2efd('0xd7')][_0x2d2efd('0x8c')][_0x2d2efd('0x4f')]('\x5c','\x5c\x5c')[_0x2d2efd('0x4f')]('\x27\x27',_0x2d2efd('0xfd'));qs[_0x2d2efd('0x7d')](_0x335d21)?_0x3856ff['or'](_0x2d2efd('0xc0'),_0x335d21+'%'):_0x3856ff['or']('MATCH\x20(me.body)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs[_0x2d2efd('0xe5')](_0x335d21))['or']('CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?',_0x335d21+'%');}}_0x53994c[_0x2d2efd('0x8a')](_0x3856ff),_0x53994c['group'](_0x2d2efd('0x49'));let _0x144ef8={'type':QueryTypes[_0x2d2efd('0xf8')],'raw':!![]};const _0x32698b=_0x53994c[_0x2d2efd('0x1e')]();_0x32698b[_0x2d2efd('0x31')](_0x2d2efd('0x49')),_0x32698b[_0x2d2efd('0x31')](_0x2d2efd('0xd8'),'unreadMessages'),_0x50d439[_0x2d2efd('0x32')]&&_0x50d439['order'][_0x2d2efd('0x59')](function(_0x557e3a){const _0x445ff0=_0x2d2efd;_0x53994c[_0x445ff0('0x32')]('i.'+_0x557e3a[0x0],_0x557e3a[0x1]==='DESC'?![]:!![]);}),!_[_0x2d2efd('0x52')](_0x5a77ab)&&(_0x53994c['having'](_0x10f3a4),_0x32698b['where']('t.id\x20IN\x20?',_0x5a77ab)),Promise['resolve']()[_0x2d2efd('0x2d')](function(){const _0x334636=_0x2d2efd;if(!_0x305134){if(_0x157b94[_0x334636('0xd7')][_0x334636('0x25')]||_0x157b94[_0x334636('0xd7')][_0x334636('0x2a')])return;_0x32698b[_0x334636('0x8a')](_0x334636('0xd9')),_0x53994c['where'](_0x334636('0xd9'));return;}return _0x157b94[_0x334636('0xd4')][_0x334636('0x61')]({'attributes':['id'],'raw':!![]})[_0x334636('0x2d')](function(_0x57cccb){const _0x154167=_0x334636;_[_0x154167('0x52')](_0x57cccb)?(_0x32698b[_0x154167('0x8a')](_0x154167('0x84')),_0x53994c[_0x154167('0x8a')](_0x154167('0x84'))):(_0x32698b[_0x154167('0x8a')](_0x154167('0xfa'),_[_0x154167('0x40')](_0x57cccb,'id')),_0x53994c['where'](_0x154167('0xfa'),_[_0x154167('0x40')](_0x57cccb,'id')));});})[_0x2d2efd('0x2d')](function(){const _0x462c9d=_0x2d2efd;db[_0x462c9d('0x3f')]['query'](_0x32698b['toString'](),_0x144ef8)[_0x462c9d('0x2d')](function(_0x4232d6){const _0x2eaef0=_0x462c9d;_0x3e5a71[_0x2eaef0('0xf9')]=_0x4232d6[_0x2eaef0('0x10')];if(_0x3e5a71[_0x2eaef0('0xf9')]===0x0)return[];return db['sequelize'][_0x2eaef0('0xd7')](_0x56a924[_0x2eaef0('0x2e')](),_0x144ef8)[_0x2eaef0('0x2d')](function(_0x5df148){const _0x5184e6=_0x2eaef0;_0x1d4d49=_[_0x5184e6('0x75')](_0x5df148,'id'),_0x144ef8=_['merge'](_0x144ef8,{'model':db[_0x5184e6('0x79')],'mapToModel':!![],'raw':!![],'nest':!![]});_0x157b94['query'][_0x5184e6('0x51')]?_0x50d439[_0x5184e6('0xab')][_0x5184e6('0x59')](function(_0x5992e0){_0x53994c['field']('i.'+_0x5992e0);}):(_0x53994c[_0x5184e6('0x31')]('SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','unreadMessages'),_0x53994c[_0x5184e6('0x31')]('a.key',_0x5184e6('0x11')),_0x53994c['field']('a.mandatoryDisposition',_0x5184e6('0xd1')),_0x53994c[_0x5184e6('0x31')](_0x5184e6('0xad')),_0x53994c[_0x5184e6('0x31')](_0x5184e6('0xa4'),'Contact.firstName'),_0x53994c['field']('c.lastName','Contact.lastName'),_0x53994c['field'](_0x5184e6('0xf1'),'Contact.email'),_0x53994c[_0x5184e6('0x31')](_0x5184e6('0x33'),_0x5184e6('0xb2')),_0x53994c['field']('c.mobile',_0x5184e6('0xc')),_0x53994c['field'](_0x5184e6('0xba'),_0x5184e6('0xe8')),_0x53994c[_0x5184e6('0x31')](_0x5184e6('0xea'),_0x5184e6('0x9e')),_0x53994c['field']('o.internal',_0x5184e6('0x10a')),_0x53994c[_0x5184e6('0x31')](_0x5184e6('0x6d'),'TagIds'));if(_0x50d439[_0x5184e6('0x43')])_0x53994c['limit'](_0x50d439['limit']);if(_0x50d439[_0x5184e6('0xec')])_0x53994c[_0x5184e6('0xec')](_0x50d439[_0x5184e6('0xec')]);return db[_0x5184e6('0x3f')][_0x5184e6('0xd7')](_0x53994c[_0x5184e6('0x2e')](),_0x144ef8);})['then'](function(_0x276133){const _0x4d84a9=_0x2eaef0;return _0x5ec977[_0x4d84a9('0x8a')](_0x4d84a9('0x6f'),_[_0x4d84a9('0x40')](_0x276133,'id')),db['sequelize'][_0x4d84a9('0xd7')](_0x5ec977[_0x4d84a9('0x2e')](),_0x144ef8)[_0x4d84a9('0x2d')](function(_0x28adb6){const _0x3eb93f=_0x4d84a9,_0x5954c9=_[_0x3eb93f('0x6a')](_0x28adb6,_0x3eb93f('0xe4')),_0x2d92c6=[];return _0x276133[_0x3eb93f('0x59')](function(_0x4b720a){const _0x25644b=_0x3eb93f;_0x2d92c6[_0x25644b('0x5')](updateChatInteraction(_0x4b720a,_0x1d4d49,_0x5954c9));}),Promise[_0x3eb93f('0x26')](_0x2d92c6);});});})['then'](function(_0x91c44){return _0x3e5a71['rows']=_0x91c44,_0x3e5a71;})[_0x462c9d('0x2d')](respondWithFilteredResult(_0x3e6137,_0x50d439));})[_0x2d2efd('0x55')](handleError(_0x3e6137,null));},exports[_0x4b28f7('0x6e')]=function(_0x8fbeb5,_0x539092){const _0x151b3e=_0x4b28f7;let _0x726b60={'raw':![],'where':{'id':_0x8fbeb5['params']['id']}};const _0xc88c95={};return _0xc88c95[_0x151b3e('0xdb')]=_[_0x151b3e('0x72')](db[_0x151b3e('0x79')][_0x151b3e('0x8b')]),_0xc88c95[_0x151b3e('0xd7')]=_[_0x151b3e('0x72')](_0x8fbeb5[_0x151b3e('0xd7')]),_0xc88c95[_0x151b3e('0xc2')]=_[_0x151b3e('0x19')](_0xc88c95[_0x151b3e('0xdb')],_0xc88c95[_0x151b3e('0xd7')]),_0x726b60[_0x151b3e('0xab')]=_[_0x151b3e('0x19')](_0xc88c95[_0x151b3e('0xdb')],qs[_0x151b3e('0x51')](_0x8fbeb5[_0x151b3e('0xd7')]['fields'])),_0x726b60['attributes']=_0x726b60['attributes']['length']?_0x726b60[_0x151b3e('0xab')]:_0xc88c95[_0x151b3e('0xdb')],_0x8fbeb5[_0x151b3e('0xd7')][_0x151b3e('0x3')]&&(_0x726b60[_0x151b3e('0x83')]=[{'all':!![]}]),_0x726b60=_[_0x151b3e('0x108')]({},_0x726b60,_0x8fbeb5[_0x151b3e('0x95')]),db[_0x151b3e('0x79')][_0x151b3e('0x78')](_0x726b60)[_0x151b3e('0x2d')](handleEntityNotFound(_0x539092,null))[_0x151b3e('0x2d')](respondWithResult(_0x539092,null))[_0x151b3e('0x55')](handleError(_0x539092,null));},exports[_0x4b28f7('0xc3')]=function(_0x5a8710,_0xf8bd6c){const _0x1e7d6a=_0x4b28f7;return db[_0x1e7d6a('0x79')][_0x1e7d6a('0xc3')](_0x5a8710[_0x1e7d6a('0x1a')],{})[_0x1e7d6a('0x2d')](respondWithResult(_0xf8bd6c,0xc9))[_0x1e7d6a('0x55')](handleError(_0xf8bd6c,null));},exports[_0x4b28f7('0xa9')]=function(_0x2b4c9b,_0x1dc106){const _0x40de50=_0x4b28f7;return _0x2b4c9b['body']['id']&&delete _0x2b4c9b[_0x40de50('0x1a')]['id'],db[_0x40de50('0x79')][_0x40de50('0x78')]({'where':{'id':_0x2b4c9b[_0x40de50('0x50')]['id']}})['then'](handleEntityNotFound(_0x1dc106,null))[_0x40de50('0x2d')](saveUpdates(_0x2b4c9b['body'],null))['then'](respondWithResult(_0x1dc106,null))[_0x40de50('0x55')](handleError(_0x1dc106,null));},exports[_0x4b28f7('0x48')]=function(_0x46d287,_0x1922c0){const _0x2adaa4=_0x4b28f7;return db['ChatInteraction'][_0x2adaa4('0x78')]({'where':{'id':_0x46d287[_0x2adaa4('0x50')]['id']}})[_0x2adaa4('0x2d')](handleEntityNotFound(_0x1922c0,null))['then'](removeEntity(_0x1922c0,null))[_0x2adaa4('0x55')](handleError(_0x1922c0,null));},exports[_0x4b28f7('0x9f')]=function(_0x3ddfbd,_0x3feff4){const _0x580382=_0x4b28f7;return db[_0x580382('0x79')][_0x580382('0x9f')]()[_0x580382('0x2d')](respondWithResult(_0x3feff4,null))[_0x580382('0x55')](handleError(_0x3feff4,null));},exports['createVidaooSession']=function(_0x2e4408,_0x45c4d1){const _0x5a1c97=_0x4b28f7,_0x3e194c=_0x2e4408[_0x5a1c97('0x50')]['id'];let _0xb95ec8,_0x22f275,_0x3cf695;return db[_0x5a1c97('0x79')]['findOne']({'where':{'id':_0x3e194c}})[_0x5a1c97('0x2d')](function(_0x367a90){const _0x34cde4=_0x5a1c97;return _0xb95ec8=_0x367a90,db[_0x34cde4('0x20')]['findOne']({'where':{'id':_0x367a90[_0x34cde4('0x25')]},'attributes':['id',_0x34cde4('0x42'),'vidaooEscalation'],'raw':!![]});})[_0x5a1c97('0x2d')](function(_0xb4cec){const _0x2b0e05=_0x5a1c97;if(_0xb4cec&&_0xb4cec[_0x2b0e05('0x42')]&&_0xb4cec[_0x2b0e05('0x0')]){_0x22f275=_0xb4cec;const _0xb2ae5b={'rejectUnauthorized':![],'method':_0x2b0e05('0xf3'),'uri':'https://api-vidaoo.xcally.com/api/v1/sessions','headers':{'X-APIKEY':_0xb4cec['vidaooApiKey']},'body':{'name':'MotionCWB:'+_0x3e194c},'redirect':_0x2b0e05('0x89'),'json':!![]};return rp(_0xb2ae5b);}else throw new ValidationError(_0x2b0e05('0x87'));})[_0x5a1c97('0x2d')](function(_0xdfb736){const _0x58e63a=_0x5a1c97;_0x3cf695=_0xdfb736;if(_0x3cf695['id']){const _0x3f48a1={'body':_0x3cf695[_0x58e63a('0xfc')],'ChatWebsiteId':_0x22f275['id'],'ChatInteractionId':_0xb95ec8['id'],'direction':_0x58e63a('0x10b'),'UserId':_0x2e4408[_0x58e63a('0xd4')]['id']};return db[_0x58e63a('0x23')][_0x58e63a('0xc3')](_0x3f48a1,{});}else throw new ValidationError('Unable\x20to\x20create\x20Vidaoo\x20session');})['then'](function(){const _0x9b4284=_0x5a1c97;return _0xb95ec8[_0x9b4284('0xa9')]({'vidaooSessionId':_0x3cf695['id']});})[_0x5a1c97('0x2d')](respondWithResult(_0x45c4d1,null))[_0x5a1c97('0x55')](handleError(_0x45c4d1,null));},exports[_0x4b28f7('0xfb')]=function(_0x68dcab,_0x389f0c){const _0x3205e4=_0x4b28f7;return _0x68dcab[_0x3205e4('0x1a')]['id']&&delete _0x68dcab[_0x3205e4('0x1a')]['id'],db[_0x3205e4('0x79')][_0x3205e4('0x78')]({'where':{'id':_0x68dcab[_0x3205e4('0x50')]['id']}})[_0x3205e4('0x2d')](handleEntityNotFound(_0x389f0c,null))[_0x3205e4('0x2d')](saveUpdates(_0x68dcab[_0x3205e4('0x1a')],null))[_0x3205e4('0x2d')](respondWithResult(_0x389f0c,null))[_0x3205e4('0x55')](handleError(_0x389f0c,null));},exports[_0x4b28f7('0x8f')]=function(_0x1c9620,_0x3f94b6){const _0xced280=_0x4b28f7;return _0x1c9620[_0xced280('0x1a')]['id']&&delete _0x1c9620[_0xced280('0x1a')]['id'],db['ChatInteraction'][_0xced280('0x78')]({'where':{'id':_0x1c9620[_0xced280('0x50')]['id']}})[_0xced280('0x2d')](function(_0x4eaf8e){const _0x4324ee=_0xced280;if(!_0x4eaf8e)logger[_0x4324ee('0x53')](_0x4324ee('0xb3'),_0x4324ee('0x8f'),0x194,_0x4324ee('0x103')),_0x3f94b6[_0x4324ee('0x3a')](0x194);else{if(_0x4eaf8e[_0x4324ee('0x64')])throw new ValidationError(_0x4324ee('0xb9'));}return _0x4eaf8e;})[_0xced280('0x2d')](function(_0x4918a0){const _0x2b4efb=_0xced280;if(_0x4918a0)return _0x4918a0[_0x2b4efb('0xa9')]({'closed':_0x1c9620[_0x2b4efb('0x1a')][_0x2b4efb('0xa6')],'disposition':_0x1c9620['body'][_0x2b4efb('0x5f')]})[_0x2b4efb('0x2d')](function(_0x3db396){return _0x3db396;});})[_0xced280('0x2d')](function(){const _0x3691fc=_0xced280;return respondWithRpcPromise('AbandonInteraction','abandon',_0x1c9620[_0x3691fc('0x1a')],client9004);})[_0xced280('0x2d')](respondWithResult(_0x3f94b6,null))[_0xced280('0x55')](handleError(_0x3f94b6,null));},exports[_0x4b28f7('0x9')]=function(_0x500463,_0x4a2f17){const _0x5dda79=_0x4b28f7;return _0x500463[_0x5dda79('0x1a')][_0x5dda79('0xd0')]=_0x500463[_0x5dda79('0x28')][_0x5dda79('0x44')],_0x500463[_0x5dda79('0x1a')]['basename']=_0x500463[_0x5dda79('0x28')][_0x5dda79('0x5b')],_0x500463[_0x5dda79('0x1a')][_0x5dda79('0xcf')]=_0x500463[_0x5dda79('0x28')][_0x5dda79('0x65')],db[_0x5dda79('0x29')]['create'](_0x500463[_0x5dda79('0x1a')])[_0x5dda79('0x2d')](respondWithResult(_0x4a2f17,0xc9))[_0x5dda79('0x55')](handleError(_0x4a2f17,null));},exports[_0x4b28f7('0xf0')]=function(_0x3377c6,_0x97b3ea){const _0x117b69=_0x4b28f7;return db['ChatInteraction']['findOne']({'where':{'id':_0x3377c6['params']['id']},'raw':!![]})[_0x117b69('0x2d')](handleEntityNotFound(_0x97b3ea,null))[_0x117b69('0x2d')](function(_0x5e5774){const _0x31e0e5=_0x117b69;if(_0x5e5774){if(_0x5e5774[_0x31e0e5('0xa6')])return _0x97b3ea[_0x31e0e5('0xe1')](0x193)['json']({'status':0x193,'message':_0x31e0e5('0xf7')});return db[_0x31e0e5('0x29')]['findOne']({'where':{'id':_0x3377c6[_0x31e0e5('0xd7')][_0x31e0e5('0x81')]},'raw':!![]})[_0x31e0e5('0x2d')](handleEntityNotFound(_0x97b3ea,null));}})[_0x117b69('0x2d')](function(_0x35db84){const _0x27f86a=_0x117b69;if(_0x35db84)return _0x97b3ea[_0x27f86a('0xa1')](path[_0x27f86a('0xa7')](config['root'],_0x27f86a('0x102'),_0x35db84['basename']));})['catch'](handleError(_0x97b3ea,null));},exports[_0x4b28f7('0x5d')]=function(_0x4dbd14,_0x366518){const _0x2e081a=_0x4b28f7;let _0x19ce98=null,_0x29bd0f=null,_0x3971cd=null;return _0x4dbd14[_0x2e081a('0x1a')]['id']&&delete _0x4dbd14[_0x2e081a('0x1a')]['id'],_0x4dbd14[_0x2e081a('0x1a')]['mailTranscript']&&(_0x3971cd=path[_0x2e081a('0xa7')](config[_0x2e081a('0xdf')],'server/files/chat/upload/',util[_0x2e081a('0xbd')]('transcript-%s.txt',Date['now']())),_0x4dbd14[_0x2e081a('0x1a')][_0x2e081a('0x8d')]=_0x3971cd),db[_0x2e081a('0x79')]['findOne']({'where':{'id':_0x4dbd14[_0x2e081a('0x50')]['id']},'include':[{'model':db[_0x2e081a('0x23')],'as':_0x2e081a('0x45'),'include':[{'model':db['User'],'as':'User'}]}]})['then'](handleEntityNotFound(_0x366518,null))['then'](saveUpdates(_0x4dbd14['body'],null))['then'](function(_0x36e764){const _0x10d706=_0x2e081a;if(_0x36e764)return _0x19ce98=_0x36e764,db[_0x10d706('0x20')][_0x10d706('0x78')]({'where':{'id':_0x19ce98['ChatWebsiteId']}});})[_0x2e081a('0x2d')](function(_0x3feec2){const _0x1c1c55=_0x2e081a;if(_0x3feec2)return _0x29bd0f=_0x3feec2,db[_0x1c1c55('0x107')]['findOne']({'where':{'id':_0x19ce98['ContactId']}});})[_0x2e081a('0x2d')](function(_0x9dd60a){const _0x4df3bd=_0x2e081a;if(_0x9dd60a){if(_0x3971cd){let _0x5ca75c=null;for(let _0x163cfe=0x1;_0x163cfe<_0x19ce98['Messages']['length'];++_0x163cfe){_0x5ca75c=_0x19ce98[_0x4df3bd('0x45')][_0x163cfe];let _0x2816c4=_0x5ca75c[_0x4df3bd('0x64')]?util[_0x4df3bd('0xbd')](_0x4df3bd('0x71'),_0x29bd0f[_0x4df3bd('0xaf')],_0x5ca75c[_0x4df3bd('0x64')]):_0x4df3bd('0x27');const _0x1d653c=_0x4dbd14['body']['customer']||util[_0x4df3bd('0xbd')](_0x4df3bd('0x71'),_0x4df3bd('0xdd'),_0x5ca75c[_0x4df3bd('0x21')]);switch(_0x29bd0f['agentIdentifier']){case'website_alias':_0x2816c4=_0x5ca75c[_0x4df3bd('0x64')]?util[_0x4df3bd('0xbd')](_0x4df3bd('0x71'),_0x29bd0f[_0x4df3bd('0xaf')],_0x5ca75c[_0x4df3bd('0x64')]):'System';break;case _0x4df3bd('0xc9'):_0x2816c4=_0x5ca75c[_0x4df3bd('0x64')]?_0x5ca75c[_0x4df3bd('0xae')][_0x4df3bd('0xbb')]||_0x5ca75c[_0x4df3bd('0xae')]['fullname']:_0x4df3bd('0x27');break;case _0x4df3bd('0x70'):_0x2816c4=_0x5ca75c[_0x4df3bd('0x64')]?_0x5ca75c[_0x4df3bd('0xae')]['fullname']:_0x4df3bd('0x27');break;default:_0x2816c4=_0x5ca75c[_0x4df3bd('0x64')]?util['format'](_0x4df3bd('0x71'),_0x29bd0f[_0x4df3bd('0xaf')],_0x5ca75c[_0x4df3bd('0x64')]):_0x4df3bd('0x27');}const _0x3d6fa2=util[_0x4df3bd('0xbd')](_0x4df3bd('0x22'),moment(_0x5ca75c[_0x4df3bd('0x6b')])['format'](_0x4df3bd('0xe2')),_0x5ca75c[_0x4df3bd('0x105')]==='in'?_0x1d653c:_0x2816c4,_0x5ca75c[_0x4df3bd('0x1a')]);!_0x5ca75c[_0x4df3bd('0x3b')]&&fs[_0x4df3bd('0x73')](_0x3971cd,_0x3d6fa2);}return db[_0x4df3bd('0x4a')][_0x4df3bd('0x78')]({'where':{'service':!![]},'include':[{'model':db[_0x4df3bd('0x2c')],'as':_0x4df3bd('0xb5'),'raw':!![]}]});}}})[_0x2e081a('0x2d')](function(_0x5fee84){const _0x538477=_0x2e081a;if(_0x5fee84&&_0x5fee84['Smtp']&&_0x4dbd14[_0x538477('0x1a')]){const _0x48b009={'tls':{'rejectUnauthorized':![]}};return _0x5fee84['Smtp'][_0x538477('0xb')]?_0x48b009[_0x538477('0xb')]=_0x5fee84[_0x538477('0xb5')][_0x538477('0xb')]:(_0x48b009[_0x538477('0x34')]=_0x5fee84[_0x538477('0xb5')][_0x538477('0x34')],_0x48b009[_0x538477('0xc6')]=_0x5fee84[_0x538477('0xb5')][_0x538477('0xc6')],_0x48b009[_0x538477('0x5e')]=_0x5fee84[_0x538477('0xb5')][_0x538477('0x5e')]),_0x5fee84[_0x538477('0xb5')][_0x538477('0xa8')]&&(_0x48b009[_0x538477('0xa0')]={'user':_0x5fee84['Smtp']['user'],'pass':_0x5fee84['Smtp']['pass']}),respondWithRpcPromise('SendMail','sendMail',{'account':_0x48b009,'message':{'from':util[_0x538477('0xbd')](_0x538477('0x1f'),_0x5fee84[_0x538477('0xd0')],_0x5fee84[_0x538477('0x4')]||_0x5fee84['Smtp']['user']),'to':_0x4dbd14['body']['mailTranscript'],'subject':_0x538477('0x7b'),'text':util[_0x538477('0xbd')](_0x538477('0x10f'),_0x4dbd14[_0x538477('0x1a')][_0x538477('0x39')]),'attachments':[{'path':_0x3971cd}]}})[_0x538477('0x2d')](function(){return _0x19ce98;})[_0x538477('0x55')](function(_0x12a7eb){console['error'](_0x12a7eb);});}else return _0x19ce98;})[_0x2e081a('0x2d')](respondWithStatusCode(_0x366518,0xc8))[_0x2e081a('0x55')](handleError(_0x366518,null));},exports['addMessage']=function(_0x5ece3f,_0x3de91f){const _0x14a098=_0x4b28f7;return db[_0x14a098('0x23')][_0x14a098('0x78')]({'where':{'id':_0x5ece3f[_0x14a098('0x50')]['id']}})[_0x14a098('0x2d')](function(_0x55674c){const _0x21aaea=_0x14a098;if(_0x55674c)return _0x55674c[_0x21aaea('0x30')](_0x5ece3f[_0x21aaea('0x1a')][_0x21aaea('0x47')],{'through':_['omit'](_0x5ece3f[_0x21aaea('0x1a')],[_0x21aaea('0x47'),'id'])});})[_0x14a098('0x2d')](respondWithResult(_0x3de91f,null))[_0x14a098('0x55')](handleError(_0x3de91f,null));},exports[_0x4b28f7('0xe7')]=function(_0x18b467,_0x4a21d3){const _0x2c275b=_0x4b28f7;let _0x5c848c={'raw':![],'where':{}};const _0x494e2c={},_0x41b2e0={'count':0x0,'rows':[]};return db[_0x2c275b('0x79')][_0x2c275b('0x78')]({'where':{'id':_0x18b467['params']['id']}})[_0x2c275b('0x2d')](handleEntityNotFound(_0x4a21d3,null))[_0x2c275b('0x2d')](function(_0xdafb1d){const _0x27aca3=_0x2c275b;if(_0xdafb1d){_0x494e2c[_0x27aca3('0xdb')]=_['keys'](db[_0x27aca3('0x23')][_0x27aca3('0x8b')]),_0x494e2c['query']=_[_0x27aca3('0x72')](_0x18b467[_0x27aca3('0xd7')]),_0x494e2c[_0x27aca3('0xc2')]=_[_0x27aca3('0x19')](_0x494e2c[_0x27aca3('0xdb')],_0x494e2c[_0x27aca3('0xd7')]),_0x5c848c['attributes']=_[_0x27aca3('0x19')](_0x494e2c['model'],qs[_0x27aca3('0x51')](_0x18b467[_0x27aca3('0xd7')][_0x27aca3('0x51')])),_0x5c848c[_0x27aca3('0xab')]=_0x5c848c[_0x27aca3('0xab')][_0x27aca3('0x10')]?_0x5c848c[_0x27aca3('0xab')]:_0x494e2c[_0x27aca3('0xdb')];typeof _0x18b467[_0x27aca3('0xd7')]['nolimit']===_0x27aca3('0x74')&&(_0x5c848c['limit']=qs[_0x27aca3('0x43')](_0x18b467[_0x27aca3('0xd7')][_0x27aca3('0x43')]),_0x5c848c['offset']=qs['offset'](_0x18b467[_0x27aca3('0xd7')]['offset']));_0x5c848c[_0x27aca3('0x32')]=qs['sort'](_0x18b467[_0x27aca3('0xd7')]['sort']),_0x5c848c[_0x27aca3('0x8a')]=qs[_0x27aca3('0xc2')](_['pick'](_0x18b467[_0x27aca3('0xd7')],_0x494e2c['filters'])),_0x5c848c[_0x27aca3('0x8a')]['ChatInteractionId']=_0xdafb1d['id'];_0x18b467[_0x27aca3('0xd7')][_0x27aca3('0x8c')]&&(_0x5c848c[_0x27aca3('0x8a')]=_[_0x27aca3('0x108')](_0x5c848c[_0x27aca3('0x8a')],{[Op['or']]:_[_0x27aca3('0x40')](_0x5c848c[_0x27aca3('0xab')],function(_0x53a22c){const _0x4edd2c=_0x27aca3,_0x21b067={};return _0x21b067[_0x53a22c]={[Op[_0x4edd2c('0xff')]]:'%'+_0x18b467[_0x4edd2c('0xd7')][_0x4edd2c('0x8c')]+'%'},_0x21b067;})}));if(_0x18b467[_0x27aca3('0xd7')][_0x27aca3('0xde')]){const _0x2adcf6=_0x18b467['query'][_0x27aca3('0xde')][_0x27aca3('0x3d')](','),_0x13ee66={};_0x13ee66[_0x2adcf6[0x0]]={[Op[_0x27aca3('0x5c')]]:moment(_0x2adcf6[0x1])[_0x27aca3('0xbd')](_0x27aca3('0xa2'))},_0x5c848c[_0x27aca3('0x8a')]=_[_0x27aca3('0x108')](_0x5c848c[_0x27aca3('0x8a')],_0x13ee66);}return _0x5c848c=_[_0x27aca3('0x108')]({},_0x5c848c,_0x18b467['options']),db['ChatMessage']['count']({'where':_0x5c848c['where']})[_0x27aca3('0x2d')](function(_0x1ffa10){const _0x30ff42=_0x27aca3;return _0x41b2e0[_0x30ff42('0xf9')]=_0x1ffa10,_0x18b467[_0x30ff42('0xd7')][_0x30ff42('0x3')]&&(_0x5c848c[_0x30ff42('0x83')]=[{'all':!![]}]),db[_0x30ff42('0x23')][_0x30ff42('0x10c')](_0x5c848c);})[_0x27aca3('0x2d')](function(_0x2a6e89){const _0x3e170b=_0x27aca3;return _0x41b2e0[_0x3e170b('0xcb')]=_0x2a6e89,_0x41b2e0;});}})['then'](respondWithFilteredResult(_0x4a21d3,_0x5c848c))[_0x2c275b('0x55')](handleError(_0x4a21d3,null));},exports['getMyMessages']=function(_0x1c7cd9,_0xdfe41f){const _0x1e53fa=_0x4b28f7;let _0x27a8dc={'where':{}};const _0x899867={},_0x112e82={'count':0x0,'rows':[]};return db[_0x1e53fa('0x79')][_0x1e53fa('0x78')]({'where':{'id':_0x1c7cd9['params']['id']}})[_0x1e53fa('0x2d')](handleEntityNotFound(_0xdfe41f,null))[_0x1e53fa('0x2d')](function(_0x5d77cd){const _0x178450=_0x1e53fa;if(_0x5d77cd)return _0x899867[_0x178450('0xdb')]=_['keys'](db['ChatMessage'][_0x178450('0x8b')]),_0x899867[_0x178450('0xd7')]=_[_0x178450('0x72')](_0x1c7cd9[_0x178450('0xd7')]),_0x899867['filters']=_[_0x178450('0x19')](_0x899867['model'],_0x899867[_0x178450('0xd7')]),_0x27a8dc[_0x178450('0xab')]=_[_0x178450('0x19')](_0x899867['model'],qs[_0x178450('0x51')](_0x1c7cd9[_0x178450('0xd7')][_0x178450('0x51')])),_0x27a8dc[_0x178450('0xab')]=_0x27a8dc[_0x178450('0xab')][_0x178450('0x10')]?_0x27a8dc[_0x178450('0xab')]:_0x899867[_0x178450('0xdb')],typeof _0x1c7cd9[_0x178450('0xd7')][_0x178450('0x98')]===_0x178450('0x74')&&(_0x27a8dc['limit']=qs[_0x178450('0x43')](_0x1c7cd9['query'][_0x178450('0x43')]),_0x27a8dc['offset']=qs['offset'](_0x1c7cd9[_0x178450('0xd7')][_0x178450('0xec')])),_0x27a8dc[_0x178450('0x32')]=qs[_0x178450('0x3e')](_0x1c7cd9[_0x178450('0xd7')][_0x178450('0x3e')]),_0x27a8dc['where']=qs[_0x178450('0xc2')](_[_0x178450('0x93')](_0x1c7cd9['query'],_0x899867[_0x178450('0xc2')])),_0x27a8dc[_0x178450('0x8a')][_0x178450('0xe4')]=_0x5d77cd['id'],_0x1c7cd9[_0x178450('0xd7')][_0x178450('0x8c')]&&(_0x27a8dc[_0x178450('0x8a')]=_[_0x178450('0x108')](_0x27a8dc[_0x178450('0x8a')],{[Op['or']]:_[_0x178450('0x40')](_0x27a8dc[_0x178450('0xab')],function(_0x3cb408){const _0x2cce58=_0x178450,_0x4d9e16={};return _0x4d9e16[_0x3cb408]={[Op[_0x2cce58('0xff')]]:'%'+_0x1c7cd9['query'][_0x2cce58('0x8c')]+'%'},_0x4d9e16;})})),_0x27a8dc[_0x178450('0x8a')]['secret']=![],_0x1c7cd9[_0x178450('0xd7')]['id']&&(_0x27a8dc[_0x178450('0x8a')]['id']={[Op['gt']]:_0x1c7cd9[_0x178450('0xd7')]['id']}),_0x27a8dc=_['merge']({},_0x27a8dc,_0x1c7cd9[_0x178450('0x95')]),db['ChatMessage']['count']({'where':_0x27a8dc[_0x178450('0x8a')]})['then'](function(_0x5b5ddc){const _0x3f70ec=_0x178450;return _0x112e82[_0x3f70ec('0xf9')]=_0x5b5ddc,_0x27a8dc[_0x3f70ec('0x83')]=[],_0x1c7cd9['query'][_0x3f70ec('0xc7')]&&_0x27a8dc['include'][_0x3f70ec('0x5')]({'model':db['User'],'as':_0x3f70ec('0xae'),'attributes':['id',_0x3f70ec('0x69'),'alias']}),_0x1c7cd9[_0x3f70ec('0xd7')]['includeAll']&&(_0x27a8dc[_0x3f70ec('0x83')]=[{'all':!![]}]),db['ChatMessage']['findAll'](_0x27a8dc);})[_0x178450('0x2d')](function(_0x59ce0d){const _0x31ebad=_0x178450;return _0x112e82[_0x31ebad('0xcb')]=_0x59ce0d,_0x112e82;});})[_0x1e53fa('0x2d')](respondWithFilteredResult(_0xdfe41f,_0x27a8dc))[_0x1e53fa('0x55')](handleError(_0xdfe41f,null));},exports['addTags']=function(_0x25f27d,_0x5d21e7){const _0x3b6d7b=_0x4b28f7;return db[_0x3b6d7b('0x79')][_0x3b6d7b('0x78')]({'where':{'id':_0x25f27d['params']['id']}})[_0x3b6d7b('0x2d')](function(_0x1402f9){const _0x3080d7=_0x3b6d7b;if(_0x1402f9)return _0x1402f9['setTags'](_0x25f27d[_0x3080d7('0x1a')][_0x3080d7('0x47')],{'through':_[_0x3080d7('0xd6')](_0x25f27d['body'],['ids','id'])})[_0x3080d7('0x2d')](function(){const _0x44f4a9=_0x3080d7;return db[_0x44f4a9('0x82')][_0x44f4a9('0x10c')]({'attributes':['id',_0x44f4a9('0xd0'),_0x44f4a9('0x7a')],'where':{'id':_0x25f27d[_0x44f4a9('0x1a')][_0x44f4a9('0x47')]}});})[_0x3080d7('0x2d')](function(_0x2825ff){const _0x49a6d8=_0x3080d7;return socket[_0x49a6d8('0xa3')]('chatInteractionTags:save',{'id':Number(_0x25f27d[_0x49a6d8('0x50')]['id']),'tags':_0x2825ff||[]}),{'id':Number(_0x25f27d[_0x49a6d8('0x50')]['id']),'tags':_0x2825ff||[]};});})[_0x3b6d7b('0x2d')](respondWithResult(_0x5d21e7,null))[_0x3b6d7b('0x55')](handleError(_0x5d21e7,null));},exports[_0x4b28f7('0xce')]=function(_0x8e8f05,_0x934a81){const _0x5805cd=_0x4b28f7;return db['ChatInteraction'][_0x5805cd('0x78')]({'where':{'id':_0x8e8f05[_0x5805cd('0x50')]['id']}})[_0x5805cd('0x2d')](handleEntityNotFound(_0x934a81,null))['then'](function(_0x7d721d){const _0x391fe2=_0x5805cd;if(_0x7d721d)return _0x7d721d[_0x391fe2('0xce')](_0x8e8f05[_0x391fe2('0xd7')][_0x391fe2('0x47')]);})[_0x5805cd('0x2d')](respondWithStatusCode(_0x934a81,null))[_0x5805cd('0x55')](handleError(_0x934a81,null));},exports[_0x4b28f7('0xa1')]=function(_0x2f6ae8,_0x5c0bf5){const _0x1ce335=_0x4b28f7,_0x447117=moment()[_0x1ce335('0x7f')]()[_0x1ce335('0x2e')](),_0x18eb81=path[_0x1ce335('0xa7')](config[_0x1ce335('0xdf')],_0x1ce335('0xcd'),_0x1ce335('0x86')),_0x41c48c=path[_0x1ce335('0xa7')](config[_0x1ce335('0xdf')],'server',_0x1ce335('0xcd'),_0x1ce335('0x9b')),_0x138a1f=path['join'](_0x18eb81,_0x447117),_0x277dba=util[_0x1ce335('0xbd')]('transcript-%d-%s.zip',_0x2f6ae8['params']['id'],_0x447117),_0x1d8b00=path['join'](_0x18eb81,_0x277dba),_0x5e0df5=[];_0x5e0df5[_0x1ce335('0x5')]({'model':db[_0x1ce335('0xae')],'as':_0x1ce335('0xae'),'attributes':['id',_0x1ce335('0x69')],'raw':!![]}),_0x5e0df5['push']({'model':db[_0x1ce335('0x107')],'as':_0x1ce335('0xb8'),'attributes':['id',_0x1ce335('0xd'),_0x1ce335('0xc4')],'raw':!![]});_0x2f6ae8[_0x1ce335('0xd7')]['attachments']&&_0x5e0df5[_0x1ce335('0x5')]({'model':db[_0x1ce335('0x29')],'as':'Attachment','raw':!![]});const _0x3f0839=[{'model':db[_0x1ce335('0x23')],'as':_0x1ce335('0x45'),'attributes':['id',_0x1ce335('0x1a'),_0x1ce335('0x6b'),_0x1ce335('0x105'),_0x1ce335('0x3b'),_0x1ce335('0x24')],'include':_0x5e0df5}];return _0x3f0839[_0x1ce335('0x5')]({'model':db[_0x1ce335('0x20')],'as':'Account','attributes':['id','name']}),_0x3f0839['push']({'model':db[_0x1ce335('0xae')],'as':'Owner','attributes':['id','fullname']}),db[_0x1ce335('0x79')][_0x1ce335('0x78')]({'where':{'id':_0x2f6ae8['params']['id']},'include':_0x3f0839})[_0x1ce335('0x2d')](handleEntityNotFound(_0x5c0bf5,null))[_0x1ce335('0x2d')](function(_0x53afc9){const _0xc21c90=_0x1ce335;if(_0x53afc9){const _0x25ff60=_0x53afc9[_0xc21c90('0xcc')]({'plain':!![]});fs[_0xc21c90('0x13')](_0x138a1f);const _0x220a25={'format':'A4','border':_0xc21c90('0x1'),'header':{'height':_0xc21c90('0x106'),'contents':{'first':'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
Interaction\x20Transcript
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'}},'footer':{'height':_0xc21c90('0x9c'),'contents':{'default':util[_0xc21c90('0xbd')]('\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{page}}/{{pages}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20',util[_0xc21c90('0xbd')]('%s\x20#%d',_0xc21c90('0x68'),_0x25ff60['id']),moment()[_0xc21c90('0xbd')](_0xc21c90('0x7c'))[_0xc21c90('0x2e')]())}}},_0x100d9d={'channel':_0xc21c90('0x68'),'account':_0x25ff60[_0xc21c90('0x99')]['name'],'agent':_0x25ff60['Owner']?_0x25ff60['Owner'][_0xc21c90('0x69')]:_0xc21c90('0x10d'),'createdAt':moment(_0x25ff60[_0xc21c90('0x6b')])['format'](_0xc21c90('0xa2'))[_0xc21c90('0x2e')](),'closedAt':_0x25ff60[_0xc21c90('0xa6')]?moment(_0x25ff60[_0xc21c90('0x76')])[_0xc21c90('0xbd')](_0xc21c90('0xa2'))[_0xc21c90('0x2e')]():'','disposition':_0x25ff60['disposition'],'chatInfo':{'browser':_0x25ff60[_0xc21c90('0xe3')],'os':_0x25ff60['osName'],'referer':_0x25ff60['referer'],'customerIp':_0x25ff60[_0xc21c90('0x14')],'customerPort':_0x25ff60[_0xc21c90('0x94')]?_0x25ff60[_0xc21c90('0x94')]:'N.A.'},'messages':_(_0x25ff60[_0xc21c90('0x45')])[_0xc21c90('0x7')]()[_0xc21c90('0x8c')]({'secret':![]})[_0xc21c90('0x40')](function(_0x9ee332){const _0x4f68b7=_0xc21c90;if(_0x9ee332[_0x4f68b7('0x29')]){const _0x3164d9=path[_0x4f68b7('0xa7')](_0x41c48c,_0x9ee332[_0x4f68b7('0x29')]['basename']);fs[_0x4f68b7('0xef')](_0x3164d9)&&fs[_0x4f68b7('0xe6')](_0x3164d9)[_0x4f68b7('0x6c')](fs[_0x4f68b7('0x109')](path['join'](_0x138a1f,_0x9ee332[_0x4f68b7('0x29')]['basename'])));}return{'date':moment(_0x9ee332[_0x4f68b7('0x6b')])[_0x4f68b7('0xbd')](_0x4f68b7('0xa2'))[_0x4f68b7('0x2e')](),'sender':_0x9ee332['direction']===_0x4f68b7('0x10b')?_0x9ee332['User']?_0x9ee332[_0x4f68b7('0xae')][_0x4f68b7('0x69')]:_0x4f68b7('0x27'):_0x9ee332[_0x4f68b7('0xb8')][_0x4f68b7('0xd')]+(_0x9ee332[_0x4f68b7('0xb8')]['lastName']?'\x20'+_0x9ee332['Contact'][_0x4f68b7('0xc4')]:''),'body':_0x9ee332[_0x4f68b7('0x29')]?_0x9ee332[_0x4f68b7('0x29')][_0x4f68b7('0xc1')]:_0x9ee332[_0x4f68b7('0x1a')],'direction':_0x9ee332[_0x4f68b7('0x105')]===_0x4f68b7('0x10b')?'A':'C','secret':_0x9ee332['secret'],'read':_0x9ee332[_0x4f68b7('0x24')],'attachment':_0x9ee332['Attachment']};})[_0xc21c90('0xda')]()};return ejs['renderFile'](path[_0xc21c90('0xa7')](config[_0xc21c90('0xdf')],_0xc21c90('0x77'),_0xc21c90('0x90'),'downloadInteraction.html'),{'interaction':_0x100d9d})[_0xc21c90('0x2d')](function(_0x1272dd){return new Promise(function(_0x8fcc82,_0x100a2f){const _0x3c03e0=a66_0x20dc;pdf['create'](_0x1272dd,_0x220a25)[_0x3c03e0('0xfe')](path[_0x3c03e0('0xa7')](_0x138a1f,_0x3c03e0('0x16')+_0x25ff60['id']+'-'+_0x447117+_0x3c03e0('0x97')),function(_0x2adaab,_0x42efcb){if(_0x2adaab)return _0x100a2f(_0x2adaab);_0x8fcc82(_0x42efcb);});});})[_0xc21c90('0x2d')](function(){const _0x403155=_0xc21c90;return new Promise(function(_0x174fd4,_0x2cac24){zipdir(_0x138a1f,{'saveTo':_0x1d8b00},function(_0xa9c7d6,_0x3f81cd){if(_0xa9c7d6)return _0x2cac24(_0xa9c7d6);return _0x174fd4(_0x3f81cd);});})['then'](function(){return new Promise(function(_0x4ddd94,_0x271adb){rimraf(_0x138a1f,function(_0x186d88){if(_0x186d88)_0x271adb(_0x186d88);return _0x4ddd94();});});})[_0x403155('0x2d')](function(){const _0x390ad9=_0x403155;return _0x5c0bf5[_0x390ad9('0xa1')](_0x1d8b00,_0x277dba,function(_0x3411f2){const _0x301cce=_0x390ad9;_0x3411f2?console[_0x301cce('0x88')](_0x301cce('0x57'),_0x3411f2):fs['unlinkSync'](_0x1d8b00);});});});}else return _0x5c0bf5['sendStatus'](0xc8);})[_0x1ce335('0x55')](handleError(_0x5c0bf5,null));}; \ No newline at end of file +const a66_0x1f58=['agentIdentifier','host','$gte','intersection','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL','zip-dir','vidaooApiKey','color','i.ChatWebsiteId\x20IS\x20NULL','SELECT','mailTranscript','\x20=\x20?','mimetype','alias','push','where','ChatInteractionId','MailServerOut','disposition','YYYY-MM-DD\x20HH:mm:ss','search','offset','like','send','ChatInteraction,\x20%s,\x20%s','attributes','o.id\x20=\x20i.UserId','include','Users','addMessage','isNumeric','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','find','pathTranscript','DESC','users','user','code','user_has_chat_interactions','having','User','replace','rimraf','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
Interaction\x20Transcript
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','pass','abandon','i.ChatWebsiteId\x20IN\x20?','N.A.','$substring','tmp','rawAttributes','CmContact','c.email','./chatInteraction.socket','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{page}}/{{pages}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','Hi\x20%s,\x20attached\x20you\x20can\x20find\x20your\x20transcript\x20file.\x20\x0a\x0aRegards.\x20\x0a\x0a','ContactId','select','getMessages','transcript-%s.txt','clone','filters','concat','text','read','firstName','omit','tools_tags','union','i.id\x20LIKE\x20?','chat_messages','createdAt','forEach','Account','chat_interaction_has_tags','service','out','https://api-vidaoo.xcally.com/api/v1/sessions','u.id\x20=\x20ui.UserId','join_url','i.id','createWriteStream','[%s]\x20%s:\x20%s\x0a','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','value','includeAgent','query','debug','compact','Contact.email','MATCH\x20(me.body)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','Contact.mobile','error','`unreadMessages`\x20=\x200','createReadStream','expr','root','status','chat_websites','`\x20>\x200','a.key','Contact.lastName','c.phone','journey','unlinkSync','pick','secret','Unauthorized','isEmpty','secure','addTags','sequelize','order','c.firstName','customerPort','close','message','Attachment','$lte','tail','sqlOperator','lodash','agent_fullname','download','keys','ChatInteraction,\x20%s,\x20%s,\x20%s','err','count','body','originalname','fieldName','then','options','Contact.fax','POST','GROUP_CONCAT(DISTINCT\x20t.id)','buildExpression','me.ChatInteractionId\x20=\x20i.id','path','ChatWebsiteId','createVidaooSession','conditions','Smtp','get','AbandonInteraction','server','closedAt','getMyMessages','files/attachments/','website_alias','40px','now','u.fullname','i.*','all','stack','MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','params','info','http','Error\x20in\x20Vidaoo\x20configuration','ChatWebsite','api','Owner','%s%d','basename','type','squel','field','moment','ids','referer','isArray','renderFile','Interaction\x20already\x20assigned','format','closed','.pdf','30px','getFullTextValue','cm_contacts','transcript-%d-%s.zip','toString','Chat','result','customUpdate','chatInteractionTags:save','Contact.phone','model','resolve','file','attachId','request','authentication','name','SendMail','rows','filename','lastName','follow','../../config/environment','attachmentUpload','osName','ChatMessage','direction','Messages','MM/DD/YYYY\x20HH:mm:ss','fullname','json','YYYY-MM-DD','limit','attachments','getChatWebsites','o.fullname','client','Owner.internal','describe','join','stringify','end','unix','\x20IS\x20NULL','fields','start','tag','customer','Owner.fullname','jayson/promise','operator','port','merge','agentAlias','i.ChatWebsiteId\x20IS\x20NOT\x20NULL','browserName','agent_alias','create','filter','groupBy','System','Contact','nolimit','update','sort','../../components/parsers/qs','appendFileSync','Unable\x20to\x20create\x20Vidaoo\x20session','findAll','length','c.fax','request\x20sent','undefined','from','files','includeAll','ChatInteraction','Account.key','downloadInteraction.html','../../mysqldb','it.ChatInteractionId\x20=\x20i.id','catch','views','sendMail','unreadMessages','group','existsSync','removeTags','emit','`\x20=\x200','key','c.mobile','findOne','request-promise-native','register','map','TagIds','ejs','10px','parseSearch','MailAccount','sendStatus','Contact.firstName','pipe','left_join','UserId','split'];(function(_0x5d81da,_0x1f58d4){const _0x3a3866=function(_0x3f69ea){while(--_0x3f69ea){_0x5d81da['push'](_0x5d81da['shift']());}};_0x3a3866(++_0x1f58d4);}(a66_0x1f58,0x1a2));const a66_0x3a38=function(_0x5d81da,_0x1f58d4){_0x5d81da=_0x5d81da-0x0;let _0x3a3866=a66_0x1f58[_0x5d81da];return _0x3a3866;};const _0x57bc50=a66_0x3a38;'use strict';const pdf=require('html-pdf'),rimraf=require(_0x57bc50('0xc2')),zipdir=require(_0x57bc50('0x9d')),rp=require(_0x57bc50('0x8a')),moment=require(_0x57bc50('0x24')),util=require('util'),path=require(_0x57bc50('0x5')),ejs=require(_0x57bc50('0x8e')),fs=require('fs'),_=require(_0x57bc50('0x111')),squel=require(_0x57bc50('0x22')),{getSocket}=require('../../rediscache'),qs=require(_0x57bc50('0x6e')),as=require('../../components/parsers/advancedSearch'),logger=require('../../config/logger')(_0x57bc50('0x1d')),config=require(_0x57bc50('0x43')),db=require(_0x57bc50('0x7c'))['db'],{Op,ValidationError,QueryTypes}=require('sequelize'),socket=getSocket();require(_0x57bc50('0xcd'))[_0x57bc50('0x8b')](socket);const jayson=require(_0x57bc50('0x5e')),client=jayson['client'][_0x57bc50('0x1a')]({'port':0x232b}),client9004=jayson[_0x57bc50('0x51')]['http']({'port':0x232c});function respondWithRpcPromise(_0x3f69ea,_0x5a05d9,_0x416b66,_0x125035){return new Promise(function(_0xe2afc3,_0x64d1ec){const _0x43c9bd=a66_0x3a38,_0x54e36a=_0x125035||client;return _0x54e36a[_0x43c9bd('0x3b')](_0x3f69ea,_0x416b66)[_0x43c9bd('0x11b')](function(_0x2ce7b6){const _0x1f7c84=_0x43c9bd;logger[_0x1f7c84('0x19')](_0x1f7c84('0xb0'),_0x5a05d9,_0x1f7c84('0x74')),logger[_0x1f7c84('0xef')](_0x1f7c84('0x115'),_0x5a05d9,_0x1f7c84('0x74'),JSON[_0x1f7c84('0x55')](_0x2ce7b6));if(_0x2ce7b6[_0x1f7c84('0xf4')]){if(_0x2ce7b6[_0x1f7c84('0xf4')][_0x1f7c84('0xbd')]===0x1f4)return logger[_0x1f7c84('0xf4')](_0x1f7c84('0xb0'),_0x5a05d9,_0x2ce7b6[_0x1f7c84('0xf4')]['message']),_0x64d1ec(_0x2ce7b6[_0x1f7c84('0xf4')]['message']);return logger[_0x1f7c84('0xf4')](_0x1f7c84('0xb0'),_0x5a05d9,_0x2ce7b6[_0x1f7c84('0xf4')][_0x1f7c84('0x10c')]),_0xe2afc3(_0x2ce7b6[_0x1f7c84('0xf4')][_0x1f7c84('0x10c')]);}else logger['info']('ChatInteraction,\x20%s,\x20%s',_0x5a05d9,_0x1f7c84('0x74')),_0xe2afc3(_0x2ce7b6[_0x1f7c84('0x33')][_0x1f7c84('0x10c')]);})[_0x43c9bd('0x7e')](function(_0x4803f3){const _0x18dc95=_0x43c9bd;logger[_0x18dc95('0xf4')]('ChatInteraction,\x20%s,\x20%s',_0x5a05d9,_0x4803f3),_0x64d1ec(_0x4803f3);});});}function respondWithStatusCode(_0x2b242e,_0x2a5e0c){return _0x2a5e0c=_0x2a5e0c||0xcc,function(_0x1954b4){const _0x473070=a66_0x3a38;if(_0x1954b4)return _0x2b242e[_0x473070('0x92')](_0x2a5e0c);return _0x2b242e[_0x473070('0xf9')](_0x2a5e0c)[_0x473070('0x56')]();};}function respondWithResult(_0x432020,_0x5385fc){return _0x5385fc=_0x5385fc||0xc8,function(_0x51486b){const _0xd349d=a66_0x3a38;if(_0x51486b)return _0x432020['status'](_0x5385fc)[_0xd349d('0x4b')](_0x51486b);};}function respondWithFilteredResult(_0x4a3aa6,_0x40442c){return function(_0x39b5c2){const _0x1491db=a66_0x3a38;if(_0x39b5c2){const _0x1c8964=_0x39b5c2[_0x1491db('0x117')],_0x3f28c6=_0x40442c[_0x1491db('0xad')];let _0xe50136=_0x40442c[_0x1491db('0xad')]+_0x40442c[_0x1491db('0x4d')],_0x5689e5;return _0xe50136>=_0x1c8964?(_0xe50136=_0x1c8964,_0x5689e5=0xc8):_0x5689e5=0xce,_0x4a3aa6[_0x1491db('0xf9')](_0x5689e5),_0x4a3aa6['set']('Content-Range',_0x3f28c6+'-'+_0xe50136+'/'+_0x1c8964)[_0x1491db('0x4b')](_0x39b5c2);}return null;};}function saveUpdates(_0x53956e){return function(_0x4349d9){const _0x707b4f=a66_0x3a38;if(_0x4349d9)return _0x4349d9[_0x707b4f('0x6c')](_0x53956e)[_0x707b4f('0x11b')](function(_0x2f1f69){return _0x2f1f69;});return null;};}function removeEntity(_0x4c2a60){return function(_0x1c3348){const _0x159866=a66_0x3a38;if(_0x1c3348)return _0x1c3348['destroy']()[_0x159866('0x11b')](function(){const _0x3c1358=_0x159866;_0x4c2a60[_0x3c1358('0xf9')](0xcc)[_0x3c1358('0x56')]();});};}function handleEntityNotFound(_0x4a63f5){return function(_0x481258){const _0x8f0394=a66_0x3a38;return!_0x481258&&_0x4a63f5[_0x8f0394('0x92')](0x194),_0x481258;};}function handleError(_0x5cdc0a,_0x53d21e){return _0x53d21e=_0x53d21e||0x1f4,function(_0x285b26){const _0x200746=a66_0x3a38;logger['error'](_0x285b26[_0x200746('0x16')]),_0x285b26[_0x200746('0x3d')]&&delete _0x285b26['name'],_0x5cdc0a[_0x200746('0xf9')](_0x53d21e)[_0x200746('0xaf')](_0x285b26);};}function getInteractionUsers(_0x2a4738,_0x255197){return new Promise(function(_0xb9bad4,_0x3da79c){const _0x3de012=a66_0x3a38;try{_0x255197[_0x2a4738['id']]&&(_0x2a4738[_0x3de012('0xb4')]=_[_0x3de012('0x8c')](_0x255197[_0x2a4738['id']],function(_0x464f08){const _0x119426=_0x3de012;return{'id':_0x464f08['id'],'fullname':_0x464f08[_0x119426('0x4a')]};}));}catch(_0x3e5807){_0x3da79c(_0x3e5807);}_0xb9bad4(_0x2a4738);});}function getInteractionTags(_0x2473fc,_0x127f3b){return new Promise(function(_0x39906a,_0x5f1180){const _0x21a6ca=a66_0x3a38;try{_0x2473fc[_0x21a6ca('0x8d')]&&(_0x2473fc['Tags']=[],_0x2473fc[_0x21a6ca('0x8d')][_0x21a6ca('0x97')](',')['forEach'](function(_0x172b6d){_0x2473fc['Tags']['push'](_0x127f3b[_0x172b6d]);})),delete _0x2473fc[_0x21a6ca('0x8d')];}catch(_0xf48d1){_0x5f1180(_0xf48d1);}_0x39906a(_0x2473fc);});}function updateChatInteraction(_0x1d5cd6,_0x1addc1,_0x233419){return new Promise(function(_0x56a597,_0x425d84){const _0x1a7153=a66_0x3a38;return getInteractionUsers(_0x1d5cd6,_0x233419)['then'](function(_0xdcaf1e){return getInteractionTags(_0xdcaf1e,_0x1addc1);})[_0x1a7153('0x11b')](function(_0x3ff086){_0x56a597(_0x3ff086);})[_0x1a7153('0x7e')](function(_0x1fb7ff){_0x425d84(_0x1fb7ff);});});}exports['index']=function(_0x3b7098,_0x32a985){const _0x267775=_0x57bc50,_0x341d7c={},_0x1f2dff={},_0x47c3a4={'count':0x0,'rows':[]},_0x29b5e6=_[_0x267775('0x8c')](db[_0x267775('0x79')]['rawAttributes'],function(_0x3de3f9){const _0x5380cc=_0x267775;return{'name':_0x3de3f9[_0x5380cc('0x11a')],'type':_0x3de3f9[_0x5380cc('0x21')][_0x5380cc('0x87')]};});_0x1f2dff[_0x267775('0x37')]=_[_0x267775('0x8c')](_0x29b5e6,_0x267775('0x3d')),_0x1f2dff[_0x267775('0xee')]=_[_0x267775('0x114')](_0x3b7098['query']),_0x1f2dff[_0x267775('0xd5')]=_['intersection'](_0x1f2dff[_0x267775('0x37')],_0x1f2dff[_0x267775('0xee')]),_0x341d7c[_0x267775('0xb1')]=_[_0x267775('0x9b')](_0x1f2dff['model'],qs[_0x267775('0x59')](_0x3b7098['query'][_0x267775('0x59')])),_0x341d7c[_0x267775('0xb1')]=_0x341d7c[_0x267775('0xb1')][_0x267775('0x72')]?_0x341d7c[_0x267775('0xb1')]:_0x1f2dff['model'];typeof _0x3b7098[_0x267775('0xee')][_0x267775('0x6b')]===_0x267775('0x75')&&(_0x341d7c['limit']=qs[_0x267775('0x4d')](_0x3b7098[_0x267775('0xee')]['limit']),_0x341d7c[_0x267775('0xad')]=qs[_0x267775('0xad')](_0x3b7098[_0x267775('0xee')]['offset']));_0x341d7c[_0x267775('0x108')]=qs[_0x267775('0x6d')](_0x3b7098[_0x267775('0xee')]['sort']),_0x341d7c[_0x267775('0xa7')]=qs[_0x267775('0xd5')](_['pick'](_0x3b7098[_0x267775('0xee')],_0x1f2dff[_0x267775('0xd5')]),_0x29b5e6);let _0x38220a=[];const _0x2f133a=squel[_0x267775('0xd1')]()[_0x267775('0x23')]('id')[_0x267775('0x23')](_0x267775('0x3d'))[_0x267775('0x23')](_0x267775('0x9f'))['from'](_0x267775('0xdb')),_0x298eaf=squel['select']()['field']('u.id')['field'](_0x267775('0x13'))[_0x267775('0x23')]('ui.ChatInteractionId')[_0x267775('0x76')](_0x267775('0xbe'),'ui')['left_join'](_0x267775('0xbb'),'u',_0x267775('0xe6')),_0x1615b9=squel[_0x267775('0xd1')]()[_0x267775('0x76')]('chat_interactions','i')[_0x267775('0x95')](_0x267775('0x2f'),'c',_0x267775('0x9c'))['left_join'](_0x267775('0xbb'),'o',_0x267775('0xb2'))['left_join'](_0x267775('0xfa'),'a','a.id\x20=\x20i.ChatWebsiteId')[_0x267775('0x95')](_0x267775('0xde'),'me',_0x267775('0x4'))['left_join'](_0x267775('0xe2'),'it',_0x267775('0x7d'))['left_join']('tools_tags','t','t.id\x20=\x20it.TagId'),_0x446587=squel[_0x267775('0xf7')]();let _0x2b93a6=[];const _0x5c94c0=squel[_0x267775('0xf7')]();let _0x47b1d1;if(_0x3b7098['query']['search']){_0x47b1d1=as[_0x267775('0x90')](_0x3b7098[_0x267775('0xee')][_0x267775('0xac')]);const _0x4d1bee=_0x47b1d1[_0x267775('0x110')];for(let _0x1f9fd9=0x0;_0x1f9fd9<_0x47b1d1['conditions'][_0x267775('0x72')];_0x1f9fd9++){const _0x49959e=_0x47b1d1[_0x267775('0x8')][_0x1f9fd9],_0x28cf9e='i';let _0x467b8a,_0x3bb316=_[_0x267775('0xb8')](_0x29b5e6,[_0x267775('0x3d'),_0x49959e[_0x267775('0x23')]]);if(!_0x3bb316)switch(_0x49959e[_0x267775('0x23')]){case _0x267775('0x81'):_0x49959e[_0x267775('0xec')]==0x1?_0x1615b9[_0x267775('0xbf')]('`'+_0x49959e['field']+_0x267775('0x86')):_0x1615b9[_0x267775('0xbf')]('`'+_0x49959e[_0x267775('0x23')]+_0x267775('0xfb'));break;case _0x267775('0x6a'):if(_0x49959e[_0x267775('0x5f')]===_0x267775('0xc8')){if(_0x49959e[_0x267775('0xec')][_0x267775('0x97')]('\x20')[_0x267775('0x72')]>0x1)_0x446587[_0x4d1bee](_0x267775('0x17'),qs[_0x267775('0x2e')](_0x49959e[_0x267775('0xec')]),null);else{const _0x2fe0d0='%'+_0x49959e['value']+'%';_0x446587[_0x4d1bee]('c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?',_0x2fe0d0,_0x2fe0d0,_0x2fe0d0);}}else _0x3bb316=_[_0x267775('0xb8')](_0x29b5e6,[_0x267775('0x3d'),_0x267775('0xd0')]),_0x49959e[_0x267775('0x23')]=_0x267775('0xd0'),_0x467b8a=as[_0x267775('0x3')](_0x28cf9e,_0x3bb316[_0x267775('0x21')],_0x49959e),_0x446587[_0x4d1bee](_0x467b8a[_0x267775('0xd7')],_0x467b8a[_0x267775('0xec')][_0x267775('0x5a')],_0x467b8a[_0x267775('0xec')]['end']);break;case'Tag':{const _0xf49c6a=_0x49959e['value'][_0x267775('0x97')](',')[_0x267775('0x8c')](function(_0x1da6f0){return Number(_0x1da6f0);});_0xf49c6a[_0x267775('0xe0')](function(_0x4bf991){_0x5c94c0['or']('CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','%,'+_0x4bf991+',%');}),_0x2b93a6=_[_0x267775('0xdc')](_0x2b93a6,_0xf49c6a);}break;case _0x267775('0xc0'):_0x49959e['operator']==='$substring'?_0x446587[_0x4d1bee](_0x267775('0xeb'),'%'+_0x49959e[_0x267775('0xec')]+'%',null):(_0x3bb316=_[_0x267775('0xb8')](_0x29b5e6,[_0x267775('0x3d'),_0x267775('0x96')]),_0x49959e['field']=_0x267775('0x96'),_0x467b8a=as[_0x267775('0x3')](_0x28cf9e,_0x3bb316[_0x267775('0x21')],_0x49959e),_0x446587[_0x4d1bee](_0x467b8a[_0x267775('0xd7')],_0x467b8a['value'][_0x267775('0x5a')],_0x467b8a['value'][_0x267775('0x56')]));break;case _0x267775('0x118'):_0x467b8a=as[_0x267775('0x3')]('me',null,_0x49959e),_0x446587[_0x4d1bee](_0x467b8a[_0x267775('0xd7')],_0x467b8a[_0x267775('0xec')][_0x267775('0x5a')],_0x467b8a[_0x267775('0xec')][_0x267775('0x56')]);break;}else _0x467b8a=as['buildExpression'](_0x28cf9e,_0x3bb316['type'],_0x49959e),_0x446587[_0x4d1bee](_0x467b8a['text'],_0x467b8a['value'][_0x267775('0x5a')],_0x467b8a[_0x267775('0xec')][_0x267775('0x56')]);}}else{const _0x477eaf=_(_0x3b7098['query'])[_0x267775('0x114')]()[_0x267775('0x8c')](function(_0x51e8f4){const _0x1105aa=_0x267775;return _['some'](_0x29b5e6,[_0x1105aa('0x3d'),_0x51e8f4])?_0x51e8f4:undefined;})[_0x267775('0xf0')]()[_0x267775('0xec')]();!_[_0x267775('0x104')](_0x477eaf)&&_0x477eaf[_0x267775('0xe0')](function(_0x8dc711){const _0x58baf2=_0x267775;if(_0x8dc711===_0x58baf2('0x6'))_0x1615b9[_0x58baf2('0xa7')]('i.ChatWebsiteId\x20IN\x20?',[][_0x58baf2('0xd6')](_0x3b7098[_0x58baf2('0xee')][_0x8dc711]));else{if(_0x8dc711===_0x58baf2('0xdf')){const _0x2d7d1d=JSON['parse'](_0x3b7098['query'][_0x8dc711])[_0x58baf2('0x9a')],_0x1518f6=JSON['parse'](_0x3b7098['query'][_0x8dc711])[_0x58baf2('0x10e')];_0x1615b9['where']('i.createdAt\x20BETWEEN\x20?\x20AND\x20?',_0x2d7d1d,_0x1518f6);}else _0x3b7098[_0x58baf2('0xee')][_0x8dc711]==='null'?_0x1615b9[_0x58baf2('0xa7')]('i.'+_0x8dc711+_0x58baf2('0x58')):_0x1615b9[_0x58baf2('0xa7')]('i.'+_0x8dc711+_0x58baf2('0xa3'),_0x3b7098[_0x58baf2('0xee')][_0x8dc711]);}});_0x3b7098[_0x267775('0xee')]['read']&&(_0x3b7098['query'][_0x267775('0xd8')]==0x1?_0x1615b9[_0x267775('0xbf')](_0x267775('0xf5')):_0x1615b9[_0x267775('0xbf')]('`unreadMessages`\x20>\x200'));_0x3b7098[_0x267775('0xee')][_0x267775('0x5b')]&&(_0x2b93a6=_[_0x267775('0x27')](_0x3b7098[_0x267775('0xee')][_0x267775('0x5b')])?_0x3b7098[_0x267775('0xee')][_0x267775('0x5b')]:new Array(_0x3b7098[_0x267775('0xee')][_0x267775('0x5b')]),_0x2b93a6[_0x267775('0xe0')](function(_0x4a9b7b){_0x5c94c0['or']('CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','%,'+_0x4a9b7b+',%');}));if(_0x3b7098[_0x267775('0xee')][_0x267775('0x67')]){const _0x15af9a=_0x3b7098[_0x267775('0xee')][_0x267775('0x67')][_0x267775('0xc1')]('\x5c','\x5c\x5c')[_0x267775('0xc1')]('\x27\x27','\x27\x27\x27\x27');qs[_0x267775('0xb6')](_0x15af9a)?_0x446587['or'](_0x267775('0xdd'),_0x15af9a+'%'):_0x446587['or'](_0x267775('0xf2'),qs[_0x267775('0x2e')](_0x15af9a))['or']('CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?',_0x15af9a+'%');}}_0x1615b9[_0x267775('0xa7')](_0x446587),_0x1615b9[_0x267775('0x82')](_0x267775('0xe8'));let _0x29fdf1={'type':QueryTypes[_0x267775('0xa1')],'raw':!![]};const _0x435593=_0x1615b9[_0x267775('0xd4')]();_0x435593['field'](_0x267775('0xe8')),_0x435593[_0x267775('0x23')](_0x267775('0xb7'),'unreadMessages'),_0x341d7c['order']&&_0x341d7c[_0x267775('0x108')][_0x267775('0xe0')](function(_0x4f0350){const _0x5a271e=_0x267775;_0x1615b9[_0x5a271e('0x108')]('i.'+_0x4f0350[0x0],_0x4f0350[0x1]===_0x5a271e('0xba')?![]:!![]);}),!_[_0x267775('0x104')](_0x2b93a6)&&(_0x1615b9[_0x267775('0xbf')](_0x5c94c0),_0x435593['where']('t.id\x20IN\x20?',_0x2b93a6)),Promise[_0x267775('0x38')]()[_0x267775('0x11b')](function(){const _0x993800=_0x267775;if(!_0x47b1d1){if(_0x3b7098['query'][_0x993800('0x6')]||_0x3b7098[_0x993800('0xee')][_0x993800('0xff')])return;_0x435593[_0x993800('0xa7')](_0x993800('0x63')),_0x1615b9[_0x993800('0xa7')](_0x993800('0x63'));return;}return _0x3b7098['user'][_0x993800('0x4f')]({'attributes':['id'],'raw':!![]})['then'](function(_0x25b7fb){const _0x5a5f55=_0x993800;_[_0x5a5f55('0x104')](_0x25b7fb)?(_0x435593['where'](_0x5a5f55('0xa0')),_0x1615b9[_0x5a5f55('0xa7')](_0x5a5f55('0xa0'))):(_0x435593[_0x5a5f55('0xa7')](_0x5a5f55('0xc6'),_['map'](_0x25b7fb,'id')),_0x1615b9[_0x5a5f55('0xa7')]('i.ChatWebsiteId\x20IN\x20?',_[_0x5a5f55('0x8c')](_0x25b7fb,'id')));});})[_0x267775('0x11b')](function(){const _0x38744d=_0x267775;db[_0x38744d('0x107')]['query'](_0x435593[_0x38744d('0x31')](),_0x29fdf1)[_0x38744d('0x11b')](function(_0x1e11ef){const _0x191341=_0x38744d;_0x47c3a4['count']=_0x1e11ef[_0x191341('0x72')];if(_0x47c3a4[_0x191341('0x117')]===0x0)return[];return db[_0x191341('0x107')]['query'](_0x2f133a[_0x191341('0x31')](),_0x29fdf1)[_0x191341('0x11b')](function(_0x393b8e){const _0x390b33=_0x191341;_0x38220a=_['keyBy'](_0x393b8e,'id'),_0x29fdf1=_[_0x390b33('0x61')](_0x29fdf1,{'model':db['ChatInteraction'],'mapToModel':!![],'raw':!![],'nest':!![]});_0x3b7098[_0x390b33('0xee')][_0x390b33('0x59')]?_0x341d7c[_0x390b33('0xb1')][_0x390b33('0xe0')](function(_0x1eb3b4){const _0x2a5de2=_0x390b33;_0x1615b9[_0x2a5de2('0x23')]('i.'+_0x1eb3b4);}):(_0x1615b9[_0x390b33('0x23')](_0x390b33('0xb7'),_0x390b33('0x81')),_0x1615b9[_0x390b33('0x23')](_0x390b33('0xfc'),_0x390b33('0x7a')),_0x1615b9[_0x390b33('0x23')]('a.mandatoryDisposition','Account.mandatoryDisposition'),_0x1615b9[_0x390b33('0x23')](_0x390b33('0x14')),_0x1615b9[_0x390b33('0x23')](_0x390b33('0x109'),_0x390b33('0x93')),_0x1615b9['field']('c.lastName',_0x390b33('0xfd')),_0x1615b9['field'](_0x390b33('0xcc'),_0x390b33('0xf1')),_0x1615b9[_0x390b33('0x23')](_0x390b33('0xfe'),_0x390b33('0x36')),_0x1615b9[_0x390b33('0x23')](_0x390b33('0x88'),_0x390b33('0xf3')),_0x1615b9[_0x390b33('0x23')](_0x390b33('0x73'),_0x390b33('0x0')),_0x1615b9['field'](_0x390b33('0x50'),_0x390b33('0x5d')),_0x1615b9['field']('o.internal',_0x390b33('0x52')),_0x1615b9[_0x390b33('0x23')](_0x390b33('0x2'),_0x390b33('0x8d')));if(_0x341d7c['limit'])_0x1615b9[_0x390b33('0x4d')](_0x341d7c[_0x390b33('0x4d')]);if(_0x341d7c[_0x390b33('0xad')])_0x1615b9[_0x390b33('0xad')](_0x341d7c[_0x390b33('0xad')]);return db[_0x390b33('0x107')][_0x390b33('0xee')](_0x1615b9['toString'](),_0x29fdf1);})[_0x191341('0x11b')](function(_0x1165d4){const _0x3749b4=_0x191341;return _0x298eaf[_0x3749b4('0xa7')]('ui.ChatInteractionId\x20IN\x20?',_[_0x3749b4('0x8c')](_0x1165d4,'id')),db[_0x3749b4('0x107')][_0x3749b4('0xee')](_0x298eaf[_0x3749b4('0x31')](),_0x29fdf1)[_0x3749b4('0x11b')](function(_0x3f9e3f){const _0x164332=_0x3749b4,_0x37597f=_[_0x164332('0x68')](_0x3f9e3f,_0x164332('0xa8')),_0x1467cb=[];return _0x1165d4[_0x164332('0xe0')](function(_0x59d5d4){const _0x51f4d6=_0x164332;_0x1467cb[_0x51f4d6('0xa6')](updateChatInteraction(_0x59d5d4,_0x38220a,_0x37597f));}),Promise[_0x164332('0x15')](_0x1467cb);});});})['then'](function(_0x2c4efc){return _0x47c3a4['rows']=_0x2c4efc,_0x47c3a4;})[_0x38744d('0x11b')](respondWithFilteredResult(_0x32a985,_0x341d7c));})[_0x267775('0x7e')](handleError(_0x32a985,null));},exports['show']=function(_0x1a0d94,_0x2584da){const _0x343768=_0x57bc50;let _0x4b97f5={'raw':![],'where':{'id':_0x1a0d94['params']['id']}};const _0x425a4e={};return _0x425a4e[_0x343768('0x37')]=_[_0x343768('0x114')](db[_0x343768('0x79')][_0x343768('0xca')]),_0x425a4e[_0x343768('0xee')]=_[_0x343768('0x114')](_0x1a0d94['query']),_0x425a4e[_0x343768('0xd5')]=_['intersection'](_0x425a4e[_0x343768('0x37')],_0x425a4e[_0x343768('0xee')]),_0x4b97f5[_0x343768('0xb1')]=_[_0x343768('0x9b')](_0x425a4e[_0x343768('0x37')],qs[_0x343768('0x59')](_0x1a0d94[_0x343768('0xee')][_0x343768('0x59')])),_0x4b97f5['attributes']=_0x4b97f5[_0x343768('0xb1')]['length']?_0x4b97f5['attributes']:_0x425a4e['model'],_0x1a0d94[_0x343768('0xee')][_0x343768('0x78')]&&(_0x4b97f5[_0x343768('0xb3')]=[{'all':!![]}]),_0x4b97f5=_['merge']({},_0x4b97f5,_0x1a0d94[_0x343768('0x11c')]),db[_0x343768('0x79')][_0x343768('0x89')](_0x4b97f5)[_0x343768('0x11b')](handleEntityNotFound(_0x2584da,null))[_0x343768('0x11b')](respondWithResult(_0x2584da,null))[_0x343768('0x7e')](handleError(_0x2584da,null));},exports[_0x57bc50('0x66')]=function(_0x49ebeb,_0x3eccec){const _0x96a024=_0x57bc50;return db[_0x96a024('0x79')][_0x96a024('0x66')](_0x49ebeb['body'],{})[_0x96a024('0x11b')](respondWithResult(_0x3eccec,0xc9))['catch'](handleError(_0x3eccec,null));},exports[_0x57bc50('0x6c')]=function(_0x44727a,_0x510d39){const _0x565be3=_0x57bc50;return _0x44727a[_0x565be3('0x118')]['id']&&delete _0x44727a[_0x565be3('0x118')]['id'],db[_0x565be3('0x79')][_0x565be3('0x89')]({'where':{'id':_0x44727a[_0x565be3('0x18')]['id']}})['then'](handleEntityNotFound(_0x510d39,null))[_0x565be3('0x11b')](saveUpdates(_0x44727a[_0x565be3('0x118')],null))['then'](respondWithResult(_0x510d39,null))[_0x565be3('0x7e')](handleError(_0x510d39,null));},exports['destroy']=function(_0xeac351,_0x1b3900){const _0x86a09=_0x57bc50;return db[_0x86a09('0x79')][_0x86a09('0x89')]({'where':{'id':_0xeac351[_0x86a09('0x18')]['id']}})['then'](handleEntityNotFound(_0x1b3900,null))[_0x86a09('0x11b')](removeEntity(_0x1b3900,null))['catch'](handleError(_0x1b3900,null));},exports[_0x57bc50('0x53')]=function(_0x44652d,_0x191cff){const _0x3dd156=_0x57bc50;return db[_0x3dd156('0x79')][_0x3dd156('0x53')]()[_0x3dd156('0x11b')](respondWithResult(_0x191cff,null))[_0x3dd156('0x7e')](handleError(_0x191cff,null));},exports[_0x57bc50('0x7')]=function(_0x2b5557,_0x48d820){const _0x268d51=_0x57bc50,_0x5e72b9=_0x2b5557[_0x268d51('0x18')]['id'];let _0x456b16,_0x4666b4,_0x2e052c;return db[_0x268d51('0x79')][_0x268d51('0x89')]({'where':{'id':_0x5e72b9}})[_0x268d51('0x11b')](function(_0x30b276){const _0x5da21b=_0x268d51;return _0x456b16=_0x30b276,db[_0x5da21b('0x1c')]['findOne']({'where':{'id':_0x30b276[_0x5da21b('0x6')]},'attributes':['id','vidaooApiKey','vidaooEscalation'],'raw':!![]});})[_0x268d51('0x11b')](function(_0x390362){const _0x529548=_0x268d51;if(_0x390362&&_0x390362[_0x529548('0x9e')]&&_0x390362['vidaooEscalation']){_0x4666b4=_0x390362;const _0x5bdc78={'rejectUnauthorized':![],'method':_0x529548('0x1'),'uri':_0x529548('0xe5'),'headers':{'X-APIKEY':_0x390362[_0x529548('0x9e')]},'body':{'name':'MotionCWB:'+_0x5e72b9},'redirect':_0x529548('0x42'),'json':!![]};return rp(_0x5bdc78);}else throw new ValidationError(_0x529548('0x1b'));})[_0x268d51('0x11b')](function(_0x4111a3){const _0x3bc05e=_0x268d51;_0x2e052c=_0x4111a3;if(_0x2e052c['id']){const _0x419b7c={'body':_0x2e052c[_0x3bc05e('0xe7')],'ChatWebsiteId':_0x4666b4['id'],'ChatInteractionId':_0x456b16['id'],'direction':_0x3bc05e('0xe4'),'UserId':_0x2b5557[_0x3bc05e('0xbc')]['id']};return db[_0x3bc05e('0x46')][_0x3bc05e('0x66')](_0x419b7c,{});}else throw new ValidationError(_0x3bc05e('0x70'));})['then'](function(){const _0x4c3bf6=_0x268d51;return _0x456b16[_0x4c3bf6('0x6c')]({'vidaooSessionId':_0x2e052c['id']});})[_0x268d51('0x11b')](respondWithResult(_0x48d820,null))[_0x268d51('0x7e')](handleError(_0x48d820,null));},exports[_0x57bc50('0x34')]=function(_0x5ed1dd,_0x49db6c){const _0x3fe031=_0x57bc50;return _0x5ed1dd[_0x3fe031('0x118')]['id']&&delete _0x5ed1dd[_0x3fe031('0x118')]['id'],db[_0x3fe031('0x79')][_0x3fe031('0x89')]({'where':{'id':_0x5ed1dd[_0x3fe031('0x18')]['id']}})[_0x3fe031('0x11b')](handleEntityNotFound(_0x49db6c,null))[_0x3fe031('0x11b')](saveUpdates(_0x5ed1dd[_0x3fe031('0x118')],null))['then'](respondWithResult(_0x49db6c,null))[_0x3fe031('0x7e')](handleError(_0x49db6c,null));},exports['abandon']=function(_0x497b22,_0x25d093){const _0xaf4fbb=_0x57bc50;return _0x497b22['body']['id']&&delete _0x497b22[_0xaf4fbb('0x118')]['id'],db[_0xaf4fbb('0x79')][_0xaf4fbb('0x89')]({'where':{'id':_0x497b22[_0xaf4fbb('0x18')]['id']}})[_0xaf4fbb('0x11b')](function(_0x1950d4){const _0x336717=_0xaf4fbb;if(!_0x1950d4)logger[_0x336717('0xf4')]('abandonInteraction,\x20%s,\x20%s,\x20%s',_0x336717('0xc5'),0x194,'entity\x20not\x20found'),_0x25d093['sendStatus'](0x194);else{if(_0x1950d4[_0x336717('0x96')])throw new ValidationError(_0x336717('0x29'));}return _0x1950d4;})[_0xaf4fbb('0x11b')](function(_0x4c4163){const _0x290ac2=_0xaf4fbb;if(_0x4c4163)return _0x4c4163[_0x290ac2('0x6c')]({'closed':_0x497b22[_0x290ac2('0x118')]['closed'],'disposition':_0x497b22['body'][_0x290ac2('0xaa')]})[_0x290ac2('0x11b')](function(_0xfaa533){return _0xfaa533;});})['then'](function(){const _0x15ba83=_0xaf4fbb;return respondWithRpcPromise(_0x15ba83('0xb'),_0x15ba83('0xc5'),_0x497b22[_0x15ba83('0x118')],client9004);})['then'](respondWithResult(_0x25d093,null))[_0xaf4fbb('0x7e')](handleError(_0x25d093,null));},exports[_0x57bc50('0x44')]=function(_0x4ee8f9,_0x7ad322){const _0x11fbe8=_0x57bc50;return _0x4ee8f9['body']['name']=_0x4ee8f9[_0x11fbe8('0x39')][_0x11fbe8('0x119')],_0x4ee8f9[_0x11fbe8('0x118')][_0x11fbe8('0x20')]=_0x4ee8f9[_0x11fbe8('0x39')][_0x11fbe8('0x40')],_0x4ee8f9['body'][_0x11fbe8('0x21')]=_0x4ee8f9['file'][_0x11fbe8('0xa4')],db[_0x11fbe8('0x10d')]['create'](_0x4ee8f9[_0x11fbe8('0x118')])['then'](respondWithResult(_0x7ad322,0xc9))[_0x11fbe8('0x7e')](handleError(_0x7ad322,null));},exports['attachmentDownload']=function(_0xc51096,_0x554f21){const _0x46509=_0x57bc50;return db[_0x46509('0x79')][_0x46509('0x89')]({'where':{'id':_0xc51096[_0x46509('0x18')]['id']},'raw':!![]})[_0x46509('0x11b')](handleEntityNotFound(_0x554f21,null))['then'](function(_0x13598c){const _0xa15eed=_0x46509;if(_0x13598c){if(_0x13598c[_0xa15eed('0x2b')])return _0x554f21['status'](0x193)[_0xa15eed('0x4b')]({'status':0x193,'message':_0xa15eed('0x103')});return db[_0xa15eed('0x10d')][_0xa15eed('0x89')]({'where':{'id':_0xc51096[_0xa15eed('0xee')][_0xa15eed('0x3a')]},'raw':!![]})[_0xa15eed('0x11b')](handleEntityNotFound(_0x554f21,null));}})[_0x46509('0x11b')](function(_0x47465c){const _0x5ca292=_0x46509;if(_0x47465c)return _0x554f21[_0x5ca292('0x113')](path[_0x5ca292('0x54')](config[_0x5ca292('0xf8')],_0x5ca292('0xf'),_0x47465c[_0x5ca292('0x20')]));})['catch'](handleError(_0x554f21,null));},exports[_0x57bc50('0x10b')]=function(_0x24fdfe,_0x27ceea){const _0x129607=_0x57bc50;let _0x15585e=null,_0x374ed4=null,_0x405a4a=null;return _0x24fdfe[_0x129607('0x118')]['id']&&delete _0x24fdfe[_0x129607('0x118')]['id'],_0x24fdfe[_0x129607('0x118')][_0x129607('0xa2')]&&(_0x405a4a=path[_0x129607('0x54')](config[_0x129607('0xf8')],'server/files/chat/upload/',util['format'](_0x129607('0xd3'),Date[_0x129607('0x12')]())),_0x24fdfe[_0x129607('0x118')][_0x129607('0xb9')]=_0x405a4a),db[_0x129607('0x79')]['findOne']({'where':{'id':_0x24fdfe[_0x129607('0x18')]['id']},'include':[{'model':db[_0x129607('0x46')],'as':'Messages','include':[{'model':db[_0x129607('0xc0')],'as':_0x129607('0xc0')}]}]})[_0x129607('0x11b')](handleEntityNotFound(_0x27ceea,null))[_0x129607('0x11b')](saveUpdates(_0x24fdfe[_0x129607('0x118')],null))[_0x129607('0x11b')](function(_0x1986d0){const _0x11c0ed=_0x129607;if(_0x1986d0)return _0x15585e=_0x1986d0,db[_0x11c0ed('0x1c')]['findOne']({'where':{'id':_0x15585e[_0x11c0ed('0x6')]}});})[_0x129607('0x11b')](function(_0xfbfd8c){const _0x3be231=_0x129607;if(_0xfbfd8c)return _0x374ed4=_0xfbfd8c,db['CmContact'][_0x3be231('0x89')]({'where':{'id':_0x15585e[_0x3be231('0xd0')]}});})['then'](function(_0x27c2ba){const _0x215335=_0x129607;if(_0x27c2ba){if(_0x405a4a){let _0x21d71c=null;for(let _0x5a411c=0x1;_0x5a411c<_0x15585e['Messages']['length'];++_0x5a411c){_0x21d71c=_0x15585e[_0x215335('0x48')][_0x5a411c];let _0x5d8946=_0x21d71c[_0x215335('0x96')]?util[_0x215335('0x2a')](_0x215335('0x1f'),_0x374ed4[_0x215335('0x62')],_0x21d71c[_0x215335('0x96')]):'System';const _0x2f4142=_0x24fdfe['body'][_0x215335('0x5c')]||util[_0x215335('0x2a')](_0x215335('0x1f'),'Visitor',_0x21d71c[_0x215335('0xd0')]);switch(_0x374ed4[_0x215335('0x98')]){case _0x215335('0x10'):_0x5d8946=_0x21d71c[_0x215335('0x96')]?util[_0x215335('0x2a')]('%s%d',_0x374ed4[_0x215335('0x62')],_0x21d71c[_0x215335('0x96')]):'System';break;case _0x215335('0x65'):_0x5d8946=_0x21d71c[_0x215335('0x96')]?_0x21d71c[_0x215335('0xc0')][_0x215335('0xa5')]||_0x21d71c['User']['fullname']:_0x215335('0x69');break;case _0x215335('0x112'):_0x5d8946=_0x21d71c['UserId']?_0x21d71c[_0x215335('0xc0')]['fullname']:_0x215335('0x69');break;default:_0x5d8946=_0x21d71c[_0x215335('0x96')]?util[_0x215335('0x2a')](_0x215335('0x1f'),_0x374ed4['agentAlias'],_0x21d71c[_0x215335('0x96')]):_0x215335('0x69');}const _0x4fcff7=util[_0x215335('0x2a')](_0x215335('0xea'),moment(_0x21d71c[_0x215335('0xdf')])[_0x215335('0x2a')](_0x215335('0x49')),_0x21d71c['direction']==='in'?_0x2f4142:_0x5d8946,_0x21d71c[_0x215335('0x118')]);!_0x21d71c[_0x215335('0x102')]&&fs[_0x215335('0x6f')](_0x405a4a,_0x4fcff7);}return db[_0x215335('0x91')][_0x215335('0x89')]({'where':{'service':!![]},'include':[{'model':db[_0x215335('0xa9')],'as':_0x215335('0x9'),'raw':!![]}]});}}})[_0x129607('0x11b')](function(_0x411205){const _0x3662a9=_0x129607;if(_0x411205&&_0x411205[_0x3662a9('0x9')]&&_0x24fdfe[_0x3662a9('0x118')]){const _0x697b68={'tls':{'rejectUnauthorized':![]}};return _0x411205[_0x3662a9('0x9')][_0x3662a9('0xe3')]?_0x697b68[_0x3662a9('0xe3')]=_0x411205[_0x3662a9('0x9')][_0x3662a9('0xe3')]:(_0x697b68[_0x3662a9('0x99')]=_0x411205['Smtp'][_0x3662a9('0x99')],_0x697b68[_0x3662a9('0x60')]=_0x411205['Smtp']['port'],_0x697b68[_0x3662a9('0x105')]=_0x411205[_0x3662a9('0x9')][_0x3662a9('0x105')]),_0x411205['Smtp'][_0x3662a9('0x3c')]&&(_0x697b68['auth']={'user':_0x411205[_0x3662a9('0x9')][_0x3662a9('0xbc')],'pass':_0x411205[_0x3662a9('0x9')][_0x3662a9('0xc4')]}),respondWithRpcPromise(_0x3662a9('0x3e'),_0x3662a9('0x80'),{'account':_0x697b68,'message':{'from':util[_0x3662a9('0x2a')]('\x22%s\x22\x20<%s>',_0x411205[_0x3662a9('0x3d')],_0x411205['email']||_0x411205[_0x3662a9('0x9')][_0x3662a9('0xbc')]),'to':_0x24fdfe[_0x3662a9('0x118')][_0x3662a9('0xa2')],'subject':'Mail\x20Transcript','text':util[_0x3662a9('0x2a')](_0x3662a9('0xcf'),_0x24fdfe[_0x3662a9('0x118')]['mailTranscript']),'attachments':[{'path':_0x405a4a}]}})['then'](function(){return _0x15585e;})[_0x3662a9('0x7e')](function(_0x112bb1){const _0x52f10f=_0x3662a9;console[_0x52f10f('0xf4')](_0x112bb1);});}else return _0x15585e;})[_0x129607('0x11b')](respondWithStatusCode(_0x27ceea,0xc8))['catch'](handleError(_0x27ceea,null));},exports[_0x57bc50('0xb5')]=function(_0x4180eb,_0x19b790){const _0x118f66=_0x57bc50;return db[_0x118f66('0x46')][_0x118f66('0x89')]({'where':{'id':_0x4180eb['params']['id']}})[_0x118f66('0x11b')](function(_0x18d2be){const _0x56c1e2=_0x118f66;if(_0x18d2be)return _0x18d2be['addMessage'](_0x4180eb[_0x56c1e2('0x118')][_0x56c1e2('0x25')],{'through':_[_0x56c1e2('0xda')](_0x4180eb['body'],[_0x56c1e2('0x25'),'id'])});})[_0x118f66('0x11b')](respondWithResult(_0x19b790,null))[_0x118f66('0x7e')](handleError(_0x19b790,null));},exports[_0x57bc50('0xd2')]=function(_0x17b431,_0x1e8b5e){const _0x20798d=_0x57bc50;let _0x16f486={'raw':![],'where':{}};const _0x5330ed={},_0x1f35e8={'count':0x0,'rows':[]};return db[_0x20798d('0x79')][_0x20798d('0x89')]({'where':{'id':_0x17b431[_0x20798d('0x18')]['id']}})[_0x20798d('0x11b')](handleEntityNotFound(_0x1e8b5e,null))[_0x20798d('0x11b')](function(_0x3acf8e){const _0x4461d0=_0x20798d;if(_0x3acf8e){_0x5330ed[_0x4461d0('0x37')]=_['keys'](db[_0x4461d0('0x46')][_0x4461d0('0xca')]),_0x5330ed[_0x4461d0('0xee')]=_['keys'](_0x17b431[_0x4461d0('0xee')]),_0x5330ed[_0x4461d0('0xd5')]=_[_0x4461d0('0x9b')](_0x5330ed[_0x4461d0('0x37')],_0x5330ed[_0x4461d0('0xee')]),_0x16f486['attributes']=_[_0x4461d0('0x9b')](_0x5330ed[_0x4461d0('0x37')],qs[_0x4461d0('0x59')](_0x17b431[_0x4461d0('0xee')][_0x4461d0('0x59')])),_0x16f486['attributes']=_0x16f486[_0x4461d0('0xb1')][_0x4461d0('0x72')]?_0x16f486[_0x4461d0('0xb1')]:_0x5330ed[_0x4461d0('0x37')];typeof _0x17b431[_0x4461d0('0xee')][_0x4461d0('0x6b')]===_0x4461d0('0x75')&&(_0x16f486[_0x4461d0('0x4d')]=qs['limit'](_0x17b431[_0x4461d0('0xee')][_0x4461d0('0x4d')]),_0x16f486[_0x4461d0('0xad')]=qs[_0x4461d0('0xad')](_0x17b431['query']['offset']));_0x16f486[_0x4461d0('0x108')]=qs[_0x4461d0('0x6d')](_0x17b431['query']['sort']),_0x16f486['where']=qs['filters'](_['pick'](_0x17b431[_0x4461d0('0xee')],_0x5330ed['filters'])),_0x16f486[_0x4461d0('0xa7')][_0x4461d0('0xa8')]=_0x3acf8e['id'];_0x17b431['query'][_0x4461d0('0x67')]&&(_0x16f486[_0x4461d0('0xa7')]=_[_0x4461d0('0x61')](_0x16f486[_0x4461d0('0xa7')],{[Op['or']]:_['map'](_0x16f486[_0x4461d0('0xb1')],function(_0x186e0d){const _0x5d473d=_0x4461d0,_0xa615c8={};return _0xa615c8[_0x186e0d]={[Op[_0x5d473d('0xae')]]:'%'+_0x17b431[_0x5d473d('0xee')][_0x5d473d('0x67')]+'%'},_0xa615c8;})}));if(_0x17b431[_0x4461d0('0xee')]['$gte']){const _0xabdc9e=_0x17b431[_0x4461d0('0xee')][_0x4461d0('0x9a')][_0x4461d0('0x97')](','),_0x5b0301={};_0x5b0301[_0xabdc9e[0x0]]={[Op['gte']]:moment(_0xabdc9e[0x1])['format'](_0x4461d0('0xab'))},_0x16f486[_0x4461d0('0xa7')]=_[_0x4461d0('0x61')](_0x16f486['where'],_0x5b0301);}return _0x16f486=_[_0x4461d0('0x61')]({},_0x16f486,_0x17b431['options']),db['ChatMessage']['count']({'where':_0x16f486[_0x4461d0('0xa7')]})[_0x4461d0('0x11b')](function(_0x2c7ddd){const _0x4886e9=_0x4461d0;return _0x1f35e8[_0x4886e9('0x117')]=_0x2c7ddd,_0x17b431[_0x4886e9('0xee')][_0x4886e9('0x78')]&&(_0x16f486[_0x4886e9('0xb3')]=[{'all':!![]}]),db[_0x4886e9('0x46')][_0x4886e9('0x71')](_0x16f486);})[_0x4461d0('0x11b')](function(_0x17d446){const _0x410e66=_0x4461d0;return _0x1f35e8[_0x410e66('0x3f')]=_0x17d446,_0x1f35e8;});}})[_0x20798d('0x11b')](respondWithFilteredResult(_0x1e8b5e,_0x16f486))[_0x20798d('0x7e')](handleError(_0x1e8b5e,null));},exports[_0x57bc50('0xe')]=function(_0x1eecab,_0x12d1bf){const _0x19b42f=_0x57bc50;let _0x689f8b={'where':{}};const _0x4dcf09={},_0x4e2aa3={'count':0x0,'rows':[]};return db[_0x19b42f('0x79')][_0x19b42f('0x89')]({'where':{'id':_0x1eecab[_0x19b42f('0x18')]['id']}})[_0x19b42f('0x11b')](handleEntityNotFound(_0x12d1bf,null))[_0x19b42f('0x11b')](function(_0x361ee6){const _0x40f6b6=_0x19b42f;if(_0x361ee6)return _0x4dcf09[_0x40f6b6('0x37')]=_[_0x40f6b6('0x114')](db[_0x40f6b6('0x46')][_0x40f6b6('0xca')]),_0x4dcf09[_0x40f6b6('0xee')]=_[_0x40f6b6('0x114')](_0x1eecab[_0x40f6b6('0xee')]),_0x4dcf09['filters']=_[_0x40f6b6('0x9b')](_0x4dcf09[_0x40f6b6('0x37')],_0x4dcf09[_0x40f6b6('0xee')]),_0x689f8b['attributes']=_[_0x40f6b6('0x9b')](_0x4dcf09[_0x40f6b6('0x37')],qs['fields'](_0x1eecab[_0x40f6b6('0xee')][_0x40f6b6('0x59')])),_0x689f8b['attributes']=_0x689f8b[_0x40f6b6('0xb1')][_0x40f6b6('0x72')]?_0x689f8b['attributes']:_0x4dcf09[_0x40f6b6('0x37')],typeof _0x1eecab['query'][_0x40f6b6('0x6b')]===_0x40f6b6('0x75')&&(_0x689f8b['limit']=qs['limit'](_0x1eecab[_0x40f6b6('0xee')]['limit']),_0x689f8b[_0x40f6b6('0xad')]=qs['offset'](_0x1eecab[_0x40f6b6('0xee')][_0x40f6b6('0xad')])),_0x689f8b[_0x40f6b6('0x108')]=qs[_0x40f6b6('0x6d')](_0x1eecab[_0x40f6b6('0xee')]['sort']),_0x689f8b[_0x40f6b6('0xa7')]=qs[_0x40f6b6('0xd5')](_[_0x40f6b6('0x101')](_0x1eecab[_0x40f6b6('0xee')],_0x4dcf09[_0x40f6b6('0xd5')])),_0x689f8b[_0x40f6b6('0xa7')]['ChatInteractionId']=_0x361ee6['id'],_0x1eecab['query'][_0x40f6b6('0x67')]&&(_0x689f8b[_0x40f6b6('0xa7')]=_[_0x40f6b6('0x61')](_0x689f8b[_0x40f6b6('0xa7')],{[Op['or']]:_[_0x40f6b6('0x8c')](_0x689f8b['attributes'],function(_0x588deb){const _0x24bd1a=_0x40f6b6,_0x2525cf={};return _0x2525cf[_0x588deb]={[Op['like']]:'%'+_0x1eecab[_0x24bd1a('0xee')][_0x24bd1a('0x67')]+'%'},_0x2525cf;})})),_0x689f8b['where'][_0x40f6b6('0x102')]=![],_0x1eecab[_0x40f6b6('0xee')]['id']&&(_0x689f8b[_0x40f6b6('0xa7')]['id']={[Op['gt']]:_0x1eecab['query']['id']}),_0x689f8b=_[_0x40f6b6('0x61')]({},_0x689f8b,_0x1eecab[_0x40f6b6('0x11c')]),db[_0x40f6b6('0x46')][_0x40f6b6('0x117')]({'where':_0x689f8b[_0x40f6b6('0xa7')]})[_0x40f6b6('0x11b')](function(_0x12a2e3){const _0x7de493=_0x40f6b6;return _0x4e2aa3[_0x7de493('0x117')]=_0x12a2e3,_0x689f8b['include']=[],_0x1eecab[_0x7de493('0xee')][_0x7de493('0xed')]&&_0x689f8b[_0x7de493('0xb3')]['push']({'model':db['User'],'as':_0x7de493('0xc0'),'attributes':['id',_0x7de493('0x4a'),_0x7de493('0xa5')]}),_0x1eecab[_0x7de493('0xee')][_0x7de493('0x78')]&&(_0x689f8b['include']=[{'all':!![]}]),db['ChatMessage']['findAll'](_0x689f8b);})['then'](function(_0x13d834){const _0x37caae=_0x40f6b6;return _0x4e2aa3[_0x37caae('0x3f')]=_0x13d834,_0x4e2aa3;});})[_0x19b42f('0x11b')](respondWithFilteredResult(_0x12d1bf,_0x689f8b))[_0x19b42f('0x7e')](handleError(_0x12d1bf,null));},exports[_0x57bc50('0x106')]=function(_0x248d92,_0x458c13){const _0x34cb6f=_0x57bc50;return db['ChatInteraction'][_0x34cb6f('0x89')]({'where':{'id':_0x248d92[_0x34cb6f('0x18')]['id']}})[_0x34cb6f('0x11b')](function(_0x4653f4){const _0x3d6329=_0x34cb6f;if(_0x4653f4)return _0x4653f4['setTags'](_0x248d92[_0x3d6329('0x118')][_0x3d6329('0x25')],{'through':_[_0x3d6329('0xda')](_0x248d92[_0x3d6329('0x118')],[_0x3d6329('0x25'),'id'])})[_0x3d6329('0x11b')](function(){const _0xee38b3=_0x3d6329;return db['Tag'][_0xee38b3('0x71')]({'attributes':['id',_0xee38b3('0x3d'),_0xee38b3('0x9f')],'where':{'id':_0x248d92[_0xee38b3('0x118')]['ids']}});})[_0x3d6329('0x11b')](function(_0x298f7b){const _0xa4bc45=_0x3d6329;return socket[_0xa4bc45('0x85')](_0xa4bc45('0x35'),{'id':Number(_0x248d92[_0xa4bc45('0x18')]['id']),'tags':_0x298f7b||[]}),{'id':Number(_0x248d92[_0xa4bc45('0x18')]['id']),'tags':_0x298f7b||[]};});})[_0x34cb6f('0x11b')](respondWithResult(_0x458c13,null))[_0x34cb6f('0x7e')](handleError(_0x458c13,null));},exports[_0x57bc50('0x84')]=function(_0x16cdfa,_0x1d17f2){const _0x4fc1d3=_0x57bc50;return db['ChatInteraction'][_0x4fc1d3('0x89')]({'where':{'id':_0x16cdfa[_0x4fc1d3('0x18')]['id']}})['then'](handleEntityNotFound(_0x1d17f2,null))['then'](function(_0x57b481){const _0x21db0f=_0x4fc1d3;if(_0x57b481)return _0x57b481[_0x21db0f('0x84')](_0x16cdfa[_0x21db0f('0xee')][_0x21db0f('0x25')]);})[_0x4fc1d3('0x11b')](respondWithStatusCode(_0x1d17f2,null))['catch'](handleError(_0x1d17f2,null));},exports[_0x57bc50('0x113')]=function(_0x3b80d1,_0x509e3b){const _0xd9b580=_0x57bc50,_0x29af10=moment()[_0xd9b580('0x57')]()['toString'](),_0x46f001=path[_0xd9b580('0x54')](config[_0xd9b580('0xf8')],_0xd9b580('0x77'),_0xd9b580('0xc9')),_0x361bc0=path[_0xd9b580('0x54')](config[_0xd9b580('0xf8')],_0xd9b580('0xc'),'files','attachments'),_0x6698f7=path[_0xd9b580('0x54')](_0x46f001,_0x29af10),_0x54dc18=util['format'](_0xd9b580('0x30'),_0x3b80d1[_0xd9b580('0x18')]['id'],_0x29af10),_0x245a34=path[_0xd9b580('0x54')](_0x46f001,_0x54dc18),_0x2c2b82=[];_0x2c2b82[_0xd9b580('0xa6')]({'model':db[_0xd9b580('0xc0')],'as':'User','attributes':['id',_0xd9b580('0x4a')],'raw':!![]}),_0x2c2b82[_0xd9b580('0xa6')]({'model':db[_0xd9b580('0xcb')],'as':_0xd9b580('0x6a'),'attributes':['id',_0xd9b580('0xd9'),_0xd9b580('0x41')],'raw':!![]});_0x3b80d1[_0xd9b580('0xee')][_0xd9b580('0x4e')]&&_0x2c2b82[_0xd9b580('0xa6')]({'model':db[_0xd9b580('0x10d')],'as':_0xd9b580('0x10d'),'raw':!![]});const _0x31f6e5=[{'model':db[_0xd9b580('0x46')],'as':_0xd9b580('0x48'),'attributes':['id',_0xd9b580('0x118'),'createdAt','direction',_0xd9b580('0x102'),_0xd9b580('0xd8')],'include':_0x2c2b82}];return _0x31f6e5[_0xd9b580('0xa6')]({'model':db[_0xd9b580('0x1c')],'as':_0xd9b580('0xe1'),'attributes':['id',_0xd9b580('0x3d')]}),_0x31f6e5[_0xd9b580('0xa6')]({'model':db['User'],'as':'Owner','attributes':['id',_0xd9b580('0x4a')]}),db['ChatInteraction']['findOne']({'where':{'id':_0x3b80d1[_0xd9b580('0x18')]['id']},'include':_0x31f6e5})[_0xd9b580('0x11b')](handleEntityNotFound(_0x509e3b,null))['then'](function(_0x509c23){const _0x41e9d9=_0xd9b580;if(_0x509c23){const _0x46a389=_0x509c23[_0x41e9d9('0xa')]({'plain':!![]});fs['mkdirSync'](_0x6698f7);const _0x303794={'format':'A4','border':_0x41e9d9('0x8f'),'header':{'height':_0x41e9d9('0x11'),'contents':{'first':_0x41e9d9('0xc3')}},'footer':{'height':_0x41e9d9('0x2d'),'contents':{'default':util['format'](_0x41e9d9('0xce'),util[_0x41e9d9('0x2a')]('%s\x20#%d',_0x41e9d9('0x32'),_0x46a389['id']),moment()[_0x41e9d9('0x2a')](_0x41e9d9('0x4c'))[_0x41e9d9('0x31')]())}}},_0x4fce17={'channel':_0x41e9d9('0x32'),'account':_0x46a389[_0x41e9d9('0xe1')][_0x41e9d9('0x3d')],'agent':_0x46a389[_0x41e9d9('0x1e')]?_0x46a389[_0x41e9d9('0x1e')][_0x41e9d9('0x4a')]:_0x41e9d9('0xc7'),'createdAt':moment(_0x46a389['createdAt'])[_0x41e9d9('0x2a')](_0x41e9d9('0xab'))[_0x41e9d9('0x31')](),'closedAt':_0x46a389[_0x41e9d9('0x2b')]?moment(_0x46a389[_0x41e9d9('0xd')])[_0x41e9d9('0x2a')](_0x41e9d9('0xab'))[_0x41e9d9('0x31')]():'','disposition':_0x46a389[_0x41e9d9('0xaa')],'chatInfo':{'browser':_0x46a389[_0x41e9d9('0x64')],'os':_0x46a389[_0x41e9d9('0x45')],'referer':_0x46a389[_0x41e9d9('0x26')],'customerIp':_0x46a389['customerIp'],'customerPort':_0x46a389[_0x41e9d9('0x10a')]?_0x46a389['customerPort']:_0x41e9d9('0xc7')},'messages':_(_0x46a389[_0x41e9d9('0x48')])[_0x41e9d9('0x10f')]()[_0x41e9d9('0x67')]({'secret':![]})['map'](function(_0x4521ef){const _0x5de6bb=_0x41e9d9;if(_0x4521ef['Attachment']){const _0x5e6eed=path[_0x5de6bb('0x54')](_0x361bc0,_0x4521ef['Attachment'][_0x5de6bb('0x20')]);fs[_0x5de6bb('0x83')](_0x5e6eed)&&fs[_0x5de6bb('0xf6')](_0x5e6eed)[_0x5de6bb('0x94')](fs[_0x5de6bb('0xe9')](path[_0x5de6bb('0x54')](_0x6698f7,_0x4521ef[_0x5de6bb('0x10d')][_0x5de6bb('0x20')])));}return{'date':moment(_0x4521ef[_0x5de6bb('0xdf')])[_0x5de6bb('0x2a')](_0x5de6bb('0xab'))['toString'](),'sender':_0x4521ef[_0x5de6bb('0x47')]==='out'?_0x4521ef[_0x5de6bb('0xc0')]?_0x4521ef[_0x5de6bb('0xc0')][_0x5de6bb('0x4a')]:'System':_0x4521ef[_0x5de6bb('0x6a')][_0x5de6bb('0xd9')]+(_0x4521ef[_0x5de6bb('0x6a')]['lastName']?'\x20'+_0x4521ef[_0x5de6bb('0x6a')][_0x5de6bb('0x41')]:''),'body':_0x4521ef[_0x5de6bb('0x10d')]?_0x4521ef[_0x5de6bb('0x10d')][_0x5de6bb('0x20')]:_0x4521ef[_0x5de6bb('0x118')],'direction':_0x4521ef['direction']==='out'?'A':'C','secret':_0x4521ef[_0x5de6bb('0x102')],'read':_0x4521ef['read'],'attachment':_0x4521ef['Attachment']};})[_0x41e9d9('0xec')]()};return ejs[_0x41e9d9('0x28')](path['join'](config[_0x41e9d9('0xf8')],_0x41e9d9('0xc'),_0x41e9d9('0x7f'),_0x41e9d9('0x7b')),{'interaction':_0x4fce17})[_0x41e9d9('0x11b')](function(_0x268c80){return new Promise(function(_0x3a4fe0,_0x15442f){const _0x5bfb88=a66_0x3a38;pdf[_0x5bfb88('0x66')](_0x268c80,_0x303794)['toFile'](path[_0x5bfb88('0x54')](_0x6698f7,'transcript-'+_0x46a389['id']+'-'+_0x29af10+_0x5bfb88('0x2c')),function(_0x2ed613,_0x196ed9){if(_0x2ed613)return _0x15442f(_0x2ed613);_0x3a4fe0(_0x196ed9);});});})[_0x41e9d9('0x11b')](function(){const _0x3f6f4c=_0x41e9d9;return new Promise(function(_0x5559bf,_0x5e76d1){zipdir(_0x6698f7,{'saveTo':_0x245a34},function(_0x5485b4,_0x5940b3){if(_0x5485b4)return _0x5e76d1(_0x5485b4);return _0x5559bf(_0x5940b3);});})[_0x3f6f4c('0x11b')](function(){return new Promise(function(_0x5182c2,_0x4a84ef){rimraf(_0x6698f7,function(_0x1f4799){if(_0x1f4799)_0x4a84ef(_0x1f4799);return _0x5182c2();});});})['then'](function(){const _0x393491=_0x3f6f4c;return _0x509e3b[_0x393491('0x113')](_0x245a34,_0x54dc18,function(_0x3f19c3){const _0x1457a7=_0x393491;_0x3f19c3?console['log'](_0x1457a7('0x116'),_0x3f19c3):fs[_0x1457a7('0x100')](_0x245a34);});});});}else return _0x509e3b[_0x41e9d9('0x92')](0xc8);})[_0xd9b580('0x7e')](handleError(_0x509e3b,null));}; \ No newline at end of file diff --git a/server/api/chatInteraction/chatInteraction.events.js b/server/api/chatInteraction/chatInteraction.events.js index 7020414..955284e 100644 --- a/server/api/chatInteraction/chatInteraction.events.js +++ b/server/api/chatInteraction/chatInteraction.events.js @@ -1 +1 @@ -const a67_0x1c29=['setDataValue','then','length','addHook','events','exports','remove','emit','catch','Users','getUsers','update','findAll','setMaxListeners','ChatInteraction','ChatMessage','unreadMessages','save'];(function(_0x42149a,_0x1c291b){const _0x2182bf=function(_0x5387de){while(--_0x5387de){_0x42149a['push'](_0x42149a['shift']());}};_0x2182bf(++_0x1c291b);}(a67_0x1c29,0xec));const a67_0x2182=function(_0x42149a,_0x1c291b){_0x42149a=_0x42149a-0x0;let _0x2182bf=a67_0x1c29[_0x42149a];return _0x2182bf;};const _0x1deeae=a67_0x2182;'use strict';const EventEmitter=require(_0x1deeae('0x2')),ChatInteraction=require('../../mysqldb')['db'][_0x1deeae('0xc')],ChatMessage=require('../../mysqldb')['db'][_0x1deeae('0xd')],ChatInteractionEvents=new EventEmitter();ChatInteractionEvents[_0x1deeae('0xb')](0x0);const events={'afterCreate':_0x1deeae('0xf'),'afterUpdate':_0x1deeae('0x9'),'afterDestroy':_0x1deeae('0x4')};function emitEvent(_0x5387de){return function(_0x55bdfd){const _0x382762=a67_0x2182;_0x55bdfd[_0x382762('0x8')]({'attributes':['id'],'raw':!![]})[_0x382762('0x11')](function(_0x38f9d7){const _0x136fb9=_0x382762;return _0x55bdfd[_0x136fb9('0x10')](_0x136fb9('0x7'),_0x38f9d7['map'](function(_0x496921){return{'id':_0x496921['id']};})),ChatMessage[_0x136fb9('0xa')]({'where':{'ChatInteractionId':_0x55bdfd['id'],'direction':'in','read':![]},'raw':!![]});})[_0x382762('0x11')](function(_0x3bafd4){const _0x20a22b=_0x382762;_0x55bdfd[_0x20a22b('0x10')](_0x20a22b('0xe'),_0x3bafd4[_0x20a22b('0x0')]),ChatInteractionEvents[_0x20a22b('0x5')](_0x5387de+':'+_0x55bdfd['id'],_0x55bdfd),ChatInteractionEvents['emit'](_0x5387de,_0x55bdfd);})[_0x382762('0x6')](()=>{});};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];ChatInteraction[_0x1deeae('0x1')](e,emitEvent(event));}}module[_0x1deeae('0x3')]=ChatInteractionEvents; \ No newline at end of file +const a67_0x28be=['setDataValue','events','../../mysqldb','findAll','catch','exports','remove','update','setMaxListeners','undefined','Users','then','length','save','emit','unreadMessages','map','ChatMessage'];(function(_0x40914b,_0x28be34){const _0x48dfd0=function(_0x281855){while(--_0x281855){_0x40914b['push'](_0x40914b['shift']());}};_0x48dfd0(++_0x28be34);}(a67_0x28be,0x19f));const a67_0x48df=function(_0x40914b,_0x28be34){_0x40914b=_0x40914b-0x0;let _0x48dfd0=a67_0x28be[_0x40914b];return _0x48dfd0;};const _0x226d59=a67_0x48df;'use strict';const EventEmitter=require(_0x226d59('0x0')),ChatInteraction=require(_0x226d59('0x1'))['db']['ChatInteraction'],ChatMessage=require('../../mysqldb')['db'][_0x226d59('0x10')],ChatInteractionEvents=new EventEmitter();ChatInteractionEvents[_0x226d59('0x7')](0x0);const events={'afterCreate':_0x226d59('0xc'),'afterUpdate':_0x226d59('0x6'),'afterDestroy':_0x226d59('0x5')};function emitEvent(_0x281855){return function(_0x5e0f2b){const _0x3f0e9e=a67_0x48df;_0x5e0f2b['getUsers']({'attributes':['id'],'raw':!![]})[_0x3f0e9e('0xa')](function(_0x14337d){const _0x134043=_0x3f0e9e;return _0x5e0f2b[_0x134043('0x11')](_0x134043('0x9'),_0x14337d[_0x134043('0xf')](function(_0x5ead2e){return{'id':_0x5ead2e['id']};})),ChatMessage[_0x134043('0x2')]({'where':{'ChatInteractionId':_0x5e0f2b['id'],'direction':'in','read':![]},'raw':!![]});})[_0x3f0e9e('0xa')](function(_0x5a4cc0){const _0x143c72=_0x3f0e9e;_0x5e0f2b['setDataValue'](_0x143c72('0xe'),_0x5a4cc0[_0x143c72('0xb')]),ChatInteractionEvents[_0x143c72('0xd')](_0x281855+':'+_0x5e0f2b['id'],_0x5e0f2b),ChatInteractionEvents[_0x143c72('0xd')](_0x281855,_0x5e0f2b);})[_0x3f0e9e('0x3')](()=>{});};}for(const e in events){if(typeof events[e]!==_0x226d59('0x8')){const event=events[e];ChatInteraction['addHook'](e,emitEvent(event));}}module[_0x226d59('0x4')]=ChatInteractionEvents; \ No newline at end of file diff --git a/server/api/chatInteraction/chatInteraction.model.js b/server/api/chatInteraction/chatInteraction.model.js index 6e8ecb6..54d6ae2 100644 --- a/server/api/chatInteraction/chatInteraction.model.js +++ b/server/api/chatInteraction/chatInteraction.model.js @@ -1 +1 @@ -const a68_0x3074=['utf8mb4_unicode_ci','changed','ChatInteraction','utf8mb4','chat_interactions','YYYY-MM-DD\x20HH:mm:ss','closed','closedAt','exports'];(function(_0xd3f8c6,_0x307468){const _0x545704=function(_0x2e894b){while(--_0x2e894b){_0xd3f8c6['push'](_0xd3f8c6['shift']());}};_0x545704(++_0x307468);}(a68_0x3074,0x9f));const a68_0x5457=function(_0xd3f8c6,_0x307468){_0xd3f8c6=_0xd3f8c6-0x0;let _0x545704=a68_0x3074[_0xd3f8c6];return _0x545704;};const _0x4ed1c9=a68_0x5457;'use strict';const moment=require('moment'),attributes=require('./chatInteraction.attributes');module[_0x4ed1c9('0x2')]=function(_0x2e894b){const _0x5247eb=_0x4ed1c9,_0x549ecc=_0x2e894b['define'](_0x5247eb('0x5'),attributes,{'tableName':_0x5247eb('0x7'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x10b35f){const _0x4dd4a3=_0x5247eb;_0x10b35f[_0x4dd4a3('0x4')](_0x4dd4a3('0x0'))&&(_0x10b35f[_0x4dd4a3('0x1')]=moment()['format'](_0x4dd4a3('0x8')));}},'charset':_0x5247eb('0x6'),'collate':_0x5247eb('0x3')});return _0x549ecc;}; \ No newline at end of file +const a68_0x26f6=['ChatInteraction','closed','./chatInteraction.attributes','utf8mb4','define','YYYY-MM-DD\x20HH:mm:ss','moment','closedAt','exports','chat_interactions'];(function(_0x2f458b,_0x26f624){const _0x2ae5a5=function(_0x41aca9){while(--_0x41aca9){_0x2f458b['push'](_0x2f458b['shift']());}};_0x2ae5a5(++_0x26f624);}(a68_0x26f6,0x155));const a68_0x2ae5=function(_0x2f458b,_0x26f624){_0x2f458b=_0x2f458b-0x0;let _0x2ae5a5=a68_0x26f6[_0x2f458b];return _0x2ae5a5;};const _0x1ff7d9=a68_0x2ae5;'use strict';const moment=require(_0x1ff7d9('0x5')),attributes=require(_0x1ff7d9('0x1'));module[_0x1ff7d9('0x7')]=function(_0x41aca9){const _0x2ad6ec=_0x1ff7d9,_0x2a4b94=_0x41aca9[_0x2ad6ec('0x3')](_0x2ad6ec('0x9'),attributes,{'tableName':_0x2ad6ec('0x8'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x14e061){const _0xdaf728=_0x2ad6ec;_0x14e061['changed'](_0xdaf728('0x0'))&&(_0x14e061[_0xdaf728('0x6')]=moment()['format'](_0xdaf728('0x4')));}},'charset':_0x2ad6ec('0x2'),'collate':'utf8mb4_unicode_ci'});return _0x2a4b94;}; \ No newline at end of file diff --git a/server/api/chatInteraction/chatInteraction.rpc.js b/server/api/chatInteraction/chatInteraction.rpc.js index 1f89907..e8ae44b 100644 --- a/server/api/chatInteraction/chatInteraction.rpc.js +++ b/server/api/chatInteraction/chatInteraction.rpc.js @@ -1 +1 @@ -const a69_0x2a91=['../../mysqldb','stringify','limit','body','info','error','then','where','addTags','UpdateChatInteraction','findOne','AddTagsToChatInteraction','./chatInteraction.socket','attributes','ChatInteraction','raw','debug','options','catch','AddTags','../../config/logger','lodash','../../rediscache','ids'];(function(_0x4580c8,_0x2a91b3){const _0x38f2f1=function(_0x182cf7){while(--_0x182cf7){_0x4580c8['push'](_0x4580c8['shift']());}};_0x38f2f1(++_0x2a91b3);}(a69_0x2a91,0xf1));const a69_0x38f2=function(_0x4580c8,_0x2a91b3){_0x4580c8=_0x4580c8-0x0;let _0x38f2f1=a69_0x2a91[_0x4580c8];return _0x38f2f1;};const _0x1ff892=a69_0x38f2;'use strict';const _=require(_0x1ff892('0x14')),db=require(_0x1ff892('0x17'))['db'],logger=require(_0x1ff892('0x13'))('rpc'),{getSocket}=require(_0x1ff892('0x15')),socket=getSocket();require(_0x1ff892('0xb'))['register'](socket),exports[_0x1ff892('0x8')]=function(_0x182cf7){const _0x5816d8=this;return new Promise(function(_0x2c5450,_0x5b1a30){const _0x16277c=a69_0x38f2;return db[_0x16277c('0xd')]['update'](_0x182cf7[_0x16277c('0x2')],{'raw':_0x182cf7['options']?_0x182cf7[_0x16277c('0x10')][_0x16277c('0xe')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x182cf7[_0x16277c('0x10')]?_0x182cf7[_0x16277c('0x10')][_0x16277c('0x6')]||null:null,'attributes':_0x182cf7[_0x16277c('0x10')]?_0x182cf7[_0x16277c('0x10')][_0x16277c('0xc')]||null:null,'limit':_0x182cf7[_0x16277c('0x10')]?_0x182cf7['options'][_0x16277c('0x1')]||null:null})[_0x16277c('0x5')](function(_0x13c661){const _0x727eb4=_0x16277c;logger[_0x727eb4('0x3')](_0x727eb4('0x8'),_0x182cf7),logger['debug'](_0x727eb4('0x8'),_0x182cf7,JSON['stringify'](_0x13c661)),_0x2c5450(_0x13c661);})['catch'](function(_0x1e970a){const _0x56a7f5=_0x16277c;logger[_0x56a7f5('0x4')](_0x56a7f5('0x8'),_0x1e970a['message'],_0x182cf7),_0x5b1a30(_0x5816d8[_0x56a7f5('0x4')](0x1f4,_0x1e970a['message']));});});},exports[_0x1ff892('0xa')]=function(_0x1add0a){const _0x3e4a12=this;return new Promise(function(_0x4e9c55,_0x5a593c){const _0x3be56b=a69_0x38f2;return db[_0x3be56b('0xd')][_0x3be56b('0x9')]({'where':_0x1add0a['options']?_0x1add0a[_0x3be56b('0x10')][_0x3be56b('0x6')]||null:null})[_0x3be56b('0x5')](function(_0x1cdac2){const _0x57b6a4=_0x3be56b;if(_0x1cdac2)return _0x1cdac2[_0x57b6a4('0x7')](_0x1add0a[_0x57b6a4('0x2')][_0x57b6a4('0x16')],{'through':_['omit'](_0x1add0a['body'],['ids','id'])});})[_0x3be56b('0x5')](function([_0x4cbec5]){const _0x4b613a=_0x3be56b;logger[_0x4b613a('0x3')](_0x4b613a('0x12'),_0x1add0a),logger[_0x4b613a('0xf')](_0x4b613a('0x12'),_0x1add0a,JSON[_0x4b613a('0x0')](_0x4cbec5)),_0x4e9c55(_0x4cbec5);})[_0x3be56b('0x11')](function(_0x59a11f){const _0x9732c=_0x3be56b;logger[_0x9732c('0x4')]('AddTags',_0x59a11f['message'],_0x1add0a),_0x5a593c(_0x3e4a12['error'](0x1f4,_0x59a11f['message']));});});}; \ No newline at end of file +const a69_0x18f7=['addTags','../../rediscache','message','lodash','ids','AddTagsToChatInteraction','AddTags','findOne','body','ChatInteraction','./chatInteraction.socket','debug','attributes','UpdateChatInteraction','stringify','where','catch','limit','error','update','raw','then','register','options','rpc'];(function(_0x5c9c22,_0x18f7a7){const _0xe2d24=function(_0x36c4b5){while(--_0x36c4b5){_0x5c9c22['push'](_0x5c9c22['shift']());}};_0xe2d24(++_0x18f7a7);}(a69_0x18f7,0x6b));const a69_0xe2d2=function(_0x5c9c22,_0x18f7a7){_0x5c9c22=_0x5c9c22-0x0;let _0xe2d24=a69_0x18f7[_0x5c9c22];return _0xe2d24;};const _0x3f0a19=a69_0xe2d2;'use strict';const _=require(_0x3f0a19('0x15')),db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x3f0a19('0x11')),{getSocket}=require(_0x3f0a19('0x13')),socket=getSocket();require(_0x3f0a19('0x3'))[_0x3f0a19('0xf')](socket),exports['UpdateChatInteraction']=function(_0x36c4b5){const _0xa45e7c=this;return new Promise(function(_0x380e10,_0x49ee33){const _0x1c33f6=a69_0xe2d2;return db[_0x1c33f6('0x2')][_0x1c33f6('0xc')](_0x36c4b5[_0x1c33f6('0x1')],{'raw':_0x36c4b5[_0x1c33f6('0x10')]?_0x36c4b5[_0x1c33f6('0x10')][_0x1c33f6('0xd')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x36c4b5[_0x1c33f6('0x10')]?_0x36c4b5[_0x1c33f6('0x10')][_0x1c33f6('0x8')]||null:null,'attributes':_0x36c4b5[_0x1c33f6('0x10')]?_0x36c4b5[_0x1c33f6('0x10')][_0x1c33f6('0x5')]||null:null,'limit':_0x36c4b5[_0x1c33f6('0x10')]?_0x36c4b5[_0x1c33f6('0x10')][_0x1c33f6('0xa')]||null:null})[_0x1c33f6('0xe')](function(_0x1edb5a){const _0x38ced7=_0x1c33f6;logger['info'](_0x38ced7('0x6'),_0x36c4b5),logger['debug']('UpdateChatInteraction',_0x36c4b5,JSON[_0x38ced7('0x7')](_0x1edb5a)),_0x380e10(_0x1edb5a);})[_0x1c33f6('0x9')](function(_0x3154cd){const _0x30a6ea=_0x1c33f6;logger['error']('UpdateChatInteraction',_0x3154cd['message'],_0x36c4b5),_0x49ee33(_0xa45e7c[_0x30a6ea('0xb')](0x1f4,_0x3154cd[_0x30a6ea('0x14')]));});});},exports[_0x3f0a19('0x17')]=function(_0x385d42){const _0x5610f4=this;return new Promise(function(_0x59734d,_0x337be1){const _0x3e021f=a69_0xe2d2;return db['ChatInteraction'][_0x3e021f('0x0')]({'where':_0x385d42['options']?_0x385d42['options'][_0x3e021f('0x8')]||null:null})[_0x3e021f('0xe')](function(_0x5038a2){const _0x26dade=_0x3e021f;if(_0x5038a2)return _0x5038a2[_0x26dade('0x12')](_0x385d42[_0x26dade('0x1')][_0x26dade('0x16')],{'through':_['omit'](_0x385d42['body'],['ids','id'])});})[_0x3e021f('0xe')](function([_0x3cc2b1]){const _0x5ebfee=_0x3e021f;logger['info'](_0x5ebfee('0x18'),_0x385d42),logger[_0x5ebfee('0x4')](_0x5ebfee('0x18'),_0x385d42,JSON['stringify'](_0x3cc2b1)),_0x59734d(_0x3cc2b1);})[_0x3e021f('0x9')](function(_0x4609ca){const _0x2e6ea3=_0x3e021f;logger[_0x2e6ea3('0xb')](_0x2e6ea3('0x18'),_0x4609ca[_0x2e6ea3('0x14')],_0x385d42),_0x337be1(_0x5610f4['error'](0x1f4,_0x4609ca['message']));});});}; \ No newline at end of file diff --git a/server/api/chatInteraction/chatInteraction.socket.js b/server/api/chatInteraction/chatInteraction.socket.js index 9ceca26..3fc414e 100644 --- a/server/api/chatInteraction/chatInteraction.socket.js +++ b/server/api/chatInteraction/chatInteraction.socket.js @@ -1 +1 @@ -const a70_0x2bb2=['./chatInteraction.events','length','chatInteraction:','register','emit','update','remove','save'];(function(_0x55298d,_0x2bb2d3){const _0x4c1b13=function(_0x108619){while(--_0x108619){_0x55298d['push'](_0x55298d['shift']());}};_0x4c1b13(++_0x2bb2d3);}(a70_0x2bb2,0x12a));const a70_0x4c1b=function(_0x55298d,_0x2bb2d3){_0x55298d=_0x55298d-0x0;let _0x4c1b13=a70_0x2bb2[_0x55298d];return _0x4c1b13;};const _0x580c01=a70_0x4c1b;'use strict';const ChatInteractionEvents=require(_0x580c01('0x6')),events=[_0x580c01('0x5'),_0x580c01('0x4'),_0x580c01('0x3')];function createListener(_0x108619,_0x3be88d){return function(_0x42e8e4){const _0x6aeb5d=a70_0x4c1b;_0x3be88d[_0x6aeb5d('0x2')](_0x108619,_0x42e8e4);};}exports[_0x580c01('0x1')]=function(_0x486b3f){const _0x37d2f0=_0x580c01;for(let _0x2898ee=0x0,_0x1fb370=events[_0x37d2f0('0x7')];_0x2898ee<_0x1fb370;_0x2898ee++){const _0x430992=events[_0x2898ee],_0x2a5384=createListener(_0x37d2f0('0x0')+_0x430992,_0x486b3f);ChatInteractionEvents['on'](_0x430992,_0x2a5384);}}; \ No newline at end of file +const a70_0x255c=['chatInteraction:','remove','save','length','emit','register','update'];(function(_0x2e40cb,_0x255ccb){const _0x453ece=function(_0x4d078a){while(--_0x4d078a){_0x2e40cb['push'](_0x2e40cb['shift']());}};_0x453ece(++_0x255ccb);}(a70_0x255c,0x1d7));const a70_0x453e=function(_0x2e40cb,_0x255ccb){_0x2e40cb=_0x2e40cb-0x0;let _0x453ece=a70_0x255c[_0x2e40cb];return _0x453ece;};const _0x1fa623=a70_0x453e;'use strict';const ChatInteractionEvents=require('./chatInteraction.events'),events=[_0x1fa623('0x0'),_0x1fa623('0x6'),_0x1fa623('0x4')];function createListener(_0x4d078a,_0x4f1954){return function(_0x1df7c2){const _0x39b089=a70_0x453e;_0x4f1954[_0x39b089('0x2')](_0x4d078a,_0x1df7c2);};}exports[_0x1fa623('0x3')]=function(_0x26c0e5){const _0x27bb3e=_0x1fa623;for(let _0x1f16c0=0x0,_0x97478=events[_0x27bb3e('0x1')];_0x1f16c0<_0x97478;_0x1f16c0++){const _0x22da1f=events[_0x1f16c0],_0x2d6d3d=createListener(_0x27bb3e('0x5')+_0x22da1f,_0x26c0e5);ChatInteractionEvents['on'](_0x22da1f,_0x2d6d3d);}}; \ No newline at end of file diff --git a/server/api/chatInteraction/index.js b/server/api/chatInteraction/index.js index 000a77b..935e444 100644 --- a/server/api/chatInteraction/index.js +++ b/server/api/chatInteraction/index.js @@ -1 +1 @@ -const a71_0x2ac7=['/:id/vidaoo','../../config/environment','diskStorage','multer','replace','show','%s-%s','/:id/messages','util','file','/:id/attachment_download','/:id/attachment_upload','index','isAuthenticated','getMyMessages','update','join','abandon','customUpdate','/:id/custom_update','/:id/tags','post','chatinteraction:addtags','put','exports','get','removeTags','../../components/auth/service','/:id/my_messages','root','close','attachmentDownload','originalname','/:id/abandon','./chatInteraction.controller','getMessages','express','/:id','addTags','files/attachments/','isChatInteractionAuthorized','/:id/download','delete','chat','chatinteraction:destroy'];(function(_0x291224,_0x2ac709){const _0x4ec03c=function(_0x43d4ce){while(--_0x43d4ce){_0x291224['push'](_0x291224['shift']());}};_0x4ec03c(++_0x2ac709);}(a71_0x2ac7,0x11e));const a71_0x4ec0=function(_0x291224,_0x2ac709){_0x291224=_0x291224-0x0;let _0x4ec03c=a71_0x2ac7[_0x291224];return _0x4ec03c;};const _0x1451ff=a71_0x4ec0;'use strict';const multer=require(_0x1451ff('0x20')),util=require(_0x1451ff('0x25')),path=require('path'),express=require(_0x1451ff('0x14')),router=express['Router'](),auth=require(_0x1451ff('0xb')),interaction=require('../../components/interaction/service'),config=require(_0x1451ff('0x1e')),controller=require(_0x1451ff('0x12'));router[_0x1451ff('0x9')]('/',auth[_0x1451ff('0x2a')](),controller[_0x1451ff('0x29')]),router[_0x1451ff('0x9')]('/describe',auth[_0x1451ff('0x2a')](),controller['describe']),router[_0x1451ff('0x9')](_0x1451ff('0x15'),auth[_0x1451ff('0x18')](),controller[_0x1451ff('0x22')]),router['get'](_0x1451ff('0x27'),auth[_0x1451ff('0x18')](),controller[_0x1451ff('0xf')]),router[_0x1451ff('0x9')](_0x1451ff('0x24'),auth[_0x1451ff('0x2a')](),controller[_0x1451ff('0x13')]),router['get'](_0x1451ff('0xc'),auth[_0x1451ff('0x18')](),controller[_0x1451ff('0x2b')]),router['get'](_0x1451ff('0x19'),auth['isAuthenticated'](),controller['download']),router[_0x1451ff('0x5')]('/',auth['isAuthenticated'](),controller['create']),router[_0x1451ff('0x5')](_0x1451ff('0x1d'),auth[_0x1451ff('0x2a')](),controller['createVidaooSession']);const upload=multer({'storage':multer[_0x1451ff('0x1f')]({'destination':function(_0x43d4ce,_0x112eb4,_0x24aaa8){const _0x2420df=_0x1451ff;_0x24aaa8(null,path[_0x2420df('0x0')](config[_0x2420df('0xd')],_0x2420df('0x17')));},'filename':function(_0xc1749,_0xc1dd70,_0x14ce48){const _0x534661=_0x1451ff;_0x14ce48(null,util['format'](_0x534661('0x23'),Date['now'](),_0xc1dd70[_0x534661('0x10')][_0x534661('0x21')](/[+@&/\\#,+()$~%'":*?<>{}\s\\|]/g,'-')));}})});router[_0x1451ff('0x5')](_0x1451ff('0x28'),upload['single'](_0x1451ff('0x26')),controller['attachmentUpload']),router['post'](_0x1451ff('0x24'),auth['isChatInteractionAuthorized'](),controller['addMessage']),router[_0x1451ff('0x5')]('/:id/tags',auth['isAuthenticated'](),interaction['tracked'](_0x1451ff('0x1b'),_0x1451ff('0x6')),controller[_0x1451ff('0x16')]),router[_0x1451ff('0x7')](_0x1451ff('0x15'),auth[_0x1451ff('0x2a')](),interaction['tracked'](_0x1451ff('0x1b'),'chatinteraction:update'),controller[_0x1451ff('0x2c')]),router[_0x1451ff('0x7')](_0x1451ff('0x3'),controller[_0x1451ff('0x2')]),router[_0x1451ff('0x7')](_0x1451ff('0x11'),auth[_0x1451ff('0x18')](),controller[_0x1451ff('0x1')]),router[_0x1451ff('0x7')]('/:id/close',controller[_0x1451ff('0xe')]),router[_0x1451ff('0x1a')]('/:id',auth[_0x1451ff('0x2a')](),interaction['tracked'](_0x1451ff('0x1b'),_0x1451ff('0x1c')),controller['destroy']),router[_0x1451ff('0x1a')](_0x1451ff('0x4'),auth[_0x1451ff('0x2a')](),controller[_0x1451ff('0xa')]),module[_0x1451ff('0x8')]=router; \ No newline at end of file +const a71_0x2cd6=['chat','close','tracked','isAuthenticated','customUpdate','chatinteraction:addtags','/:id/my_messages','file','root','chatinteraction:update','isChatInteractionAuthorized','createVidaooSession','abandon','removeTags','show','post','files/attachments/','/:id/close','attachmentDownload','/:id','/:id/attachment_download','get','join','/:id/abandon','exports','/:id/vidaoo','../../config/environment','getMessages','express','addTags','describe','/:id/messages','/:id/download','index','delete','/:id/tags','addMessage','getMyMessages','put','/describe','now','./chatInteraction.controller','update','chatinteraction:destroy','util','../../components/interaction/service','diskStorage','attachmentUpload','../../components/auth/service','format'];(function(_0xf924d5,_0x2cd643){const _0x39db5e=function(_0x3329e3){while(--_0x3329e3){_0xf924d5['push'](_0xf924d5['shift']());}};_0x39db5e(++_0x2cd643);}(a71_0x2cd6,0x78));const a71_0x39db=function(_0xf924d5,_0x2cd643){_0xf924d5=_0xf924d5-0x0;let _0x39db5e=a71_0x2cd6[_0xf924d5];return _0x39db5e;};const _0x1f53a9=a71_0x39db;'use strict';const multer=require('multer'),util=require(_0x1f53a9('0x18')),path=require('path'),express=require(_0x1f53a9('0x8')),router=express['Router'](),auth=require(_0x1f53a9('0x1c')),interaction=require(_0x1f53a9('0x19')),config=require(_0x1f53a9('0x6')),controller=require(_0x1f53a9('0x15'));router[_0x1f53a9('0x1')]('/',auth['isAuthenticated'](),controller[_0x1f53a9('0xd')]),router[_0x1f53a9('0x1')](_0x1f53a9('0x13'),auth[_0x1f53a9('0x21')](),controller[_0x1f53a9('0xa')]),router[_0x1f53a9('0x1')](_0x1f53a9('0x31'),auth[_0x1f53a9('0x28')](),controller[_0x1f53a9('0x2c')]),router[_0x1f53a9('0x1')](_0x1f53a9('0x0'),auth[_0x1f53a9('0x28')](),controller[_0x1f53a9('0x30')]),router['get']('/:id/messages',auth[_0x1f53a9('0x21')](),controller[_0x1f53a9('0x7')]),router[_0x1f53a9('0x1')](_0x1f53a9('0x24'),auth[_0x1f53a9('0x28')](),controller[_0x1f53a9('0x11')]),router[_0x1f53a9('0x1')](_0x1f53a9('0xc'),auth[_0x1f53a9('0x21')](),controller['download']),router[_0x1f53a9('0x2d')]('/',auth['isAuthenticated'](),controller['create']),router[_0x1f53a9('0x2d')](_0x1f53a9('0x5'),auth['isAuthenticated'](),controller[_0x1f53a9('0x29')]);const upload=multer({'storage':multer[_0x1f53a9('0x1a')]({'destination':function(_0x3329e3,_0x142f76,_0x480224){const _0x4156c6=_0x1f53a9;_0x480224(null,path[_0x4156c6('0x2')](config[_0x4156c6('0x26')],_0x4156c6('0x2e')));},'filename':function(_0xe71a5e,_0x187f7d,_0x4075bf){const _0x244fb7=_0x1f53a9;_0x4075bf(null,util[_0x244fb7('0x1d')]('%s-%s',Date[_0x244fb7('0x14')](),_0x187f7d['originalname']['replace'](/[+@&/\\#,+()$~%'":*?<>{}\s\\|]/g,'-')));}})});router[_0x1f53a9('0x2d')]('/:id/attachment_upload',upload['single'](_0x1f53a9('0x25')),controller[_0x1f53a9('0x1b')]),router[_0x1f53a9('0x2d')](_0x1f53a9('0xb'),auth[_0x1f53a9('0x28')](),controller[_0x1f53a9('0x10')]),router[_0x1f53a9('0x2d')](_0x1f53a9('0xf'),auth[_0x1f53a9('0x21')](),interaction[_0x1f53a9('0x20')](_0x1f53a9('0x1e'),_0x1f53a9('0x23')),controller[_0x1f53a9('0x9')]),router[_0x1f53a9('0x12')](_0x1f53a9('0x31'),auth[_0x1f53a9('0x21')](),interaction['tracked'](_0x1f53a9('0x1e'),_0x1f53a9('0x27')),controller[_0x1f53a9('0x16')]),router[_0x1f53a9('0x12')]('/:id/custom_update',controller[_0x1f53a9('0x22')]),router['put'](_0x1f53a9('0x3'),auth['isChatInteractionAuthorized'](),controller[_0x1f53a9('0x2a')]),router['put'](_0x1f53a9('0x2f'),controller[_0x1f53a9('0x1f')]),router[_0x1f53a9('0xe')](_0x1f53a9('0x31'),auth['isAuthenticated'](),interaction['tracked'](_0x1f53a9('0x1e'),_0x1f53a9('0x17')),controller['destroy']),router['delete'](_0x1f53a9('0xf'),auth[_0x1f53a9('0x21')](),controller[_0x1f53a9('0x2b')]),module[_0x1f53a9('0x4')]=router; \ No newline at end of file diff --git a/server/api/chatInternalMessage/chatInternalMessage.attributes.js b/server/api/chatInternalMessage/chatInternalMessage.attributes.js index ae385d1..8bc886d 100644 --- a/server/api/chatInternalMessage/chatInternalMessage.attributes.js +++ b/server/api/chatInternalMessage/chatInternalMessage.attributes.js @@ -1 +1 @@ -const a72_0x63ce=['BOOLEAN','sequelize','exports','INTEGER','TEXT','medium'];(function(_0x658950,_0x63ce27){const _0x5786c2=function(_0x44d304){while(--_0x44d304){_0x658950['push'](_0x658950['shift']());}};_0x5786c2(++_0x63ce27);}(a72_0x63ce,0xf9));const a72_0x5786=function(_0x658950,_0x63ce27){_0x658950=_0x658950-0x0;let _0x5786c2=a72_0x63ce[_0x658950];return _0x5786c2;};const _0x3a1ea8=a72_0x5786;'use strict';const Sequelize=require(_0x3a1ea8('0x4'));module[_0x3a1ea8('0x5')]={'body':{'type':Sequelize[_0x3a1ea8('0x1')](_0x3a1ea8('0x2')),'allowNull':![]},'read':{'type':Sequelize[_0x3a1ea8('0x3')],'defaultValue':![]},'ChatInternalMessageId':{'type':Sequelize[_0x3a1ea8('0x0')]}}; \ No newline at end of file +const a72_0x12c5=['TEXT','medium','exports','INTEGER','BOOLEAN'];(function(_0x2d286d,_0x12c525){const _0xa86e94=function(_0x51eed5){while(--_0x51eed5){_0x2d286d['push'](_0x2d286d['shift']());}};_0xa86e94(++_0x12c525);}(a72_0x12c5,0x170));const a72_0xa86e=function(_0x2d286d,_0x12c525){_0x2d286d=_0x2d286d-0x0;let _0xa86e94=a72_0x12c5[_0x2d286d];return _0xa86e94;};const _0x4b3e04=a72_0xa86e;'use strict';const Sequelize=require('sequelize');module[_0x4b3e04('0x4')]={'body':{'type':Sequelize[_0x4b3e04('0x2')](_0x4b3e04('0x3')),'allowNull':![]},'read':{'type':Sequelize[_0x4b3e04('0x1')],'defaultValue':![]},'ChatInternalMessageId':{'type':Sequelize[_0x4b3e04('0x0')]}}; \ No newline at end of file diff --git a/server/api/chatInternalMessage/chatInternalMessage.controller.js b/server/api/chatInternalMessage/chatInternalMessage.controller.js index 4e7286c..4d93711 100644 --- a/server/api/chatInternalMessage/chatInternalMessage.controller.js +++ b/server/api/chatInternalMessage/chatInternalMessage.controller.js @@ -1 +1 @@ -const a73_0x1747=['create','send','format','Agents','intersection','options','lastMessageAt','lastLoginAt','-createdAt','-online','length','../../rediscache','name','ToId','UserProfileSection','include','userpic','type','./chatInternalMessage.socket','lastMessage','nolimit','rawAttributes','stack','userProfileId','register','like','../../config/logger','undefined','isEmpty','getUsers','then','api','body','VoiceQueue','includeAll','describe','UserProfileResource','get','VIRTUAL','read','params','destroy','keys','showWebBar','attributes','all','fields','push','set','update','VoiceQueues','../../mysqldb','fieldName','sequelize','role','moment','ChatInternalMessage','User','offset','YYYY-MM-DD\x20HH:mm:ss','messages','user','admin','status','count','sort','map','internal','query','model','findOne','where','limit','agent','key','sendStatus','catch','json','order','filter','find','merge','findAll','filters'];(function(_0x589b2d,_0x174785){const _0x2bf535=function(_0x26776f){while(--_0x26776f){_0x589b2d['push'](_0x589b2d['shift']());}};_0x2bf535(++_0x174785);}(a73_0x1747,0x158));const a73_0x2bf5=function(_0x589b2d,_0x174785){_0x589b2d=_0x589b2d-0x0;let _0x2bf535=a73_0x1747[_0x589b2d];return _0x2bf535;};const _0x1e98e6=a73_0x2bf5;'use strict';const moment=require(_0x1e98e6('0x2f')),_=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x1e98e6('0x12'))(_0x1e98e6('0x17')),{getSocket}=require(_0x1e98e6('0x3')),db=require(_0x1e98e6('0x2b'))['db'],{Op}=require(_0x1e98e6('0x2d')),socket=getSocket();require(_0x1e98e6('0xa'))[_0x1e98e6('0x10')](socket);function respondWithResult(_0x26776f,_0x59eb14){return _0x59eb14=_0x59eb14||0xc8,function(_0x135259){const _0x5d7180=a73_0x2bf5;if(_0x135259)return _0x26776f[_0x5d7180('0x37')](_0x59eb14)['json'](_0x135259);};}function respondWithFilteredResult(_0x50df35,_0x92c089){return function(_0x2ebd80){const _0x55fe68=a73_0x2bf5;if(_0x2ebd80){const _0x339154=_0x2ebd80['count'],_0x157763=_0x92c089[_0x55fe68('0x32')];let _0x507c0a=_0x92c089[_0x55fe68('0x32')]+_0x92c089[_0x55fe68('0x40')],_0x6fff03;return _0x507c0a>=_0x339154?(_0x507c0a=_0x339154,_0x6fff03=0xc8):_0x6fff03=0xce,_0x50df35[_0x55fe68('0x37')](_0x6fff03),_0x50df35[_0x55fe68('0x28')]('Content-Range',_0x157763+'-'+_0x507c0a+'/'+_0x339154)[_0x55fe68('0x45')](_0x2ebd80);}return null;};}function saveUpdates(_0x4d04b7){return function(_0x3fa425){const _0xaa6966=a73_0x2bf5;if(_0x3fa425)return _0x3fa425[_0xaa6966('0x29')](_0x4d04b7)[_0xaa6966('0x16')](function(_0x251d2a){return _0x251d2a;});return null;};}function removeEntity(_0x4b451a){return function(_0x4c3626){const _0x1eb82e=a73_0x2bf5;if(_0x4c3626)return _0x4c3626[_0x1eb82e('0x21')]()[_0x1eb82e('0x16')](function(){const _0x41dc2d=_0x1eb82e;_0x4b451a[_0x41dc2d('0x37')](0xcc)['end']();});};}function handleEntityNotFound(_0x5c41e2){return function(_0x4acac8){const _0xf1526f=a73_0x2bf5;return!_0x4acac8&&_0x5c41e2[_0xf1526f('0x43')](0x194),_0x4acac8;};}function handleError(_0x4460b0,_0x50d292){return _0x50d292=_0x50d292||0x1f4,function(_0x4c7342){const _0x569a3d=a73_0x2bf5;logger['error'](_0x4c7342[_0x569a3d('0xe')]),_0x4c7342[_0x569a3d('0x4')]&&delete _0x4c7342[_0x569a3d('0x4')],_0x4460b0[_0x569a3d('0x37')](_0x50d292)[_0x569a3d('0x4d')](_0x4c7342);};}exports['index']=function(_0x2d1df6,_0x4057d5){const _0x28823c=_0x1e98e6;let _0x487dcd={};const _0x4303ee={},_0x49d135={'count':0x0,'rows':[]},_0x4d04ed=_[_0x28823c('0x3a')](db['ChatInternalMessage'][_0x28823c('0xd')],function(_0x521ce3){const _0x132288=_0x28823c;return{'name':_0x521ce3[_0x132288('0x2c')],'type':_0x521ce3[_0x132288('0x9')][_0x132288('0x42')]};});_0x4303ee[_0x28823c('0x3d')]=_[_0x28823c('0x3a')](_0x4d04ed,_0x28823c('0x4')),_0x4303ee[_0x28823c('0x3c')]=_[_0x28823c('0x22')](_0x2d1df6[_0x28823c('0x3c')]),_0x4303ee['filters']=_[_0x28823c('0x50')](_0x4303ee['model'],_0x4303ee[_0x28823c('0x3c')]),_0x487dcd[_0x28823c('0x24')]=_[_0x28823c('0x50')](_0x4303ee[_0x28823c('0x3d')],qs[_0x28823c('0x26')](_0x2d1df6[_0x28823c('0x3c')][_0x28823c('0x26')])),_0x487dcd[_0x28823c('0x24')]=_0x487dcd[_0x28823c('0x24')]['length']?_0x487dcd[_0x28823c('0x24')]:_0x4303ee['model'];typeof _0x2d1df6[_0x28823c('0x3c')][_0x28823c('0xc')]===_0x28823c('0x13')&&(_0x487dcd['limit']=qs['limit'](_0x2d1df6[_0x28823c('0x3c')][_0x28823c('0x40')]),_0x487dcd['offset']=qs[_0x28823c('0x32')](_0x2d1df6[_0x28823c('0x3c')][_0x28823c('0x32')]));_0x487dcd[_0x28823c('0x46')]=qs['sort'](_0x2d1df6[_0x28823c('0x3c')]['sort']),_0x487dcd[_0x28823c('0x3f')]=qs[_0x28823c('0x4b')](_['pick'](_0x2d1df6['query'],_0x4303ee['filters']),_0x4d04ed);_0x2d1df6[_0x28823c('0x3c')][_0x28823c('0x47')]&&(_0x487dcd[_0x28823c('0x3f')]=_[_0x28823c('0x49')](_0x487dcd[_0x28823c('0x3f')],{[Op['or']]:_[_0x28823c('0x3a')](_0x4d04ed,function(_0x1a00ac){const _0x396a66=_0x28823c;if(_0x1a00ac[_0x396a66('0x9')]!==_0x396a66('0x1e')){const _0x3ca15d={};return _0x3ca15d[_0x1a00ac[_0x396a66('0x4')]]={[Op[_0x396a66('0x11')]]:'%'+_0x2d1df6['query']['filter']+'%'},_0x3ca15d;}})}));_0x487dcd=_[_0x28823c('0x49')]({},_0x487dcd,_0x2d1df6[_0x28823c('0x51')]);const _0x1edfef={'where':_0x487dcd['where']};return db[_0x28823c('0x30')][_0x28823c('0x38')](_0x1edfef)[_0x28823c('0x16')](function(_0x54015b){const _0x3e8303=_0x28823c;return _0x49d135[_0x3e8303('0x38')]=_0x54015b,_0x2d1df6['query'][_0x3e8303('0x1a')]&&(_0x487dcd[_0x3e8303('0x7')]=[{'all':!![]}]),db['ChatInternalMessage'][_0x3e8303('0x4a')](_0x487dcd);})[_0x28823c('0x16')](function(_0x3ed498){return _0x49d135['rows']=_0x3ed498,_0x49d135;})['then'](respondWithFilteredResult(_0x4057d5,_0x487dcd))[_0x28823c('0x44')](handleError(_0x4057d5,null));},exports['show']=function(_0x2b149d,_0x16c1f9){const _0x1e640d=_0x1e98e6;let _0x15aa7a={'raw':!![],'where':{'id':_0x2b149d[_0x1e640d('0x20')]['id']}};const _0x22f74e={};return _0x22f74e['model']=_[_0x1e640d('0x22')](db[_0x1e640d('0x30')][_0x1e640d('0xd')]),_0x22f74e[_0x1e640d('0x3c')]=_['keys'](_0x2b149d[_0x1e640d('0x3c')]),_0x22f74e[_0x1e640d('0x4b')]=_['intersection'](_0x22f74e['model'],_0x22f74e[_0x1e640d('0x3c')]),_0x15aa7a[_0x1e640d('0x24')]=_[_0x1e640d('0x50')](_0x22f74e[_0x1e640d('0x3d')],qs[_0x1e640d('0x26')](_0x2b149d[_0x1e640d('0x3c')][_0x1e640d('0x26')])),_0x15aa7a['attributes']=_0x15aa7a['attributes'][_0x1e640d('0x2')]?_0x15aa7a[_0x1e640d('0x24')]:_0x22f74e[_0x1e640d('0x3d')],_0x2b149d[_0x1e640d('0x3c')][_0x1e640d('0x1a')]&&(_0x15aa7a[_0x1e640d('0x7')]=[{'all':!![]}]),_0x15aa7a=_['merge']({},_0x15aa7a,_0x2b149d[_0x1e640d('0x51')]),db[_0x1e640d('0x30')][_0x1e640d('0x3e')](_0x15aa7a)['then'](handleEntityNotFound(_0x16c1f9,null))[_0x1e640d('0x16')](respondWithResult(_0x16c1f9,null))[_0x1e640d('0x44')](handleError(_0x16c1f9,null));},exports[_0x1e98e6('0x4c')]=function(_0xcca8f1,_0x402004){const _0x54aac7=_0x1e98e6;return db[_0x54aac7('0x30')][_0x54aac7('0x4c')](_0xcca8f1[_0x54aac7('0x18')],{})[_0x54aac7('0x16')](respondWithResult(_0x402004,0xc9))[_0x54aac7('0x44')](handleError(_0x402004,null));},exports['update']=function(_0x29511f,_0x4ce7fb){const _0x2ddfa1=_0x1e98e6;return _0x29511f[_0x2ddfa1('0x18')]['id']&&delete _0x29511f['body']['id'],db['ChatInternalMessage'][_0x2ddfa1('0x3e')]({'where':{'id':_0x29511f[_0x2ddfa1('0x20')]['id']}})[_0x2ddfa1('0x16')](handleEntityNotFound(_0x4ce7fb,null))[_0x2ddfa1('0x16')](saveUpdates(_0x29511f[_0x2ddfa1('0x18')],null))[_0x2ddfa1('0x16')](respondWithResult(_0x4ce7fb,null))['catch'](handleError(_0x4ce7fb,null));},exports[_0x1e98e6('0x21')]=function(_0x401675,_0x2659fd){const _0x66882=_0x1e98e6;return db[_0x66882('0x30')][_0x66882('0x3e')]({'where':{'id':_0x401675[_0x66882('0x20')]['id']}})[_0x66882('0x16')](handleEntityNotFound(_0x2659fd,null))[_0x66882('0x16')](removeEntity(_0x2659fd,null))[_0x66882('0x44')](handleError(_0x2659fd,null));},exports[_0x1e98e6('0x1b')]=function(_0x59dcbb,_0x13a1e5){const _0x5fa766=_0x1e98e6;return db[_0x5fa766('0x30')][_0x5fa766('0x1b')]()['then'](respondWithResult(_0x13a1e5,null))[_0x5fa766('0x44')](handleError(_0x13a1e5,null));};function wrapUser(_0x5a71f8){return function(_0x49bc97){const _0x4ef55d=a73_0x2bf5,_0x371da5=_0x5a71f8[_0x4ef55d('0x1d')]({'plain':!![]});return _0x371da5[_0x4ef55d('0x34')]=[],_0x49bc97?(_0x371da5[_0x4ef55d('0x52')]=_0x49bc97['createdAt'],_0x371da5[_0x4ef55d('0xb')]=_0x49bc97):(_0x371da5['lastMessageAt']=moment(0x0)[_0x4ef55d('0x4e')](_0x4ef55d('0x33')),_0x371da5[_0x4ef55d('0xb')]={}),_0x371da5;};}exports[_0x1e98e6('0x15')]=function(_0x18d366,_0x242333){const _0x1d532e=_0x1e98e6;let _0x3e537d=[];return db[_0x1d532e('0x31')]['findAll']({'where':{'role':[_0x1d532e('0x41'),_0x1d532e('0x36'),_0x1d532e('0x35')]},'attributes':['id','fullname',_0x1d532e('0x4'),_0x1d532e('0x2e'),_0x1d532e('0x8'),_0x1d532e('0x3b'),'online',_0x1d532e('0x53'),'allowmessenger',_0x1d532e('0x23')],'order':qs[_0x1d532e('0x39')](_0x1d532e('0x1')),'include':[{'model':db[_0x1d532e('0x19')],'as':_0x1d532e('0x2a'),'attributes':['id',_0x1d532e('0x4'),_0x1d532e('0x9')],'through':{'attributes':[]}}]})[_0x1d532e('0x16')](function(_0x569dc9){const _0x5d305f=_0x1d532e;if(_0x569dc9){const _0x2f9b2b=_0x18d366[_0x5d305f('0x35')][_0x5d305f('0x1d')]({'plain':!![]});if(!_0x2f9b2b)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');return _0x2f9b2b[_0x5d305f('0x2e')]===_0x5d305f('0x35')?db[_0x5d305f('0x6')][_0x5d305f('0x3e')]({'where':{'name':_0x5d305f('0x4f'),'userProfileId':_0x2f9b2b[_0x5d305f('0xf')]},'raw':!![]})[_0x5d305f('0x16')](function(_0x40d981){const _0x55fbde=_0x5d305f;if(_0x40d981)return _0x40d981['autoAssociation']===0x0?db[_0x55fbde('0x1c')]['findAll']({'where':{'sectionId':_0x40d981['id']},'raw':!![]})[_0x55fbde('0x16')](function(_0x48a6cc){const _0x29fd7d=_0x55fbde;let _0x2825dc=[];if(_[_0x29fd7d('0x14')](_0x48a6cc))return _0x2825dc=_['filter'](_0x569dc9,function(_0x3967a1){const _0xb07d9f=_0x29fd7d;if(_0x3967a1['role']!==_0xb07d9f('0x41'))return _0x3967a1;}),_0x2825dc;else{for(let _0x5eb8af=0x0;_0x5eb8af<_0x569dc9['length'];_0x5eb8af++){const _0xe61451=_0x569dc9[_0x5eb8af];if(_0xe61451[_0x29fd7d('0x2e')]===_0x29fd7d('0x41')){const _0x50d0f8=_[_0x29fd7d('0x48')](_0x48a6cc,function(_0x36f7a6){return _0x36f7a6['resourceId']===_0xe61451['id'];});if(_0x50d0f8)_0x2825dc[_0x29fd7d('0x27')](_0xe61451);}else _0x2825dc[_0x29fd7d('0x27')](_0xe61451);}return _0x2825dc;}}):_0x569dc9;else{const _0x5a864b=_[_0x55fbde('0x47')](_0x569dc9,function(_0x55a0c4){const _0x31c51b=_0x55fbde;if(_0x55a0c4[_0x31c51b('0x2e')]!==_0x31c51b('0x41'))return _0x55a0c4;});return _0x5a864b;}}):_0x569dc9;}})[_0x1d532e('0x16')](function(_0x312460){const _0x136e14=_0x1d532e,_0x3982f3=[];if(_0x312460){_0x3e537d=_0x312460;for(let _0x195eb5=0x0;_0x195eb5<_0x312460[_0x136e14('0x2')];_0x195eb5+=0x1){_0x3e537d[_0x195eb5][_0x136e14('0x34')]=[],_0x3982f3[_0x136e14('0x27')](db['ChatInternalMessage'][_0x136e14('0x3e')]({'where':{'FromId':[_0x18d366[_0x136e14('0x35')]['id'],_0x312460[_0x195eb5]['id']],'ToId':[_0x18d366[_0x136e14('0x35')]['id'],_0x312460[_0x195eb5]['id']],'ChatGroupId':null},'attributes':['id','createdAt','FromId',_0x136e14('0x5'),_0x136e14('0x1f'),_0x136e14('0x18')],'order':qs[_0x136e14('0x39')](_0x136e14('0x0')),'limit':0x1,'offset':0x0,'raw':!![]})[_0x136e14('0x16')](wrapUser(_0x312460[_0x195eb5])));}return Promise[_0x136e14('0x25')](_0x3982f3);}return[];})[_0x1d532e('0x16')](function(_0x1ef6a2){const _0x30b838=_0x1d532e;return{'rows':_0x1ef6a2,'count':_0x1ef6a2[_0x30b838('0x2')]};})[_0x1d532e('0x16')](respondWithResult(_0x242333,null))[_0x1d532e('0x44')](handleError(_0x242333,null));}; \ No newline at end of file +const a73_0x6b41=['admin','getUsers','VIRTUAL','Content-Range','limit','YYYY-MM-DD\x20HH:mm:ss','undefined','sendStatus','type','like','intersection','error','autoAssociation','./chatInternalMessage.socket','merge','lodash','Unable\x20to\x20retrieve\x20the\x20current\x20user','role','push','model','../../components/parsers/qs','set','send','params','lastLoginAt','findAll','moment','include','map','-createdAt','describe','Agents','index','VoiceQueues','../../mysqldb','get','fullname','status','lastMessageAt','lastMessage','length','userpic','name','createdAt','internal','offset','VoiceQueue','options','show','ChatInternalMessage','fieldName','findOne','api','create','FromId','body','catch','query','attributes','rows','filter','filters','json','destroy','includeAll','fields','messages','where','all','showWebBar','resourceId','keys','../../rediscache','count','UserProfileSection','find','then','update','sort','agent','UserProfileResource','-online','user','ToId','order','nolimit'];(function(_0x240a31,_0x6b416d){const _0x4599a8=function(_0x241460){while(--_0x241460){_0x240a31['push'](_0x240a31['shift']());}};_0x4599a8(++_0x6b416d);}(a73_0x6b41,0x1a3));const a73_0x4599=function(_0x240a31,_0x6b416d){_0x240a31=_0x240a31-0x0;let _0x4599a8=a73_0x6b41[_0x240a31];return _0x4599a8;};const _0x379006=a73_0x4599;'use strict';const moment=require(_0x379006('0x25')),_=require(_0x379006('0x1a')),qs=require(_0x379006('0x1f')),logger=require('../../config/logger')(_0x379006('0x3f')),{getSocket}=require(_0x379006('0x53')),db=require(_0x379006('0x2d'))['db'],{Op}=require('sequelize'),socket=getSocket();require(_0x379006('0x18'))['register'](socket);function respondWithResult(_0x241460,_0x282119){return _0x282119=_0x282119||0xc8,function(_0x21a554){if(_0x21a554)return _0x241460['status'](_0x282119)['json'](_0x21a554);};}function respondWithFilteredResult(_0x2b4e7c,_0x5005c9){return function(_0x39d9e3){const _0x33b0f1=a73_0x4599;if(_0x39d9e3){const _0x239799=_0x39d9e3[_0x33b0f1('0x54')],_0x2d2aab=_0x5005c9[_0x33b0f1('0x38')];let _0x476692=_0x5005c9[_0x33b0f1('0x38')]+_0x5005c9[_0x33b0f1('0xf')],_0x476238;return _0x476692>=_0x239799?(_0x476692=_0x239799,_0x476238=0xc8):_0x476238=0xce,_0x2b4e7c['status'](_0x476238),_0x2b4e7c[_0x33b0f1('0x20')](_0x33b0f1('0xe'),_0x2d2aab+'-'+_0x476692+'/'+_0x239799)[_0x33b0f1('0x49')](_0x39d9e3);}return null;};}function saveUpdates(_0x282f10){return function(_0x3b3543){const _0x11e017=a73_0x4599;if(_0x3b3543)return _0x3b3543[_0x11e017('0x2')](_0x282f10)['then'](function(_0x53983b){return _0x53983b;});return null;};}function removeEntity(_0x113fed){return function(_0x48b3cf){const _0x275b96=a73_0x4599;if(_0x48b3cf)return _0x48b3cf[_0x275b96('0x4a')]()[_0x275b96('0x1')](function(){_0x113fed['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x285d92){return function(_0x441e20){const _0x2bfb50=a73_0x4599;return!_0x441e20&&_0x285d92[_0x2bfb50('0x12')](0x194),_0x441e20;};}function handleError(_0x2b2a3a,_0x57a90d){return _0x57a90d=_0x57a90d||0x1f4,function(_0x1c6a55){const _0x29bbf6=a73_0x4599;logger[_0x29bbf6('0x16')](_0x1c6a55['stack']),_0x1c6a55['name']&&delete _0x1c6a55['name'],_0x2b2a3a[_0x29bbf6('0x30')](_0x57a90d)[_0x29bbf6('0x21')](_0x1c6a55);};}exports[_0x379006('0x2b')]=function(_0x1120c1,_0x5c14a2){const _0x229c55=_0x379006;let _0x1892db={};const _0x4be2d4={},_0x46d209={'count':0x0,'rows':[]},_0x1732ef=_[_0x229c55('0x27')](db[_0x229c55('0x3c')]['rawAttributes'],function(_0x5e3526){const _0x4d1789=_0x229c55;return{'name':_0x5e3526[_0x4d1789('0x3d')],'type':_0x5e3526[_0x4d1789('0x13')]['key']};});_0x4be2d4['model']=_[_0x229c55('0x27')](_0x1732ef,_0x229c55('0x35')),_0x4be2d4[_0x229c55('0x44')]=_[_0x229c55('0x52')](_0x1120c1[_0x229c55('0x44')]),_0x4be2d4['filters']=_[_0x229c55('0x15')](_0x4be2d4[_0x229c55('0x1e')],_0x4be2d4[_0x229c55('0x44')]),_0x1892db['attributes']=_[_0x229c55('0x15')](_0x4be2d4[_0x229c55('0x1e')],qs[_0x229c55('0x4c')](_0x1120c1['query'][_0x229c55('0x4c')])),_0x1892db[_0x229c55('0x45')]=_0x1892db[_0x229c55('0x45')][_0x229c55('0x33')]?_0x1892db[_0x229c55('0x45')]:_0x4be2d4[_0x229c55('0x1e')];typeof _0x1120c1[_0x229c55('0x44')][_0x229c55('0xa')]===_0x229c55('0x11')&&(_0x1892db[_0x229c55('0xf')]=qs[_0x229c55('0xf')](_0x1120c1[_0x229c55('0x44')][_0x229c55('0xf')]),_0x1892db[_0x229c55('0x38')]=qs[_0x229c55('0x38')](_0x1120c1[_0x229c55('0x44')][_0x229c55('0x38')]));_0x1892db[_0x229c55('0x9')]=qs[_0x229c55('0x3')](_0x1120c1[_0x229c55('0x44')][_0x229c55('0x3')]),_0x1892db[_0x229c55('0x4e')]=qs[_0x229c55('0x48')](_['pick'](_0x1120c1['query'],_0x4be2d4[_0x229c55('0x48')]),_0x1732ef);_0x1120c1[_0x229c55('0x44')][_0x229c55('0x47')]&&(_0x1892db[_0x229c55('0x4e')]=_[_0x229c55('0x19')](_0x1892db[_0x229c55('0x4e')],{[Op['or']]:_[_0x229c55('0x27')](_0x1732ef,function(_0x652dd9){const _0x31124e=_0x229c55;if(_0x652dd9[_0x31124e('0x13')]!==_0x31124e('0xd')){const _0x2f235c={};return _0x2f235c[_0x652dd9[_0x31124e('0x35')]]={[Op[_0x31124e('0x14')]]:'%'+_0x1120c1[_0x31124e('0x44')]['filter']+'%'},_0x2f235c;}})}));_0x1892db=_[_0x229c55('0x19')]({},_0x1892db,_0x1120c1[_0x229c55('0x3a')]);const _0x21c129={'where':_0x1892db[_0x229c55('0x4e')]};return db['ChatInternalMessage'][_0x229c55('0x54')](_0x21c129)[_0x229c55('0x1')](function(_0x43e66c){const _0x41b555=_0x229c55;return _0x46d209[_0x41b555('0x54')]=_0x43e66c,_0x1120c1[_0x41b555('0x44')][_0x41b555('0x4b')]&&(_0x1892db[_0x41b555('0x26')]=[{'all':!![]}]),db['ChatInternalMessage'][_0x41b555('0x24')](_0x1892db);})[_0x229c55('0x1')](function(_0x5297c2){const _0x50b05d=_0x229c55;return _0x46d209[_0x50b05d('0x46')]=_0x5297c2,_0x46d209;})[_0x229c55('0x1')](respondWithFilteredResult(_0x5c14a2,_0x1892db))['catch'](handleError(_0x5c14a2,null));},exports[_0x379006('0x3b')]=function(_0x1d80ee,_0x523051){const _0x151184=_0x379006;let _0x4e2928={'raw':!![],'where':{'id':_0x1d80ee[_0x151184('0x22')]['id']}};const _0x3ba28f={};return _0x3ba28f[_0x151184('0x1e')]=_['keys'](db['ChatInternalMessage']['rawAttributes']),_0x3ba28f[_0x151184('0x44')]=_[_0x151184('0x52')](_0x1d80ee[_0x151184('0x44')]),_0x3ba28f[_0x151184('0x48')]=_[_0x151184('0x15')](_0x3ba28f[_0x151184('0x1e')],_0x3ba28f[_0x151184('0x44')]),_0x4e2928[_0x151184('0x45')]=_[_0x151184('0x15')](_0x3ba28f[_0x151184('0x1e')],qs['fields'](_0x1d80ee[_0x151184('0x44')][_0x151184('0x4c')])),_0x4e2928[_0x151184('0x45')]=_0x4e2928[_0x151184('0x45')][_0x151184('0x33')]?_0x4e2928[_0x151184('0x45')]:_0x3ba28f['model'],_0x1d80ee[_0x151184('0x44')]['includeAll']&&(_0x4e2928['include']=[{'all':!![]}]),_0x4e2928=_[_0x151184('0x19')]({},_0x4e2928,_0x1d80ee['options']),db['ChatInternalMessage'][_0x151184('0x3e')](_0x4e2928)[_0x151184('0x1')](handleEntityNotFound(_0x523051,null))['then'](respondWithResult(_0x523051,null))[_0x151184('0x43')](handleError(_0x523051,null));},exports[_0x379006('0x40')]=function(_0x474caa,_0x2b22d4){const _0x31420e=_0x379006;return db[_0x31420e('0x3c')][_0x31420e('0x40')](_0x474caa[_0x31420e('0x42')],{})[_0x31420e('0x1')](respondWithResult(_0x2b22d4,0xc9))['catch'](handleError(_0x2b22d4,null));},exports[_0x379006('0x2')]=function(_0x3e7538,_0x4c0847){const _0x50b994=_0x379006;return _0x3e7538['body']['id']&&delete _0x3e7538[_0x50b994('0x42')]['id'],db[_0x50b994('0x3c')][_0x50b994('0x3e')]({'where':{'id':_0x3e7538[_0x50b994('0x22')]['id']}})[_0x50b994('0x1')](handleEntityNotFound(_0x4c0847,null))[_0x50b994('0x1')](saveUpdates(_0x3e7538[_0x50b994('0x42')],null))['then'](respondWithResult(_0x4c0847,null))[_0x50b994('0x43')](handleError(_0x4c0847,null));},exports[_0x379006('0x4a')]=function(_0x144fae,_0x5cd912){const _0x114e13=_0x379006;return db['ChatInternalMessage']['findOne']({'where':{'id':_0x144fae[_0x114e13('0x22')]['id']}})[_0x114e13('0x1')](handleEntityNotFound(_0x5cd912,null))['then'](removeEntity(_0x5cd912,null))[_0x114e13('0x43')](handleError(_0x5cd912,null));},exports[_0x379006('0x29')]=function(_0x1e8c30,_0x17ed8a){const _0x4a81ae=_0x379006;return db['ChatInternalMessage'][_0x4a81ae('0x29')]()[_0x4a81ae('0x1')](respondWithResult(_0x17ed8a,null))[_0x4a81ae('0x43')](handleError(_0x17ed8a,null));};function wrapUser(_0x106468){return function(_0x5df349){const _0x3ee135=a73_0x4599,_0xf3c520=_0x106468[_0x3ee135('0x2e')]({'plain':!![]});return _0xf3c520[_0x3ee135('0x4d')]=[],_0x5df349?(_0xf3c520[_0x3ee135('0x31')]=_0x5df349[_0x3ee135('0x36')],_0xf3c520[_0x3ee135('0x32')]=_0x5df349):(_0xf3c520[_0x3ee135('0x31')]=moment(0x0)['format'](_0x3ee135('0x10')),_0xf3c520[_0x3ee135('0x32')]={}),_0xf3c520;};}exports[_0x379006('0xc')]=function(_0x27fd77,_0x10ba52){const _0x385187=_0x379006;let _0x490cbd=[];return db['User'][_0x385187('0x24')]({'where':{'role':[_0x385187('0x4'),_0x385187('0xb'),_0x385187('0x7')]},'attributes':['id',_0x385187('0x2f'),'name',_0x385187('0x1c'),_0x385187('0x34'),_0x385187('0x37'),'online',_0x385187('0x23'),'allowmessenger',_0x385187('0x50')],'order':qs[_0x385187('0x3')](_0x385187('0x6')),'include':[{'model':db[_0x385187('0x39')],'as':_0x385187('0x2c'),'attributes':['id',_0x385187('0x35'),_0x385187('0x13')],'through':{'attributes':[]}}]})[_0x385187('0x1')](function(_0x97f531){const _0x201fc6=_0x385187;if(_0x97f531){const _0x65c602=_0x27fd77[_0x201fc6('0x7')]['get']({'plain':!![]});if(!_0x65c602)throw new Error(_0x201fc6('0x1b'));return _0x65c602['role']===_0x201fc6('0x7')?db[_0x201fc6('0x55')]['findOne']({'where':{'name':_0x201fc6('0x2a'),'userProfileId':_0x65c602['userProfileId']},'raw':!![]})['then'](function(_0x3ed67a){const _0x534f97=_0x201fc6;if(_0x3ed67a)return _0x3ed67a[_0x534f97('0x17')]===0x0?db[_0x534f97('0x5')][_0x534f97('0x24')]({'where':{'sectionId':_0x3ed67a['id']},'raw':!![]})[_0x534f97('0x1')](function(_0x3aa1ff){const _0x4da8fe=_0x534f97;let _0x569178=[];if(_['isEmpty'](_0x3aa1ff))return _0x569178=_['filter'](_0x97f531,function(_0x5b9c0a){const _0xbafa2e=a73_0x4599;if(_0x5b9c0a[_0xbafa2e('0x1c')]!==_0xbafa2e('0x4'))return _0x5b9c0a;}),_0x569178;else{for(let _0x54db5c=0x0;_0x54db5c<_0x97f531['length'];_0x54db5c++){const _0x5602e1=_0x97f531[_0x54db5c];if(_0x5602e1[_0x4da8fe('0x1c')]===_0x4da8fe('0x4')){const _0x5d13b1=_[_0x4da8fe('0x0')](_0x3aa1ff,function(_0x345fa7){const _0x386793=_0x4da8fe;return _0x345fa7[_0x386793('0x51')]===_0x5602e1['id'];});if(_0x5d13b1)_0x569178[_0x4da8fe('0x1d')](_0x5602e1);}else _0x569178[_0x4da8fe('0x1d')](_0x5602e1);}return _0x569178;}}):_0x97f531;else{const _0x372f30=_[_0x534f97('0x47')](_0x97f531,function(_0x20461a){const _0x22a110=_0x534f97;if(_0x20461a[_0x22a110('0x1c')]!==_0x22a110('0x4'))return _0x20461a;});return _0x372f30;}}):_0x97f531;}})[_0x385187('0x1')](function(_0x5ccc9c){const _0x1ce762=_0x385187,_0x370647=[];if(_0x5ccc9c){_0x490cbd=_0x5ccc9c;for(let _0x16a2dd=0x0;_0x16a2dd<_0x5ccc9c[_0x1ce762('0x33')];_0x16a2dd+=0x1){_0x490cbd[_0x16a2dd][_0x1ce762('0x4d')]=[],_0x370647[_0x1ce762('0x1d')](db['ChatInternalMessage']['findOne']({'where':{'FromId':[_0x27fd77[_0x1ce762('0x7')]['id'],_0x5ccc9c[_0x16a2dd]['id']],'ToId':[_0x27fd77['user']['id'],_0x5ccc9c[_0x16a2dd]['id']],'ChatGroupId':null},'attributes':['id','createdAt',_0x1ce762('0x41'),_0x1ce762('0x8'),'read',_0x1ce762('0x42')],'order':qs[_0x1ce762('0x3')](_0x1ce762('0x28')),'limit':0x1,'offset':0x0,'raw':!![]})[_0x1ce762('0x1')](wrapUser(_0x5ccc9c[_0x16a2dd])));}return Promise[_0x1ce762('0x4f')](_0x370647);}return[];})[_0x385187('0x1')](function(_0x8e1fcd){const _0x34ea98=_0x385187;return{'rows':_0x8e1fcd,'count':_0x8e1fcd[_0x34ea98('0x33')]};})[_0x385187('0x1')](respondWithResult(_0x10ba52,null))[_0x385187('0x43')](handleError(_0x10ba52,null));}; \ No newline at end of file diff --git a/server/api/chatInternalMessage/chatInternalMessage.events.js b/server/api/chatInternalMessage/chatInternalMessage.events.js index bc19ea6..4b186cc 100644 --- a/server/api/chatInternalMessage/chatInternalMessage.events.js +++ b/server/api/chatInternalMessage/chatInternalMessage.events.js @@ -1 +1 @@ -const a74_0x4d56=['undefined','save','emit','ChatInternalMessage','update','setMaxListeners','events'];(function(_0x28d0f4,_0x4d5602){const _0x4e7515=function(_0x3188e9){while(--_0x3188e9){_0x28d0f4['push'](_0x28d0f4['shift']());}};_0x4e7515(++_0x4d5602);}(a74_0x4d56,0xe1));const a74_0x4e75=function(_0x28d0f4,_0x4d5602){_0x28d0f4=_0x28d0f4-0x0;let _0x4e7515=a74_0x4d56[_0x28d0f4];return _0x4e7515;};const _0x50848a=a74_0x4e75;'use strict';const EventEmitter=require(_0x50848a('0x5')),ChatInternalMessage=require('../../mysqldb')['db'][_0x50848a('0x2')],ChatInternalMessageEvents=new EventEmitter();ChatInternalMessageEvents[_0x50848a('0x4')](0x0);const events={'afterCreate':_0x50848a('0x0'),'afterUpdate':_0x50848a('0x3'),'afterDestroy':'remove'};function emitEvent(_0x3188e9){return function(_0x4226f0){const _0x36d50c=a74_0x4e75;ChatInternalMessageEvents[_0x36d50c('0x1')](_0x3188e9+':'+_0x4226f0['id'],_0x4226f0),ChatInternalMessageEvents[_0x36d50c('0x1')](_0x3188e9,_0x4226f0);};}for(const e in events){if(typeof events[e]!==_0x50848a('0x6')){const event=events[e];ChatInternalMessage['addHook'](e,emitEvent(event));}}module['exports']=ChatInternalMessageEvents; \ No newline at end of file +const a74_0x5fee=['exports','setMaxListeners','emit','addHook','events','ChatInternalMessage','save'];(function(_0x5a390,_0x5feebe){const _0x290f61=function(_0x536db6){while(--_0x536db6){_0x5a390['push'](_0x5a390['shift']());}};_0x290f61(++_0x5feebe);}(a74_0x5fee,0x1e5));const a74_0x290f=function(_0x5a390,_0x5feebe){_0x5a390=_0x5a390-0x0;let _0x290f61=a74_0x5fee[_0x5a390];return _0x290f61;};const _0x573130=a74_0x290f;'use strict';const EventEmitter=require(_0x573130('0x2')),ChatInternalMessage=require('../../mysqldb')['db'][_0x573130('0x3')],ChatInternalMessageEvents=new EventEmitter();ChatInternalMessageEvents[_0x573130('0x6')](0x0);const events={'afterCreate':_0x573130('0x4'),'afterUpdate':'update','afterDestroy':'remove'};function emitEvent(_0x536db6){return function(_0x78a8){const _0x51290e=a74_0x290f;ChatInternalMessageEvents[_0x51290e('0x0')](_0x536db6+':'+_0x78a8['id'],_0x78a8),ChatInternalMessageEvents[_0x51290e('0x0')](_0x536db6,_0x78a8);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];ChatInternalMessage[_0x573130('0x1')](e,emitEvent(event));}}module[_0x573130('0x5')]=ChatInternalMessageEvents; \ No newline at end of file diff --git a/server/api/chatInternalMessage/chatInternalMessage.model.js b/server/api/chatInternalMessage/chatInternalMessage.model.js index 21d0304..2197374 100644 --- a/server/api/chatInternalMessage/chatInternalMessage.model.js +++ b/server/api/chatInternalMessage/chatInternalMessage.model.js @@ -1 +1 @@ -const a75_0x2eb4=['utf8mb4','ChatInternalMessage','exports','./chatInternalMessage.attributes','chat_internal_messages'];(function(_0x2ded2f,_0x2eb489){const _0x405dcd=function(_0x2cc030){while(--_0x2cc030){_0x2ded2f['push'](_0x2ded2f['shift']());}};_0x405dcd(++_0x2eb489);}(a75_0x2eb4,0x119));const a75_0x405d=function(_0x2ded2f,_0x2eb489){_0x2ded2f=_0x2ded2f-0x0;let _0x405dcd=a75_0x2eb4[_0x2ded2f];return _0x405dcd;};const _0x153b68=a75_0x405d;'use strict';const attributes=require(_0x153b68('0x2'));module[_0x153b68('0x1')]=function(_0x2cc030){const _0x1a5346=_0x153b68,_0x123ba9=_0x2cc030['define'](_0x1a5346('0x0'),attributes,{'tableName':_0x1a5346('0x3'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x1a5346('0x4'),'collate':'utf8mb4_unicode_ci'});return _0x123ba9;}; \ No newline at end of file +const a75_0x1ec0=['utf8mb4_unicode_ci','utf8mb4','./chatInternalMessage.attributes','exports'];(function(_0x1dc6ff,_0x1ec090){const _0x4c82ff=function(_0x454eb9){while(--_0x454eb9){_0x1dc6ff['push'](_0x1dc6ff['shift']());}};_0x4c82ff(++_0x1ec090);}(a75_0x1ec0,0x123));const a75_0x4c82=function(_0x1dc6ff,_0x1ec090){_0x1dc6ff=_0x1dc6ff-0x0;let _0x4c82ff=a75_0x1ec0[_0x1dc6ff];return _0x4c82ff;};const _0x22a1d8=a75_0x4c82;'use strict';const attributes=require(_0x22a1d8('0x3'));module[_0x22a1d8('0x0')]=function(_0x454eb9){const _0x5ef90c=_0x22a1d8,_0x47b4fa=_0x454eb9['define']('ChatInternalMessage',attributes,{'tableName':'chat_internal_messages','paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x5ef90c('0x2'),'collate':_0x5ef90c('0x1')});return _0x47b4fa;}; \ No newline at end of file diff --git a/server/api/chatInternalMessage/chatInternalMessage.rpc.js b/server/api/chatInternalMessage/chatInternalMessage.rpc.js index 6d7c3de..4fcf636 100644 --- a/server/api/chatInternalMessage/chatInternalMessage.rpc.js +++ b/server/api/chatInternalMessage/chatInternalMessage.rpc.js @@ -1 +1 @@ -const a76_0x22c5=['../../rediscache','./chatInternalMessage.socket'];(function(_0x24fc7c,_0x22c57c){const _0x175560=function(_0x3cab7b){while(--_0x3cab7b){_0x24fc7c['push'](_0x24fc7c['shift']());}};_0x175560(++_0x22c57c);}(a76_0x22c5,0x8a));const a76_0x1755=function(_0x24fc7c,_0x22c57c){_0x24fc7c=_0x24fc7c-0x0;let _0x175560=a76_0x22c5[_0x24fc7c];return _0x175560;};const _0x59c644=a76_0x1755;'use strict';const {getSocket}=require(_0x59c644('0x0')),socket=getSocket();require(_0x59c644('0x1'))['register'](socket); \ No newline at end of file +const a76_0x365e=['../../rediscache','./chatInternalMessage.socket'];(function(_0x555914,_0x365e09){const _0x22b452=function(_0x3a672e){while(--_0x3a672e){_0x555914['push'](_0x555914['shift']());}};_0x22b452(++_0x365e09);}(a76_0x365e,0xcb));const a76_0x22b4=function(_0x555914,_0x365e09){_0x555914=_0x555914-0x0;let _0x22b452=a76_0x365e[_0x555914];return _0x22b452;};const _0x2755ca=a76_0x22b4;'use strict';const {getSocket}=require(_0x2755ca('0x1')),socket=getSocket();require(_0x2755ca('0x0'))['register'](socket); \ No newline at end of file diff --git a/server/api/chatInternalMessage/chatInternalMessage.socket.js b/server/api/chatInternalMessage/chatInternalMessage.socket.js index 7a0acbb..aaee5e3 100644 --- a/server/api/chatInternalMessage/chatInternalMessage.socket.js +++ b/server/api/chatInternalMessage/chatInternalMessage.socket.js @@ -1 +1 @@ -const a77_0x30b6=['./chatInternalMessage.events','emit','remove','update','save','register','length'];(function(_0x1ce98d,_0x30b602){const _0x4f7edc=function(_0x58492f){while(--_0x58492f){_0x1ce98d['push'](_0x1ce98d['shift']());}};_0x4f7edc(++_0x30b602);}(a77_0x30b6,0x116));const a77_0x4f7e=function(_0x1ce98d,_0x30b602){_0x1ce98d=_0x1ce98d-0x0;let _0x4f7edc=a77_0x30b6[_0x1ce98d];return _0x4f7edc;};const _0x5e8010=a77_0x4f7e;'use strict';const ChatInternalMessageEvents=require(_0x5e8010('0x2')),events=[_0x5e8010('0x6'),_0x5e8010('0x4'),_0x5e8010('0x5')];function createListener(_0x58492f,_0x26dac8){return function(_0x58278f){const _0x45c8ff=a77_0x4f7e;_0x26dac8[_0x45c8ff('0x3')](_0x58492f,_0x58278f);};}exports[_0x5e8010('0x0')]=function(_0x438d27){const _0x224058=_0x5e8010;for(let _0x6bb175=0x0,_0x54af9e=events[_0x224058('0x1')];_0x6bb175<_0x54af9e;_0x6bb175++){const _0x177a92=events[_0x6bb175],_0x18b908=createListener('chatInternalMessage:'+_0x177a92,_0x438d27);ChatInternalMessageEvents['on'](_0x177a92,_0x18b908);}}; \ No newline at end of file +const a77_0x13b8=['save','remove','emit','length','update','./chatInternalMessage.events','register'];(function(_0x4f131a,_0x13b888){const _0x2f9cc5=function(_0x32b017){while(--_0x32b017){_0x4f131a['push'](_0x4f131a['shift']());}};_0x2f9cc5(++_0x13b888);}(a77_0x13b8,0xa8));const a77_0x2f9c=function(_0x4f131a,_0x13b888){_0x4f131a=_0x4f131a-0x0;let _0x2f9cc5=a77_0x13b8[_0x4f131a];return _0x2f9cc5;};const _0x53275f=a77_0x2f9c;'use strict';const ChatInternalMessageEvents=require(_0x53275f('0x5')),events=[_0x53275f('0x0'),_0x53275f('0x1'),_0x53275f('0x4')];function createListener(_0x32b017,_0x5cb88e){function _0x36b2a0(_0x418128){const _0x5aeca0=a77_0x2f9c;_0x5cb88e[_0x5aeca0('0x2')](_0x32b017,_0x418128);}return _0x36b2a0;}exports[_0x53275f('0x6')]=function(_0x39b469){const _0x248694=_0x53275f;for(let _0x491112=0x0,_0x4f417c=events[_0x248694('0x3')];_0x491112<_0x4f417c;_0x491112++){const _0x56eb85=events[_0x491112],_0x1e39ae=createListener('chatInternalMessage:'+_0x56eb85,_0x39b469);ChatInternalMessageEvents['on'](_0x56eb85,_0x1e39ae);}}; \ No newline at end of file diff --git a/server/api/chatInternalMessage/index.js b/server/api/chatInternalMessage/index.js index b3b1a8b..06998de 100644 --- a/server/api/chatInternalMessage/index.js +++ b/server/api/chatInternalMessage/index.js @@ -1 +1 @@ -const a78_0x18b1=['get','./chatInternalMessage.controller','post','../../components/auth/service','describe','/describe','express','show','/:id','isAuthenticated','put'];(function(_0x568008,_0x18b114){const _0xeb2421=function(_0x38bf42){while(--_0x38bf42){_0x568008['push'](_0x568008['shift']());}};_0xeb2421(++_0x18b114);}(a78_0x18b1,0xe6));const a78_0xeb24=function(_0x568008,_0x18b114){_0x568008=_0x568008-0x0;let _0xeb2421=a78_0x18b1[_0x568008];return _0xeb2421;};const _0x4307d2=a78_0xeb24;'use strict';const express=require(_0x4307d2('0x7')),router=express['Router'](),auth=require(_0x4307d2('0x4')),controller=require(_0x4307d2('0x2'));router['get']('/',auth[_0x4307d2('0xa')](),controller['index']),router[_0x4307d2('0x1')](_0x4307d2('0x6'),auth['isAuthenticated'](),controller[_0x4307d2('0x5')]),router['get']('/users',auth[_0x4307d2('0xa')](),controller['getUsers']),router['get'](_0x4307d2('0x9'),auth[_0x4307d2('0xa')](),controller[_0x4307d2('0x8')]),router[_0x4307d2('0x3')]('/',auth[_0x4307d2('0xa')](),controller['create']),router[_0x4307d2('0x0')](_0x4307d2('0x9'),controller['update']),router['delete'](_0x4307d2('0x9'),auth[_0x4307d2('0xa')](),controller['destroy']),module['exports']=router; \ No newline at end of file +const a78_0x2204=['exports','/users','get','describe','show','express','destroy','/:id','/describe','index','delete','update','../../components/auth/service','isAuthenticated','post'];(function(_0x41e9de,_0x22045b){const _0x1999f6=function(_0x43435e){while(--_0x43435e){_0x41e9de['push'](_0x41e9de['shift']());}};_0x1999f6(++_0x22045b);}(a78_0x2204,0x142));const a78_0x1999=function(_0x41e9de,_0x22045b){_0x41e9de=_0x41e9de-0x0;let _0x1999f6=a78_0x2204[_0x41e9de];return _0x1999f6;};const _0x844cd1=a78_0x1999;'use strict';const express=require(_0x844cd1('0xd')),router=express['Router'](),auth=require(_0x844cd1('0x5')),controller=require('./chatInternalMessage.controller');router[_0x844cd1('0xa')]('/',auth[_0x844cd1('0x6')](),controller[_0x844cd1('0x2')]),router[_0x844cd1('0xa')](_0x844cd1('0x1'),auth[_0x844cd1('0x6')](),controller[_0x844cd1('0xb')]),router[_0x844cd1('0xa')](_0x844cd1('0x9'),auth[_0x844cd1('0x6')](),controller['getUsers']),router[_0x844cd1('0xa')]('/:id',auth[_0x844cd1('0x6')](),controller[_0x844cd1('0xc')]),router[_0x844cd1('0x7')]('/',auth[_0x844cd1('0x6')](),controller['create']),router['put'](_0x844cd1('0x0'),controller[_0x844cd1('0x4')]),router[_0x844cd1('0x3')]('/:id',auth[_0x844cd1('0x6')](),controller[_0x844cd1('0xe')]),module[_0x844cd1('0x8')]=router; \ No newline at end of file diff --git a/server/api/chatMessage/chatMessage.attributes.js b/server/api/chatMessage/chatMessage.attributes.js index da80625..8a1449e 100644 --- a/server/api/chatMessage/chatMessage.attributes.js +++ b/server/api/chatMessage/chatMessage.attributes.js @@ -1 +1 @@ -const a79_0x3305=['DATE','STRING','sequelize','out','ENUM','exports','BOOLEAN','TEXT','medium'];(function(_0x2018ea,_0x330509){const _0x127659=function(_0x239f65){while(--_0x239f65){_0x2018ea['push'](_0x2018ea['shift']());}};_0x127659(++_0x330509);}(a79_0x3305,0x1cd));const a79_0x1276=function(_0x2018ea,_0x330509){_0x2018ea=_0x2018ea-0x0;let _0x127659=a79_0x3305[_0x2018ea];return _0x127659;};const _0x173b89=a79_0x1276;'use strict';const Sequelize=require(_0x173b89('0x0'));module[_0x173b89('0x3')]={'body':{'type':Sequelize['TEXT'](_0x173b89('0x6')),'allowNull':![]},'read':{'type':Sequelize[_0x173b89('0x4')],'defaultValue':![]},'secret':{'type':Sequelize[_0x173b89('0x4')],'defaultValue':![]},'direction':{'type':Sequelize[_0x173b89('0x2')]('in',_0x173b89('0x1')),'defaultValue':_0x173b89('0x1'),'allowNull':![]},'readAt':{'type':Sequelize[_0x173b89('0x7')]},'providerName':{'type':Sequelize[_0x173b89('0x8')]},'providerResponse':{'type':Sequelize[_0x173b89('0x5')]}}; \ No newline at end of file +const a79_0x32ee=['out','medium','TEXT','BOOLEAN','ENUM','STRING','DATE','exports'];(function(_0x1bf463,_0x32ee26){const _0x15bd69=function(_0x4cea00){while(--_0x4cea00){_0x1bf463['push'](_0x1bf463['shift']());}};_0x15bd69(++_0x32ee26);}(a79_0x32ee,0x106));const a79_0x15bd=function(_0x1bf463,_0x32ee26){_0x1bf463=_0x1bf463-0x0;let _0x15bd69=a79_0x32ee[_0x1bf463];return _0x15bd69;};const _0x1f040=a79_0x15bd;'use strict';const Sequelize=require('sequelize');module[_0x1f040('0x1')]={'body':{'type':Sequelize[_0x1f040('0x4')](_0x1f040('0x3')),'allowNull':![]},'read':{'type':Sequelize[_0x1f040('0x5')],'defaultValue':![]},'secret':{'type':Sequelize[_0x1f040('0x5')],'defaultValue':![]},'direction':{'type':Sequelize[_0x1f040('0x6')]('in',_0x1f040('0x2')),'defaultValue':_0x1f040('0x2'),'allowNull':![]},'readAt':{'type':Sequelize[_0x1f040('0x0')]},'providerName':{'type':Sequelize[_0x1f040('0x7')]},'providerResponse':{'type':Sequelize[_0x1f040('0x4')]}}; \ No newline at end of file diff --git a/server/api/chatMessage/chatMessage.controller.js b/server/api/chatMessage/chatMessage.controller.js index cbbacfe..b5a6f52 100644 --- a/server/api/chatMessage/chatMessage.controller.js +++ b/server/api/chatMessage/chatMessage.controller.js @@ -1 +1 @@ -const a80_0x56b6=['keys','offset','client','request\x20sent','params','json','nolimit','Content-Range','findAll','VIRTUAL','EventManager','pick','count','../../mysqldb','debug','Contact','create','ChatMessage','acceptmessage','user','CmContact','show','formData','http','undefined','AcceptMessage','role','model','send','type','fields','accept','parse','chat','rejectMessage','limit','agent','read1stAt','util','body','format','attributes','YYYY-MM-DD\x20HH:mm:ss','sendStatus','filter','reject','interaction','length','result','rows','map','channel','lodash','interface','merge','[CHATMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','includeAll','event','chat-interactions','ChatInteraction','describe','get','order','../../config/logger','filters','name','stringify','read','intersection','jayson/promise','null','message','findOne','UserId','../../components/parsers/qs','destroy','./chatMessage.socket','catch','acceptMessage','ChatInteractionId','[CHATMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','index','query','then','fieldName','info','error','sequelize','options','rawAttributes','SIP/%s','sort','../../rediscache','rejectmessage','ChatMessage,\x20%s,\x20%s','where','RejectMessage','update','status','key','ChatMessage,\x20%s,\x20%s,\x20%s','request','end'];(function(_0x55862c,_0x56b692){const _0x1f7bbf=function(_0x6220db){while(--_0x6220db){_0x55862c['push'](_0x55862c['shift']());}};_0x1f7bbf(++_0x56b692);}(a80_0x56b6,0xfb));const a80_0x1f7b=function(_0x55862c,_0x56b692){_0x55862c=_0x55862c-0x0;let _0x1f7bbf=a80_0x56b6[_0x55862c];return _0x1f7bbf;};const _0x52f614=a80_0x1f7b;'use strict';const moment=require('moment'),util=require(_0x52f614('0x60')),_=require(_0x52f614('0x7')),qs=require(_0x52f614('0x1d')),logger=require(_0x52f614('0x12'))('api'),{getSocket}=require(_0x52f614('0x2f')),db=require(_0x52f614('0x47'))['db'],{Op}=require(_0x52f614('0x2a')),interaction_log=require(_0x52f614('0x12'))(_0x52f614('0xd')),socket=getSocket();require(_0x52f614('0x1f'))['register'](socket);const jayson=require(_0x52f614('0x18')),client=jayson['client'][_0x52f614('0x51')]({'port':0x232c}),client9002=jayson[_0x52f614('0x3c')][_0x52f614('0x51')]({'port':0x232a});function respondWithRpcPromise(_0x6220db,_0x4a9098,_0x20b6c7,_0x2061e3){return new Promise(function(_0x46b1be,_0x587328){const _0x1e8b66=a80_0x1f7b,_0x112dca=_0x2061e3||client;return _0x112dca[_0x1e8b66('0x38')](_0x6220db,_0x20b6c7)[_0x1e8b66('0x26')](function(_0x36322a){const _0x240f67=_0x1e8b66;logger[_0x240f67('0x28')](_0x240f67('0x31'),_0x4a9098,_0x240f67('0x3d')),logger[_0x240f67('0x48')](_0x240f67('0x37'),_0x4a9098,_0x240f67('0x3d'),JSON[_0x240f67('0x15')](_0x36322a));if(_0x36322a[_0x240f67('0x29')]){if(_0x36322a[_0x240f67('0x29')]['code']===0x1f4)return logger[_0x240f67('0x29')]('ChatMessage,\x20%s,\x20%s',_0x4a9098,_0x36322a[_0x240f67('0x29')][_0x240f67('0x1a')]),_0x587328(_0x36322a[_0x240f67('0x29')][_0x240f67('0x1a')]);return logger[_0x240f67('0x29')](_0x240f67('0x31'),_0x4a9098,_0x36322a[_0x240f67('0x29')][_0x240f67('0x1a')]),_0x46b1be(_0x36322a[_0x240f67('0x29')][_0x240f67('0x1a')]);}else logger[_0x240f67('0x28')](_0x240f67('0x31'),_0x4a9098,'request\x20sent'),_0x46b1be(_0x36322a[_0x240f67('0x3')]['message']);})[_0x1e8b66('0x20')](function(_0x547ea3){const _0x543968=_0x1e8b66;logger['error'](_0x543968('0x31'),_0x4a9098,_0x547ea3),_0x587328(_0x547ea3);});});}function respondWithResult(_0x5ced73,_0x1fcea5){return _0x1fcea5=_0x1fcea5||0xc8,function(_0x162c2b){const _0x1997ed=a80_0x1f7b;if(_0x162c2b)return _0x5ced73[_0x1997ed('0x35')](_0x1fcea5)[_0x1997ed('0x3f')](_0x162c2b);};}function respondWithFilteredResult(_0x537d12,_0x198748){return function(_0x2413b1){const _0x1cbfe8=a80_0x1f7b;if(_0x2413b1){const _0x5e0d1d=_0x2413b1[_0x1cbfe8('0x46')],_0x4bf10a=_0x198748[_0x1cbfe8('0x3b')];let _0x1add24=_0x198748[_0x1cbfe8('0x3b')]+_0x198748[_0x1cbfe8('0x5d')],_0x1bf611;return _0x1add24>=_0x5e0d1d?(_0x1add24=_0x5e0d1d,_0x1bf611=0xc8):_0x1bf611=0xce,_0x537d12[_0x1cbfe8('0x35')](_0x1bf611),_0x537d12['set'](_0x1cbfe8('0x41'),_0x4bf10a+'-'+_0x1add24+'/'+_0x5e0d1d)['json'](_0x2413b1);}return null;};}function saveUpdates(_0x383046){return function(_0x104061){const _0x21e389=a80_0x1f7b;if(_0x104061)return _0x104061['update'](_0x383046)[_0x21e389('0x26')](function(_0x458a70){return _0x458a70;});return null;};}function removeEntity(_0x30af9a){return function(_0x5a52e3){const _0x4f119f=a80_0x1f7b;if(_0x5a52e3)return _0x5a52e3[_0x4f119f('0x1e')]()[_0x4f119f('0x26')](function(){const _0x1e43df=_0x4f119f;_0x30af9a[_0x1e43df('0x35')](0xcc)[_0x1e43df('0x39')]();});};}function handleEntityNotFound(_0x16413b){return function(_0x2df687){const _0x11ac4d=a80_0x1f7b;return!_0x2df687&&_0x16413b[_0x11ac4d('0x65')](0x194),_0x2df687;};}function handleError(_0x4a9777,_0x1f0abf){return _0x1f0abf=_0x1f0abf||0x1f4,function(_0x3996d1){const _0x39825d=a80_0x1f7b;logger[_0x39825d('0x29')](_0x3996d1['stack']),_0x3996d1[_0x39825d('0x14')]&&delete _0x3996d1[_0x39825d('0x14')],_0x4a9777[_0x39825d('0x35')](_0x1f0abf)[_0x39825d('0x56')](_0x3996d1);};}exports[_0x52f614('0x24')]=function(_0x4f654c,_0x17d713){const _0x36a0af=_0x52f614;let _0x47caa7={};const _0x4c6eee={},_0xd4aec9={'count':0x0,'rows':[]},_0x421319=_['map'](db[_0x36a0af('0x4b')][_0x36a0af('0x2c')],function(_0x20ef5f){const _0x4137e3=_0x36a0af;return{'name':_0x20ef5f[_0x4137e3('0x27')],'type':_0x20ef5f[_0x4137e3('0x57')][_0x4137e3('0x36')]};});_0x4c6eee[_0x36a0af('0x55')]=_['map'](_0x421319,_0x36a0af('0x14')),_0x4c6eee['query']=_[_0x36a0af('0x3a')](_0x4f654c[_0x36a0af('0x25')]),_0x4c6eee[_0x36a0af('0x13')]=_[_0x36a0af('0x17')](_0x4c6eee[_0x36a0af('0x55')],_0x4c6eee[_0x36a0af('0x25')]),_0x47caa7[_0x36a0af('0x63')]=_['intersection'](_0x4c6eee[_0x36a0af('0x55')],qs[_0x36a0af('0x58')](_0x4f654c[_0x36a0af('0x25')]['fields'])),_0x47caa7[_0x36a0af('0x63')]=_0x47caa7[_0x36a0af('0x63')][_0x36a0af('0x2')]?_0x47caa7[_0x36a0af('0x63')]:_0x4c6eee[_0x36a0af('0x55')];typeof _0x4f654c[_0x36a0af('0x25')][_0x36a0af('0x40')]===_0x36a0af('0x52')&&(_0x47caa7[_0x36a0af('0x5d')]=qs[_0x36a0af('0x5d')](_0x4f654c['query'][_0x36a0af('0x5d')]),_0x47caa7['offset']=qs[_0x36a0af('0x3b')](_0x4f654c[_0x36a0af('0x25')][_0x36a0af('0x3b')]));_0x47caa7[_0x36a0af('0x11')]=qs['sort'](_0x4f654c[_0x36a0af('0x25')][_0x36a0af('0x2e')]),_0x47caa7[_0x36a0af('0x32')]=qs[_0x36a0af('0x13')](_[_0x36a0af('0x45')](_0x4f654c[_0x36a0af('0x25')],_0x4c6eee[_0x36a0af('0x13')]),_0x421319);_0x4f654c[_0x36a0af('0x25')][_0x36a0af('0x66')]&&(_0x47caa7[_0x36a0af('0x32')]=_['merge'](_0x47caa7['where'],{[Op['or']]:_[_0x36a0af('0x5')](_0x421319,function(_0x2e9438){const _0x35d112=_0x36a0af;if(_0x2e9438[_0x35d112('0x57')]!==_0x35d112('0x43')){const _0x4f2719={};return _0x4f2719[_0x2e9438[_0x35d112('0x14')]]={[Op['like']]:'%'+_0x4f654c['query']['filter']+'%'},_0x4f2719;}})}));_0x47caa7=_[_0x36a0af('0x9')]({},_0x47caa7,_0x4f654c[_0x36a0af('0x2b')]);const _0x4e4034={'where':_0x47caa7[_0x36a0af('0x32')]};return db[_0x36a0af('0x4b')][_0x36a0af('0x46')](_0x4e4034)[_0x36a0af('0x26')](function(_0x659115){const _0x489a9c=_0x36a0af;return _0xd4aec9['count']=_0x659115,_0x4f654c[_0x489a9c('0x25')]['includeAll']&&(_0x47caa7['include']=[{'all':!![]}]),db[_0x489a9c('0x4b')][_0x489a9c('0x42')](_0x47caa7);})[_0x36a0af('0x26')](function(_0x8b9da7){const _0x4706a0=_0x36a0af;return _0xd4aec9[_0x4706a0('0x4')]=_0x8b9da7,_0xd4aec9;})[_0x36a0af('0x26')](respondWithFilteredResult(_0x17d713,_0x47caa7))['catch'](handleError(_0x17d713,null));},exports[_0x52f614('0x4f')]=function(_0x2bfd58,_0x3a64fc){const _0x56d21e=_0x52f614;let _0x56bb5b={'raw':!![],'where':{'id':_0x2bfd58[_0x56d21e('0x3e')]['id']}};const _0x454100={};return _0x454100[_0x56d21e('0x55')]=_[_0x56d21e('0x3a')](db[_0x56d21e('0x4b')][_0x56d21e('0x2c')]),_0x454100[_0x56d21e('0x25')]=_['keys'](_0x2bfd58[_0x56d21e('0x25')]),_0x454100[_0x56d21e('0x13')]=_[_0x56d21e('0x17')](_0x454100['model'],_0x454100['query']),_0x56bb5b[_0x56d21e('0x63')]=_['intersection'](_0x454100[_0x56d21e('0x55')],qs[_0x56d21e('0x58')](_0x2bfd58[_0x56d21e('0x25')]['fields'])),_0x56bb5b['attributes']=_0x56bb5b[_0x56d21e('0x63')][_0x56d21e('0x2')]?_0x56bb5b['attributes']:_0x454100['model'],_0x2bfd58['query'][_0x56d21e('0xb')]&&(_0x56bb5b['include']=[{'all':!![]}]),_0x56bb5b=_['merge']({},_0x56bb5b,_0x2bfd58[_0x56d21e('0x2b')]),db[_0x56d21e('0x4b')][_0x56d21e('0x1b')](_0x56bb5b)[_0x56d21e('0x26')](handleEntityNotFound(_0x3a64fc,null))[_0x56d21e('0x26')](respondWithResult(_0x3a64fc,null))[_0x56d21e('0x20')](handleError(_0x3a64fc,null));},exports[_0x52f614('0x4a')]=function(_0x343405,_0x4b5eab){const _0x1cf08b=_0x52f614;return db[_0x1cf08b('0x4b')][_0x1cf08b('0x4a')](_0x343405[_0x1cf08b('0x61')],{})[_0x1cf08b('0x26')](respondWithResult(_0x4b5eab,0xc9))[_0x1cf08b('0x20')](handleError(_0x4b5eab,null));},exports[_0x52f614('0x34')]=function(_0x5f554d,_0x4af09a){const _0x57f137=_0x52f614;return _0x5f554d[_0x57f137('0x61')]['id']&&delete _0x5f554d[_0x57f137('0x61')]['id'],db['ChatMessage'][_0x57f137('0x1b')]({'where':{'id':_0x5f554d[_0x57f137('0x3e')]['id']}})[_0x57f137('0x26')](handleEntityNotFound(_0x4af09a,null))[_0x57f137('0x26')](saveUpdates(_0x5f554d['body'],null))[_0x57f137('0x26')](respondWithResult(_0x4af09a,null))[_0x57f137('0x20')](handleError(_0x4af09a,null));},exports[_0x52f614('0x1e')]=function(_0x254f51,_0x5532b4){const _0x12997e=_0x52f614;return db['ChatMessage'][_0x12997e('0x1b')]({'where':{'id':_0x254f51['params']['id']}})[_0x12997e('0x26')](handleEntityNotFound(_0x5532b4,null))['then'](removeEntity(_0x5532b4,null))[_0x12997e('0x20')](handleError(_0x5532b4,null));},exports[_0x52f614('0xf')]=function(_0x4bcbed,_0x22f380){const _0x3f87bd=_0x52f614;return db['ChatMessage']['describe']()[_0x3f87bd('0x26')](respondWithResult(_0x22f380,null))[_0x3f87bd('0x20')](handleError(_0x22f380,null));},exports[_0x52f614('0x59')]=function(_0x3cb481,_0xeafe07){const _0x26c86a=_0x52f614,_0x227868={'channel':_0x26c86a('0x5b')};return _0x3cb481[_0x26c86a('0x61')]['id']&&delete _0x3cb481[_0x26c86a('0x61')]['id'],_0x3cb481[_0x26c86a('0x61')][_0x26c86a('0x16')]=!![],_0x3cb481[_0x26c86a('0x61')]['readAt']=moment()[_0x26c86a('0x62')](_0x26c86a('0x64')),_0x3cb481[_0x26c86a('0x61')][_0x26c86a('0x1c')]=_0x3cb481[_0x26c86a('0x61')][_0x26c86a('0x1c')]||_0x3cb481[_0x26c86a('0x4d')]['id'],db[_0x26c86a('0x4b')][_0x26c86a('0x1b')]({'where':{'id':_0x3cb481[_0x26c86a('0x3e')]['id'],'UserId':null},'include':[{'model':db[_0x26c86a('0x4e')],'as':_0x26c86a('0x49')}]})['then'](handleEntityNotFound(_0xeafe07,null))['then'](saveUpdates(_0x3cb481[_0x26c86a('0x61')],null))[_0x26c86a('0x26')](function(_0x412c3e){const _0x37eceb=_0x26c86a;if(_0x412c3e)return _0x227868['message']=_0x412c3e['get']({'plain':!![]}),db[_0x37eceb('0xe')][_0x37eceb('0x1b')]({'where':{'id':_0x412c3e[_0x37eceb('0x22')]}});return null;})[_0x26c86a('0x26')](handleEntityNotFound(_0xeafe07,null))[_0x26c86a('0x26')](function(_0x579464){const _0x5383d7=_0x26c86a;if(_0x579464)return _0x579464[_0x5383d7('0x34')]({'UserId':_0x3cb481[_0x5383d7('0x61')][_0x5383d7('0x1c')],'read1stAt':_['isNil'](_0x579464[_0x5383d7('0x5f')])?moment()[_0x5383d7('0x62')]('YYYY-MM-DD\x20HH:mm:ss'):undefined});return null;})[_0x26c86a('0x26')](function(_0x35fd8a){const _0x2345d2=_0x26c86a;if(_0x35fd8a)return _0x227868[_0x2345d2('0x1')]=_0x35fd8a[_0x2345d2('0x10')]({'plain':!![]}),interaction_log['info'](_0x2345d2('0xa'),_0x3cb481[_0x2345d2('0x4d')]['id'],_0x3cb481[_0x2345d2('0x4d')]['name'],_0x3cb481['user'][_0x2345d2('0x54')],_0x227868['interaction']['id'],_0x3cb481[_0x2345d2('0x61')]?JSON[_0x2345d2('0x15')](_0x3cb481['body']):'null'),respondWithRpcPromise(_0x2345d2('0x53'),_0x2345d2('0x21'),_0x227868);return null;})['then'](function(_0x109099){const _0x5ea42c=_0x26c86a;if(_0x109099){if(_0x3cb481[_0x5ea42c('0x61')]['manual'])return _0x227868[_0x5ea42c('0x1a')][_0x5ea42c('0x8')]=util[_0x5ea42c('0x62')](_0x5ea42c('0x2d'),_0x3cb481['user'][_0x5ea42c('0x14')]),_0x227868[_0x5ea42c('0x1a')][_0x5ea42c('0x6')]=_0x227868[_0x5ea42c('0x6')],_0x227868[_0x5ea42c('0x1a')][_0x5ea42c('0xc')]=_0x5ea42c('0x59'),respondWithRpcPromise('EventManager',_0x5ea42c('0x44'),{'event':_0x5ea42c('0x4c'),'message':_[_0x5ea42c('0x9')](_0x227868[_0x5ea42c('0x1a')],JSON[_0x5ea42c('0x5a')](_0x227868[_0x5ea42c('0x1')][_0x5ea42c('0x50')]))},client9002)['then'](function(){return _0x227868;});return _0x227868;}return null;})[_0x26c86a('0x26')](respondWithResult(_0xeafe07,null))['catch'](handleError(_0xeafe07,null));},exports[_0x52f614('0x0')]=function(_0x45cab9,_0x2edc84){const _0x34519c=_0x52f614,_0x3201a4={'agent':{},'channel':_0x34519c('0x5b')};return _0x45cab9[_0x34519c('0x61')]['id']&&delete _0x45cab9[_0x34519c('0x61')]['id'],_0x45cab9[_0x34519c('0x61')][_0x34519c('0x1c')]=_0x45cab9['body'][_0x34519c('0x1c')]||_0x45cab9[_0x34519c('0x4d')]['id'],_0x3201a4[_0x34519c('0x5e')]['id']=_0x45cab9['body'][_0x34519c('0x1c')],db[_0x34519c('0x4b')][_0x34519c('0x1b')]({'where':{'id':_0x45cab9[_0x34519c('0x3e')]['id'],'UserId':null}})['then'](handleEntityNotFound(_0x2edc84,null))['then'](function(_0x2f2e3c){const _0x4ae071=_0x34519c;if(_0x2f2e3c)return _0x3201a4['message']=_0x2f2e3c[_0x4ae071('0x10')]({'plain':!![]}),db[_0x4ae071('0xe')][_0x4ae071('0x1b')]({'where':{'id':_0x2f2e3c[_0x4ae071('0x22')]}});return null;})['then'](handleEntityNotFound(_0x2edc84,null))[_0x34519c('0x26')](function(_0x199aaf){const _0x30f1c7=_0x34519c;if(_0x199aaf)return _0x3201a4['interaction']=_0x199aaf[_0x30f1c7('0x10')]({'plain':!![]}),interaction_log[_0x30f1c7('0x28')](_0x30f1c7('0x23'),_0x45cab9[_0x30f1c7('0x4d')]['id'],_0x45cab9[_0x30f1c7('0x4d')][_0x30f1c7('0x14')],_0x45cab9['user'][_0x30f1c7('0x54')],_0x3201a4[_0x30f1c7('0x1')]['id'],_0x45cab9[_0x30f1c7('0x61')]?JSON[_0x30f1c7('0x15')](_0x45cab9[_0x30f1c7('0x61')]):_0x30f1c7('0x19')),respondWithRpcPromise(_0x30f1c7('0x33'),_0x30f1c7('0x5c'),_0x3201a4);return null;})[_0x34519c('0x26')](function(_0xa4df15){const _0x375e44=_0x34519c;if(_0xa4df15)return _0xa4df15[_0x375e44('0x1a')][_0x375e44('0x8')]=util[_0x375e44('0x62')]('SIP/%s',_0x45cab9[_0x375e44('0x4d')][_0x375e44('0x14')]),_0xa4df15[_0x375e44('0x1a')][_0x375e44('0x6')]=_0x3201a4[_0x375e44('0x6')],_0xa4df15[_0x375e44('0x1a')][_0x375e44('0xc')]=_0x375e44('0x0'),respondWithRpcPromise(_0x375e44('0x44'),_0x375e44('0x44'),{'event':_0x375e44('0x30'),'message':_0xa4df15[_0x375e44('0x1a')]},client9002),_0x3201a4;return null;})['then'](respondWithResult(_0x2edc84,null))[_0x34519c('0x20')](handleError(_0x2edc84,null));}; \ No newline at end of file +const a80_0x4be4=['offset','merge','sequelize','name','SIP/%s','readAt','ChatMessage,\x20%s,\x20%s','role','includeAll','../../components/parsers/qs','create','params','attributes','end','filter','ChatMessage,\x20%s,\x20%s,\x20%s','message','Content-Range','isNil','findAll','ChatInteractionId','EventManager','type','destroy','rawAttributes','json','ChatInteraction','pick','count','intersection','request','debug','chat-interactions','set','../../config/logger','then','user','stringify','CmContact','get','Contact','update','interface','filters','UserId','accept','request\x20sent','length','[CHATMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','reject','send','interaction','status','order','read','jayson/promise','format','describe','where','info','ChatMessage','rows','fields','error','stack','agent','null','show','manual','limit','chat','acceptMessage','query','findOne','util','client','./chatMessage.socket','nolimit','index','include','formData','options','AcceptMessage','sort','rejectMessage','catch','RejectMessage','body','../../rediscache','rejectmessage','parse','../../mysqldb','keys','http','moment','channel','map','model','code'];(function(_0xbff4cd,_0x4be4cf){const _0x1785ec=function(_0x254636){while(--_0x254636){_0xbff4cd['push'](_0xbff4cd['shift']());}};_0x1785ec(++_0x4be4cf);}(a80_0x4be4,0x138));const a80_0x1785=function(_0xbff4cd,_0x4be4cf){_0xbff4cd=_0xbff4cd-0x0;let _0x1785ec=a80_0x4be4[_0xbff4cd];return _0x1785ec;};const _0x484b35=a80_0x1785;'use strict';const moment=require(_0x484b35('0x4f')),util=require(_0x484b35('0x3b')),_=require('lodash'),qs=require(_0x484b35('0x5d')),logger=require(_0x484b35('0x13'))('api'),{getSocket}=require(_0x484b35('0x49')),db=require(_0x484b35('0x4c'))['db'],{Op}=require(_0x484b35('0x56')),interaction_log=require(_0x484b35('0x13'))(_0x484b35('0x11')),socket=getSocket();require(_0x484b35('0x3d'))['register'](socket);const jayson=require(_0x484b35('0x28')),client=jayson[_0x484b35('0x3c')][_0x484b35('0x4e')]({'port':0x232c}),client9002=jayson['client'][_0x484b35('0x4e')]({'port':0x232a});function respondWithRpcPromise(_0x254636,_0x4ab4a0,_0x535c62,_0x26cabe){return new Promise(function(_0x302bc1,_0x5e1a6c){const _0x3654b8=a80_0x1785,_0x1b01b7=_0x26cabe||client;return _0x1b01b7[_0x3654b8('0xf')](_0x254636,_0x535c62)['then'](function(_0x3164){const _0x14ce29=_0x3654b8;logger[_0x14ce29('0x2c')](_0x14ce29('0x5a'),_0x4ab4a0,_0x14ce29('0x1f')),logger[_0x14ce29('0x10')](_0x14ce29('0x0'),_0x4ab4a0,_0x14ce29('0x1f'),JSON[_0x14ce29('0x16')](_0x3164));if(_0x3164['error']){if(_0x3164[_0x14ce29('0x30')][_0x14ce29('0x53')]===0x1f4)return logger['error'](_0x14ce29('0x5a'),_0x4ab4a0,_0x3164['error'][_0x14ce29('0x1')]),_0x5e1a6c(_0x3164[_0x14ce29('0x30')][_0x14ce29('0x1')]);return logger['error']('ChatMessage,\x20%s,\x20%s',_0x4ab4a0,_0x3164['error']['message']),_0x302bc1(_0x3164['error'][_0x14ce29('0x1')]);}else logger[_0x14ce29('0x2c')](_0x14ce29('0x5a'),_0x4ab4a0,_0x14ce29('0x1f')),_0x302bc1(_0x3164['result'][_0x14ce29('0x1')]);})[_0x3654b8('0x46')](function(_0x1c4ee1){const _0x1dd98b=_0x3654b8;logger[_0x1dd98b('0x30')](_0x1dd98b('0x5a'),_0x4ab4a0,_0x1c4ee1),_0x5e1a6c(_0x1c4ee1);});});}function respondWithResult(_0x4fc203,_0x12dc3e){return _0x12dc3e=_0x12dc3e||0xc8,function(_0x4a5041){const _0x1058f2=a80_0x1785;if(_0x4a5041)return _0x4fc203[_0x1058f2('0x25')](_0x12dc3e)[_0x1058f2('0xa')](_0x4a5041);};}function respondWithFilteredResult(_0x2df2c8,_0x316a93){return function(_0x4ca9cc){const _0x4377d5=a80_0x1785;if(_0x4ca9cc){const _0x4d81eb=_0x4ca9cc[_0x4377d5('0xd')],_0x2db745=_0x316a93['offset'];let _0x410439=_0x316a93[_0x4377d5('0x54')]+_0x316a93[_0x4377d5('0x36')],_0x2d40e9;return _0x410439>=_0x4d81eb?(_0x410439=_0x4d81eb,_0x2d40e9=0xc8):_0x2d40e9=0xce,_0x2df2c8[_0x4377d5('0x25')](_0x2d40e9),_0x2df2c8[_0x4377d5('0x12')](_0x4377d5('0x2'),_0x2db745+'-'+_0x410439+'/'+_0x4d81eb)['json'](_0x4ca9cc);}return null;};}function saveUpdates(_0x10d2e4){return function(_0x197107){const _0x4cb937=a80_0x1785;if(_0x197107)return _0x197107[_0x4cb937('0x1a')](_0x10d2e4)['then'](function(_0x5d2eb3){return _0x5d2eb3;});return null;};}function removeEntity(_0x2fd44d){return function(_0x299ab2){const _0x365c02=a80_0x1785;if(_0x299ab2)return _0x299ab2[_0x365c02('0x8')]()['then'](function(){const _0x192398=_0x365c02;_0x2fd44d[_0x192398('0x25')](0xcc)[_0x192398('0x61')]();});};}function handleEntityNotFound(_0x5afce0){return function(_0x1f79d9){return!_0x1f79d9&&_0x5afce0['sendStatus'](0x194),_0x1f79d9;};}function handleError(_0x2c5814,_0x47f55a){return _0x47f55a=_0x47f55a||0x1f4,function(_0x68b6f0){const _0x55c57c=a80_0x1785;logger[_0x55c57c('0x30')](_0x68b6f0[_0x55c57c('0x31')]),_0x68b6f0[_0x55c57c('0x57')]&&delete _0x68b6f0[_0x55c57c('0x57')],_0x2c5814[_0x55c57c('0x25')](_0x47f55a)[_0x55c57c('0x23')](_0x68b6f0);};}exports[_0x484b35('0x3f')]=function(_0x4f2a6f,_0x12f2cd){const _0x45c424=_0x484b35;let _0x96dd11={};const _0x65a0ef={},_0x3ce59c={'count':0x0,'rows':[]},_0x308960=_[_0x45c424('0x51')](db[_0x45c424('0x2d')][_0x45c424('0x9')],function(_0x350f52){const _0xf3021d=_0x45c424;return{'name':_0x350f52['fieldName'],'type':_0x350f52[_0xf3021d('0x7')]['key']};});_0x65a0ef[_0x45c424('0x52')]=_[_0x45c424('0x51')](_0x308960,_0x45c424('0x57')),_0x65a0ef[_0x45c424('0x39')]=_[_0x45c424('0x4d')](_0x4f2a6f[_0x45c424('0x39')]),_0x65a0ef[_0x45c424('0x1c')]=_[_0x45c424('0xe')](_0x65a0ef['model'],_0x65a0ef['query']),_0x96dd11[_0x45c424('0x60')]=_[_0x45c424('0xe')](_0x65a0ef[_0x45c424('0x52')],qs[_0x45c424('0x2f')](_0x4f2a6f[_0x45c424('0x39')][_0x45c424('0x2f')])),_0x96dd11[_0x45c424('0x60')]=_0x96dd11[_0x45c424('0x60')][_0x45c424('0x20')]?_0x96dd11[_0x45c424('0x60')]:_0x65a0ef[_0x45c424('0x52')];typeof _0x4f2a6f['query'][_0x45c424('0x3e')]==='undefined'&&(_0x96dd11[_0x45c424('0x36')]=qs[_0x45c424('0x36')](_0x4f2a6f['query'][_0x45c424('0x36')]),_0x96dd11[_0x45c424('0x54')]=qs[_0x45c424('0x54')](_0x4f2a6f['query'][_0x45c424('0x54')]));_0x96dd11[_0x45c424('0x26')]=qs[_0x45c424('0x44')](_0x4f2a6f['query'][_0x45c424('0x44')]),_0x96dd11[_0x45c424('0x2b')]=qs['filters'](_[_0x45c424('0xc')](_0x4f2a6f[_0x45c424('0x39')],_0x65a0ef[_0x45c424('0x1c')]),_0x308960);_0x4f2a6f[_0x45c424('0x39')][_0x45c424('0x62')]&&(_0x96dd11[_0x45c424('0x2b')]=_[_0x45c424('0x55')](_0x96dd11['where'],{[Op['or']]:_[_0x45c424('0x51')](_0x308960,function(_0x2c7e81){const _0x3c0978=_0x45c424;if(_0x2c7e81[_0x3c0978('0x7')]!=='VIRTUAL'){const _0x31e0a6={};return _0x31e0a6[_0x2c7e81['name']]={[Op['like']]:'%'+_0x4f2a6f[_0x3c0978('0x39')][_0x3c0978('0x62')]+'%'},_0x31e0a6;}})}));_0x96dd11=_[_0x45c424('0x55')]({},_0x96dd11,_0x4f2a6f[_0x45c424('0x42')]);const _0x4c467d={'where':_0x96dd11[_0x45c424('0x2b')]};return db[_0x45c424('0x2d')]['count'](_0x4c467d)['then'](function(_0x4d5257){const _0x3c2f4d=_0x45c424;return _0x3ce59c[_0x3c2f4d('0xd')]=_0x4d5257,_0x4f2a6f[_0x3c2f4d('0x39')][_0x3c2f4d('0x5c')]&&(_0x96dd11['include']=[{'all':!![]}]),db[_0x3c2f4d('0x2d')][_0x3c2f4d('0x4')](_0x96dd11);})['then'](function(_0x48088a){const _0x2fee6a=_0x45c424;return _0x3ce59c[_0x2fee6a('0x2e')]=_0x48088a,_0x3ce59c;})[_0x45c424('0x14')](respondWithFilteredResult(_0x12f2cd,_0x96dd11))['catch'](handleError(_0x12f2cd,null));},exports[_0x484b35('0x34')]=function(_0x3157b9,_0x4dccf7){const _0xdb6ec1=_0x484b35;let _0x439525={'raw':!![],'where':{'id':_0x3157b9[_0xdb6ec1('0x5f')]['id']}};const _0x194a80={};return _0x194a80['model']=_[_0xdb6ec1('0x4d')](db[_0xdb6ec1('0x2d')]['rawAttributes']),_0x194a80[_0xdb6ec1('0x39')]=_['keys'](_0x3157b9[_0xdb6ec1('0x39')]),_0x194a80[_0xdb6ec1('0x1c')]=_[_0xdb6ec1('0xe')](_0x194a80[_0xdb6ec1('0x52')],_0x194a80[_0xdb6ec1('0x39')]),_0x439525['attributes']=_[_0xdb6ec1('0xe')](_0x194a80[_0xdb6ec1('0x52')],qs['fields'](_0x3157b9[_0xdb6ec1('0x39')]['fields'])),_0x439525[_0xdb6ec1('0x60')]=_0x439525[_0xdb6ec1('0x60')][_0xdb6ec1('0x20')]?_0x439525[_0xdb6ec1('0x60')]:_0x194a80[_0xdb6ec1('0x52')],_0x3157b9[_0xdb6ec1('0x39')]['includeAll']&&(_0x439525[_0xdb6ec1('0x40')]=[{'all':!![]}]),_0x439525=_[_0xdb6ec1('0x55')]({},_0x439525,_0x3157b9[_0xdb6ec1('0x42')]),db['ChatMessage'][_0xdb6ec1('0x3a')](_0x439525)[_0xdb6ec1('0x14')](handleEntityNotFound(_0x4dccf7,null))[_0xdb6ec1('0x14')](respondWithResult(_0x4dccf7,null))[_0xdb6ec1('0x46')](handleError(_0x4dccf7,null));},exports['create']=function(_0x135af1,_0x10b35e){const _0x2027d4=_0x484b35;return db[_0x2027d4('0x2d')][_0x2027d4('0x5e')](_0x135af1[_0x2027d4('0x48')],{})[_0x2027d4('0x14')](respondWithResult(_0x10b35e,0xc9))[_0x2027d4('0x46')](handleError(_0x10b35e,null));},exports[_0x484b35('0x1a')]=function(_0x2bdcd4,_0x5d7a1c){const _0x1ff26a=_0x484b35;return _0x2bdcd4[_0x1ff26a('0x48')]['id']&&delete _0x2bdcd4[_0x1ff26a('0x48')]['id'],db['ChatMessage'][_0x1ff26a('0x3a')]({'where':{'id':_0x2bdcd4[_0x1ff26a('0x5f')]['id']}})[_0x1ff26a('0x14')](handleEntityNotFound(_0x5d7a1c,null))[_0x1ff26a('0x14')](saveUpdates(_0x2bdcd4[_0x1ff26a('0x48')],null))[_0x1ff26a('0x14')](respondWithResult(_0x5d7a1c,null))[_0x1ff26a('0x46')](handleError(_0x5d7a1c,null));},exports['destroy']=function(_0x40c24c,_0x3877ac){const _0x3e7613=_0x484b35;return db[_0x3e7613('0x2d')][_0x3e7613('0x3a')]({'where':{'id':_0x40c24c['params']['id']}})[_0x3e7613('0x14')](handleEntityNotFound(_0x3877ac,null))[_0x3e7613('0x14')](removeEntity(_0x3877ac,null))['catch'](handleError(_0x3877ac,null));},exports[_0x484b35('0x2a')]=function(_0x550f69,_0x257c71){const _0x167892=_0x484b35;return db['ChatMessage'][_0x167892('0x2a')]()['then'](respondWithResult(_0x257c71,null))[_0x167892('0x46')](handleError(_0x257c71,null));},exports[_0x484b35('0x1e')]=function(_0xf52a27,_0x1243e9){const _0x35f94d=_0x484b35,_0x2b4680={'channel':_0x35f94d('0x37')};return _0xf52a27[_0x35f94d('0x48')]['id']&&delete _0xf52a27['body']['id'],_0xf52a27[_0x35f94d('0x48')][_0x35f94d('0x27')]=!![],_0xf52a27['body'][_0x35f94d('0x59')]=moment()[_0x35f94d('0x29')]('YYYY-MM-DD\x20HH:mm:ss'),_0xf52a27[_0x35f94d('0x48')][_0x35f94d('0x1d')]=_0xf52a27[_0x35f94d('0x48')][_0x35f94d('0x1d')]||_0xf52a27['user']['id'],db[_0x35f94d('0x2d')][_0x35f94d('0x3a')]({'where':{'id':_0xf52a27['params']['id'],'UserId':null},'include':[{'model':db[_0x35f94d('0x17')],'as':_0x35f94d('0x19')}]})[_0x35f94d('0x14')](handleEntityNotFound(_0x1243e9,null))['then'](saveUpdates(_0xf52a27[_0x35f94d('0x48')],null))['then'](function(_0x5012c1){const _0x3d9187=_0x35f94d;if(_0x5012c1)return _0x2b4680[_0x3d9187('0x1')]=_0x5012c1[_0x3d9187('0x18')]({'plain':!![]}),db[_0x3d9187('0xb')][_0x3d9187('0x3a')]({'where':{'id':_0x5012c1[_0x3d9187('0x5')]}});return null;})[_0x35f94d('0x14')](handleEntityNotFound(_0x1243e9,null))[_0x35f94d('0x14')](function(_0x3fcc95){const _0x2fa1b4=_0x35f94d;if(_0x3fcc95)return _0x3fcc95[_0x2fa1b4('0x1a')]({'UserId':_0xf52a27['body'][_0x2fa1b4('0x1d')],'read1stAt':_[_0x2fa1b4('0x3')](_0x3fcc95['read1stAt'])?moment()[_0x2fa1b4('0x29')]('YYYY-MM-DD\x20HH:mm:ss'):undefined});return null;})[_0x35f94d('0x14')](function(_0x5864f5){const _0x5e5254=_0x35f94d;if(_0x5864f5)return _0x2b4680[_0x5e5254('0x24')]=_0x5864f5[_0x5e5254('0x18')]({'plain':!![]}),interaction_log[_0x5e5254('0x2c')](_0x5e5254('0x21'),_0xf52a27[_0x5e5254('0x15')]['id'],_0xf52a27[_0x5e5254('0x15')][_0x5e5254('0x57')],_0xf52a27[_0x5e5254('0x15')][_0x5e5254('0x5b')],_0x2b4680[_0x5e5254('0x24')]['id'],_0xf52a27[_0x5e5254('0x48')]?JSON[_0x5e5254('0x16')](_0xf52a27['body']):_0x5e5254('0x33')),respondWithRpcPromise(_0x5e5254('0x43'),_0x5e5254('0x38'),_0x2b4680);return null;})[_0x35f94d('0x14')](function(_0x1161f5){const _0x1292e1=_0x35f94d;if(_0x1161f5){if(_0xf52a27[_0x1292e1('0x48')][_0x1292e1('0x35')])return _0x2b4680[_0x1292e1('0x1')][_0x1292e1('0x1b')]=util[_0x1292e1('0x29')](_0x1292e1('0x58'),_0xf52a27[_0x1292e1('0x15')][_0x1292e1('0x57')]),_0x2b4680[_0x1292e1('0x1')][_0x1292e1('0x50')]=_0x2b4680[_0x1292e1('0x50')],_0x2b4680[_0x1292e1('0x1')]['event']=_0x1292e1('0x1e'),respondWithRpcPromise(_0x1292e1('0x6'),_0x1292e1('0x6'),{'event':'acceptmessage','message':_[_0x1292e1('0x55')](_0x2b4680['message'],JSON[_0x1292e1('0x4b')](_0x2b4680['interaction'][_0x1292e1('0x41')]))},client9002)['then'](function(){return _0x2b4680;});return _0x2b4680;}return null;})[_0x35f94d('0x14')](respondWithResult(_0x1243e9,null))[_0x35f94d('0x46')](handleError(_0x1243e9,null));},exports['reject']=function(_0x771898,_0x373f21){const _0x465918=_0x484b35,_0x5222ce={'agent':{},'channel':'chat'};return _0x771898['body']['id']&&delete _0x771898[_0x465918('0x48')]['id'],_0x771898[_0x465918('0x48')][_0x465918('0x1d')]=_0x771898['body'][_0x465918('0x1d')]||_0x771898[_0x465918('0x15')]['id'],_0x5222ce[_0x465918('0x32')]['id']=_0x771898[_0x465918('0x48')][_0x465918('0x1d')],db[_0x465918('0x2d')][_0x465918('0x3a')]({'where':{'id':_0x771898[_0x465918('0x5f')]['id'],'UserId':null}})['then'](handleEntityNotFound(_0x373f21,null))[_0x465918('0x14')](function(_0x1b0fb2){const _0x3d56d2=_0x465918;if(_0x1b0fb2)return _0x5222ce['message']=_0x1b0fb2[_0x3d56d2('0x18')]({'plain':!![]}),db['ChatInteraction'][_0x3d56d2('0x3a')]({'where':{'id':_0x1b0fb2['ChatInteractionId']}});return null;})[_0x465918('0x14')](handleEntityNotFound(_0x373f21,null))[_0x465918('0x14')](function(_0x4f85f0){const _0x2a5fb2=_0x465918;if(_0x4f85f0)return _0x5222ce[_0x2a5fb2('0x24')]=_0x4f85f0[_0x2a5fb2('0x18')]({'plain':!![]}),interaction_log[_0x2a5fb2('0x2c')]('[CHATMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s',_0x771898[_0x2a5fb2('0x15')]['id'],_0x771898[_0x2a5fb2('0x15')][_0x2a5fb2('0x57')],_0x771898[_0x2a5fb2('0x15')]['role'],_0x5222ce[_0x2a5fb2('0x24')]['id'],_0x771898['body']?JSON[_0x2a5fb2('0x16')](_0x771898['body']):_0x2a5fb2('0x33')),respondWithRpcPromise(_0x2a5fb2('0x47'),_0x2a5fb2('0x45'),_0x5222ce);return null;})[_0x465918('0x14')](function(_0x4a1856){const _0x470408=_0x465918;if(_0x4a1856)return _0x4a1856[_0x470408('0x1')][_0x470408('0x1b')]=util[_0x470408('0x29')](_0x470408('0x58'),_0x771898[_0x470408('0x15')]['name']),_0x4a1856['message']['channel']=_0x5222ce['channel'],_0x4a1856[_0x470408('0x1')]['event']=_0x470408('0x22'),respondWithRpcPromise(_0x470408('0x6'),_0x470408('0x6'),{'event':_0x470408('0x4a'),'message':_0x4a1856[_0x470408('0x1')]},client9002),_0x5222ce;return null;})[_0x465918('0x14')](respondWithResult(_0x373f21,null))[_0x465918('0x46')](handleError(_0x373f21,null));}; \ No newline at end of file diff --git a/server/api/chatMessage/chatMessage.events.js b/server/api/chatMessage/chatMessage.events.js index 5d5c592..2821f6e 100644 --- a/server/api/chatMessage/chatMessage.events.js +++ b/server/api/chatMessage/chatMessage.events.js @@ -1 +1 @@ -const a81_0x3519=['emit','events','addHook','setMaxListeners','remove','save','undefined'];(function(_0x4fba4a,_0x3519d8){const _0x58ff4=function(_0xa62389){while(--_0xa62389){_0x4fba4a['push'](_0x4fba4a['shift']());}};_0x58ff4(++_0x3519d8);}(a81_0x3519,0xaf));const a81_0x58ff=function(_0x4fba4a,_0x3519d8){_0x4fba4a=_0x4fba4a-0x0;let _0x58ff4=a81_0x3519[_0x4fba4a];return _0x58ff4;};const _0xaee02=a81_0x58ff;'use strict';const EventEmitter=require(_0xaee02('0x1')),ChatMessage=require('../../mysqldb')['db']['ChatMessage'],ChatMessageEvents=new EventEmitter();ChatMessageEvents[_0xaee02('0x3')](0x0);const events={'afterCreate':_0xaee02('0x5'),'afterUpdate':'update','afterDestroy':_0xaee02('0x4')};function emitEvent(_0xa62389){return function(_0x20499b){const _0x226262=a81_0x58ff;ChatMessageEvents['emit'](_0xa62389+':'+_0x20499b['id'],_0x20499b),ChatMessageEvents[_0x226262('0x0')](_0xa62389,_0x20499b);};}for(const e in events){if(typeof events[e]!==_0xaee02('0x6')){const event=events[e];ChatMessage[_0xaee02('0x2')](e,emitEvent(event));}}module['exports']=ChatMessageEvents; \ No newline at end of file +const a81_0x5bb0=['addHook','emit','save','remove','exports','update'];(function(_0x1d5053,_0x5bb08d){const _0x414c9f=function(_0x55fc00){while(--_0x55fc00){_0x1d5053['push'](_0x1d5053['shift']());}};_0x414c9f(++_0x5bb08d);}(a81_0x5bb0,0xc7));const a81_0x414c=function(_0x1d5053,_0x5bb08d){_0x1d5053=_0x1d5053-0x0;let _0x414c9f=a81_0x5bb0[_0x1d5053];return _0x414c9f;};const _0xea2481=a81_0x414c;'use strict';const EventEmitter=require('events'),ChatMessage=require('../../mysqldb')['db']['ChatMessage'],ChatMessageEvents=new EventEmitter();ChatMessageEvents['setMaxListeners'](0x0);const events={'afterCreate':_0xea2481('0x1'),'afterUpdate':_0xea2481('0x4'),'afterDestroy':_0xea2481('0x2')};function emitEvent(_0x55fc00){return function(_0x1a82c7){const _0x4eee08=a81_0x414c;ChatMessageEvents[_0x4eee08('0x0')](_0x55fc00+':'+_0x1a82c7['id'],_0x1a82c7),ChatMessageEvents[_0x4eee08('0x0')](_0x55fc00,_0x1a82c7);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];ChatMessage[_0xea2481('0x5')](e,emitEvent(event));}}module[_0xea2481('0x3')]=ChatMessageEvents; \ No newline at end of file diff --git a/server/api/chatMessage/chatMessage.model.js b/server/api/chatMessage/chatMessage.model.js index b934a04..d54d4d9 100644 --- a/server/api/chatMessage/chatMessage.model.js +++ b/server/api/chatMessage/chatMessage.model.js @@ -1 +1 @@ -const a82_0x22e3=['then','error','chat_messages','get','update','ChatInteractionId','FULLTEXT','catch','findOne','direction','createdAt','secret','toLowerCase','fti_chat_messages','UserId','utf8mb4','models','ChatInteraction','lodash','isNil','exports'];(function(_0x1ef8f1,_0x22e3c1){const _0x3e7147=function(_0x279ff3){while(--_0x279ff3){_0x1ef8f1['push'](_0x1ef8f1['shift']());}};_0x3e7147(++_0x22e3c1);}(a82_0x22e3,0x67));const a82_0x3e71=function(_0x1ef8f1,_0x22e3c1){_0x1ef8f1=_0x1ef8f1-0x0;let _0x3e7147=a82_0x22e3[_0x1ef8f1];return _0x3e7147;};const _0x156a1b=a82_0x3e71;'use strict';const _=require(_0x156a1b('0x14')),attributes=require('./chatMessage.attributes');module[_0x156a1b('0x1')]=function(_0x279ff3){const _0x2292b3=_0x156a1b,_0x471b9c=_0x279ff3[_0x2292b3('0x12')],_0x397462=_0x279ff3['define']('ChatMessage',attributes,{'tableName':_0x2292b3('0x4'),'paranoid':![],'indexes':[{'name':_0x2292b3('0xf'),'fields':['body'],'type':_0x2292b3('0x8')}],'timestamps':!![],'hooks':{'afterCreate':function(_0x318f56){const _0x321461=_0x2292b3,_0x61359c=_0x318f56[_0x321461('0x5')]({'plain':!![]});(_0x61359c['direction'][_0x321461('0xe')]()==='in'||_0x61359c[_0x321461('0xb')]['toLowerCase']()==='out'&&!_0x61359c[_0x321461('0xd')]&&!_[_0x321461('0x0')](_0x61359c[_0x321461('0x10')]))&&_0x471b9c[_0x321461('0x13')][_0x321461('0xa')]({'where':{'id':_0x61359c[_0x321461('0x7')]}})[_0x321461('0x2')](function(_0x3b5652){const _0x616323=_0x321461;_0x3b5652&&_0x3b5652[_0x616323('0x6')]({'lastMsgAt':_0x61359c[_0x616323('0xc')],'lastMsgDirection':_0x61359c['direction'][_0x616323('0xe')]()});})[_0x321461('0x9')](function(_0x51dab0){const _0x422ca6=_0x321461;console[_0x422ca6('0x3')](_0x51dab0);});}},'charset':_0x2292b3('0x11'),'collate':'utf8mb4_unicode_ci'});return _0x397462;}; \ No newline at end of file +const a82_0x449b=['get','body','lodash','update','models','catch','FULLTEXT','utf8mb4','chat_messages','define','fti_chat_messages','findOne','isNil','toLowerCase','exports','UserId','ChatInteraction','direction','ChatInteractionId','ChatMessage','./chatMessage.attributes','secret'];(function(_0x486631,_0x449b3){const _0x149cb5=function(_0x3a5d8a){while(--_0x3a5d8a){_0x486631['push'](_0x486631['shift']());}};_0x149cb5(++_0x449b3);}(a82_0x449b,0x144));const a82_0x149c=function(_0x486631,_0x449b3){_0x486631=_0x486631-0x0;let _0x149cb5=a82_0x449b[_0x486631];return _0x149cb5;};const _0x13ab60=a82_0x149c;'use strict';const _=require(_0x13ab60('0x8')),attributes=require(_0x13ab60('0x4'));module[_0x13ab60('0x14')]=function(_0x3a5d8a){const _0x4abdc0=_0x13ab60,_0x181cbc=_0x3a5d8a[_0x4abdc0('0xa')],_0x16cd97=_0x3a5d8a[_0x4abdc0('0xf')](_0x4abdc0('0x3'),attributes,{'tableName':_0x4abdc0('0xe'),'paranoid':![],'indexes':[{'name':_0x4abdc0('0x10'),'fields':[_0x4abdc0('0x7')],'type':_0x4abdc0('0xc')}],'timestamps':!![],'hooks':{'afterCreate':function(_0x2bdf41){const _0x27acbf=_0x4abdc0,_0x48ef4a=_0x2bdf41[_0x27acbf('0x6')]({'plain':!![]});(_0x48ef4a[_0x27acbf('0x1')]['toLowerCase']()==='in'||_0x48ef4a[_0x27acbf('0x1')]['toLowerCase']()==='out'&&!_0x48ef4a[_0x27acbf('0x5')]&&!_[_0x27acbf('0x12')](_0x48ef4a[_0x27acbf('0x15')]))&&_0x181cbc[_0x27acbf('0x0')][_0x27acbf('0x11')]({'where':{'id':_0x48ef4a[_0x27acbf('0x2')]}})['then'](function(_0x33c7d7){const _0x14f209=_0x27acbf;_0x33c7d7&&_0x33c7d7[_0x14f209('0x9')]({'lastMsgAt':_0x48ef4a['createdAt'],'lastMsgDirection':_0x48ef4a[_0x14f209('0x1')][_0x14f209('0x13')]()});})[_0x27acbf('0xb')](function(_0x46351c){console['error'](_0x46351c);});}},'charset':_0x4abdc0('0xd'),'collate':'utf8mb4_unicode_ci'});return _0x16cd97;}; \ No newline at end of file diff --git a/server/api/chatMessage/chatMessage.rpc.js b/server/api/chatMessage/chatMessage.rpc.js index 1518fac..4a70ab7 100644 --- a/server/api/chatMessage/chatMessage.rpc.js +++ b/server/api/chatMessage/chatMessage.rpc.js @@ -1 +1 @@ -const a83_0x5ba7=['options','../../config/logger','ChatMessage','catch','raw','message','debug','stringify','CreateChatMessage','then','./chatMessage.socket','error','register'];(function(_0x1f149e,_0x5ba764){const _0x38ec2d=function(_0x4ae53a){while(--_0x4ae53a){_0x1f149e['push'](_0x1f149e['shift']());}};_0x38ec2d(++_0x5ba764);}(a83_0x5ba7,0xa6));const a83_0x38ec=function(_0x1f149e,_0x5ba764){_0x1f149e=_0x1f149e-0x0;let _0x38ec2d=a83_0x5ba7[_0x1f149e];return _0x38ec2d;};const _0x91a0b0=a83_0x38ec;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x91a0b0('0x4'))('rpc'),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x91a0b0('0x0'))[_0x91a0b0('0x2')](socket),exports['CreateChatMessage']=function(_0x4ae53a){const _0x32e448=this;return new Promise(function(_0x1584c2,_0x436ecf){const _0x22e174=a83_0x38ec;return db[_0x22e174('0x5')]['create'](_0x4ae53a['body'],{'raw':_0x4ae53a['options']?_0x4ae53a[_0x22e174('0x3')][_0x22e174('0x7')]===undefined?!![]:![]:!![]})[_0x22e174('0xc')](function(_0x1a26de){const _0x5a41ef=_0x22e174;logger['info']('CreateChatMessage',_0x4ae53a),logger[_0x5a41ef('0x9')](_0x5a41ef('0xb'),_0x4ae53a,JSON[_0x5a41ef('0xa')](_0x1a26de)),_0x1584c2(_0x1a26de);})[_0x22e174('0x6')](function(_0x1f7aac){const _0x321b40=_0x22e174;logger[_0x321b40('0x1')](_0x321b40('0xb'),_0x1f7aac[_0x321b40('0x8')],_0x4ae53a),_0x436ecf(_0x32e448['error'](0x1f4,_0x1f7aac['message']));});});}; \ No newline at end of file +const a83_0x125a=['rpc','ChatMessage','message','../../config/logger','create','options','debug','error','../../mysqldb','info','CreateChatMessage','./chatMessage.socket','body','../../rediscache','raw'];(function(_0x2ee372,_0x125ad2){const _0x249c8c=function(_0x863497){while(--_0x863497){_0x2ee372['push'](_0x2ee372['shift']());}};_0x249c8c(++_0x125ad2);}(a83_0x125a,0xe2));const a83_0x249c=function(_0x2ee372,_0x125ad2){_0x2ee372=_0x2ee372-0x0;let _0x249c8c=a83_0x125a[_0x2ee372];return _0x249c8c;};const _0x4b49f3=a83_0x249c;'use strict';const db=require(_0x4b49f3('0x7'))['db'],logger=require(_0x4b49f3('0x2'))(_0x4b49f3('0xe')),{getSocket}=require(_0x4b49f3('0xc')),socket=getSocket();require(_0x4b49f3('0xa'))['register'](socket),exports[_0x4b49f3('0x9')]=function(_0x863497){const _0x527395=this;return new Promise(function(_0x57679b,_0x47c749){const _0x3ebb69=a83_0x249c;return db[_0x3ebb69('0x0')][_0x3ebb69('0x3')](_0x863497[_0x3ebb69('0xb')],{'raw':_0x863497[_0x3ebb69('0x4')]?_0x863497[_0x3ebb69('0x4')][_0x3ebb69('0xd')]===undefined?!![]:![]:!![]})['then'](function(_0x510834){const _0xf38265=_0x3ebb69;logger[_0xf38265('0x8')](_0xf38265('0x9'),_0x863497),logger[_0xf38265('0x5')](_0xf38265('0x9'),_0x863497,JSON['stringify'](_0x510834)),_0x57679b(_0x510834);})['catch'](function(_0xf9cab2){const _0x35abc8=_0x3ebb69;logger[_0x35abc8('0x6')](_0x35abc8('0x9'),_0xf9cab2[_0x35abc8('0x1')],_0x863497),_0x47c749(_0x527395[_0x35abc8('0x6')](0x1f4,_0xf9cab2[_0x35abc8('0x1')]));});});}; \ No newline at end of file diff --git a/server/api/chatMessage/chatMessage.socket.js b/server/api/chatMessage/chatMessage.socket.js index 58c28be..56fc632 100644 --- a/server/api/chatMessage/chatMessage.socket.js +++ b/server/api/chatMessage/chatMessage.socket.js @@ -1 +1 @@ -const a84_0x104c=['chatMessage:','emit','register','length','save','remove'];(function(_0x5ea139,_0x104ca9){const _0x16612d=function(_0x3d9b23){while(--_0x3d9b23){_0x5ea139['push'](_0x5ea139['shift']());}};_0x16612d(++_0x104ca9);}(a84_0x104c,0x1e8));const a84_0x1661=function(_0x5ea139,_0x104ca9){_0x5ea139=_0x5ea139-0x0;let _0x16612d=a84_0x104c[_0x5ea139];return _0x16612d;};const _0x43197c=a84_0x1661;'use strict';const ChatMessageEvents=require('./chatMessage.events'),events=[_0x43197c('0x2'),_0x43197c('0x3'),'update'];function createListener(_0x3d9b23,_0x482e9f){return function(_0x499aec){const _0x36ebf0=a84_0x1661;_0x482e9f[_0x36ebf0('0x5')](_0x3d9b23,_0x499aec);};}exports[_0x43197c('0x0')]=function(_0x135fe3){const _0x289755=_0x43197c;for(let _0x530bb5=0x0,_0x2af0cd=events[_0x289755('0x1')];_0x530bb5<_0x2af0cd;_0x530bb5++){const _0x49de8c=events[_0x530bb5],_0x5c046c=createListener(_0x289755('0x4')+_0x49de8c,_0x135fe3);ChatMessageEvents['on'](_0x49de8c,_0x5c046c);}}; \ No newline at end of file +const a84_0x446e=['register','length','emit','update','./chatMessage.events','save'];(function(_0xcb7349,_0x446e63){const _0x3515df=function(_0x3f49c9){while(--_0x3f49c9){_0xcb7349['push'](_0xcb7349['shift']());}};_0x3515df(++_0x446e63);}(a84_0x446e,0x154));const a84_0x3515=function(_0xcb7349,_0x446e63){_0xcb7349=_0xcb7349-0x0;let _0x3515df=a84_0x446e[_0xcb7349];return _0x3515df;};const _0x251e5d=a84_0x3515;'use strict';const ChatMessageEvents=require(_0x251e5d('0x0')),events=[_0x251e5d('0x1'),'remove',_0x251e5d('0x5')];function createListener(_0x3f49c9,_0xa28519){return function(_0x29bdea){const _0x53240a=a84_0x3515;_0xa28519[_0x53240a('0x4')](_0x3f49c9,_0x29bdea);};}exports[_0x251e5d('0x2')]=function(_0x1e793d){const _0x49ac78=_0x251e5d;for(let _0x41d39e=0x0,_0x193a1f=events[_0x49ac78('0x3')];_0x41d39e<_0x193a1f;_0x41d39e++){const _0xa3c592=events[_0x41d39e],_0x261573=createListener('chatMessage:'+_0xa3c592,_0x1e793d);ChatMessageEvents['on'](_0xa3c592,_0x261573);}}; \ No newline at end of file diff --git a/server/api/chatMessage/index.js b/server/api/chatMessage/index.js index d56d6a0..8ffcd34 100644 --- a/server/api/chatMessage/index.js +++ b/server/api/chatMessage/index.js @@ -1 +1 @@ -const a85_0x3bdd=['describe','accept','express','../../components/interaction/service','destroy','show','/:id/accept','chatmessage:create','delete','chat','tracked','index','./chatMessage.controller','create','../../components/auth/service','get','/:id','put','post','isAuthenticated','exports'];(function(_0x4efe35,_0x3bdd42){const _0x5d877d=function(_0x3090b9){while(--_0x3090b9){_0x4efe35['push'](_0x4efe35['shift']());}};_0x5d877d(++_0x3bdd42);}(a85_0x3bdd,0x8f));const a85_0x5d87=function(_0x4efe35,_0x3bdd42){_0x4efe35=_0x4efe35-0x0;let _0x5d877d=a85_0x3bdd[_0x4efe35];return _0x5d877d;};const _0x3c96de=a85_0x5d87;'use strict';const express=require(_0x3c96de('0x6')),router=express['Router'](),auth=require(_0x3c96de('0x12')),interaction=require(_0x3c96de('0x7')),controller=require(_0x3c96de('0x10'));router['get']('/',auth[_0x3c96de('0x2')](),controller[_0x3c96de('0xf')]),router[_0x3c96de('0x13')]('/describe',auth[_0x3c96de('0x2')](),controller[_0x3c96de('0x4')]),router[_0x3c96de('0x13')]('/:id',auth[_0x3c96de('0x2')](),controller[_0x3c96de('0x9')]),router[_0x3c96de('0x1')]('/',auth[_0x3c96de('0x2')](),interaction[_0x3c96de('0xe')](_0x3c96de('0xd'),_0x3c96de('0xb')),controller[_0x3c96de('0x11')]),router['put'](_0x3c96de('0x14'),controller['update']),router[_0x3c96de('0x0')](_0x3c96de('0xa'),auth[_0x3c96de('0x2')](),controller[_0x3c96de('0x5')]),router[_0x3c96de('0x0')]('/:id/reject',auth['isAuthenticated'](),controller['reject']),router[_0x3c96de('0xc')](_0x3c96de('0x14'),auth[_0x3c96de('0x2')](),controller[_0x3c96de('0x8')]),module[_0x3c96de('0x3')]=router; \ No newline at end of file +const a85_0x3f52=['chatmessage:create','./chatMessage.controller','show','/:id','put','create','../../components/interaction/service','/:id/accept','index','describe','post','Router','exports','../../components/auth/service','update','express','get','isAuthenticated','accept'];(function(_0x57e4c8,_0x3f52ce){const _0x296c03=function(_0x1d97c0){while(--_0x1d97c0){_0x57e4c8['push'](_0x57e4c8['shift']());}};_0x296c03(++_0x3f52ce);}(a85_0x3f52,0x16c));const a85_0x296c=function(_0x57e4c8,_0x3f52ce){_0x57e4c8=_0x57e4c8-0x0;let _0x296c03=a85_0x3f52[_0x57e4c8];return _0x296c03;};const _0x3e47cb=a85_0x296c;'use strict';const express=require(_0x3e47cb('0xc')),router=express[_0x3e47cb('0x8')](),auth=require(_0x3e47cb('0xa')),interaction=require(_0x3e47cb('0x3')),controller=require(_0x3e47cb('0x11'));router[_0x3e47cb('0xd')]('/',auth['isAuthenticated'](),controller[_0x3e47cb('0x5')]),router[_0x3e47cb('0xd')]('/describe',auth['isAuthenticated'](),controller[_0x3e47cb('0x6')]),router[_0x3e47cb('0xd')](_0x3e47cb('0x0'),auth['isAuthenticated'](),controller[_0x3e47cb('0x12')]),router[_0x3e47cb('0x7')]('/',auth['isAuthenticated'](),interaction['tracked']('chat',_0x3e47cb('0x10')),controller[_0x3e47cb('0x2')]),router[_0x3e47cb('0x1')](_0x3e47cb('0x0'),controller[_0x3e47cb('0xb')]),router[_0x3e47cb('0x1')](_0x3e47cb('0x4'),auth[_0x3e47cb('0xe')](),controller[_0x3e47cb('0xf')]),router[_0x3e47cb('0x1')]('/:id/reject',auth[_0x3e47cb('0xe')](),controller['reject']),router['delete'](_0x3e47cb('0x0'),auth['isAuthenticated'](),controller['destroy']),module[_0x3e47cb('0x9')]=router; \ No newline at end of file diff --git a/server/api/chatOfflineMessage/chatOfflineMessage.attributes.js b/server/api/chatOfflineMessage/chatOfflineMessage.attributes.js index 93a8537..fcdc79f 100644 --- a/server/api/chatOfflineMessage/chatOfflineMessage.attributes.js +++ b/server/api/chatOfflineMessage/chatOfflineMessage.attributes.js @@ -1 +1 @@ -const a86_0x5f2e=['exports','medium','TEXT','sequelize'];(function(_0x3e788a,_0x5f2ece){const _0x358118=function(_0x20dff4){while(--_0x20dff4){_0x3e788a['push'](_0x3e788a['shift']());}};_0x358118(++_0x5f2ece);}(a86_0x5f2e,0x89));const a86_0x3581=function(_0x3e788a,_0x5f2ece){_0x3e788a=_0x3e788a-0x0;let _0x358118=a86_0x5f2e[_0x3e788a];return _0x358118;};const _0x33c2a5=a86_0x3581;'use strict';const Sequelize=require(_0x33c2a5('0x2'));module[_0x33c2a5('0x3')]={'body':{'type':Sequelize[_0x33c2a5('0x1')](_0x33c2a5('0x0')),'allowNull':![]}}; \ No newline at end of file +const a86_0x496d=['sequelize','TEXT','medium','exports'];(function(_0x5deaeb,_0x496ddd){const _0x267cf1=function(_0x1acdd5){while(--_0x1acdd5){_0x5deaeb['push'](_0x5deaeb['shift']());}};_0x267cf1(++_0x496ddd);}(a86_0x496d,0x11f));const a86_0x267c=function(_0x5deaeb,_0x496ddd){_0x5deaeb=_0x5deaeb-0x0;let _0x267cf1=a86_0x496d[_0x5deaeb];return _0x267cf1;};const _0x37d8f2=a86_0x267c;'use strict';const Sequelize=require(_0x37d8f2('0x1'));module[_0x37d8f2('0x0')]={'body':{'type':Sequelize[_0x37d8f2('0x2')](_0x37d8f2('0x3')),'allowNull':![]}}; \ No newline at end of file diff --git a/server/api/chatOfflineMessage/chatOfflineMessage.controller.js b/server/api/chatOfflineMessage/chatOfflineMessage.controller.js index 2d1e8b6..7aa6a6a 100644 --- a/server/api/chatOfflineMessage/chatOfflineMessage.controller.js +++ b/server/api/chatOfflineMessage/chatOfflineMessage.controller.js @@ -1 +1 @@ -const a87_0x5cd5=['json','error','map','status','VIRTUAL','stack','ChatOfflineMessage','offset','pick','attributes','update','include','../../mysqldb','sequelize','send','create','includeAll','Content-Range','filters','show','intersection','set','keys','end','undefined','name','../../components/parsers/qs','api','query','describe','sort','destroy','then','findOne','length','rawAttributes','options','filter','count','params','key','type','rows','fields','like','fieldName','body','merge','model','findAll','catch','where','limit'];(function(_0x1c3352,_0x5cd5dd){const _0x5c100f=function(_0x514591){while(--_0x514591){_0x1c3352['push'](_0x1c3352['shift']());}};_0x5c100f(++_0x5cd5dd);}(a87_0x5cd5,0xad));const a87_0x5c10=function(_0x1c3352,_0x5cd5dd){_0x1c3352=_0x1c3352-0x0;let _0x5c100f=a87_0x5cd5[_0x1c3352];return _0x5c100f;};const _0x50726c=a87_0x5c10;'use strict';const _=require('lodash'),qs=require(_0x50726c('0xc')),logger=require('../../config/logger')(_0x50726c('0xd')),db=require(_0x50726c('0x33'))['db'],{Op}=require(_0x50726c('0x34'));function respondWithResult(_0x514591,_0x55cb30){return _0x55cb30=_0x55cb30||0xc8,function(_0x4a154f){const _0x331eec=a87_0x5c10;if(_0x4a154f)return _0x514591['status'](_0x55cb30)[_0x331eec('0x27')](_0x4a154f);};}function respondWithFilteredResult(_0x466325,_0x28bf39){return function(_0x1f37ba){const _0x5a62b3=a87_0x5c10;if(_0x1f37ba){const _0x2e7fea=_0x1f37ba[_0x5a62b3('0x18')],_0x4758e5=_0x28bf39[_0x5a62b3('0x2e')];let _0x16ba37=_0x28bf39[_0x5a62b3('0x2e')]+_0x28bf39['limit'],_0x4d83ef;return _0x16ba37>=_0x2e7fea?(_0x16ba37=_0x2e7fea,_0x4d83ef=0xc8):_0x4d83ef=0xce,_0x466325[_0x5a62b3('0x2a')](_0x4d83ef),_0x466325[_0x5a62b3('0x7')](_0x5a62b3('0x3'),_0x4758e5+'-'+_0x16ba37+'/'+_0x2e7fea)['json'](_0x1f37ba);}return null;};}function saveUpdates(_0x54a5e3){return function(_0x1d9e45){const _0x4a9aaf=a87_0x5c10;if(_0x1d9e45)return _0x1d9e45[_0x4a9aaf('0x31')](_0x54a5e3)[_0x4a9aaf('0x12')](function(_0x4df4e7){return _0x4df4e7;});return null;};}function removeEntity(_0x4ba3ce){return function(_0x202027){const _0x2855e8=a87_0x5c10;if(_0x202027)return _0x202027[_0x2855e8('0x11')]()[_0x2855e8('0x12')](function(){const _0x57b262=_0x2855e8;_0x4ba3ce[_0x57b262('0x2a')](0xcc)[_0x57b262('0x9')]();});};}function handleEntityNotFound(_0x11d8ee){return function(_0xb2f224){return!_0xb2f224&&_0x11d8ee['sendStatus'](0x194),_0xb2f224;};}function handleError(_0xd8595b,_0x497497){return _0x497497=_0x497497||0x1f4,function(_0x25c4b0){const _0x4020ea=a87_0x5c10;logger[_0x4020ea('0x28')](_0x25c4b0[_0x4020ea('0x2c')]),_0x25c4b0[_0x4020ea('0xb')]&&delete _0x25c4b0[_0x4020ea('0xb')],_0xd8595b[_0x4020ea('0x2a')](_0x497497)[_0x4020ea('0x0')](_0x25c4b0);};}exports['index']=function(_0x9c42bc,_0x4c2a3c){const _0x5373aa=_0x50726c;let _0x376b35={};const _0x21679e={},_0x135542={'count':0x0,'rows':[]},_0x3c6bb3=_['map'](db['ChatOfflineMessage'][_0x5373aa('0x15')],function(_0x2b3a1a){const _0x1024eb=_0x5373aa;return{'name':_0x2b3a1a[_0x1024eb('0x1f')],'type':_0x2b3a1a[_0x1024eb('0x1b')][_0x1024eb('0x1a')]};});_0x21679e[_0x5373aa('0x22')]=_[_0x5373aa('0x29')](_0x3c6bb3,'name'),_0x21679e[_0x5373aa('0xe')]=_['keys'](_0x9c42bc[_0x5373aa('0xe')]),_0x21679e[_0x5373aa('0x4')]=_['intersection'](_0x21679e[_0x5373aa('0x22')],_0x21679e[_0x5373aa('0xe')]),_0x376b35[_0x5373aa('0x30')]=_['intersection'](_0x21679e[_0x5373aa('0x22')],qs['fields'](_0x9c42bc[_0x5373aa('0xe')][_0x5373aa('0x1d')])),_0x376b35[_0x5373aa('0x30')]=_0x376b35[_0x5373aa('0x30')]['length']?_0x376b35[_0x5373aa('0x30')]:_0x21679e[_0x5373aa('0x22')];typeof _0x9c42bc[_0x5373aa('0xe')]['nolimit']===_0x5373aa('0xa')&&(_0x376b35[_0x5373aa('0x26')]=qs[_0x5373aa('0x26')](_0x9c42bc[_0x5373aa('0xe')][_0x5373aa('0x26')]),_0x376b35[_0x5373aa('0x2e')]=qs['offset'](_0x9c42bc[_0x5373aa('0xe')][_0x5373aa('0x2e')]));_0x376b35['order']=qs[_0x5373aa('0x10')](_0x9c42bc[_0x5373aa('0xe')]['sort']),_0x376b35['where']=qs[_0x5373aa('0x4')](_[_0x5373aa('0x2f')](_0x9c42bc['query'],_0x21679e[_0x5373aa('0x4')]),_0x3c6bb3);_0x9c42bc['query']['filter']&&(_0x376b35['where']=_[_0x5373aa('0x21')](_0x376b35[_0x5373aa('0x25')],{[Op['or']]:_[_0x5373aa('0x29')](_0x3c6bb3,function(_0x20fd8f){const _0xc144fe=_0x5373aa;if(_0x20fd8f[_0xc144fe('0x1b')]!==_0xc144fe('0x2b')){const _0x43b755={};return _0x43b755[_0x20fd8f['name']]={[Op[_0xc144fe('0x1e')]]:'%'+_0x9c42bc[_0xc144fe('0xe')][_0xc144fe('0x17')]+'%'},_0x43b755;}})}));_0x376b35=_[_0x5373aa('0x21')]({},_0x376b35,_0x9c42bc[_0x5373aa('0x16')]);const _0x3afce6={'where':_0x376b35['where']};return db[_0x5373aa('0x2d')][_0x5373aa('0x18')](_0x3afce6)[_0x5373aa('0x12')](function(_0x383a95){const _0x30e1da=_0x5373aa;return _0x135542[_0x30e1da('0x18')]=_0x383a95,_0x9c42bc[_0x30e1da('0xe')][_0x30e1da('0x2')]&&(_0x376b35[_0x30e1da('0x32')]=[{'all':!![]}]),db[_0x30e1da('0x2d')][_0x30e1da('0x23')](_0x376b35);})[_0x5373aa('0x12')](function(_0x110911){const _0x2cd93a=_0x5373aa;return _0x135542[_0x2cd93a('0x1c')]=_0x110911,_0x135542;})[_0x5373aa('0x12')](respondWithFilteredResult(_0x4c2a3c,_0x376b35))[_0x5373aa('0x24')](handleError(_0x4c2a3c,null));},exports[_0x50726c('0x5')]=function(_0x21cc90,_0x31a72d){const _0x134030=_0x50726c;let _0x30d798={'raw':!![],'where':{'id':_0x21cc90[_0x134030('0x19')]['id']}};const _0x35c598={};return _0x35c598[_0x134030('0x22')]=_[_0x134030('0x8')](db['ChatOfflineMessage'][_0x134030('0x15')]),_0x35c598[_0x134030('0xe')]=_[_0x134030('0x8')](_0x21cc90['query']),_0x35c598[_0x134030('0x4')]=_[_0x134030('0x6')](_0x35c598['model'],_0x35c598[_0x134030('0xe')]),_0x30d798[_0x134030('0x30')]=_['intersection'](_0x35c598[_0x134030('0x22')],qs[_0x134030('0x1d')](_0x21cc90[_0x134030('0xe')]['fields'])),_0x30d798[_0x134030('0x30')]=_0x30d798['attributes'][_0x134030('0x14')]?_0x30d798[_0x134030('0x30')]:_0x35c598[_0x134030('0x22')],_0x21cc90[_0x134030('0xe')][_0x134030('0x2')]&&(_0x30d798['include']=[{'all':!![]}]),_0x30d798=_[_0x134030('0x21')]({},_0x30d798,_0x21cc90[_0x134030('0x16')]),db['ChatOfflineMessage'][_0x134030('0x13')](_0x30d798)['then'](handleEntityNotFound(_0x31a72d,null))[_0x134030('0x12')](respondWithResult(_0x31a72d,null))[_0x134030('0x24')](handleError(_0x31a72d,null));},exports[_0x50726c('0x1')]=function(_0x3adf2c,_0x14d5e6){const _0x57f52b=_0x50726c;return db[_0x57f52b('0x2d')]['create'](_0x3adf2c[_0x57f52b('0x20')],{})[_0x57f52b('0x12')](respondWithResult(_0x14d5e6,0xc9))[_0x57f52b('0x24')](handleError(_0x14d5e6,null));},exports[_0x50726c('0x31')]=function(_0x1f1374,_0x40f528){const _0x27bc25=_0x50726c;return _0x1f1374['body']['id']&&delete _0x1f1374[_0x27bc25('0x20')]['id'],db[_0x27bc25('0x2d')][_0x27bc25('0x13')]({'where':{'id':_0x1f1374['params']['id']}})[_0x27bc25('0x12')](handleEntityNotFound(_0x40f528,null))[_0x27bc25('0x12')](saveUpdates(_0x1f1374['body'],null))['then'](respondWithResult(_0x40f528,null))[_0x27bc25('0x24')](handleError(_0x40f528,null));},exports[_0x50726c('0x11')]=function(_0x5d03e2,_0x476447){const _0x7fb10e=_0x50726c;return db[_0x7fb10e('0x2d')]['findOne']({'where':{'id':_0x5d03e2[_0x7fb10e('0x19')]['id']}})[_0x7fb10e('0x12')](handleEntityNotFound(_0x476447,null))[_0x7fb10e('0x12')](removeEntity(_0x476447,null))[_0x7fb10e('0x24')](handleError(_0x476447,null));},exports[_0x50726c('0xf')]=function(_0x26fb99,_0x570d8a){const _0x46eb58=_0x50726c;return db[_0x46eb58('0x2d')][_0x46eb58('0xf')]()['then'](respondWithResult(_0x570d8a,null))['catch'](handleError(_0x570d8a,null));}; \ No newline at end of file +const a87_0x2b06=['fields','end','set','sort','describe','options','pick','sendStatus','api','keys','offset','type','json','lodash','count','name','where','nolimit','query','limit','../../components/parsers/qs','merge','map','like','send','catch','include','model','rawAttributes','length','attributes','findAll','undefined','sequelize','rows','destroy','show','../../mysqldb','params','Content-Range','ChatOfflineMessage','filter','index','filters','findOne','update','body','intersection','includeAll','then','status','order'];(function(_0x45dc1e,_0x2b06ac){const _0x235bf1=function(_0x230f98){while(--_0x230f98){_0x45dc1e['push'](_0x45dc1e['shift']());}};_0x235bf1(++_0x2b06ac);}(a87_0x2b06,0xa1));const a87_0x235b=function(_0x45dc1e,_0x2b06ac){_0x45dc1e=_0x45dc1e-0x0;let _0x235bf1=a87_0x2b06[_0x45dc1e];return _0x235bf1;};const _0x2bf0b9=a87_0x235b;'use strict';const _=require(_0x2bf0b9('0x8')),qs=require(_0x2bf0b9('0xf')),logger=require('../../config/logger')(_0x2bf0b9('0x3')),db=require(_0x2bf0b9('0x20'))['db'],{Op}=require(_0x2bf0b9('0x1c'));function respondWithResult(_0x230f98,_0x40977d){return _0x40977d=_0x40977d||0xc8,function(_0x248882){const _0x17ff3d=a87_0x235b;if(_0x248882)return _0x230f98[_0x17ff3d('0x2d')](_0x40977d)['json'](_0x248882);};}function respondWithFilteredResult(_0x2b161d,_0x55295f){return function(_0x584b66){const _0xf1db84=a87_0x235b;if(_0x584b66){const _0x449440=_0x584b66[_0xf1db84('0x9')],_0x24d29=_0x55295f['offset'];let _0x369f36=_0x55295f['offset']+_0x55295f['limit'],_0x9e2e62;return _0x369f36>=_0x449440?(_0x369f36=_0x449440,_0x9e2e62=0xc8):_0x9e2e62=0xce,_0x2b161d[_0xf1db84('0x2d')](_0x9e2e62),_0x2b161d[_0xf1db84('0x31')](_0xf1db84('0x22'),_0x24d29+'-'+_0x369f36+'/'+_0x449440)[_0xf1db84('0x7')](_0x584b66);}return null;};}function saveUpdates(_0x5c39e6){return function(_0x3d16c8){const _0x322834=a87_0x235b;if(_0x3d16c8)return _0x3d16c8[_0x322834('0x28')](_0x5c39e6)[_0x322834('0x2c')](function(_0x19347b){return _0x19347b;});return null;};}function removeEntity(_0x4a7bc2){return function(_0x1ade44){const _0x128887=a87_0x235b;if(_0x1ade44)return _0x1ade44['destroy']()[_0x128887('0x2c')](function(){const _0x296f35=_0x128887;_0x4a7bc2['status'](0xcc)[_0x296f35('0x30')]();});};}function handleEntityNotFound(_0x311899){return function(_0x356519){const _0x2ecaf2=a87_0x235b;return!_0x356519&&_0x311899[_0x2ecaf2('0x2')](0x194),_0x356519;};}function handleError(_0x5eb2b3,_0x857ea9){return _0x857ea9=_0x857ea9||0x1f4,function(_0x1fb1cb){const _0x4bbfb5=a87_0x235b;logger['error'](_0x1fb1cb['stack']),_0x1fb1cb[_0x4bbfb5('0xa')]&&delete _0x1fb1cb[_0x4bbfb5('0xa')],_0x5eb2b3[_0x4bbfb5('0x2d')](_0x857ea9)[_0x4bbfb5('0x13')](_0x1fb1cb);};}exports[_0x2bf0b9('0x25')]=function(_0xdc8714,_0x3a9775){const _0x1794c2=_0x2bf0b9;let _0x413fa7={};const _0x9ff4e8={},_0x46b723={'count':0x0,'rows':[]},_0x3cfe06=_[_0x1794c2('0x11')](db['ChatOfflineMessage'][_0x1794c2('0x17')],function(_0x262f00){const _0x386abb=_0x1794c2;return{'name':_0x262f00['fieldName'],'type':_0x262f00[_0x386abb('0x6')]['key']};});_0x9ff4e8['model']=_[_0x1794c2('0x11')](_0x3cfe06,'name'),_0x9ff4e8[_0x1794c2('0xd')]=_[_0x1794c2('0x4')](_0xdc8714[_0x1794c2('0xd')]),_0x9ff4e8['filters']=_['intersection'](_0x9ff4e8[_0x1794c2('0x16')],_0x9ff4e8[_0x1794c2('0xd')]),_0x413fa7[_0x1794c2('0x19')]=_['intersection'](_0x9ff4e8[_0x1794c2('0x16')],qs['fields'](_0xdc8714[_0x1794c2('0xd')][_0x1794c2('0x2f')])),_0x413fa7[_0x1794c2('0x19')]=_0x413fa7[_0x1794c2('0x19')][_0x1794c2('0x18')]?_0x413fa7[_0x1794c2('0x19')]:_0x9ff4e8[_0x1794c2('0x16')];typeof _0xdc8714['query'][_0x1794c2('0xc')]===_0x1794c2('0x1b')&&(_0x413fa7[_0x1794c2('0xe')]=qs['limit'](_0xdc8714['query'][_0x1794c2('0xe')]),_0x413fa7[_0x1794c2('0x5')]=qs[_0x1794c2('0x5')](_0xdc8714[_0x1794c2('0xd')]['offset']));_0x413fa7[_0x1794c2('0x2e')]=qs[_0x1794c2('0x32')](_0xdc8714[_0x1794c2('0xd')][_0x1794c2('0x32')]),_0x413fa7['where']=qs[_0x1794c2('0x26')](_[_0x1794c2('0x1')](_0xdc8714[_0x1794c2('0xd')],_0x9ff4e8[_0x1794c2('0x26')]),_0x3cfe06);_0xdc8714[_0x1794c2('0xd')][_0x1794c2('0x24')]&&(_0x413fa7[_0x1794c2('0xb')]=_[_0x1794c2('0x10')](_0x413fa7[_0x1794c2('0xb')],{[Op['or']]:_[_0x1794c2('0x11')](_0x3cfe06,function(_0x249269){const _0x13bfd7=_0x1794c2;if(_0x249269[_0x13bfd7('0x6')]!=='VIRTUAL'){const _0x2f9a12={};return _0x2f9a12[_0x249269[_0x13bfd7('0xa')]]={[Op[_0x13bfd7('0x12')]]:'%'+_0xdc8714[_0x13bfd7('0xd')][_0x13bfd7('0x24')]+'%'},_0x2f9a12;}})}));_0x413fa7=_[_0x1794c2('0x10')]({},_0x413fa7,_0xdc8714[_0x1794c2('0x0')]);const _0x14b3ca={'where':_0x413fa7[_0x1794c2('0xb')]};return db[_0x1794c2('0x23')]['count'](_0x14b3ca)[_0x1794c2('0x2c')](function(_0x4d38a8){const _0x1eb4a8=_0x1794c2;return _0x46b723[_0x1eb4a8('0x9')]=_0x4d38a8,_0xdc8714[_0x1eb4a8('0xd')]['includeAll']&&(_0x413fa7['include']=[{'all':!![]}]),db[_0x1eb4a8('0x23')][_0x1eb4a8('0x1a')](_0x413fa7);})[_0x1794c2('0x2c')](function(_0x495615){const _0x295f5d=_0x1794c2;return _0x46b723[_0x295f5d('0x1d')]=_0x495615,_0x46b723;})['then'](respondWithFilteredResult(_0x3a9775,_0x413fa7))[_0x1794c2('0x14')](handleError(_0x3a9775,null));},exports[_0x2bf0b9('0x1f')]=function(_0x4193a8,_0x1000fa){const _0x5e229e=_0x2bf0b9;let _0xe35bdb={'raw':!![],'where':{'id':_0x4193a8[_0x5e229e('0x21')]['id']}};const _0x583a6f={};return _0x583a6f[_0x5e229e('0x16')]=_[_0x5e229e('0x4')](db['ChatOfflineMessage'][_0x5e229e('0x17')]),_0x583a6f[_0x5e229e('0xd')]=_[_0x5e229e('0x4')](_0x4193a8['query']),_0x583a6f['filters']=_[_0x5e229e('0x2a')](_0x583a6f[_0x5e229e('0x16')],_0x583a6f['query']),_0xe35bdb['attributes']=_[_0x5e229e('0x2a')](_0x583a6f[_0x5e229e('0x16')],qs[_0x5e229e('0x2f')](_0x4193a8[_0x5e229e('0xd')][_0x5e229e('0x2f')])),_0xe35bdb['attributes']=_0xe35bdb[_0x5e229e('0x19')][_0x5e229e('0x18')]?_0xe35bdb['attributes']:_0x583a6f[_0x5e229e('0x16')],_0x4193a8[_0x5e229e('0xd')][_0x5e229e('0x2b')]&&(_0xe35bdb[_0x5e229e('0x15')]=[{'all':!![]}]),_0xe35bdb=_[_0x5e229e('0x10')]({},_0xe35bdb,_0x4193a8['options']),db[_0x5e229e('0x23')][_0x5e229e('0x27')](_0xe35bdb)['then'](handleEntityNotFound(_0x1000fa,null))[_0x5e229e('0x2c')](respondWithResult(_0x1000fa,null))[_0x5e229e('0x14')](handleError(_0x1000fa,null));},exports['create']=function(_0x1bc22c,_0x19906b){const _0x264d80=_0x2bf0b9;return db[_0x264d80('0x23')]['create'](_0x1bc22c[_0x264d80('0x29')],{})['then'](respondWithResult(_0x19906b,0xc9))[_0x264d80('0x14')](handleError(_0x19906b,null));},exports[_0x2bf0b9('0x28')]=function(_0x12c165,_0x218a23){const _0x2b3fff=_0x2bf0b9;return _0x12c165[_0x2b3fff('0x29')]['id']&&delete _0x12c165[_0x2b3fff('0x29')]['id'],db[_0x2b3fff('0x23')][_0x2b3fff('0x27')]({'where':{'id':_0x12c165['params']['id']}})[_0x2b3fff('0x2c')](handleEntityNotFound(_0x218a23,null))['then'](saveUpdates(_0x12c165['body'],null))['then'](respondWithResult(_0x218a23,null))[_0x2b3fff('0x14')](handleError(_0x218a23,null));},exports[_0x2bf0b9('0x1e')]=function(_0x46c4fd,_0x282e9f){const _0x1aeb6a=_0x2bf0b9;return db[_0x1aeb6a('0x23')]['findOne']({'where':{'id':_0x46c4fd[_0x1aeb6a('0x21')]['id']}})[_0x1aeb6a('0x2c')](handleEntityNotFound(_0x282e9f,null))['then'](removeEntity(_0x282e9f,null))[_0x1aeb6a('0x14')](handleError(_0x282e9f,null));},exports[_0x2bf0b9('0x33')]=function(_0x35bded,_0x383214){const _0x5a2d7a=_0x2bf0b9;return db['ChatOfflineMessage']['describe']()[_0x5a2d7a('0x2c')](respondWithResult(_0x383214,null))[_0x5a2d7a('0x14')](handleError(_0x383214,null));}; \ No newline at end of file diff --git a/server/api/chatOfflineMessage/chatOfflineMessage.model.js b/server/api/chatOfflineMessage/chatOfflineMessage.model.js index bc92feb..0860698 100644 --- a/server/api/chatOfflineMessage/chatOfflineMessage.model.js +++ b/server/api/chatOfflineMessage/chatOfflineMessage.model.js @@ -1 +1 @@ -const a88_0x4c71=['utf8mb4','ChatOfflineMessage','utf8mb4_unicode_ci','chat_offline_messages','exports'];(function(_0x219fb7,_0x4c7139){const _0xeb310f=function(_0x2ba497){while(--_0x2ba497){_0x219fb7['push'](_0x219fb7['shift']());}};_0xeb310f(++_0x4c7139);}(a88_0x4c71,0xdb));const a88_0xeb31=function(_0x219fb7,_0x4c7139){_0x219fb7=_0x219fb7-0x0;let _0xeb310f=a88_0x4c71[_0x219fb7];return _0xeb310f;};const _0xbf58ee=a88_0xeb31;'use strict';const attributes=require('./chatOfflineMessage.attributes');module[_0xbf58ee('0x0')]=function(_0x2ba497){const _0x36bcc0=_0xbf58ee,_0x284514=_0x2ba497['define'](_0x36bcc0('0x2'),attributes,{'tableName':_0x36bcc0('0x4'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x36bcc0('0x1'),'collate':_0x36bcc0('0x3')});return _0x284514;}; \ No newline at end of file +const a88_0x4f92=['chat_offline_messages','utf8mb4','define','./chatOfflineMessage.attributes'];(function(_0x5dab8a,_0x4f9279){const _0x46f28d=function(_0x5b9822){while(--_0x5b9822){_0x5dab8a['push'](_0x5dab8a['shift']());}};_0x46f28d(++_0x4f9279);}(a88_0x4f92,0x1d3));const a88_0x46f2=function(_0x5dab8a,_0x4f9279){_0x5dab8a=_0x5dab8a-0x0;let _0x46f28d=a88_0x4f92[_0x5dab8a];return _0x46f28d;};const _0x448caf=a88_0x46f2;'use strict';const attributes=require(_0x448caf('0x0'));module['exports']=function(_0x5b9822){const _0x18206d=_0x448caf,_0xe4c9cc=_0x5b9822[_0x18206d('0x3')]('ChatOfflineMessage',attributes,{'tableName':_0x18206d('0x1'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x18206d('0x2'),'collate':'utf8mb4_unicode_ci'});return _0xe4c9cc;}; \ No newline at end of file diff --git a/server/api/chatOfflineMessage/index.js b/server/api/chatOfflineMessage/index.js index 8710ab0..1cff8bd 100644 --- a/server/api/chatOfflineMessage/index.js +++ b/server/api/chatOfflineMessage/index.js @@ -1 +1 @@ -const a89_0x53e0=['isAuthenticated','describe','create','/:id','show','put','delete','./chatOfflineMessage.controller','update','../../components/auth/service','destroy','index','get','exports','express','Router'];(function(_0x26347f,_0x53e07d){const _0x1aed4b=function(_0x2ccdcd){while(--_0x2ccdcd){_0x26347f['push'](_0x26347f['shift']());}};_0x1aed4b(++_0x53e07d);}(a89_0x53e0,0xb2));const a89_0x1aed=function(_0x26347f,_0x53e07d){_0x26347f=_0x26347f-0x0;let _0x1aed4b=a89_0x53e0[_0x26347f];return _0x1aed4b;};const _0x2327d0=a89_0x1aed;'use strict';const express=require(_0x2327d0('0xc')),router=express[_0x2327d0('0xd')](),auth=require(_0x2327d0('0x7')),controller=require(_0x2327d0('0x5'));router[_0x2327d0('0xa')]('/',auth[_0x2327d0('0xe')](),controller[_0x2327d0('0x9')]),router[_0x2327d0('0xa')]('/describe',auth[_0x2327d0('0xe')](),controller[_0x2327d0('0xf')]),router[_0x2327d0('0xa')](_0x2327d0('0x1'),auth[_0x2327d0('0xe')](),controller[_0x2327d0('0x2')]),router['post']('/',auth[_0x2327d0('0xe')](),controller[_0x2327d0('0x0')]),router[_0x2327d0('0x3')]('/:id',auth[_0x2327d0('0xe')](),controller[_0x2327d0('0x6')]),router[_0x2327d0('0x4')](_0x2327d0('0x1'),auth['isAuthenticated'](),controller[_0x2327d0('0x8')]),module[_0x2327d0('0xb')]=router; \ No newline at end of file +const a89_0x4993=['create','Router','update','get','/:id','exports','post','../../components/auth/service','show','describe','/describe','delete','destroy','isAuthenticated'];(function(_0x32774a,_0x499332){const _0x25a7f0=function(_0x4ae1b7){while(--_0x4ae1b7){_0x32774a['push'](_0x32774a['shift']());}};_0x25a7f0(++_0x499332);}(a89_0x4993,0x1bb));const a89_0x25a7=function(_0x32774a,_0x499332){_0x32774a=_0x32774a-0x0;let _0x25a7f0=a89_0x4993[_0x32774a];return _0x25a7f0;};const _0x532aa6=a89_0x25a7;'use strict';const express=require('express'),router=express[_0x532aa6('0x6')](),auth=require(_0x532aa6('0xc')),controller=require('./chatOfflineMessage.controller');router[_0x532aa6('0x8')]('/',auth[_0x532aa6('0x4')](),controller['index']),router['get'](_0x532aa6('0x1'),auth[_0x532aa6('0x4')](),controller[_0x532aa6('0x0')]),router[_0x532aa6('0x8')]('/:id',auth['isAuthenticated'](),controller[_0x532aa6('0xd')]),router[_0x532aa6('0xb')]('/',auth[_0x532aa6('0x4')](),controller[_0x532aa6('0x5')]),router['put'](_0x532aa6('0x9'),auth['isAuthenticated'](),controller[_0x532aa6('0x7')]),router[_0x532aa6('0x2')]('/:id',auth[_0x532aa6('0x4')](),controller[_0x532aa6('0x3')]),module[_0x532aa6('0xa')]=router; \ No newline at end of file diff --git a/server/api/chatProactiveAction/chatProactiveAction.attributes.js b/server/api/chatProactiveAction/chatProactiveAction.attributes.js index 47917fa..3a23646 100644 --- a/server/api/chatProactiveAction/chatProactiveAction.attributes.js +++ b/server/api/chatProactiveAction/chatProactiveAction.attributes.js @@ -1 +1 @@ -const a90_0x3714=['timeout','sequelize','exports','mouseOver','STRING','INTEGER'];(function(_0xe1fcf9,_0x3714e9){const _0x3b9a5f=function(_0x10d04a){while(--_0x10d04a){_0xe1fcf9['push'](_0xe1fcf9['shift']());}};_0x3b9a5f(++_0x3714e9);}(a90_0x3714,0x185));const a90_0x3b9a=function(_0xe1fcf9,_0x3714e9){_0xe1fcf9=_0xe1fcf9-0x0;let _0x3b9a5f=a90_0x3714[_0xe1fcf9];return _0x3b9a5f;};const _0x4900ba=a90_0x3b9a;'use strict';const Sequelize=require(_0x4900ba('0x2'));module[_0x4900ba('0x3')]={'name':{'type':Sequelize[_0x4900ba('0x5')],'allowNull':![]},'type':{'type':Sequelize['ENUM'](_0x4900ba('0x4'),_0x4900ba('0x1')),'defaultValue':'mouseOver'},'selector':{'type':Sequelize['STRING']},'timeout':{'type':Sequelize[_0x4900ba('0x0')]}}; \ No newline at end of file +const a90_0x5ac0=['sequelize','mouseOver','STRING','INTEGER','timeout','ENUM'];(function(_0x2e136a,_0x5ac046){const _0x25929d=function(_0x3e3ad6){while(--_0x3e3ad6){_0x2e136a['push'](_0x2e136a['shift']());}};_0x25929d(++_0x5ac046);}(a90_0x5ac0,0x1b6));const a90_0x2592=function(_0x2e136a,_0x5ac046){_0x2e136a=_0x2e136a-0x0;let _0x25929d=a90_0x5ac0[_0x2e136a];return _0x25929d;};const _0x118853=a90_0x2592;'use strict';const Sequelize=require(_0x118853('0x0'));module['exports']={'name':{'type':Sequelize[_0x118853('0x2')],'allowNull':![]},'type':{'type':Sequelize[_0x118853('0x5')](_0x118853('0x1'),_0x118853('0x4')),'defaultValue':_0x118853('0x1')},'selector':{'type':Sequelize[_0x118853('0x2')]},'timeout':{'type':Sequelize[_0x118853('0x3')]}}; \ No newline at end of file diff --git a/server/api/chatProactiveAction/chatProactiveAction.controller.js b/server/api/chatProactiveAction/chatProactiveAction.controller.js index 8d72a20..b817bd0 100644 --- a/server/api/chatProactiveAction/chatProactiveAction.controller.js +++ b/server/api/chatProactiveAction/chatProactiveAction.controller.js @@ -1 +1 @@ -const a91_0x426e=['model','catch','lodash','ChatProactiveAction','send','fields','status','query','destroy','then','../../mysqldb','params','include','update','attributes','includeAll','json','api','filters','stack','length','body','create','keys','show','findOne','merge','../../components/parsers/qs','options','intersection'];(function(_0x28f3d2,_0x426e6c){const _0xb5782f=function(_0x464e71){while(--_0x464e71){_0x28f3d2['push'](_0x28f3d2['shift']());}};_0xb5782f(++_0x426e6c);}(a91_0x426e,0x1cc));const a91_0xb578=function(_0x28f3d2,_0x426e6c){_0x28f3d2=_0x28f3d2-0x0;let _0xb5782f=a91_0x426e[_0x28f3d2];return _0xb5782f;};const _0xd1606a=a91_0xb578;'use strict';const _=require(_0xd1606a('0x16')),qs=require(_0xd1606a('0x11')),logger=require('../../config/logger')(_0xd1606a('0x7')),db=require(_0xd1606a('0x0'))['db'];function respondWithResult(_0x464e71,_0x2fb416){return _0x2fb416=_0x2fb416||0xc8,function(_0x8cde27){const _0x56d6f6=a91_0xb578;if(_0x8cde27)return _0x464e71[_0x56d6f6('0x1a')](_0x2fb416)[_0x56d6f6('0x6')](_0x8cde27);};}function saveUpdates(_0xd719ba){return function(_0x1c7c8f){const _0xf88456=a91_0xb578;if(_0x1c7c8f)return _0x1c7c8f['update'](_0xd719ba)[_0xf88456('0x1d')](function(_0x1b76a6){return _0x1b76a6;});return null;};}function removeEntity(_0x110c26){return function(_0x109edf){const _0x5abedc=a91_0xb578;if(_0x109edf)return _0x109edf[_0x5abedc('0x1c')]()[_0x5abedc('0x1d')](function(){const _0x538b52=_0x5abedc;_0x110c26[_0x538b52('0x1a')](0xcc)['end']();});};}function handleEntityNotFound(_0xa79cbd){return function(_0x305aad){return!_0x305aad&&_0xa79cbd['sendStatus'](0x194),_0x305aad;};}function handleError(_0xb0e6e8,_0x2365b0){return _0x2365b0=_0x2365b0||0x1f4,function(_0x251cb1){const _0x137c2f=a91_0xb578;logger['error'](_0x251cb1[_0x137c2f('0x9')]),_0x251cb1['name']&&delete _0x251cb1['name'],_0xb0e6e8[_0x137c2f('0x1a')](_0x2365b0)[_0x137c2f('0x18')](_0x251cb1);};}exports[_0xd1606a('0xe')]=function(_0x15e765,_0x370e72){const _0x2021ac=_0xd1606a;let _0x343cbc={'raw':!![],'where':{'id':_0x15e765[_0x2021ac('0x1')]['id']}};const _0x34c0fd={};return _0x34c0fd[_0x2021ac('0x14')]=_[_0x2021ac('0xd')](db[_0x2021ac('0x17')]['rawAttributes']),_0x34c0fd['query']=_[_0x2021ac('0xd')](_0x15e765['query']),_0x34c0fd[_0x2021ac('0x8')]=_[_0x2021ac('0x13')](_0x34c0fd[_0x2021ac('0x14')],_0x34c0fd['query']),_0x343cbc[_0x2021ac('0x4')]=_[_0x2021ac('0x13')](_0x34c0fd[_0x2021ac('0x14')],qs['fields'](_0x15e765[_0x2021ac('0x1b')][_0x2021ac('0x19')])),_0x343cbc[_0x2021ac('0x4')]=_0x343cbc['attributes'][_0x2021ac('0xa')]?_0x343cbc[_0x2021ac('0x4')]:_0x34c0fd['model'],_0x15e765['query'][_0x2021ac('0x5')]&&(_0x343cbc[_0x2021ac('0x2')]=[{'all':!![]}]),_0x343cbc=_[_0x2021ac('0x10')]({},_0x343cbc,_0x15e765[_0x2021ac('0x12')]),db['ChatProactiveAction'][_0x2021ac('0xf')](_0x343cbc)[_0x2021ac('0x1d')](handleEntityNotFound(_0x370e72,null))['then'](respondWithResult(_0x370e72,null))[_0x2021ac('0x15')](handleError(_0x370e72,null));},exports[_0xd1606a('0xc')]=function(_0x3ce5cd,_0x7157e4){const _0x46a9ee=_0xd1606a;return db[_0x46a9ee('0x17')][_0x46a9ee('0xc')](_0x3ce5cd[_0x46a9ee('0xb')],{})[_0x46a9ee('0x1d')](respondWithResult(_0x7157e4,0xc9))[_0x46a9ee('0x15')](handleError(_0x7157e4,null));},exports[_0xd1606a('0x3')]=function(_0x2ea722,_0x35c93d){const _0x3369a3=_0xd1606a;return _0x2ea722[_0x3369a3('0xb')]['id']&&delete _0x2ea722[_0x3369a3('0xb')]['id'],db[_0x3369a3('0x17')][_0x3369a3('0xf')]({'where':{'id':_0x2ea722[_0x3369a3('0x1')]['id']}})[_0x3369a3('0x1d')](handleEntityNotFound(_0x35c93d,null))[_0x3369a3('0x1d')](saveUpdates(_0x2ea722[_0x3369a3('0xb')],null))['then'](respondWithResult(_0x35c93d,null))[_0x3369a3('0x15')](handleError(_0x35c93d,null));},exports[_0xd1606a('0x1c')]=function(_0x360dee,_0x1ad942){const _0x1c0170=_0xd1606a;return db[_0x1c0170('0x17')]['findOne']({'where':{'id':_0x360dee[_0x1c0170('0x1')]['id']}})['then'](handleEntityNotFound(_0x1ad942,null))[_0x1c0170('0x1d')](removeEntity(_0x1ad942,null))[_0x1c0170('0x15')](handleError(_0x1ad942,null));}; \ No newline at end of file +const a91_0x5511=['then','send','status','length','model','name','catch','create','keys','json','lodash','fields','sendStatus','includeAll','stack','show','options','error','api','findOne','body','intersection','merge','params','../../mysqldb','../../config/logger','attributes','rawAttributes','query','ChatProactiveAction','end','filters','update','destroy'];(function(_0x5049de,_0x551123){const _0xed2b3=function(_0xbdb17b){while(--_0xbdb17b){_0x5049de['push'](_0x5049de['shift']());}};_0xed2b3(++_0x551123);}(a91_0x5511,0x69));const a91_0xed2b=function(_0x5049de,_0x551123){_0x5049de=_0x5049de-0x0;let _0xed2b3=a91_0x5511[_0x5049de];return _0xed2b3;};const _0x5e91c4=a91_0xed2b;'use strict';const _=require(_0x5e91c4('0x7')),qs=require('../../components/parsers/qs'),logger=require(_0x5e91c4('0x16'))(_0x5e91c4('0xf')),db=require(_0x5e91c4('0x15'))['db'];function respondWithResult(_0xbdb17b,_0x1ef77f){return _0x1ef77f=_0x1ef77f||0xc8,function(_0x52fc60){const _0x3268df=a91_0xed2b;if(_0x52fc60)return _0xbdb17b[_0x3268df('0x21')](_0x1ef77f)[_0x3268df('0x6')](_0x52fc60);};}function saveUpdates(_0x4f18df){return function(_0x3fc06a){const _0x28f165=a91_0xed2b;if(_0x3fc06a)return _0x3fc06a[_0x28f165('0x1d')](_0x4f18df)[_0x28f165('0x1f')](function(_0x3bc9b9){return _0x3bc9b9;});return null;};}function removeEntity(_0x495027){return function(_0x39c201){const _0x540513=a91_0xed2b;if(_0x39c201)return _0x39c201[_0x540513('0x1e')]()[_0x540513('0x1f')](function(){const _0x42b5fb=_0x540513;_0x495027[_0x42b5fb('0x21')](0xcc)[_0x42b5fb('0x1b')]();});};}function handleEntityNotFound(_0x5245b6){return function(_0x59ac2d){const _0x31ecd0=a91_0xed2b;return!_0x59ac2d&&_0x5245b6[_0x31ecd0('0x9')](0x194),_0x59ac2d;};}function handleError(_0x160f7d,_0x354345){return _0x354345=_0x354345||0x1f4,function(_0x307b9f){const _0xf654f6=a91_0xed2b;logger[_0xf654f6('0xe')](_0x307b9f[_0xf654f6('0xb')]),_0x307b9f[_0xf654f6('0x2')]&&delete _0x307b9f[_0xf654f6('0x2')],_0x160f7d['status'](_0x354345)[_0xf654f6('0x20')](_0x307b9f);};}exports[_0x5e91c4('0xc')]=function(_0x1f0515,_0x137edb){const _0x2ea0dc=_0x5e91c4;let _0x2fb06b={'raw':!![],'where':{'id':_0x1f0515['params']['id']}};const _0x391aeb={};return _0x391aeb['model']=_[_0x2ea0dc('0x5')](db[_0x2ea0dc('0x1a')][_0x2ea0dc('0x18')]),_0x391aeb['query']=_[_0x2ea0dc('0x5')](_0x1f0515[_0x2ea0dc('0x19')]),_0x391aeb[_0x2ea0dc('0x1c')]=_[_0x2ea0dc('0x12')](_0x391aeb[_0x2ea0dc('0x1')],_0x391aeb[_0x2ea0dc('0x19')]),_0x2fb06b[_0x2ea0dc('0x17')]=_['intersection'](_0x391aeb['model'],qs['fields'](_0x1f0515['query'][_0x2ea0dc('0x8')])),_0x2fb06b[_0x2ea0dc('0x17')]=_0x2fb06b[_0x2ea0dc('0x17')][_0x2ea0dc('0x0')]?_0x2fb06b[_0x2ea0dc('0x17')]:_0x391aeb[_0x2ea0dc('0x1')],_0x1f0515['query'][_0x2ea0dc('0xa')]&&(_0x2fb06b['include']=[{'all':!![]}]),_0x2fb06b=_[_0x2ea0dc('0x13')]({},_0x2fb06b,_0x1f0515[_0x2ea0dc('0xd')]),db[_0x2ea0dc('0x1a')][_0x2ea0dc('0x10')](_0x2fb06b)['then'](handleEntityNotFound(_0x137edb,null))[_0x2ea0dc('0x1f')](respondWithResult(_0x137edb,null))[_0x2ea0dc('0x3')](handleError(_0x137edb,null));},exports[_0x5e91c4('0x4')]=function(_0x3aea7e,_0x7fb35c){const _0x45e0fb=_0x5e91c4;return db['ChatProactiveAction'][_0x45e0fb('0x4')](_0x3aea7e[_0x45e0fb('0x11')],{})[_0x45e0fb('0x1f')](respondWithResult(_0x7fb35c,0xc9))[_0x45e0fb('0x3')](handleError(_0x7fb35c,null));},exports[_0x5e91c4('0x1d')]=function(_0x53dbd3,_0x345505){const _0x5c85ca=_0x5e91c4;return _0x53dbd3[_0x5c85ca('0x11')]['id']&&delete _0x53dbd3[_0x5c85ca('0x11')]['id'],db[_0x5c85ca('0x1a')][_0x5c85ca('0x10')]({'where':{'id':_0x53dbd3[_0x5c85ca('0x14')]['id']}})[_0x5c85ca('0x1f')](handleEntityNotFound(_0x345505,null))[_0x5c85ca('0x1f')](saveUpdates(_0x53dbd3[_0x5c85ca('0x11')],null))[_0x5c85ca('0x1f')](respondWithResult(_0x345505,null))[_0x5c85ca('0x3')](handleError(_0x345505,null));},exports[_0x5e91c4('0x1e')]=function(_0x4bbb37,_0x362344){const _0x1b1bf8=_0x5e91c4;return db[_0x1b1bf8('0x1a')]['findOne']({'where':{'id':_0x4bbb37[_0x1b1bf8('0x14')]['id']}})[_0x1b1bf8('0x1f')](handleEntityNotFound(_0x362344,null))[_0x1b1bf8('0x1f')](removeEntity(_0x362344,null))['catch'](handleError(_0x362344,null));}; \ No newline at end of file diff --git a/server/api/chatProactiveAction/chatProactiveAction.model.js b/server/api/chatProactiveAction/chatProactiveAction.model.js index 56e3ef2..bc3f6d9 100644 --- a/server/api/chatProactiveAction/chatProactiveAction.model.js +++ b/server/api/chatProactiveAction/chatProactiveAction.model.js @@ -1 +1 @@ -const a92_0x46b8=['chat_proactive_actions','exports','./chatProactiveAction.attributes','define','ChatProactiveAction'];(function(_0x3e2b70,_0x46b898){const _0x2e692a=function(_0xfe9c3f){while(--_0xfe9c3f){_0x3e2b70['push'](_0x3e2b70['shift']());}};_0x2e692a(++_0x46b898);}(a92_0x46b8,0x1a8));const a92_0x2e69=function(_0x3e2b70,_0x46b898){_0x3e2b70=_0x3e2b70-0x0;let _0x2e692a=a92_0x46b8[_0x3e2b70];return _0x2e692a;};const _0x468401=a92_0x2e69;'use strict';const attributes=require(_0x468401('0x3'));module[_0x468401('0x2')]=function(_0xfe9c3f){const _0x104fee=_0x468401,_0xbff57b=_0xfe9c3f[_0x104fee('0x4')](_0x104fee('0x0'),attributes,{'tableName':_0x104fee('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xbff57b;}; \ No newline at end of file +const a92_0x3c9f=['chat_proactive_actions','./chatProactiveAction.attributes','exports'];(function(_0x2a9d85,_0x3c9f62){const _0x592113=function(_0x174e27){while(--_0x174e27){_0x2a9d85['push'](_0x2a9d85['shift']());}};_0x592113(++_0x3c9f62);}(a92_0x3c9f,0x15a));const a92_0x5921=function(_0x2a9d85,_0x3c9f62){_0x2a9d85=_0x2a9d85-0x0;let _0x592113=a92_0x3c9f[_0x2a9d85];return _0x592113;};const _0x40106a=a92_0x5921;'use strict';const attributes=require(_0x40106a('0x0'));module[_0x40106a('0x1')]=function(_0x174e27){const _0x2d3bbb=_0x40106a,_0x5ef077=_0x174e27['define']('ChatProactiveAction',attributes,{'tableName':_0x2d3bbb('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5ef077;}; \ No newline at end of file diff --git a/server/api/chatProactiveAction/index.js b/server/api/chatProactiveAction/index.js index e6a71e5..b4ca6d1 100644 --- a/server/api/chatProactiveAction/index.js +++ b/server/api/chatProactiveAction/index.js @@ -1 +1 @@ -const a93_0x13c9=['../../components/auth/service','update','put','isAuthenticated','./chatProactiveAction.controller','/:id','destroy','get'];(function(_0x30d0a8,_0x13c90c){const _0x122527=function(_0x555970){while(--_0x555970){_0x30d0a8['push'](_0x30d0a8['shift']());}};_0x122527(++_0x13c90c);}(a93_0x13c9,0xc1));const a93_0x1225=function(_0x30d0a8,_0x13c90c){_0x30d0a8=_0x30d0a8-0x0;let _0x122527=a93_0x13c9[_0x30d0a8];return _0x122527;};const _0x45d6ac=a93_0x1225;'use strict';const express=require('express'),router=express['Router'](),auth=require(_0x45d6ac('0x7')),controller=require(_0x45d6ac('0x3'));router[_0x45d6ac('0x6')](_0x45d6ac('0x4'),auth['isAuthenticated'](),controller['show']),router['post']('/',auth['isAuthenticated'](),controller['create']),router[_0x45d6ac('0x1')](_0x45d6ac('0x4'),auth[_0x45d6ac('0x2')](),controller[_0x45d6ac('0x0')]),router['delete'](_0x45d6ac('0x4'),auth[_0x45d6ac('0x2')](),controller[_0x45d6ac('0x5')]),module['exports']=router; \ No newline at end of file +const a93_0x164e=['delete','../../components/auth/service','get','/:id','update','create','put','express','Router'];(function(_0x5f4b74,_0x164e13){const _0x2c825c=function(_0x91668){while(--_0x91668){_0x5f4b74['push'](_0x5f4b74['shift']());}};_0x2c825c(++_0x164e13);}(a93_0x164e,0x112));const a93_0x2c82=function(_0x5f4b74,_0x164e13){_0x5f4b74=_0x5f4b74-0x0;let _0x2c825c=a93_0x164e[_0x5f4b74];return _0x2c825c;};const _0x2a8c37=a93_0x2c82;'use strict';const express=require(_0x2a8c37('0x3')),router=express[_0x2a8c37('0x4')](),auth=require(_0x2a8c37('0x6')),controller=require('./chatProactiveAction.controller');router[_0x2a8c37('0x7')](_0x2a8c37('0x8'),auth['isAuthenticated'](),controller['show']),router['post']('/',auth['isAuthenticated'](),controller[_0x2a8c37('0x1')]),router[_0x2a8c37('0x2')](_0x2a8c37('0x8'),auth['isAuthenticated'](),controller[_0x2a8c37('0x0')]),router[_0x2a8c37('0x5')](_0x2a8c37('0x8'),auth['isAuthenticated'](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/chatQueue/chatQueue.attributes.js b/server/api/chatQueue/chatQueue.attributes.js index 268b7e7..daa9e03 100644 --- a/server/api/chatQueue/chatQueue.attributes.js +++ b/server/api/chatQueue/chatQueue.attributes.js @@ -1 +1 @@ -const a94_0x1a64=['rrmemory','STRING','ENUM','exports','sequelize'];(function(_0x2133e5,_0x1a643f){const _0x2fd82c=function(_0x73e21c){while(--_0x73e21c){_0x2133e5['push'](_0x2133e5['shift']());}};_0x2fd82c(++_0x1a643f);}(a94_0x1a64,0x1e7));const a94_0x2fd8=function(_0x2133e5,_0x1a643f){_0x2133e5=_0x2133e5-0x0;let _0x2fd82c=a94_0x1a64[_0x2133e5];return _0x2fd82c;};const _0x270061=a94_0x2fd8;'use strict';const Sequelize=require(_0x270061('0x2'));module[_0x270061('0x1')]={'name':{'type':Sequelize[_0x270061('0x4')],'unique':'name','allowNull':![],'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize[_0x270061('0x4')]},'timeout':{'type':Sequelize['INTEGER'],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x270061('0x0')](_0x270061('0x3'),'beepall','roundrobin')}}; \ No newline at end of file +const a94_0x59f6=['STRING','roundrobin','exports','sequelize','INTEGER','rrmemory'];(function(_0x1ce34c,_0x59f67c){const _0x156e4a=function(_0x3bc0ec){while(--_0x3bc0ec){_0x1ce34c['push'](_0x1ce34c['shift']());}};_0x156e4a(++_0x59f67c);}(a94_0x59f6,0xf7));const a94_0x156e=function(_0x1ce34c,_0x59f67c){_0x1ce34c=_0x1ce34c-0x0;let _0x156e4a=a94_0x59f6[_0x1ce34c];return _0x156e4a;};const _0x59cd1a=a94_0x156e;'use strict';const Sequelize=require(_0x59cd1a('0x2'));module[_0x59cd1a('0x1')]={'name':{'type':Sequelize[_0x59cd1a('0x5')],'unique':'name','allowNull':![],'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize[_0x59cd1a('0x5')]},'timeout':{'type':Sequelize[_0x59cd1a('0x3')],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize['ENUM'](_0x59cd1a('0x4'),'beepall',_0x59cd1a('0x0'))}}; \ No newline at end of file diff --git a/server/api/chatQueue/chatQueue.controller.js b/server/api/chatQueue/chatQueue.controller.js index e1b54e9..93c82bf 100644 --- a/server/api/chatQueue/chatQueue.controller.js +++ b/server/api/chatQueue/chatQueue.controller.js @@ -1 +1 @@ -const a95_0x164a=['isEmpty','user_has_teams','rows','include','destroy','getMembers','rawAttributes','VIRTUAL','sequelize','describe','getAgents','options','type','clone','findAll','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','flatMap','tq.TeamId','isArray','catch','limit','../../mysqldb','UserProfileSection','register','push','voicePause','every','end','where','api','filter','sendStatus','sort','update','all','each','name','fields','model','order','userChatQueue:save','then','role','ChatQueue','ChatQueueId','show','Agents','getTeams','../../components/parsers/qs','length','filters','attributes','nolimit','keys','select','forEach','send','%s/%s','findOrCreate','index','undefined','error','lodash','../../config/logger','from','autoAssociation','merge','json','chatPause','userChatQueue:remove','body','offset','createdAt','Team','ut.UserId\x20=\x20?','pick','util','ChatQueues','like','squel','User','status','ut.TeamId\x20=\x20tq.TeamId','addAgents','map','stack','value','agent','intersection','updatedAt','userProfileId','findOne','online','key','addTeams','user','transaction','includes','emit','get','removeTeams','removeAgents','fieldName','Content-Range','count','team_has_chat_queues','Unable\x20to\x20retrieve\x20the\x20current\x20user','ids','create','UserChatQueue','params','query'];(function(_0x41a232,_0x164a9a){const _0x79920b=function(_0x46dec3){while(--_0x46dec3){_0x41a232['push'](_0x41a232['shift']());}};_0x79920b(++_0x164a9a);}(a95_0x164a,0x126));const a95_0x7992=function(_0x41a232,_0x164a9a){_0x41a232=_0x41a232-0x0;let _0x79920b=a95_0x164a[_0x41a232];return _0x79920b;};const _0xf59830=a95_0x7992;'use strict';const util=require(_0xf59830('0x6')),_=require(_0xf59830('0x68')),squel=require(_0xf59830('0x9')),qs=require(_0xf59830('0x5a')),logger=require(_0xf59830('0x69'))(_0xf59830('0x47')),{getSocket}=require('../../rediscache'),db=require(_0xf59830('0x3f'))['db'],{Op,QueryTypes}=require(_0xf59830('0x32')),socket=getSocket();require('./chatQueue.socket')[_0xf59830('0x41')](socket);function respondWithStatusCode(_0x46dec3,_0x211de1){return _0x211de1=_0x211de1||0xcc,function(_0x82fcb9){const _0x129d35=a95_0x7992;if(_0x82fcb9)return _0x46dec3['sendStatus'](_0x211de1);return _0x46dec3[_0x129d35('0xb')](_0x211de1)[_0x129d35('0x45')]();};}function respondWithResult(_0x4e673c,_0x3b5bf1){return _0x3b5bf1=_0x3b5bf1||0xc8,function(_0x19591b){const _0x54ecb9=a95_0x7992;if(_0x19591b)return _0x4e673c[_0x54ecb9('0xb')](_0x3b5bf1)[_0x54ecb9('0x6d')](_0x19591b);};}function respondWithFilteredResult(_0x12bb81,_0xd29846){return function(_0x56905f){const _0x467b0c=a95_0x7992;if(_0x56905f){const _0x5db743=_0x56905f[_0x467b0c('0x22')],_0x184754=_0xd29846[_0x467b0c('0x1')];let _0x512da6=_0xd29846[_0x467b0c('0x1')]+_0xd29846['limit'],_0xb5fdb1;return _0x512da6>=_0x5db743?(_0x512da6=_0x5db743,_0xb5fdb1=0xc8):_0xb5fdb1=0xce,_0x12bb81['status'](_0xb5fdb1),_0x12bb81['set'](_0x467b0c('0x21'),_0x184754+'-'+_0x512da6+'/'+_0x5db743)[_0x467b0c('0x6d')](_0x56905f);}return null;};}function saveUpdates(_0x37cac7){return function(_0xed71ad){if(_0xed71ad)return _0xed71ad['update'](_0x37cac7)['then'](function(_0x58373a){return _0x58373a;});return null;};}function removeEntity(_0x3a31e0){return function(_0x510be0){const _0xb8a205=a95_0x7992;if(_0x510be0)return _0x510be0[_0xb8a205('0x2e')]()['then'](function(){const _0x2eb4a0=_0xb8a205,_0x53b620=_0x510be0[_0x2eb4a0('0x1d')]({'plain':!![]}),_0x55d484=_0x2eb4a0('0x7');return db['UserProfileResource'][_0x2eb4a0('0x2e')]({'where':{'type':_0x55d484,'resourceId':_0x53b620['id']}})[_0x2eb4a0('0x53')](function(){return _0x510be0;});})[_0xb8a205('0x53')](function(){const _0x1e27aa=_0xb8a205;_0x3a31e0[_0x1e27aa('0xb')](0xcc)[_0x1e27aa('0x45')]();});};}function handleEntityNotFound(_0x573d46){return function(_0x5e12ca){const _0xd2b28e=a95_0x7992;return!_0x5e12ca&&_0x573d46[_0xd2b28e('0x49')](0x194),_0x5e12ca;};}function handleError(_0x90dc71,_0x5ab1cf){return _0x5ab1cf=_0x5ab1cf||0x1f4,function(_0x22ad19){const _0x32451f=a95_0x7992;logger[_0x32451f('0x67')](_0x22ad19[_0x32451f('0xf')]),_0x22ad19[_0x32451f('0x4e')]&&delete _0x22ad19['name'],_0x90dc71['status'](_0x5ab1cf)[_0x32451f('0x62')](_0x22ad19);};}exports[_0xf59830('0x65')]=function(_0x4fad77,_0x5f3c9d){const _0xe57e4c=_0xf59830;let _0x54a37b={};const _0xa9ea92={},_0x46bb83={'count':0x0,'rows':[]},_0x320255=_[_0xe57e4c('0xe')](db['ChatQueue'][_0xe57e4c('0x30')],function(_0x26bb8c){const _0x18fefc=_0xe57e4c;return{'name':_0x26bb8c[_0x18fefc('0x20')],'type':_0x26bb8c[_0x18fefc('0x36')][_0x18fefc('0x17')]};});_0xa9ea92['model']=_[_0xe57e4c('0xe')](_0x320255,_0xe57e4c('0x4e')),_0xa9ea92[_0xe57e4c('0x29')]=_[_0xe57e4c('0x5f')](_0x4fad77[_0xe57e4c('0x29')]),_0xa9ea92[_0xe57e4c('0x5c')]=_['intersection'](_0xa9ea92[_0xe57e4c('0x50')],_0xa9ea92[_0xe57e4c('0x29')]),_0x54a37b['attributes']=_['intersection'](_0xa9ea92[_0xe57e4c('0x50')],qs[_0xe57e4c('0x4f')](_0x4fad77[_0xe57e4c('0x29')][_0xe57e4c('0x4f')])),_0x54a37b[_0xe57e4c('0x5d')]=_0x54a37b[_0xe57e4c('0x5d')][_0xe57e4c('0x5b')]?_0x54a37b[_0xe57e4c('0x5d')]:_0xa9ea92[_0xe57e4c('0x50')];typeof _0x4fad77[_0xe57e4c('0x29')][_0xe57e4c('0x5e')]===_0xe57e4c('0x66')&&(_0x54a37b['limit']=qs[_0xe57e4c('0x3e')](_0x4fad77[_0xe57e4c('0x29')][_0xe57e4c('0x3e')]),_0x54a37b[_0xe57e4c('0x1')]=qs['offset'](_0x4fad77['query'][_0xe57e4c('0x1')]));_0x54a37b[_0xe57e4c('0x51')]=qs[_0xe57e4c('0x4a')](_0x4fad77['query']['sort']),_0x54a37b['where']=qs[_0xe57e4c('0x5c')](_['pick'](_0x4fad77['query'],_0xa9ea92[_0xe57e4c('0x5c')]),_0x320255);_0x4fad77[_0xe57e4c('0x29')]['filter']&&(_0x54a37b[_0xe57e4c('0x46')]=_[_0xe57e4c('0x6c')](_0x54a37b[_0xe57e4c('0x46')],{[Op['or']]:_['map'](_0x320255,function(_0x15e7b3){const _0x5952f1=_0xe57e4c;if(_0x15e7b3[_0x5952f1('0x36')]!==_0x5952f1('0x31')){const _0x3ebf75={};return _0x3ebf75[_0x15e7b3[_0x5952f1('0x4e')]]={[Op[_0x5952f1('0x8')]]:'%'+_0x4fad77[_0x5952f1('0x29')][_0x5952f1('0x48')]+'%'},_0x3ebf75;}})}));_0x54a37b=_['merge']({},_0x54a37b,_0x4fad77['options']);const _0x2ab289={'where':_0x54a37b['where']};return db['ChatQueue'][_0xe57e4c('0x22')](_0x2ab289)[_0xe57e4c('0x53')](function(_0x738b2){const _0x3f8c98=_0xe57e4c;return _0x46bb83[_0x3f8c98('0x22')]=_0x738b2,_0x4fad77[_0x3f8c98('0x29')]['includeAll']&&(_0x54a37b[_0x3f8c98('0x2d')]=[{'all':!![]}]),db[_0x3f8c98('0x55')]['findAll'](_0x54a37b);})['then'](function(_0x3ea6f3){const _0x179b85=_0xe57e4c;return _0x46bb83[_0x179b85('0x2c')]=_0x3ea6f3,_0x46bb83;})[_0xe57e4c('0x53')](respondWithFilteredResult(_0x5f3c9d,_0x54a37b))['catch'](handleError(_0x5f3c9d,null));},exports[_0xf59830('0x57')]=function(_0x2f449c,_0x148dfb){const _0x2d5d36=_0xf59830;let _0x3fa127={'raw':!![],'where':{'id':_0x2f449c[_0x2d5d36('0x28')]['id']}};const _0x49cb38={};return _0x49cb38[_0x2d5d36('0x50')]=_[_0x2d5d36('0x5f')](db[_0x2d5d36('0x55')][_0x2d5d36('0x30')]),_0x49cb38[_0x2d5d36('0x29')]=_[_0x2d5d36('0x5f')](_0x2f449c[_0x2d5d36('0x29')]),_0x49cb38['filters']=_[_0x2d5d36('0x12')](_0x49cb38[_0x2d5d36('0x50')],_0x49cb38[_0x2d5d36('0x29')]),_0x3fa127[_0x2d5d36('0x5d')]=_[_0x2d5d36('0x12')](_0x49cb38['model'],qs['fields'](_0x2f449c['query']['fields'])),_0x3fa127['attributes']=_0x3fa127['attributes']['length']?_0x3fa127[_0x2d5d36('0x5d')]:_0x49cb38['model'],_0x2f449c[_0x2d5d36('0x29')]['includeAll']&&(_0x3fa127[_0x2d5d36('0x2d')]=[{'all':!![]}]),_0x3fa127=_[_0x2d5d36('0x6c')]({},_0x3fa127,_0x2f449c['options']),db[_0x2d5d36('0x55')][_0x2d5d36('0x15')](_0x3fa127)[_0x2d5d36('0x53')](handleEntityNotFound(_0x148dfb,null))['then'](respondWithResult(_0x148dfb,null))[_0x2d5d36('0x3d')](handleError(_0x148dfb,null));},exports[_0xf59830('0x26')]=function(_0x5954e8,_0x3a6a46){const _0x27263e=_0xf59830;return db[_0x27263e('0x55')][_0x27263e('0x26')](_0x5954e8[_0x27263e('0x0')],{})[_0x27263e('0x53')](function(_0x260a73){const _0x518c8b=_0x27263e,_0xa53e5=_0x5954e8[_0x518c8b('0x19')]['get']({'plain':!![]});if(!_0xa53e5)throw new Error(_0x518c8b('0x24'));if(_0xa53e5[_0x518c8b('0x54')]===_0x518c8b('0x19')){const _0x2379b9=_0x260a73[_0x518c8b('0x1d')]({'plain':!![]}),_0x30448f='ChatQueues';return db[_0x518c8b('0x40')][_0x518c8b('0x15')]({'where':{'name':_0x30448f,'userProfileId':_0xa53e5[_0x518c8b('0x14')]},'raw':!![]})['then'](function(_0x19c54e){const _0x1b4c4b=_0x518c8b;return _0x19c54e&&_0x19c54e[_0x1b4c4b('0x6b')]===0x0?db['UserProfileResource']['create']({'name':_0x2379b9[_0x1b4c4b('0x4e')],'resourceId':_0x2379b9['id'],'type':_0x19c54e[_0x1b4c4b('0x4e')],'sectionId':_0x19c54e['id']},{})['then'](function(){return _0x260a73;}):_0x260a73;})[_0x518c8b('0x3d')](function(_0xa92409){const _0x4cf0f6=_0x518c8b;logger[_0x4cf0f6('0x67')](_0x4cf0f6('0x39'),_0xa92409);throw _0xa92409;});}return _0x260a73;})['then'](respondWithResult(_0x3a6a46,0xc9))[_0x27263e('0x3d')](handleError(_0x3a6a46,null));},exports[_0xf59830('0x4b')]=function(_0x2da4e1,_0x5a0005){const _0x59f2ff=_0xf59830;return _0x2da4e1[_0x59f2ff('0x0')]['id']&&delete _0x2da4e1['body']['id'],db[_0x59f2ff('0x55')][_0x59f2ff('0x15')]({'where':{'id':_0x2da4e1[_0x59f2ff('0x28')]['id']}})[_0x59f2ff('0x53')](handleEntityNotFound(_0x5a0005,null))[_0x59f2ff('0x53')](saveUpdates(_0x2da4e1[_0x59f2ff('0x0')],null))[_0x59f2ff('0x53')](respondWithResult(_0x5a0005,null))[_0x59f2ff('0x3d')](handleError(_0x5a0005,null));},exports[_0xf59830('0x2e')]=function(_0x3b4d15,_0x4e99da){const _0x4b98f4=_0xf59830;return db['ChatQueue']['findOne']({'where':{'id':_0x3b4d15[_0x4b98f4('0x28')]['id']}})['then'](handleEntityNotFound(_0x4e99da,null))[_0x4b98f4('0x53')](removeEntity(_0x4e99da,null))[_0x4b98f4('0x3d')](handleError(_0x4e99da,null));},exports[_0xf59830('0x33')]=function(_0x35f5f8,_0x154559){const _0x307624=_0xf59830;return db[_0x307624('0x55')][_0x307624('0x33')]()[_0x307624('0x53')](respondWithResult(_0x154559,null))[_0x307624('0x3d')](handleError(_0x154559,null));},exports[_0xf59830('0x2f')]=function(_0x1b6877,_0x2bc00d){const _0x2a86cd=_0xf59830;let _0x18be94={'raw':!![],'where':{}};const _0x501451={};let _0xc4415e;return db[_0x2a86cd('0x55')][_0x2a86cd('0x15')]({'where':{'id':_0x1b6877[_0x2a86cd('0x28')]['id']}})['then'](handleEntityNotFound(_0x2bc00d,null))['then'](function(_0x587d7a){const _0x198397=_0x2a86cd;if(_0x587d7a)return _0xc4415e=_0x587d7a[_0x198397('0x1d')]({'plain':!![]}),_0x501451[_0x198397('0x50')]=_[_0x198397('0x5f')](db[_0x198397('0x27')][_0x198397('0x30')]),_0x501451['query']=_[_0x198397('0x5f')](_0x1b6877['query']),_0x501451['filters']=_[_0x198397('0x12')](_0x501451[_0x198397('0x50')],_0x501451['query']),_0x18be94[_0x198397('0x5d')]=_[_0x198397('0x12')](_0x501451[_0x198397('0x50')],qs[_0x198397('0x4f')](_0x1b6877[_0x198397('0x29')][_0x198397('0x4f')])),_0x18be94[_0x198397('0x5d')]=_0x18be94[_0x198397('0x5d')][_0x198397('0x5b')]?_0x18be94[_0x198397('0x5d')]:_0x501451[_0x198397('0x50')],typeof _0x1b6877[_0x198397('0x29')]['nolimit']===_0x198397('0x66')&&(_0x18be94[_0x198397('0x3e')]=qs[_0x198397('0x3e')](_0x1b6877['query'][_0x198397('0x3e')]),_0x18be94[_0x198397('0x1')]=qs['offset'](_0x1b6877[_0x198397('0x29')][_0x198397('0x1')])),_0x18be94['order']=qs[_0x198397('0x4a')](_0x1b6877[_0x198397('0x29')][_0x198397('0x4a')]),_0x18be94['where']=qs[_0x198397('0x5c')](_[_0x198397('0x5')](_0x1b6877[_0x198397('0x29')],_0x501451[_0x198397('0x5c')])),_0x18be94[_0x198397('0x46')][_0x198397('0x56')]=_0x587d7a['id'],_0x1b6877['query']['filter']&&(_0x18be94[_0x198397('0x46')]=_[_0x198397('0x6c')](_0x18be94[_0x198397('0x46')],{[Op['or']]:_['map'](_0x18be94['attributes'],function(_0x514537){const _0x45763b=_0x198397,_0x251ae6={};return _0x251ae6[_0x514537]={[Op['like']]:'%'+_0x1b6877[_0x45763b('0x29')][_0x45763b('0x48')]+'%'},_0x251ae6;})})),_0x18be94=_[_0x198397('0x6c')]({},_0x18be94,_0x1b6877[_0x198397('0x35')]),db[_0x198397('0x27')]['findAll'](_0x18be94);})[_0x2a86cd('0x53')](function(_0x1aa032){const _0x22a628=_0x2a86cd;if(_0x1aa032)return db['User']['findAndCountAll']({'where':{'id':_[_0x22a628('0xe')](_0x1aa032,'UserId'),'role':_0x22a628('0x11')},'attributes':['id',_0x22a628('0x4e'),_0x22a628('0x6e'),_0x22a628('0x13'),_0x22a628('0x2')]});})[_0x2a86cd('0x53')](function(_0x5caa22){const _0xb84ab3=_0x2a86cd;return _0x5caa22?{'count':_0x5caa22[_0xb84ab3('0x22')],'rows':_[_0xb84ab3('0xe')](_0x5caa22[_0xb84ab3('0x2c')],function(_0x3c6f1d){const _0x4f1223=_0xb84ab3;return{'membername':_0x3c6f1d[_0x4f1223('0x4e')],'UserId':_0x3c6f1d['id'],'queue_name':_0xc4415e[_0x4f1223('0x4e')],'ChatQueueId':_0xc4415e['id'],'interface':util['format'](_0x4f1223('0x63'),'SIP',_0x3c6f1d[_0x4f1223('0x4e')]),'penalty':0x0,'paused':_0x3c6f1d['chatPause'],'createdAt':_0x3c6f1d[_0x4f1223('0x2')],'updatedAt':_0x3c6f1d[_0x4f1223('0x13')]};})}:{'count':0x0,'rows':[]};})[_0x2a86cd('0x53')](respondWithFilteredResult(_0x2bc00d,_0x18be94))[_0x2a86cd('0x3d')](handleError(_0x2bc00d,null));},exports[_0xf59830('0x59')]=function(_0x553b93,_0x1dc5c3){const _0x569dec=_0xf59830;let _0x552e2d={};const _0x3fcb91={};let _0x558576,_0x1ceb8d;return db[_0x569dec('0x55')][_0x569dec('0x15')]({'where':{'id':_0x553b93[_0x569dec('0x28')]['id']}})['then'](handleEntityNotFound(_0x1dc5c3,null))[_0x569dec('0x53')](function(_0x3ae4ea){const _0x8f8506=_0x569dec;if(_0x3ae4ea)return _0x558576=_0x3ae4ea,_0x3fcb91['model']=_[_0x8f8506('0x5f')](db['Team']['rawAttributes']),_0x3fcb91[_0x8f8506('0x29')]=_[_0x8f8506('0x5f')](_0x553b93[_0x8f8506('0x29')]),_0x3fcb91['filters']=_[_0x8f8506('0x12')](_0x3fcb91[_0x8f8506('0x50')],_0x3fcb91[_0x8f8506('0x29')]),_0x552e2d[_0x8f8506('0x5d')]=_[_0x8f8506('0x12')](_0x3fcb91['model'],qs[_0x8f8506('0x4f')](_0x553b93[_0x8f8506('0x29')][_0x8f8506('0x4f')])),_0x552e2d[_0x8f8506('0x5d')]=_0x552e2d[_0x8f8506('0x5d')][_0x8f8506('0x5b')]?_0x552e2d[_0x8f8506('0x5d')]:_0x3fcb91[_0x8f8506('0x50')],_0x552e2d[_0x8f8506('0x51')]=qs['sort'](_0x553b93[_0x8f8506('0x29')]['sort']),_0x552e2d['where']=qs[_0x8f8506('0x5c')](_[_0x8f8506('0x5')](_0x553b93[_0x8f8506('0x29')],_0x3fcb91['filters'])),_0x553b93['query']['filter']&&(_0x552e2d[_0x8f8506('0x46')]=_['merge'](_0x552e2d[_0x8f8506('0x46')],{[Op['or']]:_['map'](_0x552e2d['attributes'],function(_0x9d3b7e){const _0x5dc004=_0x8f8506,_0x1cde5e={};return _0x1cde5e[_0x9d3b7e]={[Op['like']]:'%'+_0x553b93[_0x5dc004('0x29')][_0x5dc004('0x48')]+'%'},_0x1cde5e;})})),_0x552e2d=_[_0x8f8506('0x6c')]({},_0x552e2d,_0x553b93[_0x8f8506('0x35')]),_0x558576[_0x8f8506('0x59')](_0x552e2d);})[_0x569dec('0x53')](function(_0x73a252){const _0x235104=_0x569dec;if(_0x73a252)return _0x1ceb8d=_0x73a252[_0x235104('0x5b')],typeof _0x553b93[_0x235104('0x29')][_0x235104('0x5e')]===_0x235104('0x66')&&(_0x552e2d[_0x235104('0x3e')]=qs[_0x235104('0x3e')](_0x553b93['query']['limit']),_0x552e2d[_0x235104('0x1')]=qs[_0x235104('0x1')](_0x553b93[_0x235104('0x29')][_0x235104('0x1')])),_0x558576['getTeams'](_0x552e2d);})['then'](function(_0x3bae2e){if(_0x3bae2e)return _0x3bae2e?{'count':_0x1ceb8d,'rows':_0x3bae2e}:null;})['then'](respondWithResult(_0x1dc5c3,null))['catch'](handleError(_0x1dc5c3,null));},exports[_0xf59830('0x18')]=function(_0x52fa69,_0x2b66ea){const _0x2cb07f=_0xf59830,_0x22c3ea=_0x52fa69[_0x2cb07f('0x0')][_0x2cb07f('0x25')];return db['Team'][_0x2cb07f('0x38')]({'where':{'id':_0x22c3ea},'attributes':['id'],'include':[{'model':db[_0x2cb07f('0xa')],'as':_0x2cb07f('0x58'),'attributes':['id',_0x2cb07f('0x4e'),_0x2cb07f('0x16'),_0x2cb07f('0x43'),'interface'],'raw':!![]}]})[_0x2cb07f('0x53')](function(_0x1b1a8e){const _0x985983=_0x2cb07f;if(_0x1b1a8e){const _0x1891d1=_[_0x985983('0x3a')](_0x1b1a8e,function(_0x35f61e){const _0x3745bf=_0x985983,_0x3922ac=_0x35f61e[_0x3745bf('0x1d')]({'plain':!![]});return _0x3922ac[_0x3745bf('0x58')];});return db[_0x985983('0x55')]['findOne']({'where':{'id':_0x52fa69['params']['id']}})[_0x985983('0x53')](function(_0x4bda7e){const _0x26c277=_0x985983;return db[_0x26c277('0x32')]['transaction'](function(_0x55c0c1){const _0x1629b8=_0x26c277;return _0x4bda7e[_0x1629b8('0x18')](_0x22c3ea,{'transaction':_0x55c0c1})['then'](function(){const _0xa40179=_0x1629b8;return Promise[_0xa40179('0x4d')](_0x1891d1,function(_0x1d8114){const _0x2d6c7c=_0xa40179;return db[_0x2d6c7c('0x27')][_0x2d6c7c('0x64')]({'where':{'UserId':_0x1d8114['id'],'ChatQueueId':_0x52fa69[_0x2d6c7c('0x28')]['id']},'transaction':_0x55c0c1});});})[_0x1629b8('0x53')](function(){const _0x3cc97a=_0x1629b8;_0x1891d1[_0x3cc97a('0x61')](function(_0x3856d2){const _0x1d5e54=_0x3cc97a;socket['emit'](_0x1d5e54('0x52'),{'UserId':_0x3856d2['id'],'ChatQueueId':_0x4bda7e['id']});});});});});}})[_0x2cb07f('0x53')](respondWithStatusCode(_0x2b66ea,null))[_0x2cb07f('0x3d')](handleError(_0x2b66ea,null));},exports['removeTeams']=function(_0x33d5e5,_0x15608f){const _0x31ae82=_0xf59830;return db[_0x31ae82('0x3')]['findAll']({'where':{'id':_0x33d5e5['query'][_0x31ae82('0x25')]},'attributes':['id'],'include':[{'model':db[_0x31ae82('0xa')],'as':_0x31ae82('0x58'),'attributes':['id'],'raw':!![]}]})[_0x31ae82('0x53')](handleEntityNotFound(_0x15608f,null))['then'](function(_0x4727ed){const _0x20f2d7=_0x31ae82,_0x50dd3e=_[_0x20f2d7('0xe')](_0x4727ed,'id');let _0x4cc7bb=[];const _0x1ef40e=[],_0x45ae34=squel[_0x20f2d7('0x60')]();_0x45ae34['field'](_0x20f2d7('0x3b'))[_0x20f2d7('0x6a')](_0x20f2d7('0x23'),'tq')['join'](_0x20f2d7('0x2b'),'ut',_0x20f2d7('0xc'))[_0x20f2d7('0x46')]('ChatQueueId\x20=\x20?',_0x33d5e5[_0x20f2d7('0x28')]['id']);for(let _0x259976=0x0;_0x259976<_0x4727ed['length'];_0x259976+=0x1){const _0xf1b66=_0x4727ed[_0x259976];for(let _0x3d6ae5=0x0;_0x3d6ae5<_0xf1b66[_0x20f2d7('0x58')][_0x20f2d7('0x5b')];_0x3d6ae5+=0x1){const _0x274f6c=_0xf1b66[_0x20f2d7('0x58')][_0x3d6ae5],_0x109aa0=_0x45ae34[_0x20f2d7('0x37')]();_0x109aa0['where'](_0x20f2d7('0x4'),_0x274f6c['id']),_0x1ef40e[_0x20f2d7('0x42')](db[_0x20f2d7('0x32')][_0x20f2d7('0x29')](_0x109aa0['toString'](),{'type':QueryTypes['SELECT']})[_0x20f2d7('0x53')](function(_0x3792d0){const _0x5e5365=_0x20f2d7;if(_0x3792d0[_0x5e5365('0x5b')]===0x1)return _0x274f6c['id'];else{const _0x1039da=_[_0x5e5365('0x44')](_[_0x5e5365('0xe')](_0x3792d0,'TeamId'),function(_0x201678){const _0x126c85=_0x5e5365;return _[_0x126c85('0x1b')](_0x50dd3e,_0x201678);});if(_0x1039da)return _0x274f6c['id'];}}));}}return Promise[_0x20f2d7('0x4c')](_0x1ef40e)[_0x20f2d7('0x53')](function(_0x463823){const _0x45d1c5=_0x20f2d7;return _0x4cc7bb=_(_0x4cc7bb)['union'](_0x463823)['compact']()[_0x45d1c5('0x10')](),db[_0x45d1c5('0x55')][_0x45d1c5('0x15')]({'where':{'id':_0x33d5e5[_0x45d1c5('0x28')]['id']}})[_0x45d1c5('0x53')](function(_0x52e9d7){const _0x2cd424=_0x45d1c5;return db['sequelize'][_0x2cd424('0x1a')](function(_0x5b8fac){const _0x29fab0=_0x2cd424;return _0x52e9d7[_0x29fab0('0x1e')](_0x33d5e5['query'][_0x29fab0('0x25')],{'transaction':_0x5b8fac})[_0x29fab0('0x53')](function(){const _0x4b9458=_0x29fab0;if(!_[_0x4b9458('0x2a')](_0x4cc7bb))return _0x52e9d7[_0x4b9458('0x1f')](_0x4cc7bb,{'transaction':_0x5b8fac});})[_0x29fab0('0x53')](function(){const _0x5e78ec=_0x29fab0;_0x4cc7bb[_0x5e78ec('0x61')](function(_0x58fd47){const _0x3e2902=_0x5e78ec;socket[_0x3e2902('0x1c')](_0x3e2902('0x6f'),{'UserId':_0x58fd47,'ChatQueueId':_0x52e9d7['id']});});});});});});})[_0x31ae82('0x53')](respondWithStatusCode(_0x15608f,null))[_0x31ae82('0x3d')](handleError(_0x15608f,null));},exports['addAgents']=function(_0x5f39cd,_0x26f538){const _0x1764a6=_0xf59830;return db[_0x1764a6('0x55')][_0x1764a6('0x15')]({'where':{'id':_0x5f39cd['params']['id']}})[_0x1764a6('0x53')](function(_0x3145ae){const _0x4668b9=_0x1764a6;if(_0x3145ae)return _0x3145ae[_0x4668b9('0xd')](_0x5f39cd[_0x4668b9('0x0')][_0x4668b9('0x25')],{'through':_['omit'](_0x5f39cd['body'],[_0x4668b9('0x25'),'id'])})['then'](function(_0xb97d12){const _0x37a672=_0x4668b9;for(let _0x42dcc9=0x0;_0x42dcc9<_0x5f39cd[_0x37a672('0x0')]['ids'][_0x37a672('0x5b')];_0x42dcc9+=0x1){socket['emit'](_0x37a672('0x52'),{'UserId':_0x5f39cd[_0x37a672('0x0')][_0x37a672('0x25')][_0x42dcc9],'ChatQueueId':_0x5f39cd[_0x37a672('0x28')]['id']});}return _0xb97d12;});})['then'](respondWithResult(_0x26f538,null))[_0x1764a6('0x3d')](handleError(_0x26f538,null));},exports[_0xf59830('0x1f')]=function(_0x5a9a42,_0x1a7fed){const _0x31e3fe=_0xf59830;return db[_0x31e3fe('0x55')][_0x31e3fe('0x15')]({'where':{'id':_0x5a9a42[_0x31e3fe('0x28')]['id']}})[_0x31e3fe('0x53')](handleEntityNotFound(_0x1a7fed,null))[_0x31e3fe('0x53')](function(_0x3a3287){const _0x5d140f=_0x31e3fe;if(_0x3a3287)return _0x3a3287[_0x5d140f('0x1f')](_0x5a9a42[_0x5d140f('0x29')]['ids'])['then'](function(){const _0x4c2b12=_0x5d140f;if(_[_0x4c2b12('0x3c')](_0x5a9a42[_0x4c2b12('0x29')][_0x4c2b12('0x25')]))for(let _0x33c1de=0x0;_0x33c1de<_0x5a9a42[_0x4c2b12('0x29')][_0x4c2b12('0x25')][_0x4c2b12('0x5b')];_0x33c1de+=0x1){socket['emit'](_0x4c2b12('0x6f'),{'UserId':Number(_0x5a9a42[_0x4c2b12('0x29')][_0x4c2b12('0x25')][_0x33c1de]),'ChatQueueId':Number(_0x5a9a42[_0x4c2b12('0x28')]['id'])});}else socket[_0x4c2b12('0x1c')](_0x4c2b12('0x6f'),{'UserId':Number(_0x5a9a42['query']['ids']),'ChatQueueId':Number(_0x5a9a42[_0x4c2b12('0x28')]['id'])});});})[_0x31e3fe('0x53')](respondWithStatusCode(_0x1a7fed,null))[_0x31e3fe('0x3d')](handleError(_0x1a7fed,null));},exports[_0xf59830('0x34')]=function(_0x2823bd,_0x2149d8){const _0x3e0058=_0xf59830;let _0x579fe8={};const _0x460c2e={};let _0x536fad,_0x767e18;return db['ChatQueue'][_0x3e0058('0x15')]({'where':{'id':_0x2823bd[_0x3e0058('0x28')]['id']}})[_0x3e0058('0x53')](handleEntityNotFound(_0x2149d8,null))[_0x3e0058('0x53')](function(_0x48d0e0){const _0x542fac=_0x3e0058;if(_0x48d0e0)return _0x536fad=_0x48d0e0,_0x460c2e['model']=_['keys'](db[_0x542fac('0xa')]['rawAttributes']),_0x460c2e[_0x542fac('0x29')]=_[_0x542fac('0x5f')](_0x2823bd['query']),_0x460c2e['filters']=_[_0x542fac('0x12')](_0x460c2e[_0x542fac('0x50')],_0x460c2e[_0x542fac('0x29')]),_0x579fe8[_0x542fac('0x5d')]=_[_0x542fac('0x12')](_0x460c2e[_0x542fac('0x50')],qs['fields'](_0x2823bd[_0x542fac('0x29')]['fields'])),_0x579fe8[_0x542fac('0x5d')]=_0x579fe8[_0x542fac('0x5d')][_0x542fac('0x5b')]?_0x579fe8['attributes']:_0x460c2e[_0x542fac('0x50')],_0x579fe8[_0x542fac('0x51')]=qs[_0x542fac('0x4a')](_0x2823bd[_0x542fac('0x29')]['sort']),_0x579fe8['where']=qs[_0x542fac('0x5c')](_[_0x542fac('0x5')](_0x2823bd['query'],_0x460c2e[_0x542fac('0x5c')])),_0x2823bd[_0x542fac('0x29')]['filter']&&(_0x579fe8[_0x542fac('0x46')]=_[_0x542fac('0x6c')](_0x579fe8[_0x542fac('0x46')],{[Op['or']]:_[_0x542fac('0xe')](_0x579fe8['attributes'],function(_0x84a3d){const _0x38d427=_0x542fac,_0x2fa63f={};return _0x2fa63f[_0x84a3d]={[Op['like']]:'%'+_0x2823bd[_0x38d427('0x29')][_0x38d427('0x48')]+'%'},_0x2fa63f;})})),_0x579fe8=_[_0x542fac('0x6c')]({},_0x579fe8,_0x2823bd[_0x542fac('0x35')]),_0x536fad['getAgents'](_0x579fe8);})['then'](function(_0x89b654){const _0x448ec6=_0x3e0058;if(_0x89b654)return _0x767e18=_0x89b654[_0x448ec6('0x5b')],typeof _0x2823bd['query'][_0x448ec6('0x5e')]===_0x448ec6('0x66')&&(_0x579fe8['limit']=qs['limit'](_0x2823bd['query'][_0x448ec6('0x3e')]),_0x579fe8[_0x448ec6('0x1')]=qs[_0x448ec6('0x1')](_0x2823bd[_0x448ec6('0x29')]['offset'])),_0x536fad[_0x448ec6('0x34')](_0x579fe8);})[_0x3e0058('0x53')](function(_0x1d0fc0){if(_0x1d0fc0)return _0x1d0fc0?{'count':_0x767e18,'rows':_0x1d0fc0}:null;})['then'](respondWithResult(_0x2149d8,null))[_0x3e0058('0x3d')](handleError(_0x2149d8,null));}; \ No newline at end of file +const a95_0x1b6c=['join','Team','user','isEmpty','TeamId','status','team_has_chat_queues','../../components/parsers/qs','addAgents','where','filter','findAndCountAll','update','catch','order','autoAssociation','count','userChatQueue:save','map','transaction','rows','UserProfileResource','lodash','VIRTUAL','includeAll','describe','SIP','undefined','ut.UserId\x20=\x20?','../../config/logger','UserChatQueue','name','userChatQueue:remove','model','offset','nolimit','addTeams','format','squel','User','../../mysqldb','Content-Range','getAgents','emit','body','util','Agents','agent','online','options','chatPause','ids','sort','query','SELECT','every','ChatQueueId\x20=\x20?','userProfileId','send','length','filters','ChatQueues','findAll','omit','role','key','getTeams','merge','rawAttributes','error','%s/%s','forEach','fields','ChatQueue','sequelize','findOne','includes','user_has_teams','flatMap','then','sendStatus','value','field','updatedAt','params','attributes','intersection','get','removeAgents','fieldName','UserId','index','like','./chatQueue.socket','create','getMembers','include','pick','../../rediscache','limit','end','push','set','keys','Unable\x20to\x20retrieve\x20the\x20current\x20user','createdAt','isArray','destroy','compact','json','register'];(function(_0x431b9f,_0x1b6c14){const _0x11a7cf=function(_0x4db8bb){while(--_0x4db8bb){_0x431b9f['push'](_0x431b9f['shift']());}};_0x11a7cf(++_0x1b6c14);}(a95_0x1b6c,0xa3));const a95_0x11a7=function(_0x431b9f,_0x1b6c14){_0x431b9f=_0x431b9f-0x0;let _0x11a7cf=a95_0x1b6c[_0x431b9f];return _0x11a7cf;};const _0x21d0db=a95_0x11a7;'use strict';const util=require(_0x21d0db('0x68')),_=require(_0x21d0db('0x51')),squel=require(_0x21d0db('0x61')),qs=require(_0x21d0db('0x42')),logger=require(_0x21d0db('0x58'))('api'),{getSocket}=require(_0x21d0db('0x2e')),db=require(_0x21d0db('0x63'))['db'],{Op,QueryTypes}=require(_0x21d0db('0x16')),socket=getSocket();require(_0x21d0db('0x29'))[_0x21d0db('0x3a')](socket);function respondWithStatusCode(_0x4db8bb,_0x11fdd3){return _0x11fdd3=_0x11fdd3||0xcc,function(_0xd3f381){const _0x12995b=a95_0x11a7;if(_0xd3f381)return _0x4db8bb[_0x12995b('0x1c')](_0x11fdd3);return _0x4db8bb['status'](_0x11fdd3)[_0x12995b('0x30')]();};}function respondWithResult(_0x503eb8,_0x85c6f6){return _0x85c6f6=_0x85c6f6||0xc8,function(_0x1f9bce){const _0xc54892=a95_0x11a7;if(_0x1f9bce)return _0x503eb8[_0xc54892('0x40')](_0x85c6f6)[_0xc54892('0x39')](_0x1f9bce);};}function respondWithFilteredResult(_0x59024a,_0x1e8317){return function(_0x2a1990){const _0xb2fca9=a95_0x11a7;if(_0x2a1990){const _0x35e575=_0x2a1990['count'],_0xc83f8d=_0x1e8317[_0xb2fca9('0x5d')];let _0x16bc69=_0x1e8317['offset']+_0x1e8317['limit'],_0x308e9b;return _0x16bc69>=_0x35e575?(_0x16bc69=_0x35e575,_0x308e9b=0xc8):_0x308e9b=0xce,_0x59024a[_0xb2fca9('0x40')](_0x308e9b),_0x59024a[_0xb2fca9('0x32')](_0xb2fca9('0x64'),_0xc83f8d+'-'+_0x16bc69+'/'+_0x35e575)[_0xb2fca9('0x39')](_0x2a1990);}return null;};}function saveUpdates(_0x148332){return function(_0x5a8b3a){const _0x2469fc=a95_0x11a7;if(_0x5a8b3a)return _0x5a8b3a[_0x2469fc('0x47')](_0x148332)[_0x2469fc('0x1b')](function(_0x58d4a2){return _0x58d4a2;});return null;};}function removeEntity(_0x307dee){return function(_0x515181){const _0x240ee3=a95_0x11a7;if(_0x515181)return _0x515181[_0x240ee3('0x37')]()['then'](function(){const _0x1a4164=_0x240ee3,_0x5cc063=_0x515181['get']({'plain':!![]}),_0x492df2=_0x1a4164('0x9');return db[_0x1a4164('0x50')][_0x1a4164('0x37')]({'where':{'type':_0x492df2,'resourceId':_0x5cc063['id']}})['then'](function(){return _0x515181;});})['then'](function(){const _0x237b1e=_0x240ee3;_0x307dee[_0x237b1e('0x40')](0xcc)[_0x237b1e('0x30')]();});};}function handleEntityNotFound(_0x15be80){return function(_0x56701a){const _0x2172c6=a95_0x11a7;return!_0x56701a&&_0x15be80[_0x2172c6('0x1c')](0x194),_0x56701a;};}function handleError(_0x2b1d28,_0x26ef75){return _0x26ef75=_0x26ef75||0x1f4,function(_0x41ac1c){const _0x8c49d3=a95_0x11a7;logger['error'](_0x41ac1c['stack']),_0x41ac1c[_0x8c49d3('0x5a')]&&delete _0x41ac1c['name'],_0x2b1d28['status'](_0x26ef75)[_0x8c49d3('0x6')](_0x41ac1c);};}exports[_0x21d0db('0x27')]=function(_0x166655,_0x18cb57){const _0x265977=_0x21d0db;let _0xa94a61={};const _0x36add8={},_0x1bf980={'count':0x0,'rows':[]},_0x51f923=_['map'](db[_0x265977('0x15')][_0x265977('0x10')],function(_0x429dc0){const _0x73df3a=_0x265977;return{'name':_0x429dc0[_0x73df3a('0x25')],'type':_0x429dc0['type'][_0x73df3a('0xd')]};});_0x36add8[_0x265977('0x5c')]=_['map'](_0x51f923,_0x265977('0x5a')),_0x36add8[_0x265977('0x1')]=_[_0x265977('0x33')](_0x166655[_0x265977('0x1')]),_0x36add8['filters']=_[_0x265977('0x22')](_0x36add8['model'],_0x36add8[_0x265977('0x1')]),_0xa94a61['attributes']=_[_0x265977('0x22')](_0x36add8['model'],qs[_0x265977('0x14')](_0x166655[_0x265977('0x1')][_0x265977('0x14')])),_0xa94a61['attributes']=_0xa94a61['attributes']['length']?_0xa94a61['attributes']:_0x36add8['model'];typeof _0x166655[_0x265977('0x1')]['nolimit']===_0x265977('0x56')&&(_0xa94a61['limit']=qs['limit'](_0x166655[_0x265977('0x1')][_0x265977('0x2f')]),_0xa94a61['offset']=qs[_0x265977('0x5d')](_0x166655[_0x265977('0x1')][_0x265977('0x5d')]));_0xa94a61[_0x265977('0x49')]=qs[_0x265977('0x0')](_0x166655['query'][_0x265977('0x0')]),_0xa94a61['where']=qs['filters'](_[_0x265977('0x2d')](_0x166655[_0x265977('0x1')],_0x36add8[_0x265977('0x8')]),_0x51f923);_0x166655['query'][_0x265977('0x45')]&&(_0xa94a61['where']=_[_0x265977('0xf')](_0xa94a61[_0x265977('0x44')],{[Op['or']]:_[_0x265977('0x4d')](_0x51f923,function(_0x245618){const _0x526a73=_0x265977;if(_0x245618['type']!==_0x526a73('0x52')){const _0x2e1deb={};return _0x2e1deb[_0x245618[_0x526a73('0x5a')]]={[Op[_0x526a73('0x28')]]:'%'+_0x166655[_0x526a73('0x1')][_0x526a73('0x45')]+'%'},_0x2e1deb;}})}));_0xa94a61=_[_0x265977('0xf')]({},_0xa94a61,_0x166655[_0x265977('0x6c')]);const _0xff5b74={'where':_0xa94a61['where']};return db[_0x265977('0x15')][_0x265977('0x4b')](_0xff5b74)[_0x265977('0x1b')](function(_0x55aa79){const _0x202cda=_0x265977;return _0x1bf980['count']=_0x55aa79,_0x166655[_0x202cda('0x1')][_0x202cda('0x53')]&&(_0xa94a61['include']=[{'all':!![]}]),db[_0x202cda('0x15')][_0x202cda('0xa')](_0xa94a61);})[_0x265977('0x1b')](function(_0x171803){const _0xafd822=_0x265977;return _0x1bf980[_0xafd822('0x4f')]=_0x171803,_0x1bf980;})[_0x265977('0x1b')](respondWithFilteredResult(_0x18cb57,_0xa94a61))['catch'](handleError(_0x18cb57,null));},exports['show']=function(_0xe8c3f2,_0x4fb4a3){const _0x5b26ab=_0x21d0db;let _0x26582a={'raw':!![],'where':{'id':_0xe8c3f2['params']['id']}};const _0x2691c4={};return _0x2691c4[_0x5b26ab('0x5c')]=_[_0x5b26ab('0x33')](db['ChatQueue'][_0x5b26ab('0x10')]),_0x2691c4['query']=_[_0x5b26ab('0x33')](_0xe8c3f2[_0x5b26ab('0x1')]),_0x2691c4[_0x5b26ab('0x8')]=_[_0x5b26ab('0x22')](_0x2691c4[_0x5b26ab('0x5c')],_0x2691c4['query']),_0x26582a[_0x5b26ab('0x21')]=_['intersection'](_0x2691c4[_0x5b26ab('0x5c')],qs['fields'](_0xe8c3f2[_0x5b26ab('0x1')][_0x5b26ab('0x14')])),_0x26582a['attributes']=_0x26582a[_0x5b26ab('0x21')][_0x5b26ab('0x7')]?_0x26582a['attributes']:_0x2691c4[_0x5b26ab('0x5c')],_0xe8c3f2[_0x5b26ab('0x1')][_0x5b26ab('0x53')]&&(_0x26582a[_0x5b26ab('0x2c')]=[{'all':!![]}]),_0x26582a=_[_0x5b26ab('0xf')]({},_0x26582a,_0xe8c3f2[_0x5b26ab('0x6c')]),db[_0x5b26ab('0x15')]['findOne'](_0x26582a)[_0x5b26ab('0x1b')](handleEntityNotFound(_0x4fb4a3,null))['then'](respondWithResult(_0x4fb4a3,null))['catch'](handleError(_0x4fb4a3,null));},exports['create']=function(_0x16c75e,_0xf03673){const _0x3e8101=_0x21d0db;return db[_0x3e8101('0x15')][_0x3e8101('0x2a')](_0x16c75e[_0x3e8101('0x67')],{})[_0x3e8101('0x1b')](function(_0x2906e0){const _0x391ee2=_0x3e8101,_0x25d477=_0x16c75e[_0x391ee2('0x3d')]['get']({'plain':!![]});if(!_0x25d477)throw new Error(_0x391ee2('0x34'));if(_0x25d477[_0x391ee2('0xc')]==='user'){const _0x229823=_0x2906e0[_0x391ee2('0x23')]({'plain':!![]}),_0x329963=_0x391ee2('0x9');return db['UserProfileSection'][_0x391ee2('0x17')]({'where':{'name':_0x329963,'userProfileId':_0x25d477[_0x391ee2('0x5')]},'raw':!![]})[_0x391ee2('0x1b')](function(_0x1587a8){const _0x36ca3c=_0x391ee2;return _0x1587a8&&_0x1587a8[_0x36ca3c('0x4a')]===0x0?db[_0x36ca3c('0x50')]['create']({'name':_0x229823['name'],'resourceId':_0x229823['id'],'type':_0x1587a8[_0x36ca3c('0x5a')],'sectionId':_0x1587a8['id']},{})[_0x36ca3c('0x1b')](function(){return _0x2906e0;}):_0x2906e0;})['catch'](function(_0x3966b7){const _0x1c2f36=_0x391ee2;logger[_0x1c2f36('0x11')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x3966b7);throw _0x3966b7;});}return _0x2906e0;})[_0x3e8101('0x1b')](respondWithResult(_0xf03673,0xc9))['catch'](handleError(_0xf03673,null));},exports[_0x21d0db('0x47')]=function(_0x53c376,_0x251633){const _0x4e29a2=_0x21d0db;return _0x53c376[_0x4e29a2('0x67')]['id']&&delete _0x53c376['body']['id'],db[_0x4e29a2('0x15')][_0x4e29a2('0x17')]({'where':{'id':_0x53c376[_0x4e29a2('0x20')]['id']}})[_0x4e29a2('0x1b')](handleEntityNotFound(_0x251633,null))[_0x4e29a2('0x1b')](saveUpdates(_0x53c376[_0x4e29a2('0x67')],null))[_0x4e29a2('0x1b')](respondWithResult(_0x251633,null))['catch'](handleError(_0x251633,null));},exports[_0x21d0db('0x37')]=function(_0x3c132e,_0x3c5765){const _0x3a63ec=_0x21d0db;return db[_0x3a63ec('0x15')][_0x3a63ec('0x17')]({'where':{'id':_0x3c132e[_0x3a63ec('0x20')]['id']}})[_0x3a63ec('0x1b')](handleEntityNotFound(_0x3c5765,null))[_0x3a63ec('0x1b')](removeEntity(_0x3c5765,null))[_0x3a63ec('0x48')](handleError(_0x3c5765,null));},exports[_0x21d0db('0x54')]=function(_0x5eb717,_0x5ad4d7){const _0x54811f=_0x21d0db;return db[_0x54811f('0x15')]['describe']()[_0x54811f('0x1b')](respondWithResult(_0x5ad4d7,null))['catch'](handleError(_0x5ad4d7,null));},exports[_0x21d0db('0x2b')]=function(_0x452f66,_0x16b9ea){const _0xbda9f8=_0x21d0db;let _0x4e4342={'raw':!![],'where':{}};const _0x26dc6d={};let _0x3f411e;return db[_0xbda9f8('0x15')]['findOne']({'where':{'id':_0x452f66[_0xbda9f8('0x20')]['id']}})[_0xbda9f8('0x1b')](handleEntityNotFound(_0x16b9ea,null))[_0xbda9f8('0x1b')](function(_0x4f03aa){const _0x3a4d3d=_0xbda9f8;if(_0x4f03aa)return _0x3f411e=_0x4f03aa[_0x3a4d3d('0x23')]({'plain':!![]}),_0x26dc6d[_0x3a4d3d('0x5c')]=_[_0x3a4d3d('0x33')](db[_0x3a4d3d('0x59')][_0x3a4d3d('0x10')]),_0x26dc6d[_0x3a4d3d('0x1')]=_[_0x3a4d3d('0x33')](_0x452f66[_0x3a4d3d('0x1')]),_0x26dc6d['filters']=_[_0x3a4d3d('0x22')](_0x26dc6d[_0x3a4d3d('0x5c')],_0x26dc6d['query']),_0x4e4342[_0x3a4d3d('0x21')]=_[_0x3a4d3d('0x22')](_0x26dc6d[_0x3a4d3d('0x5c')],qs[_0x3a4d3d('0x14')](_0x452f66[_0x3a4d3d('0x1')][_0x3a4d3d('0x14')])),_0x4e4342['attributes']=_0x4e4342['attributes'][_0x3a4d3d('0x7')]?_0x4e4342['attributes']:_0x26dc6d[_0x3a4d3d('0x5c')],typeof _0x452f66['query'][_0x3a4d3d('0x5e')]==='undefined'&&(_0x4e4342[_0x3a4d3d('0x2f')]=qs['limit'](_0x452f66[_0x3a4d3d('0x1')][_0x3a4d3d('0x2f')]),_0x4e4342[_0x3a4d3d('0x5d')]=qs[_0x3a4d3d('0x5d')](_0x452f66[_0x3a4d3d('0x1')]['offset'])),_0x4e4342[_0x3a4d3d('0x49')]=qs['sort'](_0x452f66[_0x3a4d3d('0x1')][_0x3a4d3d('0x0')]),_0x4e4342[_0x3a4d3d('0x44')]=qs[_0x3a4d3d('0x8')](_['pick'](_0x452f66['query'],_0x26dc6d[_0x3a4d3d('0x8')])),_0x4e4342[_0x3a4d3d('0x44')]['ChatQueueId']=_0x4f03aa['id'],_0x452f66[_0x3a4d3d('0x1')][_0x3a4d3d('0x45')]&&(_0x4e4342[_0x3a4d3d('0x44')]=_['merge'](_0x4e4342['where'],{[Op['or']]:_[_0x3a4d3d('0x4d')](_0x4e4342[_0x3a4d3d('0x21')],function(_0x3532d5){const _0x2f6335=_0x3a4d3d,_0x23cf27={};return _0x23cf27[_0x3532d5]={[Op[_0x2f6335('0x28')]]:'%'+_0x452f66[_0x2f6335('0x1')][_0x2f6335('0x45')]+'%'},_0x23cf27;})})),_0x4e4342=_['merge']({},_0x4e4342,_0x452f66[_0x3a4d3d('0x6c')]),db[_0x3a4d3d('0x59')][_0x3a4d3d('0xa')](_0x4e4342);})[_0xbda9f8('0x1b')](function(_0x2f6795){const _0x12f1d=_0xbda9f8;if(_0x2f6795)return db[_0x12f1d('0x62')][_0x12f1d('0x46')]({'where':{'id':_[_0x12f1d('0x4d')](_0x2f6795,_0x12f1d('0x26')),'role':_0x12f1d('0x6a')},'attributes':['id',_0x12f1d('0x5a'),_0x12f1d('0x6d'),_0x12f1d('0x1f'),_0x12f1d('0x35')]});})[_0xbda9f8('0x1b')](function(_0x178596){const _0x11eabf=_0xbda9f8;return _0x178596?{'count':_0x178596[_0x11eabf('0x4b')],'rows':_['map'](_0x178596['rows'],function(_0x5e6ea8){const _0x307356=_0x11eabf;return{'membername':_0x5e6ea8[_0x307356('0x5a')],'UserId':_0x5e6ea8['id'],'queue_name':_0x3f411e[_0x307356('0x5a')],'ChatQueueId':_0x3f411e['id'],'interface':util[_0x307356('0x60')](_0x307356('0x12'),_0x307356('0x55'),_0x5e6ea8[_0x307356('0x5a')]),'penalty':0x0,'paused':_0x5e6ea8[_0x307356('0x6d')],'createdAt':_0x5e6ea8[_0x307356('0x35')],'updatedAt':_0x5e6ea8[_0x307356('0x1f')]};})}:{'count':0x0,'rows':[]};})[_0xbda9f8('0x1b')](respondWithFilteredResult(_0x16b9ea,_0x4e4342))['catch'](handleError(_0x16b9ea,null));},exports['getTeams']=function(_0x10422f,_0x5250ff){const _0x4485d5=_0x21d0db;let _0x4bdbb1={};const _0x5795db={};let _0x5c69f9,_0x20ac2d;return db[_0x4485d5('0x15')][_0x4485d5('0x17')]({'where':{'id':_0x10422f[_0x4485d5('0x20')]['id']}})['then'](handleEntityNotFound(_0x5250ff,null))[_0x4485d5('0x1b')](function(_0xdd15a3){const _0x4107e8=_0x4485d5;if(_0xdd15a3)return _0x5c69f9=_0xdd15a3,_0x5795db[_0x4107e8('0x5c')]=_[_0x4107e8('0x33')](db[_0x4107e8('0x3c')]['rawAttributes']),_0x5795db[_0x4107e8('0x1')]=_[_0x4107e8('0x33')](_0x10422f[_0x4107e8('0x1')]),_0x5795db[_0x4107e8('0x8')]=_['intersection'](_0x5795db[_0x4107e8('0x5c')],_0x5795db[_0x4107e8('0x1')]),_0x4bdbb1[_0x4107e8('0x21')]=_['intersection'](_0x5795db[_0x4107e8('0x5c')],qs[_0x4107e8('0x14')](_0x10422f[_0x4107e8('0x1')]['fields'])),_0x4bdbb1[_0x4107e8('0x21')]=_0x4bdbb1[_0x4107e8('0x21')][_0x4107e8('0x7')]?_0x4bdbb1[_0x4107e8('0x21')]:_0x5795db[_0x4107e8('0x5c')],_0x4bdbb1[_0x4107e8('0x49')]=qs[_0x4107e8('0x0')](_0x10422f['query'][_0x4107e8('0x0')]),_0x4bdbb1[_0x4107e8('0x44')]=qs[_0x4107e8('0x8')](_[_0x4107e8('0x2d')](_0x10422f[_0x4107e8('0x1')],_0x5795db[_0x4107e8('0x8')])),_0x10422f[_0x4107e8('0x1')][_0x4107e8('0x45')]&&(_0x4bdbb1[_0x4107e8('0x44')]=_[_0x4107e8('0xf')](_0x4bdbb1[_0x4107e8('0x44')],{[Op['or']]:_[_0x4107e8('0x4d')](_0x4bdbb1[_0x4107e8('0x21')],function(_0x327c6c){const _0x3b1861=_0x4107e8,_0x1c746a={};return _0x1c746a[_0x327c6c]={[Op[_0x3b1861('0x28')]]:'%'+_0x10422f['query'][_0x3b1861('0x45')]+'%'},_0x1c746a;})})),_0x4bdbb1=_[_0x4107e8('0xf')]({},_0x4bdbb1,_0x10422f[_0x4107e8('0x6c')]),_0x5c69f9[_0x4107e8('0xe')](_0x4bdbb1);})[_0x4485d5('0x1b')](function(_0x14fc88){const _0x395400=_0x4485d5;if(_0x14fc88)return _0x20ac2d=_0x14fc88['length'],typeof _0x10422f['query'][_0x395400('0x5e')]===_0x395400('0x56')&&(_0x4bdbb1['limit']=qs['limit'](_0x10422f[_0x395400('0x1')][_0x395400('0x2f')]),_0x4bdbb1['offset']=qs[_0x395400('0x5d')](_0x10422f[_0x395400('0x1')][_0x395400('0x5d')])),_0x5c69f9['getTeams'](_0x4bdbb1);})[_0x4485d5('0x1b')](function(_0x212c36){if(_0x212c36)return _0x212c36?{'count':_0x20ac2d,'rows':_0x212c36}:null;})['then'](respondWithResult(_0x5250ff,null))[_0x4485d5('0x48')](handleError(_0x5250ff,null));},exports[_0x21d0db('0x5f')]=function(_0x5bf9b7,_0x2c9070){const _0x473347=_0x21d0db,_0x15e592=_0x5bf9b7[_0x473347('0x67')][_0x473347('0x6e')];return db[_0x473347('0x3c')][_0x473347('0xa')]({'where':{'id':_0x15e592},'attributes':['id'],'include':[{'model':db[_0x473347('0x62')],'as':_0x473347('0x69'),'attributes':['id',_0x473347('0x5a'),_0x473347('0x6b'),'voicePause','interface'],'raw':!![]}]})['then'](function(_0x3b1761){const _0x5e41c4=_0x473347;if(_0x3b1761){const _0x1f4676=_[_0x5e41c4('0x1a')](_0x3b1761,function(_0x40d3ba){const _0x36849d=_0x5e41c4,_0x15d8ec=_0x40d3ba[_0x36849d('0x23')]({'plain':!![]});return _0x15d8ec[_0x36849d('0x69')];});return db[_0x5e41c4('0x15')]['findOne']({'where':{'id':_0x5bf9b7['params']['id']}})[_0x5e41c4('0x1b')](function(_0x22f7be){return db['sequelize']['transaction'](function(_0x3552e0){const _0x6be951=a95_0x11a7;return _0x22f7be[_0x6be951('0x5f')](_0x15e592,{'transaction':_0x3552e0})[_0x6be951('0x1b')](function(){return Promise['each'](_0x1f4676,function(_0x283ad2){const _0x21bf91=a95_0x11a7;return db[_0x21bf91('0x59')]['findOrCreate']({'where':{'UserId':_0x283ad2['id'],'ChatQueueId':_0x5bf9b7[_0x21bf91('0x20')]['id']},'transaction':_0x3552e0});});})[_0x6be951('0x1b')](function(){const _0x57cfb9=_0x6be951;_0x1f4676[_0x57cfb9('0x13')](function(_0x30853d){const _0x975ea6=_0x57cfb9;socket[_0x975ea6('0x66')](_0x975ea6('0x4c'),{'UserId':_0x30853d['id'],'ChatQueueId':_0x22f7be['id']});});});});});}})[_0x473347('0x1b')](respondWithStatusCode(_0x2c9070,null))[_0x473347('0x48')](handleError(_0x2c9070,null));},exports['removeTeams']=function(_0x1bd8d2,_0x10b4c1){const _0x3f3062=_0x21d0db;return db[_0x3f3062('0x3c')]['findAll']({'where':{'id':_0x1bd8d2[_0x3f3062('0x1')][_0x3f3062('0x6e')]},'attributes':['id'],'include':[{'model':db[_0x3f3062('0x62')],'as':_0x3f3062('0x69'),'attributes':['id'],'raw':!![]}]})[_0x3f3062('0x1b')](handleEntityNotFound(_0x10b4c1,null))[_0x3f3062('0x1b')](function(_0x77bda2){const _0x363b5d=_0x3f3062,_0x451e2d=_['map'](_0x77bda2,'id');let _0x3efcdf=[];const _0x815222=[],_0x33dc37=squel['select']();_0x33dc37[_0x363b5d('0x1e')]('tq.TeamId')['from'](_0x363b5d('0x41'),'tq')[_0x363b5d('0x3b')](_0x363b5d('0x19'),'ut','ut.TeamId\x20=\x20tq.TeamId')[_0x363b5d('0x44')](_0x363b5d('0x4'),_0x1bd8d2['params']['id']);for(let _0x4f74ce=0x0;_0x4f74ce<_0x77bda2[_0x363b5d('0x7')];_0x4f74ce+=0x1){const _0x1b9f86=_0x77bda2[_0x4f74ce];for(let _0x3bc1be=0x0;_0x3bc1be<_0x1b9f86[_0x363b5d('0x69')]['length'];_0x3bc1be+=0x1){const _0x57bb42=_0x1b9f86[_0x363b5d('0x69')][_0x3bc1be],_0x4c163e=_0x33dc37['clone']();_0x4c163e['where'](_0x363b5d('0x57'),_0x57bb42['id']),_0x815222[_0x363b5d('0x31')](db['sequelize'][_0x363b5d('0x1')](_0x4c163e['toString'](),{'type':QueryTypes[_0x363b5d('0x2')]})[_0x363b5d('0x1b')](function(_0x383cb2){const _0xcc02de=_0x363b5d;if(_0x383cb2[_0xcc02de('0x7')]===0x1)return _0x57bb42['id'];else{const _0x2f1f64=_[_0xcc02de('0x3')](_[_0xcc02de('0x4d')](_0x383cb2,_0xcc02de('0x3f')),function(_0x29182f){const _0x30f825=_0xcc02de;return _[_0x30f825('0x18')](_0x451e2d,_0x29182f);});if(_0x2f1f64)return _0x57bb42['id'];}}));}}return Promise['all'](_0x815222)[_0x363b5d('0x1b')](function(_0x17d640){const _0x3639f9=_0x363b5d;return _0x3efcdf=_(_0x3efcdf)['union'](_0x17d640)[_0x3639f9('0x38')]()[_0x3639f9('0x1d')](),db[_0x3639f9('0x15')][_0x3639f9('0x17')]({'where':{'id':_0x1bd8d2[_0x3639f9('0x20')]['id']}})[_0x3639f9('0x1b')](function(_0xac7111){const _0x31b320=_0x3639f9;return db['sequelize'][_0x31b320('0x4e')](function(_0x41e6cf){const _0x3ba57f=_0x31b320;return _0xac7111['removeTeams'](_0x1bd8d2[_0x3ba57f('0x1')][_0x3ba57f('0x6e')],{'transaction':_0x41e6cf})[_0x3ba57f('0x1b')](function(){const _0x14c8f2=_0x3ba57f;if(!_[_0x14c8f2('0x3e')](_0x3efcdf))return _0xac7111['removeAgents'](_0x3efcdf,{'transaction':_0x41e6cf});})[_0x3ba57f('0x1b')](function(){const _0xd101c0=_0x3ba57f;_0x3efcdf[_0xd101c0('0x13')](function(_0xeb57a6){const _0x7cbd55=_0xd101c0;socket[_0x7cbd55('0x66')](_0x7cbd55('0x5b'),{'UserId':_0xeb57a6,'ChatQueueId':_0xac7111['id']});});});});});});})[_0x3f3062('0x1b')](respondWithStatusCode(_0x10b4c1,null))[_0x3f3062('0x48')](handleError(_0x10b4c1,null));},exports[_0x21d0db('0x43')]=function(_0x1831c7,_0x59098e){const _0x2710da=_0x21d0db;return db['ChatQueue']['findOne']({'where':{'id':_0x1831c7['params']['id']}})['then'](function(_0x2c2b7e){const _0x392c32=a95_0x11a7;if(_0x2c2b7e)return _0x2c2b7e[_0x392c32('0x43')](_0x1831c7[_0x392c32('0x67')][_0x392c32('0x6e')],{'through':_[_0x392c32('0xb')](_0x1831c7[_0x392c32('0x67')],[_0x392c32('0x6e'),'id'])})[_0x392c32('0x1b')](function(_0x153c7a){const _0x4ad33f=_0x392c32;for(let _0x2795e9=0x0;_0x2795e9<_0x1831c7['body'][_0x4ad33f('0x6e')][_0x4ad33f('0x7')];_0x2795e9+=0x1){socket[_0x4ad33f('0x66')](_0x4ad33f('0x4c'),{'UserId':_0x1831c7[_0x4ad33f('0x67')]['ids'][_0x2795e9],'ChatQueueId':_0x1831c7[_0x4ad33f('0x20')]['id']});}return _0x153c7a;});})[_0x2710da('0x1b')](respondWithResult(_0x59098e,null))['catch'](handleError(_0x59098e,null));},exports['removeAgents']=function(_0x4df238,_0x578f6c){const _0x3ed97b=_0x21d0db;return db['ChatQueue']['findOne']({'where':{'id':_0x4df238[_0x3ed97b('0x20')]['id']}})[_0x3ed97b('0x1b')](handleEntityNotFound(_0x578f6c,null))[_0x3ed97b('0x1b')](function(_0x50e133){const _0x58a55b=_0x3ed97b;if(_0x50e133)return _0x50e133[_0x58a55b('0x24')](_0x4df238['query']['ids'])['then'](function(){const _0x3c3f5b=_0x58a55b;if(_[_0x3c3f5b('0x36')](_0x4df238[_0x3c3f5b('0x1')]['ids']))for(let _0x242e82=0x0;_0x242e82<_0x4df238[_0x3c3f5b('0x1')][_0x3c3f5b('0x6e')][_0x3c3f5b('0x7')];_0x242e82+=0x1){socket[_0x3c3f5b('0x66')](_0x3c3f5b('0x5b'),{'UserId':Number(_0x4df238['query'][_0x3c3f5b('0x6e')][_0x242e82]),'ChatQueueId':Number(_0x4df238[_0x3c3f5b('0x20')]['id'])});}else socket[_0x3c3f5b('0x66')](_0x3c3f5b('0x5b'),{'UserId':Number(_0x4df238['query']['ids']),'ChatQueueId':Number(_0x4df238[_0x3c3f5b('0x20')]['id'])});});})[_0x3ed97b('0x1b')](respondWithStatusCode(_0x578f6c,null))[_0x3ed97b('0x48')](handleError(_0x578f6c,null));},exports[_0x21d0db('0x65')]=function(_0xf8cf33,_0x3b3e54){const _0xb581f1=_0x21d0db;let _0x23ebb0={};const _0x478304={};let _0x314123,_0x24fef0;return db[_0xb581f1('0x15')][_0xb581f1('0x17')]({'where':{'id':_0xf8cf33[_0xb581f1('0x20')]['id']}})[_0xb581f1('0x1b')](handleEntityNotFound(_0x3b3e54,null))[_0xb581f1('0x1b')](function(_0x11513b){const _0x4093c9=_0xb581f1;if(_0x11513b)return _0x314123=_0x11513b,_0x478304[_0x4093c9('0x5c')]=_['keys'](db[_0x4093c9('0x62')][_0x4093c9('0x10')]),_0x478304[_0x4093c9('0x1')]=_[_0x4093c9('0x33')](_0xf8cf33['query']),_0x478304[_0x4093c9('0x8')]=_[_0x4093c9('0x22')](_0x478304['model'],_0x478304['query']),_0x23ebb0['attributes']=_[_0x4093c9('0x22')](_0x478304['model'],qs['fields'](_0xf8cf33[_0x4093c9('0x1')]['fields'])),_0x23ebb0[_0x4093c9('0x21')]=_0x23ebb0['attributes'][_0x4093c9('0x7')]?_0x23ebb0[_0x4093c9('0x21')]:_0x478304[_0x4093c9('0x5c')],_0x23ebb0[_0x4093c9('0x49')]=qs[_0x4093c9('0x0')](_0xf8cf33[_0x4093c9('0x1')][_0x4093c9('0x0')]),_0x23ebb0['where']=qs['filters'](_[_0x4093c9('0x2d')](_0xf8cf33['query'],_0x478304[_0x4093c9('0x8')])),_0xf8cf33[_0x4093c9('0x1')][_0x4093c9('0x45')]&&(_0x23ebb0[_0x4093c9('0x44')]=_[_0x4093c9('0xf')](_0x23ebb0[_0x4093c9('0x44')],{[Op['or']]:_[_0x4093c9('0x4d')](_0x23ebb0[_0x4093c9('0x21')],function(_0x5dae67){const _0x498f76=_0x4093c9,_0x2a489e={};return _0x2a489e[_0x5dae67]={[Op['like']]:'%'+_0xf8cf33[_0x498f76('0x1')]['filter']+'%'},_0x2a489e;})})),_0x23ebb0=_[_0x4093c9('0xf')]({},_0x23ebb0,_0xf8cf33[_0x4093c9('0x6c')]),_0x314123[_0x4093c9('0x65')](_0x23ebb0);})[_0xb581f1('0x1b')](function(_0x5907e2){const _0x1528f9=_0xb581f1;if(_0x5907e2)return _0x24fef0=_0x5907e2['length'],typeof _0xf8cf33[_0x1528f9('0x1')][_0x1528f9('0x5e')]===_0x1528f9('0x56')&&(_0x23ebb0[_0x1528f9('0x2f')]=qs[_0x1528f9('0x2f')](_0xf8cf33[_0x1528f9('0x1')]['limit']),_0x23ebb0[_0x1528f9('0x5d')]=qs[_0x1528f9('0x5d')](_0xf8cf33['query'][_0x1528f9('0x5d')])),_0x314123[_0x1528f9('0x65')](_0x23ebb0);})[_0xb581f1('0x1b')](function(_0x1ca42a){if(_0x1ca42a)return _0x1ca42a?{'count':_0x24fef0,'rows':_0x1ca42a}:null;})[_0xb581f1('0x1b')](respondWithResult(_0x3b3e54,null))[_0xb581f1('0x48')](handleError(_0x3b3e54,null));}; \ No newline at end of file diff --git a/server/api/chatQueue/chatQueue.events.js b/server/api/chatQueue/chatQueue.events.js index ece80c1..f299970 100644 --- a/server/api/chatQueue/chatQueue.events.js +++ b/server/api/chatQueue/chatQueue.events.js @@ -1 +1 @@ -const a96_0x5342=['remove','emit','../../mysqldb','save','undefined','exports','addHook'];(function(_0x3b87d2,_0x53424e){const _0x198472=function(_0x1a2184){while(--_0x1a2184){_0x3b87d2['push'](_0x3b87d2['shift']());}};_0x198472(++_0x53424e);}(a96_0x5342,0xd0));const a96_0x1984=function(_0x3b87d2,_0x53424e){_0x3b87d2=_0x3b87d2-0x0;let _0x198472=a96_0x5342[_0x3b87d2];return _0x198472;};const _0x5a90df=a96_0x1984;'use strict';const EventEmitter=require('events'),ChatQueue=require(_0x5a90df('0x4'))['db']['ChatQueue'],ChatQueueEvents=new EventEmitter();ChatQueueEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x5a90df('0x5'),'afterUpdate':'update','afterDestroy':_0x5a90df('0x2')};function emitEvent(_0x1a2184){return function(_0xe5018c){const _0x5e2ad4=a96_0x1984;ChatQueueEvents[_0x5e2ad4('0x3')](_0x1a2184+':'+_0xe5018c['id'],_0xe5018c),ChatQueueEvents[_0x5e2ad4('0x3')](_0x1a2184,_0xe5018c);};}for(const e in events){if(typeof events[e]!==_0x5a90df('0x6')){const event=events[e];ChatQueue[_0x5a90df('0x1')](e,emitEvent(event));}}module[_0x5a90df('0x0')]=ChatQueueEvents; \ No newline at end of file +const a96_0x183a=['ChatQueue','emit','events','remove','addHook','setMaxListeners','save'];(function(_0x2f90dc,_0x183a4e){const _0x297bc9=function(_0x2fb75e){while(--_0x2fb75e){_0x2f90dc['push'](_0x2f90dc['shift']());}};_0x297bc9(++_0x183a4e);}(a96_0x183a,0x68));const a96_0x297b=function(_0x2f90dc,_0x183a4e){_0x2f90dc=_0x2f90dc-0x0;let _0x297bc9=a96_0x183a[_0x2f90dc];return _0x297bc9;};const _0x1089a7=a96_0x297b;'use strict';const EventEmitter=require(_0x1089a7('0x3')),ChatQueue=require('../../mysqldb')['db'][_0x1089a7('0x1')],ChatQueueEvents=new EventEmitter();ChatQueueEvents[_0x1089a7('0x6')](0x0);const events={'afterCreate':_0x1089a7('0x0'),'afterUpdate':'update','afterDestroy':_0x1089a7('0x4')};function emitEvent(_0x2fb75e){return function(_0x2b6b57){const _0x36d932=a96_0x297b;ChatQueueEvents[_0x36d932('0x2')](_0x2fb75e+':'+_0x2b6b57['id'],_0x2b6b57),ChatQueueEvents['emit'](_0x2fb75e,_0x2b6b57);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];ChatQueue[_0x1089a7('0x5')](e,emitEvent(event));}}module['exports']=ChatQueueEvents; \ No newline at end of file diff --git a/server/api/chatQueue/chatQueue.model.js b/server/api/chatQueue/chatQueue.model.js index 5a9218f..6b7d643 100644 --- a/server/api/chatQueue/chatQueue.model.js +++ b/server/api/chatQueue/chatQueue.model.js @@ -1 +1 @@ -const a97_0x111b=['chat_queues','define','exports','ChatQueue','./chatQueue.attributes'];(function(_0x5e803d,_0x111bc8){const _0x124b70=function(_0x4fde32){while(--_0x4fde32){_0x5e803d['push'](_0x5e803d['shift']());}};_0x124b70(++_0x111bc8);}(a97_0x111b,0x139));const a97_0x124b=function(_0x5e803d,_0x111bc8){_0x5e803d=_0x5e803d-0x0;let _0x124b70=a97_0x111b[_0x5e803d];return _0x124b70;};const _0x4223aa=a97_0x124b;'use strict';const attributes=require(_0x4223aa('0x1'));module[_0x4223aa('0x4')]=function(_0x4fde32){const _0x48012b=_0x4223aa,_0x5df309=_0x4fde32[_0x48012b('0x3')](_0x48012b('0x0'),attributes,{'tableName':_0x48012b('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5df309;}; \ No newline at end of file +const a97_0x323f=['define','exports','ChatQueue','./chatQueue.attributes'];(function(_0x2d44d7,_0x323f49){const _0x119fa=function(_0x2f738a){while(--_0x2f738a){_0x2d44d7['push'](_0x2d44d7['shift']());}};_0x119fa(++_0x323f49);}(a97_0x323f,0x1ce));const a97_0x119f=function(_0x2d44d7,_0x323f49){_0x2d44d7=_0x2d44d7-0x0;let _0x119fa=a97_0x323f[_0x2d44d7];return _0x119fa;};const _0x34ab66=a97_0x119f;'use strict';const attributes=require(_0x34ab66('0x1'));module[_0x34ab66('0x3')]=function(_0x2f738a){const _0x54aa63=_0x34ab66,_0x3ff973=_0x2f738a[_0x54aa63('0x2')](_0x54aa63('0x0'),attributes,{'tableName':'chat_queues','paranoid':![],'indexes':[],'timestamps':!![]});return _0x3ff973;}; \ No newline at end of file diff --git a/server/api/chatQueue/chatQueue.rpc.js b/server/api/chatQueue/chatQueue.rpc.js index bd19474..2037c4e 100644 --- a/server/api/chatQueue/chatQueue.rpc.js +++ b/server/api/chatQueue/chatQueue.rpc.js @@ -1 +1 @@ -const a98_0x4e25=['raw','limit','register','info','rpc','model','../../mysqldb','findOne','debug','map','ShowChatQueue','include','options','ChatQueue','findAll','then','../../rediscache','message','attributes','error','../../config/logger','lodash','GetChatQueue','where'];(function(_0x1b58c9,_0x4e259b){const _0x4e729d=function(_0x35d0f4){while(--_0x35d0f4){_0x1b58c9['push'](_0x1b58c9['shift']());}};_0x4e729d(++_0x4e259b);}(a98_0x4e25,0x118));const a98_0x4e72=function(_0x1b58c9,_0x4e259b){_0x1b58c9=_0x1b58c9-0x0;let _0x4e729d=a98_0x4e25[_0x1b58c9];return _0x4e729d;};const _0xde065a=a98_0x4e72;'use strict';const _=require(_0xde065a('0x5')),db=require(_0xde065a('0xe'))['db'],logger=require(_0xde065a('0x4'))(_0xde065a('0xc')),{getSocket}=require(_0xde065a('0x0')),socket=getSocket();require('./chatQueue.socket')[_0xde065a('0xa')](socket),exports['GetChatQueue']=function(_0x35d0f4){const _0x3a763b=this;return new Promise(function(_0x13ca09,_0x51a4aa){const _0x240b13=a98_0x4e72;return db[_0x240b13('0x15')][_0x240b13('0x16')]({'raw':_0x35d0f4['options']?_0x35d0f4[_0x240b13('0x14')][_0x240b13('0x8')]===undefined?!![]:![]:!![],'where':_0x35d0f4['options']?_0x35d0f4['options'][_0x240b13('0x7')]||null:null,'attributes':_0x35d0f4[_0x240b13('0x14')]?_0x35d0f4[_0x240b13('0x14')][_0x240b13('0x2')]||null:null,'limit':_0x35d0f4['options']?_0x35d0f4['options'][_0x240b13('0x9')]||null:null,'include':_0x35d0f4[_0x240b13('0x14')]?_0x35d0f4['options'][_0x240b13('0x13')]?_[_0x240b13('0x11')](_0x35d0f4[_0x240b13('0x14')][_0x240b13('0x13')],function(_0x19d156){const _0x43470f=_0x240b13;return{'model':db[_0x19d156[_0x43470f('0xd')]],'as':_0x19d156['as'],'attributes':_0x19d156[_0x43470f('0x2')],'include':_0x19d156['include']?_[_0x43470f('0x11')](_0x19d156['include'],function(_0x1b186f){const _0x3c0ee7=_0x43470f;return{'model':db[_0x1b186f[_0x3c0ee7('0xd')]],'as':_0x1b186f['as'],'attributes':_0x1b186f[_0x3c0ee7('0x2')],'include':_0x1b186f[_0x3c0ee7('0x13')]?_[_0x3c0ee7('0x11')](_0x1b186f['include'],function(_0x5a8d6f){const _0x380141=_0x3c0ee7;return{'model':db[_0x5a8d6f['model']],'as':_0x5a8d6f['as'],'attributes':_0x5a8d6f[_0x380141('0x2')]};}):[]};}):[]};}):[]:[]})[_0x240b13('0x17')](function(_0x4905c7){const _0x397cb3=_0x240b13;logger[_0x397cb3('0xb')](_0x397cb3('0x6'),_0x35d0f4),logger[_0x397cb3('0x10')](_0x397cb3('0x6'),_0x35d0f4,JSON['stringify'](_0x4905c7)),_0x13ca09(_0x4905c7);})['catch'](function(_0x5832ff){const _0x1757fc=_0x240b13;logger[_0x1757fc('0x3')]('GetChatQueue',_0x5832ff[_0x1757fc('0x1')],_0x35d0f4),_0x51a4aa(_0x3a763b[_0x1757fc('0x3')](0x1f4,_0x5832ff['message']));});});},exports[_0xde065a('0x12')]=function(_0x10f95e){const _0x1d1f67=this;return new Promise(function(_0x2685f6,_0x1ba05a){const _0x55909d=a98_0x4e72;return db[_0x55909d('0x15')][_0x55909d('0xf')]({'raw':_0x10f95e['options']?_0x10f95e[_0x55909d('0x14')][_0x55909d('0x8')]===undefined?!![]:![]:!![],'where':_0x10f95e['options']?_0x10f95e[_0x55909d('0x14')][_0x55909d('0x7')]||null:null,'attributes':_0x10f95e['options']?_0x10f95e[_0x55909d('0x14')][_0x55909d('0x2')]||null:null,'include':_0x10f95e['options']?_0x10f95e[_0x55909d('0x14')]['include']?_['map'](_0x10f95e[_0x55909d('0x14')][_0x55909d('0x13')],function(_0xecf20f){const _0x4e2d45=_0x55909d;return{'model':db[_0xecf20f[_0x4e2d45('0xd')]],'as':_0xecf20f['as'],'attributes':_0xecf20f['attributes'],'include':_0xecf20f[_0x4e2d45('0x13')]?_[_0x4e2d45('0x11')](_0xecf20f[_0x4e2d45('0x13')],function(_0x555766){const _0x522145=_0x4e2d45;return{'model':db[_0x555766['model']],'as':_0x555766['as'],'attributes':_0x555766[_0x522145('0x2')],'include':_0x555766[_0x522145('0x13')]?_[_0x522145('0x11')](_0x555766[_0x522145('0x13')],function(_0x215745){return{'model':db[_0x215745['model']],'as':_0x215745['as'],'attributes':_0x215745['attributes']};}):[]};}):[]};}):[]:[]})[_0x55909d('0x17')](function(_0x3a7f7b){const _0x19e4be=_0x55909d;logger[_0x19e4be('0xb')](_0x19e4be('0x12'),_0x10f95e),logger[_0x19e4be('0x10')](_0x19e4be('0x12'),_0x10f95e,JSON['stringify'](_0x3a7f7b)),_0x2685f6(_0x3a7f7b);})['catch'](function(_0x228761){const _0x17f1bd=_0x55909d;logger[_0x17f1bd('0x3')]('ShowChatQueue',_0x228761['message'],_0x10f95e),_0x1ba05a(_0x1d1f67[_0x17f1bd('0x3')](0x1f4,_0x228761[_0x17f1bd('0x1')]));});});}; \ No newline at end of file +const a98_0x21f4=['message','error','debug','register','then','../../mysqldb','raw','map','include','../../config/logger','./chatQueue.socket','../../rediscache','catch','findOne','where','stringify','ShowChatQueue','model','attributes','options','rpc','lodash','GetChatQueue','info','ChatQueue'];(function(_0x1a2842,_0x21f479){const _0x245878=function(_0x839169){while(--_0x839169){_0x1a2842['push'](_0x1a2842['shift']());}};_0x245878(++_0x21f479);}(a98_0x21f4,0xf1));const a98_0x2458=function(_0x1a2842,_0x21f479){_0x1a2842=_0x1a2842-0x0;let _0x245878=a98_0x21f4[_0x1a2842];return _0x245878;};const _0x3efcd6=a98_0x2458;'use strict';const _=require(_0x3efcd6('0x5')),db=require(_0x3efcd6('0xe'))['db'],logger=require(_0x3efcd6('0x12'))(_0x3efcd6('0x4')),{getSocket}=require(_0x3efcd6('0x14')),socket=getSocket();require(_0x3efcd6('0x13'))[_0x3efcd6('0xc')](socket),exports['GetChatQueue']=function(_0x839169){const _0x24ffde=this;return new Promise(function(_0x319deb,_0x544b09){const _0x5de094=a98_0x2458;return db['ChatQueue']['findAll']({'raw':_0x839169['options']?_0x839169[_0x5de094('0x3')][_0x5de094('0xf')]===undefined?!![]:![]:!![],'where':_0x839169[_0x5de094('0x3')]?_0x839169[_0x5de094('0x3')][_0x5de094('0x17')]||null:null,'attributes':_0x839169[_0x5de094('0x3')]?_0x839169[_0x5de094('0x3')]['attributes']||null:null,'limit':_0x839169[_0x5de094('0x3')]?_0x839169[_0x5de094('0x3')]['limit']||null:null,'include':_0x839169[_0x5de094('0x3')]?_0x839169[_0x5de094('0x3')]['include']?_[_0x5de094('0x10')](_0x839169[_0x5de094('0x3')][_0x5de094('0x11')],function(_0x54cf2c){const _0x2fa040=_0x5de094;return{'model':db[_0x54cf2c['model']],'as':_0x54cf2c['as'],'attributes':_0x54cf2c['attributes'],'include':_0x54cf2c[_0x2fa040('0x11')]?_[_0x2fa040('0x10')](_0x54cf2c[_0x2fa040('0x11')],function(_0x5ceeb7){const _0x1aea2a=_0x2fa040;return{'model':db[_0x5ceeb7['model']],'as':_0x5ceeb7['as'],'attributes':_0x5ceeb7[_0x1aea2a('0x2')],'include':_0x5ceeb7['include']?_[_0x1aea2a('0x10')](_0x5ceeb7['include'],function(_0x5c8335){const _0x29a95f=_0x1aea2a;return{'model':db[_0x5c8335[_0x29a95f('0x1')]],'as':_0x5c8335['as'],'attributes':_0x5c8335['attributes']};}):[]};}):[]};}):[]:[]})[_0x5de094('0xd')](function(_0x172b2e){const _0x5ece9f=_0x5de094;logger['info'](_0x5ece9f('0x6'),_0x839169),logger['debug'](_0x5ece9f('0x6'),_0x839169,JSON[_0x5ece9f('0x18')](_0x172b2e)),_0x319deb(_0x172b2e);})[_0x5de094('0x15')](function(_0x4c2e5c){const _0x883a38=_0x5de094;logger[_0x883a38('0xa')](_0x883a38('0x6'),_0x4c2e5c[_0x883a38('0x9')],_0x839169),_0x544b09(_0x24ffde[_0x883a38('0xa')](0x1f4,_0x4c2e5c[_0x883a38('0x9')]));});});},exports[_0x3efcd6('0x0')]=function(_0x39088d){const _0x4d63a9=this;return new Promise(function(_0xca6761,_0x2782f2){const _0xe896d2=a98_0x2458;return db[_0xe896d2('0x8')][_0xe896d2('0x16')]({'raw':_0x39088d[_0xe896d2('0x3')]?_0x39088d[_0xe896d2('0x3')][_0xe896d2('0xf')]===undefined?!![]:![]:!![],'where':_0x39088d['options']?_0x39088d[_0xe896d2('0x3')]['where']||null:null,'attributes':_0x39088d[_0xe896d2('0x3')]?_0x39088d[_0xe896d2('0x3')]['attributes']||null:null,'include':_0x39088d[_0xe896d2('0x3')]?_0x39088d['options'][_0xe896d2('0x11')]?_['map'](_0x39088d['options']['include'],function(_0x1e7c5f){const _0x31c9d2=_0xe896d2;return{'model':db[_0x1e7c5f[_0x31c9d2('0x1')]],'as':_0x1e7c5f['as'],'attributes':_0x1e7c5f[_0x31c9d2('0x2')],'include':_0x1e7c5f[_0x31c9d2('0x11')]?_[_0x31c9d2('0x10')](_0x1e7c5f['include'],function(_0x25b549){const _0x151e1d=_0x31c9d2;return{'model':db[_0x25b549[_0x151e1d('0x1')]],'as':_0x25b549['as'],'attributes':_0x25b549[_0x151e1d('0x2')],'include':_0x25b549[_0x151e1d('0x11')]?_[_0x151e1d('0x10')](_0x25b549[_0x151e1d('0x11')],function(_0x23d134){const _0x2e09f0=_0x151e1d;return{'model':db[_0x23d134[_0x2e09f0('0x1')]],'as':_0x23d134['as'],'attributes':_0x23d134[_0x2e09f0('0x2')]};}):[]};}):[]};}):[]:[]})[_0xe896d2('0xd')](function(_0x21cabd){const _0x29ec41=_0xe896d2;logger[_0x29ec41('0x7')](_0x29ec41('0x0'),_0x39088d),logger[_0x29ec41('0xb')]('ShowChatQueue',_0x39088d,JSON[_0x29ec41('0x18')](_0x21cabd)),_0xca6761(_0x21cabd);})[_0xe896d2('0x15')](function(_0x2a091e){const _0x2f3585=_0xe896d2;logger[_0x2f3585('0xa')]('ShowChatQueue',_0x2a091e[_0x2f3585('0x9')],_0x39088d),_0x2782f2(_0x4d63a9['error'](0x1f4,_0x2a091e[_0x2f3585('0x9')]));});});}; \ No newline at end of file diff --git a/server/api/chatQueue/chatQueue.socket.js b/server/api/chatQueue/chatQueue.socket.js index c6f8e54..e78985c 100644 --- a/server/api/chatQueue/chatQueue.socket.js +++ b/server/api/chatQueue/chatQueue.socket.js @@ -1 +1 @@ -const a99_0x2d08=['chatQueue:','./chatQueue.events','length','save','emit','remove'];(function(_0x1f05a8,_0x2d0802){const _0x25e922=function(_0x49bf78){while(--_0x49bf78){_0x1f05a8['push'](_0x1f05a8['shift']());}};_0x25e922(++_0x2d0802);}(a99_0x2d08,0xf1));const a99_0x25e9=function(_0x1f05a8,_0x2d0802){_0x1f05a8=_0x1f05a8-0x0;let _0x25e922=a99_0x2d08[_0x1f05a8];return _0x25e922;};const _0x5d58a0=a99_0x25e9;'use strict';const ChatQueueEvents=require(_0x5d58a0('0x0')),events=[_0x5d58a0('0x2'),_0x5d58a0('0x4'),'update'];function createListener(_0x49bf78,_0x16a3c9){return function(_0x3cf2ba){const _0x54dfcf=a99_0x25e9;_0x16a3c9[_0x54dfcf('0x3')](_0x49bf78,_0x3cf2ba);};}exports['register']=function(_0x4ea6a3){const _0x1bbfd6=_0x5d58a0;for(let _0x1bbdbd=0x0,_0x3af41f=events[_0x1bbfd6('0x1')];_0x1bbdbd<_0x3af41f;_0x1bbdbd++){const _0x3d69f2=events[_0x1bbdbd],_0xc2c455=createListener(_0x1bbfd6('0x5')+_0x3d69f2,_0x4ea6a3);ChatQueueEvents['on'](_0x3d69f2,_0xc2c455);}}; \ No newline at end of file +const a99_0x5add=['save'];(function(_0xb4798e,_0x5add47){const _0x510caa=function(_0x22331e){while(--_0x22331e){_0xb4798e['push'](_0xb4798e['shift']());}};_0x510caa(++_0x5add47);}(a99_0x5add,0x16d));const a99_0x510c=function(_0xb4798e,_0x5add47){_0xb4798e=_0xb4798e-0x0;let _0x510caa=a99_0x5add[_0xb4798e];return _0x510caa;};const _0x2ecff2=a99_0x510c;'use strict';const ChatQueueEvents=require('./chatQueue.events'),events=[_0x2ecff2('0x0'),'remove','update'];function createListener(_0x22331e,_0x2627fd){return function(_0x95a1e3){_0x2627fd['emit'](_0x22331e,_0x95a1e3);};}exports['register']=function(_0xa2fe08){for(let _0x39caae=0x0,_0x4089da=events['length'];_0x39caae<_0x4089da;_0x39caae++){const _0x416dbb=events[_0x39caae],_0x5a0960=createListener('chatQueue:'+_0x416dbb,_0xa2fe08);ChatQueueEvents['on'](_0x416dbb,_0x5a0960);}}; \ No newline at end of file diff --git a/server/api/chatQueue/index.js b/server/api/chatQueue/index.js index 321a36d..66112df 100644 --- a/server/api/chatQueue/index.js +++ b/server/api/chatQueue/index.js @@ -1 +1 @@ -const a100_0x5afe=['/:id/teams','put','express','../../components/auth/service','addTeams','exports','post','delete','index','update','/:id','getAgents','/describe','getTeams','./chatQueue.controller','addAgents','Router','isAuthenticated','show','/:id/users','get','create','describe','removeAgents'];(function(_0x2adb93,_0x5afead){const _0x24f8df=function(_0x17aece){while(--_0x17aece){_0x2adb93['push'](_0x2adb93['shift']());}};_0x24f8df(++_0x5afead);}(a100_0x5afe,0xfd));const a100_0x24f8=function(_0x2adb93,_0x5afead){_0x2adb93=_0x2adb93-0x0;let _0x24f8df=a100_0x5afe[_0x2adb93];return _0x24f8df;};const _0x56d151=a100_0x24f8;'use strict';const express=require(_0x56d151('0xd')),router=express[_0x56d151('0x3')](),auth=require(_0x56d151('0xe')),controller=require(_0x56d151('0x1'));router[_0x56d151('0x7')]('/',auth[_0x56d151('0x4')](),controller[_0x56d151('0x13')]),router[_0x56d151('0x7')](_0x56d151('0x17'),auth[_0x56d151('0x4')](),controller[_0x56d151('0x9')]),router[_0x56d151('0x7')](_0x56d151('0x15'),auth[_0x56d151('0x4')](),controller[_0x56d151('0x5')]),router[_0x56d151('0x7')]('/:id/members',auth[_0x56d151('0x4')](),controller['getMembers']),router['get'](_0x56d151('0xb'),auth[_0x56d151('0x4')](),controller[_0x56d151('0x0')]),router[_0x56d151('0x7')](_0x56d151('0x6'),auth[_0x56d151('0x4')](),controller[_0x56d151('0x16')]),router[_0x56d151('0x11')]('/',auth['isAuthenticated'](),controller[_0x56d151('0x8')]),router['post']('/:id/teams',auth[_0x56d151('0x4')](),controller[_0x56d151('0xf')]),router[_0x56d151('0x11')](_0x56d151('0x6'),auth['isAuthenticated'](),controller[_0x56d151('0x2')]),router[_0x56d151('0xc')]('/:id',auth[_0x56d151('0x4')](),controller[_0x56d151('0x14')]),router['delete'](_0x56d151('0x15'),auth['isAuthenticated'](),controller['destroy']),router['delete'](_0x56d151('0xb'),auth[_0x56d151('0x4')](),controller['removeTeams']),router[_0x56d151('0x12')](_0x56d151('0x6'),auth[_0x56d151('0x4')](),controller[_0x56d151('0xa')]),module[_0x56d151('0x10')]=router; \ No newline at end of file +const a100_0x3f9b=['./chatQueue.controller','isAuthenticated','addAgents','removeAgents','/describe','delete','getAgents','post','/:id','put','show','get','getMembers','create','express','Router','/:id/teams','addTeams','update','/:id/users','/:id/members','../../components/auth/service'];(function(_0x122757,_0x3f9b4a){const _0x1ea0af=function(_0x48cc77){while(--_0x48cc77){_0x122757['push'](_0x122757['shift']());}};_0x1ea0af(++_0x3f9b4a);}(a100_0x3f9b,0x1da));const a100_0x1ea0=function(_0x122757,_0x3f9b4a){_0x122757=_0x122757-0x0;let _0x1ea0af=a100_0x3f9b[_0x122757];return _0x1ea0af;};const _0x50ea17=a100_0x1ea0;'use strict';const express=require(_0x50ea17('0x2')),router=express[_0x50ea17('0x3')](),auth=require(_0x50ea17('0x9')),controller=require(_0x50ea17('0xa'));router[_0x50ea17('0x15')]('/',auth['isAuthenticated'](),controller['index']),router[_0x50ea17('0x15')](_0x50ea17('0xe'),auth['isAuthenticated'](),controller['describe']),router[_0x50ea17('0x15')](_0x50ea17('0x12'),auth[_0x50ea17('0xb')](),controller[_0x50ea17('0x14')]),router[_0x50ea17('0x15')](_0x50ea17('0x8'),auth[_0x50ea17('0xb')](),controller[_0x50ea17('0x0')]),router[_0x50ea17('0x15')]('/:id/teams',auth[_0x50ea17('0xb')](),controller['getTeams']),router['get'](_0x50ea17('0x7'),auth[_0x50ea17('0xb')](),controller[_0x50ea17('0x10')]),router[_0x50ea17('0x11')]('/',auth[_0x50ea17('0xb')](),controller[_0x50ea17('0x1')]),router[_0x50ea17('0x11')](_0x50ea17('0x4'),auth[_0x50ea17('0xb')](),controller[_0x50ea17('0x5')]),router['post'](_0x50ea17('0x7'),auth[_0x50ea17('0xb')](),controller[_0x50ea17('0xc')]),router[_0x50ea17('0x13')](_0x50ea17('0x12'),auth[_0x50ea17('0xb')](),controller[_0x50ea17('0x6')]),router[_0x50ea17('0xf')](_0x50ea17('0x12'),auth[_0x50ea17('0xb')](),controller['destroy']),router[_0x50ea17('0xf')]('/:id/teams',auth[_0x50ea17('0xb')](),controller['removeTeams']),router[_0x50ea17('0xf')]('/:id/users',auth[_0x50ea17('0xb')](),controller[_0x50ea17('0xd')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/chatQueueReport/chatQueueReport.attributes.js b/server/api/chatQueueReport/chatQueueReport.attributes.js index 3f7bf5b..f4c3cb6 100644 --- a/server/api/chatQueueReport/chatQueueReport.attributes.js +++ b/server/api/chatQueueReport/chatQueueReport.attributes.js @@ -1 +1 @@ -const a101_0x23e6=['DATE','STRING','exports','sequelize'];(function(_0x152d93,_0x23e6ac){const _0x138c1b=function(_0xd42fde){while(--_0xd42fde){_0x152d93['push'](_0x152d93['shift']());}};_0x138c1b(++_0x23e6ac);}(a101_0x23e6,0x14d));const a101_0x138c=function(_0x152d93,_0x23e6ac){_0x152d93=_0x152d93-0x0;let _0x138c1b=a101_0x23e6[_0x152d93];return _0x138c1b;};const _0x139d25=a101_0x138c;'use strict';const Sequelize=require(_0x139d25('0x2'));module[_0x139d25('0x1')]={'uniqueid':{'type':Sequelize[_0x139d25('0x0')],'allowNull':![]},'from':{'type':Sequelize[_0x139d25('0x0')]},'joinAt':{'type':Sequelize[_0x139d25('0x3')]},'leaveAt':{'type':Sequelize[_0x139d25('0x3')]},'acceptAt':{'type':Sequelize[_0x139d25('0x3')]},'exitAt':{'type':Sequelize[_0x139d25('0x3')]},'reason':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a101_0x49fc=['STRING','sequelize','DATE'];(function(_0x24b827,_0x49fc81){const _0x322561=function(_0x222869){while(--_0x222869){_0x24b827['push'](_0x24b827['shift']());}};_0x322561(++_0x49fc81);}(a101_0x49fc,0x8b));const a101_0x3225=function(_0x24b827,_0x49fc81){_0x24b827=_0x24b827-0x0;let _0x322561=a101_0x49fc[_0x24b827];return _0x322561;};const _0x57d153=a101_0x3225;'use strict';const Sequelize=require(_0x57d153('0x0'));module['exports']={'uniqueid':{'type':Sequelize[_0x57d153('0x2')],'allowNull':![]},'from':{'type':Sequelize[_0x57d153('0x2')]},'joinAt':{'type':Sequelize['DATE']},'leaveAt':{'type':Sequelize[_0x57d153('0x1')]},'acceptAt':{'type':Sequelize[_0x57d153('0x1')]},'exitAt':{'type':Sequelize[_0x57d153('0x1')]},'reason':{'type':Sequelize[_0x57d153('0x2')]}}; \ No newline at end of file diff --git a/server/api/chatQueueReport/chatQueueReport.controller.js b/server/api/chatQueueReport/chatQueueReport.controller.js index 2dc4335..706702e 100644 --- a/server/api/chatQueueReport/chatQueueReport.controller.js +++ b/server/api/chatQueueReport/chatQueueReport.controller.js @@ -1 +1 @@ -const a102_0x4809=['destroy','body','findOne','ChatQueueReport','length','type','undefined','Content-Range','sort','offset','status','pick','VIRTUAL','options','create','show','end','order','attributes','filters','where','api','stack','../../mysqldb','json','filter','update','../../components/parsers/qs','count','name','include','map','keys','sequelize','rawAttributes','query','includeAll','error','describe','then','lodash','set','nolimit','model','catch','limit','fields','params','intersection','rows','merge'];(function(_0x5993fc,_0x480970){const _0x27c6ef=function(_0x44156c){while(--_0x44156c){_0x5993fc['push'](_0x5993fc['shift']());}};_0x27c6ef(++_0x480970);}(a102_0x4809,0x179));const a102_0x27c6=function(_0x5993fc,_0x480970){_0x5993fc=_0x5993fc-0x0;let _0x27c6ef=a102_0x4809[_0x5993fc];return _0x27c6ef;};const _0x5a6eba=a102_0x27c6;'use strict';const _=require(_0x5a6eba('0x14')),qs=require(_0x5a6eba('0x7')),logger=require('../../config/logger')(_0x5a6eba('0x1')),db=require(_0x5a6eba('0x3'))['db'],{Op}=require(_0x5a6eba('0xd'));function respondWithResult(_0x44156c,_0x408f1e){return _0x408f1e=_0x408f1e||0xc8,function(_0x288693){const _0x1f9951=a102_0x27c6;if(_0x288693)return _0x44156c[_0x1f9951('0x29')](_0x408f1e)[_0x1f9951('0x4')](_0x288693);};}function respondWithFilteredResult(_0x5bfba1,_0x2a34cf){return function(_0x190de0){const _0x1f57e7=a102_0x27c6;if(_0x190de0){const _0x3d5940=_0x190de0[_0x1f57e7('0x8')],_0x40cbdd=_0x2a34cf[_0x1f57e7('0x28')];let _0x4cdd70=_0x2a34cf[_0x1f57e7('0x28')]+_0x2a34cf['limit'],_0x352e87;return _0x4cdd70>=_0x3d5940?(_0x4cdd70=_0x3d5940,_0x352e87=0xc8):_0x352e87=0xce,_0x5bfba1[_0x1f57e7('0x29')](_0x352e87),_0x5bfba1[_0x1f57e7('0x15')](_0x1f57e7('0x26'),_0x40cbdd+'-'+_0x4cdd70+'/'+_0x3d5940)[_0x1f57e7('0x4')](_0x190de0);}return null;};}function saveUpdates(_0x5a6d45){return function(_0x407f9c){const _0x483a71=a102_0x27c6;if(_0x407f9c)return _0x407f9c['update'](_0x5a6d45)[_0x483a71('0x13')](function(_0x1e9d95){return _0x1e9d95;});return null;};}function removeEntity(_0x30e237){return function(_0x241759){const _0x48eadf=a102_0x27c6;if(_0x241759)return _0x241759[_0x48eadf('0x1f')]()[_0x48eadf('0x13')](function(){const _0x2d8af4=_0x48eadf;_0x30e237[_0x2d8af4('0x29')](0xcc)[_0x2d8af4('0x2f')]();});};}function handleEntityNotFound(_0x2051e6){return function(_0x266f60){return!_0x266f60&&_0x2051e6['sendStatus'](0x194),_0x266f60;};}function handleError(_0x5a2b84,_0x57bb1d){return _0x57bb1d=_0x57bb1d||0x1f4,function(_0x552fe2){const _0x5318f3=a102_0x27c6;logger[_0x5318f3('0x11')](_0x552fe2[_0x5318f3('0x2')]),_0x552fe2[_0x5318f3('0x9')]&&delete _0x552fe2[_0x5318f3('0x9')],_0x5a2b84[_0x5318f3('0x29')](_0x57bb1d)['send'](_0x552fe2);};}exports['index']=function(_0x1b9798,_0x44214a){const _0x3d4422=_0x5a6eba;let _0xd51d07={};const _0x2802a1={},_0x4b63e8={'count':0x0,'rows':[]},_0x8c6fa0=_[_0x3d4422('0xb')](db[_0x3d4422('0x22')]['rawAttributes'],function(_0x2465d1){const _0x1fed73=_0x3d4422;return{'name':_0x2465d1['fieldName'],'type':_0x2465d1[_0x1fed73('0x24')]['key']};});_0x2802a1['model']=_[_0x3d4422('0xb')](_0x8c6fa0,_0x3d4422('0x9')),_0x2802a1[_0x3d4422('0xf')]=_[_0x3d4422('0xc')](_0x1b9798[_0x3d4422('0xf')]),_0x2802a1[_0x3d4422('0x32')]=_[_0x3d4422('0x1c')](_0x2802a1[_0x3d4422('0x17')],_0x2802a1[_0x3d4422('0xf')]),_0xd51d07['attributes']=_[_0x3d4422('0x1c')](_0x2802a1[_0x3d4422('0x17')],qs['fields'](_0x1b9798[_0x3d4422('0xf')][_0x3d4422('0x1a')])),_0xd51d07[_0x3d4422('0x31')]=_0xd51d07['attributes'][_0x3d4422('0x23')]?_0xd51d07[_0x3d4422('0x31')]:_0x2802a1[_0x3d4422('0x17')];typeof _0x1b9798[_0x3d4422('0xf')][_0x3d4422('0x16')]===_0x3d4422('0x25')&&(_0xd51d07[_0x3d4422('0x19')]=qs[_0x3d4422('0x19')](_0x1b9798[_0x3d4422('0xf')][_0x3d4422('0x19')]),_0xd51d07['offset']=qs[_0x3d4422('0x28')](_0x1b9798[_0x3d4422('0xf')][_0x3d4422('0x28')]));_0xd51d07[_0x3d4422('0x30')]=qs[_0x3d4422('0x27')](_0x1b9798['query']['sort']),_0xd51d07[_0x3d4422('0x0')]=qs[_0x3d4422('0x32')](_[_0x3d4422('0x2a')](_0x1b9798['query'],_0x2802a1[_0x3d4422('0x32')]),_0x8c6fa0);_0x1b9798[_0x3d4422('0xf')][_0x3d4422('0x5')]&&(_0xd51d07[_0x3d4422('0x0')]=_[_0x3d4422('0x1e')](_0xd51d07[_0x3d4422('0x0')],{[Op['or']]:_[_0x3d4422('0xb')](_0x8c6fa0,function(_0x1f52aa){const _0x14aa48=_0x3d4422;if(_0x1f52aa[_0x14aa48('0x24')]!==_0x14aa48('0x2b')){const _0x13d24b={};return _0x13d24b[_0x1f52aa[_0x14aa48('0x9')]]={[Op['like']]:'%'+_0x1b9798['query']['filter']+'%'},_0x13d24b;}})}));_0xd51d07=_[_0x3d4422('0x1e')]({},_0xd51d07,_0x1b9798[_0x3d4422('0x2c')]);const _0x2445d9={'where':_0xd51d07[_0x3d4422('0x0')]};return db[_0x3d4422('0x22')]['count'](_0x2445d9)[_0x3d4422('0x13')](function(_0x1f316f){const _0x47dbed=_0x3d4422;return _0x4b63e8[_0x47dbed('0x8')]=_0x1f316f,_0x1b9798[_0x47dbed('0xf')][_0x47dbed('0x10')]&&(_0xd51d07[_0x47dbed('0xa')]=[{'all':!![]}]),db[_0x47dbed('0x22')]['findAll'](_0xd51d07);})['then'](function(_0x1df0c6){const _0x10d01a=_0x3d4422;return _0x4b63e8[_0x10d01a('0x1d')]=_0x1df0c6,_0x4b63e8;})[_0x3d4422('0x13')](respondWithFilteredResult(_0x44214a,_0xd51d07))[_0x3d4422('0x18')](handleError(_0x44214a,null));},exports[_0x5a6eba('0x2e')]=function(_0x52fcbf,_0x20a1a7){const _0x30c775=_0x5a6eba;let _0x578dac={'raw':!![],'where':{'id':_0x52fcbf['params']['id']}};const _0x57d7f6={};return _0x57d7f6[_0x30c775('0x17')]=_[_0x30c775('0xc')](db['ChatQueueReport'][_0x30c775('0xe')]),_0x57d7f6[_0x30c775('0xf')]=_['keys'](_0x52fcbf[_0x30c775('0xf')]),_0x57d7f6[_0x30c775('0x32')]=_[_0x30c775('0x1c')](_0x57d7f6[_0x30c775('0x17')],_0x57d7f6[_0x30c775('0xf')]),_0x578dac[_0x30c775('0x31')]=_[_0x30c775('0x1c')](_0x57d7f6[_0x30c775('0x17')],qs[_0x30c775('0x1a')](_0x52fcbf[_0x30c775('0xf')][_0x30c775('0x1a')])),_0x578dac[_0x30c775('0x31')]=_0x578dac['attributes'][_0x30c775('0x23')]?_0x578dac[_0x30c775('0x31')]:_0x57d7f6[_0x30c775('0x17')],_0x52fcbf[_0x30c775('0xf')][_0x30c775('0x10')]&&(_0x578dac[_0x30c775('0xa')]=[{'all':!![]}]),_0x578dac=_[_0x30c775('0x1e')]({},_0x578dac,_0x52fcbf[_0x30c775('0x2c')]),db[_0x30c775('0x22')][_0x30c775('0x21')](_0x578dac)[_0x30c775('0x13')](handleEntityNotFound(_0x20a1a7,null))['then'](respondWithResult(_0x20a1a7,null))[_0x30c775('0x18')](handleError(_0x20a1a7,null));},exports['create']=function(_0x202e5e,_0x10ec7a){const _0x32d233=_0x5a6eba;return db[_0x32d233('0x22')][_0x32d233('0x2d')](_0x202e5e[_0x32d233('0x20')],{})[_0x32d233('0x13')](respondWithResult(_0x10ec7a,0xc9))[_0x32d233('0x18')](handleError(_0x10ec7a,null));},exports[_0x5a6eba('0x6')]=function(_0xe553ce,_0x4cd286){const _0x153afb=_0x5a6eba;return _0xe553ce[_0x153afb('0x20')]['id']&&delete _0xe553ce['body']['id'],db[_0x153afb('0x22')][_0x153afb('0x21')]({'where':{'id':_0xe553ce[_0x153afb('0x1b')]['id']}})[_0x153afb('0x13')](handleEntityNotFound(_0x4cd286,null))[_0x153afb('0x13')](saveUpdates(_0xe553ce[_0x153afb('0x20')],null))[_0x153afb('0x13')](respondWithResult(_0x4cd286,null))[_0x153afb('0x18')](handleError(_0x4cd286,null));},exports[_0x5a6eba('0x1f')]=function(_0x422e63,_0x455898){const _0x8094f=_0x5a6eba;return db[_0x8094f('0x22')][_0x8094f('0x21')]({'where':{'id':_0x422e63[_0x8094f('0x1b')]['id']}})[_0x8094f('0x13')](handleEntityNotFound(_0x455898,null))['then'](removeEntity(_0x455898,null))[_0x8094f('0x18')](handleError(_0x455898,null));},exports[_0x5a6eba('0x12')]=function(_0x358226,_0x13fbb6){const _0x434c08=_0x5a6eba;return db['ChatQueueReport'][_0x434c08('0x12')]()['then'](respondWithResult(_0x13fbb6,null))[_0x434c08('0x18')](handleError(_0x13fbb6,null));}; \ No newline at end of file +const a102_0x54ff=['create','like','lodash','include','../../components/parsers/qs','includeAll','body','../../mysqldb','show','findOne','describe','sequelize','error','destroy','VIRTUAL','undefined','limit','send','../../config/logger','filters','attributes','length','stack','merge','fieldName','type','ChatQueueReport','json','options','Content-Range','sort','nolimit','filter','params','findAll','set','end','where','order','query','update','count','offset','pick','model','status','keys','then','fields','map','catch','name','intersection'];(function(_0xdfe434,_0x54ffeb){const _0x32081e=function(_0x329cec){while(--_0x329cec){_0xdfe434['push'](_0xdfe434['shift']());}};_0x32081e(++_0x54ffeb);}(a102_0x54ff,0x9e));const a102_0x3208=function(_0xdfe434,_0x54ffeb){_0xdfe434=_0xdfe434-0x0;let _0x32081e=a102_0x54ff[_0xdfe434];return _0x32081e;};const _0x14b404=a102_0x3208;'use strict';const _=require(_0x14b404('0x3')),qs=require(_0x14b404('0x5')),logger=require(_0x14b404('0x13'))('api'),db=require(_0x14b404('0x8'))['db'],{Op}=require(_0x14b404('0xc'));function respondWithResult(_0x329cec,_0x48b89f){return _0x48b89f=_0x48b89f||0xc8,function(_0x3a4927){const _0x5778f3=a102_0x3208;if(_0x3a4927)return _0x329cec[_0x5778f3('0x2e')](_0x48b89f)[_0x5778f3('0x1c')](_0x3a4927);};}function respondWithFilteredResult(_0x4879ed,_0x2072e7){return function(_0x3d14ea){const _0xbb0407=a102_0x3208;if(_0x3d14ea){const _0xdb39a6=_0x3d14ea[_0xbb0407('0x2a')],_0x2b0ed3=_0x2072e7[_0xbb0407('0x2b')];let _0x5eccb8=_0x2072e7['offset']+_0x2072e7[_0xbb0407('0x11')],_0x3b305a;return _0x5eccb8>=_0xdb39a6?(_0x5eccb8=_0xdb39a6,_0x3b305a=0xc8):_0x3b305a=0xce,_0x4879ed[_0xbb0407('0x2e')](_0x3b305a),_0x4879ed[_0xbb0407('0x24')](_0xbb0407('0x1e'),_0x2b0ed3+'-'+_0x5eccb8+'/'+_0xdb39a6)[_0xbb0407('0x1c')](_0x3d14ea);}return null;};}function saveUpdates(_0x452008){return function(_0x13b0bf){const _0x204074=a102_0x3208;if(_0x13b0bf)return _0x13b0bf['update'](_0x452008)[_0x204074('0x30')](function(_0x4e884d){return _0x4e884d;});return null;};}function removeEntity(_0x2561f6){return function(_0x293f36){const _0x13dc39=a102_0x3208;if(_0x293f36)return _0x293f36[_0x13dc39('0xe')]()[_0x13dc39('0x30')](function(){const _0x5edc80=_0x13dc39;_0x2561f6[_0x5edc80('0x2e')](0xcc)[_0x5edc80('0x25')]();});};}function handleEntityNotFound(_0xcec93c){return function(_0x4f539b){return!_0x4f539b&&_0xcec93c['sendStatus'](0x194),_0x4f539b;};}function handleError(_0x1325d2,_0x1cdf50){return _0x1cdf50=_0x1cdf50||0x1f4,function(_0x532e3a){const _0x365a09=a102_0x3208;logger[_0x365a09('0xd')](_0x532e3a[_0x365a09('0x17')]),_0x532e3a[_0x365a09('0x34')]&&delete _0x532e3a[_0x365a09('0x34')],_0x1325d2[_0x365a09('0x2e')](_0x1cdf50)[_0x365a09('0x12')](_0x532e3a);};}exports['index']=function(_0x49fc5f,_0x81d969){const _0x360ebc=_0x14b404;let _0x1df542={};const _0xa8a1ac={},_0x456392={'count':0x0,'rows':[]},_0x58c48b=_['map'](db[_0x360ebc('0x1b')]['rawAttributes'],function(_0x3e19bc){const _0x5c9b43=_0x360ebc;return{'name':_0x3e19bc[_0x5c9b43('0x19')],'type':_0x3e19bc[_0x5c9b43('0x1a')]['key']};});_0xa8a1ac[_0x360ebc('0x2d')]=_['map'](_0x58c48b,_0x360ebc('0x34')),_0xa8a1ac[_0x360ebc('0x28')]=_[_0x360ebc('0x2f')](_0x49fc5f['query']),_0xa8a1ac['filters']=_[_0x360ebc('0x0')](_0xa8a1ac[_0x360ebc('0x2d')],_0xa8a1ac[_0x360ebc('0x28')]),_0x1df542[_0x360ebc('0x15')]=_[_0x360ebc('0x0')](_0xa8a1ac[_0x360ebc('0x2d')],qs['fields'](_0x49fc5f[_0x360ebc('0x28')]['fields'])),_0x1df542[_0x360ebc('0x15')]=_0x1df542['attributes']['length']?_0x1df542[_0x360ebc('0x15')]:_0xa8a1ac['model'];typeof _0x49fc5f[_0x360ebc('0x28')][_0x360ebc('0x20')]===_0x360ebc('0x10')&&(_0x1df542['limit']=qs[_0x360ebc('0x11')](_0x49fc5f['query'][_0x360ebc('0x11')]),_0x1df542[_0x360ebc('0x2b')]=qs[_0x360ebc('0x2b')](_0x49fc5f[_0x360ebc('0x28')][_0x360ebc('0x2b')]));_0x1df542[_0x360ebc('0x27')]=qs[_0x360ebc('0x1f')](_0x49fc5f[_0x360ebc('0x28')][_0x360ebc('0x1f')]),_0x1df542['where']=qs[_0x360ebc('0x14')](_[_0x360ebc('0x2c')](_0x49fc5f[_0x360ebc('0x28')],_0xa8a1ac['filters']),_0x58c48b);_0x49fc5f[_0x360ebc('0x28')][_0x360ebc('0x21')]&&(_0x1df542['where']=_[_0x360ebc('0x18')](_0x1df542[_0x360ebc('0x26')],{[Op['or']]:_[_0x360ebc('0x32')](_0x58c48b,function(_0x5710cf){const _0x518630=_0x360ebc;if(_0x5710cf[_0x518630('0x1a')]!==_0x518630('0xf')){const _0x4fb1bf={};return _0x4fb1bf[_0x5710cf['name']]={[Op[_0x518630('0x2')]]:'%'+_0x49fc5f['query'][_0x518630('0x21')]+'%'},_0x4fb1bf;}})}));_0x1df542=_[_0x360ebc('0x18')]({},_0x1df542,_0x49fc5f[_0x360ebc('0x1d')]);const _0x11ed47={'where':_0x1df542[_0x360ebc('0x26')]};return db[_0x360ebc('0x1b')][_0x360ebc('0x2a')](_0x11ed47)[_0x360ebc('0x30')](function(_0xddd04){const _0x58b89b=_0x360ebc;return _0x456392[_0x58b89b('0x2a')]=_0xddd04,_0x49fc5f['query'][_0x58b89b('0x6')]&&(_0x1df542[_0x58b89b('0x4')]=[{'all':!![]}]),db[_0x58b89b('0x1b')][_0x58b89b('0x23')](_0x1df542);})[_0x360ebc('0x30')](function(_0x23970d){return _0x456392['rows']=_0x23970d,_0x456392;})[_0x360ebc('0x30')](respondWithFilteredResult(_0x81d969,_0x1df542))['catch'](handleError(_0x81d969,null));},exports[_0x14b404('0x9')]=function(_0x2b11be,_0x5257af){const _0x4bb166=_0x14b404;let _0x63914={'raw':!![],'where':{'id':_0x2b11be['params']['id']}};const _0x293aaa={};return _0x293aaa[_0x4bb166('0x2d')]=_[_0x4bb166('0x2f')](db['ChatQueueReport']['rawAttributes']),_0x293aaa[_0x4bb166('0x28')]=_['keys'](_0x2b11be['query']),_0x293aaa['filters']=_[_0x4bb166('0x0')](_0x293aaa[_0x4bb166('0x2d')],_0x293aaa['query']),_0x63914[_0x4bb166('0x15')]=_[_0x4bb166('0x0')](_0x293aaa[_0x4bb166('0x2d')],qs['fields'](_0x2b11be[_0x4bb166('0x28')][_0x4bb166('0x31')])),_0x63914[_0x4bb166('0x15')]=_0x63914[_0x4bb166('0x15')][_0x4bb166('0x16')]?_0x63914[_0x4bb166('0x15')]:_0x293aaa[_0x4bb166('0x2d')],_0x2b11be['query'][_0x4bb166('0x6')]&&(_0x63914[_0x4bb166('0x4')]=[{'all':!![]}]),_0x63914=_['merge']({},_0x63914,_0x2b11be[_0x4bb166('0x1d')]),db[_0x4bb166('0x1b')][_0x4bb166('0xa')](_0x63914)['then'](handleEntityNotFound(_0x5257af,null))[_0x4bb166('0x30')](respondWithResult(_0x5257af,null))['catch'](handleError(_0x5257af,null));},exports['create']=function(_0x3d44c0,_0xc00b5f){const _0xf35720=_0x14b404;return db[_0xf35720('0x1b')][_0xf35720('0x1')](_0x3d44c0[_0xf35720('0x7')],{})[_0xf35720('0x30')](respondWithResult(_0xc00b5f,0xc9))[_0xf35720('0x33')](handleError(_0xc00b5f,null));},exports[_0x14b404('0x29')]=function(_0x3fb079,_0x13d7cf){const _0x2c0c85=_0x14b404;return _0x3fb079['body']['id']&&delete _0x3fb079[_0x2c0c85('0x7')]['id'],db['ChatQueueReport'][_0x2c0c85('0xa')]({'where':{'id':_0x3fb079[_0x2c0c85('0x22')]['id']}})[_0x2c0c85('0x30')](handleEntityNotFound(_0x13d7cf,null))[_0x2c0c85('0x30')](saveUpdates(_0x3fb079[_0x2c0c85('0x7')],null))[_0x2c0c85('0x30')](respondWithResult(_0x13d7cf,null))['catch'](handleError(_0x13d7cf,null));},exports['destroy']=function(_0x10928b,_0xfbbb06){const _0x4b1722=_0x14b404;return db[_0x4b1722('0x1b')][_0x4b1722('0xa')]({'where':{'id':_0x10928b[_0x4b1722('0x22')]['id']}})[_0x4b1722('0x30')](handleEntityNotFound(_0xfbbb06,null))[_0x4b1722('0x30')](removeEntity(_0xfbbb06,null))[_0x4b1722('0x33')](handleError(_0xfbbb06,null));},exports[_0x14b404('0xb')]=function(_0x1a61d5,_0x4242e6){const _0x21822e=_0x14b404;return db[_0x21822e('0x1b')]['describe']()[_0x21822e('0x30')](respondWithResult(_0x4242e6,null))[_0x21822e('0x33')](handleError(_0x4242e6,null));}; \ No newline at end of file diff --git a/server/api/chatQueueReport/chatQueueReport.model.js b/server/api/chatQueueReport/chatQueueReport.model.js index bb3ac28..4ada0c9 100644 --- a/server/api/chatQueueReport/chatQueueReport.model.js +++ b/server/api/chatQueueReport/chatQueueReport.model.js @@ -1 +1 @@ -const a103_0x12f9=['./chatQueueReport.attributes','define','ChatQueueReport','uniqueid'];(function(_0x47a8ce,_0x12f9a6){const _0x5531e0=function(_0x3edeb9){while(--_0x3edeb9){_0x47a8ce['push'](_0x47a8ce['shift']());}};_0x5531e0(++_0x12f9a6);}(a103_0x12f9,0x12e));const a103_0x5531=function(_0x47a8ce,_0x12f9a6){_0x47a8ce=_0x47a8ce-0x0;let _0x5531e0=a103_0x12f9[_0x47a8ce];return _0x5531e0;};const _0x9d0817=a103_0x5531;'use strict';const attributes=require(_0x9d0817('0x2'));module['exports']=function(_0x3edeb9){const _0x45796e=_0x9d0817,_0x47a099=_0x3edeb9[_0x45796e('0x3')](_0x45796e('0x0'),attributes,{'tableName':'report_chat_queue','paranoid':![],'indexes':[{'name':_0x45796e('0x1'),'fields':[_0x45796e('0x1')]}],'timestamps':!![]});return _0x47a099;}; \ No newline at end of file +const a103_0x3d5a=['./chatQueueReport.attributes','exports','report_chat_queue','uniqueid','ChatQueueReport'];(function(_0x4d89bf,_0x3d5a1f){const _0x391ac9=function(_0xb214f4){while(--_0xb214f4){_0x4d89bf['push'](_0x4d89bf['shift']());}};_0x391ac9(++_0x3d5a1f);}(a103_0x3d5a,0x1c4));const a103_0x391a=function(_0x4d89bf,_0x3d5a1f){_0x4d89bf=_0x4d89bf-0x0;let _0x391ac9=a103_0x3d5a[_0x4d89bf];return _0x391ac9;};const _0x54504c=a103_0x391a;'use strict';const attributes=require(_0x54504c('0x3'));module[_0x54504c('0x4')]=function(_0xb214f4){const _0x30bd63=_0x54504c,_0x170483=_0xb214f4['define'](_0x30bd63('0x2'),attributes,{'tableName':_0x30bd63('0x0'),'paranoid':![],'indexes':[{'name':_0x30bd63('0x1'),'fields':['uniqueid']}],'timestamps':!![]});return _0x170483;}; \ No newline at end of file diff --git a/server/api/chatQueueReport/chatQueueReport.rpc.js b/server/api/chatQueueReport/chatQueueReport.rpc.js index 2676274..b562e36 100644 --- a/server/api/chatQueueReport/chatQueueReport.rpc.js +++ b/server/api/chatQueueReport/chatQueueReport.rpc.js @@ -1 +1 @@ -const a104_0x1568=['rpc','options','where','then','CreateChatQueueReport','info','catch','stringify','create','limit','raw','UpdateChatQueueReport','ChatQueueReport','error','body','debug','../../mysqldb','attributes','message'];(function(_0x44f8fb,_0x156824){const _0xbf263d=function(_0x3706a3){while(--_0x3706a3){_0x44f8fb['push'](_0x44f8fb['shift']());}};_0xbf263d(++_0x156824);}(a104_0x1568,0x1e5));const a104_0xbf26=function(_0x44f8fb,_0x156824){_0x44f8fb=_0x44f8fb-0x0;let _0xbf263d=a104_0x1568[_0x44f8fb];return _0xbf263d;};const _0x108dfa=a104_0xbf26;'use strict';const db=require(_0x108dfa('0x6'))['db'],logger=require('../../config/logger')(_0x108dfa('0x9'));exports[_0x108dfa('0xd')]=function(_0x3706a3){const _0x509c01=this;return new Promise(function(_0x137bdb,_0x4e1202){const _0x538d0c=a104_0xbf26;return db[_0x538d0c('0x2')][_0x538d0c('0x11')](_0x3706a3['body'],{'raw':_0x3706a3[_0x538d0c('0xa')]?_0x3706a3[_0x538d0c('0xa')]['raw']===undefined?!![]:![]:!![]})[_0x538d0c('0xc')](function(_0x55e653){const _0x20e277=_0x538d0c;logger['info'](_0x20e277('0xd'),_0x3706a3),logger[_0x20e277('0x5')](_0x20e277('0xd'),_0x3706a3,JSON[_0x20e277('0x10')](_0x55e653)),_0x137bdb(_0x55e653);})[_0x538d0c('0xf')](function(_0x32e281){const _0x18e047=_0x538d0c;logger[_0x18e047('0x3')]('CreateChatQueueReport',_0x32e281[_0x18e047('0x8')],_0x3706a3),_0x4e1202(_0x509c01[_0x18e047('0x3')](0x1f4,_0x32e281['message']));});});},exports[_0x108dfa('0x1')]=function(_0xd08df6){const _0xdaabd7=this;return new Promise(function(_0x18d479,_0x4ca58b){const _0x58f442=a104_0xbf26;return db[_0x58f442('0x2')]['update'](_0xd08df6[_0x58f442('0x4')],{'raw':_0xd08df6[_0x58f442('0xa')]?_0xd08df6[_0x58f442('0xa')][_0x58f442('0x0')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0xd08df6['options']?_0xd08df6[_0x58f442('0xa')][_0x58f442('0xb')]||null:null,'attributes':_0xd08df6[_0x58f442('0xa')]?_0xd08df6[_0x58f442('0xa')][_0x58f442('0x7')]||null:null,'limit':_0xd08df6[_0x58f442('0xa')]?_0xd08df6[_0x58f442('0xa')][_0x58f442('0x12')]||null:null})[_0x58f442('0xc')](function(_0x49c474){const _0x1eb5fd=_0x58f442;logger[_0x1eb5fd('0xe')](_0x1eb5fd('0x1'),_0xd08df6),logger[_0x1eb5fd('0x5')](_0x1eb5fd('0x1'),_0xd08df6,JSON[_0x1eb5fd('0x10')](_0x49c474)),_0x18d479(_0x49c474);})['catch'](function(_0x139fac){const _0x2eab23=_0x58f442;logger[_0x2eab23('0x3')](_0x2eab23('0x1'),_0x139fac[_0x2eab23('0x8')],_0xd08df6),_0x4ca58b(_0xdaabd7[_0x2eab23('0x3')](0x1f4,_0x139fac[_0x2eab23('0x8')]));});});}; \ No newline at end of file +const a104_0x2c63=['stringify','error','rpc','options','catch','UpdateChatQueueReport','create','limit','debug','message','info','ChatQueueReport','raw','update','body','CreateChatQueueReport','../../config/logger','then'];(function(_0x18a8e0,_0x2c6364){const _0x5c9e2f=function(_0x1357f7){while(--_0x1357f7){_0x18a8e0['push'](_0x18a8e0['shift']());}};_0x5c9e2f(++_0x2c6364);}(a104_0x2c63,0x158));const a104_0x5c9e=function(_0x18a8e0,_0x2c6364){_0x18a8e0=_0x18a8e0-0x0;let _0x5c9e2f=a104_0x2c63[_0x18a8e0];return _0x5c9e2f;};const _0xf8a9f6=a104_0x5c9e;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0xf8a9f6('0xe'))(_0xf8a9f6('0x0'));exports[_0xf8a9f6('0xd')]=function(_0x1357f7){const _0x23662d=this;return new Promise(function(_0x120ec7,_0x38a3a9){const _0x49ff6f=a104_0x5c9e;return db[_0x49ff6f('0x9')][_0x49ff6f('0x4')](_0x1357f7[_0x49ff6f('0xc')],{'raw':_0x1357f7[_0x49ff6f('0x1')]?_0x1357f7[_0x49ff6f('0x1')][_0x49ff6f('0xa')]===undefined?!![]:![]:!![]})[_0x49ff6f('0xf')](function(_0x687710){const _0x2fa5c1=_0x49ff6f;logger[_0x2fa5c1('0x8')](_0x2fa5c1('0xd'),_0x1357f7),logger['debug'](_0x2fa5c1('0xd'),_0x1357f7,JSON[_0x2fa5c1('0x10')](_0x687710)),_0x120ec7(_0x687710);})[_0x49ff6f('0x2')](function(_0x36c6a6){const _0x1adcd8=_0x49ff6f;logger['error']('CreateChatQueueReport',_0x36c6a6[_0x1adcd8('0x7')],_0x1357f7),_0x38a3a9(_0x23662d[_0x1adcd8('0x11')](0x1f4,_0x36c6a6[_0x1adcd8('0x7')]));});});},exports[_0xf8a9f6('0x3')]=function(_0x3ff638){const _0x29cc43=this;return new Promise(function(_0x15eb0c,_0x41f825){const _0x216fb7=a104_0x5c9e;return db[_0x216fb7('0x9')][_0x216fb7('0xb')](_0x3ff638[_0x216fb7('0xc')],{'raw':_0x3ff638[_0x216fb7('0x1')]?_0x3ff638[_0x216fb7('0x1')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x3ff638[_0x216fb7('0x1')]?_0x3ff638[_0x216fb7('0x1')]['where']||null:null,'attributes':_0x3ff638[_0x216fb7('0x1')]?_0x3ff638['options']['attributes']||null:null,'limit':_0x3ff638['options']?_0x3ff638[_0x216fb7('0x1')][_0x216fb7('0x5')]||null:null})[_0x216fb7('0xf')](function(_0x3e0590){const _0x77eaae=_0x216fb7;logger[_0x77eaae('0x8')](_0x77eaae('0x3'),_0x3ff638),logger[_0x77eaae('0x6')]('UpdateChatQueueReport',_0x3ff638,JSON['stringify'](_0x3e0590)),_0x15eb0c(_0x3e0590);})['catch'](function(_0x36f373){const _0x42e4d7=_0x216fb7;logger[_0x42e4d7('0x11')]('UpdateChatQueueReport',_0x36f373['message'],_0x3ff638),_0x41f825(_0x29cc43['error'](0x1f4,_0x36f373[_0x42e4d7('0x7')]));});});}; \ No newline at end of file diff --git a/server/api/chatQueueReport/index.js b/server/api/chatQueueReport/index.js index 9753420..9c3dd93 100644 --- a/server/api/chatQueueReport/index.js +++ b/server/api/chatQueueReport/index.js @@ -1 +1 @@ -const a105_0x7e36=['get','isAuthenticated','create','describe','post','./chatQueueReport.controller','../../components/auth/service','Router','exports','/:id','express','show','index','update'];(function(_0x5326d3,_0x7e365e){const _0x46eb59=function(_0x12c01b){while(--_0x12c01b){_0x5326d3['push'](_0x5326d3['shift']());}};_0x46eb59(++_0x7e365e);}(a105_0x7e36,0xdf));const a105_0x46eb=function(_0x5326d3,_0x7e365e){_0x5326d3=_0x5326d3-0x0;let _0x46eb59=a105_0x7e36[_0x5326d3];return _0x46eb59;};const _0x5128c2=a105_0x46eb;'use strict';const express=require(_0x5128c2('0xb')),router=express[_0x5128c2('0x8')](),auth=require(_0x5128c2('0x7')),controller=require(_0x5128c2('0x6'));router[_0x5128c2('0x1')]('/',auth[_0x5128c2('0x2')](),controller[_0x5128c2('0xd')]),router['get']('/describe',auth[_0x5128c2('0x2')](),controller[_0x5128c2('0x4')]),router[_0x5128c2('0x1')](_0x5128c2('0xa'),auth[_0x5128c2('0x2')](),controller[_0x5128c2('0xc')]),router[_0x5128c2('0x5')]('/',auth[_0x5128c2('0x2')](),controller[_0x5128c2('0x3')]),router['put'](_0x5128c2('0xa'),auth[_0x5128c2('0x2')](),controller[_0x5128c2('0x0')]),router['delete'](_0x5128c2('0xa'),auth['isAuthenticated'](),controller['destroy']),module[_0x5128c2('0x9')]=router; \ No newline at end of file +const a105_0x47a4=['update','isAuthenticated','get','/:id','express','Router','/describe','create','delete','index','exports','put','./chatQueueReport.controller'];(function(_0x30a36b,_0x47a448){const _0x492167=function(_0x14d913){while(--_0x14d913){_0x30a36b['push'](_0x30a36b['shift']());}};_0x492167(++_0x47a448);}(a105_0x47a4,0x8a));const a105_0x4921=function(_0x30a36b,_0x47a448){_0x30a36b=_0x30a36b-0x0;let _0x492167=a105_0x47a4[_0x30a36b];return _0x492167;};const _0x13b156=a105_0x4921;'use strict';const express=require(_0x13b156('0x9')),router=express[_0x13b156('0xa')](),auth=require('../../components/auth/service'),controller=require(_0x13b156('0x4'));router['get']('/',auth[_0x13b156('0x6')](),controller[_0x13b156('0x1')]),router[_0x13b156('0x7')](_0x13b156('0xb'),auth['isAuthenticated'](),controller['describe']),router[_0x13b156('0x7')]('/:id',auth[_0x13b156('0x6')](),controller['show']),router['post']('/',auth[_0x13b156('0x6')](),controller[_0x13b156('0xc')]),router[_0x13b156('0x3')](_0x13b156('0x8'),auth['isAuthenticated'](),controller[_0x13b156('0x5')]),router[_0x13b156('0x0')](_0x13b156('0x8'),auth['isAuthenticated'](),controller['destroy']),module[_0x13b156('0x2')]=router; \ No newline at end of file diff --git a/server/api/chatTransferReport/chatTransferReport.attributes.js b/server/api/chatTransferReport/chatTransferReport.attributes.js index 8919833..ec28261 100644 --- a/server/api/chatTransferReport/chatTransferReport.attributes.js +++ b/server/api/chatTransferReport/chatTransferReport.attributes.js @@ -1 +1 @@ -const a106_0x1364=['DATE','sequelize','agent','STRING','queue','NOW'];(function(_0x197167,_0x1364d1){const _0x4f2ae6=function(_0x1ca3d5){while(--_0x1ca3d5){_0x197167['push'](_0x197167['shift']());}};_0x4f2ae6(++_0x1364d1);}(a106_0x1364,0x13e));const a106_0x4f2a=function(_0x197167,_0x1364d1){_0x197167=_0x197167-0x0;let _0x4f2ae6=a106_0x1364[_0x197167];return _0x4f2ae6;};const _0x543371=a106_0x4f2a;'use strict';const Sequelize=require(_0x543371('0x1'));module['exports']={'uniqueid':{'type':Sequelize[_0x543371('0x3')],'allowNull':![]},'type':{'type':Sequelize['ENUM']('account',_0x543371('0x2'),'queue'),'allowNull':![],'defaultValue':_0x543371('0x4')},'transferredAt':{'type':Sequelize[_0x543371('0x0')],'allowNull':![],'defaultValue':Sequelize[_0x543371('0x5')]}}; \ No newline at end of file +const a106_0x2dc2=['exports','queue','ENUM','agent','NOW','STRING'];(function(_0xda1b6e,_0x2dc2cc){const _0x4aa35c=function(_0x533afd){while(--_0x533afd){_0xda1b6e['push'](_0xda1b6e['shift']());}};_0x4aa35c(++_0x2dc2cc);}(a106_0x2dc2,0x1b1));const a106_0x4aa3=function(_0xda1b6e,_0x2dc2cc){_0xda1b6e=_0xda1b6e-0x0;let _0x4aa35c=a106_0x2dc2[_0xda1b6e];return _0x4aa35c;};const _0x59b03b=a106_0x4aa3;'use strict';const Sequelize=require('sequelize');module[_0x59b03b('0x5')]={'uniqueid':{'type':Sequelize[_0x59b03b('0x4')],'allowNull':![]},'type':{'type':Sequelize[_0x59b03b('0x1')]('account',_0x59b03b('0x2'),_0x59b03b('0x0')),'allowNull':![],'defaultValue':_0x59b03b('0x0')},'transferredAt':{'type':Sequelize['DATE'],'allowNull':![],'defaultValue':Sequelize[_0x59b03b('0x3')]}}; \ No newline at end of file diff --git a/server/api/chatTransferReport/chatTransferReport.controller.js b/server/api/chatTransferReport/chatTransferReport.controller.js index 5f21103..b9653de 100644 --- a/server/api/chatTransferReport/chatTransferReport.controller.js +++ b/server/api/chatTransferReport/chatTransferReport.controller.js @@ -1 +1 @@ -const a107_0x4822=['sendStatus','include','merge','model','limit','map','like','attributes','status','findAll','includeAll','filters','rawAttributes','body','name','intersection','findOne','stack','sort','undefined','end','set','update','fields','length','keys','show','offset','params','fieldName','describe','options','key','json','send','error','sequelize','create','destroy','type','filter','then','ChatTransferReport','catch','where','rows','query','count','order','api'];(function(_0x508b3f,_0x482252){const _0x49cdc1=function(_0x270e97){while(--_0x270e97){_0x508b3f['push'](_0x508b3f['shift']());}};_0x49cdc1(++_0x482252);}(a107_0x4822,0x17f));const a107_0x49cd=function(_0x508b3f,_0x482252){_0x508b3f=_0x508b3f-0x0;let _0x49cdc1=a107_0x4822[_0x508b3f];return _0x49cdc1;};const _0x47b4db=a107_0x49cd;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x47b4db('0x10')),db=require('../../mysqldb')['db'],{Op}=require(_0x47b4db('0x3'));function respondWithResult(_0x270e97,_0x3e29f3){return _0x3e29f3=_0x3e29f3||0xc8,function(_0x2e83d0){const _0x1c5ba5=a107_0x49cd;if(_0x2e83d0)return _0x270e97[_0x1c5ba5('0x19')](_0x3e29f3)[_0x1c5ba5('0x0')](_0x2e83d0);};}function respondWithFilteredResult(_0x3846e9,_0x2faafe){return function(_0x37eac9){const _0x21d277=a107_0x49cd;if(_0x37eac9){const _0x102397=_0x37eac9[_0x21d277('0xe')],_0x3063a4=_0x2faafe[_0x21d277('0x2c')];let _0x1dfad9=_0x2faafe['offset']+_0x2faafe['limit'],_0x4c4b3c;return _0x1dfad9>=_0x102397?(_0x1dfad9=_0x102397,_0x4c4b3c=0xc8):_0x4c4b3c=0xce,_0x3846e9['status'](_0x4c4b3c),_0x3846e9[_0x21d277('0x26')]('Content-Range',_0x3063a4+'-'+_0x1dfad9+'/'+_0x102397)[_0x21d277('0x0')](_0x37eac9);}return null;};}function saveUpdates(_0xd5e040){return function(_0x332b85){const _0x551344=a107_0x49cd;if(_0x332b85)return _0x332b85[_0x551344('0x27')](_0xd5e040)[_0x551344('0x8')](function(_0x3d3803){return _0x3d3803;});return null;};}function removeEntity(_0x197ae6){return function(_0x30be94){const _0x3ba7e0=a107_0x49cd;if(_0x30be94)return _0x30be94[_0x3ba7e0('0x5')]()['then'](function(){const _0x592e4d=_0x3ba7e0;_0x197ae6['status'](0xcc)[_0x592e4d('0x25')]();});};}function handleEntityNotFound(_0x4a07db){return function(_0x3dfd56){const _0x26ee73=a107_0x49cd;return!_0x3dfd56&&_0x4a07db[_0x26ee73('0x11')](0x194),_0x3dfd56;};}function handleError(_0x51c5a3,_0x307fb0){return _0x307fb0=_0x307fb0||0x1f4,function(_0x5dd797){const _0x2eddda=a107_0x49cd;logger[_0x2eddda('0x2')](_0x5dd797[_0x2eddda('0x22')]),_0x5dd797[_0x2eddda('0x1f')]&&delete _0x5dd797[_0x2eddda('0x1f')],_0x51c5a3[_0x2eddda('0x19')](_0x307fb0)[_0x2eddda('0x1')](_0x5dd797);};}exports['index']=function(_0x5dd75e,_0x1d2241){const _0x2301cb=_0x47b4db;let _0x1d8395={};const _0x4e2d7c={},_0xc3eccf={'count':0x0,'rows':[]},_0x182b44=_[_0x2301cb('0x16')](db[_0x2301cb('0x9')][_0x2301cb('0x1d')],function(_0x4507a8){const _0x26ef4a=_0x2301cb;return{'name':_0x4507a8[_0x26ef4a('0x2e')],'type':_0x4507a8[_0x26ef4a('0x6')][_0x26ef4a('0x31')]};});_0x4e2d7c[_0x2301cb('0x14')]=_[_0x2301cb('0x16')](_0x182b44,'name'),_0x4e2d7c[_0x2301cb('0xd')]=_[_0x2301cb('0x2a')](_0x5dd75e[_0x2301cb('0xd')]),_0x4e2d7c['filters']=_[_0x2301cb('0x20')](_0x4e2d7c[_0x2301cb('0x14')],_0x4e2d7c[_0x2301cb('0xd')]),_0x1d8395[_0x2301cb('0x18')]=_['intersection'](_0x4e2d7c[_0x2301cb('0x14')],qs[_0x2301cb('0x28')](_0x5dd75e['query'][_0x2301cb('0x28')])),_0x1d8395[_0x2301cb('0x18')]=_0x1d8395[_0x2301cb('0x18')][_0x2301cb('0x29')]?_0x1d8395[_0x2301cb('0x18')]:_0x4e2d7c[_0x2301cb('0x14')];typeof _0x5dd75e[_0x2301cb('0xd')]['nolimit']===_0x2301cb('0x24')&&(_0x1d8395[_0x2301cb('0x15')]=qs[_0x2301cb('0x15')](_0x5dd75e[_0x2301cb('0xd')]['limit']),_0x1d8395[_0x2301cb('0x2c')]=qs[_0x2301cb('0x2c')](_0x5dd75e[_0x2301cb('0xd')]['offset']));_0x1d8395[_0x2301cb('0xf')]=qs[_0x2301cb('0x23')](_0x5dd75e['query'][_0x2301cb('0x23')]),_0x1d8395[_0x2301cb('0xb')]=qs[_0x2301cb('0x1c')](_['pick'](_0x5dd75e[_0x2301cb('0xd')],_0x4e2d7c[_0x2301cb('0x1c')]),_0x182b44);_0x5dd75e[_0x2301cb('0xd')][_0x2301cb('0x7')]&&(_0x1d8395[_0x2301cb('0xb')]=_['merge'](_0x1d8395['where'],{[Op['or']]:_[_0x2301cb('0x16')](_0x182b44,function(_0x59a5e4){const _0x1a8b1a=_0x2301cb;if(_0x59a5e4['type']!=='VIRTUAL'){const _0x1640f6={};return _0x1640f6[_0x59a5e4['name']]={[Op[_0x1a8b1a('0x17')]]:'%'+_0x5dd75e[_0x1a8b1a('0xd')][_0x1a8b1a('0x7')]+'%'},_0x1640f6;}})}));_0x1d8395=_[_0x2301cb('0x13')]({},_0x1d8395,_0x5dd75e[_0x2301cb('0x30')]);const _0x908b3a={'where':_0x1d8395[_0x2301cb('0xb')]};return db[_0x2301cb('0x9')]['count'](_0x908b3a)[_0x2301cb('0x8')](function(_0x54ead9){const _0xeb68be=_0x2301cb;return _0xc3eccf['count']=_0x54ead9,_0x5dd75e[_0xeb68be('0xd')][_0xeb68be('0x1b')]&&(_0x1d8395[_0xeb68be('0x12')]=[{'all':!![]}]),db[_0xeb68be('0x9')][_0xeb68be('0x1a')](_0x1d8395);})[_0x2301cb('0x8')](function(_0x275b4f){const _0xf54e7f=_0x2301cb;return _0xc3eccf[_0xf54e7f('0xc')]=_0x275b4f,_0xc3eccf;})[_0x2301cb('0x8')](respondWithFilteredResult(_0x1d2241,_0x1d8395))[_0x2301cb('0xa')](handleError(_0x1d2241,null));},exports[_0x47b4db('0x2b')]=function(_0x4a6731,_0x4120a1){const _0x30d4ee=_0x47b4db;let _0x5846cf={'raw':!![],'where':{'id':_0x4a6731[_0x30d4ee('0x2d')]['id']}};const _0xa85253={};return _0xa85253[_0x30d4ee('0x14')]=_[_0x30d4ee('0x2a')](db[_0x30d4ee('0x9')]['rawAttributes']),_0xa85253[_0x30d4ee('0xd')]=_['keys'](_0x4a6731['query']),_0xa85253['filters']=_[_0x30d4ee('0x20')](_0xa85253[_0x30d4ee('0x14')],_0xa85253['query']),_0x5846cf[_0x30d4ee('0x18')]=_[_0x30d4ee('0x20')](_0xa85253[_0x30d4ee('0x14')],qs['fields'](_0x4a6731['query'][_0x30d4ee('0x28')])),_0x5846cf[_0x30d4ee('0x18')]=_0x5846cf[_0x30d4ee('0x18')][_0x30d4ee('0x29')]?_0x5846cf[_0x30d4ee('0x18')]:_0xa85253[_0x30d4ee('0x14')],_0x4a6731[_0x30d4ee('0xd')]['includeAll']&&(_0x5846cf[_0x30d4ee('0x12')]=[{'all':!![]}]),_0x5846cf=_[_0x30d4ee('0x13')]({},_0x5846cf,_0x4a6731[_0x30d4ee('0x30')]),db[_0x30d4ee('0x9')][_0x30d4ee('0x21')](_0x5846cf)[_0x30d4ee('0x8')](handleEntityNotFound(_0x4120a1,null))[_0x30d4ee('0x8')](respondWithResult(_0x4120a1,null))['catch'](handleError(_0x4120a1,null));},exports['create']=function(_0x144a6e,_0x55ef6a){const _0x4b8cc7=_0x47b4db;return db['ChatTransferReport'][_0x4b8cc7('0x4')](_0x144a6e[_0x4b8cc7('0x1e')],{})[_0x4b8cc7('0x8')](respondWithResult(_0x55ef6a,0xc9))[_0x4b8cc7('0xa')](handleError(_0x55ef6a,null));},exports[_0x47b4db('0x27')]=function(_0x41be06,_0x18fe73){const _0x16254c=_0x47b4db;return _0x41be06[_0x16254c('0x1e')]['id']&&delete _0x41be06[_0x16254c('0x1e')]['id'],db[_0x16254c('0x9')][_0x16254c('0x21')]({'where':{'id':_0x41be06[_0x16254c('0x2d')]['id']}})[_0x16254c('0x8')](handleEntityNotFound(_0x18fe73,null))['then'](saveUpdates(_0x41be06[_0x16254c('0x1e')],null))[_0x16254c('0x8')](respondWithResult(_0x18fe73,null))['catch'](handleError(_0x18fe73,null));},exports[_0x47b4db('0x5')]=function(_0x5bc492,_0x3f22ac){const _0xed169a=_0x47b4db;return db['ChatTransferReport'][_0xed169a('0x21')]({'where':{'id':_0x5bc492[_0xed169a('0x2d')]['id']}})['then'](handleEntityNotFound(_0x3f22ac,null))['then'](removeEntity(_0x3f22ac,null))['catch'](handleError(_0x3f22ac,null));},exports[_0x47b4db('0x2f')]=function(_0x274d74,_0x456d2e){const _0x415987=_0x47b4db;return db[_0x415987('0x9')]['describe']()[_0x415987('0x8')](respondWithResult(_0x456d2e,null))[_0x415987('0xa')](handleError(_0x456d2e,null));}; \ No newline at end of file +const a107_0x1b2e=['status','fields','order','../../config/logger','catch','count','describe','nolimit','merge','map','api','then','create','filter','send','where','keys','key','body','like','options','index','ChatTransferReport','include','undefined','../../mysqldb','stack','type','length','sequelize','name','destroy','intersection','set','sort','model','query','offset','rows','filters','findOne','show','includeAll','limit','error','pick','sendStatus','json','update','attributes','end','rawAttributes'];(function(_0x596a49,_0x1b2e66){const _0x53f16c=function(_0x1347b0){while(--_0x1347b0){_0x596a49['push'](_0x596a49['shift']());}};_0x53f16c(++_0x1b2e66);}(a107_0x1b2e,0x1ca));const a107_0x53f1=function(_0x596a49,_0x1b2e66){_0x596a49=_0x596a49-0x0;let _0x53f16c=a107_0x1b2e[_0x596a49];return _0x53f16c;};const _0x4a507c=a107_0x53f1;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x4a507c('0xd'))(_0x4a507c('0x14')),db=require(_0x4a507c('0x23'))['db'],{Op}=require(_0x4a507c('0x27'));function respondWithResult(_0x1347b0,_0x474973){return _0x474973=_0x474973||0xc8,function(_0x5a5288){const _0x4b1b61=a107_0x53f1;if(_0x5a5288)return _0x1347b0[_0x4b1b61('0xa')](_0x474973)[_0x4b1b61('0x5')](_0x5a5288);};}function respondWithFilteredResult(_0x23fc4c,_0x168f76){return function(_0x17eb6d){const _0xe61307=a107_0x53f1;if(_0x17eb6d){const _0x5b8438=_0x17eb6d[_0xe61307('0xf')],_0x4a46bd=_0x168f76[_0xe61307('0x2f')];let _0x306956=_0x168f76[_0xe61307('0x2f')]+_0x168f76['limit'],_0x12a832;return _0x306956>=_0x5b8438?(_0x306956=_0x5b8438,_0x12a832=0xc8):_0x12a832=0xce,_0x23fc4c['status'](_0x12a832),_0x23fc4c[_0xe61307('0x2b')]('Content-Range',_0x4a46bd+'-'+_0x306956+'/'+_0x5b8438)['json'](_0x17eb6d);}return null;};}function saveUpdates(_0x233fd5){return function(_0x378d30){const _0x28f062=a107_0x53f1;if(_0x378d30)return _0x378d30[_0x28f062('0x6')](_0x233fd5)[_0x28f062('0x15')](function(_0x542c3b){return _0x542c3b;});return null;};}function removeEntity(_0x3803d1){return function(_0x447cf1){const _0x449a4b=a107_0x53f1;if(_0x447cf1)return _0x447cf1[_0x449a4b('0x29')]()[_0x449a4b('0x15')](function(){const _0xdbeae8=_0x449a4b;_0x3803d1[_0xdbeae8('0xa')](0xcc)[_0xdbeae8('0x8')]();});};}function handleEntityNotFound(_0x19fe26){return function(_0x5d7201){const _0x375cb3=a107_0x53f1;return!_0x5d7201&&_0x19fe26[_0x375cb3('0x4')](0x194),_0x5d7201;};}function handleError(_0x3f08c0,_0x1e9840){return _0x1e9840=_0x1e9840||0x1f4,function(_0x105f02){const _0x193801=a107_0x53f1;logger[_0x193801('0x2')](_0x105f02[_0x193801('0x24')]),_0x105f02['name']&&delete _0x105f02[_0x193801('0x28')],_0x3f08c0[_0x193801('0xa')](_0x1e9840)[_0x193801('0x18')](_0x105f02);};}exports[_0x4a507c('0x1f')]=function(_0xd51f00,_0x4de66a){const _0x5e6bd7=_0x4a507c;let _0x55b0bb={};const _0x1c8c08={},_0x1b6e26={'count':0x0,'rows':[]},_0x4623b2=_[_0x5e6bd7('0x13')](db['ChatTransferReport'][_0x5e6bd7('0x9')],function(_0x47e17d){const _0x59117c=_0x5e6bd7;return{'name':_0x47e17d['fieldName'],'type':_0x47e17d[_0x59117c('0x25')][_0x59117c('0x1b')]};});_0x1c8c08[_0x5e6bd7('0x2d')]=_[_0x5e6bd7('0x13')](_0x4623b2,_0x5e6bd7('0x28')),_0x1c8c08['query']=_['keys'](_0xd51f00['query']),_0x1c8c08[_0x5e6bd7('0x31')]=_['intersection'](_0x1c8c08['model'],_0x1c8c08[_0x5e6bd7('0x2e')]),_0x55b0bb[_0x5e6bd7('0x7')]=_[_0x5e6bd7('0x2a')](_0x1c8c08[_0x5e6bd7('0x2d')],qs[_0x5e6bd7('0xb')](_0xd51f00[_0x5e6bd7('0x2e')][_0x5e6bd7('0xb')])),_0x55b0bb[_0x5e6bd7('0x7')]=_0x55b0bb[_0x5e6bd7('0x7')]['length']?_0x55b0bb[_0x5e6bd7('0x7')]:_0x1c8c08[_0x5e6bd7('0x2d')];typeof _0xd51f00[_0x5e6bd7('0x2e')][_0x5e6bd7('0x11')]===_0x5e6bd7('0x22')&&(_0x55b0bb['limit']=qs['limit'](_0xd51f00[_0x5e6bd7('0x2e')][_0x5e6bd7('0x1')]),_0x55b0bb['offset']=qs[_0x5e6bd7('0x2f')](_0xd51f00['query'][_0x5e6bd7('0x2f')]));_0x55b0bb[_0x5e6bd7('0xc')]=qs[_0x5e6bd7('0x2c')](_0xd51f00['query'][_0x5e6bd7('0x2c')]),_0x55b0bb[_0x5e6bd7('0x19')]=qs[_0x5e6bd7('0x31')](_[_0x5e6bd7('0x3')](_0xd51f00[_0x5e6bd7('0x2e')],_0x1c8c08['filters']),_0x4623b2);_0xd51f00[_0x5e6bd7('0x2e')]['filter']&&(_0x55b0bb['where']=_['merge'](_0x55b0bb[_0x5e6bd7('0x19')],{[Op['or']]:_[_0x5e6bd7('0x13')](_0x4623b2,function(_0x5925c5){const _0x5f9d3e=_0x5e6bd7;if(_0x5925c5['type']!=='VIRTUAL'){const _0x296022={};return _0x296022[_0x5925c5[_0x5f9d3e('0x28')]]={[Op[_0x5f9d3e('0x1d')]]:'%'+_0xd51f00['query'][_0x5f9d3e('0x17')]+'%'},_0x296022;}})}));_0x55b0bb=_[_0x5e6bd7('0x12')]({},_0x55b0bb,_0xd51f00[_0x5e6bd7('0x1e')]);const _0x543612={'where':_0x55b0bb[_0x5e6bd7('0x19')]};return db[_0x5e6bd7('0x20')][_0x5e6bd7('0xf')](_0x543612)[_0x5e6bd7('0x15')](function(_0x331825){const _0x40624c=_0x5e6bd7;return _0x1b6e26[_0x40624c('0xf')]=_0x331825,_0xd51f00['query'][_0x40624c('0x0')]&&(_0x55b0bb['include']=[{'all':!![]}]),db[_0x40624c('0x20')]['findAll'](_0x55b0bb);})[_0x5e6bd7('0x15')](function(_0x299921){const _0x33fb14=_0x5e6bd7;return _0x1b6e26[_0x33fb14('0x30')]=_0x299921,_0x1b6e26;})[_0x5e6bd7('0x15')](respondWithFilteredResult(_0x4de66a,_0x55b0bb))['catch'](handleError(_0x4de66a,null));},exports[_0x4a507c('0x33')]=function(_0x1b174d,_0x4c3046){const _0x1773f1=_0x4a507c;let _0x2343df={'raw':!![],'where':{'id':_0x1b174d['params']['id']}};const _0x1f4768={};return _0x1f4768[_0x1773f1('0x2d')]=_[_0x1773f1('0x1a')](db[_0x1773f1('0x20')][_0x1773f1('0x9')]),_0x1f4768[_0x1773f1('0x2e')]=_[_0x1773f1('0x1a')](_0x1b174d[_0x1773f1('0x2e')]),_0x1f4768[_0x1773f1('0x31')]=_['intersection'](_0x1f4768[_0x1773f1('0x2d')],_0x1f4768[_0x1773f1('0x2e')]),_0x2343df[_0x1773f1('0x7')]=_['intersection'](_0x1f4768[_0x1773f1('0x2d')],qs[_0x1773f1('0xb')](_0x1b174d[_0x1773f1('0x2e')]['fields'])),_0x2343df[_0x1773f1('0x7')]=_0x2343df[_0x1773f1('0x7')][_0x1773f1('0x26')]?_0x2343df['attributes']:_0x1f4768[_0x1773f1('0x2d')],_0x1b174d[_0x1773f1('0x2e')][_0x1773f1('0x0')]&&(_0x2343df[_0x1773f1('0x21')]=[{'all':!![]}]),_0x2343df=_[_0x1773f1('0x12')]({},_0x2343df,_0x1b174d[_0x1773f1('0x1e')]),db['ChatTransferReport'][_0x1773f1('0x32')](_0x2343df)[_0x1773f1('0x15')](handleEntityNotFound(_0x4c3046,null))['then'](respondWithResult(_0x4c3046,null))['catch'](handleError(_0x4c3046,null));},exports[_0x4a507c('0x16')]=function(_0x2ae6ea,_0xbc6d91){const _0x5eeba7=_0x4a507c;return db[_0x5eeba7('0x20')][_0x5eeba7('0x16')](_0x2ae6ea[_0x5eeba7('0x1c')],{})[_0x5eeba7('0x15')](respondWithResult(_0xbc6d91,0xc9))[_0x5eeba7('0xe')](handleError(_0xbc6d91,null));},exports[_0x4a507c('0x6')]=function(_0x2a0460,_0x5ce6a9){const _0x2923d6=_0x4a507c;return _0x2a0460[_0x2923d6('0x1c')]['id']&&delete _0x2a0460[_0x2923d6('0x1c')]['id'],db['ChatTransferReport'][_0x2923d6('0x32')]({'where':{'id':_0x2a0460['params']['id']}})['then'](handleEntityNotFound(_0x5ce6a9,null))[_0x2923d6('0x15')](saveUpdates(_0x2a0460['body'],null))[_0x2923d6('0x15')](respondWithResult(_0x5ce6a9,null))[_0x2923d6('0xe')](handleError(_0x5ce6a9,null));},exports[_0x4a507c('0x29')]=function(_0x16076a,_0xcf9561){const _0x5a1785=_0x4a507c;return db['ChatTransferReport'][_0x5a1785('0x32')]({'where':{'id':_0x16076a['params']['id']}})[_0x5a1785('0x15')](handleEntityNotFound(_0xcf9561,null))[_0x5a1785('0x15')](removeEntity(_0xcf9561,null))['catch'](handleError(_0xcf9561,null));},exports['describe']=function(_0x3fd331,_0x454271){const _0x260ee1=_0x4a507c;return db[_0x260ee1('0x20')][_0x260ee1('0x10')]()['then'](respondWithResult(_0x454271,null))[_0x260ee1('0xe')](handleError(_0x454271,null));}; \ No newline at end of file diff --git a/server/api/chatTransferReport/chatTransferReport.model.js b/server/api/chatTransferReport/chatTransferReport.model.js index b9c2bba..9fa241a 100644 --- a/server/api/chatTransferReport/chatTransferReport.model.js +++ b/server/api/chatTransferReport/chatTransferReport.model.js @@ -1 +1 @@ -const a108_0x26d7=['./chatTransferReport.attributes','define','report_chat_transfer','ChatTransferReport','exports','uniqueid'];(function(_0x249f74,_0x26d721){const _0x3c1e3a=function(_0x586a2d){while(--_0x586a2d){_0x249f74['push'](_0x249f74['shift']());}};_0x3c1e3a(++_0x26d721);}(a108_0x26d7,0x15b));const a108_0x3c1e=function(_0x249f74,_0x26d721){_0x249f74=_0x249f74-0x0;let _0x3c1e3a=a108_0x26d7[_0x249f74];return _0x3c1e3a;};const _0x3e8765=a108_0x3c1e;'use strict';const attributes=require(_0x3e8765('0x1'));module[_0x3e8765('0x5')]=function(_0x586a2d){const _0x517333=_0x3e8765,_0x450278=_0x586a2d[_0x517333('0x2')](_0x517333('0x4'),attributes,{'tableName':_0x517333('0x3'),'paranoid':![],'indexes':[{'name':_0x517333('0x0'),'fields':[_0x517333('0x0')]}],'timestamps':!![]});return _0x450278;}; \ No newline at end of file +const a108_0x765f=['define','./chatTransferReport.attributes','ChatTransferReport','uniqueid','report_chat_transfer','exports'];(function(_0x5ddb92,_0x765fde){const _0xcaceef=function(_0x3ddaa7){while(--_0x3ddaa7){_0x5ddb92['push'](_0x5ddb92['shift']());}};_0xcaceef(++_0x765fde);}(a108_0x765f,0x116));const a108_0xcace=function(_0x5ddb92,_0x765fde){_0x5ddb92=_0x5ddb92-0x0;let _0xcaceef=a108_0x765f[_0x5ddb92];return _0xcaceef;};const _0x397e8c=a108_0xcace;'use strict';const attributes=require(_0x397e8c('0x5'));module[_0x397e8c('0x3')]=function(_0x3ddaa7){const _0x59c258=_0x397e8c,_0x4d0c08=_0x3ddaa7[_0x59c258('0x4')](_0x59c258('0x0'),attributes,{'tableName':_0x59c258('0x2'),'paranoid':![],'indexes':[{'name':_0x59c258('0x1'),'fields':[_0x59c258('0x1')]}],'timestamps':!![]});return _0x4d0c08;}; \ No newline at end of file diff --git a/server/api/chatTransferReport/index.js b/server/api/chatTransferReport/index.js index 194c28a..d628360 100644 --- a/server/api/chatTransferReport/index.js +++ b/server/api/chatTransferReport/index.js @@ -1 +1 @@ -const a109_0x2be6=['show','Router','post','../../components/auth/service','/:id','get','update','isAuthenticated','destroy','index','delete','describe'];(function(_0x4c6ea2,_0x2be6b8){const _0x465487=function(_0x484bb4){while(--_0x484bb4){_0x4c6ea2['push'](_0x4c6ea2['shift']());}};_0x465487(++_0x2be6b8);}(a109_0x2be6,0x1c9));const a109_0x4654=function(_0x4c6ea2,_0x2be6b8){_0x4c6ea2=_0x4c6ea2-0x0;let _0x465487=a109_0x2be6[_0x4c6ea2];return _0x465487;};const _0x2c399f=a109_0x4654;'use strict';const express=require('express'),router=express[_0x2c399f('0x0')](),auth=require(_0x2c399f('0x2')),controller=require('./chatTransferReport.controller');router['get']('/',auth['isAuthenticated'](),controller[_0x2c399f('0x8')]),router[_0x2c399f('0x4')]('/describe',auth[_0x2c399f('0x6')](),controller[_0x2c399f('0xa')]),router[_0x2c399f('0x4')](_0x2c399f('0x3'),auth[_0x2c399f('0x6')](),controller[_0x2c399f('0xb')]),router[_0x2c399f('0x1')]('/',auth['isAuthenticated'](),controller['create']),router['put'](_0x2c399f('0x3'),auth[_0x2c399f('0x6')](),controller[_0x2c399f('0x5')]),router[_0x2c399f('0x9')]('/:id',auth['isAuthenticated'](),controller[_0x2c399f('0x7')]),module['exports']=router; \ No newline at end of file +const a109_0x26cc=['destroy','describe','show','delete','exports','isAuthenticated','create','./chatTransferReport.controller','get','express','/describe','index','/:id','post'];(function(_0x52c3cb,_0x26ccad){const _0x489311=function(_0x133f55){while(--_0x133f55){_0x52c3cb['push'](_0x52c3cb['shift']());}};_0x489311(++_0x26ccad);}(a109_0x26cc,0x1a0));const a109_0x4893=function(_0x52c3cb,_0x26ccad){_0x52c3cb=_0x52c3cb-0x0;let _0x489311=a109_0x26cc[_0x52c3cb];return _0x489311;};const _0x288288=a109_0x4893;'use strict';const express=require(_0x288288('0xd')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x288288('0xb'));router['get']('/',auth[_0x288288('0x9')](),controller[_0x288288('0x1')]),router['get'](_0x288288('0x0'),auth[_0x288288('0x9')](),controller[_0x288288('0x5')]),router[_0x288288('0xc')](_0x288288('0x2'),auth[_0x288288('0x9')](),controller[_0x288288('0x6')]),router[_0x288288('0x3')]('/',auth['isAuthenticated'](),controller[_0x288288('0xa')]),router['put'](_0x288288('0x2'),auth[_0x288288('0x9')](),controller['update']),router[_0x288288('0x7')](_0x288288('0x2'),auth[_0x288288('0x9')](),controller[_0x288288('0x4')]),module[_0x288288('0x8')]=router; \ No newline at end of file diff --git a/server/api/chatWebsite/chatWebsite.attributes.js b/server/api/chatWebsite/chatWebsite.attributes.js index 0f795ee..0ecaafb 100644 --- a/server/api/chatWebsite/chatWebsite.attributes.js +++ b/server/api/chatWebsite/chatWebsite.attributes.js @@ -1 +1 @@ -const a110_0x2137=['Feedback','Leave\x20your\x20comments','Contact\x20us','onlineForm','star','Comments','Type\x20a\x20message','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','website_alias','rounded','Skip','We\x20are\x20here!','#011F6A','name','STRING','Powered\x20by\x20xCALLY','mandatoryDisposition','Form\x20submission\x20error','squared','textarea','mandatoryDispositionPauseId','email','getDataValue','Chat','stringify','alternate','exports','offlineForm','setDataValue','Please\x20hold\x20and\x20we\x20will\x20answer\x20your\x20request\x20as\x20soon\x20as\x20possible.','ENUM','#ffffff','All\x20of\x20our\x20agents\x20are\x20busy\x20at\x20this\x20time.\x20Your\x20chat\x20is\x20very\x20important\x20to\x20us.','bottom_right','Agent','TEXT','Your\x20request\x20has\x20not\x20been\x20processed.','thumb','Send','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','text','BOOLEAN','New\x20offline\x20message\x20from\x20websiteName','INTEGER','parse','Form\x20properly\x20submitted','input','You\x20received\x20a\x20new\x20offline\x20message\x20from\x20websiteName.\x20Here\x20you\x20can\x20find\x20the\x20details\x20of\x20the\x20request:'];(function(_0x163f77,_0x213755){const _0x43ec19=function(_0x4eb9b8){while(--_0x4eb9b8){_0x163f77['push'](_0x163f77['shift']());}};_0x43ec19(++_0x213755);}(a110_0x2137,0x162));const a110_0x43ec=function(_0x163f77,_0x213755){_0x163f77=_0x163f77-0x0;let _0x43ec19=a110_0x2137[_0x163f77];return _0x43ec19;};const _0x44326d=a110_0x43ec;'use strict';const Sequelize=require('sequelize'),rs=require('randomstring');module[_0x44326d('0x8')]={'name':{'type':Sequelize[_0x44326d('0x2c')],'allowNull':![]},'address':{'type':Sequelize[_0x44326d('0x2c')],'allowNull':![],'unique':'address'},'description':{'type':Sequelize[_0x44326d('0x2c')]},'mapKey':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x3')},'mapKeyOffline':{'type':Sequelize['STRING'],'defaultValue':'email'},'key':{'type':Sequelize[_0x44326d('0x2c')],'allowNull':![]},'agentAlias':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x10')},'customerAlias':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':'Me'},'color':{'type':Sequelize[_0x44326d('0x2c')],'allowNull':![],'defaultValue':_0x44326d('0x2a'),'validate':{'notEmpty':!![]}},'color_button':{'type':Sequelize[_0x44326d('0x2c')],'allowNull':![],'defaultValue':_0x44326d('0x2a'),'validate':{'notEmpty':!![]}},'textColor':{'type':Sequelize[_0x44326d('0x2c')],'allowNull':![],'defaultValue':_0x44326d('0xd'),'validate':{'notEmpty':!![]}},'fontSize':{'type':Sequelize['INTEGER'],'defaultValue':0xf},'remote':{'type':Sequelize[_0x44326d('0x2c')]},'animation':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':!![]},'header_shape':{'type':Sequelize[_0x44326d('0xc')](_0x44326d('0x27'),_0x44326d('0x0')),'defaultValue':'rounded'},'header_online':{'type':Sequelize['STRING'],'defaultValue':_0x44326d('0x29')},'start_chat_button':{'type':Sequelize['STRING'],'defaultValue':_0x44326d('0x5')},'offline_chat_button':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x14')},'header_offline':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x20')},'download_transcript':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'timeout':{'type':Sequelize[_0x44326d('0x19')],'defaultValue':0x0},'whiteLabel':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x2d')},'defaultWhiteLabel':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'sitepic':{'type':Sequelize[_0x44326d('0x11')]},'closingQuestion':{'type':Sequelize['STRING'],'defaultValue':'Do\x20you\x20want\x20to\x20close\x20the\x20interaction?'},'formSubmitSuccessMessage':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x1b')},'formSubmitFailureMessage':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x2f')},'noteTitle':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':'Note'},'placeholderMessage':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x24')},'closingMessage':{'type':Sequelize['STRING'],'defaultValue':'Thanks\x20you\x20for\x20your\x20time!'},'closingMessageButton':{'type':Sequelize['STRING'],'defaultValue':'Send'},'skipMessageButton':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x28')},'conditionAgreement':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'enableRating':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'enableFeedback':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'enableSendButton':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'feedbackTitle':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x1e')},'ratingType':{'type':Sequelize[_0x44326d('0xc')](_0x44326d('0x22'),_0x44326d('0x13')),'defaultValue':_0x44326d('0x22')},'ratingStarsNumber':{'type':Sequelize[_0x44326d('0x19')],'defaultValue':0x5},'onlineForm':{'type':Sequelize['TEXT'],'defaultValue':function(){const _0xad07a=_0x44326d;return JSON[_0xad07a('0x6')]({'items':[{'type':'input','variable':null,'config':{'placeholder':_0xad07a('0x2b'),'type':_0xad07a('0x16'),'required':!![]},'props':{'title':'name','helpText':''}},{'type':_0xad07a('0x1c'),'props':{'title':_0xad07a('0x3'),'helpText':''},'config':{'required':!![],'placeholder':_0xad07a('0x3'),'type':_0xad07a('0x3')},'variable':null}],'fromKey':0x1});},'get':function(){const _0xabc872=_0x44326d;return this[_0xabc872('0x4')](_0xabc872('0x21'))?JSON[_0xabc872('0x1a')](this[_0xabc872('0x4')](_0xabc872('0x21'))):{};},'set':function(_0x4eb9b8){const _0xf18be7=_0x44326d;return this['setDataValue']('onlineForm',JSON[_0xf18be7('0x6')](_0x4eb9b8));}},'offlineForm':{'type':Sequelize[_0x44326d('0x11')],'defaultValue':function(){const _0x3da97d=_0x44326d;return JSON['stringify']({'items':[{'type':_0x3da97d('0x1c'),'props':{'title':_0x3da97d('0x3'),'helpText':''},'config':{'required':!![],'placeholder':_0x3da97d('0x3'),'type':_0x3da97d('0x3')},'variable':null},{'type':_0x3da97d('0x1'),'config':{'placeholder':_0x3da97d('0x23')},'props':{'title':'Comments','helpText':_0x3da97d('0x1f')}}],'fromKey':0x0});},'get':function(){const _0x2429cc=_0x44326d;return this[_0x2429cc('0x4')](_0x2429cc('0x9'))?JSON[_0x2429cc('0x1a')](this[_0x2429cc('0x4')]('offlineForm')):{};},'set':function(_0x3c28cd){const _0x369929=_0x44326d;return this[_0x369929('0xa')]('offlineForm',JSON[_0x369929('0x6')](_0x3c28cd));}},'token':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':function(){return rs['generate']();}},'autoclose':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':!![]},'enableCustomerWriting':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'forwardTranscript':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'forwardTranscriptMessage':{'type':Sequelize['STRING']},'forwardOffline':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'forwardOfflineAddress':{'type':Sequelize['STRING']},'waitingTitle':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0xe')},'waitingMessage':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0xb')},'offlineMessageSubject':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x18')},'offlineMessageBody':{'type':Sequelize['STRING'],'defaultValue':_0x44326d('0x1d')},'enableUnmanagedNote':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'unmanagedMessage':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x12')},'skipUnmanaged':{'type':Sequelize['STRING'],'defaultValue':_0x44326d('0x28')},'sendUnmanaged':{'type':Sequelize['STRING'],'defaultValue':_0x44326d('0x14')},'enableCustomerAttachment':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'enableCustomerCheckmarks':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'agentAvatar':{'type':Sequelize[_0x44326d('0x11')]},'showAgentAvatar':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'timezone':{'type':Sequelize[_0x44326d('0x2c')]},'notificationTemplate':{'type':Sequelize['TEXT'],'defaultValue':function(){return'Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}';}},'notificationSound':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':!![]},'notificationShake':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'hideWhenOffline':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'agentIdentifier':{'type':Sequelize['STRING'],'defaultValue':_0x44326d('0x26')},'waitForTheAssignedAgent':{'type':Sequelize[_0x44326d('0x19')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'alignment':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0xf')},'verticalAlignment':{'type':Sequelize[_0x44326d('0x19')],'defaultValue':0x1e},'messagesAlignment':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':_0x44326d('0x7')},'defaultTitle':{'type':Sequelize['STRING']},'customerAvatar':{'type':Sequelize[_0x44326d('0x11')]},'showCustomerAvatar':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'messageFontSize':{'type':Sequelize[_0x44326d('0x19')],'defaultValue':0xc},'backgroundColor':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':'#fafafa','validate':{'notEmpty':!![]}},'queueTransfer':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize['INTEGER'],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0x44326d('0x19')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'systemAlias':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':'System'},'systemAvatar':{'type':Sequelize['TEXT']},'mandatoryDispositionPauseId':{'type':Sequelize[_0x44326d('0x19')],'comment':_0x44326d('0x25')},'mandatoryDisposition':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![],'comment':_0x44326d('0x15'),'set':function(_0x518461){const _0x1b3d01=_0x44326d;if(!_0x518461)this[_0x1b3d01('0xa')](_0x1b3d01('0x2'),null);this['setDataValue'](_0x1b3d01('0x2e'),_0x518461);}},'vidaooEscalation':{'type':Sequelize[_0x44326d('0x17')],'defaultValue':![]},'vidaooApiKey':{'type':Sequelize[_0x44326d('0x2c')],'defaultValue':![]}}; \ No newline at end of file +const a110_0x2ec6=['System','Chat','#011F6A','input','Type\x20a\x20message','Note','rounded','offlineForm','Agent','Skip','ENUM','email','textarea','address','parse','Thanks\x20you\x20for\x20your\x20time!','Send','exports','INTEGER','squared','getDataValue','Contact\x20us','Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}','text','alternate','Please\x20hold\x20and\x20we\x20will\x20answer\x20your\x20request\x20as\x20soon\x20as\x20possible.','STRING','name','bottom_right','Form\x20submission\x20error','generate','sequelize','mandatoryDispositionPauseId','Do\x20you\x20want\x20to\x20close\x20the\x20interaction?','Form\x20properly\x20submitted','TEXT','onlineForm','Comments','Powered\x20by\x20xCALLY','BOOLEAN','You\x20received\x20a\x20new\x20offline\x20message\x20from\x20websiteName.\x20Here\x20you\x20can\x20find\x20the\x20details\x20of\x20the\x20request:','Feedback','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','star','mandatoryDisposition','setDataValue','#fafafa','stringify','Your\x20request\x20has\x20not\x20been\x20processed.'];(function(_0x559a44,_0x2ec6ac){const _0xc320c9=function(_0x38614e){while(--_0x38614e){_0x559a44['push'](_0x559a44['shift']());}};_0xc320c9(++_0x2ec6ac);}(a110_0x2ec6,0xe6));const a110_0xc320=function(_0x559a44,_0x2ec6ac){_0x559a44=_0x559a44-0x0;let _0xc320c9=a110_0x2ec6[_0x559a44];return _0xc320c9;};const _0x4b6d71=a110_0xc320;'use strict';const Sequelize=require(_0x4b6d71('0x2e')),rs=require('randomstring');module[_0x4b6d71('0x20')]={'name':{'type':Sequelize['STRING'],'allowNull':![]},'address':{'type':Sequelize[_0x4b6d71('0x29')],'allowNull':![],'unique':_0x4b6d71('0x1c')},'description':{'type':Sequelize[_0x4b6d71('0x29')]},'mapKey':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x1a')},'mapKeyOffline':{'type':Sequelize['STRING'],'defaultValue':_0x4b6d71('0x1a')},'key':{'type':Sequelize[_0x4b6d71('0x29')],'allowNull':![]},'agentAlias':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x17')},'customerAlias':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':'Me'},'color':{'type':Sequelize[_0x4b6d71('0x29')],'allowNull':![],'defaultValue':_0x4b6d71('0x11'),'validate':{'notEmpty':!![]}},'color_button':{'type':Sequelize[_0x4b6d71('0x29')],'allowNull':![],'defaultValue':_0x4b6d71('0x11'),'validate':{'notEmpty':!![]}},'textColor':{'type':Sequelize[_0x4b6d71('0x29')],'allowNull':![],'defaultValue':'#ffffff','validate':{'notEmpty':!![]}},'fontSize':{'type':Sequelize[_0x4b6d71('0x21')],'defaultValue':0xf},'remote':{'type':Sequelize[_0x4b6d71('0x29')]},'animation':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':!![]},'header_shape':{'type':Sequelize[_0x4b6d71('0x19')](_0x4b6d71('0x15'),_0x4b6d71('0x22')),'defaultValue':_0x4b6d71('0x15')},'header_online':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':'We\x20are\x20here!'},'start_chat_button':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x10')},'offline_chat_button':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x1f')},'header_offline':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x24')},'download_transcript':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'timeout':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'whiteLabel':{'type':Sequelize['STRING'],'defaultValue':_0x4b6d71('0x4')},'defaultWhiteLabel':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'sitepic':{'type':Sequelize['TEXT']},'closingQuestion':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x30')},'formSubmitSuccessMessage':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x0')},'formSubmitFailureMessage':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x2c')},'noteTitle':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x14')},'placeholderMessage':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x13')},'closingMessage':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x1e')},'closingMessageButton':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x1f')},'skipMessageButton':{'type':Sequelize['STRING'],'defaultValue':'Skip'},'conditionAgreement':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'enableRating':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'enableFeedback':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'enableSendButton':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'feedbackTitle':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x7')},'ratingType':{'type':Sequelize[_0x4b6d71('0x19')](_0x4b6d71('0x9'),'thumb'),'defaultValue':_0x4b6d71('0x9')},'ratingStarsNumber':{'type':Sequelize['INTEGER'],'defaultValue':0x5},'onlineForm':{'type':Sequelize[_0x4b6d71('0x1')],'defaultValue':function(){const _0x2217e3=_0x4b6d71;return JSON[_0x2217e3('0xd')]({'items':[{'type':'input','variable':null,'config':{'placeholder':_0x2217e3('0x2a'),'type':_0x2217e3('0x26'),'required':!![]},'props':{'title':_0x2217e3('0x2a'),'helpText':''}},{'type':'input','props':{'title':_0x2217e3('0x1a'),'helpText':''},'config':{'required':!![],'placeholder':'email','type':_0x2217e3('0x1a')},'variable':null}],'fromKey':0x1});},'get':function(){const _0x24e2a2=_0x4b6d71;return this['getDataValue'](_0x24e2a2('0x2'))?JSON['parse'](this[_0x24e2a2('0x23')](_0x24e2a2('0x2'))):{};},'set':function(_0x38614e){const _0x162c7a=_0x4b6d71;return this[_0x162c7a('0xb')](_0x162c7a('0x2'),JSON['stringify'](_0x38614e));}},'offlineForm':{'type':Sequelize[_0x4b6d71('0x1')],'defaultValue':function(){const _0x4b8d98=_0x4b6d71;return JSON['stringify']({'items':[{'type':_0x4b8d98('0x12'),'props':{'title':_0x4b8d98('0x1a'),'helpText':''},'config':{'required':!![],'placeholder':_0x4b8d98('0x1a'),'type':_0x4b8d98('0x1a')},'variable':null},{'type':_0x4b8d98('0x1b'),'config':{'placeholder':_0x4b8d98('0x3')},'props':{'title':'Comments','helpText':'Leave\x20your\x20comments'}}],'fromKey':0x0});},'get':function(){const _0x2d7007=_0x4b6d71;return this['getDataValue'](_0x2d7007('0x16'))?JSON[_0x2d7007('0x1d')](this[_0x2d7007('0x23')](_0x2d7007('0x16'))):{};},'set':function(_0x578e81){const _0x54455c=_0x4b6d71;return this[_0x54455c('0xb')](_0x54455c('0x16'),JSON[_0x54455c('0xd')](_0x578e81));}},'token':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':function(){const _0x42dd27=_0x4b6d71;return rs[_0x42dd27('0x2d')]();}},'autoclose':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':!![]},'enableCustomerWriting':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'forwardTranscript':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'forwardTranscriptMessage':{'type':Sequelize[_0x4b6d71('0x29')]},'forwardOffline':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'forwardOfflineAddress':{'type':Sequelize[_0x4b6d71('0x29')]},'waitingTitle':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':'All\x20of\x20our\x20agents\x20are\x20busy\x20at\x20this\x20time.\x20Your\x20chat\x20is\x20very\x20important\x20to\x20us.'},'waitingMessage':{'type':Sequelize['STRING'],'defaultValue':_0x4b6d71('0x28')},'offlineMessageSubject':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':'New\x20offline\x20message\x20from\x20websiteName'},'offlineMessageBody':{'type':Sequelize['STRING'],'defaultValue':_0x4b6d71('0x6')},'enableUnmanagedNote':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':!![]},'unmanagedMessage':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0xe')},'skipUnmanaged':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x18')},'sendUnmanaged':{'type':Sequelize['STRING'],'defaultValue':_0x4b6d71('0x1f')},'enableCustomerAttachment':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'enableCustomerCheckmarks':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'agentAvatar':{'type':Sequelize['TEXT']},'showAgentAvatar':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'timezone':{'type':Sequelize['STRING']},'notificationTemplate':{'type':Sequelize[_0x4b6d71('0x1')],'defaultValue':function(){const _0x2d162f=_0x4b6d71;return _0x2d162f('0x25');}},'notificationSound':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':!![]},'notificationShake':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'hideWhenOffline':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'agentIdentifier':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':'website_alias'},'waitForTheAssignedAgent':{'type':Sequelize['INTEGER'],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'alignment':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x2b')},'verticalAlignment':{'type':Sequelize[_0x4b6d71('0x21')],'defaultValue':0x1e},'messagesAlignment':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0x27')},'defaultTitle':{'type':Sequelize['STRING']},'customerAvatar':{'type':Sequelize[_0x4b6d71('0x1')]},'showCustomerAvatar':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'messageFontSize':{'type':Sequelize['INTEGER'],'defaultValue':0xc},'backgroundColor':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x4b6d71('0xc'),'validate':{'notEmpty':!![]}},'queueTransfer':{'type':Sequelize[_0x4b6d71('0x5')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x4b6d71('0x21')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0x4b6d71('0x21')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'systemAlias':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':_0x4b6d71('0xf')},'systemAvatar':{'type':Sequelize[_0x4b6d71('0x1')]},'mandatoryDispositionPauseId':{'type':Sequelize[_0x4b6d71('0x21')],'comment':'Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled'},'mandatoryDisposition':{'type':Sequelize['BOOLEAN'],'defaultValue':![],'comment':_0x4b6d71('0x8'),'set':function(_0x336522){const _0x29f16c=_0x4b6d71;if(!_0x336522)this[_0x29f16c('0xb')](_0x29f16c('0x2f'),null);this[_0x29f16c('0xb')](_0x29f16c('0xa'),_0x336522);}},'vidaooEscalation':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'vidaooApiKey':{'type':Sequelize[_0x4b6d71('0x29')],'defaultValue':![]}}; \ No newline at end of file diff --git a/server/api/chatWebsite/chatWebsite.controller.js b/server/api/chatWebsite/chatWebsite.controller.js index 7aba8a5..eb66544 100644 --- a/server/api/chatWebsite/chatWebsite.controller.js +++ b/server/api/chatWebsite/chatWebsite.controller.js @@ -1 +1 @@ -const a111_0x5de3=['describe','unmanaged','createdAt','order','from\x20is\x20mandatory','AttachmentId','externalUrl','offlineMessageSubject','MailAccount','../../components/parsers/qs','contact','server/files/images/avatars/system_avatar.png','true','interaction','request\x20sent','No\x20timezone','getSnippet','model','type','updatedAt','files/chat/iframe.js','notify','filename','ejs','false','ContactId','server/files/images/logos/','showCustomerAvatar','Disposition','ChatWebsite,\x20%s,\x20%s','SendMail','../../rediscache','stringify','defaults','getFields','ids','Interval','pick','authentication','key','include','findAll','addAvatar','removeDispositions','toPairs','VIRTUAL','query','getProactiveActions','unknown','UserId','result','addLogo','lodash','update','sendStatus','priority','UserProfileSection','Content-Range','Smtp','json','offset','User','sitepic','end','./chatWebsite.socket','getAnswers','firstName','count','%s\x20%s','threadId','fromKey','DESC','existsSync','rows','x-real-ip','server/files/images/logos/default_logo.svg','Intervals','chatLicenseExceeded','list','customerAvatar','mapKeyOffline\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','agentAvatar','x-forwarded-for','onlineForm','addDisposition','mapKeyOffline\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20','ChatInteraction','UserProfileResource','error','rawAttributes','offline','mustache','app','getInteractions','limit','merge','undefined','keys','chatProactiveAction','addInteraction','debug','messageId','format','referer','length','getOfflineMessages','destroy','get','code','userChatWebsite:remove','server/files/images/avatars/customer_avatar.png','headers','inspect','create','../../config/environment','all','connection','emit','findOrCreate','version','CmContact','List','[%s][INTERVAL][%s]\x20%s\x20%s\x20(%s)','autoclose','replace','filters','body\x20is\x20mandatory\x20and\x20not\x20empty','getAgents','client','items','removeAnswers','remoteAddress','*,*,*,*','account','ChatApplication','set','remote','setUA','map','includeAll','autoAssociation','addAnswer','nolimit','util','../../config/license/util','mapKeyOffline','path','addApplications','service','device','x-real-port','getLogo','catch','mapKey','addProactiveActions','custom','getLicense','fullname','customerIp','virtual','from','like','download','Pause','License','indexOf','findOne','iftime\x20%s,%s','addAgents','register','applications','Contact','MailServerOut','timezone','port','lastName','getApplications','ListId','stack','fields','ONLINE','color','getAvatar','startRouting','offlineMessageBody','server/files/templates/chatOfflineMessage.ejs','CmList','bulkCreate','vendor','fieldName','status','internal','sequelize','difference','tag','server/files/images/avatars/','querystring','Applications','info','\x22%s\x22\x20<%s>','Contacts','ChatOfflineMessage','textColor','Unable\x20to\x20retrieve\x20the\x20current\x20user','mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','userChatWebsite:save','waitForTheAssignedAgent','no\x20available\x20attributes','Start','CompanyId','ChatWebsites','EventManager','unshift','OFFLINE','isArray','getSystemAvatar','transaction','includes','then','name','removeAgents','message','omit','isNil','options','utf8','role','created','systemAvatar','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','getCustomerAvatar','iftime\x20%s','push','secure','agent','index','pass','ChatWebsite','findAndCountAll','Tag','ChatProactiveAction','chatVersion','sort','CannedAnswer','host','readFileSync','body','addCustomerAvatar','ChatWebsite,\x20%s,\x20%s,\x20%s','alignment','send','forwardOfflineAddress','attributes','filter','interval','online','render','request','file','root','mandatoryDispositionPause','ChatMessage','intersection','where','cf-connecting-ip','params','browser','verticalAlignment','Command','http','ChatWebsiteId','join','user'];(function(_0x5adf03,_0x5de32f){const _0x4e4d8e=function(_0x5388ad){while(--_0x5388ad){_0x5adf03['push'](_0x5adf03['shift']());}};_0x4e4d8e(++_0x5de32f);}(a111_0x5de3,0xa7));const a111_0x4e4d=function(_0x5adf03,_0x5de32f){_0x5adf03=_0x5adf03-0x0;let _0x4e4d8e=a111_0x5de3[_0x5adf03];return _0x4e4d8e;};const _0x2e2b8c=a111_0x4e4d;'use strict';const Mustache=require(_0x2e2b8c('0xc5')),util=require(_0x2e2b8c('0xf9')),path=require(_0x2e2b8c('0xfc')),ejs=require(_0x2e2b8c('0x81')),fs=require('fs'),_=require(_0x2e2b8c('0x9e')),querystring=require(_0x2e2b8c('0x1d')),qs=require(_0x2e2b8c('0x73')),logger=require('../../config/logger')('api'),config=require(_0x2e2b8c('0xdc')),db=require('../../mysqldb')['db'],{Op,ValidationError}=require(_0x2e2b8c('0x19')),{getSocket}=require(_0x2e2b8c('0x89')),socket=getSocket();require(_0x2e2b8c('0xaa'))[_0x2e2b8c('0x2')](socket);const jayson=require('jayson/promise'),client=jayson[_0x2e2b8c('0xea')][_0x2e2b8c('0x66')]({'port':0x232c}),client9002=jayson[_0x2e2b8c('0xea')][_0x2e2b8c('0x66')]({'port':0x232a}),client9003=jayson[_0x2e2b8c('0xea')][_0x2e2b8c('0x66')]({'port':0x232b});function respondWithRpcPromise(_0x5388ad,_0x25e80b,_0x30eabc,_0x377c43){return new Promise(function(_0x299815,_0x4a86e5){const _0x1117c6=a111_0x4e4d,_0x4a4b02=_0x377c43||client;return _0x4a4b02[_0x1117c6('0x5a')](_0x5388ad,_0x30eabc)[_0x1117c6('0x33')](function(_0x139255){const _0x1d3685=_0x1117c6;logger['info'](_0x1d3685('0x87'),_0x25e80b,'request\x20sent'),logger[_0x1d3685('0xce')](_0x1d3685('0x51'),_0x25e80b,_0x1d3685('0x78'),JSON[_0x1d3685('0x8a')](_0x139255));if(_0x139255['error']){if(_0x139255[_0x1d3685('0xc2')][_0x1d3685('0xd6')]===0x1f4)return logger[_0x1d3685('0xc2')](_0x1d3685('0x87'),_0x25e80b,_0x139255[_0x1d3685('0xc2')][_0x1d3685('0x36')]),_0x4a86e5(_0x139255[_0x1d3685('0xc2')]['message']);return logger[_0x1d3685('0xc2')](_0x1d3685('0x87'),_0x25e80b,_0x139255[_0x1d3685('0xc2')][_0x1d3685('0x36')]),_0x299815(_0x139255['error'][_0x1d3685('0x36')]);}else logger[_0x1d3685('0x1f')](_0x1d3685('0x87'),_0x25e80b,_0x1d3685('0x78')),_0x299815(_0x139255[_0x1d3685('0x9c')]['message']);})[_0x1117c6('0x102')](function(_0x5192e2){const _0x363f30=_0x1117c6;logger[_0x363f30('0xc2')](_0x363f30('0x87'),_0x25e80b,_0x5192e2),_0x4a86e5(_0x5192e2);});});}function respondWithStatusCode(_0x1cf930,_0x106c04){return _0x106c04=_0x106c04||0xcc,function(_0x425fe6){const _0xd4a10=a111_0x4e4d;if(_0x425fe6)return _0x1cf930[_0xd4a10('0xa0')](_0x106c04);return _0x1cf930[_0xd4a10('0x17')](_0x106c04)[_0xd4a10('0xa9')]();};}function respondWithResult(_0x483f23,_0x3ecdd4){return _0x3ecdd4=_0x3ecdd4||0xc8,function(_0x3c97d5){const _0x55587e=a111_0x4e4d;if(_0x3c97d5)return _0x483f23[_0x55587e('0x17')](_0x3ecdd4)[_0x55587e('0xa5')](_0x3c97d5);};}function respondWithFilteredResult(_0x30fb34,_0x541669){return function(_0x137526){const _0x58bd21=a111_0x4e4d;if(_0x137526){const _0x446d7e=_0x137526['count'],_0x4e81b6=_0x541669[_0x58bd21('0xa6')];let _0x523005=_0x541669[_0x58bd21('0xa6')]+_0x541669['limit'],_0x517101;return _0x523005>=_0x446d7e?(_0x523005=_0x446d7e,_0x517101=0xc8):_0x517101=0xce,_0x30fb34['status'](_0x517101),_0x30fb34[_0x58bd21('0xf1')](_0x58bd21('0xa3'),_0x4e81b6+'-'+_0x523005+'/'+_0x446d7e)[_0x58bd21('0xa5')](_0x137526);}return null;};}function saveUpdates(_0x1879e4){return function(_0x41ad15){const _0xdf2c4c=a111_0x4e4d;if(_0x41ad15)return _0x41ad15[_0xdf2c4c('0x9f')](_0x1879e4)['then'](function(_0x5d5d1b){return _0x5d5d1b;});return null;};}function removeEntity(_0x1651c3){return function(_0x290753){const _0x3b8cbd=a111_0x4e4d;if(_0x290753)return _0x290753['destroy']()[_0x3b8cbd('0x33')](function(){const _0x3542ff=_0x3b8cbd,_0x2677cf=_0x290753[_0x3542ff('0xd5')]({'plain':!![]}),_0x46036e=_0x3542ff('0x2b');return db[_0x3542ff('0xc1')]['destroy']({'where':{'type':_0x46036e,'resourceId':_0x2677cf['id']}})[_0x3542ff('0x33')](function(){return _0x290753;});})[_0x3b8cbd('0x33')](function(){const _0x3bf176=_0x3b8cbd;_0x1651c3[_0x3bf176('0x17')](0xcc)[_0x3bf176('0xa9')]();});};}function handleEntityNotFound(_0x749f68){return function(_0x298d08){return!_0x298d08&&_0x749f68['sendStatus'](0x194),_0x298d08;};}function handleError(_0x5464ff,_0x2dc3b2){return _0x2dc3b2=_0x2dc3b2||0x1f4,function(_0x544535){const _0x3b01f4=a111_0x4e4d;logger[_0x3b01f4('0xc2')](_0x544535[_0x3b01f4('0xb')]),_0x544535[_0x3b01f4('0x34')]&&delete _0x544535[_0x3b01f4('0x34')],_0x5464ff[_0x3b01f4('0x17')](_0x2dc3b2)[_0x3b01f4('0x53')](_0x544535);};}exports[_0x2e2b8c('0x44')]=function(_0x8a823d,_0x104390){const _0x1302b7=_0x2e2b8c;let _0x5f2232={'include':[{'model':db[_0x1302b7('0x10d')],'as':_0x1302b7('0x5d')}]};const _0x3e5829={},_0x2fbbee={'count':0x0,'rows':[]},_0x42243c=_[_0x1302b7('0xf4')](db[_0x1302b7('0x46')][_0x1302b7('0xc3')],function(_0x16c1a0){const _0x38d70b=_0x1302b7;return{'name':_0x16c1a0[_0x38d70b('0x16')],'type':_0x16c1a0[_0x38d70b('0x7c')][_0x38d70b('0x91')]};});_0x3e5829[_0x1302b7('0x7b')]=_['map'](_0x42243c,_0x1302b7('0x34')),_0x3e5829[_0x1302b7('0x98')]=_[_0x1302b7('0xcb')](_0x8a823d[_0x1302b7('0x98')]),_0x3e5829[_0x1302b7('0xe7')]=_[_0x1302b7('0x5f')](_0x3e5829[_0x1302b7('0x7b')],_0x3e5829['query']),_0x5f2232['attributes']=_[_0x1302b7('0x5f')](_0x3e5829[_0x1302b7('0x7b')],qs[_0x1302b7('0xc')](_0x8a823d[_0x1302b7('0x98')]['fields'])),_0x5f2232[_0x1302b7('0x55')]=_0x5f2232[_0x1302b7('0x55')]['length']?_0x5f2232[_0x1302b7('0x55')]:_0x3e5829['model'];typeof _0x8a823d[_0x1302b7('0x98')][_0x1302b7('0xf8')]===_0x1302b7('0xca')&&(_0x5f2232[_0x1302b7('0xc8')]=qs['limit'](_0x8a823d[_0x1302b7('0x98')][_0x1302b7('0xc8')]),_0x5f2232[_0x1302b7('0xa6')]=qs[_0x1302b7('0xa6')](_0x8a823d[_0x1302b7('0x98')][_0x1302b7('0xa6')]));_0x5f2232[_0x1302b7('0x6d')]=qs['sort'](_0x8a823d[_0x1302b7('0x98')][_0x1302b7('0x4b')]),_0x5f2232[_0x1302b7('0x60')]=qs['filters'](_['pick'](_0x8a823d['query'],_0x3e5829['filters']),_0x42243c);_0x8a823d['query']['filter']&&(_0x5f2232['where']=_['merge'](_0x5f2232['where'],{[Op['or']]:_[_0x1302b7('0xf4')](_0x42243c,function(_0x1c8eb0){const _0x52d2dd=_0x1302b7;if(_0x1c8eb0['type']!==_0x52d2dd('0x97')){const _0x423c5e={};return _0x423c5e[_0x1c8eb0['name']]={[Op[_0x52d2dd('0x10b')]]:'%'+_0x8a823d[_0x52d2dd('0x98')]['filter']+'%'},_0x423c5e;}})}));_0x5f2232=_[_0x1302b7('0xc9')]({},_0x5f2232,_0x8a823d['options']);const _0x235af4={'where':_0x5f2232[_0x1302b7('0x60')]};return db[_0x1302b7('0x46')][_0x1302b7('0xad')](_0x235af4)[_0x1302b7('0x33')](function(_0x5a2be2){const _0x4677e8=_0x1302b7;return _0x2fbbee['count']=_0x5a2be2,_0x8a823d[_0x4677e8('0x98')][_0x4677e8('0xf5')]&&(_0x5f2232[_0x4677e8('0x92')]=[{'all':!![]}]),db['ChatWebsite'][_0x4677e8('0x93')](_0x5f2232);})[_0x1302b7('0x33')](function(_0x24f3c4){const _0xe1cb0b=_0x1302b7;return _0x2fbbee[_0xe1cb0b('0xb3')]=_0x24f3c4,_0x2fbbee;})['then'](respondWithFilteredResult(_0x104390,_0x5f2232))[_0x1302b7('0x102')](handleError(_0x104390,null));},exports['show']=function(_0x479b46,_0x2535f5){const _0xbe45cc=_0x2e2b8c;let _0x14934a={'raw':![],'where':{'id':_0x479b46['params']['id']},'include':[{'model':db[_0xbe45cc('0x10d')],'as':_0xbe45cc('0x5d')}]};const _0x175730={};return _0x175730[_0xbe45cc('0x7b')]=_[_0xbe45cc('0xcb')](db['ChatWebsite'][_0xbe45cc('0xc3')]),_0x175730['query']=_[_0xbe45cc('0xcb')](_0x479b46[_0xbe45cc('0x98')]),_0x175730[_0xbe45cc('0xe7')]=_['intersection'](_0x175730[_0xbe45cc('0x7b')],_0x175730[_0xbe45cc('0x98')]),_0x14934a[_0xbe45cc('0x55')]=_[_0xbe45cc('0x5f')](_0x175730['model'],qs['fields'](_0x479b46[_0xbe45cc('0x98')][_0xbe45cc('0xc')])),_0x14934a[_0xbe45cc('0x55')]=_0x14934a[_0xbe45cc('0x55')][_0xbe45cc('0xd2')]?_0x14934a[_0xbe45cc('0x55')]:_0x175730[_0xbe45cc('0x7b')],_0x479b46['query'][_0xbe45cc('0xf5')]&&(_0x14934a['include']=[{'all':!![]}]),_0x14934a=_['merge']({},_0x14934a,_0x479b46['options']),db[_0xbe45cc('0x46')][_0xbe45cc('0x110')](_0x14934a)['then'](handleEntityNotFound(_0x2535f5,null))[_0xbe45cc('0x33')](respondWithResult(_0x2535f5,null))[_0xbe45cc('0x102')](handleError(_0x2535f5,null));},exports[_0x2e2b8c('0xdb')]=function(_0x423b23,_0x8b2866){const _0x1cd81e=_0x2e2b8c;return db['ChatWebsite'][_0x1cd81e('0xdb')](_0x423b23[_0x1cd81e('0x4f')],{})['then'](function(_0xbaacd2){const _0x5b16b6=_0x1cd81e,_0x4a4af4=_0x423b23[_0x5b16b6('0x69')][_0x5b16b6('0xd5')]({'plain':!![]});if(!_0x4a4af4)throw new Error(_0x5b16b6('0x24'));if(_0x4a4af4[_0x5b16b6('0x3b')]===_0x5b16b6('0x69')){const _0x5cb923=_0xbaacd2[_0x5b16b6('0xd5')]({'plain':!![]}),_0x926fec=_0x5b16b6('0x2b');return db[_0x5b16b6('0xa2')][_0x5b16b6('0x110')]({'where':{'name':_0x926fec,'userProfileId':_0x4a4af4['userProfileId']},'raw':!![]})['then'](function(_0x4e1b30){const _0x50243c=_0x5b16b6;return _0x4e1b30&&_0x4e1b30[_0x50243c('0xf6')]===0x0?db['UserProfileResource']['create']({'name':_0x5cb923['name'],'resourceId':_0x5cb923['id'],'type':_0x4e1b30[_0x50243c('0x34')],'sectionId':_0x4e1b30['id']},{})[_0x50243c('0x33')](function(){return _0xbaacd2;}):_0xbaacd2;})[_0x5b16b6('0x102')](function(_0x1d190c){const _0x19c3b3=_0x5b16b6;logger['error'](_0x19c3b3('0x3e'),_0x1d190c);throw _0x1d190c;});}return _0xbaacd2;})[_0x1cd81e('0x33')](respondWithResult(_0x8b2866,0xc9))[_0x1cd81e('0x102')](handleError(_0x8b2866,null));},exports[_0x2e2b8c('0x9f')]=function(_0x149297,_0x2478e2){const _0x3755d5=_0x2e2b8c;return _0x149297[_0x3755d5('0x4f')]['id']&&delete _0x149297[_0x3755d5('0x4f')]['id'],db['ChatWebsite'][_0x3755d5('0x110')]({'where':{'id':_0x149297['params']['id']},'include':[{'model':db[_0x3755d5('0x10d')],'as':_0x3755d5('0x5d')}]})[_0x3755d5('0x33')](handleEntityNotFound(_0x2478e2,null))[_0x3755d5('0x33')](saveUpdates(_0x149297[_0x3755d5('0x4f')],null))['then'](respondWithResult(_0x2478e2,null))['catch'](handleError(_0x2478e2,null));},exports[_0x2e2b8c('0xd4')]=function(_0x47b669,_0x22eb43){const _0x1162b1=_0x2e2b8c;return db['ChatWebsite'][_0x1162b1('0x110')]({'where':{'id':_0x47b669[_0x1162b1('0x62')]['id']}})[_0x1162b1('0x33')](handleEntityNotFound(_0x22eb43,null))[_0x1162b1('0x33')](removeEntity(_0x22eb43,null))[_0x1162b1('0x102')](handleError(_0x22eb43,null));},exports[_0x2e2b8c('0x6a')]=function(_0x171d69,_0x36a812){const _0x2c62a3=_0x2e2b8c;return db['ChatWebsite'][_0x2c62a3('0x6a')]()[_0x2c62a3('0x33')](respondWithResult(_0x36a812,null))[_0x2c62a3('0x102')](handleError(_0x36a812,null));},exports[_0x2e2b8c('0xbe')]=function(_0xbd99f8,_0x28e28a){const _0x2409ef=_0x2e2b8c;return _0xbd99f8['body']['id']&&delete _0xbd99f8[_0x2409ef('0x4f')]['id'],db[_0x2409ef('0x46')][_0x2409ef('0x110')]({'where':{'id':_0xbd99f8[_0x2409ef('0x62')]['id']}})['then'](handleEntityNotFound(_0x28e28a,null))[_0x2409ef('0x33')](function(_0x41d891){const _0x28d680=_0x2409ef;if(_0x41d891)return _0xbd99f8[_0x28d680('0x4f')][_0x28d680('0x67')]=_0x41d891['id'],db[_0x28d680('0x86')][_0x28d680('0xdb')](_0xbd99f8[_0x28d680('0x4f')]);})[_0x2409ef('0x33')](respondWithResult(_0x28e28a,null))[_0x2409ef('0x102')](handleError(_0x28e28a,null));},exports['getDispositions']=function(_0x21c09f,_0x286a8a){const _0x44bc6e=_0x2e2b8c;let _0x417c4c={'raw':![],'where':{}};const _0x2a3f25={},_0x5482c1={'count':0x0,'rows':[]};return db[_0x44bc6e('0x46')][_0x44bc6e('0x110')]({'where':{'id':_0x21c09f[_0x44bc6e('0x62')]['id']}})[_0x44bc6e('0x33')](handleEntityNotFound(_0x286a8a,null))[_0x44bc6e('0x33')](function(_0xe2d6a1){const _0x37c022=_0x44bc6e;if(_0xe2d6a1)return _0x2a3f25[_0x37c022('0x7b')]=_['keys'](db[_0x37c022('0x86')]['rawAttributes']),_0x2a3f25[_0x37c022('0x98')]=_[_0x37c022('0xcb')](_0x21c09f[_0x37c022('0x98')]),_0x2a3f25['filters']=_['intersection'](_0x2a3f25[_0x37c022('0x7b')],_0x2a3f25[_0x37c022('0x98')]),_0x417c4c[_0x37c022('0x55')]=_[_0x37c022('0x5f')](_0x2a3f25[_0x37c022('0x7b')],qs[_0x37c022('0xc')](_0x21c09f[_0x37c022('0x98')][_0x37c022('0xc')])),_0x417c4c[_0x37c022('0x55')]=_0x417c4c[_0x37c022('0x55')][_0x37c022('0xd2')]?_0x417c4c[_0x37c022('0x55')]:_0x2a3f25['model'],typeof _0x21c09f[_0x37c022('0x98')]['nolimit']===_0x37c022('0xca')&&(_0x417c4c[_0x37c022('0xc8')]=qs['limit'](_0x21c09f['query'][_0x37c022('0xc8')]),_0x417c4c[_0x37c022('0xa6')]=qs[_0x37c022('0xa6')](_0x21c09f[_0x37c022('0x98')][_0x37c022('0xa6')])),_0x417c4c[_0x37c022('0x6d')]=qs[_0x37c022('0x4b')](_0x21c09f[_0x37c022('0x98')][_0x37c022('0x4b')]),_0x417c4c[_0x37c022('0x60')]=qs[_0x37c022('0xe7')](_[_0x37c022('0x8f')](_0x21c09f[_0x37c022('0x98')],_0x2a3f25[_0x37c022('0xe7')])),_0x417c4c['where']['ChatWebsiteId']=_0xe2d6a1['id'],_0x21c09f['query']['filter']&&(_0x417c4c['where']=_['merge'](_0x417c4c[_0x37c022('0x60')],{[Op['or']]:_[_0x37c022('0xf4')](_0x417c4c[_0x37c022('0x55')],function(_0x3891eb){const _0x6daf08=_0x37c022,_0x50c4f5={};return _0x50c4f5[_0x3891eb]={[Op[_0x6daf08('0x10b')]]:'%'+_0x21c09f[_0x6daf08('0x98')][_0x6daf08('0x56')]+'%'},_0x50c4f5;})})),_0x417c4c=_[_0x37c022('0xc9')]({},_0x417c4c,_0x21c09f[_0x37c022('0x39')]),db['Disposition']['count']({'where':_0x417c4c['where']})[_0x37c022('0x33')](function(_0x4a6caf){const _0x1020af=_0x37c022;return _0x5482c1['count']=_0x4a6caf,_0x21c09f[_0x1020af('0x98')][_0x1020af('0xf5')]&&(_0x417c4c[_0x1020af('0x92')]=[{'all':!![]}]),db[_0x1020af('0x86')][_0x1020af('0x93')](_0x417c4c);})[_0x37c022('0x33')](function(_0x41d0f1){const _0x2c31d9=_0x37c022;return _0x5482c1[_0x2c31d9('0xb3')]=_0x41d0f1,_0x5482c1;});})['then'](respondWithFilteredResult(_0x286a8a,_0x417c4c))[_0x44bc6e('0x102')](handleError(_0x286a8a,null));},exports[_0x2e2b8c('0x95')]=function(_0x318655,_0x46693c){const _0x17efa2=_0x2e2b8c;return db[_0x17efa2('0x46')][_0x17efa2('0x110')]({'where':{'id':_0x318655[_0x17efa2('0x62')]['id']}})[_0x17efa2('0x33')](handleEntityNotFound(_0x46693c,null))[_0x17efa2('0x33')](function(_0x59bf6a){const _0x28251f=_0x17efa2;if(_0x59bf6a)return _0x59bf6a[_0x28251f('0x95')](_0x318655[_0x28251f('0x98')]['ids']);})[_0x17efa2('0x33')](respondWithStatusCode(_0x46693c,null))['catch'](handleError(_0x46693c,null));},exports[_0x2e2b8c('0xf7')]=function(_0x528bfe,_0x215bf3){const _0x467dc9=_0x2e2b8c;return _0x528bfe['body']['id']&&delete _0x528bfe[_0x467dc9('0x4f')]['id'],db[_0x467dc9('0x46')][_0x467dc9('0x110')]({'where':{'id':_0x528bfe[_0x467dc9('0x62')]['id']}})['then'](handleEntityNotFound(_0x215bf3,null))[_0x467dc9('0x33')](function(_0x5ea844){const _0x3f75d9=_0x467dc9;if(_0x5ea844)return _0x528bfe['body']['ChatWebsiteId']=_0x5ea844['id'],db['CannedAnswer'][_0x3f75d9('0xdb')](_0x528bfe[_0x3f75d9('0x4f')]);})[_0x467dc9('0x33')](respondWithResult(_0x215bf3,null))[_0x467dc9('0x102')](handleError(_0x215bf3,null));},exports[_0x2e2b8c('0xab')]=function(_0x47a842,_0x3ee140){const _0x3bd3c4=_0x2e2b8c;let _0x13d514={'raw':![],'where':{}};const _0xe8faa5={},_0x22d444={'count':0x0,'rows':[]};return db['ChatWebsite']['findOne']({'where':{'id':_0x47a842[_0x3bd3c4('0x62')]['id']}})[_0x3bd3c4('0x33')](handleEntityNotFound(_0x3ee140,null))[_0x3bd3c4('0x33')](function(_0x171147){const _0x25d434=_0x3bd3c4;if(_0x171147)return _0xe8faa5['model']=_['keys'](db[_0x25d434('0x4c')][_0x25d434('0xc3')]),_0xe8faa5[_0x25d434('0x98')]=_[_0x25d434('0xcb')](_0x47a842['query']),_0xe8faa5[_0x25d434('0xe7')]=_[_0x25d434('0x5f')](_0xe8faa5[_0x25d434('0x7b')],_0xe8faa5['query']),_0x13d514[_0x25d434('0x55')]=_[_0x25d434('0x5f')](_0xe8faa5[_0x25d434('0x7b')],qs[_0x25d434('0xc')](_0x47a842['query'][_0x25d434('0xc')])),_0x13d514[_0x25d434('0x55')]=_0x13d514[_0x25d434('0x55')][_0x25d434('0xd2')]?_0x13d514[_0x25d434('0x55')]:_0xe8faa5[_0x25d434('0x7b')],typeof _0x47a842[_0x25d434('0x98')][_0x25d434('0xf8')]===_0x25d434('0xca')&&(_0x13d514['limit']=qs[_0x25d434('0xc8')](_0x47a842[_0x25d434('0x98')][_0x25d434('0xc8')]),_0x13d514[_0x25d434('0xa6')]=qs[_0x25d434('0xa6')](_0x47a842[_0x25d434('0x98')][_0x25d434('0xa6')])),_0x13d514['order']=qs[_0x25d434('0x4b')](_0x47a842['query'][_0x25d434('0x4b')]),_0x13d514['where']=qs[_0x25d434('0xe7')](_['pick'](_0x47a842['query'],_0xe8faa5[_0x25d434('0xe7')])),_0x13d514[_0x25d434('0x60')][_0x25d434('0x67')]=_0x171147['id'],_0x47a842[_0x25d434('0x98')][_0x25d434('0x56')]&&(_0x13d514[_0x25d434('0x60')]=_[_0x25d434('0xc9')](_0x13d514[_0x25d434('0x60')],{[Op['or']]:_[_0x25d434('0xf4')](_0x13d514[_0x25d434('0x55')],function(_0xf81945){const _0x669a34=_0x25d434,_0x30b354={};return _0x30b354[_0xf81945]={[Op[_0x669a34('0x10b')]]:'%'+_0x47a842[_0x669a34('0x98')][_0x669a34('0x56')]+'%'},_0x30b354;})})),_0x13d514=_[_0x25d434('0xc9')]({},_0x13d514,_0x47a842[_0x25d434('0x39')]),db[_0x25d434('0x4c')][_0x25d434('0xad')]({'where':_0x13d514[_0x25d434('0x60')]})[_0x25d434('0x33')](function(_0x27414d){const _0x3c5350=_0x25d434;return _0x22d444[_0x3c5350('0xad')]=_0x27414d,_0x47a842[_0x3c5350('0x98')][_0x3c5350('0xf5')]&&(_0x13d514['include']=[{'all':!![]}]),db[_0x3c5350('0x4c')][_0x3c5350('0x93')](_0x13d514);})[_0x25d434('0x33')](function(_0x82485){return _0x22d444['rows']=_0x82485,_0x22d444;});})[_0x3bd3c4('0x33')](respondWithFilteredResult(_0x3ee140,_0x13d514))[_0x3bd3c4('0x102')](handleError(_0x3ee140,null));},exports[_0x2e2b8c('0xec')]=function(_0x5aa867,_0x58a5d3){const _0x457fa2=_0x2e2b8c;return db[_0x457fa2('0x46')][_0x457fa2('0x110')]({'where':{'id':_0x5aa867[_0x457fa2('0x62')]['id']}})[_0x457fa2('0x33')](handleEntityNotFound(_0x58a5d3,null))[_0x457fa2('0x33')](function(_0x564195){const _0x2f3999=_0x457fa2;if(_0x564195)return _0x564195[_0x2f3999('0xec')](_0x5aa867['query'][_0x2f3999('0x8d')]);})['then'](respondWithStatusCode(_0x58a5d3,null))[_0x457fa2('0x102')](handleError(_0x58a5d3,null));},exports[_0x2e2b8c('0x9d')]=function(_0x297c5b,_0x575d54){const _0x451c8a=_0x2e2b8c;return _0x297c5b[_0x451c8a('0x4f')][_0x451c8a('0xa8')]=_0x297c5b[_0x451c8a('0x5b')]['filename'],db[_0x451c8a('0x46')][_0x451c8a('0x110')]({'where':{'id':_0x297c5b[_0x451c8a('0x62')]['id']}})[_0x451c8a('0x33')](handleEntityNotFound(_0x575d54,null))[_0x451c8a('0x33')](saveUpdates(_0x297c5b['body'],null))['then'](respondWithResult(_0x575d54,null))[_0x451c8a('0x102')](handleError(_0x575d54,null));},exports[_0x2e2b8c('0x94')]=function(_0x1d7bbb,_0x24e9b2){const _0x52446e=_0x2e2b8c;return _0x1d7bbb[_0x52446e('0x4f')][_0x52446e('0xbb')]=_0x1d7bbb[_0x52446e('0x5b')]['filename'],db[_0x52446e('0x46')][_0x52446e('0x110')]({'where':{'id':_0x1d7bbb['params']['id']}})[_0x52446e('0x33')](handleEntityNotFound(_0x24e9b2,null))[_0x52446e('0x33')](saveUpdates(_0x1d7bbb[_0x52446e('0x4f')],null))[_0x52446e('0x33')](respondWithResult(_0x24e9b2,null))[_0x52446e('0x102')](handleError(_0x24e9b2,null));},exports[_0x2e2b8c('0x50')]=function(_0x144b17,_0x565582){const _0x5f655=_0x2e2b8c;return _0x144b17[_0x5f655('0x4f')]['customerAvatar']=_0x144b17[_0x5f655('0x5b')][_0x5f655('0x80')],db['ChatWebsite'][_0x5f655('0x110')]({'where':{'id':_0x144b17[_0x5f655('0x62')]['id']}})[_0x5f655('0x33')](handleEntityNotFound(_0x565582,null))['then'](saveUpdates(_0x144b17[_0x5f655('0x4f')],null))[_0x5f655('0x33')](respondWithResult(_0x565582,null))[_0x5f655('0x102')](handleError(_0x565582,null));},exports['addSystemAvatar']=function(_0x50d24b,_0x48ffb2){const _0x483bec=_0x2e2b8c;return _0x50d24b[_0x483bec('0x4f')]['systemAvatar']=_0x50d24b['file'][_0x483bec('0x80')],db[_0x483bec('0x46')]['findOne']({'where':{'id':_0x50d24b['params']['id']}})[_0x483bec('0x33')](handleEntityNotFound(_0x48ffb2,null))[_0x483bec('0x33')](saveUpdates(_0x50d24b[_0x483bec('0x4f')],null))[_0x483bec('0x33')](respondWithResult(_0x48ffb2,null))[_0x483bec('0x102')](handleError(_0x48ffb2,null));},exports[_0x2e2b8c('0x101')]=function(_0x733e53,_0x4fda48){const _0x266d10=_0x2e2b8c;let _0x2ad89d=path['join'](config['root'],_0x266d10('0xb5'));const _0x44ddba={'where':{'id':_0x733e53[_0x266d10('0x62')]['id']},'attributes':['id',_0x266d10('0xa8')],'raw':!![]};let _0x44deb5=![];return require(_0x266d10('0xfa'))[_0x266d10('0x106')]()[_0x266d10('0x33')](function(_0x4ba7c7){const _0xd6e377=_0x266d10;_0x4ba7c7&&(_0x44deb5=_0x4ba7c7[_0xd6e377('0x105')]);})['then'](function(){const _0x93d3b1=_0x266d10;return db[_0x93d3b1('0x46')][_0x93d3b1('0x110')](_0x44ddba);})[_0x266d10('0x33')](handleEntityNotFound(_0x4fda48,null))[_0x266d10('0x33')](function(_0x112284){const _0x2c239c=_0x266d10;if(_0x112284)return!_['isNil'](_0x112284[_0x2c239c('0xa8')])&&(fs[_0x2c239c('0xb2')](path[_0x2c239c('0x68')](config['root'],_0x2c239c('0x84'),_0x112284[_0x2c239c('0xa8')]))&&_0x44deb5&&(_0x2ad89d=path[_0x2c239c('0x68')](config[_0x2c239c('0x5c')],_0x2c239c('0x84'),_0x112284['sitepic']))),_0x4fda48[_0x2c239c('0x10c')](_0x2ad89d);})[_0x266d10('0x102')](handleError(_0x4fda48,null));},exports[_0x2e2b8c('0xf')]=function(_0x53f00b,_0x3a70b6){const _0x1b1044=_0x2e2b8c;let _0x14e68c=path['join'](config[_0x1b1044('0x5c')],'server/files/images/avatars/default_avatar.png');const _0x300a54={'where':{'id':_0x53f00b[_0x1b1044('0x62')]['id']},'attributes':['id',_0x1b1044('0xbb')],'raw':!![]};return db[_0x1b1044('0x46')][_0x1b1044('0x110')](_0x300a54)['then'](handleEntityNotFound(_0x3a70b6,null))[_0x1b1044('0x33')](function(_0x1b4098){const _0x3260a4=_0x1b1044;if(_0x1b4098)return!_[_0x3260a4('0x38')](_0x1b4098[_0x3260a4('0xbb')])&&(fs[_0x3260a4('0xb2')](path[_0x3260a4('0x68')](config['root'],_0x3260a4('0x1c'),_0x1b4098[_0x3260a4('0xbb')]))&&(_0x14e68c=path[_0x3260a4('0x68')](config['root'],_0x3260a4('0x1c'),_0x1b4098[_0x3260a4('0xbb')]))),_0x3a70b6[_0x3260a4('0x10c')](_0x14e68c);})['catch'](handleError(_0x3a70b6,null));},exports[_0x2e2b8c('0x3f')]=function(_0x3bd27e,_0xb69d95){const _0x473caa=_0x2e2b8c;let _0x5b366a=path[_0x473caa('0x68')](config[_0x473caa('0x5c')],_0x473caa('0xd8'));const _0xc9d361={'where':{'id':_0x3bd27e['params']['id']},'attributes':['id',_0x473caa('0xb9'),_0x473caa('0x85')],'raw':!![]};return db[_0x473caa('0x46')][_0x473caa('0x110')](_0xc9d361)[_0x473caa('0x33')](handleEntityNotFound(_0xb69d95,null))[_0x473caa('0x33')](function(_0x5352f1){const _0x4df06b=_0x473caa;if(_0x5352f1)return!_['isNil'](_0x5352f1[_0x4df06b('0xb9')])&&(fs['existsSync'](path[_0x4df06b('0x68')](config[_0x4df06b('0x5c')],_0x4df06b('0x1c'),_0x5352f1['customerAvatar']))&&_0x5352f1[_0x4df06b('0x85')]&&(_0x5b366a=path[_0x4df06b('0x68')](config[_0x4df06b('0x5c')],_0x4df06b('0x1c'),_0x5352f1[_0x4df06b('0xb9')]))),_0xb69d95[_0x4df06b('0x10c')](_0x5b366a);})['catch'](handleError(_0xb69d95,null));},exports[_0x2e2b8c('0x30')]=function(_0x22f3b4,_0x5b5e56){const _0x201425=_0x2e2b8c;let _0x511c3d=path[_0x201425('0x68')](config['root'],_0x201425('0x75'));const _0x57fdcf={'where':{'id':_0x22f3b4[_0x201425('0x62')]['id']},'attributes':['id','systemAvatar'],'raw':!![]};return db['ChatWebsite'][_0x201425('0x110')](_0x57fdcf)[_0x201425('0x33')](handleEntityNotFound(_0x5b5e56,null))[_0x201425('0x33')](function(_0x78f6d7){const _0x5d1db3=_0x201425;if(_0x78f6d7)return!_[_0x5d1db3('0x38')](_0x78f6d7['systemAvatar'])&&(fs['existsSync'](path[_0x5d1db3('0x68')](config['root'],_0x5d1db3('0x1c'),_0x78f6d7[_0x5d1db3('0x3d')]))&&(_0x511c3d=path[_0x5d1db3('0x68')](config['root'],_0x5d1db3('0x1c'),_0x78f6d7[_0x5d1db3('0x3d')]))),_0x5b5e56[_0x5d1db3('0x10c')](_0x511c3d);})[_0x201425('0x102')](handleError(_0x5b5e56,null));},exports[_0x2e2b8c('0x7f')]=function(_0xe966c9,_0x120a45){const _0x42c6b8=_0x2e2b8c,_0x1e5311=require('user-agent-parser'),_0x238911=new _0x1e5311(),_0x49fa60=_0x238911[_0x42c6b8('0xf3')](_0xe966c9[_0x42c6b8('0xd9')]['user-agent'])['getResult'](),_0x5253c9={'body':_0xe966c9[_0x42c6b8('0x4f')],'channel':'chat'};let _0x303893=[],_0x530dcd=[];const _0x201a10={};let _0x57cd8d=![];return db[_0x42c6b8('0xe2')][_0x42c6b8('0x6a')]()['then'](function(_0x5046e7){const _0x44e548=_0x42c6b8;if(!_0x5046e7)throw new ValidationError(_0x44e548('0x28'));_0x303893=_[_0x44e548('0x1a')](_['keys'](_0x5046e7),[_0x44e548('0x6c'),_0x44e548('0x7d')]),_0x530dcd=_[_0x44e548('0x1a')](_[_0x44e548('0xcb')](_0x5046e7),[_0x44e548('0x6c'),_0x44e548('0x7d'),_0x44e548('0x2a'),_0x44e548('0xa')]);_0xe966c9[_0x44e548('0x4f')]['id']&&delete _0xe966c9[_0x44e548('0x4f')]['id'];if(_[_0x44e548('0x38')](_0xe966c9[_0x44e548('0x4f')][_0x44e548('0x10a')]))throw new ValidationError(_0x44e548('0x6e'));if(_['isNil'](_0xe966c9[_0x44e548('0x4f')][_0x44e548('0x4f')])||_0xe966c9['body'][_0x44e548('0x4f')]==='')throw new ValidationError(_0x44e548('0xe8'));if(_['isNil'](_0xe966c9[_0x44e548('0x4f')][_0x44e548('0x103')]))throw new ValidationError('mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20'+_0x530dcd);if(!_[_0x44e548('0x32')](_0x530dcd,_0xe966c9['body']['mapKey']))throw new ValidationError(_0x44e548('0x25')+_0x530dcd);_0x201a10[_0xe966c9['body'][_0x44e548('0x103')]]=_0xe966c9['body']['from'];})[_0x42c6b8('0x33')](function(){const _0x401d36=_0x42c6b8;return db['ChatWebsite'][_0x401d36('0x110')]({'where':{'id':_0xe966c9[_0x401d36('0x62')]['id']},'include':[{'model':db[_0x401d36('0x13')],'as':_0x401d36('0xe3'),'include':[{'model':db['CmContact'],'as':_0x401d36('0x21'),'where':_0x201a10,'limit':0x1,'order':[['updatedAt',_0x401d36('0xb1')]]}]},{'model':db['ChatApplication'],'as':_0x401d36('0x1e')}]});})[_0x42c6b8('0x33')](handleEntityNotFound(_0x120a45,null))[_0x42c6b8('0x33')](function(_0x33ecb5){const _0x54693c=_0x42c6b8;if(_0x33ecb5&&_0x33ecb5[_0x54693c('0xe3')]){_0x5253c9['account']=_0x33ecb5,_0x5253c9[_0x54693c('0x3')]=_0x33ecb5['Applications'],_0x5253c9[_0x54693c('0xb8')]=_0x33ecb5['List'],_0x5253c9['applications']=_['orderBy'](_0x5253c9[_0x54693c('0x3')],[_0x54693c('0xa1')],['asc']);_0x5253c9[_0x54693c('0xef')][_0x54693c('0x1e')]&&delete _0x5253c9[_0x54693c('0xef')][_0x54693c('0x1e')];if(_0x5253c9['account'][_0x54693c('0xe3')]&&_0x5253c9[_0x54693c('0xef')]['List'][_0x54693c('0x21')]['length'])return _0x5253c9['account'][_0x54693c('0xe3')][_0x54693c('0x21')][0x0];const _0x5da92a=_[_0x54693c('0x8b')](_0xe966c9['body'],{'firstName':_0xe966c9[_0x54693c('0x4f')][_0x54693c('0x10a')],'ListId':_0x33ecb5[_0x54693c('0xa')]});return _0x5da92a[_0xe966c9[_0x54693c('0x4f')][_0x54693c('0x103')]]=_0xe966c9[_0x54693c('0x4f')][_0x54693c('0x10a')],db[_0x54693c('0xe2')][_0x54693c('0xdb')](_0x5da92a,{'fields':_0x303893,'raw':!![]});}})['then'](handleEntityNotFound(_0x120a45,null))[_0x42c6b8('0x33')](function(_0x4a2f4c){const _0x71a700=_0x42c6b8;_0x5253c9[_0x71a700('0x74')]=_0x4a2f4c;let _0x3e6c14=_0xe966c9[_0x71a700('0x4f')][_0x71a700('0x108')];if(_0xe966c9[_0x71a700('0xd9')]['cf-connecting-ip'])_0x3e6c14=_0xe966c9['headers'][_0x71a700('0x61')];else _0xe966c9['headers'][_0x71a700('0xbc')]&&(_0x3e6c14=_['first'](_0xe966c9['headers']['x-forwarded-for']['split'](',')));if(_0x4a2f4c){const _0x3fc394={'ContactId':_0x4a2f4c['id'],'ChatWebsiteId':_0xe966c9['params']['id'],'from':(_0x4a2f4c[_0x71a700('0xac')]||'')+'\x20'+(_0x4a2f4c[_0x71a700('0x8')]||''),'customerIp':_0x3e6c14,'customerPort':_0xe966c9[_0x71a700('0xd9')][_0x71a700('0x100')]?_0xe966c9[_0x71a700('0xd9')][_0x71a700('0x100')]:null,'referer':_0xe966c9['body'][_0x71a700('0xd1')],'browserName':_0x49fa60[_0x71a700('0x63')]['name']&&_0x49fa60[_0x71a700('0x63')]['version']?util[_0x71a700('0xd0')]('%s\x20%s',_0x49fa60[_0x71a700('0x63')][_0x71a700('0x34')],_0x49fa60[_0x71a700('0x63')][_0x71a700('0xe1')]):_0x71a700('0x9a'),'browserVersion':_0x49fa60['browser'][_0x71a700('0xe1')]||_0x71a700('0x9a'),'osName':util[_0x71a700('0xd0')](_0x71a700('0xae'),_0x49fa60['os'][_0x71a700('0x34')],_0x49fa60['os'][_0x71a700('0xe1')]),'osVersion':_0x49fa60['os']['version'],'deviceModel':_0x49fa60['device']['model']&&_0x49fa60[_0x71a700('0xff')]['vendor']?util[_0x71a700('0xd0')]('%s\x20%s\x20%s',_0x49fa60[_0x71a700('0xff')]['model'],_0x49fa60['device'][_0x71a700('0x15')],_0x49fa60[_0x71a700('0xff')][_0x71a700('0x7c')]):null,'deviceVendor':_0x49fa60[_0x71a700('0xff')][_0x71a700('0x15')],'deviceType':_0x49fa60['device']['type'],'formData':JSON[_0x71a700('0x8a')](_0xe966c9[_0x71a700('0x4f')])},_0xfa6c0d={'ChatWebsiteId':_0xe966c9['params']['id'],'closed':![]};if(_0xe966c9[_0x71a700('0x4f')][_0x71a700('0xaf')])return _0xfa6c0d['threadId']=_0xe966c9[_0x71a700('0x4f')][_0x71a700('0xaf')],db[_0x71a700('0xc0')][_0x71a700('0x110')]({'where':_0xfa6c0d})[_0x71a700('0x33')](function(_0x197aee){const _0x4ee13a=_0x71a700;if(_0x197aee)return[_0x197aee,![]];return _0x3fc394['threadId']=_0xe966c9[_0x4ee13a('0x4f')][_0x4ee13a('0xaf')],_0x3fc394[_0x4ee13a('0x70')]=_0xe966c9[_0x4ee13a('0x4f')]['externalUrl'],db['ChatInteraction'][_0x4ee13a('0xdb')](_0x3fc394)['then'](function(_0x4b3753){return[_0x4b3753,!![]];});});_0xfa6c0d[_0x71a700('0x83')]=_0x4a2f4c['id'];if(_0xe966c9[_0x71a700('0x4f')]['interaction']&&_0xe966c9['body']['interaction']['id'])return _0xfa6c0d['id']=_0xe966c9[_0x71a700('0x4f')][_0x71a700('0x77')]['id'],db[_0x71a700('0xc0')][_0x71a700('0x110')]({'where':_0xfa6c0d})['then'](function(_0x29096d){const _0x19805a=_0x71a700;if(_0x29096d)return[_0x29096d,![]];return db[_0x19805a('0xc0')]['create'](_0x3fc394)['then'](function(_0xf671e5){return[_0xf671e5,!![]];});});return db[_0x71a700('0xc0')]['create'](_0x3fc394)[_0x71a700('0x33')](function(_0x4b1934){return[_0x4b1934,!![]];});}})[_0x42c6b8('0x33')](function([_0x21a5c8,_0x358c09]){const _0x7b31d3=_0x42c6b8;if(_0x21a5c8){_0x57cd8d=_0x358c09;if(!_0x358c09){const _0x284872={'from':(_0x5253c9[_0x7b31d3('0x74')][_0x7b31d3('0xac')]||'')+'\x20'+(_0x5253c9[_0x7b31d3('0x74')][_0x7b31d3('0x8')]||'')};return _0xe966c9[_0x7b31d3('0x4f')]['threadId']&&_0xe966c9['body']['messageId']&&_0xe966c9[_0x7b31d3('0x4f')]['threadId']!=_0xe966c9[_0x7b31d3('0x4f')][_0x7b31d3('0xcf')]&&(_0x284872[_0x7b31d3('0xaf')]=_0xe966c9[_0x7b31d3('0x4f')][_0x7b31d3('0xcf')]),_0x21a5c8['update'](_0x284872);}else return _0x21a5c8;}})[_0x42c6b8('0x33')](function(_0x3a7762){const _0x244ad5=_0x42c6b8;return _0x5253c9[_0x244ad5('0x77')]=_0x3a7762[_0x244ad5('0xd5')]({'plain':!![]}),_0x5253c9[_0x244ad5('0x77')][_0x244ad5('0x3c')]=_0x57cd8d,_0x5253c9[_0x244ad5('0x77')][_0x244ad5('0x3c')]&&(_0x5253c9[_0x244ad5('0xef')][_0x244ad5('0xe5')]&&_0x5253c9[_0x244ad5('0x3')]['push']({'id':0x0,'priority':_0x5253c9[_0x244ad5('0x3')][_0x244ad5('0xd2')]+0x1,'app':'close','appdata':_0x244ad5('0x6b'),'interval':_0x244ad5('0xee')})),db[_0x244ad5('0x5e')][_0x244ad5('0xdb')]({'body':_0xe966c9['body'][_0x244ad5('0x4f')],'ChatWebsiteId':_0xe966c9[_0x244ad5('0x62')]['id'],'ChatInteractionId':_0x3a7762['id'],'direction':'in','ContactId':_0x5253c9[_0x244ad5('0x74')]['id'],'AttachmentId':_0xe966c9[_0x244ad5('0x4f')][_0x244ad5('0x6f')]});})[_0x42c6b8('0x33')](function(_0x1928b2){const _0x1831c2=_0x42c6b8;_0x5253c9['message']=_0x1928b2;if(_0x5253c9[_0x1831c2('0x77')][_0x1831c2('0x9b')])return db['User'][_0x1831c2('0x110')]({'attributes':['id',_0x1831c2('0x34')],'where':{'id':_0x5253c9[_0x1831c2('0x77')][_0x1831c2('0x9b')]}})[_0x1831c2('0x33')](function(_0x2e3d0b){const _0x2007ae=_0x1831c2;return _0x2e3d0b&&(_0x5253c9[_0x2007ae('0x3')][_0x2007ae('0x2d')]({'id':0x0,'priority':0x0,'app':_0x2007ae('0x43'),'appdata':_0x2e3d0b['name']+','+(_0x5253c9[_0x2007ae('0xef')][_0x2007ae('0x27')]||0xa),'interval':_0x2007ae('0xee')}),_0x5253c9['forcedOwnership']=!![]),respondWithRpcPromise('Start','startRouting',_0x5253c9);});return respondWithRpcPromise(_0x1831c2('0x29'),_0x1831c2('0x10'),_0x5253c9);})[_0x42c6b8('0x33')](function(_0x409c8c){const _0xefb4c2=_0x42c6b8;return respondWithRpcPromise('EventManager',_0xefb4c2('0x2c'),{'event':_0xefb4c2('0x7f'),'message':_0x409c8c},client9002),_0x409c8c;})[_0x42c6b8('0x33')](respondWithResult(_0x120a45,null))[_0x42c6b8('0x102')](handleError(_0x120a45,null));},exports[_0x2e2b8c('0xc4')]=function(_0x102d79,_0x1eaf3d){const _0x3500ee=_0x2e2b8c;let _0x326e2b,_0xc3fb97,_0xd0b729=[];const _0x1b6bd9={};return db[_0x3500ee('0xe2')]['describe']()['then'](function(_0x45ecf6){const _0x3f04aa=_0x3500ee;if(!_0x45ecf6)throw new ValidationError(_0x3f04aa('0x28'));_0xd0b729=_['difference'](_['keys'](_0x45ecf6),['createdAt','updatedAt','CompanyId',_0x3f04aa('0xa')]);_0x102d79[_0x3f04aa('0x4f')]['id']&&delete _0x102d79[_0x3f04aa('0x4f')]['id'];if(_[_0x3f04aa('0x38')](_0x102d79['body'][_0x3f04aa('0x10a')]))throw _0x1eaf3d[_0x3f04aa('0x17')](0x1f4)[_0x3f04aa('0x53')](new ValidationError(_0x3f04aa('0x6e')));if(_[_0x3f04aa('0x38')](_0x102d79[_0x3f04aa('0x4f')][_0x3f04aa('0x4f')])||_0x102d79['body'][_0x3f04aa('0x4f')]==='')throw _0x1eaf3d[_0x3f04aa('0x17')](0x1f4)[_0x3f04aa('0x53')](new ValidationError('body\x20is\x20mandatory\x20and\x20not\x20empty'));if(_[_0x3f04aa('0x38')](_0x102d79['body'][_0x3f04aa('0xfb')]))throw _0x1eaf3d[_0x3f04aa('0x17')](0x1f4)[_0x3f04aa('0x53')](new ValidationError(_0x3f04aa('0xbf')+_0xd0b729));if(!_[_0x3f04aa('0x32')](_0xd0b729,_0x102d79[_0x3f04aa('0x4f')][_0x3f04aa('0xfb')]))throw _0x1eaf3d[_0x3f04aa('0x17')](0x1f4)[_0x3f04aa('0x53')](new ValidationError(_0x3f04aa('0xba')+_0xd0b729));_0x1b6bd9[_0x102d79[_0x3f04aa('0x4f')][_0x3f04aa('0xfb')]]=_0x102d79[_0x3f04aa('0x4f')][_0x3f04aa('0x10a')];})[_0x3500ee('0x33')](function(){const _0x2ebcc5=_0x3500ee;return db['ChatWebsite']['findOne']({'where':{'id':_0x102d79[_0x2ebcc5('0x62')]['id']},'include':[{'model':db['CmList'],'as':'List'}]});})[_0x3500ee('0x33')](handleEntityNotFound(_0x1eaf3d,null))[_0x3500ee('0x33')](function(_0x257369){const _0x475003=_0x3500ee;if(_0x257369&&_0x257369['List']){_0xc3fb97=_0x257369;const _0x217961=_[_0x475003('0x8b')](_0x102d79[_0x475003('0x4f')],{'firstName':_0x102d79[_0x475003('0x4f')][_0x475003('0x10a')],'phone':_0x102d79[_0x475003('0x4f')]['from'],'ListId':_0x257369[_0x475003('0xa')]});return _0x217961[_0x102d79[_0x475003('0x4f')][_0x475003('0xfb')]]=_0x102d79[_0x475003('0x4f')]['from'],db[_0x475003('0xe2')][_0x475003('0xe0')]({'where':_0x1b6bd9,'defaults':_0x217961});}})['then'](function([_0x21ac10]){const _0x19d963=_0x3500ee;if(_0x21ac10){const _0x3b07c0=fs[_0x19d963('0x4e')](path[_0x19d963('0x68')](config[_0x19d963('0x5c')],_0x19d963('0x12')),_0x19d963('0x3a')),_0x57a887=ejs[_0x19d963('0x59')](_0x3b07c0,{'body':_[_0x19d963('0x96')](_0x102d79[_0x19d963('0x4f')][_0x19d963('0x4f')]),'bodyTitle':_0xc3fb97[_0x19d963('0x11')]});return db['ChatOfflineMessage']['create']({'body':_0x57a887,'ContactId':_0x21ac10['id'],'ChatWebsiteId':_0xc3fb97['id']});}})[_0x3500ee('0x33')](function(_0x13903a){const _0x41b930=_0x3500ee;if(_0x13903a)return _0x326e2b=_0x13903a,db[_0x41b930('0x72')][_0x41b930('0x110')]({'where':{'service':!![]},'include':[{'model':db[_0x41b930('0x5')],'as':_0x41b930('0xa4'),'raw':!![]}]});})[_0x3500ee('0x33')](function(_0x1f824e){const _0x8a279d=_0x3500ee;if(_0x1f824e&&_0x1f824e[_0x8a279d('0xa4')]&&_0xc3fb97[_0x8a279d('0x54')]){const _0x155414={'tls':{'rejectUnauthorized':![]}};return _0x1f824e[_0x8a279d('0xa4')][_0x8a279d('0xfe')]?_0x155414[_0x8a279d('0xfe')]=_0x1f824e[_0x8a279d('0xa4')]['service']:(_0x155414['host']=_0x1f824e[_0x8a279d('0xa4')][_0x8a279d('0x4d')],_0x155414[_0x8a279d('0x7')]=_0x1f824e['Smtp']['port'],_0x155414[_0x8a279d('0x42')]=_0x1f824e[_0x8a279d('0xa4')][_0x8a279d('0x42')]),_0x1f824e[_0x8a279d('0xa4')][_0x8a279d('0x90')]&&(_0x155414['auth']={'user':_0x1f824e[_0x8a279d('0xa4')][_0x8a279d('0x69')],'pass':_0x1f824e[_0x8a279d('0xa4')][_0x8a279d('0x45')]}),respondWithRpcPromise(_0x8a279d('0x88'),'sendMail',{'account':_0x155414,'message':{'from':util[_0x8a279d('0xd0')](_0x8a279d('0x20'),_0x1f824e[_0x8a279d('0x34')],_0x1f824e['email']||_0x1f824e[_0x8a279d('0xa4')][_0x8a279d('0x69')]),'to':_0xc3fb97['forwardOfflineAddress'],'subject':_0xc3fb97[_0x8a279d('0x71')],'text':_0x326e2b[_0x8a279d('0x4f')]}},client9003)[_0x8a279d('0x33')](function(){return _0x326e2b;})[_0x8a279d('0x102')](function(_0x5f47be){console['error'](_0x5f47be);});}})['then'](function(){if(_0x326e2b)return _0x326e2b;})[_0x3500ee('0x33')](respondWithResult(_0x1eaf3d,null))[_0x3500ee('0x102')](handleError(_0x1eaf3d,null));},exports[_0x2e2b8c('0xcd')]=function(_0xd4d5ed,_0x327fba){const _0x3513ad=_0x2e2b8c;return db['ChatInteraction'][_0x3513ad('0x110')]({'where':{'id':_0xd4d5ed[_0x3513ad('0x62')]['id']}})[_0x3513ad('0x33')](function(_0x4f05f0){const _0x28adaa=_0x3513ad;if(_0x4f05f0)return _0x4f05f0[_0x28adaa('0xcd')](_0xd4d5ed[_0x28adaa('0x4f')]['ids'],{'through':_['omit'](_0xd4d5ed[_0x28adaa('0x4f')],[_0x28adaa('0x8d'),'id'])});})[_0x3513ad('0x33')](respondWithResult(_0x327fba,null))['catch'](handleError(_0x327fba,null));},exports[_0x2e2b8c('0xc7')]=function(_0x1b4600,_0x268d3c){const _0x42aaea=_0x2e2b8c;let _0x29d59d={'raw':![],'where':{}};const _0x522797={},_0x1d9912={'count':0x0,'rows':[]};return db['ChatWebsite'][_0x42aaea('0x110')]({'where':{'id':_0x1b4600[_0x42aaea('0x62')]['id']}})[_0x42aaea('0x33')](handleEntityNotFound(_0x268d3c,null))['then'](function(_0x3f5719){const _0x3556f1=_0x42aaea;if(_0x3f5719)return _0x522797[_0x3556f1('0x7b')]=_[_0x3556f1('0xcb')](db['ChatInteraction']['rawAttributes']),_0x522797[_0x3556f1('0x98')]=_[_0x3556f1('0xcb')](_0x1b4600[_0x3556f1('0x98')]),_0x522797[_0x3556f1('0xe7')]=_[_0x3556f1('0x5f')](_0x522797['model'],_0x522797[_0x3556f1('0x98')]),_0x29d59d[_0x3556f1('0x55')]=_['intersection'](_0x522797[_0x3556f1('0x7b')],qs[_0x3556f1('0xc')](_0x1b4600[_0x3556f1('0x98')][_0x3556f1('0xc')])),_0x29d59d[_0x3556f1('0x55')]=_0x29d59d[_0x3556f1('0x55')]['length']?_0x29d59d[_0x3556f1('0x55')]:_0x522797[_0x3556f1('0x7b')],typeof _0x1b4600[_0x3556f1('0x98')]['nolimit']==='undefined'&&(_0x29d59d['limit']=qs[_0x3556f1('0xc8')](_0x1b4600[_0x3556f1('0x98')][_0x3556f1('0xc8')]),_0x29d59d['offset']=qs[_0x3556f1('0xa6')](_0x1b4600[_0x3556f1('0x98')][_0x3556f1('0xa6')])),_0x29d59d[_0x3556f1('0x6d')]=qs['sort'](_0x1b4600['query'][_0x3556f1('0x4b')]),_0x29d59d[_0x3556f1('0x60')]=qs[_0x3556f1('0xe7')](_[_0x3556f1('0x8f')](_0x1b4600['query'],_0x522797[_0x3556f1('0xe7')])),_0x29d59d[_0x3556f1('0x60')][_0x3556f1('0x67')]=_0x3f5719['id'],_0x1b4600[_0x3556f1('0x98')][_0x3556f1('0x56')]&&(_0x29d59d[_0x3556f1('0x60')]=_[_0x3556f1('0xc9')](_0x29d59d[_0x3556f1('0x60')],{[Op['or']]:_[_0x3556f1('0xf4')](_0x29d59d[_0x3556f1('0x55')],function(_0x153280){const _0x3a0553=_0x3556f1,_0x3d130f={};return _0x3d130f[_0x153280]={[Op['like']]:'%'+_0x1b4600[_0x3a0553('0x98')]['filter']+'%'},_0x3d130f;})})),_0x29d59d=_[_0x3556f1('0xc9')]({},_0x29d59d,_0x1b4600[_0x3556f1('0x39')]),db[_0x3556f1('0xc0')][_0x3556f1('0xad')]({'where':_0x29d59d[_0x3556f1('0x60')]})[_0x3556f1('0x33')](function(_0x4d173b){const _0x360f1b=_0x3556f1;return _0x1d9912[_0x360f1b('0xad')]=_0x4d173b,_0x1b4600['query']['includeAll']&&(_0x29d59d[_0x360f1b('0x92')]=[{'model':db['CmContact'],'as':_0x360f1b('0x4'),'required':![]},{'model':db[_0x360f1b('0xa7')],'as':'Owner','attributes':[_0x360f1b('0x34'),_0x360f1b('0x107'),_0x360f1b('0x18')],'required':![]},{'model':db[_0x360f1b('0x48')],'as':'Tags','attributes':['id',_0x360f1b('0x34'),'color'],'where':_0x1b4600[_0x360f1b('0x98')]['tag']?{'id':_0x1b4600[_0x360f1b('0x98')]['tag']}:undefined,'required':_0x1b4600['query'][_0x360f1b('0x1b')]?!![]:![]}]),db[_0x360f1b('0xc0')][_0x360f1b('0x93')](_0x29d59d);})[_0x3556f1('0x33')](function(_0x352ff3){const _0x5b7d99=_0x3556f1;return _0x1d9912[_0x5b7d99('0xb3')]=_0x352ff3,_0x1d9912;});})[_0x42aaea('0x33')](respondWithFilteredResult(_0x268d3c,_0x29d59d))[_0x42aaea('0x102')](handleError(_0x268d3c,null));};function iftimePromise(_0x136322,_0x1ed299){const _0x120976=_0x2e2b8c;return respondWithRpcPromise(_0x120976('0x65'),_0x120976('0x7a'),{'command':_0x1ed299[_0x120976('0x6')]?util[_0x120976('0xd0')](_0x120976('0x0'),_0x136322[_0x120976('0x57')],_0x1ed299[_0x120976('0x6')]):util[_0x120976('0xd0')](_0x120976('0x40'),_0x136322['interval'])},client9002)[_0x120976('0x33')](function(_0x6a8185){const _0x2acd87=_0x120976,_0xa4ffc3=_0x6a8185&&_0x6a8185[_0x2acd87('0x10f')](_0x2acd87('0x76'))>=0x0?!![]:![];return logger[_0x2acd87('0x1f')](_0x2acd87('0xe4'),_0x1ed299['id'],_0x136322['id'],_0x136322['interval'],_0xa4ffc3?_0x2acd87('0xd'):_0x2acd87('0x2e'),_0x1ed299['timezone']?_0x1ed299['timezone']:_0x2acd87('0x79')),_0xa4ffc3;})['catch'](function(_0x27e24d){const _0x1b94b9=_0x120976;return logger[_0x1b94b9('0xc2')](_0x1b94b9('0xe4'),_0x1ed299['id'],_0x136322['id'],_0x136322[_0x1b94b9('0x57')],util[_0x1b94b9('0xda')](_0x27e24d,{'showHidden':![],'depth':null}),_0x1ed299['timezone']?_0x1ed299['timezone']:_0x1b94b9('0x79')),![];});}exports[_0x2e2b8c('0x7a')]=function(_0x180ebf,_0x4bb831){const _0x923280=_0x2e2b8c;let _0x130cb4=0x0,_0xd0077e=0x0,_0x94ccd5=![],_0x3f5cdf,_0x26231b;return db['ChatWebsite']['findOne']({'where':{'id':_0x180ebf[_0x923280('0x62')]['id']},'include':[{'model':db[_0x923280('0x8e')],'as':_0x923280('0x8e'),'include':[{'model':db[_0x923280('0x8e')],'as':_0x923280('0xb6'),'attributes':['id',_0x923280('0x57')],'raw':!![]}]}]})[_0x923280('0x33')](handleEntityNotFound(_0x4bb831,null))[_0x923280('0x33')](function(_0x50e7d5){const _0x37c69f=_0x923280;if(_0x50e7d5)return _0x3f5cdf=_0x50e7d5,_0x50e7d5[_0x37c69f('0x99')]({'raw':!![]});})['then'](function(_0x8096fd){const _0x4cc8a4=_0x923280;return _0x3f5cdf&&(_0x8096fd&&(_0x26231b=_0x8096fd)),require(_0x4cc8a4('0xfa'))['getLicense']();})[_0x923280('0x33')](function(_0x18e6df){const _0x17d3a5=_0x923280;_0x18e6df&&(_0xd0077e=_0x18e6df[_0x17d3a5('0x109')],_0x94ccd5=_0x18e6df[_0x17d3a5('0x105')]);})[_0x923280('0x33')](function(){const _0x355aaf=_0x923280;return db[_0x355aaf('0xc0')][_0x355aaf('0xad')]({'where':{'closed':![]}});})['then'](function(_0x5d93f7){const _0x4eb385=_0x923280;_0x130cb4=_0x5d93f7;if(_0xd0077e&&_0x5d93f7>_0xd0077e)return db[_0x4eb385('0x10e')][_0x4eb385('0x110')]({'where':{'id':0x1}})[_0x4eb385('0x33')](function(_0x172eef){const _0x3ec745=_0x4eb385;_0x172eef&&_0x172eef['increment'](_0x3ec745('0xb7'));});})['then'](function(){const _0x11b680=_0x923280;if(_0x3f5cdf[_0x11b680('0x8e')]&&_0x3f5cdf[_0x11b680('0x8e')][_0x11b680('0xb6')]){const _0x46aef1=[];for(let _0x193f0a=0x0;_0x193f0a<_0x3f5cdf[_0x11b680('0x8e')]['Intervals'][_0x11b680('0xd2')];_0x193f0a++){const _0x55cfae=_0x3f5cdf[_0x11b680('0x8e')][_0x11b680('0xb6')][_0x193f0a][_0x11b680('0xd5')]({'plain':!![]});_0x46aef1[_0x11b680('0x41')](iftimePromise(_0x55cfae,_0x3f5cdf));}return Promise[_0x11b680('0xdd')](_0x46aef1)[_0x11b680('0x33')](function(_0x2e8658){return _['some'](_0x2e8658);});}else return!![];})[_0x923280('0x33')](function(_0x51582e){const _0x25ff29=_0x923280,_0x1092ae=_0x180ebf[_0x25ff29('0xc6')][_0x25ff29('0xd5')](_0x25ff29('0x4a')),_0x5f165f=fs[_0x25ff29('0x4e')](path[_0x25ff29('0x68')](config[_0x25ff29('0x5c')],_0x25ff29('0x7e')),_0x25ff29('0x3a')),_0x34f26c={'chatVersion':_0x1092ae,'remote':_0x3f5cdf[_0x25ff29('0xf2')],'query':querystring['stringify'](_[_0x25ff29('0xc9')](_0x3f5cdf[_0x25ff29('0xd5')]({'plain':!![]}),{'customerIp':_0x180ebf[_0x25ff29('0xd9')][_0x25ff29('0xbc')]||_0x180ebf['headers'][_0x25ff29('0xb4')]||_0x180ebf[_0x25ff29('0xde')][_0x25ff29('0xed')]||_0x180ebf['ip'],'referer':_0x180ebf['headers'][_0x25ff29('0xd1')],'openedInteractions':_0x130cb4,'maxInteractions':_0xd0077e,'virtual':_0x94ccd5[_0x25ff29('0x109')],'online':_0x51582e,'custom':_0x94ccd5}))[_0x25ff29('0xe6')](/'/g,'\x5c\x27')};_0x4bb831['send'](ejs[_0x25ff29('0x59')](Mustache['render'](_0x5f165f,_0x34f26c),{'proactiveActions':_0x26231b,'alignment':_0x3f5cdf[_0x25ff29('0x52')],'verticalAlignment':_0x3f5cdf[_0x25ff29('0x64')],'div_color':_0x3f5cdf[_0x25ff29('0xe')],'text_color':_0x3f5cdf[_0x25ff29('0x23')]}));})[_0x923280('0x102')](handleError(_0x4bb831,null));},exports[_0x2e2b8c('0xfd')]=function(_0x51d009,_0x38b8e0){const _0x4ca044=_0x2e2b8c;return db[_0x4ca044('0x46')][_0x4ca044('0x110')]({'where':{'id':_0x51d009[_0x4ca044('0x62')]['id']}})[_0x4ca044('0x33')](handleEntityNotFound(_0x38b8e0,null))[_0x4ca044('0x33')](function(_0x37f640){const _0x52dee6=_0x4ca044;if(_0x37f640)return db['sequelize'][_0x52dee6('0x31')](function(_0x412bed){const _0x3a16a3=_0x52dee6;return db[_0x3a16a3('0xf0')][_0x3a16a3('0xd4')]({'where':{'ChatWebsiteId':_0x51d009[_0x3a16a3('0x62')]['id']},'transaction':_0x412bed})[_0x3a16a3('0x33')](function(){const _0x3abbc8=_0x3a16a3,_0x173a5b=_[_0x3abbc8('0xf4')](_0x51d009['body'],function(_0xad307){const _0x43cafc=_0x3abbc8;return _0xad307[_0x43cafc('0x67')]=_0x51d009[_0x43cafc('0x62')]['id'],_0xad307;});return db['ChatApplication'][_0x3abbc8('0x14')](_0x173a5b,{'transaction':_0x412bed});});})['then'](function(){const _0x2d8a6f=_0x52dee6;return db['ChatApplication'][_0x2d8a6f('0x47')]({'where':{'ChatWebsiteId':_0x51d009[_0x2d8a6f('0x62')]['id']},'order':_0x2d8a6f('0xa1')});});})[_0x4ca044('0x33')](respondWithResult(_0x38b8e0,null))['catch'](handleError(_0x38b8e0,null));},exports['getApplications']=function(_0x597f11,_0x22f567){const _0x2d7f4b=_0x2e2b8c;let _0x25e19f={};const _0x4d3bae={};let _0x5427e0,_0x12da3c;return db[_0x2d7f4b('0x46')][_0x2d7f4b('0x110')]({'where':{'id':_0x597f11['params']['id']}})[_0x2d7f4b('0x33')](handleEntityNotFound(_0x22f567,null))[_0x2d7f4b('0x33')](function(_0x50dff0){const _0x2eddda=_0x2d7f4b;if(_0x50dff0)return _0x5427e0=_0x50dff0,_0x4d3bae[_0x2eddda('0x7b')]=_[_0x2eddda('0xcb')](db[_0x2eddda('0xf0')][_0x2eddda('0xc3')]),_0x4d3bae[_0x2eddda('0x98')]=_[_0x2eddda('0xcb')](_0x597f11['query']),_0x4d3bae[_0x2eddda('0xe7')]=_[_0x2eddda('0x5f')](_0x4d3bae['model'],_0x4d3bae[_0x2eddda('0x98')]),_0x25e19f['attributes']=_[_0x2eddda('0x5f')](_0x4d3bae[_0x2eddda('0x7b')],qs[_0x2eddda('0xc')](_0x597f11[_0x2eddda('0x98')][_0x2eddda('0xc')])),_0x25e19f[_0x2eddda('0x55')]=_0x25e19f[_0x2eddda('0x55')]['length']?_0x25e19f[_0x2eddda('0x55')]:_0x4d3bae[_0x2eddda('0x7b')],_0x25e19f['order']=qs[_0x2eddda('0x4b')](_0x597f11['query'][_0x2eddda('0x4b')]),_0x25e19f[_0x2eddda('0x60')]=qs[_0x2eddda('0xe7')](_[_0x2eddda('0x8f')](_0x597f11[_0x2eddda('0x98')],_0x4d3bae[_0x2eddda('0xe7')])),_0x597f11['query'][_0x2eddda('0x56')]&&(_0x25e19f[_0x2eddda('0x60')]=_['merge'](_0x25e19f[_0x2eddda('0x60')],{[Op['or']]:_[_0x2eddda('0xf4')](_0x25e19f[_0x2eddda('0x55')],function(_0x9f5713){const _0x48d607=_0x2eddda,_0x36ab90={};return _0x36ab90[_0x9f5713]={[Op[_0x48d607('0x10b')]]:'%'+_0x597f11[_0x48d607('0x98')][_0x48d607('0x56')]+'%'},_0x36ab90;})})),_0x25e19f=_[_0x2eddda('0xc9')]({},_0x25e19f,_0x597f11[_0x2eddda('0x39')]),_0x5427e0[_0x2eddda('0x9')](_0x25e19f);})[_0x2d7f4b('0x33')](function(_0x5ef2b6){const _0x37c636=_0x2d7f4b;if(_0x5ef2b6)return _0x12da3c=_0x5ef2b6[_0x37c636('0xd2')],typeof _0x597f11[_0x37c636('0x98')][_0x37c636('0xf8')]===_0x37c636('0xca')&&(_0x25e19f[_0x37c636('0xc8')]=qs[_0x37c636('0xc8')](_0x597f11[_0x37c636('0x98')]['limit']),_0x25e19f[_0x37c636('0xa6')]=qs['offset'](_0x597f11[_0x37c636('0x98')]['offset'])),_0x5427e0[_0x37c636('0x9')](_0x25e19f);})[_0x2d7f4b('0x33')](function(_0x283a01){if(_0x283a01)return _0x283a01?{'count':_0x12da3c,'rows':_0x283a01}:null;})[_0x2d7f4b('0x33')](respondWithResult(_0x22f567,null))['catch'](handleError(_0x22f567,null));},exports[_0x2e2b8c('0x104')]=function(_0x3433f4,_0x3a2085){const _0x5c124d=_0x2e2b8c;return db[_0x5c124d('0xcc')][_0x5c124d('0x110')]({'where':{'id':_0x3433f4[_0x5c124d('0x62')]['id']}})[_0x5c124d('0x33')](function(_0x54d4bb){const _0x5cd877=_0x5c124d;if(_0x54d4bb)return _0x54d4bb[_0x5cd877('0x104')](_0x3433f4['body']['ids'],{'through':_[_0x5cd877('0x37')](_0x3433f4[_0x5cd877('0x4f')],[_0x5cd877('0x8d'),'id'])});})[_0x5c124d('0x33')](respondWithResult(_0x3a2085,null))[_0x5c124d('0x102')](handleError(_0x3a2085,null));},exports[_0x2e2b8c('0x99')]=function(_0x504818,_0x350312){const _0x3f3f33=_0x2e2b8c;let _0x4fb85b={};const _0x175960={};let _0x18940e,_0x19adeb;return db[_0x3f3f33('0x46')][_0x3f3f33('0x110')]({'where':{'id':_0x504818[_0x3f3f33('0x62')]['id']}})['then'](handleEntityNotFound(_0x350312,null))[_0x3f3f33('0x33')](function(_0x440b2d){const _0x11226f=_0x3f3f33;if(_0x440b2d)return _0x18940e=_0x440b2d,_0x175960[_0x11226f('0x7b')]=_[_0x11226f('0xcb')](db[_0x11226f('0x49')][_0x11226f('0xc3')]),_0x175960['query']=_['keys'](_0x504818['query']),_0x175960[_0x11226f('0xe7')]=_[_0x11226f('0x5f')](_0x175960[_0x11226f('0x7b')],_0x175960[_0x11226f('0x98')]),_0x4fb85b['attributes']=_[_0x11226f('0x5f')](_0x175960[_0x11226f('0x7b')],qs[_0x11226f('0xc')](_0x504818['query'][_0x11226f('0xc')])),_0x4fb85b[_0x11226f('0x55')]=_0x4fb85b['attributes']['length']?_0x4fb85b[_0x11226f('0x55')]:_0x175960[_0x11226f('0x7b')],_0x4fb85b[_0x11226f('0x6d')]=qs[_0x11226f('0x4b')](_0x504818[_0x11226f('0x98')][_0x11226f('0x4b')]),_0x4fb85b['where']=qs[_0x11226f('0xe7')](_[_0x11226f('0x8f')](_0x504818[_0x11226f('0x98')],_0x175960[_0x11226f('0xe7')])),_0x504818['query'][_0x11226f('0x56')]&&(_0x4fb85b[_0x11226f('0x60')]=_['merge'](_0x4fb85b[_0x11226f('0x60')],{[Op['or']]:_[_0x11226f('0xf4')](_0x4fb85b[_0x11226f('0x55')],function(_0x5aad7d){const _0x551428=_0x11226f,_0x3e90d8={};return _0x3e90d8[_0x5aad7d]={[Op['like']]:'%'+_0x504818[_0x551428('0x98')][_0x551428('0x56')]+'%'},_0x3e90d8;})})),_0x4fb85b=_[_0x11226f('0xc9')]({},_0x4fb85b,_0x504818[_0x11226f('0x39')]),_0x18940e[_0x11226f('0x99')](_0x4fb85b);})[_0x3f3f33('0x33')](function(_0x7bc695){const _0x660a3=_0x3f3f33;if(_0x7bc695)return _0x19adeb=_0x7bc695[_0x660a3('0xd2')],typeof _0x504818['query']['nolimit']==='undefined'&&(_0x4fb85b['limit']=qs[_0x660a3('0xc8')](_0x504818['query'][_0x660a3('0xc8')]),_0x4fb85b[_0x660a3('0xa6')]=qs['offset'](_0x504818['query']['offset'])),_0x18940e['getProactiveActions'](_0x4fb85b);})[_0x3f3f33('0x33')](function(_0x49808c){if(_0x49808c)return _0x49808c?{'count':_0x19adeb,'rows':_0x49808c}:null;})[_0x3f3f33('0x33')](respondWithResult(_0x350312,null))[_0x3f3f33('0x102')](handleError(_0x350312,null));},exports[_0x2e2b8c('0x8c')]=function(_0x56d9eb,_0x3cff2c){const _0x3fa50d=_0x2e2b8c,_0x5bd0cd=_0x56d9eb['query'][_0x3fa50d('0x58')]===_0x3fa50d('0x82')?'offlineForm':_0x3fa50d('0xbd');return db['ChatWebsite'][_0x3fa50d('0x110')]({'attributes':['id',_0x5bd0cd],'where':{'id':_0x56d9eb[_0x3fa50d('0x62')]['id']}})[_0x3fa50d('0x33')](handleEntityNotFound(_0x3cff2c,null))[_0x3fa50d('0x33')](function(_0x3a25d1){const _0x1ffcc8=_0x3fa50d;if(_0x3a25d1){const _0x3fc589=_0x3a25d1[_0x5bd0cd],_0x98104=_0x3fc589&&_0x3fc589[_0x1ffcc8('0xeb')]?_0x3fc589[_0x1ffcc8('0xeb')]:[];_0x3cff2c[_0x1ffcc8('0x53')]({'fromKey':_[_0x1ffcc8('0x38')](_0x3fc589[_0x1ffcc8('0xb0')])?undefined:_0x3fc589[_0x1ffcc8('0xb0')],'count':_0x98104[_0x1ffcc8('0xd2')],'rows':_0x98104});}})['catch'](handleError(_0x3cff2c,null));},exports[_0x2e2b8c('0xd3')]=function(_0x571e50,_0x2e451f){const _0x4a2639=_0x2e2b8c;let _0x46e980={'raw':![],'where':{}};const _0x5c68f2={},_0x423461={'count':0x0,'rows':[]};return db[_0x4a2639('0x46')][_0x4a2639('0x110')]({'where':{'id':_0x571e50[_0x4a2639('0x62')]['id']}})[_0x4a2639('0x33')](handleEntityNotFound(_0x2e451f,null))[_0x4a2639('0x33')](function(_0x33f593){const _0x2a9d1e=_0x4a2639;if(_0x33f593)return _0x5c68f2['model']=_[_0x2a9d1e('0xcb')](db['ChatOfflineMessage'][_0x2a9d1e('0xc3')]),_0x5c68f2[_0x2a9d1e('0x98')]=_[_0x2a9d1e('0xcb')](_0x571e50['query']),_0x5c68f2[_0x2a9d1e('0xe7')]=_['intersection'](_0x5c68f2[_0x2a9d1e('0x7b')],_0x5c68f2[_0x2a9d1e('0x98')]),_0x46e980[_0x2a9d1e('0x55')]=_[_0x2a9d1e('0x5f')](_0x5c68f2[_0x2a9d1e('0x7b')],qs['fields'](_0x571e50['query'][_0x2a9d1e('0xc')])),_0x46e980[_0x2a9d1e('0x55')]=_0x46e980[_0x2a9d1e('0x55')][_0x2a9d1e('0xd2')]?_0x46e980[_0x2a9d1e('0x55')]:_0x5c68f2['model'],typeof _0x571e50[_0x2a9d1e('0x98')]['nolimit']===_0x2a9d1e('0xca')&&(_0x46e980[_0x2a9d1e('0xc8')]=qs[_0x2a9d1e('0xc8')](_0x571e50[_0x2a9d1e('0x98')][_0x2a9d1e('0xc8')]),_0x46e980[_0x2a9d1e('0xa6')]=qs[_0x2a9d1e('0xa6')](_0x571e50[_0x2a9d1e('0x98')][_0x2a9d1e('0xa6')])),_0x46e980[_0x2a9d1e('0x6d')]=qs['sort'](_0x571e50[_0x2a9d1e('0x98')][_0x2a9d1e('0x4b')]),_0x46e980[_0x2a9d1e('0x60')]=qs[_0x2a9d1e('0xe7')](_[_0x2a9d1e('0x8f')](_0x571e50[_0x2a9d1e('0x98')],_0x5c68f2[_0x2a9d1e('0xe7')])),_0x46e980[_0x2a9d1e('0x60')][_0x2a9d1e('0x67')]=_0x33f593['id'],_0x571e50['query'][_0x2a9d1e('0x56')]&&(_0x46e980['where']=_[_0x2a9d1e('0xc9')](_0x46e980[_0x2a9d1e('0x60')],{[Op['or']]:_[_0x2a9d1e('0xf4')](_0x46e980[_0x2a9d1e('0x55')],function(_0x58d14e){const _0x1111ce={};return _0x1111ce[_0x58d14e]={[Op['like']]:'%'+_0x571e50['query']['filter']+'%'},_0x1111ce;})})),_0x46e980=_['merge']({},_0x46e980,_0x571e50[_0x2a9d1e('0x39')]),db['ChatOfflineMessage'][_0x2a9d1e('0xad')]({'where':_0x46e980[_0x2a9d1e('0x60')]})['then'](function(_0x1d2997){const _0x193e47=_0x2a9d1e;return _0x423461[_0x193e47('0xad')]=_0x1d2997,_0x571e50['query']['includeAll']?_0x46e980[_0x193e47('0x92')]=[{'all':!![]}]:_0x46e980[_0x193e47('0x92')]=[{'model':db['CmContact'],'as':_0x193e47('0x4'),'required':![]}],db[_0x193e47('0x22')][_0x193e47('0x93')](_0x46e980);})['then'](function(_0x172bdd){const _0x187aac=_0x2a9d1e;return _0x423461[_0x187aac('0xb3')]=_0x172bdd,_0x423461;});})[_0x4a2639('0x33')](respondWithFilteredResult(_0x2e451f,_0x46e980))[_0x4a2639('0x102')](handleError(_0x2e451f,null));},exports[_0x2e2b8c('0x1')]=function(_0x351bde,_0x52ef30){const _0x230faa=_0x2e2b8c;return db[_0x230faa('0x46')]['findOne']({'where':{'id':_0x351bde[_0x230faa('0x62')]['id']}})[_0x230faa('0x33')](function(_0x4fea0c){const _0x3339a9=_0x230faa;if(_0x4fea0c)return _0x4fea0c[_0x3339a9('0x1')](_0x351bde[_0x3339a9('0x4f')]['ids'],{'through':_['omit'](_0x351bde[_0x3339a9('0x4f')],['ids','id'])})[_0x3339a9('0x33')](function(_0x4f2aef){const _0x4bf6c0=_0x3339a9;for(let _0x4a9ec5=0x0;_0x4a9ec5<_0x351bde['body'][_0x4bf6c0('0x8d')][_0x4bf6c0('0xd2')];_0x4a9ec5+=0x1){socket[_0x4bf6c0('0xdf')](_0x4bf6c0('0x26'),{'UserId':_0x351bde[_0x4bf6c0('0x4f')]['ids'][_0x4a9ec5],'ChatWebsiteId':_0x351bde[_0x4bf6c0('0x62')]['id']});}return _0x4f2aef;});})[_0x230faa('0x33')](respondWithResult(_0x52ef30,null))[_0x230faa('0x102')](handleError(_0x52ef30,null));},exports['removeAgents']=function(_0x1c8b77,_0x3ddf6a){const _0x3079a7=_0x2e2b8c;return db[_0x3079a7('0x46')][_0x3079a7('0x110')]({'where':{'id':_0x1c8b77['params']['id']}})[_0x3079a7('0x33')](handleEntityNotFound(_0x3ddf6a,null))[_0x3079a7('0x33')](function(_0x460410){const _0x5e9612=_0x3079a7;if(_0x460410)return _0x460410[_0x5e9612('0x35')](_0x1c8b77[_0x5e9612('0x98')]['ids'])[_0x5e9612('0x33')](function(){const _0x2d1d65=_0x5e9612;if(_[_0x2d1d65('0x2f')](_0x1c8b77[_0x2d1d65('0x98')]['ids']))for(let _0x4866fd=0x0;_0x4866fd<_0x1c8b77[_0x2d1d65('0x98')][_0x2d1d65('0x8d')][_0x2d1d65('0xd2')];_0x4866fd+=0x1){socket[_0x2d1d65('0xdf')](_0x2d1d65('0xd7'),{'UserId':Number(_0x1c8b77[_0x2d1d65('0x98')]['ids'][_0x4866fd]),'ChatWebsiteId':Number(_0x1c8b77[_0x2d1d65('0x62')]['id'])});}else socket[_0x2d1d65('0xdf')](_0x2d1d65('0xd7'),{'UserId':Number(_0x1c8b77[_0x2d1d65('0x98')]['ids']),'ChatWebsiteId':Number(_0x1c8b77[_0x2d1d65('0x62')]['id'])});});})[_0x3079a7('0x33')](respondWithStatusCode(_0x3ddf6a,null))[_0x3079a7('0x102')](handleError(_0x3ddf6a,null));},exports[_0x2e2b8c('0xe9')]=function(_0xc01ceb,_0x171d26){const _0x2b12df=_0x2e2b8c;let _0x35c3bb={};const _0x3047b1={};let _0xcd9468,_0xc17fb6;return db[_0x2b12df('0x46')][_0x2b12df('0x110')]({'where':{'id':_0xc01ceb[_0x2b12df('0x62')]['id']}})[_0x2b12df('0x33')](handleEntityNotFound(_0x171d26,null))[_0x2b12df('0x33')](function(_0x5bd0e9){const _0x4d276b=_0x2b12df;if(_0x5bd0e9)return _0xcd9468=_0x5bd0e9,_0x3047b1[_0x4d276b('0x7b')]=_[_0x4d276b('0xcb')](db[_0x4d276b('0xa7')]['rawAttributes']),_0x3047b1[_0x4d276b('0x98')]=_[_0x4d276b('0xcb')](_0xc01ceb[_0x4d276b('0x98')]),_0x3047b1[_0x4d276b('0xe7')]=_[_0x4d276b('0x5f')](_0x3047b1['model'],_0x3047b1[_0x4d276b('0x98')]),_0x35c3bb['attributes']=_['intersection'](_0x3047b1[_0x4d276b('0x7b')],qs[_0x4d276b('0xc')](_0xc01ceb[_0x4d276b('0x98')][_0x4d276b('0xc')])),_0x35c3bb[_0x4d276b('0x55')]=_0x35c3bb['attributes'][_0x4d276b('0xd2')]?_0x35c3bb['attributes']:_0x3047b1['model'],_0x35c3bb[_0x4d276b('0x6d')]=qs[_0x4d276b('0x4b')](_0xc01ceb[_0x4d276b('0x98')]['sort']),_0x35c3bb[_0x4d276b('0x60')]=qs[_0x4d276b('0xe7')](_[_0x4d276b('0x8f')](_0xc01ceb['query'],_0x3047b1[_0x4d276b('0xe7')])),_0xc01ceb['query'][_0x4d276b('0x56')]&&(_0x35c3bb[_0x4d276b('0x60')]=_['merge'](_0x35c3bb['where'],{[Op['or']]:_[_0x4d276b('0xf4')](_0x35c3bb['attributes'],function(_0x3a0efc){const _0x3d5b1c=_0x4d276b,_0xdb6b18={};return _0xdb6b18[_0x3a0efc]={[Op[_0x3d5b1c('0x10b')]]:'%'+_0xc01ceb[_0x3d5b1c('0x98')][_0x3d5b1c('0x56')]+'%'},_0xdb6b18;})})),_0x35c3bb=_[_0x4d276b('0xc9')]({},_0x35c3bb,_0xc01ceb[_0x4d276b('0x39')]),_0xcd9468[_0x4d276b('0xe9')](_0x35c3bb);})[_0x2b12df('0x33')](function(_0x21b2e3){const _0x163374=_0x2b12df;if(_0x21b2e3)return _0xc17fb6=_0x21b2e3[_0x163374('0xd2')],typeof _0xc01ceb[_0x163374('0x98')][_0x163374('0xf8')]===_0x163374('0xca')&&(_0x35c3bb[_0x163374('0xc8')]=qs[_0x163374('0xc8')](_0xc01ceb[_0x163374('0x98')]['limit']),_0x35c3bb[_0x163374('0xa6')]=qs[_0x163374('0xa6')](_0xc01ceb[_0x163374('0x98')][_0x163374('0xa6')])),_0xcd9468['getAgents'](_0x35c3bb);})[_0x2b12df('0x33')](function(_0x5a1324){if(_0x5a1324)return _0x5a1324?{'count':_0xc17fb6,'rows':_0x5a1324}:null;})['then'](respondWithResult(_0x171d26,null))[_0x2b12df('0x102')](handleError(_0x171d26,null));}; \ No newline at end of file +const a111_0x52e4=['sendStatus','defaults','sendMail','order','virtual','list','merge','mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','push','ChatInteraction','ChatWebsites','createdAt','[%s][INTERVAL][%s]\x20%s\x20%s\x20(%s)','unshift','VIRTUAL','updatedAt','MailServerOut','%s\x20%s','UserProfileSection','send','addAvatar','mapKeyOffline\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','ejs','unknown','DESC','http','autoAssociation','download','email','../../config/logger','Contacts','result','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','Intervals','Start','mustache','ContactId','attributes','then','offline','isNil','debug','account','../../rediscache','CannedAnswer','stringify','mapKeyOffline\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20','getDispositions','offlineMessageBody','pick','server/files/images/avatars/customer_avatar.png','from\x20is\x20mandatory','server/files/images/avatars/default_avatar.png','offlineMessageSubject','chat','items','getResult','interaction','message','addSystemAvatar','../../config/license/util','device','x-forwarded-for','UserProfileResource','online','mapKeyOffline','License','Tag','OFFLINE','request','cf-connecting-ip','timezone','addInteraction','update','intersection','json','userChatWebsite:remove','create','ChatMessage','mapKey','Owner','unmanaged','UserId','connection','CmContact','register','increment','startRouting','browser','lastName','customerAvatar','messageId','nolimit','findAndCountAll','showCustomerAvatar','name','forwardOfflineAddress','sitepic','firstName','./chatWebsite.socket','verticalAlignment','ChatWebsiteId','x-real-ip','custom','app','No\x20timezone','onlineForm','includes','User','getFields','options','x-real-port','server/files/images/logos/default_logo.svg','jayson/promise','applications','secure','include','body','MailAccount','ChatWebsite,\x20%s,\x20%s,\x20%s','join','threadId','remote','waitForTheAssignedAgent','role','ChatWebsite','findOrCreate','all','\x22%s\x22\x20<%s>','where','addProactiveActions','model','body\x20is\x20mandatory\x20and\x20not\x20empty','ListId','undefined','rawAttributes','removeAgents','CompanyId','pass','ChatApplication','../../components/parsers/qs','querystring','ONLINE','fieldName','getOfflineMessages','Applications','no\x20available\x20attributes','orderBy','Pause','lodash','ChatOfflineMessage','status','emit','color','destroy','filters','../../config/environment','file','server/files/images/logos/','fields','isArray','type','key','replace','headers','show','addDisposition','transaction','server/files/images/avatars/','from','filter','like','List','includeAll','getSystemAvatar','omit','ids','fromKey','iftime\x20%s,%s','findAll','ChatProactiveAction','filename','offset','fullname','index','SendMail','version','AttachmentId','render','systemAvatar','host','catch','authentication','port','contact','params','length','chatVersion','stack','externalUrl','Disposition','api','created','getLogo','getAnswers','path','removeAnswers','ChatWebsite,\x20%s,\x20%s','EventManager','auth','tag','format','addAgents','server/files/images/avatars/system_avatar.png','client','Content-Range','keys','getAvatar','removeDispositions','addAnswer','findOne','iftime\x20%s','interval','getProactiveActions','referer','getApplications','end','false','difference','mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20','../../mysqldb','user','root','toPairs','notify','map','agentAvatar','textColor','getInteractions','agent','describe','getSnippet','Tags','sequelize','sort','Smtp','addApplications','service','get','CmList','existsSync','files/chat/iframe.js','*,*,*,*','Contact','rows','code','user-agent-parser','info','some','error','close','readFileSync','vendor','set','remoteAddress','mandatoryDispositionPause','inspect','limit','util','Interval','getAgents','query','%s\x20%s\x20%s','request\x20sent','autoclose','setUA','priority','count'];(function(_0x5d2e36,_0x52e444){const _0x50ca21=function(_0x1fa4c5){while(--_0x1fa4c5){_0x5d2e36['push'](_0x5d2e36['shift']());}};_0x50ca21(++_0x52e444);}(a111_0x52e4,0x128));const a111_0x50ca=function(_0x5d2e36,_0x52e444){_0x5d2e36=_0x5d2e36-0x0;let _0x50ca21=a111_0x52e4[_0x5d2e36];return _0x50ca21;};const _0x5a8c6e=a111_0x50ca;'use strict';const Mustache=require(_0x5a8c6e('0x11')),util=require(_0x5a8c6e('0xfa')),path=require(_0x5a8c6e('0xbb')),ejs=require(_0x5a8c6e('0x4')),fs=require('fs'),_=require(_0x5a8c6e('0x83')),querystring=require(_0x5a8c6e('0x7b')),qs=require(_0x5a8c6e('0x7a')),logger=require(_0x5a8c6e('0xb'))(_0x5a8c6e('0xb7')),config=require(_0x5a8c6e('0x8a')),db=require(_0x5a8c6e('0xd4'))['db'],{Op,ValidationError}=require('sequelize'),{getSocket}=require(_0x5a8c6e('0x19')),socket=getSocket();require(_0x5a8c6e('0x51'))[_0x5a8c6e('0x43')](socket);const jayson=require(_0x5a8c6e('0x5f')),client=jayson[_0x5a8c6e('0xc4')][_0x5a8c6e('0x7')]({'port':0x232c}),client9002=jayson['client']['http']({'port':0x232a}),client9003=jayson[_0x5a8c6e('0xc4')][_0x5a8c6e('0x7')]({'port':0x232b});function respondWithRpcPromise(_0x1fa4c5,_0x71eb09,_0x138f88,_0x554e32){return new Promise(function(_0x101712,_0x3c91da){const _0x2456fe=a111_0x50ca,_0x588665=_0x554e32||client;return _0x588665[_0x2456fe('0x33')](_0x1fa4c5,_0x138f88)[_0x2456fe('0x14')](function(_0x4bbb75){const _0x22528a=_0x2456fe;logger[_0x22528a('0xef')](_0x22528a('0xbd'),_0x71eb09,'request\x20sent'),logger[_0x22528a('0x17')](_0x22528a('0x65'),_0x71eb09,'request\x20sent',JSON[_0x22528a('0x1b')](_0x4bbb75));if(_0x4bbb75[_0x22528a('0xf1')]){if(_0x4bbb75[_0x22528a('0xf1')][_0x22528a('0xed')]===0x1f4)return logger['error'](_0x22528a('0xbd'),_0x71eb09,_0x4bbb75['error'][_0x22528a('0x28')]),_0x3c91da(_0x4bbb75[_0x22528a('0xf1')][_0x22528a('0x28')]);return logger[_0x22528a('0xf1')](_0x22528a('0xbd'),_0x71eb09,_0x4bbb75[_0x22528a('0xf1')][_0x22528a('0x28')]),_0x101712(_0x4bbb75['error'][_0x22528a('0x28')]);}else logger['info'](_0x22528a('0xbd'),_0x71eb09,_0x22528a('0xff')),_0x101712(_0x4bbb75[_0x22528a('0xd')]['message']);})['catch'](function(_0x3d2852){const _0x2ddcb0=_0x2456fe;logger[_0x2ddcb0('0xf1')]('ChatWebsite,\x20%s,\x20%s',_0x71eb09,_0x3d2852),_0x3c91da(_0x3d2852);});});}function respondWithStatusCode(_0x1091ca,_0x507117){return _0x507117=_0x507117||0xcc,function(_0x919989){const _0x55fe1c=a111_0x50ca;if(_0x919989)return _0x1091ca[_0x55fe1c('0x104')](_0x507117);return _0x1091ca[_0x55fe1c('0x85')](_0x507117)[_0x55fe1c('0xd0')]();};}function respondWithResult(_0x20bff9,_0x294a1b){return _0x294a1b=_0x294a1b||0xc8,function(_0x430a5b){const _0x149f98=a111_0x50ca;if(_0x430a5b)return _0x20bff9[_0x149f98('0x85')](_0x294a1b)['json'](_0x430a5b);};}function respondWithFilteredResult(_0x46b4a5,_0x3f50df){return function(_0x29e023){const _0x469ff3=a111_0x50ca;if(_0x29e023){const _0x3a4d66=_0x29e023[_0x469ff3('0x103')],_0x3bc346=_0x3f50df[_0x469ff3('0xa4')];let _0x4da223=_0x3f50df[_0x469ff3('0xa4')]+_0x3f50df[_0x469ff3('0xf9')],_0xf27a7;return _0x4da223>=_0x3a4d66?(_0x4da223=_0x3a4d66,_0xf27a7=0xc8):_0xf27a7=0xce,_0x46b4a5[_0x469ff3('0x85')](_0xf27a7),_0x46b4a5[_0x469ff3('0xf5')](_0x469ff3('0xc5'),_0x3bc346+'-'+_0x4da223+'/'+_0x3a4d66)[_0x469ff3('0x39')](_0x29e023);}return null;};}function saveUpdates(_0x5676ef){return function(_0xb53ea3){const _0x85643c=a111_0x50ca;if(_0xb53ea3)return _0xb53ea3[_0x85643c('0x37')](_0x5676ef)[_0x85643c('0x14')](function(_0x4ef2c7){return _0x4ef2c7;});return null;};}function removeEntity(_0x420734){return function(_0x3f27a6){const _0x2005e3=a111_0x50ca;if(_0x3f27a6)return _0x3f27a6['destroy']()['then'](function(){const _0x30d179=a111_0x50ca,_0x4cbc52=_0x3f27a6['get']({'plain':!![]}),_0x2a124b=_0x30d179('0x10e');return db[_0x30d179('0x2d')][_0x30d179('0x88')]({'where':{'type':_0x2a124b,'resourceId':_0x4cbc52['id']}})[_0x30d179('0x14')](function(){return _0x3f27a6;});})[_0x2005e3('0x14')](function(){const _0x1894d1=_0x2005e3;_0x420734[_0x1894d1('0x85')](0xcc)[_0x1894d1('0xd0')]();});};}function handleEntityNotFound(_0x4c2ea0){return function(_0x300fcc){const _0x59f3c6=a111_0x50ca;return!_0x300fcc&&_0x4c2ea0[_0x59f3c6('0x104')](0x194),_0x300fcc;};}function handleError(_0x9f47c2,_0x58c084){return _0x58c084=_0x58c084||0x1f4,function(_0x253059){const _0x17df90=a111_0x50ca;logger[_0x17df90('0xf1')](_0x253059[_0x17df90('0xb4')]),_0x253059[_0x17df90('0x4d')]&&delete _0x253059[_0x17df90('0x4d')],_0x9f47c2[_0x17df90('0x85')](_0x58c084)[_0x17df90('0x1')](_0x253059);};}exports[_0x5a8c6e('0xa6')]=function(_0x305c1f,_0x2a3d96){const _0x22620a=_0x5a8c6e;let _0x448f4b={'include':[{'model':db['Pause'],'as':_0x22620a('0xf7')}]};const _0x401158={},_0x22f4b6={'count':0x0,'rows':[]},_0x37c910=_[_0x22620a('0xd9')](db[_0x22620a('0x6b')][_0x22620a('0x75')],function(_0x255aec){const _0x25b5a3=_0x22620a;return{'name':_0x255aec[_0x25b5a3('0x7d')],'type':_0x255aec[_0x25b5a3('0x8f')][_0x25b5a3('0x90')]};});_0x401158['model']=_['map'](_0x37c910,_0x22620a('0x4d')),_0x401158['query']=_[_0x22620a('0xc6')](_0x305c1f[_0x22620a('0xfd')]),_0x401158[_0x22620a('0x89')]=_['intersection'](_0x401158[_0x22620a('0x71')],_0x401158[_0x22620a('0xfd')]),_0x448f4b[_0x22620a('0x13')]=_[_0x22620a('0x38')](_0x401158[_0x22620a('0x71')],qs[_0x22620a('0x8d')](_0x305c1f[_0x22620a('0xfd')][_0x22620a('0x8d')])),_0x448f4b[_0x22620a('0x13')]=_0x448f4b[_0x22620a('0x13')][_0x22620a('0xb2')]?_0x448f4b[_0x22620a('0x13')]:_0x401158['model'];typeof _0x305c1f['query'][_0x22620a('0x4a')]==='undefined'&&(_0x448f4b[_0x22620a('0xf9')]=qs[_0x22620a('0xf9')](_0x305c1f[_0x22620a('0xfd')]['limit']),_0x448f4b[_0x22620a('0xa4')]=qs[_0x22620a('0xa4')](_0x305c1f['query'][_0x22620a('0xa4')]));_0x448f4b[_0x22620a('0x107')]=qs[_0x22620a('0xe2')](_0x305c1f['query'][_0x22620a('0xe2')]),_0x448f4b[_0x22620a('0x6f')]=qs[_0x22620a('0x89')](_[_0x22620a('0x1f')](_0x305c1f[_0x22620a('0xfd')],_0x401158[_0x22620a('0x89')]),_0x37c910);_0x305c1f[_0x22620a('0xfd')][_0x22620a('0x98')]&&(_0x448f4b[_0x22620a('0x6f')]=_['merge'](_0x448f4b['where'],{[Op['or']]:_[_0x22620a('0xd9')](_0x37c910,function(_0x315e9a){const _0x2d4317=_0x22620a;if(_0x315e9a['type']!==_0x2d4317('0x112')){const _0x5c6474={};return _0x5c6474[_0x315e9a['name']]={[Op[_0x2d4317('0x99')]]:'%'+_0x305c1f['query']['filter']+'%'},_0x5c6474;}})}));_0x448f4b=_['merge']({},_0x448f4b,_0x305c1f['options']);const _0x59baf7={'where':_0x448f4b[_0x22620a('0x6f')]};return db['ChatWebsite'][_0x22620a('0x103')](_0x59baf7)[_0x22620a('0x14')](function(_0x23b261){const _0x427a67=_0x22620a;return _0x22f4b6[_0x427a67('0x103')]=_0x23b261,_0x305c1f[_0x427a67('0xfd')][_0x427a67('0x9b')]&&(_0x448f4b[_0x427a67('0x62')]=[{'all':!![]}]),db[_0x427a67('0x6b')]['findAll'](_0x448f4b);})['then'](function(_0x6cc2cd){return _0x22f4b6['rows']=_0x6cc2cd,_0x22f4b6;})['then'](respondWithFilteredResult(_0x2a3d96,_0x448f4b))['catch'](handleError(_0x2a3d96,null));},exports[_0x5a8c6e('0x93')]=function(_0x1717c5,_0x5898bf){const _0xb3ff6d=_0x5a8c6e;let _0x517f96={'raw':![],'where':{'id':_0x1717c5['params']['id']},'include':[{'model':db[_0xb3ff6d('0x82')],'as':'mandatoryDispositionPause'}]};const _0x4c2c1b={};return _0x4c2c1b[_0xb3ff6d('0x71')]=_[_0xb3ff6d('0xc6')](db[_0xb3ff6d('0x6b')][_0xb3ff6d('0x75')]),_0x4c2c1b[_0xb3ff6d('0xfd')]=_[_0xb3ff6d('0xc6')](_0x1717c5[_0xb3ff6d('0xfd')]),_0x4c2c1b[_0xb3ff6d('0x89')]=_[_0xb3ff6d('0x38')](_0x4c2c1b[_0xb3ff6d('0x71')],_0x4c2c1b[_0xb3ff6d('0xfd')]),_0x517f96['attributes']=_[_0xb3ff6d('0x38')](_0x4c2c1b[_0xb3ff6d('0x71')],qs[_0xb3ff6d('0x8d')](_0x1717c5[_0xb3ff6d('0xfd')][_0xb3ff6d('0x8d')])),_0x517f96[_0xb3ff6d('0x13')]=_0x517f96[_0xb3ff6d('0x13')][_0xb3ff6d('0xb2')]?_0x517f96['attributes']:_0x4c2c1b[_0xb3ff6d('0x71')],_0x1717c5[_0xb3ff6d('0xfd')]['includeAll']&&(_0x517f96[_0xb3ff6d('0x62')]=[{'all':!![]}]),_0x517f96=_[_0xb3ff6d('0x10a')]({},_0x517f96,_0x1717c5['options']),db[_0xb3ff6d('0x6b')]['findOne'](_0x517f96)[_0xb3ff6d('0x14')](handleEntityNotFound(_0x5898bf,null))[_0xb3ff6d('0x14')](respondWithResult(_0x5898bf,null))[_0xb3ff6d('0xad')](handleError(_0x5898bf,null));},exports[_0x5a8c6e('0x3b')]=function(_0x583760,_0x35c36e){const _0x2f4d1f=_0x5a8c6e;return db[_0x2f4d1f('0x6b')][_0x2f4d1f('0x3b')](_0x583760[_0x2f4d1f('0x63')],{})[_0x2f4d1f('0x14')](function(_0x4630f1){const _0x211b0f=_0x2f4d1f,_0x2b0c42=_0x583760[_0x211b0f('0xd5')][_0x211b0f('0xe6')]({'plain':!![]});if(!_0x2b0c42)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x2b0c42[_0x211b0f('0x6a')]===_0x211b0f('0xd5')){const _0x152888=_0x4630f1[_0x211b0f('0xe6')]({'plain':!![]}),_0x3d6d1e=_0x211b0f('0x10e');return db[_0x211b0f('0x0')][_0x211b0f('0xca')]({'where':{'name':_0x3d6d1e,'userProfileId':_0x2b0c42['userProfileId']},'raw':!![]})['then'](function(_0x103062){const _0x2de2b7=_0x211b0f;return _0x103062&&_0x103062[_0x2de2b7('0x8')]===0x0?db['UserProfileResource']['create']({'name':_0x152888['name'],'resourceId':_0x152888['id'],'type':_0x103062['name'],'sectionId':_0x103062['id']},{})[_0x2de2b7('0x14')](function(){return _0x4630f1;}):_0x4630f1;})['catch'](function(_0x355a5a){const _0x571159=_0x211b0f;logger['error'](_0x571159('0xe'),_0x355a5a);throw _0x355a5a;});}return _0x4630f1;})['then'](respondWithResult(_0x35c36e,0xc9))[_0x2f4d1f('0xad')](handleError(_0x35c36e,null));},exports[_0x5a8c6e('0x37')]=function(_0x4d5ff0,_0x549322){const _0x3202eb=_0x5a8c6e;return _0x4d5ff0[_0x3202eb('0x63')]['id']&&delete _0x4d5ff0[_0x3202eb('0x63')]['id'],db['ChatWebsite'][_0x3202eb('0xca')]({'where':{'id':_0x4d5ff0[_0x3202eb('0xb1')]['id']},'include':[{'model':db[_0x3202eb('0x82')],'as':_0x3202eb('0xf7')}]})[_0x3202eb('0x14')](handleEntityNotFound(_0x549322,null))['then'](saveUpdates(_0x4d5ff0[_0x3202eb('0x63')],null))[_0x3202eb('0x14')](respondWithResult(_0x549322,null))[_0x3202eb('0xad')](handleError(_0x549322,null));},exports[_0x5a8c6e('0x88')]=function(_0x14271a,_0x28f934){const _0x157743=_0x5a8c6e;return db['ChatWebsite'][_0x157743('0xca')]({'where':{'id':_0x14271a[_0x157743('0xb1')]['id']}})[_0x157743('0x14')](handleEntityNotFound(_0x28f934,null))['then'](removeEntity(_0x28f934,null))['catch'](handleError(_0x28f934,null));},exports[_0x5a8c6e('0xde')]=function(_0xecca21,_0x557e58){const _0x34a4ac=_0x5a8c6e;return db['ChatWebsite']['describe']()[_0x34a4ac('0x14')](respondWithResult(_0x557e58,null))[_0x34a4ac('0xad')](handleError(_0x557e58,null));},exports[_0x5a8c6e('0x94')]=function(_0x4543c2,_0x40e529){const _0x1f9f48=_0x5a8c6e;return _0x4543c2[_0x1f9f48('0x63')]['id']&&delete _0x4543c2[_0x1f9f48('0x63')]['id'],db[_0x1f9f48('0x6b')]['findOne']({'where':{'id':_0x4543c2[_0x1f9f48('0xb1')]['id']}})[_0x1f9f48('0x14')](handleEntityNotFound(_0x40e529,null))[_0x1f9f48('0x14')](function(_0x1fae72){const _0x1b642b=_0x1f9f48;if(_0x1fae72)return _0x4543c2['body'][_0x1b642b('0x53')]=_0x1fae72['id'],db[_0x1b642b('0xb6')][_0x1b642b('0x3b')](_0x4543c2['body']);})[_0x1f9f48('0x14')](respondWithResult(_0x40e529,null))['catch'](handleError(_0x40e529,null));},exports[_0x5a8c6e('0x1d')]=function(_0x18079b,_0x119ef8){const _0x5d6cc2=_0x5a8c6e;let _0x3a5026={'raw':![],'where':{}};const _0x598c1c={},_0x39488e={'count':0x0,'rows':[]};return db[_0x5d6cc2('0x6b')][_0x5d6cc2('0xca')]({'where':{'id':_0x18079b['params']['id']}})[_0x5d6cc2('0x14')](handleEntityNotFound(_0x119ef8,null))[_0x5d6cc2('0x14')](function(_0x36b2d9){const _0x4e0441=_0x5d6cc2;if(_0x36b2d9)return _0x598c1c[_0x4e0441('0x71')]=_[_0x4e0441('0xc6')](db[_0x4e0441('0xb6')][_0x4e0441('0x75')]),_0x598c1c[_0x4e0441('0xfd')]=_[_0x4e0441('0xc6')](_0x18079b[_0x4e0441('0xfd')]),_0x598c1c[_0x4e0441('0x89')]=_[_0x4e0441('0x38')](_0x598c1c['model'],_0x598c1c[_0x4e0441('0xfd')]),_0x3a5026[_0x4e0441('0x13')]=_[_0x4e0441('0x38')](_0x598c1c[_0x4e0441('0x71')],qs[_0x4e0441('0x8d')](_0x18079b[_0x4e0441('0xfd')][_0x4e0441('0x8d')])),_0x3a5026[_0x4e0441('0x13')]=_0x3a5026[_0x4e0441('0x13')][_0x4e0441('0xb2')]?_0x3a5026['attributes']:_0x598c1c[_0x4e0441('0x71')],typeof _0x18079b[_0x4e0441('0xfd')]['nolimit']===_0x4e0441('0x74')&&(_0x3a5026['limit']=qs[_0x4e0441('0xf9')](_0x18079b[_0x4e0441('0xfd')][_0x4e0441('0xf9')]),_0x3a5026[_0x4e0441('0xa4')]=qs[_0x4e0441('0xa4')](_0x18079b[_0x4e0441('0xfd')][_0x4e0441('0xa4')])),_0x3a5026['order']=qs[_0x4e0441('0xe2')](_0x18079b[_0x4e0441('0xfd')]['sort']),_0x3a5026[_0x4e0441('0x6f')]=qs[_0x4e0441('0x89')](_['pick'](_0x18079b[_0x4e0441('0xfd')],_0x598c1c['filters'])),_0x3a5026[_0x4e0441('0x6f')]['ChatWebsiteId']=_0x36b2d9['id'],_0x18079b[_0x4e0441('0xfd')]['filter']&&(_0x3a5026[_0x4e0441('0x6f')]=_['merge'](_0x3a5026[_0x4e0441('0x6f')],{[Op['or']]:_['map'](_0x3a5026[_0x4e0441('0x13')],function(_0x2efef7){const _0x39aff8=_0x4e0441,_0x2ca34e={};return _0x2ca34e[_0x2efef7]={[Op[_0x39aff8('0x99')]]:'%'+_0x18079b[_0x39aff8('0xfd')][_0x39aff8('0x98')]+'%'},_0x2ca34e;})})),_0x3a5026=_['merge']({},_0x3a5026,_0x18079b[_0x4e0441('0x5c')]),db[_0x4e0441('0xb6')][_0x4e0441('0x103')]({'where':_0x3a5026[_0x4e0441('0x6f')]})[_0x4e0441('0x14')](function(_0x28d25c){const _0x5c3162=_0x4e0441;return _0x39488e[_0x5c3162('0x103')]=_0x28d25c,_0x18079b['query']['includeAll']&&(_0x3a5026[_0x5c3162('0x62')]=[{'all':!![]}]),db[_0x5c3162('0xb6')][_0x5c3162('0xa1')](_0x3a5026);})['then'](function(_0x21c7a5){const _0x445b9d=_0x4e0441;return _0x39488e[_0x445b9d('0xec')]=_0x21c7a5,_0x39488e;});})['then'](respondWithFilteredResult(_0x119ef8,_0x3a5026))[_0x5d6cc2('0xad')](handleError(_0x119ef8,null));},exports[_0x5a8c6e('0xc8')]=function(_0x41ed15,_0x5cacac){const _0x4063fa=_0x5a8c6e;return db[_0x4063fa('0x6b')]['findOne']({'where':{'id':_0x41ed15['params']['id']}})[_0x4063fa('0x14')](handleEntityNotFound(_0x5cacac,null))[_0x4063fa('0x14')](function(_0x2814ca){const _0x2a627a=_0x4063fa;if(_0x2814ca)return _0x2814ca[_0x2a627a('0xc8')](_0x41ed15['query'][_0x2a627a('0x9e')]);})[_0x4063fa('0x14')](respondWithStatusCode(_0x5cacac,null))['catch'](handleError(_0x5cacac,null));},exports[_0x5a8c6e('0xc9')]=function(_0xa04270,_0x3e27f1){const _0x16df89=_0x5a8c6e;return _0xa04270[_0x16df89('0x63')]['id']&&delete _0xa04270['body']['id'],db[_0x16df89('0x6b')][_0x16df89('0xca')]({'where':{'id':_0xa04270['params']['id']}})['then'](handleEntityNotFound(_0x3e27f1,null))[_0x16df89('0x14')](function(_0x290d51){const _0x2b1c68=_0x16df89;if(_0x290d51)return _0xa04270[_0x2b1c68('0x63')][_0x2b1c68('0x53')]=_0x290d51['id'],db[_0x2b1c68('0x1a')]['create'](_0xa04270[_0x2b1c68('0x63')]);})[_0x16df89('0x14')](respondWithResult(_0x3e27f1,null))[_0x16df89('0xad')](handleError(_0x3e27f1,null));},exports[_0x5a8c6e('0xba')]=function(_0x5cdc7d,_0x5d9259){const _0x27c7d8=_0x5a8c6e;let _0x3af322={'raw':![],'where':{}};const _0x295965={},_0x1736eb={'count':0x0,'rows':[]};return db[_0x27c7d8('0x6b')][_0x27c7d8('0xca')]({'where':{'id':_0x5cdc7d[_0x27c7d8('0xb1')]['id']}})[_0x27c7d8('0x14')](handleEntityNotFound(_0x5d9259,null))[_0x27c7d8('0x14')](function(_0x2b1981){const _0x3343fa=_0x27c7d8;if(_0x2b1981)return _0x295965['model']=_[_0x3343fa('0xc6')](db[_0x3343fa('0x1a')][_0x3343fa('0x75')]),_0x295965['query']=_[_0x3343fa('0xc6')](_0x5cdc7d[_0x3343fa('0xfd')]),_0x295965[_0x3343fa('0x89')]=_[_0x3343fa('0x38')](_0x295965[_0x3343fa('0x71')],_0x295965[_0x3343fa('0xfd')]),_0x3af322['attributes']=_[_0x3343fa('0x38')](_0x295965['model'],qs[_0x3343fa('0x8d')](_0x5cdc7d[_0x3343fa('0xfd')][_0x3343fa('0x8d')])),_0x3af322[_0x3343fa('0x13')]=_0x3af322[_0x3343fa('0x13')]['length']?_0x3af322[_0x3343fa('0x13')]:_0x295965['model'],typeof _0x5cdc7d[_0x3343fa('0xfd')][_0x3343fa('0x4a')]===_0x3343fa('0x74')&&(_0x3af322[_0x3343fa('0xf9')]=qs[_0x3343fa('0xf9')](_0x5cdc7d[_0x3343fa('0xfd')][_0x3343fa('0xf9')]),_0x3af322[_0x3343fa('0xa4')]=qs['offset'](_0x5cdc7d['query'][_0x3343fa('0xa4')])),_0x3af322[_0x3343fa('0x107')]=qs[_0x3343fa('0xe2')](_0x5cdc7d['query'][_0x3343fa('0xe2')]),_0x3af322['where']=qs[_0x3343fa('0x89')](_['pick'](_0x5cdc7d[_0x3343fa('0xfd')],_0x295965[_0x3343fa('0x89')])),_0x3af322[_0x3343fa('0x6f')][_0x3343fa('0x53')]=_0x2b1981['id'],_0x5cdc7d['query']['filter']&&(_0x3af322[_0x3343fa('0x6f')]=_[_0x3343fa('0x10a')](_0x3af322[_0x3343fa('0x6f')],{[Op['or']]:_['map'](_0x3af322['attributes'],function(_0x39ce2d){const _0xd70df8=_0x3343fa,_0x2eeb0f={};return _0x2eeb0f[_0x39ce2d]={[Op[_0xd70df8('0x99')]]:'%'+_0x5cdc7d[_0xd70df8('0xfd')][_0xd70df8('0x98')]+'%'},_0x2eeb0f;})})),_0x3af322=_[_0x3343fa('0x10a')]({},_0x3af322,_0x5cdc7d['options']),db['CannedAnswer']['count']({'where':_0x3af322['where']})[_0x3343fa('0x14')](function(_0x596c47){const _0x73970e=_0x3343fa;return _0x1736eb[_0x73970e('0x103')]=_0x596c47,_0x5cdc7d[_0x73970e('0xfd')][_0x73970e('0x9b')]&&(_0x3af322[_0x73970e('0x62')]=[{'all':!![]}]),db[_0x73970e('0x1a')][_0x73970e('0xa1')](_0x3af322);})[_0x3343fa('0x14')](function(_0xbb9f1b){const _0x1e5f24=_0x3343fa;return _0x1736eb[_0x1e5f24('0xec')]=_0xbb9f1b,_0x1736eb;});})[_0x27c7d8('0x14')](respondWithFilteredResult(_0x5d9259,_0x3af322))[_0x27c7d8('0xad')](handleError(_0x5d9259,null));},exports['removeAnswers']=function(_0x2e29a1,_0x38ffe8){const _0x173afb=_0x5a8c6e;return db[_0x173afb('0x6b')]['findOne']({'where':{'id':_0x2e29a1[_0x173afb('0xb1')]['id']}})['then'](handleEntityNotFound(_0x38ffe8,null))[_0x173afb('0x14')](function(_0x322610){const _0x1a6de1=_0x173afb;if(_0x322610)return _0x322610[_0x1a6de1('0xbc')](_0x2e29a1['query'][_0x1a6de1('0x9e')]);})[_0x173afb('0x14')](respondWithStatusCode(_0x38ffe8,null))[_0x173afb('0xad')](handleError(_0x38ffe8,null));},exports['addLogo']=function(_0x29e142,_0x2569e5){const _0x19c217=_0x5a8c6e;return _0x29e142[_0x19c217('0x63')][_0x19c217('0x4f')]=_0x29e142[_0x19c217('0x8b')]['filename'],db[_0x19c217('0x6b')]['findOne']({'where':{'id':_0x29e142[_0x19c217('0xb1')]['id']}})[_0x19c217('0x14')](handleEntityNotFound(_0x2569e5,null))['then'](saveUpdates(_0x29e142[_0x19c217('0x63')],null))[_0x19c217('0x14')](respondWithResult(_0x2569e5,null))['catch'](handleError(_0x2569e5,null));},exports[_0x5a8c6e('0x2')]=function(_0x3b0934,_0x2f4a39){const _0x395937=_0x5a8c6e;return _0x3b0934[_0x395937('0x63')][_0x395937('0xda')]=_0x3b0934[_0x395937('0x8b')][_0x395937('0xa3')],db['ChatWebsite']['findOne']({'where':{'id':_0x3b0934[_0x395937('0xb1')]['id']}})[_0x395937('0x14')](handleEntityNotFound(_0x2f4a39,null))[_0x395937('0x14')](saveUpdates(_0x3b0934['body'],null))[_0x395937('0x14')](respondWithResult(_0x2f4a39,null))[_0x395937('0xad')](handleError(_0x2f4a39,null));},exports['addCustomerAvatar']=function(_0xb07a3b,_0x23649f){const _0x434405=_0x5a8c6e;return _0xb07a3b[_0x434405('0x63')][_0x434405('0x48')]=_0xb07a3b[_0x434405('0x8b')][_0x434405('0xa3')],db['ChatWebsite'][_0x434405('0xca')]({'where':{'id':_0xb07a3b[_0x434405('0xb1')]['id']}})['then'](handleEntityNotFound(_0x23649f,null))[_0x434405('0x14')](saveUpdates(_0xb07a3b[_0x434405('0x63')],null))[_0x434405('0x14')](respondWithResult(_0x23649f,null))['catch'](handleError(_0x23649f,null));},exports[_0x5a8c6e('0x29')]=function(_0x5f05c8,_0x45fdf8){const _0x5ca9e4=_0x5a8c6e;return _0x5f05c8[_0x5ca9e4('0x63')][_0x5ca9e4('0xab')]=_0x5f05c8[_0x5ca9e4('0x8b')][_0x5ca9e4('0xa3')],db['ChatWebsite'][_0x5ca9e4('0xca')]({'where':{'id':_0x5f05c8[_0x5ca9e4('0xb1')]['id']}})[_0x5ca9e4('0x14')](handleEntityNotFound(_0x45fdf8,null))[_0x5ca9e4('0x14')](saveUpdates(_0x5f05c8[_0x5ca9e4('0x63')],null))[_0x5ca9e4('0x14')](respondWithResult(_0x45fdf8,null))[_0x5ca9e4('0xad')](handleError(_0x45fdf8,null));},exports[_0x5a8c6e('0xb9')]=function(_0x2800bc,_0x241e66){const _0x3d2ee3=_0x5a8c6e;let _0x342f3f=path[_0x3d2ee3('0x66')](config['root'],_0x3d2ee3('0x5e'));const _0x4de6e3={'where':{'id':_0x2800bc[_0x3d2ee3('0xb1')]['id']},'attributes':['id',_0x3d2ee3('0x4f')],'raw':!![]};let _0x7ca510=![];return require('../../config/license/util')['getLicense']()['then'](function(_0x472389){_0x472389&&(_0x7ca510=_0x472389['custom']);})[_0x3d2ee3('0x14')](function(){const _0x5430d7=_0x3d2ee3;return db[_0x5430d7('0x6b')]['findOne'](_0x4de6e3);})[_0x3d2ee3('0x14')](handleEntityNotFound(_0x241e66,null))[_0x3d2ee3('0x14')](function(_0x3f3914){const _0x2bcb28=_0x3d2ee3;if(_0x3f3914)return!_['isNil'](_0x3f3914[_0x2bcb28('0x4f')])&&(fs[_0x2bcb28('0xe8')](path['join'](config[_0x2bcb28('0xd6')],_0x2bcb28('0x8c'),_0x3f3914[_0x2bcb28('0x4f')]))&&_0x7ca510&&(_0x342f3f=path['join'](config[_0x2bcb28('0xd6')],_0x2bcb28('0x8c'),_0x3f3914['sitepic']))),_0x241e66[_0x2bcb28('0x9')](_0x342f3f);})['catch'](handleError(_0x241e66,null));},exports[_0x5a8c6e('0xc7')]=function(_0x51722f,_0x4a1a83){const _0x5d29db=_0x5a8c6e;let _0x1e00e4=path[_0x5d29db('0x66')](config[_0x5d29db('0xd6')],_0x5d29db('0x22'));const _0x48162d={'where':{'id':_0x51722f[_0x5d29db('0xb1')]['id']},'attributes':['id','agentAvatar'],'raw':!![]};return db['ChatWebsite'][_0x5d29db('0xca')](_0x48162d)['then'](handleEntityNotFound(_0x4a1a83,null))[_0x5d29db('0x14')](function(_0x3547e1){const _0x3bfbd6=_0x5d29db;if(_0x3547e1)return!_['isNil'](_0x3547e1[_0x3bfbd6('0xda')])&&(fs[_0x3bfbd6('0xe8')](path[_0x3bfbd6('0x66')](config[_0x3bfbd6('0xd6')],_0x3bfbd6('0x96'),_0x3547e1[_0x3bfbd6('0xda')]))&&(_0x1e00e4=path[_0x3bfbd6('0x66')](config[_0x3bfbd6('0xd6')],_0x3bfbd6('0x96'),_0x3547e1[_0x3bfbd6('0xda')]))),_0x4a1a83[_0x3bfbd6('0x9')](_0x1e00e4);})[_0x5d29db('0xad')](handleError(_0x4a1a83,null));},exports['getCustomerAvatar']=function(_0x590d70,_0x4bc512){const _0x1a588f=_0x5a8c6e;let _0x2cd304=path[_0x1a588f('0x66')](config[_0x1a588f('0xd6')],_0x1a588f('0x20'));const _0x40eb4c={'where':{'id':_0x590d70['params']['id']},'attributes':['id',_0x1a588f('0x48'),_0x1a588f('0x4c')],'raw':!![]};return db['ChatWebsite'][_0x1a588f('0xca')](_0x40eb4c)[_0x1a588f('0x14')](handleEntityNotFound(_0x4bc512,null))[_0x1a588f('0x14')](function(_0x31bc8f){const _0x4145a2=_0x1a588f;if(_0x31bc8f)return!_[_0x4145a2('0x16')](_0x31bc8f['customerAvatar'])&&(fs['existsSync'](path[_0x4145a2('0x66')](config[_0x4145a2('0xd6')],'server/files/images/avatars/',_0x31bc8f['customerAvatar']))&&_0x31bc8f['showCustomerAvatar']&&(_0x2cd304=path[_0x4145a2('0x66')](config[_0x4145a2('0xd6')],_0x4145a2('0x96'),_0x31bc8f[_0x4145a2('0x48')]))),_0x4bc512[_0x4145a2('0x9')](_0x2cd304);})[_0x1a588f('0xad')](handleError(_0x4bc512,null));},exports[_0x5a8c6e('0x9c')]=function(_0x398952,_0xcb5f2b){const _0x3a3ff4=_0x5a8c6e;let _0x2d7546=path['join'](config[_0x3a3ff4('0xd6')],_0x3a3ff4('0xc3'));const _0x19b3d1={'where':{'id':_0x398952[_0x3a3ff4('0xb1')]['id']},'attributes':['id',_0x3a3ff4('0xab')],'raw':!![]};return db[_0x3a3ff4('0x6b')][_0x3a3ff4('0xca')](_0x19b3d1)[_0x3a3ff4('0x14')](handleEntityNotFound(_0xcb5f2b,null))[_0x3a3ff4('0x14')](function(_0x291139){const _0x4ed2d1=_0x3a3ff4;if(_0x291139)return!_['isNil'](_0x291139[_0x4ed2d1('0xab')])&&(fs[_0x4ed2d1('0xe8')](path[_0x4ed2d1('0x66')](config[_0x4ed2d1('0xd6')],_0x4ed2d1('0x96'),_0x291139['systemAvatar']))&&(_0x2d7546=path[_0x4ed2d1('0x66')](config[_0x4ed2d1('0xd6')],_0x4ed2d1('0x96'),_0x291139[_0x4ed2d1('0xab')]))),_0xcb5f2b[_0x4ed2d1('0x9')](_0x2d7546);})[_0x3a3ff4('0xad')](handleError(_0xcb5f2b,null));},exports['notify']=function(_0x3daa5f,_0x351803){const _0x50d158=_0x5a8c6e,_0x225432=require(_0x50d158('0xee')),_0x5b0ab4=new _0x225432(),_0x4a9939=_0x5b0ab4[_0x50d158('0x101')](_0x3daa5f[_0x50d158('0x92')]['user-agent'])[_0x50d158('0x26')](),_0x42f95b={'body':_0x3daa5f[_0x50d158('0x63')],'channel':_0x50d158('0x24')};let _0x65198c=[],_0x580c84=[];const _0x48bfbf={};let _0x9f17ac=![];return db[_0x50d158('0x42')]['describe']()[_0x50d158('0x14')](function(_0x2528f5){const _0x16e274=_0x50d158;if(!_0x2528f5)throw new ValidationError('no\x20available\x20attributes');_0x65198c=_[_0x16e274('0xd2')](_[_0x16e274('0xc6')](_0x2528f5),[_0x16e274('0x10f'),'updatedAt']),_0x580c84=_['difference'](_['keys'](_0x2528f5),['createdAt',_0x16e274('0x113'),_0x16e274('0x77'),_0x16e274('0x73')]);_0x3daa5f[_0x16e274('0x63')]['id']&&delete _0x3daa5f[_0x16e274('0x63')]['id'];if(_[_0x16e274('0x16')](_0x3daa5f[_0x16e274('0x63')][_0x16e274('0x97')]))throw new ValidationError('from\x20is\x20mandatory');if(_[_0x16e274('0x16')](_0x3daa5f[_0x16e274('0x63')]['body'])||_0x3daa5f[_0x16e274('0x63')][_0x16e274('0x63')]==='')throw new ValidationError(_0x16e274('0x72'));if(_[_0x16e274('0x16')](_0x3daa5f['body'][_0x16e274('0x3d')]))throw new ValidationError(_0x16e274('0xd3')+_0x580c84);if(!_[_0x16e274('0x59')](_0x580c84,_0x3daa5f[_0x16e274('0x63')]['mapKey']))throw new ValidationError(_0x16e274('0x10b')+_0x580c84);_0x48bfbf[_0x3daa5f[_0x16e274('0x63')][_0x16e274('0x3d')]]=_0x3daa5f[_0x16e274('0x63')][_0x16e274('0x97')];})[_0x50d158('0x14')](function(){const _0x1984d7=_0x50d158;return db[_0x1984d7('0x6b')][_0x1984d7('0xca')]({'where':{'id':_0x3daa5f['params']['id']},'include':[{'model':db['CmList'],'as':_0x1984d7('0x9a'),'include':[{'model':db['CmContact'],'as':'Contacts','where':_0x48bfbf,'limit':0x1,'order':[['updatedAt',_0x1984d7('0x6')]]}]},{'model':db[_0x1984d7('0x79')],'as':'Applications'}]});})['then'](handleEntityNotFound(_0x351803,null))[_0x50d158('0x14')](function(_0x146f71){const _0x23c29a=_0x50d158;if(_0x146f71&&_0x146f71[_0x23c29a('0x9a')]){_0x42f95b[_0x23c29a('0x18')]=_0x146f71,_0x42f95b['applications']=_0x146f71[_0x23c29a('0x7f')],_0x42f95b[_0x23c29a('0x109')]=_0x146f71[_0x23c29a('0x9a')],_0x42f95b[_0x23c29a('0x60')]=_[_0x23c29a('0x81')](_0x42f95b[_0x23c29a('0x60')],[_0x23c29a('0x102')],['asc']);_0x42f95b[_0x23c29a('0x18')][_0x23c29a('0x7f')]&&delete _0x42f95b[_0x23c29a('0x18')]['Applications'];if(_0x42f95b['account'][_0x23c29a('0x9a')]&&_0x42f95b[_0x23c29a('0x18')][_0x23c29a('0x9a')][_0x23c29a('0xc')][_0x23c29a('0xb2')])return _0x42f95b[_0x23c29a('0x18')][_0x23c29a('0x9a')][_0x23c29a('0xc')][0x0];const _0x26ebe6=_[_0x23c29a('0x105')](_0x3daa5f[_0x23c29a('0x63')],{'firstName':_0x3daa5f[_0x23c29a('0x63')][_0x23c29a('0x97')],'ListId':_0x146f71[_0x23c29a('0x73')]});return _0x26ebe6[_0x3daa5f[_0x23c29a('0x63')][_0x23c29a('0x3d')]]=_0x3daa5f[_0x23c29a('0x63')][_0x23c29a('0x97')],db[_0x23c29a('0x42')][_0x23c29a('0x3b')](_0x26ebe6,{'fields':_0x65198c,'raw':!![]});}})[_0x50d158('0x14')](handleEntityNotFound(_0x351803,null))[_0x50d158('0x14')](function(_0xbdb37d){const _0x50e29e=_0x50d158;_0x42f95b[_0x50e29e('0xb0')]=_0xbdb37d;let _0x4e52a3=_0x3daa5f['body']['customerIp'];if(_0x3daa5f[_0x50e29e('0x92')][_0x50e29e('0x34')])_0x4e52a3=_0x3daa5f[_0x50e29e('0x92')][_0x50e29e('0x34')];else _0x3daa5f[_0x50e29e('0x92')][_0x50e29e('0x2c')]&&(_0x4e52a3=_['first'](_0x3daa5f[_0x50e29e('0x92')][_0x50e29e('0x2c')]['split'](',')));if(_0xbdb37d){const _0x39200f={'ContactId':_0xbdb37d['id'],'ChatWebsiteId':_0x3daa5f[_0x50e29e('0xb1')]['id'],'from':(_0xbdb37d[_0x50e29e('0x50')]||'')+'\x20'+(_0xbdb37d['lastName']||''),'customerIp':_0x4e52a3,'customerPort':_0x3daa5f[_0x50e29e('0x92')]['x-real-port']?_0x3daa5f['headers'][_0x50e29e('0x5d')]:null,'referer':_0x3daa5f['body']['referer'],'browserName':_0x4a9939[_0x50e29e('0x46')][_0x50e29e('0x4d')]&&_0x4a9939[_0x50e29e('0x46')][_0x50e29e('0xa8')]?util[_0x50e29e('0xc1')](_0x50e29e('0x115'),_0x4a9939[_0x50e29e('0x46')][_0x50e29e('0x4d')],_0x4a9939[_0x50e29e('0x46')]['version']):_0x50e29e('0x5'),'browserVersion':_0x4a9939[_0x50e29e('0x46')]['version']||_0x50e29e('0x5'),'osName':util['format'](_0x50e29e('0x115'),_0x4a9939['os'][_0x50e29e('0x4d')],_0x4a9939['os'][_0x50e29e('0xa8')]),'osVersion':_0x4a9939['os'][_0x50e29e('0xa8')],'deviceModel':_0x4a9939[_0x50e29e('0x2b')][_0x50e29e('0x71')]&&_0x4a9939[_0x50e29e('0x2b')][_0x50e29e('0xf4')]?util[_0x50e29e('0xc1')](_0x50e29e('0xfe'),_0x4a9939[_0x50e29e('0x2b')]['model'],_0x4a9939['device'][_0x50e29e('0xf4')],_0x4a9939[_0x50e29e('0x2b')][_0x50e29e('0x8f')]):null,'deviceVendor':_0x4a9939['device'][_0x50e29e('0xf4')],'deviceType':_0x4a9939[_0x50e29e('0x2b')][_0x50e29e('0x8f')],'formData':JSON[_0x50e29e('0x1b')](_0x3daa5f[_0x50e29e('0x63')])},_0x5d813a={'ChatWebsiteId':_0x3daa5f[_0x50e29e('0xb1')]['id'],'closed':![]};if(_0x3daa5f[_0x50e29e('0x63')][_0x50e29e('0x67')])return _0x5d813a[_0x50e29e('0x67')]=_0x3daa5f[_0x50e29e('0x63')]['threadId'],db[_0x50e29e('0x10d')][_0x50e29e('0xca')]({'where':_0x5d813a})['then'](function(_0x572d3a){const _0x60ffc4=_0x50e29e;if(_0x572d3a)return[_0x572d3a,![]];return _0x39200f[_0x60ffc4('0x67')]=_0x3daa5f[_0x60ffc4('0x63')][_0x60ffc4('0x67')],_0x39200f[_0x60ffc4('0xb5')]=_0x3daa5f[_0x60ffc4('0x63')][_0x60ffc4('0xb5')],db[_0x60ffc4('0x10d')][_0x60ffc4('0x3b')](_0x39200f)['then'](function(_0x2bb9b7){return[_0x2bb9b7,!![]];});});_0x5d813a[_0x50e29e('0x12')]=_0xbdb37d['id'];if(_0x3daa5f['body'][_0x50e29e('0x27')]&&_0x3daa5f[_0x50e29e('0x63')][_0x50e29e('0x27')]['id'])return _0x5d813a['id']=_0x3daa5f[_0x50e29e('0x63')][_0x50e29e('0x27')]['id'],db[_0x50e29e('0x10d')][_0x50e29e('0xca')]({'where':_0x5d813a})[_0x50e29e('0x14')](function(_0x520677){const _0x3af64a=_0x50e29e;if(_0x520677)return[_0x520677,![]];return db[_0x3af64a('0x10d')][_0x3af64a('0x3b')](_0x39200f)[_0x3af64a('0x14')](function(_0x578abd){return[_0x578abd,!![]];});});return db[_0x50e29e('0x10d')]['create'](_0x39200f)[_0x50e29e('0x14')](function(_0x30651c){return[_0x30651c,!![]];});}})[_0x50d158('0x14')](function([_0x2e68d4,_0x308f98]){const _0x424e9b=_0x50d158;if(_0x2e68d4){_0x9f17ac=_0x308f98;if(!_0x308f98){const _0x27dcd9={'from':(_0x42f95b[_0x424e9b('0xb0')][_0x424e9b('0x50')]||'')+'\x20'+(_0x42f95b[_0x424e9b('0xb0')][_0x424e9b('0x47')]||'')};return _0x3daa5f[_0x424e9b('0x63')][_0x424e9b('0x67')]&&_0x3daa5f[_0x424e9b('0x63')][_0x424e9b('0x49')]&&_0x3daa5f[_0x424e9b('0x63')][_0x424e9b('0x67')]!=_0x3daa5f['body'][_0x424e9b('0x49')]&&(_0x27dcd9[_0x424e9b('0x67')]=_0x3daa5f[_0x424e9b('0x63')]['messageId']),_0x2e68d4[_0x424e9b('0x37')](_0x27dcd9);}else return _0x2e68d4;}})[_0x50d158('0x14')](function(_0x508632){const _0x38921a=_0x50d158;return _0x42f95b['interaction']=_0x508632[_0x38921a('0xe6')]({'plain':!![]}),_0x42f95b[_0x38921a('0x27')][_0x38921a('0xb8')]=_0x9f17ac,_0x42f95b[_0x38921a('0x27')][_0x38921a('0xb8')]&&(_0x42f95b[_0x38921a('0x18')][_0x38921a('0x100')]&&_0x42f95b['applications'][_0x38921a('0x10c')]({'id':0x0,'priority':_0x42f95b[_0x38921a('0x60')][_0x38921a('0xb2')]+0x1,'app':_0x38921a('0xf2'),'appdata':_0x38921a('0x3f'),'interval':_0x38921a('0xea')})),db[_0x38921a('0x3c')][_0x38921a('0x3b')]({'body':_0x3daa5f['body'][_0x38921a('0x63')],'ChatWebsiteId':_0x3daa5f['params']['id'],'ChatInteractionId':_0x508632['id'],'direction':'in','ContactId':_0x42f95b[_0x38921a('0xb0')]['id'],'AttachmentId':_0x3daa5f[_0x38921a('0x63')][_0x38921a('0xa9')]});})[_0x50d158('0x14')](function(_0x22de45){const _0x5b7a4d=_0x50d158;_0x42f95b['message']=_0x22de45;if(_0x42f95b[_0x5b7a4d('0x27')][_0x5b7a4d('0x40')])return db[_0x5b7a4d('0x5a')][_0x5b7a4d('0xca')]({'attributes':['id','name'],'where':{'id':_0x42f95b[_0x5b7a4d('0x27')]['UserId']}})[_0x5b7a4d('0x14')](function(_0x35f8b7){const _0x5b6f0a=_0x5b7a4d;return _0x35f8b7&&(_0x42f95b[_0x5b6f0a('0x60')][_0x5b6f0a('0x111')]({'id':0x0,'priority':0x0,'app':_0x5b6f0a('0xdd'),'appdata':_0x35f8b7['name']+','+(_0x42f95b[_0x5b6f0a('0x18')][_0x5b6f0a('0x69')]||0xa),'interval':_0x5b6f0a('0xea')}),_0x42f95b['forcedOwnership']=!![]),respondWithRpcPromise(_0x5b6f0a('0x10'),_0x5b6f0a('0x45'),_0x42f95b);});return respondWithRpcPromise(_0x5b7a4d('0x10'),'startRouting',_0x42f95b);})['then'](function(_0x18ed24){const _0x3a10b4=_0x50d158;return respondWithRpcPromise(_0x3a10b4('0xbe'),'EventManager',{'event':_0x3a10b4('0xd8'),'message':_0x18ed24},client9002),_0x18ed24;})[_0x50d158('0x14')](respondWithResult(_0x351803,null))[_0x50d158('0xad')](handleError(_0x351803,null));},exports[_0x5a8c6e('0x15')]=function(_0x47d68a,_0x5dcb11){const _0x5225d0=_0x5a8c6e;let _0x59278b,_0x41351d,_0x56d243=[];const _0x1f80bd={};return db[_0x5225d0('0x42')]['describe']()[_0x5225d0('0x14')](function(_0x35fe57){const _0x479198=_0x5225d0;if(!_0x35fe57)throw new ValidationError(_0x479198('0x80'));_0x56d243=_[_0x479198('0xd2')](_['keys'](_0x35fe57),[_0x479198('0x10f'),'updatedAt',_0x479198('0x77'),'ListId']);_0x47d68a['body']['id']&&delete _0x47d68a[_0x479198('0x63')]['id'];if(_[_0x479198('0x16')](_0x47d68a[_0x479198('0x63')][_0x479198('0x97')]))throw _0x5dcb11[_0x479198('0x85')](0x1f4)[_0x479198('0x1')](new ValidationError(_0x479198('0x21')));if(_[_0x479198('0x16')](_0x47d68a['body'][_0x479198('0x63')])||_0x47d68a[_0x479198('0x63')]['body']==='')throw _0x5dcb11[_0x479198('0x85')](0x1f4)['send'](new ValidationError(_0x479198('0x72')));if(_[_0x479198('0x16')](_0x47d68a[_0x479198('0x63')][_0x479198('0x2f')]))throw _0x5dcb11['status'](0x1f4)[_0x479198('0x1')](new ValidationError(_0x479198('0x1c')+_0x56d243));if(!_[_0x479198('0x59')](_0x56d243,_0x47d68a[_0x479198('0x63')][_0x479198('0x2f')]))throw _0x5dcb11[_0x479198('0x85')](0x1f4)[_0x479198('0x1')](new ValidationError(_0x479198('0x3')+_0x56d243));_0x1f80bd[_0x47d68a['body']['mapKeyOffline']]=_0x47d68a[_0x479198('0x63')]['from'];})['then'](function(){const _0x1a0d18=_0x5225d0;return db[_0x1a0d18('0x6b')][_0x1a0d18('0xca')]({'where':{'id':_0x47d68a[_0x1a0d18('0xb1')]['id']},'include':[{'model':db[_0x1a0d18('0xe7')],'as':_0x1a0d18('0x9a')}]});})[_0x5225d0('0x14')](handleEntityNotFound(_0x5dcb11,null))[_0x5225d0('0x14')](function(_0x21214a){const _0x583b73=_0x5225d0;if(_0x21214a&&_0x21214a[_0x583b73('0x9a')]){_0x41351d=_0x21214a;const _0x419e18=_['defaults'](_0x47d68a[_0x583b73('0x63')],{'firstName':_0x47d68a[_0x583b73('0x63')][_0x583b73('0x97')],'phone':_0x47d68a[_0x583b73('0x63')][_0x583b73('0x97')],'ListId':_0x21214a[_0x583b73('0x73')]});return _0x419e18[_0x47d68a['body'][_0x583b73('0x2f')]]=_0x47d68a[_0x583b73('0x63')][_0x583b73('0x97')],db['CmContact'][_0x583b73('0x6c')]({'where':_0x1f80bd,'defaults':_0x419e18});}})['then'](function([_0x3e916e]){const _0x39f899=_0x5225d0;if(_0x3e916e){const _0x5bc6da=fs[_0x39f899('0xf3')](path[_0x39f899('0x66')](config[_0x39f899('0xd6')],'server/files/templates/chatOfflineMessage.ejs'),'utf8'),_0x21b338=ejs[_0x39f899('0xaa')](_0x5bc6da,{'body':_[_0x39f899('0xd7')](_0x47d68a['body'][_0x39f899('0x63')]),'bodyTitle':_0x41351d[_0x39f899('0x1e')]});return db[_0x39f899('0x84')][_0x39f899('0x3b')]({'body':_0x21b338,'ContactId':_0x3e916e['id'],'ChatWebsiteId':_0x41351d['id']});}})[_0x5225d0('0x14')](function(_0x100de9){const _0x1e1f27=_0x5225d0;if(_0x100de9)return _0x59278b=_0x100de9,db[_0x1e1f27('0x64')][_0x1e1f27('0xca')]({'where':{'service':!![]},'include':[{'model':db[_0x1e1f27('0x114')],'as':_0x1e1f27('0xe3'),'raw':!![]}]});})[_0x5225d0('0x14')](function(_0x43b34d){const _0x11c362=_0x5225d0;if(_0x43b34d&&_0x43b34d[_0x11c362('0xe3')]&&_0x41351d[_0x11c362('0x4e')]){const _0x1943e6={'tls':{'rejectUnauthorized':![]}};return _0x43b34d[_0x11c362('0xe3')][_0x11c362('0xe5')]?_0x1943e6[_0x11c362('0xe5')]=_0x43b34d[_0x11c362('0xe3')][_0x11c362('0xe5')]:(_0x1943e6[_0x11c362('0xac')]=_0x43b34d[_0x11c362('0xe3')][_0x11c362('0xac')],_0x1943e6[_0x11c362('0xaf')]=_0x43b34d[_0x11c362('0xe3')][_0x11c362('0xaf')],_0x1943e6[_0x11c362('0x61')]=_0x43b34d['Smtp'][_0x11c362('0x61')]),_0x43b34d[_0x11c362('0xe3')][_0x11c362('0xae')]&&(_0x1943e6[_0x11c362('0xbf')]={'user':_0x43b34d[_0x11c362('0xe3')][_0x11c362('0xd5')],'pass':_0x43b34d['Smtp'][_0x11c362('0x78')]}),respondWithRpcPromise(_0x11c362('0xa7'),_0x11c362('0x106'),{'account':_0x1943e6,'message':{'from':util[_0x11c362('0xc1')](_0x11c362('0x6e'),_0x43b34d[_0x11c362('0x4d')],_0x43b34d[_0x11c362('0xa')]||_0x43b34d['Smtp']['user']),'to':_0x41351d[_0x11c362('0x4e')],'subject':_0x41351d[_0x11c362('0x23')],'text':_0x59278b[_0x11c362('0x63')]}},client9003)[_0x11c362('0x14')](function(){return _0x59278b;})[_0x11c362('0xad')](function(_0x400276){const _0x26ebca=_0x11c362;console[_0x26ebca('0xf1')](_0x400276);});}})[_0x5225d0('0x14')](function(){if(_0x59278b)return _0x59278b;})['then'](respondWithResult(_0x5dcb11,null))[_0x5225d0('0xad')](handleError(_0x5dcb11,null));},exports[_0x5a8c6e('0x36')]=function(_0x2eb7aa,_0x87d53a){const _0x461ab9=_0x5a8c6e;return db[_0x461ab9('0x10d')][_0x461ab9('0xca')]({'where':{'id':_0x2eb7aa[_0x461ab9('0xb1')]['id']}})[_0x461ab9('0x14')](function(_0x245498){const _0x323ba6=_0x461ab9;if(_0x245498)return _0x245498[_0x323ba6('0x36')](_0x2eb7aa[_0x323ba6('0x63')][_0x323ba6('0x9e')],{'through':_[_0x323ba6('0x9d')](_0x2eb7aa[_0x323ba6('0x63')],['ids','id'])});})[_0x461ab9('0x14')](respondWithResult(_0x87d53a,null))[_0x461ab9('0xad')](handleError(_0x87d53a,null));},exports[_0x5a8c6e('0xdc')]=function(_0x1e9927,_0x2e7563){const _0x5c6b4a=_0x5a8c6e;let _0xea7077={'raw':![],'where':{}};const _0x19befe={},_0x44c309={'count':0x0,'rows':[]};return db['ChatWebsite']['findOne']({'where':{'id':_0x1e9927[_0x5c6b4a('0xb1')]['id']}})[_0x5c6b4a('0x14')](handleEntityNotFound(_0x2e7563,null))[_0x5c6b4a('0x14')](function(_0x5cdd09){const _0x3542f9=_0x5c6b4a;if(_0x5cdd09)return _0x19befe[_0x3542f9('0x71')]=_[_0x3542f9('0xc6')](db['ChatInteraction'][_0x3542f9('0x75')]),_0x19befe[_0x3542f9('0xfd')]=_[_0x3542f9('0xc6')](_0x1e9927[_0x3542f9('0xfd')]),_0x19befe[_0x3542f9('0x89')]=_[_0x3542f9('0x38')](_0x19befe[_0x3542f9('0x71')],_0x19befe[_0x3542f9('0xfd')]),_0xea7077['attributes']=_['intersection'](_0x19befe['model'],qs[_0x3542f9('0x8d')](_0x1e9927[_0x3542f9('0xfd')][_0x3542f9('0x8d')])),_0xea7077[_0x3542f9('0x13')]=_0xea7077['attributes'][_0x3542f9('0xb2')]?_0xea7077[_0x3542f9('0x13')]:_0x19befe[_0x3542f9('0x71')],typeof _0x1e9927[_0x3542f9('0xfd')][_0x3542f9('0x4a')]===_0x3542f9('0x74')&&(_0xea7077[_0x3542f9('0xf9')]=qs[_0x3542f9('0xf9')](_0x1e9927['query'][_0x3542f9('0xf9')]),_0xea7077[_0x3542f9('0xa4')]=qs['offset'](_0x1e9927[_0x3542f9('0xfd')][_0x3542f9('0xa4')])),_0xea7077[_0x3542f9('0x107')]=qs[_0x3542f9('0xe2')](_0x1e9927[_0x3542f9('0xfd')][_0x3542f9('0xe2')]),_0xea7077[_0x3542f9('0x6f')]=qs[_0x3542f9('0x89')](_['pick'](_0x1e9927[_0x3542f9('0xfd')],_0x19befe['filters'])),_0xea7077['where'][_0x3542f9('0x53')]=_0x5cdd09['id'],_0x1e9927['query'][_0x3542f9('0x98')]&&(_0xea7077[_0x3542f9('0x6f')]=_[_0x3542f9('0x10a')](_0xea7077['where'],{[Op['or']]:_['map'](_0xea7077[_0x3542f9('0x13')],function(_0x5621ae){const _0x44ccb2=_0x3542f9,_0x2e049e={};return _0x2e049e[_0x5621ae]={[Op[_0x44ccb2('0x99')]]:'%'+_0x1e9927[_0x44ccb2('0xfd')][_0x44ccb2('0x98')]+'%'},_0x2e049e;})})),_0xea7077=_[_0x3542f9('0x10a')]({},_0xea7077,_0x1e9927['options']),db[_0x3542f9('0x10d')][_0x3542f9('0x103')]({'where':_0xea7077[_0x3542f9('0x6f')]})[_0x3542f9('0x14')](function(_0x18fdd3){const _0xdf5433=_0x3542f9;return _0x44c309[_0xdf5433('0x103')]=_0x18fdd3,_0x1e9927[_0xdf5433('0xfd')]['includeAll']&&(_0xea7077[_0xdf5433('0x62')]=[{'model':db['CmContact'],'as':_0xdf5433('0xeb'),'required':![]},{'model':db[_0xdf5433('0x5a')],'as':_0xdf5433('0x3e'),'attributes':[_0xdf5433('0x4d'),_0xdf5433('0xa5'),'internal'],'required':![]},{'model':db[_0xdf5433('0x31')],'as':_0xdf5433('0xe0'),'attributes':['id','name','color'],'where':_0x1e9927[_0xdf5433('0xfd')][_0xdf5433('0xc0')]?{'id':_0x1e9927[_0xdf5433('0xfd')][_0xdf5433('0xc0')]}:undefined,'required':_0x1e9927[_0xdf5433('0xfd')][_0xdf5433('0xc0')]?!![]:![]}]),db['ChatInteraction'][_0xdf5433('0xa1')](_0xea7077);})[_0x3542f9('0x14')](function(_0x4d8d29){const _0x39d4e6=_0x3542f9;return _0x44c309[_0x39d4e6('0xec')]=_0x4d8d29,_0x44c309;});})[_0x5c6b4a('0x14')](respondWithFilteredResult(_0x2e7563,_0xea7077))['catch'](handleError(_0x2e7563,null));};function iftimePromise(_0x487deb,_0x3770fb){const _0x4ded7e=_0x5a8c6e;return respondWithRpcPromise('Command','getSnippet',{'command':_0x3770fb[_0x4ded7e('0x35')]?util[_0x4ded7e('0xc1')](_0x4ded7e('0xa0'),_0x487deb['interval'],_0x3770fb[_0x4ded7e('0x35')]):util[_0x4ded7e('0xc1')](_0x4ded7e('0xcb'),_0x487deb[_0x4ded7e('0xcc')])},client9002)[_0x4ded7e('0x14')](function(_0xda254f){const _0x30244e=_0x4ded7e,_0x3f5d34=_0xda254f&&_0xda254f['indexOf']('true')>=0x0?!![]:![];return logger[_0x30244e('0xef')](_0x30244e('0x110'),_0x3770fb['id'],_0x487deb['id'],_0x487deb[_0x30244e('0xcc')],_0x3f5d34?_0x30244e('0x7c'):_0x30244e('0x32'),_0x3770fb['timezone']?_0x3770fb[_0x30244e('0x35')]:_0x30244e('0x57')),_0x3f5d34;})[_0x4ded7e('0xad')](function(_0x223966){const _0x4749db=_0x4ded7e;return logger[_0x4749db('0xf1')](_0x4749db('0x110'),_0x3770fb['id'],_0x487deb['id'],_0x487deb['interval'],util[_0x4749db('0xf8')](_0x223966,{'showHidden':![],'depth':null}),_0x3770fb['timezone']?_0x3770fb[_0x4749db('0x35')]:_0x4749db('0x57')),![];});}exports[_0x5a8c6e('0xdf')]=function(_0x36cab9,_0x20614c){const _0x59f74b=_0x5a8c6e;let _0x175fc3=0x0,_0x23f0b0=0x0,_0x41b494=![],_0x2d315,_0x4ed5a0;return db[_0x59f74b('0x6b')][_0x59f74b('0xca')]({'where':{'id':_0x36cab9[_0x59f74b('0xb1')]['id']},'include':[{'model':db[_0x59f74b('0xfb')],'as':'Interval','include':[{'model':db['Interval'],'as':_0x59f74b('0xf'),'attributes':['id',_0x59f74b('0xcc')],'raw':!![]}]}]})[_0x59f74b('0x14')](handleEntityNotFound(_0x20614c,null))['then'](function(_0x229331){if(_0x229331)return _0x2d315=_0x229331,_0x229331['getProactiveActions']({'raw':!![]});})[_0x59f74b('0x14')](function(_0x42636c){const _0x192a9e=_0x59f74b;return _0x2d315&&(_0x42636c&&(_0x4ed5a0=_0x42636c)),require(_0x192a9e('0x2a'))['getLicense']();})[_0x59f74b('0x14')](function(_0xb1b3ea){const _0x5f5140=_0x59f74b;_0xb1b3ea&&(_0x23f0b0=_0xb1b3ea[_0x5f5140('0x108')],_0x41b494=_0xb1b3ea[_0x5f5140('0x55')]);})[_0x59f74b('0x14')](function(){const _0x417a2b=_0x59f74b;return db[_0x417a2b('0x10d')][_0x417a2b('0x103')]({'where':{'closed':![]}});})[_0x59f74b('0x14')](function(_0x381a2d){const _0x180cab=_0x59f74b;_0x175fc3=_0x381a2d;if(_0x23f0b0&&_0x381a2d>_0x23f0b0)return db[_0x180cab('0x30')]['findOne']({'where':{'id':0x1}})['then'](function(_0x62df7f){const _0x50c45d=_0x180cab;_0x62df7f&&_0x62df7f[_0x50c45d('0x44')]('chatLicenseExceeded');});})['then'](function(){const _0x2abb05=_0x59f74b;if(_0x2d315[_0x2abb05('0xfb')]&&_0x2d315[_0x2abb05('0xfb')][_0x2abb05('0xf')]){const _0x6132a2=[];for(let _0x2cc796=0x0;_0x2cc796<_0x2d315['Interval']['Intervals'][_0x2abb05('0xb2')];_0x2cc796++){const _0x5b2984=_0x2d315[_0x2abb05('0xfb')][_0x2abb05('0xf')][_0x2cc796][_0x2abb05('0xe6')]({'plain':!![]});_0x6132a2[_0x2abb05('0x10c')](iftimePromise(_0x5b2984,_0x2d315));}return Promise[_0x2abb05('0x6d')](_0x6132a2)[_0x2abb05('0x14')](function(_0x41dfd0){const _0x3cff61=_0x2abb05;return _[_0x3cff61('0xf0')](_0x41dfd0);});}else return!![];})[_0x59f74b('0x14')](function(_0x425554){const _0x20bde7=_0x59f74b,_0x399b7f=_0x36cab9[_0x20bde7('0x56')][_0x20bde7('0xe6')](_0x20bde7('0xb3')),_0x1031b6=fs[_0x20bde7('0xf3')](path[_0x20bde7('0x66')](config['root'],_0x20bde7('0xe9')),'utf8'),_0x2b99c2={'chatVersion':_0x399b7f,'remote':_0x2d315[_0x20bde7('0x68')],'query':querystring[_0x20bde7('0x1b')](_[_0x20bde7('0x10a')](_0x2d315[_0x20bde7('0xe6')]({'plain':!![]}),{'customerIp':_0x36cab9[_0x20bde7('0x92')][_0x20bde7('0x2c')]||_0x36cab9[_0x20bde7('0x92')][_0x20bde7('0x54')]||_0x36cab9[_0x20bde7('0x41')][_0x20bde7('0xf6')]||_0x36cab9['ip'],'referer':_0x36cab9['headers'][_0x20bde7('0xce')],'openedInteractions':_0x175fc3,'maxInteractions':_0x23f0b0,'virtual':_0x41b494[_0x20bde7('0x108')],'online':_0x425554,'custom':_0x41b494}))[_0x20bde7('0x91')](/'/g,'\x5c\x27')};_0x20614c[_0x20bde7('0x1')](ejs[_0x20bde7('0xaa')](Mustache[_0x20bde7('0xaa')](_0x1031b6,_0x2b99c2),{'proactiveActions':_0x4ed5a0,'alignment':_0x2d315['alignment'],'verticalAlignment':_0x2d315[_0x20bde7('0x52')],'div_color':_0x2d315[_0x20bde7('0x87')],'text_color':_0x2d315[_0x20bde7('0xdb')]}));})[_0x59f74b('0xad')](handleError(_0x20614c,null));},exports[_0x5a8c6e('0xe4')]=function(_0xff0e5a,_0x7f0b6d){const _0x5978fa=_0x5a8c6e;return db[_0x5978fa('0x6b')][_0x5978fa('0xca')]({'where':{'id':_0xff0e5a[_0x5978fa('0xb1')]['id']}})[_0x5978fa('0x14')](handleEntityNotFound(_0x7f0b6d,null))['then'](function(_0x484056){const _0x57bec8=_0x5978fa;if(_0x484056)return db[_0x57bec8('0xe1')][_0x57bec8('0x95')](function(_0x63f4d1){const _0x363c3e=_0x57bec8;return db[_0x363c3e('0x79')][_0x363c3e('0x88')]({'where':{'ChatWebsiteId':_0xff0e5a[_0x363c3e('0xb1')]['id']},'transaction':_0x63f4d1})[_0x363c3e('0x14')](function(){const _0x22e424=_0x363c3e,_0x59f6d4=_[_0x22e424('0xd9')](_0xff0e5a[_0x22e424('0x63')],function(_0x513cf2){const _0x22d0bf=_0x22e424;return _0x513cf2[_0x22d0bf('0x53')]=_0xff0e5a[_0x22d0bf('0xb1')]['id'],_0x513cf2;});return db['ChatApplication']['bulkCreate'](_0x59f6d4,{'transaction':_0x63f4d1});});})[_0x57bec8('0x14')](function(){const _0x3ca458=_0x57bec8;return db['ChatApplication'][_0x3ca458('0x4b')]({'where':{'ChatWebsiteId':_0xff0e5a[_0x3ca458('0xb1')]['id']},'order':'priority'});});})[_0x5978fa('0x14')](respondWithResult(_0x7f0b6d,null))[_0x5978fa('0xad')](handleError(_0x7f0b6d,null));},exports[_0x5a8c6e('0xcf')]=function(_0x193550,_0x219184){const _0x50ad28=_0x5a8c6e;let _0xbe3c51={};const _0x5b8abb={};let _0x5c86b7,_0x359ce0;return db[_0x50ad28('0x6b')][_0x50ad28('0xca')]({'where':{'id':_0x193550[_0x50ad28('0xb1')]['id']}})[_0x50ad28('0x14')](handleEntityNotFound(_0x219184,null))['then'](function(_0x12ce23){const _0x464f00=_0x50ad28;if(_0x12ce23)return _0x5c86b7=_0x12ce23,_0x5b8abb[_0x464f00('0x71')]=_[_0x464f00('0xc6')](db['ChatApplication']['rawAttributes']),_0x5b8abb[_0x464f00('0xfd')]=_['keys'](_0x193550['query']),_0x5b8abb[_0x464f00('0x89')]=_['intersection'](_0x5b8abb[_0x464f00('0x71')],_0x5b8abb[_0x464f00('0xfd')]),_0xbe3c51['attributes']=_['intersection'](_0x5b8abb['model'],qs[_0x464f00('0x8d')](_0x193550[_0x464f00('0xfd')][_0x464f00('0x8d')])),_0xbe3c51[_0x464f00('0x13')]=_0xbe3c51[_0x464f00('0x13')][_0x464f00('0xb2')]?_0xbe3c51[_0x464f00('0x13')]:_0x5b8abb[_0x464f00('0x71')],_0xbe3c51['order']=qs['sort'](_0x193550[_0x464f00('0xfd')]['sort']),_0xbe3c51[_0x464f00('0x6f')]=qs[_0x464f00('0x89')](_[_0x464f00('0x1f')](_0x193550[_0x464f00('0xfd')],_0x5b8abb[_0x464f00('0x89')])),_0x193550[_0x464f00('0xfd')][_0x464f00('0x98')]&&(_0xbe3c51[_0x464f00('0x6f')]=_[_0x464f00('0x10a')](_0xbe3c51[_0x464f00('0x6f')],{[Op['or']]:_[_0x464f00('0xd9')](_0xbe3c51[_0x464f00('0x13')],function(_0x280676){const _0x274cd7=_0x464f00,_0xa56581={};return _0xa56581[_0x280676]={[Op[_0x274cd7('0x99')]]:'%'+_0x193550[_0x274cd7('0xfd')]['filter']+'%'},_0xa56581;})})),_0xbe3c51=_[_0x464f00('0x10a')]({},_0xbe3c51,_0x193550['options']),_0x5c86b7[_0x464f00('0xcf')](_0xbe3c51);})[_0x50ad28('0x14')](function(_0x300652){const _0x1e0afc=_0x50ad28;if(_0x300652)return _0x359ce0=_0x300652['length'],typeof _0x193550[_0x1e0afc('0xfd')][_0x1e0afc('0x4a')]===_0x1e0afc('0x74')&&(_0xbe3c51['limit']=qs[_0x1e0afc('0xf9')](_0x193550[_0x1e0afc('0xfd')]['limit']),_0xbe3c51[_0x1e0afc('0xa4')]=qs['offset'](_0x193550[_0x1e0afc('0xfd')][_0x1e0afc('0xa4')])),_0x5c86b7['getApplications'](_0xbe3c51);})[_0x50ad28('0x14')](function(_0x268083){if(_0x268083)return _0x268083?{'count':_0x359ce0,'rows':_0x268083}:null;})[_0x50ad28('0x14')](respondWithResult(_0x219184,null))[_0x50ad28('0xad')](handleError(_0x219184,null));},exports['addProactiveActions']=function(_0x5f40ee,_0x178833){const _0x107eb8=_0x5a8c6e;return db['chatProactiveAction']['findOne']({'where':{'id':_0x5f40ee['params']['id']}})['then'](function(_0x2e772d){const _0x1a2ee3=a111_0x50ca;if(_0x2e772d)return _0x2e772d[_0x1a2ee3('0x70')](_0x5f40ee[_0x1a2ee3('0x63')][_0x1a2ee3('0x9e')],{'through':_[_0x1a2ee3('0x9d')](_0x5f40ee['body'],[_0x1a2ee3('0x9e'),'id'])});})[_0x107eb8('0x14')](respondWithResult(_0x178833,null))[_0x107eb8('0xad')](handleError(_0x178833,null));},exports[_0x5a8c6e('0xcd')]=function(_0x190d72,_0x426e82){const _0x24956b=_0x5a8c6e;let _0x3d90bb={};const _0x5db028={};let _0x3f7b96,_0x1c6e76;return db['ChatWebsite']['findOne']({'where':{'id':_0x190d72[_0x24956b('0xb1')]['id']}})['then'](handleEntityNotFound(_0x426e82,null))['then'](function(_0x5ea4c8){const _0x4a3b2d=_0x24956b;if(_0x5ea4c8)return _0x3f7b96=_0x5ea4c8,_0x5db028['model']=_[_0x4a3b2d('0xc6')](db[_0x4a3b2d('0xa2')][_0x4a3b2d('0x75')]),_0x5db028[_0x4a3b2d('0xfd')]=_[_0x4a3b2d('0xc6')](_0x190d72['query']),_0x5db028[_0x4a3b2d('0x89')]=_[_0x4a3b2d('0x38')](_0x5db028[_0x4a3b2d('0x71')],_0x5db028['query']),_0x3d90bb[_0x4a3b2d('0x13')]=_[_0x4a3b2d('0x38')](_0x5db028['model'],qs['fields'](_0x190d72[_0x4a3b2d('0xfd')][_0x4a3b2d('0x8d')])),_0x3d90bb[_0x4a3b2d('0x13')]=_0x3d90bb['attributes'][_0x4a3b2d('0xb2')]?_0x3d90bb[_0x4a3b2d('0x13')]:_0x5db028[_0x4a3b2d('0x71')],_0x3d90bb[_0x4a3b2d('0x107')]=qs[_0x4a3b2d('0xe2')](_0x190d72[_0x4a3b2d('0xfd')]['sort']),_0x3d90bb[_0x4a3b2d('0x6f')]=qs[_0x4a3b2d('0x89')](_['pick'](_0x190d72[_0x4a3b2d('0xfd')],_0x5db028['filters'])),_0x190d72[_0x4a3b2d('0xfd')][_0x4a3b2d('0x98')]&&(_0x3d90bb['where']=_[_0x4a3b2d('0x10a')](_0x3d90bb[_0x4a3b2d('0x6f')],{[Op['or']]:_[_0x4a3b2d('0xd9')](_0x3d90bb[_0x4a3b2d('0x13')],function(_0x797a9e){const _0x45d823=_0x4a3b2d,_0x50efe8={};return _0x50efe8[_0x797a9e]={[Op['like']]:'%'+_0x190d72[_0x45d823('0xfd')][_0x45d823('0x98')]+'%'},_0x50efe8;})})),_0x3d90bb=_['merge']({},_0x3d90bb,_0x190d72[_0x4a3b2d('0x5c')]),_0x3f7b96[_0x4a3b2d('0xcd')](_0x3d90bb);})[_0x24956b('0x14')](function(_0x59e1ae){const _0xc06709=_0x24956b;if(_0x59e1ae)return _0x1c6e76=_0x59e1ae[_0xc06709('0xb2')],typeof _0x190d72[_0xc06709('0xfd')][_0xc06709('0x4a')]===_0xc06709('0x74')&&(_0x3d90bb[_0xc06709('0xf9')]=qs[_0xc06709('0xf9')](_0x190d72[_0xc06709('0xfd')][_0xc06709('0xf9')]),_0x3d90bb[_0xc06709('0xa4')]=qs[_0xc06709('0xa4')](_0x190d72[_0xc06709('0xfd')][_0xc06709('0xa4')])),_0x3f7b96[_0xc06709('0xcd')](_0x3d90bb);})['then'](function(_0x5ed2e9){if(_0x5ed2e9)return _0x5ed2e9?{'count':_0x1c6e76,'rows':_0x5ed2e9}:null;})[_0x24956b('0x14')](respondWithResult(_0x426e82,null))[_0x24956b('0xad')](handleError(_0x426e82,null));},exports[_0x5a8c6e('0x5b')]=function(_0x67c707,_0x400967){const _0x2f98f5=_0x5a8c6e,_0x29ceb6=_0x67c707[_0x2f98f5('0xfd')][_0x2f98f5('0x2e')]===_0x2f98f5('0xd1')?'offlineForm':_0x2f98f5('0x58');return db[_0x2f98f5('0x6b')][_0x2f98f5('0xca')]({'attributes':['id',_0x29ceb6],'where':{'id':_0x67c707[_0x2f98f5('0xb1')]['id']}})[_0x2f98f5('0x14')](handleEntityNotFound(_0x400967,null))['then'](function(_0x4d27cb){const _0x3aed28=_0x2f98f5;if(_0x4d27cb){const _0x4440fc=_0x4d27cb[_0x29ceb6],_0x245a7c=_0x4440fc&&_0x4440fc[_0x3aed28('0x25')]?_0x4440fc[_0x3aed28('0x25')]:[];_0x400967[_0x3aed28('0x1')]({'fromKey':_[_0x3aed28('0x16')](_0x4440fc[_0x3aed28('0x9f')])?undefined:_0x4440fc['fromKey'],'count':_0x245a7c[_0x3aed28('0xb2')],'rows':_0x245a7c});}})['catch'](handleError(_0x400967,null));},exports[_0x5a8c6e('0x7e')]=function(_0x22bd2e,_0x53214c){const _0x43ca49=_0x5a8c6e;let _0x128156={'raw':![],'where':{}};const _0x49f8d9={},_0x3aea70={'count':0x0,'rows':[]};return db[_0x43ca49('0x6b')]['findOne']({'where':{'id':_0x22bd2e[_0x43ca49('0xb1')]['id']}})[_0x43ca49('0x14')](handleEntityNotFound(_0x53214c,null))['then'](function(_0x3648e5){const _0x161ab3=_0x43ca49;if(_0x3648e5)return _0x49f8d9[_0x161ab3('0x71')]=_[_0x161ab3('0xc6')](db[_0x161ab3('0x84')][_0x161ab3('0x75')]),_0x49f8d9[_0x161ab3('0xfd')]=_[_0x161ab3('0xc6')](_0x22bd2e['query']),_0x49f8d9['filters']=_['intersection'](_0x49f8d9[_0x161ab3('0x71')],_0x49f8d9[_0x161ab3('0xfd')]),_0x128156[_0x161ab3('0x13')]=_['intersection'](_0x49f8d9[_0x161ab3('0x71')],qs[_0x161ab3('0x8d')](_0x22bd2e[_0x161ab3('0xfd')][_0x161ab3('0x8d')])),_0x128156[_0x161ab3('0x13')]=_0x128156[_0x161ab3('0x13')][_0x161ab3('0xb2')]?_0x128156['attributes']:_0x49f8d9[_0x161ab3('0x71')],typeof _0x22bd2e[_0x161ab3('0xfd')][_0x161ab3('0x4a')]===_0x161ab3('0x74')&&(_0x128156['limit']=qs[_0x161ab3('0xf9')](_0x22bd2e['query']['limit']),_0x128156['offset']=qs[_0x161ab3('0xa4')](_0x22bd2e[_0x161ab3('0xfd')][_0x161ab3('0xa4')])),_0x128156[_0x161ab3('0x107')]=qs[_0x161ab3('0xe2')](_0x22bd2e[_0x161ab3('0xfd')]['sort']),_0x128156['where']=qs[_0x161ab3('0x89')](_[_0x161ab3('0x1f')](_0x22bd2e[_0x161ab3('0xfd')],_0x49f8d9[_0x161ab3('0x89')])),_0x128156[_0x161ab3('0x6f')][_0x161ab3('0x53')]=_0x3648e5['id'],_0x22bd2e[_0x161ab3('0xfd')][_0x161ab3('0x98')]&&(_0x128156[_0x161ab3('0x6f')]=_['merge'](_0x128156['where'],{[Op['or']]:_[_0x161ab3('0xd9')](_0x128156[_0x161ab3('0x13')],function(_0x405bc6){const _0x3f1d9d=_0x161ab3,_0x38429b={};return _0x38429b[_0x405bc6]={[Op[_0x3f1d9d('0x99')]]:'%'+_0x22bd2e[_0x3f1d9d('0xfd')][_0x3f1d9d('0x98')]+'%'},_0x38429b;})})),_0x128156=_[_0x161ab3('0x10a')]({},_0x128156,_0x22bd2e[_0x161ab3('0x5c')]),db[_0x161ab3('0x84')]['count']({'where':_0x128156[_0x161ab3('0x6f')]})[_0x161ab3('0x14')](function(_0x23d531){const _0x653d7a=_0x161ab3;return _0x3aea70['count']=_0x23d531,_0x22bd2e[_0x653d7a('0xfd')][_0x653d7a('0x9b')]?_0x128156[_0x653d7a('0x62')]=[{'all':!![]}]:_0x128156['include']=[{'model':db[_0x653d7a('0x42')],'as':_0x653d7a('0xeb'),'required':![]}],db['ChatOfflineMessage']['findAll'](_0x128156);})[_0x161ab3('0x14')](function(_0x4d8943){return _0x3aea70['rows']=_0x4d8943,_0x3aea70;});})[_0x43ca49('0x14')](respondWithFilteredResult(_0x53214c,_0x128156))[_0x43ca49('0xad')](handleError(_0x53214c,null));},exports[_0x5a8c6e('0xc2')]=function(_0x1f4de2,_0x4c0452){const _0x21ae21=_0x5a8c6e;return db['ChatWebsite']['findOne']({'where':{'id':_0x1f4de2[_0x21ae21('0xb1')]['id']}})[_0x21ae21('0x14')](function(_0x2c7128){const _0x1901d4=_0x21ae21;if(_0x2c7128)return _0x2c7128[_0x1901d4('0xc2')](_0x1f4de2['body'][_0x1901d4('0x9e')],{'through':_['omit'](_0x1f4de2[_0x1901d4('0x63')],[_0x1901d4('0x9e'),'id'])})[_0x1901d4('0x14')](function(_0x2bc991){const _0x55d754=_0x1901d4;for(let _0x743c77=0x0;_0x743c77<_0x1f4de2[_0x55d754('0x63')][_0x55d754('0x9e')]['length'];_0x743c77+=0x1){socket[_0x55d754('0x86')]('userChatWebsite:save',{'UserId':_0x1f4de2[_0x55d754('0x63')][_0x55d754('0x9e')][_0x743c77],'ChatWebsiteId':_0x1f4de2['params']['id']});}return _0x2bc991;});})[_0x21ae21('0x14')](respondWithResult(_0x4c0452,null))[_0x21ae21('0xad')](handleError(_0x4c0452,null));},exports['removeAgents']=function(_0x563b72,_0x343cd8){const _0x28bab7=_0x5a8c6e;return db['ChatWebsite']['findOne']({'where':{'id':_0x563b72[_0x28bab7('0xb1')]['id']}})[_0x28bab7('0x14')](handleEntityNotFound(_0x343cd8,null))[_0x28bab7('0x14')](function(_0x412769){const _0x3535aa=_0x28bab7;if(_0x412769)return _0x412769[_0x3535aa('0x76')](_0x563b72[_0x3535aa('0xfd')][_0x3535aa('0x9e')])['then'](function(){const _0x30945a=_0x3535aa;if(_[_0x30945a('0x8e')](_0x563b72[_0x30945a('0xfd')][_0x30945a('0x9e')]))for(let _0x35e89a=0x0;_0x35e89a<_0x563b72['query'][_0x30945a('0x9e')][_0x30945a('0xb2')];_0x35e89a+=0x1){socket[_0x30945a('0x86')](_0x30945a('0x3a'),{'UserId':Number(_0x563b72[_0x30945a('0xfd')]['ids'][_0x35e89a]),'ChatWebsiteId':Number(_0x563b72['params']['id'])});}else socket[_0x30945a('0x86')](_0x30945a('0x3a'),{'UserId':Number(_0x563b72['query'][_0x30945a('0x9e')]),'ChatWebsiteId':Number(_0x563b72[_0x30945a('0xb1')]['id'])});});})['then'](respondWithStatusCode(_0x343cd8,null))['catch'](handleError(_0x343cd8,null));},exports[_0x5a8c6e('0xfc')]=function(_0x1b28c,_0x32bfaa){const _0x4604b2=_0x5a8c6e;let _0x34ae4a={};const _0x2284e6={};let _0x5b1317,_0x5b4a88;return db[_0x4604b2('0x6b')][_0x4604b2('0xca')]({'where':{'id':_0x1b28c[_0x4604b2('0xb1')]['id']}})[_0x4604b2('0x14')](handleEntityNotFound(_0x32bfaa,null))['then'](function(_0x1186d9){const _0x30853c=_0x4604b2;if(_0x1186d9)return _0x5b1317=_0x1186d9,_0x2284e6['model']=_[_0x30853c('0xc6')](db[_0x30853c('0x5a')][_0x30853c('0x75')]),_0x2284e6[_0x30853c('0xfd')]=_[_0x30853c('0xc6')](_0x1b28c[_0x30853c('0xfd')]),_0x2284e6[_0x30853c('0x89')]=_[_0x30853c('0x38')](_0x2284e6[_0x30853c('0x71')],_0x2284e6[_0x30853c('0xfd')]),_0x34ae4a['attributes']=_['intersection'](_0x2284e6[_0x30853c('0x71')],qs[_0x30853c('0x8d')](_0x1b28c[_0x30853c('0xfd')]['fields'])),_0x34ae4a[_0x30853c('0x13')]=_0x34ae4a[_0x30853c('0x13')][_0x30853c('0xb2')]?_0x34ae4a['attributes']:_0x2284e6['model'],_0x34ae4a[_0x30853c('0x107')]=qs[_0x30853c('0xe2')](_0x1b28c['query'][_0x30853c('0xe2')]),_0x34ae4a[_0x30853c('0x6f')]=qs['filters'](_[_0x30853c('0x1f')](_0x1b28c[_0x30853c('0xfd')],_0x2284e6[_0x30853c('0x89')])),_0x1b28c['query']['filter']&&(_0x34ae4a[_0x30853c('0x6f')]=_[_0x30853c('0x10a')](_0x34ae4a['where'],{[Op['or']]:_[_0x30853c('0xd9')](_0x34ae4a[_0x30853c('0x13')],function(_0x5cf821){const _0x33fdf3=_0x30853c,_0x453500={};return _0x453500[_0x5cf821]={[Op[_0x33fdf3('0x99')]]:'%'+_0x1b28c[_0x33fdf3('0xfd')][_0x33fdf3('0x98')]+'%'},_0x453500;})})),_0x34ae4a=_[_0x30853c('0x10a')]({},_0x34ae4a,_0x1b28c[_0x30853c('0x5c')]),_0x5b1317[_0x30853c('0xfc')](_0x34ae4a);})['then'](function(_0x3f3e7b){const _0xf0ce44=_0x4604b2;if(_0x3f3e7b)return _0x5b4a88=_0x3f3e7b['length'],typeof _0x1b28c[_0xf0ce44('0xfd')][_0xf0ce44('0x4a')]===_0xf0ce44('0x74')&&(_0x34ae4a[_0xf0ce44('0xf9')]=qs[_0xf0ce44('0xf9')](_0x1b28c[_0xf0ce44('0xfd')]['limit']),_0x34ae4a[_0xf0ce44('0xa4')]=qs['offset'](_0x1b28c[_0xf0ce44('0xfd')][_0xf0ce44('0xa4')])),_0x5b1317['getAgents'](_0x34ae4a);})[_0x4604b2('0x14')](function(_0x1c6acf){if(_0x1c6acf)return _0x1c6acf?{'count':_0x5b4a88,'rows':_0x1c6acf}:null;})['then'](respondWithResult(_0x32bfaa,null))['catch'](handleError(_0x32bfaa,null));}; \ No newline at end of file diff --git a/server/api/chatWebsite/chatWebsite.events.js b/server/api/chatWebsite/chatWebsite.events.js index cb3edcd..7372c04 100644 --- a/server/api/chatWebsite/chatWebsite.events.js +++ b/server/api/chatWebsite/chatWebsite.events.js @@ -1 +1 @@ -const a112_0x4131=['addHook','setMaxListeners','update','emit','ChatWebsite','save','remove','../../mysqldb'];(function(_0x1aba6c,_0x4131fa){const _0x43201c=function(_0x4f3ead){while(--_0x4f3ead){_0x1aba6c['push'](_0x1aba6c['shift']());}};_0x43201c(++_0x4131fa);}(a112_0x4131,0xe8));const a112_0x4320=function(_0x1aba6c,_0x4131fa){_0x1aba6c=_0x1aba6c-0x0;let _0x43201c=a112_0x4131[_0x1aba6c];return _0x43201c;};const _0x3ee6c7=a112_0x4320;'use strict';const EventEmitter=require('events'),ChatWebsite=require(_0x3ee6c7('0x7'))['db'][_0x3ee6c7('0x4')],ChatWebsiteEvents=new EventEmitter();ChatWebsiteEvents[_0x3ee6c7('0x1')](0x0);const events={'afterCreate':_0x3ee6c7('0x5'),'afterUpdate':_0x3ee6c7('0x2'),'afterDestroy':_0x3ee6c7('0x6')};function emitEvent(_0x4f3ead){return function(_0x5f256f){const _0x20ea13=a112_0x4320;ChatWebsiteEvents[_0x20ea13('0x3')](_0x4f3ead+':'+_0x5f256f['id'],_0x5f256f),ChatWebsiteEvents['emit'](_0x4f3ead,_0x5f256f);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];ChatWebsite[_0x3ee6c7('0x0')](e,emitEvent(event));}}module['exports']=ChatWebsiteEvents; \ No newline at end of file +const a112_0x56cf=['undefined','emit','ChatWebsite','remove','save'];(function(_0x58ea21,_0x56cf0c){const _0x16db65=function(_0x4d1f11){while(--_0x4d1f11){_0x58ea21['push'](_0x58ea21['shift']());}};_0x16db65(++_0x56cf0c);}(a112_0x56cf,0x1c6));const a112_0x16db=function(_0x58ea21,_0x56cf0c){_0x58ea21=_0x58ea21-0x0;let _0x16db65=a112_0x56cf[_0x58ea21];return _0x16db65;};const _0x3b8eb6=a112_0x16db;'use strict';const EventEmitter=require('events'),ChatWebsite=require('../../mysqldb')['db'][_0x3b8eb6('0x3')],ChatWebsiteEvents=new EventEmitter();ChatWebsiteEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x3b8eb6('0x0'),'afterUpdate':'update','afterDestroy':_0x3b8eb6('0x4')};function emitEvent(_0x4d1f11){return function(_0xb65a5d){const _0x5d77ce=a112_0x16db;ChatWebsiteEvents[_0x5d77ce('0x2')](_0x4d1f11+':'+_0xb65a5d['id'],_0xb65a5d),ChatWebsiteEvents['emit'](_0x4d1f11,_0xb65a5d);};}for(const e in events){if(typeof events[e]!==_0x3b8eb6('0x1')){const event=events[e];ChatWebsite['addHook'](e,emitEvent(event));}}module['exports']=ChatWebsiteEvents; \ No newline at end of file diff --git a/server/api/chatWebsite/chatWebsite.model.js b/server/api/chatWebsite/chatWebsite.model.js index deb91f8..f61bc72 100644 --- a/server/api/chatWebsite/chatWebsite.model.js +++ b/server/api/chatWebsite/chatWebsite.model.js @@ -1 +1 @@ -const a113_0x3e6b=['chat_websites','./chatWebsite.attributes','exports','ChatWebsite'];(function(_0x1226e6,_0x3e6bb5){const _0x33b5f8=function(_0x373103){while(--_0x373103){_0x1226e6['push'](_0x1226e6['shift']());}};_0x33b5f8(++_0x3e6bb5);}(a113_0x3e6b,0x175));const a113_0x33b5=function(_0x1226e6,_0x3e6bb5){_0x1226e6=_0x1226e6-0x0;let _0x33b5f8=a113_0x3e6b[_0x1226e6];return _0x33b5f8;};const _0x940c7a=a113_0x33b5;'use strict';const attributes=require(_0x940c7a('0x0'));module[_0x940c7a('0x1')]=function(_0x373103){const _0x57827e=_0x940c7a,_0x1b7dcc=_0x373103['define'](_0x57827e('0x2'),attributes,{'tableName':_0x57827e('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1b7dcc;}; \ No newline at end of file +const a113_0xf318=['ChatWebsite','chat_websites','exports'];(function(_0x24f060,_0xf31818){const _0x4ee32b=function(_0x58e2cf){while(--_0x58e2cf){_0x24f060['push'](_0x24f060['shift']());}};_0x4ee32b(++_0xf31818);}(a113_0xf318,0x1d1));const a113_0x4ee3=function(_0x24f060,_0xf31818){_0x24f060=_0x24f060-0x0;let _0x4ee32b=a113_0xf318[_0x24f060];return _0x4ee32b;};const _0x59839e=a113_0x4ee3;'use strict';const attributes=require('./chatWebsite.attributes');module[_0x59839e('0x2')]=function(_0x58e2cf){const _0x24ff5d=_0x59839e,_0x557130=_0x58e2cf['define'](_0x24ff5d('0x0'),attributes,{'tableName':_0x24ff5d('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x557130;}; \ No newline at end of file diff --git a/server/api/chatWebsite/chatWebsite.rpc.js b/server/api/chatWebsite/chatWebsite.rpc.js index dc6bcce..71fd54b 100644 --- a/server/api/chatWebsite/chatWebsite.rpc.js +++ b/server/api/chatWebsite/chatWebsite.rpc.js @@ -1 +1 @@ -const a114_0x1d90=['./chatWebsite.socket','register','../../rediscache'];(function(_0x313cc9,_0x1d90a5){const _0x2e5489=function(_0x2a0847){while(--_0x2a0847){_0x313cc9['push'](_0x313cc9['shift']());}};_0x2e5489(++_0x1d90a5);}(a114_0x1d90,0x103));const a114_0x2e54=function(_0x313cc9,_0x1d90a5){_0x313cc9=_0x313cc9-0x0;let _0x2e5489=a114_0x1d90[_0x313cc9];return _0x2e5489;};const _0x40d3ad=a114_0x2e54;'use strict';const {getSocket}=require(_0x40d3ad('0x1')),socket=getSocket();require(_0x40d3ad('0x2'))[_0x40d3ad('0x0')](socket); \ No newline at end of file +const a114_0x2bd0=['../../rediscache','./chatWebsite.socket','register'];(function(_0x4c05ef,_0x2bd01b){const _0x1770ca=function(_0x19c4cb){while(--_0x19c4cb){_0x4c05ef['push'](_0x4c05ef['shift']());}};_0x1770ca(++_0x2bd01b);}(a114_0x2bd0,0xfc));const a114_0x1770=function(_0x4c05ef,_0x2bd01b){_0x4c05ef=_0x4c05ef-0x0;let _0x1770ca=a114_0x2bd0[_0x4c05ef];return _0x1770ca;};const _0x2b9ae4=a114_0x1770;'use strict';const {getSocket}=require(_0x2b9ae4('0x0')),socket=getSocket();require(_0x2b9ae4('0x1'))[_0x2b9ae4('0x2')](socket); \ No newline at end of file diff --git a/server/api/chatWebsite/chatWebsite.socket.js b/server/api/chatWebsite/chatWebsite.socket.js index bfb7ac8..ca76cf1 100644 --- a/server/api/chatWebsite/chatWebsite.socket.js +++ b/server/api/chatWebsite/chatWebsite.socket.js @@ -1 +1 @@ -const a115_0x5a56=['save','remove','register','chatWebsite:','emit','length'];(function(_0x571380,_0x5a5694){const _0x2b3389=function(_0x2435c8){while(--_0x2435c8){_0x571380['push'](_0x571380['shift']());}};_0x2b3389(++_0x5a5694);}(a115_0x5a56,0x154));const a115_0x2b33=function(_0x571380,_0x5a5694){_0x571380=_0x571380-0x0;let _0x2b3389=a115_0x5a56[_0x571380];return _0x2b3389;};const _0x3ca54c=a115_0x2b33;'use strict';const ChatWebsiteEvents=require('./chatWebsite.events'),events=[_0x3ca54c('0x2'),_0x3ca54c('0x3'),'update'];function createListener(_0x2435c8,_0x2e20a2){return function(_0x4dc221){const _0x10d621=a115_0x2b33;_0x2e20a2[_0x10d621('0x0')](_0x2435c8,_0x4dc221);};}exports[_0x3ca54c('0x4')]=function(_0x3550ca){const _0x3d2509=_0x3ca54c;for(let _0x18a649=0x0,_0x37d4d3=events[_0x3d2509('0x1')];_0x18a649<_0x37d4d3;_0x18a649++){const _0x5e14af=events[_0x18a649],_0x5791f8=createListener(_0x3d2509('0x5')+_0x5e14af,_0x3550ca);ChatWebsiteEvents['on'](_0x5e14af,_0x5791f8);}}; \ No newline at end of file +const a115_0x1b54=['./chatWebsite.events','emit','update','remove','chatWebsite:','save','length','register'];(function(_0x574060,_0x1b54b1){const _0x5efc87=function(_0x46efc4){while(--_0x46efc4){_0x574060['push'](_0x574060['shift']());}};_0x5efc87(++_0x1b54b1);}(a115_0x1b54,0x1ad));const a115_0x5efc=function(_0x574060,_0x1b54b1){_0x574060=_0x574060-0x0;let _0x5efc87=a115_0x1b54[_0x574060];return _0x5efc87;};const _0x26f007=a115_0x5efc;'use strict';const ChatWebsiteEvents=require(_0x26f007('0x3')),events=[_0x26f007('0x0'),_0x26f007('0x6'),_0x26f007('0x5')];function createListener(_0x46efc4,_0x3b4276){return function(_0x166a5c){const _0x492d67=a115_0x5efc;_0x3b4276[_0x492d67('0x4')](_0x46efc4,_0x166a5c);};}exports[_0x26f007('0x2')]=function(_0x47ef42){const _0x53895e=_0x26f007;for(let _0x1c38f5=0x0,_0x1477ae=events[_0x53895e('0x1')];_0x1c38f5<_0x1477ae;_0x1c38f5++){const _0x2dbd57=events[_0x1c38f5],_0xb4173c=createListener(_0x53895e('0x7')+_0x2dbd57,_0x47ef42);ChatWebsiteEvents['on'](_0x2dbd57,_0xb4173c);}}; \ No newline at end of file diff --git a/server/api/chatWebsite/index.js b/server/api/chatWebsite/index.js index 32ac65c..2361425 100644 --- a/server/api/chatWebsite/index.js +++ b/server/api/chatWebsite/index.js @@ -1 +1 @@ -const a116_0x52fe=['removeDispositions','/:id/canned_answers','/:id/offline','exports','removeAgents','/:id/avatar','removeAnswers','addLogo','index','getLogo','/:id/proactive_actions','avatars','./chatWebsite.controller','/:id/users','/:id/customer_avatar','addCustomerAvatar','getApplications','join','../../components/auth/service','addAnswer','get','create','offline','getSystemAvatar','file','post','getOfflineMessages','show','addSystemAvatar','getAnswers','format','put','addDisposition','util','addInteraction','/:id','files/images/','originalname','/:id/dispositions','notify','/:id/interactions','getProactiveActions','root','/describe','express','now','/:id/logo','Router','%s-%s','delete','single','/:id/offline_messages','getAvatar','isAuthenticated','/:id/system_avatar','/:id/snippet','update','/:id/notify','multer','diskStorage','../../config/environment','/:id/applications'];(function(_0x2e51d0,_0x52feb1){const _0x3940db=function(_0x5bd1f9){while(--_0x5bd1f9){_0x2e51d0['push'](_0x2e51d0['shift']());}};_0x3940db(++_0x52feb1);}(a116_0x52fe,0x1d4));const a116_0x3940=function(_0x2e51d0,_0x52feb1){_0x2e51d0=_0x2e51d0-0x0;let _0x3940db=a116_0x52fe[_0x2e51d0];return _0x3940db;};const _0x569c21=a116_0x3940;'use strict';const multer=require(_0x569c21('0x18')),util=require(_0x569c21('0x3d')),path=require('path'),express=require(_0x569c21('0xa')),router=express[_0x569c21('0xd')](),auth=require(_0x569c21('0x2e')),config=require(_0x569c21('0x1a')),controller=require(_0x569c21('0x28')),upload=_0x5bd1f9=>multer({'storage':multer[_0x569c21('0x19')]({'destination':function(_0x5c4937,_0x40f82e,_0x54f4e7){const _0x176ec7=_0x569c21;_0x54f4e7(null,path[_0x176ec7('0x2d')](config[_0x176ec7('0x8')],_0x176ec7('0x2'),_0x5bd1f9));},'filename':function(_0x4ab4cd,_0x31bf74,_0xf78c26){const _0x316e0a=_0x569c21;_0xf78c26(null,util[_0x316e0a('0x3a')](_0x316e0a('0xe'),Date[_0x316e0a('0xb')](),_0x31bf74[_0x316e0a('0x3')]));}})});router[_0x569c21('0x30')]('/',auth['isAuthenticated'](),controller[_0x569c21('0x24')]),router[_0x569c21('0x30')](_0x569c21('0x9'),auth[_0x569c21('0x13')](),controller['describe']),router[_0x569c21('0x30')](_0x569c21('0x1'),auth['isAuthenticated'](),controller[_0x569c21('0x37')]),router[_0x569c21('0x30')]('/:id/dispositions',auth[_0x569c21('0x13')](),controller['getDispositions']),router[_0x569c21('0x30')](_0x569c21('0x1d'),auth['isAuthenticated'](),controller[_0x569c21('0x39')]),router[_0x569c21('0x30')](_0x569c21('0xc'),controller[_0x569c21('0x25')]),router[_0x569c21('0x30')](_0x569c21('0x21'),controller[_0x569c21('0x12')]),router[_0x569c21('0x30')](_0x569c21('0x2a'),controller['getCustomerAvatar']),router['get']('/:id/system_avatar',controller[_0x569c21('0x33')]),router['get'](_0x569c21('0x6'),auth[_0x569c21('0x13')](),controller['getInteractions']),router['get'](_0x569c21('0x15'),controller['getSnippet']),router['get'](_0x569c21('0x1b'),auth[_0x569c21('0x13')](),controller[_0x569c21('0x2c')]),router[_0x569c21('0x30')]('/:id/proactive_actions',auth[_0x569c21('0x13')](),controller[_0x569c21('0x7')]),router[_0x569c21('0x30')]('/:id/fields',controller['getFields']),router[_0x569c21('0x30')](_0x569c21('0x11'),auth[_0x569c21('0x13')](),controller[_0x569c21('0x36')]),router[_0x569c21('0x30')](_0x569c21('0x29'),auth[_0x569c21('0x13')](),controller['getAgents']),router['post']('/',auth['isAuthenticated'](),controller[_0x569c21('0x31')]),router[_0x569c21('0x35')](_0x569c21('0x4'),auth[_0x569c21('0x13')](),controller[_0x569c21('0x3c')]),router[_0x569c21('0x35')](_0x569c21('0x1d'),auth[_0x569c21('0x13')](),controller[_0x569c21('0x2f')]),router[_0x569c21('0x35')](_0x569c21('0xc'),upload('logos')['single'](_0x569c21('0x34')),controller[_0x569c21('0x23')]),router[_0x569c21('0x35')](_0x569c21('0x21'),upload(_0x569c21('0x27'))[_0x569c21('0x10')](_0x569c21('0x34')),controller['addAvatar']),router['post']('/:id/customer_avatar',upload('avatars')[_0x569c21('0x10')](_0x569c21('0x34')),controller[_0x569c21('0x2b')]),router[_0x569c21('0x35')](_0x569c21('0x14'),upload(_0x569c21('0x27'))[_0x569c21('0x10')](_0x569c21('0x34')),controller[_0x569c21('0x38')]),router[_0x569c21('0x35')](_0x569c21('0x17'),controller[_0x569c21('0x5')]),router[_0x569c21('0x35')](_0x569c21('0x1e'),controller[_0x569c21('0x32')]),router[_0x569c21('0x35')]('/:id/interactions',auth['isAuthenticated'](),controller[_0x569c21('0x0')]),router['post']('/:id/applications',auth[_0x569c21('0x13')](),controller['addApplications']),router[_0x569c21('0x35')](_0x569c21('0x26'),auth[_0x569c21('0x13')](),controller['addProactiveActions']),router[_0x569c21('0x35')]('/:id/users',auth[_0x569c21('0x13')](),controller['addAgents']),router[_0x569c21('0x3b')](_0x569c21('0x1'),auth['isAuthenticated'](),controller[_0x569c21('0x16')]),router[_0x569c21('0xf')](_0x569c21('0x1'),auth[_0x569c21('0x13')](),controller['destroy']),router[_0x569c21('0xf')](_0x569c21('0x4'),auth[_0x569c21('0x13')](),controller[_0x569c21('0x1c')]),router[_0x569c21('0xf')](_0x569c21('0x1d'),auth[_0x569c21('0x13')](),controller[_0x569c21('0x22')]),router[_0x569c21('0xf')](_0x569c21('0x29'),auth[_0x569c21('0x13')](),controller[_0x569c21('0x20')]),module[_0x569c21('0x1f')]=router; \ No newline at end of file +const a116_0x122c=['describe','multer','getInteractions','addCustomerAvatar','path','exports','addAnswer','/:id/interactions','%s-%s','originalname','/:id/fields','getSystemAvatar','destroy','offline','getCustomerAvatar','/:id/canned_answers','/:id','removeDispositions','addProactiveActions','addAgents','diskStorage','addLogo','../../components/auth/service','avatars','getLogo','/:id/snippet','/:id/proactive_actions','file','/:id/logo','/:id/applications','index','logos','getOfflineMessages','removeAgents','post','/:id/avatar','/:id/offline_messages','root','update','/:id/customer_avatar','../../config/environment','Router','/:id/users','format','join','getAvatar','get','getProactiveActions','addApplications','/describe','single','/:id/notify','removeAnswers','/:id/system_avatar','getApplications','isAuthenticated','/:id/dispositions','show','delete','getAnswers'];(function(_0x464319,_0x122caf){const _0x476037=function(_0x1f1c7a){while(--_0x1f1c7a){_0x464319['push'](_0x464319['shift']());}};_0x476037(++_0x122caf);}(a116_0x122c,0xdb));const a116_0x4760=function(_0x464319,_0x122caf){_0x464319=_0x464319-0x0;let _0x476037=a116_0x122c[_0x464319];return _0x476037;};const _0x5e4352=a116_0x4760;'use strict';const multer=require(_0x5e4352('0x16')),util=require('util'),path=require(_0x5e4352('0x19')),express=require('express'),router=express[_0x5e4352('0x2')](),auth=require(_0x5e4352('0x2b')),config=require(_0x5e4352('0x1')),controller=require('./chatWebsite.controller'),upload=_0x1f1c7a=>multer({'storage':multer[_0x5e4352('0x29')]({'destination':function(_0x277205,_0x2e7292,_0x53240d){const _0xca1977=_0x5e4352;_0x53240d(null,path[_0xca1977('0x5')](config[_0xca1977('0x3a')],'files/images/',_0x1f1c7a));},'filename':function(_0x373072,_0x4fd390,_0x289a65){const _0x5061fd=_0x5e4352;_0x289a65(null,util[_0x5061fd('0x4')](_0x5061fd('0x1d'),Date['now'](),_0x4fd390[_0x5061fd('0x1e')]));}})});router['get']('/',auth['isAuthenticated'](),controller[_0x5e4352('0x33')]),router[_0x5e4352('0x7')](_0x5e4352('0xa'),auth[_0x5e4352('0x10')](),controller[_0x5e4352('0x15')]),router[_0x5e4352('0x7')](_0x5e4352('0x25'),auth[_0x5e4352('0x10')](),controller[_0x5e4352('0x12')]),router[_0x5e4352('0x7')](_0x5e4352('0x11'),auth[_0x5e4352('0x10')](),controller['getDispositions']),router[_0x5e4352('0x7')](_0x5e4352('0x24'),auth[_0x5e4352('0x10')](),controller[_0x5e4352('0x14')]),router[_0x5e4352('0x7')](_0x5e4352('0x31'),controller[_0x5e4352('0x2d')]),router[_0x5e4352('0x7')](_0x5e4352('0x38'),controller[_0x5e4352('0x6')]),router[_0x5e4352('0x7')](_0x5e4352('0x0'),controller[_0x5e4352('0x23')]),router[_0x5e4352('0x7')](_0x5e4352('0xe'),controller[_0x5e4352('0x20')]),router[_0x5e4352('0x7')]('/:id/interactions',auth[_0x5e4352('0x10')](),controller[_0x5e4352('0x17')]),router[_0x5e4352('0x7')](_0x5e4352('0x2e'),controller['getSnippet']),router['get'](_0x5e4352('0x32'),auth['isAuthenticated'](),controller[_0x5e4352('0xf')]),router[_0x5e4352('0x7')](_0x5e4352('0x2f'),auth['isAuthenticated'](),controller[_0x5e4352('0x8')]),router[_0x5e4352('0x7')](_0x5e4352('0x1f'),controller['getFields']),router[_0x5e4352('0x7')](_0x5e4352('0x39'),auth[_0x5e4352('0x10')](),controller[_0x5e4352('0x35')]),router['get']('/:id/users',auth[_0x5e4352('0x10')](),controller['getAgents']),router[_0x5e4352('0x37')]('/',auth[_0x5e4352('0x10')](),controller['create']),router[_0x5e4352('0x37')](_0x5e4352('0x11'),auth['isAuthenticated'](),controller['addDisposition']),router['post'](_0x5e4352('0x24'),auth['isAuthenticated'](),controller[_0x5e4352('0x1b')]),router[_0x5e4352('0x37')](_0x5e4352('0x31'),upload(_0x5e4352('0x34'))[_0x5e4352('0xb')](_0x5e4352('0x30')),controller[_0x5e4352('0x2a')]),router[_0x5e4352('0x37')](_0x5e4352('0x38'),upload(_0x5e4352('0x2c'))[_0x5e4352('0xb')]('file'),controller['addAvatar']),router[_0x5e4352('0x37')]('/:id/customer_avatar',upload(_0x5e4352('0x2c'))[_0x5e4352('0xb')](_0x5e4352('0x30')),controller[_0x5e4352('0x18')]),router[_0x5e4352('0x37')](_0x5e4352('0xe'),upload(_0x5e4352('0x2c'))['single'](_0x5e4352('0x30')),controller['addSystemAvatar']),router['post'](_0x5e4352('0xc'),controller['notify']),router[_0x5e4352('0x37')]('/:id/offline',controller[_0x5e4352('0x22')]),router[_0x5e4352('0x37')](_0x5e4352('0x1c'),auth[_0x5e4352('0x10')](),controller['addInteraction']),router[_0x5e4352('0x37')](_0x5e4352('0x32'),auth['isAuthenticated'](),controller[_0x5e4352('0x9')]),router[_0x5e4352('0x37')]('/:id/proactive_actions',auth['isAuthenticated'](),controller[_0x5e4352('0x27')]),router['post'](_0x5e4352('0x3'),auth['isAuthenticated'](),controller[_0x5e4352('0x28')]),router['put'](_0x5e4352('0x25'),auth[_0x5e4352('0x10')](),controller[_0x5e4352('0x3b')]),router[_0x5e4352('0x13')](_0x5e4352('0x25'),auth[_0x5e4352('0x10')](),controller[_0x5e4352('0x21')]),router[_0x5e4352('0x13')]('/:id/dispositions',auth[_0x5e4352('0x10')](),controller[_0x5e4352('0x26')]),router['delete'](_0x5e4352('0x24'),auth['isAuthenticated'](),controller[_0x5e4352('0xd')]),router[_0x5e4352('0x13')](_0x5e4352('0x3'),auth[_0x5e4352('0x10')](),controller[_0x5e4352('0x36')]),module[_0x5e4352('0x1a')]=router; \ No newline at end of file diff --git a/server/api/cloudProvider/cloudProvider.attributes.js b/server/api/cloudProvider/cloudProvider.attributes.js index bcc817e..5418950 100644 --- a/server/api/cloudProvider/cloudProvider.attributes.js +++ b/server/api/cloudProvider/cloudProvider.attributes.js @@ -1 +1 @@ -const a117_0x3ec0=['exports','STRING','sequelize'];(function(_0x2e4498,_0x3ec065){const _0x4bfae5=function(_0x3368e6){while(--_0x3368e6){_0x2e4498['push'](_0x2e4498['shift']());}};_0x4bfae5(++_0x3ec065);}(a117_0x3ec0,0xb3));const a117_0x4bfa=function(_0x2e4498,_0x3ec065){_0x2e4498=_0x2e4498-0x0;let _0x4bfae5=a117_0x3ec0[_0x2e4498];return _0x4bfae5;};const _0x90aceb=a117_0x4bfa;'use strict';const Sequelize=require(_0x90aceb('0x0'));module[_0x90aceb('0x1')]={'name':{'type':Sequelize['STRING'],'allowNull':![],'validate':{'notEmpty':!![]}},'service':{'type':Sequelize['ENUM']('AmazonAWS','Google'),'allowNull':![],'validate':{'notEmpty':!![]}},'data1':{'type':Sequelize[_0x90aceb('0x2')]},'data2':{'type':Sequelize[_0x90aceb('0x2')]}}; \ No newline at end of file +const a117_0x5cb8=['STRING','Google','sequelize'];(function(_0x32fdc4,_0x5cb807){const _0x5cef35=function(_0x277fa8){while(--_0x277fa8){_0x32fdc4['push'](_0x32fdc4['shift']());}};_0x5cef35(++_0x5cb807);}(a117_0x5cb8,0x107));const a117_0x5cef=function(_0x32fdc4,_0x5cb807){_0x32fdc4=_0x32fdc4-0x0;let _0x5cef35=a117_0x5cb8[_0x32fdc4];return _0x5cef35;};const _0x46bf74=a117_0x5cef;'use strict';const Sequelize=require(_0x46bf74('0x0'));module['exports']={'name':{'type':Sequelize[_0x46bf74('0x1')],'allowNull':![],'validate':{'notEmpty':!![]}},'service':{'type':Sequelize['ENUM']('AmazonAWS',_0x46bf74('0x2')),'allowNull':![],'validate':{'notEmpty':!![]}},'data1':{'type':Sequelize['STRING']},'data2':{'type':Sequelize[_0x46bf74('0x1')]}}; \ No newline at end of file diff --git a/server/api/cloudProvider/cloudProvider.controller.js b/server/api/cloudProvider/cloudProvider.controller.js index 9d6f7db..d096816 100644 --- a/server/api/cloudProvider/cloudProvider.controller.js +++ b/server/api/cloudProvider/cloudProvider.controller.js @@ -1 +1 @@ -const a118_0x14e6=['catch','merge','api','like','index','error','../../components/parsers/qs','update','sendStatus','filters','params','sort','sequelize','findOne','nolimit','status','set','include','send','rows','fields','keys','json','create','includeAll','filter','attributes','order','Content-Range','offset','name','query','options','length','lodash','count','limit','show','rawAttributes','type','destroy','key','CloudProvider','stack','where','then','intersection','body','findAll','map','model'];(function(_0x39e063,_0x14e662){const _0x1c8b8f=function(_0x2483fe){while(--_0x2483fe){_0x39e063['push'](_0x39e063['shift']());}};_0x1c8b8f(++_0x14e662);}(a118_0x14e6,0x1e1));const a118_0x1c8b=function(_0x39e063,_0x14e662){_0x39e063=_0x39e063-0x0;let _0x1c8b8f=a118_0x14e6[_0x39e063];return _0x1c8b8f;};const _0x1a3fae=a118_0x1c8b;'use strict';const _=require(_0x1a3fae('0xc')),qs=require(_0x1a3fae('0x23')),logger=require('../../config/logger')(_0x1a3fae('0x1f')),db=require('../../mysqldb')['db'],{Op}=require(_0x1a3fae('0x29'));function respondWithResult(_0x2483fe,_0x439fd8){return _0x439fd8=_0x439fd8||0xc8,function(_0x1f71ea){const _0x1b90d0=a118_0x1c8b;if(_0x1f71ea)return _0x2483fe[_0x1b90d0('0x2c')](_0x439fd8)[_0x1b90d0('0x0')](_0x1f71ea);};}function respondWithFilteredResult(_0x2ff588,_0x4783d7){return function(_0x5e61f3){const _0x2a6c3c=a118_0x1c8b;if(_0x5e61f3){const _0x40838e=_0x5e61f3[_0x2a6c3c('0xd')],_0x554128=_0x4783d7[_0x2a6c3c('0x7')];let _0x440142=_0x4783d7[_0x2a6c3c('0x7')]+_0x4783d7[_0x2a6c3c('0xe')],_0x57cff0;return _0x440142>=_0x40838e?(_0x440142=_0x40838e,_0x57cff0=0xc8):_0x57cff0=0xce,_0x2ff588['status'](_0x57cff0),_0x2ff588[_0x2a6c3c('0x2d')](_0x2a6c3c('0x6'),_0x554128+'-'+_0x440142+'/'+_0x40838e)['json'](_0x5e61f3);}return null;};}function saveUpdates(_0x2e2eda){return function(_0x5dd10a){const _0x31cabb=a118_0x1c8b;if(_0x5dd10a)return _0x5dd10a[_0x31cabb('0x24')](_0x2e2eda)[_0x31cabb('0x17')](function(_0x4b26fa){return _0x4b26fa;});return null;};}function removeEntity(_0xfa62b1){return function(_0x85ebf3){const _0x419cd4=a118_0x1c8b;if(_0x85ebf3)return _0x85ebf3[_0x419cd4('0x12')]()[_0x419cd4('0x17')](function(){const _0x24eebc=_0x419cd4;_0xfa62b1[_0x24eebc('0x2c')](0xcc)['end']();});};}function handleEntityNotFound(_0x1ec4c6){return function(_0xe2dce1){const _0x2c7e19=a118_0x1c8b;return!_0xe2dce1&&_0x1ec4c6[_0x2c7e19('0x25')](0x194),_0xe2dce1;};}function handleError(_0x3e7fd3,_0x2b3122){return _0x2b3122=_0x2b3122||0x1f4,function(_0xfd170){const _0x1ebda7=a118_0x1c8b;logger[_0x1ebda7('0x22')](_0xfd170[_0x1ebda7('0x15')]),_0xfd170[_0x1ebda7('0x8')]&&delete _0xfd170[_0x1ebda7('0x8')],_0x3e7fd3['status'](_0x2b3122)[_0x1ebda7('0x2f')](_0xfd170);};}exports[_0x1a3fae('0x21')]=function(_0x1ad811,_0x4bae76){const _0x3f244f=_0x1a3fae;let _0x58df70={};const _0x3aeb7b={},_0x24889a={'count':0x0,'rows':[]},_0x4c00aa=_[_0x3f244f('0x1b')](db[_0x3f244f('0x14')][_0x3f244f('0x10')],function(_0x8822cb){const _0x4cd52b=_0x3f244f;return{'name':_0x8822cb['fieldName'],'type':_0x8822cb[_0x4cd52b('0x11')][_0x4cd52b('0x13')]};});_0x3aeb7b['model']=_[_0x3f244f('0x1b')](_0x4c00aa,'name'),_0x3aeb7b[_0x3f244f('0x9')]=_[_0x3f244f('0x32')](_0x1ad811['query']),_0x3aeb7b['filters']=_['intersection'](_0x3aeb7b['model'],_0x3aeb7b[_0x3f244f('0x9')]),_0x58df70[_0x3f244f('0x4')]=_[_0x3f244f('0x18')](_0x3aeb7b[_0x3f244f('0x1c')],qs[_0x3f244f('0x31')](_0x1ad811[_0x3f244f('0x9')][_0x3f244f('0x31')])),_0x58df70[_0x3f244f('0x4')]=_0x58df70['attributes'][_0x3f244f('0xb')]?_0x58df70[_0x3f244f('0x4')]:_0x3aeb7b['model'];typeof _0x1ad811[_0x3f244f('0x9')][_0x3f244f('0x2b')]==='undefined'&&(_0x58df70[_0x3f244f('0xe')]=qs[_0x3f244f('0xe')](_0x1ad811[_0x3f244f('0x9')][_0x3f244f('0xe')]),_0x58df70[_0x3f244f('0x7')]=qs[_0x3f244f('0x7')](_0x1ad811['query'][_0x3f244f('0x7')]));_0x58df70[_0x3f244f('0x5')]=qs[_0x3f244f('0x28')](_0x1ad811['query'][_0x3f244f('0x28')]),_0x58df70[_0x3f244f('0x16')]=qs[_0x3f244f('0x26')](_['pick'](_0x1ad811[_0x3f244f('0x9')],_0x3aeb7b[_0x3f244f('0x26')]),_0x4c00aa);_0x1ad811['query'][_0x3f244f('0x3')]&&(_0x58df70[_0x3f244f('0x16')]=_[_0x3f244f('0x1e')](_0x58df70['where'],{[Op['or']]:_[_0x3f244f('0x1b')](_0x4c00aa,function(_0x95b778){const _0x373a44=_0x3f244f;if(_0x95b778[_0x373a44('0x11')]!=='VIRTUAL'){const _0xe841cb={};return _0xe841cb[_0x95b778[_0x373a44('0x8')]]={[Op[_0x373a44('0x20')]]:'%'+_0x1ad811[_0x373a44('0x9')][_0x373a44('0x3')]+'%'},_0xe841cb;}})}));_0x58df70=_[_0x3f244f('0x1e')]({},_0x58df70,_0x1ad811[_0x3f244f('0xa')]);const _0x3b987a={'where':_0x58df70[_0x3f244f('0x16')]};return db[_0x3f244f('0x14')][_0x3f244f('0xd')](_0x3b987a)['then'](function(_0x3aadad){const _0x4ce00d=_0x3f244f;return _0x24889a['count']=_0x3aadad,_0x1ad811[_0x4ce00d('0x9')][_0x4ce00d('0x2')]&&(_0x58df70[_0x4ce00d('0x2e')]=[{'all':!![]}]),db['CloudProvider'][_0x4ce00d('0x1a')](_0x58df70);})[_0x3f244f('0x17')](function(_0x570458){const _0x4ecdc9=_0x3f244f;return _0x24889a[_0x4ecdc9('0x30')]=_0x570458,_0x24889a;})[_0x3f244f('0x17')](respondWithFilteredResult(_0x4bae76,_0x58df70))['catch'](handleError(_0x4bae76,null));},exports[_0x1a3fae('0xf')]=function(_0x5be6db,_0x3d682c){const _0x10f21b=_0x1a3fae;let _0x32ac10={'raw':!![],'where':{'id':_0x5be6db[_0x10f21b('0x27')]['id']}};const _0x2611f2={};return _0x2611f2[_0x10f21b('0x1c')]=_[_0x10f21b('0x32')](db[_0x10f21b('0x14')]['rawAttributes']),_0x2611f2[_0x10f21b('0x9')]=_[_0x10f21b('0x32')](_0x5be6db[_0x10f21b('0x9')]),_0x2611f2[_0x10f21b('0x26')]=_['intersection'](_0x2611f2[_0x10f21b('0x1c')],_0x2611f2[_0x10f21b('0x9')]),_0x32ac10[_0x10f21b('0x4')]=_[_0x10f21b('0x18')](_0x2611f2['model'],qs['fields'](_0x5be6db[_0x10f21b('0x9')][_0x10f21b('0x31')])),_0x32ac10[_0x10f21b('0x4')]=_0x32ac10['attributes'][_0x10f21b('0xb')]?_0x32ac10[_0x10f21b('0x4')]:_0x2611f2[_0x10f21b('0x1c')],_0x5be6db['query'][_0x10f21b('0x2')]&&(_0x32ac10[_0x10f21b('0x2e')]=[{'all':!![]}]),_0x32ac10=_[_0x10f21b('0x1e')]({},_0x32ac10,_0x5be6db[_0x10f21b('0xa')]),db['CloudProvider']['findOne'](_0x32ac10)[_0x10f21b('0x17')](handleEntityNotFound(_0x3d682c,null))[_0x10f21b('0x17')](respondWithResult(_0x3d682c,null))[_0x10f21b('0x1d')](handleError(_0x3d682c,null));},exports[_0x1a3fae('0x1')]=function(_0x1fa185,_0x2e7be1){const _0x3b0182=_0x1a3fae;return db[_0x3b0182('0x14')]['create'](_0x1fa185[_0x3b0182('0x19')],{})[_0x3b0182('0x17')](respondWithResult(_0x2e7be1,0xc9))[_0x3b0182('0x1d')](handleError(_0x2e7be1,null));},exports[_0x1a3fae('0x24')]=function(_0x57c5ae,_0x53e27d){const _0x270418=_0x1a3fae;return _0x57c5ae[_0x270418('0x19')]['id']&&delete _0x57c5ae[_0x270418('0x19')]['id'],db['CloudProvider']['findOne']({'where':{'id':_0x57c5ae[_0x270418('0x27')]['id']}})[_0x270418('0x17')](handleEntityNotFound(_0x53e27d,null))['then'](saveUpdates(_0x57c5ae['body'],null))[_0x270418('0x17')](respondWithResult(_0x53e27d,null))['catch'](handleError(_0x53e27d,null));},exports[_0x1a3fae('0x12')]=function(_0xaadb70,_0x223fa9){const _0x377eee=_0x1a3fae;return db[_0x377eee('0x14')][_0x377eee('0x2a')]({'where':{'id':_0xaadb70[_0x377eee('0x27')]['id']}})[_0x377eee('0x17')](handleEntityNotFound(_0x223fa9,null))['then'](removeEntity(_0x223fa9,null))[_0x377eee('0x1d')](handleError(_0x223fa9,null));}; \ No newline at end of file +const a118_0xf33b=['json','keys','intersection','nolimit','create','include','order','key','findOne','sort','fieldName','sequelize','sendStatus','options','../../config/logger','set','rawAttributes','count','stack','fields','params','query','where','CloudProvider','offset','../../components/parsers/qs','then','limit','api','update','map','length','catch','status','Content-Range','destroy','error','pick','attributes','../../mysqldb','undefined','VIRTUAL','lodash','index','filter','filters','name','body','end','model','includeAll','merge'];(function(_0x13a7d1,_0xf33b28){const _0x2f7c2f=function(_0x463d20){while(--_0x463d20){_0x13a7d1['push'](_0x13a7d1['shift']());}};_0x2f7c2f(++_0xf33b28);}(a118_0xf33b,0x1f2));const a118_0x2f7c=function(_0x13a7d1,_0xf33b28){_0x13a7d1=_0x13a7d1-0x0;let _0x2f7c2f=a118_0xf33b[_0x13a7d1];return _0x2f7c2f;};const _0x3c8d7d=a118_0x2f7c;'use strict';const _=require(_0x3c8d7d('0xc')),qs=require(_0x3c8d7d('0x2f')),logger=require(_0x3c8d7d('0x24'))(_0x3c8d7d('0x32')),db=require(_0x3c8d7d('0x9'))['db'],{Op}=require(_0x3c8d7d('0x21'));function respondWithResult(_0x463d20,_0x111413){return _0x111413=_0x111413||0xc8,function(_0x525372){if(_0x525372)return _0x463d20['status'](_0x111413)['json'](_0x525372);};}function respondWithFilteredResult(_0x5060c9,_0x2bb739){return function(_0x316dd7){const _0x2033f7=a118_0x2f7c;if(_0x316dd7){const _0x56cefc=_0x316dd7['count'],_0x334cfd=_0x2bb739['offset'];let _0x19cff6=_0x2bb739[_0x2033f7('0x2e')]+_0x2bb739[_0x2033f7('0x31')],_0x3182eb;return _0x19cff6>=_0x56cefc?(_0x19cff6=_0x56cefc,_0x3182eb=0xc8):_0x3182eb=0xce,_0x5060c9[_0x2033f7('0x3')](_0x3182eb),_0x5060c9[_0x2033f7('0x25')](_0x2033f7('0x4'),_0x334cfd+'-'+_0x19cff6+'/'+_0x56cefc)[_0x2033f7('0x16')](_0x316dd7);}return null;};}function saveUpdates(_0x16d13a){return function(_0x258da6){const _0x2a83aa=a118_0x2f7c;if(_0x258da6)return _0x258da6['update'](_0x16d13a)[_0x2a83aa('0x30')](function(_0x784ceb){return _0x784ceb;});return null;};}function removeEntity(_0x1e11e1){return function(_0x57679c){const _0x3fd980=a118_0x2f7c;if(_0x57679c)return _0x57679c[_0x3fd980('0x5')]()[_0x3fd980('0x30')](function(){const _0x35213f=_0x3fd980;_0x1e11e1[_0x35213f('0x3')](0xcc)[_0x35213f('0x12')]();});};}function handleEntityNotFound(_0x1379fc){return function(_0x4c4876){const _0x455b60=a118_0x2f7c;return!_0x4c4876&&_0x1379fc[_0x455b60('0x22')](0x194),_0x4c4876;};}function handleError(_0x1beba0,_0x1ee9dc){return _0x1ee9dc=_0x1ee9dc||0x1f4,function(_0x710275){const _0xda080c=a118_0x2f7c;logger[_0xda080c('0x6')](_0x710275[_0xda080c('0x28')]),_0x710275[_0xda080c('0x10')]&&delete _0x710275[_0xda080c('0x10')],_0x1beba0[_0xda080c('0x3')](_0x1ee9dc)['send'](_0x710275);};}exports[_0x3c8d7d('0xd')]=function(_0xbbc2a8,_0x460a03){const _0x2cf616=_0x3c8d7d;let _0x4b1fdd={};const _0xc1af4f={},_0x2a9594={'count':0x0,'rows':[]},_0x366398=_[_0x2cf616('0x0')](db[_0x2cf616('0x2d')]['rawAttributes'],function(_0x16d966){const _0x314961=_0x2cf616;return{'name':_0x16d966[_0x314961('0x20')],'type':_0x16d966['type'][_0x314961('0x1d')]};});_0xc1af4f[_0x2cf616('0x13')]=_[_0x2cf616('0x0')](_0x366398,_0x2cf616('0x10')),_0xc1af4f['query']=_['keys'](_0xbbc2a8[_0x2cf616('0x2b')]),_0xc1af4f['filters']=_[_0x2cf616('0x18')](_0xc1af4f[_0x2cf616('0x13')],_0xc1af4f['query']),_0x4b1fdd[_0x2cf616('0x8')]=_[_0x2cf616('0x18')](_0xc1af4f[_0x2cf616('0x13')],qs[_0x2cf616('0x29')](_0xbbc2a8['query'][_0x2cf616('0x29')])),_0x4b1fdd[_0x2cf616('0x8')]=_0x4b1fdd['attributes'][_0x2cf616('0x1')]?_0x4b1fdd['attributes']:_0xc1af4f[_0x2cf616('0x13')];typeof _0xbbc2a8['query'][_0x2cf616('0x19')]===_0x2cf616('0xa')&&(_0x4b1fdd['limit']=qs[_0x2cf616('0x31')](_0xbbc2a8[_0x2cf616('0x2b')][_0x2cf616('0x31')]),_0x4b1fdd[_0x2cf616('0x2e')]=qs[_0x2cf616('0x2e')](_0xbbc2a8[_0x2cf616('0x2b')]['offset']));_0x4b1fdd[_0x2cf616('0x1c')]=qs[_0x2cf616('0x1f')](_0xbbc2a8[_0x2cf616('0x2b')][_0x2cf616('0x1f')]),_0x4b1fdd[_0x2cf616('0x2c')]=qs[_0x2cf616('0xf')](_[_0x2cf616('0x7')](_0xbbc2a8[_0x2cf616('0x2b')],_0xc1af4f[_0x2cf616('0xf')]),_0x366398);_0xbbc2a8[_0x2cf616('0x2b')][_0x2cf616('0xe')]&&(_0x4b1fdd[_0x2cf616('0x2c')]=_[_0x2cf616('0x15')](_0x4b1fdd[_0x2cf616('0x2c')],{[Op['or']]:_['map'](_0x366398,function(_0x1ac4f1){const _0x43bd40=_0x2cf616;if(_0x1ac4f1['type']!==_0x43bd40('0xb')){const _0x474181={};return _0x474181[_0x1ac4f1[_0x43bd40('0x10')]]={[Op['like']]:'%'+_0xbbc2a8[_0x43bd40('0x2b')][_0x43bd40('0xe')]+'%'},_0x474181;}})}));_0x4b1fdd=_[_0x2cf616('0x15')]({},_0x4b1fdd,_0xbbc2a8[_0x2cf616('0x23')]);const _0x3e84f6={'where':_0x4b1fdd[_0x2cf616('0x2c')]};return db[_0x2cf616('0x2d')][_0x2cf616('0x27')](_0x3e84f6)[_0x2cf616('0x30')](function(_0xf2496){const _0x624872=_0x2cf616;return _0x2a9594[_0x624872('0x27')]=_0xf2496,_0xbbc2a8['query'][_0x624872('0x14')]&&(_0x4b1fdd[_0x624872('0x1b')]=[{'all':!![]}]),db[_0x624872('0x2d')]['findAll'](_0x4b1fdd);})[_0x2cf616('0x30')](function(_0x279bda){return _0x2a9594['rows']=_0x279bda,_0x2a9594;})['then'](respondWithFilteredResult(_0x460a03,_0x4b1fdd))[_0x2cf616('0x2')](handleError(_0x460a03,null));},exports['show']=function(_0x51c42f,_0x566086){const _0x43fef1=_0x3c8d7d;let _0x58216e={'raw':!![],'where':{'id':_0x51c42f['params']['id']}};const _0x33ea31={};return _0x33ea31[_0x43fef1('0x13')]=_[_0x43fef1('0x17')](db[_0x43fef1('0x2d')][_0x43fef1('0x26')]),_0x33ea31[_0x43fef1('0x2b')]=_[_0x43fef1('0x17')](_0x51c42f[_0x43fef1('0x2b')]),_0x33ea31[_0x43fef1('0xf')]=_[_0x43fef1('0x18')](_0x33ea31[_0x43fef1('0x13')],_0x33ea31[_0x43fef1('0x2b')]),_0x58216e[_0x43fef1('0x8')]=_[_0x43fef1('0x18')](_0x33ea31[_0x43fef1('0x13')],qs[_0x43fef1('0x29')](_0x51c42f[_0x43fef1('0x2b')][_0x43fef1('0x29')])),_0x58216e['attributes']=_0x58216e[_0x43fef1('0x8')][_0x43fef1('0x1')]?_0x58216e[_0x43fef1('0x8')]:_0x33ea31['model'],_0x51c42f['query'][_0x43fef1('0x14')]&&(_0x58216e[_0x43fef1('0x1b')]=[{'all':!![]}]),_0x58216e=_[_0x43fef1('0x15')]({},_0x58216e,_0x51c42f[_0x43fef1('0x23')]),db[_0x43fef1('0x2d')][_0x43fef1('0x1e')](_0x58216e)['then'](handleEntityNotFound(_0x566086,null))[_0x43fef1('0x30')](respondWithResult(_0x566086,null))[_0x43fef1('0x2')](handleError(_0x566086,null));},exports[_0x3c8d7d('0x1a')]=function(_0x543ebd,_0x2d5061){const _0x47e5b4=_0x3c8d7d;return db[_0x47e5b4('0x2d')]['create'](_0x543ebd[_0x47e5b4('0x11')],{})['then'](respondWithResult(_0x2d5061,0xc9))[_0x47e5b4('0x2')](handleError(_0x2d5061,null));},exports[_0x3c8d7d('0x33')]=function(_0x5c5c50,_0x314b7f){const _0x144199=_0x3c8d7d;return _0x5c5c50[_0x144199('0x11')]['id']&&delete _0x5c5c50[_0x144199('0x11')]['id'],db['CloudProvider'][_0x144199('0x1e')]({'where':{'id':_0x5c5c50[_0x144199('0x2a')]['id']}})['then'](handleEntityNotFound(_0x314b7f,null))[_0x144199('0x30')](saveUpdates(_0x5c5c50[_0x144199('0x11')],null))['then'](respondWithResult(_0x314b7f,null))[_0x144199('0x2')](handleError(_0x314b7f,null));},exports['destroy']=function(_0x4cffab,_0x39d33e){const _0x34a01b=_0x3c8d7d;return db[_0x34a01b('0x2d')][_0x34a01b('0x1e')]({'where':{'id':_0x4cffab[_0x34a01b('0x2a')]['id']}})['then'](handleEntityNotFound(_0x39d33e,null))[_0x34a01b('0x30')](removeEntity(_0x39d33e,null))[_0x34a01b('0x2')](handleError(_0x39d33e,null));}; \ No newline at end of file diff --git a/server/api/cloudProvider/cloudProvider.model.js b/server/api/cloudProvider/cloudProvider.model.js index b579ea0..55f5c25 100644 --- a/server/api/cloudProvider/cloudProvider.model.js +++ b/server/api/cloudProvider/cloudProvider.model.js @@ -1 +1 @@ -const a119_0x573e=['exports','define','cloud_providers','./cloudProvider.attributes'];(function(_0x4bc5ee,_0x573e68){const _0xb64f24=function(_0x14d7c4){while(--_0x14d7c4){_0x4bc5ee['push'](_0x4bc5ee['shift']());}};_0xb64f24(++_0x573e68);}(a119_0x573e,0x1b9));const a119_0xb64f=function(_0x4bc5ee,_0x573e68){_0x4bc5ee=_0x4bc5ee-0x0;let _0xb64f24=a119_0x573e[_0x4bc5ee];return _0xb64f24;};const _0x189452=a119_0xb64f;'use strict';const attributes=require(_0x189452('0x2'));module[_0x189452('0x3')]=function(_0x14d7c4){const _0x48ed46=_0x189452,_0x5055d1=_0x14d7c4[_0x48ed46('0x0')]('CloudProvider',attributes,{'tableName':_0x48ed46('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5055d1;}; \ No newline at end of file +const a119_0x23db=['define','cloud_providers','CloudProvider','exports'];(function(_0x284b2f,_0x23dbd6){const _0x475299=function(_0x40c828){while(--_0x40c828){_0x284b2f['push'](_0x284b2f['shift']());}};_0x475299(++_0x23dbd6);}(a119_0x23db,0x8a));const a119_0x4752=function(_0x284b2f,_0x23dbd6){_0x284b2f=_0x284b2f-0x0;let _0x475299=a119_0x23db[_0x284b2f];return _0x475299;};const _0x3acd3c=a119_0x4752;'use strict';const attributes=require('./cloudProvider.attributes');module[_0x3acd3c('0x1')]=function(_0x40c828){const _0x59d479=_0x3acd3c,_0xab481=_0x40c828[_0x59d479('0x2')](_0x59d479('0x0'),attributes,{'tableName':_0x59d479('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xab481;}; \ No newline at end of file diff --git a/server/api/cloudProvider/index.js b/server/api/cloudProvider/index.js index 9432da7..fedba21 100644 --- a/server/api/cloudProvider/index.js +++ b/server/api/cloudProvider/index.js @@ -1 +1 @@ -const a120_0x1655=['exports','create','delete','post','isAuthenticated','/:id','../../components/auth/service','put','destroy','get','./cloudProvider.controller','express','index','Router'];(function(_0x3b6e31,_0x1655ae){const _0x3c6455=function(_0x4c2e8b){while(--_0x4c2e8b){_0x3b6e31['push'](_0x3b6e31['shift']());}};_0x3c6455(++_0x1655ae);}(a120_0x1655,0x1a1));const a120_0x3c64=function(_0x3b6e31,_0x1655ae){_0x3b6e31=_0x3b6e31-0x0;let _0x3c6455=a120_0x1655[_0x3b6e31];return _0x3c6455;};const _0x32037d=a120_0x3c64;'use strict';const express=require(_0x32037d('0x0')),router=express[_0x32037d('0x2')](),auth=require(_0x32037d('0x9')),controller=require(_0x32037d('0xd'));router[_0x32037d('0xc')]('/',auth[_0x32037d('0x7')](),controller[_0x32037d('0x1')]),router[_0x32037d('0xc')](_0x32037d('0x8'),auth[_0x32037d('0x7')](),controller['show']),router[_0x32037d('0x6')]('/',auth[_0x32037d('0x7')](),controller[_0x32037d('0x4')]),router[_0x32037d('0xa')](_0x32037d('0x8'),auth[_0x32037d('0x7')](),controller['update']),router[_0x32037d('0x5')](_0x32037d('0x8'),auth[_0x32037d('0x7')](),controller[_0x32037d('0xb')]),module[_0x32037d('0x3')]=router; \ No newline at end of file +const a120_0x5d29=['put','delete','update','destroy','/:id','index','show','exports','post','express','get','isAuthenticated','../../components/auth/service','./cloudProvider.controller','Router'];(function(_0x589720,_0x5d2972){const _0x32aa36=function(_0xdd364a){while(--_0xdd364a){_0x589720['push'](_0x589720['shift']());}};_0x32aa36(++_0x5d2972);}(a120_0x5d29,0x128));const a120_0x32aa=function(_0x589720,_0x5d2972){_0x589720=_0x589720-0x0;let _0x32aa36=a120_0x5d29[_0x589720];return _0x32aa36;};const _0x409789=a120_0x32aa;'use strict';const express=require(_0x409789('0xd')),router=express[_0x409789('0x3')](),auth=require(_0x409789('0x1')),controller=require(_0x409789('0x2'));router['get']('/',auth[_0x409789('0x0')](),controller[_0x409789('0x9')]),router[_0x409789('0xe')](_0x409789('0x8'),auth[_0x409789('0x0')](),controller[_0x409789('0xa')]),router[_0x409789('0xc')]('/',auth[_0x409789('0x0')](),controller['create']),router[_0x409789('0x4')](_0x409789('0x8'),auth[_0x409789('0x0')](),controller[_0x409789('0x6')]),router[_0x409789('0x5')]('/:id',auth[_0x409789('0x0')](),controller[_0x409789('0x7')]),module[_0x409789('0xb')]=router; \ No newline at end of file diff --git a/server/api/cmCompany/cmCompany.attributes.js b/server/api/cmCompany/cmCompany.attributes.js index 596154b..798f435 100644 --- a/server/api/cmCompany/cmCompany.attributes.js +++ b/server/api/cmCompany/cmCompany.attributes.js @@ -1 +1 @@ -const a121_0xcd6b=['STRING','name'];(function(_0x9b43ff,_0xcd6b75){const _0x49f9f3=function(_0x54bf14){while(--_0x54bf14){_0x9b43ff['push'](_0x9b43ff['shift']());}};_0x49f9f3(++_0xcd6b75);}(a121_0xcd6b,0x77));const a121_0x49f9=function(_0x9b43ff,_0xcd6b75){_0x9b43ff=_0x9b43ff-0x0;let _0x49f9f3=a121_0xcd6b[_0x9b43ff];return _0x49f9f3;};const _0xaa8665=a121_0x49f9;'use strict';const Sequelize=require('sequelize');module['exports']={'name':{'type':Sequelize[_0xaa8665('0x1')],'unique':_0xaa8665('0x0'),'allowNull':![],'validate':{'notEmpty':!![]}},'vat':{'type':Sequelize[_0xaa8665('0x1')]},'companyId':{'type':Sequelize['STRING']},'website':{'type':Sequelize[_0xaa8665('0x1')]},'phone':{'type':Sequelize['STRING']},'fax':{'type':Sequelize['STRING']},'type':{'type':Sequelize[_0xaa8665('0x1')]},'street':{'type':Sequelize[_0xaa8665('0x1')]},'postalCode':{'type':Sequelize[_0xaa8665('0x1')]},'city':{'type':Sequelize[_0xaa8665('0x1')]},'country':{'type':Sequelize[_0xaa8665('0x1')]},'email':{'type':Sequelize[_0xaa8665('0x1')],'validate':{'isEmail':!![]}},'emailDomain':{'type':Sequelize[_0xaa8665('0x1')]},'sStreet':{'type':Sequelize[_0xaa8665('0x1')]},'sPostalCode':{'type':Sequelize[_0xaa8665('0x1')]},'sCity':{'type':Sequelize['STRING']},'sCountry':{'type':Sequelize[_0xaa8665('0x1')]},'description':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a121_0x3aa5=['sequelize','name','STRING','exports'];(function(_0x1341f1,_0x3aa504){const _0x176d12=function(_0x1fca77){while(--_0x1fca77){_0x1341f1['push'](_0x1341f1['shift']());}};_0x176d12(++_0x3aa504);}(a121_0x3aa5,0x158));const a121_0x176d=function(_0x1341f1,_0x3aa504){_0x1341f1=_0x1341f1-0x0;let _0x176d12=a121_0x3aa5[_0x1341f1];return _0x176d12;};const _0x23e3e8=a121_0x176d;'use strict';const Sequelize=require(_0x23e3e8('0x0'));module[_0x23e3e8('0x3')]={'name':{'type':Sequelize['STRING'],'unique':_0x23e3e8('0x1'),'allowNull':![],'validate':{'notEmpty':!![]}},'vat':{'type':Sequelize[_0x23e3e8('0x2')]},'companyId':{'type':Sequelize[_0x23e3e8('0x2')]},'website':{'type':Sequelize['STRING']},'phone':{'type':Sequelize[_0x23e3e8('0x2')]},'fax':{'type':Sequelize[_0x23e3e8('0x2')]},'type':{'type':Sequelize['STRING']},'street':{'type':Sequelize['STRING']},'postalCode':{'type':Sequelize[_0x23e3e8('0x2')]},'city':{'type':Sequelize[_0x23e3e8('0x2')]},'country':{'type':Sequelize[_0x23e3e8('0x2')]},'email':{'type':Sequelize[_0x23e3e8('0x2')],'validate':{'isEmail':!![]}},'emailDomain':{'type':Sequelize[_0x23e3e8('0x2')]},'sStreet':{'type':Sequelize[_0x23e3e8('0x2')]},'sPostalCode':{'type':Sequelize[_0x23e3e8('0x2')]},'sCity':{'type':Sequelize[_0x23e3e8('0x2')]},'sCountry':{'type':Sequelize[_0x23e3e8('0x2')]},'description':{'type':Sequelize[_0x23e3e8('0x2')]}}; \ No newline at end of file diff --git a/server/api/cmCompany/cmCompany.controller.js b/server/api/cmCompany/cmCompany.controller.js index 7a16276..8efa5b4 100644 --- a/server/api/cmCompany/cmCompany.controller.js +++ b/server/api/cmCompany/cmCompany.controller.js @@ -1 +1 @@ -const a122_0x14cd=['order','findOne','merge','Unable\x20to\x20retrieve\x20the\x20current\x20user','undefined','CmCompany','map','destroy','rows','model','findAll','CmContact','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','keys','end','addContacts','stack','Companies','omit','../../components/parsers/qs','update','api','params','error','status','then','filters','offset','describe','length','include','options','create','sendStatus','UserProfileSection','filter','query','name','lodash','UserProfileResource','getContacts','autoAssociation','body','fields','where','catch','send','intersection','sort','count','get','limit','nolimit','ids','includeAll','pick','user','like','attributes','rawAttributes','index'];(function(_0x4150a6,_0x14cd18){const _0x169677=function(_0x165dac){while(--_0x165dac){_0x4150a6['push'](_0x4150a6['shift']());}};_0x169677(++_0x14cd18);}(a122_0x14cd,0xeb));const a122_0x1696=function(_0x4150a6,_0x14cd18){_0x4150a6=_0x4150a6-0x0;let _0x169677=a122_0x14cd[_0x4150a6];return _0x169677;};const _0x52477e=a122_0x1696;'use strict';const _=require(_0x52477e('0x2f')),qs=require(_0x52477e('0x1c')),logger=require('../../config/logger')(_0x52477e('0x1e')),db=require('../../mysqldb')['db'],{Op}=require('sequelize');function respondWithResult(_0x165dac,_0x5994d2){return _0x5994d2=_0x5994d2||0xc8,function(_0x3684c8){const _0x284524=a122_0x1696;if(_0x3684c8)return _0x165dac[_0x284524('0x21')](_0x5994d2)['json'](_0x3684c8);};}function respondWithFilteredResult(_0x47e3e5,_0x50716f){return function(_0x529a31){const _0x4c600c=a122_0x1696;if(_0x529a31){const _0x19d306=_0x529a31[_0x4c600c('0x3a')],_0x3ed672=_0x50716f[_0x4c600c('0x24')];let _0x27aa53=_0x50716f[_0x4c600c('0x24')]+_0x50716f[_0x4c600c('0x3c')],_0x188686;return _0x27aa53>=_0x19d306?(_0x27aa53=_0x19d306,_0x188686=0xc8):_0x188686=0xce,_0x47e3e5['status'](_0x188686),_0x47e3e5['set']('Content-Range',_0x3ed672+'-'+_0x27aa53+'/'+_0x19d306)['json'](_0x529a31);}return null;};}function saveUpdates(_0x196767){return function(_0x1b5b1c){const _0x1f7a4c=a122_0x1696;if(_0x1b5b1c)return _0x1b5b1c[_0x1f7a4c('0x1d')](_0x196767)[_0x1f7a4c('0x22')](function(_0x29c107){return _0x29c107;});return null;};}function removeEntity(_0x5e1d5a){return function(_0x29b51f){const _0x3ba032=a122_0x1696;if(_0x29b51f)return _0x29b51f[_0x3ba032('0x10')]()['then'](function(){const _0x526cc3=_0x3ba032,_0x44c1c4=_0x29b51f[_0x526cc3('0x3b')]({'plain':!![]}),_0x1a7319=_0x526cc3('0x1a');return db[_0x526cc3('0x30')][_0x526cc3('0x10')]({'where':{'type':_0x1a7319,'resourceId':_0x44c1c4['id']}})[_0x526cc3('0x22')](function(){return _0x29b51f;});})[_0x3ba032('0x22')](function(){const _0x5af49c=_0x3ba032;_0x5e1d5a[_0x5af49c('0x21')](0xcc)[_0x5af49c('0x17')]();});};}function handleEntityNotFound(_0x9896bc){return function(_0x9fe3a0){const _0x381253=a122_0x1696;return!_0x9fe3a0&&_0x9896bc[_0x381253('0x2a')](0x194),_0x9fe3a0;};}function handleError(_0x39d684,_0x342296){return _0x342296=_0x342296||0x1f4,function(_0x25b54d){const _0x318250=a122_0x1696;logger[_0x318250('0x20')](_0x25b54d[_0x318250('0x19')]),_0x25b54d['name']&&delete _0x25b54d[_0x318250('0x2e')],_0x39d684[_0x318250('0x21')](_0x342296)[_0x318250('0x37')](_0x25b54d);};}exports[_0x52477e('0x8')]=function(_0x4071f2,_0x5b49b3){const _0x175adf=_0x52477e;let _0xb2cf85={};const _0x465ddf={},_0x5d9806={'count':0x0,'rows':[]};return db[_0x175adf('0xe')]['describe']()['then'](function(_0x349ae5){const _0x115fa0=_0x175adf;_0x465ddf[_0x115fa0('0x12')]=_[_0x115fa0('0x16')](_0x349ae5),_0x465ddf['query']=_[_0x115fa0('0x16')](_0x4071f2[_0x115fa0('0x2d')]),_0x465ddf[_0x115fa0('0x23')]=_['intersection'](_0x465ddf[_0x115fa0('0x12')],_0x465ddf[_0x115fa0('0x2d')]),_0xb2cf85[_0x115fa0('0x6')]=_['intersection'](_0x465ddf['model'],qs[_0x115fa0('0x34')](_0x4071f2[_0x115fa0('0x2d')][_0x115fa0('0x34')])),_0xb2cf85[_0x115fa0('0x6')]=_0xb2cf85['attributes']['length']?_0xb2cf85[_0x115fa0('0x6')]:_0x465ddf[_0x115fa0('0x12')];typeof _0x4071f2[_0x115fa0('0x2d')][_0x115fa0('0x0')]===_0x115fa0('0xd')&&(_0xb2cf85[_0x115fa0('0x3c')]=qs[_0x115fa0('0x3c')](_0x4071f2[_0x115fa0('0x2d')][_0x115fa0('0x3c')]),_0xb2cf85[_0x115fa0('0x24')]=qs['offset'](_0x4071f2[_0x115fa0('0x2d')][_0x115fa0('0x24')]));_0xb2cf85[_0x115fa0('0x9')]=qs[_0x115fa0('0x39')](_0x4071f2[_0x115fa0('0x2d')]['sort']),_0xb2cf85['where']=qs[_0x115fa0('0x23')](_[_0x115fa0('0x3')](_0x4071f2[_0x115fa0('0x2d')],_0x465ddf['filters']),_0x349ae5);_0x4071f2[_0x115fa0('0x2d')]['filter']&&(_0xb2cf85[_0x115fa0('0x35')]=_[_0x115fa0('0xb')](_0xb2cf85[_0x115fa0('0x35')],{[Op['or']]:_[_0x115fa0('0xf')](_0xb2cf85[_0x115fa0('0x6')],function(_0x4b7d3d){const _0x315cd4=_0x115fa0,_0x28e949={};return _0x28e949[_0x4b7d3d]={[Op[_0x315cd4('0x5')]]:'%'+_0x4071f2['query'][_0x315cd4('0x2c')]+'%'},_0x28e949;})}));_0xb2cf85=_['merge']({},_0xb2cf85,_0x4071f2[_0x115fa0('0x28')]);const _0x4d595b={'where':_0xb2cf85[_0x115fa0('0x35')]};return db[_0x115fa0('0xe')]['count'](_0x4d595b)[_0x115fa0('0x22')](function(_0xd22ad6){const _0x233078=_0x115fa0;return _0x5d9806[_0x233078('0x3a')]=_0xd22ad6,_0x4071f2['query'][_0x233078('0x2')]&&(_0xb2cf85[_0x233078('0x27')]=[{'all':!![]}]),db[_0x233078('0xe')][_0x233078('0x13')](_0xb2cf85);})[_0x115fa0('0x22')](function(_0x3b0116){const _0x4a2495=_0x115fa0;return _0x5d9806[_0x4a2495('0x11')]=_0x3b0116,_0x5d9806;})[_0x115fa0('0x22')](respondWithFilteredResult(_0x5b49b3,_0xb2cf85))[_0x115fa0('0x36')](handleError(_0x5b49b3,null));})[_0x175adf('0x36')](handleError(_0x5b49b3,null));},exports['show']=function(_0x5cf50e,_0x5c1f63){const _0x33c24f=_0x52477e;let _0x53c2ac={'raw':![],'where':{'id':_0x5cf50e[_0x33c24f('0x1f')]['id']}};const _0x3680eb={};return _0x3680eb['model']=_[_0x33c24f('0x16')](db[_0x33c24f('0xe')]['rawAttributes']),_0x3680eb[_0x33c24f('0x2d')]=_[_0x33c24f('0x16')](_0x5cf50e['query']),_0x3680eb['filters']=_['intersection'](_0x3680eb[_0x33c24f('0x12')],_0x3680eb[_0x33c24f('0x2d')]),_0x53c2ac['attributes']=_[_0x33c24f('0x38')](_0x3680eb['model'],qs[_0x33c24f('0x34')](_0x5cf50e[_0x33c24f('0x2d')][_0x33c24f('0x34')])),_0x53c2ac[_0x33c24f('0x6')]=_0x53c2ac[_0x33c24f('0x6')]['length']?_0x53c2ac[_0x33c24f('0x6')]:_0x3680eb[_0x33c24f('0x12')],_0x5cf50e['query'][_0x33c24f('0x2')]&&(_0x53c2ac['include']=[{'all':!![]}]),_0x53c2ac=_[_0x33c24f('0xb')]({},_0x53c2ac,_0x5cf50e['options']),db[_0x33c24f('0xe')]['findOne'](_0x53c2ac)[_0x33c24f('0x22')](handleEntityNotFound(_0x5c1f63,null))[_0x33c24f('0x22')](respondWithResult(_0x5c1f63,null))[_0x33c24f('0x36')](handleError(_0x5c1f63,null));},exports[_0x52477e('0x29')]=function(_0x2eab95,_0x38d189){const _0x5009a6=_0x52477e;return db[_0x5009a6('0xe')][_0x5009a6('0x29')](_0x2eab95[_0x5009a6('0x33')],{})['then'](function(_0x470cd3){const _0x448145=_0x5009a6,_0x4a6daa=_0x2eab95['user']['get']({'plain':!![]});if(!_0x4a6daa)throw new Error(_0x448145('0xc'));if(_0x4a6daa['role']===_0x448145('0x4')){const _0x5633db=_0x470cd3[_0x448145('0x3b')]({'plain':!![]}),_0x345c75='Companies';return db[_0x448145('0x2b')][_0x448145('0xa')]({'where':{'name':_0x345c75,'userProfileId':_0x4a6daa['userProfileId']},'raw':!![]})[_0x448145('0x22')](function(_0xc7d3f0){const _0x51fc81=_0x448145;return _0xc7d3f0&&_0xc7d3f0[_0x51fc81('0x32')]===0x0?db['UserProfileResource'][_0x51fc81('0x29')]({'name':_0x5633db['name'],'resourceId':_0x5633db['id'],'type':_0xc7d3f0['name'],'sectionId':_0xc7d3f0['id']},{})[_0x51fc81('0x22')](function(){return _0x470cd3;}):_0x470cd3;})[_0x448145('0x36')](function(_0xd5253){const _0xa1c6e6=_0x448145;logger[_0xa1c6e6('0x20')](_0xa1c6e6('0x15'),_0xd5253);throw _0xd5253;});}return _0x470cd3;})[_0x5009a6('0x22')](respondWithResult(_0x38d189,0xc9))['catch'](handleError(_0x38d189,null));},exports[_0x52477e('0x1d')]=function(_0x236672,_0x59907e){const _0x347314=_0x52477e;return _0x236672[_0x347314('0x33')]['id']&&delete _0x236672[_0x347314('0x33')]['id'],db[_0x347314('0xe')][_0x347314('0xa')]({'where':{'id':_0x236672[_0x347314('0x1f')]['id']}})[_0x347314('0x22')](handleEntityNotFound(_0x59907e,null))[_0x347314('0x22')](saveUpdates(_0x236672[_0x347314('0x33')],null))[_0x347314('0x22')](respondWithResult(_0x59907e,null))[_0x347314('0x36')](handleError(_0x59907e,null));},exports[_0x52477e('0x10')]=function(_0x1b101c,_0x29234e){const _0x5bc9be=_0x52477e;return db[_0x5bc9be('0xe')]['findOne']({'where':{'id':_0x1b101c['params']['id']}})[_0x5bc9be('0x22')](handleEntityNotFound(_0x29234e,null))[_0x5bc9be('0x22')](removeEntity(_0x29234e,null))[_0x5bc9be('0x36')](handleError(_0x29234e,null));},exports[_0x52477e('0x25')]=function(_0x5bdf46,_0x5853ca){const _0x2553f6=_0x52477e;return db[_0x2553f6('0xe')][_0x2553f6('0x25')]()[_0x2553f6('0x22')](respondWithResult(_0x5853ca,null))[_0x2553f6('0x36')](handleError(_0x5853ca,null));},exports['addContacts']=function(_0x4179f5,_0x55ac92){const _0x5d3784=_0x52477e;return db[_0x5d3784('0x14')]['findOne']({'where':{'id':_0x4179f5[_0x5d3784('0x1f')]['id']}})[_0x5d3784('0x22')](function(_0xf89140){const _0x2360d5=_0x5d3784;if(_0xf89140)return _0xf89140[_0x2360d5('0x18')](_0x4179f5[_0x2360d5('0x33')][_0x2360d5('0x1')],{'through':_[_0x2360d5('0x1b')](_0x4179f5[_0x2360d5('0x33')],[_0x2360d5('0x1'),'id'])});})[_0x5d3784('0x22')](respondWithResult(_0x55ac92,null))[_0x5d3784('0x36')](handleError(_0x55ac92,null));},exports[_0x52477e('0x31')]=function(_0x21e3b2,_0x2af5e3){const _0xfe1f79=_0x52477e;let _0x4cf8ca={};const _0x3de262={};let _0x25066e,_0x225708;return db[_0xfe1f79('0xe')][_0xfe1f79('0xa')]({'where':{'id':_0x21e3b2[_0xfe1f79('0x1f')]['id']}})[_0xfe1f79('0x22')](handleEntityNotFound(_0x2af5e3,null))[_0xfe1f79('0x22')](function(_0x1048d1){const _0x4f2c73=_0xfe1f79;if(_0x1048d1)return _0x25066e=_0x1048d1,_0x3de262[_0x4f2c73('0x12')]=_[_0x4f2c73('0x16')](db['CmContact'][_0x4f2c73('0x7')]),_0x3de262['query']=_[_0x4f2c73('0x16')](_0x21e3b2[_0x4f2c73('0x2d')]),_0x3de262['filters']=_[_0x4f2c73('0x38')](_0x3de262[_0x4f2c73('0x12')],_0x3de262[_0x4f2c73('0x2d')]),_0x4cf8ca[_0x4f2c73('0x6')]=_[_0x4f2c73('0x38')](_0x3de262[_0x4f2c73('0x12')],qs[_0x4f2c73('0x34')](_0x21e3b2[_0x4f2c73('0x2d')][_0x4f2c73('0x34')])),_0x4cf8ca[_0x4f2c73('0x6')]=_0x4cf8ca[_0x4f2c73('0x6')][_0x4f2c73('0x26')]?_0x4cf8ca[_0x4f2c73('0x6')]:_0x3de262[_0x4f2c73('0x12')],_0x4cf8ca[_0x4f2c73('0x9')]=qs[_0x4f2c73('0x39')](_0x21e3b2[_0x4f2c73('0x2d')]['sort']),_0x4cf8ca[_0x4f2c73('0x35')]=qs[_0x4f2c73('0x23')](_[_0x4f2c73('0x3')](_0x21e3b2[_0x4f2c73('0x2d')],_0x3de262['filters'])),_0x21e3b2['query']['filter']&&(_0x4cf8ca[_0x4f2c73('0x35')]=_['merge'](_0x4cf8ca[_0x4f2c73('0x35')],{[Op['or']]:_['map'](_0x4cf8ca[_0x4f2c73('0x6')],function(_0x58a8c7){const _0x50864e=_0x4f2c73,_0x523b90={};return _0x523b90[_0x58a8c7]={[Op[_0x50864e('0x5')]]:'%'+_0x21e3b2['query'][_0x50864e('0x2c')]+'%'},_0x523b90;})})),_0x4cf8ca=_[_0x4f2c73('0xb')]({},_0x4cf8ca,_0x21e3b2[_0x4f2c73('0x28')]),_0x25066e[_0x4f2c73('0x31')](_0x4cf8ca);})[_0xfe1f79('0x22')](function(_0x3160f1){const _0x222eda=_0xfe1f79;if(_0x3160f1)return _0x225708=_0x3160f1[_0x222eda('0x26')],typeof _0x21e3b2[_0x222eda('0x2d')][_0x222eda('0x0')]===_0x222eda('0xd')&&(_0x4cf8ca[_0x222eda('0x3c')]=qs[_0x222eda('0x3c')](_0x21e3b2['query']['limit']),_0x4cf8ca[_0x222eda('0x24')]=qs[_0x222eda('0x24')](_0x21e3b2[_0x222eda('0x2d')]['offset'])),_0x25066e[_0x222eda('0x31')](_0x4cf8ca);})['then'](function(_0x336078){if(_0x336078)return _0x336078?{'count':_0x225708,'rows':_0x336078}:null;})['then'](respondWithResult(_0x2af5e3,null))['catch'](handleError(_0x2af5e3,null));}; \ No newline at end of file +const a122_0x5e0a=['rawAttributes','filters','getContacts','body','includeAll','model','show','catch','intersection','name','send','sort','CmCompany','then','destroy','like','ids','user','nolimit','pick','../../components/parsers/qs','get','sendStatus','Companies','offset','index','filter','limit','count','addContacts','error','findAll','keys','options','order','../../mysqldb','set','create','length','end','include','fields','userProfileId','autoAssociation','json','attributes','omit','undefined','Content-Range','CmContact','../../config/logger','UserProfileResource','where','params','map','query','merge','update','api','status','role','rows','findOne','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','describe'];(function(_0x4bb99b,_0x5e0af7){const _0x412246=function(_0x4c7bf4){while(--_0x4c7bf4){_0x4bb99b['push'](_0x4bb99b['shift']());}};_0x412246(++_0x5e0af7);}(a122_0x5e0a,0x194));const a122_0x4122=function(_0x4bb99b,_0x5e0af7){_0x4bb99b=_0x4bb99b-0x0;let _0x412246=a122_0x5e0a[_0x4bb99b];return _0x412246;};const _0x277ca9=a122_0x4122;'use strict';const _=require('lodash'),qs=require(_0x277ca9('0x6')),logger=require(_0x277ca9('0x24'))(_0x277ca9('0x2c')),db=require(_0x277ca9('0x15'))['db'],{Op}=require('sequelize');function respondWithResult(_0x4c7bf4,_0x5b5e4a){return _0x5b5e4a=_0x5b5e4a||0xc8,function(_0x2ac000){const _0x4b1109=a122_0x4122;if(_0x2ac000)return _0x4c7bf4[_0x4b1109('0x2d')](_0x5b5e4a)[_0x4b1109('0x1e')](_0x2ac000);};}function respondWithFilteredResult(_0x9d3c57,_0x189934){return function(_0xe083b2){const _0x18eae1=a122_0x4122;if(_0xe083b2){const _0x120eac=_0xe083b2[_0x18eae1('0xe')],_0x3b8668=_0x189934[_0x18eae1('0xa')];let _0x279d76=_0x189934[_0x18eae1('0xa')]+_0x189934[_0x18eae1('0xd')],_0x5a998d;return _0x279d76>=_0x120eac?(_0x279d76=_0x120eac,_0x5a998d=0xc8):_0x5a998d=0xce,_0x9d3c57[_0x18eae1('0x2d')](_0x5a998d),_0x9d3c57[_0x18eae1('0x16')](_0x18eae1('0x22'),_0x3b8668+'-'+_0x279d76+'/'+_0x120eac)[_0x18eae1('0x1e')](_0xe083b2);}return null;};}function saveUpdates(_0x132018){return function(_0x1237af){const _0x3a4f92=a122_0x4122;if(_0x1237af)return _0x1237af[_0x3a4f92('0x2b')](_0x132018)[_0x3a4f92('0x40')](function(_0x2e3890){return _0x2e3890;});return null;};}function removeEntity(_0x2d276b){return function(_0x4b57a2){const _0x5c6b8d=a122_0x4122;if(_0x4b57a2)return _0x4b57a2['destroy']()[_0x5c6b8d('0x40')](function(){const _0xde1ca1=_0x5c6b8d,_0x12cb92=_0x4b57a2[_0xde1ca1('0x7')]({'plain':!![]}),_0x15e451=_0xde1ca1('0x9');return db[_0xde1ca1('0x25')][_0xde1ca1('0x0')]({'where':{'type':_0x15e451,'resourceId':_0x12cb92['id']}})[_0xde1ca1('0x40')](function(){return _0x4b57a2;});})[_0x5c6b8d('0x40')](function(){const _0x31bd0a=_0x5c6b8d;_0x2d276b[_0x31bd0a('0x2d')](0xcc)[_0x31bd0a('0x19')]();});};}function handleEntityNotFound(_0x432769){return function(_0x3c4b57){const _0x54e162=a122_0x4122;return!_0x3c4b57&&_0x432769[_0x54e162('0x8')](0x194),_0x3c4b57;};}function handleError(_0x5e2589,_0x5e7300){return _0x5e7300=_0x5e7300||0x1f4,function(_0x13dba9){const _0x39728e=a122_0x4122;logger[_0x39728e('0x10')](_0x13dba9['stack']),_0x13dba9['name']&&delete _0x13dba9[_0x39728e('0x3c')],_0x5e2589[_0x39728e('0x2d')](_0x5e7300)[_0x39728e('0x3d')](_0x13dba9);};}exports[_0x277ca9('0xb')]=function(_0x4c3110,_0x16d9b3){const _0x14709c=_0x277ca9;let _0x457fe8={};const _0x3cd158={},_0x342f8e={'count':0x0,'rows':[]};return db[_0x14709c('0x3f')]['describe']()[_0x14709c('0x40')](function(_0x5e2756){const _0x890d78=_0x14709c;_0x3cd158[_0x890d78('0x38')]=_[_0x890d78('0x12')](_0x5e2756),_0x3cd158[_0x890d78('0x29')]=_[_0x890d78('0x12')](_0x4c3110[_0x890d78('0x29')]),_0x3cd158['filters']=_['intersection'](_0x3cd158[_0x890d78('0x38')],_0x3cd158[_0x890d78('0x29')]),_0x457fe8['attributes']=_[_0x890d78('0x3b')](_0x3cd158[_0x890d78('0x38')],qs[_0x890d78('0x1b')](_0x4c3110[_0x890d78('0x29')][_0x890d78('0x1b')])),_0x457fe8[_0x890d78('0x1f')]=_0x457fe8[_0x890d78('0x1f')]['length']?_0x457fe8['attributes']:_0x3cd158['model'];typeof _0x4c3110[_0x890d78('0x29')][_0x890d78('0x4')]==='undefined'&&(_0x457fe8['limit']=qs[_0x890d78('0xd')](_0x4c3110['query'][_0x890d78('0xd')]),_0x457fe8[_0x890d78('0xa')]=qs[_0x890d78('0xa')](_0x4c3110[_0x890d78('0x29')][_0x890d78('0xa')]));_0x457fe8['order']=qs['sort'](_0x4c3110[_0x890d78('0x29')][_0x890d78('0x3e')]),_0x457fe8[_0x890d78('0x26')]=qs[_0x890d78('0x34')](_[_0x890d78('0x5')](_0x4c3110[_0x890d78('0x29')],_0x3cd158[_0x890d78('0x34')]),_0x5e2756);_0x4c3110['query'][_0x890d78('0xc')]&&(_0x457fe8[_0x890d78('0x26')]=_['merge'](_0x457fe8[_0x890d78('0x26')],{[Op['or']]:_['map'](_0x457fe8[_0x890d78('0x1f')],function(_0x104606){const _0x1a54c3=_0x890d78,_0x3b7ca5={};return _0x3b7ca5[_0x104606]={[Op[_0x1a54c3('0x1')]]:'%'+_0x4c3110[_0x1a54c3('0x29')][_0x1a54c3('0xc')]+'%'},_0x3b7ca5;})}));_0x457fe8=_[_0x890d78('0x2a')]({},_0x457fe8,_0x4c3110[_0x890d78('0x13')]);const _0x2e6e58={'where':_0x457fe8['where']};return db[_0x890d78('0x3f')][_0x890d78('0xe')](_0x2e6e58)[_0x890d78('0x40')](function(_0x11fdd9){const _0x50eaf9=_0x890d78;return _0x342f8e[_0x50eaf9('0xe')]=_0x11fdd9,_0x4c3110[_0x50eaf9('0x29')][_0x50eaf9('0x37')]&&(_0x457fe8['include']=[{'all':!![]}]),db[_0x50eaf9('0x3f')][_0x50eaf9('0x11')](_0x457fe8);})[_0x890d78('0x40')](function(_0x22a07c){const _0x5267dc=_0x890d78;return _0x342f8e[_0x5267dc('0x2f')]=_0x22a07c,_0x342f8e;})['then'](respondWithFilteredResult(_0x16d9b3,_0x457fe8))[_0x890d78('0x3a')](handleError(_0x16d9b3,null));})[_0x14709c('0x3a')](handleError(_0x16d9b3,null));},exports[_0x277ca9('0x39')]=function(_0x509883,_0x5037c5){const _0x4bb542=_0x277ca9;let _0x5f148e={'raw':![],'where':{'id':_0x509883[_0x4bb542('0x27')]['id']}};const _0x3c6993={};return _0x3c6993[_0x4bb542('0x38')]=_[_0x4bb542('0x12')](db[_0x4bb542('0x3f')][_0x4bb542('0x33')]),_0x3c6993[_0x4bb542('0x29')]=_[_0x4bb542('0x12')](_0x509883['query']),_0x3c6993[_0x4bb542('0x34')]=_[_0x4bb542('0x3b')](_0x3c6993[_0x4bb542('0x38')],_0x3c6993[_0x4bb542('0x29')]),_0x5f148e[_0x4bb542('0x1f')]=_[_0x4bb542('0x3b')](_0x3c6993[_0x4bb542('0x38')],qs[_0x4bb542('0x1b')](_0x509883[_0x4bb542('0x29')][_0x4bb542('0x1b')])),_0x5f148e['attributes']=_0x5f148e[_0x4bb542('0x1f')][_0x4bb542('0x18')]?_0x5f148e[_0x4bb542('0x1f')]:_0x3c6993['model'],_0x509883[_0x4bb542('0x29')][_0x4bb542('0x37')]&&(_0x5f148e[_0x4bb542('0x1a')]=[{'all':!![]}]),_0x5f148e=_[_0x4bb542('0x2a')]({},_0x5f148e,_0x509883['options']),db[_0x4bb542('0x3f')][_0x4bb542('0x30')](_0x5f148e)[_0x4bb542('0x40')](handleEntityNotFound(_0x5037c5,null))['then'](respondWithResult(_0x5037c5,null))[_0x4bb542('0x3a')](handleError(_0x5037c5,null));},exports[_0x277ca9('0x17')]=function(_0x221a01,_0x3973b9){const _0x81fd15=_0x277ca9;return db[_0x81fd15('0x3f')]['create'](_0x221a01[_0x81fd15('0x36')],{})[_0x81fd15('0x40')](function(_0x4dde98){const _0x382e3f=_0x81fd15,_0x2d1cd9=_0x221a01[_0x382e3f('0x3')]['get']({'plain':!![]});if(!_0x2d1cd9)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x2d1cd9[_0x382e3f('0x2e')]===_0x382e3f('0x3')){const _0x3f5d73=_0x4dde98['get']({'plain':!![]}),_0x211a97=_0x382e3f('0x9');return db['UserProfileSection'][_0x382e3f('0x30')]({'where':{'name':_0x211a97,'userProfileId':_0x2d1cd9[_0x382e3f('0x1c')]},'raw':!![]})[_0x382e3f('0x40')](function(_0x341876){const _0x19329b=_0x382e3f;return _0x341876&&_0x341876[_0x19329b('0x1d')]===0x0?db[_0x19329b('0x25')][_0x19329b('0x17')]({'name':_0x3f5d73[_0x19329b('0x3c')],'resourceId':_0x3f5d73['id'],'type':_0x341876[_0x19329b('0x3c')],'sectionId':_0x341876['id']},{})[_0x19329b('0x40')](function(){return _0x4dde98;}):_0x4dde98;})['catch'](function(_0x2ecd2f){const _0x41748b=_0x382e3f;logger['error'](_0x41748b('0x31'),_0x2ecd2f);throw _0x2ecd2f;});}return _0x4dde98;})['then'](respondWithResult(_0x3973b9,0xc9))[_0x81fd15('0x3a')](handleError(_0x3973b9,null));},exports[_0x277ca9('0x2b')]=function(_0x3b6884,_0x315589){const _0x50236f=_0x277ca9;return _0x3b6884['body']['id']&&delete _0x3b6884[_0x50236f('0x36')]['id'],db[_0x50236f('0x3f')][_0x50236f('0x30')]({'where':{'id':_0x3b6884[_0x50236f('0x27')]['id']}})['then'](handleEntityNotFound(_0x315589,null))[_0x50236f('0x40')](saveUpdates(_0x3b6884[_0x50236f('0x36')],null))[_0x50236f('0x40')](respondWithResult(_0x315589,null))['catch'](handleError(_0x315589,null));},exports[_0x277ca9('0x0')]=function(_0x3d3c6c,_0x42ca8b){const _0x46abc2=_0x277ca9;return db['CmCompany'][_0x46abc2('0x30')]({'where':{'id':_0x3d3c6c[_0x46abc2('0x27')]['id']}})[_0x46abc2('0x40')](handleEntityNotFound(_0x42ca8b,null))[_0x46abc2('0x40')](removeEntity(_0x42ca8b,null))[_0x46abc2('0x3a')](handleError(_0x42ca8b,null));},exports[_0x277ca9('0x32')]=function(_0x21b35b,_0x31969c){const _0x372d0d=_0x277ca9;return db[_0x372d0d('0x3f')]['describe']()['then'](respondWithResult(_0x31969c,null))[_0x372d0d('0x3a')](handleError(_0x31969c,null));},exports[_0x277ca9('0xf')]=function(_0x2ec037,_0x45e72a){const _0x2e9d97=_0x277ca9;return db['CmContact']['findOne']({'where':{'id':_0x2ec037['params']['id']}})[_0x2e9d97('0x40')](function(_0xfaa980){const _0x37b483=_0x2e9d97;if(_0xfaa980)return _0xfaa980['addContacts'](_0x2ec037['body'][_0x37b483('0x2')],{'through':_[_0x37b483('0x20')](_0x2ec037[_0x37b483('0x36')],[_0x37b483('0x2'),'id'])});})['then'](respondWithResult(_0x45e72a,null))[_0x2e9d97('0x3a')](handleError(_0x45e72a,null));},exports[_0x277ca9('0x35')]=function(_0x2f8ab6,_0x26981e){const _0x86a2b0=_0x277ca9;let _0x330354={};const _0x89e8a4={};let _0x174480,_0x24ea75;return db[_0x86a2b0('0x3f')][_0x86a2b0('0x30')]({'where':{'id':_0x2f8ab6[_0x86a2b0('0x27')]['id']}})[_0x86a2b0('0x40')](handleEntityNotFound(_0x26981e,null))[_0x86a2b0('0x40')](function(_0x4c0e09){const _0x27d3ad=_0x86a2b0;if(_0x4c0e09)return _0x174480=_0x4c0e09,_0x89e8a4[_0x27d3ad('0x38')]=_[_0x27d3ad('0x12')](db[_0x27d3ad('0x23')][_0x27d3ad('0x33')]),_0x89e8a4[_0x27d3ad('0x29')]=_[_0x27d3ad('0x12')](_0x2f8ab6[_0x27d3ad('0x29')]),_0x89e8a4['filters']=_['intersection'](_0x89e8a4[_0x27d3ad('0x38')],_0x89e8a4['query']),_0x330354[_0x27d3ad('0x1f')]=_[_0x27d3ad('0x3b')](_0x89e8a4['model'],qs['fields'](_0x2f8ab6[_0x27d3ad('0x29')][_0x27d3ad('0x1b')])),_0x330354[_0x27d3ad('0x1f')]=_0x330354[_0x27d3ad('0x1f')][_0x27d3ad('0x18')]?_0x330354['attributes']:_0x89e8a4[_0x27d3ad('0x38')],_0x330354[_0x27d3ad('0x14')]=qs['sort'](_0x2f8ab6[_0x27d3ad('0x29')][_0x27d3ad('0x3e')]),_0x330354['where']=qs[_0x27d3ad('0x34')](_['pick'](_0x2f8ab6['query'],_0x89e8a4[_0x27d3ad('0x34')])),_0x2f8ab6[_0x27d3ad('0x29')][_0x27d3ad('0xc')]&&(_0x330354['where']=_[_0x27d3ad('0x2a')](_0x330354[_0x27d3ad('0x26')],{[Op['or']]:_[_0x27d3ad('0x28')](_0x330354['attributes'],function(_0x12e5cd){const _0x2e2156=_0x27d3ad,_0x5cfc55={};return _0x5cfc55[_0x12e5cd]={[Op[_0x2e2156('0x1')]]:'%'+_0x2f8ab6[_0x2e2156('0x29')]['filter']+'%'},_0x5cfc55;})})),_0x330354=_[_0x27d3ad('0x2a')]({},_0x330354,_0x2f8ab6['options']),_0x174480[_0x27d3ad('0x35')](_0x330354);})['then'](function(_0x480876){const _0xd9b0f6=_0x86a2b0;if(_0x480876)return _0x24ea75=_0x480876['length'],typeof _0x2f8ab6['query'][_0xd9b0f6('0x4')]===_0xd9b0f6('0x21')&&(_0x330354[_0xd9b0f6('0xd')]=qs[_0xd9b0f6('0xd')](_0x2f8ab6['query']['limit']),_0x330354[_0xd9b0f6('0xa')]=qs[_0xd9b0f6('0xa')](_0x2f8ab6[_0xd9b0f6('0x29')]['offset'])),_0x174480[_0xd9b0f6('0x35')](_0x330354);})['then'](function(_0x27d305){if(_0x27d305)return _0x27d305?{'count':_0x24ea75,'rows':_0x27d305}:null;})['then'](respondWithResult(_0x26981e,null))[_0x86a2b0('0x3a')](handleError(_0x26981e,null));}; \ No newline at end of file diff --git a/server/api/cmCompany/cmCompany.model.js b/server/api/cmCompany/cmCompany.model.js index 2b23aec..d582fbd 100644 --- a/server/api/cmCompany/cmCompany.model.js +++ b/server/api/cmCompany/cmCompany.model.js @@ -1 +1 @@ -const a123_0x4e3f=['CmCompany','./cmCompany.attributes','exports','define'];(function(_0x54b3e1,_0x4e3f81){const _0x2f9d9a=function(_0x30a243){while(--_0x30a243){_0x54b3e1['push'](_0x54b3e1['shift']());}};_0x2f9d9a(++_0x4e3f81);}(a123_0x4e3f,0x187));const a123_0x2f9d=function(_0x54b3e1,_0x4e3f81){_0x54b3e1=_0x54b3e1-0x0;let _0x2f9d9a=a123_0x4e3f[_0x54b3e1];return _0x2f9d9a;};const _0x12900d=a123_0x2f9d;'use strict';const attributes=require(_0x12900d('0x2'));module[_0x12900d('0x3')]=function(_0x30a243){const _0x321cb5=_0x12900d,_0x379ddb=_0x30a243[_0x321cb5('0x0')](_0x321cb5('0x1'),attributes,{'tableName':'cm_companies','paranoid':![],'indexes':[],'timestamps':!![]});return _0x379ddb;}; \ No newline at end of file +const a123_0x4523=['./cmCompany.attributes','define','exports'];(function(_0x215416,_0x45233d){const _0x4ac602=function(_0x1828fb){while(--_0x1828fb){_0x215416['push'](_0x215416['shift']());}};_0x4ac602(++_0x45233d);}(a123_0x4523,0x162));const a123_0x4ac6=function(_0x215416,_0x45233d){_0x215416=_0x215416-0x0;let _0x4ac602=a123_0x4523[_0x215416];return _0x4ac602;};const _0x553e96=a123_0x4ac6;'use strict';const attributes=require(_0x553e96('0x0'));module[_0x553e96('0x2')]=function(_0x1828fb){const _0x4a730c=_0x553e96,_0x295879=_0x1828fb[_0x4a730c('0x1')]('CmCompany',attributes,{'tableName':'cm_companies','paranoid':![],'indexes':[],'timestamps':!![]});return _0x295879;}; \ No newline at end of file diff --git a/server/api/cmCompany/index.js b/server/api/cmCompany/index.js index 074f08c..82e535a 100644 --- a/server/api/cmCompany/index.js +++ b/server/api/cmCompany/index.js @@ -1 +1 @@ -const a124_0x1579=['put','exports','../../components/auth/service','./cmCompany.controller','index','destroy','isAuthenticated','express','/describe','get','create','update','delete','getContacts','describe','/:id/contacts','addContacts','Router','show','post'];(function(_0x3f1251,_0x1579e7){const _0x37af61=function(_0x38a2ee){while(--_0x38a2ee){_0x3f1251['push'](_0x3f1251['shift']());}};_0x37af61(++_0x1579e7);}(a124_0x1579,0x10e));const a124_0x37af=function(_0x3f1251,_0x1579e7){_0x3f1251=_0x3f1251-0x0;let _0x37af61=a124_0x1579[_0x3f1251];return _0x37af61;};const _0x2e48cb=a124_0x37af;'use strict';const express=require(_0x2e48cb('0x11')),router=express[_0x2e48cb('0x7')](),auth=require(_0x2e48cb('0xc')),controller=require(_0x2e48cb('0xd'));router[_0x2e48cb('0x13')]('/',auth['isAuthenticated'](),controller[_0x2e48cb('0xe')]),router[_0x2e48cb('0x13')](_0x2e48cb('0x12'),auth['isAuthenticated'](),controller[_0x2e48cb('0x4')]),router[_0x2e48cb('0x13')]('/:id',auth[_0x2e48cb('0x10')](),controller[_0x2e48cb('0x8')]),router[_0x2e48cb('0x13')](_0x2e48cb('0x5'),auth[_0x2e48cb('0x10')](),controller[_0x2e48cb('0x3')]),router[_0x2e48cb('0x9')]('/',auth[_0x2e48cb('0x10')](),controller[_0x2e48cb('0x0')]),router[_0x2e48cb('0x9')](_0x2e48cb('0x5'),auth['isAuthenticated'](),controller[_0x2e48cb('0x6')]),router[_0x2e48cb('0xa')]('/:id',auth[_0x2e48cb('0x10')](),controller[_0x2e48cb('0x1')]),router[_0x2e48cb('0x2')]('/:id',auth[_0x2e48cb('0x10')](),controller[_0x2e48cb('0xf')]),module[_0x2e48cb('0xb')]=router; \ No newline at end of file +const a124_0x4f6f=['addContacts','./cmCompany.controller','create','/:id','destroy','describe','index','update','put','/:id/contacts','Router','/describe','show','isAuthenticated','post','get'];(function(_0x3756ef,_0x4f6fac){const _0x56d207=function(_0x596e0e){while(--_0x596e0e){_0x3756ef['push'](_0x3756ef['shift']());}};_0x56d207(++_0x4f6fac);}(a124_0x4f6f,0x1cb));const a124_0x56d2=function(_0x3756ef,_0x4f6fac){_0x3756ef=_0x3756ef-0x0;let _0x56d207=a124_0x4f6f[_0x3756ef];return _0x56d207;};const _0x51db80=a124_0x56d2;'use strict';const express=require('express'),router=express[_0x51db80('0xf')](),auth=require('../../components/auth/service'),controller=require(_0x51db80('0x6'));router['get']('/',auth[_0x51db80('0x2')](),controller[_0x51db80('0xb')]),router[_0x51db80('0x4')](_0x51db80('0x0'),auth[_0x51db80('0x2')](),controller[_0x51db80('0xa')]),router['get'](_0x51db80('0x8'),auth['isAuthenticated'](),controller[_0x51db80('0x1')]),router[_0x51db80('0x4')](_0x51db80('0xe'),auth[_0x51db80('0x2')](),controller['getContacts']),router['post']('/',auth[_0x51db80('0x2')](),controller[_0x51db80('0x7')]),router[_0x51db80('0x3')]('/:id/contacts',auth[_0x51db80('0x2')](),controller[_0x51db80('0x5')]),router[_0x51db80('0xd')]('/:id',auth[_0x51db80('0x2')](),controller[_0x51db80('0xc')]),router['delete'](_0x51db80('0x8'),auth[_0x51db80('0x2')](),controller[_0x51db80('0x9')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/cmContact/cmContact.attributes.js b/server/api/cmContact/cmContact.attributes.js index ff4cae2..8d39e94 100644 --- a/server/api/cmContact/cmContact.attributes.js +++ b/server/api/cmContact/cmContact.attributes.js @@ -1 +1 @@ -const a125_0x3323=['STRING','exports','UNSIGNED','TEXT','INTEGER','NOW'];(function(_0x3f39f7,_0x332393){const _0x3e8e53=function(_0x5039d1){while(--_0x5039d1){_0x3f39f7['push'](_0x3f39f7['shift']());}};_0x3e8e53(++_0x332393);}(a125_0x3323,0x132));const a125_0x3e8e=function(_0x3f39f7,_0x332393){_0x3f39f7=_0x3f39f7-0x0;let _0x3e8e53=a125_0x3323[_0x3f39f7];return _0x3e8e53;};const _0x202588=a125_0x3e8e;'use strict';const Sequelize=require('sequelize');module[_0x202588('0x1')]={'firstName':{'type':Sequelize[_0x202588('0x0')],'allowNull':![]},'lastName':{'type':Sequelize['STRING']},'street':{'type':Sequelize[_0x202588('0x0')]},'postalCode':{'type':Sequelize[_0x202588('0x0')]},'city':{'type':Sequelize['STRING']},'country':{'type':Sequelize['STRING']},'dateOfBirth':{'type':Sequelize[_0x202588('0x0')]},'description':{'type':Sequelize[_0x202588('0x3')]},'phone':{'type':Sequelize['STRING']},'mobile':{'type':Sequelize[_0x202588('0x0')]},'fax':{'type':Sequelize[_0x202588('0x0')]},'email':{'type':Sequelize['STRING']},'url':{'type':Sequelize[_0x202588('0x0')]},'facebook':{'type':Sequelize[_0x202588('0x0')]},'fb_data':{'type':Sequelize[_0x202588('0x0')]},'twitter':{'type':Sequelize[_0x202588('0x0')]},'skype':{'type':Sequelize['STRING']},'teams':{'type':Sequelize['STRING']},'viber':{'type':Sequelize[_0x202588('0x0')]},'line':{'type':Sequelize[_0x202588('0x0')]},'wechat':{'type':Sequelize[_0x202588('0x0')]},'telegram':{'type':Sequelize['STRING']},'UserId':{'type':Sequelize[_0x202588('0x4')]},'priority':{'type':Sequelize[_0x202588('0x4')](0x2)[_0x202588('0x2')],'defaultValue':0x2,'validate':{'min':0x0,'max':0x4}},'scheduledat':{'type':Sequelize['DATE'],'defaultValue':Sequelize[_0x202588('0x5')]}}; \ No newline at end of file +const a125_0x52be=['TEXT','INTEGER','sequelize','STRING','exports'];(function(_0x2aa893,_0x52be11){const _0x35e187=function(_0x4ab6e2){while(--_0x4ab6e2){_0x2aa893['push'](_0x2aa893['shift']());}};_0x35e187(++_0x52be11);}(a125_0x52be,0x1e8));const a125_0x35e1=function(_0x2aa893,_0x52be11){_0x2aa893=_0x2aa893-0x0;let _0x35e187=a125_0x52be[_0x2aa893];return _0x35e187;};const _0x3d9d64=a125_0x35e1;'use strict';const Sequelize=require(_0x3d9d64('0x4'));module[_0x3d9d64('0x1')]={'firstName':{'type':Sequelize['STRING'],'allowNull':![]},'lastName':{'type':Sequelize['STRING']},'street':{'type':Sequelize['STRING']},'postalCode':{'type':Sequelize['STRING']},'city':{'type':Sequelize['STRING']},'country':{'type':Sequelize[_0x3d9d64('0x0')]},'dateOfBirth':{'type':Sequelize[_0x3d9d64('0x0')]},'description':{'type':Sequelize[_0x3d9d64('0x2')]},'phone':{'type':Sequelize[_0x3d9d64('0x0')]},'mobile':{'type':Sequelize[_0x3d9d64('0x0')]},'fax':{'type':Sequelize[_0x3d9d64('0x0')]},'email':{'type':Sequelize[_0x3d9d64('0x0')]},'url':{'type':Sequelize[_0x3d9d64('0x0')]},'facebook':{'type':Sequelize[_0x3d9d64('0x0')]},'fb_data':{'type':Sequelize['STRING']},'twitter':{'type':Sequelize['STRING']},'skype':{'type':Sequelize['STRING']},'teams':{'type':Sequelize[_0x3d9d64('0x0')]},'viber':{'type':Sequelize['STRING']},'line':{'type':Sequelize[_0x3d9d64('0x0')]},'wechat':{'type':Sequelize['STRING']},'telegram':{'type':Sequelize[_0x3d9d64('0x0')]},'UserId':{'type':Sequelize[_0x3d9d64('0x3')]},'priority':{'type':Sequelize[_0x3d9d64('0x3')](0x2)['UNSIGNED'],'defaultValue':0x2,'validate':{'min':0x0,'max':0x4}},'scheduledat':{'type':Sequelize['DATE'],'defaultValue':Sequelize['NOW']}}; \ No newline at end of file diff --git a/server/api/cmContact/cmContact.controller.js b/server/api/cmContact/cmContact.controller.js index 37836c2..e4d4430 100644 --- a/server/api/cmContact/cmContact.controller.js +++ b/server/api/cmContact/cmContact.controller.js @@ -1 +1 @@ -const a126_0x3df0=['binding_values','JscriptySessionReport','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','filename','t.id\x20IN\x20?','duplicates','attributes','from','fieldType','find','omit','createReadStream','ids','isNil','count','cf_','model','c.email','pid','c.deletedAt\x20IS\x20NULL','register','CmHopper','offset','error','fork','text','No\x20association\x20values\x20specified!','Content-Range','merge','nolimit','SmsInteraction','startsWith','Contact','user','MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','conditions','mergeWith','binding','catch','ChatOfflineMessage','select','No\x20ListId\x20specified','displayName','../../config/environment','params','../../components/import/cm/csv2','c.lastName\x20LIKE\x20?','trimStart','map','push','buildExpression','tag','body','./cmContact.socket','binding_keys','field','CmCustomField','[CmContact][merge][destroy][CmHopperBlack],\x20%s','ChatMessage','c.id','No\x20phone\x20column\x20specified','isNumeric','datetime','pickBy','rows','isArray','OpenchannelInteraction','tags','\x27\x27\x27\x27','sort','sequelize','MailInteraction','set','parse','then','setTags','getHopperHistories','format','Tags','FaxMessage','child_process','CmContact','c.fax','findOrCreate','fields','message','CmHopperHistory','custom','name','parseSearch','../../components/import/cm/csv','intersection','FaxInteraction','toParam','getHopperFinals','MailMessage','some','castTo','getFullTextValue','Unable\x20to\x20synchronize\x20socket,\x20no\x20timestamp\x20passed','firstName','forEach','include','root','update','c.firstName','import','../../components/parsers/qs','\x20=\x20?','stringify','and','CmHopperFinal','alias','c.ListId\x20IS\x20NULL','clone','cm_user_has_contacts','uc.UserId\x20=\x20?','chmodSync','ContactId','status','ChatInteraction','path','c.mobile','expr','SmsQueueReport','toString','filter','CmHopperBlack','rawAttributes','OpenchannelMessage','undefined','squel','destroy','getLists','Incorrect\x20binding\x20parameters\x20passed!','id\x20=\x20?','DESC','uc.CmContactId\x20=\x20c.id','ChatQueueReport','[CmContact][merge][destroy][CmHopper],\x20%s','[CmContact][merge]\x20to\x20%s\x20from\x20%s','phone','c.email\x20LIKE\x20?','index','FaxQueueReport','options','json','getTags','SELECT','c.id\x20LIKE\x20?','value','limit','create','meta','papaparse','GROUP_CONCAT(DISTINCT\x20t.id)','uploadCsv','having','c.phone\x20LIKE\x20?','c.ListId','get','union','QueryTypes','group','type','cm_contacts','split','SmsMessage','findOne','tools_tags','OpenchannelQueueReport','each','color','values','includeAll','../../components/parsers/advancedSearch','search','t.id\x20=\x20ct.TagId','left_join','VoiceCallReport','filters','setFields','c.firstName\x20LIKE\x20?','zipObject','send','show','util','like','error\x20child\x20process','../../config/logger','keyBy','describe','User','ct.CmContactId\x20=\x20c.id','join','where','findAll','query','getJscriptySessions','start','pick','cf_%d','socket_timestamp','keys','info','upload','sqlOperator','all','0777','../../rediscache','getHoppers','ListId','stack','replace','c.ListId\x20IN\x20?','isEmpty','DATE','order','end','No\x20association\x20keys\x20specified!','Tag','length','columnName','agent','start\x20child\x20process\x20correctly!','../../mysqldb','No\x20firstName\x20column\x20specified','File\x20uploaded\x20correctly!','file','TagIds'];(function(_0x3dc8f9,_0x3df00e){const _0x690988=function(_0x2d01b1){while(--_0x2d01b1){_0x3dc8f9['push'](_0x3dc8f9['shift']());}};_0x690988(++_0x3df00e);}(a126_0x3df0,0x1af));const a126_0x6909=function(_0x3dc8f9,_0x3df00e){_0x3dc8f9=_0x3dc8f9-0x0;let _0x690988=a126_0x3df0[_0x3dc8f9];return _0x690988;};const _0x2998d3=a126_0x6909;'use strict';const util=require(_0x2998d3('0xd7')),path=require(_0x2998d3('0x96')),fs=require('fs'),_=require('lodash'),squel=require(_0x2998d3('0xa0')),Papa=require(_0x2998d3('0xb7')),{getSocket}=require(_0x2998d3('0x8')),socket=getSocket(),qs=require(_0x2998d3('0x88')),as=require(_0x2998d3('0xcc')),logger=require(_0x2998d3('0xda'))('api'),config=require(_0x2998d3('0x48')),db=require(_0x2998d3('0x18'))['db'],{Op}=require(_0x2998d3('0x63'));require(_0x2998d3('0x52'))[_0x2998d3('0x31')](socket);function respondWithResult(_0x2d01b1,_0x5838c9){return _0x5838c9=_0x5838c9||0xc8,function(_0x34fd2e){const _0x2a6732=a126_0x6909;if(_0x34fd2e)return _0x2d01b1[_0x2a6732('0x94')](_0x5838c9)['json'](_0x34fd2e);};}function respondWithFilteredResult(_0x492385,_0xddccc1){return function(_0x3966ab){const _0x58fc8b=a126_0x6909;if(_0x3966ab){const _0x1ddc64=_0x3966ab['count'],_0x3c7889=_0xddccc1[_0x58fc8b('0x33')];let _0x6fe89b=_0xddccc1[_0x58fc8b('0x33')]+_0xddccc1[_0x58fc8b('0xb4')],_0x1855df;return _0x6fe89b>=_0x1ddc64?(_0x6fe89b=_0x1ddc64,_0x1855df=0xc8):_0x1855df=0xce,_0x492385[_0x58fc8b('0x94')](_0x1855df),_0x492385[_0x58fc8b('0x65')](_0x58fc8b('0x38'),_0x3c7889+'-'+_0x6fe89b+'/'+_0x1ddc64)['json'](_0x3966ab);}return null;};}function saveUpdates(_0x15fdf9){return function(_0x9baef1){const _0x3a51c4=a126_0x6909;if(_0x9baef1)return _0x9baef1[_0x3a51c4('0x85')](_0x15fdf9)[_0x3a51c4('0x67')](function(_0x67c526){return _0x67c526;});return null;};}function removeEntity(_0x3b8271){return function(_0x35ccfa){const _0x438288=a126_0x6909;if(_0x35ccfa)return _0x35ccfa[_0x438288('0xa1')]()[_0x438288('0x67')](function(){const _0x85ff1a=_0x438288;_0x3b8271[_0x85ff1a('0x94')](0xcc)['end']();});};}function handleEntityNotFound(_0x1c4070){return function(_0x322874){return!_0x322874&&_0x1c4070['sendStatus'](0x194),_0x322874;};}function handleError(_0x36bd2f,_0x5a3493){return _0x5a3493=_0x5a3493||0x1f4,function(_0x374294){const _0x2f10f2=a126_0x6909;logger[_0x2f10f2('0x34')](_0x374294[_0x2f10f2('0xb')]),_0x374294[_0x2f10f2('0x75')]&&delete _0x374294[_0x2f10f2('0x75')],_0x36bd2f['status'](_0x5a3493)['send'](_0x374294);};}exports[_0x2998d3('0xac')]=function(_0x365682,_0x489848){const _0x1b3f1a=_0x2998d3,_0x3d5c1b={},_0x428888={},_0x39a2ac={'count':0x0,'rows':[]};return db[_0x1b3f1a('0x6e')][_0x1b3f1a('0xdc')]()[_0x1b3f1a('0x67')](function(_0xb264d3){const _0x3fada6=_0x1b3f1a,_0x4f4849=[];for(let _0x41d26d=0x0;_0x41d26d0x1)_0x39b198['or'](_0x577bd7('0x3f'),qs[_0x577bd7('0x7f')](_0x18f894),null);else{if(qs[_0x577bd7('0x5a')](_0x18f894))_0x39b198['or'](_0x577bd7('0xb2'),_0x18f894+'%'),_0x39b198['or'](_0x577bd7('0xbb'),_0x18f894+'%'),_0x39b198['or']('c.mobile\x20LIKE\x20?',_0x18f894+'%'),_0x39b198['or']('c.fax\x20LIKE\x20?',_0x18f894+'%');else qs['isEmail'](_0x18f894)?_0x39b198['or'](_0x577bd7('0xab'),_0x18f894+'%'):(_0x39b198['or'](_0x577bd7('0xd3'),'%'+_0x18f894+'%'),_0x39b198['or'](_0x577bd7('0x4b'),'%'+_0x18f894+'%'),_0x39b198['or']('c.email\x20LIKE\x20?','%'+_0x18f894+'%'));}}}_0x447341[_0x577bd7('0xe0')](_0x39b198),_0x447341[_0x577bd7('0xc0')](_0x577bd7('0x58'));let _0x3bf038={'type':db['Sequelize'][_0x577bd7('0xbf')][_0x577bd7('0xb1')],'raw':!![]};const _0xa5136c=_0x447341[_0x577bd7('0x8f')]()['field'](_0x577bd7('0x58'));_0x3d5c1b[_0x577bd7('0x10')]&&_0x3d5c1b['order'][_0x577bd7('0x82')](function(_0xcbb632){const _0x2a4344=_0x577bd7;_0x447341[_0x2a4344('0x10')]('c.'+_0xcbb632[0x0],_0xcbb632[0x1]===_0x2a4344('0xa5')?![]:!![]);}),!_[_0x577bd7('0xe')](_0x4a5289)&&(_0x447341[_0x577bd7('0xba')](_0x175874),_0xa5136c['where'](_0x577bd7('0x21'),_0x4a5289)),Promise['resolve']()[_0x577bd7('0x67')](function(){const _0x5d131f=_0x577bd7;if(_0x380179&&!_[_0x5d131f('0x7d')](_0x380179[_0x5d131f('0x40')],[_0x5d131f('0x54'),_0x5d131f('0xdd')]))return _0x365682[_0x5d131f('0x3e')][_0x5d131f('0xa2')]({'attributes':['id'],'raw':!![]})[_0x5d131f('0x67')](function(_0x23fb08){const _0x394a7e=_0x5d131f;_[_0x394a7e('0xe')](_0x23fb08)?(_0xa5136c[_0x394a7e('0xe0')]('c.ListId\x20IS\x20NULL'),_0x447341[_0x394a7e('0xe0')](_0x394a7e('0x8e'))):(_0xa5136c[_0x394a7e('0xe0')](_0x394a7e('0xd'),_[_0x394a7e('0x4d')](_0x23fb08,'id')),_0x447341[_0x394a7e('0xe0')](_0x394a7e('0xd'),_[_0x394a7e('0x4d')](_0x23fb08,'id')));});else return;})[_0x577bd7('0x67')](function(){const _0x5e520b=_0x577bd7;db[_0x5e520b('0x63')][_0x5e520b('0xe2')](_0xa5136c['toString'](),_0x3bf038)[_0x5e520b('0x67')](function(_0xf3ea84){const _0x236dad=_0x5e520b;_0x39a2ac[_0x236dad('0x2b')]=_0xf3ea84[_0x236dad('0x14')];if(_0x39a2ac['count']===0x0)return[];return db[_0x236dad('0x63')][_0x236dad('0xe2')](_0x5a07f4[_0x236dad('0x9a')](),_0x3bf038);})['then'](function(_0x373028){const _0x1fd5db=_0x5e520b;_0xe9ec61=_[_0x1fd5db('0xdb')](_0x373028,'id'),_0x3bf038=_[_0x1fd5db('0x39')](_0x3bf038,{'model':db[_0x1fd5db('0x6e')],'mapToModel':!![],'raw':!![],'nest':!![]});_0x365682[_0x1fd5db('0xe2')][_0x1fd5db('0x71')]?_0x3d5c1b[_0x1fd5db('0x23')][_0x1fd5db('0x82')](function(_0x2d63a2){_0x447341['field']('c.'+_0x2d63a2);}):(_0x447341[_0x1fd5db('0x54')](_0x1fd5db('0x58')),_0x447341['field'](_0x1fd5db('0x86')),_0x447341[_0x1fd5db('0x54')]('c.lastName'),_0x447341[_0x1fd5db('0x54')]('c.phone'),_0x447341[_0x1fd5db('0x54')](_0x1fd5db('0x97')),_0x447341[_0x1fd5db('0x54')](_0x1fd5db('0x6f')),_0x447341['field'](_0x1fd5db('0x2e')),_0x447341['field'](_0x1fd5db('0xbc')),_0x447341[_0x1fd5db('0x54')]('c.deletedAt'),_0x447341[_0x1fd5db('0x54')](_0x1fd5db('0xb8'),'TagIds'));if(_0x3d5c1b['limit'])_0x447341[_0x1fd5db('0xb4')](_0x3d5c1b[_0x1fd5db('0xb4')]);if(_0x3d5c1b[_0x1fd5db('0x33')])_0x447341['offset'](_0x3d5c1b[_0x1fd5db('0x33')]);return db['sequelize'][_0x1fd5db('0xe2')](_0x447341[_0x1fd5db('0x9a')](),_0x3bf038);})['then'](function(_0x4428a8){const _0x1a20b1=_0x5e520b;return _0x4428a8[_0x1a20b1('0x82')](function(_0x38e516){const _0x3cc2fc=_0x1a20b1;_0x38e516[_0x3cc2fc('0x1c')]&&(_0x38e516[_0x3cc2fc('0x6b')]=[],_0x38e516['TagIds'][_0x3cc2fc('0xc3')](',')[_0x3cc2fc('0x82')](function(_0x405240){const _0x5663b9=_0x3cc2fc;_0x38e516[_0x5663b9('0x6b')]['push'](_0xe9ec61[_0x405240]);})),delete _0x38e516['TagIds'];}),_0x39a2ac[_0x1a20b1('0x5d')]=_0x4428a8,_0x39a2ac;})['then'](respondWithFilteredResult(_0x489848,_0x3d5c1b));});})[_0x1b3f1a('0x43')](handleError(_0x489848,null));},exports[_0x2998d3('0xa1')]=function(_0x14fac8,_0x215317){const _0x542d8a=_0x2998d3;return db[_0x542d8a('0x6e')]['findOne']({'where':{'id':_0x14fac8[_0x542d8a('0x49')]['id']}})['then'](handleEntityNotFound(_0x215317,null))['then'](removeEntity(_0x215317,null))[_0x542d8a('0x43')](handleError(_0x215317,null));},exports['describe']=function(_0x5cca17,_0x51202b){const _0x38a24a=_0x2998d3;return db['CmContact']['describe']()[_0x38a24a('0x67')](function(_0x437797){const _0x4b5315=_0x38a24a;delete _0x437797[_0x4b5315('0x60')];for(let _0x6a7837=0x0;_0x6a7837=_0x8dd9b1?(_0x3bd870=_0x8dd9b1,_0x246f82=0xc8):_0x246f82=0xce,_0x39f54a[_0x2e70ba('0x19')](_0x246f82),_0x39f54a[_0x2e70ba('0x96')](_0x2e70ba('0x76'),_0x33e96a+'-'+_0x3bd870+'/'+_0x8dd9b1)[_0x2e70ba('0x1a')](_0x2ae1d8);}return null;};}function saveUpdates(_0x55cf33){return function(_0x4a7294){if(_0x4a7294)return _0x4a7294['update'](_0x55cf33)['then'](function(_0x570aa9){return _0x570aa9;});return null;};}function removeEntity(_0x69aa4f){return function(_0x3a839c){const _0x32044a=a126_0x35c2;if(_0x3a839c)return _0x3a839c[_0x32044a('0xb1')]()[_0x32044a('0x35')](function(){const _0x4c5f09=_0x32044a;_0x69aa4f[_0x4c5f09('0x19')](0xcc)[_0x4c5f09('0xb7')]();});};}function handleEntityNotFound(_0x59c3d3){return function(_0x58b31f){const _0x1746af=a126_0x35c2;return!_0x58b31f&&_0x59c3d3[_0x1746af('0x58')](0x194),_0x58b31f;};}function handleError(_0x232d47,_0x45469e){return _0x45469e=_0x45469e||0x1f4,function(_0x320508){const _0x46db6d=a126_0x35c2;logger['error'](_0x320508[_0x46db6d('0x74')]),_0x320508[_0x46db6d('0x5e')]&&delete _0x320508[_0x46db6d('0x5e')],_0x232d47[_0x46db6d('0x19')](_0x45469e)['send'](_0x320508);};}exports[_0x20442d('0x4f')]=function(_0x293f4d,_0x34edf6){const _0x3cdb9a=_0x20442d,_0x4426c4={},_0x356f42={},_0x130f98={'count':0x0,'rows':[]};return db[_0x3cdb9a('0x8')][_0x3cdb9a('0x53')]()[_0x3cdb9a('0x35')](function(_0x1690e8){const _0x29baf5=_0x3cdb9a,_0x57bc46=[];for(let _0x3aca13=0x0;_0x3aca130x1)_0x3cc62b['or']('MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs[_0x2544f6('0x78')](_0x4afab5),null);else{if(qs[_0x2544f6('0x95')](_0x4afab5))_0x3cc62b['or'](_0x2544f6('0xc6'),_0x4afab5+'%'),_0x3cc62b['or']('c.phone\x20LIKE\x20?',_0x4afab5+'%'),_0x3cc62b['or']('c.mobile\x20LIKE\x20?',_0x4afab5+'%'),_0x3cc62b['or'](_0x2544f6('0x2a'),_0x4afab5+'%');else qs['isEmail'](_0x4afab5)?_0x3cc62b['or'](_0x2544f6('0x64'),_0x4afab5+'%'):(_0x3cc62b['or'](_0x2544f6('0x49'),'%'+_0x4afab5+'%'),_0x3cc62b['or'](_0x2544f6('0x42'),'%'+_0x4afab5+'%'),_0x3cc62b['or']('c.email\x20LIKE\x20?','%'+_0x4afab5+'%'));}}}_0x693f52[_0x2544f6('0x3b')](_0x3cc62b),_0x693f52['group'](_0x2544f6('0xb2'));let _0x2848d9={'type':db['Sequelize'][_0x2544f6('0xa1')][_0x2544f6('0x92')],'raw':!![]};const _0x37131b=_0x693f52[_0x2544f6('0x1c')]()[_0x2544f6('0xc')](_0x2544f6('0xb2'));_0x4426c4[_0x2544f6('0x68')]&&_0x4426c4[_0x2544f6('0x68')][_0x2544f6('0xa8')](function(_0xce0f10){const _0x38e911=_0x2544f6;_0x693f52[_0x38e911('0x68')]('c.'+_0xce0f10[0x0],_0xce0f10[0x1]===_0x38e911('0x85')?![]:!![]);}),!_[_0x2544f6('0x70')](_0x1a76bf)&&(_0x693f52[_0x2544f6('0x44')](_0x8aebfd),_0x37131b[_0x2544f6('0x3b')](_0x2544f6('0x3a'),_0x1a76bf)),Promise[_0x2544f6('0xd')]()[_0x2544f6('0x35')](function(){const _0xe271f3=_0x2544f6;if(_0x4b558b&&!_['some'](_0x4b558b[_0xe271f3('0x26')],[_0xe271f3('0xc'),_0xe271f3('0x6a')]))return _0x293f4d[_0xe271f3('0x72')]['getLists']({'attributes':['id'],'raw':!![]})['then'](function(_0xb5d031){const _0x5d333e=_0xe271f3;_[_0x5d333e('0x70')](_0xb5d031)?(_0x37131b[_0x5d333e('0x3b')](_0x5d333e('0xaa')),_0x693f52['where'](_0x5d333e('0xaa'))):(_0x37131b[_0x5d333e('0x3b')](_0x5d333e('0x6f'),_[_0x5d333e('0xba')](_0xb5d031,'id')),_0x693f52[_0x5d333e('0x3b')](_0x5d333e('0x6f'),_['map'](_0xb5d031,'id')));});else return;})['then'](function(){const _0x21cdbc=_0x2544f6;db[_0x21cdbc('0xbd')][_0x21cdbc('0x56')](_0x37131b['toString'](),_0x2848d9)[_0x21cdbc('0x35')](function(_0xde01b1){const _0x9f3bd6=_0x21cdbc;_0x130f98[_0x9f3bd6('0x7f')]=_0xde01b1[_0x9f3bd6('0x6b')];if(_0x130f98[_0x9f3bd6('0x7f')]===0x0)return[];return db[_0x9f3bd6('0xbd')]['query'](_0x38755c[_0x9f3bd6('0x5d')](),_0x2848d9);})['then'](function(_0x27e01e){const _0x52906a=_0x21cdbc;_0x5b9f2b=_[_0x52906a('0x1')](_0x27e01e,'id'),_0x2848d9=_[_0x52906a('0x28')](_0x2848d9,{'model':db['CmContact'],'mapToModel':!![],'raw':!![],'nest':!![]});_0x293f4d[_0x52906a('0x56')][_0x52906a('0xc3')]?_0x4426c4[_0x52906a('0x5f')][_0x52906a('0xa8')](function(_0x21287f){const _0x5bfc9e=_0x52906a;_0x693f52[_0x5bfc9e('0xc')]('c.'+_0x21287f);}):(_0x693f52[_0x52906a('0xc')](_0x52906a('0xb2')),_0x693f52['field']('c.firstName'),_0x693f52[_0x52906a('0xc')](_0x52906a('0x6d')),_0x693f52[_0x52906a('0xc')](_0x52906a('0x17')),_0x693f52['field'](_0x52906a('0x27')),_0x693f52['field'](_0x52906a('0x9')),_0x693f52[_0x52906a('0xc')](_0x52906a('0x65')),_0x693f52[_0x52906a('0xc')](_0x52906a('0xc8')),_0x693f52['field']('c.deletedAt'),_0x693f52['field'](_0x52906a('0xc1'),_0x52906a('0x14')));if(_0x4426c4[_0x52906a('0x9e')])_0x693f52['limit'](_0x4426c4[_0x52906a('0x9e')]);if(_0x4426c4[_0x52906a('0x4b')])_0x693f52['offset'](_0x4426c4[_0x52906a('0x4b')]);return db[_0x52906a('0xbd')][_0x52906a('0x56')](_0x693f52[_0x52906a('0x5d')](),_0x2848d9);})['then'](function(_0x24efeb){const _0x43a265=_0x21cdbc;return _0x24efeb[_0x43a265('0xa8')](function(_0x2139ec){const _0x57fa2f=_0x43a265;_0x2139ec[_0x57fa2f('0x14')]&&(_0x2139ec[_0x57fa2f('0x97')]=[],_0x2139ec[_0x57fa2f('0x14')][_0x57fa2f('0x80')](',')[_0x57fa2f('0xa8')](function(_0x3da64d){const _0x42c12c=_0x57fa2f;_0x2139ec[_0x42c12c('0x97')][_0x42c12c('0x0')](_0x5b9f2b[_0x3da64d]);})),delete _0x2139ec[_0x57fa2f('0x14')];}),_0x130f98[_0x43a265('0x15')]=_0x24efeb,_0x130f98;})[_0x21cdbc('0x35')](respondWithFilteredResult(_0x34edf6,_0x4426c4));});})[_0x3cdb9a('0x1b')](handleError(_0x34edf6,null));},exports[_0x20442d('0xb1')]=function(_0x4ad258,_0x354b86){const _0x3faebe=_0x20442d;return db[_0x3faebe('0x8')]['findOne']({'where':{'id':_0x4ad258[_0x3faebe('0x9b')]['id']}})['then'](handleEntityNotFound(_0x354b86,null))[_0x3faebe('0x35')](removeEntity(_0x354b86,null))[_0x3faebe('0x1b')](handleError(_0x354b86,null));},exports[_0x20442d('0x53')]=function(_0x15c3ef,_0x203e45){const _0x5e4ec9=_0x20442d;return db[_0x5e4ec9('0x8')][_0x5e4ec9('0x53')]()[_0x5e4ec9('0x35')](function(_0x2e223f){const _0x3f3a47=_0x5e4ec9;delete _0x2e223f['tags'];for(let _0x1c7c84=0x0;_0x1c7c84{}\s\\|]/g,'-'),_0x522d43(null,util['format'](_0x487c6a('0x29'),path['basename'](_0x589bb7[_0x487c6a('0x21')],path[_0x487c6a('0xc')](_0x589bb7[_0x487c6a('0x21')])),Date['now'](),path[_0x487c6a('0xc')](_0x589bb7[_0x487c6a('0x21')])));}})});router[_0x3971da('0x1a')]('/',auth[_0x3971da('0x12')](),controller['index']),router[_0x3971da('0x1a')]('/describe',auth[_0x3971da('0x12')](),controller[_0x3971da('0x1c')]),router[_0x3971da('0x1a')](_0x3971da('0x19'),auth[_0x3971da('0x12')](),controller[_0x3971da('0xb')]),router[_0x3971da('0x1a')](_0x3971da('0x13'),auth[_0x3971da('0x12')](),controller['getTags']),router['get'](_0x3971da('0x14'),auth[_0x3971da('0x12')](),controller[_0x3971da('0x16')]),router[_0x3971da('0x1a')](_0x3971da('0x1e'),auth['isAuthenticated'](),controller[_0x3971da('0x5')]),router[_0x3971da('0x1a')](_0x3971da('0x26'),auth[_0x3971da('0x12')](),controller['getHopperFinals']),router[_0x3971da('0x1a')](_0x3971da('0x8'),auth[_0x3971da('0x12')](),controller[_0x3971da('0xd')]),router[_0x3971da('0x24')](_0x3971da('0x1b'),auth[_0x3971da('0x12')](),controller['merge']),router[_0x3971da('0x24')]('/',auth[_0x3971da('0x12')](),controller[_0x3971da('0x10')]),router[_0x3971da('0x24')](_0x3971da('0x2'),auth[_0x3971da('0x12')](),controller[_0x3971da('0x6')]),router[_0x3971da('0x24')](_0x3971da('0x13'),auth[_0x3971da('0x12')](),controller[_0x3971da('0x25')]),router[_0x3971da('0x24')](_0x3971da('0x4'),upload[_0x3971da('0x3')](_0x3971da('0x1f')),controller[_0x3971da('0x9')]),router['post'](_0x3971da('0x1'),upload[_0x3971da('0x3')]('file'),controller[_0x3971da('0x28')]),router[_0x3971da('0x24')]('/upload/:id',auth[_0x3971da('0x12')](),controller[_0x3971da('0x27')]),router[_0x3971da('0x15')]('/:id',auth[_0x3971da('0x12')](),controller['update']),router['delete'](_0x3971da('0x19'),auth[_0x3971da('0x12')](),controller[_0x3971da('0xe')]),module['exports']=router; \ No newline at end of file +const a131_0x5c6c=['isAuthenticated','upload','originalname','format','show','express','setTags','/:id/tags','import','get','root','update','/describe','/merge','delete','getJscriptySessions','getHoppers','bulkCreate','/:id/hopper_finals','getHopperHistories','/:id/jscripty_sessions','getTags','put','describe','basename','/:id/hopper_histories','file','merge','now','extname','files/tmp','/:id/hoppers','destroy','single','create','/:id','exports','post','diskStorage','../../config/environment','getHopperFinals'];(function(_0x478d6a,_0x5c6c63){const _0x5ed863=function(_0x6020ef){while(--_0x6020ef){_0x478d6a['push'](_0x478d6a['shift']());}};_0x5ed863(++_0x5c6c63);}(a131_0x5c6c,0x94));const a131_0x5ed8=function(_0x478d6a,_0x5c6c63){_0x478d6a=_0x478d6a-0x0;let _0x5ed863=a131_0x5c6c[_0x478d6a];return _0x5ed863;};const _0x11112f=a131_0x5ed8;'use strict';const multer=require('multer'),util=require('util'),path=require('path'),express=require(_0x11112f('0x15')),router=express['Router'](),auth=require('../../components/auth/service'),config=require(_0x11112f('0xe')),controller=require('./cmContact.controller'),upload=multer({'storage':multer[_0x11112f('0xd')]({'destination':function(_0x6020ef,_0x1c6a05,_0x59c5e6){const _0x53d84e=_0x11112f;_0x59c5e6(null,path['join'](config[_0x53d84e('0x1a')],_0x53d84e('0x5')));},'filename':function(_0x4ef32d,_0x59dba8,_0x5d73cf){const _0x1819b2=_0x11112f;_0x59dba8[_0x1819b2('0x12')]=_0x59dba8[_0x1819b2('0x12')]['replace'](/[+@&-/\\#,+()$~%'":*?<>{}\s\\|]/g,'-'),_0x5d73cf(null,util[_0x1819b2('0x13')]('%s-%s%s',path[_0x1819b2('0x28')](_0x59dba8['originalname'],path[_0x1819b2('0x4')](_0x59dba8[_0x1819b2('0x12')])),Date[_0x1819b2('0x3')](),path['extname'](_0x59dba8[_0x1819b2('0x12')])));}})});router['get']('/',auth['isAuthenticated'](),controller['index']),router['get'](_0x11112f('0x1c'),auth[_0x11112f('0x10')](),controller[_0x11112f('0x27')]),router['get'](_0x11112f('0xa'),auth[_0x11112f('0x10')](),controller[_0x11112f('0x14')]),router[_0x11112f('0x19')](_0x11112f('0x17'),auth['isAuthenticated'](),controller[_0x11112f('0x25')]),router[_0x11112f('0x19')](_0x11112f('0x6'),auth[_0x11112f('0x10')](),controller[_0x11112f('0x20')]),router[_0x11112f('0x19')](_0x11112f('0x0'),auth['isAuthenticated'](),controller[_0x11112f('0x23')]),router[_0x11112f('0x19')](_0x11112f('0x22'),auth[_0x11112f('0x10')](),controller[_0x11112f('0xf')]),router['get'](_0x11112f('0x24'),auth[_0x11112f('0x10')](),controller[_0x11112f('0x1f')]),router[_0x11112f('0xc')](_0x11112f('0x1d'),auth[_0x11112f('0x10')](),controller[_0x11112f('0x2')]),router[_0x11112f('0xc')]('/',auth[_0x11112f('0x10')](),controller[_0x11112f('0x9')]),router['post']('/create_many',auth[_0x11112f('0x10')](),controller[_0x11112f('0x21')]),router['post'](_0x11112f('0x17'),auth[_0x11112f('0x10')](),controller[_0x11112f('0x16')]),router[_0x11112f('0xc')]('/csv',upload[_0x11112f('0x8')](_0x11112f('0x1')),controller['uploadCsv']),router['post']('/upload',upload[_0x11112f('0x8')](_0x11112f('0x1')),controller[_0x11112f('0x11')]),router[_0x11112f('0xc')]('/upload/:id',auth[_0x11112f('0x10')](),controller[_0x11112f('0x18')]),router[_0x11112f('0x26')](_0x11112f('0xa'),auth[_0x11112f('0x10')](),controller[_0x11112f('0x1b')]),router[_0x11112f('0x1e')]('/:id',auth[_0x11112f('0x10')](),controller[_0x11112f('0x7')]),module[_0x11112f('0xb')]=router; \ No newline at end of file diff --git a/server/api/cmCustomField/cmCustomField.attributes.js b/server/api/cmCustomField/cmCustomField.attributes.js index 81992fe..aaaf01f 100644 --- a/server/api/cmCustomField/cmCustomField.attributes.js +++ b/server/api/cmCustomField/cmCustomField.attributes.js @@ -1 +1 @@ -const a132_0x4a14=['select','TEXT','VIRTUAL','stringify','isArray','long','alias','parse','setDataValue','values','sequelize','BOOLEAN','STRING','name','getDataValue','voice'];(function(_0x396dab,_0x4a1439){const _0x2356af=function(_0x3e4932){while(--_0x3e4932){_0x396dab['push'](_0x396dab['shift']());}};_0x2356af(++_0x4a1439);}(a132_0x4a14,0x1f4));const a132_0x2356=function(_0x396dab,_0x4a1439){_0x396dab=_0x396dab-0x0;let _0x2356af=a132_0x4a14[_0x396dab];return _0x2356af;};const _0x14e3dc=a132_0x2356;'use strict';const Sequelize=require(_0x14e3dc('0x6'));module['exports']={'name':{'type':Sequelize[_0x14e3dc('0xe')],'get':function(){const _0x4dbc67=_0x14e3dc;return this[_0x4dbc67('0xa')](_0x4dbc67('0x2'));}},'alias':{'type':Sequelize['STRING'],'allowNull':![],'set':function(_0x3e4932){const _0x3d8796=_0x14e3dc;this[_0x3d8796('0x4')](_0x3d8796('0x2'),_0x3e4932?_0x3e4932:this[_0x3d8796('0xa')](_0x3d8796('0x9')));}},'type':{'type':Sequelize[_0x14e3dc('0x8')],'allowNull':![]},'values':{'type':Sequelize[_0x14e3dc('0xd')](_0x14e3dc('0x1')),'get':function(){const _0x257e2b=_0x14e3dc;return this['getDataValue']('type')===_0x257e2b('0xc')?JSON[_0x257e2b('0x3')](this['getDataValue']('values')):this[_0x257e2b('0xa')](_0x257e2b('0x5'));},'set':function(_0x484c2d){const _0x2515b4=_0x14e3dc;Array[_0x2515b4('0x0')](_0x484c2d)?this[_0x2515b4('0x4')](_0x2515b4('0x5'),JSON[_0x2515b4('0xf')](_0x484c2d)):this[_0x2515b4('0x4')](_0x2515b4('0x5'),_0x484c2d);}},'required':{'type':Sequelize[_0x14e3dc('0x7')],'defaultValue':![]},'clickToAction':{'type':Sequelize[_0x14e3dc('0x7')],'defaultValue':![]},'actionType':{'type':Sequelize['ENUM'](_0x14e3dc('0xb'))}}; \ No newline at end of file +const a132_0x6e57=['values','BOOLEAN','type','TEXT','parse','setDataValue','STRING','getDataValue','long','VIRTUAL','stringify','alias','sequelize','voice','isArray'];(function(_0x52aa53,_0x6e57d0){const _0xce64ac=function(_0x8c3c77){while(--_0x8c3c77){_0x52aa53['push'](_0x52aa53['shift']());}};_0xce64ac(++_0x6e57d0);}(a132_0x6e57,0x9b));const a132_0xce64=function(_0x52aa53,_0x6e57d0){_0x52aa53=_0x52aa53-0x0;let _0xce64ac=a132_0x6e57[_0x52aa53];return _0xce64ac;};const _0x42eb0d=a132_0xce64;'use strict';const Sequelize=require(_0x42eb0d('0x7'));module['exports']={'name':{'type':Sequelize[_0x42eb0d('0x4')],'get':function(){const _0xe22ed3=_0x42eb0d;return this[_0xe22ed3('0x2')]('alias');}},'alias':{'type':Sequelize[_0x42eb0d('0x1')],'allowNull':![],'set':function(_0x8c3c77){const _0x4719a2=_0x42eb0d;this[_0x4719a2('0x0')](_0x4719a2('0x6'),_0x8c3c77?_0x8c3c77:this[_0x4719a2('0x2')]('name'));}},'type':{'type':Sequelize['STRING'],'allowNull':![]},'values':{'type':Sequelize[_0x42eb0d('0xd')](_0x42eb0d('0x3')),'get':function(){const _0xd49c8d=_0x42eb0d;return this[_0xd49c8d('0x2')](_0xd49c8d('0xc'))==='select'?JSON[_0xd49c8d('0xe')](this[_0xd49c8d('0x2')](_0xd49c8d('0xa'))):this[_0xd49c8d('0x2')](_0xd49c8d('0xa'));},'set':function(_0x4cf9fa){const _0x58e553=_0x42eb0d;Array[_0x58e553('0x9')](_0x4cf9fa)?this[_0x58e553('0x0')](_0x58e553('0xa'),JSON[_0x58e553('0x5')](_0x4cf9fa)):this[_0x58e553('0x0')](_0x58e553('0xa'),_0x4cf9fa);}},'required':{'type':Sequelize[_0x42eb0d('0xb')],'defaultValue':![]},'clickToAction':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'actionType':{'type':Sequelize['ENUM'](_0x42eb0d('0x8'))}}; \ No newline at end of file diff --git a/server/api/cmCustomField/cmCustomField.controller.js b/server/api/cmCustomField/cmCustomField.controller.js index 291ae1c..da6be1f 100644 --- a/server/api/cmCustomField/cmCustomField.controller.js +++ b/server/api/cmCustomField/cmCustomField.controller.js @@ -1 +1 @@ -const a133_0x3561=['transaction','intersection','error','sequelize','findAll','nolimit','index','switch','text','filters','filter','query','body','includeAll','VIRTUAL','offset','lodash','length','create','set','merge','update','Content-Range','cf_%d','then','status','api','catch','sort','addColumn','attributes','fields','count','pick','destroy','keys','sendStatus','include','map','Sequelize','queryInterface','findOne','../../mysqldb','TEXT','like','key','format','BOOLEAN','type','CmCustomField','json','name','options','params','../../components/parsers/qs','util','limit','fieldName','where','defaultValue','order','number','rawAttributes','model'];(function(_0x411914,_0x3561ef){const _0x12aa1e=function(_0x23c033){while(--_0x23c033){_0x411914['push'](_0x411914['shift']());}};_0x12aa1e(++_0x3561ef);}(a133_0x3561,0x110));const a133_0x12aa=function(_0x411914,_0x3561ef){_0x411914=_0x411914-0x0;let _0x12aa1e=a133_0x3561[_0x411914];return _0x12aa1e;};const _0x210921=a133_0x12aa;'use strict';const util=require(_0x210921('0x27')),_=require(_0x210921('0x0')),qs=require(_0x210921('0x26')),logger=require('../../config/logger')(_0x210921('0xa')),db=require(_0x210921('0x1a'))['db'],{Op}=require(_0x210921('0x33'));function respondWithResult(_0x23c033,_0x585276){return _0x585276=_0x585276||0xc8,function(_0x518c20){const _0x1d160c=a133_0x12aa;if(_0x518c20)return _0x23c033[_0x1d160c('0x9')](_0x585276)[_0x1d160c('0x22')](_0x518c20);};}function respondWithFilteredResult(_0x1613c7,_0x4faa9a){return function(_0x257821){const _0x42f9f8=a133_0x12aa;if(_0x257821){const _0x1d6e9d=_0x257821['count'],_0x1aa2eb=_0x4faa9a[_0x42f9f8('0x3f')];let _0x5af7e2=_0x4faa9a[_0x42f9f8('0x3f')]+_0x4faa9a[_0x42f9f8('0x28')],_0x56e08d;return _0x5af7e2>=_0x1d6e9d?(_0x5af7e2=_0x1d6e9d,_0x56e08d=0xc8):_0x56e08d=0xce,_0x1613c7[_0x42f9f8('0x9')](_0x56e08d),_0x1613c7[_0x42f9f8('0x3')](_0x42f9f8('0x6'),_0x1aa2eb+'-'+_0x5af7e2+'/'+_0x1d6e9d)[_0x42f9f8('0x22')](_0x257821);}return null;};}function saveUpdates(_0x39ab6f){return function(_0x29beca){const _0x29444f=a133_0x12aa;if(_0x29beca)return _0x29beca[_0x29444f('0x5')](_0x39ab6f)[_0x29444f('0x8')](function(_0x110463){return _0x110463;});return null;};}function removeEntity(_0x15945b){return function(_0x55f10b){const _0x31a24f=a133_0x12aa;if(_0x55f10b)return _0x55f10b[_0x31a24f('0x12')]()[_0x31a24f('0x8')](function(){const _0x5511b9=_0x31a24f;_0x15945b[_0x5511b9('0x9')](0xcc)['end']();});};}function handleEntityNotFound(_0x5309f5){return function(_0x417582){const _0x33d104=a133_0x12aa;return!_0x417582&&_0x5309f5[_0x33d104('0x14')](0x194),_0x417582;};}function handleError(_0x22fc30,_0x23a7fb){return _0x23a7fb=_0x23a7fb||0x1f4,function(_0x4dbe0c){const _0x48851c=a133_0x12aa;logger[_0x48851c('0x32')](_0x4dbe0c['stack']),_0x4dbe0c[_0x48851c('0x23')]&&delete _0x4dbe0c[_0x48851c('0x23')],_0x22fc30[_0x48851c('0x9')](_0x23a7fb)['send'](_0x4dbe0c);};}exports[_0x210921('0x36')]=function(_0x44296c,_0x270116){const _0x1c16c1=_0x210921;let _0x5d19dc={};const _0x58a03f={},_0xd99cf7={'count':0x0,'rows':[]},_0x368f0b=_[_0x1c16c1('0x16')](db[_0x1c16c1('0x21')][_0x1c16c1('0x2e')],function(_0x162780){const _0x5074a7=_0x1c16c1;return{'name':_0x162780[_0x5074a7('0x29')],'type':_0x162780[_0x5074a7('0x20')][_0x5074a7('0x1d')]};});_0x58a03f[_0x1c16c1('0x2f')]=_['differenceBy'](_[_0x1c16c1('0x16')](_0x368f0b,_0x1c16c1('0x23')),[_0x1c16c1('0x23')]),_0x58a03f[_0x1c16c1('0x3b')]=_[_0x1c16c1('0x13')](_0x44296c[_0x1c16c1('0x3b')]),_0x58a03f['filters']=_[_0x1c16c1('0x31')](_0x58a03f[_0x1c16c1('0x2f')],_0x58a03f['query']),_0x5d19dc[_0x1c16c1('0xe')]=_['intersection'](_0x58a03f[_0x1c16c1('0x2f')],qs['fields'](_0x44296c[_0x1c16c1('0x3b')]['fields'])),_0x5d19dc[_0x1c16c1('0xe')]=_0x5d19dc[_0x1c16c1('0xe')]['length']?_0x5d19dc['attributes']:_0x58a03f[_0x1c16c1('0x2f')];typeof _0x44296c[_0x1c16c1('0x3b')][_0x1c16c1('0x35')]==='undefined'&&(_0x5d19dc[_0x1c16c1('0x28')]=qs[_0x1c16c1('0x28')](_0x44296c[_0x1c16c1('0x3b')][_0x1c16c1('0x28')]),_0x5d19dc[_0x1c16c1('0x3f')]=qs[_0x1c16c1('0x3f')](_0x44296c['query'][_0x1c16c1('0x3f')]));_0x5d19dc[_0x1c16c1('0x2c')]=qs[_0x1c16c1('0xc')](_0x44296c[_0x1c16c1('0x3b')][_0x1c16c1('0xc')]),_0x5d19dc[_0x1c16c1('0x2a')]=qs[_0x1c16c1('0x39')](_[_0x1c16c1('0x11')](_0x44296c['query'],_0x58a03f['filters']),_0x368f0b);_0x44296c[_0x1c16c1('0x3b')][_0x1c16c1('0x3a')]&&(_0x5d19dc['where']=_[_0x1c16c1('0x4')](_0x5d19dc[_0x1c16c1('0x2a')],{[Op['or']]:_[_0x1c16c1('0x16')](_0x368f0b,function(_0x5545c3){const _0x489229=_0x1c16c1;if(_0x5545c3['type']!==_0x489229('0x3e')){const _0x2b8d07={};return _0x2b8d07[_0x5545c3['name']]={[Op[_0x489229('0x1c')]]:'%'+_0x44296c[_0x489229('0x3b')][_0x489229('0x3a')]+'%'},_0x2b8d07;}})}));_0x5d19dc=_[_0x1c16c1('0x4')]({},_0x5d19dc,_0x44296c[_0x1c16c1('0x24')]);const _0x24c443={'where':_0x5d19dc[_0x1c16c1('0x2a')]};return db[_0x1c16c1('0x21')][_0x1c16c1('0x10')](_0x24c443)[_0x1c16c1('0x8')](function(_0x3123c6){const _0x1e5eb8=_0x1c16c1;return _0xd99cf7['count']=_0x3123c6,_0x44296c[_0x1e5eb8('0x3b')][_0x1e5eb8('0x3d')]&&(_0x5d19dc[_0x1e5eb8('0x15')]=[{'all':!![]}]),db[_0x1e5eb8('0x21')][_0x1e5eb8('0x34')](_0x5d19dc);})[_0x1c16c1('0x8')](function(_0x563985){return _0xd99cf7['rows']=_0x563985,_0xd99cf7;})[_0x1c16c1('0x8')](respondWithFilteredResult(_0x270116,_0x5d19dc))[_0x1c16c1('0xb')](handleError(_0x270116,null));},exports['show']=function(_0x2ddf8f,_0x3fbdb0){const _0x48917b=_0x210921;let _0xd6abc={'raw':!![],'where':{'id':_0x2ddf8f[_0x48917b('0x25')]['id']}};const _0x213a4b={};return _0x213a4b[_0x48917b('0x2f')]=_[_0x48917b('0x13')](db[_0x48917b('0x21')]['rawAttributes']),_0x213a4b['query']=_[_0x48917b('0x13')](_0x2ddf8f[_0x48917b('0x3b')]),_0x213a4b[_0x48917b('0x39')]=_[_0x48917b('0x31')](_0x213a4b['model'],_0x213a4b['query']),_0xd6abc['attributes']=_['intersection'](_0x213a4b['model'],qs['fields'](_0x2ddf8f['query'][_0x48917b('0xf')])),_0xd6abc['attributes']=_0xd6abc['attributes'][_0x48917b('0x1')]?_0xd6abc['attributes']:_0x213a4b[_0x48917b('0x2f')],_0x2ddf8f[_0x48917b('0x3b')]['includeAll']&&(_0xd6abc[_0x48917b('0x15')]=[{'all':!![]}]),_0xd6abc=_[_0x48917b('0x4')]({},_0xd6abc,_0x2ddf8f[_0x48917b('0x24')]),db[_0x48917b('0x21')]['findOne'](_0xd6abc)[_0x48917b('0x8')](handleEntityNotFound(_0x3fbdb0,null))[_0x48917b('0x8')](respondWithResult(_0x3fbdb0,null))['catch'](handleError(_0x3fbdb0,null));},exports[_0x210921('0x5')]=function(_0x45276a,_0x5943b3){const _0x279ca4=_0x210921;return _0x45276a[_0x279ca4('0x3c')]['id']&&delete _0x45276a['body']['id'],db[_0x279ca4('0x21')][_0x279ca4('0x19')]({'where':{'id':_0x45276a[_0x279ca4('0x25')]['id']}})['then'](handleEntityNotFound(_0x5943b3,null))['then'](saveUpdates(_0x45276a['body'],null))[_0x279ca4('0x8')](respondWithResult(_0x5943b3,null))[_0x279ca4('0xb')](handleError(_0x5943b3,null));},exports['destroy']=function(_0x6ace,_0x301303){const _0x288011=_0x210921;return db[_0x288011('0x21')][_0x288011('0x19')]({'where':{'id':_0x6ace['params']['id']}})[_0x288011('0x8')](handleEntityNotFound(_0x301303,null))[_0x288011('0x8')](removeEntity(_0x301303,null))[_0x288011('0xb')](handleError(_0x301303,null));},exports[_0x210921('0x2')]=function(_0x1fc0a5,_0x21f2b7){const _0x85c94=_0x210921;let _0x1ee4ae;return db['sequelize'][_0x85c94('0x30')](function(_0xfa7bf4){const _0x524bfe=_0x85c94;return db[_0x524bfe('0x21')][_0x524bfe('0x2')](_0x1fc0a5[_0x524bfe('0x3c')],{'transaction':_0xfa7bf4})[_0x524bfe('0x8')](function(_0x25ff62){const _0x46102e=_0x524bfe;_0x1ee4ae=_0x25ff62;const _0x4935c4={'type':db[_0x46102e('0x17')][_0x46102e('0x1b')],'transaction':_0xfa7bf4};switch(_0x1fc0a5[_0x46102e('0x3c')][_0x46102e('0x20')]){case _0x46102e('0x38'):_0x4935c4[_0x46102e('0x20')]=db[_0x46102e('0x17')]['TEXT'];break;case _0x46102e('0x2d'):_0x4935c4[_0x46102e('0x20')]=db[_0x46102e('0x17')]['INTEGER'];break;case _0x46102e('0x37'):_0x4935c4[_0x46102e('0x20')]=db[_0x46102e('0x17')][_0x46102e('0x1f')],_0x4935c4[_0x46102e('0x2b')]=![];break;default:}return db[_0x46102e('0x33')][_0x46102e('0x18')][_0x46102e('0xd')]('cm_contacts',util[_0x46102e('0x1e')](_0x46102e('0x7'),_0x1ee4ae['id']),_0x4935c4);})[_0x524bfe('0x8')](function(){return _0x1ee4ae;});})[_0x85c94('0x8')](respondWithResult(_0x21f2b7,0xc9))[_0x85c94('0xb')](handleError(_0x21f2b7,null));}; \ No newline at end of file +const a133_0x538e=['where','options','merge','body','keys','length','util','model','query','set','error','cf_%d','../../config/logger','undefined','../../components/parsers/qs','CmCustomField','show','queryInterface','api','like','params','send','Sequelize','include','offset','findOne','limit','status','sequelize','findAll','name','intersection','BOOLEAN','fields','sort','cm_contacts','rawAttributes','text','Content-Range','nolimit','addColumn','fieldName','attributes','order','pick','differenceBy','json','INTEGER','number','type','then','catch','count','map','destroy','filters','update','create','rows','stack','format','TEXT','includeAll'];(function(_0x4d2272,_0x538e92){const _0x4be569=function(_0x583b04){while(--_0x583b04){_0x4d2272['push'](_0x4d2272['shift']());}};_0x4be569(++_0x538e92);}(a133_0x538e,0x98));const a133_0x4be5=function(_0x4d2272,_0x538e92){_0x4d2272=_0x4d2272-0x0;let _0x4be569=a133_0x538e[_0x4d2272];return _0x4be569;};const _0x2a63e4=a133_0x4be5;'use strict';const util=require(_0x2a63e4('0x2b')),_=require('lodash'),qs=require(_0x2a63e4('0x33')),logger=require(_0x2a63e4('0x31'))(_0x2a63e4('0x37')),db=require('../../mysqldb')['db'],{Op}=require(_0x2a63e4('0x2'));function respondWithResult(_0x583b04,_0x2121a7){return _0x2121a7=_0x2121a7||0xc8,function(_0xab31dd){const _0x3275f3=a133_0x4be5;if(_0xab31dd)return _0x583b04[_0x3275f3('0x1')](_0x2121a7)[_0x3275f3('0x14')](_0xab31dd);};}function respondWithFilteredResult(_0x3158e2,_0x1399c2){return function(_0xd1cf49){const _0x510b40=a133_0x4be5;if(_0xd1cf49){const _0x5d5305=_0xd1cf49[_0x510b40('0x1a')],_0x3178cb=_0x1399c2[_0x510b40('0x3d')];let _0x1fa77e=_0x1399c2[_0x510b40('0x3d')]+_0x1399c2[_0x510b40('0x0')],_0x5aa494;return _0x1fa77e>=_0x5d5305?(_0x1fa77e=_0x5d5305,_0x5aa494=0xc8):_0x5aa494=0xce,_0x3158e2[_0x510b40('0x1')](_0x5aa494),_0x3158e2[_0x510b40('0x2e')](_0x510b40('0xc'),_0x3178cb+'-'+_0x1fa77e+'/'+_0x5d5305)[_0x510b40('0x14')](_0xd1cf49);}return null;};}function saveUpdates(_0xba7d31){return function(_0x4c4221){const _0xadd38d=a133_0x4be5;if(_0x4c4221)return _0x4c4221[_0xadd38d('0x1e')](_0xba7d31)[_0xadd38d('0x18')](function(_0x908206){return _0x908206;});return null;};}function removeEntity(_0x5d3462){return function(_0x45730f){const _0x1b4e14=a133_0x4be5;if(_0x45730f)return _0x45730f[_0x1b4e14('0x1c')]()['then'](function(){_0x5d3462['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x4bfb94){return function(_0x111ea6){return!_0x111ea6&&_0x4bfb94['sendStatus'](0x194),_0x111ea6;};}function handleError(_0x149e13,_0x43c090){return _0x43c090=_0x43c090||0x1f4,function(_0x3b19bc){const _0x70ffdf=a133_0x4be5;logger[_0x70ffdf('0x2f')](_0x3b19bc[_0x70ffdf('0x21')]),_0x3b19bc['name']&&delete _0x3b19bc[_0x70ffdf('0x4')],_0x149e13[_0x70ffdf('0x1')](_0x43c090)[_0x70ffdf('0x3a')](_0x3b19bc);};}exports['index']=function(_0xb952e2,_0x5a7d52){const _0x58dcc6=_0x2a63e4;let _0x55c8ef={};const _0x494b21={},_0x556649={'count':0x0,'rows':[]},_0x6f5d97=_[_0x58dcc6('0x1b')](db[_0x58dcc6('0x34')][_0x58dcc6('0xa')],function(_0x341b89){const _0x15cf37=_0x58dcc6;return{'name':_0x341b89[_0x15cf37('0xf')],'type':_0x341b89[_0x15cf37('0x17')]['key']};});_0x494b21[_0x58dcc6('0x2c')]=_[_0x58dcc6('0x13')](_[_0x58dcc6('0x1b')](_0x6f5d97,_0x58dcc6('0x4')),[_0x58dcc6('0x4')]),_0x494b21['query']=_[_0x58dcc6('0x29')](_0xb952e2[_0x58dcc6('0x2d')]),_0x494b21[_0x58dcc6('0x1d')]=_[_0x58dcc6('0x5')](_0x494b21[_0x58dcc6('0x2c')],_0x494b21[_0x58dcc6('0x2d')]),_0x55c8ef[_0x58dcc6('0x10')]=_[_0x58dcc6('0x5')](_0x494b21[_0x58dcc6('0x2c')],qs[_0x58dcc6('0x7')](_0xb952e2[_0x58dcc6('0x2d')][_0x58dcc6('0x7')])),_0x55c8ef[_0x58dcc6('0x10')]=_0x55c8ef[_0x58dcc6('0x10')][_0x58dcc6('0x2a')]?_0x55c8ef[_0x58dcc6('0x10')]:_0x494b21[_0x58dcc6('0x2c')];typeof _0xb952e2[_0x58dcc6('0x2d')][_0x58dcc6('0xd')]===_0x58dcc6('0x32')&&(_0x55c8ef[_0x58dcc6('0x0')]=qs[_0x58dcc6('0x0')](_0xb952e2[_0x58dcc6('0x2d')][_0x58dcc6('0x0')]),_0x55c8ef['offset']=qs[_0x58dcc6('0x3d')](_0xb952e2[_0x58dcc6('0x2d')]['offset']));_0x55c8ef[_0x58dcc6('0x11')]=qs[_0x58dcc6('0x8')](_0xb952e2[_0x58dcc6('0x2d')][_0x58dcc6('0x8')]),_0x55c8ef[_0x58dcc6('0x25')]=qs[_0x58dcc6('0x1d')](_[_0x58dcc6('0x12')](_0xb952e2['query'],_0x494b21[_0x58dcc6('0x1d')]),_0x6f5d97);_0xb952e2[_0x58dcc6('0x2d')]['filter']&&(_0x55c8ef['where']=_[_0x58dcc6('0x27')](_0x55c8ef[_0x58dcc6('0x25')],{[Op['or']]:_[_0x58dcc6('0x1b')](_0x6f5d97,function(_0x1ed660){const _0x2dcb01=_0x58dcc6;if(_0x1ed660[_0x2dcb01('0x17')]!=='VIRTUAL'){const _0xd59206={};return _0xd59206[_0x1ed660['name']]={[Op[_0x2dcb01('0x38')]]:'%'+_0xb952e2[_0x2dcb01('0x2d')]['filter']+'%'},_0xd59206;}})}));_0x55c8ef=_[_0x58dcc6('0x27')]({},_0x55c8ef,_0xb952e2[_0x58dcc6('0x26')]);const _0x32a7de={'where':_0x55c8ef['where']};return db[_0x58dcc6('0x34')][_0x58dcc6('0x1a')](_0x32a7de)[_0x58dcc6('0x18')](function(_0x576a6f){const _0x38d337=_0x58dcc6;return _0x556649[_0x38d337('0x1a')]=_0x576a6f,_0xb952e2[_0x38d337('0x2d')][_0x38d337('0x24')]&&(_0x55c8ef[_0x38d337('0x3c')]=[{'all':!![]}]),db[_0x38d337('0x34')][_0x38d337('0x3')](_0x55c8ef);})[_0x58dcc6('0x18')](function(_0x2fcaa7){const _0x24744d=_0x58dcc6;return _0x556649[_0x24744d('0x20')]=_0x2fcaa7,_0x556649;})['then'](respondWithFilteredResult(_0x5a7d52,_0x55c8ef))['catch'](handleError(_0x5a7d52,null));},exports[_0x2a63e4('0x35')]=function(_0x3fbbaf,_0x3486f8){const _0x555081=_0x2a63e4;let _0x238600={'raw':!![],'where':{'id':_0x3fbbaf['params']['id']}};const _0x2e696e={};return _0x2e696e[_0x555081('0x2c')]=_[_0x555081('0x29')](db[_0x555081('0x34')][_0x555081('0xa')]),_0x2e696e['query']=_[_0x555081('0x29')](_0x3fbbaf[_0x555081('0x2d')]),_0x2e696e[_0x555081('0x1d')]=_[_0x555081('0x5')](_0x2e696e['model'],_0x2e696e[_0x555081('0x2d')]),_0x238600[_0x555081('0x10')]=_[_0x555081('0x5')](_0x2e696e[_0x555081('0x2c')],qs[_0x555081('0x7')](_0x3fbbaf[_0x555081('0x2d')][_0x555081('0x7')])),_0x238600['attributes']=_0x238600[_0x555081('0x10')][_0x555081('0x2a')]?_0x238600[_0x555081('0x10')]:_0x2e696e[_0x555081('0x2c')],_0x3fbbaf['query'][_0x555081('0x24')]&&(_0x238600[_0x555081('0x3c')]=[{'all':!![]}]),_0x238600=_[_0x555081('0x27')]({},_0x238600,_0x3fbbaf['options']),db[_0x555081('0x34')][_0x555081('0x3e')](_0x238600)[_0x555081('0x18')](handleEntityNotFound(_0x3486f8,null))[_0x555081('0x18')](respondWithResult(_0x3486f8,null))[_0x555081('0x19')](handleError(_0x3486f8,null));},exports[_0x2a63e4('0x1e')]=function(_0x99cac8,_0x30696f){const _0x3fbc96=_0x2a63e4;return _0x99cac8[_0x3fbc96('0x28')]['id']&&delete _0x99cac8[_0x3fbc96('0x28')]['id'],db[_0x3fbc96('0x34')][_0x3fbc96('0x3e')]({'where':{'id':_0x99cac8['params']['id']}})['then'](handleEntityNotFound(_0x30696f,null))[_0x3fbc96('0x18')](saveUpdates(_0x99cac8[_0x3fbc96('0x28')],null))[_0x3fbc96('0x18')](respondWithResult(_0x30696f,null))[_0x3fbc96('0x19')](handleError(_0x30696f,null));},exports[_0x2a63e4('0x1c')]=function(_0x44fdef,_0x41fc6b){const _0x19bba9=_0x2a63e4;return db[_0x19bba9('0x34')]['findOne']({'where':{'id':_0x44fdef[_0x19bba9('0x39')]['id']}})[_0x19bba9('0x18')](handleEntityNotFound(_0x41fc6b,null))[_0x19bba9('0x18')](removeEntity(_0x41fc6b,null))[_0x19bba9('0x19')](handleError(_0x41fc6b,null));},exports[_0x2a63e4('0x1f')]=function(_0x9ce701,_0x184372){const _0x1c098a=_0x2a63e4;let _0x2b769f;return db[_0x1c098a('0x2')]['transaction'](function(_0x322e70){const _0x4d0341=_0x1c098a;return db['CmCustomField'][_0x4d0341('0x1f')](_0x9ce701[_0x4d0341('0x28')],{'transaction':_0x322e70})['then'](function(_0x39986e){const _0x211c23=_0x4d0341;_0x2b769f=_0x39986e;const _0x56ffd2={'type':db[_0x211c23('0x3b')][_0x211c23('0x23')],'transaction':_0x322e70};switch(_0x9ce701[_0x211c23('0x28')][_0x211c23('0x17')]){case _0x211c23('0xb'):_0x56ffd2[_0x211c23('0x17')]=db[_0x211c23('0x3b')][_0x211c23('0x23')];break;case _0x211c23('0x16'):_0x56ffd2['type']=db[_0x211c23('0x3b')][_0x211c23('0x15')];break;case'switch':_0x56ffd2[_0x211c23('0x17')]=db['Sequelize'][_0x211c23('0x6')],_0x56ffd2['defaultValue']=![];break;default:}return db[_0x211c23('0x2')][_0x211c23('0x36')][_0x211c23('0xe')](_0x211c23('0x9'),util[_0x211c23('0x22')](_0x211c23('0x30'),_0x2b769f['id']),_0x56ffd2);})['then'](function(){return _0x2b769f;});})[_0x1c098a('0x18')](respondWithResult(_0x184372,0xc9))['catch'](handleError(_0x184372,null));}; \ No newline at end of file diff --git a/server/api/cmCustomField/cmCustomField.model.js b/server/api/cmCustomField/cmCustomField.model.js index 17eaa2f..a69328c 100644 --- a/server/api/cmCustomField/cmCustomField.model.js +++ b/server/api/cmCustomField/cmCustomField.model.js @@ -1 +1 @@ -const a134_0xaa58=['cm_custom_fields','define'];(function(_0x5185ca,_0xaa5862){const _0x45c68e=function(_0x449663){while(--_0x449663){_0x5185ca['push'](_0x5185ca['shift']());}};_0x45c68e(++_0xaa5862);}(a134_0xaa58,0x8f));const a134_0x45c6=function(_0x5185ca,_0xaa5862){_0x5185ca=_0x5185ca-0x0;let _0x45c68e=a134_0xaa58[_0x5185ca];return _0x45c68e;};'use strict';const attributes=require('./cmCustomField.attributes');module['exports']=function(_0x449663){const _0x487b15=a134_0x45c6,_0x46525c=_0x449663[_0x487b15('0x0')]('CmCustomField',attributes,{'tableName':_0x487b15('0x1'),'paranoid':!![],'indexes':[],'timestamps':!![]});return _0x46525c;}; \ No newline at end of file +const a134_0x58d3=['define','./cmCustomField.attributes'];(function(_0x498850,_0x58d37a){const _0x51ef4f=function(_0x4551eb){while(--_0x4551eb){_0x498850['push'](_0x498850['shift']());}};_0x51ef4f(++_0x58d37a);}(a134_0x58d3,0x1e3));const a134_0x51ef=function(_0x498850,_0x58d37a){_0x498850=_0x498850-0x0;let _0x51ef4f=a134_0x58d3[_0x498850];return _0x51ef4f;};const _0x1b8ab6=a134_0x51ef;'use strict';const attributes=require(_0x1b8ab6('0x0'));module['exports']=function(_0x4551eb){const _0x316756=_0x1b8ab6,_0x370790=_0x4551eb[_0x316756('0x1')]('CmCustomField',attributes,{'tableName':'cm_custom_fields','paranoid':!![],'indexes':[],'timestamps':!![]});return _0x370790;}; \ No newline at end of file diff --git a/server/api/cmCustomField/index.js b/server/api/cmCustomField/index.js index f13f53d..d4b4b60 100644 --- a/server/api/cmCustomField/index.js +++ b/server/api/cmCustomField/index.js @@ -1 +1 @@ -const a135_0x55d4=['get','update','isAuthenticated','put','./cmCustomField.controller','Router','show','express','/:id','exports','../../components/auth/service','delete','index','create'];(function(_0x2fc000,_0x55d415){const _0x4fa9b4=function(_0x9241b4){while(--_0x9241b4){_0x2fc000['push'](_0x2fc000['shift']());}};_0x4fa9b4(++_0x55d415);}(a135_0x55d4,0xe3));const a135_0x4fa9=function(_0x2fc000,_0x55d415){_0x2fc000=_0x2fc000-0x0;let _0x4fa9b4=a135_0x55d4[_0x2fc000];return _0x4fa9b4;};const _0x110227=a135_0x4fa9;'use strict';const express=require(_0x110227('0x4')),router=express[_0x110227('0x2')](),auth=require(_0x110227('0x7')),controller=require(_0x110227('0x1'));router['get']('/',auth[_0x110227('0xd')](),controller[_0x110227('0x9')]),router[_0x110227('0xb')](_0x110227('0x5'),auth[_0x110227('0xd')](),controller[_0x110227('0x3')]),router['post']('/',auth[_0x110227('0xd')](),controller[_0x110227('0xa')]),router[_0x110227('0x0')](_0x110227('0x5'),auth[_0x110227('0xd')](),controller[_0x110227('0xc')]),router[_0x110227('0x8')]('/:id',auth[_0x110227('0xd')](),controller['destroy']),module[_0x110227('0x6')]=router; \ No newline at end of file +const a135_0x502d=['get','put','isAuthenticated','./cmCustomField.controller','Router','destroy','create','../../components/auth/service','index','show','update','exports','post','/:id','delete'];(function(_0x1fd89d,_0x502d13){const _0x690100=function(_0x4f105d){while(--_0x4f105d){_0x1fd89d['push'](_0x1fd89d['shift']());}};_0x690100(++_0x502d13);}(a135_0x502d,0x1e8));const a135_0x6901=function(_0x1fd89d,_0x502d13){_0x1fd89d=_0x1fd89d-0x0;let _0x690100=a135_0x502d[_0x1fd89d];return _0x690100;};const _0xd49a4d=a135_0x6901;'use strict';const express=require('express'),router=express[_0xd49a4d('0xb')](),auth=require(_0xd49a4d('0xe')),controller=require(_0xd49a4d('0xa'));router[_0xd49a4d('0x7')]('/',auth['isAuthenticated'](),controller[_0xd49a4d('0x0')]),router[_0xd49a4d('0x7')]('/:id',auth[_0xd49a4d('0x9')](),controller[_0xd49a4d('0x1')]),router[_0xd49a4d('0x4')]('/',auth[_0xd49a4d('0x9')](),controller[_0xd49a4d('0xd')]),router[_0xd49a4d('0x8')](_0xd49a4d('0x5'),auth[_0xd49a4d('0x9')](),controller[_0xd49a4d('0x2')]),router[_0xd49a4d('0x6')](_0xd49a4d('0x5'),auth[_0xd49a4d('0x9')](),controller[_0xd49a4d('0xc')]),module[_0xd49a4d('0x3')]=router; \ No newline at end of file diff --git a/server/api/cmHopper/cmHopper.attributes.js b/server/api/cmHopper/cmHopper.attributes.js index 3f4c8fa..1b0ed98 100644 --- a/server/api/cmHopper/cmHopper.attributes.js +++ b/server/api/cmHopper/cmHopper.attributes.js @@ -1 +1 @@ -const a136_0x3cf3=['BOOLEAN','DATE','contactListQueue','YYYY-MM-DD\x20HH:mm:ss','format','sequelize','INTEGER','STRING','UNSIGNED'];(function(_0x38c1ee,_0x3cf3a3){const _0x3b60f2=function(_0x5f38de){while(--_0x5f38de){_0x38c1ee['push'](_0x38c1ee['shift']());}};_0x3b60f2(++_0x3cf3a3);}(a136_0x3cf3,0x168));const a136_0x3b60=function(_0x38c1ee,_0x3cf3a3){_0x38c1ee=_0x38c1ee-0x0;let _0x3b60f2=a136_0x3cf3[_0x38c1ee];return _0x3b60f2;};const _0xcca140=a136_0x3b60;'use strict';const moment=require('moment'),Sequelize=require(_0xcca140('0x5'));module['exports']={'phone':{'type':Sequelize['STRING'],'allowNull':![]},'active':{'type':Sequelize[_0xcca140('0x0')],'defaultValue':![]},'scheduledat':{'type':Sequelize[_0xcca140('0x1')],'defaultValue':moment()[_0xcca140('0x4')](_0xcca140('0x3'))},'countbusyretry':{'type':Sequelize[_0xcca140('0x6')],'defaultValue':0x0},'countcongestionretry':{'type':Sequelize[_0xcca140('0x6')],'defaultValue':0x0},'countnoanswerretry':{'type':Sequelize[_0xcca140('0x6')],'defaultValue':0x0},'callback':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'callbackuniqueid':{'type':Sequelize[_0xcca140('0x7')],'defaultValue':null},'callbackat':{'type':Sequelize[_0xcca140('0x1')]},'priority':{'type':Sequelize['INTEGER'](0x2)[_0xcca140('0x8')],'defaultValue':0x2,'validate':{'min':0x0,'max':0x4}},'recallme':{'type':Sequelize[_0xcca140('0x0')],'defaultValue':![]},'ContactId':{'type':Sequelize[_0xcca140('0x6')],'unique':_0xcca140('0x2')},'ListId':{'type':Sequelize['INTEGER'],'unique':'contactListQueue'},'UserId':{'type':Sequelize[_0xcca140('0x6')]},'VoiceQueueId':{'type':Sequelize[_0xcca140('0x6')],'unique':_0xcca140('0x2')},'CampaignId':{'type':Sequelize[_0xcca140('0x6')]},'countnosuchnumberretry':{'type':Sequelize[_0xcca140('0x6')],'defaultValue':0x0},'countdropretry':{'type':Sequelize[_0xcca140('0x6')],'defaultValue':0x0},'countabandonedretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countmachineretry':{'type':Sequelize[_0xcca140('0x6')],'defaultValue':0x0},'countagentrejectretry':{'type':Sequelize[_0xcca140('0x6')],'defaultValue':0x0}}; \ No newline at end of file +const a136_0x5b88=['sequelize','UNSIGNED','STRING','BOOLEAN','DATE','format','contactListQueue','INTEGER','moment'];(function(_0x165ecc,_0x5b8872){const _0x51b59d=function(_0x10c0e9){while(--_0x10c0e9){_0x165ecc['push'](_0x165ecc['shift']());}};_0x51b59d(++_0x5b8872);}(a136_0x5b88,0x121));const a136_0x51b5=function(_0x165ecc,_0x5b8872){_0x165ecc=_0x165ecc-0x0;let _0x51b59d=a136_0x5b88[_0x165ecc];return _0x51b59d;};const _0x3a975a=a136_0x51b5;'use strict';const moment=require(_0x3a975a('0x7')),Sequelize=require(_0x3a975a('0x8'));module['exports']={'phone':{'type':Sequelize[_0x3a975a('0x1')],'allowNull':![]},'active':{'type':Sequelize[_0x3a975a('0x2')],'defaultValue':![]},'scheduledat':{'type':Sequelize[_0x3a975a('0x3')],'defaultValue':moment()[_0x3a975a('0x4')]('YYYY-MM-DD\x20HH:mm:ss')},'countbusyretry':{'type':Sequelize[_0x3a975a('0x6')],'defaultValue':0x0},'countcongestionretry':{'type':Sequelize[_0x3a975a('0x6')],'defaultValue':0x0},'countnoanswerretry':{'type':Sequelize[_0x3a975a('0x6')],'defaultValue':0x0},'callback':{'type':Sequelize[_0x3a975a('0x2')],'defaultValue':![]},'callbackuniqueid':{'type':Sequelize[_0x3a975a('0x1')],'defaultValue':null},'callbackat':{'type':Sequelize['DATE']},'priority':{'type':Sequelize[_0x3a975a('0x6')](0x2)[_0x3a975a('0x0')],'defaultValue':0x2,'validate':{'min':0x0,'max':0x4}},'recallme':{'type':Sequelize[_0x3a975a('0x2')],'defaultValue':![]},'ContactId':{'type':Sequelize['INTEGER'],'unique':_0x3a975a('0x5')},'ListId':{'type':Sequelize[_0x3a975a('0x6')],'unique':_0x3a975a('0x5')},'UserId':{'type':Sequelize[_0x3a975a('0x6')]},'VoiceQueueId':{'type':Sequelize['INTEGER'],'unique':_0x3a975a('0x5')},'CampaignId':{'type':Sequelize['INTEGER']},'countnosuchnumberretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countdropretry':{'type':Sequelize[_0x3a975a('0x6')],'defaultValue':0x0},'countabandonedretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countmachineretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countagentrejectretry':{'type':Sequelize[_0x3a975a('0x6')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/cmHopper/cmHopper.controller.js b/server/api/cmHopper/cmHopper.controller.js index 5a54913..922cc9c 100644 --- a/server/api/cmHopper/cmHopper.controller.js +++ b/server/api/cmHopper/cmHopper.controller.js @@ -1 +1 @@ -const a137_0x562c=['$between','../../mysqldb','$ne','nolimit','queue','$gte','findOne','getVoiceQueues','campaign','$gt','outbound','$not','CmContac','VoiceQueueId','params','stack','$notILike','isNil','$overlap','format','lte','$lte','$or','like','model','fieldName','DESC','$notIn','List','direction','VoiceQueue','rawAttributes','map','length','pick','catch','LOCK','includeAll','$and','phone','$in','type','Company','CmContact','where','index','filter','CmCompany','transaction','$notLike','CmHopper,\x20%s,\x20%s,\x20%s','deletedat','prev','scheduledat','campaigntype','CampaignId','$lt','show','sort','create','Content-Range','COALESCE(CmHopper.UserId,\x200)\x20ASC','createdAt','statedesc','name','Contact','$iLike','firstName','describe','getOpenContacts','body','attributes','VIRTUAL','../../config/logger','filters','getPreview','UPDATE','ContactId','then','dataValues','UserId','error','update','sendStatus','json','order','send','query','CmHopper','finally','$like','api','COALESCE(CmHopper.UserId,\x200)\x20DESC','intersection','ASC','isNumber','calleridname','count','status','keys','options','state','$contained','deleted','../../components/parsers/qs','membername','CmList','hopperIds','YYYY-MM-DD\x20HH:mm:ss','$notBetween','$eq','isEmpty','merge','calleridnum','scheduledAt','dialOrderByScheduledAt','offset','include','lastName','updatedAt','preview','rows','destroy','fields','user','set','Campaign','omit','limit'];(function(_0x47b5dc,_0x562c71){const _0x3d15a8=function(_0xb85ea){while(--_0xb85ea){_0x47b5dc['push'](_0x47b5dc['shift']());}};_0x3d15a8(++_0x562c71);}(a137_0x562c,0x1ac));const a137_0x3d15=function(_0x47b5dc,_0x562c71){_0x47b5dc=_0x47b5dc-0x0;let _0x3d15a8=a137_0x562c[_0x47b5dc];return _0x3d15a8;};const _0x3e2f6f=a137_0x3d15;'use strict';const moment=require('moment'),_=require('lodash'),qs=require(_0x3e2f6f('0x3f')),logger=require(_0x3e2f6f('0x20'))(_0x3e2f6f('0x32')),db=require(_0x3e2f6f('0x59'))['db'],{Op,literal}=require('sequelize');function respondWithResult(_0xb85ea,_0x582ed6){return _0x582ed6=_0x582ed6||0xc8,function(_0x3ef1f0){const _0x39a945=a137_0x3d15;if(_0x3ef1f0)return _0xb85ea[_0x39a945('0x39')](_0x582ed6)['json'](_0x3ef1f0);};}function respondWithFilteredResult(_0xf17ef6,_0x4ca768){return function(_0x1f12fa){const _0x152ec1=a137_0x3d15;if(_0x1f12fa){const _0x56bbe4=_0x1f12fa[_0x152ec1('0x38')],_0x570342=_0x4ca768[_0x152ec1('0x4b')];let _0x1e9ce3=_0x4ca768[_0x152ec1('0x4b')]+_0x4ca768['limit'],_0x4c0098;return _0x1e9ce3>=_0x56bbe4?(_0x1e9ce3=_0x56bbe4,_0x4c0098=0xc8):_0x4c0098=0xce,_0xf17ef6[_0x152ec1('0x39')](_0x4c0098),_0xf17ef6[_0x152ec1('0x54')](_0x152ec1('0x13'),_0x570342+'-'+_0x1e9ce3+'/'+_0x56bbe4)[_0x152ec1('0x2b')](_0x1f12fa);}return null;};}function saveUpdates(_0x888453){return function(_0x5572b9){const _0x498523=a137_0x3d15;if(_0x5572b9)return _0x5572b9[_0x498523('0x29')](_0x888453)['then'](function(_0x3d2386){return _0x3d2386;});return null;};}function handleEntityNotFound(_0xa9dd6d){return function(_0x2100fb){const _0x48eaef=a137_0x3d15;return!_0x2100fb&&_0xa9dd6d[_0x48eaef('0x2a')](0x194),_0x2100fb;};}function handleError(_0x15cc78,_0x57cfc4){return _0x57cfc4=_0x57cfc4||0x1f4,function(_0x5dfca4){const _0x56d49a=a137_0x3d15;logger[_0x56d49a('0x28')](_0x5dfca4[_0x56d49a('0x67')]),_0x5dfca4[_0x56d49a('0x17')]&&delete _0x5dfca4[_0x56d49a('0x17')],_0x15cc78[_0x56d49a('0x39')](_0x57cfc4)[_0x56d49a('0x2d')](_0x5dfca4);};}exports[_0x3e2f6f('0x4')]=function(_0x2ee95a,_0x2ad58b){const _0x311407=_0x3e2f6f;let _0x1fe11e={};const _0x1f2522={},_0x3fc1ed={'count':0x0,'rows':[]},_0x378925=_[_0x311407('0x78')](db[_0x311407('0x2f')][_0x311407('0x77')],function(_0x51ba99){const _0x2b0076=_0x311407;return{'name':_0x51ba99[_0x2b0076('0x71')],'type':_0x51ba99[_0x2b0076('0x0')]['key']};});_0x1f2522[_0x311407('0x70')]=_[_0x311407('0x78')](_0x378925,_0x311407('0x17')),_0x1f2522[_0x311407('0x2e')]=_[_0x311407('0x3a')](_0x2ee95a[_0x311407('0x2e')]),_0x1f2522['filters']=_[_0x311407('0x34')](_0x1f2522['model'],_0x1f2522[_0x311407('0x2e')]),_0x1f2522[_0x311407('0x21')]=_['concat'](_0x1f2522[_0x311407('0x21')],[_0x311407('0x7e'),_0x311407('0x6e'),_0x311407('0x61'),_0x311407('0x5d'),_0x311407('0xf'),_0x311407('0x6d'),_0x311407('0x5a'),_0x311407('0x45'),_0x311407('0x63'),_0x311407('0x58'),_0x311407('0x44'),_0x311407('0x80'),_0x311407('0x73'),_0x311407('0x31'),_0x311407('0x8'),_0x311407('0x19'),_0x311407('0x68'),'$like',_0x311407('0x6a'),'$contains',_0x311407('0x3d'),'$any']),_0x1fe11e[_0x311407('0x1e')]=_[_0x311407('0x34')](_0x1f2522['model'],qs[_0x311407('0x52')](_0x2ee95a[_0x311407('0x2e')]['fields'])),_0x1fe11e[_0x311407('0x1e')]=_0x1fe11e[_0x311407('0x1e')]['length']?_0x1fe11e[_0x311407('0x1e')]:_0x1f2522[_0x311407('0x70')];typeof _0x2ee95a[_0x311407('0x2e')][_0x311407('0x5b')]==='undefined'&&(_0x1fe11e[_0x311407('0x57')]=qs[_0x311407('0x57')](_0x2ee95a[_0x311407('0x2e')][_0x311407('0x57')]),_0x1fe11e[_0x311407('0x4b')]=qs[_0x311407('0x4b')](_0x2ee95a[_0x311407('0x2e')][_0x311407('0x4b')]));_0x1fe11e[_0x311407('0x2c')]=qs['sort'](_0x2ee95a[_0x311407('0x2e')][_0x311407('0x11')]),_0x1fe11e[_0x311407('0x3')]=qs[_0x311407('0x21')](_[_0x311407('0x7a')](_0x2ee95a[_0x311407('0x2e')],_0x1f2522[_0x311407('0x21')]),_0x378925);_0x2ee95a[_0x311407('0x2e')][_0x311407('0x5')]&&(_0x1fe11e[_0x311407('0x3')]=_[_0x311407('0x47')](_0x1fe11e['where'],{[Op['or']]:_[_0x311407('0x78')](_0x378925,function(_0x1b5a5b){const _0x196008=_0x311407;if(_0x1b5a5b['type']!==_0x196008('0x1f')){const _0x34e9df={};return _0x34e9df[_0x1b5a5b['name']]={[Op[_0x196008('0x6f')]]:'%'+_0x2ee95a[_0x196008('0x2e')][_0x196008('0x5')]+'%'},_0x34e9df;}})}));_0x1fe11e=_[_0x311407('0x47')]({},_0x1fe11e,_0x2ee95a[_0x311407('0x3b')]);const _0x2a9a9f={'where':_0x1fe11e[_0x311407('0x3')]};return db[_0x311407('0x2f')]['count'](_0x2a9a9f)[_0x311407('0x25')](function(_0x4b9e12){const _0x25c0f0=_0x311407;return _0x3fc1ed[_0x25c0f0('0x38')]=_0x4b9e12,_0x2ee95a[_0x25c0f0('0x2e')]['includeAll']&&(_0x1fe11e['include']=[{'all':!![]}]),db[_0x25c0f0('0x2f')]['findAll'](_0x1fe11e);})[_0x311407('0x25')](function(_0x16069b){const _0xea2d24=_0x311407;return _0x3fc1ed[_0xea2d24('0x50')]=_0x16069b,_0x3fc1ed;})[_0x311407('0x25')](respondWithFilteredResult(_0x2ad58b,_0x1fe11e))[_0x311407('0x7b')](handleError(_0x2ad58b,null));},exports[_0x3e2f6f('0x10')]=function(_0x1eb16f,_0x13670f){const _0x3538de=_0x3e2f6f;let _0x29056a={'raw':!![],'where':{'id':_0x1eb16f['params']['id']}};const _0x51b099={};return _0x51b099[_0x3538de('0x70')]=_[_0x3538de('0x3a')](db[_0x3538de('0x2f')]['rawAttributes']),_0x51b099['query']=_['keys'](_0x1eb16f[_0x3538de('0x2e')]),_0x51b099[_0x3538de('0x21')]=_[_0x3538de('0x34')](_0x51b099[_0x3538de('0x70')],_0x51b099[_0x3538de('0x2e')]),_0x29056a['attributes']=_[_0x3538de('0x34')](_0x51b099[_0x3538de('0x70')],qs['fields'](_0x1eb16f[_0x3538de('0x2e')]['fields'])),_0x29056a[_0x3538de('0x1e')]=_0x29056a[_0x3538de('0x1e')][_0x3538de('0x79')]?_0x29056a[_0x3538de('0x1e')]:_0x51b099[_0x3538de('0x70')],_0x1eb16f['query'][_0x3538de('0x7d')]&&(_0x29056a[_0x3538de('0x4c')]=[{'all':!![]}]),_0x29056a=_[_0x3538de('0x47')]({},_0x29056a,_0x1eb16f[_0x3538de('0x3b')]),db['CmHopper'][_0x3538de('0x5e')](_0x29056a)[_0x3538de('0x25')](handleEntityNotFound(_0x13670f,null))[_0x3538de('0x25')](respondWithResult(_0x13670f,null))['catch'](handleError(_0x13670f,null));},exports[_0x3e2f6f('0x12')]=function(_0x387de0,_0x2732f9){const _0x24867d=_0x3e2f6f;return db[_0x24867d('0x2f')][_0x24867d('0x12')](_0x387de0[_0x24867d('0x1d')],{})['then'](respondWithResult(_0x2732f9,0xc9))[_0x24867d('0x7b')](handleError(_0x2732f9,null));},exports[_0x3e2f6f('0x29')]=function(_0x5255be,_0x2cb65b){const _0x5055f1=_0x3e2f6f;return _0x5255be['body']['id']&&delete _0x5255be[_0x5055f1('0x1d')]['id'],db[_0x5055f1('0x2f')][_0x5055f1('0x5e')]({'where':{'id':_0x5255be['params']['id']}})[_0x5055f1('0x25')](handleEntityNotFound(_0x2cb65b,null))[_0x5055f1('0x25')](saveUpdates(_0x5255be['body'],null))[_0x5055f1('0x25')](respondWithResult(_0x2cb65b,null))[_0x5055f1('0x7b')](handleError(_0x2cb65b,null));},exports[_0x3e2f6f('0x1b')]=function(_0x280548,_0x2fbc6f){const _0x5481c4=_0x3e2f6f;return db[_0x5481c4('0x2f')][_0x5481c4('0x1b')]()['then'](respondWithResult(_0x2fbc6f,null))[_0x5481c4('0x7b')](handleError(_0x2fbc6f,null));},exports[_0x3e2f6f('0x51')]=function(_0x1292b7,_0x183f5e){const _0x50432a=_0x3e2f6f;let _0x350be9;return db['CmHopper']['findOne']({'where':{'id':_0x1292b7[_0x50432a('0x66')]['id']}})[_0x50432a('0x25')](handleEntityNotFound(_0x183f5e,null))[_0x50432a('0x25')](function(_0x200eaa){if(_0x200eaa)return _0x200eaa['destroy']()['then'](function(_0x21774c){return _0x21774c;});})[_0x50432a('0x25')](function(_0x18641b){const _0x169b22=_0x50432a;_0x350be9=_0x18641b;if(_0x18641b){if(_0x18641b[_0x169b22('0x65')]||_0x18641b[_0x169b22('0xe')])return db[_0x18641b[_0x169b22('0x65')]?_0x169b22('0x76'):_0x169b22('0x55')][_0x169b22('0x5e')]({'where':{'id':_0x18641b['VoiceQueueId']?_0x18641b[_0x169b22('0x65')]:_0x18641b[_0x169b22('0xe')]},'attributes':['id',_0x169b22('0x17')],'raw':!![]});}})[_0x50432a('0x25')](function(_0x4cdeef){const _0x38fb3f=_0x50432a,_0x49aa74={};if(_0x4cdeef)return _[_0x38fb3f('0x47')](_0x49aa74,_[_0x38fb3f('0x56')](_0x350be9[_0x38fb3f('0x26')],[_0x38fb3f('0x15'),_0x38fb3f('0x4e'),'id'])),_0x49aa74[_0x38fb3f('0x3c')]=0x15,_0x49aa74[_0x38fb3f('0x16')]=_0x38fb3f('0x3e'),_0x49aa74[_0x38fb3f('0x60')]=_0x4cdeef[_0x38fb3f('0x17')],_0x49aa74[_0x38fb3f('0x40')]=_0x1292b7['user'][_0x38fb3f('0x17')],_0x49aa74[_0x38fb3f('0x27')]=_0x1292b7[_0x38fb3f('0x53')]['id'],_0x49aa74[_0x38fb3f('0x3e')]=!![],_0x49aa74[_0x38fb3f('0xa')]=moment()[_0x38fb3f('0x6b')](_0x38fb3f('0x43')),_0x49aa74[_0x38fb3f('0x48')]=_0x350be9[_0x38fb3f('0x7f')],_0x49aa74[_0x38fb3f('0xd')]=_0x350be9[_0x38fb3f('0x65')]?_0x38fb3f('0x5c'):'ivr',db[_0x38fb3f('0x64')][_0x38fb3f('0x5e')]({'where':{'id':_0x49aa74[_0x38fb3f('0x24')]},'attributes':[_0x38fb3f('0x1a'),_0x38fb3f('0x4d')]})[_0x38fb3f('0x25')](function(_0x39d69c){const _0x139832=_0x38fb3f;!_[_0x139832('0x69')](_0x183f5e)&&!_['isNil'](_0x39d69c[_0x139832('0x1a')])&&(_0x49aa74[_0x139832('0x37')]=_0x39d69c['firstName'],!_[_0x139832('0x69')](_0x39d69c[_0x139832('0x4d')])&&(_0x49aa74[_0x139832('0x37')]+='\x20'+_0x39d69c[_0x139832('0x4d')]));})[_0x38fb3f('0x30')](function(){const _0xa8cf8f=_0x38fb3f;return db['CmHopperFinal'][_0xa8cf8f('0x12')](_0x49aa74);});})[_0x50432a('0x25')](function(){return _0x183f5e['status'](0xcc)['end']();})[_0x50432a('0x7b')](handleError(_0x183f5e,null));},exports[_0x3e2f6f('0x22')]=function(_0x177bbb,_0x3959aa){const _0x1b1611=_0x3e2f6f;let _0x1f6998=[];return db[_0x1b1611('0x2')][_0x1b1611('0x1b')]()[_0x1b1611('0x25')](function(_0x158dcf){const _0x2d7c7b=_0x1b1611;return _0x1f6998=_[_0x2d7c7b('0x3a')](_0x158dcf),_0x177bbb[_0x2d7c7b('0x53')][_0x2d7c7b('0x5f')]({'where':{'type':'outbound','dialActive':!![],'dialMethod':_0x2d7c7b('0x4f')},'attributes':['id',_0x2d7c7b('0x4a')],'raw':!![]});})[_0x1b1611('0x25')](function(_0x435629){const _0x14e667=_0x1b1611;if(_0x435629&&_0x435629[_0x14e667('0x79')])return db['sequelize'][_0x14e667('0x7')](function(_0x24b337){const _0x4f12b0=_0x14e667,_0x5b4cc5={'active':![],'recallme':![],'scheduledAt':{[Op['lte']]:moment()['format'](_0x4f12b0('0x43'))},'VoiceQueueId':{[Op['in']]:_[_0x4f12b0('0x78')](_0x435629,'id')},[Op['or']]:[{'UserId':null},{'UserId':_0x177bbb[_0x4f12b0('0x53')]['id']}]};let _0x38e526=[];return _0x177bbb['body'][_0x4f12b0('0x75')]&&_0x177bbb[_0x4f12b0('0x1d')][_0x4f12b0('0x75')]===_0x4f12b0('0xb')?(!_['isEmpty'](_0x177bbb['body']['hopperIds'])&&(_0x5b4cc5['id']={'$in':_0x177bbb[_0x4f12b0('0x1d')]['hopperIds']}),_0x38e526=[['priority',_0x4f12b0('0x35')],[_0x4f12b0('0x49'),_0x435629[0x0]['dialOrderByScheduledAt']===_0x4f12b0('0x35')?_0x4f12b0('0x72'):'ASC'],literal(_0x4f12b0('0x14')),['id',_0x4f12b0('0x72')]]):(!_[_0x4f12b0('0x46')](_0x177bbb[_0x4f12b0('0x1d')]['hopperIds'])&&(_0x5b4cc5['id']={'$notIn':_0x177bbb[_0x4f12b0('0x1d')][_0x4f12b0('0x42')]}),_0x38e526=[['priority','DESC'],[_0x4f12b0('0x49'),_0x435629[0x0]['dialOrderByScheduledAt']],literal(_0x4f12b0('0x33')),['id',_0x4f12b0('0x35')]]),db['CmHopper'][_0x4f12b0('0x5e')]({'attributes':['id',_0x4f12b0('0xc')],'where':_0x5b4cc5,'order':_0x38e526,'transaction':_0x24b337,'lock':_0x24b337[_0x4f12b0('0x7c')][_0x4f12b0('0x23')],'include':[{'model':db[_0x4f12b0('0x2')],'as':_0x4f12b0('0x18'),'attributes':_0x1f6998,'include':[{'model':db[_0x4f12b0('0x6')],'as':_0x4f12b0('0x1'),'attributes':['id',_0x4f12b0('0x17')]}]},{'model':db[_0x4f12b0('0x41')],'as':_0x4f12b0('0x74'),'attributes':['id',_0x4f12b0('0x17')]},{'model':db[_0x4f12b0('0x76')],'as':'Queue','attributes':['id',_0x4f12b0('0x17'),'dialActive']}]})[_0x4f12b0('0x25')](function(_0x41a1ee){const _0x526260=_0x4f12b0;if(_0x41a1ee)return _0x41a1ee[_0x526260('0x29')]({'UserId':_0x177bbb[_0x526260('0x53')]['id']},{'transaction':_0x24b337});});});})[_0x1b1611('0x25')](handleEntityNotFound(_0x3959aa,null))['then'](respondWithResult(_0x3959aa,null))['catch'](handleError(_0x3959aa,null));},exports['getOpenContacts']=function(_0x25ab99,_0xff960d){const _0x1f62f4=_0x3e2f6f;return _0x25ab99['user'][_0x1f62f4('0x5f')]({'where':{'type':_0x1f62f4('0x62'),'dialActive':!![],'dialMethod':_0x1f62f4('0x4f')},'attributes':['id'],'raw':!![]})['then'](function(_0x2f43fc){const _0x1025a0=_0x1f62f4;if(_0x2f43fc&&_0x2f43fc[_0x1025a0('0x79')])return db[_0x1025a0('0x2f')]['count']({'where':{'active':![],'recallme':![],'scheduledAt':{[Op[_0x1025a0('0x6c')]]:moment()[_0x1025a0('0x6b')](_0x1025a0('0x43'))},'VoiceQueueId':{[Op['in']]:_[_0x1025a0('0x78')](_0x2f43fc,'id')},[Op['or']]:[{'UserId':null},{'UserId':_0x25ab99[_0x1025a0('0x53')]['id']}]}});return 0x0;})['then'](function(_0x4da4a3){const _0x422f4b=_0x1f62f4;if(!_[_0x422f4b('0x69')](_0x4da4a3)&&_[_0x422f4b('0x36')](_0x4da4a3))return _0xff960d[_0x422f4b('0x39')](0xc8)[_0x422f4b('0x2b')]({'contacts':_0x4da4a3});else logger[_0x422f4b('0x28')](_0x422f4b('0x9'),_0x422f4b('0x1c'),0x194,'entity\x20not\x20found'),_0xff960d['sendStatus'](0x194);})[_0x1f62f4('0x7b')](handleError(_0xff960d,null));}; \ No newline at end of file +const a137_0x8a97=['CmHopper','include','destroy','index','$between','rawAttributes','intersection','finally','length','deleted','$or','$gte','phone','name','campaign','DESC','COALESCE(CmHopper.UserId,\x200)\x20DESC','undefined','outbound','createdAt','api','calleridname','UserId','YYYY-MM-DD\x20HH:mm:ss','CmHopperFinal','like','json','pick','LOCK','scheduledAt','$notILike','lastName','query','describe','membername','model','Queue','limit','error','status','VoiceQueueId','ASC','fieldName','create','stack','offset','lte','user','Company','attributes','direction','CmContact','catch','key','getVoiceQueues','options','moment','sendStatus','send','CmContac','type','CmHopper,\x20%s,\x20%s,\x20%s','deletedat','firstName','findOne','entity\x20not\x20found','getPreview','isEmpty','ivr','merge','map','$like','$iLike','$lt','getOpenContacts','campaigntype','CmList','List','format','hopperIds','VoiceQueue','$overlap','concat','dataValues','../../mysqldb','omit','CampaignId','$and','includeAll','Campaign','keys','rows','filters','params','order','$notIn','then','end','dialOrderByScheduledAt','$notLike','body','nolimit','isNil','update','COALESCE(CmHopper.UserId,\x200)\x20ASC','where','filter','updatedAt','queue','Contact','preview','$not','count','lodash','sort'];(function(_0x1705e9,_0x8a973c){const _0x71dc29=function(_0x426ca8){while(--_0x426ca8){_0x1705e9['push'](_0x1705e9['shift']());}};_0x71dc29(++_0x8a973c);}(a137_0x8a97,0xdb));const a137_0x71dc=function(_0x1705e9,_0x8a973c){_0x1705e9=_0x1705e9-0x0;let _0x71dc29=a137_0x8a97[_0x1705e9];return _0x71dc29;};const _0x2301d3=a137_0x71dc;'use strict';const moment=require(_0x2301d3('0x43')),_=require(_0x2301d3('0x9')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x2301d3('0x1f')),db=require(_0x2301d3('0x5f'))['db'],{Op,literal}=require('sequelize');function respondWithResult(_0x426ca8,_0x3a2fab){return _0x3a2fab=_0x3a2fab||0xc8,function(_0x52e92f){const _0x349a9b=a137_0x71dc;if(_0x52e92f)return _0x426ca8[_0x349a9b('0x32')](_0x3a2fab)[_0x349a9b('0x25')](_0x52e92f);};}function respondWithFilteredResult(_0x30a45f,_0x2a73cb){return function(_0x4347ba){const _0xce7966=a137_0x71dc;if(_0x4347ba){const _0x38ae9a=_0x4347ba[_0xce7966('0x8')],_0x3fd7ed=_0x2a73cb[_0xce7966('0x38')];let _0x82f269=_0x2a73cb[_0xce7966('0x38')]+_0x2a73cb[_0xce7966('0x30')],_0x394d6d;return _0x82f269>=_0x38ae9a?(_0x82f269=_0x38ae9a,_0x394d6d=0xc8):_0x394d6d=0xce,_0x30a45f['status'](_0x394d6d),_0x30a45f['set']('Content-Range',_0x3fd7ed+'-'+_0x82f269+'/'+_0x38ae9a)[_0xce7966('0x25')](_0x4347ba);}return null;};}function saveUpdates(_0x2c78c1){return function(_0x489cb1){const _0x1f804f=a137_0x71dc;if(_0x489cb1)return _0x489cb1[_0x1f804f('0x72')](_0x2c78c1)[_0x1f804f('0x6b')](function(_0x5ef628){return _0x5ef628;});return null;};}function handleEntityNotFound(_0x5070e1){return function(_0x15f541){const _0x4c88eb=a137_0x71dc;return!_0x15f541&&_0x5070e1[_0x4c88eb('0x44')](0x194),_0x15f541;};}function handleError(_0x118f9c,_0x49efe7){return _0x49efe7=_0x49efe7||0x1f4,function(_0x37bcb8){const _0x4fd8e7=a137_0x71dc;logger[_0x4fd8e7('0x31')](_0x37bcb8[_0x4fd8e7('0x37')]),_0x37bcb8[_0x4fd8e7('0x18')]&&delete _0x37bcb8['name'],_0x118f9c['status'](_0x49efe7)[_0x4fd8e7('0x45')](_0x37bcb8);};}exports[_0x2301d3('0xe')]=function(_0x3c4406,_0x18b60b){const _0x20a2b3=_0x2301d3;let _0x2448c9={};const _0x56ba08={},_0x4916f3={'count':0x0,'rows':[]},_0x34c1a8=_[_0x20a2b3('0x51')](db['CmHopper'][_0x20a2b3('0x10')],function(_0x4b234c){const _0x366c2b=_0x20a2b3;return{'name':_0x4b234c[_0x366c2b('0x35')],'type':_0x4b234c[_0x366c2b('0x47')][_0x366c2b('0x40')]};});_0x56ba08[_0x20a2b3('0x2e')]=_[_0x20a2b3('0x51')](_0x34c1a8,_0x20a2b3('0x18')),_0x56ba08[_0x20a2b3('0x2b')]=_[_0x20a2b3('0x65')](_0x3c4406['query']),_0x56ba08[_0x20a2b3('0x67')]=_[_0x20a2b3('0x11')](_0x56ba08[_0x20a2b3('0x2e')],_0x56ba08[_0x20a2b3('0x2b')]),_0x56ba08[_0x20a2b3('0x67')]=_[_0x20a2b3('0x5d')](_0x56ba08[_0x20a2b3('0x67')],[_0x20a2b3('0x62'),_0x20a2b3('0x15'),'$gt',_0x20a2b3('0x16'),_0x20a2b3('0x54'),'$lte','$ne','$eq',_0x20a2b3('0x7'),_0x20a2b3('0xf'),'$notBetween','$in',_0x20a2b3('0x6a'),_0x20a2b3('0x52'),_0x20a2b3('0x6e'),_0x20a2b3('0x53'),_0x20a2b3('0x29'),_0x20a2b3('0x52'),_0x20a2b3('0x5c'),'$contains','$contained','$any']),_0x2448c9[_0x20a2b3('0x3c')]=_[_0x20a2b3('0x11')](_0x56ba08['model'],qs['fields'](_0x3c4406[_0x20a2b3('0x2b')]['fields'])),_0x2448c9[_0x20a2b3('0x3c')]=_0x2448c9[_0x20a2b3('0x3c')][_0x20a2b3('0x13')]?_0x2448c9[_0x20a2b3('0x3c')]:_0x56ba08['model'];typeof _0x3c4406[_0x20a2b3('0x2b')][_0x20a2b3('0x70')]===_0x20a2b3('0x1c')&&(_0x2448c9[_0x20a2b3('0x30')]=qs['limit'](_0x3c4406[_0x20a2b3('0x2b')][_0x20a2b3('0x30')]),_0x2448c9[_0x20a2b3('0x38')]=qs[_0x20a2b3('0x38')](_0x3c4406[_0x20a2b3('0x2b')]['offset']));_0x2448c9[_0x20a2b3('0x69')]=qs[_0x20a2b3('0xa')](_0x3c4406['query'][_0x20a2b3('0xa')]),_0x2448c9['where']=qs[_0x20a2b3('0x67')](_[_0x20a2b3('0x26')](_0x3c4406[_0x20a2b3('0x2b')],_0x56ba08[_0x20a2b3('0x67')]),_0x34c1a8);_0x3c4406[_0x20a2b3('0x2b')][_0x20a2b3('0x2')]&&(_0x2448c9[_0x20a2b3('0x1')]=_['merge'](_0x2448c9[_0x20a2b3('0x1')],{[Op['or']]:_[_0x20a2b3('0x51')](_0x34c1a8,function(_0x181355){const _0x2f3dfd=_0x20a2b3;if(_0x181355['type']!=='VIRTUAL'){const _0x32be4b={};return _0x32be4b[_0x181355[_0x2f3dfd('0x18')]]={[Op[_0x2f3dfd('0x24')]]:'%'+_0x3c4406[_0x2f3dfd('0x2b')][_0x2f3dfd('0x2')]+'%'},_0x32be4b;}})}));_0x2448c9=_[_0x20a2b3('0x50')]({},_0x2448c9,_0x3c4406[_0x20a2b3('0x42')]);const _0x451f16={'where':_0x2448c9[_0x20a2b3('0x1')]};return db[_0x20a2b3('0xb')]['count'](_0x451f16)[_0x20a2b3('0x6b')](function(_0x16b4e3){const _0x19cac4=_0x20a2b3;return _0x4916f3[_0x19cac4('0x8')]=_0x16b4e3,_0x3c4406['query'][_0x19cac4('0x63')]&&(_0x2448c9[_0x19cac4('0xc')]=[{'all':!![]}]),db[_0x19cac4('0xb')]['findAll'](_0x2448c9);})[_0x20a2b3('0x6b')](function(_0x12fd26){const _0x497663=_0x20a2b3;return _0x4916f3[_0x497663('0x66')]=_0x12fd26,_0x4916f3;})[_0x20a2b3('0x6b')](respondWithFilteredResult(_0x18b60b,_0x2448c9))['catch'](handleError(_0x18b60b,null));},exports['show']=function(_0x47671d,_0x46517c){const _0x4825b2=_0x2301d3;let _0x2c6818={'raw':!![],'where':{'id':_0x47671d[_0x4825b2('0x68')]['id']}};const _0x35b59f={};return _0x35b59f[_0x4825b2('0x2e')]=_[_0x4825b2('0x65')](db[_0x4825b2('0xb')][_0x4825b2('0x10')]),_0x35b59f['query']=_['keys'](_0x47671d[_0x4825b2('0x2b')]),_0x35b59f['filters']=_[_0x4825b2('0x11')](_0x35b59f[_0x4825b2('0x2e')],_0x35b59f[_0x4825b2('0x2b')]),_0x2c6818['attributes']=_[_0x4825b2('0x11')](_0x35b59f[_0x4825b2('0x2e')],qs['fields'](_0x47671d[_0x4825b2('0x2b')]['fields'])),_0x2c6818[_0x4825b2('0x3c')]=_0x2c6818[_0x4825b2('0x3c')][_0x4825b2('0x13')]?_0x2c6818[_0x4825b2('0x3c')]:_0x35b59f[_0x4825b2('0x2e')],_0x47671d[_0x4825b2('0x2b')][_0x4825b2('0x63')]&&(_0x2c6818[_0x4825b2('0xc')]=[{'all':!![]}]),_0x2c6818=_[_0x4825b2('0x50')]({},_0x2c6818,_0x47671d['options']),db[_0x4825b2('0xb')][_0x4825b2('0x4b')](_0x2c6818)['then'](handleEntityNotFound(_0x46517c,null))['then'](respondWithResult(_0x46517c,null))[_0x4825b2('0x3f')](handleError(_0x46517c,null));},exports['create']=function(_0x5e4654,_0x504bd4){const _0x4ad5b0=_0x2301d3;return db[_0x4ad5b0('0xb')][_0x4ad5b0('0x36')](_0x5e4654[_0x4ad5b0('0x6f')],{})[_0x4ad5b0('0x6b')](respondWithResult(_0x504bd4,0xc9))['catch'](handleError(_0x504bd4,null));},exports[_0x2301d3('0x72')]=function(_0x5e7064,_0x543a9a){const _0x59f4ab=_0x2301d3;return _0x5e7064['body']['id']&&delete _0x5e7064[_0x59f4ab('0x6f')]['id'],db[_0x59f4ab('0xb')][_0x59f4ab('0x4b')]({'where':{'id':_0x5e7064[_0x59f4ab('0x68')]['id']}})[_0x59f4ab('0x6b')](handleEntityNotFound(_0x543a9a,null))[_0x59f4ab('0x6b')](saveUpdates(_0x5e7064[_0x59f4ab('0x6f')],null))[_0x59f4ab('0x6b')](respondWithResult(_0x543a9a,null))[_0x59f4ab('0x3f')](handleError(_0x543a9a,null));},exports[_0x2301d3('0x2c')]=function(_0x3a8942,_0x3317f9){const _0x10fdab=_0x2301d3;return db[_0x10fdab('0xb')]['describe']()[_0x10fdab('0x6b')](respondWithResult(_0x3317f9,null))['catch'](handleError(_0x3317f9,null));},exports['destroy']=function(_0x51df52,_0x1a153e){const _0x4d81af=_0x2301d3;let _0x5482f2;return db[_0x4d81af('0xb')][_0x4d81af('0x4b')]({'where':{'id':_0x51df52[_0x4d81af('0x68')]['id']}})[_0x4d81af('0x6b')](handleEntityNotFound(_0x1a153e,null))['then'](function(_0x11f124){const _0x5a0d6b=_0x4d81af;if(_0x11f124)return _0x11f124[_0x5a0d6b('0xd')]()['then'](function(_0x39759d){return _0x39759d;});})[_0x4d81af('0x6b')](function(_0x340f7d){const _0x42bfc3=_0x4d81af;_0x5482f2=_0x340f7d;if(_0x340f7d){if(_0x340f7d[_0x42bfc3('0x33')]||_0x340f7d[_0x42bfc3('0x61')])return db[_0x340f7d[_0x42bfc3('0x33')]?_0x42bfc3('0x5b'):_0x42bfc3('0x64')][_0x42bfc3('0x4b')]({'where':{'id':_0x340f7d[_0x42bfc3('0x33')]?_0x340f7d['VoiceQueueId']:_0x340f7d[_0x42bfc3('0x61')]},'attributes':['id',_0x42bfc3('0x18')],'raw':!![]});}})[_0x4d81af('0x6b')](function(_0x49db8d){const _0x3c6892=_0x4d81af,_0x523666={};if(_0x49db8d)return _[_0x3c6892('0x50')](_0x523666,_[_0x3c6892('0x60')](_0x5482f2[_0x3c6892('0x5e')],[_0x3c6892('0x1e'),_0x3c6892('0x3'),'id'])),_0x523666['state']=0x15,_0x523666['statedesc']=_0x3c6892('0x14'),_0x523666[_0x3c6892('0x19')]=_0x49db8d[_0x3c6892('0x18')],_0x523666[_0x3c6892('0x2d')]=_0x51df52[_0x3c6892('0x3a')]['name'],_0x523666[_0x3c6892('0x21')]=_0x51df52[_0x3c6892('0x3a')]['id'],_0x523666['deleted']=!![],_0x523666[_0x3c6892('0x49')]=moment()[_0x3c6892('0x59')](_0x3c6892('0x22')),_0x523666['calleridnum']=_0x5482f2[_0x3c6892('0x17')],_0x523666[_0x3c6892('0x56')]=_0x5482f2[_0x3c6892('0x33')]?_0x3c6892('0x4'):_0x3c6892('0x4f'),db[_0x3c6892('0x46')][_0x3c6892('0x4b')]({'where':{'id':_0x523666['ContactId']},'attributes':[_0x3c6892('0x4a'),'lastName']})['then'](function(_0x4a80d9){const _0x5324e6=_0x3c6892;!_[_0x5324e6('0x71')](_0x1a153e)&&!_['isNil'](_0x4a80d9[_0x5324e6('0x4a')])&&(_0x523666[_0x5324e6('0x20')]=_0x4a80d9[_0x5324e6('0x4a')],!_[_0x5324e6('0x71')](_0x4a80d9[_0x5324e6('0x2a')])&&(_0x523666['calleridname']+='\x20'+_0x4a80d9[_0x5324e6('0x2a')]));})[_0x3c6892('0x12')](function(){const _0x241db7=_0x3c6892;return db[_0x241db7('0x23')][_0x241db7('0x36')](_0x523666);});})[_0x4d81af('0x6b')](function(){const _0x149764=_0x4d81af;return _0x1a153e[_0x149764('0x32')](0xcc)[_0x149764('0x6c')]();})[_0x4d81af('0x3f')](handleError(_0x1a153e,null));},exports[_0x2301d3('0x4d')]=function(_0x3442a7,_0x44a308){const _0x42fc6e=_0x2301d3;let _0x5246f9=[];return db[_0x42fc6e('0x3e')][_0x42fc6e('0x2c')]()[_0x42fc6e('0x6b')](function(_0x544f94){const _0x4b81a5=_0x42fc6e;return _0x5246f9=_[_0x4b81a5('0x65')](_0x544f94),_0x3442a7[_0x4b81a5('0x3a')][_0x4b81a5('0x41')]({'where':{'type':_0x4b81a5('0x1d'),'dialActive':!![],'dialMethod':_0x4b81a5('0x6')},'attributes':['id',_0x4b81a5('0x6d')],'raw':!![]});})['then'](function(_0x5371d3){const _0x1f4ef1=_0x42fc6e;if(_0x5371d3&&_0x5371d3[_0x1f4ef1('0x13')])return db['sequelize']['transaction'](function(_0x4c5558){const _0x3eb0da=_0x1f4ef1,_0x89c2d1={'active':![],'recallme':![],'scheduledAt':{[Op[_0x3eb0da('0x39')]]:moment()[_0x3eb0da('0x59')](_0x3eb0da('0x22'))},'VoiceQueueId':{[Op['in']]:_[_0x3eb0da('0x51')](_0x5371d3,'id')},[Op['or']]:[{'UserId':null},{'UserId':_0x3442a7['user']['id']}]};let _0x422958=[];return _0x3442a7['body'][_0x3eb0da('0x3d')]&&_0x3442a7[_0x3eb0da('0x6f')][_0x3eb0da('0x3d')]==='prev'?(!_['isEmpty'](_0x3442a7[_0x3eb0da('0x6f')][_0x3eb0da('0x5a')])&&(_0x89c2d1['id']={'$in':_0x3442a7[_0x3eb0da('0x6f')][_0x3eb0da('0x5a')]}),_0x422958=[['priority',_0x3eb0da('0x34')],[_0x3eb0da('0x28'),_0x5371d3[0x0]['dialOrderByScheduledAt']===_0x3eb0da('0x34')?_0x3eb0da('0x1a'):_0x3eb0da('0x34')],literal(_0x3eb0da('0x0')),['id',_0x3eb0da('0x1a')]]):(!_[_0x3eb0da('0x4e')](_0x3442a7[_0x3eb0da('0x6f')][_0x3eb0da('0x5a')])&&(_0x89c2d1['id']={'$notIn':_0x3442a7[_0x3eb0da('0x6f')]['hopperIds']}),_0x422958=[['priority','DESC'],['scheduledAt',_0x5371d3[0x0][_0x3eb0da('0x6d')]],literal(_0x3eb0da('0x1b')),['id','ASC']]),db[_0x3eb0da('0xb')]['findOne']({'attributes':['id','scheduledat'],'where':_0x89c2d1,'order':_0x422958,'transaction':_0x4c5558,'lock':_0x4c5558[_0x3eb0da('0x27')]['UPDATE'],'include':[{'model':db[_0x3eb0da('0x3e')],'as':_0x3eb0da('0x5'),'attributes':_0x5246f9,'include':[{'model':db['CmCompany'],'as':_0x3eb0da('0x3b'),'attributes':['id','name']}]},{'model':db[_0x3eb0da('0x57')],'as':_0x3eb0da('0x58'),'attributes':['id',_0x3eb0da('0x18')]},{'model':db[_0x3eb0da('0x5b')],'as':_0x3eb0da('0x2f'),'attributes':['id',_0x3eb0da('0x18'),'dialActive']}]})[_0x3eb0da('0x6b')](function(_0x2b9fc7){const _0x4c0de2=_0x3eb0da;if(_0x2b9fc7)return _0x2b9fc7[_0x4c0de2('0x72')]({'UserId':_0x3442a7[_0x4c0de2('0x3a')]['id']},{'transaction':_0x4c5558});});});})[_0x42fc6e('0x6b')](handleEntityNotFound(_0x44a308,null))['then'](respondWithResult(_0x44a308,null))[_0x42fc6e('0x3f')](handleError(_0x44a308,null));},exports['getOpenContacts']=function(_0x215bc1,_0x3c1c80){const _0x3e907b=_0x2301d3;return _0x215bc1[_0x3e907b('0x3a')][_0x3e907b('0x41')]({'where':{'type':_0x3e907b('0x1d'),'dialActive':!![],'dialMethod':_0x3e907b('0x6')},'attributes':['id'],'raw':!![]})[_0x3e907b('0x6b')](function(_0x2e62fe){const _0x2fa734=_0x3e907b;if(_0x2e62fe&&_0x2e62fe[_0x2fa734('0x13')])return db[_0x2fa734('0xb')][_0x2fa734('0x8')]({'where':{'active':![],'recallme':![],'scheduledAt':{[Op[_0x2fa734('0x39')]]:moment()[_0x2fa734('0x59')]('YYYY-MM-DD\x20HH:mm:ss')},'VoiceQueueId':{[Op['in']]:_['map'](_0x2e62fe,'id')},[Op['or']]:[{'UserId':null},{'UserId':_0x215bc1[_0x2fa734('0x3a')]['id']}]}});return 0x0;})[_0x3e907b('0x6b')](function(_0x3ef886){const _0x545a8e=_0x3e907b;if(!_['isNil'](_0x3ef886)&&_['isNumber'](_0x3ef886))return _0x3c1c80[_0x545a8e('0x32')](0xc8)['json']({'contacts':_0x3ef886});else logger[_0x545a8e('0x31')](_0x545a8e('0x48'),_0x545a8e('0x55'),0x194,_0x545a8e('0x4c')),_0x3c1c80[_0x545a8e('0x44')](0x194);})[_0x3e907b('0x3f')](handleError(_0x3c1c80,null));}; \ No newline at end of file diff --git a/server/api/cmHopper/cmHopper.model.js b/server/api/cmHopper/cmHopper.model.js index ce4bf2f..c3fdff7 100644 --- a/server/api/cmHopper/cmHopper.model.js +++ b/server/api/cmHopper/cmHopper.model.js @@ -1 +1 @@ -const a138_0x2d2e=['priority','phone','define','scheduledat','./cmHopper.attributes','cm_hopper','CmHopper'];(function(_0x5ac135,_0x2d2e1a){const _0x416e1c=function(_0x4dcd71){while(--_0x4dcd71){_0x5ac135['push'](_0x5ac135['shift']());}};_0x416e1c(++_0x2d2e1a);}(a138_0x2d2e,0x1ad));const a138_0x416e=function(_0x5ac135,_0x2d2e1a){_0x5ac135=_0x5ac135-0x0;let _0x416e1c=a138_0x2d2e[_0x5ac135];return _0x416e1c;};const _0x3cccfb=a138_0x416e;'use strict';const attributes=require(_0x3cccfb('0x2'));module['exports']=function(_0x4dcd71){const _0x55d4f6=_0x3cccfb,_0x503c6d=_0x4dcd71[_0x55d4f6('0x0')](_0x55d4f6('0x4'),attributes,{'tableName':_0x55d4f6('0x3'),'paranoid':![],'indexes':[{'name':_0x55d4f6('0x1'),'fields':['scheduledat']},{'name':'phone','fields':[_0x55d4f6('0x6')]},{'name':_0x55d4f6('0x5'),'fields':[_0x55d4f6('0x5')]}],'timestamps':!![]});return _0x503c6d;}; \ No newline at end of file +const a138_0x2a1a=['./cmHopper.attributes','cm_hopper','define','priority','scheduledat','CmHopper','exports','phone'];(function(_0x10cc32,_0x2a1a30){const _0x1f4473=function(_0xf7cf49){while(--_0xf7cf49){_0x10cc32['push'](_0x10cc32['shift']());}};_0x1f4473(++_0x2a1a30);}(a138_0x2a1a,0x7e));const a138_0x1f44=function(_0x10cc32,_0x2a1a30){_0x10cc32=_0x10cc32-0x0;let _0x1f4473=a138_0x2a1a[_0x10cc32];return _0x1f4473;};const _0x29a953=a138_0x1f44;'use strict';const attributes=require(_0x29a953('0x2'));module[_0x29a953('0x0')]=function(_0xf7cf49){const _0x165ed0=_0x29a953,_0x179bec=_0xf7cf49[_0x165ed0('0x4')](_0x165ed0('0x7'),attributes,{'tableName':_0x165ed0('0x3'),'paranoid':![],'indexes':[{'name':'scheduledat','fields':[_0x165ed0('0x6')]},{'name':_0x165ed0('0x1'),'fields':[_0x165ed0('0x1')]},{'name':'priority','fields':[_0x165ed0('0x5')]}],'timestamps':!![]});return _0x179bec;}; \ No newline at end of file diff --git a/server/api/cmHopper/cmHopper.rpc.js b/server/api/cmHopper/cmHopper.rpc.js index e779756..a3c5868 100644 --- a/server/api/cmHopper/cmHopper.rpc.js +++ b/server/api/cmHopper/cmHopper.rpc.js @@ -1 +1 @@ -const a139_0x46e6=['info','COUNT','CmHopperFinal','keys','catch','message','../../config/logger','sequelize','User','findOne','order','GetCmHopper','UpdateCmHopper','MoveContactManagedDialer','UPDATE','body','raw','length','describe','map','\x22%s\x22','then','util','\x20,\x201,\x20null','model','include','../../mysqldb','all','Contact','error','CreateCmHopper','CmHopper','attributes','debug','format','CountReScheduled','push','options','LOCK','DestroyCmHopper','UserId','stringify','CmContact','GetContactRecallMe','includes','`scheduledat`\x20>=\x20','update','rpc','limit','where','ShowCmHopper','findAll','GetContactDialer','YYYY-MM-DD\x20HH:mm:ss','moment','create','destroy','transaction'];(function(_0x51c70a,_0x46e6a0){const _0x2d468e=function(_0x256d81){while(--_0x256d81){_0x51c70a['push'](_0x51c70a['shift']());}};_0x2d468e(++_0x46e6a0);}(a139_0x46e6,0x17b));const a139_0x2d46=function(_0x51c70a,_0x46e6a0){_0x51c70a=_0x51c70a-0x0;let _0x2d468e=a139_0x46e6[_0x51c70a];return _0x2d468e;};const _0x2850d1=a139_0x2d46;'use strict';const _=require('lodash'),util=require(_0x2850d1('0x31')),moment=require(_0x2850d1('0x17')),db=require(_0x2850d1('0x35'))['db'],logger=require(_0x2850d1('0x21'))(_0x2850d1('0x10')),{literal,fn}=require('sequelize');exports[_0x2850d1('0x26')]=function(_0x256d81){const _0x4584da=this;return new Promise(function(_0x3928a3,_0x2ab080){const _0x557931=a139_0x2d46;return db['CmHopper'][_0x557931('0x14')]({'raw':_0x256d81[_0x557931('0x6')]?_0x256d81['options']['raw']===undefined?!![]:![]:!![],'where':_0x256d81['options']?_0x256d81[_0x557931('0x6')][_0x557931('0x12')]||null:null,'attributes':_0x256d81['options']?_0x256d81[_0x557931('0x6')]['attributes']||null:null,'limit':_0x256d81[_0x557931('0x6')]?_0x256d81[_0x557931('0x6')][_0x557931('0x11')]||null:null,'include':_0x256d81[_0x557931('0x6')]?_0x256d81['options'][_0x557931('0x34')]?_[_0x557931('0x2e')](_0x256d81[_0x557931('0x6')][_0x557931('0x34')],function(_0x26dbd0){const _0x2851d4=_0x557931;return{'model':db[_0x26dbd0['model']],'as':_0x26dbd0['as'],'attributes':_0x26dbd0[_0x2851d4('0x1')],'include':_0x26dbd0[_0x2851d4('0x34')]?_[_0x2851d4('0x2e')](_0x26dbd0[_0x2851d4('0x34')],function(_0x23b9db){const _0x327600=_0x2851d4;return{'model':db[_0x23b9db[_0x327600('0x33')]],'as':_0x23b9db['as'],'attributes':_0x23b9db[_0x327600('0x1')],'include':_0x23b9db[_0x327600('0x34')]?_['map'](_0x23b9db[_0x327600('0x34')],function(_0x2efb89){const _0xf49ad=_0x327600;return{'model':db[_0x2efb89[_0xf49ad('0x33')]],'as':_0x2efb89['as'],'attributes':_0x2efb89['attributes']};}):[]};}):[]};}):[]:[]})[_0x557931('0x30')](function(_0x2a16a4){const _0x2688a4=_0x557931;logger[_0x2688a4('0x1b')]('GetCmHopper',_0x256d81),logger[_0x2688a4('0x2')](_0x2688a4('0x26'),_0x256d81,JSON[_0x2688a4('0xa')](_0x2a16a4)),_0x3928a3(_0x2a16a4);})[_0x557931('0x1f')](function(_0x1c40bd){const _0x52ec36=_0x557931;logger[_0x52ec36('0x38')]('GetCmHopper',_0x1c40bd[_0x52ec36('0x20')],_0x256d81),_0x2ab080(_0x4584da['error'](0x1f4,_0x1c40bd[_0x52ec36('0x20')]));});});},exports[_0x2850d1('0x13')]=function(_0x16d18f){const _0x1e8711=this;return new Promise(function(_0x3c1b4f,_0x3c8079){const _0x4461f9=a139_0x2d46;return db['CmHopper'][_0x4461f9('0x24')]({'raw':_0x16d18f[_0x4461f9('0x6')]?_0x16d18f[_0x4461f9('0x6')][_0x4461f9('0x2b')]===undefined?!![]:![]:!![],'where':_0x16d18f[_0x4461f9('0x6')]?_0x16d18f[_0x4461f9('0x6')]['where']||null:null,'attributes':_0x16d18f[_0x4461f9('0x6')]?_0x16d18f[_0x4461f9('0x6')]['attributes']||null:null,'include':_0x16d18f['options']?_0x16d18f[_0x4461f9('0x6')][_0x4461f9('0x34')]?_[_0x4461f9('0x2e')](_0x16d18f[_0x4461f9('0x6')][_0x4461f9('0x34')],function(_0x673f72){const _0x30e010=_0x4461f9;return{'model':db[_0x673f72[_0x30e010('0x33')]],'as':_0x673f72['as'],'attributes':_0x673f72[_0x30e010('0x1')],'include':_0x673f72[_0x30e010('0x34')]?_['map'](_0x673f72['include'],function(_0x375e13){const _0x61aed4=_0x30e010;return{'model':db[_0x375e13[_0x61aed4('0x33')]],'as':_0x375e13['as'],'attributes':_0x375e13[_0x61aed4('0x1')],'include':_0x375e13[_0x61aed4('0x34')]?_[_0x61aed4('0x2e')](_0x375e13[_0x61aed4('0x34')],function(_0x17f828){const _0x566899=_0x61aed4;return{'model':db[_0x17f828[_0x566899('0x33')]],'as':_0x17f828['as'],'attributes':_0x17f828[_0x566899('0x1')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x5d4a07){const _0x31a9b7=_0x4461f9;logger['info'](_0x31a9b7('0x13'),_0x16d18f),logger['debug']('ShowCmHopper',_0x16d18f,JSON[_0x31a9b7('0xa')](_0x5d4a07)),_0x3c1b4f(_0x5d4a07);})[_0x4461f9('0x1f')](function(_0xae1cc9){const _0x25b0fe=_0x4461f9;logger['error'](_0x25b0fe('0x13'),_0xae1cc9[_0x25b0fe('0x20')],_0x16d18f),_0x3c8079(_0x1e8711[_0x25b0fe('0x38')](0x1f4,_0xae1cc9[_0x25b0fe('0x20')]));});});},exports[_0x2850d1('0x39')]=function(_0x63d4c5){const _0x1a05de=this;return new Promise(function(_0x887b53,_0x737eb8){const _0x3b0247=a139_0x2d46;return db[_0x3b0247('0x0')][_0x3b0247('0x18')](_0x63d4c5[_0x3b0247('0x2a')],{'raw':_0x63d4c5['options']?_0x63d4c5[_0x3b0247('0x6')][_0x3b0247('0x2b')]===undefined?!![]:![]:!![]})[_0x3b0247('0x30')](function(_0x23545f){const _0x735bfd=_0x3b0247;logger[_0x735bfd('0x1b')](_0x735bfd('0x39'),_0x63d4c5),logger[_0x735bfd('0x2')]('CreateCmHopper',_0x63d4c5,JSON[_0x735bfd('0xa')](_0x23545f)),_0x887b53(_0x23545f);})[_0x3b0247('0x1f')](function(_0x17119b){const _0x3b5098=_0x3b0247;logger[_0x3b5098('0x38')]('CreateCmHopper',_0x17119b[_0x3b5098('0x20')],_0x63d4c5),_0x737eb8(_0x1a05de[_0x3b5098('0x38')](0x1f4,_0x17119b[_0x3b5098('0x20')]));});});},exports[_0x2850d1('0x27')]=function(_0x4b4ad1){const _0x183d47=this;return new Promise(function(_0x517f2d,_0xb61ec2){const _0x8d9d05=a139_0x2d46;return db[_0x8d9d05('0x0')]['update'](_0x4b4ad1[_0x8d9d05('0x2a')],{'raw':_0x4b4ad1[_0x8d9d05('0x6')]?_0x4b4ad1[_0x8d9d05('0x6')][_0x8d9d05('0x2b')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x4b4ad1[_0x8d9d05('0x6')]?_0x4b4ad1[_0x8d9d05('0x6')][_0x8d9d05('0x12')]||null:null,'attributes':_0x4b4ad1['options']?_0x4b4ad1[_0x8d9d05('0x6')]['attributes']||null:null,'limit':_0x4b4ad1['options']?_0x4b4ad1[_0x8d9d05('0x6')][_0x8d9d05('0x11')]||null:null})[_0x8d9d05('0x30')](function(_0x3ebc13){const _0x29b543=_0x8d9d05;logger[_0x29b543('0x1b')](_0x29b543('0x27'),_0x4b4ad1),logger[_0x29b543('0x2')](_0x29b543('0x27'),_0x4b4ad1,JSON[_0x29b543('0xa')](_0x3ebc13)),_0x517f2d(_0x3ebc13);})[_0x8d9d05('0x1f')](function(_0x251584){const _0x1d7209=_0x8d9d05;logger[_0x1d7209('0x38')](_0x1d7209('0x27'),_0x251584[_0x1d7209('0x20')],_0x4b4ad1),_0xb61ec2(_0x183d47['error'](0x1f4,_0x251584['message']));});});},exports[_0x2850d1('0x8')]=function(_0x5a9de6){const _0xa26c68=this;return new Promise(function(_0x21519e,_0x320b60){const _0x31e635=a139_0x2d46;return db[_0x31e635('0x0')][_0x31e635('0x19')]({'where':_0x5a9de6[_0x31e635('0x6')]?_0x5a9de6['options'][_0x31e635('0x12')]||null:null})[_0x31e635('0x30')](function(_0x3b7053){const _0x538bbd=_0x31e635;logger[_0x538bbd('0x1b')]('DestroyCmHopper',_0x5a9de6),logger[_0x538bbd('0x2')](_0x538bbd('0x8'),_0x5a9de6,JSON['stringify'](_0x3b7053)),_0x21519e(_0x3b7053);})['catch'](function(_0x7d26a4){const _0x37bf8f=_0x31e635;logger[_0x37bf8f('0x38')](_0x37bf8f('0x8'),_0x7d26a4[_0x37bf8f('0x20')],_0x5a9de6),_0x320b60(_0xa26c68[_0x37bf8f('0x38')](0x1f4,_0x7d26a4[_0x37bf8f('0x20')]));});});},exports[_0x2850d1('0x15')]=function(_0xbca6c4){const _0x12c2c3=this;return new Promise(function(_0x15e228,_0x973b08){const _0x1845b2=a139_0x2d46;return db['CmContact'][_0x1845b2('0x2d')]()[_0x1845b2('0x30')](function(_0xaee8b8){const _0x4f1885=_0x1845b2;return db[_0x4f1885('0x22')]['transaction'](function(_0x5c4573){const _0x8c56bc=_0x4f1885;return db[_0x8c56bc('0x0')][_0x8c56bc('0x14')]({'where':_0xbca6c4[_0x8c56bc('0x6')]?_0xbca6c4[_0x8c56bc('0x6')]['where']||null:null,'attributes':_0xbca6c4[_0x8c56bc('0x6')]?_0xbca6c4['options'][_0x8c56bc('0x1')]||null:null,'limit':_0xbca6c4[_0x8c56bc('0x6')]?_0xbca6c4[_0x8c56bc('0x6')][_0x8c56bc('0x11')]||null:null,'order':_0xbca6c4[_0x8c56bc('0x6')]?_0xbca6c4[_0x8c56bc('0x6')]['order']||null:null,'transaction':_0x5c4573,'lock':_0x5c4573[_0x8c56bc('0x7')][_0x8c56bc('0x29')],'include':[{'model':db['CmContact'],'as':_0x8c56bc('0x37'),'attributes':_[_0x8c56bc('0x1e')](_0xaee8b8)},{'model':db[_0x8c56bc('0x23')],'as':'Agent','attributes':['id','name','voicePause']}]})[_0x8c56bc('0x30')](function(_0x2f5537){const _0x4e0342=_0x8c56bc,_0x25961b=[],_0x46310b=[];for(let _0x17f602=0x0;_0x17f602<_0x2f5537[_0x4e0342('0x2c')];_0x17f602+=0x1){!_0x46310b[_0x4e0342('0xd')](_0x2f5537[_0x17f602][_0x4e0342('0x9')])&&(_0x46310b[_0x4e0342('0x5')](_0x2f5537[_0x17f602][_0x4e0342('0x9')]),_0x25961b[_0x4e0342('0x5')](_0x2f5537[_0x17f602][_0x4e0342('0xf')](_0xbca6c4['body'],{'transaction':_0x5c4573})));}return Promise['all'](_0x25961b);});})['then'](function(_0x22645b){const _0x486867=_0x4f1885;logger[_0x486867('0x1b')]('GetContactDialer',_0xbca6c4),logger[_0x486867('0x2')]('GetContactDialer',_0xbca6c4,JSON[_0x486867('0xa')](_0x22645b)),_0x15e228(_0x22645b);})[_0x4f1885('0x1f')](function(_0x3fbe26){const _0x3ba2fb=_0x4f1885;logger[_0x3ba2fb('0x38')](_0x3ba2fb('0x15'),_0x3fbe26[_0x3ba2fb('0x20')],_0xbca6c4),_0x973b08(_0x12c2c3['error'](0x1f4,_0x3fbe26[_0x3ba2fb('0x20')]));});});});},exports[_0x2850d1('0x28')]=function(_0x39e48e){const _0x131afb=this;return new Promise(function(_0x5b530b,_0x59f72e){const _0x2711ab=a139_0x2d46;return db[_0x2711ab('0x22')][_0x2711ab('0x1a')](function(_0x2d17a5){const _0x5ac265=_0x2711ab;return db[_0x5ac265('0x1d')]['create'](_0x39e48e['body'],{'raw':_0x39e48e[_0x5ac265('0x6')]?_0x39e48e[_0x5ac265('0x6')]['raw']===undefined?!![]:![]:!![],'transaction':_0x2d17a5})['then'](function(){const _0x2a90dc=_0x5ac265;return db['CmHopper'][_0x2a90dc('0x19')]({'where':_0x39e48e[_0x2a90dc('0x6')]?_0x39e48e[_0x2a90dc('0x6')][_0x2a90dc('0x12')]||null:null,'transaction':_0x2d17a5});});})[_0x2711ab('0x30')](function(_0x9915d8){const _0x434909=_0x2711ab;logger[_0x434909('0x1b')](_0x434909('0x28'),_0x39e48e),logger[_0x434909('0x2')](_0x434909('0x28'),_0x39e48e,JSON[_0x434909('0xa')](_0x9915d8)),_0x5b530b(_0x9915d8);})['catch'](function(_0x4f1627){const _0x1869ed=_0x2711ab;logger[_0x1869ed('0x38')](_0x1869ed('0x28'),_0x4f1627[_0x1869ed('0x20')],_0x39e48e),_0x59f72e(_0x131afb[_0x1869ed('0x38')](0x1f4,_0x4f1627[_0x1869ed('0x20')]));});});},exports['CountReScheduled']=function(_0x2969b3){const _0x2433a2=this;return new Promise(function(_0x5b3090,_0x11d531){const _0x5a16a5=a139_0x2d46;return db[_0x5a16a5('0x0')][_0x5a16a5('0x14')]({'raw':_0x2969b3[_0x5a16a5('0x6')]?_0x2969b3['options'][_0x5a16a5('0x2b')]===undefined?!![]:![]:!![],'where':_0x2969b3['options']?_0x2969b3['options'][_0x5a16a5('0x12')]||null:null,'attributes':[[fn(_0x5a16a5('0x1c'),fn('IF',literal(_0x5a16a5('0xe')+util[_0x5a16a5('0x3')](_0x5a16a5('0x2f'),moment()[_0x5a16a5('0x3')](_0x5a16a5('0x16')))+_0x5a16a5('0x32')))),'contactsRescheduled']]})[_0x5a16a5('0x30')](function(_0x5c37f0){const _0x3b9615=_0x5a16a5;logger['info'](_0x3b9615('0x4'),_0x2969b3),logger['debug']('CountReScheduled',_0x2969b3,JSON[_0x3b9615('0xa')](_0x5c37f0)),_0x5b3090(_0x5c37f0);})[_0x5a16a5('0x1f')](function(_0x1caf60){const _0x54c965=_0x5a16a5;logger['error'](_0x54c965('0x4'),_0x1caf60[_0x54c965('0x20')],_0x2969b3),_0x11d531(_0x2433a2[_0x54c965('0x38')](0x1f4,_0x1caf60['message']));});});},exports[_0x2850d1('0xc')]=function(_0x2c242a){const _0xfc2ce0=this;return new Promise(function(_0x43509b,_0x5bd06c){const _0x12e0bd=a139_0x2d46;return db[_0x12e0bd('0xb')][_0x12e0bd('0x2d')]()[_0x12e0bd('0x30')](function(){const _0x3a8b63=_0x12e0bd;return db[_0x3a8b63('0x22')][_0x3a8b63('0x1a')](function(_0x3893d1){const _0xcf7da7=_0x3a8b63;return db['CmHopper'][_0xcf7da7('0x14')]({'where':_0x2c242a['options']?_0x2c242a[_0xcf7da7('0x6')]['where']||null:null,'attributes':_0x2c242a[_0xcf7da7('0x6')]?_0x2c242a[_0xcf7da7('0x6')][_0xcf7da7('0x1')]||null:null,'limit':0x1,'order':_0x2c242a[_0xcf7da7('0x6')]?_0x2c242a[_0xcf7da7('0x6')][_0xcf7da7('0x25')]||null:null,'group':db[_0xcf7da7('0x0')][_0xcf7da7('0x9')],'transaction':_0x3893d1,'lock':_0x3893d1[_0xcf7da7('0x7')][_0xcf7da7('0x29')],'include':_0x2c242a[_0xcf7da7('0x6')]?_0x2c242a[_0xcf7da7('0x6')][_0xcf7da7('0x34')]?_[_0xcf7da7('0x2e')](_0x2c242a[_0xcf7da7('0x6')][_0xcf7da7('0x34')],function(_0x188dc7){const _0x2bcbdf=_0xcf7da7;return{'model':db[_0x188dc7[_0x2bcbdf('0x33')]],'as':_0x188dc7['as'],'attributes':_0x188dc7[_0x2bcbdf('0x1')],'include':_0x188dc7[_0x2bcbdf('0x34')]?_['map'](_0x188dc7[_0x2bcbdf('0x34')],function(_0x35a4e2){const _0x147a11=_0x2bcbdf;return{'model':db[_0x35a4e2[_0x147a11('0x33')]],'as':_0x35a4e2['as'],'attributes':_0x35a4e2['attributes'],'include':_0x35a4e2[_0x147a11('0x34')]?_[_0x147a11('0x2e')](_0x35a4e2['include'],function(_0x2eddd7){const _0x1fca7e=_0x147a11;return{'model':db[_0x2eddd7[_0x1fca7e('0x33')]],'as':_0x2eddd7['as'],'attributes':_0x2eddd7['attributes']};}):[]};}):[]};}):[]:[]})[_0xcf7da7('0x30')](function(_0x1f43b2){const _0x180fa7=_0xcf7da7,_0x4a00e4=[];for(let _0x59cf13=0x0;_0x59cf13<_0x1f43b2[_0x180fa7('0x2c')];_0x59cf13+=0x1){_0x4a00e4['push'](_0x1f43b2[_0x59cf13][_0x180fa7('0xf')](_0x2c242a[_0x180fa7('0x2a')],{'transaction':_0x3893d1}));}return Promise[_0x180fa7('0x36')](_0x4a00e4);});})[_0x3a8b63('0x30')](function(_0x37e6ae){const _0x1b2868=_0x3a8b63;logger[_0x1b2868('0x1b')](_0x1b2868('0xc'),_0x2c242a),logger[_0x1b2868('0x2')](_0x1b2868('0xc'),_0x2c242a,JSON[_0x1b2868('0xa')](_0x37e6ae)),_0x43509b(_0x37e6ae);})['catch'](function(_0x3f9714){const _0x416843=_0x3a8b63;logger[_0x416843('0x38')](_0x416843('0xc'),_0x3f9714[_0x416843('0x20')],_0x2c242a),_0x5bd06c(_0xfc2ce0[_0x416843('0x38')](0x1f4,_0x3f9714[_0x416843('0x20')]));});});});},exports['GetCmHopperPreview']=function(_0x4d2de6){const _0x39c721=this;return new Promise(function(_0x2e0344,_0x1e6632){const _0x280fce=a139_0x2d46;db[_0x280fce('0xb')][_0x280fce('0x2d')]()[_0x280fce('0x30')](function(_0x3103f4){const _0x393dcc=_0x280fce;return db[_0x393dcc('0x0')][_0x393dcc('0x14')]({'raw':_0x4d2de6[_0x393dcc('0x6')]?_0x4d2de6[_0x393dcc('0x6')][_0x393dcc('0x2b')]===undefined?!![]:![]:!![],'where':_0x4d2de6[_0x393dcc('0x6')]?_0x4d2de6[_0x393dcc('0x6')][_0x393dcc('0x12')]||null:null,'attributes':_0x4d2de6[_0x393dcc('0x6')]?_0x4d2de6[_0x393dcc('0x6')]['attributes']||null:null,'limit':_0x4d2de6[_0x393dcc('0x6')]?_0x4d2de6[_0x393dcc('0x6')][_0x393dcc('0x11')]||null:null,'include':_0x4d2de6[_0x393dcc('0x6')]?_0x4d2de6['options']['include']?_[_0x393dcc('0x2e')](_0x4d2de6[_0x393dcc('0x6')][_0x393dcc('0x34')],function(_0xc00f4a){const _0x3fb71d=_0x393dcc;return{'model':db[_0xc00f4a[_0x3fb71d('0x33')]],'as':_0xc00f4a['as'],'attributes':_0xc00f4a['as']==='Contact'?_[_0x3fb71d('0x1e')](_0x3103f4):_0xc00f4a[_0x3fb71d('0x1')],'include':_0xc00f4a[_0x3fb71d('0x34')]?_[_0x3fb71d('0x2e')](_0xc00f4a[_0x3fb71d('0x34')],function(_0x54ca03){const _0x252e01=_0x3fb71d;return{'model':db[_0x54ca03['model']],'as':_0x54ca03['as'],'attributes':_0x54ca03[_0x252e01('0x1')],'include':_0x54ca03[_0x252e01('0x34')]?_['map'](_0x54ca03[_0x252e01('0x34')],function(_0x376e83){const _0x1c631b=_0x252e01;return{'model':db[_0x376e83['model']],'as':_0x376e83['as'],'attributes':_0x376e83[_0x1c631b('0x1')]};}):[]};}):[]};}):[]:[]})[_0x393dcc('0x30')](function(_0x5b8a0d){const _0x5f123b=_0x393dcc;logger['info'](_0x5f123b('0x26'),_0x4d2de6),logger[_0x5f123b('0x2')](_0x5f123b('0x26'),_0x4d2de6,JSON[_0x5f123b('0xa')](_0x5b8a0d)),_0x2e0344(_0x5b8a0d);})[_0x393dcc('0x1f')](function(_0x17768f){const _0x2844c0=_0x393dcc;logger['error'](_0x2844c0('0x26'),_0x17768f['message'],_0x4d2de6),_0x1e6632(_0x39c721[_0x2844c0('0x38')](0x1f4,_0x17768f[_0x2844c0('0x20')]));});});});}; \ No newline at end of file +const a139_0x20e5=['UpdateCmHopper','voicePause','options','CmHopper','update','info','order','LOCK','format','destroy','findOne','GetContactRecallMe','raw','User','length','GetCmHopper','UserId','GetCmHopperPreview','lodash','keys','sequelize','describe','contactsRescheduled','`scheduledat`\x20>=\x20','ShowCmHopper','CreateCmHopper','DestroyCmHopper','push','GetContactDialer','\x22%s\x22','Contact','transaction','CountReScheduled','../../config/logger','catch','moment','YYYY-MM-DD\x20HH:mm:ss','includes','CmHopperFinal','map','../../mysqldb','model','include','UPDATE','message','name','debug','CmContact','Agent','stringify','findAll','MoveContactManagedDialer','then','where','error','body','limit','attributes','all'];(function(_0x179054,_0x20e587){const _0x5ef286=function(_0x3de4d5){while(--_0x3de4d5){_0x179054['push'](_0x179054['shift']());}};_0x5ef286(++_0x20e587);}(a139_0x20e5,0x9d));const a139_0x5ef2=function(_0x179054,_0x20e587){_0x179054=_0x179054-0x0;let _0x5ef286=a139_0x20e5[_0x179054];return _0x5ef286;};const _0x425782=a139_0x5ef2;'use strict';const _=require(_0x425782('0x26')),util=require('util'),moment=require(_0x425782('0x37')),db=require(_0x425782('0x1'))['db'],logger=require(_0x425782('0x35'))('rpc'),{literal,fn}=require(_0x425782('0x28'));exports[_0x425782('0x23')]=function(_0x3de4d5){const _0xb5414a=this;return new Promise(function(_0x44f700,_0x1fe0d4){const _0x22679a=a139_0x5ef2;return db[_0x22679a('0x17')][_0x22679a('0xb')]({'raw':_0x3de4d5[_0x22679a('0x16')]?_0x3de4d5[_0x22679a('0x16')][_0x22679a('0x20')]===undefined?!![]:![]:!![],'where':_0x3de4d5['options']?_0x3de4d5[_0x22679a('0x16')][_0x22679a('0xe')]||null:null,'attributes':_0x3de4d5['options']?_0x3de4d5[_0x22679a('0x16')][_0x22679a('0x12')]||null:null,'limit':_0x3de4d5['options']?_0x3de4d5[_0x22679a('0x16')][_0x22679a('0x11')]||null:null,'include':_0x3de4d5[_0x22679a('0x16')]?_0x3de4d5[_0x22679a('0x16')]['include']?_['map'](_0x3de4d5['options'][_0x22679a('0x3')],function(_0x5c390b){const _0x2eb876=_0x22679a;return{'model':db[_0x5c390b['model']],'as':_0x5c390b['as'],'attributes':_0x5c390b[_0x2eb876('0x12')],'include':_0x5c390b[_0x2eb876('0x3')]?_['map'](_0x5c390b['include'],function(_0x3f833c){const _0x17aea7=_0x2eb876;return{'model':db[_0x3f833c[_0x17aea7('0x2')]],'as':_0x3f833c['as'],'attributes':_0x3f833c['attributes'],'include':_0x3f833c[_0x17aea7('0x3')]?_[_0x17aea7('0x0')](_0x3f833c[_0x17aea7('0x3')],function(_0x3066fb){const _0x36fddb=_0x17aea7;return{'model':db[_0x3066fb[_0x36fddb('0x2')]],'as':_0x3066fb['as'],'attributes':_0x3066fb[_0x36fddb('0x12')]};}):[]};}):[]};}):[]:[]})[_0x22679a('0xd')](function(_0x10aefe){const _0x21ceed=_0x22679a;logger[_0x21ceed('0x19')](_0x21ceed('0x23'),_0x3de4d5),logger[_0x21ceed('0x7')](_0x21ceed('0x23'),_0x3de4d5,JSON[_0x21ceed('0xa')](_0x10aefe)),_0x44f700(_0x10aefe);})[_0x22679a('0x36')](function(_0x104036){const _0x1535f2=_0x22679a;logger['error'](_0x1535f2('0x23'),_0x104036[_0x1535f2('0x5')],_0x3de4d5),_0x1fe0d4(_0xb5414a['error'](0x1f4,_0x104036[_0x1535f2('0x5')]));});});},exports[_0x425782('0x2c')]=function(_0x45d7f7){const _0xcd0a89=this;return new Promise(function(_0x3d32f2,_0x3ed52d){const _0x47e0ba=a139_0x5ef2;return db[_0x47e0ba('0x17')][_0x47e0ba('0x1e')]({'raw':_0x45d7f7[_0x47e0ba('0x16')]?_0x45d7f7[_0x47e0ba('0x16')]['raw']===undefined?!![]:![]:!![],'where':_0x45d7f7[_0x47e0ba('0x16')]?_0x45d7f7[_0x47e0ba('0x16')]['where']||null:null,'attributes':_0x45d7f7[_0x47e0ba('0x16')]?_0x45d7f7[_0x47e0ba('0x16')][_0x47e0ba('0x12')]||null:null,'include':_0x45d7f7['options']?_0x45d7f7[_0x47e0ba('0x16')]['include']?_['map'](_0x45d7f7[_0x47e0ba('0x16')][_0x47e0ba('0x3')],function(_0x18beff){const _0xabb920=_0x47e0ba;return{'model':db[_0x18beff[_0xabb920('0x2')]],'as':_0x18beff['as'],'attributes':_0x18beff[_0xabb920('0x12')],'include':_0x18beff[_0xabb920('0x3')]?_[_0xabb920('0x0')](_0x18beff[_0xabb920('0x3')],function(_0x508fe5){const _0x592110=_0xabb920;return{'model':db[_0x508fe5[_0x592110('0x2')]],'as':_0x508fe5['as'],'attributes':_0x508fe5[_0x592110('0x12')],'include':_0x508fe5[_0x592110('0x3')]?_[_0x592110('0x0')](_0x508fe5[_0x592110('0x3')],function(_0xe16a5b){const _0x390443=_0x592110;return{'model':db[_0xe16a5b['model']],'as':_0xe16a5b['as'],'attributes':_0xe16a5b[_0x390443('0x12')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x3d6f9d){const _0x3f3b64=_0x47e0ba;logger[_0x3f3b64('0x19')](_0x3f3b64('0x2c'),_0x45d7f7),logger[_0x3f3b64('0x7')](_0x3f3b64('0x2c'),_0x45d7f7,JSON[_0x3f3b64('0xa')](_0x3d6f9d)),_0x3d32f2(_0x3d6f9d);})[_0x47e0ba('0x36')](function(_0x23af13){const _0x4096d3=_0x47e0ba;logger[_0x4096d3('0xf')](_0x4096d3('0x2c'),_0x23af13[_0x4096d3('0x5')],_0x45d7f7),_0x3ed52d(_0xcd0a89[_0x4096d3('0xf')](0x1f4,_0x23af13[_0x4096d3('0x5')]));});});},exports['CreateCmHopper']=function(_0x17b7b6){const _0xae7706=this;return new Promise(function(_0x33c847,_0x13708b){const _0x2b84ec=a139_0x5ef2;return db['CmHopper']['create'](_0x17b7b6['body'],{'raw':_0x17b7b6[_0x2b84ec('0x16')]?_0x17b7b6[_0x2b84ec('0x16')][_0x2b84ec('0x20')]===undefined?!![]:![]:!![]})[_0x2b84ec('0xd')](function(_0x1c7f0d){const _0x2e10ee=_0x2b84ec;logger[_0x2e10ee('0x19')]('CreateCmHopper',_0x17b7b6),logger['debug'](_0x2e10ee('0x2d'),_0x17b7b6,JSON[_0x2e10ee('0xa')](_0x1c7f0d)),_0x33c847(_0x1c7f0d);})[_0x2b84ec('0x36')](function(_0xe3ceab){const _0x3b38e6=_0x2b84ec;logger[_0x3b38e6('0xf')](_0x3b38e6('0x2d'),_0xe3ceab[_0x3b38e6('0x5')],_0x17b7b6),_0x13708b(_0xae7706[_0x3b38e6('0xf')](0x1f4,_0xe3ceab[_0x3b38e6('0x5')]));});});},exports[_0x425782('0x14')]=function(_0x2d3955){const _0x1cc044=this;return new Promise(function(_0x8793c5,_0xc4fbc1){const _0x26c2e2=a139_0x5ef2;return db['CmHopper'][_0x26c2e2('0x18')](_0x2d3955['body'],{'raw':_0x2d3955['options']?_0x2d3955[_0x26c2e2('0x16')][_0x26c2e2('0x20')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x2d3955['options']?_0x2d3955[_0x26c2e2('0x16')][_0x26c2e2('0xe')]||null:null,'attributes':_0x2d3955[_0x26c2e2('0x16')]?_0x2d3955['options'][_0x26c2e2('0x12')]||null:null,'limit':_0x2d3955['options']?_0x2d3955[_0x26c2e2('0x16')][_0x26c2e2('0x11')]||null:null})[_0x26c2e2('0xd')](function(_0x345d67){const _0x3e001a=_0x26c2e2;logger['info'](_0x3e001a('0x14'),_0x2d3955),logger[_0x3e001a('0x7')](_0x3e001a('0x14'),_0x2d3955,JSON['stringify'](_0x345d67)),_0x8793c5(_0x345d67);})['catch'](function(_0xfcfbf){const _0x502fe8=_0x26c2e2;logger['error']('UpdateCmHopper',_0xfcfbf[_0x502fe8('0x5')],_0x2d3955),_0xc4fbc1(_0x1cc044['error'](0x1f4,_0xfcfbf['message']));});});},exports['DestroyCmHopper']=function(_0x562cfa){const _0x320a0b=this;return new Promise(function(_0x3b42bb,_0x2b772b){const _0x12395b=a139_0x5ef2;return db[_0x12395b('0x17')][_0x12395b('0x1d')]({'where':_0x562cfa[_0x12395b('0x16')]?_0x562cfa['options'][_0x12395b('0xe')]||null:null})[_0x12395b('0xd')](function(_0x2239c9){const _0x1db62b=_0x12395b;logger[_0x1db62b('0x19')](_0x1db62b('0x2e'),_0x562cfa),logger[_0x1db62b('0x7')]('DestroyCmHopper',_0x562cfa,JSON[_0x1db62b('0xa')](_0x2239c9)),_0x3b42bb(_0x2239c9);})[_0x12395b('0x36')](function(_0x6f0a98){const _0xad361d=_0x12395b;logger[_0xad361d('0xf')]('DestroyCmHopper',_0x6f0a98[_0xad361d('0x5')],_0x562cfa),_0x2b772b(_0x320a0b[_0xad361d('0xf')](0x1f4,_0x6f0a98[_0xad361d('0x5')]));});});},exports[_0x425782('0x30')]=function(_0x21c938){const _0x47e149=this;return new Promise(function(_0xca4659,_0x5b2d44){const _0x24bd82=a139_0x5ef2;return db[_0x24bd82('0x8')]['describe']()['then'](function(_0x38829d){const _0x3d582a=_0x24bd82;return db[_0x3d582a('0x28')][_0x3d582a('0x33')](function(_0x59c6e3){const _0x2d1546=_0x3d582a;return db[_0x2d1546('0x17')][_0x2d1546('0xb')]({'where':_0x21c938[_0x2d1546('0x16')]?_0x21c938[_0x2d1546('0x16')][_0x2d1546('0xe')]||null:null,'attributes':_0x21c938[_0x2d1546('0x16')]?_0x21c938[_0x2d1546('0x16')][_0x2d1546('0x12')]||null:null,'limit':_0x21c938[_0x2d1546('0x16')]?_0x21c938['options'][_0x2d1546('0x11')]||null:null,'order':_0x21c938[_0x2d1546('0x16')]?_0x21c938[_0x2d1546('0x16')][_0x2d1546('0x1a')]||null:null,'transaction':_0x59c6e3,'lock':_0x59c6e3[_0x2d1546('0x1b')][_0x2d1546('0x4')],'include':[{'model':db[_0x2d1546('0x8')],'as':_0x2d1546('0x32'),'attributes':_[_0x2d1546('0x27')](_0x38829d)},{'model':db[_0x2d1546('0x21')],'as':_0x2d1546('0x9'),'attributes':['id',_0x2d1546('0x6'),_0x2d1546('0x15')]}]})[_0x2d1546('0xd')](function(_0x483e1f){const _0x646b3f=_0x2d1546,_0x345ac0=[],_0x5b5529=[];for(let _0x365090=0x0;_0x365090<_0x483e1f['length'];_0x365090+=0x1){!_0x5b5529[_0x646b3f('0x39')](_0x483e1f[_0x365090][_0x646b3f('0x24')])&&(_0x5b5529[_0x646b3f('0x2f')](_0x483e1f[_0x365090][_0x646b3f('0x24')]),_0x345ac0[_0x646b3f('0x2f')](_0x483e1f[_0x365090][_0x646b3f('0x18')](_0x21c938[_0x646b3f('0x10')],{'transaction':_0x59c6e3})));}return Promise[_0x646b3f('0x13')](_0x345ac0);});})[_0x3d582a('0xd')](function(_0x154cae){const _0x438dcb=_0x3d582a;logger[_0x438dcb('0x19')](_0x438dcb('0x30'),_0x21c938),logger['debug'](_0x438dcb('0x30'),_0x21c938,JSON[_0x438dcb('0xa')](_0x154cae)),_0xca4659(_0x154cae);})[_0x3d582a('0x36')](function(_0xbd360){const _0x4d02a4=_0x3d582a;logger[_0x4d02a4('0xf')]('GetContactDialer',_0xbd360[_0x4d02a4('0x5')],_0x21c938),_0x5b2d44(_0x47e149[_0x4d02a4('0xf')](0x1f4,_0xbd360[_0x4d02a4('0x5')]));});});});},exports[_0x425782('0xc')]=function(_0x4e2971){const _0x2f251f=this;return new Promise(function(_0x28ebef,_0x427e50){const _0x1e0a3c=a139_0x5ef2;return db[_0x1e0a3c('0x28')][_0x1e0a3c('0x33')](function(_0x39f54a){const _0x17408c=_0x1e0a3c;return db[_0x17408c('0x3a')]['create'](_0x4e2971[_0x17408c('0x10')],{'raw':_0x4e2971[_0x17408c('0x16')]?_0x4e2971[_0x17408c('0x16')][_0x17408c('0x20')]===undefined?!![]:![]:!![],'transaction':_0x39f54a})[_0x17408c('0xd')](function(){const _0x55a7db=_0x17408c;return db[_0x55a7db('0x17')][_0x55a7db('0x1d')]({'where':_0x4e2971[_0x55a7db('0x16')]?_0x4e2971[_0x55a7db('0x16')][_0x55a7db('0xe')]||null:null,'transaction':_0x39f54a});});})[_0x1e0a3c('0xd')](function(_0xb3b074){const _0x1913fc=_0x1e0a3c;logger[_0x1913fc('0x19')]('MoveContactManagedDialer',_0x4e2971),logger['debug'](_0x1913fc('0xc'),_0x4e2971,JSON[_0x1913fc('0xa')](_0xb3b074)),_0x28ebef(_0xb3b074);})[_0x1e0a3c('0x36')](function(_0x5db89e){const _0x3d4187=_0x1e0a3c;logger[_0x3d4187('0xf')](_0x3d4187('0xc'),_0x5db89e[_0x3d4187('0x5')],_0x4e2971),_0x427e50(_0x2f251f[_0x3d4187('0xf')](0x1f4,_0x5db89e['message']));});});},exports['CountReScheduled']=function(_0x8f2cce){const _0x33ef65=this;return new Promise(function(_0x40d6fc,_0x56a9a0){const _0x5a10b4=a139_0x5ef2;return db['CmHopper'][_0x5a10b4('0xb')]({'raw':_0x8f2cce[_0x5a10b4('0x16')]?_0x8f2cce[_0x5a10b4('0x16')]['raw']===undefined?!![]:![]:!![],'where':_0x8f2cce[_0x5a10b4('0x16')]?_0x8f2cce[_0x5a10b4('0x16')][_0x5a10b4('0xe')]||null:null,'attributes':[[fn('COUNT',fn('IF',literal(_0x5a10b4('0x2b')+util[_0x5a10b4('0x1c')](_0x5a10b4('0x31'),moment()['format'](_0x5a10b4('0x38')))+'\x20,\x201,\x20null'))),_0x5a10b4('0x2a')]]})[_0x5a10b4('0xd')](function(_0x5402ef){const _0x386677=_0x5a10b4;logger[_0x386677('0x19')]('CountReScheduled',_0x8f2cce),logger['debug'](_0x386677('0x34'),_0x8f2cce,JSON['stringify'](_0x5402ef)),_0x40d6fc(_0x5402ef);})[_0x5a10b4('0x36')](function(_0x57ac91){const _0x5824d2=_0x5a10b4;logger[_0x5824d2('0xf')](_0x5824d2('0x34'),_0x57ac91[_0x5824d2('0x5')],_0x8f2cce),_0x56a9a0(_0x33ef65[_0x5824d2('0xf')](0x1f4,_0x57ac91[_0x5824d2('0x5')]));});});},exports[_0x425782('0x1f')]=function(_0x30d908){const _0x50ad06=this;return new Promise(function(_0x4e8eaa,_0x4b900c){const _0x2d0a7d=a139_0x5ef2;return db[_0x2d0a7d('0x8')][_0x2d0a7d('0x29')]()[_0x2d0a7d('0xd')](function(){const _0x1a060b=_0x2d0a7d;return db['sequelize'][_0x1a060b('0x33')](function(_0x297aae){const _0x27f0f9=_0x1a060b;return db['CmHopper']['findAll']({'where':_0x30d908[_0x27f0f9('0x16')]?_0x30d908[_0x27f0f9('0x16')][_0x27f0f9('0xe')]||null:null,'attributes':_0x30d908[_0x27f0f9('0x16')]?_0x30d908[_0x27f0f9('0x16')][_0x27f0f9('0x12')]||null:null,'limit':0x1,'order':_0x30d908[_0x27f0f9('0x16')]?_0x30d908['options']['order']||null:null,'group':db[_0x27f0f9('0x17')][_0x27f0f9('0x24')],'transaction':_0x297aae,'lock':_0x297aae['LOCK']['UPDATE'],'include':_0x30d908[_0x27f0f9('0x16')]?_0x30d908[_0x27f0f9('0x16')][_0x27f0f9('0x3')]?_['map'](_0x30d908[_0x27f0f9('0x16')][_0x27f0f9('0x3')],function(_0x175c08){const _0x44ba92=_0x27f0f9;return{'model':db[_0x175c08[_0x44ba92('0x2')]],'as':_0x175c08['as'],'attributes':_0x175c08[_0x44ba92('0x12')],'include':_0x175c08[_0x44ba92('0x3')]?_[_0x44ba92('0x0')](_0x175c08[_0x44ba92('0x3')],function(_0x156b33){const _0x1e75f2=_0x44ba92;return{'model':db[_0x156b33[_0x1e75f2('0x2')]],'as':_0x156b33['as'],'attributes':_0x156b33[_0x1e75f2('0x12')],'include':_0x156b33[_0x1e75f2('0x3')]?_[_0x1e75f2('0x0')](_0x156b33['include'],function(_0x551c12){const _0x210cd3=_0x1e75f2;return{'model':db[_0x551c12[_0x210cd3('0x2')]],'as':_0x551c12['as'],'attributes':_0x551c12[_0x210cd3('0x12')]};}):[]};}):[]};}):[]:[]})[_0x27f0f9('0xd')](function(_0x59e44e){const _0x714895=_0x27f0f9,_0x46e980=[];for(let _0x45f4d4=0x0;_0x45f4d4<_0x59e44e[_0x714895('0x22')];_0x45f4d4+=0x1){_0x46e980[_0x714895('0x2f')](_0x59e44e[_0x45f4d4][_0x714895('0x18')](_0x30d908[_0x714895('0x10')],{'transaction':_0x297aae}));}return Promise[_0x714895('0x13')](_0x46e980);});})[_0x1a060b('0xd')](function(_0x1934bb){const _0x1c246c=_0x1a060b;logger[_0x1c246c('0x19')](_0x1c246c('0x1f'),_0x30d908),logger['debug']('GetContactRecallMe',_0x30d908,JSON[_0x1c246c('0xa')](_0x1934bb)),_0x4e8eaa(_0x1934bb);})[_0x1a060b('0x36')](function(_0x4300c1){const _0x2040b8=_0x1a060b;logger[_0x2040b8('0xf')](_0x2040b8('0x1f'),_0x4300c1[_0x2040b8('0x5')],_0x30d908),_0x4b900c(_0x50ad06['error'](0x1f4,_0x4300c1[_0x2040b8('0x5')]));});});});},exports[_0x425782('0x25')]=function(_0x3c1205){const _0x27f6f9=this;return new Promise(function(_0x20e542,_0x35b5b4){const _0x260e99=a139_0x5ef2;db[_0x260e99('0x8')][_0x260e99('0x29')]()[_0x260e99('0xd')](function(_0x13cd51){const _0x343301=_0x260e99;return db[_0x343301('0x17')]['findAll']({'raw':_0x3c1205[_0x343301('0x16')]?_0x3c1205[_0x343301('0x16')]['raw']===undefined?!![]:![]:!![],'where':_0x3c1205[_0x343301('0x16')]?_0x3c1205[_0x343301('0x16')][_0x343301('0xe')]||null:null,'attributes':_0x3c1205[_0x343301('0x16')]?_0x3c1205[_0x343301('0x16')][_0x343301('0x12')]||null:null,'limit':_0x3c1205[_0x343301('0x16')]?_0x3c1205[_0x343301('0x16')]['limit']||null:null,'include':_0x3c1205['options']?_0x3c1205[_0x343301('0x16')][_0x343301('0x3')]?_[_0x343301('0x0')](_0x3c1205['options']['include'],function(_0x1718b9){const _0x2bffd4=_0x343301;return{'model':db[_0x1718b9[_0x2bffd4('0x2')]],'as':_0x1718b9['as'],'attributes':_0x1718b9['as']==='Contact'?_[_0x2bffd4('0x27')](_0x13cd51):_0x1718b9[_0x2bffd4('0x12')],'include':_0x1718b9['include']?_[_0x2bffd4('0x0')](_0x1718b9[_0x2bffd4('0x3')],function(_0x3cf206){const _0x4cb87a=_0x2bffd4;return{'model':db[_0x3cf206[_0x4cb87a('0x2')]],'as':_0x3cf206['as'],'attributes':_0x3cf206['attributes'],'include':_0x3cf206['include']?_[_0x4cb87a('0x0')](_0x3cf206[_0x4cb87a('0x3')],function(_0x20b8e1){const _0x5c400a=_0x4cb87a;return{'model':db[_0x20b8e1[_0x5c400a('0x2')]],'as':_0x20b8e1['as'],'attributes':_0x20b8e1[_0x5c400a('0x12')]};}):[]};}):[]};}):[]:[]})[_0x343301('0xd')](function(_0x4c19cf){const _0x164d54=_0x343301;logger['info']('GetCmHopper',_0x3c1205),logger[_0x164d54('0x7')](_0x164d54('0x23'),_0x3c1205,JSON['stringify'](_0x4c19cf)),_0x20e542(_0x4c19cf);})['catch'](function(_0x2a6c66){const _0xaff642=_0x343301;logger[_0xaff642('0xf')](_0xaff642('0x23'),_0x2a6c66[_0xaff642('0x5')],_0x3c1205),_0x35b5b4(_0x27f6f9[_0xaff642('0xf')](0x1f4,_0x2a6c66['message']));});});});}; \ No newline at end of file diff --git a/server/api/cmHopper/index.js b/server/api/cmHopper/index.js index 15174cf..379300f 100644 --- a/server/api/cmHopper/index.js +++ b/server/api/cmHopper/index.js @@ -1 +1 @@ -const a140_0x55f3=['show','update','post','/preview','get','express','describe','isAuthenticated','Router','create','exports','index','/opencontacts','getOpenContacts','put','/describe','/:id','delete'];(function(_0x1d08b5,_0x55f3b8){const _0x5c624d=function(_0x37ec20){while(--_0x37ec20){_0x1d08b5['push'](_0x1d08b5['shift']());}};_0x5c624d(++_0x55f3b8);}(a140_0x55f3,0x1d5));const a140_0x5c62=function(_0x1d08b5,_0x55f3b8){_0x1d08b5=_0x1d08b5-0x0;let _0x5c624d=a140_0x55f3[_0x1d08b5];return _0x5c624d;};const _0x23de4a=a140_0x5c62;'use strict';const express=require(_0x23de4a('0x4')),router=express[_0x23de4a('0x7')](),auth=require('../../components/auth/service'),controller=require('./cmHopper.controller');router[_0x23de4a('0x3')]('/',auth['isAuthenticated'](),controller[_0x23de4a('0xa')]),router['get'](_0x23de4a('0xe'),auth['isAuthenticated'](),controller[_0x23de4a('0x5')]),router[_0x23de4a('0x3')](_0x23de4a('0xb'),auth[_0x23de4a('0x6')](),controller[_0x23de4a('0xc')]),router[_0x23de4a('0x3')](_0x23de4a('0xf'),auth[_0x23de4a('0x6')](),controller[_0x23de4a('0x11')]),router[_0x23de4a('0x1')]('/',auth[_0x23de4a('0x6')](),controller[_0x23de4a('0x8')]),router['post'](_0x23de4a('0x2'),auth[_0x23de4a('0x6')](),controller['getPreview']),router[_0x23de4a('0xd')]('/:id',auth[_0x23de4a('0x6')](),controller[_0x23de4a('0x0')]),router[_0x23de4a('0x10')](_0x23de4a('0xf'),auth[_0x23de4a('0x6')](),controller['destroy']),module[_0x23de4a('0x9')]=router; \ No newline at end of file +const a140_0x4258=['create','/preview','getPreview','./cmHopper.controller','Router','/describe','update','/:id','express','destroy','describe','show','post','../../components/auth/service','get','put','exports','isAuthenticated','delete'];(function(_0x608d42,_0x4258d7){const _0x58c804=function(_0x286fe8){while(--_0x286fe8){_0x608d42['push'](_0x608d42['shift']());}};_0x58c804(++_0x4258d7);}(a140_0x4258,0x104));const a140_0x58c8=function(_0x608d42,_0x4258d7){_0x608d42=_0x608d42-0x0;let _0x58c804=a140_0x4258[_0x608d42];return _0x58c804;};const _0x433625=a140_0x58c8;'use strict';const express=require(_0x433625('0xe')),router=express[_0x433625('0xa')](),auth=require(_0x433625('0x0')),controller=require(_0x433625('0x9'));router['get']('/',auth[_0x433625('0x4')](),controller['index']),router[_0x433625('0x1')](_0x433625('0xb'),auth[_0x433625('0x4')](),controller[_0x433625('0x10')]),router[_0x433625('0x1')]('/opencontacts',auth[_0x433625('0x4')](),controller['getOpenContacts']),router[_0x433625('0x1')](_0x433625('0xd'),auth[_0x433625('0x4')](),controller[_0x433625('0x11')]),router[_0x433625('0x12')]('/',auth[_0x433625('0x4')](),controller[_0x433625('0x6')]),router[_0x433625('0x12')](_0x433625('0x7'),auth[_0x433625('0x4')](),controller[_0x433625('0x8')]),router[_0x433625('0x2')](_0x433625('0xd'),auth['isAuthenticated'](),controller[_0x433625('0xc')]),router[_0x433625('0x5')](_0x433625('0xd'),auth[_0x433625('0x4')](),controller[_0x433625('0xf')]),module[_0x433625('0x3')]=router; \ No newline at end of file diff --git a/server/api/cmHopperBlack/cmHopperBlack.attributes.js b/server/api/cmHopperBlack/cmHopperBlack.attributes.js index 02ac9f2..6aa0bab 100644 --- a/server/api/cmHopperBlack/cmHopperBlack.attributes.js +++ b/server/api/cmHopperBlack/cmHopperBlack.attributes.js @@ -1 +1 @@ -const a141_0xefb8=['INTEGER','contactListQueue','exports','STRING','sequelize'];(function(_0x29d9e8,_0xefb884){const _0x1edc72=function(_0x1a93c8){while(--_0x1a93c8){_0x29d9e8['push'](_0x29d9e8['shift']());}};_0x1edc72(++_0xefb884);}(a141_0xefb8,0x110));const a141_0x1edc=function(_0x29d9e8,_0xefb884){_0x29d9e8=_0x29d9e8-0x0;let _0x1edc72=a141_0xefb8[_0x29d9e8];return _0x1edc72;};const _0x638742=a141_0x1edc;'use strict';const Sequelize=require(_0x638742('0x2'));module[_0x638742('0x0')]={'phone':{'type':Sequelize[_0x638742('0x1')],'allowNull':![]},'ContactId':{'type':Sequelize[_0x638742('0x3')],'unique':_0x638742('0x4')},'ListId':{'type':Sequelize['INTEGER'],'unique':_0x638742('0x4')},'VoiceQueueId':{'type':Sequelize[_0x638742('0x3')],'unique':_0x638742('0x4')}}; \ No newline at end of file +const a141_0x1503=['sequelize','contactListQueue','STRING','exports','INTEGER'];(function(_0xf7d189,_0x15032d){const _0x28ac3a=function(_0xd35de6){while(--_0xd35de6){_0xf7d189['push'](_0xf7d189['shift']());}};_0x28ac3a(++_0x15032d);}(a141_0x1503,0x1ec));const a141_0x28ac=function(_0xf7d189,_0x15032d){_0xf7d189=_0xf7d189-0x0;let _0x28ac3a=a141_0x1503[_0xf7d189];return _0x28ac3a;};const _0x4f59f3=a141_0x28ac;'use strict';const Sequelize=require(_0x4f59f3('0x3'));module[_0x4f59f3('0x1')]={'phone':{'type':Sequelize[_0x4f59f3('0x0')],'allowNull':![]},'ContactId':{'type':Sequelize[_0x4f59f3('0x2')],'unique':_0x4f59f3('0x4')},'ListId':{'type':Sequelize[_0x4f59f3('0x2')],'unique':_0x4f59f3('0x4')},'VoiceQueueId':{'type':Sequelize['INTEGER'],'unique':_0x4f59f3('0x4')}}; \ No newline at end of file diff --git a/server/api/cmHopperBlack/cmHopperBlack.controller.js b/server/api/cmHopperBlack/cmHopperBlack.controller.js index d045593..c7052f3 100644 --- a/server/api/cmHopperBlack/cmHopperBlack.controller.js +++ b/server/api/cmHopperBlack/cmHopperBlack.controller.js @@ -1 +1 @@ -const a142_0x21c0=['key','intersection','body','json','stack','filters','api','rawAttributes','send','CmHopperBlack','../../mysqldb','show','index','merge','lodash','where','then','model','include','attributes','filter','../../components/parsers/qs','name','offset','status','count','sort','sequelize','query','limit','pick','error','type','findAll','rows','undefined','params','update','fieldName','destroy','catch','map','describe','options','Content-Range','includeAll','fields','order','length','keys','findOne','sendStatus'];(function(_0x264084,_0x21c0f2){const _0x5c04aa=function(_0x5e2e6c){while(--_0x5e2e6c){_0x264084['push'](_0x264084['shift']());}};_0x5c04aa(++_0x21c0f2);}(a142_0x21c0,0x10c));const a142_0x5c04=function(_0x264084,_0x21c0f2){_0x264084=_0x264084-0x0;let _0x5c04aa=a142_0x21c0[_0x264084];return _0x5c04aa;};const _0x758333=a142_0x5c04;'use strict';const _=require(_0x758333('0x6')),qs=require(_0x758333('0xd')),logger=require('../../config/logger')(_0x758333('0x32')),db=require(_0x758333('0x2'))['db'],{Op}=require(_0x758333('0x13'));function respondWithResult(_0x5e2e6c,_0xafa85e){return _0xafa85e=_0xafa85e||0xc8,function(_0x18e71a){const _0x1de92f=a142_0x5c04;if(_0x18e71a)return _0x5e2e6c[_0x1de92f('0x10')](_0xafa85e)[_0x1de92f('0x2f')](_0x18e71a);};}function respondWithFilteredResult(_0x27d892,_0x40e374){return function(_0x5bf8fd){const _0x5948eb=a142_0x5c04;if(_0x5bf8fd){const _0x2b8e1e=_0x5bf8fd[_0x5948eb('0x11')],_0x2b31d3=_0x40e374['offset'];let _0x499bde=_0x40e374[_0x5948eb('0xf')]+_0x40e374[_0x5948eb('0x15')],_0x16b58d;return _0x499bde>=_0x2b8e1e?(_0x499bde=_0x2b8e1e,_0x16b58d=0xc8):_0x16b58d=0xce,_0x27d892[_0x5948eb('0x10')](_0x16b58d),_0x27d892['set'](_0x5948eb('0x24'),_0x2b31d3+'-'+_0x499bde+'/'+_0x2b8e1e)[_0x5948eb('0x2f')](_0x5bf8fd);}return null;};}function saveUpdates(_0x59d17e){return function(_0x3409f4){const _0x41c303=a142_0x5c04;if(_0x3409f4)return _0x3409f4[_0x41c303('0x1d')](_0x59d17e)[_0x41c303('0x8')](function(_0xecb717){return _0xecb717;});return null;};}function removeEntity(_0x52e707){return function(_0x2b0414){const _0x28eb30=a142_0x5c04;if(_0x2b0414)return _0x2b0414[_0x28eb30('0x1f')]()[_0x28eb30('0x8')](function(){const _0x190cdd=_0x28eb30;_0x52e707[_0x190cdd('0x10')](0xcc)['end']();});};}function handleEntityNotFound(_0x529915){return function(_0x24e072){const _0x569eda=a142_0x5c04;return!_0x24e072&&_0x529915[_0x569eda('0x2b')](0x194),_0x24e072;};}function handleError(_0x2a9018,_0x3ed5c5){return _0x3ed5c5=_0x3ed5c5||0x1f4,function(_0x244386){const _0x5078ea=a142_0x5c04;logger[_0x5078ea('0x17')](_0x244386[_0x5078ea('0x30')]),_0x244386[_0x5078ea('0xe')]&&delete _0x244386[_0x5078ea('0xe')],_0x2a9018[_0x5078ea('0x10')](_0x3ed5c5)[_0x5078ea('0x0')](_0x244386);};}exports[_0x758333('0x4')]=function(_0x563871,_0x1be3f9){const _0x25c485=_0x758333;let _0x988c61={};const _0x505076={},_0x3f0fd1={'count':0x0,'rows':[]},_0x2cfd58=_['map'](db[_0x25c485('0x1')][_0x25c485('0x33')],function(_0x5903bf){const _0x533866=_0x25c485;return{'name':_0x5903bf[_0x533866('0x1e')],'type':_0x5903bf[_0x533866('0x18')][_0x533866('0x2c')]};});_0x505076[_0x25c485('0x9')]=_[_0x25c485('0x21')](_0x2cfd58,_0x25c485('0xe')),_0x505076['query']=_[_0x25c485('0x29')](_0x563871[_0x25c485('0x14')]),_0x505076[_0x25c485('0x31')]=_['intersection'](_0x505076['model'],_0x505076[_0x25c485('0x14')]),_0x988c61['attributes']=_[_0x25c485('0x2d')](_0x505076[_0x25c485('0x9')],qs[_0x25c485('0x26')](_0x563871[_0x25c485('0x14')][_0x25c485('0x26')])),_0x988c61[_0x25c485('0xb')]=_0x988c61[_0x25c485('0xb')]['length']?_0x988c61[_0x25c485('0xb')]:_0x505076[_0x25c485('0x9')];typeof _0x563871[_0x25c485('0x14')]['nolimit']===_0x25c485('0x1b')&&(_0x988c61[_0x25c485('0x15')]=qs['limit'](_0x563871[_0x25c485('0x14')][_0x25c485('0x15')]),_0x988c61[_0x25c485('0xf')]=qs[_0x25c485('0xf')](_0x563871[_0x25c485('0x14')]['offset']));_0x988c61[_0x25c485('0x27')]=qs[_0x25c485('0x12')](_0x563871[_0x25c485('0x14')][_0x25c485('0x12')]),_0x988c61[_0x25c485('0x7')]=qs[_0x25c485('0x31')](_[_0x25c485('0x16')](_0x563871[_0x25c485('0x14')],_0x505076[_0x25c485('0x31')]),_0x2cfd58);_0x563871[_0x25c485('0x14')][_0x25c485('0xc')]&&(_0x988c61[_0x25c485('0x7')]=_[_0x25c485('0x5')](_0x988c61['where'],{[Op['or']]:_[_0x25c485('0x21')](_0x2cfd58,function(_0x48bc1e){const _0x17f76c=_0x25c485;if(_0x48bc1e[_0x17f76c('0x18')]!=='VIRTUAL'){const _0x3ff136={};return _0x3ff136[_0x48bc1e[_0x17f76c('0xe')]]={[Op['like']]:'%'+_0x563871[_0x17f76c('0x14')][_0x17f76c('0xc')]+'%'},_0x3ff136;}})}));_0x988c61=_[_0x25c485('0x5')]({},_0x988c61,_0x563871[_0x25c485('0x23')]);const _0x3c2da9={'where':_0x988c61[_0x25c485('0x7')]};return db[_0x25c485('0x1')][_0x25c485('0x11')](_0x3c2da9)['then'](function(_0x5f8a){const _0x3e6a6f=_0x25c485;return _0x3f0fd1['count']=_0x5f8a,_0x563871[_0x3e6a6f('0x14')][_0x3e6a6f('0x25')]&&(_0x988c61[_0x3e6a6f('0xa')]=[{'all':!![]}]),db[_0x3e6a6f('0x1')][_0x3e6a6f('0x19')](_0x988c61);})['then'](function(_0x50c073){const _0x325469=_0x25c485;return _0x3f0fd1[_0x325469('0x1a')]=_0x50c073,_0x3f0fd1;})['then'](respondWithFilteredResult(_0x1be3f9,_0x988c61))[_0x25c485('0x20')](handleError(_0x1be3f9,null));},exports[_0x758333('0x3')]=function(_0x51b718,_0x2c2f16){const _0x12c4ab=_0x758333;let _0x300d87={'raw':!![],'where':{'id':_0x51b718[_0x12c4ab('0x1c')]['id']}};const _0x2eed58={};return _0x2eed58[_0x12c4ab('0x9')]=_[_0x12c4ab('0x29')](db[_0x12c4ab('0x1')][_0x12c4ab('0x33')]),_0x2eed58[_0x12c4ab('0x14')]=_[_0x12c4ab('0x29')](_0x51b718['query']),_0x2eed58[_0x12c4ab('0x31')]=_[_0x12c4ab('0x2d')](_0x2eed58[_0x12c4ab('0x9')],_0x2eed58['query']),_0x300d87[_0x12c4ab('0xb')]=_[_0x12c4ab('0x2d')](_0x2eed58[_0x12c4ab('0x9')],qs[_0x12c4ab('0x26')](_0x51b718[_0x12c4ab('0x14')][_0x12c4ab('0x26')])),_0x300d87[_0x12c4ab('0xb')]=_0x300d87['attributes'][_0x12c4ab('0x28')]?_0x300d87['attributes']:_0x2eed58[_0x12c4ab('0x9')],_0x51b718[_0x12c4ab('0x14')][_0x12c4ab('0x25')]&&(_0x300d87[_0x12c4ab('0xa')]=[{'all':!![]}]),_0x300d87=_[_0x12c4ab('0x5')]({},_0x300d87,_0x51b718[_0x12c4ab('0x23')]),db[_0x12c4ab('0x1')][_0x12c4ab('0x2a')](_0x300d87)[_0x12c4ab('0x8')](handleEntityNotFound(_0x2c2f16,null))['then'](respondWithResult(_0x2c2f16,null))[_0x12c4ab('0x20')](handleError(_0x2c2f16,null));},exports['update']=function(_0x4c7884,_0x38776b){const _0x30d997=_0x758333;return _0x4c7884[_0x30d997('0x2e')]['id']&&delete _0x4c7884['body']['id'],db['CmHopperBlack'][_0x30d997('0x2a')]({'where':{'id':_0x4c7884[_0x30d997('0x1c')]['id']}})[_0x30d997('0x8')](handleEntityNotFound(_0x38776b,null))[_0x30d997('0x8')](saveUpdates(_0x4c7884[_0x30d997('0x2e')],null))['then'](respondWithResult(_0x38776b,null))[_0x30d997('0x20')](handleError(_0x38776b,null));},exports[_0x758333('0x1f')]=function(_0x5bcf2d,_0x323cb9){const _0x35c042=_0x758333;return db[_0x35c042('0x1')][_0x35c042('0x2a')]({'where':{'id':_0x5bcf2d[_0x35c042('0x1c')]['id']}})[_0x35c042('0x8')](handleEntityNotFound(_0x323cb9,null))[_0x35c042('0x8')](removeEntity(_0x323cb9,null))['catch'](handleError(_0x323cb9,null));},exports[_0x758333('0x22')]=function(_0x3f9a9a,_0x35a6ac){const _0x822a45=_0x758333;return db[_0x822a45('0x1')][_0x822a45('0x22')]()['then'](respondWithResult(_0x35a6ac,null))['catch'](handleError(_0x35a6ac,null));}; \ No newline at end of file +const a142_0x5d37=['status','body','filter','params','limit','includeAll','rows','fields','catch','findAll','nolimit','rawAttributes','update','set','VIRTUAL','length','sort','then','sequelize','CmHopperBlack','map','api','intersection','name','keys','where','error','json','stack','count','filters','model','include','attributes','like','fieldName','end','../../config/logger','describe','lodash','type','index','offset','merge','send','Content-Range','query','sendStatus'];(function(_0x432855,_0x5d37ba){const _0x2f6c1f=function(_0x29b146){while(--_0x29b146){_0x432855['push'](_0x432855['shift']());}};_0x2f6c1f(++_0x5d37ba);}(a142_0x5d37,0x13e));const a142_0x2f6c=function(_0x432855,_0x5d37ba){_0x432855=_0x432855-0x0;let _0x2f6c1f=a142_0x5d37[_0x432855];return _0x2f6c1f;};const _0x4b9b13=a142_0x2f6c;'use strict';const _=require(_0x4b9b13('0x9')),qs=require('../../components/parsers/qs'),logger=require(_0x4b9b13('0x7'))(_0x4b9b13('0x27')),db=require('../../mysqldb')['db'],{Op}=require(_0x4b9b13('0x24'));function respondWithResult(_0x29b146,_0x102987){return _0x102987=_0x102987||0xc8,function(_0x370007){if(_0x370007)return _0x29b146['status'](_0x102987)['json'](_0x370007);};}function respondWithFilteredResult(_0x56dc99,_0x40f0a2){return function(_0xaa25ec){const _0x46ac66=a142_0x2f6c;if(_0xaa25ec){const _0x67399f=_0xaa25ec['count'],_0x56cdf0=_0x40f0a2['offset'];let _0x4a644b=_0x40f0a2[_0x46ac66('0xc')]+_0x40f0a2[_0x46ac66('0x16')],_0x357190;return _0x4a644b>=_0x67399f?(_0x4a644b=_0x67399f,_0x357190=0xc8):_0x357190=0xce,_0x56dc99[_0x46ac66('0x12')](_0x357190),_0x56dc99[_0x46ac66('0x1f')](_0x46ac66('0xf'),_0x56cdf0+'-'+_0x4a644b+'/'+_0x67399f)[_0x46ac66('0x2d')](_0xaa25ec);}return null;};}function saveUpdates(_0x419a48){return function(_0x3f4324){const _0x4f912a=a142_0x2f6c;if(_0x3f4324)return _0x3f4324[_0x4f912a('0x1e')](_0x419a48)['then'](function(_0xdebcd0){return _0xdebcd0;});return null;};}function removeEntity(_0x482ddf){return function(_0x526abd){const _0x14da38=a142_0x2f6c;if(_0x526abd)return _0x526abd['destroy']()[_0x14da38('0x23')](function(){const _0x5348a6=_0x14da38;_0x482ddf[_0x5348a6('0x12')](0xcc)[_0x5348a6('0x6')]();});};}function handleEntityNotFound(_0x6bd089){return function(_0x478340){const _0x4206d8=a142_0x2f6c;return!_0x478340&&_0x6bd089[_0x4206d8('0x11')](0x194),_0x478340;};}function handleError(_0x3337b2,_0x518e56){return _0x518e56=_0x518e56||0x1f4,function(_0x5997fd){const _0xa3bdde=a142_0x2f6c;logger[_0xa3bdde('0x2c')](_0x5997fd[_0xa3bdde('0x2e')]),_0x5997fd[_0xa3bdde('0x29')]&&delete _0x5997fd[_0xa3bdde('0x29')],_0x3337b2[_0xa3bdde('0x12')](_0x518e56)[_0xa3bdde('0xe')](_0x5997fd);};}exports[_0x4b9b13('0xb')]=function(_0x59a6ec,_0x31d4f8){const _0x2dbafb=_0x4b9b13;let _0x217410={};const _0xc711cc={},_0x356eb4={'count':0x0,'rows':[]},_0x345f08=_[_0x2dbafb('0x26')](db['CmHopperBlack'][_0x2dbafb('0x1d')],function(_0x5447d9){const _0x3307d2=_0x2dbafb;return{'name':_0x5447d9[_0x3307d2('0x5')],'type':_0x5447d9[_0x3307d2('0xa')]['key']};});_0xc711cc['model']=_['map'](_0x345f08,'name'),_0xc711cc['query']=_[_0x2dbafb('0x2a')](_0x59a6ec['query']),_0xc711cc['filters']=_[_0x2dbafb('0x28')](_0xc711cc[_0x2dbafb('0x1')],_0xc711cc[_0x2dbafb('0x10')]),_0x217410[_0x2dbafb('0x3')]=_['intersection'](_0xc711cc['model'],qs[_0x2dbafb('0x19')](_0x59a6ec[_0x2dbafb('0x10')]['fields'])),_0x217410['attributes']=_0x217410[_0x2dbafb('0x3')][_0x2dbafb('0x21')]?_0x217410['attributes']:_0xc711cc[_0x2dbafb('0x1')];typeof _0x59a6ec[_0x2dbafb('0x10')][_0x2dbafb('0x1c')]==='undefined'&&(_0x217410[_0x2dbafb('0x16')]=qs[_0x2dbafb('0x16')](_0x59a6ec['query'][_0x2dbafb('0x16')]),_0x217410[_0x2dbafb('0xc')]=qs['offset'](_0x59a6ec['query'][_0x2dbafb('0xc')]));_0x217410['order']=qs[_0x2dbafb('0x22')](_0x59a6ec['query']['sort']),_0x217410[_0x2dbafb('0x2b')]=qs[_0x2dbafb('0x0')](_['pick'](_0x59a6ec['query'],_0xc711cc['filters']),_0x345f08);_0x59a6ec[_0x2dbafb('0x10')]['filter']&&(_0x217410[_0x2dbafb('0x2b')]=_[_0x2dbafb('0xd')](_0x217410[_0x2dbafb('0x2b')],{[Op['or']]:_[_0x2dbafb('0x26')](_0x345f08,function(_0x369616){const _0x2f9a1f=_0x2dbafb;if(_0x369616['type']!==_0x2f9a1f('0x20')){const _0x1fccee={};return _0x1fccee[_0x369616[_0x2f9a1f('0x29')]]={[Op[_0x2f9a1f('0x4')]]:'%'+_0x59a6ec[_0x2f9a1f('0x10')][_0x2f9a1f('0x14')]+'%'},_0x1fccee;}})}));_0x217410=_[_0x2dbafb('0xd')]({},_0x217410,_0x59a6ec['options']);const _0xafc840={'where':_0x217410['where']};return db[_0x2dbafb('0x25')]['count'](_0xafc840)[_0x2dbafb('0x23')](function(_0x40d74d){const _0x3fdb20=_0x2dbafb;return _0x356eb4[_0x3fdb20('0x2f')]=_0x40d74d,_0x59a6ec[_0x3fdb20('0x10')][_0x3fdb20('0x17')]&&(_0x217410[_0x3fdb20('0x2')]=[{'all':!![]}]),db[_0x3fdb20('0x25')][_0x3fdb20('0x1b')](_0x217410);})[_0x2dbafb('0x23')](function(_0x264aaa){const _0xb7fa7b=_0x2dbafb;return _0x356eb4[_0xb7fa7b('0x18')]=_0x264aaa,_0x356eb4;})[_0x2dbafb('0x23')](respondWithFilteredResult(_0x31d4f8,_0x217410))[_0x2dbafb('0x1a')](handleError(_0x31d4f8,null));},exports['show']=function(_0x497fc7,_0xc80f40){const _0x180a3b=_0x4b9b13;let _0x5679cb={'raw':!![],'where':{'id':_0x497fc7[_0x180a3b('0x15')]['id']}};const _0x5e7d32={};return _0x5e7d32['model']=_[_0x180a3b('0x2a')](db[_0x180a3b('0x25')][_0x180a3b('0x1d')]),_0x5e7d32['query']=_[_0x180a3b('0x2a')](_0x497fc7[_0x180a3b('0x10')]),_0x5e7d32['filters']=_[_0x180a3b('0x28')](_0x5e7d32['model'],_0x5e7d32[_0x180a3b('0x10')]),_0x5679cb['attributes']=_[_0x180a3b('0x28')](_0x5e7d32[_0x180a3b('0x1')],qs[_0x180a3b('0x19')](_0x497fc7[_0x180a3b('0x10')]['fields'])),_0x5679cb[_0x180a3b('0x3')]=_0x5679cb[_0x180a3b('0x3')][_0x180a3b('0x21')]?_0x5679cb['attributes']:_0x5e7d32[_0x180a3b('0x1')],_0x497fc7['query'][_0x180a3b('0x17')]&&(_0x5679cb[_0x180a3b('0x2')]=[{'all':!![]}]),_0x5679cb=_[_0x180a3b('0xd')]({},_0x5679cb,_0x497fc7['options']),db[_0x180a3b('0x25')]['findOne'](_0x5679cb)[_0x180a3b('0x23')](handleEntityNotFound(_0xc80f40,null))[_0x180a3b('0x23')](respondWithResult(_0xc80f40,null))['catch'](handleError(_0xc80f40,null));},exports[_0x4b9b13('0x1e')]=function(_0x5bf051,_0x297d44){const _0x5e072e=_0x4b9b13;return _0x5bf051[_0x5e072e('0x13')]['id']&&delete _0x5bf051['body']['id'],db[_0x5e072e('0x25')]['findOne']({'where':{'id':_0x5bf051[_0x5e072e('0x15')]['id']}})['then'](handleEntityNotFound(_0x297d44,null))[_0x5e072e('0x23')](saveUpdates(_0x5bf051[_0x5e072e('0x13')],null))[_0x5e072e('0x23')](respondWithResult(_0x297d44,null))[_0x5e072e('0x1a')](handleError(_0x297d44,null));},exports['destroy']=function(_0x13587c,_0x345f2e){const _0x1d0b86=_0x4b9b13;return db['CmHopperBlack']['findOne']({'where':{'id':_0x13587c[_0x1d0b86('0x15')]['id']}})['then'](handleEntityNotFound(_0x345f2e,null))['then'](removeEntity(_0x345f2e,null))[_0x1d0b86('0x1a')](handleError(_0x345f2e,null));},exports['describe']=function(_0x4ad231,_0xcce1ff){const _0x12f029=_0x4b9b13;return db[_0x12f029('0x25')][_0x12f029('0x8')]()[_0x12f029('0x23')](respondWithResult(_0xcce1ff,null))[_0x12f029('0x1a')](handleError(_0xcce1ff,null));}; \ No newline at end of file diff --git a/server/api/cmHopperBlack/cmHopperBlack.model.js b/server/api/cmHopperBlack/cmHopperBlack.model.js index 7603a40..6167d2c 100644 --- a/server/api/cmHopperBlack/cmHopperBlack.model.js +++ b/server/api/cmHopperBlack/cmHopperBlack.model.js @@ -1 +1 @@ -const a143_0x692c=['./cmHopperBlack.attributes','cm_hopper_black','define'];(function(_0x5b9d8c,_0x692cb2){const _0x21437c=function(_0x4bbbb9){while(--_0x4bbbb9){_0x5b9d8c['push'](_0x5b9d8c['shift']());}};_0x21437c(++_0x692cb2);}(a143_0x692c,0x11c));const a143_0x2143=function(_0x5b9d8c,_0x692cb2){_0x5b9d8c=_0x5b9d8c-0x0;let _0x21437c=a143_0x692c[_0x5b9d8c];return _0x21437c;};const _0x13afb3=a143_0x2143;'use strict';const attributes=require(_0x13afb3('0x1'));module['exports']=function(_0x4bbbb9){const _0x44dacf=_0x13afb3,_0x487c8b=_0x4bbbb9[_0x44dacf('0x0')]('CmHopperBlack',attributes,{'tableName':_0x44dacf('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x487c8b;}; \ No newline at end of file +const a143_0x1557=['./cmHopperBlack.attributes','cm_hopper_black','exports'];(function(_0x2c52a7,_0x15570a){const _0x10c4f2=function(_0x310e4c){while(--_0x310e4c){_0x2c52a7['push'](_0x2c52a7['shift']());}};_0x10c4f2(++_0x15570a);}(a143_0x1557,0x71));const a143_0x10c4=function(_0x2c52a7,_0x15570a){_0x2c52a7=_0x2c52a7-0x0;let _0x10c4f2=a143_0x1557[_0x2c52a7];return _0x10c4f2;};const _0x3cfdda=a143_0x10c4;'use strict';const attributes=require(_0x3cfdda('0x1'));module[_0x3cfdda('0x0')]=function(_0x310e4c){const _0x1fbba2=_0x3cfdda,_0x41548c=_0x310e4c['define']('CmHopperBlack',attributes,{'tableName':_0x1fbba2('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x41548c;}; \ No newline at end of file diff --git a/server/api/cmHopperBlack/cmHopperBlack.rpc.js b/server/api/cmHopperBlack/cmHopperBlack.rpc.js index dd8d749..c36d3ba 100644 --- a/server/api/cmHopperBlack/cmHopperBlack.rpc.js +++ b/server/api/cmHopperBlack/cmHopperBlack.rpc.js @@ -1 +1 @@ -const a144_0x1530=['rpc','UpdateCmHopperBlack','message','options','lodash','findAll','error','where','then','stringify','../../config/logger','model','catch','CmHopperBlack','map','limit','../../mysqldb','debug','GetCmHopperBlack','raw','attributes','info','update','include','DestroyCmHopperBlack','destroy'];(function(_0x2c2388,_0x153003){const _0x5cd002=function(_0x21c680){while(--_0x21c680){_0x2c2388['push'](_0x2c2388['shift']());}};_0x5cd002(++_0x153003);}(a144_0x1530,0x1e3));const a144_0x5cd0=function(_0x2c2388,_0x153003){_0x2c2388=_0x2c2388-0x0;let _0x5cd002=a144_0x1530[_0x2c2388];return _0x5cd002;};const _0xf925d9=a144_0x5cd0;'use strict';const _=require(_0xf925d9('0xf')),db=require(_0xf925d9('0x1'))['db'],logger=require(_0xf925d9('0x15'))(_0xf925d9('0xb'));exports[_0xf925d9('0x3')]=function(_0x21c680){const _0xd20b3=this;return new Promise(function(_0x2ced31,_0xcd28de){const _0x44d228=a144_0x5cd0;return db[_0x44d228('0x18')][_0x44d228('0x10')]({'raw':_0x21c680[_0x44d228('0xe')]?_0x21c680[_0x44d228('0xe')][_0x44d228('0x4')]===undefined?!![]:![]:!![],'where':_0x21c680[_0x44d228('0xe')]?_0x21c680[_0x44d228('0xe')][_0x44d228('0x12')]||null:null,'attributes':_0x21c680[_0x44d228('0xe')]?_0x21c680[_0x44d228('0xe')]['attributes']||null:null,'limit':_0x21c680[_0x44d228('0xe')]?_0x21c680['options'][_0x44d228('0x0')]||null:null,'include':_0x21c680['options']?_0x21c680['options']['include']?_[_0x44d228('0x19')](_0x21c680['options'][_0x44d228('0x8')],function(_0x440374){const _0x494522=_0x44d228;return{'model':db[_0x440374[_0x494522('0x16')]],'as':_0x440374['as'],'attributes':_0x440374[_0x494522('0x5')],'include':_0x440374['include']?_['map'](_0x440374[_0x494522('0x8')],function(_0x3003e0){const _0xb49199=_0x494522;return{'model':db[_0x3003e0[_0xb49199('0x16')]],'as':_0x3003e0['as'],'attributes':_0x3003e0[_0xb49199('0x5')],'include':_0x3003e0['include']?_[_0xb49199('0x19')](_0x3003e0[_0xb49199('0x8')],function(_0x1ced43){const _0x584057=_0xb49199;return{'model':db[_0x1ced43[_0x584057('0x16')]],'as':_0x1ced43['as'],'attributes':_0x1ced43[_0x584057('0x5')]};}):[]};}):[]};}):[]:[]})[_0x44d228('0x13')](function(_0x4109cc){const _0x4ffaf5=_0x44d228;logger[_0x4ffaf5('0x6')](_0x4ffaf5('0x3'),_0x21c680),logger[_0x4ffaf5('0x2')]('GetCmHopperBlack',_0x21c680,JSON[_0x4ffaf5('0x14')](_0x4109cc)),_0x2ced31(_0x4109cc);})['catch'](function(_0x178c81){const _0x1ed0e1=_0x44d228;logger[_0x1ed0e1('0x11')](_0x1ed0e1('0x3'),_0x178c81[_0x1ed0e1('0xd')],_0x21c680),_0xcd28de(_0xd20b3[_0x1ed0e1('0x11')](0x1f4,_0x178c81[_0x1ed0e1('0xd')]));});});},exports[_0xf925d9('0xc')]=function(_0x54a957){const _0x242ddd=this;return new Promise(function(_0x4e49d2,_0x30dcff){const _0x2d3b24=a144_0x5cd0;return db[_0x2d3b24('0x18')][_0x2d3b24('0x7')](_0x54a957['body'],{'raw':_0x54a957[_0x2d3b24('0xe')]?_0x54a957['options']['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x54a957[_0x2d3b24('0xe')]?_0x54a957['options'][_0x2d3b24('0x12')]||null:null,'attributes':_0x54a957[_0x2d3b24('0xe')]?_0x54a957['options'][_0x2d3b24('0x5')]||null:null,'limit':_0x54a957[_0x2d3b24('0xe')]?_0x54a957[_0x2d3b24('0xe')]['limit']||null:null})[_0x2d3b24('0x13')](function(_0xf0279c){const _0x3ae5ca=_0x2d3b24;logger[_0x3ae5ca('0x6')](_0x3ae5ca('0xc'),_0x54a957),logger['debug'](_0x3ae5ca('0xc'),_0x54a957,JSON[_0x3ae5ca('0x14')](_0xf0279c)),_0x4e49d2(_0xf0279c);})['catch'](function(_0x3d39ec){const _0x13fdf2=_0x2d3b24;logger[_0x13fdf2('0x11')]('UpdateCmHopperBlack',_0x3d39ec[_0x13fdf2('0xd')],_0x54a957),_0x30dcff(_0x242ddd['error'](0x1f4,_0x3d39ec[_0x13fdf2('0xd')]));});});},exports['DestroyCmHopperBlack']=function(_0x2acfd4){const _0x391167=this;return new Promise(function(_0x59e693,_0x1852bd){const _0x4b25b5=a144_0x5cd0;return db[_0x4b25b5('0x18')][_0x4b25b5('0xa')]({'where':_0x2acfd4[_0x4b25b5('0xe')]?_0x2acfd4[_0x4b25b5('0xe')][_0x4b25b5('0x12')]||null:null})[_0x4b25b5('0x13')](function(_0x56fc77){const _0x3b0808=_0x4b25b5;logger[_0x3b0808('0x6')](_0x3b0808('0x9'),_0x2acfd4),logger[_0x3b0808('0x2')](_0x3b0808('0x9'),_0x2acfd4,JSON[_0x3b0808('0x14')](_0x56fc77)),_0x59e693(_0x56fc77);})[_0x4b25b5('0x17')](function(_0x42a0e9){const _0x462f56=_0x4b25b5;logger['error']('DestroyCmHopperBlack',_0x42a0e9[_0x462f56('0xd')],_0x2acfd4),_0x1852bd(_0x391167[_0x462f56('0x11')](0x1f4,_0x42a0e9['message']));});});}; \ No newline at end of file +const a144_0x50ec=['options','raw','where','update','stringify','attributes','../../config/logger','lodash','catch','UpdateCmHopperBlack','limit','body','destroy','map','GetCmHopperBlack','message','error','then','model','rpc','debug','DestroyCmHopperBlack','CmHopperBlack','include','../../mysqldb','findAll'];(function(_0xb98b2a,_0x50ecb6){const _0x56f5a8=function(_0x13ef95){while(--_0x13ef95){_0xb98b2a['push'](_0xb98b2a['shift']());}};_0x56f5a8(++_0x50ecb6);}(a144_0x50ec,0x16c));const a144_0x56f5=function(_0xb98b2a,_0x50ecb6){_0xb98b2a=_0xb98b2a-0x0;let _0x56f5a8=a144_0x50ec[_0xb98b2a];return _0x56f5a8;};const _0x32d5a0=a144_0x56f5;'use strict';const _=require(_0x32d5a0('0x7')),db=require(_0x32d5a0('0x18'))['db'],logger=require(_0x32d5a0('0x6'))(_0x32d5a0('0x13'));exports['GetCmHopperBlack']=function(_0x13ef95){const _0x287185=this;return new Promise(function(_0x1e4a92,_0x6e007a){const _0x438ac9=a144_0x56f5;return db['CmHopperBlack'][_0x438ac9('0x19')]({'raw':_0x13ef95[_0x438ac9('0x0')]?_0x13ef95[_0x438ac9('0x0')][_0x438ac9('0x1')]===undefined?!![]:![]:!![],'where':_0x13ef95[_0x438ac9('0x0')]?_0x13ef95['options'][_0x438ac9('0x2')]||null:null,'attributes':_0x13ef95['options']?_0x13ef95[_0x438ac9('0x0')]['attributes']||null:null,'limit':_0x13ef95['options']?_0x13ef95[_0x438ac9('0x0')][_0x438ac9('0xa')]||null:null,'include':_0x13ef95['options']?_0x13ef95[_0x438ac9('0x0')][_0x438ac9('0x17')]?_[_0x438ac9('0xd')](_0x13ef95[_0x438ac9('0x0')][_0x438ac9('0x17')],function(_0x257642){const _0x2e7293=_0x438ac9;return{'model':db[_0x257642[_0x2e7293('0x12')]],'as':_0x257642['as'],'attributes':_0x257642[_0x2e7293('0x5')],'include':_0x257642[_0x2e7293('0x17')]?_[_0x2e7293('0xd')](_0x257642['include'],function(_0xda2bb9){const _0xff5e06=_0x2e7293;return{'model':db[_0xda2bb9[_0xff5e06('0x12')]],'as':_0xda2bb9['as'],'attributes':_0xda2bb9[_0xff5e06('0x5')],'include':_0xda2bb9[_0xff5e06('0x17')]?_['map'](_0xda2bb9[_0xff5e06('0x17')],function(_0x23af9a){const _0x4973bd=_0xff5e06;return{'model':db[_0x23af9a[_0x4973bd('0x12')]],'as':_0x23af9a['as'],'attributes':_0x23af9a['attributes']};}):[]};}):[]};}):[]:[]})[_0x438ac9('0x11')](function(_0x420481){const _0x1b5b2b=_0x438ac9;logger['info'](_0x1b5b2b('0xe'),_0x13ef95),logger[_0x1b5b2b('0x14')](_0x1b5b2b('0xe'),_0x13ef95,JSON[_0x1b5b2b('0x4')](_0x420481)),_0x1e4a92(_0x420481);})[_0x438ac9('0x8')](function(_0x457c7d){const _0x4d9644=_0x438ac9;logger['error'](_0x4d9644('0xe'),_0x457c7d['message'],_0x13ef95),_0x6e007a(_0x287185[_0x4d9644('0x10')](0x1f4,_0x457c7d[_0x4d9644('0xf')]));});});},exports[_0x32d5a0('0x9')]=function(_0x383da0){const _0x46f21a=this;return new Promise(function(_0x91c26e,_0x522918){const _0xc11dc7=a144_0x56f5;return db[_0xc11dc7('0x16')][_0xc11dc7('0x3')](_0x383da0[_0xc11dc7('0xb')],{'raw':_0x383da0['options']?_0x383da0[_0xc11dc7('0x0')][_0xc11dc7('0x1')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x383da0['options']?_0x383da0[_0xc11dc7('0x0')][_0xc11dc7('0x2')]||null:null,'attributes':_0x383da0['options']?_0x383da0[_0xc11dc7('0x0')]['attributes']||null:null,'limit':_0x383da0[_0xc11dc7('0x0')]?_0x383da0[_0xc11dc7('0x0')][_0xc11dc7('0xa')]||null:null})[_0xc11dc7('0x11')](function(_0x4595f6){const _0x1ad642=_0xc11dc7;logger['info'](_0x1ad642('0x9'),_0x383da0),logger[_0x1ad642('0x14')]('UpdateCmHopperBlack',_0x383da0,JSON[_0x1ad642('0x4')](_0x4595f6)),_0x91c26e(_0x4595f6);})[_0xc11dc7('0x8')](function(_0x1f8431){const _0x264c22=_0xc11dc7;logger['error'](_0x264c22('0x9'),_0x1f8431[_0x264c22('0xf')],_0x383da0),_0x522918(_0x46f21a[_0x264c22('0x10')](0x1f4,_0x1f8431['message']));});});},exports[_0x32d5a0('0x15')]=function(_0x40df56){const _0x276a75=this;return new Promise(function(_0x164141,_0x15b682){const _0x2c0e6b=a144_0x56f5;return db[_0x2c0e6b('0x16')][_0x2c0e6b('0xc')]({'where':_0x40df56[_0x2c0e6b('0x0')]?_0x40df56[_0x2c0e6b('0x0')][_0x2c0e6b('0x2')]||null:null})['then'](function(_0xaae0c){const _0x3195e1=_0x2c0e6b;logger['info']('DestroyCmHopperBlack',_0x40df56),logger[_0x3195e1('0x14')](_0x3195e1('0x15'),_0x40df56,JSON[_0x3195e1('0x4')](_0xaae0c)),_0x164141(_0xaae0c);})[_0x2c0e6b('0x8')](function(_0xafa40a){const _0x2ce43a=_0x2c0e6b;logger[_0x2ce43a('0x10')](_0x2ce43a('0x15'),_0xafa40a[_0x2ce43a('0xf')],_0x40df56),_0x15b682(_0x276a75[_0x2ce43a('0x10')](0x1f4,_0xafa40a[_0x2ce43a('0xf')]));});});}; \ No newline at end of file diff --git a/server/api/cmHopperBlack/index.js b/server/api/cmHopperBlack/index.js index b743eb6..50daf72 100644 --- a/server/api/cmHopperBlack/index.js +++ b/server/api/cmHopperBlack/index.js @@ -1 +1 @@ -const a145_0x438f=['./cmHopperBlack.controller','destroy','index','exports','put','describe','isAuthenticated','get','/:id','Router','../../components/auth/service','express'];(function(_0x269e08,_0x438f21){const _0x5bc0a3=function(_0x22a8ac){while(--_0x22a8ac){_0x269e08['push'](_0x269e08['shift']());}};_0x5bc0a3(++_0x438f21);}(a145_0x438f,0x192));const a145_0x5bc0=function(_0x269e08,_0x438f21){_0x269e08=_0x269e08-0x0;let _0x5bc0a3=a145_0x438f[_0x269e08];return _0x5bc0a3;};const _0xa31d57=a145_0x5bc0;'use strict';const express=require(_0xa31d57('0x5')),router=express[_0xa31d57('0x3')](),auth=require(_0xa31d57('0x4')),controller=require(_0xa31d57('0x6'));router[_0xa31d57('0x1')]('/',auth[_0xa31d57('0x0')](),controller[_0xa31d57('0x8')]),router[_0xa31d57('0x1')]('/describe',auth[_0xa31d57('0x0')](),controller[_0xa31d57('0xb')]),router['get']('/:id',auth[_0xa31d57('0x0')](),controller['show']),router[_0xa31d57('0xa')](_0xa31d57('0x2'),auth[_0xa31d57('0x0')](),controller['update']),router['delete'](_0xa31d57('0x2'),auth[_0xa31d57('0x0')](),controller[_0xa31d57('0x7')]),module[_0xa31d57('0x9')]=router; \ No newline at end of file +const a145_0x3b74=['show','destroy','./cmHopperBlack.controller','isAuthenticated','Router','/:id','get','update','/describe'];(function(_0x362e85,_0x3b74ab){const _0x2b3b2e=function(_0x5cbbbf){while(--_0x5cbbbf){_0x362e85['push'](_0x362e85['shift']());}};_0x2b3b2e(++_0x3b74ab);}(a145_0x3b74,0x110));const a145_0x2b3b=function(_0x362e85,_0x3b74ab){_0x362e85=_0x362e85-0x0;let _0x2b3b2e=a145_0x3b74[_0x362e85];return _0x2b3b2e;};const _0x475a15=a145_0x2b3b;'use strict';const express=require('express'),router=express[_0x475a15('0x2')](),auth=require('../../components/auth/service'),controller=require(_0x475a15('0x0'));router[_0x475a15('0x4')]('/',auth[_0x475a15('0x1')](),controller['index']),router[_0x475a15('0x4')](_0x475a15('0x6'),auth[_0x475a15('0x1')](),controller['describe']),router[_0x475a15('0x4')](_0x475a15('0x3'),auth[_0x475a15('0x1')](),controller[_0x475a15('0x7')]),router['put']('/:id',auth[_0x475a15('0x1')](),controller[_0x475a15('0x5')]),router['delete']('/:id',auth['isAuthenticated'](),controller[_0x475a15('0x8')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/cmHopperFinal/cmHopperFinal.attributes.js b/server/api/cmHopperFinal/cmHopperFinal.attributes.js index 678b5f1..2b80343 100644 --- a/server/api/cmHopperFinal/cmHopperFinal.attributes.js +++ b/server/api/cmHopperFinal/cmHopperFinal.attributes.js @@ -1 +1 @@ -const a146_0x565c=['STRING','sequelize','endtime','exports','setDataValue','INTEGER','BOOLEAN','getDataValue','DATE','seconds','diff','moment','dispositionat'];(function(_0x1a3361,_0x565c28){const _0x11632d=function(_0x18e6ba){while(--_0x18e6ba){_0x1a3361['push'](_0x1a3361['shift']());}};_0x11632d(++_0x565c28);}(a146_0x565c,0x1f1));const a146_0x1163=function(_0x1a3361,_0x565c28){_0x1a3361=_0x1a3361-0x0;let _0x11632d=a146_0x565c[_0x1a3361];return _0x11632d;};const _0x48a218=a146_0x1163;'use strict';const Sequelize=require(_0x48a218('0xb')),moment=require(_0x48a218('0x8'));module[_0x48a218('0x0')]={'state':{'type':Sequelize[_0x48a218('0x2')](0x2)},'statedesc':{'type':Sequelize[_0x48a218('0xa')]},'scheduledat':{'type':Sequelize[_0x48a218('0x5')]},'countbusyretry':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'countcongestionretry':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'countnoanswerretry':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'countglobal':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'uniqueid':{'type':Sequelize[_0x48a218('0xa')]},'originatecalleridnum':{'type':Sequelize['STRING']},'originatecalleridname':{'type':Sequelize[_0x48a218('0xa')]},'calleridnum':{'type':Sequelize[_0x48a218('0xa')]},'calleridname':{'type':Sequelize[_0x48a218('0xa')]},'starttime':{'type':Sequelize['DATE']},'responsetime':{'type':Sequelize['DATE']},'answertime':{'type':Sequelize[_0x48a218('0x5')]},'droptime':{'type':Sequelize[_0x48a218('0x5')]},'endtime':{'type':Sequelize[_0x48a218('0x5')]},'ringtime':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'holdtime':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'talktime':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'followuptime':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'dropreason':{'type':Sequelize['STRING']},'campaign':{'type':Sequelize[_0x48a218('0xa')]},'campaigntype':{'type':Sequelize[_0x48a218('0xa')]},'membername':{'type':Sequelize['STRING']},'reason':{'type':Sequelize[_0x48a218('0xa')]},'disposition':{'type':Sequelize[_0x48a218('0xa')]},'secondDisposition':{'type':Sequelize[_0x48a218('0xa')]},'thirdDisposition':{'type':Sequelize[_0x48a218('0xa')]},'dispositionat':{'type':Sequelize[_0x48a218('0x5')],'set':function(_0x18e6ba){const _0x12eaa0=_0x48a218,_0x474a15=this[_0x12eaa0('0x4')](_0x12eaa0('0xc'));return _0x474a15&&_0x18e6ba&&this[_0x12eaa0('0x1')]('followuptime',moment(_0x18e6ba)[_0x12eaa0('0x7')](moment(_0x474a15),_0x12eaa0('0x6'))),this[_0x12eaa0('0x1')](_0x12eaa0('0x9'),_0x18e6ba);}},'amd':{'type':Sequelize[_0x48a218('0x3')],'defaultValue':![]},'fax':{'type':Sequelize[_0x48a218('0x3')],'defaultValue':![]},'blacklist':{'type':Sequelize[_0x48a218('0x3')],'defaultValue':![]},'rescheduled':{'type':Sequelize[_0x48a218('0x3')],'defaultValue':![]},'rescheduledat':{'type':Sequelize[_0x48a218('0x5')]},'callback':{'type':Sequelize[_0x48a218('0x3')],'defaultValue':![]},'callbackuniqueid':{'type':Sequelize[_0x48a218('0xa')],'defaultValue':null},'callbackat':{'type':Sequelize[_0x48a218('0x5')]},'deleted':{'type':Sequelize[_0x48a218('0xa')],'defaultValue':null},'deletedat':{'type':Sequelize[_0x48a218('0x5')]},'recallme':{'type':Sequelize[_0x48a218('0x3')],'defaultValue':![]},'agiafterat':{'type':Sequelize['DATE']},'countnosuchnumberretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countdropretry':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'countabandonedretry':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'countmachineretry':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0},'countagentrejectretry':{'type':Sequelize[_0x48a218('0x2')],'defaultValue':0x0}}; \ No newline at end of file +const a146_0x7a43=['exports','diff','dispositionat','endtime','followuptime','moment','getDataValue','STRING','seconds','BOOLEAN','setDataValue','INTEGER','DATE','sequelize'];(function(_0x15a20d,_0x7a4322){const _0x244530=function(_0xda48d0){while(--_0xda48d0){_0x15a20d['push'](_0x15a20d['shift']());}};_0x244530(++_0x7a4322);}(a146_0x7a43,0x80));const a146_0x2445=function(_0x15a20d,_0x7a4322){_0x15a20d=_0x15a20d-0x0;let _0x244530=a146_0x7a43[_0x15a20d];return _0x244530;};const _0x59fd4b=a146_0x2445;'use strict';const Sequelize=require(_0x59fd4b('0xb')),moment=require(_0x59fd4b('0x3'));module[_0x59fd4b('0xc')]={'state':{'type':Sequelize[_0x59fd4b('0x9')](0x2)},'statedesc':{'type':Sequelize[_0x59fd4b('0x5')]},'scheduledat':{'type':Sequelize[_0x59fd4b('0xa')]},'countbusyretry':{'type':Sequelize[_0x59fd4b('0x9')],'defaultValue':0x0},'countcongestionretry':{'type':Sequelize[_0x59fd4b('0x9')],'defaultValue':0x0},'countnoanswerretry':{'type':Sequelize[_0x59fd4b('0x9')],'defaultValue':0x0},'countglobal':{'type':Sequelize[_0x59fd4b('0x9')],'defaultValue':0x0},'uniqueid':{'type':Sequelize[_0x59fd4b('0x5')]},'originatecalleridnum':{'type':Sequelize[_0x59fd4b('0x5')]},'originatecalleridname':{'type':Sequelize[_0x59fd4b('0x5')]},'calleridnum':{'type':Sequelize[_0x59fd4b('0x5')]},'calleridname':{'type':Sequelize[_0x59fd4b('0x5')]},'starttime':{'type':Sequelize['DATE']},'responsetime':{'type':Sequelize[_0x59fd4b('0xa')]},'answertime':{'type':Sequelize[_0x59fd4b('0xa')]},'droptime':{'type':Sequelize[_0x59fd4b('0xa')]},'endtime':{'type':Sequelize[_0x59fd4b('0xa')]},'ringtime':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'holdtime':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'talktime':{'type':Sequelize[_0x59fd4b('0x9')],'defaultValue':0x0},'followuptime':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'dropreason':{'type':Sequelize[_0x59fd4b('0x5')]},'campaign':{'type':Sequelize['STRING']},'campaigntype':{'type':Sequelize[_0x59fd4b('0x5')]},'membername':{'type':Sequelize[_0x59fd4b('0x5')]},'reason':{'type':Sequelize['STRING']},'disposition':{'type':Sequelize['STRING']},'secondDisposition':{'type':Sequelize[_0x59fd4b('0x5')]},'thirdDisposition':{'type':Sequelize[_0x59fd4b('0x5')]},'dispositionat':{'type':Sequelize[_0x59fd4b('0xa')],'set':function(_0xda48d0){const _0x434a61=_0x59fd4b,_0x9520e8=this[_0x434a61('0x4')](_0x434a61('0x1'));return _0x9520e8&&_0xda48d0&&this[_0x434a61('0x8')](_0x434a61('0x2'),moment(_0xda48d0)[_0x434a61('0xd')](moment(_0x9520e8),_0x434a61('0x6'))),this[_0x434a61('0x8')](_0x434a61('0x0'),_0xda48d0);}},'amd':{'type':Sequelize[_0x59fd4b('0x7')],'defaultValue':![]},'fax':{'type':Sequelize[_0x59fd4b('0x7')],'defaultValue':![]},'blacklist':{'type':Sequelize[_0x59fd4b('0x7')],'defaultValue':![]},'rescheduled':{'type':Sequelize[_0x59fd4b('0x7')],'defaultValue':![]},'rescheduledat':{'type':Sequelize[_0x59fd4b('0xa')]},'callback':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'callbackuniqueid':{'type':Sequelize[_0x59fd4b('0x5')],'defaultValue':null},'callbackat':{'type':Sequelize[_0x59fd4b('0xa')]},'deleted':{'type':Sequelize[_0x59fd4b('0x5')],'defaultValue':null},'deletedat':{'type':Sequelize[_0x59fd4b('0xa')]},'recallme':{'type':Sequelize[_0x59fd4b('0x7')],'defaultValue':![]},'agiafterat':{'type':Sequelize[_0x59fd4b('0xa')]},'countnosuchnumberretry':{'type':Sequelize[_0x59fd4b('0x9')],'defaultValue':0x0},'countdropretry':{'type':Sequelize[_0x59fd4b('0x9')],'defaultValue':0x0},'countabandonedretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countmachineretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countagentrejectretry':{'type':Sequelize[_0x59fd4b('0x9')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/cmHopperFinal/cmHopperFinal.controller.js b/server/api/cmHopperFinal/cmHopperFinal.controller.js index ce54760..1bbb7fd 100644 --- a/server/api/cmHopperFinal/cmHopperFinal.controller.js +++ b/server/api/cmHopperFinal/cmHopperFinal.controller.js @@ -1 +1 @@ -const a147_0x282c=['catch','attributes','intersection','countContactsIvrCampaignHopperFinal','length','state\x20=\x204','api','from','CmHopperFinal','ANY_VALUE(VoiceQueueId)','undefined','offset','fromQuery','order','update','busyContacts','Content-Range','VoiceQueueId','findOne','sequelize','type','sort','calleridnum','CampaignId\x20=\x20?','state\x20=\x20?','stack','CampaignId','abandonedContacts','into','noAnswerContacts','ListId','filter','VoiceQueueId\x20=\x20?','body','select','then','moveContactsIvrCampaignHopperFinal','merge','pick','ContactId','`state`\x20=\x2019,\x201,\x20null','describe','dropContacts','phone','group','nolimit','VoiceQueue','congestionContacts','includeAll','findAll','fieldName','send','VIRTUAL','`state`\x20=\x2022,\x201,\x20null','status','include','options','limit','name','calleridnum\x20IS\x20NOT\x20NULL','answeringMachine','fields','map','ANY_VALUE(CampaignId)','`state`\x20=\x2011\x20,\x201,\x20null','model','createdAt','NOW()','`state`\x20=\x208,\x201,\x20null','rows','Campaign','squel','ANY_VALUE(ContactId)','query','insert','where','toString','`state`\x20=\x205,\x201,\x20null','noSuchContacts','countContactsQueueCampaignHopperFinal','updatedAt','COUNT','like','count','calleridnum\x20NOT\x20IN\x20(?)','error','index','reCallContacts','cm_hopper_final','`state`\x20=\x2010\x20,\x201,\x20null','json','uniqueid','rawAttributes','`state`\x20=\x200,\x201,\x20null','cm_hopper','field','state','scheduledAt','params','ANY_VALUE(ListId)','key','`state`\x20=\x203,\x201,\x20null','keys','filters'];(function(_0x2ca019,_0x282c45){const _0x5ded1a=function(_0x506fbd){while(--_0x506fbd){_0x2ca019['push'](_0x2ca019['shift']());}};_0x5ded1a(++_0x282c45);}(a147_0x282c,0x15a));const a147_0x5ded=function(_0x2ca019,_0x282c45){_0x2ca019=_0x2ca019-0x0;let _0x5ded1a=a147_0x282c[_0x2ca019];return _0x5ded1a;};const _0x4301f5=a147_0x5ded;'use strict';const _=require('lodash'),squel=require(_0x4301f5('0x25')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x4301f5('0x4c')),db=require('../../mysqldb')['db'],{Op,fn,literal}=require('sequelize');function respondWithResult(_0x506fbd,_0x55bf10){return _0x55bf10=_0x55bf10||0xc8,function(_0x443b42){const _0x5223de=a147_0x5ded;if(_0x443b42)return _0x506fbd[_0x5223de('0x14')](_0x55bf10)[_0x5223de('0x38')](_0x443b42);};}function respondWithFilteredResult(_0x2b2aea,_0x287182){return function(_0x34fef5){const _0x1d0d6c=a147_0x5ded;if(_0x34fef5){const _0x81f8ee=_0x34fef5[_0x1d0d6c('0x31')],_0x5d705b=_0x287182['offset'];let _0x5337f4=_0x287182[_0x1d0d6c('0x51')]+_0x287182[_0x1d0d6c('0x17')],_0x406ec9;return _0x5337f4>=_0x81f8ee?(_0x5337f4=_0x81f8ee,_0x406ec9=0xc8):_0x406ec9=0xce,_0x2b2aea['status'](_0x406ec9),_0x2b2aea['set'](_0x1d0d6c('0x56'),_0x5d705b+'-'+_0x5337f4+'/'+_0x81f8ee)[_0x1d0d6c('0x38')](_0x34fef5);}return null;};}function saveUpdates(_0x57451c){return function(_0x4cd9d7){const _0xc7c419=a147_0x5ded;if(_0x4cd9d7)return _0x4cd9d7[_0xc7c419('0x54')](_0x57451c)[_0xc7c419('0x1')](function(_0x576cd9){return _0x576cd9;});return null;};}function handleEntityNotFound(_0x49cde6){return function(_0x4fd225){return!_0x4fd225&&_0x49cde6['sendStatus'](0x194),_0x4fd225;};}function handleError(_0x2380d0,_0x351653){return _0x351653=_0x351653||0x1f4,function(_0x311b86){const _0x2bea3b=a147_0x5ded;logger[_0x2bea3b('0x33')](_0x311b86[_0x2bea3b('0x5f')]),_0x311b86['name']&&delete _0x311b86[_0x2bea3b('0x18')],_0x2380d0[_0x2bea3b('0x14')](_0x351653)[_0x2bea3b('0x11')](_0x311b86);};}exports[_0x4301f5('0x34')]=function(_0x8411e6,_0x1ecd30){const _0x2f43a3=_0x4301f5;let _0x2183c6={};const _0x194542={},_0x2e3e3b={'count':0x0,'rows':[]},_0x370007=_['map'](db[_0x2f43a3('0x4e')][_0x2f43a3('0x3a')],function(_0x5a1e85){const _0xbb5731=_0x2f43a3;return{'name':_0x5a1e85[_0xbb5731('0x10')],'type':_0x5a1e85[_0xbb5731('0x5a')][_0xbb5731('0x42')]};});_0x194542[_0x2f43a3('0x1f')]=_[_0x2f43a3('0x1c')](_0x370007,_0x2f43a3('0x18')),_0x194542[_0x2f43a3('0x27')]=_[_0x2f43a3('0x44')](_0x8411e6[_0x2f43a3('0x27')]),_0x194542[_0x2f43a3('0x45')]=_[_0x2f43a3('0x48')](_0x194542[_0x2f43a3('0x1f')],_0x194542[_0x2f43a3('0x27')]),_0x2183c6[_0x2f43a3('0x47')]=_[_0x2f43a3('0x48')](_0x194542[_0x2f43a3('0x1f')],qs[_0x2f43a3('0x1b')](_0x8411e6[_0x2f43a3('0x27')][_0x2f43a3('0x1b')])),_0x2183c6[_0x2f43a3('0x47')]=_0x2183c6[_0x2f43a3('0x47')][_0x2f43a3('0x4a')]?_0x2183c6[_0x2f43a3('0x47')]:_0x194542['model'];typeof _0x8411e6[_0x2f43a3('0x27')][_0x2f43a3('0xb')]===_0x2f43a3('0x50')&&(_0x2183c6[_0x2f43a3('0x17')]=qs['limit'](_0x8411e6[_0x2f43a3('0x27')][_0x2f43a3('0x17')]),_0x2183c6[_0x2f43a3('0x51')]=qs['offset'](_0x8411e6[_0x2f43a3('0x27')]['offset']));_0x2183c6[_0x2f43a3('0x53')]=qs[_0x2f43a3('0x5b')](_0x8411e6[_0x2f43a3('0x27')][_0x2f43a3('0x5b')]),_0x2183c6[_0x2f43a3('0x29')]=qs[_0x2f43a3('0x45')](_[_0x2f43a3('0x4')](_0x8411e6[_0x2f43a3('0x27')],_0x194542[_0x2f43a3('0x45')]),_0x370007);_0x8411e6['query'][_0x2f43a3('0x65')]&&(_0x2183c6[_0x2f43a3('0x29')]=_[_0x2f43a3('0x3')](_0x2183c6['where'],{[Op['or']]:_[_0x2f43a3('0x1c')](_0x370007,function(_0x38567d){const _0x395991=_0x2f43a3;if(_0x38567d[_0x395991('0x5a')]!==_0x395991('0x12')){const _0xf665bb={};return _0xf665bb[_0x38567d[_0x395991('0x18')]]={[Op[_0x395991('0x30')]]:'%'+_0x8411e6[_0x395991('0x27')][_0x395991('0x65')]+'%'},_0xf665bb;}})}));_0x2183c6=_['merge']({},_0x2183c6,_0x8411e6['options']);const _0x38dd14={'where':_0x2183c6[_0x2f43a3('0x29')]};return db[_0x2f43a3('0x4e')][_0x2f43a3('0x31')](_0x38dd14)['then'](function(_0x4d8936){const _0x2c092d=_0x2f43a3;return _0x2e3e3b['count']=_0x4d8936,_0x8411e6[_0x2c092d('0x27')][_0x2c092d('0xe')]&&(_0x2183c6[_0x2c092d('0x15')]=[{'all':!![]}]),db[_0x2c092d('0x4e')][_0x2c092d('0xf')](_0x2183c6);})['then'](function(_0x4a3c11){const _0x360094=_0x2f43a3;return _0x2e3e3b[_0x360094('0x23')]=_0x4a3c11,_0x2e3e3b;})[_0x2f43a3('0x1')](respondWithFilteredResult(_0x1ecd30,_0x2183c6))[_0x2f43a3('0x46')](handleError(_0x1ecd30,null));},exports['show']=function(_0x3aa253,_0x4218fe){const _0x54df26=_0x4301f5;let _0x5cb219={'raw':!![],'where':{'id':_0x3aa253[_0x54df26('0x40')]['id']}};const _0x322ffc={};return _0x322ffc[_0x54df26('0x1f')]=_[_0x54df26('0x44')](db[_0x54df26('0x4e')][_0x54df26('0x3a')]),_0x322ffc[_0x54df26('0x27')]=_[_0x54df26('0x44')](_0x3aa253['query']),_0x322ffc[_0x54df26('0x45')]=_[_0x54df26('0x48')](_0x322ffc[_0x54df26('0x1f')],_0x322ffc[_0x54df26('0x27')]),_0x5cb219[_0x54df26('0x47')]=_[_0x54df26('0x48')](_0x322ffc[_0x54df26('0x1f')],qs[_0x54df26('0x1b')](_0x3aa253[_0x54df26('0x27')]['fields'])),_0x5cb219[_0x54df26('0x47')]=_0x5cb219[_0x54df26('0x47')][_0x54df26('0x4a')]?_0x5cb219[_0x54df26('0x47')]:_0x322ffc['model'],_0x3aa253[_0x54df26('0x27')][_0x54df26('0xe')]&&(_0x5cb219[_0x54df26('0x15')]=[{'all':!![]}]),_0x5cb219=_[_0x54df26('0x3')]({},_0x5cb219,_0x3aa253[_0x54df26('0x16')]),db['CmHopperFinal'][_0x54df26('0x58')](_0x5cb219)[_0x54df26('0x1')](handleEntityNotFound(_0x4218fe,null))[_0x54df26('0x1')](respondWithResult(_0x4218fe,null))[_0x54df26('0x46')](handleError(_0x4218fe,null));},exports[_0x4301f5('0x7')]=function(_0x273c20,_0x1547f3){const _0x1e01c5=_0x4301f5;return db[_0x1e01c5('0x4e')]['describe']()[_0x1e01c5('0x1')](respondWithResult(_0x1547f3,null))[_0x1e01c5('0x46')](handleError(_0x1547f3,null));},exports['update']=function(_0x8089fe,_0x438d59){const _0x34805c=_0x4301f5;return _0x8089fe[_0x34805c('0x67')]['uniqueid']&&delete _0x8089fe[_0x34805c('0x67')][_0x34805c('0x39')],db[_0x34805c('0x4e')]['findOne']({'where':{'uniqueid':_0x8089fe['params']['id']}})[_0x34805c('0x1')](handleEntityNotFound(_0x438d59,null))[_0x34805c('0x1')](saveUpdates(_0x8089fe[_0x34805c('0x67')],null))[_0x34805c('0x1')](respondWithResult(_0x438d59,null))[_0x34805c('0x46')](handleError(_0x438d59,null));},exports[_0x4301f5('0x2d')]=function(_0x144269,_0x2c2a7e){const _0x38a21b=_0x4301f5;return db[_0x38a21b('0x4e')]['findAll']({'raw':![],'where':{'VoiceQueueId':_0x144269[_0x38a21b('0x40')]['id']},'attributes':[[fn(_0x38a21b('0x2f'),fn('IF',literal('`state`\x20=\x200,\x201,\x20null'))),_0x38a21b('0x2c')],[fn(_0x38a21b('0x2f'),fn('IF',literal(_0x38a21b('0x43')))),_0x38a21b('0x63')],[fn(_0x38a21b('0x2f'),fn('IF',literal(_0x38a21b('0x2b')))),_0x38a21b('0x55')],[fn(_0x38a21b('0x2f'),fn('IF',literal(_0x38a21b('0x22')))),_0x38a21b('0xd')],[fn('COUNT',fn('IF',literal(_0x38a21b('0x37')))),'dropContacts'],[fn(_0x38a21b('0x2f'),fn('IF',literal('`state`\x20=\x2011\x20,\x201,\x20null'))),_0x38a21b('0x61')],[fn('COUNT',fn('IF',literal('`state`\x20=\x2022,\x201,\x20null'))),_0x38a21b('0x35')],[fn(_0x38a21b('0x2f'),fn('IF',literal(_0x38a21b('0x6')))),_0x38a21b('0x1a')]]})[_0x38a21b('0x1')](handleEntityNotFound(_0x2c2a7e,null))[_0x38a21b('0x1')](respondWithResult(_0x2c2a7e,null))[_0x38a21b('0x46')](handleError(_0x2c2a7e,null));},exports[_0x4301f5('0x49')]=function(_0x132544,_0x5bfd48){const _0x4dc5fd=_0x4301f5;return db[_0x4dc5fd('0x4e')]['findAll']({'raw':![],'where':{'CampaignId':_0x132544[_0x4dc5fd('0x40')]['id']},'attributes':[[fn(_0x4dc5fd('0x2f'),fn('IF',literal(_0x4dc5fd('0x3b')))),_0x4dc5fd('0x2c')],[fn(_0x4dc5fd('0x2f'),fn('IF',literal(_0x4dc5fd('0x43')))),_0x4dc5fd('0x63')],[fn(_0x4dc5fd('0x2f'),fn('IF',literal(_0x4dc5fd('0x2b')))),_0x4dc5fd('0x55')],[fn('COUNT',fn('IF',literal(_0x4dc5fd('0x22')))),'congestionContacts'],[fn(_0x4dc5fd('0x2f'),fn('IF',literal(_0x4dc5fd('0x37')))),_0x4dc5fd('0x8')],[fn(_0x4dc5fd('0x2f'),fn('IF',literal(_0x4dc5fd('0x1e')))),_0x4dc5fd('0x61')],[fn(_0x4dc5fd('0x2f'),fn('IF',literal(_0x4dc5fd('0x13')))),_0x4dc5fd('0x35')],[fn('COUNT',fn('IF',literal(_0x4dc5fd('0x6')))),_0x4dc5fd('0x1a')]]})[_0x4dc5fd('0x1')](handleEntityNotFound(_0x5bfd48,null))[_0x4dc5fd('0x1')](respondWithResult(_0x5bfd48,null))[_0x4dc5fd('0x46')](handleError(_0x5bfd48,null));},exports['moveContactsQueueCampaignHopperFinal']=function(_0x29f9df,_0x5d7449){const _0x268ba1=_0x4301f5;return db[_0x268ba1('0xc')][_0x268ba1('0x58')]({'where':{'id':_0x29f9df[_0x268ba1('0x40')]['id']}})[_0x268ba1('0x1')](handleEntityNotFound(_0x5d7449,null))[_0x268ba1('0x1')](function(_0x178899){const _0x46232a=_0x268ba1;let _0x1d4849;if(_0x178899)return _0x1d4849=squel['insert']()[_0x46232a('0x62')](_0x46232a('0x3c'))[_0x46232a('0x52')]([_0x46232a('0x9'),_0x46232a('0x3f'),_0x46232a('0x5'),'ListId',_0x46232a('0x57'),_0x46232a('0x20'),_0x46232a('0x2e')],squel[_0x46232a('0x0')]()[_0x46232a('0x3d')]('ANY_VALUE(calleridnum)','phone')['field'](_0x46232a('0x21'),_0x46232a('0x3f'))[_0x46232a('0x3d')](_0x46232a('0x26'),'ContactId')['field'](_0x46232a('0x41'),_0x46232a('0x64'))[_0x46232a('0x3d')](_0x46232a('0x4f'),_0x46232a('0x57'))['field']('NOW()',_0x46232a('0x20'))[_0x46232a('0x3d')]('NOW()',_0x46232a('0x2e'))[_0x46232a('0x4d')]('cm_hopper_final')['where'](_0x46232a('0x66'),_0x29f9df[_0x46232a('0x40')]['id'][_0x46232a('0x2a')]())['where'](_0x46232a('0x5e'),_0x29f9df[_0x46232a('0x67')][_0x46232a('0x3e')][_0x46232a('0x2a')]())[_0x46232a('0x29')]('calleridnum\x20IS\x20NOT\x20NULL')[_0x46232a('0x29')](_0x46232a('0x32'),squel[_0x46232a('0x0')]()[_0x46232a('0x3d')](_0x46232a('0x9'))[_0x46232a('0x4d')]('cm_hopper')[_0x46232a('0x29')](_0x46232a('0x66'),_0x29f9df[_0x46232a('0x40')]['id'][_0x46232a('0x2a')]()))[_0x46232a('0x29')](_0x46232a('0x32'),squel['select']()[_0x46232a('0x3d')](_0x46232a('0x5c'))[_0x46232a('0x4d')](_0x46232a('0x36'))[_0x46232a('0x29')](_0x46232a('0x66'),_0x29f9df[_0x46232a('0x40')]['id'][_0x46232a('0x2a')]())[_0x46232a('0x29')](_0x46232a('0x4b')))[_0x46232a('0xa')](_0x46232a('0x5')))[_0x46232a('0x2a')](),db[_0x46232a('0x59')][_0x46232a('0x27')](_0x1d4849);return[];})[_0x268ba1('0x1')](respondWithResult(_0x5d7449,null))[_0x268ba1('0x46')](handleError(_0x5d7449,null));},exports[_0x4301f5('0x2')]=function(_0x175971,_0x495569){const _0x543375=_0x4301f5;return db[_0x543375('0x24')][_0x543375('0x58')]({'where':{'id':_0x175971[_0x543375('0x40')]['id']}})[_0x543375('0x1')](handleEntityNotFound(_0x495569,null))[_0x543375('0x1')](function(_0x477817){const _0x31688c=_0x543375;let _0xdae563;if(_0x477817)return _0xdae563=squel[_0x31688c('0x28')]()['into'](_0x31688c('0x3c'))['fromQuery']([_0x31688c('0x9'),'scheduledAt',_0x31688c('0x5'),_0x31688c('0x64'),_0x31688c('0x60'),_0x31688c('0x20'),_0x31688c('0x2e')],squel[_0x31688c('0x0')]()[_0x31688c('0x3d')]('ANY_VALUE(calleridnum)',_0x31688c('0x9'))[_0x31688c('0x3d')](_0x31688c('0x21'),_0x31688c('0x3f'))[_0x31688c('0x3d')](_0x31688c('0x26'),_0x31688c('0x5'))['field']('ANY_VALUE(ListId)',_0x31688c('0x64'))[_0x31688c('0x3d')](_0x31688c('0x1d'),_0x31688c('0x60'))[_0x31688c('0x3d')]('NOW()',_0x31688c('0x20'))[_0x31688c('0x3d')](_0x31688c('0x21'),'updatedAt')['from'](_0x31688c('0x36'))[_0x31688c('0x29')](_0x31688c('0x5d'),_0x175971[_0x31688c('0x40')]['id'][_0x31688c('0x2a')]())['where'](_0x31688c('0x5e'),_0x175971[_0x31688c('0x67')][_0x31688c('0x3e')][_0x31688c('0x2a')]())[_0x31688c('0x29')](_0x31688c('0x19'))[_0x31688c('0x29')](_0x31688c('0x32'),squel[_0x31688c('0x0')]()[_0x31688c('0x3d')](_0x31688c('0x9'))[_0x31688c('0x4d')](_0x31688c('0x3c'))[_0x31688c('0x29')]('CampaignId\x20=\x20?',_0x175971[_0x31688c('0x40')]['id'][_0x31688c('0x2a')]()))[_0x31688c('0x29')](_0x31688c('0x32'),squel[_0x31688c('0x0')]()['field'](_0x31688c('0x5c'))[_0x31688c('0x4d')]('cm_hopper_final')[_0x31688c('0x29')](_0x31688c('0x5d'),_0x175971[_0x31688c('0x40')]['id'][_0x31688c('0x2a')]())[_0x31688c('0x29')](_0x31688c('0x4b')))[_0x31688c('0xa')]('ContactId'))[_0x31688c('0x2a')](),db[_0x31688c('0x59')]['query'](_0xdae563);return[];})[_0x543375('0x1')](respondWithResult(_0x495569,null))[_0x543375('0x46')](handleError(_0x495569,null));},exports['checkContactHopper']=function(_0x1359b0,_0x32bd6f){const _0x58083a=_0x4301f5;return db['CmHopper']['findOne']({'where':{'VoiceQueueId':_0x1359b0[_0x58083a('0x67')]['VoiceQueueId'],'CampaignId':_0x1359b0[_0x58083a('0x67')][_0x58083a('0x60')],'ContactId':_0x1359b0[_0x58083a('0x67')]['ContactId']}})[_0x58083a('0x1')](handleEntityNotFound(_0x32bd6f,null))[_0x58083a('0x1')](function(_0x5defb7){if(_0x5defb7)return _0x5defb7;return null;})[_0x58083a('0x1')](respondWithResult(_0x32bd6f,null))['catch'](handleError(_0x32bd6f,null));}; \ No newline at end of file +const a147_0xd803=['field','fieldName','moveContactsIvrCampaignHopperFinal','createdAt','dropContacts','CampaignId','api','answeringMachine','catch','key','into','keys','VoiceQueueId','name','body','`state`\x20=\x203,\x201,\x20null','options','nolimit','`state`\x20=\x2022,\x201,\x20null','rawAttributes','params','`state`\x20=\x208,\x201,\x20null','CampaignId\x20=\x20?','cm_hopper_final','Campaign','include','intersection','lodash','ANY_VALUE(VoiceQueueId)','model','moveContactsQueueCampaignHopperFinal','phone','squel','toString','sort','attributes','congestionContacts','scheduledAt','`state`\x20=\x2010\x20,\x201,\x20null','state','ANY_VALUE(calleridnum)','ANY_VALUE(ListId)','noAnswerContacts','../../mysqldb','reCallContacts','sequelize','fromQuery','json','uniqueid','state\x20=\x204','checkContactHopper','calleridnum\x20NOT\x20IN\x20(?)','status','VoiceQueue','pick','noSuchContacts','query','fields','length','ANY_VALUE(ContactId)','CmHopperFinal','updatedAt','CmHopper','merge','select','insert','COUNT','../../components/parsers/qs','calleridnum','index','calleridnum\x20IS\x20NOT\x20NULL','where','cm_hopper','VoiceQueueId\x20=\x20?','findAll','findOne','../../config/logger','`state`\x20=\x2019,\x201,\x20null','describe','includeAll','`state`\x20=\x2011\x20,\x201,\x20null','NOW()','error','undefined','count','offset','type','then','abandonedContacts','ListId','busyContacts','filters','group','like','ContactId','from','`state`\x20=\x200,\x201,\x20null','countContactsQueueCampaignHopperFinal','map','limit','show','Content-Range','send','update','filter'];(function(_0x20a445,_0xd803a4){const _0xf72f0b=function(_0x3c684d){while(--_0x3c684d){_0x20a445['push'](_0x20a445['shift']());}};_0xf72f0b(++_0xd803a4);}(a147_0xd803,0x1ca));const a147_0xf72f=function(_0x20a445,_0xd803a4){_0x20a445=_0x20a445-0x0;let _0xf72f0b=a147_0xd803[_0x20a445];return _0xf72f0b;};const _0x3cc1cb=a147_0xf72f;'use strict';const _=require(_0x3cc1cb('0x5e')),squel=require(_0x3cc1cb('0x63')),qs=require(_0x3cc1cb('0x1d')),logger=require(_0x3cc1cb('0x26'))(_0x3cc1cb('0x49')),db=require(_0x3cc1cb('0x5'))['db'],{Op,fn,literal}=require('sequelize');function respondWithResult(_0x3c684d,_0x3e72e0){return _0x3e72e0=_0x3e72e0||0xc8,function(_0x1f2588){const _0x2c8077=a147_0xf72f;if(_0x1f2588)return _0x3c684d['status'](_0x3e72e0)[_0x2c8077('0x9')](_0x1f2588);};}function respondWithFilteredResult(_0x2b7060,_0x3761ed){return function(_0x41bfe0){const _0x3a5093=a147_0xf72f;if(_0x41bfe0){const _0x2dec6c=_0x41bfe0[_0x3a5093('0x2e')],_0x259241=_0x3761ed['offset'];let _0x28e59d=_0x3761ed[_0x3a5093('0x2f')]+_0x3761ed[_0x3a5093('0x3d')],_0x419e8e;return _0x28e59d>=_0x2dec6c?(_0x28e59d=_0x2dec6c,_0x419e8e=0xc8):_0x419e8e=0xce,_0x2b7060[_0x3a5093('0xe')](_0x419e8e),_0x2b7060['set'](_0x3a5093('0x3f'),_0x259241+'-'+_0x28e59d+'/'+_0x2dec6c)[_0x3a5093('0x9')](_0x41bfe0);}return null;};}function saveUpdates(_0xb4b97f){return function(_0x27c2a5){const _0x38cafe=a147_0xf72f;if(_0x27c2a5)return _0x27c2a5[_0x38cafe('0x41')](_0xb4b97f)['then'](function(_0x3657e7){return _0x3657e7;});return null;};}function handleEntityNotFound(_0x291fee){return function(_0x298f61){return!_0x298f61&&_0x291fee['sendStatus'](0x194),_0x298f61;};}function handleError(_0xc735c0,_0xdcd567){return _0xdcd567=_0xdcd567||0x1f4,function(_0xa8cc76){const _0x597c4b=a147_0xf72f;logger[_0x597c4b('0x2c')](_0xa8cc76['stack']),_0xa8cc76[_0x597c4b('0x50')]&&delete _0xa8cc76[_0x597c4b('0x50')],_0xc735c0['status'](_0xdcd567)[_0x597c4b('0x40')](_0xa8cc76);};}exports[_0x3cc1cb('0x1f')]=function(_0x1b5843,_0x29cb26){const _0x17dfa3=_0x3cc1cb;let _0x4d7063={};const _0x3be0a7={},_0xeb6026={'count':0x0,'rows':[]},_0x40db4e=_['map'](db[_0x17dfa3('0x16')][_0x17dfa3('0x56')],function(_0x526850){const _0x239069=_0x17dfa3;return{'name':_0x526850[_0x239069('0x44')],'type':_0x526850[_0x239069('0x30')][_0x239069('0x4c')]};});_0x3be0a7[_0x17dfa3('0x60')]=_[_0x17dfa3('0x3c')](_0x40db4e,_0x17dfa3('0x50')),_0x3be0a7[_0x17dfa3('0x12')]=_[_0x17dfa3('0x4e')](_0x1b5843[_0x17dfa3('0x12')]),_0x3be0a7[_0x17dfa3('0x35')]=_[_0x17dfa3('0x5d')](_0x3be0a7[_0x17dfa3('0x60')],_0x3be0a7[_0x17dfa3('0x12')]),_0x4d7063[_0x17dfa3('0x66')]=_[_0x17dfa3('0x5d')](_0x3be0a7[_0x17dfa3('0x60')],qs[_0x17dfa3('0x13')](_0x1b5843['query'][_0x17dfa3('0x13')])),_0x4d7063['attributes']=_0x4d7063[_0x17dfa3('0x66')][_0x17dfa3('0x14')]?_0x4d7063[_0x17dfa3('0x66')]:_0x3be0a7['model'];typeof _0x1b5843[_0x17dfa3('0x12')][_0x17dfa3('0x54')]===_0x17dfa3('0x2d')&&(_0x4d7063[_0x17dfa3('0x3d')]=qs[_0x17dfa3('0x3d')](_0x1b5843[_0x17dfa3('0x12')]['limit']),_0x4d7063[_0x17dfa3('0x2f')]=qs[_0x17dfa3('0x2f')](_0x1b5843[_0x17dfa3('0x12')][_0x17dfa3('0x2f')]));_0x4d7063['order']=qs[_0x17dfa3('0x65')](_0x1b5843[_0x17dfa3('0x12')]['sort']),_0x4d7063[_0x17dfa3('0x21')]=qs['filters'](_[_0x17dfa3('0x10')](_0x1b5843[_0x17dfa3('0x12')],_0x3be0a7[_0x17dfa3('0x35')]),_0x40db4e);_0x1b5843[_0x17dfa3('0x12')][_0x17dfa3('0x42')]&&(_0x4d7063[_0x17dfa3('0x21')]=_[_0x17dfa3('0x19')](_0x4d7063[_0x17dfa3('0x21')],{[Op['or']]:_[_0x17dfa3('0x3c')](_0x40db4e,function(_0x1e31ae){const _0x324cb8=_0x17dfa3;if(_0x1e31ae[_0x324cb8('0x30')]!=='VIRTUAL'){const _0x41b7de={};return _0x41b7de[_0x1e31ae[_0x324cb8('0x50')]]={[Op[_0x324cb8('0x37')]]:'%'+_0x1b5843['query'][_0x324cb8('0x42')]+'%'},_0x41b7de;}})}));_0x4d7063=_['merge']({},_0x4d7063,_0x1b5843[_0x17dfa3('0x53')]);const _0x2ada05={'where':_0x4d7063['where']};return db[_0x17dfa3('0x16')][_0x17dfa3('0x2e')](_0x2ada05)[_0x17dfa3('0x31')](function(_0x39b67c){const _0x1a3718=_0x17dfa3;return _0xeb6026['count']=_0x39b67c,_0x1b5843[_0x1a3718('0x12')][_0x1a3718('0x29')]&&(_0x4d7063[_0x1a3718('0x5c')]=[{'all':!![]}]),db[_0x1a3718('0x16')][_0x1a3718('0x24')](_0x4d7063);})[_0x17dfa3('0x31')](function(_0x17ea39){return _0xeb6026['rows']=_0x17ea39,_0xeb6026;})[_0x17dfa3('0x31')](respondWithFilteredResult(_0x29cb26,_0x4d7063))[_0x17dfa3('0x4b')](handleError(_0x29cb26,null));},exports[_0x3cc1cb('0x3e')]=function(_0x3aaac3,_0x29bd87){const _0x4aadf0=_0x3cc1cb;let _0x4b8fc3={'raw':!![],'where':{'id':_0x3aaac3['params']['id']}};const _0xc1de73={};return _0xc1de73[_0x4aadf0('0x60')]=_[_0x4aadf0('0x4e')](db[_0x4aadf0('0x16')][_0x4aadf0('0x56')]),_0xc1de73[_0x4aadf0('0x12')]=_['keys'](_0x3aaac3[_0x4aadf0('0x12')]),_0xc1de73['filters']=_[_0x4aadf0('0x5d')](_0xc1de73[_0x4aadf0('0x60')],_0xc1de73['query']),_0x4b8fc3['attributes']=_['intersection'](_0xc1de73[_0x4aadf0('0x60')],qs['fields'](_0x3aaac3['query'][_0x4aadf0('0x13')])),_0x4b8fc3[_0x4aadf0('0x66')]=_0x4b8fc3['attributes'][_0x4aadf0('0x14')]?_0x4b8fc3[_0x4aadf0('0x66')]:_0xc1de73['model'],_0x3aaac3[_0x4aadf0('0x12')][_0x4aadf0('0x29')]&&(_0x4b8fc3[_0x4aadf0('0x5c')]=[{'all':!![]}]),_0x4b8fc3=_[_0x4aadf0('0x19')]({},_0x4b8fc3,_0x3aaac3[_0x4aadf0('0x53')]),db[_0x4aadf0('0x16')][_0x4aadf0('0x25')](_0x4b8fc3)['then'](handleEntityNotFound(_0x29bd87,null))[_0x4aadf0('0x31')](respondWithResult(_0x29bd87,null))[_0x4aadf0('0x4b')](handleError(_0x29bd87,null));},exports[_0x3cc1cb('0x28')]=function(_0x366b5a,_0x4ff19c){const _0x43e371=_0x3cc1cb;return db[_0x43e371('0x16')][_0x43e371('0x28')]()[_0x43e371('0x31')](respondWithResult(_0x4ff19c,null))[_0x43e371('0x4b')](handleError(_0x4ff19c,null));},exports[_0x3cc1cb('0x41')]=function(_0x1e182a,_0x29048e){const _0x1a69ff=_0x3cc1cb;return _0x1e182a['body'][_0x1a69ff('0xa')]&&delete _0x1e182a[_0x1a69ff('0x51')][_0x1a69ff('0xa')],db[_0x1a69ff('0x16')]['findOne']({'where':{'uniqueid':_0x1e182a[_0x1a69ff('0x57')]['id']}})[_0x1a69ff('0x31')](handleEntityNotFound(_0x29048e,null))[_0x1a69ff('0x31')](saveUpdates(_0x1e182a[_0x1a69ff('0x51')],null))['then'](respondWithResult(_0x29048e,null))[_0x1a69ff('0x4b')](handleError(_0x29048e,null));},exports[_0x3cc1cb('0x3b')]=function(_0x3228c1,_0x628537){const _0x23d79e=_0x3cc1cb;return db[_0x23d79e('0x16')][_0x23d79e('0x24')]({'raw':![],'where':{'VoiceQueueId':_0x3228c1[_0x23d79e('0x57')]['id']},'attributes':[[fn(_0x23d79e('0x1c'),fn('IF',literal(_0x23d79e('0x3a')))),_0x23d79e('0x11')],[fn(_0x23d79e('0x1c'),fn('IF',literal('`state`\x20=\x203,\x201,\x20null'))),_0x23d79e('0x4')],[fn(_0x23d79e('0x1c'),fn('IF',literal('`state`\x20=\x205,\x201,\x20null'))),'busyContacts'],[fn(_0x23d79e('0x1c'),fn('IF',literal(_0x23d79e('0x58')))),_0x23d79e('0x67')],[fn(_0x23d79e('0x1c'),fn('IF',literal('`state`\x20=\x2010\x20,\x201,\x20null'))),_0x23d79e('0x47')],[fn(_0x23d79e('0x1c'),fn('IF',literal(_0x23d79e('0x2a')))),'abandonedContacts'],[fn(_0x23d79e('0x1c'),fn('IF',literal(_0x23d79e('0x55')))),_0x23d79e('0x6')],[fn(_0x23d79e('0x1c'),fn('IF',literal(_0x23d79e('0x27')))),_0x23d79e('0x4a')]]})[_0x23d79e('0x31')](handleEntityNotFound(_0x628537,null))[_0x23d79e('0x31')](respondWithResult(_0x628537,null))[_0x23d79e('0x4b')](handleError(_0x628537,null));},exports['countContactsIvrCampaignHopperFinal']=function(_0x95b6c6,_0x1a5c6c){const _0x2ac686=_0x3cc1cb;return db[_0x2ac686('0x16')]['findAll']({'raw':![],'where':{'CampaignId':_0x95b6c6[_0x2ac686('0x57')]['id']},'attributes':[[fn(_0x2ac686('0x1c'),fn('IF',literal(_0x2ac686('0x3a')))),'noSuchContacts'],[fn(_0x2ac686('0x1c'),fn('IF',literal(_0x2ac686('0x52')))),'noAnswerContacts'],[fn(_0x2ac686('0x1c'),fn('IF',literal('`state`\x20=\x205,\x201,\x20null'))),_0x2ac686('0x34')],[fn(_0x2ac686('0x1c'),fn('IF',literal(_0x2ac686('0x58')))),_0x2ac686('0x67')],[fn(_0x2ac686('0x1c'),fn('IF',literal(_0x2ac686('0x0')))),_0x2ac686('0x47')],[fn(_0x2ac686('0x1c'),fn('IF',literal('`state`\x20=\x2011\x20,\x201,\x20null'))),_0x2ac686('0x32')],[fn(_0x2ac686('0x1c'),fn('IF',literal('`state`\x20=\x2022,\x201,\x20null'))),'reCallContacts'],[fn('COUNT',fn('IF',literal('`state`\x20=\x2019,\x201,\x20null'))),'answeringMachine']]})[_0x2ac686('0x31')](handleEntityNotFound(_0x1a5c6c,null))[_0x2ac686('0x31')](respondWithResult(_0x1a5c6c,null))[_0x2ac686('0x4b')](handleError(_0x1a5c6c,null));},exports[_0x3cc1cb('0x61')]=function(_0x332818,_0x507e84){const _0x5ec382=_0x3cc1cb;return db[_0x5ec382('0xf')][_0x5ec382('0x25')]({'where':{'id':_0x332818[_0x5ec382('0x57')]['id']}})[_0x5ec382('0x31')](handleEntityNotFound(_0x507e84,null))[_0x5ec382('0x31')](function(_0x1e904a){const _0x39ece7=_0x5ec382;let _0x4d3d4c;if(_0x1e904a)return _0x4d3d4c=squel[_0x39ece7('0x1b')]()[_0x39ece7('0x4d')](_0x39ece7('0x22'))[_0x39ece7('0x8')](['phone','scheduledAt','ContactId',_0x39ece7('0x33'),_0x39ece7('0x4f'),_0x39ece7('0x46'),'updatedAt'],squel[_0x39ece7('0x1a')]()['field'](_0x39ece7('0x2'),_0x39ece7('0x62'))[_0x39ece7('0x43')]('NOW()','scheduledAt')[_0x39ece7('0x43')](_0x39ece7('0x15'),_0x39ece7('0x38'))[_0x39ece7('0x43')](_0x39ece7('0x3'),'ListId')[_0x39ece7('0x43')](_0x39ece7('0x5f'),_0x39ece7('0x4f'))[_0x39ece7('0x43')](_0x39ece7('0x2b'),_0x39ece7('0x46'))[_0x39ece7('0x43')]('NOW()',_0x39ece7('0x17'))[_0x39ece7('0x39')](_0x39ece7('0x5a'))[_0x39ece7('0x21')]('VoiceQueueId\x20=\x20?',_0x332818[_0x39ece7('0x57')]['id'][_0x39ece7('0x64')]())['where']('state\x20=\x20?',_0x332818[_0x39ece7('0x51')]['state'][_0x39ece7('0x64')]())[_0x39ece7('0x21')](_0x39ece7('0x20'))[_0x39ece7('0x21')](_0x39ece7('0xd'),squel[_0x39ece7('0x1a')]()['field'](_0x39ece7('0x62'))['from'](_0x39ece7('0x22'))['where']('VoiceQueueId\x20=\x20?',_0x332818[_0x39ece7('0x57')]['id']['toString']()))[_0x39ece7('0x21')](_0x39ece7('0xd'),squel[_0x39ece7('0x1a')]()[_0x39ece7('0x43')](_0x39ece7('0x1e'))[_0x39ece7('0x39')](_0x39ece7('0x5a'))[_0x39ece7('0x21')](_0x39ece7('0x23'),_0x332818[_0x39ece7('0x57')]['id'][_0x39ece7('0x64')]())['where']('state\x20=\x204'))[_0x39ece7('0x36')](_0x39ece7('0x38')))[_0x39ece7('0x64')](),db['sequelize'][_0x39ece7('0x12')](_0x4d3d4c);return[];})['then'](respondWithResult(_0x507e84,null))[_0x5ec382('0x4b')](handleError(_0x507e84,null));},exports[_0x3cc1cb('0x45')]=function(_0x3e5243,_0x1193bc){const _0x1e604d=_0x3cc1cb;return db[_0x1e604d('0x5b')][_0x1e604d('0x25')]({'where':{'id':_0x3e5243[_0x1e604d('0x57')]['id']}})['then'](handleEntityNotFound(_0x1193bc,null))[_0x1e604d('0x31')](function(_0x56d138){const _0x1019c4=_0x1e604d;let _0x5e64d7;if(_0x56d138)return _0x5e64d7=squel['insert']()[_0x1019c4('0x4d')](_0x1019c4('0x22'))[_0x1019c4('0x8')]([_0x1019c4('0x62'),_0x1019c4('0x68'),_0x1019c4('0x38'),_0x1019c4('0x33'),_0x1019c4('0x48'),'createdAt',_0x1019c4('0x17')],squel['select']()['field'](_0x1019c4('0x2'),_0x1019c4('0x62'))[_0x1019c4('0x43')](_0x1019c4('0x2b'),_0x1019c4('0x68'))[_0x1019c4('0x43')]('ANY_VALUE(ContactId)',_0x1019c4('0x38'))[_0x1019c4('0x43')](_0x1019c4('0x3'),_0x1019c4('0x33'))[_0x1019c4('0x43')]('ANY_VALUE(CampaignId)',_0x1019c4('0x48'))[_0x1019c4('0x43')]('NOW()',_0x1019c4('0x46'))['field']('NOW()',_0x1019c4('0x17'))[_0x1019c4('0x39')](_0x1019c4('0x5a'))[_0x1019c4('0x21')](_0x1019c4('0x59'),_0x3e5243[_0x1019c4('0x57')]['id'][_0x1019c4('0x64')]())[_0x1019c4('0x21')]('state\x20=\x20?',_0x3e5243[_0x1019c4('0x51')][_0x1019c4('0x1')]['toString']())['where'](_0x1019c4('0x20'))[_0x1019c4('0x21')]('calleridnum\x20NOT\x20IN\x20(?)',squel[_0x1019c4('0x1a')]()[_0x1019c4('0x43')](_0x1019c4('0x62'))[_0x1019c4('0x39')](_0x1019c4('0x22'))[_0x1019c4('0x21')]('CampaignId\x20=\x20?',_0x3e5243[_0x1019c4('0x57')]['id'][_0x1019c4('0x64')]()))[_0x1019c4('0x21')]('calleridnum\x20NOT\x20IN\x20(?)',squel[_0x1019c4('0x1a')]()[_0x1019c4('0x43')]('calleridnum')[_0x1019c4('0x39')]('cm_hopper_final')['where']('CampaignId\x20=\x20?',_0x3e5243['params']['id'][_0x1019c4('0x64')]())['where'](_0x1019c4('0xb')))[_0x1019c4('0x36')](_0x1019c4('0x38')))[_0x1019c4('0x64')](),db[_0x1019c4('0x7')][_0x1019c4('0x12')](_0x5e64d7);return[];})[_0x1e604d('0x31')](respondWithResult(_0x1193bc,null))[_0x1e604d('0x4b')](handleError(_0x1193bc,null));},exports[_0x3cc1cb('0xc')]=function(_0xde0a18,_0x46fdf3){const _0x485ed1=_0x3cc1cb;return db[_0x485ed1('0x18')][_0x485ed1('0x25')]({'where':{'VoiceQueueId':_0xde0a18[_0x485ed1('0x51')][_0x485ed1('0x4f')],'CampaignId':_0xde0a18[_0x485ed1('0x51')]['CampaignId'],'ContactId':_0xde0a18['body'][_0x485ed1('0x38')]}})[_0x485ed1('0x31')](handleEntityNotFound(_0x46fdf3,null))[_0x485ed1('0x31')](function(_0x1ac14b){if(_0x1ac14b)return _0x1ac14b;return null;})[_0x485ed1('0x31')](respondWithResult(_0x46fdf3,null))[_0x485ed1('0x4b')](handleError(_0x46fdf3,null));}; \ No newline at end of file diff --git a/server/api/cmHopperFinal/cmHopperFinal.model.js b/server/api/cmHopperFinal/cmHopperFinal.model.js index bcd912f..5dc592d 100644 --- a/server/api/cmHopperFinal/cmHopperFinal.model.js +++ b/server/api/cmHopperFinal/cmHopperFinal.model.js @@ -1 +1 @@ -const a148_0x2e6e=['cm_hopper_final','CmHopperFinal','define','uniqueid'];(function(_0x184af6,_0x2e6e20){const _0x29ae74=function(_0x2c408f){while(--_0x2c408f){_0x184af6['push'](_0x184af6['shift']());}};_0x29ae74(++_0x2e6e20);}(a148_0x2e6e,0x151));const a148_0x29ae=function(_0x184af6,_0x2e6e20){_0x184af6=_0x184af6-0x0;let _0x29ae74=a148_0x2e6e[_0x184af6];return _0x29ae74;};'use strict';const attributes=require('./cmHopperFinal.attributes');module['exports']=function(_0x2c408f){const _0x4d9376=a148_0x29ae,_0x3bb816=_0x2c408f[_0x4d9376('0x1')](_0x4d9376('0x0'),attributes,{'tableName':_0x4d9376('0x3'),'paranoid':![],'indexes':[{'name':'calleridnum','fields':['calleridnum']},{'name':_0x4d9376('0x2'),'fields':[_0x4d9376('0x2')]}],'timestamps':!![]});return _0x3bb816;}; \ No newline at end of file +const a148_0xd1bf=['cm_hopper_final','exports','./cmHopperFinal.attributes','define','calleridnum'];(function(_0x43c85c,_0xd1bf2c){const _0x29555e=function(_0xb2f135){while(--_0xb2f135){_0x43c85c['push'](_0x43c85c['shift']());}};_0x29555e(++_0xd1bf2c);}(a148_0xd1bf,0x19c));const a148_0x2955=function(_0x43c85c,_0xd1bf2c){_0x43c85c=_0x43c85c-0x0;let _0x29555e=a148_0xd1bf[_0x43c85c];return _0x29555e;};const _0x30c228=a148_0x2955;'use strict';const attributes=require(_0x30c228('0x0'));module[_0x30c228('0x4')]=function(_0xb2f135){const _0x38a1b6=_0x30c228,_0x5836cf=_0xb2f135[_0x38a1b6('0x1')]('CmHopperFinal',attributes,{'tableName':_0x38a1b6('0x3'),'paranoid':![],'indexes':[{'name':_0x38a1b6('0x2'),'fields':[_0x38a1b6('0x2')]},{'name':'uniqueid','fields':['uniqueid']}],'timestamps':!![]});return _0x5836cf;}; \ No newline at end of file diff --git a/server/api/cmHopperFinal/cmHopperFinal.rpc.js b/server/api/cmHopperFinal/cmHopperFinal.rpc.js index 56d5da7..080aeda 100644 --- a/server/api/cmHopperFinal/cmHopperFinal.rpc.js +++ b/server/api/cmHopperFinal/cmHopperFinal.rpc.js @@ -1 +1 @@ -const a149_0x3a94=['raw','message','error','info','then','catch','debug','rpc','CmHopperFinal','stringify','create','CreateCmHopperFinal','options','../../config/logger'];(function(_0x3f35be,_0x3a94fc){const _0x1aff72=function(_0x59b3d6){while(--_0x59b3d6){_0x3f35be['push'](_0x3f35be['shift']());}};_0x1aff72(++_0x3a94fc);}(a149_0x3a94,0x9f));const a149_0x1aff=function(_0x3f35be,_0x3a94fc){_0x3f35be=_0x3f35be-0x0;let _0x1aff72=a149_0x3a94[_0x3f35be];return _0x1aff72;};const _0x500194=a149_0x1aff;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x500194('0x8'))(_0x500194('0x2'));exports['CreateCmHopperFinal']=function(_0x59b3d6){const _0x5c4f11=this;return new Promise(function(_0x29b056,_0x210650){const _0x475d87=a149_0x1aff;return db[_0x475d87('0x3')][_0x475d87('0x5')](_0x59b3d6['body'],{'raw':_0x59b3d6[_0x475d87('0x7')]?_0x59b3d6['options'][_0x475d87('0x9')]===undefined?!![]:![]:!![]})[_0x475d87('0xd')](function(_0xb5a400){const _0x39d85a=_0x475d87;logger[_0x39d85a('0xc')](_0x39d85a('0x6'),_0x59b3d6),logger[_0x39d85a('0x1')]('CreateCmHopperFinal',_0x59b3d6,JSON[_0x39d85a('0x4')](_0xb5a400)),_0x29b056(_0xb5a400);})[_0x475d87('0x0')](function(_0x58a3c2){const _0x3998fc=_0x475d87;logger[_0x3998fc('0xb')]('CreateCmHopperFinal',_0x58a3c2[_0x3998fc('0xa')],_0x59b3d6),_0x210650(_0x5c4f11[_0x3998fc('0xb')](0x1f4,_0x58a3c2[_0x3998fc('0xa')]));});});}; \ No newline at end of file +const a149_0x517b=['catch','stringify','raw','CmHopperFinal','rpc','options','message','error','body','../../mysqldb','create','CreateCmHopperFinal'];(function(_0x13a573,_0x517b7b){const _0x2058e0=function(_0x26b732){while(--_0x26b732){_0x13a573['push'](_0x13a573['shift']());}};_0x2058e0(++_0x517b7b);}(a149_0x517b,0xf0));const a149_0x2058=function(_0x13a573,_0x517b7b){_0x13a573=_0x13a573-0x0;let _0x2058e0=a149_0x517b[_0x13a573];return _0x2058e0;};const _0xdc8340=a149_0x2058;'use strict';const db=require(_0xdc8340('0x9'))['db'],logger=require('../../config/logger')(_0xdc8340('0x4'));exports[_0xdc8340('0xb')]=function(_0x26b732){const _0x34e94f=this;return new Promise(function(_0xbb24e,_0x3e3ddc){const _0x8ffaf1=a149_0x2058;return db[_0x8ffaf1('0x3')][_0x8ffaf1('0xa')](_0x26b732[_0x8ffaf1('0x8')],{'raw':_0x26b732[_0x8ffaf1('0x5')]?_0x26b732['options'][_0x8ffaf1('0x2')]===undefined?!![]:![]:!![]})['then'](function(_0x42dcae){const _0x416f00=_0x8ffaf1;logger['info']('CreateCmHopperFinal',_0x26b732),logger['debug']('CreateCmHopperFinal',_0x26b732,JSON[_0x416f00('0x1')](_0x42dcae)),_0xbb24e(_0x42dcae);})[_0x8ffaf1('0x0')](function(_0x23ef8a){const _0x63ee02=_0x8ffaf1;logger[_0x63ee02('0x7')](_0x63ee02('0xb'),_0x23ef8a['message'],_0x26b732),_0x3e3ddc(_0x34e94f[_0x63ee02('0x7')](0x1f4,_0x23ef8a[_0x63ee02('0x6')]));});});}; \ No newline at end of file diff --git a/server/api/cmHopperFinal/index.js b/server/api/cmHopperFinal/index.js index 4c908a6..3db9b47 100644 --- a/server/api/cmHopperFinal/index.js +++ b/server/api/cmHopperFinal/index.js @@ -1 +1 @@ -const a150_0x5b51=['describe','/:id','../../components/auth/service','countContactsIvrCampaignHopperFinal','/voice/queue/moveContacts/:id','exports','post','show','isAuthenticated','put','./cmHopperFinal.controller','/voice/campaign/moveContacts/:id','/campaign/countAttributes/:id','express','moveContactsQueueCampaignHopperFinal','get','/describe','countContactsQueueCampaignHopperFinal','index','checkContactHopper','moveContactsIvrCampaignHopperFinal'];(function(_0x433920,_0x5b5112){const _0x270afa=function(_0x29fefa){while(--_0x29fefa){_0x433920['push'](_0x433920['shift']());}};_0x270afa(++_0x5b5112);}(a150_0x5b51,0x148));const a150_0x270a=function(_0x433920,_0x5b5112){_0x433920=_0x433920-0x0;let _0x270afa=a150_0x5b51[_0x433920];return _0x270afa;};const _0x3f0901=a150_0x270a;'use strict';const express=require(_0x3f0901('0x0')),router=express['Router'](),auth=require(_0x3f0901('0xa')),controller=require(_0x3f0901('0x12'));router[_0x3f0901('0x2')]('/',auth['isAuthenticated'](),controller[_0x3f0901('0x5')]),router[_0x3f0901('0x2')](_0x3f0901('0x3'),auth['isAuthenticated'](),controller[_0x3f0901('0x8')]),router[_0x3f0901('0x2')](_0x3f0901('0x9'),auth['isAuthenticated'](),controller[_0x3f0901('0xf')]),router[_0x3f0901('0x2')]('/voice/queue/countAttributes/:id',auth['isAuthenticated'](),controller[_0x3f0901('0x4')]),router[_0x3f0901('0x2')](_0x3f0901('0x14'),auth['isAuthenticated'](),controller[_0x3f0901('0xb')]),router['post'](_0x3f0901('0xc'),auth[_0x3f0901('0x10')](),controller[_0x3f0901('0x1')]),router[_0x3f0901('0xe')](_0x3f0901('0x13'),auth['isAuthenticated'](),controller[_0x3f0901('0x7')]),router['post']('/checkContactHopper',auth[_0x3f0901('0x10')](),controller[_0x3f0901('0x6')]),router[_0x3f0901('0x11')](_0x3f0901('0x9'),auth[_0x3f0901('0x10')](),controller['update']),module[_0x3f0901('0xd')]=router; \ No newline at end of file +const a150_0x42bf=['index','checkContactHopper','isAuthenticated','/checkContactHopper','put','/voice/campaign/moveContacts/:id','Router','../../components/auth/service','exports','show','post','moveContactsIvrCampaignHopperFinal','moveContactsQueueCampaignHopperFinal','countContactsIvrCampaignHopperFinal','/voice/queue/countAttributes/:id','/:id','/voice/queue/moveContacts/:id','get','./cmHopperFinal.controller','/campaign/countAttributes/:id'];(function(_0x262c58,_0x42bfe5){const _0x50a099=function(_0x54b8cf){while(--_0x54b8cf){_0x262c58['push'](_0x262c58['shift']());}};_0x50a099(++_0x42bfe5);}(a150_0x42bf,0x122));const a150_0x50a0=function(_0x262c58,_0x42bfe5){_0x262c58=_0x262c58-0x0;let _0x50a099=a150_0x42bf[_0x262c58];return _0x50a099;};const _0x56fa66=a150_0x50a0;'use strict';const express=require('express'),router=express[_0x56fa66('0x10')](),auth=require(_0x56fa66('0x11')),controller=require(_0x56fa66('0x8'));router[_0x56fa66('0x7')]('/',auth[_0x56fa66('0xc')](),controller[_0x56fa66('0xa')]),router[_0x56fa66('0x7')]('/describe',auth['isAuthenticated'](),controller['describe']),router['get'](_0x56fa66('0x5'),auth[_0x56fa66('0xc')](),controller[_0x56fa66('0x13')]),router[_0x56fa66('0x7')](_0x56fa66('0x4'),auth[_0x56fa66('0xc')](),controller['countContactsQueueCampaignHopperFinal']),router[_0x56fa66('0x7')](_0x56fa66('0x9'),auth[_0x56fa66('0xc')](),controller[_0x56fa66('0x3')]),router[_0x56fa66('0x0')](_0x56fa66('0x6'),auth[_0x56fa66('0xc')](),controller[_0x56fa66('0x2')]),router['post'](_0x56fa66('0xf'),auth[_0x56fa66('0xc')](),controller[_0x56fa66('0x1')]),router['post'](_0x56fa66('0xd'),auth[_0x56fa66('0xc')](),controller[_0x56fa66('0xb')]),router[_0x56fa66('0xe')](_0x56fa66('0x5'),auth[_0x56fa66('0xc')](),controller['update']),module[_0x56fa66('0x12')]=router; \ No newline at end of file diff --git a/server/api/cmHopperHistory/cmHopperHistory.attributes.js b/server/api/cmHopperHistory/cmHopperHistory.attributes.js index b4813ea..7ba51a1 100644 --- a/server/api/cmHopperHistory/cmHopperHistory.attributes.js +++ b/server/api/cmHopperHistory/cmHopperHistory.attributes.js @@ -1 +1 @@ -const a151_0x7bc1=['INTEGER','sequelize','DATE','exports','STRING','BOOLEAN'];(function(_0xd3a63f,_0x7bc1fe){const _0x2a3125=function(_0x13aacc){while(--_0x13aacc){_0xd3a63f['push'](_0xd3a63f['shift']());}};_0x2a3125(++_0x7bc1fe);}(a151_0x7bc1,0x1b3));const a151_0x2a31=function(_0xd3a63f,_0x7bc1fe){_0xd3a63f=_0xd3a63f-0x0;let _0x2a3125=a151_0x7bc1[_0xd3a63f];return _0x2a3125;};const _0x2fee43=a151_0x2a31;'use strict';const Sequelize=require(_0x2fee43('0x4'));module[_0x2fee43('0x0')]={'state':{'type':Sequelize[_0x2fee43('0x3')](0x2)},'statedesc':{'type':Sequelize[_0x2fee43('0x1')]},'scheduledat':{'type':Sequelize['DATE']},'countbusyretry':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0},'countcongestionretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countnoanswerretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countglobal':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0},'uniqueid':{'type':Sequelize[_0x2fee43('0x1')]},'originatecalleridnum':{'type':Sequelize[_0x2fee43('0x1')]},'originatecalleridname':{'type':Sequelize[_0x2fee43('0x1')]},'calleridnum':{'type':Sequelize[_0x2fee43('0x1')]},'calleridname':{'type':Sequelize[_0x2fee43('0x1')]},'starttime':{'type':Sequelize[_0x2fee43('0x5')]},'responsetime':{'type':Sequelize[_0x2fee43('0x5')]},'answertime':{'type':Sequelize[_0x2fee43('0x5')]},'droptime':{'type':Sequelize['DATE']},'endtime':{'type':Sequelize[_0x2fee43('0x5')]},'ringtime':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0},'holdtime':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0},'talktime':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0},'followuptime':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0},'dropreason':{'type':Sequelize[_0x2fee43('0x1')]},'campaign':{'type':Sequelize[_0x2fee43('0x1')]},'campaigntype':{'type':Sequelize[_0x2fee43('0x1')]},'membername':{'type':Sequelize[_0x2fee43('0x1')]},'reason':{'type':Sequelize['STRING']},'amd':{'type':Sequelize[_0x2fee43('0x2')],'defaultValue':![]},'fax':{'type':Sequelize[_0x2fee43('0x2')],'defaultValue':![]},'callback':{'type':Sequelize[_0x2fee43('0x2')],'defaultValue':![]},'callbackuniqueid':{'type':Sequelize[_0x2fee43('0x1')],'defaultValue':null},'callbackat':{'type':Sequelize[_0x2fee43('0x5')]},'recallme':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'editedat':{'type':Sequelize[_0x2fee43('0x5')]},'edited':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'countnosuchnumberretry':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0},'countdropretry':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0},'countabandonedretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countmachineretry':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0},'countagentrejectretry':{'type':Sequelize[_0x2fee43('0x3')],'defaultValue':0x0}}; \ No newline at end of file +const a151_0x49c9=['exports','DATE','STRING','BOOLEAN','INTEGER'];(function(_0x2b54c7,_0x49c924){const _0x51a7c9=function(_0x55fad3){while(--_0x55fad3){_0x2b54c7['push'](_0x2b54c7['shift']());}};_0x51a7c9(++_0x49c924);}(a151_0x49c9,0xd0));const a151_0x51a7=function(_0x2b54c7,_0x49c924){_0x2b54c7=_0x2b54c7-0x0;let _0x51a7c9=a151_0x49c9[_0x2b54c7];return _0x51a7c9;};const _0x44d738=a151_0x51a7;'use strict';const Sequelize=require('sequelize');module[_0x44d738('0x2')]={'state':{'type':Sequelize['INTEGER'](0x2)},'statedesc':{'type':Sequelize['STRING']},'scheduledat':{'type':Sequelize[_0x44d738('0x3')]},'countbusyretry':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'countcongestionretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countnoanswerretry':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'countglobal':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'uniqueid':{'type':Sequelize[_0x44d738('0x4')]},'originatecalleridnum':{'type':Sequelize[_0x44d738('0x4')]},'originatecalleridname':{'type':Sequelize[_0x44d738('0x4')]},'calleridnum':{'type':Sequelize['STRING']},'calleridname':{'type':Sequelize[_0x44d738('0x4')]},'starttime':{'type':Sequelize['DATE']},'responsetime':{'type':Sequelize['DATE']},'answertime':{'type':Sequelize[_0x44d738('0x3')]},'droptime':{'type':Sequelize[_0x44d738('0x3')]},'endtime':{'type':Sequelize[_0x44d738('0x3')]},'ringtime':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'holdtime':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'talktime':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'followuptime':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'dropreason':{'type':Sequelize[_0x44d738('0x4')]},'campaign':{'type':Sequelize['STRING']},'campaigntype':{'type':Sequelize[_0x44d738('0x4')]},'membername':{'type':Sequelize[_0x44d738('0x4')]},'reason':{'type':Sequelize[_0x44d738('0x4')]},'amd':{'type':Sequelize[_0x44d738('0x0')],'defaultValue':![]},'fax':{'type':Sequelize[_0x44d738('0x0')],'defaultValue':![]},'callback':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'callbackuniqueid':{'type':Sequelize[_0x44d738('0x4')],'defaultValue':null},'callbackat':{'type':Sequelize['DATE']},'recallme':{'type':Sequelize[_0x44d738('0x0')],'defaultValue':![]},'editedat':{'type':Sequelize[_0x44d738('0x3')]},'edited':{'type':Sequelize[_0x44d738('0x0')],'defaultValue':![]},'countnosuchnumberretry':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'countdropretry':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'countabandonedretry':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0},'countmachineretry':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'countagentrejectretry':{'type':Sequelize[_0x44d738('0x1')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/cmHopperHistory/cmHopperHistory.controller.js b/server/api/cmHopperHistory/cmHopperHistory.controller.js index 80b15fa..4752e03 100644 --- a/server/api/cmHopperHistory/cmHopperHistory.controller.js +++ b/server/api/cmHopperHistory/cmHopperHistory.controller.js @@ -1 +1 @@ -const a152_0x2859=['update','../../config/logger','sort','offset','sequelize','limit','include','fieldName','nolimit','undefined','sendStatus','send','name','filter','uniqueid','count','params','merge','keys','json','lodash','rows','order','error','options','attributes','../../components/parsers/qs','findOne','model','CmHopperHistory','query','key','catch','VIRTUAL','fields','show','Content-Range','filters','status','create','rawAttributes','then','where','length','set','intersection','index','describe','map','findAll','type','body'];(function(_0x3dcb3f,_0x28599d){const _0x1faef1=function(_0x373a39){while(--_0x373a39){_0x3dcb3f['push'](_0x3dcb3f['shift']());}};_0x1faef1(++_0x28599d);}(a152_0x2859,0x9f));const a152_0x1fae=function(_0x3dcb3f,_0x28599d){_0x3dcb3f=_0x3dcb3f-0x0;let _0x1faef1=a152_0x2859[_0x3dcb3f];return _0x1faef1;};const _0x44c15e=a152_0x1fae;'use strict';const _=require(_0x44c15e('0x11')),qs=require(_0x44c15e('0x17')),logger=require(_0x44c15e('0x32'))('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x44c15e('0x1'));function respondWithResult(_0x373a39,_0x4069c1){return _0x4069c1=_0x4069c1||0xc8,function(_0x34da38){const _0xb16062=a152_0x1fae;if(_0x34da38)return _0x373a39[_0xb16062('0x23')](_0x4069c1)[_0xb16062('0x10')](_0x34da38);};}function respondWithFilteredResult(_0x28cac0,_0x4365e8){return function(_0x4d8f67){const _0x1fce42=a152_0x1fae;if(_0x4d8f67){const _0x34a724=_0x4d8f67[_0x1fce42('0xc')],_0x53b527=_0x4365e8[_0x1fce42('0x0')];let _0x36b09b=_0x4365e8['offset']+_0x4365e8[_0x1fce42('0x2')],_0x56bbba;return _0x36b09b>=_0x34a724?(_0x36b09b=_0x34a724,_0x56bbba=0xc8):_0x56bbba=0xce,_0x28cac0[_0x1fce42('0x23')](_0x56bbba),_0x28cac0[_0x1fce42('0x29')](_0x1fce42('0x21'),_0x53b527+'-'+_0x36b09b+'/'+_0x34a724)[_0x1fce42('0x10')](_0x4d8f67);}return null;};}function saveUpdates(_0xcc780d){return function(_0x1b1bd3){const _0x26a5f0=a152_0x1fae;if(_0x1b1bd3)return _0x1b1bd3[_0x26a5f0('0x31')](_0xcc780d)[_0x26a5f0('0x26')](function(_0x273971){return _0x273971;});return null;};}function handleEntityNotFound(_0x20b0ea){return function(_0x11c1f3){const _0x3a9362=a152_0x1fae;return!_0x11c1f3&&_0x20b0ea[_0x3a9362('0x7')](0x194),_0x11c1f3;};}function handleError(_0x57d7da,_0x32550c){return _0x32550c=_0x32550c||0x1f4,function(_0xa5546f){const _0x292025=a152_0x1fae;logger[_0x292025('0x14')](_0xa5546f['stack']),_0xa5546f[_0x292025('0x9')]&&delete _0xa5546f[_0x292025('0x9')],_0x57d7da[_0x292025('0x23')](_0x32550c)[_0x292025('0x8')](_0xa5546f);};}exports[_0x44c15e('0x2b')]=function(_0x3eb110,_0x5a99ec){const _0x3bfb38=_0x44c15e;let _0x1ed38f={};const _0x4f5335={},_0x4aa7be={'count':0x0,'rows':[]},_0x27ef3f=_['map'](db['CmHopperHistory'][_0x3bfb38('0x25')],function(_0x3aad82){const _0x265597=_0x3bfb38;return{'name':_0x3aad82[_0x265597('0x4')],'type':_0x3aad82[_0x265597('0x2f')][_0x265597('0x1c')]};});_0x4f5335[_0x3bfb38('0x19')]=_[_0x3bfb38('0x2d')](_0x27ef3f,_0x3bfb38('0x9')),_0x4f5335[_0x3bfb38('0x1b')]=_[_0x3bfb38('0xf')](_0x3eb110[_0x3bfb38('0x1b')]),_0x4f5335[_0x3bfb38('0x22')]=_[_0x3bfb38('0x2a')](_0x4f5335[_0x3bfb38('0x19')],_0x4f5335['query']),_0x1ed38f[_0x3bfb38('0x16')]=_[_0x3bfb38('0x2a')](_0x4f5335[_0x3bfb38('0x19')],qs[_0x3bfb38('0x1f')](_0x3eb110['query'][_0x3bfb38('0x1f')])),_0x1ed38f[_0x3bfb38('0x16')]=_0x1ed38f[_0x3bfb38('0x16')][_0x3bfb38('0x28')]?_0x1ed38f[_0x3bfb38('0x16')]:_0x4f5335['model'];typeof _0x3eb110[_0x3bfb38('0x1b')][_0x3bfb38('0x5')]===_0x3bfb38('0x6')&&(_0x1ed38f[_0x3bfb38('0x2')]=qs[_0x3bfb38('0x2')](_0x3eb110[_0x3bfb38('0x1b')]['limit']),_0x1ed38f[_0x3bfb38('0x0')]=qs[_0x3bfb38('0x0')](_0x3eb110['query']['offset']));_0x1ed38f[_0x3bfb38('0x13')]=qs[_0x3bfb38('0x33')](_0x3eb110[_0x3bfb38('0x1b')][_0x3bfb38('0x33')]),_0x1ed38f[_0x3bfb38('0x27')]=qs[_0x3bfb38('0x22')](_['pick'](_0x3eb110['query'],_0x4f5335[_0x3bfb38('0x22')]),_0x27ef3f);_0x3eb110[_0x3bfb38('0x1b')][_0x3bfb38('0xa')]&&(_0x1ed38f[_0x3bfb38('0x27')]=_[_0x3bfb38('0xe')](_0x1ed38f[_0x3bfb38('0x27')],{[Op['or']]:_['map'](_0x27ef3f,function(_0x2a5815){const _0x3f4dc6=_0x3bfb38;if(_0x2a5815[_0x3f4dc6('0x2f')]!==_0x3f4dc6('0x1e')){const _0x1bdbbb={};return _0x1bdbbb[_0x2a5815[_0x3f4dc6('0x9')]]={[Op['like']]:'%'+_0x3eb110['query']['filter']+'%'},_0x1bdbbb;}})}));_0x1ed38f=_[_0x3bfb38('0xe')]({},_0x1ed38f,_0x3eb110['options']);const _0x4e1ff8={'where':_0x1ed38f[_0x3bfb38('0x27')]};return db[_0x3bfb38('0x1a')][_0x3bfb38('0xc')](_0x4e1ff8)[_0x3bfb38('0x26')](function(_0x2433b8){const _0x2e2ffd=_0x3bfb38;return _0x4aa7be['count']=_0x2433b8,_0x3eb110['query']['includeAll']&&(_0x1ed38f[_0x2e2ffd('0x3')]=[{'all':!![]}]),db[_0x2e2ffd('0x1a')][_0x2e2ffd('0x2e')](_0x1ed38f);})[_0x3bfb38('0x26')](function(_0x55c624){const _0x166229=_0x3bfb38;return _0x4aa7be[_0x166229('0x12')]=_0x55c624,_0x4aa7be;})[_0x3bfb38('0x26')](respondWithFilteredResult(_0x5a99ec,_0x1ed38f))[_0x3bfb38('0x1d')](handleError(_0x5a99ec,null));},exports[_0x44c15e('0x20')]=function(_0x5205e2,_0x1c2f03){const _0x8f64e9=_0x44c15e;let _0x4e58da={'raw':!![],'where':{'id':_0x5205e2[_0x8f64e9('0xd')]['id']}};const _0x3079c6={};return _0x3079c6[_0x8f64e9('0x19')]=_['keys'](db[_0x8f64e9('0x1a')][_0x8f64e9('0x25')]),_0x3079c6[_0x8f64e9('0x1b')]=_['keys'](_0x5205e2['query']),_0x3079c6['filters']=_[_0x8f64e9('0x2a')](_0x3079c6[_0x8f64e9('0x19')],_0x3079c6[_0x8f64e9('0x1b')]),_0x4e58da[_0x8f64e9('0x16')]=_[_0x8f64e9('0x2a')](_0x3079c6[_0x8f64e9('0x19')],qs['fields'](_0x5205e2['query'][_0x8f64e9('0x1f')])),_0x4e58da[_0x8f64e9('0x16')]=_0x4e58da['attributes']['length']?_0x4e58da[_0x8f64e9('0x16')]:_0x3079c6['model'],_0x5205e2[_0x8f64e9('0x1b')]['includeAll']&&(_0x4e58da[_0x8f64e9('0x3')]=[{'all':!![]}]),_0x4e58da=_[_0x8f64e9('0xe')]({},_0x4e58da,_0x5205e2[_0x8f64e9('0x15')]),db['CmHopperHistory']['findOne'](_0x4e58da)[_0x8f64e9('0x26')](handleEntityNotFound(_0x1c2f03,null))[_0x8f64e9('0x26')](respondWithResult(_0x1c2f03,null))['catch'](handleError(_0x1c2f03,null));},exports[_0x44c15e('0x24')]=function(_0x218e10,_0xd2e35b){const _0x409655=_0x44c15e;return db['CmHopperHistory'][_0x409655('0x24')](_0x218e10[_0x409655('0x30')],{})['then'](respondWithResult(_0xd2e35b,0xc9))[_0x409655('0x1d')](handleError(_0xd2e35b,null));},exports[_0x44c15e('0x2c')]=function(_0x841e8b,_0x23f38d){const _0x460e1d=_0x44c15e;return db[_0x460e1d('0x1a')][_0x460e1d('0x2c')]()['then'](respondWithResult(_0x23f38d,null))[_0x460e1d('0x1d')](handleError(_0x23f38d,null));},exports['update']=function(_0x3a1954,_0x52398a){const _0x41bc3f=_0x44c15e;return _0x3a1954['body']['uniqueid']&&delete _0x3a1954['body'][_0x41bc3f('0xb')],db[_0x41bc3f('0x1a')][_0x41bc3f('0x18')]({'where':{'uniqueid':_0x3a1954[_0x41bc3f('0xd')]['id']}})[_0x41bc3f('0x26')](handleEntityNotFound(_0x52398a,null))[_0x41bc3f('0x26')](saveUpdates(_0x3a1954[_0x41bc3f('0x30')],null))[_0x41bc3f('0x26')](respondWithResult(_0x52398a,null))['catch'](handleError(_0x52398a,null));}; \ No newline at end of file +const a152_0x2c7f=['../../config/logger','uniqueid','length','keys','lodash','name','options','params','model','where','sequelize','status','offset','body','query','describe','fields','findOne','error','filter','filters','set','includeAll','catch','map','findAll','key','attributes','VIRTUAL','../../mysqldb','rows','type','order','json','include','update','count','limit','sort','then','show','send','Content-Range','CmHopperHistory','rawAttributes','api','intersection','create','nolimit','sendStatus','../../components/parsers/qs'];(function(_0x3dac37,_0x2c7f8f){const _0x1b1bc5=function(_0x2854e9){while(--_0x2854e9){_0x3dac37['push'](_0x3dac37['shift']());}};_0x1b1bc5(++_0x2c7f8f);}(a152_0x2c7f,0x1f2));const a152_0x1b1b=function(_0x3dac37,_0x2c7f8f){_0x3dac37=_0x3dac37-0x0;let _0x1b1bc5=a152_0x2c7f[_0x3dac37];return _0x1b1bc5;};const _0x168aec=a152_0x1b1b;'use strict';const _=require(_0x168aec('0x10')),qs=require(_0x168aec('0xb')),logger=require(_0x168aec('0xc'))(_0x168aec('0x6')),db=require(_0x168aec('0x29'))['db'],{Op}=require(_0x168aec('0x16'));function respondWithResult(_0x2854e9,_0x520bf6){return _0x520bf6=_0x520bf6||0xc8,function(_0x2139e6){if(_0x2139e6)return _0x2854e9['status'](_0x520bf6)['json'](_0x2139e6);};}function respondWithFilteredResult(_0x5dc814,_0x421732){return function(_0x35213e){const _0x394216=a152_0x1b1b;if(_0x35213e){const _0x352eff=_0x35213e[_0x394216('0x30')],_0x331f43=_0x421732[_0x394216('0x18')];let _0xeaa6cf=_0x421732[_0x394216('0x18')]+_0x421732[_0x394216('0x31')],_0x2435d7;return _0xeaa6cf>=_0x352eff?(_0xeaa6cf=_0x352eff,_0x2435d7=0xc8):_0x2435d7=0xce,_0x5dc814[_0x394216('0x17')](_0x2435d7),_0x5dc814[_0x394216('0x21')](_0x394216('0x3'),_0x331f43+'-'+_0xeaa6cf+'/'+_0x352eff)[_0x394216('0x2d')](_0x35213e);}return null;};}function saveUpdates(_0x407030){return function(_0x2f7430){const _0x476f17=a152_0x1b1b;if(_0x2f7430)return _0x2f7430[_0x476f17('0x2f')](_0x407030)[_0x476f17('0x0')](function(_0x24db4f){return _0x24db4f;});return null;};}function handleEntityNotFound(_0x465a72){return function(_0x215204){const _0x300e42=a152_0x1b1b;return!_0x215204&&_0x465a72[_0x300e42('0xa')](0x194),_0x215204;};}function handleError(_0x2dbe34,_0xda6f0){return _0xda6f0=_0xda6f0||0x1f4,function(_0x4ad2ea){const _0x4f8e0f=a152_0x1b1b;logger[_0x4f8e0f('0x1e')](_0x4ad2ea['stack']),_0x4ad2ea['name']&&delete _0x4ad2ea[_0x4f8e0f('0x11')],_0x2dbe34[_0x4f8e0f('0x17')](_0xda6f0)[_0x4f8e0f('0x2')](_0x4ad2ea);};}exports['index']=function(_0x3d46cc,_0xb56175){const _0x1a6432=_0x168aec;let _0x477837={};const _0x43f877={},_0x4013ee={'count':0x0,'rows':[]},_0x322f4f=_[_0x1a6432('0x24')](db['CmHopperHistory'][_0x1a6432('0x5')],function(_0x3af17f){const _0x565889=_0x1a6432;return{'name':_0x3af17f['fieldName'],'type':_0x3af17f[_0x565889('0x2b')][_0x565889('0x26')]};});_0x43f877['model']=_[_0x1a6432('0x24')](_0x322f4f,'name'),_0x43f877[_0x1a6432('0x1a')]=_[_0x1a6432('0xf')](_0x3d46cc[_0x1a6432('0x1a')]),_0x43f877['filters']=_['intersection'](_0x43f877['model'],_0x43f877[_0x1a6432('0x1a')]),_0x477837['attributes']=_[_0x1a6432('0x7')](_0x43f877[_0x1a6432('0x14')],qs['fields'](_0x3d46cc[_0x1a6432('0x1a')]['fields'])),_0x477837[_0x1a6432('0x27')]=_0x477837[_0x1a6432('0x27')][_0x1a6432('0xe')]?_0x477837[_0x1a6432('0x27')]:_0x43f877[_0x1a6432('0x14')];typeof _0x3d46cc[_0x1a6432('0x1a')][_0x1a6432('0x9')]==='undefined'&&(_0x477837[_0x1a6432('0x31')]=qs[_0x1a6432('0x31')](_0x3d46cc[_0x1a6432('0x1a')][_0x1a6432('0x31')]),_0x477837[_0x1a6432('0x18')]=qs['offset'](_0x3d46cc[_0x1a6432('0x1a')][_0x1a6432('0x18')]));_0x477837[_0x1a6432('0x2c')]=qs[_0x1a6432('0x32')](_0x3d46cc[_0x1a6432('0x1a')][_0x1a6432('0x32')]),_0x477837['where']=qs['filters'](_['pick'](_0x3d46cc[_0x1a6432('0x1a')],_0x43f877[_0x1a6432('0x20')]),_0x322f4f);_0x3d46cc[_0x1a6432('0x1a')][_0x1a6432('0x1f')]&&(_0x477837['where']=_['merge'](_0x477837['where'],{[Op['or']]:_['map'](_0x322f4f,function(_0x179bbd){const _0x10ad92=_0x1a6432;if(_0x179bbd[_0x10ad92('0x2b')]!==_0x10ad92('0x28')){const _0x2f8aa9={};return _0x2f8aa9[_0x179bbd[_0x10ad92('0x11')]]={[Op['like']]:'%'+_0x3d46cc[_0x10ad92('0x1a')][_0x10ad92('0x1f')]+'%'},_0x2f8aa9;}})}));_0x477837=_['merge']({},_0x477837,_0x3d46cc['options']);const _0x1c0fef={'where':_0x477837[_0x1a6432('0x15')]};return db[_0x1a6432('0x4')]['count'](_0x1c0fef)[_0x1a6432('0x0')](function(_0x4a5d7f){const _0x40eada=_0x1a6432;return _0x4013ee['count']=_0x4a5d7f,_0x3d46cc[_0x40eada('0x1a')]['includeAll']&&(_0x477837[_0x40eada('0x2e')]=[{'all':!![]}]),db[_0x40eada('0x4')][_0x40eada('0x25')](_0x477837);})['then'](function(_0x5c6445){const _0x21bbb3=_0x1a6432;return _0x4013ee[_0x21bbb3('0x2a')]=_0x5c6445,_0x4013ee;})[_0x1a6432('0x0')](respondWithFilteredResult(_0xb56175,_0x477837))[_0x1a6432('0x23')](handleError(_0xb56175,null));},exports[_0x168aec('0x1')]=function(_0xe12495,_0x179712){const _0x40cf55=_0x168aec;let _0x5a6c69={'raw':!![],'where':{'id':_0xe12495[_0x40cf55('0x13')]['id']}};const _0x4ec5e1={};return _0x4ec5e1['model']=_['keys'](db[_0x40cf55('0x4')][_0x40cf55('0x5')]),_0x4ec5e1[_0x40cf55('0x1a')]=_['keys'](_0xe12495[_0x40cf55('0x1a')]),_0x4ec5e1[_0x40cf55('0x20')]=_[_0x40cf55('0x7')](_0x4ec5e1[_0x40cf55('0x14')],_0x4ec5e1[_0x40cf55('0x1a')]),_0x5a6c69[_0x40cf55('0x27')]=_[_0x40cf55('0x7')](_0x4ec5e1['model'],qs[_0x40cf55('0x1c')](_0xe12495[_0x40cf55('0x1a')][_0x40cf55('0x1c')])),_0x5a6c69[_0x40cf55('0x27')]=_0x5a6c69['attributes'][_0x40cf55('0xe')]?_0x5a6c69['attributes']:_0x4ec5e1[_0x40cf55('0x14')],_0xe12495[_0x40cf55('0x1a')][_0x40cf55('0x22')]&&(_0x5a6c69[_0x40cf55('0x2e')]=[{'all':!![]}]),_0x5a6c69=_['merge']({},_0x5a6c69,_0xe12495[_0x40cf55('0x12')]),db[_0x40cf55('0x4')]['findOne'](_0x5a6c69)[_0x40cf55('0x0')](handleEntityNotFound(_0x179712,null))['then'](respondWithResult(_0x179712,null))[_0x40cf55('0x23')](handleError(_0x179712,null));},exports[_0x168aec('0x8')]=function(_0x2d92b7,_0x5d88d5){const _0x30ab5c=_0x168aec;return db[_0x30ab5c('0x4')]['create'](_0x2d92b7[_0x30ab5c('0x19')],{})['then'](respondWithResult(_0x5d88d5,0xc9))['catch'](handleError(_0x5d88d5,null));},exports[_0x168aec('0x1b')]=function(_0x23496a,_0x2cc2d7){const _0x58cd5d=_0x168aec;return db[_0x58cd5d('0x4')][_0x58cd5d('0x1b')]()[_0x58cd5d('0x0')](respondWithResult(_0x2cc2d7,null))['catch'](handleError(_0x2cc2d7,null));},exports[_0x168aec('0x2f')]=function(_0x13737b,_0x1f0ff9){const _0x345e3f=_0x168aec;return _0x13737b[_0x345e3f('0x19')][_0x345e3f('0xd')]&&delete _0x13737b[_0x345e3f('0x19')][_0x345e3f('0xd')],db[_0x345e3f('0x4')][_0x345e3f('0x1d')]({'where':{'uniqueid':_0x13737b[_0x345e3f('0x13')]['id']}})[_0x345e3f('0x0')](handleEntityNotFound(_0x1f0ff9,null))[_0x345e3f('0x0')](saveUpdates(_0x13737b[_0x345e3f('0x19')],null))[_0x345e3f('0x0')](respondWithResult(_0x1f0ff9,null))[_0x345e3f('0x23')](handleError(_0x1f0ff9,null));}; \ No newline at end of file diff --git a/server/api/cmHopperHistory/cmHopperHistory.model.js b/server/api/cmHopperHistory/cmHopperHistory.model.js index 53bd13d..e3ae983 100644 --- a/server/api/cmHopperHistory/cmHopperHistory.model.js +++ b/server/api/cmHopperHistory/cmHopperHistory.model.js @@ -1 +1 @@ -const a153_0x3b3c=['uniqueid','exports','CmHopperHistory','./cmHopperHistory.attributes','endtime'];(function(_0x25ca0e,_0x3b3c12){const _0x49bbdb=function(_0x3e881c){while(--_0x3e881c){_0x25ca0e['push'](_0x25ca0e['shift']());}};_0x49bbdb(++_0x3b3c12);}(a153_0x3b3c,0x67));const a153_0x49bb=function(_0x25ca0e,_0x3b3c12){_0x25ca0e=_0x25ca0e-0x0;let _0x49bbdb=a153_0x3b3c[_0x25ca0e];return _0x49bbdb;};const _0x3a21fa=a153_0x49bb;'use strict';const attributes=require(_0x3a21fa('0x0'));module[_0x3a21fa('0x3')]=function(_0x3e881c){const _0x336778=_0x3a21fa,_0x14ba83=_0x3e881c['define'](_0x336778('0x4'),attributes,{'tableName':'cm_hopper_history','paranoid':![],'indexes':[{'name':_0x336778('0x1'),'fields':['endtime']},{'name':'uniqueid','fields':[_0x336778('0x2')]}],'timestamps':!![]});return _0x14ba83;}; \ No newline at end of file +const a153_0x34c1=['exports','uniqueid','define','cm_hopper_history','CmHopperHistory'];(function(_0x149cab,_0x34c1dd){const _0x2536a9=function(_0x402321){while(--_0x402321){_0x149cab['push'](_0x149cab['shift']());}};_0x2536a9(++_0x34c1dd);}(a153_0x34c1,0x130));const a153_0x2536=function(_0x149cab,_0x34c1dd){_0x149cab=_0x149cab-0x0;let _0x2536a9=a153_0x34c1[_0x149cab];return _0x2536a9;};const _0x4cee72=a153_0x2536;'use strict';const attributes=require('./cmHopperHistory.attributes');module[_0x4cee72('0x1')]=function(_0x402321){const _0x3fa1f2=_0x4cee72,_0x446a1c=_0x402321[_0x3fa1f2('0x3')](_0x3fa1f2('0x0'),attributes,{'tableName':_0x3fa1f2('0x4'),'paranoid':![],'indexes':[{'name':'endtime','fields':['endtime']},{'name':_0x3fa1f2('0x2'),'fields':['uniqueid']}],'timestamps':!![]});return _0x446a1c;}; \ No newline at end of file diff --git a/server/api/cmHopperHistory/cmHopperHistory.rpc.js b/server/api/cmHopperHistory/cmHopperHistory.rpc.js index 92acf5c..4506163 100644 --- a/server/api/cmHopperHistory/cmHopperHistory.rpc.js +++ b/server/api/cmHopperHistory/cmHopperHistory.rpc.js @@ -1 +1 @@ -const a154_0x37af=['COUNT','stringify','`state`\x20=\x203,\x201,\x20null','findAll','GetVoiceQueueHopperHistory','`state`\x20=\x204,\x20`holdtime`,\x20null','error','`state`\x20=\x2010\x20,\x201,\x20null','GetCampaignHopperHistory','AVG','`state`\x20=\x2022\x20or\x20`state`\x20=\x2023,\x201,\x20null','predictiveIntervalAnsweredCalls','`state`\x20=\x204,\x20`talktime`,\x20null','`state`\x20=\x2018,\x201,\x20null','message','create','info','options','`state`\x20=\x2020,\x201,\x20null','catch','`state`\x20=\x2012,\x201,\x20null','`state`\x20=\x2013,\x201,\x20null','where','outboundBlacklistCallsDay','ivrAnswerCallsDay','outboundReCallsDay','outboundUnknownCallsDay','predictiveIntervalTotalCalls','../../mysqldb','outboundAnswerCallsDay','outboundNoSuchCallsDay','`state`\x20=\x204,\x201,\x20null','debug','AvgHandleTime','outboundDropCallsDayCallersExit','ivrTotalCallsDays','`state`\x20=\x2016,\x201,\x20null','then','CmHopperHistory','sequelize','`state`\x20=\x205,\x201,\x20null','CreateCmHopperHistory','outboundRejectCallsDay','name','predictiveIntervalDroppedCallsCallersExit','body','outboundNoAnswerCallsDay','outboundAnswerAgiCallsDay','campaign','outboundOriginateFailureCallsDay','`state`\x20=\x2011\x20,\x201,\x20null','raw','`state`\x20=\x2011,\x201,\x20null'];(function(_0x17673d,_0x37af55){const _0x3f4b6d=function(_0x2e0efd){while(--_0x2e0efd){_0x17673d['push'](_0x17673d['shift']());}};_0x3f4b6d(++_0x37af55);}(a154_0x37af,0x89));const a154_0x3f4b=function(_0x17673d,_0x37af55){_0x17673d=_0x17673d-0x0;let _0x3f4b6d=a154_0x37af[_0x17673d];return _0x3f4b6d;};const _0x343aa7=a154_0x3f4b;'use strict';const db=require(_0x343aa7('0x32'))['db'],{fn,literal,col}=require(_0x343aa7('0x8')),logger=require('../../config/logger')('rpc');exports[_0x343aa7('0xa')]=function(_0x2e0efd){const _0x2854a9=this;return new Promise(function(_0x37bf0c,_0x4a6999){const _0x180c00=a154_0x3f4b;return db[_0x180c00('0x7')][_0x180c00('0x25')](_0x2e0efd[_0x180c00('0xe')],{'raw':_0x2e0efd[_0x180c00('0x27')]?_0x2e0efd[_0x180c00('0x27')][_0x180c00('0x14')]===undefined?!![]:![]:!![]})['then'](function(_0x2d6be0){const _0x1f5ec0=_0x180c00;logger[_0x1f5ec0('0x26')](_0x1f5ec0('0xa'),_0x2e0efd),logger[_0x1f5ec0('0x1')](_0x1f5ec0('0xa'),_0x2e0efd,JSON[_0x1f5ec0('0x17')](_0x2d6be0)),_0x37bf0c(_0x2d6be0);})[_0x180c00('0x29')](function(_0x54bd12){const _0x401743=_0x180c00;logger['error'](_0x401743('0xa'),_0x54bd12['message'],_0x2e0efd),_0x4a6999(_0x2854a9[_0x401743('0x1c')](0x1f4,_0x54bd12[_0x401743('0x24')]));});});},exports[_0x343aa7('0x2')]=function(_0x36c0a5){const _0x130485=this;return new Promise(function(_0x1adc6c,_0x1112a2){const _0x3dfa57=a154_0x3f4b;return db['CmHopperHistory'][_0x3dfa57('0x19')]({'raw':_0x36c0a5[_0x3dfa57('0x27')]?_0x36c0a5[_0x3dfa57('0x27')]['raw']===undefined?!![]:![]:!![],'where':_0x36c0a5['options']?_0x36c0a5[_0x3dfa57('0x27')]['where']||null:null,'attributes':[[fn(_0x3dfa57('0x16'),col('id')),_0x3dfa57('0x31')],[fn(_0x3dfa57('0x16'),fn('IF',literal(_0x3dfa57('0x0')))),_0x3dfa57('0x21')],[fn(_0x3dfa57('0x16'),fn('IF',literal('`state`\x20=\x2010,\x201,\x20null'))),'predictiveIntervalDroppedCallsTimeout'],[fn('COUNT',fn('IF',literal(_0x3dfa57('0x15')))),_0x3dfa57('0xd')],[fn(_0x3dfa57('0x1f'),fn('IF',literal(_0x3dfa57('0x1b')))),'predictiveIntervalAvgHoldtime'],[fn(_0x3dfa57('0x1f'),fn('IF',literal(_0x3dfa57('0x22')))),'predictiveIntervalAvgTalktime']]})[_0x3dfa57('0x6')](function(_0x2caf8a){const _0x18f1ad=_0x3dfa57;logger[_0x18f1ad('0x26')]('AvgHandleTime',_0x36c0a5),logger[_0x18f1ad('0x1')]('AvgHandleTime',_0x36c0a5,JSON[_0x18f1ad('0x17')](_0x2caf8a)),_0x1adc6c(_0x2caf8a);})['catch'](function(_0x224f47){const _0x8db803=_0x3dfa57;logger[_0x8db803('0x1c')](_0x8db803('0x2'),_0x224f47[_0x8db803('0x24')],_0x36c0a5),_0x1112a2(_0x130485[_0x8db803('0x1c')](0x1f4,_0x224f47[_0x8db803('0x24')]));});});},exports[_0x343aa7('0x1a')]=function(_0x3dc406){const _0x18635d=this;return new Promise(function(_0x25c26f,_0x54f4fb){const _0x5bbfd6=a154_0x3f4b;return db[_0x5bbfd6('0x7')][_0x5bbfd6('0x19')]({'raw':_0x3dc406[_0x5bbfd6('0x27')]?_0x3dc406[_0x5bbfd6('0x27')]['raw']===undefined?!![]:![]:!![],'where':_0x3dc406[_0x5bbfd6('0x27')]?_0x3dc406[_0x5bbfd6('0x27')][_0x5bbfd6('0x2c')]||null:null,'attributes':[[_0x5bbfd6('0x11'),'name'],[fn(_0x5bbfd6('0x16'),fn('IF',literal('`state`\x20=\x200,\x201,\x20null'))),_0x5bbfd6('0x34')],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x18')))),_0x5bbfd6('0xf')],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x0')))),_0x5bbfd6('0x33')],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x9')))),'outboundBusyCallsDay'],[fn(_0x5bbfd6('0x16'),fn('IF',literal('`state`\x20=\x208,\x201,\x20null'))),'outboundCongestionCallsDay'],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x1d')))),'outboundDropCallsDayTimeout'],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x13')))),_0x5bbfd6('0x3')],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x2a')))),_0x5bbfd6('0x30')],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x2b')))),_0x5bbfd6('0x2d')],[fn('COUNT',fn('IF',literal('`state`\x20=\x2014,\x201,\x20null'))),_0x5bbfd6('0x12')],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x23')))),_0x5bbfd6('0xb')],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x5')))),_0x5bbfd6('0x10')],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x28')))),_0x5bbfd6('0xb')],[fn(_0x5bbfd6('0x16'),fn('IF',literal(_0x5bbfd6('0x20')))),_0x5bbfd6('0x2f')]],'group':[_0x5bbfd6('0x11')]})['then'](function(_0x78b415){const _0x2a061f=_0x5bbfd6;logger[_0x2a061f('0x26')](_0x2a061f('0x1a'),_0x3dc406),logger[_0x2a061f('0x1')](_0x2a061f('0x1a'),_0x3dc406,JSON[_0x2a061f('0x17')](_0x78b415)),_0x25c26f(_0x78b415);})[_0x5bbfd6('0x29')](function(_0x2759f0){const _0x2d70bb=_0x5bbfd6;logger[_0x2d70bb('0x1c')](_0x2d70bb('0x1a'),_0x2759f0[_0x2d70bb('0x24')],_0x3dc406),_0x54f4fb(_0x18635d[_0x2d70bb('0x1c')](0x1f4,_0x2759f0['message']));});});},exports[_0x343aa7('0x1e')]=function(_0x34c4f6){const _0x49abb7=this;return new Promise(function(_0x130787,_0x108e5a){const _0x45382e=a154_0x3f4b;return db[_0x45382e('0x7')]['findAll']({'raw':_0x34c4f6[_0x45382e('0x27')]?_0x34c4f6[_0x45382e('0x27')][_0x45382e('0x14')]===undefined?!![]:![]:!![],'where':_0x34c4f6[_0x45382e('0x27')]?_0x34c4f6[_0x45382e('0x27')][_0x45382e('0x2c')]||null:null,'attributes':[[_0x45382e('0x11'),_0x45382e('0xc')],[fn(_0x45382e('0x16'),col('id')),_0x45382e('0x4')],[fn(_0x45382e('0x16'),fn('IF',literal('`state`\x20=\x204,\x201,\x20null'))),_0x45382e('0x2e')]],'group':[_0x45382e('0x11')]})[_0x45382e('0x6')](function(_0x5eb3e8){const _0x194aaa=_0x45382e;logger['info'](_0x194aaa('0x1e'),_0x34c4f6),logger[_0x194aaa('0x1')](_0x194aaa('0x1e'),_0x34c4f6,JSON[_0x194aaa('0x17')](_0x5eb3e8)),_0x130787(_0x5eb3e8);})[_0x45382e('0x29')](function(_0x1882d5){const _0x370032=_0x45382e;logger[_0x370032('0x1c')](_0x370032('0x1e'),_0x1882d5[_0x370032('0x24')],_0x34c4f6),_0x108e5a(_0x49abb7[_0x370032('0x1c')](0x1f4,_0x1882d5[_0x370032('0x24')]));});});}; \ No newline at end of file +const a154_0x34dc=['where','`state`\x20=\x204,\x20`talktime`,\x20null','`state`\x20=\x2020,\x201,\x20null','predictiveIntervalDroppedCallsTimeout','raw','debug','`state`\x20=\x2022\x20or\x20`state`\x20=\x2023,\x201,\x20null','info','COUNT','then','outboundDropCallsDayCallersExit','outboundRejectCallsDay','`state`\x20=\x2011,\x201,\x20null','sequelize','catch','campaign','`state`\x20=\x2014,\x201,\x20null','message','predictiveIntervalAvgTalktime','findAll','CreateCmHopperHistory','`state`\x20=\x208,\x201,\x20null','stringify','body','GetCampaignHopperHistory','predictiveIntervalAnsweredCalls','../../mysqldb','../../config/logger','AVG','outboundDropCallsDayTimeout','outboundBusyCallsDay','AvgHandleTime','GetVoiceQueueHopperHistory','outboundNoAnswerCallsDay','`state`\x20=\x204,\x20`holdtime`,\x20null','predictiveIntervalTotalCalls','ivrAnswerCallsDay','predictiveIntervalAvgHoldtime','CmHopperHistory','predictiveIntervalDroppedCallsCallersExit','rpc','name','`state`\x20=\x204,\x201,\x20null','outboundBlacklistCallsDay','`state`\x20=\x2010,\x201,\x20null','ivrTotalCallsDays','`state`\x20=\x2010\x20,\x201,\x20null','outboundOriginateFailureCallsDay','outboundCongestionCallsDay','`state`\x20=\x2016,\x201,\x20null','error','`state`\x20=\x2012,\x201,\x20null','`state`\x20=\x2011\x20,\x201,\x20null','`state`\x20=\x200,\x201,\x20null','options'];(function(_0x10d2fc,_0x34dc12){const _0x4d85c4=function(_0x2f35f8){while(--_0x2f35f8){_0x10d2fc['push'](_0x10d2fc['shift']());}};_0x4d85c4(++_0x34dc12);}(a154_0x34dc,0x64));const a154_0x4d85=function(_0x10d2fc,_0x34dc12){_0x10d2fc=_0x10d2fc-0x0;let _0x4d85c4=a154_0x34dc[_0x10d2fc];return _0x4d85c4;};const _0x276bd8=a154_0x4d85;'use strict';const db=require(_0x276bd8('0x24'))['db'],{fn,literal,col}=require(_0x276bd8('0x17')),logger=require(_0x276bd8('0x25'))(_0x276bd8('0x32'));exports[_0x276bd8('0x1e')]=function(_0x2f35f8){const _0x2aff0f=this;return new Promise(function(_0x3f7e7d,_0x1a8e41){const _0x4e2aa8=a154_0x4d85;return db[_0x4e2aa8('0x30')]['create'](_0x2f35f8[_0x4e2aa8('0x21')],{'raw':_0x2f35f8[_0x4e2aa8('0x9')]?_0x2f35f8[_0x4e2aa8('0x9')][_0x4e2aa8('0xe')]===undefined?!![]:![]:!![]})['then'](function(_0x113b8d){const _0x220211=_0x4e2aa8;logger[_0x220211('0x11')](_0x220211('0x1e'),_0x2f35f8),logger[_0x220211('0xf')](_0x220211('0x1e'),_0x2f35f8,JSON[_0x220211('0x20')](_0x113b8d)),_0x3f7e7d(_0x113b8d);})[_0x4e2aa8('0x18')](function(_0x37a01){const _0x24801e=_0x4e2aa8;logger['error'](_0x24801e('0x1e'),_0x37a01[_0x24801e('0x1b')],_0x2f35f8),_0x1a8e41(_0x2aff0f[_0x24801e('0x5')](0x1f4,_0x37a01['message']));});});},exports[_0x276bd8('0x29')]=function(_0x56e324){const _0x10a75b=this;return new Promise(function(_0x48a84e,_0x504501){const _0x58b44d=a154_0x4d85;return db['CmHopperHistory'][_0x58b44d('0x1d')]({'raw':_0x56e324[_0x58b44d('0x9')]?_0x56e324[_0x58b44d('0x9')][_0x58b44d('0xe')]===undefined?!![]:![]:!![],'where':_0x56e324[_0x58b44d('0x9')]?_0x56e324[_0x58b44d('0x9')]['where']||null:null,'attributes':[[fn(_0x58b44d('0x12'),col('id')),_0x58b44d('0x2d')],[fn(_0x58b44d('0x12'),fn('IF',literal(_0x58b44d('0x34')))),_0x58b44d('0x23')],[fn(_0x58b44d('0x12'),fn('IF',literal(_0x58b44d('0x36')))),_0x58b44d('0xd')],[fn('COUNT',fn('IF',literal(_0x58b44d('0x16')))),_0x58b44d('0x31')],[fn(_0x58b44d('0x26'),fn('IF',literal(_0x58b44d('0x2c')))),_0x58b44d('0x2f')],[fn('AVG',fn('IF',literal(_0x58b44d('0xb')))),_0x58b44d('0x1c')]]})[_0x58b44d('0x13')](function(_0x4bf213){const _0x3c514f=_0x58b44d;logger[_0x3c514f('0x11')](_0x3c514f('0x29'),_0x56e324),logger[_0x3c514f('0xf')]('AvgHandleTime',_0x56e324,JSON[_0x3c514f('0x20')](_0x4bf213)),_0x48a84e(_0x4bf213);})[_0x58b44d('0x18')](function(_0x3def18){const _0x111882=_0x58b44d;logger[_0x111882('0x5')](_0x111882('0x29'),_0x3def18[_0x111882('0x1b')],_0x56e324),_0x504501(_0x10a75b['error'](0x1f4,_0x3def18['message']));});});},exports[_0x276bd8('0x2a')]=function(_0x5d44d8){const _0x5c3e89=this;return new Promise(function(_0x5b687e,_0x18bd4d){const _0x222159=a154_0x4d85;return db[_0x222159('0x30')][_0x222159('0x1d')]({'raw':_0x5d44d8[_0x222159('0x9')]?_0x5d44d8[_0x222159('0x9')][_0x222159('0xe')]===undefined?!![]:![]:!![],'where':_0x5d44d8['options']?_0x5d44d8[_0x222159('0x9')]['where']||null:null,'attributes':[[_0x222159('0x19'),_0x222159('0x33')],[fn('COUNT',fn('IF',literal(_0x222159('0x8')))),'outboundNoSuchCallsDay'],[fn('COUNT',fn('IF',literal('`state`\x20=\x203,\x201,\x20null'))),_0x222159('0x2b')],[fn(_0x222159('0x12'),fn('IF',literal(_0x222159('0x34')))),'outboundAnswerCallsDay'],[fn(_0x222159('0x12'),fn('IF',literal('`state`\x20=\x205,\x201,\x20null'))),_0x222159('0x28')],[fn(_0x222159('0x12'),fn('IF',literal(_0x222159('0x1f')))),_0x222159('0x3')],[fn(_0x222159('0x12'),fn('IF',literal(_0x222159('0x1')))),_0x222159('0x27')],[fn(_0x222159('0x12'),fn('IF',literal(_0x222159('0x7')))),_0x222159('0x14')],[fn(_0x222159('0x12'),fn('IF',literal(_0x222159('0x6')))),'outboundUnknownCallsDay'],[fn(_0x222159('0x12'),fn('IF',literal('`state`\x20=\x2013,\x201,\x20null'))),_0x222159('0x35')],[fn(_0x222159('0x12'),fn('IF',literal(_0x222159('0x1a')))),_0x222159('0x2')],[fn(_0x222159('0x12'),fn('IF',literal('`state`\x20=\x2018,\x201,\x20null'))),_0x222159('0x15')],[fn('COUNT',fn('IF',literal(_0x222159('0x4')))),'outboundAnswerAgiCallsDay'],[fn(_0x222159('0x12'),fn('IF',literal(_0x222159('0xc')))),'outboundRejectCallsDay'],[fn(_0x222159('0x12'),fn('IF',literal(_0x222159('0x10')))),'outboundReCallsDay']],'group':[_0x222159('0x19')]})[_0x222159('0x13')](function(_0x5b0824){const _0x104550=_0x222159;logger['info'](_0x104550('0x2a'),_0x5d44d8),logger[_0x104550('0xf')](_0x104550('0x2a'),_0x5d44d8,JSON[_0x104550('0x20')](_0x5b0824)),_0x5b687e(_0x5b0824);})[_0x222159('0x18')](function(_0x212aa2){const _0x569a8f=_0x222159;logger['error']('GetVoiceQueueHopperHistory',_0x212aa2['message'],_0x5d44d8),_0x18bd4d(_0x5c3e89['error'](0x1f4,_0x212aa2[_0x569a8f('0x1b')]));});});},exports[_0x276bd8('0x22')]=function(_0x194846){const _0x3d1889=this;return new Promise(function(_0x4818e0,_0x7bb464){const _0xfd76c=a154_0x4d85;return db[_0xfd76c('0x30')][_0xfd76c('0x1d')]({'raw':_0x194846[_0xfd76c('0x9')]?_0x194846[_0xfd76c('0x9')][_0xfd76c('0xe')]===undefined?!![]:![]:!![],'where':_0x194846['options']?_0x194846[_0xfd76c('0x9')][_0xfd76c('0xa')]||null:null,'attributes':[[_0xfd76c('0x19'),_0xfd76c('0x33')],[fn('COUNT',col('id')),_0xfd76c('0x0')],[fn(_0xfd76c('0x12'),fn('IF',literal(_0xfd76c('0x34')))),_0xfd76c('0x2e')]],'group':[_0xfd76c('0x19')]})[_0xfd76c('0x13')](function(_0x2e9aa2){const _0x4a96dc=_0xfd76c;logger[_0x4a96dc('0x11')](_0x4a96dc('0x22'),_0x194846),logger['debug'](_0x4a96dc('0x22'),_0x194846,JSON[_0x4a96dc('0x20')](_0x2e9aa2)),_0x4818e0(_0x2e9aa2);})[_0xfd76c('0x18')](function(_0x232a89){const _0x4a4305=_0xfd76c;logger['error'](_0x4a4305('0x22'),_0x232a89[_0x4a4305('0x1b')],_0x194846),_0x7bb464(_0x3d1889['error'](0x1f4,_0x232a89[_0x4a4305('0x1b')]));});});}; \ No newline at end of file diff --git a/server/api/cmHopperHistory/index.js b/server/api/cmHopperHistory/index.js index 9cd5e4a..d4c983b 100644 --- a/server/api/cmHopperHistory/index.js +++ b/server/api/cmHopperHistory/index.js @@ -1 +1 @@ -const a155_0x19a2=['isAuthenticated','express','get','put','../../components/auth/service','Router','update','./cmHopperHistory.controller','create','show','exports'];(function(_0x303b7b,_0x19a2c8){const _0xfb2f11=function(_0x2ffe1d){while(--_0x2ffe1d){_0x303b7b['push'](_0x303b7b['shift']());}};_0xfb2f11(++_0x19a2c8);}(a155_0x19a2,0xd2));const a155_0xfb2f=function(_0x303b7b,_0x19a2c8){_0x303b7b=_0x303b7b-0x0;let _0xfb2f11=a155_0x19a2[_0x303b7b];return _0xfb2f11;};const _0xcfd9b4=a155_0xfb2f;'use strict';const express=require(_0xcfd9b4('0x0')),router=express[_0xcfd9b4('0x4')](),auth=require(_0xcfd9b4('0x3')),controller=require(_0xcfd9b4('0x6'));router[_0xcfd9b4('0x1')]('/',auth[_0xcfd9b4('0xa')](),controller['index']),router[_0xcfd9b4('0x1')]('/describe',auth['isAuthenticated'](),controller['describe']),router[_0xcfd9b4('0x1')]('/:id',auth[_0xcfd9b4('0xa')](),controller[_0xcfd9b4('0x8')]),router['post']('/',auth[_0xcfd9b4('0xa')](),controller[_0xcfd9b4('0x7')]),router[_0xcfd9b4('0x2')]('/:id',auth[_0xcfd9b4('0xa')](),controller[_0xcfd9b4('0x5')]),module[_0xcfd9b4('0x9')]=router; \ No newline at end of file +const a155_0x1be3=['./cmHopperHistory.controller','Router','describe','isAuthenticated','post','create','/:id','get','put','../../components/auth/service','exports','/describe','index'];(function(_0x8f6fdb,_0x1be35c){const _0x9f18f7=function(_0x56b296){while(--_0x56b296){_0x8f6fdb['push'](_0x8f6fdb['shift']());}};_0x9f18f7(++_0x1be35c);}(a155_0x1be3,0x1d7));const a155_0x9f18=function(_0x8f6fdb,_0x1be35c){_0x8f6fdb=_0x8f6fdb-0x0;let _0x9f18f7=a155_0x1be3[_0x8f6fdb];return _0x9f18f7;};const _0x46c18d=a155_0x9f18;'use strict';const express=require('express'),router=express[_0x46c18d('0xb')](),auth=require(_0x46c18d('0x6')),controller=require(_0x46c18d('0xa'));router['get']('/',auth[_0x46c18d('0x0')](),controller[_0x46c18d('0x9')]),router[_0x46c18d('0x4')](_0x46c18d('0x8'),auth[_0x46c18d('0x0')](),controller[_0x46c18d('0xc')]),router['get'](_0x46c18d('0x3'),auth['isAuthenticated'](),controller['show']),router[_0x46c18d('0x1')]('/',auth['isAuthenticated'](),controller[_0x46c18d('0x2')]),router[_0x46c18d('0x5')](_0x46c18d('0x3'),auth[_0x46c18d('0x0')](),controller['update']),module[_0x46c18d('0x7')]=router; \ No newline at end of file diff --git a/server/api/cmList/cmList.attributes.js b/server/api/cmList/cmList.attributes.js index 7e23f17..df16900 100644 --- a/server/api/cmList/cmList.attributes.js +++ b/server/api/cmList/cmList.attributes.js @@ -1 +1 @@ -const a156_0x58a0=['STRING','sequelize','name'];(function(_0x5efeb8,_0x58a073){const _0x10daf4=function(_0x29cb93){while(--_0x29cb93){_0x5efeb8['push'](_0x5efeb8['shift']());}};_0x10daf4(++_0x58a073);}(a156_0x58a0,0xb7));const a156_0x10da=function(_0x5efeb8,_0x58a073){_0x5efeb8=_0x5efeb8-0x0;let _0x10daf4=a156_0x58a0[_0x5efeb8];return _0x10daf4;};const _0x4a7ca6=a156_0x10da;'use strict';const Sequelize=require(_0x4a7ca6('0x1'));module['exports']={'name':{'type':Sequelize[_0x4a7ca6('0x0')],'unique':_0x4a7ca6('0x2'),'allowNull':![],'validate':{'notEmpty':!![]}},'description':{'type':Sequelize['STRING']},'dialPrefix':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a156_0x3950=['name','STRING','exports'];(function(_0x510c7b,_0x39508d){const _0x3f6c67=function(_0x4cf816){while(--_0x4cf816){_0x510c7b['push'](_0x510c7b['shift']());}};_0x3f6c67(++_0x39508d);}(a156_0x3950,0x1e4));const a156_0x3f6c=function(_0x510c7b,_0x39508d){_0x510c7b=_0x510c7b-0x0;let _0x3f6c67=a156_0x3950[_0x510c7b];return _0x3f6c67;};const _0x4968e3=a156_0x3f6c;'use strict';const Sequelize=require('sequelize');module[_0x4968e3('0x1')]={'name':{'type':Sequelize[_0x4968e3('0x0')],'unique':_0x4968e3('0x2'),'allowNull':![],'validate':{'notEmpty':!![]}},'description':{'type':Sequelize[_0x4968e3('0x0')]},'dialPrefix':{'type':Sequelize[_0x4968e3('0x0')]}}; \ No newline at end of file diff --git a/server/api/cmList/cmList.controller.js b/server/api/cmList/cmList.controller.js index a7dec20..df2f5bc 100644 --- a/server/api/cmList/cmList.controller.js +++ b/server/api/cmList/cmList.controller.js @@ -1 +1 @@ -const a157_0x32b4=['describe','getContactsCsv','lodash','text','./cmList.socket','userProfileId','role','get','options','then','includeAll','errors','VIRTUAL','like','TEXT','now','rows','/tmp/list_%d_%s.csv','queryInterface','nolimit','findAll','BOOLEAN','stack','error','dataValues','pick','raw','setHeader','rawAttributes','body','filter','name','params','length','send','catch','fields','register','UserProfileSection','sendStatus','UserProfileResource','json','util','attachment;\x20filename=','type','isArray','addContacts','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','CmCustomField','removeDispositions','userCmList:save','getContacts','fieldName','model','CmContact','number','status','query','getAgents','CmList','filters','isEmpty','attributes','cf_%d','intersection','User','destroy','success','index','Content-type','where','Lists','user','text/csv','writeFileSync','findOne','concat','message','offset','removeAgents','merge','order','cm_contacts','autoAssociation','create','push','Disposition','update','CustomFields','switch','undefined','getDispositions','sequelize','getCustomFields','list_%d_%s.csv','limit','map','Content-Range','format','tags','Malformed\x20request\x20syntax','include','key','ListId','defaultValue','count','addCustomField','download','Unable\x20to\x20retrieve\x20the\x20current\x20user','ids','emit','addAgents','each','Sequelize','sort','omit','Content-disposition','keys','end'];(function(_0x495e5e,_0x32b474){const _0x415079=function(_0x1f377c){while(--_0x1f377c){_0x495e5e['push'](_0x495e5e['shift']());}};_0x415079(++_0x32b474);}(a157_0x32b4,0x71));const a157_0x4150=function(_0x495e5e,_0x32b474){_0x495e5e=_0x495e5e-0x0;let _0x415079=a157_0x32b4[_0x495e5e];return _0x415079;};const _0x57cde2=a157_0x4150;'use strict';const util=require(_0x57cde2('0x30')),fs=require('fs'),_=require(_0x57cde2('0x8')),toCsv=require('to-csv'),{getSocket}=require('../../rediscache'),socket=getSocket(),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x57cde2('0x62'));require(_0x57cde2('0xa'))[_0x57cde2('0x2b')](socket);function respondWithStatusCode(_0x1f377c,_0x5511b7){return _0x5511b7=_0x5511b7||0xcc,function(_0xd46ea8){const _0x51d0f1=a157_0x4150;if(_0xd46ea8)return _0x1f377c[_0x51d0f1('0x2d')](_0x5511b7);return _0x1f377c[_0x51d0f1('0x3e')](_0x5511b7)[_0x51d0f1('0x5')]();};}function respondWithResult(_0x3e8a15,_0x341300){return _0x341300=_0x341300||0xc8,function(_0x1b4173){const _0x5c277b=a157_0x4150;if(_0x1b4173)return _0x3e8a15['status'](_0x341300)[_0x5c277b('0x2f')](_0x1b4173);};}function respondWithFilteredResult(_0x40d48d,_0x5451f0){return function(_0x2cd01c){const _0x3abca4=a157_0x4150;if(_0x2cd01c){const _0x115f9f=_0x2cd01c['count'],_0x56ff98=_0x5451f0[_0x3abca4('0x54')];let _0x2c7252=_0x5451f0['offset']+_0x5451f0[_0x3abca4('0x65')],_0x2f8e09;return _0x2c7252>=_0x115f9f?(_0x2c7252=_0x115f9f,_0x2f8e09=0xc8):_0x2f8e09=0xce,_0x40d48d[_0x3abca4('0x3e')](_0x2f8e09),_0x40d48d['set'](_0x3abca4('0x67'),_0x56ff98+'-'+_0x2c7252+'/'+_0x115f9f)[_0x3abca4('0x2f')](_0x2cd01c);}return null;};}function saveUpdates(_0x13fe72){return function(_0x337df0){const _0x1831bd=a157_0x4150;if(_0x337df0)return _0x337df0[_0x1831bd('0x5d')](_0x13fe72)['then'](function(_0x412da9){return _0x412da9;});return null;};}function removeEntity(_0x4f33ba){return function(_0x3b7d4c){const _0x2d5304=a157_0x4150;if(_0x3b7d4c)return _0x3b7d4c[_0x2d5304('0x48')]()[_0x2d5304('0xf')](function(){const _0x1cd7b0=_0x2d5304,_0xcf5420=_0x3b7d4c['get']({'plain':!![]}),_0x48d108=_0x1cd7b0('0x4d');return db['UserProfileResource']['destroy']({'where':{'type':_0x48d108,'resourceId':_0xcf5420['id']}})[_0x1cd7b0('0xf')](function(){return _0x3b7d4c;});})[_0x2d5304('0xf')](function(){const _0x26c5c2=_0x2d5304;_0x4f33ba[_0x26c5c2('0x3e')](0xcc)[_0x26c5c2('0x5')]();});};}function handleEntityNotFound(_0x4b90db){return function(_0x3fb7bf){return!_0x3fb7bf&&_0x4b90db['sendStatus'](0x194),_0x3fb7bf;};}function handleError(_0x852d37,_0x370eb9){return _0x370eb9=_0x370eb9||0x1f4,function(_0x59ee39){const _0xf45342=a157_0x4150;logger[_0xf45342('0x1d')](_0x59ee39[_0xf45342('0x1c')]),_0x59ee39[_0xf45342('0x25')]&&delete _0x59ee39[_0xf45342('0x25')],_0x852d37[_0xf45342('0x3e')](_0x370eb9)[_0xf45342('0x28')](_0x59ee39);};}exports[_0x57cde2('0x4a')]=function(_0x35ef5c,_0x5d263c){const _0x1c68d4=_0x57cde2;let _0x281862={};const _0x155fad={},_0xffa529={'count':0x0,'rows':[]},_0x236530=_[_0x1c68d4('0x66')](db[_0x1c68d4('0x41')]['rawAttributes'],function(_0x10319c){const _0x1745f4=_0x1c68d4;return{'name':_0x10319c[_0x1745f4('0x3a')],'type':_0x10319c[_0x1745f4('0x32')][_0x1745f4('0x6c')]};});_0x155fad[_0x1c68d4('0x3b')]=_[_0x1c68d4('0x66')](_0x236530,_0x1c68d4('0x25')),_0x155fad[_0x1c68d4('0x3f')]=_[_0x1c68d4('0x4')](_0x35ef5c[_0x1c68d4('0x3f')]),_0x155fad[_0x1c68d4('0x42')]=_[_0x1c68d4('0x46')](_0x155fad[_0x1c68d4('0x3b')],_0x155fad[_0x1c68d4('0x3f')]),_0x281862['attributes']=_[_0x1c68d4('0x46')](_0x155fad[_0x1c68d4('0x3b')],qs['fields'](_0x35ef5c[_0x1c68d4('0x3f')][_0x1c68d4('0x2a')])),_0x281862[_0x1c68d4('0x44')]=_0x281862[_0x1c68d4('0x44')][_0x1c68d4('0x27')]?_0x281862[_0x1c68d4('0x44')]:_0x155fad[_0x1c68d4('0x3b')];typeof _0x35ef5c[_0x1c68d4('0x3f')]['nolimit']===_0x1c68d4('0x60')&&(_0x281862[_0x1c68d4('0x65')]=qs['limit'](_0x35ef5c['query'][_0x1c68d4('0x65')]),_0x281862['offset']=qs['offset'](_0x35ef5c[_0x1c68d4('0x3f')]['offset']));_0x281862[_0x1c68d4('0x57')]=qs[_0x1c68d4('0x1')](_0x35ef5c['query'][_0x1c68d4('0x1')]),_0x281862[_0x1c68d4('0x4c')]=qs[_0x1c68d4('0x42')](_['pick'](_0x35ef5c[_0x1c68d4('0x3f')],_0x155fad[_0x1c68d4('0x42')]),_0x236530);_0x35ef5c[_0x1c68d4('0x3f')][_0x1c68d4('0x24')]&&(_0x281862[_0x1c68d4('0x4c')]=_['merge'](_0x281862['where'],{[Op['or']]:_[_0x1c68d4('0x66')](_0x236530,function(_0x5bffde){const _0x172c55=_0x1c68d4;if(_0x5bffde[_0x172c55('0x32')]!==_0x172c55('0x12')){const _0xcdaf={};return _0xcdaf[_0x5bffde['name']]={[Op[_0x172c55('0x13')]]:'%'+_0x35ef5c['query'][_0x172c55('0x24')]+'%'},_0xcdaf;}})}));_0x281862=_['merge']({},_0x281862,_0x35ef5c['options']);const _0x463c81={'where':_0x281862[_0x1c68d4('0x4c')]};return db[_0x1c68d4('0x41')][_0x1c68d4('0x6f')](_0x463c81)[_0x1c68d4('0xf')](function(_0x40eda1){const _0x48253d=_0x1c68d4;return _0xffa529['count']=_0x40eda1,_0x35ef5c[_0x48253d('0x3f')][_0x48253d('0x10')]&&(_0x281862[_0x48253d('0x6b')]=[{'all':!![]}]),db['CmList'][_0x48253d('0x1a')](_0x281862);})[_0x1c68d4('0xf')](function(_0x4aaad6){const _0x52e545=_0x1c68d4;return _0xffa529[_0x52e545('0x16')]=_0x4aaad6,_0xffa529;})[_0x1c68d4('0xf')](respondWithFilteredResult(_0x5d263c,_0x281862))[_0x1c68d4('0x29')](handleError(_0x5d263c,null));},exports['show']=function(_0xc2c9bb,_0x15f267){const _0x40a8ae=_0x57cde2;let _0x2fff64={'raw':![],'where':{'id':_0xc2c9bb[_0x40a8ae('0x26')]['id']}};const _0x15f8ec={};return _0x15f8ec[_0x40a8ae('0x3b')]=_[_0x40a8ae('0x4')](db[_0x40a8ae('0x41')][_0x40a8ae('0x22')]),_0x15f8ec[_0x40a8ae('0x3f')]=_['keys'](_0xc2c9bb[_0x40a8ae('0x3f')]),_0x15f8ec[_0x40a8ae('0x42')]=_['intersection'](_0x15f8ec['model'],_0x15f8ec[_0x40a8ae('0x3f')]),_0x2fff64[_0x40a8ae('0x44')]=_['intersection'](_0x15f8ec[_0x40a8ae('0x3b')],qs[_0x40a8ae('0x2a')](_0xc2c9bb['query'][_0x40a8ae('0x2a')])),_0x2fff64[_0x40a8ae('0x44')]=_0x2fff64[_0x40a8ae('0x44')][_0x40a8ae('0x27')]?_0x2fff64[_0x40a8ae('0x44')]:_0x15f8ec[_0x40a8ae('0x3b')],_0xc2c9bb[_0x40a8ae('0x3f')][_0x40a8ae('0x10')]&&(_0x2fff64['include']=[{'all':!![]}]),_0x2fff64=_['merge']({},_0x2fff64,_0xc2c9bb[_0x40a8ae('0xe')]),db[_0x40a8ae('0x41')][_0x40a8ae('0x51')](_0x2fff64)[_0x40a8ae('0xf')](handleEntityNotFound(_0x15f267,null))[_0x40a8ae('0xf')](respondWithResult(_0x15f267,null))[_0x40a8ae('0x29')](handleError(_0x15f267,null));},exports['create']=function(_0x39a792,_0x15636e){const _0x384c9c=_0x57cde2;return db[_0x384c9c('0x41')][_0x384c9c('0x5a')](_0x39a792[_0x384c9c('0x23')],{})[_0x384c9c('0xf')](function(_0x38b7e9){const _0x22dc6b=_0x384c9c,_0x2a39cc=_0x39a792[_0x22dc6b('0x4e')][_0x22dc6b('0xd')]({'plain':!![]});if(!_0x2a39cc)throw new Error(_0x22dc6b('0x72'));if(_0x2a39cc[_0x22dc6b('0xc')]===_0x22dc6b('0x4e')){const _0x41eb04=_0x38b7e9[_0x22dc6b('0xd')]({'plain':!![]}),_0x189a96=_0x22dc6b('0x4d');return db[_0x22dc6b('0x2c')][_0x22dc6b('0x51')]({'where':{'name':_0x189a96,'userProfileId':_0x2a39cc[_0x22dc6b('0xb')]},'raw':!![]})[_0x22dc6b('0xf')](function(_0x25106e){const _0x3f3808=_0x22dc6b;return _0x25106e&&_0x25106e[_0x3f3808('0x59')]===0x0?db[_0x3f3808('0x2e')][_0x3f3808('0x5a')]({'name':_0x41eb04[_0x3f3808('0x25')],'resourceId':_0x41eb04['id'],'type':_0x25106e[_0x3f3808('0x25')],'sectionId':_0x25106e['id']},{})['then'](function(){return _0x38b7e9;}):_0x38b7e9;})[_0x22dc6b('0x29')](function(_0x2cb440){const _0x41ce42=_0x22dc6b;logger['error'](_0x41ce42('0x35'),_0x2cb440);throw _0x2cb440;});}return _0x38b7e9;})['then'](respondWithResult(_0x15636e,0xc9))[_0x384c9c('0x29')](handleError(_0x15636e,null));},exports[_0x57cde2('0x5d')]=function(_0x1ecfdc,_0x58bfd1){const _0x50a0c0=_0x57cde2;return _0x1ecfdc[_0x50a0c0('0x23')]['id']&&delete _0x1ecfdc[_0x50a0c0('0x23')]['id'],db['CmList']['findOne']({'where':{'id':_0x1ecfdc[_0x50a0c0('0x26')]['id']}})['then'](handleEntityNotFound(_0x58bfd1,null))[_0x50a0c0('0xf')](saveUpdates(_0x1ecfdc['body'],null))[_0x50a0c0('0xf')](respondWithResult(_0x58bfd1,null))[_0x50a0c0('0x29')](handleError(_0x58bfd1,null));},exports[_0x57cde2('0x48')]=function(_0xa61ef5,_0x5aa688){const _0x21bf03=_0x57cde2;return db['CmList'][_0x21bf03('0x51')]({'where':{'id':_0xa61ef5[_0x21bf03('0x26')]['id']}})[_0x21bf03('0xf')](handleEntityNotFound(_0x5aa688,null))[_0x21bf03('0xf')](removeEntity(_0x5aa688,null))[_0x21bf03('0x29')](handleError(_0x5aa688,null));},exports['describe']=function(_0x5c5111,_0x1f62ce){const _0x2f16c9=_0x57cde2;return db[_0x2f16c9('0x41')][_0x2f16c9('0x6')]()[_0x2f16c9('0xf')](respondWithResult(_0x1f62ce,null))['catch'](handleError(_0x1f62ce,null));},exports['addDisposition']=function(_0x3a4fbc,_0x3a279d){const _0x15e688=_0x57cde2;return _0x3a4fbc['body']['id']&&delete _0x3a4fbc[_0x15e688('0x23')]['id'],db[_0x15e688('0x41')][_0x15e688('0x51')]({'where':{'id':_0x3a4fbc[_0x15e688('0x26')]['id']}})['then'](handleEntityNotFound(_0x3a279d,null))[_0x15e688('0xf')](function(_0x5cfc0f){const _0x3311f9=_0x15e688;if(_0x5cfc0f)return _0x3a4fbc[_0x3311f9('0x23')][_0x3311f9('0x6d')]=_0x5cfc0f['id'],db['Disposition'][_0x3311f9('0x5a')](_0x3a4fbc[_0x3311f9('0x23')]);})[_0x15e688('0xf')](respondWithResult(_0x3a279d,null))['catch'](handleError(_0x3a279d,null));},exports[_0x57cde2('0x61')]=function(_0x56b4da,_0x3ac5e6){const _0x1dcf9d=_0x57cde2;let _0x1f4eca={'raw':![],'where':{}};const _0x22c889={},_0xd4e8a1={'count':0x0,'rows':[]};return db[_0x1dcf9d('0x41')][_0x1dcf9d('0x51')]({'where':{'id':_0x56b4da[_0x1dcf9d('0x26')]['id']}})[_0x1dcf9d('0xf')](handleEntityNotFound(_0x3ac5e6,null))['then'](function(_0x1da593){const _0x1eb6d3=_0x1dcf9d;if(_0x1da593)return _0x22c889[_0x1eb6d3('0x3b')]=_['keys'](db[_0x1eb6d3('0x5c')][_0x1eb6d3('0x22')]),_0x22c889['query']=_[_0x1eb6d3('0x4')](_0x56b4da[_0x1eb6d3('0x3f')]),_0x22c889['filters']=_[_0x1eb6d3('0x46')](_0x22c889[_0x1eb6d3('0x3b')],_0x22c889['query']),_0x1f4eca['attributes']=_['intersection'](_0x22c889['model'],qs[_0x1eb6d3('0x2a')](_0x56b4da[_0x1eb6d3('0x3f')][_0x1eb6d3('0x2a')])),_0x1f4eca[_0x1eb6d3('0x44')]=_0x1f4eca[_0x1eb6d3('0x44')][_0x1eb6d3('0x27')]?_0x1f4eca[_0x1eb6d3('0x44')]:_0x22c889[_0x1eb6d3('0x3b')],typeof _0x56b4da[_0x1eb6d3('0x3f')][_0x1eb6d3('0x19')]==='undefined'&&(_0x1f4eca[_0x1eb6d3('0x65')]=qs['limit'](_0x56b4da[_0x1eb6d3('0x3f')]['limit']),_0x1f4eca[_0x1eb6d3('0x54')]=qs['offset'](_0x56b4da['query']['offset'])),_0x1f4eca[_0x1eb6d3('0x57')]=qs['sort'](_0x56b4da[_0x1eb6d3('0x3f')][_0x1eb6d3('0x1')]),_0x1f4eca['where']=qs[_0x1eb6d3('0x42')](_[_0x1eb6d3('0x1f')](_0x56b4da[_0x1eb6d3('0x3f')],_0x22c889[_0x1eb6d3('0x42')])),_0x1f4eca[_0x1eb6d3('0x4c')][_0x1eb6d3('0x6d')]=_0x1da593['id'],_0x56b4da['query'][_0x1eb6d3('0x24')]&&(_0x1f4eca[_0x1eb6d3('0x4c')]=_[_0x1eb6d3('0x56')](_0x1f4eca[_0x1eb6d3('0x4c')],{[Op['or']]:_[_0x1eb6d3('0x66')](_0x1f4eca['attributes'],function(_0x25c98d){const _0x10c0c9=_0x1eb6d3,_0x1daf75={};return _0x1daf75[_0x25c98d]={[Op[_0x10c0c9('0x13')]]:'%'+_0x56b4da[_0x10c0c9('0x3f')][_0x10c0c9('0x24')]+'%'},_0x1daf75;})})),_0x1f4eca=_[_0x1eb6d3('0x56')]({},_0x1f4eca,_0x56b4da[_0x1eb6d3('0xe')]),db[_0x1eb6d3('0x5c')][_0x1eb6d3('0x6f')]({'where':_0x1f4eca[_0x1eb6d3('0x4c')]})[_0x1eb6d3('0xf')](function(_0x185bf4){const _0x57fd23=_0x1eb6d3;return _0xd4e8a1[_0x57fd23('0x6f')]=_0x185bf4,_0x56b4da[_0x57fd23('0x3f')][_0x57fd23('0x10')]&&(_0x1f4eca['include']=[{'all':!![]}]),db['Disposition'][_0x57fd23('0x1a')](_0x1f4eca);})[_0x1eb6d3('0xf')](function(_0x306961){return _0xd4e8a1['rows']=_0x306961,_0xd4e8a1;});})['then'](respondWithFilteredResult(_0x3ac5e6,_0x1f4eca))[_0x1dcf9d('0x29')](handleError(_0x3ac5e6,null));},exports['removeDispositions']=function(_0x4b59cb,_0x30bb13){const _0x3beedc=_0x57cde2;return db[_0x3beedc('0x41')][_0x3beedc('0x51')]({'where':{'id':_0x4b59cb['params']['id']}})[_0x3beedc('0xf')](handleEntityNotFound(_0x30bb13,null))['then'](function(_0x21ebd5){const _0x35c2b0=_0x3beedc;if(_0x21ebd5)return _0x21ebd5[_0x35c2b0('0x37')](_0x4b59cb[_0x35c2b0('0x3f')]['ids']);})['then'](respondWithStatusCode(_0x30bb13,null))[_0x3beedc('0x29')](handleError(_0x30bb13,null));},exports[_0x57cde2('0x34')]=function(_0x2d8475,_0xdeb139){const _0x1aa7c3=_0x57cde2;return db[_0x1aa7c3('0x41')]['findOne']({'where':{'id':_0x2d8475['params']['id']}})[_0x1aa7c3('0xf')](handleEntityNotFound(_0xdeb139,null))[_0x1aa7c3('0xf')](function(_0x2a2463){const _0x5f3749=_0x1aa7c3;if(_0x2a2463){const _0x4f8553=[],_0x46ed3e={'success':[],'errors':[]};return db['CmContact']['describe']()[_0x5f3749('0xf')](function(_0x296125){const _0x1a6b23=_0x5f3749;_0x2d8475['body']['tags']&&_[_0x1a6b23('0x33')](_0x2d8475[_0x1a6b23('0x23')][_0x1a6b23('0x69')])?_0x2d8475['body']['tags'][_0x1a6b23('0x27')]?_0x2d8475[_0x1a6b23('0x23')][_0x1a6b23('0x69')]=_0x2d8475['body'][_0x1a6b23('0x69')]['join'](';')+';':_0x2d8475[_0x1a6b23('0x23')][_0x1a6b23('0x69')]=null:_0x2d8475['body'][_0x1a6b23('0x69')]=null;if(_0x2d8475[_0x1a6b23('0x23')]&&_[_0x1a6b23('0x33')](_0x2d8475['body'])){for(let _0x1c02c5=0x0;_0x1c02c5<_0x2d8475['body']['length'];_0x1c02c5+=0x1){_0x2d8475['body'][_0x1c02c5][_0x1a6b23('0x6d')]=_0x2d8475['params']['id'],_0x4f8553['push'](_0x2d8475[_0x1a6b23('0x23')][_0x1c02c5]);}return Promise[_0x1a6b23('0x76')](_0x4f8553,function(_0x2038ec){const _0x2ad16d=_0x1a6b23;return db[_0x2ad16d('0x3c')][_0x2ad16d('0x5a')](_['omit'](_0x2038ec,[_0x2ad16d('0x73'),'id'])||{},{'fields':_['keys'](_0x296125),'raw':!![]})[_0x2ad16d('0xf')](function(_0x47d884){const _0x3aeca4=_0x2ad16d;_0x46ed3e[_0x3aeca4('0x49')][_0x3aeca4('0x5b')](_0x47d884[_0x3aeca4('0x1e')]);})['catch'](function(_0x25baaa){const _0x4f9a03=_0x2ad16d;_0x46ed3e[_0x4f9a03('0x11')][_0x4f9a03('0x5b')]({'data':_0x2038ec,'error':_0x25baaa[_0x4f9a03('0x53')]});});})['then'](function(){return _0x46ed3e;})[_0x1a6b23('0x29')](function(_0x39c7d7){return _0x39c7d7;});}else _0xdeb139[_0x1a6b23('0x3e')](0x190)[_0x1a6b23('0x2f')]({'message':_0x1a6b23('0x6a')});});}})[_0x1aa7c3('0xf')](respondWithResult(_0xdeb139,null))[_0x1aa7c3('0x29')](handleError(_0xdeb139,null));},exports[_0x57cde2('0x39')]=function(_0x19c4e0,_0x7ae7d6){const _0xf0ac57=_0x57cde2;let _0x5192c3;return db[_0xf0ac57('0x41')][_0xf0ac57('0x51')]({'where':{'id':_0x19c4e0[_0xf0ac57('0x26')]['id']},'include':[{'model':db[_0xf0ac57('0x36')],'as':_0xf0ac57('0x5e')}]})[_0xf0ac57('0xf')](handleEntityNotFound(_0x7ae7d6,null))[_0xf0ac57('0xf')](function(_0x263e87){const _0x19864e=_0xf0ac57;if(_0x263e87)return _0x5192c3=_0x263e87,db[_0x19864e('0x3c')][_0x19864e('0x22')];})[_0xf0ac57('0xf')](function(_0x362101){const _0x10e653=_0xf0ac57;if(_0x362101){let _0x299f47={};const _0x195808={};return _0x195808['model']=_[_0x10e653('0x52')](_['keys'](_0x362101),_['map'](_0x5192c3[_0x10e653('0x5e')],function(_0x257d2){const _0x4f8249=_0x10e653;return util[_0x4f8249('0x68')](_0x4f8249('0x45'),_0x257d2['id']);})),_0x195808[_0x10e653('0x3f')]=_[_0x10e653('0x4')](_0x19c4e0[_0x10e653('0x3f')]),_0x195808[_0x10e653('0x42')]=_[_0x10e653('0x46')](_0x195808[_0x10e653('0x3b')],_0x195808[_0x10e653('0x3f')]),_0x299f47['attributes']=_[_0x10e653('0x46')](_0x195808[_0x10e653('0x3b')],qs[_0x10e653('0x2a')](_0x19c4e0[_0x10e653('0x3f')][_0x10e653('0x2a')])),_0x299f47['attributes']=_0x299f47[_0x10e653('0x44')]['length']?_0x299f47[_0x10e653('0x44')]:_0x195808['model'],typeof _0x19c4e0[_0x10e653('0x3f')][_0x10e653('0x19')]===_0x10e653('0x60')&&(_0x299f47[_0x10e653('0x65')]=qs['limit'](_0x19c4e0['query'][_0x10e653('0x65')]),_0x299f47[_0x10e653('0x54')]=qs[_0x10e653('0x54')](_0x19c4e0[_0x10e653('0x3f')][_0x10e653('0x54')])),_0x299f47[_0x10e653('0x57')]=qs['sort'](_0x19c4e0['query']['sort']),_0x299f47[_0x10e653('0x4c')]=qs[_0x10e653('0x42')](_[_0x10e653('0x1f')](_0x19c4e0[_0x10e653('0x3f')],_0x195808[_0x10e653('0x42')])),_0x299f47['raw']=!![],_0x19c4e0[_0x10e653('0x3f')]['filter']&&(_0x299f47[_0x10e653('0x4c')]=_[_0x10e653('0x56')](_0x299f47[_0x10e653('0x4c')],{[Op['or']]:_[_0x10e653('0x66')](_0x299f47[_0x10e653('0x44')],function(_0x19f098){const _0x34eacd=_0x10e653,_0x2dacc8={};return _0x2dacc8[_0x19f098]={[Op[_0x34eacd('0x13')]]:'%'+_0x19c4e0[_0x34eacd('0x3f')][_0x34eacd('0x24')]+'%'},_0x2dacc8;})})),_0x299f47=_[_0x10e653('0x56')]({},_0x299f47,_0x19c4e0[_0x10e653('0xe')]),_0x5192c3[_0x10e653('0x39')](_0x299f47);}})['then'](respondWithResult(_0x7ae7d6,null))[_0xf0ac57('0x29')](handleError(_0x7ae7d6,null));},exports[_0x57cde2('0x7')]=function(_0x1378ca,_0x100601){const _0x51c81d=_0x57cde2;let _0x555452;return db['CmList'][_0x51c81d('0x51')]({'where':{'id':_0x1378ca[_0x51c81d('0x26')]['id']},'include':[{'model':db['CmCustomField'],'as':'CustomFields'}]})[_0x51c81d('0xf')](handleEntityNotFound(_0x100601,null))['then'](function(_0x36b523){const _0x410f8b=_0x51c81d;if(_0x36b523)return _0x555452=_0x36b523,db[_0x410f8b('0x3c')]['rawAttributes'];})[_0x51c81d('0xf')](function(_0x5e5c12){const _0x419dec=_0x51c81d;if(_0x5e5c12){let _0x52f525={};const _0x1bc130={};return _0x1bc130[_0x419dec('0x3b')]=_[_0x419dec('0x52')](_[_0x419dec('0x4')](_0x5e5c12),_[_0x419dec('0x66')](_0x555452[_0x419dec('0x5e')],function(_0x42c54b){const _0x2a8d33=_0x419dec;return util[_0x2a8d33('0x68')](_0x2a8d33('0x45'),_0x42c54b['id']);})),_0x1bc130[_0x419dec('0x3f')]=_[_0x419dec('0x4')](_0x1378ca[_0x419dec('0x3f')]),_0x1bc130['filters']=_[_0x419dec('0x46')](_0x1bc130[_0x419dec('0x3b')],_0x1bc130[_0x419dec('0x3f')]),_0x52f525[_0x419dec('0x44')]=_['intersection'](_0x1bc130[_0x419dec('0x3b')],qs[_0x419dec('0x2a')](_0x1378ca['query'][_0x419dec('0x2a')])),_0x52f525[_0x419dec('0x44')]=_0x52f525[_0x419dec('0x44')][_0x419dec('0x27')]?_0x52f525[_0x419dec('0x44')]:_0x1bc130['model'],typeof _0x1378ca['query']['nolimit']===_0x419dec('0x60')&&(_0x52f525['limit']=qs['limit'](_0x1378ca['query'][_0x419dec('0x65')]),_0x52f525['offset']=qs[_0x419dec('0x54')](_0x1378ca[_0x419dec('0x3f')][_0x419dec('0x54')])),_0x52f525['order']=qs[_0x419dec('0x1')](_0x1378ca[_0x419dec('0x3f')][_0x419dec('0x1')]),_0x52f525[_0x419dec('0x4c')]=qs[_0x419dec('0x42')](_[_0x419dec('0x1f')](_0x1378ca['query'],_0x1bc130['filters'])),_0x52f525[_0x419dec('0x20')]=!![],_0x1378ca[_0x419dec('0x3f')][_0x419dec('0x24')]&&(_0x52f525[_0x419dec('0x4c')]=_['merge'](_0x52f525[_0x419dec('0x4c')],{[Op['or']]:_[_0x419dec('0x66')](_0x52f525['attributes'],function(_0x44b75f){const _0x56da1e=_0x419dec,_0x549023={};return _0x549023[_0x44b75f]={[Op[_0x56da1e('0x13')]]:'%'+_0x1378ca[_0x56da1e('0x3f')][_0x56da1e('0x24')]+'%'},_0x549023;})})),_0x52f525=_[_0x419dec('0x56')]({},_0x52f525,_0x1378ca[_0x419dec('0xe')]),_0x555452[_0x419dec('0x39')](_0x52f525);}})[_0x51c81d('0xf')](function(_0x5bf456){const _0x252fca=_0x51c81d;if(!_[_0x252fca('0x43')](_0x5bf456)){const _0x178772=toCsv(_0x5bf456),_0x2a92a6=Date[_0x252fca('0x15')]();return fs[_0x252fca('0x50')](util[_0x252fca('0x68')](_0x252fca('0x17'),_0x555452['id'],_0x2a92a6),_0x178772),_0x100601[_0x252fca('0x21')](_0x252fca('0x3'),_0x252fca('0x31')+util[_0x252fca('0x68')](_0x252fca('0x64'),_0x555452['id'],_0x2a92a6)),_0x100601[_0x252fca('0x21')](_0x252fca('0x4b'),_0x252fca('0x4f')),_0x100601[_0x252fca('0x71')](util[_0x252fca('0x68')](_0x252fca('0x17'),_0x555452['id'],_0x2a92a6));}else return _0x100601[_0x252fca('0x2d')](0xcc);})[_0x51c81d('0x29')](handleError(_0x100601,null));},exports[_0x57cde2('0x70')]=function(_0x4ce179,_0x2d4c70){const _0x5603dc=_0x57cde2;let _0x2f0b57;return delete _0x4ce179[_0x5603dc('0x23')]['id'],db[_0x5603dc('0x41')][_0x5603dc('0x51')]({'where':{'id':_0x4ce179[_0x5603dc('0x26')]['id']}})[_0x5603dc('0xf')](handleEntityNotFound(_0x2d4c70,null))[_0x5603dc('0xf')](function(_0x5e17dc){const _0x31fcd3=_0x5603dc;if(_0x5e17dc)return db[_0x31fcd3('0x62')]['transaction'](function(_0x13bf57){const _0x1c2187=_0x31fcd3;return db[_0x1c2187('0x36')][_0x1c2187('0x5a')](_0x4ce179[_0x1c2187('0x23')],{'transaction':_0x13bf57})[_0x1c2187('0xf')](function(_0x1ac48a){return _0x2f0b57=_0x1ac48a,_0x5e17dc['addCustomFields'](_0x1ac48a,{'transaction':_0x13bf57});})['then'](function(){const _0x4878d0=_0x1c2187,_0x2c9dc7={'type':db[_0x4878d0('0x0')]['TEXT'],'transaction':_0x13bf57};switch(_0x4ce179[_0x4878d0('0x23')][_0x4878d0('0x32')]){case _0x4878d0('0x9'):_0x2c9dc7[_0x4878d0('0x32')]=db[_0x4878d0('0x0')][_0x4878d0('0x14')];break;case _0x4878d0('0x3d'):_0x2c9dc7[_0x4878d0('0x32')]=db['Sequelize']['INTEGER'];break;case _0x4878d0('0x5f'):_0x2c9dc7[_0x4878d0('0x32')]=db[_0x4878d0('0x0')][_0x4878d0('0x1b')],_0x2c9dc7[_0x4878d0('0x6e')]=![];break;default:}return db[_0x4878d0('0x62')][_0x4878d0('0x18')]['addColumn'](_0x4878d0('0x58'),util[_0x4878d0('0x68')]('cf_%s',_0x2f0b57['id']),_0x2c9dc7);})[_0x1c2187('0xf')](function(){return _0x2f0b57;});});})[_0x5603dc('0xf')](respondWithResult(_0x2d4c70,null))['catch'](handleError(_0x2d4c70,null));},exports[_0x57cde2('0x63')]=function(_0x2ca5ac,_0x338b47){const _0x507478=_0x57cde2;let _0x456927={};const _0x22c0f2={};return db[_0x507478('0x41')]['findOne']({'where':{'id':_0x2ca5ac['params']['id']}})[_0x507478('0xf')](handleEntityNotFound(_0x338b47,null))[_0x507478('0xf')](function(_0x5c5633){const _0x178ad0=_0x507478;if(_0x5c5633)return _0x22c0f2[_0x178ad0('0x3b')]=_[_0x178ad0('0x4')](db[_0x178ad0('0x36')][_0x178ad0('0x22')]),_0x22c0f2[_0x178ad0('0x3f')]=_[_0x178ad0('0x4')](_0x2ca5ac[_0x178ad0('0x3f')]),_0x22c0f2[_0x178ad0('0x42')]=_[_0x178ad0('0x46')](_0x22c0f2['model'],_0x22c0f2[_0x178ad0('0x3f')]),_0x456927[_0x178ad0('0x44')]=_['intersection'](_0x22c0f2['model'],qs[_0x178ad0('0x2a')](_0x2ca5ac[_0x178ad0('0x3f')]['fields'])),_0x456927['attributes']=_0x456927[_0x178ad0('0x44')]['length']?_0x456927['attributes']:_0x22c0f2[_0x178ad0('0x3b')],_0x456927[_0x178ad0('0x57')]=qs['sort'](_0x2ca5ac['query'][_0x178ad0('0x1')]),_0x456927[_0x178ad0('0x4c')]=qs[_0x178ad0('0x42')](_[_0x178ad0('0x1f')](_0x2ca5ac['query'],_0x22c0f2[_0x178ad0('0x42')])),_0x456927[_0x178ad0('0x4c')]=_[_0x178ad0('0x56')](_0x456927[_0x178ad0('0x4c')],{[Op['or']]:[{'ListId':_0x5c5633['id']},{'ListId':null}]}),_0x2ca5ac[_0x178ad0('0x3f')][_0x178ad0('0x24')]&&(_0x456927[_0x178ad0('0x4c')]=_[_0x178ad0('0x56')](_0x456927[_0x178ad0('0x4c')],{[Op['or']]:_[_0x178ad0('0x66')](_0x456927[_0x178ad0('0x44')],function(_0xa17d75){const _0x25eadc={};return _0x25eadc[_0xa17d75]={[Op['like']]:'%'+_0x2ca5ac['query']['filter']+'%'},_0x25eadc;})})),_0x456927=_[_0x178ad0('0x56')]({},_0x456927,_0x2ca5ac[_0x178ad0('0xe')]),db[_0x178ad0('0x36')]['findAndCountAll'](_0x456927);})[_0x507478('0xf')](respondWithResult(_0x338b47,null))[_0x507478('0x29')](handleError(_0x338b47,null));},exports[_0x57cde2('0x75')]=function(_0x2be11b,_0x73f81b){const _0x57a713=_0x57cde2;return db[_0x57a713('0x41')][_0x57a713('0x51')]({'where':{'id':_0x2be11b['params']['id']}})['then'](function(_0x1625c6){const _0x42ecb8=_0x57a713;if(_0x1625c6)return _0x1625c6[_0x42ecb8('0x75')](_0x2be11b[_0x42ecb8('0x23')][_0x42ecb8('0x73')],{'through':_[_0x42ecb8('0x2')](_0x2be11b[_0x42ecb8('0x23')],[_0x42ecb8('0x73'),'id'])})[_0x42ecb8('0xf')](function(_0x22f95d){const _0x573fcf=_0x42ecb8;for(let _0x3c29da=0x0;_0x3c29da<_0x2be11b[_0x573fcf('0x23')][_0x573fcf('0x73')]['length'];_0x3c29da+=0x1){socket[_0x573fcf('0x74')](_0x573fcf('0x38'),{'UserId':_0x2be11b[_0x573fcf('0x23')][_0x573fcf('0x73')][_0x3c29da],'CmListId':_0x2be11b[_0x573fcf('0x26')]['id']});}return _0x22f95d;});})['then'](respondWithResult(_0x73f81b,null))[_0x57a713('0x29')](handleError(_0x73f81b,null));},exports[_0x57cde2('0x55')]=function(_0xb0ac11,_0x172193){const _0x286acd=_0x57cde2;return db[_0x286acd('0x41')][_0x286acd('0x51')]({'where':{'id':_0xb0ac11['params']['id']}})[_0x286acd('0xf')](handleEntityNotFound(_0x172193,null))[_0x286acd('0xf')](function(_0x5df569){const _0x270099=_0x286acd;if(_0x5df569)return _0x5df569[_0x270099('0x55')](_0xb0ac11[_0x270099('0x3f')][_0x270099('0x73')])[_0x270099('0xf')](function(){const _0x51e2ec=_0x270099;if(_['isArray'](_0xb0ac11[_0x51e2ec('0x3f')][_0x51e2ec('0x73')]))for(let _0x376461=0x0;_0x376461<_0xb0ac11[_0x51e2ec('0x3f')]['ids'][_0x51e2ec('0x27')];_0x376461+=0x1){socket[_0x51e2ec('0x74')]('userCmList:remove',{'UserId':Number(_0xb0ac11[_0x51e2ec('0x3f')][_0x51e2ec('0x73')][_0x376461]),'CmListId':Number(_0xb0ac11[_0x51e2ec('0x26')]['id'])});}else socket[_0x51e2ec('0x74')]('userCmList:remove',{'UserId':Number(_0xb0ac11[_0x51e2ec('0x3f')][_0x51e2ec('0x73')]),'CmListId':Number(_0xb0ac11['params']['id'])});});})[_0x286acd('0xf')](respondWithStatusCode(_0x172193,null))[_0x286acd('0x29')](handleError(_0x172193,null));},exports['getAgents']=function(_0x4fcbff,_0x4bbdb9){const _0x1684c7=_0x57cde2;let _0x464fd2={};const _0x5be761={};let _0x439c44,_0x45a653;return db[_0x1684c7('0x41')][_0x1684c7('0x51')]({'where':{'id':_0x4fcbff[_0x1684c7('0x26')]['id']}})[_0x1684c7('0xf')](handleEntityNotFound(_0x4bbdb9,null))[_0x1684c7('0xf')](function(_0x1f8d65){const _0x18b2c6=_0x1684c7;if(_0x1f8d65)return _0x439c44=_0x1f8d65,_0x5be761[_0x18b2c6('0x3b')]=_['keys'](db[_0x18b2c6('0x47')]['rawAttributes']),_0x5be761[_0x18b2c6('0x3f')]=_[_0x18b2c6('0x4')](_0x4fcbff[_0x18b2c6('0x3f')]),_0x5be761[_0x18b2c6('0x42')]=_[_0x18b2c6('0x46')](_0x5be761[_0x18b2c6('0x3b')],_0x5be761[_0x18b2c6('0x3f')]),_0x464fd2[_0x18b2c6('0x44')]=_[_0x18b2c6('0x46')](_0x5be761[_0x18b2c6('0x3b')],qs[_0x18b2c6('0x2a')](_0x4fcbff[_0x18b2c6('0x3f')][_0x18b2c6('0x2a')])),_0x464fd2[_0x18b2c6('0x44')]=_0x464fd2[_0x18b2c6('0x44')][_0x18b2c6('0x27')]?_0x464fd2['attributes']:_0x5be761[_0x18b2c6('0x3b')],_0x464fd2['order']=qs[_0x18b2c6('0x1')](_0x4fcbff[_0x18b2c6('0x3f')][_0x18b2c6('0x1')]),_0x464fd2[_0x18b2c6('0x4c')]=qs['filters'](_[_0x18b2c6('0x1f')](_0x4fcbff['query'],_0x5be761['filters'])),_0x4fcbff[_0x18b2c6('0x3f')][_0x18b2c6('0x24')]&&(_0x464fd2[_0x18b2c6('0x4c')]=_[_0x18b2c6('0x56')](_0x464fd2[_0x18b2c6('0x4c')],{[Op['or']]:_['map'](_0x464fd2[_0x18b2c6('0x44')],function(_0x2e1e52){const _0x20c288=_0x18b2c6,_0x1e1e5f={};return _0x1e1e5f[_0x2e1e52]={[Op[_0x20c288('0x13')]]:'%'+_0x4fcbff[_0x20c288('0x3f')][_0x20c288('0x24')]+'%'},_0x1e1e5f;})})),_0x464fd2=_[_0x18b2c6('0x56')]({},_0x464fd2,_0x4fcbff[_0x18b2c6('0xe')]),_0x439c44[_0x18b2c6('0x40')](_0x464fd2);})[_0x1684c7('0xf')](function(_0x1de123){const _0x6596e5=_0x1684c7;if(_0x1de123)return _0x45a653=_0x1de123['length'],typeof _0x4fcbff[_0x6596e5('0x3f')][_0x6596e5('0x19')]==='undefined'&&(_0x464fd2['limit']=qs[_0x6596e5('0x65')](_0x4fcbff[_0x6596e5('0x3f')][_0x6596e5('0x65')]),_0x464fd2[_0x6596e5('0x54')]=qs['offset'](_0x4fcbff[_0x6596e5('0x3f')][_0x6596e5('0x54')])),_0x439c44['getAgents'](_0x464fd2);})[_0x1684c7('0xf')](function(_0x53e023){if(_0x53e023)return _0x53e023?{'count':_0x45a653,'rows':_0x53e023}:null;})['then'](respondWithResult(_0x4bbdb9,null))[_0x1684c7('0x29')](handleError(_0x4bbdb9,null));}; \ No newline at end of file +const a157_0x549d=['cm_contacts','fieldName','autoAssociation','VIRTUAL','../../rediscache','addContacts','ids','Content-Range','download','switch','order','sort','INTEGER','intersection','user','./cmList.socket','removeDispositions','include','userCmList:remove','nolimit','model','type','addColumn','cf_%d','map','merge','dataValues','addCustomFields','Malformed\x20request\x20syntax','rawAttributes','getAgents','like','writeFileSync','create','errors','getContacts','filter','findAll','UserProfileResource','status','where','count','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','CmContact','attachment;\x20filename=','destroy','show','fields','emit','stack','role','format','set','error','text','UserProfileSection','getCustomFields','isEmpty','Lists','to-csv','update','limit','util','body','number','findOne','addAgents','name','offset','filters','Unable\x20to\x20retrieve\x20the\x20current\x20user','undefined','raw','rows','push','defaultValue','omit','catch','json','sequelize','cf_%s','api','join','keys','send','length','tags','concat','describe','options','attributes','isArray','params','CmList','get','sendStatus','CmCustomField','setHeader','removeAgents','then','Sequelize','pick','success','CustomFields','lodash','text/csv','Disposition','ListId','transaction','/tmp/list_%d_%s.csv','includeAll','query','Content-type','User'];(function(_0x4fa610,_0x549d54){const _0x4ad813=function(_0x44823a){while(--_0x44823a){_0x4fa610['push'](_0x4fa610['shift']());}};_0x4ad813(++_0x549d54);}(a157_0x549d,0x80));const a157_0x4ad8=function(_0x4fa610,_0x549d54){_0x4fa610=_0x4fa610-0x0;let _0x4ad813=a157_0x549d[_0x4fa610];return _0x4ad813;};const _0x11abdc=a157_0x4ad8;'use strict';const util=require(_0x11abdc('0x30')),fs=require('fs'),_=require(_0x11abdc('0x5a')),toCsv=require(_0x11abdc('0x2d')),{getSocket}=require(_0x11abdc('0x68')),socket=getSocket(),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x11abdc('0x43')),db=require('../../mysqldb')['db'],{Op}=require(_0x11abdc('0x41'));require(_0x11abdc('0x1'))['register'](socket);function respondWithStatusCode(_0x44823a,_0x4e2d88){return _0x4e2d88=_0x4e2d88||0xcc,function(_0x554c91){const _0x2e2b1a=a157_0x4ad8;if(_0x554c91)return _0x44823a[_0x2e2b1a('0x51')](_0x4e2d88);return _0x44823a['status'](_0x4e2d88)['end']();};}function respondWithResult(_0x5930cb,_0x36a329){return _0x36a329=_0x36a329||0xc8,function(_0x4dd2d1){const _0x5e1a80=a157_0x4ad8;if(_0x4dd2d1)return _0x5930cb[_0x5e1a80('0x19')](_0x36a329)['json'](_0x4dd2d1);};}function respondWithFilteredResult(_0x493eb5,_0x5e2d1d){return function(_0x4754da){const _0x2a3195=a157_0x4ad8;if(_0x4754da){const _0x24a32e=_0x4754da['count'],_0xd8a1cc=_0x5e2d1d['offset'];let _0x4a1414=_0x5e2d1d[_0x2a3195('0x36')]+_0x5e2d1d[_0x2a3195('0x2f')],_0x5d3c74;return _0x4a1414>=_0x24a32e?(_0x4a1414=_0x24a32e,_0x5d3c74=0xc8):_0x5d3c74=0xce,_0x493eb5[_0x2a3195('0x19')](_0x5d3c74),_0x493eb5[_0x2a3195('0x26')](_0x2a3195('0x6b'),_0xd8a1cc+'-'+_0x4a1414+'/'+_0x24a32e)[_0x2a3195('0x40')](_0x4754da);}return null;};}function saveUpdates(_0x8f6d40){return function(_0x49e083){const _0x3b9a34=a157_0x4ad8;if(_0x49e083)return _0x49e083[_0x3b9a34('0x2e')](_0x8f6d40)[_0x3b9a34('0x55')](function(_0x497258){return _0x497258;});return null;};}function removeEntity(_0x1b632a){return function(_0x5e5ec9){const _0x4c415b=a157_0x4ad8;if(_0x5e5ec9)return _0x5e5ec9[_0x4c415b('0x1f')]()[_0x4c415b('0x55')](function(){const _0x1af3b5=_0x4c415b,_0x5bbd22=_0x5e5ec9['get']({'plain':!![]}),_0x4ffcdb=_0x1af3b5('0x2c');return db[_0x1af3b5('0x18')][_0x1af3b5('0x1f')]({'where':{'type':_0x4ffcdb,'resourceId':_0x5bbd22['id']}})[_0x1af3b5('0x55')](function(){return _0x5e5ec9;});})['then'](function(){const _0x371560=_0x4c415b;_0x1b632a[_0x371560('0x19')](0xcc)['end']();});};}function handleEntityNotFound(_0x349d4a){return function(_0x4b4616){const _0x5905d9=a157_0x4ad8;return!_0x4b4616&&_0x349d4a[_0x5905d9('0x51')](0x194),_0x4b4616;};}function handleError(_0x58bf49,_0x485008){return _0x485008=_0x485008||0x1f4,function(_0x3d9066){const _0x5772fb=a157_0x4ad8;logger[_0x5772fb('0x27')](_0x3d9066[_0x5772fb('0x23')]),_0x3d9066[_0x5772fb('0x35')]&&delete _0x3d9066['name'],_0x58bf49[_0x5772fb('0x19')](_0x485008)[_0x5772fb('0x46')](_0x3d9066);};}exports['index']=function(_0x4d2e0e,_0x3bd080){const _0x7f88a=_0x11abdc;let _0x5e122b={};const _0x34b82c={},_0x28a7e4={'count':0x0,'rows':[]},_0x5d10c1=_[_0x7f88a('0xa')](db[_0x7f88a('0x4f')][_0x7f88a('0xf')],function(_0x1b810f){const _0x2362bc=_0x7f88a;return{'name':_0x1b810f[_0x2362bc('0x65')],'type':_0x1b810f[_0x2362bc('0x7')]['key']};});_0x34b82c['model']=_[_0x7f88a('0xa')](_0x5d10c1,_0x7f88a('0x35')),_0x34b82c[_0x7f88a('0x61')]=_['keys'](_0x4d2e0e[_0x7f88a('0x61')]),_0x34b82c[_0x7f88a('0x37')]=_[_0x7f88a('0x71')](_0x34b82c[_0x7f88a('0x6')],_0x34b82c[_0x7f88a('0x61')]),_0x5e122b['attributes']=_[_0x7f88a('0x71')](_0x34b82c['model'],qs['fields'](_0x4d2e0e[_0x7f88a('0x61')][_0x7f88a('0x21')])),_0x5e122b[_0x7f88a('0x4c')]=_0x5e122b[_0x7f88a('0x4c')]['length']?_0x5e122b[_0x7f88a('0x4c')]:_0x34b82c[_0x7f88a('0x6')];typeof _0x4d2e0e['query'][_0x7f88a('0x5')]==='undefined'&&(_0x5e122b[_0x7f88a('0x2f')]=qs[_0x7f88a('0x2f')](_0x4d2e0e['query'][_0x7f88a('0x2f')]),_0x5e122b[_0x7f88a('0x36')]=qs[_0x7f88a('0x36')](_0x4d2e0e['query'][_0x7f88a('0x36')]));_0x5e122b['order']=qs['sort'](_0x4d2e0e[_0x7f88a('0x61')]['sort']),_0x5e122b[_0x7f88a('0x1a')]=qs['filters'](_[_0x7f88a('0x57')](_0x4d2e0e['query'],_0x34b82c['filters']),_0x5d10c1);_0x4d2e0e[_0x7f88a('0x61')][_0x7f88a('0x16')]&&(_0x5e122b[_0x7f88a('0x1a')]=_[_0x7f88a('0xb')](_0x5e122b['where'],{[Op['or']]:_[_0x7f88a('0xa')](_0x5d10c1,function(_0x11b8e2){const _0x1f38ab=_0x7f88a;if(_0x11b8e2[_0x1f38ab('0x7')]!==_0x1f38ab('0x67')){const _0xd0d6a1={};return _0xd0d6a1[_0x11b8e2['name']]={[Op['like']]:'%'+_0x4d2e0e[_0x1f38ab('0x61')]['filter']+'%'},_0xd0d6a1;}})}));_0x5e122b=_[_0x7f88a('0xb')]({},_0x5e122b,_0x4d2e0e[_0x7f88a('0x4b')]);const _0x15d6ec={'where':_0x5e122b[_0x7f88a('0x1a')]};return db[_0x7f88a('0x4f')][_0x7f88a('0x1b')](_0x15d6ec)[_0x7f88a('0x55')](function(_0x1cb89a){const _0x2e1b87=_0x7f88a;return _0x28a7e4['count']=_0x1cb89a,_0x4d2e0e['query'][_0x2e1b87('0x60')]&&(_0x5e122b[_0x2e1b87('0x3')]=[{'all':!![]}]),db['CmList'][_0x2e1b87('0x17')](_0x5e122b);})['then'](function(_0x2456f0){const _0x5ebbec=_0x7f88a;return _0x28a7e4[_0x5ebbec('0x3b')]=_0x2456f0,_0x28a7e4;})[_0x7f88a('0x55')](respondWithFilteredResult(_0x3bd080,_0x5e122b))[_0x7f88a('0x3f')](handleError(_0x3bd080,null));},exports[_0x11abdc('0x20')]=function(_0x4b5b6d,_0x38687d){const _0x5ac6ac=_0x11abdc;let _0x2030b9={'raw':![],'where':{'id':_0x4b5b6d[_0x5ac6ac('0x4e')]['id']}};const _0x1344cd={};return _0x1344cd['model']=_['keys'](db[_0x5ac6ac('0x4f')][_0x5ac6ac('0xf')]),_0x1344cd[_0x5ac6ac('0x61')]=_[_0x5ac6ac('0x45')](_0x4b5b6d[_0x5ac6ac('0x61')]),_0x1344cd[_0x5ac6ac('0x37')]=_[_0x5ac6ac('0x71')](_0x1344cd[_0x5ac6ac('0x6')],_0x1344cd[_0x5ac6ac('0x61')]),_0x2030b9[_0x5ac6ac('0x4c')]=_[_0x5ac6ac('0x71')](_0x1344cd[_0x5ac6ac('0x6')],qs[_0x5ac6ac('0x21')](_0x4b5b6d[_0x5ac6ac('0x61')][_0x5ac6ac('0x21')])),_0x2030b9[_0x5ac6ac('0x4c')]=_0x2030b9['attributes'][_0x5ac6ac('0x47')]?_0x2030b9['attributes']:_0x1344cd['model'],_0x4b5b6d[_0x5ac6ac('0x61')][_0x5ac6ac('0x60')]&&(_0x2030b9[_0x5ac6ac('0x3')]=[{'all':!![]}]),_0x2030b9=_[_0x5ac6ac('0xb')]({},_0x2030b9,_0x4b5b6d[_0x5ac6ac('0x4b')]),db[_0x5ac6ac('0x4f')][_0x5ac6ac('0x33')](_0x2030b9)[_0x5ac6ac('0x55')](handleEntityNotFound(_0x38687d,null))[_0x5ac6ac('0x55')](respondWithResult(_0x38687d,null))[_0x5ac6ac('0x3f')](handleError(_0x38687d,null));},exports[_0x11abdc('0x13')]=function(_0x529f1f,_0x10f4c8){const _0x2dc2de=_0x11abdc;return db[_0x2dc2de('0x4f')][_0x2dc2de('0x13')](_0x529f1f['body'],{})[_0x2dc2de('0x55')](function(_0x1b24fb){const _0x54ecf4=_0x2dc2de,_0x346412=_0x529f1f[_0x54ecf4('0x0')][_0x54ecf4('0x50')]({'plain':!![]});if(!_0x346412)throw new Error(_0x54ecf4('0x38'));if(_0x346412[_0x54ecf4('0x24')]===_0x54ecf4('0x0')){const _0x5bf4b5=_0x1b24fb['get']({'plain':!![]}),_0x205f24=_0x54ecf4('0x2c');return db[_0x54ecf4('0x29')]['findOne']({'where':{'name':_0x205f24,'userProfileId':_0x346412['userProfileId']},'raw':!![]})[_0x54ecf4('0x55')](function(_0x28c6f4){const _0x1d112a=_0x54ecf4;return _0x28c6f4&&_0x28c6f4[_0x1d112a('0x66')]===0x0?db[_0x1d112a('0x18')]['create']({'name':_0x5bf4b5[_0x1d112a('0x35')],'resourceId':_0x5bf4b5['id'],'type':_0x28c6f4[_0x1d112a('0x35')],'sectionId':_0x28c6f4['id']},{})[_0x1d112a('0x55')](function(){return _0x1b24fb;}):_0x1b24fb;})[_0x54ecf4('0x3f')](function(_0x53b365){const _0x2ce8c5=_0x54ecf4;logger[_0x2ce8c5('0x27')](_0x2ce8c5('0x1c'),_0x53b365);throw _0x53b365;});}return _0x1b24fb;})[_0x2dc2de('0x55')](respondWithResult(_0x10f4c8,0xc9))['catch'](handleError(_0x10f4c8,null));},exports[_0x11abdc('0x2e')]=function(_0x416240,_0x1a5ff2){const _0x3da3ff=_0x11abdc;return _0x416240[_0x3da3ff('0x31')]['id']&&delete _0x416240[_0x3da3ff('0x31')]['id'],db[_0x3da3ff('0x4f')][_0x3da3ff('0x33')]({'where':{'id':_0x416240[_0x3da3ff('0x4e')]['id']}})[_0x3da3ff('0x55')](handleEntityNotFound(_0x1a5ff2,null))[_0x3da3ff('0x55')](saveUpdates(_0x416240[_0x3da3ff('0x31')],null))[_0x3da3ff('0x55')](respondWithResult(_0x1a5ff2,null))['catch'](handleError(_0x1a5ff2,null));},exports[_0x11abdc('0x1f')]=function(_0x50cb16,_0x28bb20){const _0x3b9263=_0x11abdc;return db[_0x3b9263('0x4f')][_0x3b9263('0x33')]({'where':{'id':_0x50cb16[_0x3b9263('0x4e')]['id']}})[_0x3b9263('0x55')](handleEntityNotFound(_0x28bb20,null))['then'](removeEntity(_0x28bb20,null))[_0x3b9263('0x3f')](handleError(_0x28bb20,null));},exports[_0x11abdc('0x4a')]=function(_0x4f8969,_0x3ee2d8){const _0x28221a=_0x11abdc;return db['CmList'][_0x28221a('0x4a')]()[_0x28221a('0x55')](respondWithResult(_0x3ee2d8,null))[_0x28221a('0x3f')](handleError(_0x3ee2d8,null));},exports['addDisposition']=function(_0x255454,_0x56697c){const _0x3e3419=_0x11abdc;return _0x255454[_0x3e3419('0x31')]['id']&&delete _0x255454[_0x3e3419('0x31')]['id'],db[_0x3e3419('0x4f')][_0x3e3419('0x33')]({'where':{'id':_0x255454['params']['id']}})[_0x3e3419('0x55')](handleEntityNotFound(_0x56697c,null))[_0x3e3419('0x55')](function(_0x4ebaf3){const _0x591cae=_0x3e3419;if(_0x4ebaf3)return _0x255454['body'][_0x591cae('0x5d')]=_0x4ebaf3['id'],db['Disposition'][_0x591cae('0x13')](_0x255454[_0x591cae('0x31')]);})['then'](respondWithResult(_0x56697c,null))[_0x3e3419('0x3f')](handleError(_0x56697c,null));},exports['getDispositions']=function(_0x4bf870,_0x2acbb6){const _0x5ba61c=_0x11abdc;let _0xdbd6f1={'raw':![],'where':{}};const _0x3d220c={},_0x5c3a8d={'count':0x0,'rows':[]};return db[_0x5ba61c('0x4f')][_0x5ba61c('0x33')]({'where':{'id':_0x4bf870[_0x5ba61c('0x4e')]['id']}})[_0x5ba61c('0x55')](handleEntityNotFound(_0x2acbb6,null))[_0x5ba61c('0x55')](function(_0xab6430){const _0x32a0c1=_0x5ba61c;if(_0xab6430)return _0x3d220c[_0x32a0c1('0x6')]=_[_0x32a0c1('0x45')](db['Disposition'][_0x32a0c1('0xf')]),_0x3d220c[_0x32a0c1('0x61')]=_[_0x32a0c1('0x45')](_0x4bf870[_0x32a0c1('0x61')]),_0x3d220c[_0x32a0c1('0x37')]=_[_0x32a0c1('0x71')](_0x3d220c[_0x32a0c1('0x6')],_0x3d220c[_0x32a0c1('0x61')]),_0xdbd6f1[_0x32a0c1('0x4c')]=_[_0x32a0c1('0x71')](_0x3d220c[_0x32a0c1('0x6')],qs['fields'](_0x4bf870[_0x32a0c1('0x61')][_0x32a0c1('0x21')])),_0xdbd6f1[_0x32a0c1('0x4c')]=_0xdbd6f1[_0x32a0c1('0x4c')][_0x32a0c1('0x47')]?_0xdbd6f1[_0x32a0c1('0x4c')]:_0x3d220c[_0x32a0c1('0x6')],typeof _0x4bf870['query'][_0x32a0c1('0x5')]===_0x32a0c1('0x39')&&(_0xdbd6f1[_0x32a0c1('0x2f')]=qs[_0x32a0c1('0x2f')](_0x4bf870[_0x32a0c1('0x61')][_0x32a0c1('0x2f')]),_0xdbd6f1['offset']=qs[_0x32a0c1('0x36')](_0x4bf870[_0x32a0c1('0x61')][_0x32a0c1('0x36')])),_0xdbd6f1[_0x32a0c1('0x6e')]=qs[_0x32a0c1('0x6f')](_0x4bf870[_0x32a0c1('0x61')][_0x32a0c1('0x6f')]),_0xdbd6f1[_0x32a0c1('0x1a')]=qs[_0x32a0c1('0x37')](_['pick'](_0x4bf870[_0x32a0c1('0x61')],_0x3d220c[_0x32a0c1('0x37')])),_0xdbd6f1[_0x32a0c1('0x1a')][_0x32a0c1('0x5d')]=_0xab6430['id'],_0x4bf870[_0x32a0c1('0x61')][_0x32a0c1('0x16')]&&(_0xdbd6f1['where']=_['merge'](_0xdbd6f1[_0x32a0c1('0x1a')],{[Op['or']]:_[_0x32a0c1('0xa')](_0xdbd6f1[_0x32a0c1('0x4c')],function(_0x42e7e9){const _0x118e86=_0x32a0c1,_0x519cc5={};return _0x519cc5[_0x42e7e9]={[Op[_0x118e86('0x11')]]:'%'+_0x4bf870[_0x118e86('0x61')][_0x118e86('0x16')]+'%'},_0x519cc5;})})),_0xdbd6f1=_[_0x32a0c1('0xb')]({},_0xdbd6f1,_0x4bf870['options']),db[_0x32a0c1('0x5c')][_0x32a0c1('0x1b')]({'where':_0xdbd6f1['where']})[_0x32a0c1('0x55')](function(_0x408268){const _0x1e2ab2=_0x32a0c1;return _0x5c3a8d[_0x1e2ab2('0x1b')]=_0x408268,_0x4bf870[_0x1e2ab2('0x61')][_0x1e2ab2('0x60')]&&(_0xdbd6f1['include']=[{'all':!![]}]),db['Disposition'][_0x1e2ab2('0x17')](_0xdbd6f1);})[_0x32a0c1('0x55')](function(_0x253b52){const _0x38212c=_0x32a0c1;return _0x5c3a8d[_0x38212c('0x3b')]=_0x253b52,_0x5c3a8d;});})['then'](respondWithFilteredResult(_0x2acbb6,_0xdbd6f1))[_0x5ba61c('0x3f')](handleError(_0x2acbb6,null));},exports[_0x11abdc('0x2')]=function(_0x392a8d,_0x41b1c8){const _0x14df04=_0x11abdc;return db[_0x14df04('0x4f')][_0x14df04('0x33')]({'where':{'id':_0x392a8d['params']['id']}})[_0x14df04('0x55')](handleEntityNotFound(_0x41b1c8,null))['then'](function(_0x1fcab9){const _0x366d59=_0x14df04;if(_0x1fcab9)return _0x1fcab9['removeDispositions'](_0x392a8d[_0x366d59('0x61')][_0x366d59('0x6a')]);})['then'](respondWithStatusCode(_0x41b1c8,null))['catch'](handleError(_0x41b1c8,null));},exports[_0x11abdc('0x69')]=function(_0x2f3271,_0x5c3de7){const _0x304a89=_0x11abdc;return db[_0x304a89('0x4f')]['findOne']({'where':{'id':_0x2f3271[_0x304a89('0x4e')]['id']}})[_0x304a89('0x55')](handleEntityNotFound(_0x5c3de7,null))[_0x304a89('0x55')](function(_0x1d47aa){const _0x2aae9a=_0x304a89;if(_0x1d47aa){const _0x7c018d=[],_0x5e29b3={'success':[],'errors':[]};return db[_0x2aae9a('0x1d')][_0x2aae9a('0x4a')]()[_0x2aae9a('0x55')](function(_0x22173a){const _0x2f3c43=_0x2aae9a;_0x2f3271[_0x2f3c43('0x31')][_0x2f3c43('0x48')]&&_[_0x2f3c43('0x4d')](_0x2f3271[_0x2f3c43('0x31')][_0x2f3c43('0x48')])?_0x2f3271[_0x2f3c43('0x31')]['tags']['length']?_0x2f3271[_0x2f3c43('0x31')]['tags']=_0x2f3271['body'][_0x2f3c43('0x48')][_0x2f3c43('0x44')](';')+';':_0x2f3271[_0x2f3c43('0x31')]['tags']=null:_0x2f3271[_0x2f3c43('0x31')][_0x2f3c43('0x48')]=null;if(_0x2f3271[_0x2f3c43('0x31')]&&_[_0x2f3c43('0x4d')](_0x2f3271[_0x2f3c43('0x31')])){for(let _0x2145f2=0x0;_0x2145f2<_0x2f3271[_0x2f3c43('0x31')][_0x2f3c43('0x47')];_0x2145f2+=0x1){_0x2f3271['body'][_0x2145f2][_0x2f3c43('0x5d')]=_0x2f3271[_0x2f3c43('0x4e')]['id'],_0x7c018d['push'](_0x2f3271[_0x2f3c43('0x31')][_0x2145f2]);}return Promise['each'](_0x7c018d,function(_0x566c1a){const _0xdeb384=_0x2f3c43;return db[_0xdeb384('0x1d')][_0xdeb384('0x13')](_['omit'](_0x566c1a,[_0xdeb384('0x6a'),'id'])||{},{'fields':_[_0xdeb384('0x45')](_0x22173a),'raw':!![]})[_0xdeb384('0x55')](function(_0x4eca31){const _0x20c2c9=_0xdeb384;_0x5e29b3[_0x20c2c9('0x58')][_0x20c2c9('0x3c')](_0x4eca31[_0x20c2c9('0xc')]);})[_0xdeb384('0x3f')](function(_0x3c7436){const _0xf3194=_0xdeb384;_0x5e29b3[_0xf3194('0x14')][_0xf3194('0x3c')]({'data':_0x566c1a,'error':_0x3c7436['message']});});})[_0x2f3c43('0x55')](function(){return _0x5e29b3;})[_0x2f3c43('0x3f')](function(_0x3bf41f){return _0x3bf41f;});}else _0x5c3de7[_0x2f3c43('0x19')](0x190)['json']({'message':_0x2f3c43('0xe')});});}})[_0x304a89('0x55')](respondWithResult(_0x5c3de7,null))[_0x304a89('0x3f')](handleError(_0x5c3de7,null));},exports[_0x11abdc('0x15')]=function(_0x5eb52e,_0x5c0d83){const _0x4c03c8=_0x11abdc;let _0x46c924;return db[_0x4c03c8('0x4f')][_0x4c03c8('0x33')]({'where':{'id':_0x5eb52e[_0x4c03c8('0x4e')]['id']},'include':[{'model':db[_0x4c03c8('0x52')],'as':_0x4c03c8('0x59')}]})[_0x4c03c8('0x55')](handleEntityNotFound(_0x5c0d83,null))[_0x4c03c8('0x55')](function(_0x3ff955){const _0x29f37a=_0x4c03c8;if(_0x3ff955)return _0x46c924=_0x3ff955,db[_0x29f37a('0x1d')]['rawAttributes'];})['then'](function(_0x43897d){const _0x5299d6=_0x4c03c8;if(_0x43897d){let _0x2e7200={};const _0x37e661={};return _0x37e661['model']=_[_0x5299d6('0x49')](_[_0x5299d6('0x45')](_0x43897d),_[_0x5299d6('0xa')](_0x46c924[_0x5299d6('0x59')],function(_0x5d8e31){const _0x5923e2=_0x5299d6;return util['format'](_0x5923e2('0x9'),_0x5d8e31['id']);})),_0x37e661['query']=_[_0x5299d6('0x45')](_0x5eb52e[_0x5299d6('0x61')]),_0x37e661[_0x5299d6('0x37')]=_[_0x5299d6('0x71')](_0x37e661[_0x5299d6('0x6')],_0x37e661[_0x5299d6('0x61')]),_0x2e7200[_0x5299d6('0x4c')]=_['intersection'](_0x37e661['model'],qs['fields'](_0x5eb52e['query'][_0x5299d6('0x21')])),_0x2e7200['attributes']=_0x2e7200[_0x5299d6('0x4c')][_0x5299d6('0x47')]?_0x2e7200[_0x5299d6('0x4c')]:_0x37e661[_0x5299d6('0x6')],typeof _0x5eb52e[_0x5299d6('0x61')][_0x5299d6('0x5')]===_0x5299d6('0x39')&&(_0x2e7200[_0x5299d6('0x2f')]=qs['limit'](_0x5eb52e[_0x5299d6('0x61')]['limit']),_0x2e7200[_0x5299d6('0x36')]=qs[_0x5299d6('0x36')](_0x5eb52e[_0x5299d6('0x61')][_0x5299d6('0x36')])),_0x2e7200[_0x5299d6('0x6e')]=qs['sort'](_0x5eb52e[_0x5299d6('0x61')][_0x5299d6('0x6f')]),_0x2e7200[_0x5299d6('0x1a')]=qs[_0x5299d6('0x37')](_[_0x5299d6('0x57')](_0x5eb52e[_0x5299d6('0x61')],_0x37e661[_0x5299d6('0x37')])),_0x2e7200[_0x5299d6('0x3a')]=!![],_0x5eb52e[_0x5299d6('0x61')][_0x5299d6('0x16')]&&(_0x2e7200[_0x5299d6('0x1a')]=_[_0x5299d6('0xb')](_0x2e7200[_0x5299d6('0x1a')],{[Op['or']]:_['map'](_0x2e7200[_0x5299d6('0x4c')],function(_0x413cd8){const _0x12223c=_0x5299d6,_0x270c90={};return _0x270c90[_0x413cd8]={[Op[_0x12223c('0x11')]]:'%'+_0x5eb52e[_0x12223c('0x61')][_0x12223c('0x16')]+'%'},_0x270c90;})})),_0x2e7200=_[_0x5299d6('0xb')]({},_0x2e7200,_0x5eb52e[_0x5299d6('0x4b')]),_0x46c924[_0x5299d6('0x15')](_0x2e7200);}})[_0x4c03c8('0x55')](respondWithResult(_0x5c0d83,null))[_0x4c03c8('0x3f')](handleError(_0x5c0d83,null));},exports['getContactsCsv']=function(_0xfbbe61,_0x19016e){const _0x27c870=_0x11abdc;let _0x347e12;return db[_0x27c870('0x4f')][_0x27c870('0x33')]({'where':{'id':_0xfbbe61[_0x27c870('0x4e')]['id']},'include':[{'model':db['CmCustomField'],'as':'CustomFields'}]})[_0x27c870('0x55')](handleEntityNotFound(_0x19016e,null))['then'](function(_0x43df8e){const _0x24243b=_0x27c870;if(_0x43df8e)return _0x347e12=_0x43df8e,db[_0x24243b('0x1d')][_0x24243b('0xf')];})[_0x27c870('0x55')](function(_0x14ffd5){const _0x118c51=_0x27c870;if(_0x14ffd5){let _0x51e2fb={};const _0x127748={};return _0x127748[_0x118c51('0x6')]=_[_0x118c51('0x49')](_['keys'](_0x14ffd5),_[_0x118c51('0xa')](_0x347e12[_0x118c51('0x59')],function(_0x221bfb){const _0x5531df=_0x118c51;return util[_0x5531df('0x25')](_0x5531df('0x9'),_0x221bfb['id']);})),_0x127748[_0x118c51('0x61')]=_[_0x118c51('0x45')](_0xfbbe61[_0x118c51('0x61')]),_0x127748[_0x118c51('0x37')]=_[_0x118c51('0x71')](_0x127748[_0x118c51('0x6')],_0x127748[_0x118c51('0x61')]),_0x51e2fb[_0x118c51('0x4c')]=_[_0x118c51('0x71')](_0x127748['model'],qs[_0x118c51('0x21')](_0xfbbe61['query']['fields'])),_0x51e2fb[_0x118c51('0x4c')]=_0x51e2fb[_0x118c51('0x4c')]['length']?_0x51e2fb[_0x118c51('0x4c')]:_0x127748[_0x118c51('0x6')],typeof _0xfbbe61[_0x118c51('0x61')][_0x118c51('0x5')]==='undefined'&&(_0x51e2fb[_0x118c51('0x2f')]=qs['limit'](_0xfbbe61[_0x118c51('0x61')][_0x118c51('0x2f')]),_0x51e2fb[_0x118c51('0x36')]=qs[_0x118c51('0x36')](_0xfbbe61[_0x118c51('0x61')]['offset'])),_0x51e2fb[_0x118c51('0x6e')]=qs[_0x118c51('0x6f')](_0xfbbe61[_0x118c51('0x61')][_0x118c51('0x6f')]),_0x51e2fb[_0x118c51('0x1a')]=qs[_0x118c51('0x37')](_[_0x118c51('0x57')](_0xfbbe61[_0x118c51('0x61')],_0x127748[_0x118c51('0x37')])),_0x51e2fb['raw']=!![],_0xfbbe61['query']['filter']&&(_0x51e2fb['where']=_[_0x118c51('0xb')](_0x51e2fb[_0x118c51('0x1a')],{[Op['or']]:_[_0x118c51('0xa')](_0x51e2fb[_0x118c51('0x4c')],function(_0x8e5886){const _0xee7528=_0x118c51,_0x4b2ca5={};return _0x4b2ca5[_0x8e5886]={[Op[_0xee7528('0x11')]]:'%'+_0xfbbe61[_0xee7528('0x61')]['filter']+'%'},_0x4b2ca5;})})),_0x51e2fb=_[_0x118c51('0xb')]({},_0x51e2fb,_0xfbbe61[_0x118c51('0x4b')]),_0x347e12[_0x118c51('0x15')](_0x51e2fb);}})[_0x27c870('0x55')](function(_0x474d73){const _0x43977a=_0x27c870;if(!_[_0x43977a('0x2b')](_0x474d73)){const _0x255bf7=toCsv(_0x474d73),_0x341ecb=Date['now']();return fs[_0x43977a('0x12')](util[_0x43977a('0x25')](_0x43977a('0x5f'),_0x347e12['id'],_0x341ecb),_0x255bf7),_0x19016e[_0x43977a('0x53')]('Content-disposition',_0x43977a('0x1e')+util[_0x43977a('0x25')]('list_%d_%s.csv',_0x347e12['id'],_0x341ecb)),_0x19016e[_0x43977a('0x53')](_0x43977a('0x62'),_0x43977a('0x5b')),_0x19016e[_0x43977a('0x6c')](util[_0x43977a('0x25')](_0x43977a('0x5f'),_0x347e12['id'],_0x341ecb));}else return _0x19016e[_0x43977a('0x51')](0xcc);})[_0x27c870('0x3f')](handleError(_0x19016e,null));},exports['addCustomField']=function(_0x4623ea,_0x76ea23){const _0x25fb15=_0x11abdc;let _0x42fe85;return delete _0x4623ea['body']['id'],db[_0x25fb15('0x4f')][_0x25fb15('0x33')]({'where':{'id':_0x4623ea[_0x25fb15('0x4e')]['id']}})[_0x25fb15('0x55')](handleEntityNotFound(_0x76ea23,null))['then'](function(_0x4d61c6){const _0x304f4f=_0x25fb15;if(_0x4d61c6)return db[_0x304f4f('0x41')][_0x304f4f('0x5e')](function(_0x2f6a86){const _0x2b7291=_0x304f4f;return db['CmCustomField']['create'](_0x4623ea[_0x2b7291('0x31')],{'transaction':_0x2f6a86})[_0x2b7291('0x55')](function(_0x22811f){const _0x48b3e3=_0x2b7291;return _0x42fe85=_0x22811f,_0x4d61c6[_0x48b3e3('0xd')](_0x22811f,{'transaction':_0x2f6a86});})[_0x2b7291('0x55')](function(){const _0x5c7748=_0x2b7291,_0x3a9987={'type':db[_0x5c7748('0x56')]['TEXT'],'transaction':_0x2f6a86};switch(_0x4623ea[_0x5c7748('0x31')][_0x5c7748('0x7')]){case _0x5c7748('0x28'):_0x3a9987['type']=db['Sequelize']['TEXT'];break;case _0x5c7748('0x32'):_0x3a9987[_0x5c7748('0x7')]=db[_0x5c7748('0x56')][_0x5c7748('0x70')];break;case _0x5c7748('0x6d'):_0x3a9987[_0x5c7748('0x7')]=db['Sequelize']['BOOLEAN'],_0x3a9987[_0x5c7748('0x3d')]=![];break;default:}return db[_0x5c7748('0x41')]['queryInterface'][_0x5c7748('0x8')](_0x5c7748('0x64'),util['format'](_0x5c7748('0x42'),_0x42fe85['id']),_0x3a9987);})['then'](function(){return _0x42fe85;});});})[_0x25fb15('0x55')](respondWithResult(_0x76ea23,null))[_0x25fb15('0x3f')](handleError(_0x76ea23,null));},exports[_0x11abdc('0x2a')]=function(_0x57c783,_0x5c9406){const _0x3c07de=_0x11abdc;let _0x354b89={};const _0x4a8d16={};return db[_0x3c07de('0x4f')][_0x3c07de('0x33')]({'where':{'id':_0x57c783[_0x3c07de('0x4e')]['id']}})[_0x3c07de('0x55')](handleEntityNotFound(_0x5c9406,null))[_0x3c07de('0x55')](function(_0xf7729d){const _0x29ccff=_0x3c07de;if(_0xf7729d)return _0x4a8d16[_0x29ccff('0x6')]=_[_0x29ccff('0x45')](db[_0x29ccff('0x52')][_0x29ccff('0xf')]),_0x4a8d16['query']=_[_0x29ccff('0x45')](_0x57c783[_0x29ccff('0x61')]),_0x4a8d16[_0x29ccff('0x37')]=_[_0x29ccff('0x71')](_0x4a8d16[_0x29ccff('0x6')],_0x4a8d16[_0x29ccff('0x61')]),_0x354b89[_0x29ccff('0x4c')]=_['intersection'](_0x4a8d16['model'],qs[_0x29ccff('0x21')](_0x57c783[_0x29ccff('0x61')][_0x29ccff('0x21')])),_0x354b89[_0x29ccff('0x4c')]=_0x354b89[_0x29ccff('0x4c')][_0x29ccff('0x47')]?_0x354b89[_0x29ccff('0x4c')]:_0x4a8d16[_0x29ccff('0x6')],_0x354b89[_0x29ccff('0x6e')]=qs[_0x29ccff('0x6f')](_0x57c783[_0x29ccff('0x61')][_0x29ccff('0x6f')]),_0x354b89[_0x29ccff('0x1a')]=qs[_0x29ccff('0x37')](_[_0x29ccff('0x57')](_0x57c783[_0x29ccff('0x61')],_0x4a8d16[_0x29ccff('0x37')])),_0x354b89[_0x29ccff('0x1a')]=_['merge'](_0x354b89[_0x29ccff('0x1a')],{[Op['or']]:[{'ListId':_0xf7729d['id']},{'ListId':null}]}),_0x57c783['query'][_0x29ccff('0x16')]&&(_0x354b89[_0x29ccff('0x1a')]=_['merge'](_0x354b89['where'],{[Op['or']]:_['map'](_0x354b89['attributes'],function(_0x32cc16){const _0x3827d9=_0x29ccff,_0x25ff8f={};return _0x25ff8f[_0x32cc16]={[Op[_0x3827d9('0x11')]]:'%'+_0x57c783['query'][_0x3827d9('0x16')]+'%'},_0x25ff8f;})})),_0x354b89=_['merge']({},_0x354b89,_0x57c783[_0x29ccff('0x4b')]),db[_0x29ccff('0x52')]['findAndCountAll'](_0x354b89);})[_0x3c07de('0x55')](respondWithResult(_0x5c9406,null))[_0x3c07de('0x3f')](handleError(_0x5c9406,null));},exports[_0x11abdc('0x34')]=function(_0x21d00a,_0x40b983){const _0x1a075b=_0x11abdc;return db[_0x1a075b('0x4f')][_0x1a075b('0x33')]({'where':{'id':_0x21d00a[_0x1a075b('0x4e')]['id']}})[_0x1a075b('0x55')](function(_0x36b877){const _0x41b838=_0x1a075b;if(_0x36b877)return _0x36b877[_0x41b838('0x34')](_0x21d00a[_0x41b838('0x31')][_0x41b838('0x6a')],{'through':_[_0x41b838('0x3e')](_0x21d00a[_0x41b838('0x31')],[_0x41b838('0x6a'),'id'])})[_0x41b838('0x55')](function(_0x4f781d){const _0x45e6aa=_0x41b838;for(let _0x5024b8=0x0;_0x5024b8<_0x21d00a[_0x45e6aa('0x31')][_0x45e6aa('0x6a')][_0x45e6aa('0x47')];_0x5024b8+=0x1){socket[_0x45e6aa('0x22')]('userCmList:save',{'UserId':_0x21d00a[_0x45e6aa('0x31')][_0x45e6aa('0x6a')][_0x5024b8],'CmListId':_0x21d00a[_0x45e6aa('0x4e')]['id']});}return _0x4f781d;});})[_0x1a075b('0x55')](respondWithResult(_0x40b983,null))[_0x1a075b('0x3f')](handleError(_0x40b983,null));},exports[_0x11abdc('0x54')]=function(_0x1b8892,_0x40342f){const _0x5b8399=_0x11abdc;return db[_0x5b8399('0x4f')][_0x5b8399('0x33')]({'where':{'id':_0x1b8892['params']['id']}})[_0x5b8399('0x55')](handleEntityNotFound(_0x40342f,null))[_0x5b8399('0x55')](function(_0x247370){const _0x5718e2=_0x5b8399;if(_0x247370)return _0x247370[_0x5718e2('0x54')](_0x1b8892[_0x5718e2('0x61')][_0x5718e2('0x6a')])[_0x5718e2('0x55')](function(){const _0x107c3f=_0x5718e2;if(_['isArray'](_0x1b8892[_0x107c3f('0x61')]['ids']))for(let _0x24b994=0x0;_0x24b994<_0x1b8892[_0x107c3f('0x61')]['ids']['length'];_0x24b994+=0x1){socket['emit'](_0x107c3f('0x4'),{'UserId':Number(_0x1b8892[_0x107c3f('0x61')][_0x107c3f('0x6a')][_0x24b994]),'CmListId':Number(_0x1b8892[_0x107c3f('0x4e')]['id'])});}else socket['emit'](_0x107c3f('0x4'),{'UserId':Number(_0x1b8892['query']['ids']),'CmListId':Number(_0x1b8892[_0x107c3f('0x4e')]['id'])});});})[_0x5b8399('0x55')](respondWithStatusCode(_0x40342f,null))['catch'](handleError(_0x40342f,null));},exports[_0x11abdc('0x10')]=function(_0x2daa01,_0x253589){const _0x3f5d46=_0x11abdc;let _0x35e9a7={};const _0x4f4ada={};let _0x56660e,_0x44eba8;return db['CmList'][_0x3f5d46('0x33')]({'where':{'id':_0x2daa01[_0x3f5d46('0x4e')]['id']}})['then'](handleEntityNotFound(_0x253589,null))[_0x3f5d46('0x55')](function(_0x5bf78f){const _0x23398f=_0x3f5d46;if(_0x5bf78f)return _0x56660e=_0x5bf78f,_0x4f4ada[_0x23398f('0x6')]=_[_0x23398f('0x45')](db[_0x23398f('0x63')][_0x23398f('0xf')]),_0x4f4ada[_0x23398f('0x61')]=_[_0x23398f('0x45')](_0x2daa01[_0x23398f('0x61')]),_0x4f4ada[_0x23398f('0x37')]=_[_0x23398f('0x71')](_0x4f4ada['model'],_0x4f4ada[_0x23398f('0x61')]),_0x35e9a7['attributes']=_[_0x23398f('0x71')](_0x4f4ada[_0x23398f('0x6')],qs[_0x23398f('0x21')](_0x2daa01['query'][_0x23398f('0x21')])),_0x35e9a7[_0x23398f('0x4c')]=_0x35e9a7[_0x23398f('0x4c')]['length']?_0x35e9a7[_0x23398f('0x4c')]:_0x4f4ada[_0x23398f('0x6')],_0x35e9a7['order']=qs[_0x23398f('0x6f')](_0x2daa01[_0x23398f('0x61')]['sort']),_0x35e9a7[_0x23398f('0x1a')]=qs[_0x23398f('0x37')](_[_0x23398f('0x57')](_0x2daa01[_0x23398f('0x61')],_0x4f4ada['filters'])),_0x2daa01[_0x23398f('0x61')][_0x23398f('0x16')]&&(_0x35e9a7[_0x23398f('0x1a')]=_[_0x23398f('0xb')](_0x35e9a7[_0x23398f('0x1a')],{[Op['or']]:_['map'](_0x35e9a7[_0x23398f('0x4c')],function(_0x6e1b67){const _0x244dea=_0x23398f,_0x179bdf={};return _0x179bdf[_0x6e1b67]={[Op['like']]:'%'+_0x2daa01[_0x244dea('0x61')][_0x244dea('0x16')]+'%'},_0x179bdf;})})),_0x35e9a7=_[_0x23398f('0xb')]({},_0x35e9a7,_0x2daa01[_0x23398f('0x4b')]),_0x56660e['getAgents'](_0x35e9a7);})[_0x3f5d46('0x55')](function(_0x2e52a9){const _0x218f06=_0x3f5d46;if(_0x2e52a9)return _0x44eba8=_0x2e52a9[_0x218f06('0x47')],typeof _0x2daa01[_0x218f06('0x61')][_0x218f06('0x5')]==='undefined'&&(_0x35e9a7[_0x218f06('0x2f')]=qs[_0x218f06('0x2f')](_0x2daa01['query'][_0x218f06('0x2f')]),_0x35e9a7[_0x218f06('0x36')]=qs['offset'](_0x2daa01['query'][_0x218f06('0x36')])),_0x56660e[_0x218f06('0x10')](_0x35e9a7);})[_0x3f5d46('0x55')](function(_0x4692d1){if(_0x4692d1)return _0x4692d1?{'count':_0x44eba8,'rows':_0x4692d1}:null;})[_0x3f5d46('0x55')](respondWithResult(_0x253589,null))[_0x3f5d46('0x3f')](handleError(_0x253589,null));}; \ No newline at end of file diff --git a/server/api/cmList/cmList.events.js b/server/api/cmList/cmList.events.js index 4c709e4..635ba0b 100644 --- a/server/api/cmList/cmList.events.js +++ b/server/api/cmList/cmList.events.js @@ -1 +1 @@ -const a158_0x30ef=['setMaxListeners','undefined','exports','../../mysqldb','CmList','events','emit','update'];(function(_0x36bc0a,_0x30ef74){const _0x5e6f66=function(_0xaf4564){while(--_0xaf4564){_0x36bc0a['push'](_0x36bc0a['shift']());}};_0x5e6f66(++_0x30ef74);}(a158_0x30ef,0x70));const a158_0x5e6f=function(_0x36bc0a,_0x30ef74){_0x36bc0a=_0x36bc0a-0x0;let _0x5e6f66=a158_0x30ef[_0x36bc0a];return _0x5e6f66;};const _0x188039=a158_0x5e6f;'use strict';const EventEmitter=require(_0x188039('0x5')),CmList=require(_0x188039('0x3'))['db'][_0x188039('0x4')],CmListEvents=new EventEmitter();CmListEvents[_0x188039('0x0')](0x0);const events={'afterCreate':'save','afterUpdate':_0x188039('0x7'),'afterDestroy':'remove'};function emitEvent(_0xaf4564){return function(_0x4a9a4b){const _0xc8249b=a158_0x5e6f;CmListEvents[_0xc8249b('0x6')](_0xaf4564+':'+_0x4a9a4b['id'],_0x4a9a4b),CmListEvents[_0xc8249b('0x6')](_0xaf4564,_0x4a9a4b);};}for(const e in events){if(typeof events[e]!==_0x188039('0x1')){const event=events[e];CmList['addHook'](e,emitEvent(event));}}module[_0x188039('0x2')]=CmListEvents; \ No newline at end of file +const a158_0x171e=['setMaxListeners','exports','update','../../mysqldb','remove','CmList','undefined','save','events','emit'];(function(_0x71f444,_0x171e3c){const _0x1c8e72=function(_0x3eb4bc){while(--_0x3eb4bc){_0x71f444['push'](_0x71f444['shift']());}};_0x1c8e72(++_0x171e3c);}(a158_0x171e,0xaa));const a158_0x1c8e=function(_0x71f444,_0x171e3c){_0x71f444=_0x71f444-0x0;let _0x1c8e72=a158_0x171e[_0x71f444];return _0x1c8e72;};const _0x5ef362=a158_0x1c8e;'use strict';const EventEmitter=require(_0x5ef362('0x8')),CmList=require(_0x5ef362('0x3'))['db'][_0x5ef362('0x5')],CmListEvents=new EventEmitter();CmListEvents[_0x5ef362('0x0')](0x0);const events={'afterCreate':_0x5ef362('0x7'),'afterUpdate':_0x5ef362('0x2'),'afterDestroy':_0x5ef362('0x4')};function emitEvent(_0x3eb4bc){return function(_0xffd7f9){const _0x4c0af9=a158_0x1c8e;CmListEvents[_0x4c0af9('0x9')](_0x3eb4bc+':'+_0xffd7f9['id'],_0xffd7f9),CmListEvents['emit'](_0x3eb4bc,_0xffd7f9);};}for(const e in events){if(typeof events[e]!==_0x5ef362('0x6')){const event=events[e];CmList['addHook'](e,emitEvent(event));}}module[_0x5ef362('0x1')]=CmListEvents; \ No newline at end of file diff --git a/server/api/cmList/cmList.model.js b/server/api/cmList/cmList.model.js index c15ab00..722806c 100644 --- a/server/api/cmList/cmList.model.js +++ b/server/api/cmList/cmList.model.js @@ -1 +1 @@ -const a159_0x58ef=['define','./cmList.attributes','CmList','cm_lists'];(function(_0x1fafb6,_0x58ef37){const _0x31f334=function(_0x27b76c){while(--_0x27b76c){_0x1fafb6['push'](_0x1fafb6['shift']());}};_0x31f334(++_0x58ef37);}(a159_0x58ef,0x1a7));const a159_0x31f3=function(_0x1fafb6,_0x58ef37){_0x1fafb6=_0x1fafb6-0x0;let _0x31f334=a159_0x58ef[_0x1fafb6];return _0x31f334;};const _0x2322e2=a159_0x31f3;'use strict';const attributes=require(_0x2322e2('0x2'));module['exports']=function(_0x27b76c){const _0xef5494=_0x2322e2,_0x3966b4=_0x27b76c[_0xef5494('0x1')](_0xef5494('0x3'),attributes,{'tableName':_0xef5494('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3966b4;}; \ No newline at end of file +const a159_0x1a88=['./cmList.attributes','CmList','define','cm_lists','exports'];(function(_0x59d5ce,_0x1a889f){const _0x5f0d3d=function(_0x32a5b4){while(--_0x32a5b4){_0x59d5ce['push'](_0x59d5ce['shift']());}};_0x5f0d3d(++_0x1a889f);}(a159_0x1a88,0x6d));const a159_0x5f0d=function(_0x59d5ce,_0x1a889f){_0x59d5ce=_0x59d5ce-0x0;let _0x5f0d3d=a159_0x1a88[_0x59d5ce];return _0x5f0d3d;};const _0x14e0b9=a159_0x5f0d;'use strict';const attributes=require(_0x14e0b9('0x1'));module[_0x14e0b9('0x0')]=function(_0x32a5b4){const _0x3c4aed=_0x14e0b9,_0x40f54d=_0x32a5b4[_0x3c4aed('0x3')](_0x3c4aed('0x2'),attributes,{'tableName':_0x3c4aed('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x40f54d;}; \ No newline at end of file diff --git a/server/api/cmList/cmList.rpc.js b/server/api/cmList/cmList.rpc.js index 9f7a7a0..af19454 100644 --- a/server/api/cmList/cmList.rpc.js +++ b/server/api/cmList/cmList.rpc.js @@ -1 +1 @@ -const a160_0xbaac=['./cmList.socket','../../rediscache','register'];(function(_0x289e6f,_0xbaacce){const _0x368a18=function(_0x26d564){while(--_0x26d564){_0x289e6f['push'](_0x289e6f['shift']());}};_0x368a18(++_0xbaacce);}(a160_0xbaac,0x75));const a160_0x368a=function(_0x289e6f,_0xbaacce){_0x289e6f=_0x289e6f-0x0;let _0x368a18=a160_0xbaac[_0x289e6f];return _0x368a18;};const _0x5980a7=a160_0x368a;'use strict';const {getSocket}=require(_0x5980a7('0x1')),socket=getSocket();require(_0x5980a7('0x0'))[_0x5980a7('0x2')](socket); \ No newline at end of file +const a160_0x34cd=['./cmList.socket','register','../../rediscache'];(function(_0x35a671,_0x34cdc5){const _0x42570a=function(_0x8ba0b2){while(--_0x8ba0b2){_0x35a671['push'](_0x35a671['shift']());}};_0x42570a(++_0x34cdc5);}(a160_0x34cd,0xf1));const a160_0x4257=function(_0x35a671,_0x34cdc5){_0x35a671=_0x35a671-0x0;let _0x42570a=a160_0x34cd[_0x35a671];return _0x42570a;};const _0x3fe2c0=a160_0x4257;'use strict';const {getSocket}=require(_0x3fe2c0('0x1')),socket=getSocket();require(_0x3fe2c0('0x2'))[_0x3fe2c0('0x0')](socket); \ No newline at end of file diff --git a/server/api/cmList/cmList.socket.js b/server/api/cmList/cmList.socket.js index 033ef31..604d0ed 100644 --- a/server/api/cmList/cmList.socket.js +++ b/server/api/cmList/cmList.socket.js @@ -1 +1 @@ -const a161_0x19ad=['./cmList.events','emit','cmList:','update','length','remove','save','register'];(function(_0x1a3e6f,_0x19ad4c){const _0x427be9=function(_0x580ac9){while(--_0x580ac9){_0x1a3e6f['push'](_0x1a3e6f['shift']());}};_0x427be9(++_0x19ad4c);}(a161_0x19ad,0x1cf));const a161_0x427b=function(_0x1a3e6f,_0x19ad4c){_0x1a3e6f=_0x1a3e6f-0x0;let _0x427be9=a161_0x19ad[_0x1a3e6f];return _0x427be9;};const _0x437037=a161_0x427b;'use strict';const CmListEvents=require(_0x437037('0x1')),events=[_0x437037('0x7'),_0x437037('0x6'),_0x437037('0x4')];function createListener(_0x580ac9,_0x2ef53d){return function(_0x29580e){const _0x571413=a161_0x427b;_0x2ef53d[_0x571413('0x2')](_0x580ac9,_0x29580e);};}exports[_0x437037('0x0')]=function(_0x577b9f){const _0x2b483d=_0x437037;for(let _0x4618eb=0x0,_0x54602d=events[_0x2b483d('0x5')];_0x4618eb<_0x54602d;_0x4618eb++){const _0x573f84=events[_0x4618eb],_0x3a2d1e=createListener(_0x2b483d('0x3')+_0x573f84,_0x577b9f);CmListEvents['on'](_0x573f84,_0x3a2d1e);}}; \ No newline at end of file +const a161_0x3926=['update','save','emit','length','./cmList.events','cmList:','register'];(function(_0x4876fc,_0x392693){const _0x15b021=function(_0x15e7c5){while(--_0x15e7c5){_0x4876fc['push'](_0x4876fc['shift']());}};_0x15b021(++_0x392693);}(a161_0x3926,0x73));const a161_0x15b0=function(_0x4876fc,_0x392693){_0x4876fc=_0x4876fc-0x0;let _0x15b021=a161_0x3926[_0x4876fc];return _0x15b021;};const _0x1d79b2=a161_0x15b0;'use strict';const CmListEvents=require(_0x1d79b2('0x1')),events=[_0x1d79b2('0x5'),'remove',_0x1d79b2('0x4')];function createListener(_0x15e7c5,_0x2eee80){return function(_0x557b9b){const _0x3925ad=a161_0x15b0;_0x2eee80[_0x3925ad('0x6')](_0x15e7c5,_0x557b9b);};}exports[_0x1d79b2('0x3')]=function(_0x549b98){const _0x59ea56=_0x1d79b2;for(let _0xfd00ce=0x0,_0x5925a2=events[_0x59ea56('0x0')];_0xfd00ce<_0x5925a2;_0xfd00ce++){const _0x4c8177=events[_0xfd00ce],_0x38bba0=createListener(_0x59ea56('0x2')+_0x4c8177,_0x549b98);CmListEvents['on'](_0x4c8177,_0x38bba0);}}; \ No newline at end of file diff --git a/server/api/cmList/index.js b/server/api/cmList/index.js index 64c0e06..ca0bd1a 100644 --- a/server/api/cmList/index.js +++ b/server/api/cmList/index.js @@ -1 +1 @@ -const a162_0xa4fb=['post','getDispositions','getCustomFields','get','destroy','delete','removeDispositions','addAgents','removeAgents','/:id','getContacts','/describe','isAuthenticated','getAgents','exports','/:id/users','/:id/dispositions','addCustomField','./cmList.controller','describe','index','Router','../../components/auth/service','addContacts','/:id/fields','show'];(function(_0x451629,_0xa4fbb0){const _0x2e724c=function(_0x51593d){while(--_0x51593d){_0x451629['push'](_0x451629['shift']());}};_0x2e724c(++_0xa4fbb0);}(a162_0xa4fb,0x1c0));const a162_0x2e72=function(_0x451629,_0xa4fbb0){_0x451629=_0x451629-0x0;let _0x2e724c=a162_0xa4fb[_0x451629];return _0x2e724c;};const _0x18e7c9=a162_0x2e72;'use strict';const express=require('express'),router=express[_0x18e7c9('0xf')](),auth=require(_0x18e7c9('0x10')),controller=require(_0x18e7c9('0xc'));router[_0x18e7c9('0x17')]('/',auth['isAuthenticated'](),controller[_0x18e7c9('0xe')]),router['get'](_0x18e7c9('0x5'),auth['isAuthenticated'](),controller[_0x18e7c9('0xd')]),router[_0x18e7c9('0x17')](_0x18e7c9('0x3'),auth[_0x18e7c9('0x6')](),controller[_0x18e7c9('0x13')]),router[_0x18e7c9('0x17')]('/:id/dispositions',auth[_0x18e7c9('0x6')](),controller[_0x18e7c9('0x15')]),router[_0x18e7c9('0x17')]('/:id/contacts',auth[_0x18e7c9('0x6')](),controller[_0x18e7c9('0x4')]),router[_0x18e7c9('0x17')]('/:id/contacts/csv',auth[_0x18e7c9('0x6')](),controller['getContactsCsv']),router[_0x18e7c9('0x17')](_0x18e7c9('0x12'),auth[_0x18e7c9('0x6')](),controller[_0x18e7c9('0x16')]),router[_0x18e7c9('0x17')](_0x18e7c9('0x9'),auth[_0x18e7c9('0x6')](),controller[_0x18e7c9('0x7')]),router[_0x18e7c9('0x14')]('/',auth['isAuthenticated'](),controller['create']),router[_0x18e7c9('0x14')](_0x18e7c9('0xa'),auth['isAuthenticated'](),controller['addDisposition']),router[_0x18e7c9('0x14')]('/:id/contacts',auth[_0x18e7c9('0x6')](),controller[_0x18e7c9('0x11')]),router[_0x18e7c9('0x14')]('/:id/fields',auth['isAuthenticated'](),controller[_0x18e7c9('0xb')]),router[_0x18e7c9('0x14')](_0x18e7c9('0x9'),auth[_0x18e7c9('0x6')](),controller[_0x18e7c9('0x1')]),router['put']('/:id',auth['isAuthenticated'](),controller['update']),router['delete'](_0x18e7c9('0x3'),auth['isAuthenticated'](),controller[_0x18e7c9('0x18')]),router[_0x18e7c9('0x19')](_0x18e7c9('0xa'),auth[_0x18e7c9('0x6')](),controller[_0x18e7c9('0x0')]),router[_0x18e7c9('0x19')](_0x18e7c9('0x9'),auth['isAuthenticated'](),controller[_0x18e7c9('0x2')]),module[_0x18e7c9('0x8')]=router; \ No newline at end of file +const a162_0x3792=['getAgents','show','/:id/contacts','/:id/contacts/csv','addAgents','exports','Router','post','../../components/auth/service','/:id/users','/:id/dispositions','isAuthenticated','describe','create','addCustomField','removeAgents','addDisposition','removeDispositions','getCustomFields','getContacts','addContacts','get','delete','/:id','index','/:id/fields','destroy'];(function(_0x4743f2,_0x379280){const _0x1779df=function(_0x4e188f){while(--_0x4e188f){_0x4743f2['push'](_0x4743f2['shift']());}};_0x1779df(++_0x379280);}(a162_0x3792,0x199));const a162_0x1779=function(_0x4743f2,_0x379280){_0x4743f2=_0x4743f2-0x0;let _0x1779df=a162_0x3792[_0x4743f2];return _0x1779df;};const _0x24e939=a162_0x1779;'use strict';const express=require('express'),router=express[_0x24e939('0x2')](),auth=require(_0x24e939('0x4')),controller=require('./cmList.controller');router['get']('/',auth[_0x24e939('0x7')](),controller[_0x24e939('0x14')]),router[_0x24e939('0x11')]('/describe',auth['isAuthenticated'](),controller[_0x24e939('0x8')]),router['get']('/:id',auth['isAuthenticated'](),controller[_0x24e939('0x18')]),router[_0x24e939('0x11')](_0x24e939('0x6'),auth['isAuthenticated'](),controller['getDispositions']),router[_0x24e939('0x11')](_0x24e939('0x19'),auth['isAuthenticated'](),controller[_0x24e939('0xf')]),router[_0x24e939('0x11')](_0x24e939('0x1a'),auth[_0x24e939('0x7')](),controller['getContactsCsv']),router[_0x24e939('0x11')]('/:id/fields',auth['isAuthenticated'](),controller[_0x24e939('0xe')]),router[_0x24e939('0x11')](_0x24e939('0x5'),auth[_0x24e939('0x7')](),controller[_0x24e939('0x17')]),router[_0x24e939('0x3')]('/',auth['isAuthenticated'](),controller[_0x24e939('0x9')]),router[_0x24e939('0x3')](_0x24e939('0x6'),auth['isAuthenticated'](),controller[_0x24e939('0xc')]),router[_0x24e939('0x3')]('/:id/contacts',auth[_0x24e939('0x7')](),controller[_0x24e939('0x10')]),router[_0x24e939('0x3')](_0x24e939('0x15'),auth['isAuthenticated'](),controller[_0x24e939('0xa')]),router[_0x24e939('0x3')](_0x24e939('0x5'),auth[_0x24e939('0x7')](),controller[_0x24e939('0x0')]),router['put'](_0x24e939('0x13'),auth[_0x24e939('0x7')](),controller['update']),router['delete']('/:id',auth[_0x24e939('0x7')](),controller[_0x24e939('0x16')]),router[_0x24e939('0x12')](_0x24e939('0x6'),auth['isAuthenticated'](),controller[_0x24e939('0xd')]),router[_0x24e939('0x12')]('/:id/users',auth[_0x24e939('0x7')](),controller[_0x24e939('0xb')]),module[_0x24e939('0x1')]=router; \ No newline at end of file diff --git a/server/api/condition/condition.attributes.js b/server/api/condition/condition.attributes.js index 1fecd61..5937304 100644 --- a/server/api/condition/condition.attributes.js +++ b/server/api/condition/condition.attributes.js @@ -1 +1 @@ -const a163_0x4c4c=['field','getDataValue','STRING'];(function(_0x5b9617,_0x4c4c4a){const _0x4c22f5=function(_0x5a9024){while(--_0x5a9024){_0x5b9617['push'](_0x5b9617['shift']());}};_0x4c22f5(++_0x4c4c4a);}(a163_0x4c4c,0x70));const a163_0x4c22=function(_0x5b9617,_0x4c4c4a){_0x5b9617=_0x5b9617-0x0;let _0x4c22f5=a163_0x4c4c[_0x5b9617];return _0x4c22f5;};const _0x2d6f69=a163_0x4c22;'use strict';const Sequelize=require('sequelize');module['exports']={'name':{'type':Sequelize['VIRTUAL'],'get':function(){const _0x221adc=a163_0x4c22;return this[_0x221adc('0x0')](_0x221adc('0x2'));}},'field':{'type':Sequelize[_0x2d6f69('0x1')],'allowNull':![]},'operator':{'type':Sequelize['STRING'],'allowNull':![]},'value':{'type':Sequelize['STRING'],'allowNull':![]}}; \ No newline at end of file +const a163_0x9f6d=['field','STRING','exports','getDataValue','VIRTUAL'];(function(_0x1a1755,_0x9f6db4){const _0x16c1dc=function(_0x4b37e8){while(--_0x4b37e8){_0x1a1755['push'](_0x1a1755['shift']());}};_0x16c1dc(++_0x9f6db4);}(a163_0x9f6d,0x168));const a163_0x16c1=function(_0x1a1755,_0x9f6db4){_0x1a1755=_0x1a1755-0x0;let _0x16c1dc=a163_0x9f6d[_0x1a1755];return _0x16c1dc;};const _0x534902=a163_0x16c1;'use strict';const Sequelize=require('sequelize');module[_0x534902('0x2')]={'name':{'type':Sequelize[_0x534902('0x4')],'get':function(){const _0x58828e=_0x534902;return this[_0x58828e('0x3')](_0x58828e('0x0'));}},'field':{'type':Sequelize[_0x534902('0x1')],'allowNull':![]},'operator':{'type':Sequelize['STRING'],'allowNull':![]},'value':{'type':Sequelize[_0x534902('0x1')],'allowNull':![]}}; \ No newline at end of file diff --git a/server/api/condition/condition.controller.js b/server/api/condition/condition.controller.js index 87368f0..a8d3e30 100644 --- a/server/api/condition/condition.controller.js +++ b/server/api/condition/condition.controller.js @@ -1 +1 @@ -const a164_0x2a6a=['status','then','body','error','api','params','end','findOne','stack','destroy','name','catch','../../mysqldb','update','send','sendStatus','json'];(function(_0x44b082,_0x2a6a1a){const _0x5f0a77=function(_0x31bf6e){while(--_0x31bf6e){_0x44b082['push'](_0x44b082['shift']());}};_0x5f0a77(++_0x2a6a1a);}(a164_0x2a6a,0x1a0));const a164_0x5f0a=function(_0x44b082,_0x2a6a1a){_0x44b082=_0x44b082-0x0;let _0x5f0a77=a164_0x2a6a[_0x44b082];return _0x5f0a77;};const _0x54854b=a164_0x5f0a;'use strict';const logger=require('../../config/logger')(_0x54854b('0xd')),db=require(_0x54854b('0x4'))['db'];function respondWithResult(_0x31bf6e,_0x3b5680){return _0x3b5680=_0x3b5680||0xc8,function(_0x225d85){const _0x3252fd=a164_0x5f0a;if(_0x225d85)return _0x31bf6e[_0x3252fd('0x9')](_0x3b5680)[_0x3252fd('0x8')](_0x225d85);};}function saveUpdates(_0x3a55a9){return function(_0x552a11){const _0x1d486d=a164_0x5f0a;if(_0x552a11)return _0x552a11[_0x1d486d('0x5')](_0x3a55a9)[_0x1d486d('0xa')](function(_0x68e414){return _0x68e414;});return null;};}function removeEntity(_0x45e6c4){return function(_0x152d9b){const _0x1e5c2e=a164_0x5f0a;if(_0x152d9b)return _0x152d9b[_0x1e5c2e('0x1')]()[_0x1e5c2e('0xa')](function(){const _0x1e6d3b=_0x1e5c2e;_0x45e6c4[_0x1e6d3b('0x9')](0xcc)[_0x1e6d3b('0xf')]();});};}function handleEntityNotFound(_0x1e36ad){return function(_0xfe235){const _0x43eecf=a164_0x5f0a;return!_0xfe235&&_0x1e36ad[_0x43eecf('0x7')](0x194),_0xfe235;};}function handleError(_0x453b9d,_0x12f9e5){return _0x12f9e5=_0x12f9e5||0x1f4,function(_0x3caf04){const _0x3c1383=a164_0x5f0a;logger[_0x3c1383('0xc')](_0x3caf04[_0x3c1383('0x0')]),_0x3caf04[_0x3c1383('0x2')]&&delete _0x3caf04[_0x3c1383('0x2')],_0x453b9d[_0x3c1383('0x9')](_0x12f9e5)[_0x3c1383('0x6')](_0x3caf04);};}exports[_0x54854b('0x5')]=function(_0x425612,_0x4d95a1){const _0xf65162=_0x54854b;return _0x425612[_0xf65162('0xb')]['id']&&delete _0x425612[_0xf65162('0xb')]['id'],db['Condition'][_0xf65162('0x10')]({'where':{'id':_0x425612[_0xf65162('0xe')]['id']}})[_0xf65162('0xa')](handleEntityNotFound(_0x4d95a1,null))['then'](saveUpdates(_0x425612[_0xf65162('0xb')],null))['then'](respondWithResult(_0x4d95a1,null))[_0xf65162('0x3')](handleError(_0x4d95a1,null));},exports[_0x54854b('0x1')]=function(_0x75974e,_0x339612){const _0x4a4a10=_0x54854b;return db['Condition'][_0x4a4a10('0x10')]({'where':{'id':_0x75974e['params']['id']}})[_0x4a4a10('0xa')](handleEntityNotFound(_0x339612,null))[_0x4a4a10('0xa')](removeEntity(_0x339612,null))['catch'](handleError(_0x339612,null));}; \ No newline at end of file +const a164_0x19cb=['name','stack','then','params','../../mysqldb','sendStatus','body','api','status','json','../../config/logger','findOne','end','Condition'];(function(_0x5dbb6e,_0x19cb13){const _0x43ce2c=function(_0x547e4b){while(--_0x547e4b){_0x5dbb6e['push'](_0x5dbb6e['shift']());}};_0x43ce2c(++_0x19cb13);}(a164_0x19cb,0x1c7));const a164_0x43ce=function(_0x5dbb6e,_0x19cb13){_0x5dbb6e=_0x5dbb6e-0x0;let _0x43ce2c=a164_0x19cb[_0x5dbb6e];return _0x43ce2c;};const _0x49bc68=a164_0x43ce;'use strict';const logger=require(_0x49bc68('0x3'))(_0x49bc68('0x0')),db=require(_0x49bc68('0xb'))['db'];function respondWithResult(_0x547e4b,_0x7e80df){return _0x7e80df=_0x7e80df||0xc8,function(_0x4b54f1){const _0x7ae6fc=a164_0x43ce;if(_0x4b54f1)return _0x547e4b[_0x7ae6fc('0x1')](_0x7e80df)[_0x7ae6fc('0x2')](_0x4b54f1);};}function saveUpdates(_0x12cc40){return function(_0x40768f){const _0x1acef4=a164_0x43ce;if(_0x40768f)return _0x40768f['update'](_0x12cc40)[_0x1acef4('0x9')](function(_0x229c69){return _0x229c69;});return null;};}function removeEntity(_0x3d69b0){return function(_0x467855){const _0x53fd4f=a164_0x43ce;if(_0x467855)return _0x467855['destroy']()[_0x53fd4f('0x9')](function(){const _0x40c9f1=_0x53fd4f;_0x3d69b0[_0x40c9f1('0x1')](0xcc)[_0x40c9f1('0x5')]();});};}function handleEntityNotFound(_0x4c785b){return function(_0x570e16){const _0x13ab68=a164_0x43ce;return!_0x570e16&&_0x4c785b[_0x13ab68('0xc')](0x194),_0x570e16;};}function handleError(_0x157c60,_0x2a4c60){return _0x2a4c60=_0x2a4c60||0x1f4,function(_0x598ce2){const _0x53ade4=a164_0x43ce;logger['error'](_0x598ce2[_0x53ade4('0x8')]),_0x598ce2['name']&&delete _0x598ce2[_0x53ade4('0x7')],_0x157c60[_0x53ade4('0x1')](_0x2a4c60)['send'](_0x598ce2);};}exports['update']=function(_0x2822f5,_0x3f28b0){const _0x4159cb=_0x49bc68;return _0x2822f5[_0x4159cb('0xd')]['id']&&delete _0x2822f5[_0x4159cb('0xd')]['id'],db['Condition']['findOne']({'where':{'id':_0x2822f5[_0x4159cb('0xa')]['id']}})[_0x4159cb('0x9')](handleEntityNotFound(_0x3f28b0,null))[_0x4159cb('0x9')](saveUpdates(_0x2822f5[_0x4159cb('0xd')],null))[_0x4159cb('0x9')](respondWithResult(_0x3f28b0,null))['catch'](handleError(_0x3f28b0,null));},exports['destroy']=function(_0x2aa399,_0x1050dc){const _0x138522=_0x49bc68;return db[_0x138522('0x6')][_0x138522('0x4')]({'where':{'id':_0x2aa399[_0x138522('0xa')]['id']}})[_0x138522('0x9')](handleEntityNotFound(_0x1050dc,null))[_0x138522('0x9')](removeEntity(_0x1050dc,null))['catch'](handleError(_0x1050dc,null));}; \ No newline at end of file diff --git a/server/api/condition/condition.model.js b/server/api/condition/condition.model.js index d96d5aa..7fa25fa 100644 --- a/server/api/condition/condition.model.js +++ b/server/api/condition/condition.model.js @@ -1 +1 @@ -const a165_0x44c7=['./condition.attributes','tools_conditions','exports','define','Condition'];(function(_0x5356a0,_0x44c7f4){const _0x4c2c7b=function(_0x5c90b4){while(--_0x5c90b4){_0x5356a0['push'](_0x5356a0['shift']());}};_0x4c2c7b(++_0x44c7f4);}(a165_0x44c7,0x78));const a165_0x4c2c=function(_0x5356a0,_0x44c7f4){_0x5356a0=_0x5356a0-0x0;let _0x4c2c7b=a165_0x44c7[_0x5356a0];return _0x4c2c7b;};const _0x3a5854=a165_0x4c2c;'use strict';const attributes=require(_0x3a5854('0x0'));module[_0x3a5854('0x2')]=function(_0x5c90b4){const _0x47fb85=_0x3a5854,_0xe1708=_0x5c90b4[_0x47fb85('0x3')](_0x47fb85('0x4'),attributes,{'tableName':_0x47fb85('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xe1708;}; \ No newline at end of file +const a165_0x577e=['Condition','./condition.attributes','exports'];(function(_0x10bd2d,_0x577e3b){const _0x4a0519=function(_0x24e3e0){while(--_0x24e3e0){_0x10bd2d['push'](_0x10bd2d['shift']());}};_0x4a0519(++_0x577e3b);}(a165_0x577e,0x192));const a165_0x4a05=function(_0x10bd2d,_0x577e3b){_0x10bd2d=_0x10bd2d-0x0;let _0x4a0519=a165_0x577e[_0x10bd2d];return _0x4a0519;};const _0x1381f4=a165_0x4a05;'use strict';const attributes=require(_0x1381f4('0x1'));module[_0x1381f4('0x2')]=function(_0x24e3e0){const _0x57a819=_0x1381f4,_0x48e5eb=_0x24e3e0['define'](_0x57a819('0x0'),attributes,{'tableName':'tools_conditions','paranoid':![],'indexes':[],'timestamps':!![]});return _0x48e5eb;}; \ No newline at end of file diff --git a/server/api/condition/index.js b/server/api/condition/index.js index e3e5a82..9154618 100644 --- a/server/api/condition/index.js +++ b/server/api/condition/index.js @@ -1 +1 @@ -const a166_0x5aa6=['Router','express','exports','destroy','isAuthenticated','/:id','../../components/auth/service','update','./condition.controller'];(function(_0x1b3357,_0x5aa65a){const _0x537bb6=function(_0xceea81){while(--_0xceea81){_0x1b3357['push'](_0x1b3357['shift']());}};_0x537bb6(++_0x5aa65a);}(a166_0x5aa6,0xa1));const a166_0x537b=function(_0x1b3357,_0x5aa65a){_0x1b3357=_0x1b3357-0x0;let _0x537bb6=a166_0x5aa6[_0x1b3357];return _0x537bb6;};const _0x636cd0=a166_0x537b;'use strict';const express=require(_0x636cd0('0x2')),router=express[_0x636cd0('0x1')](),auth=require(_0x636cd0('0x7')),controller=require(_0x636cd0('0x0'));router['put'](_0x636cd0('0x6'),auth['isAuthenticated'](),controller[_0x636cd0('0x8')]),router['delete'](_0x636cd0('0x6'),auth[_0x636cd0('0x5')](),controller[_0x636cd0('0x4')]),module[_0x636cd0('0x3')]=router; \ No newline at end of file +const a166_0x3315=['isAuthenticated','express','/:id','./condition.controller','exports','destroy','Router','delete'];(function(_0x258954,_0x331549){const _0xe16888=function(_0x41382f){while(--_0x41382f){_0x258954['push'](_0x258954['shift']());}};_0xe16888(++_0x331549);}(a166_0x3315,0xe0));const a166_0xe168=function(_0x258954,_0x331549){_0x258954=_0x258954-0x0;let _0xe16888=a166_0x3315[_0x258954];return _0xe16888;};const _0x40585c=a166_0xe168;'use strict';const express=require(_0x40585c('0x1')),router=express[_0x40585c('0x6')](),auth=require('../../components/auth/service'),controller=require(_0x40585c('0x3'));router['put'](_0x40585c('0x2'),auth[_0x40585c('0x0')](),controller['update']),router[_0x40585c('0x7')](_0x40585c('0x2'),auth[_0x40585c('0x0')](),controller[_0x40585c('0x5')]),module[_0x40585c('0x4')]=router; \ No newline at end of file diff --git a/server/api/dashboard/dashboard.attributes.js b/server/api/dashboard/dashboard.attributes.js index 96e64e4..74044f3 100644 --- a/server/api/dashboard/dashboard.attributes.js +++ b/server/api/dashboard/dashboard.attributes.js @@ -1 +1 @@ -const a167_0x7497=['exports','name','STRING'];(function(_0x392e21,_0x7497ef){const _0x242614=function(_0x5744e5){while(--_0x5744e5){_0x392e21['push'](_0x392e21['shift']());}};_0x242614(++_0x7497ef);}(a167_0x7497,0x1c4));const a167_0x2426=function(_0x392e21,_0x7497ef){_0x392e21=_0x392e21-0x0;let _0x242614=a167_0x7497[_0x392e21];return _0x242614;};const _0x42352a=a167_0x2426;'use strict';const Sequelize=require('sequelize');module[_0x42352a('0x1')]={'name':{'type':Sequelize[_0x42352a('0x0')],'allowNull':![],'unique':_0x42352a('0x2')},'description':{'type':Sequelize[_0x42352a('0x0')]}}; \ No newline at end of file +const a167_0x4897=['STRING','sequelize','name'];(function(_0x5e8820,_0x489760){const _0x274a92=function(_0x46dc26){while(--_0x46dc26){_0x5e8820['push'](_0x5e8820['shift']());}};_0x274a92(++_0x489760);}(a167_0x4897,0xcb));const a167_0x274a=function(_0x5e8820,_0x489760){_0x5e8820=_0x5e8820-0x0;let _0x274a92=a167_0x4897[_0x5e8820];return _0x274a92;};const _0x18f090=a167_0x274a;'use strict';const Sequelize=require(_0x18f090('0x2'));module['exports']={'name':{'type':Sequelize[_0x18f090('0x1')],'allowNull':![],'unique':_0x18f090('0x0')},'description':{'type':Sequelize[_0x18f090('0x1')]}}; \ No newline at end of file diff --git a/server/api/dashboard/dashboard.controller.js b/server/api/dashboard/dashboard.controller.js index 7bb92be..8edc26c 100644 --- a/server/api/dashboard/dashboard.controller.js +++ b/server/api/dashboard/dashboard.controller.js @@ -1 +1 @@ -const a168_0x2cce=['attrRefresh','userProfileId','updatedAt','map','total','like','reportType','attrFontSize','get','attrReport','clone','offset','attrMetric','filters','merge','rawAttributes','iframe','attrUrl','pie-chart','addItem','omit','options','value','includeAll','end','length','findOne','stack','update','order','0.00','pick','https://','../../rediscache','sendStatus','autoAssociation','Unable\x20to\x20retrieve\x20the\x20current\x20user','custom','model','params','name','attrSerie1','counter','./dashboard.socket','DashboardId','include','UserProfileSection','attrSerie2','UserProfileResource','attrVoiceQueues','then','fields','../../config/logger','attrPath','query','keys','../../mysqldb','Content-Range','create','sort','json','send','undefined','set','limit','body','attrTimezone','user','destroy','createdAt','stringify','attrs','type','filter','lodash','attrSerie3','where','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','count','status','intersection','api','getItems','attributes','attrHourFormat','CustomDashboards','error','catch','key','role','findAll','Dashboard'];(function(_0x5755ff,_0x2cce33){const _0x3c08db=function(_0x31830d){while(--_0x31830d){_0x5755ff['push'](_0x5755ff['shift']());}};_0x3c08db(++_0x2cce33);}(a168_0x2cce,0x1b4));const a168_0x3c08=function(_0x5755ff,_0x2cce33){_0x5755ff=_0x5755ff-0x0;let _0x3c08db=a168_0x2cce[_0x5755ff];return _0x3c08db;};const _0x5b0929=a168_0x3c08;'use strict';const _=require(_0x5b0929('0x6')),qs=require('../../components/parsers/qs'),logger=require(_0x5b0929('0x4c'))(_0x5b0929('0xd')),{getSocket}=require(_0x5b0929('0x39')),socket=getSocket(),db=require(_0x5b0929('0x50'))['db'],{Op}=require('sequelize');require(_0x5b0929('0x43'))['register'](socket);function respondWithResult(_0x31830d,_0x18ccfa){return _0x18ccfa=_0x18ccfa||0xc8,function(_0x93db94){const _0x1f14d6=a168_0x3c08;if(_0x93db94)return _0x31830d[_0x1f14d6('0xb')](_0x18ccfa)['json'](_0x93db94);};}function respondWithFilteredResult(_0x18584e,_0x461fb0){return function(_0x971928){const _0x5f4022=a168_0x3c08;if(_0x971928){const _0x3aa3b1=_0x971928['count'],_0x261a69=_0x461fb0[_0x5f4022('0x23')];let _0x148718=_0x461fb0[_0x5f4022('0x23')]+_0x461fb0['limit'],_0x4ec773;return _0x148718>=_0x3aa3b1?(_0x148718=_0x3aa3b1,_0x4ec773=0xc8):_0x4ec773=0xce,_0x18584e['status'](_0x4ec773),_0x18584e[_0x5f4022('0x57')](_0x5f4022('0x51'),_0x261a69+'-'+_0x148718+'/'+_0x3aa3b1)[_0x5f4022('0x54')](_0x971928);}return null;};}function saveUpdates(_0x5a5ab0){return function(_0x1aa071){const _0x15ca18=a168_0x3c08;if(_0x1aa071)return _0x1aa071['update'](_0x5a5ab0)[_0x15ca18('0x4a')](function(_0x41f9ac){return _0x41f9ac;});return null;};}function removeEntity(_0x5ee89e){return function(_0x1b4cb1){const _0x4c80e4=a168_0x3c08;if(_0x1b4cb1)return _0x1b4cb1['destroy']()[_0x4c80e4('0x4a')](function(){const _0x3a4cb1=_0x4c80e4,_0xa536a7=_0x1b4cb1[_0x3a4cb1('0x20')]({'plain':!![]}),_0x22c48c=_0x3a4cb1('0x11');return db['UserProfileResource'][_0x3a4cb1('0x0')]({'where':{'type':_0x22c48c,'resourceId':_0xa536a7['id']}})['then'](function(){return _0x1b4cb1;});})[_0x4c80e4('0x4a')](function(){const _0x177f22=_0x4c80e4;_0x5ee89e[_0x177f22('0xb')](0xcc)[_0x177f22('0x30')]();});};}function handleEntityNotFound(_0x28c766){return function(_0x3835d4){const _0x1e2b91=a168_0x3c08;return!_0x3835d4&&_0x28c766[_0x1e2b91('0x3a')](0x194),_0x3835d4;};}function handleError(_0x88ab48,_0x2b5652){return _0x2b5652=_0x2b5652||0x1f4,function(_0x4992e7){const _0x199590=a168_0x3c08;logger['error'](_0x4992e7[_0x199590('0x33')]),_0x4992e7[_0x199590('0x40')]&&delete _0x4992e7[_0x199590('0x40')],_0x88ab48[_0x199590('0xb')](_0x2b5652)[_0x199590('0x55')](_0x4992e7);};}exports['index']=function(_0x375710,_0x20cfd6){const _0x3758ce=_0x5b0929;let _0x85df10={};const _0x43d1b9={},_0x42ac5d={'count':0x0,'rows':[]},_0xa07d96=_[_0x3758ce('0x1b')](db[_0x3758ce('0x17')][_0x3758ce('0x27')],function(_0x4ec219){const _0x14a6be=_0x3758ce;return{'name':_0x4ec219['fieldName'],'type':_0x4ec219[_0x14a6be('0x4')][_0x14a6be('0x14')]};});_0x43d1b9[_0x3758ce('0x3e')]=_[_0x3758ce('0x1b')](_0xa07d96,_0x3758ce('0x40')),_0x43d1b9[_0x3758ce('0x4e')]=_[_0x3758ce('0x4f')](_0x375710[_0x3758ce('0x4e')]),_0x43d1b9[_0x3758ce('0x25')]=_[_0x3758ce('0xc')](_0x43d1b9[_0x3758ce('0x3e')],_0x43d1b9[_0x3758ce('0x4e')]),_0x85df10[_0x3758ce('0xf')]=_[_0x3758ce('0xc')](_0x43d1b9[_0x3758ce('0x3e')],qs['fields'](_0x375710[_0x3758ce('0x4e')]['fields'])),_0x85df10[_0x3758ce('0xf')]=_0x85df10[_0x3758ce('0xf')][_0x3758ce('0x31')]?_0x85df10[_0x3758ce('0xf')]:_0x43d1b9[_0x3758ce('0x3e')];typeof _0x375710[_0x3758ce('0x4e')]['nolimit']===_0x3758ce('0x56')&&(_0x85df10['limit']=qs[_0x3758ce('0x58')](_0x375710[_0x3758ce('0x4e')][_0x3758ce('0x58')]),_0x85df10[_0x3758ce('0x23')]=qs['offset'](_0x375710[_0x3758ce('0x4e')][_0x3758ce('0x23')]));_0x85df10[_0x3758ce('0x35')]=qs['sort'](_0x375710['query'][_0x3758ce('0x53')]),_0x85df10[_0x3758ce('0x8')]=qs['filters'](_[_0x3758ce('0x37')](_0x375710[_0x3758ce('0x4e')],_0x43d1b9[_0x3758ce('0x25')]),_0xa07d96);_0x375710['query'][_0x3758ce('0x5')]&&(_0x85df10[_0x3758ce('0x8')]=_[_0x3758ce('0x26')](_0x85df10['where'],{[Op['or']]:_['map'](_0xa07d96,function(_0x511921){const _0x4abf64=_0x3758ce;if(_0x511921['type']!=='VIRTUAL'){const _0x19cae3={};return _0x19cae3[_0x511921[_0x4abf64('0x40')]]={[Op[_0x4abf64('0x1d')]]:'%'+_0x375710[_0x4abf64('0x4e')][_0x4abf64('0x5')]+'%'},_0x19cae3;}})}));_0x85df10=_['merge']({},_0x85df10,_0x375710[_0x3758ce('0x2d')]);const _0x4033c1={'where':_0x85df10[_0x3758ce('0x8')]};return db[_0x3758ce('0x17')]['count'](_0x4033c1)['then'](function(_0x2ea311){const _0x598375=_0x3758ce;return _0x42ac5d[_0x598375('0xa')]=_0x2ea311,_0x375710[_0x598375('0x4e')][_0x598375('0x2f')]&&(_0x85df10[_0x598375('0x45')]=[{'all':!![]}]),db[_0x598375('0x17')][_0x598375('0x16')](_0x85df10);})[_0x3758ce('0x4a')](function(_0x23d309){return _0x42ac5d['rows']=_0x23d309,_0x42ac5d;})[_0x3758ce('0x4a')](respondWithFilteredResult(_0x20cfd6,_0x85df10))[_0x3758ce('0x13')](handleError(_0x20cfd6,null));},exports['show']=function(_0xc4a8ca,_0xc34c87){const _0x2d4592=_0x5b0929;let _0x1dd5ca={'raw':![],'where':{'id':_0xc4a8ca['params']['id']}};const _0xaa779f={};return _0xaa779f[_0x2d4592('0x3e')]=_[_0x2d4592('0x4f')](db[_0x2d4592('0x17')][_0x2d4592('0x27')]),_0xaa779f[_0x2d4592('0x4e')]=_[_0x2d4592('0x4f')](_0xc4a8ca[_0x2d4592('0x4e')]),_0xaa779f['filters']=_[_0x2d4592('0xc')](_0xaa779f[_0x2d4592('0x3e')],_0xaa779f[_0x2d4592('0x4e')]),_0x1dd5ca[_0x2d4592('0xf')]=_['intersection'](_0xaa779f['model'],qs['fields'](_0xc4a8ca[_0x2d4592('0x4e')][_0x2d4592('0x4b')])),_0x1dd5ca[_0x2d4592('0xf')]=_0x1dd5ca[_0x2d4592('0xf')][_0x2d4592('0x31')]?_0x1dd5ca[_0x2d4592('0xf')]:_0xaa779f[_0x2d4592('0x3e')],_0xc4a8ca[_0x2d4592('0x4e')][_0x2d4592('0x2f')]&&(_0x1dd5ca['include']=[{'all':!![]}]),_0x1dd5ca=_[_0x2d4592('0x26')]({},_0x1dd5ca,_0xc4a8ca[_0x2d4592('0x2d')]),db[_0x2d4592('0x17')]['findOne'](_0x1dd5ca)[_0x2d4592('0x4a')](handleEntityNotFound(_0xc34c87,null))[_0x2d4592('0x4a')](respondWithResult(_0xc34c87,null))[_0x2d4592('0x13')](handleError(_0xc34c87,null));},exports['create']=function(_0x5d12dd,_0x261ac2){const _0x3bbe08=_0x5b0929;return db[_0x3bbe08('0x17')][_0x3bbe08('0x52')](_0x5d12dd[_0x3bbe08('0x59')],{})[_0x3bbe08('0x4a')](function(_0x3b76cc){const _0x56b371=_0x3bbe08,_0x271c63=_0x5d12dd[_0x56b371('0x5b')][_0x56b371('0x20')]({'plain':!![]});if(!_0x271c63)throw new Error(_0x56b371('0x3c'));if(_0x271c63[_0x56b371('0x15')]==='user'){const _0x2c6da5=_0x3b76cc[_0x56b371('0x20')]({'plain':!![]}),_0xe571e8=_0x56b371('0x11');return db['UserProfileSection'][_0x56b371('0x32')]({'where':{'name':_0xe571e8,'userProfileId':_0x271c63[_0x56b371('0x19')]},'raw':!![]})[_0x56b371('0x4a')](function(_0x27ec0e){const _0x2208b4=_0x56b371;return _0x27ec0e&&_0x27ec0e[_0x2208b4('0x3b')]===0x0?db[_0x2208b4('0x48')][_0x2208b4('0x52')]({'name':_0x2c6da5[_0x2208b4('0x40')],'resourceId':_0x2c6da5['id'],'type':_0x27ec0e[_0x2208b4('0x40')],'sectionId':_0x27ec0e['id']},{})[_0x2208b4('0x4a')](function(){return _0x3b76cc;}):_0x3b76cc;})['catch'](function(_0x40345d){const _0x2bc4c9=_0x56b371;logger[_0x2bc4c9('0x12')](_0x2bc4c9('0x9'),_0x40345d);throw _0x40345d;});}return _0x3b76cc;})[_0x3bbe08('0x4a')](respondWithResult(_0x261ac2,0xc9))[_0x3bbe08('0x13')](handleError(_0x261ac2,null));},exports[_0x5b0929('0x22')]=function(_0x530d1c,_0x222f47){const _0x666566=_0x5b0929;let _0x5ae6ed={'where':{'id':_0x530d1c[_0x666566('0x3f')]['id']}};const _0x1800c4={};return _0x1800c4[_0x666566('0x3e')]=_[_0x666566('0x4f')](db[_0x666566('0x17')][_0x666566('0x27')]),_0x5ae6ed[_0x666566('0xf')]=_['intersection'](_0x1800c4[_0x666566('0x3e')],qs[_0x666566('0x4b')](_0x530d1c['query']['fields'])),_0x5ae6ed[_0x666566('0xf')]=_0x5ae6ed[_0x666566('0xf')][_0x666566('0x31')]?_0x5ae6ed[_0x666566('0xf')]:_0x1800c4['model'],_0x530d1c[_0x666566('0x4e')][_0x666566('0x2f')]&&(_0x5ae6ed[_0x666566('0x45')]=[{'all':!![]}]),_0x5ae6ed=_['merge']({},_0x5ae6ed,_0x530d1c['options']),db['Dashboard'][_0x666566('0x32')](_0x5ae6ed)['then'](handleEntityNotFound(_0x222f47,null))[_0x666566('0x4a')](function(_0x15fee3){const _0x1887f5=_0x666566;if(_0x15fee3){let _0xef67ec=_0x15fee3[_0x1887f5('0x20')]({'plain':!![]});return _0xef67ec=qs[_0x1887f5('0x2c')](_0xef67ec,['id',_0x1887f5('0x1'),_0x1887f5('0x1a')]),_0x530d1c[_0x1887f5('0x59')]=_[_0x1887f5('0x2c')](_0x530d1c[_0x1887f5('0x59')],['id',_0x1887f5('0x1'),_0x1887f5('0x1a')]),db[_0x1887f5('0x17')]['create'](_[_0x1887f5('0x26')](_0xef67ec,_0x530d1c[_0x1887f5('0x59')]),{'include':_0x530d1c[_0x1887f5('0x4e')][_0x1887f5('0x2f')]?[{'all':!![]}]:undefined})[_0x1887f5('0x4a')](function(_0x4aaa19){const _0x54f241=_0x1887f5,_0x331725=_0x530d1c[_0x54f241('0x5b')][_0x54f241('0x20')]({'plain':!![]});if(!_0x331725)throw new Error(_0x54f241('0x3c'));if(_0x331725[_0x54f241('0x15')]==='user'){const _0x3246ea=_0x4aaa19[_0x54f241('0x20')]({'plain':!![]}),_0x4ff2f8='CustomDashboards';return db[_0x54f241('0x46')][_0x54f241('0x32')]({'where':{'name':_0x4ff2f8,'userProfileId':_0x331725[_0x54f241('0x19')]},'raw':!![]})['then'](function(_0x4f3f68){const _0x5045f7=_0x54f241;return _0x4f3f68&&_0x4f3f68[_0x5045f7('0x3b')]===0x0?db['UserProfileResource'][_0x5045f7('0x52')]({'name':_0x3246ea['name'],'resourceId':_0x3246ea['id'],'type':_0x4f3f68[_0x5045f7('0x40')],'sectionId':_0x4f3f68['id']},{})[_0x5045f7('0x4a')](function(){return _0x4aaa19;}):_0x4aaa19;})['catch'](function(_0xce19e){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0xce19e);throw _0xce19e;});}return _0x4aaa19;});}})[_0x666566('0x4a')](respondWithResult(_0x222f47,0xc9))[_0x666566('0x13')](handleError(_0x222f47,null));},exports[_0x5b0929('0x34')]=function(_0x2c37db,_0x19307f){const _0x16e21d=_0x5b0929;return _0x2c37db[_0x16e21d('0x59')]['id']&&delete _0x2c37db[_0x16e21d('0x59')]['id'],db['Dashboard']['findOne']({'where':{'id':_0x2c37db['params']['id']}})[_0x16e21d('0x4a')](handleEntityNotFound(_0x19307f,null))[_0x16e21d('0x4a')](saveUpdates(_0x2c37db[_0x16e21d('0x59')],null))[_0x16e21d('0x4a')](respondWithResult(_0x19307f,null))[_0x16e21d('0x13')](handleError(_0x19307f,null));},exports[_0x5b0929('0x0')]=function(_0x57e956,_0x10b2a9){const _0x40b450=_0x5b0929;return db['Dashboard']['findOne']({'where':{'id':_0x57e956[_0x40b450('0x3f')]['id']}})[_0x40b450('0x4a')](handleEntityNotFound(_0x10b2a9,null))[_0x40b450('0x4a')](removeEntity(_0x10b2a9,null))[_0x40b450('0x13')](handleError(_0x10b2a9,null));};function widgetAttributes(_0x4a0c36){const _0x44c9ff=_0x5b0929;try{switch(_0x4a0c36[_0x44c9ff('0x4')]){case _0x44c9ff('0x28'):return[{'name':_0x44c9ff('0x29'),'value':_0x4a0c36[_0x44c9ff('0x29')]||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36[_0x44c9ff('0x3')][0x0]?_0x4a0c36[_0x44c9ff('0x3')][0x0][_0x44c9ff('0x2e')]:undefined)||_0x44c9ff('0x38')}];case _0x44c9ff('0x3d'):return[{'name':_0x44c9ff('0x4d'),'value':_0x4a0c36[_0x44c9ff('0x4d')]||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36[_0x44c9ff('0x3')][0x0]?_0x4a0c36[_0x44c9ff('0x3')][0x0][_0x44c9ff('0x2e')]:undefined)||''}];case'clock':return[{'name':_0x44c9ff('0x10'),'value':_0x4a0c36[_0x44c9ff('0x10')]||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36[_0x44c9ff('0x3')][0x0]?_0x4a0c36[_0x44c9ff('0x3')][0x0][_0x44c9ff('0x2e')]:undefined)||'HH:mm:ss'},{'name':_0x44c9ff('0x5a'),'value':_0x4a0c36[_0x44c9ff('0x5a')]||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36['attrs'][0x1]?_0x4a0c36['attrs'][0x1]['value']:undefined)||_0x44c9ff('0x36')},{'name':_0x44c9ff('0x1f'),'value':_0x4a0c36['attrFontSize']||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36[_0x44c9ff('0x3')][0x2]?_0x4a0c36[_0x44c9ff('0x3')][0x2]['value']:undefined)||0xc}];case _0x44c9ff('0x42'):return[{'name':_0x44c9ff('0x24'),'value':_0x4a0c36['attrMetric']||(_0x4a0c36['attrs']&&_0x4a0c36[_0x44c9ff('0x3')][0x0]?_0x4a0c36[_0x44c9ff('0x3')][0x0]['value']:undefined)||_0x44c9ff('0x1c')},{'name':_0x44c9ff('0x49'),'value':_0x4a0c36[_0x44c9ff('0x49')]||(_0x4a0c36['attrs']&&_0x4a0c36[_0x44c9ff('0x3')][0x1]?_0x4a0c36[_0x44c9ff('0x3')][0x1][_0x44c9ff('0x2e')]:undefined)||[]},{'name':_0x44c9ff('0x1f'),'value':_0x4a0c36['attrFontSize']||(_0x4a0c36['attrs']&&_0x4a0c36[_0x44c9ff('0x3')][0x2]?_0x4a0c36[_0x44c9ff('0x3')][0x2]['value']:undefined)||0x14}];case'multibar-chart':case _0x44c9ff('0x2a'):return[{'name':_0x44c9ff('0x41'),'value':_0x4a0c36['attrSerie1']||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36[_0x44c9ff('0x3')][0x0]?_0x4a0c36['attrs'][0x0]['value']:undefined)||_0x44c9ff('0x1c')},{'name':_0x44c9ff('0x47'),'value':_0x4a0c36[_0x44c9ff('0x47')]||(_0x4a0c36['attrs']&&_0x4a0c36[_0x44c9ff('0x3')][0x1]?_0x4a0c36[_0x44c9ff('0x3')][0x1][_0x44c9ff('0x2e')]:undefined)||null},{'name':_0x44c9ff('0x7'),'value':_0x4a0c36[_0x44c9ff('0x7')]||(_0x4a0c36['attrs']&&_0x4a0c36[_0x44c9ff('0x3')][0x2]?_0x4a0c36[_0x44c9ff('0x3')][0x2]['value']:undefined)||null},{'name':_0x44c9ff('0x49'),'value':_0x4a0c36['attrVoiceQueues']||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36[_0x44c9ff('0x3')][0x3]?_0x4a0c36['attrs'][0x3]['value']:undefined)||[]}];case'web-report':return[{'name':_0x44c9ff('0x21'),'type':_0x4a0c36[_0x44c9ff('0x1e')]||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36[_0x44c9ff('0x3')][0x0]?_0x4a0c36[_0x44c9ff('0x3')][0x0][_0x44c9ff('0x4')]:undefined)||null,'value':_0x4a0c36[_0x44c9ff('0x21')]||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36[_0x44c9ff('0x3')][0x0]?_0x4a0c36[_0x44c9ff('0x3')][0x0]['value']:undefined)||null},{'name':_0x44c9ff('0x18'),'value':_0x4a0c36[_0x44c9ff('0x18')]||(_0x4a0c36[_0x44c9ff('0x3')]&&_0x4a0c36[_0x44c9ff('0x3')][0x1]?_0x4a0c36[_0x44c9ff('0x3')][0x1]['value']:undefined)||0x0}];default:return[];}}catch(_0x3f87c0){return logger['error']('widgetAttributes:\x20%s',JSON[_0x44c9ff('0x2')](_0x3f87c0)),[];}}exports[_0x5b0929('0x2b')]=function(_0x474587,_0x57ed94){const _0x3743d5=_0x5b0929;return _0x474587[_0x3743d5('0x59')]['id']&&delete _0x474587[_0x3743d5('0x59')]['id'],db[_0x3743d5('0x17')][_0x3743d5('0x32')]({'where':{'id':_0x474587[_0x3743d5('0x3f')]['id']}})[_0x3743d5('0x4a')](handleEntityNotFound(_0x57ed94,null))[_0x3743d5('0x4a')](function(_0x5587c8){const _0x5cf9ed=_0x3743d5;if(_0x5587c8)return _0x474587[_0x5cf9ed('0x59')][_0x5cf9ed('0x44')]=_0x5587c8['id'],_0x474587[_0x5cf9ed('0x59')][_0x5cf9ed('0x3')]=widgetAttributes(_0x474587['body']),db['DashboardItem'][_0x5cf9ed('0x52')](_0x474587[_0x5cf9ed('0x59')]);})[_0x3743d5('0x4a')](respondWithResult(_0x57ed94,null))[_0x3743d5('0x13')](handleError(_0x57ed94,null));},exports[_0x5b0929('0xe')]=function(_0x69e562,_0x53c158){const _0x41ca61=_0x5b0929;let _0x4a63e4={};const _0x118bdd={};let _0x23a949,_0x3a2524;return db[_0x41ca61('0x17')]['findOne']({'where':{'id':_0x69e562['params']['id']}})[_0x41ca61('0x4a')](handleEntityNotFound(_0x53c158,null))[_0x41ca61('0x4a')](function(_0x4b1a50){const _0x16aea8=_0x41ca61;if(_0x4b1a50)return _0x23a949=_0x4b1a50,_0x118bdd[_0x16aea8('0x3e')]=_[_0x16aea8('0x4f')](db['DashboardItem'][_0x16aea8('0x27')]),_0x118bdd[_0x16aea8('0x4e')]=_[_0x16aea8('0x4f')](_0x69e562['query']),_0x118bdd[_0x16aea8('0x25')]=_[_0x16aea8('0xc')](_0x118bdd[_0x16aea8('0x3e')],_0x118bdd[_0x16aea8('0x4e')]),_0x4a63e4[_0x16aea8('0xf')]=_[_0x16aea8('0xc')](_0x118bdd[_0x16aea8('0x3e')],qs[_0x16aea8('0x4b')](_0x69e562[_0x16aea8('0x4e')]['fields'])),_0x4a63e4[_0x16aea8('0xf')]=_0x4a63e4[_0x16aea8('0xf')][_0x16aea8('0x31')]?_0x4a63e4[_0x16aea8('0xf')]:_0x118bdd[_0x16aea8('0x3e')],_0x4a63e4[_0x16aea8('0x35')]=qs[_0x16aea8('0x53')](_0x69e562[_0x16aea8('0x4e')][_0x16aea8('0x53')]),_0x4a63e4[_0x16aea8('0x8')]=qs[_0x16aea8('0x25')](_[_0x16aea8('0x37')](_0x69e562[_0x16aea8('0x4e')],_0x118bdd['filters'])),_0x69e562[_0x16aea8('0x4e')][_0x16aea8('0x5')]&&(_0x4a63e4[_0x16aea8('0x8')]=_[_0x16aea8('0x26')](_0x4a63e4['where'],{[Op['or']]:_['map'](_0x4a63e4[_0x16aea8('0xf')],function(_0x2879c8){const _0x14fe1e=_0x16aea8,_0x51012e={};return _0x51012e[_0x2879c8]={[Op['like']]:'%'+_0x69e562[_0x14fe1e('0x4e')][_0x14fe1e('0x5')]+'%'},_0x51012e;})})),_0x4a63e4=_['merge']({},_0x4a63e4,_0x69e562['options']),_0x23a949[_0x16aea8('0xe')](_0x4a63e4);})[_0x41ca61('0x4a')](function(_0x34518a){const _0xaf0e99=_0x41ca61;if(_0x34518a)return _0x3a2524=_0x34518a[_0xaf0e99('0x31')],typeof _0x69e562[_0xaf0e99('0x4e')]['nolimit']===_0xaf0e99('0x56')&&(_0x4a63e4[_0xaf0e99('0x58')]=qs[_0xaf0e99('0x58')](_0x69e562[_0xaf0e99('0x4e')][_0xaf0e99('0x58')]),_0x4a63e4[_0xaf0e99('0x23')]=qs[_0xaf0e99('0x23')](_0x69e562[_0xaf0e99('0x4e')][_0xaf0e99('0x23')])),_0x23a949[_0xaf0e99('0xe')](_0x4a63e4);})['then'](function(_0x258b0e){if(_0x258b0e)return _0x258b0e?{'count':_0x3a2524,'rows':_0x258b0e}:null;})[_0x41ca61('0x4a')](respondWithResult(_0x53c158,null))[_0x41ca61('0x13')](handleError(_0x53c158,null));}; \ No newline at end of file +const a168_0x505a=['create','attrSerie1','userProfileId','clone','sort','DashboardItem','findOne','json','sequelize','where','set','order','pick','multibar-chart','options','updatedAt','intersection','destroy','offset','CustomDashboards','UserProfileResource','type','widgetAttributes:\x20%s','then','params','total','name','UserProfileSection','../../components/parsers/qs','catch','attrHourFormat','body','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','attrPath','custom','fieldName','sendStatus','stringify','value','findAll','keys','autoAssociation','attrReport','stack','Content-Range','attrSerie3','https://','query','omit','attrVoiceQueues','iframe','getItems','Unable\x20to\x20retrieve\x20the\x20current\x20user','createdAt','VIRTUAL','map','get','undefined','includeAll','model','error','clock','fields','end','Dashboard','attrTimezone','count','key','like','../../mysqldb','attributes','DashboardId','merge','attrs','attrUrl','status','pie-chart','user','include','attrSerie2','length','filters','register','rawAttributes','attrFontSize','limit','filter','web-report','attrMetric','attrRefresh','0.00','show','role','index'];(function(_0x19af0e,_0x505a29){const _0x2eab46=function(_0x5e59f5){while(--_0x5e59f5){_0x19af0e['push'](_0x19af0e['shift']());}};_0x2eab46(++_0x505a29);}(a168_0x505a,0x8c));const a168_0x2eab=function(_0x19af0e,_0x505a29){_0x19af0e=_0x19af0e-0x0;let _0x2eab46=a168_0x505a[_0x19af0e];return _0x2eab46;};const _0x372ff9=a168_0x2eab;'use strict';const _=require('lodash'),qs=require(_0x372ff9('0x4c')),logger=require('../../config/logger')('api'),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x372ff9('0x17'))['db'],{Op}=require(_0x372ff9('0x38'));require('./dashboard.socket')[_0x372ff9('0x24')](socket);function respondWithResult(_0x5e59f5,_0x203092){return _0x203092=_0x203092||0xc8,function(_0x1c4b81){const _0x2f73a2=a168_0x2eab;if(_0x1c4b81)return _0x5e59f5['status'](_0x203092)[_0x2f73a2('0x37')](_0x1c4b81);};}function respondWithFilteredResult(_0x42f674,_0x4843fd){return function(_0x276509){const _0x5cbdc0=a168_0x2eab;if(_0x276509){const _0xe178e5=_0x276509[_0x5cbdc0('0x14')],_0x255418=_0x4843fd['offset'];let _0x42e11d=_0x4843fd['offset']+_0x4843fd['limit'],_0x1ae2f2;return _0x42e11d>=_0xe178e5?(_0x42e11d=_0xe178e5,_0x1ae2f2=0xc8):_0x1ae2f2=0xce,_0x42f674[_0x5cbdc0('0x1d')](_0x1ae2f2),_0x42f674[_0x5cbdc0('0x3a')](_0x5cbdc0('0x5c'),_0x255418+'-'+_0x42e11d+'/'+_0xe178e5)[_0x5cbdc0('0x37')](_0x276509);}return null;};}function saveUpdates(_0x16ca14){return function(_0x1f95e4){const _0x569f2d=a168_0x2eab;if(_0x1f95e4)return _0x1f95e4['update'](_0x16ca14)[_0x569f2d('0x47')](function(_0x5f51ed){return _0x5f51ed;});return null;};}function removeEntity(_0xc410f9){return function(_0x5072ff){const _0x5344d9=a168_0x2eab;if(_0x5072ff)return _0x5072ff[_0x5344d9('0x41')]()[_0x5344d9('0x47')](function(){const _0x1f8089=_0x5344d9,_0x1b5cdb=_0x5072ff[_0x1f8089('0xa')]({'plain':!![]}),_0x422182='CustomDashboards';return db[_0x1f8089('0x44')][_0x1f8089('0x41')]({'where':{'type':_0x422182,'resourceId':_0x1b5cdb['id']}})[_0x1f8089('0x47')](function(){return _0x5072ff;});})[_0x5344d9('0x47')](function(){const _0x7692bf=_0x5344d9;_0xc410f9[_0x7692bf('0x1d')](0xcc)[_0x7692bf('0x11')]();});};}function handleEntityNotFound(_0x19ae1e){return function(_0x424509){const _0x4a84d9=a168_0x2eab;return!_0x424509&&_0x19ae1e[_0x4a84d9('0x54')](0x194),_0x424509;};}function handleError(_0x4ece56,_0x164cf7){return _0x164cf7=_0x164cf7||0x1f4,function(_0x480977){const _0x38d9e2=a168_0x2eab;logger[_0x38d9e2('0xe')](_0x480977[_0x38d9e2('0x5b')]),_0x480977[_0x38d9e2('0x4a')]&&delete _0x480977[_0x38d9e2('0x4a')],_0x4ece56[_0x38d9e2('0x1d')](_0x164cf7)['send'](_0x480977);};}exports[_0x372ff9('0x2f')]=function(_0x112062,_0x1c5a3c){const _0x2925bc=_0x372ff9;let _0x41631a={};const _0xf2f812={},_0xa1d226={'count':0x0,'rows':[]},_0xbe2ad0=_['map'](db[_0x2925bc('0x12')][_0x2925bc('0x25')],function(_0x18b7f4){const _0x236483=_0x2925bc;return{'name':_0x18b7f4[_0x236483('0x53')],'type':_0x18b7f4[_0x236483('0x45')][_0x236483('0x15')]};});_0xf2f812['model']=_[_0x2925bc('0x9')](_0xbe2ad0,_0x2925bc('0x4a')),_0xf2f812[_0x2925bc('0x1')]=_[_0x2925bc('0x58')](_0x112062[_0x2925bc('0x1')]),_0xf2f812[_0x2925bc('0x23')]=_['intersection'](_0xf2f812[_0x2925bc('0xd')],_0xf2f812[_0x2925bc('0x1')]),_0x41631a[_0x2925bc('0x18')]=_['intersection'](_0xf2f812[_0x2925bc('0xd')],qs[_0x2925bc('0x10')](_0x112062[_0x2925bc('0x1')][_0x2925bc('0x10')])),_0x41631a[_0x2925bc('0x18')]=_0x41631a[_0x2925bc('0x18')][_0x2925bc('0x22')]?_0x41631a[_0x2925bc('0x18')]:_0xf2f812[_0x2925bc('0xd')];typeof _0x112062[_0x2925bc('0x1')]['nolimit']===_0x2925bc('0xb')&&(_0x41631a[_0x2925bc('0x27')]=qs[_0x2925bc('0x27')](_0x112062['query']['limit']),_0x41631a[_0x2925bc('0x42')]=qs[_0x2925bc('0x42')](_0x112062[_0x2925bc('0x1')][_0x2925bc('0x42')]));_0x41631a[_0x2925bc('0x3b')]=qs[_0x2925bc('0x34')](_0x112062['query'][_0x2925bc('0x34')]),_0x41631a[_0x2925bc('0x39')]=qs[_0x2925bc('0x23')](_[_0x2925bc('0x3c')](_0x112062['query'],_0xf2f812['filters']),_0xbe2ad0);_0x112062[_0x2925bc('0x1')][_0x2925bc('0x28')]&&(_0x41631a['where']=_[_0x2925bc('0x1a')](_0x41631a[_0x2925bc('0x39')],{[Op['or']]:_[_0x2925bc('0x9')](_0xbe2ad0,function(_0x3c1fa4){const _0x24fbf3=_0x2925bc;if(_0x3c1fa4[_0x24fbf3('0x45')]!==_0x24fbf3('0x8')){const _0x1e3aa3={};return _0x1e3aa3[_0x3c1fa4[_0x24fbf3('0x4a')]]={[Op[_0x24fbf3('0x16')]]:'%'+_0x112062['query']['filter']+'%'},_0x1e3aa3;}})}));_0x41631a=_['merge']({},_0x41631a,_0x112062['options']);const _0x1cc5fe={'where':_0x41631a[_0x2925bc('0x39')]};return db[_0x2925bc('0x12')][_0x2925bc('0x14')](_0x1cc5fe)['then'](function(_0x5eea42){const _0x58d345=_0x2925bc;return _0xa1d226[_0x58d345('0x14')]=_0x5eea42,_0x112062[_0x58d345('0x1')]['includeAll']&&(_0x41631a[_0x58d345('0x20')]=[{'all':!![]}]),db[_0x58d345('0x12')][_0x58d345('0x57')](_0x41631a);})['then'](function(_0x43636d){return _0xa1d226['rows']=_0x43636d,_0xa1d226;})[_0x2925bc('0x47')](respondWithFilteredResult(_0x1c5a3c,_0x41631a))[_0x2925bc('0x4d')](handleError(_0x1c5a3c,null));},exports[_0x372ff9('0x2d')]=function(_0xd52523,_0x4db35e){const _0x389f91=_0x372ff9;let _0x1b9d8d={'raw':![],'where':{'id':_0xd52523[_0x389f91('0x48')]['id']}};const _0x3112fa={};return _0x3112fa[_0x389f91('0xd')]=_[_0x389f91('0x58')](db['Dashboard'][_0x389f91('0x25')]),_0x3112fa['query']=_['keys'](_0xd52523[_0x389f91('0x1')]),_0x3112fa[_0x389f91('0x23')]=_[_0x389f91('0x40')](_0x3112fa['model'],_0x3112fa[_0x389f91('0x1')]),_0x1b9d8d[_0x389f91('0x18')]=_['intersection'](_0x3112fa['model'],qs[_0x389f91('0x10')](_0xd52523[_0x389f91('0x1')][_0x389f91('0x10')])),_0x1b9d8d[_0x389f91('0x18')]=_0x1b9d8d['attributes']['length']?_0x1b9d8d[_0x389f91('0x18')]:_0x3112fa[_0x389f91('0xd')],_0xd52523[_0x389f91('0x1')][_0x389f91('0xc')]&&(_0x1b9d8d[_0x389f91('0x20')]=[{'all':!![]}]),_0x1b9d8d=_[_0x389f91('0x1a')]({},_0x1b9d8d,_0xd52523[_0x389f91('0x3e')]),db[_0x389f91('0x12')][_0x389f91('0x36')](_0x1b9d8d)[_0x389f91('0x47')](handleEntityNotFound(_0x4db35e,null))['then'](respondWithResult(_0x4db35e,null))[_0x389f91('0x4d')](handleError(_0x4db35e,null));},exports[_0x372ff9('0x30')]=function(_0x1da8e9,_0x46b8f8){const _0x4d7673=_0x372ff9;return db[_0x4d7673('0x12')][_0x4d7673('0x30')](_0x1da8e9['body'],{})[_0x4d7673('0x47')](function(_0x74d8d4){const _0x4c20a4=_0x4d7673,_0x271166=_0x1da8e9[_0x4c20a4('0x1f')]['get']({'plain':!![]});if(!_0x271166)throw new Error(_0x4c20a4('0x6'));if(_0x271166['role']===_0x4c20a4('0x1f')){const _0x247000=_0x74d8d4[_0x4c20a4('0xa')]({'plain':!![]}),_0x5d7cdc=_0x4c20a4('0x43');return db[_0x4c20a4('0x4b')][_0x4c20a4('0x36')]({'where':{'name':_0x5d7cdc,'userProfileId':_0x271166[_0x4c20a4('0x32')]},'raw':!![]})[_0x4c20a4('0x47')](function(_0xa6e3e){return _0xa6e3e&&_0xa6e3e['autoAssociation']===0x0?db['UserProfileResource']['create']({'name':_0x247000['name'],'resourceId':_0x247000['id'],'type':_0xa6e3e['name'],'sectionId':_0xa6e3e['id']},{})['then'](function(){return _0x74d8d4;}):_0x74d8d4;})[_0x4c20a4('0x4d')](function(_0x16bf3f){const _0x10ea27=_0x4c20a4;logger[_0x10ea27('0xe')](_0x10ea27('0x50'),_0x16bf3f);throw _0x16bf3f;});}return _0x74d8d4;})[_0x4d7673('0x47')](respondWithResult(_0x46b8f8,0xc9))['catch'](handleError(_0x46b8f8,null));},exports[_0x372ff9('0x33')]=function(_0x4b0323,_0x2ebe02){const _0x517804=_0x372ff9;let _0x2d27e6={'where':{'id':_0x4b0323[_0x517804('0x48')]['id']}};const _0x1f6ac3={};return _0x1f6ac3[_0x517804('0xd')]=_[_0x517804('0x58')](db[_0x517804('0x12')][_0x517804('0x25')]),_0x2d27e6[_0x517804('0x18')]=_[_0x517804('0x40')](_0x1f6ac3[_0x517804('0xd')],qs['fields'](_0x4b0323['query'][_0x517804('0x10')])),_0x2d27e6['attributes']=_0x2d27e6[_0x517804('0x18')]['length']?_0x2d27e6[_0x517804('0x18')]:_0x1f6ac3['model'],_0x4b0323[_0x517804('0x1')][_0x517804('0xc')]&&(_0x2d27e6[_0x517804('0x20')]=[{'all':!![]}]),_0x2d27e6=_[_0x517804('0x1a')]({},_0x2d27e6,_0x4b0323[_0x517804('0x3e')]),db[_0x517804('0x12')][_0x517804('0x36')](_0x2d27e6)[_0x517804('0x47')](handleEntityNotFound(_0x2ebe02,null))['then'](function(_0x50e9f5){const _0x7c97e5=_0x517804;if(_0x50e9f5){let _0x239585=_0x50e9f5[_0x7c97e5('0xa')]({'plain':!![]});return _0x239585=qs[_0x7c97e5('0x2')](_0x239585,['id',_0x7c97e5('0x7'),_0x7c97e5('0x3f')]),_0x4b0323[_0x7c97e5('0x4f')]=_['omit'](_0x4b0323[_0x7c97e5('0x4f')],['id','createdAt',_0x7c97e5('0x3f')]),db[_0x7c97e5('0x12')][_0x7c97e5('0x30')](_[_0x7c97e5('0x1a')](_0x239585,_0x4b0323['body']),{'include':_0x4b0323['query']['includeAll']?[{'all':!![]}]:undefined})[_0x7c97e5('0x47')](function(_0x541397){const _0x1b8ce7=_0x7c97e5,_0x33743b=_0x4b0323[_0x1b8ce7('0x1f')][_0x1b8ce7('0xa')]({'plain':!![]});if(!_0x33743b)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x33743b[_0x1b8ce7('0x2e')]===_0x1b8ce7('0x1f')){const _0x3233a2=_0x541397[_0x1b8ce7('0xa')]({'plain':!![]}),_0x40b05f=_0x1b8ce7('0x43');return db['UserProfileSection'][_0x1b8ce7('0x36')]({'where':{'name':_0x40b05f,'userProfileId':_0x33743b[_0x1b8ce7('0x32')]},'raw':!![]})[_0x1b8ce7('0x47')](function(_0x152b4b){const _0x5c8a0b=_0x1b8ce7;return _0x152b4b&&_0x152b4b[_0x5c8a0b('0x59')]===0x0?db['UserProfileResource'][_0x5c8a0b('0x30')]({'name':_0x3233a2[_0x5c8a0b('0x4a')],'resourceId':_0x3233a2['id'],'type':_0x152b4b[_0x5c8a0b('0x4a')],'sectionId':_0x152b4b['id']},{})[_0x5c8a0b('0x47')](function(){return _0x541397;}):_0x541397;})[_0x1b8ce7('0x4d')](function(_0x4a00ce){const _0x1fb4d2=_0x1b8ce7;logger['error'](_0x1fb4d2('0x50'),_0x4a00ce);throw _0x4a00ce;});}return _0x541397;});}})[_0x517804('0x47')](respondWithResult(_0x2ebe02,0xc9))[_0x517804('0x4d')](handleError(_0x2ebe02,null));},exports['update']=function(_0x536e89,_0x2f7fc5){const _0x5d7f93=_0x372ff9;return _0x536e89[_0x5d7f93('0x4f')]['id']&&delete _0x536e89[_0x5d7f93('0x4f')]['id'],db[_0x5d7f93('0x12')][_0x5d7f93('0x36')]({'where':{'id':_0x536e89[_0x5d7f93('0x48')]['id']}})['then'](handleEntityNotFound(_0x2f7fc5,null))[_0x5d7f93('0x47')](saveUpdates(_0x536e89[_0x5d7f93('0x4f')],null))[_0x5d7f93('0x47')](respondWithResult(_0x2f7fc5,null))[_0x5d7f93('0x4d')](handleError(_0x2f7fc5,null));},exports['destroy']=function(_0x176926,_0x45b25e){const _0x31cd11=_0x372ff9;return db[_0x31cd11('0x12')]['findOne']({'where':{'id':_0x176926['params']['id']}})[_0x31cd11('0x47')](handleEntityNotFound(_0x45b25e,null))[_0x31cd11('0x47')](removeEntity(_0x45b25e,null))['catch'](handleError(_0x45b25e,null));};function widgetAttributes(_0x2725c0){const _0x5080cb=_0x372ff9;try{switch(_0x2725c0[_0x5080cb('0x45')]){case _0x5080cb('0x4'):return[{'name':_0x5080cb('0x1c'),'value':_0x2725c0['attrUrl']||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0['attrs'][0x0]?_0x2725c0[_0x5080cb('0x1b')][0x0][_0x5080cb('0x56')]:undefined)||_0x5080cb('0x0')}];case _0x5080cb('0x52'):return[{'name':_0x5080cb('0x51'),'value':_0x2725c0[_0x5080cb('0x51')]||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0['attrs'][0x0]?_0x2725c0[_0x5080cb('0x1b')][0x0][_0x5080cb('0x56')]:undefined)||''}];case _0x5080cb('0xf'):return[{'name':'attrHourFormat','value':_0x2725c0[_0x5080cb('0x4e')]||(_0x2725c0['attrs']&&_0x2725c0[_0x5080cb('0x1b')][0x0]?_0x2725c0[_0x5080cb('0x1b')][0x0][_0x5080cb('0x56')]:undefined)||'HH:mm:ss'},{'name':_0x5080cb('0x13'),'value':_0x2725c0['attrTimezone']||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0[_0x5080cb('0x1b')][0x1]?_0x2725c0[_0x5080cb('0x1b')][0x1]['value']:undefined)||_0x5080cb('0x2c')},{'name':_0x5080cb('0x26'),'value':_0x2725c0[_0x5080cb('0x26')]||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0[_0x5080cb('0x1b')][0x2]?_0x2725c0[_0x5080cb('0x1b')][0x2][_0x5080cb('0x56')]:undefined)||0xc}];case'counter':return[{'name':_0x5080cb('0x2a'),'value':_0x2725c0['attrMetric']||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0[_0x5080cb('0x1b')][0x0]?_0x2725c0[_0x5080cb('0x1b')][0x0][_0x5080cb('0x56')]:undefined)||'total'},{'name':_0x5080cb('0x3'),'value':_0x2725c0[_0x5080cb('0x3')]||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0[_0x5080cb('0x1b')][0x1]?_0x2725c0[_0x5080cb('0x1b')][0x1][_0x5080cb('0x56')]:undefined)||[]},{'name':_0x5080cb('0x26'),'value':_0x2725c0[_0x5080cb('0x26')]||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0[_0x5080cb('0x1b')][0x2]?_0x2725c0[_0x5080cb('0x1b')][0x2][_0x5080cb('0x56')]:undefined)||0x14}];case _0x5080cb('0x3d'):case _0x5080cb('0x1e'):return[{'name':_0x5080cb('0x31'),'value':_0x2725c0[_0x5080cb('0x31')]||(_0x2725c0['attrs']&&_0x2725c0[_0x5080cb('0x1b')][0x0]?_0x2725c0[_0x5080cb('0x1b')][0x0][_0x5080cb('0x56')]:undefined)||_0x5080cb('0x49')},{'name':'attrSerie2','value':_0x2725c0[_0x5080cb('0x21')]||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0['attrs'][0x1]?_0x2725c0[_0x5080cb('0x1b')][0x1][_0x5080cb('0x56')]:undefined)||null},{'name':_0x5080cb('0x5d'),'value':_0x2725c0['attrSerie3']||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0[_0x5080cb('0x1b')][0x2]?_0x2725c0['attrs'][0x2]['value']:undefined)||null},{'name':'attrVoiceQueues','value':_0x2725c0[_0x5080cb('0x3')]||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0[_0x5080cb('0x1b')][0x3]?_0x2725c0[_0x5080cb('0x1b')][0x3][_0x5080cb('0x56')]:undefined)||[]}];case _0x5080cb('0x29'):return[{'name':'attrReport','type':_0x2725c0['reportType']||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0[_0x5080cb('0x1b')][0x0]?_0x2725c0[_0x5080cb('0x1b')][0x0]['type']:undefined)||null,'value':_0x2725c0[_0x5080cb('0x5a')]||(_0x2725c0[_0x5080cb('0x1b')]&&_0x2725c0[_0x5080cb('0x1b')][0x0]?_0x2725c0[_0x5080cb('0x1b')][0x0][_0x5080cb('0x56')]:undefined)||null},{'name':_0x5080cb('0x2b'),'value':_0x2725c0[_0x5080cb('0x2b')]||(_0x2725c0['attrs']&&_0x2725c0['attrs'][0x1]?_0x2725c0[_0x5080cb('0x1b')][0x1][_0x5080cb('0x56')]:undefined)||0x0}];default:return[];}}catch(_0x25c569){return logger['error'](_0x5080cb('0x46'),JSON[_0x5080cb('0x55')](_0x25c569)),[];}}exports['addItem']=function(_0x39a420,_0xdcc9bf){const _0x2804ec=_0x372ff9;return _0x39a420[_0x2804ec('0x4f')]['id']&&delete _0x39a420[_0x2804ec('0x4f')]['id'],db['Dashboard'][_0x2804ec('0x36')]({'where':{'id':_0x39a420['params']['id']}})[_0x2804ec('0x47')](handleEntityNotFound(_0xdcc9bf,null))[_0x2804ec('0x47')](function(_0x1f71db){const _0x1a70b3=_0x2804ec;if(_0x1f71db)return _0x39a420['body'][_0x1a70b3('0x19')]=_0x1f71db['id'],_0x39a420['body'][_0x1a70b3('0x1b')]=widgetAttributes(_0x39a420[_0x1a70b3('0x4f')]),db[_0x1a70b3('0x35')][_0x1a70b3('0x30')](_0x39a420[_0x1a70b3('0x4f')]);})['then'](respondWithResult(_0xdcc9bf,null))[_0x2804ec('0x4d')](handleError(_0xdcc9bf,null));},exports[_0x372ff9('0x5')]=function(_0x11c326,_0x2be1e8){const _0x2a7741=_0x372ff9;let _0x225825={};const _0xe57bda={};let _0x39fa6e,_0xc0c18b;return db[_0x2a7741('0x12')][_0x2a7741('0x36')]({'where':{'id':_0x11c326[_0x2a7741('0x48')]['id']}})[_0x2a7741('0x47')](handleEntityNotFound(_0x2be1e8,null))['then'](function(_0x56f77e){const _0x4a0622=_0x2a7741;if(_0x56f77e)return _0x39fa6e=_0x56f77e,_0xe57bda[_0x4a0622('0xd')]=_[_0x4a0622('0x58')](db[_0x4a0622('0x35')][_0x4a0622('0x25')]),_0xe57bda[_0x4a0622('0x1')]=_['keys'](_0x11c326[_0x4a0622('0x1')]),_0xe57bda[_0x4a0622('0x23')]=_[_0x4a0622('0x40')](_0xe57bda['model'],_0xe57bda[_0x4a0622('0x1')]),_0x225825[_0x4a0622('0x18')]=_[_0x4a0622('0x40')](_0xe57bda[_0x4a0622('0xd')],qs[_0x4a0622('0x10')](_0x11c326['query'][_0x4a0622('0x10')])),_0x225825[_0x4a0622('0x18')]=_0x225825[_0x4a0622('0x18')]['length']?_0x225825['attributes']:_0xe57bda['model'],_0x225825[_0x4a0622('0x3b')]=qs[_0x4a0622('0x34')](_0x11c326[_0x4a0622('0x1')][_0x4a0622('0x34')]),_0x225825[_0x4a0622('0x39')]=qs[_0x4a0622('0x23')](_['pick'](_0x11c326[_0x4a0622('0x1')],_0xe57bda[_0x4a0622('0x23')])),_0x11c326[_0x4a0622('0x1')][_0x4a0622('0x28')]&&(_0x225825['where']=_['merge'](_0x225825[_0x4a0622('0x39')],{[Op['or']]:_[_0x4a0622('0x9')](_0x225825[_0x4a0622('0x18')],function(_0x172d4b){const _0x2cd599=_0x4a0622,_0x501132={};return _0x501132[_0x172d4b]={[Op[_0x2cd599('0x16')]]:'%'+_0x11c326[_0x2cd599('0x1')]['filter']+'%'},_0x501132;})})),_0x225825=_[_0x4a0622('0x1a')]({},_0x225825,_0x11c326[_0x4a0622('0x3e')]),_0x39fa6e[_0x4a0622('0x5')](_0x225825);})['then'](function(_0xce77b){const _0x437de6=_0x2a7741;if(_0xce77b)return _0xc0c18b=_0xce77b['length'],typeof _0x11c326['query']['nolimit']===_0x437de6('0xb')&&(_0x225825['limit']=qs[_0x437de6('0x27')](_0x11c326[_0x437de6('0x1')][_0x437de6('0x27')]),_0x225825[_0x437de6('0x42')]=qs[_0x437de6('0x42')](_0x11c326[_0x437de6('0x1')][_0x437de6('0x42')])),_0x39fa6e[_0x437de6('0x5')](_0x225825);})[_0x2a7741('0x47')](function(_0x4eca10){if(_0x4eca10)return _0x4eca10?{'count':_0xc0c18b,'rows':_0x4eca10}:null;})[_0x2a7741('0x47')](respondWithResult(_0x2be1e8,null))[_0x2a7741('0x4d')](handleError(_0x2be1e8,null));}; \ No newline at end of file diff --git a/server/api/dashboard/dashboard.events.js b/server/api/dashboard/dashboard.events.js index 2ad0e5e..83c051e 100644 --- a/server/api/dashboard/dashboard.events.js +++ b/server/api/dashboard/dashboard.events.js @@ -1 +1 @@ -const a169_0x5c9f=['Dashboard','events','undefined','remove','../../mysqldb','update','exports','save','emit','addHook','setMaxListeners'];(function(_0x4e32f3,_0x5c9fda){const _0x473f92=function(_0x4517d0){while(--_0x4517d0){_0x4e32f3['push'](_0x4e32f3['shift']());}};_0x473f92(++_0x5c9fda);}(a169_0x5c9f,0xd4));const a169_0x473f=function(_0x4e32f3,_0x5c9fda){_0x4e32f3=_0x4e32f3-0x0;let _0x473f92=a169_0x5c9f[_0x4e32f3];return _0x473f92;};const _0x28fee2=a169_0x473f;'use strict';const EventEmitter=require(_0x28fee2('0x9')),Dashboard=require(_0x28fee2('0x1'))['db'][_0x28fee2('0x8')],DashboardEvents=new EventEmitter();DashboardEvents[_0x28fee2('0x7')](0x0);const events={'afterCreate':_0x28fee2('0x4'),'afterUpdate':_0x28fee2('0x2'),'afterDestroy':_0x28fee2('0x0')};function emitEvent(_0x4517d0){return function(_0x4909c7){const _0x43ea45=a169_0x473f;DashboardEvents[_0x43ea45('0x5')](_0x4517d0+':'+_0x4909c7['id'],_0x4909c7),DashboardEvents[_0x43ea45('0x5')](_0x4517d0,_0x4909c7);};}for(const e in events){if(typeof events[e]!==_0x28fee2('0xa')){const event=events[e];Dashboard[_0x28fee2('0x6')](e,emitEvent(event));}}module[_0x28fee2('0x3')]=DashboardEvents; \ No newline at end of file +const a169_0xf3a4=['undefined','setMaxListeners','update','Dashboard','save','emit','remove','../../mysqldb','addHook'];(function(_0x109289,_0xf3a476){const _0x2ce91c=function(_0x1d0559){while(--_0x1d0559){_0x109289['push'](_0x109289['shift']());}};_0x2ce91c(++_0xf3a476);}(a169_0xf3a4,0x1ad));const a169_0x2ce9=function(_0x109289,_0xf3a476){_0x109289=_0x109289-0x0;let _0x2ce91c=a169_0xf3a4[_0x109289];return _0x2ce91c;};const _0x781e3d=a169_0x2ce9;'use strict';const EventEmitter=require('events'),Dashboard=require(_0x781e3d('0x1'))['db'][_0x781e3d('0x6')],DashboardEvents=new EventEmitter();DashboardEvents[_0x781e3d('0x4')](0x0);const events={'afterCreate':_0x781e3d('0x7'),'afterUpdate':_0x781e3d('0x5'),'afterDestroy':_0x781e3d('0x0')};function emitEvent(_0x1d0559){return function(_0x4f14ba){const _0x1e122d=a169_0x2ce9;DashboardEvents[_0x1e122d('0x8')](_0x1d0559+':'+_0x4f14ba['id'],_0x4f14ba),DashboardEvents[_0x1e122d('0x8')](_0x1d0559,_0x4f14ba);};}for(const e in events){if(typeof events[e]!==_0x781e3d('0x3')){const event=events[e];Dashboard[_0x781e3d('0x2')](e,emitEvent(event));}}module['exports']=DashboardEvents; \ No newline at end of file diff --git a/server/api/dashboard/dashboard.model.js b/server/api/dashboard/dashboard.model.js index b154b84..c65e3e6 100644 --- a/server/api/dashboard/dashboard.model.js +++ b/server/api/dashboard/dashboard.model.js @@ -1 +1 @@ -const a170_0x3537=['exports','dashboards','./dashboard.attributes','Dashboard','define'];(function(_0x55b859,_0x3537dc){const _0x282d27=function(_0x56e1e4){while(--_0x56e1e4){_0x55b859['push'](_0x55b859['shift']());}};_0x282d27(++_0x3537dc);}(a170_0x3537,0x156));const a170_0x282d=function(_0x55b859,_0x3537dc){_0x55b859=_0x55b859-0x0;let _0x282d27=a170_0x3537[_0x55b859];return _0x282d27;};const _0xefddcd=a170_0x282d;'use strict';const attributes=require(_0xefddcd('0x0'));module[_0xefddcd('0x3')]=function(_0x56e1e4){const _0x48fe3f=_0xefddcd,_0x4bd7dd=_0x56e1e4[_0x48fe3f('0x2')](_0x48fe3f('0x1'),attributes,{'tableName':_0x48fe3f('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x4bd7dd;}; \ No newline at end of file +const a170_0x564e=['define','exports'];(function(_0x4c92ac,_0x564eb1){const _0x5d94c7=function(_0x3fcfe2){while(--_0x3fcfe2){_0x4c92ac['push'](_0x4c92ac['shift']());}};_0x5d94c7(++_0x564eb1);}(a170_0x564e,0x175));const a170_0x5d94=function(_0x4c92ac,_0x564eb1){_0x4c92ac=_0x4c92ac-0x0;let _0x5d94c7=a170_0x564e[_0x4c92ac];return _0x5d94c7;};const _0x5e15c2=a170_0x5d94;'use strict';const attributes=require('./dashboard.attributes');module[_0x5e15c2('0x0')]=function(_0x3fcfe2){const _0x2d427a=_0x5e15c2,_0x25c890=_0x3fcfe2[_0x2d427a('0x1')]('Dashboard',attributes,{'tableName':'dashboards','paranoid':![],'indexes':[],'timestamps':!![]});return _0x25c890;}; \ No newline at end of file diff --git a/server/api/dashboard/dashboard.rpc.js b/server/api/dashboard/dashboard.rpc.js index 0e76720..e9efdef 100644 --- a/server/api/dashboard/dashboard.rpc.js +++ b/server/api/dashboard/dashboard.rpc.js @@ -1 +1 @@ -const a171_0x18df=['./dashboard.socket','../../rediscache'];(function(_0x1aaf88,_0x18dfda){const _0x154e03=function(_0x4166e9){while(--_0x4166e9){_0x1aaf88['push'](_0x1aaf88['shift']());}};_0x154e03(++_0x18dfda);}(a171_0x18df,0x1bb));const a171_0x154e=function(_0x1aaf88,_0x18dfda){_0x1aaf88=_0x1aaf88-0x0;let _0x154e03=a171_0x18df[_0x1aaf88];return _0x154e03;};const _0x48e2ea=a171_0x154e;'use strict';const {getSocket}=require(_0x48e2ea('0x0')),socket=getSocket();require(_0x48e2ea('0x1'))['register'](socket); \ No newline at end of file +const a171_0x35f3=['register','../../rediscache','./dashboard.socket'];(function(_0x3c6182,_0x35f34b){const _0x51f410=function(_0x5c2e8f){while(--_0x5c2e8f){_0x3c6182['push'](_0x3c6182['shift']());}};_0x51f410(++_0x35f34b);}(a171_0x35f3,0x84));const a171_0x51f4=function(_0x3c6182,_0x35f34b){_0x3c6182=_0x3c6182-0x0;let _0x51f410=a171_0x35f3[_0x3c6182];return _0x51f410;};const _0x4d4466=a171_0x51f4;'use strict';const {getSocket}=require(_0x4d4466('0x1')),socket=getSocket();require(_0x4d4466('0x2'))[_0x4d4466('0x0')](socket); \ No newline at end of file diff --git a/server/api/dashboard/dashboard.socket.js b/server/api/dashboard/dashboard.socket.js index 9ae1f88..1cd2353 100644 --- a/server/api/dashboard/dashboard.socket.js +++ b/server/api/dashboard/dashboard.socket.js @@ -1 +1 @@ -const a172_0x5052=['remove','emit','update','length','register','./dashboard.events','dashboard:'];(function(_0x39c42a,_0x50522a){const _0x38444b=function(_0x1c376c){while(--_0x1c376c){_0x39c42a['push'](_0x39c42a['shift']());}};_0x38444b(++_0x50522a);}(a172_0x5052,0xe2));const a172_0x3844=function(_0x39c42a,_0x50522a){_0x39c42a=_0x39c42a-0x0;let _0x38444b=a172_0x5052[_0x39c42a];return _0x38444b;};const _0xcdaaae=a172_0x3844;'use strict';const DashboardEvents=require(_0xcdaaae('0x3')),events=['save',_0xcdaaae('0x5'),_0xcdaaae('0x0')];function createListener(_0x1c376c,_0xbe9581){return function(_0x6ebaf6){const _0x1b62af=a172_0x3844;_0xbe9581[_0x1b62af('0x6')](_0x1c376c,_0x6ebaf6);};}exports[_0xcdaaae('0x2')]=function(_0x25165c){const _0x508efa=_0xcdaaae;for(let _0x5c557b=0x0,_0x39253e=events[_0x508efa('0x1')];_0x5c557b<_0x39253e;_0x5c557b++){const _0x1a6ac5=events[_0x5c557b],_0x5e6e1b=createListener(_0x508efa('0x4')+_0x1a6ac5,_0x25165c);DashboardEvents['on'](_0x1a6ac5,_0x5e6e1b);}}; \ No newline at end of file +const a172_0x102e=['remove','./dashboard.events','save','length','dashboard:','emit'];(function(_0x516f40,_0x102e53){const _0x4c3b3d=function(_0xc816c8){while(--_0xc816c8){_0x516f40['push'](_0x516f40['shift']());}};_0x4c3b3d(++_0x102e53);}(a172_0x102e,0x124));const a172_0x4c3b=function(_0x516f40,_0x102e53){_0x516f40=_0x516f40-0x0;let _0x4c3b3d=a172_0x102e[_0x516f40];return _0x4c3b3d;};const _0x1021c0=a172_0x4c3b;'use strict';const DashboardEvents=require(_0x1021c0('0x3')),events=[_0x1021c0('0x4'),_0x1021c0('0x2'),'update'];function createListener(_0xc816c8,_0x311612){return function(_0xe40a5a){const _0x4219e2=a172_0x4c3b;_0x311612[_0x4219e2('0x1')](_0xc816c8,_0xe40a5a);};}exports['register']=function(_0x5dcba5){const _0x11ae86=_0x1021c0;for(let _0x53d9e8=0x0,_0x569def=events[_0x11ae86('0x5')];_0x53d9e8<_0x569def;_0x53d9e8++){const _0x496669=events[_0x53d9e8],_0x22a804=createListener(_0x11ae86('0x0')+_0x496669,_0x5dcba5);DashboardEvents['on'](_0x496669,_0x22a804);}}; \ No newline at end of file diff --git a/server/api/dashboard/index.js b/server/api/dashboard/index.js index 06db137..0447f4e 100644 --- a/server/api/dashboard/index.js +++ b/server/api/dashboard/index.js @@ -1 +1 @@ -const a173_0x35a8=['/:id','create','addItem','update','/:id/items','isAuthenticated','show','post','get','clone','put','delete','exports','getItems','express','Router','./dashboard.controller'];(function(_0x59e4c8,_0x35a813){const _0x12d35e=function(_0x29aebe){while(--_0x29aebe){_0x59e4c8['push'](_0x59e4c8['shift']());}};_0x12d35e(++_0x35a813);}(a173_0x35a8,0x10c));const a173_0x12d3=function(_0x59e4c8,_0x35a813){_0x59e4c8=_0x59e4c8-0x0;let _0x12d35e=a173_0x35a8[_0x59e4c8];return _0x12d35e;};const _0x34e698=a173_0x12d3;'use strict';const express=require(_0x34e698('0x1')),router=express[_0x34e698('0x2')](),auth=require('../../components/auth/service'),controller=require(_0x34e698('0x3'));router[_0x34e698('0xc')]('/',auth[_0x34e698('0x9')](),controller['index']),router[_0x34e698('0xc')](_0x34e698('0x4'),auth[_0x34e698('0x9')](),controller[_0x34e698('0xa')]),router['get'](_0x34e698('0x8'),auth[_0x34e698('0x9')](),controller[_0x34e698('0x0')]),router['post']('/',auth['isAuthenticated'](),controller[_0x34e698('0x5')]),router[_0x34e698('0xb')]('/:id/clone',auth[_0x34e698('0x9')](),controller[_0x34e698('0xd')]),router[_0x34e698('0xb')](_0x34e698('0x8'),auth[_0x34e698('0x9')](),controller[_0x34e698('0x6')]),router[_0x34e698('0xe')](_0x34e698('0x4'),auth['isAuthenticated'](),controller[_0x34e698('0x7')]),router[_0x34e698('0xf')](_0x34e698('0x4'),auth['isAuthenticated'](),controller['destroy']),module[_0x34e698('0x10')]=router; \ No newline at end of file +const a173_0xbb73=['./dashboard.controller','create','destroy','update','show','exports','getItems','/:id','delete','get','isAuthenticated','Router','post','/:id/clone','/:id/items','../../components/auth/service','index'];(function(_0x1b355c,_0xbb73c1){const _0x54397a=function(_0x56b254){while(--_0x56b254){_0x1b355c['push'](_0x1b355c['shift']());}};_0x54397a(++_0xbb73c1);}(a173_0xbb73,0x1ca));const a173_0x5439=function(_0x1b355c,_0xbb73c1){_0x1b355c=_0x1b355c-0x0;let _0x54397a=a173_0xbb73[_0x1b355c];return _0x54397a;};const _0x28e2f0=a173_0x5439;'use strict';const express=require('express'),router=express[_0x28e2f0('0xc')](),auth=require(_0x28e2f0('0x10')),controller=require(_0x28e2f0('0x1'));router[_0x28e2f0('0xa')]('/',auth['isAuthenticated'](),controller[_0x28e2f0('0x0')]),router[_0x28e2f0('0xa')](_0x28e2f0('0x8'),auth[_0x28e2f0('0xb')](),controller[_0x28e2f0('0x5')]),router['get']('/:id/items',auth[_0x28e2f0('0xb')](),controller[_0x28e2f0('0x7')]),router[_0x28e2f0('0xd')]('/',auth[_0x28e2f0('0xb')](),controller[_0x28e2f0('0x2')]),router[_0x28e2f0('0xd')](_0x28e2f0('0xe'),auth[_0x28e2f0('0xb')](),controller['clone']),router[_0x28e2f0('0xd')](_0x28e2f0('0xf'),auth[_0x28e2f0('0xb')](),controller['addItem']),router['put'](_0x28e2f0('0x8'),auth[_0x28e2f0('0xb')](),controller[_0x28e2f0('0x4')]),router[_0x28e2f0('0x9')]('/:id',auth[_0x28e2f0('0xb')](),controller[_0x28e2f0('0x3')]),module[_0x28e2f0('0x6')]=router; \ No newline at end of file diff --git a/server/api/dashboardItem/dashboardItem.attributes.js b/server/api/dashboardItem/dashboardItem.attributes.js index 4606118..1d9082e 100644 --- a/server/api/dashboardItem/dashboardItem.attributes.js +++ b/server/api/dashboardItem/dashboardItem.attributes.js @@ -1 +1 @@ -const a174_0xfad7=['long','INTEGER','setDataValue','sequelize','#ffffff','#2196f3','attrs','STRING','getDataValue','stringify'];(function(_0x55c2d6,_0xfad7e2){const _0x2670da=function(_0x4600e8){while(--_0x4600e8){_0x55c2d6['push'](_0x55c2d6['shift']());}};_0x2670da(++_0xfad7e2);}(a174_0xfad7,0x64));const a174_0x2670=function(_0x55c2d6,_0xfad7e2){_0x55c2d6=_0x55c2d6-0x0;let _0x2670da=a174_0xfad7[_0x55c2d6];return _0x2670da;};const _0x3b1cc4=a174_0x2670;'use strict';const Sequelize=require(_0x3b1cc4('0x3'));module['exports']={'title':{'type':Sequelize[_0x3b1cc4('0x7')],'allowNull':![]},'type':{'type':Sequelize['STRING'](0x14),'allowNull':![],'validate':{'len':[0x1,0x14]}},'attrs':{'type':Sequelize['TEXT'](_0x3b1cc4('0x0')),'get':function(){const _0x8e4e29=_0x3b1cc4;try{return JSON['parse'](this[_0x8e4e29('0x8')](_0x8e4e29('0x6')));}catch(_0x4600e8){return[];}},'set':function(_0x479c2e){const _0x5d8053=_0x3b1cc4;try{this[_0x5d8053('0x2')](_0x5d8053('0x6'),JSON[_0x5d8053('0x9')](_0x479c2e));}catch(_0x1c11c6){this[_0x5d8053('0x2')](_0x5d8053('0x6'),JSON[_0x5d8053('0x9')]([]));}}},'sizeX':{'type':Sequelize[_0x3b1cc4('0x1')],'allowNull':![],'defaultValue':0x1},'sizeY':{'type':Sequelize[_0x3b1cc4('0x1')],'allowNull':![],'defaultValue':0x1},'row':{'type':Sequelize['INTEGER']},'col':{'type':Sequelize[_0x3b1cc4('0x1')]},'background':{'type':Sequelize[_0x3b1cc4('0x7')],'allowNull':![],'defaultValue':_0x3b1cc4('0x4'),'validate':{'notEmpty':!![]}},'foreground':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x3b1cc4('0x5'),'validate':{'notEmpty':!![]}},'link':{'type':Sequelize[_0x3b1cc4('0x7')]}}; \ No newline at end of file +const a174_0x2684=['stringify','#2196f3','INTEGER','long','parse','TEXT','attrs','setDataValue','exports','STRING'];(function(_0x1986ae,_0x26844c){const _0x52f7b5=function(_0x498b0a){while(--_0x498b0a){_0x1986ae['push'](_0x1986ae['shift']());}};_0x52f7b5(++_0x26844c);}(a174_0x2684,0x180));const a174_0x52f7=function(_0x1986ae,_0x26844c){_0x1986ae=_0x1986ae-0x0;let _0x52f7b5=a174_0x2684[_0x1986ae];return _0x52f7b5;};const _0x2551dc=a174_0x52f7;'use strict';const Sequelize=require('sequelize');module[_0x2551dc('0x4')]={'title':{'type':Sequelize[_0x2551dc('0x5')],'allowNull':![]},'type':{'type':Sequelize[_0x2551dc('0x5')](0x14),'allowNull':![],'validate':{'len':[0x1,0x14]}},'attrs':{'type':Sequelize[_0x2551dc('0x1')](_0x2551dc('0x9')),'get':function(){const _0x4b86a3=_0x2551dc;try{return JSON[_0x4b86a3('0x0')](this['getDataValue'](_0x4b86a3('0x2')));}catch(_0x498b0a){return[];}},'set':function(_0x547acd){const _0x54afab=_0x2551dc;try{this[_0x54afab('0x3')](_0x54afab('0x2'),JSON['stringify'](_0x547acd));}catch(_0x19b486){this['setDataValue']('attrs',JSON[_0x54afab('0x6')]([]));}}},'sizeX':{'type':Sequelize[_0x2551dc('0x8')],'allowNull':![],'defaultValue':0x1},'sizeY':{'type':Sequelize[_0x2551dc('0x8')],'allowNull':![],'defaultValue':0x1},'row':{'type':Sequelize[_0x2551dc('0x8')]},'col':{'type':Sequelize[_0x2551dc('0x8')]},'background':{'type':Sequelize[_0x2551dc('0x5')],'allowNull':![],'defaultValue':'#ffffff','validate':{'notEmpty':!![]}},'foreground':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x2551dc('0x7'),'validate':{'notEmpty':!![]}},'link':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/dashboardItem/dashboardItem.controller.js b/server/api/dashboardItem/dashboardItem.controller.js index 41c4f1e..eec5cf2 100644 --- a/server/api/dashboardItem/dashboardItem.controller.js +++ b/server/api/dashboardItem/dashboardItem.controller.js @@ -1 +1 @@ -const a175_0x43c1=['https://','total','api','params','destroy','error','attrFontSize','intersection','attrUrl','attrHourFormat','json','DashboardItem','pie-chart','update','attrVoiceQueues','widgetAttributes:\x20%s','attrSerie3','attrs','options','attrPath','custom','merge','HH:mm:ss','attrReport','body','status','include','iframe','sendStatus','stringify','show','send','query','then','../../config/logger','../../mysqldb','includeAll','attrSerie1','value','attributes','keys','stack','name','./dashboardItem.socket','attrRefresh','attrSerie2','catch','model','end','type','attrMetric','0.00','clock','findOne','create','attrTimezone'];(function(_0x2f0b37,_0x43c16e){const _0x2f553b=function(_0x454656){while(--_0x454656){_0x2f0b37['push'](_0x2f0b37['shift']());}};_0x2f553b(++_0x43c16e);}(a175_0x43c1,0x84));const a175_0x2f55=function(_0x2f0b37,_0x43c16e){_0x2f0b37=_0x2f0b37-0x0;let _0x2f553b=a175_0x43c1[_0x2f0b37];return _0x2f553b;};const _0x953321=a175_0x2f55;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x953321('0xe'))(_0x953321('0x26')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x953321('0xf'))['db'];require(_0x953321('0x17'))['register'](socket);function respondWithResult(_0x454656,_0x7d3efe){return _0x7d3efe=_0x7d3efe||0xc8,function(_0x167a34){const _0x4584d3=a175_0x2f55;if(_0x167a34)return _0x454656['status'](_0x7d3efe)[_0x4584d3('0x2e')](_0x167a34);};}function saveUpdates(_0x552023){return function(_0x59d866){if(_0x59d866)return _0x59d866['update'](_0x552023)['then'](function(_0x179c59){return _0x179c59;});return null;};}function removeEntity(_0x1a5fc9){return function(_0x34c628){const _0x3df588=a175_0x2f55;if(_0x34c628)return _0x34c628[_0x3df588('0x28')]()[_0x3df588('0xd')](function(){const _0x3ea5dd=_0x3df588;_0x1a5fc9[_0x3ea5dd('0x5')](0xcc)[_0x3ea5dd('0x1c')]();});};}function handleEntityNotFound(_0x21dda8){return function(_0x134e2a){const _0x4d3813=a175_0x2f55;return!_0x134e2a&&_0x21dda8[_0x4d3813('0x8')](0x194),_0x134e2a;};}function handleError(_0x378825,_0x560645){return _0x560645=_0x560645||0x1f4,function(_0xdc964){const _0x5af656=a175_0x2f55;logger[_0x5af656('0x29')](_0xdc964[_0x5af656('0x15')]),_0xdc964['name']&&delete _0xdc964[_0x5af656('0x16')],_0x378825[_0x5af656('0x5')](_0x560645)[_0x5af656('0xb')](_0xdc964);};}exports[_0x953321('0xa')]=function(_0x3e5d65,_0x327293){const _0x5310cf=_0x953321;let _0x4b78d4={'raw':![],'where':{'id':_0x3e5d65[_0x5310cf('0x27')]['id']}};const _0x18dce1={};return _0x18dce1['model']=_[_0x5310cf('0x14')](db[_0x5310cf('0x2f')]['rawAttributes']),_0x18dce1[_0x5310cf('0xc')]=_[_0x5310cf('0x14')](_0x3e5d65[_0x5310cf('0xc')]),_0x18dce1['filters']=_[_0x5310cf('0x2b')](_0x18dce1['model'],_0x18dce1[_0x5310cf('0xc')]),_0x4b78d4[_0x5310cf('0x13')]=_[_0x5310cf('0x2b')](_0x18dce1['model'],qs['fields'](_0x3e5d65[_0x5310cf('0xc')]['fields'])),_0x4b78d4[_0x5310cf('0x13')]=_0x4b78d4[_0x5310cf('0x13')]['length']?_0x4b78d4[_0x5310cf('0x13')]:_0x18dce1[_0x5310cf('0x1b')],_0x3e5d65['query'][_0x5310cf('0x10')]&&(_0x4b78d4[_0x5310cf('0x6')]=[{'all':!![]}]),_0x4b78d4=_[_0x5310cf('0x1')]({},_0x4b78d4,_0x3e5d65[_0x5310cf('0x36')]),db[_0x5310cf('0x2f')]['findOne'](_0x4b78d4)[_0x5310cf('0xd')](handleEntityNotFound(_0x327293,null))[_0x5310cf('0xd')](respondWithResult(_0x327293,null))['catch'](handleError(_0x327293,null));},exports[_0x953321('0x28')]=function(_0xa0f667,_0x1f2820){const _0x36bad2=_0x953321;return db[_0x36bad2('0x2f')][_0x36bad2('0x21')]({'where':{'id':_0xa0f667[_0x36bad2('0x27')]['id']}})[_0x36bad2('0xd')](handleEntityNotFound(_0x1f2820,null))['then'](removeEntity(_0x1f2820,null))[_0x36bad2('0x1a')](handleError(_0x1f2820,null));};function widgetAttributes(_0x10acef){const _0x518f3c=_0x953321;try{switch(_0x10acef[_0x518f3c('0x1d')]){case _0x518f3c('0x7'):return[{'name':_0x518f3c('0x2c'),'value':_0x10acef[_0x518f3c('0x2c')]||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x0]?_0x10acef[_0x518f3c('0x35')][0x0][_0x518f3c('0x12')]:undefined)||_0x518f3c('0x24')}];case _0x518f3c('0x0'):return[{'name':_0x518f3c('0x37'),'value':_0x10acef[_0x518f3c('0x37')]||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x0]?_0x10acef[_0x518f3c('0x35')][0x0][_0x518f3c('0x12')]:undefined)||''}];case _0x518f3c('0x20'):return[{'name':_0x518f3c('0x2d'),'value':_0x10acef[_0x518f3c('0x2d')]||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef['attrs'][0x0]?_0x10acef[_0x518f3c('0x35')][0x0][_0x518f3c('0x12')]:undefined)||_0x518f3c('0x2')},{'name':_0x518f3c('0x23'),'value':_0x10acef['attrTimezone']||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x1]?_0x10acef[_0x518f3c('0x35')][0x1][_0x518f3c('0x12')]:undefined)||_0x518f3c('0x1f')},{'name':_0x518f3c('0x2a'),'value':_0x10acef['attrFontSize']||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x2]?_0x10acef['attrs'][0x2]['value']:undefined)||0xc}];case'counter':return[{'name':_0x518f3c('0x1e'),'value':_0x10acef[_0x518f3c('0x1e')]||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x0]?_0x10acef[_0x518f3c('0x35')][0x0][_0x518f3c('0x12')]:undefined)||'total'},{'name':_0x518f3c('0x32'),'value':_0x10acef[_0x518f3c('0x32')]||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x1]?_0x10acef[_0x518f3c('0x35')][0x1][_0x518f3c('0x12')]:undefined)||[]},{'name':_0x518f3c('0x2a'),'value':_0x10acef[_0x518f3c('0x2a')]||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x2]?_0x10acef[_0x518f3c('0x35')][0x2][_0x518f3c('0x12')]:undefined)||0x14}];case'multibar-chart':case _0x518f3c('0x30'):return[{'name':_0x518f3c('0x11'),'value':_0x10acef[_0x518f3c('0x11')]||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x0]?_0x10acef[_0x518f3c('0x35')][0x0][_0x518f3c('0x12')]:undefined)||_0x518f3c('0x25')},{'name':_0x518f3c('0x19'),'value':_0x10acef['attrSerie2']||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x1]?_0x10acef['attrs'][0x1][_0x518f3c('0x12')]:undefined)||null},{'name':_0x518f3c('0x34'),'value':_0x10acef[_0x518f3c('0x34')]||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x2]?_0x10acef['attrs'][0x2]['value']:undefined)||null},{'name':_0x518f3c('0x32'),'value':_0x10acef[_0x518f3c('0x32')]||(_0x10acef['attrs']&&_0x10acef[_0x518f3c('0x35')][0x3]?_0x10acef['attrs'][0x3][_0x518f3c('0x12')]:undefined)||[]}];case'web-report':return[{'name':_0x518f3c('0x3'),'type':_0x10acef['reportType']||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x0]?_0x10acef[_0x518f3c('0x35')][0x0][_0x518f3c('0x1d')]:undefined)||null,'value':_0x10acef['attrReport']||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x0]?_0x10acef[_0x518f3c('0x35')][0x0][_0x518f3c('0x12')]:undefined)||null},{'name':_0x518f3c('0x18'),'value':_0x10acef[_0x518f3c('0x18')]||(_0x10acef[_0x518f3c('0x35')]&&_0x10acef[_0x518f3c('0x35')][0x1]?_0x10acef[_0x518f3c('0x35')][0x1]['value']:undefined)||0x0}];default:return[];}}catch(_0x421c5c){return logger[_0x518f3c('0x29')](_0x518f3c('0x33'),JSON[_0x518f3c('0x9')](_0x421c5c)),[];}}exports[_0x953321('0x22')]=function(_0x4b370a,_0x7f7ab8){const _0x3ccab1=_0x953321;return _0x4b370a[_0x3ccab1('0x4')]&&(_0x4b370a['body'][_0x3ccab1('0x35')]=widgetAttributes(_0x4b370a['body'])),db[_0x3ccab1('0x2f')][_0x3ccab1('0x22')](_0x4b370a['body'],{})[_0x3ccab1('0xd')](respondWithResult(_0x7f7ab8,0xc9))['catch'](handleError(_0x7f7ab8,null));},exports[_0x953321('0x31')]=function(_0x4c89cd,_0x186894){const _0x5aa586=_0x953321;return _0x4c89cd[_0x5aa586('0x4')]['id']&&delete _0x4c89cd[_0x5aa586('0x4')]['id'],_0x4c89cd[_0x5aa586('0x4')][_0x5aa586('0x35')]=widgetAttributes(_0x4c89cd['body']),db[_0x5aa586('0x2f')][_0x5aa586('0x21')]({'where':{'id':_0x4c89cd['params']['id']}})[_0x5aa586('0xd')](handleEntityNotFound(_0x186894,null))['then'](saveUpdates(_0x4c89cd[_0x5aa586('0x4')],null))[_0x5aa586('0xd')](respondWithResult(_0x186894,null))[_0x5aa586('0x1a')](handleError(_0x186894,null));}; \ No newline at end of file +const a175_0x3246=['merge','total','attrReport','type','include','widgetAttributes:\x20%s','attrHourFormat','params','destroy','0.00','DashboardItem','attrRefresh','https://','then','attrMetric','iframe','query','intersection','keys','attrTimezone','./dashboardItem.socket','attrSerie1','web-report','../../components/parsers/qs','name','clock','stringify','error','update','../../rediscache','multibar-chart','body','attributes','catch','create','attrPath','lodash','sendStatus','includeAll','custom','attrFontSize','findOne','attrSerie2','show','options','../../mysqldb','attrVoiceQueues','HH:mm:ss','status','attrs','register','reportType','value','attrSerie3','api','send','model','attrUrl'];(function(_0x308787,_0x32468b){const _0x155a62=function(_0x27ad4f){while(--_0x27ad4f){_0x308787['push'](_0x308787['shift']());}};_0x155a62(++_0x32468b);}(a175_0x3246,0x7d));const a175_0x155a=function(_0x308787,_0x32468b){_0x308787=_0x308787-0x0;let _0x155a62=a175_0x3246[_0x308787];return _0x155a62;};const _0x2cb1d9=a175_0x155a;'use strict';const _=require(_0x2cb1d9('0x1b')),qs=require(_0x2cb1d9('0xe')),logger=require('../../config/logger')(_0x2cb1d9('0x2d')),{getSocket}=require(_0x2cb1d9('0x14')),socket=getSocket(),db=require(_0x2cb1d9('0x24'))['db'];require(_0x2cb1d9('0xb'))[_0x2cb1d9('0x29')](socket);function respondWithResult(_0x27ad4f,_0x2840de){return _0x2840de=_0x2840de||0xc8,function(_0x198f94){const _0x596135=a175_0x155a;if(_0x198f94)return _0x27ad4f[_0x596135('0x27')](_0x2840de)['json'](_0x198f94);};}function saveUpdates(_0x23f93a){return function(_0x23ce21){const _0xf1aaf6=a175_0x155a;if(_0x23ce21)return _0x23ce21[_0xf1aaf6('0x13')](_0x23f93a)[_0xf1aaf6('0x4')](function(_0x753c70){return _0x753c70;});return null;};}function removeEntity(_0x4e4e12){return function(_0x581f45){const _0x4368d6=a175_0x155a;if(_0x581f45)return _0x581f45[_0x4368d6('0x39')]()['then'](function(){const _0xb18173=_0x4368d6;_0x4e4e12[_0xb18173('0x27')](0xcc)['end']();});};}function handleEntityNotFound(_0x1c83a5){return function(_0x4da4d8){const _0x2e9418=a175_0x155a;return!_0x4da4d8&&_0x1c83a5[_0x2e9418('0x1c')](0x194),_0x4da4d8;};}function handleError(_0x17f3f2,_0x2d9f4d){return _0x2d9f4d=_0x2d9f4d||0x1f4,function(_0x389a49){const _0x2d54dc=a175_0x155a;logger[_0x2d54dc('0x12')](_0x389a49['stack']),_0x389a49[_0x2d54dc('0xf')]&&delete _0x389a49[_0x2d54dc('0xf')],_0x17f3f2['status'](_0x2d9f4d)[_0x2d54dc('0x2e')](_0x389a49);};}exports[_0x2cb1d9('0x22')]=function(_0x18ddae,_0xdae914){const _0x43b6d8=_0x2cb1d9;let _0x52a012={'raw':![],'where':{'id':_0x18ddae[_0x43b6d8('0x38')]['id']}};const _0x1c5588={};return _0x1c5588['model']=_[_0x43b6d8('0x9')](db[_0x43b6d8('0x1')]['rawAttributes']),_0x1c5588[_0x43b6d8('0x7')]=_[_0x43b6d8('0x9')](_0x18ddae[_0x43b6d8('0x7')]),_0x1c5588['filters']=_[_0x43b6d8('0x8')](_0x1c5588[_0x43b6d8('0x2f')],_0x1c5588[_0x43b6d8('0x7')]),_0x52a012[_0x43b6d8('0x17')]=_['intersection'](_0x1c5588[_0x43b6d8('0x2f')],qs['fields'](_0x18ddae[_0x43b6d8('0x7')]['fields'])),_0x52a012[_0x43b6d8('0x17')]=_0x52a012['attributes']['length']?_0x52a012[_0x43b6d8('0x17')]:_0x1c5588['model'],_0x18ddae[_0x43b6d8('0x7')][_0x43b6d8('0x1d')]&&(_0x52a012[_0x43b6d8('0x35')]=[{'all':!![]}]),_0x52a012=_[_0x43b6d8('0x31')]({},_0x52a012,_0x18ddae[_0x43b6d8('0x23')]),db[_0x43b6d8('0x1')][_0x43b6d8('0x20')](_0x52a012)[_0x43b6d8('0x4')](handleEntityNotFound(_0xdae914,null))['then'](respondWithResult(_0xdae914,null))[_0x43b6d8('0x18')](handleError(_0xdae914,null));},exports[_0x2cb1d9('0x39')]=function(_0x1d6320,_0x461f63){const _0x5d380c=_0x2cb1d9;return db[_0x5d380c('0x1')][_0x5d380c('0x20')]({'where':{'id':_0x1d6320['params']['id']}})[_0x5d380c('0x4')](handleEntityNotFound(_0x461f63,null))[_0x5d380c('0x4')](removeEntity(_0x461f63,null))[_0x5d380c('0x18')](handleError(_0x461f63,null));};function widgetAttributes(_0x25ffba){const _0x569693=_0x2cb1d9;try{switch(_0x25ffba[_0x569693('0x34')]){case _0x569693('0x6'):return[{'name':_0x569693('0x30'),'value':_0x25ffba['attrUrl']||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x0]?_0x25ffba['attrs'][0x0]['value']:undefined)||_0x569693('0x3')}];case _0x569693('0x1e'):return[{'name':_0x569693('0x1a'),'value':_0x25ffba[_0x569693('0x1a')]||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x0]?_0x25ffba['attrs'][0x0][_0x569693('0x2b')]:undefined)||''}];case _0x569693('0x10'):return[{'name':_0x569693('0x37'),'value':_0x25ffba[_0x569693('0x37')]||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x0]?_0x25ffba[_0x569693('0x28')][0x0][_0x569693('0x2b')]:undefined)||_0x569693('0x26')},{'name':_0x569693('0xa'),'value':_0x25ffba[_0x569693('0xa')]||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x1]?_0x25ffba['attrs'][0x1][_0x569693('0x2b')]:undefined)||_0x569693('0x0')},{'name':_0x569693('0x1f'),'value':_0x25ffba['attrFontSize']||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x2]?_0x25ffba[_0x569693('0x28')][0x2]['value']:undefined)||0xc}];case'counter':return[{'name':'attrMetric','value':_0x25ffba[_0x569693('0x5')]||(_0x25ffba['attrs']&&_0x25ffba[_0x569693('0x28')][0x0]?_0x25ffba['attrs'][0x0][_0x569693('0x2b')]:undefined)||_0x569693('0x32')},{'name':_0x569693('0x25'),'value':_0x25ffba[_0x569693('0x25')]||(_0x25ffba['attrs']&&_0x25ffba[_0x569693('0x28')][0x1]?_0x25ffba[_0x569693('0x28')][0x1][_0x569693('0x2b')]:undefined)||[]},{'name':_0x569693('0x1f'),'value':_0x25ffba[_0x569693('0x1f')]||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x2]?_0x25ffba[_0x569693('0x28')][0x2][_0x569693('0x2b')]:undefined)||0x14}];case _0x569693('0x15'):case'pie-chart':return[{'name':'attrSerie1','value':_0x25ffba[_0x569693('0xc')]||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x0]?_0x25ffba[_0x569693('0x28')][0x0][_0x569693('0x2b')]:undefined)||_0x569693('0x32')},{'name':_0x569693('0x21'),'value':_0x25ffba[_0x569693('0x21')]||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x1]?_0x25ffba[_0x569693('0x28')][0x1]['value']:undefined)||null},{'name':_0x569693('0x2c'),'value':_0x25ffba[_0x569693('0x2c')]||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x2]?_0x25ffba['attrs'][0x2][_0x569693('0x2b')]:undefined)||null},{'name':'attrVoiceQueues','value':_0x25ffba[_0x569693('0x25')]||(_0x25ffba['attrs']&&_0x25ffba[_0x569693('0x28')][0x3]?_0x25ffba[_0x569693('0x28')][0x3][_0x569693('0x2b')]:undefined)||[]}];case _0x569693('0xd'):return[{'name':_0x569693('0x33'),'type':_0x25ffba[_0x569693('0x2a')]||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x0]?_0x25ffba[_0x569693('0x28')][0x0][_0x569693('0x34')]:undefined)||null,'value':_0x25ffba[_0x569693('0x33')]||(_0x25ffba[_0x569693('0x28')]&&_0x25ffba[_0x569693('0x28')][0x0]?_0x25ffba['attrs'][0x0]['value']:undefined)||null},{'name':_0x569693('0x2'),'value':_0x25ffba[_0x569693('0x2')]||(_0x25ffba['attrs']&&_0x25ffba['attrs'][0x1]?_0x25ffba['attrs'][0x1][_0x569693('0x2b')]:undefined)||0x0}];default:return[];}}catch(_0x3251fd){return logger[_0x569693('0x12')](_0x569693('0x36'),JSON[_0x569693('0x11')](_0x3251fd)),[];}}exports[_0x2cb1d9('0x19')]=function(_0x4f8ab8,_0x2a5d38){const _0x4f0444=_0x2cb1d9;return _0x4f8ab8['body']&&(_0x4f8ab8[_0x4f0444('0x16')]['attrs']=widgetAttributes(_0x4f8ab8['body'])),db['DashboardItem'][_0x4f0444('0x19')](_0x4f8ab8[_0x4f0444('0x16')],{})['then'](respondWithResult(_0x2a5d38,0xc9))[_0x4f0444('0x18')](handleError(_0x2a5d38,null));},exports[_0x2cb1d9('0x13')]=function(_0x17d47e,_0x373e31){const _0x471979=_0x2cb1d9;return _0x17d47e[_0x471979('0x16')]['id']&&delete _0x17d47e[_0x471979('0x16')]['id'],_0x17d47e[_0x471979('0x16')][_0x471979('0x28')]=widgetAttributes(_0x17d47e[_0x471979('0x16')]),db[_0x471979('0x1')][_0x471979('0x20')]({'where':{'id':_0x17d47e['params']['id']}})[_0x471979('0x4')](handleEntityNotFound(_0x373e31,null))[_0x471979('0x4')](saveUpdates(_0x17d47e[_0x471979('0x16')],null))['then'](respondWithResult(_0x373e31,null))['catch'](handleError(_0x373e31,null));}; \ No newline at end of file diff --git a/server/api/dashboardItem/dashboardItem.events.js b/server/api/dashboardItem/dashboardItem.events.js index 2ccc027..87b5ae4 100644 --- a/server/api/dashboardItem/dashboardItem.events.js +++ b/server/api/dashboardItem/dashboardItem.events.js @@ -1 +1 @@ -const a176_0x5c0f=['save','addHook','setMaxListeners','DashboardItem','update','emit','remove'];(function(_0x1e03c7,_0x5c0f6d){const _0x372871=function(_0x1fdc8d){while(--_0x1fdc8d){_0x1e03c7['push'](_0x1e03c7['shift']());}};_0x372871(++_0x5c0f6d);}(a176_0x5c0f,0x11d));const a176_0x3728=function(_0x1e03c7,_0x5c0f6d){_0x1e03c7=_0x1e03c7-0x0;let _0x372871=a176_0x5c0f[_0x1e03c7];return _0x372871;};const _0x1e3ba2=a176_0x3728;'use strict';const EventEmitter=require('events'),DashboardItem=require('../../mysqldb')['db'][_0x1e3ba2('0x5')],DashboardItemEvents=new EventEmitter();DashboardItemEvents[_0x1e3ba2('0x4')](0x0);const events={'afterCreate':_0x1e3ba2('0x2'),'afterUpdate':_0x1e3ba2('0x6'),'afterDestroy':_0x1e3ba2('0x1')};function emitEvent(_0x1fdc8d){return function(_0x3f5a47){const _0x2cbe8e=a176_0x3728;DashboardItemEvents[_0x2cbe8e('0x0')](_0x1fdc8d+':'+_0x3f5a47['id'],_0x3f5a47),DashboardItemEvents['emit'](_0x1fdc8d,_0x3f5a47);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];DashboardItem[_0x1e3ba2('0x3')](e,emitEvent(event));}}module['exports']=DashboardItemEvents; \ No newline at end of file +const a176_0x24bc=['../../mysqldb','remove','update','emit','save','addHook'];(function(_0x25a274,_0x24bcf1){const _0x5c5e50=function(_0x1cb50b){while(--_0x1cb50b){_0x25a274['push'](_0x25a274['shift']());}};_0x5c5e50(++_0x24bcf1);}(a176_0x24bc,0x15c));const a176_0x5c5e=function(_0x25a274,_0x24bcf1){_0x25a274=_0x25a274-0x0;let _0x5c5e50=a176_0x24bc[_0x25a274];return _0x5c5e50;};const _0xb5dc76=a176_0x5c5e;'use strict';const EventEmitter=require('events'),DashboardItem=require(_0xb5dc76('0x0'))['db']['DashboardItem'],DashboardItemEvents=new EventEmitter();DashboardItemEvents['setMaxListeners'](0x0);const events={'afterCreate':_0xb5dc76('0x4'),'afterUpdate':_0xb5dc76('0x2'),'afterDestroy':_0xb5dc76('0x1')};function emitEvent(_0x1cb50b){return function(_0x128b7d){const _0x2a23ac=a176_0x5c5e;DashboardItemEvents[_0x2a23ac('0x3')](_0x1cb50b+':'+_0x128b7d['id'],_0x128b7d),DashboardItemEvents[_0x2a23ac('0x3')](_0x1cb50b,_0x128b7d);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];DashboardItem[_0xb5dc76('0x5')](e,emitEvent(event));}}module['exports']=DashboardItemEvents; \ No newline at end of file diff --git a/server/api/dashboardItem/dashboardItem.model.js b/server/api/dashboardItem/dashboardItem.model.js index 81e6175..b51d725 100644 --- a/server/api/dashboardItem/dashboardItem.model.js +++ b/server/api/dashboardItem/dashboardItem.model.js @@ -1 +1 @@ -const a177_0x4e95=['define','./dashboardItem.attributes','DashboardItem'];(function(_0x4b6ca3,_0x4e954c){const _0x58dc75=function(_0xf368dc){while(--_0xf368dc){_0x4b6ca3['push'](_0x4b6ca3['shift']());}};_0x58dc75(++_0x4e954c);}(a177_0x4e95,0xbf));const a177_0x58dc=function(_0x4b6ca3,_0x4e954c){_0x4b6ca3=_0x4b6ca3-0x0;let _0x58dc75=a177_0x4e95[_0x4b6ca3];return _0x58dc75;};const _0x884167=a177_0x58dc;'use strict';const attributes=require(_0x884167('0x2'));module['exports']=function(_0xf368dc){const _0x3ac633=_0x884167,_0x2e2dad=_0xf368dc[_0x3ac633('0x1')](_0x3ac633('0x0'),attributes,{'tableName':'dashboard_items','paranoid':![],'indexes':[],'timestamps':!![]});return _0x2e2dad;}; \ No newline at end of file +const a177_0x4765=['exports','./dashboardItem.attributes','DashboardItem','define','dashboard_items'];(function(_0x14c6f0,_0x4765a0){const _0x1e6ee1=function(_0x3f905c){while(--_0x3f905c){_0x14c6f0['push'](_0x14c6f0['shift']());}};_0x1e6ee1(++_0x4765a0);}(a177_0x4765,0x18f));const a177_0x1e6e=function(_0x14c6f0,_0x4765a0){_0x14c6f0=_0x14c6f0-0x0;let _0x1e6ee1=a177_0x4765[_0x14c6f0];return _0x1e6ee1;};const _0xb1f394=a177_0x1e6e;'use strict';const attributes=require(_0xb1f394('0x2'));module[_0xb1f394('0x1')]=function(_0x3f905c){const _0x1bd253=_0xb1f394,_0x3ae7e9=_0x3f905c[_0x1bd253('0x4')](_0x1bd253('0x3'),attributes,{'tableName':_0x1bd253('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3ae7e9;}; \ No newline at end of file diff --git a/server/api/dashboardItem/dashboardItem.rpc.js b/server/api/dashboardItem/dashboardItem.rpc.js index b68492c..3ddca64 100644 --- a/server/api/dashboardItem/dashboardItem.rpc.js +++ b/server/api/dashboardItem/dashboardItem.rpc.js @@ -1 +1 @@ -const a178_0x70af=['../../rediscache','./dashboardItem.socket','register'];(function(_0x373cf2,_0x70af49){const _0x40cef6=function(_0x26e0a0){while(--_0x26e0a0){_0x373cf2['push'](_0x373cf2['shift']());}};_0x40cef6(++_0x70af49);}(a178_0x70af,0x6c));const a178_0x40ce=function(_0x373cf2,_0x70af49){_0x373cf2=_0x373cf2-0x0;let _0x40cef6=a178_0x70af[_0x373cf2];return _0x40cef6;};const _0x42e244=a178_0x40ce;'use strict';const {getSocket}=require(_0x42e244('0x0')),socket=getSocket();require(_0x42e244('0x1'))[_0x42e244('0x2')](socket); \ No newline at end of file +const a178_0x1f39=['./dashboardItem.socket'];(function(_0x5c0df3,_0x1f39d2){const _0x54d45c=function(_0x57589e){while(--_0x57589e){_0x5c0df3['push'](_0x5c0df3['shift']());}};_0x54d45c(++_0x1f39d2);}(a178_0x1f39,0x1d6));const a178_0x54d4=function(_0x5c0df3,_0x1f39d2){_0x5c0df3=_0x5c0df3-0x0;let _0x54d45c=a178_0x1f39[_0x5c0df3];return _0x54d45c;};const _0xb1ae27=a178_0x54d4;'use strict';const {getSocket}=require('../../rediscache'),socket=getSocket();require(_0xb1ae27('0x0'))['register'](socket); \ No newline at end of file diff --git a/server/api/dashboardItem/dashboardItem.socket.js b/server/api/dashboardItem/dashboardItem.socket.js index 0d1f754..41fac20 100644 --- a/server/api/dashboardItem/dashboardItem.socket.js +++ b/server/api/dashboardItem/dashboardItem.socket.js @@ -1 +1 @@ -const a179_0x2526=['save','register','emit','update','remove','length','dashboardItem:'];(function(_0x179d7c,_0x252644){const _0x3e64b3=function(_0x5a5ccb){while(--_0x5a5ccb){_0x179d7c['push'](_0x179d7c['shift']());}};_0x3e64b3(++_0x252644);}(a179_0x2526,0xe1));const a179_0x3e64=function(_0x179d7c,_0x252644){_0x179d7c=_0x179d7c-0x0;let _0x3e64b3=a179_0x2526[_0x179d7c];return _0x3e64b3;};const _0x3814bd=a179_0x3e64;'use strict';const DashboardItemEvents=require('./dashboardItem.events'),events=[_0x3814bd('0x6'),_0x3814bd('0x3'),_0x3814bd('0x2')];function createListener(_0x5a5ccb,_0x1f9d6f){return function(_0x10da66){const _0xdc1f6d=a179_0x3e64;_0x1f9d6f[_0xdc1f6d('0x1')](_0x5a5ccb,_0x10da66);};}exports[_0x3814bd('0x0')]=function(_0x3910d3){const _0x2d07a8=_0x3814bd;for(let _0x367268=0x0,_0x46de28=events[_0x2d07a8('0x4')];_0x367268<_0x46de28;_0x367268++){const _0x6d3d7f=events[_0x367268],_0x3f72dd=createListener(_0x2d07a8('0x5')+_0x6d3d7f,_0x3910d3);DashboardItemEvents['on'](_0x6d3d7f,_0x3f72dd);}}; \ No newline at end of file +const a179_0x59a9=['update','length','dashboardItem:','emit','./dashboardItem.events','register'];(function(_0x45c8ad,_0x59a908){const _0x3b85b2=function(_0x1aa3df){while(--_0x1aa3df){_0x45c8ad['push'](_0x45c8ad['shift']());}};_0x3b85b2(++_0x59a908);}(a179_0x59a9,0x99));const a179_0x3b85=function(_0x45c8ad,_0x59a908){_0x45c8ad=_0x45c8ad-0x0;let _0x3b85b2=a179_0x59a9[_0x45c8ad];return _0x3b85b2;};const _0x546767=a179_0x3b85;'use strict';const DashboardItemEvents=require(_0x546767('0x1')),events=['save','remove',_0x546767('0x3')];function createListener(_0x1aa3df,_0x25d429){return function(_0x3f96ab){const _0x27bd6e=a179_0x3b85;_0x25d429[_0x27bd6e('0x0')](_0x1aa3df,_0x3f96ab);};}exports[_0x546767('0x2')]=function(_0x1101c0){const _0x99f1b3=_0x546767;for(let _0x295dc5=0x0,_0x3368e2=events[_0x99f1b3('0x4')];_0x295dc5<_0x3368e2;_0x295dc5++){const _0x38b84c=events[_0x295dc5],_0x3f4273=createListener(_0x99f1b3('0x5')+_0x38b84c,_0x1101c0);DashboardItemEvents['on'](_0x38b84c,_0x3f4273);}}; \ No newline at end of file diff --git a/server/api/dashboardItem/index.js b/server/api/dashboardItem/index.js index d3eac88..2ea45b4 100644 --- a/server/api/dashboardItem/index.js +++ b/server/api/dashboardItem/index.js @@ -1 +1 @@ -const a180_0x2858=['isAuthenticated','get','create','../../components/auth/service','post','Router','exports','/:id','put','update','show'];(function(_0x2a62a8,_0x2858ee){const _0xa03eea=function(_0x534afd){while(--_0x534afd){_0x2a62a8['push'](_0x2a62a8['shift']());}};_0xa03eea(++_0x2858ee);}(a180_0x2858,0x14a));const a180_0xa03e=function(_0x2a62a8,_0x2858ee){_0x2a62a8=_0x2a62a8-0x0;let _0xa03eea=a180_0x2858[_0x2a62a8];return _0xa03eea;};const _0x2cb061=a180_0xa03e;'use strict';const express=require('express'),router=express[_0x2cb061('0x5')](),auth=require(_0x2cb061('0x3')),controller=require('./dashboardItem.controller');router[_0x2cb061('0x1')](_0x2cb061('0x7'),auth[_0x2cb061('0x0')](),controller[_0x2cb061('0xa')]),router[_0x2cb061('0x4')]('/',auth[_0x2cb061('0x0')](),controller[_0x2cb061('0x2')]),router[_0x2cb061('0x8')](_0x2cb061('0x7'),auth[_0x2cb061('0x0')](),controller[_0x2cb061('0x9')]),router['delete']('/:id',auth[_0x2cb061('0x0')](),controller['destroy']),module[_0x2cb061('0x6')]=router; \ No newline at end of file +const a180_0x1a20=['post','isAuthenticated','/:id','Router','show','./dashboardItem.controller','destroy','../../components/auth/service'];(function(_0x3cb4d3,_0x1a203c){const _0x560795=function(_0x5d68f3){while(--_0x5d68f3){_0x3cb4d3['push'](_0x3cb4d3['shift']());}};_0x560795(++_0x1a203c);}(a180_0x1a20,0x1bd));const a180_0x5607=function(_0x3cb4d3,_0x1a203c){_0x3cb4d3=_0x3cb4d3-0x0;let _0x560795=a180_0x1a20[_0x3cb4d3];return _0x560795;};const _0x22b86f=a180_0x5607;'use strict';const express=require('express'),router=express[_0x22b86f('0x6')](),auth=require(_0x22b86f('0x2')),controller=require(_0x22b86f('0x0'));router['get'](_0x22b86f('0x5'),auth[_0x22b86f('0x4')](),controller[_0x22b86f('0x7')]),router[_0x22b86f('0x3')]('/',auth['isAuthenticated'](),controller['create']),router['put']('/:id',auth[_0x22b86f('0x4')](),controller['update']),router['delete'](_0x22b86f('0x5'),auth[_0x22b86f('0x4')](),controller[_0x22b86f('0x1')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/disposition/disposition.attributes.js b/server/api/disposition/disposition.attributes.js index 786d800..124570c 100644 --- a/server/api/disposition/disposition.attributes.js +++ b/server/api/disposition/disposition.attributes.js @@ -1 +1 @@ -const a181_0x12a1=['STRING','third','sequelize','exports','second','ENUM','first'];(function(_0x2a6f67,_0x12a14f){const _0x388b9b=function(_0xa062c9){while(--_0xa062c9){_0x2a6f67['push'](_0x2a6f67['shift']());}};_0x388b9b(++_0x12a14f);}(a181_0x12a1,0x65));const a181_0x388b=function(_0x2a6f67,_0x12a14f){_0x2a6f67=_0x2a6f67-0x0;let _0x388b9b=a181_0x12a1[_0x2a6f67];return _0x388b9b;};const _0x598c4b=a181_0x388b;'use strict';const Sequelize=require(_0x598c4b('0x6'));module[_0x598c4b('0x0')]={'name':{'type':Sequelize[_0x598c4b('0x4')],'allowNull':![]},'level':{'type':Sequelize[_0x598c4b('0x2')](_0x598c4b('0x3'),_0x598c4b('0x1'),_0x598c4b('0x5')),'allowNull':![],'defaultValue':_0x598c4b('0x3')},'description':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a181_0x2d61=['sequelize','third','STRING','exports','ENUM','first','second'];(function(_0x2368f4,_0x2d61a2){const _0x34721c=function(_0x418606){while(--_0x418606){_0x2368f4['push'](_0x2368f4['shift']());}};_0x34721c(++_0x2d61a2);}(a181_0x2d61,0xbc));const a181_0x3472=function(_0x2368f4,_0x2d61a2){_0x2368f4=_0x2368f4-0x0;let _0x34721c=a181_0x2d61[_0x2368f4];return _0x34721c;};const _0x5811a5=a181_0x3472;'use strict';const Sequelize=require(_0x5811a5('0x1'));module[_0x5811a5('0x4')]={'name':{'type':Sequelize[_0x5811a5('0x3')],'allowNull':![]},'level':{'type':Sequelize[_0x5811a5('0x5')](_0x5811a5('0x6'),_0x5811a5('0x0'),_0x5811a5('0x2')),'allowNull':![],'defaultValue':_0x5811a5('0x6')},'description':{'type':Sequelize[_0x5811a5('0x3')]}}; \ No newline at end of file diff --git a/server/api/disposition/disposition.controller.js b/server/api/disposition/disposition.controller.js index 5a1b03c..f54612f 100644 --- a/server/api/disposition/disposition.controller.js +++ b/server/api/disposition/disposition.controller.js @@ -1 +1 @@ -const a182_0x6bc2=['Unable\x20to\x20retrieve\x20the\x20current\x20user','findOne','order','json','nolimit','where','catch','pick','sort','error','attributes','Content-Range','query','length','VIRTUAL','Disposition','send','rawAttributes','../../mysqldb','UserProfileResource','status','set','options','get','filters','Dispositions','name','body','stack','then','../../components/parsers/qs','end','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','update','../../config/logger','create','api','user','UserProfileSection','model','destroy','sequelize','map','show','merge','like','limit','count','lodash','index','fields','intersection','key','findAll','type','include','offset','params','filter','includeAll','rows','fieldName','sendStatus','undefined'];(function(_0x561d9e,_0x6bc2da){const _0x227614=function(_0x15b91c){while(--_0x15b91c){_0x561d9e['push'](_0x561d9e['shift']());}};_0x227614(++_0x6bc2da);}(a182_0x6bc2,0x161));const a182_0x2276=function(_0x561d9e,_0x6bc2da){_0x561d9e=_0x561d9e-0x0;let _0x227614=a182_0x6bc2[_0x561d9e];return _0x227614;};const _0x409aca=a182_0x2276;'use strict';const _=require(_0x409aca('0xf')),qs=require(_0x409aca('0x3d')),logger=require(_0x409aca('0x1'))(_0x409aca('0x3')),db=require(_0x409aca('0x31'))['db'],{Op}=require(_0x409aca('0x8'));function respondWithResult(_0x15b91c,_0x3100c7){return _0x3100c7=_0x3100c7||0xc8,function(_0x39f68e){const _0x4b159b=a182_0x2276;if(_0x39f68e)return _0x15b91c[_0x4b159b('0x33')](_0x3100c7)[_0x4b159b('0x22')](_0x39f68e);};}function respondWithFilteredResult(_0x5ca129,_0x13f2a1){return function(_0x3f9930){const _0x2f5a23=a182_0x2276;if(_0x3f9930){const _0x2a32c7=_0x3f9930['count'],_0x25ca96=_0x13f2a1[_0x2f5a23('0x17')];let _0x5addf4=_0x13f2a1[_0x2f5a23('0x17')]+_0x13f2a1[_0x2f5a23('0xd')],_0x4b56bf;return _0x5addf4>=_0x2a32c7?(_0x5addf4=_0x2a32c7,_0x4b56bf=0xc8):_0x4b56bf=0xce,_0x5ca129[_0x2f5a23('0x33')](_0x4b56bf),_0x5ca129[_0x2f5a23('0x34')](_0x2f5a23('0x2a'),_0x25ca96+'-'+_0x5addf4+'/'+_0x2a32c7)[_0x2f5a23('0x22')](_0x3f9930);}return null;};}function saveUpdates(_0x5126fa){return function(_0x4a5f3a){const _0x36052b=a182_0x2276;if(_0x4a5f3a)return _0x4a5f3a[_0x36052b('0x0')](_0x5126fa)[_0x36052b('0x3c')](function(_0x5a46ba){return _0x5a46ba;});return null;};}function removeEntity(_0x32880a){return function(_0x416e19){const _0x373616=a182_0x2276;if(_0x416e19)return _0x416e19[_0x373616('0x7')]()[_0x373616('0x3c')](function(){const _0x273cf=_0x373616,_0x55210e=_0x416e19['get']({'plain':!![]}),_0x25b0b6=_0x273cf('0x38');return db[_0x273cf('0x32')][_0x273cf('0x7')]({'where':{'type':_0x25b0b6,'resourceId':_0x55210e['id']}})[_0x273cf('0x3c')](function(){return _0x416e19;});})[_0x373616('0x3c')](function(){const _0x4566b8=_0x373616;_0x32880a['status'](0xcc)[_0x4566b8('0x3e')]();});};}function handleEntityNotFound(_0x462dec){return function(_0x5b8a1b){const _0x3d5c49=a182_0x2276;return!_0x5b8a1b&&_0x462dec[_0x3d5c49('0x1d')](0x194),_0x5b8a1b;};}function handleError(_0x504706,_0x15374f){return _0x15374f=_0x15374f||0x1f4,function(_0x4100fd){const _0x172b77=a182_0x2276;logger[_0x172b77('0x28')](_0x4100fd[_0x172b77('0x3b')]),_0x4100fd[_0x172b77('0x39')]&&delete _0x4100fd[_0x172b77('0x39')],_0x504706['status'](_0x15374f)[_0x172b77('0x2f')](_0x4100fd);};}exports[_0x409aca('0x10')]=function(_0x32a706,_0x17b968){const _0x209bec=_0x409aca;let _0x4b18ee={};const _0x2e1bb2={},_0xd33f28={'count':0x0,'rows':[]},_0x22c73=_[_0x209bec('0x9')](db[_0x209bec('0x2e')][_0x209bec('0x30')],function(_0x13bc1c){const _0x4c68e7=_0x209bec;return{'name':_0x13bc1c[_0x4c68e7('0x1c')],'type':_0x13bc1c[_0x4c68e7('0x15')][_0x4c68e7('0x13')]};});_0x2e1bb2['model']=_[_0x209bec('0x9')](_0x22c73,'name'),_0x2e1bb2[_0x209bec('0x2b')]=_['keys'](_0x32a706[_0x209bec('0x2b')]),_0x2e1bb2[_0x209bec('0x37')]=_[_0x209bec('0x12')](_0x2e1bb2[_0x209bec('0x6')],_0x2e1bb2[_0x209bec('0x2b')]),_0x4b18ee[_0x209bec('0x29')]=_['intersection'](_0x2e1bb2['model'],qs[_0x209bec('0x11')](_0x32a706[_0x209bec('0x2b')]['fields'])),_0x4b18ee[_0x209bec('0x29')]=_0x4b18ee[_0x209bec('0x29')][_0x209bec('0x2c')]?_0x4b18ee[_0x209bec('0x29')]:_0x2e1bb2[_0x209bec('0x6')];typeof _0x32a706[_0x209bec('0x2b')][_0x209bec('0x23')]===_0x209bec('0x1e')&&(_0x4b18ee[_0x209bec('0xd')]=qs[_0x209bec('0xd')](_0x32a706[_0x209bec('0x2b')][_0x209bec('0xd')]),_0x4b18ee[_0x209bec('0x17')]=qs[_0x209bec('0x17')](_0x32a706['query'][_0x209bec('0x17')]));_0x4b18ee[_0x209bec('0x21')]=qs['sort'](_0x32a706['query'][_0x209bec('0x27')]),_0x4b18ee[_0x209bec('0x24')]=qs[_0x209bec('0x37')](_[_0x209bec('0x26')](_0x32a706[_0x209bec('0x2b')],_0x2e1bb2['filters']),_0x22c73);_0x32a706[_0x209bec('0x2b')]['filter']&&(_0x4b18ee[_0x209bec('0x24')]=_['merge'](_0x4b18ee['where'],{[Op['or']]:_['map'](_0x22c73,function(_0x28dd4a){const _0x8dcbe2=_0x209bec;if(_0x28dd4a['type']!==_0x8dcbe2('0x2d')){const _0x271417={};return _0x271417[_0x28dd4a[_0x8dcbe2('0x39')]]={[Op[_0x8dcbe2('0xc')]]:'%'+_0x32a706[_0x8dcbe2('0x2b')][_0x8dcbe2('0x19')]+'%'},_0x271417;}})}));_0x4b18ee=_[_0x209bec('0xb')]({},_0x4b18ee,_0x32a706[_0x209bec('0x35')]);const _0x507fdb={'where':_0x4b18ee[_0x209bec('0x24')]};return db[_0x209bec('0x2e')][_0x209bec('0xe')](_0x507fdb)[_0x209bec('0x3c')](function(_0x5085ca){const _0x19e6b6=_0x209bec;return _0xd33f28['count']=_0x5085ca,_0x32a706[_0x19e6b6('0x2b')][_0x19e6b6('0x1a')]&&(_0x4b18ee[_0x19e6b6('0x16')]=[{'all':!![]}]),db[_0x19e6b6('0x2e')][_0x19e6b6('0x14')](_0x4b18ee);})[_0x209bec('0x3c')](function(_0x446017){const _0xe3a533=_0x209bec;return _0xd33f28[_0xe3a533('0x1b')]=_0x446017,_0xd33f28;})[_0x209bec('0x3c')](respondWithFilteredResult(_0x17b968,_0x4b18ee))[_0x209bec('0x25')](handleError(_0x17b968,null));},exports[_0x409aca('0xa')]=function(_0x5d3db8,_0x112b83){const _0x39ac0d=_0x409aca;let _0x1aa9e7={'raw':!![],'where':{'id':_0x5d3db8[_0x39ac0d('0x18')]['id']}};const _0x521db7={};return _0x521db7[_0x39ac0d('0x6')]=_['keys'](db[_0x39ac0d('0x2e')][_0x39ac0d('0x30')]),_0x521db7['query']=_['keys'](_0x5d3db8['query']),_0x521db7[_0x39ac0d('0x37')]=_[_0x39ac0d('0x12')](_0x521db7['model'],_0x521db7[_0x39ac0d('0x2b')]),_0x1aa9e7['attributes']=_[_0x39ac0d('0x12')](_0x521db7[_0x39ac0d('0x6')],qs['fields'](_0x5d3db8[_0x39ac0d('0x2b')]['fields'])),_0x1aa9e7[_0x39ac0d('0x29')]=_0x1aa9e7[_0x39ac0d('0x29')][_0x39ac0d('0x2c')]?_0x1aa9e7[_0x39ac0d('0x29')]:_0x521db7['model'],_0x5d3db8[_0x39ac0d('0x2b')][_0x39ac0d('0x1a')]&&(_0x1aa9e7[_0x39ac0d('0x16')]=[{'all':!![]}]),_0x1aa9e7=_[_0x39ac0d('0xb')]({},_0x1aa9e7,_0x5d3db8['options']),db[_0x39ac0d('0x2e')][_0x39ac0d('0x20')](_0x1aa9e7)[_0x39ac0d('0x3c')](handleEntityNotFound(_0x112b83,null))['then'](respondWithResult(_0x112b83,null))[_0x39ac0d('0x25')](handleError(_0x112b83,null));},exports[_0x409aca('0x2')]=function(_0x2727d8,_0x2a014a){const _0x5168e5=_0x409aca;return db['Disposition'][_0x5168e5('0x2')](_0x2727d8[_0x5168e5('0x3a')],{})[_0x5168e5('0x3c')](function(_0x57d96d){const _0x21bd92=_0x5168e5,_0x4c751b=_0x2727d8[_0x21bd92('0x4')]['get']({'plain':!![]});if(!_0x4c751b)throw new Error(_0x21bd92('0x1f'));if(_0x4c751b['role']===_0x21bd92('0x4')){const _0x1bd154=_0x57d96d[_0x21bd92('0x36')]({'plain':!![]}),_0x1fd90d=_0x21bd92('0x38');return db[_0x21bd92('0x5')]['findOne']({'where':{'name':_0x1fd90d,'userProfileId':_0x4c751b['userProfileId']},'raw':!![]})['then'](function(_0x55a512){const _0x664328=_0x21bd92;return _0x55a512&&_0x55a512['autoAssociation']===0x0?db[_0x664328('0x32')][_0x664328('0x2')]({'name':_0x1bd154[_0x664328('0x39')],'resourceId':_0x1bd154['id'],'type':_0x55a512[_0x664328('0x39')],'sectionId':_0x55a512['id']},{})[_0x664328('0x3c')](function(){return _0x57d96d;}):_0x57d96d;})['catch'](function(_0x5b876d){const _0x48f844=_0x21bd92;logger[_0x48f844('0x28')](_0x48f844('0x3f'),_0x5b876d);throw _0x5b876d;});}return _0x57d96d;})[_0x5168e5('0x3c')](respondWithResult(_0x2a014a,0xc9))[_0x5168e5('0x25')](handleError(_0x2a014a,null));},exports[_0x409aca('0x0')]=function(_0x5d2712,_0x5a7baf){const _0x5b50e8=_0x409aca;return _0x5d2712[_0x5b50e8('0x3a')]['id']&&delete _0x5d2712[_0x5b50e8('0x3a')]['id'],db['Disposition'][_0x5b50e8('0x20')]({'where':{'id':_0x5d2712[_0x5b50e8('0x18')]['id']}})[_0x5b50e8('0x3c')](handleEntityNotFound(_0x5a7baf,null))['then'](saveUpdates(_0x5d2712[_0x5b50e8('0x3a')],null))[_0x5b50e8('0x3c')](respondWithResult(_0x5a7baf,null))[_0x5b50e8('0x25')](handleError(_0x5a7baf,null));},exports[_0x409aca('0x7')]=function(_0x570597,_0x2ddc5a){const _0x1b27da=_0x409aca;return db[_0x1b27da('0x2e')][_0x1b27da('0x20')]({'where':{'id':_0x570597[_0x1b27da('0x18')]['id']}})['then'](handleEntityNotFound(_0x2ddc5a,null))[_0x1b27da('0x3c')](removeEntity(_0x2ddc5a,null))[_0x1b27da('0x25')](handleError(_0x2ddc5a,null));}; \ No newline at end of file +const a182_0x47c0=['api','sequelize','catch','options','Unable\x20to\x20retrieve\x20the\x20current\x20user','update','keys','limit','intersection','sort','userProfileId','destroy','offset','user','index','Disposition','model','params','name','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','count','../../mysqldb','body','type','role','findAll','lodash','status','then','include','attributes','filters','where','fields','sendStatus','filter','autoAssociation','Content-Range','UserProfileResource','merge','create','query','show','get','map','fieldName','undefined','length','set','json','includeAll','like','Dispositions','error','rawAttributes','findOne','send'];(function(_0xa4b1a9,_0x47c013){const _0x3253bc=function(_0x21971){while(--_0x21971){_0xa4b1a9['push'](_0xa4b1a9['shift']());}};_0x3253bc(++_0x47c013);}(a182_0x47c0,0xa9));const a182_0x3253=function(_0xa4b1a9,_0x47c013){_0xa4b1a9=_0xa4b1a9-0x0;let _0x3253bc=a182_0x47c0[_0xa4b1a9];return _0x3253bc;};const _0x49415b=a182_0x3253;'use strict';const _=require(_0x49415b('0x1c')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x49415b('0x2')),db=require(_0x49415b('0x17'))['db'],{Op}=require(_0x49415b('0x3'));function respondWithResult(_0x21971,_0x544024){return _0x544024=_0x544024||0xc8,function(_0x439e67){const _0x4da94e=a182_0x3253;if(_0x439e67)return _0x21971[_0x4da94e('0x1d')](_0x544024)[_0x4da94e('0x33')](_0x439e67);};}function respondWithFilteredResult(_0x2d9ff1,_0x456e54){return function(_0x48c4ce){const _0x3606e2=a182_0x3253;if(_0x48c4ce){const _0x4afb09=_0x48c4ce[_0x3606e2('0x16')],_0x1efbe0=_0x456e54[_0x3606e2('0xe')];let _0x2ed137=_0x456e54[_0x3606e2('0xe')]+_0x456e54[_0x3606e2('0x9')],_0x304107;return _0x2ed137>=_0x4afb09?(_0x2ed137=_0x4afb09,_0x304107=0xc8):_0x304107=0xce,_0x2d9ff1[_0x3606e2('0x1d')](_0x304107),_0x2d9ff1[_0x3606e2('0x32')](_0x3606e2('0x27'),_0x1efbe0+'-'+_0x2ed137+'/'+_0x4afb09)[_0x3606e2('0x33')](_0x48c4ce);}return null;};}function saveUpdates(_0x54f1c7){return function(_0xd5d31b){const _0x27eab3=a182_0x3253;if(_0xd5d31b)return _0xd5d31b[_0x27eab3('0x7')](_0x54f1c7)['then'](function(_0x18507c){return _0x18507c;});return null;};}function removeEntity(_0x573f23){return function(_0x560800){const _0x191b2b=a182_0x3253;if(_0x560800)return _0x560800[_0x191b2b('0xd')]()[_0x191b2b('0x1e')](function(){const _0x5e894c=_0x191b2b,_0x3cd502=_0x560800[_0x5e894c('0x2d')]({'plain':!![]}),_0x5e51ff=_0x5e894c('0x36');return db['UserProfileResource']['destroy']({'where':{'type':_0x5e51ff,'resourceId':_0x3cd502['id']}})[_0x5e894c('0x1e')](function(){return _0x560800;});})[_0x191b2b('0x1e')](function(){const _0xbfc64a=_0x191b2b;_0x573f23[_0xbfc64a('0x1d')](0xcc)['end']();});};}function handleEntityNotFound(_0x5ba895){return function(_0x4d97c9){const _0x1256b0=a182_0x3253;return!_0x4d97c9&&_0x5ba895[_0x1256b0('0x24')](0x194),_0x4d97c9;};}function handleError(_0x49f237,_0xabf85b){return _0xabf85b=_0xabf85b||0x1f4,function(_0x4c3d09){const _0x515a12=a182_0x3253;logger[_0x515a12('0x37')](_0x4c3d09['stack']),_0x4c3d09[_0x515a12('0x14')]&&delete _0x4c3d09[_0x515a12('0x14')],_0x49f237[_0x515a12('0x1d')](_0xabf85b)[_0x515a12('0x1')](_0x4c3d09);};}exports[_0x49415b('0x10')]=function(_0x1fa272,_0xb0b953){const _0x1c7ba1=_0x49415b;let _0x4708c8={};const _0x588546={},_0x3523d9={'count':0x0,'rows':[]},_0x5d7604=_[_0x1c7ba1('0x2e')](db[_0x1c7ba1('0x11')][_0x1c7ba1('0x38')],function(_0x16cd9f){const _0x223f4c=_0x1c7ba1;return{'name':_0x16cd9f[_0x223f4c('0x2f')],'type':_0x16cd9f[_0x223f4c('0x19')]['key']};});_0x588546[_0x1c7ba1('0x12')]=_[_0x1c7ba1('0x2e')](_0x5d7604,_0x1c7ba1('0x14')),_0x588546[_0x1c7ba1('0x2b')]=_[_0x1c7ba1('0x8')](_0x1fa272[_0x1c7ba1('0x2b')]),_0x588546[_0x1c7ba1('0x21')]=_[_0x1c7ba1('0xa')](_0x588546[_0x1c7ba1('0x12')],_0x588546[_0x1c7ba1('0x2b')]),_0x4708c8[_0x1c7ba1('0x20')]=_[_0x1c7ba1('0xa')](_0x588546[_0x1c7ba1('0x12')],qs[_0x1c7ba1('0x23')](_0x1fa272['query']['fields'])),_0x4708c8[_0x1c7ba1('0x20')]=_0x4708c8[_0x1c7ba1('0x20')][_0x1c7ba1('0x31')]?_0x4708c8[_0x1c7ba1('0x20')]:_0x588546['model'];typeof _0x1fa272[_0x1c7ba1('0x2b')]['nolimit']===_0x1c7ba1('0x30')&&(_0x4708c8['limit']=qs[_0x1c7ba1('0x9')](_0x1fa272['query'][_0x1c7ba1('0x9')]),_0x4708c8[_0x1c7ba1('0xe')]=qs[_0x1c7ba1('0xe')](_0x1fa272[_0x1c7ba1('0x2b')][_0x1c7ba1('0xe')]));_0x4708c8['order']=qs[_0x1c7ba1('0xb')](_0x1fa272[_0x1c7ba1('0x2b')]['sort']),_0x4708c8[_0x1c7ba1('0x22')]=qs[_0x1c7ba1('0x21')](_['pick'](_0x1fa272[_0x1c7ba1('0x2b')],_0x588546['filters']),_0x5d7604);_0x1fa272[_0x1c7ba1('0x2b')][_0x1c7ba1('0x25')]&&(_0x4708c8[_0x1c7ba1('0x22')]=_[_0x1c7ba1('0x29')](_0x4708c8[_0x1c7ba1('0x22')],{[Op['or']]:_[_0x1c7ba1('0x2e')](_0x5d7604,function(_0x22d1ee){const _0x3af252=_0x1c7ba1;if(_0x22d1ee[_0x3af252('0x19')]!=='VIRTUAL'){const _0x446a57={};return _0x446a57[_0x22d1ee[_0x3af252('0x14')]]={[Op[_0x3af252('0x35')]]:'%'+_0x1fa272[_0x3af252('0x2b')][_0x3af252('0x25')]+'%'},_0x446a57;}})}));_0x4708c8=_[_0x1c7ba1('0x29')]({},_0x4708c8,_0x1fa272[_0x1c7ba1('0x5')]);const _0x41c7a6={'where':_0x4708c8[_0x1c7ba1('0x22')]};return db['Disposition'][_0x1c7ba1('0x16')](_0x41c7a6)[_0x1c7ba1('0x1e')](function(_0x427768){const _0x4a92c6=_0x1c7ba1;return _0x3523d9[_0x4a92c6('0x16')]=_0x427768,_0x1fa272[_0x4a92c6('0x2b')][_0x4a92c6('0x34')]&&(_0x4708c8['include']=[{'all':!![]}]),db[_0x4a92c6('0x11')][_0x4a92c6('0x1b')](_0x4708c8);})[_0x1c7ba1('0x1e')](function(_0x68e940){return _0x3523d9['rows']=_0x68e940,_0x3523d9;})[_0x1c7ba1('0x1e')](respondWithFilteredResult(_0xb0b953,_0x4708c8))[_0x1c7ba1('0x4')](handleError(_0xb0b953,null));},exports[_0x49415b('0x2c')]=function(_0x164112,_0x5dd19e){const _0x562afc=_0x49415b;let _0x121b45={'raw':!![],'where':{'id':_0x164112[_0x562afc('0x13')]['id']}};const _0xb27093={};return _0xb27093['model']=_['keys'](db[_0x562afc('0x11')]['rawAttributes']),_0xb27093[_0x562afc('0x2b')]=_[_0x562afc('0x8')](_0x164112[_0x562afc('0x2b')]),_0xb27093[_0x562afc('0x21')]=_[_0x562afc('0xa')](_0xb27093[_0x562afc('0x12')],_0xb27093[_0x562afc('0x2b')]),_0x121b45[_0x562afc('0x20')]=_[_0x562afc('0xa')](_0xb27093[_0x562afc('0x12')],qs['fields'](_0x164112[_0x562afc('0x2b')][_0x562afc('0x23')])),_0x121b45[_0x562afc('0x20')]=_0x121b45['attributes'][_0x562afc('0x31')]?_0x121b45['attributes']:_0xb27093[_0x562afc('0x12')],_0x164112[_0x562afc('0x2b')][_0x562afc('0x34')]&&(_0x121b45[_0x562afc('0x1f')]=[{'all':!![]}]),_0x121b45=_[_0x562afc('0x29')]({},_0x121b45,_0x164112[_0x562afc('0x5')]),db[_0x562afc('0x11')][_0x562afc('0x0')](_0x121b45)[_0x562afc('0x1e')](handleEntityNotFound(_0x5dd19e,null))[_0x562afc('0x1e')](respondWithResult(_0x5dd19e,null))['catch'](handleError(_0x5dd19e,null));},exports['create']=function(_0x50ef47,_0x3b13cd){const _0x236519=_0x49415b;return db['Disposition'][_0x236519('0x2a')](_0x50ef47[_0x236519('0x18')],{})[_0x236519('0x1e')](function(_0x1c2013){const _0x311ac8=_0x236519,_0x3d71e=_0x50ef47[_0x311ac8('0xf')][_0x311ac8('0x2d')]({'plain':!![]});if(!_0x3d71e)throw new Error(_0x311ac8('0x6'));if(_0x3d71e[_0x311ac8('0x1a')]===_0x311ac8('0xf')){const _0x94208d=_0x1c2013[_0x311ac8('0x2d')]({'plain':!![]}),_0xfdbfce=_0x311ac8('0x36');return db['UserProfileSection'][_0x311ac8('0x0')]({'where':{'name':_0xfdbfce,'userProfileId':_0x3d71e[_0x311ac8('0xc')]},'raw':!![]})[_0x311ac8('0x1e')](function(_0x2568d5){const _0x21515e=_0x311ac8;return _0x2568d5&&_0x2568d5[_0x21515e('0x26')]===0x0?db[_0x21515e('0x28')][_0x21515e('0x2a')]({'name':_0x94208d[_0x21515e('0x14')],'resourceId':_0x94208d['id'],'type':_0x2568d5[_0x21515e('0x14')],'sectionId':_0x2568d5['id']},{})[_0x21515e('0x1e')](function(){return _0x1c2013;}):_0x1c2013;})[_0x311ac8('0x4')](function(_0x58412a){const _0x59cd7a=_0x311ac8;logger[_0x59cd7a('0x37')](_0x59cd7a('0x15'),_0x58412a);throw _0x58412a;});}return _0x1c2013;})['then'](respondWithResult(_0x3b13cd,0xc9))[_0x236519('0x4')](handleError(_0x3b13cd,null));},exports[_0x49415b('0x7')]=function(_0x33d2b9,_0x17eba4){const _0x19fd6a=_0x49415b;return _0x33d2b9[_0x19fd6a('0x18')]['id']&&delete _0x33d2b9[_0x19fd6a('0x18')]['id'],db[_0x19fd6a('0x11')][_0x19fd6a('0x0')]({'where':{'id':_0x33d2b9['params']['id']}})[_0x19fd6a('0x1e')](handleEntityNotFound(_0x17eba4,null))['then'](saveUpdates(_0x33d2b9[_0x19fd6a('0x18')],null))[_0x19fd6a('0x1e')](respondWithResult(_0x17eba4,null))[_0x19fd6a('0x4')](handleError(_0x17eba4,null));},exports['destroy']=function(_0x43639c,_0x5e00bc){const _0x3c9507=_0x49415b;return db[_0x3c9507('0x11')]['findOne']({'where':{'id':_0x43639c[_0x3c9507('0x13')]['id']}})[_0x3c9507('0x1e')](handleEntityNotFound(_0x5e00bc,null))[_0x3c9507('0x1e')](removeEntity(_0x5e00bc,null))[_0x3c9507('0x4')](handleError(_0x5e00bc,null));}; \ No newline at end of file diff --git a/server/api/disposition/disposition.model.js b/server/api/disposition/disposition.model.js index 2ee81e6..ba4d6c8 100644 --- a/server/api/disposition/disposition.model.js +++ b/server/api/disposition/disposition.model.js @@ -1 +1 @@ -const a183_0x5863=['./disposition.attributes','WhatsappAccountId','ChatWebsiteId','name_voice','name_openchannel','MailAccountId','name','tools_dispositions','exports','name_whatsapp','name_chat','name_fax','SmsAccountId','define','Disposition','name_sms'];(function(_0x28c39a,_0x586342){const _0x5e0858=function(_0x3467be){while(--_0x3467be){_0x28c39a['push'](_0x28c39a['shift']());}};_0x5e0858(++_0x586342);}(a183_0x5863,0xab));const a183_0x5e08=function(_0x28c39a,_0x586342){_0x28c39a=_0x28c39a-0x0;let _0x5e0858=a183_0x5863[_0x28c39a];return _0x5e0858;};const _0x1bc593=a183_0x5e08;'use strict';const attributes=require(_0x1bc593('0x5'));module[_0x1bc593('0xd')]=function(_0x3467be){const _0x19015a=_0x1bc593,_0x4fef71=_0x3467be[_0x19015a('0x2')](_0x19015a('0x3'),attributes,{'tableName':_0x19015a('0xc'),'paranoid':![],'indexes':[{'unique':!![],'name':_0x19015a('0x8'),'fields':[_0x19015a('0xb'),'ListId']},{'unique':!![],'name':_0x19015a('0xf'),'fields':[_0x19015a('0xb'),_0x19015a('0x7')]},{'unique':!![],'name':'name_mail','fields':[_0x19015a('0xb'),_0x19015a('0xa')]},{'unique':!![],'name':_0x19015a('0x4'),'fields':[_0x19015a('0xb'),_0x19015a('0x1')]},{'unique':!![],'name':_0x19015a('0x0'),'fields':[_0x19015a('0xb'),'FaxAccountId']},{'unique':!![],'name':_0x19015a('0x9'),'fields':[_0x19015a('0xb'),'OpenchannelAccountId']},{'unique':!![],'name':_0x19015a('0xe'),'fields':[_0x19015a('0xb'),_0x19015a('0x6')]}],'timestamps':!![]});return _0x4fef71;}; \ No newline at end of file +const a183_0x24cc=['FaxAccountId','OpenchannelAccountId','SmsAccountId','ListId','name_chat','./disposition.attributes','name_mail','exports','name_fax','tools_dispositions','name_voice','name','define','MailAccountId'];(function(_0x447a80,_0x24cc2a){const _0x25b317=function(_0x474672){while(--_0x474672){_0x447a80['push'](_0x447a80['shift']());}};_0x25b317(++_0x24cc2a);}(a183_0x24cc,0x1ec));const a183_0x25b3=function(_0x447a80,_0x24cc2a){_0x447a80=_0x447a80-0x0;let _0x25b317=a183_0x24cc[_0x447a80];return _0x25b317;};const _0x4ed149=a183_0x25b3;'use strict';const attributes=require(_0x4ed149('0x3'));module[_0x4ed149('0x5')]=function(_0x474672){const _0x3411f3=_0x4ed149,_0x1d8315=_0x474672[_0x3411f3('0xa')]('Disposition',attributes,{'tableName':_0x3411f3('0x7'),'paranoid':![],'indexes':[{'unique':!![],'name':_0x3411f3('0x8'),'fields':[_0x3411f3('0x9'),_0x3411f3('0x1')]},{'unique':!![],'name':_0x3411f3('0x2'),'fields':['name','ChatWebsiteId']},{'unique':!![],'name':_0x3411f3('0x4'),'fields':[_0x3411f3('0x9'),_0x3411f3('0xb')]},{'unique':!![],'name':'name_sms','fields':[_0x3411f3('0x9'),_0x3411f3('0x0')]},{'unique':!![],'name':_0x3411f3('0x6'),'fields':['name',_0x3411f3('0xc')]},{'unique':!![],'name':'name_openchannel','fields':[_0x3411f3('0x9'),_0x3411f3('0xd')]},{'unique':!![],'name':'name_whatsapp','fields':[_0x3411f3('0x9'),'WhatsappAccountId']}],'timestamps':!![]});return _0x1d8315;}; \ No newline at end of file diff --git a/server/api/disposition/index.js b/server/api/disposition/index.js index 70ff15e..c1bb540 100644 --- a/server/api/disposition/index.js +++ b/server/api/disposition/index.js @@ -1 +1 @@ -const a184_0x1f56=['index','delete','../../components/auth/service','create','destroy','Router','get','put','exports','show','update','./disposition.controller','/:id','isAuthenticated'];(function(_0x43266d,_0x1f5682){const _0x195bf7=function(_0x4df331){while(--_0x4df331){_0x43266d['push'](_0x43266d['shift']());}};_0x195bf7(++_0x1f5682);}(a184_0x1f56,0x136));const a184_0x195b=function(_0x43266d,_0x1f5682){_0x43266d=_0x43266d-0x0;let _0x195bf7=a184_0x1f56[_0x43266d];return _0x195bf7;};const _0x295ff5=a184_0x195b;'use strict';const express=require('express'),router=express[_0x295ff5('0x3')](),auth=require(_0x295ff5('0x0')),controller=require(_0x295ff5('0x9'));router[_0x295ff5('0x4')]('/',auth['isAuthenticated'](),controller[_0x295ff5('0xc')]),router[_0x295ff5('0x4')]('/:id',auth[_0x295ff5('0xb')](),controller[_0x295ff5('0x7')]),router['post']('/',auth[_0x295ff5('0xb')](),controller[_0x295ff5('0x1')]),router[_0x295ff5('0x5')]('/:id',auth[_0x295ff5('0xb')](),controller[_0x295ff5('0x8')]),router[_0x295ff5('0xd')](_0x295ff5('0xa'),auth['isAuthenticated'](),controller[_0x295ff5('0x2')]),module[_0x295ff5('0x6')]=router; \ No newline at end of file +const a184_0x3ef9=['Router','isAuthenticated','show','update','get','../../components/auth/service','./disposition.controller','index','delete','put','/:id','exports','post'];(function(_0x33752b,_0x3ef95a){const _0x330eaf=function(_0x4f88b0){while(--_0x4f88b0){_0x33752b['push'](_0x33752b['shift']());}};_0x330eaf(++_0x3ef95a);}(a184_0x3ef9,0xe6));const a184_0x330e=function(_0x33752b,_0x3ef95a){_0x33752b=_0x33752b-0x0;let _0x330eaf=a184_0x3ef9[_0x33752b];return _0x330eaf;};const _0x2c1bea=a184_0x330e;'use strict';const express=require('express'),router=express[_0x2c1bea('0x4')](),auth=require(_0x2c1bea('0x9')),controller=require(_0x2c1bea('0xa'));router['get']('/',auth[_0x2c1bea('0x5')](),controller[_0x2c1bea('0xb')]),router[_0x2c1bea('0x8')](_0x2c1bea('0x1'),auth[_0x2c1bea('0x5')](),controller[_0x2c1bea('0x6')]),router[_0x2c1bea('0x3')]('/',auth[_0x2c1bea('0x5')](),controller['create']),router[_0x2c1bea('0x0')](_0x2c1bea('0x1'),auth['isAuthenticated'](),controller[_0x2c1bea('0x7')]),router[_0x2c1bea('0xc')](_0x2c1bea('0x1'),auth[_0x2c1bea('0x5')](),controller['destroy']),module[_0x2c1bea('0x2')]=router; \ No newline at end of file diff --git a/server/api/faxAccount/faxAccount.attributes.js b/server/api/faxAccount/faxAccount.attributes.js index bf636f6..a20f63d 100644 --- a/server/api/faxAccount/faxAccount.attributes.js +++ b/server/api/faxAccount/faxAccount.attributes.js @@ -1 +1 @@ -const a185_0x3443=['v17,v27,v29','INTEGER','14400','localstationid','yes','7200','ENUM','TEXT','mandatoryDisposition','BOOLEAN','xCALLY\x20Motion\x20Fax','Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}','KHOMP','DADHI','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','9600','SIP','2400','12000','setDataValue','STRING','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','sequelize','IAX'];(function(_0x39172e,_0x3443c4){const _0x2aa2d6=function(_0x2f6948){while(--_0x2f6948){_0x39172e['push'](_0x39172e['shift']());}};_0x2aa2d6(++_0x3443c4);}(a185_0x3443,0x10c));const a185_0x2aa2=function(_0x39172e,_0x3443c4){_0x39172e=_0x39172e-0x0;let _0x2aa2d6=a185_0x3443[_0x39172e];return _0x2aa2d6;};const _0x3b5d22=a185_0x2aa2;'use strict';const Sequelize=require(_0x3b5d22('0x12'));module['exports']={'name':{'type':Sequelize[_0x3b5d22('0x10')],'allowNull':![],'validate':{'notEmpty':!![]}},'description':{'type':Sequelize[_0x3b5d22('0x10')]},'ecm':{'type':Sequelize[_0x3b5d22('0x2')](_0x3b5d22('0x0'),'no'),'defaultValue':_0x3b5d22('0x0')},'headerinfo':{'type':Sequelize['STRING'],'defaultValue':_0x3b5d22('0x6')},'localstationid':{'type':Sequelize[_0x3b5d22('0x10')],'unique':_0x3b5d22('0x17')},'minrate':{'type':Sequelize[_0x3b5d22('0x2')](_0x3b5d22('0xd'),'4800',_0x3b5d22('0x1'),'9600',_0x3b5d22('0xe'),'14400'),'defaultValue':'4800'},'maxrate':{'type':Sequelize[_0x3b5d22('0x2')](_0x3b5d22('0xd'),'4800',_0x3b5d22('0x1'),_0x3b5d22('0xb'),_0x3b5d22('0xe'),_0x3b5d22('0x16')),'defaultValue':'14400'},'modem':{'type':Sequelize[_0x3b5d22('0x10')],'defaultValue':_0x3b5d22('0x14')},'gateway':{'type':Sequelize[_0x3b5d22('0x10')],'defaultValue':'no','validate':{'is':/^(?:yes|no|[0-9]+)$/}},'faxdetect':{'type':Sequelize['STRING'],'defaultValue':'no','validate':{'is':/^(?:yes|no|t38|cng|[0-9]+)$/}},'t38timeout':{'type':Sequelize[_0x3b5d22('0x15')],'defaultValue':0x1388,'validate':{'min':0x3e8}},'tech':{'type':Sequelize[_0x3b5d22('0x2')](_0x3b5d22('0xc'),_0x3b5d22('0x13'),_0x3b5d22('0x9'),_0x3b5d22('0x8')),'defaultValue':_0x3b5d22('0xc')},'key':{'type':Sequelize[_0x3b5d22('0x10')],'allowNull':![]},'notificationTemplate':{'type':Sequelize[_0x3b5d22('0x3')],'defaultValue':function(){const _0x1aa6c5=_0x3b5d22;return _0x1aa6c5('0x7');}},'notificationSound':{'type':Sequelize[_0x3b5d22('0x5')],'defaultValue':!![]},'notificationShake':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x3b5d22('0x15')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'queueTransfer':{'type':Sequelize[_0x3b5d22('0x5')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x3b5d22('0x15')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize[_0x3b5d22('0x5')],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0x3b5d22('0x15')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'mandatoryDispositionPauseId':{'type':Sequelize['INTEGER'],'allowNull':!![],'defaultValue':null,'comment':_0x3b5d22('0x11')},'mandatoryDisposition':{'type':Sequelize[_0x3b5d22('0x5')],'defaultValue':![],'comment':_0x3b5d22('0xa'),'set':function(_0x2f6948){const _0x4b3ade=_0x3b5d22;if(!_0x2f6948)this[_0x4b3ade('0xf')]('mandatoryDispositionPauseId',null);this[_0x4b3ade('0xf')](_0x4b3ade('0x4'),_0x2f6948);}}}; \ No newline at end of file +const a185_0x5848=['TEXT','KHOMP','STRING','7200','4800','xCALLY\x20Motion\x20Fax','BOOLEAN','2400','SIP','exports','ENUM','localstationid','mandatoryDispositionPauseId','mandatoryDisposition','INTEGER','yes','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','14400','setDataValue','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','12000','9600','sequelize'];(function(_0x400760,_0x584882){const _0x9d9f3a=function(_0x372c21){while(--_0x372c21){_0x400760['push'](_0x400760['shift']());}};_0x9d9f3a(++_0x584882);}(a185_0x5848,0x1f3));const a185_0x9d9f=function(_0x400760,_0x584882){_0x400760=_0x400760-0x0;let _0x9d9f3a=a185_0x5848[_0x400760];return _0x9d9f3a;};const _0x28884b=a185_0x9d9f;'use strict';const Sequelize=require(_0x28884b('0x6'));module[_0x28884b('0x10')]={'name':{'type':Sequelize[_0x28884b('0x9')],'allowNull':![],'validate':{'notEmpty':!![]}},'description':{'type':Sequelize[_0x28884b('0x9')]},'ecm':{'type':Sequelize['ENUM'](_0x28884b('0x16'),'no'),'defaultValue':_0x28884b('0x16')},'headerinfo':{'type':Sequelize[_0x28884b('0x9')],'defaultValue':_0x28884b('0xc')},'localstationid':{'type':Sequelize[_0x28884b('0x9')],'unique':_0x28884b('0x12')},'minrate':{'type':Sequelize['ENUM'](_0x28884b('0xe'),'4800',_0x28884b('0xa'),'9600',_0x28884b('0x4'),_0x28884b('0x1')),'defaultValue':_0x28884b('0xb')},'maxrate':{'type':Sequelize[_0x28884b('0x11')]('2400',_0x28884b('0xb'),_0x28884b('0xa'),_0x28884b('0x5'),_0x28884b('0x4'),_0x28884b('0x1')),'defaultValue':_0x28884b('0x1')},'modem':{'type':Sequelize[_0x28884b('0x9')],'defaultValue':'v17,v27,v29'},'gateway':{'type':Sequelize[_0x28884b('0x9')],'defaultValue':'no','validate':{'is':/^(?:yes|no|[0-9]+)$/}},'faxdetect':{'type':Sequelize[_0x28884b('0x9')],'defaultValue':'no','validate':{'is':/^(?:yes|no|t38|cng|[0-9]+)$/}},'t38timeout':{'type':Sequelize[_0x28884b('0x15')],'defaultValue':0x1388,'validate':{'min':0x3e8}},'tech':{'type':Sequelize['ENUM']('SIP','IAX','DADHI',_0x28884b('0x8')),'defaultValue':_0x28884b('0xf')},'key':{'type':Sequelize[_0x28884b('0x9')],'allowNull':![]},'notificationTemplate':{'type':Sequelize[_0x28884b('0x7')],'defaultValue':function(){return'Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}';}},'notificationSound':{'type':Sequelize[_0x28884b('0xd')],'defaultValue':!![]},'notificationShake':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x28884b('0x15')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'queueTransfer':{'type':Sequelize[_0x28884b('0xd')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x28884b('0x15')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize[_0x28884b('0xd')],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0x28884b('0x15')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'mandatoryDispositionPauseId':{'type':Sequelize[_0x28884b('0x15')],'allowNull':!![],'defaultValue':null,'comment':_0x28884b('0x3')},'mandatoryDisposition':{'type':Sequelize[_0x28884b('0xd')],'defaultValue':![],'comment':_0x28884b('0x0'),'set':function(_0x372c21){const _0x35e048=_0x28884b;if(!_0x372c21)this[_0x35e048('0x2')](_0x35e048('0x13'),null);this[_0x35e048('0x2')](_0x35e048('0x14'),_0x372c21);}}}; \ No newline at end of file diff --git a/server/api/faxAccount/faxAccount.controller.js b/server/api/faxAccount/faxAccount.controller.js index 05dab14..ccbf4e6 100644 --- a/server/api/faxAccount/faxAccount.controller.js +++ b/server/api/faxAccount/faxAccount.controller.js @@ -1 +1 @@ -const a186_0x2502=['createdAt','emit','out','addAccountApplications','order','format','ecm','addAnswer','addInteraction','autoAssociation','Contact\x20not\x20found','attachments','keys','from','Tag','modem','SendFax','pick','filename','user','addApplications','client','FaxAccount,\x20%s,\x20%s,\x20%s','params','merge','debug','bulkCreate','sort','sendStatus','Contact','error','rows','fax','set','status','gte','moment','CDR(type)=inbound-fax','VIRTUAL','getInteractions','getApplications','UserProfileSection','request\x20sent','send','isArray','util','type','stack','where','offset','result','length','stringify','http','priority','userProfileId','userFaxAccount:remove','findByPk','getAnswers','CmList','body','undefined','register','like','name','filter','internal','system','../../mysqldb','Content-Range','get','getDispositions','mandatoryDispositionPause','Unable\x20to\x20retrieve\x20the\x20current\x20user','Owner','Messages','rawAttributes','fields','code','model','root','attributes','localstationid','transaction','context','options','FaxApplication','addDisposition','ReceiveFax','\x22%s\x22\x20<%s>','includeAll','DESC','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','fullname','Contacts','CheckAfterSend','update','map','json','removeAnswers','getAgents','path','headerinfo','List\x20not\x20found','addAgents','jayson/promise','join','query','ids','YYYY-MM-DD\x20HH:mm:ss','exten','basename','push','updatedAt','info','./faxAccount.socket','isNil','Answer','FaxAccount','CannedAnswer','FaxInteraction','FaxMessage','removeAgents','limit','intersection','from-voip-provider','tag','request','describe','FaxAccounts','include','omit','then','filters','VoiceExtension','../../config/logger','../../rediscache','destroy','Fax\x20Extension','userFaxAccount:save','Pause','FAXOPT(','List','create','nolimit','ListId','gateway','catch','appdata','SendFaxRpc,\x20%s','Disposition','/var/opt/motion2/server/files/attachments/fax-${CALLERID(num)}-${CUT(UNIQUEID,.,1)}-${CUT(UNIQUEID,.,2)}-${STRFTIME(,,%C%y%m%d%H%M%S)}-rx.tif,d','$gte','dataValues','sequelize','CmContact','role','tech','defaults','FaxAccountId','../../components/parsers/qs','fieldName','message','minrate','removeDispositions','User','server/files/attachments','findAll','findOne','index','split','FaxAccount,\x20%s,\x20%s','findAndCountAll','t38timeout','count','end','Tags','maxrate'];(function(_0x4119f0,_0x250288){const _0x29e6e3=function(_0x1a4765){while(--_0x1a4765){_0x4119f0['push'](_0x4119f0['shift']());}};_0x29e6e3(++_0x250288);}(a186_0x2502,0x155));const a186_0x29e6=function(_0x4119f0,_0x250288){_0x4119f0=_0x4119f0-0x0;let _0x29e6e3=a186_0x2502[_0x4119f0];return _0x29e6e3;};const _0xfcc404=a186_0x29e6;'use strict';const moment=require(_0xfcc404('0x33')),util=require(_0xfcc404('0x3c')),path=require(_0xfcc404('0x74')),_=require('lodash'),{getSocket}=require(_0xfcc404('0x97')),socket=getSocket(),qs=require(_0xfcc404('0xaf')),logger=require(_0xfcc404('0x96'))('api'),config=require('../../config/environment'),db=require(_0xfcc404('0x53'))['db'],{Op}=require(_0xfcc404('0xa9'));require(_0xfcc404('0x82'))[_0xfcc404('0x4d')](socket);const jayson=require(_0xfcc404('0x78')),client=jayson[_0xfcc404('0x24')]['http']({'port':0x232c}),client9002=jayson[_0xfcc404('0x24')][_0xfcc404('0x44')]({'port':0x232a});function respondWithRpcPromise(_0x1a4765,_0x1e55c1,_0x345218,_0xa9e3e1){return new Promise(function(_0x2f5787,_0x2ccb8b){const _0x6e26b2=a186_0x29e6,_0x23cdb2=_0xa9e3e1||client;return _0x23cdb2[_0x6e26b2('0x8e')](_0x1a4765,_0x345218)[_0x6e26b2('0x93')](function(_0x1d7c68){const _0x1b5d2f=_0x6e26b2;logger['info'](_0x1b5d2f('0x8'),_0x1e55c1,_0x1b5d2f('0x39')),logger[_0x1b5d2f('0x28')](_0x1b5d2f('0x25'),_0x1e55c1,'request\x20sent',JSON[_0x1b5d2f('0x43')](_0x1d7c68));if(_0x1d7c68[_0x1b5d2f('0x2d')]){if(_0x1d7c68['error'][_0x1b5d2f('0x5d')]===0x1f4)return logger[_0x1b5d2f('0x2d')](_0x1b5d2f('0x8'),_0x1e55c1,_0x1d7c68[_0x1b5d2f('0x2d')][_0x1b5d2f('0xb1')]),_0x2ccb8b(_0x1d7c68['error']['message']);return logger['error'](_0x1b5d2f('0x8'),_0x1e55c1,_0x1d7c68[_0x1b5d2f('0x2d')]['message']),_0x2f5787(_0x1d7c68[_0x1b5d2f('0x2d')]['message']);}else logger[_0x1b5d2f('0x81')](_0x1b5d2f('0x8'),_0x1e55c1,_0x1b5d2f('0x39')),_0x2f5787(_0x1d7c68[_0x1b5d2f('0x41')][_0x1b5d2f('0xb1')]);})['catch'](function(_0x13566c){const _0x32463e=_0x6e26b2;logger['error'](_0x32463e('0x8'),_0x1e55c1,_0x13566c),_0x2ccb8b(_0x13566c);});});}function respondWithStatusCode(_0x22c9bb,_0x5b4f9c){return _0x5b4f9c=_0x5b4f9c||0xcc,function(_0x5171b3){const _0x80a484=a186_0x29e6;if(_0x5171b3)return _0x22c9bb[_0x80a484('0x2b')](_0x5b4f9c);return _0x22c9bb[_0x80a484('0x31')](_0x5b4f9c)[_0x80a484('0xc')]();};}function respondWithResult(_0x4be686,_0x1d2383){return _0x1d2383=_0x1d2383||0xc8,function(_0x1a019d){const _0x4683f1=a186_0x29e6;if(_0x1a019d)return _0x4be686[_0x4683f1('0x31')](_0x1d2383)[_0x4683f1('0x71')](_0x1a019d);};}function respondWithFilteredResult(_0x67348c,_0x5bb3f5){return function(_0x12e074){const _0x488008=a186_0x29e6;if(_0x12e074){const _0x50fe00=_0x12e074[_0x488008('0xb')],_0x5d7099=_0x5bb3f5['offset'];let _0x116645=_0x5bb3f5['offset']+_0x5bb3f5[_0x488008('0x8a')],_0x42a109;return _0x116645>=_0x50fe00?(_0x116645=_0x50fe00,_0x42a109=0xc8):_0x42a109=0xce,_0x67348c[_0x488008('0x31')](_0x42a109),_0x67348c[_0x488008('0x30')](_0x488008('0x54'),_0x5d7099+'-'+_0x116645+'/'+_0x50fe00)[_0x488008('0x71')](_0x12e074);}return null;};}function saveUpdates(_0x362c76){return function(_0x3c133b){const _0x17d6fb=a186_0x29e6;if(_0x3c133b)return _0x3c133b[_0x17d6fb('0x6f')](_0x362c76)[_0x17d6fb('0x93')](function(_0x1594c9){return _0x1594c9;});return null;};}function removeEntity(_0x32bb78){return function(_0x217b12){const _0x6ba253=a186_0x29e6;if(_0x217b12)return _0x217b12[_0x6ba253('0x98')]()[_0x6ba253('0x93')](function(){const _0x13d469=_0x6ba253,_0x19490d=_0x217b12['get']({'plain':!![]}),_0x4327fe=_0x13d469('0x90');return db['UserProfileResource']['destroy']({'where':{'type':_0x4327fe,'resourceId':_0x19490d['id']}})[_0x13d469('0x93')](function(){return _0x217b12;});})['then'](function(){const _0x17f3c4=_0x6ba253;_0x32bb78[_0x17f3c4('0x31')](0xcc)[_0x17f3c4('0xc')]();});};}function handleEntityNotFound(_0x2f62e5){return function(_0x192c24){return!_0x192c24&&_0x2f62e5['sendStatus'](0x194),_0x192c24;};}function handleError(_0x20219c,_0x379c3e){return _0x379c3e=_0x379c3e||0x1f4,function(_0x34c48f){const _0x2907dc=a186_0x29e6;logger['error'](_0x34c48f[_0x2907dc('0x3e')]),_0x34c48f[_0x2907dc('0x4f')]&&delete _0x34c48f[_0x2907dc('0x4f')],_0x20219c[_0x2907dc('0x31')](_0x379c3e)['send'](_0x34c48f);};}exports[_0xfcc404('0x6')]=function(_0x22b715,_0x20f1c0){const _0x5d75ad=_0xfcc404;let _0x27c0de={'include':[{'model':db[_0x5d75ad('0x9b')],'as':'mandatoryDispositionPause'}]};const _0x1348fc={},_0x36aa88={'count':0x0,'rows':[]},_0x543808=_[_0x5d75ad('0x70')](db[_0x5d75ad('0x85')][_0x5d75ad('0x5b')],function(_0x569110){const _0x5f584e=_0x5d75ad;return{'name':_0x569110[_0x5f584e('0xb0')],'type':_0x569110[_0x5f584e('0x3d')]['key']};});_0x1348fc[_0x5d75ad('0x5e')]=_[_0x5d75ad('0x70')](_0x543808,_0x5d75ad('0x4f')),_0x1348fc[_0x5d75ad('0x7a')]=_['keys'](_0x22b715[_0x5d75ad('0x7a')]),_0x1348fc[_0x5d75ad('0x94')]=_['intersection'](_0x1348fc['model'],_0x1348fc[_0x5d75ad('0x7a')]),_0x27c0de[_0x5d75ad('0x60')]=_['intersection'](_0x1348fc[_0x5d75ad('0x5e')],qs[_0x5d75ad('0x5c')](_0x22b715['query'][_0x5d75ad('0x5c')])),_0x27c0de[_0x5d75ad('0x60')]=_0x27c0de[_0x5d75ad('0x60')][_0x5d75ad('0x42')]?_0x27c0de[_0x5d75ad('0x60')]:_0x1348fc[_0x5d75ad('0x5e')];typeof _0x22b715['query'][_0x5d75ad('0x9f')]===_0x5d75ad('0x4c')&&(_0x27c0de[_0x5d75ad('0x8a')]=qs[_0x5d75ad('0x8a')](_0x22b715['query'][_0x5d75ad('0x8a')]),_0x27c0de[_0x5d75ad('0x40')]=qs[_0x5d75ad('0x40')](_0x22b715[_0x5d75ad('0x7a')]['offset']));_0x27c0de[_0x5d75ad('0x13')]=qs['sort'](_0x22b715[_0x5d75ad('0x7a')][_0x5d75ad('0x2a')]),_0x27c0de[_0x5d75ad('0x3f')]=qs[_0x5d75ad('0x94')](_[_0x5d75ad('0x20')](_0x22b715[_0x5d75ad('0x7a')],_0x1348fc[_0x5d75ad('0x94')]),_0x543808);_0x22b715[_0x5d75ad('0x7a')]['filter']&&(_0x27c0de[_0x5d75ad('0x3f')]=_[_0x5d75ad('0x27')](_0x27c0de[_0x5d75ad('0x3f')],{[Op['or']]:_[_0x5d75ad('0x70')](_0x543808,function(_0x190547){const _0x1685c0=_0x5d75ad;if(_0x190547['type']!==_0x1685c0('0x35')){const _0x22dcdc={};return _0x22dcdc[_0x190547[_0x1685c0('0x4f')]]={[Op[_0x1685c0('0x4e')]]:'%'+_0x22b715[_0x1685c0('0x7a')][_0x1685c0('0x50')]+'%'},_0x22dcdc;}})}));_0x27c0de=_[_0x5d75ad('0x27')]({},_0x27c0de,_0x22b715[_0x5d75ad('0x64')]);const _0x300cd1={'where':_0x27c0de['where']};return db[_0x5d75ad('0x85')][_0x5d75ad('0xb')](_0x300cd1)[_0x5d75ad('0x93')](function(_0xcd0a0f){const _0xe8ec23=_0x5d75ad;return _0x36aa88[_0xe8ec23('0xb')]=_0xcd0a0f,_0x22b715[_0xe8ec23('0x7a')][_0xe8ec23('0x69')]&&(_0x27c0de[_0xe8ec23('0x91')]=[{'all':!![]}]),db[_0xe8ec23('0x85')][_0xe8ec23('0x4')](_0x27c0de);})[_0x5d75ad('0x93')](function(_0x344f5f){return _0x36aa88['rows']=_0x344f5f,_0x36aa88;})[_0x5d75ad('0x93')](respondWithFilteredResult(_0x20f1c0,_0x27c0de))['catch'](handleError(_0x20f1c0,null));},exports['show']=function(_0x45cbe9,_0x365a23){const _0x2c73db=_0xfcc404;let _0xc51113={'raw':![],'where':{'id':_0x45cbe9[_0x2c73db('0x26')]['id']},'include':[{'model':db[_0x2c73db('0x9b')],'as':_0x2c73db('0x57')}]};const _0x5a108e={};return _0x5a108e[_0x2c73db('0x5e')]=_[_0x2c73db('0x1b')](db[_0x2c73db('0x85')][_0x2c73db('0x5b')]),_0x5a108e['query']=_[_0x2c73db('0x1b')](_0x45cbe9[_0x2c73db('0x7a')]),_0x5a108e[_0x2c73db('0x94')]=_[_0x2c73db('0x8b')](_0x5a108e[_0x2c73db('0x5e')],_0x5a108e[_0x2c73db('0x7a')]),_0xc51113[_0x2c73db('0x60')]=_[_0x2c73db('0x8b')](_0x5a108e['model'],qs[_0x2c73db('0x5c')](_0x45cbe9['query']['fields'])),_0xc51113[_0x2c73db('0x60')]=_0xc51113['attributes'][_0x2c73db('0x42')]?_0xc51113[_0x2c73db('0x60')]:_0x5a108e['model'],_0x45cbe9[_0x2c73db('0x7a')][_0x2c73db('0x69')]&&(_0xc51113[_0x2c73db('0x91')]=[{'all':!![]}]),_0xc51113=_[_0x2c73db('0x27')]({},_0xc51113,_0x45cbe9['options']),db[_0x2c73db('0x85')][_0x2c73db('0x5')](_0xc51113)[_0x2c73db('0x93')](handleEntityNotFound(_0x365a23,null))[_0x2c73db('0x93')](respondWithResult(_0x365a23,null))[_0x2c73db('0xa2')](handleError(_0x365a23,null));},exports[_0xfcc404('0x9e')]=function(_0xb902ad,_0xe52426){const _0x5602df=_0xfcc404;return db[_0x5602df('0x85')][_0x5602df('0x9e')](_0xb902ad[_0x5602df('0x4b')],{})[_0x5602df('0x93')](function(_0x41c811){const _0x21b715=_0x5602df,_0x2b4540=_0xb902ad[_0x21b715('0x22')][_0x21b715('0x55')]({'plain':!![]});if(!_0x2b4540)throw new Error(_0x21b715('0x58'));if(_0x2b4540[_0x21b715('0xab')]===_0x21b715('0x22')){const _0x271e19=_0x41c811[_0x21b715('0x55')]({'plain':!![]}),_0x2027c0=_0x21b715('0x90');return db[_0x21b715('0x38')][_0x21b715('0x5')]({'where':{'name':_0x2027c0,'userProfileId':_0x2b4540[_0x21b715('0x46')]},'raw':!![]})[_0x21b715('0x93')](function(_0x3d610e){const _0x533b08=_0x21b715;return _0x3d610e&&_0x3d610e[_0x533b08('0x18')]===0x0?db['UserProfileResource'][_0x533b08('0x9e')]({'name':_0x271e19[_0x533b08('0x4f')],'resourceId':_0x271e19['id'],'type':_0x3d610e[_0x533b08('0x4f')],'sectionId':_0x3d610e['id']},{})[_0x533b08('0x93')](function(){return _0x41c811;}):_0x41c811;})[_0x21b715('0xa2')](function(_0x1cec4a){const _0x678a6f=_0x21b715;logger['error'](_0x678a6f('0x6b'),_0x1cec4a);throw _0x1cec4a;});}return _0x41c811;})[_0x5602df('0x93')](respondWithResult(_0xe52426,0xc9))[_0x5602df('0xa2')](handleError(_0xe52426,null));},exports[_0xfcc404('0x6f')]=function(_0x109989,_0x1b01c6){const _0x422018=_0xfcc404;return _0x109989[_0x422018('0x4b')]['id']&&delete _0x109989[_0x422018('0x4b')]['id'],db[_0x422018('0x85')][_0x422018('0x5')]({'where':{'id':_0x109989[_0x422018('0x26')]['id']},'include':[{'model':db[_0x422018('0x9b')],'as':_0x422018('0x57')}]})[_0x422018('0x93')](handleEntityNotFound(_0x1b01c6,null))[_0x422018('0x93')](saveUpdates(_0x109989[_0x422018('0x4b')],null))['then'](respondWithResult(_0x1b01c6,null))[_0x422018('0xa2')](handleError(_0x1b01c6,null));},exports['destroy']=function(_0x41cef1,_0x13d5a2){const _0x222169=_0xfcc404;return db['FaxAccount']['findOne']({'where':{'id':_0x41cef1[_0x222169('0x26')]['id']}})[_0x222169('0x93')](handleEntityNotFound(_0x13d5a2,null))[_0x222169('0x93')](removeEntity(_0x13d5a2,null))[_0x222169('0xa2')](handleError(_0x13d5a2,null));},exports[_0xfcc404('0x8f')]=function(_0x4b76ab,_0x19e95d){const _0xa37602=_0xfcc404;return db[_0xa37602('0x85')][_0xa37602('0x8f')]()[_0xa37602('0x93')](respondWithResult(_0x19e95d,null))[_0xa37602('0xa2')](handleError(_0x19e95d,null));},exports[_0xfcc404('0x66')]=function(_0x249a71,_0x2bc1dd){const _0x1c233e=_0xfcc404;return _0x249a71[_0x1c233e('0x4b')]['id']&&delete _0x249a71['body']['id'],db['FaxAccount'][_0x1c233e('0x5')]({'where':{'id':_0x249a71[_0x1c233e('0x26')]['id']}})[_0x1c233e('0x93')](handleEntityNotFound(_0x2bc1dd,null))[_0x1c233e('0x93')](function(_0xb4a759){const _0x512abb=_0x1c233e;if(_0xb4a759)return _0x249a71[_0x512abb('0x4b')]['FaxAccountId']=_0xb4a759['id'],db[_0x512abb('0xa5')][_0x512abb('0x9e')](_0x249a71[_0x512abb('0x4b')]);})[_0x1c233e('0x93')](respondWithResult(_0x2bc1dd,null))[_0x1c233e('0xa2')](handleError(_0x2bc1dd,null));},exports[_0xfcc404('0x56')]=function(_0x4f1b39,_0x468d46){const _0x3ae79b=_0xfcc404;let _0x18264d={'raw':![],'where':{}};const _0x2ba9dd={},_0x4a8dcb={'count':0x0,'rows':[]};return db[_0x3ae79b('0x85')]['findOne']({'where':{'id':_0x4f1b39[_0x3ae79b('0x26')]['id']}})['then'](handleEntityNotFound(_0x468d46,null))['then'](function(_0x2a54e0){const _0x5996f5=_0x3ae79b;if(_0x2a54e0)return _0x2ba9dd[_0x5996f5('0x5e')]=_[_0x5996f5('0x1b')](db[_0x5996f5('0xa5')][_0x5996f5('0x5b')]),_0x2ba9dd[_0x5996f5('0x7a')]=_[_0x5996f5('0x1b')](_0x4f1b39[_0x5996f5('0x7a')]),_0x2ba9dd[_0x5996f5('0x94')]=_[_0x5996f5('0x8b')](_0x2ba9dd['model'],_0x2ba9dd['query']),_0x18264d[_0x5996f5('0x60')]=_['intersection'](_0x2ba9dd[_0x5996f5('0x5e')],qs[_0x5996f5('0x5c')](_0x4f1b39['query'][_0x5996f5('0x5c')])),_0x18264d[_0x5996f5('0x60')]=_0x18264d[_0x5996f5('0x60')][_0x5996f5('0x42')]?_0x18264d[_0x5996f5('0x60')]:_0x2ba9dd['model'],typeof _0x4f1b39[_0x5996f5('0x7a')][_0x5996f5('0x9f')]===_0x5996f5('0x4c')&&(_0x18264d[_0x5996f5('0x8a')]=qs[_0x5996f5('0x8a')](_0x4f1b39['query'][_0x5996f5('0x8a')]),_0x18264d[_0x5996f5('0x40')]=qs[_0x5996f5('0x40')](_0x4f1b39[_0x5996f5('0x7a')]['offset'])),_0x18264d[_0x5996f5('0x13')]=qs[_0x5996f5('0x2a')](_0x4f1b39[_0x5996f5('0x7a')]['sort']),_0x18264d[_0x5996f5('0x3f')]=qs[_0x5996f5('0x94')](_[_0x5996f5('0x20')](_0x4f1b39[_0x5996f5('0x7a')],_0x2ba9dd[_0x5996f5('0x94')])),_0x18264d[_0x5996f5('0x3f')][_0x5996f5('0xae')]=_0x2a54e0['id'],_0x4f1b39[_0x5996f5('0x7a')][_0x5996f5('0x50')]&&(_0x18264d[_0x5996f5('0x3f')]=_[_0x5996f5('0x27')](_0x18264d['where'],{[Op['or']]:_[_0x5996f5('0x70')](_0x18264d[_0x5996f5('0x60')],function(_0x320c3c){const _0x19a64a=_0x5996f5,_0xa576c4={};return _0xa576c4[_0x320c3c]={[Op[_0x19a64a('0x4e')]]:'%'+_0x4f1b39['query'][_0x19a64a('0x50')]+'%'},_0xa576c4;})})),_0x18264d=_[_0x5996f5('0x27')]({},_0x18264d,_0x4f1b39[_0x5996f5('0x64')]),db[_0x5996f5('0xa5')][_0x5996f5('0xb')]({'where':_0x18264d[_0x5996f5('0x3f')]})[_0x5996f5('0x93')](function(_0x79e505){const _0x2b2539=_0x5996f5;return _0x4a8dcb[_0x2b2539('0xb')]=_0x79e505,_0x4f1b39[_0x2b2539('0x7a')]['includeAll']&&(_0x18264d['include']=[{'all':!![]}]),db['Disposition']['findAll'](_0x18264d);})[_0x5996f5('0x93')](function(_0x3a9949){const _0x32568c=_0x5996f5;return _0x4a8dcb[_0x32568c('0x2e')]=_0x3a9949,_0x4a8dcb;});})[_0x3ae79b('0x93')](respondWithFilteredResult(_0x468d46,_0x18264d))[_0x3ae79b('0xa2')](handleError(_0x468d46,null));},exports[_0xfcc404('0x1')]=function(_0x551524,_0x39d756){const _0x3a40ac=_0xfcc404;return db[_0x3a40ac('0x85')][_0x3a40ac('0x5')]({'where':{'id':_0x551524[_0x3a40ac('0x26')]['id']}})[_0x3a40ac('0x93')](handleEntityNotFound(_0x39d756,null))[_0x3a40ac('0x93')](function(_0x13f923){const _0x3302fa=_0x3a40ac;if(_0x13f923)return _0x13f923['removeDispositions'](_0x551524[_0x3302fa('0x7a')][_0x3302fa('0x7b')]);})[_0x3a40ac('0x93')](respondWithStatusCode(_0x39d756,null))['catch'](handleError(_0x39d756,null));},exports[_0xfcc404('0x16')]=function(_0x51b8e7,_0x2b6385){const _0x4b3677=_0xfcc404;return _0x51b8e7[_0x4b3677('0x4b')]['id']&&delete _0x51b8e7[_0x4b3677('0x4b')]['id'],db[_0x4b3677('0x85')][_0x4b3677('0x5')]({'where':{'id':_0x51b8e7[_0x4b3677('0x26')]['id']}})[_0x4b3677('0x93')](handleEntityNotFound(_0x2b6385,null))[_0x4b3677('0x93')](function(_0x1ebdb5){const _0x270345=_0x4b3677;if(_0x1ebdb5)return _0x51b8e7['body'][_0x270345('0xae')]=_0x1ebdb5['id'],db['CannedAnswer']['create'](_0x51b8e7[_0x270345('0x4b')]);})[_0x4b3677('0x93')](respondWithResult(_0x2b6385,null))['catch'](handleError(_0x2b6385,null));},exports[_0xfcc404('0x49')]=function(_0x44a186,_0x20f36c){const _0x25cc16=_0xfcc404;let _0x742ac1={'raw':![],'where':{}};const _0x1151bf={},_0xc2dea5={'count':0x0,'rows':[]};return db['FaxAccount']['findOne']({'where':{'id':_0x44a186[_0x25cc16('0x26')]['id']}})[_0x25cc16('0x93')](handleEntityNotFound(_0x20f36c,null))['then'](function(_0x45e6d3){const _0x5740c6=_0x25cc16;if(_0x45e6d3)return _0x1151bf[_0x5740c6('0x5e')]=_[_0x5740c6('0x1b')](db[_0x5740c6('0x86')][_0x5740c6('0x5b')]),_0x1151bf['query']=_['keys'](_0x44a186[_0x5740c6('0x7a')]),_0x1151bf[_0x5740c6('0x94')]=_['intersection'](_0x1151bf[_0x5740c6('0x5e')],_0x1151bf[_0x5740c6('0x7a')]),_0x742ac1[_0x5740c6('0x60')]=_[_0x5740c6('0x8b')](_0x1151bf[_0x5740c6('0x5e')],qs['fields'](_0x44a186[_0x5740c6('0x7a')][_0x5740c6('0x5c')])),_0x742ac1[_0x5740c6('0x60')]=_0x742ac1[_0x5740c6('0x60')][_0x5740c6('0x42')]?_0x742ac1[_0x5740c6('0x60')]:_0x1151bf['model'],typeof _0x44a186[_0x5740c6('0x7a')][_0x5740c6('0x9f')]===_0x5740c6('0x4c')&&(_0x742ac1[_0x5740c6('0x8a')]=qs[_0x5740c6('0x8a')](_0x44a186[_0x5740c6('0x7a')][_0x5740c6('0x8a')]),_0x742ac1[_0x5740c6('0x40')]=qs[_0x5740c6('0x40')](_0x44a186[_0x5740c6('0x7a')][_0x5740c6('0x40')])),_0x742ac1[_0x5740c6('0x13')]=qs[_0x5740c6('0x2a')](_0x44a186[_0x5740c6('0x7a')][_0x5740c6('0x2a')]),_0x742ac1[_0x5740c6('0x3f')]=qs[_0x5740c6('0x94')](_[_0x5740c6('0x20')](_0x44a186['query'],_0x1151bf[_0x5740c6('0x94')])),_0x742ac1[_0x5740c6('0x3f')][_0x5740c6('0xae')]=_0x45e6d3['id'],_0x44a186[_0x5740c6('0x7a')]['filter']&&(_0x742ac1[_0x5740c6('0x3f')]=_[_0x5740c6('0x27')](_0x742ac1['where'],{[Op['or']]:_[_0x5740c6('0x70')](_0x742ac1['attributes'],function(_0x18a801){const _0x2a8a65=_0x5740c6,_0x4b0426={};return _0x4b0426[_0x18a801]={[Op[_0x2a8a65('0x4e')]]:'%'+_0x44a186['query'][_0x2a8a65('0x50')]+'%'},_0x4b0426;})})),_0x742ac1=_['merge']({},_0x742ac1,_0x44a186[_0x5740c6('0x64')]),db[_0x5740c6('0x86')][_0x5740c6('0xb')]({'where':_0x742ac1[_0x5740c6('0x3f')]})[_0x5740c6('0x93')](function(_0x1ece9b){const _0x5ae963=_0x5740c6;return _0xc2dea5[_0x5ae963('0xb')]=_0x1ece9b,_0x44a186[_0x5ae963('0x7a')]['includeAll']&&(_0x742ac1['include']=[{'all':!![]}]),db['CannedAnswer'][_0x5ae963('0x4')](_0x742ac1);})[_0x5740c6('0x93')](function(_0x1ac6ba){const _0x2af4f6=_0x5740c6;return _0xc2dea5[_0x2af4f6('0x2e')]=_0x1ac6ba,_0xc2dea5;});})[_0x25cc16('0x93')](respondWithFilteredResult(_0x20f36c,_0x742ac1))[_0x25cc16('0xa2')](handleError(_0x20f36c,null));},exports['removeAnswers']=function(_0xce3cd,_0x177218){const _0x4d8d97=_0xfcc404;return db['FaxAccount'][_0x4d8d97('0x5')]({'where':{'id':_0xce3cd[_0x4d8d97('0x26')]['id']}})[_0x4d8d97('0x93')](handleEntityNotFound(_0x177218,null))[_0x4d8d97('0x93')](function(_0x2a9e46){const _0x5c57e3=_0x4d8d97;if(_0x2a9e46)return _0x2a9e46[_0x5c57e3('0x72')](_0xce3cd[_0x5c57e3('0x7a')][_0x5c57e3('0x7b')]);})[_0x4d8d97('0x93')](respondWithStatusCode(_0x177218,null))[_0x4d8d97('0xa2')](handleError(_0x177218,null));},exports[_0xfcc404('0x17')]=function(_0x1fd1e2,_0x3d94b6){const _0x3312f6=_0xfcc404;return db['FaxInteraction'][_0x3312f6('0x5')]({'where':{'id':_0x1fd1e2['params']['id']}})[_0x3312f6('0x93')](function(_0x6a4b7){const _0x5ef0d8=_0x3312f6;if(_0x6a4b7)return _0x6a4b7[_0x5ef0d8('0x17')](_0x1fd1e2['body'][_0x5ef0d8('0x7b')],{'through':_[_0x5ef0d8('0x92')](_0x1fd1e2[_0x5ef0d8('0x4b')],[_0x5ef0d8('0x7b'),'id'])});})[_0x3312f6('0x93')](respondWithResult(_0x3d94b6,null))[_0x3312f6('0xa2')](handleError(_0x3d94b6,null));},exports[_0xfcc404('0x36')]=function(_0x130315,_0x24d1d8){const _0x2dba5d=_0xfcc404;let _0x4dfb32={'raw':![],'where':{}};const _0x2eb7b8={},_0x38b7ee={'count':0x0,'rows':[]};return db[_0x2dba5d('0x85')]['findOne']({'where':{'id':_0x130315[_0x2dba5d('0x26')]['id']}})['then'](handleEntityNotFound(_0x24d1d8,null))[_0x2dba5d('0x93')](function(_0x1e051c){const _0x291def=_0x2dba5d;if(_0x1e051c)return _0x2eb7b8[_0x291def('0x5e')]=_['keys'](db[_0x291def('0x87')][_0x291def('0x5b')]),_0x2eb7b8[_0x291def('0x7a')]=_[_0x291def('0x1b')](_0x130315[_0x291def('0x7a')]),_0x2eb7b8[_0x291def('0x94')]=_[_0x291def('0x8b')](_0x2eb7b8[_0x291def('0x5e')],_0x2eb7b8[_0x291def('0x7a')]),_0x4dfb32[_0x291def('0x60')]=_['intersection'](_0x2eb7b8[_0x291def('0x5e')],qs[_0x291def('0x5c')](_0x130315['query'][_0x291def('0x5c')])),_0x4dfb32[_0x291def('0x60')]=_0x4dfb32[_0x291def('0x60')][_0x291def('0x42')]?_0x4dfb32['attributes']:_0x2eb7b8['model'],typeof _0x130315[_0x291def('0x7a')][_0x291def('0x9f')]===_0x291def('0x4c')&&(_0x4dfb32[_0x291def('0x8a')]=qs[_0x291def('0x8a')](_0x130315[_0x291def('0x7a')][_0x291def('0x8a')]),_0x4dfb32[_0x291def('0x40')]=qs[_0x291def('0x40')](_0x130315[_0x291def('0x7a')][_0x291def('0x40')])),_0x4dfb32[_0x291def('0x13')]=qs[_0x291def('0x2a')](_0x130315[_0x291def('0x7a')]['sort']),_0x4dfb32[_0x291def('0x3f')]=qs['filters'](_['pick'](_0x130315[_0x291def('0x7a')],_0x2eb7b8[_0x291def('0x94')])),_0x4dfb32['where']['FaxAccountId']=_0x1e051c['id'],_0x130315[_0x291def('0x7a')][_0x291def('0x50')]&&(_0x4dfb32[_0x291def('0x3f')]=_[_0x291def('0x27')](_0x4dfb32[_0x291def('0x3f')],{[Op['or']]:_[_0x291def('0x70')](_0x4dfb32[_0x291def('0x60')],function(_0x11a712){const _0x508b42=_0x291def,_0x210796={};return _0x210796[_0x11a712]={[Op['like']]:'%'+_0x130315['query'][_0x508b42('0x50')]+'%'},_0x210796;})})),_0x4dfb32=_[_0x291def('0x27')]({},_0x4dfb32,_0x130315[_0x291def('0x64')]),db['FaxInteraction'][_0x291def('0xb')]({'where':_0x4dfb32[_0x291def('0x3f')]})['then'](function(_0x52fbda){const _0x300eb8=_0x291def;return _0x38b7ee[_0x300eb8('0xb')]=_0x52fbda,_0x130315[_0x300eb8('0x7a')][_0x300eb8('0x69')]&&(_0x4dfb32[_0x300eb8('0x91')]=[{'model':db['CmContact'],'as':_0x300eb8('0x2c'),'required':![]},{'model':db['User'],'as':_0x300eb8('0x59'),'attributes':['name',_0x300eb8('0x6c'),_0x300eb8('0x51')],'required':![]},{'model':db[_0x300eb8('0x1d')],'as':_0x300eb8('0xd'),'attributes':['id',_0x300eb8('0x4f'),'color'],'where':_0x130315['query'][_0x300eb8('0x8d')]?{'id':_0x130315[_0x300eb8('0x7a')][_0x300eb8('0x8d')]}:undefined,'required':_0x130315[_0x300eb8('0x7a')][_0x300eb8('0x8d')]?!![]:![]}]),db[_0x300eb8('0x87')]['findAll'](_0x4dfb32);})[_0x291def('0x93')](function(_0x512619){const _0x2cd484=_0x291def;return _0x38b7ee[_0x2cd484('0x2e')]=_0x512619,_0x38b7ee;});})[_0x2dba5d('0x93')](respondWithFilteredResult(_0x24d1d8,_0x4dfb32))[_0x2dba5d('0xa2')](handleError(_0x24d1d8,null));},exports[_0xfcc404('0x23')]=function(_0x528809,_0x5a0262){const _0x464088=_0xfcc404;return db[_0x464088('0x85')][_0x464088('0x5')]({'where':{'id':_0x528809['params']['id']}})[_0x464088('0x93')](handleEntityNotFound(_0x5a0262,null))[_0x464088('0x93')](function(_0x2c5cd5){const _0x380282=_0x464088;if(_0x2c5cd5)return db[_0x380282('0xa9')]['transaction'](function(_0x53dc68){const _0x4af6ac=_0x380282;return db[_0x4af6ac('0x65')][_0x4af6ac('0x98')]({'where':{'FaxAccountId':_0x528809[_0x4af6ac('0x26')]['id']},'transaction':_0x53dc68})[_0x4af6ac('0x93')](function(){const _0x18dfd5=_0x4af6ac,_0x1fa354=_['map'](_0x528809[_0x18dfd5('0x4b')],function(_0x29db6f){const _0x17c482=_0x18dfd5;return _0x29db6f['FaxAccountId']=_0x528809[_0x17c482('0x26')]['id'],_0x29db6f;});return db['FaxApplication']['bulkCreate'](_0x1fa354,{'transaction':_0x53dc68});});})[_0x380282('0x93')](function(){const _0x1ea16f=_0x380282;return db[_0x1ea16f('0x65')][_0x1ea16f('0x9')]({'where':{'FaxAccountId':_0x528809[_0x1ea16f('0x26')]['id']},'order':_0x1ea16f('0x45')});});})['then'](respondWithResult(_0x5a0262,null))[_0x464088('0xa2')](handleError(_0x5a0262,null));},exports[_0xfcc404('0x37')]=function(_0x249a78,_0x27e522){const _0x52de5b=_0xfcc404;let _0x25b9ec={};const _0x2b758a={};let _0xb20367,_0x527882;return db[_0x52de5b('0x85')][_0x52de5b('0x5')]({'where':{'id':_0x249a78[_0x52de5b('0x26')]['id']}})[_0x52de5b('0x93')](handleEntityNotFound(_0x27e522,null))[_0x52de5b('0x93')](function(_0x2fcc7a){const _0x263007=_0x52de5b;if(_0x2fcc7a)return _0xb20367=_0x2fcc7a,_0x2b758a[_0x263007('0x5e')]=_['keys'](db['FaxApplication'][_0x263007('0x5b')]),_0x2b758a[_0x263007('0x7a')]=_['keys'](_0x249a78[_0x263007('0x7a')]),_0x2b758a['filters']=_[_0x263007('0x8b')](_0x2b758a[_0x263007('0x5e')],_0x2b758a[_0x263007('0x7a')]),_0x25b9ec[_0x263007('0x60')]=_[_0x263007('0x8b')](_0x2b758a[_0x263007('0x5e')],qs[_0x263007('0x5c')](_0x249a78['query'][_0x263007('0x5c')])),_0x25b9ec['attributes']=_0x25b9ec[_0x263007('0x60')][_0x263007('0x42')]?_0x25b9ec[_0x263007('0x60')]:_0x2b758a['model'],_0x25b9ec[_0x263007('0x13')]=qs[_0x263007('0x2a')](_0x249a78[_0x263007('0x7a')][_0x263007('0x2a')]),_0x25b9ec['where']=qs['filters'](_[_0x263007('0x20')](_0x249a78['query'],_0x2b758a[_0x263007('0x94')])),_0x249a78[_0x263007('0x7a')][_0x263007('0x50')]&&(_0x25b9ec[_0x263007('0x3f')]=_[_0x263007('0x27')](_0x25b9ec['where'],{[Op['or']]:_[_0x263007('0x70')](_0x25b9ec[_0x263007('0x60')],function(_0x3e69bf){const _0x58de9c=_0x263007,_0x34e58d={};return _0x34e58d[_0x3e69bf]={[Op['like']]:'%'+_0x249a78[_0x58de9c('0x7a')][_0x58de9c('0x50')]+'%'},_0x34e58d;})})),_0x25b9ec=_[_0x263007('0x27')]({},_0x25b9ec,_0x249a78['options']),_0xb20367[_0x263007('0x37')](_0x25b9ec);})[_0x52de5b('0x93')](function(_0xeb714b){const _0x2b48b2=_0x52de5b;if(_0xeb714b)return _0x527882=_0xeb714b['length'],typeof _0x249a78[_0x2b48b2('0x7a')]['nolimit']===_0x2b48b2('0x4c')&&(_0x25b9ec[_0x2b48b2('0x8a')]=qs[_0x2b48b2('0x8a')](_0x249a78[_0x2b48b2('0x7a')][_0x2b48b2('0x8a')]),_0x25b9ec[_0x2b48b2('0x40')]=qs[_0x2b48b2('0x40')](_0x249a78['query']['offset'])),_0xb20367[_0x2b48b2('0x37')](_0x25b9ec);})[_0x52de5b('0x93')](function(_0x58fcc6){if(_0x58fcc6)return _0x58fcc6?{'count':_0x527882,'rows':_0x58fcc6}:null;})[_0x52de5b('0x93')](respondWithResult(_0x27e522,null))[_0x52de5b('0xa2')](handleError(_0x27e522,null));};function Extension(_0x2827e4,_0xd60f66,_0x1f786c,_0x5d4a1a){const _0x3c3d76=_0xfcc404;this[_0x3c3d76('0x63')]=_0x3c3d76('0x8c'),this[_0x3c3d76('0x7d')]=_0x2827e4[_0x3c3d76('0x61')],this['app']=_0x5d4a1a,this[_0x3c3d76('0x3d')]=_0x3c3d76('0x52'),this['description']=_0x3c3d76('0x99'),this[_0x3c3d76('0xae')]=_0x2827e4['id'],this['priority']=_0xd60f66,this[_0x3c3d76('0xa3')]=_0x1f786c;}function createExtensionsReciveFax(_0x4c1b99){const _0x4ddce8=_0xfcc404;let _0x4e6b54=0x1;const _0x40fc13=[];_0x40fc13[_0x4ddce8('0x7f')](new Extension(_0x4c1b99,_0x4e6b54,'',_0x4ddce8('0x84'))),_0x4e6b54+=0x1,_0x40fc13['push'](new Extension(_0x4c1b99,_0x4e6b54,_0x4ddce8('0x34'),'Set')),_0x4e6b54+=0x1;for(const _0x2167fe in _0x4c1b99){typeof _0x4c1b99[_0x2167fe]!=='undefined'&&(_0x2167fe===_0x4ddce8('0x15')||_0x2167fe===_0x4ddce8('0x61')||_0x2167fe===_0x4ddce8('0xa1')||_0x2167fe==='faxdetect'||_0x2167fe===_0x4ddce8('0x75')||_0x2167fe===_0x4ddce8('0xe')||_0x2167fe===_0x4ddce8('0x0')||_0x2167fe===_0x4ddce8('0x1e')||_0x2167fe===_0x4ddce8('0xa'))&&(_0x40fc13[_0x4ddce8('0x7f')](new Extension(_0x4c1b99,_0x4e6b54,_0x4ddce8('0x9c')+_0x2167fe+')='+_0x4c1b99[_0x2167fe],'Set')),_0x4e6b54+=0x1);}return _0x40fc13['push'](new Extension(_0x4c1b99,_0x4e6b54,'6','Wait')),_0x4e6b54+=0x1,_0x40fc13['push'](new Extension(_0x4c1b99,_0x4e6b54,_0x4ddce8('0xa6'),_0x4ddce8('0x67'))),_0x4e6b54=0x0,_0x40fc13;}exports[_0xfcc404('0x12')]=function(_0x25a311,_0x9c260b){const _0x4e0ffa=_0xfcc404;let _0x4ac706;return db[_0x4e0ffa('0xa9')][_0x4e0ffa('0x62')](function(_0x421a69){const _0x41816a=_0x4e0ffa;return db[_0x41816a('0x85')]['create'](_0x25a311[_0x41816a('0x4b')],{'transaction':_0x421a69})[_0x41816a('0x93')](function(_0x3eb3da){const _0x55b1c5=_0x41816a;return _0x4ac706=_0x3eb3da[_0x55b1c5('0x55')]({'plain':!![]}),db[_0x55b1c5('0x95')][_0x55b1c5('0x29')](createExtensionsReciveFax(_0x4ac706),{'transaction':_0x421a69});});})[_0x4e0ffa('0x93')](function(){return _0x4ac706;})[_0x4e0ffa('0x93')](respondWithResult(_0x9c260b,null))[_0x4e0ffa('0xa2')](handleError(_0x9c260b,null));},exports['updateAccountApplications']=function(_0x315d22,_0x18c78e){const _0x407d27=_0xfcc404;return db[_0x407d27('0xa9')][_0x407d27('0x62')](function(_0x5a2c44){const _0xf5ca4=_0x407d27;return db[_0xf5ca4('0x85')][_0xf5ca4('0x6f')](_0x315d22[_0xf5ca4('0x4b')],{'where':{'id':_0x315d22['body']['id']},'transaction':_0x5a2c44})[_0xf5ca4('0x93')](function(){const _0x3ec877=_0xf5ca4;return db[_0x3ec877('0x95')]['destroy']({'where':{'FaxAccountId':_0x315d22[_0x3ec877('0x4b')]['id']},'transaction':_0x5a2c44})[_0x3ec877('0x93')](function(){const _0x1edc9a=_0x3ec877;return db[_0x1edc9a('0x95')]['bulkCreate'](createExtensionsReciveFax(_[_0x1edc9a('0x92')](_0x315d22[_0x1edc9a('0x4b')],[_0x1edc9a('0xac'),'key',_0x1edc9a('0xf'),'updatedAt','TrunkId',_0x1edc9a('0xa0')])),{'transaction':_0x5a2c44});});});})[_0x407d27('0x93')](function(){const _0x5ed4bb=_0x407d27;return db[_0x5ed4bb('0x85')][_0x5ed4bb('0x48')](_0x315d22['body']['id']);})[_0x407d27('0x93')](respondWithResult(_0x18c78e,null))[_0x407d27('0xa2')](handleError(_0x18c78e,null));},exports['getMessages']=function(_0x49afcf,_0x24d681){const _0x3753ee=_0xfcc404;let _0x59bf15={'raw':!![],'where':{}};const _0x547ae1={},_0x565fe2={'count':0x0,'rows':[]};return db[_0x3753ee('0x85')][_0x3753ee('0x5')]({'where':{'id':_0x49afcf[_0x3753ee('0x26')]['id']}})[_0x3753ee('0x93')](handleEntityNotFound(_0x24d681,null))['then'](function(_0x3a1a04){const _0x54ccf8=_0x3753ee;if(_0x3a1a04){_0x547ae1['model']=_[_0x54ccf8('0x1b')](db[_0x54ccf8('0x88')][_0x54ccf8('0x5b')]),_0x547ae1[_0x54ccf8('0x7a')]=_['keys'](_0x49afcf[_0x54ccf8('0x7a')]),_0x547ae1[_0x54ccf8('0x94')]=_['intersection'](_0x547ae1[_0x54ccf8('0x5e')],_0x547ae1[_0x54ccf8('0x7a')]),_0x59bf15[_0x54ccf8('0x60')]=_['intersection'](_0x547ae1[_0x54ccf8('0x5e')],qs[_0x54ccf8('0x5c')](_0x49afcf[_0x54ccf8('0x7a')][_0x54ccf8('0x5c')])),_0x59bf15[_0x54ccf8('0x60')]=_0x59bf15[_0x54ccf8('0x60')][_0x54ccf8('0x42')]?_0x59bf15[_0x54ccf8('0x60')]:_0x547ae1[_0x54ccf8('0x5e')];typeof _0x49afcf[_0x54ccf8('0x7a')][_0x54ccf8('0x9f')]===_0x54ccf8('0x4c')&&(_0x59bf15[_0x54ccf8('0x8a')]=qs[_0x54ccf8('0x8a')](_0x49afcf[_0x54ccf8('0x7a')][_0x54ccf8('0x8a')]),_0x59bf15[_0x54ccf8('0x40')]=qs['offset'](_0x49afcf['query'][_0x54ccf8('0x40')]));_0x59bf15[_0x54ccf8('0x13')]=qs[_0x54ccf8('0x2a')](_0x49afcf[_0x54ccf8('0x7a')][_0x54ccf8('0x2a')]),_0x59bf15[_0x54ccf8('0x3f')]=qs[_0x54ccf8('0x94')](_['pick'](_0x49afcf[_0x54ccf8('0x7a')],_0x547ae1[_0x54ccf8('0x94')])),_0x59bf15[_0x54ccf8('0x3f')][_0x54ccf8('0xae')]=_0x3a1a04['id'];_0x49afcf[_0x54ccf8('0x7a')][_0x54ccf8('0x50')]&&(_0x59bf15[_0x54ccf8('0x3f')]=_[_0x54ccf8('0x27')](_0x59bf15[_0x54ccf8('0x3f')],{[Op['or']]:_[_0x54ccf8('0x70')](_0x59bf15[_0x54ccf8('0x60')],function(_0x3f1c12){const _0x4b6662=_0x54ccf8,_0xac2a6={};return _0xac2a6[_0x3f1c12]={[Op[_0x4b6662('0x4e')]]:'%'+_0x49afcf[_0x4b6662('0x7a')]['filter']+'%'},_0xac2a6;})}));if(_0x49afcf[_0x54ccf8('0x7a')]['$gte']){const _0x2a1a35=_0x49afcf[_0x54ccf8('0x7a')][_0x54ccf8('0xa7')][_0x54ccf8('0x7')](','),_0x27d062={};_0x27d062[_0x2a1a35[0x0]]={[Op[_0x54ccf8('0x32')]]:moment(_0x2a1a35[0x1])[_0x54ccf8('0x14')](_0x54ccf8('0x7c'))},_0x59bf15[_0x54ccf8('0x3f')]=_[_0x54ccf8('0x27')](_0x59bf15[_0x54ccf8('0x3f')],_0x27d062);}return _0x59bf15=_[_0x54ccf8('0x27')]({},_0x59bf15,_0x49afcf[_0x54ccf8('0x64')]),db[_0x54ccf8('0x88')][_0x54ccf8('0xb')]({'where':_0x59bf15['where']})[_0x54ccf8('0x93')](function(_0x148856){const _0x116c75=_0x54ccf8;return _0x565fe2[_0x116c75('0xb')]=_0x148856,_0x49afcf[_0x116c75('0x7a')][_0x116c75('0x69')]&&(_0x59bf15[_0x116c75('0x91')]=[{'all':!![]}]),db[_0x116c75('0x88')][_0x116c75('0x4')](_0x59bf15);})['then'](function(_0x175dd3){const _0x131781=_0x54ccf8;return _0x565fe2[_0x131781('0x2e')]=_0x175dd3,_0x565fe2;});}})[_0x3753ee('0x93')](respondWithFilteredResult(_0x24d681,_0x59bf15))['catch'](handleError(_0x24d681,null));},exports[_0xfcc404('0x3a')]=function(_0x3442e6,_0x3ffcf7){const _0x2571a8=_0xfcc404;let _0x31a090,_0xc44ed0;return _0x3442e6[_0x2571a8('0x4b')]['to']&&(_0xc44ed0=_0x3442e6[_0x2571a8('0x4b')]['to'][0x0]),db[_0x2571a8('0x85')]['findOne']({'where':{'id':_0x3442e6[_0x2571a8('0x26')]['id']},'include':[{'model':db[_0x2571a8('0x4a')],'as':'List','include':[{'model':db[_0x2571a8('0xaa')],'as':_0x2571a8('0x6d'),'where':{'fax':_0xc44ed0},'limit':0x1,'order':[[_0x2571a8('0x80'),_0x2571a8('0x6a')]]}]}]})[_0x2571a8('0x93')](handleEntityNotFound(_0x3ffcf7,null))[_0x2571a8('0x93')](function(_0xf1bd88){const _0x424a96=_0x2571a8;_0x31a090=_0xf1bd88;if(_0x3442e6['body'][_0x424a96('0x1a')]&&_0x3442e6[_0x424a96('0x4b')][_0x424a96('0x1a')][_0x424a96('0x42')])for(let _0xad766c=0x0;_0xad766c<_0x3442e6[_0x424a96('0x4b')][_0x424a96('0x1a')][_0x424a96('0x42')];_0xad766c+=0x1){_0x3442e6[_0x424a96('0x4b')][_0x424a96('0x1a')][_0xad766c]={'filename':_0x3442e6[_0x424a96('0x4b')][_0x424a96('0x1a')][_0xad766c]['name'],'id':_0x3442e6[_0x424a96('0x4b')][_0x424a96('0x1a')][_0xad766c]['id'],'path':path[_0x424a96('0x79')](config[_0x424a96('0x5f')],_0x424a96('0x3'),_0x3442e6['body'][_0x424a96('0x1a')][_0xad766c][_0x424a96('0x7e')])};}return respondWithRpcPromise('CheckAfterSend',_0x424a96('0x6e'),{'FaxAccountId':_[_0x424a96('0x83')](_0x3442e6[_0x424a96('0x26')]['id'])?undefined:_0x3442e6[_0x424a96('0x26')]['id'],'path':_[_0x424a96('0x83')](_0x3442e6[_0x424a96('0x4b')]['attachments'][0x0][_0x424a96('0x74')])?undefined:_0x3442e6[_0x424a96('0x4b')][_0x424a96('0x1a')][0x0][_0x424a96('0x74')],'fax':_[_0x424a96('0x83')](_0x3442e6[_0x424a96('0x4b')]['to'][0x0])?undefined:_0x3442e6[_0x424a96('0x4b')]['to'][0x0]},client9002);})['then'](function(){const _0x1d3414=_0x2571a8;if(_0x31a090){_[_0x1d3414('0x83')](_0x3442e6['body'][_0x1d3414('0x1c')])&&(_0x3442e6[_0x1d3414('0x4b')][_0x1d3414('0x1c')]=util[_0x1d3414('0x14')](_0x1d3414('0x68'),_0x31a090[_0x1d3414('0x4f')],_0x31a090[_0x1d3414('0x2f')]));if(_0x31a090[_0x1d3414('0x9d')])return _0x31a090[_0x1d3414('0x9d')][_0x1d3414('0x6d')][_0x1d3414('0x42')]?_0x31a090['List']['Contacts'][0x0]:db[_0x1d3414('0xaa')][_0x1d3414('0x9e')](_[_0x1d3414('0xad')](_0x3442e6[_0x1d3414('0x4b')],{'firstName':_0x3442e6['body']['to'][0x0],'phone':_0x3442e6[_0x1d3414('0x4b')]['to'][0x0],'fax':_0x3442e6[_0x1d3414('0x4b')]['to'][0x0],'ListId':_0x31a090[_0x1d3414('0xa0')]}));else throw new Error(_0x1d3414('0x76'));}else throw new Error('Send\x20Fax\x20failed');})[_0x2571a8('0x93')](function(_0x184e34){const _0x572265=_0x2571a8;if(_0x184e34)return db['FaxInteraction'][_0x572265('0x5')]({'where':{'ContactId':_0x184e34['id'],'closed':![],'FaxAccountId':_0x31a090['id']}})[_0x572265('0x93')](function(_0x4e8e17){const _0x5644cd=_0x572265;if(_0x4e8e17)return[_0x4e8e17,![]];return db[_0x5644cd('0x87')][_0x5644cd('0x9e')]({'UserId':_0x3442e6[_0x5644cd('0x22')]['id'],'ContactId':_0x184e34['id'],'FaxAccountId':_0x31a090['id'],'fax':_0x3442e6[_0x5644cd('0x4b')]['to'][0x0],'firstMsgDirection':_0x5644cd('0x11'),'Messages':[_[_0x5644cd('0x27')](_0x3442e6[_0x5644cd('0x4b')],{'read':![],'body':_0x3442e6[_0x5644cd('0x4b')]['attachments'][0x0][_0x5644cd('0x21')],'FaxAccountId':_0x31a090['id'],'UserId':_0x3442e6['user']['id'],'ContactId':_0x184e34['id'],'AttachmentId':_0x3442e6[_0x5644cd('0x4b')][_0x5644cd('0x1a')][0x0]['id']})]},{'include':[{'model':db[_0x5644cd('0x88')],'as':_0x5644cd('0x5a')}]})['then'](function(_0x302f1a){return[_0x302f1a,!![]];});});else throw new Error(_0x572265('0x19'));})[_0x2571a8('0x93')](function([_0x11b457,_0x4a766a]){const _0x3b9052=_0x2571a8;if(_0x4a766a)return _0x11b457;return db[_0x3b9052('0x88')]['create']({'direction':'out','read':![],'body':_0x3442e6[_0x3b9052('0x4b')][_0x3b9052('0x1a')][0x0][_0x3b9052('0x21')],'FaxAccountId':_0x31a090['id'],'FaxInteractionId':_0x11b457['id'],'UserId':_0x3442e6[_0x3b9052('0x22')]['id'],'ContactId':_0x11b457['ContactId'],'AttachmentId':_0x3442e6['body'][_0x3b9052('0x1a')][0x0]['id']})[_0x3b9052('0x93')](function(_0x213c28){const _0x4731fc=_0x3b9052;return _0x11b457[_0x4731fc('0xa8')][_0x4731fc('0x5a')]=[],_0x11b457[_0x4731fc('0xa8')]['Messages'][_0x4731fc('0x7f')](_0x213c28['dataValues']),_0x11b457;});})['then'](function(_0x1f935f){const _0x3b4e30=_0x2571a8;return respondWithRpcPromise(_0x3b4e30('0x1f'),_0x3b4e30('0x1f'),{'FaxAccountId':_[_0x3b4e30('0x83')](_0x3442e6['params']['id'])?undefined:_0x3442e6[_0x3b4e30('0x26')]['id'],'path':_[_0x3b4e30('0x83')](_0x3442e6[_0x3b4e30('0x4b')]['attachments'][0x0][_0x3b4e30('0x74')])?undefined:_0x3442e6[_0x3b4e30('0x4b')][_0x3b4e30('0x1a')][0x0][_0x3b4e30('0x74')],'fax':_[_0x3b4e30('0x83')](_0x3442e6[_0x3b4e30('0x4b')]['to'][0x0])?undefined:_0x3442e6['body']['to'][0x0],'AttachmentId':_0x3442e6[_0x3b4e30('0x4b')][_0x3b4e30('0x1a')][0x0]['id']},client9002)[_0x3b4e30('0x93')](function(_0x718fff){const _0x5e59bf=_0x3b4e30;logger[_0x5e59bf('0x81')](_0x5e59bf('0xa4'),_0x718fff);})[_0x3b4e30('0xa2')](function(_0x292948){const _0x26bb3b=_0x3b4e30;logger[_0x26bb3b('0x81')](_0x26bb3b('0xa4'),_0x292948);}),_0x1f935f;})[_0x2571a8('0x93')](respondWithResult(_0x3ffcf7,null))[_0x2571a8('0xa2')](handleError(_0x3ffcf7,null));},exports['addAgents']=function(_0xc754a6,_0x3cd86a){const _0x39ed7b=_0xfcc404;return db[_0x39ed7b('0x85')][_0x39ed7b('0x5')]({'where':{'id':_0xc754a6['params']['id']}})[_0x39ed7b('0x93')](function(_0x2ea978){const _0x21b8a2=_0x39ed7b;if(_0x2ea978)return _0x2ea978[_0x21b8a2('0x77')](_0xc754a6[_0x21b8a2('0x4b')]['ids'],{'through':_[_0x21b8a2('0x92')](_0xc754a6[_0x21b8a2('0x4b')],[_0x21b8a2('0x7b'),'id'])})[_0x21b8a2('0x93')](function(_0x1549af){const _0x4e3a6b=_0x21b8a2;for(let _0x411917=0x0;_0x411917<_0xc754a6[_0x4e3a6b('0x4b')][_0x4e3a6b('0x7b')][_0x4e3a6b('0x42')];_0x411917+=0x1){socket[_0x4e3a6b('0x10')](_0x4e3a6b('0x9a'),{'UserId':_0xc754a6[_0x4e3a6b('0x4b')][_0x4e3a6b('0x7b')][_0x411917],'FaxAccountId':_0xc754a6[_0x4e3a6b('0x26')]['id']});}return _0x1549af;});})[_0x39ed7b('0x93')](respondWithResult(_0x3cd86a,null))['catch'](handleError(_0x3cd86a,null));},exports[_0xfcc404('0x89')]=function(_0x27d2cc,_0xa243ed){const _0x450bc0=_0xfcc404;return db[_0x450bc0('0x85')][_0x450bc0('0x5')]({'where':{'id':_0x27d2cc[_0x450bc0('0x26')]['id']}})['then'](handleEntityNotFound(_0xa243ed,null))[_0x450bc0('0x93')](function(_0x1bd8e0){const _0x4a5db4=_0x450bc0;if(_0x1bd8e0)return _0x1bd8e0[_0x4a5db4('0x89')](_0x27d2cc[_0x4a5db4('0x7a')][_0x4a5db4('0x7b')])[_0x4a5db4('0x93')](function(){const _0x5b3687=_0x4a5db4;if(_[_0x5b3687('0x3b')](_0x27d2cc[_0x5b3687('0x7a')]['ids']))for(let _0x5c5295=0x0;_0x5c5295<_0x27d2cc['query'][_0x5b3687('0x7b')][_0x5b3687('0x42')];_0x5c5295+=0x1){socket[_0x5b3687('0x10')](_0x5b3687('0x47'),{'UserId':Number(_0x27d2cc[_0x5b3687('0x7a')][_0x5b3687('0x7b')][_0x5c5295]),'FaxAccountId':Number(_0x27d2cc['params']['id'])});}else socket['emit'](_0x5b3687('0x47'),{'UserId':Number(_0x27d2cc['query']['ids']),'FaxAccountId':Number(_0x27d2cc[_0x5b3687('0x26')]['id'])});});})[_0x450bc0('0x93')](respondWithStatusCode(_0xa243ed,null))['catch'](handleError(_0xa243ed,null));},exports['getAgents']=function(_0x37de8d,_0x5cc525){const _0x5a2ecd=_0xfcc404;let _0x2fc6cd={};const _0x30e462={};let _0x1025eb,_0x4dd491;return db[_0x5a2ecd('0x85')][_0x5a2ecd('0x5')]({'where':{'id':_0x37de8d[_0x5a2ecd('0x26')]['id']}})['then'](handleEntityNotFound(_0x5cc525,null))[_0x5a2ecd('0x93')](function(_0x3b2979){const _0x24296a=_0x5a2ecd;if(_0x3b2979)return _0x1025eb=_0x3b2979,_0x30e462[_0x24296a('0x5e')]=_[_0x24296a('0x1b')](db[_0x24296a('0x2')][_0x24296a('0x5b')]),_0x30e462[_0x24296a('0x7a')]=_[_0x24296a('0x1b')](_0x37de8d[_0x24296a('0x7a')]),_0x30e462[_0x24296a('0x94')]=_[_0x24296a('0x8b')](_0x30e462[_0x24296a('0x5e')],_0x30e462['query']),_0x2fc6cd[_0x24296a('0x60')]=_[_0x24296a('0x8b')](_0x30e462[_0x24296a('0x5e')],qs['fields'](_0x37de8d[_0x24296a('0x7a')]['fields'])),_0x2fc6cd[_0x24296a('0x60')]=_0x2fc6cd[_0x24296a('0x60')]['length']?_0x2fc6cd[_0x24296a('0x60')]:_0x30e462[_0x24296a('0x5e')],_0x2fc6cd[_0x24296a('0x13')]=qs[_0x24296a('0x2a')](_0x37de8d['query']['sort']),_0x2fc6cd[_0x24296a('0x3f')]=qs[_0x24296a('0x94')](_[_0x24296a('0x20')](_0x37de8d[_0x24296a('0x7a')],_0x30e462[_0x24296a('0x94')])),_0x37de8d[_0x24296a('0x7a')][_0x24296a('0x50')]&&(_0x2fc6cd[_0x24296a('0x3f')]=_[_0x24296a('0x27')](_0x2fc6cd['where'],{[Op['or']]:_['map'](_0x2fc6cd[_0x24296a('0x60')],function(_0x1284d9){const _0x2729c2=_0x24296a,_0xeba911={};return _0xeba911[_0x1284d9]={[Op['like']]:'%'+_0x37de8d[_0x2729c2('0x7a')][_0x2729c2('0x50')]+'%'},_0xeba911;})})),_0x2fc6cd=_['merge']({},_0x2fc6cd,_0x37de8d[_0x24296a('0x64')]),_0x1025eb['getAgents'](_0x2fc6cd);})[_0x5a2ecd('0x93')](function(_0x71d177){const _0x427ffa=_0x5a2ecd;if(_0x71d177)return _0x4dd491=_0x71d177[_0x427ffa('0x42')],typeof _0x37de8d[_0x427ffa('0x7a')][_0x427ffa('0x9f')]===_0x427ffa('0x4c')&&(_0x2fc6cd[_0x427ffa('0x8a')]=qs[_0x427ffa('0x8a')](_0x37de8d[_0x427ffa('0x7a')][_0x427ffa('0x8a')]),_0x2fc6cd[_0x427ffa('0x40')]=qs[_0x427ffa('0x40')](_0x37de8d[_0x427ffa('0x7a')]['offset'])),_0x1025eb[_0x427ffa('0x73')](_0x2fc6cd);})['then'](function(_0x5617f0){if(_0x5617f0)return _0x5617f0?{'count':_0x4dd491,'rows':_0x5617f0}:null;})[_0x5a2ecd('0x93')](respondWithResult(_0x5cc525,null))[_0x5a2ecd('0xa2')](handleError(_0x5cc525,null));}; \ No newline at end of file +const a186_0x27b1=['root','isNil','localstationid','split','UserProfileSection','jayson/promise','attributes','CmContact','send','CmList','Messages','get','attachments','FaxAccount,\x20%s,\x20%s','FaxInteraction','faxdetect','body','ListId','model','addAgents','options','count','path','undefined','type','query','from','removeAnswers','dataValues','ids','List','message','tech','ecm','includeAll','register','../../rediscache','context','then','color','format','t38timeout','update','updateAccountApplications','merge','request','code','create','system','basename','fax','key','stack','sendStatus','addDisposition','sort','modem','getApplications','rows','FaxMessage','omit','lodash','exten','result','updatedAt','../../config/environment','FaxAccounts','mandatoryDispositionPause','http','minrate','role','util','Contact\x20not\x20found','VIRTUAL','Contacts','CDR(type)=inbound-fax','$gte','removeDispositions','keys','app','SendFax','tag','userFaxAccount:remove','stringify','bulkCreate','rawAttributes','findAll','length','SendFaxRpc,\x20%s','findAndCountAll','transaction','Set','fullname','emit','filters','nolimit','server/files/attachments','VoiceExtension','catch','addApplications','show','request\x20sent','push','destroy','map','isArray','FaxAccountId','../../config/logger','../../mysqldb','where','FaxAccount','intersection','error','index','Tag','client','./faxAccount.socket','ContactId','Wait','autoAssociation','UserProfileResource','filter','Send\x20Fax\x20failed','debug','DESC','info','ReceiveFax','include','Pause','name','like','join','gateway','CannedAnswer','removeAgents','Owner','filename','gte','describe','out','offset','api','user','limit','getAgents','status','order','sequelize','priority','userProfileId','json','appdata','defaults','User','params','Fax\x20Extension','maxrate','fieldName','from-voip-provider','internal','Disposition','pick','findOne','FaxAccount,\x20%s,\x20%s,\x20%s','FaxApplication','CheckAfterSend','../../components/parsers/qs','userFaxAccount:save','fields','findByPk','addInteraction'];(function(_0x94b1fc,_0x27b1aa){const _0x55f4c0=function(_0x16444e){while(--_0x16444e){_0x94b1fc['push'](_0x94b1fc['shift']());}};_0x55f4c0(++_0x27b1aa);}(a186_0x27b1,0xb6));const a186_0x55f4=function(_0x94b1fc,_0x27b1aa){_0x94b1fc=_0x94b1fc-0x0;let _0x55f4c0=a186_0x27b1[_0x94b1fc];return _0x55f4c0;};const _0x4737e7=a186_0x55f4;'use strict';const moment=require('moment'),util=require(_0x4737e7('0x3c')),path=require(_0x4737e7('0xb')),_=require(_0x4737e7('0x32')),{getSocket}=require(_0x4737e7('0x19')),socket=getSocket(),qs=require(_0x4737e7('0x9b')),logger=require(_0x4737e7('0x60'))(_0x4737e7('0x82')),config=require(_0x4737e7('0x36')),db=require(_0x4737e7('0x61'))['db'],{Op}=require('sequelize');require(_0x4737e7('0x69'))[_0x4737e7('0x18')](socket);const jayson=require(_0x4737e7('0xa5')),client=jayson['client'][_0x4737e7('0x39')]({'port':0x232c}),client9002=jayson[_0x4737e7('0x68')][_0x4737e7('0x39')]({'port':0x232a});function respondWithRpcPromise(_0x16444e,_0x592089,_0x16a96c,_0x8f596b){return new Promise(function(_0x45adb0,_0xb08ea8){const _0x379232=a186_0x55f4,_0x1dbe6f=_0x8f596b||client;return _0x1dbe6f[_0x379232('0x22')](_0x16444e,_0x16a96c)[_0x379232('0x1b')](function(_0x429e51){const _0xd910d3=_0x379232;logger[_0xd910d3('0x72')](_0xd910d3('0x2'),_0x592089,_0xd910d3('0x5a')),logger[_0xd910d3('0x70')](_0xd910d3('0x98'),_0x592089,'request\x20sent',JSON[_0xd910d3('0x48')](_0x429e51));if(_0x429e51[_0xd910d3('0x65')]){if(_0x429e51[_0xd910d3('0x65')][_0xd910d3('0x23')]===0x1f4)return logger[_0xd910d3('0x65')](_0xd910d3('0x2'),_0x592089,_0x429e51[_0xd910d3('0x65')]['message']),_0xb08ea8(_0x429e51['error'][_0xd910d3('0x14')]);return logger[_0xd910d3('0x65')](_0xd910d3('0x2'),_0x592089,_0x429e51['error'][_0xd910d3('0x14')]),_0x45adb0(_0x429e51['error'][_0xd910d3('0x14')]);}else logger[_0xd910d3('0x72')](_0xd910d3('0x2'),_0x592089,_0xd910d3('0x5a')),_0x45adb0(_0x429e51[_0xd910d3('0x34')]['message']);})[_0x379232('0x57')](function(_0x1b8891){const _0x10da11=_0x379232;logger[_0x10da11('0x65')](_0x10da11('0x2'),_0x592089,_0x1b8891),_0xb08ea8(_0x1b8891);});});}function respondWithStatusCode(_0x53a955,_0x395eff){return _0x395eff=_0x395eff||0xcc,function(_0x47be54){const _0x32dfc1=a186_0x55f4;if(_0x47be54)return _0x53a955[_0x32dfc1('0x2a')](_0x395eff);return _0x53a955[_0x32dfc1('0x86')](_0x395eff)['end']();};}function respondWithResult(_0xe761b8,_0x468c22){return _0x468c22=_0x468c22||0xc8,function(_0x2c4586){const _0x3f690e=a186_0x55f4;if(_0x2c4586)return _0xe761b8['status'](_0x468c22)[_0x3f690e('0x8b')](_0x2c4586);};}function respondWithFilteredResult(_0xc5eef3,_0x4ad3f5){return function(_0x514024){const _0x45eede=a186_0x55f4;if(_0x514024){const _0xcebf8e=_0x514024['count'],_0xfc67af=_0x4ad3f5[_0x45eede('0x81')];let _0x1b27ba=_0x4ad3f5[_0x45eede('0x81')]+_0x4ad3f5[_0x45eede('0x84')],_0x1a4b6e;return _0x1b27ba>=_0xcebf8e?(_0x1b27ba=_0xcebf8e,_0x1a4b6e=0xc8):_0x1a4b6e=0xce,_0xc5eef3[_0x45eede('0x86')](_0x1a4b6e),_0xc5eef3['set']('Content-Range',_0xfc67af+'-'+_0x1b27ba+'/'+_0xcebf8e)[_0x45eede('0x8b')](_0x514024);}return null;};}function saveUpdates(_0x5eaeda){return function(_0x9dbf70){const _0x39c927=a186_0x55f4;if(_0x9dbf70)return _0x9dbf70[_0x39c927('0x1f')](_0x5eaeda)[_0x39c927('0x1b')](function(_0x313161){return _0x313161;});return null;};}function removeEntity(_0x490603){return function(_0x237e03){const _0x2a7437=a186_0x55f4;if(_0x237e03)return _0x237e03[_0x2a7437('0x5c')]()[_0x2a7437('0x1b')](function(){const _0x7bdf53=_0x2a7437,_0x118f1d=_0x237e03[_0x7bdf53('0x0')]({'plain':!![]}),_0xaaf569=_0x7bdf53('0x37');return db[_0x7bdf53('0x6d')]['destroy']({'where':{'type':_0xaaf569,'resourceId':_0x118f1d['id']}})[_0x7bdf53('0x1b')](function(){return _0x237e03;});})[_0x2a7437('0x1b')](function(){const _0x4c9ef9=_0x2a7437;_0x490603[_0x4c9ef9('0x86')](0xcc)['end']();});};}function handleEntityNotFound(_0x540f23){return function(_0x206500){return!_0x206500&&_0x540f23['sendStatus'](0x194),_0x206500;};}function handleError(_0x320240,_0x1359be){return _0x1359be=_0x1359be||0x1f4,function(_0x85d355){const _0x4ac653=a186_0x55f4;logger[_0x4ac653('0x65')](_0x85d355[_0x4ac653('0x29')]),_0x85d355[_0x4ac653('0x76')]&&delete _0x85d355[_0x4ac653('0x76')],_0x320240['status'](_0x1359be)[_0x4ac653('0xa8')](_0x85d355);};}exports[_0x4737e7('0x66')]=function(_0x3168a1,_0x261e90){const _0x527ea7=_0x4737e7;let _0x4d6155={'include':[{'model':db[_0x527ea7('0x75')],'as':_0x527ea7('0x38')}]};const _0xa0b430={},_0x22dedd={'count':0x0,'rows':[]},_0x110e53=_[_0x527ea7('0x5d')](db[_0x527ea7('0x63')][_0x527ea7('0x4a')],function(_0x41bceb){const _0x54d0c1=_0x527ea7;return{'name':_0x41bceb[_0x54d0c1('0x92')],'type':_0x41bceb[_0x54d0c1('0xd')][_0x54d0c1('0x28')]};});_0xa0b430['model']=_[_0x527ea7('0x5d')](_0x110e53,_0x527ea7('0x76')),_0xa0b430[_0x527ea7('0xe')]=_['keys'](_0x3168a1[_0x527ea7('0xe')]),_0xa0b430[_0x527ea7('0x53')]=_['intersection'](_0xa0b430[_0x527ea7('0x7')],_0xa0b430[_0x527ea7('0xe')]),_0x4d6155['attributes']=_[_0x527ea7('0x64')](_0xa0b430[_0x527ea7('0x7')],qs[_0x527ea7('0x9d')](_0x3168a1[_0x527ea7('0xe')][_0x527ea7('0x9d')])),_0x4d6155[_0x527ea7('0xa6')]=_0x4d6155[_0x527ea7('0xa6')][_0x527ea7('0x4c')]?_0x4d6155[_0x527ea7('0xa6')]:_0xa0b430[_0x527ea7('0x7')];typeof _0x3168a1[_0x527ea7('0xe')][_0x527ea7('0x54')]===_0x527ea7('0xc')&&(_0x4d6155[_0x527ea7('0x84')]=qs['limit'](_0x3168a1[_0x527ea7('0xe')][_0x527ea7('0x84')]),_0x4d6155['offset']=qs[_0x527ea7('0x81')](_0x3168a1[_0x527ea7('0xe')][_0x527ea7('0x81')]));_0x4d6155[_0x527ea7('0x87')]=qs[_0x527ea7('0x2c')](_0x3168a1[_0x527ea7('0xe')][_0x527ea7('0x2c')]),_0x4d6155[_0x527ea7('0x62')]=qs[_0x527ea7('0x53')](_[_0x527ea7('0x96')](_0x3168a1[_0x527ea7('0xe')],_0xa0b430[_0x527ea7('0x53')]),_0x110e53);_0x3168a1['query'][_0x527ea7('0x6e')]&&(_0x4d6155[_0x527ea7('0x62')]=_['merge'](_0x4d6155[_0x527ea7('0x62')],{[Op['or']]:_[_0x527ea7('0x5d')](_0x110e53,function(_0x2a99bc){const _0x41831b=_0x527ea7;if(_0x2a99bc[_0x41831b('0xd')]!==_0x41831b('0x3e')){const _0x3398f0={};return _0x3398f0[_0x2a99bc[_0x41831b('0x76')]]={[Op['like']]:'%'+_0x3168a1[_0x41831b('0xe')]['filter']+'%'},_0x3398f0;}})}));_0x4d6155=_['merge']({},_0x4d6155,_0x3168a1[_0x527ea7('0x9')]);const _0x59fffd={'where':_0x4d6155[_0x527ea7('0x62')]};return db[_0x527ea7('0x63')]['count'](_0x59fffd)[_0x527ea7('0x1b')](function(_0x19a52d){const _0x2f464b=_0x527ea7;return _0x22dedd[_0x2f464b('0xa')]=_0x19a52d,_0x3168a1['query'][_0x2f464b('0x17')]&&(_0x4d6155['include']=[{'all':!![]}]),db['FaxAccount'][_0x2f464b('0x4b')](_0x4d6155);})[_0x527ea7('0x1b')](function(_0xcb572e){const _0x435ebc=_0x527ea7;return _0x22dedd[_0x435ebc('0x2f')]=_0xcb572e,_0x22dedd;})[_0x527ea7('0x1b')](respondWithFilteredResult(_0x261e90,_0x4d6155))[_0x527ea7('0x57')](handleError(_0x261e90,null));},exports[_0x4737e7('0x59')]=function(_0xb1f3dc,_0x2e4b27){const _0x20e2bb=_0x4737e7;let _0x49105a={'raw':![],'where':{'id':_0xb1f3dc[_0x20e2bb('0x8f')]['id']},'include':[{'model':db[_0x20e2bb('0x75')],'as':_0x20e2bb('0x38')}]};const _0x3c28e9={};return _0x3c28e9[_0x20e2bb('0x7')]=_['keys'](db[_0x20e2bb('0x63')][_0x20e2bb('0x4a')]),_0x3c28e9[_0x20e2bb('0xe')]=_[_0x20e2bb('0x43')](_0xb1f3dc[_0x20e2bb('0xe')]),_0x3c28e9['filters']=_['intersection'](_0x3c28e9[_0x20e2bb('0x7')],_0x3c28e9['query']),_0x49105a[_0x20e2bb('0xa6')]=_['intersection'](_0x3c28e9[_0x20e2bb('0x7')],qs['fields'](_0xb1f3dc[_0x20e2bb('0xe')]['fields'])),_0x49105a[_0x20e2bb('0xa6')]=_0x49105a['attributes']['length']?_0x49105a[_0x20e2bb('0xa6')]:_0x3c28e9[_0x20e2bb('0x7')],_0xb1f3dc[_0x20e2bb('0xe')][_0x20e2bb('0x17')]&&(_0x49105a['include']=[{'all':!![]}]),_0x49105a=_[_0x20e2bb('0x21')]({},_0x49105a,_0xb1f3dc['options']),db[_0x20e2bb('0x63')]['findOne'](_0x49105a)[_0x20e2bb('0x1b')](handleEntityNotFound(_0x2e4b27,null))[_0x20e2bb('0x1b')](respondWithResult(_0x2e4b27,null))[_0x20e2bb('0x57')](handleError(_0x2e4b27,null));},exports[_0x4737e7('0x24')]=function(_0x1a5235,_0x3ceb7f){const _0x1c96b0=_0x4737e7;return db['FaxAccount'][_0x1c96b0('0x24')](_0x1a5235['body'],{})[_0x1c96b0('0x1b')](function(_0x37c2c6){const _0x50e2fd=_0x1c96b0,_0x1a56f1=_0x1a5235[_0x50e2fd('0x83')][_0x50e2fd('0x0')]({'plain':!![]});if(!_0x1a56f1)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x1a56f1[_0x50e2fd('0x3b')]==='user'){const _0x3fc951=_0x37c2c6[_0x50e2fd('0x0')]({'plain':!![]}),_0x8184bf=_0x50e2fd('0x37');return db[_0x50e2fd('0xa4')]['findOne']({'where':{'name':_0x8184bf,'userProfileId':_0x1a56f1[_0x50e2fd('0x8a')]},'raw':!![]})[_0x50e2fd('0x1b')](function(_0x2f8883){const _0xca9db1=_0x50e2fd;return _0x2f8883&&_0x2f8883[_0xca9db1('0x6c')]===0x0?db['UserProfileResource'][_0xca9db1('0x24')]({'name':_0x3fc951[_0xca9db1('0x76')],'resourceId':_0x3fc951['id'],'type':_0x2f8883[_0xca9db1('0x76')],'sectionId':_0x2f8883['id']},{})[_0xca9db1('0x1b')](function(){return _0x37c2c6;}):_0x37c2c6;})[_0x50e2fd('0x57')](function(_0x939f1c){const _0x2d798d=_0x50e2fd;logger[_0x2d798d('0x65')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x939f1c);throw _0x939f1c;});}return _0x37c2c6;})[_0x1c96b0('0x1b')](respondWithResult(_0x3ceb7f,0xc9))['catch'](handleError(_0x3ceb7f,null));},exports['update']=function(_0x2dacd3,_0xa1bb9){const _0x40b787=_0x4737e7;return _0x2dacd3[_0x40b787('0x5')]['id']&&delete _0x2dacd3[_0x40b787('0x5')]['id'],db[_0x40b787('0x63')][_0x40b787('0x97')]({'where':{'id':_0x2dacd3[_0x40b787('0x8f')]['id']},'include':[{'model':db['Pause'],'as':_0x40b787('0x38')}]})[_0x40b787('0x1b')](handleEntityNotFound(_0xa1bb9,null))['then'](saveUpdates(_0x2dacd3[_0x40b787('0x5')],null))[_0x40b787('0x1b')](respondWithResult(_0xa1bb9,null))['catch'](handleError(_0xa1bb9,null));},exports[_0x4737e7('0x5c')]=function(_0x5c2973,_0x2070a7){const _0x41fd72=_0x4737e7;return db[_0x41fd72('0x63')][_0x41fd72('0x97')]({'where':{'id':_0x5c2973['params']['id']}})[_0x41fd72('0x1b')](handleEntityNotFound(_0x2070a7,null))['then'](removeEntity(_0x2070a7,null))[_0x41fd72('0x57')](handleError(_0x2070a7,null));},exports[_0x4737e7('0x7f')]=function(_0x540076,_0x4368df){const _0x9a1107=_0x4737e7;return db['FaxAccount'][_0x9a1107('0x7f')]()['then'](respondWithResult(_0x4368df,null))[_0x9a1107('0x57')](handleError(_0x4368df,null));},exports[_0x4737e7('0x2b')]=function(_0x3fefca,_0x54a3cc){const _0x34b9d4=_0x4737e7;return _0x3fefca[_0x34b9d4('0x5')]['id']&&delete _0x3fefca[_0x34b9d4('0x5')]['id'],db[_0x34b9d4('0x63')][_0x34b9d4('0x97')]({'where':{'id':_0x3fefca[_0x34b9d4('0x8f')]['id']}})[_0x34b9d4('0x1b')](handleEntityNotFound(_0x54a3cc,null))[_0x34b9d4('0x1b')](function(_0xbc6dcd){const _0x3908a3=_0x34b9d4;if(_0xbc6dcd)return _0x3fefca[_0x3908a3('0x5')][_0x3908a3('0x5f')]=_0xbc6dcd['id'],db[_0x3908a3('0x95')][_0x3908a3('0x24')](_0x3fefca[_0x3908a3('0x5')]);})[_0x34b9d4('0x1b')](respondWithResult(_0x54a3cc,null))['catch'](handleError(_0x54a3cc,null));},exports['getDispositions']=function(_0x2e543b,_0x472efb){const _0x43f9e7=_0x4737e7;let _0x375f18={'raw':![],'where':{}};const _0x5743c4={},_0x10ad92={'count':0x0,'rows':[]};return db[_0x43f9e7('0x63')][_0x43f9e7('0x97')]({'where':{'id':_0x2e543b['params']['id']}})[_0x43f9e7('0x1b')](handleEntityNotFound(_0x472efb,null))['then'](function(_0x1ab68e){const _0x4af96f=_0x43f9e7;if(_0x1ab68e)return _0x5743c4[_0x4af96f('0x7')]=_['keys'](db[_0x4af96f('0x95')][_0x4af96f('0x4a')]),_0x5743c4[_0x4af96f('0xe')]=_[_0x4af96f('0x43')](_0x2e543b[_0x4af96f('0xe')]),_0x5743c4['filters']=_[_0x4af96f('0x64')](_0x5743c4[_0x4af96f('0x7')],_0x5743c4['query']),_0x375f18['attributes']=_['intersection'](_0x5743c4[_0x4af96f('0x7')],qs[_0x4af96f('0x9d')](_0x2e543b[_0x4af96f('0xe')][_0x4af96f('0x9d')])),_0x375f18['attributes']=_0x375f18[_0x4af96f('0xa6')][_0x4af96f('0x4c')]?_0x375f18[_0x4af96f('0xa6')]:_0x5743c4[_0x4af96f('0x7')],typeof _0x2e543b[_0x4af96f('0xe')][_0x4af96f('0x54')]===_0x4af96f('0xc')&&(_0x375f18[_0x4af96f('0x84')]=qs[_0x4af96f('0x84')](_0x2e543b[_0x4af96f('0xe')]['limit']),_0x375f18['offset']=qs[_0x4af96f('0x81')](_0x2e543b[_0x4af96f('0xe')]['offset'])),_0x375f18['order']=qs['sort'](_0x2e543b['query'][_0x4af96f('0x2c')]),_0x375f18[_0x4af96f('0x62')]=qs[_0x4af96f('0x53')](_[_0x4af96f('0x96')](_0x2e543b[_0x4af96f('0xe')],_0x5743c4[_0x4af96f('0x53')])),_0x375f18['where'][_0x4af96f('0x5f')]=_0x1ab68e['id'],_0x2e543b[_0x4af96f('0xe')][_0x4af96f('0x6e')]&&(_0x375f18[_0x4af96f('0x62')]=_['merge'](_0x375f18['where'],{[Op['or']]:_[_0x4af96f('0x5d')](_0x375f18[_0x4af96f('0xa6')],function(_0x3de62c){const _0x4aa026=_0x4af96f,_0x58f204={};return _0x58f204[_0x3de62c]={[Op[_0x4aa026('0x77')]]:'%'+_0x2e543b[_0x4aa026('0xe')][_0x4aa026('0x6e')]+'%'},_0x58f204;})})),_0x375f18=_[_0x4af96f('0x21')]({},_0x375f18,_0x2e543b['options']),db['Disposition'][_0x4af96f('0xa')]({'where':_0x375f18[_0x4af96f('0x62')]})[_0x4af96f('0x1b')](function(_0x489640){const _0x4352c2=_0x4af96f;return _0x10ad92[_0x4352c2('0xa')]=_0x489640,_0x2e543b[_0x4352c2('0xe')][_0x4352c2('0x17')]&&(_0x375f18[_0x4352c2('0x74')]=[{'all':!![]}]),db['Disposition'][_0x4352c2('0x4b')](_0x375f18);})['then'](function(_0x546e9){return _0x10ad92['rows']=_0x546e9,_0x10ad92;});})[_0x43f9e7('0x1b')](respondWithFilteredResult(_0x472efb,_0x375f18))['catch'](handleError(_0x472efb,null));},exports[_0x4737e7('0x42')]=function(_0x43fb0e,_0x317df1){const _0x2c4bb0=_0x4737e7;return db[_0x2c4bb0('0x63')][_0x2c4bb0('0x97')]({'where':{'id':_0x43fb0e[_0x2c4bb0('0x8f')]['id']}})[_0x2c4bb0('0x1b')](handleEntityNotFound(_0x317df1,null))[_0x2c4bb0('0x1b')](function(_0xe76d14){const _0xb5aa5a=_0x2c4bb0;if(_0xe76d14)return _0xe76d14[_0xb5aa5a('0x42')](_0x43fb0e[_0xb5aa5a('0xe')][_0xb5aa5a('0x12')]);})[_0x2c4bb0('0x1b')](respondWithStatusCode(_0x317df1,null))[_0x2c4bb0('0x57')](handleError(_0x317df1,null));},exports['addAnswer']=function(_0x453144,_0x5c30a0){const _0x40d757=_0x4737e7;return _0x453144[_0x40d757('0x5')]['id']&&delete _0x453144[_0x40d757('0x5')]['id'],db[_0x40d757('0x63')][_0x40d757('0x97')]({'where':{'id':_0x453144['params']['id']}})['then'](handleEntityNotFound(_0x5c30a0,null))[_0x40d757('0x1b')](function(_0x58e407){const _0x2aca70=_0x40d757;if(_0x58e407)return _0x453144[_0x2aca70('0x5')][_0x2aca70('0x5f')]=_0x58e407['id'],db['CannedAnswer'][_0x2aca70('0x24')](_0x453144[_0x2aca70('0x5')]);})[_0x40d757('0x1b')](respondWithResult(_0x5c30a0,null))[_0x40d757('0x57')](handleError(_0x5c30a0,null));},exports['getAnswers']=function(_0x4bd866,_0x28dadb){const _0x3f97e4=_0x4737e7;let _0x54b6d4={'raw':![],'where':{}};const _0x4dc068={},_0x155282={'count':0x0,'rows':[]};return db[_0x3f97e4('0x63')][_0x3f97e4('0x97')]({'where':{'id':_0x4bd866[_0x3f97e4('0x8f')]['id']}})[_0x3f97e4('0x1b')](handleEntityNotFound(_0x28dadb,null))[_0x3f97e4('0x1b')](function(_0x133ece){const _0x5da55e=_0x3f97e4;if(_0x133ece)return _0x4dc068[_0x5da55e('0x7')]=_[_0x5da55e('0x43')](db[_0x5da55e('0x7a')][_0x5da55e('0x4a')]),_0x4dc068[_0x5da55e('0xe')]=_[_0x5da55e('0x43')](_0x4bd866[_0x5da55e('0xe')]),_0x4dc068[_0x5da55e('0x53')]=_['intersection'](_0x4dc068[_0x5da55e('0x7')],_0x4dc068[_0x5da55e('0xe')]),_0x54b6d4[_0x5da55e('0xa6')]=_['intersection'](_0x4dc068['model'],qs['fields'](_0x4bd866['query'][_0x5da55e('0x9d')])),_0x54b6d4['attributes']=_0x54b6d4[_0x5da55e('0xa6')][_0x5da55e('0x4c')]?_0x54b6d4['attributes']:_0x4dc068[_0x5da55e('0x7')],typeof _0x4bd866['query'][_0x5da55e('0x54')]===_0x5da55e('0xc')&&(_0x54b6d4[_0x5da55e('0x84')]=qs[_0x5da55e('0x84')](_0x4bd866['query']['limit']),_0x54b6d4[_0x5da55e('0x81')]=qs[_0x5da55e('0x81')](_0x4bd866[_0x5da55e('0xe')][_0x5da55e('0x81')])),_0x54b6d4[_0x5da55e('0x87')]=qs['sort'](_0x4bd866['query'][_0x5da55e('0x2c')]),_0x54b6d4[_0x5da55e('0x62')]=qs[_0x5da55e('0x53')](_[_0x5da55e('0x96')](_0x4bd866[_0x5da55e('0xe')],_0x4dc068[_0x5da55e('0x53')])),_0x54b6d4[_0x5da55e('0x62')][_0x5da55e('0x5f')]=_0x133ece['id'],_0x4bd866[_0x5da55e('0xe')][_0x5da55e('0x6e')]&&(_0x54b6d4[_0x5da55e('0x62')]=_[_0x5da55e('0x21')](_0x54b6d4[_0x5da55e('0x62')],{[Op['or']]:_[_0x5da55e('0x5d')](_0x54b6d4[_0x5da55e('0xa6')],function(_0x5e6b1a){const _0x429d45=_0x5da55e,_0x3eaafe={};return _0x3eaafe[_0x5e6b1a]={[Op[_0x429d45('0x77')]]:'%'+_0x4bd866[_0x429d45('0xe')][_0x429d45('0x6e')]+'%'},_0x3eaafe;})})),_0x54b6d4=_[_0x5da55e('0x21')]({},_0x54b6d4,_0x4bd866['options']),db['CannedAnswer'][_0x5da55e('0xa')]({'where':_0x54b6d4[_0x5da55e('0x62')]})['then'](function(_0x5f428e){const _0x5b0984=_0x5da55e;return _0x155282[_0x5b0984('0xa')]=_0x5f428e,_0x4bd866['query']['includeAll']&&(_0x54b6d4['include']=[{'all':!![]}]),db['CannedAnswer'][_0x5b0984('0x4b')](_0x54b6d4);})[_0x5da55e('0x1b')](function(_0x452223){const _0x410532=_0x5da55e;return _0x155282[_0x410532('0x2f')]=_0x452223,_0x155282;});})['then'](respondWithFilteredResult(_0x28dadb,_0x54b6d4))[_0x3f97e4('0x57')](handleError(_0x28dadb,null));},exports[_0x4737e7('0x10')]=function(_0x2bfb34,_0x3d6916){const _0x2980d5=_0x4737e7;return db['FaxAccount'][_0x2980d5('0x97')]({'where':{'id':_0x2bfb34[_0x2980d5('0x8f')]['id']}})['then'](handleEntityNotFound(_0x3d6916,null))[_0x2980d5('0x1b')](function(_0x300d6e){const _0x5dd6b8=_0x2980d5;if(_0x300d6e)return _0x300d6e[_0x5dd6b8('0x10')](_0x2bfb34[_0x5dd6b8('0xe')]['ids']);})['then'](respondWithStatusCode(_0x3d6916,null))['catch'](handleError(_0x3d6916,null));},exports[_0x4737e7('0x9f')]=function(_0x26d89e,_0x2188e6){const _0x5f1eb9=_0x4737e7;return db[_0x5f1eb9('0x3')]['findOne']({'where':{'id':_0x26d89e[_0x5f1eb9('0x8f')]['id']}})[_0x5f1eb9('0x1b')](function(_0x16f92a){const _0x4a11d5=_0x5f1eb9;if(_0x16f92a)return _0x16f92a[_0x4a11d5('0x9f')](_0x26d89e[_0x4a11d5('0x5')][_0x4a11d5('0x12')],{'through':_[_0x4a11d5('0x31')](_0x26d89e[_0x4a11d5('0x5')],[_0x4a11d5('0x12'),'id'])});})[_0x5f1eb9('0x1b')](respondWithResult(_0x2188e6,null))[_0x5f1eb9('0x57')](handleError(_0x2188e6,null));},exports['getInteractions']=function(_0x3b9bf3,_0x32af0b){const _0x44616b=_0x4737e7;let _0x1ff26a={'raw':![],'where':{}};const _0x2b8c13={},_0x59400c={'count':0x0,'rows':[]};return db[_0x44616b('0x63')][_0x44616b('0x97')]({'where':{'id':_0x3b9bf3[_0x44616b('0x8f')]['id']}})[_0x44616b('0x1b')](handleEntityNotFound(_0x32af0b,null))['then'](function(_0x5c05fc){const _0x20f698=_0x44616b;if(_0x5c05fc)return _0x2b8c13[_0x20f698('0x7')]=_[_0x20f698('0x43')](db[_0x20f698('0x3')][_0x20f698('0x4a')]),_0x2b8c13[_0x20f698('0xe')]=_['keys'](_0x3b9bf3[_0x20f698('0xe')]),_0x2b8c13['filters']=_['intersection'](_0x2b8c13[_0x20f698('0x7')],_0x2b8c13['query']),_0x1ff26a['attributes']=_[_0x20f698('0x64')](_0x2b8c13[_0x20f698('0x7')],qs[_0x20f698('0x9d')](_0x3b9bf3[_0x20f698('0xe')][_0x20f698('0x9d')])),_0x1ff26a[_0x20f698('0xa6')]=_0x1ff26a[_0x20f698('0xa6')][_0x20f698('0x4c')]?_0x1ff26a[_0x20f698('0xa6')]:_0x2b8c13[_0x20f698('0x7')],typeof _0x3b9bf3[_0x20f698('0xe')]['nolimit']===_0x20f698('0xc')&&(_0x1ff26a['limit']=qs[_0x20f698('0x84')](_0x3b9bf3['query'][_0x20f698('0x84')]),_0x1ff26a['offset']=qs[_0x20f698('0x81')](_0x3b9bf3['query']['offset'])),_0x1ff26a[_0x20f698('0x87')]=qs['sort'](_0x3b9bf3[_0x20f698('0xe')][_0x20f698('0x2c')]),_0x1ff26a[_0x20f698('0x62')]=qs['filters'](_['pick'](_0x3b9bf3['query'],_0x2b8c13[_0x20f698('0x53')])),_0x1ff26a[_0x20f698('0x62')][_0x20f698('0x5f')]=_0x5c05fc['id'],_0x3b9bf3['query'][_0x20f698('0x6e')]&&(_0x1ff26a[_0x20f698('0x62')]=_[_0x20f698('0x21')](_0x1ff26a[_0x20f698('0x62')],{[Op['or']]:_['map'](_0x1ff26a[_0x20f698('0xa6')],function(_0x1b5170){const _0x147dba=_0x20f698,_0x1da05a={};return _0x1da05a[_0x1b5170]={[Op[_0x147dba('0x77')]]:'%'+_0x3b9bf3[_0x147dba('0xe')]['filter']+'%'},_0x1da05a;})})),_0x1ff26a=_['merge']({},_0x1ff26a,_0x3b9bf3[_0x20f698('0x9')]),db['FaxInteraction'][_0x20f698('0xa')]({'where':_0x1ff26a[_0x20f698('0x62')]})['then'](function(_0x4c9c66){const _0x40a389=_0x20f698;return _0x59400c[_0x40a389('0xa')]=_0x4c9c66,_0x3b9bf3['query'][_0x40a389('0x17')]&&(_0x1ff26a[_0x40a389('0x74')]=[{'model':db[_0x40a389('0xa7')],'as':'Contact','required':![]},{'model':db[_0x40a389('0x8e')],'as':_0x40a389('0x7c'),'attributes':[_0x40a389('0x76'),_0x40a389('0x51'),_0x40a389('0x94')],'required':![]},{'model':db[_0x40a389('0x67')],'as':'Tags','attributes':['id',_0x40a389('0x76'),_0x40a389('0x1c')],'where':_0x3b9bf3[_0x40a389('0xe')][_0x40a389('0x46')]?{'id':_0x3b9bf3[_0x40a389('0xe')][_0x40a389('0x46')]}:undefined,'required':_0x3b9bf3['query'][_0x40a389('0x46')]?!![]:![]}]),db[_0x40a389('0x3')]['findAll'](_0x1ff26a);})[_0x20f698('0x1b')](function(_0x31782a){const _0x30c3ae=_0x20f698;return _0x59400c[_0x30c3ae('0x2f')]=_0x31782a,_0x59400c;});})[_0x44616b('0x1b')](respondWithFilteredResult(_0x32af0b,_0x1ff26a))[_0x44616b('0x57')](handleError(_0x32af0b,null));},exports[_0x4737e7('0x58')]=function(_0x37634d,_0x4b37c6){const _0x50a0d5=_0x4737e7;return db[_0x50a0d5('0x63')][_0x50a0d5('0x97')]({'where':{'id':_0x37634d['params']['id']}})[_0x50a0d5('0x1b')](handleEntityNotFound(_0x4b37c6,null))[_0x50a0d5('0x1b')](function(_0x4ec726){const _0x400c4d=_0x50a0d5;if(_0x4ec726)return db['sequelize'][_0x400c4d('0x4f')](function(_0x944c8){const _0x1eed14=_0x400c4d;return db[_0x1eed14('0x99')][_0x1eed14('0x5c')]({'where':{'FaxAccountId':_0x37634d[_0x1eed14('0x8f')]['id']},'transaction':_0x944c8})[_0x1eed14('0x1b')](function(){const _0x62f176=_0x1eed14,_0x174e2d=_['map'](_0x37634d['body'],function(_0x5990ba){const _0x3b76cb=a186_0x55f4;return _0x5990ba[_0x3b76cb('0x5f')]=_0x37634d[_0x3b76cb('0x8f')]['id'],_0x5990ba;});return db[_0x62f176('0x99')][_0x62f176('0x49')](_0x174e2d,{'transaction':_0x944c8});});})[_0x400c4d('0x1b')](function(){const _0x246bc7=_0x400c4d;return db[_0x246bc7('0x99')][_0x246bc7('0x4e')]({'where':{'FaxAccountId':_0x37634d[_0x246bc7('0x8f')]['id']},'order':_0x246bc7('0x89')});});})[_0x50a0d5('0x1b')](respondWithResult(_0x4b37c6,null))['catch'](handleError(_0x4b37c6,null));},exports[_0x4737e7('0x2e')]=function(_0x175e7d,_0x49e6a9){const _0x5af372=_0x4737e7;let _0x1e4830={};const _0x53c5f1={};let _0x76fc7c,_0x3e6657;return db['FaxAccount'][_0x5af372('0x97')]({'where':{'id':_0x175e7d['params']['id']}})['then'](handleEntityNotFound(_0x49e6a9,null))['then'](function(_0x16e55f){const _0x5a18e4=_0x5af372;if(_0x16e55f)return _0x76fc7c=_0x16e55f,_0x53c5f1[_0x5a18e4('0x7')]=_[_0x5a18e4('0x43')](db['FaxApplication'][_0x5a18e4('0x4a')]),_0x53c5f1[_0x5a18e4('0xe')]=_['keys'](_0x175e7d[_0x5a18e4('0xe')]),_0x53c5f1[_0x5a18e4('0x53')]=_[_0x5a18e4('0x64')](_0x53c5f1[_0x5a18e4('0x7')],_0x53c5f1['query']),_0x1e4830[_0x5a18e4('0xa6')]=_['intersection'](_0x53c5f1[_0x5a18e4('0x7')],qs['fields'](_0x175e7d[_0x5a18e4('0xe')]['fields'])),_0x1e4830[_0x5a18e4('0xa6')]=_0x1e4830[_0x5a18e4('0xa6')][_0x5a18e4('0x4c')]?_0x1e4830[_0x5a18e4('0xa6')]:_0x53c5f1[_0x5a18e4('0x7')],_0x1e4830[_0x5a18e4('0x87')]=qs[_0x5a18e4('0x2c')](_0x175e7d[_0x5a18e4('0xe')][_0x5a18e4('0x2c')]),_0x1e4830[_0x5a18e4('0x62')]=qs['filters'](_['pick'](_0x175e7d[_0x5a18e4('0xe')],_0x53c5f1[_0x5a18e4('0x53')])),_0x175e7d['query'][_0x5a18e4('0x6e')]&&(_0x1e4830[_0x5a18e4('0x62')]=_['merge'](_0x1e4830['where'],{[Op['or']]:_[_0x5a18e4('0x5d')](_0x1e4830[_0x5a18e4('0xa6')],function(_0x10d6ff){const _0x25457f=_0x5a18e4,_0x4dd15d={};return _0x4dd15d[_0x10d6ff]={[Op[_0x25457f('0x77')]]:'%'+_0x175e7d[_0x25457f('0xe')]['filter']+'%'},_0x4dd15d;})})),_0x1e4830=_[_0x5a18e4('0x21')]({},_0x1e4830,_0x175e7d[_0x5a18e4('0x9')]),_0x76fc7c['getApplications'](_0x1e4830);})[_0x5af372('0x1b')](function(_0x29a068){const _0x1ecbdf=_0x5af372;if(_0x29a068)return _0x3e6657=_0x29a068[_0x1ecbdf('0x4c')],typeof _0x175e7d[_0x1ecbdf('0xe')]['nolimit']===_0x1ecbdf('0xc')&&(_0x1e4830[_0x1ecbdf('0x84')]=qs['limit'](_0x175e7d[_0x1ecbdf('0xe')][_0x1ecbdf('0x84')]),_0x1e4830['offset']=qs['offset'](_0x175e7d['query']['offset'])),_0x76fc7c[_0x1ecbdf('0x2e')](_0x1e4830);})['then'](function(_0x1f07e2){if(_0x1f07e2)return _0x1f07e2?{'count':_0x3e6657,'rows':_0x1f07e2}:null;})[_0x5af372('0x1b')](respondWithResult(_0x49e6a9,null))[_0x5af372('0x57')](handleError(_0x49e6a9,null));};function Extension(_0x2f88e1,_0x414f2a,_0x547073,_0x55d60e){const _0x51bba7=_0x4737e7;this[_0x51bba7('0x1a')]=_0x51bba7('0x93'),this[_0x51bba7('0x33')]=_0x2f88e1[_0x51bba7('0xa2')],this[_0x51bba7('0x44')]=_0x55d60e,this[_0x51bba7('0xd')]=_0x51bba7('0x25'),this['description']=_0x51bba7('0x90'),this[_0x51bba7('0x5f')]=_0x2f88e1['id'],this['priority']=_0x414f2a,this[_0x51bba7('0x8c')]=_0x547073;}function createExtensionsReciveFax(_0x202098){const _0x24709b=_0x4737e7;let _0xe9bef6=0x1;const _0x26725f=[];_0x26725f[_0x24709b('0x5b')](new Extension(_0x202098,_0xe9bef6,'','Answer')),_0xe9bef6+=0x1,_0x26725f[_0x24709b('0x5b')](new Extension(_0x202098,_0xe9bef6,_0x24709b('0x40'),'Set')),_0xe9bef6+=0x1;for(const _0x5d1345 in _0x202098){typeof _0x202098[_0x5d1345]!==_0x24709b('0xc')&&(_0x5d1345===_0x24709b('0x16')||_0x5d1345===_0x24709b('0xa2')||_0x5d1345===_0x24709b('0x79')||_0x5d1345===_0x24709b('0x4')||_0x5d1345==='headerinfo'||_0x5d1345===_0x24709b('0x91')||_0x5d1345===_0x24709b('0x3a')||_0x5d1345===_0x24709b('0x2d')||_0x5d1345===_0x24709b('0x1e'))&&(_0x26725f[_0x24709b('0x5b')](new Extension(_0x202098,_0xe9bef6,'FAXOPT('+_0x5d1345+')='+_0x202098[_0x5d1345],_0x24709b('0x50'))),_0xe9bef6+=0x1);}return _0x26725f[_0x24709b('0x5b')](new Extension(_0x202098,_0xe9bef6,'6',_0x24709b('0x6b'))),_0xe9bef6+=0x1,_0x26725f[_0x24709b('0x5b')](new Extension(_0x202098,_0xe9bef6,'/var/opt/motion2/server/files/attachments/fax-${CALLERID(num)}-${CUT(UNIQUEID,.,1)}-${CUT(UNIQUEID,.,2)}-${STRFTIME(,,%C%y%m%d%H%M%S)}-rx.tif,d',_0x24709b('0x73'))),_0xe9bef6=0x0,_0x26725f;}exports['addAccountApplications']=function(_0x314d9e,_0x3f2eeb){const _0x5718ab=_0x4737e7;let _0x1c5d7a;return db[_0x5718ab('0x88')][_0x5718ab('0x4f')](function(_0x56b230){const _0x54c485=_0x5718ab;return db[_0x54c485('0x63')]['create'](_0x314d9e[_0x54c485('0x5')],{'transaction':_0x56b230})['then'](function(_0x5b17a5){const _0x5ef20f=_0x54c485;return _0x1c5d7a=_0x5b17a5[_0x5ef20f('0x0')]({'plain':!![]}),db[_0x5ef20f('0x56')][_0x5ef20f('0x49')](createExtensionsReciveFax(_0x1c5d7a),{'transaction':_0x56b230});});})[_0x5718ab('0x1b')](function(){return _0x1c5d7a;})[_0x5718ab('0x1b')](respondWithResult(_0x3f2eeb,null))[_0x5718ab('0x57')](handleError(_0x3f2eeb,null));},exports[_0x4737e7('0x20')]=function(_0xe0d435,_0x506b8a){const _0x562e68=_0x4737e7;return db[_0x562e68('0x88')][_0x562e68('0x4f')](function(_0x30e4df){const _0x3a22dd=_0x562e68;return db[_0x3a22dd('0x63')][_0x3a22dd('0x1f')](_0xe0d435[_0x3a22dd('0x5')],{'where':{'id':_0xe0d435['body']['id']},'transaction':_0x30e4df})[_0x3a22dd('0x1b')](function(){const _0x429c96=_0x3a22dd;return db[_0x429c96('0x56')][_0x429c96('0x5c')]({'where':{'FaxAccountId':_0xe0d435['body']['id']},'transaction':_0x30e4df})[_0x429c96('0x1b')](function(){const _0x1fc9e5=_0x429c96;return db[_0x1fc9e5('0x56')][_0x1fc9e5('0x49')](createExtensionsReciveFax(_[_0x1fc9e5('0x31')](_0xe0d435['body'],[_0x1fc9e5('0x15'),'key','createdAt','updatedAt','TrunkId',_0x1fc9e5('0x6')])),{'transaction':_0x30e4df});});});})[_0x562e68('0x1b')](function(){const _0x5b8d7e=_0x562e68;return db[_0x5b8d7e('0x63')][_0x5b8d7e('0x9e')](_0xe0d435['body']['id']);})[_0x562e68('0x1b')](respondWithResult(_0x506b8a,null))[_0x562e68('0x57')](handleError(_0x506b8a,null));},exports['getMessages']=function(_0x204db7,_0x5a1bd0){const _0x1e11ba=_0x4737e7;let _0x11a806={'raw':!![],'where':{}};const _0x27812f={},_0x5b568d={'count':0x0,'rows':[]};return db[_0x1e11ba('0x63')][_0x1e11ba('0x97')]({'where':{'id':_0x204db7[_0x1e11ba('0x8f')]['id']}})['then'](handleEntityNotFound(_0x5a1bd0,null))[_0x1e11ba('0x1b')](function(_0x49ec13){const _0x1ab13c=_0x1e11ba;if(_0x49ec13){_0x27812f[_0x1ab13c('0x7')]=_[_0x1ab13c('0x43')](db['FaxMessage'][_0x1ab13c('0x4a')]),_0x27812f['query']=_[_0x1ab13c('0x43')](_0x204db7[_0x1ab13c('0xe')]),_0x27812f['filters']=_[_0x1ab13c('0x64')](_0x27812f[_0x1ab13c('0x7')],_0x27812f[_0x1ab13c('0xe')]),_0x11a806[_0x1ab13c('0xa6')]=_['intersection'](_0x27812f[_0x1ab13c('0x7')],qs[_0x1ab13c('0x9d')](_0x204db7[_0x1ab13c('0xe')][_0x1ab13c('0x9d')])),_0x11a806[_0x1ab13c('0xa6')]=_0x11a806[_0x1ab13c('0xa6')][_0x1ab13c('0x4c')]?_0x11a806[_0x1ab13c('0xa6')]:_0x27812f[_0x1ab13c('0x7')];typeof _0x204db7[_0x1ab13c('0xe')][_0x1ab13c('0x54')]===_0x1ab13c('0xc')&&(_0x11a806[_0x1ab13c('0x84')]=qs[_0x1ab13c('0x84')](_0x204db7[_0x1ab13c('0xe')][_0x1ab13c('0x84')]),_0x11a806[_0x1ab13c('0x81')]=qs[_0x1ab13c('0x81')](_0x204db7[_0x1ab13c('0xe')][_0x1ab13c('0x81')]));_0x11a806['order']=qs[_0x1ab13c('0x2c')](_0x204db7[_0x1ab13c('0xe')][_0x1ab13c('0x2c')]),_0x11a806[_0x1ab13c('0x62')]=qs[_0x1ab13c('0x53')](_[_0x1ab13c('0x96')](_0x204db7[_0x1ab13c('0xe')],_0x27812f[_0x1ab13c('0x53')])),_0x11a806[_0x1ab13c('0x62')][_0x1ab13c('0x5f')]=_0x49ec13['id'];_0x204db7['query']['filter']&&(_0x11a806['where']=_[_0x1ab13c('0x21')](_0x11a806[_0x1ab13c('0x62')],{[Op['or']]:_[_0x1ab13c('0x5d')](_0x11a806[_0x1ab13c('0xa6')],function(_0x277a0d){const _0x477043=_0x1ab13c,_0x1281bb={};return _0x1281bb[_0x277a0d]={[Op[_0x477043('0x77')]]:'%'+_0x204db7[_0x477043('0xe')][_0x477043('0x6e')]+'%'},_0x1281bb;})}));if(_0x204db7[_0x1ab13c('0xe')][_0x1ab13c('0x41')]){const _0x529cd6=_0x204db7['query'][_0x1ab13c('0x41')][_0x1ab13c('0xa3')](','),_0x529bb2={};_0x529bb2[_0x529cd6[0x0]]={[Op[_0x1ab13c('0x7e')]]:moment(_0x529cd6[0x1])[_0x1ab13c('0x1d')]('YYYY-MM-DD\x20HH:mm:ss')},_0x11a806['where']=_[_0x1ab13c('0x21')](_0x11a806[_0x1ab13c('0x62')],_0x529bb2);}return _0x11a806=_[_0x1ab13c('0x21')]({},_0x11a806,_0x204db7['options']),db[_0x1ab13c('0x30')]['count']({'where':_0x11a806[_0x1ab13c('0x62')]})[_0x1ab13c('0x1b')](function(_0x143a17){const _0x5d8bc4=_0x1ab13c;return _0x5b568d[_0x5d8bc4('0xa')]=_0x143a17,_0x204db7['query'][_0x5d8bc4('0x17')]&&(_0x11a806[_0x5d8bc4('0x74')]=[{'all':!![]}]),db[_0x5d8bc4('0x30')]['findAll'](_0x11a806);})[_0x1ab13c('0x1b')](function(_0x2eb8c2){return _0x5b568d['rows']=_0x2eb8c2,_0x5b568d;});}})['then'](respondWithFilteredResult(_0x5a1bd0,_0x11a806))['catch'](handleError(_0x5a1bd0,null));},exports[_0x4737e7('0xa8')]=function(_0x5d422e,_0x4de501){const _0xf0b5e5=_0x4737e7;let _0x9a80d4,_0x5c1260;return _0x5d422e[_0xf0b5e5('0x5')]['to']&&(_0x5c1260=_0x5d422e['body']['to'][0x0]),db[_0xf0b5e5('0x63')][_0xf0b5e5('0x97')]({'where':{'id':_0x5d422e['params']['id']},'include':[{'model':db[_0xf0b5e5('0xa9')],'as':'List','include':[{'model':db[_0xf0b5e5('0xa7')],'as':_0xf0b5e5('0x3f'),'where':{'fax':_0x5c1260},'limit':0x1,'order':[[_0xf0b5e5('0x35'),_0xf0b5e5('0x71')]]}]}]})['then'](handleEntityNotFound(_0x4de501,null))['then'](function(_0x5b0f29){const _0xa8ec22=_0xf0b5e5;_0x9a80d4=_0x5b0f29;if(_0x5d422e[_0xa8ec22('0x5')]['attachments']&&_0x5d422e[_0xa8ec22('0x5')][_0xa8ec22('0x1')]['length'])for(let _0x42fcd7=0x0;_0x42fcd7<_0x5d422e[_0xa8ec22('0x5')][_0xa8ec22('0x1')]['length'];_0x42fcd7+=0x1){_0x5d422e[_0xa8ec22('0x5')][_0xa8ec22('0x1')][_0x42fcd7]={'filename':_0x5d422e[_0xa8ec22('0x5')][_0xa8ec22('0x1')][_0x42fcd7][_0xa8ec22('0x76')],'id':_0x5d422e[_0xa8ec22('0x5')]['attachments'][_0x42fcd7]['id'],'path':path[_0xa8ec22('0x78')](config[_0xa8ec22('0xa0')],_0xa8ec22('0x55'),_0x5d422e['body'][_0xa8ec22('0x1')][_0x42fcd7][_0xa8ec22('0x26')])};}return respondWithRpcPromise(_0xa8ec22('0x9a'),_0xa8ec22('0x9a'),{'FaxAccountId':_[_0xa8ec22('0xa1')](_0x5d422e[_0xa8ec22('0x8f')]['id'])?undefined:_0x5d422e[_0xa8ec22('0x8f')]['id'],'path':_[_0xa8ec22('0xa1')](_0x5d422e[_0xa8ec22('0x5')][_0xa8ec22('0x1')][0x0][_0xa8ec22('0xb')])?undefined:_0x5d422e['body'][_0xa8ec22('0x1')][0x0]['path'],'fax':_[_0xa8ec22('0xa1')](_0x5d422e[_0xa8ec22('0x5')]['to'][0x0])?undefined:_0x5d422e['body']['to'][0x0]},client9002);})[_0xf0b5e5('0x1b')](function(){const _0x24fd54=_0xf0b5e5;if(_0x9a80d4){_[_0x24fd54('0xa1')](_0x5d422e[_0x24fd54('0x5')][_0x24fd54('0xf')])&&(_0x5d422e[_0x24fd54('0x5')]['from']=util['format']('\x22%s\x22\x20<%s>',_0x9a80d4[_0x24fd54('0x76')],_0x9a80d4[_0x24fd54('0x27')]));if(_0x9a80d4[_0x24fd54('0x13')])return _0x9a80d4[_0x24fd54('0x13')]['Contacts'][_0x24fd54('0x4c')]?_0x9a80d4[_0x24fd54('0x13')]['Contacts'][0x0]:db[_0x24fd54('0xa7')][_0x24fd54('0x24')](_[_0x24fd54('0x8d')](_0x5d422e[_0x24fd54('0x5')],{'firstName':_0x5d422e['body']['to'][0x0],'phone':_0x5d422e['body']['to'][0x0],'fax':_0x5d422e[_0x24fd54('0x5')]['to'][0x0],'ListId':_0x9a80d4[_0x24fd54('0x6')]}));else throw new Error('List\x20not\x20found');}else throw new Error(_0x24fd54('0x6f'));})[_0xf0b5e5('0x1b')](function(_0x5282de){const _0x51e1bf=_0xf0b5e5;if(_0x5282de)return db[_0x51e1bf('0x3')][_0x51e1bf('0x97')]({'where':{'ContactId':_0x5282de['id'],'closed':![],'FaxAccountId':_0x9a80d4['id']}})[_0x51e1bf('0x1b')](function(_0x5d9098){const _0x2aaf1b=_0x51e1bf;if(_0x5d9098)return[_0x5d9098,![]];return db['FaxInteraction']['create']({'UserId':_0x5d422e[_0x2aaf1b('0x83')]['id'],'ContactId':_0x5282de['id'],'FaxAccountId':_0x9a80d4['id'],'fax':_0x5d422e[_0x2aaf1b('0x5')]['to'][0x0],'firstMsgDirection':'out','Messages':[_['merge'](_0x5d422e[_0x2aaf1b('0x5')],{'read':![],'body':_0x5d422e[_0x2aaf1b('0x5')][_0x2aaf1b('0x1')][0x0][_0x2aaf1b('0x7d')],'FaxAccountId':_0x9a80d4['id'],'UserId':_0x5d422e[_0x2aaf1b('0x83')]['id'],'ContactId':_0x5282de['id'],'AttachmentId':_0x5d422e[_0x2aaf1b('0x5')]['attachments'][0x0]['id']})]},{'include':[{'model':db[_0x2aaf1b('0x30')],'as':_0x2aaf1b('0xaa')}]})['then'](function(_0x19b270){return[_0x19b270,!![]];});});else throw new Error(_0x51e1bf('0x3d'));})[_0xf0b5e5('0x1b')](function([_0x3f1f79,_0x3071b8]){const _0x5194f7=_0xf0b5e5;if(_0x3071b8)return _0x3f1f79;return db[_0x5194f7('0x30')][_0x5194f7('0x24')]({'direction':_0x5194f7('0x80'),'read':![],'body':_0x5d422e[_0x5194f7('0x5')]['attachments'][0x0][_0x5194f7('0x7d')],'FaxAccountId':_0x9a80d4['id'],'FaxInteractionId':_0x3f1f79['id'],'UserId':_0x5d422e['user']['id'],'ContactId':_0x3f1f79[_0x5194f7('0x6a')],'AttachmentId':_0x5d422e[_0x5194f7('0x5')][_0x5194f7('0x1')][0x0]['id']})[_0x5194f7('0x1b')](function(_0x1e8b3a){const _0x195d97=_0x5194f7;return _0x3f1f79[_0x195d97('0x11')][_0x195d97('0xaa')]=[],_0x3f1f79['dataValues'][_0x195d97('0xaa')][_0x195d97('0x5b')](_0x1e8b3a['dataValues']),_0x3f1f79;});})[_0xf0b5e5('0x1b')](function(_0x1039c6){const _0x2eac8c=_0xf0b5e5;return respondWithRpcPromise(_0x2eac8c('0x45'),_0x2eac8c('0x45'),{'FaxAccountId':_[_0x2eac8c('0xa1')](_0x5d422e[_0x2eac8c('0x8f')]['id'])?undefined:_0x5d422e[_0x2eac8c('0x8f')]['id'],'path':_[_0x2eac8c('0xa1')](_0x5d422e[_0x2eac8c('0x5')][_0x2eac8c('0x1')][0x0][_0x2eac8c('0xb')])?undefined:_0x5d422e[_0x2eac8c('0x5')][_0x2eac8c('0x1')][0x0][_0x2eac8c('0xb')],'fax':_[_0x2eac8c('0xa1')](_0x5d422e[_0x2eac8c('0x5')]['to'][0x0])?undefined:_0x5d422e[_0x2eac8c('0x5')]['to'][0x0],'AttachmentId':_0x5d422e['body'][_0x2eac8c('0x1')][0x0]['id']},client9002)[_0x2eac8c('0x1b')](function(_0x2fe0c5){const _0x36844c=_0x2eac8c;logger[_0x36844c('0x72')](_0x36844c('0x4d'),_0x2fe0c5);})[_0x2eac8c('0x57')](function(_0x367837){const _0x38f7a8=_0x2eac8c;logger[_0x38f7a8('0x72')](_0x38f7a8('0x4d'),_0x367837);}),_0x1039c6;})[_0xf0b5e5('0x1b')](respondWithResult(_0x4de501,null))[_0xf0b5e5('0x57')](handleError(_0x4de501,null));},exports[_0x4737e7('0x8')]=function(_0x714331,_0xb3b228){const _0x5702bd=_0x4737e7;return db['FaxAccount']['findOne']({'where':{'id':_0x714331[_0x5702bd('0x8f')]['id']}})[_0x5702bd('0x1b')](function(_0x3b9bda){const _0x5e3cd8=_0x5702bd;if(_0x3b9bda)return _0x3b9bda[_0x5e3cd8('0x8')](_0x714331['body'][_0x5e3cd8('0x12')],{'through':_[_0x5e3cd8('0x31')](_0x714331[_0x5e3cd8('0x5')],[_0x5e3cd8('0x12'),'id'])})['then'](function(_0x171233){const _0x54abc2=_0x5e3cd8;for(let _0x1ee10c=0x0;_0x1ee10c<_0x714331[_0x54abc2('0x5')][_0x54abc2('0x12')][_0x54abc2('0x4c')];_0x1ee10c+=0x1){socket[_0x54abc2('0x52')](_0x54abc2('0x9c'),{'UserId':_0x714331[_0x54abc2('0x5')][_0x54abc2('0x12')][_0x1ee10c],'FaxAccountId':_0x714331[_0x54abc2('0x8f')]['id']});}return _0x171233;});})['then'](respondWithResult(_0xb3b228,null))[_0x5702bd('0x57')](handleError(_0xb3b228,null));},exports[_0x4737e7('0x7b')]=function(_0x19053a,_0x579275){const _0x1ebcb9=_0x4737e7;return db[_0x1ebcb9('0x63')][_0x1ebcb9('0x97')]({'where':{'id':_0x19053a[_0x1ebcb9('0x8f')]['id']}})[_0x1ebcb9('0x1b')](handleEntityNotFound(_0x579275,null))[_0x1ebcb9('0x1b')](function(_0x40b167){const _0x5bbcc6=_0x1ebcb9;if(_0x40b167)return _0x40b167[_0x5bbcc6('0x7b')](_0x19053a['query'][_0x5bbcc6('0x12')])[_0x5bbcc6('0x1b')](function(){const _0x139159=_0x5bbcc6;if(_[_0x139159('0x5e')](_0x19053a[_0x139159('0xe')][_0x139159('0x12')]))for(let _0x228bf8=0x0;_0x228bf8<_0x19053a[_0x139159('0xe')][_0x139159('0x12')][_0x139159('0x4c')];_0x228bf8+=0x1){socket[_0x139159('0x52')]('userFaxAccount:remove',{'UserId':Number(_0x19053a['query'][_0x139159('0x12')][_0x228bf8]),'FaxAccountId':Number(_0x19053a[_0x139159('0x8f')]['id'])});}else socket[_0x139159('0x52')](_0x139159('0x47'),{'UserId':Number(_0x19053a[_0x139159('0xe')][_0x139159('0x12')]),'FaxAccountId':Number(_0x19053a[_0x139159('0x8f')]['id'])});});})['then'](respondWithStatusCode(_0x579275,null))['catch'](handleError(_0x579275,null));},exports['getAgents']=function(_0x192b37,_0x305095){const _0x2c50da=_0x4737e7;let _0x54caa0={};const _0x1892f0={};let _0x40ad00,_0x47ca16;return db[_0x2c50da('0x63')][_0x2c50da('0x97')]({'where':{'id':_0x192b37['params']['id']}})['then'](handleEntityNotFound(_0x305095,null))[_0x2c50da('0x1b')](function(_0x53329e){const _0x5599d8=_0x2c50da;if(_0x53329e)return _0x40ad00=_0x53329e,_0x1892f0[_0x5599d8('0x7')]=_[_0x5599d8('0x43')](db[_0x5599d8('0x8e')][_0x5599d8('0x4a')]),_0x1892f0[_0x5599d8('0xe')]=_[_0x5599d8('0x43')](_0x192b37['query']),_0x1892f0[_0x5599d8('0x53')]=_[_0x5599d8('0x64')](_0x1892f0['model'],_0x1892f0[_0x5599d8('0xe')]),_0x54caa0[_0x5599d8('0xa6')]=_[_0x5599d8('0x64')](_0x1892f0[_0x5599d8('0x7')],qs['fields'](_0x192b37[_0x5599d8('0xe')][_0x5599d8('0x9d')])),_0x54caa0[_0x5599d8('0xa6')]=_0x54caa0[_0x5599d8('0xa6')][_0x5599d8('0x4c')]?_0x54caa0[_0x5599d8('0xa6')]:_0x1892f0[_0x5599d8('0x7')],_0x54caa0[_0x5599d8('0x87')]=qs[_0x5599d8('0x2c')](_0x192b37[_0x5599d8('0xe')][_0x5599d8('0x2c')]),_0x54caa0[_0x5599d8('0x62')]=qs['filters'](_[_0x5599d8('0x96')](_0x192b37[_0x5599d8('0xe')],_0x1892f0[_0x5599d8('0x53')])),_0x192b37['query'][_0x5599d8('0x6e')]&&(_0x54caa0[_0x5599d8('0x62')]=_[_0x5599d8('0x21')](_0x54caa0['where'],{[Op['or']]:_[_0x5599d8('0x5d')](_0x54caa0['attributes'],function(_0x31ad6e){const _0x469f1f=_0x5599d8,_0x11b903={};return _0x11b903[_0x31ad6e]={[Op[_0x469f1f('0x77')]]:'%'+_0x192b37['query'][_0x469f1f('0x6e')]+'%'},_0x11b903;})})),_0x54caa0=_[_0x5599d8('0x21')]({},_0x54caa0,_0x192b37['options']),_0x40ad00[_0x5599d8('0x85')](_0x54caa0);})[_0x2c50da('0x1b')](function(_0x189406){const _0x3f6f82=_0x2c50da;if(_0x189406)return _0x47ca16=_0x189406[_0x3f6f82('0x4c')],typeof _0x192b37['query'][_0x3f6f82('0x54')]===_0x3f6f82('0xc')&&(_0x54caa0[_0x3f6f82('0x84')]=qs[_0x3f6f82('0x84')](_0x192b37[_0x3f6f82('0xe')][_0x3f6f82('0x84')]),_0x54caa0[_0x3f6f82('0x81')]=qs[_0x3f6f82('0x81')](_0x192b37[_0x3f6f82('0xe')][_0x3f6f82('0x81')])),_0x40ad00[_0x3f6f82('0x85')](_0x54caa0);})[_0x2c50da('0x1b')](function(_0x160724){if(_0x160724)return _0x160724?{'count':_0x47ca16,'rows':_0x160724}:null;})[_0x2c50da('0x1b')](respondWithResult(_0x305095,null))[_0x2c50da('0x57')](handleError(_0x305095,null));}; \ No newline at end of file diff --git a/server/api/faxAccount/faxAccount.events.js b/server/api/faxAccount/faxAccount.events.js index f9c4334..582102b 100644 --- a/server/api/faxAccount/faxAccount.events.js +++ b/server/api/faxAccount/faxAccount.events.js @@ -1 +1 @@ -const a187_0x1fa5=['setMaxListeners','../../mysqldb','emit','update','exports','events','remove','FaxAccount'];(function(_0x2265c3,_0x1fa5d4){const _0x5a9ebd=function(_0x17c0cb){while(--_0x17c0cb){_0x2265c3['push'](_0x2265c3['shift']());}};_0x5a9ebd(++_0x1fa5d4);}(a187_0x1fa5,0x99));const a187_0x5a9e=function(_0x2265c3,_0x1fa5d4){_0x2265c3=_0x2265c3-0x0;let _0x5a9ebd=a187_0x1fa5[_0x2265c3];return _0x5a9ebd;};const _0x2e5f6b=a187_0x5a9e;'use strict';const EventEmitter=require(_0x2e5f6b('0x4')),FaxAccount=require(_0x2e5f6b('0x0'))['db'][_0x2e5f6b('0x6')],FaxAccountEvents=new EventEmitter();FaxAccountEvents[_0x2e5f6b('0x7')](0x0);const events={'afterCreate':'save','afterUpdate':_0x2e5f6b('0x2'),'afterDestroy':_0x2e5f6b('0x5')};function emitEvent(_0x17c0cb){return function(_0x3d9664){const _0x26ea09=a187_0x5a9e;FaxAccountEvents[_0x26ea09('0x1')](_0x17c0cb+':'+_0x3d9664['id'],_0x3d9664),FaxAccountEvents['emit'](_0x17c0cb,_0x3d9664);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];FaxAccount['addHook'](e,emitEvent(event));}}module[_0x2e5f6b('0x3')]=FaxAccountEvents; \ No newline at end of file +const a187_0x27b0=['emit','save','exports','../../mysqldb','setMaxListeners','remove','FaxAccount','undefined','events'];(function(_0x71fe8d,_0x27b074){const _0x28130a=function(_0x4e6ceb){while(--_0x4e6ceb){_0x71fe8d['push'](_0x71fe8d['shift']());}};_0x28130a(++_0x27b074);}(a187_0x27b0,0x129));const a187_0x2813=function(_0x71fe8d,_0x27b074){_0x71fe8d=_0x71fe8d-0x0;let _0x28130a=a187_0x27b0[_0x71fe8d];return _0x28130a;};const _0x4f76b6=a187_0x2813;'use strict';const EventEmitter=require(_0x4f76b6('0x8')),FaxAccount=require(_0x4f76b6('0x3'))['db'][_0x4f76b6('0x6')],FaxAccountEvents=new EventEmitter();FaxAccountEvents[_0x4f76b6('0x4')](0x0);const events={'afterCreate':_0x4f76b6('0x1'),'afterUpdate':'update','afterDestroy':_0x4f76b6('0x5')};function emitEvent(_0x4e6ceb){return function(_0x376c87){const _0x1709d8=a187_0x2813;FaxAccountEvents['emit'](_0x4e6ceb+':'+_0x376c87['id'],_0x376c87),FaxAccountEvents[_0x1709d8('0x0')](_0x4e6ceb,_0x376c87);};}for(const e in events){if(typeof events[e]!==_0x4f76b6('0x7')){const event=events[e];FaxAccount['addHook'](e,emitEvent(event));}}module[_0x4f76b6('0x2')]=FaxAccountEvents; \ No newline at end of file diff --git a/server/api/faxAccount/faxAccount.model.js b/server/api/faxAccount/faxAccount.model.js index 6047a7d..2d397ab 100644 --- a/server/api/faxAccount/faxAccount.model.js +++ b/server/api/faxAccount/faxAccount.model.js @@ -1 +1 @@ -const a188_0x5632=['exports','FaxAccount','define','./faxAccount.attributes','fax_accounts'];(function(_0x3672f9,_0x56325b){const _0x1841ab=function(_0x4a1e08){while(--_0x4a1e08){_0x3672f9['push'](_0x3672f9['shift']());}};_0x1841ab(++_0x56325b);}(a188_0x5632,0xd4));const a188_0x1841=function(_0x3672f9,_0x56325b){_0x3672f9=_0x3672f9-0x0;let _0x1841ab=a188_0x5632[_0x3672f9];return _0x1841ab;};const _0x1405e4=a188_0x1841;'use strict';const attributes=require(_0x1405e4('0x1'));module[_0x1405e4('0x3')]=function(_0x4a1e08){const _0x322448=_0x1405e4,_0x195732=_0x4a1e08[_0x322448('0x0')](_0x322448('0x4'),attributes,{'tableName':_0x322448('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x195732;}; \ No newline at end of file +const a188_0x375d=['define','FaxAccount','exports'];(function(_0x4cf3e9,_0x375d8a){const _0x56ce5b=function(_0x297fc4){while(--_0x297fc4){_0x4cf3e9['push'](_0x4cf3e9['shift']());}};_0x56ce5b(++_0x375d8a);}(a188_0x375d,0x11d));const a188_0x56ce=function(_0x4cf3e9,_0x375d8a){_0x4cf3e9=_0x4cf3e9-0x0;let _0x56ce5b=a188_0x375d[_0x4cf3e9];return _0x56ce5b;};const _0x145416=a188_0x56ce;'use strict';const attributes=require('./faxAccount.attributes');module[_0x145416('0x2')]=function(_0x297fc4){const _0x5c21ec=_0x145416,_0x3fd3bc=_0x297fc4[_0x5c21ec('0x0')](_0x5c21ec('0x1'),attributes,{'tableName':'fax_accounts','paranoid':![],'indexes':[],'timestamps':!![]});return _0x3fd3bc;}; \ No newline at end of file diff --git a/server/api/faxAccount/faxAccount.rpc.js b/server/api/faxAccount/faxAccount.rpc.js index d826f5a..11c42c0 100644 --- a/server/api/faxAccount/faxAccount.rpc.js +++ b/server/api/faxAccount/faxAccount.rpc.js @@ -1 +1 @@ -const a189_0x4189=['startRouting','ContactId','*,*,*,*','includes','limit','../../mysqldb','findAll','body\x20is\x20mandatory\x20and\x20not\x20empty','body','register','keys','then','GetFaxAccount','mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20','findOne','User','../../rediscache','contact','orderBy','fax','Contacts','close','length','catch','account','List','CompanyId','FaxAccount,\x20%s,\x20%s','name','ListId','lodash','error','../../config/logger','result','from\x20is\x20mandatory','describe','FaxInteraction','CmList','interaction','debug','FaxApplication','create','UserId','priority','where','agent','FaxAccount,\x20%s,\x20%s,\x20%s','FaxAccount','raw','Start','FaxMessage','difference','NotifyFaxAccount','push','sequelize','message','applications','attributes','rpc','info','createdAt','from','model','client','stringify','map','CmContact','AttachmentId','request','options','jayson/promise','unshift','Contact\x20not\x20found','updatedAt','Applications','get','isNil','mapKey','./faxAccount.socket','request\x20sent','include','waitForTheAssignedAgent'];(function(_0x6b82c2,_0x41898a){const _0x364a76=function(_0x55cf5d){while(--_0x55cf5d){_0x6b82c2['push'](_0x6b82c2['shift']());}};_0x364a76(++_0x41898a);}(a189_0x4189,0x1c1));const a189_0x364a=function(_0x6b82c2,_0x41898a){_0x6b82c2=_0x6b82c2-0x0;let _0x364a76=a189_0x4189[_0x6b82c2];return _0x364a76;};const _0x58e63c=a189_0x364a;'use strict';const _=require(_0x58e63c('0x49')),db=require(_0x58e63c('0x30'))['db'],{ValidationError}=require(_0x58e63c('0xf')),logger=require(_0x58e63c('0x4b'))(_0x58e63c('0x13')),{getSocket}=require(_0x58e63c('0x3b')),socket=getSocket(),jayson=require(_0x58e63c('0x1f')),client=jayson[_0x58e63c('0x18')]['http']({'port':0x232c});require(_0x58e63c('0x27'))[_0x58e63c('0x34')](socket);function respondWithRpcPromise(_0x55cf5d,_0x1a5a72,_0x45666e){return new Promise(function(_0x4ddec0,_0x10a6be){const _0x52149e=a189_0x364a;return client[_0x52149e('0x1d')](_0x55cf5d,_0x45666e)[_0x52149e('0x36')](function(_0x3a3687){const _0x283c25=_0x52149e;logger[_0x283c25('0x14')](_0x283c25('0x46'),_0x1a5a72,'request\x20sent'),logger[_0x283c25('0x0')](_0x283c25('0x7'),_0x1a5a72,_0x283c25('0x28'),JSON[_0x283c25('0x19')](_0x3a3687));if(_0x3a3687[_0x283c25('0x4a')]){if(_0x3a3687[_0x283c25('0x4a')]['code']===0x1f4)return logger[_0x283c25('0x4a')]('FaxAccount,\x20%s,\x20%s',_0x1a5a72,_0x3a3687['error'][_0x283c25('0x10')]),_0x10a6be(_0x3a3687[_0x283c25('0x4a')]['message']);return logger[_0x283c25('0x4a')]('FaxAccount,\x20%s,\x20%s',_0x1a5a72,_0x3a3687[_0x283c25('0x4a')][_0x283c25('0x10')]),_0x4ddec0(_0x3a3687[_0x283c25('0x4a')][_0x283c25('0x10')]);}else logger[_0x283c25('0x14')](_0x283c25('0x46'),_0x1a5a72,'request\x20sent'),_0x4ddec0(_0x3a3687[_0x283c25('0x4c')][_0x283c25('0x10')]);})[_0x52149e('0x42')](function(_0x3e2870){const _0x1ecadc=_0x52149e;logger[_0x1ecadc('0x4a')](_0x1ecadc('0x46'),_0x1a5a72,_0x3e2870),_0x10a6be(_0x3e2870);});});}exports[_0x58e63c('0x37')]=function(_0x3adbd6){const _0x4cd3c1=this;return new Promise(function(_0x1d9424,_0x589560){const _0x5c2dc7=a189_0x364a;return db[_0x5c2dc7('0x8')][_0x5c2dc7('0x31')]({'raw':_0x3adbd6[_0x5c2dc7('0x1e')]?_0x3adbd6[_0x5c2dc7('0x1e')][_0x5c2dc7('0x9')]===undefined?!![]:![]:!![],'where':_0x3adbd6[_0x5c2dc7('0x1e')]?_0x3adbd6['options'][_0x5c2dc7('0x5')]||null:null,'attributes':_0x3adbd6[_0x5c2dc7('0x1e')]?_0x3adbd6[_0x5c2dc7('0x1e')]['attributes']||null:null,'limit':_0x3adbd6['options']?_0x3adbd6['options'][_0x5c2dc7('0x2f')]||null:null,'include':_0x3adbd6[_0x5c2dc7('0x1e')]?_0x3adbd6[_0x5c2dc7('0x1e')]['include']?_[_0x5c2dc7('0x1a')](_0x3adbd6[_0x5c2dc7('0x1e')][_0x5c2dc7('0x29')],function(_0x154de7){const _0x3ce182=_0x5c2dc7;return{'model':db[_0x154de7[_0x3ce182('0x17')]],'as':_0x154de7['as'],'attributes':_0x154de7['attributes'],'include':_0x154de7[_0x3ce182('0x29')]?_[_0x3ce182('0x1a')](_0x154de7[_0x3ce182('0x29')],function(_0x397784){const _0x18d05c=_0x3ce182;return{'model':db[_0x397784[_0x18d05c('0x17')]],'as':_0x397784['as'],'attributes':_0x397784['attributes'],'include':_0x397784[_0x18d05c('0x29')]?_[_0x18d05c('0x1a')](_0x397784[_0x18d05c('0x29')],function(_0x407e66){const _0x4ac666=_0x18d05c;return{'model':db[_0x407e66[_0x4ac666('0x17')]],'as':_0x407e66['as'],'attributes':_0x407e66[_0x4ac666('0x12')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x2885a2){const _0x55bb6b=_0x5c2dc7;logger[_0x55bb6b('0x14')]('GetFaxAccount',_0x3adbd6),logger[_0x55bb6b('0x0')](_0x55bb6b('0x37'),_0x3adbd6,JSON[_0x55bb6b('0x19')](_0x2885a2)),_0x1d9424(_0x2885a2);})[_0x5c2dc7('0x42')](function(_0x3198aa){const _0x81faae=_0x5c2dc7;logger['error'](_0x81faae('0x37'),_0x3198aa[_0x81faae('0x10')],_0x3adbd6),_0x589560(_0x4cd3c1[_0x81faae('0x4a')](0x1f4,_0x3198aa[_0x81faae('0x10')]));});});},exports[_0x58e63c('0xd')]=function(_0x5cab85){const _0x184a04=this;return new Promise(function(_0x2a773d,_0x12b480){const _0x3ed39f=a189_0x364a,_0x3fcedd={'body':_0x5cab85[_0x3ed39f('0x33')],'channel':_0x3ed39f('0x3e')};let _0x20c6e0=[],_0x1f85f3=[];const _0x5a5373={};return db[_0x3ed39f('0x1b')][_0x3ed39f('0x4e')]()[_0x3ed39f('0x36')](function(_0xcf62a0){const _0x3a9a92=_0x3ed39f;if(!_0xcf62a0)throw new ValidationError('no\x20available\x20attributes');_0x20c6e0=_['difference'](_[_0x3a9a92('0x35')](_0xcf62a0),[_0x3a9a92('0x15'),_0x3a9a92('0x22')]),_0x1f85f3=_[_0x3a9a92('0xc')](_[_0x3a9a92('0x35')](_0xcf62a0),[_0x3a9a92('0x15'),_0x3a9a92('0x22'),_0x3a9a92('0x45'),_0x3a9a92('0x48')]);_0x5cab85[_0x3a9a92('0x33')]['id']&&delete _0x5cab85[_0x3a9a92('0x33')]['id'];if(_[_0x3a9a92('0x25')](_0x5cab85[_0x3a9a92('0x33')][_0x3a9a92('0x16')]))throw new ValidationError(_0x3a9a92('0x4d'));if(_['isNil'](_0x5cab85['body']['body'])||_0x5cab85['body'][_0x3a9a92('0x33')]==='')throw new ValidationError(_0x3a9a92('0x32'));if(_[_0x3a9a92('0x25')](_0x5cab85[_0x3a9a92('0x33')][_0x3a9a92('0x26')]))throw new ValidationError(_0x3a9a92('0x38')+_0x1f85f3);if(!_[_0x3a9a92('0x2e')](_0x1f85f3,_0x5cab85[_0x3a9a92('0x33')][_0x3a9a92('0x26')]))throw new ValidationError('mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20'+_0x1f85f3);_0x5a5373[_0x5cab85[_0x3a9a92('0x33')][_0x3a9a92('0x26')]]=_0x5cab85[_0x3a9a92('0x33')][_0x3a9a92('0x16')];})[_0x3ed39f('0x36')](function(){const _0x39197e=_0x3ed39f;return db[_0x39197e('0x8')][_0x39197e('0x39')]({'where':{'id':_0x5cab85[_0x39197e('0x43')]['id']},'include':[{'model':db[_0x39197e('0x50')],'as':'List','include':[{'model':db[_0x39197e('0x1b')],'as':'Contacts','where':_0x5a5373,'limit':0x1,'order':[['updatedAt','DESC']]}]},{'model':db[_0x39197e('0x1')],'as':'Applications'}]});})[_0x3ed39f('0x36')](function(_0x329325){const _0x3dda8c=_0x3ed39f;if(_0x329325&&_0x329325[_0x3dda8c('0x44')]){const _0x123f3d=_0x329325['get']({'plain':!![]});_0x3fcedd['account']=_0x123f3d,_0x3fcedd[_0x3dda8c('0x11')]=_0x123f3d[_0x3dda8c('0x23')],_0x3fcedd['list']=_0x123f3d['List'],_0x3fcedd[_0x3dda8c('0x11')]=_[_0x3dda8c('0x3d')](_0x3fcedd['applications'],[_0x3dda8c('0x4')],['asc']);_0x3fcedd['account'][_0x3dda8c('0x23')]&&delete _0x3fcedd['account']['Applications'];if(_0x3fcedd[_0x3dda8c('0x43')][_0x3dda8c('0x44')]&&_0x3fcedd[_0x3dda8c('0x43')][_0x3dda8c('0x44')][_0x3dda8c('0x3f')][_0x3dda8c('0x41')])return _0x3fcedd[_0x3dda8c('0x43')][_0x3dda8c('0x44')][_0x3dda8c('0x3f')][0x0];const _0x21f338=_['defaults'](_0x5cab85[_0x3dda8c('0x33')],{'firstName':_0x5cab85[_0x3dda8c('0x33')][_0x3dda8c('0x16')],'ListId':_0x123f3d[_0x3dda8c('0x48')]});return _0x21f338[_0x5cab85['body']['mapKey']]=_0x5cab85[_0x3dda8c('0x33')][_0x3dda8c('0x16')],db['CmContact'][_0x3dda8c('0x2')](_0x21f338,{'fields':_0x20c6e0,'raw':!![]});}})[_0x3ed39f('0x36')](function(_0x56197f){const _0x49e730=_0x3ed39f;_0x3fcedd[_0x49e730('0x3c')]=_0x56197f;if(_0x56197f){const _0x2f879e={'ContactId':_0x56197f['id'],'FaxAccountId':_0x5cab85[_0x49e730('0x43')]['id'],'fax':_0x56197f[_0x49e730('0x3e')]};return db[_0x49e730('0x4f')][_0x49e730('0x39')]({'where':{'ContactId':_0x56197f['id'],'closed':![],'FaxAccountId':_0x5cab85[_0x49e730('0x43')]['id']}})['then'](function(_0x2e3d0f){const _0x43248f=_0x49e730;if(_0x2e3d0f)return[_0x2e3d0f,![]];return db['FaxInteraction']['create'](_0x2f879e)[_0x43248f('0x36')](function(_0x5461d0){return[_0x5461d0,!![]];});});}else throw new Error(_0x49e730('0x21'));})['then'](function([_0x216fbe,_0x595701]){const _0x27e9d6=_0x3ed39f,_0x48cae9=_0x216fbe[_0x27e9d6('0x24')]({'plain':!![]});return _0x595701?(_0x3fcedd[_0x27e9d6('0x43')]['autoclose']&&_0x3fcedd[_0x27e9d6('0x11')][_0x27e9d6('0xe')]({'id':0x0,'priority':_0x3fcedd[_0x27e9d6('0x11')][_0x27e9d6('0x41')]+0x1,'app':_0x27e9d6('0x40'),'appdata':'unmanaged','interval':_0x27e9d6('0x2d')}),_0x48cae9['created']=!![]):_0x48cae9['created']=![],_0x3fcedd[_0x27e9d6('0x51')]=_0x48cae9,db[_0x27e9d6('0xb')]['create']({'body':_0x5cab85['body'][_0x27e9d6('0x33')],'FaxAccountId':_0x5cab85[_0x27e9d6('0x43')]['id'],'FaxInteractionId':_0x216fbe['id'],'direction':'in','ContactId':_0x216fbe[_0x27e9d6('0x2c')],'AttachmentId':_0x5cab85[_0x27e9d6('0x33')][_0x27e9d6('0x1c')]});})[_0x3ed39f('0x36')](function(_0x4511c3){const _0x44f8a6=_0x3ed39f;_0x3fcedd[_0x44f8a6('0x10')]=_0x4511c3;if(_0x3fcedd[_0x44f8a6('0x51')]['UserId'])return db[_0x44f8a6('0x3a')][_0x44f8a6('0x39')]({'attributes':['id',_0x44f8a6('0x47')],'where':{'id':_0x3fcedd[_0x44f8a6('0x51')][_0x44f8a6('0x3')]}})[_0x44f8a6('0x36')](function(_0x5b932d){const _0x6b6dd6=_0x44f8a6;return _0x5b932d&&_0x3fcedd[_0x6b6dd6('0x11')][_0x6b6dd6('0x20')]({'id':0x0,'priority':0x0,'app':_0x6b6dd6('0x6'),'appdata':_0x5b932d['name']+','+(_0x3fcedd[_0x6b6dd6('0x43')][_0x6b6dd6('0x2a')]||0xa),'interval':_0x6b6dd6('0x2d')}),respondWithRpcPromise('Start','startRouting',_0x3fcedd);});return respondWithRpcPromise(_0x44f8a6('0xa'),_0x44f8a6('0x2b'),_0x3fcedd);})[_0x3ed39f('0x36')](function(_0x3537d7){_0x2a773d(_0x3537d7);})['catch'](function(_0x51e2e3){const _0x2b5b65=_0x3ed39f;_0x12b480(_0x184a04['error'](0x1f4,_0x51e2e3[_0x2b5b65('0x10')]));});});}; \ No newline at end of file +const a189_0x3a35=['../../mysqldb','updatedAt','http','mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','applications','priority','waitForTheAssignedAgent','includes','created','request','asc','name','FaxAccount','map','CompanyId','ListId','stringify','rpc','FaxAccount,\x20%s,\x20%s','keys','limit','attributes','interaction','then','jayson/promise','account','agent','from\x20is\x20mandatory','NotifyFaxAccount','difference','findOne','../../config/logger','sequelize','isNil','options','*,*,*,*','UserId','error','get','Contacts','./faxAccount.socket','autoclose','startRouting','client','FaxMessage','Applications','createdAt','register','List','from','unshift','CmContact','fax','message','where','mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20','CmList','model','orderBy','User','info','body','findAll','close','FaxInteraction','Start','GetFaxAccount','request\x20sent','mapKey','length','include','catch','no\x20available\x20attributes','ContactId','create','defaults'];(function(_0x2ac9ae,_0x3a355b){const _0x53b5d1=function(_0x344536){while(--_0x344536){_0x2ac9ae['push'](_0x2ac9ae['shift']());}};_0x53b5d1(++_0x3a355b);}(a189_0x3a35,0xfe));const a189_0x53b5=function(_0x2ac9ae,_0x3a355b){_0x2ac9ae=_0x2ac9ae-0x0;let _0x53b5d1=a189_0x3a35[_0x2ac9ae];return _0x53b5d1;};const _0x397ef7=a189_0x53b5;'use strict';const _=require('lodash'),db=require(_0x397ef7('0x32'))['db'],{ValidationError}=require(_0x397ef7('0x6')),logger=require(_0x397ef7('0x5'))(_0x397ef7('0x43')),{getSocket}=require('../../rediscache'),socket=getSocket(),jayson=require(_0x397ef7('0x4a')),client=jayson[_0x397ef7('0x11')][_0x397ef7('0x34')]({'port':0x232c});require(_0x397ef7('0xe'))[_0x397ef7('0x15')](socket);function respondWithRpcPromise(_0x344536,_0x1ea474,_0x3c514b){return new Promise(function(_0xd03bb7,_0x30e2cf){const _0x1ecb8f=a189_0x53b5;return client[_0x1ecb8f('0x3b')](_0x344536,_0x3c514b)[_0x1ecb8f('0x49')](function(_0x1ca0b9){const _0x42ca5d=_0x1ecb8f;logger[_0x42ca5d('0x22')](_0x42ca5d('0x44'),_0x1ea474,_0x42ca5d('0x29')),logger['debug']('FaxAccount,\x20%s,\x20%s,\x20%s',_0x1ea474,_0x42ca5d('0x29'),JSON[_0x42ca5d('0x42')](_0x1ca0b9));if(_0x1ca0b9[_0x42ca5d('0xb')]){if(_0x1ca0b9['error']['code']===0x1f4)return logger[_0x42ca5d('0xb')](_0x42ca5d('0x44'),_0x1ea474,_0x1ca0b9[_0x42ca5d('0xb')]['message']),_0x30e2cf(_0x1ca0b9[_0x42ca5d('0xb')][_0x42ca5d('0x1b')]);return logger[_0x42ca5d('0xb')]('FaxAccount,\x20%s,\x20%s',_0x1ea474,_0x1ca0b9[_0x42ca5d('0xb')]['message']),_0xd03bb7(_0x1ca0b9['error'][_0x42ca5d('0x1b')]);}else logger[_0x42ca5d('0x22')](_0x42ca5d('0x44'),_0x1ea474,_0x42ca5d('0x29')),_0xd03bb7(_0x1ca0b9['result']['message']);})[_0x1ecb8f('0x2d')](function(_0xf365a2){logger['error']('FaxAccount,\x20%s,\x20%s',_0x1ea474,_0xf365a2),_0x30e2cf(_0xf365a2);});});}exports[_0x397ef7('0x28')]=function(_0x275a13){const _0x20aa57=this;return new Promise(function(_0x369a66,_0x1793cc){const _0x3d8581=a189_0x53b5;return db[_0x3d8581('0x3e')][_0x3d8581('0x24')]({'raw':_0x275a13[_0x3d8581('0x8')]?_0x275a13[_0x3d8581('0x8')]['raw']===undefined?!![]:![]:!![],'where':_0x275a13[_0x3d8581('0x8')]?_0x275a13[_0x3d8581('0x8')][_0x3d8581('0x1c')]||null:null,'attributes':_0x275a13[_0x3d8581('0x8')]?_0x275a13[_0x3d8581('0x8')][_0x3d8581('0x47')]||null:null,'limit':_0x275a13['options']?_0x275a13[_0x3d8581('0x8')][_0x3d8581('0x46')]||null:null,'include':_0x275a13[_0x3d8581('0x8')]?_0x275a13['options'][_0x3d8581('0x2c')]?_[_0x3d8581('0x3f')](_0x275a13[_0x3d8581('0x8')][_0x3d8581('0x2c')],function(_0x48fb5d){const _0x3a213f=_0x3d8581;return{'model':db[_0x48fb5d[_0x3a213f('0x1f')]],'as':_0x48fb5d['as'],'attributes':_0x48fb5d[_0x3a213f('0x47')],'include':_0x48fb5d['include']?_[_0x3a213f('0x3f')](_0x48fb5d['include'],function(_0xea48af){const _0x15953a=_0x3a213f;return{'model':db[_0xea48af[_0x15953a('0x1f')]],'as':_0xea48af['as'],'attributes':_0xea48af[_0x15953a('0x47')],'include':_0xea48af['include']?_['map'](_0xea48af[_0x15953a('0x2c')],function(_0x5a4be1){const _0x3475a5=_0x15953a;return{'model':db[_0x5a4be1[_0x3475a5('0x1f')]],'as':_0x5a4be1['as'],'attributes':_0x5a4be1['attributes']};}):[]};}):[]};}):[]:[]})[_0x3d8581('0x49')](function(_0x2b03e7){const _0x2eecc6=_0x3d8581;logger[_0x2eecc6('0x22')](_0x2eecc6('0x28'),_0x275a13),logger['debug']('GetFaxAccount',_0x275a13,JSON[_0x2eecc6('0x42')](_0x2b03e7)),_0x369a66(_0x2b03e7);})['catch'](function(_0x4d4268){const _0x284bf9=_0x3d8581;logger['error'](_0x284bf9('0x28'),_0x4d4268['message'],_0x275a13),_0x1793cc(_0x20aa57[_0x284bf9('0xb')](0x1f4,_0x4d4268[_0x284bf9('0x1b')]));});});},exports[_0x397ef7('0x2')]=function(_0x13a547){const _0x12b50f=this;return new Promise(function(_0x53a482,_0x3bcc7c){const _0xef2e24=a189_0x53b5,_0x4f683b={'body':_0x13a547['body'],'channel':_0xef2e24('0x1a')};let _0x139a20=[],_0x48589e=[];const _0x29b24b={};return db['CmContact']['describe']()[_0xef2e24('0x49')](function(_0x21b532){const _0x252743=_0xef2e24;if(!_0x21b532)throw new ValidationError(_0x252743('0x2e'));_0x139a20=_[_0x252743('0x3')](_[_0x252743('0x45')](_0x21b532),[_0x252743('0x14'),_0x252743('0x33')]),_0x48589e=_['difference'](_[_0x252743('0x45')](_0x21b532),[_0x252743('0x14'),_0x252743('0x33'),_0x252743('0x40'),'ListId']);_0x13a547[_0x252743('0x23')]['id']&&delete _0x13a547[_0x252743('0x23')]['id'];if(_[_0x252743('0x7')](_0x13a547[_0x252743('0x23')][_0x252743('0x17')]))throw new ValidationError(_0x252743('0x1'));if(_['isNil'](_0x13a547[_0x252743('0x23')][_0x252743('0x23')])||_0x13a547[_0x252743('0x23')]['body']==='')throw new ValidationError('body\x20is\x20mandatory\x20and\x20not\x20empty');if(_['isNil'](_0x13a547[_0x252743('0x23')][_0x252743('0x2a')]))throw new ValidationError(_0x252743('0x1d')+_0x48589e);if(!_[_0x252743('0x39')](_0x48589e,_0x13a547[_0x252743('0x23')][_0x252743('0x2a')]))throw new ValidationError(_0x252743('0x35')+_0x48589e);_0x29b24b[_0x13a547[_0x252743('0x23')][_0x252743('0x2a')]]=_0x13a547['body'][_0x252743('0x17')];})[_0xef2e24('0x49')](function(){const _0xc9d514=_0xef2e24;return db[_0xc9d514('0x3e')]['findOne']({'where':{'id':_0x13a547[_0xc9d514('0x4b')]['id']},'include':[{'model':db[_0xc9d514('0x1e')],'as':'List','include':[{'model':db[_0xc9d514('0x19')],'as':_0xc9d514('0xd'),'where':_0x29b24b,'limit':0x1,'order':[[_0xc9d514('0x33'),'DESC']]}]},{'model':db['FaxApplication'],'as':_0xc9d514('0x13')}]});})[_0xef2e24('0x49')](function(_0x437d75){const _0x4a9a0d=_0xef2e24;if(_0x437d75&&_0x437d75[_0x4a9a0d('0x16')]){const _0x39a00=_0x437d75[_0x4a9a0d('0xc')]({'plain':!![]});_0x4f683b[_0x4a9a0d('0x4b')]=_0x39a00,_0x4f683b[_0x4a9a0d('0x36')]=_0x39a00['Applications'],_0x4f683b['list']=_0x39a00[_0x4a9a0d('0x16')],_0x4f683b[_0x4a9a0d('0x36')]=_[_0x4a9a0d('0x20')](_0x4f683b[_0x4a9a0d('0x36')],[_0x4a9a0d('0x37')],[_0x4a9a0d('0x3c')]);_0x4f683b[_0x4a9a0d('0x4b')]['Applications']&&delete _0x4f683b[_0x4a9a0d('0x4b')]['Applications'];if(_0x4f683b[_0x4a9a0d('0x4b')][_0x4a9a0d('0x16')]&&_0x4f683b['account'][_0x4a9a0d('0x16')][_0x4a9a0d('0xd')][_0x4a9a0d('0x2b')])return _0x4f683b[_0x4a9a0d('0x4b')]['List'][_0x4a9a0d('0xd')][0x0];const _0x3308ad=_[_0x4a9a0d('0x31')](_0x13a547[_0x4a9a0d('0x23')],{'firstName':_0x13a547[_0x4a9a0d('0x23')]['from'],'ListId':_0x39a00[_0x4a9a0d('0x41')]});return _0x3308ad[_0x13a547[_0x4a9a0d('0x23')]['mapKey']]=_0x13a547['body'][_0x4a9a0d('0x17')],db[_0x4a9a0d('0x19')][_0x4a9a0d('0x30')](_0x3308ad,{'fields':_0x139a20,'raw':!![]});}})['then'](function(_0x328ad4){const _0x5d07da=_0xef2e24;_0x4f683b['contact']=_0x328ad4;if(_0x328ad4){const _0x14c6d5={'ContactId':_0x328ad4['id'],'FaxAccountId':_0x13a547[_0x5d07da('0x4b')]['id'],'fax':_0x328ad4[_0x5d07da('0x1a')]};return db[_0x5d07da('0x26')][_0x5d07da('0x4')]({'where':{'ContactId':_0x328ad4['id'],'closed':![],'FaxAccountId':_0x13a547[_0x5d07da('0x4b')]['id']}})[_0x5d07da('0x49')](function(_0x3ff910){const _0x3db104=_0x5d07da;if(_0x3ff910)return[_0x3ff910,![]];return db[_0x3db104('0x26')][_0x3db104('0x30')](_0x14c6d5)[_0x3db104('0x49')](function(_0x200374){return[_0x200374,!![]];});});}else throw new Error('Contact\x20not\x20found');})['then'](function([_0x1b7180,_0x2891c7]){const _0x29eb27=_0xef2e24,_0x59ba4d=_0x1b7180[_0x29eb27('0xc')]({'plain':!![]});return _0x2891c7?(_0x4f683b[_0x29eb27('0x4b')][_0x29eb27('0xf')]&&_0x4f683b[_0x29eb27('0x36')]['push']({'id':0x0,'priority':_0x4f683b[_0x29eb27('0x36')][_0x29eb27('0x2b')]+0x1,'app':_0x29eb27('0x25'),'appdata':'unmanaged','interval':_0x29eb27('0x9')}),_0x59ba4d[_0x29eb27('0x3a')]=!![]):_0x59ba4d[_0x29eb27('0x3a')]=![],_0x4f683b['interaction']=_0x59ba4d,db[_0x29eb27('0x12')][_0x29eb27('0x30')]({'body':_0x13a547[_0x29eb27('0x23')]['body'],'FaxAccountId':_0x13a547[_0x29eb27('0x4b')]['id'],'FaxInteractionId':_0x1b7180['id'],'direction':'in','ContactId':_0x1b7180[_0x29eb27('0x2f')],'AttachmentId':_0x13a547[_0x29eb27('0x23')]['AttachmentId']});})[_0xef2e24('0x49')](function(_0x390e57){const _0x45c6d3=_0xef2e24;_0x4f683b[_0x45c6d3('0x1b')]=_0x390e57;if(_0x4f683b[_0x45c6d3('0x48')][_0x45c6d3('0xa')])return db[_0x45c6d3('0x21')][_0x45c6d3('0x4')]({'attributes':['id',_0x45c6d3('0x3d')],'where':{'id':_0x4f683b[_0x45c6d3('0x48')][_0x45c6d3('0xa')]}})['then'](function(_0x4b4aac){const _0x433996=_0x45c6d3;return _0x4b4aac&&_0x4f683b[_0x433996('0x36')][_0x433996('0x18')]({'id':0x0,'priority':0x0,'app':_0x433996('0x0'),'appdata':_0x4b4aac[_0x433996('0x3d')]+','+(_0x4f683b[_0x433996('0x4b')][_0x433996('0x38')]||0xa),'interval':_0x433996('0x9')}),respondWithRpcPromise(_0x433996('0x27'),_0x433996('0x10'),_0x4f683b);});return respondWithRpcPromise(_0x45c6d3('0x27'),_0x45c6d3('0x10'),_0x4f683b);})[_0xef2e24('0x49')](function(_0x56f7d2){_0x53a482(_0x56f7d2);})[_0xef2e24('0x2d')](function(_0x1b3541){const _0x1d26ca=_0xef2e24;_0x3bcc7c(_0x12b50f[_0x1d26ca('0xb')](0x1f4,_0x1b3541[_0x1d26ca('0x1b')]));});});}; \ No newline at end of file diff --git a/server/api/faxAccount/faxAccount.socket.js b/server/api/faxAccount/faxAccount.socket.js index 2031e10..99156aa 100644 --- a/server/api/faxAccount/faxAccount.socket.js +++ b/server/api/faxAccount/faxAccount.socket.js @@ -1 +1 @@ -const a190_0x3b44=['update','emit','save','./faxAccount.events','length','register','remove','faxAccount:'];(function(_0x2bc6f9,_0x3b44b8){const _0x1c1484=function(_0x52a98f){while(--_0x52a98f){_0x2bc6f9['push'](_0x2bc6f9['shift']());}};_0x1c1484(++_0x3b44b8);}(a190_0x3b44,0x97));const a190_0x1c14=function(_0x2bc6f9,_0x3b44b8){_0x2bc6f9=_0x2bc6f9-0x0;let _0x1c1484=a190_0x3b44[_0x2bc6f9];return _0x1c1484;};const _0x4653ba=a190_0x1c14;'use strict';const FaxAccountEvents=require(_0x4653ba('0x4')),events=[_0x4653ba('0x3'),_0x4653ba('0x7'),_0x4653ba('0x1')];function createListener(_0x52a98f,_0x25df96){return function(_0x62db75){const _0x3a458f=a190_0x1c14;_0x25df96[_0x3a458f('0x2')](_0x52a98f,_0x62db75);};}exports[_0x4653ba('0x6')]=function(_0x15724f){const _0x3e12f2=_0x4653ba;for(let _0x8ba095=0x0,_0x10edb4=events[_0x3e12f2('0x5')];_0x8ba095<_0x10edb4;_0x8ba095++){const _0x337cef=events[_0x8ba095],_0x5b63eb=createListener(_0x3e12f2('0x0')+_0x337cef,_0x15724f);FaxAccountEvents['on'](_0x337cef,_0x5b63eb);}}; \ No newline at end of file +const a190_0x1f89=['save','faxAccount:','emit','register','remove','update'];(function(_0x4e85c7,_0x1f8919){const _0x52f34b=function(_0x3544f9){while(--_0x3544f9){_0x4e85c7['push'](_0x4e85c7['shift']());}};_0x52f34b(++_0x1f8919);}(a190_0x1f89,0x128));const a190_0x52f3=function(_0x4e85c7,_0x1f8919){_0x4e85c7=_0x4e85c7-0x0;let _0x52f34b=a190_0x1f89[_0x4e85c7];return _0x52f34b;};const _0x3a089d=a190_0x52f3;'use strict';const FaxAccountEvents=require('./faxAccount.events'),events=[_0x3a089d('0x4'),_0x3a089d('0x2'),_0x3a089d('0x3')];function createListener(_0x3544f9,_0x3c4c4a){return function(_0x48fe86){const _0x712fbe=a190_0x52f3;_0x3c4c4a[_0x712fbe('0x0')](_0x3544f9,_0x48fe86);};}exports[_0x3a089d('0x1')]=function(_0x3226c0){const _0x3872cf=_0x3a089d;for(let _0x3a85ff=0x0,_0x5bf2ad=events['length'];_0x3a85ff<_0x5bf2ad;_0x3a85ff++){const _0x18f2fa=events[_0x3a85ff],_0x49b946=createListener(_0x3872cf('0x5')+_0x18f2fa,_0x3226c0);FaxAccountEvents['on'](_0x18f2fa,_0x49b946);}}; \ No newline at end of file diff --git a/server/api/faxAccount/index.js b/server/api/faxAccount/index.js index 78fc0fa..c78bdd3 100644 --- a/server/api/faxAccount/index.js +++ b/server/api/faxAccount/index.js @@ -1 +1 @@ -const a191_0x53a4=['describe','/:id/canned_answers','addDisposition','show','/:id/dispositions','Router','addAccountApplications','getDispositions','addInteraction','/:id','put','/:id/applications','getAnswers','post','/:id/send','exports','create','destroy','addAnswer','get','removeAnswers','express','/:id/interactions','index','/:id/users','addApplications','delete','getMessages','addAgents','send','isAuthenticated','/:id/messages'];(function(_0x383026,_0x53a418){const _0x3c2665=function(_0x4b92e1){while(--_0x4b92e1){_0x383026['push'](_0x383026['shift']());}};_0x3c2665(++_0x53a418);}(a191_0x53a4,0x1e6));const a191_0x3c26=function(_0x383026,_0x53a418){_0x383026=_0x383026-0x0;let _0x3c2665=a191_0x53a4[_0x383026];return _0x3c2665;};const _0x35da92=a191_0x3c26;'use strict';const express=require(_0x35da92('0xf')),router=express[_0x35da92('0x1f')](),auth=require('../../components/auth/service'),controller=require('./faxAccount.controller');router[_0x35da92('0xd')]('/',auth['isAuthenticated'](),controller[_0x35da92('0x11')]),router['get']('/describe',auth[_0x35da92('0x18')](),controller[_0x35da92('0x1a')]),router['get'](_0x35da92('0x3'),auth[_0x35da92('0x18')](),controller[_0x35da92('0x1d')]),router['get']('/:id/dispositions',auth[_0x35da92('0x18')](),controller[_0x35da92('0x1')]),router['get'](_0x35da92('0x1b'),auth[_0x35da92('0x18')](),controller[_0x35da92('0x6')]),router['get'](_0x35da92('0x10'),auth['isAuthenticated'](),controller['getInteractions']),router[_0x35da92('0xd')]('/:id/applications',auth['isAuthenticated'](),controller['getApplications']),router['get'](_0x35da92('0x19'),auth[_0x35da92('0x18')](),controller[_0x35da92('0x15')]),router[_0x35da92('0xd')](_0x35da92('0x12'),auth[_0x35da92('0x18')](),controller['getAgents']),router[_0x35da92('0x7')]('/',auth[_0x35da92('0x18')](),controller[_0x35da92('0xa')]),router[_0x35da92('0x7')](_0x35da92('0x1e'),auth['isAuthenticated'](),controller[_0x35da92('0x1c')]),router[_0x35da92('0x7')](_0x35da92('0x1b'),auth[_0x35da92('0x18')](),controller[_0x35da92('0xc')]),router[_0x35da92('0x7')](_0x35da92('0x10'),auth[_0x35da92('0x18')](),controller[_0x35da92('0x2')]),router[_0x35da92('0x7')](_0x35da92('0x5'),auth[_0x35da92('0x18')](),controller[_0x35da92('0x13')]),router[_0x35da92('0x7')]('/addaccountapplications',auth[_0x35da92('0x18')](),controller[_0x35da92('0x0')]),router['post']('/updateaccountapplications',auth[_0x35da92('0x18')](),controller['updateAccountApplications']),router['post'](_0x35da92('0x8'),auth[_0x35da92('0x18')](),controller[_0x35da92('0x17')]),router[_0x35da92('0x7')]('/:id/users',auth[_0x35da92('0x18')](),controller[_0x35da92('0x16')]),router[_0x35da92('0x4')](_0x35da92('0x3'),auth[_0x35da92('0x18')](),controller['update']),router['delete'](_0x35da92('0x3'),auth[_0x35da92('0x18')](),controller[_0x35da92('0xb')]),router['delete']('/:id/dispositions',auth[_0x35da92('0x18')](),controller['removeDispositions']),router[_0x35da92('0x14')](_0x35da92('0x1b'),auth[_0x35da92('0x18')](),controller[_0x35da92('0xe')]),router['delete']('/:id/users',auth[_0x35da92('0x18')](),controller['removeAgents']),module[_0x35da92('0x9')]=router; \ No newline at end of file +const a191_0x2561=['index','/:id/messages','../../components/auth/service','removeAgents','destroy','getMessages','send','/:id/applications','addAgents','/:id/send','exports','update','describe','/:id/canned_answers','isAuthenticated','getAgents','getAnswers','./faxAccount.controller','/addaccountapplications','getInteractions','/:id/dispositions','Router','/describe','get','show','getApplications','addApplications','/:id/interactions','delete','removeAnswers','post','addAnswer','/:id/users','addInteraction','/updateaccountapplications','addDisposition'];(function(_0x47a3cd,_0x256143){const _0x1e5565=function(_0x492aa4){while(--_0x492aa4){_0x47a3cd['push'](_0x47a3cd['shift']());}};_0x1e5565(++_0x256143);}(a191_0x2561,0xe0));const a191_0x1e55=function(_0x47a3cd,_0x256143){_0x47a3cd=_0x47a3cd-0x0;let _0x1e5565=a191_0x2561[_0x47a3cd];return _0x1e5565;};const _0x21656c=a191_0x1e55;'use strict';const express=require('express'),router=express[_0x21656c('0xd')](),auth=require(_0x21656c('0x1e')),controller=require(_0x21656c('0x9'));router['get']('/',auth[_0x21656c('0x6')](),controller[_0x21656c('0x1c')]),router['get'](_0x21656c('0xe'),auth[_0x21656c('0x6')](),controller[_0x21656c('0x4')]),router[_0x21656c('0xf')]('/:id',auth[_0x21656c('0x6')](),controller[_0x21656c('0x10')]),router[_0x21656c('0xf')]('/:id/dispositions',auth['isAuthenticated'](),controller['getDispositions']),router[_0x21656c('0xf')]('/:id/canned_answers',auth[_0x21656c('0x6')](),controller[_0x21656c('0x8')]),router[_0x21656c('0xf')](_0x21656c('0x13'),auth[_0x21656c('0x6')](),controller[_0x21656c('0xb')]),router[_0x21656c('0xf')](_0x21656c('0x23'),auth[_0x21656c('0x6')](),controller[_0x21656c('0x11')]),router[_0x21656c('0xf')](_0x21656c('0x1d'),auth[_0x21656c('0x6')](),controller[_0x21656c('0x21')]),router[_0x21656c('0xf')]('/:id/users',auth[_0x21656c('0x6')](),controller[_0x21656c('0x7')]),router[_0x21656c('0x16')]('/',auth[_0x21656c('0x6')](),controller['create']),router['post'](_0x21656c('0xc'),auth[_0x21656c('0x6')](),controller[_0x21656c('0x1b')]),router[_0x21656c('0x16')](_0x21656c('0x5'),auth[_0x21656c('0x6')](),controller[_0x21656c('0x17')]),router['post']('/:id/interactions',auth[_0x21656c('0x6')](),controller[_0x21656c('0x19')]),router[_0x21656c('0x16')]('/:id/applications',auth[_0x21656c('0x6')](),controller[_0x21656c('0x12')]),router[_0x21656c('0x16')](_0x21656c('0xa'),auth[_0x21656c('0x6')](),controller['addAccountApplications']),router['post'](_0x21656c('0x1a'),auth[_0x21656c('0x6')](),controller['updateAccountApplications']),router[_0x21656c('0x16')](_0x21656c('0x1'),auth['isAuthenticated'](),controller[_0x21656c('0x22')]),router[_0x21656c('0x16')](_0x21656c('0x18'),auth['isAuthenticated'](),controller[_0x21656c('0x0')]),router['put']('/:id',auth[_0x21656c('0x6')](),controller[_0x21656c('0x3')]),router[_0x21656c('0x14')]('/:id',auth['isAuthenticated'](),controller[_0x21656c('0x20')]),router[_0x21656c('0x14')](_0x21656c('0xc'),auth[_0x21656c('0x6')](),controller['removeDispositions']),router[_0x21656c('0x14')](_0x21656c('0x5'),auth[_0x21656c('0x6')](),controller[_0x21656c('0x15')]),router[_0x21656c('0x14')]('/:id/users',auth[_0x21656c('0x6')](),controller[_0x21656c('0x1f')]),module[_0x21656c('0x2')]=router; \ No newline at end of file diff --git a/server/api/faxApplication/faxApplication.attributes.js b/server/api/faxApplication/faxApplication.attributes.js index 7573e0c..f5b4f24 100644 --- a/server/api/faxApplication/faxApplication.attributes.js +++ b/server/api/faxApplication/faxApplication.attributes.js @@ -1 +1 @@ -const a192_0x1a45=['noop','*,*,*,*','STRING','exports','TEXT','sequelize'];(function(_0x535e71,_0x1a454f){const _0x147841=function(_0x1d2308){while(--_0x1d2308){_0x535e71['push'](_0x535e71['shift']());}};_0x147841(++_0x1a454f);}(a192_0x1a45,0x75));const a192_0x1478=function(_0x535e71,_0x1a454f){_0x535e71=_0x535e71-0x0;let _0x147841=a192_0x1a45[_0x535e71];return _0x147841;};const _0x57ea0c=a192_0x1478;'use strict';const Sequelize=require(_0x57ea0c('0x2'));module[_0x57ea0c('0x0')]={'priority':{'type':Sequelize['INTEGER'],'allowNull':![]},'app':{'type':Sequelize[_0x57ea0c('0x5')],'allowNull':![],'defaultValue':_0x57ea0c('0x3')},'appdata':{'type':Sequelize[_0x57ea0c('0x1')]()},'description':{'type':Sequelize[_0x57ea0c('0x5')]},'interval':{'type':Sequelize[_0x57ea0c('0x5')],'defaultValue':_0x57ea0c('0x4')}}; \ No newline at end of file +const a192_0x2847=['INTEGER','exports','noop','*,*,*,*','sequelize','STRING'];(function(_0x31fc57,_0x28478b){const _0x4da1f7=function(_0x4603c2){while(--_0x4603c2){_0x31fc57['push'](_0x31fc57['shift']());}};_0x4da1f7(++_0x28478b);}(a192_0x2847,0x13a));const a192_0x4da1=function(_0x31fc57,_0x28478b){_0x31fc57=_0x31fc57-0x0;let _0x4da1f7=a192_0x2847[_0x31fc57];return _0x4da1f7;};const _0x55ef09=a192_0x4da1;'use strict';const Sequelize=require(_0x55ef09('0x2'));module[_0x55ef09('0x5')]={'priority':{'type':Sequelize[_0x55ef09('0x4')],'allowNull':![]},'app':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x55ef09('0x0')},'appdata':{'type':Sequelize['TEXT']()},'description':{'type':Sequelize[_0x55ef09('0x3')]},'interval':{'type':Sequelize[_0x55ef09('0x3')],'defaultValue':_0x55ef09('0x1')}}; \ No newline at end of file diff --git a/server/api/faxApplication/faxApplication.controller.js b/server/api/faxApplication/faxApplication.controller.js index 377517f..929a814 100644 --- a/server/api/faxApplication/faxApplication.controller.js +++ b/server/api/faxApplication/faxApplication.controller.js @@ -1 +1 @@ -const a193_0x33c0=['pick','include','sort','options','create','keys','undefined','findOne','includeAll','model','../../components/parsers/qs','sequelize','key','destroy','fields','send','map','where','body','count','limit','type','rawAttributes','params','end','lodash','name','order','index','length','update','then','api','offset','show','../../config/logger','set','catch','Content-Range','nolimit','findAll','status','rows','intersection','filter','json','FaxApplication','VIRTUAL','attributes','query','merge','sendStatus','filters'];(function(_0x47c27f,_0x33c0e0){const _0x2edf36=function(_0x5c8936){while(--_0x5c8936){_0x47c27f['push'](_0x47c27f['shift']());}};_0x2edf36(++_0x33c0e0);}(a193_0x33c0,0x1ec));const a193_0x2edf=function(_0x47c27f,_0x33c0e0){_0x47c27f=_0x47c27f-0x0;let _0x2edf36=a193_0x33c0[_0x47c27f];return _0x2edf36;};const _0x27dd95=a193_0x2edf;'use strict';const _=require(_0x27dd95('0xa')),qs=require(_0x27dd95('0x30')),logger=require(_0x27dd95('0x14'))(_0x27dd95('0x11')),db=require('../../mysqldb')['db'],{Op}=require(_0x27dd95('0x31'));function respondWithResult(_0x5c8936,_0x517821){return _0x517821=_0x517821||0xc8,function(_0x24134c){const _0x326230=a193_0x2edf;if(_0x24134c)return _0x5c8936[_0x326230('0x1a')](_0x517821)[_0x326230('0x1e')](_0x24134c);};}function respondWithFilteredResult(_0x3cbefd,_0x4f6b84){return function(_0x3d3a66){const _0x4299d3=a193_0x2edf;if(_0x3d3a66){const _0x26ffcc=_0x3d3a66['count'],_0x34b73b=_0x4f6b84[_0x4299d3('0x12')];let _0x2e4adb=_0x4f6b84[_0x4299d3('0x12')]+_0x4f6b84[_0x4299d3('0x5')],_0x246b4a;return _0x2e4adb>=_0x26ffcc?(_0x2e4adb=_0x26ffcc,_0x246b4a=0xc8):_0x246b4a=0xce,_0x3cbefd[_0x4299d3('0x1a')](_0x246b4a),_0x3cbefd[_0x4299d3('0x15')](_0x4299d3('0x17'),_0x34b73b+'-'+_0x2e4adb+'/'+_0x26ffcc)[_0x4299d3('0x1e')](_0x3d3a66);}return null;};}function saveUpdates(_0x5521f9){return function(_0x4fcc82){const _0xf7a12b=a193_0x2edf;if(_0x4fcc82)return _0x4fcc82[_0xf7a12b('0xf')](_0x5521f9)['then'](function(_0x595696){return _0x595696;});return null;};}function removeEntity(_0x549f23){return function(_0x205cb5){const _0x29764e=a193_0x2edf;if(_0x205cb5)return _0x205cb5[_0x29764e('0x33')]()[_0x29764e('0x10')](function(){const _0x3fc9bb=_0x29764e;_0x549f23[_0x3fc9bb('0x1a')](0xcc)[_0x3fc9bb('0x9')]();});};}function handleEntityNotFound(_0x5ee873){return function(_0xb6c455){const _0x10932e=a193_0x2edf;return!_0xb6c455&&_0x5ee873[_0x10932e('0x24')](0x194),_0xb6c455;};}function handleError(_0x50297e,_0x457fca){return _0x457fca=_0x457fca||0x1f4,function(_0x2a3b1c){const _0x123bde=a193_0x2edf;logger['error'](_0x2a3b1c['stack']),_0x2a3b1c[_0x123bde('0xb')]&&delete _0x2a3b1c[_0x123bde('0xb')],_0x50297e[_0x123bde('0x1a')](_0x457fca)[_0x123bde('0x0')](_0x2a3b1c);};}exports[_0x27dd95('0xd')]=function(_0x3af5f0,_0x359522){const _0x1688a9=_0x27dd95;let _0x39fade={};const _0x3b1366={},_0x508364={'count':0x0,'rows':[]},_0x2e804f=_[_0x1688a9('0x1')](db[_0x1688a9('0x1f')][_0x1688a9('0x7')],function(_0x39caa1){const _0x38c299=_0x1688a9;return{'name':_0x39caa1['fieldName'],'type':_0x39caa1[_0x38c299('0x6')][_0x38c299('0x32')]};});_0x3b1366['model']=_[_0x1688a9('0x1')](_0x2e804f,'name'),_0x3b1366[_0x1688a9('0x22')]=_[_0x1688a9('0x2b')](_0x3af5f0[_0x1688a9('0x22')]),_0x3b1366[_0x1688a9('0x25')]=_[_0x1688a9('0x1c')](_0x3b1366[_0x1688a9('0x2f')],_0x3b1366['query']),_0x39fade[_0x1688a9('0x21')]=_[_0x1688a9('0x1c')](_0x3b1366[_0x1688a9('0x2f')],qs['fields'](_0x3af5f0[_0x1688a9('0x22')][_0x1688a9('0x34')])),_0x39fade['attributes']=_0x39fade[_0x1688a9('0x21')][_0x1688a9('0xe')]?_0x39fade[_0x1688a9('0x21')]:_0x3b1366[_0x1688a9('0x2f')];typeof _0x3af5f0[_0x1688a9('0x22')][_0x1688a9('0x18')]===_0x1688a9('0x2c')&&(_0x39fade[_0x1688a9('0x5')]=qs['limit'](_0x3af5f0[_0x1688a9('0x22')][_0x1688a9('0x5')]),_0x39fade[_0x1688a9('0x12')]=qs[_0x1688a9('0x12')](_0x3af5f0[_0x1688a9('0x22')][_0x1688a9('0x12')]));_0x39fade[_0x1688a9('0xc')]=qs['sort'](_0x3af5f0[_0x1688a9('0x22')][_0x1688a9('0x28')]),_0x39fade['where']=qs[_0x1688a9('0x25')](_[_0x1688a9('0x26')](_0x3af5f0[_0x1688a9('0x22')],_0x3b1366[_0x1688a9('0x25')]),_0x2e804f);_0x3af5f0[_0x1688a9('0x22')]['filter']&&(_0x39fade[_0x1688a9('0x2')]=_['merge'](_0x39fade[_0x1688a9('0x2')],{[Op['or']]:_['map'](_0x2e804f,function(_0x565add){const _0x537ebb=_0x1688a9;if(_0x565add[_0x537ebb('0x6')]!==_0x537ebb('0x20')){const _0x46d9d1={};return _0x46d9d1[_0x565add[_0x537ebb('0xb')]]={[Op['like']]:'%'+_0x3af5f0[_0x537ebb('0x22')][_0x537ebb('0x1d')]+'%'},_0x46d9d1;}})}));_0x39fade=_[_0x1688a9('0x23')]({},_0x39fade,_0x3af5f0[_0x1688a9('0x29')]);const _0x384c80={'where':_0x39fade['where']};return db['FaxApplication'][_0x1688a9('0x4')](_0x384c80)[_0x1688a9('0x10')](function(_0x463249){const _0x478d9c=_0x1688a9;return _0x508364[_0x478d9c('0x4')]=_0x463249,_0x3af5f0['query'][_0x478d9c('0x2e')]&&(_0x39fade[_0x478d9c('0x27')]=[{'all':!![]}]),db[_0x478d9c('0x1f')][_0x478d9c('0x19')](_0x39fade);})[_0x1688a9('0x10')](function(_0x1eeae2){const _0x20fef6=_0x1688a9;return _0x508364[_0x20fef6('0x1b')]=_0x1eeae2,_0x508364;})[_0x1688a9('0x10')](respondWithFilteredResult(_0x359522,_0x39fade))[_0x1688a9('0x16')](handleError(_0x359522,null));},exports[_0x27dd95('0x13')]=function(_0x785da2,_0xd6075d){const _0xd48325=_0x27dd95;let _0x3cb1f9={'raw':!![],'where':{'id':_0x785da2[_0xd48325('0x8')]['id']}};const _0x2de0fb={};return _0x2de0fb['model']=_['keys'](db['FaxApplication']['rawAttributes']),_0x2de0fb['query']=_[_0xd48325('0x2b')](_0x785da2[_0xd48325('0x22')]),_0x2de0fb['filters']=_[_0xd48325('0x1c')](_0x2de0fb[_0xd48325('0x2f')],_0x2de0fb[_0xd48325('0x22')]),_0x3cb1f9['attributes']=_[_0xd48325('0x1c')](_0x2de0fb['model'],qs[_0xd48325('0x34')](_0x785da2[_0xd48325('0x22')][_0xd48325('0x34')])),_0x3cb1f9[_0xd48325('0x21')]=_0x3cb1f9['attributes']['length']?_0x3cb1f9[_0xd48325('0x21')]:_0x2de0fb[_0xd48325('0x2f')],_0x785da2['query'][_0xd48325('0x2e')]&&(_0x3cb1f9['include']=[{'all':!![]}]),_0x3cb1f9=_[_0xd48325('0x23')]({},_0x3cb1f9,_0x785da2['options']),db[_0xd48325('0x1f')][_0xd48325('0x2d')](_0x3cb1f9)[_0xd48325('0x10')](handleEntityNotFound(_0xd6075d,null))[_0xd48325('0x10')](respondWithResult(_0xd6075d,null))[_0xd48325('0x16')](handleError(_0xd6075d,null));},exports['create']=function(_0x3a6f46,_0x1c2484){const _0x4574df=_0x27dd95;return db[_0x4574df('0x1f')][_0x4574df('0x2a')](_0x3a6f46[_0x4574df('0x3')],{})['then'](respondWithResult(_0x1c2484,0xc9))[_0x4574df('0x16')](handleError(_0x1c2484,null));},exports[_0x27dd95('0xf')]=function(_0x3ef56a,_0x17f2f5){const _0x5137a5=_0x27dd95;return _0x3ef56a[_0x5137a5('0x3')]['id']&&delete _0x3ef56a[_0x5137a5('0x3')]['id'],db[_0x5137a5('0x1f')][_0x5137a5('0x2d')]({'where':{'id':_0x3ef56a[_0x5137a5('0x8')]['id']}})[_0x5137a5('0x10')](handleEntityNotFound(_0x17f2f5,null))['then'](saveUpdates(_0x3ef56a['body'],null))['then'](respondWithResult(_0x17f2f5,null))[_0x5137a5('0x16')](handleError(_0x17f2f5,null));},exports[_0x27dd95('0x33')]=function(_0x7f2d80,_0x371923){const _0x6ef969=_0x27dd95;return db[_0x6ef969('0x1f')][_0x6ef969('0x2d')]({'where':{'id':_0x7f2d80[_0x6ef969('0x8')]['id']}})[_0x6ef969('0x10')](handleEntityNotFound(_0x371923,null))[_0x6ef969('0x10')](removeEntity(_0x371923,null))[_0x6ef969('0x16')](handleError(_0x371923,null));}; \ No newline at end of file +const a193_0x5242=['show','FaxApplication','include','body','rows','nolimit','filter','Content-Range','fields','merge','update','../../components/parsers/qs','rawAttributes','VIRTUAL','map','status','findAll','json','offset','like','keys','includeAll','fieldName','sequelize','params','length','lodash','findOne','type','model','create','index','send','key','../../mysqldb','sort','api','stack','end','set','destroy','then','where','count','name','intersection','filters','query','catch','../../config/logger','attributes','limit','error'];(function(_0x29cd39,_0x524201){const _0x3ed76f=function(_0xe75e33){while(--_0xe75e33){_0x29cd39['push'](_0x29cd39['shift']());}};_0x3ed76f(++_0x524201);}(a193_0x5242,0x13e));const a193_0x3ed7=function(_0x29cd39,_0x524201){_0x29cd39=_0x29cd39-0x0;let _0x3ed76f=a193_0x5242[_0x29cd39];return _0x3ed76f;};const _0x230f90=a193_0x3ed7;'use strict';const _=require(_0x230f90('0x1a')),qs=require(_0x230f90('0xb')),logger=require(_0x230f90('0x31'))(_0x230f90('0x24')),db=require(_0x230f90('0x22'))['db'],{Op}=require(_0x230f90('0x17'));function respondWithResult(_0xe75e33,_0x309196){return _0x309196=_0x309196||0xc8,function(_0x14a8f8){const _0x4b7873=a193_0x3ed7;if(_0x14a8f8)return _0xe75e33[_0x4b7873('0xf')](_0x309196)[_0x4b7873('0x11')](_0x14a8f8);};}function respondWithFilteredResult(_0x368ec0,_0x5323e9){return function(_0x449876){const _0x1de366=a193_0x3ed7;if(_0x449876){const _0x296403=_0x449876[_0x1de366('0x2b')],_0x9de0b6=_0x5323e9[_0x1de366('0x12')];let _0x282111=_0x5323e9[_0x1de366('0x12')]+_0x5323e9['limit'],_0x26e537;return _0x282111>=_0x296403?(_0x282111=_0x296403,_0x26e537=0xc8):_0x26e537=0xce,_0x368ec0[_0x1de366('0xf')](_0x26e537),_0x368ec0[_0x1de366('0x27')](_0x1de366('0x7'),_0x9de0b6+'-'+_0x282111+'/'+_0x296403)['json'](_0x449876);}return null;};}function saveUpdates(_0x14d7fe){return function(_0x91a13){const _0x372fd6=a193_0x3ed7;if(_0x91a13)return _0x91a13[_0x372fd6('0xa')](_0x14d7fe)[_0x372fd6('0x29')](function(_0x42711f){return _0x42711f;});return null;};}function removeEntity(_0x14af25){return function(_0x5b2cd0){const _0x5e0aa0=a193_0x3ed7;if(_0x5b2cd0)return _0x5b2cd0[_0x5e0aa0('0x28')]()[_0x5e0aa0('0x29')](function(){const _0x1554a8=_0x5e0aa0;_0x14af25['status'](0xcc)[_0x1554a8('0x26')]();});};}function handleEntityNotFound(_0x5585cb){return function(_0x2353ce){return!_0x2353ce&&_0x5585cb['sendStatus'](0x194),_0x2353ce;};}function handleError(_0x2f8a35,_0x16a5af){return _0x16a5af=_0x16a5af||0x1f4,function(_0x2fa754){const _0x4c3996=a193_0x3ed7;logger[_0x4c3996('0x34')](_0x2fa754[_0x4c3996('0x25')]),_0x2fa754[_0x4c3996('0x2c')]&&delete _0x2fa754[_0x4c3996('0x2c')],_0x2f8a35[_0x4c3996('0xf')](_0x16a5af)[_0x4c3996('0x20')](_0x2fa754);};}exports[_0x230f90('0x1f')]=function(_0x483c43,_0x285e3f){const _0x4a0fc2=_0x230f90;let _0x3a5dd1={};const _0x121365={},_0x368204={'count':0x0,'rows':[]},_0x161470=_[_0x4a0fc2('0xe')](db[_0x4a0fc2('0x1')][_0x4a0fc2('0xc')],function(_0x1d11eb){const _0x52674b=_0x4a0fc2;return{'name':_0x1d11eb[_0x52674b('0x16')],'type':_0x1d11eb[_0x52674b('0x1c')][_0x52674b('0x21')]};});_0x121365[_0x4a0fc2('0x1d')]=_[_0x4a0fc2('0xe')](_0x161470,'name'),_0x121365[_0x4a0fc2('0x2f')]=_[_0x4a0fc2('0x14')](_0x483c43[_0x4a0fc2('0x2f')]),_0x121365[_0x4a0fc2('0x2e')]=_['intersection'](_0x121365['model'],_0x121365[_0x4a0fc2('0x2f')]),_0x3a5dd1[_0x4a0fc2('0x32')]=_[_0x4a0fc2('0x2d')](_0x121365['model'],qs[_0x4a0fc2('0x8')](_0x483c43['query']['fields'])),_0x3a5dd1[_0x4a0fc2('0x32')]=_0x3a5dd1[_0x4a0fc2('0x32')][_0x4a0fc2('0x19')]?_0x3a5dd1['attributes']:_0x121365[_0x4a0fc2('0x1d')];typeof _0x483c43[_0x4a0fc2('0x2f')][_0x4a0fc2('0x5')]==='undefined'&&(_0x3a5dd1['limit']=qs[_0x4a0fc2('0x33')](_0x483c43[_0x4a0fc2('0x2f')]['limit']),_0x3a5dd1[_0x4a0fc2('0x12')]=qs['offset'](_0x483c43[_0x4a0fc2('0x2f')][_0x4a0fc2('0x12')]));_0x3a5dd1['order']=qs[_0x4a0fc2('0x23')](_0x483c43[_0x4a0fc2('0x2f')]['sort']),_0x3a5dd1[_0x4a0fc2('0x2a')]=qs['filters'](_['pick'](_0x483c43[_0x4a0fc2('0x2f')],_0x121365[_0x4a0fc2('0x2e')]),_0x161470);_0x483c43[_0x4a0fc2('0x2f')]['filter']&&(_0x3a5dd1[_0x4a0fc2('0x2a')]=_[_0x4a0fc2('0x9')](_0x3a5dd1[_0x4a0fc2('0x2a')],{[Op['or']]:_['map'](_0x161470,function(_0x324536){const _0x4f1395=_0x4a0fc2;if(_0x324536[_0x4f1395('0x1c')]!==_0x4f1395('0xd')){const _0x415d69={};return _0x415d69[_0x324536[_0x4f1395('0x2c')]]={[Op[_0x4f1395('0x13')]]:'%'+_0x483c43[_0x4f1395('0x2f')][_0x4f1395('0x6')]+'%'},_0x415d69;}})}));_0x3a5dd1=_[_0x4a0fc2('0x9')]({},_0x3a5dd1,_0x483c43['options']);const _0x171529={'where':_0x3a5dd1['where']};return db[_0x4a0fc2('0x1')][_0x4a0fc2('0x2b')](_0x171529)[_0x4a0fc2('0x29')](function(_0x3588e6){const _0x597230=_0x4a0fc2;return _0x368204[_0x597230('0x2b')]=_0x3588e6,_0x483c43[_0x597230('0x2f')]['includeAll']&&(_0x3a5dd1[_0x597230('0x2')]=[{'all':!![]}]),db[_0x597230('0x1')][_0x597230('0x10')](_0x3a5dd1);})[_0x4a0fc2('0x29')](function(_0x421ed3){const _0x550ceb=_0x4a0fc2;return _0x368204[_0x550ceb('0x4')]=_0x421ed3,_0x368204;})['then'](respondWithFilteredResult(_0x285e3f,_0x3a5dd1))[_0x4a0fc2('0x30')](handleError(_0x285e3f,null));},exports[_0x230f90('0x0')]=function(_0x12a88d,_0x186572){const _0x9de5b6=_0x230f90;let _0x50d6ff={'raw':!![],'where':{'id':_0x12a88d['params']['id']}};const _0x2caec2={};return _0x2caec2[_0x9de5b6('0x1d')]=_[_0x9de5b6('0x14')](db[_0x9de5b6('0x1')][_0x9de5b6('0xc')]),_0x2caec2['query']=_[_0x9de5b6('0x14')](_0x12a88d['query']),_0x2caec2['filters']=_['intersection'](_0x2caec2[_0x9de5b6('0x1d')],_0x2caec2[_0x9de5b6('0x2f')]),_0x50d6ff['attributes']=_[_0x9de5b6('0x2d')](_0x2caec2['model'],qs[_0x9de5b6('0x8')](_0x12a88d['query'][_0x9de5b6('0x8')])),_0x50d6ff['attributes']=_0x50d6ff['attributes'][_0x9de5b6('0x19')]?_0x50d6ff[_0x9de5b6('0x32')]:_0x2caec2[_0x9de5b6('0x1d')],_0x12a88d[_0x9de5b6('0x2f')][_0x9de5b6('0x15')]&&(_0x50d6ff[_0x9de5b6('0x2')]=[{'all':!![]}]),_0x50d6ff=_[_0x9de5b6('0x9')]({},_0x50d6ff,_0x12a88d['options']),db[_0x9de5b6('0x1')][_0x9de5b6('0x1b')](_0x50d6ff)[_0x9de5b6('0x29')](handleEntityNotFound(_0x186572,null))[_0x9de5b6('0x29')](respondWithResult(_0x186572,null))[_0x9de5b6('0x30')](handleError(_0x186572,null));},exports[_0x230f90('0x1e')]=function(_0x1b76b0,_0x207a47){const _0x5a01ed=_0x230f90;return db[_0x5a01ed('0x1')]['create'](_0x1b76b0[_0x5a01ed('0x3')],{})[_0x5a01ed('0x29')](respondWithResult(_0x207a47,0xc9))[_0x5a01ed('0x30')](handleError(_0x207a47,null));},exports[_0x230f90('0xa')]=function(_0x5adf81,_0x59ca9a){const _0x209b61=_0x230f90;return _0x5adf81[_0x209b61('0x3')]['id']&&delete _0x5adf81[_0x209b61('0x3')]['id'],db[_0x209b61('0x1')][_0x209b61('0x1b')]({'where':{'id':_0x5adf81[_0x209b61('0x18')]['id']}})['then'](handleEntityNotFound(_0x59ca9a,null))['then'](saveUpdates(_0x5adf81['body'],null))[_0x209b61('0x29')](respondWithResult(_0x59ca9a,null))[_0x209b61('0x30')](handleError(_0x59ca9a,null));},exports[_0x230f90('0x28')]=function(_0xe5139d,_0x5431e3){const _0x135700=_0x230f90;return db[_0x135700('0x1')][_0x135700('0x1b')]({'where':{'id':_0xe5139d[_0x135700('0x18')]['id']}})[_0x135700('0x29')](handleEntityNotFound(_0x5431e3,null))[_0x135700('0x29')](removeEntity(_0x5431e3,null))[_0x135700('0x30')](handleError(_0x5431e3,null));}; \ No newline at end of file diff --git a/server/api/faxApplication/faxApplication.model.js b/server/api/faxApplication/faxApplication.model.js index 9badba3..ed6d0b9 100644 --- a/server/api/faxApplication/faxApplication.model.js +++ b/server/api/faxApplication/faxApplication.model.js @@ -1 +1 @@ -const a194_0x3ae3=['fax_applications','utf8mb4_unicode_ci','FaxApplication','define','./faxApplication.attributes'];(function(_0x538c66,_0x3ae349){const _0x1a2ddb=function(_0x3f2ea3){while(--_0x3f2ea3){_0x538c66['push'](_0x538c66['shift']());}};_0x1a2ddb(++_0x3ae349);}(a194_0x3ae3,0x67));const a194_0x1a2d=function(_0x538c66,_0x3ae349){_0x538c66=_0x538c66-0x0;let _0x1a2ddb=a194_0x3ae3[_0x538c66];return _0x1a2ddb;};const _0x15e385=a194_0x1a2d;'use strict';const attributes=require(_0x15e385('0x1'));module['exports']=function(_0x3f2ea3){const _0x26a4ea=_0x15e385,_0x14c18a=_0x3f2ea3[_0x26a4ea('0x0')](_0x26a4ea('0x4'),attributes,{'tableName':_0x26a4ea('0x2'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':'utf8mb4','collate':_0x26a4ea('0x3')});return _0x14c18a;}; \ No newline at end of file +const a194_0x52c2=['./faxApplication.attributes','FaxApplication','exports','define','utf8mb4','fax_applications'];(function(_0x26a0e7,_0x52c29b){const _0x26f5db=function(_0x50b27e){while(--_0x50b27e){_0x26a0e7['push'](_0x26a0e7['shift']());}};_0x26f5db(++_0x52c29b);}(a194_0x52c2,0xa6));const a194_0x26f5=function(_0x26a0e7,_0x52c29b){_0x26a0e7=_0x26a0e7-0x0;let _0x26f5db=a194_0x52c2[_0x26a0e7];return _0x26f5db;};const _0x4f1607=a194_0x26f5;'use strict';const attributes=require(_0x4f1607('0x2'));module[_0x4f1607('0x4')]=function(_0x50b27e){const _0x5ac21c=_0x4f1607,_0xe5bd84=_0x50b27e[_0x5ac21c('0x5')](_0x5ac21c('0x3'),attributes,{'tableName':_0x5ac21c('0x1'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x5ac21c('0x0'),'collate':'utf8mb4_unicode_ci'});return _0xe5bd84;}; \ No newline at end of file diff --git a/server/api/faxApplication/faxApplication.rpc.js b/server/api/faxApplication/faxApplication.rpc.js index cb81e5d..fcec6c8 100644 --- a/server/api/faxApplication/faxApplication.rpc.js +++ b/server/api/faxApplication/faxApplication.rpc.js @@ -1 +1 @@ -const a195_0x52fe=['update','options','raw','body','attributes','stringify','limit','message','error','then','../../mysqldb','where','info','catch','../../config/logger','rpc','debug','UpdateFaxApplication'];(function(_0x141755,_0x52fecf){const _0x21c548=function(_0x5f4cc1){while(--_0x5f4cc1){_0x141755['push'](_0x141755['shift']());}};_0x21c548(++_0x52fecf);}(a195_0x52fe,0x77));const a195_0x21c5=function(_0x141755,_0x52fecf){_0x141755=_0x141755-0x0;let _0x21c548=a195_0x52fe[_0x141755];return _0x21c548;};const _0x4a7893=a195_0x21c5;'use strict';const db=require(_0x4a7893('0x11'))['db'],logger=require(_0x4a7893('0x3'))(_0x4a7893('0x4'));exports[_0x4a7893('0x6')]=function(_0x5f4cc1){const _0x421484=this;return new Promise(function(_0x5d0f7e,_0x11646a){const _0x323127=a195_0x21c5;return db['FaxApplication'][_0x323127('0x7')](_0x5f4cc1[_0x323127('0xa')],{'raw':_0x5f4cc1['options']?_0x5f4cc1['options'][_0x323127('0x9')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x5f4cc1[_0x323127('0x8')]?_0x5f4cc1[_0x323127('0x8')][_0x323127('0x0')]||null:null,'attributes':_0x5f4cc1[_0x323127('0x8')]?_0x5f4cc1[_0x323127('0x8')][_0x323127('0xb')]||null:null,'limit':_0x5f4cc1[_0x323127('0x8')]?_0x5f4cc1[_0x323127('0x8')][_0x323127('0xd')]||null:null})[_0x323127('0x10')](function(_0x3df2f6){const _0x54b7d8=_0x323127;logger[_0x54b7d8('0x1')](_0x54b7d8('0x6'),_0x5f4cc1),logger[_0x54b7d8('0x5')](_0x54b7d8('0x6'),_0x5f4cc1,JSON[_0x54b7d8('0xc')](_0x3df2f6)),_0x5d0f7e(_0x3df2f6);})[_0x323127('0x2')](function(_0xb9c659){const _0x3a6b7c=_0x323127;logger['error'](_0x3a6b7c('0x6'),_0xb9c659[_0x3a6b7c('0xe')],_0x5f4cc1),_0x11646a(_0x421484[_0x3a6b7c('0xf')](0x1f4,_0xb9c659[_0x3a6b7c('0xe')]));});});}; \ No newline at end of file +const a195_0x53d7=['catch','then','message','error','rpc','limit','UpdateFaxApplication','info','where','options','update','FaxApplication','raw'];(function(_0x33ee21,_0x53d7fe){const _0x41b037=function(_0xf1c5ad){while(--_0xf1c5ad){_0x33ee21['push'](_0x33ee21['shift']());}};_0x41b037(++_0x53d7fe);}(a195_0x53d7,0x155));const a195_0x41b0=function(_0x33ee21,_0x53d7fe){_0x33ee21=_0x33ee21-0x0;let _0x41b037=a195_0x53d7[_0x33ee21];return _0x41b037;};const _0x52ff49=a195_0x41b0;'use strict';const db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x52ff49('0x1'));exports[_0x52ff49('0x3')]=function(_0xf1c5ad){const _0x1b51b3=this;return new Promise(function(_0x7d4b03,_0x5a2cb7){const _0x14f642=a195_0x41b0;return db[_0x14f642('0x8')][_0x14f642('0x7')](_0xf1c5ad['body'],{'raw':_0xf1c5ad[_0x14f642('0x6')]?_0xf1c5ad[_0x14f642('0x6')][_0x14f642('0x9')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0xf1c5ad[_0x14f642('0x6')]?_0xf1c5ad[_0x14f642('0x6')][_0x14f642('0x5')]||null:null,'attributes':_0xf1c5ad[_0x14f642('0x6')]?_0xf1c5ad[_0x14f642('0x6')]['attributes']||null:null,'limit':_0xf1c5ad['options']?_0xf1c5ad['options'][_0x14f642('0x2')]||null:null})[_0x14f642('0xb')](function(_0x527184){const _0x14ab27=_0x14f642;logger[_0x14ab27('0x4')](_0x14ab27('0x3'),_0xf1c5ad),logger['debug'](_0x14ab27('0x3'),_0xf1c5ad,JSON['stringify'](_0x527184)),_0x7d4b03(_0x527184);})[_0x14f642('0xa')](function(_0x4fc144){const _0x9a6212=_0x14f642;logger['error'](_0x9a6212('0x3'),_0x4fc144[_0x9a6212('0xc')],_0xf1c5ad),_0x5a2cb7(_0x1b51b3[_0x9a6212('0x0')](0x1f4,_0x4fc144['message']));});});}; \ No newline at end of file diff --git a/server/api/faxApplication/index.js b/server/api/faxApplication/index.js index ca01f2b..0193a97 100644 --- a/server/api/faxApplication/index.js +++ b/server/api/faxApplication/index.js @@ -1 +1 @@ -const a196_0xcf6b=['post','express','update','show','./faxApplication.controller','/:id','Router','delete','put','destroy','exports','index','get','isAuthenticated'];(function(_0x1ef94f,_0xcf6bf5){const _0x5009f3=function(_0x2c655e){while(--_0x2c655e){_0x1ef94f['push'](_0x1ef94f['shift']());}};_0x5009f3(++_0xcf6bf5);}(a196_0xcf6b,0x188));const a196_0x5009=function(_0x1ef94f,_0xcf6bf5){_0x1ef94f=_0x1ef94f-0x0;let _0x5009f3=a196_0xcf6b[_0x1ef94f];return _0x5009f3;};const _0x155a77=a196_0x5009;'use strict';const express=require(_0x155a77('0x1')),router=express[_0x155a77('0x6')](),auth=require('../../components/auth/service'),controller=require(_0x155a77('0x4'));router[_0x155a77('0xc')]('/',auth[_0x155a77('0xd')](),controller[_0x155a77('0xb')]),router[_0x155a77('0xc')]('/:id',auth[_0x155a77('0xd')](),controller[_0x155a77('0x3')]),router[_0x155a77('0x0')]('/',auth[_0x155a77('0xd')](),controller['create']),router[_0x155a77('0x8')](_0x155a77('0x5'),auth['isAuthenticated'](),controller[_0x155a77('0x2')]),router[_0x155a77('0x7')](_0x155a77('0x5'),auth[_0x155a77('0xd')](),controller[_0x155a77('0x9')]),module[_0x155a77('0xa')]=router; \ No newline at end of file +const a196_0x5e3b=['../../components/auth/service','index','put','express','delete','./faxApplication.controller','update','Router','destroy','/:id','show','isAuthenticated','get','create'];(function(_0x4b610a,_0x5e3bba){const _0x36b3e3=function(_0x2266a6){while(--_0x2266a6){_0x4b610a['push'](_0x4b610a['shift']());}};_0x36b3e3(++_0x5e3bba);}(a196_0x5e3b,0x1dc));const a196_0x36b3=function(_0x4b610a,_0x5e3bba){_0x4b610a=_0x4b610a-0x0;let _0x36b3e3=a196_0x5e3b[_0x4b610a];return _0x36b3e3;};const _0x4b45d0=a196_0x36b3;'use strict';const express=require(_0x4b45d0('0x3')),router=express[_0x4b45d0('0x7')](),auth=require(_0x4b45d0('0x0')),controller=require(_0x4b45d0('0x5'));router['get']('/',auth['isAuthenticated'](),controller[_0x4b45d0('0x1')]),router[_0x4b45d0('0xc')](_0x4b45d0('0x9'),auth[_0x4b45d0('0xb')](),controller[_0x4b45d0('0xa')]),router['post']('/',auth[_0x4b45d0('0xb')](),controller[_0x4b45d0('0xd')]),router[_0x4b45d0('0x2')](_0x4b45d0('0x9'),auth[_0x4b45d0('0xb')](),controller[_0x4b45d0('0x6')]),router[_0x4b45d0('0x4')]('/:id',auth[_0x4b45d0('0xb')](),controller[_0x4b45d0('0x8')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/faxInteraction/faxInteraction.attributes.js b/server/api/faxInteraction/faxInteraction.attributes.js index 6100541..459d5db 100644 --- a/server/api/faxInteraction/faxInteraction.attributes.js +++ b/server/api/faxInteraction/faxInteraction.attributes.js @@ -1 +1 @@ -const a197_0x3dea=['ENUM','DATE','sequelize','BOOLEAN','STRING','out'];(function(_0x1bafb2,_0x3dea0c){const _0x74dc0b=function(_0x34e4c9){while(--_0x34e4c9){_0x1bafb2['push'](_0x1bafb2['shift']());}};_0x74dc0b(++_0x3dea0c);}(a197_0x3dea,0x151));const a197_0x74dc=function(_0x1bafb2,_0x3dea0c){_0x1bafb2=_0x1bafb2-0x0;let _0x74dc0b=a197_0x3dea[_0x1bafb2];return _0x74dc0b;};const _0x171c7c=a197_0x74dc;'use strict';const Sequelize=require(_0x171c7c('0x1'));module['exports']={'closed':{'type':Sequelize[_0x171c7c('0x2')],'defaultValue':![]},'closedAt':{'type':Sequelize[_0x171c7c('0x0')]},'disposition':{'type':Sequelize[_0x171c7c('0x3')]},'secondDisposition':{'type':Sequelize[_0x171c7c('0x3')]},'thirdDisposition':{'type':Sequelize[_0x171c7c('0x3')]},'note':{'type':Sequelize[_0x171c7c('0x3')]},'read1stAt':{'type':Sequelize[_0x171c7c('0x0')]},'fax':{'type':Sequelize[_0x171c7c('0x3')]},'firstMsgDirection':{'type':Sequelize[_0x171c7c('0x5')]('in',_0x171c7c('0x4')),'defaultValue':'in','allowNull':![]},'lastMsgAt':{'type':Sequelize[_0x171c7c('0x0')]},'lastMsgDirection':{'type':Sequelize[_0x171c7c('0x5')]('in',_0x171c7c('0x4')),'defaultValue':'in','allowNull':![]}}; \ No newline at end of file +const a197_0x51e5=['ENUM','STRING','out','DATE','BOOLEAN','sequelize'];(function(_0x3fc099,_0x51e538){const _0x166710=function(_0x1456a1){while(--_0x1456a1){_0x3fc099['push'](_0x3fc099['shift']());}};_0x166710(++_0x51e538);}(a197_0x51e5,0x131));const a197_0x1667=function(_0x3fc099,_0x51e538){_0x3fc099=_0x3fc099-0x0;let _0x166710=a197_0x51e5[_0x3fc099];return _0x166710;};const _0x19d1f4=a197_0x1667;'use strict';const Sequelize=require(_0x19d1f4('0x0'));module['exports']={'closed':{'type':Sequelize[_0x19d1f4('0x5')],'defaultValue':![]},'closedAt':{'type':Sequelize['DATE']},'disposition':{'type':Sequelize[_0x19d1f4('0x2')]},'secondDisposition':{'type':Sequelize[_0x19d1f4('0x2')]},'thirdDisposition':{'type':Sequelize[_0x19d1f4('0x2')]},'note':{'type':Sequelize[_0x19d1f4('0x2')]},'read1stAt':{'type':Sequelize[_0x19d1f4('0x4')]},'fax':{'type':Sequelize[_0x19d1f4('0x2')]},'firstMsgDirection':{'type':Sequelize[_0x19d1f4('0x1')]('in',_0x19d1f4('0x3')),'defaultValue':'in','allowNull':![]},'lastMsgAt':{'type':Sequelize[_0x19d1f4('0x4')]},'lastMsgDirection':{'type':Sequelize[_0x19d1f4('0x1')]('in',_0x19d1f4('0x3')),'defaultValue':'in','allowNull':![]}}; \ No newline at end of file diff --git a/server/api/faxInteraction/faxInteraction.controller.js b/server/api/faxInteraction/faxInteraction.controller.js index 9896ff5..6e91f61 100644 --- a/server/api/faxInteraction/faxInteraction.controller.js +++ b/server/api/faxInteraction/faxInteraction.controller.js @@ -1 +1 @@ -const a198_0x2529=['Users','concat','fax_accounts','SELECT','operator','a.id\x20=\x20i.FaxAccountId','c.mobile','existsSync','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','Content-Range','parse','includeAll','from','FaxAccountId','rimraf','query','split','user','\x27\x27\x27\x27','end','sequelize','i.id\x20LIKE\x20?','clone','toString','map','nolimit','./faxInteraction.socket','Contact.fax','expr','union','order','`\x20=\x200','TagIds','where','c.fax','findAll','show','send','rows','sort','../../config/logger','user_has_fax_interactions','update','destroy','start','findOne','Tag','keyBy','keys','server','YYYY-MM-DD\x20HH:mm:ss','isArray','i.*','i.FaxAccountId\x20IS\x20NOT\x20NULL','attributes','err','t.id\x20=\x20it.TagId','replace','files','u.id\x20=\x20ui.UserId','a.mandatoryDisposition','name','limit','json','User','../../components/parsers/qs','left_join','isEmpty','format','options','Attachment','zip-dir','resolve','$lte','ui.FaxInteractionId\x20IN\x20?','MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','forEach','Contact.mobile','color','Account.mandatoryDisposition','filters','fullname','download','length','Account.key','register','parseSearch','moment','removeTags','field','conditions','push','text','$substring','Messages','read','offset','undefined','Contact.lastName','unix','addTags','unreadMessages','type','group','fields','c.lastName','then','o.id\x20=\x20i.UserId','join','like','count','buildExpression','Contact','c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?','CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?','groupBy','createWriteStream','journey','all','filter','getFaxAccounts','emit','fax_interaction_has_tags','pick','`unreadMessages`\x20=\x200','tmp','UserId','users','status','select','Contact.email','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','squel','faxInteractionTags:save','ids','createdAt','getFullTextValue','catch','FaxMessage','addMessage','model','fieldName','unlinkSync','i.id','tag','intersection','search','Owner.fullname','describe','find','../../components/parsers/advancedSearch','rawAttributes','i.FaxAccountId\x20IN\x20?','params','c.email','basename','`unreadMessages`\x20>\x200','cm_contacts','attachments','pipe','include','stack','../../config/environment','Contact.phone','create','sendStatus','key','Sequelize','merge','i.FaxAccountId\x20IS\x20NULL','having','createReadStream','i.fax\x20LIKE\x20?','Tags','c.firstName','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','error','lodash','`\x20>\x200','body','tools_tags','util','t.id\x20IN\x20?','FaxInteraction','api','o.fullname','log','get','$gte','omit','value','a.key','i.createdAt\x20BETWEEN\x20?\x20AND\x20?'];(function(_0x2aad9d,_0x2529de){const _0x2864a2=function(_0x38703a){while(--_0x38703a){_0x2aad9d['push'](_0x2aad9d['shift']());}};_0x2864a2(++_0x2529de);}(a198_0x2529,0xec));const a198_0x2864=function(_0x2aad9d,_0x2529de){_0x2aad9d=_0x2aad9d-0x0;let _0x2864a2=a198_0x2529[_0x2aad9d];return _0x2864a2;};const _0x41d941=a198_0x2864;'use strict';const rimraf=require(_0x41d941('0xa4')),zipdir=require(_0x41d941('0x1c')),moment=require(_0x41d941('0x2c')),util=require(_0x41d941('0x8a')),path=require('path'),fs=require('fs'),_=require(_0x41d941('0x86')),squel=require(_0x41d941('0x59')),{getSocket}=require('../../rediscache'),socket=getSocket(),qs=require(_0x41d941('0x16')),as=require(_0x41d941('0x6b')),logger=require(_0x41d941('0xbe'))(_0x41d941('0x8d')),config=require(_0x41d941('0x77')),db=require('../../mysqldb')['db'],{Op}=require(_0x41d941('0xaa'));require(_0x41d941('0xb0'))[_0x41d941('0x2a')](socket);function respondWithStatusCode(_0x38703a,_0x5ee7a9){return _0x5ee7a9=_0x5ee7a9||0xcc,function(_0x33af3e){const _0x331674=a198_0x2864;if(_0x33af3e)return _0x38703a[_0x331674('0x7a')](_0x5ee7a9);return _0x38703a['status'](_0x5ee7a9)['end']();};}function respondWithResult(_0x4910e0,_0x5f40a4){return _0x5f40a4=_0x5f40a4||0xc8,function(_0x2e3f95){const _0x5f2148=a198_0x2864;if(_0x2e3f95)return _0x4910e0[_0x5f2148('0x55')](_0x5f40a4)[_0x5f2148('0x14')](_0x2e3f95);};}function respondWithFilteredResult(_0x245137,_0x16583e){return function(_0x2d015d){const _0x44b1df=a198_0x2864;if(_0x2d015d){const _0xd8576e=_0x2d015d[_0x44b1df('0x43')],_0x19f76b=_0x16583e['offset'];let _0x8f7cd7=_0x16583e[_0x44b1df('0x35')]+_0x16583e[_0x44b1df('0x13')],_0xc9088;return _0x8f7cd7>=_0xd8576e?(_0x8f7cd7=_0xd8576e,_0xc9088=0xc8):_0xc9088=0xce,_0x245137[_0x44b1df('0x55')](_0xc9088),_0x245137['set'](_0x44b1df('0x9f'),_0x19f76b+'-'+_0x8f7cd7+'/'+_0xd8576e)[_0x44b1df('0x14')](_0x2d015d);}return null;};}function saveUpdates(_0x108568){return function(_0x3cb0b6){const _0x4346a0=a198_0x2864;if(_0x3cb0b6)return _0x3cb0b6[_0x4346a0('0xc0')](_0x108568)[_0x4346a0('0x3f')](function(_0x15146d){return _0x15146d;});return null;};}function removeEntity(_0x202f6d){return function(_0x5cfd92){const _0x294a2f=a198_0x2864;if(_0x5cfd92)return _0x5cfd92['destroy']()[_0x294a2f('0x3f')](function(){const _0x14a280=_0x294a2f;_0x202f6d[_0x14a280('0x55')](0xcc)[_0x14a280('0xa9')]();});};}function handleEntityNotFound(_0x1f9e76){return function(_0x138d07){const _0x1be499=a198_0x2864;return!_0x138d07&&_0x1f9e76[_0x1be499('0x7a')](0x194),_0x138d07;};}function handleError(_0x1f688b,_0x4151f2){return _0x4151f2=_0x4151f2||0x1f4,function(_0x507532){const _0x5b256a=a198_0x2864;logger[_0x5b256a('0x85')](_0x507532[_0x5b256a('0x76')]),_0x507532[_0x5b256a('0x12')]&&delete _0x507532['name'],_0x1f688b[_0x5b256a('0x55')](_0x4151f2)[_0x5b256a('0xbb')](_0x507532);};}function getInteractionUsers(_0x24cd0f,_0x485be7){return new Promise(function(_0x1d8aec,_0x1b58f5){const _0xf02d8f=a198_0x2864;try{_0x485be7[_0x24cd0f['id']]&&(_0x24cd0f[_0xf02d8f('0x96')]=_[_0xf02d8f('0xae')](_0x485be7[_0x24cd0f['id']],function(_0x10615a){const _0x3eecd9=_0xf02d8f;return{'id':_0x10615a['id'],'fullname':_0x10615a[_0x3eecd9('0x26')]};}));}catch(_0x4e851d){_0x1b58f5(_0x4e851d);}_0x1d8aec(_0x24cd0f);});}function getInteractionTags(_0x38e61f,_0x5442ff){return new Promise(function(_0x34918a,_0x1cf0bb){const _0x23c0e6=a198_0x2864;try{_0x38e61f['TagIds']&&(_0x38e61f[_0x23c0e6('0x82')]=[],_0x38e61f[_0x23c0e6('0xb6')]['split'](',')[_0x23c0e6('0x21')](function(_0x108720){const _0x132f02=_0x23c0e6;_0x38e61f[_0x132f02('0x82')][_0x132f02('0x30')](_0x5442ff[_0x108720]);})),delete _0x38e61f[_0x23c0e6('0xb6')];}catch(_0x21a6f3){_0x1cf0bb(_0x21a6f3);}_0x34918a(_0x38e61f);});}function updateFaxInteraction(_0x26b4e8,_0x2a1897,_0x5cfb0a){return new Promise(function(_0x109a12,_0x286dc7){const _0xfba4f8=a198_0x2864;return getInteractionUsers(_0x26b4e8,_0x5cfb0a)[_0xfba4f8('0x3f')](function(_0x3dffd4){return getInteractionTags(_0x3dffd4,_0x2a1897);})['then'](function(_0x47b06a){_0x109a12(_0x47b06a);})['catch'](function(_0x35a540){_0x286dc7(_0x35a540);});});}exports['index']=function(_0x99e3c7,_0x277233){const _0x4160ec=_0x41d941,_0x3376eb={},_0x30117c={},_0x49090b={'count':0x0,'rows':[]},_0x16e3d7=_[_0x4160ec('0xae')](db[_0x4160ec('0x8c')][_0x4160ec('0x6c')],function(_0x3c4d37){const _0x3e3551=_0x4160ec;return{'name':_0x3c4d37[_0x3e3551('0x62')],'type':_0x3c4d37[_0x3e3551('0x3b')][_0x3e3551('0x7b')]};});_0x30117c['model']=_[_0x4160ec('0xae')](_0x16e3d7,_0x4160ec('0x12')),_0x30117c[_0x4160ec('0xa5')]=_[_0x4160ec('0x5')](_0x99e3c7[_0x4160ec('0xa5')]),_0x30117c[_0x4160ec('0x25')]=_[_0x4160ec('0x66')](_0x30117c['model'],_0x30117c[_0x4160ec('0xa5')]),_0x3376eb['attributes']=_[_0x4160ec('0x66')](_0x30117c[_0x4160ec('0x61')],qs[_0x4160ec('0x3d')](_0x99e3c7[_0x4160ec('0xa5')]['fields'])),_0x3376eb[_0x4160ec('0xb')]=_0x3376eb[_0x4160ec('0xb')][_0x4160ec('0x28')]?_0x3376eb[_0x4160ec('0xb')]:_0x30117c[_0x4160ec('0x61')];typeof _0x99e3c7[_0x4160ec('0xa5')][_0x4160ec('0xaf')]===_0x4160ec('0x36')&&(_0x3376eb[_0x4160ec('0x13')]=qs[_0x4160ec('0x13')](_0x99e3c7['query'][_0x4160ec('0x13')]),_0x3376eb['offset']=qs['offset'](_0x99e3c7['query'][_0x4160ec('0x35')]));_0x3376eb[_0x4160ec('0xb4')]=qs[_0x4160ec('0xbd')](_0x99e3c7[_0x4160ec('0xa5')][_0x4160ec('0xbd')]),_0x3376eb[_0x4160ec('0xb7')]=qs[_0x4160ec('0x25')](_['pick'](_0x99e3c7[_0x4160ec('0xa5')],_0x30117c['filters']),_0x16e3d7);let _0x4c7eca=[];const _0xb5c369=squel['select']()[_0x4160ec('0x2e')]('id')[_0x4160ec('0x2e')](_0x4160ec('0x12'))['field'](_0x4160ec('0x23'))[_0x4160ec('0xa2')](_0x4160ec('0x89')),_0x4aab1f=squel[_0x4160ec('0x56')]()[_0x4160ec('0x2e')]('u.id')['field']('u.fullname')['field']('ui.FaxInteractionId')['from'](_0x4160ec('0xbf'),'ui')[_0x4160ec('0x17')](_0x4160ec('0x54'),'u',_0x4160ec('0x10')),_0x55b98f=squel['select']()[_0x4160ec('0xa2')]('fax_interactions','i')['left_join'](_0x4160ec('0x72'),'c','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL')[_0x4160ec('0x17')](_0x4160ec('0x54'),'o',_0x4160ec('0x40'))[_0x4160ec('0x17')](_0x4160ec('0x98'),'a',_0x4160ec('0x9b'))[_0x4160ec('0x17')]('fax_messages','me','me.FaxInteractionId\x20=\x20i.id')['left_join'](_0x4160ec('0x4f'),'it','it.FaxInteractionId\x20=\x20i.id')['left_join']('tools_tags','t',_0x4160ec('0xd')),_0x4c7f5d=squel['expr']();let _0x16201b=[];const _0x541a5d=squel[_0x4160ec('0xb2')]();let _0x1c83d5;if(_0x99e3c7['query'][_0x4160ec('0x67')]){_0x1c83d5=as[_0x4160ec('0x2b')](_0x99e3c7[_0x4160ec('0xa5')]['search']);const _0x11a398=_0x1c83d5['sqlOperator'];for(let _0x746f80=0x0;_0x746f80<_0x1c83d5[_0x4160ec('0x2f')][_0x4160ec('0x28')];_0x746f80++){const _0xae8f3f=_0x1c83d5[_0x4160ec('0x2f')][_0x746f80],_0x29ae62='i';let _0x3864dc,_0x1c56aa=_[_0x4160ec('0x6a')](_0x16e3d7,[_0x4160ec('0x12'),_0xae8f3f['field']]);if(!_0x1c56aa)switch(_0xae8f3f[_0x4160ec('0x2e')]){case _0x4160ec('0x3a'):_0xae8f3f[_0x4160ec('0x93')]==0x1?_0x55b98f[_0x4160ec('0x7f')]('`'+_0xae8f3f[_0x4160ec('0x2e')]+_0x4160ec('0xb5')):_0x55b98f[_0x4160ec('0x7f')]('`'+_0xae8f3f[_0x4160ec('0x2e')]+_0x4160ec('0x87'));break;case _0x4160ec('0x45'):if(_0xae8f3f[_0x4160ec('0x9a')]===_0x4160ec('0x32')){if(_0xae8f3f[_0x4160ec('0x93')][_0x4160ec('0xa6')]('\x20')[_0x4160ec('0x28')]>0x1)_0x4c7f5d[_0x11a398](_0x4160ec('0x20'),qs[_0x4160ec('0x5d')](_0xae8f3f['value']),null);else{const _0x15a74e='%'+_0xae8f3f[_0x4160ec('0x93')]+'%';_0x4c7f5d[_0x11a398](_0x4160ec('0x46'),_0x15a74e,_0x15a74e,_0x15a74e);}}else _0x1c56aa=_[_0x4160ec('0x6a')](_0x16e3d7,[_0x4160ec('0x12'),'ContactId']),_0xae8f3f[_0x4160ec('0x2e')]='ContactId',_0x3864dc=as[_0x4160ec('0x44')](_0x29ae62,_0x1c56aa[_0x4160ec('0x3b')],_0xae8f3f),_0x4c7f5d[_0x11a398](_0x3864dc[_0x4160ec('0x31')],_0x3864dc[_0x4160ec('0x93')][_0x4160ec('0x1')],_0x3864dc[_0x4160ec('0x93')][_0x4160ec('0xa9')]);break;case _0x4160ec('0x3'):{const _0x302e4f=_0xae8f3f['value'][_0x4160ec('0xa6')](',')[_0x4160ec('0xae')](function(_0x56fcf4){return Number(_0x56fcf4);});_0x302e4f[_0x4160ec('0x21')](function(_0x1a9df9){const _0x49658e=_0x4160ec;_0x541a5d['or'](_0x49658e('0x58'),'%,'+_0x1a9df9+',%');}),_0x16201b=_[_0x4160ec('0xb3')](_0x16201b,_0x302e4f);}break;case _0x4160ec('0x15'):_0xae8f3f['operator']===_0x4160ec('0x32')?_0x4c7f5d[_0x11a398](_0x4160ec('0x84'),'%'+_0xae8f3f[_0x4160ec('0x93')]+'%',null):(_0x1c56aa=_[_0x4160ec('0x6a')](_0x16e3d7,[_0x4160ec('0x12'),_0x4160ec('0x53')]),_0xae8f3f['field']='UserId',_0x3864dc=as[_0x4160ec('0x44')](_0x29ae62,_0x1c56aa['type'],_0xae8f3f),_0x4c7f5d[_0x11a398](_0x3864dc[_0x4160ec('0x31')],_0x3864dc[_0x4160ec('0x93')][_0x4160ec('0x1')],_0x3864dc[_0x4160ec('0x93')][_0x4160ec('0xa9')]));break;case'body':_0x3864dc=as['buildExpression']('me',null,_0xae8f3f),_0x4c7f5d[_0x11a398](_0x3864dc['text'],_0x3864dc[_0x4160ec('0x93')][_0x4160ec('0x1')],_0x3864dc[_0x4160ec('0x93')][_0x4160ec('0xa9')]);break;}else _0x3864dc=as[_0x4160ec('0x44')](_0x29ae62,_0x1c56aa[_0x4160ec('0x3b')],_0xae8f3f),_0x4c7f5d[_0x11a398](_0x3864dc[_0x4160ec('0x31')],_0x3864dc[_0x4160ec('0x93')][_0x4160ec('0x1')],_0x3864dc['value'][_0x4160ec('0xa9')]);}}else{const _0x2d4c4d=_(_0x99e3c7[_0x4160ec('0xa5')])[_0x4160ec('0x5')]()['map'](function(_0x10b675){const _0x38a928=_0x4160ec;return _['some'](_0x16e3d7,[_0x38a928('0x12'),_0x10b675])?_0x10b675:undefined;})['compact']()[_0x4160ec('0x93')]();!_[_0x4160ec('0x18')](_0x2d4c4d)&&_0x2d4c4d['forEach'](function(_0xb9e13e){const _0x56a717=_0x4160ec;if(_0xb9e13e===_0x56a717('0xa3'))_0x55b98f[_0x56a717('0xb7')](_0x56a717('0x6d'),[][_0x56a717('0x97')](_0x99e3c7[_0x56a717('0xa5')][_0xb9e13e]));else{if(_0xb9e13e===_0x56a717('0x5c')){const _0x196cec=JSON[_0x56a717('0xa0')](_0x99e3c7[_0x56a717('0xa5')][_0xb9e13e])[_0x56a717('0x91')],_0x17b575=JSON[_0x56a717('0xa0')](_0x99e3c7['query'][_0xb9e13e])[_0x56a717('0x1e')];_0x55b98f[_0x56a717('0xb7')](_0x56a717('0x95'),_0x196cec,_0x17b575);}else _0x99e3c7[_0x56a717('0xa5')][_0xb9e13e]==='null'?_0x55b98f[_0x56a717('0xb7')]('i.'+_0xb9e13e+'\x20IS\x20NULL'):_0x55b98f['where']('i.'+_0xb9e13e+'\x20=\x20?',_0x99e3c7['query'][_0xb9e13e]);}});_0x99e3c7['query'][_0x4160ec('0x34')]&&(_0x99e3c7[_0x4160ec('0xa5')][_0x4160ec('0x34')]==0x1?_0x55b98f['having'](_0x4160ec('0x51')):_0x55b98f[_0x4160ec('0x7f')](_0x4160ec('0x71')));_0x99e3c7[_0x4160ec('0xa5')][_0x4160ec('0x65')]&&(_0x16201b=_[_0x4160ec('0x8')](_0x99e3c7[_0x4160ec('0xa5')][_0x4160ec('0x65')])?_0x99e3c7[_0x4160ec('0xa5')][_0x4160ec('0x65')]:new Array(_0x99e3c7[_0x4160ec('0xa5')][_0x4160ec('0x65')]),_0x16201b[_0x4160ec('0x21')](function(_0xe53144){const _0x44502d=_0x4160ec;_0x541a5d['or'](_0x44502d('0x58'),'%,'+_0xe53144+',%');}));if(_0x99e3c7[_0x4160ec('0xa5')][_0x4160ec('0x4c')]){const _0x245b94=_0x99e3c7['query'][_0x4160ec('0x4c')]['replace']('\x5c','\x5c\x5c')[_0x4160ec('0xe')]('\x27\x27',_0x4160ec('0xa8'));qs['isNumeric'](_0x245b94)&&_0x4c7f5d['or'](_0x4160ec('0xab'),_0x245b94+'%')['or'](_0x4160ec('0x81'),_0x245b94+'%'),_0x4c7f5d['or'](_0x4160ec('0x47'),_0x245b94+'%');}}_0x55b98f[_0x4160ec('0xb7')](_0x4c7f5d),_0x55b98f[_0x4160ec('0x3c')](_0x4160ec('0x64'));let _0x594661={'type':db[_0x4160ec('0x7c')]['QueryTypes'][_0x4160ec('0x99')],'raw':!![]};const _0x56e2c1=_0x55b98f[_0x4160ec('0xac')]();_0x56e2c1[_0x4160ec('0x2e')](_0x4160ec('0x64')),_0x56e2c1[_0x4160ec('0x2e')](_0x4160ec('0x9e'),'unreadMessages'),_0x3376eb[_0x4160ec('0xb4')]&&_0x3376eb[_0x4160ec('0xb4')][_0x4160ec('0x21')](function(_0xea52f){const _0x3c053a=_0x4160ec;_0x55b98f[_0x3c053a('0xb4')]('i.'+_0xea52f[0x0],_0xea52f[0x1]==='DESC'?![]:!![]);}),!_['isEmpty'](_0x16201b)&&(_0x55b98f[_0x4160ec('0x7f')](_0x541a5d),_0x56e2c1[_0x4160ec('0xb7')](_0x4160ec('0x8b'),_0x16201b)),Promise[_0x4160ec('0x1d')]()[_0x4160ec('0x3f')](function(){const _0x1a207d=_0x4160ec;if(!_0x1c83d5){if(_0x99e3c7[_0x1a207d('0xa5')]['FaxAccountId']||_0x99e3c7['query'][_0x1a207d('0x4a')])return;_0x56e2c1[_0x1a207d('0xb7')]('i.FaxAccountId\x20IS\x20NOT\x20NULL'),_0x55b98f[_0x1a207d('0xb7')](_0x1a207d('0xa'));return;}return _0x99e3c7[_0x1a207d('0xa7')][_0x1a207d('0x4d')]({'attributes':['id'],'raw':!![]})[_0x1a207d('0x3f')](function(_0x2e6ae7){const _0x480312=_0x1a207d;_[_0x480312('0x18')](_0x2e6ae7)?(_0x56e2c1['where'](_0x480312('0x7e')),_0x55b98f[_0x480312('0xb7')]('i.FaxAccountId\x20IS\x20NULL')):(_0x56e2c1['where']('i.FaxAccountId\x20IN\x20?',_[_0x480312('0xae')](_0x2e6ae7,'id')),_0x55b98f[_0x480312('0xb7')](_0x480312('0x6d'),_[_0x480312('0xae')](_0x2e6ae7,'id')));});})[_0x4160ec('0x3f')](function(){const _0x50ec59=_0x4160ec;db[_0x50ec59('0xaa')][_0x50ec59('0xa5')](_0x56e2c1[_0x50ec59('0xad')](),_0x594661)['then'](function(_0x3d8267){const _0x3dc330=_0x50ec59;_0x49090b[_0x3dc330('0x43')]=_0x3d8267[_0x3dc330('0x28')];if(_0x49090b[_0x3dc330('0x43')]===0x0)return[];return db[_0x3dc330('0xaa')][_0x3dc330('0xa5')](_0xb5c369[_0x3dc330('0xad')](),_0x594661)[_0x3dc330('0x3f')](function(_0x5356b2){const _0x1871f6=_0x3dc330;_0x4c7eca=_[_0x1871f6('0x4')](_0x5356b2,'id'),_0x594661=_[_0x1871f6('0x7d')](_0x594661,{'model':db[_0x1871f6('0x8c')],'mapToModel':!![],'raw':!![],'nest':!![]});_0x99e3c7[_0x1871f6('0xa5')]['fields']?_0x3376eb[_0x1871f6('0xb')][_0x1871f6('0x21')](function(_0x574534){const _0x17c498=_0x1871f6;_0x55b98f[_0x17c498('0x2e')]('i.'+_0x574534);}):(_0x55b98f[_0x1871f6('0x2e')]('SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)',_0x1871f6('0x3a')),_0x55b98f['field'](_0x1871f6('0x94'),_0x1871f6('0x29')),_0x55b98f[_0x1871f6('0x2e')](_0x1871f6('0x11'),_0x1871f6('0x24')),_0x55b98f[_0x1871f6('0x2e')](_0x1871f6('0x9')),_0x55b98f[_0x1871f6('0x2e')](_0x1871f6('0x83'),'Contact.firstName'),_0x55b98f[_0x1871f6('0x2e')](_0x1871f6('0x3e'),_0x1871f6('0x37')),_0x55b98f[_0x1871f6('0x2e')](_0x1871f6('0x6f'),_0x1871f6('0x57')),_0x55b98f[_0x1871f6('0x2e')]('c.phone',_0x1871f6('0x78')),_0x55b98f[_0x1871f6('0x2e')](_0x1871f6('0x9c'),_0x1871f6('0x22')),_0x55b98f['field'](_0x1871f6('0xb8'),_0x1871f6('0xb1')),_0x55b98f[_0x1871f6('0x2e')](_0x1871f6('0x8e'),_0x1871f6('0x68')),_0x55b98f['field']('o.internal','Owner.internal'),_0x55b98f['field']('GROUP_CONCAT(DISTINCT\x20t.id)',_0x1871f6('0xb6')));if(_0x3376eb[_0x1871f6('0x13')])_0x55b98f['limit'](_0x3376eb['limit']);if(_0x3376eb[_0x1871f6('0x35')])_0x55b98f['offset'](_0x3376eb[_0x1871f6('0x35')]);return db[_0x1871f6('0xaa')]['query'](_0x55b98f[_0x1871f6('0xad')](),_0x594661);})[_0x3dc330('0x3f')](function(_0xc0b47){const _0xf92211=_0x3dc330;return _0x4aab1f[_0xf92211('0xb7')](_0xf92211('0x1f'),_[_0xf92211('0xae')](_0xc0b47,'id')),db[_0xf92211('0xaa')][_0xf92211('0xa5')](_0x4aab1f['toString'](),_0x594661)[_0xf92211('0x3f')](function(_0x864b69){const _0x3996d1=_0xf92211,_0x49647e=_[_0x3996d1('0x48')](_0x864b69,'FaxInteractionId'),_0x260d5a=[];return _0xc0b47[_0x3996d1('0x21')](function(_0x39e68f){const _0x17740a=_0x3996d1;_0x260d5a[_0x17740a('0x30')](updateFaxInteraction(_0x39e68f,_0x4c7eca,_0x49647e));}),Promise[_0x3996d1('0x4b')](_0x260d5a);});});})[_0x50ec59('0x3f')](function(_0x5e16a5){return _0x49090b['rows']=_0x5e16a5,_0x49090b;})['then'](respondWithFilteredResult(_0x277233,_0x3376eb));})[_0x4160ec('0x5e')](handleError(_0x277233,null));},exports[_0x41d941('0xba')]=function(_0x1dfafe,_0x1cc50e){const _0x532bf7=_0x41d941;let _0x77df0c={'raw':![],'where':{'id':_0x1dfafe[_0x532bf7('0x6e')]['id']}};const _0x3c7c1c={};return _0x3c7c1c['model']=_['keys'](db['FaxInteraction'][_0x532bf7('0x6c')]),_0x3c7c1c['query']=_[_0x532bf7('0x5')](_0x1dfafe[_0x532bf7('0xa5')]),_0x3c7c1c[_0x532bf7('0x25')]=_[_0x532bf7('0x66')](_0x3c7c1c[_0x532bf7('0x61')],_0x3c7c1c[_0x532bf7('0xa5')]),_0x77df0c[_0x532bf7('0xb')]=_[_0x532bf7('0x66')](_0x3c7c1c['model'],qs[_0x532bf7('0x3d')](_0x1dfafe['query'][_0x532bf7('0x3d')])),_0x77df0c[_0x532bf7('0xb')]=_0x77df0c[_0x532bf7('0xb')][_0x532bf7('0x28')]?_0x77df0c['attributes']:_0x3c7c1c[_0x532bf7('0x61')],_0x1dfafe['query']['includeAll']&&(_0x77df0c['include']=[{'all':!![]}]),_0x77df0c=_[_0x532bf7('0x7d')]({},_0x77df0c,_0x1dfafe[_0x532bf7('0x1a')]),db[_0x532bf7('0x8c')][_0x532bf7('0x2')](_0x77df0c)[_0x532bf7('0x3f')](handleEntityNotFound(_0x1cc50e,null))[_0x532bf7('0x3f')](respondWithResult(_0x1cc50e,null))['catch'](handleError(_0x1cc50e,null));},exports['create']=function(_0x28d3fc,_0x13c886){const _0x4d4d93=_0x41d941;return db[_0x4d4d93('0x8c')][_0x4d4d93('0x79')](_0x28d3fc[_0x4d4d93('0x88')],{})[_0x4d4d93('0x3f')](respondWithResult(_0x13c886,0xc9))[_0x4d4d93('0x5e')](handleError(_0x13c886,null));},exports[_0x41d941('0xc0')]=function(_0x1926c8,_0x362b34){const _0x47f06f=_0x41d941;return _0x1926c8['body']['id']&&delete _0x1926c8[_0x47f06f('0x88')]['id'],db[_0x47f06f('0x8c')][_0x47f06f('0x2')]({'where':{'id':_0x1926c8[_0x47f06f('0x6e')]['id']}})[_0x47f06f('0x3f')](handleEntityNotFound(_0x362b34,null))[_0x47f06f('0x3f')](saveUpdates(_0x1926c8[_0x47f06f('0x88')],null))['then'](respondWithResult(_0x362b34,null))[_0x47f06f('0x5e')](handleError(_0x362b34,null));},exports[_0x41d941('0x0')]=function(_0x54ff84,_0x160456){const _0x449085=_0x41d941;return db['FaxInteraction'][_0x449085('0x2')]({'where':{'id':_0x54ff84[_0x449085('0x6e')]['id']}})[_0x449085('0x3f')](handleEntityNotFound(_0x160456,null))[_0x449085('0x3f')](removeEntity(_0x160456,null))[_0x449085('0x5e')](handleError(_0x160456,null));},exports[_0x41d941('0x69')]=function(_0x5323fa,_0x52bda7){const _0x73d1d3=_0x41d941;return db[_0x73d1d3('0x8c')][_0x73d1d3('0x69')]()['then'](respondWithResult(_0x52bda7,null))[_0x73d1d3('0x5e')](handleError(_0x52bda7,null));},exports[_0x41d941('0x60')]=function(_0xa9a28,_0x2e66fb){const _0x5c1995=_0x41d941;return db[_0x5c1995('0x5f')][_0x5c1995('0x2')]({'where':{'id':_0xa9a28[_0x5c1995('0x6e')]['id']}})[_0x5c1995('0x3f')](function(_0x428890){const _0x322952=_0x5c1995;if(_0x428890)return _0x428890[_0x322952('0x60')](_0xa9a28[_0x322952('0x88')][_0x322952('0x5b')],{'through':_[_0x322952('0x92')](_0xa9a28[_0x322952('0x88')],[_0x322952('0x5b'),'id'])});})['then'](respondWithResult(_0x2e66fb,null))[_0x5c1995('0x5e')](handleError(_0x2e66fb,null));},exports['getMessages']=function(_0x5098e6,_0x4dd855){const _0x17b1db=_0x41d941;let _0x3a9292={'raw':![],'where':{}};const _0x46f2f7={},_0x50b466={'count':0x0,'rows':[]};return db[_0x17b1db('0x8c')]['findOne']({'where':{'id':_0x5098e6['params']['id']}})[_0x17b1db('0x3f')](handleEntityNotFound(_0x4dd855,null))['then'](function(_0x4eea4e){const _0x6bcb45=_0x17b1db;if(_0x4eea4e){_0x46f2f7[_0x6bcb45('0x61')]=_[_0x6bcb45('0x5')](db[_0x6bcb45('0x5f')]['rawAttributes']),_0x46f2f7['query']=_[_0x6bcb45('0x5')](_0x5098e6['query']),_0x46f2f7[_0x6bcb45('0x25')]=_['intersection'](_0x46f2f7[_0x6bcb45('0x61')],_0x46f2f7[_0x6bcb45('0xa5')]),_0x3a9292['attributes']=_['intersection'](_0x46f2f7[_0x6bcb45('0x61')],qs[_0x6bcb45('0x3d')](_0x5098e6[_0x6bcb45('0xa5')][_0x6bcb45('0x3d')])),_0x3a9292[_0x6bcb45('0xb')]=_0x3a9292['attributes']['length']?_0x3a9292[_0x6bcb45('0xb')]:_0x46f2f7[_0x6bcb45('0x61')];typeof _0x5098e6[_0x6bcb45('0xa5')]['nolimit']===_0x6bcb45('0x36')&&(_0x3a9292['limit']=qs['limit'](_0x5098e6[_0x6bcb45('0xa5')][_0x6bcb45('0x13')]),_0x3a9292[_0x6bcb45('0x35')]=qs['offset'](_0x5098e6[_0x6bcb45('0xa5')][_0x6bcb45('0x35')]));_0x3a9292[_0x6bcb45('0xb4')]=qs[_0x6bcb45('0xbd')](_0x5098e6[_0x6bcb45('0xa5')]['sort']),_0x3a9292[_0x6bcb45('0xb7')]=qs[_0x6bcb45('0x25')](_[_0x6bcb45('0x50')](_0x5098e6['query'],_0x46f2f7[_0x6bcb45('0x25')])),_0x3a9292[_0x6bcb45('0xb7')]['FaxInteractionId']=_0x4eea4e['id'];_0x5098e6[_0x6bcb45('0xa5')]['filter']&&(_0x3a9292['where']=_[_0x6bcb45('0x7d')](_0x3a9292['where'],{[Op['or']]:_[_0x6bcb45('0xae')](_0x3a9292[_0x6bcb45('0xb')],function(_0xc23c2){const _0x32b375=_0x6bcb45,_0x209351={};return _0x209351[_0xc23c2]={[Op[_0x32b375('0x42')]]:'%'+_0x5098e6[_0x32b375('0xa5')][_0x32b375('0x4c')]+'%'},_0x209351;})}));if(_0x5098e6['query'][_0x6bcb45('0x91')]){const _0x457c84=_0x5098e6[_0x6bcb45('0xa5')][_0x6bcb45('0x91')][_0x6bcb45('0xa6')](','),_0x24ad5c={};_0x24ad5c[_0x457c84[0x0]]={[Op['gte']]:moment(_0x457c84[0x1])[_0x6bcb45('0x19')](_0x6bcb45('0x7'))},_0x3a9292[_0x6bcb45('0xb7')]=_[_0x6bcb45('0x7d')](_0x3a9292[_0x6bcb45('0xb7')],_0x24ad5c);}return _0x3a9292=_[_0x6bcb45('0x7d')]({},_0x3a9292,_0x5098e6[_0x6bcb45('0x1a')]),db[_0x6bcb45('0x5f')][_0x6bcb45('0x43')]({'where':_0x3a9292['where']})['then'](function(_0x1075c1){const _0x3e05df=_0x6bcb45;return _0x50b466[_0x3e05df('0x43')]=_0x1075c1,_0x5098e6[_0x3e05df('0xa5')][_0x3e05df('0xa1')]&&(_0x3a9292[_0x3e05df('0x75')]=[{'all':!![]}]),db[_0x3e05df('0x5f')]['findAll'](_0x3a9292);})[_0x6bcb45('0x3f')](function(_0x2c95b1){const _0x45dd20=_0x6bcb45;return _0x50b466[_0x45dd20('0xbc')]=_0x2c95b1,_0x50b466;});}})[_0x17b1db('0x3f')](respondWithFilteredResult(_0x4dd855,_0x3a9292))['catch'](handleError(_0x4dd855,null));},exports[_0x41d941('0x39')]=function(_0x59f2a1,_0x5d6a5c){const _0xa465a8=_0x41d941;return db[_0xa465a8('0x8c')]['findOne']({'where':{'id':_0x59f2a1[_0xa465a8('0x6e')]['id']}})['then'](function(_0x1a246a){const _0x226589=_0xa465a8;if(_0x1a246a)return _0x1a246a['setTags'](_0x59f2a1[_0x226589('0x88')][_0x226589('0x5b')],{'through':_['omit'](_0x59f2a1[_0x226589('0x88')],[_0x226589('0x5b'),'id'])})['then'](function(){const _0x2a6371=_0x226589;return db[_0x2a6371('0x3')][_0x2a6371('0xb9')]({'attributes':['id','name',_0x2a6371('0x23')],'where':{'id':_0x59f2a1['body'][_0x2a6371('0x5b')]}});})[_0x226589('0x3f')](function(_0x40b5d6){const _0xfac171=_0x226589;return socket[_0xfac171('0x4e')](_0xfac171('0x5a'),{'id':Number(_0x59f2a1[_0xfac171('0x6e')]['id']),'tags':_0x40b5d6||[]}),{'id':Number(_0x59f2a1[_0xfac171('0x6e')]['id']),'tags':_0x40b5d6||[]};});})[_0xa465a8('0x3f')](respondWithResult(_0x5d6a5c,null))[_0xa465a8('0x5e')](handleError(_0x5d6a5c,null));},exports[_0x41d941('0x2d')]=function(_0x554459,_0x1d5454){const _0x3b5ccd=_0x41d941;return db['FaxInteraction'][_0x3b5ccd('0x2')]({'where':{'id':_0x554459[_0x3b5ccd('0x6e')]['id']}})[_0x3b5ccd('0x3f')](handleEntityNotFound(_0x1d5454,null))['then'](function(_0x18605f){const _0x4dd987=_0x3b5ccd;if(_0x18605f)return _0x18605f[_0x4dd987('0x2d')](_0x554459['query'][_0x4dd987('0x5b')]);})[_0x3b5ccd('0x3f')](respondWithStatusCode(_0x1d5454,null))[_0x3b5ccd('0x5e')](handleError(_0x1d5454,null));},exports['download']=function(_0x46c2f5,_0x4c015e){const _0x44d7ce=_0x41d941,_0x4cfe9f=moment()[_0x44d7ce('0x38')]()[_0x44d7ce('0xad')](),_0x538f58=path['join'](config['root'],_0x44d7ce('0xf'),_0x44d7ce('0x52')),_0x5ce0a2=path[_0x44d7ce('0x41')](config['root'],_0x44d7ce('0x6'),_0x44d7ce('0xf'),_0x44d7ce('0x73')),_0x12f13c=path['join'](_0x538f58,_0x4cfe9f),_0x4b3d9a=util[_0x44d7ce('0x19')]('transcript-%d-%s.zip',_0x46c2f5[_0x44d7ce('0x6e')]['id'],_0x4cfe9f),_0xfb08e3=path[_0x44d7ce('0x41')](_0x538f58,_0x4b3d9a),_0x2f9fdc=[];_0x2f9fdc[_0x44d7ce('0x30')]({'model':db[_0x44d7ce('0x1b')],'as':_0x44d7ce('0x1b'),'raw':!![]});const _0x112f32=[{'model':db[_0x44d7ce('0x5f')],'as':_0x44d7ce('0x33'),'attributes':['id',_0x44d7ce('0x88'),_0x44d7ce('0x5c')],'include':_0x2f9fdc}];return db[_0x44d7ce('0x8c')][_0x44d7ce('0x2')]({'where':{'id':_0x46c2f5[_0x44d7ce('0x6e')]['id']},'include':_0x112f32})[_0x44d7ce('0x3f')](handleEntityNotFound(_0x4c015e,null))[_0x44d7ce('0x3f')](function(_0x58b354){const _0x43ecc5=_0x44d7ce;if(_0x58b354&&_0x58b354['Messages']){const _0x266c20=_0x58b354[_0x43ecc5('0x90')]({'plain':!![]});fs['mkdirSync'](_0x12f13c);for(let _0x4c1fe8=0x0;_0x4c1fe8<_0x266c20['Messages'][_0x43ecc5('0x28')];_0x4c1fe8++){const _0x3899c5=_0x266c20['Messages'][_0x4c1fe8][_0x43ecc5('0x1b')];if(_0x3899c5){const _0x2edc24=path[_0x43ecc5('0x41')](_0x5ce0a2,_0x3899c5[_0x43ecc5('0x70')]);fs[_0x43ecc5('0x9d')](_0x2edc24)&&fs[_0x43ecc5('0x80')](_0x2edc24)[_0x43ecc5('0x74')](fs[_0x43ecc5('0x49')](path[_0x43ecc5('0x41')](_0x12f13c,_0x3899c5[_0x43ecc5('0x70')])));}}return Promise[_0x43ecc5('0x1d')]()['then'](function(){const _0x1d5a6e=_0x43ecc5;return new Promise(function(_0x1bc592,_0x2d3480){zipdir(_0x12f13c,{'saveTo':_0xfb08e3},function(_0x4272bd,_0x9c3c69){if(_0x4272bd)return _0x2d3480(_0x4272bd);return _0x1bc592(_0x9c3c69);});})[_0x1d5a6e('0x3f')](function(){return new Promise(function(_0x426897,_0xd7e5ee){rimraf(_0x12f13c,function(_0x53a370){if(_0x53a370)_0xd7e5ee(_0x53a370);return _0x426897();});});})[_0x1d5a6e('0x3f')](function(){const _0x4c3da7=_0x1d5a6e;return _0x4c015e[_0x4c3da7('0x27')](_0xfb08e3,_0x4b3d9a,function(_0x1044e2){const _0x999182=_0x4c3da7;_0x1044e2?console[_0x999182('0x8f')](_0x999182('0xc'),_0x1044e2):fs[_0x999182('0x63')](_0xfb08e3);});});});}else return _0x4c015e['sendStatus'](0xc8);})['catch'](handleError(_0x4c015e,null));}; \ No newline at end of file +const a198_0x404d=['parseSearch','\x27\x27\x27\x27','nolimit','TagIds','Content-Range','group','Contact.email','\x20IS\x20NULL','stack','rows','value','i.id\x20LIKE\x20?','sqlOperator','FaxInteraction','catch','getFaxAccounts','`unreadMessages`\x20>\x200','GROUP_CONCAT(DISTINCT\x20t.id)','keyBy','tools_tags','color','pick','ContactId','DESC','destroy','conditions','user','intersection','model','$gte','forEach','tag','show','users','tmp','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','root','select','c.email','existsSync','resolve','split','set','search','addTags','zip-dir','sequelize','`unreadMessages`\x20=\x200','sort','keys','cm_contacts','read','body','includeAll','Contact.lastName','lodash','offset','emit','getMessages','fax_messages','replace','addMessage','rimraf','rawAttributes','ids','squel','files','end','basename','c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?','omit','createReadStream','options','order','journey','fax_accounts','clone','user_has_fax_interactions','like','UserId','Attachment','buildExpression','../../components/parsers/qs','c.phone','QueryTypes','where','filter','send','../../components/parsers/advancedSearch','FaxMessage','unix','name','FaxInteractionId','status','params','index','all','`\x20=\x200','push','Messages','i.FaxAccountId\x20IS\x20NOT\x20NULL','include','error','attributes','Contact','Tag','expr','map','User','path','fieldName','api','from','parse','Owner.fullname','i.FaxAccountId\x20IS\x20NULL','length','operator','Users','./faxInteraction.socket','start','Tags','isEmpty','i.id','toString','u.fullname','register','compact','merge','having','text','Contact.fax','o.id\x20=\x20i.UserId','query','type','describe','\x20=\x20?','filters','left_join','faxInteractionTags:save','SELECT','gte','find','../../config/logger','undefined','format','Account.mandatoryDisposition','pipe','removeTags','update','field','then','sendStatus','join','../../mysqldb','FaxAccountId','count','t.id\x20IN\x20?','findOne','../../config/environment','fields','../../rediscache','a.mandatoryDisposition','download','i.FaxAccountId\x20IN\x20?','c.mobile','a.id\x20=\x20i.FaxAccountId','server','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','$substring','`\x20>\x200','log','ui.FaxInteractionId','err','Contact.firstName','YYYY-MM-DD\x20HH:mm:ss','unreadMessages','fax_interaction_has_tags','ui.FaxInteractionId\x20IN\x20?','some','t.id\x20=\x20it.TagId','createdAt','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL','limit','null','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','me.FaxInteractionId\x20=\x20i.id','transcript-%d-%s.zip','i.createdAt\x20BETWEEN\x20?\x20AND\x20?'];(function(_0x4aa101,_0x404d28){const _0x4c8c92=function(_0x1a003f){while(--_0x1a003f){_0x4aa101['push'](_0x4aa101['shift']());}};_0x4c8c92(++_0x404d28);}(a198_0x404d,0x10d));const a198_0x4c8c=function(_0x4aa101,_0x404d28){_0x4aa101=_0x4aa101-0x0;let _0x4c8c92=a198_0x404d[_0x4aa101];return _0x4c8c92;};const _0x2c1268=a198_0x4c8c;'use strict';const rimraf=require(_0x2c1268('0xab')),zipdir=require(_0x2c1268('0x9a')),moment=require('moment'),util=require('util'),path=require(_0x2c1268('0x1d')),fs=require('fs'),_=require(_0x2c1268('0xa4')),squel=require(_0x2c1268('0xae')),{getSocket}=require(_0x2c1268('0x51')),socket=getSocket(),qs=require(_0x2c1268('0x2')),as=require(_0x2c1268('0x8')),logger=require(_0x2c1268('0x3f'))(_0x2c1268('0x1f')),config=require(_0x2c1268('0x4f')),db=require(_0x2c1268('0x4a'))['db'],{Op}=require(_0x2c1268('0x9b'));require(_0x2c1268('0x27'))[_0x2c1268('0x2e')](socket);function respondWithStatusCode(_0x1a003f,_0xd285c2){return _0xd285c2=_0xd285c2||0xcc,function(_0x3d2aaf){const _0x59832c=a198_0x4c8c;if(_0x3d2aaf)return _0x1a003f[_0x59832c('0x48')](_0xd285c2);return _0x1a003f['status'](_0xd285c2)['end']();};}function respondWithResult(_0xb1e91b,_0x59a442){return _0x59a442=_0x59a442||0xc8,function(_0x290f78){const _0x30b3ac=a198_0x4c8c;if(_0x290f78)return _0xb1e91b[_0x30b3ac('0xd')](_0x59a442)['json'](_0x290f78);};}function respondWithFilteredResult(_0x214981,_0x31dc37){return function(_0x5622c9){const _0x3b158c=a198_0x4c8c;if(_0x5622c9){const _0x16e15a=_0x5622c9[_0x3b158c('0x4c')],_0x2bc4a5=_0x31dc37['offset'];let _0x5c8a17=_0x31dc37['offset']+_0x31dc37[_0x3b158c('0x67')],_0x239c8e;return _0x5c8a17>=_0x16e15a?(_0x5c8a17=_0x16e15a,_0x239c8e=0xc8):_0x239c8e=0xce,_0x214981[_0x3b158c('0xd')](_0x239c8e),_0x214981[_0x3b158c('0x97')](_0x3b158c('0x71'),_0x2bc4a5+'-'+_0x5c8a17+'/'+_0x16e15a)['json'](_0x5622c9);}return null;};}function saveUpdates(_0x2224ee){return function(_0x1eca16){const _0x1f5a35=a198_0x4c8c;if(_0x1eca16)return _0x1eca16[_0x1f5a35('0x45')](_0x2224ee)['then'](function(_0x21d58c){return _0x21d58c;});return null;};}function removeEntity(_0x1beee9){return function(_0x18d6b7){const _0xfceb40=a198_0x4c8c;if(_0x18d6b7)return _0x18d6b7[_0xfceb40('0x85')]()[_0xfceb40('0x47')](function(){const _0x3f740a=_0xfceb40;_0x1beee9[_0x3f740a('0xd')](0xcc)[_0x3f740a('0xb0')]();});};}function handleEntityNotFound(_0x2f74b8){return function(_0x5d4429){const _0x2709b8=a198_0x4c8c;return!_0x5d4429&&_0x2f74b8[_0x2709b8('0x48')](0x194),_0x5d4429;};}function handleError(_0x57bbd8,_0x3913a3){return _0x3913a3=_0x3913a3||0x1f4,function(_0x315aad){const _0x2e59dc=a198_0x4c8c;logger[_0x2e59dc('0x16')](_0x315aad[_0x2e59dc('0x75')]),_0x315aad[_0x2e59dc('0xb')]&&delete _0x315aad['name'],_0x57bbd8[_0x2e59dc('0xd')](_0x3913a3)[_0x2e59dc('0x7')](_0x315aad);};}function getInteractionUsers(_0x34d2d0,_0x78617a){return new Promise(function(_0xd3ab0e,_0x445ce2){const _0x34e36a=a198_0x4c8c;try{_0x78617a[_0x34d2d0['id']]&&(_0x34d2d0[_0x34e36a('0x26')]=_[_0x34e36a('0x1b')](_0x78617a[_0x34d2d0['id']],function(_0x3f4a99){return{'id':_0x3f4a99['id'],'fullname':_0x3f4a99['fullname']};}));}catch(_0x3932ca){_0x445ce2(_0x3932ca);}_0xd3ab0e(_0x34d2d0);});}function getInteractionTags(_0x30a5e7,_0x1821f8){return new Promise(function(_0x35ef0b,_0x252850){const _0x2031d5=a198_0x4c8c;try{_0x30a5e7[_0x2031d5('0x70')]&&(_0x30a5e7[_0x2031d5('0x29')]=[],_0x30a5e7[_0x2031d5('0x70')][_0x2031d5('0x96')](',')[_0x2031d5('0x8b')](function(_0x539c1a){const _0x1b44d5=_0x2031d5;_0x30a5e7['Tags'][_0x1b44d5('0x12')](_0x1821f8[_0x539c1a]);})),delete _0x30a5e7[_0x2031d5('0x70')];}catch(_0x1cb8c2){_0x252850(_0x1cb8c2);}_0x35ef0b(_0x30a5e7);});}function updateFaxInteraction(_0x50d9d1,_0x41a5c7,_0x2c71fc){return new Promise(function(_0x308e1d,_0x359509){const _0x26a8ca=a198_0x4c8c;return getInteractionUsers(_0x50d9d1,_0x2c71fc)[_0x26a8ca('0x47')](function(_0x61e4c){return getInteractionTags(_0x61e4c,_0x41a5c7);})[_0x26a8ca('0x47')](function(_0x322368){_0x308e1d(_0x322368);})[_0x26a8ca('0x7b')](function(_0x3a5498){_0x359509(_0x3a5498);});});}exports[_0x2c1268('0xf')]=function(_0x541a80,_0x25b2ba){const _0x27e3db=_0x2c1268,_0x6e4c97={},_0x5d17d4={},_0x1d9f64={'count':0x0,'rows':[]},_0x5b59d1=_[_0x27e3db('0x1b')](db[_0x27e3db('0x7a')][_0x27e3db('0xac')],function(_0x5b8c90){const _0x9b3e6b=_0x27e3db;return{'name':_0x5b8c90[_0x9b3e6b('0x1e')],'type':_0x5b8c90[_0x9b3e6b('0x36')]['key']};});_0x5d17d4[_0x27e3db('0x89')]=_['map'](_0x5b59d1,_0x27e3db('0xb')),_0x5d17d4[_0x27e3db('0x35')]=_['keys'](_0x541a80[_0x27e3db('0x35')]),_0x5d17d4[_0x27e3db('0x39')]=_[_0x27e3db('0x88')](_0x5d17d4[_0x27e3db('0x89')],_0x5d17d4[_0x27e3db('0x35')]),_0x6e4c97[_0x27e3db('0x17')]=_[_0x27e3db('0x88')](_0x5d17d4[_0x27e3db('0x89')],qs['fields'](_0x541a80[_0x27e3db('0x35')][_0x27e3db('0x50')])),_0x6e4c97[_0x27e3db('0x17')]=_0x6e4c97['attributes'][_0x27e3db('0x24')]?_0x6e4c97[_0x27e3db('0x17')]:_0x5d17d4[_0x27e3db('0x89')];typeof _0x541a80[_0x27e3db('0x35')][_0x27e3db('0x6f')]===_0x27e3db('0x40')&&(_0x6e4c97[_0x27e3db('0x67')]=qs[_0x27e3db('0x67')](_0x541a80['query'][_0x27e3db('0x67')]),_0x6e4c97[_0x27e3db('0xa5')]=qs[_0x27e3db('0xa5')](_0x541a80[_0x27e3db('0x35')][_0x27e3db('0xa5')]));_0x6e4c97[_0x27e3db('0xb6')]=qs[_0x27e3db('0x9d')](_0x541a80[_0x27e3db('0x35')][_0x27e3db('0x9d')]),_0x6e4c97[_0x27e3db('0x5')]=qs[_0x27e3db('0x39')](_[_0x27e3db('0x82')](_0x541a80[_0x27e3db('0x35')],_0x5d17d4[_0x27e3db('0x39')]),_0x5b59d1);let _0x36bcba=[];const _0x334678=squel[_0x27e3db('0x92')]()[_0x27e3db('0x46')]('id')[_0x27e3db('0x46')]('name')['field'](_0x27e3db('0x81'))[_0x27e3db('0x20')](_0x27e3db('0x80')),_0x458fd4=squel[_0x27e3db('0x92')]()[_0x27e3db('0x46')]('u.id')['field'](_0x27e3db('0x2d'))[_0x27e3db('0x46')](_0x27e3db('0x5c'))['from'](_0x27e3db('0xba'),'ui')[_0x27e3db('0x3a')](_0x27e3db('0x8e'),'u','u.id\x20=\x20ui.UserId'),_0x490991=squel['select']()[_0x27e3db('0x20')]('fax_interactions','i')[_0x27e3db('0x3a')](_0x27e3db('0x9f'),'c',_0x27e3db('0x66'))[_0x27e3db('0x3a')]('users','o',_0x27e3db('0x34'))[_0x27e3db('0x3a')](_0x27e3db('0xb8'),'a',_0x27e3db('0x56'))['left_join'](_0x27e3db('0xa8'),'me',_0x27e3db('0x6a'))[_0x27e3db('0x3a')](_0x27e3db('0x61'),'it','it.FaxInteractionId\x20=\x20i.id')[_0x27e3db('0x3a')](_0x27e3db('0x80'),'t',_0x27e3db('0x64')),_0x36732b=squel[_0x27e3db('0x1a')]();let _0x27f9f9=[];const _0xb31e3b=squel[_0x27e3db('0x1a')]();let _0x576cf2;if(_0x541a80[_0x27e3db('0x35')][_0x27e3db('0x98')]){_0x576cf2=as[_0x27e3db('0x6d')](_0x541a80[_0x27e3db('0x35')][_0x27e3db('0x98')]);const _0x3c5a50=_0x576cf2[_0x27e3db('0x79')];for(let _0x7aa93f=0x0;_0x7aa93f<_0x576cf2[_0x27e3db('0x86')][_0x27e3db('0x24')];_0x7aa93f++){const _0x296165=_0x576cf2[_0x27e3db('0x86')][_0x7aa93f],_0x30a218='i';let _0x14c51f,_0x5dd864=_[_0x27e3db('0x3e')](_0x5b59d1,[_0x27e3db('0xb'),_0x296165[_0x27e3db('0x46')]]);if(!_0x5dd864)switch(_0x296165[_0x27e3db('0x46')]){case _0x27e3db('0x60'):_0x296165[_0x27e3db('0x77')]==0x1?_0x490991[_0x27e3db('0x31')]('`'+_0x296165[_0x27e3db('0x46')]+_0x27e3db('0x11')):_0x490991[_0x27e3db('0x31')]('`'+_0x296165[_0x27e3db('0x46')]+_0x27e3db('0x5a'));break;case _0x27e3db('0x18'):if(_0x296165[_0x27e3db('0x25')]===_0x27e3db('0x59')){if(_0x296165[_0x27e3db('0x77')]['split']('\x20')[_0x27e3db('0x24')]>0x1)_0x36732b[_0x3c5a50]('MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs['getFullTextValue'](_0x296165['value']),null);else{const _0x9940fc='%'+_0x296165[_0x27e3db('0x77')]+'%';_0x36732b[_0x3c5a50](_0x27e3db('0xb2'),_0x9940fc,_0x9940fc,_0x9940fc);}}else _0x5dd864=_[_0x27e3db('0x3e')](_0x5b59d1,[_0x27e3db('0xb'),_0x27e3db('0x83')]),_0x296165[_0x27e3db('0x46')]=_0x27e3db('0x83'),_0x14c51f=as['buildExpression'](_0x30a218,_0x5dd864[_0x27e3db('0x36')],_0x296165),_0x36732b[_0x3c5a50](_0x14c51f[_0x27e3db('0x32')],_0x14c51f[_0x27e3db('0x77')][_0x27e3db('0x28')],_0x14c51f[_0x27e3db('0x77')]['end']);break;case _0x27e3db('0x19'):{const _0x2fe57b=_0x296165[_0x27e3db('0x77')][_0x27e3db('0x96')](',')[_0x27e3db('0x1b')](function(_0x1a2c30){return Number(_0x1a2c30);});_0x2fe57b[_0x27e3db('0x8b')](function(_0x2ba2de){const _0x66d725=_0x27e3db;_0xb31e3b['or'](_0x66d725('0x58'),'%,'+_0x2ba2de+',%');}),_0x27f9f9=_['union'](_0x27f9f9,_0x2fe57b);}break;case _0x27e3db('0x1c'):_0x296165['operator']===_0x27e3db('0x59')?_0x36732b[_0x3c5a50](_0x27e3db('0x69'),'%'+_0x296165[_0x27e3db('0x77')]+'%',null):(_0x5dd864=_[_0x27e3db('0x3e')](_0x5b59d1,[_0x27e3db('0xb'),_0x27e3db('0xbc')]),_0x296165['field']=_0x27e3db('0xbc'),_0x14c51f=as['buildExpression'](_0x30a218,_0x5dd864['type'],_0x296165),_0x36732b[_0x3c5a50](_0x14c51f[_0x27e3db('0x32')],_0x14c51f[_0x27e3db('0x77')]['start'],_0x14c51f['value'][_0x27e3db('0xb0')]));break;case _0x27e3db('0xa1'):_0x14c51f=as[_0x27e3db('0x1')]('me',null,_0x296165),_0x36732b[_0x3c5a50](_0x14c51f['text'],_0x14c51f['value'][_0x27e3db('0x28')],_0x14c51f['value']['end']);break;}else _0x14c51f=as[_0x27e3db('0x1')](_0x30a218,_0x5dd864[_0x27e3db('0x36')],_0x296165),_0x36732b[_0x3c5a50](_0x14c51f[_0x27e3db('0x32')],_0x14c51f[_0x27e3db('0x77')][_0x27e3db('0x28')],_0x14c51f[_0x27e3db('0x77')][_0x27e3db('0xb0')]);}}else{const _0x1183a7=_(_0x541a80[_0x27e3db('0x35')])[_0x27e3db('0x9e')]()[_0x27e3db('0x1b')](function(_0x420c94){const _0x167825=_0x27e3db;return _[_0x167825('0x63')](_0x5b59d1,[_0x167825('0xb'),_0x420c94])?_0x420c94:undefined;})[_0x27e3db('0x2f')]()[_0x27e3db('0x77')]();!_[_0x27e3db('0x2a')](_0x1183a7)&&_0x1183a7[_0x27e3db('0x8b')](function(_0x2a909d){const _0x19e793=_0x27e3db;if(_0x2a909d===_0x19e793('0x4b'))_0x490991[_0x19e793('0x5')](_0x19e793('0x54'),[]['concat'](_0x541a80['query'][_0x2a909d]));else{if(_0x2a909d==='createdAt'){const _0x1a4228=JSON[_0x19e793('0x21')](_0x541a80['query'][_0x2a909d])[_0x19e793('0x8a')],_0x6304d4=JSON['parse'](_0x541a80[_0x19e793('0x35')][_0x2a909d])['$lte'];_0x490991['where'](_0x19e793('0x6c'),_0x1a4228,_0x6304d4);}else _0x541a80[_0x19e793('0x35')][_0x2a909d]===_0x19e793('0x68')?_0x490991[_0x19e793('0x5')]('i.'+_0x2a909d+_0x19e793('0x74')):_0x490991[_0x19e793('0x5')]('i.'+_0x2a909d+_0x19e793('0x38'),_0x541a80[_0x19e793('0x35')][_0x2a909d]);}});_0x541a80['query'][_0x27e3db('0xa0')]&&(_0x541a80[_0x27e3db('0x35')][_0x27e3db('0xa0')]==0x1?_0x490991[_0x27e3db('0x31')](_0x27e3db('0x9c')):_0x490991['having'](_0x27e3db('0x7d')));_0x541a80[_0x27e3db('0x35')][_0x27e3db('0x8c')]&&(_0x27f9f9=_['isArray'](_0x541a80[_0x27e3db('0x35')][_0x27e3db('0x8c')])?_0x541a80[_0x27e3db('0x35')]['tag']:new Array(_0x541a80[_0x27e3db('0x35')][_0x27e3db('0x8c')]),_0x27f9f9[_0x27e3db('0x8b')](function(_0x7e51f3){_0xb31e3b['or']('CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','%,'+_0x7e51f3+',%');}));if(_0x541a80[_0x27e3db('0x35')][_0x27e3db('0x6')]){const _0x51a9a9=_0x541a80[_0x27e3db('0x35')][_0x27e3db('0x6')][_0x27e3db('0xa9')]('\x5c','\x5c\x5c')[_0x27e3db('0xa9')]('\x27\x27',_0x27e3db('0x6e'));qs['isNumeric'](_0x51a9a9)&&_0x36732b['or'](_0x27e3db('0x78'),_0x51a9a9+'%')['or']('i.fax\x20LIKE\x20?',_0x51a9a9+'%'),_0x36732b['or']('CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?',_0x51a9a9+'%');}}_0x490991[_0x27e3db('0x5')](_0x36732b),_0x490991[_0x27e3db('0x72')](_0x27e3db('0x2b'));let _0x175def={'type':db['Sequelize'][_0x27e3db('0x4')][_0x27e3db('0x3c')],'raw':!![]};const _0x44858c=_0x490991[_0x27e3db('0xb9')]();_0x44858c[_0x27e3db('0x46')](_0x27e3db('0x2b')),_0x44858c[_0x27e3db('0x46')]('SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)',_0x27e3db('0x60')),_0x6e4c97[_0x27e3db('0xb6')]&&_0x6e4c97[_0x27e3db('0xb6')]['forEach'](function(_0x57640a){const _0x43d6c3=_0x27e3db;_0x490991[_0x43d6c3('0xb6')]('i.'+_0x57640a[0x0],_0x57640a[0x1]===_0x43d6c3('0x84')?![]:!![]);}),!_[_0x27e3db('0x2a')](_0x27f9f9)&&(_0x490991[_0x27e3db('0x31')](_0xb31e3b),_0x44858c[_0x27e3db('0x5')](_0x27e3db('0x4d'),_0x27f9f9)),Promise['resolve']()[_0x27e3db('0x47')](function(){const _0x488b37=_0x27e3db;if(!_0x576cf2){if(_0x541a80['query'][_0x488b37('0x4b')]||_0x541a80['query'][_0x488b37('0xb7')])return;_0x44858c[_0x488b37('0x5')](_0x488b37('0x14')),_0x490991['where']('i.FaxAccountId\x20IS\x20NOT\x20NULL');return;}return _0x541a80[_0x488b37('0x87')][_0x488b37('0x7c')]({'attributes':['id'],'raw':!![]})['then'](function(_0x508d66){const _0x5852a4=_0x488b37;_['isEmpty'](_0x508d66)?(_0x44858c[_0x5852a4('0x5')]('i.FaxAccountId\x20IS\x20NULL'),_0x490991[_0x5852a4('0x5')](_0x5852a4('0x23'))):(_0x44858c[_0x5852a4('0x5')](_0x5852a4('0x54'),_['map'](_0x508d66,'id')),_0x490991[_0x5852a4('0x5')]('i.FaxAccountId\x20IN\x20?',_[_0x5852a4('0x1b')](_0x508d66,'id')));});})[_0x27e3db('0x47')](function(){const _0x44cbab=_0x27e3db;db['sequelize'][_0x44cbab('0x35')](_0x44858c[_0x44cbab('0x2c')](),_0x175def)[_0x44cbab('0x47')](function(_0x2fcdb9){const _0x5deff7=_0x44cbab;_0x1d9f64[_0x5deff7('0x4c')]=_0x2fcdb9[_0x5deff7('0x24')];if(_0x1d9f64[_0x5deff7('0x4c')]===0x0)return[];return db[_0x5deff7('0x9b')]['query'](_0x334678[_0x5deff7('0x2c')](),_0x175def)[_0x5deff7('0x47')](function(_0xaff88d){const _0x54099b=_0x5deff7;_0x36bcba=_[_0x54099b('0x7f')](_0xaff88d,'id'),_0x175def=_[_0x54099b('0x30')](_0x175def,{'model':db['FaxInteraction'],'mapToModel':!![],'raw':!![],'nest':!![]});_0x541a80[_0x54099b('0x35')]['fields']?_0x6e4c97['attributes'][_0x54099b('0x8b')](function(_0x74518f){_0x490991['field']('i.'+_0x74518f);}):(_0x490991[_0x54099b('0x46')](_0x54099b('0x90'),_0x54099b('0x60')),_0x490991[_0x54099b('0x46')]('a.key','Account.key'),_0x490991[_0x54099b('0x46')](_0x54099b('0x52'),_0x54099b('0x42')),_0x490991['field']('i.*'),_0x490991[_0x54099b('0x46')]('c.firstName',_0x54099b('0x5e')),_0x490991[_0x54099b('0x46')]('c.lastName',_0x54099b('0xa3')),_0x490991[_0x54099b('0x46')](_0x54099b('0x93'),_0x54099b('0x73')),_0x490991[_0x54099b('0x46')](_0x54099b('0x3'),'Contact.phone'),_0x490991[_0x54099b('0x46')](_0x54099b('0x55'),'Contact.mobile'),_0x490991[_0x54099b('0x46')]('c.fax',_0x54099b('0x33')),_0x490991['field']('o.fullname',_0x54099b('0x22')),_0x490991[_0x54099b('0x46')]('o.internal','Owner.internal'),_0x490991[_0x54099b('0x46')](_0x54099b('0x7e'),'TagIds'));if(_0x6e4c97[_0x54099b('0x67')])_0x490991['limit'](_0x6e4c97[_0x54099b('0x67')]);if(_0x6e4c97[_0x54099b('0xa5')])_0x490991[_0x54099b('0xa5')](_0x6e4c97[_0x54099b('0xa5')]);return db['sequelize'][_0x54099b('0x35')](_0x490991[_0x54099b('0x2c')](),_0x175def);})['then'](function(_0x4f6b21){const _0x79e81b=_0x5deff7;return _0x458fd4['where'](_0x79e81b('0x62'),_[_0x79e81b('0x1b')](_0x4f6b21,'id')),db[_0x79e81b('0x9b')]['query'](_0x458fd4[_0x79e81b('0x2c')](),_0x175def)['then'](function(_0x58fa5a){const _0x248f5e=_0x79e81b,_0x103628=_['groupBy'](_0x58fa5a,'FaxInteractionId'),_0x337eda=[];return _0x4f6b21[_0x248f5e('0x8b')](function(_0x101cdd){const _0x2e3024=_0x248f5e;_0x337eda[_0x2e3024('0x12')](updateFaxInteraction(_0x101cdd,_0x36bcba,_0x103628));}),Promise[_0x248f5e('0x10')](_0x337eda);});});})['then'](function(_0x4902a4){const _0x404fa4=_0x44cbab;return _0x1d9f64[_0x404fa4('0x76')]=_0x4902a4,_0x1d9f64;})[_0x44cbab('0x47')](respondWithFilteredResult(_0x25b2ba,_0x6e4c97));})[_0x27e3db('0x7b')](handleError(_0x25b2ba,null));},exports[_0x2c1268('0x8d')]=function(_0x1332f7,_0x4b09dd){const _0x54168c=_0x2c1268;let _0x3ebc34={'raw':![],'where':{'id':_0x1332f7['params']['id']}};const _0x44d6d4={};return _0x44d6d4['model']=_['keys'](db[_0x54168c('0x7a')]['rawAttributes']),_0x44d6d4[_0x54168c('0x35')]=_[_0x54168c('0x9e')](_0x1332f7['query']),_0x44d6d4[_0x54168c('0x39')]=_[_0x54168c('0x88')](_0x44d6d4[_0x54168c('0x89')],_0x44d6d4[_0x54168c('0x35')]),_0x3ebc34[_0x54168c('0x17')]=_['intersection'](_0x44d6d4[_0x54168c('0x89')],qs[_0x54168c('0x50')](_0x1332f7[_0x54168c('0x35')][_0x54168c('0x50')])),_0x3ebc34[_0x54168c('0x17')]=_0x3ebc34['attributes'][_0x54168c('0x24')]?_0x3ebc34[_0x54168c('0x17')]:_0x44d6d4[_0x54168c('0x89')],_0x1332f7['query'][_0x54168c('0xa2')]&&(_0x3ebc34[_0x54168c('0x15')]=[{'all':!![]}]),_0x3ebc34=_[_0x54168c('0x30')]({},_0x3ebc34,_0x1332f7[_0x54168c('0xb5')]),db['FaxInteraction'][_0x54168c('0x4e')](_0x3ebc34)[_0x54168c('0x47')](handleEntityNotFound(_0x4b09dd,null))[_0x54168c('0x47')](respondWithResult(_0x4b09dd,null))[_0x54168c('0x7b')](handleError(_0x4b09dd,null));},exports['create']=function(_0x43ac0b,_0x21a299){const _0x42400f=_0x2c1268;return db['FaxInteraction']['create'](_0x43ac0b[_0x42400f('0xa1')],{})['then'](respondWithResult(_0x21a299,0xc9))[_0x42400f('0x7b')](handleError(_0x21a299,null));},exports[_0x2c1268('0x45')]=function(_0x330133,_0x348643){const _0x3e6a31=_0x2c1268;return _0x330133[_0x3e6a31('0xa1')]['id']&&delete _0x330133[_0x3e6a31('0xa1')]['id'],db['FaxInteraction']['findOne']({'where':{'id':_0x330133[_0x3e6a31('0xe')]['id']}})[_0x3e6a31('0x47')](handleEntityNotFound(_0x348643,null))[_0x3e6a31('0x47')](saveUpdates(_0x330133[_0x3e6a31('0xa1')],null))['then'](respondWithResult(_0x348643,null))[_0x3e6a31('0x7b')](handleError(_0x348643,null));},exports['destroy']=function(_0x4f00ac,_0x1df03c){const _0x389601=_0x2c1268;return db['FaxInteraction']['findOne']({'where':{'id':_0x4f00ac['params']['id']}})[_0x389601('0x47')](handleEntityNotFound(_0x1df03c,null))[_0x389601('0x47')](removeEntity(_0x1df03c,null))[_0x389601('0x7b')](handleError(_0x1df03c,null));},exports[_0x2c1268('0x37')]=function(_0x15ffe1,_0x50c36b){const _0x3cc436=_0x2c1268;return db[_0x3cc436('0x7a')]['describe']()[_0x3cc436('0x47')](respondWithResult(_0x50c36b,null))[_0x3cc436('0x7b')](handleError(_0x50c36b,null));},exports[_0x2c1268('0xaa')]=function(_0x55c1c,_0x2aafba){const _0xaa3576=_0x2c1268;return db[_0xaa3576('0x9')][_0xaa3576('0x4e')]({'where':{'id':_0x55c1c['params']['id']}})['then'](function(_0x14ef70){const _0x80d3b6=_0xaa3576;if(_0x14ef70)return _0x14ef70[_0x80d3b6('0xaa')](_0x55c1c[_0x80d3b6('0xa1')][_0x80d3b6('0xad')],{'through':_[_0x80d3b6('0xb3')](_0x55c1c[_0x80d3b6('0xa1')],[_0x80d3b6('0xad'),'id'])});})[_0xaa3576('0x47')](respondWithResult(_0x2aafba,null))[_0xaa3576('0x7b')](handleError(_0x2aafba,null));},exports[_0x2c1268('0xa7')]=function(_0x484f3b,_0x2cb678){const _0x56b34e=_0x2c1268;let _0x4d00fe={'raw':![],'where':{}};const _0x2829c4={},_0x4e7d1c={'count':0x0,'rows':[]};return db[_0x56b34e('0x7a')][_0x56b34e('0x4e')]({'where':{'id':_0x484f3b[_0x56b34e('0xe')]['id']}})['then'](handleEntityNotFound(_0x2cb678,null))[_0x56b34e('0x47')](function(_0x4ee05d){const _0x363757=_0x56b34e;if(_0x4ee05d){_0x2829c4[_0x363757('0x89')]=_[_0x363757('0x9e')](db['FaxMessage'][_0x363757('0xac')]),_0x2829c4['query']=_[_0x363757('0x9e')](_0x484f3b[_0x363757('0x35')]),_0x2829c4[_0x363757('0x39')]=_[_0x363757('0x88')](_0x2829c4[_0x363757('0x89')],_0x2829c4[_0x363757('0x35')]),_0x4d00fe[_0x363757('0x17')]=_[_0x363757('0x88')](_0x2829c4['model'],qs[_0x363757('0x50')](_0x484f3b[_0x363757('0x35')][_0x363757('0x50')])),_0x4d00fe[_0x363757('0x17')]=_0x4d00fe[_0x363757('0x17')][_0x363757('0x24')]?_0x4d00fe[_0x363757('0x17')]:_0x2829c4[_0x363757('0x89')];typeof _0x484f3b['query'][_0x363757('0x6f')]===_0x363757('0x40')&&(_0x4d00fe['limit']=qs[_0x363757('0x67')](_0x484f3b[_0x363757('0x35')][_0x363757('0x67')]),_0x4d00fe[_0x363757('0xa5')]=qs['offset'](_0x484f3b[_0x363757('0x35')][_0x363757('0xa5')]));_0x4d00fe[_0x363757('0xb6')]=qs[_0x363757('0x9d')](_0x484f3b[_0x363757('0x35')]['sort']),_0x4d00fe[_0x363757('0x5')]=qs[_0x363757('0x39')](_['pick'](_0x484f3b[_0x363757('0x35')],_0x2829c4['filters'])),_0x4d00fe[_0x363757('0x5')][_0x363757('0xc')]=_0x4ee05d['id'];_0x484f3b[_0x363757('0x35')]['filter']&&(_0x4d00fe[_0x363757('0x5')]=_['merge'](_0x4d00fe[_0x363757('0x5')],{[Op['or']]:_['map'](_0x4d00fe['attributes'],function(_0x552deb){const _0x17ebb4=_0x363757,_0x33a333={};return _0x33a333[_0x552deb]={[Op[_0x17ebb4('0xbb')]]:'%'+_0x484f3b['query'][_0x17ebb4('0x6')]+'%'},_0x33a333;})}));if(_0x484f3b[_0x363757('0x35')][_0x363757('0x8a')]){const _0x1813ee=_0x484f3b[_0x363757('0x35')][_0x363757('0x8a')][_0x363757('0x96')](','),_0x2f53e0={};_0x2f53e0[_0x1813ee[0x0]]={[Op[_0x363757('0x3d')]]:moment(_0x1813ee[0x1])[_0x363757('0x41')](_0x363757('0x5f'))},_0x4d00fe[_0x363757('0x5')]=_['merge'](_0x4d00fe[_0x363757('0x5')],_0x2f53e0);}return _0x4d00fe=_['merge']({},_0x4d00fe,_0x484f3b['options']),db[_0x363757('0x9')]['count']({'where':_0x4d00fe[_0x363757('0x5')]})['then'](function(_0x315379){const _0x4ecdd2=_0x363757;return _0x4e7d1c[_0x4ecdd2('0x4c')]=_0x315379,_0x484f3b[_0x4ecdd2('0x35')][_0x4ecdd2('0xa2')]&&(_0x4d00fe[_0x4ecdd2('0x15')]=[{'all':!![]}]),db['FaxMessage']['findAll'](_0x4d00fe);})[_0x363757('0x47')](function(_0x215043){const _0x2b057b=_0x363757;return _0x4e7d1c[_0x2b057b('0x76')]=_0x215043,_0x4e7d1c;});}})[_0x56b34e('0x47')](respondWithFilteredResult(_0x2cb678,_0x4d00fe))[_0x56b34e('0x7b')](handleError(_0x2cb678,null));},exports[_0x2c1268('0x99')]=function(_0x4913d1,_0x4c2964){const _0x3fa56=_0x2c1268;return db[_0x3fa56('0x7a')]['findOne']({'where':{'id':_0x4913d1[_0x3fa56('0xe')]['id']}})[_0x3fa56('0x47')](function(_0x1c2ae){const _0x43e4e6=_0x3fa56;if(_0x1c2ae)return _0x1c2ae['setTags'](_0x4913d1[_0x43e4e6('0xa1')][_0x43e4e6('0xad')],{'through':_['omit'](_0x4913d1[_0x43e4e6('0xa1')],[_0x43e4e6('0xad'),'id'])})[_0x43e4e6('0x47')](function(){const _0x5401d5=_0x43e4e6;return db[_0x5401d5('0x19')]['findAll']({'attributes':['id',_0x5401d5('0xb'),_0x5401d5('0x81')],'where':{'id':_0x4913d1['body']['ids']}});})[_0x43e4e6('0x47')](function(_0x38d272){const _0x254de3=_0x43e4e6;return socket[_0x254de3('0xa6')](_0x254de3('0x3b'),{'id':Number(_0x4913d1[_0x254de3('0xe')]['id']),'tags':_0x38d272||[]}),{'id':Number(_0x4913d1['params']['id']),'tags':_0x38d272||[]};});})[_0x3fa56('0x47')](respondWithResult(_0x4c2964,null))['catch'](handleError(_0x4c2964,null));},exports[_0x2c1268('0x44')]=function(_0x498a03,_0xa5cb8b){const _0x2a48de=_0x2c1268;return db[_0x2a48de('0x7a')][_0x2a48de('0x4e')]({'where':{'id':_0x498a03[_0x2a48de('0xe')]['id']}})['then'](handleEntityNotFound(_0xa5cb8b,null))[_0x2a48de('0x47')](function(_0x186f38){const _0x850b54=_0x2a48de;if(_0x186f38)return _0x186f38['removeTags'](_0x498a03[_0x850b54('0x35')][_0x850b54('0xad')]);})['then'](respondWithStatusCode(_0xa5cb8b,null))['catch'](handleError(_0xa5cb8b,null));},exports['download']=function(_0x20dfb6,_0x5119db){const _0x5bedda=_0x2c1268,_0x58d6ea=moment()[_0x5bedda('0xa')]()[_0x5bedda('0x2c')](),_0x3402bc=path[_0x5bedda('0x49')](config[_0x5bedda('0x91')],_0x5bedda('0xaf'),_0x5bedda('0x8f')),_0x460292=path[_0x5bedda('0x49')](config[_0x5bedda('0x91')],_0x5bedda('0x57'),_0x5bedda('0xaf'),'attachments'),_0x3ded3b=path[_0x5bedda('0x49')](_0x3402bc,_0x58d6ea),_0x299814=util['format'](_0x5bedda('0x6b'),_0x20dfb6[_0x5bedda('0xe')]['id'],_0x58d6ea),_0x15d428=path[_0x5bedda('0x49')](_0x3402bc,_0x299814),_0x247596=[];_0x247596['push']({'model':db[_0x5bedda('0x0')],'as':_0x5bedda('0x0'),'raw':!![]});const _0x6adb0=[{'model':db[_0x5bedda('0x9')],'as':'Messages','attributes':['id',_0x5bedda('0xa1'),_0x5bedda('0x65')],'include':_0x247596}];return db[_0x5bedda('0x7a')][_0x5bedda('0x4e')]({'where':{'id':_0x20dfb6[_0x5bedda('0xe')]['id']},'include':_0x6adb0})['then'](handleEntityNotFound(_0x5119db,null))[_0x5bedda('0x47')](function(_0x368512){const _0x3b4042=_0x5bedda;if(_0x368512&&_0x368512[_0x3b4042('0x13')]){const _0x1ebdbb=_0x368512['get']({'plain':!![]});fs['mkdirSync'](_0x3ded3b);for(let _0x10ecfb=0x0;_0x10ecfb<_0x1ebdbb[_0x3b4042('0x13')][_0x3b4042('0x24')];_0x10ecfb++){const _0x385e1e=_0x1ebdbb['Messages'][_0x10ecfb][_0x3b4042('0x0')];if(_0x385e1e){const _0x5e7461=path[_0x3b4042('0x49')](_0x460292,_0x385e1e[_0x3b4042('0xb1')]);fs[_0x3b4042('0x94')](_0x5e7461)&&fs[_0x3b4042('0xb4')](_0x5e7461)[_0x3b4042('0x43')](fs['createWriteStream'](path['join'](_0x3ded3b,_0x385e1e[_0x3b4042('0xb1')])));}}return Promise[_0x3b4042('0x95')]()[_0x3b4042('0x47')](function(){const _0x178ce=_0x3b4042;return new Promise(function(_0x4de7b6,_0xb91d87){zipdir(_0x3ded3b,{'saveTo':_0x15d428},function(_0x17409c,_0x2fbb35){if(_0x17409c)return _0xb91d87(_0x17409c);return _0x4de7b6(_0x2fbb35);});})[_0x178ce('0x47')](function(){return new Promise(function(_0x3873f6,_0x58a340){rimraf(_0x3ded3b,function(_0x493d0b){if(_0x493d0b)_0x58a340(_0x493d0b);return _0x3873f6();});});})['then'](function(){const _0x10e1f0=_0x178ce;return _0x5119db[_0x10e1f0('0x53')](_0x15d428,_0x299814,function(_0x1deba5){const _0x482d87=_0x10e1f0;_0x1deba5?console[_0x482d87('0x5b')](_0x482d87('0x5d'),_0x1deba5):fs['unlinkSync'](_0x15d428);});});});}else return _0x5119db['sendStatus'](0xc8);})[_0x5bedda('0x7b')](handleError(_0x5119db,null));}; \ No newline at end of file diff --git a/server/api/faxInteraction/faxInteraction.events.js b/server/api/faxInteraction/faxInteraction.events.js index d37bf03..c6f8306 100644 --- a/server/api/faxInteraction/faxInteraction.events.js +++ b/server/api/faxInteraction/faxInteraction.events.js @@ -1 +1 @@ -const a199_0x4cd7=['setDataValue','../../mysqldb','addHook','findAll','save','FaxMessage','getUsers','exports','emit','catch','events','undefined','unreadMessages','update','remove','setMaxListeners','then','Users','FaxInteraction'];(function(_0x1aa8e9,_0x4cd723){const _0x44db7a=function(_0xe24c55){while(--_0xe24c55){_0x1aa8e9['push'](_0x1aa8e9['shift']());}};_0x44db7a(++_0x4cd723);}(a199_0x4cd7,0x1c5));const a199_0x44db=function(_0x1aa8e9,_0x4cd723){_0x1aa8e9=_0x1aa8e9-0x0;let _0x44db7a=a199_0x4cd7[_0x1aa8e9];return _0x44db7a;};const _0x361d1d=a199_0x44db;'use strict';const EventEmitter=require(_0x361d1d('0xd')),FaxInteraction=require(_0x361d1d('0x4'))['db'][_0x361d1d('0x2')],FaxMessage=require(_0x361d1d('0x4'))['db'][_0x361d1d('0x8')],FaxInteractionEvents=new EventEmitter();FaxInteractionEvents[_0x361d1d('0x12')](0x0);const events={'afterCreate':_0x361d1d('0x7'),'afterUpdate':_0x361d1d('0x10'),'afterDestroy':_0x361d1d('0x11')};function emitEvent(_0xe24c55){return function(_0x26d5aa){const _0x3ac266=a199_0x44db;_0x26d5aa[_0x3ac266('0x9')]({'attributes':['id'],'raw':!![]})[_0x3ac266('0x0')](function(_0x35d43b){const _0x555bed=_0x3ac266;return _0x26d5aa[_0x555bed('0x3')](_0x555bed('0x1'),_0x35d43b['map'](function(_0x5cb7d5){return{'id':_0x5cb7d5['id']};})),FaxMessage[_0x555bed('0x6')]({'where':{'FaxInteractionId':_0x26d5aa['id'],'direction':'in','read':![]},'raw':!![]});})[_0x3ac266('0x0')](function(_0x54ff68){const _0xe2a02a=_0x3ac266;_0x26d5aa[_0xe2a02a('0x3')](_0xe2a02a('0xf'),_0x54ff68['length']),FaxInteractionEvents[_0xe2a02a('0xb')](_0xe24c55+':'+_0x26d5aa['id'],_0x26d5aa),FaxInteractionEvents[_0xe2a02a('0xb')](_0xe24c55,_0x26d5aa);})[_0x3ac266('0xc')](()=>{});};}for(const e in events){if(typeof events[e]!==_0x361d1d('0xe')){const event=events[e];FaxInteraction[_0x361d1d('0x5')](e,emitEvent(event));}}module[_0x361d1d('0xa')]=FaxInteractionEvents; \ No newline at end of file +const a199_0x3e3a=['undefined','emit','save','../../mysqldb','unreadMessages','FaxMessage','map','Users','findAll','length','catch','addHook','update','setMaxListeners','then','setDataValue'];(function(_0xee386f,_0x3e3a31){const _0x5ee824=function(_0x2b369d){while(--_0x2b369d){_0xee386f['push'](_0xee386f['shift']());}};_0x5ee824(++_0x3e3a31);}(a199_0x3e3a,0xba));const a199_0x5ee8=function(_0xee386f,_0x3e3a31){_0xee386f=_0xee386f-0x0;let _0x5ee824=a199_0x3e3a[_0xee386f];return _0x5ee824;};const _0x428598=a199_0x5ee8;'use strict';const EventEmitter=require('events'),FaxInteraction=require(_0x428598('0x9'))['db']['FaxInteraction'],FaxMessage=require(_0x428598('0x9'))['db'][_0x428598('0xb')],FaxInteractionEvents=new EventEmitter();FaxInteractionEvents[_0x428598('0x3')](0x0);const events={'afterCreate':_0x428598('0x8'),'afterUpdate':_0x428598('0x2'),'afterDestroy':'remove'};function emitEvent(_0x2b369d){return function(_0xbac4aa){const _0x568ab0=a199_0x5ee8;_0xbac4aa['getUsers']({'attributes':['id'],'raw':!![]})[_0x568ab0('0x4')](function(_0x15ee2c){const _0x44e755=_0x568ab0;return _0xbac4aa[_0x44e755('0x5')](_0x44e755('0xd'),_0x15ee2c[_0x44e755('0xc')](function(_0x2734e5){return{'id':_0x2734e5['id']};})),FaxMessage[_0x44e755('0xe')]({'where':{'FaxInteractionId':_0xbac4aa['id'],'direction':'in','read':![]},'raw':!![]});})[_0x568ab0('0x4')](function(_0x36b1b7){const _0x18c1a2=_0x568ab0;_0xbac4aa[_0x18c1a2('0x5')](_0x18c1a2('0xa'),_0x36b1b7[_0x18c1a2('0xf')]),FaxInteractionEvents['emit'](_0x2b369d+':'+_0xbac4aa['id'],_0xbac4aa),FaxInteractionEvents[_0x18c1a2('0x7')](_0x2b369d,_0xbac4aa);})[_0x568ab0('0x0')](()=>{});};}for(const e in events){if(typeof events[e]!==_0x428598('0x6')){const event=events[e];FaxInteraction[_0x428598('0x1')](e,emitEvent(event));}}module['exports']=FaxInteractionEvents; \ No newline at end of file diff --git a/server/api/faxInteraction/faxInteraction.model.js b/server/api/faxInteraction/faxInteraction.model.js index 5e759f1..821879d 100644 --- a/server/api/faxInteraction/faxInteraction.model.js +++ b/server/api/faxInteraction/faxInteraction.model.js @@ -1 +1 @@ -const a200_0x3710=['changed','exports','closedAt','format','fax_interactions','define'];(function(_0x1c2982,_0x3710d5){const _0xcd62c7=function(_0x5b1d7d){while(--_0x5b1d7d){_0x1c2982['push'](_0x1c2982['shift']());}};_0xcd62c7(++_0x3710d5);}(a200_0x3710,0x1d7));const a200_0xcd62=function(_0x1c2982,_0x3710d5){_0x1c2982=_0x1c2982-0x0;let _0xcd62c7=a200_0x3710[_0x1c2982];return _0xcd62c7;};const _0x4b1281=a200_0xcd62;'use strict';const moment=require('moment'),attributes=require('./faxInteraction.attributes');module[_0x4b1281('0x4')]=function(_0x5b1d7d){const _0x2be7fe=_0x4b1281,_0x23d454=_0x5b1d7d[_0x2be7fe('0x2')]('FaxInteraction',attributes,{'tableName':_0x2be7fe('0x1'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x372261){const _0x5ebd27=_0x2be7fe;_0x372261[_0x5ebd27('0x3')]('closed')&&(_0x372261[_0x5ebd27('0x5')]=moment()[_0x5ebd27('0x0')]('YYYY-MM-DD\x20HH:mm:ss'));}}});return _0x23d454;}; \ No newline at end of file +const a200_0x4fc2=['closedAt','FaxInteraction','fax_interactions','exports','./faxInteraction.attributes','format','changed','define','closed','YYYY-MM-DD\x20HH:mm:ss'];(function(_0x3361b9,_0x4fc2ba){const _0x2f5da8=function(_0x4cedf8){while(--_0x4cedf8){_0x3361b9['push'](_0x3361b9['shift']());}};_0x2f5da8(++_0x4fc2ba);}(a200_0x4fc2,0xe4));const a200_0x2f5d=function(_0x3361b9,_0x4fc2ba){_0x3361b9=_0x3361b9-0x0;let _0x2f5da8=a200_0x4fc2[_0x3361b9];return _0x2f5da8;};const _0xf6bd81=a200_0x2f5d;'use strict';const moment=require('moment'),attributes=require(_0xf6bd81('0x6'));module[_0xf6bd81('0x5')]=function(_0x4cedf8){const _0x3d5a4e=_0xf6bd81,_0x8370d8=_0x4cedf8[_0x3d5a4e('0x9')](_0x3d5a4e('0x3'),attributes,{'tableName':_0x3d5a4e('0x4'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x328cc7){const _0x29b6d4=_0x3d5a4e;_0x328cc7[_0x29b6d4('0x8')](_0x29b6d4('0x0'))&&(_0x328cc7[_0x29b6d4('0x2')]=moment()[_0x29b6d4('0x7')](_0x29b6d4('0x1')));}}});return _0x8370d8;}; \ No newline at end of file diff --git a/server/api/faxInteraction/faxInteraction.rpc.js b/server/api/faxInteraction/faxInteraction.rpc.js index 283474e..58892f2 100644 --- a/server/api/faxInteraction/faxInteraction.rpc.js +++ b/server/api/faxInteraction/faxInteraction.rpc.js @@ -1 +1 @@ -const a201_0xa009=['stringify','addTags','FaxInteraction','message','UpdateFaxInteraction','info','attributes','then','limit','where','lodash','ids','raw','AddTagsToFaxInteraction','AddTags','register','body','../../mysqldb','catch','options','error','update','debug'];(function(_0x42db04,_0xa009e6){const _0x5009e8=function(_0xe53c17){while(--_0xe53c17){_0x42db04['push'](_0x42db04['shift']());}};_0x5009e8(++_0xa009e6);}(a201_0xa009,0xb8));const a201_0x5009=function(_0x42db04,_0xa009e6){_0x42db04=_0x42db04-0x0;let _0x5009e8=a201_0xa009[_0x42db04];return _0x5009e8;};const _0x5881d4=a201_0x5009;'use strict';const _=require(_0x5881d4('0xa')),db=require(_0x5881d4('0x11'))['db'],logger=require('../../config/logger')('rpc'),{getSocket}=require('../../rediscache'),socket=getSocket();require('./faxInteraction.socket')[_0x5881d4('0xf')](socket),exports[_0x5881d4('0x4')]=function(_0xe53c17){const _0x5a3b3f=this;return new Promise(function(_0x6f0477,_0x18f734){const _0x142e68=a201_0x5009;return db[_0x142e68('0x2')][_0x142e68('0x15')](_0xe53c17[_0x142e68('0x10')],{'raw':_0xe53c17[_0x142e68('0x13')]?_0xe53c17['options'][_0x142e68('0xc')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0xe53c17['options']?_0xe53c17[_0x142e68('0x13')][_0x142e68('0x9')]||null:null,'attributes':_0xe53c17[_0x142e68('0x13')]?_0xe53c17[_0x142e68('0x13')][_0x142e68('0x6')]||null:null,'limit':_0xe53c17[_0x142e68('0x13')]?_0xe53c17[_0x142e68('0x13')][_0x142e68('0x8')]||null:null})[_0x142e68('0x7')](function(_0x1d90da){const _0x32f80f=_0x142e68;logger[_0x32f80f('0x5')](_0x32f80f('0x4'),_0xe53c17),logger[_0x32f80f('0x16')](_0x32f80f('0x4'),_0xe53c17,JSON[_0x32f80f('0x0')](_0x1d90da)),_0x6f0477(_0x1d90da);})[_0x142e68('0x12')](function(_0x45046c){const _0x2961a1=_0x142e68;logger['error'](_0x2961a1('0x4'),_0x45046c['message'],_0xe53c17),_0x18f734(_0x5a3b3f['error'](0x1f4,_0x45046c['message']));});});},exports[_0x5881d4('0xd')]=function(_0x46f30b){const _0x3b4b6d=this;return new Promise(function(_0x3bbb2c,_0x2a4754){const _0x154f97=a201_0x5009;return db[_0x154f97('0x2')]['findOne']({'where':_0x46f30b['options']?_0x46f30b[_0x154f97('0x13')]['where']||null:null})[_0x154f97('0x7')](function(_0x418419){const _0x9eecff=_0x154f97;if(_0x418419)return _0x418419[_0x9eecff('0x1')](_0x46f30b['body'][_0x9eecff('0xb')],{'through':_['omit'](_0x46f30b[_0x9eecff('0x10')],[_0x9eecff('0xb'),'id'])});})[_0x154f97('0x7')](function([_0x40ed15]){const _0x72e821=_0x154f97;logger[_0x72e821('0x5')](_0x72e821('0xe'),_0x46f30b),logger['debug'](_0x72e821('0xe'),_0x46f30b,JSON[_0x72e821('0x0')](_0x40ed15)),_0x3bbb2c(_0x40ed15);})['catch'](function(_0x399310){const _0x1b8c8d=_0x154f97;logger[_0x1b8c8d('0x14')](_0x1b8c8d('0xe'),_0x399310[_0x1b8c8d('0x3')],_0x46f30b),_0x2a4754(_0x3b4b6d['error'](0x1f4,_0x399310[_0x1b8c8d('0x3')]));});});}; \ No newline at end of file +const a201_0xd83d=['debug','update','stringify','rpc','findOne','limit','addTags','FaxInteraction','info','catch','../../config/logger','AddTagsToFaxInteraction','omit','then','message','options','where','ids','UpdateFaxInteraction','./faxInteraction.socket','../../rediscache','AddTags','../../mysqldb','error','attributes','body'];(function(_0x5c51e6,_0xd83d85){const _0x3cddc9=function(_0x18aa2f){while(--_0x18aa2f){_0x5c51e6['push'](_0x5c51e6['shift']());}};_0x3cddc9(++_0xd83d85);}(a201_0xd83d,0x7f));const a201_0x3cdd=function(_0x5c51e6,_0xd83d85){_0x5c51e6=_0x5c51e6-0x0;let _0x3cddc9=a201_0xd83d[_0x5c51e6];return _0x3cddc9;};const _0x10a36a=a201_0x3cdd;'use strict';const _=require('lodash'),db=require(_0x10a36a('0x19'))['db'],logger=require(_0x10a36a('0xd'))(_0x10a36a('0x6')),{getSocket}=require(_0x10a36a('0x17')),socket=getSocket();require(_0x10a36a('0x16'))['register'](socket),exports[_0x10a36a('0x15')]=function(_0x18aa2f){const _0x46dc11=this;return new Promise(function(_0x3e4a87,_0x33d2e6){const _0x1cc0e4=a201_0x3cdd;return db[_0x1cc0e4('0xa')][_0x1cc0e4('0x4')](_0x18aa2f[_0x1cc0e4('0x2')],{'raw':_0x18aa2f[_0x1cc0e4('0x12')]?_0x18aa2f['options']['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x18aa2f[_0x1cc0e4('0x12')]?_0x18aa2f['options'][_0x1cc0e4('0x13')]||null:null,'attributes':_0x18aa2f[_0x1cc0e4('0x12')]?_0x18aa2f[_0x1cc0e4('0x12')][_0x1cc0e4('0x1')]||null:null,'limit':_0x18aa2f[_0x1cc0e4('0x12')]?_0x18aa2f[_0x1cc0e4('0x12')][_0x1cc0e4('0x8')]||null:null})[_0x1cc0e4('0x10')](function(_0x4242ba){const _0x23793c=_0x1cc0e4;logger[_0x23793c('0xb')](_0x23793c('0x15'),_0x18aa2f),logger[_0x23793c('0x3')](_0x23793c('0x15'),_0x18aa2f,JSON[_0x23793c('0x5')](_0x4242ba)),_0x3e4a87(_0x4242ba);})[_0x1cc0e4('0xc')](function(_0x46c107){const _0x253e1c=_0x1cc0e4;logger[_0x253e1c('0x0')]('UpdateFaxInteraction',_0x46c107[_0x253e1c('0x11')],_0x18aa2f),_0x33d2e6(_0x46dc11[_0x253e1c('0x0')](0x1f4,_0x46c107[_0x253e1c('0x11')]));});});},exports[_0x10a36a('0xe')]=function(_0x43ee44){const _0x482b45=this;return new Promise(function(_0x5bb3a0,_0x2c025e){const _0xf42c73=a201_0x3cdd;return db[_0xf42c73('0xa')][_0xf42c73('0x7')]({'where':_0x43ee44[_0xf42c73('0x12')]?_0x43ee44['options']['where']||null:null})[_0xf42c73('0x10')](function(_0x5070d8){const _0x144eac=_0xf42c73;if(_0x5070d8)return _0x5070d8[_0x144eac('0x9')](_0x43ee44[_0x144eac('0x2')]['ids'],{'through':_[_0x144eac('0xf')](_0x43ee44['body'],[_0x144eac('0x14'),'id'])});})[_0xf42c73('0x10')](function([_0x59d8f0]){const _0x3ff350=_0xf42c73;logger['info'](_0x3ff350('0x18'),_0x43ee44),logger[_0x3ff350('0x3')](_0x3ff350('0x18'),_0x43ee44,JSON['stringify'](_0x59d8f0)),_0x5bb3a0(_0x59d8f0);})[_0xf42c73('0xc')](function(_0x299e65){const _0x3f7303=_0xf42c73;logger['error']('AddTags',_0x299e65['message'],_0x43ee44),_0x2c025e(_0x482b45[_0x3f7303('0x0')](0x1f4,_0x299e65['message']));});});}; \ No newline at end of file diff --git a/server/api/faxInteraction/faxInteraction.socket.js b/server/api/faxInteraction/faxInteraction.socket.js index e80995d..a6d6953 100644 --- a/server/api/faxInteraction/faxInteraction.socket.js +++ b/server/api/faxInteraction/faxInteraction.socket.js @@ -1 +1 @@ -const a202_0xeafe=['faxInteraction:','update','save','length','emit'];(function(_0x1065d1,_0xeafe16){const _0x581b66=function(_0x487078){while(--_0x487078){_0x1065d1['push'](_0x1065d1['shift']());}};_0x581b66(++_0xeafe16);}(a202_0xeafe,0x180));const a202_0x581b=function(_0x1065d1,_0xeafe16){_0x1065d1=_0x1065d1-0x0;let _0x581b66=a202_0xeafe[_0x1065d1];return _0x581b66;};const _0x4d3bfe=a202_0x581b;'use strict';const FaxInteractionEvents=require('./faxInteraction.events'),events=[_0x4d3bfe('0x3'),'remove',_0x4d3bfe('0x2')];function createListener(_0x487078,_0x37d809){return function(_0x265f85){const _0x268e55=a202_0x581b;_0x37d809[_0x268e55('0x0')](_0x487078,_0x265f85);};}exports['register']=function(_0x25c97d){const _0x1dd9a0=_0x4d3bfe;for(let _0x1c8d43=0x0,_0x2571c1=events[_0x1dd9a0('0x4')];_0x1c8d43<_0x2571c1;_0x1c8d43++){const _0x42be2c=events[_0x1c8d43],_0x4a5a4b=createListener(_0x1dd9a0('0x1')+_0x42be2c,_0x25c97d);FaxInteractionEvents['on'](_0x42be2c,_0x4a5a4b);}}; \ No newline at end of file +const a202_0xd4fa=['faxInteraction:','length','update','save','remove','./faxInteraction.events','emit'];(function(_0x527266,_0xd4fad5){const _0x17574c=function(_0x52988b){while(--_0x52988b){_0x527266['push'](_0x527266['shift']());}};_0x17574c(++_0xd4fad5);}(a202_0xd4fa,0x10d));const a202_0x1757=function(_0x527266,_0xd4fad5){_0x527266=_0x527266-0x0;let _0x17574c=a202_0xd4fa[_0x527266];return _0x17574c;};const _0x222118=a202_0x1757;'use strict';const FaxInteractionEvents=require(_0x222118('0x2')),events=[_0x222118('0x0'),_0x222118('0x1'),_0x222118('0x6')];function createListener(_0x52988b,_0x4f2810){return function(_0x5136c9){const _0x47c4b3=a202_0x1757;_0x4f2810[_0x47c4b3('0x3')](_0x52988b,_0x5136c9);};}exports['register']=function(_0x4b9d65){const _0x24e6c8=_0x222118;for(let _0x4df1ac=0x0,_0x3065ab=events[_0x24e6c8('0x5')];_0x4df1ac<_0x3065ab;_0x4df1ac++){const _0x1a1a59=events[_0x4df1ac],_0x594c32=createListener(_0x24e6c8('0x4')+_0x1a1a59,_0x4b9d65);FaxInteractionEvents['on'](_0x1a1a59,_0x594c32);}}; \ No newline at end of file diff --git a/server/api/faxInteraction/index.js b/server/api/faxInteraction/index.js index d5e5732..d99f6f0 100644 --- a/server/api/faxInteraction/index.js +++ b/server/api/faxInteraction/index.js @@ -1 +1 @@ -const a203_0x56e8=['isAuthenticated','removeTags','destroy','/:id/download','/:id','fax','faxinteraction:destroy','create','tracked','express','../../components/auth/service','addMessage','delete','get','getMessages','exports','./faxInteraction.controller','faxinteraction:addtags','update','describe','/:id/tags','addTags','post','index'];(function(_0x583bb9,_0x56e8b1){const _0x510ec8=function(_0x2f687f){while(--_0x2f687f){_0x583bb9['push'](_0x583bb9['shift']());}};_0x510ec8(++_0x56e8b1);}(a203_0x56e8,0x19c));const a203_0x510e=function(_0x583bb9,_0x56e8b1){_0x583bb9=_0x583bb9-0x0;let _0x510ec8=a203_0x56e8[_0x583bb9];return _0x510ec8;};const _0x197f9d=a203_0x510e;'use strict';const express=require(_0x197f9d('0x5')),router=express['Router'](),auth=require(_0x197f9d('0x6')),interaction=require('../../components/interaction/service'),controller=require(_0x197f9d('0xc'));router['get']('/',auth['isAuthenticated'](),controller[_0x197f9d('0x13')]),router['get']('/describe',auth[_0x197f9d('0x14')](),controller[_0x197f9d('0xf')]),router[_0x197f9d('0x9')](_0x197f9d('0x0'),auth[_0x197f9d('0x14')](),controller['show']),router[_0x197f9d('0x9')]('/:id/messages',auth['isAuthenticated'](),controller[_0x197f9d('0xa')]),router[_0x197f9d('0x9')](_0x197f9d('0x17'),auth['isAuthenticated'](),controller['download']),router[_0x197f9d('0x12')]('/',auth[_0x197f9d('0x14')](),controller[_0x197f9d('0x3')]),router['post']('/:id/messages',auth[_0x197f9d('0x14')](),controller[_0x197f9d('0x7')]),router[_0x197f9d('0x12')](_0x197f9d('0x10'),auth[_0x197f9d('0x14')](),interaction[_0x197f9d('0x4')](_0x197f9d('0x1'),_0x197f9d('0xd')),controller[_0x197f9d('0x11')]),router['put'](_0x197f9d('0x0'),auth['isAuthenticated'](),interaction[_0x197f9d('0x4')](_0x197f9d('0x1'),'faxinteraction:update'),controller[_0x197f9d('0xe')]),router['delete']('/:id',auth[_0x197f9d('0x14')](),interaction['tracked'](_0x197f9d('0x1'),_0x197f9d('0x2')),controller[_0x197f9d('0x16')]),router[_0x197f9d('0x8')](_0x197f9d('0x10'),auth[_0x197f9d('0x14')](),controller[_0x197f9d('0x15')]),module[_0x197f9d('0xb')]=router; \ No newline at end of file +const a203_0x4b79=['update','./faxInteraction.controller','/describe','tracked','../../components/interaction/service','exports','post','isAuthenticated','put','/:id','/:id/messages','addMessage','/:id/tags','download','../../components/auth/service','/:id/download','index','faxinteraction:addtags','fax','delete','get','express'];(function(_0x8849b,_0x4b79cf){const _0x277318=function(_0x408003){while(--_0x408003){_0x8849b['push'](_0x8849b['shift']());}};_0x277318(++_0x4b79cf);}(a203_0x4b79,0x113));const a203_0x2773=function(_0x8849b,_0x4b79cf){_0x8849b=_0x8849b-0x0;let _0x277318=a203_0x4b79[_0x8849b];return _0x277318;};const _0x5e0721=a203_0x2773;'use strict';const express=require(_0x5e0721('0xa')),router=express['Router'](),auth=require(_0x5e0721('0x3')),interaction=require(_0x5e0721('0xf')),controller=require(_0x5e0721('0xc'));router['get']('/',auth[_0x5e0721('0x12')](),controller[_0x5e0721('0x5')]),router[_0x5e0721('0x9')](_0x5e0721('0xd'),auth[_0x5e0721('0x12')](),controller['describe']),router[_0x5e0721('0x9')](_0x5e0721('0x14'),auth['isAuthenticated'](),controller['show']),router[_0x5e0721('0x9')](_0x5e0721('0x15'),auth['isAuthenticated'](),controller['getMessages']),router[_0x5e0721('0x9')](_0x5e0721('0x4'),auth[_0x5e0721('0x12')](),controller[_0x5e0721('0x2')]),router[_0x5e0721('0x11')]('/',auth[_0x5e0721('0x12')](),controller['create']),router[_0x5e0721('0x11')](_0x5e0721('0x15'),auth[_0x5e0721('0x12')](),controller[_0x5e0721('0x0')]),router[_0x5e0721('0x11')](_0x5e0721('0x1'),auth[_0x5e0721('0x12')](),interaction[_0x5e0721('0xe')]('fax',_0x5e0721('0x6')),controller['addTags']),router[_0x5e0721('0x13')](_0x5e0721('0x14'),auth[_0x5e0721('0x12')](),interaction[_0x5e0721('0xe')](_0x5e0721('0x7'),'faxinteraction:update'),controller[_0x5e0721('0xb')]),router[_0x5e0721('0x8')](_0x5e0721('0x14'),auth[_0x5e0721('0x12')](),interaction[_0x5e0721('0xe')](_0x5e0721('0x7'),'faxinteraction:destroy'),controller['destroy']),router[_0x5e0721('0x8')]('/:id/tags',auth['isAuthenticated'](),controller['removeTags']),module[_0x5e0721('0x10')]=router; \ No newline at end of file diff --git a/server/api/faxMessage/faxMessage.attributes.js b/server/api/faxMessage/faxMessage.attributes.js index 1d57dea..6b882b1 100644 --- a/server/api/faxMessage/faxMessage.attributes.js +++ b/server/api/faxMessage/faxMessage.attributes.js @@ -1 +1 @@ -const a204_0x64fc=['medium','TEXT','DATE','exports','out','sequelize','ENUM'];(function(_0x3ade0f,_0x64fc7e){const _0x3b9a13=function(_0x37eab4){while(--_0x37eab4){_0x3ade0f['push'](_0x3ade0f['shift']());}};_0x3b9a13(++_0x64fc7e);}(a204_0x64fc,0xda));const a204_0x3b9a=function(_0x3ade0f,_0x64fc7e){_0x3ade0f=_0x3ade0f-0x0;let _0x3b9a13=a204_0x64fc[_0x3ade0f];return _0x3b9a13;};const _0x18a08d=a204_0x3b9a;'use strict';const Sequelize=require(_0x18a08d('0x4'));module[_0x18a08d('0x2')]={'body':{'type':Sequelize[_0x18a08d('0x0')](_0x18a08d('0x6')),'allowNull':![]},'read':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'direction':{'type':Sequelize[_0x18a08d('0x5')]('in',_0x18a08d('0x3')),'defaultValue':_0x18a08d('0x3'),'allowNull':![]},'failMessage':{'type':Sequelize['TEXT'],'defaultValue':null},'readAt':{'type':Sequelize[_0x18a08d('0x1')]}}; \ No newline at end of file +const a204_0x1da5=['DATE','medium','TEXT','sequelize','out','exports','ENUM'];(function(_0x5b23f8,_0x1da55f){const _0xa8a4f3=function(_0x39ee8e){while(--_0x39ee8e){_0x5b23f8['push'](_0x5b23f8['shift']());}};_0xa8a4f3(++_0x1da55f);}(a204_0x1da5,0x159));const a204_0xa8a4=function(_0x5b23f8,_0x1da55f){_0x5b23f8=_0x5b23f8-0x0;let _0xa8a4f3=a204_0x1da5[_0x5b23f8];return _0xa8a4f3;};const _0x4df7b6=a204_0xa8a4;'use strict';const Sequelize=require(_0x4df7b6('0x1'));module[_0x4df7b6('0x3')]={'body':{'type':Sequelize[_0x4df7b6('0x0')](_0x4df7b6('0x6')),'allowNull':![]},'read':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'direction':{'type':Sequelize[_0x4df7b6('0x4')]('in',_0x4df7b6('0x2')),'defaultValue':_0x4df7b6('0x2'),'allowNull':![]},'failMessage':{'type':Sequelize['TEXT'],'defaultValue':null},'readAt':{'type':Sequelize[_0x4df7b6('0x5')]}}; \ No newline at end of file diff --git a/server/api/faxMessage/faxMessage.controller.js b/server/api/faxMessage/faxMessage.controller.js index e169c89..c9fb333 100644 --- a/server/api/faxMessage/faxMessage.controller.js +++ b/server/api/faxMessage/faxMessage.controller.js @@ -1 +1 @@ -const a205_0x508c=['rawAttributes','rejectMessage','intersection','SendFax','include','filter','FaxMessage,\x20%s,\x20%s,\x20%s','Attachment','length','FaxMessage,\x20%s,\x20%s','map','root','AttachmentId','json','keys','[FAXMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','moment','catch','filters','findAll','interaction','AcceptMessage','body','query','SIP/%s','YYYY-MM-DD\x20HH:mm:ss','files','jayson/promise','agent','model','merge','isNil','where','sort','../../components/parsers/qs','FaxInteraction','request\x20sent','manual','rejectmessage','rows','type','lodash','read1stAt','index','fieldName','channel','[FAXMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','describe','info','event','end','destroy','send','register','util','../../mysqldb','accept','http','sequelize','error','fields','path','get','CmContact','params','role','EventManager','../../config/logger','code','attachments','result','count','ContactId','user','key','./faxMessage.socket','then','create','options','FaxInteractionId','interface','name','basename','RejectMessage','message','null','undefined','FaxAccountId','FaxMessage','status','debug','like','attributes','update','stringify','join','Contact','reject','UserId','findOne','order','VIRTUAL','offset','../../rediscache','fax','fax-interactions','limit','read','format','api','set'];(function(_0x3a9acb,_0x508c64){const _0x4c0ff5=function(_0x3226cf){while(--_0x3226cf){_0x3a9acb['push'](_0x3a9acb['shift']());}};_0x4c0ff5(++_0x508c64);}(a205_0x508c,0x1ea));const a205_0x4c0f=function(_0x3a9acb,_0x508c64){_0x3a9acb=_0x3a9acb-0x0;let _0x4c0ff5=a205_0x508c[_0x3a9acb];return _0x4c0ff5;};const _0x3d0fbe=a205_0x4c0f;'use strict';const moment=require(_0x3d0fbe('0x51')),util=require(_0x3d0fbe('0x8')),path=require(_0x3d0fbe('0xf')),_=require(_0x3d0fbe('0x6a')),{getSocket}=require(_0x3d0fbe('0x39')),socket=getSocket(),qs=require(_0x3d0fbe('0x63')),logger=require(_0x3d0fbe('0x15'))(_0x3d0fbe('0x3f')),config=require('../../config/environment'),interaction_log=require(_0x3d0fbe('0x15'))(_0x3d0fbe('0x3b')),db=require(_0x3d0fbe('0x9'))['db'],{Op}=require(_0x3d0fbe('0xc'));require(_0x3d0fbe('0x1d'))[_0x3d0fbe('0x7')](socket);const jayson=require(_0x3d0fbe('0x5c')),client=jayson['client']['http']({'port':0x232c}),client9002=jayson['client'][_0x3d0fbe('0xb')]({'port':0x232a});function respondWithRpcPromise(_0x3226cf,_0x187da7,_0x4e7b79,_0x15e9d7){return new Promise(function(_0x30f18e,_0x27cb5b){const _0x108ad2=a205_0x4c0f,_0x4f6abd=_0x15e9d7||client;return _0x4f6abd['request'](_0x3226cf,_0x4e7b79)[_0x108ad2('0x1e')](function(_0x37e27a){const _0x5aca03=_0x108ad2;logger[_0x5aca03('0x2')](_0x5aca03('0x4a'),_0x187da7,'request\x20sent'),logger[_0x5aca03('0x2c')](_0x5aca03('0x47'),_0x187da7,'request\x20sent',JSON['stringify'](_0x37e27a));if(_0x37e27a['error']){if(_0x37e27a[_0x5aca03('0xd')][_0x5aca03('0x16')]===0x1f4)return logger['error'](_0x5aca03('0x4a'),_0x187da7,_0x37e27a[_0x5aca03('0xd')]['message']),_0x27cb5b(_0x37e27a[_0x5aca03('0xd')][_0x5aca03('0x26')]);return logger[_0x5aca03('0xd')](_0x5aca03('0x4a'),_0x187da7,_0x37e27a['error'][_0x5aca03('0x26')]),_0x30f18e(_0x37e27a[_0x5aca03('0xd')][_0x5aca03('0x26')]);}else logger['info'](_0x5aca03('0x4a'),_0x187da7,_0x5aca03('0x65')),_0x30f18e(_0x37e27a[_0x5aca03('0x18')][_0x5aca03('0x26')]);})[_0x108ad2('0x52')](function(_0x9c3682){const _0x66c5f2=_0x108ad2;logger['error'](_0x66c5f2('0x4a'),_0x187da7,_0x9c3682),_0x27cb5b(_0x9c3682);});});}function respondWithResult(_0x44d1ed,_0x5a1031){return _0x5a1031=_0x5a1031||0xc8,function(_0x6582f3){if(_0x6582f3)return _0x44d1ed['status'](_0x5a1031)['json'](_0x6582f3);};}function respondWithFilteredResult(_0x4e48f8,_0x2cbc7e){return function(_0x49444c){const _0x513fb2=a205_0x4c0f;if(_0x49444c){const _0x4e6d1c=_0x49444c[_0x513fb2('0x19')],_0x549a15=_0x2cbc7e['offset'];let _0x2c6a81=_0x2cbc7e[_0x513fb2('0x38')]+_0x2cbc7e[_0x513fb2('0x3c')],_0x22513f;return _0x2c6a81>=_0x4e6d1c?(_0x2c6a81=_0x4e6d1c,_0x22513f=0xc8):_0x22513f=0xce,_0x4e48f8['status'](_0x22513f),_0x4e48f8[_0x513fb2('0x40')]('Content-Range',_0x549a15+'-'+_0x2c6a81+'/'+_0x4e6d1c)[_0x513fb2('0x4e')](_0x49444c);}return null;};}function saveUpdates(_0x13788f){return function(_0x3fd5ab){const _0x4bd414=a205_0x4c0f;if(_0x3fd5ab)return _0x3fd5ab[_0x4bd414('0x2f')](_0x13788f)['then'](function(_0x24f850){return _0x24f850;});return null;};}function removeEntity(_0x5d354f){return function(_0x5ca246){const _0x522307=a205_0x4c0f;if(_0x5ca246)return _0x5ca246[_0x522307('0x5')]()[_0x522307('0x1e')](function(){const _0x2ba5ff=_0x522307;_0x5d354f[_0x2ba5ff('0x2b')](0xcc)[_0x2ba5ff('0x4')]();});};}function handleEntityNotFound(_0x443c5d){return function(_0x53e552){return!_0x53e552&&_0x443c5d['sendStatus'](0x194),_0x53e552;};}function handleError(_0x179529,_0x167d19){return _0x167d19=_0x167d19||0x1f4,function(_0x155a75){const _0x2bd87e=a205_0x4c0f;logger[_0x2bd87e('0xd')](_0x155a75['stack']),_0x155a75[_0x2bd87e('0x23')]&&delete _0x155a75[_0x2bd87e('0x23')],_0x179529[_0x2bd87e('0x2b')](_0x167d19)[_0x2bd87e('0x6')](_0x155a75);};}exports[_0x3d0fbe('0x6c')]=function(_0x1afa2c,_0x5bd9f6){const _0x52e24b=_0x3d0fbe;let _0x2d0ff4={};const _0x236ca9={},_0x26bd92={'count':0x0,'rows':[]},_0x4735a5=_[_0x52e24b('0x4b')](db[_0x52e24b('0x2a')]['rawAttributes'],function(_0x25c535){const _0x3ad6ed=_0x52e24b;return{'name':_0x25c535[_0x3ad6ed('0x6d')],'type':_0x25c535[_0x3ad6ed('0x69')][_0x3ad6ed('0x1c')]};});_0x236ca9[_0x52e24b('0x5e')]=_[_0x52e24b('0x4b')](_0x4735a5,_0x52e24b('0x23')),_0x236ca9[_0x52e24b('0x58')]=_[_0x52e24b('0x4f')](_0x1afa2c[_0x52e24b('0x58')]),_0x236ca9[_0x52e24b('0x53')]=_[_0x52e24b('0x43')](_0x236ca9[_0x52e24b('0x5e')],_0x236ca9[_0x52e24b('0x58')]),_0x2d0ff4['attributes']=_[_0x52e24b('0x43')](_0x236ca9[_0x52e24b('0x5e')],qs['fields'](_0x1afa2c[_0x52e24b('0x58')][_0x52e24b('0xe')])),_0x2d0ff4[_0x52e24b('0x2e')]=_0x2d0ff4[_0x52e24b('0x2e')]['length']?_0x2d0ff4[_0x52e24b('0x2e')]:_0x236ca9['model'];typeof _0x1afa2c[_0x52e24b('0x58')]['nolimit']===_0x52e24b('0x28')&&(_0x2d0ff4['limit']=qs[_0x52e24b('0x3c')](_0x1afa2c[_0x52e24b('0x58')][_0x52e24b('0x3c')]),_0x2d0ff4[_0x52e24b('0x38')]=qs[_0x52e24b('0x38')](_0x1afa2c[_0x52e24b('0x58')][_0x52e24b('0x38')]));_0x2d0ff4[_0x52e24b('0x36')]=qs['sort'](_0x1afa2c[_0x52e24b('0x58')][_0x52e24b('0x62')]),_0x2d0ff4[_0x52e24b('0x61')]=qs[_0x52e24b('0x53')](_['pick'](_0x1afa2c[_0x52e24b('0x58')],_0x236ca9[_0x52e24b('0x53')]),_0x4735a5);_0x1afa2c[_0x52e24b('0x58')]['filter']&&(_0x2d0ff4[_0x52e24b('0x61')]=_[_0x52e24b('0x5f')](_0x2d0ff4['where'],{[Op['or']]:_['map'](_0x4735a5,function(_0x1fc599){const _0x312330=_0x52e24b;if(_0x1fc599[_0x312330('0x69')]!==_0x312330('0x37')){const _0x12840c={};return _0x12840c[_0x1fc599[_0x312330('0x23')]]={[Op[_0x312330('0x2d')]]:'%'+_0x1afa2c[_0x312330('0x58')][_0x312330('0x46')]+'%'},_0x12840c;}})}));_0x2d0ff4=_[_0x52e24b('0x5f')]({},_0x2d0ff4,_0x1afa2c[_0x52e24b('0x20')]);const _0x2e33e7={'where':_0x2d0ff4['where']};return db['FaxMessage']['count'](_0x2e33e7)['then'](function(_0x344abc){const _0x2ae62f=_0x52e24b;return _0x26bd92[_0x2ae62f('0x19')]=_0x344abc,_0x1afa2c[_0x2ae62f('0x58')]['includeAll']&&(_0x2d0ff4[_0x2ae62f('0x45')]=[{'all':!![]}]),db[_0x2ae62f('0x2a')][_0x2ae62f('0x54')](_0x2d0ff4);})[_0x52e24b('0x1e')](function(_0xf3ad9d){const _0x566dc0=_0x52e24b;return _0x26bd92[_0x566dc0('0x68')]=_0xf3ad9d,_0x26bd92;})[_0x52e24b('0x1e')](respondWithFilteredResult(_0x5bd9f6,_0x2d0ff4))[_0x52e24b('0x52')](handleError(_0x5bd9f6,null));},exports['show']=function(_0x427cc6,_0x2ad2df){const _0x3b1b16=_0x3d0fbe;let _0x3a5d36={'raw':!![],'where':{'id':_0x427cc6[_0x3b1b16('0x12')]['id']}};const _0x3dc090={};return _0x3dc090['model']=_[_0x3b1b16('0x4f')](db[_0x3b1b16('0x2a')][_0x3b1b16('0x41')]),_0x3dc090['query']=_[_0x3b1b16('0x4f')](_0x427cc6['query']),_0x3dc090[_0x3b1b16('0x53')]=_[_0x3b1b16('0x43')](_0x3dc090[_0x3b1b16('0x5e')],_0x3dc090['query']),_0x3a5d36['attributes']=_['intersection'](_0x3dc090[_0x3b1b16('0x5e')],qs[_0x3b1b16('0xe')](_0x427cc6[_0x3b1b16('0x58')][_0x3b1b16('0xe')])),_0x3a5d36[_0x3b1b16('0x2e')]=_0x3a5d36[_0x3b1b16('0x2e')][_0x3b1b16('0x49')]?_0x3a5d36[_0x3b1b16('0x2e')]:_0x3dc090[_0x3b1b16('0x5e')],_0x427cc6[_0x3b1b16('0x58')]['includeAll']&&(_0x3a5d36[_0x3b1b16('0x45')]=[{'all':!![]}]),_0x3a5d36=_['merge']({},_0x3a5d36,_0x427cc6[_0x3b1b16('0x20')]),db[_0x3b1b16('0x2a')][_0x3b1b16('0x35')](_0x3a5d36)[_0x3b1b16('0x1e')](handleEntityNotFound(_0x2ad2df,null))[_0x3b1b16('0x1e')](respondWithResult(_0x2ad2df,null))[_0x3b1b16('0x52')](handleError(_0x2ad2df,null));},exports[_0x3d0fbe('0x2f')]=function(_0x3c8fa0,_0x1e1a56){const _0x35a0a1=_0x3d0fbe;return _0x3c8fa0[_0x35a0a1('0x57')]['id']&&delete _0x3c8fa0[_0x35a0a1('0x57')]['id'],db['FaxMessage']['findOne']({'where':{'id':_0x3c8fa0[_0x35a0a1('0x12')]['id']}})[_0x35a0a1('0x1e')](handleEntityNotFound(_0x1e1a56,null))[_0x35a0a1('0x1e')](saveUpdates(_0x3c8fa0[_0x35a0a1('0x57')],null))[_0x35a0a1('0x1e')](respondWithResult(_0x1e1a56,null))[_0x35a0a1('0x52')](handleError(_0x1e1a56,null));},exports[_0x3d0fbe('0x5')]=function(_0x53304b,_0x4a7044){const _0x1f2c7a=_0x3d0fbe;return db[_0x1f2c7a('0x2a')]['findOne']({'where':{'id':_0x53304b[_0x1f2c7a('0x12')]['id']}})['then'](handleEntityNotFound(_0x4a7044,null))[_0x1f2c7a('0x1e')](removeEntity(_0x4a7044,null))['catch'](handleError(_0x4a7044,null));},exports['describe']=function(_0x30040e,_0x7e59a7){const _0x52a4c1=_0x3d0fbe;return db[_0x52a4c1('0x2a')][_0x52a4c1('0x1')]()[_0x52a4c1('0x1e')](respondWithResult(_0x7e59a7,null))[_0x52a4c1('0x52')](handleError(_0x7e59a7,null));},exports[_0x3d0fbe('0xa')]=function(_0x43f1fe,_0x58a6b8){const _0x4c13fb=_0x3d0fbe,_0xc3cdb8={'channel':_0x4c13fb('0x3a')};return _0x43f1fe[_0x4c13fb('0x57')]['id']&&delete _0x43f1fe[_0x4c13fb('0x57')]['id'],_0x43f1fe[_0x4c13fb('0x57')][_0x4c13fb('0x3d')]=!![],_0x43f1fe['body']['readAt']=moment()[_0x4c13fb('0x3e')](_0x4c13fb('0x5a')),_0x43f1fe['body'][_0x4c13fb('0x34')]=_0x43f1fe[_0x4c13fb('0x57')][_0x4c13fb('0x34')]||_0x43f1fe[_0x4c13fb('0x1b')]['id'],db[_0x4c13fb('0x2a')][_0x4c13fb('0x35')]({'where':{'id':_0x43f1fe[_0x4c13fb('0x12')]['id'],'UserId':null},'include':[{'model':db[_0x4c13fb('0x11')],'as':_0x4c13fb('0x32')}]})[_0x4c13fb('0x1e')](handleEntityNotFound(_0x58a6b8,null))['then'](saveUpdates(_0x43f1fe['body'],null))[_0x4c13fb('0x1e')](function(_0x1c2371){const _0x4b866b=_0x4c13fb;if(_0x1c2371)return _0xc3cdb8[_0x4b866b('0x26')]=_0x1c2371[_0x4b866b('0x10')]({'plain':!![]}),db[_0x4b866b('0x64')][_0x4b866b('0x35')]({'where':{'id':_0x1c2371[_0x4b866b('0x21')]}});return null;})['then'](handleEntityNotFound(_0x58a6b8,null))[_0x4c13fb('0x1e')](function(_0x23d36a){const _0x265a90=_0x4c13fb;if(_0x23d36a)return _0x23d36a[_0x265a90('0x2f')]({'UserId':_0x43f1fe[_0x265a90('0x57')][_0x265a90('0x34')],'read1stAt':_[_0x265a90('0x60')](_0x23d36a[_0x265a90('0x6b')])?moment()[_0x265a90('0x3e')](_0x265a90('0x5a')):undefined});return null;})[_0x4c13fb('0x1e')](function(_0x2f13e2){const _0x280413=_0x4c13fb;if(_0x2f13e2)return _0xc3cdb8[_0x280413('0x55')]=_0x2f13e2['get']({'plain':!![]}),interaction_log['info'](_0x280413('0x0'),_0x43f1fe[_0x280413('0x1b')]['id'],_0x43f1fe[_0x280413('0x1b')][_0x280413('0x23')],_0x43f1fe[_0x280413('0x1b')][_0x280413('0x13')],_0xc3cdb8[_0x280413('0x55')]['id'],_0x43f1fe[_0x280413('0x57')]?JSON[_0x280413('0x30')](_0x43f1fe[_0x280413('0x57')]):_0x280413('0x27')),respondWithRpcPromise(_0x280413('0x56'),'acceptMessage',_0xc3cdb8);return null;})['then'](function(_0x4f82e5){const _0x18944b=_0x4c13fb;if(_0x4f82e5){if(_0x43f1fe[_0x18944b('0x57')][_0x18944b('0x66')])return _0xc3cdb8[_0x18944b('0x26')][_0x18944b('0x22')]=util[_0x18944b('0x3e')](_0x18944b('0x59'),_0x43f1fe[_0x18944b('0x1b')][_0x18944b('0x23')]),_0xc3cdb8[_0x18944b('0x26')][_0x18944b('0x6e')]=_0xc3cdb8[_0x18944b('0x6e')],_0xc3cdb8[_0x18944b('0x26')][_0x18944b('0x3')]='accept',respondWithRpcPromise(_0x18944b('0x14'),_0x18944b('0x14'),{'event':'acceptmessage','message':_0xc3cdb8['message']},client9002)[_0x18944b('0x1e')](function(){return _0xc3cdb8;});return _0xc3cdb8;}return null;})[_0x4c13fb('0x1e')](respondWithResult(_0x58a6b8,null))[_0x4c13fb('0x52')](handleError(_0x58a6b8,null));},exports[_0x3d0fbe('0x33')]=function(_0x2a51cf,_0x591b53){const _0x36e3bb=_0x3d0fbe,_0x338b02={'agent':{},'channel':_0x36e3bb('0x3a')};return _0x2a51cf[_0x36e3bb('0x57')]['id']&&delete _0x2a51cf['body']['id'],_0x2a51cf['body'][_0x36e3bb('0x34')]=_0x2a51cf[_0x36e3bb('0x57')][_0x36e3bb('0x34')]||_0x2a51cf[_0x36e3bb('0x1b')]['id'],_0x338b02[_0x36e3bb('0x5d')]['id']=_0x2a51cf['body']['UserId'],db[_0x36e3bb('0x2a')][_0x36e3bb('0x35')]({'where':{'id':_0x2a51cf[_0x36e3bb('0x12')]['id'],'UserId':null}})['then'](handleEntityNotFound(_0x591b53,null))[_0x36e3bb('0x1e')](function(_0x354f16){const _0x5150a2=_0x36e3bb;if(_0x354f16)return _0x338b02[_0x5150a2('0x26')]=_0x354f16['get']({'plain':!![]}),db[_0x5150a2('0x64')][_0x5150a2('0x35')]({'where':{'id':_0x354f16[_0x5150a2('0x21')]}});return null;})[_0x36e3bb('0x1e')](handleEntityNotFound(_0x591b53,null))['then'](function(_0x1a3ba8){const _0x13d485=_0x36e3bb;if(_0x1a3ba8)return _0x338b02[_0x13d485('0x55')]=_0x1a3ba8[_0x13d485('0x10')]({'plain':!![]}),interaction_log[_0x13d485('0x2')](_0x13d485('0x50'),_0x2a51cf[_0x13d485('0x1b')]['id'],_0x2a51cf['user'][_0x13d485('0x23')],_0x2a51cf[_0x13d485('0x1b')][_0x13d485('0x13')],_0x338b02[_0x13d485('0x55')]['id'],_0x2a51cf[_0x13d485('0x57')]?JSON['stringify'](_0x2a51cf['body']):_0x13d485('0x27')),respondWithRpcPromise(_0x13d485('0x25'),_0x13d485('0x42'),_0x338b02);return null;})['then'](function(_0x811ddd){const _0x4096f4=_0x36e3bb;if(_0x811ddd)return _0x811ddd['message'][_0x4096f4('0x22')]=util[_0x4096f4('0x3e')](_0x4096f4('0x59'),_0x2a51cf[_0x4096f4('0x1b')][_0x4096f4('0x23')]),_0x811ddd[_0x4096f4('0x26')][_0x4096f4('0x6e')]=_0x338b02['channel'],_0x811ddd[_0x4096f4('0x26')][_0x4096f4('0x3')]=_0x4096f4('0x33'),respondWithRpcPromise('EventManager',_0x4096f4('0x14'),{'event':_0x4096f4('0x67'),'message':_0x811ddd[_0x4096f4('0x26')]},client9002),_0x338b02;return null;})['then'](respondWithResult(_0x591b53,null))[_0x36e3bb('0x52')](handleError(_0x591b53,null));},exports[_0x3d0fbe('0x1f')]=function(_0x2b98d4,_0x493de4){const _0x5683aa=_0x3d0fbe;let _0x43d71e;return db['FaxMessage']['create'](_0x2b98d4['body'],{})[_0x5683aa('0x1e')](function(_0x55d086){const _0x29a9f0=_0x5683aa;return _0x43d71e=_0x55d086,db['CmContact'][_0x29a9f0('0x35')]({'where':{'id':_0x43d71e[_0x29a9f0('0x1a')]}});})[_0x5683aa('0x1e')](function(_0x122b9a){const _0x4c763d=_0x5683aa;if(_[_0x4c763d('0x60')](_0x122b9a))return;else return _0x43d71e[_0x4c763d('0x3a')]=_0x122b9a['fax'],db[_0x4c763d('0x48')][_0x4c763d('0x35')]({'where':{'id':_0x43d71e[_0x4c763d('0x4d')]}});})[_0x5683aa('0x1e')](function(_0x20fab4){const _0x4850d8=_0x5683aa;return respondWithRpcPromise('SendFax',_0x4850d8('0x44'),{'FaxAccountId':_[_0x4850d8('0x60')](_0x2b98d4[_0x4850d8('0x57')])?undefined:_0x2b98d4[_0x4850d8('0x57')][_0x4850d8('0x29')],'path':_[_0x4850d8('0x60')](_0x20fab4)?undefined:util[_0x4850d8('0x3e')]('/var/opt/motion2/server/files/attachments/%s',_0x20fab4['basename']),'fax':_[_0x4850d8('0x60')](_0x43d71e[_0x4850d8('0x3a')])?undefined:_0x43d71e[_0x4850d8('0x3a')],'AttachmentId':_0x43d71e[_0x4850d8('0x4d')]},client9002);})[_0x5683aa('0x1e')](respondWithResult(_0x493de4,0xc9))['catch'](handleError(_0x493de4,null));},exports['download']=function(_0x2cf21b,_0x1e6f26){const _0x14c1a2=_0x3d0fbe,_0x172510=path[_0x14c1a2('0x31')](config[_0x14c1a2('0x4c')],'server',_0x14c1a2('0x5b'),_0x14c1a2('0x17'));return db[_0x14c1a2('0x2a')][_0x14c1a2('0x35')]({'where':{'id':_0x2cf21b[_0x14c1a2('0x12')]['id']},'include':[{'model':db[_0x14c1a2('0x48')],'as':'Attachment'}]})[_0x14c1a2('0x1e')](handleEntityNotFound(_0x1e6f26,null))['then'](function(_0x391b77){const _0x32b62c=_0x14c1a2;if(_0x391b77)return _0x1e6f26['download'](path['join'](_0x172510,_0x391b77['Attachment'][_0x32b62c('0x24')]));})['catch'](handleError(_0x1e6f26,null));}; \ No newline at end of file +const a205_0x2e7b=['Attachment','fax','manual','files','destroy','RejectMessage','nolimit','where','rejectmessage','message','merge','request\x20sent','stringify','reject','EventManager','FaxMessage','filters','update','count','user','rejectMessage','./faxMessage.socket','isNil','limit','sendStatus','length','VIRTUAL','AcceptMessage','SIP/%s','channel','../../config/environment','create','server','ContactId','/var/opt/motion2/server/files/attachments/%s','get','findAll','../../components/parsers/qs','model','request','join','[FAXMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','../../rediscache','UserId','query','include','null','options','Contact','then','keys','pick','info','accept','attributes','name','sort','api','map','debug','body','role','sequelize','FaxMessage,\x20%s,\x20%s','SendFax','end','error','catch','includeAll','fieldName','filter','event','offset','index','FaxInteraction','../../config/logger','json','AttachmentId','findOne','show','client','readAt','YYYY-MM-DD\x20HH:mm:ss','like','fields','intersection','download','root','agent','read','fax-interactions','rows','params','order','key','format','../../mysqldb','http','type','stack','status','lodash','jayson/promise','undefined','interface','FaxInteractionId','path','rawAttributes','basename','FaxAccountId','set','interaction'];(function(_0xd80274,_0x2e7b3d){const _0x4b083c=function(_0xa70f41){while(--_0xa70f41){_0xd80274['push'](_0xd80274['shift']());}};_0x4b083c(++_0x2e7b3d);}(a205_0x2e7b,0x1a8));const a205_0x4b08=function(_0xd80274,_0x2e7b3d){_0xd80274=_0xd80274-0x0;let _0x4b083c=a205_0x2e7b[_0xd80274];return _0x4b083c;};const _0x21345f=a205_0x4b08;'use strict';const moment=require('moment'),util=require('util'),path=require(_0x21345f('0x12')),_=require(_0x21345f('0xd')),{getSocket}=require(_0x21345f('0x42')),socket=getSocket(),qs=require(_0x21345f('0x3d')),logger=require(_0x21345f('0x63'))(_0x21345f('0x51')),config=require(_0x21345f('0x36')),interaction_log=require(_0x21345f('0x63'))(_0x21345f('0x2')),db=require(_0x21345f('0x8'))['db'],{Op}=require(_0x21345f('0x56'));require(_0x21345f('0x2d'))['register'](socket);const jayson=require(_0x21345f('0xe')),client=jayson[_0x21345f('0x68')][_0x21345f('0x9')]({'port':0x232c}),client9002=jayson[_0x21345f('0x68')]['http']({'port':0x232a});function respondWithRpcPromise(_0xa70f41,_0xc5dddc,_0x20977f,_0xd0122d){return new Promise(function(_0x2fa7d4,_0x5e64a4){const _0x539195=a205_0x4b08,_0x22f773=_0xd0122d||client;return _0x22f773[_0x539195('0x3f')](_0xa70f41,_0x20977f)[_0x539195('0x49')](function(_0x3897d8){const _0x30dda4=_0x539195;logger['info'](_0x30dda4('0x57'),_0xc5dddc,_0x30dda4('0x23')),logger[_0x30dda4('0x53')]('FaxMessage,\x20%s,\x20%s,\x20%s',_0xc5dddc,_0x30dda4('0x23'),JSON['stringify'](_0x3897d8));if(_0x3897d8['error']){if(_0x3897d8[_0x30dda4('0x5a')]['code']===0x1f4)return logger[_0x30dda4('0x5a')](_0x30dda4('0x57'),_0xc5dddc,_0x3897d8[_0x30dda4('0x5a')]['message']),_0x5e64a4(_0x3897d8[_0x30dda4('0x5a')][_0x30dda4('0x21')]);return logger['error'](_0x30dda4('0x57'),_0xc5dddc,_0x3897d8[_0x30dda4('0x5a')][_0x30dda4('0x21')]),_0x2fa7d4(_0x3897d8[_0x30dda4('0x5a')]['message']);}else logger[_0x30dda4('0x4c')](_0x30dda4('0x57'),_0xc5dddc,'request\x20sent'),_0x2fa7d4(_0x3897d8['result']['message']);})[_0x539195('0x5b')](function(_0x3ffaf7){const _0x1400d6=_0x539195;logger[_0x1400d6('0x5a')](_0x1400d6('0x57'),_0xc5dddc,_0x3ffaf7),_0x5e64a4(_0x3ffaf7);});});}function respondWithResult(_0x200256,_0x2fa80a){return _0x2fa80a=_0x2fa80a||0xc8,function(_0x5ddaaa){const _0x4cc22f=a205_0x4b08;if(_0x5ddaaa)return _0x200256[_0x4cc22f('0xc')](_0x2fa80a)['json'](_0x5ddaaa);};}function respondWithFilteredResult(_0x27ce51,_0x1fff78){return function(_0x2a3421){const _0x2e7b92=a205_0x4b08;if(_0x2a3421){const _0x5247ad=_0x2a3421[_0x2e7b92('0x2a')],_0x47a8bb=_0x1fff78['offset'];let _0x3c86ff=_0x1fff78[_0x2e7b92('0x60')]+_0x1fff78[_0x2e7b92('0x2f')],_0x2fd8e5;return _0x3c86ff>=_0x5247ad?(_0x3c86ff=_0x5247ad,_0x2fd8e5=0xc8):_0x2fd8e5=0xce,_0x27ce51[_0x2e7b92('0xc')](_0x2fd8e5),_0x27ce51[_0x2e7b92('0x16')]('Content-Range',_0x47a8bb+'-'+_0x3c86ff+'/'+_0x5247ad)[_0x2e7b92('0x64')](_0x2a3421);}return null;};}function saveUpdates(_0x67c78e){return function(_0x23e4a3){const _0x3f6dbf=a205_0x4b08;if(_0x23e4a3)return _0x23e4a3['update'](_0x67c78e)[_0x3f6dbf('0x49')](function(_0x220f1a){return _0x220f1a;});return null;};}function removeEntity(_0x484235){return function(_0x157bb5){const _0x2406cd=a205_0x4b08;if(_0x157bb5)return _0x157bb5[_0x2406cd('0x1c')]()['then'](function(){const _0xb847ba=_0x2406cd;_0x484235[_0xb847ba('0xc')](0xcc)[_0xb847ba('0x59')]();});};}function handleEntityNotFound(_0x5be973){return function(_0x1e48e4){const _0x1db9fd=a205_0x4b08;return!_0x1e48e4&&_0x5be973[_0x1db9fd('0x30')](0x194),_0x1e48e4;};}function handleError(_0x25fd22,_0x3b771e){return _0x3b771e=_0x3b771e||0x1f4,function(_0x5980e0){const _0x14bba0=a205_0x4b08;logger[_0x14bba0('0x5a')](_0x5980e0[_0x14bba0('0xb')]),_0x5980e0[_0x14bba0('0x4f')]&&delete _0x5980e0[_0x14bba0('0x4f')],_0x25fd22[_0x14bba0('0xc')](_0x3b771e)['send'](_0x5980e0);};}exports[_0x21345f('0x61')]=function(_0x21867c,_0x108f8d){const _0x39a015=_0x21345f;let _0xa7c27={};const _0x328de8={},_0x33bec9={'count':0x0,'rows':[]},_0x2c881f=_[_0x39a015('0x52')](db[_0x39a015('0x27')][_0x39a015('0x13')],function(_0x57f710){const _0x397a28=_0x39a015;return{'name':_0x57f710[_0x397a28('0x5d')],'type':_0x57f710[_0x397a28('0xa')][_0x397a28('0x6')]};});_0x328de8[_0x39a015('0x3e')]=_[_0x39a015('0x52')](_0x2c881f,_0x39a015('0x4f')),_0x328de8[_0x39a015('0x44')]=_[_0x39a015('0x4a')](_0x21867c['query']),_0x328de8[_0x39a015('0x28')]=_[_0x39a015('0x6d')](_0x328de8['model'],_0x328de8[_0x39a015('0x44')]),_0xa7c27[_0x39a015('0x4e')]=_[_0x39a015('0x6d')](_0x328de8[_0x39a015('0x3e')],qs[_0x39a015('0x6c')](_0x21867c[_0x39a015('0x44')][_0x39a015('0x6c')])),_0xa7c27[_0x39a015('0x4e')]=_0xa7c27['attributes'][_0x39a015('0x31')]?_0xa7c27[_0x39a015('0x4e')]:_0x328de8[_0x39a015('0x3e')];typeof _0x21867c[_0x39a015('0x44')][_0x39a015('0x1e')]===_0x39a015('0xf')&&(_0xa7c27[_0x39a015('0x2f')]=qs[_0x39a015('0x2f')](_0x21867c['query']['limit']),_0xa7c27[_0x39a015('0x60')]=qs[_0x39a015('0x60')](_0x21867c[_0x39a015('0x44')][_0x39a015('0x60')]));_0xa7c27[_0x39a015('0x5')]=qs[_0x39a015('0x50')](_0x21867c['query'][_0x39a015('0x50')]),_0xa7c27[_0x39a015('0x1f')]=qs[_0x39a015('0x28')](_[_0x39a015('0x4b')](_0x21867c[_0x39a015('0x44')],_0x328de8[_0x39a015('0x28')]),_0x2c881f);_0x21867c[_0x39a015('0x44')][_0x39a015('0x5e')]&&(_0xa7c27['where']=_[_0x39a015('0x22')](_0xa7c27[_0x39a015('0x1f')],{[Op['or']]:_[_0x39a015('0x52')](_0x2c881f,function(_0x46959c){const _0xda9a9c=_0x39a015;if(_0x46959c['type']!==_0xda9a9c('0x32')){const _0x45bdbe={};return _0x45bdbe[_0x46959c[_0xda9a9c('0x4f')]]={[Op[_0xda9a9c('0x6b')]]:'%'+_0x21867c[_0xda9a9c('0x44')][_0xda9a9c('0x5e')]+'%'},_0x45bdbe;}})}));_0xa7c27=_[_0x39a015('0x22')]({},_0xa7c27,_0x21867c[_0x39a015('0x47')]);const _0x12bb6c={'where':_0xa7c27[_0x39a015('0x1f')]};return db[_0x39a015('0x27')][_0x39a015('0x2a')](_0x12bb6c)[_0x39a015('0x49')](function(_0xf9f20){const _0x503a7b=_0x39a015;return _0x33bec9[_0x503a7b('0x2a')]=_0xf9f20,_0x21867c[_0x503a7b('0x44')][_0x503a7b('0x5c')]&&(_0xa7c27['include']=[{'all':!![]}]),db[_0x503a7b('0x27')][_0x503a7b('0x3c')](_0xa7c27);})[_0x39a015('0x49')](function(_0x4adcf1){const _0x2c6c70=_0x39a015;return _0x33bec9[_0x2c6c70('0x3')]=_0x4adcf1,_0x33bec9;})[_0x39a015('0x49')](respondWithFilteredResult(_0x108f8d,_0xa7c27))[_0x39a015('0x5b')](handleError(_0x108f8d,null));},exports[_0x21345f('0x67')]=function(_0x57125b,_0x5c6b0f){const _0x17f62f=_0x21345f;let _0x6299aa={'raw':!![],'where':{'id':_0x57125b['params']['id']}};const _0x4b2b7b={};return _0x4b2b7b['model']=_['keys'](db['FaxMessage'][_0x17f62f('0x13')]),_0x4b2b7b[_0x17f62f('0x44')]=_[_0x17f62f('0x4a')](_0x57125b[_0x17f62f('0x44')]),_0x4b2b7b[_0x17f62f('0x28')]=_[_0x17f62f('0x6d')](_0x4b2b7b[_0x17f62f('0x3e')],_0x4b2b7b['query']),_0x6299aa[_0x17f62f('0x4e')]=_[_0x17f62f('0x6d')](_0x4b2b7b[_0x17f62f('0x3e')],qs[_0x17f62f('0x6c')](_0x57125b[_0x17f62f('0x44')][_0x17f62f('0x6c')])),_0x6299aa[_0x17f62f('0x4e')]=_0x6299aa[_0x17f62f('0x4e')][_0x17f62f('0x31')]?_0x6299aa[_0x17f62f('0x4e')]:_0x4b2b7b[_0x17f62f('0x3e')],_0x57125b[_0x17f62f('0x44')][_0x17f62f('0x5c')]&&(_0x6299aa[_0x17f62f('0x45')]=[{'all':!![]}]),_0x6299aa=_[_0x17f62f('0x22')]({},_0x6299aa,_0x57125b[_0x17f62f('0x47')]),db['FaxMessage'][_0x17f62f('0x66')](_0x6299aa)[_0x17f62f('0x49')](handleEntityNotFound(_0x5c6b0f,null))[_0x17f62f('0x49')](respondWithResult(_0x5c6b0f,null))[_0x17f62f('0x5b')](handleError(_0x5c6b0f,null));},exports['update']=function(_0x36e90a,_0x17ee3f){const _0x28f8b6=_0x21345f;return _0x36e90a['body']['id']&&delete _0x36e90a[_0x28f8b6('0x54')]['id'],db[_0x28f8b6('0x27')][_0x28f8b6('0x66')]({'where':{'id':_0x36e90a[_0x28f8b6('0x4')]['id']}})[_0x28f8b6('0x49')](handleEntityNotFound(_0x17ee3f,null))['then'](saveUpdates(_0x36e90a[_0x28f8b6('0x54')],null))[_0x28f8b6('0x49')](respondWithResult(_0x17ee3f,null))[_0x28f8b6('0x5b')](handleError(_0x17ee3f,null));},exports['destroy']=function(_0x14bbb2,_0x3a53f7){const _0x309018=_0x21345f;return db[_0x309018('0x27')]['findOne']({'where':{'id':_0x14bbb2['params']['id']}})['then'](handleEntityNotFound(_0x3a53f7,null))[_0x309018('0x49')](removeEntity(_0x3a53f7,null))[_0x309018('0x5b')](handleError(_0x3a53f7,null));},exports['describe']=function(_0x499646,_0x5f1692){const _0x1d3a04=_0x21345f;return db[_0x1d3a04('0x27')]['describe']()['then'](respondWithResult(_0x5f1692,null))[_0x1d3a04('0x5b')](handleError(_0x5f1692,null));},exports['accept']=function(_0x18b1da,_0x105d43){const _0x4e6397=_0x21345f,_0x5add27={'channel':_0x4e6397('0x19')};return _0x18b1da[_0x4e6397('0x54')]['id']&&delete _0x18b1da['body']['id'],_0x18b1da[_0x4e6397('0x54')][_0x4e6397('0x1')]=!![],_0x18b1da['body'][_0x4e6397('0x69')]=moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),_0x18b1da['body'][_0x4e6397('0x43')]=_0x18b1da[_0x4e6397('0x54')][_0x4e6397('0x43')]||_0x18b1da[_0x4e6397('0x2b')]['id'],db[_0x4e6397('0x27')][_0x4e6397('0x66')]({'where':{'id':_0x18b1da[_0x4e6397('0x4')]['id'],'UserId':null},'include':[{'model':db['CmContact'],'as':_0x4e6397('0x48')}]})[_0x4e6397('0x49')](handleEntityNotFound(_0x105d43,null))[_0x4e6397('0x49')](saveUpdates(_0x18b1da['body'],null))[_0x4e6397('0x49')](function(_0xd3601){const _0x47ce45=_0x4e6397;if(_0xd3601)return _0x5add27['message']=_0xd3601[_0x47ce45('0x3b')]({'plain':!![]}),db[_0x47ce45('0x62')][_0x47ce45('0x66')]({'where':{'id':_0xd3601['FaxInteractionId']}});return null;})[_0x4e6397('0x49')](handleEntityNotFound(_0x105d43,null))[_0x4e6397('0x49')](function(_0x51764c){const _0x3bdacb=_0x4e6397;if(_0x51764c)return _0x51764c[_0x3bdacb('0x29')]({'UserId':_0x18b1da[_0x3bdacb('0x54')]['UserId'],'read1stAt':_['isNil'](_0x51764c['read1stAt'])?moment()[_0x3bdacb('0x7')](_0x3bdacb('0x6a')):undefined});return null;})[_0x4e6397('0x49')](function(_0x2cfc95){const _0x498478=_0x4e6397;if(_0x2cfc95)return _0x5add27[_0x498478('0x17')]=_0x2cfc95[_0x498478('0x3b')]({'plain':!![]}),interaction_log['info']('[FAXMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s',_0x18b1da['user']['id'],_0x18b1da['user'][_0x498478('0x4f')],_0x18b1da[_0x498478('0x2b')][_0x498478('0x55')],_0x5add27[_0x498478('0x17')]['id'],_0x18b1da[_0x498478('0x54')]?JSON[_0x498478('0x24')](_0x18b1da[_0x498478('0x54')]):_0x498478('0x46')),respondWithRpcPromise(_0x498478('0x33'),'acceptMessage',_0x5add27);return null;})[_0x4e6397('0x49')](function(_0x151228){const _0x3842b0=_0x4e6397;if(_0x151228){if(_0x18b1da[_0x3842b0('0x54')][_0x3842b0('0x1a')])return _0x5add27[_0x3842b0('0x21')][_0x3842b0('0x10')]=util[_0x3842b0('0x7')](_0x3842b0('0x34'),_0x18b1da['user'][_0x3842b0('0x4f')]),_0x5add27[_0x3842b0('0x21')][_0x3842b0('0x35')]=_0x5add27[_0x3842b0('0x35')],_0x5add27[_0x3842b0('0x21')][_0x3842b0('0x5f')]=_0x3842b0('0x4d'),respondWithRpcPromise(_0x3842b0('0x26'),_0x3842b0('0x26'),{'event':'acceptmessage','message':_0x5add27['message']},client9002)[_0x3842b0('0x49')](function(){return _0x5add27;});return _0x5add27;}return null;})[_0x4e6397('0x49')](respondWithResult(_0x105d43,null))[_0x4e6397('0x5b')](handleError(_0x105d43,null));},exports[_0x21345f('0x25')]=function(_0x1bcb14,_0x26c2c7){const _0x2de23a=_0x21345f,_0x3c7c2f={'agent':{},'channel':_0x2de23a('0x19')};return _0x1bcb14['body']['id']&&delete _0x1bcb14[_0x2de23a('0x54')]['id'],_0x1bcb14[_0x2de23a('0x54')]['UserId']=_0x1bcb14[_0x2de23a('0x54')][_0x2de23a('0x43')]||_0x1bcb14[_0x2de23a('0x2b')]['id'],_0x3c7c2f[_0x2de23a('0x0')]['id']=_0x1bcb14[_0x2de23a('0x54')]['UserId'],db['FaxMessage'][_0x2de23a('0x66')]({'where':{'id':_0x1bcb14[_0x2de23a('0x4')]['id'],'UserId':null}})[_0x2de23a('0x49')](handleEntityNotFound(_0x26c2c7,null))['then'](function(_0x5f1068){const _0x1a4806=_0x2de23a;if(_0x5f1068)return _0x3c7c2f[_0x1a4806('0x21')]=_0x5f1068[_0x1a4806('0x3b')]({'plain':!![]}),db[_0x1a4806('0x62')]['findOne']({'where':{'id':_0x5f1068[_0x1a4806('0x11')]}});return null;})[_0x2de23a('0x49')](handleEntityNotFound(_0x26c2c7,null))['then'](function(_0x503e5e){const _0x5d506c=_0x2de23a;if(_0x503e5e)return _0x3c7c2f[_0x5d506c('0x17')]=_0x503e5e[_0x5d506c('0x3b')]({'plain':!![]}),interaction_log[_0x5d506c('0x4c')](_0x5d506c('0x41'),_0x1bcb14[_0x5d506c('0x2b')]['id'],_0x1bcb14[_0x5d506c('0x2b')][_0x5d506c('0x4f')],_0x1bcb14[_0x5d506c('0x2b')][_0x5d506c('0x55')],_0x3c7c2f[_0x5d506c('0x17')]['id'],_0x1bcb14[_0x5d506c('0x54')]?JSON[_0x5d506c('0x24')](_0x1bcb14[_0x5d506c('0x54')]):_0x5d506c('0x46')),respondWithRpcPromise(_0x5d506c('0x1d'),_0x5d506c('0x2c'),_0x3c7c2f);return null;})['then'](function(_0x7a6b93){const _0x33ec85=_0x2de23a;if(_0x7a6b93)return _0x7a6b93[_0x33ec85('0x21')][_0x33ec85('0x10')]=util['format']('SIP/%s',_0x1bcb14[_0x33ec85('0x2b')][_0x33ec85('0x4f')]),_0x7a6b93['message'][_0x33ec85('0x35')]=_0x3c7c2f[_0x33ec85('0x35')],_0x7a6b93[_0x33ec85('0x21')][_0x33ec85('0x5f')]='reject',respondWithRpcPromise('EventManager',_0x33ec85('0x26'),{'event':_0x33ec85('0x20'),'message':_0x7a6b93[_0x33ec85('0x21')]},client9002),_0x3c7c2f;return null;})[_0x2de23a('0x49')](respondWithResult(_0x26c2c7,null))[_0x2de23a('0x5b')](handleError(_0x26c2c7,null));},exports[_0x21345f('0x37')]=function(_0x150486,_0x20eaac){const _0x2b58bb=_0x21345f;let _0x4c6608;return db[_0x2b58bb('0x27')][_0x2b58bb('0x37')](_0x150486[_0x2b58bb('0x54')],{})[_0x2b58bb('0x49')](function(_0x36eb24){const _0x1b2245=_0x2b58bb;return _0x4c6608=_0x36eb24,db['CmContact'][_0x1b2245('0x66')]({'where':{'id':_0x4c6608[_0x1b2245('0x39')]}});})['then'](function(_0x144d88){const _0x2da437=_0x2b58bb;if(_['isNil'](_0x144d88))return;else return _0x4c6608[_0x2da437('0x19')]=_0x144d88['fax'],db[_0x2da437('0x18')][_0x2da437('0x66')]({'where':{'id':_0x4c6608['AttachmentId']}});})[_0x2b58bb('0x49')](function(_0xa4285e){const _0x12dec0=_0x2b58bb;return respondWithRpcPromise(_0x12dec0('0x58'),_0x12dec0('0x58'),{'FaxAccountId':_[_0x12dec0('0x2e')](_0x150486[_0x12dec0('0x54')])?undefined:_0x150486['body'][_0x12dec0('0x15')],'path':_[_0x12dec0('0x2e')](_0xa4285e)?undefined:util[_0x12dec0('0x7')](_0x12dec0('0x3a'),_0xa4285e[_0x12dec0('0x14')]),'fax':_['isNil'](_0x4c6608[_0x12dec0('0x19')])?undefined:_0x4c6608[_0x12dec0('0x19')],'AttachmentId':_0x4c6608[_0x12dec0('0x65')]},client9002);})[_0x2b58bb('0x49')](respondWithResult(_0x20eaac,0xc9))[_0x2b58bb('0x5b')](handleError(_0x20eaac,null));},exports[_0x21345f('0x6e')]=function(_0x3c0975,_0x15492d){const _0x5e5b87=_0x21345f,_0x1ad04e=path[_0x5e5b87('0x40')](config[_0x5e5b87('0x6f')],_0x5e5b87('0x38'),_0x5e5b87('0x1b'),'attachments');return db['FaxMessage'][_0x5e5b87('0x66')]({'where':{'id':_0x3c0975[_0x5e5b87('0x4')]['id']},'include':[{'model':db[_0x5e5b87('0x18')],'as':'Attachment'}]})['then'](handleEntityNotFound(_0x15492d,null))['then'](function(_0x125674){const _0x48ebfa=_0x5e5b87;if(_0x125674)return _0x15492d['download'](path['join'](_0x1ad04e,_0x125674['Attachment'][_0x48ebfa('0x14')]));})[_0x5e5b87('0x5b')](handleError(_0x15492d,null));}; \ No newline at end of file diff --git a/server/api/faxMessage/faxMessage.events.js b/server/api/faxMessage/faxMessage.events.js index 985ef5e..3df8360 100644 --- a/server/api/faxMessage/faxMessage.events.js +++ b/server/api/faxMessage/faxMessage.events.js @@ -1 +1 @@ -const a206_0x1389=['events','exports','remove','undefined','addHook','emit','update','save','FaxMessage','setMaxListeners'];(function(_0x57bf1d,_0x1389e2){const _0x5e4851=function(_0x358d34){while(--_0x358d34){_0x57bf1d['push'](_0x57bf1d['shift']());}};_0x5e4851(++_0x1389e2);}(a206_0x1389,0xf7));const a206_0x5e48=function(_0x57bf1d,_0x1389e2){_0x57bf1d=_0x57bf1d-0x0;let _0x5e4851=a206_0x1389[_0x57bf1d];return _0x5e4851;};const _0x5d30e5=a206_0x5e48;'use strict';const EventEmitter=require(_0x5d30e5('0x3')),FaxMessage=require('../../mysqldb')['db'][_0x5d30e5('0x1')],FaxMessageEvents=new EventEmitter();FaxMessageEvents[_0x5d30e5('0x2')](0x0);const events={'afterCreate':_0x5d30e5('0x0'),'afterUpdate':_0x5d30e5('0x9'),'afterDestroy':_0x5d30e5('0x5')};function emitEvent(_0x358d34){return function(_0x2e5f1e){const _0xd0089c=a206_0x5e48;FaxMessageEvents[_0xd0089c('0x8')](_0x358d34+':'+_0x2e5f1e['id'],_0x2e5f1e),FaxMessageEvents[_0xd0089c('0x8')](_0x358d34,_0x2e5f1e);};}for(const e in events){if(typeof events[e]!==_0x5d30e5('0x6')){const event=events[e];FaxMessage[_0x5d30e5('0x7')](e,emitEvent(event));}}module[_0x5d30e5('0x4')]=FaxMessageEvents; \ No newline at end of file +const a206_0x3b35=['FaxMessage','../../mysqldb','emit','exports','setMaxListeners','addHook','remove'];(function(_0x5bfab2,_0x3b356b){const _0x866b75=function(_0x37e14b){while(--_0x37e14b){_0x5bfab2['push'](_0x5bfab2['shift']());}};_0x866b75(++_0x3b356b);}(a206_0x3b35,0x16b));const a206_0x866b=function(_0x5bfab2,_0x3b356b){_0x5bfab2=_0x5bfab2-0x0;let _0x866b75=a206_0x3b35[_0x5bfab2];return _0x866b75;};const _0xabd62e=a206_0x866b;'use strict';const EventEmitter=require('events'),FaxMessage=require(_0xabd62e('0x2'))['db'][_0xabd62e('0x1')],FaxMessageEvents=new EventEmitter();FaxMessageEvents[_0xabd62e('0x5')](0x0);const events={'afterCreate':'save','afterUpdate':'update','afterDestroy':_0xabd62e('0x0')};function emitEvent(_0x37e14b){return function(_0x108f4a){const _0x3c9a88=a206_0x866b;FaxMessageEvents[_0x3c9a88('0x3')](_0x37e14b+':'+_0x108f4a['id'],_0x108f4a),FaxMessageEvents[_0x3c9a88('0x3')](_0x37e14b,_0x108f4a);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];FaxMessage[_0xabd62e('0x6')](e,emitEvent(event));}}module[_0xabd62e('0x4')]=FaxMessageEvents; \ No newline at end of file diff --git a/server/api/faxMessage/faxMessage.model.js b/server/api/faxMessage/faxMessage.model.js index f41d868..5f19e38 100644 --- a/server/api/faxMessage/faxMessage.model.js +++ b/server/api/faxMessage/faxMessage.model.js @@ -1 +1 @@ -const a207_0xd688=['catch','fti_fax_messages','createdAt','isNil','out','FaxInteractionId','exports','./faxMessage.attributes','FaxMessage','get','FaxInteraction','toLowerCase','fax_messages','UserId','lodash','update','define','utf8mb4','utf8mb4_unicode_ci','direction'];(function(_0x4a4951,_0xd68838){const _0x5197ad=function(_0x2d604c){while(--_0x2d604c){_0x4a4951['push'](_0x4a4951['shift']());}};_0x5197ad(++_0xd68838);}(a207_0xd688,0x157));const a207_0x5197=function(_0x4a4951,_0xd68838){_0x4a4951=_0x4a4951-0x0;let _0x5197ad=a207_0xd688[_0x4a4951];return _0x5197ad;};const _0x383999=a207_0x5197;'use strict';const _=require(_0x383999('0xb')),attributes=require(_0x383999('0x4'));module[_0x383999('0x3')]=function(_0x2d604c){const _0x12ee30=_0x383999,_0x1f9c17=_0x2d604c['models'],_0x5aba16=_0x2d604c[_0x12ee30('0xd')](_0x12ee30('0x5'),attributes,{'tableName':_0x12ee30('0x9'),'paranoid':![],'indexes':[{'name':_0x12ee30('0x12'),'fields':['body'],'type':'FULLTEXT'}],'timestamps':!![],'hooks':{'afterCreate':function(_0x175748){const _0x1f79d5=_0x12ee30,_0xb05570=_0x175748[_0x1f79d5('0x6')]({'plain':!![]});(_0xb05570['direction']['toLowerCase']()==='in'||_0xb05570[_0x1f79d5('0x10')][_0x1f79d5('0x8')]()===_0x1f79d5('0x1')&&!_0xb05570['secret']&&!_[_0x1f79d5('0x0')](_0xb05570[_0x1f79d5('0xa')]))&&_0x1f9c17[_0x1f79d5('0x7')]['findOne']({'where':{'id':_0xb05570[_0x1f79d5('0x2')]}})['then'](function(_0xccfcac){const _0x4a9027=_0x1f79d5;_0xccfcac&&_0xccfcac[_0x4a9027('0xc')]({'lastMsgAt':_0xb05570[_0x4a9027('0x13')],'lastMsgDirection':_0xb05570[_0x4a9027('0x10')][_0x4a9027('0x8')]()});})[_0x1f79d5('0x11')](function(_0x1d2b8f){console['error'](_0x1d2b8f);});}},'charset':_0x12ee30('0xe'),'collate':_0x12ee30('0xf')});return _0x5aba16;}; \ No newline at end of file +const a207_0x3149=['./faxMessage.attributes','body','out','FULLTEXT','FaxInteraction','fti_fax_messages','FaxInteractionId','createdAt','then','error','fax_messages','FaxMessage','isNil','toLowerCase','direction','UserId','exports','define','get','catch'];(function(_0x4259b3,_0x314945){const _0x55c6af=function(_0x5e8c96){while(--_0x5e8c96){_0x4259b3['push'](_0x4259b3['shift']());}};_0x55c6af(++_0x314945);}(a207_0x3149,0x183));const a207_0x55c6=function(_0x4259b3,_0x314945){_0x4259b3=_0x4259b3-0x0;let _0x55c6af=a207_0x3149[_0x4259b3];return _0x55c6af;};const _0x2573ff=a207_0x55c6;'use strict';const _=require('lodash'),attributes=require(_0x2573ff('0xd'));module[_0x2573ff('0x9')]=function(_0x5e8c96){const _0x1ceb19=_0x2573ff,_0x5d8cac=_0x5e8c96['models'],_0x1faaec=_0x5e8c96[_0x1ceb19('0xa')](_0x1ceb19('0x4'),attributes,{'tableName':_0x1ceb19('0x3'),'paranoid':![],'indexes':[{'name':_0x1ceb19('0x12'),'fields':[_0x1ceb19('0xe')],'type':_0x1ceb19('0x10')}],'timestamps':!![],'hooks':{'afterCreate':function(_0x4d180e){const _0x45f330=_0x1ceb19,_0x2aa321=_0x4d180e[_0x45f330('0xb')]({'plain':!![]});(_0x2aa321['direction'][_0x45f330('0x6')]()==='in'||_0x2aa321[_0x45f330('0x7')][_0x45f330('0x6')]()===_0x45f330('0xf')&&!_0x2aa321['secret']&&!_[_0x45f330('0x5')](_0x2aa321[_0x45f330('0x8')]))&&_0x5d8cac[_0x45f330('0x11')]['findOne']({'where':{'id':_0x2aa321[_0x45f330('0x13')]}})[_0x45f330('0x1')](function(_0xeda0ad){const _0x31fd14=_0x45f330;_0xeda0ad&&_0xeda0ad['update']({'lastMsgAt':_0x2aa321[_0x31fd14('0x0')],'lastMsgDirection':_0x2aa321[_0x31fd14('0x7')][_0x31fd14('0x6')]()});})[_0x45f330('0xc')](function(_0x1558af){const _0x1ccffa=_0x45f330;console[_0x1ccffa('0x2')](_0x1558af);});}},'charset':'utf8mb4','collate':'utf8mb4_unicode_ci'});return _0x1faaec;}; \ No newline at end of file diff --git a/server/api/faxMessage/faxMessage.rpc.js b/server/api/faxMessage/faxMessage.rpc.js index 776d94a..b9e0849 100644 --- a/server/api/faxMessage/faxMessage.rpc.js +++ b/server/api/faxMessage/faxMessage.rpc.js @@ -1 +1 @@ -const a208_0x243f=['message','stringify','error','../../mysqldb','raw','then','./faxMessage.socket','../../config/logger','catch','limit','create','CreateFaxMessage','rpc','FaxMessage','body','UpdateFaxMessage','debug','options','info','register'];(function(_0x1620a3,_0x243f7c){const _0x59f4ba=function(_0x34d8d5){while(--_0x34d8d5){_0x1620a3['push'](_0x1620a3['shift']());}};_0x59f4ba(++_0x243f7c);}(a208_0x243f,0x1e9));const a208_0x59f4=function(_0x1620a3,_0x243f7c){_0x1620a3=_0x1620a3-0x0;let _0x59f4ba=a208_0x243f[_0x1620a3];return _0x59f4ba;};const _0x51da74=a208_0x59f4;'use strict';const db=require(_0x51da74('0xe'))['db'],logger=require(_0x51da74('0x12'))(_0x51da74('0x3')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x51da74('0x11'))[_0x51da74('0xa')](socket),exports[_0x51da74('0x2')]=function(_0x34d8d5){const _0x23af94=this;return new Promise(function(_0x457e13,_0x5bd767){const _0x2464c5=a208_0x59f4;return db[_0x2464c5('0x4')][_0x2464c5('0x1')](_0x34d8d5[_0x2464c5('0x5')],{'raw':_0x34d8d5[_0x2464c5('0x8')]?_0x34d8d5[_0x2464c5('0x8')][_0x2464c5('0xf')]===undefined?!![]:![]:!![]})[_0x2464c5('0x10')](function(_0x44c887){const _0x1b550f=_0x2464c5;logger[_0x1b550f('0x9')](_0x1b550f('0x2'),_0x34d8d5),logger['debug'](_0x1b550f('0x2'),_0x34d8d5,JSON[_0x1b550f('0xc')](_0x44c887)),_0x457e13(_0x44c887);})['catch'](function(_0xf5f09c){const _0x5e1cec=_0x2464c5;logger[_0x5e1cec('0xd')]('CreateFaxMessage',_0xf5f09c[_0x5e1cec('0xb')],_0x34d8d5),_0x5bd767(_0x23af94[_0x5e1cec('0xd')](0x1f4,_0xf5f09c[_0x5e1cec('0xb')]));});});},exports[_0x51da74('0x6')]=function(_0x576217){const _0x35d413=this;return new Promise(function(_0x2de785,_0x27d064){const _0x4e9fec=a208_0x59f4;return db[_0x4e9fec('0x4')]['update'](_0x576217[_0x4e9fec('0x5')],{'raw':_0x576217['options']?_0x576217[_0x4e9fec('0x8')][_0x4e9fec('0xf')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x576217['options']?_0x576217[_0x4e9fec('0x8')]['where']||null:null,'attributes':_0x576217[_0x4e9fec('0x8')]?_0x576217[_0x4e9fec('0x8')]['attributes']||null:null,'limit':_0x576217[_0x4e9fec('0x8')]?_0x576217[_0x4e9fec('0x8')][_0x4e9fec('0x0')]||null:null})[_0x4e9fec('0x10')](function(_0x24ff4d){const _0x525617=_0x4e9fec;logger[_0x525617('0x9')]('UpdateFaxMessage',_0x576217),logger[_0x525617('0x7')](_0x525617('0x6'),_0x576217,JSON[_0x525617('0xc')](_0x24ff4d)),_0x2de785(_0x24ff4d);})[_0x4e9fec('0x13')](function(_0x55fb33){const _0x2175b2=_0x4e9fec;logger[_0x2175b2('0xd')](_0x2175b2('0x6'),_0x55fb33[_0x2175b2('0xb')],_0x576217),_0x27d064(_0x35d413['error'](0x1f4,_0x55fb33[_0x2175b2('0xb')]));});});}; \ No newline at end of file +const a208_0x10aa=['options','catch','error','update','raw','CreateFaxMessage','rpc','info','FaxMessage','body','message','../../mysqldb','register','debug','stringify','then','UpdateFaxMessage','where','../../rediscache','./faxMessage.socket','limit'];(function(_0x56f0e8,_0x10aada){const _0x141ac3=function(_0x1c5caf){while(--_0x1c5caf){_0x56f0e8['push'](_0x56f0e8['shift']());}};_0x141ac3(++_0x10aada);}(a208_0x10aa,0x189));const a208_0x141a=function(_0x56f0e8,_0x10aada){_0x56f0e8=_0x56f0e8-0x0;let _0x141ac3=a208_0x10aa[_0x56f0e8];return _0x141ac3;};const _0x2c0e5e=a208_0x141a;'use strict';const db=require(_0x2c0e5e('0x11'))['db'],logger=require('../../config/logger')(_0x2c0e5e('0xc')),{getSocket}=require(_0x2c0e5e('0x3')),socket=getSocket();require(_0x2c0e5e('0x4'))[_0x2c0e5e('0x12')](socket),exports[_0x2c0e5e('0xb')]=function(_0x1c5caf){const _0x7c33f8=this;return new Promise(function(_0x152eeb,_0x449eff){const _0x54223d=a208_0x141a;return db[_0x54223d('0xe')]['create'](_0x1c5caf[_0x54223d('0xf')],{'raw':_0x1c5caf[_0x54223d('0x6')]?_0x1c5caf['options']['raw']===undefined?!![]:![]:!![]})['then'](function(_0x54e238){const _0x58c0fa=_0x54223d;logger[_0x58c0fa('0xd')](_0x58c0fa('0xb'),_0x1c5caf),logger[_0x58c0fa('0x13')](_0x58c0fa('0xb'),_0x1c5caf,JSON[_0x58c0fa('0x14')](_0x54e238)),_0x152eeb(_0x54e238);})['catch'](function(_0x29ab23){const _0x5d66cc=_0x54223d;logger[_0x5d66cc('0x8')](_0x5d66cc('0xb'),_0x29ab23[_0x5d66cc('0x10')],_0x1c5caf),_0x449eff(_0x7c33f8['error'](0x1f4,_0x29ab23[_0x5d66cc('0x10')]));});});},exports[_0x2c0e5e('0x1')]=function(_0x38249c){const _0x21cfba=this;return new Promise(function(_0x34c2d2,_0x449516){const _0x5fbf0=a208_0x141a;return db['FaxMessage'][_0x5fbf0('0x9')](_0x38249c[_0x5fbf0('0xf')],{'raw':_0x38249c[_0x5fbf0('0x6')]?_0x38249c[_0x5fbf0('0x6')][_0x5fbf0('0xa')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x38249c[_0x5fbf0('0x6')]?_0x38249c['options'][_0x5fbf0('0x2')]||null:null,'attributes':_0x38249c['options']?_0x38249c[_0x5fbf0('0x6')]['attributes']||null:null,'limit':_0x38249c[_0x5fbf0('0x6')]?_0x38249c['options'][_0x5fbf0('0x5')]||null:null})[_0x5fbf0('0x0')](function(_0x12cd9f){const _0x46da79=_0x5fbf0;logger[_0x46da79('0xd')](_0x46da79('0x1'),_0x38249c),logger[_0x46da79('0x13')](_0x46da79('0x1'),_0x38249c,JSON[_0x46da79('0x14')](_0x12cd9f)),_0x34c2d2(_0x12cd9f);})[_0x5fbf0('0x7')](function(_0x1d3b0a){const _0x441268=_0x5fbf0;logger[_0x441268('0x8')](_0x441268('0x1'),_0x1d3b0a[_0x441268('0x10')],_0x38249c),_0x449516(_0x21cfba['error'](0x1f4,_0x1d3b0a[_0x441268('0x10')]));});});}; \ No newline at end of file diff --git a/server/api/faxMessage/faxMessage.socket.js b/server/api/faxMessage/faxMessage.socket.js index c1eea86..6355858 100644 --- a/server/api/faxMessage/faxMessage.socket.js +++ b/server/api/faxMessage/faxMessage.socket.js @@ -1 +1 @@ -const a209_0x361c=['save','faxMessage:','emit','register','./faxMessage.events','update'];(function(_0x4fa5e5,_0x361c74){const _0x52e90e=function(_0x3b8d88){while(--_0x3b8d88){_0x4fa5e5['push'](_0x4fa5e5['shift']());}};_0x52e90e(++_0x361c74);}(a209_0x361c,0x68));const a209_0x52e9=function(_0x4fa5e5,_0x361c74){_0x4fa5e5=_0x4fa5e5-0x0;let _0x52e90e=a209_0x361c[_0x4fa5e5];return _0x52e90e;};const _0x585a97=a209_0x52e9;'use strict';const FaxMessageEvents=require(_0x585a97('0x2')),events=[_0x585a97('0x4'),'remove',_0x585a97('0x3')];function createListener(_0x3b8d88,_0xd73fc4){return function(_0x378596){const _0x2c1dca=a209_0x52e9;_0xd73fc4[_0x2c1dca('0x0')](_0x3b8d88,_0x378596);};}exports[_0x585a97('0x1')]=function(_0x476734){const _0x55754a=_0x585a97;for(let _0x7aa0c4=0x0,_0x53a68c=events['length'];_0x7aa0c4<_0x53a68c;_0x7aa0c4++){const _0xb62566=events[_0x7aa0c4],_0x34dbfa=createListener(_0x55754a('0x5')+_0xb62566,_0x476734);FaxMessageEvents['on'](_0xb62566,_0x34dbfa);}}; \ No newline at end of file +const a209_0x1807=['register','length','update','save','faxMessage:','remove'];(function(_0x8d96fc,_0x1807c4){const _0x234aae=function(_0x35627c){while(--_0x35627c){_0x8d96fc['push'](_0x8d96fc['shift']());}};_0x234aae(++_0x1807c4);}(a209_0x1807,0x177));const a209_0x234a=function(_0x8d96fc,_0x1807c4){_0x8d96fc=_0x8d96fc-0x0;let _0x234aae=a209_0x1807[_0x8d96fc];return _0x234aae;};const _0x2802f2=a209_0x234a;'use strict';const FaxMessageEvents=require('./faxMessage.events'),events=[_0x2802f2('0x0'),_0x2802f2('0x2'),_0x2802f2('0x5')];function createListener(_0x35627c,_0x5ee560){return function(_0x1f1a8b){_0x5ee560['emit'](_0x35627c,_0x1f1a8b);};}exports[_0x2802f2('0x3')]=function(_0x5539a9){const _0x4f7380=_0x2802f2;for(let _0x2a4895=0x0,_0x122235=events[_0x4f7380('0x4')];_0x2a4895<_0x122235;_0x2a4895++){const _0xf5ab4b=events[_0x2a4895],_0x356055=createListener(_0x4f7380('0x1')+_0xf5ab4b,_0x5539a9);FaxMessageEvents['on'](_0xf5ab4b,_0x356055);}}; \ No newline at end of file diff --git a/server/api/faxMessage/index.js b/server/api/faxMessage/index.js index 162346f..0d1bd23 100644 --- a/server/api/faxMessage/index.js +++ b/server/api/faxMessage/index.js @@ -1 +1 @@ -const a210_0x1531=['reject','/:id/reject','index','/:id/accept','show','express','Router','update','faxmessage:create','isAuthenticated','/describe','download','put','/:id','./faxMessage.controller','describe','accept','delete','exports','destroy','get','/:id/download','tracked'];(function(_0x251638,_0x15316d){const _0x3ed2aa=function(_0x263b41){while(--_0x263b41){_0x251638['push'](_0x251638['shift']());}};_0x3ed2aa(++_0x15316d);}(a210_0x1531,0x133));const a210_0x3ed2=function(_0x251638,_0x15316d){_0x251638=_0x251638-0x0;let _0x3ed2aa=a210_0x1531[_0x251638];return _0x3ed2aa;};const _0x4ed02c=a210_0x3ed2;'use strict';const express=require(_0x4ed02c('0x14')),router=express[_0x4ed02c('0x15')](),auth=require('../../components/auth/service'),interaction=require('../../components/interaction/service'),controller=require(_0x4ed02c('0x6'));router['get']('/',auth[_0x4ed02c('0x1')](),controller[_0x4ed02c('0x11')]),router[_0x4ed02c('0xc')](_0x4ed02c('0x2'),auth[_0x4ed02c('0x1')](),controller[_0x4ed02c('0x7')]),router['get']('/:id',auth['isAuthenticated'](),controller[_0x4ed02c('0x13')]),router[_0x4ed02c('0xc')](_0x4ed02c('0xd'),auth['isAuthenticated'](),controller[_0x4ed02c('0x3')]),router['post']('/',auth[_0x4ed02c('0x1')](),interaction[_0x4ed02c('0xe')]('fax',_0x4ed02c('0x0')),controller['create']),router[_0x4ed02c('0x4')](_0x4ed02c('0x5'),auth['isAuthenticated'](),controller[_0x4ed02c('0x16')]),router[_0x4ed02c('0x4')](_0x4ed02c('0x12'),auth[_0x4ed02c('0x1')](),controller[_0x4ed02c('0x8')]),router[_0x4ed02c('0x4')](_0x4ed02c('0x10'),auth['isAuthenticated'](),controller[_0x4ed02c('0xf')]),router[_0x4ed02c('0x9')](_0x4ed02c('0x5'),auth[_0x4ed02c('0x1')](),controller[_0x4ed02c('0xb')]),module[_0x4ed02c('0xa')]=router; \ No newline at end of file +const a210_0x31a5=['express','update','describe','delete','get','fax','/describe','isAuthenticated','reject','show','/:id/reject','post','download','put','/:id/accept','Router','../../components/auth/service','./faxMessage.controller','tracked','../../components/interaction/service','/:id'];(function(_0x51f835,_0x31a59a){const _0x39c2ac=function(_0x20b285){while(--_0x20b285){_0x51f835['push'](_0x51f835['shift']());}};_0x39c2ac(++_0x31a59a);}(a210_0x31a5,0x1ef));const a210_0x39c2=function(_0x51f835,_0x31a59a){_0x51f835=_0x51f835-0x0;let _0x39c2ac=a210_0x31a5[_0x51f835];return _0x39c2ac;};const _0x277c87=a210_0x39c2;'use strict';const express=require(_0x277c87('0x9')),router=express[_0x277c87('0x3')](),auth=require(_0x277c87('0x4')),interaction=require(_0x277c87('0x7')),controller=require(_0x277c87('0x5'));router[_0x277c87('0xd')]('/',auth[_0x277c87('0x10')](),controller['index']),router[_0x277c87('0xd')](_0x277c87('0xf'),auth[_0x277c87('0x10')](),controller[_0x277c87('0xb')]),router[_0x277c87('0xd')]('/:id',auth[_0x277c87('0x10')](),controller[_0x277c87('0x12')]),router[_0x277c87('0xd')]('/:id/download',auth[_0x277c87('0x10')](),controller[_0x277c87('0x0')]),router[_0x277c87('0x14')]('/',auth[_0x277c87('0x10')](),interaction[_0x277c87('0x6')](_0x277c87('0xe'),'faxmessage:create'),controller['create']),router[_0x277c87('0x1')](_0x277c87('0x8'),auth[_0x277c87('0x10')](),controller[_0x277c87('0xa')]),router[_0x277c87('0x1')](_0x277c87('0x2'),auth[_0x277c87('0x10')](),controller['accept']),router[_0x277c87('0x1')](_0x277c87('0x13'),auth['isAuthenticated'](),controller[_0x277c87('0x11')]),router[_0x277c87('0xc')](_0x277c87('0x8'),auth[_0x277c87('0x10')](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/faxQueue/faxQueue.attributes.js b/server/api/faxQueue/faxQueue.attributes.js index 7b61771..f648741 100644 --- a/server/api/faxQueue/faxQueue.attributes.js +++ b/server/api/faxQueue/faxQueue.attributes.js @@ -1 +1 @@ -const a211_0x4719=['beepall','exports','STRING','INTEGER','name','sequelize'];(function(_0x25ce42,_0x47192a){const _0x255f8b=function(_0x50837){while(--_0x50837){_0x25ce42['push'](_0x25ce42['shift']());}};_0x255f8b(++_0x47192a);}(a211_0x4719,0x128));const a211_0x255f=function(_0x25ce42,_0x47192a){_0x25ce42=_0x25ce42-0x0;let _0x255f8b=a211_0x4719[_0x25ce42];return _0x255f8b;};const _0xe1287e=a211_0x255f;'use strict';const Sequelize=require(_0xe1287e('0x3'));module[_0xe1287e('0x5')]={'name':{'type':Sequelize[_0xe1287e('0x0')],'unique':_0xe1287e('0x2'),'allowNull':![],'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize[_0xe1287e('0x0')]},'timeout':{'type':Sequelize['INTEGER'],'allowNull':![],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize['ENUM']('rrmemory',_0xe1287e('0x4'),'roundrobin'),'allowNull':![]},'lastAgent':{'type':Sequelize[_0xe1287e('0x1')],'defaultValue':0x0}}; \ No newline at end of file +const a211_0x1beb=['name','roundrobin','STRING','rrmemory','exports','INTEGER','ENUM','sequelize','beepall'];(function(_0x346b36,_0x1beb34){const _0x7283c3=function(_0x2649c7){while(--_0x2649c7){_0x346b36['push'](_0x346b36['shift']());}};_0x7283c3(++_0x1beb34);}(a211_0x1beb,0x179));const a211_0x7283=function(_0x346b36,_0x1beb34){_0x346b36=_0x346b36-0x0;let _0x7283c3=a211_0x1beb[_0x346b36];return _0x7283c3;};const _0x70ec38=a211_0x7283;'use strict';const Sequelize=require(_0x70ec38('0x8'));module[_0x70ec38('0x5')]={'name':{'type':Sequelize[_0x70ec38('0x3')],'unique':_0x70ec38('0x1'),'allowNull':![],'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize[_0x70ec38('0x3')]},'timeout':{'type':Sequelize[_0x70ec38('0x6')],'allowNull':![],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x70ec38('0x7')](_0x70ec38('0x4'),_0x70ec38('0x0'),_0x70ec38('0x2')),'allowNull':![]},'lastAgent':{'type':Sequelize['INTEGER'],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/faxQueue/faxQueue.controller.js b/server/api/faxQueue/faxQueue.controller.js index 6eeab96..6223693 100644 --- a/server/api/faxQueue/faxQueue.controller.js +++ b/server/api/faxQueue/faxQueue.controller.js @@ -1 +1 @@ -const a212_0x5bb8=['userFaxQueue:remove','Unable\x20to\x20retrieve\x20the\x20current\x20user','fields','catch','body','join','update','findAll','updatedAt','send','agent','findAndCountAll','query','pick','rows','UserId','../../components/parsers/qs','voicePause','FaxQueueId\x20=\x20?','role','set','undefined','./faxQueue.socket','attributes','show','get','flatMap','ut.TeamId\x20=\x20tq.TeamId','then','intersection','faxPause','findOrCreate','nolimit','map','like','FaxQueues','status','ut.UserId\x20=\x20?','ids','rawAttributes','index','offset','FaxQueue','user','describe','emit','format','tq.TeamId','keys','limit','from','forEach','destroy','isArray','fieldName','field','findOne','SELECT','removeAgents','union','includes','isEmpty','Team','VIRTUAL','getTeams','order','include','sort','UserProfileResource','key','options','getMembers','count','filters','sequelize','addAgents','params','includeAll','where','createdAt','value','lodash','autoAssociation','length','sendStatus','model','userFaxQueue:save','api','json','Agents','name','create','merge','User','error','clone','type','omit','each','filter','end','FaxQueueId','UserFaxQueue','../../rediscache','transaction','every','compact','all'];(function(_0x546dc8,_0x5bb835){const _0x1d3ea5=function(_0x2bf798){while(--_0x2bf798){_0x546dc8['push'](_0x546dc8['shift']());}};_0x1d3ea5(++_0x5bb835);}(a212_0x5bb8,0x1c7));const a212_0x1d3e=function(_0x546dc8,_0x5bb835){_0x546dc8=_0x546dc8-0x0;let _0x1d3ea5=a212_0x5bb8[_0x546dc8];return _0x1d3ea5;};const _0x40cca2=a212_0x1d3e;'use strict';const util=require('util'),_=require(_0x40cca2('0x3a')),squel=require('squel'),qs=require(_0x40cca2('0x65')),logger=require('../../config/logger')(_0x40cca2('0x40')),{getSocket}=require(_0x40cca2('0x50')),socket=getSocket(),db=require('../../mysqldb')['db'],{Op,QueryTypes}=require('sequelize');require(_0x40cca2('0x6b'))['register'](socket);function respondWithStatusCode(_0x2bf798,_0x26700d){return _0x26700d=_0x26700d||0xcc,function(_0x54ab61){const _0x1bfe66=a212_0x1d3e;if(_0x54ab61)return _0x2bf798[_0x1bfe66('0x3d')](_0x26700d);return _0x2bf798[_0x1bfe66('0xd')](_0x26700d)[_0x1bfe66('0x4d')]();};}function respondWithResult(_0x2c757c,_0x3bfb87){return _0x3bfb87=_0x3bfb87||0xc8,function(_0x2f0620){const _0x358a6f=a212_0x1d3e;if(_0x2f0620)return _0x2c757c[_0x358a6f('0xd')](_0x3bfb87)[_0x358a6f('0x41')](_0x2f0620);};}function respondWithFilteredResult(_0x37ef5b,_0x261740){return function(_0x3e932f){const _0x244e4c=a212_0x1d3e;if(_0x3e932f){const _0x56fffd=_0x3e932f[_0x244e4c('0x31')],_0x27f81c=_0x261740[_0x244e4c('0x12')];let _0x28a703=_0x261740['offset']+_0x261740['limit'],_0x200592;return _0x28a703>=_0x56fffd?(_0x28a703=_0x56fffd,_0x200592=0xc8):_0x200592=0xce,_0x37ef5b[_0x244e4c('0xd')](_0x200592),_0x37ef5b[_0x244e4c('0x69')]('Content-Range',_0x27f81c+'-'+_0x28a703+'/'+_0x56fffd)[_0x244e4c('0x41')](_0x3e932f);}return null;};}function saveUpdates(_0x2dcf47){return function(_0x3b3feb){const _0x29af8e=a212_0x1d3e;if(_0x3b3feb)return _0x3b3feb[_0x29af8e('0x5b')](_0x2dcf47)['then'](function(_0x136341){return _0x136341;});return null;};}function removeEntity(_0xe3571f){return function(_0x496d74){const _0x2f88ba=a212_0x1d3e;if(_0x496d74)return _0x496d74[_0x2f88ba('0x1d')]()[_0x2f88ba('0x5')](function(){const _0x3a7e66=_0x2f88ba,_0x17d209=_0x496d74[_0x3a7e66('0x2')]({'plain':!![]}),_0x523558=_0x3a7e66('0xc');return db[_0x3a7e66('0x2d')]['destroy']({'where':{'type':_0x523558,'resourceId':_0x17d209['id']}})[_0x3a7e66('0x5')](function(){return _0x496d74;});})['then'](function(){const _0x312a88=_0x2f88ba;_0xe3571f[_0x312a88('0xd')](0xcc)[_0x312a88('0x4d')]();});};}function handleEntityNotFound(_0x57719a){return function(_0x3e54f4){return!_0x3e54f4&&_0x57719a['sendStatus'](0x194),_0x3e54f4;};}function handleError(_0x278207,_0x58269d){return _0x58269d=_0x58269d||0x1f4,function(_0x1f555c){const _0xd0489d=a212_0x1d3e;logger[_0xd0489d('0x47')](_0x1f555c['stack']),_0x1f555c['name']&&delete _0x1f555c[_0xd0489d('0x43')],_0x278207[_0xd0489d('0xd')](_0x58269d)[_0xd0489d('0x5e')](_0x1f555c);};}exports[_0x40cca2('0x11')]=function(_0x3a48cc,_0x1a3924){const _0x752b65=_0x40cca2;let _0x4eae39={};const _0x2edcca={},_0x2bc5eb={'count':0x0,'rows':[]},_0x1ae4f9=_[_0x752b65('0xa')](db['FaxQueue'][_0x752b65('0x10')],function(_0x753d92){const _0x3649f0=_0x752b65;return{'name':_0x753d92[_0x3649f0('0x1f')],'type':_0x753d92[_0x3649f0('0x49')][_0x3649f0('0x2e')]};});_0x2edcca[_0x752b65('0x3e')]=_[_0x752b65('0xa')](_0x1ae4f9,_0x752b65('0x43')),_0x2edcca[_0x752b65('0x61')]=_['keys'](_0x3a48cc[_0x752b65('0x61')]),_0x2edcca[_0x752b65('0x32')]=_[_0x752b65('0x6')](_0x2edcca[_0x752b65('0x3e')],_0x2edcca['query']),_0x4eae39['attributes']=_[_0x752b65('0x6')](_0x2edcca['model'],qs[_0x752b65('0x57')](_0x3a48cc[_0x752b65('0x61')][_0x752b65('0x57')])),_0x4eae39[_0x752b65('0x0')]=_0x4eae39[_0x752b65('0x0')][_0x752b65('0x3c')]?_0x4eae39[_0x752b65('0x0')]:_0x2edcca[_0x752b65('0x3e')];typeof _0x3a48cc['query'][_0x752b65('0x9')]===_0x752b65('0x6a')&&(_0x4eae39[_0x752b65('0x1a')]=qs[_0x752b65('0x1a')](_0x3a48cc[_0x752b65('0x61')][_0x752b65('0x1a')]),_0x4eae39[_0x752b65('0x12')]=qs[_0x752b65('0x12')](_0x3a48cc['query'][_0x752b65('0x12')]));_0x4eae39[_0x752b65('0x2a')]=qs['sort'](_0x3a48cc['query'][_0x752b65('0x2c')]),_0x4eae39['where']=qs[_0x752b65('0x32')](_[_0x752b65('0x62')](_0x3a48cc[_0x752b65('0x61')],_0x2edcca[_0x752b65('0x32')]),_0x1ae4f9);_0x3a48cc[_0x752b65('0x61')][_0x752b65('0x4c')]&&(_0x4eae39[_0x752b65('0x37')]=_[_0x752b65('0x45')](_0x4eae39[_0x752b65('0x37')],{[Op['or']]:_[_0x752b65('0xa')](_0x1ae4f9,function(_0x24280a){const _0x52784c=_0x752b65;if(_0x24280a[_0x52784c('0x49')]!==_0x52784c('0x28')){const _0x218d19={};return _0x218d19[_0x24280a[_0x52784c('0x43')]]={[Op[_0x52784c('0xb')]]:'%'+_0x3a48cc[_0x52784c('0x61')][_0x52784c('0x4c')]+'%'},_0x218d19;}})}));_0x4eae39=_['merge']({},_0x4eae39,_0x3a48cc[_0x752b65('0x2f')]);const _0x3ea2c2={'where':_0x4eae39[_0x752b65('0x37')]};return db[_0x752b65('0x13')][_0x752b65('0x31')](_0x3ea2c2)[_0x752b65('0x5')](function(_0x598fca){const _0x23cdbe=_0x752b65;return _0x2bc5eb['count']=_0x598fca,_0x3a48cc[_0x23cdbe('0x61')][_0x23cdbe('0x36')]&&(_0x4eae39[_0x23cdbe('0x2b')]=[{'all':!![]}]),db[_0x23cdbe('0x13')][_0x23cdbe('0x5c')](_0x4eae39);})[_0x752b65('0x5')](function(_0x2ceadd){const _0x5e588f=_0x752b65;return _0x2bc5eb[_0x5e588f('0x63')]=_0x2ceadd,_0x2bc5eb;})[_0x752b65('0x5')](respondWithFilteredResult(_0x1a3924,_0x4eae39))[_0x752b65('0x58')](handleError(_0x1a3924,null));},exports[_0x40cca2('0x1')]=function(_0x356b47,_0x4625c6){const _0xd3df53=_0x40cca2;let _0x5e3874={'raw':!![],'where':{'id':_0x356b47['params']['id']}};const _0x109ba5={};return _0x109ba5['model']=_[_0xd3df53('0x19')](db[_0xd3df53('0x13')]['rawAttributes']),_0x109ba5[_0xd3df53('0x61')]=_[_0xd3df53('0x19')](_0x356b47[_0xd3df53('0x61')]),_0x109ba5['filters']=_[_0xd3df53('0x6')](_0x109ba5[_0xd3df53('0x3e')],_0x109ba5[_0xd3df53('0x61')]),_0x5e3874['attributes']=_['intersection'](_0x109ba5[_0xd3df53('0x3e')],qs[_0xd3df53('0x57')](_0x356b47[_0xd3df53('0x61')][_0xd3df53('0x57')])),_0x5e3874[_0xd3df53('0x0')]=_0x5e3874[_0xd3df53('0x0')][_0xd3df53('0x3c')]?_0x5e3874['attributes']:_0x109ba5['model'],_0x356b47[_0xd3df53('0x61')][_0xd3df53('0x36')]&&(_0x5e3874[_0xd3df53('0x2b')]=[{'all':!![]}]),_0x5e3874=_[_0xd3df53('0x45')]({},_0x5e3874,_0x356b47[_0xd3df53('0x2f')]),db[_0xd3df53('0x13')][_0xd3df53('0x21')](_0x5e3874)['then'](handleEntityNotFound(_0x4625c6,null))[_0xd3df53('0x5')](respondWithResult(_0x4625c6,null))[_0xd3df53('0x58')](handleError(_0x4625c6,null));},exports[_0x40cca2('0x44')]=function(_0x1ddee8,_0x219e9a){const _0x31f5d5=_0x40cca2;return db['FaxQueue'][_0x31f5d5('0x44')](_0x1ddee8['body'],{})[_0x31f5d5('0x5')](function(_0x47c42a){const _0x312dba=_0x31f5d5,_0x3eadc3=_0x1ddee8['user']['get']({'plain':!![]});if(!_0x3eadc3)throw new Error(_0x312dba('0x56'));if(_0x3eadc3[_0x312dba('0x68')]===_0x312dba('0x14')){const _0x285f35=_0x47c42a[_0x312dba('0x2')]({'plain':!![]}),_0x10d672='FaxQueues';return db['UserProfileSection'][_0x312dba('0x21')]({'where':{'name':_0x10d672,'userProfileId':_0x3eadc3['userProfileId']},'raw':!![]})[_0x312dba('0x5')](function(_0x384b23){const _0x1d759c=_0x312dba;return _0x384b23&&_0x384b23[_0x1d759c('0x3b')]===0x0?db[_0x1d759c('0x2d')][_0x1d759c('0x44')]({'name':_0x285f35[_0x1d759c('0x43')],'resourceId':_0x285f35['id'],'type':_0x384b23['name'],'sectionId':_0x384b23['id']},{})[_0x1d759c('0x5')](function(){return _0x47c42a;}):_0x47c42a;})[_0x312dba('0x58')](function(_0x5ef140){const _0x3aa279=_0x312dba;logger[_0x3aa279('0x47')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x5ef140);throw _0x5ef140;});}return _0x47c42a;})[_0x31f5d5('0x5')](respondWithResult(_0x219e9a,0xc9))[_0x31f5d5('0x58')](handleError(_0x219e9a,null));},exports[_0x40cca2('0x5b')]=function(_0x35a2f5,_0x4555f3){const _0x3fa511=_0x40cca2;return _0x35a2f5[_0x3fa511('0x59')]['id']&&delete _0x35a2f5[_0x3fa511('0x59')]['id'],db[_0x3fa511('0x13')][_0x3fa511('0x21')]({'where':{'id':_0x35a2f5['params']['id']}})[_0x3fa511('0x5')](handleEntityNotFound(_0x4555f3,null))['then'](saveUpdates(_0x35a2f5[_0x3fa511('0x59')],null))[_0x3fa511('0x5')](respondWithResult(_0x4555f3,null))[_0x3fa511('0x58')](handleError(_0x4555f3,null));},exports['destroy']=function(_0x3e74a5,_0x30f4df){const _0x1c1e4f=_0x40cca2;return db['FaxQueue'][_0x1c1e4f('0x21')]({'where':{'id':_0x3e74a5[_0x1c1e4f('0x35')]['id']}})['then'](handleEntityNotFound(_0x30f4df,null))['then'](removeEntity(_0x30f4df,null))[_0x1c1e4f('0x58')](handleError(_0x30f4df,null));},exports[_0x40cca2('0x15')]=function(_0xd9fae0,_0x1048d6){const _0x4a23d7=_0x40cca2;return db[_0x4a23d7('0x13')][_0x4a23d7('0x15')]()[_0x4a23d7('0x5')](respondWithResult(_0x1048d6,null))['catch'](handleError(_0x1048d6,null));},exports[_0x40cca2('0x30')]=function(_0x3f7d17,_0x4e346a){const _0x510e36=_0x40cca2;let _0x4ac417={'raw':!![],'where':{}};const _0x319995={};let _0x1d54c9;return db[_0x510e36('0x13')][_0x510e36('0x21')]({'where':{'id':_0x3f7d17[_0x510e36('0x35')]['id']}})[_0x510e36('0x5')](handleEntityNotFound(_0x4e346a,null))[_0x510e36('0x5')](function(_0x1d0267){const _0x906236=_0x510e36;if(_0x1d0267)return _0x1d54c9=_0x1d0267[_0x906236('0x2')]({'plain':!![]}),_0x319995[_0x906236('0x3e')]=_[_0x906236('0x19')](db[_0x906236('0x4f')]['rawAttributes']),_0x319995[_0x906236('0x61')]=_[_0x906236('0x19')](_0x3f7d17[_0x906236('0x61')]),_0x319995['filters']=_[_0x906236('0x6')](_0x319995[_0x906236('0x3e')],_0x319995['query']),_0x4ac417[_0x906236('0x0')]=_['intersection'](_0x319995[_0x906236('0x3e')],qs[_0x906236('0x57')](_0x3f7d17[_0x906236('0x61')]['fields'])),_0x4ac417[_0x906236('0x0')]=_0x4ac417[_0x906236('0x0')][_0x906236('0x3c')]?_0x4ac417[_0x906236('0x0')]:_0x319995[_0x906236('0x3e')],typeof _0x3f7d17[_0x906236('0x61')][_0x906236('0x9')]==='undefined'&&(_0x4ac417['limit']=qs[_0x906236('0x1a')](_0x3f7d17[_0x906236('0x61')][_0x906236('0x1a')]),_0x4ac417[_0x906236('0x12')]=qs[_0x906236('0x12')](_0x3f7d17[_0x906236('0x61')][_0x906236('0x12')])),_0x4ac417['order']=qs[_0x906236('0x2c')](_0x3f7d17[_0x906236('0x61')]['sort']),_0x4ac417['where']=qs[_0x906236('0x32')](_['pick'](_0x3f7d17['query'],_0x319995[_0x906236('0x32')])),_0x4ac417['where'][_0x906236('0x4e')]=_0x1d0267['id'],_0x3f7d17['query'][_0x906236('0x4c')]&&(_0x4ac417[_0x906236('0x37')]=_[_0x906236('0x45')](_0x4ac417[_0x906236('0x37')],{[Op['or']]:_['map'](_0x4ac417['attributes'],function(_0x14c049){const _0x5de7aa=_0x906236,_0x4b6548={};return _0x4b6548[_0x14c049]={[Op['like']]:'%'+_0x3f7d17['query'][_0x5de7aa('0x4c')]+'%'},_0x4b6548;})})),_0x4ac417=_[_0x906236('0x45')]({},_0x4ac417,_0x3f7d17[_0x906236('0x2f')]),db[_0x906236('0x4f')][_0x906236('0x5c')](_0x4ac417);})[_0x510e36('0x5')](function(_0x25f4d7){const _0x3085c0=_0x510e36;if(_0x25f4d7)return db[_0x3085c0('0x46')][_0x3085c0('0x60')]({'where':{'id':_[_0x3085c0('0xa')](_0x25f4d7,_0x3085c0('0x64')),'role':_0x3085c0('0x5f')},'attributes':['id',_0x3085c0('0x43'),_0x3085c0('0x7'),'updatedAt',_0x3085c0('0x38')]});})[_0x510e36('0x5')](function(_0x44f380){const _0x68b61d=_0x510e36;return _0x44f380?{'count':_0x44f380[_0x68b61d('0x31')],'rows':_['map'](_0x44f380[_0x68b61d('0x63')],function(_0x1cebe2){const _0x3e79b0=_0x68b61d;return{'membername':_0x1cebe2['name'],'UserId':_0x1cebe2['id'],'queue_name':_0x1d54c9[_0x3e79b0('0x43')],'FaxQueueId':_0x1d54c9['id'],'interface':util[_0x3e79b0('0x17')]('%s/%s','SIP',_0x1cebe2[_0x3e79b0('0x43')]),'penalty':0x0,'paused':_0x1cebe2['faxPause'],'createdAt':_0x1cebe2[_0x3e79b0('0x38')],'updatedAt':_0x1cebe2[_0x3e79b0('0x5d')]};})}:{'count':0x0,'rows':[]};})[_0x510e36('0x5')](respondWithFilteredResult(_0x4e346a,_0x4ac417))['catch'](handleError(_0x4e346a,null));},exports[_0x40cca2('0x29')]=function(_0x20f181,_0x4648b3){const _0x3dca91=_0x40cca2;let _0x4633e0={};const _0x407509={};let _0x2b30a4,_0x362276;return db[_0x3dca91('0x13')][_0x3dca91('0x21')]({'where':{'id':_0x20f181[_0x3dca91('0x35')]['id']}})[_0x3dca91('0x5')](handleEntityNotFound(_0x4648b3,null))[_0x3dca91('0x5')](function(_0x18fd87){const _0xdffb62=_0x3dca91;if(_0x18fd87)return _0x2b30a4=_0x18fd87,_0x407509['model']=_[_0xdffb62('0x19')](db[_0xdffb62('0x27')][_0xdffb62('0x10')]),_0x407509[_0xdffb62('0x61')]=_[_0xdffb62('0x19')](_0x20f181[_0xdffb62('0x61')]),_0x407509[_0xdffb62('0x32')]=_[_0xdffb62('0x6')](_0x407509[_0xdffb62('0x3e')],_0x407509['query']),_0x4633e0[_0xdffb62('0x0')]=_[_0xdffb62('0x6')](_0x407509[_0xdffb62('0x3e')],qs[_0xdffb62('0x57')](_0x20f181['query'][_0xdffb62('0x57')])),_0x4633e0[_0xdffb62('0x0')]=_0x4633e0[_0xdffb62('0x0')][_0xdffb62('0x3c')]?_0x4633e0[_0xdffb62('0x0')]:_0x407509['model'],_0x4633e0['order']=qs['sort'](_0x20f181[_0xdffb62('0x61')][_0xdffb62('0x2c')]),_0x4633e0[_0xdffb62('0x37')]=qs[_0xdffb62('0x32')](_[_0xdffb62('0x62')](_0x20f181[_0xdffb62('0x61')],_0x407509[_0xdffb62('0x32')])),_0x20f181['query'][_0xdffb62('0x4c')]&&(_0x4633e0['where']=_[_0xdffb62('0x45')](_0x4633e0[_0xdffb62('0x37')],{[Op['or']]:_[_0xdffb62('0xa')](_0x4633e0[_0xdffb62('0x0')],function(_0x362bcb){const _0x5d5d75={};return _0x5d5d75[_0x362bcb]={[Op['like']]:'%'+_0x20f181['query']['filter']+'%'},_0x5d5d75;})})),_0x4633e0=_[_0xdffb62('0x45')]({},_0x4633e0,_0x20f181[_0xdffb62('0x2f')]),_0x2b30a4[_0xdffb62('0x29')](_0x4633e0);})[_0x3dca91('0x5')](function(_0x5e9d60){const _0x4cdc52=_0x3dca91;if(_0x5e9d60)return _0x362276=_0x5e9d60[_0x4cdc52('0x3c')],typeof _0x20f181[_0x4cdc52('0x61')][_0x4cdc52('0x9')]==='undefined'&&(_0x4633e0[_0x4cdc52('0x1a')]=qs[_0x4cdc52('0x1a')](_0x20f181[_0x4cdc52('0x61')][_0x4cdc52('0x1a')]),_0x4633e0[_0x4cdc52('0x12')]=qs[_0x4cdc52('0x12')](_0x20f181[_0x4cdc52('0x61')][_0x4cdc52('0x12')])),_0x2b30a4[_0x4cdc52('0x29')](_0x4633e0);})[_0x3dca91('0x5')](function(_0x53660a){if(_0x53660a)return _0x53660a?{'count':_0x362276,'rows':_0x53660a}:null;})[_0x3dca91('0x5')](respondWithResult(_0x4648b3,null))[_0x3dca91('0x58')](handleError(_0x4648b3,null));},exports['addTeams']=function(_0xa0618c,_0x2bd61f){const _0x2cb529=_0x40cca2,_0x402eb3=_0xa0618c[_0x2cb529('0x59')][_0x2cb529('0xf')];return db['Team'][_0x2cb529('0x5c')]({'where':{'id':_0x402eb3},'attributes':['id'],'include':[{'model':db['User'],'as':'Agents','attributes':['id',_0x2cb529('0x43'),'online',_0x2cb529('0x66'),'interface'],'raw':!![]}]})[_0x2cb529('0x5')](function(_0x14b86d){const _0x49adff=_0x2cb529;if(_0x14b86d){const _0x4f410c=_[_0x49adff('0x3')](_0x14b86d,function(_0x512159){const _0x25faa8=_0x49adff,_0x54bb75=_0x512159['get']({'plain':!![]});return _0x54bb75[_0x25faa8('0x42')];});return db[_0x49adff('0x13')][_0x49adff('0x21')]({'where':{'id':_0xa0618c[_0x49adff('0x35')]['id']}})[_0x49adff('0x5')](function(_0x393f4e){const _0x740bed=_0x49adff;return db[_0x740bed('0x33')][_0x740bed('0x51')](function(_0x21ee75){const _0x316f83=_0x740bed;return _0x393f4e['addTeams'](_0x402eb3,{'transaction':_0x21ee75})[_0x316f83('0x5')](function(){const _0x462cdc=_0x316f83;return Promise[_0x462cdc('0x4b')](_0x4f410c,function(_0x58877e){const _0x18462e=_0x462cdc;return db[_0x18462e('0x4f')][_0x18462e('0x8')]({'where':{'UserId':_0x58877e['id'],'FaxQueueId':_0xa0618c[_0x18462e('0x35')]['id']},'transaction':_0x21ee75});});})[_0x316f83('0x5')](function(){const _0x50c5de=_0x316f83;_0x4f410c[_0x50c5de('0x1c')](function(_0xa56be2){const _0x29c4da=_0x50c5de;socket[_0x29c4da('0x16')](_0x29c4da('0x3f'),{'UserId':_0xa56be2['id'],'FaxQueueId':_0x393f4e['id']});});});});});}})[_0x2cb529('0x5')](respondWithStatusCode(_0x2bd61f,null))[_0x2cb529('0x58')](handleError(_0x2bd61f,null));},exports['removeTeams']=function(_0x49758a,_0x3ea830){const _0x1d2de2=_0x40cca2;return db['Team']['findAll']({'where':{'id':_0x49758a[_0x1d2de2('0x61')][_0x1d2de2('0xf')]},'attributes':['id'],'include':[{'model':db[_0x1d2de2('0x46')],'as':_0x1d2de2('0x42'),'attributes':['id'],'raw':!![]}]})[_0x1d2de2('0x5')](handleEntityNotFound(_0x3ea830,null))[_0x1d2de2('0x5')](function(_0x45b3ce){const _0x41c865=_0x1d2de2,_0x96402a=_[_0x41c865('0xa')](_0x45b3ce,'id');let _0x653df6=[];const _0x4bebb1=[],_0x100075=squel['select']();_0x100075[_0x41c865('0x20')](_0x41c865('0x18'))[_0x41c865('0x1b')]('team_has_fax_queues','tq')[_0x41c865('0x5a')]('user_has_teams','ut',_0x41c865('0x4'))[_0x41c865('0x37')](_0x41c865('0x67'),_0x49758a['params']['id']);for(let _0x24afe3=0x0;_0x24afe3<_0x45b3ce['length'];_0x24afe3+=0x1){const _0xaaad80=_0x45b3ce[_0x24afe3];for(let _0x5d73e7=0x0;_0x5d73e7<_0xaaad80[_0x41c865('0x42')][_0x41c865('0x3c')];_0x5d73e7+=0x1){const _0x196b7e=_0xaaad80[_0x41c865('0x42')][_0x5d73e7],_0x1e2697=_0x100075[_0x41c865('0x48')]();_0x1e2697[_0x41c865('0x37')](_0x41c865('0xe'),_0x196b7e['id']),_0x4bebb1['push'](db[_0x41c865('0x33')][_0x41c865('0x61')](_0x1e2697['toString'](),{'type':QueryTypes[_0x41c865('0x22')]})[_0x41c865('0x5')](function(_0x4e1048){const _0x43a2c3=_0x41c865;if(_0x4e1048[_0x43a2c3('0x3c')]===0x1)return _0x196b7e['id'];else{const _0x73b64f=_[_0x43a2c3('0x52')](_[_0x43a2c3('0xa')](_0x4e1048,'TeamId'),function(_0x38b7ba){const _0x40e168=_0x43a2c3;return _[_0x40e168('0x25')](_0x96402a,_0x38b7ba);});if(_0x73b64f)return _0x196b7e['id'];}}));}}return Promise[_0x41c865('0x54')](_0x4bebb1)[_0x41c865('0x5')](function(_0x296fdf){const _0x135d4a=_0x41c865;return _0x653df6=_(_0x653df6)[_0x135d4a('0x24')](_0x296fdf)[_0x135d4a('0x53')]()[_0x135d4a('0x39')](),db[_0x135d4a('0x13')][_0x135d4a('0x21')]({'where':{'id':_0x49758a[_0x135d4a('0x35')]['id']}})[_0x135d4a('0x5')](function(_0x3799d2){const _0x2089a2=_0x135d4a;return db[_0x2089a2('0x33')][_0x2089a2('0x51')](function(_0x3cccd2){const _0x4261ee=_0x2089a2;return _0x3799d2['removeTeams'](_0x49758a[_0x4261ee('0x61')][_0x4261ee('0xf')],{'transaction':_0x3cccd2})[_0x4261ee('0x5')](function(){const _0x178bc1=_0x4261ee;if(!_[_0x178bc1('0x26')](_0x653df6))return _0x3799d2[_0x178bc1('0x23')](_0x653df6,{'transaction':_0x3cccd2});})['then'](function(){const _0x2a8f01=_0x4261ee;_0x653df6[_0x2a8f01('0x1c')](function(_0x43d647){const _0xbb912d=_0x2a8f01;socket[_0xbb912d('0x16')](_0xbb912d('0x55'),{'UserId':_0x43d647,'FaxQueueId':_0x3799d2['id']});});});});});});})['then'](respondWithStatusCode(_0x3ea830,null))[_0x1d2de2('0x58')](handleError(_0x3ea830,null));},exports[_0x40cca2('0x34')]=function(_0x207b40,_0x33db8b){const _0x389208=_0x40cca2;return db['FaxQueue'][_0x389208('0x21')]({'where':{'id':_0x207b40[_0x389208('0x35')]['id']}})[_0x389208('0x5')](function(_0x1c37c1){const _0x5f37c9=_0x389208;if(_0x1c37c1)return _0x1c37c1[_0x5f37c9('0x34')](_0x207b40['body'][_0x5f37c9('0xf')],{'through':_[_0x5f37c9('0x4a')](_0x207b40[_0x5f37c9('0x59')],[_0x5f37c9('0xf'),'id'])})[_0x5f37c9('0x5')](function(_0xbfc4bc){const _0xb32bf4=_0x5f37c9;for(let _0x4f33d1=0x0;_0x4f33d1<_0x207b40['body'][_0xb32bf4('0xf')][_0xb32bf4('0x3c')];_0x4f33d1+=0x1){socket[_0xb32bf4('0x16')]('userFaxQueue:save',{'UserId':_0x207b40[_0xb32bf4('0x59')][_0xb32bf4('0xf')][_0x4f33d1],'FaxQueueId':_0x207b40[_0xb32bf4('0x35')]['id']});}return _0xbfc4bc;});})[_0x389208('0x5')](respondWithResult(_0x33db8b,null))[_0x389208('0x58')](handleError(_0x33db8b,null));},exports[_0x40cca2('0x23')]=function(_0x3c0391,_0x34b12f){const _0x2894c2=_0x40cca2;return db[_0x2894c2('0x13')][_0x2894c2('0x21')]({'where':{'id':_0x3c0391[_0x2894c2('0x35')]['id']}})['then'](handleEntityNotFound(_0x34b12f,null))['then'](function(_0x530771){const _0x4e126b=_0x2894c2;if(_0x530771)return _0x530771['removeAgents'](_0x3c0391[_0x4e126b('0x61')][_0x4e126b('0xf')])['then'](function(){const _0x1a8888=_0x4e126b;if(_[_0x1a8888('0x1e')](_0x3c0391[_0x1a8888('0x61')][_0x1a8888('0xf')]))for(let _0x3dbe4c=0x0;_0x3dbe4c<_0x3c0391['query']['ids'][_0x1a8888('0x3c')];_0x3dbe4c+=0x1){socket[_0x1a8888('0x16')](_0x1a8888('0x55'),{'UserId':Number(_0x3c0391[_0x1a8888('0x61')][_0x1a8888('0xf')][_0x3dbe4c]),'FaxQueueId':Number(_0x3c0391[_0x1a8888('0x35')]['id'])});}else socket['emit'](_0x1a8888('0x55'),{'UserId':Number(_0x3c0391[_0x1a8888('0x61')]['ids']),'FaxQueueId':Number(_0x3c0391['params']['id'])});});})[_0x2894c2('0x5')](respondWithStatusCode(_0x34b12f,null))[_0x2894c2('0x58')](handleError(_0x34b12f,null));},exports['getAgents']=function(_0x55ccab,_0x2ce1f9){const _0x6d966a=_0x40cca2;let _0x48b00f={};const _0x54d224={};let _0x405769,_0x582f8e;return db[_0x6d966a('0x13')][_0x6d966a('0x21')]({'where':{'id':_0x55ccab['params']['id']}})[_0x6d966a('0x5')](handleEntityNotFound(_0x2ce1f9,null))[_0x6d966a('0x5')](function(_0x5882b3){const _0x3fd0a4=_0x6d966a;if(_0x5882b3)return _0x405769=_0x5882b3,_0x54d224['model']=_[_0x3fd0a4('0x19')](db[_0x3fd0a4('0x46')][_0x3fd0a4('0x10')]),_0x54d224[_0x3fd0a4('0x61')]=_[_0x3fd0a4('0x19')](_0x55ccab[_0x3fd0a4('0x61')]),_0x54d224['filters']=_[_0x3fd0a4('0x6')](_0x54d224[_0x3fd0a4('0x3e')],_0x54d224[_0x3fd0a4('0x61')]),_0x48b00f['attributes']=_[_0x3fd0a4('0x6')](_0x54d224[_0x3fd0a4('0x3e')],qs[_0x3fd0a4('0x57')](_0x55ccab[_0x3fd0a4('0x61')][_0x3fd0a4('0x57')])),_0x48b00f[_0x3fd0a4('0x0')]=_0x48b00f['attributes'][_0x3fd0a4('0x3c')]?_0x48b00f[_0x3fd0a4('0x0')]:_0x54d224[_0x3fd0a4('0x3e')],_0x48b00f['order']=qs[_0x3fd0a4('0x2c')](_0x55ccab[_0x3fd0a4('0x61')][_0x3fd0a4('0x2c')]),_0x48b00f['where']=qs[_0x3fd0a4('0x32')](_[_0x3fd0a4('0x62')](_0x55ccab[_0x3fd0a4('0x61')],_0x54d224[_0x3fd0a4('0x32')])),_0x55ccab['query'][_0x3fd0a4('0x4c')]&&(_0x48b00f[_0x3fd0a4('0x37')]=_[_0x3fd0a4('0x45')](_0x48b00f[_0x3fd0a4('0x37')],{[Op['or']]:_[_0x3fd0a4('0xa')](_0x48b00f[_0x3fd0a4('0x0')],function(_0xaefe){const _0x2efe59=_0x3fd0a4,_0x3f06c3={};return _0x3f06c3[_0xaefe]={[Op['like']]:'%'+_0x55ccab[_0x2efe59('0x61')][_0x2efe59('0x4c')]+'%'},_0x3f06c3;})})),_0x48b00f=_['merge']({},_0x48b00f,_0x55ccab[_0x3fd0a4('0x2f')]),_0x405769['getAgents'](_0x48b00f);})['then'](function(_0xc87c0c){const _0x3f673d=_0x6d966a;if(_0xc87c0c)return _0x582f8e=_0xc87c0c[_0x3f673d('0x3c')],typeof _0x55ccab['query'][_0x3f673d('0x9')]===_0x3f673d('0x6a')&&(_0x48b00f[_0x3f673d('0x1a')]=qs[_0x3f673d('0x1a')](_0x55ccab[_0x3f673d('0x61')][_0x3f673d('0x1a')]),_0x48b00f['offset']=qs['offset'](_0x55ccab[_0x3f673d('0x61')][_0x3f673d('0x12')])),_0x405769['getAgents'](_0x48b00f);})[_0x6d966a('0x5')](function(_0x3483df){if(_0x3483df)return _0x3483df?{'count':_0x582f8e,'rows':_0x3483df}:null;})[_0x6d966a('0x5')](respondWithResult(_0x2ce1f9,null))[_0x6d966a('0x58')](handleError(_0x2ce1f9,null));}; \ No newline at end of file +const a212_0x3300=['set','map','includeAll','name','updatedAt','isEmpty','create','count','flatMap','all','Content-Range','join','push','length','each','FaxQueueId','SELECT','getMembers','describe','ids','keys','%s/%s','includes','filters','params','pick','get','user','type','ut.TeamId\x20=\x20tq.TeamId','getTeams','FaxQueueId\x20=\x20?','findAll','limit','filter','offset','Team','field','sort','destroy','then','json','VIRTUAL','body','update','findOrCreate','merge','rows','options','stack','forEach','FaxQueues','send','interface','like','removeAgents','squel','isArray','userProfileId','nolimit','sequelize','compact','removeTeams','../../rediscache','../../mysqldb','register','tq.TeamId','UserFaxQueue','faxPause','findOne','model','FaxQueue','error','index','catch','omit','format','UserProfileResource','addTeams','online','./faxQueue.socket','where','rawAttributes','clone','UserId','end','value','Unable\x20to\x20retrieve\x20the\x20current\x20user','findAndCountAll','role','include','transaction','util','fields','undefined','query','addAgents','attributes','sendStatus','getAgents','userFaxQueue:save','TeamId','User','user_has_teams','userFaxQueue:remove','Agents','intersection','show','UserProfileSection','order','select','from','createdAt','voicePause','emit','status'];(function(_0x5bd242,_0x33005f){const _0x5a27d7=function(_0x13e1f4){while(--_0x13e1f4){_0x5bd242['push'](_0x5bd242['shift']());}};_0x5a27d7(++_0x33005f);}(a212_0x3300,0x69));const a212_0x5a27=function(_0x5bd242,_0x33005f){_0x5bd242=_0x5bd242-0x0;let _0x5a27d7=a212_0x3300[_0x5bd242];return _0x5a27d7;};const _0x405522=a212_0x5a27;'use strict';const util=require(_0x405522('0x67')),_=require('lodash'),squel=require(_0x405522('0x43')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')('api'),{getSocket}=require(_0x405522('0x4a')),socket=getSocket(),db=require(_0x405522('0x4b'))['db'],{Op,QueryTypes}=require(_0x405522('0x47'));require(_0x405522('0x5b'))[_0x405522('0x4c')](socket);function respondWithStatusCode(_0x13e1f4,_0x4639c4){return _0x4639c4=_0x4639c4||0xcc,function(_0x4e8401){const _0x247db9=a212_0x5a27;if(_0x4e8401)return _0x13e1f4[_0x247db9('0x6d')](_0x4639c4);return _0x13e1f4[_0x247db9('0xa')](_0x4639c4)['end']();};}function respondWithResult(_0x3c33ee,_0x283c22){return _0x283c22=_0x283c22||0xc8,function(_0x52493e){const _0xa3ddbc=a212_0x5a27;if(_0x52493e)return _0x3c33ee['status'](_0x283c22)[_0xa3ddbc('0x34')](_0x52493e);};}function respondWithFilteredResult(_0x32a11a,_0x29ee73){return function(_0x399a8f){const _0x6a3894=a212_0x5a27;if(_0x399a8f){const _0x8bba22=_0x399a8f['count'],_0x164b8a=_0x29ee73[_0x6a3894('0x2e')];let _0x2206fd=_0x29ee73['offset']+_0x29ee73[_0x6a3894('0x2c')],_0x4083c0;return _0x2206fd>=_0x8bba22?(_0x2206fd=_0x8bba22,_0x4083c0=0xc8):_0x4083c0=0xce,_0x32a11a[_0x6a3894('0xa')](_0x4083c0),_0x32a11a[_0x6a3894('0xb')](_0x6a3894('0x15'),_0x164b8a+'-'+_0x2206fd+'/'+_0x8bba22)[_0x6a3894('0x34')](_0x399a8f);}return null;};}function saveUpdates(_0xefa8c7){return function(_0xeb9ca){const _0x403d9f=a212_0x5a27;if(_0xeb9ca)return _0xeb9ca[_0x403d9f('0x37')](_0xefa8c7)['then'](function(_0x4622de){return _0x4622de;});return null;};}function removeEntity(_0x17e24d){return function(_0x2f0949){const _0x47ee2e=a212_0x5a27;if(_0x2f0949)return _0x2f0949[_0x47ee2e('0x32')]()['then'](function(){const _0x4b3ff6=_0x47ee2e,_0xab6e69=_0x2f0949['get']({'plain':!![]}),_0x3b751e=_0x4b3ff6('0x3e');return db[_0x4b3ff6('0x58')][_0x4b3ff6('0x32')]({'where':{'type':_0x3b751e,'resourceId':_0xab6e69['id']}})['then'](function(){return _0x2f0949;});})['then'](function(){const _0x1f9baa=_0x47ee2e;_0x17e24d[_0x1f9baa('0xa')](0xcc)[_0x1f9baa('0x60')]();});};}function handleEntityNotFound(_0x39254e){return function(_0x33bb73){const _0x2c65b9=a212_0x5a27;return!_0x33bb73&&_0x39254e[_0x2c65b9('0x6d')](0x194),_0x33bb73;};}function handleError(_0x5400b0,_0x48be63){return _0x48be63=_0x48be63||0x1f4,function(_0xd35cb4){const _0x53611b=a212_0x5a27;logger[_0x53611b('0x53')](_0xd35cb4[_0x53611b('0x3c')]),_0xd35cb4[_0x53611b('0xe')]&&delete _0xd35cb4['name'],_0x5400b0[_0x53611b('0xa')](_0x48be63)[_0x53611b('0x3f')](_0xd35cb4);};}exports[_0x405522('0x54')]=function(_0x4c995a,_0x430d49){const _0x555593=_0x405522;let _0x3e8e77={};const _0x52703f={},_0x278025={'count':0x0,'rows':[]},_0xfa6725=_[_0x555593('0xc')](db[_0x555593('0x52')][_0x555593('0x5d')],function(_0x55f053){const _0x5e91ec=_0x555593;return{'name':_0x55f053['fieldName'],'type':_0x55f053[_0x5e91ec('0x27')]['key']};});_0x52703f[_0x555593('0x51')]=_[_0x555593('0xc')](_0xfa6725,'name'),_0x52703f[_0x555593('0x6a')]=_[_0x555593('0x1f')](_0x4c995a[_0x555593('0x6a')]),_0x52703f[_0x555593('0x22')]=_[_0x555593('0x1')](_0x52703f[_0x555593('0x51')],_0x52703f['query']),_0x3e8e77[_0x555593('0x6c')]=_['intersection'](_0x52703f[_0x555593('0x51')],qs['fields'](_0x4c995a[_0x555593('0x6a')][_0x555593('0x68')])),_0x3e8e77[_0x555593('0x6c')]=_0x3e8e77[_0x555593('0x6c')][_0x555593('0x18')]?_0x3e8e77[_0x555593('0x6c')]:_0x52703f['model'];typeof _0x4c995a[_0x555593('0x6a')][_0x555593('0x46')]==='undefined'&&(_0x3e8e77['limit']=qs[_0x555593('0x2c')](_0x4c995a[_0x555593('0x6a')][_0x555593('0x2c')]),_0x3e8e77[_0x555593('0x2e')]=qs[_0x555593('0x2e')](_0x4c995a[_0x555593('0x6a')][_0x555593('0x2e')]));_0x3e8e77[_0x555593('0x4')]=qs['sort'](_0x4c995a[_0x555593('0x6a')][_0x555593('0x31')]),_0x3e8e77[_0x555593('0x5c')]=qs[_0x555593('0x22')](_[_0x555593('0x24')](_0x4c995a[_0x555593('0x6a')],_0x52703f[_0x555593('0x22')]),_0xfa6725);_0x4c995a[_0x555593('0x6a')][_0x555593('0x2d')]&&(_0x3e8e77[_0x555593('0x5c')]=_[_0x555593('0x39')](_0x3e8e77['where'],{[Op['or']]:_['map'](_0xfa6725,function(_0x9a3ca){const _0x2c8301=_0x555593;if(_0x9a3ca['type']!==_0x2c8301('0x35')){const _0x51acb1={};return _0x51acb1[_0x9a3ca['name']]={[Op[_0x2c8301('0x41')]]:'%'+_0x4c995a['query'][_0x2c8301('0x2d')]+'%'},_0x51acb1;}})}));_0x3e8e77=_[_0x555593('0x39')]({},_0x3e8e77,_0x4c995a[_0x555593('0x3b')]);const _0x560053={'where':_0x3e8e77[_0x555593('0x5c')]};return db[_0x555593('0x52')][_0x555593('0x12')](_0x560053)['then'](function(_0x423bcd){const _0x513084=_0x555593;return _0x278025[_0x513084('0x12')]=_0x423bcd,_0x4c995a['query'][_0x513084('0xd')]&&(_0x3e8e77[_0x513084('0x65')]=[{'all':!![]}]),db[_0x513084('0x52')]['findAll'](_0x3e8e77);})[_0x555593('0x33')](function(_0x517479){const _0xd18448=_0x555593;return _0x278025[_0xd18448('0x3a')]=_0x517479,_0x278025;})[_0x555593('0x33')](respondWithFilteredResult(_0x430d49,_0x3e8e77))[_0x555593('0x55')](handleError(_0x430d49,null));},exports[_0x405522('0x2')]=function(_0x18c59b,_0x5aae5e){const _0x2bd3c5=_0x405522;let _0x2bdfd2={'raw':!![],'where':{'id':_0x18c59b[_0x2bd3c5('0x23')]['id']}};const _0x432124={};return _0x432124['model']=_[_0x2bd3c5('0x1f')](db[_0x2bd3c5('0x52')][_0x2bd3c5('0x5d')]),_0x432124[_0x2bd3c5('0x6a')]=_['keys'](_0x18c59b[_0x2bd3c5('0x6a')]),_0x432124[_0x2bd3c5('0x22')]=_['intersection'](_0x432124[_0x2bd3c5('0x51')],_0x432124[_0x2bd3c5('0x6a')]),_0x2bdfd2[_0x2bd3c5('0x6c')]=_[_0x2bd3c5('0x1')](_0x432124[_0x2bd3c5('0x51')],qs['fields'](_0x18c59b[_0x2bd3c5('0x6a')][_0x2bd3c5('0x68')])),_0x2bdfd2[_0x2bd3c5('0x6c')]=_0x2bdfd2[_0x2bd3c5('0x6c')][_0x2bd3c5('0x18')]?_0x2bdfd2[_0x2bd3c5('0x6c')]:_0x432124[_0x2bd3c5('0x51')],_0x18c59b[_0x2bd3c5('0x6a')][_0x2bd3c5('0xd')]&&(_0x2bdfd2[_0x2bd3c5('0x65')]=[{'all':!![]}]),_0x2bdfd2=_[_0x2bd3c5('0x39')]({},_0x2bdfd2,_0x18c59b['options']),db[_0x2bd3c5('0x52')][_0x2bd3c5('0x50')](_0x2bdfd2)[_0x2bd3c5('0x33')](handleEntityNotFound(_0x5aae5e,null))[_0x2bd3c5('0x33')](respondWithResult(_0x5aae5e,null))[_0x2bd3c5('0x55')](handleError(_0x5aae5e,null));},exports[_0x405522('0x11')]=function(_0x5e3070,_0x2847ba){const _0x10d792=_0x405522;return db[_0x10d792('0x52')][_0x10d792('0x11')](_0x5e3070[_0x10d792('0x36')],{})[_0x10d792('0x33')](function(_0x41606e){const _0x2e24b8=_0x10d792,_0x4d2c0e=_0x5e3070[_0x2e24b8('0x26')]['get']({'plain':!![]});if(!_0x4d2c0e)throw new Error(_0x2e24b8('0x62'));if(_0x4d2c0e[_0x2e24b8('0x64')]===_0x2e24b8('0x26')){const _0x1aa7d9=_0x41606e['get']({'plain':!![]}),_0x598918=_0x2e24b8('0x3e');return db[_0x2e24b8('0x3')][_0x2e24b8('0x50')]({'where':{'name':_0x598918,'userProfileId':_0x4d2c0e[_0x2e24b8('0x45')]},'raw':!![]})[_0x2e24b8('0x33')](function(_0x1b9eaf){const _0x535fce=_0x2e24b8;return _0x1b9eaf&&_0x1b9eaf['autoAssociation']===0x0?db[_0x535fce('0x58')]['create']({'name':_0x1aa7d9[_0x535fce('0xe')],'resourceId':_0x1aa7d9['id'],'type':_0x1b9eaf[_0x535fce('0xe')],'sectionId':_0x1b9eaf['id']},{})[_0x535fce('0x33')](function(){return _0x41606e;}):_0x41606e;})[_0x2e24b8('0x55')](function(_0x444412){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x444412);throw _0x444412;});}return _0x41606e;})[_0x10d792('0x33')](respondWithResult(_0x2847ba,0xc9))[_0x10d792('0x55')](handleError(_0x2847ba,null));},exports['update']=function(_0x204349,_0xd51406){const _0x1c1c0c=_0x405522;return _0x204349['body']['id']&&delete _0x204349['body']['id'],db[_0x1c1c0c('0x52')]['findOne']({'where':{'id':_0x204349[_0x1c1c0c('0x23')]['id']}})['then'](handleEntityNotFound(_0xd51406,null))['then'](saveUpdates(_0x204349['body'],null))[_0x1c1c0c('0x33')](respondWithResult(_0xd51406,null))['catch'](handleError(_0xd51406,null));},exports[_0x405522('0x32')]=function(_0x2443bb,_0x52840){const _0x446970=_0x405522;return db[_0x446970('0x52')]['findOne']({'where':{'id':_0x2443bb[_0x446970('0x23')]['id']}})['then'](handleEntityNotFound(_0x52840,null))[_0x446970('0x33')](removeEntity(_0x52840,null))[_0x446970('0x55')](handleError(_0x52840,null));},exports['describe']=function(_0xd4b1b7,_0x33d57d){const _0xd7a461=_0x405522;return db[_0xd7a461('0x52')][_0xd7a461('0x1d')]()[_0xd7a461('0x33')](respondWithResult(_0x33d57d,null))[_0xd7a461('0x55')](handleError(_0x33d57d,null));},exports[_0x405522('0x1c')]=function(_0x360d0a,_0x59ebda){const _0x4db6c4=_0x405522;let _0x104235={'raw':!![],'where':{}};const _0x268284={};let _0xabcee4;return db['FaxQueue'][_0x4db6c4('0x50')]({'where':{'id':_0x360d0a[_0x4db6c4('0x23')]['id']}})[_0x4db6c4('0x33')](handleEntityNotFound(_0x59ebda,null))['then'](function(_0x4ed43a){const _0x1ac45c=_0x4db6c4;if(_0x4ed43a)return _0xabcee4=_0x4ed43a[_0x1ac45c('0x25')]({'plain':!![]}),_0x268284[_0x1ac45c('0x51')]=_['keys'](db[_0x1ac45c('0x4e')][_0x1ac45c('0x5d')]),_0x268284['query']=_[_0x1ac45c('0x1f')](_0x360d0a[_0x1ac45c('0x6a')]),_0x268284[_0x1ac45c('0x22')]=_[_0x1ac45c('0x1')](_0x268284['model'],_0x268284['query']),_0x104235[_0x1ac45c('0x6c')]=_[_0x1ac45c('0x1')](_0x268284[_0x1ac45c('0x51')],qs['fields'](_0x360d0a[_0x1ac45c('0x6a')][_0x1ac45c('0x68')])),_0x104235['attributes']=_0x104235[_0x1ac45c('0x6c')][_0x1ac45c('0x18')]?_0x104235[_0x1ac45c('0x6c')]:_0x268284['model'],typeof _0x360d0a[_0x1ac45c('0x6a')][_0x1ac45c('0x46')]===_0x1ac45c('0x69')&&(_0x104235[_0x1ac45c('0x2c')]=qs['limit'](_0x360d0a['query'][_0x1ac45c('0x2c')]),_0x104235['offset']=qs[_0x1ac45c('0x2e')](_0x360d0a[_0x1ac45c('0x6a')][_0x1ac45c('0x2e')])),_0x104235[_0x1ac45c('0x4')]=qs[_0x1ac45c('0x31')](_0x360d0a['query'][_0x1ac45c('0x31')]),_0x104235['where']=qs[_0x1ac45c('0x22')](_[_0x1ac45c('0x24')](_0x360d0a[_0x1ac45c('0x6a')],_0x268284[_0x1ac45c('0x22')])),_0x104235['where'][_0x1ac45c('0x1a')]=_0x4ed43a['id'],_0x360d0a[_0x1ac45c('0x6a')]['filter']&&(_0x104235[_0x1ac45c('0x5c')]=_['merge'](_0x104235['where'],{[Op['or']]:_['map'](_0x104235['attributes'],function(_0x5d00c2){const _0x1f6291=_0x1ac45c,_0x31df27={};return _0x31df27[_0x5d00c2]={[Op[_0x1f6291('0x41')]]:'%'+_0x360d0a[_0x1f6291('0x6a')]['filter']+'%'},_0x31df27;})})),_0x104235=_[_0x1ac45c('0x39')]({},_0x104235,_0x360d0a[_0x1ac45c('0x3b')]),db[_0x1ac45c('0x4e')]['findAll'](_0x104235);})[_0x4db6c4('0x33')](function(_0x5f04fb){const _0x7fae85=_0x4db6c4;if(_0x5f04fb)return db[_0x7fae85('0x71')][_0x7fae85('0x63')]({'where':{'id':_['map'](_0x5f04fb,_0x7fae85('0x5f')),'role':'agent'},'attributes':['id',_0x7fae85('0xe'),_0x7fae85('0x4f'),'updatedAt',_0x7fae85('0x7')]});})[_0x4db6c4('0x33')](function(_0x10fa50){const _0x6fe1e6=_0x4db6c4;return _0x10fa50?{'count':_0x10fa50['count'],'rows':_['map'](_0x10fa50[_0x6fe1e6('0x3a')],function(_0x40b15c){const _0x1568b8=_0x6fe1e6;return{'membername':_0x40b15c['name'],'UserId':_0x40b15c['id'],'queue_name':_0xabcee4[_0x1568b8('0xe')],'FaxQueueId':_0xabcee4['id'],'interface':util[_0x1568b8('0x57')](_0x1568b8('0x20'),'SIP',_0x40b15c[_0x1568b8('0xe')]),'penalty':0x0,'paused':_0x40b15c[_0x1568b8('0x4f')],'createdAt':_0x40b15c[_0x1568b8('0x7')],'updatedAt':_0x40b15c[_0x1568b8('0xf')]};})}:{'count':0x0,'rows':[]};})['then'](respondWithFilteredResult(_0x59ebda,_0x104235))[_0x4db6c4('0x55')](handleError(_0x59ebda,null));},exports[_0x405522('0x29')]=function(_0x1426cd,_0x2b384d){const _0x664c67=_0x405522;let _0x5d929b={};const _0x2ac717={};let _0x551be5,_0x527237;return db['FaxQueue'][_0x664c67('0x50')]({'where':{'id':_0x1426cd['params']['id']}})[_0x664c67('0x33')](handleEntityNotFound(_0x2b384d,null))['then'](function(_0x288ca3){const _0x9e8938=_0x664c67;if(_0x288ca3)return _0x551be5=_0x288ca3,_0x2ac717[_0x9e8938('0x51')]=_['keys'](db[_0x9e8938('0x2f')][_0x9e8938('0x5d')]),_0x2ac717[_0x9e8938('0x6a')]=_['keys'](_0x1426cd[_0x9e8938('0x6a')]),_0x2ac717[_0x9e8938('0x22')]=_['intersection'](_0x2ac717['model'],_0x2ac717[_0x9e8938('0x6a')]),_0x5d929b[_0x9e8938('0x6c')]=_[_0x9e8938('0x1')](_0x2ac717[_0x9e8938('0x51')],qs[_0x9e8938('0x68')](_0x1426cd[_0x9e8938('0x6a')][_0x9e8938('0x68')])),_0x5d929b[_0x9e8938('0x6c')]=_0x5d929b[_0x9e8938('0x6c')]['length']?_0x5d929b['attributes']:_0x2ac717['model'],_0x5d929b['order']=qs[_0x9e8938('0x31')](_0x1426cd['query'][_0x9e8938('0x31')]),_0x5d929b['where']=qs['filters'](_[_0x9e8938('0x24')](_0x1426cd[_0x9e8938('0x6a')],_0x2ac717[_0x9e8938('0x22')])),_0x1426cd[_0x9e8938('0x6a')][_0x9e8938('0x2d')]&&(_0x5d929b[_0x9e8938('0x5c')]=_[_0x9e8938('0x39')](_0x5d929b[_0x9e8938('0x5c')],{[Op['or']]:_[_0x9e8938('0xc')](_0x5d929b[_0x9e8938('0x6c')],function(_0x4d46de){const _0x116a12=_0x9e8938,_0x24ebdf={};return _0x24ebdf[_0x4d46de]={[Op[_0x116a12('0x41')]]:'%'+_0x1426cd['query'][_0x116a12('0x2d')]+'%'},_0x24ebdf;})})),_0x5d929b=_[_0x9e8938('0x39')]({},_0x5d929b,_0x1426cd[_0x9e8938('0x3b')]),_0x551be5[_0x9e8938('0x29')](_0x5d929b);})[_0x664c67('0x33')](function(_0x40c2e4){const _0x50ae4f=_0x664c67;if(_0x40c2e4)return _0x527237=_0x40c2e4[_0x50ae4f('0x18')],typeof _0x1426cd[_0x50ae4f('0x6a')][_0x50ae4f('0x46')]==='undefined'&&(_0x5d929b['limit']=qs[_0x50ae4f('0x2c')](_0x1426cd['query'][_0x50ae4f('0x2c')]),_0x5d929b[_0x50ae4f('0x2e')]=qs[_0x50ae4f('0x2e')](_0x1426cd[_0x50ae4f('0x6a')][_0x50ae4f('0x2e')])),_0x551be5[_0x50ae4f('0x29')](_0x5d929b);})[_0x664c67('0x33')](function(_0x188f3c){if(_0x188f3c)return _0x188f3c?{'count':_0x527237,'rows':_0x188f3c}:null;})[_0x664c67('0x33')](respondWithResult(_0x2b384d,null))[_0x664c67('0x55')](handleError(_0x2b384d,null));},exports[_0x405522('0x59')]=function(_0x4f90e2,_0x387259){const _0x4b300e=_0x405522,_0x2ade6d=_0x4f90e2[_0x4b300e('0x36')][_0x4b300e('0x1e')];return db[_0x4b300e('0x2f')][_0x4b300e('0x2b')]({'where':{'id':_0x2ade6d},'attributes':['id'],'include':[{'model':db[_0x4b300e('0x71')],'as':_0x4b300e('0x0'),'attributes':['id',_0x4b300e('0xe'),_0x4b300e('0x5a'),_0x4b300e('0x8'),_0x4b300e('0x40')],'raw':!![]}]})[_0x4b300e('0x33')](function(_0x485f1f){const _0x2042a5=_0x4b300e;if(_0x485f1f){const _0x5eec3c=_[_0x2042a5('0x13')](_0x485f1f,function(_0x4b4aa4){const _0x5b27d9=_0x4b4aa4['get']({'plain':!![]});return _0x5b27d9['Agents'];});return db[_0x2042a5('0x52')]['findOne']({'where':{'id':_0x4f90e2[_0x2042a5('0x23')]['id']}})['then'](function(_0x3e7ee7){const _0x536b14=_0x2042a5;return db[_0x536b14('0x47')][_0x536b14('0x66')](function(_0x35dc05){const _0x2066a9=_0x536b14;return _0x3e7ee7[_0x2066a9('0x59')](_0x2ade6d,{'transaction':_0x35dc05})['then'](function(){const _0x1f3fc=_0x2066a9;return Promise[_0x1f3fc('0x19')](_0x5eec3c,function(_0x502f55){const _0x4009b8=_0x1f3fc;return db[_0x4009b8('0x4e')][_0x4009b8('0x38')]({'where':{'UserId':_0x502f55['id'],'FaxQueueId':_0x4f90e2['params']['id']},'transaction':_0x35dc05});});})['then'](function(){_0x5eec3c['forEach'](function(_0x2276be){const _0x4fe476=a212_0x5a27;socket[_0x4fe476('0x9')](_0x4fe476('0x6f'),{'UserId':_0x2276be['id'],'FaxQueueId':_0x3e7ee7['id']});});});});});}})[_0x4b300e('0x33')](respondWithStatusCode(_0x387259,null))['catch'](handleError(_0x387259,null));},exports[_0x405522('0x49')]=function(_0x3a628d,_0x5970bc){const _0x2aa0ee=_0x405522;return db[_0x2aa0ee('0x2f')][_0x2aa0ee('0x2b')]({'where':{'id':_0x3a628d[_0x2aa0ee('0x6a')][_0x2aa0ee('0x1e')]},'attributes':['id'],'include':[{'model':db[_0x2aa0ee('0x71')],'as':_0x2aa0ee('0x0'),'attributes':['id'],'raw':!![]}]})[_0x2aa0ee('0x33')](handleEntityNotFound(_0x5970bc,null))[_0x2aa0ee('0x33')](function(_0x2a20df){const _0x2b983c=_0x2aa0ee,_0x146955=_['map'](_0x2a20df,'id');let _0x7606a3=[];const _0x3c29ab=[],_0x41f1e5=squel[_0x2b983c('0x5')]();_0x41f1e5[_0x2b983c('0x30')](_0x2b983c('0x4d'))[_0x2b983c('0x6')]('team_has_fax_queues','tq')[_0x2b983c('0x16')](_0x2b983c('0x72'),'ut',_0x2b983c('0x28'))[_0x2b983c('0x5c')](_0x2b983c('0x2a'),_0x3a628d[_0x2b983c('0x23')]['id']);for(let _0x615c8e=0x0;_0x615c8e<_0x2a20df['length'];_0x615c8e+=0x1){const _0x4a9f8a=_0x2a20df[_0x615c8e];for(let _0x3c9dc3=0x0;_0x3c9dc3<_0x4a9f8a['Agents']['length'];_0x3c9dc3+=0x1){const _0x5094ef=_0x4a9f8a['Agents'][_0x3c9dc3],_0xe33f2d=_0x41f1e5[_0x2b983c('0x5e')]();_0xe33f2d[_0x2b983c('0x5c')]('ut.UserId\x20=\x20?',_0x5094ef['id']),_0x3c29ab[_0x2b983c('0x17')](db[_0x2b983c('0x47')][_0x2b983c('0x6a')](_0xe33f2d['toString'](),{'type':QueryTypes[_0x2b983c('0x1b')]})[_0x2b983c('0x33')](function(_0x10b92d){const _0x2f3a1b=_0x2b983c;if(_0x10b92d[_0x2f3a1b('0x18')]===0x1)return _0x5094ef['id'];else{const _0x4d6622=_['every'](_['map'](_0x10b92d,_0x2f3a1b('0x70')),function(_0x4e3321){const _0x158035=_0x2f3a1b;return _[_0x158035('0x21')](_0x146955,_0x4e3321);});if(_0x4d6622)return _0x5094ef['id'];}}));}}return Promise[_0x2b983c('0x14')](_0x3c29ab)['then'](function(_0x452e24){const _0x2b32d8=_0x2b983c;return _0x7606a3=_(_0x7606a3)['union'](_0x452e24)[_0x2b32d8('0x48')]()[_0x2b32d8('0x61')](),db[_0x2b32d8('0x52')][_0x2b32d8('0x50')]({'where':{'id':_0x3a628d[_0x2b32d8('0x23')]['id']}})[_0x2b32d8('0x33')](function(_0x5a4b95){const _0x3dc6c3=_0x2b32d8;return db[_0x3dc6c3('0x47')]['transaction'](function(_0xa58a0f){const _0x4ec6f7=_0x3dc6c3;return _0x5a4b95[_0x4ec6f7('0x49')](_0x3a628d[_0x4ec6f7('0x6a')][_0x4ec6f7('0x1e')],{'transaction':_0xa58a0f})[_0x4ec6f7('0x33')](function(){const _0x467eec=_0x4ec6f7;if(!_[_0x467eec('0x10')](_0x7606a3))return _0x5a4b95[_0x467eec('0x42')](_0x7606a3,{'transaction':_0xa58a0f});})[_0x4ec6f7('0x33')](function(){const _0x46c7ea=_0x4ec6f7;_0x7606a3[_0x46c7ea('0x3d')](function(_0xe355b6){const _0x592fd7=_0x46c7ea;socket[_0x592fd7('0x9')](_0x592fd7('0x73'),{'UserId':_0xe355b6,'FaxQueueId':_0x5a4b95['id']});});});});});});})['then'](respondWithStatusCode(_0x5970bc,null))[_0x2aa0ee('0x55')](handleError(_0x5970bc,null));},exports[_0x405522('0x6b')]=function(_0x4c3d0d,_0x22cb09){const _0x5f4eda=_0x405522;return db[_0x5f4eda('0x52')][_0x5f4eda('0x50')]({'where':{'id':_0x4c3d0d[_0x5f4eda('0x23')]['id']}})[_0x5f4eda('0x33')](function(_0x531953){const _0x56fa97=_0x5f4eda;if(_0x531953)return _0x531953[_0x56fa97('0x6b')](_0x4c3d0d[_0x56fa97('0x36')][_0x56fa97('0x1e')],{'through':_[_0x56fa97('0x56')](_0x4c3d0d[_0x56fa97('0x36')],[_0x56fa97('0x1e'),'id'])})[_0x56fa97('0x33')](function(_0x18d044){const _0x33ab32=_0x56fa97;for(let _0x4d021c=0x0;_0x4d021c<_0x4c3d0d[_0x33ab32('0x36')][_0x33ab32('0x1e')][_0x33ab32('0x18')];_0x4d021c+=0x1){socket[_0x33ab32('0x9')](_0x33ab32('0x6f'),{'UserId':_0x4c3d0d[_0x33ab32('0x36')][_0x33ab32('0x1e')][_0x4d021c],'FaxQueueId':_0x4c3d0d[_0x33ab32('0x23')]['id']});}return _0x18d044;});})[_0x5f4eda('0x33')](respondWithResult(_0x22cb09,null))[_0x5f4eda('0x55')](handleError(_0x22cb09,null));},exports[_0x405522('0x42')]=function(_0x1a6631,_0x8b3f3e){const _0x35b5e0=_0x405522;return db[_0x35b5e0('0x52')][_0x35b5e0('0x50')]({'where':{'id':_0x1a6631['params']['id']}})[_0x35b5e0('0x33')](handleEntityNotFound(_0x8b3f3e,null))[_0x35b5e0('0x33')](function(_0x354586){const _0x683780=_0x35b5e0;if(_0x354586)return _0x354586[_0x683780('0x42')](_0x1a6631[_0x683780('0x6a')]['ids'])['then'](function(){const _0xc45233=_0x683780;if(_[_0xc45233('0x44')](_0x1a6631[_0xc45233('0x6a')][_0xc45233('0x1e')]))for(let _0x3386ef=0x0;_0x3386ef<_0x1a6631[_0xc45233('0x6a')]['ids'][_0xc45233('0x18')];_0x3386ef+=0x1){socket['emit'](_0xc45233('0x73'),{'UserId':Number(_0x1a6631['query'][_0xc45233('0x1e')][_0x3386ef]),'FaxQueueId':Number(_0x1a6631['params']['id'])});}else socket['emit'](_0xc45233('0x73'),{'UserId':Number(_0x1a6631[_0xc45233('0x6a')]['ids']),'FaxQueueId':Number(_0x1a6631['params']['id'])});});})[_0x35b5e0('0x33')](respondWithStatusCode(_0x8b3f3e,null))[_0x35b5e0('0x55')](handleError(_0x8b3f3e,null));},exports['getAgents']=function(_0x12caff,_0x24616f){const _0x17daaf=_0x405522;let _0xb8fc5f={};const _0x3ba768={};let _0x31bef5,_0x197fa2;return db[_0x17daaf('0x52')][_0x17daaf('0x50')]({'where':{'id':_0x12caff[_0x17daaf('0x23')]['id']}})[_0x17daaf('0x33')](handleEntityNotFound(_0x24616f,null))[_0x17daaf('0x33')](function(_0x5699a6){const _0x3749e2=_0x17daaf;if(_0x5699a6)return _0x31bef5=_0x5699a6,_0x3ba768[_0x3749e2('0x51')]=_[_0x3749e2('0x1f')](db[_0x3749e2('0x71')]['rawAttributes']),_0x3ba768[_0x3749e2('0x6a')]=_[_0x3749e2('0x1f')](_0x12caff[_0x3749e2('0x6a')]),_0x3ba768[_0x3749e2('0x22')]=_[_0x3749e2('0x1')](_0x3ba768[_0x3749e2('0x51')],_0x3ba768[_0x3749e2('0x6a')]),_0xb8fc5f[_0x3749e2('0x6c')]=_[_0x3749e2('0x1')](_0x3ba768[_0x3749e2('0x51')],qs[_0x3749e2('0x68')](_0x12caff[_0x3749e2('0x6a')][_0x3749e2('0x68')])),_0xb8fc5f[_0x3749e2('0x6c')]=_0xb8fc5f[_0x3749e2('0x6c')][_0x3749e2('0x18')]?_0xb8fc5f['attributes']:_0x3ba768[_0x3749e2('0x51')],_0xb8fc5f[_0x3749e2('0x4')]=qs[_0x3749e2('0x31')](_0x12caff[_0x3749e2('0x6a')][_0x3749e2('0x31')]),_0xb8fc5f[_0x3749e2('0x5c')]=qs['filters'](_[_0x3749e2('0x24')](_0x12caff[_0x3749e2('0x6a')],_0x3ba768[_0x3749e2('0x22')])),_0x12caff['query'][_0x3749e2('0x2d')]&&(_0xb8fc5f[_0x3749e2('0x5c')]=_[_0x3749e2('0x39')](_0xb8fc5f[_0x3749e2('0x5c')],{[Op['or']]:_['map'](_0xb8fc5f['attributes'],function(_0xba2485){const _0x2fa866=_0x3749e2,_0x299ee5={};return _0x299ee5[_0xba2485]={[Op['like']]:'%'+_0x12caff['query'][_0x2fa866('0x2d')]+'%'},_0x299ee5;})})),_0xb8fc5f=_[_0x3749e2('0x39')]({},_0xb8fc5f,_0x12caff[_0x3749e2('0x3b')]),_0x31bef5[_0x3749e2('0x6e')](_0xb8fc5f);})[_0x17daaf('0x33')](function(_0x38e760){const _0x52aa9e=_0x17daaf;if(_0x38e760)return _0x197fa2=_0x38e760[_0x52aa9e('0x18')],typeof _0x12caff['query'][_0x52aa9e('0x46')]===_0x52aa9e('0x69')&&(_0xb8fc5f[_0x52aa9e('0x2c')]=qs[_0x52aa9e('0x2c')](_0x12caff['query'][_0x52aa9e('0x2c')]),_0xb8fc5f[_0x52aa9e('0x2e')]=qs[_0x52aa9e('0x2e')](_0x12caff[_0x52aa9e('0x6a')][_0x52aa9e('0x2e')])),_0x31bef5['getAgents'](_0xb8fc5f);})[_0x17daaf('0x33')](function(_0x4de03a){if(_0x4de03a)return _0x4de03a?{'count':_0x197fa2,'rows':_0x4de03a}:null;})[_0x17daaf('0x33')](respondWithResult(_0x24616f,null))[_0x17daaf('0x55')](handleError(_0x24616f,null));}; \ No newline at end of file diff --git a/server/api/faxQueue/faxQueue.events.js b/server/api/faxQueue/faxQueue.events.js index 4fb587d..116cce1 100644 --- a/server/api/faxQueue/faxQueue.events.js +++ b/server/api/faxQueue/faxQueue.events.js @@ -1 +1 @@ -const a213_0x2794=['save','remove','addHook','update','emit','FaxQueue','../../mysqldb','undefined'];(function(_0x21c92e,_0x2794d9){const _0x1e11fc=function(_0x266089){while(--_0x266089){_0x21c92e['push'](_0x21c92e['shift']());}};_0x1e11fc(++_0x2794d9);}(a213_0x2794,0xf4));const a213_0x1e11=function(_0x21c92e,_0x2794d9){_0x21c92e=_0x21c92e-0x0;let _0x1e11fc=a213_0x2794[_0x21c92e];return _0x1e11fc;};const _0x31553d=a213_0x1e11;'use strict';const EventEmitter=require('events'),FaxQueue=require(_0x31553d('0x2'))['db'][_0x31553d('0x1')],FaxQueueEvents=new EventEmitter();FaxQueueEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x31553d('0x4'),'afterUpdate':_0x31553d('0x7'),'afterDestroy':_0x31553d('0x5')};function emitEvent(_0x266089){return function(_0x56c65a){const _0x459167=a213_0x1e11;FaxQueueEvents[_0x459167('0x0')](_0x266089+':'+_0x56c65a['id'],_0x56c65a),FaxQueueEvents['emit'](_0x266089,_0x56c65a);};}for(const e in events){if(typeof events[e]!==_0x31553d('0x3')){const event=events[e];FaxQueue[_0x31553d('0x6')](e,emitEvent(event));}}module['exports']=FaxQueueEvents; \ No newline at end of file +const a213_0x41d1=['FaxQueue','remove','save','setMaxListeners','exports','addHook','undefined','events','update','emit','../../mysqldb'];(function(_0x46ae0a,_0x41d18b){const _0x409399=function(_0x38d62a){while(--_0x38d62a){_0x46ae0a['push'](_0x46ae0a['shift']());}};_0x409399(++_0x41d18b);}(a213_0x41d1,0x158));const a213_0x4093=function(_0x46ae0a,_0x41d18b){_0x46ae0a=_0x46ae0a-0x0;let _0x409399=a213_0x41d1[_0x46ae0a];return _0x409399;};const _0x15df73=a213_0x4093;'use strict';const EventEmitter=require(_0x15df73('0x4')),FaxQueue=require(_0x15df73('0x7'))['db'][_0x15df73('0x8')],FaxQueueEvents=new EventEmitter();FaxQueueEvents[_0x15df73('0x0')](0x0);const events={'afterCreate':_0x15df73('0xa'),'afterUpdate':_0x15df73('0x5'),'afterDestroy':_0x15df73('0x9')};function emitEvent(_0x38d62a){return function(_0x574ca8){const _0x1d9d4e=a213_0x4093;FaxQueueEvents[_0x1d9d4e('0x6')](_0x38d62a+':'+_0x574ca8['id'],_0x574ca8),FaxQueueEvents[_0x1d9d4e('0x6')](_0x38d62a,_0x574ca8);};}for(const e in events){if(typeof events[e]!==_0x15df73('0x3')){const event=events[e];FaxQueue[_0x15df73('0x2')](e,emitEvent(event));}}module[_0x15df73('0x1')]=FaxQueueEvents; \ No newline at end of file diff --git a/server/api/faxQueue/faxQueue.model.js b/server/api/faxQueue/faxQueue.model.js index 629ce08..3969e9d 100644 --- a/server/api/faxQueue/faxQueue.model.js +++ b/server/api/faxQueue/faxQueue.model.js @@ -1 +1 @@ -const a214_0x3974=['define','./faxQueue.attributes','FaxQueue','fax_queues','exports'];(function(_0x347105,_0x3974ab){const _0x5c4577=function(_0x271b89){while(--_0x271b89){_0x347105['push'](_0x347105['shift']());}};_0x5c4577(++_0x3974ab);}(a214_0x3974,0xef));const a214_0x5c45=function(_0x347105,_0x3974ab){_0x347105=_0x347105-0x0;let _0x5c4577=a214_0x3974[_0x347105];return _0x5c4577;};const _0xc6b7b2=a214_0x5c45;'use strict';const attributes=require(_0xc6b7b2('0x2'));module[_0xc6b7b2('0x0')]=function(_0x271b89){const _0x282888=_0xc6b7b2,_0x2cc0a3=_0x271b89[_0x282888('0x1')](_0x282888('0x3'),attributes,{'tableName':_0x282888('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2cc0a3;}; \ No newline at end of file +const a214_0x43ac=['exports','FaxQueue','./faxQueue.attributes','fax_queues','define'];(function(_0x12580f,_0x43acfe){const _0x1c8222=function(_0x4fa6e7){while(--_0x4fa6e7){_0x12580f['push'](_0x12580f['shift']());}};_0x1c8222(++_0x43acfe);}(a214_0x43ac,0x1d1));const a214_0x1c82=function(_0x12580f,_0x43acfe){_0x12580f=_0x12580f-0x0;let _0x1c8222=a214_0x43ac[_0x12580f];return _0x1c8222;};const _0x271041=a214_0x1c82;'use strict';const attributes=require(_0x271041('0x2'));module[_0x271041('0x0')]=function(_0x4fa6e7){const _0x408bc6=_0x271041,_0x5df70c=_0x4fa6e7[_0x408bc6('0x4')](_0x408bc6('0x1'),attributes,{'tableName':_0x408bc6('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5df70c;}; \ No newline at end of file diff --git a/server/api/faxQueue/faxQueue.rpc.js b/server/api/faxQueue/faxQueue.rpc.js index 005ca9a..132790d 100644 --- a/server/api/faxQueue/faxQueue.rpc.js +++ b/server/api/faxQueue/faxQueue.rpc.js @@ -1 +1 @@ -const a215_0xede5=['./faxQueue.socket','GetFaxQueue','info','stringify','lodash','message','limit','findAll','map','raw','options','../../config/logger','error','then','where','include','ShowFaxQueue','../../rediscache','debug','FaxQueue','findOne','attributes','model'];(function(_0x584572,_0xede552){const _0x24270d=function(_0x36e616){while(--_0x36e616){_0x584572['push'](_0x584572['shift']());}};_0x24270d(++_0xede552);}(a215_0xede5,0x1cd));const a215_0x2427=function(_0x584572,_0xede552){_0x584572=_0x584572-0x0;let _0x24270d=a215_0xede5[_0x584572];return _0x24270d;};const _0x356f9b=a215_0x2427;'use strict';const _=require(_0x356f9b('0x3')),db=require('../../mysqldb')['db'],logger=require(_0x356f9b('0xa'))('rpc'),{getSocket}=require(_0x356f9b('0x10')),socket=getSocket();require(_0x356f9b('0x16'))['register'](socket),exports['GetFaxQueue']=function(_0x36e616){const _0xd69d9e=this;return new Promise(function(_0x2f9015,_0x2e9e0b){const _0x3c3d34=a215_0x2427;return db[_0x3c3d34('0x12')][_0x3c3d34('0x6')]({'raw':_0x36e616[_0x3c3d34('0x9')]?_0x36e616['options'][_0x3c3d34('0x8')]===undefined?!![]:![]:!![],'where':_0x36e616[_0x3c3d34('0x9')]?_0x36e616[_0x3c3d34('0x9')]['where']||null:null,'attributes':_0x36e616[_0x3c3d34('0x9')]?_0x36e616['options'][_0x3c3d34('0x14')]||null:null,'limit':_0x36e616[_0x3c3d34('0x9')]?_0x36e616['options'][_0x3c3d34('0x5')]||null:null,'include':_0x36e616[_0x3c3d34('0x9')]?_0x36e616[_0x3c3d34('0x9')]['include']?_['map'](_0x36e616['options']['include'],function(_0x2f60bc){const _0x4aad81=_0x3c3d34;return{'model':db[_0x2f60bc[_0x4aad81('0x15')]],'as':_0x2f60bc['as'],'attributes':_0x2f60bc[_0x4aad81('0x14')],'include':_0x2f60bc['include']?_['map'](_0x2f60bc[_0x4aad81('0xe')],function(_0x535554){const _0x2583a1=_0x4aad81;return{'model':db[_0x535554[_0x2583a1('0x15')]],'as':_0x535554['as'],'attributes':_0x535554[_0x2583a1('0x14')],'include':_0x535554['include']?_[_0x2583a1('0x7')](_0x535554[_0x2583a1('0xe')],function(_0x4876f7){const _0x2a527c=_0x2583a1;return{'model':db[_0x4876f7[_0x2a527c('0x15')]],'as':_0x4876f7['as'],'attributes':_0x4876f7[_0x2a527c('0x14')]};}):[]};}):[]};}):[]:[]})[_0x3c3d34('0xc')](function(_0x146ea7){const _0xedd5b6=_0x3c3d34;logger['info'](_0xedd5b6('0x0'),_0x36e616),logger[_0xedd5b6('0x11')](_0xedd5b6('0x0'),_0x36e616,JSON['stringify'](_0x146ea7)),_0x2f9015(_0x146ea7);})['catch'](function(_0x2a238e){const _0x126568=_0x3c3d34;logger[_0x126568('0xb')](_0x126568('0x0'),_0x2a238e[_0x126568('0x4')],_0x36e616),_0x2e9e0b(_0xd69d9e[_0x126568('0xb')](0x1f4,_0x2a238e['message']));});});},exports['ShowFaxQueue']=function(_0x55db03){const _0x366837=this;return new Promise(function(_0xdf583,_0x48d7ce){const _0x283ec8=a215_0x2427;return db[_0x283ec8('0x12')][_0x283ec8('0x13')]({'raw':_0x55db03[_0x283ec8('0x9')]?_0x55db03[_0x283ec8('0x9')][_0x283ec8('0x8')]===undefined?!![]:![]:!![],'where':_0x55db03[_0x283ec8('0x9')]?_0x55db03['options'][_0x283ec8('0xd')]||null:null,'attributes':_0x55db03[_0x283ec8('0x9')]?_0x55db03[_0x283ec8('0x9')][_0x283ec8('0x14')]||null:null,'include':_0x55db03[_0x283ec8('0x9')]?_0x55db03[_0x283ec8('0x9')][_0x283ec8('0xe')]?_[_0x283ec8('0x7')](_0x55db03[_0x283ec8('0x9')][_0x283ec8('0xe')],function(_0x156430){const _0x5e6058=_0x283ec8;return{'model':db[_0x156430[_0x5e6058('0x15')]],'as':_0x156430['as'],'attributes':_0x156430[_0x5e6058('0x14')],'include':_0x156430[_0x5e6058('0xe')]?_[_0x5e6058('0x7')](_0x156430[_0x5e6058('0xe')],function(_0x11fe04){const _0x5e771a=_0x5e6058;return{'model':db[_0x11fe04[_0x5e771a('0x15')]],'as':_0x11fe04['as'],'attributes':_0x11fe04[_0x5e771a('0x14')],'include':_0x11fe04['include']?_['map'](_0x11fe04[_0x5e771a('0xe')],function(_0x213893){const _0x5944c9=_0x5e771a;return{'model':db[_0x213893[_0x5944c9('0x15')]],'as':_0x213893['as'],'attributes':_0x213893[_0x5944c9('0x14')]};}):[]};}):[]};}):[]:[]})[_0x283ec8('0xc')](function(_0x36fbd3){const _0x4f05c4=_0x283ec8;logger[_0x4f05c4('0x1')](_0x4f05c4('0xf'),_0x55db03),logger['debug']('ShowFaxQueue',_0x55db03,JSON[_0x4f05c4('0x2')](_0x36fbd3)),_0xdf583(_0x36fbd3);})['catch'](function(_0x96d8cd){const _0x219e49=_0x283ec8;logger[_0x219e49('0xb')](_0x219e49('0xf'),_0x96d8cd[_0x219e49('0x4')],_0x55db03),_0x48d7ce(_0x366837[_0x219e49('0xb')](0x1f4,_0x96d8cd['message']));});});}; \ No newline at end of file +const a215_0x4119=['model','debug','FaxQueue','register','raw','options','then','map','stringify','message','findAll','where','./faxQueue.socket','rpc','error','include','../../config/logger','limit','catch','attributes','lodash','GetFaxQueue','info','ShowFaxQueue'];(function(_0x4e2a7c,_0x411949){const _0x31bd33=function(_0x4bce12){while(--_0x4bce12){_0x4e2a7c['push'](_0x4e2a7c['shift']());}};_0x31bd33(++_0x411949);}(a215_0x4119,0xa6));const a215_0x31bd=function(_0x4e2a7c,_0x411949){_0x4e2a7c=_0x4e2a7c-0x0;let _0x31bd33=a215_0x4119[_0x4e2a7c];return _0x31bd33;};const _0x48d4b5=a215_0x31bd;'use strict';const _=require(_0x48d4b5('0x16')),db=require('../../mysqldb')['db'],logger=require(_0x48d4b5('0x12'))(_0x48d4b5('0xf')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x48d4b5('0xe'))[_0x48d4b5('0x5')](socket),exports[_0x48d4b5('0x17')]=function(_0x4bce12){const _0xce651b=this;return new Promise(function(_0x39521b,_0x317ac0){const _0x397bad=a215_0x31bd;return db['FaxQueue'][_0x397bad('0xc')]({'raw':_0x4bce12[_0x397bad('0x7')]?_0x4bce12['options'][_0x397bad('0x6')]===undefined?!![]:![]:!![],'where':_0x4bce12['options']?_0x4bce12[_0x397bad('0x7')][_0x397bad('0xd')]||null:null,'attributes':_0x4bce12[_0x397bad('0x7')]?_0x4bce12['options'][_0x397bad('0x15')]||null:null,'limit':_0x4bce12[_0x397bad('0x7')]?_0x4bce12[_0x397bad('0x7')][_0x397bad('0x13')]||null:null,'include':_0x4bce12[_0x397bad('0x7')]?_0x4bce12['options'][_0x397bad('0x11')]?_[_0x397bad('0x9')](_0x4bce12[_0x397bad('0x7')][_0x397bad('0x11')],function(_0xbdb68){const _0x48491e=_0x397bad;return{'model':db[_0xbdb68['model']],'as':_0xbdb68['as'],'attributes':_0xbdb68['attributes'],'include':_0xbdb68[_0x48491e('0x11')]?_[_0x48491e('0x9')](_0xbdb68[_0x48491e('0x11')],function(_0x1c414a){const _0xd153ec=_0x48491e;return{'model':db[_0x1c414a[_0xd153ec('0x2')]],'as':_0x1c414a['as'],'attributes':_0x1c414a['attributes'],'include':_0x1c414a['include']?_[_0xd153ec('0x9')](_0x1c414a[_0xd153ec('0x11')],function(_0xc5f873){const _0x35c9b7=_0xd153ec;return{'model':db[_0xc5f873[_0x35c9b7('0x2')]],'as':_0xc5f873['as'],'attributes':_0xc5f873[_0x35c9b7('0x15')]};}):[]};}):[]};}):[]:[]})[_0x397bad('0x8')](function(_0x260804){const _0x2c7d2b=_0x397bad;logger['info'](_0x2c7d2b('0x17'),_0x4bce12),logger[_0x2c7d2b('0x3')](_0x2c7d2b('0x17'),_0x4bce12,JSON[_0x2c7d2b('0xa')](_0x260804)),_0x39521b(_0x260804);})[_0x397bad('0x14')](function(_0xd3c3a0){const _0x5d1a4c=_0x397bad;logger[_0x5d1a4c('0x10')](_0x5d1a4c('0x17'),_0xd3c3a0['message'],_0x4bce12),_0x317ac0(_0xce651b[_0x5d1a4c('0x10')](0x1f4,_0xd3c3a0[_0x5d1a4c('0xb')]));});});},exports[_0x48d4b5('0x1')]=function(_0x563ccd){const _0x1397c9=this;return new Promise(function(_0x571154,_0x279444){const _0x141493=a215_0x31bd;return db[_0x141493('0x4')]['findOne']({'raw':_0x563ccd[_0x141493('0x7')]?_0x563ccd[_0x141493('0x7')][_0x141493('0x6')]===undefined?!![]:![]:!![],'where':_0x563ccd[_0x141493('0x7')]?_0x563ccd['options'][_0x141493('0xd')]||null:null,'attributes':_0x563ccd[_0x141493('0x7')]?_0x563ccd['options'][_0x141493('0x15')]||null:null,'include':_0x563ccd[_0x141493('0x7')]?_0x563ccd[_0x141493('0x7')][_0x141493('0x11')]?_[_0x141493('0x9')](_0x563ccd[_0x141493('0x7')][_0x141493('0x11')],function(_0x371063){const _0x182226=_0x141493;return{'model':db[_0x371063[_0x182226('0x2')]],'as':_0x371063['as'],'attributes':_0x371063[_0x182226('0x15')],'include':_0x371063[_0x182226('0x11')]?_[_0x182226('0x9')](_0x371063[_0x182226('0x11')],function(_0x526328){const _0x3de1d6=_0x182226;return{'model':db[_0x526328[_0x3de1d6('0x2')]],'as':_0x526328['as'],'attributes':_0x526328[_0x3de1d6('0x15')],'include':_0x526328[_0x3de1d6('0x11')]?_[_0x3de1d6('0x9')](_0x526328['include'],function(_0x4c4e41){const _0x12dcd7=_0x3de1d6;return{'model':db[_0x4c4e41[_0x12dcd7('0x2')]],'as':_0x4c4e41['as'],'attributes':_0x4c4e41[_0x12dcd7('0x15')]};}):[]};}):[]};}):[]:[]})[_0x141493('0x8')](function(_0x50c347){const _0x1afd04=_0x141493;logger[_0x1afd04('0x0')](_0x1afd04('0x1'),_0x563ccd),logger[_0x1afd04('0x3')](_0x1afd04('0x1'),_0x563ccd,JSON[_0x1afd04('0xa')](_0x50c347)),_0x571154(_0x50c347);})['catch'](function(_0x17626c){const _0xb11e86=_0x141493;logger[_0xb11e86('0x10')](_0xb11e86('0x1'),_0x17626c['message'],_0x563ccd),_0x279444(_0x1397c9[_0xb11e86('0x10')](0x1f4,_0x17626c[_0xb11e86('0xb')]));});});}; \ No newline at end of file diff --git a/server/api/faxQueue/faxQueue.socket.js b/server/api/faxQueue/faxQueue.socket.js index b814953..8516162 100644 --- a/server/api/faxQueue/faxQueue.socket.js +++ b/server/api/faxQueue/faxQueue.socket.js @@ -1 +1 @@ -const a216_0x2f48=['register','emit','update','length','remove','./faxQueue.events'];(function(_0x2740f2,_0x2f4889){const _0x5e82ed=function(_0x3d06b8){while(--_0x3d06b8){_0x2740f2['push'](_0x2740f2['shift']());}};_0x5e82ed(++_0x2f4889);}(a216_0x2f48,0x1d7));const a216_0x5e82=function(_0x2740f2,_0x2f4889){_0x2740f2=_0x2740f2-0x0;let _0x5e82ed=a216_0x2f48[_0x2740f2];return _0x5e82ed;};const _0x3f9bc1=a216_0x5e82;'use strict';const FaxQueueEvents=require(_0x3f9bc1('0x2')),events=['save',_0x3f9bc1('0x1'),_0x3f9bc1('0x5')];function createListener(_0x3d06b8,_0x32bb80){return function(_0x570f42){const _0x10f83c=a216_0x5e82;_0x32bb80[_0x10f83c('0x4')](_0x3d06b8,_0x570f42);};}exports[_0x3f9bc1('0x3')]=function(_0x51a607){const _0xa90641=_0x3f9bc1;for(let _0x49317c=0x0,_0x4d5ac0=events[_0xa90641('0x0')];_0x49317c<_0x4d5ac0;_0x49317c++){const _0x1ee886=events[_0x49317c],_0x1af693=createListener('faxQueue:'+_0x1ee886,_0x51a607);FaxQueueEvents['on'](_0x1ee886,_0x1af693);}}; \ No newline at end of file +const a216_0x6929=['update','emit','./faxQueue.events','register','faxQueue:','save'];(function(_0x41ea5e,_0x6929a9){const _0x397017=function(_0x523061){while(--_0x523061){_0x41ea5e['push'](_0x41ea5e['shift']());}};_0x397017(++_0x6929a9);}(a216_0x6929,0x1aa));const a216_0x3970=function(_0x41ea5e,_0x6929a9){_0x41ea5e=_0x41ea5e-0x0;let _0x397017=a216_0x6929[_0x41ea5e];return _0x397017;};const _0x50cbc2=a216_0x3970;'use strict';const FaxQueueEvents=require(_0x50cbc2('0x2')),events=[_0x50cbc2('0x5'),'remove',_0x50cbc2('0x0')];function createListener(_0x523061,_0x171fa0){return function(_0x206128){const _0x37f23a=a216_0x3970;_0x171fa0[_0x37f23a('0x1')](_0x523061,_0x206128);};}exports[_0x50cbc2('0x3')]=function(_0x1bac85){const _0x4ea647=_0x50cbc2;for(let _0x4207b2=0x0,_0x4b21ae=events['length'];_0x4207b2<_0x4b21ae;_0x4207b2++){const _0xa5789b=events[_0x4207b2],_0x3fb33c=createListener(_0x4ea647('0x4')+_0xa5789b,_0x1bac85);FaxQueueEvents['on'](_0xa5789b,_0x3fb33c);}}; \ No newline at end of file diff --git a/server/api/faxQueue/index.js b/server/api/faxQueue/index.js index 15f08f0..7f97e31 100644 --- a/server/api/faxQueue/index.js +++ b/server/api/faxQueue/index.js @@ -1 +1 @@ -const a217_0x3856=['/:id/teams','addAgents','express','index','removeAgents','../../components/auth/service','post','update','get','describe','show','/describe','/:id','removeTeams','delete','./faxQueue.controller','/:id/users','isAuthenticated','Router','addTeams','getMembers','put','getAgents'];(function(_0x41b5a2,_0x385608){const _0x418e64=function(_0x28fb6d){while(--_0x28fb6d){_0x41b5a2['push'](_0x41b5a2['shift']());}};_0x418e64(++_0x385608);}(a217_0x3856,0x143));const a217_0x418e=function(_0x41b5a2,_0x385608){_0x41b5a2=_0x41b5a2-0x0;let _0x418e64=a217_0x3856[_0x41b5a2];return _0x418e64;};const _0x558e94=a217_0x418e;'use strict';const express=require(_0x558e94('0x1')),router=express[_0x558e94('0x11')](),auth=require(_0x558e94('0x4')),controller=require(_0x558e94('0xe'));router[_0x558e94('0x7')]('/',auth[_0x558e94('0x10')](),controller[_0x558e94('0x2')]),router[_0x558e94('0x7')](_0x558e94('0xa'),auth['isAuthenticated'](),controller[_0x558e94('0x8')]),router[_0x558e94('0x7')](_0x558e94('0xb'),auth[_0x558e94('0x10')](),controller[_0x558e94('0x9')]),router[_0x558e94('0x7')]('/:id/members',auth[_0x558e94('0x10')](),controller[_0x558e94('0x13')]),router[_0x558e94('0x7')](_0x558e94('0x16'),auth[_0x558e94('0x10')](),controller['getTeams']),router[_0x558e94('0x7')]('/:id/users',auth[_0x558e94('0x10')](),controller[_0x558e94('0x15')]),router[_0x558e94('0x5')]('/',auth[_0x558e94('0x10')](),controller['create']),router[_0x558e94('0x5')](_0x558e94('0x16'),auth[_0x558e94('0x10')](),controller[_0x558e94('0x12')]),router[_0x558e94('0x5')](_0x558e94('0xf'),auth['isAuthenticated'](),controller[_0x558e94('0x0')]),router[_0x558e94('0x14')](_0x558e94('0xb'),auth[_0x558e94('0x10')](),controller[_0x558e94('0x6')]),router[_0x558e94('0xd')](_0x558e94('0xb'),auth[_0x558e94('0x10')](),controller['destroy']),router[_0x558e94('0xd')](_0x558e94('0x16'),auth[_0x558e94('0x10')](),controller[_0x558e94('0xc')]),router[_0x558e94('0xd')](_0x558e94('0xf'),auth[_0x558e94('0x10')](),controller[_0x558e94('0x3')]),module['exports']=router; \ No newline at end of file +const a217_0x5c60=['index','removeAgents','delete','getTeams','../../components/auth/service','getMembers','get','post','/:id/users','removeTeams','/:id','put','update','create','isAuthenticated','show','destroy','Router','/:id/members','./faxQueue.controller','/:id/teams'];(function(_0x1ff223,_0x5c6032){const _0x24dd78=function(_0x54acac){while(--_0x54acac){_0x1ff223['push'](_0x1ff223['shift']());}};_0x24dd78(++_0x5c6032);}(a217_0x5c60,0x64));const a217_0x24dd=function(_0x1ff223,_0x5c6032){_0x1ff223=_0x1ff223-0x0;let _0x24dd78=a217_0x5c60[_0x1ff223];return _0x24dd78;};const _0x1693e9=a217_0x24dd;'use strict';const express=require('express'),router=express[_0x1693e9('0x1')](),auth=require(_0x1693e9('0x9')),controller=require(_0x1693e9('0x3'));router[_0x1693e9('0xb')]('/',auth[_0x1693e9('0x13')](),controller[_0x1693e9('0x5')]),router['get']('/describe',auth[_0x1693e9('0x13')](),controller['describe']),router[_0x1693e9('0xb')](_0x1693e9('0xf'),auth[_0x1693e9('0x13')](),controller[_0x1693e9('0x14')]),router[_0x1693e9('0xb')](_0x1693e9('0x2'),auth[_0x1693e9('0x13')](),controller[_0x1693e9('0xa')]),router['get'](_0x1693e9('0x4'),auth['isAuthenticated'](),controller[_0x1693e9('0x8')]),router[_0x1693e9('0xb')](_0x1693e9('0xd'),auth['isAuthenticated'](),controller['getAgents']),router[_0x1693e9('0xc')]('/',auth[_0x1693e9('0x13')](),controller[_0x1693e9('0x12')]),router[_0x1693e9('0xc')](_0x1693e9('0x4'),auth[_0x1693e9('0x13')](),controller['addTeams']),router[_0x1693e9('0xc')](_0x1693e9('0xd'),auth[_0x1693e9('0x13')](),controller['addAgents']),router[_0x1693e9('0x10')](_0x1693e9('0xf'),auth['isAuthenticated'](),controller[_0x1693e9('0x11')]),router['delete']('/:id',auth['isAuthenticated'](),controller[_0x1693e9('0x0')]),router[_0x1693e9('0x7')]('/:id/teams',auth[_0x1693e9('0x13')](),controller[_0x1693e9('0xe')]),router[_0x1693e9('0x7')](_0x1693e9('0xd'),auth[_0x1693e9('0x13')](),controller[_0x1693e9('0x6')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/faxQueueReport/faxQueueReport.attributes.js b/server/api/faxQueueReport/faxQueueReport.attributes.js index f9d2a6e..ff90116 100644 --- a/server/api/faxQueueReport/faxQueueReport.attributes.js +++ b/server/api/faxQueueReport/faxQueueReport.attributes.js @@ -1 +1 @@ -const a218_0x3a08=['DATE','STRING','sequelize','exports'];(function(_0x344bff,_0x3a08a2){const _0x5e24b3=function(_0x1b52c2){while(--_0x1b52c2){_0x344bff['push'](_0x344bff['shift']());}};_0x5e24b3(++_0x3a08a2);}(a218_0x3a08,0x1c4));const a218_0x5e24=function(_0x344bff,_0x3a08a2){_0x344bff=_0x344bff-0x0;let _0x5e24b3=a218_0x3a08[_0x344bff];return _0x5e24b3;};const _0x5c67b7=a218_0x5e24;'use strict';const Sequelize=require(_0x5c67b7('0x2'));module[_0x5c67b7('0x3')]={'uniqueid':{'type':Sequelize[_0x5c67b7('0x1')],'allowNull':![]},'from':{'type':Sequelize[_0x5c67b7('0x1')]},'joinAt':{'type':Sequelize[_0x5c67b7('0x0')]},'leaveAt':{'type':Sequelize[_0x5c67b7('0x0')]},'acceptAt':{'type':Sequelize[_0x5c67b7('0x0')]},'exitAt':{'type':Sequelize['DATE']},'reason':{'type':Sequelize[_0x5c67b7('0x1')]}}; \ No newline at end of file +const a218_0x33d8=['STRING','sequelize','DATE','exports'];(function(_0x41c292,_0x33d870){const _0x5010b7=function(_0x188e97){while(--_0x188e97){_0x41c292['push'](_0x41c292['shift']());}};_0x5010b7(++_0x33d870);}(a218_0x33d8,0x15f));const a218_0x5010=function(_0x41c292,_0x33d870){_0x41c292=_0x41c292-0x0;let _0x5010b7=a218_0x33d8[_0x41c292];return _0x5010b7;};const _0x390e01=a218_0x5010;'use strict';const Sequelize=require(_0x390e01('0x2'));module[_0x390e01('0x0')]={'uniqueid':{'type':Sequelize['STRING'],'allowNull':![]},'from':{'type':Sequelize[_0x390e01('0x1')]},'joinAt':{'type':Sequelize[_0x390e01('0x3')]},'leaveAt':{'type':Sequelize[_0x390e01('0x3')]},'acceptAt':{'type':Sequelize[_0x390e01('0x3')]},'exitAt':{'type':Sequelize[_0x390e01('0x3')]},'reason':{'type':Sequelize[_0x390e01('0x1')]}}; \ No newline at end of file diff --git a/server/api/faxQueueReport/faxQueueReport.controller.js b/server/api/faxQueueReport/faxQueueReport.controller.js index 1e35add..42da15c 100644 --- a/server/api/faxQueueReport/faxQueueReport.controller.js +++ b/server/api/faxQueueReport/faxQueueReport.controller.js @@ -1 +1 @@ -const a219_0x2f5b=['count','body','options','includeAll','pick','catch','params','order','key','error','query','undefined','keys','name','send','Content-Range','then','fields','model','length','findOne','offset','map','set','create','index','status','merge','lodash','where','../../config/logger','type','filter','sort','rows','../../components/parsers/qs','api','FaxQueueReport','stack','sendStatus','show','json','rawAttributes','update','nolimit','describe','../../mysqldb','filters','VIRTUAL','end','sequelize','limit','like','destroy','attributes','intersection'];(function(_0x39af39,_0x2f5bad){const _0x3d3c99=function(_0x499c12){while(--_0x499c12){_0x39af39['push'](_0x39af39['shift']());}};_0x3d3c99(++_0x2f5bad);}(a219_0x2f5b,0x116));const a219_0x3d3c=function(_0x39af39,_0x2f5bad){_0x39af39=_0x39af39-0x0;let _0x3d3c99=a219_0x2f5b[_0x39af39];return _0x3d3c99;};const _0x531e3=a219_0x3d3c;'use strict';const _=require(_0x531e3('0x1e')),qs=require(_0x531e3('0x25')),logger=require(_0x531e3('0x20'))(_0x531e3('0x26')),db=require(_0x531e3('0x30'))['db'],{Op}=require(_0x531e3('0x34'));function respondWithResult(_0x499c12,_0xe9fa19){return _0xe9fa19=_0xe9fa19||0xc8,function(_0xcfc338){const _0x35a0c8=a219_0x3d3c;if(_0xcfc338)return _0x499c12[_0x35a0c8('0x1c')](_0xe9fa19)[_0x35a0c8('0x2b')](_0xcfc338);};}function respondWithFilteredResult(_0xa6e377,_0x1cd10d){return function(_0x102edf){const _0x242ec9=a219_0x3d3c;if(_0x102edf){const _0x44079a=_0x102edf[_0x242ec9('0x2')],_0x3ed025=_0x1cd10d['offset'];let _0x2528c2=_0x1cd10d[_0x242ec9('0x17')]+_0x1cd10d[_0x242ec9('0x35')],_0x80665e;return _0x2528c2>=_0x44079a?(_0x2528c2=_0x44079a,_0x80665e=0xc8):_0x80665e=0xce,_0xa6e377[_0x242ec9('0x1c')](_0x80665e),_0xa6e377[_0x242ec9('0x19')](_0x242ec9('0x11'),_0x3ed025+'-'+_0x2528c2+'/'+_0x44079a)[_0x242ec9('0x2b')](_0x102edf);}return null;};}function saveUpdates(_0x5b123a){return function(_0x5b8423){if(_0x5b8423)return _0x5b8423['update'](_0x5b123a)['then'](function(_0x1b6a69){return _0x1b6a69;});return null;};}function removeEntity(_0x4e53e5){return function(_0x262e68){const _0x2a1167=a219_0x3d3c;if(_0x262e68)return _0x262e68[_0x2a1167('0x37')]()[_0x2a1167('0x12')](function(){const _0x49deda=_0x2a1167;_0x4e53e5[_0x49deda('0x1c')](0xcc)[_0x49deda('0x33')]();});};}function handleEntityNotFound(_0x3a796f){return function(_0x27ccf8){const _0x5bb22e=a219_0x3d3c;return!_0x27ccf8&&_0x3a796f[_0x5bb22e('0x29')](0x194),_0x27ccf8;};}function handleError(_0x29f7a8,_0x444ce1){return _0x444ce1=_0x444ce1||0x1f4,function(_0x5875a1){const _0x287273=a219_0x3d3c;logger[_0x287273('0xb')](_0x5875a1[_0x287273('0x28')]),_0x5875a1['name']&&delete _0x5875a1[_0x287273('0xf')],_0x29f7a8[_0x287273('0x1c')](_0x444ce1)[_0x287273('0x10')](_0x5875a1);};}exports[_0x531e3('0x1b')]=function(_0x4160ab,_0x30dd09){const _0x30ae93=_0x531e3;let _0x2340a6={};const _0x4ef886={},_0x2fbe99={'count':0x0,'rows':[]},_0x22ae43=_[_0x30ae93('0x18')](db[_0x30ae93('0x27')][_0x30ae93('0x2c')],function(_0x2d0a13){const _0x42f5da=_0x30ae93;return{'name':_0x2d0a13['fieldName'],'type':_0x2d0a13[_0x42f5da('0x21')][_0x42f5da('0xa')]};});_0x4ef886[_0x30ae93('0x14')]=_[_0x30ae93('0x18')](_0x22ae43,_0x30ae93('0xf')),_0x4ef886['query']=_[_0x30ae93('0xe')](_0x4160ab['query']),_0x4ef886['filters']=_[_0x30ae93('0x1')](_0x4ef886[_0x30ae93('0x14')],_0x4ef886[_0x30ae93('0xc')]),_0x2340a6[_0x30ae93('0x0')]=_[_0x30ae93('0x1')](_0x4ef886[_0x30ae93('0x14')],qs[_0x30ae93('0x13')](_0x4160ab[_0x30ae93('0xc')][_0x30ae93('0x13')])),_0x2340a6[_0x30ae93('0x0')]=_0x2340a6[_0x30ae93('0x0')][_0x30ae93('0x15')]?_0x2340a6[_0x30ae93('0x0')]:_0x4ef886[_0x30ae93('0x14')];typeof _0x4160ab[_0x30ae93('0xc')][_0x30ae93('0x2e')]===_0x30ae93('0xd')&&(_0x2340a6['limit']=qs[_0x30ae93('0x35')](_0x4160ab['query']['limit']),_0x2340a6['offset']=qs[_0x30ae93('0x17')](_0x4160ab[_0x30ae93('0xc')]['offset']));_0x2340a6[_0x30ae93('0x9')]=qs[_0x30ae93('0x23')](_0x4160ab[_0x30ae93('0xc')][_0x30ae93('0x23')]),_0x2340a6[_0x30ae93('0x1f')]=qs['filters'](_[_0x30ae93('0x6')](_0x4160ab[_0x30ae93('0xc')],_0x4ef886[_0x30ae93('0x31')]),_0x22ae43);_0x4160ab['query'][_0x30ae93('0x22')]&&(_0x2340a6[_0x30ae93('0x1f')]=_[_0x30ae93('0x1d')](_0x2340a6['where'],{[Op['or']]:_[_0x30ae93('0x18')](_0x22ae43,function(_0x1a32e9){const _0xfff531=_0x30ae93;if(_0x1a32e9[_0xfff531('0x21')]!==_0xfff531('0x32')){const _0x4d038c={};return _0x4d038c[_0x1a32e9[_0xfff531('0xf')]]={[Op[_0xfff531('0x36')]]:'%'+_0x4160ab[_0xfff531('0xc')]['filter']+'%'},_0x4d038c;}})}));_0x2340a6=_[_0x30ae93('0x1d')]({},_0x2340a6,_0x4160ab['options']);const _0x26a5c8={'where':_0x2340a6['where']};return db[_0x30ae93('0x27')]['count'](_0x26a5c8)[_0x30ae93('0x12')](function(_0x447593){const _0x4bacbc=_0x30ae93;return _0x2fbe99[_0x4bacbc('0x2')]=_0x447593,_0x4160ab[_0x4bacbc('0xc')]['includeAll']&&(_0x2340a6['include']=[{'all':!![]}]),db[_0x4bacbc('0x27')]['findAll'](_0x2340a6);})['then'](function(_0x22f294){const _0x4929be=_0x30ae93;return _0x2fbe99[_0x4929be('0x24')]=_0x22f294,_0x2fbe99;})[_0x30ae93('0x12')](respondWithFilteredResult(_0x30dd09,_0x2340a6))[_0x30ae93('0x7')](handleError(_0x30dd09,null));},exports[_0x531e3('0x2a')]=function(_0x1a5b0c,_0x3626c7){const _0x10d5c0=_0x531e3;let _0x1917b9={'raw':!![],'where':{'id':_0x1a5b0c[_0x10d5c0('0x8')]['id']}};const _0x42ba9b={};return _0x42ba9b['model']=_['keys'](db[_0x10d5c0('0x27')][_0x10d5c0('0x2c')]),_0x42ba9b[_0x10d5c0('0xc')]=_[_0x10d5c0('0xe')](_0x1a5b0c[_0x10d5c0('0xc')]),_0x42ba9b[_0x10d5c0('0x31')]=_[_0x10d5c0('0x1')](_0x42ba9b['model'],_0x42ba9b[_0x10d5c0('0xc')]),_0x1917b9[_0x10d5c0('0x0')]=_[_0x10d5c0('0x1')](_0x42ba9b[_0x10d5c0('0x14')],qs[_0x10d5c0('0x13')](_0x1a5b0c['query'][_0x10d5c0('0x13')])),_0x1917b9[_0x10d5c0('0x0')]=_0x1917b9[_0x10d5c0('0x0')][_0x10d5c0('0x15')]?_0x1917b9[_0x10d5c0('0x0')]:_0x42ba9b[_0x10d5c0('0x14')],_0x1a5b0c[_0x10d5c0('0xc')][_0x10d5c0('0x5')]&&(_0x1917b9['include']=[{'all':!![]}]),_0x1917b9=_[_0x10d5c0('0x1d')]({},_0x1917b9,_0x1a5b0c[_0x10d5c0('0x4')]),db[_0x10d5c0('0x27')]['findOne'](_0x1917b9)[_0x10d5c0('0x12')](handleEntityNotFound(_0x3626c7,null))[_0x10d5c0('0x12')](respondWithResult(_0x3626c7,null))[_0x10d5c0('0x7')](handleError(_0x3626c7,null));},exports[_0x531e3('0x1a')]=function(_0x2e35dd,_0xe1f202){const _0x33eaf1=_0x531e3;return db[_0x33eaf1('0x27')][_0x33eaf1('0x1a')](_0x2e35dd[_0x33eaf1('0x3')],{})[_0x33eaf1('0x12')](respondWithResult(_0xe1f202,0xc9))[_0x33eaf1('0x7')](handleError(_0xe1f202,null));},exports[_0x531e3('0x2d')]=function(_0x3344f5,_0x444cfa){const _0x1cf9d7=_0x531e3;return _0x3344f5[_0x1cf9d7('0x3')]['id']&&delete _0x3344f5['body']['id'],db['FaxQueueReport'][_0x1cf9d7('0x16')]({'where':{'id':_0x3344f5['params']['id']}})['then'](handleEntityNotFound(_0x444cfa,null))['then'](saveUpdates(_0x3344f5[_0x1cf9d7('0x3')],null))[_0x1cf9d7('0x12')](respondWithResult(_0x444cfa,null))[_0x1cf9d7('0x7')](handleError(_0x444cfa,null));},exports[_0x531e3('0x37')]=function(_0x179414,_0x878b16){const _0x38dd30=_0x531e3;return db[_0x38dd30('0x27')][_0x38dd30('0x16')]({'where':{'id':_0x179414[_0x38dd30('0x8')]['id']}})['then'](handleEntityNotFound(_0x878b16,null))['then'](removeEntity(_0x878b16,null))[_0x38dd30('0x7')](handleError(_0x878b16,null));},exports[_0x531e3('0x2f')]=function(_0x544e08,_0x3c1dd7){const _0xa06d13=_0x531e3;return db['FaxQueueReport']['describe']()[_0xa06d13('0x12')](respondWithResult(_0x3c1dd7,null))[_0xa06d13('0x7')](handleError(_0x3c1dd7,null));}; \ No newline at end of file +const a219_0x5348=['create','pick','sequelize','status','stack','type','findOne','limit','map','length','merge','undefined','../../mysqldb','body','keys','name','catch','FaxQueueReport','key','model','update','send','offset','count','then','filters','rows','../../components/parsers/qs','../../config/logger','lodash','attributes','fields','filter','where','sort','findAll','VIRTUAL','order','includeAll','Content-Range','include','intersection','fieldName','json','rawAttributes','describe','set','index','destroy','options','params','query','error'];(function(_0x26a666,_0x53485a){const _0x19ac0d=function(_0x2c6877){while(--_0x2c6877){_0x26a666['push'](_0x26a666['shift']());}};_0x19ac0d(++_0x53485a);}(a219_0x5348,0x16b));const a219_0x19ac=function(_0x26a666,_0x53485a){_0x26a666=_0x26a666-0x0;let _0x19ac0d=a219_0x5348[_0x26a666];return _0x19ac0d;};const _0x2f476a=a219_0x19ac;'use strict';const _=require(_0x2f476a('0x25')),qs=require(_0x2f476a('0x23')),logger=require(_0x2f476a('0x24'))('api'),db=require(_0x2f476a('0x14'))['db'],{Op}=require(_0x2f476a('0xa'));function respondWithResult(_0x2c6877,_0x244b6b){return _0x244b6b=_0x244b6b||0xc8,function(_0x19a764){const _0x3bb8f9=a219_0x19ac;if(_0x19a764)return _0x2c6877['status'](_0x244b6b)[_0x3bb8f9('0x33')](_0x19a764);};}function respondWithFilteredResult(_0x3fb0e8,_0x295f97){return function(_0x183c8c){const _0xcc7a81=a219_0x19ac;if(_0x183c8c){const _0x55d415=_0x183c8c[_0xcc7a81('0x1f')],_0x496ae9=_0x295f97[_0xcc7a81('0x1e')];let _0x254f3c=_0x295f97['offset']+_0x295f97['limit'],_0x3cff33;return _0x254f3c>=_0x55d415?(_0x254f3c=_0x55d415,_0x3cff33=0xc8):_0x3cff33=0xce,_0x3fb0e8['status'](_0x3cff33),_0x3fb0e8[_0xcc7a81('0x1')](_0xcc7a81('0x2f'),_0x496ae9+'-'+_0x254f3c+'/'+_0x55d415)[_0xcc7a81('0x33')](_0x183c8c);}return null;};}function saveUpdates(_0xb96e98){return function(_0xa3dac2){const _0x2e1710=a219_0x19ac;if(_0xa3dac2)return _0xa3dac2[_0x2e1710('0x1c')](_0xb96e98)[_0x2e1710('0x20')](function(_0x4f5546){return _0x4f5546;});return null;};}function removeEntity(_0x52c046){return function(_0x3743c7){if(_0x3743c7)return _0x3743c7['destroy']()['then'](function(){const _0x768e8d=a219_0x19ac;_0x52c046[_0x768e8d('0xb')](0xcc)['end']();});};}function handleEntityNotFound(_0x21facf){return function(_0x5e28f1){return!_0x5e28f1&&_0x21facf['sendStatus'](0x194),_0x5e28f1;};}function handleError(_0x521a35,_0x519804){return _0x519804=_0x519804||0x1f4,function(_0xdf2ae9){const _0x44acc5=a219_0x19ac;logger[_0x44acc5('0x7')](_0xdf2ae9[_0x44acc5('0xc')]),_0xdf2ae9[_0x44acc5('0x17')]&&delete _0xdf2ae9[_0x44acc5('0x17')],_0x521a35['status'](_0x519804)[_0x44acc5('0x1d')](_0xdf2ae9);};}exports[_0x2f476a('0x2')]=function(_0x1be810,_0xb75214){const _0x1f210a=_0x2f476a;let _0x54cf81={};const _0x44f5d5={},_0x438645={'count':0x0,'rows':[]},_0x15635b=_['map'](db[_0x1f210a('0x19')][_0x1f210a('0x34')],function(_0x3e1735){const _0x918c13=_0x1f210a;return{'name':_0x3e1735[_0x918c13('0x32')],'type':_0x3e1735['type'][_0x918c13('0x1a')]};});_0x44f5d5[_0x1f210a('0x1b')]=_[_0x1f210a('0x10')](_0x15635b,_0x1f210a('0x17')),_0x44f5d5['query']=_[_0x1f210a('0x16')](_0x1be810[_0x1f210a('0x6')]),_0x44f5d5[_0x1f210a('0x21')]=_[_0x1f210a('0x31')](_0x44f5d5[_0x1f210a('0x1b')],_0x44f5d5[_0x1f210a('0x6')]),_0x54cf81['attributes']=_[_0x1f210a('0x31')](_0x44f5d5[_0x1f210a('0x1b')],qs[_0x1f210a('0x27')](_0x1be810['query'][_0x1f210a('0x27')])),_0x54cf81['attributes']=_0x54cf81[_0x1f210a('0x26')]['length']?_0x54cf81[_0x1f210a('0x26')]:_0x44f5d5[_0x1f210a('0x1b')];typeof _0x1be810[_0x1f210a('0x6')]['nolimit']===_0x1f210a('0x13')&&(_0x54cf81[_0x1f210a('0xf')]=qs[_0x1f210a('0xf')](_0x1be810['query']['limit']),_0x54cf81['offset']=qs[_0x1f210a('0x1e')](_0x1be810['query'][_0x1f210a('0x1e')]));_0x54cf81[_0x1f210a('0x2d')]=qs[_0x1f210a('0x2a')](_0x1be810[_0x1f210a('0x6')]['sort']),_0x54cf81[_0x1f210a('0x29')]=qs['filters'](_[_0x1f210a('0x9')](_0x1be810[_0x1f210a('0x6')],_0x44f5d5[_0x1f210a('0x21')]),_0x15635b);_0x1be810[_0x1f210a('0x6')][_0x1f210a('0x28')]&&(_0x54cf81[_0x1f210a('0x29')]=_['merge'](_0x54cf81[_0x1f210a('0x29')],{[Op['or']]:_[_0x1f210a('0x10')](_0x15635b,function(_0x3209a5){const _0x42e32b=_0x1f210a;if(_0x3209a5[_0x42e32b('0xd')]!==_0x42e32b('0x2c')){const _0x5f56a0={};return _0x5f56a0[_0x3209a5[_0x42e32b('0x17')]]={[Op['like']]:'%'+_0x1be810[_0x42e32b('0x6')][_0x42e32b('0x28')]+'%'},_0x5f56a0;}})}));_0x54cf81=_[_0x1f210a('0x12')]({},_0x54cf81,_0x1be810[_0x1f210a('0x4')]);const _0xb3e1ef={'where':_0x54cf81[_0x1f210a('0x29')]};return db['FaxQueueReport'][_0x1f210a('0x1f')](_0xb3e1ef)['then'](function(_0x545fb3){const _0x414d40=_0x1f210a;return _0x438645[_0x414d40('0x1f')]=_0x545fb3,_0x1be810[_0x414d40('0x6')][_0x414d40('0x2e')]&&(_0x54cf81[_0x414d40('0x30')]=[{'all':!![]}]),db[_0x414d40('0x19')][_0x414d40('0x2b')](_0x54cf81);})[_0x1f210a('0x20')](function(_0x1bbead){const _0x21f245=_0x1f210a;return _0x438645[_0x21f245('0x22')]=_0x1bbead,_0x438645;})['then'](respondWithFilteredResult(_0xb75214,_0x54cf81))[_0x1f210a('0x18')](handleError(_0xb75214,null));},exports['show']=function(_0x50cd06,_0x276975){const _0x2a96b4=_0x2f476a;let _0x981aba={'raw':!![],'where':{'id':_0x50cd06['params']['id']}};const _0x5874e7={};return _0x5874e7[_0x2a96b4('0x1b')]=_['keys'](db[_0x2a96b4('0x19')][_0x2a96b4('0x34')]),_0x5874e7[_0x2a96b4('0x6')]=_['keys'](_0x50cd06[_0x2a96b4('0x6')]),_0x5874e7[_0x2a96b4('0x21')]=_[_0x2a96b4('0x31')](_0x5874e7[_0x2a96b4('0x1b')],_0x5874e7['query']),_0x981aba[_0x2a96b4('0x26')]=_[_0x2a96b4('0x31')](_0x5874e7[_0x2a96b4('0x1b')],qs[_0x2a96b4('0x27')](_0x50cd06[_0x2a96b4('0x6')][_0x2a96b4('0x27')])),_0x981aba['attributes']=_0x981aba[_0x2a96b4('0x26')][_0x2a96b4('0x11')]?_0x981aba[_0x2a96b4('0x26')]:_0x5874e7['model'],_0x50cd06[_0x2a96b4('0x6')][_0x2a96b4('0x2e')]&&(_0x981aba[_0x2a96b4('0x30')]=[{'all':!![]}]),_0x981aba=_[_0x2a96b4('0x12')]({},_0x981aba,_0x50cd06[_0x2a96b4('0x4')]),db['FaxQueueReport'][_0x2a96b4('0xe')](_0x981aba)[_0x2a96b4('0x20')](handleEntityNotFound(_0x276975,null))[_0x2a96b4('0x20')](respondWithResult(_0x276975,null))[_0x2a96b4('0x18')](handleError(_0x276975,null));},exports[_0x2f476a('0x8')]=function(_0x333cf5,_0x2ecf0d){const _0x33a78d=_0x2f476a;return db[_0x33a78d('0x19')][_0x33a78d('0x8')](_0x333cf5[_0x33a78d('0x15')],{})['then'](respondWithResult(_0x2ecf0d,0xc9))[_0x33a78d('0x18')](handleError(_0x2ecf0d,null));},exports[_0x2f476a('0x1c')]=function(_0x22663b,_0x21778e){const _0x5b02c8=_0x2f476a;return _0x22663b[_0x5b02c8('0x15')]['id']&&delete _0x22663b[_0x5b02c8('0x15')]['id'],db[_0x5b02c8('0x19')][_0x5b02c8('0xe')]({'where':{'id':_0x22663b['params']['id']}})[_0x5b02c8('0x20')](handleEntityNotFound(_0x21778e,null))[_0x5b02c8('0x20')](saveUpdates(_0x22663b[_0x5b02c8('0x15')],null))[_0x5b02c8('0x20')](respondWithResult(_0x21778e,null))[_0x5b02c8('0x18')](handleError(_0x21778e,null));},exports[_0x2f476a('0x3')]=function(_0x41b63d,_0x335bee){const _0x5bec1c=_0x2f476a;return db['FaxQueueReport'][_0x5bec1c('0xe')]({'where':{'id':_0x41b63d[_0x5bec1c('0x5')]['id']}})[_0x5bec1c('0x20')](handleEntityNotFound(_0x335bee,null))['then'](removeEntity(_0x335bee,null))[_0x5bec1c('0x18')](handleError(_0x335bee,null));},exports[_0x2f476a('0x0')]=function(_0xd0f7fe,_0x2b8a1b){const _0x4ce456=_0x2f476a;return db[_0x4ce456('0x19')][_0x4ce456('0x0')]()[_0x4ce456('0x20')](respondWithResult(_0x2b8a1b,null))[_0x4ce456('0x18')](handleError(_0x2b8a1b,null));}; \ No newline at end of file diff --git a/server/api/faxQueueReport/faxQueueReport.model.js b/server/api/faxQueueReport/faxQueueReport.model.js index 762ce6c..83c2aa4 100644 --- a/server/api/faxQueueReport/faxQueueReport.model.js +++ b/server/api/faxQueueReport/faxQueueReport.model.js @@ -1 +1 @@ -const a220_0x3341=['report_fax_queue','uniqueid','exports','define','FaxQueueReport','./faxQueueReport.attributes'];(function(_0xef88a0,_0x3341d7){const _0x2c3547=function(_0x301ece){while(--_0x301ece){_0xef88a0['push'](_0xef88a0['shift']());}};_0x2c3547(++_0x3341d7);}(a220_0x3341,0x150));const a220_0x2c35=function(_0xef88a0,_0x3341d7){_0xef88a0=_0xef88a0-0x0;let _0x2c3547=a220_0x3341[_0xef88a0];return _0x2c3547;};const _0x178474=a220_0x2c35;'use strict';const attributes=require(_0x178474('0x5'));module[_0x178474('0x2')]=function(_0x301ece){const _0x5cec9b=_0x178474,_0x11c7ff=_0x301ece[_0x5cec9b('0x3')](_0x5cec9b('0x4'),attributes,{'tableName':_0x5cec9b('0x0'),'paranoid':![],'indexes':[{'name':_0x5cec9b('0x1'),'fields':[_0x5cec9b('0x1')]}],'timestamps':!![]});return _0x11c7ff;}; \ No newline at end of file +const a220_0x47d4=['uniqueid','exports','./faxQueueReport.attributes','report_fax_queue'];(function(_0x4a6d4b,_0x47d4ce){const _0x29af71=function(_0x5baa92){while(--_0x5baa92){_0x4a6d4b['push'](_0x4a6d4b['shift']());}};_0x29af71(++_0x47d4ce);}(a220_0x47d4,0xe5));const a220_0x29af=function(_0x4a6d4b,_0x47d4ce){_0x4a6d4b=_0x4a6d4b-0x0;let _0x29af71=a220_0x47d4[_0x4a6d4b];return _0x29af71;};const _0x44ac1f=a220_0x29af;'use strict';const attributes=require(_0x44ac1f('0x1'));module[_0x44ac1f('0x0')]=function(_0x5baa92){const _0x2d2a90=_0x44ac1f,_0x2b355a=_0x5baa92['define']('FaxQueueReport',attributes,{'tableName':_0x2d2a90('0x2'),'paranoid':![],'indexes':[{'name':_0x2d2a90('0x3'),'fields':[_0x2d2a90('0x3')]}],'timestamps':!![]});return _0x2b355a;}; \ No newline at end of file diff --git a/server/api/faxQueueReport/faxQueueReport.rpc.js b/server/api/faxQueueReport/faxQueueReport.rpc.js index 47c704d..978fde1 100644 --- a/server/api/faxQueueReport/faxQueueReport.rpc.js +++ b/server/api/faxQueueReport/faxQueueReport.rpc.js @@ -1 +1 @@ -const a221_0x26da=['../../config/logger','raw','FaxQueueReport','debug','then','limit','stringify','message','where','info','UpdateFaxQueueReport','body','error','CreateFaxQueueReport','../../mysqldb','catch','create','options'];(function(_0x348836,_0x26daa7){const _0x1ee534=function(_0xc3a79e){while(--_0xc3a79e){_0x348836['push'](_0x348836['shift']());}};_0x1ee534(++_0x26daa7);}(a221_0x26da,0x18d));const a221_0x1ee5=function(_0x348836,_0x26daa7){_0x348836=_0x348836-0x0;let _0x1ee534=a221_0x26da[_0x348836];return _0x1ee534;};const _0x18c37c=a221_0x1ee5;'use strict';const db=require(_0x18c37c('0xd'))['db'],logger=require(_0x18c37c('0x11'))('rpc');exports[_0x18c37c('0xc')]=function(_0xc3a79e){const _0x1b88b3=this;return new Promise(function(_0x2ec89f,_0x27d2f1){const _0x19c14f=a221_0x1ee5;return db[_0x19c14f('0x1')][_0x19c14f('0xf')](_0xc3a79e[_0x19c14f('0xa')],{'raw':_0xc3a79e[_0x19c14f('0x10')]?_0xc3a79e[_0x19c14f('0x10')][_0x19c14f('0x0')]===undefined?!![]:![]:!![]})[_0x19c14f('0x3')](function(_0x44db81){const _0x2c6e31=_0x19c14f;logger[_0x2c6e31('0x8')](_0x2c6e31('0xc'),_0xc3a79e),logger['debug'](_0x2c6e31('0xc'),_0xc3a79e,JSON[_0x2c6e31('0x5')](_0x44db81)),_0x2ec89f(_0x44db81);})[_0x19c14f('0xe')](function(_0x1100de){const _0x143525=_0x19c14f;logger[_0x143525('0xb')]('CreateFaxQueueReport',_0x1100de[_0x143525('0x6')],_0xc3a79e),_0x27d2f1(_0x1b88b3[_0x143525('0xb')](0x1f4,_0x1100de[_0x143525('0x6')]));});});},exports[_0x18c37c('0x9')]=function(_0x1f619d){const _0x11fd4a=this;return new Promise(function(_0x2b84d9,_0x404e39){const _0x3b4a4b=a221_0x1ee5;return db[_0x3b4a4b('0x1')]['update'](_0x1f619d['body'],{'raw':_0x1f619d[_0x3b4a4b('0x10')]?_0x1f619d[_0x3b4a4b('0x10')][_0x3b4a4b('0x0')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x1f619d[_0x3b4a4b('0x10')]?_0x1f619d['options'][_0x3b4a4b('0x7')]||null:null,'attributes':_0x1f619d['options']?_0x1f619d['options']['attributes']||null:null,'limit':_0x1f619d[_0x3b4a4b('0x10')]?_0x1f619d['options'][_0x3b4a4b('0x4')]||null:null})[_0x3b4a4b('0x3')](function(_0x393096){const _0x314634=_0x3b4a4b;logger[_0x314634('0x8')](_0x314634('0x9'),_0x1f619d),logger[_0x314634('0x2')](_0x314634('0x9'),_0x1f619d,JSON[_0x314634('0x5')](_0x393096)),_0x2b84d9(_0x393096);})[_0x3b4a4b('0xe')](function(_0x46d7f){const _0x151ee2=_0x3b4a4b;logger[_0x151ee2('0xb')](_0x151ee2('0x9'),_0x46d7f[_0x151ee2('0x6')],_0x1f619d),_0x404e39(_0x11fd4a['error'](0x1f4,_0x46d7f[_0x151ee2('0x6')]));});});}; \ No newline at end of file +const a221_0x346a=['stringify','../../config/logger','../../mysqldb','options','info','body','raw','error','then','CreateFaxQueueReport','debug','UpdateFaxQueueReport','message','catch','where','limit','attributes','rpc','create','FaxQueueReport'];(function(_0x378f59,_0x346a22){const _0x396935=function(_0x4618d9){while(--_0x4618d9){_0x378f59['push'](_0x378f59['shift']());}};_0x396935(++_0x346a22);}(a221_0x346a,0xe5));const a221_0x3969=function(_0x378f59,_0x346a22){_0x378f59=_0x378f59-0x0;let _0x396935=a221_0x346a[_0x378f59];return _0x396935;};const _0x14a397=a221_0x3969;'use strict';const db=require(_0x14a397('0xd'))['db'],logger=require(_0x14a397('0xc'))(_0x14a397('0x8'));exports[_0x14a397('0x0')]=function(_0x4618d9){const _0x4b4c34=this;return new Promise(function(_0x6390ba,_0x5910b8){const _0x42aff5=a221_0x3969;return db[_0x42aff5('0xa')][_0x42aff5('0x9')](_0x4618d9[_0x42aff5('0x10')],{'raw':_0x4618d9[_0x42aff5('0xe')]?_0x4618d9['options'][_0x42aff5('0x11')]===undefined?!![]:![]:!![]})[_0x42aff5('0x13')](function(_0x46105b){const _0x26efec=_0x42aff5;logger[_0x26efec('0xf')](_0x26efec('0x0'),_0x4618d9),logger[_0x26efec('0x1')](_0x26efec('0x0'),_0x4618d9,JSON['stringify'](_0x46105b)),_0x6390ba(_0x46105b);})[_0x42aff5('0x4')](function(_0x4fd836){const _0x28a44b=_0x42aff5;logger[_0x28a44b('0x12')]('CreateFaxQueueReport',_0x4fd836[_0x28a44b('0x3')],_0x4618d9),_0x5910b8(_0x4b4c34[_0x28a44b('0x12')](0x1f4,_0x4fd836['message']));});});},exports[_0x14a397('0x2')]=function(_0x21a3ec){const _0xfd671c=this;return new Promise(function(_0x250bb6,_0x24179c){const _0x2f1714=a221_0x3969;return db[_0x2f1714('0xa')]['update'](_0x21a3ec[_0x2f1714('0x10')],{'raw':_0x21a3ec[_0x2f1714('0xe')]?_0x21a3ec['options'][_0x2f1714('0x11')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x21a3ec['options']?_0x21a3ec['options'][_0x2f1714('0x5')]||null:null,'attributes':_0x21a3ec[_0x2f1714('0xe')]?_0x21a3ec[_0x2f1714('0xe')][_0x2f1714('0x7')]||null:null,'limit':_0x21a3ec[_0x2f1714('0xe')]?_0x21a3ec[_0x2f1714('0xe')][_0x2f1714('0x6')]||null:null})[_0x2f1714('0x13')](function(_0x331eb8){const _0x4fa1ef=_0x2f1714;logger[_0x4fa1ef('0xf')](_0x4fa1ef('0x2'),_0x21a3ec),logger['debug'](_0x4fa1ef('0x2'),_0x21a3ec,JSON[_0x4fa1ef('0xb')](_0x331eb8)),_0x250bb6(_0x331eb8);})[_0x2f1714('0x4')](function(_0x58c30b){const _0x54c2f1=_0x2f1714;logger['error']('UpdateFaxQueueReport',_0x58c30b[_0x54c2f1('0x3')],_0x21a3ec),_0x24179c(_0xfd671c['error'](0x1f4,_0x58c30b['message']));});});}; \ No newline at end of file diff --git a/server/api/faxQueueReport/index.js b/server/api/faxQueueReport/index.js index 7cb81d6..0078419 100644 --- a/server/api/faxQueueReport/index.js +++ b/server/api/faxQueueReport/index.js @@ -1 +1 @@ -const a222_0x5ba6=['isAuthenticated','destroy','exports','Router','delete','post','update','put','index','./faxQueueReport.controller','describe','express','../../components/auth/service','/:id','get'];(function(_0xf04bb6,_0x5ba626){const _0x1781a6=function(_0x23690f){while(--_0x23690f){_0xf04bb6['push'](_0xf04bb6['shift']());}};_0x1781a6(++_0x5ba626);}(a222_0x5ba6,0xa2));const a222_0x1781=function(_0xf04bb6,_0x5ba626){_0xf04bb6=_0xf04bb6-0x0;let _0x1781a6=a222_0x5ba6[_0xf04bb6];return _0x1781a6;};const _0x2586c3=a222_0x1781;'use strict';const express=require(_0x2586c3('0xe')),router=express[_0x2586c3('0x6')](),auth=require(_0x2586c3('0x0')),controller=require(_0x2586c3('0xc'));router[_0x2586c3('0x2')]('/',auth['isAuthenticated'](),controller[_0x2586c3('0xb')]),router[_0x2586c3('0x2')]('/describe',auth[_0x2586c3('0x3')](),controller[_0x2586c3('0xd')]),router[_0x2586c3('0x2')]('/:id',auth[_0x2586c3('0x3')](),controller['show']),router[_0x2586c3('0x8')]('/',auth[_0x2586c3('0x3')](),controller['create']),router[_0x2586c3('0xa')]('/:id',auth[_0x2586c3('0x3')](),controller[_0x2586c3('0x9')]),router[_0x2586c3('0x7')](_0x2586c3('0x1'),auth[_0x2586c3('0x3')](),controller[_0x2586c3('0x4')]),module[_0x2586c3('0x5')]=router; \ No newline at end of file +const a222_0xdca3=['isAuthenticated','index','get','Router','./faxQueueReport.controller','/:id','../../components/auth/service','destroy','exports','express','delete'];(function(_0x276cc6,_0xdca382){const _0x56aaa8=function(_0x81e946){while(--_0x81e946){_0x276cc6['push'](_0x276cc6['shift']());}};_0x56aaa8(++_0xdca382);}(a222_0xdca3,0x1a4));const a222_0x56aa=function(_0x276cc6,_0xdca382){_0x276cc6=_0x276cc6-0x0;let _0x56aaa8=a222_0xdca3[_0x276cc6];return _0x56aaa8;};const _0x5589ff=a222_0x56aa;'use strict';const express=require(_0x5589ff('0x7')),router=express[_0x5589ff('0x1')](),auth=require(_0x5589ff('0x4')),controller=require(_0x5589ff('0x2'));router[_0x5589ff('0x0')]('/',auth[_0x5589ff('0x9')](),controller[_0x5589ff('0xa')]),router[_0x5589ff('0x0')]('/describe',auth[_0x5589ff('0x9')](),controller['describe']),router[_0x5589ff('0x0')](_0x5589ff('0x3'),auth[_0x5589ff('0x9')](),controller['show']),router['post']('/',auth['isAuthenticated'](),controller['create']),router['put'](_0x5589ff('0x3'),auth[_0x5589ff('0x9')](),controller['update']),router[_0x5589ff('0x8')]('/:id',auth[_0x5589ff('0x9')](),controller[_0x5589ff('0x5')]),module[_0x5589ff('0x6')]=router; \ No newline at end of file diff --git a/server/api/faxTransferReport/faxTransferReport.attributes.js b/server/api/faxTransferReport/faxTransferReport.attributes.js index 7630f8e..2e6e3a2 100644 --- a/server/api/faxTransferReport/faxTransferReport.attributes.js +++ b/server/api/faxTransferReport/faxTransferReport.attributes.js @@ -1 +1 @@ -const a223_0x2ee7=['account','ENUM','sequelize','NOW','exports','queue'];(function(_0x1b1341,_0x2ee70f){const _0x1c44d5=function(_0x1d88d9){while(--_0x1d88d9){_0x1b1341['push'](_0x1b1341['shift']());}};_0x1c44d5(++_0x2ee70f);}(a223_0x2ee7,0x172));const a223_0x1c44=function(_0x1b1341,_0x2ee70f){_0x1b1341=_0x1b1341-0x0;let _0x1c44d5=a223_0x2ee7[_0x1b1341];return _0x1c44d5;};const _0xb57bfb=a223_0x1c44;'use strict';const Sequelize=require(_0xb57bfb('0x4'));module[_0xb57bfb('0x0')]={'uniqueid':{'type':Sequelize['STRING'],'allowNull':![]},'type':{'type':Sequelize[_0xb57bfb('0x3')](_0xb57bfb('0x2'),'agent',_0xb57bfb('0x1')),'allowNull':![],'defaultValue':_0xb57bfb('0x1')},'transferredAt':{'type':Sequelize['DATE'],'allowNull':![],'defaultValue':Sequelize[_0xb57bfb('0x5')]}}; \ No newline at end of file +const a223_0xda06=['account','NOW','queue','ENUM','agent','exports','DATE'];(function(_0x4dc9d3,_0xda06b2){const _0x4fe046=function(_0x4afaf7){while(--_0x4afaf7){_0x4dc9d3['push'](_0x4dc9d3['shift']());}};_0x4fe046(++_0xda06b2);}(a223_0xda06,0x7e));const a223_0x4fe0=function(_0x4dc9d3,_0xda06b2){_0x4dc9d3=_0x4dc9d3-0x0;let _0x4fe046=a223_0xda06[_0x4dc9d3];return _0x4fe046;};const _0x1cb470=a223_0x4fe0;'use strict';const Sequelize=require('sequelize');module[_0x1cb470('0x5')]={'uniqueid':{'type':Sequelize['STRING'],'allowNull':![]},'type':{'type':Sequelize[_0x1cb470('0x3')](_0x1cb470('0x0'),_0x1cb470('0x4'),_0x1cb470('0x2')),'allowNull':![],'defaultValue':_0x1cb470('0x2')},'transferredAt':{'type':Sequelize[_0x1cb470('0x6')],'allowNull':![],'defaultValue':Sequelize[_0x1cb470('0x1')]}}; \ No newline at end of file diff --git a/server/api/faxTransferReport/faxTransferReport.controller.js b/server/api/faxTransferReport/faxTransferReport.controller.js index 4ba63b4..8a07cf4 100644 --- a/server/api/faxTransferReport/faxTransferReport.controller.js +++ b/server/api/faxTransferReport/faxTransferReport.controller.js @@ -1 +1 @@ -const a224_0x5d76=['describe','query','fields','findAll','options','map','type','catch','keys','error','count','VIRTUAL','fieldName','filter','rows','set','update','includeAll','filters','rawAttributes','then','nolimit','offset','json','intersection','include','limit','params','undefined','stack','show','attributes','model','FaxTransferReport','order','sendStatus','status','pick','name','../../config/logger','index','body','api','findOne','where','merge','length','create','sort'];(function(_0x2642b4,_0x5d76c0){const _0x3733a4=function(_0x43e0f1){while(--_0x43e0f1){_0x2642b4['push'](_0x2642b4['shift']());}};_0x3733a4(++_0x5d76c0);}(a224_0x5d76,0xa6));const a224_0x3733=function(_0x2642b4,_0x5d76c0){_0x2642b4=_0x2642b4-0x0;let _0x3733a4=a224_0x5d76[_0x2642b4];return _0x3733a4;};const _0x1758f6=a224_0x3733;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x1758f6('0x14'))(_0x1758f6('0x17')),db=require('../../mysqldb')['db'],{Op}=require('sequelize');function respondWithResult(_0x43e0f1,_0x390e3f){return _0x390e3f=_0x390e3f||0xc8,function(_0x49aab3){const _0x1bb856=a224_0x3733;if(_0x49aab3)return _0x43e0f1[_0x1bb856('0x11')](_0x390e3f)[_0x1bb856('0x4')](_0x49aab3);};}function respondWithFilteredResult(_0x36cb72,_0x514128){return function(_0x56bedd){const _0x22cf87=a224_0x3733;if(_0x56bedd){const _0x46596f=_0x56bedd[_0x22cf87('0x28')],_0x425569=_0x514128[_0x22cf87('0x3')];let _0x583efc=_0x514128[_0x22cf87('0x3')]+_0x514128[_0x22cf87('0x7')],_0x386484;return _0x583efc>=_0x46596f?(_0x583efc=_0x46596f,_0x386484=0xc8):_0x386484=0xce,_0x36cb72[_0x22cf87('0x11')](_0x386484),_0x36cb72[_0x22cf87('0x2d')]('Content-Range',_0x425569+'-'+_0x583efc+'/'+_0x46596f)['json'](_0x56bedd);}return null;};}function saveUpdates(_0x45f685){return function(_0x35b15d){const _0x5c48e7=a224_0x3733;if(_0x35b15d)return _0x35b15d[_0x5c48e7('0x2e')](_0x45f685)['then'](function(_0x245979){return _0x245979;});return null;};}function removeEntity(_0x3226f8){return function(_0x30a9b3){const _0x2753d3=a224_0x3733;if(_0x30a9b3)return _0x30a9b3['destroy']()[_0x2753d3('0x1')](function(){const _0x1082d5=_0x2753d3;_0x3226f8[_0x1082d5('0x11')](0xcc)['end']();});};}function handleEntityNotFound(_0x3ea524){return function(_0x2429c5){const _0x48e71e=a224_0x3733;return!_0x2429c5&&_0x3ea524[_0x48e71e('0x10')](0x194),_0x2429c5;};}function handleError(_0x134f3f,_0x3f8edc){return _0x3f8edc=_0x3f8edc||0x1f4,function(_0x23a7f2){const _0x4accb7=a224_0x3733;logger[_0x4accb7('0x27')](_0x23a7f2[_0x4accb7('0xa')]),_0x23a7f2[_0x4accb7('0x13')]&&delete _0x23a7f2['name'],_0x134f3f[_0x4accb7('0x11')](_0x3f8edc)['send'](_0x23a7f2);};}exports[_0x1758f6('0x15')]=function(_0x34148f,_0x40393c){const _0x10cdc9=_0x1758f6;let _0x4c1656={};const _0x5ce9be={},_0xc792f5={'count':0x0,'rows':[]},_0x1b5588=_[_0x10cdc9('0x23')](db[_0x10cdc9('0xe')][_0x10cdc9('0x0')],function(_0x1db4aa){const _0x478609=_0x10cdc9;return{'name':_0x1db4aa[_0x478609('0x2a')],'type':_0x1db4aa['type']['key']};});_0x5ce9be[_0x10cdc9('0xd')]=_[_0x10cdc9('0x23')](_0x1b5588,_0x10cdc9('0x13')),_0x5ce9be[_0x10cdc9('0x1f')]=_['keys'](_0x34148f[_0x10cdc9('0x1f')]),_0x5ce9be[_0x10cdc9('0x30')]=_[_0x10cdc9('0x5')](_0x5ce9be[_0x10cdc9('0xd')],_0x5ce9be[_0x10cdc9('0x1f')]),_0x4c1656['attributes']=_['intersection'](_0x5ce9be[_0x10cdc9('0xd')],qs[_0x10cdc9('0x20')](_0x34148f[_0x10cdc9('0x1f')]['fields'])),_0x4c1656[_0x10cdc9('0xc')]=_0x4c1656[_0x10cdc9('0xc')][_0x10cdc9('0x1b')]?_0x4c1656[_0x10cdc9('0xc')]:_0x5ce9be['model'];typeof _0x34148f[_0x10cdc9('0x1f')][_0x10cdc9('0x2')]===_0x10cdc9('0x9')&&(_0x4c1656['limit']=qs[_0x10cdc9('0x7')](_0x34148f[_0x10cdc9('0x1f')]['limit']),_0x4c1656[_0x10cdc9('0x3')]=qs['offset'](_0x34148f['query']['offset']));_0x4c1656[_0x10cdc9('0xf')]=qs[_0x10cdc9('0x1d')](_0x34148f[_0x10cdc9('0x1f')][_0x10cdc9('0x1d')]),_0x4c1656[_0x10cdc9('0x19')]=qs[_0x10cdc9('0x30')](_[_0x10cdc9('0x12')](_0x34148f['query'],_0x5ce9be[_0x10cdc9('0x30')]),_0x1b5588);_0x34148f[_0x10cdc9('0x1f')]['filter']&&(_0x4c1656['where']=_[_0x10cdc9('0x1a')](_0x4c1656['where'],{[Op['or']]:_[_0x10cdc9('0x23')](_0x1b5588,function(_0xbd68e4){const _0x84e319=_0x10cdc9;if(_0xbd68e4[_0x84e319('0x24')]!==_0x84e319('0x29')){const _0x50bd23={};return _0x50bd23[_0xbd68e4[_0x84e319('0x13')]]={[Op['like']]:'%'+_0x34148f[_0x84e319('0x1f')][_0x84e319('0x2b')]+'%'},_0x50bd23;}})}));_0x4c1656=_['merge']({},_0x4c1656,_0x34148f[_0x10cdc9('0x22')]);const _0x43d496={'where':_0x4c1656[_0x10cdc9('0x19')]};return db[_0x10cdc9('0xe')][_0x10cdc9('0x28')](_0x43d496)[_0x10cdc9('0x1')](function(_0x8506aa){const _0x4ba9b2=_0x10cdc9;return _0xc792f5[_0x4ba9b2('0x28')]=_0x8506aa,_0x34148f[_0x4ba9b2('0x1f')][_0x4ba9b2('0x2f')]&&(_0x4c1656[_0x4ba9b2('0x6')]=[{'all':!![]}]),db[_0x4ba9b2('0xe')][_0x4ba9b2('0x21')](_0x4c1656);})[_0x10cdc9('0x1')](function(_0x5ee2b2){const _0x48cbe4=_0x10cdc9;return _0xc792f5[_0x48cbe4('0x2c')]=_0x5ee2b2,_0xc792f5;})['then'](respondWithFilteredResult(_0x40393c,_0x4c1656))[_0x10cdc9('0x25')](handleError(_0x40393c,null));},exports[_0x1758f6('0xb')]=function(_0x30d6d8,_0x442cc8){const _0x5e0638=_0x1758f6;let _0x2af931={'raw':!![],'where':{'id':_0x30d6d8[_0x5e0638('0x8')]['id']}};const _0x3c0dd7={};return _0x3c0dd7[_0x5e0638('0xd')]=_['keys'](db[_0x5e0638('0xe')][_0x5e0638('0x0')]),_0x3c0dd7['query']=_[_0x5e0638('0x26')](_0x30d6d8[_0x5e0638('0x1f')]),_0x3c0dd7[_0x5e0638('0x30')]=_['intersection'](_0x3c0dd7[_0x5e0638('0xd')],_0x3c0dd7[_0x5e0638('0x1f')]),_0x2af931['attributes']=_[_0x5e0638('0x5')](_0x3c0dd7[_0x5e0638('0xd')],qs[_0x5e0638('0x20')](_0x30d6d8[_0x5e0638('0x1f')][_0x5e0638('0x20')])),_0x2af931['attributes']=_0x2af931[_0x5e0638('0xc')][_0x5e0638('0x1b')]?_0x2af931['attributes']:_0x3c0dd7[_0x5e0638('0xd')],_0x30d6d8[_0x5e0638('0x1f')][_0x5e0638('0x2f')]&&(_0x2af931[_0x5e0638('0x6')]=[{'all':!![]}]),_0x2af931=_[_0x5e0638('0x1a')]({},_0x2af931,_0x30d6d8[_0x5e0638('0x22')]),db[_0x5e0638('0xe')][_0x5e0638('0x18')](_0x2af931)[_0x5e0638('0x1')](handleEntityNotFound(_0x442cc8,null))['then'](respondWithResult(_0x442cc8,null))[_0x5e0638('0x25')](handleError(_0x442cc8,null));},exports['create']=function(_0x1d4c55,_0x55174b){const _0x3e959e=_0x1758f6;return db[_0x3e959e('0xe')][_0x3e959e('0x1c')](_0x1d4c55['body'],{})[_0x3e959e('0x1')](respondWithResult(_0x55174b,0xc9))[_0x3e959e('0x25')](handleError(_0x55174b,null));},exports[_0x1758f6('0x2e')]=function(_0x180198,_0x34ffb4){const _0x1bfa70=_0x1758f6;return _0x180198[_0x1bfa70('0x16')]['id']&&delete _0x180198[_0x1bfa70('0x16')]['id'],db[_0x1bfa70('0xe')][_0x1bfa70('0x18')]({'where':{'id':_0x180198[_0x1bfa70('0x8')]['id']}})[_0x1bfa70('0x1')](handleEntityNotFound(_0x34ffb4,null))[_0x1bfa70('0x1')](saveUpdates(_0x180198['body'],null))[_0x1bfa70('0x1')](respondWithResult(_0x34ffb4,null))[_0x1bfa70('0x25')](handleError(_0x34ffb4,null));},exports['destroy']=function(_0x7130af,_0x1e7f29){const _0xd84a1d=_0x1758f6;return db[_0xd84a1d('0xe')][_0xd84a1d('0x18')]({'where':{'id':_0x7130af['params']['id']}})['then'](handleEntityNotFound(_0x1e7f29,null))['then'](removeEntity(_0x1e7f29,null))['catch'](handleError(_0x1e7f29,null));},exports[_0x1758f6('0x1e')]=function(_0x2ae9f4,_0x16b98d){const _0xf5c87d=_0x1758f6;return db[_0xf5c87d('0xe')][_0xf5c87d('0x1e')]()[_0xf5c87d('0x1')](respondWithResult(_0x16b98d,null))[_0xf5c87d('0x25')](handleError(_0x16b98d,null));}; \ No newline at end of file +const a224_0x3573=['sort','merge','status','type','query','send','../../mysqldb','then','offset','params','pick','model','destroy','findOne','sendStatus','undefined','VIRTUAL','sequelize','length','attributes','count','include','json','filters','name','limit','keys','map','lodash','Content-Range','key','filter','rows','catch','error','fields','update','intersection','../../config/logger','index','rawAttributes','set','order','api','FaxTransferReport','create','body','nolimit','where','describe','like'];(function(_0x3b1ded,_0x3573bc){const _0x4df32b=function(_0x10256c){while(--_0x10256c){_0x3b1ded['push'](_0x3b1ded['shift']());}};_0x4df32b(++_0x3573bc);}(a224_0x3573,0x165));const a224_0x4df3=function(_0x3b1ded,_0x3573bc){_0x3b1ded=_0x3b1ded-0x0;let _0x4df32b=a224_0x3573[_0x3b1ded];return _0x4df32b;};const _0x5382a6=a224_0x4df3;'use strict';const _=require(_0x5382a6('0x1c')),qs=require('../../components/parsers/qs'),logger=require(_0x5382a6('0x26'))(_0x5382a6('0x2b')),db=require(_0x5382a6('0x6'))['db'],{Op}=require(_0x5382a6('0x11'));function respondWithResult(_0x10256c,_0x58963c){return _0x58963c=_0x58963c||0xc8,function(_0x1c97a6){const _0x1c7f62=a224_0x4df3;if(_0x1c97a6)return _0x10256c[_0x1c7f62('0x2')](_0x58963c)['json'](_0x1c97a6);};}function respondWithFilteredResult(_0x29183e,_0x112a83){return function(_0x4ec40e){const _0x559674=a224_0x4df3;if(_0x4ec40e){const _0x3ff59d=_0x4ec40e[_0x559674('0x14')],_0x9de9fc=_0x112a83[_0x559674('0x8')];let _0x1f50ea=_0x112a83[_0x559674('0x8')]+_0x112a83['limit'],_0x48d339;return _0x1f50ea>=_0x3ff59d?(_0x1f50ea=_0x3ff59d,_0x48d339=0xc8):_0x48d339=0xce,_0x29183e[_0x559674('0x2')](_0x48d339),_0x29183e[_0x559674('0x29')](_0x559674('0x1d'),_0x9de9fc+'-'+_0x1f50ea+'/'+_0x3ff59d)[_0x559674('0x16')](_0x4ec40e);}return null;};}function saveUpdates(_0x47aa03){return function(_0x2beec1){const _0x39b9cb=a224_0x4df3;if(_0x2beec1)return _0x2beec1[_0x39b9cb('0x24')](_0x47aa03)[_0x39b9cb('0x7')](function(_0x25e3f0){return _0x25e3f0;});return null;};}function removeEntity(_0x341b54){return function(_0x167e26){const _0x12079a=a224_0x4df3;if(_0x167e26)return _0x167e26[_0x12079a('0xc')]()[_0x12079a('0x7')](function(){const _0x256746=_0x12079a;_0x341b54[_0x256746('0x2')](0xcc)['end']();});};}function handleEntityNotFound(_0x26ca26){return function(_0x3a87b7){const _0x105d9b=a224_0x4df3;return!_0x3a87b7&&_0x26ca26[_0x105d9b('0xe')](0x194),_0x3a87b7;};}function handleError(_0x18397b,_0x13e480){return _0x13e480=_0x13e480||0x1f4,function(_0x263982){const _0x380674=a224_0x4df3;logger[_0x380674('0x22')](_0x263982['stack']),_0x263982[_0x380674('0x18')]&&delete _0x263982['name'],_0x18397b[_0x380674('0x2')](_0x13e480)[_0x380674('0x5')](_0x263982);};}exports[_0x5382a6('0x27')]=function(_0x3c272a,_0x357f8){const _0xfe2897=_0x5382a6;let _0x5889c2={};const _0x4ac6fd={},_0x2d4cc4={'count':0x0,'rows':[]},_0x54962c=_[_0xfe2897('0x1b')](db[_0xfe2897('0x2c')][_0xfe2897('0x28')],function(_0x3db573){const _0xec77f8=_0xfe2897;return{'name':_0x3db573['fieldName'],'type':_0x3db573[_0xec77f8('0x3')][_0xec77f8('0x1e')]};});_0x4ac6fd[_0xfe2897('0xb')]=_[_0xfe2897('0x1b')](_0x54962c,_0xfe2897('0x18')),_0x4ac6fd[_0xfe2897('0x4')]=_[_0xfe2897('0x1a')](_0x3c272a[_0xfe2897('0x4')]),_0x4ac6fd[_0xfe2897('0x17')]=_[_0xfe2897('0x25')](_0x4ac6fd[_0xfe2897('0xb')],_0x4ac6fd[_0xfe2897('0x4')]),_0x5889c2[_0xfe2897('0x13')]=_['intersection'](_0x4ac6fd[_0xfe2897('0xb')],qs[_0xfe2897('0x23')](_0x3c272a[_0xfe2897('0x4')]['fields'])),_0x5889c2[_0xfe2897('0x13')]=_0x5889c2[_0xfe2897('0x13')][_0xfe2897('0x12')]?_0x5889c2[_0xfe2897('0x13')]:_0x4ac6fd[_0xfe2897('0xb')];typeof _0x3c272a[_0xfe2897('0x4')][_0xfe2897('0x2f')]===_0xfe2897('0xf')&&(_0x5889c2[_0xfe2897('0x19')]=qs['limit'](_0x3c272a[_0xfe2897('0x4')][_0xfe2897('0x19')]),_0x5889c2[_0xfe2897('0x8')]=qs[_0xfe2897('0x8')](_0x3c272a[_0xfe2897('0x4')]['offset']));_0x5889c2[_0xfe2897('0x2a')]=qs['sort'](_0x3c272a['query'][_0xfe2897('0x0')]),_0x5889c2[_0xfe2897('0x30')]=qs[_0xfe2897('0x17')](_[_0xfe2897('0xa')](_0x3c272a[_0xfe2897('0x4')],_0x4ac6fd[_0xfe2897('0x17')]),_0x54962c);_0x3c272a[_0xfe2897('0x4')][_0xfe2897('0x1f')]&&(_0x5889c2['where']=_['merge'](_0x5889c2[_0xfe2897('0x30')],{[Op['or']]:_['map'](_0x54962c,function(_0x440628){const _0x157a2e=_0xfe2897;if(_0x440628['type']!==_0x157a2e('0x10')){const _0x55caba={};return _0x55caba[_0x440628['name']]={[Op[_0x157a2e('0x32')]]:'%'+_0x3c272a['query'][_0x157a2e('0x1f')]+'%'},_0x55caba;}})}));_0x5889c2=_[_0xfe2897('0x1')]({},_0x5889c2,_0x3c272a['options']);const _0x3e4eae={'where':_0x5889c2[_0xfe2897('0x30')]};return db[_0xfe2897('0x2c')]['count'](_0x3e4eae)[_0xfe2897('0x7')](function(_0x2fbb8c){const _0x545830=_0xfe2897;return _0x2d4cc4['count']=_0x2fbb8c,_0x3c272a[_0x545830('0x4')]['includeAll']&&(_0x5889c2[_0x545830('0x15')]=[{'all':!![]}]),db[_0x545830('0x2c')]['findAll'](_0x5889c2);})['then'](function(_0x366370){const _0x5f4c5f=_0xfe2897;return _0x2d4cc4[_0x5f4c5f('0x20')]=_0x366370,_0x2d4cc4;})[_0xfe2897('0x7')](respondWithFilteredResult(_0x357f8,_0x5889c2))['catch'](handleError(_0x357f8,null));},exports['show']=function(_0x1ffab7,_0x1a4c06){const _0xe18ebb=_0x5382a6;let _0x2a5453={'raw':!![],'where':{'id':_0x1ffab7['params']['id']}};const _0x410cc7={};return _0x410cc7['model']=_['keys'](db[_0xe18ebb('0x2c')][_0xe18ebb('0x28')]),_0x410cc7['query']=_[_0xe18ebb('0x1a')](_0x1ffab7[_0xe18ebb('0x4')]),_0x410cc7[_0xe18ebb('0x17')]=_[_0xe18ebb('0x25')](_0x410cc7[_0xe18ebb('0xb')],_0x410cc7['query']),_0x2a5453[_0xe18ebb('0x13')]=_[_0xe18ebb('0x25')](_0x410cc7[_0xe18ebb('0xb')],qs[_0xe18ebb('0x23')](_0x1ffab7['query'][_0xe18ebb('0x23')])),_0x2a5453['attributes']=_0x2a5453[_0xe18ebb('0x13')]['length']?_0x2a5453[_0xe18ebb('0x13')]:_0x410cc7[_0xe18ebb('0xb')],_0x1ffab7[_0xe18ebb('0x4')]['includeAll']&&(_0x2a5453[_0xe18ebb('0x15')]=[{'all':!![]}]),_0x2a5453=_[_0xe18ebb('0x1')]({},_0x2a5453,_0x1ffab7['options']),db[_0xe18ebb('0x2c')][_0xe18ebb('0xd')](_0x2a5453)[_0xe18ebb('0x7')](handleEntityNotFound(_0x1a4c06,null))[_0xe18ebb('0x7')](respondWithResult(_0x1a4c06,null))['catch'](handleError(_0x1a4c06,null));},exports[_0x5382a6('0x2d')]=function(_0x4274c0,_0x57a7ad){const _0x337ddc=_0x5382a6;return db[_0x337ddc('0x2c')][_0x337ddc('0x2d')](_0x4274c0[_0x337ddc('0x2e')],{})[_0x337ddc('0x7')](respondWithResult(_0x57a7ad,0xc9))[_0x337ddc('0x21')](handleError(_0x57a7ad,null));},exports[_0x5382a6('0x24')]=function(_0x5c3f19,_0x485e3b){const _0x27e72b=_0x5382a6;return _0x5c3f19[_0x27e72b('0x2e')]['id']&&delete _0x5c3f19[_0x27e72b('0x2e')]['id'],db[_0x27e72b('0x2c')][_0x27e72b('0xd')]({'where':{'id':_0x5c3f19[_0x27e72b('0x9')]['id']}})[_0x27e72b('0x7')](handleEntityNotFound(_0x485e3b,null))[_0x27e72b('0x7')](saveUpdates(_0x5c3f19[_0x27e72b('0x2e')],null))['then'](respondWithResult(_0x485e3b,null))[_0x27e72b('0x21')](handleError(_0x485e3b,null));},exports[_0x5382a6('0xc')]=function(_0x518ac0,_0x2a3ea2){const _0x2a3ba3=_0x5382a6;return db[_0x2a3ba3('0x2c')][_0x2a3ba3('0xd')]({'where':{'id':_0x518ac0[_0x2a3ba3('0x9')]['id']}})[_0x2a3ba3('0x7')](handleEntityNotFound(_0x2a3ea2,null))[_0x2a3ba3('0x7')](removeEntity(_0x2a3ea2,null))[_0x2a3ba3('0x21')](handleError(_0x2a3ea2,null));},exports[_0x5382a6('0x31')]=function(_0x13eb4d,_0x2787e1){const _0x525821=_0x5382a6;return db[_0x525821('0x2c')][_0x525821('0x31')]()['then'](respondWithResult(_0x2787e1,null))[_0x525821('0x21')](handleError(_0x2787e1,null));}; \ No newline at end of file diff --git a/server/api/faxTransferReport/faxTransferReport.model.js b/server/api/faxTransferReport/faxTransferReport.model.js index f8fe180..5313dcb 100644 --- a/server/api/faxTransferReport/faxTransferReport.model.js +++ b/server/api/faxTransferReport/faxTransferReport.model.js @@ -1 +1 @@ -const a225_0x188d=['FaxTransferReport','uniqueid','./faxTransferReport.attributes','report_fax_transfer'];(function(_0x39af6a,_0x188d58){const _0x4ab0ae=function(_0xbcfa82){while(--_0xbcfa82){_0x39af6a['push'](_0x39af6a['shift']());}};_0x4ab0ae(++_0x188d58);}(a225_0x188d,0xfe));const a225_0x4ab0=function(_0x39af6a,_0x188d58){_0x39af6a=_0x39af6a-0x0;let _0x4ab0ae=a225_0x188d[_0x39af6a];return _0x4ab0ae;};const _0x5790aa=a225_0x4ab0;'use strict';const attributes=require(_0x5790aa('0x0'));module['exports']=function(_0xbcfa82){const _0x23f5fd=_0x5790aa,_0x449fb3=_0xbcfa82['define'](_0x23f5fd('0x2'),attributes,{'tableName':_0x23f5fd('0x1'),'paranoid':![],'indexes':[{'name':_0x23f5fd('0x3'),'fields':[_0x23f5fd('0x3')]}],'timestamps':!![]});return _0x449fb3;}; \ No newline at end of file +const a225_0xa3fb=['report_fax_transfer','FaxTransferReport','uniqueid','./faxTransferReport.attributes','exports','define'];(function(_0x5d45ed,_0xa3fb35){const _0x2cd751=function(_0x3874e6){while(--_0x3874e6){_0x5d45ed['push'](_0x5d45ed['shift']());}};_0x2cd751(++_0xa3fb35);}(a225_0xa3fb,0x1cc));const a225_0x2cd7=function(_0x5d45ed,_0xa3fb35){_0x5d45ed=_0x5d45ed-0x0;let _0x2cd751=a225_0xa3fb[_0x5d45ed];return _0x2cd751;};const _0x206ee7=a225_0x2cd7;'use strict';const attributes=require(_0x206ee7('0x5'));module[_0x206ee7('0x0')]=function(_0x3874e6){const _0x3276e9=_0x206ee7,_0x25168e=_0x3874e6[_0x3276e9('0x1')](_0x3276e9('0x3'),attributes,{'tableName':_0x3276e9('0x2'),'paranoid':![],'indexes':[{'name':_0x3276e9('0x4'),'fields':[_0x3276e9('0x4')]}],'timestamps':!![]});return _0x25168e;}; \ No newline at end of file diff --git a/server/api/faxTransferReport/index.js b/server/api/faxTransferReport/index.js index c562e77..139bff8 100644 --- a/server/api/faxTransferReport/index.js +++ b/server/api/faxTransferReport/index.js @@ -1 +1 @@ -const a226_0x1f64=['../../components/auth/service','exports','post','./faxTransferReport.controller','express','describe','show','destroy','get','delete','/:id','isAuthenticated','index'];(function(_0x2eec14,_0x1f6419){const _0x4d2728=function(_0x9cbf43){while(--_0x9cbf43){_0x2eec14['push'](_0x2eec14['shift']());}};_0x4d2728(++_0x1f6419);}(a226_0x1f64,0x1c1));const a226_0x4d27=function(_0x2eec14,_0x1f6419){_0x2eec14=_0x2eec14-0x0;let _0x4d2728=a226_0x1f64[_0x2eec14];return _0x4d2728;};const _0x187639=a226_0x4d27;'use strict';const express=require(_0x187639('0xa')),router=express['Router'](),auth=require(_0x187639('0x6')),controller=require(_0x187639('0x9'));router[_0x187639('0x1')]('/',auth[_0x187639('0x4')](),controller[_0x187639('0x5')]),router[_0x187639('0x1')]('/describe',auth[_0x187639('0x4')](),controller[_0x187639('0xb')]),router[_0x187639('0x1')]('/:id',auth[_0x187639('0x4')](),controller[_0x187639('0xc')]),router[_0x187639('0x8')]('/',auth[_0x187639('0x4')](),controller['create']),router['put'](_0x187639('0x3'),auth['isAuthenticated'](),controller['update']),router[_0x187639('0x2')](_0x187639('0x3'),auth[_0x187639('0x4')](),controller[_0x187639('0x0')]),module[_0x187639('0x7')]=router; \ No newline at end of file +const a226_0x4171=['isAuthenticated','/:id','exports','./faxTransferReport.controller','post','describe','destroy','get','index','express','../../components/auth/service','delete','show','put','create'];(function(_0x70efe2,_0x417196){const _0x35abc0=function(_0xca0a22){while(--_0xca0a22){_0x70efe2['push'](_0x70efe2['shift']());}};_0x35abc0(++_0x417196);}(a226_0x4171,0xfa));const a226_0x35ab=function(_0x70efe2,_0x417196){_0x70efe2=_0x70efe2-0x0;let _0x35abc0=a226_0x4171[_0x70efe2];return _0x35abc0;};const _0x1fc7da=a226_0x35ab;'use strict';const express=require(_0x1fc7da('0xe')),router=express['Router'](),auth=require(_0x1fc7da('0x0')),controller=require(_0x1fc7da('0x8'));router[_0x1fc7da('0xc')]('/',auth[_0x1fc7da('0x5')](),controller[_0x1fc7da('0xd')]),router[_0x1fc7da('0xc')]('/describe',auth[_0x1fc7da('0x5')](),controller[_0x1fc7da('0xa')]),router[_0x1fc7da('0xc')](_0x1fc7da('0x6'),auth['isAuthenticated'](),controller[_0x1fc7da('0x2')]),router[_0x1fc7da('0x9')]('/',auth['isAuthenticated'](),controller[_0x1fc7da('0x4')]),router[_0x1fc7da('0x3')](_0x1fc7da('0x6'),auth['isAuthenticated'](),controller['update']),router[_0x1fc7da('0x1')](_0x1fc7da('0x6'),auth[_0x1fc7da('0x5')](),controller[_0x1fc7da('0xb')]),module[_0x1fc7da('0x7')]=router; \ No newline at end of file diff --git a/server/api/intDeskAccount/index.js b/server/api/intDeskAccount/index.js index c4f49ef..1d0e808 100644 --- a/server/api/intDeskAccount/index.js +++ b/server/api/intDeskAccount/index.js @@ -1 +1 @@ -const a227_0x3961=['destroy','delete','/:id/configurations','../../components/auth/service','getConfigurations','Router','/:id/fields','create','put','addConfiguration','index','isAuthenticated','./intDeskAccount.controller','get','post','/:id','update'];(function(_0x42dbd0,_0x3961f8){const _0x4d1e8d=function(_0x5a18c8){while(--_0x5a18c8){_0x42dbd0['push'](_0x42dbd0['shift']());}};_0x4d1e8d(++_0x3961f8);}(a227_0x3961,0x93));const a227_0x4d1e=function(_0x42dbd0,_0x3961f8){_0x42dbd0=_0x42dbd0-0x0;let _0x4d1e8d=a227_0x3961[_0x42dbd0];return _0x4d1e8d;};const _0x462047=a227_0x4d1e;'use strict';const express=require('express'),router=express[_0x462047('0xb')](),auth=require(_0x462047('0x9')),controller=require(_0x462047('0x1'));router['get']('/',auth[_0x462047('0x0')](),controller[_0x462047('0x10')]),router['get'](_0x462047('0x4'),auth['isAuthenticated'](),controller['show']),router['get'](_0x462047('0x8'),auth[_0x462047('0x0')](),controller[_0x462047('0xa')]),router[_0x462047('0x2')](_0x462047('0xc'),auth[_0x462047('0x0')](),controller['getFields']),router[_0x462047('0x3')]('/',auth[_0x462047('0x0')](),controller[_0x462047('0xd')]),router['post'](_0x462047('0x8'),auth['isAuthenticated'](),controller[_0x462047('0xf')]),router[_0x462047('0xe')](_0x462047('0x4'),auth['isAuthenticated'](),controller[_0x462047('0x5')]),router[_0x462047('0x7')]('/:id',auth[_0x462047('0x0')](),controller[_0x462047('0x6')]),module['exports']=router; \ No newline at end of file +const a227_0x11c9=['./intDeskAccount.controller','addConfiguration','/:id/configurations','isAuthenticated','/:id/fields','get','create','destroy','Router','delete','exports','show','/:id','put','../../components/auth/service','getConfigurations','post'];(function(_0x1390e1,_0x11c95c){const _0x4c9bdf=function(_0x548b18){while(--_0x548b18){_0x1390e1['push'](_0x1390e1['shift']());}};_0x4c9bdf(++_0x11c95c);}(a227_0x11c9,0x124));const a227_0x4c9b=function(_0x1390e1,_0x11c95c){_0x1390e1=_0x1390e1-0x0;let _0x4c9bdf=a227_0x11c9[_0x1390e1];return _0x4c9bdf;};const _0x3db172=a227_0x4c9b;'use strict';const express=require('express'),router=express[_0x3db172('0x5')](),auth=require(_0x3db172('0xb')),controller=require(_0x3db172('0xe'));router[_0x3db172('0x2')]('/',auth[_0x3db172('0x0')](),controller['index']),router[_0x3db172('0x2')](_0x3db172('0x9'),auth[_0x3db172('0x0')](),controller[_0x3db172('0x8')]),router[_0x3db172('0x2')](_0x3db172('0x10'),auth[_0x3db172('0x0')](),controller[_0x3db172('0xc')]),router[_0x3db172('0x2')](_0x3db172('0x1'),auth['isAuthenticated'](),controller['getFields']),router[_0x3db172('0xd')]('/',auth[_0x3db172('0x0')](),controller[_0x3db172('0x3')]),router[_0x3db172('0xd')]('/:id/configurations',auth['isAuthenticated'](),controller[_0x3db172('0xf')]),router[_0x3db172('0xa')](_0x3db172('0x9'),auth['isAuthenticated'](),controller['update']),router[_0x3db172('0x6')](_0x3db172('0x9'),auth[_0x3db172('0x0')](),controller[_0x3db172('0x4')]),module[_0x3db172('0x7')]=router; \ No newline at end of file diff --git a/server/api/intDeskAccount/intDeskAccount.attributes.js b/server/api/intDeskAccount/intDeskAccount.attributes.js index 6799873..63c4566 100644 --- a/server/api/intDeskAccount/intDeskAccount.attributes.js +++ b/server/api/intDeskAccount/intDeskAccount.attributes.js @@ -1 +1 @@ -const a228_0x89ac=['ENUM','exports','basic','integrationTab','STRING','sequelize'];(function(_0x24d327,_0x89acb0){const _0x11e796=function(_0x226f6e){while(--_0x226f6e){_0x24d327['push'](_0x24d327['shift']());}};_0x11e796(++_0x89acb0);}(a228_0x89ac,0x16d));const a228_0x11e7=function(_0x24d327,_0x89acb0){_0x24d327=_0x24d327-0x0;let _0x11e796=a228_0x89ac[_0x24d327];return _0x11e796;};const _0x285c6b=a228_0x11e7;'use strict';const Sequelize=require(_0x285c6b('0x0'));module[_0x285c6b('0x2')]={'name':{'type':Sequelize[_0x285c6b('0x5')]},'description':{'type':Sequelize[_0x285c6b('0x5')]},'username':{'type':Sequelize[_0x285c6b('0x5')]},'remoteUri':{'type':Sequelize['STRING']},'authType':{'type':Sequelize[_0x285c6b('0x1')]('basic'),'defaultValue':_0x285c6b('0x3')},'password':{'type':Sequelize[_0x285c6b('0x5')]},'consumerKey':{'type':Sequelize['STRING']},'consumerSecret':{'type':Sequelize['STRING']},'token':{'type':Sequelize[_0x285c6b('0x5')]},'tokenSecret':{'type':Sequelize[_0x285c6b('0x5')]},'serverUrl':{'type':Sequelize[_0x285c6b('0x5')]},'type':{'type':Sequelize['ENUM'](_0x285c6b('0x4'),'newTab'),'defaultValue':_0x285c6b('0x4')}}; \ No newline at end of file +const a228_0x2b2e=['STRING','basic','exports','newTab','ENUM','integrationTab'];(function(_0x3afbde,_0x2b2ebd){const _0x4553b1=function(_0x5ebe8e){while(--_0x5ebe8e){_0x3afbde['push'](_0x3afbde['shift']());}};_0x4553b1(++_0x2b2ebd);}(a228_0x2b2e,0x1d9));const a228_0x4553=function(_0x3afbde,_0x2b2ebd){_0x3afbde=_0x3afbde-0x0;let _0x4553b1=a228_0x2b2e[_0x3afbde];return _0x4553b1;};const _0x4e3679=a228_0x4553;'use strict';const Sequelize=require('sequelize');module[_0x4e3679('0x3')]={'name':{'type':Sequelize[_0x4e3679('0x1')]},'description':{'type':Sequelize[_0x4e3679('0x1')]},'username':{'type':Sequelize[_0x4e3679('0x1')]},'remoteUri':{'type':Sequelize[_0x4e3679('0x1')]},'authType':{'type':Sequelize[_0x4e3679('0x5')](_0x4e3679('0x2')),'defaultValue':_0x4e3679('0x2')},'password':{'type':Sequelize[_0x4e3679('0x1')]},'consumerKey':{'type':Sequelize[_0x4e3679('0x1')]},'consumerSecret':{'type':Sequelize['STRING']},'token':{'type':Sequelize[_0x4e3679('0x1')]},'tokenSecret':{'type':Sequelize[_0x4e3679('0x1')]},'serverUrl':{'type':Sequelize[_0x4e3679('0x1')]},'type':{'type':Sequelize[_0x4e3679('0x5')]('integrationTab',_0x4e3679('0x4')),'defaultValue':_0x4e3679('0x0')}}; \ No newline at end of file diff --git a/server/api/intDeskAccount/intDeskAccount.controller.js b/server/api/intDeskAccount/intDeskAccount.controller.js index 5c2c687..1dcfc4a 100644 --- a/server/api/intDeskAccount/intDeskAccount.controller.js +++ b/server/api/intDeskAccount/intDeskAccount.controller.js @@ -1 +1 @@ -const a229_0x519f=['query','status','sort','order','then','undefined','toString','like','params','index','addConfiguration','model','entries','substring','filters','api','getDescriptions','sequelize','AccountId','priority','findAll','GET','fieldName','fields','getFields','include','set','lastIndexOf','DeskAccount','error','keys','basic','stack','slice','concat','consumerSecret','count','show','sendStatus','update','nolimit','options','offset','base64','headers','../../components/integrations/configuration','intersection','name','username','_embedded','channel','end','catch','type','statusCode','request-promise-native','Wrong\x20credentials','send','rows','filter','map','merge','Descriptions','length','Basic\x20%s','token','includeAll','label','create','DeskField','stringify','limit','Authorization','destroy','pick','../../config/logger','from','authType','Subjects','test','format','body','password','DeskConfiguration','remoteUri','where','rawAttributes','getConfigurations','findOne','application/json','attributes'];(function(_0x2b1189,_0x519f0d){const _0x3221cd=function(_0x3596bb){while(--_0x3596bb){_0x2b1189['push'](_0x2b1189['shift']());}};_0x3221cd(++_0x519f0d);}(a229_0x519f,0x146));const a229_0x3221=function(_0x2b1189,_0x519f0d){_0x2b1189=_0x2b1189-0x0;let _0x3221cd=a229_0x519f[_0x2b1189];return _0x3221cd;};const _0x58fe65=a229_0x3221;'use strict';const rp=require(_0x58fe65('0x2')),util=require('util'),_=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x58fe65('0x16'))(_0x58fe65('0x35')),db=require('../../mysqldb')['db'],{Op}=require(_0x58fe65('0x37')),integrations=require(_0x58fe65('0x53'));function respondWithResult(_0x3596bb,_0x1034e6){return _0x1034e6=_0x1034e6||0xc8,function(_0x2cd131){if(_0x2cd131)return _0x3596bb['status'](_0x1034e6)['json'](_0x2cd131);};}function respondWithFilteredResult(_0x505702,_0x44c5d3){return function(_0x2bcd3a){const _0x59f54f=a229_0x3221;if(_0x2bcd3a){const _0x928b44=_0x2bcd3a[_0x59f54f('0x4a')],_0x2c47d7=_0x44c5d3[_0x59f54f('0x50')];let _0x45d29e=_0x44c5d3[_0x59f54f('0x50')]+_0x44c5d3[_0x59f54f('0x12')],_0x374aa8;return _0x45d29e>=_0x928b44?(_0x45d29e=_0x928b44,_0x374aa8=0xc8):_0x374aa8=0xce,_0x505702['status'](_0x374aa8),_0x505702[_0x59f54f('0x40')]('Content-Range',_0x2c47d7+'-'+_0x45d29e+'/'+_0x928b44)['json'](_0x2bcd3a);}return null;};}function saveUpdates(_0xe1f6a8){return function(_0x147572){const _0x527338=a229_0x3221;if(_0x147572)return _0x147572[_0x527338('0x4d')](_0xe1f6a8)[_0x527338('0x2a')](function(_0x1d4ab3){return _0x1d4ab3;});return null;};}function removeEntity(_0x1fcb2a){return function(_0x45e36b){const _0x8b69ee=a229_0x3221;if(_0x45e36b)return _0x45e36b[_0x8b69ee('0x14')]()['then'](function(){const _0xd1e925=_0x8b69ee;_0x1fcb2a[_0xd1e925('0x27')](0xcc)[_0xd1e925('0x59')]();});};}function handleEntityNotFound(_0x3475fc){return function(_0x1f6e4e){const _0x24055a=a229_0x3221;return!_0x1f6e4e&&_0x3475fc[_0x24055a('0x4c')](0x194),_0x1f6e4e;};}function handleError(_0x5566d3,_0x120909){return _0x120909=_0x120909||0x1f4,function(_0x29ccf1){const _0x1a67fc=a229_0x3221;logger[_0x1a67fc('0x43')](_0x29ccf1[_0x1a67fc('0x46')]),_0x29ccf1['name']&&delete _0x29ccf1[_0x1a67fc('0x55')],_0x5566d3[_0x1a67fc('0x27')](_0x120909)['send'](_0x29ccf1);};}exports[_0x58fe65('0x2f')]=function(_0x156083,_0x3384fd){const _0x32b8e4=_0x58fe65;let _0x129c2f={};const _0x54bb92={},_0x4849a6={'count':0x0,'rows':[]},_0x323b7c=_[_0x32b8e4('0x7')](db[_0x32b8e4('0x42')][_0x32b8e4('0x21')],function(_0x5ef1e4){const _0x520f67=_0x32b8e4;return{'name':_0x5ef1e4[_0x520f67('0x3c')],'type':_0x5ef1e4[_0x520f67('0x0')]['key']};});_0x54bb92[_0x32b8e4('0x31')]=_[_0x32b8e4('0x7')](_0x323b7c,_0x32b8e4('0x55')),_0x54bb92['query']=_[_0x32b8e4('0x44')](_0x156083[_0x32b8e4('0x26')]),_0x54bb92[_0x32b8e4('0x34')]=_[_0x32b8e4('0x54')](_0x54bb92[_0x32b8e4('0x31')],_0x54bb92[_0x32b8e4('0x26')]),_0x129c2f[_0x32b8e4('0x25')]=_[_0x32b8e4('0x54')](_0x54bb92[_0x32b8e4('0x31')],qs[_0x32b8e4('0x3d')](_0x156083[_0x32b8e4('0x26')][_0x32b8e4('0x3d')])),_0x129c2f[_0x32b8e4('0x25')]=_0x129c2f[_0x32b8e4('0x25')][_0x32b8e4('0xa')]?_0x129c2f[_0x32b8e4('0x25')]:_0x54bb92['model'];typeof _0x156083[_0x32b8e4('0x26')][_0x32b8e4('0x4e')]==='undefined'&&(_0x129c2f['limit']=qs[_0x32b8e4('0x12')](_0x156083[_0x32b8e4('0x26')]['limit']),_0x129c2f[_0x32b8e4('0x50')]=qs[_0x32b8e4('0x50')](_0x156083['query'][_0x32b8e4('0x50')]));_0x129c2f['order']=qs[_0x32b8e4('0x28')](_0x156083[_0x32b8e4('0x26')][_0x32b8e4('0x28')]),_0x129c2f[_0x32b8e4('0x20')]=qs['filters'](_[_0x32b8e4('0x15')](_0x156083[_0x32b8e4('0x26')],_0x54bb92[_0x32b8e4('0x34')]),_0x323b7c);_0x156083[_0x32b8e4('0x26')][_0x32b8e4('0x6')]&&(_0x129c2f[_0x32b8e4('0x20')]=_[_0x32b8e4('0x8')](_0x129c2f[_0x32b8e4('0x20')],{[Op['or']]:_[_0x32b8e4('0x7')](_0x323b7c,function(_0xf9a446){const _0x1f8579=_0x32b8e4;if(_0xf9a446[_0x1f8579('0x0')]!=='VIRTUAL'){const _0x164de8={};return _0x164de8[_0xf9a446[_0x1f8579('0x55')]]={[Op[_0x1f8579('0x2d')]]:'%'+_0x156083[_0x1f8579('0x26')][_0x1f8579('0x6')]+'%'},_0x164de8;}})}));_0x129c2f=_['merge']({},_0x129c2f,_0x156083[_0x32b8e4('0x4f')]);const _0x263332={'where':_0x129c2f[_0x32b8e4('0x20')]};return db[_0x32b8e4('0x42')]['count'](_0x263332)[_0x32b8e4('0x2a')](function(_0x328d76){const _0x4e6221=_0x32b8e4;return _0x4849a6[_0x4e6221('0x4a')]=_0x328d76,_0x156083['query'][_0x4e6221('0xd')]&&(_0x129c2f['include']=[{'all':!![]}]),db[_0x4e6221('0x42')][_0x4e6221('0x3a')](_0x129c2f);})[_0x32b8e4('0x2a')](function(_0x3cf069){const _0x37f764=_0x32b8e4;return _0x4849a6[_0x37f764('0x5')]=_0x3cf069,_0x4849a6;})[_0x32b8e4('0x2a')](respondWithFilteredResult(_0x3384fd,_0x129c2f))['catch'](handleError(_0x3384fd,null));},exports[_0x58fe65('0x4b')]=function(_0x5d6cda,_0x2dc8b7){const _0x9413d5=_0x58fe65;let _0x57348f={'raw':![],'where':{'id':_0x5d6cda[_0x9413d5('0x2e')]['id']}};const _0x5eaddb={};return _0x5eaddb['model']=_[_0x9413d5('0x44')](db[_0x9413d5('0x42')][_0x9413d5('0x21')]),_0x5eaddb[_0x9413d5('0x26')]=_[_0x9413d5('0x44')](_0x5d6cda[_0x9413d5('0x26')]),_0x5eaddb[_0x9413d5('0x34')]=_[_0x9413d5('0x54')](_0x5eaddb[_0x9413d5('0x31')],_0x5eaddb[_0x9413d5('0x26')]),_0x57348f[_0x9413d5('0x25')]=_[_0x9413d5('0x54')](_0x5eaddb[_0x9413d5('0x31')],qs[_0x9413d5('0x3d')](_0x5d6cda[_0x9413d5('0x26')][_0x9413d5('0x3d')])),_0x57348f['attributes']=_0x57348f['attributes'][_0x9413d5('0xa')]?_0x57348f[_0x9413d5('0x25')]:_0x5eaddb[_0x9413d5('0x31')],_0x5d6cda[_0x9413d5('0x26')]['includeAll']&&(_0x57348f[_0x9413d5('0x3f')]=[{'all':!![]}]),_0x57348f=_[_0x9413d5('0x8')]({},_0x57348f,_0x5d6cda[_0x9413d5('0x4f')]),db[_0x9413d5('0x42')][_0x9413d5('0x23')](_0x57348f)[_0x9413d5('0x2a')](handleEntityNotFound(_0x2dc8b7,null))[_0x9413d5('0x2a')](respondWithResult(_0x2dc8b7,null))[_0x9413d5('0x5a')](handleError(_0x2dc8b7,null));},exports[_0x58fe65('0xf')]=function(_0x54d1ca,_0x5afe11){const _0x57e99e=_0x58fe65;return db['DeskAccount']['create'](_0x54d1ca[_0x57e99e('0x1c')],{})[_0x57e99e('0x2a')](respondWithResult(_0x5afe11,0xc9))['catch'](handleError(_0x5afe11,null));},exports[_0x58fe65('0x4d')]=function(_0x306876,_0x295fdd){const _0x38232c=_0x58fe65;return _0x306876[_0x38232c('0x1c')]['id']&&delete _0x306876[_0x38232c('0x1c')]['id'],db[_0x38232c('0x42')]['findOne']({'where':{'id':_0x306876[_0x38232c('0x2e')]['id']}})[_0x38232c('0x2a')](handleEntityNotFound(_0x295fdd,null))[_0x38232c('0x2a')](saveUpdates(_0x306876[_0x38232c('0x1c')],null))['then'](respondWithResult(_0x295fdd,null))['catch'](handleError(_0x295fdd,null));},exports['destroy']=function(_0x34e445,_0x4c1352){const _0x3afd68=_0x58fe65;return db['DeskAccount'][_0x3afd68('0x23')]({'where':{'id':_0x34e445[_0x3afd68('0x2e')]['id']}})['then'](handleEntityNotFound(_0x4c1352,null))[_0x3afd68('0x2a')](removeEntity(_0x4c1352,null))['catch'](handleError(_0x4c1352,null));},exports[_0x58fe65('0x22')]=function(_0x1c914e,_0x5f0b35){const _0x5c8be4=_0x58fe65;let _0x2c4097={};const _0x45f832={};let _0x4fdaed,_0x5e7388;return db[_0x5c8be4('0x42')][_0x5c8be4('0x23')]({'where':{'id':_0x1c914e[_0x5c8be4('0x2e')]['id']}})['then'](handleEntityNotFound(_0x5f0b35,null))[_0x5c8be4('0x2a')](function(_0x56472a){const _0x1d9255=_0x5c8be4;if(_0x56472a)return _0x4fdaed=_0x56472a,_0x45f832[_0x1d9255('0x31')]=_['keys'](db[_0x1d9255('0x1e')][_0x1d9255('0x21')]),_0x45f832[_0x1d9255('0x26')]=_['keys'](_0x1c914e[_0x1d9255('0x26')]),_0x45f832[_0x1d9255('0x34')]=_[_0x1d9255('0x54')](_0x45f832[_0x1d9255('0x31')],_0x45f832[_0x1d9255('0x26')]),_0x2c4097['attributes']=_[_0x1d9255('0x54')](_0x45f832[_0x1d9255('0x31')],qs[_0x1d9255('0x3d')](_0x1c914e[_0x1d9255('0x26')][_0x1d9255('0x3d')])),_0x2c4097[_0x1d9255('0x25')]=_0x2c4097[_0x1d9255('0x25')][_0x1d9255('0xa')]?_0x2c4097[_0x1d9255('0x25')]:_0x45f832[_0x1d9255('0x31')],_0x2c4097[_0x1d9255('0x29')]=qs[_0x1d9255('0x28')](_0x1c914e[_0x1d9255('0x26')][_0x1d9255('0x28')]),_0x2c4097[_0x1d9255('0x20')]=qs[_0x1d9255('0x34')](_['pick'](_0x1c914e[_0x1d9255('0x26')],_0x45f832[_0x1d9255('0x34')])),_0x1c914e['query'][_0x1d9255('0x6')]&&(_0x2c4097['where']=_[_0x1d9255('0x8')](_0x2c4097['where'],{[Op['or']]:_[_0x1d9255('0x7')](_0x2c4097[_0x1d9255('0x25')],function(_0x545aab){const _0xd026c=_0x1d9255,_0x34b5cd={};return _0x34b5cd[_0x545aab]={[Op['like']]:'%'+_0x1c914e[_0xd026c('0x26')][_0xd026c('0x6')]+'%'},_0x34b5cd;})})),_0x2c4097=_['merge']({},_0x2c4097,_0x1c914e[_0x1d9255('0x4f')]),_0x4fdaed[_0x1d9255('0x22')](_0x2c4097);})[_0x5c8be4('0x2a')](function(_0x53f730){const _0x1f840b=_0x5c8be4;if(_0x53f730)return _0x5e7388=_0x53f730['length'],typeof _0x1c914e[_0x1f840b('0x26')][_0x1f840b('0x4e')]===_0x1f840b('0x2b')&&(_0x2c4097[_0x1f840b('0x12')]=qs[_0x1f840b('0x12')](_0x1c914e[_0x1f840b('0x26')][_0x1f840b('0x12')]),_0x2c4097[_0x1f840b('0x50')]=qs[_0x1f840b('0x50')](_0x1c914e[_0x1f840b('0x26')]['offset'])),_0x4fdaed['getConfigurations'](_0x2c4097);})[_0x5c8be4('0x2a')](function(_0x32b962){if(_0x32b962)return _0x32b962?{'count':_0x5e7388,'rows':_0x32b962}:null;})[_0x5c8be4('0x2a')](respondWithResult(_0x5f0b35,null))[_0x5c8be4('0x5a')](handleError(_0x5f0b35,null));},exports[_0x58fe65('0x30')]=function(_0x17587a,_0x228a30){const _0x2f9d53=_0x58fe65;return _0x17587a['body']['id']&&delete _0x17587a[_0x2f9d53('0x1c')]['id'],db[_0x2f9d53('0x42')][_0x2f9d53('0x23')]({'where':{'id':_0x17587a['params']['id']}})['then'](handleEntityNotFound(_0x228a30,null))[_0x2f9d53('0x2a')](function(_0x2ff41b){const _0x564598=_0x2f9d53;if(_0x2ff41b)return _0x17587a[_0x564598('0x1c')][_0x564598('0x38')]=_0x2ff41b['id'],_0x17587a['body']['Subjects']=integrations['getSubjects'](_0x17587a[_0x564598('0x1c')][_0x564598('0x58')],_0x17587a[_0x564598('0x1c')][_0x564598('0x0')]),_0x17587a['body'][_0x564598('0x9')]=integrations[_0x564598('0x36')](_0x17587a[_0x564598('0x1c')][_0x564598('0x58')],_0x17587a[_0x564598('0x1c')][_0x564598('0x0')]),db[_0x564598('0x1e')][_0x564598('0xf')](_0x17587a[_0x564598('0x1c')],{'include':[{'model':db[_0x564598('0x10')],'as':_0x564598('0x19')},{'model':db['DeskField'],'as':_0x564598('0x9')}]});return null;})[_0x2f9d53('0x2a')](respondWithResult(_0x228a30,null))[_0x2f9d53('0x5a')](handleError(_0x228a30,null));},exports[_0x58fe65('0x3e')]=function(_0x233c6a,_0x1771b8){const _0x1bc184=_0x58fe65,_0x4f4a12=[{'name':_0x1bc184('0x39'),'label':_0x1bc184('0x39'),'custom':![],'options':[{'name':0x1,'value':0x1},{'name':0x2,'value':0x2},{'name':0x3,'value':0x3},{'name':0x4,'value':0x4},{'name':0x5,'value':0x5},{'name':0x6,'value':0x6},{'name':0x7,'value':0x7},{'name':0x8,'value':0x8},{'name':0x9,'value':0x9},{'name':0xa,'value':0xa}]}];let _0x555b01='';return db[_0x1bc184('0x42')][_0x1bc184('0x23')]({'where':{'id':_0x233c6a[_0x1bc184('0x2e')]['id']},'attributes':['id',_0x1bc184('0x1f'),_0x1bc184('0x18'),_0x1bc184('0x56'),_0x1bc184('0x1d'),'consumerKey',_0x1bc184('0x49'),_0x1bc184('0xc'),'tokenSecret']})['then'](handleEntityNotFound(_0x1771b8,null))[_0x1bc184('0x2a')](function(_0x82f882){const _0x11e343=_0x1bc184;if(_0x82f882){_0x555b01=_0x82f882[_0x11e343('0x1f')];const _0xd5173=_0x555b01[_0x11e343('0x47')](-0x1);_0xd5173==='/'&&(_0x555b01=_0x555b01[_0x11e343('0x33')](0x0,_0x555b01[_0x11e343('0x41')](_0xd5173)));const _0x1b6d51={'method':_0x11e343('0x3b'),'uri':util[_0x11e343('0x1b')]('%s/custom_fields',_0x555b01),'headers':{'Content-Type':_0x11e343('0x24'),'Accept':_0x11e343('0x24')},'json':!![]};return _0x82f882['authType']===_0x11e343('0x45')&&(_0x1b6d51[_0x11e343('0x52')][_0x11e343('0x13')]=util['format'](_0x11e343('0xb'),Buffer[_0x11e343('0x17')](util[_0x11e343('0x1b')]('%s:%s',_0x82f882[_0x11e343('0x56')],_0x82f882[_0x11e343('0x1d')]))[_0x11e343('0x2c')](_0x11e343('0x51')))),rp(_0x1b6d51)[_0x11e343('0x2a')](function(_0x1bbf3e){const _0x5e85b1=_0x11e343;return _0x4f4a12[_0x5e85b1('0x48')](_[_0x5e85b1('0x7')](_0x1bbf3e[_0x5e85b1('0x57')][_0x5e85b1('0x32')],function(_0x4bafe3){const _0x1073be=_0x5e85b1;return{'id':_0x4bafe3[_0x1073be('0x55')],'name':_0x4bafe3['name'],'type':_0x4bafe3[_0x1073be('0x0')],'active':_0x4bafe3['active'],'label':_0x4bafe3[_0x1073be('0xe')],'custom':!![]};}));});}})['then'](function(_0x2c8169){const _0x387584=_0x1bc184;return{'count':_0x2c8169[_0x387584('0xa')],'rows':_0x2c8169};})[_0x1bc184('0x2a')](respondWithResult(_0x1771b8,null))['catch'](function(_0x4937e6){const _0x2ee499=_0x1bc184;let _0x327cf4=_0x233c6a[_0x2ee499('0x26')]['test']?0x1f4:_0x4937e6[_0x2ee499('0x1')]||0x1f4;logger[_0x2ee499('0x43')]('getFields,\x20%s,\x20%s,\x20%s',_0x2ee499('0x3e'),_0x327cf4,JSON[_0x2ee499('0x11')](_0x4937e6)),delete _0x4937e6[_0x2ee499('0x55')],_0x327cf4===0x191&&(_0x327cf4=0x190),_0x1771b8[_0x2ee499('0x27')](_0x327cf4)[_0x2ee499('0x4')](_0x233c6a['query'][_0x2ee499('0x1a')]?{'message':_0x2ee499('0x3'),'statusCode':_0x4937e6['statusCode']}:_0x4937e6);});}; \ No newline at end of file +const a229_0x1287=['getSubjects','attributes','priority','request-promise-native','body','Basic\x20%s','nolimit','api','DeskField','basic','index','end','findOne','status','test','filter','intersection','%s:%s','where','show','toString','addConfiguration','update','channel','limit','../../mysqldb','filters','rows','DeskConfiguration','getConfigurations','format','getFields,\x20%s,\x20%s,\x20%s','length','sort','count','map','../../components/parsers/qs','include','remoteUri','name','options','includeAll','consumerKey','error','sendStatus','offset','slice','json','fieldName','from','password','Subjects','model','Descriptions','rawAttributes','DeskAccount','entries','tokenSecret','undefined','label','params','VIRTUAL','%s/custom_fields','query','consumerSecret','then','lastIndexOf','type','application/json','pick','send','keys','merge','create','catch','like','fields','stringify','statusCode','concat','lodash','destroy','../../config/logger','util','order','getFields','_embedded'];(function(_0x101e4c,_0x128779){const _0x39232b=function(_0x2acf5c){while(--_0x2acf5c){_0x101e4c['push'](_0x101e4c['shift']());}};_0x39232b(++_0x128779);}(a229_0x1287,0xb0));const a229_0x3923=function(_0x101e4c,_0x128779){_0x101e4c=_0x101e4c-0x0;let _0x39232b=a229_0x1287[_0x101e4c];return _0x39232b;};const _0x3efdc6=a229_0x3923;'use strict';const rp=require(_0x3efdc6('0x1')),util=require(_0x3efdc6('0x51')),_=require(_0x3efdc6('0x4e')),qs=require(_0x3efdc6('0x22')),logger=require(_0x3efdc6('0x50'))(_0x3efdc6('0x5')),db=require(_0x3efdc6('0x17'))['db'],{Op}=require('sequelize'),integrations=require('../../components/integrations/configuration');function respondWithResult(_0x2acf5c,_0x433aaf){return _0x433aaf=_0x433aaf||0xc8,function(_0x2e1f29){const _0x1ea9ff=a229_0x3923;if(_0x2e1f29)return _0x2acf5c[_0x1ea9ff('0xb')](_0x433aaf)[_0x1ea9ff('0x2d')](_0x2e1f29);};}function respondWithFilteredResult(_0x2c88de,_0x5921d4){return function(_0x54a200){const _0x180f7c=a229_0x3923;if(_0x54a200){const _0x34a3b6=_0x54a200['count'],_0x29e9b6=_0x5921d4[_0x180f7c('0x2b')];let _0x5e61cc=_0x5921d4[_0x180f7c('0x2b')]+_0x5921d4['limit'],_0x2322b9;return _0x5e61cc>=_0x34a3b6?(_0x5e61cc=_0x34a3b6,_0x2322b9=0xc8):_0x2322b9=0xce,_0x2c88de[_0x180f7c('0xb')](_0x2322b9),_0x2c88de['set']('Content-Range',_0x29e9b6+'-'+_0x5e61cc+'/'+_0x34a3b6)[_0x180f7c('0x2d')](_0x54a200);}return null;};}function saveUpdates(_0x33a783){return function(_0x66aaf7){const _0x5f3d1e=a229_0x3923;if(_0x66aaf7)return _0x66aaf7[_0x5f3d1e('0x14')](_0x33a783)[_0x5f3d1e('0x3f')](function(_0x5eb1b4){return _0x5eb1b4;});return null;};}function removeEntity(_0x3374e4){return function(_0x2d14bf){const _0x2b4bb0=a229_0x3923;if(_0x2d14bf)return _0x2d14bf[_0x2b4bb0('0x4f')]()['then'](function(){const _0x59a8aa=_0x2b4bb0;_0x3374e4[_0x59a8aa('0xb')](0xcc)[_0x59a8aa('0x9')]();});};}function handleEntityNotFound(_0x468063){return function(_0x4d22f1){const _0x5b90db=a229_0x3923;return!_0x4d22f1&&_0x468063[_0x5b90db('0x2a')](0x194),_0x4d22f1;};}function handleError(_0x27a226,_0x4380cf){return _0x4380cf=_0x4380cf||0x1f4,function(_0x2b7140){const _0x2cc5bd=a229_0x3923;logger[_0x2cc5bd('0x29')](_0x2b7140['stack']),_0x2b7140[_0x2cc5bd('0x25')]&&delete _0x2b7140['name'],_0x27a226['status'](_0x4380cf)[_0x2cc5bd('0x44')](_0x2b7140);};}exports[_0x3efdc6('0x8')]=function(_0x356b0b,_0x2813e8){const _0x4e2ecd=_0x3efdc6;let _0x4c1932={};const _0x26e1cc={},_0x2a66c8={'count':0x0,'rows':[]},_0x1ebf15=_[_0x4e2ecd('0x21')](db[_0x4e2ecd('0x35')][_0x4e2ecd('0x34')],function(_0x28c669){const _0x594105=_0x4e2ecd;return{'name':_0x28c669[_0x594105('0x2e')],'type':_0x28c669[_0x594105('0x41')]['key']};});_0x26e1cc['model']=_[_0x4e2ecd('0x21')](_0x1ebf15,_0x4e2ecd('0x25')),_0x26e1cc[_0x4e2ecd('0x3d')]=_['keys'](_0x356b0b[_0x4e2ecd('0x3d')]),_0x26e1cc['filters']=_['intersection'](_0x26e1cc[_0x4e2ecd('0x32')],_0x26e1cc[_0x4e2ecd('0x3d')]),_0x4c1932[_0x4e2ecd('0x56')]=_[_0x4e2ecd('0xe')](_0x26e1cc[_0x4e2ecd('0x32')],qs[_0x4e2ecd('0x4a')](_0x356b0b['query'][_0x4e2ecd('0x4a')])),_0x4c1932[_0x4e2ecd('0x56')]=_0x4c1932['attributes'][_0x4e2ecd('0x1e')]?_0x4c1932['attributes']:_0x26e1cc['model'];typeof _0x356b0b[_0x4e2ecd('0x3d')][_0x4e2ecd('0x4')]===_0x4e2ecd('0x38')&&(_0x4c1932[_0x4e2ecd('0x16')]=qs[_0x4e2ecd('0x16')](_0x356b0b[_0x4e2ecd('0x3d')]['limit']),_0x4c1932['offset']=qs[_0x4e2ecd('0x2b')](_0x356b0b[_0x4e2ecd('0x3d')][_0x4e2ecd('0x2b')]));_0x4c1932[_0x4e2ecd('0x52')]=qs[_0x4e2ecd('0x1f')](_0x356b0b[_0x4e2ecd('0x3d')][_0x4e2ecd('0x1f')]),_0x4c1932[_0x4e2ecd('0x10')]=qs[_0x4e2ecd('0x18')](_['pick'](_0x356b0b[_0x4e2ecd('0x3d')],_0x26e1cc[_0x4e2ecd('0x18')]),_0x1ebf15);_0x356b0b[_0x4e2ecd('0x3d')][_0x4e2ecd('0xd')]&&(_0x4c1932[_0x4e2ecd('0x10')]=_[_0x4e2ecd('0x46')](_0x4c1932[_0x4e2ecd('0x10')],{[Op['or']]:_[_0x4e2ecd('0x21')](_0x1ebf15,function(_0x41641d){const _0x3e5db1=_0x4e2ecd;if(_0x41641d['type']!==_0x3e5db1('0x3b')){const _0x395534={};return _0x395534[_0x41641d[_0x3e5db1('0x25')]]={[Op['like']]:'%'+_0x356b0b[_0x3e5db1('0x3d')]['filter']+'%'},_0x395534;}})}));_0x4c1932=_[_0x4e2ecd('0x46')]({},_0x4c1932,_0x356b0b[_0x4e2ecd('0x26')]);const _0x2d608f={'where':_0x4c1932[_0x4e2ecd('0x10')]};return db[_0x4e2ecd('0x35')][_0x4e2ecd('0x20')](_0x2d608f)[_0x4e2ecd('0x3f')](function(_0x4e78dc){const _0x319834=_0x4e2ecd;return _0x2a66c8[_0x319834('0x20')]=_0x4e78dc,_0x356b0b['query'][_0x319834('0x27')]&&(_0x4c1932[_0x319834('0x23')]=[{'all':!![]}]),db[_0x319834('0x35')]['findAll'](_0x4c1932);})[_0x4e2ecd('0x3f')](function(_0x3673b0){const _0x1654e8=_0x4e2ecd;return _0x2a66c8[_0x1654e8('0x19')]=_0x3673b0,_0x2a66c8;})[_0x4e2ecd('0x3f')](respondWithFilteredResult(_0x2813e8,_0x4c1932))[_0x4e2ecd('0x48')](handleError(_0x2813e8,null));},exports[_0x3efdc6('0x11')]=function(_0x99d1a7,_0x1eaa4f){const _0x3db46c=_0x3efdc6;let _0x3c1d0b={'raw':![],'where':{'id':_0x99d1a7['params']['id']}};const _0x467a5b={};return _0x467a5b[_0x3db46c('0x32')]=_[_0x3db46c('0x45')](db[_0x3db46c('0x35')][_0x3db46c('0x34')]),_0x467a5b['query']=_[_0x3db46c('0x45')](_0x99d1a7['query']),_0x467a5b['filters']=_[_0x3db46c('0xe')](_0x467a5b[_0x3db46c('0x32')],_0x467a5b['query']),_0x3c1d0b[_0x3db46c('0x56')]=_['intersection'](_0x467a5b[_0x3db46c('0x32')],qs[_0x3db46c('0x4a')](_0x99d1a7[_0x3db46c('0x3d')][_0x3db46c('0x4a')])),_0x3c1d0b[_0x3db46c('0x56')]=_0x3c1d0b[_0x3db46c('0x56')][_0x3db46c('0x1e')]?_0x3c1d0b[_0x3db46c('0x56')]:_0x467a5b[_0x3db46c('0x32')],_0x99d1a7[_0x3db46c('0x3d')][_0x3db46c('0x27')]&&(_0x3c1d0b[_0x3db46c('0x23')]=[{'all':!![]}]),_0x3c1d0b=_[_0x3db46c('0x46')]({},_0x3c1d0b,_0x99d1a7[_0x3db46c('0x26')]),db['DeskAccount'][_0x3db46c('0xa')](_0x3c1d0b)[_0x3db46c('0x3f')](handleEntityNotFound(_0x1eaa4f,null))[_0x3db46c('0x3f')](respondWithResult(_0x1eaa4f,null))[_0x3db46c('0x48')](handleError(_0x1eaa4f,null));},exports[_0x3efdc6('0x47')]=function(_0x1a21a7,_0xd32e6a){const _0x522270=_0x3efdc6;return db[_0x522270('0x35')][_0x522270('0x47')](_0x1a21a7[_0x522270('0x2')],{})[_0x522270('0x3f')](respondWithResult(_0xd32e6a,0xc9))[_0x522270('0x48')](handleError(_0xd32e6a,null));},exports[_0x3efdc6('0x14')]=function(_0x106ecb,_0x3506a3){const _0x412b88=_0x3efdc6;return _0x106ecb['body']['id']&&delete _0x106ecb[_0x412b88('0x2')]['id'],db[_0x412b88('0x35')][_0x412b88('0xa')]({'where':{'id':_0x106ecb['params']['id']}})[_0x412b88('0x3f')](handleEntityNotFound(_0x3506a3,null))[_0x412b88('0x3f')](saveUpdates(_0x106ecb[_0x412b88('0x2')],null))[_0x412b88('0x3f')](respondWithResult(_0x3506a3,null))[_0x412b88('0x48')](handleError(_0x3506a3,null));},exports[_0x3efdc6('0x4f')]=function(_0xf88cac,_0x1e5402){const _0x5215fd=_0x3efdc6;return db[_0x5215fd('0x35')][_0x5215fd('0xa')]({'where':{'id':_0xf88cac[_0x5215fd('0x3a')]['id']}})[_0x5215fd('0x3f')](handleEntityNotFound(_0x1e5402,null))['then'](removeEntity(_0x1e5402,null))[_0x5215fd('0x48')](handleError(_0x1e5402,null));},exports['getConfigurations']=function(_0x606db9,_0xb23308){const _0x5b9439=_0x3efdc6;let _0x385543={};const _0xc6284b={};let _0x1f4947,_0x517f86;return db[_0x5b9439('0x35')][_0x5b9439('0xa')]({'where':{'id':_0x606db9[_0x5b9439('0x3a')]['id']}})[_0x5b9439('0x3f')](handleEntityNotFound(_0xb23308,null))['then'](function(_0x1743f8){const _0x103ba6=_0x5b9439;if(_0x1743f8)return _0x1f4947=_0x1743f8,_0xc6284b['model']=_[_0x103ba6('0x45')](db[_0x103ba6('0x1a')][_0x103ba6('0x34')]),_0xc6284b[_0x103ba6('0x3d')]=_[_0x103ba6('0x45')](_0x606db9['query']),_0xc6284b[_0x103ba6('0x18')]=_[_0x103ba6('0xe')](_0xc6284b[_0x103ba6('0x32')],_0xc6284b[_0x103ba6('0x3d')]),_0x385543[_0x103ba6('0x56')]=_[_0x103ba6('0xe')](_0xc6284b['model'],qs[_0x103ba6('0x4a')](_0x606db9[_0x103ba6('0x3d')][_0x103ba6('0x4a')])),_0x385543[_0x103ba6('0x56')]=_0x385543[_0x103ba6('0x56')]['length']?_0x385543[_0x103ba6('0x56')]:_0xc6284b[_0x103ba6('0x32')],_0x385543[_0x103ba6('0x52')]=qs[_0x103ba6('0x1f')](_0x606db9[_0x103ba6('0x3d')][_0x103ba6('0x1f')]),_0x385543['where']=qs['filters'](_[_0x103ba6('0x43')](_0x606db9['query'],_0xc6284b[_0x103ba6('0x18')])),_0x606db9[_0x103ba6('0x3d')][_0x103ba6('0xd')]&&(_0x385543[_0x103ba6('0x10')]=_['merge'](_0x385543['where'],{[Op['or']]:_[_0x103ba6('0x21')](_0x385543[_0x103ba6('0x56')],function(_0x286781){const _0x39c64a=_0x103ba6,_0x37527e={};return _0x37527e[_0x286781]={[Op[_0x39c64a('0x49')]]:'%'+_0x606db9[_0x39c64a('0x3d')][_0x39c64a('0xd')]+'%'},_0x37527e;})})),_0x385543=_[_0x103ba6('0x46')]({},_0x385543,_0x606db9[_0x103ba6('0x26')]),_0x1f4947[_0x103ba6('0x1b')](_0x385543);})[_0x5b9439('0x3f')](function(_0xb5431d){const _0x4e8a08=_0x5b9439;if(_0xb5431d)return _0x517f86=_0xb5431d[_0x4e8a08('0x1e')],typeof _0x606db9[_0x4e8a08('0x3d')][_0x4e8a08('0x4')]==='undefined'&&(_0x385543[_0x4e8a08('0x16')]=qs['limit'](_0x606db9[_0x4e8a08('0x3d')][_0x4e8a08('0x16')]),_0x385543[_0x4e8a08('0x2b')]=qs[_0x4e8a08('0x2b')](_0x606db9[_0x4e8a08('0x3d')][_0x4e8a08('0x2b')])),_0x1f4947[_0x4e8a08('0x1b')](_0x385543);})[_0x5b9439('0x3f')](function(_0x253d6b){if(_0x253d6b)return _0x253d6b?{'count':_0x517f86,'rows':_0x253d6b}:null;})[_0x5b9439('0x3f')](respondWithResult(_0xb23308,null))['catch'](handleError(_0xb23308,null));},exports[_0x3efdc6('0x13')]=function(_0x28fe8e,_0x2b76bc){const _0x263e3c=_0x3efdc6;return _0x28fe8e[_0x263e3c('0x2')]['id']&&delete _0x28fe8e[_0x263e3c('0x2')]['id'],db[_0x263e3c('0x35')][_0x263e3c('0xa')]({'where':{'id':_0x28fe8e[_0x263e3c('0x3a')]['id']}})[_0x263e3c('0x3f')](handleEntityNotFound(_0x2b76bc,null))[_0x263e3c('0x3f')](function(_0x3cb12d){const _0x105c5d=_0x263e3c;if(_0x3cb12d)return _0x28fe8e[_0x105c5d('0x2')]['AccountId']=_0x3cb12d['id'],_0x28fe8e[_0x105c5d('0x2')][_0x105c5d('0x31')]=integrations[_0x105c5d('0x55')](_0x28fe8e[_0x105c5d('0x2')][_0x105c5d('0x15')],_0x28fe8e['body'][_0x105c5d('0x41')]),_0x28fe8e['body'][_0x105c5d('0x33')]=integrations['getDescriptions'](_0x28fe8e['body'][_0x105c5d('0x15')],_0x28fe8e[_0x105c5d('0x2')][_0x105c5d('0x41')]),db[_0x105c5d('0x1a')][_0x105c5d('0x47')](_0x28fe8e[_0x105c5d('0x2')],{'include':[{'model':db['DeskField'],'as':'Subjects'},{'model':db[_0x105c5d('0x6')],'as':_0x105c5d('0x33')}]});return null;})[_0x263e3c('0x3f')](respondWithResult(_0x2b76bc,null))[_0x263e3c('0x48')](handleError(_0x2b76bc,null));},exports[_0x3efdc6('0x53')]=function(_0x3b78b7,_0x460a8b){const _0x53c166=_0x3efdc6,_0x5713f5=[{'name':_0x53c166('0x0'),'label':_0x53c166('0x0'),'custom':![],'options':[{'name':0x1,'value':0x1},{'name':0x2,'value':0x2},{'name':0x3,'value':0x3},{'name':0x4,'value':0x4},{'name':0x5,'value':0x5},{'name':0x6,'value':0x6},{'name':0x7,'value':0x7},{'name':0x8,'value':0x8},{'name':0x9,'value':0x9},{'name':0xa,'value':0xa}]}];let _0x2b4944='';return db[_0x53c166('0x35')]['findOne']({'where':{'id':_0x3b78b7[_0x53c166('0x3a')]['id']},'attributes':['id',_0x53c166('0x24'),'authType','username',_0x53c166('0x30'),_0x53c166('0x28'),_0x53c166('0x3e'),'token',_0x53c166('0x37')]})[_0x53c166('0x3f')](handleEntityNotFound(_0x460a8b,null))[_0x53c166('0x3f')](function(_0x2da06c){const _0x4e3298=_0x53c166;if(_0x2da06c){_0x2b4944=_0x2da06c[_0x4e3298('0x24')];const _0x37e479=_0x2b4944[_0x4e3298('0x2c')](-0x1);_0x37e479==='/'&&(_0x2b4944=_0x2b4944['substring'](0x0,_0x2b4944[_0x4e3298('0x40')](_0x37e479)));const _0x3ed757={'method':'GET','uri':util[_0x4e3298('0x1c')](_0x4e3298('0x3c'),_0x2b4944),'headers':{'Content-Type':'application/json','Accept':_0x4e3298('0x42')},'json':!![]};return _0x2da06c['authType']===_0x4e3298('0x7')&&(_0x3ed757['headers']['Authorization']=util['format'](_0x4e3298('0x3'),Buffer[_0x4e3298('0x2f')](util[_0x4e3298('0x1c')](_0x4e3298('0xf'),_0x2da06c['username'],_0x2da06c[_0x4e3298('0x30')]))[_0x4e3298('0x12')]('base64'))),rp(_0x3ed757)[_0x4e3298('0x3f')](function(_0x826407){const _0x5f3f5d=_0x4e3298;return _0x5713f5[_0x5f3f5d('0x4d')](_[_0x5f3f5d('0x21')](_0x826407[_0x5f3f5d('0x54')][_0x5f3f5d('0x36')],function(_0x3b5b19){const _0x3812b2=_0x5f3f5d;return{'id':_0x3b5b19[_0x3812b2('0x25')],'name':_0x3b5b19[_0x3812b2('0x25')],'type':_0x3b5b19[_0x3812b2('0x41')],'active':_0x3b5b19['active'],'label':_0x3b5b19[_0x3812b2('0x39')],'custom':!![]};}));});}})['then'](function(_0x5bdd4f){const _0x21bf1b=_0x53c166;return{'count':_0x5bdd4f[_0x21bf1b('0x1e')],'rows':_0x5bdd4f};})[_0x53c166('0x3f')](respondWithResult(_0x460a8b,null))[_0x53c166('0x48')](function(_0x214a15){const _0x3287c4=_0x53c166;let _0x2666b3=_0x3b78b7[_0x3287c4('0x3d')][_0x3287c4('0xc')]?0x1f4:_0x214a15['statusCode']||0x1f4;logger[_0x3287c4('0x29')](_0x3287c4('0x1d'),_0x3287c4('0x53'),_0x2666b3,JSON[_0x3287c4('0x4b')](_0x214a15)),delete _0x214a15[_0x3287c4('0x25')],_0x2666b3===0x191&&(_0x2666b3=0x190),_0x460a8b[_0x3287c4('0xb')](_0x2666b3)[_0x3287c4('0x44')](_0x3b78b7[_0x3287c4('0x3d')][_0x3287c4('0xc')]?{'message':'Wrong\x20credentials','statusCode':_0x214a15[_0x3287c4('0x4c')]}:_0x214a15);});}; \ No newline at end of file diff --git a/server/api/intDeskAccount/intDeskAccount.model.js b/server/api/intDeskAccount/intDeskAccount.model.js index a49751d..480be00 100644 --- a/server/api/intDeskAccount/intDeskAccount.model.js +++ b/server/api/intDeskAccount/intDeskAccount.model.js @@ -1 +1 @@ -const a230_0x4897=['DeskAccount','./intDeskAccount.attributes','int_desk_accounts','exports'];(function(_0x28dd6a,_0x489708){const _0x40bba2=function(_0x3cd14d){while(--_0x3cd14d){_0x28dd6a['push'](_0x28dd6a['shift']());}};_0x40bba2(++_0x489708);}(a230_0x4897,0x91));const a230_0x40bb=function(_0x28dd6a,_0x489708){_0x28dd6a=_0x28dd6a-0x0;let _0x40bba2=a230_0x4897[_0x28dd6a];return _0x40bba2;};const _0x11d2d9=a230_0x40bb;'use strict';const attributes=require(_0x11d2d9('0x0'));module[_0x11d2d9('0x2')]=function(_0x3cd14d){const _0x3b9704=_0x11d2d9,_0x41d92b=_0x3cd14d['define'](_0x3b9704('0x3'),attributes,{'tableName':_0x3b9704('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x41d92b;}; \ No newline at end of file +const a230_0xb169=['DeskAccount','int_desk_accounts','exports','define'];(function(_0x2efff6,_0xb16952){const _0x2aae44=function(_0x2894fb){while(--_0x2894fb){_0x2efff6['push'](_0x2efff6['shift']());}};_0x2aae44(++_0xb16952);}(a230_0xb169,0x191));const a230_0x2aae=function(_0x2efff6,_0xb16952){_0x2efff6=_0x2efff6-0x0;let _0x2aae44=a230_0xb169[_0x2efff6];return _0x2aae44;};const _0x40362f=a230_0x2aae;'use strict';const attributes=require('./intDeskAccount.attributes');module[_0x40362f('0x1')]=function(_0x2894fb){const _0x3b9f19=_0x40362f,_0x1736d0=_0x2894fb[_0x3b9f19('0x2')](_0x3b9f19('0x3'),attributes,{'tableName':_0x3b9f19('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1736d0;}; \ No newline at end of file diff --git a/server/api/intDeskAccount/intDeskAccount.rpc.js b/server/api/intDeskAccount/intDeskAccount.rpc.js index 42994ce..fa0f030 100644 --- a/server/api/intDeskAccount/intDeskAccount.rpc.js +++ b/server/api/intDeskAccount/intDeskAccount.rpc.js @@ -1 +1 @@ -const a231_0xc761=['rpc','error','../../mysqldb','stringify','DeskAccount','message','catch','raw','include','where','GetDeskAccount','ShowDeskAccount','../../config/logger','lodash','findOne','then','info','model','attributes','map','findAll','options','debug'];(function(_0x4ea2d6,_0xc76159){const _0x3eb7bb=function(_0x1d7fe1){while(--_0x1d7fe1){_0x4ea2d6['push'](_0x4ea2d6['shift']());}};_0x3eb7bb(++_0xc76159);}(a231_0xc761,0x114));const a231_0x3eb7=function(_0x4ea2d6,_0xc76159){_0x4ea2d6=_0x4ea2d6-0x0;let _0x3eb7bb=a231_0xc761[_0x4ea2d6];return _0x3eb7bb;};const _0x236e04=a231_0x3eb7;'use strict';const _=require(_0x236e04('0xd')),db=require(_0x236e04('0x2'))['db'],logger=require(_0x236e04('0xc'))(_0x236e04('0x0'));exports[_0x236e04('0xa')]=function(_0x1d7fe1){const _0x4206a1=this;return new Promise(function(_0x3dbca6,_0x4253c0){const _0x5d997b=a231_0x3eb7;return db[_0x5d997b('0x4')][_0x5d997b('0x14')]({'raw':_0x1d7fe1[_0x5d997b('0x15')]?_0x1d7fe1['options']['raw']===undefined?!![]:![]:!![],'where':_0x1d7fe1['options']?_0x1d7fe1[_0x5d997b('0x15')]['where']||null:null,'attributes':_0x1d7fe1[_0x5d997b('0x15')]?_0x1d7fe1[_0x5d997b('0x15')][_0x5d997b('0x12')]||null:null,'limit':_0x1d7fe1['options']?_0x1d7fe1[_0x5d997b('0x15')]['limit']||null:null,'include':_0x1d7fe1[_0x5d997b('0x15')]?_0x1d7fe1[_0x5d997b('0x15')][_0x5d997b('0x8')]?_['map'](_0x1d7fe1['options']['include'],function(_0x4fa316){const _0x49b828=_0x5d997b;return{'model':db[_0x4fa316[_0x49b828('0x11')]],'as':_0x4fa316['as'],'attributes':_0x4fa316[_0x49b828('0x12')],'include':_0x4fa316['include']?_['map'](_0x4fa316[_0x49b828('0x8')],function(_0x9468dc){const _0x1a896f=_0x49b828;return{'model':db[_0x9468dc[_0x1a896f('0x11')]],'as':_0x9468dc['as'],'attributes':_0x9468dc[_0x1a896f('0x12')],'include':_0x9468dc[_0x1a896f('0x8')]?_['map'](_0x9468dc['include'],function(_0x3c407){return{'model':db[_0x3c407['model']],'as':_0x3c407['as'],'attributes':_0x3c407['attributes']};}):[]};}):[]};}):[]:[]})[_0x5d997b('0xf')](function(_0xf38c55){const _0x51f8fb=_0x5d997b;logger['info']('GetDeskAccount',_0x1d7fe1),logger[_0x51f8fb('0x16')](_0x51f8fb('0xa'),_0x1d7fe1,JSON['stringify'](_0xf38c55)),_0x3dbca6(_0xf38c55);})[_0x5d997b('0x6')](function(_0x4e1aee){const _0x4c377d=_0x5d997b;logger['error']('GetDeskAccount',_0x4e1aee[_0x4c377d('0x5')],_0x1d7fe1),_0x4253c0(_0x4206a1[_0x4c377d('0x1')](0x1f4,_0x4e1aee[_0x4c377d('0x5')]));});});},exports[_0x236e04('0xb')]=function(_0x3cde86){const _0x2c0789=this;return new Promise(function(_0x155d90,_0x4f2d1b){const _0x207f0a=a231_0x3eb7;return db['DeskAccount'][_0x207f0a('0xe')]({'raw':_0x3cde86[_0x207f0a('0x15')]?_0x3cde86['options'][_0x207f0a('0x7')]===undefined?!![]:![]:!![],'where':_0x3cde86[_0x207f0a('0x15')]?_0x3cde86[_0x207f0a('0x15')][_0x207f0a('0x9')]||null:null,'attributes':_0x3cde86[_0x207f0a('0x15')]?_0x3cde86[_0x207f0a('0x15')][_0x207f0a('0x12')]||null:null,'include':_0x3cde86[_0x207f0a('0x15')]?_0x3cde86['options'][_0x207f0a('0x8')]?_[_0x207f0a('0x13')](_0x3cde86[_0x207f0a('0x15')][_0x207f0a('0x8')],function(_0x2e1e91){const _0x20ea71=_0x207f0a;return{'model':db[_0x2e1e91[_0x20ea71('0x11')]],'as':_0x2e1e91['as'],'attributes':_0x2e1e91[_0x20ea71('0x12')],'include':_0x2e1e91['include']?_['map'](_0x2e1e91[_0x20ea71('0x8')],function(_0x5944a3){const _0xff358b=_0x20ea71;return{'model':db[_0x5944a3[_0xff358b('0x11')]],'as':_0x5944a3['as'],'attributes':_0x5944a3['attributes'],'include':_0x5944a3['include']?_[_0xff358b('0x13')](_0x5944a3[_0xff358b('0x8')],function(_0x54de55){const _0x4fc43f=_0xff358b;return{'model':db[_0x54de55[_0x4fc43f('0x11')]],'as':_0x54de55['as'],'attributes':_0x54de55[_0x4fc43f('0x12')]};}):[]};}):[]};}):[]:[]})[_0x207f0a('0xf')](function(_0x5c66de){const _0x198544=_0x207f0a;logger[_0x198544('0x10')](_0x198544('0xb'),_0x3cde86),logger[_0x198544('0x16')](_0x198544('0xb'),_0x3cde86,JSON[_0x198544('0x3')](_0x5c66de)),_0x155d90(_0x5c66de);})[_0x207f0a('0x6')](function(_0x4fc571){const _0x3bdb84=_0x207f0a;logger[_0x3bdb84('0x1')](_0x3bdb84('0xb'),_0x4fc571[_0x3bdb84('0x5')],_0x3cde86),_0x4f2d1b(_0x2c0789['error'](0x1f4,_0x4fc571[_0x3bdb84('0x5')]));});});}; \ No newline at end of file +const a231_0x3924=['where','info','debug','error','lodash','model','options','then','DeskAccount','attributes','stringify','message','rpc','limit','findOne','ShowDeskAccount','GetDeskAccount','map','../../mysqldb','catch','include'];(function(_0x437b26,_0x39245a){const _0x59160c=function(_0x594f3a){while(--_0x594f3a){_0x437b26['push'](_0x437b26['shift']());}};_0x59160c(++_0x39245a);}(a231_0x3924,0x152));const a231_0x5916=function(_0x437b26,_0x39245a){_0x437b26=_0x437b26-0x0;let _0x59160c=a231_0x3924[_0x437b26];return _0x59160c;};const _0x18e4d2=a231_0x5916;'use strict';const _=require(_0x18e4d2('0x2')),db=require(_0x18e4d2('0x10'))['db'],logger=require('../../config/logger')(_0x18e4d2('0xa'));exports[_0x18e4d2('0xe')]=function(_0x594f3a){const _0x512172=this;return new Promise(function(_0x104fcc,_0x1c23e4){const _0x94062a=a231_0x5916;return db[_0x94062a('0x6')]['findAll']({'raw':_0x594f3a[_0x94062a('0x4')]?_0x594f3a[_0x94062a('0x4')]['raw']===undefined?!![]:![]:!![],'where':_0x594f3a[_0x94062a('0x4')]?_0x594f3a[_0x94062a('0x4')]['where']||null:null,'attributes':_0x594f3a[_0x94062a('0x4')]?_0x594f3a[_0x94062a('0x4')]['attributes']||null:null,'limit':_0x594f3a[_0x94062a('0x4')]?_0x594f3a[_0x94062a('0x4')][_0x94062a('0xb')]||null:null,'include':_0x594f3a[_0x94062a('0x4')]?_0x594f3a['options'][_0x94062a('0x12')]?_[_0x94062a('0xf')](_0x594f3a[_0x94062a('0x4')][_0x94062a('0x12')],function(_0x1569e5){const _0x2c40aa=_0x94062a;return{'model':db[_0x1569e5[_0x2c40aa('0x3')]],'as':_0x1569e5['as'],'attributes':_0x1569e5[_0x2c40aa('0x7')],'include':_0x1569e5[_0x2c40aa('0x12')]?_[_0x2c40aa('0xf')](_0x1569e5[_0x2c40aa('0x12')],function(_0x3565e1){const _0x2b9705=_0x2c40aa;return{'model':db[_0x3565e1['model']],'as':_0x3565e1['as'],'attributes':_0x3565e1[_0x2b9705('0x7')],'include':_0x3565e1[_0x2b9705('0x12')]?_['map'](_0x3565e1[_0x2b9705('0x12')],function(_0x335459){const _0x255d6d=_0x2b9705;return{'model':db[_0x335459[_0x255d6d('0x3')]],'as':_0x335459['as'],'attributes':_0x335459[_0x255d6d('0x7')]};}):[]};}):[]};}):[]:[]})[_0x94062a('0x5')](function(_0xa732ec){const _0x3ca0cd=_0x94062a;logger[_0x3ca0cd('0x14')](_0x3ca0cd('0xe'),_0x594f3a),logger[_0x3ca0cd('0x0')](_0x3ca0cd('0xe'),_0x594f3a,JSON[_0x3ca0cd('0x8')](_0xa732ec)),_0x104fcc(_0xa732ec);})[_0x94062a('0x11')](function(_0x263669){const _0x2f9b8f=_0x94062a;logger[_0x2f9b8f('0x1')](_0x2f9b8f('0xe'),_0x263669['message'],_0x594f3a),_0x1c23e4(_0x512172[_0x2f9b8f('0x1')](0x1f4,_0x263669['message']));});});},exports[_0x18e4d2('0xd')]=function(_0x2916d8){const _0x128cd7=this;return new Promise(function(_0x2c45b6,_0x3d9100){const _0x25f277=a231_0x5916;return db[_0x25f277('0x6')][_0x25f277('0xc')]({'raw':_0x2916d8[_0x25f277('0x4')]?_0x2916d8[_0x25f277('0x4')]['raw']===undefined?!![]:![]:!![],'where':_0x2916d8['options']?_0x2916d8[_0x25f277('0x4')][_0x25f277('0x13')]||null:null,'attributes':_0x2916d8[_0x25f277('0x4')]?_0x2916d8[_0x25f277('0x4')][_0x25f277('0x7')]||null:null,'include':_0x2916d8[_0x25f277('0x4')]?_0x2916d8[_0x25f277('0x4')][_0x25f277('0x12')]?_[_0x25f277('0xf')](_0x2916d8[_0x25f277('0x4')][_0x25f277('0x12')],function(_0xab208f){const _0x556de5=_0x25f277;return{'model':db[_0xab208f[_0x556de5('0x3')]],'as':_0xab208f['as'],'attributes':_0xab208f[_0x556de5('0x7')],'include':_0xab208f[_0x556de5('0x12')]?_['map'](_0xab208f[_0x556de5('0x12')],function(_0x437fd1){const _0x4f92f2=_0x556de5;return{'model':db[_0x437fd1[_0x4f92f2('0x3')]],'as':_0x437fd1['as'],'attributes':_0x437fd1[_0x4f92f2('0x7')],'include':_0x437fd1[_0x4f92f2('0x12')]?_[_0x4f92f2('0xf')](_0x437fd1['include'],function(_0x9e2984){const _0x41506a=_0x4f92f2;return{'model':db[_0x9e2984[_0x41506a('0x3')]],'as':_0x9e2984['as'],'attributes':_0x9e2984[_0x41506a('0x7')]};}):[]};}):[]};}):[]:[]})[_0x25f277('0x5')](function(_0x3af9a5){const _0x51c423=_0x25f277;logger[_0x51c423('0x14')](_0x51c423('0xd'),_0x2916d8),logger[_0x51c423('0x0')](_0x51c423('0xd'),_0x2916d8,JSON['stringify'](_0x3af9a5)),_0x2c45b6(_0x3af9a5);})['catch'](function(_0x42efca){const _0x26685a=_0x25f277;logger[_0x26685a('0x1')](_0x26685a('0xd'),_0x42efca[_0x26685a('0x9')],_0x2916d8),_0x3d9100(_0x128cd7[_0x26685a('0x1')](0x1f4,_0x42efca['message']));});});}; \ No newline at end of file diff --git a/server/api/intDeskConfiguration/index.js b/server/api/intDeskConfiguration/index.js index 949b0c0..9c9ca25 100644 --- a/server/api/intDeskConfiguration/index.js +++ b/server/api/intDeskConfiguration/index.js @@ -1 +1 @@ -const a232_0x4334=['put','/:id/fields','create','show','setTags','exports','destroy','/:id','./intDeskConfiguration.controller','isAuthenticated','/:id/subjects','update','index','/:id/descriptions','express','getFields','/:id/tags','getDescriptions','get'];(function(_0x42517e,_0x43343d){const _0x7d55d=function(_0x163374){while(--_0x163374){_0x42517e['push'](_0x42517e['shift']());}};_0x7d55d(++_0x43343d);}(a232_0x4334,0xe8));const a232_0x7d55=function(_0x42517e,_0x43343d){_0x42517e=_0x42517e-0x0;let _0x7d55d=a232_0x4334[_0x42517e];return _0x7d55d;};const _0x3490ec=a232_0x7d55;'use strict';const express=require(_0x3490ec('0xa')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x3490ec('0x4'));router[_0x3490ec('0xe')]('/',auth[_0x3490ec('0x5')](),controller[_0x3490ec('0x8')]),router[_0x3490ec('0xe')](_0x3490ec('0x3'),auth[_0x3490ec('0x5')](),controller[_0x3490ec('0x12')]),router['get'](_0x3490ec('0x10'),auth[_0x3490ec('0x5')](),controller[_0x3490ec('0xb')]),router[_0x3490ec('0xe')](_0x3490ec('0x6'),auth[_0x3490ec('0x5')](),controller['getSubjects']),router[_0x3490ec('0xe')](_0x3490ec('0x9'),auth[_0x3490ec('0x5')](),controller[_0x3490ec('0xd')]),router['get'](_0x3490ec('0xc'),auth[_0x3490ec('0x5')](),controller['getTags']),router['post']('/',auth[_0x3490ec('0x5')](),controller[_0x3490ec('0x11')]),router['post'](_0x3490ec('0xc'),auth[_0x3490ec('0x5')](),controller[_0x3490ec('0x0')]),router[_0x3490ec('0xf')]('/:id',auth[_0x3490ec('0x5')](),controller[_0x3490ec('0x7')]),router['delete'](_0x3490ec('0x3'),auth[_0x3490ec('0x5')](),controller[_0x3490ec('0x2')]),module[_0x3490ec('0x1')]=router; \ No newline at end of file +const a232_0x18da=['/:id/fields','post','/:id/tags','Router','show','getFields','getSubjects','index','express','delete','update','../../components/auth/service','getDescriptions','/:id/subjects','isAuthenticated','/:id','put','get'];(function(_0x1c15ea,_0x18da98){const _0x54b21c=function(_0x33e348){while(--_0x33e348){_0x1c15ea['push'](_0x1c15ea['shift']());}};_0x54b21c(++_0x18da98);}(a232_0x18da,0x179));const a232_0x54b2=function(_0x1c15ea,_0x18da98){_0x1c15ea=_0x1c15ea-0x0;let _0x54b21c=a232_0x18da[_0x1c15ea];return _0x54b21c;};const _0xd6838b=a232_0x54b2;'use strict';const express=require(_0xd6838b('0x9')),router=express[_0xd6838b('0x4')](),auth=require(_0xd6838b('0xc')),controller=require('./intDeskConfiguration.controller');router[_0xd6838b('0x0')]('/',auth['isAuthenticated'](),controller[_0xd6838b('0x8')]),router[_0xd6838b('0x0')](_0xd6838b('0x10'),auth['isAuthenticated'](),controller[_0xd6838b('0x5')]),router[_0xd6838b('0x0')](_0xd6838b('0x1'),auth[_0xd6838b('0xf')](),controller[_0xd6838b('0x6')]),router[_0xd6838b('0x0')](_0xd6838b('0xe'),auth[_0xd6838b('0xf')](),controller[_0xd6838b('0x7')]),router[_0xd6838b('0x0')]('/:id/descriptions',auth[_0xd6838b('0xf')](),controller[_0xd6838b('0xd')]),router['get']('/:id/tags',auth[_0xd6838b('0xf')](),controller['getTags']),router[_0xd6838b('0x2')]('/',auth[_0xd6838b('0xf')](),controller['create']),router[_0xd6838b('0x2')](_0xd6838b('0x3'),auth[_0xd6838b('0xf')](),controller['setTags']),router[_0xd6838b('0x11')](_0xd6838b('0x10'),auth[_0xd6838b('0xf')](),controller[_0xd6838b('0xb')]),router[_0xd6838b('0xa')](_0xd6838b('0x10'),auth[_0xd6838b('0xf')](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/intDeskConfiguration/intDeskConfiguration.attributes.js b/server/api/intDeskConfiguration/intDeskConfiguration.attributes.js index 303bc90..75e22b8 100644 --- a/server/api/intDeskConfiguration/intDeskConfiguration.attributes.js +++ b/server/api/intDeskConfiguration/intDeskConfiguration.attributes.js @@ -1 +1 @@ -const a233_0x427f=['STRING'];(function(_0x1ebf1c,_0x427fc1){const _0x2b619a=function(_0x4b135d){while(--_0x4b135d){_0x1ebf1c['push'](_0x1ebf1c['shift']());}};_0x2b619a(++_0x427fc1);}(a233_0x427f,0x128));const a233_0x2b61=function(_0x1ebf1c,_0x427fc1){_0x1ebf1c=_0x1ebf1c-0x0;let _0x2b619a=a233_0x427f[_0x1ebf1c];return _0x2b619a;};const _0x3d2cb3=a233_0x2b61;'use strict';const Sequelize=require('sequelize');module['exports']={'name':{'type':Sequelize[_0x3d2cb3('0x0')]},'description':{'type':Sequelize[_0x3d2cb3('0x0')]}}; \ No newline at end of file +const a233_0x17b9=['sequelize','STRING'];(function(_0x3c34e6,_0x17b97a){const _0x2e75da=function(_0x2393ff){while(--_0x2393ff){_0x3c34e6['push'](_0x3c34e6['shift']());}};_0x2e75da(++_0x17b97a);}(a233_0x17b9,0xf3));const a233_0x2e75=function(_0x3c34e6,_0x17b97a){_0x3c34e6=_0x3c34e6-0x0;let _0x2e75da=a233_0x17b9[_0x3c34e6];return _0x2e75da;};const _0x4890c8=a233_0x2e75;'use strict';const Sequelize=require(_0x4890c8('0x1'));module['exports']={'name':{'type':Sequelize[_0x4890c8('0x0')]},'description':{'type':Sequelize[_0x4890c8('0x0')]}}; \ No newline at end of file diff --git a/server/api/intDeskConfiguration/intDeskConfiguration.controller.js b/server/api/intDeskConfiguration/intDeskConfiguration.controller.js index 6753e70..0768984 100644 --- a/server/api/intDeskConfiguration/intDeskConfiguration.controller.js +++ b/server/api/intDeskConfiguration/intDeskConfiguration.controller.js @@ -1 +1 @@ -const a234_0x7395=['ids','stack','DeskConfiguration','filter','catch','fields','sequelize','findOne','send','options','../../components/parsers/qs','model','where','rawAttributes','lodash','filters','api','like','map','sort','create','findAll','attributes','length','Content-Range','index','update','show','json','getDescriptions','getSubjects','offset','merge','intersection','getTags','then','DeskField','set','undefined','destroy','count','limit','getFields','include','status','../../config/logger','params','name','../../mysqldb','pick','includeAll','query','order','nolimit','end','body','fieldName','VIRTUAL','rows','keys'];(function(_0x34108d,_0x7395b8){const _0x29a1d5=function(_0x4840b3){while(--_0x4840b3){_0x34108d['push'](_0x34108d['shift']());}};_0x29a1d5(++_0x7395b8);}(a234_0x7395,0x155));const a234_0x29a1=function(_0x34108d,_0x7395b8){_0x34108d=_0x34108d-0x0;let _0x29a1d5=a234_0x7395[_0x34108d];return _0x29a1d5;};const _0x243cb5=a234_0x29a1;'use strict';const _=require(_0x243cb5('0x21')),qs=require(_0x243cb5('0x1d')),logger=require(_0x243cb5('0x4'))(_0x243cb5('0x23')),db=require(_0x243cb5('0x7'))['db'],{Op}=require(_0x243cb5('0x19'));function respondWithResult(_0x4840b3,_0x4be35a){return _0x4be35a=_0x4be35a||0xc8,function(_0x307d6e){const _0x18c80f=a234_0x29a1;if(_0x307d6e)return _0x4840b3[_0x18c80f('0x3')](_0x4be35a)[_0x18c80f('0x2f')](_0x307d6e);};}function respondWithFilteredResult(_0x9e2024,_0x1b2572){return function(_0x3efc69){const _0x5d2870=a234_0x29a1;if(_0x3efc69){const _0x53ab06=_0x3efc69[_0x5d2870('0x3b')],_0x1c1969=_0x1b2572['offset'];let _0x27fdc0=_0x1b2572[_0x5d2870('0x32')]+_0x1b2572[_0x5d2870('0x0')],_0x3b295c;return _0x27fdc0>=_0x53ab06?(_0x27fdc0=_0x53ab06,_0x3b295c=0xc8):_0x3b295c=0xce,_0x9e2024[_0x5d2870('0x3')](_0x3b295c),_0x9e2024[_0x5d2870('0x38')](_0x5d2870('0x2b'),_0x1c1969+'-'+_0x27fdc0+'/'+_0x53ab06)[_0x5d2870('0x2f')](_0x3efc69);}return null;};}function saveUpdates(_0x3ca0e6){return function(_0x4d3614){const _0x115eb5=a234_0x29a1;if(_0x4d3614)return _0x4d3614['update'](_0x3ca0e6)[_0x115eb5('0x36')](function(_0x58ed72){return _0x58ed72;});return null;};}function removeEntity(_0x45f9e0){return function(_0x6de6a3){const _0xc8d085=a234_0x29a1;if(_0x6de6a3)return _0x6de6a3[_0xc8d085('0x3a')]()[_0xc8d085('0x36')](function(){const _0x5f4295=_0xc8d085;_0x45f9e0[_0x5f4295('0x3')](0xcc)[_0x5f4295('0xd')]();});};}function handleEntityNotFound(_0x1a3c4f){return function(_0x1f3b43){return!_0x1f3b43&&_0x1a3c4f['sendStatus'](0x194),_0x1f3b43;};}function handleError(_0x5b703d,_0x37a0bf){return _0x37a0bf=_0x37a0bf||0x1f4,function(_0x591a75){const _0x3c8120=a234_0x29a1;logger['error'](_0x591a75[_0x3c8120('0x14')]),_0x591a75['name']&&delete _0x591a75[_0x3c8120('0x6')],_0x5b703d[_0x3c8120('0x3')](_0x37a0bf)[_0x3c8120('0x1b')](_0x591a75);};}exports[_0x243cb5('0x2c')]=function(_0x5ccc7d,_0x389351){const _0x561d10=_0x243cb5;let _0x595e14={};const _0x24b052={},_0xff0339={'count':0x0,'rows':[]},_0x32274b=_[_0x561d10('0x25')](db[_0x561d10('0x15')][_0x561d10('0x20')],function(_0x41bba5){const _0x1af38e=_0x561d10;return{'name':_0x41bba5[_0x1af38e('0xf')],'type':_0x41bba5['type']['key']};});_0x24b052[_0x561d10('0x1e')]=_['map'](_0x32274b,'name'),_0x24b052[_0x561d10('0xa')]=_[_0x561d10('0x12')](_0x5ccc7d[_0x561d10('0xa')]),_0x24b052[_0x561d10('0x22')]=_[_0x561d10('0x34')](_0x24b052['model'],_0x24b052[_0x561d10('0xa')]),_0x595e14['attributes']=_['intersection'](_0x24b052[_0x561d10('0x1e')],qs['fields'](_0x5ccc7d[_0x561d10('0xa')]['fields'])),_0x595e14[_0x561d10('0x29')]=_0x595e14[_0x561d10('0x29')][_0x561d10('0x2a')]?_0x595e14[_0x561d10('0x29')]:_0x24b052[_0x561d10('0x1e')];typeof _0x5ccc7d[_0x561d10('0xa')][_0x561d10('0xc')]===_0x561d10('0x39')&&(_0x595e14[_0x561d10('0x0')]=qs[_0x561d10('0x0')](_0x5ccc7d[_0x561d10('0xa')][_0x561d10('0x0')]),_0x595e14[_0x561d10('0x32')]=qs['offset'](_0x5ccc7d[_0x561d10('0xa')][_0x561d10('0x32')]));_0x595e14[_0x561d10('0xb')]=qs[_0x561d10('0x26')](_0x5ccc7d['query']['sort']),_0x595e14[_0x561d10('0x1f')]=qs[_0x561d10('0x22')](_[_0x561d10('0x8')](_0x5ccc7d[_0x561d10('0xa')],_0x24b052[_0x561d10('0x22')]),_0x32274b);_0x5ccc7d['query'][_0x561d10('0x16')]&&(_0x595e14[_0x561d10('0x1f')]=_[_0x561d10('0x33')](_0x595e14[_0x561d10('0x1f')],{[Op['or']]:_[_0x561d10('0x25')](_0x32274b,function(_0x15742c){const _0x26726d=_0x561d10;if(_0x15742c['type']!==_0x26726d('0x10')){const _0x1f7013={};return _0x1f7013[_0x15742c[_0x26726d('0x6')]]={[Op['like']]:'%'+_0x5ccc7d[_0x26726d('0xa')][_0x26726d('0x16')]+'%'},_0x1f7013;}})}));_0x595e14=_[_0x561d10('0x33')]({},_0x595e14,_0x5ccc7d[_0x561d10('0x1c')]);const _0x5a84f4={'where':_0x595e14['where']};return db[_0x561d10('0x15')][_0x561d10('0x3b')](_0x5a84f4)[_0x561d10('0x36')](function(_0x54bf83){const _0x1f0acb=_0x561d10;return _0xff0339[_0x1f0acb('0x3b')]=_0x54bf83,_0x5ccc7d[_0x1f0acb('0xa')][_0x1f0acb('0x9')]&&(_0x595e14[_0x1f0acb('0x2')]=[{'all':!![]}]),db['DeskConfiguration'][_0x1f0acb('0x28')](_0x595e14);})[_0x561d10('0x36')](function(_0x2a1ae5){const _0x25e5b8=_0x561d10;return _0xff0339[_0x25e5b8('0x11')]=_0x2a1ae5,_0xff0339;})[_0x561d10('0x36')](respondWithFilteredResult(_0x389351,_0x595e14))[_0x561d10('0x17')](handleError(_0x389351,null));},exports[_0x243cb5('0x2e')]=function(_0x5acca7,_0x346e9b){const _0x12ae68=_0x243cb5;let _0x2d95a3={'raw':![],'where':{'id':_0x5acca7[_0x12ae68('0x5')]['id']}};const _0x549ebe={};return _0x549ebe[_0x12ae68('0x1e')]=_[_0x12ae68('0x12')](db['DeskConfiguration']['rawAttributes']),_0x549ebe[_0x12ae68('0xa')]=_[_0x12ae68('0x12')](_0x5acca7['query']),_0x549ebe[_0x12ae68('0x22')]=_[_0x12ae68('0x34')](_0x549ebe['model'],_0x549ebe[_0x12ae68('0xa')]),_0x2d95a3['attributes']=_[_0x12ae68('0x34')](_0x549ebe[_0x12ae68('0x1e')],qs[_0x12ae68('0x18')](_0x5acca7['query'][_0x12ae68('0x18')])),_0x2d95a3[_0x12ae68('0x29')]=_0x2d95a3[_0x12ae68('0x29')][_0x12ae68('0x2a')]?_0x2d95a3[_0x12ae68('0x29')]:_0x549ebe[_0x12ae68('0x1e')],_0x5acca7[_0x12ae68('0xa')][_0x12ae68('0x9')]&&(_0x2d95a3['include']=[{'all':!![]}]),_0x2d95a3=_['merge']({},_0x2d95a3,_0x5acca7[_0x12ae68('0x1c')]),db['DeskConfiguration']['findOne'](_0x2d95a3)['then'](handleEntityNotFound(_0x346e9b,null))[_0x12ae68('0x36')](respondWithResult(_0x346e9b,null))[_0x12ae68('0x17')](handleError(_0x346e9b,null));},exports[_0x243cb5('0x27')]=function(_0x4c654d,_0x46c1e5){const _0x2c772c=_0x243cb5;return db[_0x2c772c('0x15')][_0x2c772c('0x27')](_0x4c654d[_0x2c772c('0xe')],{})[_0x2c772c('0x36')](respondWithResult(_0x46c1e5,0xc9))[_0x2c772c('0x17')](handleError(_0x46c1e5,null));},exports[_0x243cb5('0x2d')]=function(_0x242890,_0x3f860e){const _0x3b3ed0=_0x243cb5;return _0x242890['body']['id']&&delete _0x242890['body']['id'],db[_0x3b3ed0('0x15')][_0x3b3ed0('0x1a')]({'where':{'id':_0x242890[_0x3b3ed0('0x5')]['id']}})[_0x3b3ed0('0x36')](handleEntityNotFound(_0x3f860e,null))['then'](saveUpdates(_0x242890[_0x3b3ed0('0xe')],null))[_0x3b3ed0('0x36')](respondWithResult(_0x3f860e,null))[_0x3b3ed0('0x17')](handleError(_0x3f860e,null));},exports[_0x243cb5('0x3a')]=function(_0xfb159e,_0x2e95b8){const _0x588d60=_0x243cb5;return db[_0x588d60('0x15')]['findOne']({'where':{'id':_0xfb159e['params']['id']}})[_0x588d60('0x36')](handleEntityNotFound(_0x2e95b8,null))[_0x588d60('0x36')](removeEntity(_0x2e95b8,null))[_0x588d60('0x17')](handleError(_0x2e95b8,null));},exports['getFields']=function(_0x30e099,_0x75f2e3){const _0x1f5124=_0x243cb5;let _0x7546b5={};const _0x13fd12={};let _0x5bab43,_0x4131ec;return db['DeskConfiguration'][_0x1f5124('0x1a')]({'where':{'id':_0x30e099[_0x1f5124('0x5')]['id']}})[_0x1f5124('0x36')](handleEntityNotFound(_0x75f2e3,null))[_0x1f5124('0x36')](function(_0x3eaa22){const _0x5dfbef=_0x1f5124;if(_0x3eaa22)return _0x5bab43=_0x3eaa22,_0x13fd12[_0x5dfbef('0x1e')]=_[_0x5dfbef('0x12')](db['DeskField'][_0x5dfbef('0x20')]),_0x13fd12['query']=_[_0x5dfbef('0x12')](_0x30e099[_0x5dfbef('0xa')]),_0x13fd12[_0x5dfbef('0x22')]=_[_0x5dfbef('0x34')](_0x13fd12[_0x5dfbef('0x1e')],_0x13fd12[_0x5dfbef('0xa')]),_0x7546b5['attributes']=_[_0x5dfbef('0x34')](_0x13fd12[_0x5dfbef('0x1e')],qs[_0x5dfbef('0x18')](_0x30e099[_0x5dfbef('0xa')][_0x5dfbef('0x18')])),_0x7546b5['attributes']=_0x7546b5[_0x5dfbef('0x29')][_0x5dfbef('0x2a')]?_0x7546b5[_0x5dfbef('0x29')]:_0x13fd12[_0x5dfbef('0x1e')],_0x7546b5[_0x5dfbef('0xb')]=qs[_0x5dfbef('0x26')](_0x30e099[_0x5dfbef('0xa')]['sort']),_0x7546b5[_0x5dfbef('0x1f')]=qs['filters'](_[_0x5dfbef('0x8')](_0x30e099[_0x5dfbef('0xa')],_0x13fd12['filters'])),_0x30e099[_0x5dfbef('0xa')][_0x5dfbef('0x16')]&&(_0x7546b5[_0x5dfbef('0x1f')]=_[_0x5dfbef('0x33')](_0x7546b5[_0x5dfbef('0x1f')],{[Op['or']]:_[_0x5dfbef('0x25')](_0x7546b5[_0x5dfbef('0x29')],function(_0x2be5a4){const _0x597a1c=_0x5dfbef,_0x1a9cbf={};return _0x1a9cbf[_0x2be5a4]={[Op[_0x597a1c('0x24')]]:'%'+_0x30e099[_0x597a1c('0xa')]['filter']+'%'},_0x1a9cbf;})})),_0x7546b5=_['merge']({},_0x7546b5,_0x30e099['options']),_0x5bab43[_0x5dfbef('0x1')](_0x7546b5);})[_0x1f5124('0x36')](function(_0x3e619c){const _0x30ee54=_0x1f5124;if(_0x3e619c)return _0x4131ec=_0x3e619c['length'],typeof _0x30e099[_0x30ee54('0xa')][_0x30ee54('0xc')]===_0x30ee54('0x39')&&(_0x7546b5[_0x30ee54('0x0')]=qs['limit'](_0x30e099[_0x30ee54('0xa')]['limit']),_0x7546b5[_0x30ee54('0x32')]=qs[_0x30ee54('0x32')](_0x30e099[_0x30ee54('0xa')][_0x30ee54('0x32')])),_0x5bab43[_0x30ee54('0x1')](_0x7546b5);})['then'](function(_0xca6971){if(_0xca6971)return _0xca6971?{'count':_0x4131ec,'rows':_0xca6971}:null;})[_0x1f5124('0x36')](respondWithResult(_0x75f2e3,null))[_0x1f5124('0x17')](handleError(_0x75f2e3,null));},exports[_0x243cb5('0x31')]=function(_0x1c7653,_0x107dc7){const _0x29c66e=_0x243cb5;let _0x4e387b={};const _0xe14b3={};let _0x489998,_0x4e0407;return db[_0x29c66e('0x15')][_0x29c66e('0x1a')]({'where':{'id':_0x1c7653['params']['id']}})['then'](handleEntityNotFound(_0x107dc7,null))[_0x29c66e('0x36')](function(_0x553ea4){const _0x20be4f=_0x29c66e;if(_0x553ea4)return _0x489998=_0x553ea4,_0xe14b3[_0x20be4f('0x1e')]=_[_0x20be4f('0x12')](db['DeskField'][_0x20be4f('0x20')]),_0xe14b3[_0x20be4f('0xa')]=_['keys'](_0x1c7653[_0x20be4f('0xa')]),_0xe14b3[_0x20be4f('0x22')]=_[_0x20be4f('0x34')](_0xe14b3[_0x20be4f('0x1e')],_0xe14b3[_0x20be4f('0xa')]),_0x4e387b['attributes']=_[_0x20be4f('0x34')](_0xe14b3[_0x20be4f('0x1e')],qs[_0x20be4f('0x18')](_0x1c7653['query'][_0x20be4f('0x18')])),_0x4e387b['attributes']=_0x4e387b[_0x20be4f('0x29')]['length']?_0x4e387b[_0x20be4f('0x29')]:_0xe14b3[_0x20be4f('0x1e')],_0x4e387b[_0x20be4f('0xb')]=qs['sort'](_0x1c7653[_0x20be4f('0xa')]['sort']),_0x4e387b[_0x20be4f('0x1f')]=qs[_0x20be4f('0x22')](_[_0x20be4f('0x8')](_0x1c7653['query'],_0xe14b3[_0x20be4f('0x22')])),_0x1c7653['query'][_0x20be4f('0x16')]&&(_0x4e387b[_0x20be4f('0x1f')]=_[_0x20be4f('0x33')](_0x4e387b[_0x20be4f('0x1f')],{[Op['or']]:_[_0x20be4f('0x25')](_0x4e387b['attributes'],function(_0x373d1e){const _0x36b406=_0x20be4f,_0x365b19={};return _0x365b19[_0x373d1e]={[Op[_0x36b406('0x24')]]:'%'+_0x1c7653[_0x36b406('0xa')][_0x36b406('0x16')]+'%'},_0x365b19;})})),_0x4e387b=_['merge']({},_0x4e387b,_0x1c7653[_0x20be4f('0x1c')]),_0x489998[_0x20be4f('0x31')](_0x4e387b);})[_0x29c66e('0x36')](function(_0x2662c2){const _0x946826=_0x29c66e;if(_0x2662c2)return _0x4e0407=_0x2662c2[_0x946826('0x2a')],typeof _0x1c7653[_0x946826('0xa')][_0x946826('0xc')]===_0x946826('0x39')&&(_0x4e387b['limit']=qs['limit'](_0x1c7653['query']['limit']),_0x4e387b[_0x946826('0x32')]=qs[_0x946826('0x32')](_0x1c7653[_0x946826('0xa')][_0x946826('0x32')])),_0x489998['getSubjects'](_0x4e387b);})[_0x29c66e('0x36')](function(_0x43211d){if(_0x43211d)return _0x43211d?{'count':_0x4e0407,'rows':_0x43211d}:null;})['then'](respondWithResult(_0x107dc7,null))['catch'](handleError(_0x107dc7,null));},exports[_0x243cb5('0x30')]=function(_0xa50876,_0x4aa6a6){const _0x179a06=_0x243cb5;let _0x51dfdc={};const _0x19effa={};let _0x2be099,_0x37d07f;return db[_0x179a06('0x15')][_0x179a06('0x1a')]({'where':{'id':_0xa50876[_0x179a06('0x5')]['id']}})[_0x179a06('0x36')](handleEntityNotFound(_0x4aa6a6,null))['then'](function(_0xf23d88){const _0x166ac9=_0x179a06;if(_0xf23d88)return _0x2be099=_0xf23d88,_0x19effa[_0x166ac9('0x1e')]=_[_0x166ac9('0x12')](db[_0x166ac9('0x37')]['rawAttributes']),_0x19effa[_0x166ac9('0xa')]=_[_0x166ac9('0x12')](_0xa50876['query']),_0x19effa[_0x166ac9('0x22')]=_[_0x166ac9('0x34')](_0x19effa['model'],_0x19effa[_0x166ac9('0xa')]),_0x51dfdc['attributes']=_[_0x166ac9('0x34')](_0x19effa[_0x166ac9('0x1e')],qs['fields'](_0xa50876['query'][_0x166ac9('0x18')])),_0x51dfdc[_0x166ac9('0x29')]=_0x51dfdc[_0x166ac9('0x29')][_0x166ac9('0x2a')]?_0x51dfdc[_0x166ac9('0x29')]:_0x19effa['model'],_0x51dfdc[_0x166ac9('0xb')]=qs['sort'](_0xa50876[_0x166ac9('0xa')][_0x166ac9('0x26')]),_0x51dfdc[_0x166ac9('0x1f')]=qs[_0x166ac9('0x22')](_['pick'](_0xa50876[_0x166ac9('0xa')],_0x19effa[_0x166ac9('0x22')])),_0xa50876[_0x166ac9('0xa')][_0x166ac9('0x16')]&&(_0x51dfdc[_0x166ac9('0x1f')]=_[_0x166ac9('0x33')](_0x51dfdc[_0x166ac9('0x1f')],{[Op['or']]:_[_0x166ac9('0x25')](_0x51dfdc[_0x166ac9('0x29')],function(_0x217ddb){const _0x33445e={};return _0x33445e[_0x217ddb]={[Op['like']]:'%'+_0xa50876['query']['filter']+'%'},_0x33445e;})})),_0x51dfdc=_[_0x166ac9('0x33')]({},_0x51dfdc,_0xa50876[_0x166ac9('0x1c')]),_0x2be099[_0x166ac9('0x30')](_0x51dfdc);})[_0x179a06('0x36')](function(_0x2c3e08){const _0x715660=_0x179a06;if(_0x2c3e08)return _0x37d07f=_0x2c3e08[_0x715660('0x2a')],typeof _0xa50876['query'][_0x715660('0xc')]===_0x715660('0x39')&&(_0x51dfdc[_0x715660('0x0')]=qs[_0x715660('0x0')](_0xa50876[_0x715660('0xa')][_0x715660('0x0')]),_0x51dfdc[_0x715660('0x32')]=qs[_0x715660('0x32')](_0xa50876['query'][_0x715660('0x32')])),_0x2be099[_0x715660('0x30')](_0x51dfdc);})['then'](function(_0xdda92c){if(_0xdda92c)return _0xdda92c?{'count':_0x37d07f,'rows':_0xdda92c}:null;})[_0x179a06('0x36')](respondWithResult(_0x4aa6a6,null))[_0x179a06('0x17')](handleError(_0x4aa6a6,null));},exports['getTags']=function(_0x3de7d8,_0x8d7d9e){const _0x53413a=_0x243cb5;let _0x1b744f={};const _0x284275={};let _0x2efdc2,_0x41eb1b;return db[_0x53413a('0x15')][_0x53413a('0x1a')]({'where':{'id':_0x3de7d8['params']['id']}})[_0x53413a('0x36')](handleEntityNotFound(_0x8d7d9e,null))['then'](function(_0x8b28f7){const _0x35ef43=_0x53413a;if(_0x8b28f7)return _0x2efdc2=_0x8b28f7,_0x284275['model']=_[_0x35ef43('0x12')](db['Tag'][_0x35ef43('0x20')]),_0x284275[_0x35ef43('0xa')]=_['keys'](_0x3de7d8[_0x35ef43('0xa')]),_0x284275[_0x35ef43('0x22')]=_[_0x35ef43('0x34')](_0x284275['model'],_0x284275[_0x35ef43('0xa')]),_0x1b744f[_0x35ef43('0x29')]=_[_0x35ef43('0x34')](_0x284275[_0x35ef43('0x1e')],qs['fields'](_0x3de7d8[_0x35ef43('0xa')][_0x35ef43('0x18')])),_0x1b744f[_0x35ef43('0x29')]=_0x1b744f[_0x35ef43('0x29')][_0x35ef43('0x2a')]?_0x1b744f['attributes']:_0x284275['model'],_0x1b744f[_0x35ef43('0xb')]=qs[_0x35ef43('0x26')](_0x3de7d8['query'][_0x35ef43('0x26')]),_0x1b744f['where']=qs[_0x35ef43('0x22')](_[_0x35ef43('0x8')](_0x3de7d8[_0x35ef43('0xa')],_0x284275[_0x35ef43('0x22')])),_0x3de7d8[_0x35ef43('0xa')][_0x35ef43('0x16')]&&(_0x1b744f['where']=_[_0x35ef43('0x33')](_0x1b744f['where'],{[Op['or']]:_[_0x35ef43('0x25')](_0x1b744f[_0x35ef43('0x29')],function(_0x9c61fe){const _0x2f01a8=_0x35ef43,_0x137681={};return _0x137681[_0x9c61fe]={[Op[_0x2f01a8('0x24')]]:'%'+_0x3de7d8[_0x2f01a8('0xa')][_0x2f01a8('0x16')]+'%'},_0x137681;})})),_0x1b744f=_['merge']({},_0x1b744f,_0x3de7d8[_0x35ef43('0x1c')]),_0x2efdc2[_0x35ef43('0x35')](_0x1b744f);})['then'](function(_0x48d96a){const _0x5481db=_0x53413a;if(_0x48d96a)return _0x41eb1b=_0x48d96a[_0x5481db('0x2a')],typeof _0x3de7d8[_0x5481db('0xa')][_0x5481db('0xc')]==='undefined'&&(_0x1b744f[_0x5481db('0x0')]=qs[_0x5481db('0x0')](_0x3de7d8[_0x5481db('0xa')][_0x5481db('0x0')]),_0x1b744f['offset']=qs['offset'](_0x3de7d8['query'][_0x5481db('0x32')])),_0x2efdc2['getTags'](_0x1b744f);})[_0x53413a('0x36')](function(_0x326d24){if(_0x326d24)return _0x326d24?{'count':_0x41eb1b,'rows':_0x326d24}:null;})[_0x53413a('0x36')](respondWithResult(_0x8d7d9e,null))[_0x53413a('0x17')](handleError(_0x8d7d9e,null));},exports['setTags']=function(_0x2d54f2,_0x5ae3e5){const _0x5e6bd7=_0x243cb5;return _0x2d54f2[_0x5e6bd7('0xe')]['id']&&delete _0x2d54f2[_0x5e6bd7('0xe')]['id'],db[_0x5e6bd7('0x15')]['findOne']({'where':{'id':_0x2d54f2[_0x5e6bd7('0x5')]['id']}})[_0x5e6bd7('0x36')](handleEntityNotFound(_0x5ae3e5,null))[_0x5e6bd7('0x36')](function(_0xc214ad){const _0x12131d=_0x5e6bd7;if(_0xc214ad)return _0xc214ad['setTags'](_0x2d54f2[_0x12131d('0xe')][_0x12131d('0x13')]||[]);return null;})['then'](respondWithResult(_0x5ae3e5,null))[_0x5e6bd7('0x17')](handleError(_0x5ae3e5,null));}; \ No newline at end of file +const a234_0x5e8c=['findOne','then','update','../../config/logger','set','error','DeskConfiguration','map','getDescriptions','fields','stack','length','like','options','catch','where','ids','pick','body','undefined','rows','DeskField','include','destroy','send','lodash','../../mysqldb','name','query','api','getSubjects','Tag','status','index','type','sort','getTags','filters','json','getFields','offset','show','merge','create','nolimit','attributes','VIRTUAL','keys','count','setTags','params','rawAttributes','filter','sequelize','intersection','model','order','limit','findAll'];(function(_0x1b7e58,_0x5e8cc8){const _0x3861e4=function(_0x23b903){while(--_0x23b903){_0x1b7e58['push'](_0x1b7e58['shift']());}};_0x3861e4(++_0x5e8cc8);}(a234_0x5e8c,0x160));const a234_0x3861=function(_0x1b7e58,_0x5e8cc8){_0x1b7e58=_0x1b7e58-0x0;let _0x3861e4=a234_0x5e8c[_0x1b7e58];return _0x3861e4;};const _0x2465c8=a234_0x3861;'use strict';const _=require(_0x2465c8('0x1b')),qs=require('../../components/parsers/qs'),logger=require(_0x2465c8('0x5'))(_0x2465c8('0x1f')),db=require(_0x2465c8('0x1c'))['db'],{Op}=require(_0x2465c8('0x37'));function respondWithResult(_0x23b903,_0x2496d9){return _0x2496d9=_0x2496d9||0xc8,function(_0x38ddce){const _0x3c2933=a234_0x3861;if(_0x38ddce)return _0x23b903[_0x3c2933('0x22')](_0x2496d9)['json'](_0x38ddce);};}function respondWithFilteredResult(_0x277e2a,_0x3a9ac8){return function(_0x3e76cd){const _0x2a2052=a234_0x3861;if(_0x3e76cd){const _0x2ea53b=_0x3e76cd[_0x2a2052('0x32')],_0x1a414b=_0x3a9ac8[_0x2a2052('0x2a')];let _0x31c696=_0x3a9ac8[_0x2a2052('0x2a')]+_0x3a9ac8[_0x2a2052('0x0')],_0x46d579;return _0x31c696>=_0x2ea53b?(_0x31c696=_0x2ea53b,_0x46d579=0xc8):_0x46d579=0xce,_0x277e2a[_0x2a2052('0x22')](_0x46d579),_0x277e2a[_0x2a2052('0x6')]('Content-Range',_0x1a414b+'-'+_0x31c696+'/'+_0x2ea53b)[_0x2a2052('0x28')](_0x3e76cd);}return null;};}function saveUpdates(_0x480041){return function(_0x113976){const _0x254e2c=a234_0x3861;if(_0x113976)return _0x113976[_0x254e2c('0x4')](_0x480041)[_0x254e2c('0x3')](function(_0x3a11be){return _0x3a11be;});return null;};}function removeEntity(_0x129389){return function(_0x242df4){const _0x4eeea2=a234_0x3861;if(_0x242df4)return _0x242df4[_0x4eeea2('0x19')]()['then'](function(){const _0x26b25c=_0x4eeea2;_0x129389[_0x26b25c('0x22')](0xcc)['end']();});};}function handleEntityNotFound(_0xa2a076){return function(_0x39fc6e){return!_0x39fc6e&&_0xa2a076['sendStatus'](0x194),_0x39fc6e;};}function handleError(_0x7d2e9d,_0x511299){return _0x511299=_0x511299||0x1f4,function(_0x3905d7){const _0x4f7e32=a234_0x3861;logger[_0x4f7e32('0x7')](_0x3905d7[_0x4f7e32('0xc')]),_0x3905d7[_0x4f7e32('0x1d')]&&delete _0x3905d7[_0x4f7e32('0x1d')],_0x7d2e9d[_0x4f7e32('0x22')](_0x511299)[_0x4f7e32('0x1a')](_0x3905d7);};}exports[_0x2465c8('0x23')]=function(_0x40beb5,_0x3adcb6){const _0x212d46=_0x2465c8;let _0x24595e={};const _0x5dcba8={},_0x4819b0={'count':0x0,'rows':[]},_0x22e32f=_[_0x212d46('0x9')](db[_0x212d46('0x8')][_0x212d46('0x35')],function(_0x5247ad){const _0x10f768=_0x212d46;return{'name':_0x5247ad['fieldName'],'type':_0x5247ad[_0x10f768('0x24')]['key']};});_0x5dcba8[_0x212d46('0x39')]=_[_0x212d46('0x9')](_0x22e32f,'name'),_0x5dcba8[_0x212d46('0x1e')]=_[_0x212d46('0x31')](_0x40beb5['query']),_0x5dcba8[_0x212d46('0x27')]=_[_0x212d46('0x38')](_0x5dcba8[_0x212d46('0x39')],_0x5dcba8[_0x212d46('0x1e')]),_0x24595e[_0x212d46('0x2f')]=_['intersection'](_0x5dcba8['model'],qs['fields'](_0x40beb5[_0x212d46('0x1e')][_0x212d46('0xb')])),_0x24595e[_0x212d46('0x2f')]=_0x24595e[_0x212d46('0x2f')][_0x212d46('0xd')]?_0x24595e['attributes']:_0x5dcba8[_0x212d46('0x39')];typeof _0x40beb5[_0x212d46('0x1e')][_0x212d46('0x2e')]==='undefined'&&(_0x24595e[_0x212d46('0x0')]=qs[_0x212d46('0x0')](_0x40beb5[_0x212d46('0x1e')]['limit']),_0x24595e[_0x212d46('0x2a')]=qs['offset'](_0x40beb5[_0x212d46('0x1e')][_0x212d46('0x2a')]));_0x24595e[_0x212d46('0x3a')]=qs['sort'](_0x40beb5[_0x212d46('0x1e')][_0x212d46('0x25')]),_0x24595e['where']=qs[_0x212d46('0x27')](_[_0x212d46('0x13')](_0x40beb5[_0x212d46('0x1e')],_0x5dcba8[_0x212d46('0x27')]),_0x22e32f);_0x40beb5[_0x212d46('0x1e')][_0x212d46('0x36')]&&(_0x24595e['where']=_[_0x212d46('0x2c')](_0x24595e[_0x212d46('0x11')],{[Op['or']]:_[_0x212d46('0x9')](_0x22e32f,function(_0x55325b){const _0x5b1613=_0x212d46;if(_0x55325b[_0x5b1613('0x24')]!==_0x5b1613('0x30')){const _0xb239cb={};return _0xb239cb[_0x55325b[_0x5b1613('0x1d')]]={[Op[_0x5b1613('0xe')]]:'%'+_0x40beb5[_0x5b1613('0x1e')][_0x5b1613('0x36')]+'%'},_0xb239cb;}})}));_0x24595e=_[_0x212d46('0x2c')]({},_0x24595e,_0x40beb5[_0x212d46('0xf')]);const _0x2b810d={'where':_0x24595e[_0x212d46('0x11')]};return db[_0x212d46('0x8')]['count'](_0x2b810d)[_0x212d46('0x3')](function(_0x2251fb){const _0x212e4f=_0x212d46;return _0x4819b0[_0x212e4f('0x32')]=_0x2251fb,_0x40beb5['query']['includeAll']&&(_0x24595e[_0x212e4f('0x18')]=[{'all':!![]}]),db[_0x212e4f('0x8')][_0x212e4f('0x1')](_0x24595e);})[_0x212d46('0x3')](function(_0xa4a272){const _0x44b682=_0x212d46;return _0x4819b0[_0x44b682('0x16')]=_0xa4a272,_0x4819b0;})[_0x212d46('0x3')](respondWithFilteredResult(_0x3adcb6,_0x24595e))[_0x212d46('0x10')](handleError(_0x3adcb6,null));},exports[_0x2465c8('0x2b')]=function(_0x2ace7e,_0x34b0eb){const _0x2d4e4e=_0x2465c8;let _0x216a85={'raw':![],'where':{'id':_0x2ace7e[_0x2d4e4e('0x34')]['id']}};const _0x4fa4d9={};return _0x4fa4d9[_0x2d4e4e('0x39')]=_[_0x2d4e4e('0x31')](db[_0x2d4e4e('0x8')][_0x2d4e4e('0x35')]),_0x4fa4d9[_0x2d4e4e('0x1e')]=_[_0x2d4e4e('0x31')](_0x2ace7e[_0x2d4e4e('0x1e')]),_0x4fa4d9['filters']=_[_0x2d4e4e('0x38')](_0x4fa4d9['model'],_0x4fa4d9[_0x2d4e4e('0x1e')]),_0x216a85['attributes']=_['intersection'](_0x4fa4d9['model'],qs[_0x2d4e4e('0xb')](_0x2ace7e[_0x2d4e4e('0x1e')][_0x2d4e4e('0xb')])),_0x216a85['attributes']=_0x216a85['attributes'][_0x2d4e4e('0xd')]?_0x216a85[_0x2d4e4e('0x2f')]:_0x4fa4d9[_0x2d4e4e('0x39')],_0x2ace7e[_0x2d4e4e('0x1e')]['includeAll']&&(_0x216a85[_0x2d4e4e('0x18')]=[{'all':!![]}]),_0x216a85=_['merge']({},_0x216a85,_0x2ace7e[_0x2d4e4e('0xf')]),db[_0x2d4e4e('0x8')][_0x2d4e4e('0x2')](_0x216a85)[_0x2d4e4e('0x3')](handleEntityNotFound(_0x34b0eb,null))['then'](respondWithResult(_0x34b0eb,null))[_0x2d4e4e('0x10')](handleError(_0x34b0eb,null));},exports[_0x2465c8('0x2d')]=function(_0x410fd7,_0x144acf){const _0x3bcbb5=_0x2465c8;return db[_0x3bcbb5('0x8')][_0x3bcbb5('0x2d')](_0x410fd7[_0x3bcbb5('0x14')],{})['then'](respondWithResult(_0x144acf,0xc9))[_0x3bcbb5('0x10')](handleError(_0x144acf,null));},exports[_0x2465c8('0x4')]=function(_0xd5d620,_0x48d44f){const _0x135103=_0x2465c8;return _0xd5d620['body']['id']&&delete _0xd5d620[_0x135103('0x14')]['id'],db[_0x135103('0x8')][_0x135103('0x2')]({'where':{'id':_0xd5d620['params']['id']}})[_0x135103('0x3')](handleEntityNotFound(_0x48d44f,null))['then'](saveUpdates(_0xd5d620[_0x135103('0x14')],null))[_0x135103('0x3')](respondWithResult(_0x48d44f,null))[_0x135103('0x10')](handleError(_0x48d44f,null));},exports[_0x2465c8('0x19')]=function(_0x66a59f,_0x386156){const _0x159e5a=_0x2465c8;return db[_0x159e5a('0x8')][_0x159e5a('0x2')]({'where':{'id':_0x66a59f[_0x159e5a('0x34')]['id']}})[_0x159e5a('0x3')](handleEntityNotFound(_0x386156,null))[_0x159e5a('0x3')](removeEntity(_0x386156,null))['catch'](handleError(_0x386156,null));},exports[_0x2465c8('0x29')]=function(_0x2a325c,_0xbea9eb){const _0x3d706b=_0x2465c8;let _0x110d00={};const _0x5c369f={};let _0x1a4a8f,_0x58a4b8;return db['DeskConfiguration']['findOne']({'where':{'id':_0x2a325c['params']['id']}})[_0x3d706b('0x3')](handleEntityNotFound(_0xbea9eb,null))[_0x3d706b('0x3')](function(_0x17a15a){const _0x385dda=_0x3d706b;if(_0x17a15a)return _0x1a4a8f=_0x17a15a,_0x5c369f[_0x385dda('0x39')]=_[_0x385dda('0x31')](db['DeskField']['rawAttributes']),_0x5c369f[_0x385dda('0x1e')]=_[_0x385dda('0x31')](_0x2a325c[_0x385dda('0x1e')]),_0x5c369f[_0x385dda('0x27')]=_['intersection'](_0x5c369f[_0x385dda('0x39')],_0x5c369f[_0x385dda('0x1e')]),_0x110d00['attributes']=_[_0x385dda('0x38')](_0x5c369f[_0x385dda('0x39')],qs['fields'](_0x2a325c['query']['fields'])),_0x110d00[_0x385dda('0x2f')]=_0x110d00[_0x385dda('0x2f')][_0x385dda('0xd')]?_0x110d00[_0x385dda('0x2f')]:_0x5c369f[_0x385dda('0x39')],_0x110d00[_0x385dda('0x3a')]=qs[_0x385dda('0x25')](_0x2a325c[_0x385dda('0x1e')][_0x385dda('0x25')]),_0x110d00[_0x385dda('0x11')]=qs[_0x385dda('0x27')](_[_0x385dda('0x13')](_0x2a325c[_0x385dda('0x1e')],_0x5c369f[_0x385dda('0x27')])),_0x2a325c[_0x385dda('0x1e')][_0x385dda('0x36')]&&(_0x110d00[_0x385dda('0x11')]=_['merge'](_0x110d00['where'],{[Op['or']]:_[_0x385dda('0x9')](_0x110d00['attributes'],function(_0x34969b){const _0x47edd7=_0x385dda,_0x2fd319={};return _0x2fd319[_0x34969b]={[Op[_0x47edd7('0xe')]]:'%'+_0x2a325c[_0x47edd7('0x1e')][_0x47edd7('0x36')]+'%'},_0x2fd319;})})),_0x110d00=_['merge']({},_0x110d00,_0x2a325c[_0x385dda('0xf')]),_0x1a4a8f[_0x385dda('0x29')](_0x110d00);})[_0x3d706b('0x3')](function(_0x4b1633){const _0x371778=_0x3d706b;if(_0x4b1633)return _0x58a4b8=_0x4b1633[_0x371778('0xd')],typeof _0x2a325c[_0x371778('0x1e')][_0x371778('0x2e')]===_0x371778('0x15')&&(_0x110d00[_0x371778('0x0')]=qs['limit'](_0x2a325c[_0x371778('0x1e')]['limit']),_0x110d00[_0x371778('0x2a')]=qs[_0x371778('0x2a')](_0x2a325c['query'][_0x371778('0x2a')])),_0x1a4a8f[_0x371778('0x29')](_0x110d00);})[_0x3d706b('0x3')](function(_0x2ff7ad){if(_0x2ff7ad)return _0x2ff7ad?{'count':_0x58a4b8,'rows':_0x2ff7ad}:null;})['then'](respondWithResult(_0xbea9eb,null))['catch'](handleError(_0xbea9eb,null));},exports[_0x2465c8('0x20')]=function(_0x271096,_0x1acfd7){const _0x31797e=_0x2465c8;let _0x3dccf2={};const _0x5ba20a={};let _0x2bfede,_0x4abae6;return db[_0x31797e('0x8')]['findOne']({'where':{'id':_0x271096[_0x31797e('0x34')]['id']}})['then'](handleEntityNotFound(_0x1acfd7,null))[_0x31797e('0x3')](function(_0x3d95c3){const _0x18d015=_0x31797e;if(_0x3d95c3)return _0x2bfede=_0x3d95c3,_0x5ba20a[_0x18d015('0x39')]=_[_0x18d015('0x31')](db[_0x18d015('0x17')][_0x18d015('0x35')]),_0x5ba20a['query']=_[_0x18d015('0x31')](_0x271096['query']),_0x5ba20a[_0x18d015('0x27')]=_[_0x18d015('0x38')](_0x5ba20a['model'],_0x5ba20a['query']),_0x3dccf2['attributes']=_[_0x18d015('0x38')](_0x5ba20a['model'],qs['fields'](_0x271096['query']['fields'])),_0x3dccf2[_0x18d015('0x2f')]=_0x3dccf2[_0x18d015('0x2f')][_0x18d015('0xd')]?_0x3dccf2[_0x18d015('0x2f')]:_0x5ba20a['model'],_0x3dccf2[_0x18d015('0x3a')]=qs[_0x18d015('0x25')](_0x271096[_0x18d015('0x1e')][_0x18d015('0x25')]),_0x3dccf2['where']=qs[_0x18d015('0x27')](_['pick'](_0x271096[_0x18d015('0x1e')],_0x5ba20a['filters'])),_0x271096['query'][_0x18d015('0x36')]&&(_0x3dccf2['where']=_['merge'](_0x3dccf2[_0x18d015('0x11')],{[Op['or']]:_['map'](_0x3dccf2['attributes'],function(_0x55abee){const _0x393185=_0x18d015,_0x33d032={};return _0x33d032[_0x55abee]={[Op[_0x393185('0xe')]]:'%'+_0x271096[_0x393185('0x1e')][_0x393185('0x36')]+'%'},_0x33d032;})})),_0x3dccf2=_[_0x18d015('0x2c')]({},_0x3dccf2,_0x271096[_0x18d015('0xf')]),_0x2bfede[_0x18d015('0x20')](_0x3dccf2);})[_0x31797e('0x3')](function(_0x678608){const _0x16c9ef=_0x31797e;if(_0x678608)return _0x4abae6=_0x678608[_0x16c9ef('0xd')],typeof _0x271096[_0x16c9ef('0x1e')][_0x16c9ef('0x2e')]==='undefined'&&(_0x3dccf2['limit']=qs['limit'](_0x271096[_0x16c9ef('0x1e')]['limit']),_0x3dccf2['offset']=qs[_0x16c9ef('0x2a')](_0x271096[_0x16c9ef('0x1e')][_0x16c9ef('0x2a')])),_0x2bfede[_0x16c9ef('0x20')](_0x3dccf2);})[_0x31797e('0x3')](function(_0x40ab01){if(_0x40ab01)return _0x40ab01?{'count':_0x4abae6,'rows':_0x40ab01}:null;})[_0x31797e('0x3')](respondWithResult(_0x1acfd7,null))[_0x31797e('0x10')](handleError(_0x1acfd7,null));},exports[_0x2465c8('0xa')]=function(_0x49b45e,_0x1db470){const _0xba3923=_0x2465c8;let _0x40e3fd={};const _0x50b55b={};let _0x19ec44,_0x1d4cbd;return db[_0xba3923('0x8')][_0xba3923('0x2')]({'where':{'id':_0x49b45e[_0xba3923('0x34')]['id']}})[_0xba3923('0x3')](handleEntityNotFound(_0x1db470,null))[_0xba3923('0x3')](function(_0xff08b){const _0x43d48b=_0xba3923;if(_0xff08b)return _0x19ec44=_0xff08b,_0x50b55b[_0x43d48b('0x39')]=_[_0x43d48b('0x31')](db[_0x43d48b('0x17')][_0x43d48b('0x35')]),_0x50b55b[_0x43d48b('0x1e')]=_[_0x43d48b('0x31')](_0x49b45e[_0x43d48b('0x1e')]),_0x50b55b['filters']=_['intersection'](_0x50b55b[_0x43d48b('0x39')],_0x50b55b[_0x43d48b('0x1e')]),_0x40e3fd[_0x43d48b('0x2f')]=_[_0x43d48b('0x38')](_0x50b55b[_0x43d48b('0x39')],qs[_0x43d48b('0xb')](_0x49b45e['query'][_0x43d48b('0xb')])),_0x40e3fd[_0x43d48b('0x2f')]=_0x40e3fd[_0x43d48b('0x2f')][_0x43d48b('0xd')]?_0x40e3fd[_0x43d48b('0x2f')]:_0x50b55b['model'],_0x40e3fd['order']=qs[_0x43d48b('0x25')](_0x49b45e[_0x43d48b('0x1e')]['sort']),_0x40e3fd['where']=qs[_0x43d48b('0x27')](_['pick'](_0x49b45e[_0x43d48b('0x1e')],_0x50b55b[_0x43d48b('0x27')])),_0x49b45e['query'][_0x43d48b('0x36')]&&(_0x40e3fd['where']=_['merge'](_0x40e3fd['where'],{[Op['or']]:_[_0x43d48b('0x9')](_0x40e3fd[_0x43d48b('0x2f')],function(_0x329a56){const _0x25e67a=_0x43d48b,_0x398908={};return _0x398908[_0x329a56]={[Op['like']]:'%'+_0x49b45e[_0x25e67a('0x1e')]['filter']+'%'},_0x398908;})})),_0x40e3fd=_[_0x43d48b('0x2c')]({},_0x40e3fd,_0x49b45e[_0x43d48b('0xf')]),_0x19ec44[_0x43d48b('0xa')](_0x40e3fd);})['then'](function(_0x2c1273){const _0x287588=_0xba3923;if(_0x2c1273)return _0x1d4cbd=_0x2c1273['length'],typeof _0x49b45e[_0x287588('0x1e')][_0x287588('0x2e')]===_0x287588('0x15')&&(_0x40e3fd['limit']=qs[_0x287588('0x0')](_0x49b45e[_0x287588('0x1e')]['limit']),_0x40e3fd['offset']=qs[_0x287588('0x2a')](_0x49b45e[_0x287588('0x1e')][_0x287588('0x2a')])),_0x19ec44[_0x287588('0xa')](_0x40e3fd);})[_0xba3923('0x3')](function(_0x4b175b){if(_0x4b175b)return _0x4b175b?{'count':_0x1d4cbd,'rows':_0x4b175b}:null;})['then'](respondWithResult(_0x1db470,null))[_0xba3923('0x10')](handleError(_0x1db470,null));},exports['getTags']=function(_0x5416ce,_0x629608){const _0x1b4c85=_0x2465c8;let _0x1ee0cc={};const _0x13aaa1={};let _0x1b850f,_0x2513e7;return db['DeskConfiguration'][_0x1b4c85('0x2')]({'where':{'id':_0x5416ce[_0x1b4c85('0x34')]['id']}})[_0x1b4c85('0x3')](handleEntityNotFound(_0x629608,null))[_0x1b4c85('0x3')](function(_0x3eab69){const _0x1e58f0=_0x1b4c85;if(_0x3eab69)return _0x1b850f=_0x3eab69,_0x13aaa1[_0x1e58f0('0x39')]=_[_0x1e58f0('0x31')](db[_0x1e58f0('0x21')][_0x1e58f0('0x35')]),_0x13aaa1['query']=_[_0x1e58f0('0x31')](_0x5416ce[_0x1e58f0('0x1e')]),_0x13aaa1['filters']=_[_0x1e58f0('0x38')](_0x13aaa1[_0x1e58f0('0x39')],_0x13aaa1['query']),_0x1ee0cc[_0x1e58f0('0x2f')]=_['intersection'](_0x13aaa1[_0x1e58f0('0x39')],qs[_0x1e58f0('0xb')](_0x5416ce[_0x1e58f0('0x1e')]['fields'])),_0x1ee0cc['attributes']=_0x1ee0cc[_0x1e58f0('0x2f')]['length']?_0x1ee0cc['attributes']:_0x13aaa1[_0x1e58f0('0x39')],_0x1ee0cc[_0x1e58f0('0x3a')]=qs[_0x1e58f0('0x25')](_0x5416ce[_0x1e58f0('0x1e')][_0x1e58f0('0x25')]),_0x1ee0cc[_0x1e58f0('0x11')]=qs[_0x1e58f0('0x27')](_[_0x1e58f0('0x13')](_0x5416ce[_0x1e58f0('0x1e')],_0x13aaa1[_0x1e58f0('0x27')])),_0x5416ce[_0x1e58f0('0x1e')]['filter']&&(_0x1ee0cc[_0x1e58f0('0x11')]=_['merge'](_0x1ee0cc[_0x1e58f0('0x11')],{[Op['or']]:_[_0x1e58f0('0x9')](_0x1ee0cc[_0x1e58f0('0x2f')],function(_0x243f4){const _0x10fab0=_0x1e58f0,_0x4ab6e7={};return _0x4ab6e7[_0x243f4]={[Op['like']]:'%'+_0x5416ce[_0x10fab0('0x1e')][_0x10fab0('0x36')]+'%'},_0x4ab6e7;})})),_0x1ee0cc=_[_0x1e58f0('0x2c')]({},_0x1ee0cc,_0x5416ce[_0x1e58f0('0xf')]),_0x1b850f[_0x1e58f0('0x26')](_0x1ee0cc);})[_0x1b4c85('0x3')](function(_0x66d3bc){const _0x3a31ab=_0x1b4c85;if(_0x66d3bc)return _0x2513e7=_0x66d3bc[_0x3a31ab('0xd')],typeof _0x5416ce[_0x3a31ab('0x1e')]['nolimit']===_0x3a31ab('0x15')&&(_0x1ee0cc['limit']=qs[_0x3a31ab('0x0')](_0x5416ce[_0x3a31ab('0x1e')][_0x3a31ab('0x0')]),_0x1ee0cc['offset']=qs[_0x3a31ab('0x2a')](_0x5416ce[_0x3a31ab('0x1e')][_0x3a31ab('0x2a')])),_0x1b850f[_0x3a31ab('0x26')](_0x1ee0cc);})[_0x1b4c85('0x3')](function(_0x5dfc2){if(_0x5dfc2)return _0x5dfc2?{'count':_0x2513e7,'rows':_0x5dfc2}:null;})['then'](respondWithResult(_0x629608,null))[_0x1b4c85('0x10')](handleError(_0x629608,null));},exports[_0x2465c8('0x33')]=function(_0x2442ab,_0x4b83f6){const _0x30b1ab=_0x2465c8;return _0x2442ab[_0x30b1ab('0x14')]['id']&&delete _0x2442ab['body']['id'],db[_0x30b1ab('0x8')][_0x30b1ab('0x2')]({'where':{'id':_0x2442ab[_0x30b1ab('0x34')]['id']}})[_0x30b1ab('0x3')](handleEntityNotFound(_0x4b83f6,null))[_0x30b1ab('0x3')](function(_0x3099d4){const _0x1974e0=_0x30b1ab;if(_0x3099d4)return _0x3099d4[_0x1974e0('0x33')](_0x2442ab[_0x1974e0('0x14')][_0x1974e0('0x12')]||[]);return null;})[_0x30b1ab('0x3')](respondWithResult(_0x4b83f6,null))[_0x30b1ab('0x10')](handleError(_0x4b83f6,null));}; \ No newline at end of file diff --git a/server/api/intDeskConfiguration/intDeskConfiguration.model.js b/server/api/intDeskConfiguration/intDeskConfiguration.model.js index 7997c6e..bf1e08c 100644 --- a/server/api/intDeskConfiguration/intDeskConfiguration.model.js +++ b/server/api/intDeskConfiguration/intDeskConfiguration.model.js @@ -1 +1 @@ -const a235_0x2a7c=['DeskConfiguration','./intDeskConfiguration.attributes','exports','define','int_desk_configurations'];(function(_0x1f50f6,_0x2a7cd8){const _0x351eaf=function(_0xc0ddb){while(--_0xc0ddb){_0x1f50f6['push'](_0x1f50f6['shift']());}};_0x351eaf(++_0x2a7cd8);}(a235_0x2a7c,0x1a4));const a235_0x351e=function(_0x1f50f6,_0x2a7cd8){_0x1f50f6=_0x1f50f6-0x0;let _0x351eaf=a235_0x2a7c[_0x1f50f6];return _0x351eaf;};const _0x549e55=a235_0x351e;'use strict';const attributes=require(_0x549e55('0x1'));module[_0x549e55('0x2')]=function(_0xc0ddb){const _0x320129=_0x549e55,_0x24b2e3=_0xc0ddb[_0x320129('0x3')](_0x320129('0x0'),attributes,{'tableName':_0x320129('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x24b2e3;}; \ No newline at end of file +const a235_0x156d=['DeskConfiguration','./intDeskConfiguration.attributes'];(function(_0x5574c9,_0x156d2d){const _0x47143a=function(_0x2ff4f7){while(--_0x2ff4f7){_0x5574c9['push'](_0x5574c9['shift']());}};_0x47143a(++_0x156d2d);}(a235_0x156d,0x106));const a235_0x4714=function(_0x5574c9,_0x156d2d){_0x5574c9=_0x5574c9-0x0;let _0x47143a=a235_0x156d[_0x5574c9];return _0x47143a;};const _0x33881c=a235_0x4714;'use strict';const attributes=require(_0x33881c('0x1'));module['exports']=function(_0x2ff4f7){const _0x54ae4d=_0x33881c,_0x87b079=_0x2ff4f7['define'](_0x54ae4d('0x0'),attributes,{'tableName':'int_desk_configurations','paranoid':![],'indexes':[],'timestamps':!![]});return _0x87b079;}; \ No newline at end of file diff --git a/server/api/intDeskField/index.js b/server/api/intDeskField/index.js index f9d4726..55eea94 100644 --- a/server/api/intDeskField/index.js +++ b/server/api/intDeskField/index.js @@ -1 +1 @@ -const a236_0x3398=['delete','./intDeskField.controller','create','isAuthenticated','destroy','show','/:id','express','get','Router','../../components/auth/service'];(function(_0x18a7d3,_0x339822){const _0x1026ad=function(_0x2be6f4){while(--_0x2be6f4){_0x18a7d3['push'](_0x18a7d3['shift']());}};_0x1026ad(++_0x339822);}(a236_0x3398,0x90));const a236_0x1026=function(_0x18a7d3,_0x339822){_0x18a7d3=_0x18a7d3-0x0;let _0x1026ad=a236_0x3398[_0x18a7d3];return _0x1026ad;};const _0x470296=a236_0x1026;'use strict';const express=require(_0x470296('0x6')),router=express[_0x470296('0x8')](),auth=require(_0x470296('0x9')),controller=require(_0x470296('0x0'));router[_0x470296('0x7')]('/',auth['isAuthenticated'](),controller['index']),router[_0x470296('0x7')](_0x470296('0x5'),auth['isAuthenticated'](),controller[_0x470296('0x4')]),router['post']('/',auth[_0x470296('0x2')](),controller[_0x470296('0x1')]),router['put'](_0x470296('0x5'),auth[_0x470296('0x2')](),controller['update']),router[_0x470296('0xa')]('/:id',auth[_0x470296('0x2')](),controller[_0x470296('0x3')]),module['exports']=router; \ No newline at end of file +const a236_0x4ef1=['get','update','post','Router','index','exports','/:id','show','../../components/auth/service','isAuthenticated','./intDeskField.controller','express','put'];(function(_0x56d04e,_0x4ef136){const _0x204c52=function(_0xc0c036){while(--_0xc0c036){_0x56d04e['push'](_0x56d04e['shift']());}};_0x204c52(++_0x4ef136);}(a236_0x4ef1,0x8a));const a236_0x204c=function(_0x56d04e,_0x4ef136){_0x56d04e=_0x56d04e-0x0;let _0x204c52=a236_0x4ef1[_0x56d04e];return _0x204c52;};const _0x378506=a236_0x204c;'use strict';const express=require(_0x378506('0x3')),router=express[_0x378506('0x8')](),auth=require(_0x378506('0x0')),controller=require(_0x378506('0x2'));router[_0x378506('0x5')]('/',auth[_0x378506('0x1')](),controller[_0x378506('0x9')]),router[_0x378506('0x5')](_0x378506('0xb'),auth[_0x378506('0x1')](),controller[_0x378506('0xc')]),router[_0x378506('0x7')]('/',auth[_0x378506('0x1')](),controller['create']),router[_0x378506('0x4')]('/:id',auth['isAuthenticated'](),controller[_0x378506('0x6')]),router['delete']('/:id',auth[_0x378506('0x1')](),controller['destroy']),module[_0x378506('0xa')]=router; \ No newline at end of file diff --git a/server/api/intDeskField/intDeskField.attributes.js b/server/api/intDeskField/intDeskField.attributes.js index 164ec51..69ca04e 100644 --- a/server/api/intDeskField/intDeskField.attributes.js +++ b/server/api/intDeskField/intDeskField.attributes.js @@ -1 +1 @@ -const a237_0x31b1=['exports','variable','sequelize','keyValue','string','STRING','customVariable','ENUM'];(function(_0xc9fd58,_0x31b12c){const _0x4d4fde=function(_0x7a1dc4){while(--_0x7a1dc4){_0xc9fd58['push'](_0xc9fd58['shift']());}};_0x4d4fde(++_0x31b12c);}(a237_0x31b1,0x144));const a237_0x4d4f=function(_0xc9fd58,_0x31b12c){_0xc9fd58=_0xc9fd58-0x0;let _0x4d4fde=a237_0x31b1[_0xc9fd58];return _0x4d4fde;};const _0xb535e=a237_0x4d4f;'use strict';const Sequelize=require(_0xb535e('0x6'));module[_0xb535e('0x4')]={'type':{'type':Sequelize[_0xb535e('0x3')](_0xb535e('0x0'),_0xb535e('0x5'),'customVariable',_0xb535e('0x7')),'defaultValue':_0xb535e('0x0')},'content':{'type':Sequelize[_0xb535e('0x1')]},'key':{'type':Sequelize[_0xb535e('0x1')]},'keyType':{'type':Sequelize[_0xb535e('0x3')](_0xb535e('0x0'),'variable',_0xb535e('0x2'))},'keyContent':{'type':Sequelize[_0xb535e('0x1')]},'idField':{'type':Sequelize[_0xb535e('0x1')]},'nameField':{'type':Sequelize['STRING']},'customField':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'variableName':{'type':Sequelize[_0xb535e('0x1')]}}; \ No newline at end of file +const a237_0x1edb=['ENUM','STRING','BOOLEAN','customVariable','variable','sequelize'];(function(_0xeaf0fb,_0x1edbeb){const _0xc52f24=function(_0x1aa817){while(--_0x1aa817){_0xeaf0fb['push'](_0xeaf0fb['shift']());}};_0xc52f24(++_0x1edbeb);}(a237_0x1edb,0x1a0));const a237_0xc52f=function(_0xeaf0fb,_0x1edbeb){_0xeaf0fb=_0xeaf0fb-0x0;let _0xc52f24=a237_0x1edb[_0xeaf0fb];return _0xc52f24;};const _0x12edd8=a237_0xc52f;'use strict';const Sequelize=require(_0x12edd8('0x3'));module['exports']={'type':{'type':Sequelize[_0x12edd8('0x4')]('string',_0x12edd8('0x2'),_0x12edd8('0x1'),'keyValue'),'defaultValue':'string'},'content':{'type':Sequelize[_0x12edd8('0x5')]},'key':{'type':Sequelize[_0x12edd8('0x5')]},'keyType':{'type':Sequelize[_0x12edd8('0x4')]('string',_0x12edd8('0x2'),_0x12edd8('0x1'))},'keyContent':{'type':Sequelize[_0x12edd8('0x5')]},'idField':{'type':Sequelize[_0x12edd8('0x5')]},'nameField':{'type':Sequelize['STRING']},'customField':{'type':Sequelize[_0x12edd8('0x0')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x12edd8('0x5')]}}; \ No newline at end of file diff --git a/server/api/intDeskField/intDeskField.controller.js b/server/api/intDeskField/intDeskField.controller.js index 1574578..e9c52b3 100644 --- a/server/api/intDeskField/intDeskField.controller.js +++ b/server/api/intDeskField/intDeskField.controller.js @@ -1 +1 @@ -const a238_0xfd6e=['body','send','undefined','params','create','destroy','then','query','intersection','nolimit','where','VIRTUAL','json','lodash','type','sendStatus','api','pick','../../mysqldb','like','set','filter','catch','attributes','../../components/parsers/qs','count','map','DeskField','fieldName','includeAll','stack','sequelize','options','rows','Content-Range','keys','model','findAll','sort','../../config/logger','include','status','index','length','filters','name','offset','show','limit','merge','order','rawAttributes','fields'];(function(_0x158024,_0xfd6e0){const _0x2fe38=function(_0x20c7db){while(--_0x20c7db){_0x158024['push'](_0x158024['shift']());}};_0x2fe38(++_0xfd6e0);}(a238_0xfd6e,0x165));const a238_0x2fe3=function(_0x158024,_0xfd6e0){_0x158024=_0x158024-0x0;let _0x2fe38=a238_0xfd6e[_0x158024];return _0x2fe38;};const _0x5a19db=a238_0x2fe3;'use strict';const _=require(_0x5a19db('0x1b')),qs=require(_0x5a19db('0x26')),logger=require(_0x5a19db('0x0'))(_0x5a19db('0x1e')),db=require(_0x5a19db('0x20'))['db'],{Op}=require(_0x5a19db('0x2d'));function respondWithResult(_0x20c7db,_0x41eea9){return _0x41eea9=_0x41eea9||0xc8,function(_0x217dc9){const _0x4cc78a=a238_0x2fe3;if(_0x217dc9)return _0x20c7db[_0x4cc78a('0x2')](_0x41eea9)[_0x4cc78a('0x1a')](_0x217dc9);};}function respondWithFilteredResult(_0x2054ce,_0x54aa04){return function(_0x4bc7fb){const _0x26b457=a238_0x2fe3;if(_0x4bc7fb){const _0x5ba85a=_0x4bc7fb['count'],_0x527a72=_0x54aa04['offset'];let _0x5c383d=_0x54aa04['offset']+_0x54aa04['limit'],_0x541485;return _0x5c383d>=_0x5ba85a?(_0x5c383d=_0x5ba85a,_0x541485=0xc8):_0x541485=0xce,_0x2054ce[_0x26b457('0x2')](_0x541485),_0x2054ce[_0x26b457('0x22')](_0x26b457('0x30'),_0x527a72+'-'+_0x5c383d+'/'+_0x5ba85a)[_0x26b457('0x1a')](_0x4bc7fb);}return null;};}function saveUpdates(_0x47dbdb){return function(_0x5d3a73){const _0x26d524=a238_0x2fe3;if(_0x5d3a73)return _0x5d3a73['update'](_0x47dbdb)[_0x26d524('0x14')](function(_0x4c9f08){return _0x4c9f08;});return null;};}function removeEntity(_0xb37a94){return function(_0x22c923){const _0x58786f=a238_0x2fe3;if(_0x22c923)return _0x22c923[_0x58786f('0x13')]()['then'](function(){_0xb37a94['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x4f12f1){return function(_0x36464f){const _0x460a39=a238_0x2fe3;return!_0x36464f&&_0x4f12f1[_0x460a39('0x1d')](0x194),_0x36464f;};}function handleError(_0x1e454f,_0x357a06){return _0x357a06=_0x357a06||0x1f4,function(_0x21d79f){const _0x5ab0fa=a238_0x2fe3;logger['error'](_0x21d79f[_0x5ab0fa('0x2c')]),_0x21d79f[_0x5ab0fa('0x6')]&&delete _0x21d79f[_0x5ab0fa('0x6')],_0x1e454f[_0x5ab0fa('0x2')](_0x357a06)[_0x5ab0fa('0xf')](_0x21d79f);};}exports[_0x5a19db('0x3')]=function(_0x578953,_0x3162c9){const _0x5d459e=_0x5a19db;let _0x2ce05f={};const _0x218afb={},_0x4d39f5={'count':0x0,'rows':[]},_0x255e03=_[_0x5d459e('0x28')](db['DeskField'][_0x5d459e('0xc')],function(_0x508dd1){const _0x254974=_0x5d459e;return{'name':_0x508dd1[_0x254974('0x2a')],'type':_0x508dd1[_0x254974('0x1c')]['key']};});_0x218afb[_0x5d459e('0x32')]=_[_0x5d459e('0x28')](_0x255e03,_0x5d459e('0x6')),_0x218afb['query']=_[_0x5d459e('0x31')](_0x578953[_0x5d459e('0x15')]),_0x218afb[_0x5d459e('0x5')]=_['intersection'](_0x218afb[_0x5d459e('0x32')],_0x218afb['query']),_0x2ce05f[_0x5d459e('0x25')]=_[_0x5d459e('0x16')](_0x218afb[_0x5d459e('0x32')],qs['fields'](_0x578953[_0x5d459e('0x15')][_0x5d459e('0xd')])),_0x2ce05f[_0x5d459e('0x25')]=_0x2ce05f['attributes'][_0x5d459e('0x4')]?_0x2ce05f['attributes']:_0x218afb[_0x5d459e('0x32')];typeof _0x578953[_0x5d459e('0x15')][_0x5d459e('0x17')]===_0x5d459e('0x10')&&(_0x2ce05f[_0x5d459e('0x9')]=qs[_0x5d459e('0x9')](_0x578953[_0x5d459e('0x15')][_0x5d459e('0x9')]),_0x2ce05f['offset']=qs['offset'](_0x578953['query'][_0x5d459e('0x7')]));_0x2ce05f[_0x5d459e('0xb')]=qs[_0x5d459e('0x34')](_0x578953[_0x5d459e('0x15')][_0x5d459e('0x34')]),_0x2ce05f[_0x5d459e('0x18')]=qs[_0x5d459e('0x5')](_[_0x5d459e('0x1f')](_0x578953[_0x5d459e('0x15')],_0x218afb['filters']),_0x255e03);_0x578953[_0x5d459e('0x15')][_0x5d459e('0x23')]&&(_0x2ce05f[_0x5d459e('0x18')]=_[_0x5d459e('0xa')](_0x2ce05f['where'],{[Op['or']]:_[_0x5d459e('0x28')](_0x255e03,function(_0xeddb20){const _0x528b44=_0x5d459e;if(_0xeddb20[_0x528b44('0x1c')]!==_0x528b44('0x19')){const _0x3a734a={};return _0x3a734a[_0xeddb20[_0x528b44('0x6')]]={[Op[_0x528b44('0x21')]]:'%'+_0x578953['query'][_0x528b44('0x23')]+'%'},_0x3a734a;}})}));_0x2ce05f=_[_0x5d459e('0xa')]({},_0x2ce05f,_0x578953[_0x5d459e('0x2e')]);const _0x416013={'where':_0x2ce05f[_0x5d459e('0x18')]};return db['DeskField']['count'](_0x416013)['then'](function(_0x3abe31){const _0x361af4=_0x5d459e;return _0x4d39f5[_0x361af4('0x27')]=_0x3abe31,_0x578953[_0x361af4('0x15')]['includeAll']&&(_0x2ce05f[_0x361af4('0x1')]=[{'all':!![]}]),db['DeskField'][_0x361af4('0x33')](_0x2ce05f);})[_0x5d459e('0x14')](function(_0x5286e0){const _0x3fc0e9=_0x5d459e;return _0x4d39f5[_0x3fc0e9('0x2f')]=_0x5286e0,_0x4d39f5;})['then'](respondWithFilteredResult(_0x3162c9,_0x2ce05f))['catch'](handleError(_0x3162c9,null));},exports[_0x5a19db('0x8')]=function(_0xe23815,_0x505e27){const _0x45f5d9=_0x5a19db;let _0x55a746={'raw':!![],'where':{'id':_0xe23815['params']['id']}};const _0x314d3e={};return _0x314d3e[_0x45f5d9('0x32')]=_[_0x45f5d9('0x31')](db[_0x45f5d9('0x29')][_0x45f5d9('0xc')]),_0x314d3e[_0x45f5d9('0x15')]=_[_0x45f5d9('0x31')](_0xe23815[_0x45f5d9('0x15')]),_0x314d3e[_0x45f5d9('0x5')]=_[_0x45f5d9('0x16')](_0x314d3e['model'],_0x314d3e[_0x45f5d9('0x15')]),_0x55a746['attributes']=_[_0x45f5d9('0x16')](_0x314d3e[_0x45f5d9('0x32')],qs[_0x45f5d9('0xd')](_0xe23815[_0x45f5d9('0x15')]['fields'])),_0x55a746[_0x45f5d9('0x25')]=_0x55a746[_0x45f5d9('0x25')]['length']?_0x55a746[_0x45f5d9('0x25')]:_0x314d3e[_0x45f5d9('0x32')],_0xe23815[_0x45f5d9('0x15')][_0x45f5d9('0x2b')]&&(_0x55a746[_0x45f5d9('0x1')]=[{'all':!![]}]),_0x55a746=_['merge']({},_0x55a746,_0xe23815['options']),db['DeskField']['findOne'](_0x55a746)[_0x45f5d9('0x14')](handleEntityNotFound(_0x505e27,null))[_0x45f5d9('0x14')](respondWithResult(_0x505e27,null))['catch'](handleError(_0x505e27,null));},exports[_0x5a19db('0x12')]=function(_0x2b572f,_0x136212){const _0xcddbdb=_0x5a19db;return db['DeskField'][_0xcddbdb('0x12')](_0x2b572f[_0xcddbdb('0xe')],{})[_0xcddbdb('0x14')](respondWithResult(_0x136212,0xc9))[_0xcddbdb('0x24')](handleError(_0x136212,null));},exports['update']=function(_0x3bb33a,_0x827c02){const _0x300d85=_0x5a19db;return _0x3bb33a[_0x300d85('0xe')]['id']&&delete _0x3bb33a[_0x300d85('0xe')]['id'],db[_0x300d85('0x29')]['findOne']({'where':{'id':_0x3bb33a[_0x300d85('0x11')]['id']}})['then'](handleEntityNotFound(_0x827c02,null))['then'](saveUpdates(_0x3bb33a[_0x300d85('0xe')],null))[_0x300d85('0x14')](respondWithResult(_0x827c02,null))[_0x300d85('0x24')](handleError(_0x827c02,null));},exports[_0x5a19db('0x13')]=function(_0x24aff8,_0x190c16){const _0x5bc92c=_0x5a19db;return db[_0x5bc92c('0x29')]['findOne']({'where':{'id':_0x24aff8[_0x5bc92c('0x11')]['id']}})[_0x5bc92c('0x14')](handleEntityNotFound(_0x190c16,null))[_0x5bc92c('0x14')](removeEntity(_0x190c16,null))['catch'](handleError(_0x190c16,null));}; \ No newline at end of file +const a238_0x5056=['query','VIRTUAL','api','filter','nolimit','Content-Range','merge','type','findOne','filters','undefined','DeskField','offset','include','../../config/logger','map','key','send','fieldName','attributes','then','name','options','fields','end','keys','limit','catch','includeAll','order','where','sort','create','length','destroy','params','sendStatus','index','update','body','rawAttributes','stack','model','count','../../components/parsers/qs','error','intersection','status'];(function(_0x4d35ff,_0x505620){const _0x31f5c9=function(_0x19d54f){while(--_0x19d54f){_0x4d35ff['push'](_0x4d35ff['shift']());}};_0x31f5c9(++_0x505620);}(a238_0x5056,0x163));const a238_0x31f5=function(_0x4d35ff,_0x505620){_0x4d35ff=_0x4d35ff-0x0;let _0x31f5c9=a238_0x5056[_0x4d35ff];return _0x31f5c9;};const _0x3342fa=a238_0x31f5;'use strict';const _=require('lodash'),qs=require(_0x3342fa('0x19')),logger=require(_0x3342fa('0x2b'))(_0x3342fa('0x1f')),db=require('../../mysqldb')['db'],{Op}=require('sequelize');function respondWithResult(_0x19d54f,_0x5be96b){return _0x5be96b=_0x5be96b||0xc8,function(_0x291b8a){const _0x32893b=a238_0x31f5;if(_0x291b8a)return _0x19d54f[_0x32893b('0x1c')](_0x5be96b)['json'](_0x291b8a);};}function respondWithFilteredResult(_0x2cfe7f,_0x4a7b89){return function(_0x25cc50){const _0x521796=a238_0x31f5;if(_0x25cc50){const _0x121060=_0x25cc50['count'],_0x99efa9=_0x4a7b89['offset'];let _0x49cbe4=_0x4a7b89[_0x521796('0x29')]+_0x4a7b89[_0x521796('0x7')],_0x140841;return _0x49cbe4>=_0x121060?(_0x49cbe4=_0x121060,_0x140841=0xc8):_0x140841=0xce,_0x2cfe7f[_0x521796('0x1c')](_0x140841),_0x2cfe7f['set'](_0x521796('0x22'),_0x99efa9+'-'+_0x49cbe4+'/'+_0x121060)['json'](_0x25cc50);}return null;};}function saveUpdates(_0x9ccb1f){return function(_0x15eb0a){const _0x23acf6=a238_0x31f5;if(_0x15eb0a)return _0x15eb0a[_0x23acf6('0x13')](_0x9ccb1f)[_0x23acf6('0x1')](function(_0x4fadc7){return _0x4fadc7;});return null;};}function removeEntity(_0x529fab){return function(_0x318dc9){const _0x18b6d5=a238_0x31f5;if(_0x318dc9)return _0x318dc9['destroy']()[_0x18b6d5('0x1')](function(){const _0x38e8ed=_0x18b6d5;_0x529fab['status'](0xcc)[_0x38e8ed('0x5')]();});};}function handleEntityNotFound(_0x2cef91){return function(_0x4d1446){const _0x4f657c=a238_0x31f5;return!_0x4d1446&&_0x2cef91[_0x4f657c('0x11')](0x194),_0x4d1446;};}function handleError(_0x36c0a4,_0x4e5e7a){return _0x4e5e7a=_0x4e5e7a||0x1f4,function(_0x237947){const _0x2b95e9=a238_0x31f5;logger[_0x2b95e9('0x1a')](_0x237947[_0x2b95e9('0x16')]),_0x237947[_0x2b95e9('0x2')]&&delete _0x237947[_0x2b95e9('0x2')],_0x36c0a4[_0x2b95e9('0x1c')](_0x4e5e7a)[_0x2b95e9('0x2e')](_0x237947);};}exports[_0x3342fa('0x12')]=function(_0x2ccad9,_0xb3fa53){const _0x148a71=_0x3342fa;let _0x2bae37={};const _0x2865d0={},_0x22ccd4={'count':0x0,'rows':[]},_0x34538d=_['map'](db['DeskField'][_0x148a71('0x15')],function(_0x3784f7){const _0x154a95=_0x148a71;return{'name':_0x3784f7[_0x154a95('0x2f')],'type':_0x3784f7[_0x154a95('0x24')][_0x154a95('0x2d')]};});_0x2865d0[_0x148a71('0x17')]=_[_0x148a71('0x2c')](_0x34538d,_0x148a71('0x2')),_0x2865d0['query']=_[_0x148a71('0x6')](_0x2ccad9['query']),_0x2865d0[_0x148a71('0x26')]=_[_0x148a71('0x1b')](_0x2865d0[_0x148a71('0x17')],_0x2865d0[_0x148a71('0x1d')]),_0x2bae37[_0x148a71('0x0')]=_[_0x148a71('0x1b')](_0x2865d0[_0x148a71('0x17')],qs[_0x148a71('0x4')](_0x2ccad9[_0x148a71('0x1d')][_0x148a71('0x4')])),_0x2bae37[_0x148a71('0x0')]=_0x2bae37[_0x148a71('0x0')][_0x148a71('0xe')]?_0x2bae37['attributes']:_0x2865d0[_0x148a71('0x17')];typeof _0x2ccad9[_0x148a71('0x1d')][_0x148a71('0x21')]===_0x148a71('0x27')&&(_0x2bae37[_0x148a71('0x7')]=qs['limit'](_0x2ccad9['query'][_0x148a71('0x7')]),_0x2bae37[_0x148a71('0x29')]=qs['offset'](_0x2ccad9[_0x148a71('0x1d')][_0x148a71('0x29')]));_0x2bae37[_0x148a71('0xa')]=qs[_0x148a71('0xc')](_0x2ccad9['query']['sort']),_0x2bae37[_0x148a71('0xb')]=qs[_0x148a71('0x26')](_['pick'](_0x2ccad9[_0x148a71('0x1d')],_0x2865d0[_0x148a71('0x26')]),_0x34538d);_0x2ccad9['query'][_0x148a71('0x20')]&&(_0x2bae37[_0x148a71('0xb')]=_[_0x148a71('0x23')](_0x2bae37['where'],{[Op['or']]:_['map'](_0x34538d,function(_0xc317c1){const _0xba953b=_0x148a71;if(_0xc317c1[_0xba953b('0x24')]!==_0xba953b('0x1e')){const _0x1a471e={};return _0x1a471e[_0xc317c1['name']]={[Op['like']]:'%'+_0x2ccad9[_0xba953b('0x1d')][_0xba953b('0x20')]+'%'},_0x1a471e;}})}));_0x2bae37=_[_0x148a71('0x23')]({},_0x2bae37,_0x2ccad9[_0x148a71('0x3')]);const _0x2275d5={'where':_0x2bae37[_0x148a71('0xb')]};return db[_0x148a71('0x28')][_0x148a71('0x18')](_0x2275d5)[_0x148a71('0x1')](function(_0x4d8fef){const _0x32140a=_0x148a71;return _0x22ccd4[_0x32140a('0x18')]=_0x4d8fef,_0x2ccad9[_0x32140a('0x1d')][_0x32140a('0x9')]&&(_0x2bae37[_0x32140a('0x2a')]=[{'all':!![]}]),db[_0x32140a('0x28')]['findAll'](_0x2bae37);})[_0x148a71('0x1')](function(_0x3575c6){return _0x22ccd4['rows']=_0x3575c6,_0x22ccd4;})[_0x148a71('0x1')](respondWithFilteredResult(_0xb3fa53,_0x2bae37))[_0x148a71('0x8')](handleError(_0xb3fa53,null));},exports['show']=function(_0x5643ed,_0x20b43f){const _0x4cbb8b=_0x3342fa;let _0x2ca549={'raw':!![],'where':{'id':_0x5643ed['params']['id']}};const _0x4b1c96={};return _0x4b1c96['model']=_[_0x4cbb8b('0x6')](db[_0x4cbb8b('0x28')][_0x4cbb8b('0x15')]),_0x4b1c96[_0x4cbb8b('0x1d')]=_['keys'](_0x5643ed[_0x4cbb8b('0x1d')]),_0x4b1c96['filters']=_['intersection'](_0x4b1c96[_0x4cbb8b('0x17')],_0x4b1c96[_0x4cbb8b('0x1d')]),_0x2ca549[_0x4cbb8b('0x0')]=_[_0x4cbb8b('0x1b')](_0x4b1c96['model'],qs[_0x4cbb8b('0x4')](_0x5643ed[_0x4cbb8b('0x1d')][_0x4cbb8b('0x4')])),_0x2ca549[_0x4cbb8b('0x0')]=_0x2ca549[_0x4cbb8b('0x0')]['length']?_0x2ca549[_0x4cbb8b('0x0')]:_0x4b1c96['model'],_0x5643ed[_0x4cbb8b('0x1d')][_0x4cbb8b('0x9')]&&(_0x2ca549[_0x4cbb8b('0x2a')]=[{'all':!![]}]),_0x2ca549=_[_0x4cbb8b('0x23')]({},_0x2ca549,_0x5643ed[_0x4cbb8b('0x3')]),db[_0x4cbb8b('0x28')][_0x4cbb8b('0x25')](_0x2ca549)['then'](handleEntityNotFound(_0x20b43f,null))[_0x4cbb8b('0x1')](respondWithResult(_0x20b43f,null))[_0x4cbb8b('0x8')](handleError(_0x20b43f,null));},exports[_0x3342fa('0xd')]=function(_0x31b5f6,_0x43c092){const _0x266737=_0x3342fa;return db['DeskField'][_0x266737('0xd')](_0x31b5f6[_0x266737('0x14')],{})[_0x266737('0x1')](respondWithResult(_0x43c092,0xc9))['catch'](handleError(_0x43c092,null));},exports[_0x3342fa('0x13')]=function(_0x1e494e,_0x39c95b){const _0x1abceb=_0x3342fa;return _0x1e494e[_0x1abceb('0x14')]['id']&&delete _0x1e494e[_0x1abceb('0x14')]['id'],db['DeskField']['findOne']({'where':{'id':_0x1e494e[_0x1abceb('0x10')]['id']}})[_0x1abceb('0x1')](handleEntityNotFound(_0x39c95b,null))[_0x1abceb('0x1')](saveUpdates(_0x1e494e[_0x1abceb('0x14')],null))[_0x1abceb('0x1')](respondWithResult(_0x39c95b,null))[_0x1abceb('0x8')](handleError(_0x39c95b,null));},exports[_0x3342fa('0xf')]=function(_0xfacfba,_0x1dae28){const _0x2ba731=_0x3342fa;return db[_0x2ba731('0x28')][_0x2ba731('0x25')]({'where':{'id':_0xfacfba[_0x2ba731('0x10')]['id']}})[_0x2ba731('0x1')](handleEntityNotFound(_0x1dae28,null))['then'](removeEntity(_0x1dae28,null))['catch'](handleError(_0x1dae28,null));}; \ No newline at end of file diff --git a/server/api/intDeskField/intDeskField.model.js b/server/api/intDeskField/intDeskField.model.js index a949f29..4e5c062 100644 --- a/server/api/intDeskField/intDeskField.model.js +++ b/server/api/intDeskField/intDeskField.model.js @@ -1 +1 @@ -const a239_0x1806=['FieldId','idField','int_desk_fields','DeskField','exports','./intDeskField.attributes','desk_unique_index'];(function(_0x446052,_0x180664){const _0x1825f1=function(_0x2c2d86){while(--_0x2c2d86){_0x446052['push'](_0x446052['shift']());}};_0x1825f1(++_0x180664);}(a239_0x1806,0x181));const a239_0x1825=function(_0x446052,_0x180664){_0x446052=_0x446052-0x0;let _0x1825f1=a239_0x1806[_0x446052];return _0x1825f1;};const _0x3cd214=a239_0x1825;'use strict';const attributes=require(_0x3cd214('0x5'));module[_0x3cd214('0x4')]=function(_0x2c2d86){const _0x39ce0c=_0x3cd214,_0x2b5f31=_0x2c2d86['define'](_0x39ce0c('0x3'),attributes,{'tableName':_0x39ce0c('0x2'),'paranoid':![],'indexes':[{'name':_0x39ce0c('0x6'),'fields':[_0x39ce0c('0x1'),_0x39ce0c('0x0')],'unique':!![]}],'timestamps':!![]});return _0x2b5f31;}; \ No newline at end of file +const a239_0x50be=['define','exports','idField','FieldId','DeskField','int_desk_fields'];(function(_0x1b7a06,_0x50be0d){const _0x1990c1=function(_0x41c2de){while(--_0x41c2de){_0x1b7a06['push'](_0x1b7a06['shift']());}};_0x1990c1(++_0x50be0d);}(a239_0x50be,0x1eb));const a239_0x1990=function(_0x1b7a06,_0x50be0d){_0x1b7a06=_0x1b7a06-0x0;let _0x1990c1=a239_0x50be[_0x1b7a06];return _0x1990c1;};const _0x1b7fe8=a239_0x1990;'use strict';const attributes=require('./intDeskField.attributes');module[_0x1b7fe8('0x2')]=function(_0x41c2de){const _0xb5dc8c=_0x1b7fe8,_0x1377a9=_0x41c2de[_0xb5dc8c('0x1')](_0xb5dc8c('0x5'),attributes,{'tableName':_0xb5dc8c('0x0'),'paranoid':![],'indexes':[{'name':'desk_unique_index','fields':[_0xb5dc8c('0x3'),_0xb5dc8c('0x4')],'unique':!![]}],'timestamps':!![]});return _0x1377a9;}; \ No newline at end of file diff --git a/server/api/intDynamics365Account/index.js b/server/api/intDynamics365Account/index.js index f2a5085..303a768 100644 --- a/server/api/intDynamics365Account/index.js +++ b/server/api/intDynamics365Account/index.js @@ -1 +1 @@ -const a240_0x57d8=['Router','exports','addConfiguration','../../components/auth/service','post','getConfigurations','index','get','delete','/:id/fields','/:id','./intDynamics365Account.controller','isAuthenticated','destroy','create','express','/:id/configurations','update','show'];(function(_0x2e0028,_0x57d8ab){const _0x14d39e=function(_0xa17af1){while(--_0xa17af1){_0x2e0028['push'](_0x2e0028['shift']());}};_0x14d39e(++_0x57d8ab);}(a240_0x57d8,0xaa));const a240_0x14d3=function(_0x2e0028,_0x57d8ab){_0x2e0028=_0x2e0028-0x0;let _0x14d39e=a240_0x57d8[_0x2e0028];return _0x14d39e;};const _0x419aa5=a240_0x14d3;'use strict';const express=require(_0x419aa5('0x10')),router=express[_0x419aa5('0x1')](),auth=require(_0x419aa5('0x4')),controller=require(_0x419aa5('0xc'));router[_0x419aa5('0x8')]('/',auth[_0x419aa5('0xd')](),controller[_0x419aa5('0x7')]),router['get'](_0x419aa5('0xb'),auth[_0x419aa5('0xd')](),controller[_0x419aa5('0x0')]),router[_0x419aa5('0x8')](_0x419aa5('0x11'),auth[_0x419aa5('0xd')](),controller[_0x419aa5('0x6')]),router[_0x419aa5('0x8')](_0x419aa5('0xa'),auth[_0x419aa5('0xd')](),controller['getFields']),router['post']('/',auth[_0x419aa5('0xd')](),controller[_0x419aa5('0xf')]),router[_0x419aa5('0x5')]('/:id/configurations',auth['isAuthenticated'](),controller[_0x419aa5('0x3')]),router['put'](_0x419aa5('0xb'),auth[_0x419aa5('0xd')](),controller[_0x419aa5('0x12')]),router[_0x419aa5('0x9')](_0x419aa5('0xb'),auth[_0x419aa5('0xd')](),controller[_0x419aa5('0xe')]),module[_0x419aa5('0x2')]=router; \ No newline at end of file +const a240_0x1171=['addConfiguration','destroy','./intDynamics365Account.controller','/:id/configurations','post','index','/:id/fields','../../components/auth/service','exports','delete','Router','put','express','isAuthenticated','/:id','get','create'];(function(_0x39370f,_0x11718b){const _0x19d951=function(_0x1845c9){while(--_0x1845c9){_0x39370f['push'](_0x39370f['shift']());}};_0x19d951(++_0x11718b);}(a240_0x1171,0xed));const a240_0x19d9=function(_0x39370f,_0x11718b){_0x39370f=_0x39370f-0x0;let _0x19d951=a240_0x1171[_0x39370f];return _0x19d951;};const _0x2c4caf=a240_0x19d9;'use strict';const express=require(_0x2c4caf('0xd')),router=express[_0x2c4caf('0xb')](),auth=require(_0x2c4caf('0x8')),controller=require(_0x2c4caf('0x3'));router[_0x2c4caf('0x10')]('/',auth[_0x2c4caf('0xe')](),controller[_0x2c4caf('0x6')]),router[_0x2c4caf('0x10')](_0x2c4caf('0xf'),auth[_0x2c4caf('0xe')](),controller['show']),router[_0x2c4caf('0x10')]('/:id/configurations',auth[_0x2c4caf('0xe')](),controller['getConfigurations']),router['get'](_0x2c4caf('0x7'),auth[_0x2c4caf('0xe')](),controller['getFields']),router[_0x2c4caf('0x5')]('/',auth[_0x2c4caf('0xe')](),controller[_0x2c4caf('0x0')]),router[_0x2c4caf('0x5')](_0x2c4caf('0x4'),auth[_0x2c4caf('0xe')](),controller[_0x2c4caf('0x1')]),router[_0x2c4caf('0xc')]('/:id',auth[_0x2c4caf('0xe')](),controller['update']),router[_0x2c4caf('0xa')](_0x2c4caf('0xf'),auth[_0x2c4caf('0xe')](),controller[_0x2c4caf('0x2')]),module[_0x2c4caf('0x9')]=router; \ No newline at end of file diff --git a/server/api/intDynamics365Account/intDynamics365Account.attributes.js b/server/api/intDynamics365Account/intDynamics365Account.attributes.js index 1bc3e44..2f26abd 100644 --- a/server/api/intDynamics365Account/intDynamics365Account.attributes.js +++ b/server/api/intDynamics365Account/intDynamics365Account.attributes.js @@ -1 +1 @@ -const a241_0x18b0=['STRING','sequelize'];(function(_0x39b55c,_0x18b0d8){const _0x25c385=function(_0x295b1b){while(--_0x295b1b){_0x39b55c['push'](_0x39b55c['shift']());}};_0x25c385(++_0x18b0d8);}(a241_0x18b0,0x14e));const a241_0x25c3=function(_0x39b55c,_0x18b0d8){_0x39b55c=_0x39b55c-0x0;let _0x25c385=a241_0x18b0[_0x39b55c];return _0x25c385;};const _0x22e386=a241_0x25c3;'use strict';const Sequelize=require(_0x22e386('0x1'));module['exports']={'name':{'type':Sequelize[_0x22e386('0x0')]},'username':{'type':Sequelize['STRING']},'password':{'type':Sequelize[_0x22e386('0x0')]},'remoteUri':{'type':Sequelize[_0x22e386('0x0')]},'tenantId':{'type':Sequelize['STRING']},'clientId':{'type':Sequelize[_0x22e386('0x0')]},'clientSecret':{'type':Sequelize[_0x22e386('0x0')]},'serverUrl':{'type':Sequelize[_0x22e386('0x0')]},'description':{'type':Sequelize[_0x22e386('0x0')]}}; \ No newline at end of file +const a241_0x16fc=['STRING','exports'];(function(_0x21d001,_0x16fcf9){const _0x5686d3=function(_0x536f20){while(--_0x536f20){_0x21d001['push'](_0x21d001['shift']());}};_0x5686d3(++_0x16fcf9);}(a241_0x16fc,0x119));const a241_0x5686=function(_0x21d001,_0x16fcf9){_0x21d001=_0x21d001-0x0;let _0x5686d3=a241_0x16fc[_0x21d001];return _0x5686d3;};const _0x2880b6=a241_0x5686;'use strict';const Sequelize=require('sequelize');module[_0x2880b6('0x0')]={'name':{'type':Sequelize['STRING']},'username':{'type':Sequelize['STRING']},'password':{'type':Sequelize[_0x2880b6('0x1')]},'remoteUri':{'type':Sequelize[_0x2880b6('0x1')]},'tenantId':{'type':Sequelize[_0x2880b6('0x1')]},'clientId':{'type':Sequelize['STRING']},'clientSecret':{'type':Sequelize['STRING']},'serverUrl':{'type':Sequelize[_0x2880b6('0x1')]},'description':{'type':Sequelize[_0x2880b6('0x1')]}}; \ No newline at end of file diff --git a/server/api/intDynamics365Account/intDynamics365Account.controller.js b/server/api/intDynamics365Account/intDynamics365Account.controller.js index fd9f957..d48b02e 100644 --- a/server/api/intDynamics365Account/intDynamics365Account.controller.js +++ b/server/api/intDynamics365Account/intDynamics365Account.controller.js @@ -1 +1 @@ -const a242_0x5039=['customeridyominame','remove','lastIndexOf','catch',')?$select=LogicalName&$expand=Attributes($select=LogicalName)','FalseOption','like','entityimage_url','query','socialprofileidname','type','Label','ownerid','key','nolimit','BigIntAttributeMetadata','importsequencenumber','findAll','4.0','count','?$select=DisplayName,LogicalName','rawAttributes','limit','../../components/parsers/qs','tenantId','includeAll','set','Content-Range','findOne','modifiedonbehalfbyyominame','parentcaseidname','all','util','fields','then','transactioncurrencyidname','status','directioncode','versionnumber','model','Options','map','stack','../../components/integrations/configuration','sendStatus','name','true','PhoneCall','%s/api/data/v9.0/','phonenumber','keys','params','Descriptions','StateAttributeMetadata','https://login.microsoftonline.com/','ticketType','StringAttributeMetadata','Attributes','Value','push','exchangerate','body','EntityDefinitions(','includes','UserLocalizedLabel','timezoneruleversionnumber','@odata.type','DecimalAttributeMetadata','clientSecret','sentimentvalue','concat','update','modifiedbyyominame','resolvebykpiidname','responsiblecontactidname','/oauth2/token','Dynamics365Field','caseorigincode','modifiedbyexternalpartyyominame','Subjects','primarycontactidname','lodash','Dynamics365Configuration','resolveby','owneridname','influencescore','destroy','LogicalName','utcconversiontimezonecode','Dynamics365Account','title',')/Microsoft.Dynamics.CRM.','access_token','overriddencreatedon','DateTimeAttributeMetadata','createdonbehalfbyname','../../config/logger','false','substring','api','subject','slice','subjectidname','createdbyexternalpartyyominame','sort','password','MemoAttributeMetadata',')/Attributes(',')/Microsoft.Dynamics.CRM.PicklistAttributeMetadata?','prioritycodename','POST','fieldName','getFields','primarycontactidyominame','customeridtype','where','OptionSet','masteridname','getConfigurations','modifiedbyname','entitlementidname','username','clientId','include','productserialnumber','createdbyyominame','contactidyominame','owneridyominame','responsiblecontactidyominame','DisplayName','length','$select=DisplayName,LogicalName&$expand=OptionSet($select=Options)','statusCode','entityimage_timestamp','msdyn_iotalertname','statecode','contractidname','Wrong\x20credentials','merge','error','incident','StatusAttributeMetadata','channel','getSubjects','attributes','modifiedbyexternalpartyname','createdbyexternalpartyname','pick','msdyn_incidenttypename','accountidname','json','customeridname','regardingobjectid','intersection','MetadataId','undefined','remoteUri','AccountId','create','Bearer\x20','filter','end','BooleanAttributeMetadata','order','filters','GET','forEach','kbarticleidname','index','slaname','test','IntegerAttributeMetadata','isNil','value','numberofchildincidents','../../mysqldb','createdbyname','onholdtime','offset',')/Microsoft.Dynamics.CRM.BooleanAttributeMetadata?$select=DisplayName,LogicalName&$expand=OptionSet($select=FalseOption,\x20TrueOption)','options','request-promise-native','VIRTUAL'];(function(_0x276559,_0x5039a3){const _0x1e1bfa=function(_0x2efb0e){while(--_0x2efb0e){_0x276559['push'](_0x276559['shift']());}};_0x1e1bfa(++_0x5039a3);}(a242_0x5039,0x139));const a242_0x1e1b=function(_0x276559,_0x5039a3){_0x276559=_0x276559-0x0;let _0x1e1bfa=a242_0x5039[_0x276559];return _0x1e1bfa;};const _0x2e0ff3=a242_0x1e1b;'use strict';const rp=require(_0x2e0ff3('0x33')),util=require(_0x2e0ff3('0x55')),_=require(_0x2e0ff3('0x86')),qs=require(_0x2e0ff3('0x4c')),logger=require(_0x2e0ff3('0x95'))(_0x2e0ff3('0x98')),db=require(_0x2e0ff3('0x2d'))['db'],{Op}=require('sequelize'),integrations=require(_0x2e0ff3('0x60'));function respondWithResult(_0x2efb0e,_0x8f2bad){return _0x8f2bad=_0x8f2bad||0xc8,function(_0x45a256){const _0x54aab8=a242_0x1e1b;if(_0x45a256)return _0x2efb0e[_0x54aab8('0x59')](_0x8f2bad)[_0x54aab8('0x14')](_0x45a256);};}function respondWithFilteredResult(_0x23655c,_0x1b8b59){return function(_0x47c804){const _0x556279=a242_0x1e1b;if(_0x47c804){const _0x555be0=_0x47c804[_0x556279('0x48')],_0x48575f=_0x1b8b59['offset'];let _0x1fa871=_0x1b8b59[_0x556279('0x30')]+_0x1b8b59[_0x556279('0x4b')],_0x5d61c4;return _0x1fa871>=_0x555be0?(_0x1fa871=_0x555be0,_0x5d61c4=0xc8):_0x5d61c4=0xce,_0x23655c['status'](_0x5d61c4),_0x23655c[_0x556279('0x4f')](_0x556279('0x50'),_0x48575f+'-'+_0x1fa871+'/'+_0x555be0)[_0x556279('0x14')](_0x47c804);}return null;};}function saveUpdates(_0x5aafe2){return function(_0x5a82bd){const _0xfbe4d5=a242_0x1e1b;if(_0x5a82bd)return _0x5a82bd[_0xfbe4d5('0x7c')](_0x5aafe2)['then'](function(_0x4c499c){return _0x4c499c;});return null;};}function removeEntity(_0x3794fa){return function(_0x27cde7){const _0x10d682=a242_0x1e1b;if(_0x27cde7)return _0x27cde7[_0x10d682('0x8b')]()['then'](function(){const _0x3ffc01=_0x10d682;_0x3794fa[_0x3ffc01('0x59')](0xcc)[_0x3ffc01('0x1f')]();});};}function handleEntityNotFound(_0x2b68fb){return function(_0x327888){const _0x527554=a242_0x1e1b;return!_0x327888&&_0x2b68fb[_0x527554('0x61')](0x194),_0x327888;};}function handleError(_0x50d8bd,_0xc4b8ff){return _0xc4b8ff=_0xc4b8ff||0x1f4,function(_0x3967da){const _0x5f0007=a242_0x1e1b;logger[_0x5f0007('0x9')](_0x3967da['stack']),_0x3967da[_0x5f0007('0x62')]&&delete _0x3967da[_0x5f0007('0x62')],_0x50d8bd[_0x5f0007('0x59')](_0xc4b8ff)['send'](_0x3967da);};}exports[_0x2e0ff3('0x26')]=function(_0x5708b9,_0x199271){const _0xb31708=_0x2e0ff3;let _0x221f8e={};const _0x568b3c={},_0x4b55bb={'count':0x0,'rows':[]},_0x1f8536=_[_0xb31708('0x5e')](db[_0xb31708('0x8e')][_0xb31708('0x4a')],function(_0x218ee3){const _0x2a0454=_0xb31708;return{'name':_0x218ee3[_0x2a0454('0xa4')],'type':_0x218ee3[_0x2a0454('0x3f')][_0x2a0454('0x42')]};});_0x568b3c[_0xb31708('0x5c')]=_[_0xb31708('0x5e')](_0x1f8536,_0xb31708('0x62')),_0x568b3c['query']=_[_0xb31708('0x67')](_0x5708b9[_0xb31708('0x3d')]),_0x568b3c['filters']=_['intersection'](_0x568b3c[_0xb31708('0x5c')],_0x568b3c['query']),_0x221f8e[_0xb31708('0xe')]=_[_0xb31708('0x17')](_0x568b3c[_0xb31708('0x5c')],qs[_0xb31708('0x56')](_0x5708b9[_0xb31708('0x3d')]['fields'])),_0x221f8e[_0xb31708('0xe')]=_0x221f8e[_0xb31708('0xe')]['length']?_0x221f8e[_0xb31708('0xe')]:_0x568b3c[_0xb31708('0x5c')];typeof _0x5708b9['query'][_0xb31708('0x43')]===_0xb31708('0x19')&&(_0x221f8e[_0xb31708('0x4b')]=qs[_0xb31708('0x4b')](_0x5708b9[_0xb31708('0x3d')][_0xb31708('0x4b')]),_0x221f8e['offset']=qs[_0xb31708('0x30')](_0x5708b9['query'][_0xb31708('0x30')]));_0x221f8e[_0xb31708('0x21')]=qs[_0xb31708('0x9d')](_0x5708b9[_0xb31708('0x3d')][_0xb31708('0x9d')]),_0x221f8e['where']=qs[_0xb31708('0x22')](_[_0xb31708('0x11')](_0x5708b9[_0xb31708('0x3d')],_0x568b3c[_0xb31708('0x22')]),_0x1f8536);_0x5708b9[_0xb31708('0x3d')][_0xb31708('0x1e')]&&(_0x221f8e['where']=_[_0xb31708('0x8')](_0x221f8e['where'],{[Op['or']]:_[_0xb31708('0x5e')](_0x1f8536,function(_0x2b0b2d){const _0x4d7554=_0xb31708;if(_0x2b0b2d[_0x4d7554('0x3f')]!==_0x4d7554('0x34')){const _0x5538e3={};return _0x5538e3[_0x2b0b2d[_0x4d7554('0x62')]]={[Op[_0x4d7554('0x3b')]]:'%'+_0x5708b9[_0x4d7554('0x3d')][_0x4d7554('0x1e')]+'%'},_0x5538e3;}})}));_0x221f8e=_[_0xb31708('0x8')]({},_0x221f8e,_0x5708b9['options']);const _0x2526d4={'where':_0x221f8e[_0xb31708('0xa8')]};return db[_0xb31708('0x8e')]['count'](_0x2526d4)[_0xb31708('0x57')](function(_0x2440b5){const _0x571c1d=_0xb31708;return _0x4b55bb[_0x571c1d('0x48')]=_0x2440b5,_0x5708b9[_0x571c1d('0x3d')][_0x571c1d('0x4e')]&&(_0x221f8e[_0x571c1d('0xb0')]=[{'all':!![]}]),db[_0x571c1d('0x8e')][_0x571c1d('0x46')](_0x221f8e);})[_0xb31708('0x57')](function(_0x13958c){return _0x4b55bb['rows']=_0x13958c,_0x4b55bb;})[_0xb31708('0x57')](respondWithFilteredResult(_0x199271,_0x221f8e))['catch'](handleError(_0x199271,null));},exports['show']=function(_0x51f836,_0x1ef1fc){const _0x326701=_0x2e0ff3;let _0x455641={'raw':![],'where':{'id':_0x51f836[_0x326701('0x68')]['id']}};const _0x1b51c2={};return _0x1b51c2['model']=_[_0x326701('0x67')](db[_0x326701('0x8e')]['rawAttributes']),_0x1b51c2[_0x326701('0x3d')]=_[_0x326701('0x67')](_0x51f836[_0x326701('0x3d')]),_0x1b51c2['filters']=_[_0x326701('0x17')](_0x1b51c2[_0x326701('0x5c')],_0x1b51c2['query']),_0x455641[_0x326701('0xe')]=_['intersection'](_0x1b51c2[_0x326701('0x5c')],qs[_0x326701('0x56')](_0x51f836[_0x326701('0x3d')][_0x326701('0x56')])),_0x455641[_0x326701('0xe')]=_0x455641[_0x326701('0xe')][_0x326701('0x0')]?_0x455641[_0x326701('0xe')]:_0x1b51c2[_0x326701('0x5c')],_0x51f836[_0x326701('0x3d')][_0x326701('0x4e')]&&(_0x455641[_0x326701('0xb0')]=[{'all':!![]}]),_0x455641=_[_0x326701('0x8')]({},_0x455641,_0x51f836[_0x326701('0x32')]),db[_0x326701('0x8e')][_0x326701('0x51')](_0x455641)['then'](handleEntityNotFound(_0x1ef1fc,null))[_0x326701('0x57')](respondWithResult(_0x1ef1fc,null))['catch'](handleError(_0x1ef1fc,null));},exports['create']=function(_0x128050,_0x1f6d5c){const _0x23ec84=_0x2e0ff3;return db[_0x23ec84('0x8e')][_0x23ec84('0x1c')](_0x128050['body'],{})[_0x23ec84('0x57')](respondWithResult(_0x1f6d5c,0xc9))[_0x23ec84('0x38')](handleError(_0x1f6d5c,null));},exports['update']=function(_0x433f8f,_0x2d6288){const _0x3153ee=_0x2e0ff3;return _0x433f8f[_0x3153ee('0x72')]['id']&&delete _0x433f8f[_0x3153ee('0x72')]['id'],db[_0x3153ee('0x8e')][_0x3153ee('0x51')]({'where':{'id':_0x433f8f[_0x3153ee('0x68')]['id']}})[_0x3153ee('0x57')](handleEntityNotFound(_0x2d6288,null))[_0x3153ee('0x57')](saveUpdates(_0x433f8f['body'],null))['then'](respondWithResult(_0x2d6288,null))[_0x3153ee('0x38')](handleError(_0x2d6288,null));},exports[_0x2e0ff3('0x8b')]=function(_0x27db87,_0x1ee6ae){const _0x151815=_0x2e0ff3;return db[_0x151815('0x8e')][_0x151815('0x51')]({'where':{'id':_0x27db87[_0x151815('0x68')]['id']}})[_0x151815('0x57')](handleEntityNotFound(_0x1ee6ae,null))[_0x151815('0x57')](removeEntity(_0x1ee6ae,null))['catch'](handleError(_0x1ee6ae,null));},exports[_0x2e0ff3('0xab')]=function(_0xfc810e,_0x1a9205){const _0x53e096=_0x2e0ff3;let _0x275552={};const _0x53ff94={};let _0x10e400,_0x222fdd;return db[_0x53e096('0x8e')][_0x53e096('0x51')]({'where':{'id':_0xfc810e[_0x53e096('0x68')]['id']}})[_0x53e096('0x57')](handleEntityNotFound(_0x1a9205,null))[_0x53e096('0x57')](function(_0x54d600){const _0x3e404d=_0x53e096;if(_0x54d600)return _0x10e400=_0x54d600,_0x53ff94['model']=_['keys'](db[_0x3e404d('0x87')][_0x3e404d('0x4a')]),_0x53ff94['query']=_[_0x3e404d('0x67')](_0xfc810e[_0x3e404d('0x3d')]),_0x53ff94[_0x3e404d('0x22')]=_[_0x3e404d('0x17')](_0x53ff94[_0x3e404d('0x5c')],_0x53ff94[_0x3e404d('0x3d')]),_0x275552['attributes']=_['intersection'](_0x53ff94['model'],qs['fields'](_0xfc810e[_0x3e404d('0x3d')][_0x3e404d('0x56')])),_0x275552[_0x3e404d('0xe')]=_0x275552[_0x3e404d('0xe')]['length']?_0x275552[_0x3e404d('0xe')]:_0x53ff94['model'],_0x275552[_0x3e404d('0x21')]=qs[_0x3e404d('0x9d')](_0xfc810e['query']['sort']),_0x275552[_0x3e404d('0xa8')]=qs['filters'](_['pick'](_0xfc810e[_0x3e404d('0x3d')],_0x53ff94[_0x3e404d('0x22')])),_0xfc810e['query'][_0x3e404d('0x1e')]&&(_0x275552[_0x3e404d('0xa8')]=_[_0x3e404d('0x8')](_0x275552[_0x3e404d('0xa8')],{[Op['or']]:_[_0x3e404d('0x5e')](_0x275552[_0x3e404d('0xe')],function(_0x3aba4f){const _0x1e4596=_0x3e404d,_0x257a32={};return _0x257a32[_0x3aba4f]={[Op[_0x1e4596('0x3b')]]:'%'+_0xfc810e['query']['filter']+'%'},_0x257a32;})})),_0x275552=_[_0x3e404d('0x8')]({},_0x275552,_0xfc810e[_0x3e404d('0x32')]),_0x10e400[_0x3e404d('0xab')](_0x275552);})[_0x53e096('0x57')](function(_0x47b3c9){const _0x27661b=_0x53e096;if(_0x47b3c9)return _0x222fdd=_0x47b3c9[_0x27661b('0x0')],typeof _0xfc810e['query']['nolimit']===_0x27661b('0x19')&&(_0x275552[_0x27661b('0x4b')]=qs['limit'](_0xfc810e['query'][_0x27661b('0x4b')]),_0x275552[_0x27661b('0x30')]=qs[_0x27661b('0x30')](_0xfc810e[_0x27661b('0x3d')]['offset'])),_0x10e400[_0x27661b('0xab')](_0x275552);})[_0x53e096('0x57')](function(_0x1db086){if(_0x1db086)return _0x1db086?{'count':_0x222fdd,'rows':_0x1db086}:null;})['then'](respondWithResult(_0x1a9205,null))[_0x53e096('0x38')](handleError(_0x1a9205,null));},exports['addConfiguration']=function(_0x1ec9a4,_0x3c9d10){const _0x5b1c48=_0x2e0ff3;return _0x1ec9a4[_0x5b1c48('0x72')]['id']&&delete _0x1ec9a4[_0x5b1c48('0x72')]['id'],db[_0x5b1c48('0x8e')][_0x5b1c48('0x51')]({'where':{'id':_0x1ec9a4[_0x5b1c48('0x68')]['id']}})[_0x5b1c48('0x57')](handleEntityNotFound(_0x3c9d10,null))[_0x5b1c48('0x57')](function(_0x4577ed){const _0x21f74f=_0x5b1c48;if(_0x4577ed)return _0x1ec9a4[_0x21f74f('0x72')][_0x21f74f('0x1b')]=_0x4577ed['id'],_0x1ec9a4[_0x21f74f('0x72')][_0x21f74f('0x84')]=integrations[_0x21f74f('0xd')](_0x1ec9a4[_0x21f74f('0x72')][_0x21f74f('0xc')],_0x1ec9a4[_0x21f74f('0x72')][_0x21f74f('0x3f')]),_0x1ec9a4['body'][_0x21f74f('0x69')]=integrations['getDescriptions'](_0x1ec9a4['body'][_0x21f74f('0xc')],_0x1ec9a4[_0x21f74f('0x72')]['type']),db['Dynamics365Configuration'][_0x21f74f('0x1c')](_0x1ec9a4[_0x21f74f('0x72')],{'include':[{'model':db[_0x21f74f('0x81')],'as':_0x21f74f('0x84')},{'model':db[_0x21f74f('0x81')],'as':'Descriptions'}]});return null;})[_0x5b1c48('0x57')](respondWithResult(_0x3c9d10,null))[_0x5b1c48('0x38')](handleError(_0x3c9d10,null));},exports[_0x2e0ff3('0xa5')]=function(_0x3b4f11,_0x3048b4){const _0x4da875=_0x2e0ff3,_0x283489=_0x3b4f11[_0x4da875('0x3d')][_0x4da875('0x6c')],_0x9c92a1=_0x283489===_0x4da875('0xa')?'Incident':_0x4da875('0x64');let _0x51c5c7='',_0x388fd7='',_0x5d362f='',_0x3cf314='',_0xbaa70b='',_0x4063ee='',_0x37ec32='',_0x2f855d='';const _0x2384e9=[_0x4da875('0x8f'),'description','customerid',_0x4da875('0x41'),_0x4da875('0x82'),_0x4da875('0x99'),_0x4da875('0x66'),_0x4da875('0x16'),_0x4da875('0x5a'),'phonecall_activity_parties'],_0x324072=[_0x4da875('0x13'),'accountidyominame','actualserviceunits','billedserviceunits','contactidname',_0x4da875('0xb3'),'contractdetailidname',_0x4da875('0x6'),_0x4da875('0x10'),_0x4da875('0x9c'),_0x4da875('0x2e'),_0x4da875('0xb2'),'createdon',_0x4da875('0x94'),'createdonbehalfbyyominame',_0x4da875('0x15'),_0x4da875('0xa7'),_0x4da875('0x35'),'emailaddress',_0x4da875('0xad'),_0x4da875('0x3'),_0x4da875('0x3c'),'escalatedon',_0x4da875('0x71'),'firstresponsebykpiidname','followupby',_0x4da875('0x45'),_0x4da875('0x8a'),_0x4da875('0x25'),'lastonholdtime',_0x4da875('0xaa'),_0x4da875('0xf'),_0x4da875('0x83'),_0x4da875('0xac'),_0x4da875('0x7d'),'modifiedon','modifiedonbehalfbyname',_0x4da875('0x52'),_0x4da875('0x12'),_0x4da875('0x4'),_0x4da875('0x2c'),_0x4da875('0x2f'),_0x4da875('0x92'),_0x4da875('0x89'),'owneridtype',_0x4da875('0xb4'),_0x4da875('0x53'),_0x4da875('0x85'),_0x4da875('0xa6'),_0x4da875('0xa2'),'productidname',_0x4da875('0xb1'),_0x4da875('0x88'),_0x4da875('0x7e'),'responseby',_0x4da875('0x7f'),_0x4da875('0xb5'),_0x4da875('0x7a'),'slainvokedidname',_0x4da875('0x27'),_0x4da875('0x3e'),_0x4da875('0x5'),'statuscode',_0x4da875('0x9b'),'ticketnumber',_0x4da875('0x76'),_0x4da875('0x58'),'traversedpath',_0x4da875('0x8d'),_0x4da875('0x5b')],_0x32082c=_0x2384e9[_0x4da875('0x7b')](_0x324072);return db[_0x4da875('0x8e')][_0x4da875('0x51')]({'where':{'id':_0x3b4f11[_0x4da875('0x68')]['id']},'attributes':['id',_0x4da875('0xae'),_0x4da875('0x9e'),_0x4da875('0x1a'),_0x4da875('0x4d'),_0x4da875('0xaf'),_0x4da875('0x79')]})[_0x4da875('0x57')](handleEntityNotFound(_0x3048b4,null))['then'](function(_0x3732a9){const _0x4ec627=_0x4da875;if(_0x3732a9){_0x2f855d=_0x3732a9[_0x4ec627('0x1a')];const _0x2a5108=_0x2f855d[_0x4ec627('0x9a')](-0x1);_0x2a5108==='/'&&(_0x2f855d=_0x2f855d[_0x4ec627('0x97')](0x0,_0x2f855d[_0x4ec627('0x37')](_0x2a5108)));_0x37ec32=util['format'](_0x4ec627('0x65'),_0x2f855d);const _0x172a43={'method':_0x4ec627('0xa3'),'uri':_0x4ec627('0x6b')+_0x3732a9[_0x4ec627('0x4d')]+_0x4ec627('0x80'),'form':{'client_id':_0x3732a9['clientId'],'resource':_0x2f855d,'username':_0x3732a9[_0x4ec627('0xae')],'password':_0x3732a9[_0x4ec627('0x9e')],'grant_type':_0x4ec627('0x9e'),'client_secret':_0x3732a9[_0x4ec627('0x79')]},'json':!![]};return rp(_0x172a43);}})[_0x4da875('0x57')](function(_0x1ecf82){const _0x1ab84c=_0x4da875;_0x4063ee=_0x1ecf82[_0x1ab84c('0x91')];const _0x2c39b8={'method':_0x1ab84c('0x23'),'uri':encodeURI(_0x37ec32+'EntityDefinitions?$select=DisplayName,EntitySetName&$filter=SchemaName\x20eq\x20\x27'+_0x9c92a1+'\x27'),'headers':{'Authorization':_0x1ab84c('0x1d')+_0x4063ee,'If-None-Match':null,'OData-Version':_0x1ab84c('0x47')},'json':!![]};return rp(_0x2c39b8);})[_0x4da875('0x57')](function(_0x415ebe){const _0x453b09=_0x4da875,_0xc4ea5a=_0x415ebe[_0x453b09('0x2b')][0x0],_0x3579da=_0xc4ea5a[_0x453b09('0x18')],_0x427502={'method':'GET','uri':_0x37ec32+_0x453b09('0x73')+_0x3579da+_0x453b09('0x39'),'headers':{'Authorization':'Bearer\x20'+_0x4063ee,'If-None-Match':null,'OData-Version':_0x453b09('0x47')},'json':!![]};return rp(_0x427502);})[_0x4da875('0x57')](function(_0x55550a){const _0x36fd06=_0x4da875;_0x51c5c7=_0x55550a,_0x388fd7=_0x51c5c7[_0x36fd06('0x6e')],_0x388fd7=_[_0x36fd06('0x36')](_0x388fd7,function(_0x1f4106){const _0x5a70f7=_0x36fd06;return!_0x32082c[_0x5a70f7('0x74')](_0x1f4106['LogicalName']);});const _0x4ecdb0=[],_0x85e958=[];return _0x388fd7['forEach'](function(_0x4606ee){const _0x428127=_0x36fd06;if(_0x4606ee[_0x428127('0x77')]){const _0x215c71=_0x4606ee[_0x428127('0x77')][_0x428127('0x97')](_0x4606ee[_0x428127('0x77')][_0x428127('0x37')]('.')+0x1);_0x215c71==='PicklistAttributeMetadata'&&_0x4ecdb0[_0x428127('0x70')](getSelectList(_0x37ec32,_0x283489,_0x85e958,_0x51c5c7[_0x428127('0x18')],_0x4606ee[_0x428127('0x18')],_0x4063ee));}}),Promise[_0x36fd06('0x54')](_0x4ecdb0);})['then'](function(_0x239544){const _0x56d7ce=_0x4da875;_0x5d362f=_0x239544[0x0];const _0x5daab8=[],_0x1b6142=[];return _0x388fd7[_0x56d7ce('0x24')](function(_0x44510b){const _0x124169=_0x56d7ce;if(!_[_0x124169('0x2a')](_0x44510b[_0x124169('0x77')])){const _0x2054c6=_0x44510b[_0x124169('0x77')][_0x124169('0x97')](_0x44510b[_0x124169('0x77')]['lastIndexOf']('.')+0x1);_0x2054c6===_0x124169('0x20')&&_0x5daab8['push'](getBooleanList(_0x37ec32,_0x283489,_0x1b6142,_0x51c5c7[_0x124169('0x18')],_0x44510b[_0x124169('0x18')],_0x4063ee));}}),Promise[_0x56d7ce('0x54')](_0x5daab8);})[_0x4da875('0x57')](function(_0x4bfc78){const _0x185b7b=_0x4da875;_0x3cf314=_0x4bfc78[0x0];const _0x3382c9=[],_0x7579ca=[];return _0x388fd7[_0x185b7b('0x24')](function(_0x29778c){const _0x4a28a4=_0x185b7b;if(_0x29778c[_0x4a28a4('0x77')]){const _0x30b0cc=_0x29778c[_0x4a28a4('0x77')]['substring'](_0x29778c[_0x4a28a4('0x77')][_0x4a28a4('0x37')]('.')+0x1);(_0x30b0cc===_0x4a28a4('0x6d')||_0x30b0cc==='DoubleAttributeMetadata'||_0x30b0cc===_0x4a28a4('0x44')||_0x30b0cc===_0x4a28a4('0x29')||_0x30b0cc===_0x4a28a4('0x9f')||_0x30b0cc===_0x4a28a4('0x93')||_0x30b0cc===_0x4a28a4('0xb')||_0x30b0cc==='EntityNameAttributeMetadata'||_0x30b0cc===_0x4a28a4('0x6a')||_0x30b0cc===_0x4a28a4('0x78'))&&_0x3382c9[_0x4a28a4('0x70')](getInputList(_0x37ec32,_0x283489,_0x30b0cc,_0x7579ca,_0x51c5c7['MetadataId'],_0x29778c[_0x4a28a4('0x18')],_0x4063ee));}}),Promise[_0x185b7b('0x54')](_0x3382c9);})[_0x4da875('0x57')](function(_0x5dd01c){const _0x2d7fb6=_0x4da875;_0xbaa70b=_0x5dd01c[0x0];const _0x3b915b=_0x5d362f['concat'](_0x3cf314)[_0x2d7fb6('0x7b')](_0xbaa70b),_0x225e5a={'count':_0x3b915b['length'],'rows':_0x3b915b};return _0x225e5a;})[_0x4da875('0x57')](respondWithResult(_0x3048b4,null))[_0x4da875('0x38')](function(_0x22faf8){const _0x3f685c=_0x4da875;let _0x58646c=_0x3b4f11[_0x3f685c('0x3d')][_0x3f685c('0x28')]?0x1f4:_0x22faf8[_0x3f685c('0x2')]||0x1f4;logger[_0x3f685c('0x9')](_0x22faf8[_0x3f685c('0x5f')]),delete _0x22faf8['name'],_0x58646c===0x191&&(_0x58646c=0x190),_0x3048b4['status'](_0x58646c)['send'](_0x3b4f11[_0x3f685c('0x3d')]['test']?{'message':_0x3f685c('0x7'),'statusCode':_0x22faf8[_0x3f685c('0x2')]}:_0x22faf8);});};function getSelectList(_0x3087af,_0xd2fc56,_0x39e182,_0x4c55cb,_0x416f04,_0x2dd41d){const _0x104390=_0x2e0ff3,_0x287ba1={'method':'GET','uri':_0x3087af+_0x104390('0x73')+_0x4c55cb+_0x104390('0xa0')+_0x416f04+_0x104390('0xa1')+_0x104390('0x1'),'headers':{'Authorization':'Bearer\x20'+_0x2dd41d,'If-None-Match':null,'OData-Version':_0x104390('0x47')},'json':!![]};return rp(_0x287ba1)[_0x104390('0x57')](function(_0x732a8b){const _0x24115c=_0x104390,_0x144790=[],_0x123351=_0x732a8b['OptionSet'][_0x24115c('0x5d')];_0x123351[_0x24115c('0x24')](function(_0x5d4adc){const _0x4c3b6d=_0x24115c;_0x144790['push']({'name':_0x5d4adc[_0x4c3b6d('0x40')][_0x4c3b6d('0x75')][_0x4c3b6d('0x40')],'value':String(_0x5d4adc[_0x4c3b6d('0x6f')])});});const _0x46f30b={'id':_0xd2fc56+'_'+_0x732a8b[_0x24115c('0x8c')],'name':_0x732a8b['DisplayName']['UserLocalizedLabel']['Label'],'custom':![],'options':_0x144790};return _0x39e182[_0x24115c('0x70')](_0x46f30b),_0x39e182;});}function getBooleanList(_0x381e46,_0x15f87e,_0x102f68,_0x27bdd7,_0x5ddd5c,_0x177bcb){const _0xf406ff=_0x2e0ff3,_0x2163fa={'method':_0xf406ff('0x23'),'uri':_0x381e46+'EntityDefinitions('+_0x27bdd7+_0xf406ff('0xa0')+_0x5ddd5c+_0xf406ff('0x31'),'headers':{'Authorization':_0xf406ff('0x1d')+_0x177bcb,'If-None-Match':null,'OData-Version':'4.0'},'json':!![]};return rp(_0x2163fa)[_0xf406ff('0x57')](function(_0x348713){const _0x491d5c=_0xf406ff,_0xb7ff32=[];_0xb7ff32[_0x491d5c('0x70')]({'name':_0x348713[_0x491d5c('0xa9')]['TrueOption'][_0x491d5c('0x40')][_0x491d5c('0x75')][_0x491d5c('0x40')],'value':_0x491d5c('0x63')},{'name':_0x348713[_0x491d5c('0xa9')][_0x491d5c('0x3a')][_0x491d5c('0x40')][_0x491d5c('0x75')][_0x491d5c('0x40')],'value':_0x491d5c('0x96')});const _0x297795={'id':_0x15f87e+'_'+_0x348713[_0x491d5c('0x8c')],'name':_0x348713[_0x491d5c('0xb6')][_0x491d5c('0x75')][_0x491d5c('0x40')],'custom':![],'options':_0xb7ff32};return _0x102f68[_0x491d5c('0x70')](_0x297795),_0x102f68;});}function getInputList(_0x73e044,_0x51e155,_0x3af578,_0x35ac92,_0x324179,_0x4e2db3,_0x55bda7){const _0x39cbb0=_0x2e0ff3,_0x1986d1={'method':'GET','uri':_0x73e044+_0x39cbb0('0x73')+_0x324179+')/Attributes('+_0x4e2db3+_0x39cbb0('0x90')+_0x3af578+_0x39cbb0('0x49'),'headers':{'Authorization':_0x39cbb0('0x1d')+_0x55bda7,'If-None-Match':null,'OData-Version':_0x39cbb0('0x47')},'json':!![]};return rp(_0x1986d1)['then'](function(_0x20b290){const _0xa3991=_0x39cbb0,_0x33425d={'id':_0x51e155+'_'+_0x20b290[_0xa3991('0x8c')],'name':_0x20b290[_0xa3991('0xb6')][_0xa3991('0x75')]?_0x20b290[_0xa3991('0xb6')][_0xa3991('0x75')][_0xa3991('0x40')]:_0x20b290[_0xa3991('0x8c')],'custom':![],'options':[]};return _0x35ac92[_0xa3991('0x70')](_0x33425d),_0x35ac92;});} \ No newline at end of file +const a242_0x308d=['statecode','substring','undefined','responsiblecontactidname','?$select=DisplayName,LogicalName',')?$select=LogicalName&$expand=Attributes($select=LogicalName)','index','Dynamics365Configuration','directioncode','rows','catch','modifiedonbehalfbyyominame','value','slice','body','ownerid','all','productserialnumber','LogicalName','getDescriptions','MemoAttributeMetadata','statuscode','then','Descriptions',')/Microsoft.Dynamics.CRM.','../../components/parsers/qs','msdyn_incidenttypename','../../mysqldb','actualserviceunits','error','clientSecret','createdbyexternalpartyname','owneridtype','destroy','filters','$select=DisplayName,LogicalName&$expand=OptionSet($select=Options)','modifiedbyexternalpartyyominame','PicklistAttributeMetadata','description','Incident','count','accountidyominame','DecimalAttributeMetadata','length','json','DateTimeAttributeMetadata','statusCode','Value','EntityNameAttributeMetadata','model',')/Microsoft.Dynamics.CRM.PicklistAttributeMetadata?','sort','lastIndexOf','isNil','primarycontactidname','intersection','emailaddress','true','Attributes','password','like','regardingobjectid','UserLocalizedLabel','Label','Content-Range','resolveby','../../components/integrations/configuration','escalatedon','billedserviceunits','resolvebykpiidname','Subjects','key','query','rawAttributes','4.0','subjectidname','channel','ticketType','set','phonecall_activity_parties','modifiedbyexternalpartyname','remove','entitlementidname','productidname','/oauth2/token','includes','Bearer\x20','utcconversiontimezonecode','subject','end','sequelize','FalseOption','modifiedbyname','Options','modifiedonbehalfbyname','fieldName','contactidname','PhoneCall','ticketnumber','GET','status','test','create','EntityDefinitions?$select=DisplayName,EntitySetName&$filter=SchemaName\x20eq\x20\x27','options','limit','forEach','StateAttributeMetadata','Dynamics365Account','AccountId','merge','exchangerate',')/Microsoft.Dynamics.CRM.BooleanAttributeMetadata?$select=DisplayName,LogicalName&$expand=OptionSet($select=FalseOption,\x20TrueOption)','keys','POST','includeAll','msdyn_iotalertname','false','remoteUri','lastonholdtime','prioritycodename','request-promise-native','customerid','clientId','overriddencreatedon','entityimage_url','responsiblecontactidyominame','onholdtime','access_token','DoubleAttributeMetadata','where','accountidname','modifiedon','BigIntAttributeMetadata','responseby','primarycontactidyominame','stack','send','firstresponsebykpiidname','Wrong\x20credentials','update',')/Attributes(','filter','concat','BooleanAttributeMetadata','versionnumber','../../config/logger','username','addConfiguration','include','getFields','Dynamics365Field','pick','traversedpath','DisplayName','findOne','order','name','createdon','IntegerAttributeMetadata','owneridyominame','MetadataId','attributes','transactioncurrencyidname','socialprofileidname','map','fields','show','owneridname','VIRTUAL','getConfigurations','offset','EntityDefinitions(','push','@odata.type','phonenumber','api','numberofchildincidents','OptionSet','type','parentcaseidname','influencescore','nolimit','StatusAttributeMetadata','tenantId','incident','slaname','https://login.microsoftonline.com/','kbarticleidname','params'];(function(_0x267e64,_0x308d06){const _0x30b835=function(_0xa48457){while(--_0xa48457){_0x267e64['push'](_0x267e64['shift']());}};_0x30b835(++_0x308d06);}(a242_0x308d,0xab));const a242_0x30b8=function(_0x267e64,_0x308d06){_0x267e64=_0x267e64-0x0;let _0x30b835=a242_0x308d[_0x267e64];return _0x30b835;};const _0x20f9ab=a242_0x30b8;'use strict';const rp=require(_0x20f9ab('0x8c')),util=require('util'),_=require('lodash'),qs=require(_0x20f9ab('0x2c')),logger=require(_0x20f9ab('0xa5'))(_0x20f9ab('0x5')),db=require(_0x20f9ab('0x2e'))['db'],{Op}=require(_0x20f9ab('0x6d')),integrations=require(_0x20f9ab('0x55'));function respondWithResult(_0xa48457,_0x2edb4a){return _0x2edb4a=_0x2edb4a||0xc8,function(_0xe62d2e){const _0x278312=a242_0x30b8;if(_0xe62d2e)return _0xa48457[_0x278312('0x77')](_0x2edb4a)[_0x278312('0x3f')](_0xe62d2e);};}function respondWithFilteredResult(_0x109afd,_0x270d0b){return function(_0x204a18){const _0xc2e20a=a242_0x30b8;if(_0x204a18){const _0x318043=_0x204a18[_0xc2e20a('0x3b')],_0x3566a8=_0x270d0b[_0xc2e20a('0x0')];let _0x1256f8=_0x270d0b[_0xc2e20a('0x0')]+_0x270d0b[_0xc2e20a('0x7c')],_0x41ada6;return _0x1256f8>=_0x318043?(_0x1256f8=_0x318043,_0x41ada6=0xc8):_0x41ada6=0xce,_0x109afd[_0xc2e20a('0x77')](_0x41ada6),_0x109afd[_0xc2e20a('0x61')](_0xc2e20a('0x53'),_0x3566a8+'-'+_0x1256f8+'/'+_0x318043)[_0xc2e20a('0x3f')](_0x204a18);}return null;};}function saveUpdates(_0x4d6a37){return function(_0x5846b4){const _0x4100a3=a242_0x30b8;if(_0x5846b4)return _0x5846b4['update'](_0x4d6a37)[_0x4100a3('0x29')](function(_0x5cab9c){return _0x5cab9c;});return null;};}function removeEntity(_0x4609e8){return function(_0x5ee20d){const _0x2b7f5b=a242_0x30b8;if(_0x5ee20d)return _0x5ee20d[_0x2b7f5b('0x34')]()[_0x2b7f5b('0x29')](function(){const _0x124d3e=_0x2b7f5b;_0x4609e8['status'](0xcc)[_0x124d3e('0x6c')]();});};}function handleEntityNotFound(_0x29c6c6){return function(_0x1931b1){return!_0x1931b1&&_0x29c6c6['sendStatus'](0x194),_0x1931b1;};}function handleError(_0xa15fdb,_0x113208){return _0x113208=_0x113208||0x1f4,function(_0x1b5a04){const _0x17b6d6=a242_0x30b8;logger[_0x17b6d6('0x30')](_0x1b5a04[_0x17b6d6('0x9b')]),_0x1b5a04[_0x17b6d6('0xb0')]&&delete _0x1b5a04['name'],_0xa15fdb[_0x17b6d6('0x77')](_0x113208)[_0x17b6d6('0x9c')](_0x1b5a04);};}exports[_0x20f9ab('0x19')]=function(_0xdcfdc6,_0x5adba7){const _0x2532c4=_0x20f9ab;let _0x63308e={};const _0x2f1288={},_0x545d30={'count':0x0,'rows':[]},_0x3f65ea=_['map'](db[_0x2532c4('0x7f')][_0x2532c4('0x5c')],function(_0x43a858){const _0x563e6b=_0x2532c4;return{'name':_0x43a858[_0x563e6b('0x72')],'type':_0x43a858['type'][_0x563e6b('0x5a')]};});_0x2f1288['model']=_['map'](_0x3f65ea,'name'),_0x2f1288[_0x2532c4('0x5b')]=_[_0x2532c4('0x84')](_0xdcfdc6[_0x2532c4('0x5b')]),_0x2f1288[_0x2532c4('0x35')]=_[_0x2532c4('0x4a')](_0x2f1288['model'],_0x2f1288[_0x2532c4('0x5b')]),_0x63308e[_0x2532c4('0xb5')]=_[_0x2532c4('0x4a')](_0x2f1288[_0x2532c4('0x44')],qs[_0x2532c4('0xb9')](_0xdcfdc6[_0x2532c4('0x5b')][_0x2532c4('0xb9')])),_0x63308e['attributes']=_0x63308e[_0x2532c4('0xb5')][_0x2532c4('0x3e')]?_0x63308e[_0x2532c4('0xb5')]:_0x2f1288[_0x2532c4('0x44')];typeof _0xdcfdc6[_0x2532c4('0x5b')][_0x2532c4('0xb')]===_0x2532c4('0x15')&&(_0x63308e[_0x2532c4('0x7c')]=qs[_0x2532c4('0x7c')](_0xdcfdc6[_0x2532c4('0x5b')][_0x2532c4('0x7c')]),_0x63308e[_0x2532c4('0x0')]=qs[_0x2532c4('0x0')](_0xdcfdc6[_0x2532c4('0x5b')][_0x2532c4('0x0')]));_0x63308e[_0x2532c4('0xaf')]=qs['sort'](_0xdcfdc6[_0x2532c4('0x5b')][_0x2532c4('0x46')]),_0x63308e['where']=qs['filters'](_[_0x2532c4('0xab')](_0xdcfdc6['query'],_0x2f1288[_0x2532c4('0x35')]),_0x3f65ea);_0xdcfdc6[_0x2532c4('0x5b')]['filter']&&(_0x63308e[_0x2532c4('0x95')]=_['merge'](_0x63308e[_0x2532c4('0x95')],{[Op['or']]:_[_0x2532c4('0xb8')](_0x3f65ea,function(_0x5bba3c){const _0x1da89b=_0x2532c4;if(_0x5bba3c['type']!==_0x1da89b('0xbc')){const _0x2e3f5e={};return _0x2e3f5e[_0x5bba3c[_0x1da89b('0xb0')]]={[Op['like']]:'%'+_0xdcfdc6[_0x1da89b('0x5b')][_0x1da89b('0xa1')]+'%'},_0x2e3f5e;}})}));_0x63308e=_[_0x2532c4('0x81')]({},_0x63308e,_0xdcfdc6[_0x2532c4('0x7b')]);const _0x5aeedb={'where':_0x63308e['where']};return db['Dynamics365Account'][_0x2532c4('0x3b')](_0x5aeedb)[_0x2532c4('0x29')](function(_0x5c2738){const _0x4c46e1=_0x2532c4;return _0x545d30['count']=_0x5c2738,_0xdcfdc6[_0x4c46e1('0x5b')][_0x4c46e1('0x86')]&&(_0x63308e['include']=[{'all':!![]}]),db[_0x4c46e1('0x7f')]['findAll'](_0x63308e);})['then'](function(_0x21abef){const _0x106b1f=_0x2532c4;return _0x545d30[_0x106b1f('0x1c')]=_0x21abef,_0x545d30;})[_0x2532c4('0x29')](respondWithFilteredResult(_0x5adba7,_0x63308e))['catch'](handleError(_0x5adba7,null));},exports[_0x20f9ab('0xba')]=function(_0x338dc5,_0x447627){const _0x2a388b=_0x20f9ab;let _0x3e329d={'raw':![],'where':{'id':_0x338dc5[_0x2a388b('0x12')]['id']}};const _0x59ccf0={};return _0x59ccf0[_0x2a388b('0x44')]=_['keys'](db[_0x2a388b('0x7f')][_0x2a388b('0x5c')]),_0x59ccf0[_0x2a388b('0x5b')]=_['keys'](_0x338dc5[_0x2a388b('0x5b')]),_0x59ccf0['filters']=_[_0x2a388b('0x4a')](_0x59ccf0[_0x2a388b('0x44')],_0x59ccf0[_0x2a388b('0x5b')]),_0x3e329d[_0x2a388b('0xb5')]=_[_0x2a388b('0x4a')](_0x59ccf0[_0x2a388b('0x44')],qs[_0x2a388b('0xb9')](_0x338dc5[_0x2a388b('0x5b')][_0x2a388b('0xb9')])),_0x3e329d[_0x2a388b('0xb5')]=_0x3e329d[_0x2a388b('0xb5')][_0x2a388b('0x3e')]?_0x3e329d[_0x2a388b('0xb5')]:_0x59ccf0[_0x2a388b('0x44')],_0x338dc5[_0x2a388b('0x5b')][_0x2a388b('0x86')]&&(_0x3e329d[_0x2a388b('0xa8')]=[{'all':!![]}]),_0x3e329d=_[_0x2a388b('0x81')]({},_0x3e329d,_0x338dc5['options']),db['Dynamics365Account'][_0x2a388b('0xae')](_0x3e329d)[_0x2a388b('0x29')](handleEntityNotFound(_0x447627,null))[_0x2a388b('0x29')](respondWithResult(_0x447627,null))[_0x2a388b('0x1d')](handleError(_0x447627,null));},exports['create']=function(_0x54cc24,_0x38956f){const _0x127dc6=_0x20f9ab;return db[_0x127dc6('0x7f')][_0x127dc6('0x79')](_0x54cc24[_0x127dc6('0x21')],{})[_0x127dc6('0x29')](respondWithResult(_0x38956f,0xc9))['catch'](handleError(_0x38956f,null));},exports[_0x20f9ab('0x9f')]=function(_0x5a67f0,_0x53c9ea){const _0x5cfa0e=_0x20f9ab;return _0x5a67f0[_0x5cfa0e('0x21')]['id']&&delete _0x5a67f0[_0x5cfa0e('0x21')]['id'],db['Dynamics365Account'][_0x5cfa0e('0xae')]({'where':{'id':_0x5a67f0[_0x5cfa0e('0x12')]['id']}})[_0x5cfa0e('0x29')](handleEntityNotFound(_0x53c9ea,null))['then'](saveUpdates(_0x5a67f0[_0x5cfa0e('0x21')],null))[_0x5cfa0e('0x29')](respondWithResult(_0x53c9ea,null))[_0x5cfa0e('0x1d')](handleError(_0x53c9ea,null));},exports[_0x20f9ab('0x34')]=function(_0x36991f,_0x29922c){const _0x2a11ff=_0x20f9ab;return db[_0x2a11ff('0x7f')]['findOne']({'where':{'id':_0x36991f[_0x2a11ff('0x12')]['id']}})[_0x2a11ff('0x29')](handleEntityNotFound(_0x29922c,null))[_0x2a11ff('0x29')](removeEntity(_0x29922c,null))[_0x2a11ff('0x1d')](handleError(_0x29922c,null));},exports[_0x20f9ab('0xbd')]=function(_0x22bdbf,_0x53d12d){const _0xaf647=_0x20f9ab;let _0x4241fd={};const _0x524313={};let _0x2472af,_0x136c95;return db[_0xaf647('0x7f')][_0xaf647('0xae')]({'where':{'id':_0x22bdbf[_0xaf647('0x12')]['id']}})['then'](handleEntityNotFound(_0x53d12d,null))[_0xaf647('0x29')](function(_0x253708){const _0x437eef=_0xaf647;if(_0x253708)return _0x2472af=_0x253708,_0x524313['model']=_[_0x437eef('0x84')](db[_0x437eef('0x1a')]['rawAttributes']),_0x524313['query']=_[_0x437eef('0x84')](_0x22bdbf[_0x437eef('0x5b')]),_0x524313[_0x437eef('0x35')]=_[_0x437eef('0x4a')](_0x524313['model'],_0x524313[_0x437eef('0x5b')]),_0x4241fd[_0x437eef('0xb5')]=_['intersection'](_0x524313[_0x437eef('0x44')],qs[_0x437eef('0xb9')](_0x22bdbf[_0x437eef('0x5b')][_0x437eef('0xb9')])),_0x4241fd[_0x437eef('0xb5')]=_0x4241fd[_0x437eef('0xb5')]['length']?_0x4241fd[_0x437eef('0xb5')]:_0x524313[_0x437eef('0x44')],_0x4241fd[_0x437eef('0xaf')]=qs[_0x437eef('0x46')](_0x22bdbf[_0x437eef('0x5b')][_0x437eef('0x46')]),_0x4241fd[_0x437eef('0x95')]=qs[_0x437eef('0x35')](_['pick'](_0x22bdbf[_0x437eef('0x5b')],_0x524313[_0x437eef('0x35')])),_0x22bdbf[_0x437eef('0x5b')][_0x437eef('0xa1')]&&(_0x4241fd[_0x437eef('0x95')]=_['merge'](_0x4241fd['where'],{[Op['or']]:_[_0x437eef('0xb8')](_0x4241fd[_0x437eef('0xb5')],function(_0x249b18){const _0x24b1e5=_0x437eef,_0x439ef2={};return _0x439ef2[_0x249b18]={[Op[_0x24b1e5('0x4f')]]:'%'+_0x22bdbf[_0x24b1e5('0x5b')]['filter']+'%'},_0x439ef2;})})),_0x4241fd=_[_0x437eef('0x81')]({},_0x4241fd,_0x22bdbf[_0x437eef('0x7b')]),_0x2472af[_0x437eef('0xbd')](_0x4241fd);})[_0xaf647('0x29')](function(_0x1bd8fa){const _0x154773=_0xaf647;if(_0x1bd8fa)return _0x136c95=_0x1bd8fa['length'],typeof _0x22bdbf[_0x154773('0x5b')][_0x154773('0xb')]==='undefined'&&(_0x4241fd[_0x154773('0x7c')]=qs['limit'](_0x22bdbf['query'][_0x154773('0x7c')]),_0x4241fd[_0x154773('0x0')]=qs[_0x154773('0x0')](_0x22bdbf[_0x154773('0x5b')][_0x154773('0x0')])),_0x2472af[_0x154773('0xbd')](_0x4241fd);})[_0xaf647('0x29')](function(_0x336017){if(_0x336017)return _0x336017?{'count':_0x136c95,'rows':_0x336017}:null;})[_0xaf647('0x29')](respondWithResult(_0x53d12d,null))[_0xaf647('0x1d')](handleError(_0x53d12d,null));},exports[_0x20f9ab('0xa7')]=function(_0x33e8d0,_0x329ef9){const _0x30ead8=_0x20f9ab;return _0x33e8d0[_0x30ead8('0x21')]['id']&&delete _0x33e8d0[_0x30ead8('0x21')]['id'],db[_0x30ead8('0x7f')][_0x30ead8('0xae')]({'where':{'id':_0x33e8d0[_0x30ead8('0x12')]['id']}})[_0x30ead8('0x29')](handleEntityNotFound(_0x329ef9,null))[_0x30ead8('0x29')](function(_0x47236a){const _0x3d76d8=_0x30ead8;if(_0x47236a)return _0x33e8d0[_0x3d76d8('0x21')][_0x3d76d8('0x80')]=_0x47236a['id'],_0x33e8d0[_0x3d76d8('0x21')][_0x3d76d8('0x59')]=integrations['getSubjects'](_0x33e8d0[_0x3d76d8('0x21')]['channel'],_0x33e8d0['body'][_0x3d76d8('0x8')]),_0x33e8d0[_0x3d76d8('0x21')][_0x3d76d8('0x2a')]=integrations[_0x3d76d8('0x26')](_0x33e8d0[_0x3d76d8('0x21')][_0x3d76d8('0x5f')],_0x33e8d0[_0x3d76d8('0x21')]['type']),db[_0x3d76d8('0x1a')][_0x3d76d8('0x79')](_0x33e8d0[_0x3d76d8('0x21')],{'include':[{'model':db[_0x3d76d8('0xaa')],'as':_0x3d76d8('0x59')},{'model':db[_0x3d76d8('0xaa')],'as':_0x3d76d8('0x2a')}]});return null;})[_0x30ead8('0x29')](respondWithResult(_0x329ef9,null))[_0x30ead8('0x1d')](handleError(_0x329ef9,null));},exports[_0x20f9ab('0xa9')]=function(_0x1b6ec6,_0xf58a91){const _0x2420dc=_0x20f9ab,_0x3658a4=_0x1b6ec6['query'][_0x2420dc('0x60')],_0x3f7e21=_0x3658a4===_0x2420dc('0xe')?_0x2420dc('0x3a'):_0x2420dc('0x74');let _0x3c948f='',_0x50751b='',_0x4130e5='',_0x48c2a6='',_0x54caf3='',_0x46bb82='',_0x567499='',_0x5424f2='';const _0xe1d4c5=['title',_0x2420dc('0x39'),_0x2420dc('0x8d'),_0x2420dc('0x22'),'caseorigincode',_0x2420dc('0x6b'),_0x2420dc('0x4'),_0x2420dc('0x50'),_0x2420dc('0x1b'),_0x2420dc('0x62')],_0x1868c9=[_0x2420dc('0x96'),_0x2420dc('0x3c'),_0x2420dc('0x2f'),_0x2420dc('0x57'),_0x2420dc('0x73'),'contactidyominame','contractdetailidname','contractidname',_0x2420dc('0x32'),'createdbyexternalpartyyominame','createdbyname','createdbyyominame',_0x2420dc('0xb1'),'createdonbehalfbyname','createdonbehalfbyyominame','customeridname','customeridtype','customeridyominame',_0x2420dc('0x4b'),_0x2420dc('0x65'),'entityimage_timestamp',_0x2420dc('0x90'),_0x2420dc('0x56'),_0x2420dc('0x82'),_0x2420dc('0x9d'),'followupby','importsequencenumber',_0x2420dc('0xa'),_0x2420dc('0x11'),_0x2420dc('0x8a'),'masteridname',_0x2420dc('0x63'),_0x2420dc('0x37'),_0x2420dc('0x6f'),'modifiedbyyominame',_0x2420dc('0x97'),_0x2420dc('0x71'),_0x2420dc('0x1e'),_0x2420dc('0x2d'),_0x2420dc('0x87'),_0x2420dc('0x6'),_0x2420dc('0x92'),_0x2420dc('0x8f'),_0x2420dc('0xbb'),_0x2420dc('0x33'),_0x2420dc('0xb3'),_0x2420dc('0x9'),_0x2420dc('0x49'),_0x2420dc('0x9a'),_0x2420dc('0x8b'),_0x2420dc('0x66'),_0x2420dc('0x24'),_0x2420dc('0x54'),_0x2420dc('0x58'),_0x2420dc('0x99'),_0x2420dc('0x16'),_0x2420dc('0x91'),'sentimentvalue','slainvokedidname',_0x2420dc('0xf'),_0x2420dc('0xb7'),_0x2420dc('0x13'),_0x2420dc('0x28'),_0x2420dc('0x5e'),_0x2420dc('0x75'),'timezoneruleversionnumber',_0x2420dc('0xb6'),_0x2420dc('0xac'),_0x2420dc('0x6a'),_0x2420dc('0xa4')],_0x4a2f49=_0xe1d4c5[_0x2420dc('0xa2')](_0x1868c9);return db[_0x2420dc('0x7f')][_0x2420dc('0xae')]({'where':{'id':_0x1b6ec6[_0x2420dc('0x12')]['id']},'attributes':['id',_0x2420dc('0xa6'),'password',_0x2420dc('0x89'),_0x2420dc('0xd'),_0x2420dc('0x8e'),_0x2420dc('0x31')]})[_0x2420dc('0x29')](handleEntityNotFound(_0xf58a91,null))[_0x2420dc('0x29')](function(_0x466410){const _0x345d03=_0x2420dc;if(_0x466410){_0x5424f2=_0x466410['remoteUri'];const _0x1c0bd7=_0x5424f2[_0x345d03('0x20')](-0x1);_0x1c0bd7==='/'&&(_0x5424f2=_0x5424f2[_0x345d03('0x14')](0x0,_0x5424f2['lastIndexOf'](_0x1c0bd7)));_0x567499=util['format']('%s/api/data/v9.0/',_0x5424f2);const _0x19c056={'method':_0x345d03('0x85'),'uri':_0x345d03('0x10')+_0x466410[_0x345d03('0xd')]+_0x345d03('0x67'),'form':{'client_id':_0x466410['clientId'],'resource':_0x5424f2,'username':_0x466410[_0x345d03('0xa6')],'password':_0x466410[_0x345d03('0x4e')],'grant_type':'password','client_secret':_0x466410[_0x345d03('0x31')]},'json':!![]};return rp(_0x19c056);}})[_0x2420dc('0x29')](function(_0x389d91){const _0x5c99c1=_0x2420dc;_0x46bb82=_0x389d91[_0x5c99c1('0x93')];const _0x4267d2={'method':_0x5c99c1('0x76'),'uri':encodeURI(_0x567499+_0x5c99c1('0x7a')+_0x3f7e21+'\x27'),'headers':{'Authorization':_0x5c99c1('0x69')+_0x46bb82,'If-None-Match':null,'OData-Version':_0x5c99c1('0x5d')},'json':!![]};return rp(_0x4267d2);})[_0x2420dc('0x29')](function(_0x5d96d9){const _0x4771ef=_0x2420dc,_0x4efd8d=_0x5d96d9[_0x4771ef('0x1f')][0x0],_0x160639=_0x4efd8d[_0x4771ef('0xb4')],_0x4cb996={'method':_0x4771ef('0x76'),'uri':_0x567499+_0x4771ef('0x1')+_0x160639+_0x4771ef('0x18'),'headers':{'Authorization':_0x4771ef('0x69')+_0x46bb82,'If-None-Match':null,'OData-Version':'4.0'},'json':!![]};return rp(_0x4cb996);})[_0x2420dc('0x29')](function(_0x47682a){const _0x57a276=_0x2420dc;_0x3c948f=_0x47682a,_0x50751b=_0x3c948f[_0x57a276('0x4d')],_0x50751b=_[_0x57a276('0x64')](_0x50751b,function(_0x5dd987){const _0x239d15=_0x57a276;return!_0x4a2f49[_0x239d15('0x68')](_0x5dd987[_0x239d15('0x25')]);});const _0x57a0e1=[],_0x3f0570=[];return _0x50751b[_0x57a276('0x7d')](function(_0x1acfb3){const _0x4c9f1c=_0x57a276;if(_0x1acfb3[_0x4c9f1c('0x3')]){const _0x15f277=_0x1acfb3['@odata.type']['substring'](_0x1acfb3['@odata.type'][_0x4c9f1c('0x47')]('.')+0x1);_0x15f277===_0x4c9f1c('0x38')&&_0x57a0e1['push'](getSelectList(_0x567499,_0x3658a4,_0x3f0570,_0x3c948f[_0x4c9f1c('0xb4')],_0x1acfb3['MetadataId'],_0x46bb82));}}),Promise[_0x57a276('0x23')](_0x57a0e1);})[_0x2420dc('0x29')](function(_0x4495a6){const _0x2c944e=_0x2420dc;_0x4130e5=_0x4495a6[0x0];const _0x2083b7=[],_0x36af76=[];return _0x50751b[_0x2c944e('0x7d')](function(_0x357b8c){const _0x206d94=_0x2c944e;if(!_[_0x206d94('0x48')](_0x357b8c[_0x206d94('0x3')])){const _0x2f6340=_0x357b8c[_0x206d94('0x3')][_0x206d94('0x14')](_0x357b8c[_0x206d94('0x3')][_0x206d94('0x47')]('.')+0x1);_0x2f6340===_0x206d94('0xa3')&&_0x2083b7[_0x206d94('0x2')](getBooleanList(_0x567499,_0x3658a4,_0x36af76,_0x3c948f[_0x206d94('0xb4')],_0x357b8c['MetadataId'],_0x46bb82));}}),Promise[_0x2c944e('0x23')](_0x2083b7);})['then'](function(_0x322923){const _0x2fee40=_0x2420dc;_0x48c2a6=_0x322923[0x0];const _0x5b6682=[],_0xe854cc=[];return _0x50751b[_0x2fee40('0x7d')](function(_0xef8e26){const _0x30fb06=_0x2fee40;if(_0xef8e26[_0x30fb06('0x3')]){const _0x23aa54=_0xef8e26['@odata.type'][_0x30fb06('0x14')](_0xef8e26[_0x30fb06('0x3')][_0x30fb06('0x47')]('.')+0x1);(_0x23aa54==='StringAttributeMetadata'||_0x23aa54===_0x30fb06('0x94')||_0x23aa54===_0x30fb06('0x98')||_0x23aa54===_0x30fb06('0xb2')||_0x23aa54===_0x30fb06('0x27')||_0x23aa54===_0x30fb06('0x40')||_0x23aa54===_0x30fb06('0xc')||_0x23aa54===_0x30fb06('0x43')||_0x23aa54===_0x30fb06('0x7e')||_0x23aa54===_0x30fb06('0x3d'))&&_0x5b6682[_0x30fb06('0x2')](getInputList(_0x567499,_0x3658a4,_0x23aa54,_0xe854cc,_0x3c948f[_0x30fb06('0xb4')],_0xef8e26['MetadataId'],_0x46bb82));}}),Promise['all'](_0x5b6682);})['then'](function(_0x211f2d){const _0x2f5216=_0x2420dc;_0x54caf3=_0x211f2d[0x0];const _0x5909b5=_0x4130e5[_0x2f5216('0xa2')](_0x48c2a6)[_0x2f5216('0xa2')](_0x54caf3),_0x5424fb={'count':_0x5909b5[_0x2f5216('0x3e')],'rows':_0x5909b5};return _0x5424fb;})[_0x2420dc('0x29')](respondWithResult(_0xf58a91,null))['catch'](function(_0x55e17e){const _0x149c26=_0x2420dc;let _0x3779c2=_0x1b6ec6[_0x149c26('0x5b')]['test']?0x1f4:_0x55e17e[_0x149c26('0x41')]||0x1f4;logger[_0x149c26('0x30')](_0x55e17e[_0x149c26('0x9b')]),delete _0x55e17e[_0x149c26('0xb0')],_0x3779c2===0x191&&(_0x3779c2=0x190),_0xf58a91[_0x149c26('0x77')](_0x3779c2)['send'](_0x1b6ec6[_0x149c26('0x5b')][_0x149c26('0x78')]?{'message':_0x149c26('0x9e'),'statusCode':_0x55e17e[_0x149c26('0x41')]}:_0x55e17e);});};function getSelectList(_0x17b142,_0x102309,_0x5c9fcf,_0x4572ae,_0x492a0e,_0xc10a04){const _0x392023=_0x20f9ab,_0x42861c={'method':_0x392023('0x76'),'uri':_0x17b142+_0x392023('0x1')+_0x4572ae+_0x392023('0xa0')+_0x492a0e+_0x392023('0x45')+_0x392023('0x36'),'headers':{'Authorization':_0x392023('0x69')+_0xc10a04,'If-None-Match':null,'OData-Version':_0x392023('0x5d')},'json':!![]};return rp(_0x42861c)[_0x392023('0x29')](function(_0x30f7dd){const _0x1cd5f2=_0x392023,_0x11b40a=[],_0x58aa7b=_0x30f7dd[_0x1cd5f2('0x7')][_0x1cd5f2('0x70')];_0x58aa7b['forEach'](function(_0x1ff8b2){const _0x5cf3d5=_0x1cd5f2;_0x11b40a['push']({'name':_0x1ff8b2[_0x5cf3d5('0x52')][_0x5cf3d5('0x51')]['Label'],'value':String(_0x1ff8b2[_0x5cf3d5('0x42')])});});const _0xed23ec={'id':_0x102309+'_'+_0x30f7dd[_0x1cd5f2('0x25')],'name':_0x30f7dd[_0x1cd5f2('0xad')][_0x1cd5f2('0x51')][_0x1cd5f2('0x52')],'custom':![],'options':_0x11b40a};return _0x5c9fcf[_0x1cd5f2('0x2')](_0xed23ec),_0x5c9fcf;});}function getBooleanList(_0x3c1df9,_0x579259,_0x287638,_0x47c53c,_0x22d000,_0x4e22f7){const _0xc73c1c=_0x20f9ab,_0x2525cf={'method':_0xc73c1c('0x76'),'uri':_0x3c1df9+_0xc73c1c('0x1')+_0x47c53c+_0xc73c1c('0xa0')+_0x22d000+_0xc73c1c('0x83'),'headers':{'Authorization':'Bearer\x20'+_0x4e22f7,'If-None-Match':null,'OData-Version':_0xc73c1c('0x5d')},'json':!![]};return rp(_0x2525cf)[_0xc73c1c('0x29')](function(_0x4dc231){const _0xa56bc=_0xc73c1c,_0x27de71=[];_0x27de71['push']({'name':_0x4dc231['OptionSet']['TrueOption']['Label'][_0xa56bc('0x51')][_0xa56bc('0x52')],'value':_0xa56bc('0x4c')},{'name':_0x4dc231[_0xa56bc('0x7')][_0xa56bc('0x6e')][_0xa56bc('0x52')][_0xa56bc('0x51')]['Label'],'value':_0xa56bc('0x88')});const _0x59f10c={'id':_0x579259+'_'+_0x4dc231[_0xa56bc('0x25')],'name':_0x4dc231['DisplayName'][_0xa56bc('0x51')][_0xa56bc('0x52')],'custom':![],'options':_0x27de71};return _0x287638[_0xa56bc('0x2')](_0x59f10c),_0x287638;});}function getInputList(_0x5a572d,_0x51fa7e,_0x4e38cf,_0x5debcf,_0x422231,_0x31ce15,_0x5e5082){const _0x570b06=_0x20f9ab,_0x3aa41b={'method':_0x570b06('0x76'),'uri':_0x5a572d+_0x570b06('0x1')+_0x422231+_0x570b06('0xa0')+_0x31ce15+_0x570b06('0x2b')+_0x4e38cf+_0x570b06('0x17'),'headers':{'Authorization':_0x570b06('0x69')+_0x5e5082,'If-None-Match':null,'OData-Version':_0x570b06('0x5d')},'json':!![]};return rp(_0x3aa41b)[_0x570b06('0x29')](function(_0x48fb1a){const _0x2ea9ea=_0x570b06,_0xb27bf3={'id':_0x51fa7e+'_'+_0x48fb1a[_0x2ea9ea('0x25')],'name':_0x48fb1a[_0x2ea9ea('0xad')][_0x2ea9ea('0x51')]?_0x48fb1a[_0x2ea9ea('0xad')][_0x2ea9ea('0x51')][_0x2ea9ea('0x52')]:_0x48fb1a[_0x2ea9ea('0x25')],'custom':![],'options':[]};return _0x5debcf[_0x2ea9ea('0x2')](_0xb27bf3),_0x5debcf;});} \ No newline at end of file diff --git a/server/api/intDynamics365Account/intDynamics365Account.model.js b/server/api/intDynamics365Account/intDynamics365Account.model.js index 2478654..636b8b2 100644 --- a/server/api/intDynamics365Account/intDynamics365Account.model.js +++ b/server/api/intDynamics365Account/intDynamics365Account.model.js @@ -1 +1 @@ -const a243_0x233b=['define','./intDynamics365Account.attributes','exports'];(function(_0x48553d,_0x233b18){const _0x385429=function(_0x61f349){while(--_0x61f349){_0x48553d['push'](_0x48553d['shift']());}};_0x385429(++_0x233b18);}(a243_0x233b,0x88));const a243_0x3854=function(_0x48553d,_0x233b18){_0x48553d=_0x48553d-0x0;let _0x385429=a243_0x233b[_0x48553d];return _0x385429;};const _0x25617c=a243_0x3854;'use strict';const attributes=require(_0x25617c('0x0'));module[_0x25617c('0x1')]=function(_0x61f349){const _0x1be55c=_0x25617c,_0x2b0f8e=_0x61f349[_0x1be55c('0x2')]('Dynamics365Account',attributes,{'tableName':'int_dynamics365_accounts','paranoid':![],'indexes':[],'timestamps':!![]});return _0x2b0f8e;}; \ No newline at end of file +const a243_0x3c53=['define','int_dynamics365_accounts','exports','Dynamics365Account'];(function(_0x61506,_0x3c5320){const _0x41dd75=function(_0x31befd){while(--_0x31befd){_0x61506['push'](_0x61506['shift']());}};_0x41dd75(++_0x3c5320);}(a243_0x3c53,0x151));const a243_0x41dd=function(_0x61506,_0x3c5320){_0x61506=_0x61506-0x0;let _0x41dd75=a243_0x3c53[_0x61506];return _0x41dd75;};const _0x27e9ad=a243_0x41dd;'use strict';const attributes=require('./intDynamics365Account.attributes');module[_0x27e9ad('0x1')]=function(_0x31befd){const _0x5437cd=_0x27e9ad,_0x106528=_0x31befd[_0x5437cd('0x3')](_0x5437cd('0x2'),attributes,{'tableName':_0x5437cd('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x106528;}; \ No newline at end of file diff --git a/server/api/intDynamics365Account/intDynamics365Account.rpc.js b/server/api/intDynamics365Account/intDynamics365Account.rpc.js index 9d5d9c7..7c3fc4d 100644 --- a/server/api/intDynamics365Account/intDynamics365Account.rpc.js +++ b/server/api/intDynamics365Account/intDynamics365Account.rpc.js @@ -1 +1 @@ -const a244_0x5c40=['where','include','raw','Dynamics365Account','options','debug','lodash','message','GetDynamics365Account','attributes','../../config/logger','catch','ShowDynamics365Account','model','limit','then','../../mysqldb','info','rpc','map','stringify','error'];(function(_0x5a5796,_0x5c4069){const _0x430b38=function(_0xf071e7){while(--_0xf071e7){_0x5a5796['push'](_0x5a5796['shift']());}};_0x430b38(++_0x5c4069);}(a244_0x5c40,0x159));const a244_0x430b=function(_0x5a5796,_0x5c4069){_0x5a5796=_0x5a5796-0x0;let _0x430b38=a244_0x5c40[_0x5a5796];return _0x430b38;};const _0x439518=a244_0x430b;'use strict';const _=require(_0x439518('0xd')),db=require(_0x439518('0x1'))['db'],logger=require(_0x439518('0x11'))(_0x439518('0x3'));exports[_0x439518('0xf')]=function(_0xf071e7){const _0x4f20cc=this;return new Promise(function(_0xa0fbae,_0x3678fb){const _0x172d7c=a244_0x430b;return db[_0x172d7c('0xa')]['findAll']({'raw':_0xf071e7[_0x172d7c('0xb')]?_0xf071e7[_0x172d7c('0xb')]['raw']===undefined?!![]:![]:!![],'where':_0xf071e7[_0x172d7c('0xb')]?_0xf071e7['options'][_0x172d7c('0x7')]||null:null,'attributes':_0xf071e7['options']?_0xf071e7[_0x172d7c('0xb')][_0x172d7c('0x10')]||null:null,'limit':_0xf071e7[_0x172d7c('0xb')]?_0xf071e7[_0x172d7c('0xb')][_0x172d7c('0x15')]||null:null,'include':_0xf071e7['options']?_0xf071e7['options']['include']?_[_0x172d7c('0x4')](_0xf071e7[_0x172d7c('0xb')][_0x172d7c('0x8')],function(_0x5ec13c){const _0x573e67=_0x172d7c;return{'model':db[_0x5ec13c[_0x573e67('0x14')]],'as':_0x5ec13c['as'],'attributes':_0x5ec13c['attributes'],'include':_0x5ec13c[_0x573e67('0x8')]?_[_0x573e67('0x4')](_0x5ec13c[_0x573e67('0x8')],function(_0x44f0a3){const _0x46e0cd=_0x573e67;return{'model':db[_0x44f0a3[_0x46e0cd('0x14')]],'as':_0x44f0a3['as'],'attributes':_0x44f0a3[_0x46e0cd('0x10')],'include':_0x44f0a3[_0x46e0cd('0x8')]?_[_0x46e0cd('0x4')](_0x44f0a3[_0x46e0cd('0x8')],function(_0x575529){const _0x4fd45a=_0x46e0cd;return{'model':db[_0x575529[_0x4fd45a('0x14')]],'as':_0x575529['as'],'attributes':_0x575529[_0x4fd45a('0x10')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x520de9){const _0x485cc2=_0x172d7c;logger['info'](_0x485cc2('0xf'),_0xf071e7),logger[_0x485cc2('0xc')](_0x485cc2('0xf'),_0xf071e7,JSON[_0x485cc2('0x5')](_0x520de9)),_0xa0fbae(_0x520de9);})[_0x172d7c('0x12')](function(_0x35b4b8){const _0xf6907f=_0x172d7c;logger[_0xf6907f('0x6')](_0xf6907f('0xf'),_0x35b4b8[_0xf6907f('0xe')],_0xf071e7),_0x3678fb(_0x4f20cc[_0xf6907f('0x6')](0x1f4,_0x35b4b8['message']));});});},exports['ShowDynamics365Account']=function(_0x422dd0){const _0x3272df=this;return new Promise(function(_0x540780,_0x48ce85){const _0xf49e62=a244_0x430b;return db[_0xf49e62('0xa')]['findOne']({'raw':_0x422dd0[_0xf49e62('0xb')]?_0x422dd0['options'][_0xf49e62('0x9')]===undefined?!![]:![]:!![],'where':_0x422dd0['options']?_0x422dd0[_0xf49e62('0xb')][_0xf49e62('0x7')]||null:null,'attributes':_0x422dd0[_0xf49e62('0xb')]?_0x422dd0['options'][_0xf49e62('0x10')]||null:null,'include':_0x422dd0[_0xf49e62('0xb')]?_0x422dd0[_0xf49e62('0xb')][_0xf49e62('0x8')]?_['map'](_0x422dd0['options'][_0xf49e62('0x8')],function(_0x46ee5f){const _0x4a559=_0xf49e62;return{'model':db[_0x46ee5f[_0x4a559('0x14')]],'as':_0x46ee5f['as'],'attributes':_0x46ee5f[_0x4a559('0x10')],'include':_0x46ee5f[_0x4a559('0x8')]?_[_0x4a559('0x4')](_0x46ee5f[_0x4a559('0x8')],function(_0x1412c5){const _0x1fb524=_0x4a559;return{'model':db[_0x1412c5[_0x1fb524('0x14')]],'as':_0x1412c5['as'],'attributes':_0x1412c5[_0x1fb524('0x10')],'include':_0x1412c5['include']?_[_0x1fb524('0x4')](_0x1412c5['include'],function(_0x1b1584){const _0x28a7f5=_0x1fb524;return{'model':db[_0x1b1584['model']],'as':_0x1b1584['as'],'attributes':_0x1b1584[_0x28a7f5('0x10')]};}):[]};}):[]};}):[]:[]})[_0xf49e62('0x0')](function(_0x55803b){const _0x2786a9=_0xf49e62;logger[_0x2786a9('0x2')](_0x2786a9('0x13'),_0x422dd0),logger[_0x2786a9('0xc')](_0x2786a9('0x13'),_0x422dd0,JSON['stringify'](_0x55803b)),_0x540780(_0x55803b);})[_0xf49e62('0x12')](function(_0x45f298){const _0x16dbe8=_0xf49e62;logger['error']('ShowDynamics365Account',_0x45f298['message'],_0x422dd0),_0x48ce85(_0x3272df['error'](0x1f4,_0x45f298[_0x16dbe8('0xe')]));});});}; \ No newline at end of file +const a244_0x326d=['options','attributes','../../config/logger','catch','debug','Dynamics365Account','map','model','then','message','GetDynamics365Account','raw','error','ShowDynamics365Account','stringify','include','where','../../mysqldb','rpc','findOne','findAll','info'];(function(_0x5b551b,_0x326d7f){const _0x300cc1=function(_0xf1cec8){while(--_0xf1cec8){_0x5b551b['push'](_0x5b551b['shift']());}};_0x300cc1(++_0x326d7f);}(a244_0x326d,0x9a));const a244_0x300c=function(_0x5b551b,_0x326d7f){_0x5b551b=_0x5b551b-0x0;let _0x300cc1=a244_0x326d[_0x5b551b];return _0x300cc1;};const _0x6c761a=a244_0x300c;'use strict';const _=require('lodash'),db=require(_0x6c761a('0x11'))['db'],logger=require(_0x6c761a('0x2'))(_0x6c761a('0x12'));exports[_0x6c761a('0xa')]=function(_0xf1cec8){const _0x32c459=this;return new Promise(function(_0x4b8998,_0x3fcae0){const _0x420eec=a244_0x300c;return db[_0x420eec('0x5')][_0x420eec('0x14')]({'raw':_0xf1cec8[_0x420eec('0x0')]?_0xf1cec8[_0x420eec('0x0')]['raw']===undefined?!![]:![]:!![],'where':_0xf1cec8['options']?_0xf1cec8['options'][_0x420eec('0x10')]||null:null,'attributes':_0xf1cec8['options']?_0xf1cec8[_0x420eec('0x0')][_0x420eec('0x1')]||null:null,'limit':_0xf1cec8[_0x420eec('0x0')]?_0xf1cec8[_0x420eec('0x0')]['limit']||null:null,'include':_0xf1cec8[_0x420eec('0x0')]?_0xf1cec8[_0x420eec('0x0')][_0x420eec('0xf')]?_[_0x420eec('0x6')](_0xf1cec8[_0x420eec('0x0')][_0x420eec('0xf')],function(_0x4f0a22){const _0x3234e7=_0x420eec;return{'model':db[_0x4f0a22[_0x3234e7('0x7')]],'as':_0x4f0a22['as'],'attributes':_0x4f0a22[_0x3234e7('0x1')],'include':_0x4f0a22[_0x3234e7('0xf')]?_['map'](_0x4f0a22['include'],function(_0x5eefdd){const _0xa04e70=_0x3234e7;return{'model':db[_0x5eefdd[_0xa04e70('0x7')]],'as':_0x5eefdd['as'],'attributes':_0x5eefdd[_0xa04e70('0x1')],'include':_0x5eefdd[_0xa04e70('0xf')]?_[_0xa04e70('0x6')](_0x5eefdd['include'],function(_0x51206d){const _0x361baf=_0xa04e70;return{'model':db[_0x51206d[_0x361baf('0x7')]],'as':_0x51206d['as'],'attributes':_0x51206d[_0x361baf('0x1')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x133375){const _0x4f0f92=_0x420eec;logger[_0x4f0f92('0x15')](_0x4f0f92('0xa'),_0xf1cec8),logger[_0x4f0f92('0x4')](_0x4f0f92('0xa'),_0xf1cec8,JSON[_0x4f0f92('0xe')](_0x133375)),_0x4b8998(_0x133375);})['catch'](function(_0x41dca9){const _0x504cff=_0x420eec;logger['error'](_0x504cff('0xa'),_0x41dca9[_0x504cff('0x9')],_0xf1cec8),_0x3fcae0(_0x32c459['error'](0x1f4,_0x41dca9['message']));});});},exports[_0x6c761a('0xd')]=function(_0x5e5a57){const _0x59ecd6=this;return new Promise(function(_0x3e9388,_0x3b13b9){const _0xa4d93=a244_0x300c;return db[_0xa4d93('0x5')][_0xa4d93('0x13')]({'raw':_0x5e5a57[_0xa4d93('0x0')]?_0x5e5a57['options'][_0xa4d93('0xb')]===undefined?!![]:![]:!![],'where':_0x5e5a57[_0xa4d93('0x0')]?_0x5e5a57['options']['where']||null:null,'attributes':_0x5e5a57[_0xa4d93('0x0')]?_0x5e5a57[_0xa4d93('0x0')][_0xa4d93('0x1')]||null:null,'include':_0x5e5a57[_0xa4d93('0x0')]?_0x5e5a57[_0xa4d93('0x0')][_0xa4d93('0xf')]?_['map'](_0x5e5a57['options'][_0xa4d93('0xf')],function(_0x5a1dc4){const _0x3f5479=_0xa4d93;return{'model':db[_0x5a1dc4[_0x3f5479('0x7')]],'as':_0x5a1dc4['as'],'attributes':_0x5a1dc4[_0x3f5479('0x1')],'include':_0x5a1dc4[_0x3f5479('0xf')]?_['map'](_0x5a1dc4[_0x3f5479('0xf')],function(_0x1b5c9b){const _0x265289=_0x3f5479;return{'model':db[_0x1b5c9b[_0x265289('0x7')]],'as':_0x1b5c9b['as'],'attributes':_0x1b5c9b[_0x265289('0x1')],'include':_0x1b5c9b[_0x265289('0xf')]?_[_0x265289('0x6')](_0x1b5c9b[_0x265289('0xf')],function(_0x3b024e){const _0x104021=_0x265289;return{'model':db[_0x3b024e[_0x104021('0x7')]],'as':_0x3b024e['as'],'attributes':_0x3b024e[_0x104021('0x1')]};}):[]};}):[]};}):[]:[]})[_0xa4d93('0x8')](function(_0x4dd78e){const _0x1a75c2=_0xa4d93;logger[_0x1a75c2('0x15')](_0x1a75c2('0xd'),_0x5e5a57),logger['debug']('ShowDynamics365Account',_0x5e5a57,JSON[_0x1a75c2('0xe')](_0x4dd78e)),_0x3e9388(_0x4dd78e);})[_0xa4d93('0x3')](function(_0x58f30e){const _0x20d22c=_0xa4d93;logger[_0x20d22c('0xc')](_0x20d22c('0xd'),_0x58f30e[_0x20d22c('0x9')],_0x5e5a57),_0x3b13b9(_0x59ecd6[_0x20d22c('0xc')](0x1f4,_0x58f30e[_0x20d22c('0x9')]));});});}; \ No newline at end of file diff --git a/server/api/intDynamics365Configuration/index.js b/server/api/intDynamics365Configuration/index.js index 3c30a55..11ed3ad 100644 --- a/server/api/intDynamics365Configuration/index.js +++ b/server/api/intDynamics365Configuration/index.js @@ -1 +1 @@ -const a245_0x3491=['isAuthenticated','/:id/descriptions','get','put','delete','/:id/fields','show','create','../../components/auth/service','update','getSubjects','exports','/:id/subjects','/:id','express','post','Router'];(function(_0x20452d,_0x3491c0){const _0x497e46=function(_0xbde0b5){while(--_0xbde0b5){_0x20452d['push'](_0x20452d['shift']());}};_0x497e46(++_0x3491c0);}(a245_0x3491,0x134));const a245_0x497e=function(_0x20452d,_0x3491c0){_0x20452d=_0x20452d-0x0;let _0x497e46=a245_0x3491[_0x20452d];return _0x497e46;};const _0x35d098=a245_0x497e;'use strict';const express=require(_0x35d098('0xc')),router=express[_0x35d098('0xe')](),auth=require(_0x35d098('0x6')),controller=require('./intDynamics365Configuration.controller');router[_0x35d098('0x0')]('/',auth[_0x35d098('0xf')](),controller['index']),router['get'](_0x35d098('0xb'),auth[_0x35d098('0xf')](),controller[_0x35d098('0x4')]),router[_0x35d098('0x0')](_0x35d098('0x3'),auth['isAuthenticated'](),controller['getFields']),router[_0x35d098('0x0')](_0x35d098('0xa'),auth['isAuthenticated'](),controller[_0x35d098('0x8')]),router[_0x35d098('0x0')](_0x35d098('0x10'),auth['isAuthenticated'](),controller['getDescriptions']),router[_0x35d098('0xd')]('/',auth[_0x35d098('0xf')](),controller[_0x35d098('0x5')]),router[_0x35d098('0x1')](_0x35d098('0xb'),auth['isAuthenticated'](),controller[_0x35d098('0x7')]),router[_0x35d098('0x2')](_0x35d098('0xb'),auth[_0x35d098('0xf')](),controller['destroy']),module[_0x35d098('0x9')]=router; \ No newline at end of file +const a245_0x1cf5=['get','show','/:id/subjects','../../components/auth/service','exports','index','isAuthenticated','create','/:id','destroy','./intDynamics365Configuration.controller','express','getDescriptions','/:id/descriptions','getSubjects'];(function(_0x34cf1a,_0x1cf596){const _0x1b2887=function(_0xd9fd7f){while(--_0xd9fd7f){_0x34cf1a['push'](_0x34cf1a['shift']());}};_0x1b2887(++_0x1cf596);}(a245_0x1cf5,0xfe));const a245_0x1b28=function(_0x34cf1a,_0x1cf596){_0x34cf1a=_0x34cf1a-0x0;let _0x1b2887=a245_0x1cf5[_0x34cf1a];return _0x1b2887;};const _0x1311da=a245_0x1b28;'use strict';const express=require(_0x1311da('0xc')),router=express['Router'](),auth=require(_0x1311da('0x4')),controller=require(_0x1311da('0xb'));router[_0x1311da('0x1')]('/',auth[_0x1311da('0x7')](),controller[_0x1311da('0x6')]),router['get'](_0x1311da('0x9'),auth['isAuthenticated'](),controller[_0x1311da('0x2')]),router['get']('/:id/fields',auth['isAuthenticated'](),controller['getFields']),router['get'](_0x1311da('0x3'),auth[_0x1311da('0x7')](),controller[_0x1311da('0x0')]),router[_0x1311da('0x1')](_0x1311da('0xe'),auth[_0x1311da('0x7')](),controller[_0x1311da('0xd')]),router['post']('/',auth['isAuthenticated'](),controller[_0x1311da('0x8')]),router['put'](_0x1311da('0x9'),auth[_0x1311da('0x7')](),controller['update']),router['delete'](_0x1311da('0x9'),auth[_0x1311da('0x7')](),controller[_0x1311da('0xa')]),module[_0x1311da('0x5')]=router; \ No newline at end of file diff --git a/server/api/intDynamics365Configuration/intDynamics365Configuration.attributes.js b/server/api/intDynamics365Configuration/intDynamics365Configuration.attributes.js index 8bf6776..c59bbe4 100644 --- a/server/api/intDynamics365Configuration/intDynamics365Configuration.attributes.js +++ b/server/api/intDynamics365Configuration/intDynamics365Configuration.attributes.js @@ -1 +1 @@ -const a246_0x43b4=['sequelize','ENUM','STRING','incident','exports'];(function(_0x169803,_0x43b49c){const _0x4095f6=function(_0x1c328a){while(--_0x1c328a){_0x169803['push'](_0x169803['shift']());}};_0x4095f6(++_0x43b49c);}(a246_0x43b4,0x185));const a246_0x4095=function(_0x169803,_0x43b49c){_0x169803=_0x169803-0x0;let _0x4095f6=a246_0x43b4[_0x169803];return _0x4095f6;};const _0x8e18b9=a246_0x4095;'use strict';const Sequelize=require(_0x8e18b9('0x1'));module[_0x8e18b9('0x0')]={'name':{'type':Sequelize['STRING']},'description':{'type':Sequelize[_0x8e18b9('0x3')]},'ticketType':{'type':Sequelize[_0x8e18b9('0x2')](_0x8e18b9('0x4'),'phonecall'),'defaultValue':_0x8e18b9('0x4')}}; \ No newline at end of file +const a246_0x279c=['incident','sequelize','phonecall','ENUM','STRING','exports'];(function(_0x418991,_0x279c21){const _0x4ad79f=function(_0x28adb6){while(--_0x28adb6){_0x418991['push'](_0x418991['shift']());}};_0x4ad79f(++_0x279c21);}(a246_0x279c,0x11c));const a246_0x4ad7=function(_0x418991,_0x279c21){_0x418991=_0x418991-0x0;let _0x4ad79f=a246_0x279c[_0x418991];return _0x4ad79f;};const _0x6781da=a246_0x4ad7;'use strict';const Sequelize=require(_0x6781da('0x5'));module[_0x6781da('0x3')]={'name':{'type':Sequelize[_0x6781da('0x2')]},'description':{'type':Sequelize[_0x6781da('0x2')]},'ticketType':{'type':Sequelize[_0x6781da('0x1')](_0x6781da('0x4'),_0x6781da('0x0')),'defaultValue':_0x6781da('0x4')}}; \ No newline at end of file diff --git a/server/api/intDynamics365Configuration/intDynamics365Configuration.controller.js b/server/api/intDynamics365Configuration/intDynamics365Configuration.controller.js index 14aec10..b0eb2ec 100644 --- a/server/api/intDynamics365Configuration/intDynamics365Configuration.controller.js +++ b/server/api/intDynamics365Configuration/intDynamics365Configuration.controller.js @@ -1 +1 @@ -const a247_0x596e=['Dynamics365Field','length','getFields','fieldName','params','type','Content-Range','body','api','sendStatus','sort','query','fields','filters','like','lodash','nolimit','create','keys','name','rows','where','offset','then','getSubjects','sequelize','order','Dynamics365Configuration','findOne','index','getDescriptions','stack','model','include','VIRTUAL','intersection','limit','error','filter','pick','includeAll','json','count','attributes','end','send','../../components/parsers/qs','destroy','merge','undefined','status','rawAttributes','options','set','update','catch','map'];(function(_0x347393,_0x596ebd){const _0x1b8762=function(_0x334c93){while(--_0x334c93){_0x347393['push'](_0x347393['shift']());}};_0x1b8762(++_0x596ebd);}(a247_0x596e,0x6d));const a247_0x1b87=function(_0x347393,_0x596ebd){_0x347393=_0x347393-0x0;let _0x1b8762=a247_0x596e[_0x347393];return _0x1b8762;};const _0x2f2ec8=a247_0x1b87;'use strict';const _=require(_0x2f2ec8('0x14')),qs=require(_0x2f2ec8('0x33')),logger=require('../../config/logger')(_0x2f2ec8('0xd')),db=require('../../mysqldb')['db'],{Op}=require(_0x2f2ec8('0x1e'));function respondWithResult(_0x334c93,_0x1e4496){return _0x1e4496=_0x1e4496||0xc8,function(_0x30c041){const _0x419af1=a247_0x1b87;if(_0x30c041)return _0x334c93[_0x419af1('0x37')](_0x1e4496)['json'](_0x30c041);};}function respondWithFilteredResult(_0x3a0c1a,_0x3a5122){return function(_0x5c597a){const _0x51647b=a247_0x1b87;if(_0x5c597a){const _0x5e8364=_0x5c597a[_0x51647b('0x2f')],_0x40eb91=_0x3a5122['offset'];let _0x383886=_0x3a5122[_0x51647b('0x1b')]+_0x3a5122['limit'],_0x498aa5;return _0x383886>=_0x5e8364?(_0x383886=_0x5e8364,_0x498aa5=0xc8):_0x498aa5=0xce,_0x3a0c1a['status'](_0x498aa5),_0x3a0c1a[_0x51647b('0x1')](_0x51647b('0xb'),_0x40eb91+'-'+_0x383886+'/'+_0x5e8364)[_0x51647b('0x2e')](_0x5c597a);}return null;};}function saveUpdates(_0x45cce4){return function(_0x4f6dfd){const _0x1ed2e5=a247_0x1b87;if(_0x4f6dfd)return _0x4f6dfd['update'](_0x45cce4)[_0x1ed2e5('0x1c')](function(_0x21788d){return _0x21788d;});return null;};}function removeEntity(_0x57e178){return function(_0x20c525){const _0x1902a7=a247_0x1b87;if(_0x20c525)return _0x20c525[_0x1902a7('0x34')]()['then'](function(){const _0x448f97=_0x1902a7;_0x57e178[_0x448f97('0x37')](0xcc)[_0x448f97('0x31')]();});};}function handleEntityNotFound(_0x42f6c9){return function(_0x2ae74f){const _0x58d063=a247_0x1b87;return!_0x2ae74f&&_0x42f6c9[_0x58d063('0xe')](0x194),_0x2ae74f;};}function handleError(_0x390045,_0x2ad631){return _0x2ad631=_0x2ad631||0x1f4,function(_0x32648f){const _0x473757=a247_0x1b87;logger[_0x473757('0x2a')](_0x32648f[_0x473757('0x24')]),_0x32648f[_0x473757('0x18')]&&delete _0x32648f[_0x473757('0x18')],_0x390045['status'](_0x2ad631)[_0x473757('0x32')](_0x32648f);};}exports[_0x2f2ec8('0x22')]=function(_0x37837a,_0x2a5f9d){const _0x29e92b=_0x2f2ec8;let _0xe526e4={};const _0x389d86={},_0x10dde0={'count':0x0,'rows':[]},_0x1a1389=_['map'](db[_0x29e92b('0x20')][_0x29e92b('0x38')],function(_0x115aa6){const _0xfa2593=_0x29e92b;return{'name':_0x115aa6[_0xfa2593('0x8')],'type':_0x115aa6[_0xfa2593('0xa')]['key']};});_0x389d86['model']=_[_0x29e92b('0x4')](_0x1a1389,_0x29e92b('0x18')),_0x389d86[_0x29e92b('0x10')]=_[_0x29e92b('0x17')](_0x37837a[_0x29e92b('0x10')]),_0x389d86[_0x29e92b('0x12')]=_[_0x29e92b('0x28')](_0x389d86[_0x29e92b('0x25')],_0x389d86['query']),_0xe526e4[_0x29e92b('0x30')]=_['intersection'](_0x389d86[_0x29e92b('0x25')],qs[_0x29e92b('0x11')](_0x37837a[_0x29e92b('0x10')][_0x29e92b('0x11')])),_0xe526e4['attributes']=_0xe526e4[_0x29e92b('0x30')][_0x29e92b('0x6')]?_0xe526e4['attributes']:_0x389d86[_0x29e92b('0x25')];typeof _0x37837a[_0x29e92b('0x10')][_0x29e92b('0x15')]===_0x29e92b('0x36')&&(_0xe526e4[_0x29e92b('0x29')]=qs[_0x29e92b('0x29')](_0x37837a[_0x29e92b('0x10')][_0x29e92b('0x29')]),_0xe526e4[_0x29e92b('0x1b')]=qs[_0x29e92b('0x1b')](_0x37837a['query'][_0x29e92b('0x1b')]));_0xe526e4['order']=qs[_0x29e92b('0xf')](_0x37837a[_0x29e92b('0x10')][_0x29e92b('0xf')]),_0xe526e4[_0x29e92b('0x1a')]=qs['filters'](_[_0x29e92b('0x2c')](_0x37837a[_0x29e92b('0x10')],_0x389d86['filters']),_0x1a1389);_0x37837a['query'][_0x29e92b('0x2b')]&&(_0xe526e4[_0x29e92b('0x1a')]=_[_0x29e92b('0x35')](_0xe526e4[_0x29e92b('0x1a')],{[Op['or']]:_[_0x29e92b('0x4')](_0x1a1389,function(_0x6eff00){const _0xa06072=_0x29e92b;if(_0x6eff00[_0xa06072('0xa')]!==_0xa06072('0x27')){const _0x531d88={};return _0x531d88[_0x6eff00['name']]={[Op[_0xa06072('0x13')]]:'%'+_0x37837a[_0xa06072('0x10')]['filter']+'%'},_0x531d88;}})}));_0xe526e4=_[_0x29e92b('0x35')]({},_0xe526e4,_0x37837a[_0x29e92b('0x0')]);const _0x51bf4d={'where':_0xe526e4['where']};return db[_0x29e92b('0x20')][_0x29e92b('0x2f')](_0x51bf4d)[_0x29e92b('0x1c')](function(_0xc0263b){const _0x1cdcec=_0x29e92b;return _0x10dde0[_0x1cdcec('0x2f')]=_0xc0263b,_0x37837a[_0x1cdcec('0x10')][_0x1cdcec('0x2d')]&&(_0xe526e4[_0x1cdcec('0x26')]=[{'all':!![]}]),db[_0x1cdcec('0x20')]['findAll'](_0xe526e4);})['then'](function(_0x571dfb){const _0x1b6e0e=_0x29e92b;return _0x10dde0[_0x1b6e0e('0x19')]=_0x571dfb,_0x10dde0;})[_0x29e92b('0x1c')](respondWithFilteredResult(_0x2a5f9d,_0xe526e4))['catch'](handleError(_0x2a5f9d,null));},exports['show']=function(_0x30fbb2,_0xbf5c75){const _0x2f0837=_0x2f2ec8;let _0x26f3b4={'raw':![],'where':{'id':_0x30fbb2[_0x2f0837('0x9')]['id']}};const _0x568628={};return _0x568628[_0x2f0837('0x25')]=_[_0x2f0837('0x17')](db[_0x2f0837('0x20')][_0x2f0837('0x38')]),_0x568628[_0x2f0837('0x10')]=_[_0x2f0837('0x17')](_0x30fbb2[_0x2f0837('0x10')]),_0x568628[_0x2f0837('0x12')]=_[_0x2f0837('0x28')](_0x568628[_0x2f0837('0x25')],_0x568628[_0x2f0837('0x10')]),_0x26f3b4[_0x2f0837('0x30')]=_[_0x2f0837('0x28')](_0x568628[_0x2f0837('0x25')],qs[_0x2f0837('0x11')](_0x30fbb2[_0x2f0837('0x10')][_0x2f0837('0x11')])),_0x26f3b4[_0x2f0837('0x30')]=_0x26f3b4['attributes']['length']?_0x26f3b4[_0x2f0837('0x30')]:_0x568628[_0x2f0837('0x25')],_0x30fbb2[_0x2f0837('0x10')][_0x2f0837('0x2d')]&&(_0x26f3b4['include']=[{'all':!![]}]),_0x26f3b4=_[_0x2f0837('0x35')]({},_0x26f3b4,_0x30fbb2['options']),db[_0x2f0837('0x20')][_0x2f0837('0x21')](_0x26f3b4)[_0x2f0837('0x1c')](handleEntityNotFound(_0xbf5c75,null))[_0x2f0837('0x1c')](respondWithResult(_0xbf5c75,null))[_0x2f0837('0x3')](handleError(_0xbf5c75,null));},exports['create']=function(_0xfa6a,_0x66f8d4){const _0x450abc=_0x2f2ec8;return db['Dynamics365Configuration'][_0x450abc('0x16')](_0xfa6a[_0x450abc('0xc')],{})[_0x450abc('0x1c')](respondWithResult(_0x66f8d4,0xc9))[_0x450abc('0x3')](handleError(_0x66f8d4,null));},exports[_0x2f2ec8('0x2')]=function(_0x274915,_0x479d8e){const _0x128847=_0x2f2ec8;return _0x274915[_0x128847('0xc')]['id']&&delete _0x274915[_0x128847('0xc')]['id'],db['Dynamics365Configuration'][_0x128847('0x21')]({'where':{'id':_0x274915[_0x128847('0x9')]['id']}})[_0x128847('0x1c')](handleEntityNotFound(_0x479d8e,null))[_0x128847('0x1c')](saveUpdates(_0x274915['body'],null))[_0x128847('0x1c')](respondWithResult(_0x479d8e,null))[_0x128847('0x3')](handleError(_0x479d8e,null));},exports[_0x2f2ec8('0x34')]=function(_0x3ae639,_0x5f4c3b){const _0x3fa773=_0x2f2ec8;return db[_0x3fa773('0x20')][_0x3fa773('0x21')]({'where':{'id':_0x3ae639[_0x3fa773('0x9')]['id']}})['then'](handleEntityNotFound(_0x5f4c3b,null))[_0x3fa773('0x1c')](removeEntity(_0x5f4c3b,null))[_0x3fa773('0x3')](handleError(_0x5f4c3b,null));},exports[_0x2f2ec8('0x7')]=function(_0x21ff8c,_0x12631d){const _0x492cf9=_0x2f2ec8;let _0x5d40a9={};const _0x3f7f2f={};let _0x249a5c,_0x2b7ea0;return db[_0x492cf9('0x20')][_0x492cf9('0x21')]({'where':{'id':_0x21ff8c['params']['id']}})['then'](handleEntityNotFound(_0x12631d,null))[_0x492cf9('0x1c')](function(_0x2ce4f9){const _0xaaaf4c=_0x492cf9;if(_0x2ce4f9)return _0x249a5c=_0x2ce4f9,_0x3f7f2f[_0xaaaf4c('0x25')]=_[_0xaaaf4c('0x17')](db['Dynamics365Field'][_0xaaaf4c('0x38')]),_0x3f7f2f['query']=_[_0xaaaf4c('0x17')](_0x21ff8c[_0xaaaf4c('0x10')]),_0x3f7f2f[_0xaaaf4c('0x12')]=_['intersection'](_0x3f7f2f['model'],_0x3f7f2f[_0xaaaf4c('0x10')]),_0x5d40a9[_0xaaaf4c('0x30')]=_['intersection'](_0x3f7f2f['model'],qs['fields'](_0x21ff8c[_0xaaaf4c('0x10')][_0xaaaf4c('0x11')])),_0x5d40a9['attributes']=_0x5d40a9[_0xaaaf4c('0x30')]['length']?_0x5d40a9['attributes']:_0x3f7f2f[_0xaaaf4c('0x25')],_0x5d40a9['order']=qs[_0xaaaf4c('0xf')](_0x21ff8c[_0xaaaf4c('0x10')][_0xaaaf4c('0xf')]),_0x5d40a9[_0xaaaf4c('0x1a')]=qs[_0xaaaf4c('0x12')](_[_0xaaaf4c('0x2c')](_0x21ff8c[_0xaaaf4c('0x10')],_0x3f7f2f[_0xaaaf4c('0x12')])),_0x21ff8c[_0xaaaf4c('0x10')][_0xaaaf4c('0x2b')]&&(_0x5d40a9['where']=_[_0xaaaf4c('0x35')](_0x5d40a9[_0xaaaf4c('0x1a')],{[Op['or']]:_[_0xaaaf4c('0x4')](_0x5d40a9[_0xaaaf4c('0x30')],function(_0x5ec2fc){const _0x1598ac=_0xaaaf4c,_0x40d7dd={};return _0x40d7dd[_0x5ec2fc]={[Op[_0x1598ac('0x13')]]:'%'+_0x21ff8c[_0x1598ac('0x10')]['filter']+'%'},_0x40d7dd;})})),_0x5d40a9=_[_0xaaaf4c('0x35')]({},_0x5d40a9,_0x21ff8c[_0xaaaf4c('0x0')]),_0x249a5c['getFields'](_0x5d40a9);})['then'](function(_0x4bf5b3){const _0x783018=_0x492cf9;if(_0x4bf5b3)return _0x2b7ea0=_0x4bf5b3[_0x783018('0x6')],typeof _0x21ff8c[_0x783018('0x10')][_0x783018('0x15')]==='undefined'&&(_0x5d40a9[_0x783018('0x29')]=qs[_0x783018('0x29')](_0x21ff8c[_0x783018('0x10')][_0x783018('0x29')]),_0x5d40a9[_0x783018('0x1b')]=qs['offset'](_0x21ff8c[_0x783018('0x10')]['offset'])),_0x249a5c[_0x783018('0x7')](_0x5d40a9);})[_0x492cf9('0x1c')](function(_0x279c91){if(_0x279c91)return _0x279c91?{'count':_0x2b7ea0,'rows':_0x279c91}:null;})[_0x492cf9('0x1c')](respondWithResult(_0x12631d,null))[_0x492cf9('0x3')](handleError(_0x12631d,null));},exports[_0x2f2ec8('0x1d')]=function(_0x363eb7,_0x3374bb){const _0x20a815=_0x2f2ec8;let _0x45702f={};const _0x53bb35={};let _0x49c75d,_0x2c8ca1;return db['Dynamics365Configuration'][_0x20a815('0x21')]({'where':{'id':_0x363eb7[_0x20a815('0x9')]['id']}})[_0x20a815('0x1c')](handleEntityNotFound(_0x3374bb,null))[_0x20a815('0x1c')](function(_0x3b73c9){const _0x488b42=_0x20a815;if(_0x3b73c9)return _0x49c75d=_0x3b73c9,_0x53bb35['model']=_[_0x488b42('0x17')](db[_0x488b42('0x5')][_0x488b42('0x38')]),_0x53bb35[_0x488b42('0x10')]=_['keys'](_0x363eb7[_0x488b42('0x10')]),_0x53bb35[_0x488b42('0x12')]=_[_0x488b42('0x28')](_0x53bb35['model'],_0x53bb35['query']),_0x45702f[_0x488b42('0x30')]=_[_0x488b42('0x28')](_0x53bb35[_0x488b42('0x25')],qs[_0x488b42('0x11')](_0x363eb7[_0x488b42('0x10')][_0x488b42('0x11')])),_0x45702f[_0x488b42('0x30')]=_0x45702f[_0x488b42('0x30')][_0x488b42('0x6')]?_0x45702f[_0x488b42('0x30')]:_0x53bb35['model'],_0x45702f['order']=qs[_0x488b42('0xf')](_0x363eb7[_0x488b42('0x10')][_0x488b42('0xf')]),_0x45702f[_0x488b42('0x1a')]=qs[_0x488b42('0x12')](_[_0x488b42('0x2c')](_0x363eb7[_0x488b42('0x10')],_0x53bb35['filters'])),_0x363eb7[_0x488b42('0x10')][_0x488b42('0x2b')]&&(_0x45702f[_0x488b42('0x1a')]=_[_0x488b42('0x35')](_0x45702f['where'],{[Op['or']]:_[_0x488b42('0x4')](_0x45702f[_0x488b42('0x30')],function(_0x59346d){const _0x22efa7=_0x488b42,_0x23af2d={};return _0x23af2d[_0x59346d]={[Op[_0x22efa7('0x13')]]:'%'+_0x363eb7[_0x22efa7('0x10')][_0x22efa7('0x2b')]+'%'},_0x23af2d;})})),_0x45702f=_[_0x488b42('0x35')]({},_0x45702f,_0x363eb7[_0x488b42('0x0')]),_0x49c75d[_0x488b42('0x1d')](_0x45702f);})['then'](function(_0x47a067){const _0x548c64=_0x20a815;if(_0x47a067)return _0x2c8ca1=_0x47a067[_0x548c64('0x6')],typeof _0x363eb7[_0x548c64('0x10')][_0x548c64('0x15')]==='undefined'&&(_0x45702f[_0x548c64('0x29')]=qs[_0x548c64('0x29')](_0x363eb7[_0x548c64('0x10')][_0x548c64('0x29')]),_0x45702f['offset']=qs[_0x548c64('0x1b')](_0x363eb7[_0x548c64('0x10')][_0x548c64('0x1b')])),_0x49c75d[_0x548c64('0x1d')](_0x45702f);})[_0x20a815('0x1c')](function(_0x19e88c){if(_0x19e88c)return _0x19e88c?{'count':_0x2c8ca1,'rows':_0x19e88c}:null;})[_0x20a815('0x1c')](respondWithResult(_0x3374bb,null))['catch'](handleError(_0x3374bb,null));},exports['getDescriptions']=function(_0x40db16,_0xf125fa){const _0xe482c0=_0x2f2ec8;let _0x30101c={};const _0x16b3cc={};let _0x6bcd04,_0x2d4975;return db['Dynamics365Configuration'][_0xe482c0('0x21')]({'where':{'id':_0x40db16[_0xe482c0('0x9')]['id']}})[_0xe482c0('0x1c')](handleEntityNotFound(_0xf125fa,null))['then'](function(_0x4e5bc2){const _0x49adc5=_0xe482c0;if(_0x4e5bc2)return _0x6bcd04=_0x4e5bc2,_0x16b3cc[_0x49adc5('0x25')]=_[_0x49adc5('0x17')](db['Dynamics365Field'][_0x49adc5('0x38')]),_0x16b3cc[_0x49adc5('0x10')]=_['keys'](_0x40db16['query']),_0x16b3cc[_0x49adc5('0x12')]=_[_0x49adc5('0x28')](_0x16b3cc[_0x49adc5('0x25')],_0x16b3cc[_0x49adc5('0x10')]),_0x30101c[_0x49adc5('0x30')]=_[_0x49adc5('0x28')](_0x16b3cc['model'],qs[_0x49adc5('0x11')](_0x40db16[_0x49adc5('0x10')]['fields'])),_0x30101c[_0x49adc5('0x30')]=_0x30101c[_0x49adc5('0x30')]['length']?_0x30101c[_0x49adc5('0x30')]:_0x16b3cc[_0x49adc5('0x25')],_0x30101c[_0x49adc5('0x1f')]=qs['sort'](_0x40db16['query'][_0x49adc5('0xf')]),_0x30101c[_0x49adc5('0x1a')]=qs[_0x49adc5('0x12')](_[_0x49adc5('0x2c')](_0x40db16['query'],_0x16b3cc[_0x49adc5('0x12')])),_0x40db16[_0x49adc5('0x10')][_0x49adc5('0x2b')]&&(_0x30101c[_0x49adc5('0x1a')]=_['merge'](_0x30101c['where'],{[Op['or']]:_[_0x49adc5('0x4')](_0x30101c[_0x49adc5('0x30')],function(_0x5014ae){const _0x2736ed=_0x49adc5,_0x46c92d={};return _0x46c92d[_0x5014ae]={[Op[_0x2736ed('0x13')]]:'%'+_0x40db16[_0x2736ed('0x10')]['filter']+'%'},_0x46c92d;})})),_0x30101c=_[_0x49adc5('0x35')]({},_0x30101c,_0x40db16[_0x49adc5('0x0')]),_0x6bcd04[_0x49adc5('0x23')](_0x30101c);})['then'](function(_0x23492f){const _0x4375dc=_0xe482c0;if(_0x23492f)return _0x2d4975=_0x23492f[_0x4375dc('0x6')],typeof _0x40db16[_0x4375dc('0x10')]['nolimit']===_0x4375dc('0x36')&&(_0x30101c[_0x4375dc('0x29')]=qs['limit'](_0x40db16[_0x4375dc('0x10')]['limit']),_0x30101c[_0x4375dc('0x1b')]=qs['offset'](_0x40db16[_0x4375dc('0x10')][_0x4375dc('0x1b')])),_0x6bcd04[_0x4375dc('0x23')](_0x30101c);})[_0xe482c0('0x1c')](function(_0x530669){if(_0x530669)return _0x530669?{'count':_0x2d4975,'rows':_0x530669}:null;})[_0xe482c0('0x1c')](respondWithResult(_0xf125fa,null))[_0xe482c0('0x3')](handleError(_0xf125fa,null));}; \ No newline at end of file +const a247_0x2dce=['sendStatus','index','order','status','name','rawAttributes','end','like','keys','stack','getDescriptions','include','nolimit','set','offset','where','limit','fields','params','Dynamics365Configuration','api','findOne','lodash','options','body','filter','map','then','count','length','fieldName','sort','create','catch','query','model','../../config/logger','pick','attributes','../../mysqldb','undefined','Content-Range','rows','type','merge','filters','getSubjects','show','json','send','sequelize','includeAll','Dynamics365Field','update','destroy','intersection'];(function(_0x3b84b6,_0x2dce6f){const _0x133e78=function(_0x389126){while(--_0x389126){_0x3b84b6['push'](_0x3b84b6['shift']());}};_0x133e78(++_0x2dce6f);}(a247_0x2dce,0xc6));const a247_0x133e=function(_0x3b84b6,_0x2dce6f){_0x3b84b6=_0x3b84b6-0x0;let _0x133e78=a247_0x2dce[_0x3b84b6];return _0x133e78;};const _0x56215b=a247_0x133e;'use strict';const _=require(_0x56215b('0x30')),qs=require('../../components/parsers/qs'),logger=require(_0x56215b('0x6'))(_0x56215b('0x2e')),db=require(_0x56215b('0x9'))['db'],{Op}=require(_0x56215b('0x14'));function respondWithResult(_0x389126,_0x1b2930){return _0x1b2930=_0x1b2930||0xc8,function(_0x407039){const _0x4827d6=a247_0x133e;if(_0x407039)return _0x389126[_0x4827d6('0x1d')](_0x1b2930)[_0x4827d6('0x12')](_0x407039);};}function respondWithFilteredResult(_0x42cef0,_0x118fc7){return function(_0x35af44){const _0x1718b6=a247_0x133e;if(_0x35af44){const _0x5d4131=_0x35af44[_0x1718b6('0x36')],_0xbf7d1e=_0x118fc7['offset'];let _0xf26f9a=_0x118fc7[_0x1718b6('0x28')]+_0x118fc7['limit'],_0x28e09d;return _0xf26f9a>=_0x5d4131?(_0xf26f9a=_0x5d4131,_0x28e09d=0xc8):_0x28e09d=0xce,_0x42cef0['status'](_0x28e09d),_0x42cef0[_0x1718b6('0x27')](_0x1718b6('0xb'),_0xbf7d1e+'-'+_0xf26f9a+'/'+_0x5d4131)[_0x1718b6('0x12')](_0x35af44);}return null;};}function saveUpdates(_0x5cca0b){return function(_0x2b81fb){const _0x2c094b=a247_0x133e;if(_0x2b81fb)return _0x2b81fb[_0x2c094b('0x17')](_0x5cca0b)['then'](function(_0x3ba8b6){return _0x3ba8b6;});return null;};}function removeEntity(_0x4270a3){return function(_0x69f652){const _0x1356b1=a247_0x133e;if(_0x69f652)return _0x69f652[_0x1356b1('0x18')]()['then'](function(){const _0x11e318=_0x1356b1;_0x4270a3['status'](0xcc)[_0x11e318('0x20')]();});};}function handleEntityNotFound(_0x22f7bc){return function(_0x4f6b50){const _0x1315be=a247_0x133e;return!_0x4f6b50&&_0x22f7bc[_0x1315be('0x1a')](0x194),_0x4f6b50;};}function handleError(_0x389765,_0x3f1601){return _0x3f1601=_0x3f1601||0x1f4,function(_0x26c89f){const _0x10b8a8=a247_0x133e;logger['error'](_0x26c89f[_0x10b8a8('0x23')]),_0x26c89f[_0x10b8a8('0x1e')]&&delete _0x26c89f[_0x10b8a8('0x1e')],_0x389765[_0x10b8a8('0x1d')](_0x3f1601)[_0x10b8a8('0x13')](_0x26c89f);};}exports[_0x56215b('0x1b')]=function(_0x4379e6,_0x58f239){const _0x37459e=_0x56215b;let _0x54102b={};const _0x13c73a={},_0x15381c={'count':0x0,'rows':[]},_0x2a7d18=_[_0x37459e('0x34')](db[_0x37459e('0x2d')]['rawAttributes'],function(_0x25b96f){const _0x251df2=_0x37459e;return{'name':_0x25b96f[_0x251df2('0x0')],'type':_0x25b96f['type']['key']};});_0x13c73a['model']=_[_0x37459e('0x34')](_0x2a7d18,'name'),_0x13c73a[_0x37459e('0x4')]=_[_0x37459e('0x22')](_0x4379e6['query']),_0x13c73a['filters']=_[_0x37459e('0x19')](_0x13c73a['model'],_0x13c73a[_0x37459e('0x4')]),_0x54102b[_0x37459e('0x8')]=_['intersection'](_0x13c73a[_0x37459e('0x5')],qs[_0x37459e('0x2b')](_0x4379e6[_0x37459e('0x4')]['fields'])),_0x54102b[_0x37459e('0x8')]=_0x54102b['attributes'][_0x37459e('0x37')]?_0x54102b[_0x37459e('0x8')]:_0x13c73a[_0x37459e('0x5')];typeof _0x4379e6[_0x37459e('0x4')][_0x37459e('0x26')]===_0x37459e('0xa')&&(_0x54102b['limit']=qs['limit'](_0x4379e6[_0x37459e('0x4')][_0x37459e('0x2a')]),_0x54102b['offset']=qs[_0x37459e('0x28')](_0x4379e6[_0x37459e('0x4')][_0x37459e('0x28')]));_0x54102b[_0x37459e('0x1c')]=qs['sort'](_0x4379e6[_0x37459e('0x4')]['sort']),_0x54102b['where']=qs[_0x37459e('0xf')](_[_0x37459e('0x7')](_0x4379e6['query'],_0x13c73a[_0x37459e('0xf')]),_0x2a7d18);_0x4379e6[_0x37459e('0x4')]['filter']&&(_0x54102b[_0x37459e('0x29')]=_[_0x37459e('0xe')](_0x54102b[_0x37459e('0x29')],{[Op['or']]:_[_0x37459e('0x34')](_0x2a7d18,function(_0x2442f7){const _0x441b07=_0x37459e;if(_0x2442f7[_0x441b07('0xd')]!=='VIRTUAL'){const _0x255432={};return _0x255432[_0x2442f7['name']]={[Op['like']]:'%'+_0x4379e6[_0x441b07('0x4')][_0x441b07('0x33')]+'%'},_0x255432;}})}));_0x54102b=_[_0x37459e('0xe')]({},_0x54102b,_0x4379e6['options']);const _0x4c67fd={'where':_0x54102b[_0x37459e('0x29')]};return db[_0x37459e('0x2d')][_0x37459e('0x36')](_0x4c67fd)[_0x37459e('0x35')](function(_0x3dacf2){const _0x497240=_0x37459e;return _0x15381c[_0x497240('0x36')]=_0x3dacf2,_0x4379e6[_0x497240('0x4')][_0x497240('0x15')]&&(_0x54102b[_0x497240('0x25')]=[{'all':!![]}]),db[_0x497240('0x2d')]['findAll'](_0x54102b);})[_0x37459e('0x35')](function(_0x4ac7bd){const _0x33aad4=_0x37459e;return _0x15381c[_0x33aad4('0xc')]=_0x4ac7bd,_0x15381c;})[_0x37459e('0x35')](respondWithFilteredResult(_0x58f239,_0x54102b))[_0x37459e('0x3')](handleError(_0x58f239,null));},exports[_0x56215b('0x11')]=function(_0x54f504,_0x3c5969){const _0x49ed28=_0x56215b;let _0x5ef737={'raw':![],'where':{'id':_0x54f504[_0x49ed28('0x2c')]['id']}};const _0xe3dc01={};return _0xe3dc01['model']=_[_0x49ed28('0x22')](db['Dynamics365Configuration']['rawAttributes']),_0xe3dc01[_0x49ed28('0x4')]=_[_0x49ed28('0x22')](_0x54f504[_0x49ed28('0x4')]),_0xe3dc01[_0x49ed28('0xf')]=_[_0x49ed28('0x19')](_0xe3dc01[_0x49ed28('0x5')],_0xe3dc01['query']),_0x5ef737['attributes']=_[_0x49ed28('0x19')](_0xe3dc01[_0x49ed28('0x5')],qs[_0x49ed28('0x2b')](_0x54f504[_0x49ed28('0x4')][_0x49ed28('0x2b')])),_0x5ef737[_0x49ed28('0x8')]=_0x5ef737[_0x49ed28('0x8')][_0x49ed28('0x37')]?_0x5ef737[_0x49ed28('0x8')]:_0xe3dc01['model'],_0x54f504[_0x49ed28('0x4')][_0x49ed28('0x15')]&&(_0x5ef737['include']=[{'all':!![]}]),_0x5ef737=_[_0x49ed28('0xe')]({},_0x5ef737,_0x54f504['options']),db[_0x49ed28('0x2d')][_0x49ed28('0x2f')](_0x5ef737)[_0x49ed28('0x35')](handleEntityNotFound(_0x3c5969,null))['then'](respondWithResult(_0x3c5969,null))[_0x49ed28('0x3')](handleError(_0x3c5969,null));},exports['create']=function(_0x19815a,_0x17ee8f){const _0x352816=_0x56215b;return db[_0x352816('0x2d')][_0x352816('0x2')](_0x19815a[_0x352816('0x32')],{})[_0x352816('0x35')](respondWithResult(_0x17ee8f,0xc9))[_0x352816('0x3')](handleError(_0x17ee8f,null));},exports[_0x56215b('0x17')]=function(_0x3533e7,_0x1c6acb){const _0x3ad190=_0x56215b;return _0x3533e7[_0x3ad190('0x32')]['id']&&delete _0x3533e7[_0x3ad190('0x32')]['id'],db[_0x3ad190('0x2d')][_0x3ad190('0x2f')]({'where':{'id':_0x3533e7[_0x3ad190('0x2c')]['id']}})[_0x3ad190('0x35')](handleEntityNotFound(_0x1c6acb,null))[_0x3ad190('0x35')](saveUpdates(_0x3533e7[_0x3ad190('0x32')],null))[_0x3ad190('0x35')](respondWithResult(_0x1c6acb,null))[_0x3ad190('0x3')](handleError(_0x1c6acb,null));},exports[_0x56215b('0x18')]=function(_0x4fde53,_0xbcb743){const _0x26f6f5=_0x56215b;return db[_0x26f6f5('0x2d')][_0x26f6f5('0x2f')]({'where':{'id':_0x4fde53[_0x26f6f5('0x2c')]['id']}})[_0x26f6f5('0x35')](handleEntityNotFound(_0xbcb743,null))[_0x26f6f5('0x35')](removeEntity(_0xbcb743,null))[_0x26f6f5('0x3')](handleError(_0xbcb743,null));},exports['getFields']=function(_0x5c34bf,_0x376d88){const _0x56aa34=_0x56215b;let _0x42846f={};const _0x9e951={};let _0x5d73d2,_0x3aaaa3;return db['Dynamics365Configuration'][_0x56aa34('0x2f')]({'where':{'id':_0x5c34bf[_0x56aa34('0x2c')]['id']}})['then'](handleEntityNotFound(_0x376d88,null))[_0x56aa34('0x35')](function(_0x228718){const _0x371e0a=_0x56aa34;if(_0x228718)return _0x5d73d2=_0x228718,_0x9e951['model']=_[_0x371e0a('0x22')](db[_0x371e0a('0x16')]['rawAttributes']),_0x9e951['query']=_[_0x371e0a('0x22')](_0x5c34bf[_0x371e0a('0x4')]),_0x9e951[_0x371e0a('0xf')]=_[_0x371e0a('0x19')](_0x9e951[_0x371e0a('0x5')],_0x9e951['query']),_0x42846f[_0x371e0a('0x8')]=_[_0x371e0a('0x19')](_0x9e951['model'],qs['fields'](_0x5c34bf[_0x371e0a('0x4')][_0x371e0a('0x2b')])),_0x42846f[_0x371e0a('0x8')]=_0x42846f[_0x371e0a('0x8')][_0x371e0a('0x37')]?_0x42846f[_0x371e0a('0x8')]:_0x9e951[_0x371e0a('0x5')],_0x42846f[_0x371e0a('0x1c')]=qs[_0x371e0a('0x1')](_0x5c34bf['query'][_0x371e0a('0x1')]),_0x42846f[_0x371e0a('0x29')]=qs[_0x371e0a('0xf')](_[_0x371e0a('0x7')](_0x5c34bf['query'],_0x9e951['filters'])),_0x5c34bf[_0x371e0a('0x4')][_0x371e0a('0x33')]&&(_0x42846f[_0x371e0a('0x29')]=_[_0x371e0a('0xe')](_0x42846f[_0x371e0a('0x29')],{[Op['or']]:_[_0x371e0a('0x34')](_0x42846f['attributes'],function(_0xf5ea6b){const _0x4f6e13=_0x371e0a,_0x21c6b7={};return _0x21c6b7[_0xf5ea6b]={[Op[_0x4f6e13('0x21')]]:'%'+_0x5c34bf['query'][_0x4f6e13('0x33')]+'%'},_0x21c6b7;})})),_0x42846f=_['merge']({},_0x42846f,_0x5c34bf[_0x371e0a('0x31')]),_0x5d73d2['getFields'](_0x42846f);})[_0x56aa34('0x35')](function(_0x9de66d){const _0x1199de=_0x56aa34;if(_0x9de66d)return _0x3aaaa3=_0x9de66d[_0x1199de('0x37')],typeof _0x5c34bf[_0x1199de('0x4')][_0x1199de('0x26')]===_0x1199de('0xa')&&(_0x42846f[_0x1199de('0x2a')]=qs[_0x1199de('0x2a')](_0x5c34bf[_0x1199de('0x4')]['limit']),_0x42846f[_0x1199de('0x28')]=qs['offset'](_0x5c34bf[_0x1199de('0x4')][_0x1199de('0x28')])),_0x5d73d2['getFields'](_0x42846f);})[_0x56aa34('0x35')](function(_0x4ebcaf){if(_0x4ebcaf)return _0x4ebcaf?{'count':_0x3aaaa3,'rows':_0x4ebcaf}:null;})[_0x56aa34('0x35')](respondWithResult(_0x376d88,null))[_0x56aa34('0x3')](handleError(_0x376d88,null));},exports['getSubjects']=function(_0x500af4,_0x5a037c){const _0x3633c1=_0x56215b;let _0x35867b={};const _0x4da8c0={};let _0x2eb183,_0x28f176;return db['Dynamics365Configuration'][_0x3633c1('0x2f')]({'where':{'id':_0x500af4[_0x3633c1('0x2c')]['id']}})[_0x3633c1('0x35')](handleEntityNotFound(_0x5a037c,null))['then'](function(_0x17ec88){const _0x595706=_0x3633c1;if(_0x17ec88)return _0x2eb183=_0x17ec88,_0x4da8c0[_0x595706('0x5')]=_[_0x595706('0x22')](db[_0x595706('0x16')]['rawAttributes']),_0x4da8c0[_0x595706('0x4')]=_[_0x595706('0x22')](_0x500af4[_0x595706('0x4')]),_0x4da8c0[_0x595706('0xf')]=_[_0x595706('0x19')](_0x4da8c0[_0x595706('0x5')],_0x4da8c0[_0x595706('0x4')]),_0x35867b[_0x595706('0x8')]=_[_0x595706('0x19')](_0x4da8c0[_0x595706('0x5')],qs[_0x595706('0x2b')](_0x500af4[_0x595706('0x4')][_0x595706('0x2b')])),_0x35867b[_0x595706('0x8')]=_0x35867b[_0x595706('0x8')][_0x595706('0x37')]?_0x35867b[_0x595706('0x8')]:_0x4da8c0[_0x595706('0x5')],_0x35867b[_0x595706('0x1c')]=qs[_0x595706('0x1')](_0x500af4['query'][_0x595706('0x1')]),_0x35867b[_0x595706('0x29')]=qs[_0x595706('0xf')](_[_0x595706('0x7')](_0x500af4[_0x595706('0x4')],_0x4da8c0[_0x595706('0xf')])),_0x500af4['query'][_0x595706('0x33')]&&(_0x35867b['where']=_[_0x595706('0xe')](_0x35867b['where'],{[Op['or']]:_['map'](_0x35867b[_0x595706('0x8')],function(_0x35e3ff){const _0xc7fadf=_0x595706,_0x12c8df={};return _0x12c8df[_0x35e3ff]={[Op[_0xc7fadf('0x21')]]:'%'+_0x500af4[_0xc7fadf('0x4')]['filter']+'%'},_0x12c8df;})})),_0x35867b=_[_0x595706('0xe')]({},_0x35867b,_0x500af4[_0x595706('0x31')]),_0x2eb183[_0x595706('0x10')](_0x35867b);})[_0x3633c1('0x35')](function(_0x55c67f){const _0xf26e85=_0x3633c1;if(_0x55c67f)return _0x28f176=_0x55c67f[_0xf26e85('0x37')],typeof _0x500af4['query'][_0xf26e85('0x26')]===_0xf26e85('0xa')&&(_0x35867b['limit']=qs['limit'](_0x500af4[_0xf26e85('0x4')][_0xf26e85('0x2a')]),_0x35867b['offset']=qs['offset'](_0x500af4[_0xf26e85('0x4')][_0xf26e85('0x28')])),_0x2eb183['getSubjects'](_0x35867b);})[_0x3633c1('0x35')](function(_0x272903){if(_0x272903)return _0x272903?{'count':_0x28f176,'rows':_0x272903}:null;})[_0x3633c1('0x35')](respondWithResult(_0x5a037c,null))['catch'](handleError(_0x5a037c,null));},exports[_0x56215b('0x24')]=function(_0x27a209,_0x467bfe){const _0x57b615=_0x56215b;let _0x3b2679={};const _0x44bb8c={};let _0x51e927,_0x380ae4;return db[_0x57b615('0x2d')][_0x57b615('0x2f')]({'where':{'id':_0x27a209[_0x57b615('0x2c')]['id']}})[_0x57b615('0x35')](handleEntityNotFound(_0x467bfe,null))[_0x57b615('0x35')](function(_0x3dd27a){const _0x207d0d=_0x57b615;if(_0x3dd27a)return _0x51e927=_0x3dd27a,_0x44bb8c[_0x207d0d('0x5')]=_[_0x207d0d('0x22')](db[_0x207d0d('0x16')][_0x207d0d('0x1f')]),_0x44bb8c[_0x207d0d('0x4')]=_[_0x207d0d('0x22')](_0x27a209[_0x207d0d('0x4')]),_0x44bb8c[_0x207d0d('0xf')]=_[_0x207d0d('0x19')](_0x44bb8c[_0x207d0d('0x5')],_0x44bb8c[_0x207d0d('0x4')]),_0x3b2679[_0x207d0d('0x8')]=_['intersection'](_0x44bb8c['model'],qs['fields'](_0x27a209[_0x207d0d('0x4')][_0x207d0d('0x2b')])),_0x3b2679[_0x207d0d('0x8')]=_0x3b2679[_0x207d0d('0x8')]['length']?_0x3b2679['attributes']:_0x44bb8c[_0x207d0d('0x5')],_0x3b2679[_0x207d0d('0x1c')]=qs[_0x207d0d('0x1')](_0x27a209['query'][_0x207d0d('0x1')]),_0x3b2679[_0x207d0d('0x29')]=qs[_0x207d0d('0xf')](_['pick'](_0x27a209[_0x207d0d('0x4')],_0x44bb8c['filters'])),_0x27a209[_0x207d0d('0x4')][_0x207d0d('0x33')]&&(_0x3b2679[_0x207d0d('0x29')]=_[_0x207d0d('0xe')](_0x3b2679[_0x207d0d('0x29')],{[Op['or']]:_['map'](_0x3b2679[_0x207d0d('0x8')],function(_0x5381a0){const _0x36a911=_0x207d0d,_0x27c3f4={};return _0x27c3f4[_0x5381a0]={[Op[_0x36a911('0x21')]]:'%'+_0x27a209[_0x36a911('0x4')][_0x36a911('0x33')]+'%'},_0x27c3f4;})})),_0x3b2679=_[_0x207d0d('0xe')]({},_0x3b2679,_0x27a209[_0x207d0d('0x31')]),_0x51e927['getDescriptions'](_0x3b2679);})[_0x57b615('0x35')](function(_0x1b9296){const _0x178aef=_0x57b615;if(_0x1b9296)return _0x380ae4=_0x1b9296[_0x178aef('0x37')],typeof _0x27a209[_0x178aef('0x4')][_0x178aef('0x26')]==='undefined'&&(_0x3b2679['limit']=qs[_0x178aef('0x2a')](_0x27a209[_0x178aef('0x4')][_0x178aef('0x2a')]),_0x3b2679[_0x178aef('0x28')]=qs[_0x178aef('0x28')](_0x27a209[_0x178aef('0x4')][_0x178aef('0x28')])),_0x51e927[_0x178aef('0x24')](_0x3b2679);})[_0x57b615('0x35')](function(_0x4c5930){if(_0x4c5930)return _0x4c5930?{'count':_0x380ae4,'rows':_0x4c5930}:null;})[_0x57b615('0x35')](respondWithResult(_0x467bfe,null))['catch'](handleError(_0x467bfe,null));}; \ No newline at end of file diff --git a/server/api/intDynamics365Configuration/intDynamics365Configuration.model.js b/server/api/intDynamics365Configuration/intDynamics365Configuration.model.js index 5846223..9138789 100644 --- a/server/api/intDynamics365Configuration/intDynamics365Configuration.model.js +++ b/server/api/intDynamics365Configuration/intDynamics365Configuration.model.js @@ -1 +1 @@ -const a248_0x5e4c=['exports','./intDynamics365Configuration.attributes','define'];(function(_0x106b84,_0x5e4c8a){const _0x2172eb=function(_0x4a3959){while(--_0x4a3959){_0x106b84['push'](_0x106b84['shift']());}};_0x2172eb(++_0x5e4c8a);}(a248_0x5e4c,0x93));const a248_0x2172=function(_0x106b84,_0x5e4c8a){_0x106b84=_0x106b84-0x0;let _0x2172eb=a248_0x5e4c[_0x106b84];return _0x2172eb;};const _0x38ba49=a248_0x2172;'use strict';const attributes=require(_0x38ba49('0x1'));module[_0x38ba49('0x0')]=function(_0x4a3959){const _0x584b3f=_0x38ba49,_0x4c44c4=_0x4a3959[_0x584b3f('0x2')]('Dynamics365Configuration',attributes,{'tableName':'int_dynamics365_configurations','paranoid':![],'indexes':[],'timestamps':!![]});return _0x4c44c4;}; \ No newline at end of file +const a248_0x40ec=['define','exports','int_dynamics365_configurations','./intDynamics365Configuration.attributes','Dynamics365Configuration'];(function(_0x558f9d,_0x40ec76){const _0x256587=function(_0x299368){while(--_0x299368){_0x558f9d['push'](_0x558f9d['shift']());}};_0x256587(++_0x40ec76);}(a248_0x40ec,0x131));const a248_0x2565=function(_0x558f9d,_0x40ec76){_0x558f9d=_0x558f9d-0x0;let _0x256587=a248_0x40ec[_0x558f9d];return _0x256587;};const _0x22715c=a248_0x2565;'use strict';const attributes=require(_0x22715c('0x3'));module[_0x22715c('0x1')]=function(_0x299368){const _0x3af027=_0x22715c,_0x2079fa=_0x299368[_0x3af027('0x0')](_0x3af027('0x4'),attributes,{'tableName':_0x3af027('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2079fa;}; \ No newline at end of file diff --git a/server/api/intDynamics365Field/index.js b/server/api/intDynamics365Field/index.js index d19df00..fb4255b 100644 --- a/server/api/intDynamics365Field/index.js +++ b/server/api/intDynamics365Field/index.js @@ -1 +1 @@ -const a249_0xacad=['put','update','create','show','get','express','./intDynamics365Field.controller','Router','delete','isAuthenticated','/:id','exports'];(function(_0xade31e,_0xacadab){const _0x26c6be=function(_0x3b91d3){while(--_0x3b91d3){_0xade31e['push'](_0xade31e['shift']());}};_0x26c6be(++_0xacadab);}(a249_0xacad,0x1a2));const a249_0x26c6=function(_0xade31e,_0xacadab){_0xade31e=_0xade31e-0x0;let _0x26c6be=a249_0xacad[_0xade31e];return _0x26c6be;};const _0xc174b8=a249_0x26c6;'use strict';const express=require(_0xc174b8('0x7')),router=express[_0xc174b8('0x9')](),auth=require('../../components/auth/service'),controller=require(_0xc174b8('0x8'));router[_0xc174b8('0x6')]('/',auth[_0xc174b8('0xb')](),controller['index']),router[_0xc174b8('0x6')]('/:id',auth[_0xc174b8('0xb')](),controller[_0xc174b8('0x5')]),router['post']('/',auth[_0xc174b8('0xb')](),controller[_0xc174b8('0x4')]),router[_0xc174b8('0x2')](_0xc174b8('0x0'),auth[_0xc174b8('0xb')](),controller[_0xc174b8('0x3')]),router[_0xc174b8('0xa')](_0xc174b8('0x0'),auth[_0xc174b8('0xb')](),controller['destroy']),module[_0xc174b8('0x1')]=router; \ No newline at end of file +const a249_0x4b75=['delete','isAuthenticated','../../components/auth/service','show','/:id','Router','exports','destroy','update','index','get','./intDynamics365Field.controller','create','post'];(function(_0x2b16f4,_0x4b7587){const _0x4b49ab=function(_0x5ece36){while(--_0x5ece36){_0x2b16f4['push'](_0x2b16f4['shift']());}};_0x4b49ab(++_0x4b7587);}(a249_0x4b75,0x19c));const a249_0x4b49=function(_0x2b16f4,_0x4b7587){_0x2b16f4=_0x2b16f4-0x0;let _0x4b49ab=a249_0x4b75[_0x2b16f4];return _0x4b49ab;};const _0x2f5ebc=a249_0x4b49;'use strict';const express=require('express'),router=express[_0x2f5ebc('0xd')](),auth=require(_0x2f5ebc('0xa')),controller=require(_0x2f5ebc('0x5'));router[_0x2f5ebc('0x4')]('/',auth[_0x2f5ebc('0x9')](),controller[_0x2f5ebc('0x3')]),router[_0x2f5ebc('0x4')]('/:id',auth[_0x2f5ebc('0x9')](),controller[_0x2f5ebc('0xb')]),router[_0x2f5ebc('0x7')]('/',auth[_0x2f5ebc('0x9')](),controller[_0x2f5ebc('0x6')]),router['put'](_0x2f5ebc('0xc'),auth[_0x2f5ebc('0x9')](),controller[_0x2f5ebc('0x2')]),router[_0x2f5ebc('0x8')](_0x2f5ebc('0xc'),auth['isAuthenticated'](),controller[_0x2f5ebc('0x1')]),module[_0x2f5ebc('0x0')]=router; \ No newline at end of file diff --git a/server/api/intDynamics365Field/intDynamics365Field.attributes.js b/server/api/intDynamics365Field/intDynamics365Field.attributes.js index bfda72a..fd06b63 100644 --- a/server/api/intDynamics365Field/intDynamics365Field.attributes.js +++ b/server/api/intDynamics365Field/intDynamics365Field.attributes.js @@ -1 +1 @@ -const a250_0x2fe4=['BOOLEAN','keyValue','exports','sequelize','ENUM','variable','customVariable','string','STRING'];(function(_0x46fcbc,_0x2fe435){const _0x172148=function(_0x1607ce){while(--_0x1607ce){_0x46fcbc['push'](_0x46fcbc['shift']());}};_0x172148(++_0x2fe435);}(a250_0x2fe4,0x92));const a250_0x1721=function(_0x46fcbc,_0x2fe435){_0x46fcbc=_0x46fcbc-0x0;let _0x172148=a250_0x2fe4[_0x46fcbc];return _0x172148;};const _0x13c4d4=a250_0x1721;'use strict';const Sequelize=require(_0x13c4d4('0x1'));module[_0x13c4d4('0x0')]={'type':{'type':Sequelize[_0x13c4d4('0x2')]('string',_0x13c4d4('0x3'),'customVariable',_0x13c4d4('0x8')),'defaultValue':_0x13c4d4('0x5')},'content':{'type':Sequelize['STRING']},'key':{'type':Sequelize['STRING']},'keyType':{'type':Sequelize[_0x13c4d4('0x2')](_0x13c4d4('0x5'),'variable',_0x13c4d4('0x4'))},'keyContent':{'type':Sequelize[_0x13c4d4('0x6')]},'idField':{'type':Sequelize['STRING']},'nameField':{'type':Sequelize[_0x13c4d4('0x6')]},'customField':{'type':Sequelize[_0x13c4d4('0x7')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x13c4d4('0x6')]}}; \ No newline at end of file +const a250_0xdb31=['variable','string','ENUM','keyValue','exports','BOOLEAN','customVariable','STRING'];(function(_0x10be76,_0xdb3103){const _0x5227f3=function(_0x523b5d){while(--_0x523b5d){_0x10be76['push'](_0x10be76['shift']());}};_0x5227f3(++_0xdb3103);}(a250_0xdb31,0x120));const a250_0x5227=function(_0x10be76,_0xdb3103){_0x10be76=_0x10be76-0x0;let _0x5227f3=a250_0xdb31[_0x10be76];return _0x5227f3;};const _0x7a70c4=a250_0x5227;'use strict';const Sequelize=require('sequelize');module[_0x7a70c4('0x4')]={'type':{'type':Sequelize[_0x7a70c4('0x2')]('string','variable',_0x7a70c4('0x6'),_0x7a70c4('0x3')),'defaultValue':_0x7a70c4('0x1')},'content':{'type':Sequelize[_0x7a70c4('0x7')]},'key':{'type':Sequelize[_0x7a70c4('0x7')]},'keyType':{'type':Sequelize[_0x7a70c4('0x2')](_0x7a70c4('0x1'),_0x7a70c4('0x0'),_0x7a70c4('0x6'))},'keyContent':{'type':Sequelize[_0x7a70c4('0x7')]},'idField':{'type':Sequelize[_0x7a70c4('0x7')]},'nameField':{'type':Sequelize['STRING']},'customField':{'type':Sequelize[_0x7a70c4('0x5')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x7a70c4('0x7')]}}; \ No newline at end of file diff --git a/server/api/intDynamics365Field/intDynamics365Field.controller.js b/server/api/intDynamics365Field/intDynamics365Field.controller.js index 84c9bbc..ade2914 100644 --- a/server/api/intDynamics365Field/intDynamics365Field.controller.js +++ b/server/api/intDynamics365Field/intDynamics365Field.controller.js @@ -1 +1 @@ -const a251_0x54f7=['where','../../components/parsers/qs','limit','filter','index','../../config/logger','lodash','key','then','findOne','api','error','update','sequelize','status','like','set','Content-Range','intersection','findAll','Dynamics365Field','json','model','catch','offset','fields','VIRTUAL','map','type','rawAttributes','nolimit','keys','filters','end','merge','show','rows','count','options','sort','include','attributes','destroy','order','body','query','undefined','length','params','name'];(function(_0x3ddffd,_0x54f7cf){const _0x3d1d62=function(_0x3e4ba0){while(--_0x3e4ba0){_0x3ddffd['push'](_0x3ddffd['shift']());}};_0x3d1d62(++_0x54f7cf);}(a251_0x54f7,0x6a));const a251_0x3d1d=function(_0x3ddffd,_0x54f7cf){_0x3ddffd=_0x3ddffd-0x0;let _0x3d1d62=a251_0x54f7[_0x3ddffd];return _0x3d1d62;};const _0x3212dc=a251_0x3d1d;'use strict';const _=require(_0x3212dc('0x0')),qs=require(_0x3212dc('0x2d')),logger=require(_0x3212dc('0x31'))(_0x3212dc('0x4')),db=require('../../mysqldb')['db'],{Op}=require(_0x3212dc('0x7'));function respondWithResult(_0x3e4ba0,_0x32c3f6){return _0x32c3f6=_0x32c3f6||0xc8,function(_0x3af688){const _0x30114f=a251_0x3d1d;if(_0x3af688)return _0x3e4ba0[_0x30114f('0x8')](_0x32c3f6)['json'](_0x3af688);};}function respondWithFilteredResult(_0x3a1d3c,_0x11291a){return function(_0x26dae8){const _0x2f4082=a251_0x3d1d;if(_0x26dae8){const _0x5b4184=_0x26dae8[_0x2f4082('0x1f')],_0x3bd15d=_0x11291a[_0x2f4082('0x12')];let _0x22bb3b=_0x11291a[_0x2f4082('0x12')]+_0x11291a['limit'],_0x874ea9;return _0x22bb3b>=_0x5b4184?(_0x22bb3b=_0x5b4184,_0x874ea9=0xc8):_0x874ea9=0xce,_0x3a1d3c[_0x2f4082('0x8')](_0x874ea9),_0x3a1d3c[_0x2f4082('0xa')](_0x2f4082('0xb'),_0x3bd15d+'-'+_0x22bb3b+'/'+_0x5b4184)[_0x2f4082('0xf')](_0x26dae8);}return null;};}function saveUpdates(_0x45a7d9){return function(_0x12d3d9){const _0x2ce161=a251_0x3d1d;if(_0x12d3d9)return _0x12d3d9[_0x2ce161('0x6')](_0x45a7d9)[_0x2ce161('0x2')](function(_0x3757a2){return _0x3757a2;});return null;};}function removeEntity(_0x48eaa0){return function(_0x1543d2){const _0x2372d4=a251_0x3d1d;if(_0x1543d2)return _0x1543d2[_0x2372d4('0x24')]()[_0x2372d4('0x2')](function(){const _0x1a90f3=_0x2372d4;_0x48eaa0[_0x1a90f3('0x8')](0xcc)[_0x1a90f3('0x1b')]();});};}function handleEntityNotFound(_0x4675fc){return function(_0x2d1df9){return!_0x2d1df9&&_0x4675fc['sendStatus'](0x194),_0x2d1df9;};}function handleError(_0x40ce2c,_0x2f14ed){return _0x2f14ed=_0x2f14ed||0x1f4,function(_0x46c734){const _0x11356c=a251_0x3d1d;logger[_0x11356c('0x5')](_0x46c734['stack']),_0x46c734[_0x11356c('0x2b')]&&delete _0x46c734[_0x11356c('0x2b')],_0x40ce2c[_0x11356c('0x8')](_0x2f14ed)['send'](_0x46c734);};}exports[_0x3212dc('0x30')]=function(_0x293d9a,_0x13c65e){const _0x5e3580=_0x3212dc;let _0x2ee192={};const _0x1401a2={},_0x4e9562={'count':0x0,'rows':[]},_0x38303b=_[_0x5e3580('0x15')](db['Dynamics365Field'][_0x5e3580('0x17')],function(_0x3a3ae0){const _0x1249ce=_0x5e3580;return{'name':_0x3a3ae0['fieldName'],'type':_0x3a3ae0[_0x1249ce('0x16')][_0x1249ce('0x1')]};});_0x1401a2['model']=_[_0x5e3580('0x15')](_0x38303b,_0x5e3580('0x2b')),_0x1401a2[_0x5e3580('0x27')]=_[_0x5e3580('0x19')](_0x293d9a[_0x5e3580('0x27')]),_0x1401a2['filters']=_[_0x5e3580('0xc')](_0x1401a2[_0x5e3580('0x10')],_0x1401a2[_0x5e3580('0x27')]),_0x2ee192[_0x5e3580('0x23')]=_[_0x5e3580('0xc')](_0x1401a2[_0x5e3580('0x10')],qs['fields'](_0x293d9a[_0x5e3580('0x27')]['fields'])),_0x2ee192['attributes']=_0x2ee192['attributes'][_0x5e3580('0x29')]?_0x2ee192[_0x5e3580('0x23')]:_0x1401a2['model'];typeof _0x293d9a[_0x5e3580('0x27')][_0x5e3580('0x18')]===_0x5e3580('0x28')&&(_0x2ee192[_0x5e3580('0x2e')]=qs[_0x5e3580('0x2e')](_0x293d9a[_0x5e3580('0x27')][_0x5e3580('0x2e')]),_0x2ee192['offset']=qs[_0x5e3580('0x12')](_0x293d9a['query'][_0x5e3580('0x12')]));_0x2ee192[_0x5e3580('0x25')]=qs['sort'](_0x293d9a['query'][_0x5e3580('0x21')]),_0x2ee192[_0x5e3580('0x2c')]=qs['filters'](_['pick'](_0x293d9a[_0x5e3580('0x27')],_0x1401a2[_0x5e3580('0x1a')]),_0x38303b);_0x293d9a[_0x5e3580('0x27')][_0x5e3580('0x2f')]&&(_0x2ee192['where']=_[_0x5e3580('0x1c')](_0x2ee192[_0x5e3580('0x2c')],{[Op['or']]:_[_0x5e3580('0x15')](_0x38303b,function(_0x1f1e94){const _0x1379f1=_0x5e3580;if(_0x1f1e94[_0x1379f1('0x16')]!==_0x1379f1('0x14')){const _0x55308c={};return _0x55308c[_0x1f1e94[_0x1379f1('0x2b')]]={[Op[_0x1379f1('0x9')]]:'%'+_0x293d9a['query'][_0x1379f1('0x2f')]+'%'},_0x55308c;}})}));_0x2ee192=_[_0x5e3580('0x1c')]({},_0x2ee192,_0x293d9a[_0x5e3580('0x20')]);const _0x305c45={'where':_0x2ee192[_0x5e3580('0x2c')]};return db[_0x5e3580('0xe')][_0x5e3580('0x1f')](_0x305c45)[_0x5e3580('0x2')](function(_0x32af4c){const _0x22fcdc=_0x5e3580;return _0x4e9562[_0x22fcdc('0x1f')]=_0x32af4c,_0x293d9a[_0x22fcdc('0x27')]['includeAll']&&(_0x2ee192[_0x22fcdc('0x22')]=[{'all':!![]}]),db['Dynamics365Field'][_0x22fcdc('0xd')](_0x2ee192);})[_0x5e3580('0x2')](function(_0x5769f8){const _0x26f346=_0x5e3580;return _0x4e9562[_0x26f346('0x1e')]=_0x5769f8,_0x4e9562;})['then'](respondWithFilteredResult(_0x13c65e,_0x2ee192))[_0x5e3580('0x11')](handleError(_0x13c65e,null));},exports[_0x3212dc('0x1d')]=function(_0x59b681,_0x471061){const _0x3fffa1=_0x3212dc;let _0x5b5920={'raw':!![],'where':{'id':_0x59b681['params']['id']}};const _0x180aaa={};return _0x180aaa[_0x3fffa1('0x10')]=_[_0x3fffa1('0x19')](db[_0x3fffa1('0xe')][_0x3fffa1('0x17')]),_0x180aaa[_0x3fffa1('0x27')]=_[_0x3fffa1('0x19')](_0x59b681[_0x3fffa1('0x27')]),_0x180aaa[_0x3fffa1('0x1a')]=_[_0x3fffa1('0xc')](_0x180aaa[_0x3fffa1('0x10')],_0x180aaa[_0x3fffa1('0x27')]),_0x5b5920[_0x3fffa1('0x23')]=_[_0x3fffa1('0xc')](_0x180aaa[_0x3fffa1('0x10')],qs[_0x3fffa1('0x13')](_0x59b681[_0x3fffa1('0x27')][_0x3fffa1('0x13')])),_0x5b5920[_0x3fffa1('0x23')]=_0x5b5920[_0x3fffa1('0x23')][_0x3fffa1('0x29')]?_0x5b5920[_0x3fffa1('0x23')]:_0x180aaa['model'],_0x59b681[_0x3fffa1('0x27')]['includeAll']&&(_0x5b5920[_0x3fffa1('0x22')]=[{'all':!![]}]),_0x5b5920=_[_0x3fffa1('0x1c')]({},_0x5b5920,_0x59b681[_0x3fffa1('0x20')]),db[_0x3fffa1('0xe')][_0x3fffa1('0x3')](_0x5b5920)[_0x3fffa1('0x2')](handleEntityNotFound(_0x471061,null))[_0x3fffa1('0x2')](respondWithResult(_0x471061,null))[_0x3fffa1('0x11')](handleError(_0x471061,null));},exports['create']=function(_0x4845fb,_0x1b9867){const _0x28c080=_0x3212dc;return db['Dynamics365Field']['create'](_0x4845fb[_0x28c080('0x26')],{})[_0x28c080('0x2')](respondWithResult(_0x1b9867,0xc9))[_0x28c080('0x11')](handleError(_0x1b9867,null));},exports[_0x3212dc('0x6')]=function(_0x4c34d1,_0x41d9a8){const _0x5c1395=_0x3212dc;return _0x4c34d1[_0x5c1395('0x26')]['id']&&delete _0x4c34d1[_0x5c1395('0x26')]['id'],db[_0x5c1395('0xe')]['findOne']({'where':{'id':_0x4c34d1[_0x5c1395('0x2a')]['id']}})[_0x5c1395('0x2')](handleEntityNotFound(_0x41d9a8,null))[_0x5c1395('0x2')](saveUpdates(_0x4c34d1[_0x5c1395('0x26')],null))[_0x5c1395('0x2')](respondWithResult(_0x41d9a8,null))[_0x5c1395('0x11')](handleError(_0x41d9a8,null));},exports[_0x3212dc('0x24')]=function(_0x16550c,_0x4d68a6){const _0x18d99c=_0x3212dc;return db[_0x18d99c('0xe')]['findOne']({'where':{'id':_0x16550c[_0x18d99c('0x2a')]['id']}})['then'](handleEntityNotFound(_0x4d68a6,null))[_0x18d99c('0x2')](removeEntity(_0x4d68a6,null))[_0x18d99c('0x11')](handleError(_0x4d68a6,null));}; \ No newline at end of file +const a251_0x26cf=['body','destroy','catch','type','create','rawAttributes','lodash','../../config/logger','keys','json','rows','intersection','Dynamics365Field','model','merge','status','findAll','filters','set','map','query','nolimit','key','VIRTUAL','includeAll','undefined','params','filter','count','fields','then','name','update','where','Content-Range','../../mysqldb','error','sort','end','length','offset','limit','pick','attributes','findOne','include','send'];(function(_0x334ed8,_0x26cffb){const _0x5a3828=function(_0x54ca26){while(--_0x54ca26){_0x334ed8['push'](_0x334ed8['shift']());}};_0x5a3828(++_0x26cffb);}(a251_0x26cf,0x9e));const a251_0x5a38=function(_0x334ed8,_0x26cffb){_0x334ed8=_0x334ed8-0x0;let _0x5a3828=a251_0x26cf[_0x334ed8];return _0x5a3828;};const _0xeb8cfc=a251_0x5a38;'use strict';const _=require(_0xeb8cfc('0x24')),qs=require('../../components/parsers/qs'),logger=require(_0xeb8cfc('0x25'))('api'),db=require(_0xeb8cfc('0x12'))['db'],{Op}=require('sequelize');function respondWithResult(_0x54ca26,_0x35510b){return _0x35510b=_0x35510b||0xc8,function(_0x1d0add){if(_0x1d0add)return _0x54ca26['status'](_0x35510b)['json'](_0x1d0add);};}function respondWithFilteredResult(_0x40dd50,_0x2cdf05){return function(_0x4fb8d4){const _0x127d20=a251_0x5a38;if(_0x4fb8d4){const _0x80adc=_0x4fb8d4['count'],_0x5a5c4a=_0x2cdf05['offset'];let _0x31f971=_0x2cdf05[_0x127d20('0x17')]+_0x2cdf05[_0x127d20('0x18')],_0x2fde8b;return _0x31f971>=_0x80adc?(_0x31f971=_0x80adc,_0x2fde8b=0xc8):_0x2fde8b=0xce,_0x40dd50['status'](_0x2fde8b),_0x40dd50[_0x127d20('0x1')](_0x127d20('0x11'),_0x5a5c4a+'-'+_0x31f971+'/'+_0x80adc)[_0x127d20('0x27')](_0x4fb8d4);}return null;};}function saveUpdates(_0x2d5b35){return function(_0x2fa2fb){const _0x64c426=a251_0x5a38;if(_0x2fa2fb)return _0x2fa2fb[_0x64c426('0xf')](_0x2d5b35)[_0x64c426('0xd')](function(_0x328e11){return _0x328e11;});return null;};}function removeEntity(_0x3acfa2){return function(_0x1be8fa){const _0x52a9bb=a251_0x5a38;if(_0x1be8fa)return _0x1be8fa[_0x52a9bb('0x1f')]()[_0x52a9bb('0xd')](function(){const _0x421342=_0x52a9bb;_0x3acfa2['status'](0xcc)[_0x421342('0x15')]();});};}function handleEntityNotFound(_0x5dca42){return function(_0x42eca3){return!_0x42eca3&&_0x5dca42['sendStatus'](0x194),_0x42eca3;};}function handleError(_0x558015,_0x1fa7de){return _0x1fa7de=_0x1fa7de||0x1f4,function(_0x62f93c){const _0x33f733=a251_0x5a38;logger[_0x33f733('0x13')](_0x62f93c['stack']),_0x62f93c[_0x33f733('0xe')]&&delete _0x62f93c[_0x33f733('0xe')],_0x558015[_0x33f733('0x2d')](_0x1fa7de)[_0x33f733('0x1d')](_0x62f93c);};}exports['index']=function(_0x5917b3,_0x15687a){const _0x52a15c=_0xeb8cfc;let _0x465ab7={};const _0x1fe426={},_0x54fa21={'count':0x0,'rows':[]},_0x1bf80f=_[_0x52a15c('0x2')](db[_0x52a15c('0x2a')][_0x52a15c('0x23')],function(_0xa69935){const _0x17fc1b=_0x52a15c;return{'name':_0xa69935['fieldName'],'type':_0xa69935['type'][_0x17fc1b('0x5')]};});_0x1fe426['model']=_[_0x52a15c('0x2')](_0x1bf80f,_0x52a15c('0xe')),_0x1fe426[_0x52a15c('0x3')]=_[_0x52a15c('0x26')](_0x5917b3[_0x52a15c('0x3')]),_0x1fe426[_0x52a15c('0x0')]=_[_0x52a15c('0x29')](_0x1fe426[_0x52a15c('0x2b')],_0x1fe426[_0x52a15c('0x3')]),_0x465ab7[_0x52a15c('0x1a')]=_['intersection'](_0x1fe426[_0x52a15c('0x2b')],qs['fields'](_0x5917b3[_0x52a15c('0x3')]['fields'])),_0x465ab7[_0x52a15c('0x1a')]=_0x465ab7['attributes'][_0x52a15c('0x16')]?_0x465ab7['attributes']:_0x1fe426[_0x52a15c('0x2b')];typeof _0x5917b3['query'][_0x52a15c('0x4')]===_0x52a15c('0x8')&&(_0x465ab7['limit']=qs[_0x52a15c('0x18')](_0x5917b3[_0x52a15c('0x3')]['limit']),_0x465ab7[_0x52a15c('0x17')]=qs[_0x52a15c('0x17')](_0x5917b3[_0x52a15c('0x3')]['offset']));_0x465ab7['order']=qs[_0x52a15c('0x14')](_0x5917b3['query'][_0x52a15c('0x14')]),_0x465ab7[_0x52a15c('0x10')]=qs[_0x52a15c('0x0')](_[_0x52a15c('0x19')](_0x5917b3[_0x52a15c('0x3')],_0x1fe426[_0x52a15c('0x0')]),_0x1bf80f);_0x5917b3[_0x52a15c('0x3')][_0x52a15c('0xa')]&&(_0x465ab7[_0x52a15c('0x10')]=_[_0x52a15c('0x2c')](_0x465ab7[_0x52a15c('0x10')],{[Op['or']]:_[_0x52a15c('0x2')](_0x1bf80f,function(_0x64b41b){const _0x176561=_0x52a15c;if(_0x64b41b[_0x176561('0x21')]!==_0x176561('0x6')){const _0x2ebe06={};return _0x2ebe06[_0x64b41b[_0x176561('0xe')]]={[Op['like']]:'%'+_0x5917b3[_0x176561('0x3')][_0x176561('0xa')]+'%'},_0x2ebe06;}})}));_0x465ab7=_[_0x52a15c('0x2c')]({},_0x465ab7,_0x5917b3['options']);const _0x4a6aee={'where':_0x465ab7[_0x52a15c('0x10')]};return db[_0x52a15c('0x2a')]['count'](_0x4a6aee)[_0x52a15c('0xd')](function(_0x101ea9){const _0x364cc8=_0x52a15c;return _0x54fa21[_0x364cc8('0xb')]=_0x101ea9,_0x5917b3[_0x364cc8('0x3')]['includeAll']&&(_0x465ab7['include']=[{'all':!![]}]),db[_0x364cc8('0x2a')][_0x364cc8('0x2e')](_0x465ab7);})[_0x52a15c('0xd')](function(_0x14a4c5){const _0x536907=_0x52a15c;return _0x54fa21[_0x536907('0x28')]=_0x14a4c5,_0x54fa21;})[_0x52a15c('0xd')](respondWithFilteredResult(_0x15687a,_0x465ab7))[_0x52a15c('0x20')](handleError(_0x15687a,null));},exports['show']=function(_0x4522fc,_0x277377){const _0xd9f914=_0xeb8cfc;let _0x586301={'raw':!![],'where':{'id':_0x4522fc['params']['id']}};const _0x865278={};return _0x865278[_0xd9f914('0x2b')]=_[_0xd9f914('0x26')](db[_0xd9f914('0x2a')][_0xd9f914('0x23')]),_0x865278[_0xd9f914('0x3')]=_['keys'](_0x4522fc[_0xd9f914('0x3')]),_0x865278[_0xd9f914('0x0')]=_['intersection'](_0x865278[_0xd9f914('0x2b')],_0x865278[_0xd9f914('0x3')]),_0x586301[_0xd9f914('0x1a')]=_[_0xd9f914('0x29')](_0x865278[_0xd9f914('0x2b')],qs[_0xd9f914('0xc')](_0x4522fc[_0xd9f914('0x3')][_0xd9f914('0xc')])),_0x586301[_0xd9f914('0x1a')]=_0x586301[_0xd9f914('0x1a')][_0xd9f914('0x16')]?_0x586301['attributes']:_0x865278[_0xd9f914('0x2b')],_0x4522fc[_0xd9f914('0x3')][_0xd9f914('0x7')]&&(_0x586301[_0xd9f914('0x1c')]=[{'all':!![]}]),_0x586301=_[_0xd9f914('0x2c')]({},_0x586301,_0x4522fc['options']),db[_0xd9f914('0x2a')][_0xd9f914('0x1b')](_0x586301)[_0xd9f914('0xd')](handleEntityNotFound(_0x277377,null))[_0xd9f914('0xd')](respondWithResult(_0x277377,null))['catch'](handleError(_0x277377,null));},exports[_0xeb8cfc('0x22')]=function(_0x3f1cd1,_0x38afea){const _0x27625e=_0xeb8cfc;return db[_0x27625e('0x2a')][_0x27625e('0x22')](_0x3f1cd1[_0x27625e('0x1e')],{})[_0x27625e('0xd')](respondWithResult(_0x38afea,0xc9))[_0x27625e('0x20')](handleError(_0x38afea,null));},exports['update']=function(_0x5baf04,_0x3fcd38){const _0x33d4d0=_0xeb8cfc;return _0x5baf04[_0x33d4d0('0x1e')]['id']&&delete _0x5baf04['body']['id'],db[_0x33d4d0('0x2a')][_0x33d4d0('0x1b')]({'where':{'id':_0x5baf04['params']['id']}})[_0x33d4d0('0xd')](handleEntityNotFound(_0x3fcd38,null))[_0x33d4d0('0xd')](saveUpdates(_0x5baf04[_0x33d4d0('0x1e')],null))[_0x33d4d0('0xd')](respondWithResult(_0x3fcd38,null))[_0x33d4d0('0x20')](handleError(_0x3fcd38,null));},exports['destroy']=function(_0x1025d6,_0x4a3887){const _0x570244=_0xeb8cfc;return db[_0x570244('0x2a')][_0x570244('0x1b')]({'where':{'id':_0x1025d6[_0x570244('0x9')]['id']}})[_0x570244('0xd')](handleEntityNotFound(_0x4a3887,null))['then'](removeEntity(_0x4a3887,null))[_0x570244('0x20')](handleError(_0x4a3887,null));}; \ No newline at end of file diff --git a/server/api/intDynamics365Field/intDynamics365Field.model.js b/server/api/intDynamics365Field/intDynamics365Field.model.js index af7d837..1634675 100644 --- a/server/api/intDynamics365Field/intDynamics365Field.model.js +++ b/server/api/intDynamics365Field/intDynamics365Field.model.js @@ -1 +1 @@ -const a252_0x5888=['exports','./intDynamics365Field.attributes','idField','int_dynamics365_fields','FieldId','Dynamics365Field','define','dynamics365_unique_index'];(function(_0x3e5218,_0x5888a7){const _0x272cb2=function(_0x217713){while(--_0x217713){_0x3e5218['push'](_0x3e5218['shift']());}};_0x272cb2(++_0x5888a7);}(a252_0x5888,0x154));const a252_0x272c=function(_0x3e5218,_0x5888a7){_0x3e5218=_0x3e5218-0x0;let _0x272cb2=a252_0x5888[_0x3e5218];return _0x272cb2;};const _0x362d1b=a252_0x272c;'use strict';const attributes=require(_0x362d1b('0x5'));module[_0x362d1b('0x4')]=function(_0x217713){const _0x5e772a=_0x362d1b,_0x238e39=_0x217713[_0x5e772a('0x2')](_0x5e772a('0x1'),attributes,{'tableName':_0x5e772a('0x7'),'paranoid':![],'indexes':[{'name':_0x5e772a('0x3'),'fields':[_0x5e772a('0x6'),_0x5e772a('0x0')],'unique':!![]}],'timestamps':!![]});return _0x238e39;}; \ No newline at end of file +const a252_0x105c=['exports','idField','int_dynamics365_fields','define','./intDynamics365Field.attributes','dynamics365_unique_index'];(function(_0x267e77,_0x105cde){const _0x3c19d6=function(_0x51da4a){while(--_0x51da4a){_0x267e77['push'](_0x267e77['shift']());}};_0x3c19d6(++_0x105cde);}(a252_0x105c,0x134));const a252_0x3c19=function(_0x267e77,_0x105cde){_0x267e77=_0x267e77-0x0;let _0x3c19d6=a252_0x105c[_0x267e77];return _0x3c19d6;};const _0x143171=a252_0x3c19;'use strict';const attributes=require(_0x143171('0x2'));module[_0x143171('0x4')]=function(_0x51da4a){const _0x5b75b6=_0x143171,_0x55f9fa=_0x51da4a[_0x5b75b6('0x1')]('Dynamics365Field',attributes,{'tableName':_0x5b75b6('0x0'),'paranoid':![],'indexes':[{'name':_0x5b75b6('0x3'),'fields':[_0x5b75b6('0x5'),'FieldId'],'unique':!![]}],'timestamps':!![]});return _0x55f9fa;}; \ No newline at end of file diff --git a/server/api/intFreshdeskAccount/index.js b/server/api/intFreshdeskAccount/index.js index 748f499..17713cd 100644 --- a/server/api/intFreshdeskAccount/index.js +++ b/server/api/intFreshdeskAccount/index.js @@ -1 +1 @@ -const a253_0x6e2a=['isAuthenticated','get','./intFreshdeskAccount.controller','getFields','getConfigurations','index','express','update','delete','show','post','/:id','create','put','/:id/configurations'];(function(_0x38436a,_0x6e2a85){const _0xdcee09=function(_0x461c31){while(--_0x461c31){_0x38436a['push'](_0x38436a['shift']());}};_0xdcee09(++_0x6e2a85);}(a253_0x6e2a,0x1a9));const a253_0xdcee=function(_0x38436a,_0x6e2a85){_0x38436a=_0x38436a-0x0;let _0xdcee09=a253_0x6e2a[_0x38436a];return _0xdcee09;};const _0x337cba=a253_0xdcee;'use strict';const express=require(_0x337cba('0x1')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x337cba('0xc'));router[_0x337cba('0xb')]('/',auth[_0x337cba('0xa')](),controller[_0x337cba('0x0')]),router[_0x337cba('0xb')](_0x337cba('0x6'),auth['isAuthenticated'](),controller[_0x337cba('0x4')]),router[_0x337cba('0xb')](_0x337cba('0x9'),auth[_0x337cba('0xa')](),controller[_0x337cba('0xe')]),router[_0x337cba('0xb')]('/:id/fields',auth['isAuthenticated'](),controller[_0x337cba('0xd')]),router[_0x337cba('0x5')]('/',auth['isAuthenticated'](),controller[_0x337cba('0x7')]),router[_0x337cba('0x5')](_0x337cba('0x9'),auth[_0x337cba('0xa')](),controller['addConfiguration']),router[_0x337cba('0x8')](_0x337cba('0x6'),auth[_0x337cba('0xa')](),controller[_0x337cba('0x2')]),router[_0x337cba('0x3')](_0x337cba('0x6'),auth[_0x337cba('0xa')](),controller['destroy']),module['exports']=router; \ No newline at end of file +const a253_0x2bd3=['show','destroy','exports','addConfiguration','/:id/configurations','put','update','post','/:id','./intFreshdeskAccount.controller','index','create','get','delete','../../components/auth/service','/:id/fields','getFields','express','isAuthenticated'];(function(_0x5dd764,_0x2bd3e8){const _0x16cb73=function(_0x162942){while(--_0x162942){_0x5dd764['push'](_0x5dd764['shift']());}};_0x16cb73(++_0x2bd3e8);}(a253_0x2bd3,0xa3));const a253_0x16cb=function(_0x5dd764,_0x2bd3e8){_0x5dd764=_0x5dd764-0x0;let _0x16cb73=a253_0x2bd3[_0x5dd764];return _0x16cb73;};const _0x10d808=a253_0x16cb;'use strict';const express=require(_0x10d808('0x6')),router=express['Router'](),auth=require(_0x10d808('0x3')),controller=require(_0x10d808('0x11'));router['get']('/',auth[_0x10d808('0x7')](),controller[_0x10d808('0x12')]),router[_0x10d808('0x1')](_0x10d808('0x10'),auth[_0x10d808('0x7')](),controller[_0x10d808('0x8')]),router[_0x10d808('0x1')](_0x10d808('0xc'),auth[_0x10d808('0x7')](),controller['getConfigurations']),router['get'](_0x10d808('0x4'),auth[_0x10d808('0x7')](),controller[_0x10d808('0x5')]),router['post']('/',auth[_0x10d808('0x7')](),controller[_0x10d808('0x0')]),router[_0x10d808('0xf')]('/:id/configurations',auth['isAuthenticated'](),controller[_0x10d808('0xb')]),router[_0x10d808('0xd')](_0x10d808('0x10'),auth['isAuthenticated'](),controller[_0x10d808('0xe')]),router[_0x10d808('0x2')](_0x10d808('0x10'),auth[_0x10d808('0x7')](),controller[_0x10d808('0x9')]),module[_0x10d808('0xa')]=router; \ No newline at end of file diff --git a/server/api/intFreshdeskAccount/intFreshdeskAccount.attributes.js b/server/api/intFreshdeskAccount/intFreshdeskAccount.attributes.js index 2cbc9dd..ce42065 100644 --- a/server/api/intFreshdeskAccount/intFreshdeskAccount.attributes.js +++ b/server/api/intFreshdeskAccount/intFreshdeskAccount.attributes.js @@ -1 +1 @@ -const a254_0x1117=['sequelize','exports','username','remoteUri','STRING'];(function(_0x1c779b,_0x11170d){const _0x17283e=function(_0x9829fb){while(--_0x9829fb){_0x1c779b['push'](_0x1c779b['shift']());}};_0x17283e(++_0x11170d);}(a254_0x1117,0x167));const a254_0x1728=function(_0x1c779b,_0x11170d){_0x1c779b=_0x1c779b-0x0;let _0x17283e=a254_0x1117[_0x1c779b];return _0x17283e;};const _0x51ace8=a254_0x1728;'use strict';const Sequelize=require(_0x51ace8('0x1'));module[_0x51ace8('0x2')]={'name':{'type':Sequelize[_0x51ace8('0x0')]},'description':{'type':Sequelize[_0x51ace8('0x0')]},'username':{'type':Sequelize[_0x51ace8('0x0')],'unique':_0x51ace8('0x3')},'apiKey':{'type':Sequelize[_0x51ace8('0x0')]},'remoteUri':{'type':Sequelize[_0x51ace8('0x0')],'unique':_0x51ace8('0x4')},'serverUrl':{'type':Sequelize[_0x51ace8('0x0')]}}; \ No newline at end of file +const a254_0x41f8=['STRING','sequelize','username','exports','remoteUri'];(function(_0x212c79,_0x41f8ef){const _0x32a093=function(_0x2a4450){while(--_0x2a4450){_0x212c79['push'](_0x212c79['shift']());}};_0x32a093(++_0x41f8ef);}(a254_0x41f8,0x162));const a254_0x32a0=function(_0x212c79,_0x41f8ef){_0x212c79=_0x212c79-0x0;let _0x32a093=a254_0x41f8[_0x212c79];return _0x32a093;};const _0x239f94=a254_0x32a0;'use strict';const Sequelize=require(_0x239f94('0x2'));module[_0x239f94('0x4')]={'name':{'type':Sequelize[_0x239f94('0x1')]},'description':{'type':Sequelize[_0x239f94('0x1')]},'username':{'type':Sequelize[_0x239f94('0x1')],'unique':_0x239f94('0x3')},'apiKey':{'type':Sequelize[_0x239f94('0x1')]},'remoteUri':{'type':Sequelize[_0x239f94('0x1')],'unique':_0x239f94('0x0')},'serverUrl':{'type':Sequelize[_0x239f94('0x1')]}}; \ No newline at end of file diff --git a/server/api/intFreshdeskAccount/intFreshdeskAccount.controller.js b/server/api/intFreshdeskAccount/intFreshdeskAccount.controller.js index 3979f2a..fd85fb9 100644 --- a/server/api/intFreshdeskAccount/intFreshdeskAccount.controller.js +++ b/server/api/intFreshdeskAccount/intFreshdeskAccount.controller.js @@ -1 +1 @@ -const a255_0x2632=['findAll','query','agent','json','apiKey','%s/%s','remoteUri','request-promise-native','toString','ticket_type','rawAttributes','lodash','test','addConfiguration','stringify','include','../../components/parsers/qs','type','then','requester','remove','update','body','Subjects','filter','keys','offset','filters','capitalize','Basic\x20%s','error','Wrong\x20credentials','show','../../mysqldb','description','rows','AccountId','count','getFields','order','fieldName','catch','model','slice','nolimit','format','fields','like','name','getSubjects','%s:X','limit','where','pick','status','../../components/integrations/configuration','key','Descriptions','index','../../config/logger','findOne','sendStatus','destroy','channel','VIRTUAL','create','includeAll','attributes','FreshdeskConfiguration','group','lastIndexOf','api/v2/ticket_fields','getConfigurations','sort','FreshdeskAccount','params','FreshdeskField','set','intersection','options','Content-Range','map','custom_text','end','default','choices','undefined','statusCode','stack','length','merge','substring'];(function(_0x1976ba,_0x26321f){const _0x8c0002=function(_0x4bb3b8){while(--_0x4bb3b8){_0x1976ba['push'](_0x1976ba['shift']());}};_0x8c0002(++_0x26321f);}(a255_0x2632,0x92));const a255_0x8c00=function(_0x1976ba,_0x26321f){_0x1976ba=_0x1976ba-0x0;let _0x8c0002=a255_0x2632[_0x1976ba];return _0x8c0002;};const _0x2206f2=a255_0x8c00;'use strict';const rp=require(_0x2206f2('0x2d')),util=require('util'),_=require(_0x2206f2('0x31')),qs=require(_0x2206f2('0x36')),logger=require(_0x2206f2('0x5'))('api'),db=require(_0x2206f2('0x47'))['db'],{Op}=require('sequelize'),integrations=require(_0x2206f2('0x1'));function respondWithResult(_0x4bb3b8,_0x4b80d9){return _0x4b80d9=_0x4b80d9||0xc8,function(_0x4f1928){const _0xc031e8=a255_0x8c00;if(_0x4f1928)return _0x4bb3b8['status'](_0x4b80d9)[_0xc031e8('0x29')](_0x4f1928);};}function respondWithFilteredResult(_0x41196c,_0x2cd114){return function(_0x5b6488){const _0x211b70=a255_0x8c00;if(_0x5b6488){const _0x3fde12=_0x5b6488[_0x211b70('0x4b')],_0x77eb3c=_0x2cd114[_0x211b70('0x40')];let _0x157818=_0x2cd114['offset']+_0x2cd114[_0x211b70('0x59')],_0x532177;return _0x157818>=_0x3fde12?(_0x157818=_0x3fde12,_0x532177=0xc8):_0x532177=0xce,_0x41196c[_0x211b70('0x0')](_0x532177),_0x41196c[_0x211b70('0x17')](_0x211b70('0x1a'),_0x77eb3c+'-'+_0x157818+'/'+_0x3fde12)[_0x211b70('0x29')](_0x5b6488);}return null;};}function saveUpdates(_0x3d93ce){return function(_0x16c763){const _0x14cd9a=a255_0x8c00;if(_0x16c763)return _0x16c763[_0x14cd9a('0x3b')](_0x3d93ce)['then'](function(_0x3e2db7){return _0x3e2db7;});return null;};}function removeEntity(_0x5908ea){return function(_0x599a4a){const _0x363ff5=a255_0x8c00;if(_0x599a4a)return _0x599a4a[_0x363ff5('0x8')]()['then'](function(){const _0x337d19=_0x363ff5;_0x5908ea[_0x337d19('0x0')](0xcc)[_0x337d19('0x1d')]();});};}function handleEntityNotFound(_0x31c647){return function(_0x518a3e){const _0x4522d0=a255_0x8c00;return!_0x518a3e&&_0x31c647[_0x4522d0('0x7')](0x194),_0x518a3e;};}function handleError(_0x43c5ca,_0x46b909){return _0x46b909=_0x46b909||0x1f4,function(_0x102a46){const _0x3fd8e9=a255_0x8c00;logger[_0x3fd8e9('0x44')](_0x102a46[_0x3fd8e9('0x22')]),_0x102a46[_0x3fd8e9('0x56')]&&delete _0x102a46['name'],_0x43c5ca[_0x3fd8e9('0x0')](_0x46b909)['send'](_0x102a46);};}exports[_0x2206f2('0x4')]=function(_0x8b9736,_0xf2a27c){const _0xd49600=_0x2206f2;let _0xdf15bf={};const _0x3cfddf={},_0x49f3cf={'count':0x0,'rows':[]},_0x43a7c3=_[_0xd49600('0x1b')](db[_0xd49600('0x14')][_0xd49600('0x30')],function(_0x122e3b){const _0x2fc14d=_0xd49600;return{'name':_0x122e3b[_0x2fc14d('0x4e')],'type':_0x122e3b[_0x2fc14d('0x37')][_0x2fc14d('0x2')]};});_0x3cfddf[_0xd49600('0x50')]=_[_0xd49600('0x1b')](_0x43a7c3,_0xd49600('0x56')),_0x3cfddf[_0xd49600('0x27')]=_['keys'](_0x8b9736[_0xd49600('0x27')]),_0x3cfddf[_0xd49600('0x41')]=_[_0xd49600('0x18')](_0x3cfddf[_0xd49600('0x50')],_0x3cfddf[_0xd49600('0x27')]),_0xdf15bf[_0xd49600('0xd')]=_[_0xd49600('0x18')](_0x3cfddf[_0xd49600('0x50')],qs['fields'](_0x8b9736[_0xd49600('0x27')][_0xd49600('0x54')])),_0xdf15bf[_0xd49600('0xd')]=_0xdf15bf[_0xd49600('0xd')][_0xd49600('0x23')]?_0xdf15bf[_0xd49600('0xd')]:_0x3cfddf[_0xd49600('0x50')];typeof _0x8b9736[_0xd49600('0x27')][_0xd49600('0x52')]===_0xd49600('0x20')&&(_0xdf15bf[_0xd49600('0x59')]=qs['limit'](_0x8b9736[_0xd49600('0x27')][_0xd49600('0x59')]),_0xdf15bf[_0xd49600('0x40')]=qs[_0xd49600('0x40')](_0x8b9736[_0xd49600('0x27')][_0xd49600('0x40')]));_0xdf15bf[_0xd49600('0x4d')]=qs['sort'](_0x8b9736[_0xd49600('0x27')][_0xd49600('0x13')]),_0xdf15bf[_0xd49600('0x5a')]=qs[_0xd49600('0x41')](_[_0xd49600('0x5b')](_0x8b9736[_0xd49600('0x27')],_0x3cfddf[_0xd49600('0x41')]),_0x43a7c3);_0x8b9736[_0xd49600('0x27')]['filter']&&(_0xdf15bf[_0xd49600('0x5a')]=_['merge'](_0xdf15bf[_0xd49600('0x5a')],{[Op['or']]:_[_0xd49600('0x1b')](_0x43a7c3,function(_0x4342be){const _0x1f3db5=_0xd49600;if(_0x4342be[_0x1f3db5('0x37')]!==_0x1f3db5('0xa')){const _0x45c325={};return _0x45c325[_0x4342be[_0x1f3db5('0x56')]]={[Op[_0x1f3db5('0x55')]]:'%'+_0x8b9736[_0x1f3db5('0x27')][_0x1f3db5('0x3e')]+'%'},_0x45c325;}})}));_0xdf15bf=_[_0xd49600('0x24')]({},_0xdf15bf,_0x8b9736[_0xd49600('0x19')]);const _0x24ad76={'where':_0xdf15bf['where']};return db[_0xd49600('0x14')][_0xd49600('0x4b')](_0x24ad76)[_0xd49600('0x38')](function(_0x55ab33){const _0xfae096=_0xd49600;return _0x49f3cf[_0xfae096('0x4b')]=_0x55ab33,_0x8b9736[_0xfae096('0x27')][_0xfae096('0xc')]&&(_0xdf15bf[_0xfae096('0x35')]=[{'all':!![]}]),db[_0xfae096('0x14')][_0xfae096('0x26')](_0xdf15bf);})[_0xd49600('0x38')](function(_0x2ed93c){const _0x1a7cc4=_0xd49600;return _0x49f3cf[_0x1a7cc4('0x49')]=_0x2ed93c,_0x49f3cf;})['then'](respondWithFilteredResult(_0xf2a27c,_0xdf15bf))[_0xd49600('0x4f')](handleError(_0xf2a27c,null));},exports[_0x2206f2('0x46')]=function(_0x35f79f,_0x758db5){const _0xed73c5=_0x2206f2;let _0x33ec3d={'raw':![],'where':{'id':_0x35f79f[_0xed73c5('0x15')]['id']}};const _0x4f22f1={};return _0x4f22f1['model']=_[_0xed73c5('0x3f')](db['FreshdeskAccount'][_0xed73c5('0x30')]),_0x4f22f1['query']=_[_0xed73c5('0x3f')](_0x35f79f[_0xed73c5('0x27')]),_0x4f22f1[_0xed73c5('0x41')]=_['intersection'](_0x4f22f1[_0xed73c5('0x50')],_0x4f22f1[_0xed73c5('0x27')]),_0x33ec3d['attributes']=_[_0xed73c5('0x18')](_0x4f22f1[_0xed73c5('0x50')],qs[_0xed73c5('0x54')](_0x35f79f['query']['fields'])),_0x33ec3d['attributes']=_0x33ec3d['attributes'][_0xed73c5('0x23')]?_0x33ec3d['attributes']:_0x4f22f1['model'],_0x35f79f[_0xed73c5('0x27')]['includeAll']&&(_0x33ec3d[_0xed73c5('0x35')]=[{'all':!![]}]),_0x33ec3d=_[_0xed73c5('0x24')]({},_0x33ec3d,_0x35f79f[_0xed73c5('0x19')]),db[_0xed73c5('0x14')][_0xed73c5('0x6')](_0x33ec3d)['then'](handleEntityNotFound(_0x758db5,null))[_0xed73c5('0x38')](respondWithResult(_0x758db5,null))[_0xed73c5('0x4f')](handleError(_0x758db5,null));},exports[_0x2206f2('0xb')]=function(_0x2062a0,_0x22efef){const _0x14a39f=_0x2206f2;return db[_0x14a39f('0x14')][_0x14a39f('0xb')](_0x2062a0[_0x14a39f('0x3c')],{})['then'](respondWithResult(_0x22efef,0xc9))[_0x14a39f('0x4f')](handleError(_0x22efef,null));},exports[_0x2206f2('0x3b')]=function(_0x22517c,_0x2401c4){const _0x558546=_0x2206f2;return _0x22517c[_0x558546('0x3c')]['id']&&delete _0x22517c['body']['id'],db[_0x558546('0x14')][_0x558546('0x6')]({'where':{'id':_0x22517c[_0x558546('0x15')]['id']}})['then'](handleEntityNotFound(_0x2401c4,null))[_0x558546('0x38')](saveUpdates(_0x22517c['body'],null))[_0x558546('0x38')](respondWithResult(_0x2401c4,null))[_0x558546('0x4f')](handleError(_0x2401c4,null));},exports[_0x2206f2('0x8')]=function(_0xd7723a,_0x35ddd7){const _0x20777d=_0x2206f2;return db[_0x20777d('0x14')][_0x20777d('0x6')]({'where':{'id':_0xd7723a[_0x20777d('0x15')]['id']}})['then'](handleEntityNotFound(_0x35ddd7,null))[_0x20777d('0x38')](removeEntity(_0x35ddd7,null))[_0x20777d('0x4f')](handleError(_0x35ddd7,null));},exports['getConfigurations']=function(_0x2b08d8,_0x1631bf){const _0x3529e3=_0x2206f2;let _0x10a247={};const _0x28e399={};let _0x1953e7,_0x74e44c;return db[_0x3529e3('0x14')][_0x3529e3('0x6')]({'where':{'id':_0x2b08d8[_0x3529e3('0x15')]['id']}})[_0x3529e3('0x38')](handleEntityNotFound(_0x1631bf,null))[_0x3529e3('0x38')](function(_0xc7d4d3){const _0x3438aa=_0x3529e3;if(_0xc7d4d3)return _0x1953e7=_0xc7d4d3,_0x28e399[_0x3438aa('0x50')]=_['keys'](db[_0x3438aa('0xe')][_0x3438aa('0x30')]),_0x28e399['query']=_['keys'](_0x2b08d8[_0x3438aa('0x27')]),_0x28e399['filters']=_[_0x3438aa('0x18')](_0x28e399[_0x3438aa('0x50')],_0x28e399[_0x3438aa('0x27')]),_0x10a247['attributes']=_['intersection'](_0x28e399[_0x3438aa('0x50')],qs[_0x3438aa('0x54')](_0x2b08d8[_0x3438aa('0x27')][_0x3438aa('0x54')])),_0x10a247[_0x3438aa('0xd')]=_0x10a247[_0x3438aa('0xd')][_0x3438aa('0x23')]?_0x10a247[_0x3438aa('0xd')]:_0x28e399[_0x3438aa('0x50')],_0x10a247[_0x3438aa('0x4d')]=qs[_0x3438aa('0x13')](_0x2b08d8['query'][_0x3438aa('0x13')]),_0x10a247['where']=qs[_0x3438aa('0x41')](_[_0x3438aa('0x5b')](_0x2b08d8[_0x3438aa('0x27')],_0x28e399[_0x3438aa('0x41')])),_0x2b08d8[_0x3438aa('0x27')][_0x3438aa('0x3e')]&&(_0x10a247[_0x3438aa('0x5a')]=_[_0x3438aa('0x24')](_0x10a247[_0x3438aa('0x5a')],{[Op['or']]:_['map'](_0x10a247[_0x3438aa('0xd')],function(_0x1c8e1b){const _0x556579=_0x3438aa,_0x5a44c6={};return _0x5a44c6[_0x1c8e1b]={[Op[_0x556579('0x55')]]:'%'+_0x2b08d8[_0x556579('0x27')]['filter']+'%'},_0x5a44c6;})})),_0x10a247=_[_0x3438aa('0x24')]({},_0x10a247,_0x2b08d8['options']),_0x1953e7[_0x3438aa('0x12')](_0x10a247);})['then'](function(_0x773f6){const _0x430342=_0x3529e3;if(_0x773f6)return _0x74e44c=_0x773f6[_0x430342('0x23')],typeof _0x2b08d8[_0x430342('0x27')][_0x430342('0x52')]===_0x430342('0x20')&&(_0x10a247[_0x430342('0x59')]=qs[_0x430342('0x59')](_0x2b08d8[_0x430342('0x27')][_0x430342('0x59')]),_0x10a247[_0x430342('0x40')]=qs[_0x430342('0x40')](_0x2b08d8[_0x430342('0x27')][_0x430342('0x40')])),_0x1953e7[_0x430342('0x12')](_0x10a247);})[_0x3529e3('0x38')](function(_0x3a3769){if(_0x3a3769)return _0x3a3769?{'count':_0x74e44c,'rows':_0x3a3769}:null;})[_0x3529e3('0x38')](respondWithResult(_0x1631bf,null))['catch'](handleError(_0x1631bf,null));},exports[_0x2206f2('0x33')]=function(_0x3eb8bf,_0x1a0f11){const _0x5ed1bc=_0x2206f2;return _0x3eb8bf[_0x5ed1bc('0x3c')]['id']&&delete _0x3eb8bf[_0x5ed1bc('0x3c')]['id'],db[_0x5ed1bc('0x14')]['findOne']({'where':{'id':_0x3eb8bf['params']['id']}})['then'](handleEntityNotFound(_0x1a0f11,null))[_0x5ed1bc('0x38')](function(_0x210b1f){const _0x43bbe=_0x5ed1bc;if(_0x210b1f)return _0x3eb8bf[_0x43bbe('0x3c')][_0x43bbe('0x4a')]=_0x210b1f['id'],_0x3eb8bf[_0x43bbe('0x3c')][_0x43bbe('0x3d')]=integrations[_0x43bbe('0x57')](_0x3eb8bf[_0x43bbe('0x3c')][_0x43bbe('0x9')],_0x3eb8bf[_0x43bbe('0x3c')][_0x43bbe('0x37')]),_0x3eb8bf['body'][_0x43bbe('0x3')]=integrations['getDescriptions'](_0x3eb8bf[_0x43bbe('0x3c')][_0x43bbe('0x9')],_0x3eb8bf['body'][_0x43bbe('0x37')]),db['FreshdeskConfiguration']['create'](_0x3eb8bf[_0x43bbe('0x3c')],{'include':[{'model':db[_0x43bbe('0x16')],'as':_0x43bbe('0x3d')},{'model':db['FreshdeskField'],'as':'Descriptions'}]});return null;})[_0x5ed1bc('0x38')](respondWithResult(_0x1a0f11,null))[_0x5ed1bc('0x4f')](handleError(_0x1a0f11,null));},exports[_0x2206f2('0x4c')]=function(_0x111e6e,_0x193ee9){const _0x40499a=_0x2206f2;let _0x3775be='';return db[_0x40499a('0x14')][_0x40499a('0x6')]({'where':{'id':_0x111e6e[_0x40499a('0x15')]['id']},'attributes':['id',_0x40499a('0x2c'),_0x40499a('0x2a')]})[_0x40499a('0x38')](handleEntityNotFound(_0x193ee9,null))['then'](function(_0x1058c1){const _0x4f71ad=_0x40499a;if(_0x1058c1){_0x3775be=_0x1058c1['remoteUri'];const _0x31b2cc=_0x3775be[_0x4f71ad('0x51')](-0x1);return _0x31b2cc==='/'&&(_0x3775be=_0x3775be[_0x4f71ad('0x25')](0x0,_0x3775be[_0x4f71ad('0x10')](_0x31b2cc))),rp({'method':'GET','uri':util[_0x4f71ad('0x53')](_0x4f71ad('0x2b'),_0x3775be,_0x4f71ad('0x11')),'headers':{'Authorization':util[_0x4f71ad('0x53')](_0x4f71ad('0x43'),Buffer['from'](util[_0x4f71ad('0x53')](_0x4f71ad('0x58'),_0x1058c1[_0x4f71ad('0x2a')]))[_0x4f71ad('0x2e')]('base64'))},'json':!![]});}})[_0x40499a('0x38')](function(_0xb6f4cf){const _0x4b0805=_0x40499a;if(_0xb6f4cf){const _0x181128=[_0x4b0805('0x39'),'subject',_0x4b0805('0x28'),_0x4b0805('0x48'),_0x4b0805('0x0'),'priority','group','source',_0x4b0805('0x2f'),_0x4b0805('0xf'),'company'];return _[_0x4b0805('0x3a')](_0xb6f4cf,function(_0x157a00){const _0x1c4d13=_0x4b0805;return _0x181128['includes'](_0x157a00[_0x1c4d13('0x56')])||!_0x157a00['default']&&_0x157a00[_0x1c4d13('0x37')]!==_0x1c4d13('0x1c')&&_0x157a00[_0x1c4d13('0x37')]!=='custom_dropdown';}),{'count':_0xb6f4cf[_0x4b0805('0x23')],'rows':_[_0x4b0805('0x1b')](_0xb6f4cf,function(_0x298719){const _0xd50ea1=_0x4b0805;return{'id':_0x298719[_0xd50ea1('0x56')],'name':_0x298719['label'],'custom':!_0x298719[_0xd50ea1('0x1e')],'options':_0x298719[_0xd50ea1('0x1f')]?_[_0xd50ea1('0x1b')](_0x298719[_0xd50ea1('0x1f')],function(_0x49884e){const _0xf669aa=_0xd50ea1;return{'name':_[_0xf669aa('0x42')](_0x49884e),'value':_0x49884e};}):[]};})};}})[_0x40499a('0x38')](respondWithResult(_0x193ee9,null))[_0x40499a('0x4f')](function(_0x45e46c){const _0xd1af9c=_0x40499a;let _0x134a1f=_0x111e6e[_0xd1af9c('0x27')][_0xd1af9c('0x32')]?0x1f4:_0x45e46c[_0xd1af9c('0x21')]||0x1f4;logger['error']('getFields,\x20%s,\x20%s,\x20%s',_0xd1af9c('0x4c'),_0x134a1f,JSON[_0xd1af9c('0x34')](_0x45e46c)),delete _0x45e46c[_0xd1af9c('0x56')],_0x134a1f===0x191&&(_0x134a1f=0x190),_0x193ee9[_0xd1af9c('0x0')](_0x134a1f)['send'](_0x111e6e['query']['test']?{'message':_0xd1af9c('0x45'),'statusCode':_0x45e46c['statusCode']}:_0x45e46c);});}; \ No newline at end of file +const a255_0x3ebb=['api/v2/ticket_fields','AccountId','filters','source','Wrong\x20credentials','FreshdeskConfiguration','show','label','channel','filter','length','order','rawAttributes','../../components/integrations/configuration','apiKey','catch','Basic\x20%s','VIRTUAL','custom_dropdown','subject','nolimit','include','../../components/parsers/qs','choices','getConfigurations','getSubjects','status','index','description','sort','body','attributes','api','statusCode','request-promise-native','type','includes','offset','FreshdeskField','includeAll','name','query','capitalize','error','test','findOne','remove','format','where','key','stack','rows','limit','create','intersection','like','getFields','sendStatus','../../config/logger','FreshdeskAccount','params','Content-Range','destroy','keys','Descriptions','json','pick','fieldName','fields','set','ticket_type','toString','base64','Subjects','../../mysqldb','send','getFields,\x20%s,\x20%s,\x20%s','stringify','requester','update','model','merge','undefined','util','options','GET','getDescriptions','default','lastIndexOf','end','count','then','map','group'];(function(_0x4546ce,_0x3ebbdd){const _0xc7e2e3=function(_0x45365c){while(--_0x45365c){_0x4546ce['push'](_0x4546ce['shift']());}};_0xc7e2e3(++_0x3ebbdd);}(a255_0x3ebb,0xfb));const a255_0xc7e2=function(_0x4546ce,_0x3ebbdd){_0x4546ce=_0x4546ce-0x0;let _0xc7e2e3=a255_0x3ebb[_0x4546ce];return _0xc7e2e3;};const _0x454cea=a255_0xc7e2;'use strict';const rp=require(_0x454cea('0x41')),util=require(_0x454cea('0x14')),_=require('lodash'),qs=require(_0x454cea('0x35')),logger=require(_0x454cea('0x59'))(_0x454cea('0x3f')),db=require(_0x454cea('0xb'))['db'],{Op}=require('sequelize'),integrations=require(_0x454cea('0x2c'));function respondWithResult(_0x45365c,_0xa62e06){return _0xa62e06=_0xa62e06||0xc8,function(_0x2e718f){const _0x5a2ed4=a255_0xc7e2;if(_0x2e718f)return _0x45365c['status'](_0xa62e06)[_0x5a2ed4('0x2')](_0x2e718f);};}function respondWithFilteredResult(_0x3e90af,_0x25eed6){return function(_0x1e7c67){const _0xbcca26=a255_0xc7e2;if(_0x1e7c67){const _0x2ad7a3=_0x1e7c67[_0xbcca26('0x1b')],_0x2db582=_0x25eed6[_0xbcca26('0x44')];let _0x3d91e1=_0x25eed6['offset']+_0x25eed6[_0xbcca26('0x53')],_0x20919d;return _0x3d91e1>=_0x2ad7a3?(_0x3d91e1=_0x2ad7a3,_0x20919d=0xc8):_0x20919d=0xce,_0x3e90af['status'](_0x20919d),_0x3e90af[_0xbcca26('0x6')](_0xbcca26('0x5c'),_0x2db582+'-'+_0x3d91e1+'/'+_0x2ad7a3)[_0xbcca26('0x2')](_0x1e7c67);}return null;};}function saveUpdates(_0x22ef96){return function(_0x7808a5){const _0x341b42=a255_0xc7e2;if(_0x7808a5)return _0x7808a5[_0x341b42('0x10')](_0x22ef96)[_0x341b42('0x1c')](function(_0x5a653b){return _0x5a653b;});return null;};}function removeEntity(_0xf2259f){return function(_0x10f618){const _0x321dc2=a255_0xc7e2;if(_0x10f618)return _0x10f618[_0x321dc2('0x5d')]()[_0x321dc2('0x1c')](function(){const _0x2e8330=_0x321dc2;_0xf2259f[_0x2e8330('0x39')](0xcc)[_0x2e8330('0x1a')]();});};}function handleEntityNotFound(_0x593332){return function(_0x509d0c){const _0x58aa67=a255_0xc7e2;return!_0x509d0c&&_0x593332[_0x58aa67('0x58')](0x194),_0x509d0c;};}function handleError(_0x11f9fb,_0x45bf91){return _0x45bf91=_0x45bf91||0x1f4,function(_0x39b752){const _0x141e0c=a255_0xc7e2;logger['error'](_0x39b752[_0x141e0c('0x51')]),_0x39b752[_0x141e0c('0x47')]&&delete _0x39b752[_0x141e0c('0x47')],_0x11f9fb[_0x141e0c('0x39')](_0x45bf91)[_0x141e0c('0xc')](_0x39b752);};}exports[_0x454cea('0x3a')]=function(_0x5042dd,_0xcf5ac){const _0x2a81ca=_0x454cea;let _0x22a627={};const _0x20407b={},_0x4e133d={'count':0x0,'rows':[]},_0x18ba5a=_[_0x2a81ca('0x1d')](db[_0x2a81ca('0x5a')]['rawAttributes'],function(_0x2e962c){const _0x5ac1ac=_0x2a81ca;return{'name':_0x2e962c[_0x5ac1ac('0x4')],'type':_0x2e962c[_0x5ac1ac('0x42')][_0x5ac1ac('0x50')]};});_0x20407b[_0x2a81ca('0x11')]=_[_0x2a81ca('0x1d')](_0x18ba5a,_0x2a81ca('0x47')),_0x20407b[_0x2a81ca('0x48')]=_['keys'](_0x5042dd[_0x2a81ca('0x48')]),_0x20407b[_0x2a81ca('0x21')]=_[_0x2a81ca('0x55')](_0x20407b['model'],_0x20407b['query']),_0x22a627[_0x2a81ca('0x3e')]=_[_0x2a81ca('0x55')](_0x20407b[_0x2a81ca('0x11')],qs[_0x2a81ca('0x5')](_0x5042dd[_0x2a81ca('0x48')][_0x2a81ca('0x5')])),_0x22a627[_0x2a81ca('0x3e')]=_0x22a627[_0x2a81ca('0x3e')][_0x2a81ca('0x29')]?_0x22a627[_0x2a81ca('0x3e')]:_0x20407b['model'];typeof _0x5042dd[_0x2a81ca('0x48')][_0x2a81ca('0x33')]===_0x2a81ca('0x13')&&(_0x22a627[_0x2a81ca('0x53')]=qs[_0x2a81ca('0x53')](_0x5042dd[_0x2a81ca('0x48')][_0x2a81ca('0x53')]),_0x22a627[_0x2a81ca('0x44')]=qs['offset'](_0x5042dd[_0x2a81ca('0x48')]['offset']));_0x22a627[_0x2a81ca('0x2a')]=qs[_0x2a81ca('0x3c')](_0x5042dd['query'][_0x2a81ca('0x3c')]),_0x22a627[_0x2a81ca('0x4f')]=qs[_0x2a81ca('0x21')](_['pick'](_0x5042dd[_0x2a81ca('0x48')],_0x20407b[_0x2a81ca('0x21')]),_0x18ba5a);_0x5042dd['query']['filter']&&(_0x22a627[_0x2a81ca('0x4f')]=_[_0x2a81ca('0x12')](_0x22a627[_0x2a81ca('0x4f')],{[Op['or']]:_['map'](_0x18ba5a,function(_0x39e5da){const _0x46194f=_0x2a81ca;if(_0x39e5da[_0x46194f('0x42')]!==_0x46194f('0x30')){const _0x3f1840={};return _0x3f1840[_0x39e5da['name']]={[Op[_0x46194f('0x56')]]:'%'+_0x5042dd[_0x46194f('0x48')]['filter']+'%'},_0x3f1840;}})}));_0x22a627=_[_0x2a81ca('0x12')]({},_0x22a627,_0x5042dd[_0x2a81ca('0x15')]);const _0x74046e={'where':_0x22a627[_0x2a81ca('0x4f')]};return db['FreshdeskAccount']['count'](_0x74046e)[_0x2a81ca('0x1c')](function(_0x280b34){const _0x293fb9=_0x2a81ca;return _0x4e133d[_0x293fb9('0x1b')]=_0x280b34,_0x5042dd[_0x293fb9('0x48')][_0x293fb9('0x46')]&&(_0x22a627[_0x293fb9('0x34')]=[{'all':!![]}]),db[_0x293fb9('0x5a')]['findAll'](_0x22a627);})['then'](function(_0x1803c6){const _0x26911d=_0x2a81ca;return _0x4e133d[_0x26911d('0x52')]=_0x1803c6,_0x4e133d;})[_0x2a81ca('0x1c')](respondWithFilteredResult(_0xcf5ac,_0x22a627))['catch'](handleError(_0xcf5ac,null));},exports[_0x454cea('0x25')]=function(_0x4a964e,_0xa7b01a){const _0x552bee=_0x454cea;let _0x15ba9c={'raw':![],'where':{'id':_0x4a964e['params']['id']}};const _0x55b717={};return _0x55b717[_0x552bee('0x11')]=_['keys'](db[_0x552bee('0x5a')][_0x552bee('0x2b')]),_0x55b717[_0x552bee('0x48')]=_[_0x552bee('0x0')](_0x4a964e[_0x552bee('0x48')]),_0x55b717[_0x552bee('0x21')]=_[_0x552bee('0x55')](_0x55b717[_0x552bee('0x11')],_0x55b717[_0x552bee('0x48')]),_0x15ba9c['attributes']=_[_0x552bee('0x55')](_0x55b717[_0x552bee('0x11')],qs[_0x552bee('0x5')](_0x4a964e[_0x552bee('0x48')][_0x552bee('0x5')])),_0x15ba9c[_0x552bee('0x3e')]=_0x15ba9c[_0x552bee('0x3e')][_0x552bee('0x29')]?_0x15ba9c[_0x552bee('0x3e')]:_0x55b717[_0x552bee('0x11')],_0x4a964e['query'][_0x552bee('0x46')]&&(_0x15ba9c[_0x552bee('0x34')]=[{'all':!![]}]),_0x15ba9c=_[_0x552bee('0x12')]({},_0x15ba9c,_0x4a964e[_0x552bee('0x15')]),db[_0x552bee('0x5a')][_0x552bee('0x4c')](_0x15ba9c)[_0x552bee('0x1c')](handleEntityNotFound(_0xa7b01a,null))[_0x552bee('0x1c')](respondWithResult(_0xa7b01a,null))[_0x552bee('0x2e')](handleError(_0xa7b01a,null));},exports[_0x454cea('0x54')]=function(_0x4e16b0,_0x4db667){const _0x952d1a=_0x454cea;return db['FreshdeskAccount'][_0x952d1a('0x54')](_0x4e16b0['body'],{})[_0x952d1a('0x1c')](respondWithResult(_0x4db667,0xc9))[_0x952d1a('0x2e')](handleError(_0x4db667,null));},exports['update']=function(_0x18be4b,_0xc7178b){const _0x253ecc=_0x454cea;return _0x18be4b[_0x253ecc('0x3d')]['id']&&delete _0x18be4b[_0x253ecc('0x3d')]['id'],db['FreshdeskAccount'][_0x253ecc('0x4c')]({'where':{'id':_0x18be4b[_0x253ecc('0x5b')]['id']}})[_0x253ecc('0x1c')](handleEntityNotFound(_0xc7178b,null))[_0x253ecc('0x1c')](saveUpdates(_0x18be4b[_0x253ecc('0x3d')],null))[_0x253ecc('0x1c')](respondWithResult(_0xc7178b,null))[_0x253ecc('0x2e')](handleError(_0xc7178b,null));},exports[_0x454cea('0x5d')]=function(_0x27293c,_0x106c6e){const _0x293f45=_0x454cea;return db[_0x293f45('0x5a')][_0x293f45('0x4c')]({'where':{'id':_0x27293c[_0x293f45('0x5b')]['id']}})[_0x293f45('0x1c')](handleEntityNotFound(_0x106c6e,null))[_0x293f45('0x1c')](removeEntity(_0x106c6e,null))['catch'](handleError(_0x106c6e,null));},exports[_0x454cea('0x37')]=function(_0x5bf55a,_0x167dde){const _0x1ffe55=_0x454cea;let _0x430cf6={};const _0x23eb56={};let _0x4732de,_0x4bf9fe;return db[_0x1ffe55('0x5a')][_0x1ffe55('0x4c')]({'where':{'id':_0x5bf55a[_0x1ffe55('0x5b')]['id']}})['then'](handleEntityNotFound(_0x167dde,null))['then'](function(_0x44147e){const _0x4344d9=_0x1ffe55;if(_0x44147e)return _0x4732de=_0x44147e,_0x23eb56[_0x4344d9('0x11')]=_[_0x4344d9('0x0')](db['FreshdeskConfiguration'][_0x4344d9('0x2b')]),_0x23eb56[_0x4344d9('0x48')]=_[_0x4344d9('0x0')](_0x5bf55a['query']),_0x23eb56[_0x4344d9('0x21')]=_[_0x4344d9('0x55')](_0x23eb56['model'],_0x23eb56[_0x4344d9('0x48')]),_0x430cf6[_0x4344d9('0x3e')]=_[_0x4344d9('0x55')](_0x23eb56[_0x4344d9('0x11')],qs[_0x4344d9('0x5')](_0x5bf55a[_0x4344d9('0x48')]['fields'])),_0x430cf6[_0x4344d9('0x3e')]=_0x430cf6['attributes'][_0x4344d9('0x29')]?_0x430cf6[_0x4344d9('0x3e')]:_0x23eb56[_0x4344d9('0x11')],_0x430cf6[_0x4344d9('0x2a')]=qs[_0x4344d9('0x3c')](_0x5bf55a[_0x4344d9('0x48')]['sort']),_0x430cf6[_0x4344d9('0x4f')]=qs[_0x4344d9('0x21')](_[_0x4344d9('0x3')](_0x5bf55a[_0x4344d9('0x48')],_0x23eb56[_0x4344d9('0x21')])),_0x5bf55a[_0x4344d9('0x48')][_0x4344d9('0x28')]&&(_0x430cf6[_0x4344d9('0x4f')]=_['merge'](_0x430cf6['where'],{[Op['or']]:_['map'](_0x430cf6[_0x4344d9('0x3e')],function(_0x59cc2d){const _0x290b54=_0x4344d9,_0x2337a3={};return _0x2337a3[_0x59cc2d]={[Op[_0x290b54('0x56')]]:'%'+_0x5bf55a[_0x290b54('0x48')][_0x290b54('0x28')]+'%'},_0x2337a3;})})),_0x430cf6=_[_0x4344d9('0x12')]({},_0x430cf6,_0x5bf55a['options']),_0x4732de[_0x4344d9('0x37')](_0x430cf6);})[_0x1ffe55('0x1c')](function(_0x51dd26){const _0x4946e9=_0x1ffe55;if(_0x51dd26)return _0x4bf9fe=_0x51dd26[_0x4946e9('0x29')],typeof _0x5bf55a[_0x4946e9('0x48')][_0x4946e9('0x33')]===_0x4946e9('0x13')&&(_0x430cf6[_0x4946e9('0x53')]=qs['limit'](_0x5bf55a[_0x4946e9('0x48')][_0x4946e9('0x53')]),_0x430cf6['offset']=qs[_0x4946e9('0x44')](_0x5bf55a[_0x4946e9('0x48')][_0x4946e9('0x44')])),_0x4732de[_0x4946e9('0x37')](_0x430cf6);})[_0x1ffe55('0x1c')](function(_0x2bc689){if(_0x2bc689)return _0x2bc689?{'count':_0x4bf9fe,'rows':_0x2bc689}:null;})['then'](respondWithResult(_0x167dde,null))[_0x1ffe55('0x2e')](handleError(_0x167dde,null));},exports['addConfiguration']=function(_0x288529,_0x2a6ca7){const _0x1aa371=_0x454cea;return _0x288529[_0x1aa371('0x3d')]['id']&&delete _0x288529[_0x1aa371('0x3d')]['id'],db['FreshdeskAccount'][_0x1aa371('0x4c')]({'where':{'id':_0x288529[_0x1aa371('0x5b')]['id']}})[_0x1aa371('0x1c')](handleEntityNotFound(_0x2a6ca7,null))[_0x1aa371('0x1c')](function(_0x19a2df){const _0x2a3122=_0x1aa371;if(_0x19a2df)return _0x288529[_0x2a3122('0x3d')][_0x2a3122('0x20')]=_0x19a2df['id'],_0x288529[_0x2a3122('0x3d')][_0x2a3122('0xa')]=integrations[_0x2a3122('0x38')](_0x288529[_0x2a3122('0x3d')][_0x2a3122('0x27')],_0x288529[_0x2a3122('0x3d')][_0x2a3122('0x42')]),_0x288529[_0x2a3122('0x3d')]['Descriptions']=integrations[_0x2a3122('0x17')](_0x288529['body'][_0x2a3122('0x27')],_0x288529['body'][_0x2a3122('0x42')]),db[_0x2a3122('0x24')][_0x2a3122('0x54')](_0x288529[_0x2a3122('0x3d')],{'include':[{'model':db[_0x2a3122('0x45')],'as':_0x2a3122('0xa')},{'model':db['FreshdeskField'],'as':_0x2a3122('0x1')}]});return null;})[_0x1aa371('0x1c')](respondWithResult(_0x2a6ca7,null))['catch'](handleError(_0x2a6ca7,null));},exports[_0x454cea('0x57')]=function(_0x2b1cf0,_0x570446){const _0x200738=_0x454cea;let _0x219f72='';return db[_0x200738('0x5a')]['findOne']({'where':{'id':_0x2b1cf0[_0x200738('0x5b')]['id']},'attributes':['id','remoteUri',_0x200738('0x2d')]})[_0x200738('0x1c')](handleEntityNotFound(_0x570446,null))[_0x200738('0x1c')](function(_0x24afa4){const _0x4b20a6=_0x200738;if(_0x24afa4){_0x219f72=_0x24afa4['remoteUri'];const _0x36e4e3=_0x219f72['slice'](-0x1);return _0x36e4e3==='/'&&(_0x219f72=_0x219f72['substring'](0x0,_0x219f72[_0x4b20a6('0x19')](_0x36e4e3))),rp({'method':_0x4b20a6('0x16'),'uri':util[_0x4b20a6('0x4e')]('%s/%s',_0x219f72,_0x4b20a6('0x1f')),'headers':{'Authorization':util['format'](_0x4b20a6('0x2f'),Buffer['from'](util[_0x4b20a6('0x4e')]('%s:X',_0x24afa4[_0x4b20a6('0x2d')]))[_0x4b20a6('0x8')](_0x4b20a6('0x9')))},'json':!![]});}})[_0x200738('0x1c')](function(_0x30058a){const _0x1896be=_0x200738;if(_0x30058a){const _0x580b72=[_0x1896be('0xf'),_0x1896be('0x32'),'agent',_0x1896be('0x3b'),_0x1896be('0x39'),'priority','group',_0x1896be('0x22'),_0x1896be('0x7'),_0x1896be('0x1e'),'company'];return _[_0x1896be('0x4d')](_0x30058a,function(_0x3e6bb0){const _0x3ab191=_0x1896be;return _0x580b72[_0x3ab191('0x43')](_0x3e6bb0[_0x3ab191('0x47')])||!_0x3e6bb0[_0x3ab191('0x18')]&&_0x3e6bb0[_0x3ab191('0x42')]!=='custom_text'&&_0x3e6bb0['type']!==_0x3ab191('0x31');}),{'count':_0x30058a[_0x1896be('0x29')],'rows':_[_0x1896be('0x1d')](_0x30058a,function(_0x1db726){const _0x3cb433=_0x1896be;return{'id':_0x1db726[_0x3cb433('0x47')],'name':_0x1db726[_0x3cb433('0x26')],'custom':!_0x1db726[_0x3cb433('0x18')],'options':_0x1db726['choices']?_[_0x3cb433('0x1d')](_0x1db726[_0x3cb433('0x36')],function(_0xb066ac){const _0x16d734=_0x3cb433;return{'name':_[_0x16d734('0x49')](_0xb066ac),'value':_0xb066ac};}):[]};})};}})['then'](respondWithResult(_0x570446,null))[_0x200738('0x2e')](function(_0x53f7a6){const _0x223410=_0x200738;let _0x38b7c3=_0x2b1cf0[_0x223410('0x48')][_0x223410('0x4b')]?0x1f4:_0x53f7a6['statusCode']||0x1f4;logger[_0x223410('0x4a')](_0x223410('0xd'),_0x223410('0x57'),_0x38b7c3,JSON[_0x223410('0xe')](_0x53f7a6)),delete _0x53f7a6['name'],_0x38b7c3===0x191&&(_0x38b7c3=0x190),_0x570446[_0x223410('0x39')](_0x38b7c3)[_0x223410('0xc')](_0x2b1cf0['query'][_0x223410('0x4b')]?{'message':_0x223410('0x23'),'statusCode':_0x53f7a6[_0x223410('0x40')]}:_0x53f7a6);});}; \ No newline at end of file diff --git a/server/api/intFreshdeskAccount/intFreshdeskAccount.model.js b/server/api/intFreshdeskAccount/intFreshdeskAccount.model.js index 63698dc..711e732 100644 --- a/server/api/intFreshdeskAccount/intFreshdeskAccount.model.js +++ b/server/api/intFreshdeskAccount/intFreshdeskAccount.model.js @@ -1 +1 @@ -const a256_0x5b9d=['FreshdeskAccount','int_freshdesk_accounts'];(function(_0xeb2203,_0x5b9da3){const _0x25341a=function(_0x3a2ae4){while(--_0x3a2ae4){_0xeb2203['push'](_0xeb2203['shift']());}};_0x25341a(++_0x5b9da3);}(a256_0x5b9d,0xdb));const a256_0x2534=function(_0xeb2203,_0x5b9da3){_0xeb2203=_0xeb2203-0x0;let _0x25341a=a256_0x5b9d[_0xeb2203];return _0x25341a;};'use strict';const attributes=require('./intFreshdeskAccount.attributes');module['exports']=function(_0x3a2ae4){const _0x2d9aa0=a256_0x2534,_0x1e147c=_0x3a2ae4['define'](_0x2d9aa0('0x1'),attributes,{'tableName':_0x2d9aa0('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1e147c;}; \ No newline at end of file +const a256_0x2eb3=['FreshdeskAccount','define','exports'];(function(_0x24c2af,_0x2eb30f){const _0x340fea=function(_0x5906c0){while(--_0x5906c0){_0x24c2af['push'](_0x24c2af['shift']());}};_0x340fea(++_0x2eb30f);}(a256_0x2eb3,0x1f0));const a256_0x340f=function(_0x24c2af,_0x2eb30f){_0x24c2af=_0x24c2af-0x0;let _0x340fea=a256_0x2eb3[_0x24c2af];return _0x340fea;};const _0x1de551=a256_0x340f;'use strict';const attributes=require('./intFreshdeskAccount.attributes');module[_0x1de551('0x1')]=function(_0x5906c0){const _0x272e8c=_0x1de551,_0x3d8418=_0x5906c0[_0x272e8c('0x0')](_0x272e8c('0x2'),attributes,{'tableName':'int_freshdesk_accounts','paranoid':![],'indexes':[],'timestamps':!![]});return _0x3d8418;}; \ No newline at end of file diff --git a/server/api/intFreshdeskAccount/intFreshdeskAccount.rpc.js b/server/api/intFreshdeskAccount/intFreshdeskAccount.rpc.js index 78f5d27..61368a6 100644 --- a/server/api/intFreshdeskAccount/intFreshdeskAccount.rpc.js +++ b/server/api/intFreshdeskAccount/intFreshdeskAccount.rpc.js @@ -1 +1 @@ -const a257_0x2275=['GetFreshdeskAccount','then','include','lodash','findAll','attributes','options','rpc','message','../../config/logger','limit','raw','model','../../mysqldb','debug','where','findOne','FreshdeskAccount','ShowFreshdeskAccount','stringify','error','catch','map'];(function(_0x35bcbf,_0x227568){const _0x311a4e=function(_0xcf8b44){while(--_0xcf8b44){_0x35bcbf['push'](_0x35bcbf['shift']());}};_0x311a4e(++_0x227568);}(a257_0x2275,0x17d));const a257_0x311a=function(_0x35bcbf,_0x227568){_0x35bcbf=_0x35bcbf-0x0;let _0x311a4e=a257_0x2275[_0x35bcbf];return _0x311a4e;};const _0x4710d0=a257_0x311a;'use strict';const _=require(_0x4710d0('0xd')),db=require(_0x4710d0('0x0'))['db'],logger=require(_0x4710d0('0x13'))(_0x4710d0('0x11'));exports[_0x4710d0('0xa')]=function(_0xcf8b44){const _0x21703b=this;return new Promise(function(_0x5df9bc,_0x5632aa){const _0x250866=a257_0x311a;return db[_0x250866('0x4')][_0x250866('0xe')]({'raw':_0xcf8b44[_0x250866('0x10')]?_0xcf8b44[_0x250866('0x10')][_0x250866('0x15')]===undefined?!![]:![]:!![],'where':_0xcf8b44['options']?_0xcf8b44['options'][_0x250866('0x2')]||null:null,'attributes':_0xcf8b44['options']?_0xcf8b44[_0x250866('0x10')][_0x250866('0xf')]||null:null,'limit':_0xcf8b44['options']?_0xcf8b44[_0x250866('0x10')][_0x250866('0x14')]||null:null,'include':_0xcf8b44['options']?_0xcf8b44[_0x250866('0x10')][_0x250866('0xc')]?_[_0x250866('0x9')](_0xcf8b44[_0x250866('0x10')][_0x250866('0xc')],function(_0x581d77){const _0x267358=_0x250866;return{'model':db[_0x581d77[_0x267358('0x16')]],'as':_0x581d77['as'],'attributes':_0x581d77[_0x267358('0xf')],'include':_0x581d77['include']?_[_0x267358('0x9')](_0x581d77['include'],function(_0x89d1bc){const _0x5ae250=_0x267358;return{'model':db[_0x89d1bc[_0x5ae250('0x16')]],'as':_0x89d1bc['as'],'attributes':_0x89d1bc[_0x5ae250('0xf')],'include':_0x89d1bc[_0x5ae250('0xc')]?_['map'](_0x89d1bc[_0x5ae250('0xc')],function(_0xef26d1){const _0x28186e=_0x5ae250;return{'model':db[_0xef26d1[_0x28186e('0x16')]],'as':_0xef26d1['as'],'attributes':_0xef26d1['attributes']};}):[]};}):[]};}):[]:[]})[_0x250866('0xb')](function(_0x3b28b6){const _0x1c1ff2=_0x250866;logger['info'](_0x1c1ff2('0xa'),_0xcf8b44),logger[_0x1c1ff2('0x1')](_0x1c1ff2('0xa'),_0xcf8b44,JSON['stringify'](_0x3b28b6)),_0x5df9bc(_0x3b28b6);})['catch'](function(_0x544d73){const _0x53162f=_0x250866;logger[_0x53162f('0x7')](_0x53162f('0xa'),_0x544d73[_0x53162f('0x12')],_0xcf8b44),_0x5632aa(_0x21703b[_0x53162f('0x7')](0x1f4,_0x544d73['message']));});});},exports[_0x4710d0('0x5')]=function(_0x5e3147){const _0x4d1e7a=this;return new Promise(function(_0x25d8dc,_0x76b6b2){const _0x477921=a257_0x311a;return db[_0x477921('0x4')][_0x477921('0x3')]({'raw':_0x5e3147['options']?_0x5e3147['options'][_0x477921('0x15')]===undefined?!![]:![]:!![],'where':_0x5e3147[_0x477921('0x10')]?_0x5e3147['options'][_0x477921('0x2')]||null:null,'attributes':_0x5e3147[_0x477921('0x10')]?_0x5e3147['options'][_0x477921('0xf')]||null:null,'include':_0x5e3147[_0x477921('0x10')]?_0x5e3147[_0x477921('0x10')][_0x477921('0xc')]?_[_0x477921('0x9')](_0x5e3147[_0x477921('0x10')][_0x477921('0xc')],function(_0x5e892e){const _0x1b5c35=_0x477921;return{'model':db[_0x5e892e[_0x1b5c35('0x16')]],'as':_0x5e892e['as'],'attributes':_0x5e892e[_0x1b5c35('0xf')],'include':_0x5e892e[_0x1b5c35('0xc')]?_[_0x1b5c35('0x9')](_0x5e892e['include'],function(_0x2a24dc){const _0x4822f8=_0x1b5c35;return{'model':db[_0x2a24dc[_0x4822f8('0x16')]],'as':_0x2a24dc['as'],'attributes':_0x2a24dc['attributes'],'include':_0x2a24dc[_0x4822f8('0xc')]?_[_0x4822f8('0x9')](_0x2a24dc[_0x4822f8('0xc')],function(_0x577825){const _0x2142d9=_0x4822f8;return{'model':db[_0x577825[_0x2142d9('0x16')]],'as':_0x577825['as'],'attributes':_0x577825[_0x2142d9('0xf')]};}):[]};}):[]};}):[]:[]})[_0x477921('0xb')](function(_0x3c308d){const _0x134cdc=_0x477921;logger['info'](_0x134cdc('0x5'),_0x5e3147),logger[_0x134cdc('0x1')]('ShowFreshdeskAccount',_0x5e3147,JSON[_0x134cdc('0x6')](_0x3c308d)),_0x25d8dc(_0x3c308d);})[_0x477921('0x8')](function(_0xc1556){const _0x3fe54c=_0x477921;logger[_0x3fe54c('0x7')]('ShowFreshdeskAccount',_0xc1556[_0x3fe54c('0x12')],_0x5e3147),_0x76b6b2(_0x4d1e7a['error'](0x1f4,_0xc1556[_0x3fe54c('0x12')]));});});}; \ No newline at end of file +const a257_0x4c9b=['limit','raw','model','map','then','findOne','error','FreshdeskAccount','findAll','debug','options','attributes','lodash','catch','message','rpc','stringify','GetFreshdeskAccount','ShowFreshdeskAccount','include','where','info','../../config/logger'];(function(_0x5cc319,_0x4c9b5c){const _0xbbfdcc=function(_0x56f1ce){while(--_0x56f1ce){_0x5cc319['push'](_0x5cc319['shift']());}};_0xbbfdcc(++_0x4c9b5c);}(a257_0x4c9b,0x19f));const a257_0xbbfd=function(_0x5cc319,_0x4c9b5c){_0x5cc319=_0x5cc319-0x0;let _0xbbfdcc=a257_0x4c9b[_0x5cc319];return _0xbbfdcc;};const _0x461e4e=a257_0xbbfd;'use strict';const _=require(_0x461e4e('0xb')),db=require('../../mysqldb')['db'],logger=require(_0x461e4e('0x15'))(_0x461e4e('0xe'));exports[_0x461e4e('0x10')]=function(_0x56f1ce){const _0x3d6667=this;return new Promise(function(_0x3f93ea,_0x12ee52){const _0x1ade9f=a257_0xbbfd;return db[_0x1ade9f('0x6')][_0x1ade9f('0x7')]({'raw':_0x56f1ce[_0x1ade9f('0x9')]?_0x56f1ce[_0x1ade9f('0x9')]['raw']===undefined?!![]:![]:!![],'where':_0x56f1ce[_0x1ade9f('0x9')]?_0x56f1ce[_0x1ade9f('0x9')][_0x1ade9f('0x13')]||null:null,'attributes':_0x56f1ce[_0x1ade9f('0x9')]?_0x56f1ce[_0x1ade9f('0x9')]['attributes']||null:null,'limit':_0x56f1ce[_0x1ade9f('0x9')]?_0x56f1ce['options'][_0x1ade9f('0x16')]||null:null,'include':_0x56f1ce[_0x1ade9f('0x9')]?_0x56f1ce['options'][_0x1ade9f('0x12')]?_[_0x1ade9f('0x2')](_0x56f1ce[_0x1ade9f('0x9')][_0x1ade9f('0x12')],function(_0x28e4ef){const _0x4d72ba=_0x1ade9f;return{'model':db[_0x28e4ef[_0x4d72ba('0x1')]],'as':_0x28e4ef['as'],'attributes':_0x28e4ef[_0x4d72ba('0xa')],'include':_0x28e4ef[_0x4d72ba('0x12')]?_[_0x4d72ba('0x2')](_0x28e4ef[_0x4d72ba('0x12')],function(_0x54c5b2){const _0x20bf3a=_0x4d72ba;return{'model':db[_0x54c5b2[_0x20bf3a('0x1')]],'as':_0x54c5b2['as'],'attributes':_0x54c5b2[_0x20bf3a('0xa')],'include':_0x54c5b2[_0x20bf3a('0x12')]?_[_0x20bf3a('0x2')](_0x54c5b2[_0x20bf3a('0x12')],function(_0x35fa6f){const _0x2a9c59=_0x20bf3a;return{'model':db[_0x35fa6f[_0x2a9c59('0x1')]],'as':_0x35fa6f['as'],'attributes':_0x35fa6f[_0x2a9c59('0xa')]};}):[]};}):[]};}):[]:[]})[_0x1ade9f('0x3')](function(_0x1debf7){const _0x3e0a57=_0x1ade9f;logger[_0x3e0a57('0x14')](_0x3e0a57('0x10'),_0x56f1ce),logger[_0x3e0a57('0x8')]('GetFreshdeskAccount',_0x56f1ce,JSON['stringify'](_0x1debf7)),_0x3f93ea(_0x1debf7);})['catch'](function(_0x5e7852){const _0x1e14d6=_0x1ade9f;logger[_0x1e14d6('0x5')](_0x1e14d6('0x10'),_0x5e7852[_0x1e14d6('0xd')],_0x56f1ce),_0x12ee52(_0x3d6667['error'](0x1f4,_0x5e7852[_0x1e14d6('0xd')]));});});},exports[_0x461e4e('0x11')]=function(_0x2d5db4){const _0x22f91c=this;return new Promise(function(_0x42ce03,_0x2e6c3c){const _0x3081c0=a257_0xbbfd;return db[_0x3081c0('0x6')][_0x3081c0('0x4')]({'raw':_0x2d5db4[_0x3081c0('0x9')]?_0x2d5db4[_0x3081c0('0x9')][_0x3081c0('0x0')]===undefined?!![]:![]:!![],'where':_0x2d5db4['options']?_0x2d5db4[_0x3081c0('0x9')][_0x3081c0('0x13')]||null:null,'attributes':_0x2d5db4[_0x3081c0('0x9')]?_0x2d5db4[_0x3081c0('0x9')][_0x3081c0('0xa')]||null:null,'include':_0x2d5db4[_0x3081c0('0x9')]?_0x2d5db4[_0x3081c0('0x9')][_0x3081c0('0x12')]?_[_0x3081c0('0x2')](_0x2d5db4['options'][_0x3081c0('0x12')],function(_0x3a8381){const _0x16e892=_0x3081c0;return{'model':db[_0x3a8381[_0x16e892('0x1')]],'as':_0x3a8381['as'],'attributes':_0x3a8381['attributes'],'include':_0x3a8381[_0x16e892('0x12')]?_[_0x16e892('0x2')](_0x3a8381['include'],function(_0x185d6f){const _0x4f6554=_0x16e892;return{'model':db[_0x185d6f['model']],'as':_0x185d6f['as'],'attributes':_0x185d6f[_0x4f6554('0xa')],'include':_0x185d6f[_0x4f6554('0x12')]?_['map'](_0x185d6f['include'],function(_0x407299){const _0x34da75=_0x4f6554;return{'model':db[_0x407299[_0x34da75('0x1')]],'as':_0x407299['as'],'attributes':_0x407299[_0x34da75('0xa')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x5bfb78){const _0x119a70=_0x3081c0;logger['info'](_0x119a70('0x11'),_0x2d5db4),logger[_0x119a70('0x8')](_0x119a70('0x11'),_0x2d5db4,JSON[_0x119a70('0xf')](_0x5bfb78)),_0x42ce03(_0x5bfb78);})[_0x3081c0('0xc')](function(_0x40ef55){const _0x459136=_0x3081c0;logger[_0x459136('0x5')](_0x459136('0x11'),_0x40ef55[_0x459136('0xd')],_0x2d5db4),_0x2e6c3c(_0x22f91c[_0x459136('0x5')](0x1f4,_0x40ef55[_0x459136('0xd')]));});});}; \ No newline at end of file diff --git a/server/api/intFreshdeskConfiguration/index.js b/server/api/intFreshdeskConfiguration/index.js index 7fe5f5e..02856f6 100644 --- a/server/api/intFreshdeskConfiguration/index.js +++ b/server/api/intFreshdeskConfiguration/index.js @@ -1 +1 @@ -const a258_0x46ca=['show','/:id/fields','Router','delete','/:id/subjects','isAuthenticated','../../components/auth/service','/:id','exports','post','put','get','destroy','/:id/tags','getFields','getDescriptions','getSubjects'];(function(_0xd5f626,_0x46cae6){const _0x3b24e6=function(_0x487a14){while(--_0x487a14){_0xd5f626['push'](_0xd5f626['shift']());}};_0x3b24e6(++_0x46cae6);}(a258_0x46ca,0x6a));const a258_0x3b24=function(_0xd5f626,_0x46cae6){_0xd5f626=_0xd5f626-0x0;let _0x3b24e6=a258_0x46ca[_0xd5f626];return _0x3b24e6;};const _0x24c2b8=a258_0x3b24;'use strict';const express=require('express'),router=express[_0x24c2b8('0xf')](),auth=require(_0x24c2b8('0x2')),controller=require('./intFreshdeskConfiguration.controller');router[_0x24c2b8('0x7')]('/',auth[_0x24c2b8('0x1')](),controller['index']),router[_0x24c2b8('0x7')]('/:id',auth[_0x24c2b8('0x1')](),controller[_0x24c2b8('0xd')]),router[_0x24c2b8('0x7')](_0x24c2b8('0xe'),auth['isAuthenticated'](),controller[_0x24c2b8('0xa')]),router[_0x24c2b8('0x7')](_0x24c2b8('0x0'),auth[_0x24c2b8('0x1')](),controller[_0x24c2b8('0xc')]),router[_0x24c2b8('0x7')]('/:id/descriptions',auth[_0x24c2b8('0x1')](),controller[_0x24c2b8('0xb')]),router[_0x24c2b8('0x7')](_0x24c2b8('0x9'),auth[_0x24c2b8('0x1')](),controller['getTags']),router['post']('/',auth['isAuthenticated'](),controller['create']),router[_0x24c2b8('0x5')](_0x24c2b8('0x9'),auth['isAuthenticated'](),controller['setTags']),router[_0x24c2b8('0x6')](_0x24c2b8('0x3'),auth[_0x24c2b8('0x1')](),controller['update']),router[_0x24c2b8('0x10')]('/:id',auth['isAuthenticated'](),controller[_0x24c2b8('0x8')]),module[_0x24c2b8('0x4')]=router; \ No newline at end of file +const a258_0x1891=['delete','express','getFields','/:id/fields','show','/:id/descriptions','/:id/tags','./intFreshdeskConfiguration.controller','getDescriptions','isAuthenticated','post','/:id','get','exports','update','Router','../../components/auth/service','index','put'];(function(_0x21d546,_0x18912b){const _0x369be6=function(_0x238119){while(--_0x238119){_0x21d546['push'](_0x21d546['shift']());}};_0x369be6(++_0x18912b);}(a258_0x1891,0x1cf));const a258_0x369b=function(_0x21d546,_0x18912b){_0x21d546=_0x21d546-0x0;let _0x369be6=a258_0x1891[_0x21d546];return _0x369be6;};const _0x30c8af=a258_0x369b;'use strict';const express=require(_0x30c8af('0xd')),router=express[_0x30c8af('0x8')](),auth=require(_0x30c8af('0x9')),controller=require(_0x30c8af('0x0'));router['get']('/',auth[_0x30c8af('0x2')](),controller[_0x30c8af('0xa')]),router['get'](_0x30c8af('0x4'),auth[_0x30c8af('0x2')](),controller[_0x30c8af('0x10')]),router[_0x30c8af('0x5')](_0x30c8af('0xf'),auth[_0x30c8af('0x2')](),controller[_0x30c8af('0xe')]),router[_0x30c8af('0x5')]('/:id/subjects',auth[_0x30c8af('0x2')](),controller['getSubjects']),router[_0x30c8af('0x5')](_0x30c8af('0x11'),auth[_0x30c8af('0x2')](),controller[_0x30c8af('0x1')]),router[_0x30c8af('0x5')](_0x30c8af('0x12'),auth['isAuthenticated'](),controller['getTags']),router[_0x30c8af('0x3')]('/',auth[_0x30c8af('0x2')](),controller['create']),router[_0x30c8af('0x3')](_0x30c8af('0x12'),auth['isAuthenticated'](),controller['setTags']),router[_0x30c8af('0xb')](_0x30c8af('0x4'),auth['isAuthenticated'](),controller[_0x30c8af('0x7')]),router[_0x30c8af('0xc')](_0x30c8af('0x4'),auth[_0x30c8af('0x2')](),controller['destroy']),module[_0x30c8af('0x6')]=router; \ No newline at end of file diff --git a/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.attributes.js b/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.attributes.js index 7258e4b..cc5e8cb 100644 --- a/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.attributes.js +++ b/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.attributes.js @@ -1 +1 @@ -const a259_0x4410=['exports','sequelize'];(function(_0x35e2f7,_0x441070){const _0x149e9d=function(_0x356b72){while(--_0x356b72){_0x35e2f7['push'](_0x35e2f7['shift']());}};_0x149e9d(++_0x441070);}(a259_0x4410,0x186));const a259_0x149e=function(_0x35e2f7,_0x441070){_0x35e2f7=_0x35e2f7-0x0;let _0x149e9d=a259_0x4410[_0x35e2f7];return _0x149e9d;};const _0x642d47=a259_0x149e;'use strict';const Sequelize=require(_0x642d47('0x1'));module[_0x642d47('0x0')]={'name':{'type':Sequelize['STRING']},'description':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a259_0x414a=['sequelize','STRING','exports'];(function(_0x42fdad,_0x414a6f){const _0x5cd271=function(_0x353557){while(--_0x353557){_0x42fdad['push'](_0x42fdad['shift']());}};_0x5cd271(++_0x414a6f);}(a259_0x414a,0x1ba));const a259_0x5cd2=function(_0x42fdad,_0x414a6f){_0x42fdad=_0x42fdad-0x0;let _0x5cd271=a259_0x414a[_0x42fdad];return _0x5cd271;};const _0x29c52e=a259_0x5cd2;'use strict';const Sequelize=require(_0x29c52e('0x2'));module[_0x29c52e('0x1')]={'name':{'type':Sequelize[_0x29c52e('0x0')]},'description':{'type':Sequelize[_0x29c52e('0x0')]}}; \ No newline at end of file diff --git a/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.controller.js b/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.controller.js index 603ed3c..7e36a26 100644 --- a/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.controller.js +++ b/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.controller.js @@ -1 +1 @@ -const a260_0x4006=['map','fieldName','body','getSubjects','undefined','index','attributes','where','query','stack','../../components/parsers/qs','findOne','keys','rows','sort','then','setTags','VIRTUAL','json','getDescriptions','nolimit','set','rawAttributes','filters','catch','include','error','getFields','options','model','findAll','params','order','key','create','sendStatus','destroy','intersection','end','like','merge','count','fields','FreshdeskField','offset','pick','length','../../config/logger','name','includeAll','limit','update','type','status','ids','sequelize','FreshdeskConfiguration','getTags','show','filter'];(function(_0x53f275,_0x40066e){const _0x332bad=function(_0x12a3cf){while(--_0x12a3cf){_0x53f275['push'](_0x53f275['shift']());}};_0x332bad(++_0x40066e);}(a260_0x4006,0xaa));const a260_0x332b=function(_0x53f275,_0x40066e){_0x53f275=_0x53f275-0x0;let _0x332bad=a260_0x4006[_0x53f275];return _0x332bad;};const _0xca723c=a260_0x332b;'use strict';const _=require('lodash'),qs=require(_0xca723c('0x14')),logger=require(_0xca723c('0x39'))('api'),db=require('../../mysqldb')['db'],{Op}=require(_0xca723c('0x5'));function respondWithResult(_0x12a3cf,_0x41dd4f){return _0x41dd4f=_0x41dd4f||0xc8,function(_0x59a1cd){if(_0x59a1cd)return _0x12a3cf['status'](_0x41dd4f)['json'](_0x59a1cd);};}function respondWithFilteredResult(_0x5eb44b,_0x3f4bc3){return function(_0x2181a8){const _0x5b259a=a260_0x332b;if(_0x2181a8){const _0x1e4731=_0x2181a8['count'],_0x161062=_0x3f4bc3[_0x5b259a('0x36')];let _0x55e558=_0x3f4bc3[_0x5b259a('0x36')]+_0x3f4bc3[_0x5b259a('0x0')],_0x5877f9;return _0x55e558>=_0x1e4731?(_0x55e558=_0x1e4731,_0x5877f9=0xc8):_0x5877f9=0xce,_0x5eb44b[_0x5b259a('0x3')](_0x5877f9),_0x5eb44b[_0x5b259a('0x1f')]('Content-Range',_0x161062+'-'+_0x55e558+'/'+_0x1e4731)[_0x5b259a('0x1c')](_0x2181a8);}return null;};}function saveUpdates(_0x20cb2b){return function(_0x4fabfe){const _0x3f8b26=a260_0x332b;if(_0x4fabfe)return _0x4fabfe[_0x3f8b26('0x1')](_0x20cb2b)['then'](function(_0x1149ab){return _0x1149ab;});return null;};}function removeEntity(_0x5732c4){return function(_0x5e8099){if(_0x5e8099)return _0x5e8099['destroy']()['then'](function(){const _0x53f5ee=a260_0x332b;_0x5732c4[_0x53f5ee('0x3')](0xcc)[_0x53f5ee('0x30')]();});};}function handleEntityNotFound(_0x5b5381){return function(_0x1cdbf9){const _0xf7aa6f=a260_0x332b;return!_0x1cdbf9&&_0x5b5381[_0xf7aa6f('0x2d')](0x194),_0x1cdbf9;};}function handleError(_0x2c3b92,_0x2f6837){return _0x2f6837=_0x2f6837||0x1f4,function(_0x1f76a1){const _0x10d537=a260_0x332b;logger[_0x10d537('0x24')](_0x1f76a1[_0x10d537('0x13')]),_0x1f76a1['name']&&delete _0x1f76a1[_0x10d537('0x3a')],_0x2c3b92[_0x10d537('0x3')](_0x2f6837)['send'](_0x1f76a1);};}exports[_0xca723c('0xf')]=function(_0x5e30d7,_0x1a1f80){const _0x1e92f1=_0xca723c;let _0x3a4e0a={};const _0xb72532={},_0x5c9df1={'count':0x0,'rows':[]},_0x5bbee2=_[_0x1e92f1('0xa')](db[_0x1e92f1('0x6')][_0x1e92f1('0x20')],function(_0x3ab9f0){const _0x5875eb=_0x1e92f1;return{'name':_0x3ab9f0[_0x5875eb('0xb')],'type':_0x3ab9f0[_0x5875eb('0x2')][_0x5875eb('0x2b')]};});_0xb72532[_0x1e92f1('0x27')]=_[_0x1e92f1('0xa')](_0x5bbee2,_0x1e92f1('0x3a')),_0xb72532[_0x1e92f1('0x12')]=_[_0x1e92f1('0x16')](_0x5e30d7[_0x1e92f1('0x12')]),_0xb72532[_0x1e92f1('0x21')]=_[_0x1e92f1('0x2f')](_0xb72532[_0x1e92f1('0x27')],_0xb72532[_0x1e92f1('0x12')]),_0x3a4e0a['attributes']=_[_0x1e92f1('0x2f')](_0xb72532[_0x1e92f1('0x27')],qs[_0x1e92f1('0x34')](_0x5e30d7[_0x1e92f1('0x12')][_0x1e92f1('0x34')])),_0x3a4e0a[_0x1e92f1('0x10')]=_0x3a4e0a[_0x1e92f1('0x10')]['length']?_0x3a4e0a[_0x1e92f1('0x10')]:_0xb72532[_0x1e92f1('0x27')];typeof _0x5e30d7[_0x1e92f1('0x12')]['nolimit']===_0x1e92f1('0xe')&&(_0x3a4e0a['limit']=qs[_0x1e92f1('0x0')](_0x5e30d7['query'][_0x1e92f1('0x0')]),_0x3a4e0a['offset']=qs[_0x1e92f1('0x36')](_0x5e30d7[_0x1e92f1('0x12')][_0x1e92f1('0x36')]));_0x3a4e0a[_0x1e92f1('0x2a')]=qs[_0x1e92f1('0x18')](_0x5e30d7[_0x1e92f1('0x12')][_0x1e92f1('0x18')]),_0x3a4e0a[_0x1e92f1('0x11')]=qs[_0x1e92f1('0x21')](_[_0x1e92f1('0x37')](_0x5e30d7[_0x1e92f1('0x12')],_0xb72532[_0x1e92f1('0x21')]),_0x5bbee2);_0x5e30d7[_0x1e92f1('0x12')][_0x1e92f1('0x9')]&&(_0x3a4e0a[_0x1e92f1('0x11')]=_[_0x1e92f1('0x32')](_0x3a4e0a[_0x1e92f1('0x11')],{[Op['or']]:_[_0x1e92f1('0xa')](_0x5bbee2,function(_0x59fa4d){const _0x528c0b=_0x1e92f1;if(_0x59fa4d[_0x528c0b('0x2')]!==_0x528c0b('0x1b')){const _0x31a346={};return _0x31a346[_0x59fa4d['name']]={[Op['like']]:'%'+_0x5e30d7[_0x528c0b('0x12')][_0x528c0b('0x9')]+'%'},_0x31a346;}})}));_0x3a4e0a=_[_0x1e92f1('0x32')]({},_0x3a4e0a,_0x5e30d7[_0x1e92f1('0x26')]);const _0x3a1c67={'where':_0x3a4e0a[_0x1e92f1('0x11')]};return db[_0x1e92f1('0x6')][_0x1e92f1('0x33')](_0x3a1c67)[_0x1e92f1('0x19')](function(_0x248a86){const _0x5237ba=_0x1e92f1;return _0x5c9df1[_0x5237ba('0x33')]=_0x248a86,_0x5e30d7[_0x5237ba('0x12')][_0x5237ba('0x3b')]&&(_0x3a4e0a['include']=[{'all':!![]}]),db[_0x5237ba('0x6')][_0x5237ba('0x28')](_0x3a4e0a);})['then'](function(_0x4655b6){const _0x4032bd=_0x1e92f1;return _0x5c9df1[_0x4032bd('0x17')]=_0x4655b6,_0x5c9df1;})[_0x1e92f1('0x19')](respondWithFilteredResult(_0x1a1f80,_0x3a4e0a))[_0x1e92f1('0x22')](handleError(_0x1a1f80,null));},exports[_0xca723c('0x8')]=function(_0x548e9c,_0x48a173){const _0x5cb106=_0xca723c;let _0x48dac1={'raw':![],'where':{'id':_0x548e9c[_0x5cb106('0x29')]['id']}};const _0x4cb81a={};return _0x4cb81a[_0x5cb106('0x27')]=_[_0x5cb106('0x16')](db[_0x5cb106('0x6')]['rawAttributes']),_0x4cb81a['query']=_[_0x5cb106('0x16')](_0x548e9c['query']),_0x4cb81a[_0x5cb106('0x21')]=_[_0x5cb106('0x2f')](_0x4cb81a['model'],_0x4cb81a[_0x5cb106('0x12')]),_0x48dac1[_0x5cb106('0x10')]=_[_0x5cb106('0x2f')](_0x4cb81a['model'],qs['fields'](_0x548e9c['query']['fields'])),_0x48dac1[_0x5cb106('0x10')]=_0x48dac1['attributes']['length']?_0x48dac1[_0x5cb106('0x10')]:_0x4cb81a[_0x5cb106('0x27')],_0x548e9c['query'][_0x5cb106('0x3b')]&&(_0x48dac1[_0x5cb106('0x23')]=[{'all':!![]}]),_0x48dac1=_[_0x5cb106('0x32')]({},_0x48dac1,_0x548e9c['options']),db[_0x5cb106('0x6')]['findOne'](_0x48dac1)[_0x5cb106('0x19')](handleEntityNotFound(_0x48a173,null))['then'](respondWithResult(_0x48a173,null))['catch'](handleError(_0x48a173,null));},exports[_0xca723c('0x2c')]=function(_0x2dfd82,_0xed666b){const _0x88780f=_0xca723c;return db[_0x88780f('0x6')][_0x88780f('0x2c')](_0x2dfd82[_0x88780f('0xc')],{})[_0x88780f('0x19')](respondWithResult(_0xed666b,0xc9))[_0x88780f('0x22')](handleError(_0xed666b,null));},exports[_0xca723c('0x1')]=function(_0x5cbf45,_0x320aa5){const _0x1c6b29=_0xca723c;return _0x5cbf45['body']['id']&&delete _0x5cbf45[_0x1c6b29('0xc')]['id'],db['FreshdeskConfiguration']['findOne']({'where':{'id':_0x5cbf45[_0x1c6b29('0x29')]['id']}})['then'](handleEntityNotFound(_0x320aa5,null))['then'](saveUpdates(_0x5cbf45['body'],null))[_0x1c6b29('0x19')](respondWithResult(_0x320aa5,null))['catch'](handleError(_0x320aa5,null));},exports[_0xca723c('0x2e')]=function(_0x5bbfea,_0x5fce2f){const _0x3d6348=_0xca723c;return db[_0x3d6348('0x6')]['findOne']({'where':{'id':_0x5bbfea[_0x3d6348('0x29')]['id']}})[_0x3d6348('0x19')](handleEntityNotFound(_0x5fce2f,null))[_0x3d6348('0x19')](removeEntity(_0x5fce2f,null))[_0x3d6348('0x22')](handleError(_0x5fce2f,null));},exports[_0xca723c('0x25')]=function(_0x276403,_0x4eb50b){const _0x9029c1=_0xca723c;let _0x2cfb4b={};const _0x2fb434={};let _0x147615,_0x1386b9;return db['FreshdeskConfiguration'][_0x9029c1('0x15')]({'where':{'id':_0x276403['params']['id']}})[_0x9029c1('0x19')](handleEntityNotFound(_0x4eb50b,null))[_0x9029c1('0x19')](function(_0x15d248){const _0x2e69c2=_0x9029c1;if(_0x15d248)return _0x147615=_0x15d248,_0x2fb434[_0x2e69c2('0x27')]=_[_0x2e69c2('0x16')](db['FreshdeskField']['rawAttributes']),_0x2fb434[_0x2e69c2('0x12')]=_[_0x2e69c2('0x16')](_0x276403[_0x2e69c2('0x12')]),_0x2fb434[_0x2e69c2('0x21')]=_['intersection'](_0x2fb434[_0x2e69c2('0x27')],_0x2fb434[_0x2e69c2('0x12')]),_0x2cfb4b[_0x2e69c2('0x10')]=_[_0x2e69c2('0x2f')](_0x2fb434['model'],qs[_0x2e69c2('0x34')](_0x276403[_0x2e69c2('0x12')][_0x2e69c2('0x34')])),_0x2cfb4b[_0x2e69c2('0x10')]=_0x2cfb4b[_0x2e69c2('0x10')]['length']?_0x2cfb4b[_0x2e69c2('0x10')]:_0x2fb434[_0x2e69c2('0x27')],_0x2cfb4b[_0x2e69c2('0x2a')]=qs[_0x2e69c2('0x18')](_0x276403[_0x2e69c2('0x12')][_0x2e69c2('0x18')]),_0x2cfb4b[_0x2e69c2('0x11')]=qs['filters'](_[_0x2e69c2('0x37')](_0x276403['query'],_0x2fb434[_0x2e69c2('0x21')])),_0x276403['query'][_0x2e69c2('0x9')]&&(_0x2cfb4b[_0x2e69c2('0x11')]=_[_0x2e69c2('0x32')](_0x2cfb4b[_0x2e69c2('0x11')],{[Op['or']]:_['map'](_0x2cfb4b['attributes'],function(_0xe565bf){const _0x1ada71=_0x2e69c2,_0x34ef5d={};return _0x34ef5d[_0xe565bf]={[Op[_0x1ada71('0x31')]]:'%'+_0x276403[_0x1ada71('0x12')][_0x1ada71('0x9')]+'%'},_0x34ef5d;})})),_0x2cfb4b=_[_0x2e69c2('0x32')]({},_0x2cfb4b,_0x276403[_0x2e69c2('0x26')]),_0x147615[_0x2e69c2('0x25')](_0x2cfb4b);})[_0x9029c1('0x19')](function(_0x396d5d){const _0x2c7158=_0x9029c1;if(_0x396d5d)return _0x1386b9=_0x396d5d['length'],typeof _0x276403['query'][_0x2c7158('0x1e')]===_0x2c7158('0xe')&&(_0x2cfb4b[_0x2c7158('0x0')]=qs[_0x2c7158('0x0')](_0x276403[_0x2c7158('0x12')]['limit']),_0x2cfb4b['offset']=qs[_0x2c7158('0x36')](_0x276403['query']['offset'])),_0x147615[_0x2c7158('0x25')](_0x2cfb4b);})[_0x9029c1('0x19')](function(_0x18bdf3){if(_0x18bdf3)return _0x18bdf3?{'count':_0x1386b9,'rows':_0x18bdf3}:null;})[_0x9029c1('0x19')](respondWithResult(_0x4eb50b,null))[_0x9029c1('0x22')](handleError(_0x4eb50b,null));},exports[_0xca723c('0xd')]=function(_0x18b899,_0xbee192){const _0x5dd01c=_0xca723c;let _0x1c541e={};const _0x49b291={};let _0x3dc059,_0x447f2f;return db[_0x5dd01c('0x6')]['findOne']({'where':{'id':_0x18b899[_0x5dd01c('0x29')]['id']}})[_0x5dd01c('0x19')](handleEntityNotFound(_0xbee192,null))[_0x5dd01c('0x19')](function(_0x1e865c){const _0x5decb4=_0x5dd01c;if(_0x1e865c)return _0x3dc059=_0x1e865c,_0x49b291[_0x5decb4('0x27')]=_['keys'](db[_0x5decb4('0x35')][_0x5decb4('0x20')]),_0x49b291['query']=_[_0x5decb4('0x16')](_0x18b899[_0x5decb4('0x12')]),_0x49b291[_0x5decb4('0x21')]=_[_0x5decb4('0x2f')](_0x49b291[_0x5decb4('0x27')],_0x49b291[_0x5decb4('0x12')]),_0x1c541e[_0x5decb4('0x10')]=_['intersection'](_0x49b291[_0x5decb4('0x27')],qs[_0x5decb4('0x34')](_0x18b899[_0x5decb4('0x12')]['fields'])),_0x1c541e[_0x5decb4('0x10')]=_0x1c541e[_0x5decb4('0x10')][_0x5decb4('0x38')]?_0x1c541e[_0x5decb4('0x10')]:_0x49b291[_0x5decb4('0x27')],_0x1c541e[_0x5decb4('0x2a')]=qs[_0x5decb4('0x18')](_0x18b899['query'][_0x5decb4('0x18')]),_0x1c541e[_0x5decb4('0x11')]=qs[_0x5decb4('0x21')](_[_0x5decb4('0x37')](_0x18b899[_0x5decb4('0x12')],_0x49b291[_0x5decb4('0x21')])),_0x18b899['query']['filter']&&(_0x1c541e['where']=_['merge'](_0x1c541e[_0x5decb4('0x11')],{[Op['or']]:_[_0x5decb4('0xa')](_0x1c541e[_0x5decb4('0x10')],function(_0x5c6965){const _0x362a2b=_0x5decb4,_0x30c2aa={};return _0x30c2aa[_0x5c6965]={[Op[_0x362a2b('0x31')]]:'%'+_0x18b899[_0x362a2b('0x12')][_0x362a2b('0x9')]+'%'},_0x30c2aa;})})),_0x1c541e=_[_0x5decb4('0x32')]({},_0x1c541e,_0x18b899['options']),_0x3dc059[_0x5decb4('0xd')](_0x1c541e);})[_0x5dd01c('0x19')](function(_0x1f9ed4){const _0x1eec0e=_0x5dd01c;if(_0x1f9ed4)return _0x447f2f=_0x1f9ed4[_0x1eec0e('0x38')],typeof _0x18b899[_0x1eec0e('0x12')][_0x1eec0e('0x1e')]===_0x1eec0e('0xe')&&(_0x1c541e[_0x1eec0e('0x0')]=qs[_0x1eec0e('0x0')](_0x18b899[_0x1eec0e('0x12')]['limit']),_0x1c541e['offset']=qs[_0x1eec0e('0x36')](_0x18b899[_0x1eec0e('0x12')][_0x1eec0e('0x36')])),_0x3dc059[_0x1eec0e('0xd')](_0x1c541e);})['then'](function(_0x24df09){if(_0x24df09)return _0x24df09?{'count':_0x447f2f,'rows':_0x24df09}:null;})[_0x5dd01c('0x19')](respondWithResult(_0xbee192,null))[_0x5dd01c('0x22')](handleError(_0xbee192,null));},exports['getDescriptions']=function(_0x45ebe1,_0x3d983f){const _0xf5bb17=_0xca723c;let _0x2dbd5c={};const _0x380dcb={};let _0x1079cc,_0x26eb0c;return db[_0xf5bb17('0x6')]['findOne']({'where':{'id':_0x45ebe1[_0xf5bb17('0x29')]['id']}})[_0xf5bb17('0x19')](handleEntityNotFound(_0x3d983f,null))[_0xf5bb17('0x19')](function(_0x10708a){const _0x46294d=_0xf5bb17;if(_0x10708a)return _0x1079cc=_0x10708a,_0x380dcb[_0x46294d('0x27')]=_[_0x46294d('0x16')](db[_0x46294d('0x35')]['rawAttributes']),_0x380dcb[_0x46294d('0x12')]=_[_0x46294d('0x16')](_0x45ebe1['query']),_0x380dcb[_0x46294d('0x21')]=_[_0x46294d('0x2f')](_0x380dcb['model'],_0x380dcb['query']),_0x2dbd5c['attributes']=_[_0x46294d('0x2f')](_0x380dcb[_0x46294d('0x27')],qs[_0x46294d('0x34')](_0x45ebe1[_0x46294d('0x12')][_0x46294d('0x34')])),_0x2dbd5c[_0x46294d('0x10')]=_0x2dbd5c[_0x46294d('0x10')][_0x46294d('0x38')]?_0x2dbd5c[_0x46294d('0x10')]:_0x380dcb[_0x46294d('0x27')],_0x2dbd5c[_0x46294d('0x2a')]=qs[_0x46294d('0x18')](_0x45ebe1[_0x46294d('0x12')][_0x46294d('0x18')]),_0x2dbd5c[_0x46294d('0x11')]=qs[_0x46294d('0x21')](_[_0x46294d('0x37')](_0x45ebe1[_0x46294d('0x12')],_0x380dcb[_0x46294d('0x21')])),_0x45ebe1['query'][_0x46294d('0x9')]&&(_0x2dbd5c['where']=_[_0x46294d('0x32')](_0x2dbd5c[_0x46294d('0x11')],{[Op['or']]:_[_0x46294d('0xa')](_0x2dbd5c['attributes'],function(_0x632d9e){const _0x376a23=_0x46294d,_0x31191a={};return _0x31191a[_0x632d9e]={[Op[_0x376a23('0x31')]]:'%'+_0x45ebe1[_0x376a23('0x12')][_0x376a23('0x9')]+'%'},_0x31191a;})})),_0x2dbd5c=_['merge']({},_0x2dbd5c,_0x45ebe1['options']),_0x1079cc[_0x46294d('0x1d')](_0x2dbd5c);})[_0xf5bb17('0x19')](function(_0x9c84a2){const _0x2b5846=_0xf5bb17;if(_0x9c84a2)return _0x26eb0c=_0x9c84a2[_0x2b5846('0x38')],typeof _0x45ebe1[_0x2b5846('0x12')][_0x2b5846('0x1e')]===_0x2b5846('0xe')&&(_0x2dbd5c[_0x2b5846('0x0')]=qs[_0x2b5846('0x0')](_0x45ebe1['query'][_0x2b5846('0x0')]),_0x2dbd5c[_0x2b5846('0x36')]=qs[_0x2b5846('0x36')](_0x45ebe1[_0x2b5846('0x12')]['offset'])),_0x1079cc[_0x2b5846('0x1d')](_0x2dbd5c);})[_0xf5bb17('0x19')](function(_0x3a1cb6){if(_0x3a1cb6)return _0x3a1cb6?{'count':_0x26eb0c,'rows':_0x3a1cb6}:null;})['then'](respondWithResult(_0x3d983f,null))[_0xf5bb17('0x22')](handleError(_0x3d983f,null));},exports[_0xca723c('0x7')]=function(_0x2ea4ce,_0x3f2d4){const _0x38a7f3=_0xca723c;let _0x156597={};const _0x3d8f11={};let _0x4398be,_0x24b601;return db[_0x38a7f3('0x6')][_0x38a7f3('0x15')]({'where':{'id':_0x2ea4ce[_0x38a7f3('0x29')]['id']}})['then'](handleEntityNotFound(_0x3f2d4,null))['then'](function(_0xb729c0){const _0x233658=_0x38a7f3;if(_0xb729c0)return _0x4398be=_0xb729c0,_0x3d8f11[_0x233658('0x27')]=_[_0x233658('0x16')](db['Tag'][_0x233658('0x20')]),_0x3d8f11[_0x233658('0x12')]=_[_0x233658('0x16')](_0x2ea4ce[_0x233658('0x12')]),_0x3d8f11[_0x233658('0x21')]=_['intersection'](_0x3d8f11[_0x233658('0x27')],_0x3d8f11[_0x233658('0x12')]),_0x156597[_0x233658('0x10')]=_[_0x233658('0x2f')](_0x3d8f11[_0x233658('0x27')],qs[_0x233658('0x34')](_0x2ea4ce['query']['fields'])),_0x156597[_0x233658('0x10')]=_0x156597[_0x233658('0x10')][_0x233658('0x38')]?_0x156597[_0x233658('0x10')]:_0x3d8f11[_0x233658('0x27')],_0x156597[_0x233658('0x2a')]=qs[_0x233658('0x18')](_0x2ea4ce[_0x233658('0x12')][_0x233658('0x18')]),_0x156597[_0x233658('0x11')]=qs[_0x233658('0x21')](_['pick'](_0x2ea4ce[_0x233658('0x12')],_0x3d8f11[_0x233658('0x21')])),_0x2ea4ce[_0x233658('0x12')]['filter']&&(_0x156597[_0x233658('0x11')]=_[_0x233658('0x32')](_0x156597[_0x233658('0x11')],{[Op['or']]:_[_0x233658('0xa')](_0x156597[_0x233658('0x10')],function(_0x48923a){const _0x3d4f4f=_0x233658,_0x4c553b={};return _0x4c553b[_0x48923a]={[Op[_0x3d4f4f('0x31')]]:'%'+_0x2ea4ce['query'][_0x3d4f4f('0x9')]+'%'},_0x4c553b;})})),_0x156597=_[_0x233658('0x32')]({},_0x156597,_0x2ea4ce[_0x233658('0x26')]),_0x4398be[_0x233658('0x7')](_0x156597);})[_0x38a7f3('0x19')](function(_0x449057){const _0x20f1a4=_0x38a7f3;if(_0x449057)return _0x24b601=_0x449057[_0x20f1a4('0x38')],typeof _0x2ea4ce[_0x20f1a4('0x12')][_0x20f1a4('0x1e')]===_0x20f1a4('0xe')&&(_0x156597[_0x20f1a4('0x0')]=qs[_0x20f1a4('0x0')](_0x2ea4ce['query'][_0x20f1a4('0x0')]),_0x156597[_0x20f1a4('0x36')]=qs[_0x20f1a4('0x36')](_0x2ea4ce['query']['offset'])),_0x4398be[_0x20f1a4('0x7')](_0x156597);})['then'](function(_0x4441be){if(_0x4441be)return _0x4441be?{'count':_0x24b601,'rows':_0x4441be}:null;})[_0x38a7f3('0x19')](respondWithResult(_0x3f2d4,null))['catch'](handleError(_0x3f2d4,null));},exports[_0xca723c('0x1a')]=function(_0x4986c9,_0x252d32){const _0x2d515d=_0xca723c;return _0x4986c9['body']['id']&&delete _0x4986c9['body']['id'],db[_0x2d515d('0x6')][_0x2d515d('0x15')]({'where':{'id':_0x4986c9[_0x2d515d('0x29')]['id']}})[_0x2d515d('0x19')](handleEntityNotFound(_0x252d32,null))[_0x2d515d('0x19')](function(_0x137c3e){const _0x4d95ac=_0x2d515d;if(_0x137c3e)return _0x137c3e[_0x4d95ac('0x1a')](_0x4986c9[_0x4d95ac('0xc')][_0x4d95ac('0x4')]||[]);return null;})['then'](respondWithResult(_0x252d32,null))['catch'](handleError(_0x252d32,null));}; \ No newline at end of file +const a260_0x5b53=['lodash','params','VIRTUAL','stack','attributes','nolimit','options','limit','status','FreshdeskConfiguration','sequelize','setTags','ids','create','intersection','then','merge','send','json','findOne','error','fields','key','index','like','rawAttributes','Tag','api','update','findAll','rows','includeAll','fieldName','name','catch','pick','undefined','getFields','body','query','count','map','filter','sort','getDescriptions','where','include','getTags','FreshdeskField','Content-Range','sendStatus','order','../../mysqldb','type','length','filters','set','model','offset','end','../../config/logger','destroy','keys','getSubjects'];(function(_0x5202ed,_0x5b53c0){const _0x423948=function(_0x3823d9){while(--_0x3823d9){_0x5202ed['push'](_0x5202ed['shift']());}};_0x423948(++_0x5b53c0);}(a260_0x5b53,0x1f0));const a260_0x4239=function(_0x5202ed,_0x5b53c0){_0x5202ed=_0x5202ed-0x0;let _0x423948=a260_0x5b53[_0x5202ed];return _0x423948;};const _0x5394d3=a260_0x4239;'use strict';const _=require(_0x5394d3('0x10')),qs=require('../../components/parsers/qs'),logger=require(_0x5394d3('0xc'))(_0x5394d3('0x2b')),db=require(_0x5394d3('0x4'))['db'],{Op}=require(_0x5394d3('0x1a'));function respondWithResult(_0x3823d9,_0x1aae6b){return _0x1aae6b=_0x1aae6b||0xc8,function(_0x3b245d){const _0x194d17=a260_0x4239;if(_0x3b245d)return _0x3823d9[_0x194d17('0x18')](_0x1aae6b)[_0x194d17('0x22')](_0x3b245d);};}function respondWithFilteredResult(_0x1d0dc9,_0x510cb0){return function(_0x3a60f2){const _0x19bc6c=a260_0x4239;if(_0x3a60f2){const _0x447573=_0x3a60f2[_0x19bc6c('0x38')],_0x5ca57a=_0x510cb0[_0x19bc6c('0xa')];let _0x1f1e09=_0x510cb0['offset']+_0x510cb0['limit'],_0x2307fe;return _0x1f1e09>=_0x447573?(_0x1f1e09=_0x447573,_0x2307fe=0xc8):_0x2307fe=0xce,_0x1d0dc9[_0x19bc6c('0x18')](_0x2307fe),_0x1d0dc9[_0x19bc6c('0x8')](_0x19bc6c('0x1'),_0x5ca57a+'-'+_0x1f1e09+'/'+_0x447573)[_0x19bc6c('0x22')](_0x3a60f2);}return null;};}function saveUpdates(_0x56f80b){return function(_0x32f2bc){const _0x3dcb86=a260_0x4239;if(_0x32f2bc)return _0x32f2bc[_0x3dcb86('0x2c')](_0x56f80b)['then'](function(_0x333bab){return _0x333bab;});return null;};}function removeEntity(_0x204a87){return function(_0x1bee6b){const _0x5ee442=a260_0x4239;if(_0x1bee6b)return _0x1bee6b[_0x5ee442('0xd')]()[_0x5ee442('0x1f')](function(){const _0x6c5a03=_0x5ee442;_0x204a87[_0x6c5a03('0x18')](0xcc)[_0x6c5a03('0xb')]();});};}function handleEntityNotFound(_0x5c2111){return function(_0x1d3eac){const _0x3f4097=a260_0x4239;return!_0x1d3eac&&_0x5c2111[_0x3f4097('0x2')](0x194),_0x1d3eac;};}function handleError(_0x2a5e3b,_0x4eb628){return _0x4eb628=_0x4eb628||0x1f4,function(_0x24ebed){const _0x4171ee=a260_0x4239;logger[_0x4171ee('0x24')](_0x24ebed[_0x4171ee('0x13')]),_0x24ebed[_0x4171ee('0x31')]&&delete _0x24ebed[_0x4171ee('0x31')],_0x2a5e3b[_0x4171ee('0x18')](_0x4eb628)[_0x4171ee('0x21')](_0x24ebed);};}exports[_0x5394d3('0x27')]=function(_0x3161f3,_0x177a2c){const _0x418358=_0x5394d3;let _0x3b37f3={};const _0x364fa5={},_0x32b0d7={'count':0x0,'rows':[]},_0x55b0e5=_[_0x418358('0x39')](db[_0x418358('0x19')][_0x418358('0x29')],function(_0x266f43){const _0x2a3952=_0x418358;return{'name':_0x266f43[_0x2a3952('0x30')],'type':_0x266f43[_0x2a3952('0x5')][_0x2a3952('0x26')]};});_0x364fa5[_0x418358('0x9')]=_[_0x418358('0x39')](_0x55b0e5,_0x418358('0x31')),_0x364fa5[_0x418358('0x37')]=_[_0x418358('0xe')](_0x3161f3[_0x418358('0x37')]),_0x364fa5[_0x418358('0x7')]=_[_0x418358('0x1e')](_0x364fa5[_0x418358('0x9')],_0x364fa5[_0x418358('0x37')]),_0x3b37f3[_0x418358('0x14')]=_[_0x418358('0x1e')](_0x364fa5[_0x418358('0x9')],qs[_0x418358('0x25')](_0x3161f3[_0x418358('0x37')][_0x418358('0x25')])),_0x3b37f3['attributes']=_0x3b37f3[_0x418358('0x14')][_0x418358('0x6')]?_0x3b37f3['attributes']:_0x364fa5['model'];typeof _0x3161f3[_0x418358('0x37')][_0x418358('0x15')]===_0x418358('0x34')&&(_0x3b37f3[_0x418358('0x17')]=qs[_0x418358('0x17')](_0x3161f3[_0x418358('0x37')]['limit']),_0x3b37f3['offset']=qs[_0x418358('0xa')](_0x3161f3[_0x418358('0x37')]['offset']));_0x3b37f3[_0x418358('0x3')]=qs[_0x418358('0x3b')](_0x3161f3[_0x418358('0x37')][_0x418358('0x3b')]),_0x3b37f3[_0x418358('0x3d')]=qs[_0x418358('0x7')](_[_0x418358('0x33')](_0x3161f3[_0x418358('0x37')],_0x364fa5[_0x418358('0x7')]),_0x55b0e5);_0x3161f3[_0x418358('0x37')][_0x418358('0x3a')]&&(_0x3b37f3[_0x418358('0x3d')]=_[_0x418358('0x20')](_0x3b37f3[_0x418358('0x3d')],{[Op['or']]:_[_0x418358('0x39')](_0x55b0e5,function(_0x1cf03a){const _0x589e3c=_0x418358;if(_0x1cf03a[_0x589e3c('0x5')]!==_0x589e3c('0x12')){const _0x3057be={};return _0x3057be[_0x1cf03a['name']]={[Op['like']]:'%'+_0x3161f3[_0x589e3c('0x37')]['filter']+'%'},_0x3057be;}})}));_0x3b37f3=_[_0x418358('0x20')]({},_0x3b37f3,_0x3161f3[_0x418358('0x16')]);const _0x43e96a={'where':_0x3b37f3['where']};return db['FreshdeskConfiguration'][_0x418358('0x38')](_0x43e96a)[_0x418358('0x1f')](function(_0x19c084){const _0x351aec=_0x418358;return _0x32b0d7[_0x351aec('0x38')]=_0x19c084,_0x3161f3['query']['includeAll']&&(_0x3b37f3[_0x351aec('0x3e')]=[{'all':!![]}]),db[_0x351aec('0x19')][_0x351aec('0x2d')](_0x3b37f3);})[_0x418358('0x1f')](function(_0x45416f){const _0x12921b=_0x418358;return _0x32b0d7[_0x12921b('0x2e')]=_0x45416f,_0x32b0d7;})[_0x418358('0x1f')](respondWithFilteredResult(_0x177a2c,_0x3b37f3))[_0x418358('0x32')](handleError(_0x177a2c,null));},exports['show']=function(_0x188000,_0x3f1bba){const _0x288df7=_0x5394d3;let _0x77a24c={'raw':![],'where':{'id':_0x188000[_0x288df7('0x11')]['id']}};const _0x202a8f={};return _0x202a8f[_0x288df7('0x9')]=_['keys'](db[_0x288df7('0x19')][_0x288df7('0x29')]),_0x202a8f['query']=_['keys'](_0x188000['query']),_0x202a8f[_0x288df7('0x7')]=_[_0x288df7('0x1e')](_0x202a8f[_0x288df7('0x9')],_0x202a8f[_0x288df7('0x37')]),_0x77a24c[_0x288df7('0x14')]=_[_0x288df7('0x1e')](_0x202a8f['model'],qs['fields'](_0x188000['query'][_0x288df7('0x25')])),_0x77a24c[_0x288df7('0x14')]=_0x77a24c[_0x288df7('0x14')][_0x288df7('0x6')]?_0x77a24c[_0x288df7('0x14')]:_0x202a8f['model'],_0x188000['query'][_0x288df7('0x2f')]&&(_0x77a24c[_0x288df7('0x3e')]=[{'all':!![]}]),_0x77a24c=_[_0x288df7('0x20')]({},_0x77a24c,_0x188000[_0x288df7('0x16')]),db[_0x288df7('0x19')][_0x288df7('0x23')](_0x77a24c)['then'](handleEntityNotFound(_0x3f1bba,null))['then'](respondWithResult(_0x3f1bba,null))[_0x288df7('0x32')](handleError(_0x3f1bba,null));},exports[_0x5394d3('0x1d')]=function(_0x15c9a4,_0x1a6214){const _0x17b2b2=_0x5394d3;return db['FreshdeskConfiguration']['create'](_0x15c9a4[_0x17b2b2('0x36')],{})['then'](respondWithResult(_0x1a6214,0xc9))[_0x17b2b2('0x32')](handleError(_0x1a6214,null));},exports[_0x5394d3('0x2c')]=function(_0x22857f,_0x31bcbe){const _0x4654e2=_0x5394d3;return _0x22857f['body']['id']&&delete _0x22857f[_0x4654e2('0x36')]['id'],db[_0x4654e2('0x19')][_0x4654e2('0x23')]({'where':{'id':_0x22857f[_0x4654e2('0x11')]['id']}})[_0x4654e2('0x1f')](handleEntityNotFound(_0x31bcbe,null))[_0x4654e2('0x1f')](saveUpdates(_0x22857f['body'],null))[_0x4654e2('0x1f')](respondWithResult(_0x31bcbe,null))[_0x4654e2('0x32')](handleError(_0x31bcbe,null));},exports['destroy']=function(_0x432d6b,_0x1c3130){const _0x1171b3=_0x5394d3;return db['FreshdeskConfiguration'][_0x1171b3('0x23')]({'where':{'id':_0x432d6b[_0x1171b3('0x11')]['id']}})[_0x1171b3('0x1f')](handleEntityNotFound(_0x1c3130,null))[_0x1171b3('0x1f')](removeEntity(_0x1c3130,null))[_0x1171b3('0x32')](handleError(_0x1c3130,null));},exports['getFields']=function(_0x241032,_0x4ff62a){const _0x1f014f=_0x5394d3;let _0x136994={};const _0x5c6582={};let _0x4fcb27,_0xb15bf9;return db['FreshdeskConfiguration'][_0x1f014f('0x23')]({'where':{'id':_0x241032[_0x1f014f('0x11')]['id']}})[_0x1f014f('0x1f')](handleEntityNotFound(_0x4ff62a,null))[_0x1f014f('0x1f')](function(_0xafc96f){const _0x44ee9d=_0x1f014f;if(_0xafc96f)return _0x4fcb27=_0xafc96f,_0x5c6582['model']=_[_0x44ee9d('0xe')](db['FreshdeskField'][_0x44ee9d('0x29')]),_0x5c6582['query']=_['keys'](_0x241032[_0x44ee9d('0x37')]),_0x5c6582[_0x44ee9d('0x7')]=_[_0x44ee9d('0x1e')](_0x5c6582[_0x44ee9d('0x9')],_0x5c6582[_0x44ee9d('0x37')]),_0x136994[_0x44ee9d('0x14')]=_['intersection'](_0x5c6582[_0x44ee9d('0x9')],qs['fields'](_0x241032[_0x44ee9d('0x37')][_0x44ee9d('0x25')])),_0x136994[_0x44ee9d('0x14')]=_0x136994[_0x44ee9d('0x14')][_0x44ee9d('0x6')]?_0x136994['attributes']:_0x5c6582[_0x44ee9d('0x9')],_0x136994[_0x44ee9d('0x3')]=qs[_0x44ee9d('0x3b')](_0x241032['query'][_0x44ee9d('0x3b')]),_0x136994[_0x44ee9d('0x3d')]=qs[_0x44ee9d('0x7')](_['pick'](_0x241032[_0x44ee9d('0x37')],_0x5c6582[_0x44ee9d('0x7')])),_0x241032[_0x44ee9d('0x37')][_0x44ee9d('0x3a')]&&(_0x136994['where']=_[_0x44ee9d('0x20')](_0x136994[_0x44ee9d('0x3d')],{[Op['or']]:_[_0x44ee9d('0x39')](_0x136994['attributes'],function(_0x257aba){const _0x166b64=_0x44ee9d,_0x1a571f={};return _0x1a571f[_0x257aba]={[Op[_0x166b64('0x28')]]:'%'+_0x241032[_0x166b64('0x37')]['filter']+'%'},_0x1a571f;})})),_0x136994=_[_0x44ee9d('0x20')]({},_0x136994,_0x241032[_0x44ee9d('0x16')]),_0x4fcb27[_0x44ee9d('0x35')](_0x136994);})[_0x1f014f('0x1f')](function(_0x50c75a){const _0xd84615=_0x1f014f;if(_0x50c75a)return _0xb15bf9=_0x50c75a[_0xd84615('0x6')],typeof _0x241032[_0xd84615('0x37')][_0xd84615('0x15')]===_0xd84615('0x34')&&(_0x136994['limit']=qs[_0xd84615('0x17')](_0x241032[_0xd84615('0x37')]['limit']),_0x136994[_0xd84615('0xa')]=qs[_0xd84615('0xa')](_0x241032[_0xd84615('0x37')][_0xd84615('0xa')])),_0x4fcb27[_0xd84615('0x35')](_0x136994);})[_0x1f014f('0x1f')](function(_0x30c335){if(_0x30c335)return _0x30c335?{'count':_0xb15bf9,'rows':_0x30c335}:null;})[_0x1f014f('0x1f')](respondWithResult(_0x4ff62a,null))[_0x1f014f('0x32')](handleError(_0x4ff62a,null));},exports[_0x5394d3('0xf')]=function(_0x41e988,_0x5c37ae){const _0x40073e=_0x5394d3;let _0xbb273={};const _0xcaefa={};let _0x100ca5,_0x293a1e;return db[_0x40073e('0x19')]['findOne']({'where':{'id':_0x41e988[_0x40073e('0x11')]['id']}})[_0x40073e('0x1f')](handleEntityNotFound(_0x5c37ae,null))[_0x40073e('0x1f')](function(_0x11a42b){const _0x712290=_0x40073e;if(_0x11a42b)return _0x100ca5=_0x11a42b,_0xcaefa[_0x712290('0x9')]=_[_0x712290('0xe')](db[_0x712290('0x0')][_0x712290('0x29')]),_0xcaefa[_0x712290('0x37')]=_['keys'](_0x41e988[_0x712290('0x37')]),_0xcaefa[_0x712290('0x7')]=_[_0x712290('0x1e')](_0xcaefa[_0x712290('0x9')],_0xcaefa[_0x712290('0x37')]),_0xbb273[_0x712290('0x14')]=_[_0x712290('0x1e')](_0xcaefa['model'],qs[_0x712290('0x25')](_0x41e988[_0x712290('0x37')]['fields'])),_0xbb273[_0x712290('0x14')]=_0xbb273['attributes'][_0x712290('0x6')]?_0xbb273[_0x712290('0x14')]:_0xcaefa[_0x712290('0x9')],_0xbb273[_0x712290('0x3')]=qs[_0x712290('0x3b')](_0x41e988[_0x712290('0x37')][_0x712290('0x3b')]),_0xbb273[_0x712290('0x3d')]=qs['filters'](_['pick'](_0x41e988[_0x712290('0x37')],_0xcaefa['filters'])),_0x41e988[_0x712290('0x37')][_0x712290('0x3a')]&&(_0xbb273[_0x712290('0x3d')]=_['merge'](_0xbb273[_0x712290('0x3d')],{[Op['or']]:_[_0x712290('0x39')](_0xbb273[_0x712290('0x14')],function(_0x58aa56){const _0x2512f0=_0x712290,_0x3b0971={};return _0x3b0971[_0x58aa56]={[Op[_0x2512f0('0x28')]]:'%'+_0x41e988[_0x2512f0('0x37')][_0x2512f0('0x3a')]+'%'},_0x3b0971;})})),_0xbb273=_[_0x712290('0x20')]({},_0xbb273,_0x41e988[_0x712290('0x16')]),_0x100ca5[_0x712290('0xf')](_0xbb273);})['then'](function(_0x81b15){const _0xa1a48f=_0x40073e;if(_0x81b15)return _0x293a1e=_0x81b15['length'],typeof _0x41e988[_0xa1a48f('0x37')]['nolimit']===_0xa1a48f('0x34')&&(_0xbb273[_0xa1a48f('0x17')]=qs[_0xa1a48f('0x17')](_0x41e988['query'][_0xa1a48f('0x17')]),_0xbb273['offset']=qs[_0xa1a48f('0xa')](_0x41e988[_0xa1a48f('0x37')][_0xa1a48f('0xa')])),_0x100ca5['getSubjects'](_0xbb273);})[_0x40073e('0x1f')](function(_0x169906){if(_0x169906)return _0x169906?{'count':_0x293a1e,'rows':_0x169906}:null;})[_0x40073e('0x1f')](respondWithResult(_0x5c37ae,null))[_0x40073e('0x32')](handleError(_0x5c37ae,null));},exports['getDescriptions']=function(_0x2b1dc6,_0x2dded3){const _0x593984=_0x5394d3;let _0xef0abd={};const _0x3b38e1={};let _0x52009b,_0x52d343;return db['FreshdeskConfiguration'][_0x593984('0x23')]({'where':{'id':_0x2b1dc6[_0x593984('0x11')]['id']}})[_0x593984('0x1f')](handleEntityNotFound(_0x2dded3,null))['then'](function(_0x39ec44){const _0x14c162=_0x593984;if(_0x39ec44)return _0x52009b=_0x39ec44,_0x3b38e1[_0x14c162('0x9')]=_[_0x14c162('0xe')](db[_0x14c162('0x0')]['rawAttributes']),_0x3b38e1[_0x14c162('0x37')]=_[_0x14c162('0xe')](_0x2b1dc6[_0x14c162('0x37')]),_0x3b38e1['filters']=_[_0x14c162('0x1e')](_0x3b38e1[_0x14c162('0x9')],_0x3b38e1[_0x14c162('0x37')]),_0xef0abd['attributes']=_[_0x14c162('0x1e')](_0x3b38e1['model'],qs[_0x14c162('0x25')](_0x2b1dc6[_0x14c162('0x37')][_0x14c162('0x25')])),_0xef0abd[_0x14c162('0x14')]=_0xef0abd['attributes'][_0x14c162('0x6')]?_0xef0abd['attributes']:_0x3b38e1[_0x14c162('0x9')],_0xef0abd[_0x14c162('0x3')]=qs[_0x14c162('0x3b')](_0x2b1dc6[_0x14c162('0x37')][_0x14c162('0x3b')]),_0xef0abd[_0x14c162('0x3d')]=qs[_0x14c162('0x7')](_[_0x14c162('0x33')](_0x2b1dc6[_0x14c162('0x37')],_0x3b38e1[_0x14c162('0x7')])),_0x2b1dc6[_0x14c162('0x37')]['filter']&&(_0xef0abd['where']=_[_0x14c162('0x20')](_0xef0abd[_0x14c162('0x3d')],{[Op['or']]:_['map'](_0xef0abd[_0x14c162('0x14')],function(_0x5e6c9f){const _0x1a2d04=_0x14c162,_0x127481={};return _0x127481[_0x5e6c9f]={[Op['like']]:'%'+_0x2b1dc6[_0x1a2d04('0x37')][_0x1a2d04('0x3a')]+'%'},_0x127481;})})),_0xef0abd=_[_0x14c162('0x20')]({},_0xef0abd,_0x2b1dc6['options']),_0x52009b[_0x14c162('0x3c')](_0xef0abd);})['then'](function(_0x2b2053){const _0x1f5b11=_0x593984;if(_0x2b2053)return _0x52d343=_0x2b2053['length'],typeof _0x2b1dc6[_0x1f5b11('0x37')][_0x1f5b11('0x15')]===_0x1f5b11('0x34')&&(_0xef0abd[_0x1f5b11('0x17')]=qs[_0x1f5b11('0x17')](_0x2b1dc6[_0x1f5b11('0x37')][_0x1f5b11('0x17')]),_0xef0abd['offset']=qs[_0x1f5b11('0xa')](_0x2b1dc6['query'][_0x1f5b11('0xa')])),_0x52009b[_0x1f5b11('0x3c')](_0xef0abd);})[_0x593984('0x1f')](function(_0x35d19f){if(_0x35d19f)return _0x35d19f?{'count':_0x52d343,'rows':_0x35d19f}:null;})[_0x593984('0x1f')](respondWithResult(_0x2dded3,null))['catch'](handleError(_0x2dded3,null));},exports[_0x5394d3('0x3f')]=function(_0x19e5d7,_0x355f63){const _0x3b2f41=_0x5394d3;let _0x340a0f={};const _0x1ae151={};let _0x3aeac6,_0x1d8a6d;return db[_0x3b2f41('0x19')][_0x3b2f41('0x23')]({'where':{'id':_0x19e5d7[_0x3b2f41('0x11')]['id']}})['then'](handleEntityNotFound(_0x355f63,null))[_0x3b2f41('0x1f')](function(_0x4cf784){const _0xe4ba5b=_0x3b2f41;if(_0x4cf784)return _0x3aeac6=_0x4cf784,_0x1ae151['model']=_[_0xe4ba5b('0xe')](db[_0xe4ba5b('0x2a')][_0xe4ba5b('0x29')]),_0x1ae151[_0xe4ba5b('0x37')]=_[_0xe4ba5b('0xe')](_0x19e5d7[_0xe4ba5b('0x37')]),_0x1ae151[_0xe4ba5b('0x7')]=_[_0xe4ba5b('0x1e')](_0x1ae151[_0xe4ba5b('0x9')],_0x1ae151[_0xe4ba5b('0x37')]),_0x340a0f[_0xe4ba5b('0x14')]=_['intersection'](_0x1ae151[_0xe4ba5b('0x9')],qs[_0xe4ba5b('0x25')](_0x19e5d7[_0xe4ba5b('0x37')][_0xe4ba5b('0x25')])),_0x340a0f[_0xe4ba5b('0x14')]=_0x340a0f[_0xe4ba5b('0x14')][_0xe4ba5b('0x6')]?_0x340a0f[_0xe4ba5b('0x14')]:_0x1ae151[_0xe4ba5b('0x9')],_0x340a0f[_0xe4ba5b('0x3')]=qs[_0xe4ba5b('0x3b')](_0x19e5d7[_0xe4ba5b('0x37')][_0xe4ba5b('0x3b')]),_0x340a0f[_0xe4ba5b('0x3d')]=qs[_0xe4ba5b('0x7')](_[_0xe4ba5b('0x33')](_0x19e5d7[_0xe4ba5b('0x37')],_0x1ae151['filters'])),_0x19e5d7[_0xe4ba5b('0x37')][_0xe4ba5b('0x3a')]&&(_0x340a0f[_0xe4ba5b('0x3d')]=_[_0xe4ba5b('0x20')](_0x340a0f[_0xe4ba5b('0x3d')],{[Op['or']]:_[_0xe4ba5b('0x39')](_0x340a0f['attributes'],function(_0x4fca47){const _0x10534c=_0xe4ba5b,_0x496928={};return _0x496928[_0x4fca47]={[Op[_0x10534c('0x28')]]:'%'+_0x19e5d7[_0x10534c('0x37')]['filter']+'%'},_0x496928;})})),_0x340a0f=_['merge']({},_0x340a0f,_0x19e5d7[_0xe4ba5b('0x16')]),_0x3aeac6[_0xe4ba5b('0x3f')](_0x340a0f);})[_0x3b2f41('0x1f')](function(_0x13e8cd){const _0x8e07dc=_0x3b2f41;if(_0x13e8cd)return _0x1d8a6d=_0x13e8cd['length'],typeof _0x19e5d7[_0x8e07dc('0x37')][_0x8e07dc('0x15')]===_0x8e07dc('0x34')&&(_0x340a0f[_0x8e07dc('0x17')]=qs['limit'](_0x19e5d7[_0x8e07dc('0x37')][_0x8e07dc('0x17')]),_0x340a0f[_0x8e07dc('0xa')]=qs['offset'](_0x19e5d7['query'][_0x8e07dc('0xa')])),_0x3aeac6['getTags'](_0x340a0f);})['then'](function(_0x48a96f){if(_0x48a96f)return _0x48a96f?{'count':_0x1d8a6d,'rows':_0x48a96f}:null;})[_0x3b2f41('0x1f')](respondWithResult(_0x355f63,null))[_0x3b2f41('0x32')](handleError(_0x355f63,null));},exports[_0x5394d3('0x1b')]=function(_0x186d13,_0x485f32){const _0x4acefa=_0x5394d3;return _0x186d13[_0x4acefa('0x36')]['id']&&delete _0x186d13[_0x4acefa('0x36')]['id'],db[_0x4acefa('0x19')][_0x4acefa('0x23')]({'where':{'id':_0x186d13[_0x4acefa('0x11')]['id']}})[_0x4acefa('0x1f')](handleEntityNotFound(_0x485f32,null))['then'](function(_0x222635){const _0x989a1a=_0x4acefa;if(_0x222635)return _0x222635[_0x989a1a('0x1b')](_0x186d13[_0x989a1a('0x36')][_0x989a1a('0x1c')]||[]);return null;})[_0x4acefa('0x1f')](respondWithResult(_0x485f32,null))['catch'](handleError(_0x485f32,null));}; \ No newline at end of file diff --git a/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.model.js b/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.model.js index 4483ce8..57dc9a2 100644 --- a/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.model.js +++ b/server/api/intFreshdeskConfiguration/intFreshdeskConfiguration.model.js @@ -1 +1 @@ -const a261_0x264d=['define','exports','FreshdeskConfiguration'];(function(_0x34c7e2,_0x264d33){const _0x3891eb=function(_0x36f270){while(--_0x36f270){_0x34c7e2['push'](_0x34c7e2['shift']());}};_0x3891eb(++_0x264d33);}(a261_0x264d,0x1dc));const a261_0x3891=function(_0x34c7e2,_0x264d33){_0x34c7e2=_0x34c7e2-0x0;let _0x3891eb=a261_0x264d[_0x34c7e2];return _0x3891eb;};const _0x1017fa=a261_0x3891;'use strict';const attributes=require('./intFreshdeskConfiguration.attributes');module[_0x1017fa('0x2')]=function(_0x36f270){const _0x46b5b3=_0x1017fa,_0x22d130=_0x36f270[_0x46b5b3('0x1')](_0x46b5b3('0x0'),attributes,{'tableName':'int_freshdesk_configurations','paranoid':![],'indexes':[],'timestamps':!![]});return _0x22d130;}; \ No newline at end of file +const a261_0x3210=['FreshdeskConfiguration','exports','int_freshdesk_configurations','define'];(function(_0x55a020,_0x321053){const _0x2f315a=function(_0x496148){while(--_0x496148){_0x55a020['push'](_0x55a020['shift']());}};_0x2f315a(++_0x321053);}(a261_0x3210,0x161));const a261_0x2f31=function(_0x55a020,_0x321053){_0x55a020=_0x55a020-0x0;let _0x2f315a=a261_0x3210[_0x55a020];return _0x2f315a;};const _0x5be42d=a261_0x2f31;'use strict';const attributes=require('./intFreshdeskConfiguration.attributes');module[_0x5be42d('0x0')]=function(_0x496148){const _0x2bb817=_0x5be42d,_0x1a9f5c=_0x496148[_0x2bb817('0x2')](_0x2bb817('0x3'),attributes,{'tableName':_0x2bb817('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1a9f5c;}; \ No newline at end of file diff --git a/server/api/intFreshdeskField/index.js b/server/api/intFreshdeskField/index.js index bb46e84..e07c7ee 100644 --- a/server/api/intFreshdeskField/index.js +++ b/server/api/intFreshdeskField/index.js @@ -1 +1 @@ -const a262_0x1204=['exports','Router','./intFreshdeskField.controller','show','put','/:id','create','get','index','express','delete','update','isAuthenticated','post'];(function(_0x47fa8c,_0x120435){const _0x4cc0cc=function(_0x10825a){while(--_0x10825a){_0x47fa8c['push'](_0x47fa8c['shift']());}};_0x4cc0cc(++_0x120435);}(a262_0x1204,0x124));const a262_0x4cc0=function(_0x47fa8c,_0x120435){_0x47fa8c=_0x47fa8c-0x0;let _0x4cc0cc=a262_0x1204[_0x47fa8c];return _0x4cc0cc;};const _0x58c27c=a262_0x4cc0;'use strict';const express=require(_0x58c27c('0xb')),router=express[_0x58c27c('0x3')](),auth=require('../../components/auth/service'),controller=require(_0x58c27c('0x4'));router[_0x58c27c('0x9')]('/',auth['isAuthenticated'](),controller[_0x58c27c('0xa')]),router[_0x58c27c('0x9')](_0x58c27c('0x7'),auth['isAuthenticated'](),controller[_0x58c27c('0x5')]),router[_0x58c27c('0x1')]('/',auth['isAuthenticated'](),controller[_0x58c27c('0x8')]),router[_0x58c27c('0x6')](_0x58c27c('0x7'),auth[_0x58c27c('0x0')](),controller[_0x58c27c('0xd')]),router[_0x58c27c('0xc')](_0x58c27c('0x7'),auth[_0x58c27c('0x0')](),controller['destroy']),module[_0x58c27c('0x2')]=router; \ No newline at end of file +const a262_0x4c0c=['destroy','put','/:id','Router','delete','show','get','express','exports','post','index','./intFreshdeskField.controller','../../components/auth/service','isAuthenticated'];(function(_0x5497c6,_0x4c0c24){const _0x26e099=function(_0x3e34c6){while(--_0x3e34c6){_0x5497c6['push'](_0x5497c6['shift']());}};_0x26e099(++_0x4c0c24);}(a262_0x4c0c,0x137));const a262_0x26e0=function(_0x5497c6,_0x4c0c24){_0x5497c6=_0x5497c6-0x0;let _0x26e099=a262_0x4c0c[_0x5497c6];return _0x26e099;};const _0x2b74a4=a262_0x26e0;'use strict';const express=require(_0x2b74a4('0x4')),router=express[_0x2b74a4('0x0')](),auth=require(_0x2b74a4('0x9')),controller=require(_0x2b74a4('0x8'));router[_0x2b74a4('0x3')]('/',auth[_0x2b74a4('0xa')](),controller[_0x2b74a4('0x7')]),router['get'](_0x2b74a4('0xd'),auth[_0x2b74a4('0xa')](),controller[_0x2b74a4('0x2')]),router[_0x2b74a4('0x6')]('/',auth['isAuthenticated'](),controller['create']),router[_0x2b74a4('0xc')](_0x2b74a4('0xd'),auth['isAuthenticated'](),controller['update']),router[_0x2b74a4('0x1')]('/:id',auth['isAuthenticated'](),controller[_0x2b74a4('0xb')]),module[_0x2b74a4('0x5')]=router; \ No newline at end of file diff --git a/server/api/intFreshdeskField/intFreshdeskField.attributes.js b/server/api/intFreshdeskField/intFreshdeskField.attributes.js index 83bbcb3..b1d5def 100644 --- a/server/api/intFreshdeskField/intFreshdeskField.attributes.js +++ b/server/api/intFreshdeskField/intFreshdeskField.attributes.js @@ -1 +1 @@ -const a263_0x1b1b=['ENUM','BOOLEAN','string','sequelize','variable','keyValue','customVariable','STRING'];(function(_0x11f4cf,_0x1b1bad){const _0x2a69ca=function(_0x3ed4f4){while(--_0x3ed4f4){_0x11f4cf['push'](_0x11f4cf['shift']());}};_0x2a69ca(++_0x1b1bad);}(a263_0x1b1b,0xeb));const a263_0x2a69=function(_0x11f4cf,_0x1b1bad){_0x11f4cf=_0x11f4cf-0x0;let _0x2a69ca=a263_0x1b1b[_0x11f4cf];return _0x2a69ca;};const _0x179147=a263_0x2a69;'use strict';const Sequelize=require(_0x179147('0x0'));module['exports']={'type':{'type':Sequelize[_0x179147('0x5')](_0x179147('0x7'),'variable','customVariable',_0x179147('0x2')),'defaultValue':_0x179147('0x7')},'content':{'type':Sequelize[_0x179147('0x4')]},'key':{'type':Sequelize['STRING']},'keyType':{'type':Sequelize[_0x179147('0x5')](_0x179147('0x7'),_0x179147('0x1'),_0x179147('0x3'))},'keyContent':{'type':Sequelize['STRING']},'idField':{'type':Sequelize['STRING']},'nameField':{'type':Sequelize[_0x179147('0x4')]},'customField':{'type':Sequelize[_0x179147('0x6')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x179147('0x4')]}}; \ No newline at end of file +const a263_0x7c6b=['sequelize','STRING','exports','variable','ENUM','customVariable','BOOLEAN','string'];(function(_0x477543,_0x7c6bfd){const _0x677e85=function(_0x1b6779){while(--_0x1b6779){_0x477543['push'](_0x477543['shift']());}};_0x677e85(++_0x7c6bfd);}(a263_0x7c6b,0xc2));const a263_0x677e=function(_0x477543,_0x7c6bfd){_0x477543=_0x477543-0x0;let _0x677e85=a263_0x7c6b[_0x477543];return _0x677e85;};const _0x42115b=a263_0x677e;'use strict';const Sequelize=require(_0x42115b('0x6'));module[_0x42115b('0x0')]={'type':{'type':Sequelize[_0x42115b('0x2')]('string',_0x42115b('0x1'),_0x42115b('0x3'),'keyValue'),'defaultValue':_0x42115b('0x5')},'content':{'type':Sequelize[_0x42115b('0x7')]},'key':{'type':Sequelize[_0x42115b('0x7')]},'keyType':{'type':Sequelize[_0x42115b('0x2')](_0x42115b('0x5'),'variable',_0x42115b('0x3'))},'keyContent':{'type':Sequelize['STRING']},'idField':{'type':Sequelize[_0x42115b('0x7')]},'nameField':{'type':Sequelize['STRING']},'customField':{'type':Sequelize[_0x42115b('0x4')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x42115b('0x7')]}}; \ No newline at end of file diff --git a/server/api/intFreshdeskField/intFreshdeskField.controller.js b/server/api/intFreshdeskField/intFreshdeskField.controller.js index c32e4ce..88e7f70 100644 --- a/server/api/intFreshdeskField/intFreshdeskField.controller.js +++ b/server/api/intFreshdeskField/intFreshdeskField.controller.js @@ -1 +1 @@ -const a264_0x2a3e=['send','params','create','status','fields','../../config/logger','sendStatus','intersection','body','sort','findAll','rawAttributes','nolimit','index','../../mysqldb','length','filters','attributes','options','map','where','keys','include','includeAll','model','VIRTUAL','findOne','name','error','stack','json','query','api','like','rows','filter','pick','limit','destroy','fieldName','then','offset','FreshdeskField','sequelize','update','merge','catch','type','count'];(function(_0x34412d,_0x2a3e8f){const _0x32e20e=function(_0x314b24){while(--_0x314b24){_0x34412d['push'](_0x34412d['shift']());}};_0x32e20e(++_0x2a3e8f);}(a264_0x2a3e,0xa7));const a264_0x32e2=function(_0x34412d,_0x2a3e8f){_0x34412d=_0x34412d-0x0;let _0x32e20e=a264_0x2a3e[_0x34412d];return _0x32e20e;};const _0x1a6ba5=a264_0x32e2;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x1a6ba5('0x22'))(_0x1a6ba5('0xc')),db=require(_0x1a6ba5('0x2b'))['db'],{Op}=require(_0x1a6ba5('0x17'));function respondWithResult(_0x314b24,_0x354088){return _0x354088=_0x354088||0xc8,function(_0xf82462){const _0x5e6a4b=a264_0x32e2;if(_0xf82462)return _0x314b24[_0x5e6a4b('0x20')](_0x354088)[_0x5e6a4b('0xa')](_0xf82462);};}function respondWithFilteredResult(_0x41f784,_0x2e4d30){return function(_0x455039){const _0x3a5848=a264_0x32e2;if(_0x455039){const _0x8b3427=_0x455039['count'],_0x486986=_0x2e4d30['offset'];let _0xbc768c=_0x2e4d30[_0x3a5848('0x15')]+_0x2e4d30['limit'],_0x4dcf7b;return _0xbc768c>=_0x8b3427?(_0xbc768c=_0x8b3427,_0x4dcf7b=0xc8):_0x4dcf7b=0xce,_0x41f784[_0x3a5848('0x20')](_0x4dcf7b),_0x41f784['set']('Content-Range',_0x486986+'-'+_0xbc768c+'/'+_0x8b3427)[_0x3a5848('0xa')](_0x455039);}return null;};}function saveUpdates(_0x54a1bb){return function(_0x2e2be2){const _0x20787c=a264_0x32e2;if(_0x2e2be2)return _0x2e2be2[_0x20787c('0x18')](_0x54a1bb)[_0x20787c('0x14')](function(_0x47b627){return _0x47b627;});return null;};}function removeEntity(_0x523214){return function(_0x51c8bb){const _0x484d37=a264_0x32e2;if(_0x51c8bb)return _0x51c8bb['destroy']()[_0x484d37('0x14')](function(){const _0x329e80=_0x484d37;_0x523214[_0x329e80('0x20')](0xcc)['end']();});};}function handleEntityNotFound(_0x2a39c8){return function(_0x45e688){const _0x2ea857=a264_0x32e2;return!_0x45e688&&_0x2a39c8[_0x2ea857('0x23')](0x194),_0x45e688;};}function handleError(_0x432251,_0x14dd6b){return _0x14dd6b=_0x14dd6b||0x1f4,function(_0x55a44f){const _0x1055a8=a264_0x32e2;logger[_0x1055a8('0x8')](_0x55a44f[_0x1055a8('0x9')]),_0x55a44f[_0x1055a8('0x7')]&&delete _0x55a44f['name'],_0x432251[_0x1055a8('0x20')](_0x14dd6b)[_0x1055a8('0x1d')](_0x55a44f);};}exports[_0x1a6ba5('0x2a')]=function(_0x5e0afe,_0x360076){const _0x799206=_0x1a6ba5;let _0x1c500f={};const _0x271a0b={},_0x4577e4={'count':0x0,'rows':[]},_0x150078=_[_0x799206('0x30')](db[_0x799206('0x16')][_0x799206('0x28')],function(_0x4f4969){const _0x38903a=_0x799206;return{'name':_0x4f4969[_0x38903a('0x13')],'type':_0x4f4969[_0x38903a('0x1b')]['key']};});_0x271a0b[_0x799206('0x4')]=_[_0x799206('0x30')](_0x150078,'name'),_0x271a0b['query']=_[_0x799206('0x1')](_0x5e0afe[_0x799206('0xb')]),_0x271a0b['filters']=_[_0x799206('0x24')](_0x271a0b[_0x799206('0x4')],_0x271a0b[_0x799206('0xb')]),_0x1c500f[_0x799206('0x2e')]=_['intersection'](_0x271a0b[_0x799206('0x4')],qs['fields'](_0x5e0afe['query'][_0x799206('0x21')])),_0x1c500f[_0x799206('0x2e')]=_0x1c500f[_0x799206('0x2e')][_0x799206('0x2c')]?_0x1c500f['attributes']:_0x271a0b['model'];typeof _0x5e0afe[_0x799206('0xb')][_0x799206('0x29')]==='undefined'&&(_0x1c500f[_0x799206('0x11')]=qs['limit'](_0x5e0afe[_0x799206('0xb')][_0x799206('0x11')]),_0x1c500f[_0x799206('0x15')]=qs[_0x799206('0x15')](_0x5e0afe['query'][_0x799206('0x15')]));_0x1c500f['order']=qs[_0x799206('0x26')](_0x5e0afe[_0x799206('0xb')][_0x799206('0x26')]),_0x1c500f[_0x799206('0x0')]=qs[_0x799206('0x2d')](_[_0x799206('0x10')](_0x5e0afe[_0x799206('0xb')],_0x271a0b[_0x799206('0x2d')]),_0x150078);_0x5e0afe['query'][_0x799206('0xf')]&&(_0x1c500f['where']=_[_0x799206('0x19')](_0x1c500f[_0x799206('0x0')],{[Op['or']]:_[_0x799206('0x30')](_0x150078,function(_0x5e99e2){const _0x2db283=_0x799206;if(_0x5e99e2['type']!==_0x2db283('0x5')){const _0x446265={};return _0x446265[_0x5e99e2[_0x2db283('0x7')]]={[Op[_0x2db283('0xd')]]:'%'+_0x5e0afe[_0x2db283('0xb')][_0x2db283('0xf')]+'%'},_0x446265;}})}));_0x1c500f=_[_0x799206('0x19')]({},_0x1c500f,_0x5e0afe['options']);const _0x424c8c={'where':_0x1c500f['where']};return db['FreshdeskField'][_0x799206('0x1c')](_0x424c8c)['then'](function(_0x513959){const _0x193ee9=_0x799206;return _0x4577e4[_0x193ee9('0x1c')]=_0x513959,_0x5e0afe[_0x193ee9('0xb')][_0x193ee9('0x3')]&&(_0x1c500f['include']=[{'all':!![]}]),db[_0x193ee9('0x16')][_0x193ee9('0x27')](_0x1c500f);})[_0x799206('0x14')](function(_0x1096ca){const _0x1d854a=_0x799206;return _0x4577e4[_0x1d854a('0xe')]=_0x1096ca,_0x4577e4;})[_0x799206('0x14')](respondWithFilteredResult(_0x360076,_0x1c500f))[_0x799206('0x1a')](handleError(_0x360076,null));},exports['show']=function(_0x50af50,_0x4e7497){const _0x370d7d=_0x1a6ba5;let _0x60a136={'raw':!![],'where':{'id':_0x50af50[_0x370d7d('0x1e')]['id']}};const _0x2d5dc7={};return _0x2d5dc7['model']=_['keys'](db[_0x370d7d('0x16')][_0x370d7d('0x28')]),_0x2d5dc7[_0x370d7d('0xb')]=_[_0x370d7d('0x1')](_0x50af50['query']),_0x2d5dc7[_0x370d7d('0x2d')]=_[_0x370d7d('0x24')](_0x2d5dc7['model'],_0x2d5dc7['query']),_0x60a136[_0x370d7d('0x2e')]=_['intersection'](_0x2d5dc7[_0x370d7d('0x4')],qs[_0x370d7d('0x21')](_0x50af50[_0x370d7d('0xb')][_0x370d7d('0x21')])),_0x60a136[_0x370d7d('0x2e')]=_0x60a136[_0x370d7d('0x2e')]['length']?_0x60a136[_0x370d7d('0x2e')]:_0x2d5dc7[_0x370d7d('0x4')],_0x50af50[_0x370d7d('0xb')][_0x370d7d('0x3')]&&(_0x60a136[_0x370d7d('0x2')]=[{'all':!![]}]),_0x60a136=_['merge']({},_0x60a136,_0x50af50[_0x370d7d('0x2f')]),db[_0x370d7d('0x16')][_0x370d7d('0x6')](_0x60a136)[_0x370d7d('0x14')](handleEntityNotFound(_0x4e7497,null))[_0x370d7d('0x14')](respondWithResult(_0x4e7497,null))[_0x370d7d('0x1a')](handleError(_0x4e7497,null));},exports['create']=function(_0x476099,_0x2d296a){const _0x4cf05d=_0x1a6ba5;return db['FreshdeskField'][_0x4cf05d('0x1f')](_0x476099[_0x4cf05d('0x25')],{})['then'](respondWithResult(_0x2d296a,0xc9))['catch'](handleError(_0x2d296a,null));},exports[_0x1a6ba5('0x18')]=function(_0xa82425,_0x3cb419){const _0x563221=_0x1a6ba5;return _0xa82425[_0x563221('0x25')]['id']&&delete _0xa82425[_0x563221('0x25')]['id'],db['FreshdeskField'][_0x563221('0x6')]({'where':{'id':_0xa82425['params']['id']}})[_0x563221('0x14')](handleEntityNotFound(_0x3cb419,null))[_0x563221('0x14')](saveUpdates(_0xa82425[_0x563221('0x25')],null))[_0x563221('0x14')](respondWithResult(_0x3cb419,null))['catch'](handleError(_0x3cb419,null));},exports[_0x1a6ba5('0x12')]=function(_0x23dbd4,_0xc03ee){const _0x38bfc4=_0x1a6ba5;return db[_0x38bfc4('0x16')][_0x38bfc4('0x6')]({'where':{'id':_0x23dbd4[_0x38bfc4('0x1e')]['id']}})[_0x38bfc4('0x14')](handleEntityNotFound(_0xc03ee,null))[_0x38bfc4('0x14')](removeEntity(_0xc03ee,null))[_0x38bfc4('0x1a')](handleError(_0xc03ee,null));}; \ No newline at end of file +const a264_0x17f3=['include','name','attributes','merge','body','VIRTUAL','options','sort','api','create','map','status','end','filter','destroy','fields','type','like','where','lodash','Content-Range','length','undefined','rawAttributes','sendStatus','query','show','error','../../mysqldb','set','model','limit','FreshdeskField','stack','index','send','intersection','../../config/logger','keys','includeAll','then','offset','catch','update','rows','count','findOne','params','filters','findAll','json'];(function(_0x4bd251,_0x17f3cd){const _0x545fba=function(_0x15d7a4){while(--_0x15d7a4){_0x4bd251['push'](_0x4bd251['shift']());}};_0x545fba(++_0x17f3cd);}(a264_0x17f3,0xa7));const a264_0x545f=function(_0x4bd251,_0x17f3cd){_0x4bd251=_0x4bd251-0x0;let _0x545fba=a264_0x17f3[_0x4bd251];return _0x545fba;};const _0x4aa3fd=a264_0x545f;'use strict';const _=require(_0x4aa3fd('0x5')),qs=require('../../components/parsers/qs'),logger=require(_0x4aa3fd('0x17'))(_0x4aa3fd('0x2d')),db=require(_0x4aa3fd('0xe'))['db'],{Op}=require('sequelize');function respondWithResult(_0x15d7a4,_0xf57761){return _0xf57761=_0xf57761||0xc8,function(_0x47ddbb){const _0x5bfe99=a264_0x545f;if(_0x47ddbb)return _0x15d7a4['status'](_0xf57761)[_0x5bfe99('0x24')](_0x47ddbb);};}function respondWithFilteredResult(_0x383953,_0x33535f){return function(_0x2468ac){const _0x29db92=a264_0x545f;if(_0x2468ac){const _0x5684bc=_0x2468ac[_0x29db92('0x1f')],_0x3d18c2=_0x33535f['offset'];let _0x4d851d=_0x33535f[_0x29db92('0x1b')]+_0x33535f[_0x29db92('0x11')],_0x2ddc1a;return _0x4d851d>=_0x5684bc?(_0x4d851d=_0x5684bc,_0x2ddc1a=0xc8):_0x2ddc1a=0xce,_0x383953['status'](_0x2ddc1a),_0x383953[_0x29db92('0xf')](_0x29db92('0x6'),_0x3d18c2+'-'+_0x4d851d+'/'+_0x5684bc)[_0x29db92('0x24')](_0x2468ac);}return null;};}function saveUpdates(_0x45723d){return function(_0x2cd1b1){const _0x167847=a264_0x545f;if(_0x2cd1b1)return _0x2cd1b1['update'](_0x45723d)[_0x167847('0x1a')](function(_0xec8c0f){return _0xec8c0f;});return null;};}function removeEntity(_0x594a27){return function(_0x3170ad){const _0x57a787=a264_0x545f;if(_0x3170ad)return _0x3170ad['destroy']()[_0x57a787('0x1a')](function(){const _0x1fe0c3=_0x57a787;_0x594a27[_0x1fe0c3('0x30')](0xcc)[_0x1fe0c3('0x31')]();});};}function handleEntityNotFound(_0x5b9990){return function(_0x2c2f30){const _0x519d0e=a264_0x545f;return!_0x2c2f30&&_0x5b9990[_0x519d0e('0xa')](0x194),_0x2c2f30;};}function handleError(_0x58881f,_0x5e6202){return _0x5e6202=_0x5e6202||0x1f4,function(_0x5938ec){const _0x1e4a84=a264_0x545f;logger[_0x1e4a84('0xd')](_0x5938ec[_0x1e4a84('0x13')]),_0x5938ec[_0x1e4a84('0x26')]&&delete _0x5938ec[_0x1e4a84('0x26')],_0x58881f['status'](_0x5e6202)[_0x1e4a84('0x15')](_0x5938ec);};}exports[_0x4aa3fd('0x14')]=function(_0x3f2a23,_0x247cce){const _0x55cc02=_0x4aa3fd;let _0x556452={};const _0x4f5bc3={},_0x6f2c52={'count':0x0,'rows':[]},_0x4319fe=_[_0x55cc02('0x2f')](db[_0x55cc02('0x12')][_0x55cc02('0x9')],function(_0x541c3e){return{'name':_0x541c3e['fieldName'],'type':_0x541c3e['type']['key']};});_0x4f5bc3[_0x55cc02('0x10')]=_['map'](_0x4319fe,_0x55cc02('0x26')),_0x4f5bc3['query']=_['keys'](_0x3f2a23['query']),_0x4f5bc3['filters']=_['intersection'](_0x4f5bc3[_0x55cc02('0x10')],_0x4f5bc3['query']),_0x556452[_0x55cc02('0x27')]=_['intersection'](_0x4f5bc3[_0x55cc02('0x10')],qs[_0x55cc02('0x1')](_0x3f2a23['query'][_0x55cc02('0x1')])),_0x556452['attributes']=_0x556452[_0x55cc02('0x27')][_0x55cc02('0x7')]?_0x556452[_0x55cc02('0x27')]:_0x4f5bc3[_0x55cc02('0x10')];typeof _0x3f2a23[_0x55cc02('0xb')]['nolimit']===_0x55cc02('0x8')&&(_0x556452[_0x55cc02('0x11')]=qs[_0x55cc02('0x11')](_0x3f2a23['query']['limit']),_0x556452[_0x55cc02('0x1b')]=qs[_0x55cc02('0x1b')](_0x3f2a23[_0x55cc02('0xb')][_0x55cc02('0x1b')]));_0x556452['order']=qs[_0x55cc02('0x2c')](_0x3f2a23[_0x55cc02('0xb')][_0x55cc02('0x2c')]),_0x556452['where']=qs[_0x55cc02('0x22')](_['pick'](_0x3f2a23[_0x55cc02('0xb')],_0x4f5bc3[_0x55cc02('0x22')]),_0x4319fe);_0x3f2a23['query'][_0x55cc02('0x32')]&&(_0x556452[_0x55cc02('0x4')]=_[_0x55cc02('0x28')](_0x556452[_0x55cc02('0x4')],{[Op['or']]:_['map'](_0x4319fe,function(_0xaf07e8){const _0x309b4d=_0x55cc02;if(_0xaf07e8[_0x309b4d('0x2')]!==_0x309b4d('0x2a')){const _0x4b9a2b={};return _0x4b9a2b[_0xaf07e8[_0x309b4d('0x26')]]={[Op[_0x309b4d('0x3')]]:'%'+_0x3f2a23[_0x309b4d('0xb')][_0x309b4d('0x32')]+'%'},_0x4b9a2b;}})}));_0x556452=_[_0x55cc02('0x28')]({},_0x556452,_0x3f2a23[_0x55cc02('0x2b')]);const _0x4397dc={'where':_0x556452[_0x55cc02('0x4')]};return db[_0x55cc02('0x12')]['count'](_0x4397dc)[_0x55cc02('0x1a')](function(_0x2929a5){const _0x11e14a=_0x55cc02;return _0x6f2c52['count']=_0x2929a5,_0x3f2a23['query'][_0x11e14a('0x19')]&&(_0x556452[_0x11e14a('0x25')]=[{'all':!![]}]),db[_0x11e14a('0x12')][_0x11e14a('0x23')](_0x556452);})[_0x55cc02('0x1a')](function(_0xec066c){const _0x1e392e=_0x55cc02;return _0x6f2c52[_0x1e392e('0x1e')]=_0xec066c,_0x6f2c52;})[_0x55cc02('0x1a')](respondWithFilteredResult(_0x247cce,_0x556452))[_0x55cc02('0x1c')](handleError(_0x247cce,null));},exports[_0x4aa3fd('0xc')]=function(_0x952ad9,_0x5a3a8e){const _0x4a3d46=_0x4aa3fd;let _0x5326d2={'raw':!![],'where':{'id':_0x952ad9[_0x4a3d46('0x21')]['id']}};const _0x2e6d05={};return _0x2e6d05[_0x4a3d46('0x10')]=_[_0x4a3d46('0x18')](db[_0x4a3d46('0x12')][_0x4a3d46('0x9')]),_0x2e6d05[_0x4a3d46('0xb')]=_[_0x4a3d46('0x18')](_0x952ad9[_0x4a3d46('0xb')]),_0x2e6d05[_0x4a3d46('0x22')]=_[_0x4a3d46('0x16')](_0x2e6d05[_0x4a3d46('0x10')],_0x2e6d05[_0x4a3d46('0xb')]),_0x5326d2[_0x4a3d46('0x27')]=_['intersection'](_0x2e6d05[_0x4a3d46('0x10')],qs['fields'](_0x952ad9[_0x4a3d46('0xb')][_0x4a3d46('0x1')])),_0x5326d2[_0x4a3d46('0x27')]=_0x5326d2[_0x4a3d46('0x27')]['length']?_0x5326d2[_0x4a3d46('0x27')]:_0x2e6d05['model'],_0x952ad9[_0x4a3d46('0xb')][_0x4a3d46('0x19')]&&(_0x5326d2[_0x4a3d46('0x25')]=[{'all':!![]}]),_0x5326d2=_[_0x4a3d46('0x28')]({},_0x5326d2,_0x952ad9[_0x4a3d46('0x2b')]),db[_0x4a3d46('0x12')]['findOne'](_0x5326d2)['then'](handleEntityNotFound(_0x5a3a8e,null))[_0x4a3d46('0x1a')](respondWithResult(_0x5a3a8e,null))[_0x4a3d46('0x1c')](handleError(_0x5a3a8e,null));},exports['create']=function(_0x322ddd,_0x345b89){const _0x11a1e1=_0x4aa3fd;return db[_0x11a1e1('0x12')][_0x11a1e1('0x2e')](_0x322ddd[_0x11a1e1('0x29')],{})[_0x11a1e1('0x1a')](respondWithResult(_0x345b89,0xc9))[_0x11a1e1('0x1c')](handleError(_0x345b89,null));},exports[_0x4aa3fd('0x1d')]=function(_0x249991,_0x2718a1){const _0x1bf3d1=_0x4aa3fd;return _0x249991[_0x1bf3d1('0x29')]['id']&&delete _0x249991['body']['id'],db[_0x1bf3d1('0x12')][_0x1bf3d1('0x20')]({'where':{'id':_0x249991[_0x1bf3d1('0x21')]['id']}})[_0x1bf3d1('0x1a')](handleEntityNotFound(_0x2718a1,null))[_0x1bf3d1('0x1a')](saveUpdates(_0x249991[_0x1bf3d1('0x29')],null))[_0x1bf3d1('0x1a')](respondWithResult(_0x2718a1,null))[_0x1bf3d1('0x1c')](handleError(_0x2718a1,null));},exports[_0x4aa3fd('0x0')]=function(_0x20149f,_0xbcbbba){const _0x139b20=_0x4aa3fd;return db[_0x139b20('0x12')][_0x139b20('0x20')]({'where':{'id':_0x20149f[_0x139b20('0x21')]['id']}})[_0x139b20('0x1a')](handleEntityNotFound(_0xbcbbba,null))[_0x139b20('0x1a')](removeEntity(_0xbcbbba,null))[_0x139b20('0x1c')](handleError(_0xbcbbba,null));}; \ No newline at end of file diff --git a/server/api/intFreshdeskField/intFreshdeskField.model.js b/server/api/intFreshdeskField/intFreshdeskField.model.js index 1b7791c..1506158 100644 --- a/server/api/intFreshdeskField/intFreshdeskField.model.js +++ b/server/api/intFreshdeskField/intFreshdeskField.model.js @@ -1 +1 @@ -const a265_0x11ca=['FieldId','idField','exports','int_freshdesk_fields','freshdesk_unique_index','./intFreshdeskField.attributes','define','FreshdeskField'];(function(_0x389e6b,_0x11ca26){const _0x283229=function(_0x6cf1e){while(--_0x6cf1e){_0x389e6b['push'](_0x389e6b['shift']());}};_0x283229(++_0x11ca26);}(a265_0x11ca,0x81));const a265_0x2832=function(_0x389e6b,_0x11ca26){_0x389e6b=_0x389e6b-0x0;let _0x283229=a265_0x11ca[_0x389e6b];return _0x283229;};const _0x3ce55f=a265_0x2832;'use strict';const attributes=require(_0x3ce55f('0x4'));module[_0x3ce55f('0x1')]=function(_0x6cf1e){const _0x264e3b=_0x3ce55f,_0x5183e8=_0x6cf1e[_0x264e3b('0x5')](_0x264e3b('0x6'),attributes,{'tableName':_0x264e3b('0x2'),'paranoid':![],'indexes':[{'name':_0x264e3b('0x3'),'fields':[_0x264e3b('0x0'),_0x264e3b('0x7')],'unique':!![]}],'timestamps':!![]});return _0x5183e8;}; \ No newline at end of file +const a265_0x101a=['exports','int_freshdesk_fields','freshdesk_unique_index','FieldId','define','./intFreshdeskField.attributes','idField'];(function(_0x3ffff7,_0x101ae2){const _0x26d0b7=function(_0x2bb6eb){while(--_0x2bb6eb){_0x3ffff7['push'](_0x3ffff7['shift']());}};_0x26d0b7(++_0x101ae2);}(a265_0x101a,0xe1));const a265_0x26d0=function(_0x3ffff7,_0x101ae2){_0x3ffff7=_0x3ffff7-0x0;let _0x26d0b7=a265_0x101a[_0x3ffff7];return _0x26d0b7;};const _0x4aac26=a265_0x26d0;'use strict';const attributes=require(_0x4aac26('0x4'));module[_0x4aac26('0x6')]=function(_0x2bb6eb){const _0x363076=_0x4aac26,_0x4a2c62=_0x2bb6eb[_0x363076('0x3')]('FreshdeskField',attributes,{'tableName':_0x363076('0x0'),'paranoid':![],'indexes':[{'name':_0x363076('0x1'),'fields':[_0x363076('0x5'),_0x363076('0x2')],'unique':!![]}],'timestamps':!![]});return _0x4a2c62;}; \ No newline at end of file diff --git a/server/api/intFreshsalesAccount/index.js b/server/api/intFreshsalesAccount/index.js index 4190665..95fafce 100644 --- a/server/api/intFreshsalesAccount/index.js +++ b/server/api/intFreshsalesAccount/index.js @@ -1 +1 @@ -const a266_0x1519=['./intFreshsalesAccount.controller','addConfiguration','isAuthenticated','getConfigurations','/:id/configurations','destroy','index','put','delete','update','getFields','show','/:id','exports','get','express','post','/:id/fields'];(function(_0x331df3,_0x15193a){const _0x920d78=function(_0x3002a5){while(--_0x3002a5){_0x331df3['push'](_0x331df3['shift']());}};_0x920d78(++_0x15193a);}(a266_0x1519,0x7d));const a266_0x920d=function(_0x331df3,_0x15193a){_0x331df3=_0x331df3-0x0;let _0x920d78=a266_0x1519[_0x331df3];return _0x920d78;};const _0x3ba84d=a266_0x920d;'use strict';const express=require(_0x3ba84d('0x10')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x3ba84d('0x1'));router[_0x3ba84d('0xf')]('/',auth[_0x3ba84d('0x3')](),controller[_0x3ba84d('0x7')]),router[_0x3ba84d('0xf')](_0x3ba84d('0xd'),auth[_0x3ba84d('0x3')](),controller[_0x3ba84d('0xc')]),router[_0x3ba84d('0xf')](_0x3ba84d('0x5'),auth[_0x3ba84d('0x3')](),controller[_0x3ba84d('0x4')]),router[_0x3ba84d('0xf')](_0x3ba84d('0x0'),auth[_0x3ba84d('0x3')](),controller[_0x3ba84d('0xb')]),router[_0x3ba84d('0x11')]('/',auth[_0x3ba84d('0x3')](),controller['create']),router['post'](_0x3ba84d('0x5'),auth[_0x3ba84d('0x3')](),controller[_0x3ba84d('0x2')]),router[_0x3ba84d('0x8')]('/:id',auth[_0x3ba84d('0x3')](),controller[_0x3ba84d('0xa')]),router[_0x3ba84d('0x9')](_0x3ba84d('0xd'),auth['isAuthenticated'](),controller[_0x3ba84d('0x6')]),module[_0x3ba84d('0xe')]=router; \ No newline at end of file +const a266_0x19bb=['show','create','put','post','get','Router','delete','/:id','./intFreshsalesAccount.controller','/:id/fields','addConfiguration','destroy','express','isAuthenticated','getFields','update','/:id/configurations','../../components/auth/service','exports','index'];(function(_0x62937f,_0x19bb6a){const _0xdb440c=function(_0x17f6a3){while(--_0x17f6a3){_0x62937f['push'](_0x62937f['shift']());}};_0xdb440c(++_0x19bb6a);}(a266_0x19bb,0x129));const a266_0xdb44=function(_0x62937f,_0x19bb6a){_0x62937f=_0x62937f-0x0;let _0xdb440c=a266_0x19bb[_0x62937f];return _0xdb440c;};const _0x168cc3=a266_0xdb44;'use strict';const express=require(_0x168cc3('0xf')),router=express[_0x168cc3('0x8')](),auth=require(_0x168cc3('0x0')),controller=require(_0x168cc3('0xb'));router[_0x168cc3('0x7')]('/',auth['isAuthenticated'](),controller[_0x168cc3('0x2')]),router[_0x168cc3('0x7')](_0x168cc3('0xa'),auth[_0x168cc3('0x10')](),controller[_0x168cc3('0x3')]),router['get'](_0x168cc3('0x13'),auth[_0x168cc3('0x10')](),controller['getConfigurations']),router[_0x168cc3('0x7')](_0x168cc3('0xc'),auth[_0x168cc3('0x10')](),controller[_0x168cc3('0x11')]),router[_0x168cc3('0x6')]('/',auth[_0x168cc3('0x10')](),controller[_0x168cc3('0x4')]),router[_0x168cc3('0x6')]('/:id/configurations',auth[_0x168cc3('0x10')](),controller[_0x168cc3('0xd')]),router[_0x168cc3('0x5')]('/:id',auth[_0x168cc3('0x10')](),controller[_0x168cc3('0x12')]),router[_0x168cc3('0x9')]('/:id',auth[_0x168cc3('0x10')](),controller[_0x168cc3('0xe')]),module[_0x168cc3('0x1')]=router; \ No newline at end of file diff --git a/server/api/intFreshsalesAccount/intFreshsalesAccount.attributes.js b/server/api/intFreshsalesAccount/intFreshsalesAccount.attributes.js index eb8e561..b0b0a55 100644 --- a/server/api/intFreshsalesAccount/intFreshsalesAccount.attributes.js +++ b/server/api/intFreshsalesAccount/intFreshsalesAccount.attributes.js @@ -1 +1 @@ -const a267_0x4639=['STRING','remoteUri','username'];(function(_0x3de242,_0x4639ef){const _0x463605=function(_0x495b41){while(--_0x495b41){_0x3de242['push'](_0x3de242['shift']());}};_0x463605(++_0x4639ef);}(a267_0x4639,0x1ca));const a267_0x4636=function(_0x3de242,_0x4639ef){_0x3de242=_0x3de242-0x0;let _0x463605=a267_0x4639[_0x3de242];return _0x463605;};const _0x431fb9=a267_0x4636;'use strict';const Sequelize=require('sequelize');module['exports']={'name':{'type':Sequelize[_0x431fb9('0x1')]},'description':{'type':Sequelize[_0x431fb9('0x1')]},'username':{'type':Sequelize[_0x431fb9('0x1')],'unique':_0x431fb9('0x0')},'apiKey':{'type':Sequelize[_0x431fb9('0x1')]},'remoteUri':{'type':Sequelize[_0x431fb9('0x1')],'unique':_0x431fb9('0x2')},'serverUrl':{'type':Sequelize[_0x431fb9('0x1')]}}; \ No newline at end of file +const a267_0x31b4=['remoteUri','username','exports','STRING'];(function(_0x415df9,_0x31b409){const _0x3cb8df=function(_0x587be8){while(--_0x587be8){_0x415df9['push'](_0x415df9['shift']());}};_0x3cb8df(++_0x31b409);}(a267_0x31b4,0x7b));const a267_0x3cb8=function(_0x415df9,_0x31b409){_0x415df9=_0x415df9-0x0;let _0x3cb8df=a267_0x31b4[_0x415df9];return _0x3cb8df;};const _0x4919d5=a267_0x3cb8;'use strict';const Sequelize=require('sequelize');module[_0x4919d5('0x3')]={'name':{'type':Sequelize[_0x4919d5('0x0')]},'description':{'type':Sequelize[_0x4919d5('0x0')]},'username':{'type':Sequelize['STRING'],'unique':_0x4919d5('0x2')},'apiKey':{'type':Sequelize[_0x4919d5('0x0')]},'remoteUri':{'type':Sequelize[_0x4919d5('0x0')],'unique':_0x4919d5('0x1')},'serverUrl':{'type':Sequelize[_0x4919d5('0x0')]}}; \ No newline at end of file diff --git a/server/api/intFreshsalesAccount/intFreshsalesAccount.controller.js b/server/api/intFreshsalesAccount/intFreshsalesAccount.controller.js index e58ec49..3d1f8c4 100644 --- a/server/api/intFreshsalesAccount/intFreshsalesAccount.controller.js +++ b/server/api/intFreshsalesAccount/intFreshsalesAccount.controller.js @@ -1 +1 @@ -const a268_0x46ed=['model','order','apiKey','offset','rows','fields','FreshsalesField','create','Content-Range','catch','../../config/logger','query','AccountId','test','format','map','getFields','slice','GET','username','end','body','channel','merge','findAll','fieldName','request-promise-native','substring','Requested\x20Resource\x20not\x20Found','length','stack','options','../../components/integrations/configuration','attributes','filter','include','filters','FreshsalesConfiguration','includeAll','send','type','destroy','count','lastIndexOf','statusCode','then','error','undefined','getConfigurations','name','where','VIRTUAL','show','Descriptions','nolimit','stringify','remoteUri','status','sort','getDescriptions','getSubjects','rawAttributes','limit','users','Token\x20token=','email','Subjects','FreshsalesAccount','%s%s','sequelize','util','keys','../../components/parsers/qs','../../mysqldb','findOne','params','lodash','intersection','like','getFields,\x20%s,\x20%s,\x20%s'];(function(_0x285c40,_0x46ed02){const _0x2fc82d=function(_0x49c4b4){while(--_0x49c4b4){_0x285c40['push'](_0x285c40['shift']());}};_0x2fc82d(++_0x46ed02);}(a268_0x46ed,0x149));const a268_0x2fc8=function(_0x285c40,_0x46ed02){_0x285c40=_0x285c40-0x0;let _0x2fc82d=a268_0x46ed[_0x285c40];return _0x2fc82d;};const _0xe37b2a=a268_0x2fc8;'use strict';const rp=require(_0xe37b2a('0x11')),util=require(_0xe37b2a('0x3d')),_=require(_0xe37b2a('0x43')),qs=require(_0xe37b2a('0x3f')),logger=require(_0xe37b2a('0x1'))('api'),db=require(_0xe37b2a('0x40'))['db'],{Op}=require(_0xe37b2a('0x3c')),integrations=require(_0xe37b2a('0x17'));function respondWithResult(_0x49c4b4,_0x132185){return _0x132185=_0x132185||0xc8,function(_0x111916){const _0x308e7c=a268_0x2fc8;if(_0x111916)return _0x49c4b4[_0x308e7c('0x30')](_0x132185)['json'](_0x111916);};}function respondWithFilteredResult(_0x230f1a,_0x2eca5f){return function(_0x58c943){const _0x357a14=a268_0x2fc8;if(_0x58c943){const _0x1c6fc4=_0x58c943['count'],_0x2f9f93=_0x2eca5f[_0x357a14('0x4a')];let _0x2a9c32=_0x2eca5f[_0x357a14('0x4a')]+_0x2eca5f[_0x357a14('0x35')],_0x5d5a1f;return _0x2a9c32>=_0x1c6fc4?(_0x2a9c32=_0x1c6fc4,_0x5d5a1f=0xc8):_0x5d5a1f=0xce,_0x230f1a[_0x357a14('0x30')](_0x5d5a1f),_0x230f1a['set'](_0x357a14('0x4f'),_0x2f9f93+'-'+_0x2a9c32+'/'+_0x1c6fc4)['json'](_0x58c943);}return null;};}function saveUpdates(_0x4fc7ec){return function(_0x21419f){if(_0x21419f)return _0x21419f['update'](_0x4fc7ec)['then'](function(_0x5c64cd){return _0x5c64cd;});return null;};}function removeEntity(_0x90ee5){return function(_0x1a9680){if(_0x1a9680)return _0x1a9680['destroy']()['then'](function(){const _0x1cedda=a268_0x2fc8;_0x90ee5['status'](0xcc)[_0x1cedda('0xb')]();});};}function handleEntityNotFound(_0x2a9f2e){return function(_0x21c0f1){return!_0x21c0f1&&_0x2a9f2e['sendStatus'](0x194),_0x21c0f1;};}function handleError(_0x395a1f,_0x46dce9){return _0x46dce9=_0x46dce9||0x1f4,function(_0x1f4724){const _0x2b297c=a268_0x2fc8;logger[_0x2b297c('0x25')](_0x1f4724[_0x2b297c('0x15')]),_0x1f4724['name']&&delete _0x1f4724['name'],_0x395a1f['status'](_0x46dce9)[_0x2b297c('0x1e')](_0x1f4724);};}exports['index']=function(_0x38ebb8,_0x232af0){const _0x445b1f=_0xe37b2a;let _0x576750={};const _0x513e06={},_0x375027={'count':0x0,'rows':[]},_0xb13ead=_[_0x445b1f('0x6')](db[_0x445b1f('0x3a')][_0x445b1f('0x34')],function(_0x31d62d){const _0x9baa1a=_0x445b1f;return{'name':_0x31d62d[_0x9baa1a('0x10')],'type':_0x31d62d[_0x9baa1a('0x1f')]['key']};});_0x513e06[_0x445b1f('0x47')]=_['map'](_0xb13ead,'name'),_0x513e06[_0x445b1f('0x2')]=_[_0x445b1f('0x3e')](_0x38ebb8[_0x445b1f('0x2')]),_0x513e06[_0x445b1f('0x1b')]=_[_0x445b1f('0x44')](_0x513e06[_0x445b1f('0x47')],_0x513e06[_0x445b1f('0x2')]),_0x576750['attributes']=_[_0x445b1f('0x44')](_0x513e06['model'],qs[_0x445b1f('0x4c')](_0x38ebb8[_0x445b1f('0x2')][_0x445b1f('0x4c')])),_0x576750[_0x445b1f('0x18')]=_0x576750[_0x445b1f('0x18')][_0x445b1f('0x14')]?_0x576750['attributes']:_0x513e06[_0x445b1f('0x47')];typeof _0x38ebb8[_0x445b1f('0x2')][_0x445b1f('0x2d')]===_0x445b1f('0x26')&&(_0x576750[_0x445b1f('0x35')]=qs[_0x445b1f('0x35')](_0x38ebb8[_0x445b1f('0x2')][_0x445b1f('0x35')]),_0x576750['offset']=qs[_0x445b1f('0x4a')](_0x38ebb8[_0x445b1f('0x2')][_0x445b1f('0x4a')]));_0x576750[_0x445b1f('0x48')]=qs['sort'](_0x38ebb8[_0x445b1f('0x2')][_0x445b1f('0x31')]),_0x576750['where']=qs['filters'](_['pick'](_0x38ebb8['query'],_0x513e06['filters']),_0xb13ead);_0x38ebb8[_0x445b1f('0x2')][_0x445b1f('0x19')]&&(_0x576750[_0x445b1f('0x29')]=_[_0x445b1f('0xe')](_0x576750[_0x445b1f('0x29')],{[Op['or']]:_['map'](_0xb13ead,function(_0xd11f88){const _0x19daf6=_0x445b1f;if(_0xd11f88[_0x19daf6('0x1f')]!==_0x19daf6('0x2a')){const _0x508a57={};return _0x508a57[_0xd11f88[_0x19daf6('0x28')]]={[Op[_0x19daf6('0x45')]]:'%'+_0x38ebb8['query'][_0x19daf6('0x19')]+'%'},_0x508a57;}})}));_0x576750=_[_0x445b1f('0xe')]({},_0x576750,_0x38ebb8[_0x445b1f('0x16')]);const _0x4eac16={'where':_0x576750[_0x445b1f('0x29')]};return db[_0x445b1f('0x3a')][_0x445b1f('0x21')](_0x4eac16)['then'](function(_0x243bd7){const _0x573e73=_0x445b1f;return _0x375027[_0x573e73('0x21')]=_0x243bd7,_0x38ebb8['query'][_0x573e73('0x1d')]&&(_0x576750[_0x573e73('0x1a')]=[{'all':!![]}]),db['FreshsalesAccount'][_0x573e73('0xf')](_0x576750);})[_0x445b1f('0x24')](function(_0x3c51d){const _0x3ce508=_0x445b1f;return _0x375027[_0x3ce508('0x4b')]=_0x3c51d,_0x375027;})['then'](respondWithFilteredResult(_0x232af0,_0x576750))['catch'](handleError(_0x232af0,null));},exports[_0xe37b2a('0x2b')]=function(_0x295d29,_0x516df4){const _0x4e2e0e=_0xe37b2a;let _0x344010={'raw':![],'where':{'id':_0x295d29[_0x4e2e0e('0x42')]['id']}};const _0x1e1ae5={};return _0x1e1ae5[_0x4e2e0e('0x47')]=_[_0x4e2e0e('0x3e')](db[_0x4e2e0e('0x3a')][_0x4e2e0e('0x34')]),_0x1e1ae5[_0x4e2e0e('0x2')]=_[_0x4e2e0e('0x3e')](_0x295d29['query']),_0x1e1ae5[_0x4e2e0e('0x1b')]=_[_0x4e2e0e('0x44')](_0x1e1ae5[_0x4e2e0e('0x47')],_0x1e1ae5['query']),_0x344010[_0x4e2e0e('0x18')]=_['intersection'](_0x1e1ae5[_0x4e2e0e('0x47')],qs['fields'](_0x295d29[_0x4e2e0e('0x2')][_0x4e2e0e('0x4c')])),_0x344010['attributes']=_0x344010[_0x4e2e0e('0x18')][_0x4e2e0e('0x14')]?_0x344010[_0x4e2e0e('0x18')]:_0x1e1ae5[_0x4e2e0e('0x47')],_0x295d29[_0x4e2e0e('0x2')]['includeAll']&&(_0x344010[_0x4e2e0e('0x1a')]=[{'all':!![]}]),_0x344010=_['merge']({},_0x344010,_0x295d29[_0x4e2e0e('0x16')]),db[_0x4e2e0e('0x3a')][_0x4e2e0e('0x41')](_0x344010)[_0x4e2e0e('0x24')](handleEntityNotFound(_0x516df4,null))[_0x4e2e0e('0x24')](respondWithResult(_0x516df4,null))[_0x4e2e0e('0x0')](handleError(_0x516df4,null));},exports[_0xe37b2a('0x4e')]=function(_0x58d2e3,_0xc19875){const _0x329c54=_0xe37b2a;return db[_0x329c54('0x3a')][_0x329c54('0x4e')](_0x58d2e3['body'],{})['then'](respondWithResult(_0xc19875,0xc9))[_0x329c54('0x0')](handleError(_0xc19875,null));},exports['update']=function(_0x36acbd,_0x8d0094){const _0x4f832c=_0xe37b2a;return _0x36acbd[_0x4f832c('0xc')]['id']&&delete _0x36acbd['body']['id'],db[_0x4f832c('0x3a')][_0x4f832c('0x41')]({'where':{'id':_0x36acbd[_0x4f832c('0x42')]['id']}})[_0x4f832c('0x24')](handleEntityNotFound(_0x8d0094,null))[_0x4f832c('0x24')](saveUpdates(_0x36acbd[_0x4f832c('0xc')],null))['then'](respondWithResult(_0x8d0094,null))[_0x4f832c('0x0')](handleError(_0x8d0094,null));},exports[_0xe37b2a('0x20')]=function(_0x2549cc,_0xfb469b){const _0x2a9df9=_0xe37b2a;return db['FreshsalesAccount'][_0x2a9df9('0x41')]({'where':{'id':_0x2549cc['params']['id']}})[_0x2a9df9('0x24')](handleEntityNotFound(_0xfb469b,null))[_0x2a9df9('0x24')](removeEntity(_0xfb469b,null))['catch'](handleError(_0xfb469b,null));},exports[_0xe37b2a('0x27')]=function(_0x26c6a6,_0x28089e){const _0x1872ab=_0xe37b2a;let _0xb740f1={};const _0x855d4d={};let _0x30056a,_0x143179;return db['FreshsalesAccount'][_0x1872ab('0x41')]({'where':{'id':_0x26c6a6[_0x1872ab('0x42')]['id']}})[_0x1872ab('0x24')](handleEntityNotFound(_0x28089e,null))[_0x1872ab('0x24')](function(_0x53b775){const _0x131fe1=_0x1872ab;if(_0x53b775)return _0x30056a=_0x53b775,_0x855d4d[_0x131fe1('0x47')]=_['keys'](db[_0x131fe1('0x1c')][_0x131fe1('0x34')]),_0x855d4d[_0x131fe1('0x2')]=_['keys'](_0x26c6a6[_0x131fe1('0x2')]),_0x855d4d[_0x131fe1('0x1b')]=_[_0x131fe1('0x44')](_0x855d4d[_0x131fe1('0x47')],_0x855d4d[_0x131fe1('0x2')]),_0xb740f1[_0x131fe1('0x18')]=_[_0x131fe1('0x44')](_0x855d4d[_0x131fe1('0x47')],qs[_0x131fe1('0x4c')](_0x26c6a6[_0x131fe1('0x2')][_0x131fe1('0x4c')])),_0xb740f1[_0x131fe1('0x18')]=_0xb740f1[_0x131fe1('0x18')][_0x131fe1('0x14')]?_0xb740f1[_0x131fe1('0x18')]:_0x855d4d['model'],_0xb740f1['order']=qs[_0x131fe1('0x31')](_0x26c6a6[_0x131fe1('0x2')][_0x131fe1('0x31')]),_0xb740f1['where']=qs[_0x131fe1('0x1b')](_['pick'](_0x26c6a6['query'],_0x855d4d[_0x131fe1('0x1b')])),_0x26c6a6['query'][_0x131fe1('0x19')]&&(_0xb740f1[_0x131fe1('0x29')]=_[_0x131fe1('0xe')](_0xb740f1[_0x131fe1('0x29')],{[Op['or']]:_['map'](_0xb740f1[_0x131fe1('0x18')],function(_0x4830b5){const _0x523c95=_0x131fe1,_0x1499ed={};return _0x1499ed[_0x4830b5]={[Op[_0x523c95('0x45')]]:'%'+_0x26c6a6['query'][_0x523c95('0x19')]+'%'},_0x1499ed;})})),_0xb740f1=_[_0x131fe1('0xe')]({},_0xb740f1,_0x26c6a6[_0x131fe1('0x16')]),_0x30056a[_0x131fe1('0x27')](_0xb740f1);})['then'](function(_0xe9d3b2){const _0x3f57cc=_0x1872ab;if(_0xe9d3b2)return _0x143179=_0xe9d3b2[_0x3f57cc('0x14')],typeof _0x26c6a6['query'][_0x3f57cc('0x2d')]==='undefined'&&(_0xb740f1['limit']=qs[_0x3f57cc('0x35')](_0x26c6a6['query'][_0x3f57cc('0x35')]),_0xb740f1[_0x3f57cc('0x4a')]=qs[_0x3f57cc('0x4a')](_0x26c6a6[_0x3f57cc('0x2')][_0x3f57cc('0x4a')])),_0x30056a['getConfigurations'](_0xb740f1);})['then'](function(_0x5955a8){if(_0x5955a8)return _0x5955a8?{'count':_0x143179,'rows':_0x5955a8}:null;})[_0x1872ab('0x24')](respondWithResult(_0x28089e,null))[_0x1872ab('0x0')](handleError(_0x28089e,null));},exports['addConfiguration']=function(_0x14492f,_0x12c258){const _0x1f1fcf=_0xe37b2a;return _0x14492f['body']['id']&&delete _0x14492f[_0x1f1fcf('0xc')]['id'],db['FreshsalesAccount'][_0x1f1fcf('0x41')]({'where':{'id':_0x14492f[_0x1f1fcf('0x42')]['id']}})['then'](handleEntityNotFound(_0x12c258,null))[_0x1f1fcf('0x24')](function(_0x31ee72){const _0x2a5ff6=_0x1f1fcf;if(_0x31ee72)return _0x14492f['body'][_0x2a5ff6('0x3')]=_0x31ee72['id'],_0x14492f['body'][_0x2a5ff6('0x39')]=integrations[_0x2a5ff6('0x33')](_0x14492f[_0x2a5ff6('0xc')][_0x2a5ff6('0xd')],_0x14492f[_0x2a5ff6('0xc')][_0x2a5ff6('0x1f')]),_0x14492f[_0x2a5ff6('0xc')]['Descriptions']=integrations[_0x2a5ff6('0x32')](_0x14492f['body'][_0x2a5ff6('0xd')],_0x14492f[_0x2a5ff6('0xc')][_0x2a5ff6('0x1f')]),db[_0x2a5ff6('0x1c')]['create'](_0x14492f['body'],{'include':[{'model':db[_0x2a5ff6('0x4d')],'as':_0x2a5ff6('0x39')},{'model':db[_0x2a5ff6('0x4d')],'as':_0x2a5ff6('0x2c')}]});return null;})[_0x1f1fcf('0x24')](respondWithResult(_0x12c258,null))[_0x1f1fcf('0x0')](handleError(_0x12c258,null));},exports[_0xe37b2a('0x7')]=function(_0x2806d4,_0x2a3612){const _0x264d30=_0xe37b2a;let _0x566f9f='',_0x13dde1='';return db[_0x264d30('0x3a')]['findOne']({'where':{'id':_0x2806d4[_0x264d30('0x42')]['id']},'attributes':['id',_0x264d30('0xa'),_0x264d30('0x2f'),_0x264d30('0x49')]})[_0x264d30('0x24')](handleEntityNotFound(_0x2a3612,null))[_0x264d30('0x24')](function(_0x2ff924){const _0x24d420=_0x264d30;if(_0x2ff924){_0x13dde1=_0x2ff924['username'],_0x566f9f=_0x2ff924[_0x24d420('0x2f')];const _0x4df870=_0x2ff924['remoteUri'][_0x24d420('0x8')](-0x1);return _0x4df870==='/'&&(_0x566f9f=_0x566f9f[_0x24d420('0x12')](0x0,_0x566f9f[_0x24d420('0x22')](_0x4df870))),rp({'method':_0x24d420('0x9'),'uri':util[_0x24d420('0x5')](_0x24d420('0x3b'),_0x566f9f,'/api/selector/owners'),'headers':{'Authorization':_0x24d420('0x37')+_0x2ff924[_0x24d420('0x49')]},'json':!![]});}})[_0x264d30('0x24')](function(_0x10017d){const _0x4201d1=_0x264d30;if(_0x10017d){const _0x1d9a33=_0x10017d[_0x4201d1('0x36')];let _0x2a91a6=![],_0x5451b0=null;for(_0x5451b0=0x0;_0x5451b0<_0x1d9a33[_0x4201d1('0x14')];_0x5451b0++){_0x1d9a33[_0x5451b0][_0x4201d1('0x38')]===_0x13dde1&&(_0x2a91a6=!![]);}if(_0x2a91a6)return!![];else throw new Error({'statusCode':0x194,'message':_0x4201d1('0x13')});}})[_0x264d30('0x24')](respondWithResult(_0x2a3612,null))[_0x264d30('0x0')](function(_0x30ecb3){const _0x4eb8b6=_0x264d30;let _0x3def0d=_0x2806d4[_0x4eb8b6('0x2')]['test']?0x1f4:_0x30ecb3[_0x4eb8b6('0x23')]||0x1f4;logger[_0x4eb8b6('0x25')](_0x4eb8b6('0x46'),'getFields',_0x3def0d,JSON[_0x4eb8b6('0x2e')](_0x30ecb3)),delete _0x30ecb3[_0x4eb8b6('0x28')],_0x3def0d===0x191&&(_0x3def0d=0x190),_0x2a3612[_0x4eb8b6('0x30')](_0x3def0d)[_0x4eb8b6('0x1e')](_0x2806d4['query'][_0x4eb8b6('0x4')]?{'message':'Wrong\x20credentials','statusCode':_0x30ecb3[_0x4eb8b6('0x23')]}:_0x30ecb3);});}; \ No newline at end of file +const a268_0x433c=['getConfigurations','lastIndexOf','includeAll','include','then','like','rawAttributes','users','index','fieldName','map','where','apiKey','keys','name','Subjects','slice','FreshsalesField','order','FreshsalesConfiguration','nolimit','util','sequelize','attributes','/api/selector/owners','params','Requested\x20Resource\x20not\x20Found','pick','username','Descriptions','addConfiguration','destroy','remoteUri','offset','catch','request-promise-native','lodash','limit','%s%s','rows','end','length','status','error','../../mysqldb','type','body','key','getFields','channel','api','model','statusCode','merge','AccountId','intersection','json','FreshsalesAccount','stringify','sendStatus','Wrong\x20credentials','send','filter','undefined','sort','filters','findOne','create','update','format','substring','Token\x20token=','email','../../components/parsers/qs','set','getSubjects','query','stack','test','options','fields','../../components/integrations/configuration','count','../../config/logger','show'];(function(_0x2b194c,_0x433c81){const _0x114c5e=function(_0x1ca4ed){while(--_0x1ca4ed){_0x2b194c['push'](_0x2b194c['shift']());}};_0x114c5e(++_0x433c81);}(a268_0x433c,0xbe));const a268_0x114c=function(_0x2b194c,_0x433c81){_0x2b194c=_0x2b194c-0x0;let _0x114c5e=a268_0x433c[_0x2b194c];return _0x114c5e;};const _0x43be16=a268_0x114c;'use strict';const rp=require(_0x43be16('0xf')),util=require(_0x43be16('0x1')),_=require(_0x43be16('0x10')),qs=require(_0x43be16('0x35')),logger=require(_0x43be16('0x3f'))(_0x43be16('0x1e')),db=require(_0x43be16('0x18'))['db'],{Op}=require(_0x43be16('0x2')),integrations=require(_0x43be16('0x3d'));function respondWithResult(_0x1ca4ed,_0xfb0706){return _0xfb0706=_0xfb0706||0xc8,function(_0x33c13a){const _0x368c68=a268_0x114c;if(_0x33c13a)return _0x1ca4ed['status'](_0xfb0706)[_0x368c68('0x24')](_0x33c13a);};}function respondWithFilteredResult(_0x1e9672,_0x1a85ad){return function(_0x362b99){const _0x4e5970=a268_0x114c;if(_0x362b99){const _0x15678b=_0x362b99[_0x4e5970('0x3e')],_0xa63370=_0x1a85ad[_0x4e5970('0xd')];let _0x386150=_0x1a85ad[_0x4e5970('0xd')]+_0x1a85ad[_0x4e5970('0x11')],_0x5e45d1;return _0x386150>=_0x15678b?(_0x386150=_0x15678b,_0x5e45d1=0xc8):_0x5e45d1=0xce,_0x1e9672[_0x4e5970('0x16')](_0x5e45d1),_0x1e9672[_0x4e5970('0x36')]('Content-Range',_0xa63370+'-'+_0x386150+'/'+_0x15678b)[_0x4e5970('0x24')](_0x362b99);}return null;};}function saveUpdates(_0x73d541){return function(_0x57eacb){const _0x497ace=a268_0x114c;if(_0x57eacb)return _0x57eacb[_0x497ace('0x30')](_0x73d541)['then'](function(_0x5edf56){return _0x5edf56;});return null;};}function removeEntity(_0x5dd19b){return function(_0x3af819){if(_0x3af819)return _0x3af819['destroy']()['then'](function(){const _0x27da61=a268_0x114c;_0x5dd19b['status'](0xcc)[_0x27da61('0x14')]();});};}function handleEntityNotFound(_0xc80dca){return function(_0x276bbb){const _0x36a3a5=a268_0x114c;return!_0x276bbb&&_0xc80dca[_0x36a3a5('0x27')](0x194),_0x276bbb;};}function handleError(_0x2f825a,_0x5c9369){return _0x5c9369=_0x5c9369||0x1f4,function(_0x1c9e4b){const _0x33ce59=a268_0x114c;logger['error'](_0x1c9e4b[_0x33ce59('0x39')]),_0x1c9e4b['name']&&delete _0x1c9e4b[_0x33ce59('0x4f')],_0x2f825a[_0x33ce59('0x16')](_0x5c9369)['send'](_0x1c9e4b);};}exports[_0x43be16('0x49')]=function(_0x3b096d,_0x119bcd){const _0x2825f9=_0x43be16;let _0x43aaad={};const _0x5f320b={},_0x5d8f6c={'count':0x0,'rows':[]},_0x260af3=_[_0x2825f9('0x4b')](db[_0x2825f9('0x25')]['rawAttributes'],function(_0x202788){const _0x5d5c55=_0x2825f9;return{'name':_0x202788[_0x5d5c55('0x4a')],'type':_0x202788[_0x5d5c55('0x19')][_0x5d5c55('0x1b')]};});_0x5f320b[_0x2825f9('0x1f')]=_[_0x2825f9('0x4b')](_0x260af3,_0x2825f9('0x4f')),_0x5f320b[_0x2825f9('0x38')]=_[_0x2825f9('0x4e')](_0x3b096d[_0x2825f9('0x38')]),_0x5f320b[_0x2825f9('0x2d')]=_[_0x2825f9('0x23')](_0x5f320b['model'],_0x5f320b[_0x2825f9('0x38')]),_0x43aaad['attributes']=_['intersection'](_0x5f320b[_0x2825f9('0x1f')],qs[_0x2825f9('0x3c')](_0x3b096d[_0x2825f9('0x38')][_0x2825f9('0x3c')])),_0x43aaad[_0x2825f9('0x3')]=_0x43aaad[_0x2825f9('0x3')][_0x2825f9('0x15')]?_0x43aaad[_0x2825f9('0x3')]:_0x5f320b['model'];typeof _0x3b096d[_0x2825f9('0x38')][_0x2825f9('0x0')]===_0x2825f9('0x2b')&&(_0x43aaad['limit']=qs[_0x2825f9('0x11')](_0x3b096d[_0x2825f9('0x38')][_0x2825f9('0x11')]),_0x43aaad[_0x2825f9('0xd')]=qs[_0x2825f9('0xd')](_0x3b096d[_0x2825f9('0x38')][_0x2825f9('0xd')]));_0x43aaad[_0x2825f9('0x53')]=qs[_0x2825f9('0x2c')](_0x3b096d[_0x2825f9('0x38')][_0x2825f9('0x2c')]),_0x43aaad[_0x2825f9('0x4c')]=qs[_0x2825f9('0x2d')](_[_0x2825f9('0x7')](_0x3b096d[_0x2825f9('0x38')],_0x5f320b['filters']),_0x260af3);_0x3b096d[_0x2825f9('0x38')]['filter']&&(_0x43aaad[_0x2825f9('0x4c')]=_[_0x2825f9('0x21')](_0x43aaad[_0x2825f9('0x4c')],{[Op['or']]:_[_0x2825f9('0x4b')](_0x260af3,function(_0x271dd8){const _0xd6afe1=_0x2825f9;if(_0x271dd8[_0xd6afe1('0x19')]!=='VIRTUAL'){const _0x440f7f={};return _0x440f7f[_0x271dd8['name']]={[Op[_0xd6afe1('0x46')]]:'%'+_0x3b096d[_0xd6afe1('0x38')][_0xd6afe1('0x2a')]+'%'},_0x440f7f;}})}));_0x43aaad=_[_0x2825f9('0x21')]({},_0x43aaad,_0x3b096d[_0x2825f9('0x3b')]);const _0x33a3a1={'where':_0x43aaad[_0x2825f9('0x4c')]};return db[_0x2825f9('0x25')][_0x2825f9('0x3e')](_0x33a3a1)[_0x2825f9('0x45')](function(_0x286ffa){const _0x40a977=_0x2825f9;return _0x5d8f6c[_0x40a977('0x3e')]=_0x286ffa,_0x3b096d[_0x40a977('0x38')]['includeAll']&&(_0x43aaad[_0x40a977('0x44')]=[{'all':!![]}]),db[_0x40a977('0x25')]['findAll'](_0x43aaad);})[_0x2825f9('0x45')](function(_0x13abd6){const _0x1b5a76=_0x2825f9;return _0x5d8f6c[_0x1b5a76('0x13')]=_0x13abd6,_0x5d8f6c;})[_0x2825f9('0x45')](respondWithFilteredResult(_0x119bcd,_0x43aaad))[_0x2825f9('0xe')](handleError(_0x119bcd,null));},exports[_0x43be16('0x40')]=function(_0x2b9be5,_0x1c1373){const _0x1b82a6=_0x43be16;let _0x21f213={'raw':![],'where':{'id':_0x2b9be5[_0x1b82a6('0x5')]['id']}};const _0xbe8913={};return _0xbe8913[_0x1b82a6('0x1f')]=_[_0x1b82a6('0x4e')](db['FreshsalesAccount'][_0x1b82a6('0x47')]),_0xbe8913['query']=_['keys'](_0x2b9be5['query']),_0xbe8913[_0x1b82a6('0x2d')]=_['intersection'](_0xbe8913['model'],_0xbe8913[_0x1b82a6('0x38')]),_0x21f213['attributes']=_[_0x1b82a6('0x23')](_0xbe8913['model'],qs[_0x1b82a6('0x3c')](_0x2b9be5[_0x1b82a6('0x38')][_0x1b82a6('0x3c')])),_0x21f213[_0x1b82a6('0x3')]=_0x21f213['attributes'][_0x1b82a6('0x15')]?_0x21f213['attributes']:_0xbe8913[_0x1b82a6('0x1f')],_0x2b9be5['query'][_0x1b82a6('0x43')]&&(_0x21f213['include']=[{'all':!![]}]),_0x21f213=_[_0x1b82a6('0x21')]({},_0x21f213,_0x2b9be5[_0x1b82a6('0x3b')]),db[_0x1b82a6('0x25')][_0x1b82a6('0x2e')](_0x21f213)[_0x1b82a6('0x45')](handleEntityNotFound(_0x1c1373,null))[_0x1b82a6('0x45')](respondWithResult(_0x1c1373,null))[_0x1b82a6('0xe')](handleError(_0x1c1373,null));},exports[_0x43be16('0x2f')]=function(_0x28240d,_0x2ce695){const _0x2c3509=_0x43be16;return db[_0x2c3509('0x25')][_0x2c3509('0x2f')](_0x28240d['body'],{})[_0x2c3509('0x45')](respondWithResult(_0x2ce695,0xc9))[_0x2c3509('0xe')](handleError(_0x2ce695,null));},exports[_0x43be16('0x30')]=function(_0x3a71d9,_0x176bd4){const _0x111a83=_0x43be16;return _0x3a71d9['body']['id']&&delete _0x3a71d9['body']['id'],db[_0x111a83('0x25')]['findOne']({'where':{'id':_0x3a71d9['params']['id']}})[_0x111a83('0x45')](handleEntityNotFound(_0x176bd4,null))['then'](saveUpdates(_0x3a71d9[_0x111a83('0x1a')],null))[_0x111a83('0x45')](respondWithResult(_0x176bd4,null))['catch'](handleError(_0x176bd4,null));},exports[_0x43be16('0xb')]=function(_0x34225c,_0x407922){const _0x40613d=_0x43be16;return db['FreshsalesAccount'][_0x40613d('0x2e')]({'where':{'id':_0x34225c[_0x40613d('0x5')]['id']}})[_0x40613d('0x45')](handleEntityNotFound(_0x407922,null))[_0x40613d('0x45')](removeEntity(_0x407922,null))[_0x40613d('0xe')](handleError(_0x407922,null));},exports[_0x43be16('0x41')]=function(_0x2535b4,_0x41552e){const _0x47ae35=_0x43be16;let _0x51dbb0={};const _0x5e6548={};let _0x4ca037,_0x31a4d0;return db[_0x47ae35('0x25')][_0x47ae35('0x2e')]({'where':{'id':_0x2535b4['params']['id']}})['then'](handleEntityNotFound(_0x41552e,null))['then'](function(_0x334e44){const _0x3ba7bc=_0x47ae35;if(_0x334e44)return _0x4ca037=_0x334e44,_0x5e6548['model']=_[_0x3ba7bc('0x4e')](db[_0x3ba7bc('0x54')]['rawAttributes']),_0x5e6548[_0x3ba7bc('0x38')]=_[_0x3ba7bc('0x4e')](_0x2535b4[_0x3ba7bc('0x38')]),_0x5e6548['filters']=_[_0x3ba7bc('0x23')](_0x5e6548[_0x3ba7bc('0x1f')],_0x5e6548[_0x3ba7bc('0x38')]),_0x51dbb0['attributes']=_[_0x3ba7bc('0x23')](_0x5e6548['model'],qs[_0x3ba7bc('0x3c')](_0x2535b4['query'][_0x3ba7bc('0x3c')])),_0x51dbb0[_0x3ba7bc('0x3')]=_0x51dbb0['attributes']['length']?_0x51dbb0[_0x3ba7bc('0x3')]:_0x5e6548['model'],_0x51dbb0[_0x3ba7bc('0x53')]=qs[_0x3ba7bc('0x2c')](_0x2535b4[_0x3ba7bc('0x38')][_0x3ba7bc('0x2c')]),_0x51dbb0[_0x3ba7bc('0x4c')]=qs[_0x3ba7bc('0x2d')](_['pick'](_0x2535b4[_0x3ba7bc('0x38')],_0x5e6548[_0x3ba7bc('0x2d')])),_0x2535b4[_0x3ba7bc('0x38')][_0x3ba7bc('0x2a')]&&(_0x51dbb0[_0x3ba7bc('0x4c')]=_[_0x3ba7bc('0x21')](_0x51dbb0[_0x3ba7bc('0x4c')],{[Op['or']]:_[_0x3ba7bc('0x4b')](_0x51dbb0[_0x3ba7bc('0x3')],function(_0x2d2f8a){const _0x3cef23=_0x3ba7bc,_0x101d6a={};return _0x101d6a[_0x2d2f8a]={[Op[_0x3cef23('0x46')]]:'%'+_0x2535b4[_0x3cef23('0x38')][_0x3cef23('0x2a')]+'%'},_0x101d6a;})})),_0x51dbb0=_[_0x3ba7bc('0x21')]({},_0x51dbb0,_0x2535b4[_0x3ba7bc('0x3b')]),_0x4ca037['getConfigurations'](_0x51dbb0);})[_0x47ae35('0x45')](function(_0x509792){const _0x5cbc73=_0x47ae35;if(_0x509792)return _0x31a4d0=_0x509792[_0x5cbc73('0x15')],typeof _0x2535b4[_0x5cbc73('0x38')][_0x5cbc73('0x0')]==='undefined'&&(_0x51dbb0['limit']=qs['limit'](_0x2535b4[_0x5cbc73('0x38')]['limit']),_0x51dbb0[_0x5cbc73('0xd')]=qs[_0x5cbc73('0xd')](_0x2535b4[_0x5cbc73('0x38')]['offset'])),_0x4ca037[_0x5cbc73('0x41')](_0x51dbb0);})['then'](function(_0x409aa6){if(_0x409aa6)return _0x409aa6?{'count':_0x31a4d0,'rows':_0x409aa6}:null;})['then'](respondWithResult(_0x41552e,null))[_0x47ae35('0xe')](handleError(_0x41552e,null));},exports[_0x43be16('0xa')]=function(_0x944c3a,_0x1e1e58){const _0x540833=_0x43be16;return _0x944c3a['body']['id']&&delete _0x944c3a[_0x540833('0x1a')]['id'],db[_0x540833('0x25')]['findOne']({'where':{'id':_0x944c3a[_0x540833('0x5')]['id']}})[_0x540833('0x45')](handleEntityNotFound(_0x1e1e58,null))['then'](function(_0x16fd94){const _0x4b0dbc=_0x540833;if(_0x16fd94)return _0x944c3a[_0x4b0dbc('0x1a')][_0x4b0dbc('0x22')]=_0x16fd94['id'],_0x944c3a[_0x4b0dbc('0x1a')]['Subjects']=integrations[_0x4b0dbc('0x37')](_0x944c3a['body'][_0x4b0dbc('0x1d')],_0x944c3a[_0x4b0dbc('0x1a')][_0x4b0dbc('0x19')]),_0x944c3a[_0x4b0dbc('0x1a')][_0x4b0dbc('0x9')]=integrations['getDescriptions'](_0x944c3a[_0x4b0dbc('0x1a')]['channel'],_0x944c3a[_0x4b0dbc('0x1a')][_0x4b0dbc('0x19')]),db['FreshsalesConfiguration']['create'](_0x944c3a[_0x4b0dbc('0x1a')],{'include':[{'model':db[_0x4b0dbc('0x52')],'as':_0x4b0dbc('0x50')},{'model':db[_0x4b0dbc('0x52')],'as':_0x4b0dbc('0x9')}]});return null;})[_0x540833('0x45')](respondWithResult(_0x1e1e58,null))[_0x540833('0xe')](handleError(_0x1e1e58,null));},exports['getFields']=function(_0x46c285,_0x18da04){const _0x56fed8=_0x43be16;let _0x1be1e3='',_0x35ba39='';return db[_0x56fed8('0x25')][_0x56fed8('0x2e')]({'where':{'id':_0x46c285[_0x56fed8('0x5')]['id']},'attributes':['id',_0x56fed8('0x8'),_0x56fed8('0xc'),_0x56fed8('0x4d')]})[_0x56fed8('0x45')](handleEntityNotFound(_0x18da04,null))[_0x56fed8('0x45')](function(_0x4ba6e7){const _0x39464e=_0x56fed8;if(_0x4ba6e7){_0x35ba39=_0x4ba6e7[_0x39464e('0x8')],_0x1be1e3=_0x4ba6e7[_0x39464e('0xc')];const _0x1d40a2=_0x4ba6e7[_0x39464e('0xc')][_0x39464e('0x51')](-0x1);return _0x1d40a2==='/'&&(_0x1be1e3=_0x1be1e3[_0x39464e('0x32')](0x0,_0x1be1e3[_0x39464e('0x42')](_0x1d40a2))),rp({'method':'GET','uri':util[_0x39464e('0x31')](_0x39464e('0x12'),_0x1be1e3,_0x39464e('0x4')),'headers':{'Authorization':_0x39464e('0x33')+_0x4ba6e7[_0x39464e('0x4d')]},'json':!![]});}})[_0x56fed8('0x45')](function(_0x5cf5cf){const _0x4c530a=_0x56fed8;if(_0x5cf5cf){const _0x2161a2=_0x5cf5cf[_0x4c530a('0x48')];let _0x3960a1=![],_0x46cae5=null;for(_0x46cae5=0x0;_0x46cae5<_0x2161a2[_0x4c530a('0x15')];_0x46cae5++){_0x2161a2[_0x46cae5][_0x4c530a('0x34')]===_0x35ba39&&(_0x3960a1=!![]);}if(_0x3960a1)return!![];else throw new Error({'statusCode':0x194,'message':_0x4c530a('0x6')});}})['then'](respondWithResult(_0x18da04,null))[_0x56fed8('0xe')](function(_0x30a368){const _0x2f0675=_0x56fed8;let _0x4c703d=_0x46c285[_0x2f0675('0x38')]['test']?0x1f4:_0x30a368['statusCode']||0x1f4;logger[_0x2f0675('0x17')]('getFields,\x20%s,\x20%s,\x20%s',_0x2f0675('0x1c'),_0x4c703d,JSON[_0x2f0675('0x26')](_0x30a368)),delete _0x30a368[_0x2f0675('0x4f')],_0x4c703d===0x191&&(_0x4c703d=0x190),_0x18da04[_0x2f0675('0x16')](_0x4c703d)[_0x2f0675('0x29')](_0x46c285[_0x2f0675('0x38')][_0x2f0675('0x3a')]?{'message':_0x2f0675('0x28'),'statusCode':_0x30a368[_0x2f0675('0x20')]}:_0x30a368);});}; \ No newline at end of file diff --git a/server/api/intFreshsalesAccount/intFreshsalesAccount.model.js b/server/api/intFreshsalesAccount/intFreshsalesAccount.model.js index 28b7743..8872117 100644 --- a/server/api/intFreshsalesAccount/intFreshsalesAccount.model.js +++ b/server/api/intFreshsalesAccount/intFreshsalesAccount.model.js @@ -1 +1 @@ -const a269_0x1dd6=['./intFreshsalesAccount.attributes','FreshsalesAccount','define','int_freshsales_accounts'];(function(_0x26f236,_0x1dd6fe){const _0x4b65de=function(_0x13f684){while(--_0x13f684){_0x26f236['push'](_0x26f236['shift']());}};_0x4b65de(++_0x1dd6fe);}(a269_0x1dd6,0x119));const a269_0x4b65=function(_0x26f236,_0x1dd6fe){_0x26f236=_0x26f236-0x0;let _0x4b65de=a269_0x1dd6[_0x26f236];return _0x4b65de;};const _0x4657e5=a269_0x4b65;'use strict';const attributes=require(_0x4657e5('0x3'));module['exports']=function(_0x13f684){const _0x235c99=_0x4657e5,_0x34e46b=_0x13f684[_0x235c99('0x1')](_0x235c99('0x0'),attributes,{'tableName':_0x235c99('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x34e46b;}; \ No newline at end of file +const a269_0x4498=['FreshsalesAccount','exports','./intFreshsalesAccount.attributes','define','int_freshsales_accounts'];(function(_0x279bf0,_0x44981d){const _0x219981=function(_0x5c94c0){while(--_0x5c94c0){_0x279bf0['push'](_0x279bf0['shift']());}};_0x219981(++_0x44981d);}(a269_0x4498,0x78));const a269_0x2199=function(_0x279bf0,_0x44981d){_0x279bf0=_0x279bf0-0x0;let _0x219981=a269_0x4498[_0x279bf0];return _0x219981;};const _0x2e9e6c=a269_0x2199;'use strict';const attributes=require(_0x2e9e6c('0x2'));module[_0x2e9e6c('0x1')]=function(_0x5c94c0){const _0x4af9cc=_0x2e9e6c,_0x2ff9e0=_0x5c94c0[_0x4af9cc('0x3')](_0x4af9cc('0x0'),attributes,{'tableName':_0x4af9cc('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2ff9e0;}; \ No newline at end of file diff --git a/server/api/intFreshsalesAccount/intFreshsalesAccount.rpc.js b/server/api/intFreshsalesAccount/intFreshsalesAccount.rpc.js index 6b944c9..0f9bc95 100644 --- a/server/api/intFreshsalesAccount/intFreshsalesAccount.rpc.js +++ b/server/api/intFreshsalesAccount/intFreshsalesAccount.rpc.js @@ -1 +1 @@ -const a270_0x5820=['then','options','GetFreshsalesAccount','lodash','findOne','ShowFreshsalesAccount','message','catch','../../config/logger','FreshsalesAccount','map','include','limit','attributes','model','where','findAll','info','error','../../mysqldb','stringify','rpc','raw'];(function(_0x278cd3,_0x58209a){const _0x5541f5=function(_0x4ab7be){while(--_0x4ab7be){_0x278cd3['push'](_0x278cd3['shift']());}};_0x5541f5(++_0x58209a);}(a270_0x5820,0x8c));const a270_0x5541=function(_0x278cd3,_0x58209a){_0x278cd3=_0x278cd3-0x0;let _0x5541f5=a270_0x5820[_0x278cd3];return _0x5541f5;};const _0x3d7628=a270_0x5541;'use strict';const _=require(_0x3d7628('0x1')),db=require(_0x3d7628('0x11'))['db'],logger=require(_0x3d7628('0x6'))(_0x3d7628('0x13'));exports[_0x3d7628('0x0')]=function(_0x4ab7be){const _0x384e33=this;return new Promise(function(_0x555ae1,_0x168d64){const _0x581004=a270_0x5541;return db[_0x581004('0x7')][_0x581004('0xe')]({'raw':_0x4ab7be[_0x581004('0x16')]?_0x4ab7be[_0x581004('0x16')][_0x581004('0x14')]===undefined?!![]:![]:!![],'where':_0x4ab7be['options']?_0x4ab7be['options']['where']||null:null,'attributes':_0x4ab7be[_0x581004('0x16')]?_0x4ab7be[_0x581004('0x16')][_0x581004('0xb')]||null:null,'limit':_0x4ab7be['options']?_0x4ab7be[_0x581004('0x16')][_0x581004('0xa')]||null:null,'include':_0x4ab7be[_0x581004('0x16')]?_0x4ab7be['options'][_0x581004('0x9')]?_[_0x581004('0x8')](_0x4ab7be[_0x581004('0x16')][_0x581004('0x9')],function(_0x27aaf6){const _0x1df18b=_0x581004;return{'model':db[_0x27aaf6[_0x1df18b('0xc')]],'as':_0x27aaf6['as'],'attributes':_0x27aaf6['attributes'],'include':_0x27aaf6[_0x1df18b('0x9')]?_['map'](_0x27aaf6[_0x1df18b('0x9')],function(_0x3e37db){const _0xd19968=_0x1df18b;return{'model':db[_0x3e37db[_0xd19968('0xc')]],'as':_0x3e37db['as'],'attributes':_0x3e37db[_0xd19968('0xb')],'include':_0x3e37db[_0xd19968('0x9')]?_['map'](_0x3e37db[_0xd19968('0x9')],function(_0x3f29db){const _0x1ec30=_0xd19968;return{'model':db[_0x3f29db[_0x1ec30('0xc')]],'as':_0x3f29db['as'],'attributes':_0x3f29db['attributes']};}):[]};}):[]};}):[]:[]})[_0x581004('0x15')](function(_0x5e50ee){const _0x478700=_0x581004;logger['info'](_0x478700('0x0'),_0x4ab7be),logger['debug'](_0x478700('0x0'),_0x4ab7be,JSON['stringify'](_0x5e50ee)),_0x555ae1(_0x5e50ee);})[_0x581004('0x5')](function(_0x466a1f){const _0x114583=_0x581004;logger['error'](_0x114583('0x0'),_0x466a1f[_0x114583('0x4')],_0x4ab7be),_0x168d64(_0x384e33[_0x114583('0x10')](0x1f4,_0x466a1f[_0x114583('0x4')]));});});},exports[_0x3d7628('0x3')]=function(_0x27ba8b){const _0x4771f0=this;return new Promise(function(_0xd3f824,_0x222e78){const _0x4a60e5=a270_0x5541;return db['FreshsalesAccount'][_0x4a60e5('0x2')]({'raw':_0x27ba8b['options']?_0x27ba8b[_0x4a60e5('0x16')]['raw']===undefined?!![]:![]:!![],'where':_0x27ba8b[_0x4a60e5('0x16')]?_0x27ba8b[_0x4a60e5('0x16')][_0x4a60e5('0xd')]||null:null,'attributes':_0x27ba8b[_0x4a60e5('0x16')]?_0x27ba8b[_0x4a60e5('0x16')][_0x4a60e5('0xb')]||null:null,'include':_0x27ba8b[_0x4a60e5('0x16')]?_0x27ba8b[_0x4a60e5('0x16')][_0x4a60e5('0x9')]?_['map'](_0x27ba8b[_0x4a60e5('0x16')]['include'],function(_0xd7595e){const _0x1e0009=_0x4a60e5;return{'model':db[_0xd7595e[_0x1e0009('0xc')]],'as':_0xd7595e['as'],'attributes':_0xd7595e['attributes'],'include':_0xd7595e[_0x1e0009('0x9')]?_['map'](_0xd7595e[_0x1e0009('0x9')],function(_0x225855){const _0x277b68=_0x1e0009;return{'model':db[_0x225855[_0x277b68('0xc')]],'as':_0x225855['as'],'attributes':_0x225855['attributes'],'include':_0x225855[_0x277b68('0x9')]?_[_0x277b68('0x8')](_0x225855[_0x277b68('0x9')],function(_0x38e7ad){const _0x325e38=_0x277b68;return{'model':db[_0x38e7ad[_0x325e38('0xc')]],'as':_0x38e7ad['as'],'attributes':_0x38e7ad['attributes']};}):[]};}):[]};}):[]:[]})['then'](function(_0x23aabe){const _0xd928d7=_0x4a60e5;logger[_0xd928d7('0xf')](_0xd928d7('0x3'),_0x27ba8b),logger['debug'](_0xd928d7('0x3'),_0x27ba8b,JSON[_0xd928d7('0x12')](_0x23aabe)),_0xd3f824(_0x23aabe);})[_0x4a60e5('0x5')](function(_0x5da6c2){const _0x4ad6e6=_0x4a60e5;logger['error']('ShowFreshsalesAccount',_0x5da6c2[_0x4ad6e6('0x4')],_0x27ba8b),_0x222e78(_0x4771f0[_0x4ad6e6('0x10')](0x1f4,_0x5da6c2[_0x4ad6e6('0x4')]));});});}; \ No newline at end of file +const a270_0x483e=['ShowFreshsalesAccount','debug','findOne','attributes','then','message','catch','FreshsalesAccount','stringify','where','rpc','info','options','lodash','model','findAll','include','map','error','raw','GetFreshsalesAccount'];(function(_0x5a2a72,_0x483ecb){const _0x14c849=function(_0x4db19e){while(--_0x4db19e){_0x5a2a72['push'](_0x5a2a72['shift']());}};_0x14c849(++_0x483ecb);}(a270_0x483e,0x131));const a270_0x14c8=function(_0x5a2a72,_0x483ecb){_0x5a2a72=_0x5a2a72-0x0;let _0x14c849=a270_0x483e[_0x5a2a72];return _0x14c849;};const _0x197135=a270_0x14c8;'use strict';const _=require(_0x197135('0x2')),db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x197135('0x14'));exports[_0x197135('0x9')]=function(_0x4db19e){const _0x496f05=this;return new Promise(function(_0x562061,_0x572bec){const _0x51ea08=a270_0x14c8;return db[_0x51ea08('0x11')][_0x51ea08('0x4')]({'raw':_0x4db19e[_0x51ea08('0x1')]?_0x4db19e['options'][_0x51ea08('0x8')]===undefined?!![]:![]:!![],'where':_0x4db19e[_0x51ea08('0x1')]?_0x4db19e[_0x51ea08('0x1')][_0x51ea08('0x13')]||null:null,'attributes':_0x4db19e['options']?_0x4db19e[_0x51ea08('0x1')][_0x51ea08('0xd')]||null:null,'limit':_0x4db19e['options']?_0x4db19e['options']['limit']||null:null,'include':_0x4db19e[_0x51ea08('0x1')]?_0x4db19e[_0x51ea08('0x1')]['include']?_[_0x51ea08('0x6')](_0x4db19e['options'][_0x51ea08('0x5')],function(_0x3be4b0){const _0x271de3=_0x51ea08;return{'model':db[_0x3be4b0['model']],'as':_0x3be4b0['as'],'attributes':_0x3be4b0[_0x271de3('0xd')],'include':_0x3be4b0[_0x271de3('0x5')]?_[_0x271de3('0x6')](_0x3be4b0[_0x271de3('0x5')],function(_0x30cda0){const _0x1cd1d4=_0x271de3;return{'model':db[_0x30cda0[_0x1cd1d4('0x3')]],'as':_0x30cda0['as'],'attributes':_0x30cda0[_0x1cd1d4('0xd')],'include':_0x30cda0[_0x1cd1d4('0x5')]?_['map'](_0x30cda0[_0x1cd1d4('0x5')],function(_0xe07675){const _0x1ce9ad=_0x1cd1d4;return{'model':db[_0xe07675[_0x1ce9ad('0x3')]],'as':_0xe07675['as'],'attributes':_0xe07675[_0x1ce9ad('0xd')]};}):[]};}):[]};}):[]:[]})[_0x51ea08('0xe')](function(_0x818e04){const _0x4c8010=_0x51ea08;logger['info']('GetFreshsalesAccount',_0x4db19e),logger[_0x4c8010('0xb')](_0x4c8010('0x9'),_0x4db19e,JSON[_0x4c8010('0x12')](_0x818e04)),_0x562061(_0x818e04);})['catch'](function(_0x84b2d4){const _0x1ab206=_0x51ea08;logger[_0x1ab206('0x7')](_0x1ab206('0x9'),_0x84b2d4[_0x1ab206('0xf')],_0x4db19e),_0x572bec(_0x496f05[_0x1ab206('0x7')](0x1f4,_0x84b2d4[_0x1ab206('0xf')]));});});},exports[_0x197135('0xa')]=function(_0x2acb54){const _0x53ee01=this;return new Promise(function(_0x305cbf,_0x5ba7e3){const _0x14382d=a270_0x14c8;return db[_0x14382d('0x11')][_0x14382d('0xc')]({'raw':_0x2acb54[_0x14382d('0x1')]?_0x2acb54[_0x14382d('0x1')][_0x14382d('0x8')]===undefined?!![]:![]:!![],'where':_0x2acb54['options']?_0x2acb54[_0x14382d('0x1')][_0x14382d('0x13')]||null:null,'attributes':_0x2acb54[_0x14382d('0x1')]?_0x2acb54['options'][_0x14382d('0xd')]||null:null,'include':_0x2acb54[_0x14382d('0x1')]?_0x2acb54['options'][_0x14382d('0x5')]?_[_0x14382d('0x6')](_0x2acb54[_0x14382d('0x1')]['include'],function(_0x1440a6){const _0x36eca2=_0x14382d;return{'model':db[_0x1440a6[_0x36eca2('0x3')]],'as':_0x1440a6['as'],'attributes':_0x1440a6[_0x36eca2('0xd')],'include':_0x1440a6[_0x36eca2('0x5')]?_[_0x36eca2('0x6')](_0x1440a6[_0x36eca2('0x5')],function(_0x21fd15){const _0x20fae9=_0x36eca2;return{'model':db[_0x21fd15[_0x20fae9('0x3')]],'as':_0x21fd15['as'],'attributes':_0x21fd15[_0x20fae9('0xd')],'include':_0x21fd15[_0x20fae9('0x5')]?_[_0x20fae9('0x6')](_0x21fd15[_0x20fae9('0x5')],function(_0x592168){const _0x27063a=_0x20fae9;return{'model':db[_0x592168[_0x27063a('0x3')]],'as':_0x592168['as'],'attributes':_0x592168['attributes']};}):[]};}):[]};}):[]:[]})[_0x14382d('0xe')](function(_0x371ea9){const _0x590dfc=_0x14382d;logger[_0x590dfc('0x0')](_0x590dfc('0xa'),_0x2acb54),logger[_0x590dfc('0xb')](_0x590dfc('0xa'),_0x2acb54,JSON[_0x590dfc('0x12')](_0x371ea9)),_0x305cbf(_0x371ea9);})[_0x14382d('0x10')](function(_0x4502f2){const _0x44e995=_0x14382d;logger[_0x44e995('0x7')]('ShowFreshsalesAccount',_0x4502f2[_0x44e995('0xf')],_0x2acb54),_0x5ba7e3(_0x53ee01['error'](0x1f4,_0x4502f2['message']));});});}; \ No newline at end of file diff --git a/server/api/intFreshsalesConfiguration/index.js b/server/api/intFreshsalesConfiguration/index.js index d8239b9..51ce343 100644 --- a/server/api/intFreshsalesConfiguration/index.js +++ b/server/api/intFreshsalesConfiguration/index.js @@ -1 +1 @@ -const a271_0x4de1=['./intFreshsalesConfiguration.controller','show','delete','/:id/fields','post','getSubjects','getFields','/:id','Router','get','exports','index','create','isAuthenticated','update','express','destroy'];(function(_0x1a1419,_0x4de1c4){const _0x92caf3=function(_0x330d02){while(--_0x330d02){_0x1a1419['push'](_0x1a1419['shift']());}};_0x92caf3(++_0x4de1c4);}(a271_0x4de1,0x81));const a271_0x92ca=function(_0x1a1419,_0x4de1c4){_0x1a1419=_0x1a1419-0x0;let _0x92caf3=a271_0x4de1[_0x1a1419];return _0x92caf3;};const _0xf38d36=a271_0x92ca;'use strict';const express=require(_0xf38d36('0x5')),router=express[_0xf38d36('0xf')](),auth=require('../../components/auth/service'),controller=require(_0xf38d36('0x7'));router['get']('/',auth[_0xf38d36('0x3')](),controller[_0xf38d36('0x1')]),router[_0xf38d36('0x10')]('/:id',auth[_0xf38d36('0x3')](),controller[_0xf38d36('0x8')]),router[_0xf38d36('0x10')]('/:id/subjects',auth[_0xf38d36('0x3')](),controller[_0xf38d36('0xc')]),router[_0xf38d36('0x10')]('/:id/descriptions',auth[_0xf38d36('0x3')](),controller['getDescriptions']),router[_0xf38d36('0x10')](_0xf38d36('0xa'),auth[_0xf38d36('0x3')](),controller[_0xf38d36('0xd')]),router[_0xf38d36('0xb')]('/',auth[_0xf38d36('0x3')](),controller[_0xf38d36('0x2')]),router['put']('/:id',auth[_0xf38d36('0x3')](),controller[_0xf38d36('0x4')]),router[_0xf38d36('0x9')](_0xf38d36('0xe'),auth['isAuthenticated'](),controller[_0xf38d36('0x6')]),module[_0xf38d36('0x0')]=router; \ No newline at end of file +const a271_0x549c=['/:id/descriptions','create','post','exports','delete','/:id/subjects','isAuthenticated','/:id/fields','index','Router','/:id','update','put','getDescriptions','get','../../components/auth/service','./intFreshsalesConfiguration.controller'];(function(_0x35dcfc,_0x549c68){const _0x58d6b5=function(_0x4e83e2){while(--_0x4e83e2){_0x35dcfc['push'](_0x35dcfc['shift']());}};_0x58d6b5(++_0x549c68);}(a271_0x549c,0x119));const a271_0x58d6=function(_0x35dcfc,_0x549c68){_0x35dcfc=_0x35dcfc-0x0;let _0x58d6b5=a271_0x549c[_0x35dcfc];return _0x58d6b5;};const _0x37cd1d=a271_0x58d6;'use strict';const express=require('express'),router=express[_0x37cd1d('0x0')](),auth=require(_0x37cd1d('0x6')),controller=require(_0x37cd1d('0x7'));router['get']('/',auth[_0x37cd1d('0xe')](),controller[_0x37cd1d('0x10')]),router[_0x37cd1d('0x5')]('/:id',auth[_0x37cd1d('0xe')](),controller['show']),router[_0x37cd1d('0x5')](_0x37cd1d('0xd'),auth[_0x37cd1d('0xe')](),controller['getSubjects']),router[_0x37cd1d('0x5')](_0x37cd1d('0x8'),auth['isAuthenticated'](),controller[_0x37cd1d('0x4')]),router[_0x37cd1d('0x5')](_0x37cd1d('0xf'),auth['isAuthenticated'](),controller['getFields']),router[_0x37cd1d('0xa')]('/',auth[_0x37cd1d('0xe')](),controller[_0x37cd1d('0x9')]),router[_0x37cd1d('0x3')]('/:id',auth[_0x37cd1d('0xe')](),controller[_0x37cd1d('0x2')]),router[_0x37cd1d('0xc')](_0x37cd1d('0x1'),auth[_0x37cd1d('0xe')](),controller['destroy']),module[_0x37cd1d('0xb')]=router; \ No newline at end of file diff --git a/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.attributes.js b/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.attributes.js index ded8c07..2e244af 100644 --- a/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.attributes.js +++ b/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.attributes.js @@ -1 +1 @@ -const a272_0x15eb=['sequelize','STRING','exports'];(function(_0x4687a8,_0x15eb52){const _0x35f852=function(_0x14dff2){while(--_0x14dff2){_0x4687a8['push'](_0x4687a8['shift']());}};_0x35f852(++_0x15eb52);}(a272_0x15eb,0x17c));const a272_0x35f8=function(_0x4687a8,_0x15eb52){_0x4687a8=_0x4687a8-0x0;let _0x35f852=a272_0x15eb[_0x4687a8];return _0x35f852;};const _0x1c7307=a272_0x35f8;'use strict';const Sequelize=require(_0x1c7307('0x1'));module[_0x1c7307('0x0')]={'name':{'type':Sequelize[_0x1c7307('0x2')]},'description':{'type':Sequelize[_0x1c7307('0x2')]}}; \ No newline at end of file +const a272_0x2237=['STRING','sequelize'];(function(_0xcf099,_0x2237e7){const _0x275914=function(_0x172e95){while(--_0x172e95){_0xcf099['push'](_0xcf099['shift']());}};_0x275914(++_0x2237e7);}(a272_0x2237,0x180));const a272_0x2759=function(_0xcf099,_0x2237e7){_0xcf099=_0xcf099-0x0;let _0x275914=a272_0x2237[_0xcf099];return _0x275914;};const _0x5ce2a4=a272_0x2759;'use strict';const Sequelize=require(_0x5ce2a4('0x1'));module['exports']={'name':{'type':Sequelize[_0x5ce2a4('0x0')]},'description':{'type':Sequelize[_0x5ce2a4('0x0')]}}; \ No newline at end of file diff --git a/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.controller.js b/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.controller.js index cb8fe28..9d80b12 100644 --- a/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.controller.js +++ b/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.controller.js @@ -1 +1 @@ -const a273_0x4949=['findOne','key','map','then','params','merge','../../config/logger','json','like','../../components/parsers/qs','query','getFields','body','where','Content-Range','rawAttributes','sequelize','fieldName','intersection','lodash','options','set','FreshsalesConfiguration','create','include','keys','FreshsalesField','filters','limit','count','includeAll','length','type','undefined','destroy','status','name','stack','pick','order','update','nolimit','fields','api','send','getDescriptions','sort','catch','model','findAll','end','getSubjects','attributes','offset','filter'];(function(_0x256ccf,_0x4949e2){const _0x3b766e=function(_0x4197f9){while(--_0x4197f9){_0x256ccf['push'](_0x256ccf['shift']());}};_0x3b766e(++_0x4949e2);}(a273_0x4949,0x86));const a273_0x3b76=function(_0x256ccf,_0x4949e2){_0x256ccf=_0x256ccf-0x0;let _0x3b766e=a273_0x4949[_0x256ccf];return _0x3b766e;};const _0x9a1785=a273_0x3b76;'use strict';const _=require(_0x9a1785('0x32')),qs=require(_0x9a1785('0x28')),logger=require(_0x9a1785('0x25'))(_0x9a1785('0x13')),db=require('../../mysqldb')['db'],{Op}=require(_0x9a1785('0x2f'));function respondWithResult(_0x4197f9,_0x546dd8){return _0x546dd8=_0x546dd8||0xc8,function(_0x495540){const _0x2951a8=a273_0x3b76;if(_0x495540)return _0x4197f9[_0x2951a8('0xb')](_0x546dd8)['json'](_0x495540);};}function respondWithFilteredResult(_0x1ac59c,_0x56ad58){return function(_0x172841){const _0x3a1692=a273_0x3b76;if(_0x172841){const _0x2ab567=_0x172841[_0x3a1692('0x5')],_0x23944c=_0x56ad58[_0x3a1692('0x1d')];let _0x1690d6=_0x56ad58['offset']+_0x56ad58[_0x3a1692('0x4')],_0x4ef7a1;return _0x1690d6>=_0x2ab567?(_0x1690d6=_0x2ab567,_0x4ef7a1=0xc8):_0x4ef7a1=0xce,_0x1ac59c[_0x3a1692('0xb')](_0x4ef7a1),_0x1ac59c[_0x3a1692('0x34')](_0x3a1692('0x2d'),_0x23944c+'-'+_0x1690d6+'/'+_0x2ab567)[_0x3a1692('0x26')](_0x172841);}return null;};}function saveUpdates(_0x126f16){return function(_0x5b004a){const _0x1e6ce0=a273_0x3b76;if(_0x5b004a)return _0x5b004a[_0x1e6ce0('0x10')](_0x126f16)[_0x1e6ce0('0x22')](function(_0x3b15cc){return _0x3b15cc;});return null;};}function removeEntity(_0x1cbf37){return function(_0x3078e){const _0x11e3f5=a273_0x3b76;if(_0x3078e)return _0x3078e[_0x11e3f5('0xa')]()['then'](function(){const _0x16c693=_0x11e3f5;_0x1cbf37[_0x16c693('0xb')](0xcc)[_0x16c693('0x1a')]();});};}function handleEntityNotFound(_0xfa087f){return function(_0x4d95ec){return!_0x4d95ec&&_0xfa087f['sendStatus'](0x194),_0x4d95ec;};}function handleError(_0x3ff9b3,_0x515efd){return _0x515efd=_0x515efd||0x1f4,function(_0x4a788d){const _0x177bb5=a273_0x3b76;logger['error'](_0x4a788d[_0x177bb5('0xd')]),_0x4a788d[_0x177bb5('0xc')]&&delete _0x4a788d[_0x177bb5('0xc')],_0x3ff9b3[_0x177bb5('0xb')](_0x515efd)[_0x177bb5('0x14')](_0x4a788d);};}exports['index']=function(_0x2672b4,_0x109b60){const _0x408650=_0x9a1785;let _0x1734c6={};const _0x19686f={},_0x442f3e={'count':0x0,'rows':[]},_0x3a4d6f=_['map'](db[_0x408650('0x35')][_0x408650('0x2e')],function(_0x23ee38){const _0x330764=_0x408650;return{'name':_0x23ee38[_0x330764('0x30')],'type':_0x23ee38[_0x330764('0x8')][_0x330764('0x20')]};});_0x19686f['model']=_[_0x408650('0x21')](_0x3a4d6f,_0x408650('0xc')),_0x19686f[_0x408650('0x29')]=_['keys'](_0x2672b4['query']),_0x19686f['filters']=_[_0x408650('0x31')](_0x19686f[_0x408650('0x18')],_0x19686f[_0x408650('0x29')]),_0x1734c6['attributes']=_[_0x408650('0x31')](_0x19686f[_0x408650('0x18')],qs[_0x408650('0x12')](_0x2672b4[_0x408650('0x29')]['fields'])),_0x1734c6[_0x408650('0x1c')]=_0x1734c6[_0x408650('0x1c')][_0x408650('0x7')]?_0x1734c6['attributes']:_0x19686f[_0x408650('0x18')];typeof _0x2672b4[_0x408650('0x29')][_0x408650('0x11')]===_0x408650('0x9')&&(_0x1734c6['limit']=qs[_0x408650('0x4')](_0x2672b4[_0x408650('0x29')][_0x408650('0x4')]),_0x1734c6[_0x408650('0x1d')]=qs[_0x408650('0x1d')](_0x2672b4[_0x408650('0x29')][_0x408650('0x1d')]));_0x1734c6[_0x408650('0xf')]=qs[_0x408650('0x16')](_0x2672b4[_0x408650('0x29')][_0x408650('0x16')]),_0x1734c6[_0x408650('0x2c')]=qs['filters'](_['pick'](_0x2672b4[_0x408650('0x29')],_0x19686f['filters']),_0x3a4d6f);_0x2672b4['query'][_0x408650('0x1e')]&&(_0x1734c6['where']=_['merge'](_0x1734c6[_0x408650('0x2c')],{[Op['or']]:_['map'](_0x3a4d6f,function(_0xc35142){const _0x11c046=_0x408650;if(_0xc35142[_0x11c046('0x8')]!=='VIRTUAL'){const _0x1f8259={};return _0x1f8259[_0xc35142['name']]={[Op[_0x11c046('0x27')]]:'%'+_0x2672b4[_0x11c046('0x29')]['filter']+'%'},_0x1f8259;}})}));_0x1734c6=_['merge']({},_0x1734c6,_0x2672b4[_0x408650('0x33')]);const _0x4893c8={'where':_0x1734c6[_0x408650('0x2c')]};return db[_0x408650('0x35')][_0x408650('0x5')](_0x4893c8)['then'](function(_0x784fdf){const _0x5299ee=_0x408650;return _0x442f3e['count']=_0x784fdf,_0x2672b4[_0x5299ee('0x29')][_0x5299ee('0x6')]&&(_0x1734c6[_0x5299ee('0x0')]=[{'all':!![]}]),db[_0x5299ee('0x35')][_0x5299ee('0x19')](_0x1734c6);})[_0x408650('0x22')](function(_0x27b19e){return _0x442f3e['rows']=_0x27b19e,_0x442f3e;})['then'](respondWithFilteredResult(_0x109b60,_0x1734c6))[_0x408650('0x17')](handleError(_0x109b60,null));},exports['show']=function(_0x2aafcf,_0x85f63c){const _0x490279=_0x9a1785;let _0x6d96dd={'raw':![],'where':{'id':_0x2aafcf[_0x490279('0x23')]['id']}};const _0x46d5cc={};return _0x46d5cc[_0x490279('0x18')]=_[_0x490279('0x1')](db['FreshsalesConfiguration'][_0x490279('0x2e')]),_0x46d5cc[_0x490279('0x29')]=_[_0x490279('0x1')](_0x2aafcf['query']),_0x46d5cc['filters']=_[_0x490279('0x31')](_0x46d5cc[_0x490279('0x18')],_0x46d5cc[_0x490279('0x29')]),_0x6d96dd[_0x490279('0x1c')]=_[_0x490279('0x31')](_0x46d5cc['model'],qs[_0x490279('0x12')](_0x2aafcf[_0x490279('0x29')]['fields'])),_0x6d96dd[_0x490279('0x1c')]=_0x6d96dd['attributes'][_0x490279('0x7')]?_0x6d96dd[_0x490279('0x1c')]:_0x46d5cc['model'],_0x2aafcf[_0x490279('0x29')]['includeAll']&&(_0x6d96dd[_0x490279('0x0')]=[{'all':!![]}]),_0x6d96dd=_[_0x490279('0x24')]({},_0x6d96dd,_0x2aafcf[_0x490279('0x33')]),db[_0x490279('0x35')][_0x490279('0x1f')](_0x6d96dd)[_0x490279('0x22')](handleEntityNotFound(_0x85f63c,null))[_0x490279('0x22')](respondWithResult(_0x85f63c,null))[_0x490279('0x17')](handleError(_0x85f63c,null));},exports[_0x9a1785('0x36')]=function(_0x28505c,_0xcc0245){const _0x526f37=_0x9a1785;return db[_0x526f37('0x35')][_0x526f37('0x36')](_0x28505c[_0x526f37('0x2b')],{})[_0x526f37('0x22')](respondWithResult(_0xcc0245,0xc9))[_0x526f37('0x17')](handleError(_0xcc0245,null));},exports['update']=function(_0x373dfd,_0x12e346){const _0xc79652=_0x9a1785;return _0x373dfd['body']['id']&&delete _0x373dfd[_0xc79652('0x2b')]['id'],db[_0xc79652('0x35')][_0xc79652('0x1f')]({'where':{'id':_0x373dfd[_0xc79652('0x23')]['id']}})[_0xc79652('0x22')](handleEntityNotFound(_0x12e346,null))[_0xc79652('0x22')](saveUpdates(_0x373dfd[_0xc79652('0x2b')],null))[_0xc79652('0x22')](respondWithResult(_0x12e346,null))[_0xc79652('0x17')](handleError(_0x12e346,null));},exports['destroy']=function(_0x2d10f2,_0x4211c4){const _0x374893=_0x9a1785;return db[_0x374893('0x35')][_0x374893('0x1f')]({'where':{'id':_0x2d10f2[_0x374893('0x23')]['id']}})['then'](handleEntityNotFound(_0x4211c4,null))[_0x374893('0x22')](removeEntity(_0x4211c4,null))[_0x374893('0x17')](handleError(_0x4211c4,null));},exports['getSubjects']=function(_0x3e8b80,_0x3ae0c7){const _0x21d7d7=_0x9a1785;let _0x5ad161={};const _0x2ee781={};let _0x3a2dcb,_0x472c8d;return db[_0x21d7d7('0x35')]['findOne']({'where':{'id':_0x3e8b80['params']['id']}})['then'](handleEntityNotFound(_0x3ae0c7,null))[_0x21d7d7('0x22')](function(_0x392470){const _0x186390=_0x21d7d7;if(_0x392470)return _0x3a2dcb=_0x392470,_0x2ee781[_0x186390('0x18')]=_[_0x186390('0x1')](db[_0x186390('0x2')]['rawAttributes']),_0x2ee781[_0x186390('0x29')]=_[_0x186390('0x1')](_0x3e8b80['query']),_0x2ee781[_0x186390('0x3')]=_[_0x186390('0x31')](_0x2ee781[_0x186390('0x18')],_0x2ee781['query']),_0x5ad161[_0x186390('0x1c')]=_[_0x186390('0x31')](_0x2ee781[_0x186390('0x18')],qs[_0x186390('0x12')](_0x3e8b80[_0x186390('0x29')][_0x186390('0x12')])),_0x5ad161[_0x186390('0x1c')]=_0x5ad161[_0x186390('0x1c')][_0x186390('0x7')]?_0x5ad161[_0x186390('0x1c')]:_0x2ee781['model'],_0x5ad161[_0x186390('0xf')]=qs[_0x186390('0x16')](_0x3e8b80[_0x186390('0x29')][_0x186390('0x16')]),_0x5ad161['where']=qs[_0x186390('0x3')](_['pick'](_0x3e8b80[_0x186390('0x29')],_0x2ee781[_0x186390('0x3')])),_0x3e8b80[_0x186390('0x29')][_0x186390('0x1e')]&&(_0x5ad161[_0x186390('0x2c')]=_['merge'](_0x5ad161[_0x186390('0x2c')],{[Op['or']]:_[_0x186390('0x21')](_0x5ad161[_0x186390('0x1c')],function(_0x33fd88){const _0x4f95b6=_0x186390,_0xa27310={};return _0xa27310[_0x33fd88]={[Op['like']]:'%'+_0x3e8b80[_0x4f95b6('0x29')][_0x4f95b6('0x1e')]+'%'},_0xa27310;})})),_0x5ad161=_[_0x186390('0x24')]({},_0x5ad161,_0x3e8b80[_0x186390('0x33')]),_0x3a2dcb[_0x186390('0x1b')](_0x5ad161);})['then'](function(_0x351c71){const _0x512210=_0x21d7d7;if(_0x351c71)return _0x472c8d=_0x351c71['length'],typeof _0x3e8b80[_0x512210('0x29')][_0x512210('0x11')]===_0x512210('0x9')&&(_0x5ad161[_0x512210('0x4')]=qs[_0x512210('0x4')](_0x3e8b80[_0x512210('0x29')][_0x512210('0x4')]),_0x5ad161[_0x512210('0x1d')]=qs[_0x512210('0x1d')](_0x3e8b80[_0x512210('0x29')]['offset'])),_0x3a2dcb['getSubjects'](_0x5ad161);})['then'](function(_0xd32b69){if(_0xd32b69)return _0xd32b69?{'count':_0x472c8d,'rows':_0xd32b69}:null;})['then'](respondWithResult(_0x3ae0c7,null))[_0x21d7d7('0x17')](handleError(_0x3ae0c7,null));},exports[_0x9a1785('0x15')]=function(_0x7afcb2,_0x137def){const _0x175aa2=_0x9a1785;let _0x2ab847={};const _0xe45d00={};let _0x189829,_0x43ae64;return db['FreshsalesConfiguration'][_0x175aa2('0x1f')]({'where':{'id':_0x7afcb2['params']['id']}})[_0x175aa2('0x22')](handleEntityNotFound(_0x137def,null))[_0x175aa2('0x22')](function(_0x2b374a){const _0x18be30=_0x175aa2;if(_0x2b374a)return _0x189829=_0x2b374a,_0xe45d00[_0x18be30('0x18')]=_[_0x18be30('0x1')](db[_0x18be30('0x2')][_0x18be30('0x2e')]),_0xe45d00['query']=_['keys'](_0x7afcb2[_0x18be30('0x29')]),_0xe45d00[_0x18be30('0x3')]=_['intersection'](_0xe45d00[_0x18be30('0x18')],_0xe45d00[_0x18be30('0x29')]),_0x2ab847[_0x18be30('0x1c')]=_[_0x18be30('0x31')](_0xe45d00['model'],qs[_0x18be30('0x12')](_0x7afcb2['query'][_0x18be30('0x12')])),_0x2ab847[_0x18be30('0x1c')]=_0x2ab847[_0x18be30('0x1c')][_0x18be30('0x7')]?_0x2ab847[_0x18be30('0x1c')]:_0xe45d00['model'],_0x2ab847[_0x18be30('0xf')]=qs['sort'](_0x7afcb2['query'][_0x18be30('0x16')]),_0x2ab847[_0x18be30('0x2c')]=qs[_0x18be30('0x3')](_['pick'](_0x7afcb2[_0x18be30('0x29')],_0xe45d00[_0x18be30('0x3')])),_0x7afcb2['query'][_0x18be30('0x1e')]&&(_0x2ab847[_0x18be30('0x2c')]=_[_0x18be30('0x24')](_0x2ab847[_0x18be30('0x2c')],{[Op['or']]:_[_0x18be30('0x21')](_0x2ab847[_0x18be30('0x1c')],function(_0x3a5f8f){const _0x26e90b=_0x18be30,_0x232fd9={};return _0x232fd9[_0x3a5f8f]={[Op[_0x26e90b('0x27')]]:'%'+_0x7afcb2[_0x26e90b('0x29')][_0x26e90b('0x1e')]+'%'},_0x232fd9;})})),_0x2ab847=_['merge']({},_0x2ab847,_0x7afcb2[_0x18be30('0x33')]),_0x189829[_0x18be30('0x15')](_0x2ab847);})[_0x175aa2('0x22')](function(_0x29b993){const _0x4455c0=_0x175aa2;if(_0x29b993)return _0x43ae64=_0x29b993[_0x4455c0('0x7')],typeof _0x7afcb2[_0x4455c0('0x29')]['nolimit']===_0x4455c0('0x9')&&(_0x2ab847[_0x4455c0('0x4')]=qs[_0x4455c0('0x4')](_0x7afcb2[_0x4455c0('0x29')][_0x4455c0('0x4')]),_0x2ab847[_0x4455c0('0x1d')]=qs[_0x4455c0('0x1d')](_0x7afcb2[_0x4455c0('0x29')][_0x4455c0('0x1d')])),_0x189829[_0x4455c0('0x15')](_0x2ab847);})[_0x175aa2('0x22')](function(_0x556722){if(_0x556722)return _0x556722?{'count':_0x43ae64,'rows':_0x556722}:null;})[_0x175aa2('0x22')](respondWithResult(_0x137def,null))['catch'](handleError(_0x137def,null));},exports[_0x9a1785('0x2a')]=function(_0x20fe5e,_0x14faf4){const _0x437d0f=_0x9a1785;let _0x347d01={};const _0xaac1eb={};let _0x4c56c6,_0x55c853;return db[_0x437d0f('0x35')][_0x437d0f('0x1f')]({'where':{'id':_0x20fe5e[_0x437d0f('0x23')]['id']}})[_0x437d0f('0x22')](handleEntityNotFound(_0x14faf4,null))[_0x437d0f('0x22')](function(_0x189ff9){const _0xa908a1=_0x437d0f;if(_0x189ff9)return _0x4c56c6=_0x189ff9,_0xaac1eb[_0xa908a1('0x18')]=_[_0xa908a1('0x1')](db[_0xa908a1('0x2')][_0xa908a1('0x2e')]),_0xaac1eb[_0xa908a1('0x29')]=_[_0xa908a1('0x1')](_0x20fe5e[_0xa908a1('0x29')]),_0xaac1eb['filters']=_['intersection'](_0xaac1eb[_0xa908a1('0x18')],_0xaac1eb['query']),_0x347d01[_0xa908a1('0x1c')]=_['intersection'](_0xaac1eb[_0xa908a1('0x18')],qs[_0xa908a1('0x12')](_0x20fe5e[_0xa908a1('0x29')][_0xa908a1('0x12')])),_0x347d01[_0xa908a1('0x1c')]=_0x347d01[_0xa908a1('0x1c')]['length']?_0x347d01[_0xa908a1('0x1c')]:_0xaac1eb['model'],_0x347d01[_0xa908a1('0xf')]=qs[_0xa908a1('0x16')](_0x20fe5e[_0xa908a1('0x29')][_0xa908a1('0x16')]),_0x347d01[_0xa908a1('0x2c')]=qs[_0xa908a1('0x3')](_[_0xa908a1('0xe')](_0x20fe5e[_0xa908a1('0x29')],_0xaac1eb[_0xa908a1('0x3')])),_0x20fe5e['query'][_0xa908a1('0x1e')]&&(_0x347d01[_0xa908a1('0x2c')]=_['merge'](_0x347d01[_0xa908a1('0x2c')],{[Op['or']]:_[_0xa908a1('0x21')](_0x347d01[_0xa908a1('0x1c')],function(_0x1885b9){const _0x903c89=_0xa908a1,_0x2602ed={};return _0x2602ed[_0x1885b9]={[Op[_0x903c89('0x27')]]:'%'+_0x20fe5e[_0x903c89('0x29')]['filter']+'%'},_0x2602ed;})})),_0x347d01=_[_0xa908a1('0x24')]({},_0x347d01,_0x20fe5e['options']),_0x4c56c6[_0xa908a1('0x2a')](_0x347d01);})[_0x437d0f('0x22')](function(_0x44a0c5){const _0x1d17c8=_0x437d0f;if(_0x44a0c5)return _0x55c853=_0x44a0c5['length'],typeof _0x20fe5e['query'][_0x1d17c8('0x11')]===_0x1d17c8('0x9')&&(_0x347d01['limit']=qs[_0x1d17c8('0x4')](_0x20fe5e[_0x1d17c8('0x29')][_0x1d17c8('0x4')]),_0x347d01['offset']=qs[_0x1d17c8('0x1d')](_0x20fe5e[_0x1d17c8('0x29')]['offset'])),_0x4c56c6[_0x1d17c8('0x2a')](_0x347d01);})['then'](function(_0x658a3b){if(_0x658a3b)return _0x658a3b?{'count':_0x55c853,'rows':_0x658a3b}:null;})[_0x437d0f('0x22')](respondWithResult(_0x14faf4,null))[_0x437d0f('0x17')](handleError(_0x14faf4,null));}; \ No newline at end of file +const a273_0x5999=['catch','getDescriptions','map','name','getSubjects','sort','limit','includeAll','FreshsalesField','body','merge','filter','attributes','FreshsalesConfiguration','intersection','undefined','fields','update','include','sendStatus','../../components/parsers/qs','rawAttributes','filters','getFields','destroy','nolimit','params','stack','where','end','show','like','length','type','findOne','query','create','order','offset','api','index','../../mysqldb','pick','status','json','count','keys','lodash','set','model','rows','then','options'];(function(_0x5aafd3,_0x599972){const _0x47351e=function(_0x2f9b1a){while(--_0x2f9b1a){_0x5aafd3['push'](_0x5aafd3['shift']());}};_0x47351e(++_0x599972);}(a273_0x5999,0xb2));const a273_0x4735=function(_0x5aafd3,_0x599972){_0x5aafd3=_0x5aafd3-0x0;let _0x47351e=a273_0x5999[_0x5aafd3];return _0x47351e;};const _0x31163b=a273_0x4735;'use strict';const _=require(_0x31163b('0x1c')),qs=require(_0x31163b('0x1')),logger=require('../../config/logger')(_0x31163b('0x14')),db=require(_0x31163b('0x16'))['db'],{Op}=require('sequelize');function respondWithResult(_0x2f9b1a,_0x5db716){return _0x5db716=_0x5db716||0xc8,function(_0x67dd8){const _0x2201ca=a273_0x4735;if(_0x67dd8)return _0x2f9b1a[_0x2201ca('0x18')](_0x5db716)[_0x2201ca('0x19')](_0x67dd8);};}function respondWithFilteredResult(_0x16eaeb,_0x350391){return function(_0x1e271a){const _0x12cf79=a273_0x4735;if(_0x1e271a){const _0x9a238d=_0x1e271a[_0x12cf79('0x1a')],_0x9d5165=_0x350391['offset'];let _0x35abf6=_0x350391['offset']+_0x350391[_0x12cf79('0x28')],_0x2722b2;return _0x35abf6>=_0x9a238d?(_0x35abf6=_0x9a238d,_0x2722b2=0xc8):_0x2722b2=0xce,_0x16eaeb[_0x12cf79('0x18')](_0x2722b2),_0x16eaeb[_0x12cf79('0x1d')]('Content-Range',_0x9d5165+'-'+_0x35abf6+'/'+_0x9a238d)[_0x12cf79('0x19')](_0x1e271a);}return null;};}function saveUpdates(_0xfcb3bb){return function(_0xb43eb4){if(_0xb43eb4)return _0xb43eb4['update'](_0xfcb3bb)['then'](function(_0x2f50a5){return _0x2f50a5;});return null;};}function removeEntity(_0x559889){return function(_0x273d6b){const _0x582f13=a273_0x4735;if(_0x273d6b)return _0x273d6b[_0x582f13('0x5')]()[_0x582f13('0x20')](function(){const _0x39d9ea=_0x582f13;_0x559889[_0x39d9ea('0x18')](0xcc)[_0x39d9ea('0xa')]();});};}function handleEntityNotFound(_0x115714){return function(_0x3eea80){const _0x3e862d=a273_0x4735;return!_0x3eea80&&_0x115714[_0x3e862d('0x0')](0x194),_0x3eea80;};}function handleError(_0x5a05e6,_0x3a7bc5){return _0x3a7bc5=_0x3a7bc5||0x1f4,function(_0x685160){const _0xa1f57=a273_0x4735;logger['error'](_0x685160[_0xa1f57('0x8')]),_0x685160[_0xa1f57('0x25')]&&delete _0x685160['name'],_0x5a05e6[_0xa1f57('0x18')](_0x3a7bc5)['send'](_0x685160);};}exports[_0x31163b('0x15')]=function(_0xdad2db,_0x5507e6){const _0x236668=_0x31163b;let _0x12fd14={};const _0x4df7a7={},_0x37be5b={'count':0x0,'rows':[]},_0x352a81=_[_0x236668('0x24')](db[_0x236668('0x2f')][_0x236668('0x2')],function(_0x415a1d){const _0x52735e=_0x236668;return{'name':_0x415a1d['fieldName'],'type':_0x415a1d[_0x52735e('0xe')]['key']};});_0x4df7a7['model']=_[_0x236668('0x24')](_0x352a81,_0x236668('0x25')),_0x4df7a7[_0x236668('0x10')]=_['keys'](_0xdad2db[_0x236668('0x10')]),_0x4df7a7['filters']=_[_0x236668('0x30')](_0x4df7a7[_0x236668('0x1e')],_0x4df7a7[_0x236668('0x10')]),_0x12fd14[_0x236668('0x2e')]=_[_0x236668('0x30')](_0x4df7a7[_0x236668('0x1e')],qs[_0x236668('0x32')](_0xdad2db['query'][_0x236668('0x32')])),_0x12fd14[_0x236668('0x2e')]=_0x12fd14[_0x236668('0x2e')][_0x236668('0xd')]?_0x12fd14['attributes']:_0x4df7a7[_0x236668('0x1e')];typeof _0xdad2db['query']['nolimit']==='undefined'&&(_0x12fd14['limit']=qs['limit'](_0xdad2db[_0x236668('0x10')][_0x236668('0x28')]),_0x12fd14[_0x236668('0x13')]=qs['offset'](_0xdad2db['query']['offset']));_0x12fd14[_0x236668('0x12')]=qs[_0x236668('0x27')](_0xdad2db['query']['sort']),_0x12fd14[_0x236668('0x9')]=qs[_0x236668('0x3')](_[_0x236668('0x17')](_0xdad2db[_0x236668('0x10')],_0x4df7a7[_0x236668('0x3')]),_0x352a81);_0xdad2db[_0x236668('0x10')][_0x236668('0x2d')]&&(_0x12fd14[_0x236668('0x9')]=_[_0x236668('0x2c')](_0x12fd14[_0x236668('0x9')],{[Op['or']]:_[_0x236668('0x24')](_0x352a81,function(_0x2ec881){const _0x20b7d6=_0x236668;if(_0x2ec881[_0x20b7d6('0xe')]!=='VIRTUAL'){const _0x4ab35e={};return _0x4ab35e[_0x2ec881[_0x20b7d6('0x25')]]={[Op[_0x20b7d6('0xc')]]:'%'+_0xdad2db['query'][_0x20b7d6('0x2d')]+'%'},_0x4ab35e;}})}));_0x12fd14=_[_0x236668('0x2c')]({},_0x12fd14,_0xdad2db['options']);const _0x3e73dd={'where':_0x12fd14[_0x236668('0x9')]};return db[_0x236668('0x2f')][_0x236668('0x1a')](_0x3e73dd)['then'](function(_0x22de81){const _0xfda04e=_0x236668;return _0x37be5b[_0xfda04e('0x1a')]=_0x22de81,_0xdad2db[_0xfda04e('0x10')][_0xfda04e('0x29')]&&(_0x12fd14[_0xfda04e('0x34')]=[{'all':!![]}]),db[_0xfda04e('0x2f')]['findAll'](_0x12fd14);})['then'](function(_0x498d1e){const _0x3e3ea5=_0x236668;return _0x37be5b[_0x3e3ea5('0x1f')]=_0x498d1e,_0x37be5b;})[_0x236668('0x20')](respondWithFilteredResult(_0x5507e6,_0x12fd14))[_0x236668('0x22')](handleError(_0x5507e6,null));},exports[_0x31163b('0xb')]=function(_0x2e9ee0,_0xd46067){const _0x49374b=_0x31163b;let _0x3f576d={'raw':![],'where':{'id':_0x2e9ee0[_0x49374b('0x7')]['id']}};const _0x3e4ebc={};return _0x3e4ebc[_0x49374b('0x1e')]=_[_0x49374b('0x1b')](db[_0x49374b('0x2f')][_0x49374b('0x2')]),_0x3e4ebc['query']=_[_0x49374b('0x1b')](_0x2e9ee0['query']),_0x3e4ebc[_0x49374b('0x3')]=_['intersection'](_0x3e4ebc['model'],_0x3e4ebc[_0x49374b('0x10')]),_0x3f576d[_0x49374b('0x2e')]=_[_0x49374b('0x30')](_0x3e4ebc['model'],qs[_0x49374b('0x32')](_0x2e9ee0['query']['fields'])),_0x3f576d[_0x49374b('0x2e')]=_0x3f576d[_0x49374b('0x2e')][_0x49374b('0xd')]?_0x3f576d[_0x49374b('0x2e')]:_0x3e4ebc['model'],_0x2e9ee0[_0x49374b('0x10')][_0x49374b('0x29')]&&(_0x3f576d[_0x49374b('0x34')]=[{'all':!![]}]),_0x3f576d=_[_0x49374b('0x2c')]({},_0x3f576d,_0x2e9ee0['options']),db[_0x49374b('0x2f')]['findOne'](_0x3f576d)[_0x49374b('0x20')](handleEntityNotFound(_0xd46067,null))[_0x49374b('0x20')](respondWithResult(_0xd46067,null))['catch'](handleError(_0xd46067,null));},exports['create']=function(_0x33c727,_0x42de6f){const _0x2cd7f7=_0x31163b;return db[_0x2cd7f7('0x2f')][_0x2cd7f7('0x11')](_0x33c727[_0x2cd7f7('0x2b')],{})[_0x2cd7f7('0x20')](respondWithResult(_0x42de6f,0xc9))[_0x2cd7f7('0x22')](handleError(_0x42de6f,null));},exports[_0x31163b('0x33')]=function(_0x1ea2ba,_0x3c96a3){const _0x10ae65=_0x31163b;return _0x1ea2ba['body']['id']&&delete _0x1ea2ba['body']['id'],db[_0x10ae65('0x2f')]['findOne']({'where':{'id':_0x1ea2ba[_0x10ae65('0x7')]['id']}})[_0x10ae65('0x20')](handleEntityNotFound(_0x3c96a3,null))[_0x10ae65('0x20')](saveUpdates(_0x1ea2ba[_0x10ae65('0x2b')],null))['then'](respondWithResult(_0x3c96a3,null))[_0x10ae65('0x22')](handleError(_0x3c96a3,null));},exports['destroy']=function(_0x35a5e0,_0x4261fe){const _0x31ab2d=_0x31163b;return db['FreshsalesConfiguration'][_0x31ab2d('0xf')]({'where':{'id':_0x35a5e0[_0x31ab2d('0x7')]['id']}})[_0x31ab2d('0x20')](handleEntityNotFound(_0x4261fe,null))[_0x31ab2d('0x20')](removeEntity(_0x4261fe,null))[_0x31ab2d('0x22')](handleError(_0x4261fe,null));},exports[_0x31163b('0x26')]=function(_0x1a6404,_0x487441){const _0x4c6542=_0x31163b;let _0x53db97={};const _0x4c2296={};let _0x1d506e,_0x5e39a9;return db[_0x4c6542('0x2f')][_0x4c6542('0xf')]({'where':{'id':_0x1a6404[_0x4c6542('0x7')]['id']}})[_0x4c6542('0x20')](handleEntityNotFound(_0x487441,null))[_0x4c6542('0x20')](function(_0x3acda4){const _0x298b1e=_0x4c6542;if(_0x3acda4)return _0x1d506e=_0x3acda4,_0x4c2296[_0x298b1e('0x1e')]=_['keys'](db[_0x298b1e('0x2a')][_0x298b1e('0x2')]),_0x4c2296[_0x298b1e('0x10')]=_[_0x298b1e('0x1b')](_0x1a6404['query']),_0x4c2296[_0x298b1e('0x3')]=_['intersection'](_0x4c2296[_0x298b1e('0x1e')],_0x4c2296[_0x298b1e('0x10')]),_0x53db97['attributes']=_[_0x298b1e('0x30')](_0x4c2296['model'],qs[_0x298b1e('0x32')](_0x1a6404[_0x298b1e('0x10')]['fields'])),_0x53db97[_0x298b1e('0x2e')]=_0x53db97[_0x298b1e('0x2e')]['length']?_0x53db97['attributes']:_0x4c2296['model'],_0x53db97[_0x298b1e('0x12')]=qs[_0x298b1e('0x27')](_0x1a6404['query'][_0x298b1e('0x27')]),_0x53db97[_0x298b1e('0x9')]=qs[_0x298b1e('0x3')](_[_0x298b1e('0x17')](_0x1a6404[_0x298b1e('0x10')],_0x4c2296[_0x298b1e('0x3')])),_0x1a6404[_0x298b1e('0x10')][_0x298b1e('0x2d')]&&(_0x53db97[_0x298b1e('0x9')]=_[_0x298b1e('0x2c')](_0x53db97['where'],{[Op['or']]:_[_0x298b1e('0x24')](_0x53db97[_0x298b1e('0x2e')],function(_0x35379b){const _0x1c3b3b=_0x298b1e,_0x1bc977={};return _0x1bc977[_0x35379b]={[Op[_0x1c3b3b('0xc')]]:'%'+_0x1a6404[_0x1c3b3b('0x10')][_0x1c3b3b('0x2d')]+'%'},_0x1bc977;})})),_0x53db97=_[_0x298b1e('0x2c')]({},_0x53db97,_0x1a6404['options']),_0x1d506e[_0x298b1e('0x26')](_0x53db97);})['then'](function(_0x320949){const _0x286a3b=_0x4c6542;if(_0x320949)return _0x5e39a9=_0x320949['length'],typeof _0x1a6404[_0x286a3b('0x10')][_0x286a3b('0x6')]===_0x286a3b('0x31')&&(_0x53db97[_0x286a3b('0x28')]=qs[_0x286a3b('0x28')](_0x1a6404[_0x286a3b('0x10')][_0x286a3b('0x28')]),_0x53db97[_0x286a3b('0x13')]=qs[_0x286a3b('0x13')](_0x1a6404['query'][_0x286a3b('0x13')])),_0x1d506e[_0x286a3b('0x26')](_0x53db97);})['then'](function(_0x529207){if(_0x529207)return _0x529207?{'count':_0x5e39a9,'rows':_0x529207}:null;})[_0x4c6542('0x20')](respondWithResult(_0x487441,null))[_0x4c6542('0x22')](handleError(_0x487441,null));},exports['getDescriptions']=function(_0x484cc2,_0x182c88){const _0x30af28=_0x31163b;let _0x5c60c1={};const _0x3ea8b1={};let _0xd81f64,_0x1716f3;return db[_0x30af28('0x2f')]['findOne']({'where':{'id':_0x484cc2[_0x30af28('0x7')]['id']}})[_0x30af28('0x20')](handleEntityNotFound(_0x182c88,null))[_0x30af28('0x20')](function(_0x2f98c9){const _0x3ab9b9=_0x30af28;if(_0x2f98c9)return _0xd81f64=_0x2f98c9,_0x3ea8b1[_0x3ab9b9('0x1e')]=_['keys'](db['FreshsalesField'][_0x3ab9b9('0x2')]),_0x3ea8b1['query']=_[_0x3ab9b9('0x1b')](_0x484cc2[_0x3ab9b9('0x10')]),_0x3ea8b1[_0x3ab9b9('0x3')]=_[_0x3ab9b9('0x30')](_0x3ea8b1[_0x3ab9b9('0x1e')],_0x3ea8b1[_0x3ab9b9('0x10')]),_0x5c60c1['attributes']=_['intersection'](_0x3ea8b1['model'],qs['fields'](_0x484cc2[_0x3ab9b9('0x10')][_0x3ab9b9('0x32')])),_0x5c60c1['attributes']=_0x5c60c1[_0x3ab9b9('0x2e')]['length']?_0x5c60c1[_0x3ab9b9('0x2e')]:_0x3ea8b1['model'],_0x5c60c1[_0x3ab9b9('0x12')]=qs[_0x3ab9b9('0x27')](_0x484cc2['query'][_0x3ab9b9('0x27')]),_0x5c60c1['where']=qs[_0x3ab9b9('0x3')](_[_0x3ab9b9('0x17')](_0x484cc2[_0x3ab9b9('0x10')],_0x3ea8b1['filters'])),_0x484cc2['query'][_0x3ab9b9('0x2d')]&&(_0x5c60c1[_0x3ab9b9('0x9')]=_['merge'](_0x5c60c1['where'],{[Op['or']]:_['map'](_0x5c60c1[_0x3ab9b9('0x2e')],function(_0x41d69f){const _0x3b3b9b=_0x3ab9b9,_0x1c2b02={};return _0x1c2b02[_0x41d69f]={[Op[_0x3b3b9b('0xc')]]:'%'+_0x484cc2[_0x3b3b9b('0x10')][_0x3b3b9b('0x2d')]+'%'},_0x1c2b02;})})),_0x5c60c1=_[_0x3ab9b9('0x2c')]({},_0x5c60c1,_0x484cc2[_0x3ab9b9('0x21')]),_0xd81f64[_0x3ab9b9('0x23')](_0x5c60c1);})[_0x30af28('0x20')](function(_0x5158dc){const _0x39e7b7=_0x30af28;if(_0x5158dc)return _0x1716f3=_0x5158dc[_0x39e7b7('0xd')],typeof _0x484cc2[_0x39e7b7('0x10')][_0x39e7b7('0x6')]===_0x39e7b7('0x31')&&(_0x5c60c1[_0x39e7b7('0x28')]=qs[_0x39e7b7('0x28')](_0x484cc2[_0x39e7b7('0x10')][_0x39e7b7('0x28')]),_0x5c60c1['offset']=qs[_0x39e7b7('0x13')](_0x484cc2[_0x39e7b7('0x10')][_0x39e7b7('0x13')])),_0xd81f64['getDescriptions'](_0x5c60c1);})[_0x30af28('0x20')](function(_0x301c2b){if(_0x301c2b)return _0x301c2b?{'count':_0x1716f3,'rows':_0x301c2b}:null;})[_0x30af28('0x20')](respondWithResult(_0x182c88,null))[_0x30af28('0x22')](handleError(_0x182c88,null));},exports[_0x31163b('0x4')]=function(_0xffce6,_0x176e9c){const _0x2f04c1=_0x31163b;let _0x34d04b={};const _0x47c481={};let _0x40ae07,_0x3ba47f;return db[_0x2f04c1('0x2f')][_0x2f04c1('0xf')]({'where':{'id':_0xffce6[_0x2f04c1('0x7')]['id']}})[_0x2f04c1('0x20')](handleEntityNotFound(_0x176e9c,null))[_0x2f04c1('0x20')](function(_0x1cb932){const _0x344c9b=_0x2f04c1;if(_0x1cb932)return _0x40ae07=_0x1cb932,_0x47c481[_0x344c9b('0x1e')]=_[_0x344c9b('0x1b')](db[_0x344c9b('0x2a')][_0x344c9b('0x2')]),_0x47c481['query']=_[_0x344c9b('0x1b')](_0xffce6['query']),_0x47c481[_0x344c9b('0x3')]=_[_0x344c9b('0x30')](_0x47c481['model'],_0x47c481['query']),_0x34d04b[_0x344c9b('0x2e')]=_[_0x344c9b('0x30')](_0x47c481['model'],qs[_0x344c9b('0x32')](_0xffce6[_0x344c9b('0x10')][_0x344c9b('0x32')])),_0x34d04b[_0x344c9b('0x2e')]=_0x34d04b[_0x344c9b('0x2e')]['length']?_0x34d04b['attributes']:_0x47c481[_0x344c9b('0x1e')],_0x34d04b[_0x344c9b('0x12')]=qs['sort'](_0xffce6[_0x344c9b('0x10')][_0x344c9b('0x27')]),_0x34d04b[_0x344c9b('0x9')]=qs[_0x344c9b('0x3')](_[_0x344c9b('0x17')](_0xffce6['query'],_0x47c481['filters'])),_0xffce6[_0x344c9b('0x10')][_0x344c9b('0x2d')]&&(_0x34d04b['where']=_['merge'](_0x34d04b['where'],{[Op['or']]:_[_0x344c9b('0x24')](_0x34d04b[_0x344c9b('0x2e')],function(_0x5f592f){const _0x1b1110=_0x344c9b,_0x5aaff8={};return _0x5aaff8[_0x5f592f]={[Op['like']]:'%'+_0xffce6[_0x1b1110('0x10')][_0x1b1110('0x2d')]+'%'},_0x5aaff8;})})),_0x34d04b=_[_0x344c9b('0x2c')]({},_0x34d04b,_0xffce6[_0x344c9b('0x21')]),_0x40ae07[_0x344c9b('0x4')](_0x34d04b);})[_0x2f04c1('0x20')](function(_0x14b79b){const _0x217b42=_0x2f04c1;if(_0x14b79b)return _0x3ba47f=_0x14b79b[_0x217b42('0xd')],typeof _0xffce6[_0x217b42('0x10')][_0x217b42('0x6')]===_0x217b42('0x31')&&(_0x34d04b[_0x217b42('0x28')]=qs[_0x217b42('0x28')](_0xffce6['query'][_0x217b42('0x28')]),_0x34d04b[_0x217b42('0x13')]=qs[_0x217b42('0x13')](_0xffce6[_0x217b42('0x10')][_0x217b42('0x13')])),_0x40ae07[_0x217b42('0x4')](_0x34d04b);})[_0x2f04c1('0x20')](function(_0x54e841){if(_0x54e841)return _0x54e841?{'count':_0x3ba47f,'rows':_0x54e841}:null;})['then'](respondWithResult(_0x176e9c,null))[_0x2f04c1('0x22')](handleError(_0x176e9c,null));}; \ No newline at end of file diff --git a/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.model.js b/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.model.js index 3807387..8919170 100644 --- a/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.model.js +++ b/server/api/intFreshsalesConfiguration/intFreshsalesConfiguration.model.js @@ -1 +1 @@ -const a274_0x2520=['int_freshsales_configurations','exports','define','FreshsalesConfiguration','./intFreshsalesConfiguration.attributes'];(function(_0xf778e9,_0x252045){const _0x21c336=function(_0x3ff893){while(--_0x3ff893){_0xf778e9['push'](_0xf778e9['shift']());}};_0x21c336(++_0x252045);}(a274_0x2520,0x1a9));const a274_0x21c3=function(_0xf778e9,_0x252045){_0xf778e9=_0xf778e9-0x0;let _0x21c336=a274_0x2520[_0xf778e9];return _0x21c336;};const _0x104a44=a274_0x21c3;'use strict';const attributes=require(_0x104a44('0x4'));module[_0x104a44('0x1')]=function(_0x3ff893){const _0x22a688=_0x104a44,_0x4d81b9=_0x3ff893[_0x22a688('0x2')](_0x22a688('0x3'),attributes,{'tableName':_0x22a688('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x4d81b9;}; \ No newline at end of file +const a274_0x38cf=['define','int_freshsales_configurations','exports'];(function(_0x481020,_0x38cf8b){const _0x1466c9=function(_0x4ff931){while(--_0x4ff931){_0x481020['push'](_0x481020['shift']());}};_0x1466c9(++_0x38cf8b);}(a274_0x38cf,0x1e5));const a274_0x1466=function(_0x481020,_0x38cf8b){_0x481020=_0x481020-0x0;let _0x1466c9=a274_0x38cf[_0x481020];return _0x1466c9;};const _0x2433bd=a274_0x1466;'use strict';const attributes=require('./intFreshsalesConfiguration.attributes');module[_0x2433bd('0x0')]=function(_0x4ff931){const _0x405aeb=_0x2433bd,_0x316d0e=_0x4ff931[_0x405aeb('0x1')]('FreshsalesConfiguration',attributes,{'tableName':_0x405aeb('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x316d0e;}; \ No newline at end of file diff --git a/server/api/intFreshsalesField/index.js b/server/api/intFreshsalesField/index.js index c34466d..c4a161f 100644 --- a/server/api/intFreshsalesField/index.js +++ b/server/api/intFreshsalesField/index.js @@ -1 +1 @@ -const a275_0x2585=['./intFreshsalesField.controller','put','delete','isAuthenticated','index','show','/:id','Router','create','../../components/auth/service','destroy','get','post','update'];(function(_0x5d6191,_0x258521){const _0x227315=function(_0x4ffea6){while(--_0x4ffea6){_0x5d6191['push'](_0x5d6191['shift']());}};_0x227315(++_0x258521);}(a275_0x2585,0x17f));const a275_0x2273=function(_0x5d6191,_0x258521){_0x5d6191=_0x5d6191-0x0;let _0x227315=a275_0x2585[_0x5d6191];return _0x227315;};const _0x5d869c=a275_0x2273;'use strict';const express=require('express'),router=express[_0x5d869c('0x2')](),auth=require(_0x5d869c('0x4')),controller=require(_0x5d869c('0x9'));router['get']('/',auth[_0x5d869c('0xc')](),controller[_0x5d869c('0xd')]),router[_0x5d869c('0x6')]('/:id',auth['isAuthenticated'](),controller[_0x5d869c('0x0')]),router[_0x5d869c('0x7')]('/',auth[_0x5d869c('0xc')](),controller[_0x5d869c('0x3')]),router[_0x5d869c('0xa')](_0x5d869c('0x1'),auth[_0x5d869c('0xc')](),controller[_0x5d869c('0x8')]),router[_0x5d869c('0xb')](_0x5d869c('0x1'),auth[_0x5d869c('0xc')](),controller[_0x5d869c('0x5')]),module['exports']=router; \ No newline at end of file +const a275_0x2a28=['post','delete','/:id','put','./intFreshsalesField.controller','../../components/auth/service','get','update','index','express','Router','create','isAuthenticated'];(function(_0x1343e3,_0x2a28ff){const _0x2256df=function(_0x2f63d5){while(--_0x2f63d5){_0x1343e3['push'](_0x1343e3['shift']());}};_0x2256df(++_0x2a28ff);}(a275_0x2a28,0x160));const a275_0x2256=function(_0x1343e3,_0x2a28ff){_0x1343e3=_0x1343e3-0x0;let _0x2256df=a275_0x2a28[_0x1343e3];return _0x2256df;};const _0x3e3b0a=a275_0x2256;'use strict';const express=require(_0x3e3b0a('0x8')),router=express[_0x3e3b0a('0x9')](),auth=require(_0x3e3b0a('0x4')),controller=require(_0x3e3b0a('0x3'));router[_0x3e3b0a('0x5')]('/',auth[_0x3e3b0a('0xb')](),controller[_0x3e3b0a('0x7')]),router[_0x3e3b0a('0x5')]('/:id',auth[_0x3e3b0a('0xb')](),controller['show']),router[_0x3e3b0a('0xc')]('/',auth['isAuthenticated'](),controller[_0x3e3b0a('0xa')]),router[_0x3e3b0a('0x2')](_0x3e3b0a('0x1'),auth[_0x3e3b0a('0xb')](),controller[_0x3e3b0a('0x6')]),router[_0x3e3b0a('0x0')]('/:id',auth[_0x3e3b0a('0xb')](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/intFreshsalesField/intFreshsalesField.attributes.js b/server/api/intFreshsalesField/intFreshsalesField.attributes.js index 7255c42..3db6317 100644 --- a/server/api/intFreshsalesField/intFreshsalesField.attributes.js +++ b/server/api/intFreshsalesField/intFreshsalesField.attributes.js @@ -1 +1 @@ -const a276_0x5d94=['sequelize','string','ENUM','customVariable','variable','BOOLEAN','exports','keyValue','STRING'];(function(_0x493f07,_0x5d9487){const _0x51df4a=function(_0x371cb4){while(--_0x371cb4){_0x493f07['push'](_0x493f07['shift']());}};_0x51df4a(++_0x5d9487);}(a276_0x5d94,0x77));const a276_0x51df=function(_0x493f07,_0x5d9487){_0x493f07=_0x493f07-0x0;let _0x51df4a=a276_0x5d94[_0x493f07];return _0x51df4a;};const _0x2d5b3f=a276_0x51df;'use strict';const Sequelize=require(_0x2d5b3f('0x7'));module[_0x2d5b3f('0x4')]={'type':{'type':Sequelize[_0x2d5b3f('0x0')](_0x2d5b3f('0x8'),'variable',_0x2d5b3f('0x1'),_0x2d5b3f('0x5')),'defaultValue':'string'},'content':{'type':Sequelize[_0x2d5b3f('0x6')]},'key':{'type':Sequelize[_0x2d5b3f('0x6')]},'keyType':{'type':Sequelize[_0x2d5b3f('0x0')]('string',_0x2d5b3f('0x2'),'customVariable')},'keyContent':{'type':Sequelize[_0x2d5b3f('0x6')]},'idField':{'type':Sequelize[_0x2d5b3f('0x6')]},'nameField':{'type':Sequelize[_0x2d5b3f('0x6')]},'customField':{'type':Sequelize[_0x2d5b3f('0x3')],'defaultValue':!![]},'variableName':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a276_0x27d3=['keyValue','string','ENUM','exports','variable','BOOLEAN','sequelize','customVariable','STRING'];(function(_0xd86be9,_0x27d337){const _0x15123f=function(_0xb3e474){while(--_0xb3e474){_0xd86be9['push'](_0xd86be9['shift']());}};_0x15123f(++_0x27d337);}(a276_0x27d3,0x128));const a276_0x1512=function(_0xd86be9,_0x27d337){_0xd86be9=_0xd86be9-0x0;let _0x15123f=a276_0x27d3[_0xd86be9];return _0x15123f;};const _0x1591e0=a276_0x1512;'use strict';const Sequelize=require(_0x1591e0('0x7'));module[_0x1591e0('0x4')]={'type':{'type':Sequelize['ENUM']('string',_0x1591e0('0x5'),_0x1591e0('0x8'),_0x1591e0('0x1')),'defaultValue':_0x1591e0('0x2')},'content':{'type':Sequelize[_0x1591e0('0x0')]},'key':{'type':Sequelize[_0x1591e0('0x0')]},'keyType':{'type':Sequelize[_0x1591e0('0x3')](_0x1591e0('0x2'),_0x1591e0('0x5'),'customVariable')},'keyContent':{'type':Sequelize[_0x1591e0('0x0')]},'idField':{'type':Sequelize[_0x1591e0('0x0')]},'nameField':{'type':Sequelize['STRING']},'customField':{'type':Sequelize[_0x1591e0('0x6')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x1591e0('0x0')]}}; \ No newline at end of file diff --git a/server/api/intFreshsalesField/intFreshsalesField.controller.js b/server/api/intFreshsalesField/intFreshsalesField.controller.js index d0fc4ff..076cc25 100644 --- a/server/api/intFreshsalesField/intFreshsalesField.controller.js +++ b/server/api/intFreshsalesField/intFreshsalesField.controller.js @@ -1 +1 @@ -const a277_0x1295=['set','destroy','sendStatus','rawAttributes','send','type','intersection','filter','name','body','sequelize','update','offset','keys','like','include','create','filters','status','fields','../../mysqldb','model','fieldName','merge','then','../../config/logger','FreshsalesField','pick','index','api','map','query','json','findAll','VIRTUAL','rows','../../components/parsers/qs','includeAll','options','lodash','limit','where','key','stack','attributes','params','end','findOne','catch','sort','Content-Range','nolimit','count'];(function(_0x365e7d,_0x129514){const _0x2cfdd6=function(_0x11c364){while(--_0x11c364){_0x365e7d['push'](_0x365e7d['shift']());}};_0x2cfdd6(++_0x129514);}(a277_0x1295,0x71));const a277_0x2cfd=function(_0x365e7d,_0x129514){_0x365e7d=_0x365e7d-0x0;let _0x2cfdd6=a277_0x1295[_0x365e7d];return _0x2cfdd6;};const _0x10e87=a277_0x2cfd;'use strict';const _=require(_0x10e87('0x20')),qs=require(_0x10e87('0x1d')),logger=require(_0x10e87('0x12'))(_0x10e87('0x16')),db=require(_0x10e87('0xd'))['db'],{Op}=require(_0x10e87('0x3'));function respondWithResult(_0x11c364,_0x3dd36c){return _0x3dd36c=_0x3dd36c||0xc8,function(_0x3a74e3){if(_0x3a74e3)return _0x11c364['status'](_0x3dd36c)['json'](_0x3a74e3);};}function respondWithFilteredResult(_0x44f253,_0x2b1401){return function(_0x581f45){const _0x5f5aa9=a277_0x2cfd;if(_0x581f45){const _0x112e18=_0x581f45[_0x5f5aa9('0x2d')],_0x467449=_0x2b1401[_0x5f5aa9('0x5')];let _0x10aa57=_0x2b1401[_0x5f5aa9('0x5')]+_0x2b1401[_0x5f5aa9('0x21')],_0x2d56c8;return _0x10aa57>=_0x112e18?(_0x10aa57=_0x112e18,_0x2d56c8=0xc8):_0x2d56c8=0xce,_0x44f253['status'](_0x2d56c8),_0x44f253[_0x5f5aa9('0x2e')](_0x5f5aa9('0x2b'),_0x467449+'-'+_0x10aa57+'/'+_0x112e18)[_0x5f5aa9('0x19')](_0x581f45);}return null;};}function saveUpdates(_0x61c8bd){return function(_0x8684c5){const _0x11696a=a277_0x2cfd;if(_0x8684c5)return _0x8684c5[_0x11696a('0x4')](_0x61c8bd)[_0x11696a('0x11')](function(_0xd7beb1){return _0xd7beb1;});return null;};}function removeEntity(_0x28ff46){return function(_0x49331a){const _0x47592f=a277_0x2cfd;if(_0x49331a)return _0x49331a[_0x47592f('0x2f')]()['then'](function(){const _0x4b0566=_0x47592f;_0x28ff46['status'](0xcc)[_0x4b0566('0x27')]();});};}function handleEntityNotFound(_0x27cd94){return function(_0x57e156){const _0x40960b=a277_0x2cfd;return!_0x57e156&&_0x27cd94[_0x40960b('0x30')](0x194),_0x57e156;};}function handleError(_0x501e5e,_0x2a81ae){return _0x2a81ae=_0x2a81ae||0x1f4,function(_0x125a55){const _0x39236d=a277_0x2cfd;logger['error'](_0x125a55[_0x39236d('0x24')]),_0x125a55[_0x39236d('0x1')]&&delete _0x125a55[_0x39236d('0x1')],_0x501e5e[_0x39236d('0xb')](_0x2a81ae)[_0x39236d('0x32')](_0x125a55);};}exports[_0x10e87('0x15')]=function(_0x3214b0,_0x185f07){const _0x4d70a1=_0x10e87;let _0x4e4bc1={};const _0xb03097={},_0x155f53={'count':0x0,'rows':[]},_0xe0a745=_[_0x4d70a1('0x17')](db['FreshsalesField'][_0x4d70a1('0x31')],function(_0x2ce85d){const _0x5e7818=_0x4d70a1;return{'name':_0x2ce85d[_0x5e7818('0xf')],'type':_0x2ce85d[_0x5e7818('0x33')][_0x5e7818('0x23')]};});_0xb03097['model']=_[_0x4d70a1('0x17')](_0xe0a745,_0x4d70a1('0x1')),_0xb03097[_0x4d70a1('0x18')]=_[_0x4d70a1('0x6')](_0x3214b0[_0x4d70a1('0x18')]),_0xb03097[_0x4d70a1('0xa')]=_[_0x4d70a1('0x34')](_0xb03097[_0x4d70a1('0xe')],_0xb03097[_0x4d70a1('0x18')]),_0x4e4bc1['attributes']=_[_0x4d70a1('0x34')](_0xb03097[_0x4d70a1('0xe')],qs[_0x4d70a1('0xc')](_0x3214b0[_0x4d70a1('0x18')]['fields'])),_0x4e4bc1[_0x4d70a1('0x25')]=_0x4e4bc1[_0x4d70a1('0x25')]['length']?_0x4e4bc1[_0x4d70a1('0x25')]:_0xb03097[_0x4d70a1('0xe')];typeof _0x3214b0['query'][_0x4d70a1('0x2c')]==='undefined'&&(_0x4e4bc1[_0x4d70a1('0x21')]=qs[_0x4d70a1('0x21')](_0x3214b0[_0x4d70a1('0x18')][_0x4d70a1('0x21')]),_0x4e4bc1[_0x4d70a1('0x5')]=qs['offset'](_0x3214b0['query']['offset']));_0x4e4bc1['order']=qs[_0x4d70a1('0x2a')](_0x3214b0['query'][_0x4d70a1('0x2a')]),_0x4e4bc1[_0x4d70a1('0x22')]=qs[_0x4d70a1('0xa')](_[_0x4d70a1('0x14')](_0x3214b0[_0x4d70a1('0x18')],_0xb03097[_0x4d70a1('0xa')]),_0xe0a745);_0x3214b0['query'][_0x4d70a1('0x0')]&&(_0x4e4bc1[_0x4d70a1('0x22')]=_[_0x4d70a1('0x10')](_0x4e4bc1[_0x4d70a1('0x22')],{[Op['or']]:_[_0x4d70a1('0x17')](_0xe0a745,function(_0x5e0cb4){const _0x225b66=_0x4d70a1;if(_0x5e0cb4[_0x225b66('0x33')]!==_0x225b66('0x1b')){const _0x5cec74={};return _0x5cec74[_0x5e0cb4[_0x225b66('0x1')]]={[Op[_0x225b66('0x7')]]:'%'+_0x3214b0[_0x225b66('0x18')][_0x225b66('0x0')]+'%'},_0x5cec74;}})}));_0x4e4bc1=_[_0x4d70a1('0x10')]({},_0x4e4bc1,_0x3214b0['options']);const _0x527910={'where':_0x4e4bc1[_0x4d70a1('0x22')]};return db['FreshsalesField']['count'](_0x527910)[_0x4d70a1('0x11')](function(_0x1d8d03){const _0x39092f=_0x4d70a1;return _0x155f53['count']=_0x1d8d03,_0x3214b0[_0x39092f('0x18')][_0x39092f('0x1e')]&&(_0x4e4bc1[_0x39092f('0x8')]=[{'all':!![]}]),db[_0x39092f('0x13')][_0x39092f('0x1a')](_0x4e4bc1);})[_0x4d70a1('0x11')](function(_0x190f39){const _0x4c1140=_0x4d70a1;return _0x155f53[_0x4c1140('0x1c')]=_0x190f39,_0x155f53;})['then'](respondWithFilteredResult(_0x185f07,_0x4e4bc1))['catch'](handleError(_0x185f07,null));},exports['show']=function(_0x33d158,_0x4d6c13){const _0x3a5805=_0x10e87;let _0x3ec09b={'raw':!![],'where':{'id':_0x33d158[_0x3a5805('0x26')]['id']}};const _0x4a3d9b={};return _0x4a3d9b[_0x3a5805('0xe')]=_[_0x3a5805('0x6')](db[_0x3a5805('0x13')][_0x3a5805('0x31')]),_0x4a3d9b[_0x3a5805('0x18')]=_[_0x3a5805('0x6')](_0x33d158[_0x3a5805('0x18')]),_0x4a3d9b['filters']=_[_0x3a5805('0x34')](_0x4a3d9b['model'],_0x4a3d9b[_0x3a5805('0x18')]),_0x3ec09b[_0x3a5805('0x25')]=_['intersection'](_0x4a3d9b[_0x3a5805('0xe')],qs[_0x3a5805('0xc')](_0x33d158[_0x3a5805('0x18')][_0x3a5805('0xc')])),_0x3ec09b[_0x3a5805('0x25')]=_0x3ec09b[_0x3a5805('0x25')]['length']?_0x3ec09b[_0x3a5805('0x25')]:_0x4a3d9b['model'],_0x33d158['query'][_0x3a5805('0x1e')]&&(_0x3ec09b[_0x3a5805('0x8')]=[{'all':!![]}]),_0x3ec09b=_[_0x3a5805('0x10')]({},_0x3ec09b,_0x33d158[_0x3a5805('0x1f')]),db[_0x3a5805('0x13')]['findOne'](_0x3ec09b)[_0x3a5805('0x11')](handleEntityNotFound(_0x4d6c13,null))[_0x3a5805('0x11')](respondWithResult(_0x4d6c13,null))[_0x3a5805('0x29')](handleError(_0x4d6c13,null));},exports[_0x10e87('0x9')]=function(_0x311c8b,_0x4b04ad){const _0x1c5c0c=_0x10e87;return db[_0x1c5c0c('0x13')][_0x1c5c0c('0x9')](_0x311c8b[_0x1c5c0c('0x2')],{})[_0x1c5c0c('0x11')](respondWithResult(_0x4b04ad,0xc9))[_0x1c5c0c('0x29')](handleError(_0x4b04ad,null));},exports[_0x10e87('0x4')]=function(_0x10a609,_0x21271d){const _0x44cbd4=_0x10e87;return _0x10a609[_0x44cbd4('0x2')]['id']&&delete _0x10a609[_0x44cbd4('0x2')]['id'],db[_0x44cbd4('0x13')][_0x44cbd4('0x28')]({'where':{'id':_0x10a609['params']['id']}})[_0x44cbd4('0x11')](handleEntityNotFound(_0x21271d,null))[_0x44cbd4('0x11')](saveUpdates(_0x10a609[_0x44cbd4('0x2')],null))[_0x44cbd4('0x11')](respondWithResult(_0x21271d,null))[_0x44cbd4('0x29')](handleError(_0x21271d,null));},exports['destroy']=function(_0x246354,_0x1d5350){const _0x4577e1=_0x10e87;return db[_0x4577e1('0x13')][_0x4577e1('0x28')]({'where':{'id':_0x246354['params']['id']}})[_0x4577e1('0x11')](handleEntityNotFound(_0x1d5350,null))['then'](removeEntity(_0x1d5350,null))[_0x4577e1('0x29')](handleError(_0x1d5350,null));}; \ No newline at end of file +const a277_0x32ef=['count','body','map','rawAttributes','key','query','json','intersection','length','filters','catch','offset','attributes','api','sequelize','undefined','send','destroy','filter','model','findOne','merge','name','fields','include','like','FreshsalesField','includeAll','create','../../mysqldb','lodash','index','show','error','../../components/parsers/qs','order','nolimit','keys','../../config/logger','where','type','limit','sendStatus','then','fieldName','end','update','params','status','pick'];(function(_0x2e69c1,_0x32ef9c){const _0x43b290=function(_0x4550dc){while(--_0x4550dc){_0x2e69c1['push'](_0x2e69c1['shift']());}};_0x43b290(++_0x32ef9c);}(a277_0x32ef,0x18a));const a277_0x43b2=function(_0x2e69c1,_0x32ef9c){_0x2e69c1=_0x2e69c1-0x0;let _0x43b290=a277_0x32ef[_0x2e69c1];return _0x43b290;};const _0x5615dc=a277_0x43b2;'use strict';const _=require(_0x5615dc('0x24')),qs=require(_0x5615dc('0x28')),logger=require(_0x5615dc('0x2c'))(_0x5615dc('0x13')),db=require(_0x5615dc('0x23'))['db'],{Op}=require(_0x5615dc('0x14'));function respondWithResult(_0x4550dc,_0x342f0e){return _0x342f0e=_0x342f0e||0xc8,function(_0x402b08){const _0x23b079=a277_0x43b2;if(_0x402b08)return _0x4550dc[_0x23b079('0x4')](_0x342f0e)[_0x23b079('0xc')](_0x402b08);};}function respondWithFilteredResult(_0x4aef07,_0xc135b8){return function(_0x518650){const _0x57e733=a277_0x43b2;if(_0x518650){const _0x414abe=_0x518650[_0x57e733('0x6')],_0x27c1f5=_0xc135b8[_0x57e733('0x11')];let _0x29c9af=_0xc135b8[_0x57e733('0x11')]+_0xc135b8[_0x57e733('0x2f')],_0xfa0e0f;return _0x29c9af>=_0x414abe?(_0x29c9af=_0x414abe,_0xfa0e0f=0xc8):_0xfa0e0f=0xce,_0x4aef07['status'](_0xfa0e0f),_0x4aef07['set']('Content-Range',_0x27c1f5+'-'+_0x29c9af+'/'+_0x414abe)[_0x57e733('0xc')](_0x518650);}return null;};}function saveUpdates(_0x320df9){return function(_0x47e148){const _0x13b699=a277_0x43b2;if(_0x47e148)return _0x47e148[_0x13b699('0x2')](_0x320df9)['then'](function(_0xe194d9){return _0xe194d9;});return null;};}function removeEntity(_0x479474){return function(_0x58cca4){const _0x45e3af=a277_0x43b2;if(_0x58cca4)return _0x58cca4[_0x45e3af('0x17')]()[_0x45e3af('0x31')](function(){const _0x1f7111=_0x45e3af;_0x479474[_0x1f7111('0x4')](0xcc)[_0x1f7111('0x1')]();});};}function handleEntityNotFound(_0x570f59){return function(_0x454879){const _0x5c5401=a277_0x43b2;return!_0x454879&&_0x570f59[_0x5c5401('0x30')](0x194),_0x454879;};}function handleError(_0x4247ff,_0x11c2cf){return _0x11c2cf=_0x11c2cf||0x1f4,function(_0x13b0c1){const _0x183fcc=a277_0x43b2;logger[_0x183fcc('0x27')](_0x13b0c1['stack']),_0x13b0c1[_0x183fcc('0x1c')]&&delete _0x13b0c1[_0x183fcc('0x1c')],_0x4247ff['status'](_0x11c2cf)[_0x183fcc('0x16')](_0x13b0c1);};}exports[_0x5615dc('0x25')]=function(_0x425c0d,_0x48b66a){const _0x301328=_0x5615dc;let _0x313bc7={};const _0x2396a5={},_0x24c391={'count':0x0,'rows':[]},_0xaccc2a=_['map'](db[_0x301328('0x20')][_0x301328('0x9')],function(_0x3ffbeb){const _0x5a7d15=_0x301328;return{'name':_0x3ffbeb[_0x5a7d15('0x0')],'type':_0x3ffbeb[_0x5a7d15('0x2e')][_0x5a7d15('0xa')]};});_0x2396a5[_0x301328('0x19')]=_['map'](_0xaccc2a,_0x301328('0x1c')),_0x2396a5['query']=_['keys'](_0x425c0d['query']),_0x2396a5[_0x301328('0xf')]=_[_0x301328('0xd')](_0x2396a5[_0x301328('0x19')],_0x2396a5[_0x301328('0xb')]),_0x313bc7[_0x301328('0x12')]=_[_0x301328('0xd')](_0x2396a5[_0x301328('0x19')],qs[_0x301328('0x1d')](_0x425c0d[_0x301328('0xb')]['fields'])),_0x313bc7[_0x301328('0x12')]=_0x313bc7[_0x301328('0x12')]['length']?_0x313bc7['attributes']:_0x2396a5[_0x301328('0x19')];typeof _0x425c0d['query'][_0x301328('0x2a')]===_0x301328('0x15')&&(_0x313bc7[_0x301328('0x2f')]=qs['limit'](_0x425c0d[_0x301328('0xb')][_0x301328('0x2f')]),_0x313bc7['offset']=qs[_0x301328('0x11')](_0x425c0d['query'][_0x301328('0x11')]));_0x313bc7[_0x301328('0x29')]=qs['sort'](_0x425c0d[_0x301328('0xb')]['sort']),_0x313bc7[_0x301328('0x2d')]=qs[_0x301328('0xf')](_[_0x301328('0x5')](_0x425c0d[_0x301328('0xb')],_0x2396a5[_0x301328('0xf')]),_0xaccc2a);_0x425c0d[_0x301328('0xb')]['filter']&&(_0x313bc7['where']=_[_0x301328('0x1b')](_0x313bc7[_0x301328('0x2d')],{[Op['or']]:_[_0x301328('0x8')](_0xaccc2a,function(_0x289211){const _0x5a3c69=_0x301328;if(_0x289211[_0x5a3c69('0x2e')]!=='VIRTUAL'){const _0x5851e4={};return _0x5851e4[_0x289211[_0x5a3c69('0x1c')]]={[Op[_0x5a3c69('0x1f')]]:'%'+_0x425c0d['query'][_0x5a3c69('0x18')]+'%'},_0x5851e4;}})}));_0x313bc7=_['merge']({},_0x313bc7,_0x425c0d['options']);const _0x403bcc={'where':_0x313bc7['where']};return db[_0x301328('0x20')][_0x301328('0x6')](_0x403bcc)[_0x301328('0x31')](function(_0x3c9dd5){const _0x230055=_0x301328;return _0x24c391[_0x230055('0x6')]=_0x3c9dd5,_0x425c0d['query'][_0x230055('0x21')]&&(_0x313bc7[_0x230055('0x1e')]=[{'all':!![]}]),db[_0x230055('0x20')]['findAll'](_0x313bc7);})[_0x301328('0x31')](function(_0x5e76eb){return _0x24c391['rows']=_0x5e76eb,_0x24c391;})['then'](respondWithFilteredResult(_0x48b66a,_0x313bc7))[_0x301328('0x10')](handleError(_0x48b66a,null));},exports[_0x5615dc('0x26')]=function(_0x10d0f1,_0x510c96){const _0x2b65bd=_0x5615dc;let _0x1db6e5={'raw':!![],'where':{'id':_0x10d0f1[_0x2b65bd('0x3')]['id']}};const _0x525337={};return _0x525337[_0x2b65bd('0x19')]=_[_0x2b65bd('0x2b')](db['FreshsalesField']['rawAttributes']),_0x525337[_0x2b65bd('0xb')]=_['keys'](_0x10d0f1[_0x2b65bd('0xb')]),_0x525337['filters']=_[_0x2b65bd('0xd')](_0x525337[_0x2b65bd('0x19')],_0x525337[_0x2b65bd('0xb')]),_0x1db6e5[_0x2b65bd('0x12')]=_['intersection'](_0x525337[_0x2b65bd('0x19')],qs[_0x2b65bd('0x1d')](_0x10d0f1[_0x2b65bd('0xb')][_0x2b65bd('0x1d')])),_0x1db6e5['attributes']=_0x1db6e5['attributes'][_0x2b65bd('0xe')]?_0x1db6e5[_0x2b65bd('0x12')]:_0x525337['model'],_0x10d0f1['query']['includeAll']&&(_0x1db6e5[_0x2b65bd('0x1e')]=[{'all':!![]}]),_0x1db6e5=_[_0x2b65bd('0x1b')]({},_0x1db6e5,_0x10d0f1['options']),db[_0x2b65bd('0x20')][_0x2b65bd('0x1a')](_0x1db6e5)[_0x2b65bd('0x31')](handleEntityNotFound(_0x510c96,null))[_0x2b65bd('0x31')](respondWithResult(_0x510c96,null))['catch'](handleError(_0x510c96,null));},exports['create']=function(_0x5f0327,_0x5ab39d){const _0x2a35bd=_0x5615dc;return db[_0x2a35bd('0x20')][_0x2a35bd('0x22')](_0x5f0327[_0x2a35bd('0x7')],{})[_0x2a35bd('0x31')](respondWithResult(_0x5ab39d,0xc9))[_0x2a35bd('0x10')](handleError(_0x5ab39d,null));},exports[_0x5615dc('0x2')]=function(_0xe5cece,_0x56103c){const _0x5b8ba7=_0x5615dc;return _0xe5cece[_0x5b8ba7('0x7')]['id']&&delete _0xe5cece[_0x5b8ba7('0x7')]['id'],db['FreshsalesField'][_0x5b8ba7('0x1a')]({'where':{'id':_0xe5cece[_0x5b8ba7('0x3')]['id']}})['then'](handleEntityNotFound(_0x56103c,null))['then'](saveUpdates(_0xe5cece[_0x5b8ba7('0x7')],null))[_0x5b8ba7('0x31')](respondWithResult(_0x56103c,null))[_0x5b8ba7('0x10')](handleError(_0x56103c,null));},exports['destroy']=function(_0x1e5ff0,_0x34d33e){const _0x18e795=_0x5615dc;return db[_0x18e795('0x20')][_0x18e795('0x1a')]({'where':{'id':_0x1e5ff0['params']['id']}})[_0x18e795('0x31')](handleEntityNotFound(_0x34d33e,null))[_0x18e795('0x31')](removeEntity(_0x34d33e,null))[_0x18e795('0x10')](handleError(_0x34d33e,null));}; \ No newline at end of file diff --git a/server/api/intFreshsalesField/intFreshsalesField.model.js b/server/api/intFreshsalesField/intFreshsalesField.model.js index 4bdfb16..5ba36c1 100644 --- a/server/api/intFreshsalesField/intFreshsalesField.model.js +++ b/server/api/intFreshsalesField/intFreshsalesField.model.js @@ -1 +1 @@ -const a278_0x5e3a=['FreshsalesField','./intFreshsalesField.attributes','define','exports','idField','FieldId','freshsales_unique_index','int_freshsales_fields'];(function(_0x432c6a,_0x5e3a69){const _0x385a36=function(_0x27aee7){while(--_0x27aee7){_0x432c6a['push'](_0x432c6a['shift']());}};_0x385a36(++_0x5e3a69);}(a278_0x5e3a,0x1da));const a278_0x385a=function(_0x432c6a,_0x5e3a69){_0x432c6a=_0x432c6a-0x0;let _0x385a36=a278_0x5e3a[_0x432c6a];return _0x385a36;};const _0x5db7bb=a278_0x385a;'use strict';const attributes=require(_0x5db7bb('0x7'));module[_0x5db7bb('0x1')]=function(_0x27aee7){const _0x427667=_0x5db7bb,_0x497362=_0x27aee7[_0x427667('0x0')](_0x427667('0x6'),attributes,{'tableName':_0x427667('0x5'),'paranoid':![],'indexes':[{'name':_0x427667('0x4'),'fields':[_0x427667('0x2'),_0x427667('0x3')],'unique':!![]}],'timestamps':!![]});return _0x497362;}; \ No newline at end of file +const a278_0x16fb=['int_freshsales_fields','idField','FieldId','./intFreshsalesField.attributes'];(function(_0x252720,_0x16fb80){const _0x4a68d5=function(_0xd3530){while(--_0xd3530){_0x252720['push'](_0x252720['shift']());}};_0x4a68d5(++_0x16fb80);}(a278_0x16fb,0x12a));const a278_0x4a68=function(_0x252720,_0x16fb80){_0x252720=_0x252720-0x0;let _0x4a68d5=a278_0x16fb[_0x252720];return _0x4a68d5;};const _0x7f5958=a278_0x4a68;'use strict';const attributes=require(_0x7f5958('0x1'));module['exports']=function(_0xd3530){const _0x3b47c8=_0x7f5958,_0x12225a=_0xd3530['define']('FreshsalesField',attributes,{'tableName':_0x3b47c8('0x2'),'paranoid':![],'indexes':[{'name':'freshsales_unique_index','fields':[_0x3b47c8('0x3'),_0x3b47c8('0x0')],'unique':!![]}],'timestamps':!![]});return _0x12225a;}; \ No newline at end of file diff --git a/server/api/intSalesforceAccount/index.js b/server/api/intSalesforceAccount/index.js index 0815c59..6fb4160 100644 --- a/server/api/intSalesforceAccount/index.js +++ b/server/api/intSalesforceAccount/index.js @@ -1 +1 @@ -const a279_0x3b70=['/:id/fields','getFields','get','exports','index','./intSalesforceAccount.controller','isAuthenticated','../../components/auth/service','destroy','put','/:id','Router','/:id/configurations','post','addConfiguration','show'];(function(_0x21926d,_0x3b7009){const _0x3b5a68=function(_0x51d4c4){while(--_0x51d4c4){_0x21926d['push'](_0x21926d['shift']());}};_0x3b5a68(++_0x3b7009);}(a279_0x3b70,0xb2));const a279_0x3b5a=function(_0x21926d,_0x3b7009){_0x21926d=_0x21926d-0x0;let _0x3b5a68=a279_0x3b70[_0x21926d];return _0x3b5a68;};const _0xed842f=a279_0x3b5a;'use strict';const express=require('express'),router=express[_0xed842f('0x9')](),auth=require(_0xed842f('0x5')),controller=require(_0xed842f('0x3'));router['get']('/',auth[_0xed842f('0x4')](),controller[_0xed842f('0x2')]),router[_0xed842f('0x0')]('/:id',auth[_0xed842f('0x4')](),controller[_0xed842f('0xd')]),router[_0xed842f('0x0')](_0xed842f('0xa'),auth[_0xed842f('0x4')](),controller['getConfigurations']),router[_0xed842f('0x0')](_0xed842f('0xe'),auth['isAuthenticated'](),controller[_0xed842f('0xf')]),router['post']('/',auth[_0xed842f('0x4')](),controller['create']),router[_0xed842f('0xb')](_0xed842f('0xa'),auth['isAuthenticated'](),controller[_0xed842f('0xc')]),router[_0xed842f('0x7')](_0xed842f('0x8'),auth['isAuthenticated'](),controller['update']),router['delete'](_0xed842f('0x8'),auth[_0xed842f('0x4')](),controller[_0xed842f('0x6')]),module[_0xed842f('0x1')]=router; \ No newline at end of file +const a279_0x3494=['index','getFields','post','show','getConfigurations','/:id/fields','isAuthenticated','/:id','destroy','express','./intSalesforceAccount.controller','exports','/:id/configurations','update','Router','put','addConfiguration','get','../../components/auth/service','delete','create'];(function(_0x528c79,_0x349445){const _0xefaa2f=function(_0x13dd99){while(--_0x13dd99){_0x528c79['push'](_0x528c79['shift']());}};_0xefaa2f(++_0x349445);}(a279_0x3494,0xe9));const a279_0xefaa=function(_0x528c79,_0x349445){_0x528c79=_0x528c79-0x0;let _0xefaa2f=a279_0x3494[_0x528c79];return _0xefaa2f;};const _0x17bf6f=a279_0xefaa;'use strict';const express=require(_0x17bf6f('0x7')),router=express[_0x17bf6f('0xc')](),auth=require(_0x17bf6f('0x10')),controller=require(_0x17bf6f('0x8'));router['get']('/',auth[_0x17bf6f('0x4')](),controller[_0x17bf6f('0x13')]),router[_0x17bf6f('0xf')](_0x17bf6f('0x5'),auth[_0x17bf6f('0x4')](),controller[_0x17bf6f('0x1')]),router[_0x17bf6f('0xf')](_0x17bf6f('0xa'),auth[_0x17bf6f('0x4')](),controller[_0x17bf6f('0x2')]),router[_0x17bf6f('0xf')](_0x17bf6f('0x3'),auth['isAuthenticated'](),controller[_0x17bf6f('0x14')]),router['post']('/',auth['isAuthenticated'](),controller[_0x17bf6f('0x12')]),router[_0x17bf6f('0x0')](_0x17bf6f('0xa'),auth['isAuthenticated'](),controller[_0x17bf6f('0xe')]),router[_0x17bf6f('0xd')](_0x17bf6f('0x5'),auth[_0x17bf6f('0x4')](),controller[_0x17bf6f('0xb')]),router[_0x17bf6f('0x11')]('/:id',auth[_0x17bf6f('0x4')](),controller[_0x17bf6f('0x6')]),module[_0x17bf6f('0x9')]=router; \ No newline at end of file diff --git a/server/api/intSalesforceAccount/intSalesforceAccount.attributes.js b/server/api/intSalesforceAccount/intSalesforceAccount.attributes.js index 2f2535d..5ebcb94 100644 --- a/server/api/intSalesforceAccount/intSalesforceAccount.attributes.js +++ b/server/api/intSalesforceAccount/intSalesforceAccount.attributes.js @@ -1 +1 @@ -const a280_0x1579=['exports','ENUM','newTab','STRING','username','integrationTab'];(function(_0x1acd17,_0x1579f0){const _0x1600ba=function(_0x5f55ba){while(--_0x5f55ba){_0x1acd17['push'](_0x1acd17['shift']());}};_0x1600ba(++_0x1579f0);}(a280_0x1579,0xa1));const a280_0x1600=function(_0x1acd17,_0x1579f0){_0x1acd17=_0x1acd17-0x0;let _0x1600ba=a280_0x1579[_0x1acd17];return _0x1600ba;};const _0x29cee8=a280_0x1600;'use strict';const Sequelize=require('sequelize');module[_0x29cee8('0x1')]={'name':{'type':Sequelize[_0x29cee8('0x4')]},'description':{'type':Sequelize[_0x29cee8('0x4')]},'username':{'type':Sequelize[_0x29cee8('0x4')],'unique':_0x29cee8('0x5')},'remoteUri':{'type':Sequelize['STRING']},'password':{'type':Sequelize[_0x29cee8('0x4')]},'clientId':{'type':Sequelize[_0x29cee8('0x4')]},'clientSecret':{'type':Sequelize[_0x29cee8('0x4')]},'securityToken':{'type':Sequelize[_0x29cee8('0x4')]},'serverUrl':{'type':Sequelize[_0x29cee8('0x4')]},'type':{'type':Sequelize[_0x29cee8('0x2')](_0x29cee8('0x0'),_0x29cee8('0x3')),'defaultValue':_0x29cee8('0x0')}}; \ No newline at end of file +const a280_0x2bdf=['exports','integrationTab','username','newTab','STRING','sequelize'];(function(_0x363ac0,_0x2bdfbd){const _0x57c57b=function(_0x2a9e4a){while(--_0x2a9e4a){_0x363ac0['push'](_0x363ac0['shift']());}};_0x57c57b(++_0x2bdfbd);}(a280_0x2bdf,0x1b7));const a280_0x57c5=function(_0x363ac0,_0x2bdfbd){_0x363ac0=_0x363ac0-0x0;let _0x57c57b=a280_0x2bdf[_0x363ac0];return _0x57c57b;};const _0x182b47=a280_0x57c5;'use strict';const Sequelize=require(_0x182b47('0x4'));module[_0x182b47('0x5')]={'name':{'type':Sequelize[_0x182b47('0x3')]},'description':{'type':Sequelize['STRING']},'username':{'type':Sequelize[_0x182b47('0x3')],'unique':_0x182b47('0x1')},'remoteUri':{'type':Sequelize[_0x182b47('0x3')]},'password':{'type':Sequelize['STRING']},'clientId':{'type':Sequelize[_0x182b47('0x3')]},'clientSecret':{'type':Sequelize[_0x182b47('0x3')]},'securityToken':{'type':Sequelize[_0x182b47('0x3')]},'serverUrl':{'type':Sequelize['STRING']},'type':{'type':Sequelize['ENUM'](_0x182b47('0x0'),_0x182b47('0x2')),'defaultValue':_0x182b47('0x0')}}; \ No newline at end of file diff --git a/server/api/intSalesforceAccount/intSalesforceAccount.controller.js b/server/api/intSalesforceAccount/intSalesforceAccount.controller.js index e3c6215..555c72b 100644 --- a/server/api/intSalesforceAccount/intSalesforceAccount.controller.js +++ b/server/api/intSalesforceAccount/intSalesforceAccount.controller.js @@ -1 +1 @@ -const a281_0x291e=['key','Priority','IsEscalated','Descriptions','CallDurationInSeconds','lastIndexOf','map','slice','name','remoteUri','describe','model','like','SalesforceField','include','label','Origin','set','fields','findOne','SuppliedCompany','CallType','pick','false','getFields','catch','create','then','value','True','ticketType','jsforce','../../config/logger','SalesforceAccount','channel','order','sendStatus','status','VIRTUAL','merge','test','true','SuppliedName','getSubjects','../../mysqldb','undefined','login','limit','json','query','index','substring','rows','filter','Content-Range','getConfigurations','../../components/integrations/configuration','filters','statusCode','concat','isNil','SalesforceConfiguration','attributes','IsArchived','getDescriptions','params','clientSecret','Type','offset','Reason','length','securityToken','stack','sobject','nolimit','options','False','body','where','addConfiguration','Subjects','type','findAll','CallObject','Case','fieldName','intersection','count','send','error','Status','end','includeAll','clientId','sort','picklistValues','remove','stringify','password','keys','username','Task','getFields,\x20%s,\x20%s,\x20%s','destroy','rawAttributes','custom'];(function(_0x24dafd,_0x291efc){const _0x2f8b0a=function(_0x4ddc50){while(--_0x4ddc50){_0x24dafd['push'](_0x24dafd['shift']());}};_0x2f8b0a(++_0x291efc);}(a281_0x291e,0x19a));const a281_0x2f8b=function(_0x24dafd,_0x291efc){_0x24dafd=_0x24dafd-0x0;let _0x2f8b0a=a281_0x291e[_0x24dafd];return _0x2f8b0a;};const _0xf564f3=a281_0x2f8b;'use strict';const _=require('lodash'),jsforce=require(_0xf564f3('0x2d')),qs=require('../../components/parsers/qs'),logger=require(_0xf564f3('0x2e'))('api'),db=require(_0xf564f3('0x3a'))['db'],{Op}=require('sequelize'),integrations=require(_0xf564f3('0x46'));function respondWithResult(_0x4ddc50,_0x2cad42){return _0x2cad42=_0x2cad42||0xc8,function(_0x2fe0c1){const _0x54bb84=a281_0x2f8b;if(_0x2fe0c1)return _0x4ddc50['status'](_0x2cad42)[_0x54bb84('0x3e')](_0x2fe0c1);};}function respondWithFilteredResult(_0x14c734,_0x11c6a2){return function(_0x57ac58){const _0x290b8a=a281_0x2f8b;if(_0x57ac58){const _0x5d2ca1=_0x57ac58[_0x290b8a('0x65')],_0xb217e4=_0x11c6a2[_0x290b8a('0x52')];let _0x2ad283=_0x11c6a2[_0x290b8a('0x52')]+_0x11c6a2['limit'],_0xc1a788;return _0x2ad283>=_0x5d2ca1?(_0x2ad283=_0x5d2ca1,_0xc1a788=0xc8):_0xc1a788=0xce,_0x14c734['status'](_0xc1a788),_0x14c734[_0x290b8a('0x1f')](_0x290b8a('0x44'),_0xb217e4+'-'+_0x2ad283+'/'+_0x5d2ca1)['json'](_0x57ac58);}return null;};}function saveUpdates(_0x48b958){return function(_0x36569f){const _0x444822=a281_0x2f8b;if(_0x36569f)return _0x36569f['update'](_0x48b958)[_0x444822('0x29')](function(_0x35555f){return _0x35555f;});return null;};}function removeEntity(_0x302197){return function(_0x352fcc){if(_0x352fcc)return _0x352fcc['destroy']()['then'](function(){const _0x5bb6d8=a281_0x2f8b;_0x302197[_0x5bb6d8('0x33')](0xcc)[_0x5bb6d8('0x69')]();});};}function handleEntityNotFound(_0x3c3f35){return function(_0x101f47){const _0x2d688a=a281_0x2f8b;return!_0x101f47&&_0x3c3f35[_0x2d688a('0x32')](0x194),_0x101f47;};}function handleError(_0x15ba95,_0x572672){return _0x572672=_0x572672||0x1f4,function(_0x4ed990){const _0x39f705=a281_0x2f8b;logger['error'](_0x4ed990[_0x39f705('0x56')]),_0x4ed990[_0x39f705('0x16')]&&delete _0x4ed990[_0x39f705('0x16')],_0x15ba95[_0x39f705('0x33')](_0x572672)[_0x39f705('0x66')](_0x4ed990);};}exports[_0xf564f3('0x40')]=function(_0x3c815a,_0x3334e1){const _0x2114b8=_0xf564f3;let _0x45909a={};const _0x4c74c2={},_0x4254e5={'count':0x0,'rows':[]},_0x1cbb09=_[_0x2114b8('0x14')](db[_0x2114b8('0x2f')][_0x2114b8('0xc')],function(_0x16247b){const _0x1d3350=_0x2114b8;return{'name':_0x16247b[_0x1d3350('0x63')],'type':_0x16247b[_0x1d3350('0x5f')][_0x1d3350('0xe')]};});_0x4c74c2[_0x2114b8('0x19')]=_[_0x2114b8('0x14')](_0x1cbb09,_0x2114b8('0x16')),_0x4c74c2['query']=_[_0x2114b8('0x7')](_0x3c815a[_0x2114b8('0x3f')]),_0x4c74c2[_0x2114b8('0x47')]=_[_0x2114b8('0x64')](_0x4c74c2['model'],_0x4c74c2['query']),_0x45909a[_0x2114b8('0x4c')]=_['intersection'](_0x4c74c2[_0x2114b8('0x19')],qs['fields'](_0x3c815a[_0x2114b8('0x3f')]['fields'])),_0x45909a['attributes']=_0x45909a[_0x2114b8('0x4c')]['length']?_0x45909a[_0x2114b8('0x4c')]:_0x4c74c2[_0x2114b8('0x19')];typeof _0x3c815a[_0x2114b8('0x3f')][_0x2114b8('0x58')]===_0x2114b8('0x3b')&&(_0x45909a['limit']=qs['limit'](_0x3c815a[_0x2114b8('0x3f')][_0x2114b8('0x3d')]),_0x45909a['offset']=qs[_0x2114b8('0x52')](_0x3c815a[_0x2114b8('0x3f')]['offset']));_0x45909a['order']=qs[_0x2114b8('0x2')](_0x3c815a['query'][_0x2114b8('0x2')]),_0x45909a['where']=qs['filters'](_[_0x2114b8('0x24')](_0x3c815a[_0x2114b8('0x3f')],_0x4c74c2[_0x2114b8('0x47')]),_0x1cbb09);_0x3c815a[_0x2114b8('0x3f')][_0x2114b8('0x43')]&&(_0x45909a[_0x2114b8('0x5c')]=_['merge'](_0x45909a['where'],{[Op['or']]:_[_0x2114b8('0x14')](_0x1cbb09,function(_0x115238){const _0x2f3de9=_0x2114b8;if(_0x115238[_0x2f3de9('0x5f')]!==_0x2f3de9('0x34')){const _0x58e892={};return _0x58e892[_0x115238['name']]={[Op[_0x2f3de9('0x1a')]]:'%'+_0x3c815a[_0x2f3de9('0x3f')]['filter']+'%'},_0x58e892;}})}));_0x45909a=_[_0x2114b8('0x35')]({},_0x45909a,_0x3c815a[_0x2114b8('0x59')]);const _0x95d896={'where':_0x45909a[_0x2114b8('0x5c')]};return db[_0x2114b8('0x2f')][_0x2114b8('0x65')](_0x95d896)[_0x2114b8('0x29')](function(_0x3b28c7){const _0x519398=_0x2114b8;return _0x4254e5['count']=_0x3b28c7,_0x3c815a['query']['includeAll']&&(_0x45909a[_0x519398('0x1c')]=[{'all':!![]}]),db['SalesforceAccount'][_0x519398('0x60')](_0x45909a);})[_0x2114b8('0x29')](function(_0x7b1fa3){const _0x37b4e9=_0x2114b8;return _0x4254e5[_0x37b4e9('0x42')]=_0x7b1fa3,_0x4254e5;})[_0x2114b8('0x29')](respondWithFilteredResult(_0x3334e1,_0x45909a))[_0x2114b8('0x27')](handleError(_0x3334e1,null));},exports['show']=function(_0x1caada,_0x4a3404){const _0x5757f0=_0xf564f3;let _0x27ba1a={'raw':![],'where':{'id':_0x1caada[_0x5757f0('0x4f')]['id']}};const _0x33a010={};return _0x33a010[_0x5757f0('0x19')]=_[_0x5757f0('0x7')](db['SalesforceAccount'][_0x5757f0('0xc')]),_0x33a010[_0x5757f0('0x3f')]=_[_0x5757f0('0x7')](_0x1caada[_0x5757f0('0x3f')]),_0x33a010[_0x5757f0('0x47')]=_[_0x5757f0('0x64')](_0x33a010[_0x5757f0('0x19')],_0x33a010[_0x5757f0('0x3f')]),_0x27ba1a[_0x5757f0('0x4c')]=_[_0x5757f0('0x64')](_0x33a010[_0x5757f0('0x19')],qs['fields'](_0x1caada[_0x5757f0('0x3f')][_0x5757f0('0x20')])),_0x27ba1a['attributes']=_0x27ba1a[_0x5757f0('0x4c')][_0x5757f0('0x54')]?_0x27ba1a[_0x5757f0('0x4c')]:_0x33a010[_0x5757f0('0x19')],_0x1caada[_0x5757f0('0x3f')][_0x5757f0('0x0')]&&(_0x27ba1a[_0x5757f0('0x1c')]=[{'all':!![]}]),_0x27ba1a=_['merge']({},_0x27ba1a,_0x1caada[_0x5757f0('0x59')]),db[_0x5757f0('0x2f')][_0x5757f0('0x21')](_0x27ba1a)['then'](handleEntityNotFound(_0x4a3404,null))['then'](respondWithResult(_0x4a3404,null))[_0x5757f0('0x27')](handleError(_0x4a3404,null));},exports['create']=function(_0x138b92,_0x14cf08){const _0x3b25e1=_0xf564f3;return db['SalesforceAccount']['create'](_0x138b92[_0x3b25e1('0x5b')],{})[_0x3b25e1('0x29')](respondWithResult(_0x14cf08,0xc9))['catch'](handleError(_0x14cf08,null));},exports['update']=function(_0x4bc728,_0x4b5ccd){const _0x1fc563=_0xf564f3;return _0x4bc728[_0x1fc563('0x5b')]['id']&&delete _0x4bc728['body']['id'],db['SalesforceAccount']['findOne']({'where':{'id':_0x4bc728[_0x1fc563('0x4f')]['id']}})[_0x1fc563('0x29')](handleEntityNotFound(_0x4b5ccd,null))[_0x1fc563('0x29')](saveUpdates(_0x4bc728[_0x1fc563('0x5b')],null))[_0x1fc563('0x29')](respondWithResult(_0x4b5ccd,null))[_0x1fc563('0x27')](handleError(_0x4b5ccd,null));},exports[_0xf564f3('0xb')]=function(_0x248a48,_0x373435){const _0x133ad4=_0xf564f3;return db['SalesforceAccount'][_0x133ad4('0x21')]({'where':{'id':_0x248a48['params']['id']}})[_0x133ad4('0x29')](handleEntityNotFound(_0x373435,null))[_0x133ad4('0x29')](removeEntity(_0x373435,null))[_0x133ad4('0x27')](handleError(_0x373435,null));},exports[_0xf564f3('0x45')]=function(_0xe8dd99,_0x2b9990){const _0x398256=_0xf564f3;let _0x383fce={};const _0x2fedaf={};let _0x5895de,_0x263747;return db[_0x398256('0x2f')][_0x398256('0x21')]({'where':{'id':_0xe8dd99[_0x398256('0x4f')]['id']}})[_0x398256('0x29')](handleEntityNotFound(_0x2b9990,null))[_0x398256('0x29')](function(_0x1a8958){const _0x5063f7=_0x398256;if(_0x1a8958)return _0x5895de=_0x1a8958,_0x2fedaf['model']=_[_0x5063f7('0x7')](db[_0x5063f7('0x4b')]['rawAttributes']),_0x2fedaf[_0x5063f7('0x3f')]=_[_0x5063f7('0x7')](_0xe8dd99[_0x5063f7('0x3f')]),_0x2fedaf['filters']=_['intersection'](_0x2fedaf[_0x5063f7('0x19')],_0x2fedaf[_0x5063f7('0x3f')]),_0x383fce['attributes']=_[_0x5063f7('0x64')](_0x2fedaf[_0x5063f7('0x19')],qs[_0x5063f7('0x20')](_0xe8dd99[_0x5063f7('0x3f')]['fields'])),_0x383fce[_0x5063f7('0x4c')]=_0x383fce[_0x5063f7('0x4c')]['length']?_0x383fce[_0x5063f7('0x4c')]:_0x2fedaf[_0x5063f7('0x19')],_0x383fce[_0x5063f7('0x31')]=qs[_0x5063f7('0x2')](_0xe8dd99[_0x5063f7('0x3f')][_0x5063f7('0x2')]),_0x383fce[_0x5063f7('0x5c')]=qs[_0x5063f7('0x47')](_[_0x5063f7('0x24')](_0xe8dd99[_0x5063f7('0x3f')],_0x2fedaf[_0x5063f7('0x47')])),_0xe8dd99[_0x5063f7('0x3f')][_0x5063f7('0x43')]&&(_0x383fce[_0x5063f7('0x5c')]=_[_0x5063f7('0x35')](_0x383fce[_0x5063f7('0x5c')],{[Op['or']]:_[_0x5063f7('0x14')](_0x383fce[_0x5063f7('0x4c')],function(_0x160fd1){const _0x269c9c=_0x5063f7,_0x5cb9b3={};return _0x5cb9b3[_0x160fd1]={[Op['like']]:'%'+_0xe8dd99[_0x269c9c('0x3f')]['filter']+'%'},_0x5cb9b3;})})),_0x383fce=_[_0x5063f7('0x35')]({},_0x383fce,_0xe8dd99[_0x5063f7('0x59')]),_0x5895de['getConfigurations'](_0x383fce);})['then'](function(_0x1110d7){const _0x3a9bca=_0x398256;if(_0x1110d7)return _0x263747=_0x1110d7[_0x3a9bca('0x54')],typeof _0xe8dd99['query'][_0x3a9bca('0x58')]===_0x3a9bca('0x3b')&&(_0x383fce[_0x3a9bca('0x3d')]=qs[_0x3a9bca('0x3d')](_0xe8dd99[_0x3a9bca('0x3f')][_0x3a9bca('0x3d')]),_0x383fce[_0x3a9bca('0x52')]=qs['offset'](_0xe8dd99[_0x3a9bca('0x3f')]['offset'])),_0x5895de[_0x3a9bca('0x45')](_0x383fce);})[_0x398256('0x29')](function(_0xe8eb96){if(_0xe8eb96)return _0xe8eb96?{'count':_0x263747,'rows':_0xe8eb96}:null;})[_0x398256('0x29')](respondWithResult(_0x2b9990,null))[_0x398256('0x27')](handleError(_0x2b9990,null));},exports[_0xf564f3('0x5d')]=function(_0x1d4bd6,_0x54be8a){const _0x3f13dd=_0xf564f3;return _0x1d4bd6['body']['id']&&delete _0x1d4bd6[_0x3f13dd('0x5b')]['id'],db['SalesforceAccount'][_0x3f13dd('0x21')]({'where':{'id':_0x1d4bd6[_0x3f13dd('0x4f')]['id']}})[_0x3f13dd('0x29')](handleEntityNotFound(_0x54be8a,null))[_0x3f13dd('0x29')](function(_0x30e3e3){const _0x504071=_0x3f13dd;if(_0x30e3e3)return _0x1d4bd6['body']['AccountId']=_0x30e3e3['id'],_0x1d4bd6[_0x504071('0x5b')]['Subjects']=integrations[_0x504071('0x39')](_0x1d4bd6[_0x504071('0x5b')][_0x504071('0x30')],_0x1d4bd6['body'][_0x504071('0x5f')]),_0x1d4bd6[_0x504071('0x5b')][_0x504071('0x11')]=integrations[_0x504071('0x4e')](_0x1d4bd6[_0x504071('0x5b')]['channel'],_0x1d4bd6[_0x504071('0x5b')][_0x504071('0x5f')]),db[_0x504071('0x4b')][_0x504071('0x28')](_0x1d4bd6[_0x504071('0x5b')],{'include':[{'model':db['SalesforceField'],'as':_0x504071('0x5e')},{'model':db[_0x504071('0x1b')],'as':_0x504071('0x11')}]});return null;})[_0x3f13dd('0x29')](respondWithResult(_0x54be8a,null))[_0x3f13dd('0x27')](handleError(_0x54be8a,null));},exports[_0xf564f3('0x26')]=function(_0x4e875e,_0x319bb9){const _0x84b576=_0xf564f3;let _0x9c840e,_0x28906a='',_0x46bb7e=_0x84b576('0x9');return db['SalesforceAccount']['findOne']({'where':{'id':_0x4e875e[_0x84b576('0x4f')]['id']},'attributes':['id',_0x84b576('0x17'),'clientId','clientSecret',_0x84b576('0x8'),'password',_0x84b576('0x55')]})[_0x84b576('0x29')](handleEntityNotFound(_0x319bb9,null))[_0x84b576('0x29')](function(_0x372cca){const _0x42fce1=_0x84b576;if(_0x372cca){_0x28906a=_0x372cca[_0x42fce1('0x17')];const _0x3e0159=_0x28906a[_0x42fce1('0x15')](-0x1);return _0x3e0159==='/'&&(_0x28906a=_0x28906a[_0x42fce1('0x41')](0x0,_0x28906a[_0x42fce1('0x13')](_0x3e0159))),_0x9c840e=new jsforce['Connection']({'oauth2':{'loginUrl':_0x28906a,'clientId':_0x372cca[_0x42fce1('0x1')],'clientSecret':_0x372cca[_0x42fce1('0x50')]}}),_0x9c840e[_0x42fce1('0x3c')](_0x372cca[_0x42fce1('0x8')],_0x372cca[_0x42fce1('0x6')][_0x42fce1('0x49')](_0x372cca[_0x42fce1('0x55')]));}})[_0x84b576('0x29')](function(_0x3ab07f){const _0x417dd1=_0x84b576;if(_0x3ab07f)return!_[_0x417dd1('0x4a')](_0x4e875e[_0x417dd1('0x3f')]['ticketType'])&&(_0x46bb7e=_0x4e875e[_0x417dd1('0x3f')][_0x417dd1('0x2c')]),_0x9c840e[_0x417dd1('0x57')](_0x46bb7e)[_0x417dd1('0x18')]();})[_0x84b576('0x29')](function(_0x31edf2){const _0x473d3e=_0x84b576;let _0x7e41af=['CallDisposition',_0x473d3e('0x12'),_0x473d3e('0x61'),_0x473d3e('0x23'),_0x473d3e('0x4d'),'Priority',_0x473d3e('0x68'),_0x473d3e('0x51')];!_[_0x473d3e('0x4a')](_0x4e875e['query'][_0x473d3e('0x2c')])&&_0x4e875e[_0x473d3e('0x3f')][_0x473d3e('0x2c')]===_0x473d3e('0x62')&&(_0x7e41af=[_0x473d3e('0x51'),_0x473d3e('0x1e'),_0x473d3e('0x53'),_0x473d3e('0x68'),_0x473d3e('0xf'),_0x473d3e('0x10'),_0x473d3e('0x38'),_0x473d3e('0x22')]);if(_0x31edf2)return _[_0x473d3e('0x4')](_0x31edf2['fields'],function(_0x3b3bee){const _0x2dff8d=_0x473d3e;return _0x3b3bee[_0x2dff8d('0xd')]===![]&&!_0x7e41af['includes'](_0x3b3bee[_0x2dff8d('0x16')]);}),{'count':_0x31edf2[_0x473d3e('0x20')]['length'],'rows':_['map'](_0x31edf2[_0x473d3e('0x20')],function(_0xa8e569){const _0x33dda9=_0x473d3e;return{'id':_0xa8e569['name'],'name':_0xa8e569[_0x33dda9('0x1d')],'custom':_0xa8e569[_0x33dda9('0xd')],'options':_0xa8e569['picklistValues'][_0x33dda9('0x54')]>0x0?_[_0x33dda9('0x14')](_0xa8e569[_0x33dda9('0x3')],function(_0xc3b253){const _0x25c42a=_0x33dda9;return{'name':_0xc3b253[_0x25c42a('0x1d')],'value':_0xc3b253[_0x25c42a('0x2a')]};}):_0xa8e569[_0x33dda9('0x5f')]=='boolean'?[{'name':_0x33dda9('0x2b'),'value':_0x33dda9('0x37')},{'name':_0x33dda9('0x5a'),'value':_0x33dda9('0x25')}]:[]};})};})[_0x84b576('0x29')](respondWithResult(_0x319bb9,null))['catch'](function(_0x22b13b){const _0x25eb62=_0x84b576;let _0x334599=_0x4e875e[_0x25eb62('0x3f')][_0x25eb62('0x36')]?0x1f4:_0x22b13b['statusCode']||0x1f4;logger[_0x25eb62('0x67')](_0x25eb62('0xa'),_0x25eb62('0x26'),_0x334599,JSON[_0x25eb62('0x5')](_0x22b13b)),delete _0x22b13b[_0x25eb62('0x16')],_0x334599===0x191&&(_0x334599=0x190),_0x319bb9[_0x25eb62('0x33')](_0x334599)[_0x25eb62('0x66')](_0x4e875e[_0x25eb62('0x3f')][_0x25eb62('0x36')]?{'message':'Wrong\x20credentials','statusCode':_0x22b13b[_0x25eb62('0x48')]}:_0x22b13b);});}; \ No newline at end of file +const a281_0x18f9=['jsforce','undefined','CallType','includeAll','securityToken','../../config/logger','getConfigurations','catch','label','../../components/parsers/qs','sobject','false','filter','Descriptions','substring','login','order','Subjects','addConfiguration','Task','CallDisposition','stringify','json','error','count','merge','password','clientSecret','pick','lodash','limit','body','include','concat','SalesforceField','params','channel','query','key','Reason','clientId','../../mysqldb','username','map','Case','fields','lastIndexOf','True','attributes','rows','SuppliedName','custom','SalesforceAccount','index','Content-Range','type','CallDurationInSeconds','where','rawAttributes','length','statusCode','SalesforceConfiguration','api','model','nolimit','then','picklistValues','IsEscalated','true','end','intersection','remove','isNil','offset','name','findAll','filters','create','getDescriptions','keys','show','findOne','getFields','Connection','VIRTUAL','send','False','stack','sort','Wrong\x20credentials','options','Type','Priority','value','like','status','ticketType','fieldName','Status','destroy'];(function(_0x441659,_0x18f968){const _0x377593=function(_0x18e56a){while(--_0x18e56a){_0x441659['push'](_0x441659['shift']());}};_0x377593(++_0x18f968);}(a281_0x18f9,0x130));const a281_0x3775=function(_0x441659,_0x18f968){_0x441659=_0x441659-0x0;let _0x377593=a281_0x18f9[_0x441659];return _0x377593;};const _0x2a06ea=a281_0x3775;'use strict';const _=require(_0x2a06ea('0x19')),jsforce=require(_0x2a06ea('0x60')),qs=require(_0x2a06ea('0x5')),logger=require(_0x2a06ea('0x1'))(_0x2a06ea('0x3a')),db=require(_0x2a06ea('0x25'))['db'],{Op}=require('sequelize'),integrations=require('../../components/integrations/configuration');function respondWithResult(_0x18e56a,_0x4c4ae4){return _0x4c4ae4=_0x4c4ae4||0xc8,function(_0x8dfb57){const _0x53f9e8=a281_0x3775;if(_0x8dfb57)return _0x18e56a[_0x53f9e8('0x5b')](_0x4c4ae4)[_0x53f9e8('0x12')](_0x8dfb57);};}function respondWithFilteredResult(_0x429856,_0x1ba856){return function(_0x50c17d){const _0x5ad0c0=a281_0x3775;if(_0x50c17d){const _0x43e3da=_0x50c17d[_0x5ad0c0('0x14')],_0x186ff0=_0x1ba856[_0x5ad0c0('0x45')];let _0x3ae634=_0x1ba856[_0x5ad0c0('0x45')]+_0x1ba856['limit'],_0xb8eab2;return _0x3ae634>=_0x43e3da?(_0x3ae634=_0x43e3da,_0xb8eab2=0xc8):_0xb8eab2=0xce,_0x429856['status'](_0xb8eab2),_0x429856['set'](_0x5ad0c0('0x32'),_0x186ff0+'-'+_0x3ae634+'/'+_0x43e3da)[_0x5ad0c0('0x12')](_0x50c17d);}return null;};}function saveUpdates(_0x4b3cdd){return function(_0x380ef0){const _0x2c9714=a281_0x3775;if(_0x380ef0)return _0x380ef0['update'](_0x4b3cdd)[_0x2c9714('0x3d')](function(_0x5838c4){return _0x5838c4;});return null;};}function removeEntity(_0x81924e){return function(_0x2ce607){const _0x470ba7=a281_0x3775;if(_0x2ce607)return _0x2ce607['destroy']()[_0x470ba7('0x3d')](function(){const _0x3ffc80=_0x470ba7;_0x81924e[_0x3ffc80('0x5b')](0xcc)[_0x3ffc80('0x41')]();});};}function handleEntityNotFound(_0x5c722d){return function(_0x4c7246){return!_0x4c7246&&_0x5c722d['sendStatus'](0x194),_0x4c7246;};}function handleError(_0x5dd67e,_0x5c3589){return _0x5c3589=_0x5c3589||0x1f4,function(_0x51d5c1){const _0x2a5ab2=a281_0x3775;logger[_0x2a5ab2('0x13')](_0x51d5c1[_0x2a5ab2('0x53')]),_0x51d5c1[_0x2a5ab2('0x46')]&&delete _0x51d5c1[_0x2a5ab2('0x46')],_0x5dd67e['status'](_0x5c3589)[_0x2a5ab2('0x51')](_0x51d5c1);};}exports[_0x2a06ea('0x31')]=function(_0x4abecb,_0x3bb0b6){const _0x1f7480=_0x2a06ea;let _0xa0a25d={};const _0x749596={},_0x33177c={'count':0x0,'rows':[]},_0xa55af8=_[_0x1f7480('0x27')](db[_0x1f7480('0x30')]['rawAttributes'],function(_0xab1e10){const _0x41810a=_0x1f7480;return{'name':_0xab1e10[_0x41810a('0x5d')],'type':_0xab1e10[_0x41810a('0x33')][_0x41810a('0x22')]};});_0x749596[_0x1f7480('0x3b')]=_[_0x1f7480('0x27')](_0xa55af8,_0x1f7480('0x46')),_0x749596['query']=_[_0x1f7480('0x4b')](_0x4abecb['query']),_0x749596[_0x1f7480('0x48')]=_[_0x1f7480('0x42')](_0x749596[_0x1f7480('0x3b')],_0x749596[_0x1f7480('0x21')]),_0xa0a25d['attributes']=_[_0x1f7480('0x42')](_0x749596[_0x1f7480('0x3b')],qs['fields'](_0x4abecb[_0x1f7480('0x21')][_0x1f7480('0x29')])),_0xa0a25d[_0x1f7480('0x2c')]=_0xa0a25d[_0x1f7480('0x2c')]['length']?_0xa0a25d[_0x1f7480('0x2c')]:_0x749596['model'];typeof _0x4abecb[_0x1f7480('0x21')]['nolimit']===_0x1f7480('0x61')&&(_0xa0a25d[_0x1f7480('0x1a')]=qs['limit'](_0x4abecb[_0x1f7480('0x21')]['limit']),_0xa0a25d[_0x1f7480('0x45')]=qs[_0x1f7480('0x45')](_0x4abecb[_0x1f7480('0x21')][_0x1f7480('0x45')]));_0xa0a25d[_0x1f7480('0xc')]=qs[_0x1f7480('0x54')](_0x4abecb['query'][_0x1f7480('0x54')]),_0xa0a25d['where']=qs[_0x1f7480('0x48')](_['pick'](_0x4abecb[_0x1f7480('0x21')],_0x749596[_0x1f7480('0x48')]),_0xa55af8);_0x4abecb[_0x1f7480('0x21')][_0x1f7480('0x8')]&&(_0xa0a25d[_0x1f7480('0x35')]=_[_0x1f7480('0x15')](_0xa0a25d[_0x1f7480('0x35')],{[Op['or']]:_['map'](_0xa55af8,function(_0x25d48c){const _0xae9b6a=_0x1f7480;if(_0x25d48c[_0xae9b6a('0x33')]!==_0xae9b6a('0x50')){const _0x55c470={};return _0x55c470[_0x25d48c[_0xae9b6a('0x46')]]={[Op['like']]:'%'+_0x4abecb['query'][_0xae9b6a('0x8')]+'%'},_0x55c470;}})}));_0xa0a25d=_[_0x1f7480('0x15')]({},_0xa0a25d,_0x4abecb['options']);const _0x4ce8e4={'where':_0xa0a25d[_0x1f7480('0x35')]};return db[_0x1f7480('0x30')][_0x1f7480('0x14')](_0x4ce8e4)[_0x1f7480('0x3d')](function(_0x21d017){const _0x51b36d=_0x1f7480;return _0x33177c['count']=_0x21d017,_0x4abecb['query'][_0x51b36d('0x63')]&&(_0xa0a25d[_0x51b36d('0x1c')]=[{'all':!![]}]),db[_0x51b36d('0x30')][_0x51b36d('0x47')](_0xa0a25d);})[_0x1f7480('0x3d')](function(_0x3112e6){const _0x4bf148=_0x1f7480;return _0x33177c[_0x4bf148('0x2d')]=_0x3112e6,_0x33177c;})['then'](respondWithFilteredResult(_0x3bb0b6,_0xa0a25d))['catch'](handleError(_0x3bb0b6,null));},exports[_0x2a06ea('0x4c')]=function(_0x43fc7a,_0x4ebf86){const _0x944b6c=_0x2a06ea;let _0x17c008={'raw':![],'where':{'id':_0x43fc7a[_0x944b6c('0x1f')]['id']}};const _0x27784a={};return _0x27784a['model']=_[_0x944b6c('0x4b')](db[_0x944b6c('0x30')][_0x944b6c('0x36')]),_0x27784a[_0x944b6c('0x21')]=_[_0x944b6c('0x4b')](_0x43fc7a[_0x944b6c('0x21')]),_0x27784a['filters']=_[_0x944b6c('0x42')](_0x27784a['model'],_0x27784a[_0x944b6c('0x21')]),_0x17c008[_0x944b6c('0x2c')]=_[_0x944b6c('0x42')](_0x27784a[_0x944b6c('0x3b')],qs[_0x944b6c('0x29')](_0x43fc7a[_0x944b6c('0x21')][_0x944b6c('0x29')])),_0x17c008[_0x944b6c('0x2c')]=_0x17c008[_0x944b6c('0x2c')]['length']?_0x17c008[_0x944b6c('0x2c')]:_0x27784a[_0x944b6c('0x3b')],_0x43fc7a['query'][_0x944b6c('0x63')]&&(_0x17c008[_0x944b6c('0x1c')]=[{'all':!![]}]),_0x17c008=_[_0x944b6c('0x15')]({},_0x17c008,_0x43fc7a['options']),db[_0x944b6c('0x30')][_0x944b6c('0x4d')](_0x17c008)['then'](handleEntityNotFound(_0x4ebf86,null))[_0x944b6c('0x3d')](respondWithResult(_0x4ebf86,null))[_0x944b6c('0x3')](handleError(_0x4ebf86,null));},exports[_0x2a06ea('0x49')]=function(_0x19ff9e,_0x47f7b5){const _0x24b8d5=_0x2a06ea;return db[_0x24b8d5('0x30')][_0x24b8d5('0x49')](_0x19ff9e[_0x24b8d5('0x1b')],{})[_0x24b8d5('0x3d')](respondWithResult(_0x47f7b5,0xc9))[_0x24b8d5('0x3')](handleError(_0x47f7b5,null));},exports['update']=function(_0x3d414b,_0xb4ecfd){const _0x1129a9=_0x2a06ea;return _0x3d414b['body']['id']&&delete _0x3d414b['body']['id'],db[_0x1129a9('0x30')][_0x1129a9('0x4d')]({'where':{'id':_0x3d414b[_0x1129a9('0x1f')]['id']}})['then'](handleEntityNotFound(_0xb4ecfd,null))[_0x1129a9('0x3d')](saveUpdates(_0x3d414b[_0x1129a9('0x1b')],null))[_0x1129a9('0x3d')](respondWithResult(_0xb4ecfd,null))[_0x1129a9('0x3')](handleError(_0xb4ecfd,null));},exports[_0x2a06ea('0x5f')]=function(_0x30d633,_0x31442c){const _0x41a6bc=_0x2a06ea;return db[_0x41a6bc('0x30')][_0x41a6bc('0x4d')]({'where':{'id':_0x30d633[_0x41a6bc('0x1f')]['id']}})[_0x41a6bc('0x3d')](handleEntityNotFound(_0x31442c,null))[_0x41a6bc('0x3d')](removeEntity(_0x31442c,null))[_0x41a6bc('0x3')](handleError(_0x31442c,null));},exports[_0x2a06ea('0x2')]=function(_0x251460,_0x4772b4){const _0x161909=_0x2a06ea;let _0x2a9087={};const _0x396450={};let _0x1c05ff,_0x54b861;return db[_0x161909('0x30')][_0x161909('0x4d')]({'where':{'id':_0x251460[_0x161909('0x1f')]['id']}})[_0x161909('0x3d')](handleEntityNotFound(_0x4772b4,null))[_0x161909('0x3d')](function(_0x415609){const _0xda76c4=_0x161909;if(_0x415609)return _0x1c05ff=_0x415609,_0x396450[_0xda76c4('0x3b')]=_[_0xda76c4('0x4b')](db[_0xda76c4('0x39')][_0xda76c4('0x36')]),_0x396450[_0xda76c4('0x21')]=_['keys'](_0x251460['query']),_0x396450[_0xda76c4('0x48')]=_[_0xda76c4('0x42')](_0x396450[_0xda76c4('0x3b')],_0x396450[_0xda76c4('0x21')]),_0x2a9087['attributes']=_[_0xda76c4('0x42')](_0x396450[_0xda76c4('0x3b')],qs[_0xda76c4('0x29')](_0x251460[_0xda76c4('0x21')][_0xda76c4('0x29')])),_0x2a9087['attributes']=_0x2a9087[_0xda76c4('0x2c')][_0xda76c4('0x37')]?_0x2a9087['attributes']:_0x396450[_0xda76c4('0x3b')],_0x2a9087[_0xda76c4('0xc')]=qs[_0xda76c4('0x54')](_0x251460[_0xda76c4('0x21')][_0xda76c4('0x54')]),_0x2a9087['where']=qs['filters'](_[_0xda76c4('0x18')](_0x251460[_0xda76c4('0x21')],_0x396450[_0xda76c4('0x48')])),_0x251460[_0xda76c4('0x21')][_0xda76c4('0x8')]&&(_0x2a9087[_0xda76c4('0x35')]=_[_0xda76c4('0x15')](_0x2a9087[_0xda76c4('0x35')],{[Op['or']]:_[_0xda76c4('0x27')](_0x2a9087[_0xda76c4('0x2c')],function(_0x179d11){const _0x50bdcb=_0xda76c4,_0xa845d9={};return _0xa845d9[_0x179d11]={[Op[_0x50bdcb('0x5a')]]:'%'+_0x251460[_0x50bdcb('0x21')][_0x50bdcb('0x8')]+'%'},_0xa845d9;})})),_0x2a9087=_[_0xda76c4('0x15')]({},_0x2a9087,_0x251460[_0xda76c4('0x56')]),_0x1c05ff[_0xda76c4('0x2')](_0x2a9087);})[_0x161909('0x3d')](function(_0x5164d0){const _0x11e966=_0x161909;if(_0x5164d0)return _0x54b861=_0x5164d0['length'],typeof _0x251460[_0x11e966('0x21')][_0x11e966('0x3c')]===_0x11e966('0x61')&&(_0x2a9087[_0x11e966('0x1a')]=qs['limit'](_0x251460['query'][_0x11e966('0x1a')]),_0x2a9087[_0x11e966('0x45')]=qs[_0x11e966('0x45')](_0x251460[_0x11e966('0x21')][_0x11e966('0x45')])),_0x1c05ff[_0x11e966('0x2')](_0x2a9087);})[_0x161909('0x3d')](function(_0x60f0fe){if(_0x60f0fe)return _0x60f0fe?{'count':_0x54b861,'rows':_0x60f0fe}:null;})[_0x161909('0x3d')](respondWithResult(_0x4772b4,null))[_0x161909('0x3')](handleError(_0x4772b4,null));},exports[_0x2a06ea('0xe')]=function(_0x28699d,_0x32d39a){const _0x569ecc=_0x2a06ea;return _0x28699d['body']['id']&&delete _0x28699d[_0x569ecc('0x1b')]['id'],db['SalesforceAccount']['findOne']({'where':{'id':_0x28699d[_0x569ecc('0x1f')]['id']}})['then'](handleEntityNotFound(_0x32d39a,null))['then'](function(_0x4ab0ca){const _0x216940=_0x569ecc;if(_0x4ab0ca)return _0x28699d[_0x216940('0x1b')]['AccountId']=_0x4ab0ca['id'],_0x28699d['body'][_0x216940('0xd')]=integrations['getSubjects'](_0x28699d[_0x216940('0x1b')][_0x216940('0x20')],_0x28699d['body']['type']),_0x28699d[_0x216940('0x1b')][_0x216940('0x9')]=integrations[_0x216940('0x4a')](_0x28699d[_0x216940('0x1b')]['channel'],_0x28699d['body'][_0x216940('0x33')]),db[_0x216940('0x39')][_0x216940('0x49')](_0x28699d[_0x216940('0x1b')],{'include':[{'model':db[_0x216940('0x1e')],'as':_0x216940('0xd')},{'model':db[_0x216940('0x1e')],'as':_0x216940('0x9')}]});return null;})[_0x569ecc('0x3d')](respondWithResult(_0x32d39a,null))[_0x569ecc('0x3')](handleError(_0x32d39a,null));},exports['getFields']=function(_0xb656b0,_0x594e60){const _0x8651c0=_0x2a06ea;let _0x29a30d,_0x17b82e='',_0x1f004b=_0x8651c0('0xf');return db['SalesforceAccount'][_0x8651c0('0x4d')]({'where':{'id':_0xb656b0['params']['id']},'attributes':['id','remoteUri','clientId',_0x8651c0('0x17'),_0x8651c0('0x26'),'password','securityToken']})[_0x8651c0('0x3d')](handleEntityNotFound(_0x594e60,null))[_0x8651c0('0x3d')](function(_0x77aade){const _0x5bab1c=_0x8651c0;if(_0x77aade){_0x17b82e=_0x77aade['remoteUri'];const _0x35ad2b=_0x17b82e['slice'](-0x1);return _0x35ad2b==='/'&&(_0x17b82e=_0x17b82e[_0x5bab1c('0xa')](0x0,_0x17b82e[_0x5bab1c('0x2a')](_0x35ad2b))),_0x29a30d=new jsforce[(_0x5bab1c('0x4f'))]({'oauth2':{'loginUrl':_0x17b82e,'clientId':_0x77aade[_0x5bab1c('0x24')],'clientSecret':_0x77aade[_0x5bab1c('0x17')]}}),_0x29a30d[_0x5bab1c('0xb')](_0x77aade[_0x5bab1c('0x26')],_0x77aade[_0x5bab1c('0x16')][_0x5bab1c('0x1d')](_0x77aade[_0x5bab1c('0x0')]));}})[_0x8651c0('0x3d')](function(_0x234c2f){const _0x6b6f12=_0x8651c0;if(_0x234c2f)return!_[_0x6b6f12('0x44')](_0xb656b0[_0x6b6f12('0x21')][_0x6b6f12('0x5c')])&&(_0x1f004b=_0xb656b0['query'][_0x6b6f12('0x5c')]),_0x29a30d[_0x6b6f12('0x6')](_0x1f004b)['describe']();})[_0x8651c0('0x3d')](function(_0x10312a){const _0x41196d=_0x8651c0;let _0x12dfca=[_0x41196d('0x10'),_0x41196d('0x34'),'CallObject',_0x41196d('0x62'),'IsArchived',_0x41196d('0x58'),_0x41196d('0x5e'),_0x41196d('0x57')];!_[_0x41196d('0x44')](_0xb656b0[_0x41196d('0x21')][_0x41196d('0x5c')])&&_0xb656b0['query'][_0x41196d('0x5c')]===_0x41196d('0x28')&&(_0x12dfca=[_0x41196d('0x57'),'Origin',_0x41196d('0x23'),_0x41196d('0x5e'),_0x41196d('0x58'),_0x41196d('0x3f'),_0x41196d('0x2e'),'SuppliedCompany']);if(_0x10312a)return _[_0x41196d('0x43')](_0x10312a[_0x41196d('0x29')],function(_0x57b3d8){const _0x467921=_0x41196d;return _0x57b3d8[_0x467921('0x2f')]===![]&&!_0x12dfca['includes'](_0x57b3d8[_0x467921('0x46')]);}),{'count':_0x10312a[_0x41196d('0x29')][_0x41196d('0x37')],'rows':_[_0x41196d('0x27')](_0x10312a[_0x41196d('0x29')],function(_0x4df0bf){const _0x3afa6f=_0x41196d;return{'id':_0x4df0bf['name'],'name':_0x4df0bf[_0x3afa6f('0x4')],'custom':_0x4df0bf[_0x3afa6f('0x2f')],'options':_0x4df0bf[_0x3afa6f('0x3e')][_0x3afa6f('0x37')]>0x0?_['map'](_0x4df0bf[_0x3afa6f('0x3e')],function(_0x5064b3){const _0x260f45=_0x3afa6f;return{'name':_0x5064b3[_0x260f45('0x4')],'value':_0x5064b3[_0x260f45('0x59')]};}):_0x4df0bf[_0x3afa6f('0x33')]=='boolean'?[{'name':_0x3afa6f('0x2b'),'value':_0x3afa6f('0x40')},{'name':_0x3afa6f('0x52'),'value':_0x3afa6f('0x7')}]:[]};})};})[_0x8651c0('0x3d')](respondWithResult(_0x594e60,null))[_0x8651c0('0x3')](function(_0x3eb5bd){const _0x2bea4f=_0x8651c0;let _0x3cefe2=_0xb656b0[_0x2bea4f('0x21')]['test']?0x1f4:_0x3eb5bd['statusCode']||0x1f4;logger[_0x2bea4f('0x13')]('getFields,\x20%s,\x20%s,\x20%s',_0x2bea4f('0x4e'),_0x3cefe2,JSON[_0x2bea4f('0x11')](_0x3eb5bd)),delete _0x3eb5bd[_0x2bea4f('0x46')],_0x3cefe2===0x191&&(_0x3cefe2=0x190),_0x594e60[_0x2bea4f('0x5b')](_0x3cefe2)[_0x2bea4f('0x51')](_0xb656b0[_0x2bea4f('0x21')]['test']?{'message':_0x2bea4f('0x55'),'statusCode':_0x3eb5bd[_0x2bea4f('0x38')]}:_0x3eb5bd);});}; \ No newline at end of file diff --git a/server/api/intSalesforceAccount/intSalesforceAccount.model.js b/server/api/intSalesforceAccount/intSalesforceAccount.model.js index b73ee91..f267f7a 100644 --- a/server/api/intSalesforceAccount/intSalesforceAccount.model.js +++ b/server/api/intSalesforceAccount/intSalesforceAccount.model.js @@ -1 +1 @@ -const a282_0x138d=['define','./intSalesforceAccount.attributes','SalesforceAccount'];(function(_0x127f07,_0x138d02){const _0x4ed960=function(_0x476fe8){while(--_0x476fe8){_0x127f07['push'](_0x127f07['shift']());}};_0x4ed960(++_0x138d02);}(a282_0x138d,0xc2));const a282_0x4ed9=function(_0x127f07,_0x138d02){_0x127f07=_0x127f07-0x0;let _0x4ed960=a282_0x138d[_0x127f07];return _0x4ed960;};const _0x175205=a282_0x4ed9;'use strict';const attributes=require(_0x175205('0x2'));module['exports']=function(_0x476fe8){const _0x29b841=_0x175205,_0x5ea6ba=_0x476fe8[_0x29b841('0x1')](_0x29b841('0x0'),attributes,{'tableName':'int_salesforce_accounts','paranoid':![],'indexes':[],'timestamps':!![]});return _0x5ea6ba;}; \ No newline at end of file +const a282_0x2e48=['./intSalesforceAccount.attributes','define','int_salesforce_accounts','SalesforceAccount'];(function(_0x2cba9c,_0x2e48bd){const _0x4b0467=function(_0x206efd){while(--_0x206efd){_0x2cba9c['push'](_0x2cba9c['shift']());}};_0x4b0467(++_0x2e48bd);}(a282_0x2e48,0x107));const a282_0x4b04=function(_0x2cba9c,_0x2e48bd){_0x2cba9c=_0x2cba9c-0x0;let _0x4b0467=a282_0x2e48[_0x2cba9c];return _0x4b0467;};const _0x24b35c=a282_0x4b04;'use strict';const attributes=require(_0x24b35c('0x1'));module['exports']=function(_0x206efd){const _0x225082=_0x24b35c,_0x2f82ca=_0x206efd[_0x225082('0x2')](_0x225082('0x0'),attributes,{'tableName':_0x225082('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2f82ca;}; \ No newline at end of file diff --git a/server/api/intSalesforceAccount/intSalesforceAccount.rpc.js b/server/api/intSalesforceAccount/intSalesforceAccount.rpc.js index 895c723..be83611 100644 --- a/server/api/intSalesforceAccount/intSalesforceAccount.rpc.js +++ b/server/api/intSalesforceAccount/intSalesforceAccount.rpc.js @@ -1 +1 @@ -const a283_0x16ac=['catch','GetSalesforceAccount','SalesforceAccount','debug','options','limit','findOne','rpc','map','../../mysqldb','findAll','ShowSalesforceAccount','model','stringify','error','raw','info','where','include','attributes','message'];(function(_0xe55c34,_0x16acda){const _0x116b3f=function(_0x120201){while(--_0x120201){_0xe55c34['push'](_0xe55c34['shift']());}};_0x116b3f(++_0x16acda);}(a283_0x16ac,0x17c));const a283_0x116b=function(_0xe55c34,_0x16acda){_0xe55c34=_0xe55c34-0x0;let _0x116b3f=a283_0x16ac[_0xe55c34];return _0x116b3f;};const _0x3b0625=a283_0x116b;'use strict';const _=require('lodash'),db=require(_0x3b0625('0x7'))['db'],logger=require('../../config/logger')(_0x3b0625('0x5'));exports['GetSalesforceAccount']=function(_0x120201){const _0x50e49a=this;return new Promise(function(_0x2ff115,_0x34239f){const _0x3fae8e=a283_0x116b;return db[_0x3fae8e('0x0')][_0x3fae8e('0x8')]({'raw':_0x120201[_0x3fae8e('0x2')]?_0x120201[_0x3fae8e('0x2')]['raw']===undefined?!![]:![]:!![],'where':_0x120201[_0x3fae8e('0x2')]?_0x120201[_0x3fae8e('0x2')][_0x3fae8e('0xf')]||null:null,'attributes':_0x120201[_0x3fae8e('0x2')]?_0x120201[_0x3fae8e('0x2')][_0x3fae8e('0x11')]||null:null,'limit':_0x120201[_0x3fae8e('0x2')]?_0x120201[_0x3fae8e('0x2')][_0x3fae8e('0x3')]||null:null,'include':_0x120201[_0x3fae8e('0x2')]?_0x120201[_0x3fae8e('0x2')]['include']?_['map'](_0x120201['options'][_0x3fae8e('0x10')],function(_0x5b7d87){const _0x37522c=_0x3fae8e;return{'model':db[_0x5b7d87['model']],'as':_0x5b7d87['as'],'attributes':_0x5b7d87[_0x37522c('0x11')],'include':_0x5b7d87[_0x37522c('0x10')]?_[_0x37522c('0x6')](_0x5b7d87[_0x37522c('0x10')],function(_0x519f6d){const _0x5a32aa=_0x37522c;return{'model':db[_0x519f6d[_0x5a32aa('0xa')]],'as':_0x519f6d['as'],'attributes':_0x519f6d[_0x5a32aa('0x11')],'include':_0x519f6d['include']?_[_0x5a32aa('0x6')](_0x519f6d[_0x5a32aa('0x10')],function(_0x5b2911){const _0x1a1492=_0x5a32aa;return{'model':db[_0x5b2911[_0x1a1492('0xa')]],'as':_0x5b2911['as'],'attributes':_0x5b2911['attributes']};}):[]};}):[]};}):[]:[]})['then'](function(_0x69a596){const _0x1d982b=_0x3fae8e;logger[_0x1d982b('0xe')]('GetSalesforceAccount',_0x120201),logger[_0x1d982b('0x1')](_0x1d982b('0x14'),_0x120201,JSON[_0x1d982b('0xb')](_0x69a596)),_0x2ff115(_0x69a596);})[_0x3fae8e('0x13')](function(_0xa858ce){const _0x44085c=_0x3fae8e;logger[_0x44085c('0xc')](_0x44085c('0x14'),_0xa858ce['message'],_0x120201),_0x34239f(_0x50e49a[_0x44085c('0xc')](0x1f4,_0xa858ce[_0x44085c('0x12')]));});});},exports[_0x3b0625('0x9')]=function(_0x6cc575){const _0x12e6fe=this;return new Promise(function(_0x391676,_0x142300){const _0x24e43c=a283_0x116b;return db['SalesforceAccount'][_0x24e43c('0x4')]({'raw':_0x6cc575[_0x24e43c('0x2')]?_0x6cc575[_0x24e43c('0x2')][_0x24e43c('0xd')]===undefined?!![]:![]:!![],'where':_0x6cc575[_0x24e43c('0x2')]?_0x6cc575[_0x24e43c('0x2')]['where']||null:null,'attributes':_0x6cc575[_0x24e43c('0x2')]?_0x6cc575['options'][_0x24e43c('0x11')]||null:null,'include':_0x6cc575['options']?_0x6cc575[_0x24e43c('0x2')]['include']?_[_0x24e43c('0x6')](_0x6cc575[_0x24e43c('0x2')][_0x24e43c('0x10')],function(_0x41bbbc){const _0x3e62c1=_0x24e43c;return{'model':db[_0x41bbbc[_0x3e62c1('0xa')]],'as':_0x41bbbc['as'],'attributes':_0x41bbbc[_0x3e62c1('0x11')],'include':_0x41bbbc['include']?_[_0x3e62c1('0x6')](_0x41bbbc[_0x3e62c1('0x10')],function(_0x355de6){const _0x2f57b0=_0x3e62c1;return{'model':db[_0x355de6[_0x2f57b0('0xa')]],'as':_0x355de6['as'],'attributes':_0x355de6['attributes'],'include':_0x355de6['include']?_[_0x2f57b0('0x6')](_0x355de6[_0x2f57b0('0x10')],function(_0x45b044){const _0x5c6d60=_0x2f57b0;return{'model':db[_0x45b044[_0x5c6d60('0xa')]],'as':_0x45b044['as'],'attributes':_0x45b044[_0x5c6d60('0x11')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x10599e){const _0x5e26c1=_0x24e43c;logger['info']('ShowSalesforceAccount',_0x6cc575),logger[_0x5e26c1('0x1')](_0x5e26c1('0x9'),_0x6cc575,JSON['stringify'](_0x10599e)),_0x391676(_0x10599e);})[_0x24e43c('0x13')](function(_0x2a015b){const _0xf4cc96=_0x24e43c;logger[_0xf4cc96('0xc')]('ShowSalesforceAccount',_0x2a015b[_0xf4cc96('0x12')],_0x6cc575),_0x142300(_0x12e6fe[_0xf4cc96('0xc')](0x1f4,_0x2a015b[_0xf4cc96('0x12')]));});});}; \ No newline at end of file +const a283_0x3a8f=['SalesforceAccount','map','lodash','debug','info','then','stringify','rpc','ShowSalesforceAccount','raw','message','findAll','attributes','limit','options','error','catch','include','where','model','GetSalesforceAccount'];(function(_0x2640b6,_0x3a8f3c){const _0x58945e=function(_0xe7f8fa){while(--_0xe7f8fa){_0x2640b6['push'](_0x2640b6['shift']());}};_0x58945e(++_0x3a8f3c);}(a283_0x3a8f,0xce));const a283_0x5894=function(_0x2640b6,_0x3a8f3c){_0x2640b6=_0x2640b6-0x0;let _0x58945e=a283_0x3a8f[_0x2640b6];return _0x58945e;};const _0x30d010=a283_0x5894;'use strict';const _=require(_0x30d010('0x6')),db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x30d010('0xb'));exports[_0x30d010('0x3')]=function(_0xe7f8fa){const _0x1c2f68=this;return new Promise(function(_0x494d33,_0x4c7f44){const _0x10748f=a283_0x5894;return db[_0x10748f('0x4')][_0x10748f('0xf')]({'raw':_0xe7f8fa['options']?_0xe7f8fa['options'][_0x10748f('0xd')]===undefined?!![]:![]:!![],'where':_0xe7f8fa[_0x10748f('0x12')]?_0xe7f8fa['options'][_0x10748f('0x1')]||null:null,'attributes':_0xe7f8fa[_0x10748f('0x12')]?_0xe7f8fa[_0x10748f('0x12')]['attributes']||null:null,'limit':_0xe7f8fa['options']?_0xe7f8fa[_0x10748f('0x12')][_0x10748f('0x11')]||null:null,'include':_0xe7f8fa[_0x10748f('0x12')]?_0xe7f8fa['options']['include']?_['map'](_0xe7f8fa[_0x10748f('0x12')][_0x10748f('0x0')],function(_0x3293c5){const _0x27d386=_0x10748f;return{'model':db[_0x3293c5[_0x27d386('0x2')]],'as':_0x3293c5['as'],'attributes':_0x3293c5[_0x27d386('0x10')],'include':_0x3293c5[_0x27d386('0x0')]?_[_0x27d386('0x5')](_0x3293c5[_0x27d386('0x0')],function(_0x13eebf){const _0x21040e=_0x27d386;return{'model':db[_0x13eebf[_0x21040e('0x2')]],'as':_0x13eebf['as'],'attributes':_0x13eebf[_0x21040e('0x10')],'include':_0x13eebf[_0x21040e('0x0')]?_['map'](_0x13eebf[_0x21040e('0x0')],function(_0xdf0739){const _0x58b453=_0x21040e;return{'model':db[_0xdf0739[_0x58b453('0x2')]],'as':_0xdf0739['as'],'attributes':_0xdf0739[_0x58b453('0x10')]};}):[]};}):[]};}):[]:[]})[_0x10748f('0x9')](function(_0x28c591){const _0x5acc02=_0x10748f;logger['info'](_0x5acc02('0x3'),_0xe7f8fa),logger[_0x5acc02('0x7')](_0x5acc02('0x3'),_0xe7f8fa,JSON['stringify'](_0x28c591)),_0x494d33(_0x28c591);})['catch'](function(_0x339418){const _0x2487d7=_0x10748f;logger['error'](_0x2487d7('0x3'),_0x339418[_0x2487d7('0xe')],_0xe7f8fa),_0x4c7f44(_0x1c2f68[_0x2487d7('0x13')](0x1f4,_0x339418[_0x2487d7('0xe')]));});});},exports[_0x30d010('0xc')]=function(_0x4833cf){const _0x37b7b0=this;return new Promise(function(_0x4e4521,_0x45de08){const _0x31d042=a283_0x5894;return db[_0x31d042('0x4')]['findOne']({'raw':_0x4833cf[_0x31d042('0x12')]?_0x4833cf['options']['raw']===undefined?!![]:![]:!![],'where':_0x4833cf[_0x31d042('0x12')]?_0x4833cf[_0x31d042('0x12')][_0x31d042('0x1')]||null:null,'attributes':_0x4833cf[_0x31d042('0x12')]?_0x4833cf['options'][_0x31d042('0x10')]||null:null,'include':_0x4833cf[_0x31d042('0x12')]?_0x4833cf[_0x31d042('0x12')][_0x31d042('0x0')]?_[_0x31d042('0x5')](_0x4833cf[_0x31d042('0x12')][_0x31d042('0x0')],function(_0x14e0fa){const _0x495952=_0x31d042;return{'model':db[_0x14e0fa[_0x495952('0x2')]],'as':_0x14e0fa['as'],'attributes':_0x14e0fa[_0x495952('0x10')],'include':_0x14e0fa['include']?_[_0x495952('0x5')](_0x14e0fa[_0x495952('0x0')],function(_0x5d00ae){const _0xb73ec9=_0x495952;return{'model':db[_0x5d00ae['model']],'as':_0x5d00ae['as'],'attributes':_0x5d00ae['attributes'],'include':_0x5d00ae[_0xb73ec9('0x0')]?_[_0xb73ec9('0x5')](_0x5d00ae[_0xb73ec9('0x0')],function(_0x4d1f59){const _0x46290e=_0xb73ec9;return{'model':db[_0x4d1f59[_0x46290e('0x2')]],'as':_0x4d1f59['as'],'attributes':_0x4d1f59[_0x46290e('0x10')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x2952a9){const _0x1c3843=_0x31d042;logger[_0x1c3843('0x8')]('ShowSalesforceAccount',_0x4833cf),logger[_0x1c3843('0x7')](_0x1c3843('0xc'),_0x4833cf,JSON[_0x1c3843('0xa')](_0x2952a9)),_0x4e4521(_0x2952a9);})[_0x31d042('0x14')](function(_0x4107ca){const _0xac60fa=_0x31d042;logger['error']('ShowSalesforceAccount',_0x4107ca['message'],_0x4833cf),_0x45de08(_0x37b7b0[_0xac60fa('0x13')](0x1f4,_0x4107ca[_0xac60fa('0xe')]));});});}; \ No newline at end of file diff --git a/server/api/intSalesforceConfiguration/index.js b/server/api/intSalesforceConfiguration/index.js index cc1eb7f..1109967 100644 --- a/server/api/intSalesforceConfiguration/index.js +++ b/server/api/intSalesforceConfiguration/index.js @@ -1 +1 @@ -const a284_0x4ca4=['/:id/descriptions','create','getFields','update','/:id/fields','Router','get','isAuthenticated','delete','getSubjects','destroy','post','show','exports','express','/:id/subjects','./intSalesforceConfiguration.controller','/:id'];(function(_0x238943,_0x4ca433){const _0x9609fa=function(_0x311370){while(--_0x311370){_0x238943['push'](_0x238943['shift']());}};_0x9609fa(++_0x4ca433);}(a284_0x4ca4,0xeb));const a284_0x9609=function(_0x238943,_0x4ca433){_0x238943=_0x238943-0x0;let _0x9609fa=a284_0x4ca4[_0x238943];return _0x9609fa;};const _0x4ac808=a284_0x9609;'use strict';const express=require(_0x4ac808('0xd')),router=express[_0x4ac808('0x4')](),auth=require('../../components/auth/service'),controller=require(_0x4ac808('0xf'));router['get']('/',auth[_0x4ac808('0x6')](),controller['index']),router[_0x4ac808('0x5')](_0x4ac808('0x10'),auth[_0x4ac808('0x6')](),controller[_0x4ac808('0xb')]),router[_0x4ac808('0x5')](_0x4ac808('0x3'),auth[_0x4ac808('0x6')](),controller[_0x4ac808('0x1')]),router[_0x4ac808('0x5')](_0x4ac808('0xe'),auth[_0x4ac808('0x6')](),controller[_0x4ac808('0x8')]),router[_0x4ac808('0x5')](_0x4ac808('0x11'),auth[_0x4ac808('0x6')](),controller['getDescriptions']),router[_0x4ac808('0xa')]('/',auth['isAuthenticated'](),controller[_0x4ac808('0x0')]),router['put'](_0x4ac808('0x10'),auth[_0x4ac808('0x6')](),controller[_0x4ac808('0x2')]),router[_0x4ac808('0x7')](_0x4ac808('0x10'),auth[_0x4ac808('0x6')](),controller[_0x4ac808('0x9')]),module[_0x4ac808('0xc')]=router; \ No newline at end of file +const a284_0x18f6=['index','exports','getFields','../../components/auth/service','destroy','post','update','/:id/subjects','get','/:id/fields','/:id','express','Router','delete','getSubjects','./intSalesforceConfiguration.controller','/:id/descriptions','isAuthenticated','show','getDescriptions'];(function(_0x38e421,_0x18f6e1){const _0x34bd0f=function(_0x1d31f2){while(--_0x1d31f2){_0x38e421['push'](_0x38e421['shift']());}};_0x34bd0f(++_0x18f6e1);}(a284_0x18f6,0xb3));const a284_0x34bd=function(_0x38e421,_0x18f6e1){_0x38e421=_0x38e421-0x0;let _0x34bd0f=a284_0x18f6[_0x38e421];return _0x34bd0f;};const _0x49fc77=a284_0x34bd;'use strict';const express=require(_0x49fc77('0xc')),router=express[_0x49fc77('0xd')](),auth=require(_0x49fc77('0x4')),controller=require(_0x49fc77('0x10'));router[_0x49fc77('0x9')]('/',auth[_0x49fc77('0x12')](),controller[_0x49fc77('0x1')]),router[_0x49fc77('0x9')](_0x49fc77('0xb'),auth[_0x49fc77('0x12')](),controller[_0x49fc77('0x13')]),router[_0x49fc77('0x9')](_0x49fc77('0xa'),auth[_0x49fc77('0x12')](),controller[_0x49fc77('0x3')]),router['get'](_0x49fc77('0x8'),auth[_0x49fc77('0x12')](),controller[_0x49fc77('0xf')]),router[_0x49fc77('0x9')](_0x49fc77('0x11'),auth[_0x49fc77('0x12')](),controller[_0x49fc77('0x0')]),router[_0x49fc77('0x6')]('/',auth[_0x49fc77('0x12')](),controller['create']),router['put']('/:id',auth[_0x49fc77('0x12')](),controller[_0x49fc77('0x7')]),router[_0x49fc77('0xe')](_0x49fc77('0xb'),auth[_0x49fc77('0x12')](),controller[_0x49fc77('0x5')]),module[_0x49fc77('0x2')]=router; \ No newline at end of file diff --git a/server/api/intSalesforceConfiguration/intSalesforceConfiguration.attributes.js b/server/api/intSalesforceConfiguration/intSalesforceConfiguration.attributes.js index e48217f..b1f28f3 100644 --- a/server/api/intSalesforceConfiguration/intSalesforceConfiguration.attributes.js +++ b/server/api/intSalesforceConfiguration/intSalesforceConfiguration.attributes.js @@ -1 +1 @@ -const a285_0x502e=['contact','nothing','lead','STRING','contact_lead','exports','Task','ENUM'];(function(_0x219604,_0x502e6b){const _0x2dfd83=function(_0x4e20b4){while(--_0x4e20b4){_0x219604['push'](_0x219604['shift']());}};_0x2dfd83(++_0x502e6b);}(a285_0x502e,0xf9));const a285_0x2dfd=function(_0x219604,_0x502e6b){_0x219604=_0x219604-0x0;let _0x2dfd83=a285_0x502e[_0x219604];return _0x2dfd83;};const _0x3a450e=a285_0x2dfd;'use strict';const Sequelize=require('sequelize');module[_0x3a450e('0x4')]={'name':{'type':Sequelize[_0x3a450e('0x2')]},'description':{'type':Sequelize[_0x3a450e('0x2')]},'ticketType':{'type':Sequelize[_0x3a450e('0x6')](_0x3a450e('0x5'),'Case'),'defaultValue':'Task'},'moduleSearch':{'type':Sequelize[_0x3a450e('0x6')](_0x3a450e('0x3'),'contact',_0x3a450e('0x1')),'defaultValue':_0x3a450e('0x3')},'moduleCreate':{'type':Sequelize[_0x3a450e('0x6')](_0x3a450e('0x0'),_0x3a450e('0x7'),_0x3a450e('0x1')),'defaultValue':'lead'}}; \ No newline at end of file +const a285_0x564b=['Case','nothing','ENUM','contact','Task','STRING','exports','contact_lead','lead'];(function(_0x2ea741,_0x564ba7){const _0x585905=function(_0x5f46c4){while(--_0x5f46c4){_0x2ea741['push'](_0x2ea741['shift']());}};_0x585905(++_0x564ba7);}(a285_0x564b,0x1f1));const a285_0x5859=function(_0x2ea741,_0x564ba7){_0x2ea741=_0x2ea741-0x0;let _0x585905=a285_0x564b[_0x2ea741];return _0x585905;};const _0x288fe4=a285_0x5859;'use strict';const Sequelize=require('sequelize');module[_0x288fe4('0x4')]={'name':{'type':Sequelize[_0x288fe4('0x3')]},'description':{'type':Sequelize[_0x288fe4('0x3')]},'ticketType':{'type':Sequelize[_0x288fe4('0x0')](_0x288fe4('0x2'),_0x288fe4('0x7')),'defaultValue':'Task'},'moduleSearch':{'type':Sequelize[_0x288fe4('0x0')](_0x288fe4('0x5'),_0x288fe4('0x1'),'lead'),'defaultValue':'contact_lead'},'moduleCreate':{'type':Sequelize['ENUM'](_0x288fe4('0x8'),'contact',_0x288fe4('0x6')),'defaultValue':_0x288fe4('0x6')}}; \ No newline at end of file diff --git a/server/api/intSalesforceConfiguration/intSalesforceConfiguration.controller.js b/server/api/intSalesforceConfiguration/intSalesforceConfiguration.controller.js index 820c40d..eab14c5 100644 --- a/server/api/intSalesforceConfiguration/intSalesforceConfiguration.controller.js +++ b/server/api/intSalesforceConfiguration/intSalesforceConfiguration.controller.js @@ -1 +1 @@ -const a286_0x327c=['VIRTUAL','intersection','offset','../../components/parsers/qs','limit','nolimit','filter','index','type','rawAttributes','map','filters','../../mysqldb','then','merge','key','name','status','findOne','sendStatus','attributes','fields','getDescriptions','query','findAll','getFields','keys','fieldName','includeAll','sort','show','destroy','include','update','SalesforceConfiguration','Content-Range','options','body','length','error','undefined','params','count','stack','pick','order','getSubjects','json','catch','like','api','end','SalesforceField','set','where','model','create'];(function(_0x48fd02,_0x327c01){const _0xa751e2=function(_0x43fb9b){while(--_0x43fb9b){_0x48fd02['push'](_0x48fd02['shift']());}};_0xa751e2(++_0x327c01);}(a286_0x327c,0xcf));const a286_0xa751=function(_0x48fd02,_0x327c01){_0x48fd02=_0x48fd02-0x0;let _0xa751e2=a286_0x327c[_0x48fd02];return _0xa751e2;};const _0x5761b7=a286_0xa751;'use strict';const _=require('lodash'),qs=require(_0x5761b7('0x18')),logger=require('../../config/logger')(_0x5761b7('0xe')),db=require(_0x5761b7('0x21'))['db'],{Op}=require('sequelize');function respondWithResult(_0x43fb9b,_0x8c30ec){return _0x8c30ec=_0x8c30ec||0xc8,function(_0x52afdc){const _0x2562d5=a286_0xa751;if(_0x52afdc)return _0x43fb9b[_0x2562d5('0x26')](_0x8c30ec)[_0x2562d5('0xb')](_0x52afdc);};}function respondWithFilteredResult(_0x42acee,_0x3369d6){return function(_0x52991b){const _0x56ff6b=a286_0xa751;if(_0x52991b){const _0x5aadc2=_0x52991b[_0x56ff6b('0x6')],_0x505d39=_0x3369d6[_0x56ff6b('0x17')];let _0xcc8d1d=_0x3369d6['offset']+_0x3369d6[_0x56ff6b('0x19')],_0x5bfa16;return _0xcc8d1d>=_0x5aadc2?(_0xcc8d1d=_0x5aadc2,_0x5bfa16=0xc8):_0x5bfa16=0xce,_0x42acee[_0x56ff6b('0x26')](_0x5bfa16),_0x42acee[_0x56ff6b('0x11')](_0x56ff6b('0x38'),_0x505d39+'-'+_0xcc8d1d+'/'+_0x5aadc2)[_0x56ff6b('0xb')](_0x52991b);}return null;};}function saveUpdates(_0x1baabf){return function(_0x51b22e){const _0x2fb259=a286_0xa751;if(_0x51b22e)return _0x51b22e[_0x2fb259('0x36')](_0x1baabf)[_0x2fb259('0x22')](function(_0x386d71){return _0x386d71;});return null;};}function removeEntity(_0x3e23ca){return function(_0x2671c6){const _0x324264=a286_0xa751;if(_0x2671c6)return _0x2671c6[_0x324264('0x34')]()['then'](function(){const _0x4290c6=_0x324264;_0x3e23ca[_0x4290c6('0x26')](0xcc)[_0x4290c6('0xf')]();});};}function handleEntityNotFound(_0x14208f){return function(_0x1a0af8){const _0xabba46=a286_0xa751;return!_0x1a0af8&&_0x14208f[_0xabba46('0x28')](0x194),_0x1a0af8;};}function handleError(_0x22fb77,_0x197909){return _0x197909=_0x197909||0x1f4,function(_0x120cf3){const _0x5aeba4=a286_0xa751;logger[_0x5aeba4('0x3')](_0x120cf3[_0x5aeba4('0x7')]),_0x120cf3[_0x5aeba4('0x25')]&&delete _0x120cf3[_0x5aeba4('0x25')],_0x22fb77['status'](_0x197909)['send'](_0x120cf3);};}exports[_0x5761b7('0x1c')]=function(_0x4292f9,_0x42b547){const _0x35d7e9=_0x5761b7;let _0x1daaf8={};const _0x339d0c={},_0x429a65={'count':0x0,'rows':[]},_0x53164d=_[_0x35d7e9('0x1f')](db[_0x35d7e9('0x37')][_0x35d7e9('0x1e')],function(_0x5e5e13){const _0x1f26d5=_0x35d7e9;return{'name':_0x5e5e13[_0x1f26d5('0x30')],'type':_0x5e5e13['type'][_0x1f26d5('0x24')]};});_0x339d0c[_0x35d7e9('0x13')]=_[_0x35d7e9('0x1f')](_0x53164d,_0x35d7e9('0x25')),_0x339d0c[_0x35d7e9('0x2c')]=_['keys'](_0x4292f9['query']),_0x339d0c['filters']=_[_0x35d7e9('0x16')](_0x339d0c[_0x35d7e9('0x13')],_0x339d0c[_0x35d7e9('0x2c')]),_0x1daaf8[_0x35d7e9('0x29')]=_[_0x35d7e9('0x16')](_0x339d0c['model'],qs['fields'](_0x4292f9[_0x35d7e9('0x2c')][_0x35d7e9('0x2a')])),_0x1daaf8[_0x35d7e9('0x29')]=_0x1daaf8[_0x35d7e9('0x29')][_0x35d7e9('0x2')]?_0x1daaf8[_0x35d7e9('0x29')]:_0x339d0c[_0x35d7e9('0x13')];typeof _0x4292f9[_0x35d7e9('0x2c')]['nolimit']===_0x35d7e9('0x4')&&(_0x1daaf8[_0x35d7e9('0x19')]=qs[_0x35d7e9('0x19')](_0x4292f9[_0x35d7e9('0x2c')][_0x35d7e9('0x19')]),_0x1daaf8['offset']=qs['offset'](_0x4292f9[_0x35d7e9('0x2c')]['offset']));_0x1daaf8[_0x35d7e9('0x9')]=qs['sort'](_0x4292f9[_0x35d7e9('0x2c')][_0x35d7e9('0x32')]),_0x1daaf8[_0x35d7e9('0x12')]=qs['filters'](_[_0x35d7e9('0x8')](_0x4292f9[_0x35d7e9('0x2c')],_0x339d0c['filters']),_0x53164d);_0x4292f9[_0x35d7e9('0x2c')]['filter']&&(_0x1daaf8[_0x35d7e9('0x12')]=_[_0x35d7e9('0x23')](_0x1daaf8['where'],{[Op['or']]:_[_0x35d7e9('0x1f')](_0x53164d,function(_0x3c1e97){const _0x304173=_0x35d7e9;if(_0x3c1e97[_0x304173('0x1d')]!==_0x304173('0x15')){const _0x4da118={};return _0x4da118[_0x3c1e97['name']]={[Op[_0x304173('0xd')]]:'%'+_0x4292f9[_0x304173('0x2c')][_0x304173('0x1b')]+'%'},_0x4da118;}})}));_0x1daaf8=_[_0x35d7e9('0x23')]({},_0x1daaf8,_0x4292f9['options']);const _0x3ccb61={'where':_0x1daaf8['where']};return db[_0x35d7e9('0x37')]['count'](_0x3ccb61)['then'](function(_0x401c2e){const _0x23c605=_0x35d7e9;return _0x429a65[_0x23c605('0x6')]=_0x401c2e,_0x4292f9[_0x23c605('0x2c')][_0x23c605('0x31')]&&(_0x1daaf8[_0x23c605('0x35')]=[{'all':!![]}]),db[_0x23c605('0x37')][_0x23c605('0x2d')](_0x1daaf8);})[_0x35d7e9('0x22')](function(_0x12d5a6){return _0x429a65['rows']=_0x12d5a6,_0x429a65;})[_0x35d7e9('0x22')](respondWithFilteredResult(_0x42b547,_0x1daaf8))[_0x35d7e9('0xc')](handleError(_0x42b547,null));},exports[_0x5761b7('0x33')]=function(_0x2b7ecb,_0x34d1d9){const _0x321c71=_0x5761b7;let _0x26b020={'raw':![],'where':{'id':_0x2b7ecb[_0x321c71('0x5')]['id']}};const _0x3042e8={};return _0x3042e8[_0x321c71('0x13')]=_[_0x321c71('0x2f')](db[_0x321c71('0x37')][_0x321c71('0x1e')]),_0x3042e8[_0x321c71('0x2c')]=_[_0x321c71('0x2f')](_0x2b7ecb[_0x321c71('0x2c')]),_0x3042e8[_0x321c71('0x20')]=_[_0x321c71('0x16')](_0x3042e8['model'],_0x3042e8['query']),_0x26b020[_0x321c71('0x29')]=_[_0x321c71('0x16')](_0x3042e8[_0x321c71('0x13')],qs[_0x321c71('0x2a')](_0x2b7ecb[_0x321c71('0x2c')]['fields'])),_0x26b020[_0x321c71('0x29')]=_0x26b020[_0x321c71('0x29')]['length']?_0x26b020[_0x321c71('0x29')]:_0x3042e8[_0x321c71('0x13')],_0x2b7ecb['query'][_0x321c71('0x31')]&&(_0x26b020[_0x321c71('0x35')]=[{'all':!![]}]),_0x26b020=_[_0x321c71('0x23')]({},_0x26b020,_0x2b7ecb[_0x321c71('0x0')]),db['SalesforceConfiguration'][_0x321c71('0x27')](_0x26b020)[_0x321c71('0x22')](handleEntityNotFound(_0x34d1d9,null))[_0x321c71('0x22')](respondWithResult(_0x34d1d9,null))[_0x321c71('0xc')](handleError(_0x34d1d9,null));},exports[_0x5761b7('0x14')]=function(_0x5084ab,_0x887f6e){const _0x17a108=_0x5761b7;return db[_0x17a108('0x37')][_0x17a108('0x14')](_0x5084ab[_0x17a108('0x1')],{})[_0x17a108('0x22')](respondWithResult(_0x887f6e,0xc9))['catch'](handleError(_0x887f6e,null));},exports[_0x5761b7('0x36')]=function(_0x58254a,_0x1d7444){const _0x42c885=_0x5761b7;return _0x58254a[_0x42c885('0x1')]['id']&&delete _0x58254a[_0x42c885('0x1')]['id'],db['SalesforceConfiguration'][_0x42c885('0x27')]({'where':{'id':_0x58254a[_0x42c885('0x5')]['id']}})[_0x42c885('0x22')](handleEntityNotFound(_0x1d7444,null))[_0x42c885('0x22')](saveUpdates(_0x58254a[_0x42c885('0x1')],null))[_0x42c885('0x22')](respondWithResult(_0x1d7444,null))['catch'](handleError(_0x1d7444,null));},exports['destroy']=function(_0x1ac2a1,_0x58079f){const _0x34db20=_0x5761b7;return db[_0x34db20('0x37')]['findOne']({'where':{'id':_0x1ac2a1[_0x34db20('0x5')]['id']}})['then'](handleEntityNotFound(_0x58079f,null))['then'](removeEntity(_0x58079f,null))['catch'](handleError(_0x58079f,null));},exports[_0x5761b7('0x2e')]=function(_0x304fd7,_0xb51fbb){const _0x1efedc=_0x5761b7;let _0x276c8c={};const _0x1f1e29={};let _0x3963b5,_0x228723;return db[_0x1efedc('0x37')][_0x1efedc('0x27')]({'where':{'id':_0x304fd7[_0x1efedc('0x5')]['id']}})[_0x1efedc('0x22')](handleEntityNotFound(_0xb51fbb,null))[_0x1efedc('0x22')](function(_0x1c65a3){const _0x38b842=_0x1efedc;if(_0x1c65a3)return _0x3963b5=_0x1c65a3,_0x1f1e29[_0x38b842('0x13')]=_[_0x38b842('0x2f')](db[_0x38b842('0x10')][_0x38b842('0x1e')]),_0x1f1e29[_0x38b842('0x2c')]=_[_0x38b842('0x2f')](_0x304fd7[_0x38b842('0x2c')]),_0x1f1e29['filters']=_[_0x38b842('0x16')](_0x1f1e29[_0x38b842('0x13')],_0x1f1e29[_0x38b842('0x2c')]),_0x276c8c['attributes']=_['intersection'](_0x1f1e29[_0x38b842('0x13')],qs[_0x38b842('0x2a')](_0x304fd7['query'][_0x38b842('0x2a')])),_0x276c8c[_0x38b842('0x29')]=_0x276c8c[_0x38b842('0x29')]['length']?_0x276c8c[_0x38b842('0x29')]:_0x1f1e29[_0x38b842('0x13')],_0x276c8c[_0x38b842('0x9')]=qs['sort'](_0x304fd7[_0x38b842('0x2c')][_0x38b842('0x32')]),_0x276c8c['where']=qs['filters'](_[_0x38b842('0x8')](_0x304fd7[_0x38b842('0x2c')],_0x1f1e29[_0x38b842('0x20')])),_0x304fd7[_0x38b842('0x2c')]['filter']&&(_0x276c8c[_0x38b842('0x12')]=_[_0x38b842('0x23')](_0x276c8c[_0x38b842('0x12')],{[Op['or']]:_[_0x38b842('0x1f')](_0x276c8c[_0x38b842('0x29')],function(_0x2b4368){const _0xb6d8c5=_0x38b842,_0x3a2fed={};return _0x3a2fed[_0x2b4368]={[Op[_0xb6d8c5('0xd')]]:'%'+_0x304fd7['query'][_0xb6d8c5('0x1b')]+'%'},_0x3a2fed;})})),_0x276c8c=_[_0x38b842('0x23')]({},_0x276c8c,_0x304fd7[_0x38b842('0x0')]),_0x3963b5[_0x38b842('0x2e')](_0x276c8c);})['then'](function(_0x3bc2f5){const _0x3e6bd9=_0x1efedc;if(_0x3bc2f5)return _0x228723=_0x3bc2f5[_0x3e6bd9('0x2')],typeof _0x304fd7['query'][_0x3e6bd9('0x1a')]==='undefined'&&(_0x276c8c[_0x3e6bd9('0x19')]=qs[_0x3e6bd9('0x19')](_0x304fd7[_0x3e6bd9('0x2c')][_0x3e6bd9('0x19')]),_0x276c8c[_0x3e6bd9('0x17')]=qs[_0x3e6bd9('0x17')](_0x304fd7['query'][_0x3e6bd9('0x17')])),_0x3963b5[_0x3e6bd9('0x2e')](_0x276c8c);})[_0x1efedc('0x22')](function(_0x24f101){if(_0x24f101)return _0x24f101?{'count':_0x228723,'rows':_0x24f101}:null;})[_0x1efedc('0x22')](respondWithResult(_0xb51fbb,null))['catch'](handleError(_0xb51fbb,null));},exports['getSubjects']=function(_0xc628d9,_0x1f9f19){const _0x1383a5=_0x5761b7;let _0x214a4a={};const _0x4fcda0={};let _0x2c016a,_0x5ab14b;return db[_0x1383a5('0x37')][_0x1383a5('0x27')]({'where':{'id':_0xc628d9[_0x1383a5('0x5')]['id']}})[_0x1383a5('0x22')](handleEntityNotFound(_0x1f9f19,null))[_0x1383a5('0x22')](function(_0x2d1edc){const _0x337b56=_0x1383a5;if(_0x2d1edc)return _0x2c016a=_0x2d1edc,_0x4fcda0['model']=_['keys'](db[_0x337b56('0x10')][_0x337b56('0x1e')]),_0x4fcda0[_0x337b56('0x2c')]=_[_0x337b56('0x2f')](_0xc628d9['query']),_0x4fcda0['filters']=_[_0x337b56('0x16')](_0x4fcda0[_0x337b56('0x13')],_0x4fcda0['query']),_0x214a4a['attributes']=_[_0x337b56('0x16')](_0x4fcda0[_0x337b56('0x13')],qs[_0x337b56('0x2a')](_0xc628d9[_0x337b56('0x2c')][_0x337b56('0x2a')])),_0x214a4a[_0x337b56('0x29')]=_0x214a4a[_0x337b56('0x29')][_0x337b56('0x2')]?_0x214a4a['attributes']:_0x4fcda0[_0x337b56('0x13')],_0x214a4a['order']=qs['sort'](_0xc628d9['query']['sort']),_0x214a4a['where']=qs[_0x337b56('0x20')](_['pick'](_0xc628d9['query'],_0x4fcda0[_0x337b56('0x20')])),_0xc628d9[_0x337b56('0x2c')]['filter']&&(_0x214a4a[_0x337b56('0x12')]=_[_0x337b56('0x23')](_0x214a4a[_0x337b56('0x12')],{[Op['or']]:_['map'](_0x214a4a[_0x337b56('0x29')],function(_0x1d3085){const _0x42d22e=_0x337b56,_0x3de6bd={};return _0x3de6bd[_0x1d3085]={[Op[_0x42d22e('0xd')]]:'%'+_0xc628d9[_0x42d22e('0x2c')]['filter']+'%'},_0x3de6bd;})})),_0x214a4a=_['merge']({},_0x214a4a,_0xc628d9[_0x337b56('0x0')]),_0x2c016a[_0x337b56('0xa')](_0x214a4a);})[_0x1383a5('0x22')](function(_0x56156b){const _0x28405b=_0x1383a5;if(_0x56156b)return _0x5ab14b=_0x56156b[_0x28405b('0x2')],typeof _0xc628d9['query']['nolimit']===_0x28405b('0x4')&&(_0x214a4a[_0x28405b('0x19')]=qs[_0x28405b('0x19')](_0xc628d9['query'][_0x28405b('0x19')]),_0x214a4a[_0x28405b('0x17')]=qs[_0x28405b('0x17')](_0xc628d9[_0x28405b('0x2c')]['offset'])),_0x2c016a[_0x28405b('0xa')](_0x214a4a);})[_0x1383a5('0x22')](function(_0x3520d1){if(_0x3520d1)return _0x3520d1?{'count':_0x5ab14b,'rows':_0x3520d1}:null;})[_0x1383a5('0x22')](respondWithResult(_0x1f9f19,null))['catch'](handleError(_0x1f9f19,null));},exports[_0x5761b7('0x2b')]=function(_0x2b9c0e,_0x2766b6){const _0x8425f9=_0x5761b7;let _0x4dc601={};const _0x12089e={};let _0x12421d,_0x588e29;return db[_0x8425f9('0x37')][_0x8425f9('0x27')]({'where':{'id':_0x2b9c0e[_0x8425f9('0x5')]['id']}})[_0x8425f9('0x22')](handleEntityNotFound(_0x2766b6,null))[_0x8425f9('0x22')](function(_0x1e6495){const _0x1291e5=_0x8425f9;if(_0x1e6495)return _0x12421d=_0x1e6495,_0x12089e[_0x1291e5('0x13')]=_[_0x1291e5('0x2f')](db[_0x1291e5('0x10')][_0x1291e5('0x1e')]),_0x12089e[_0x1291e5('0x2c')]=_[_0x1291e5('0x2f')](_0x2b9c0e[_0x1291e5('0x2c')]),_0x12089e['filters']=_['intersection'](_0x12089e[_0x1291e5('0x13')],_0x12089e[_0x1291e5('0x2c')]),_0x4dc601['attributes']=_[_0x1291e5('0x16')](_0x12089e[_0x1291e5('0x13')],qs[_0x1291e5('0x2a')](_0x2b9c0e[_0x1291e5('0x2c')]['fields'])),_0x4dc601[_0x1291e5('0x29')]=_0x4dc601[_0x1291e5('0x29')][_0x1291e5('0x2')]?_0x4dc601[_0x1291e5('0x29')]:_0x12089e[_0x1291e5('0x13')],_0x4dc601[_0x1291e5('0x9')]=qs['sort'](_0x2b9c0e[_0x1291e5('0x2c')]['sort']),_0x4dc601[_0x1291e5('0x12')]=qs[_0x1291e5('0x20')](_[_0x1291e5('0x8')](_0x2b9c0e['query'],_0x12089e[_0x1291e5('0x20')])),_0x2b9c0e[_0x1291e5('0x2c')][_0x1291e5('0x1b')]&&(_0x4dc601[_0x1291e5('0x12')]=_[_0x1291e5('0x23')](_0x4dc601[_0x1291e5('0x12')],{[Op['or']]:_[_0x1291e5('0x1f')](_0x4dc601[_0x1291e5('0x29')],function(_0x4feb03){const _0x1cef21=_0x1291e5,_0x1825a8={};return _0x1825a8[_0x4feb03]={[Op[_0x1cef21('0xd')]]:'%'+_0x2b9c0e[_0x1cef21('0x2c')][_0x1cef21('0x1b')]+'%'},_0x1825a8;})})),_0x4dc601=_[_0x1291e5('0x23')]({},_0x4dc601,_0x2b9c0e['options']),_0x12421d['getDescriptions'](_0x4dc601);})[_0x8425f9('0x22')](function(_0x4b723d){const _0x39bdf3=_0x8425f9;if(_0x4b723d)return _0x588e29=_0x4b723d[_0x39bdf3('0x2')],typeof _0x2b9c0e[_0x39bdf3('0x2c')][_0x39bdf3('0x1a')]===_0x39bdf3('0x4')&&(_0x4dc601[_0x39bdf3('0x19')]=qs['limit'](_0x2b9c0e[_0x39bdf3('0x2c')][_0x39bdf3('0x19')]),_0x4dc601[_0x39bdf3('0x17')]=qs[_0x39bdf3('0x17')](_0x2b9c0e[_0x39bdf3('0x2c')][_0x39bdf3('0x17')])),_0x12421d[_0x39bdf3('0x2b')](_0x4dc601);})['then'](function(_0x227ccc){if(_0x227ccc)return _0x227ccc?{'count':_0x588e29,'rows':_0x227ccc}:null;})[_0x8425f9('0x22')](respondWithResult(_0x2766b6,null))[_0x8425f9('0xc')](handleError(_0x2766b6,null));}; \ No newline at end of file +const a286_0x4d8d=['getSubjects','send','attributes','lodash','catch','../../mysqldb','sort','error','offset','length','rows','query','where','sequelize','keys','filters','pick','getDescriptions','Content-Range','type','body','map','findOne','includeAll','undefined','fields','SalesforceConfiguration','merge','json','nolimit','api','limit','findAll','count','end','sendStatus','index','filter','options','params','intersection','key','fieldName','status','then','order','update','getFields','create','VIRTUAL','destroy','name','model','like','show','include','../../components/parsers/qs','SalesforceField','rawAttributes'];(function(_0x28fedc,_0x4d8d7c){const _0x1cf82e=function(_0x5a2c57){while(--_0x5a2c57){_0x28fedc['push'](_0x28fedc['shift']());}};_0x1cf82e(++_0x4d8d7c);}(a286_0x4d8d,0xb5));const a286_0x1cf8=function(_0x28fedc,_0x4d8d7c){_0x28fedc=_0x28fedc-0x0;let _0x1cf82e=a286_0x4d8d[_0x28fedc];return _0x1cf82e;};const _0x394dbe=a286_0x1cf8;'use strict';const _=require(_0x394dbe('0x3a')),qs=require(_0x394dbe('0x34')),logger=require('../../config/logger')(_0x394dbe('0x1a')),db=require(_0x394dbe('0x1'))['db'],{Op}=require(_0x394dbe('0x9'));function respondWithResult(_0x5a2c57,_0x377b6a){return _0x377b6a=_0x377b6a||0xc8,function(_0x244c51){const _0x5ac982=a286_0x1cf8;if(_0x244c51)return _0x5a2c57[_0x5ac982('0x27')](_0x377b6a)[_0x5ac982('0x18')](_0x244c51);};}function respondWithFilteredResult(_0x30c266,_0x332b01){return function(_0x1bcd95){const _0x59db2c=a286_0x1cf8;if(_0x1bcd95){const _0x188f84=_0x1bcd95[_0x59db2c('0x1d')],_0x25a5e3=_0x332b01['offset'];let _0x38783f=_0x332b01['offset']+_0x332b01[_0x59db2c('0x1b')],_0x463cbe;return _0x38783f>=_0x188f84?(_0x38783f=_0x188f84,_0x463cbe=0xc8):_0x463cbe=0xce,_0x30c266[_0x59db2c('0x27')](_0x463cbe),_0x30c266['set'](_0x59db2c('0xe'),_0x25a5e3+'-'+_0x38783f+'/'+_0x188f84)[_0x59db2c('0x18')](_0x1bcd95);}return null;};}function saveUpdates(_0x59277b){return function(_0x1b3406){const _0x3c9c29=a286_0x1cf8;if(_0x1b3406)return _0x1b3406[_0x3c9c29('0x2a')](_0x59277b)['then'](function(_0x7bc76){return _0x7bc76;});return null;};}function removeEntity(_0x3312ec){return function(_0x3b26f4){const _0x547187=a286_0x1cf8;if(_0x3b26f4)return _0x3b26f4[_0x547187('0x2e')]()[_0x547187('0x28')](function(){const _0x5f5614=_0x547187;_0x3312ec[_0x5f5614('0x27')](0xcc)[_0x5f5614('0x1e')]();});};}function handleEntityNotFound(_0x2f68c4){return function(_0x3fc7fb){const _0x39aa36=a286_0x1cf8;return!_0x3fc7fb&&_0x2f68c4[_0x39aa36('0x1f')](0x194),_0x3fc7fb;};}function handleError(_0x54293c,_0x30a564){return _0x30a564=_0x30a564||0x1f4,function(_0x58dc17){const _0x1822d2=a286_0x1cf8;logger[_0x1822d2('0x3')](_0x58dc17['stack']),_0x58dc17[_0x1822d2('0x2f')]&&delete _0x58dc17[_0x1822d2('0x2f')],_0x54293c['status'](_0x30a564)[_0x1822d2('0x38')](_0x58dc17);};}exports[_0x394dbe('0x20')]=function(_0x101679,_0x53ccca){const _0x5ee330=_0x394dbe;let _0x10dc3d={};const _0x13d4ed={},_0x393c1a={'count':0x0,'rows':[]},_0x36838a=_[_0x5ee330('0x11')](db[_0x5ee330('0x16')]['rawAttributes'],function(_0x1feda4){const _0x29a628=_0x5ee330;return{'name':_0x1feda4[_0x29a628('0x26')],'type':_0x1feda4[_0x29a628('0xf')][_0x29a628('0x25')]};});_0x13d4ed[_0x5ee330('0x30')]=_[_0x5ee330('0x11')](_0x36838a,_0x5ee330('0x2f')),_0x13d4ed[_0x5ee330('0x7')]=_[_0x5ee330('0xa')](_0x101679[_0x5ee330('0x7')]),_0x13d4ed[_0x5ee330('0xb')]=_['intersection'](_0x13d4ed[_0x5ee330('0x30')],_0x13d4ed[_0x5ee330('0x7')]),_0x10dc3d['attributes']=_[_0x5ee330('0x24')](_0x13d4ed['model'],qs['fields'](_0x101679[_0x5ee330('0x7')][_0x5ee330('0x15')])),_0x10dc3d[_0x5ee330('0x39')]=_0x10dc3d[_0x5ee330('0x39')][_0x5ee330('0x5')]?_0x10dc3d[_0x5ee330('0x39')]:_0x13d4ed['model'];typeof _0x101679[_0x5ee330('0x7')]['nolimit']===_0x5ee330('0x14')&&(_0x10dc3d['limit']=qs[_0x5ee330('0x1b')](_0x101679[_0x5ee330('0x7')][_0x5ee330('0x1b')]),_0x10dc3d[_0x5ee330('0x4')]=qs[_0x5ee330('0x4')](_0x101679[_0x5ee330('0x7')][_0x5ee330('0x4')]));_0x10dc3d['order']=qs[_0x5ee330('0x2')](_0x101679[_0x5ee330('0x7')][_0x5ee330('0x2')]),_0x10dc3d[_0x5ee330('0x8')]=qs[_0x5ee330('0xb')](_[_0x5ee330('0xc')](_0x101679[_0x5ee330('0x7')],_0x13d4ed['filters']),_0x36838a);_0x101679['query'][_0x5ee330('0x21')]&&(_0x10dc3d[_0x5ee330('0x8')]=_[_0x5ee330('0x17')](_0x10dc3d[_0x5ee330('0x8')],{[Op['or']]:_['map'](_0x36838a,function(_0x36519f){const _0x5a3b21=_0x5ee330;if(_0x36519f['type']!==_0x5a3b21('0x2d')){const _0x5d8ad7={};return _0x5d8ad7[_0x36519f[_0x5a3b21('0x2f')]]={[Op[_0x5a3b21('0x31')]]:'%'+_0x101679[_0x5a3b21('0x7')][_0x5a3b21('0x21')]+'%'},_0x5d8ad7;}})}));_0x10dc3d=_['merge']({},_0x10dc3d,_0x101679[_0x5ee330('0x22')]);const _0x1d2f2f={'where':_0x10dc3d[_0x5ee330('0x8')]};return db[_0x5ee330('0x16')][_0x5ee330('0x1d')](_0x1d2f2f)['then'](function(_0x3165c2){const _0x55aed8=_0x5ee330;return _0x393c1a['count']=_0x3165c2,_0x101679['query'][_0x55aed8('0x13')]&&(_0x10dc3d[_0x55aed8('0x33')]=[{'all':!![]}]),db['SalesforceConfiguration'][_0x55aed8('0x1c')](_0x10dc3d);})['then'](function(_0x58b336){const _0x46d683=_0x5ee330;return _0x393c1a[_0x46d683('0x6')]=_0x58b336,_0x393c1a;})[_0x5ee330('0x28')](respondWithFilteredResult(_0x53ccca,_0x10dc3d))[_0x5ee330('0x0')](handleError(_0x53ccca,null));},exports[_0x394dbe('0x32')]=function(_0x41a713,_0x3276f0){const _0x2af95b=_0x394dbe;let _0x354b60={'raw':![],'where':{'id':_0x41a713[_0x2af95b('0x23')]['id']}};const _0x46e4e1={};return _0x46e4e1[_0x2af95b('0x30')]=_[_0x2af95b('0xa')](db[_0x2af95b('0x16')][_0x2af95b('0x36')]),_0x46e4e1[_0x2af95b('0x7')]=_['keys'](_0x41a713[_0x2af95b('0x7')]),_0x46e4e1[_0x2af95b('0xb')]=_[_0x2af95b('0x24')](_0x46e4e1[_0x2af95b('0x30')],_0x46e4e1[_0x2af95b('0x7')]),_0x354b60[_0x2af95b('0x39')]=_[_0x2af95b('0x24')](_0x46e4e1['model'],qs['fields'](_0x41a713['query'][_0x2af95b('0x15')])),_0x354b60[_0x2af95b('0x39')]=_0x354b60[_0x2af95b('0x39')][_0x2af95b('0x5')]?_0x354b60['attributes']:_0x46e4e1[_0x2af95b('0x30')],_0x41a713[_0x2af95b('0x7')][_0x2af95b('0x13')]&&(_0x354b60[_0x2af95b('0x33')]=[{'all':!![]}]),_0x354b60=_['merge']({},_0x354b60,_0x41a713['options']),db[_0x2af95b('0x16')]['findOne'](_0x354b60)[_0x2af95b('0x28')](handleEntityNotFound(_0x3276f0,null))[_0x2af95b('0x28')](respondWithResult(_0x3276f0,null))['catch'](handleError(_0x3276f0,null));},exports[_0x394dbe('0x2c')]=function(_0x12f58b,_0x45765e){const _0x248cfa=_0x394dbe;return db[_0x248cfa('0x16')][_0x248cfa('0x2c')](_0x12f58b[_0x248cfa('0x10')],{})['then'](respondWithResult(_0x45765e,0xc9))[_0x248cfa('0x0')](handleError(_0x45765e,null));},exports['update']=function(_0x462ebb,_0x52ebe0){const _0x2bc30e=_0x394dbe;return _0x462ebb[_0x2bc30e('0x10')]['id']&&delete _0x462ebb[_0x2bc30e('0x10')]['id'],db[_0x2bc30e('0x16')][_0x2bc30e('0x12')]({'where':{'id':_0x462ebb['params']['id']}})[_0x2bc30e('0x28')](handleEntityNotFound(_0x52ebe0,null))[_0x2bc30e('0x28')](saveUpdates(_0x462ebb[_0x2bc30e('0x10')],null))[_0x2bc30e('0x28')](respondWithResult(_0x52ebe0,null))[_0x2bc30e('0x0')](handleError(_0x52ebe0,null));},exports['destroy']=function(_0x1fe91e,_0x45d4a7){const _0x2adbac=_0x394dbe;return db[_0x2adbac('0x16')][_0x2adbac('0x12')]({'where':{'id':_0x1fe91e[_0x2adbac('0x23')]['id']}})[_0x2adbac('0x28')](handleEntityNotFound(_0x45d4a7,null))[_0x2adbac('0x28')](removeEntity(_0x45d4a7,null))['catch'](handleError(_0x45d4a7,null));},exports[_0x394dbe('0x2b')]=function(_0x2cabad,_0x28bd8f){const _0x1e2a61=_0x394dbe;let _0x218eb6={};const _0x2a246c={};let _0xbd54a4,_0x13c2ff;return db[_0x1e2a61('0x16')][_0x1e2a61('0x12')]({'where':{'id':_0x2cabad[_0x1e2a61('0x23')]['id']}})[_0x1e2a61('0x28')](handleEntityNotFound(_0x28bd8f,null))['then'](function(_0x51cf6c){const _0x902df2=_0x1e2a61;if(_0x51cf6c)return _0xbd54a4=_0x51cf6c,_0x2a246c[_0x902df2('0x30')]=_[_0x902df2('0xa')](db[_0x902df2('0x35')]['rawAttributes']),_0x2a246c['query']=_[_0x902df2('0xa')](_0x2cabad[_0x902df2('0x7')]),_0x2a246c['filters']=_[_0x902df2('0x24')](_0x2a246c['model'],_0x2a246c[_0x902df2('0x7')]),_0x218eb6[_0x902df2('0x39')]=_[_0x902df2('0x24')](_0x2a246c[_0x902df2('0x30')],qs['fields'](_0x2cabad[_0x902df2('0x7')][_0x902df2('0x15')])),_0x218eb6[_0x902df2('0x39')]=_0x218eb6[_0x902df2('0x39')][_0x902df2('0x5')]?_0x218eb6[_0x902df2('0x39')]:_0x2a246c[_0x902df2('0x30')],_0x218eb6[_0x902df2('0x29')]=qs[_0x902df2('0x2')](_0x2cabad[_0x902df2('0x7')][_0x902df2('0x2')]),_0x218eb6[_0x902df2('0x8')]=qs[_0x902df2('0xb')](_[_0x902df2('0xc')](_0x2cabad[_0x902df2('0x7')],_0x2a246c[_0x902df2('0xb')])),_0x2cabad[_0x902df2('0x7')]['filter']&&(_0x218eb6[_0x902df2('0x8')]=_['merge'](_0x218eb6[_0x902df2('0x8')],{[Op['or']]:_[_0x902df2('0x11')](_0x218eb6[_0x902df2('0x39')],function(_0x1e7637){const _0x35ff38=_0x902df2,_0x2587b5={};return _0x2587b5[_0x1e7637]={[Op[_0x35ff38('0x31')]]:'%'+_0x2cabad[_0x35ff38('0x7')][_0x35ff38('0x21')]+'%'},_0x2587b5;})})),_0x218eb6=_['merge']({},_0x218eb6,_0x2cabad[_0x902df2('0x22')]),_0xbd54a4[_0x902df2('0x2b')](_0x218eb6);})[_0x1e2a61('0x28')](function(_0x3e6d65){const _0x3321b0=_0x1e2a61;if(_0x3e6d65)return _0x13c2ff=_0x3e6d65[_0x3321b0('0x5')],typeof _0x2cabad[_0x3321b0('0x7')][_0x3321b0('0x19')]===_0x3321b0('0x14')&&(_0x218eb6[_0x3321b0('0x1b')]=qs['limit'](_0x2cabad[_0x3321b0('0x7')][_0x3321b0('0x1b')]),_0x218eb6[_0x3321b0('0x4')]=qs[_0x3321b0('0x4')](_0x2cabad[_0x3321b0('0x7')][_0x3321b0('0x4')])),_0xbd54a4[_0x3321b0('0x2b')](_0x218eb6);})[_0x1e2a61('0x28')](function(_0x10e1e4){if(_0x10e1e4)return _0x10e1e4?{'count':_0x13c2ff,'rows':_0x10e1e4}:null;})[_0x1e2a61('0x28')](respondWithResult(_0x28bd8f,null))[_0x1e2a61('0x0')](handleError(_0x28bd8f,null));},exports[_0x394dbe('0x37')]=function(_0x4a2e9b,_0x2e6232){const _0xd936ce=_0x394dbe;let _0x2b162d={};const _0x181dd8={};let _0x377736,_0x2b98d8;return db[_0xd936ce('0x16')][_0xd936ce('0x12')]({'where':{'id':_0x4a2e9b['params']['id']}})[_0xd936ce('0x28')](handleEntityNotFound(_0x2e6232,null))['then'](function(_0x5408a0){const _0x5e9ac9=_0xd936ce;if(_0x5408a0)return _0x377736=_0x5408a0,_0x181dd8['model']=_[_0x5e9ac9('0xa')](db[_0x5e9ac9('0x35')][_0x5e9ac9('0x36')]),_0x181dd8[_0x5e9ac9('0x7')]=_[_0x5e9ac9('0xa')](_0x4a2e9b[_0x5e9ac9('0x7')]),_0x181dd8['filters']=_[_0x5e9ac9('0x24')](_0x181dd8[_0x5e9ac9('0x30')],_0x181dd8[_0x5e9ac9('0x7')]),_0x2b162d[_0x5e9ac9('0x39')]=_[_0x5e9ac9('0x24')](_0x181dd8[_0x5e9ac9('0x30')],qs[_0x5e9ac9('0x15')](_0x4a2e9b['query'][_0x5e9ac9('0x15')])),_0x2b162d[_0x5e9ac9('0x39')]=_0x2b162d[_0x5e9ac9('0x39')][_0x5e9ac9('0x5')]?_0x2b162d[_0x5e9ac9('0x39')]:_0x181dd8['model'],_0x2b162d[_0x5e9ac9('0x29')]=qs[_0x5e9ac9('0x2')](_0x4a2e9b['query'][_0x5e9ac9('0x2')]),_0x2b162d['where']=qs['filters'](_[_0x5e9ac9('0xc')](_0x4a2e9b['query'],_0x181dd8[_0x5e9ac9('0xb')])),_0x4a2e9b[_0x5e9ac9('0x7')][_0x5e9ac9('0x21')]&&(_0x2b162d[_0x5e9ac9('0x8')]=_[_0x5e9ac9('0x17')](_0x2b162d[_0x5e9ac9('0x8')],{[Op['or']]:_[_0x5e9ac9('0x11')](_0x2b162d['attributes'],function(_0x165c33){const _0x5817d8=_0x5e9ac9,_0x2d5f3b={};return _0x2d5f3b[_0x165c33]={[Op[_0x5817d8('0x31')]]:'%'+_0x4a2e9b[_0x5817d8('0x7')][_0x5817d8('0x21')]+'%'},_0x2d5f3b;})})),_0x2b162d=_[_0x5e9ac9('0x17')]({},_0x2b162d,_0x4a2e9b[_0x5e9ac9('0x22')]),_0x377736[_0x5e9ac9('0x37')](_0x2b162d);})[_0xd936ce('0x28')](function(_0x1bde6d){const _0x4ab80e=_0xd936ce;if(_0x1bde6d)return _0x2b98d8=_0x1bde6d[_0x4ab80e('0x5')],typeof _0x4a2e9b['query']['nolimit']===_0x4ab80e('0x14')&&(_0x2b162d[_0x4ab80e('0x1b')]=qs[_0x4ab80e('0x1b')](_0x4a2e9b['query'][_0x4ab80e('0x1b')]),_0x2b162d[_0x4ab80e('0x4')]=qs[_0x4ab80e('0x4')](_0x4a2e9b[_0x4ab80e('0x7')][_0x4ab80e('0x4')])),_0x377736[_0x4ab80e('0x37')](_0x2b162d);})[_0xd936ce('0x28')](function(_0x218b44){if(_0x218b44)return _0x218b44?{'count':_0x2b98d8,'rows':_0x218b44}:null;})[_0xd936ce('0x28')](respondWithResult(_0x2e6232,null))['catch'](handleError(_0x2e6232,null));},exports[_0x394dbe('0xd')]=function(_0x31fcd0,_0x40e204){const _0x187240=_0x394dbe;let _0xfd970f={};const _0x3dbe9c={};let _0x334554,_0x219b61;return db[_0x187240('0x16')][_0x187240('0x12')]({'where':{'id':_0x31fcd0[_0x187240('0x23')]['id']}})[_0x187240('0x28')](handleEntityNotFound(_0x40e204,null))['then'](function(_0x4c5ba6){const _0x3877ae=_0x187240;if(_0x4c5ba6)return _0x334554=_0x4c5ba6,_0x3dbe9c[_0x3877ae('0x30')]=_[_0x3877ae('0xa')](db[_0x3877ae('0x35')][_0x3877ae('0x36')]),_0x3dbe9c[_0x3877ae('0x7')]=_[_0x3877ae('0xa')](_0x31fcd0[_0x3877ae('0x7')]),_0x3dbe9c[_0x3877ae('0xb')]=_[_0x3877ae('0x24')](_0x3dbe9c['model'],_0x3dbe9c['query']),_0xfd970f[_0x3877ae('0x39')]=_[_0x3877ae('0x24')](_0x3dbe9c[_0x3877ae('0x30')],qs['fields'](_0x31fcd0['query'][_0x3877ae('0x15')])),_0xfd970f[_0x3877ae('0x39')]=_0xfd970f['attributes'][_0x3877ae('0x5')]?_0xfd970f[_0x3877ae('0x39')]:_0x3dbe9c[_0x3877ae('0x30')],_0xfd970f[_0x3877ae('0x29')]=qs[_0x3877ae('0x2')](_0x31fcd0[_0x3877ae('0x7')][_0x3877ae('0x2')]),_0xfd970f[_0x3877ae('0x8')]=qs[_0x3877ae('0xb')](_[_0x3877ae('0xc')](_0x31fcd0['query'],_0x3dbe9c[_0x3877ae('0xb')])),_0x31fcd0[_0x3877ae('0x7')]['filter']&&(_0xfd970f[_0x3877ae('0x8')]=_[_0x3877ae('0x17')](_0xfd970f[_0x3877ae('0x8')],{[Op['or']]:_[_0x3877ae('0x11')](_0xfd970f[_0x3877ae('0x39')],function(_0x284590){const _0x3e9bb7=_0x3877ae,_0x4ba4d8={};return _0x4ba4d8[_0x284590]={[Op['like']]:'%'+_0x31fcd0[_0x3e9bb7('0x7')][_0x3e9bb7('0x21')]+'%'},_0x4ba4d8;})})),_0xfd970f=_['merge']({},_0xfd970f,_0x31fcd0[_0x3877ae('0x22')]),_0x334554[_0x3877ae('0xd')](_0xfd970f);})['then'](function(_0x4022d8){const _0x1af11a=_0x187240;if(_0x4022d8)return _0x219b61=_0x4022d8[_0x1af11a('0x5')],typeof _0x31fcd0[_0x1af11a('0x7')][_0x1af11a('0x19')]===_0x1af11a('0x14')&&(_0xfd970f[_0x1af11a('0x1b')]=qs[_0x1af11a('0x1b')](_0x31fcd0[_0x1af11a('0x7')][_0x1af11a('0x1b')]),_0xfd970f[_0x1af11a('0x4')]=qs[_0x1af11a('0x4')](_0x31fcd0['query'][_0x1af11a('0x4')])),_0x334554[_0x1af11a('0xd')](_0xfd970f);})['then'](function(_0x599f25){if(_0x599f25)return _0x599f25?{'count':_0x219b61,'rows':_0x599f25}:null;})[_0x187240('0x28')](respondWithResult(_0x40e204,null))[_0x187240('0x0')](handleError(_0x40e204,null));}; \ No newline at end of file diff --git a/server/api/intSalesforceConfiguration/intSalesforceConfiguration.model.js b/server/api/intSalesforceConfiguration/intSalesforceConfiguration.model.js index 7c6f2f6..e01e60d 100644 --- a/server/api/intSalesforceConfiguration/intSalesforceConfiguration.model.js +++ b/server/api/intSalesforceConfiguration/intSalesforceConfiguration.model.js @@ -1 +1 @@ -const a287_0x4ffc=['exports','define','int_salesforce_configurations'];(function(_0x3ea6ad,_0x4ffcfd){const _0x35fd67=function(_0x233a28){while(--_0x233a28){_0x3ea6ad['push'](_0x3ea6ad['shift']());}};_0x35fd67(++_0x4ffcfd);}(a287_0x4ffc,0x68));const a287_0x35fd=function(_0x3ea6ad,_0x4ffcfd){_0x3ea6ad=_0x3ea6ad-0x0;let _0x35fd67=a287_0x4ffc[_0x3ea6ad];return _0x35fd67;};const _0x292b6c=a287_0x35fd;'use strict';const attributes=require('./intSalesforceConfiguration.attributes');module[_0x292b6c('0x1')]=function(_0x233a28){const _0x2d732f=_0x292b6c,_0x31db5a=_0x233a28[_0x2d732f('0x2')]('SalesforceConfiguration',attributes,{'tableName':_0x2d732f('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x31db5a;}; \ No newline at end of file +const a287_0x4e21=['exports','SalesforceConfiguration','define','./intSalesforceConfiguration.attributes','int_salesforce_configurations'];(function(_0x5b4808,_0x4e2198){const _0x2bafd9=function(_0x4eb5b4){while(--_0x4eb5b4){_0x5b4808['push'](_0x5b4808['shift']());}};_0x2bafd9(++_0x4e2198);}(a287_0x4e21,0x1d0));const a287_0x2baf=function(_0x5b4808,_0x4e2198){_0x5b4808=_0x5b4808-0x0;let _0x2bafd9=a287_0x4e21[_0x5b4808];return _0x2bafd9;};const _0x58dff1=a287_0x2baf;'use strict';const attributes=require(_0x58dff1('0x4'));module[_0x58dff1('0x1')]=function(_0x4eb5b4){const _0x1d6e8c=_0x58dff1,_0xeaa78f=_0x4eb5b4[_0x1d6e8c('0x3')](_0x1d6e8c('0x2'),attributes,{'tableName':_0x1d6e8c('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xeaa78f;}; \ No newline at end of file diff --git a/server/api/intSalesforceField/index.js b/server/api/intSalesforceField/index.js index 254d563..9f68ced 100644 --- a/server/api/intSalesforceField/index.js +++ b/server/api/intSalesforceField/index.js @@ -1 +1 @@ -const a288_0x557d=['isAuthenticated','show','exports','update','delete','express','/:id','./intSalesforceField.controller','destroy','put','create','get','post'];(function(_0x325e38,_0x557d64){const _0x24fc02=function(_0x26807d){while(--_0x26807d){_0x325e38['push'](_0x325e38['shift']());}};_0x24fc02(++_0x557d64);}(a288_0x557d,0x13b));const a288_0x24fc=function(_0x325e38,_0x557d64){_0x325e38=_0x325e38-0x0;let _0x24fc02=a288_0x557d[_0x325e38];return _0x24fc02;};const _0x40ddcd=a288_0x24fc;'use strict';const express=require(_0x40ddcd('0x2')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x40ddcd('0x4'));router[_0x40ddcd('0x8')]('/',auth[_0x40ddcd('0xa')](),controller['index']),router[_0x40ddcd('0x8')]('/:id',auth[_0x40ddcd('0xa')](),controller[_0x40ddcd('0xb')]),router[_0x40ddcd('0x9')]('/',auth[_0x40ddcd('0xa')](),controller[_0x40ddcd('0x7')]),router[_0x40ddcd('0x6')]('/:id',auth['isAuthenticated'](),controller[_0x40ddcd('0x0')]),router[_0x40ddcd('0x1')](_0x40ddcd('0x3'),auth[_0x40ddcd('0xa')](),controller[_0x40ddcd('0x5')]),module[_0x40ddcd('0xc')]=router; \ No newline at end of file +const a288_0x3001=['/:id','../../components/auth/service','create','index','./intSalesforceField.controller','isAuthenticated','update','get','put','delete','express','destroy','show'];(function(_0x2576e0,_0x3001c1){const _0x61da94=function(_0x25f868){while(--_0x25f868){_0x2576e0['push'](_0x2576e0['shift']());}};_0x61da94(++_0x3001c1);}(a288_0x3001,0x125));const a288_0x61da=function(_0x2576e0,_0x3001c1){_0x2576e0=_0x2576e0-0x0;let _0x61da94=a288_0x3001[_0x2576e0];return _0x61da94;};const _0x1e3634=a288_0x61da;'use strict';const express=require(_0x1e3634('0x3')),router=express['Router'](),auth=require(_0x1e3634('0x7')),controller=require(_0x1e3634('0xa'));router[_0x1e3634('0x0')]('/',auth[_0x1e3634('0xb')](),controller[_0x1e3634('0x9')]),router['get'](_0x1e3634('0x6'),auth['isAuthenticated'](),controller[_0x1e3634('0x5')]),router['post']('/',auth[_0x1e3634('0xb')](),controller[_0x1e3634('0x8')]),router[_0x1e3634('0x1')](_0x1e3634('0x6'),auth[_0x1e3634('0xb')](),controller[_0x1e3634('0xc')]),router[_0x1e3634('0x2')](_0x1e3634('0x6'),auth[_0x1e3634('0xb')](),controller[_0x1e3634('0x4')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/intSalesforceField/intSalesforceField.attributes.js b/server/api/intSalesforceField/intSalesforceField.attributes.js index e46c556..674dbb8 100644 --- a/server/api/intSalesforceField/intSalesforceField.attributes.js +++ b/server/api/intSalesforceField/intSalesforceField.attributes.js @@ -1 +1 @@ -const a289_0x1038=['customVariable','variable','exports','string','STRING','sequelize'];(function(_0x3e1fad,_0x103864){const _0x2f47b7=function(_0x3393ed){while(--_0x3393ed){_0x3e1fad['push'](_0x3e1fad['shift']());}};_0x2f47b7(++_0x103864);}(a289_0x1038,0x11f));const a289_0x2f47=function(_0x3e1fad,_0x103864){_0x3e1fad=_0x3e1fad-0x0;let _0x2f47b7=a289_0x1038[_0x3e1fad];return _0x2f47b7;};const _0x489198=a289_0x2f47;'use strict';const Sequelize=require(_0x489198('0x0'));module[_0x489198('0x3')]={'type':{'type':Sequelize['ENUM'](_0x489198('0x4'),_0x489198('0x2'),'customVariable','keyValue'),'defaultValue':_0x489198('0x4')},'content':{'type':Sequelize[_0x489198('0x5')]},'key':{'type':Sequelize[_0x489198('0x5')]},'keyType':{'type':Sequelize['ENUM'](_0x489198('0x4'),_0x489198('0x2'),_0x489198('0x1'))},'keyContent':{'type':Sequelize[_0x489198('0x5')]},'idField':{'type':Sequelize[_0x489198('0x5')]},'variableName':{'type':Sequelize[_0x489198('0x5')]}}; \ No newline at end of file +const a289_0x34ef=['sequelize','ENUM','STRING','customVariable','variable','string'];(function(_0x3a5cfe,_0x34ef4e){const _0x4ea62b=function(_0x2df91c){while(--_0x2df91c){_0x3a5cfe['push'](_0x3a5cfe['shift']());}};_0x4ea62b(++_0x34ef4e);}(a289_0x34ef,0x79));const a289_0x4ea6=function(_0x3a5cfe,_0x34ef4e){_0x3a5cfe=_0x3a5cfe-0x0;let _0x4ea62b=a289_0x34ef[_0x3a5cfe];return _0x4ea62b;};const _0x36533e=a289_0x4ea6;'use strict';const Sequelize=require(_0x36533e('0x5'));module['exports']={'type':{'type':Sequelize[_0x36533e('0x0')](_0x36533e('0x4'),'variable',_0x36533e('0x2'),'keyValue'),'defaultValue':'string'},'content':{'type':Sequelize[_0x36533e('0x1')]},'key':{'type':Sequelize[_0x36533e('0x1')]},'keyType':{'type':Sequelize[_0x36533e('0x0')]('string',_0x36533e('0x3'),_0x36533e('0x2'))},'keyContent':{'type':Sequelize[_0x36533e('0x1')]},'idField':{'type':Sequelize[_0x36533e('0x1')]},'variableName':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/intSalesforceField/intSalesforceField.controller.js b/server/api/intSalesforceField/intSalesforceField.controller.js index 0e32478..0efb870 100644 --- a/server/api/intSalesforceField/intSalesforceField.controller.js +++ b/server/api/intSalesforceField/intSalesforceField.controller.js @@ -1 +1 @@ -const a290_0x57e1=['findOne','set','merge','filter','fieldName','end','Content-Range','count','fields','stack','then','error','name','SalesforceField','body','undefined','type','limit','nolimit','params','query','index','json','keys','where','options','key','rawAttributes','order','destroy','../../mysqldb','intersection','catch','pick','sort','offset','show','update','model','create','map','filters','lodash','status','includeAll','sequelize','../../components/parsers/qs','attributes'];(function(_0x319592,_0x57e16b){const _0xf16755=function(_0x16eac1){while(--_0x16eac1){_0x319592['push'](_0x319592['shift']());}};_0xf16755(++_0x57e16b);}(a290_0x57e1,0x133));const a290_0xf167=function(_0x319592,_0x57e16b){_0x319592=_0x319592-0x0;let _0xf16755=a290_0x57e1[_0x319592];return _0xf16755;};const _0x10c0a7=a290_0xf167;'use strict';const _=require(_0x10c0a7('0x17')),qs=require(_0x10c0a7('0x1b')),logger=require('../../config/logger')('api'),db=require(_0x10c0a7('0xb'))['db'],{Op}=require(_0x10c0a7('0x1a'));function respondWithResult(_0x16eac1,_0x544946){return _0x544946=_0x544946||0xc8,function(_0x270343){const _0xe46604=a290_0xf167;if(_0x270343)return _0x16eac1[_0xe46604('0x18')](_0x544946)[_0xe46604('0x3')](_0x270343);};}function respondWithFilteredResult(_0x1ea8bd,_0x4041bf){return function(_0x11cb99){const _0x261425=a290_0xf167;if(_0x11cb99){const _0x139478=_0x11cb99[_0x261425('0x24')],_0xab9d0c=_0x4041bf[_0x261425('0x10')];let _0x1dbe08=_0x4041bf[_0x261425('0x10')]+_0x4041bf[_0x261425('0x2e')],_0x100f4a;return _0x1dbe08>=_0x139478?(_0x1dbe08=_0x139478,_0x100f4a=0xc8):_0x100f4a=0xce,_0x1ea8bd[_0x261425('0x18')](_0x100f4a),_0x1ea8bd[_0x261425('0x1e')](_0x261425('0x23'),_0xab9d0c+'-'+_0x1dbe08+'/'+_0x139478)[_0x261425('0x3')](_0x11cb99);}return null;};}function saveUpdates(_0x3fbcc9){return function(_0x3f2761){const _0x62f80b=a290_0xf167;if(_0x3f2761)return _0x3f2761['update'](_0x3fbcc9)[_0x62f80b('0x27')](function(_0x419842){return _0x419842;});return null;};}function removeEntity(_0x4a8bc3){return function(_0xcf597f){const _0x119bed=a290_0xf167;if(_0xcf597f)return _0xcf597f['destroy']()[_0x119bed('0x27')](function(){const _0x3fec0d=_0x119bed;_0x4a8bc3[_0x3fec0d('0x18')](0xcc)[_0x3fec0d('0x22')]();});};}function handleEntityNotFound(_0x1ce9ce){return function(_0x17e94c){return!_0x17e94c&&_0x1ce9ce['sendStatus'](0x194),_0x17e94c;};}function handleError(_0x403736,_0xf868de){return _0xf868de=_0xf868de||0x1f4,function(_0x20541b){const _0x231463=a290_0xf167;logger[_0x231463('0x28')](_0x20541b[_0x231463('0x26')]),_0x20541b[_0x231463('0x29')]&&delete _0x20541b[_0x231463('0x29')],_0x403736[_0x231463('0x18')](_0xf868de)['send'](_0x20541b);};}exports[_0x10c0a7('0x2')]=function(_0x5e8f36,_0x109c6b){const _0x42dea4=_0x10c0a7;let _0x1a27c3={};const _0x17f0b7={},_0x2bfabb={'count':0x0,'rows':[]},_0x1ff1a4=_[_0x42dea4('0x15')](db['SalesforceField'][_0x42dea4('0x8')],function(_0x3fb209){const _0x5251ba=_0x42dea4;return{'name':_0x3fb209[_0x5251ba('0x21')],'type':_0x3fb209['type'][_0x5251ba('0x7')]};});_0x17f0b7[_0x42dea4('0x13')]=_['map'](_0x1ff1a4,_0x42dea4('0x29')),_0x17f0b7[_0x42dea4('0x1')]=_['keys'](_0x5e8f36['query']),_0x17f0b7[_0x42dea4('0x16')]=_['intersection'](_0x17f0b7['model'],_0x17f0b7[_0x42dea4('0x1')]),_0x1a27c3[_0x42dea4('0x1c')]=_[_0x42dea4('0xc')](_0x17f0b7[_0x42dea4('0x13')],qs[_0x42dea4('0x25')](_0x5e8f36[_0x42dea4('0x1')]['fields'])),_0x1a27c3[_0x42dea4('0x1c')]=_0x1a27c3['attributes']['length']?_0x1a27c3[_0x42dea4('0x1c')]:_0x17f0b7[_0x42dea4('0x13')];typeof _0x5e8f36[_0x42dea4('0x1')][_0x42dea4('0x2f')]===_0x42dea4('0x2c')&&(_0x1a27c3[_0x42dea4('0x2e')]=qs[_0x42dea4('0x2e')](_0x5e8f36[_0x42dea4('0x1')][_0x42dea4('0x2e')]),_0x1a27c3['offset']=qs[_0x42dea4('0x10')](_0x5e8f36['query'][_0x42dea4('0x10')]));_0x1a27c3[_0x42dea4('0x9')]=qs['sort'](_0x5e8f36['query'][_0x42dea4('0xf')]),_0x1a27c3['where']=qs['filters'](_[_0x42dea4('0xe')](_0x5e8f36[_0x42dea4('0x1')],_0x17f0b7['filters']),_0x1ff1a4);_0x5e8f36['query'][_0x42dea4('0x20')]&&(_0x1a27c3[_0x42dea4('0x5')]=_[_0x42dea4('0x1f')](_0x1a27c3[_0x42dea4('0x5')],{[Op['or']]:_[_0x42dea4('0x15')](_0x1ff1a4,function(_0x49bbc3){const _0x3eec2b=_0x42dea4;if(_0x49bbc3[_0x3eec2b('0x2d')]!=='VIRTUAL'){const _0x3beaae={};return _0x3beaae[_0x49bbc3[_0x3eec2b('0x29')]]={[Op['like']]:'%'+_0x5e8f36[_0x3eec2b('0x1')]['filter']+'%'},_0x3beaae;}})}));_0x1a27c3=_[_0x42dea4('0x1f')]({},_0x1a27c3,_0x5e8f36[_0x42dea4('0x6')]);const _0x40d144={'where':_0x1a27c3[_0x42dea4('0x5')]};return db[_0x42dea4('0x2a')][_0x42dea4('0x24')](_0x40d144)[_0x42dea4('0x27')](function(_0x44138e){const _0x3fff1c=_0x42dea4;return _0x2bfabb[_0x3fff1c('0x24')]=_0x44138e,_0x5e8f36[_0x3fff1c('0x1')][_0x3fff1c('0x19')]&&(_0x1a27c3['include']=[{'all':!![]}]),db[_0x3fff1c('0x2a')]['findAll'](_0x1a27c3);})[_0x42dea4('0x27')](function(_0x5972a4){return _0x2bfabb['rows']=_0x5972a4,_0x2bfabb;})[_0x42dea4('0x27')](respondWithFilteredResult(_0x109c6b,_0x1a27c3))[_0x42dea4('0xd')](handleError(_0x109c6b,null));},exports[_0x10c0a7('0x11')]=function(_0x33b456,_0x48a29f){const _0x600e06=_0x10c0a7;let _0x1b7543={'raw':!![],'where':{'id':_0x33b456[_0x600e06('0x0')]['id']}};const _0x444506={};return _0x444506[_0x600e06('0x13')]=_[_0x600e06('0x4')](db[_0x600e06('0x2a')]['rawAttributes']),_0x444506[_0x600e06('0x1')]=_[_0x600e06('0x4')](_0x33b456[_0x600e06('0x1')]),_0x444506['filters']=_[_0x600e06('0xc')](_0x444506[_0x600e06('0x13')],_0x444506['query']),_0x1b7543[_0x600e06('0x1c')]=_[_0x600e06('0xc')](_0x444506[_0x600e06('0x13')],qs[_0x600e06('0x25')](_0x33b456[_0x600e06('0x1')][_0x600e06('0x25')])),_0x1b7543[_0x600e06('0x1c')]=_0x1b7543[_0x600e06('0x1c')]['length']?_0x1b7543['attributes']:_0x444506[_0x600e06('0x13')],_0x33b456['query'][_0x600e06('0x19')]&&(_0x1b7543['include']=[{'all':!![]}]),_0x1b7543=_[_0x600e06('0x1f')]({},_0x1b7543,_0x33b456['options']),db[_0x600e06('0x2a')][_0x600e06('0x1d')](_0x1b7543)[_0x600e06('0x27')](handleEntityNotFound(_0x48a29f,null))[_0x600e06('0x27')](respondWithResult(_0x48a29f,null))['catch'](handleError(_0x48a29f,null));},exports[_0x10c0a7('0x14')]=function(_0x4d1db6,_0x54956d){const _0x5429f7=_0x10c0a7;return db['SalesforceField'][_0x5429f7('0x14')](_0x4d1db6['body'],{})['then'](respondWithResult(_0x54956d,0xc9))[_0x5429f7('0xd')](handleError(_0x54956d,null));},exports[_0x10c0a7('0x12')]=function(_0x4dc11b,_0x5e30eb){const _0x2b047d=_0x10c0a7;return _0x4dc11b['body']['id']&&delete _0x4dc11b[_0x2b047d('0x2b')]['id'],db[_0x2b047d('0x2a')]['findOne']({'where':{'id':_0x4dc11b[_0x2b047d('0x0')]['id']}})[_0x2b047d('0x27')](handleEntityNotFound(_0x5e30eb,null))[_0x2b047d('0x27')](saveUpdates(_0x4dc11b['body'],null))[_0x2b047d('0x27')](respondWithResult(_0x5e30eb,null))[_0x2b047d('0xd')](handleError(_0x5e30eb,null));},exports[_0x10c0a7('0xa')]=function(_0x1f590a,_0x3009f0){const _0x56a633=_0x10c0a7;return db['SalesforceField'][_0x56a633('0x1d')]({'where':{'id':_0x1f590a[_0x56a633('0x0')]['id']}})[_0x56a633('0x27')](handleEntityNotFound(_0x3009f0,null))[_0x56a633('0x27')](removeEntity(_0x3009f0,null))[_0x56a633('0xd')](handleError(_0x3009f0,null));}; \ No newline at end of file +const a290_0x2a90=['sort','set','like','query','stack','json','include','findOne','length','update','keys','order','filters','pick','intersection','SalesforceField','api','rawAttributes','index','create','undefined','catch','limit','where','key','rows','params','count','options','map','end','type','filter','sendStatus','then','name','offset','Content-Range','model','attributes','body','error','fields','fieldName','destroy','../../mysqldb','merge','findAll','status'];(function(_0x2c4219,_0x2a90e0){const _0x4c834c=function(_0x47409b){while(--_0x47409b){_0x2c4219['push'](_0x2c4219['shift']());}};_0x4c834c(++_0x2a90e0);}(a290_0x2a90,0x1a0));const a290_0x4c83=function(_0x2c4219,_0x2a90e0){_0x2c4219=_0x2c4219-0x0;let _0x4c834c=a290_0x2a90[_0x2c4219];return _0x4c834c;};const _0x3d13cc=a290_0x4c83;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x3d13cc('0x29')),db=require(_0x3d13cc('0x15'))['db'],{Op}=require('sequelize');function respondWithResult(_0x47409b,_0x282cc2){return _0x282cc2=_0x282cc2||0xc8,function(_0x504ddb){const _0x310aa1=a290_0x4c83;if(_0x504ddb)return _0x47409b[_0x310aa1('0x18')](_0x282cc2)[_0x310aa1('0x1e')](_0x504ddb);};}function respondWithFilteredResult(_0x51403d,_0x41d270){return function(_0x249747){const _0x58c3a3=a290_0x4c83;if(_0x249747){const _0x51c2e0=_0x249747['count'],_0x9cb765=_0x41d270[_0x58c3a3('0xc')];let _0x380f70=_0x41d270[_0x58c3a3('0xc')]+_0x41d270[_0x58c3a3('0x2f')],_0x222e5f;return _0x380f70>=_0x51c2e0?(_0x380f70=_0x51c2e0,_0x222e5f=0xc8):_0x222e5f=0xce,_0x51403d[_0x58c3a3('0x18')](_0x222e5f),_0x51403d[_0x58c3a3('0x1a')](_0x58c3a3('0xd'),_0x9cb765+'-'+_0x380f70+'/'+_0x51c2e0)[_0x58c3a3('0x1e')](_0x249747);}return null;};}function saveUpdates(_0x474ba1){return function(_0x15ddd6){const _0x1f4278=a290_0x4c83;if(_0x15ddd6)return _0x15ddd6[_0x1f4278('0x22')](_0x474ba1)[_0x1f4278('0xa')](function(_0x183e05){return _0x183e05;});return null;};}function removeEntity(_0x46fb83){return function(_0x18ff00){const _0xf039c6=a290_0x4c83;if(_0x18ff00)return _0x18ff00[_0xf039c6('0x14')]()[_0xf039c6('0xa')](function(){const _0x481764=_0xf039c6;_0x46fb83[_0x481764('0x18')](0xcc)[_0x481764('0x6')]();});};}function handleEntityNotFound(_0x3117d3){return function(_0x379ae8){const _0x3a0469=a290_0x4c83;return!_0x379ae8&&_0x3117d3[_0x3a0469('0x9')](0x194),_0x379ae8;};}function handleError(_0x417af9,_0x58c0ef){return _0x58c0ef=_0x58c0ef||0x1f4,function(_0x54cc6a){const _0x2b55a6=a290_0x4c83;logger[_0x2b55a6('0x11')](_0x54cc6a[_0x2b55a6('0x1d')]),_0x54cc6a[_0x2b55a6('0xb')]&&delete _0x54cc6a['name'],_0x417af9['status'](_0x58c0ef)['send'](_0x54cc6a);};}exports[_0x3d13cc('0x2b')]=function(_0x4fc022,_0x7cb9d2){const _0x21561b=_0x3d13cc;let _0x2053d6={};const _0x34d5ea={},_0x1b6d82={'count':0x0,'rows':[]},_0x498c98=_[_0x21561b('0x5')](db[_0x21561b('0x28')]['rawAttributes'],function(_0x460376){const _0x2f04cc=_0x21561b;return{'name':_0x460376[_0x2f04cc('0x13')],'type':_0x460376[_0x2f04cc('0x7')][_0x2f04cc('0x0')]};});_0x34d5ea['model']=_[_0x21561b('0x5')](_0x498c98,'name'),_0x34d5ea[_0x21561b('0x1c')]=_[_0x21561b('0x23')](_0x4fc022[_0x21561b('0x1c')]),_0x34d5ea[_0x21561b('0x25')]=_[_0x21561b('0x27')](_0x34d5ea['model'],_0x34d5ea[_0x21561b('0x1c')]),_0x2053d6[_0x21561b('0xf')]=_[_0x21561b('0x27')](_0x34d5ea['model'],qs['fields'](_0x4fc022[_0x21561b('0x1c')][_0x21561b('0x12')])),_0x2053d6[_0x21561b('0xf')]=_0x2053d6[_0x21561b('0xf')][_0x21561b('0x21')]?_0x2053d6['attributes']:_0x34d5ea[_0x21561b('0xe')];typeof _0x4fc022[_0x21561b('0x1c')]['nolimit']===_0x21561b('0x2d')&&(_0x2053d6[_0x21561b('0x2f')]=qs[_0x21561b('0x2f')](_0x4fc022[_0x21561b('0x1c')][_0x21561b('0x2f')]),_0x2053d6[_0x21561b('0xc')]=qs['offset'](_0x4fc022['query']['offset']));_0x2053d6[_0x21561b('0x24')]=qs[_0x21561b('0x19')](_0x4fc022['query'][_0x21561b('0x19')]),_0x2053d6[_0x21561b('0x30')]=qs[_0x21561b('0x25')](_[_0x21561b('0x26')](_0x4fc022[_0x21561b('0x1c')],_0x34d5ea[_0x21561b('0x25')]),_0x498c98);_0x4fc022[_0x21561b('0x1c')]['filter']&&(_0x2053d6[_0x21561b('0x30')]=_['merge'](_0x2053d6[_0x21561b('0x30')],{[Op['or']]:_[_0x21561b('0x5')](_0x498c98,function(_0x4839e1){const _0x5c6bf5=_0x21561b;if(_0x4839e1[_0x5c6bf5('0x7')]!=='VIRTUAL'){const _0x2ab210={};return _0x2ab210[_0x4839e1[_0x5c6bf5('0xb')]]={[Op[_0x5c6bf5('0x1b')]]:'%'+_0x4fc022[_0x5c6bf5('0x1c')][_0x5c6bf5('0x8')]+'%'},_0x2ab210;}})}));_0x2053d6=_[_0x21561b('0x16')]({},_0x2053d6,_0x4fc022[_0x21561b('0x4')]);const _0x1db66b={'where':_0x2053d6[_0x21561b('0x30')]};return db[_0x21561b('0x28')][_0x21561b('0x3')](_0x1db66b)[_0x21561b('0xa')](function(_0x370dd5){const _0x139f09=_0x21561b;return _0x1b6d82['count']=_0x370dd5,_0x4fc022[_0x139f09('0x1c')]['includeAll']&&(_0x2053d6[_0x139f09('0x1f')]=[{'all':!![]}]),db['SalesforceField'][_0x139f09('0x17')](_0x2053d6);})[_0x21561b('0xa')](function(_0x400d52){const _0x45ff2f=_0x21561b;return _0x1b6d82[_0x45ff2f('0x1')]=_0x400d52,_0x1b6d82;})[_0x21561b('0xa')](respondWithFilteredResult(_0x7cb9d2,_0x2053d6))[_0x21561b('0x2e')](handleError(_0x7cb9d2,null));},exports['show']=function(_0xbb922b,_0x5b82c7){const _0x2d1f68=_0x3d13cc;let _0x5a5218={'raw':!![],'where':{'id':_0xbb922b[_0x2d1f68('0x2')]['id']}};const _0x1a0051={};return _0x1a0051[_0x2d1f68('0xe')]=_[_0x2d1f68('0x23')](db[_0x2d1f68('0x28')][_0x2d1f68('0x2a')]),_0x1a0051[_0x2d1f68('0x1c')]=_[_0x2d1f68('0x23')](_0xbb922b[_0x2d1f68('0x1c')]),_0x1a0051['filters']=_[_0x2d1f68('0x27')](_0x1a0051[_0x2d1f68('0xe')],_0x1a0051[_0x2d1f68('0x1c')]),_0x5a5218['attributes']=_[_0x2d1f68('0x27')](_0x1a0051[_0x2d1f68('0xe')],qs[_0x2d1f68('0x12')](_0xbb922b[_0x2d1f68('0x1c')][_0x2d1f68('0x12')])),_0x5a5218[_0x2d1f68('0xf')]=_0x5a5218[_0x2d1f68('0xf')][_0x2d1f68('0x21')]?_0x5a5218['attributes']:_0x1a0051[_0x2d1f68('0xe')],_0xbb922b['query']['includeAll']&&(_0x5a5218['include']=[{'all':!![]}]),_0x5a5218=_[_0x2d1f68('0x16')]({},_0x5a5218,_0xbb922b[_0x2d1f68('0x4')]),db[_0x2d1f68('0x28')][_0x2d1f68('0x20')](_0x5a5218)[_0x2d1f68('0xa')](handleEntityNotFound(_0x5b82c7,null))[_0x2d1f68('0xa')](respondWithResult(_0x5b82c7,null))['catch'](handleError(_0x5b82c7,null));},exports[_0x3d13cc('0x2c')]=function(_0x1602b9,_0x3db6c0){const _0x37375e=_0x3d13cc;return db[_0x37375e('0x28')][_0x37375e('0x2c')](_0x1602b9['body'],{})[_0x37375e('0xa')](respondWithResult(_0x3db6c0,0xc9))[_0x37375e('0x2e')](handleError(_0x3db6c0,null));},exports[_0x3d13cc('0x22')]=function(_0x3dd6fc,_0x43062b){const _0xefbbc7=_0x3d13cc;return _0x3dd6fc['body']['id']&&delete _0x3dd6fc[_0xefbbc7('0x10')]['id'],db[_0xefbbc7('0x28')][_0xefbbc7('0x20')]({'where':{'id':_0x3dd6fc['params']['id']}})[_0xefbbc7('0xa')](handleEntityNotFound(_0x43062b,null))[_0xefbbc7('0xa')](saveUpdates(_0x3dd6fc[_0xefbbc7('0x10')],null))['then'](respondWithResult(_0x43062b,null))['catch'](handleError(_0x43062b,null));},exports[_0x3d13cc('0x14')]=function(_0x24858b,_0x52a674){const _0x4e6f84=_0x3d13cc;return db[_0x4e6f84('0x28')][_0x4e6f84('0x20')]({'where':{'id':_0x24858b[_0x4e6f84('0x2')]['id']}})[_0x4e6f84('0xa')](handleEntityNotFound(_0x52a674,null))[_0x4e6f84('0xa')](removeEntity(_0x52a674,null))[_0x4e6f84('0x2e')](handleError(_0x52a674,null));}; \ No newline at end of file diff --git a/server/api/intSalesforceField/intSalesforceField.model.js b/server/api/intSalesforceField/intSalesforceField.model.js index adab8d2..630a8ab 100644 --- a/server/api/intSalesforceField/intSalesforceField.model.js +++ b/server/api/intSalesforceField/intSalesforceField.model.js @@ -1 +1 @@ -const a291_0x5309=['./intSalesforceField.attributes','int_salesforce_fields','exports','salesforce_unique_index','FieldId','SalesforceField'];(function(_0x354ab3,_0x53095f){const _0x2d43c5=function(_0x8f4145){while(--_0x8f4145){_0x354ab3['push'](_0x354ab3['shift']());}};_0x2d43c5(++_0x53095f);}(a291_0x5309,0x131));const a291_0x2d43=function(_0x354ab3,_0x53095f){_0x354ab3=_0x354ab3-0x0;let _0x2d43c5=a291_0x5309[_0x354ab3];return _0x2d43c5;};const _0x4ef866=a291_0x2d43;'use strict';const attributes=require(_0x4ef866('0x1'));module[_0x4ef866('0x3')]=function(_0x8f4145){const _0x2608f3=_0x4ef866,_0x162c89=_0x8f4145['define'](_0x2608f3('0x0'),attributes,{'tableName':_0x2608f3('0x2'),'paranoid':![],'indexes':[{'name':_0x2608f3('0x4'),'fields':['idField',_0x2608f3('0x5')],'unique':!![]}],'timestamps':!![]});return _0x162c89;}; \ No newline at end of file +const a291_0x2117=['salesforce_unique_index','define','SalesforceField','FieldId','./intSalesforceField.attributes','int_salesforce_fields'];(function(_0x26f7a5,_0x2117e1){const _0x2ef369=function(_0x4e42d3){while(--_0x4e42d3){_0x26f7a5['push'](_0x26f7a5['shift']());}};_0x2ef369(++_0x2117e1);}(a291_0x2117,0x140));const a291_0x2ef3=function(_0x26f7a5,_0x2117e1){_0x26f7a5=_0x26f7a5-0x0;let _0x2ef369=a291_0x2117[_0x26f7a5];return _0x2ef369;};const _0x427816=a291_0x2ef3;'use strict';const attributes=require(_0x427816('0x2'));module['exports']=function(_0x4e42d3){const _0x43ac3a=_0x427816,_0x1713f6=_0x4e42d3[_0x43ac3a('0x5')](_0x43ac3a('0x0'),attributes,{'tableName':_0x43ac3a('0x3'),'paranoid':![],'indexes':[{'name':_0x43ac3a('0x4'),'fields':['idField',_0x43ac3a('0x1')],'unique':!![]}],'timestamps':!![]});return _0x1713f6;}; \ No newline at end of file diff --git a/server/api/intServicenowAccount/index.js b/server/api/intServicenowAccount/index.js index 947c7fc..307ddb7 100644 --- a/server/api/intServicenowAccount/index.js +++ b/server/api/intServicenowAccount/index.js @@ -1 +1 @@ -const a292_0x4409=['post','isAuthenticated','destroy','getConfigurations','/:id/fields','/:id/configurations','update','../../components/auth/service','Router','show','/:id','./intServicenowAccount.controller','express','get','exports'];(function(_0x111340,_0x440918){const _0x10f0a3=function(_0x32a518){while(--_0x32a518){_0x111340['push'](_0x111340['shift']());}};_0x10f0a3(++_0x440918);}(a292_0x4409,0x1ee));const a292_0x10f0=function(_0x111340,_0x440918){_0x111340=_0x111340-0x0;let _0x10f0a3=a292_0x4409[_0x111340];return _0x10f0a3;};const _0x351d82=a292_0x10f0;'use strict';const express=require(_0x351d82('0xd')),router=express[_0x351d82('0x9')](),auth=require(_0x351d82('0x8')),controller=require(_0x351d82('0xc'));router[_0x351d82('0xe')]('/',auth[_0x351d82('0x2')](),controller['index']),router['get'](_0x351d82('0xb'),auth[_0x351d82('0x2')](),controller[_0x351d82('0xa')]),router[_0x351d82('0xe')](_0x351d82('0x6'),auth[_0x351d82('0x2')](),controller[_0x351d82('0x4')]),router[_0x351d82('0xe')](_0x351d82('0x5'),auth[_0x351d82('0x2')](),controller['getFields']),router[_0x351d82('0x1')]('/',auth[_0x351d82('0x2')](),controller['create']),router[_0x351d82('0x1')](_0x351d82('0x6'),auth[_0x351d82('0x2')](),controller['addConfiguration']),router['put'](_0x351d82('0xb'),auth[_0x351d82('0x2')](),controller[_0x351d82('0x7')]),router['delete'](_0x351d82('0xb'),auth[_0x351d82('0x2')](),controller[_0x351d82('0x3')]),module[_0x351d82('0x0')]=router; \ No newline at end of file +const a292_0x5732=['getConfigurations','/:id','get','post','destroy','./intServicenowAccount.controller','express','create','addConfiguration','isAuthenticated','/:id/configurations','exports'];(function(_0x336627,_0x573288){const _0x3cbb2e=function(_0x29447d){while(--_0x29447d){_0x336627['push'](_0x336627['shift']());}};_0x3cbb2e(++_0x573288);}(a292_0x5732,0xcf));const a292_0x3cbb=function(_0x336627,_0x573288){_0x336627=_0x336627-0x0;let _0x3cbb2e=a292_0x5732[_0x336627];return _0x3cbb2e;};const _0x3b5a92=a292_0x3cbb;'use strict';const express=require(_0x3b5a92('0x3')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x3b5a92('0x2'));router[_0x3b5a92('0xb')]('/',auth['isAuthenticated'](),controller['index']),router['get'](_0x3b5a92('0xa'),auth[_0x3b5a92('0x6')](),controller['show']),router['get'](_0x3b5a92('0x7'),auth[_0x3b5a92('0x6')](),controller[_0x3b5a92('0x9')]),router['get']('/:id/fields',auth[_0x3b5a92('0x6')](),controller['getFields']),router[_0x3b5a92('0x0')]('/',auth[_0x3b5a92('0x6')](),controller[_0x3b5a92('0x4')]),router['post']('/:id/configurations',auth[_0x3b5a92('0x6')](),controller[_0x3b5a92('0x5')]),router['put']('/:id',auth[_0x3b5a92('0x6')](),controller['update']),router['delete'](_0x3b5a92('0xa'),auth['isAuthenticated'](),controller[_0x3b5a92('0x1')]),module[_0x3b5a92('0x8')]=router; \ No newline at end of file diff --git a/server/api/intServicenowAccount/intServicenowAccount.attributes.js b/server/api/intServicenowAccount/intServicenowAccount.attributes.js index a8c906d..6cca36c 100644 --- a/server/api/intServicenowAccount/intServicenowAccount.attributes.js +++ b/server/api/intServicenowAccount/intServicenowAccount.attributes.js @@ -1 +1 @@ -const a293_0x3860=['sequelize','exports','STRING','remoteUri'];(function(_0x3d2cc4,_0x386094){const _0x475f85=function(_0xf1e3ee){while(--_0xf1e3ee){_0x3d2cc4['push'](_0x3d2cc4['shift']());}};_0x475f85(++_0x386094);}(a293_0x3860,0xb4));const a293_0x475f=function(_0x3d2cc4,_0x386094){_0x3d2cc4=_0x3d2cc4-0x0;let _0x475f85=a293_0x3860[_0x3d2cc4];return _0x475f85;};const _0x2aef40=a293_0x475f;'use strict';const Sequelize=require(_0x2aef40('0x0'));module[_0x2aef40('0x1')]={'name':{'type':Sequelize[_0x2aef40('0x2')]},'description':{'type':Sequelize[_0x2aef40('0x2')]},'username':{'type':Sequelize[_0x2aef40('0x2')],'unique':'username'},'password':{'type':Sequelize[_0x2aef40('0x2')]},'email':{'type':Sequelize['STRING']},'remoteUri':{'type':Sequelize['STRING'],'unique':_0x2aef40('0x3')},'serverUrl':{'type':Sequelize[_0x2aef40('0x2')]}}; \ No newline at end of file +const a293_0x54e5=['remoteUri','STRING','exports'];(function(_0x53f845,_0x54e5f5){const _0x32dfb4=function(_0x520585){while(--_0x520585){_0x53f845['push'](_0x53f845['shift']());}};_0x32dfb4(++_0x54e5f5);}(a293_0x54e5,0x132));const a293_0x32df=function(_0x53f845,_0x54e5f5){_0x53f845=_0x53f845-0x0;let _0x32dfb4=a293_0x54e5[_0x53f845];return _0x32dfb4;};const _0x22a2e3=a293_0x32df;'use strict';const Sequelize=require('sequelize');module[_0x22a2e3('0x2')]={'name':{'type':Sequelize[_0x22a2e3('0x1')]},'description':{'type':Sequelize[_0x22a2e3('0x1')]},'username':{'type':Sequelize[_0x22a2e3('0x1')],'unique':'username'},'password':{'type':Sequelize[_0x22a2e3('0x1')]},'email':{'type':Sequelize[_0x22a2e3('0x1')]},'remoteUri':{'type':Sequelize[_0x22a2e3('0x1')],'unique':_0x22a2e3('0x0')},'serverUrl':{'type':Sequelize[_0x22a2e3('0x1')]}}; \ No newline at end of file diff --git a/server/api/intServicenowAccount/intServicenowAccount.controller.js b/server/api/intServicenowAccount/intServicenowAccount.controller.js index 3700948..f686186 100644 --- a/server/api/intServicenowAccount/intServicenowAccount.controller.js +++ b/server/api/intServicenowAccount/intServicenowAccount.controller.js @@ -1 +1 @@ -const a294_0x33cf=['label','sla_due','close_code','%s/api/now/table/','options','keys','sys_updated_on','offset','rawAttributes','sys_domain','substring','internalType','findOne','fieldName','../../components/integrations/configuration','sys_created_on','impact','destroy','length','slice','calendar_duration','cmdb_ci','comments','lodash','error','opened_at','forEach','getDescriptions','includes','stack','due_date','%s/api/now/doc/table/schema/','then','statusCode','intersection','true','group_list','ServicenowConfiguration','../../components/parsers/qs','number','where','GET','state','TCL:\x20_object','create','result','business_service','log','rfc','sys_choice?sysparm_query=name=incident^element=','close_notes','problem_id','util','made_sla','subcategory','approval_history','location','set','fields','escalation','short_description','upon_approval','type','include','username','assignment_group','follow_up','getFields','incident_state','VIRTUAL','category','undefined','ServiceNow\x20error:\x20','merge','pick','limit','lastIndexOf','hold_reason','user_input','company','body','show','index','assigned_to','name','params','Descriptions','boolean','query','activity_due','calendar_stc','contact_type','incident?sysparm_display_value=all','upon_reject','child_incidents','reopen_count','assign','additional_assignee_list','getConfigurations','knowledge','ServicenowField','serverUrl','false','model','request-promise-native','filters','filter','correlation_id','order','json','incident\x20table\x20objects','nolimit','approval_set','AccountId','attributes','sys_id','business_stc','email','TCL:\x20exports.getEntityFields\x20->\x20_objectsCustom','True','comments_and_work_notes','count','update','delivery_task','sendStatus','caused_by','opened_by','send','status','format','sys_mod_count','delivery_plan','catch','map','active','notify','sys_class_name','test','closed_at','push','Content-Range','concat','ServicenowAccount','watch_list','resolved_at','caller_id','channel','remoteUri','description','sort','reopened_time','business_duration','like','resolved_by','addConfiguration','reopened_by','Subjects'];(function(_0x53e288,_0x33cfab){const _0x97740d=function(_0x242de0){while(--_0x242de0){_0x53e288['push'](_0x53e288['shift']());}};_0x97740d(++_0x33cfab);}(a294_0x33cf,0x85));const a294_0x9774=function(_0x53e288,_0x33cfab){_0x53e288=_0x53e288-0x0;let _0x97740d=a294_0x33cf[_0x53e288];return _0x97740d;};const _0x120570=a294_0x9774;'use strict';const rp=require(_0x120570('0x80')),util=require(_0x120570('0x4c')),_=require(_0x120570('0x2f')),qs=require(_0x120570('0x3e')),logger=require('../../config/logger')('api'),db=require('../../mysqldb')['db'],{Op}=require('sequelize'),integrations=require(_0x120570('0x26'));function respondWithResult(_0x242de0,_0x106c1d){return _0x106c1d=_0x106c1d||0xc8,function(_0x5d986c){const _0x3bafee=a294_0x9774;if(_0x5d986c)return _0x242de0[_0x3bafee('0x98')](_0x106c1d)[_0x3bafee('0x85')](_0x5d986c);};}function respondWithFilteredResult(_0x3733ef,_0x22a083){return function(_0x4682d5){const _0x204852=a294_0x9774;if(_0x4682d5){const _0x4ad9ec=_0x4682d5[_0x204852('0x91')],_0x4cacf3=_0x22a083[_0x204852('0x1f')];let _0x304178=_0x22a083['offset']+_0x22a083[_0x204852('0x63')],_0x8f087;return _0x304178>=_0x4ad9ec?(_0x304178=_0x4ad9ec,_0x8f087=0xc8):_0x8f087=0xce,_0x3733ef['status'](_0x8f087),_0x3733ef[_0x204852('0x51')](_0x204852('0x7'),_0x4cacf3+'-'+_0x304178+'/'+_0x4ad9ec)['json'](_0x4682d5);}return null;};}function saveUpdates(_0x556a1b){return function(_0xf1ca43){const _0x3561e8=a294_0x9774;if(_0xf1ca43)return _0xf1ca43[_0x3561e8('0x92')](_0x556a1b)[_0x3561e8('0x38')](function(_0x176ab3){return _0x176ab3;});return null;};}function removeEntity(_0x4af5d5){return function(_0x6162a8){const _0x4fd6d4=a294_0x9774;if(_0x6162a8)return _0x6162a8['destroy']()[_0x4fd6d4('0x38')](function(){const _0x71a8ea=_0x4fd6d4;_0x4af5d5[_0x71a8ea('0x98')](0xcc)['end']();});};}function handleEntityNotFound(_0x541dfa){return function(_0x4bc543){const _0x610d6d=a294_0x9774;return!_0x4bc543&&_0x541dfa[_0x610d6d('0x94')](0x194),_0x4bc543;};}function handleError(_0x4fae5a,_0xd77eb5){return _0xd77eb5=_0xd77eb5||0x1f4,function(_0x222ae4){const _0x19fd4b=a294_0x9774;logger['error'](_0x222ae4[_0x19fd4b('0x35')]),_0x222ae4['name']&&delete _0x222ae4[_0x19fd4b('0x6c')],_0x4fae5a['status'](_0xd77eb5)[_0x19fd4b('0x97')](_0x222ae4);};}exports[_0x120570('0x6a')]=function(_0x2a98e3,_0x3e2ad1){const _0x33276f=_0x120570;let _0xd96ab2={};const _0xcde5ef={},_0x3a8869={'count':0x0,'rows':[]},_0xed185=_[_0x33276f('0x0')](db[_0x33276f('0x9')][_0x33276f('0x20')],function(_0x5bdcc3){const _0x520c38=_0x33276f;return{'name':_0x5bdcc3[_0x520c38('0x25')],'type':_0x5bdcc3[_0x520c38('0x56')]['key']};});_0xcde5ef[_0x33276f('0x7f')]=_[_0x33276f('0x0')](_0xed185,_0x33276f('0x6c')),_0xcde5ef['query']=_[_0x33276f('0x1d')](_0x2a98e3[_0x33276f('0x70')]),_0xcde5ef[_0x33276f('0x81')]=_[_0x33276f('0x3a')](_0xcde5ef[_0x33276f('0x7f')],_0xcde5ef[_0x33276f('0x70')]),_0xd96ab2[_0x33276f('0x8a')]=_[_0x33276f('0x3a')](_0xcde5ef[_0x33276f('0x7f')],qs[_0x33276f('0x52')](_0x2a98e3['query'][_0x33276f('0x52')])),_0xd96ab2['attributes']=_0xd96ab2['attributes'][_0x33276f('0x2a')]?_0xd96ab2['attributes']:_0xcde5ef['model'];typeof _0x2a98e3[_0x33276f('0x70')][_0x33276f('0x87')]===_0x33276f('0x5f')&&(_0xd96ab2[_0x33276f('0x63')]=qs[_0x33276f('0x63')](_0x2a98e3['query']['limit']),_0xd96ab2['offset']=qs[_0x33276f('0x1f')](_0x2a98e3[_0x33276f('0x70')][_0x33276f('0x1f')]));_0xd96ab2[_0x33276f('0x84')]=qs['sort'](_0x2a98e3[_0x33276f('0x70')]['sort']),_0xd96ab2[_0x33276f('0x40')]=qs[_0x33276f('0x81')](_[_0x33276f('0x62')](_0x2a98e3[_0x33276f('0x70')],_0xcde5ef[_0x33276f('0x81')]),_0xed185);_0x2a98e3[_0x33276f('0x70')][_0x33276f('0x82')]&&(_0xd96ab2[_0x33276f('0x40')]=_[_0x33276f('0x61')](_0xd96ab2['where'],{[Op['or']]:_[_0x33276f('0x0')](_0xed185,function(_0xc80002){const _0x2ce2f8=_0x33276f;if(_0xc80002[_0x2ce2f8('0x56')]!==_0x2ce2f8('0x5d')){const _0x7b937e={};return _0x7b937e[_0xc80002[_0x2ce2f8('0x6c')]]={[Op[_0x2ce2f8('0x13')]]:'%'+_0x2a98e3[_0x2ce2f8('0x70')][_0x2ce2f8('0x82')]+'%'},_0x7b937e;}})}));_0xd96ab2=_['merge']({},_0xd96ab2,_0x2a98e3[_0x33276f('0x1c')]);const _0x25e5b6={'where':_0xd96ab2[_0x33276f('0x40')]};return db[_0x33276f('0x9')][_0x33276f('0x91')](_0x25e5b6)[_0x33276f('0x38')](function(_0x4e58ca){const _0x2d365d=_0x33276f;return _0x3a8869[_0x2d365d('0x91')]=_0x4e58ca,_0x2a98e3[_0x2d365d('0x70')]['includeAll']&&(_0xd96ab2['include']=[{'all':!![]}]),db[_0x2d365d('0x9')]['findAll'](_0xd96ab2);})[_0x33276f('0x38')](function(_0x592805){return _0x3a8869['rows']=_0x592805,_0x3a8869;})[_0x33276f('0x38')](respondWithFilteredResult(_0x3e2ad1,_0xd96ab2))[_0x33276f('0x9c')](handleError(_0x3e2ad1,null));},exports[_0x120570('0x69')]=function(_0x2ae806,_0x28f7cb){const _0x1c7e4e=_0x120570;let _0x412f91={'raw':![],'where':{'id':_0x2ae806['params']['id']}};const _0x48601e={};return _0x48601e[_0x1c7e4e('0x7f')]=_[_0x1c7e4e('0x1d')](db[_0x1c7e4e('0x9')][_0x1c7e4e('0x20')]),_0x48601e['query']=_['keys'](_0x2ae806[_0x1c7e4e('0x70')]),_0x48601e[_0x1c7e4e('0x81')]=_[_0x1c7e4e('0x3a')](_0x48601e[_0x1c7e4e('0x7f')],_0x48601e['query']),_0x412f91[_0x1c7e4e('0x8a')]=_[_0x1c7e4e('0x3a')](_0x48601e['model'],qs[_0x1c7e4e('0x52')](_0x2ae806[_0x1c7e4e('0x70')][_0x1c7e4e('0x52')])),_0x412f91[_0x1c7e4e('0x8a')]=_0x412f91['attributes'][_0x1c7e4e('0x2a')]?_0x412f91[_0x1c7e4e('0x8a')]:_0x48601e[_0x1c7e4e('0x7f')],_0x2ae806['query']['includeAll']&&(_0x412f91[_0x1c7e4e('0x57')]=[{'all':!![]}]),_0x412f91=_[_0x1c7e4e('0x61')]({},_0x412f91,_0x2ae806[_0x1c7e4e('0x1c')]),db[_0x1c7e4e('0x9')]['findOne'](_0x412f91)[_0x1c7e4e('0x38')](handleEntityNotFound(_0x28f7cb,null))[_0x1c7e4e('0x38')](respondWithResult(_0x28f7cb,null))[_0x1c7e4e('0x9c')](handleError(_0x28f7cb,null));},exports[_0x120570('0x44')]=function(_0x5a4000,_0x39a3c5){const _0x409aa2=_0x120570;return db['ServicenowAccount'][_0x409aa2('0x44')](_0x5a4000['body'],{})['then'](respondWithResult(_0x39a3c5,0xc9))[_0x409aa2('0x9c')](handleError(_0x39a3c5,null));},exports['update']=function(_0x2302ba,_0x5ebce1){const _0x2252a8=_0x120570;return _0x2302ba['body']['id']&&delete _0x2302ba[_0x2252a8('0x68')]['id'],db['ServicenowAccount'][_0x2252a8('0x24')]({'where':{'id':_0x2302ba[_0x2252a8('0x6d')]['id']}})['then'](handleEntityNotFound(_0x5ebce1,null))['then'](saveUpdates(_0x2302ba[_0x2252a8('0x68')],null))['then'](respondWithResult(_0x5ebce1,null))[_0x2252a8('0x9c')](handleError(_0x5ebce1,null));},exports[_0x120570('0x29')]=function(_0x3fbe58,_0x2dfbf5){const _0x36c7f4=_0x120570;return db[_0x36c7f4('0x9')]['findOne']({'where':{'id':_0x3fbe58[_0x36c7f4('0x6d')]['id']}})[_0x36c7f4('0x38')](handleEntityNotFound(_0x2dfbf5,null))['then'](removeEntity(_0x2dfbf5,null))[_0x36c7f4('0x9c')](handleError(_0x2dfbf5,null));},exports[_0x120570('0x7a')]=function(_0x5d1cce,_0x534218){const _0x2f3ea1=_0x120570;let _0x2482cd={};const _0x306318={};let _0x17b19b,_0xce574f;return db[_0x2f3ea1('0x9')][_0x2f3ea1('0x24')]({'where':{'id':_0x5d1cce[_0x2f3ea1('0x6d')]['id']}})['then'](handleEntityNotFound(_0x534218,null))['then'](function(_0x3415a5){const _0x4e6fc4=_0x2f3ea1;if(_0x3415a5)return _0x17b19b=_0x3415a5,_0x306318[_0x4e6fc4('0x7f')]=_[_0x4e6fc4('0x1d')](db[_0x4e6fc4('0x3d')][_0x4e6fc4('0x20')]),_0x306318[_0x4e6fc4('0x70')]=_[_0x4e6fc4('0x1d')](_0x5d1cce['query']),_0x306318['filters']=_[_0x4e6fc4('0x3a')](_0x306318[_0x4e6fc4('0x7f')],_0x306318[_0x4e6fc4('0x70')]),_0x2482cd[_0x4e6fc4('0x8a')]=_['intersection'](_0x306318['model'],qs[_0x4e6fc4('0x52')](_0x5d1cce[_0x4e6fc4('0x70')]['fields'])),_0x2482cd[_0x4e6fc4('0x8a')]=_0x2482cd[_0x4e6fc4('0x8a')][_0x4e6fc4('0x2a')]?_0x2482cd['attributes']:_0x306318[_0x4e6fc4('0x7f')],_0x2482cd[_0x4e6fc4('0x84')]=qs[_0x4e6fc4('0x10')](_0x5d1cce[_0x4e6fc4('0x70')]['sort']),_0x2482cd[_0x4e6fc4('0x40')]=qs[_0x4e6fc4('0x81')](_[_0x4e6fc4('0x62')](_0x5d1cce[_0x4e6fc4('0x70')],_0x306318[_0x4e6fc4('0x81')])),_0x5d1cce[_0x4e6fc4('0x70')][_0x4e6fc4('0x82')]&&(_0x2482cd[_0x4e6fc4('0x40')]=_[_0x4e6fc4('0x61')](_0x2482cd[_0x4e6fc4('0x40')],{[Op['or']]:_[_0x4e6fc4('0x0')](_0x2482cd[_0x4e6fc4('0x8a')],function(_0x24c473){const _0x530f16=_0x4e6fc4,_0x227f63={};return _0x227f63[_0x24c473]={[Op[_0x530f16('0x13')]]:'%'+_0x5d1cce[_0x530f16('0x70')][_0x530f16('0x82')]+'%'},_0x227f63;})})),_0x2482cd=_['merge']({},_0x2482cd,_0x5d1cce['options']),_0x17b19b[_0x4e6fc4('0x7a')](_0x2482cd);})[_0x2f3ea1('0x38')](function(_0x2e8cd2){const _0x111d5a=_0x2f3ea1;if(_0x2e8cd2)return _0xce574f=_0x2e8cd2['length'],typeof _0x5d1cce[_0x111d5a('0x70')][_0x111d5a('0x87')]==='undefined'&&(_0x2482cd[_0x111d5a('0x63')]=qs[_0x111d5a('0x63')](_0x5d1cce[_0x111d5a('0x70')][_0x111d5a('0x63')]),_0x2482cd['offset']=qs[_0x111d5a('0x1f')](_0x5d1cce[_0x111d5a('0x70')][_0x111d5a('0x1f')])),_0x17b19b[_0x111d5a('0x7a')](_0x2482cd);})[_0x2f3ea1('0x38')](function(_0x3d26c4){if(_0x3d26c4)return _0x3d26c4?{'count':_0xce574f,'rows':_0x3d26c4}:null;})[_0x2f3ea1('0x38')](respondWithResult(_0x534218,null))[_0x2f3ea1('0x9c')](handleError(_0x534218,null));},exports[_0x120570('0x15')]=function(_0x231789,_0x321b30){const _0x251a85=_0x120570;return _0x231789['body']['id']&&delete _0x231789[_0x251a85('0x68')]['id'],db[_0x251a85('0x9')][_0x251a85('0x24')]({'where':{'id':_0x231789[_0x251a85('0x6d')]['id']}})[_0x251a85('0x38')](handleEntityNotFound(_0x321b30,null))[_0x251a85('0x38')](function(_0x2a5a9f){const _0x1df975=_0x251a85;if(_0x2a5a9f)return _0x231789['body'][_0x1df975('0x89')]=_0x2a5a9f['id'],_0x231789[_0x1df975('0x68')][_0x1df975('0x17')]=integrations['getSubjects'](_0x231789['body'][_0x1df975('0xd')],_0x231789[_0x1df975('0x68')][_0x1df975('0x56')]),_0x231789[_0x1df975('0x68')][_0x1df975('0x6e')]=integrations[_0x1df975('0x33')](_0x231789['body']['channel'],_0x231789['body'][_0x1df975('0x56')]),db[_0x1df975('0x3d')]['create'](_0x231789['body'],{'include':[{'model':db['ServicenowField'],'as':_0x1df975('0x17')},{'model':db[_0x1df975('0x7c')],'as':_0x1df975('0x6e')}]});return null;})[_0x251a85('0x38')](respondWithResult(_0x321b30,null))['catch'](handleError(_0x321b30,null));},exports[_0x120570('0x5b')]=function(_0x99e0d2,_0x32c72e){const _0xbbf1c7=_0x120570,_0xaf6daf=['made_sla',_0xbbf1c7('0x65'),_0xbbf1c7('0x7b'),_0xbbf1c7('0x4e'),'close_code',_0xbbf1c7('0x2'),'incident_state','severity','category'],_0x53ba28=['parent',_0xbbf1c7('0x4d'),_0xbbf1c7('0x95'),_0xbbf1c7('0xa'),_0xbbf1c7('0x75'),_0xbbf1c7('0x1e'),_0xbbf1c7('0x76'),_0xbbf1c7('0x65'),_0xbbf1c7('0x4f'),_0xbbf1c7('0x3f'),_0xbbf1c7('0x14'),'sys_updated_by',_0xbbf1c7('0x96'),_0xbbf1c7('0x66'),_0xbbf1c7('0x27'),_0xbbf1c7('0x21'),_0xbbf1c7('0x42'),'sys_created_by',_0xbbf1c7('0x7b'),_0xbbf1c7('0x84'),_0xbbf1c7('0x72'),_0xbbf1c7('0x5'),_0xbbf1c7('0x2d'),_0xbbf1c7('0x9b'),_0xbbf1c7('0x28'),_0xbbf1c7('0x1'),'work_notes_list',_0xbbf1c7('0x46'),'priority','sys_domain_path',_0xbbf1c7('0x48'),'time_worked','expected_start',_0xbbf1c7('0x31'),_0xbbf1c7('0x12'),_0xbbf1c7('0x3c'),'work_end',_0xbbf1c7('0x11'),_0xbbf1c7('0xb'),_0xbbf1c7('0xc'),_0xbbf1c7('0x88'),_0xbbf1c7('0x4e'),'work_notes',_0xbbf1c7('0x54'),_0xbbf1c7('0x1a'),'correlation_display',_0xbbf1c7('0x93'),'work_start',_0xbbf1c7('0x59'),_0xbbf1c7('0x8c'),_0xbbf1c7('0x79'),_0xbbf1c7('0xf'),_0xbbf1c7('0x2c'),_0xbbf1c7('0x2'),_0xbbf1c7('0x3'),_0xbbf1c7('0x4a'),'closed_by',_0xbbf1c7('0x5a'),'parent_incident',_0xbbf1c7('0x8b'),_0xbbf1c7('0x73'),_0xbbf1c7('0x16'),_0xbbf1c7('0x5c'),'urgency',_0xbbf1c7('0x4b'),_0xbbf1c7('0x67'),'reassignment_count',_0xbbf1c7('0x71'),_0xbbf1c7('0x6b'),'severity',_0xbbf1c7('0x2e'),_0xbbf1c7('0x19'),'approval',_0xbbf1c7('0x90'),_0xbbf1c7('0x36'),_0xbbf1c7('0x9a'),_0xbbf1c7('0x77'),'sys_tags',_0xbbf1c7('0x53'),_0xbbf1c7('0x55'),_0xbbf1c7('0x83'),_0xbbf1c7('0x50'),_0xbbf1c7('0x5e')];let _0x11ba53='',_0x5a78e4='',_0xeeb05c=[],_0x48bc0b='',_0x3af758='',_0x12f094=[],_0x10e495='',_0x5f55ed='',_0x182730={},_0x2a4c4e='';return db[_0xbbf1c7('0x9')][_0xbbf1c7('0x24')]({'where':{'id':_0x99e0d2[_0xbbf1c7('0x6d')]['id']},'attributes':['id','username','password',_0xbbf1c7('0x8d'),_0xbbf1c7('0xe'),_0xbbf1c7('0x7d')]})[_0xbbf1c7('0x38')](handleEntityNotFound(_0x32c72e,null))[_0xbbf1c7('0x38')](function(_0x11f26a){const _0x3b1cea=_0xbbf1c7;if(_0x11f26a){_0x2a4c4e=_0x11f26a[_0x3b1cea('0xe')];const _0x2b583f=_0x2a4c4e[_0x3b1cea('0x2b')](-0x1);_0x2b583f==='/'&&(_0x2a4c4e=_0x2a4c4e[_0x3b1cea('0x22')](0x0,_0x2a4c4e[_0x3b1cea('0x64')](_0x2b583f)));_0x5f55ed=util[_0x3b1cea('0x99')](_0x3b1cea('0x37'),_0x2a4c4e),_0x10e495=util[_0x3b1cea('0x99')](_0x3b1cea('0x1b'),_0x2a4c4e),_0x182730={'user':_0x11f26a[_0x3b1cea('0x58')],'pass':_0x11f26a['password']};const _0x508198={'method':_0x3b1cea('0x41'),'uri':_0x5f55ed+_0x3b1cea('0x74'),'auth':_0x182730,'json':!![]};return rp(_0x508198);}})['then'](function(_0x545518){const _0xb296f5=_0xbbf1c7;return _0x545518[_0xb296f5('0x45')][_0xb296f5('0x2a')]>0x0&&(_0x11ba53=_0x545518[_0xb296f5('0x45')]),console['log'](_0xb296f5('0x86'),_0x11ba53),_0x12f094=[],_0x5a78e4=Object[_0xb296f5('0x78')]([],_0x11ba53),_['remove'](_0x5a78e4,function(_0x36d840){const _0x57c83a=_0xb296f5;return!_0xaf6daf[_0x57c83a('0x34')](_0x36d840['name']);}),_0x5a78e4['forEach'](function(_0x1ef657){const _0x4df77d=_0xb296f5,_0x1cec33=createFieldObject(_0x10e495,_0x182730,_0x1ef657[_0x4df77d('0x23')],_0x1ef657[_0x4df77d('0x6c')],_0x1ef657['label'],![]);_0x12f094[_0x4df77d('0x6')](_0x1cec33);}),Promise['all'](_0x12f094);})['then'](function(_0x1567dd){const _0x5a063f=_0xbbf1c7;return _0xeeb05c=_0x1567dd,_0x48bc0b=Object[_0x5a063f('0x78')]([],_0x11ba53),console['log'](_0x5a063f('0x43'),_0x11ba53),_['remove'](_0x48bc0b,function(_0x416b83){const _0x58c8c8=_0x5a063f;return _0x53ba28[_0x58c8c8('0x34')](_0x416b83[_0x58c8c8('0x6c')]);}),console[_0x5a063f('0x47')](_0x5a063f('0x8e'),_0x48bc0b),_0x12f094=[],_0x48bc0b[_0x5a063f('0x32')](function(_0x30a88f){const _0x3b5c09=_0x5a063f,_0x29126d=createFieldObject(_0x10e495,_0x182730,_0x30a88f['internalType'],_0x30a88f[_0x3b5c09('0x6c')],_0x30a88f[_0x3b5c09('0x18')],!![]);_0x12f094['push'](_0x29126d);}),Promise['all'](_0x12f094);})[_0xbbf1c7('0x38')](function(_0x5bc896){const _0x24ccc5=_0xbbf1c7;_0x3af758=_0x5bc896;const _0x125e56=_0xeeb05c[_0x24ccc5('0x8')](_0x3af758);return{'count':_0x125e56['length'],'rows':_0x125e56};})['then'](respondWithResult(_0x32c72e,null))[_0xbbf1c7('0x9c')](function(_0x4b8574){const _0x4b8f99=_0xbbf1c7;console[_0x4b8f99('0x47')](_0x4b8f99('0x60')+_0x4b8574);let _0x2bf922=_0x99e0d2[_0x4b8f99('0x70')]['test']?0x1f4:_0x4b8574[_0x4b8f99('0x39')]||0x1f4;logger[_0x4b8f99('0x30')](_0x4b8574[_0x4b8f99('0x35')]),delete _0x4b8574[_0x4b8f99('0x6c')],_0x2bf922===0x191&&(_0x2bf922=0x190),_0x32c72e[_0x4b8f99('0x98')](_0x2bf922)['send'](_0x99e0d2['query'][_0x4b8f99('0x4')]?{'message':'Wrong\x20credentials','statusCode':_0x4b8574[_0x4b8f99('0x39')]}:_0x4b8574);});};function createFieldObject(_0x40da37,_0xe8b0aa,_0x114e83,_0x2a58ce,_0xc4a398,_0x454718){return new Promise(function(_0x54cb61){const _0x1ee58c=a294_0x9774,_0x5f5cab={'id':_0x2a58ce,'name':_0xc4a398,'custom':_0x454718};if(_0x114e83===_0x1ee58c('0x6f'))_0x5f5cab[_0x1ee58c('0x1c')]=[{'name':_0x1ee58c('0x8f'),'value':_0x1ee58c('0x3b')},{'name':'False','value':_0x1ee58c('0x7e')}],_0x54cb61(_0x5f5cab);else{const _0x2dab77={'method':_0x1ee58c('0x41'),'uri':_0x40da37+_0x1ee58c('0x49')+_0x2a58ce,'auth':_0xe8b0aa,'json':!![]};return rp(_0x2dab77)[_0x1ee58c('0x38')](function(_0x353cba){const _0x5af3f5=_0x1ee58c,_0x29269e=[];_0x353cba['result'][_0x5af3f5('0x2a')]>0x0&&_0x353cba[_0x5af3f5('0x45')]['forEach'](function(_0x8f97f4){const _0x5dc075=_0x5af3f5;if(_0x8f97f4['inactive']===_0x5dc075('0x7e')){const _0x1cfe88={'name':_0x8f97f4[_0x5dc075('0x18')],'value':_0x8f97f4['value']};_0x29269e[_0x5dc075('0x6')](_0x1cfe88);}}),_0x5f5cab['options']=_0x29269e,_0x5f5cab['options']['length']>0x0?_0x54cb61(_0x5f5cab):_0x454718==![]?_0x54cb61():_0x54cb61(_0x5f5cab);});}});} \ No newline at end of file +const a294_0x10ab=['business_service','correlation_display','label','model','AccountId','ServicenowField','getConfigurations','internalType','approval_history','follow_up','comments','resolved_by','approval_set','options','test','%s/api/now/table/','work_end','notify','sequelize','send','knowledge','sys_updated_on','undefined','watch_list','include','order','../../components/parsers/qs','sys_mod_count','active','escalation','pick','incident?sysparm_display_value=all','slice','result','subcategory','body','offset','sys_created_by','getFields','count','business_stc','destroy','key','password','update','assign','VIRTUAL','False','additional_assignee_list','inactive','sys_id','severity','findOne','upon_reject','short_description','assignment_group','nolimit','location','reassignment_count','resolved_at','remoteUri','fields','query','incident\x20table\x20objects','sys_created_on','email','show','caller_id','serverUrl','made_sla','all','cmdb_ci','remove','create','where','Subjects','approval','../../components/integrations/configuration','child_incidents','impact','close_code','rawAttributes','sys_tags','ServiceNow\x20error:\x20','request-promise-native','forEach','business_duration','closed_at','attributes','limit','end','includes','calendar_stc','sys_domain_path','like','parent','ServicenowConfiguration','description','map','True','status','work_start','incident_state','closed_by','lastIndexOf','catch','stack','keys','substring','then','upon_approval','addConfiguration','util','merge','filters','problem_id','channel','type','caused_by','opened_by','sys_domain','format','Wrong\x20credentials','log','Descriptions','number','lodash','sys_class_name','filter','params','push','findAll','length','ServicenowAccount','statusCode','error','boolean','intersection','value','TCL:\x20_object','true','state','api','sendStatus','getSubjects','correlation_id','calendar_duration','concat','false','name','sort','sys_updated_by','category','sys_choice?sysparm_query=name=incident^element=','reopened_time','company','expected_start','hold_reason','work_notes_list','reopened_by','TCL:\x20exports.getEntityFields\x20->\x20_objectsCustom','GET','../../config/logger','contact_type'];(function(_0x55af21,_0x10abf1){const _0x126e5e=function(_0x993ea1){while(--_0x993ea1){_0x55af21['push'](_0x55af21['shift']());}};_0x126e5e(++_0x10abf1);}(a294_0x10ab,0x1eb));const a294_0x126e=function(_0x55af21,_0x10abf1){_0x55af21=_0x55af21-0x0;let _0x126e5e=a294_0x10ab[_0x55af21];return _0x126e5e;};const _0x5d8fb2=a294_0x126e;'use strict';const rp=require(_0x5d8fb2('0x55')),util=require(_0x5d8fb2('0x71')),_=require(_0x5d8fb2('0x7f')),qs=require(_0x5d8fb2('0x1b')),logger=require(_0x5d8fb2('0xa3'))(_0x5d8fb2('0x8f')),db=require('../../mysqldb')['db'],{Op}=require(_0x5d8fb2('0x13')),integrations=require(_0x5d8fb2('0x4e'));function respondWithResult(_0x993ea1,_0xa448e9){return _0xa448e9=_0xa448e9||0xc8,function(_0x47dd01){const _0x7be070=a294_0x126e;if(_0x47dd01)return _0x993ea1[_0x7be070('0x65')](_0xa448e9)['json'](_0x47dd01);};}function respondWithFilteredResult(_0x4237a1,_0x11be43){return function(_0x3f6c6d){const _0xa5ca7d=a294_0x126e;if(_0x3f6c6d){const _0x1e2f74=_0x3f6c6d[_0xa5ca7d('0x28')],_0x380395=_0x11be43[_0xa5ca7d('0x25')];let _0x4c758a=_0x11be43['offset']+_0x11be43[_0xa5ca7d('0x5a')],_0x39c15c;return _0x4c758a>=_0x1e2f74?(_0x4c758a=_0x1e2f74,_0x39c15c=0xc8):_0x39c15c=0xce,_0x4237a1[_0xa5ca7d('0x65')](_0x39c15c),_0x4237a1['set']('Content-Range',_0x380395+'-'+_0x4c758a+'/'+_0x1e2f74)['json'](_0x3f6c6d);}return null;};}function saveUpdates(_0xd89ff2){return function(_0x2eb16f){const _0x70848d=a294_0x126e;if(_0x2eb16f)return _0x2eb16f[_0x70848d('0x2d')](_0xd89ff2)[_0x70848d('0x6e')](function(_0x2ae973){return _0x2ae973;});return null;};}function removeEntity(_0x2e65bc){return function(_0x28ea1c){const _0x2fdfad=a294_0x126e;if(_0x28ea1c)return _0x28ea1c[_0x2fdfad('0x2a')]()[_0x2fdfad('0x6e')](function(){const _0x1d0173=_0x2fdfad;_0x2e65bc[_0x1d0173('0x65')](0xcc)[_0x1d0173('0x5b')]();});};}function handleEntityNotFound(_0x1adc23){return function(_0x50ad41){const _0x37500c=a294_0x126e;return!_0x50ad41&&_0x1adc23[_0x37500c('0x90')](0x194),_0x50ad41;};}function handleError(_0x5388a4,_0x5a3d5b){return _0x5a3d5b=_0x5a3d5b||0x1f4,function(_0x22aeee){const _0x5f43cd=a294_0x126e;logger[_0x5f43cd('0x88')](_0x22aeee[_0x5f43cd('0x6b')]),_0x22aeee[_0x5f43cd('0x96')]&&delete _0x22aeee[_0x5f43cd('0x96')],_0x5388a4[_0x5f43cd('0x65')](_0x5a3d5b)[_0x5f43cd('0x14')](_0x22aeee);};}exports['index']=function(_0x3c0217,_0x56efeb){const _0x59ac19=_0x5d8fb2;let _0x5c83fb={};const _0x4f915={},_0x366627={'count':0x0,'rows':[]},_0x5662dc=_['map'](db[_0x59ac19('0x86')]['rawAttributes'],function(_0x59f81d){const _0x4723ae=_0x59ac19;return{'name':_0x59f81d['fieldName'],'type':_0x59f81d[_0x4723ae('0x76')][_0x4723ae('0x2b')]};});_0x4f915[_0x59ac19('0x4')]=_[_0x59ac19('0x63')](_0x5662dc,_0x59ac19('0x96')),_0x4f915['query']=_['keys'](_0x3c0217['query']),_0x4f915[_0x59ac19('0x73')]=_[_0x59ac19('0x8a')](_0x4f915[_0x59ac19('0x4')],_0x4f915[_0x59ac19('0x3f')]),_0x5c83fb[_0x59ac19('0x59')]=_[_0x59ac19('0x8a')](_0x4f915[_0x59ac19('0x4')],qs['fields'](_0x3c0217[_0x59ac19('0x3f')][_0x59ac19('0x3e')])),_0x5c83fb[_0x59ac19('0x59')]=_0x5c83fb['attributes']['length']?_0x5c83fb['attributes']:_0x4f915['model'];typeof _0x3c0217[_0x59ac19('0x3f')][_0x59ac19('0x39')]===_0x59ac19('0x17')&&(_0x5c83fb[_0x59ac19('0x5a')]=qs['limit'](_0x3c0217[_0x59ac19('0x3f')][_0x59ac19('0x5a')]),_0x5c83fb['offset']=qs['offset'](_0x3c0217[_0x59ac19('0x3f')]['offset']));_0x5c83fb[_0x59ac19('0x1a')]=qs[_0x59ac19('0x97')](_0x3c0217[_0x59ac19('0x3f')][_0x59ac19('0x97')]),_0x5c83fb[_0x59ac19('0x4b')]=qs['filters'](_[_0x59ac19('0x1f')](_0x3c0217['query'],_0x4f915[_0x59ac19('0x73')]),_0x5662dc);_0x3c0217[_0x59ac19('0x3f')]['filter']&&(_0x5c83fb[_0x59ac19('0x4b')]=_['merge'](_0x5c83fb['where'],{[Op['or']]:_[_0x59ac19('0x63')](_0x5662dc,function(_0x323797){const _0x5cb06e=_0x59ac19;if(_0x323797[_0x5cb06e('0x76')]!==_0x5cb06e('0x2f')){const _0x256526={};return _0x256526[_0x323797[_0x5cb06e('0x96')]]={[Op[_0x5cb06e('0x5f')]]:'%'+_0x3c0217[_0x5cb06e('0x3f')][_0x5cb06e('0x81')]+'%'},_0x256526;}})}));_0x5c83fb=_[_0x59ac19('0x72')]({},_0x5c83fb,_0x3c0217[_0x59ac19('0xe')]);const _0x1fb499={'where':_0x5c83fb[_0x59ac19('0x4b')]};return db[_0x59ac19('0x86')]['count'](_0x1fb499)[_0x59ac19('0x6e')](function(_0x2ab9fb){const _0x3193b6=_0x59ac19;return _0x366627[_0x3193b6('0x28')]=_0x2ab9fb,_0x3c0217['query']['includeAll']&&(_0x5c83fb[_0x3193b6('0x19')]=[{'all':!![]}]),db[_0x3193b6('0x86')][_0x3193b6('0x84')](_0x5c83fb);})[_0x59ac19('0x6e')](function(_0x153a02){return _0x366627['rows']=_0x153a02,_0x366627;})[_0x59ac19('0x6e')](respondWithFilteredResult(_0x56efeb,_0x5c83fb))[_0x59ac19('0x6a')](handleError(_0x56efeb,null));},exports[_0x5d8fb2('0x43')]=function(_0x20e3d9,_0x5d2c1a){const _0x576f85=_0x5d8fb2;let _0x1a4823={'raw':![],'where':{'id':_0x20e3d9['params']['id']}};const _0x362263={};return _0x362263['model']=_[_0x576f85('0x6c')](db[_0x576f85('0x86')][_0x576f85('0x52')]),_0x362263['query']=_['keys'](_0x20e3d9[_0x576f85('0x3f')]),_0x362263['filters']=_['intersection'](_0x362263[_0x576f85('0x4')],_0x362263['query']),_0x1a4823[_0x576f85('0x59')]=_['intersection'](_0x362263[_0x576f85('0x4')],qs[_0x576f85('0x3e')](_0x20e3d9[_0x576f85('0x3f')][_0x576f85('0x3e')])),_0x1a4823[_0x576f85('0x59')]=_0x1a4823[_0x576f85('0x59')][_0x576f85('0x85')]?_0x1a4823['attributes']:_0x362263[_0x576f85('0x4')],_0x20e3d9[_0x576f85('0x3f')]['includeAll']&&(_0x1a4823[_0x576f85('0x19')]=[{'all':!![]}]),_0x1a4823=_[_0x576f85('0x72')]({},_0x1a4823,_0x20e3d9[_0x576f85('0xe')]),db['ServicenowAccount'][_0x576f85('0x35')](_0x1a4823)[_0x576f85('0x6e')](handleEntityNotFound(_0x5d2c1a,null))[_0x576f85('0x6e')](respondWithResult(_0x5d2c1a,null))[_0x576f85('0x6a')](handleError(_0x5d2c1a,null));},exports[_0x5d8fb2('0x4a')]=function(_0x185516,_0x45a178){const _0x280f51=_0x5d8fb2;return db[_0x280f51('0x86')][_0x280f51('0x4a')](_0x185516[_0x280f51('0x24')],{})[_0x280f51('0x6e')](respondWithResult(_0x45a178,0xc9))['catch'](handleError(_0x45a178,null));},exports[_0x5d8fb2('0x2d')]=function(_0x5b03f8,_0x408d38){const _0x37af0f=_0x5d8fb2;return _0x5b03f8[_0x37af0f('0x24')]['id']&&delete _0x5b03f8[_0x37af0f('0x24')]['id'],db[_0x37af0f('0x86')][_0x37af0f('0x35')]({'where':{'id':_0x5b03f8[_0x37af0f('0x82')]['id']}})[_0x37af0f('0x6e')](handleEntityNotFound(_0x408d38,null))[_0x37af0f('0x6e')](saveUpdates(_0x5b03f8[_0x37af0f('0x24')],null))[_0x37af0f('0x6e')](respondWithResult(_0x408d38,null))[_0x37af0f('0x6a')](handleError(_0x408d38,null));},exports[_0x5d8fb2('0x2a')]=function(_0x42e47b,_0x4e012c){const _0x553d56=_0x5d8fb2;return db[_0x553d56('0x86')][_0x553d56('0x35')]({'where':{'id':_0x42e47b[_0x553d56('0x82')]['id']}})[_0x553d56('0x6e')](handleEntityNotFound(_0x4e012c,null))[_0x553d56('0x6e')](removeEntity(_0x4e012c,null))[_0x553d56('0x6a')](handleError(_0x4e012c,null));},exports[_0x5d8fb2('0x7')]=function(_0x53704a,_0x34616e){const _0x2b8446=_0x5d8fb2;let _0x5d3d17={};const _0x1076ce={};let _0x51b7a3,_0x12304a;return db[_0x2b8446('0x86')][_0x2b8446('0x35')]({'where':{'id':_0x53704a['params']['id']}})[_0x2b8446('0x6e')](handleEntityNotFound(_0x34616e,null))[_0x2b8446('0x6e')](function(_0x511338){const _0x3472b4=_0x2b8446;if(_0x511338)return _0x51b7a3=_0x511338,_0x1076ce['model']=_[_0x3472b4('0x6c')](db[_0x3472b4('0x61')][_0x3472b4('0x52')]),_0x1076ce[_0x3472b4('0x3f')]=_[_0x3472b4('0x6c')](_0x53704a[_0x3472b4('0x3f')]),_0x1076ce[_0x3472b4('0x73')]=_[_0x3472b4('0x8a')](_0x1076ce['model'],_0x1076ce[_0x3472b4('0x3f')]),_0x5d3d17[_0x3472b4('0x59')]=_[_0x3472b4('0x8a')](_0x1076ce[_0x3472b4('0x4')],qs[_0x3472b4('0x3e')](_0x53704a['query'][_0x3472b4('0x3e')])),_0x5d3d17['attributes']=_0x5d3d17[_0x3472b4('0x59')]['length']?_0x5d3d17[_0x3472b4('0x59')]:_0x1076ce[_0x3472b4('0x4')],_0x5d3d17['order']=qs[_0x3472b4('0x97')](_0x53704a[_0x3472b4('0x3f')][_0x3472b4('0x97')]),_0x5d3d17['where']=qs['filters'](_[_0x3472b4('0x1f')](_0x53704a[_0x3472b4('0x3f')],_0x1076ce[_0x3472b4('0x73')])),_0x53704a[_0x3472b4('0x3f')]['filter']&&(_0x5d3d17[_0x3472b4('0x4b')]=_[_0x3472b4('0x72')](_0x5d3d17[_0x3472b4('0x4b')],{[Op['or']]:_[_0x3472b4('0x63')](_0x5d3d17[_0x3472b4('0x59')],function(_0x3751f7){const _0x39ff51=_0x3472b4,_0x917235={};return _0x917235[_0x3751f7]={[Op[_0x39ff51('0x5f')]]:'%'+_0x53704a[_0x39ff51('0x3f')][_0x39ff51('0x81')]+'%'},_0x917235;})})),_0x5d3d17=_[_0x3472b4('0x72')]({},_0x5d3d17,_0x53704a[_0x3472b4('0xe')]),_0x51b7a3[_0x3472b4('0x7')](_0x5d3d17);})['then'](function(_0x1d7726){const _0x4c8f31=_0x2b8446;if(_0x1d7726)return _0x12304a=_0x1d7726[_0x4c8f31('0x85')],typeof _0x53704a[_0x4c8f31('0x3f')]['nolimit']===_0x4c8f31('0x17')&&(_0x5d3d17[_0x4c8f31('0x5a')]=qs[_0x4c8f31('0x5a')](_0x53704a[_0x4c8f31('0x3f')]['limit']),_0x5d3d17['offset']=qs['offset'](_0x53704a['query'][_0x4c8f31('0x25')])),_0x51b7a3[_0x4c8f31('0x7')](_0x5d3d17);})[_0x2b8446('0x6e')](function(_0x2c0503){if(_0x2c0503)return _0x2c0503?{'count':_0x12304a,'rows':_0x2c0503}:null;})['then'](respondWithResult(_0x34616e,null))[_0x2b8446('0x6a')](handleError(_0x34616e,null));},exports[_0x5d8fb2('0x70')]=function(_0x50c9a6,_0x365ac3){const _0x1dd508=_0x5d8fb2;return _0x50c9a6['body']['id']&&delete _0x50c9a6[_0x1dd508('0x24')]['id'],db[_0x1dd508('0x86')][_0x1dd508('0x35')]({'where':{'id':_0x50c9a6[_0x1dd508('0x82')]['id']}})[_0x1dd508('0x6e')](handleEntityNotFound(_0x365ac3,null))[_0x1dd508('0x6e')](function(_0x244344){const _0x55c2fe=_0x1dd508;if(_0x244344)return _0x50c9a6[_0x55c2fe('0x24')][_0x55c2fe('0x5')]=_0x244344['id'],_0x50c9a6[_0x55c2fe('0x24')][_0x55c2fe('0x4c')]=integrations[_0x55c2fe('0x91')](_0x50c9a6[_0x55c2fe('0x24')][_0x55c2fe('0x75')],_0x50c9a6[_0x55c2fe('0x24')][_0x55c2fe('0x76')]),_0x50c9a6[_0x55c2fe('0x24')][_0x55c2fe('0x7d')]=integrations['getDescriptions'](_0x50c9a6[_0x55c2fe('0x24')][_0x55c2fe('0x75')],_0x50c9a6[_0x55c2fe('0x24')][_0x55c2fe('0x76')]),db[_0x55c2fe('0x61')][_0x55c2fe('0x4a')](_0x50c9a6[_0x55c2fe('0x24')],{'include':[{'model':db['ServicenowField'],'as':_0x55c2fe('0x4c')},{'model':db[_0x55c2fe('0x6')],'as':_0x55c2fe('0x7d')}]});return null;})[_0x1dd508('0x6e')](respondWithResult(_0x365ac3,null))[_0x1dd508('0x6a')](handleError(_0x365ac3,null));},exports[_0x5d8fb2('0x27')]=function(_0x430fbf,_0x5e9611){const _0x511cae=_0x5d8fb2,_0x369035=['made_sla',_0x511cae('0x9e'),_0x511cae('0x15'),_0x511cae('0x23'),_0x511cae('0x51'),_0x511cae('0x12'),_0x511cae('0x67'),_0x511cae('0x34'),_0x511cae('0x99')],_0x489d73=[_0x511cae('0x60'),_0x511cae('0x46'),_0x511cae('0x77'),_0x511cae('0x18'),_0x511cae('0x36'),_0x511cae('0x16'),_0x511cae('0x4f'),_0x511cae('0x9e'),_0x511cae('0x9'),_0x511cae('0x7e'),_0x511cae('0xc'),_0x511cae('0x98'),_0x511cae('0x78'),'user_input',_0x511cae('0x41'),_0x511cae('0x79'),_0x511cae('0x8e'),_0x511cae('0x26'),_0x511cae('0x15'),_0x511cae('0x1a'),_0x511cae('0x5d'),_0x511cae('0x58'),_0x511cae('0x48'),'delivery_plan',_0x511cae('0x50'),_0x511cae('0x1d'),_0x511cae('0x9f'),_0x511cae('0x1'),'priority',_0x511cae('0x5e'),'rfc','time_worked',_0x511cae('0x9d'),'opened_at',_0x511cae('0x57'),'group_list',_0x511cae('0x11'),_0x511cae('0x9b'),_0x511cae('0x3c'),_0x511cae('0x44'),_0x511cae('0xd'),_0x511cae('0x23'),'work_notes',_0x511cae('0x37'),'close_code',_0x511cae('0x2'),'delivery_task',_0x511cae('0x66'),_0x511cae('0x38'),_0x511cae('0x29'),_0x511cae('0x31'),_0x511cae('0x62'),_0x511cae('0x93'),_0x511cae('0x12'),_0x511cae('0x80'),'close_notes',_0x511cae('0x68'),_0x511cae('0xa'),'parent_incident',_0x511cae('0x33'),_0x511cae('0x0'),_0x511cae('0xa0'),_0x511cae('0x67'),'urgency',_0x511cae('0x74'),_0x511cae('0x9c'),_0x511cae('0x3b'),'activity_due','assigned_to',_0x511cae('0x34'),_0x511cae('0xb'),'sla_due',_0x511cae('0x4d'),'comments_and_work_notes','due_date',_0x511cae('0x1c'),'reopen_count',_0x511cae('0x53'),_0x511cae('0x1e'),_0x511cae('0x6f'),_0x511cae('0x92'),_0x511cae('0x3a'),_0x511cae('0x99')];let _0x4e108f='',_0x2403a4='',_0x2295c8=[],_0x340728='',_0x26b837='',_0x194270=[],_0x521ce4='',_0x118ffa='',_0x5c8687={},_0x5b5477='';return db[_0x511cae('0x86')][_0x511cae('0x35')]({'where':{'id':_0x430fbf[_0x511cae('0x82')]['id']},'attributes':['id','username',_0x511cae('0x2c'),_0x511cae('0x42'),'remoteUri',_0x511cae('0x45')]})[_0x511cae('0x6e')](handleEntityNotFound(_0x5e9611,null))[_0x511cae('0x6e')](function(_0x545b0a){const _0x3d3f00=_0x511cae;if(_0x545b0a){_0x5b5477=_0x545b0a[_0x3d3f00('0x3d')];const _0x1595fc=_0x5b5477[_0x3d3f00('0x21')](-0x1);_0x1595fc==='/'&&(_0x5b5477=_0x5b5477[_0x3d3f00('0x6d')](0x0,_0x5b5477[_0x3d3f00('0x69')](_0x1595fc)));_0x118ffa=util[_0x3d3f00('0x7a')]('%s/api/now/doc/table/schema/',_0x5b5477),_0x521ce4=util[_0x3d3f00('0x7a')](_0x3d3f00('0x10'),_0x5b5477),_0x5c8687={'user':_0x545b0a['username'],'pass':_0x545b0a['password']};const _0x4d1ea1={'method':_0x3d3f00('0xa2'),'uri':_0x118ffa+_0x3d3f00('0x20'),'auth':_0x5c8687,'json':!![]};return rp(_0x4d1ea1);}})[_0x511cae('0x6e')](function(_0x139b4d){const _0x5d3bb2=_0x511cae;return _0x139b4d[_0x5d3bb2('0x22')]['length']>0x0&&(_0x4e108f=_0x139b4d[_0x5d3bb2('0x22')]),console[_0x5d3bb2('0x7c')](_0x5d3bb2('0x40'),_0x4e108f),_0x194270=[],_0x2403a4=Object['assign']([],_0x4e108f),_['remove'](_0x2403a4,function(_0x4e6e52){const _0x41b7cf=_0x5d3bb2;return!_0x369035[_0x41b7cf('0x5c')](_0x4e6e52[_0x41b7cf('0x96')]);}),_0x2403a4[_0x5d3bb2('0x56')](function(_0x278c41){const _0x327af9=_0x5d3bb2,_0x48fd00=createFieldObject(_0x521ce4,_0x5c8687,_0x278c41[_0x327af9('0x8')],_0x278c41['name'],_0x278c41[_0x327af9('0x3')],![]);_0x194270[_0x327af9('0x83')](_0x48fd00);}),Promise['all'](_0x194270);})[_0x511cae('0x6e')](function(_0x13d7b9){const _0x3fda07=_0x511cae;return _0x2295c8=_0x13d7b9,_0x340728=Object[_0x3fda07('0x2e')]([],_0x4e108f),console[_0x3fda07('0x7c')](_0x3fda07('0x8c'),_0x4e108f),_[_0x3fda07('0x49')](_0x340728,function(_0x1c25a2){const _0x4f1733=_0x3fda07;return _0x489d73[_0x4f1733('0x5c')](_0x1c25a2[_0x4f1733('0x96')]);}),console[_0x3fda07('0x7c')](_0x3fda07('0xa1'),_0x340728),_0x194270=[],_0x340728['forEach'](function(_0x3b5d04){const _0xc241d1=_0x3fda07,_0x5f6d7c=createFieldObject(_0x521ce4,_0x5c8687,_0x3b5d04[_0xc241d1('0x8')],_0x3b5d04[_0xc241d1('0x96')],_0x3b5d04[_0xc241d1('0x3')],!![]);_0x194270[_0xc241d1('0x83')](_0x5f6d7c);}),Promise[_0x3fda07('0x47')](_0x194270);})['then'](function(_0x29a68b){const _0x80328a=_0x511cae;_0x26b837=_0x29a68b;const _0x10b81b=_0x2295c8[_0x80328a('0x94')](_0x26b837);return{'count':_0x10b81b[_0x80328a('0x85')],'rows':_0x10b81b};})['then'](respondWithResult(_0x5e9611,null))['catch'](function(_0x7d93b6){const _0x5436ea=_0x511cae;console[_0x5436ea('0x7c')](_0x5436ea('0x54')+_0x7d93b6);let _0x263ed6=_0x430fbf['query'][_0x5436ea('0xf')]?0x1f4:_0x7d93b6['statusCode']||0x1f4;logger[_0x5436ea('0x88')](_0x7d93b6[_0x5436ea('0x6b')]),delete _0x7d93b6[_0x5436ea('0x96')],_0x263ed6===0x191&&(_0x263ed6=0x190),_0x5e9611['status'](_0x263ed6)['send'](_0x430fbf[_0x5436ea('0x3f')][_0x5436ea('0xf')]?{'message':_0x5436ea('0x7b'),'statusCode':_0x7d93b6[_0x5436ea('0x87')]}:_0x7d93b6);});};function createFieldObject(_0x55cf0e,_0x59d73d,_0x331824,_0x9d7ed6,_0x575d37,_0x2be354){return new Promise(function(_0x28bd0e){const _0x4c658f=a294_0x126e,_0x15ff91={'id':_0x9d7ed6,'name':_0x575d37,'custom':_0x2be354};if(_0x331824===_0x4c658f('0x89'))_0x15ff91[_0x4c658f('0xe')]=[{'name':_0x4c658f('0x64'),'value':_0x4c658f('0x8d')},{'name':_0x4c658f('0x30'),'value':_0x4c658f('0x95')}],_0x28bd0e(_0x15ff91);else{const _0xf7cf5b={'method':_0x4c658f('0xa2'),'uri':_0x55cf0e+_0x4c658f('0x9a')+_0x9d7ed6,'auth':_0x59d73d,'json':!![]};return rp(_0xf7cf5b)['then'](function(_0x3049f4){const _0x3a98c9=_0x4c658f,_0xb25340=[];_0x3049f4['result'][_0x3a98c9('0x85')]>0x0&&_0x3049f4[_0x3a98c9('0x22')][_0x3a98c9('0x56')](function(_0x1da8d9){const _0x3d99e4=_0x3a98c9;if(_0x1da8d9[_0x3d99e4('0x32')]===_0x3d99e4('0x95')){const _0x53eec1={'name':_0x1da8d9['label'],'value':_0x1da8d9[_0x3d99e4('0x8b')]};_0xb25340[_0x3d99e4('0x83')](_0x53eec1);}}),_0x15ff91[_0x3a98c9('0xe')]=_0xb25340,_0x15ff91['options'][_0x3a98c9('0x85')]>0x0?_0x28bd0e(_0x15ff91):_0x2be354==![]?_0x28bd0e():_0x28bd0e(_0x15ff91);});}});} \ No newline at end of file diff --git a/server/api/intServicenowAccount/intServicenowAccount.model.js b/server/api/intServicenowAccount/intServicenowAccount.model.js index 954558b..d3682ad 100644 --- a/server/api/intServicenowAccount/intServicenowAccount.model.js +++ b/server/api/intServicenowAccount/intServicenowAccount.model.js @@ -1 +1 @@ -const a295_0x4f86=['int_servicenow_accounts','ServicenowAccount','define'];(function(_0x20316f,_0x4f86b5){const _0x8132ea=function(_0x43094f){while(--_0x43094f){_0x20316f['push'](_0x20316f['shift']());}};_0x8132ea(++_0x4f86b5);}(a295_0x4f86,0x14e));const a295_0x8132=function(_0x20316f,_0x4f86b5){_0x20316f=_0x20316f-0x0;let _0x8132ea=a295_0x4f86[_0x20316f];return _0x8132ea;};'use strict';const attributes=require('./intServicenowAccount.attributes');module['exports']=function(_0x43094f){const _0x24b3c4=a295_0x8132,_0x46133a=_0x43094f[_0x24b3c4('0x1')](_0x24b3c4('0x0'),attributes,{'tableName':_0x24b3c4('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x46133a;}; \ No newline at end of file +const a295_0x134a=['exports','ServicenowAccount','define','./intServicenowAccount.attributes','int_servicenow_accounts'];(function(_0x4b3f02,_0x134a42){const _0x1a0856=function(_0x3e684d){while(--_0x3e684d){_0x4b3f02['push'](_0x4b3f02['shift']());}};_0x1a0856(++_0x134a42);}(a295_0x134a,0xf9));const a295_0x1a08=function(_0x4b3f02,_0x134a42){_0x4b3f02=_0x4b3f02-0x0;let _0x1a0856=a295_0x134a[_0x4b3f02];return _0x1a0856;};const _0x191872=a295_0x1a08;'use strict';const attributes=require(_0x191872('0x4'));module[_0x191872('0x1')]=function(_0x3e684d){const _0x2ac423=_0x191872,_0x31c68c=_0x3e684d[_0x2ac423('0x3')](_0x2ac423('0x2'),attributes,{'tableName':_0x2ac423('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x31c68c;}; \ No newline at end of file diff --git a/server/api/intServicenowAccount/intServicenowAccount.rpc.js b/server/api/intServicenowAccount/intServicenowAccount.rpc.js index 223dddf..0ead7b7 100644 --- a/server/api/intServicenowAccount/intServicenowAccount.rpc.js +++ b/server/api/intServicenowAccount/intServicenowAccount.rpc.js @@ -1 +1 @@ -const a296_0x21f0=['error','ShowServicenowAccount','../../mysqldb','lodash','findOne','message','ServicenowAccount','raw','then','map','options','attributes','GetServicenowAccount','stringify','findAll','include','rpc','info','where','catch','model'];(function(_0x4f05bb,_0x21f0de){const _0xb02119=function(_0x23c86f){while(--_0x23c86f){_0x4f05bb['push'](_0x4f05bb['shift']());}};_0xb02119(++_0x21f0de);}(a296_0x21f0,0x190));const a296_0xb021=function(_0x4f05bb,_0x21f0de){_0x4f05bb=_0x4f05bb-0x0;let _0xb02119=a296_0x21f0[_0x4f05bb];return _0xb02119;};const _0x410849=a296_0xb021;'use strict';const _=require(_0x410849('0x2')),db=require(_0x410849('0x1'))['db'],logger=require('../../config/logger')(_0x410849('0xf'));exports[_0x410849('0xb')]=function(_0x23c86f){const _0x35705d=this;return new Promise(function(_0xe5a723,_0x213d82){const _0x9b0e1b=a296_0xb021;return db[_0x9b0e1b('0x5')][_0x9b0e1b('0xd')]({'raw':_0x23c86f[_0x9b0e1b('0x9')]?_0x23c86f[_0x9b0e1b('0x9')]['raw']===undefined?!![]:![]:!![],'where':_0x23c86f[_0x9b0e1b('0x9')]?_0x23c86f[_0x9b0e1b('0x9')][_0x9b0e1b('0x11')]||null:null,'attributes':_0x23c86f['options']?_0x23c86f[_0x9b0e1b('0x9')]['attributes']||null:null,'limit':_0x23c86f[_0x9b0e1b('0x9')]?_0x23c86f[_0x9b0e1b('0x9')]['limit']||null:null,'include':_0x23c86f[_0x9b0e1b('0x9')]?_0x23c86f[_0x9b0e1b('0x9')][_0x9b0e1b('0xe')]?_[_0x9b0e1b('0x8')](_0x23c86f[_0x9b0e1b('0x9')][_0x9b0e1b('0xe')],function(_0x213ebb){const _0x3101f7=_0x9b0e1b;return{'model':db[_0x213ebb[_0x3101f7('0x13')]],'as':_0x213ebb['as'],'attributes':_0x213ebb[_0x3101f7('0xa')],'include':_0x213ebb[_0x3101f7('0xe')]?_[_0x3101f7('0x8')](_0x213ebb[_0x3101f7('0xe')],function(_0x2f6148){return{'model':db[_0x2f6148['model']],'as':_0x2f6148['as'],'attributes':_0x2f6148['attributes'],'include':_0x2f6148['include']?_['map'](_0x2f6148['include'],function(_0x28662d){const _0x2eb350=a296_0xb021;return{'model':db[_0x28662d['model']],'as':_0x28662d['as'],'attributes':_0x28662d[_0x2eb350('0xa')]};}):[]};}):[]};}):[]:[]})[_0x9b0e1b('0x7')](function(_0x296ac5){const _0x46ed9a=_0x9b0e1b;logger[_0x46ed9a('0x10')]('GetServicenowAccount',_0x23c86f),logger['debug']('GetServicenowAccount',_0x23c86f,JSON['stringify'](_0x296ac5)),_0xe5a723(_0x296ac5);})[_0x9b0e1b('0x12')](function(_0x4723f3){const _0x2973f1=_0x9b0e1b;logger[_0x2973f1('0x14')]('GetServicenowAccount',_0x4723f3[_0x2973f1('0x4')],_0x23c86f),_0x213d82(_0x35705d[_0x2973f1('0x14')](0x1f4,_0x4723f3[_0x2973f1('0x4')]));});});},exports[_0x410849('0x0')]=function(_0x118561){const _0x35b0cf=this;return new Promise(function(_0x1bd725,_0x413cfb){const _0x1a436b=a296_0xb021;return db[_0x1a436b('0x5')][_0x1a436b('0x3')]({'raw':_0x118561['options']?_0x118561['options'][_0x1a436b('0x6')]===undefined?!![]:![]:!![],'where':_0x118561[_0x1a436b('0x9')]?_0x118561['options'][_0x1a436b('0x11')]||null:null,'attributes':_0x118561['options']?_0x118561[_0x1a436b('0x9')]['attributes']||null:null,'include':_0x118561[_0x1a436b('0x9')]?_0x118561['options']['include']?_[_0x1a436b('0x8')](_0x118561[_0x1a436b('0x9')][_0x1a436b('0xe')],function(_0x44468a){const _0x4bfeea=_0x1a436b;return{'model':db[_0x44468a['model']],'as':_0x44468a['as'],'attributes':_0x44468a[_0x4bfeea('0xa')],'include':_0x44468a[_0x4bfeea('0xe')]?_['map'](_0x44468a[_0x4bfeea('0xe')],function(_0x1222ef){const _0x21e780=_0x4bfeea;return{'model':db[_0x1222ef[_0x21e780('0x13')]],'as':_0x1222ef['as'],'attributes':_0x1222ef[_0x21e780('0xa')],'include':_0x1222ef[_0x21e780('0xe')]?_[_0x21e780('0x8')](_0x1222ef['include'],function(_0x40ba29){const _0x45abf1=_0x21e780;return{'model':db[_0x40ba29['model']],'as':_0x40ba29['as'],'attributes':_0x40ba29[_0x45abf1('0xa')]};}):[]};}):[]};}):[]:[]})[_0x1a436b('0x7')](function(_0x49269e){const _0x1f7299=_0x1a436b;logger[_0x1f7299('0x10')]('ShowServicenowAccount',_0x118561),logger['debug'](_0x1f7299('0x0'),_0x118561,JSON[_0x1f7299('0xc')](_0x49269e)),_0x1bd725(_0x49269e);})['catch'](function(_0xa5446c){const _0x270967=_0x1a436b;logger[_0x270967('0x14')](_0x270967('0x0'),_0xa5446c[_0x270967('0x4')],_0x118561),_0x413cfb(_0x35b0cf[_0x270967('0x14')](0x1f4,_0xa5446c[_0x270967('0x4')]));});});}; \ No newline at end of file +const a296_0x14b7=['message','where','findOne','info','limit','rpc','then','error','options','model','map','stringify','ShowServicenowAccount','raw','debug','include','GetServicenowAccount','catch','lodash','attributes','../../config/logger','ServicenowAccount'];(function(_0x22626e,_0x14b79f){const _0x1d7c94=function(_0x334d5c){while(--_0x334d5c){_0x22626e['push'](_0x22626e['shift']());}};_0x1d7c94(++_0x14b79f);}(a296_0x14b7,0x152));const a296_0x1d7c=function(_0x22626e,_0x14b79f){_0x22626e=_0x22626e-0x0;let _0x1d7c94=a296_0x14b7[_0x22626e];return _0x1d7c94;};const _0x9791ec=a296_0x1d7c;'use strict';const _=require(_0x9791ec('0xa')),db=require('../../mysqldb')['db'],logger=require(_0x9791ec('0xc'))(_0x9791ec('0x13'));exports['GetServicenowAccount']=function(_0x334d5c){const _0x2af490=this;return new Promise(function(_0x4b072d,_0x41dee7){const _0x320ffa=a296_0x1d7c;return db[_0x320ffa('0xd')]['findAll']({'raw':_0x334d5c[_0x320ffa('0x0')]?_0x334d5c[_0x320ffa('0x0')][_0x320ffa('0x5')]===undefined?!![]:![]:!![],'where':_0x334d5c[_0x320ffa('0x0')]?_0x334d5c[_0x320ffa('0x0')][_0x320ffa('0xf')]||null:null,'attributes':_0x334d5c[_0x320ffa('0x0')]?_0x334d5c['options']['attributes']||null:null,'limit':_0x334d5c['options']?_0x334d5c[_0x320ffa('0x0')][_0x320ffa('0x12')]||null:null,'include':_0x334d5c[_0x320ffa('0x0')]?_0x334d5c[_0x320ffa('0x0')][_0x320ffa('0x7')]?_[_0x320ffa('0x2')](_0x334d5c['options'][_0x320ffa('0x7')],function(_0x1d6a12){const _0x51cee9=_0x320ffa;return{'model':db[_0x1d6a12[_0x51cee9('0x1')]],'as':_0x1d6a12['as'],'attributes':_0x1d6a12['attributes'],'include':_0x1d6a12['include']?_[_0x51cee9('0x2')](_0x1d6a12['include'],function(_0x26485a){const _0xd75a56=_0x51cee9;return{'model':db[_0x26485a[_0xd75a56('0x1')]],'as':_0x26485a['as'],'attributes':_0x26485a[_0xd75a56('0xb')],'include':_0x26485a[_0xd75a56('0x7')]?_['map'](_0x26485a[_0xd75a56('0x7')],function(_0x377a22){const _0x46e3d4=_0xd75a56;return{'model':db[_0x377a22['model']],'as':_0x377a22['as'],'attributes':_0x377a22[_0x46e3d4('0xb')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x107e3c){const _0x33dfc9=_0x320ffa;logger[_0x33dfc9('0x11')](_0x33dfc9('0x8'),_0x334d5c),logger[_0x33dfc9('0x6')](_0x33dfc9('0x8'),_0x334d5c,JSON[_0x33dfc9('0x3')](_0x107e3c)),_0x4b072d(_0x107e3c);})[_0x320ffa('0x9')](function(_0x521240){const _0x3bbddc=_0x320ffa;logger[_0x3bbddc('0x15')](_0x3bbddc('0x8'),_0x521240['message'],_0x334d5c),_0x41dee7(_0x2af490[_0x3bbddc('0x15')](0x1f4,_0x521240['message']));});});},exports['ShowServicenowAccount']=function(_0x4217ed){const _0x1b0950=this;return new Promise(function(_0xaa2898,_0x566390){const _0x30acdf=a296_0x1d7c;return db[_0x30acdf('0xd')][_0x30acdf('0x10')]({'raw':_0x4217ed[_0x30acdf('0x0')]?_0x4217ed[_0x30acdf('0x0')][_0x30acdf('0x5')]===undefined?!![]:![]:!![],'where':_0x4217ed['options']?_0x4217ed[_0x30acdf('0x0')][_0x30acdf('0xf')]||null:null,'attributes':_0x4217ed[_0x30acdf('0x0')]?_0x4217ed[_0x30acdf('0x0')][_0x30acdf('0xb')]||null:null,'include':_0x4217ed['options']?_0x4217ed[_0x30acdf('0x0')][_0x30acdf('0x7')]?_[_0x30acdf('0x2')](_0x4217ed[_0x30acdf('0x0')]['include'],function(_0x5b45ec){const _0x5ddb8f=_0x30acdf;return{'model':db[_0x5b45ec[_0x5ddb8f('0x1')]],'as':_0x5b45ec['as'],'attributes':_0x5b45ec['attributes'],'include':_0x5b45ec[_0x5ddb8f('0x7')]?_['map'](_0x5b45ec['include'],function(_0x4cad4f){const _0x272c1d=_0x5ddb8f;return{'model':db[_0x4cad4f[_0x272c1d('0x1')]],'as':_0x4cad4f['as'],'attributes':_0x4cad4f[_0x272c1d('0xb')],'include':_0x4cad4f[_0x272c1d('0x7')]?_[_0x272c1d('0x2')](_0x4cad4f[_0x272c1d('0x7')],function(_0x5431fb){const _0x1c4ee0=_0x272c1d;return{'model':db[_0x5431fb[_0x1c4ee0('0x1')]],'as':_0x5431fb['as'],'attributes':_0x5431fb[_0x1c4ee0('0xb')]};}):[]};}):[]};}):[]:[]})[_0x30acdf('0x14')](function(_0x405be6){const _0x200628=_0x30acdf;logger[_0x200628('0x11')](_0x200628('0x4'),_0x4217ed),logger[_0x200628('0x6')](_0x200628('0x4'),_0x4217ed,JSON[_0x200628('0x3')](_0x405be6)),_0xaa2898(_0x405be6);})[_0x30acdf('0x9')](function(_0x53115e){const _0x48e69b=_0x30acdf;logger[_0x48e69b('0x15')](_0x48e69b('0x4'),_0x53115e[_0x48e69b('0xe')],_0x4217ed),_0x566390(_0x1b0950['error'](0x1f4,_0x53115e[_0x48e69b('0xe')]));});});}; \ No newline at end of file diff --git a/server/api/intServicenowConfiguration/index.js b/server/api/intServicenowConfiguration/index.js index f10d371..d8689be 100644 --- a/server/api/intServicenowConfiguration/index.js +++ b/server/api/intServicenowConfiguration/index.js @@ -1 +1 @@ -const a297_0x2b30=['/:id/descriptions','getDescriptions','put','../../components/auth/service','get','show','exports','express','isAuthenticated','/:id/subjects','index','getSubjects','update','/:id/fields','delete','destroy','post','/:id','getFields','Router'];(function(_0x1d5c88,_0x2b308f){const _0x4842a7=function(_0x24e79f){while(--_0x24e79f){_0x1d5c88['push'](_0x1d5c88['shift']());}};_0x4842a7(++_0x2b308f);}(a297_0x2b30,0xbb));const a297_0x4842=function(_0x1d5c88,_0x2b308f){_0x1d5c88=_0x1d5c88-0x0;let _0x4842a7=a297_0x2b30[_0x1d5c88];return _0x4842a7;};const _0x4b0fb5=a297_0x4842;'use strict';const express=require(_0x4b0fb5('0x0')),router=express[_0x4b0fb5('0xc')](),auth=require(_0x4b0fb5('0x10')),controller=require('./intServicenowConfiguration.controller');router[_0x4b0fb5('0x11')]('/',auth[_0x4b0fb5('0x1')](),controller[_0x4b0fb5('0x3')]),router[_0x4b0fb5('0x11')](_0x4b0fb5('0xa'),auth[_0x4b0fb5('0x1')](),controller[_0x4b0fb5('0x12')]),router[_0x4b0fb5('0x11')](_0x4b0fb5('0x6'),auth['isAuthenticated'](),controller[_0x4b0fb5('0xb')]),router[_0x4b0fb5('0x11')](_0x4b0fb5('0x2'),auth[_0x4b0fb5('0x1')](),controller[_0x4b0fb5('0x4')]),router[_0x4b0fb5('0x11')](_0x4b0fb5('0xd'),auth['isAuthenticated'](),controller[_0x4b0fb5('0xe')]),router[_0x4b0fb5('0x9')]('/',auth['isAuthenticated'](),controller['create']),router[_0x4b0fb5('0xf')](_0x4b0fb5('0xa'),auth[_0x4b0fb5('0x1')](),controller[_0x4b0fb5('0x5')]),router[_0x4b0fb5('0x7')](_0x4b0fb5('0xa'),auth['isAuthenticated'](),controller[_0x4b0fb5('0x8')]),module[_0x4b0fb5('0x13')]=router; \ No newline at end of file +const a297_0x53d3=['./intServicenowConfiguration.controller','post','isAuthenticated','/:id','get','getSubjects','getDescriptions','../../components/auth/service','express','put','create','/:id/subjects','index','exports','delete','/:id/descriptions','Router','show'];(function(_0x3ba9f3,_0x53d31c){const _0x5aa14c=function(_0x45fd17){while(--_0x45fd17){_0x3ba9f3['push'](_0x3ba9f3['shift']());}};_0x5aa14c(++_0x53d31c);}(a297_0x53d3,0xde));const a297_0x5aa1=function(_0x3ba9f3,_0x53d31c){_0x3ba9f3=_0x3ba9f3-0x0;let _0x5aa14c=a297_0x53d3[_0x3ba9f3];return _0x5aa14c;};const _0x478b10=a297_0x5aa1;'use strict';const express=require(_0x478b10('0x2')),router=express[_0x478b10('0xa')](),auth=require(_0x478b10('0x1')),controller=require(_0x478b10('0xc'));router[_0x478b10('0x10')]('/',auth[_0x478b10('0xe')](),controller[_0x478b10('0x6')]),router[_0x478b10('0x10')](_0x478b10('0xf'),auth['isAuthenticated'](),controller[_0x478b10('0xb')]),router[_0x478b10('0x10')]('/:id/fields',auth[_0x478b10('0xe')](),controller['getFields']),router[_0x478b10('0x10')](_0x478b10('0x5'),auth['isAuthenticated'](),controller[_0x478b10('0x11')]),router['get'](_0x478b10('0x9'),auth[_0x478b10('0xe')](),controller[_0x478b10('0x0')]),router[_0x478b10('0xd')]('/',auth['isAuthenticated'](),controller[_0x478b10('0x4')]),router[_0x478b10('0x3')](_0x478b10('0xf'),auth['isAuthenticated'](),controller['update']),router[_0x478b10('0x8')](_0x478b10('0xf'),auth[_0x478b10('0xe')](),controller['destroy']),module[_0x478b10('0x7')]=router; \ No newline at end of file diff --git a/server/api/intServicenowConfiguration/intServicenowConfiguration.attributes.js b/server/api/intServicenowConfiguration/intServicenowConfiguration.attributes.js index 60369ea..c500928 100644 --- a/server/api/intServicenowConfiguration/intServicenowConfiguration.attributes.js +++ b/server/api/intServicenowConfiguration/intServicenowConfiguration.attributes.js @@ -1 +1 @@ -const a298_0x589f=['sequelize','STRING','exports'];(function(_0x260fc9,_0x589f2a){const _0x208555=function(_0x3881eb){while(--_0x3881eb){_0x260fc9['push'](_0x260fc9['shift']());}};_0x208555(++_0x589f2a);}(a298_0x589f,0x15e));const a298_0x2085=function(_0x260fc9,_0x589f2a){_0x260fc9=_0x260fc9-0x0;let _0x208555=a298_0x589f[_0x260fc9];return _0x208555;};const _0x5371d8=a298_0x2085;'use strict';const Sequelize=require(_0x5371d8('0x1'));module[_0x5371d8('0x0')]={'name':{'type':Sequelize[_0x5371d8('0x2')]},'description':{'type':Sequelize[_0x5371d8('0x2')]}}; \ No newline at end of file +const a298_0x445f=['STRING','sequelize','exports'];(function(_0x2103d8,_0x445fc6){const _0x1da917=function(_0x1a1126){while(--_0x1a1126){_0x2103d8['push'](_0x2103d8['shift']());}};_0x1da917(++_0x445fc6);}(a298_0x445f,0x128));const a298_0x1da9=function(_0x2103d8,_0x445fc6){_0x2103d8=_0x2103d8-0x0;let _0x1da917=a298_0x445f[_0x2103d8];return _0x1da917;};const _0x459f2a=a298_0x1da9;'use strict';const Sequelize=require(_0x459f2a('0x2'));module[_0x459f2a('0x0')]={'name':{'type':Sequelize[_0x459f2a('0x1')]},'description':{'type':Sequelize[_0x459f2a('0x1')]}}; \ No newline at end of file diff --git a/server/api/intServicenowConfiguration/intServicenowConfiguration.controller.js b/server/api/intServicenowConfiguration/intServicenowConfiguration.controller.js index b9675cf..a8aea3f 100644 --- a/server/api/intServicenowConfiguration/intServicenowConfiguration.controller.js +++ b/server/api/intServicenowConfiguration/intServicenowConfiguration.controller.js @@ -1 +1 @@ -const a299_0x42a9=['query','options','create','set','filters','stack','update','../../components/parsers/qs','where','show','fieldName','model','length','params','api','lodash','rawAttributes','getDescriptions','findOne','sort','error','count','like','status','destroy','undefined','merge','rows','name','order','getFields','sequelize','VIRTUAL','includeAll','filter','getSubjects','keys','catch','send','limit','type','../../mysqldb','findAll','fields','pick','intersection','offset','ServicenowConfiguration','attributes','json','key','nolimit','body','then','include','map','ServicenowField','end'];(function(_0x44bbf2,_0x42a9e9){const _0x3cd2aa=function(_0x52d498){while(--_0x52d498){_0x44bbf2['push'](_0x44bbf2['shift']());}};_0x3cd2aa(++_0x42a9e9);}(a299_0x42a9,0x1c9));const a299_0x3cd2=function(_0x44bbf2,_0x42a9e9){_0x44bbf2=_0x44bbf2-0x0;let _0x3cd2aa=a299_0x42a9[_0x44bbf2];return _0x3cd2aa;};const _0x136837=a299_0x3cd2;'use strict';const _=require(_0x136837('0x16')),qs=require(_0x136837('0xe')),logger=require('../../config/logger')(_0x136837('0x15')),db=require(_0x136837('0x30'))['db'],{Op}=require(_0x136837('0x26'));function respondWithResult(_0x52d498,_0x6035d0){return _0x6035d0=_0x6035d0||0xc8,function(_0xbd0922){const _0x234ee8=a299_0x3cd2;if(_0xbd0922)return _0x52d498[_0x234ee8('0x1e')](_0x6035d0)['json'](_0xbd0922);};}function respondWithFilteredResult(_0x5cdc49,_0x1b4c58){return function(_0x3ca01b){const _0x2ff86c=a299_0x3cd2;if(_0x3ca01b){const _0x36a3d2=_0x3ca01b[_0x2ff86c('0x1c')],_0x547dba=_0x1b4c58['offset'];let _0x188a0a=_0x1b4c58['offset']+_0x1b4c58[_0x2ff86c('0x2e')],_0x1c97f6;return _0x188a0a>=_0x36a3d2?(_0x188a0a=_0x36a3d2,_0x1c97f6=0xc8):_0x1c97f6=0xce,_0x5cdc49[_0x2ff86c('0x1e')](_0x1c97f6),_0x5cdc49[_0x2ff86c('0xa')]('Content-Range',_0x547dba+'-'+_0x188a0a+'/'+_0x36a3d2)[_0x2ff86c('0x38')](_0x3ca01b);}return null;};}function saveUpdates(_0xfc346){return function(_0x3ec6ca){const _0x1fcc75=a299_0x3cd2;if(_0x3ec6ca)return _0x3ec6ca[_0x1fcc75('0xd')](_0xfc346)[_0x1fcc75('0x2')](function(_0x5c1ec6){return _0x5c1ec6;});return null;};}function removeEntity(_0x391954){return function(_0x1965af){const _0x1b66c1=a299_0x3cd2;if(_0x1965af)return _0x1965af[_0x1b66c1('0x1f')]()['then'](function(){const _0x49dbf4=_0x1b66c1;_0x391954[_0x49dbf4('0x1e')](0xcc)[_0x49dbf4('0x6')]();});};}function handleEntityNotFound(_0x4dec34){return function(_0x353f2c){return!_0x353f2c&&_0x4dec34['sendStatus'](0x194),_0x353f2c;};}function handleError(_0x1156a8,_0x2ba5d0){return _0x2ba5d0=_0x2ba5d0||0x1f4,function(_0x5538f7){const _0x1ecee5=a299_0x3cd2;logger[_0x1ecee5('0x1b')](_0x5538f7[_0x1ecee5('0xc')]),_0x5538f7[_0x1ecee5('0x23')]&&delete _0x5538f7[_0x1ecee5('0x23')],_0x1156a8[_0x1ecee5('0x1e')](_0x2ba5d0)[_0x1ecee5('0x2d')](_0x5538f7);};}exports['index']=function(_0x106bc4,_0x23e962){const _0x4dcaa1=_0x136837;let _0x2b429d={};const _0xf3f79b={},_0x4f3e5c={'count':0x0,'rows':[]},_0x289b70=_[_0x4dcaa1('0x4')](db[_0x4dcaa1('0x36')][_0x4dcaa1('0x17')],function(_0x3366d2){const _0x48725b=_0x4dcaa1;return{'name':_0x3366d2[_0x48725b('0x11')],'type':_0x3366d2[_0x48725b('0x2f')][_0x48725b('0x39')]};});_0xf3f79b[_0x4dcaa1('0x12')]=_[_0x4dcaa1('0x4')](_0x289b70,'name'),_0xf3f79b['query']=_[_0x4dcaa1('0x2b')](_0x106bc4[_0x4dcaa1('0x7')]),_0xf3f79b['filters']=_[_0x4dcaa1('0x34')](_0xf3f79b['model'],_0xf3f79b['query']),_0x2b429d[_0x4dcaa1('0x37')]=_[_0x4dcaa1('0x34')](_0xf3f79b[_0x4dcaa1('0x12')],qs[_0x4dcaa1('0x32')](_0x106bc4[_0x4dcaa1('0x7')][_0x4dcaa1('0x32')])),_0x2b429d[_0x4dcaa1('0x37')]=_0x2b429d[_0x4dcaa1('0x37')]['length']?_0x2b429d[_0x4dcaa1('0x37')]:_0xf3f79b[_0x4dcaa1('0x12')];typeof _0x106bc4[_0x4dcaa1('0x7')]['nolimit']===_0x4dcaa1('0x20')&&(_0x2b429d[_0x4dcaa1('0x2e')]=qs[_0x4dcaa1('0x2e')](_0x106bc4[_0x4dcaa1('0x7')]['limit']),_0x2b429d[_0x4dcaa1('0x35')]=qs['offset'](_0x106bc4[_0x4dcaa1('0x7')][_0x4dcaa1('0x35')]));_0x2b429d[_0x4dcaa1('0x24')]=qs[_0x4dcaa1('0x1a')](_0x106bc4[_0x4dcaa1('0x7')][_0x4dcaa1('0x1a')]),_0x2b429d['where']=qs['filters'](_['pick'](_0x106bc4['query'],_0xf3f79b[_0x4dcaa1('0xb')]),_0x289b70);_0x106bc4[_0x4dcaa1('0x7')]['filter']&&(_0x2b429d[_0x4dcaa1('0xf')]=_['merge'](_0x2b429d['where'],{[Op['or']]:_[_0x4dcaa1('0x4')](_0x289b70,function(_0x1c4699){const _0x227d32=_0x4dcaa1;if(_0x1c4699['type']!==_0x227d32('0x27')){const _0x46f317={};return _0x46f317[_0x1c4699[_0x227d32('0x23')]]={[Op[_0x227d32('0x1d')]]:'%'+_0x106bc4[_0x227d32('0x7')]['filter']+'%'},_0x46f317;}})}));_0x2b429d=_['merge']({},_0x2b429d,_0x106bc4[_0x4dcaa1('0x8')]);const _0x5b87e7={'where':_0x2b429d['where']};return db[_0x4dcaa1('0x36')][_0x4dcaa1('0x1c')](_0x5b87e7)[_0x4dcaa1('0x2')](function(_0x5cdfac){const _0x3ced63=_0x4dcaa1;return _0x4f3e5c['count']=_0x5cdfac,_0x106bc4[_0x3ced63('0x7')][_0x3ced63('0x28')]&&(_0x2b429d['include']=[{'all':!![]}]),db['ServicenowConfiguration'][_0x3ced63('0x31')](_0x2b429d);})[_0x4dcaa1('0x2')](function(_0x551f32){const _0x5ebfa0=_0x4dcaa1;return _0x4f3e5c[_0x5ebfa0('0x22')]=_0x551f32,_0x4f3e5c;})[_0x4dcaa1('0x2')](respondWithFilteredResult(_0x23e962,_0x2b429d))['catch'](handleError(_0x23e962,null));},exports[_0x136837('0x10')]=function(_0x41b3be,_0xd83f5){const _0x25f306=_0x136837;let _0x405da9={'raw':![],'where':{'id':_0x41b3be[_0x25f306('0x14')]['id']}};const _0x100228={};return _0x100228[_0x25f306('0x12')]=_[_0x25f306('0x2b')](db[_0x25f306('0x36')][_0x25f306('0x17')]),_0x100228[_0x25f306('0x7')]=_[_0x25f306('0x2b')](_0x41b3be['query']),_0x100228[_0x25f306('0xb')]=_['intersection'](_0x100228[_0x25f306('0x12')],_0x100228[_0x25f306('0x7')]),_0x405da9[_0x25f306('0x37')]=_[_0x25f306('0x34')](_0x100228[_0x25f306('0x12')],qs[_0x25f306('0x32')](_0x41b3be[_0x25f306('0x7')][_0x25f306('0x32')])),_0x405da9[_0x25f306('0x37')]=_0x405da9['attributes']['length']?_0x405da9[_0x25f306('0x37')]:_0x100228[_0x25f306('0x12')],_0x41b3be[_0x25f306('0x7')][_0x25f306('0x28')]&&(_0x405da9[_0x25f306('0x3')]=[{'all':!![]}]),_0x405da9=_[_0x25f306('0x21')]({},_0x405da9,_0x41b3be[_0x25f306('0x8')]),db[_0x25f306('0x36')][_0x25f306('0x19')](_0x405da9)[_0x25f306('0x2')](handleEntityNotFound(_0xd83f5,null))[_0x25f306('0x2')](respondWithResult(_0xd83f5,null))[_0x25f306('0x2c')](handleError(_0xd83f5,null));},exports[_0x136837('0x9')]=function(_0x34a76d,_0x2ecf12){const _0xe54086=_0x136837;return db[_0xe54086('0x36')][_0xe54086('0x9')](_0x34a76d[_0xe54086('0x1')],{})[_0xe54086('0x2')](respondWithResult(_0x2ecf12,0xc9))['catch'](handleError(_0x2ecf12,null));},exports[_0x136837('0xd')]=function(_0x5945e3,_0x58f9a7){const _0x544377=_0x136837;return _0x5945e3['body']['id']&&delete _0x5945e3[_0x544377('0x1')]['id'],db[_0x544377('0x36')][_0x544377('0x19')]({'where':{'id':_0x5945e3[_0x544377('0x14')]['id']}})['then'](handleEntityNotFound(_0x58f9a7,null))[_0x544377('0x2')](saveUpdates(_0x5945e3['body'],null))[_0x544377('0x2')](respondWithResult(_0x58f9a7,null))['catch'](handleError(_0x58f9a7,null));},exports[_0x136837('0x1f')]=function(_0x3e3bfe,_0x1899a0){const _0x1331da=_0x136837;return db[_0x1331da('0x36')][_0x1331da('0x19')]({'where':{'id':_0x3e3bfe[_0x1331da('0x14')]['id']}})['then'](handleEntityNotFound(_0x1899a0,null))[_0x1331da('0x2')](removeEntity(_0x1899a0,null))[_0x1331da('0x2c')](handleError(_0x1899a0,null));},exports[_0x136837('0x25')]=function(_0x449348,_0x2e9a0e){const _0x1efc4c=_0x136837;let _0x4894f1={};const _0x216729={};let _0x13510d,_0x3b739b;return db['ServicenowConfiguration'][_0x1efc4c('0x19')]({'where':{'id':_0x449348['params']['id']}})['then'](handleEntityNotFound(_0x2e9a0e,null))[_0x1efc4c('0x2')](function(_0x2b70a5){const _0x867ba4=_0x1efc4c;if(_0x2b70a5)return _0x13510d=_0x2b70a5,_0x216729['model']=_[_0x867ba4('0x2b')](db['ServicenowField']['rawAttributes']),_0x216729[_0x867ba4('0x7')]=_[_0x867ba4('0x2b')](_0x449348[_0x867ba4('0x7')]),_0x216729[_0x867ba4('0xb')]=_[_0x867ba4('0x34')](_0x216729['model'],_0x216729[_0x867ba4('0x7')]),_0x4894f1[_0x867ba4('0x37')]=_['intersection'](_0x216729[_0x867ba4('0x12')],qs[_0x867ba4('0x32')](_0x449348['query'][_0x867ba4('0x32')])),_0x4894f1[_0x867ba4('0x37')]=_0x4894f1[_0x867ba4('0x37')][_0x867ba4('0x13')]?_0x4894f1[_0x867ba4('0x37')]:_0x216729[_0x867ba4('0x12')],_0x4894f1[_0x867ba4('0x24')]=qs[_0x867ba4('0x1a')](_0x449348[_0x867ba4('0x7')][_0x867ba4('0x1a')]),_0x4894f1['where']=qs['filters'](_[_0x867ba4('0x33')](_0x449348[_0x867ba4('0x7')],_0x216729[_0x867ba4('0xb')])),_0x449348[_0x867ba4('0x7')][_0x867ba4('0x29')]&&(_0x4894f1['where']=_['merge'](_0x4894f1[_0x867ba4('0xf')],{[Op['or']]:_[_0x867ba4('0x4')](_0x4894f1[_0x867ba4('0x37')],function(_0x1c181a){const _0x2dc591=_0x867ba4,_0x45838a={};return _0x45838a[_0x1c181a]={[Op[_0x2dc591('0x1d')]]:'%'+_0x449348[_0x2dc591('0x7')]['filter']+'%'},_0x45838a;})})),_0x4894f1=_[_0x867ba4('0x21')]({},_0x4894f1,_0x449348[_0x867ba4('0x8')]),_0x13510d[_0x867ba4('0x25')](_0x4894f1);})[_0x1efc4c('0x2')](function(_0x29bf93){const _0x33f74b=_0x1efc4c;if(_0x29bf93)return _0x3b739b=_0x29bf93[_0x33f74b('0x13')],typeof _0x449348[_0x33f74b('0x7')][_0x33f74b('0x0')]===_0x33f74b('0x20')&&(_0x4894f1[_0x33f74b('0x2e')]=qs[_0x33f74b('0x2e')](_0x449348[_0x33f74b('0x7')]['limit']),_0x4894f1[_0x33f74b('0x35')]=qs[_0x33f74b('0x35')](_0x449348[_0x33f74b('0x7')][_0x33f74b('0x35')])),_0x13510d['getFields'](_0x4894f1);})[_0x1efc4c('0x2')](function(_0x4239cd){if(_0x4239cd)return _0x4239cd?{'count':_0x3b739b,'rows':_0x4239cd}:null;})[_0x1efc4c('0x2')](respondWithResult(_0x2e9a0e,null))[_0x1efc4c('0x2c')](handleError(_0x2e9a0e,null));},exports['getSubjects']=function(_0xd5110f,_0x5ee5dd){const _0x509258=_0x136837;let _0x563071={};const _0x32004b={};let _0x556b84,_0x7f17ba;return db[_0x509258('0x36')]['findOne']({'where':{'id':_0xd5110f[_0x509258('0x14')]['id']}})[_0x509258('0x2')](handleEntityNotFound(_0x5ee5dd,null))['then'](function(_0x3126f7){const _0x9e0814=_0x509258;if(_0x3126f7)return _0x556b84=_0x3126f7,_0x32004b['model']=_[_0x9e0814('0x2b')](db[_0x9e0814('0x5')][_0x9e0814('0x17')]),_0x32004b[_0x9e0814('0x7')]=_['keys'](_0xd5110f['query']),_0x32004b[_0x9e0814('0xb')]=_[_0x9e0814('0x34')](_0x32004b['model'],_0x32004b[_0x9e0814('0x7')]),_0x563071['attributes']=_[_0x9e0814('0x34')](_0x32004b['model'],qs[_0x9e0814('0x32')](_0xd5110f['query']['fields'])),_0x563071[_0x9e0814('0x37')]=_0x563071[_0x9e0814('0x37')][_0x9e0814('0x13')]?_0x563071[_0x9e0814('0x37')]:_0x32004b[_0x9e0814('0x12')],_0x563071['order']=qs[_0x9e0814('0x1a')](_0xd5110f[_0x9e0814('0x7')][_0x9e0814('0x1a')]),_0x563071[_0x9e0814('0xf')]=qs[_0x9e0814('0xb')](_[_0x9e0814('0x33')](_0xd5110f['query'],_0x32004b[_0x9e0814('0xb')])),_0xd5110f[_0x9e0814('0x7')][_0x9e0814('0x29')]&&(_0x563071[_0x9e0814('0xf')]=_[_0x9e0814('0x21')](_0x563071[_0x9e0814('0xf')],{[Op['or']]:_[_0x9e0814('0x4')](_0x563071[_0x9e0814('0x37')],function(_0x3c5cbf){const _0x95a0bd=_0x9e0814,_0x48d42c={};return _0x48d42c[_0x3c5cbf]={[Op[_0x95a0bd('0x1d')]]:'%'+_0xd5110f[_0x95a0bd('0x7')][_0x95a0bd('0x29')]+'%'},_0x48d42c;})})),_0x563071=_[_0x9e0814('0x21')]({},_0x563071,_0xd5110f[_0x9e0814('0x8')]),_0x556b84[_0x9e0814('0x2a')](_0x563071);})[_0x509258('0x2')](function(_0x8c564b){const _0x4d1f38=_0x509258;if(_0x8c564b)return _0x7f17ba=_0x8c564b[_0x4d1f38('0x13')],typeof _0xd5110f[_0x4d1f38('0x7')][_0x4d1f38('0x0')]===_0x4d1f38('0x20')&&(_0x563071['limit']=qs[_0x4d1f38('0x2e')](_0xd5110f[_0x4d1f38('0x7')][_0x4d1f38('0x2e')]),_0x563071['offset']=qs[_0x4d1f38('0x35')](_0xd5110f[_0x4d1f38('0x7')][_0x4d1f38('0x35')])),_0x556b84[_0x4d1f38('0x2a')](_0x563071);})[_0x509258('0x2')](function(_0x207d80){if(_0x207d80)return _0x207d80?{'count':_0x7f17ba,'rows':_0x207d80}:null;})[_0x509258('0x2')](respondWithResult(_0x5ee5dd,null))['catch'](handleError(_0x5ee5dd,null));},exports[_0x136837('0x18')]=function(_0x121e39,_0x20db5e){const _0x47ed6e=_0x136837;let _0x1735f2={};const _0x5fe7b6={};let _0x253f5c,_0x27800f;return db[_0x47ed6e('0x36')][_0x47ed6e('0x19')]({'where':{'id':_0x121e39['params']['id']}})[_0x47ed6e('0x2')](handleEntityNotFound(_0x20db5e,null))[_0x47ed6e('0x2')](function(_0x52f600){const _0x5da778=_0x47ed6e;if(_0x52f600)return _0x253f5c=_0x52f600,_0x5fe7b6[_0x5da778('0x12')]=_[_0x5da778('0x2b')](db[_0x5da778('0x5')][_0x5da778('0x17')]),_0x5fe7b6[_0x5da778('0x7')]=_['keys'](_0x121e39['query']),_0x5fe7b6['filters']=_[_0x5da778('0x34')](_0x5fe7b6[_0x5da778('0x12')],_0x5fe7b6[_0x5da778('0x7')]),_0x1735f2[_0x5da778('0x37')]=_['intersection'](_0x5fe7b6[_0x5da778('0x12')],qs[_0x5da778('0x32')](_0x121e39[_0x5da778('0x7')][_0x5da778('0x32')])),_0x1735f2[_0x5da778('0x37')]=_0x1735f2[_0x5da778('0x37')]['length']?_0x1735f2['attributes']:_0x5fe7b6['model'],_0x1735f2[_0x5da778('0x24')]=qs[_0x5da778('0x1a')](_0x121e39[_0x5da778('0x7')][_0x5da778('0x1a')]),_0x1735f2[_0x5da778('0xf')]=qs[_0x5da778('0xb')](_[_0x5da778('0x33')](_0x121e39[_0x5da778('0x7')],_0x5fe7b6[_0x5da778('0xb')])),_0x121e39[_0x5da778('0x7')][_0x5da778('0x29')]&&(_0x1735f2[_0x5da778('0xf')]=_['merge'](_0x1735f2['where'],{[Op['or']]:_[_0x5da778('0x4')](_0x1735f2[_0x5da778('0x37')],function(_0x38d28f){const _0x593822=_0x5da778,_0x45c4a9={};return _0x45c4a9[_0x38d28f]={[Op[_0x593822('0x1d')]]:'%'+_0x121e39[_0x593822('0x7')]['filter']+'%'},_0x45c4a9;})})),_0x1735f2=_[_0x5da778('0x21')]({},_0x1735f2,_0x121e39[_0x5da778('0x8')]),_0x253f5c['getDescriptions'](_0x1735f2);})[_0x47ed6e('0x2')](function(_0x60017c){const _0x290495=_0x47ed6e;if(_0x60017c)return _0x27800f=_0x60017c[_0x290495('0x13')],typeof _0x121e39[_0x290495('0x7')][_0x290495('0x0')]===_0x290495('0x20')&&(_0x1735f2['limit']=qs['limit'](_0x121e39[_0x290495('0x7')]['limit']),_0x1735f2[_0x290495('0x35')]=qs[_0x290495('0x35')](_0x121e39[_0x290495('0x7')]['offset'])),_0x253f5c[_0x290495('0x18')](_0x1735f2);})['then'](function(_0x28c64f){if(_0x28c64f)return _0x28c64f?{'count':_0x27800f,'rows':_0x28c64f}:null;})['then'](respondWithResult(_0x20db5e,null))['catch'](handleError(_0x20db5e,null));}; \ No newline at end of file +const a299_0x57f7=['set','lodash','attributes','update','fieldName','intersection','then','includeAll','json','sort','show','merge','api','query','getSubjects','order','name','count','create','map','sequelize','body','length','undefined','include','error','limit','filter','options','like','status','ServicenowConfiguration','../../components/parsers/qs','Content-Range','findOne','type','nolimit','getDescriptions','rawAttributes','keys','end','offset','catch','filters','destroy','where','model','../../config/logger','ServicenowField','pick','fields','getFields','VIRTUAL','findAll','params','send','../../mysqldb'];(function(_0xbc1216,_0x57f77a){const _0x54a961=function(_0x3cf0e2){while(--_0x3cf0e2){_0xbc1216['push'](_0xbc1216['shift']());}};_0x54a961(++_0x57f77a);}(a299_0x57f7,0x105));const a299_0x54a9=function(_0xbc1216,_0x57f77a){_0xbc1216=_0xbc1216-0x0;let _0x54a961=a299_0x57f7[_0xbc1216];return _0x54a961;};const _0x41cb8e=a299_0x54a9;'use strict';const _=require(_0x41cb8e('0x19')),qs=require(_0x41cb8e('0x38')),logger=require(_0x41cb8e('0xe'))(_0x41cb8e('0x24')),db=require(_0x41cb8e('0x17'))['db'],{Op}=require(_0x41cb8e('0x2c'));function respondWithResult(_0x3cf0e2,_0x2e9337){return _0x2e9337=_0x2e9337||0xc8,function(_0xa93d06){const _0x123a43=a299_0x54a9;if(_0xa93d06)return _0x3cf0e2[_0x123a43('0x36')](_0x2e9337)[_0x123a43('0x20')](_0xa93d06);};}function respondWithFilteredResult(_0xa2b8,_0x84a4d1){return function(_0x349dee){const _0x1b9679=a299_0x54a9;if(_0x349dee){const _0x55a11a=_0x349dee[_0x1b9679('0x29')],_0x111cc6=_0x84a4d1[_0x1b9679('0x8')];let _0x45a9d5=_0x84a4d1[_0x1b9679('0x8')]+_0x84a4d1[_0x1b9679('0x32')],_0x59c993;return _0x45a9d5>=_0x55a11a?(_0x45a9d5=_0x55a11a,_0x59c993=0xc8):_0x59c993=0xce,_0xa2b8[_0x1b9679('0x36')](_0x59c993),_0xa2b8[_0x1b9679('0x18')](_0x1b9679('0x0'),_0x111cc6+'-'+_0x45a9d5+'/'+_0x55a11a)[_0x1b9679('0x20')](_0x349dee);}return null;};}function saveUpdates(_0xfc39f8){return function(_0x368daf){const _0x33207a=a299_0x54a9;if(_0x368daf)return _0x368daf[_0x33207a('0x1b')](_0xfc39f8)[_0x33207a('0x1e')](function(_0x35d83a){return _0x35d83a;});return null;};}function removeEntity(_0x83e78f){return function(_0x265ae2){const _0x80f94c=a299_0x54a9;if(_0x265ae2)return _0x265ae2[_0x80f94c('0xb')]()[_0x80f94c('0x1e')](function(){const _0x345282=_0x80f94c;_0x83e78f[_0x345282('0x36')](0xcc)[_0x345282('0x7')]();});};}function handleEntityNotFound(_0x38302b){return function(_0x529917){return!_0x529917&&_0x38302b['sendStatus'](0x194),_0x529917;};}function handleError(_0x3eb53a,_0x102419){return _0x102419=_0x102419||0x1f4,function(_0x4ee914){const _0x25eb66=a299_0x54a9;logger[_0x25eb66('0x31')](_0x4ee914['stack']),_0x4ee914[_0x25eb66('0x28')]&&delete _0x4ee914['name'],_0x3eb53a['status'](_0x102419)[_0x25eb66('0x16')](_0x4ee914);};}exports['index']=function(_0x1033d6,_0x112887){const _0x13f6e8=_0x41cb8e;let _0x3ab733={};const _0x127f94={},_0x2f8f8d={'count':0x0,'rows':[]},_0x27446f=_[_0x13f6e8('0x2b')](db[_0x13f6e8('0x37')]['rawAttributes'],function(_0x3fd15b){const _0x1f5cb4=_0x13f6e8;return{'name':_0x3fd15b[_0x1f5cb4('0x1c')],'type':_0x3fd15b[_0x1f5cb4('0x2')]['key']};});_0x127f94[_0x13f6e8('0xd')]=_[_0x13f6e8('0x2b')](_0x27446f,_0x13f6e8('0x28')),_0x127f94[_0x13f6e8('0x25')]=_['keys'](_0x1033d6[_0x13f6e8('0x25')]),_0x127f94[_0x13f6e8('0xa')]=_[_0x13f6e8('0x1d')](_0x127f94['model'],_0x127f94[_0x13f6e8('0x25')]),_0x3ab733[_0x13f6e8('0x1a')]=_[_0x13f6e8('0x1d')](_0x127f94['model'],qs[_0x13f6e8('0x11')](_0x1033d6[_0x13f6e8('0x25')][_0x13f6e8('0x11')])),_0x3ab733[_0x13f6e8('0x1a')]=_0x3ab733[_0x13f6e8('0x1a')][_0x13f6e8('0x2e')]?_0x3ab733[_0x13f6e8('0x1a')]:_0x127f94[_0x13f6e8('0xd')];typeof _0x1033d6['query'][_0x13f6e8('0x3')]==='undefined'&&(_0x3ab733[_0x13f6e8('0x32')]=qs[_0x13f6e8('0x32')](_0x1033d6[_0x13f6e8('0x25')][_0x13f6e8('0x32')]),_0x3ab733[_0x13f6e8('0x8')]=qs[_0x13f6e8('0x8')](_0x1033d6[_0x13f6e8('0x25')][_0x13f6e8('0x8')]));_0x3ab733['order']=qs['sort'](_0x1033d6[_0x13f6e8('0x25')][_0x13f6e8('0x21')]),_0x3ab733['where']=qs[_0x13f6e8('0xa')](_['pick'](_0x1033d6[_0x13f6e8('0x25')],_0x127f94[_0x13f6e8('0xa')]),_0x27446f);_0x1033d6[_0x13f6e8('0x25')]['filter']&&(_0x3ab733[_0x13f6e8('0xc')]=_['merge'](_0x3ab733[_0x13f6e8('0xc')],{[Op['or']]:_[_0x13f6e8('0x2b')](_0x27446f,function(_0x4a5572){const _0x58688d=_0x13f6e8;if(_0x4a5572[_0x58688d('0x2')]!==_0x58688d('0x13')){const _0x20c3f8={};return _0x20c3f8[_0x4a5572[_0x58688d('0x28')]]={[Op['like']]:'%'+_0x1033d6[_0x58688d('0x25')][_0x58688d('0x33')]+'%'},_0x20c3f8;}})}));_0x3ab733=_['merge']({},_0x3ab733,_0x1033d6[_0x13f6e8('0x34')]);const _0x20ba78={'where':_0x3ab733[_0x13f6e8('0xc')]};return db[_0x13f6e8('0x37')][_0x13f6e8('0x29')](_0x20ba78)['then'](function(_0x2b67c6){const _0x2d360e=_0x13f6e8;return _0x2f8f8d['count']=_0x2b67c6,_0x1033d6[_0x2d360e('0x25')][_0x2d360e('0x1f')]&&(_0x3ab733[_0x2d360e('0x30')]=[{'all':!![]}]),db['ServicenowConfiguration'][_0x2d360e('0x14')](_0x3ab733);})[_0x13f6e8('0x1e')](function(_0xae414a){return _0x2f8f8d['rows']=_0xae414a,_0x2f8f8d;})[_0x13f6e8('0x1e')](respondWithFilteredResult(_0x112887,_0x3ab733))[_0x13f6e8('0x9')](handleError(_0x112887,null));},exports[_0x41cb8e('0x22')]=function(_0x209b26,_0x1435af){const _0x41a08f=_0x41cb8e;let _0x4c0a08={'raw':![],'where':{'id':_0x209b26[_0x41a08f('0x15')]['id']}};const _0x854f12={};return _0x854f12[_0x41a08f('0xd')]=_[_0x41a08f('0x6')](db['ServicenowConfiguration'][_0x41a08f('0x5')]),_0x854f12['query']=_[_0x41a08f('0x6')](_0x209b26[_0x41a08f('0x25')]),_0x854f12[_0x41a08f('0xa')]=_[_0x41a08f('0x1d')](_0x854f12[_0x41a08f('0xd')],_0x854f12[_0x41a08f('0x25')]),_0x4c0a08[_0x41a08f('0x1a')]=_[_0x41a08f('0x1d')](_0x854f12[_0x41a08f('0xd')],qs[_0x41a08f('0x11')](_0x209b26['query']['fields'])),_0x4c0a08[_0x41a08f('0x1a')]=_0x4c0a08['attributes']['length']?_0x4c0a08[_0x41a08f('0x1a')]:_0x854f12[_0x41a08f('0xd')],_0x209b26['query']['includeAll']&&(_0x4c0a08[_0x41a08f('0x30')]=[{'all':!![]}]),_0x4c0a08=_[_0x41a08f('0x23')]({},_0x4c0a08,_0x209b26[_0x41a08f('0x34')]),db[_0x41a08f('0x37')][_0x41a08f('0x1')](_0x4c0a08)[_0x41a08f('0x1e')](handleEntityNotFound(_0x1435af,null))[_0x41a08f('0x1e')](respondWithResult(_0x1435af,null))[_0x41a08f('0x9')](handleError(_0x1435af,null));},exports['create']=function(_0x5039c1,_0x8217a1){const _0x20a140=_0x41cb8e;return db[_0x20a140('0x37')][_0x20a140('0x2a')](_0x5039c1['body'],{})[_0x20a140('0x1e')](respondWithResult(_0x8217a1,0xc9))[_0x20a140('0x9')](handleError(_0x8217a1,null));},exports['update']=function(_0x2e7e90,_0x1afb8c){const _0x5e2311=_0x41cb8e;return _0x2e7e90[_0x5e2311('0x2d')]['id']&&delete _0x2e7e90['body']['id'],db[_0x5e2311('0x37')][_0x5e2311('0x1')]({'where':{'id':_0x2e7e90[_0x5e2311('0x15')]['id']}})[_0x5e2311('0x1e')](handleEntityNotFound(_0x1afb8c,null))[_0x5e2311('0x1e')](saveUpdates(_0x2e7e90[_0x5e2311('0x2d')],null))[_0x5e2311('0x1e')](respondWithResult(_0x1afb8c,null))['catch'](handleError(_0x1afb8c,null));},exports['destroy']=function(_0x1c884d,_0x3c6f91){const _0xf9ec64=_0x41cb8e;return db['ServicenowConfiguration'][_0xf9ec64('0x1')]({'where':{'id':_0x1c884d[_0xf9ec64('0x15')]['id']}})[_0xf9ec64('0x1e')](handleEntityNotFound(_0x3c6f91,null))[_0xf9ec64('0x1e')](removeEntity(_0x3c6f91,null))[_0xf9ec64('0x9')](handleError(_0x3c6f91,null));},exports['getFields']=function(_0x4a85d8,_0x493c53){const _0x1ad4e8=_0x41cb8e;let _0x1716de={};const _0x1643aa={};let _0x5897dc,_0x3a9f06;return db[_0x1ad4e8('0x37')][_0x1ad4e8('0x1')]({'where':{'id':_0x4a85d8[_0x1ad4e8('0x15')]['id']}})[_0x1ad4e8('0x1e')](handleEntityNotFound(_0x493c53,null))[_0x1ad4e8('0x1e')](function(_0x24b7d5){const _0x222532=_0x1ad4e8;if(_0x24b7d5)return _0x5897dc=_0x24b7d5,_0x1643aa[_0x222532('0xd')]=_[_0x222532('0x6')](db[_0x222532('0xf')]['rawAttributes']),_0x1643aa[_0x222532('0x25')]=_['keys'](_0x4a85d8['query']),_0x1643aa[_0x222532('0xa')]=_[_0x222532('0x1d')](_0x1643aa[_0x222532('0xd')],_0x1643aa[_0x222532('0x25')]),_0x1716de['attributes']=_[_0x222532('0x1d')](_0x1643aa[_0x222532('0xd')],qs[_0x222532('0x11')](_0x4a85d8[_0x222532('0x25')]['fields'])),_0x1716de[_0x222532('0x1a')]=_0x1716de[_0x222532('0x1a')][_0x222532('0x2e')]?_0x1716de[_0x222532('0x1a')]:_0x1643aa[_0x222532('0xd')],_0x1716de[_0x222532('0x27')]=qs[_0x222532('0x21')](_0x4a85d8[_0x222532('0x25')]['sort']),_0x1716de[_0x222532('0xc')]=qs[_0x222532('0xa')](_[_0x222532('0x10')](_0x4a85d8[_0x222532('0x25')],_0x1643aa[_0x222532('0xa')])),_0x4a85d8[_0x222532('0x25')][_0x222532('0x33')]&&(_0x1716de[_0x222532('0xc')]=_[_0x222532('0x23')](_0x1716de[_0x222532('0xc')],{[Op['or']]:_[_0x222532('0x2b')](_0x1716de['attributes'],function(_0x410136){const _0x35fa60=_0x222532,_0x31c2f8={};return _0x31c2f8[_0x410136]={[Op[_0x35fa60('0x35')]]:'%'+_0x4a85d8['query'][_0x35fa60('0x33')]+'%'},_0x31c2f8;})})),_0x1716de=_[_0x222532('0x23')]({},_0x1716de,_0x4a85d8[_0x222532('0x34')]),_0x5897dc[_0x222532('0x12')](_0x1716de);})[_0x1ad4e8('0x1e')](function(_0x504306){const _0x41b32d=_0x1ad4e8;if(_0x504306)return _0x3a9f06=_0x504306[_0x41b32d('0x2e')],typeof _0x4a85d8[_0x41b32d('0x25')][_0x41b32d('0x3')]==='undefined'&&(_0x1716de[_0x41b32d('0x32')]=qs[_0x41b32d('0x32')](_0x4a85d8['query'][_0x41b32d('0x32')]),_0x1716de[_0x41b32d('0x8')]=qs[_0x41b32d('0x8')](_0x4a85d8[_0x41b32d('0x25')][_0x41b32d('0x8')])),_0x5897dc[_0x41b32d('0x12')](_0x1716de);})[_0x1ad4e8('0x1e')](function(_0x5e04d0){if(_0x5e04d0)return _0x5e04d0?{'count':_0x3a9f06,'rows':_0x5e04d0}:null;})['then'](respondWithResult(_0x493c53,null))[_0x1ad4e8('0x9')](handleError(_0x493c53,null));},exports['getSubjects']=function(_0x5f55cc,_0x5c4c4e){const _0x5c371f=_0x41cb8e;let _0x258efc={};const _0x20a670={};let _0x378387,_0xa2ad4e;return db[_0x5c371f('0x37')][_0x5c371f('0x1')]({'where':{'id':_0x5f55cc['params']['id']}})[_0x5c371f('0x1e')](handleEntityNotFound(_0x5c4c4e,null))[_0x5c371f('0x1e')](function(_0x41893a){const _0x140de6=_0x5c371f;if(_0x41893a)return _0x378387=_0x41893a,_0x20a670['model']=_['keys'](db['ServicenowField'][_0x140de6('0x5')]),_0x20a670[_0x140de6('0x25')]=_[_0x140de6('0x6')](_0x5f55cc[_0x140de6('0x25')]),_0x20a670[_0x140de6('0xa')]=_['intersection'](_0x20a670[_0x140de6('0xd')],_0x20a670[_0x140de6('0x25')]),_0x258efc[_0x140de6('0x1a')]=_[_0x140de6('0x1d')](_0x20a670[_0x140de6('0xd')],qs['fields'](_0x5f55cc[_0x140de6('0x25')]['fields'])),_0x258efc[_0x140de6('0x1a')]=_0x258efc[_0x140de6('0x1a')][_0x140de6('0x2e')]?_0x258efc[_0x140de6('0x1a')]:_0x20a670[_0x140de6('0xd')],_0x258efc[_0x140de6('0x27')]=qs[_0x140de6('0x21')](_0x5f55cc['query'][_0x140de6('0x21')]),_0x258efc[_0x140de6('0xc')]=qs[_0x140de6('0xa')](_[_0x140de6('0x10')](_0x5f55cc[_0x140de6('0x25')],_0x20a670[_0x140de6('0xa')])),_0x5f55cc[_0x140de6('0x25')][_0x140de6('0x33')]&&(_0x258efc[_0x140de6('0xc')]=_[_0x140de6('0x23')](_0x258efc[_0x140de6('0xc')],{[Op['or']]:_['map'](_0x258efc[_0x140de6('0x1a')],function(_0x1f6184){const _0x44d783=_0x140de6,_0x3105f8={};return _0x3105f8[_0x1f6184]={[Op[_0x44d783('0x35')]]:'%'+_0x5f55cc[_0x44d783('0x25')][_0x44d783('0x33')]+'%'},_0x3105f8;})})),_0x258efc=_['merge']({},_0x258efc,_0x5f55cc[_0x140de6('0x34')]),_0x378387['getSubjects'](_0x258efc);})['then'](function(_0x821797){const _0x2c3706=_0x5c371f;if(_0x821797)return _0xa2ad4e=_0x821797[_0x2c3706('0x2e')],typeof _0x5f55cc[_0x2c3706('0x25')][_0x2c3706('0x3')]===_0x2c3706('0x2f')&&(_0x258efc[_0x2c3706('0x32')]=qs[_0x2c3706('0x32')](_0x5f55cc['query']['limit']),_0x258efc[_0x2c3706('0x8')]=qs[_0x2c3706('0x8')](_0x5f55cc[_0x2c3706('0x25')][_0x2c3706('0x8')])),_0x378387[_0x2c3706('0x26')](_0x258efc);})[_0x5c371f('0x1e')](function(_0x3d7b2f){if(_0x3d7b2f)return _0x3d7b2f?{'count':_0xa2ad4e,'rows':_0x3d7b2f}:null;})[_0x5c371f('0x1e')](respondWithResult(_0x5c4c4e,null))['catch'](handleError(_0x5c4c4e,null));},exports[_0x41cb8e('0x4')]=function(_0x13d306,_0x2e548b){const _0x4e94a6=_0x41cb8e;let _0x39baa2={};const _0x1ee946={};let _0x31a049,_0x4d5024;return db[_0x4e94a6('0x37')][_0x4e94a6('0x1')]({'where':{'id':_0x13d306[_0x4e94a6('0x15')]['id']}})[_0x4e94a6('0x1e')](handleEntityNotFound(_0x2e548b,null))[_0x4e94a6('0x1e')](function(_0x1902b0){const _0x43941c=_0x4e94a6;if(_0x1902b0)return _0x31a049=_0x1902b0,_0x1ee946[_0x43941c('0xd')]=_['keys'](db[_0x43941c('0xf')][_0x43941c('0x5')]),_0x1ee946[_0x43941c('0x25')]=_[_0x43941c('0x6')](_0x13d306['query']),_0x1ee946[_0x43941c('0xa')]=_[_0x43941c('0x1d')](_0x1ee946['model'],_0x1ee946[_0x43941c('0x25')]),_0x39baa2[_0x43941c('0x1a')]=_[_0x43941c('0x1d')](_0x1ee946[_0x43941c('0xd')],qs[_0x43941c('0x11')](_0x13d306[_0x43941c('0x25')]['fields'])),_0x39baa2[_0x43941c('0x1a')]=_0x39baa2['attributes'][_0x43941c('0x2e')]?_0x39baa2[_0x43941c('0x1a')]:_0x1ee946['model'],_0x39baa2[_0x43941c('0x27')]=qs[_0x43941c('0x21')](_0x13d306[_0x43941c('0x25')][_0x43941c('0x21')]),_0x39baa2[_0x43941c('0xc')]=qs[_0x43941c('0xa')](_[_0x43941c('0x10')](_0x13d306[_0x43941c('0x25')],_0x1ee946[_0x43941c('0xa')])),_0x13d306['query'][_0x43941c('0x33')]&&(_0x39baa2[_0x43941c('0xc')]=_[_0x43941c('0x23')](_0x39baa2[_0x43941c('0xc')],{[Op['or']]:_['map'](_0x39baa2[_0x43941c('0x1a')],function(_0x5221a9){const _0x432150=_0x43941c,_0x556cfa={};return _0x556cfa[_0x5221a9]={[Op[_0x432150('0x35')]]:'%'+_0x13d306['query'][_0x432150('0x33')]+'%'},_0x556cfa;})})),_0x39baa2=_[_0x43941c('0x23')]({},_0x39baa2,_0x13d306[_0x43941c('0x34')]),_0x31a049[_0x43941c('0x4')](_0x39baa2);})[_0x4e94a6('0x1e')](function(_0x1dd582){const _0x47e1df=_0x4e94a6;if(_0x1dd582)return _0x4d5024=_0x1dd582[_0x47e1df('0x2e')],typeof _0x13d306[_0x47e1df('0x25')][_0x47e1df('0x3')]==='undefined'&&(_0x39baa2[_0x47e1df('0x32')]=qs[_0x47e1df('0x32')](_0x13d306[_0x47e1df('0x25')]['limit']),_0x39baa2[_0x47e1df('0x8')]=qs[_0x47e1df('0x8')](_0x13d306[_0x47e1df('0x25')][_0x47e1df('0x8')])),_0x31a049[_0x47e1df('0x4')](_0x39baa2);})[_0x4e94a6('0x1e')](function(_0x5d0793){if(_0x5d0793)return _0x5d0793?{'count':_0x4d5024,'rows':_0x5d0793}:null;})[_0x4e94a6('0x1e')](respondWithResult(_0x2e548b,null))[_0x4e94a6('0x9')](handleError(_0x2e548b,null));}; \ No newline at end of file diff --git a/server/api/intServicenowConfiguration/intServicenowConfiguration.model.js b/server/api/intServicenowConfiguration/intServicenowConfiguration.model.js index 9205ec1..52cfd85 100644 --- a/server/api/intServicenowConfiguration/intServicenowConfiguration.model.js +++ b/server/api/intServicenowConfiguration/intServicenowConfiguration.model.js @@ -1 +1 @@ -const a300_0x25ef=['ServicenowConfiguration','./intServicenowConfiguration.attributes','int_servicenow_configurations','define'];(function(_0x10269b,_0x25ef1f){const _0x35d2e9=function(_0x552a8b){while(--_0x552a8b){_0x10269b['push'](_0x10269b['shift']());}};_0x35d2e9(++_0x25ef1f);}(a300_0x25ef,0xb4));const a300_0x35d2=function(_0x10269b,_0x25ef1f){_0x10269b=_0x10269b-0x0;let _0x35d2e9=a300_0x25ef[_0x10269b];return _0x35d2e9;};const _0x58ccf5=a300_0x35d2;'use strict';const attributes=require(_0x58ccf5('0x1'));module['exports']=function(_0x552a8b){const _0x27e2dd=_0x58ccf5,_0x900032=_0x552a8b[_0x27e2dd('0x3')](_0x27e2dd('0x0'),attributes,{'tableName':_0x27e2dd('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x900032;}; \ No newline at end of file +const a300_0x1727=['exports','int_servicenow_configurations','ServicenowConfiguration','define'];(function(_0x268c59,_0x1727e3){const _0x1be820=function(_0x4197fd){while(--_0x4197fd){_0x268c59['push'](_0x268c59['shift']());}};_0x1be820(++_0x1727e3);}(a300_0x1727,0xf0));const a300_0x1be8=function(_0x268c59,_0x1727e3){_0x268c59=_0x268c59-0x0;let _0x1be820=a300_0x1727[_0x268c59];return _0x1be820;};const _0x58a357=a300_0x1be8;'use strict';const attributes=require('./intServicenowConfiguration.attributes');module[_0x58a357('0x0')]=function(_0x4197fd){const _0x51f9a1=_0x58a357,_0x5f26b9=_0x4197fd[_0x51f9a1('0x3')](_0x51f9a1('0x2'),attributes,{'tableName':_0x51f9a1('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5f26b9;}; \ No newline at end of file diff --git a/server/api/intServicenowField/index.js b/server/api/intServicenowField/index.js index 5217119..6135136 100644 --- a/server/api/intServicenowField/index.js +++ b/server/api/intServicenowField/index.js @@ -1 +1 @@ -const a301_0x314a=['get','../../components/auth/service','destroy','create','update','show','/:id','put','isAuthenticated','post','exports','index','delete','./intServicenowField.controller'];(function(_0x3cd70c,_0x314a50){const _0xc888c=function(_0x5def48){while(--_0x5def48){_0x3cd70c['push'](_0x3cd70c['shift']());}};_0xc888c(++_0x314a50);}(a301_0x314a,0x108));const a301_0xc888=function(_0x3cd70c,_0x314a50){_0x3cd70c=_0x3cd70c-0x0;let _0xc888c=a301_0x314a[_0x3cd70c];return _0xc888c;};const _0x5efbfd=a301_0xc888;'use strict';const express=require('express'),router=express['Router'](),auth=require(_0x5efbfd('0x3')),controller=require(_0x5efbfd('0x1'));router[_0x5efbfd('0x2')]('/',auth[_0x5efbfd('0xa')](),controller[_0x5efbfd('0xd')]),router[_0x5efbfd('0x2')]('/:id',auth[_0x5efbfd('0xa')](),controller[_0x5efbfd('0x7')]),router[_0x5efbfd('0xb')]('/',auth['isAuthenticated'](),controller[_0x5efbfd('0x5')]),router[_0x5efbfd('0x9')](_0x5efbfd('0x8'),auth[_0x5efbfd('0xa')](),controller[_0x5efbfd('0x6')]),router[_0x5efbfd('0x0')](_0x5efbfd('0x8'),auth['isAuthenticated'](),controller[_0x5efbfd('0x4')]),module[_0x5efbfd('0xc')]=router; \ No newline at end of file +const a301_0x5f31=['isAuthenticated','exports','create','put','index','show','Router','post','get','/:id','delete','../../components/auth/service','./intServicenowField.controller','express'];(function(_0x5dbe82,_0x5f31c8){const _0x2ac1c1=function(_0x14b05f){while(--_0x14b05f){_0x5dbe82['push'](_0x5dbe82['shift']());}};_0x2ac1c1(++_0x5f31c8);}(a301_0x5f31,0xe6));const a301_0x2ac1=function(_0x5dbe82,_0x5f31c8){_0x5dbe82=_0x5dbe82-0x0;let _0x2ac1c1=a301_0x5f31[_0x5dbe82];return _0x2ac1c1;};const _0x39e59a=a301_0x2ac1;'use strict';const express=require(_0x39e59a('0x7')),router=express[_0x39e59a('0x0')](),auth=require(_0x39e59a('0x5')),controller=require(_0x39e59a('0x6'));router[_0x39e59a('0x2')]('/',auth[_0x39e59a('0x8')](),controller[_0x39e59a('0xc')]),router['get'](_0x39e59a('0x3'),auth['isAuthenticated'](),controller[_0x39e59a('0xd')]),router[_0x39e59a('0x1')]('/',auth['isAuthenticated'](),controller[_0x39e59a('0xa')]),router[_0x39e59a('0xb')](_0x39e59a('0x3'),auth[_0x39e59a('0x8')](),controller['update']),router[_0x39e59a('0x4')](_0x39e59a('0x3'),auth[_0x39e59a('0x8')](),controller['destroy']),module[_0x39e59a('0x9')]=router; \ No newline at end of file diff --git a/server/api/intServicenowField/intServicenowField.attributes.js b/server/api/intServicenowField/intServicenowField.attributes.js index 5fa9b0d..b41680f 100644 --- a/server/api/intServicenowField/intServicenowField.attributes.js +++ b/server/api/intServicenowField/intServicenowField.attributes.js @@ -1 +1 @@ -const a302_0x3156=['variable','exports','keyValue','sequelize','BOOLEAN','STRING','customVariable','string','ENUM'];(function(_0x502f3a,_0x315663){const _0x29af1e=function(_0xba8f2c){while(--_0xba8f2c){_0x502f3a['push'](_0x502f3a['shift']());}};_0x29af1e(++_0x315663);}(a302_0x3156,0x86));const a302_0x29af=function(_0x502f3a,_0x315663){_0x502f3a=_0x502f3a-0x0;let _0x29af1e=a302_0x3156[_0x502f3a];return _0x29af1e;};const _0xf992de=a302_0x29af;'use strict';const Sequelize=require(_0xf992de('0x4'));module[_0xf992de('0x2')]={'type':{'type':Sequelize[_0xf992de('0x0')](_0xf992de('0x8'),_0xf992de('0x1'),_0xf992de('0x7'),_0xf992de('0x3')),'defaultValue':_0xf992de('0x8')},'content':{'type':Sequelize['STRING']},'key':{'type':Sequelize[_0xf992de('0x6')]},'keyType':{'type':Sequelize[_0xf992de('0x0')](_0xf992de('0x8'),_0xf992de('0x1'),_0xf992de('0x7'))},'keyContent':{'type':Sequelize[_0xf992de('0x6')]},'idField':{'type':Sequelize['STRING']},'nameField':{'type':Sequelize['STRING']},'customField':{'type':Sequelize[_0xf992de('0x5')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0xf992de('0x6')]}}; \ No newline at end of file +const a302_0x2c5a=['keyValue','BOOLEAN','variable','string','ENUM','customVariable','sequelize','STRING','exports'];(function(_0xe8bb59,_0x2c5a3e){const _0x44c555=function(_0x8c918a){while(--_0x8c918a){_0xe8bb59['push'](_0xe8bb59['shift']());}};_0x44c555(++_0x2c5a3e);}(a302_0x2c5a,0x64));const a302_0x44c5=function(_0xe8bb59,_0x2c5a3e){_0xe8bb59=_0xe8bb59-0x0;let _0x44c555=a302_0x2c5a[_0xe8bb59];return _0x44c555;};const _0x1b5770=a302_0x44c5;'use strict';const Sequelize=require(_0x1b5770('0x5'));module[_0x1b5770('0x7')]={'type':{'type':Sequelize['ENUM']('string','variable','customVariable',_0x1b5770('0x8')),'defaultValue':_0x1b5770('0x2')},'content':{'type':Sequelize[_0x1b5770('0x6')]},'key':{'type':Sequelize[_0x1b5770('0x6')]},'keyType':{'type':Sequelize[_0x1b5770('0x3')](_0x1b5770('0x2'),_0x1b5770('0x1'),_0x1b5770('0x4'))},'keyContent':{'type':Sequelize[_0x1b5770('0x6')]},'idField':{'type':Sequelize[_0x1b5770('0x6')]},'nameField':{'type':Sequelize[_0x1b5770('0x6')]},'customField':{'type':Sequelize[_0x1b5770('0x0')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x1b5770('0x6')]}}; \ No newline at end of file diff --git a/server/api/intServicenowField/intServicenowField.controller.js b/server/api/intServicenowField/intServicenowField.controller.js index c4b7146..e48887a 100644 --- a/server/api/intServicenowField/intServicenowField.controller.js +++ b/server/api/intServicenowField/intServicenowField.controller.js @@ -1 +1 @@ -const a303_0x5a1c=['lodash','rawAttributes','findAll','nolimit','status','undefined','sequelize','error','length','query','order','include','index','like','type','name','ServicenowField','../../components/parsers/qs','filters','then','update','map','api','count','rows','offset','where','model','intersection','send','set','limit','sort','filter','show','destroy','keys','params','merge','end','pick','findOne','fields','body','options','VIRTUAL','catch','Content-Range','attributes'];(function(_0x3b3d9c,_0x5a1ccb){const _0x2fbcd6=function(_0x2167a5){while(--_0x2167a5){_0x3b3d9c['push'](_0x3b3d9c['shift']());}};_0x2fbcd6(++_0x5a1ccb);}(a303_0x5a1c,0x64));const a303_0x2fbc=function(_0x3b3d9c,_0x5a1ccb){_0x3b3d9c=_0x3b3d9c-0x0;let _0x2fbcd6=a303_0x5a1c[_0x3b3d9c];return _0x2fbcd6;};const _0x187413=a303_0x2fbc;'use strict';const _=require(_0x187413('0x2f')),qs=require(_0x187413('0xf')),logger=require('../../config/logger')(_0x187413('0x14')),db=require('../../mysqldb')['db'],{Op}=require(_0x187413('0x4'));function respondWithResult(_0x2167a5,_0x4270d0){return _0x4270d0=_0x4270d0||0xc8,function(_0x23a9b5){const _0x35327b=a303_0x2fbc;if(_0x23a9b5)return _0x2167a5[_0x35327b('0x2')](_0x4270d0)['json'](_0x23a9b5);};}function respondWithFilteredResult(_0x32fc7d,_0x45fc01){return function(_0x56233a){const _0x1993ed=a303_0x2fbc;if(_0x56233a){const _0x6b9bea=_0x56233a['count'],_0x4a568b=_0x45fc01['offset'];let _0x4b352a=_0x45fc01[_0x1993ed('0x17')]+_0x45fc01['limit'],_0x382b22;return _0x4b352a>=_0x6b9bea?(_0x4b352a=_0x6b9bea,_0x382b22=0xc8):_0x382b22=0xce,_0x32fc7d[_0x1993ed('0x2')](_0x382b22),_0x32fc7d[_0x1993ed('0x1c')](_0x1993ed('0x2d'),_0x4a568b+'-'+_0x4b352a+'/'+_0x6b9bea)['json'](_0x56233a);}return null;};}function saveUpdates(_0x28714e){return function(_0x414ebe){const _0x511c3f=a303_0x2fbc;if(_0x414ebe)return _0x414ebe[_0x511c3f('0x12')](_0x28714e)[_0x511c3f('0x11')](function(_0x5a02ad){return _0x5a02ad;});return null;};}function removeEntity(_0x290bcb){return function(_0x5d93fd){const _0x1ca6fa=a303_0x2fbc;if(_0x5d93fd)return _0x5d93fd[_0x1ca6fa('0x21')]()[_0x1ca6fa('0x11')](function(){const _0x4e6354=_0x1ca6fa;_0x290bcb[_0x4e6354('0x2')](0xcc)[_0x4e6354('0x25')]();});};}function handleEntityNotFound(_0x4abaa7){return function(_0x475c2d){return!_0x475c2d&&_0x4abaa7['sendStatus'](0x194),_0x475c2d;};}function handleError(_0xb14722,_0x17a714){return _0x17a714=_0x17a714||0x1f4,function(_0x4ba28f){const _0x1813f3=a303_0x2fbc;logger[_0x1813f3('0x5')](_0x4ba28f['stack']),_0x4ba28f[_0x1813f3('0xd')]&&delete _0x4ba28f['name'],_0xb14722['status'](_0x17a714)[_0x1813f3('0x1b')](_0x4ba28f);};}exports[_0x187413('0xa')]=function(_0x343155,_0x11344a){const _0x2d29f2=_0x187413;let _0x4ecd8a={};const _0x40b8d8={},_0x21fdf3={'count':0x0,'rows':[]},_0x58b7a8=_['map'](db[_0x2d29f2('0xe')][_0x2d29f2('0x30')],function(_0x5b4533){const _0x274311=_0x2d29f2;return{'name':_0x5b4533['fieldName'],'type':_0x5b4533[_0x274311('0xc')]['key']};});_0x40b8d8['model']=_['map'](_0x58b7a8,'name'),_0x40b8d8[_0x2d29f2('0x7')]=_[_0x2d29f2('0x22')](_0x343155[_0x2d29f2('0x7')]),_0x40b8d8[_0x2d29f2('0x10')]=_[_0x2d29f2('0x1a')](_0x40b8d8[_0x2d29f2('0x19')],_0x40b8d8['query']),_0x4ecd8a['attributes']=_[_0x2d29f2('0x1a')](_0x40b8d8[_0x2d29f2('0x19')],qs[_0x2d29f2('0x28')](_0x343155[_0x2d29f2('0x7')][_0x2d29f2('0x28')])),_0x4ecd8a[_0x2d29f2('0x2e')]=_0x4ecd8a[_0x2d29f2('0x2e')][_0x2d29f2('0x6')]?_0x4ecd8a[_0x2d29f2('0x2e')]:_0x40b8d8[_0x2d29f2('0x19')];typeof _0x343155[_0x2d29f2('0x7')][_0x2d29f2('0x1')]===_0x2d29f2('0x3')&&(_0x4ecd8a[_0x2d29f2('0x1d')]=qs['limit'](_0x343155['query'][_0x2d29f2('0x1d')]),_0x4ecd8a[_0x2d29f2('0x17')]=qs['offset'](_0x343155[_0x2d29f2('0x7')]['offset']));_0x4ecd8a[_0x2d29f2('0x8')]=qs[_0x2d29f2('0x1e')](_0x343155[_0x2d29f2('0x7')][_0x2d29f2('0x1e')]),_0x4ecd8a[_0x2d29f2('0x18')]=qs[_0x2d29f2('0x10')](_[_0x2d29f2('0x26')](_0x343155[_0x2d29f2('0x7')],_0x40b8d8[_0x2d29f2('0x10')]),_0x58b7a8);_0x343155['query']['filter']&&(_0x4ecd8a[_0x2d29f2('0x18')]=_[_0x2d29f2('0x24')](_0x4ecd8a[_0x2d29f2('0x18')],{[Op['or']]:_[_0x2d29f2('0x13')](_0x58b7a8,function(_0x2bd809){const _0x5f0c05=_0x2d29f2;if(_0x2bd809[_0x5f0c05('0xc')]!==_0x5f0c05('0x2b')){const _0x25d851={};return _0x25d851[_0x2bd809[_0x5f0c05('0xd')]]={[Op[_0x5f0c05('0xb')]]:'%'+_0x343155['query'][_0x5f0c05('0x1f')]+'%'},_0x25d851;}})}));_0x4ecd8a=_[_0x2d29f2('0x24')]({},_0x4ecd8a,_0x343155[_0x2d29f2('0x2a')]);const _0x260f69={'where':_0x4ecd8a[_0x2d29f2('0x18')]};return db[_0x2d29f2('0xe')]['count'](_0x260f69)[_0x2d29f2('0x11')](function(_0x323fe5){const _0x11dd09=_0x2d29f2;return _0x21fdf3[_0x11dd09('0x15')]=_0x323fe5,_0x343155['query']['includeAll']&&(_0x4ecd8a[_0x11dd09('0x9')]=[{'all':!![]}]),db['ServicenowField'][_0x11dd09('0x0')](_0x4ecd8a);})['then'](function(_0x2e78e8){const _0x1b62d9=_0x2d29f2;return _0x21fdf3[_0x1b62d9('0x16')]=_0x2e78e8,_0x21fdf3;})[_0x2d29f2('0x11')](respondWithFilteredResult(_0x11344a,_0x4ecd8a))[_0x2d29f2('0x2c')](handleError(_0x11344a,null));},exports[_0x187413('0x20')]=function(_0x45688b,_0x5cf6c4){const _0x38a633=_0x187413;let _0x11f6d8={'raw':!![],'where':{'id':_0x45688b[_0x38a633('0x23')]['id']}};const _0x1ff28f={};return _0x1ff28f[_0x38a633('0x19')]=_[_0x38a633('0x22')](db[_0x38a633('0xe')]['rawAttributes']),_0x1ff28f[_0x38a633('0x7')]=_['keys'](_0x45688b['query']),_0x1ff28f[_0x38a633('0x10')]=_[_0x38a633('0x1a')](_0x1ff28f[_0x38a633('0x19')],_0x1ff28f[_0x38a633('0x7')]),_0x11f6d8[_0x38a633('0x2e')]=_[_0x38a633('0x1a')](_0x1ff28f[_0x38a633('0x19')],qs[_0x38a633('0x28')](_0x45688b[_0x38a633('0x7')]['fields'])),_0x11f6d8[_0x38a633('0x2e')]=_0x11f6d8[_0x38a633('0x2e')][_0x38a633('0x6')]?_0x11f6d8[_0x38a633('0x2e')]:_0x1ff28f[_0x38a633('0x19')],_0x45688b['query']['includeAll']&&(_0x11f6d8[_0x38a633('0x9')]=[{'all':!![]}]),_0x11f6d8=_[_0x38a633('0x24')]({},_0x11f6d8,_0x45688b[_0x38a633('0x2a')]),db[_0x38a633('0xe')][_0x38a633('0x27')](_0x11f6d8)['then'](handleEntityNotFound(_0x5cf6c4,null))[_0x38a633('0x11')](respondWithResult(_0x5cf6c4,null))[_0x38a633('0x2c')](handleError(_0x5cf6c4,null));},exports['create']=function(_0xa86321,_0x5089d0){const _0x1b7199=_0x187413;return db[_0x1b7199('0xe')]['create'](_0xa86321[_0x1b7199('0x29')],{})[_0x1b7199('0x11')](respondWithResult(_0x5089d0,0xc9))[_0x1b7199('0x2c')](handleError(_0x5089d0,null));},exports[_0x187413('0x12')]=function(_0x2b8669,_0x39ab0a){const _0x1ef7ca=_0x187413;return _0x2b8669['body']['id']&&delete _0x2b8669[_0x1ef7ca('0x29')]['id'],db[_0x1ef7ca('0xe')][_0x1ef7ca('0x27')]({'where':{'id':_0x2b8669[_0x1ef7ca('0x23')]['id']}})[_0x1ef7ca('0x11')](handleEntityNotFound(_0x39ab0a,null))[_0x1ef7ca('0x11')](saveUpdates(_0x2b8669[_0x1ef7ca('0x29')],null))[_0x1ef7ca('0x11')](respondWithResult(_0x39ab0a,null))[_0x1ef7ca('0x2c')](handleError(_0x39ab0a,null));},exports[_0x187413('0x21')]=function(_0x42efd0,_0x51df86){const _0x4e6e6d=_0x187413;return db[_0x4e6e6d('0xe')][_0x4e6e6d('0x27')]({'where':{'id':_0x42efd0[_0x4e6e6d('0x23')]['id']}})[_0x4e6e6d('0x11')](handleEntityNotFound(_0x51df86,null))[_0x4e6e6d('0x11')](removeEntity(_0x51df86,null))['catch'](handleError(_0x51df86,null));}; \ No newline at end of file +const a303_0x53a9=['rawAttributes','model','attributes','like','filter','order','pick','includeAll','error','create','include','limit','stack','query','length','params','count','merge','nolimit','status','name','findOne','send','show','../../components/parsers/qs','end','fieldName','body','key','catch','sendStatus','offset','update','index','then','destroy','keys','where','fields','lodash','../../config/logger','map','VIRTUAL','sort','ServicenowField','intersection','undefined','Content-Range','sequelize','filters','rows'];(function(_0xc56bf9,_0x53a959){const _0xeff452=function(_0x578c01){while(--_0x578c01){_0xc56bf9['push'](_0xc56bf9['shift']());}};_0xeff452(++_0x53a959);}(a303_0x53a9,0x1ec));const a303_0xeff4=function(_0xc56bf9,_0x53a959){_0xc56bf9=_0xc56bf9-0x0;let _0xeff452=a303_0x53a9[_0xc56bf9];return _0xeff452;};const _0x35baa0=a303_0xeff4;'use strict';const _=require(_0x35baa0('0x6')),qs=require(_0x35baa0('0x2a')),logger=require(_0x35baa0('0x7'))('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x35baa0('0xf'));function respondWithResult(_0x578c01,_0x47481e){return _0x47481e=_0x47481e||0xc8,function(_0x3d33d4){const _0x41eff3=a303_0xeff4;if(_0x3d33d4)return _0x578c01[_0x41eff3('0x25')](_0x47481e)['json'](_0x3d33d4);};}function respondWithFilteredResult(_0x3fee29,_0x5eac95){return function(_0xf49db5){const _0x26a101=a303_0xeff4;if(_0xf49db5){const _0x250039=_0xf49db5[_0x26a101('0x22')],_0x57ec58=_0x5eac95['offset'];let _0x1dd5aa=_0x5eac95['offset']+_0x5eac95[_0x26a101('0x1d')],_0x27d5fb;return _0x1dd5aa>=_0x250039?(_0x1dd5aa=_0x250039,_0x27d5fb=0xc8):_0x27d5fb=0xce,_0x3fee29[_0x26a101('0x25')](_0x27d5fb),_0x3fee29['set'](_0x26a101('0xe'),_0x57ec58+'-'+_0x1dd5aa+'/'+_0x250039)['json'](_0xf49db5);}return null;};}function saveUpdates(_0x1ed07a){return function(_0x1c9a9d){const _0x544db1=a303_0xeff4;if(_0x1c9a9d)return _0x1c9a9d[_0x544db1('0x32')](_0x1ed07a)['then'](function(_0x309cf1){return _0x309cf1;});return null;};}function removeEntity(_0x51928f){return function(_0x2d394d){const _0x460b5d=a303_0xeff4;if(_0x2d394d)return _0x2d394d[_0x460b5d('0x2')]()[_0x460b5d('0x1')](function(){const _0x545e07=_0x460b5d;_0x51928f['status'](0xcc)[_0x545e07('0x2b')]();});};}function handleEntityNotFound(_0x400328){return function(_0x423c30){const _0x24746e=a303_0xeff4;return!_0x423c30&&_0x400328[_0x24746e('0x30')](0x194),_0x423c30;};}function handleError(_0x4f66b9,_0x1c1288){return _0x1c1288=_0x1c1288||0x1f4,function(_0x1ed970){const _0x19ad21=a303_0xeff4;logger[_0x19ad21('0x1a')](_0x1ed970[_0x19ad21('0x1e')]),_0x1ed970[_0x19ad21('0x26')]&&delete _0x1ed970[_0x19ad21('0x26')],_0x4f66b9[_0x19ad21('0x25')](_0x1c1288)[_0x19ad21('0x28')](_0x1ed970);};}exports[_0x35baa0('0x0')]=function(_0x1fb625,_0x3adec9){const _0x3265ed=_0x35baa0;let _0x58d724={};const _0x173f89={},_0x3177fb={'count':0x0,'rows':[]},_0x3bfaef=_[_0x3265ed('0x8')](db['ServicenowField'][_0x3265ed('0x12')],function(_0x5ab1d5){const _0x36290d=_0x3265ed;return{'name':_0x5ab1d5[_0x36290d('0x2c')],'type':_0x5ab1d5['type'][_0x36290d('0x2e')]};});_0x173f89[_0x3265ed('0x13')]=_[_0x3265ed('0x8')](_0x3bfaef,_0x3265ed('0x26')),_0x173f89[_0x3265ed('0x1f')]=_['keys'](_0x1fb625[_0x3265ed('0x1f')]),_0x173f89[_0x3265ed('0x10')]=_[_0x3265ed('0xc')](_0x173f89['model'],_0x173f89[_0x3265ed('0x1f')]),_0x58d724[_0x3265ed('0x14')]=_[_0x3265ed('0xc')](_0x173f89[_0x3265ed('0x13')],qs[_0x3265ed('0x5')](_0x1fb625['query'][_0x3265ed('0x5')])),_0x58d724[_0x3265ed('0x14')]=_0x58d724['attributes'][_0x3265ed('0x20')]?_0x58d724[_0x3265ed('0x14')]:_0x173f89[_0x3265ed('0x13')];typeof _0x1fb625[_0x3265ed('0x1f')][_0x3265ed('0x24')]===_0x3265ed('0xd')&&(_0x58d724[_0x3265ed('0x1d')]=qs[_0x3265ed('0x1d')](_0x1fb625[_0x3265ed('0x1f')][_0x3265ed('0x1d')]),_0x58d724[_0x3265ed('0x31')]=qs[_0x3265ed('0x31')](_0x1fb625[_0x3265ed('0x1f')]['offset']));_0x58d724[_0x3265ed('0x17')]=qs[_0x3265ed('0xa')](_0x1fb625[_0x3265ed('0x1f')][_0x3265ed('0xa')]),_0x58d724[_0x3265ed('0x4')]=qs[_0x3265ed('0x10')](_[_0x3265ed('0x18')](_0x1fb625[_0x3265ed('0x1f')],_0x173f89[_0x3265ed('0x10')]),_0x3bfaef);_0x1fb625['query'][_0x3265ed('0x16')]&&(_0x58d724[_0x3265ed('0x4')]=_[_0x3265ed('0x23')](_0x58d724['where'],{[Op['or']]:_[_0x3265ed('0x8')](_0x3bfaef,function(_0x871a8e){const _0x5191c8=_0x3265ed;if(_0x871a8e['type']!==_0x5191c8('0x9')){const _0x499674={};return _0x499674[_0x871a8e[_0x5191c8('0x26')]]={[Op[_0x5191c8('0x15')]]:'%'+_0x1fb625[_0x5191c8('0x1f')][_0x5191c8('0x16')]+'%'},_0x499674;}})}));_0x58d724=_[_0x3265ed('0x23')]({},_0x58d724,_0x1fb625['options']);const _0x341b26={'where':_0x58d724[_0x3265ed('0x4')]};return db['ServicenowField'][_0x3265ed('0x22')](_0x341b26)[_0x3265ed('0x1')](function(_0x2403b2){const _0x36204a=_0x3265ed;return _0x3177fb['count']=_0x2403b2,_0x1fb625[_0x36204a('0x1f')][_0x36204a('0x19')]&&(_0x58d724[_0x36204a('0x1c')]=[{'all':!![]}]),db[_0x36204a('0xb')]['findAll'](_0x58d724);})[_0x3265ed('0x1')](function(_0x1301e1){const _0xcf6361=_0x3265ed;return _0x3177fb[_0xcf6361('0x11')]=_0x1301e1,_0x3177fb;})['then'](respondWithFilteredResult(_0x3adec9,_0x58d724))['catch'](handleError(_0x3adec9,null));},exports[_0x35baa0('0x29')]=function(_0x18d668,_0x1a3e12){const _0x4fc28d=_0x35baa0;let _0x18dde8={'raw':!![],'where':{'id':_0x18d668[_0x4fc28d('0x21')]['id']}};const _0x440630={};return _0x440630[_0x4fc28d('0x13')]=_['keys'](db[_0x4fc28d('0xb')]['rawAttributes']),_0x440630['query']=_[_0x4fc28d('0x3')](_0x18d668[_0x4fc28d('0x1f')]),_0x440630[_0x4fc28d('0x10')]=_[_0x4fc28d('0xc')](_0x440630[_0x4fc28d('0x13')],_0x440630['query']),_0x18dde8[_0x4fc28d('0x14')]=_[_0x4fc28d('0xc')](_0x440630[_0x4fc28d('0x13')],qs[_0x4fc28d('0x5')](_0x18d668[_0x4fc28d('0x1f')]['fields'])),_0x18dde8['attributes']=_0x18dde8['attributes'][_0x4fc28d('0x20')]?_0x18dde8['attributes']:_0x440630[_0x4fc28d('0x13')],_0x18d668[_0x4fc28d('0x1f')][_0x4fc28d('0x19')]&&(_0x18dde8['include']=[{'all':!![]}]),_0x18dde8=_[_0x4fc28d('0x23')]({},_0x18dde8,_0x18d668['options']),db[_0x4fc28d('0xb')][_0x4fc28d('0x27')](_0x18dde8)[_0x4fc28d('0x1')](handleEntityNotFound(_0x1a3e12,null))[_0x4fc28d('0x1')](respondWithResult(_0x1a3e12,null))['catch'](handleError(_0x1a3e12,null));},exports[_0x35baa0('0x1b')]=function(_0x1758af,_0x52bd4b){const _0x89412=_0x35baa0;return db[_0x89412('0xb')]['create'](_0x1758af[_0x89412('0x2d')],{})[_0x89412('0x1')](respondWithResult(_0x52bd4b,0xc9))[_0x89412('0x2f')](handleError(_0x52bd4b,null));},exports[_0x35baa0('0x32')]=function(_0x2cdcf2,_0xaca83d){const _0x3c9693=_0x35baa0;return _0x2cdcf2['body']['id']&&delete _0x2cdcf2[_0x3c9693('0x2d')]['id'],db[_0x3c9693('0xb')][_0x3c9693('0x27')]({'where':{'id':_0x2cdcf2[_0x3c9693('0x21')]['id']}})['then'](handleEntityNotFound(_0xaca83d,null))[_0x3c9693('0x1')](saveUpdates(_0x2cdcf2['body'],null))[_0x3c9693('0x1')](respondWithResult(_0xaca83d,null))[_0x3c9693('0x2f')](handleError(_0xaca83d,null));},exports['destroy']=function(_0x53c52d,_0x2f90d6){const _0x1ad38=_0x35baa0;return db[_0x1ad38('0xb')][_0x1ad38('0x27')]({'where':{'id':_0x53c52d[_0x1ad38('0x21')]['id']}})[_0x1ad38('0x1')](handleEntityNotFound(_0x2f90d6,null))[_0x1ad38('0x1')](removeEntity(_0x2f90d6,null))[_0x1ad38('0x2f')](handleError(_0x2f90d6,null));}; \ No newline at end of file diff --git a/server/api/intServicenowField/intServicenowField.model.js b/server/api/intServicenowField/intServicenowField.model.js index 90b666f..25c4117 100644 --- a/server/api/intServicenowField/intServicenowField.model.js +++ b/server/api/intServicenowField/intServicenowField.model.js @@ -1 +1 @@ -const a304_0x16dd=['idField','define','exports','./intServicenowField.attributes','ServicenowField','int_servicenow_fields','FieldId','servicenow_unique_index'];(function(_0x5e47e6,_0x16dd72){const _0x2a4d37=function(_0x215f7c){while(--_0x215f7c){_0x5e47e6['push'](_0x5e47e6['shift']());}};_0x2a4d37(++_0x16dd72);}(a304_0x16dd,0x17e));const a304_0x2a4d=function(_0x5e47e6,_0x16dd72){_0x5e47e6=_0x5e47e6-0x0;let _0x2a4d37=a304_0x16dd[_0x5e47e6];return _0x2a4d37;};const _0x169534=a304_0x2a4d;'use strict';const attributes=require(_0x169534('0x5'));module[_0x169534('0x4')]=function(_0x215f7c){const _0x1375d1=_0x169534,_0x2d8620=_0x215f7c[_0x1375d1('0x3')](_0x1375d1('0x6'),attributes,{'tableName':_0x1375d1('0x7'),'paranoid':![],'indexes':[{'name':_0x1375d1('0x1'),'fields':[_0x1375d1('0x2'),_0x1375d1('0x0')],'unique':!![]}],'timestamps':!![]});return _0x2d8620;}; \ No newline at end of file +const a304_0x3ce2=['./intServicenowField.attributes','int_servicenow_fields','servicenow_unique_index','define','idField'];(function(_0x10b660,_0x3ce270){const _0x45f61a=function(_0x5cad06){while(--_0x5cad06){_0x10b660['push'](_0x10b660['shift']());}};_0x45f61a(++_0x3ce270);}(a304_0x3ce2,0x1b5));const a304_0x45f6=function(_0x10b660,_0x3ce270){_0x10b660=_0x10b660-0x0;let _0x45f61a=a304_0x3ce2[_0x10b660];return _0x45f61a;};const _0x406eb0=a304_0x45f6;'use strict';const attributes=require(_0x406eb0('0x3'));module['exports']=function(_0x5cad06){const _0x120b5b=_0x406eb0,_0x2df6eb=_0x5cad06[_0x120b5b('0x1')]('ServicenowField',attributes,{'tableName':_0x120b5b('0x4'),'paranoid':![],'indexes':[{'name':_0x120b5b('0x0'),'fields':[_0x120b5b('0x2'),'FieldId'],'unique':!![]}],'timestamps':!![]});return _0x2df6eb;}; \ No newline at end of file diff --git a/server/api/intSugarcrmAccount/index.js b/server/api/intSugarcrmAccount/index.js index 931a91c..a920c95 100644 --- a/server/api/intSugarcrmAccount/index.js +++ b/server/api/intSugarcrmAccount/index.js @@ -1 +1 @@ -const a305_0x4b18=['Router','express','update','isAuthenticated','post','delete','getConfigurations','addConfiguration','/:id/fields','index','exports','/:id/configurations','create','get','show','../../components/auth/service','/:id','getFields'];(function(_0x2e2302,_0x4b1869){const _0x397203=function(_0x28913a){while(--_0x28913a){_0x2e2302['push'](_0x2e2302['shift']());}};_0x397203(++_0x4b1869);}(a305_0x4b18,0x9e));const a305_0x3972=function(_0x2e2302,_0x4b1869){_0x2e2302=_0x2e2302-0x0;let _0x397203=a305_0x4b18[_0x2e2302];return _0x397203;};const _0xcd6d01=a305_0x3972;'use strict';const express=require(_0xcd6d01('0x5')),router=express[_0xcd6d01('0x4')](),auth=require(_0xcd6d01('0x1')),controller=require('./intSugarcrmAccount.controller');router[_0xcd6d01('0x11')]('/',auth[_0xcd6d01('0x7')](),controller[_0xcd6d01('0xd')]),router['get'](_0xcd6d01('0x2'),auth['isAuthenticated'](),controller[_0xcd6d01('0x0')]),router[_0xcd6d01('0x11')](_0xcd6d01('0xf'),auth[_0xcd6d01('0x7')](),controller[_0xcd6d01('0xa')]),router['get'](_0xcd6d01('0xc'),auth[_0xcd6d01('0x7')](),controller[_0xcd6d01('0x3')]),router['post']('/',auth[_0xcd6d01('0x7')](),controller[_0xcd6d01('0x10')]),router[_0xcd6d01('0x8')](_0xcd6d01('0xf'),auth['isAuthenticated'](),controller[_0xcd6d01('0xb')]),router['put']('/:id',auth[_0xcd6d01('0x7')](),controller[_0xcd6d01('0x6')]),router[_0xcd6d01('0x9')](_0xcd6d01('0x2'),auth[_0xcd6d01('0x7')](),controller['destroy']),module[_0xcd6d01('0xe')]=router; \ No newline at end of file +const a305_0x387b=['isAuthenticated','put','index','get','/:id/configurations','../../components/auth/service','/:id','/:id/fields','addConfiguration','show','create','post','express','exports','delete'];(function(_0x4d7d15,_0x387bf6){const _0x12ca30=function(_0x34d6eb){while(--_0x34d6eb){_0x4d7d15['push'](_0x4d7d15['shift']());}};_0x12ca30(++_0x387bf6);}(a305_0x387b,0x1e3));const a305_0x12ca=function(_0x4d7d15,_0x387bf6){_0x4d7d15=_0x4d7d15-0x0;let _0x12ca30=a305_0x387b[_0x4d7d15];return _0x12ca30;};const _0x4c8275=a305_0x12ca;'use strict';const express=require(_0x4c8275('0x9')),router=express['Router'](),auth=require(_0x4c8275('0x2')),controller=require('./intSugarcrmAccount.controller');router[_0x4c8275('0x0')]('/',auth[_0x4c8275('0xc')](),controller[_0x4c8275('0xe')]),router['get'](_0x4c8275('0x3'),auth[_0x4c8275('0xc')](),controller[_0x4c8275('0x6')]),router['get'](_0x4c8275('0x1'),auth[_0x4c8275('0xc')](),controller['getConfigurations']),router['get'](_0x4c8275('0x4'),auth[_0x4c8275('0xc')](),controller['getFields']),router[_0x4c8275('0x8')]('/',auth['isAuthenticated'](),controller[_0x4c8275('0x7')]),router[_0x4c8275('0x8')]('/:id/configurations',auth[_0x4c8275('0xc')](),controller[_0x4c8275('0x5')]),router[_0x4c8275('0xd')](_0x4c8275('0x3'),auth[_0x4c8275('0xc')](),controller['update']),router[_0x4c8275('0xb')](_0x4c8275('0x3'),auth[_0x4c8275('0xc')](),controller['destroy']),module[_0x4c8275('0xa')]=router; \ No newline at end of file diff --git a/server/api/intSugarcrmAccount/intSugarcrmAccount.attributes.js b/server/api/intSugarcrmAccount/intSugarcrmAccount.attributes.js index 171e36e..d7842a5 100644 --- a/server/api/intSugarcrmAccount/intSugarcrmAccount.attributes.js +++ b/server/api/intSugarcrmAccount/intSugarcrmAccount.attributes.js @@ -1 +1 @@ -const a306_0x2642=['sequelize','STRING','remoteUri'];(function(_0x4642b9,_0x264275){const _0x469dc7=function(_0x104119){while(--_0x104119){_0x4642b9['push'](_0x4642b9['shift']());}};_0x469dc7(++_0x264275);}(a306_0x2642,0x1c3));const a306_0x469d=function(_0x4642b9,_0x264275){_0x4642b9=_0x4642b9-0x0;let _0x469dc7=a306_0x2642[_0x4642b9];return _0x469dc7;};const _0x5be06a=a306_0x469d;'use strict';const Sequelize=require(_0x5be06a('0x2'));module['exports']={'name':{'type':Sequelize[_0x5be06a('0x0')]},'description':{'type':Sequelize[_0x5be06a('0x0')]},'username':{'type':Sequelize[_0x5be06a('0x0')],'unique':'username'},'password':{'type':Sequelize['STRING']},'remoteUri':{'type':Sequelize[_0x5be06a('0x0')],'unique':_0x5be06a('0x1')},'serverUrl':{'type':Sequelize[_0x5be06a('0x0')]}}; \ No newline at end of file +const a306_0xa147=['exports','sequelize','username','remoteUri','STRING'];(function(_0x2f511c,_0xa14791){const _0x549d6e=function(_0x411dce){while(--_0x411dce){_0x2f511c['push'](_0x2f511c['shift']());}};_0x549d6e(++_0xa14791);}(a306_0xa147,0x17a));const a306_0x549d=function(_0x2f511c,_0xa14791){_0x2f511c=_0x2f511c-0x0;let _0x549d6e=a306_0xa147[_0x2f511c];return _0x549d6e;};const _0x308635=a306_0x549d;'use strict';const Sequelize=require(_0x308635('0x3'));module[_0x308635('0x2')]={'name':{'type':Sequelize['STRING']},'description':{'type':Sequelize[_0x308635('0x1')]},'username':{'type':Sequelize[_0x308635('0x1')],'unique':_0x308635('0x4')},'password':{'type':Sequelize[_0x308635('0x1')]},'remoteUri':{'type':Sequelize[_0x308635('0x1')],'unique':_0x308635('0x0')},'serverUrl':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/intSugarcrmAccount/intSugarcrmAccount.controller.js b/server/api/intSugarcrmAccount/intSugarcrmAccount.controller.js index c739d7c..ee234c1 100644 --- a/server/api/intSugarcrmAccount/intSugarcrmAccount.controller.js +++ b/server/api/intSugarcrmAccount/intSugarcrmAccount.controller.js @@ -1 +1 @@ -const a307_0x4479=['getConfigurations','duration_minutes','remoteUri','parent_type','filter','filters','key','Invalid\x20Login','include','fieldName','rawAttributes','remove','fields','direction','SugarcrmField','password','POST','name','merge','destroy','login','query','Wrong\x20credentials','options','body','count','type','JSON','AccountId','Calls','includes','nolimit','xCALLY\x20Motion\x20Integration','stringify','keys','like','order','getFields','create','undefined','lastIndexOf','index','show','getSubjects','date_start','findAll','map','rows','pick','PLAIN','getDescriptions','limit','intersection','username','label','error','parent_name','json','util','../../mysqldb','statusCode','assigned_user_id','slice','%s%s','model','parent_id','sort','../../config/logger','SugarcrmAccount','channel','Content-Range','Descriptions','where','test','status','length','../../components/integrations/configuration','send','params','sendStatus','module_fields','catch','end','then','/service/v4_1/rest.php','values','offset','set','includeAll','Subjects','duration_hours','update','findOne','SugarcrmConfiguration','attributes'];(function(_0x3a62fa,_0x447902){const _0x13a74b=function(_0x51e4be){while(--_0x51e4be){_0x3a62fa['push'](_0x3a62fa['shift']());}};_0x13a74b(++_0x447902);}(a307_0x4479,0xc0));const a307_0x13a7=function(_0x3a62fa,_0x447902){_0x3a62fa=_0x3a62fa-0x0;let _0x13a74b=a307_0x4479[_0x3a62fa];return _0x13a74b;};const _0x14b584=a307_0x13a7;'use strict';const rp=require('request-promise-native'),util=require(_0x14b584('0x38')),_=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x14b584('0x41'))('api'),db=require(_0x14b584('0x39'))['db'],{Op}=require('sequelize'),integrations=require(_0x14b584('0x4a'));function respondWithResult(_0x51e4be,_0x5c08ce){return _0x5c08ce=_0x5c08ce||0xc8,function(_0x1ae5d2){const _0x4272a6=a307_0x13a7;if(_0x1ae5d2)return _0x51e4be[_0x4272a6('0x48')](_0x5c08ce)[_0x4272a6('0x37')](_0x1ae5d2);};}function respondWithFilteredResult(_0x58e75a,_0x518704){return function(_0x38da1c){const _0x2cedbf=a307_0x13a7;if(_0x38da1c){const _0x2ab608=_0x38da1c[_0x2cedbf('0x17')],_0x231b99=_0x518704[_0x2cedbf('0x54')];let _0x1a35c0=_0x518704[_0x2cedbf('0x54')]+_0x518704['limit'],_0x2611ae;return _0x1a35c0>=_0x2ab608?(_0x1a35c0=_0x2ab608,_0x2611ae=0xc8):_0x2611ae=0xce,_0x58e75a['status'](_0x2611ae),_0x58e75a[_0x2cedbf('0x55')](_0x2cedbf('0x44'),_0x231b99+'-'+_0x1a35c0+'/'+_0x2ab608)[_0x2cedbf('0x37')](_0x38da1c);}return null;};}function saveUpdates(_0x38995f){return function(_0x16c224){const _0x1094c0=a307_0x13a7;if(_0x16c224)return _0x16c224['update'](_0x38995f)[_0x1094c0('0x51')](function(_0x5f1a0e){return _0x5f1a0e;});return null;};}function removeEntity(_0x33fb76){return function(_0x301d72){const _0x25ac54=a307_0x13a7;if(_0x301d72)return _0x301d72[_0x25ac54('0x11')]()[_0x25ac54('0x51')](function(){const _0x149347=_0x25ac54;_0x33fb76['status'](0xcc)[_0x149347('0x50')]();});};}function handleEntityNotFound(_0x5072bf){return function(_0x43ec66){const _0x57944b=a307_0x13a7;return!_0x43ec66&&_0x5072bf[_0x57944b('0x4d')](0x194),_0x43ec66;};}function handleError(_0xfd2a90,_0x413565){return _0x413565=_0x413565||0x1f4,function(_0x1d83ba){const _0x4aafc7=a307_0x13a7;logger[_0x4aafc7('0x35')](_0x1d83ba['stack']),_0x1d83ba[_0x4aafc7('0xf')]&&delete _0x1d83ba[_0x4aafc7('0xf')],_0xfd2a90[_0x4aafc7('0x48')](_0x413565)[_0x4aafc7('0x4b')](_0x1d83ba);};}exports[_0x14b584('0x27')]=function(_0x28cca6,_0x3d7eef){const _0x50847b=_0x14b584;let _0x3a14c7={};const _0x43d8e8={},_0x29e4f3={'count':0x0,'rows':[]},_0x1708b5=_['map'](db[_0x50847b('0x42')][_0x50847b('0x8')],function(_0x5a17d5){const _0x3a9ca5=_0x50847b;return{'name':_0x5a17d5[_0x3a9ca5('0x7')],'type':_0x5a17d5[_0x3a9ca5('0x18')][_0x3a9ca5('0x4')]};});_0x43d8e8['model']=_[_0x50847b('0x2c')](_0x1708b5,_0x50847b('0xf')),_0x43d8e8[_0x50847b('0x13')]=_[_0x50847b('0x20')](_0x28cca6[_0x50847b('0x13')]),_0x43d8e8[_0x50847b('0x3')]=_[_0x50847b('0x32')](_0x43d8e8['model'],_0x43d8e8[_0x50847b('0x13')]),_0x3a14c7['attributes']=_[_0x50847b('0x32')](_0x43d8e8[_0x50847b('0x3e')],qs[_0x50847b('0xa')](_0x28cca6[_0x50847b('0x13')][_0x50847b('0xa')])),_0x3a14c7[_0x50847b('0x5c')]=_0x3a14c7['attributes'][_0x50847b('0x49')]?_0x3a14c7[_0x50847b('0x5c')]:_0x43d8e8[_0x50847b('0x3e')];typeof _0x28cca6[_0x50847b('0x13')][_0x50847b('0x1d')]===_0x50847b('0x25')&&(_0x3a14c7[_0x50847b('0x31')]=qs[_0x50847b('0x31')](_0x28cca6['query'][_0x50847b('0x31')]),_0x3a14c7[_0x50847b('0x54')]=qs[_0x50847b('0x54')](_0x28cca6[_0x50847b('0x13')][_0x50847b('0x54')]));_0x3a14c7[_0x50847b('0x22')]=qs[_0x50847b('0x40')](_0x28cca6[_0x50847b('0x13')][_0x50847b('0x40')]),_0x3a14c7[_0x50847b('0x46')]=qs['filters'](_[_0x50847b('0x2e')](_0x28cca6[_0x50847b('0x13')],_0x43d8e8[_0x50847b('0x3')]),_0x1708b5);_0x28cca6['query']['filter']&&(_0x3a14c7[_0x50847b('0x46')]=_[_0x50847b('0x10')](_0x3a14c7[_0x50847b('0x46')],{[Op['or']]:_[_0x50847b('0x2c')](_0x1708b5,function(_0x6025bf){const _0x128e39=_0x50847b;if(_0x6025bf[_0x128e39('0x18')]!=='VIRTUAL'){const _0x366ceb={};return _0x366ceb[_0x6025bf[_0x128e39('0xf')]]={[Op[_0x128e39('0x21')]]:'%'+_0x28cca6[_0x128e39('0x13')]['filter']+'%'},_0x366ceb;}})}));_0x3a14c7=_['merge']({},_0x3a14c7,_0x28cca6[_0x50847b('0x15')]);const _0x58e97e={'where':_0x3a14c7[_0x50847b('0x46')]};return db[_0x50847b('0x42')][_0x50847b('0x17')](_0x58e97e)[_0x50847b('0x51')](function(_0x59c833){const _0x3ac845=_0x50847b;return _0x29e4f3[_0x3ac845('0x17')]=_0x59c833,_0x28cca6['query'][_0x3ac845('0x56')]&&(_0x3a14c7[_0x3ac845('0x6')]=[{'all':!![]}]),db[_0x3ac845('0x42')][_0x3ac845('0x2b')](_0x3a14c7);})[_0x50847b('0x51')](function(_0x385e91){const _0x309ab6=_0x50847b;return _0x29e4f3[_0x309ab6('0x2d')]=_0x385e91,_0x29e4f3;})[_0x50847b('0x51')](respondWithFilteredResult(_0x3d7eef,_0x3a14c7))[_0x50847b('0x4f')](handleError(_0x3d7eef,null));},exports[_0x14b584('0x28')]=function(_0x136cf7,_0x2eaf1d){const _0x5a9dc6=_0x14b584;let _0x3b3454={'raw':![],'where':{'id':_0x136cf7[_0x5a9dc6('0x4c')]['id']}};const _0x51802b={};return _0x51802b['model']=_['keys'](db[_0x5a9dc6('0x42')][_0x5a9dc6('0x8')]),_0x51802b[_0x5a9dc6('0x13')]=_['keys'](_0x136cf7[_0x5a9dc6('0x13')]),_0x51802b[_0x5a9dc6('0x3')]=_[_0x5a9dc6('0x32')](_0x51802b['model'],_0x51802b[_0x5a9dc6('0x13')]),_0x3b3454[_0x5a9dc6('0x5c')]=_[_0x5a9dc6('0x32')](_0x51802b['model'],qs['fields'](_0x136cf7[_0x5a9dc6('0x13')][_0x5a9dc6('0xa')])),_0x3b3454[_0x5a9dc6('0x5c')]=_0x3b3454[_0x5a9dc6('0x5c')][_0x5a9dc6('0x49')]?_0x3b3454['attributes']:_0x51802b[_0x5a9dc6('0x3e')],_0x136cf7[_0x5a9dc6('0x13')][_0x5a9dc6('0x56')]&&(_0x3b3454[_0x5a9dc6('0x6')]=[{'all':!![]}]),_0x3b3454=_[_0x5a9dc6('0x10')]({},_0x3b3454,_0x136cf7['options']),db['SugarcrmAccount'][_0x5a9dc6('0x5a')](_0x3b3454)[_0x5a9dc6('0x51')](handleEntityNotFound(_0x2eaf1d,null))['then'](respondWithResult(_0x2eaf1d,null))[_0x5a9dc6('0x4f')](handleError(_0x2eaf1d,null));},exports[_0x14b584('0x24')]=function(_0x1f7ac1,_0x2e159d){const _0x51f379=_0x14b584;return db[_0x51f379('0x42')][_0x51f379('0x24')](_0x1f7ac1[_0x51f379('0x16')],{})[_0x51f379('0x51')](respondWithResult(_0x2e159d,0xc9))[_0x51f379('0x4f')](handleError(_0x2e159d,null));},exports[_0x14b584('0x59')]=function(_0x4bc5a0,_0x28620c){const _0x52c697=_0x14b584;return _0x4bc5a0['body']['id']&&delete _0x4bc5a0[_0x52c697('0x16')]['id'],db[_0x52c697('0x42')]['findOne']({'where':{'id':_0x4bc5a0[_0x52c697('0x4c')]['id']}})[_0x52c697('0x51')](handleEntityNotFound(_0x28620c,null))[_0x52c697('0x51')](saveUpdates(_0x4bc5a0['body'],null))[_0x52c697('0x51')](respondWithResult(_0x28620c,null))[_0x52c697('0x4f')](handleError(_0x28620c,null));},exports[_0x14b584('0x11')]=function(_0x2a5423,_0xce8b3e){const _0x483d6e=_0x14b584;return db[_0x483d6e('0x42')][_0x483d6e('0x5a')]({'where':{'id':_0x2a5423[_0x483d6e('0x4c')]['id']}})[_0x483d6e('0x51')](handleEntityNotFound(_0xce8b3e,null))[_0x483d6e('0x51')](removeEntity(_0xce8b3e,null))[_0x483d6e('0x4f')](handleError(_0xce8b3e,null));},exports['getConfigurations']=function(_0x570233,_0x3209f7){const _0x46c76e=_0x14b584;let _0x46d695={};const _0x15b602={};let _0x3d7b58,_0x204ff7;return db[_0x46c76e('0x42')]['findOne']({'where':{'id':_0x570233['params']['id']}})[_0x46c76e('0x51')](handleEntityNotFound(_0x3209f7,null))['then'](function(_0x8e31d7){const _0x452784=_0x46c76e;if(_0x8e31d7)return _0x3d7b58=_0x8e31d7,_0x15b602[_0x452784('0x3e')]=_['keys'](db[_0x452784('0x5b')][_0x452784('0x8')]),_0x15b602[_0x452784('0x13')]=_[_0x452784('0x20')](_0x570233['query']),_0x15b602[_0x452784('0x3')]=_['intersection'](_0x15b602[_0x452784('0x3e')],_0x15b602['query']),_0x46d695[_0x452784('0x5c')]=_[_0x452784('0x32')](_0x15b602['model'],qs[_0x452784('0xa')](_0x570233[_0x452784('0x13')]['fields'])),_0x46d695[_0x452784('0x5c')]=_0x46d695[_0x452784('0x5c')][_0x452784('0x49')]?_0x46d695['attributes']:_0x15b602['model'],_0x46d695[_0x452784('0x22')]=qs['sort'](_0x570233[_0x452784('0x13')][_0x452784('0x40')]),_0x46d695[_0x452784('0x46')]=qs[_0x452784('0x3')](_['pick'](_0x570233['query'],_0x15b602[_0x452784('0x3')])),_0x570233[_0x452784('0x13')][_0x452784('0x2')]&&(_0x46d695[_0x452784('0x46')]=_[_0x452784('0x10')](_0x46d695[_0x452784('0x46')],{[Op['or']]:_[_0x452784('0x2c')](_0x46d695['attributes'],function(_0x2abbf3){const _0x1ef9fb=_0x452784,_0x35b7ba={};return _0x35b7ba[_0x2abbf3]={[Op[_0x1ef9fb('0x21')]]:'%'+_0x570233[_0x1ef9fb('0x13')]['filter']+'%'},_0x35b7ba;})})),_0x46d695=_[_0x452784('0x10')]({},_0x46d695,_0x570233[_0x452784('0x15')]),_0x3d7b58[_0x452784('0x5d')](_0x46d695);})['then'](function(_0xcbb0a4){const _0x421117=_0x46c76e;if(_0xcbb0a4)return _0x204ff7=_0xcbb0a4['length'],typeof _0x570233['query'][_0x421117('0x1d')]==='undefined'&&(_0x46d695[_0x421117('0x31')]=qs[_0x421117('0x31')](_0x570233[_0x421117('0x13')][_0x421117('0x31')]),_0x46d695['offset']=qs[_0x421117('0x54')](_0x570233[_0x421117('0x13')][_0x421117('0x54')])),_0x3d7b58[_0x421117('0x5d')](_0x46d695);})[_0x46c76e('0x51')](function(_0x49e44b){if(_0x49e44b)return _0x49e44b?{'count':_0x204ff7,'rows':_0x49e44b}:null;})[_0x46c76e('0x51')](respondWithResult(_0x3209f7,null))[_0x46c76e('0x4f')](handleError(_0x3209f7,null));},exports['addConfiguration']=function(_0x3e62ad,_0xbedf83){const _0x56ff5a=_0x14b584;return _0x3e62ad[_0x56ff5a('0x16')]['id']&&delete _0x3e62ad[_0x56ff5a('0x16')]['id'],db['SugarcrmAccount']['findOne']({'where':{'id':_0x3e62ad['params']['id']}})[_0x56ff5a('0x51')](handleEntityNotFound(_0xbedf83,null))[_0x56ff5a('0x51')](function(_0x4c7e7a){const _0x30591a=_0x56ff5a;if(_0x4c7e7a)return _0x3e62ad[_0x30591a('0x16')][_0x30591a('0x1a')]=_0x4c7e7a['id'],_0x3e62ad[_0x30591a('0x16')][_0x30591a('0x57')]=integrations[_0x30591a('0x29')](_0x3e62ad[_0x30591a('0x16')][_0x30591a('0x43')],_0x3e62ad[_0x30591a('0x16')][_0x30591a('0x18')]),_0x3e62ad[_0x30591a('0x16')][_0x30591a('0x45')]=integrations[_0x30591a('0x30')](_0x3e62ad[_0x30591a('0x16')][_0x30591a('0x43')],_0x3e62ad[_0x30591a('0x16')]['type']),db[_0x30591a('0x5b')][_0x30591a('0x24')](_0x3e62ad[_0x30591a('0x16')],{'include':[{'model':db[_0x30591a('0xc')],'as':_0x30591a('0x57')},{'model':db[_0x30591a('0xc')],'as':_0x30591a('0x45')}]});return null;})[_0x56ff5a('0x51')](respondWithResult(_0xbedf83,null))[_0x56ff5a('0x4f')](handleError(_0xbedf83,null));},exports[_0x14b584('0x23')]=function(_0x2b6152,_0xa0e7cb){const _0x1b7f16=_0x14b584;let _0x3e1234='';const _0x7a8694=['id','name',_0x1b7f16('0x3b'),'created_by','description',_0x1b7f16('0x2a'),_0x1b7f16('0x58'),_0x1b7f16('0x5e'),_0x1b7f16('0x3f'),_0x1b7f16('0x1'),_0x1b7f16('0x36'),_0x1b7f16('0xb')];return db[_0x1b7f16('0x42')][_0x1b7f16('0x5a')]({'where':{'id':_0x2b6152['params']['id']},'attributes':['id',_0x1b7f16('0x33'),_0x1b7f16('0xd'),_0x1b7f16('0x0')]})[_0x1b7f16('0x51')](handleEntityNotFound(_0xa0e7cb,null))[_0x1b7f16('0x51')](function(_0x2eedae){const _0x2d2624=_0x1b7f16;if(_0x2eedae){_0x3e1234=_0x2eedae[_0x2d2624('0x0')];const _0x56db76=_0x3e1234[_0x2d2624('0x3c')](-0x1);return _0x56db76==='/'&&(_0x3e1234=_0x3e1234['substring'](0x0,_0x3e1234[_0x2d2624('0x26')](_0x56db76))),rp({'method':_0x2d2624('0xe'),'uri':util['format'](_0x2d2624('0x3d'),_0x3e1234,_0x2d2624('0x52')),'json':!![],'form':{'method':_0x2d2624('0x12'),'input_type':_0x2d2624('0x19'),'response_type':_0x2d2624('0x19'),'rest_data':JSON[_0x2d2624('0x1f')]({'user_auth':{'user_name':_0x2eedae[_0x2d2624('0x33')],'password':_0x2eedae[_0x2d2624('0xd')],'encryption':_0x2d2624('0x2f')},'application':_0x2d2624('0x1e')})}});}})[_0x1b7f16('0x51')](function(_0x1db257){const _0x230429=_0x1b7f16;if(_0x1db257&&_0x1db257[_0x230429('0xf')]!==_0x230429('0x5')&&_0x1db257['name']!=='Password\x20Expired')return rp({'method':'POST','uri':util['format'](_0x230429('0x3d'),_0x3e1234,_0x230429('0x52')),'json':!![],'form':{'method':'get_module_fields','input_type':'JSON','response_type':_0x230429('0x19'),'rest_data':JSON['stringify']({'session':_0x1db257['id'],'module_name':_0x230429('0x1b')})}})[_0x230429('0x51')](function(_0x493e9b){const _0x3aee78=_0x230429;if(_0x493e9b){const _0x123f9e=_[_0x3aee78('0x53')](_0x493e9b[_0x3aee78('0x4e')]);return _[_0x3aee78('0x9')](_0x123f9e,function(_0x133782){const _0x4ab32b=_0x3aee78;return _0x7a8694[_0x4ab32b('0x1c')](_0x133782[_0x4ab32b('0xf')]);}),{'count':_0x123f9e['length'],'rows':_[_0x3aee78('0x2c')](_0x123f9e,function(_0x16d9cb){const _0x22d1d1=_0x3aee78;return{'id':_0x16d9cb[_0x22d1d1('0xf')],'name':_0x16d9cb[_0x22d1d1('0x34')],'custom':_['endsWith'](_0x16d9cb[_0x22d1d1('0xf')],'_c')?!![]:![],'options':_0x16d9cb[_0x22d1d1('0x15')]?_['map'](_['values'](_0x16d9cb[_0x22d1d1('0x15')]),function(_0x5c48cc){const _0x32ab33=_0x22d1d1;return{'name':_0x5c48cc['value'],'value':_0x5c48cc[_0x32ab33('0xf')]};}):[]};})};}})[_0x230429('0x51')](respondWithResult(_0xa0e7cb,null))['catch'](function(_0x29fb4e){const _0x2cb884=_0x230429;let _0x4811c7=_0x2b6152[_0x2cb884('0x13')][_0x2cb884('0x47')]?0x1f4:_0x29fb4e[_0x2cb884('0x3a')]||0x1f4;logger[_0x2cb884('0x35')]('getFields,\x20%s,\x20%s,\x20%s','getFields',_0x4811c7,JSON[_0x2cb884('0x1f')](_0x29fb4e)),delete _0x29fb4e['name'],_0x4811c7===0x191&&(_0x4811c7=0x190),_0xa0e7cb[_0x2cb884('0x48')](_0x4811c7)[_0x2cb884('0x4b')](_0x2b6152[_0x2cb884('0x13')]['test']?{'message':'Wrong\x20credentials','statusCode':_0x29fb4e[_0x2cb884('0x3a')]}:_0x29fb4e);});else{const _0x2d2a94=0x1f4;_0xa0e7cb[_0x230429('0x48')](_0x2d2a94)[_0x230429('0x4b')]({'message':_0x230429('0x14'),'statusCode':0x190});}});}; \ No newline at end of file +const a307_0x3819=['/service/v4_1/rest.php','api','../../config/logger','module_fields','sort','then','remoteUri','destroy','undefined','statusCode','name','rawAttributes','offset','../../mysqldb','map','update','sendStatus','SugarcrmField','json','catch','get_module_fields','xCALLY\x20Motion\x20Integration','JSON','create','fieldName','includeAll','SugarcrmAccount','end','date_start','../../components/parsers/qs','where','AccountId','filter','request-promise-native','include','attributes','getFields,\x20%s,\x20%s,\x20%s','Content-Range','like','stack','parent_type','slice','values','type','findAll','substring','Invalid\x20Login','assigned_user_id','login','error','limit','%s%s','format','getSubjects','params','getConfigurations','merge','filters','description','findOne','includes','VIRTUAL','POST','query','username','getFields','status','channel','remove','duration_minutes','order','rows','Wrong\x20credentials','show','stringify','test','model','count','Subjects','nolimit','parent_id','SugarcrmConfiguration','length','PLAIN','getDescriptions','key','direction','pick','body','password','keys','intersection','sequelize','options','Descriptions','index','lastIndexOf','send','fields'];(function(_0x52fb64,_0x381989){const _0x28b484=function(_0x3e6a4a){while(--_0x3e6a4a){_0x52fb64['push'](_0x52fb64['shift']());}};_0x28b484(++_0x381989);}(a307_0x3819,0x89));const a307_0x28b4=function(_0x52fb64,_0x381989){_0x52fb64=_0x52fb64-0x0;let _0x28b484=a307_0x3819[_0x52fb64];return _0x28b484;};const _0x3b782d=a307_0x28b4;'use strict';const rp=require(_0x3b782d('0x5e')),util=require('util'),_=require('lodash'),qs=require(_0x3b782d('0x5a')),logger=require(_0x3b782d('0x3f'))(_0x3b782d('0x3e')),db=require(_0x3b782d('0x4a'))['db'],{Op}=require(_0x3b782d('0x36')),integrations=require('../../components/integrations/configuration');function respondWithResult(_0x3e6a4a,_0x582124){return _0x582124=_0x582124||0xc8,function(_0x5394ba){const _0x1e2708=a307_0x28b4;if(_0x5394ba)return _0x3e6a4a[_0x1e2708('0x1c')](_0x582124)[_0x1e2708('0x4f')](_0x5394ba);};}function respondWithFilteredResult(_0x2afb5b,_0x45dfaa){return function(_0xacdf2b){const _0x58d1c4=a307_0x28b4;if(_0xacdf2b){const _0x144d9d=_0xacdf2b[_0x58d1c4('0x27')],_0x2fb6d8=_0x45dfaa[_0x58d1c4('0x49')];let _0xa853a=_0x45dfaa[_0x58d1c4('0x49')]+_0x45dfaa[_0x58d1c4('0xc')],_0x571184;return _0xa853a>=_0x144d9d?(_0xa853a=_0x144d9d,_0x571184=0xc8):_0x571184=0xce,_0x2afb5b[_0x58d1c4('0x1c')](_0x571184),_0x2afb5b['set'](_0x58d1c4('0x62'),_0x2fb6d8+'-'+_0xa853a+'/'+_0x144d9d)[_0x58d1c4('0x4f')](_0xacdf2b);}return null;};}function saveUpdates(_0x5b6f8d){return function(_0x1172b6){const _0x435bc8=a307_0x28b4;if(_0x1172b6)return _0x1172b6['update'](_0x5b6f8d)[_0x435bc8('0x42')](function(_0x380a71){return _0x380a71;});return null;};}function removeEntity(_0x5981a9){return function(_0x524ae2){const _0x4fe08f=a307_0x28b4;if(_0x524ae2)return _0x524ae2[_0x4fe08f('0x44')]()[_0x4fe08f('0x42')](function(){const _0x36aca1=_0x4fe08f;_0x5981a9['status'](0xcc)[_0x36aca1('0x58')]();});};}function handleEntityNotFound(_0x41866c){return function(_0x5264ca){const _0x3b14ab=a307_0x28b4;return!_0x5264ca&&_0x41866c[_0x3b14ab('0x4d')](0x194),_0x5264ca;};}function handleError(_0x3cfb0c,_0x323307){return _0x323307=_0x323307||0x1f4,function(_0x27a0bb){const _0x416cc7=a307_0x28b4;logger[_0x416cc7('0xb')](_0x27a0bb[_0x416cc7('0x1')]),_0x27a0bb[_0x416cc7('0x47')]&&delete _0x27a0bb['name'],_0x3cfb0c['status'](_0x323307)[_0x416cc7('0x3b')](_0x27a0bb);};}exports[_0x3b782d('0x39')]=function(_0x2de231,_0x92c115){const _0x5d5d7d=_0x3b782d;let _0x115d87={};const _0x299175={},_0x4702d2={'count':0x0,'rows':[]},_0x3a02c7=_[_0x5d5d7d('0x4b')](db[_0x5d5d7d('0x57')][_0x5d5d7d('0x48')],function(_0x595476){const _0x2751e3=_0x5d5d7d;return{'name':_0x595476[_0x2751e3('0x55')],'type':_0x595476[_0x2751e3('0x5')][_0x2751e3('0x2f')]};});_0x299175['model']=_['map'](_0x3a02c7,_0x5d5d7d('0x47')),_0x299175[_0x5d5d7d('0x19')]=_['keys'](_0x2de231['query']),_0x299175[_0x5d5d7d('0x13')]=_[_0x5d5d7d('0x35')](_0x299175['model'],_0x299175['query']),_0x115d87['attributes']=_[_0x5d5d7d('0x35')](_0x299175[_0x5d5d7d('0x26')],qs[_0x5d5d7d('0x3c')](_0x2de231['query'][_0x5d5d7d('0x3c')])),_0x115d87[_0x5d5d7d('0x60')]=_0x115d87['attributes']['length']?_0x115d87[_0x5d5d7d('0x60')]:_0x299175['model'];typeof _0x2de231[_0x5d5d7d('0x19')][_0x5d5d7d('0x29')]===_0x5d5d7d('0x45')&&(_0x115d87[_0x5d5d7d('0xc')]=qs[_0x5d5d7d('0xc')](_0x2de231['query'][_0x5d5d7d('0xc')]),_0x115d87[_0x5d5d7d('0x49')]=qs[_0x5d5d7d('0x49')](_0x2de231[_0x5d5d7d('0x19')][_0x5d5d7d('0x49')]));_0x115d87[_0x5d5d7d('0x20')]=qs[_0x5d5d7d('0x41')](_0x2de231[_0x5d5d7d('0x19')][_0x5d5d7d('0x41')]),_0x115d87[_0x5d5d7d('0x5b')]=qs[_0x5d5d7d('0x13')](_[_0x5d5d7d('0x31')](_0x2de231[_0x5d5d7d('0x19')],_0x299175[_0x5d5d7d('0x13')]),_0x3a02c7);_0x2de231['query'][_0x5d5d7d('0x5d')]&&(_0x115d87[_0x5d5d7d('0x5b')]=_[_0x5d5d7d('0x12')](_0x115d87[_0x5d5d7d('0x5b')],{[Op['or']]:_['map'](_0x3a02c7,function(_0x572320){const _0x5789ef=_0x5d5d7d;if(_0x572320[_0x5789ef('0x5')]!==_0x5789ef('0x17')){const _0x213020={};return _0x213020[_0x572320[_0x5789ef('0x47')]]={[Op[_0x5789ef('0x0')]]:'%'+_0x2de231[_0x5789ef('0x19')]['filter']+'%'},_0x213020;}})}));_0x115d87=_['merge']({},_0x115d87,_0x2de231[_0x5d5d7d('0x37')]);const _0x229240={'where':_0x115d87[_0x5d5d7d('0x5b')]};return db[_0x5d5d7d('0x57')][_0x5d5d7d('0x27')](_0x229240)[_0x5d5d7d('0x42')](function(_0x2f7852){const _0x2d9980=_0x5d5d7d;return _0x4702d2['count']=_0x2f7852,_0x2de231['query'][_0x2d9980('0x56')]&&(_0x115d87[_0x2d9980('0x5f')]=[{'all':!![]}]),db[_0x2d9980('0x57')][_0x2d9980('0x6')](_0x115d87);})[_0x5d5d7d('0x42')](function(_0x18ff38){const _0x286088=_0x5d5d7d;return _0x4702d2[_0x286088('0x21')]=_0x18ff38,_0x4702d2;})[_0x5d5d7d('0x42')](respondWithFilteredResult(_0x92c115,_0x115d87))[_0x5d5d7d('0x50')](handleError(_0x92c115,null));},exports[_0x3b782d('0x23')]=function(_0x2cf20a,_0x188abd){const _0x32fdbe=_0x3b782d;let _0x453027={'raw':![],'where':{'id':_0x2cf20a['params']['id']}};const _0x2e3830={};return _0x2e3830['model']=_[_0x32fdbe('0x34')](db[_0x32fdbe('0x57')][_0x32fdbe('0x48')]),_0x2e3830[_0x32fdbe('0x19')]=_['keys'](_0x2cf20a['query']),_0x2e3830[_0x32fdbe('0x13')]=_[_0x32fdbe('0x35')](_0x2e3830[_0x32fdbe('0x26')],_0x2e3830[_0x32fdbe('0x19')]),_0x453027['attributes']=_['intersection'](_0x2e3830['model'],qs['fields'](_0x2cf20a[_0x32fdbe('0x19')]['fields'])),_0x453027[_0x32fdbe('0x60')]=_0x453027[_0x32fdbe('0x60')][_0x32fdbe('0x2c')]?_0x453027['attributes']:_0x2e3830[_0x32fdbe('0x26')],_0x2cf20a[_0x32fdbe('0x19')][_0x32fdbe('0x56')]&&(_0x453027['include']=[{'all':!![]}]),_0x453027=_[_0x32fdbe('0x12')]({},_0x453027,_0x2cf20a['options']),db['SugarcrmAccount'][_0x32fdbe('0x15')](_0x453027)[_0x32fdbe('0x42')](handleEntityNotFound(_0x188abd,null))[_0x32fdbe('0x42')](respondWithResult(_0x188abd,null))[_0x32fdbe('0x50')](handleError(_0x188abd,null));},exports[_0x3b782d('0x54')]=function(_0x553dd3,_0x415092){const _0x295c4b=_0x3b782d;return db[_0x295c4b('0x57')][_0x295c4b('0x54')](_0x553dd3[_0x295c4b('0x32')],{})[_0x295c4b('0x42')](respondWithResult(_0x415092,0xc9))[_0x295c4b('0x50')](handleError(_0x415092,null));},exports[_0x3b782d('0x4c')]=function(_0xd542d0,_0x3e8d6c){const _0x38f19c=_0x3b782d;return _0xd542d0[_0x38f19c('0x32')]['id']&&delete _0xd542d0[_0x38f19c('0x32')]['id'],db[_0x38f19c('0x57')][_0x38f19c('0x15')]({'where':{'id':_0xd542d0[_0x38f19c('0x10')]['id']}})[_0x38f19c('0x42')](handleEntityNotFound(_0x3e8d6c,null))[_0x38f19c('0x42')](saveUpdates(_0xd542d0[_0x38f19c('0x32')],null))[_0x38f19c('0x42')](respondWithResult(_0x3e8d6c,null))[_0x38f19c('0x50')](handleError(_0x3e8d6c,null));},exports[_0x3b782d('0x44')]=function(_0x39bd30,_0x3efd33){const _0x64ce7c=_0x3b782d;return db['SugarcrmAccount']['findOne']({'where':{'id':_0x39bd30[_0x64ce7c('0x10')]['id']}})[_0x64ce7c('0x42')](handleEntityNotFound(_0x3efd33,null))['then'](removeEntity(_0x3efd33,null))[_0x64ce7c('0x50')](handleError(_0x3efd33,null));},exports[_0x3b782d('0x11')]=function(_0x1dff27,_0x3183d5){const _0x54bf73=_0x3b782d;let _0x430300={};const _0x3ae13c={};let _0x40ff9d,_0x133caa;return db['SugarcrmAccount'][_0x54bf73('0x15')]({'where':{'id':_0x1dff27[_0x54bf73('0x10')]['id']}})[_0x54bf73('0x42')](handleEntityNotFound(_0x3183d5,null))[_0x54bf73('0x42')](function(_0x2fca05){const _0x35202f=_0x54bf73;if(_0x2fca05)return _0x40ff9d=_0x2fca05,_0x3ae13c['model']=_[_0x35202f('0x34')](db[_0x35202f('0x2b')][_0x35202f('0x48')]),_0x3ae13c[_0x35202f('0x19')]=_[_0x35202f('0x34')](_0x1dff27['query']),_0x3ae13c[_0x35202f('0x13')]=_[_0x35202f('0x35')](_0x3ae13c[_0x35202f('0x26')],_0x3ae13c[_0x35202f('0x19')]),_0x430300[_0x35202f('0x60')]=_[_0x35202f('0x35')](_0x3ae13c[_0x35202f('0x26')],qs[_0x35202f('0x3c')](_0x1dff27['query'][_0x35202f('0x3c')])),_0x430300[_0x35202f('0x60')]=_0x430300[_0x35202f('0x60')][_0x35202f('0x2c')]?_0x430300['attributes']:_0x3ae13c[_0x35202f('0x26')],_0x430300[_0x35202f('0x20')]=qs[_0x35202f('0x41')](_0x1dff27[_0x35202f('0x19')][_0x35202f('0x41')]),_0x430300['where']=qs[_0x35202f('0x13')](_['pick'](_0x1dff27['query'],_0x3ae13c[_0x35202f('0x13')])),_0x1dff27[_0x35202f('0x19')][_0x35202f('0x5d')]&&(_0x430300[_0x35202f('0x5b')]=_['merge'](_0x430300['where'],{[Op['or']]:_[_0x35202f('0x4b')](_0x430300['attributes'],function(_0x31f375){const _0x67bdc1=_0x35202f,_0x507d94={};return _0x507d94[_0x31f375]={[Op['like']]:'%'+_0x1dff27[_0x67bdc1('0x19')][_0x67bdc1('0x5d')]+'%'},_0x507d94;})})),_0x430300=_[_0x35202f('0x12')]({},_0x430300,_0x1dff27[_0x35202f('0x37')]),_0x40ff9d['getConfigurations'](_0x430300);})[_0x54bf73('0x42')](function(_0x30aafb){const _0x5b467c=_0x54bf73;if(_0x30aafb)return _0x133caa=_0x30aafb[_0x5b467c('0x2c')],typeof _0x1dff27[_0x5b467c('0x19')][_0x5b467c('0x29')]==='undefined'&&(_0x430300['limit']=qs['limit'](_0x1dff27[_0x5b467c('0x19')][_0x5b467c('0xc')]),_0x430300[_0x5b467c('0x49')]=qs[_0x5b467c('0x49')](_0x1dff27[_0x5b467c('0x19')][_0x5b467c('0x49')])),_0x40ff9d[_0x5b467c('0x11')](_0x430300);})['then'](function(_0x16a60c){if(_0x16a60c)return _0x16a60c?{'count':_0x133caa,'rows':_0x16a60c}:null;})[_0x54bf73('0x42')](respondWithResult(_0x3183d5,null))['catch'](handleError(_0x3183d5,null));},exports['addConfiguration']=function(_0x100942,_0x24f585){const _0x3490c1=_0x3b782d;return _0x100942[_0x3490c1('0x32')]['id']&&delete _0x100942['body']['id'],db[_0x3490c1('0x57')][_0x3490c1('0x15')]({'where':{'id':_0x100942[_0x3490c1('0x10')]['id']}})[_0x3490c1('0x42')](handleEntityNotFound(_0x24f585,null))[_0x3490c1('0x42')](function(_0xba522c){const _0x22fe13=_0x3490c1;if(_0xba522c)return _0x100942[_0x22fe13('0x32')][_0x22fe13('0x5c')]=_0xba522c['id'],_0x100942[_0x22fe13('0x32')][_0x22fe13('0x28')]=integrations[_0x22fe13('0xf')](_0x100942[_0x22fe13('0x32')][_0x22fe13('0x1d')],_0x100942['body']['type']),_0x100942[_0x22fe13('0x32')]['Descriptions']=integrations[_0x22fe13('0x2e')](_0x100942['body']['channel'],_0x100942[_0x22fe13('0x32')][_0x22fe13('0x5')]),db[_0x22fe13('0x2b')][_0x22fe13('0x54')](_0x100942['body'],{'include':[{'model':db[_0x22fe13('0x4e')],'as':_0x22fe13('0x28')},{'model':db[_0x22fe13('0x4e')],'as':_0x22fe13('0x38')}]});return null;})[_0x3490c1('0x42')](respondWithResult(_0x24f585,null))[_0x3490c1('0x50')](handleError(_0x24f585,null));},exports[_0x3b782d('0x1b')]=function(_0x36d640,_0x380e32){const _0x501abb=_0x3b782d;let _0x51e29f='';const _0x175253=['id','name',_0x501abb('0x9'),'created_by',_0x501abb('0x14'),_0x501abb('0x59'),'duration_hours',_0x501abb('0x1f'),_0x501abb('0x2a'),_0x501abb('0x2'),'parent_name',_0x501abb('0x30')];return db[_0x501abb('0x57')][_0x501abb('0x15')]({'where':{'id':_0x36d640[_0x501abb('0x10')]['id']},'attributes':['id',_0x501abb('0x1a'),_0x501abb('0x33'),_0x501abb('0x43')]})[_0x501abb('0x42')](handleEntityNotFound(_0x380e32,null))[_0x501abb('0x42')](function(_0x27d8f1){const _0x55c6af=_0x501abb;if(_0x27d8f1){_0x51e29f=_0x27d8f1['remoteUri'];const _0x4ee77c=_0x51e29f[_0x55c6af('0x3')](-0x1);return _0x4ee77c==='/'&&(_0x51e29f=_0x51e29f[_0x55c6af('0x7')](0x0,_0x51e29f[_0x55c6af('0x3a')](_0x4ee77c))),rp({'method':_0x55c6af('0x18'),'uri':util[_0x55c6af('0xe')](_0x55c6af('0xd'),_0x51e29f,'/service/v4_1/rest.php'),'json':!![],'form':{'method':_0x55c6af('0xa'),'input_type':_0x55c6af('0x53'),'response_type':'JSON','rest_data':JSON['stringify']({'user_auth':{'user_name':_0x27d8f1[_0x55c6af('0x1a')],'password':_0x27d8f1[_0x55c6af('0x33')],'encryption':_0x55c6af('0x2d')},'application':_0x55c6af('0x52')})}});}})['then'](function(_0x5b2456){const _0x5c5831=_0x501abb;if(_0x5b2456&&_0x5b2456[_0x5c5831('0x47')]!==_0x5c5831('0x8')&&_0x5b2456[_0x5c5831('0x47')]!=='Password\x20Expired')return rp({'method':_0x5c5831('0x18'),'uri':util[_0x5c5831('0xe')](_0x5c5831('0xd'),_0x51e29f,_0x5c5831('0x3d')),'json':!![],'form':{'method':_0x5c5831('0x51'),'input_type':_0x5c5831('0x53'),'response_type':_0x5c5831('0x53'),'rest_data':JSON[_0x5c5831('0x24')]({'session':_0x5b2456['id'],'module_name':'Calls'})}})[_0x5c5831('0x42')](function(_0x26ed8e){const _0x1ab6bb=_0x5c5831;if(_0x26ed8e){const _0x9fd102=_[_0x1ab6bb('0x4')](_0x26ed8e[_0x1ab6bb('0x40')]);return _[_0x1ab6bb('0x1e')](_0x9fd102,function(_0xe56fa8){const _0x4b6732=_0x1ab6bb;return _0x175253[_0x4b6732('0x16')](_0xe56fa8[_0x4b6732('0x47')]);}),{'count':_0x9fd102[_0x1ab6bb('0x2c')],'rows':_['map'](_0x9fd102,function(_0x1f1fce){const _0x4154ab=_0x1ab6bb;return{'id':_0x1f1fce['name'],'name':_0x1f1fce['label'],'custom':_['endsWith'](_0x1f1fce[_0x4154ab('0x47')],'_c')?!![]:![],'options':_0x1f1fce[_0x4154ab('0x37')]?_[_0x4154ab('0x4b')](_[_0x4154ab('0x4')](_0x1f1fce[_0x4154ab('0x37')]),function(_0x24ec45){const _0x38e16c=_0x4154ab;return{'name':_0x24ec45['value'],'value':_0x24ec45[_0x38e16c('0x47')]};}):[]};})};}})[_0x5c5831('0x42')](respondWithResult(_0x380e32,null))[_0x5c5831('0x50')](function(_0x28b2a0){const _0x46c988=_0x5c5831;let _0x4b0b79=_0x36d640[_0x46c988('0x19')][_0x46c988('0x25')]?0x1f4:_0x28b2a0[_0x46c988('0x46')]||0x1f4;logger['error'](_0x46c988('0x61'),_0x46c988('0x1b'),_0x4b0b79,JSON[_0x46c988('0x24')](_0x28b2a0)),delete _0x28b2a0[_0x46c988('0x47')],_0x4b0b79===0x191&&(_0x4b0b79=0x190),_0x380e32[_0x46c988('0x1c')](_0x4b0b79)[_0x46c988('0x3b')](_0x36d640[_0x46c988('0x19')][_0x46c988('0x25')]?{'message':'Wrong\x20credentials','statusCode':_0x28b2a0[_0x46c988('0x46')]}:_0x28b2a0);});else{const _0x132d34=0x1f4;_0x380e32['status'](_0x132d34)[_0x5c5831('0x3b')]({'message':_0x5c5831('0x22'),'statusCode':0x190});}});}; \ No newline at end of file diff --git a/server/api/intSugarcrmAccount/intSugarcrmAccount.model.js b/server/api/intSugarcrmAccount/intSugarcrmAccount.model.js index 14a8dc3..558f64e 100644 --- a/server/api/intSugarcrmAccount/intSugarcrmAccount.model.js +++ b/server/api/intSugarcrmAccount/intSugarcrmAccount.model.js @@ -1 +1 @@ -const a308_0x5c09=['define','./intSugarcrmAccount.attributes','SugarcrmAccount','int_sugarcrm_accounts'];(function(_0x4534b7,_0x5c098c){const _0x2f556c=function(_0x5792a3){while(--_0x5792a3){_0x4534b7['push'](_0x4534b7['shift']());}};_0x2f556c(++_0x5c098c);}(a308_0x5c09,0x79));const a308_0x2f55=function(_0x4534b7,_0x5c098c){_0x4534b7=_0x4534b7-0x0;let _0x2f556c=a308_0x5c09[_0x4534b7];return _0x2f556c;};const _0x4a1e0d=a308_0x2f55;'use strict';const attributes=require(_0x4a1e0d('0x0'));module['exports']=function(_0x5792a3){const _0x24d141=_0x4a1e0d,_0x5622a7=_0x5792a3[_0x24d141('0x3')](_0x24d141('0x1'),attributes,{'tableName':_0x24d141('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5622a7;}; \ No newline at end of file +const a308_0xa91e=['define','./intSugarcrmAccount.attributes'];(function(_0x815734,_0xa91e23){const _0xffea1=function(_0x3cb583){while(--_0x3cb583){_0x815734['push'](_0x815734['shift']());}};_0xffea1(++_0xa91e23);}(a308_0xa91e,0x1ef));const a308_0xffea=function(_0x815734,_0xa91e23){_0x815734=_0x815734-0x0;let _0xffea1=a308_0xa91e[_0x815734];return _0xffea1;};const _0x347ea5=a308_0xffea;'use strict';const attributes=require(_0x347ea5('0x0'));module['exports']=function(_0x3cb583){const _0x5796f6=_0x347ea5,_0x59a9b4=_0x3cb583[_0x5796f6('0x1')]('SugarcrmAccount',attributes,{'tableName':'int_sugarcrm_accounts','paranoid':![],'indexes':[],'timestamps':!![]});return _0x59a9b4;}; \ No newline at end of file diff --git a/server/api/intSugarcrmAccount/intSugarcrmAccount.rpc.js b/server/api/intSugarcrmAccount/intSugarcrmAccount.rpc.js index 2c41f8a..846269f 100644 --- a/server/api/intSugarcrmAccount/intSugarcrmAccount.rpc.js +++ b/server/api/intSugarcrmAccount/intSugarcrmAccount.rpc.js @@ -1 +1 @@ -const a309_0x11e4=['error','raw','limit','lodash','findAll','../../mysqldb','include','GetSugarcrmAccount','debug','model','info','rpc','SugarcrmAccount','attributes','where','map','options','ShowSugarcrmAccount','message'];(function(_0x56444d,_0x11e4f3){const _0xd57a3e=function(_0x4a2b08){while(--_0x4a2b08){_0x56444d['push'](_0x56444d['shift']());}};_0xd57a3e(++_0x11e4f3);}(a309_0x11e4,0x116));const a309_0xd57a=function(_0x56444d,_0x11e4f3){_0x56444d=_0x56444d-0x0;let _0xd57a3e=a309_0x11e4[_0x56444d];return _0xd57a3e;};const _0x54731f=a309_0xd57a;'use strict';const _=require(_0x54731f('0xa')),db=require(_0x54731f('0xc'))['db'],logger=require('../../config/logger')(_0x54731f('0x12'));exports[_0x54731f('0xe')]=function(_0x4a2b08){const _0x13f37b=this;return new Promise(function(_0x5b1ec5,_0x533f8d){const _0x56ca16=a309_0xd57a;return db[_0x56ca16('0x0')][_0x56ca16('0xb')]({'raw':_0x4a2b08[_0x56ca16('0x4')]?_0x4a2b08[_0x56ca16('0x4')][_0x56ca16('0x8')]===undefined?!![]:![]:!![],'where':_0x4a2b08['options']?_0x4a2b08[_0x56ca16('0x4')][_0x56ca16('0x2')]||null:null,'attributes':_0x4a2b08[_0x56ca16('0x4')]?_0x4a2b08[_0x56ca16('0x4')][_0x56ca16('0x1')]||null:null,'limit':_0x4a2b08[_0x56ca16('0x4')]?_0x4a2b08[_0x56ca16('0x4')][_0x56ca16('0x9')]||null:null,'include':_0x4a2b08[_0x56ca16('0x4')]?_0x4a2b08['options']['include']?_['map'](_0x4a2b08[_0x56ca16('0x4')]['include'],function(_0x497e7c){const _0x532635=_0x56ca16;return{'model':db[_0x497e7c['model']],'as':_0x497e7c['as'],'attributes':_0x497e7c[_0x532635('0x1')],'include':_0x497e7c[_0x532635('0xd')]?_[_0x532635('0x3')](_0x497e7c[_0x532635('0xd')],function(_0x48425d){const _0x26fce0=_0x532635;return{'model':db[_0x48425d[_0x26fce0('0x10')]],'as':_0x48425d['as'],'attributes':_0x48425d['attributes'],'include':_0x48425d['include']?_['map'](_0x48425d[_0x26fce0('0xd')],function(_0x204e9b){const _0x2b7318=_0x26fce0;return{'model':db[_0x204e9b[_0x2b7318('0x10')]],'as':_0x204e9b['as'],'attributes':_0x204e9b['attributes']};}):[]};}):[]};}):[]:[]})['then'](function(_0x3d2b2b){const _0x4dba79=_0x56ca16;logger['info'](_0x4dba79('0xe'),_0x4a2b08),logger[_0x4dba79('0xf')]('GetSugarcrmAccount',_0x4a2b08,JSON['stringify'](_0x3d2b2b)),_0x5b1ec5(_0x3d2b2b);})['catch'](function(_0x9654ec){const _0x406032=_0x56ca16;logger[_0x406032('0x7')](_0x406032('0xe'),_0x9654ec[_0x406032('0x6')],_0x4a2b08),_0x533f8d(_0x13f37b[_0x406032('0x7')](0x1f4,_0x9654ec[_0x406032('0x6')]));});});},exports[_0x54731f('0x5')]=function(_0x269034){const _0x566fd8=this;return new Promise(function(_0x39e443,_0x16b662){const _0x50c60f=a309_0xd57a;return db[_0x50c60f('0x0')]['findOne']({'raw':_0x269034[_0x50c60f('0x4')]?_0x269034[_0x50c60f('0x4')]['raw']===undefined?!![]:![]:!![],'where':_0x269034[_0x50c60f('0x4')]?_0x269034[_0x50c60f('0x4')][_0x50c60f('0x2')]||null:null,'attributes':_0x269034[_0x50c60f('0x4')]?_0x269034[_0x50c60f('0x4')][_0x50c60f('0x1')]||null:null,'include':_0x269034[_0x50c60f('0x4')]?_0x269034[_0x50c60f('0x4')]['include']?_[_0x50c60f('0x3')](_0x269034['options'][_0x50c60f('0xd')],function(_0x37ca03){const _0x17e110=_0x50c60f;return{'model':db[_0x37ca03[_0x17e110('0x10')]],'as':_0x37ca03['as'],'attributes':_0x37ca03['attributes'],'include':_0x37ca03[_0x17e110('0xd')]?_[_0x17e110('0x3')](_0x37ca03[_0x17e110('0xd')],function(_0x46abec){const _0x1d1d20=_0x17e110;return{'model':db[_0x46abec[_0x1d1d20('0x10')]],'as':_0x46abec['as'],'attributes':_0x46abec[_0x1d1d20('0x1')],'include':_0x46abec[_0x1d1d20('0xd')]?_[_0x1d1d20('0x3')](_0x46abec[_0x1d1d20('0xd')],function(_0x5e4b9e){const _0x13a65d=_0x1d1d20;return{'model':db[_0x5e4b9e['model']],'as':_0x5e4b9e['as'],'attributes':_0x5e4b9e[_0x13a65d('0x1')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x3cc71b){const _0x48553f=_0x50c60f;logger[_0x48553f('0x11')]('ShowSugarcrmAccount',_0x269034),logger[_0x48553f('0xf')](_0x48553f('0x5'),_0x269034,JSON['stringify'](_0x3cc71b)),_0x39e443(_0x3cc71b);})['catch'](function(_0x325267){const _0x536205=_0x50c60f;logger[_0x536205('0x7')]('ShowSugarcrmAccount',_0x325267[_0x536205('0x6')],_0x269034),_0x16b662(_0x566fd8[_0x536205('0x7')](0x1f4,_0x325267[_0x536205('0x6')]));});});}; \ No newline at end of file +const a309_0x1ec5=['options','ShowSugarcrmAccount','map','stringify','attributes','error','findAll','catch','message','lodash','include','raw','SugarcrmAccount','debug','model','info','where','rpc','limit','then','GetSugarcrmAccount'];(function(_0x29a39e,_0x1ec510){const _0x405121=function(_0x3957b3){while(--_0x3957b3){_0x29a39e['push'](_0x29a39e['shift']());}};_0x405121(++_0x1ec510);}(a309_0x1ec5,0x177));const a309_0x4051=function(_0x29a39e,_0x1ec510){_0x29a39e=_0x29a39e-0x0;let _0x405121=a309_0x1ec5[_0x29a39e];return _0x405121;};const _0x214e3f=a309_0x4051;'use strict';const _=require(_0x214e3f('0xc')),db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x214e3f('0x14'));exports[_0x214e3f('0x2')]=function(_0x3957b3){const _0x2290d2=this;return new Promise(function(_0x1da32c,_0x139e5e){const _0x255119=a309_0x4051;return db[_0x255119('0xf')][_0x255119('0x9')]({'raw':_0x3957b3[_0x255119('0x3')]?_0x3957b3[_0x255119('0x3')][_0x255119('0xe')]===undefined?!![]:![]:!![],'where':_0x3957b3[_0x255119('0x3')]?_0x3957b3['options']['where']||null:null,'attributes':_0x3957b3[_0x255119('0x3')]?_0x3957b3[_0x255119('0x3')][_0x255119('0x7')]||null:null,'limit':_0x3957b3[_0x255119('0x3')]?_0x3957b3['options'][_0x255119('0x0')]||null:null,'include':_0x3957b3['options']?_0x3957b3[_0x255119('0x3')][_0x255119('0xd')]?_['map'](_0x3957b3[_0x255119('0x3')][_0x255119('0xd')],function(_0x2b5e35){const _0xa7f856=_0x255119;return{'model':db[_0x2b5e35['model']],'as':_0x2b5e35['as'],'attributes':_0x2b5e35[_0xa7f856('0x7')],'include':_0x2b5e35[_0xa7f856('0xd')]?_[_0xa7f856('0x5')](_0x2b5e35['include'],function(_0x1d9e2d){const _0x1981b8=_0xa7f856;return{'model':db[_0x1d9e2d['model']],'as':_0x1d9e2d['as'],'attributes':_0x1d9e2d[_0x1981b8('0x7')],'include':_0x1d9e2d[_0x1981b8('0xd')]?_[_0x1981b8('0x5')](_0x1d9e2d[_0x1981b8('0xd')],function(_0x21ec05){const _0x53c6d8=_0x1981b8;return{'model':db[_0x21ec05[_0x53c6d8('0x11')]],'as':_0x21ec05['as'],'attributes':_0x21ec05['attributes']};}):[]};}):[]};}):[]:[]})[_0x255119('0x1')](function(_0x153633){const _0x5c846c=_0x255119;logger['info'](_0x5c846c('0x2'),_0x3957b3),logger[_0x5c846c('0x10')](_0x5c846c('0x2'),_0x3957b3,JSON['stringify'](_0x153633)),_0x1da32c(_0x153633);})[_0x255119('0xa')](function(_0x57d4a5){const _0x2c7889=_0x255119;logger[_0x2c7889('0x8')](_0x2c7889('0x2'),_0x57d4a5['message'],_0x3957b3),_0x139e5e(_0x2290d2['error'](0x1f4,_0x57d4a5[_0x2c7889('0xb')]));});});},exports[_0x214e3f('0x4')]=function(_0x4687b2){const _0x35d034=this;return new Promise(function(_0x53e318,_0x140c5c){const _0x73a698=a309_0x4051;return db[_0x73a698('0xf')]['findOne']({'raw':_0x4687b2['options']?_0x4687b2[_0x73a698('0x3')]['raw']===undefined?!![]:![]:!![],'where':_0x4687b2[_0x73a698('0x3')]?_0x4687b2[_0x73a698('0x3')][_0x73a698('0x13')]||null:null,'attributes':_0x4687b2[_0x73a698('0x3')]?_0x4687b2['options'][_0x73a698('0x7')]||null:null,'include':_0x4687b2[_0x73a698('0x3')]?_0x4687b2['options'][_0x73a698('0xd')]?_[_0x73a698('0x5')](_0x4687b2['options'][_0x73a698('0xd')],function(_0x338017){const _0x5f03c4=_0x73a698;return{'model':db[_0x338017['model']],'as':_0x338017['as'],'attributes':_0x338017[_0x5f03c4('0x7')],'include':_0x338017['include']?_[_0x5f03c4('0x5')](_0x338017['include'],function(_0x2e3781){const _0x1c0d2c=_0x5f03c4;return{'model':db[_0x2e3781['model']],'as':_0x2e3781['as'],'attributes':_0x2e3781[_0x1c0d2c('0x7')],'include':_0x2e3781[_0x1c0d2c('0xd')]?_['map'](_0x2e3781[_0x1c0d2c('0xd')],function(_0x2805c9){const _0x255d6f=_0x1c0d2c;return{'model':db[_0x2805c9[_0x255d6f('0x11')]],'as':_0x2805c9['as'],'attributes':_0x2805c9[_0x255d6f('0x7')]};}):[]};}):[]};}):[]:[]})[_0x73a698('0x1')](function(_0x561a4e){const _0x40d372=_0x73a698;logger[_0x40d372('0x12')](_0x40d372('0x4'),_0x4687b2),logger[_0x40d372('0x10')]('ShowSugarcrmAccount',_0x4687b2,JSON[_0x40d372('0x6')](_0x561a4e)),_0x53e318(_0x561a4e);})['catch'](function(_0x4a4b7c){const _0x5e897b=_0x73a698;logger[_0x5e897b('0x8')](_0x5e897b('0x4'),_0x4a4b7c[_0x5e897b('0xb')],_0x4687b2),_0x140c5c(_0x35d034[_0x5e897b('0x8')](0x1f4,_0x4a4b7c[_0x5e897b('0xb')]));});});}; \ No newline at end of file diff --git a/server/api/intSugarcrmConfiguration/index.js b/server/api/intSugarcrmConfiguration/index.js index 355ff62..60ef46c 100644 --- a/server/api/intSugarcrmConfiguration/index.js +++ b/server/api/intSugarcrmConfiguration/index.js @@ -1 +1 @@ -const a310_0x815f=['/:id/subjects','delete','exports','/:id/fields','create','post','./intSugarcrmConfiguration.controller','get','../../components/auth/service','isAuthenticated','put','destroy','getSubjects','getDescriptions','update','/:id','express','index'];(function(_0x594d5b,_0x815ff0){const _0xe5bf4f=function(_0xa8c8af){while(--_0xa8c8af){_0x594d5b['push'](_0x594d5b['shift']());}};_0xe5bf4f(++_0x815ff0);}(a310_0x815f,0xcd));const a310_0xe5bf=function(_0x594d5b,_0x815ff0){_0x594d5b=_0x594d5b-0x0;let _0xe5bf4f=a310_0x815f[_0x594d5b];return _0xe5bf4f;};const _0x37549e=a310_0xe5bf;'use strict';const express=require(_0x37549e('0x9')),router=express['Router'](),auth=require(_0x37549e('0x1')),controller=require(_0x37549e('0x11'));router[_0x37549e('0x0')]('/',auth[_0x37549e('0x2')](),controller[_0x37549e('0xa')]),router[_0x37549e('0x0')](_0x37549e('0x8'),auth[_0x37549e('0x2')](),controller['show']),router[_0x37549e('0x0')](_0x37549e('0xe'),auth[_0x37549e('0x2')](),controller['getFields']),router['get'](_0x37549e('0xb'),auth[_0x37549e('0x2')](),controller[_0x37549e('0x5')]),router[_0x37549e('0x0')]('/:id/descriptions',auth[_0x37549e('0x2')](),controller[_0x37549e('0x6')]),router[_0x37549e('0x10')]('/',auth['isAuthenticated'](),controller[_0x37549e('0xf')]),router[_0x37549e('0x3')]('/:id',auth[_0x37549e('0x2')](),controller[_0x37549e('0x7')]),router[_0x37549e('0xc')]('/:id',auth[_0x37549e('0x2')](),controller[_0x37549e('0x4')]),module[_0x37549e('0xd')]=router; \ No newline at end of file +const a310_0x1357=['get','express','./intSugarcrmConfiguration.controller','show','getFields','getSubjects','getDescriptions','/:id/descriptions','/:id/fields','create','Router','destroy','put','/:id','isAuthenticated'];(function(_0x3cbc3b,_0x135732){const _0x22dac4=function(_0x168870){while(--_0x168870){_0x3cbc3b['push'](_0x3cbc3b['shift']());}};_0x22dac4(++_0x135732);}(a310_0x1357,0xab));const a310_0x22da=function(_0x3cbc3b,_0x135732){_0x3cbc3b=_0x3cbc3b-0x0;let _0x22dac4=a310_0x1357[_0x3cbc3b];return _0x22dac4;};const _0x2bf610=a310_0x22da;'use strict';const express=require(_0x2bf610('0xa')),router=express[_0x2bf610('0x4')](),auth=require('../../components/auth/service'),controller=require(_0x2bf610('0xb'));router[_0x2bf610('0x9')]('/',auth['isAuthenticated'](),controller['index']),router[_0x2bf610('0x9')](_0x2bf610('0x7'),auth['isAuthenticated'](),controller[_0x2bf610('0xc')]),router[_0x2bf610('0x9')](_0x2bf610('0x2'),auth[_0x2bf610('0x8')](),controller[_0x2bf610('0xd')]),router['get']('/:id/subjects',auth[_0x2bf610('0x8')](),controller[_0x2bf610('0xe')]),router['get'](_0x2bf610('0x1'),auth[_0x2bf610('0x8')](),controller[_0x2bf610('0x0')]),router['post']('/',auth[_0x2bf610('0x8')](),controller[_0x2bf610('0x3')]),router[_0x2bf610('0x6')](_0x2bf610('0x7'),auth['isAuthenticated'](),controller['update']),router['delete'](_0x2bf610('0x7'),auth['isAuthenticated'](),controller[_0x2bf610('0x5')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.attributes.js b/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.attributes.js index 82e414f..8dfc6b2 100644 --- a/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.attributes.js +++ b/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.attributes.js @@ -1 +1 @@ -const a311_0x50b0=['exports','sequelize','STRING'];(function(_0x2802e0,_0x50b0db){const _0x1a8e35=function(_0x3c1468){while(--_0x3c1468){_0x2802e0['push'](_0x2802e0['shift']());}};_0x1a8e35(++_0x50b0db);}(a311_0x50b0,0x82));const a311_0x1a8e=function(_0x2802e0,_0x50b0db){_0x2802e0=_0x2802e0-0x0;let _0x1a8e35=a311_0x50b0[_0x2802e0];return _0x1a8e35;};const _0x2e2fd7=a311_0x1a8e;'use strict';const Sequelize=require(_0x2e2fd7('0x0'));module[_0x2e2fd7('0x2')]={'name':{'type':Sequelize[_0x2e2fd7('0x1')]},'description':{'type':Sequelize[_0x2e2fd7('0x1')]}}; \ No newline at end of file +const a311_0x37e4=['sequelize','STRING','exports'];(function(_0xa89ad3,_0x37e42b){const _0x555acd=function(_0x1d0b3c){while(--_0x1d0b3c){_0xa89ad3['push'](_0xa89ad3['shift']());}};_0x555acd(++_0x37e42b);}(a311_0x37e4,0x196));const a311_0x555a=function(_0xa89ad3,_0x37e42b){_0xa89ad3=_0xa89ad3-0x0;let _0x555acd=a311_0x37e4[_0xa89ad3];return _0x555acd;};const _0x2cf892=a311_0x555a;'use strict';const Sequelize=require(_0x2cf892('0x2'));module[_0x2cf892('0x1')]={'name':{'type':Sequelize[_0x2cf892('0x0')]},'description':{'type':Sequelize[_0x2cf892('0x0')]}}; \ No newline at end of file diff --git a/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.controller.js b/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.controller.js index 6060721..9ea017e 100644 --- a/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.controller.js +++ b/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.controller.js @@ -1 +1 @@ -const a312_0x1f87=['nolimit','merge','filters','sequelize','count','set','getFields','sort','index','lodash','where','create','undefined','params','offset','getSubjects','key','intersection','end','fields','sendStatus','includeAll','like','attributes','include','name','../../components/parsers/qs','then','stack','map','../../config/logger','order','destroy','json','options','findAll','length','catch','getDescriptions','model','filter','status','pick','SugarcrmConfiguration','limit','rows','rawAttributes','update','SugarcrmField','query','Content-Range','type','body','findOne','show','send','VIRTUAL','keys'];(function(_0xca48f1,_0x1f870d){const _0x200895=function(_0x179e50){while(--_0x179e50){_0xca48f1['push'](_0xca48f1['shift']());}};_0x200895(++_0x1f870d);}(a312_0x1f87,0xcc));const a312_0x2008=function(_0xca48f1,_0x1f870d){_0xca48f1=_0xca48f1-0x0;let _0x200895=a312_0x1f87[_0xca48f1];return _0x200895;};const _0x2bc3b7=a312_0x2008;'use strict';const _=require(_0x2bc3b7('0x25')),qs=require(_0x2bc3b7('0x36')),logger=require(_0x2bc3b7('0x0'))('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x2bc3b7('0x1f'));function respondWithResult(_0x179e50,_0x52ab18){return _0x52ab18=_0x52ab18||0xc8,function(_0x4a37f5){const _0x56297b=a312_0x2008;if(_0x4a37f5)return _0x179e50['status'](_0x52ab18)[_0x56297b('0x3')](_0x4a37f5);};}function respondWithFilteredResult(_0x129a26,_0x740c3b){return function(_0x38ec5b){const _0x5398f6=a312_0x2008;if(_0x38ec5b){const _0x5d856f=_0x38ec5b[_0x5398f6('0x20')],_0x58fc9f=_0x740c3b[_0x5398f6('0x2a')];let _0x3a29f6=_0x740c3b[_0x5398f6('0x2a')]+_0x740c3b['limit'],_0x170a2f;return _0x3a29f6>=_0x5d856f?(_0x3a29f6=_0x5d856f,_0x170a2f=0xc8):_0x170a2f=0xce,_0x129a26[_0x5398f6('0xb')](_0x170a2f),_0x129a26[_0x5398f6('0x21')](_0x5398f6('0x14'),_0x58fc9f+'-'+_0x3a29f6+'/'+_0x5d856f)[_0x5398f6('0x3')](_0x38ec5b);}return null;};}function saveUpdates(_0x407c84){return function(_0x2d3779){const _0x564fbd=a312_0x2008;if(_0x2d3779)return _0x2d3779[_0x564fbd('0x11')](_0x407c84)[_0x564fbd('0x37')](function(_0x2769e2){return _0x2769e2;});return null;};}function removeEntity(_0x3e0e66){return function(_0x39b0bc){const _0x131a80=a312_0x2008;if(_0x39b0bc)return _0x39b0bc[_0x131a80('0x2')]()[_0x131a80('0x37')](function(){const _0xddb88d=_0x131a80;_0x3e0e66['status'](0xcc)[_0xddb88d('0x2e')]();});};}function handleEntityNotFound(_0x5639a6){return function(_0x4be820){const _0x52376a=a312_0x2008;return!_0x4be820&&_0x5639a6[_0x52376a('0x30')](0x194),_0x4be820;};}function handleError(_0x274573,_0x96d7c1){return _0x96d7c1=_0x96d7c1||0x1f4,function(_0x3afa3c){const _0x1100b4=a312_0x2008;logger['error'](_0x3afa3c[_0x1100b4('0x38')]),_0x3afa3c[_0x1100b4('0x35')]&&delete _0x3afa3c[_0x1100b4('0x35')],_0x274573[_0x1100b4('0xb')](_0x96d7c1)[_0x1100b4('0x19')](_0x3afa3c);};}exports[_0x2bc3b7('0x24')]=function(_0xcf469b,_0x14ac06){const _0x5f096a=_0x2bc3b7;let _0x3f79c6={};const _0x3cecb8={},_0x2440f7={'count':0x0,'rows':[]},_0x195c2e=_[_0x5f096a('0x39')](db[_0x5f096a('0xd')][_0x5f096a('0x10')],function(_0x1651af){const _0x57e6a0=_0x5f096a;return{'name':_0x1651af['fieldName'],'type':_0x1651af[_0x57e6a0('0x15')][_0x57e6a0('0x2c')]};});_0x3cecb8['model']=_[_0x5f096a('0x39')](_0x195c2e,_0x5f096a('0x35')),_0x3cecb8[_0x5f096a('0x13')]=_[_0x5f096a('0x1b')](_0xcf469b[_0x5f096a('0x13')]),_0x3cecb8[_0x5f096a('0x1e')]=_[_0x5f096a('0x2d')](_0x3cecb8['model'],_0x3cecb8[_0x5f096a('0x13')]),_0x3f79c6[_0x5f096a('0x33')]=_[_0x5f096a('0x2d')](_0x3cecb8[_0x5f096a('0x9')],qs[_0x5f096a('0x2f')](_0xcf469b['query'][_0x5f096a('0x2f')])),_0x3f79c6[_0x5f096a('0x33')]=_0x3f79c6[_0x5f096a('0x33')][_0x5f096a('0x6')]?_0x3f79c6[_0x5f096a('0x33')]:_0x3cecb8[_0x5f096a('0x9')];typeof _0xcf469b[_0x5f096a('0x13')][_0x5f096a('0x1c')]===_0x5f096a('0x28')&&(_0x3f79c6[_0x5f096a('0xe')]=qs['limit'](_0xcf469b['query'][_0x5f096a('0xe')]),_0x3f79c6[_0x5f096a('0x2a')]=qs['offset'](_0xcf469b['query'][_0x5f096a('0x2a')]));_0x3f79c6[_0x5f096a('0x1')]=qs[_0x5f096a('0x23')](_0xcf469b[_0x5f096a('0x13')][_0x5f096a('0x23')]),_0x3f79c6['where']=qs['filters'](_['pick'](_0xcf469b[_0x5f096a('0x13')],_0x3cecb8['filters']),_0x195c2e);_0xcf469b[_0x5f096a('0x13')][_0x5f096a('0xa')]&&(_0x3f79c6[_0x5f096a('0x26')]=_[_0x5f096a('0x1d')](_0x3f79c6[_0x5f096a('0x26')],{[Op['or']]:_[_0x5f096a('0x39')](_0x195c2e,function(_0x4cbd6d){const _0x456724=_0x5f096a;if(_0x4cbd6d[_0x456724('0x15')]!==_0x456724('0x1a')){const _0x3242b7={};return _0x3242b7[_0x4cbd6d['name']]={[Op[_0x456724('0x32')]]:'%'+_0xcf469b['query'][_0x456724('0xa')]+'%'},_0x3242b7;}})}));_0x3f79c6=_[_0x5f096a('0x1d')]({},_0x3f79c6,_0xcf469b['options']);const _0x2381e9={'where':_0x3f79c6[_0x5f096a('0x26')]};return db[_0x5f096a('0xd')][_0x5f096a('0x20')](_0x2381e9)[_0x5f096a('0x37')](function(_0x189c2f){const _0x3c96ec=_0x5f096a;return _0x2440f7['count']=_0x189c2f,_0xcf469b[_0x3c96ec('0x13')][_0x3c96ec('0x31')]&&(_0x3f79c6[_0x3c96ec('0x34')]=[{'all':!![]}]),db['SugarcrmConfiguration'][_0x3c96ec('0x5')](_0x3f79c6);})[_0x5f096a('0x37')](function(_0x2da8f4){const _0x1a5ae5=_0x5f096a;return _0x2440f7[_0x1a5ae5('0xf')]=_0x2da8f4,_0x2440f7;})[_0x5f096a('0x37')](respondWithFilteredResult(_0x14ac06,_0x3f79c6))['catch'](handleError(_0x14ac06,null));},exports[_0x2bc3b7('0x18')]=function(_0x574c8b,_0x143549){const _0x40af74=_0x2bc3b7;let _0x45a342={'raw':![],'where':{'id':_0x574c8b['params']['id']}};const _0x53c178={};return _0x53c178['model']=_['keys'](db[_0x40af74('0xd')][_0x40af74('0x10')]),_0x53c178[_0x40af74('0x13')]=_[_0x40af74('0x1b')](_0x574c8b[_0x40af74('0x13')]),_0x53c178['filters']=_[_0x40af74('0x2d')](_0x53c178[_0x40af74('0x9')],_0x53c178[_0x40af74('0x13')]),_0x45a342['attributes']=_[_0x40af74('0x2d')](_0x53c178[_0x40af74('0x9')],qs[_0x40af74('0x2f')](_0x574c8b['query'][_0x40af74('0x2f')])),_0x45a342[_0x40af74('0x33')]=_0x45a342[_0x40af74('0x33')]['length']?_0x45a342[_0x40af74('0x33')]:_0x53c178[_0x40af74('0x9')],_0x574c8b[_0x40af74('0x13')][_0x40af74('0x31')]&&(_0x45a342['include']=[{'all':!![]}]),_0x45a342=_[_0x40af74('0x1d')]({},_0x45a342,_0x574c8b[_0x40af74('0x4')]),db[_0x40af74('0xd')]['findOne'](_0x45a342)['then'](handleEntityNotFound(_0x143549,null))[_0x40af74('0x37')](respondWithResult(_0x143549,null))[_0x40af74('0x7')](handleError(_0x143549,null));},exports[_0x2bc3b7('0x27')]=function(_0xafad6a,_0x3d598a){const _0x3cd9d7=_0x2bc3b7;return db['SugarcrmConfiguration'][_0x3cd9d7('0x27')](_0xafad6a[_0x3cd9d7('0x16')],{})[_0x3cd9d7('0x37')](respondWithResult(_0x3d598a,0xc9))[_0x3cd9d7('0x7')](handleError(_0x3d598a,null));},exports['update']=function(_0x501c6f,_0x3c53d2){const _0x4ef698=_0x2bc3b7;return _0x501c6f[_0x4ef698('0x16')]['id']&&delete _0x501c6f['body']['id'],db['SugarcrmConfiguration'][_0x4ef698('0x17')]({'where':{'id':_0x501c6f[_0x4ef698('0x29')]['id']}})[_0x4ef698('0x37')](handleEntityNotFound(_0x3c53d2,null))[_0x4ef698('0x37')](saveUpdates(_0x501c6f['body'],null))[_0x4ef698('0x37')](respondWithResult(_0x3c53d2,null))[_0x4ef698('0x7')](handleError(_0x3c53d2,null));},exports[_0x2bc3b7('0x2')]=function(_0x48ae96,_0xc1cb11){const _0x4db6fd=_0x2bc3b7;return db['SugarcrmConfiguration']['findOne']({'where':{'id':_0x48ae96['params']['id']}})[_0x4db6fd('0x37')](handleEntityNotFound(_0xc1cb11,null))[_0x4db6fd('0x37')](removeEntity(_0xc1cb11,null))[_0x4db6fd('0x7')](handleError(_0xc1cb11,null));},exports[_0x2bc3b7('0x22')]=function(_0x1657d4,_0xa427b9){const _0x597d75=_0x2bc3b7;let _0x42052f={};const _0x28221b={};let _0x1ffdeb,_0x40a53d;return db[_0x597d75('0xd')]['findOne']({'where':{'id':_0x1657d4[_0x597d75('0x29')]['id']}})[_0x597d75('0x37')](handleEntityNotFound(_0xa427b9,null))[_0x597d75('0x37')](function(_0x55cf27){const _0x147dad=_0x597d75;if(_0x55cf27)return _0x1ffdeb=_0x55cf27,_0x28221b['model']=_[_0x147dad('0x1b')](db['SugarcrmField'][_0x147dad('0x10')]),_0x28221b['query']=_[_0x147dad('0x1b')](_0x1657d4[_0x147dad('0x13')]),_0x28221b['filters']=_[_0x147dad('0x2d')](_0x28221b[_0x147dad('0x9')],_0x28221b[_0x147dad('0x13')]),_0x42052f[_0x147dad('0x33')]=_[_0x147dad('0x2d')](_0x28221b[_0x147dad('0x9')],qs['fields'](_0x1657d4[_0x147dad('0x13')]['fields'])),_0x42052f['attributes']=_0x42052f[_0x147dad('0x33')][_0x147dad('0x6')]?_0x42052f['attributes']:_0x28221b[_0x147dad('0x9')],_0x42052f[_0x147dad('0x1')]=qs[_0x147dad('0x23')](_0x1657d4[_0x147dad('0x13')][_0x147dad('0x23')]),_0x42052f[_0x147dad('0x26')]=qs[_0x147dad('0x1e')](_[_0x147dad('0xc')](_0x1657d4[_0x147dad('0x13')],_0x28221b[_0x147dad('0x1e')])),_0x1657d4[_0x147dad('0x13')][_0x147dad('0xa')]&&(_0x42052f[_0x147dad('0x26')]=_[_0x147dad('0x1d')](_0x42052f[_0x147dad('0x26')],{[Op['or']]:_[_0x147dad('0x39')](_0x42052f[_0x147dad('0x33')],function(_0x59007b){const _0x16f769=_0x147dad,_0x5adfbf={};return _0x5adfbf[_0x59007b]={[Op['like']]:'%'+_0x1657d4['query'][_0x16f769('0xa')]+'%'},_0x5adfbf;})})),_0x42052f=_[_0x147dad('0x1d')]({},_0x42052f,_0x1657d4[_0x147dad('0x4')]),_0x1ffdeb['getFields'](_0x42052f);})[_0x597d75('0x37')](function(_0x338fcf){const _0x4464bf=_0x597d75;if(_0x338fcf)return _0x40a53d=_0x338fcf[_0x4464bf('0x6')],typeof _0x1657d4[_0x4464bf('0x13')][_0x4464bf('0x1c')]==='undefined'&&(_0x42052f['limit']=qs[_0x4464bf('0xe')](_0x1657d4[_0x4464bf('0x13')][_0x4464bf('0xe')]),_0x42052f[_0x4464bf('0x2a')]=qs[_0x4464bf('0x2a')](_0x1657d4[_0x4464bf('0x13')]['offset'])),_0x1ffdeb[_0x4464bf('0x22')](_0x42052f);})[_0x597d75('0x37')](function(_0x2ae757){if(_0x2ae757)return _0x2ae757?{'count':_0x40a53d,'rows':_0x2ae757}:null;})['then'](respondWithResult(_0xa427b9,null))[_0x597d75('0x7')](handleError(_0xa427b9,null));},exports[_0x2bc3b7('0x2b')]=function(_0x3f9393,_0x4de688){const _0x5cb341=_0x2bc3b7;let _0x130f7e={};const _0x1dd7d2={};let _0x22690f,_0x317d12;return db[_0x5cb341('0xd')][_0x5cb341('0x17')]({'where':{'id':_0x3f9393[_0x5cb341('0x29')]['id']}})[_0x5cb341('0x37')](handleEntityNotFound(_0x4de688,null))['then'](function(_0x391bf2){const _0xa319bb=_0x5cb341;if(_0x391bf2)return _0x22690f=_0x391bf2,_0x1dd7d2[_0xa319bb('0x9')]=_[_0xa319bb('0x1b')](db[_0xa319bb('0x12')]['rawAttributes']),_0x1dd7d2[_0xa319bb('0x13')]=_['keys'](_0x3f9393['query']),_0x1dd7d2[_0xa319bb('0x1e')]=_[_0xa319bb('0x2d')](_0x1dd7d2[_0xa319bb('0x9')],_0x1dd7d2[_0xa319bb('0x13')]),_0x130f7e[_0xa319bb('0x33')]=_[_0xa319bb('0x2d')](_0x1dd7d2[_0xa319bb('0x9')],qs['fields'](_0x3f9393[_0xa319bb('0x13')][_0xa319bb('0x2f')])),_0x130f7e[_0xa319bb('0x33')]=_0x130f7e['attributes']['length']?_0x130f7e[_0xa319bb('0x33')]:_0x1dd7d2[_0xa319bb('0x9')],_0x130f7e['order']=qs['sort'](_0x3f9393[_0xa319bb('0x13')][_0xa319bb('0x23')]),_0x130f7e[_0xa319bb('0x26')]=qs['filters'](_[_0xa319bb('0xc')](_0x3f9393[_0xa319bb('0x13')],_0x1dd7d2[_0xa319bb('0x1e')])),_0x3f9393[_0xa319bb('0x13')][_0xa319bb('0xa')]&&(_0x130f7e[_0xa319bb('0x26')]=_[_0xa319bb('0x1d')](_0x130f7e['where'],{[Op['or']]:_[_0xa319bb('0x39')](_0x130f7e[_0xa319bb('0x33')],function(_0x15676c){const _0x2586b0=_0xa319bb,_0x85805a={};return _0x85805a[_0x15676c]={[Op[_0x2586b0('0x32')]]:'%'+_0x3f9393[_0x2586b0('0x13')][_0x2586b0('0xa')]+'%'},_0x85805a;})})),_0x130f7e=_['merge']({},_0x130f7e,_0x3f9393[_0xa319bb('0x4')]),_0x22690f[_0xa319bb('0x2b')](_0x130f7e);})[_0x5cb341('0x37')](function(_0x150fd7){const _0x494769=_0x5cb341;if(_0x150fd7)return _0x317d12=_0x150fd7[_0x494769('0x6')],typeof _0x3f9393[_0x494769('0x13')][_0x494769('0x1c')]==='undefined'&&(_0x130f7e[_0x494769('0xe')]=qs[_0x494769('0xe')](_0x3f9393[_0x494769('0x13')]['limit']),_0x130f7e['offset']=qs[_0x494769('0x2a')](_0x3f9393[_0x494769('0x13')][_0x494769('0x2a')])),_0x22690f['getSubjects'](_0x130f7e);})[_0x5cb341('0x37')](function(_0x1114a8){if(_0x1114a8)return _0x1114a8?{'count':_0x317d12,'rows':_0x1114a8}:null;})[_0x5cb341('0x37')](respondWithResult(_0x4de688,null))[_0x5cb341('0x7')](handleError(_0x4de688,null));},exports[_0x2bc3b7('0x8')]=function(_0x4ccb28,_0x8dad4b){const _0x5cfe7d=_0x2bc3b7;let _0x49bded={};const _0x9dc31={};let _0x93e511,_0x28accb;return db[_0x5cfe7d('0xd')][_0x5cfe7d('0x17')]({'where':{'id':_0x4ccb28[_0x5cfe7d('0x29')]['id']}})[_0x5cfe7d('0x37')](handleEntityNotFound(_0x8dad4b,null))['then'](function(_0x40fadf){const _0x23e347=_0x5cfe7d;if(_0x40fadf)return _0x93e511=_0x40fadf,_0x9dc31[_0x23e347('0x9')]=_[_0x23e347('0x1b')](db[_0x23e347('0x12')][_0x23e347('0x10')]),_0x9dc31[_0x23e347('0x13')]=_[_0x23e347('0x1b')](_0x4ccb28[_0x23e347('0x13')]),_0x9dc31[_0x23e347('0x1e')]=_[_0x23e347('0x2d')](_0x9dc31[_0x23e347('0x9')],_0x9dc31[_0x23e347('0x13')]),_0x49bded[_0x23e347('0x33')]=_[_0x23e347('0x2d')](_0x9dc31[_0x23e347('0x9')],qs['fields'](_0x4ccb28[_0x23e347('0x13')][_0x23e347('0x2f')])),_0x49bded['attributes']=_0x49bded[_0x23e347('0x33')]['length']?_0x49bded[_0x23e347('0x33')]:_0x9dc31['model'],_0x49bded[_0x23e347('0x1')]=qs[_0x23e347('0x23')](_0x4ccb28['query'][_0x23e347('0x23')]),_0x49bded[_0x23e347('0x26')]=qs[_0x23e347('0x1e')](_[_0x23e347('0xc')](_0x4ccb28['query'],_0x9dc31[_0x23e347('0x1e')])),_0x4ccb28[_0x23e347('0x13')][_0x23e347('0xa')]&&(_0x49bded[_0x23e347('0x26')]=_['merge'](_0x49bded[_0x23e347('0x26')],{[Op['or']]:_[_0x23e347('0x39')](_0x49bded[_0x23e347('0x33')],function(_0x475087){const _0x3c2e37=_0x23e347,_0x4af8f3={};return _0x4af8f3[_0x475087]={[Op[_0x3c2e37('0x32')]]:'%'+_0x4ccb28['query'][_0x3c2e37('0xa')]+'%'},_0x4af8f3;})})),_0x49bded=_[_0x23e347('0x1d')]({},_0x49bded,_0x4ccb28[_0x23e347('0x4')]),_0x93e511[_0x23e347('0x8')](_0x49bded);})['then'](function(_0x585f7d){const _0x3a483e=_0x5cfe7d;if(_0x585f7d)return _0x28accb=_0x585f7d[_0x3a483e('0x6')],typeof _0x4ccb28['query']['nolimit']===_0x3a483e('0x28')&&(_0x49bded['limit']=qs[_0x3a483e('0xe')](_0x4ccb28[_0x3a483e('0x13')][_0x3a483e('0xe')]),_0x49bded[_0x3a483e('0x2a')]=qs[_0x3a483e('0x2a')](_0x4ccb28['query'][_0x3a483e('0x2a')])),_0x93e511[_0x3a483e('0x8')](_0x49bded);})['then'](function(_0x1eda2e){if(_0x1eda2e)return _0x1eda2e?{'count':_0x28accb,'rows':_0x1eda2e}:null;})[_0x5cfe7d('0x37')](respondWithResult(_0x8dad4b,null))[_0x5cfe7d('0x7')](handleError(_0x8dad4b,null));}; \ No newline at end of file +const a312_0x5d06=['offset','fields','options','update','where','intersection','merge','Content-Range','findAll','then','findOne','key','filters','includeAll','like','sort','SugarcrmConfiguration','set','json','catch','../../config/logger','name','getDescriptions','send','getFields','model','status','show','destroy','getSubjects','keys','limit','query','../../mysqldb','type','attributes','map','body','end','order','SugarcrmField','undefined','fieldName','create','count','sequelize','params','include','length','../../components/parsers/qs','rawAttributes','index','lodash','filter','nolimit','pick'];(function(_0x4ed729,_0x5d06cd){const _0x1c35d5=function(_0xcebc7a){while(--_0xcebc7a){_0x4ed729['push'](_0x4ed729['shift']());}};_0x1c35d5(++_0x5d06cd);}(a312_0x5d06,0x1e3));const a312_0x1c35=function(_0x4ed729,_0x5d06cd){_0x4ed729=_0x4ed729-0x0;let _0x1c35d5=a312_0x5d06[_0x4ed729];return _0x1c35d5;};const _0x3fa6bf=a312_0x1c35;'use strict';const _=require(_0x3fa6bf('0x11')),qs=require(_0x3fa6bf('0xe')),logger=require(_0x3fa6bf('0x29'))('api'),db=require(_0x3fa6bf('0x36'))['db'],{Op}=require(_0x3fa6bf('0xa'));function respondWithResult(_0xcebc7a,_0x4c96f1){return _0x4c96f1=_0x4c96f1||0xc8,function(_0x12761d){const _0x1b5625=a312_0x1c35;if(_0x12761d)return _0xcebc7a[_0x1b5625('0x2f')](_0x4c96f1)[_0x1b5625('0x27')](_0x12761d);};}function respondWithFilteredResult(_0x407ac8,_0x177e41){return function(_0x50fd8e){const _0x285346=a312_0x1c35;if(_0x50fd8e){const _0x475f5c=_0x50fd8e[_0x285346('0x9')],_0x199ee4=_0x177e41[_0x285346('0x15')];let _0x5cc544=_0x177e41[_0x285346('0x15')]+_0x177e41[_0x285346('0x34')],_0x271648;return _0x5cc544>=_0x475f5c?(_0x5cc544=_0x475f5c,_0x271648=0xc8):_0x271648=0xce,_0x407ac8['status'](_0x271648),_0x407ac8[_0x285346('0x26')](_0x285346('0x1c'),_0x199ee4+'-'+_0x5cc544+'/'+_0x475f5c)[_0x285346('0x27')](_0x50fd8e);}return null;};}function saveUpdates(_0x27a415){return function(_0x3d6d01){const _0x5191ef=a312_0x1c35;if(_0x3d6d01)return _0x3d6d01[_0x5191ef('0x18')](_0x27a415)[_0x5191ef('0x1e')](function(_0x165080){return _0x165080;});return null;};}function removeEntity(_0x531223){return function(_0x1631de){const _0x5de73c=a312_0x1c35;if(_0x1631de)return _0x1631de[_0x5de73c('0x31')]()[_0x5de73c('0x1e')](function(){const _0x35d23f=_0x5de73c;_0x531223['status'](0xcc)[_0x35d23f('0x3')]();});};}function handleEntityNotFound(_0x2e78c8){return function(_0x9fc0a3){return!_0x9fc0a3&&_0x2e78c8['sendStatus'](0x194),_0x9fc0a3;};}function handleError(_0x292f21,_0x5e53f2){return _0x5e53f2=_0x5e53f2||0x1f4,function(_0x498c1d){const _0x235ef6=a312_0x1c35;logger['error'](_0x498c1d['stack']),_0x498c1d[_0x235ef6('0x2a')]&&delete _0x498c1d[_0x235ef6('0x2a')],_0x292f21['status'](_0x5e53f2)[_0x235ef6('0x2c')](_0x498c1d);};}exports[_0x3fa6bf('0x10')]=function(_0x1aea36,_0x2fcdbb){const _0x418a90=_0x3fa6bf;let _0x1efb7b={};const _0x55210d={},_0x52f51f={'count':0x0,'rows':[]},_0x3cadb0=_['map'](db[_0x418a90('0x25')]['rawAttributes'],function(_0x39e6a6){const _0x4df4c0=_0x418a90;return{'name':_0x39e6a6[_0x4df4c0('0x7')],'type':_0x39e6a6[_0x4df4c0('0x37')][_0x4df4c0('0x20')]};});_0x55210d[_0x418a90('0x2e')]=_[_0x418a90('0x1')](_0x3cadb0,_0x418a90('0x2a')),_0x55210d[_0x418a90('0x35')]=_[_0x418a90('0x33')](_0x1aea36[_0x418a90('0x35')]),_0x55210d[_0x418a90('0x21')]=_[_0x418a90('0x1a')](_0x55210d[_0x418a90('0x2e')],_0x55210d[_0x418a90('0x35')]),_0x1efb7b[_0x418a90('0x0')]=_['intersection'](_0x55210d['model'],qs[_0x418a90('0x16')](_0x1aea36[_0x418a90('0x35')][_0x418a90('0x16')])),_0x1efb7b[_0x418a90('0x0')]=_0x1efb7b[_0x418a90('0x0')][_0x418a90('0xd')]?_0x1efb7b[_0x418a90('0x0')]:_0x55210d[_0x418a90('0x2e')];typeof _0x1aea36[_0x418a90('0x35')][_0x418a90('0x13')]===_0x418a90('0x6')&&(_0x1efb7b[_0x418a90('0x34')]=qs[_0x418a90('0x34')](_0x1aea36[_0x418a90('0x35')][_0x418a90('0x34')]),_0x1efb7b[_0x418a90('0x15')]=qs[_0x418a90('0x15')](_0x1aea36[_0x418a90('0x35')][_0x418a90('0x15')]));_0x1efb7b['order']=qs['sort'](_0x1aea36[_0x418a90('0x35')][_0x418a90('0x24')]),_0x1efb7b[_0x418a90('0x19')]=qs['filters'](_['pick'](_0x1aea36[_0x418a90('0x35')],_0x55210d[_0x418a90('0x21')]),_0x3cadb0);_0x1aea36[_0x418a90('0x35')][_0x418a90('0x12')]&&(_0x1efb7b[_0x418a90('0x19')]=_[_0x418a90('0x1b')](_0x1efb7b[_0x418a90('0x19')],{[Op['or']]:_[_0x418a90('0x1')](_0x3cadb0,function(_0x2e1bf9){const _0x55faab=_0x418a90;if(_0x2e1bf9[_0x55faab('0x37')]!=='VIRTUAL'){const _0x3be389={};return _0x3be389[_0x2e1bf9['name']]={[Op[_0x55faab('0x23')]]:'%'+_0x1aea36[_0x55faab('0x35')]['filter']+'%'},_0x3be389;}})}));_0x1efb7b=_[_0x418a90('0x1b')]({},_0x1efb7b,_0x1aea36[_0x418a90('0x17')]);const _0x26fb15={'where':_0x1efb7b[_0x418a90('0x19')]};return db[_0x418a90('0x25')][_0x418a90('0x9')](_0x26fb15)[_0x418a90('0x1e')](function(_0x4ad052){const _0x3ba0c6=_0x418a90;return _0x52f51f[_0x3ba0c6('0x9')]=_0x4ad052,_0x1aea36[_0x3ba0c6('0x35')]['includeAll']&&(_0x1efb7b[_0x3ba0c6('0xc')]=[{'all':!![]}]),db[_0x3ba0c6('0x25')][_0x3ba0c6('0x1d')](_0x1efb7b);})[_0x418a90('0x1e')](function(_0x459521){return _0x52f51f['rows']=_0x459521,_0x52f51f;})[_0x418a90('0x1e')](respondWithFilteredResult(_0x2fcdbb,_0x1efb7b))[_0x418a90('0x28')](handleError(_0x2fcdbb,null));},exports[_0x3fa6bf('0x30')]=function(_0x391de4,_0x5bce12){const _0xd974dc=_0x3fa6bf;let _0x421b95={'raw':![],'where':{'id':_0x391de4['params']['id']}};const _0x47dd3f={};return _0x47dd3f['model']=_[_0xd974dc('0x33')](db[_0xd974dc('0x25')][_0xd974dc('0xf')]),_0x47dd3f[_0xd974dc('0x35')]=_['keys'](_0x391de4[_0xd974dc('0x35')]),_0x47dd3f['filters']=_[_0xd974dc('0x1a')](_0x47dd3f['model'],_0x47dd3f[_0xd974dc('0x35')]),_0x421b95[_0xd974dc('0x0')]=_[_0xd974dc('0x1a')](_0x47dd3f['model'],qs[_0xd974dc('0x16')](_0x391de4[_0xd974dc('0x35')][_0xd974dc('0x16')])),_0x421b95['attributes']=_0x421b95[_0xd974dc('0x0')][_0xd974dc('0xd')]?_0x421b95[_0xd974dc('0x0')]:_0x47dd3f[_0xd974dc('0x2e')],_0x391de4['query'][_0xd974dc('0x22')]&&(_0x421b95[_0xd974dc('0xc')]=[{'all':!![]}]),_0x421b95=_['merge']({},_0x421b95,_0x391de4[_0xd974dc('0x17')]),db[_0xd974dc('0x25')][_0xd974dc('0x1f')](_0x421b95)['then'](handleEntityNotFound(_0x5bce12,null))[_0xd974dc('0x1e')](respondWithResult(_0x5bce12,null))['catch'](handleError(_0x5bce12,null));},exports[_0x3fa6bf('0x8')]=function(_0x109a27,_0x5a7ce0){const _0x44e623=_0x3fa6bf;return db[_0x44e623('0x25')][_0x44e623('0x8')](_0x109a27[_0x44e623('0x2')],{})['then'](respondWithResult(_0x5a7ce0,0xc9))['catch'](handleError(_0x5a7ce0,null));},exports[_0x3fa6bf('0x18')]=function(_0x4c3122,_0x4ea60c){const _0x5ba6a5=_0x3fa6bf;return _0x4c3122[_0x5ba6a5('0x2')]['id']&&delete _0x4c3122[_0x5ba6a5('0x2')]['id'],db[_0x5ba6a5('0x25')][_0x5ba6a5('0x1f')]({'where':{'id':_0x4c3122['params']['id']}})[_0x5ba6a5('0x1e')](handleEntityNotFound(_0x4ea60c,null))[_0x5ba6a5('0x1e')](saveUpdates(_0x4c3122[_0x5ba6a5('0x2')],null))['then'](respondWithResult(_0x4ea60c,null))[_0x5ba6a5('0x28')](handleError(_0x4ea60c,null));},exports[_0x3fa6bf('0x31')]=function(_0x527cb3,_0x18f2bd){const _0x249df8=_0x3fa6bf;return db[_0x249df8('0x25')]['findOne']({'where':{'id':_0x527cb3['params']['id']}})[_0x249df8('0x1e')](handleEntityNotFound(_0x18f2bd,null))[_0x249df8('0x1e')](removeEntity(_0x18f2bd,null))[_0x249df8('0x28')](handleError(_0x18f2bd,null));},exports[_0x3fa6bf('0x2d')]=function(_0x5179d0,_0x5874d0){const _0x4c4960=_0x3fa6bf;let _0x16ff07={};const _0x383a84={};let _0x38b64e,_0x5c66e4;return db[_0x4c4960('0x25')][_0x4c4960('0x1f')]({'where':{'id':_0x5179d0[_0x4c4960('0xb')]['id']}})[_0x4c4960('0x1e')](handleEntityNotFound(_0x5874d0,null))[_0x4c4960('0x1e')](function(_0x7df290){const _0x2abf21=_0x4c4960;if(_0x7df290)return _0x38b64e=_0x7df290,_0x383a84[_0x2abf21('0x2e')]=_[_0x2abf21('0x33')](db[_0x2abf21('0x5')][_0x2abf21('0xf')]),_0x383a84['query']=_[_0x2abf21('0x33')](_0x5179d0['query']),_0x383a84[_0x2abf21('0x21')]=_['intersection'](_0x383a84['model'],_0x383a84[_0x2abf21('0x35')]),_0x16ff07[_0x2abf21('0x0')]=_[_0x2abf21('0x1a')](_0x383a84[_0x2abf21('0x2e')],qs['fields'](_0x5179d0[_0x2abf21('0x35')][_0x2abf21('0x16')])),_0x16ff07[_0x2abf21('0x0')]=_0x16ff07[_0x2abf21('0x0')][_0x2abf21('0xd')]?_0x16ff07[_0x2abf21('0x0')]:_0x383a84[_0x2abf21('0x2e')],_0x16ff07[_0x2abf21('0x4')]=qs[_0x2abf21('0x24')](_0x5179d0[_0x2abf21('0x35')][_0x2abf21('0x24')]),_0x16ff07[_0x2abf21('0x19')]=qs[_0x2abf21('0x21')](_['pick'](_0x5179d0['query'],_0x383a84[_0x2abf21('0x21')])),_0x5179d0[_0x2abf21('0x35')]['filter']&&(_0x16ff07['where']=_[_0x2abf21('0x1b')](_0x16ff07['where'],{[Op['or']]:_[_0x2abf21('0x1')](_0x16ff07[_0x2abf21('0x0')],function(_0x4778d3){const _0x2c406f=_0x2abf21,_0x2b58e7={};return _0x2b58e7[_0x4778d3]={[Op[_0x2c406f('0x23')]]:'%'+_0x5179d0[_0x2c406f('0x35')][_0x2c406f('0x12')]+'%'},_0x2b58e7;})})),_0x16ff07=_[_0x2abf21('0x1b')]({},_0x16ff07,_0x5179d0[_0x2abf21('0x17')]),_0x38b64e[_0x2abf21('0x2d')](_0x16ff07);})[_0x4c4960('0x1e')](function(_0x26f42b){const _0x290be6=_0x4c4960;if(_0x26f42b)return _0x5c66e4=_0x26f42b[_0x290be6('0xd')],typeof _0x5179d0[_0x290be6('0x35')][_0x290be6('0x13')]==='undefined'&&(_0x16ff07[_0x290be6('0x34')]=qs[_0x290be6('0x34')](_0x5179d0[_0x290be6('0x35')][_0x290be6('0x34')]),_0x16ff07[_0x290be6('0x15')]=qs[_0x290be6('0x15')](_0x5179d0[_0x290be6('0x35')][_0x290be6('0x15')])),_0x38b64e['getFields'](_0x16ff07);})[_0x4c4960('0x1e')](function(_0x15bcce){if(_0x15bcce)return _0x15bcce?{'count':_0x5c66e4,'rows':_0x15bcce}:null;})['then'](respondWithResult(_0x5874d0,null))[_0x4c4960('0x28')](handleError(_0x5874d0,null));},exports[_0x3fa6bf('0x32')]=function(_0x45c279,_0x39d23e){const _0x3ccd2e=_0x3fa6bf;let _0x1a883c={};const _0x3eb6c9={};let _0x1fb384,_0x3bba33;return db[_0x3ccd2e('0x25')][_0x3ccd2e('0x1f')]({'where':{'id':_0x45c279[_0x3ccd2e('0xb')]['id']}})[_0x3ccd2e('0x1e')](handleEntityNotFound(_0x39d23e,null))[_0x3ccd2e('0x1e')](function(_0xff35bc){const _0x4057a1=_0x3ccd2e;if(_0xff35bc)return _0x1fb384=_0xff35bc,_0x3eb6c9[_0x4057a1('0x2e')]=_[_0x4057a1('0x33')](db[_0x4057a1('0x5')][_0x4057a1('0xf')]),_0x3eb6c9['query']=_[_0x4057a1('0x33')](_0x45c279[_0x4057a1('0x35')]),_0x3eb6c9[_0x4057a1('0x21')]=_[_0x4057a1('0x1a')](_0x3eb6c9[_0x4057a1('0x2e')],_0x3eb6c9[_0x4057a1('0x35')]),_0x1a883c[_0x4057a1('0x0')]=_['intersection'](_0x3eb6c9[_0x4057a1('0x2e')],qs[_0x4057a1('0x16')](_0x45c279[_0x4057a1('0x35')][_0x4057a1('0x16')])),_0x1a883c['attributes']=_0x1a883c[_0x4057a1('0x0')]['length']?_0x1a883c['attributes']:_0x3eb6c9[_0x4057a1('0x2e')],_0x1a883c[_0x4057a1('0x4')]=qs['sort'](_0x45c279['query'][_0x4057a1('0x24')]),_0x1a883c[_0x4057a1('0x19')]=qs[_0x4057a1('0x21')](_[_0x4057a1('0x14')](_0x45c279['query'],_0x3eb6c9['filters'])),_0x45c279['query']['filter']&&(_0x1a883c[_0x4057a1('0x19')]=_[_0x4057a1('0x1b')](_0x1a883c[_0x4057a1('0x19')],{[Op['or']]:_[_0x4057a1('0x1')](_0x1a883c[_0x4057a1('0x0')],function(_0x41b2e0){const _0xb7b4e9=_0x4057a1,_0x2931e2={};return _0x2931e2[_0x41b2e0]={[Op[_0xb7b4e9('0x23')]]:'%'+_0x45c279[_0xb7b4e9('0x35')][_0xb7b4e9('0x12')]+'%'},_0x2931e2;})})),_0x1a883c=_[_0x4057a1('0x1b')]({},_0x1a883c,_0x45c279[_0x4057a1('0x17')]),_0x1fb384[_0x4057a1('0x32')](_0x1a883c);})[_0x3ccd2e('0x1e')](function(_0x81084e){const _0x142ae7=_0x3ccd2e;if(_0x81084e)return _0x3bba33=_0x81084e[_0x142ae7('0xd')],typeof _0x45c279[_0x142ae7('0x35')]['nolimit']===_0x142ae7('0x6')&&(_0x1a883c['limit']=qs[_0x142ae7('0x34')](_0x45c279['query'][_0x142ae7('0x34')]),_0x1a883c['offset']=qs[_0x142ae7('0x15')](_0x45c279[_0x142ae7('0x35')][_0x142ae7('0x15')])),_0x1fb384[_0x142ae7('0x32')](_0x1a883c);})[_0x3ccd2e('0x1e')](function(_0x35bcf4){if(_0x35bcf4)return _0x35bcf4?{'count':_0x3bba33,'rows':_0x35bcf4}:null;})[_0x3ccd2e('0x1e')](respondWithResult(_0x39d23e,null))[_0x3ccd2e('0x28')](handleError(_0x39d23e,null));},exports[_0x3fa6bf('0x2b')]=function(_0x1f9934,_0x3b888c){const _0x500944=_0x3fa6bf;let _0x4bacea={};const _0x5469ef={};let _0x21acbb,_0x1c0959;return db['SugarcrmConfiguration']['findOne']({'where':{'id':_0x1f9934[_0x500944('0xb')]['id']}})['then'](handleEntityNotFound(_0x3b888c,null))[_0x500944('0x1e')](function(_0x4b9393){const _0x1d7bfa=_0x500944;if(_0x4b9393)return _0x21acbb=_0x4b9393,_0x5469ef[_0x1d7bfa('0x2e')]=_[_0x1d7bfa('0x33')](db[_0x1d7bfa('0x5')][_0x1d7bfa('0xf')]),_0x5469ef[_0x1d7bfa('0x35')]=_['keys'](_0x1f9934[_0x1d7bfa('0x35')]),_0x5469ef[_0x1d7bfa('0x21')]=_['intersection'](_0x5469ef[_0x1d7bfa('0x2e')],_0x5469ef[_0x1d7bfa('0x35')]),_0x4bacea[_0x1d7bfa('0x0')]=_[_0x1d7bfa('0x1a')](_0x5469ef['model'],qs[_0x1d7bfa('0x16')](_0x1f9934[_0x1d7bfa('0x35')][_0x1d7bfa('0x16')])),_0x4bacea[_0x1d7bfa('0x0')]=_0x4bacea[_0x1d7bfa('0x0')][_0x1d7bfa('0xd')]?_0x4bacea[_0x1d7bfa('0x0')]:_0x5469ef[_0x1d7bfa('0x2e')],_0x4bacea['order']=qs[_0x1d7bfa('0x24')](_0x1f9934[_0x1d7bfa('0x35')]['sort']),_0x4bacea[_0x1d7bfa('0x19')]=qs['filters'](_['pick'](_0x1f9934[_0x1d7bfa('0x35')],_0x5469ef[_0x1d7bfa('0x21')])),_0x1f9934[_0x1d7bfa('0x35')][_0x1d7bfa('0x12')]&&(_0x4bacea[_0x1d7bfa('0x19')]=_[_0x1d7bfa('0x1b')](_0x4bacea['where'],{[Op['or']]:_['map'](_0x4bacea[_0x1d7bfa('0x0')],function(_0x10e227){const _0x464108=_0x1d7bfa,_0x1f440f={};return _0x1f440f[_0x10e227]={[Op['like']]:'%'+_0x1f9934[_0x464108('0x35')][_0x464108('0x12')]+'%'},_0x1f440f;})})),_0x4bacea=_[_0x1d7bfa('0x1b')]({},_0x4bacea,_0x1f9934[_0x1d7bfa('0x17')]),_0x21acbb[_0x1d7bfa('0x2b')](_0x4bacea);})[_0x500944('0x1e')](function(_0x780bad){const _0x45e565=_0x500944;if(_0x780bad)return _0x1c0959=_0x780bad['length'],typeof _0x1f9934[_0x45e565('0x35')][_0x45e565('0x13')]==='undefined'&&(_0x4bacea[_0x45e565('0x34')]=qs[_0x45e565('0x34')](_0x1f9934['query'][_0x45e565('0x34')]),_0x4bacea[_0x45e565('0x15')]=qs[_0x45e565('0x15')](_0x1f9934['query']['offset'])),_0x21acbb['getDescriptions'](_0x4bacea);})[_0x500944('0x1e')](function(_0x3e37a){if(_0x3e37a)return _0x3e37a?{'count':_0x1c0959,'rows':_0x3e37a}:null;})['then'](respondWithResult(_0x3b888c,null))[_0x500944('0x28')](handleError(_0x3b888c,null));}; \ No newline at end of file diff --git a/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.model.js b/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.model.js index 3d73c0f..ace0864 100644 --- a/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.model.js +++ b/server/api/intSugarcrmConfiguration/intSugarcrmConfiguration.model.js @@ -1 +1 @@ -const a313_0x1fe5=['SugarcrmConfiguration','exports','define','int_sugarcrm_configurations','./intSugarcrmConfiguration.attributes'];(function(_0x2f582d,_0x1fe5f2){const _0x58929b=function(_0x1aff37){while(--_0x1aff37){_0x2f582d['push'](_0x2f582d['shift']());}};_0x58929b(++_0x1fe5f2);}(a313_0x1fe5,0x82));const a313_0x5892=function(_0x2f582d,_0x1fe5f2){_0x2f582d=_0x2f582d-0x0;let _0x58929b=a313_0x1fe5[_0x2f582d];return _0x58929b;};const _0x2f24c8=a313_0x5892;'use strict';const attributes=require(_0x2f24c8('0x4'));module[_0x2f24c8('0x1')]=function(_0x1aff37){const _0x34128c=_0x2f24c8,_0x293f3d=_0x1aff37[_0x34128c('0x2')](_0x34128c('0x0'),attributes,{'tableName':_0x34128c('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x293f3d;}; \ No newline at end of file +const a313_0x376f=['exports','./intSugarcrmConfiguration.attributes','define','int_sugarcrm_configurations'];(function(_0x253ac5,_0x376fbf){const _0x57acd2=function(_0x395bf0){while(--_0x395bf0){_0x253ac5['push'](_0x253ac5['shift']());}};_0x57acd2(++_0x376fbf);}(a313_0x376f,0xdf));const a313_0x57ac=function(_0x253ac5,_0x376fbf){_0x253ac5=_0x253ac5-0x0;let _0x57acd2=a313_0x376f[_0x253ac5];return _0x57acd2;};const _0xef6c17=a313_0x57ac;'use strict';const attributes=require(_0xef6c17('0x2'));module[_0xef6c17('0x1')]=function(_0x395bf0){const _0x3e3413=_0xef6c17,_0x3000ea=_0x395bf0[_0x3e3413('0x3')]('SugarcrmConfiguration',attributes,{'tableName':_0x3e3413('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3000ea;}; \ No newline at end of file diff --git a/server/api/intSugarcrmField/index.js b/server/api/intSugarcrmField/index.js index 7377190..dc2b579 100644 --- a/server/api/intSugarcrmField/index.js +++ b/server/api/intSugarcrmField/index.js @@ -1 +1 @@ -const a314_0x5e52=['./intSugarcrmField.controller','show','isAuthenticated','../../components/auth/service','exports','destroy','/:id','delete','create','get','Router','index','update','post','express'];(function(_0x4596a3,_0x5e520d){const _0x16fe47=function(_0xee872){while(--_0xee872){_0x4596a3['push'](_0x4596a3['shift']());}};_0x16fe47(++_0x5e520d);}(a314_0x5e52,0x1e0));const a314_0x16fe=function(_0x4596a3,_0x5e520d){_0x4596a3=_0x4596a3-0x0;let _0x16fe47=a314_0x5e52[_0x4596a3];return _0x16fe47;};const _0x103c36=a314_0x16fe;'use strict';const express=require(_0x103c36('0xe')),router=express[_0x103c36('0xa')](),auth=require(_0x103c36('0x3')),controller=require(_0x103c36('0x0'));router[_0x103c36('0x9')]('/',auth[_0x103c36('0x2')](),controller[_0x103c36('0xb')]),router['get'](_0x103c36('0x6'),auth['isAuthenticated'](),controller[_0x103c36('0x1')]),router[_0x103c36('0xd')]('/',auth['isAuthenticated'](),controller[_0x103c36('0x8')]),router['put']('/:id',auth['isAuthenticated'](),controller[_0x103c36('0xc')]),router[_0x103c36('0x7')](_0x103c36('0x6'),auth[_0x103c36('0x2')](),controller[_0x103c36('0x5')]),module[_0x103c36('0x4')]=router; \ No newline at end of file +const a314_0x39c9=['index','Router','get','./intSugarcrmField.controller','put','exports','express','../../components/auth/service','isAuthenticated','post','show','update','/:id'];(function(_0x566d56,_0x39c9c0){const _0x3ff539=function(_0xd90163){while(--_0xd90163){_0x566d56['push'](_0x566d56['shift']());}};_0x3ff539(++_0x39c9c0);}(a314_0x39c9,0x1c9));const a314_0x3ff5=function(_0x566d56,_0x39c9c0){_0x566d56=_0x566d56-0x0;let _0x3ff539=a314_0x39c9[_0x566d56];return _0x3ff539;};const _0x19215a=a314_0x3ff5;'use strict';const express=require(_0x19215a('0x4')),router=express[_0x19215a('0xc')](),auth=require(_0x19215a('0x5')),controller=require(_0x19215a('0x1'));router[_0x19215a('0x0')]('/',auth[_0x19215a('0x6')](),controller[_0x19215a('0xb')]),router[_0x19215a('0x0')](_0x19215a('0xa'),auth['isAuthenticated'](),controller[_0x19215a('0x8')]),router[_0x19215a('0x7')]('/',auth['isAuthenticated'](),controller['create']),router[_0x19215a('0x2')](_0x19215a('0xa'),auth[_0x19215a('0x6')](),controller[_0x19215a('0x9')]),router['delete'](_0x19215a('0xa'),auth[_0x19215a('0x6')](),controller['destroy']),module[_0x19215a('0x3')]=router; \ No newline at end of file diff --git a/server/api/intSugarcrmField/intSugarcrmField.attributes.js b/server/api/intSugarcrmField/intSugarcrmField.attributes.js index 87dc2b8..a16a026 100644 --- a/server/api/intSugarcrmField/intSugarcrmField.attributes.js +++ b/server/api/intSugarcrmField/intSugarcrmField.attributes.js @@ -1 +1 @@ -const a315_0x49c1=['customVariable','ENUM','STRING','BOOLEAN','exports','sequelize','variable','keyValue','string'];(function(_0x39b2db,_0x49c192){const _0x3fa2b1=function(_0xbecdea){while(--_0xbecdea){_0x39b2db['push'](_0x39b2db['shift']());}};_0x3fa2b1(++_0x49c192);}(a315_0x49c1,0xf0));const a315_0x3fa2=function(_0x39b2db,_0x49c192){_0x39b2db=_0x39b2db-0x0;let _0x3fa2b1=a315_0x49c1[_0x39b2db];return _0x3fa2b1;};const _0x40da33=a315_0x3fa2;'use strict';const Sequelize=require(_0x40da33('0x8'));module[_0x40da33('0x7')]={'type':{'type':Sequelize['ENUM'](_0x40da33('0x2'),_0x40da33('0x0'),_0x40da33('0x3'),_0x40da33('0x1')),'defaultValue':'string'},'content':{'type':Sequelize[_0x40da33('0x5')]},'key':{'type':Sequelize[_0x40da33('0x5')]},'keyType':{'type':Sequelize[_0x40da33('0x4')](_0x40da33('0x2'),_0x40da33('0x0'),_0x40da33('0x3'))},'keyContent':{'type':Sequelize['STRING']},'idField':{'type':Sequelize[_0x40da33('0x5')]},'nameField':{'type':Sequelize[_0x40da33('0x5')]},'customField':{'type':Sequelize[_0x40da33('0x6')],'defaultValue':!![]},'variableName':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a315_0x352a=['BOOLEAN','keyValue','STRING','sequelize','customVariable','string','exports','ENUM'];(function(_0x40e08d,_0x352a50){const _0x13b22e=function(_0x23ba17){while(--_0x23ba17){_0x40e08d['push'](_0x40e08d['shift']());}};_0x13b22e(++_0x352a50);}(a315_0x352a,0xeb));const a315_0x13b2=function(_0x40e08d,_0x352a50){_0x40e08d=_0x40e08d-0x0;let _0x13b22e=a315_0x352a[_0x40e08d];return _0x13b22e;};const _0x5cb8f3=a315_0x13b2;'use strict';const Sequelize=require(_0x5cb8f3('0x0'));module[_0x5cb8f3('0x3')]={'type':{'type':Sequelize['ENUM'](_0x5cb8f3('0x2'),'variable',_0x5cb8f3('0x1'),_0x5cb8f3('0x6')),'defaultValue':'string'},'content':{'type':Sequelize[_0x5cb8f3('0x7')]},'key':{'type':Sequelize[_0x5cb8f3('0x7')]},'keyType':{'type':Sequelize[_0x5cb8f3('0x4')]('string','variable',_0x5cb8f3('0x1'))},'keyContent':{'type':Sequelize[_0x5cb8f3('0x7')]},'idField':{'type':Sequelize[_0x5cb8f3('0x7')]},'nameField':{'type':Sequelize[_0x5cb8f3('0x7')]},'customField':{'type':Sequelize[_0x5cb8f3('0x5')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x5cb8f3('0x7')]}}; \ No newline at end of file diff --git a/server/api/intSugarcrmField/intSugarcrmField.controller.js b/server/api/intSugarcrmField/intSugarcrmField.controller.js index 4bfd95c..1b21ea5 100644 --- a/server/api/intSugarcrmField/intSugarcrmField.controller.js +++ b/server/api/intSugarcrmField/intSugarcrmField.controller.js @@ -1 +1 @@ -const a316_0x5244=['../../components/parsers/qs','filters','intersection','SugarcrmField','order','lodash','nolimit','map','params','then','offset','count','model','length','status','body','set','includeAll','sort','type','show','where','update','key','undefined','rows','attributes','json','query','keys','name','sequelize','create','include','pick','stack','VIRTUAL','Content-Range','end','fields','catch','index','limit','findAll','findOne','options','rawAttributes','merge','sendStatus'];(function(_0x43e50e,_0x524489){const _0x3e6ac3=function(_0x2f7d91){while(--_0x2f7d91){_0x43e50e['push'](_0x43e50e['shift']());}};_0x3e6ac3(++_0x524489);}(a316_0x5244,0x150));const a316_0x3e6a=function(_0x43e50e,_0x524489){_0x43e50e=_0x43e50e-0x0;let _0x3e6ac3=a316_0x5244[_0x43e50e];return _0x3e6ac3;};const _0x335ef3=a316_0x3e6a;'use strict';const _=require(_0x335ef3('0xc')),qs=require(_0x335ef3('0x7')),logger=require('../../config/logger')('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x335ef3('0x26'));function respondWithResult(_0x2f7d91,_0x2bf331){return _0x2bf331=_0x2bf331||0xc8,function(_0x3fdc47){if(_0x3fdc47)return _0x2f7d91['status'](_0x2bf331)['json'](_0x3fdc47);};}function respondWithFilteredResult(_0x32fb5c,_0x5c46f7){return function(_0x33f862){const _0x2b615e=a316_0x3e6a;if(_0x33f862){const _0x270183=_0x33f862['count'],_0x58a9c5=_0x5c46f7['offset'];let _0xbd4d0a=_0x5c46f7[_0x2b615e('0x11')]+_0x5c46f7[_0x2b615e('0x0')],_0x5664f3;return _0xbd4d0a>=_0x270183?(_0xbd4d0a=_0x270183,_0x5664f3=0xc8):_0x5664f3=0xce,_0x32fb5c[_0x2b615e('0x15')](_0x5664f3),_0x32fb5c[_0x2b615e('0x17')](_0x2b615e('0x2c'),_0x58a9c5+'-'+_0xbd4d0a+'/'+_0x270183)[_0x2b615e('0x22')](_0x33f862);}return null;};}function saveUpdates(_0x2b7909){return function(_0x40e81a){const _0x5ec6dc=a316_0x3e6a;if(_0x40e81a)return _0x40e81a['update'](_0x2b7909)[_0x5ec6dc('0x10')](function(_0x5e8967){return _0x5e8967;});return null;};}function removeEntity(_0x45f18e){return function(_0x36ed32){const _0x3fe1b1=a316_0x3e6a;if(_0x36ed32)return _0x36ed32['destroy']()[_0x3fe1b1('0x10')](function(){const _0x37cfee=_0x3fe1b1;_0x45f18e[_0x37cfee('0x15')](0xcc)[_0x37cfee('0x2d')]();});};}function handleEntityNotFound(_0x2ac6f2){return function(_0x3f5e3f){const _0x280104=a316_0x3e6a;return!_0x3f5e3f&&_0x2ac6f2[_0x280104('0x6')](0x194),_0x3f5e3f;};}function handleError(_0x197874,_0x9a98e6){return _0x9a98e6=_0x9a98e6||0x1f4,function(_0x2421d6){const _0x466f2d=a316_0x3e6a;logger['error'](_0x2421d6[_0x466f2d('0x2a')]),_0x2421d6[_0x466f2d('0x25')]&&delete _0x2421d6[_0x466f2d('0x25')],_0x197874[_0x466f2d('0x15')](_0x9a98e6)['send'](_0x2421d6);};}exports[_0x335ef3('0x30')]=function(_0x9520ba,_0x62d463){const _0x4eeae3=_0x335ef3;let _0x4b095c={};const _0x5dc29f={},_0xeb0c3d={'count':0x0,'rows':[]},_0x5de0ca=_['map'](db[_0x4eeae3('0xa')][_0x4eeae3('0x4')],function(_0x48049f){const _0x58122c=_0x4eeae3;return{'name':_0x48049f['fieldName'],'type':_0x48049f[_0x58122c('0x1a')][_0x58122c('0x1e')]};});_0x5dc29f[_0x4eeae3('0x13')]=_[_0x4eeae3('0xe')](_0x5de0ca,_0x4eeae3('0x25')),_0x5dc29f[_0x4eeae3('0x23')]=_[_0x4eeae3('0x24')](_0x9520ba[_0x4eeae3('0x23')]),_0x5dc29f['filters']=_[_0x4eeae3('0x9')](_0x5dc29f[_0x4eeae3('0x13')],_0x5dc29f['query']),_0x4b095c[_0x4eeae3('0x21')]=_[_0x4eeae3('0x9')](_0x5dc29f['model'],qs[_0x4eeae3('0x2e')](_0x9520ba['query']['fields'])),_0x4b095c['attributes']=_0x4b095c[_0x4eeae3('0x21')][_0x4eeae3('0x14')]?_0x4b095c['attributes']:_0x5dc29f[_0x4eeae3('0x13')];typeof _0x9520ba[_0x4eeae3('0x23')][_0x4eeae3('0xd')]===_0x4eeae3('0x1f')&&(_0x4b095c[_0x4eeae3('0x0')]=qs[_0x4eeae3('0x0')](_0x9520ba[_0x4eeae3('0x23')][_0x4eeae3('0x0')]),_0x4b095c[_0x4eeae3('0x11')]=qs[_0x4eeae3('0x11')](_0x9520ba[_0x4eeae3('0x23')][_0x4eeae3('0x11')]));_0x4b095c[_0x4eeae3('0xb')]=qs['sort'](_0x9520ba[_0x4eeae3('0x23')][_0x4eeae3('0x19')]),_0x4b095c[_0x4eeae3('0x1c')]=qs[_0x4eeae3('0x8')](_[_0x4eeae3('0x29')](_0x9520ba['query'],_0x5dc29f['filters']),_0x5de0ca);_0x9520ba[_0x4eeae3('0x23')]['filter']&&(_0x4b095c[_0x4eeae3('0x1c')]=_[_0x4eeae3('0x5')](_0x4b095c[_0x4eeae3('0x1c')],{[Op['or']]:_[_0x4eeae3('0xe')](_0x5de0ca,function(_0x6a3935){const _0x320de4=_0x4eeae3;if(_0x6a3935[_0x320de4('0x1a')]!==_0x320de4('0x2b')){const _0x50ca3e={};return _0x50ca3e[_0x6a3935['name']]={[Op['like']]:'%'+_0x9520ba[_0x320de4('0x23')]['filter']+'%'},_0x50ca3e;}})}));_0x4b095c=_[_0x4eeae3('0x5')]({},_0x4b095c,_0x9520ba[_0x4eeae3('0x3')]);const _0x50789e={'where':_0x4b095c['where']};return db[_0x4eeae3('0xa')][_0x4eeae3('0x12')](_0x50789e)[_0x4eeae3('0x10')](function(_0x4dcb67){const _0x1ffa89=_0x4eeae3;return _0xeb0c3d[_0x1ffa89('0x12')]=_0x4dcb67,_0x9520ba[_0x1ffa89('0x23')][_0x1ffa89('0x18')]&&(_0x4b095c[_0x1ffa89('0x28')]=[{'all':!![]}]),db[_0x1ffa89('0xa')][_0x1ffa89('0x1')](_0x4b095c);})[_0x4eeae3('0x10')](function(_0x33477c){const _0x1cd455=_0x4eeae3;return _0xeb0c3d[_0x1cd455('0x20')]=_0x33477c,_0xeb0c3d;})[_0x4eeae3('0x10')](respondWithFilteredResult(_0x62d463,_0x4b095c))[_0x4eeae3('0x2f')](handleError(_0x62d463,null));},exports[_0x335ef3('0x1b')]=function(_0xd95ffc,_0xb40858){const _0x3beb98=_0x335ef3;let _0x535674={'raw':!![],'where':{'id':_0xd95ffc[_0x3beb98('0xf')]['id']}};const _0x6fee7b={};return _0x6fee7b[_0x3beb98('0x13')]=_[_0x3beb98('0x24')](db[_0x3beb98('0xa')]['rawAttributes']),_0x6fee7b[_0x3beb98('0x23')]=_[_0x3beb98('0x24')](_0xd95ffc[_0x3beb98('0x23')]),_0x6fee7b[_0x3beb98('0x8')]=_[_0x3beb98('0x9')](_0x6fee7b[_0x3beb98('0x13')],_0x6fee7b[_0x3beb98('0x23')]),_0x535674['attributes']=_[_0x3beb98('0x9')](_0x6fee7b[_0x3beb98('0x13')],qs[_0x3beb98('0x2e')](_0xd95ffc['query'][_0x3beb98('0x2e')])),_0x535674['attributes']=_0x535674['attributes'][_0x3beb98('0x14')]?_0x535674['attributes']:_0x6fee7b[_0x3beb98('0x13')],_0xd95ffc['query'][_0x3beb98('0x18')]&&(_0x535674[_0x3beb98('0x28')]=[{'all':!![]}]),_0x535674=_[_0x3beb98('0x5')]({},_0x535674,_0xd95ffc[_0x3beb98('0x3')]),db[_0x3beb98('0xa')][_0x3beb98('0x2')](_0x535674)[_0x3beb98('0x10')](handleEntityNotFound(_0xb40858,null))[_0x3beb98('0x10')](respondWithResult(_0xb40858,null))[_0x3beb98('0x2f')](handleError(_0xb40858,null));},exports[_0x335ef3('0x27')]=function(_0x42498f,_0x5b3a37){const _0x2f0c39=_0x335ef3;return db[_0x2f0c39('0xa')]['create'](_0x42498f[_0x2f0c39('0x16')],{})[_0x2f0c39('0x10')](respondWithResult(_0x5b3a37,0xc9))['catch'](handleError(_0x5b3a37,null));},exports[_0x335ef3('0x1d')]=function(_0x2bc4b6,_0x2d468c){const _0xe5c83a=_0x335ef3;return _0x2bc4b6[_0xe5c83a('0x16')]['id']&&delete _0x2bc4b6[_0xe5c83a('0x16')]['id'],db['SugarcrmField'][_0xe5c83a('0x2')]({'where':{'id':_0x2bc4b6[_0xe5c83a('0xf')]['id']}})[_0xe5c83a('0x10')](handleEntityNotFound(_0x2d468c,null))[_0xe5c83a('0x10')](saveUpdates(_0x2bc4b6['body'],null))['then'](respondWithResult(_0x2d468c,null))['catch'](handleError(_0x2d468c,null));},exports['destroy']=function(_0x49f3c8,_0x5ec72a){const _0x10ce9d=_0x335ef3;return db[_0x10ce9d('0xa')][_0x10ce9d('0x2')]({'where':{'id':_0x49f3c8[_0x10ce9d('0xf')]['id']}})['then'](handleEntityNotFound(_0x5ec72a,null))['then'](removeEntity(_0x5ec72a,null))[_0x10ce9d('0x2f')](handleError(_0x5ec72a,null));}; \ No newline at end of file +const a316_0x1778=['params','query','offset','fields','status','include','where','show','pick','findOne','send','key','name','VIRTUAL','undefined','catch','sendStatus','type','options','set','index','body','limit','length','lodash','count','sequelize','merge','destroy','keys','rawAttributes','model','end','nolimit','then','order','update','SugarcrmField','like','filter','sort','rows','../../config/logger','../../components/parsers/qs','map','intersection','includeAll','filters','json','attributes'];(function(_0x309ff0,_0x17788c){const _0x29d3ad=function(_0x336c36){while(--_0x336c36){_0x309ff0['push'](_0x309ff0['shift']());}};_0x29d3ad(++_0x17788c);}(a316_0x1778,0x7e));const a316_0x29d3=function(_0x309ff0,_0x17788c){_0x309ff0=_0x309ff0-0x0;let _0x29d3ad=a316_0x1778[_0x309ff0];return _0x29d3ad;};const _0x1b5a70=a316_0x29d3;'use strict';const _=require(_0x1b5a70('0x30')),qs=require(_0x1b5a70('0x11')),logger=require(_0x1b5a70('0x10'))('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x1b5a70('0x0'));function respondWithResult(_0x336c36,_0x3114d3){return _0x3114d3=_0x3114d3||0xc8,function(_0x3e355c){const _0x133540=a316_0x29d3;if(_0x3e355c)return _0x336c36[_0x133540('0x1c')](_0x3114d3)[_0x133540('0x16')](_0x3e355c);};}function respondWithFilteredResult(_0x538f71,_0x656709){return function(_0x8f2b){const _0x1b1e22=a316_0x29d3;if(_0x8f2b){const _0x5a2062=_0x8f2b['count'],_0x36859b=_0x656709['offset'];let _0x372c41=_0x656709[_0x1b1e22('0x1a')]+_0x656709[_0x1b1e22('0x2e')],_0xc4f7ca;return _0x372c41>=_0x5a2062?(_0x372c41=_0x5a2062,_0xc4f7ca=0xc8):_0xc4f7ca=0xce,_0x538f71[_0x1b1e22('0x1c')](_0xc4f7ca),_0x538f71[_0x1b1e22('0x2b')]('Content-Range',_0x36859b+'-'+_0x372c41+'/'+_0x5a2062)[_0x1b1e22('0x16')](_0x8f2b);}return null;};}function saveUpdates(_0x13f833){return function(_0xdfdb65){const _0x1ed0ea=a316_0x29d3;if(_0xdfdb65)return _0xdfdb65[_0x1ed0ea('0xa')](_0x13f833)[_0x1ed0ea('0x8')](function(_0x43d59f){return _0x43d59f;});return null;};}function removeEntity(_0x4c43f1){return function(_0x3e55c1){const _0x39a85a=a316_0x29d3;if(_0x3e55c1)return _0x3e55c1[_0x39a85a('0x2')]()['then'](function(){const _0x221122=_0x39a85a;_0x4c43f1['status'](0xcc)[_0x221122('0x6')]();});};}function handleEntityNotFound(_0x3b06ae){return function(_0x261d99){const _0x214d5a=a316_0x29d3;return!_0x261d99&&_0x3b06ae[_0x214d5a('0x28')](0x194),_0x261d99;};}function handleError(_0x1a8ba4,_0x29a3e0){return _0x29a3e0=_0x29a3e0||0x1f4,function(_0x18b598){const _0x47d2b4=a316_0x29d3;logger['error'](_0x18b598['stack']),_0x18b598[_0x47d2b4('0x24')]&&delete _0x18b598[_0x47d2b4('0x24')],_0x1a8ba4[_0x47d2b4('0x1c')](_0x29a3e0)[_0x47d2b4('0x22')](_0x18b598);};}exports[_0x1b5a70('0x2c')]=function(_0x332526,_0x2b842b){const _0x27b115=_0x1b5a70;let _0x5b92bb={};const _0x574321={},_0x205544={'count':0x0,'rows':[]},_0x31f7e8=_[_0x27b115('0x12')](db[_0x27b115('0xb')][_0x27b115('0x4')],function(_0x16f0ab){const _0x5f04ff=_0x27b115;return{'name':_0x16f0ab['fieldName'],'type':_0x16f0ab[_0x5f04ff('0x29')][_0x5f04ff('0x23')]};});_0x574321['model']=_[_0x27b115('0x12')](_0x31f7e8,_0x27b115('0x24')),_0x574321[_0x27b115('0x19')]=_['keys'](_0x332526[_0x27b115('0x19')]),_0x574321['filters']=_['intersection'](_0x574321[_0x27b115('0x5')],_0x574321[_0x27b115('0x19')]),_0x5b92bb['attributes']=_[_0x27b115('0x13')](_0x574321[_0x27b115('0x5')],qs[_0x27b115('0x1b')](_0x332526[_0x27b115('0x19')][_0x27b115('0x1b')])),_0x5b92bb[_0x27b115('0x17')]=_0x5b92bb[_0x27b115('0x17')][_0x27b115('0x2f')]?_0x5b92bb[_0x27b115('0x17')]:_0x574321[_0x27b115('0x5')];typeof _0x332526[_0x27b115('0x19')][_0x27b115('0x7')]===_0x27b115('0x26')&&(_0x5b92bb['limit']=qs[_0x27b115('0x2e')](_0x332526[_0x27b115('0x19')][_0x27b115('0x2e')]),_0x5b92bb['offset']=qs[_0x27b115('0x1a')](_0x332526[_0x27b115('0x19')][_0x27b115('0x1a')]));_0x5b92bb[_0x27b115('0x9')]=qs[_0x27b115('0xe')](_0x332526[_0x27b115('0x19')]['sort']),_0x5b92bb['where']=qs[_0x27b115('0x15')](_[_0x27b115('0x20')](_0x332526[_0x27b115('0x19')],_0x574321[_0x27b115('0x15')]),_0x31f7e8);_0x332526[_0x27b115('0x19')]['filter']&&(_0x5b92bb[_0x27b115('0x1e')]=_['merge'](_0x5b92bb[_0x27b115('0x1e')],{[Op['or']]:_[_0x27b115('0x12')](_0x31f7e8,function(_0x390a1d){const _0x5a0704=_0x27b115;if(_0x390a1d['type']!==_0x5a0704('0x25')){const _0x5c9b74={};return _0x5c9b74[_0x390a1d[_0x5a0704('0x24')]]={[Op[_0x5a0704('0xc')]]:'%'+_0x332526[_0x5a0704('0x19')][_0x5a0704('0xd')]+'%'},_0x5c9b74;}})}));_0x5b92bb=_['merge']({},_0x5b92bb,_0x332526[_0x27b115('0x2a')]);const _0x7cb247={'where':_0x5b92bb[_0x27b115('0x1e')]};return db[_0x27b115('0xb')][_0x27b115('0x31')](_0x7cb247)[_0x27b115('0x8')](function(_0x75313c){const _0x573496=_0x27b115;return _0x205544[_0x573496('0x31')]=_0x75313c,_0x332526[_0x573496('0x19')][_0x573496('0x14')]&&(_0x5b92bb[_0x573496('0x1d')]=[{'all':!![]}]),db[_0x573496('0xb')]['findAll'](_0x5b92bb);})[_0x27b115('0x8')](function(_0x316ff1){const _0x27cc5f=_0x27b115;return _0x205544[_0x27cc5f('0xf')]=_0x316ff1,_0x205544;})[_0x27b115('0x8')](respondWithFilteredResult(_0x2b842b,_0x5b92bb))[_0x27b115('0x27')](handleError(_0x2b842b,null));},exports[_0x1b5a70('0x1f')]=function(_0x53dfce,_0xce05d8){const _0x24e1c8=_0x1b5a70;let _0x8c3ca3={'raw':!![],'where':{'id':_0x53dfce[_0x24e1c8('0x18')]['id']}};const _0x4b3d93={};return _0x4b3d93[_0x24e1c8('0x5')]=_['keys'](db[_0x24e1c8('0xb')][_0x24e1c8('0x4')]),_0x4b3d93[_0x24e1c8('0x19')]=_[_0x24e1c8('0x3')](_0x53dfce['query']),_0x4b3d93[_0x24e1c8('0x15')]=_[_0x24e1c8('0x13')](_0x4b3d93[_0x24e1c8('0x5')],_0x4b3d93[_0x24e1c8('0x19')]),_0x8c3ca3[_0x24e1c8('0x17')]=_['intersection'](_0x4b3d93[_0x24e1c8('0x5')],qs['fields'](_0x53dfce[_0x24e1c8('0x19')][_0x24e1c8('0x1b')])),_0x8c3ca3[_0x24e1c8('0x17')]=_0x8c3ca3[_0x24e1c8('0x17')]['length']?_0x8c3ca3[_0x24e1c8('0x17')]:_0x4b3d93[_0x24e1c8('0x5')],_0x53dfce[_0x24e1c8('0x19')]['includeAll']&&(_0x8c3ca3[_0x24e1c8('0x1d')]=[{'all':!![]}]),_0x8c3ca3=_[_0x24e1c8('0x1')]({},_0x8c3ca3,_0x53dfce[_0x24e1c8('0x2a')]),db[_0x24e1c8('0xb')][_0x24e1c8('0x21')](_0x8c3ca3)[_0x24e1c8('0x8')](handleEntityNotFound(_0xce05d8,null))[_0x24e1c8('0x8')](respondWithResult(_0xce05d8,null))[_0x24e1c8('0x27')](handleError(_0xce05d8,null));},exports['create']=function(_0x44e32f,_0x530ca4){const _0xbc3a49=_0x1b5a70;return db[_0xbc3a49('0xb')]['create'](_0x44e32f[_0xbc3a49('0x2d')],{})[_0xbc3a49('0x8')](respondWithResult(_0x530ca4,0xc9))[_0xbc3a49('0x27')](handleError(_0x530ca4,null));},exports[_0x1b5a70('0xa')]=function(_0x271223,_0x3b5aed){const _0x249521=_0x1b5a70;return _0x271223['body']['id']&&delete _0x271223['body']['id'],db[_0x249521('0xb')][_0x249521('0x21')]({'where':{'id':_0x271223[_0x249521('0x18')]['id']}})['then'](handleEntityNotFound(_0x3b5aed,null))['then'](saveUpdates(_0x271223[_0x249521('0x2d')],null))[_0x249521('0x8')](respondWithResult(_0x3b5aed,null))[_0x249521('0x27')](handleError(_0x3b5aed,null));},exports[_0x1b5a70('0x2')]=function(_0x27dd84,_0x4d983a){const _0x29e8fa=_0x1b5a70;return db[_0x29e8fa('0xb')][_0x29e8fa('0x21')]({'where':{'id':_0x27dd84[_0x29e8fa('0x18')]['id']}})[_0x29e8fa('0x8')](handleEntityNotFound(_0x4d983a,null))['then'](removeEntity(_0x4d983a,null))[_0x29e8fa('0x27')](handleError(_0x4d983a,null));}; \ No newline at end of file diff --git a/server/api/intSugarcrmField/intSugarcrmField.model.js b/server/api/intSugarcrmField/intSugarcrmField.model.js index c2f9be9..5461620 100644 --- a/server/api/intSugarcrmField/intSugarcrmField.model.js +++ b/server/api/intSugarcrmField/intSugarcrmField.model.js @@ -1 +1 @@ -const a317_0x5eec=['./intSugarcrmField.attributes','define','FieldId','sugarcrm_unique_index','idField'];(function(_0x58a714,_0x5eec4b){const _0x4674f5=function(_0x4583fa){while(--_0x4583fa){_0x58a714['push'](_0x58a714['shift']());}};_0x4674f5(++_0x5eec4b);}(a317_0x5eec,0x179));const a317_0x4674=function(_0x58a714,_0x5eec4b){_0x58a714=_0x58a714-0x0;let _0x4674f5=a317_0x5eec[_0x58a714];return _0x4674f5;};const _0x4feb43=a317_0x4674;'use strict';const attributes=require(_0x4feb43('0x3'));module['exports']=function(_0x4583fa){const _0x85d2cb=_0x4feb43,_0x4bddcf=_0x4583fa[_0x85d2cb('0x4')]('SugarcrmField',attributes,{'tableName':'int_sugarcrm_fields','paranoid':![],'indexes':[{'name':_0x85d2cb('0x1'),'fields':[_0x85d2cb('0x2'),_0x85d2cb('0x0')],'unique':!![]}],'timestamps':!![]});return _0x4bddcf;}; \ No newline at end of file +const a317_0xd31c=['./intSugarcrmField.attributes','define','int_sugarcrm_fields','FieldId','sugarcrm_unique_index','SugarcrmField','exports'];(function(_0x32ca5f,_0xd31c2b){const _0x4b2417=function(_0x421a67){while(--_0x421a67){_0x32ca5f['push'](_0x32ca5f['shift']());}};_0x4b2417(++_0xd31c2b);}(a317_0xd31c,0xb3));const a317_0x4b24=function(_0x32ca5f,_0xd31c2b){_0x32ca5f=_0x32ca5f-0x0;let _0x4b2417=a317_0xd31c[_0x32ca5f];return _0x4b2417;};const _0x44e539=a317_0x4b24;'use strict';const attributes=require(_0x44e539('0x3'));module[_0x44e539('0x2')]=function(_0x421a67){const _0x1cd193=_0x44e539,_0x29c34a=_0x421a67[_0x1cd193('0x4')](_0x1cd193('0x1'),attributes,{'tableName':_0x1cd193('0x5'),'paranoid':![],'indexes':[{'name':_0x1cd193('0x0'),'fields':['idField',_0x1cd193('0x6')],'unique':!![]}],'timestamps':!![]});return _0x29c34a;}; \ No newline at end of file diff --git a/server/api/intVtigerAccount/index.js b/server/api/intVtigerAccount/index.js index 402c606..857a63b 100644 --- a/server/api/intVtigerAccount/index.js +++ b/server/api/intVtigerAccount/index.js @@ -1 +1 @@ -const a318_0x3732=['post','Router','get','/:id','isAuthenticated','destroy','index','create','show','getFields','exports','delete','/:id/configurations'];(function(_0x165ce0,_0x37321c){const _0x1817b8=function(_0x58e559){while(--_0x58e559){_0x165ce0['push'](_0x165ce0['shift']());}};_0x1817b8(++_0x37321c);}(a318_0x3732,0x102));const a318_0x1817=function(_0x165ce0,_0x37321c){_0x165ce0=_0x165ce0-0x0;let _0x1817b8=a318_0x3732[_0x165ce0];return _0x1817b8;};const _0x8041f1=a318_0x1817;'use strict';const express=require('express'),router=express[_0x8041f1('0x3')](),auth=require('../../components/auth/service'),controller=require('./intVtigerAccount.controller');router[_0x8041f1('0x4')]('/',auth[_0x8041f1('0x6')](),controller[_0x8041f1('0x8')]),router[_0x8041f1('0x4')]('/:id',auth[_0x8041f1('0x6')](),controller[_0x8041f1('0xa')]),router['get'](_0x8041f1('0x1'),auth[_0x8041f1('0x6')](),controller['getConfigurations']),router[_0x8041f1('0x4')]('/:id/fields',auth[_0x8041f1('0x6')](),controller[_0x8041f1('0xb')]),router[_0x8041f1('0x2')]('/',auth[_0x8041f1('0x6')](),controller[_0x8041f1('0x9')]),router[_0x8041f1('0x2')]('/:id/configurations',auth[_0x8041f1('0x6')](),controller['addConfiguration']),router['put'](_0x8041f1('0x5'),auth['isAuthenticated'](),controller['update']),router[_0x8041f1('0x0')](_0x8041f1('0x5'),auth['isAuthenticated'](),controller[_0x8041f1('0x7')]),module[_0x8041f1('0xc')]=router; \ No newline at end of file +const a318_0x1362=['/:id','Router','post','isAuthenticated','put','addConfiguration','/:id/configurations','../../components/auth/service','getConfigurations','./intVtigerAccount.controller','update','/:id/fields','exports','get','getFields','delete','index'];(function(_0x38b45b,_0x13628b){const _0x4ea9c1=function(_0x52a475){while(--_0x52a475){_0x38b45b['push'](_0x38b45b['shift']());}};_0x4ea9c1(++_0x13628b);}(a318_0x1362,0x128));const a318_0x4ea9=function(_0x38b45b,_0x13628b){_0x38b45b=_0x38b45b-0x0;let _0x4ea9c1=a318_0x1362[_0x38b45b];return _0x4ea9c1;};const _0x4ca028=a318_0x4ea9;'use strict';const express=require('express'),router=express[_0x4ca028('0xb')](),auth=require(_0x4ca028('0x0')),controller=require(_0x4ca028('0x2'));router['get']('/',auth[_0x4ca028('0xd')](),controller[_0x4ca028('0x9')]),router[_0x4ca028('0x6')]('/:id',auth['isAuthenticated'](),controller['show']),router[_0x4ca028('0x6')](_0x4ca028('0x10'),auth[_0x4ca028('0xd')](),controller[_0x4ca028('0x1')]),router[_0x4ca028('0x6')](_0x4ca028('0x4'),auth[_0x4ca028('0xd')](),controller[_0x4ca028('0x7')]),router['post']('/',auth[_0x4ca028('0xd')](),controller['create']),router[_0x4ca028('0xc')](_0x4ca028('0x10'),auth['isAuthenticated'](),controller[_0x4ca028('0xf')]),router[_0x4ca028('0xe')](_0x4ca028('0xa'),auth[_0x4ca028('0xd')](),controller[_0x4ca028('0x3')]),router[_0x4ca028('0x8')]('/:id',auth[_0x4ca028('0xd')](),controller['destroy']),module[_0x4ca028('0x5')]=router; \ No newline at end of file diff --git a/server/api/intVtigerAccount/intVtigerAccount.attributes.js b/server/api/intVtigerAccount/intVtigerAccount.attributes.js index 9901a31..8d7cd89 100644 --- a/server/api/intVtigerAccount/intVtigerAccount.attributes.js +++ b/server/api/intVtigerAccount/intVtigerAccount.attributes.js @@ -1 +1 @@ -const a319_0x37d7=['STRING','HelpDesk','sequelize'];(function(_0x151121,_0x37d7e7){const _0x245f50=function(_0x412a03){while(--_0x412a03){_0x151121['push'](_0x151121['shift']());}};_0x245f50(++_0x37d7e7);}(a319_0x37d7,0x101));const a319_0x245f=function(_0x151121,_0x37d7e7){_0x151121=_0x151121-0x0;let _0x245f50=a319_0x37d7[_0x151121];return _0x245f50;};const _0x16c68a=a319_0x245f;'use strict';const Sequelize=require(_0x16c68a('0x0'));module['exports']={'name':{'type':Sequelize[_0x16c68a('0x1')],'allowNull':![]},'description':{'type':Sequelize[_0x16c68a('0x1')]},'username':{'type':Sequelize[_0x16c68a('0x1')],'allowNull':![]},'moduleName':{'type':Sequelize[_0x16c68a('0x1')],'allowNull':![],'defaultValue':_0x16c68a('0x2')},'remoteUri':{'type':Sequelize['STRING'],'allowNull':![]},'serverUrl':{'type':Sequelize[_0x16c68a('0x1')]},'accessKey':{'type':Sequelize[_0x16c68a('0x1')],'allowNull':![]}}; \ No newline at end of file +const a319_0x33c8=['HelpDesk','STRING'];(function(_0x4ea256,_0x33c883){const _0x2d76cc=function(_0x59641e){while(--_0x59641e){_0x4ea256['push'](_0x4ea256['shift']());}};_0x2d76cc(++_0x33c883);}(a319_0x33c8,0x105));const a319_0x2d76=function(_0x4ea256,_0x33c883){_0x4ea256=_0x4ea256-0x0;let _0x2d76cc=a319_0x33c8[_0x4ea256];return _0x2d76cc;};const _0x89265a=a319_0x2d76;'use strict';const Sequelize=require('sequelize');module['exports']={'name':{'type':Sequelize[_0x89265a('0x0')],'allowNull':![]},'description':{'type':Sequelize[_0x89265a('0x0')]},'username':{'type':Sequelize[_0x89265a('0x0')],'allowNull':![]},'moduleName':{'type':Sequelize[_0x89265a('0x0')],'allowNull':![],'defaultValue':_0x89265a('0x1')},'remoteUri':{'type':Sequelize[_0x89265a('0x0')],'allowNull':![]},'serverUrl':{'type':Sequelize[_0x89265a('0x0')]},'accessKey':{'type':Sequelize[_0x89265a('0x0')],'allowNull':![]}}; \ No newline at end of file diff --git a/server/api/intVtigerAccount/intVtigerAccount.controller.js b/server/api/intVtigerAccount/intVtigerAccount.controller.js index c8c99f7..c57c095 100644 --- a/server/api/intVtigerAccount/intVtigerAccount.controller.js +++ b/server/api/intVtigerAccount/intVtigerAccount.controller.js @@ -1 +1 @@ -const a320_0x40df=['AccountId','serverUrl','nolimit','error','md5','name','keys','sort','fields','then','json','substring','VtigerConfiguration','intersection','accessKey','startsWith','cf_','VtigerAccount','rows','Content-Range','include','autogenerated','update','type','map','login','request-promise-native','status','params','show','lastIndexOf','model','value','token','%s/webservice.php','test','VtigerField','api','send','sequelize','username','pick','rawAttributes','offset','stack','describe','where','query','end','Descriptions','findOne','includeAll','body','../../config/logger','limit','getSubjects','editable','attributes','getFields','undefined','owner','destroy','getchallenge','includes','POST','order','Subjects','key','success','../../mysqldb','filter','filters','moduleName','catch','create','channel','set','../../components/parsers/qs','getConfigurations','options','GET','result','length','count','Wrong\x20credentials','fieldName','description','lodash','../../components/integrations/configuration','merge','index','remove','getDescriptions','sendStatus','statusCode'];(function(_0x1f5b6b,_0x40df1f){const _0x36a22c=function(_0xb9708b){while(--_0xb9708b){_0x1f5b6b['push'](_0x1f5b6b['shift']());}};_0x36a22c(++_0x40df1f);}(a320_0x40df,0x1cc));const a320_0x36a2=function(_0x1f5b6b,_0x40df1f){_0x1f5b6b=_0x1f5b6b-0x0;let _0x36a22c=a320_0x40df[_0x1f5b6b];return _0x36a22c;};const _0x9f3ff6=a320_0x36a2;'use strict';const rp=require(_0x9f3ff6('0x29')),util=require('util'),_=require(_0x9f3ff6('0x7')),qs=require(_0x9f3ff6('0x5c')),logger=require(_0x9f3ff6('0x44'))(_0x9f3ff6('0x34')),db=require(_0x9f3ff6('0x54'))['db'],{Op}=require(_0x9f3ff6('0x36')),integrations=require(_0x9f3ff6('0x8'));function respondWithResult(_0xb9708b,_0x374818){return _0x374818=_0x374818||0xc8,function(_0x16f339){const _0x574bb7=a320_0x36a2;if(_0x16f339)return _0xb9708b[_0x574bb7('0x2a')](_0x374818)['json'](_0x16f339);};}function respondWithFilteredResult(_0x98e1c6,_0x133b56){return function(_0x317b0d){const _0x51a830=a320_0x36a2;if(_0x317b0d){const _0x20131b=_0x317b0d['count'],_0x45c169=_0x133b56['offset'];let _0x12c106=_0x133b56[_0x51a830('0x3a')]+_0x133b56[_0x51a830('0x45')],_0x551800;return _0x12c106>=_0x20131b?(_0x12c106=_0x20131b,_0x551800=0xc8):_0x551800=0xce,_0x98e1c6['status'](_0x551800),_0x98e1c6[_0x51a830('0x5b')](_0x51a830('0x22'),_0x45c169+'-'+_0x12c106+'/'+_0x20131b)[_0x51a830('0x19')](_0x317b0d);}return null;};}function saveUpdates(_0x776300){return function(_0x8fa78a){const _0x5bf0e4=a320_0x36a2;if(_0x8fa78a)return _0x8fa78a[_0x5bf0e4('0x25')](_0x776300)[_0x5bf0e4('0x18')](function(_0x457d8e){return _0x457d8e;});return null;};}function removeEntity(_0x28dbb5){return function(_0xb5fe2f){const _0x403002=a320_0x36a2;if(_0xb5fe2f)return _0xb5fe2f['destroy']()[_0x403002('0x18')](function(){const _0x4772b6=_0x403002;_0x28dbb5['status'](0xcc)[_0x4772b6('0x3f')]();});};}function handleEntityNotFound(_0x37aff4){return function(_0x431e28){const _0x56000c=a320_0x36a2;return!_0x431e28&&_0x37aff4[_0x56000c('0xd')](0x194),_0x431e28;};}function handleError(_0x2ce8e3,_0x2f16aa){return _0x2f16aa=_0x2f16aa||0x1f4,function(_0x23a819){const _0x2cecfc=a320_0x36a2;logger[_0x2cecfc('0x12')](_0x23a819[_0x2cecfc('0x3b')]),_0x23a819[_0x2cecfc('0x14')]&&delete _0x23a819[_0x2cecfc('0x14')],_0x2ce8e3[_0x2cecfc('0x2a')](_0x2f16aa)[_0x2cecfc('0x35')](_0x23a819);};}exports[_0x9f3ff6('0xa')]=function(_0x4013e5,_0x1ec217){const _0x322ce4=_0x9f3ff6;let _0x12910a={};const _0x48f49a={},_0x417bad={'count':0x0,'rows':[]},_0x4808fd=_[_0x322ce4('0x27')](db[_0x322ce4('0x20')][_0x322ce4('0x39')],function(_0x269238){const _0x3f49e6=_0x322ce4;return{'name':_0x269238[_0x3f49e6('0x5')],'type':_0x269238[_0x3f49e6('0x26')][_0x3f49e6('0x52')]};});_0x48f49a[_0x322ce4('0x2e')]=_[_0x322ce4('0x27')](_0x4808fd,_0x322ce4('0x14')),_0x48f49a[_0x322ce4('0x3e')]=_[_0x322ce4('0x15')](_0x4013e5[_0x322ce4('0x3e')]),_0x48f49a[_0x322ce4('0x56')]=_[_0x322ce4('0x1c')](_0x48f49a[_0x322ce4('0x2e')],_0x48f49a[_0x322ce4('0x3e')]),_0x12910a['attributes']=_['intersection'](_0x48f49a[_0x322ce4('0x2e')],qs[_0x322ce4('0x17')](_0x4013e5[_0x322ce4('0x3e')][_0x322ce4('0x17')])),_0x12910a['attributes']=_0x12910a[_0x322ce4('0x48')][_0x322ce4('0x2')]?_0x12910a[_0x322ce4('0x48')]:_0x48f49a[_0x322ce4('0x2e')];typeof _0x4013e5[_0x322ce4('0x3e')]['nolimit']===_0x322ce4('0x4a')&&(_0x12910a[_0x322ce4('0x45')]=qs['limit'](_0x4013e5[_0x322ce4('0x3e')][_0x322ce4('0x45')]),_0x12910a[_0x322ce4('0x3a')]=qs[_0x322ce4('0x3a')](_0x4013e5[_0x322ce4('0x3e')][_0x322ce4('0x3a')]));_0x12910a[_0x322ce4('0x50')]=qs[_0x322ce4('0x16')](_0x4013e5[_0x322ce4('0x3e')]['sort']),_0x12910a[_0x322ce4('0x3d')]=qs[_0x322ce4('0x56')](_[_0x322ce4('0x38')](_0x4013e5[_0x322ce4('0x3e')],_0x48f49a[_0x322ce4('0x56')]),_0x4808fd);_0x4013e5['query'][_0x322ce4('0x55')]&&(_0x12910a[_0x322ce4('0x3d')]=_['merge'](_0x12910a[_0x322ce4('0x3d')],{[Op['or']]:_['map'](_0x4808fd,function(_0xc1de44){const _0x57e58c=_0x322ce4;if(_0xc1de44[_0x57e58c('0x26')]!=='VIRTUAL'){const _0x4a3d33={};return _0x4a3d33[_0xc1de44[_0x57e58c('0x14')]]={[Op['like']]:'%'+_0x4013e5[_0x57e58c('0x3e')][_0x57e58c('0x55')]+'%'},_0x4a3d33;}})}));_0x12910a=_[_0x322ce4('0x9')]({},_0x12910a,_0x4013e5['options']);const _0x4629b6={'where':_0x12910a[_0x322ce4('0x3d')]};return db[_0x322ce4('0x20')][_0x322ce4('0x3')](_0x4629b6)[_0x322ce4('0x18')](function(_0x47a79f){const _0xfab8b3=_0x322ce4;return _0x417bad[_0xfab8b3('0x3')]=_0x47a79f,_0x4013e5[_0xfab8b3('0x3e')][_0xfab8b3('0x42')]&&(_0x12910a['include']=[{'all':!![]}]),db[_0xfab8b3('0x20')]['findAll'](_0x12910a);})[_0x322ce4('0x18')](function(_0x4014d7){const _0x1faffe=_0x322ce4;return _0x417bad[_0x1faffe('0x21')]=_0x4014d7,_0x417bad;})['then'](respondWithFilteredResult(_0x1ec217,_0x12910a))[_0x322ce4('0x58')](handleError(_0x1ec217,null));},exports[_0x9f3ff6('0x2c')]=function(_0x59fc42,_0x4b6ea7){const _0x1fe257=_0x9f3ff6;let _0x27ea66={'raw':![],'where':{'id':_0x59fc42['params']['id']}};const _0x40cdf4={};return _0x40cdf4[_0x1fe257('0x2e')]=_['keys'](db[_0x1fe257('0x20')][_0x1fe257('0x39')]),_0x40cdf4[_0x1fe257('0x3e')]=_['keys'](_0x59fc42[_0x1fe257('0x3e')]),_0x40cdf4[_0x1fe257('0x56')]=_[_0x1fe257('0x1c')](_0x40cdf4[_0x1fe257('0x2e')],_0x40cdf4[_0x1fe257('0x3e')]),_0x27ea66['attributes']=_[_0x1fe257('0x1c')](_0x40cdf4[_0x1fe257('0x2e')],qs['fields'](_0x59fc42[_0x1fe257('0x3e')][_0x1fe257('0x17')])),_0x27ea66['attributes']=_0x27ea66[_0x1fe257('0x48')][_0x1fe257('0x2')]?_0x27ea66[_0x1fe257('0x48')]:_0x40cdf4['model'],_0x59fc42[_0x1fe257('0x3e')]['includeAll']&&(_0x27ea66[_0x1fe257('0x23')]=[{'all':!![]}]),_0x27ea66=_[_0x1fe257('0x9')]({},_0x27ea66,_0x59fc42['options']),db['VtigerAccount'][_0x1fe257('0x41')](_0x27ea66)[_0x1fe257('0x18')](handleEntityNotFound(_0x4b6ea7,null))[_0x1fe257('0x18')](respondWithResult(_0x4b6ea7,null))[_0x1fe257('0x58')](handleError(_0x4b6ea7,null));},exports['create']=function(_0x1005cc,_0x38d463){const _0x408495=_0x9f3ff6;return db[_0x408495('0x20')][_0x408495('0x59')](_0x1005cc[_0x408495('0x43')],{})[_0x408495('0x18')](respondWithResult(_0x38d463,0xc9))['catch'](handleError(_0x38d463,null));},exports[_0x9f3ff6('0x25')]=function(_0x303c18,_0x42bedb){const _0x17a515=_0x9f3ff6;return _0x303c18[_0x17a515('0x43')]['id']&&delete _0x303c18[_0x17a515('0x43')]['id'],db['VtigerAccount'][_0x17a515('0x41')]({'where':{'id':_0x303c18[_0x17a515('0x2b')]['id']}})['then'](handleEntityNotFound(_0x42bedb,null))[_0x17a515('0x18')](saveUpdates(_0x303c18[_0x17a515('0x43')],null))[_0x17a515('0x18')](respondWithResult(_0x42bedb,null))['catch'](handleError(_0x42bedb,null));},exports[_0x9f3ff6('0x4c')]=function(_0x30dcfa,_0x3365ef){const _0xbdbec=_0x9f3ff6;return db[_0xbdbec('0x20')][_0xbdbec('0x41')]({'where':{'id':_0x30dcfa['params']['id']}})[_0xbdbec('0x18')](handleEntityNotFound(_0x3365ef,null))[_0xbdbec('0x18')](removeEntity(_0x3365ef,null))[_0xbdbec('0x58')](handleError(_0x3365ef,null));},exports[_0x9f3ff6('0x5d')]=function(_0x4c1dcf,_0x5f4b00){const _0x5028c8=_0x9f3ff6;let _0x4890c0={};const _0x3317f1={};let _0x508e48,_0x42fb8d;return db['VtigerAccount'][_0x5028c8('0x41')]({'where':{'id':_0x4c1dcf[_0x5028c8('0x2b')]['id']}})[_0x5028c8('0x18')](handleEntityNotFound(_0x5f4b00,null))[_0x5028c8('0x18')](function(_0x84049e){const _0x5afde6=_0x5028c8;if(_0x84049e)return _0x508e48=_0x84049e,_0x3317f1[_0x5afde6('0x2e')]=_[_0x5afde6('0x15')](db[_0x5afde6('0x1b')]['rawAttributes']),_0x3317f1['query']=_[_0x5afde6('0x15')](_0x4c1dcf[_0x5afde6('0x3e')]),_0x3317f1[_0x5afde6('0x56')]=_[_0x5afde6('0x1c')](_0x3317f1[_0x5afde6('0x2e')],_0x3317f1[_0x5afde6('0x3e')]),_0x4890c0[_0x5afde6('0x48')]=_[_0x5afde6('0x1c')](_0x3317f1[_0x5afde6('0x2e')],qs['fields'](_0x4c1dcf[_0x5afde6('0x3e')][_0x5afde6('0x17')])),_0x4890c0[_0x5afde6('0x48')]=_0x4890c0[_0x5afde6('0x48')][_0x5afde6('0x2')]?_0x4890c0[_0x5afde6('0x48')]:_0x3317f1['model'],_0x4890c0[_0x5afde6('0x50')]=qs[_0x5afde6('0x16')](_0x4c1dcf['query'][_0x5afde6('0x16')]),_0x4890c0[_0x5afde6('0x3d')]=qs[_0x5afde6('0x56')](_[_0x5afde6('0x38')](_0x4c1dcf[_0x5afde6('0x3e')],_0x3317f1[_0x5afde6('0x56')])),_0x4c1dcf[_0x5afde6('0x3e')][_0x5afde6('0x55')]&&(_0x4890c0['where']=_['merge'](_0x4890c0[_0x5afde6('0x3d')],{[Op['or']]:_[_0x5afde6('0x27')](_0x4890c0[_0x5afde6('0x48')],function(_0x3b4a73){const _0x2eb375=_0x5afde6,_0x13c7d7={};return _0x13c7d7[_0x3b4a73]={[Op['like']]:'%'+_0x4c1dcf[_0x2eb375('0x3e')][_0x2eb375('0x55')]+'%'},_0x13c7d7;})})),_0x4890c0=_[_0x5afde6('0x9')]({},_0x4890c0,_0x4c1dcf[_0x5afde6('0x5e')]),_0x508e48[_0x5afde6('0x5d')](_0x4890c0);})[_0x5028c8('0x18')](function(_0x401a2c){const _0x20d6d2=_0x5028c8;if(_0x401a2c)return _0x42fb8d=_0x401a2c[_0x20d6d2('0x2')],typeof _0x4c1dcf['query'][_0x20d6d2('0x11')]===_0x20d6d2('0x4a')&&(_0x4890c0['limit']=qs[_0x20d6d2('0x45')](_0x4c1dcf[_0x20d6d2('0x3e')][_0x20d6d2('0x45')]),_0x4890c0['offset']=qs[_0x20d6d2('0x3a')](_0x4c1dcf[_0x20d6d2('0x3e')][_0x20d6d2('0x3a')])),_0x508e48[_0x20d6d2('0x5d')](_0x4890c0);})[_0x5028c8('0x18')](function(_0x41ff20){if(_0x41ff20)return _0x41ff20?{'count':_0x42fb8d,'rows':_0x41ff20}:null;})[_0x5028c8('0x18')](respondWithResult(_0x5f4b00,null))[_0x5028c8('0x58')](handleError(_0x5f4b00,null));},exports['addConfiguration']=function(_0x659a62,_0x4a2f61){const _0x2ea936=_0x9f3ff6;return _0x659a62['body']['id']&&delete _0x659a62[_0x2ea936('0x43')]['id'],db[_0x2ea936('0x20')][_0x2ea936('0x41')]({'where':{'id':_0x659a62['params']['id']}})[_0x2ea936('0x18')](handleEntityNotFound(_0x4a2f61,null))[_0x2ea936('0x18')](function(_0xfe5d87){const _0x1859c8=_0x2ea936;if(_0xfe5d87)return _0x659a62[_0x1859c8('0x43')][_0x1859c8('0xf')]=_0xfe5d87['id'],_0x659a62[_0x1859c8('0x43')][_0x1859c8('0x51')]=integrations[_0x1859c8('0x46')](_0x659a62[_0x1859c8('0x43')]['channel'],_0x659a62[_0x1859c8('0x43')][_0x1859c8('0x26')]),_0x659a62[_0x1859c8('0x43')]['Descriptions']=integrations[_0x1859c8('0xc')](_0x659a62[_0x1859c8('0x43')][_0x1859c8('0x5a')],_0x659a62[_0x1859c8('0x43')][_0x1859c8('0x26')]),db['VtigerConfiguration']['create'](_0x659a62['body'],{'include':[{'model':db[_0x1859c8('0x33')],'as':_0x1859c8('0x51')},{'model':db[_0x1859c8('0x33')],'as':_0x1859c8('0x40')}]});return null;})['then'](respondWithResult(_0x4a2f61,null))[_0x2ea936('0x58')](handleError(_0x4a2f61,null));};const md5=require(_0x9f3ff6('0x13'));exports[_0x9f3ff6('0x49')]=function(_0x155f11,_0x46c553){const _0x4d8c33=_0x9f3ff6;let _0x1cc933=null,_0x3e094e=null,_0x58bbdf=null,_0x131b32=null,_0x1b2589='';return db[_0x4d8c33('0x20')][_0x4d8c33('0x41')]({'where':{'id':_0x155f11[_0x4d8c33('0x2b')]['id']},'attributes':['id',_0x4d8c33('0x14'),_0x4d8c33('0x37'),_0x4d8c33('0x6'),_0x4d8c33('0x57'),'remoteUri',_0x4d8c33('0x10'),_0x4d8c33('0x1d')]})[_0x4d8c33('0x18')](handleEntityNotFound(_0x46c553,null))['then'](function(_0x33a23c){const _0x46381e=_0x4d8c33;if(_0x33a23c){_0x1cc933=_0x33a23c[_0x46381e('0x37')],_0x3e094e=_0x33a23c[_0x46381e('0x1d')],_0x58bbdf=_0x33a23c[_0x46381e('0x57')],_0x1b2589=_0x33a23c['remoteUri'];const _0x5c433b=_0x1b2589['slice'](-0x1);_0x5c433b==='/'&&(_0x1b2589=_0x1b2589[_0x46381e('0x1a')](0x0,_0x1b2589[_0x46381e('0x2d')](_0x5c433b)));_0x131b32=util['format'](_0x46381e('0x31'),_0x1b2589);const _0x36368c={'method':_0x46381e('0x0'),'uri':_0x131b32,'qs':{'operation':_0x46381e('0x4d'),'username':_0x33a23c[_0x46381e('0x37')]},'json':!![]};return rp(_0x36368c);}})[_0x4d8c33('0x18')](function(_0x369a86){const _0x1d9b28=_0x4d8c33;if(_0x369a86[_0x1d9b28('0x53')]){const _0x3485fa={'method':_0x1d9b28('0x4f'),'uri':_0x131b32,'form':{'operation':_0x1d9b28('0x28'),'username':_0x1cc933,'accessKey':md5(_0x369a86[_0x1d9b28('0x1')][_0x1d9b28('0x30')]+_0x3e094e)},'json':!![]};return rp(_0x3485fa);}})['then'](function(_0x49b856){const _0x4f1942=_0x4d8c33;if(_0x49b856['success']){const _0x531eba={'method':'GET','uri':_0x131b32,'qs':{'operation':_0x4f1942('0x3c'),'username':_0x1cc933,'sessionName':_0x49b856['result']['sessionName'],'elementType':_0x58bbdf},'json':!![]};return rp(_0x531eba);}})['then'](function(_0x5b3bf8){const _0x1a8253=_0x4d8c33;if(_0x5b3bf8[_0x1a8253('0x53')]){const _0x4f1400=[_0x1a8253('0x24'),'reference',_0x1a8253('0x4b')];return _[_0x1a8253('0xb')](_0x5b3bf8[_0x1a8253('0x1')]['fields'],function(_0x154b44){const _0xb277a6=_0x1a8253;return _0x4f1400[_0xb277a6('0x4e')](_0x154b44['type'][_0xb277a6('0x14')]);}),_['remove'](_0x5b3bf8[_0x1a8253('0x1')][_0x1a8253('0x17')],function(_0x1a24c1){const _0x27a4a7=_0x1a8253;return _0x1a24c1[_0x27a4a7('0x47')]==='false';}),{'count':_0x5b3bf8[_0x1a8253('0x1')]['fields'][_0x1a8253('0x2')],'rows':_[_0x1a8253('0x27')](_0x5b3bf8[_0x1a8253('0x1')]['fields'],function(_0x17ba65){const _0x2f541c=_0x1a8253;return{'id':_0x17ba65[_0x2f541c('0x14')],'name':_0x17ba65['label'],'custom':_[_0x2f541c('0x1e')](_0x17ba65[_0x2f541c('0x14')],_0x2f541c('0x1f'))?!![]:![],'options':_0x17ba65[_0x2f541c('0x26')][_0x2f541c('0x14')]==='picklist'&&_0x17ba65[_0x2f541c('0x26')]['picklistValues'][_0x2f541c('0x2')]>0x0?_['map'](_0x17ba65[_0x2f541c('0x26')]['picklistValues'],function(_0x3a9a9c){const _0x24ed80=_0x2f541c;return{'name':_0x3a9a9c['label'],'value':_0x3a9a9c[_0x24ed80('0x2f')]};}):[]};})};}})[_0x4d8c33('0x18')](respondWithResult(_0x46c553,null))[_0x4d8c33('0x58')](function(_0x1d76a0){const _0x1205f6=_0x4d8c33;console['log']('vTiger\x20error:\x20'+_0x1d76a0);let _0x3f971e=_0x155f11['query']['test']?0x1f4:_0x1d76a0[_0x1205f6('0xe')]||0x1f4;logger[_0x1205f6('0x12')]('getFields,\x20%s,\x20%s,\x20%s','getFields',_0x3f971e,JSON['stringify'](_0x1d76a0)),delete _0x1d76a0[_0x1205f6('0x14')],_0x3f971e===0x191&&(_0x3f971e=0x190),_0x46c553[_0x1205f6('0x2a')](_0x3f971e)[_0x1205f6('0x35')](_0x155f11[_0x1205f6('0x3e')][_0x1205f6('0x32')]?{'message':_0x1205f6('0x4'),'statusCode':_0x1d76a0[_0x1205f6('0xe')]}:_0x1d76a0);});}; \ No newline at end of file +const a320_0x4900=['show','slice','cf_','channel','intersection','catch','length','VtigerAccount','map','destroy','update','where','getSubjects','count','accessKey','stringify','findAll','sort','status','value','serverUrl','../../components/parsers/qs','findOne','Content-Range','util','VtigerConfiguration','key','query','getFields,\x20%s,\x20%s,\x20%s','log','json','describe','sendStatus','order','addConfiguration','type','Wrong\x20credentials','send','offset','picklistValues','success','Subjects','md5','nolimit','lodash','body','name','startsWith','getFields','remove','false','undefined','fields','filters','set','index','result','then','../../mysqldb','limit','model','Descriptions','editable','owner','rawAttributes','attributes','keys','getchallenge','includeAll','AccountId','VtigerField','sessionName','test','%s/webservice.php','rows','end','stack','vTiger\x20error:\x20','autogenerated','remoteUri','POST','filter','fieldName','description','label','pick','create','options','../../components/integrations/configuration','getDescriptions','token','error','moduleName','GET','username','getConfigurations','params','merge','login'];(function(_0x27641a,_0x490032){const _0x2d63f0=function(_0x2a7521){while(--_0x2a7521){_0x27641a['push'](_0x27641a['shift']());}};_0x2d63f0(++_0x490032);}(a320_0x4900,0xeb));const a320_0x2d63=function(_0x27641a,_0x490032){_0x27641a=_0x27641a-0x0;let _0x2d63f0=a320_0x4900[_0x27641a];return _0x2d63f0;};const _0x1b8333=a320_0x2d63;'use strict';const rp=require('request-promise-native'),util=require(_0x1b8333('0x56')),_=require(_0x1b8333('0x7')),qs=require(_0x1b8333('0x53')),logger=require('../../config/logger')('api'),db=require(_0x1b8333('0x15'))['db'],{Op}=require('sequelize'),integrations=require(_0x1b8333('0x33'));function respondWithResult(_0x2a7521,_0x4dfb13){return _0x4dfb13=_0x4dfb13||0xc8,function(_0x29e0e6){const _0x47ae46=a320_0x2d63;if(_0x29e0e6)return _0x2a7521[_0x47ae46('0x50')](_0x4dfb13)[_0x47ae46('0x5c')](_0x29e0e6);};}function respondWithFilteredResult(_0x45bfa9,_0x58d2aa){return function(_0x187479){const _0x4cdb1e=a320_0x2d63;if(_0x187479){const _0xa37c0c=_0x187479[_0x4cdb1e('0x4b')],_0x49d7f5=_0x58d2aa[_0x4cdb1e('0x1')];let _0x1cf7f1=_0x58d2aa['offset']+_0x58d2aa['limit'],_0xc846d0;return _0x1cf7f1>=_0xa37c0c?(_0x1cf7f1=_0xa37c0c,_0xc846d0=0xc8):_0xc846d0=0xce,_0x45bfa9[_0x4cdb1e('0x50')](_0xc846d0),_0x45bfa9[_0x4cdb1e('0x11')](_0x4cdb1e('0x55'),_0x49d7f5+'-'+_0x1cf7f1+'/'+_0xa37c0c)['json'](_0x187479);}return null;};}function saveUpdates(_0x260699){return function(_0x44145b){const _0x5d4562=a320_0x2d63;if(_0x44145b)return _0x44145b[_0x5d4562('0x48')](_0x260699)[_0x5d4562('0x14')](function(_0x9ecfd7){return _0x9ecfd7;});return null;};}function removeEntity(_0x2710ae){return function(_0x206b85){const _0x51349d=a320_0x2d63;if(_0x206b85)return _0x206b85['destroy']()[_0x51349d('0x14')](function(){const _0x4f2ed9=_0x51349d;_0x2710ae[_0x4f2ed9('0x50')](0xcc)[_0x4f2ed9('0x26')]();});};}function handleEntityNotFound(_0x1bcae1){return function(_0x27bc1e){const _0x170cbf=a320_0x2d63;return!_0x27bc1e&&_0x1bcae1[_0x170cbf('0x5e')](0x194),_0x27bc1e;};}function handleError(_0x1b9ca3,_0x33e9e5){return _0x33e9e5=_0x33e9e5||0x1f4,function(_0x3ca678){const _0x5a795f=a320_0x2d63;logger[_0x5a795f('0x36')](_0x3ca678[_0x5a795f('0x27')]),_0x3ca678['name']&&delete _0x3ca678['name'],_0x1b9ca3[_0x5a795f('0x50')](_0x33e9e5)[_0x5a795f('0x0')](_0x3ca678);};}exports[_0x1b8333('0x12')]=function(_0x3b6484,_0x2ebebf){const _0x3597c8=_0x1b8333;let _0x4551fe={};const _0x346b65={},_0x1cdf0d={'count':0x0,'rows':[]},_0x4b1768=_[_0x3597c8('0x46')](db[_0x3597c8('0x45')][_0x3597c8('0x1b')],function(_0x24fef9){const _0x56033c=_0x3597c8;return{'name':_0x24fef9[_0x56033c('0x2d')],'type':_0x24fef9[_0x56033c('0x61')][_0x56033c('0x58')]};});_0x346b65[_0x3597c8('0x17')]=_['map'](_0x4b1768,_0x3597c8('0x9')),_0x346b65[_0x3597c8('0x59')]=_[_0x3597c8('0x1d')](_0x3b6484[_0x3597c8('0x59')]),_0x346b65[_0x3597c8('0x10')]=_[_0x3597c8('0x42')](_0x346b65[_0x3597c8('0x17')],_0x346b65[_0x3597c8('0x59')]),_0x4551fe['attributes']=_[_0x3597c8('0x42')](_0x346b65[_0x3597c8('0x17')],qs[_0x3597c8('0xf')](_0x3b6484[_0x3597c8('0x59')][_0x3597c8('0xf')])),_0x4551fe[_0x3597c8('0x1c')]=_0x4551fe[_0x3597c8('0x1c')][_0x3597c8('0x44')]?_0x4551fe[_0x3597c8('0x1c')]:_0x346b65[_0x3597c8('0x17')];typeof _0x3b6484[_0x3597c8('0x59')][_0x3597c8('0x6')]===_0x3597c8('0xe')&&(_0x4551fe[_0x3597c8('0x16')]=qs[_0x3597c8('0x16')](_0x3b6484[_0x3597c8('0x59')][_0x3597c8('0x16')]),_0x4551fe[_0x3597c8('0x1')]=qs['offset'](_0x3b6484['query'][_0x3597c8('0x1')]));_0x4551fe[_0x3597c8('0x5f')]=qs['sort'](_0x3b6484[_0x3597c8('0x59')][_0x3597c8('0x4f')]),_0x4551fe['where']=qs[_0x3597c8('0x10')](_['pick'](_0x3b6484[_0x3597c8('0x59')],_0x346b65[_0x3597c8('0x10')]),_0x4b1768);_0x3b6484[_0x3597c8('0x59')][_0x3597c8('0x2c')]&&(_0x4551fe[_0x3597c8('0x49')]=_['merge'](_0x4551fe['where'],{[Op['or']]:_[_0x3597c8('0x46')](_0x4b1768,function(_0x4ddb50){const _0x58ddc1=_0x3597c8;if(_0x4ddb50[_0x58ddc1('0x61')]!=='VIRTUAL'){const _0x77ed20={};return _0x77ed20[_0x4ddb50[_0x58ddc1('0x9')]]={[Op['like']]:'%'+_0x3b6484['query'][_0x58ddc1('0x2c')]+'%'},_0x77ed20;}})}));_0x4551fe=_[_0x3597c8('0x3c')]({},_0x4551fe,_0x3b6484[_0x3597c8('0x32')]);const _0x2630f4={'where':_0x4551fe[_0x3597c8('0x49')]};return db['VtigerAccount']['count'](_0x2630f4)['then'](function(_0x2206b1){const _0x1e33ef=_0x3597c8;return _0x1cdf0d['count']=_0x2206b1,_0x3b6484[_0x1e33ef('0x59')][_0x1e33ef('0x1f')]&&(_0x4551fe['include']=[{'all':!![]}]),db[_0x1e33ef('0x45')][_0x1e33ef('0x4e')](_0x4551fe);})[_0x3597c8('0x14')](function(_0x269225){const _0x55973d=_0x3597c8;return _0x1cdf0d[_0x55973d('0x25')]=_0x269225,_0x1cdf0d;})[_0x3597c8('0x14')](respondWithFilteredResult(_0x2ebebf,_0x4551fe))[_0x3597c8('0x43')](handleError(_0x2ebebf,null));},exports[_0x1b8333('0x3e')]=function(_0x23f117,_0x3219b6){const _0x5afb9a=_0x1b8333;let _0x3420d0={'raw':![],'where':{'id':_0x23f117[_0x5afb9a('0x3b')]['id']}};const _0x22872d={};return _0x22872d[_0x5afb9a('0x17')]=_[_0x5afb9a('0x1d')](db[_0x5afb9a('0x45')][_0x5afb9a('0x1b')]),_0x22872d[_0x5afb9a('0x59')]=_['keys'](_0x23f117[_0x5afb9a('0x59')]),_0x22872d['filters']=_['intersection'](_0x22872d[_0x5afb9a('0x17')],_0x22872d[_0x5afb9a('0x59')]),_0x3420d0[_0x5afb9a('0x1c')]=_[_0x5afb9a('0x42')](_0x22872d[_0x5afb9a('0x17')],qs[_0x5afb9a('0xf')](_0x23f117[_0x5afb9a('0x59')]['fields'])),_0x3420d0['attributes']=_0x3420d0['attributes']['length']?_0x3420d0[_0x5afb9a('0x1c')]:_0x22872d[_0x5afb9a('0x17')],_0x23f117['query'][_0x5afb9a('0x1f')]&&(_0x3420d0['include']=[{'all':!![]}]),_0x3420d0=_[_0x5afb9a('0x3c')]({},_0x3420d0,_0x23f117[_0x5afb9a('0x32')]),db[_0x5afb9a('0x45')][_0x5afb9a('0x54')](_0x3420d0)[_0x5afb9a('0x14')](handleEntityNotFound(_0x3219b6,null))[_0x5afb9a('0x14')](respondWithResult(_0x3219b6,null))[_0x5afb9a('0x43')](handleError(_0x3219b6,null));},exports[_0x1b8333('0x31')]=function(_0x5d77d6,_0x3cd133){const _0x465cf1=_0x1b8333;return db[_0x465cf1('0x45')]['create'](_0x5d77d6[_0x465cf1('0x8')],{})[_0x465cf1('0x14')](respondWithResult(_0x3cd133,0xc9))[_0x465cf1('0x43')](handleError(_0x3cd133,null));},exports[_0x1b8333('0x48')]=function(_0x8f4987,_0x36a08b){const _0x503170=_0x1b8333;return _0x8f4987[_0x503170('0x8')]['id']&&delete _0x8f4987[_0x503170('0x8')]['id'],db['VtigerAccount'][_0x503170('0x54')]({'where':{'id':_0x8f4987['params']['id']}})[_0x503170('0x14')](handleEntityNotFound(_0x36a08b,null))[_0x503170('0x14')](saveUpdates(_0x8f4987[_0x503170('0x8')],null))['then'](respondWithResult(_0x36a08b,null))[_0x503170('0x43')](handleError(_0x36a08b,null));},exports[_0x1b8333('0x47')]=function(_0x1b9bb0,_0x65c066){const _0xdda702=_0x1b8333;return db['VtigerAccount'][_0xdda702('0x54')]({'where':{'id':_0x1b9bb0[_0xdda702('0x3b')]['id']}})['then'](handleEntityNotFound(_0x65c066,null))[_0xdda702('0x14')](removeEntity(_0x65c066,null))[_0xdda702('0x43')](handleError(_0x65c066,null));},exports[_0x1b8333('0x3a')]=function(_0x30a1a1,_0x5a78ac){const _0x5a71da=_0x1b8333;let _0x323899={};const _0xc6dcce={};let _0x33b6d0,_0x26b043;return db['VtigerAccount'][_0x5a71da('0x54')]({'where':{'id':_0x30a1a1[_0x5a71da('0x3b')]['id']}})['then'](handleEntityNotFound(_0x5a78ac,null))['then'](function(_0x44423a){const _0x4d34b1=_0x5a71da;if(_0x44423a)return _0x33b6d0=_0x44423a,_0xc6dcce[_0x4d34b1('0x17')]=_[_0x4d34b1('0x1d')](db[_0x4d34b1('0x57')][_0x4d34b1('0x1b')]),_0xc6dcce[_0x4d34b1('0x59')]=_[_0x4d34b1('0x1d')](_0x30a1a1['query']),_0xc6dcce[_0x4d34b1('0x10')]=_[_0x4d34b1('0x42')](_0xc6dcce[_0x4d34b1('0x17')],_0xc6dcce[_0x4d34b1('0x59')]),_0x323899[_0x4d34b1('0x1c')]=_['intersection'](_0xc6dcce['model'],qs[_0x4d34b1('0xf')](_0x30a1a1[_0x4d34b1('0x59')][_0x4d34b1('0xf')])),_0x323899[_0x4d34b1('0x1c')]=_0x323899['attributes'][_0x4d34b1('0x44')]?_0x323899[_0x4d34b1('0x1c')]:_0xc6dcce['model'],_0x323899[_0x4d34b1('0x5f')]=qs[_0x4d34b1('0x4f')](_0x30a1a1[_0x4d34b1('0x59')][_0x4d34b1('0x4f')]),_0x323899['where']=qs[_0x4d34b1('0x10')](_[_0x4d34b1('0x30')](_0x30a1a1[_0x4d34b1('0x59')],_0xc6dcce[_0x4d34b1('0x10')])),_0x30a1a1[_0x4d34b1('0x59')]['filter']&&(_0x323899[_0x4d34b1('0x49')]=_['merge'](_0x323899[_0x4d34b1('0x49')],{[Op['or']]:_['map'](_0x323899[_0x4d34b1('0x1c')],function(_0x1e5b64){const _0x4f61a5=_0x4d34b1,_0x3bc3cb={};return _0x3bc3cb[_0x1e5b64]={[Op['like']]:'%'+_0x30a1a1[_0x4f61a5('0x59')][_0x4f61a5('0x2c')]+'%'},_0x3bc3cb;})})),_0x323899=_[_0x4d34b1('0x3c')]({},_0x323899,_0x30a1a1[_0x4d34b1('0x32')]),_0x33b6d0[_0x4d34b1('0x3a')](_0x323899);})[_0x5a71da('0x14')](function(_0x556ad8){const _0x3d2d09=_0x5a71da;if(_0x556ad8)return _0x26b043=_0x556ad8[_0x3d2d09('0x44')],typeof _0x30a1a1[_0x3d2d09('0x59')][_0x3d2d09('0x6')]===_0x3d2d09('0xe')&&(_0x323899[_0x3d2d09('0x16')]=qs['limit'](_0x30a1a1[_0x3d2d09('0x59')]['limit']),_0x323899[_0x3d2d09('0x1')]=qs['offset'](_0x30a1a1[_0x3d2d09('0x59')][_0x3d2d09('0x1')])),_0x33b6d0[_0x3d2d09('0x3a')](_0x323899);})[_0x5a71da('0x14')](function(_0x4e087a){if(_0x4e087a)return _0x4e087a?{'count':_0x26b043,'rows':_0x4e087a}:null;})[_0x5a71da('0x14')](respondWithResult(_0x5a78ac,null))['catch'](handleError(_0x5a78ac,null));},exports[_0x1b8333('0x60')]=function(_0x35e911,_0x2c3392){const _0x3d840a=_0x1b8333;return _0x35e911[_0x3d840a('0x8')]['id']&&delete _0x35e911[_0x3d840a('0x8')]['id'],db[_0x3d840a('0x45')]['findOne']({'where':{'id':_0x35e911['params']['id']}})[_0x3d840a('0x14')](handleEntityNotFound(_0x2c3392,null))[_0x3d840a('0x14')](function(_0x126b84){const _0x1b3e1d=_0x3d840a;if(_0x126b84)return _0x35e911[_0x1b3e1d('0x8')][_0x1b3e1d('0x20')]=_0x126b84['id'],_0x35e911[_0x1b3e1d('0x8')][_0x1b3e1d('0x4')]=integrations[_0x1b3e1d('0x4a')](_0x35e911[_0x1b3e1d('0x8')][_0x1b3e1d('0x41')],_0x35e911['body'][_0x1b3e1d('0x61')]),_0x35e911[_0x1b3e1d('0x8')][_0x1b3e1d('0x18')]=integrations[_0x1b3e1d('0x34')](_0x35e911[_0x1b3e1d('0x8')]['channel'],_0x35e911['body'][_0x1b3e1d('0x61')]),db[_0x1b3e1d('0x57')][_0x1b3e1d('0x31')](_0x35e911[_0x1b3e1d('0x8')],{'include':[{'model':db[_0x1b3e1d('0x21')],'as':_0x1b3e1d('0x4')},{'model':db[_0x1b3e1d('0x21')],'as':_0x1b3e1d('0x18')}]});return null;})[_0x3d840a('0x14')](respondWithResult(_0x2c3392,null))[_0x3d840a('0x43')](handleError(_0x2c3392,null));};const md5=require(_0x1b8333('0x5'));exports[_0x1b8333('0xb')]=function(_0x20f6e3,_0x40bc58){const _0x150ed0=_0x1b8333;let _0x128a26=null,_0x122097=null,_0x2c20e7=null,_0x413d8f=null,_0x44ebba='';return db[_0x150ed0('0x45')][_0x150ed0('0x54')]({'where':{'id':_0x20f6e3['params']['id']},'attributes':['id',_0x150ed0('0x9'),_0x150ed0('0x39'),_0x150ed0('0x2e'),_0x150ed0('0x37'),_0x150ed0('0x2a'),_0x150ed0('0x52'),_0x150ed0('0x4c')]})[_0x150ed0('0x14')](handleEntityNotFound(_0x40bc58,null))[_0x150ed0('0x14')](function(_0x4b5ac3){const _0x3cf7a5=_0x150ed0;if(_0x4b5ac3){_0x128a26=_0x4b5ac3[_0x3cf7a5('0x39')],_0x122097=_0x4b5ac3['accessKey'],_0x2c20e7=_0x4b5ac3[_0x3cf7a5('0x37')],_0x44ebba=_0x4b5ac3[_0x3cf7a5('0x2a')];const _0x24b159=_0x44ebba[_0x3cf7a5('0x3f')](-0x1);_0x24b159==='/'&&(_0x44ebba=_0x44ebba['substring'](0x0,_0x44ebba['lastIndexOf'](_0x24b159)));_0x413d8f=util['format'](_0x3cf7a5('0x24'),_0x44ebba);const _0xab9c38={'method':'GET','uri':_0x413d8f,'qs':{'operation':_0x3cf7a5('0x1e'),'username':_0x4b5ac3[_0x3cf7a5('0x39')]},'json':!![]};return rp(_0xab9c38);}})[_0x150ed0('0x14')](function(_0x3f6b74){const _0x3c2ad5=_0x150ed0;if(_0x3f6b74[_0x3c2ad5('0x3')]){const _0x4506ea={'method':_0x3c2ad5('0x2b'),'uri':_0x413d8f,'form':{'operation':_0x3c2ad5('0x3d'),'username':_0x128a26,'accessKey':md5(_0x3f6b74['result'][_0x3c2ad5('0x35')]+_0x122097)},'json':!![]};return rp(_0x4506ea);}})[_0x150ed0('0x14')](function(_0x5e7d8e){const _0x38709e=_0x150ed0;if(_0x5e7d8e[_0x38709e('0x3')]){const _0x4b60a4={'method':_0x38709e('0x38'),'uri':_0x413d8f,'qs':{'operation':_0x38709e('0x5d'),'username':_0x128a26,'sessionName':_0x5e7d8e[_0x38709e('0x13')][_0x38709e('0x22')],'elementType':_0x2c20e7},'json':!![]};return rp(_0x4b60a4);}})[_0x150ed0('0x14')](function(_0x54d3f1){const _0xaff844=_0x150ed0;if(_0x54d3f1[_0xaff844('0x3')]){const _0x583e31=[_0xaff844('0x29'),'reference',_0xaff844('0x1a')];return _[_0xaff844('0xc')](_0x54d3f1[_0xaff844('0x13')][_0xaff844('0xf')],function(_0x183554){const _0x3a2b57=_0xaff844;return _0x583e31['includes'](_0x183554[_0x3a2b57('0x61')][_0x3a2b57('0x9')]);}),_[_0xaff844('0xc')](_0x54d3f1[_0xaff844('0x13')]['fields'],function(_0x12fbba){const _0x27a6df=_0xaff844;return _0x12fbba[_0x27a6df('0x19')]===_0x27a6df('0xd');}),{'count':_0x54d3f1[_0xaff844('0x13')][_0xaff844('0xf')]['length'],'rows':_[_0xaff844('0x46')](_0x54d3f1[_0xaff844('0x13')][_0xaff844('0xf')],function(_0x56c744){const _0x47d482=_0xaff844;return{'id':_0x56c744[_0x47d482('0x9')],'name':_0x56c744[_0x47d482('0x2f')],'custom':_[_0x47d482('0xa')](_0x56c744[_0x47d482('0x9')],_0x47d482('0x40'))?!![]:![],'options':_0x56c744[_0x47d482('0x61')][_0x47d482('0x9')]==='picklist'&&_0x56c744[_0x47d482('0x61')][_0x47d482('0x2')][_0x47d482('0x44')]>0x0?_[_0x47d482('0x46')](_0x56c744[_0x47d482('0x61')][_0x47d482('0x2')],function(_0x2078f6){const _0x2cb7b0=_0x47d482;return{'name':_0x2078f6[_0x2cb7b0('0x2f')],'value':_0x2078f6[_0x2cb7b0('0x51')]};}):[]};})};}})[_0x150ed0('0x14')](respondWithResult(_0x40bc58,null))['catch'](function(_0x38d046){const _0x55ba2a=_0x150ed0;console[_0x55ba2a('0x5b')](_0x55ba2a('0x28')+_0x38d046);let _0x29d065=_0x20f6e3[_0x55ba2a('0x59')][_0x55ba2a('0x23')]?0x1f4:_0x38d046['statusCode']||0x1f4;logger[_0x55ba2a('0x36')](_0x55ba2a('0x5a'),_0x55ba2a('0xb'),_0x29d065,JSON[_0x55ba2a('0x4d')](_0x38d046)),delete _0x38d046['name'],_0x29d065===0x191&&(_0x29d065=0x190),_0x40bc58[_0x55ba2a('0x50')](_0x29d065)[_0x55ba2a('0x0')](_0x20f6e3[_0x55ba2a('0x59')][_0x55ba2a('0x23')]?{'message':_0x55ba2a('0x62'),'statusCode':_0x38d046['statusCode']}:_0x38d046);});}; \ No newline at end of file diff --git a/server/api/intVtigerAccount/intVtigerAccount.model.js b/server/api/intVtigerAccount/intVtigerAccount.model.js index a5f42f2..b966c9f 100644 --- a/server/api/intVtigerAccount/intVtigerAccount.model.js +++ b/server/api/intVtigerAccount/intVtigerAccount.model.js @@ -1 +1 @@ -const a321_0x553b=['./intVtigerAccount.attributes','define','exports','VtigerAccount'];(function(_0x456074,_0x553bf6){const _0x3312a9=function(_0x111917){while(--_0x111917){_0x456074['push'](_0x456074['shift']());}};_0x3312a9(++_0x553bf6);}(a321_0x553b,0x99));const a321_0x3312=function(_0x456074,_0x553bf6){_0x456074=_0x456074-0x0;let _0x3312a9=a321_0x553b[_0x456074];return _0x3312a9;};const _0x5ba3b6=a321_0x3312;'use strict';const attributes=require(_0x5ba3b6('0x3'));module[_0x5ba3b6('0x1')]=function(_0x111917){const _0x53ceab=_0x5ba3b6,_0x3ee58c=_0x111917[_0x53ceab('0x0')](_0x53ceab('0x2'),attributes,{'tableName':'int_vtiger_accounts','paranoid':![],'indexes':[],'timestamps':!![]});return _0x3ee58c;}; \ No newline at end of file +const a321_0x355c=['exports','int_vtiger_accounts','define'];(function(_0xa1cfd7,_0x355c2b){const _0x268497=function(_0x332c6b){while(--_0x332c6b){_0xa1cfd7['push'](_0xa1cfd7['shift']());}};_0x268497(++_0x355c2b);}(a321_0x355c,0x17b));const a321_0x2684=function(_0xa1cfd7,_0x355c2b){_0xa1cfd7=_0xa1cfd7-0x0;let _0x268497=a321_0x355c[_0xa1cfd7];return _0x268497;};const _0x232da7=a321_0x2684;'use strict';const attributes=require('./intVtigerAccount.attributes');module[_0x232da7('0x2')]=function(_0x332c6b){const _0x34cd7b=_0x232da7,_0xae6c57=_0x332c6b[_0x34cd7b('0x1')]('VtigerAccount',attributes,{'tableName':_0x34cd7b('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xae6c57;}; \ No newline at end of file diff --git a/server/api/intVtigerAccount/intVtigerAccount.rpc.js b/server/api/intVtigerAccount/intVtigerAccount.rpc.js index 37703f1..85748ca 100644 --- a/server/api/intVtigerAccount/intVtigerAccount.rpc.js +++ b/server/api/intVtigerAccount/intVtigerAccount.rpc.js @@ -1 +1 @@ -const a322_0x4567=['debug','findAll','options','ShowVtigerAccount','catch','error','lodash','attributes','include','then','stringify','info','message','../../mysqldb','findOne','raw','where','VtigerAccount','GetVtigerAccount','../../config/logger','map','limit','model'];(function(_0x438268,_0x45674f){const _0x92643a=function(_0x7dbe18){while(--_0x7dbe18){_0x438268['push'](_0x438268['shift']());}};_0x92643a(++_0x45674f);}(a322_0x4567,0x1f1));const a322_0x9264=function(_0x438268,_0x45674f){_0x438268=_0x438268-0x0;let _0x92643a=a322_0x4567[_0x438268];return _0x92643a;};const _0x1fe20e=a322_0x9264;'use strict';const _=require(_0x1fe20e('0xf')),db=require(_0x1fe20e('0x16'))['db'],logger=require(_0x1fe20e('0x5'))('rpc');exports[_0x1fe20e('0x4')]=function(_0x7dbe18){const _0x257994=this;return new Promise(function(_0x38f7d3,_0x552039){const _0xe39b9b=a322_0x9264;return db[_0xe39b9b('0x3')][_0xe39b9b('0xa')]({'raw':_0x7dbe18[_0xe39b9b('0xb')]?_0x7dbe18[_0xe39b9b('0xb')][_0xe39b9b('0x1')]===undefined?!![]:![]:!![],'where':_0x7dbe18[_0xe39b9b('0xb')]?_0x7dbe18[_0xe39b9b('0xb')][_0xe39b9b('0x2')]||null:null,'attributes':_0x7dbe18['options']?_0x7dbe18[_0xe39b9b('0xb')][_0xe39b9b('0x10')]||null:null,'limit':_0x7dbe18['options']?_0x7dbe18['options'][_0xe39b9b('0x7')]||null:null,'include':_0x7dbe18[_0xe39b9b('0xb')]?_0x7dbe18[_0xe39b9b('0xb')]['include']?_['map'](_0x7dbe18[_0xe39b9b('0xb')]['include'],function(_0x27f11c){const _0x128b93=_0xe39b9b;return{'model':db[_0x27f11c[_0x128b93('0x8')]],'as':_0x27f11c['as'],'attributes':_0x27f11c[_0x128b93('0x10')],'include':_0x27f11c['include']?_[_0x128b93('0x6')](_0x27f11c[_0x128b93('0x11')],function(_0x510608){const _0x5bda65=_0x128b93;return{'model':db[_0x510608[_0x5bda65('0x8')]],'as':_0x510608['as'],'attributes':_0x510608['attributes'],'include':_0x510608[_0x5bda65('0x11')]?_[_0x5bda65('0x6')](_0x510608[_0x5bda65('0x11')],function(_0x3b4b33){const _0x2a8f63=_0x5bda65;return{'model':db[_0x3b4b33[_0x2a8f63('0x8')]],'as':_0x3b4b33['as'],'attributes':_0x3b4b33[_0x2a8f63('0x10')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x27cb3a){const _0x36f846=_0xe39b9b;logger[_0x36f846('0x14')](_0x36f846('0x4'),_0x7dbe18),logger[_0x36f846('0x9')](_0x36f846('0x4'),_0x7dbe18,JSON[_0x36f846('0x13')](_0x27cb3a)),_0x38f7d3(_0x27cb3a);})[_0xe39b9b('0xd')](function(_0x2ae0fd){const _0x5ddad8=_0xe39b9b;logger['error']('GetVtigerAccount',_0x2ae0fd[_0x5ddad8('0x15')],_0x7dbe18),_0x552039(_0x257994[_0x5ddad8('0xe')](0x1f4,_0x2ae0fd['message']));});});},exports[_0x1fe20e('0xc')]=function(_0x3b8140){const _0x150bcb=this;return new Promise(function(_0x530c59,_0x153c70){const _0x3fe15b=a322_0x9264;return db[_0x3fe15b('0x3')][_0x3fe15b('0x0')]({'raw':_0x3b8140[_0x3fe15b('0xb')]?_0x3b8140[_0x3fe15b('0xb')][_0x3fe15b('0x1')]===undefined?!![]:![]:!![],'where':_0x3b8140['options']?_0x3b8140[_0x3fe15b('0xb')][_0x3fe15b('0x2')]||null:null,'attributes':_0x3b8140[_0x3fe15b('0xb')]?_0x3b8140[_0x3fe15b('0xb')][_0x3fe15b('0x10')]||null:null,'include':_0x3b8140['options']?_0x3b8140[_0x3fe15b('0xb')][_0x3fe15b('0x11')]?_[_0x3fe15b('0x6')](_0x3b8140['options'][_0x3fe15b('0x11')],function(_0x3e53db){const _0x12c2eb=_0x3fe15b;return{'model':db[_0x3e53db[_0x12c2eb('0x8')]],'as':_0x3e53db['as'],'attributes':_0x3e53db[_0x12c2eb('0x10')],'include':_0x3e53db[_0x12c2eb('0x11')]?_[_0x12c2eb('0x6')](_0x3e53db['include'],function(_0x7b304){const _0x202227=_0x12c2eb;return{'model':db[_0x7b304['model']],'as':_0x7b304['as'],'attributes':_0x7b304[_0x202227('0x10')],'include':_0x7b304[_0x202227('0x11')]?_[_0x202227('0x6')](_0x7b304[_0x202227('0x11')],function(_0x2898e3){const _0x482d57=_0x202227;return{'model':db[_0x2898e3[_0x482d57('0x8')]],'as':_0x2898e3['as'],'attributes':_0x2898e3['attributes']};}):[]};}):[]};}):[]:[]})[_0x3fe15b('0x12')](function(_0x5ddd1c){const _0x3cbc32=_0x3fe15b;logger[_0x3cbc32('0x14')](_0x3cbc32('0xc'),_0x3b8140),logger[_0x3cbc32('0x9')]('ShowVtigerAccount',_0x3b8140,JSON[_0x3cbc32('0x13')](_0x5ddd1c)),_0x530c59(_0x5ddd1c);})[_0x3fe15b('0xd')](function(_0x5e47f8){const _0xf67e49=_0x3fe15b;logger[_0xf67e49('0xe')](_0xf67e49('0xc'),_0x5e47f8[_0xf67e49('0x15')],_0x3b8140),_0x153c70(_0x150bcb[_0xf67e49('0xe')](0x1f4,_0x5e47f8['message']));});});}; \ No newline at end of file +const a322_0x2f74=['../../config/logger','findAll','then','VtigerAccount','GetVtigerAccount','model','message','raw','options','stringify','ShowVtigerAccount','map','limit','attributes','findOne','debug','include','lodash','error','../../mysqldb','catch','info','where'];(function(_0x13276b,_0x2f7484){const _0x360334=function(_0x5072ab){while(--_0x5072ab){_0x13276b['push'](_0x13276b['shift']());}};_0x360334(++_0x2f7484);}(a322_0x2f74,0x1be));const a322_0x3603=function(_0x13276b,_0x2f7484){_0x13276b=_0x13276b-0x0;let _0x360334=a322_0x2f74[_0x13276b];return _0x360334;};const _0x1bacbe=a322_0x3603;'use strict';const _=require(_0x1bacbe('0x8')),db=require(_0x1bacbe('0xa'))['db'],logger=require(_0x1bacbe('0xe'))('rpc');exports[_0x1bacbe('0x12')]=function(_0x5072ab){const _0xb58dc6=this;return new Promise(function(_0x3293c0,_0x47a815){const _0x284a9e=a322_0x3603;return db[_0x284a9e('0x11')][_0x284a9e('0xf')]({'raw':_0x5072ab[_0x284a9e('0x16')]?_0x5072ab['options'][_0x284a9e('0x15')]===undefined?!![]:![]:!![],'where':_0x5072ab[_0x284a9e('0x16')]?_0x5072ab[_0x284a9e('0x16')][_0x284a9e('0xd')]||null:null,'attributes':_0x5072ab['options']?_0x5072ab[_0x284a9e('0x16')][_0x284a9e('0x4')]||null:null,'limit':_0x5072ab[_0x284a9e('0x16')]?_0x5072ab['options'][_0x284a9e('0x3')]||null:null,'include':_0x5072ab[_0x284a9e('0x16')]?_0x5072ab[_0x284a9e('0x16')][_0x284a9e('0x7')]?_[_0x284a9e('0x2')](_0x5072ab[_0x284a9e('0x16')]['include'],function(_0x1c20b8){const _0x2500b1=_0x284a9e;return{'model':db[_0x1c20b8[_0x2500b1('0x13')]],'as':_0x1c20b8['as'],'attributes':_0x1c20b8[_0x2500b1('0x4')],'include':_0x1c20b8[_0x2500b1('0x7')]?_[_0x2500b1('0x2')](_0x1c20b8['include'],function(_0x13cf0c){const _0x49b0e5=_0x2500b1;return{'model':db[_0x13cf0c['model']],'as':_0x13cf0c['as'],'attributes':_0x13cf0c[_0x49b0e5('0x4')],'include':_0x13cf0c['include']?_['map'](_0x13cf0c['include'],function(_0x687784){return{'model':db[_0x687784['model']],'as':_0x687784['as'],'attributes':_0x687784['attributes']};}):[]};}):[]};}):[]:[]})[_0x284a9e('0x10')](function(_0x3cf1b4){const _0x22c129=_0x284a9e;logger[_0x22c129('0xc')]('GetVtigerAccount',_0x5072ab),logger[_0x22c129('0x6')]('GetVtigerAccount',_0x5072ab,JSON['stringify'](_0x3cf1b4)),_0x3293c0(_0x3cf1b4);})['catch'](function(_0xab3786){const _0x1a9af0=_0x284a9e;logger['error']('GetVtigerAccount',_0xab3786['message'],_0x5072ab),_0x47a815(_0xb58dc6['error'](0x1f4,_0xab3786[_0x1a9af0('0x14')]));});});},exports['ShowVtigerAccount']=function(_0x5ddd33){const _0x52a2c2=this;return new Promise(function(_0x447c99,_0xaa8dd9){const _0x47ff8f=a322_0x3603;return db[_0x47ff8f('0x11')][_0x47ff8f('0x5')]({'raw':_0x5ddd33[_0x47ff8f('0x16')]?_0x5ddd33[_0x47ff8f('0x16')]['raw']===undefined?!![]:![]:!![],'where':_0x5ddd33['options']?_0x5ddd33[_0x47ff8f('0x16')]['where']||null:null,'attributes':_0x5ddd33[_0x47ff8f('0x16')]?_0x5ddd33[_0x47ff8f('0x16')][_0x47ff8f('0x4')]||null:null,'include':_0x5ddd33[_0x47ff8f('0x16')]?_0x5ddd33[_0x47ff8f('0x16')][_0x47ff8f('0x7')]?_[_0x47ff8f('0x2')](_0x5ddd33[_0x47ff8f('0x16')][_0x47ff8f('0x7')],function(_0x1d70dc){const _0xfd177a=_0x47ff8f;return{'model':db[_0x1d70dc['model']],'as':_0x1d70dc['as'],'attributes':_0x1d70dc[_0xfd177a('0x4')],'include':_0x1d70dc[_0xfd177a('0x7')]?_[_0xfd177a('0x2')](_0x1d70dc[_0xfd177a('0x7')],function(_0x33da0e){const _0x462a81=_0xfd177a;return{'model':db[_0x33da0e[_0x462a81('0x13')]],'as':_0x33da0e['as'],'attributes':_0x33da0e['attributes'],'include':_0x33da0e[_0x462a81('0x7')]?_[_0x462a81('0x2')](_0x33da0e[_0x462a81('0x7')],function(_0x2062f3){const _0x1e6a1b=_0x462a81;return{'model':db[_0x2062f3[_0x1e6a1b('0x13')]],'as':_0x2062f3['as'],'attributes':_0x2062f3['attributes']};}):[]};}):[]};}):[]:[]})['then'](function(_0x5da166){const _0x2ecf75=_0x47ff8f;logger[_0x2ecf75('0xc')]('ShowVtigerAccount',_0x5ddd33),logger[_0x2ecf75('0x6')](_0x2ecf75('0x1'),_0x5ddd33,JSON[_0x2ecf75('0x0')](_0x5da166)),_0x447c99(_0x5da166);})[_0x47ff8f('0xb')](function(_0x547157){const _0x4dd1e9=_0x47ff8f;logger[_0x4dd1e9('0x9')](_0x4dd1e9('0x1'),_0x547157[_0x4dd1e9('0x14')],_0x5ddd33),_0xaa8dd9(_0x52a2c2[_0x4dd1e9('0x9')](0x1f4,_0x547157[_0x4dd1e9('0x14')]));});});}; \ No newline at end of file diff --git a/server/api/intVtigerConfiguration/index.js b/server/api/intVtigerConfiguration/index.js index aabd952..7ab7aea 100644 --- a/server/api/intVtigerConfiguration/index.js +++ b/server/api/intVtigerConfiguration/index.js @@ -1 +1 @@ -const a323_0x5aa7=['update','getFields','exports','getDescriptions','express','/:id','get','isAuthenticated','Router','delete','put','/:id/subjects','index','create','/:id/fields','../../components/auth/service','/:id/descriptions','post'];(function(_0x3ac1a3,_0x5aa73e){const _0x176c66=function(_0xb1cdfc){while(--_0xb1cdfc){_0x3ac1a3['push'](_0x3ac1a3['shift']());}};_0x176c66(++_0x5aa73e);}(a323_0x5aa7,0xe4));const a323_0x176c=function(_0x3ac1a3,_0x5aa73e){_0x3ac1a3=_0x3ac1a3-0x0;let _0x176c66=a323_0x5aa7[_0x3ac1a3];return _0x176c66;};const _0x43efb9=a323_0x176c;'use strict';const express=require(_0x43efb9('0xa')),router=express[_0x43efb9('0xe')](),auth=require(_0x43efb9('0x3')),controller=require('./intVtigerConfiguration.controller');router[_0x43efb9('0xc')]('/',auth['isAuthenticated'](),controller[_0x43efb9('0x0')]),router[_0x43efb9('0xc')](_0x43efb9('0xb'),auth[_0x43efb9('0xd')](),controller['show']),router[_0x43efb9('0xc')](_0x43efb9('0x2'),auth[_0x43efb9('0xd')](),controller[_0x43efb9('0x7')]),router[_0x43efb9('0xc')](_0x43efb9('0x11'),auth[_0x43efb9('0xd')](),controller['getSubjects']),router[_0x43efb9('0xc')](_0x43efb9('0x4'),auth['isAuthenticated'](),controller[_0x43efb9('0x9')]),router[_0x43efb9('0x5')]('/',auth[_0x43efb9('0xd')](),controller[_0x43efb9('0x1')]),router[_0x43efb9('0x10')]('/:id',auth['isAuthenticated'](),controller[_0x43efb9('0x6')]),router[_0x43efb9('0xf')](_0x43efb9('0xb'),auth[_0x43efb9('0xd')](),controller['destroy']),module[_0x43efb9('0x8')]=router; \ No newline at end of file +const a323_0x1c98=['Router','create','getDescriptions','destroy','update','/:id','express','getSubjects','./intVtigerConfiguration.controller','../../components/auth/service','index','isAuthenticated','post','show','getFields','exports','delete','get'];(function(_0x43210f,_0x1c98bc){const _0x29a6f6=function(_0x30cbca){while(--_0x30cbca){_0x43210f['push'](_0x43210f['shift']());}};_0x29a6f6(++_0x1c98bc);}(a323_0x1c98,0x101));const a323_0x29a6=function(_0x43210f,_0x1c98bc){_0x43210f=_0x43210f-0x0;let _0x29a6f6=a323_0x1c98[_0x43210f];return _0x29a6f6;};const _0x44a1dd=a323_0x29a6;'use strict';const express=require(_0x44a1dd('0x1')),router=express[_0x44a1dd('0xd')](),auth=require(_0x44a1dd('0x4')),controller=require(_0x44a1dd('0x3'));router[_0x44a1dd('0xc')]('/',auth['isAuthenticated'](),controller[_0x44a1dd('0x5')]),router[_0x44a1dd('0xc')](_0x44a1dd('0x0'),auth[_0x44a1dd('0x6')](),controller[_0x44a1dd('0x8')]),router[_0x44a1dd('0xc')]('/:id/fields',auth[_0x44a1dd('0x6')](),controller[_0x44a1dd('0x9')]),router[_0x44a1dd('0xc')]('/:id/subjects',auth[_0x44a1dd('0x6')](),controller[_0x44a1dd('0x2')]),router[_0x44a1dd('0xc')]('/:id/descriptions',auth[_0x44a1dd('0x6')](),controller[_0x44a1dd('0xf')]),router[_0x44a1dd('0x7')]('/',auth[_0x44a1dd('0x6')](),controller[_0x44a1dd('0xe')]),router['put'](_0x44a1dd('0x0'),auth['isAuthenticated'](),controller[_0x44a1dd('0x11')]),router[_0x44a1dd('0xb')](_0x44a1dd('0x0'),auth[_0x44a1dd('0x6')](),controller[_0x44a1dd('0x10')]),module[_0x44a1dd('0xa')]=router; \ No newline at end of file diff --git a/server/api/intVtigerConfiguration/intVtigerConfiguration.attributes.js b/server/api/intVtigerConfiguration/intVtigerConfiguration.attributes.js index 8f48ac2..b44c921 100644 --- a/server/api/intVtigerConfiguration/intVtigerConfiguration.attributes.js +++ b/server/api/intVtigerConfiguration/intVtigerConfiguration.attributes.js @@ -1 +1 @@ -const a324_0x3744=['exports','STRING'];(function(_0x455308,_0x374430){const _0x3fcebc=function(_0x5c5652){while(--_0x5c5652){_0x455308['push'](_0x455308['shift']());}};_0x3fcebc(++_0x374430);}(a324_0x3744,0x6f));const a324_0x3fce=function(_0x455308,_0x374430){_0x455308=_0x455308-0x0;let _0x3fcebc=a324_0x3744[_0x455308];return _0x3fcebc;};const _0x2be7bd=a324_0x3fce;'use strict';const Sequelize=require('sequelize');module[_0x2be7bd('0x1')]={'name':{'type':Sequelize[_0x2be7bd('0x0')]},'description':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a324_0x1c94=['STRING','sequelize','exports'];(function(_0x1059f3,_0x1c946f){const _0x73ac2d=function(_0x4683d3){while(--_0x4683d3){_0x1059f3['push'](_0x1059f3['shift']());}};_0x73ac2d(++_0x1c946f);}(a324_0x1c94,0xd1));const a324_0x73ac=function(_0x1059f3,_0x1c946f){_0x1059f3=_0x1059f3-0x0;let _0x73ac2d=a324_0x1c94[_0x1059f3];return _0x73ac2d;};const _0x3949f6=a324_0x73ac;'use strict';const Sequelize=require(_0x3949f6('0x2'));module[_0x3949f6('0x0')]={'name':{'type':Sequelize[_0x3949f6('0x1')]},'description':{'type':Sequelize[_0x3949f6('0x1')]}}; \ No newline at end of file diff --git a/server/api/intVtigerConfiguration/intVtigerConfiguration.controller.js b/server/api/intVtigerConfiguration/intVtigerConfiguration.controller.js index 7c4bbca..c38007b 100644 --- a/server/api/intVtigerConfiguration/intVtigerConfiguration.controller.js +++ b/server/api/intVtigerConfiguration/intVtigerConfiguration.controller.js @@ -1 +1 @@ -const a325_0x231a=['catch','includeAll','create','findOne','lodash','VtigerConfiguration','offset','params','name','map','options','count','getDescriptions','length','like','../../mysqldb','undefined','filter','set','intersection','../../components/parsers/qs','sequelize','limit','fields','destroy','model','sort','VtigerField','include','update','json','rows','where','query','filters','merge','rawAttributes','findAll','status','keys','attributes','send','api','index','order','nolimit','type','getSubjects','body','show','pick','end','getFields','then','fieldName'];(function(_0x5c4365,_0x231afc){const _0x429a57=function(_0x3ce6cb){while(--_0x3ce6cb){_0x5c4365['push'](_0x5c4365['shift']());}};_0x429a57(++_0x231afc);}(a325_0x231a,0x13f));const a325_0x429a=function(_0x5c4365,_0x231afc){_0x5c4365=_0x5c4365-0x0;let _0x429a57=a325_0x231a[_0x5c4365];return _0x429a57;};const _0x5b3943=a325_0x429a;'use strict';const _=require(_0x5b3943('0xf')),qs=require(_0x5b3943('0x1f')),logger=require('../../config/logger')(_0x5b3943('0x35')),db=require(_0x5b3943('0x1a'))['db'],{Op}=require(_0x5b3943('0x20'));function respondWithResult(_0x3ce6cb,_0x1491ce){return _0x1491ce=_0x1491ce||0xc8,function(_0x504156){const _0x5ec567=a325_0x429a;if(_0x504156)return _0x3ce6cb[_0x5ec567('0x31')](_0x1491ce)[_0x5ec567('0x29')](_0x504156);};}function respondWithFilteredResult(_0x1a8d7e,_0x4f72ec){return function(_0x6b2a37){const _0xef7b01=a325_0x429a;if(_0x6b2a37){const _0x2ed8ab=_0x6b2a37[_0xef7b01('0x16')],_0x5c4ae0=_0x4f72ec['offset'];let _0x582a11=_0x4f72ec['offset']+_0x4f72ec[_0xef7b01('0x21')],_0x3e2636;return _0x582a11>=_0x2ed8ab?(_0x582a11=_0x2ed8ab,_0x3e2636=0xc8):_0x3e2636=0xce,_0x1a8d7e[_0xef7b01('0x31')](_0x3e2636),_0x1a8d7e[_0xef7b01('0x1d')]('Content-Range',_0x5c4ae0+'-'+_0x582a11+'/'+_0x2ed8ab)[_0xef7b01('0x29')](_0x6b2a37);}return null;};}function saveUpdates(_0x14f3c0){return function(_0x49e9b2){const _0x18fb77=a325_0x429a;if(_0x49e9b2)return _0x49e9b2[_0x18fb77('0x28')](_0x14f3c0)[_0x18fb77('0x9')](function(_0x554c9f){return _0x554c9f;});return null;};}function removeEntity(_0x5803bb){return function(_0x19f825){const _0x4b75dd=a325_0x429a;if(_0x19f825)return _0x19f825[_0x4b75dd('0x23')]()[_0x4b75dd('0x9')](function(){const _0x42c12e=_0x4b75dd;_0x5803bb[_0x42c12e('0x31')](0xcc)[_0x42c12e('0x7')]();});};}function handleEntityNotFound(_0x6c873){return function(_0x3c43d8){return!_0x3c43d8&&_0x6c873['sendStatus'](0x194),_0x3c43d8;};}function handleError(_0x4d0c1a,_0x1c3d28){return _0x1c3d28=_0x1c3d28||0x1f4,function(_0x508cfb){const _0x58f46b=a325_0x429a;logger['error'](_0x508cfb['stack']),_0x508cfb['name']&&delete _0x508cfb[_0x58f46b('0x13')],_0x4d0c1a[_0x58f46b('0x31')](_0x1c3d28)[_0x58f46b('0x34')](_0x508cfb);};}exports[_0x5b3943('0x36')]=function(_0x551c46,_0x37b900){const _0x12d521=_0x5b3943;let _0x151ce7={};const _0x3d226b={},_0x44a979={'count':0x0,'rows':[]},_0x73634f=_[_0x12d521('0x14')](db[_0x12d521('0x10')][_0x12d521('0x2f')],function(_0x56c29a){const _0xcd201e=_0x12d521;return{'name':_0x56c29a[_0xcd201e('0xa')],'type':_0x56c29a[_0xcd201e('0x2')]['key']};});_0x3d226b['model']=_['map'](_0x73634f,'name'),_0x3d226b[_0x12d521('0x2c')]=_['keys'](_0x551c46[_0x12d521('0x2c')]),_0x3d226b[_0x12d521('0x2d')]=_['intersection'](_0x3d226b['model'],_0x3d226b['query']),_0x151ce7['attributes']=_[_0x12d521('0x1e')](_0x3d226b[_0x12d521('0x24')],qs[_0x12d521('0x22')](_0x551c46[_0x12d521('0x2c')][_0x12d521('0x22')])),_0x151ce7[_0x12d521('0x33')]=_0x151ce7[_0x12d521('0x33')][_0x12d521('0x18')]?_0x151ce7[_0x12d521('0x33')]:_0x3d226b[_0x12d521('0x24')];typeof _0x551c46[_0x12d521('0x2c')][_0x12d521('0x1')]===_0x12d521('0x1b')&&(_0x151ce7[_0x12d521('0x21')]=qs[_0x12d521('0x21')](_0x551c46[_0x12d521('0x2c')][_0x12d521('0x21')]),_0x151ce7[_0x12d521('0x11')]=qs[_0x12d521('0x11')](_0x551c46[_0x12d521('0x2c')][_0x12d521('0x11')]));_0x151ce7[_0x12d521('0x0')]=qs[_0x12d521('0x25')](_0x551c46[_0x12d521('0x2c')][_0x12d521('0x25')]),_0x151ce7['where']=qs['filters'](_['pick'](_0x551c46[_0x12d521('0x2c')],_0x3d226b[_0x12d521('0x2d')]),_0x73634f);_0x551c46['query'][_0x12d521('0x1c')]&&(_0x151ce7[_0x12d521('0x2b')]=_[_0x12d521('0x2e')](_0x151ce7['where'],{[Op['or']]:_[_0x12d521('0x14')](_0x73634f,function(_0x3e684a){const _0x1a4765=_0x12d521;if(_0x3e684a['type']!=='VIRTUAL'){const _0x2069ac={};return _0x2069ac[_0x3e684a[_0x1a4765('0x13')]]={[Op[_0x1a4765('0x19')]]:'%'+_0x551c46[_0x1a4765('0x2c')][_0x1a4765('0x1c')]+'%'},_0x2069ac;}})}));_0x151ce7=_['merge']({},_0x151ce7,_0x551c46['options']);const _0xf8c26d={'where':_0x151ce7[_0x12d521('0x2b')]};return db[_0x12d521('0x10')][_0x12d521('0x16')](_0xf8c26d)[_0x12d521('0x9')](function(_0x447e05){const _0x53e084=_0x12d521;return _0x44a979['count']=_0x447e05,_0x551c46['query']['includeAll']&&(_0x151ce7[_0x53e084('0x27')]=[{'all':!![]}]),db[_0x53e084('0x10')][_0x53e084('0x30')](_0x151ce7);})['then'](function(_0x15d142){const _0x263719=_0x12d521;return _0x44a979[_0x263719('0x2a')]=_0x15d142,_0x44a979;})['then'](respondWithFilteredResult(_0x37b900,_0x151ce7))[_0x12d521('0xb')](handleError(_0x37b900,null));},exports[_0x5b3943('0x5')]=function(_0x55e164,_0x71c6d3){const _0xf4869e=_0x5b3943;let _0x418cb3={'raw':![],'where':{'id':_0x55e164[_0xf4869e('0x12')]['id']}};const _0x7b683b={};return _0x7b683b[_0xf4869e('0x24')]=_[_0xf4869e('0x32')](db['VtigerConfiguration'][_0xf4869e('0x2f')]),_0x7b683b[_0xf4869e('0x2c')]=_['keys'](_0x55e164['query']),_0x7b683b['filters']=_[_0xf4869e('0x1e')](_0x7b683b[_0xf4869e('0x24')],_0x7b683b[_0xf4869e('0x2c')]),_0x418cb3[_0xf4869e('0x33')]=_['intersection'](_0x7b683b['model'],qs[_0xf4869e('0x22')](_0x55e164[_0xf4869e('0x2c')][_0xf4869e('0x22')])),_0x418cb3[_0xf4869e('0x33')]=_0x418cb3[_0xf4869e('0x33')][_0xf4869e('0x18')]?_0x418cb3['attributes']:_0x7b683b[_0xf4869e('0x24')],_0x55e164[_0xf4869e('0x2c')][_0xf4869e('0xc')]&&(_0x418cb3[_0xf4869e('0x27')]=[{'all':!![]}]),_0x418cb3=_[_0xf4869e('0x2e')]({},_0x418cb3,_0x55e164['options']),db[_0xf4869e('0x10')]['findOne'](_0x418cb3)['then'](handleEntityNotFound(_0x71c6d3,null))[_0xf4869e('0x9')](respondWithResult(_0x71c6d3,null))[_0xf4869e('0xb')](handleError(_0x71c6d3,null));},exports[_0x5b3943('0xd')]=function(_0x8089ed,_0x5189ca){const _0x2fd7a1=_0x5b3943;return db['VtigerConfiguration']['create'](_0x8089ed[_0x2fd7a1('0x4')],{})[_0x2fd7a1('0x9')](respondWithResult(_0x5189ca,0xc9))[_0x2fd7a1('0xb')](handleError(_0x5189ca,null));},exports['update']=function(_0x1d050e,_0xc2afca){const _0x3383c2=_0x5b3943;return _0x1d050e[_0x3383c2('0x4')]['id']&&delete _0x1d050e[_0x3383c2('0x4')]['id'],db['VtigerConfiguration'][_0x3383c2('0xe')]({'where':{'id':_0x1d050e[_0x3383c2('0x12')]['id']}})[_0x3383c2('0x9')](handleEntityNotFound(_0xc2afca,null))[_0x3383c2('0x9')](saveUpdates(_0x1d050e[_0x3383c2('0x4')],null))[_0x3383c2('0x9')](respondWithResult(_0xc2afca,null))[_0x3383c2('0xb')](handleError(_0xc2afca,null));},exports[_0x5b3943('0x23')]=function(_0x4bd75a,_0x309158){const _0x1cae5d=_0x5b3943;return db['VtigerConfiguration'][_0x1cae5d('0xe')]({'where':{'id':_0x4bd75a[_0x1cae5d('0x12')]['id']}})[_0x1cae5d('0x9')](handleEntityNotFound(_0x309158,null))[_0x1cae5d('0x9')](removeEntity(_0x309158,null))[_0x1cae5d('0xb')](handleError(_0x309158,null));},exports[_0x5b3943('0x8')]=function(_0x3c0917,_0x24d213){const _0x2d1f1d=_0x5b3943;let _0x2872d5={};const _0x138ec6={};let _0x165f27,_0x197a83;return db[_0x2d1f1d('0x10')][_0x2d1f1d('0xe')]({'where':{'id':_0x3c0917['params']['id']}})[_0x2d1f1d('0x9')](handleEntityNotFound(_0x24d213,null))[_0x2d1f1d('0x9')](function(_0x57ca59){const _0x31f206=_0x2d1f1d;if(_0x57ca59)return _0x165f27=_0x57ca59,_0x138ec6[_0x31f206('0x24')]=_['keys'](db['VtigerField']['rawAttributes']),_0x138ec6[_0x31f206('0x2c')]=_[_0x31f206('0x32')](_0x3c0917[_0x31f206('0x2c')]),_0x138ec6[_0x31f206('0x2d')]=_['intersection'](_0x138ec6[_0x31f206('0x24')],_0x138ec6['query']),_0x2872d5['attributes']=_[_0x31f206('0x1e')](_0x138ec6[_0x31f206('0x24')],qs[_0x31f206('0x22')](_0x3c0917[_0x31f206('0x2c')][_0x31f206('0x22')])),_0x2872d5[_0x31f206('0x33')]=_0x2872d5[_0x31f206('0x33')][_0x31f206('0x18')]?_0x2872d5['attributes']:_0x138ec6[_0x31f206('0x24')],_0x2872d5[_0x31f206('0x0')]=qs[_0x31f206('0x25')](_0x3c0917[_0x31f206('0x2c')][_0x31f206('0x25')]),_0x2872d5[_0x31f206('0x2b')]=qs[_0x31f206('0x2d')](_['pick'](_0x3c0917[_0x31f206('0x2c')],_0x138ec6['filters'])),_0x3c0917[_0x31f206('0x2c')]['filter']&&(_0x2872d5[_0x31f206('0x2b')]=_[_0x31f206('0x2e')](_0x2872d5[_0x31f206('0x2b')],{[Op['or']]:_[_0x31f206('0x14')](_0x2872d5[_0x31f206('0x33')],function(_0x23461c){const _0x27381c=_0x31f206,_0x1fa2e9={};return _0x1fa2e9[_0x23461c]={[Op[_0x27381c('0x19')]]:'%'+_0x3c0917[_0x27381c('0x2c')][_0x27381c('0x1c')]+'%'},_0x1fa2e9;})})),_0x2872d5=_[_0x31f206('0x2e')]({},_0x2872d5,_0x3c0917[_0x31f206('0x15')]),_0x165f27['getFields'](_0x2872d5);})[_0x2d1f1d('0x9')](function(_0x5cd22a){const _0x1d9a0a=_0x2d1f1d;if(_0x5cd22a)return _0x197a83=_0x5cd22a['length'],typeof _0x3c0917[_0x1d9a0a('0x2c')]['nolimit']===_0x1d9a0a('0x1b')&&(_0x2872d5[_0x1d9a0a('0x21')]=qs[_0x1d9a0a('0x21')](_0x3c0917[_0x1d9a0a('0x2c')][_0x1d9a0a('0x21')]),_0x2872d5['offset']=qs[_0x1d9a0a('0x11')](_0x3c0917[_0x1d9a0a('0x2c')][_0x1d9a0a('0x11')])),_0x165f27['getFields'](_0x2872d5);})['then'](function(_0x479975){if(_0x479975)return _0x479975?{'count':_0x197a83,'rows':_0x479975}:null;})[_0x2d1f1d('0x9')](respondWithResult(_0x24d213,null))[_0x2d1f1d('0xb')](handleError(_0x24d213,null));},exports['getSubjects']=function(_0xcacf60,_0x2b432d){const _0x42b04e=_0x5b3943;let _0x3e0736={};const _0x5c7289={};let _0x3dc31c,_0x394d3b;return db[_0x42b04e('0x10')][_0x42b04e('0xe')]({'where':{'id':_0xcacf60[_0x42b04e('0x12')]['id']}})[_0x42b04e('0x9')](handleEntityNotFound(_0x2b432d,null))[_0x42b04e('0x9')](function(_0x587976){const _0x57e52f=_0x42b04e;if(_0x587976)return _0x3dc31c=_0x587976,_0x5c7289['model']=_['keys'](db[_0x57e52f('0x26')][_0x57e52f('0x2f')]),_0x5c7289[_0x57e52f('0x2c')]=_[_0x57e52f('0x32')](_0xcacf60['query']),_0x5c7289[_0x57e52f('0x2d')]=_[_0x57e52f('0x1e')](_0x5c7289['model'],_0x5c7289[_0x57e52f('0x2c')]),_0x3e0736[_0x57e52f('0x33')]=_[_0x57e52f('0x1e')](_0x5c7289[_0x57e52f('0x24')],qs[_0x57e52f('0x22')](_0xcacf60[_0x57e52f('0x2c')][_0x57e52f('0x22')])),_0x3e0736['attributes']=_0x3e0736['attributes'][_0x57e52f('0x18')]?_0x3e0736[_0x57e52f('0x33')]:_0x5c7289['model'],_0x3e0736[_0x57e52f('0x0')]=qs['sort'](_0xcacf60[_0x57e52f('0x2c')][_0x57e52f('0x25')]),_0x3e0736[_0x57e52f('0x2b')]=qs[_0x57e52f('0x2d')](_[_0x57e52f('0x6')](_0xcacf60[_0x57e52f('0x2c')],_0x5c7289[_0x57e52f('0x2d')])),_0xcacf60[_0x57e52f('0x2c')][_0x57e52f('0x1c')]&&(_0x3e0736[_0x57e52f('0x2b')]=_[_0x57e52f('0x2e')](_0x3e0736[_0x57e52f('0x2b')],{[Op['or']]:_[_0x57e52f('0x14')](_0x3e0736[_0x57e52f('0x33')],function(_0x48be43){const _0xe1b5e2=_0x57e52f,_0x273a7b={};return _0x273a7b[_0x48be43]={[Op[_0xe1b5e2('0x19')]]:'%'+_0xcacf60[_0xe1b5e2('0x2c')][_0xe1b5e2('0x1c')]+'%'},_0x273a7b;})})),_0x3e0736=_[_0x57e52f('0x2e')]({},_0x3e0736,_0xcacf60['options']),_0x3dc31c[_0x57e52f('0x3')](_0x3e0736);})[_0x42b04e('0x9')](function(_0x3c5af2){const _0x52af0c=_0x42b04e;if(_0x3c5af2)return _0x394d3b=_0x3c5af2[_0x52af0c('0x18')],typeof _0xcacf60[_0x52af0c('0x2c')][_0x52af0c('0x1')]==='undefined'&&(_0x3e0736[_0x52af0c('0x21')]=qs[_0x52af0c('0x21')](_0xcacf60[_0x52af0c('0x2c')]['limit']),_0x3e0736[_0x52af0c('0x11')]=qs[_0x52af0c('0x11')](_0xcacf60[_0x52af0c('0x2c')][_0x52af0c('0x11')])),_0x3dc31c[_0x52af0c('0x3')](_0x3e0736);})[_0x42b04e('0x9')](function(_0x5a564c){if(_0x5a564c)return _0x5a564c?{'count':_0x394d3b,'rows':_0x5a564c}:null;})[_0x42b04e('0x9')](respondWithResult(_0x2b432d,null))[_0x42b04e('0xb')](handleError(_0x2b432d,null));},exports[_0x5b3943('0x17')]=function(_0x224c88,_0x4b04bd){const _0x132225=_0x5b3943;let _0x19c135={};const _0x2a2dff={};let _0x54b715,_0x2a902c;return db[_0x132225('0x10')][_0x132225('0xe')]({'where':{'id':_0x224c88[_0x132225('0x12')]['id']}})[_0x132225('0x9')](handleEntityNotFound(_0x4b04bd,null))[_0x132225('0x9')](function(_0x4f7cf9){const _0x5d83a4=_0x132225;if(_0x4f7cf9)return _0x54b715=_0x4f7cf9,_0x2a2dff[_0x5d83a4('0x24')]=_['keys'](db['VtigerField'][_0x5d83a4('0x2f')]),_0x2a2dff[_0x5d83a4('0x2c')]=_[_0x5d83a4('0x32')](_0x224c88[_0x5d83a4('0x2c')]),_0x2a2dff['filters']=_[_0x5d83a4('0x1e')](_0x2a2dff['model'],_0x2a2dff[_0x5d83a4('0x2c')]),_0x19c135[_0x5d83a4('0x33')]=_['intersection'](_0x2a2dff[_0x5d83a4('0x24')],qs[_0x5d83a4('0x22')](_0x224c88[_0x5d83a4('0x2c')][_0x5d83a4('0x22')])),_0x19c135[_0x5d83a4('0x33')]=_0x19c135[_0x5d83a4('0x33')][_0x5d83a4('0x18')]?_0x19c135['attributes']:_0x2a2dff['model'],_0x19c135[_0x5d83a4('0x0')]=qs[_0x5d83a4('0x25')](_0x224c88[_0x5d83a4('0x2c')][_0x5d83a4('0x25')]),_0x19c135[_0x5d83a4('0x2b')]=qs[_0x5d83a4('0x2d')](_['pick'](_0x224c88[_0x5d83a4('0x2c')],_0x2a2dff[_0x5d83a4('0x2d')])),_0x224c88['query'][_0x5d83a4('0x1c')]&&(_0x19c135[_0x5d83a4('0x2b')]=_[_0x5d83a4('0x2e')](_0x19c135['where'],{[Op['or']]:_[_0x5d83a4('0x14')](_0x19c135[_0x5d83a4('0x33')],function(_0x191ee1){const _0x33d964=_0x5d83a4,_0x1a8cdc={};return _0x1a8cdc[_0x191ee1]={[Op[_0x33d964('0x19')]]:'%'+_0x224c88[_0x33d964('0x2c')][_0x33d964('0x1c')]+'%'},_0x1a8cdc;})})),_0x19c135=_[_0x5d83a4('0x2e')]({},_0x19c135,_0x224c88[_0x5d83a4('0x15')]),_0x54b715['getDescriptions'](_0x19c135);})[_0x132225('0x9')](function(_0x20dcb9){const _0xddced5=_0x132225;if(_0x20dcb9)return _0x2a902c=_0x20dcb9['length'],typeof _0x224c88[_0xddced5('0x2c')]['nolimit']==='undefined'&&(_0x19c135[_0xddced5('0x21')]=qs['limit'](_0x224c88['query'][_0xddced5('0x21')]),_0x19c135[_0xddced5('0x11')]=qs[_0xddced5('0x11')](_0x224c88['query'][_0xddced5('0x11')])),_0x54b715['getDescriptions'](_0x19c135);})[_0x132225('0x9')](function(_0x1d6c5e){if(_0x1d6c5e)return _0x1d6c5e?{'count':_0x2a902c,'rows':_0x1d6c5e}:null;})[_0x132225('0x9')](respondWithResult(_0x4b04bd,null))[_0x132225('0xb')](handleError(_0x4b04bd,null));}; \ No newline at end of file +const a325_0x452d=['length','query','limit','../../config/logger','filter','type','VIRTUAL','update','merge','../../mysqldb','attributes','offset','params','like','api','getFields','filters','then','Content-Range','findAll','map','undefined','destroy','intersection','pick','send','json','sort','order','name','error','index','VtigerField','key','options','nolimit','set','includeAll','VtigerConfiguration','getSubjects','catch','sendStatus','count','rows','findOne','getDescriptions','rawAttributes','status','create','keys','body','../../components/parsers/qs','model','fields','show','where'];(function(_0xfbbd62,_0x452dfb){const _0x3673d2=function(_0x56237f){while(--_0x56237f){_0xfbbd62['push'](_0xfbbd62['shift']());}};_0x3673d2(++_0x452dfb);}(a325_0x452d,0x76));const a325_0x3673=function(_0xfbbd62,_0x452dfb){_0xfbbd62=_0xfbbd62-0x0;let _0x3673d2=a325_0x452d[_0xfbbd62];return _0x3673d2;};const _0x38aeb5=a325_0x3673;'use strict';const _=require('lodash'),qs=require(_0x38aeb5('0x2d')),logger=require(_0x38aeb5('0x35'))(_0x38aeb5('0x8')),db=require(_0x38aeb5('0x3'))['db'],{Op}=require('sequelize');function respondWithResult(_0x56237f,_0x2395c9){return _0x2395c9=_0x2395c9||0xc8,function(_0x248c3d){const _0x26c86f=a325_0x3673;if(_0x248c3d)return _0x56237f[_0x26c86f('0x29')](_0x2395c9)[_0x26c86f('0x14')](_0x248c3d);};}function respondWithFilteredResult(_0x5cdde9,_0x4962b9){return function(_0x464429){const _0xb44ea2=a325_0x3673;if(_0x464429){const _0x46e492=_0x464429[_0xb44ea2('0x24')],_0x3fbe50=_0x4962b9[_0xb44ea2('0x5')];let _0x2269d0=_0x4962b9['offset']+_0x4962b9['limit'],_0x22c9a7;return _0x2269d0>=_0x46e492?(_0x2269d0=_0x46e492,_0x22c9a7=0xc8):_0x22c9a7=0xce,_0x5cdde9[_0xb44ea2('0x29')](_0x22c9a7),_0x5cdde9[_0xb44ea2('0x1e')](_0xb44ea2('0xc'),_0x3fbe50+'-'+_0x2269d0+'/'+_0x46e492)[_0xb44ea2('0x14')](_0x464429);}return null;};}function saveUpdates(_0x578200){return function(_0x1ccd7b){const _0x5c1dd0=a325_0x3673;if(_0x1ccd7b)return _0x1ccd7b[_0x5c1dd0('0x1')](_0x578200)[_0x5c1dd0('0xb')](function(_0x1054ac){return _0x1054ac;});return null;};}function removeEntity(_0x4bd751){return function(_0x22fc34){const _0x27cfbe=a325_0x3673;if(_0x22fc34)return _0x22fc34[_0x27cfbe('0x10')]()['then'](function(){const _0x497e43=_0x27cfbe;_0x4bd751[_0x497e43('0x29')](0xcc)['end']();});};}function handleEntityNotFound(_0x17b4d8){return function(_0x4368ad){const _0xbe7b8a=a325_0x3673;return!_0x4368ad&&_0x17b4d8[_0xbe7b8a('0x23')](0x194),_0x4368ad;};}function handleError(_0x14dcae,_0x572663){return _0x572663=_0x572663||0x1f4,function(_0x5efb8c){const _0x28e36a=a325_0x3673;logger[_0x28e36a('0x18')](_0x5efb8c['stack']),_0x5efb8c[_0x28e36a('0x17')]&&delete _0x5efb8c[_0x28e36a('0x17')],_0x14dcae['status'](_0x572663)[_0x28e36a('0x13')](_0x5efb8c);};}exports[_0x38aeb5('0x19')]=function(_0x200bae,_0x1d40b4){const _0x14fa59=_0x38aeb5;let _0x3d3409={};const _0x2e1ec7={},_0x3562ce={'count':0x0,'rows':[]},_0x5bb7da=_['map'](db['VtigerConfiguration'][_0x14fa59('0x28')],function(_0x33cf21){const _0x103559=_0x14fa59;return{'name':_0x33cf21['fieldName'],'type':_0x33cf21[_0x103559('0x37')][_0x103559('0x1b')]};});_0x2e1ec7[_0x14fa59('0x2e')]=_[_0x14fa59('0xe')](_0x5bb7da,_0x14fa59('0x17')),_0x2e1ec7[_0x14fa59('0x33')]=_[_0x14fa59('0x2b')](_0x200bae[_0x14fa59('0x33')]),_0x2e1ec7[_0x14fa59('0xa')]=_[_0x14fa59('0x11')](_0x2e1ec7['model'],_0x2e1ec7[_0x14fa59('0x33')]),_0x3d3409[_0x14fa59('0x4')]=_['intersection'](_0x2e1ec7[_0x14fa59('0x2e')],qs[_0x14fa59('0x2f')](_0x200bae[_0x14fa59('0x33')][_0x14fa59('0x2f')])),_0x3d3409[_0x14fa59('0x4')]=_0x3d3409[_0x14fa59('0x4')][_0x14fa59('0x32')]?_0x3d3409[_0x14fa59('0x4')]:_0x2e1ec7[_0x14fa59('0x2e')];typeof _0x200bae[_0x14fa59('0x33')][_0x14fa59('0x1d')]===_0x14fa59('0xf')&&(_0x3d3409[_0x14fa59('0x34')]=qs['limit'](_0x200bae['query'][_0x14fa59('0x34')]),_0x3d3409[_0x14fa59('0x5')]=qs[_0x14fa59('0x5')](_0x200bae[_0x14fa59('0x33')][_0x14fa59('0x5')]));_0x3d3409[_0x14fa59('0x16')]=qs[_0x14fa59('0x15')](_0x200bae['query']['sort']),_0x3d3409['where']=qs[_0x14fa59('0xa')](_[_0x14fa59('0x12')](_0x200bae[_0x14fa59('0x33')],_0x2e1ec7[_0x14fa59('0xa')]),_0x5bb7da);_0x200bae['query'][_0x14fa59('0x36')]&&(_0x3d3409[_0x14fa59('0x31')]=_[_0x14fa59('0x2')](_0x3d3409[_0x14fa59('0x31')],{[Op['or']]:_['map'](_0x5bb7da,function(_0x51fb02){const _0x3c6c35=_0x14fa59;if(_0x51fb02[_0x3c6c35('0x37')]!==_0x3c6c35('0x0')){const _0x238c0b={};return _0x238c0b[_0x51fb02[_0x3c6c35('0x17')]]={[Op[_0x3c6c35('0x7')]]:'%'+_0x200bae[_0x3c6c35('0x33')][_0x3c6c35('0x36')]+'%'},_0x238c0b;}})}));_0x3d3409=_[_0x14fa59('0x2')]({},_0x3d3409,_0x200bae[_0x14fa59('0x1c')]);const _0x589bd8={'where':_0x3d3409['where']};return db[_0x14fa59('0x20')][_0x14fa59('0x24')](_0x589bd8)['then'](function(_0x259600){const _0x28ee23=_0x14fa59;return _0x3562ce['count']=_0x259600,_0x200bae[_0x28ee23('0x33')][_0x28ee23('0x1f')]&&(_0x3d3409['include']=[{'all':!![]}]),db[_0x28ee23('0x20')][_0x28ee23('0xd')](_0x3d3409);})['then'](function(_0x35c498){const _0x5cdac3=_0x14fa59;return _0x3562ce[_0x5cdac3('0x25')]=_0x35c498,_0x3562ce;})[_0x14fa59('0xb')](respondWithFilteredResult(_0x1d40b4,_0x3d3409))[_0x14fa59('0x22')](handleError(_0x1d40b4,null));},exports[_0x38aeb5('0x30')]=function(_0x659385,_0x2e5028){const _0x2ba377=_0x38aeb5;let _0x1cf54e={'raw':![],'where':{'id':_0x659385[_0x2ba377('0x6')]['id']}};const _0x3539e={};return _0x3539e[_0x2ba377('0x2e')]=_[_0x2ba377('0x2b')](db[_0x2ba377('0x20')][_0x2ba377('0x28')]),_0x3539e[_0x2ba377('0x33')]=_['keys'](_0x659385['query']),_0x3539e[_0x2ba377('0xa')]=_[_0x2ba377('0x11')](_0x3539e[_0x2ba377('0x2e')],_0x3539e[_0x2ba377('0x33')]),_0x1cf54e[_0x2ba377('0x4')]=_['intersection'](_0x3539e[_0x2ba377('0x2e')],qs['fields'](_0x659385[_0x2ba377('0x33')]['fields'])),_0x1cf54e[_0x2ba377('0x4')]=_0x1cf54e[_0x2ba377('0x4')][_0x2ba377('0x32')]?_0x1cf54e[_0x2ba377('0x4')]:_0x3539e[_0x2ba377('0x2e')],_0x659385['query'][_0x2ba377('0x1f')]&&(_0x1cf54e['include']=[{'all':!![]}]),_0x1cf54e=_['merge']({},_0x1cf54e,_0x659385[_0x2ba377('0x1c')]),db[_0x2ba377('0x20')][_0x2ba377('0x26')](_0x1cf54e)[_0x2ba377('0xb')](handleEntityNotFound(_0x2e5028,null))[_0x2ba377('0xb')](respondWithResult(_0x2e5028,null))[_0x2ba377('0x22')](handleError(_0x2e5028,null));},exports[_0x38aeb5('0x2a')]=function(_0x2d79be,_0x5625cf){const _0x308e52=_0x38aeb5;return db[_0x308e52('0x20')][_0x308e52('0x2a')](_0x2d79be[_0x308e52('0x2c')],{})['then'](respondWithResult(_0x5625cf,0xc9))[_0x308e52('0x22')](handleError(_0x5625cf,null));},exports[_0x38aeb5('0x1')]=function(_0x4ce6f4,_0x11fe59){const _0x7d3b4f=_0x38aeb5;return _0x4ce6f4[_0x7d3b4f('0x2c')]['id']&&delete _0x4ce6f4[_0x7d3b4f('0x2c')]['id'],db['VtigerConfiguration'][_0x7d3b4f('0x26')]({'where':{'id':_0x4ce6f4[_0x7d3b4f('0x6')]['id']}})[_0x7d3b4f('0xb')](handleEntityNotFound(_0x11fe59,null))[_0x7d3b4f('0xb')](saveUpdates(_0x4ce6f4[_0x7d3b4f('0x2c')],null))[_0x7d3b4f('0xb')](respondWithResult(_0x11fe59,null))[_0x7d3b4f('0x22')](handleError(_0x11fe59,null));},exports['destroy']=function(_0x591415,_0x3d2bdc){const _0x478e7e=_0x38aeb5;return db[_0x478e7e('0x20')][_0x478e7e('0x26')]({'where':{'id':_0x591415[_0x478e7e('0x6')]['id']}})['then'](handleEntityNotFound(_0x3d2bdc,null))[_0x478e7e('0xb')](removeEntity(_0x3d2bdc,null))[_0x478e7e('0x22')](handleError(_0x3d2bdc,null));},exports[_0x38aeb5('0x9')]=function(_0xe2c07f,_0x2029c2){const _0x2a5596=_0x38aeb5;let _0x218376={};const _0x2d8cbc={};let _0xe17e1c,_0x47f48e;return db[_0x2a5596('0x20')][_0x2a5596('0x26')]({'where':{'id':_0xe2c07f['params']['id']}})['then'](handleEntityNotFound(_0x2029c2,null))['then'](function(_0x344cad){const _0x144ee0=_0x2a5596;if(_0x344cad)return _0xe17e1c=_0x344cad,_0x2d8cbc['model']=_[_0x144ee0('0x2b')](db[_0x144ee0('0x1a')][_0x144ee0('0x28')]),_0x2d8cbc[_0x144ee0('0x33')]=_[_0x144ee0('0x2b')](_0xe2c07f['query']),_0x2d8cbc[_0x144ee0('0xa')]=_['intersection'](_0x2d8cbc['model'],_0x2d8cbc['query']),_0x218376[_0x144ee0('0x4')]=_['intersection'](_0x2d8cbc['model'],qs[_0x144ee0('0x2f')](_0xe2c07f['query'][_0x144ee0('0x2f')])),_0x218376[_0x144ee0('0x4')]=_0x218376[_0x144ee0('0x4')][_0x144ee0('0x32')]?_0x218376[_0x144ee0('0x4')]:_0x2d8cbc[_0x144ee0('0x2e')],_0x218376[_0x144ee0('0x16')]=qs[_0x144ee0('0x15')](_0xe2c07f[_0x144ee0('0x33')][_0x144ee0('0x15')]),_0x218376[_0x144ee0('0x31')]=qs[_0x144ee0('0xa')](_[_0x144ee0('0x12')](_0xe2c07f[_0x144ee0('0x33')],_0x2d8cbc[_0x144ee0('0xa')])),_0xe2c07f[_0x144ee0('0x33')]['filter']&&(_0x218376[_0x144ee0('0x31')]=_[_0x144ee0('0x2')](_0x218376[_0x144ee0('0x31')],{[Op['or']]:_[_0x144ee0('0xe')](_0x218376[_0x144ee0('0x4')],function(_0x539e0a){const _0xf02836=_0x144ee0,_0x188794={};return _0x188794[_0x539e0a]={[Op[_0xf02836('0x7')]]:'%'+_0xe2c07f[_0xf02836('0x33')][_0xf02836('0x36')]+'%'},_0x188794;})})),_0x218376=_[_0x144ee0('0x2')]({},_0x218376,_0xe2c07f[_0x144ee0('0x1c')]),_0xe17e1c[_0x144ee0('0x9')](_0x218376);})[_0x2a5596('0xb')](function(_0x4df567){const _0x37875c=_0x2a5596;if(_0x4df567)return _0x47f48e=_0x4df567['length'],typeof _0xe2c07f['query'][_0x37875c('0x1d')]==='undefined'&&(_0x218376['limit']=qs['limit'](_0xe2c07f[_0x37875c('0x33')][_0x37875c('0x34')]),_0x218376['offset']=qs[_0x37875c('0x5')](_0xe2c07f[_0x37875c('0x33')]['offset'])),_0xe17e1c['getFields'](_0x218376);})[_0x2a5596('0xb')](function(_0x48289e){if(_0x48289e)return _0x48289e?{'count':_0x47f48e,'rows':_0x48289e}:null;})[_0x2a5596('0xb')](respondWithResult(_0x2029c2,null))[_0x2a5596('0x22')](handleError(_0x2029c2,null));},exports[_0x38aeb5('0x21')]=function(_0x1f4fc8,_0x300929){const _0x4d7ded=_0x38aeb5;let _0x57dcd9={};const _0x62e48e={};let _0x5d8c1b,_0x4ff225;return db[_0x4d7ded('0x20')][_0x4d7ded('0x26')]({'where':{'id':_0x1f4fc8[_0x4d7ded('0x6')]['id']}})[_0x4d7ded('0xb')](handleEntityNotFound(_0x300929,null))[_0x4d7ded('0xb')](function(_0x48e726){const _0x30d0ba=_0x4d7ded;if(_0x48e726)return _0x5d8c1b=_0x48e726,_0x62e48e[_0x30d0ba('0x2e')]=_['keys'](db[_0x30d0ba('0x1a')]['rawAttributes']),_0x62e48e[_0x30d0ba('0x33')]=_[_0x30d0ba('0x2b')](_0x1f4fc8['query']),_0x62e48e['filters']=_[_0x30d0ba('0x11')](_0x62e48e[_0x30d0ba('0x2e')],_0x62e48e['query']),_0x57dcd9[_0x30d0ba('0x4')]=_[_0x30d0ba('0x11')](_0x62e48e[_0x30d0ba('0x2e')],qs[_0x30d0ba('0x2f')](_0x1f4fc8[_0x30d0ba('0x33')]['fields'])),_0x57dcd9[_0x30d0ba('0x4')]=_0x57dcd9[_0x30d0ba('0x4')]['length']?_0x57dcd9['attributes']:_0x62e48e[_0x30d0ba('0x2e')],_0x57dcd9[_0x30d0ba('0x16')]=qs[_0x30d0ba('0x15')](_0x1f4fc8[_0x30d0ba('0x33')][_0x30d0ba('0x15')]),_0x57dcd9[_0x30d0ba('0x31')]=qs[_0x30d0ba('0xa')](_[_0x30d0ba('0x12')](_0x1f4fc8[_0x30d0ba('0x33')],_0x62e48e[_0x30d0ba('0xa')])),_0x1f4fc8[_0x30d0ba('0x33')][_0x30d0ba('0x36')]&&(_0x57dcd9[_0x30d0ba('0x31')]=_['merge'](_0x57dcd9[_0x30d0ba('0x31')],{[Op['or']]:_[_0x30d0ba('0xe')](_0x57dcd9[_0x30d0ba('0x4')],function(_0x50952d){const _0x22ae22=_0x30d0ba,_0x2f65f6={};return _0x2f65f6[_0x50952d]={[Op[_0x22ae22('0x7')]]:'%'+_0x1f4fc8[_0x22ae22('0x33')][_0x22ae22('0x36')]+'%'},_0x2f65f6;})})),_0x57dcd9=_[_0x30d0ba('0x2')]({},_0x57dcd9,_0x1f4fc8[_0x30d0ba('0x1c')]),_0x5d8c1b[_0x30d0ba('0x21')](_0x57dcd9);})['then'](function(_0x567927){const _0x30baa4=_0x4d7ded;if(_0x567927)return _0x4ff225=_0x567927[_0x30baa4('0x32')],typeof _0x1f4fc8[_0x30baa4('0x33')][_0x30baa4('0x1d')]==='undefined'&&(_0x57dcd9[_0x30baa4('0x34')]=qs[_0x30baa4('0x34')](_0x1f4fc8['query'][_0x30baa4('0x34')]),_0x57dcd9[_0x30baa4('0x5')]=qs['offset'](_0x1f4fc8[_0x30baa4('0x33')][_0x30baa4('0x5')])),_0x5d8c1b[_0x30baa4('0x21')](_0x57dcd9);})[_0x4d7ded('0xb')](function(_0x2bad70){if(_0x2bad70)return _0x2bad70?{'count':_0x4ff225,'rows':_0x2bad70}:null;})[_0x4d7ded('0xb')](respondWithResult(_0x300929,null))[_0x4d7ded('0x22')](handleError(_0x300929,null));},exports[_0x38aeb5('0x27')]=function(_0x2157c4,_0x45c86b){const _0x3c9f2d=_0x38aeb5;let _0x20dcb0={};const _0x5e121c={};let _0x2e6617,_0x46ee1b;return db['VtigerConfiguration'][_0x3c9f2d('0x26')]({'where':{'id':_0x2157c4['params']['id']}})[_0x3c9f2d('0xb')](handleEntityNotFound(_0x45c86b,null))['then'](function(_0x1b9738){const _0x56a08d=_0x3c9f2d;if(_0x1b9738)return _0x2e6617=_0x1b9738,_0x5e121c['model']=_[_0x56a08d('0x2b')](db[_0x56a08d('0x1a')][_0x56a08d('0x28')]),_0x5e121c['query']=_['keys'](_0x2157c4[_0x56a08d('0x33')]),_0x5e121c[_0x56a08d('0xa')]=_[_0x56a08d('0x11')](_0x5e121c[_0x56a08d('0x2e')],_0x5e121c[_0x56a08d('0x33')]),_0x20dcb0['attributes']=_['intersection'](_0x5e121c['model'],qs[_0x56a08d('0x2f')](_0x2157c4[_0x56a08d('0x33')][_0x56a08d('0x2f')])),_0x20dcb0[_0x56a08d('0x4')]=_0x20dcb0['attributes'][_0x56a08d('0x32')]?_0x20dcb0[_0x56a08d('0x4')]:_0x5e121c[_0x56a08d('0x2e')],_0x20dcb0[_0x56a08d('0x16')]=qs[_0x56a08d('0x15')](_0x2157c4[_0x56a08d('0x33')][_0x56a08d('0x15')]),_0x20dcb0[_0x56a08d('0x31')]=qs[_0x56a08d('0xa')](_[_0x56a08d('0x12')](_0x2157c4[_0x56a08d('0x33')],_0x5e121c[_0x56a08d('0xa')])),_0x2157c4[_0x56a08d('0x33')]['filter']&&(_0x20dcb0['where']=_[_0x56a08d('0x2')](_0x20dcb0['where'],{[Op['or']]:_[_0x56a08d('0xe')](_0x20dcb0[_0x56a08d('0x4')],function(_0x1b312d){const _0x44410c=_0x56a08d,_0x1245ea={};return _0x1245ea[_0x1b312d]={[Op[_0x44410c('0x7')]]:'%'+_0x2157c4[_0x44410c('0x33')][_0x44410c('0x36')]+'%'},_0x1245ea;})})),_0x20dcb0=_[_0x56a08d('0x2')]({},_0x20dcb0,_0x2157c4[_0x56a08d('0x1c')]),_0x2e6617[_0x56a08d('0x27')](_0x20dcb0);})[_0x3c9f2d('0xb')](function(_0x2e17ad){const _0x2110b6=_0x3c9f2d;if(_0x2e17ad)return _0x46ee1b=_0x2e17ad[_0x2110b6('0x32')],typeof _0x2157c4['query'][_0x2110b6('0x1d')]===_0x2110b6('0xf')&&(_0x20dcb0['limit']=qs[_0x2110b6('0x34')](_0x2157c4[_0x2110b6('0x33')][_0x2110b6('0x34')]),_0x20dcb0[_0x2110b6('0x5')]=qs[_0x2110b6('0x5')](_0x2157c4['query']['offset'])),_0x2e6617['getDescriptions'](_0x20dcb0);})[_0x3c9f2d('0xb')](function(_0x47e969){if(_0x47e969)return _0x47e969?{'count':_0x46ee1b,'rows':_0x47e969}:null;})[_0x3c9f2d('0xb')](respondWithResult(_0x45c86b,null))[_0x3c9f2d('0x22')](handleError(_0x45c86b,null));}; \ No newline at end of file diff --git a/server/api/intVtigerConfiguration/intVtigerConfiguration.model.js b/server/api/intVtigerConfiguration/intVtigerConfiguration.model.js index ea48563..1024924 100644 --- a/server/api/intVtigerConfiguration/intVtigerConfiguration.model.js +++ b/server/api/intVtigerConfiguration/intVtigerConfiguration.model.js @@ -1 +1 @@ -const a326_0x1bd6=['exports','VtigerConfiguration','./intVtigerConfiguration.attributes','int_vtiger_configurations'];(function(_0x1bbb52,_0x1bd659){const _0x2b6545=function(_0x463d1a){while(--_0x463d1a){_0x1bbb52['push'](_0x1bbb52['shift']());}};_0x2b6545(++_0x1bd659);}(a326_0x1bd6,0x19f));const a326_0x2b65=function(_0x1bbb52,_0x1bd659){_0x1bbb52=_0x1bbb52-0x0;let _0x2b6545=a326_0x1bd6[_0x1bbb52];return _0x2b6545;};const _0x587625=a326_0x2b65;'use strict';const attributes=require(_0x587625('0x3'));module[_0x587625('0x1')]=function(_0x463d1a){const _0x4b5943=_0x587625,_0x57697e=_0x463d1a['define'](_0x4b5943('0x2'),attributes,{'tableName':_0x4b5943('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x57697e;}; \ No newline at end of file +const a326_0xef52=['./intVtigerConfiguration.attributes','define','exports'];(function(_0xaec7db,_0xef524){const _0x562beb=function(_0x19adb1){while(--_0x19adb1){_0xaec7db['push'](_0xaec7db['shift']());}};_0x562beb(++_0xef524);}(a326_0xef52,0x105));const a326_0x562b=function(_0xaec7db,_0xef524){_0xaec7db=_0xaec7db-0x0;let _0x562beb=a326_0xef52[_0xaec7db];return _0x562beb;};const _0x5f3d85=a326_0x562b;'use strict';const attributes=require(_0x5f3d85('0x0'));module[_0x5f3d85('0x2')]=function(_0x19adb1){const _0x4e85a9=_0x5f3d85,_0x58a968=_0x19adb1[_0x4e85a9('0x1')]('VtigerConfiguration',attributes,{'tableName':'int_vtiger_configurations','paranoid':![],'indexes':[],'timestamps':!![]});return _0x58a968;}; \ No newline at end of file diff --git a/server/api/intVtigerField/index.js b/server/api/intVtigerField/index.js index b37e88e..726e14b 100644 --- a/server/api/intVtigerField/index.js +++ b/server/api/intVtigerField/index.js @@ -1 +1 @@ -const a327_0x3372=['post','create','exports','isAuthenticated','get','./intVtigerField.controller','/:id','delete','Router','destroy','put','show'];(function(_0x5e4f99,_0x3372bf){const _0x56a9c1=function(_0x59484f){while(--_0x59484f){_0x5e4f99['push'](_0x5e4f99['shift']());}};_0x56a9c1(++_0x3372bf);}(a327_0x3372,0x186));const a327_0x56a9=function(_0x5e4f99,_0x3372bf){_0x5e4f99=_0x5e4f99-0x0;let _0x56a9c1=a327_0x3372[_0x5e4f99];return _0x56a9c1;};const _0x5a13f1=a327_0x56a9;'use strict';const express=require('express'),router=express[_0x5a13f1('0x2')](),auth=require('../../components/auth/service'),controller=require(_0x5a13f1('0xb'));router[_0x5a13f1('0xa')]('/',auth[_0x5a13f1('0x9')](),controller['index']),router[_0x5a13f1('0xa')](_0x5a13f1('0x0'),auth[_0x5a13f1('0x9')](),controller[_0x5a13f1('0x5')]),router[_0x5a13f1('0x6')]('/',auth[_0x5a13f1('0x9')](),controller[_0x5a13f1('0x7')]),router[_0x5a13f1('0x4')](_0x5a13f1('0x0'),auth[_0x5a13f1('0x9')](),controller['update']),router[_0x5a13f1('0x1')](_0x5a13f1('0x0'),auth['isAuthenticated'](),controller[_0x5a13f1('0x3')]),module[_0x5a13f1('0x8')]=router; \ No newline at end of file +const a327_0x1d3b=['/:id','delete','update','express','get','./intVtigerField.controller','put','../../components/auth/service','isAuthenticated','destroy','show','Router','post'];(function(_0x3d4c32,_0x1d3bfd){const _0x2f966f=function(_0x379dd4){while(--_0x379dd4){_0x3d4c32['push'](_0x3d4c32['shift']());}};_0x2f966f(++_0x1d3bfd);}(a327_0x1d3b,0x164));const a327_0x2f96=function(_0x3d4c32,_0x1d3bfd){_0x3d4c32=_0x3d4c32-0x0;let _0x2f966f=a327_0x1d3b[_0x3d4c32];return _0x2f966f;};const _0x55586e=a327_0x2f96;'use strict';const express=require(_0x55586e('0xb')),router=express[_0x55586e('0x6')](),auth=require(_0x55586e('0x2')),controller=require(_0x55586e('0x0'));router[_0x55586e('0xc')]('/',auth[_0x55586e('0x3')](),controller['index']),router[_0x55586e('0xc')](_0x55586e('0x8'),auth[_0x55586e('0x3')](),controller[_0x55586e('0x5')]),router[_0x55586e('0x7')]('/',auth[_0x55586e('0x3')](),controller['create']),router[_0x55586e('0x1')](_0x55586e('0x8'),auth['isAuthenticated'](),controller[_0x55586e('0xa')]),router[_0x55586e('0x9')]('/:id',auth['isAuthenticated'](),controller[_0x55586e('0x4')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/intVtigerField/intVtigerField.attributes.js b/server/api/intVtigerField/intVtigerField.attributes.js index 4dc8fea..01b0eba 100644 --- a/server/api/intVtigerField/intVtigerField.attributes.js +++ b/server/api/intVtigerField/intVtigerField.attributes.js @@ -1 +1 @@ -const a328_0x2e58=['ENUM','sequelize','string','variable','STRING'];(function(_0x22c352,_0x2e581e){const _0x3e7c6f=function(_0x1bdc6a){while(--_0x1bdc6a){_0x22c352['push'](_0x22c352['shift']());}};_0x3e7c6f(++_0x2e581e);}(a328_0x2e58,0x96));const a328_0x3e7c=function(_0x22c352,_0x2e581e){_0x22c352=_0x22c352-0x0;let _0x3e7c6f=a328_0x2e58[_0x22c352];return _0x3e7c6f;};const _0x39d724=a328_0x3e7c;'use strict';const Sequelize=require(_0x39d724('0x1'));module['exports']={'type':{'type':Sequelize[_0x39d724('0x0')](_0x39d724('0x2'),_0x39d724('0x3'),'customVariable','keyValue'),'defaultValue':_0x39d724('0x2')},'content':{'type':Sequelize[_0x39d724('0x4')]},'key':{'type':Sequelize[_0x39d724('0x4')]},'keyType':{'type':Sequelize[_0x39d724('0x0')](_0x39d724('0x2'),_0x39d724('0x3'),'customVariable')},'keyContent':{'type':Sequelize[_0x39d724('0x4')]},'idField':{'type':Sequelize[_0x39d724('0x4')]},'nameField':{'type':Sequelize[_0x39d724('0x4')]},'customField':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x39d724('0x4')]}}; \ No newline at end of file +const a328_0x4769=['ENUM','string','exports','variable','sequelize','keyValue','STRING','customVariable'];(function(_0x427ba7,_0x476985){const _0x5ac4e1=function(_0x313955){while(--_0x313955){_0x427ba7['push'](_0x427ba7['shift']());}};_0x5ac4e1(++_0x476985);}(a328_0x4769,0x140));const a328_0x5ac4=function(_0x427ba7,_0x476985){_0x427ba7=_0x427ba7-0x0;let _0x5ac4e1=a328_0x4769[_0x427ba7];return _0x5ac4e1;};const _0x4c012a=a328_0x5ac4;'use strict';const Sequelize=require(_0x4c012a('0x4'));module[_0x4c012a('0x2')]={'type':{'type':Sequelize[_0x4c012a('0x0')](_0x4c012a('0x1'),'variable',_0x4c012a('0x7'),_0x4c012a('0x5')),'defaultValue':_0x4c012a('0x1')},'content':{'type':Sequelize[_0x4c012a('0x6')]},'key':{'type':Sequelize['STRING']},'keyType':{'type':Sequelize['ENUM'](_0x4c012a('0x1'),_0x4c012a('0x3'),_0x4c012a('0x7'))},'keyContent':{'type':Sequelize[_0x4c012a('0x6')]},'idField':{'type':Sequelize[_0x4c012a('0x6')]},'nameField':{'type':Sequelize[_0x4c012a('0x6')]},'customField':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x4c012a('0x6')]}}; \ No newline at end of file diff --git a/server/api/intVtigerField/intVtigerField.controller.js b/server/api/intVtigerField/intVtigerField.controller.js index e107aaf..d8006ed 100644 --- a/server/api/intVtigerField/intVtigerField.controller.js +++ b/server/api/intVtigerField/intVtigerField.controller.js @@ -1 +1 @@ -const a329_0x1dce=['options','body','rawAttributes','update','fields','end','includeAll','Content-Range','intersection','model','query','like','sendStatus','map','sequelize','../../components/parsers/qs','nolimit','filter','fieldName','order','merge','findOne','filters','offset','length','catch','include','then','stack','params','rows','status','VIRTUAL','lodash','name','VtigerField','limit','type','index','undefined','destroy','pick','json','count','findAll','../../mysqldb','create','sort','attributes','keys','where'];(function(_0x448189,_0x1dce7d){const _0x17ef23=function(_0x13f654){while(--_0x13f654){_0x448189['push'](_0x448189['shift']());}};_0x17ef23(++_0x1dce7d);}(a329_0x1dce,0x11a));const a329_0x17ef=function(_0x448189,_0x1dce7d){_0x448189=_0x448189-0x0;let _0x17ef23=a329_0x1dce[_0x448189];return _0x17ef23;};const _0x51d99f=a329_0x17ef;'use strict';const _=require(_0x51d99f('0x6')),qs=require(_0x51d99f('0x27')),logger=require('../../config/logger')('api'),db=require(_0x51d99f('0x12'))['db'],{Op}=require(_0x51d99f('0x26'));function respondWithResult(_0x13f654,_0x1fe011){return _0x1fe011=_0x1fe011||0xc8,function(_0x227beb){const _0x111e34=a329_0x17ef;if(_0x227beb)return _0x13f654[_0x111e34('0x4')](_0x1fe011)[_0x111e34('0xf')](_0x227beb);};}function respondWithFilteredResult(_0x3416ee,_0x2493e2){return function(_0x170c7e){const _0x562420=a329_0x17ef;if(_0x170c7e){const _0x42d3c4=_0x170c7e['count'],_0x2a075a=_0x2493e2[_0x562420('0x2f')];let _0x42f0d8=_0x2493e2[_0x562420('0x2f')]+_0x2493e2['limit'],_0x49952c;return _0x42f0d8>=_0x42d3c4?(_0x42f0d8=_0x42d3c4,_0x49952c=0xc8):_0x49952c=0xce,_0x3416ee[_0x562420('0x4')](_0x49952c),_0x3416ee['set'](_0x562420('0x1f'),_0x2a075a+'-'+_0x42f0d8+'/'+_0x42d3c4)[_0x562420('0xf')](_0x170c7e);}return null;};}function saveUpdates(_0x245267){return function(_0x2bc8b5){const _0xf1a90e=a329_0x17ef;if(_0x2bc8b5)return _0x2bc8b5[_0xf1a90e('0x1b')](_0x245267)['then'](function(_0x424fab){return _0x424fab;});return null;};}function removeEntity(_0x3bcc03){return function(_0x30464e){const _0x5b748f=a329_0x17ef;if(_0x30464e)return _0x30464e[_0x5b748f('0xd')]()[_0x5b748f('0x0')](function(){const _0x5836aa=_0x5b748f;_0x3bcc03['status'](0xcc)[_0x5836aa('0x1d')]();});};}function handleEntityNotFound(_0x4236e5){return function(_0x309475){const _0x1a1891=a329_0x17ef;return!_0x309475&&_0x4236e5[_0x1a1891('0x24')](0x194),_0x309475;};}function handleError(_0x4d6cd0,_0x561dc9){return _0x561dc9=_0x561dc9||0x1f4,function(_0x3e0aa1){const _0x105c53=a329_0x17ef;logger['error'](_0x3e0aa1[_0x105c53('0x1')]),_0x3e0aa1[_0x105c53('0x7')]&&delete _0x3e0aa1[_0x105c53('0x7')],_0x4d6cd0[_0x105c53('0x4')](_0x561dc9)['send'](_0x3e0aa1);};}exports[_0x51d99f('0xb')]=function(_0x14aece,_0x3406ba){const _0x1adab1=_0x51d99f;let _0x538a03={};const _0x4bc299={},_0x56040e={'count':0x0,'rows':[]},_0xe2f225=_[_0x1adab1('0x25')](db['VtigerField'][_0x1adab1('0x1a')],function(_0x429da2){const _0x22fa97=_0x1adab1;return{'name':_0x429da2[_0x22fa97('0x2a')],'type':_0x429da2[_0x22fa97('0xa')]['key']};});_0x4bc299[_0x1adab1('0x21')]=_[_0x1adab1('0x25')](_0xe2f225,_0x1adab1('0x7')),_0x4bc299['query']=_[_0x1adab1('0x16')](_0x14aece[_0x1adab1('0x22')]),_0x4bc299[_0x1adab1('0x2e')]=_[_0x1adab1('0x20')](_0x4bc299[_0x1adab1('0x21')],_0x4bc299[_0x1adab1('0x22')]),_0x538a03['attributes']=_[_0x1adab1('0x20')](_0x4bc299[_0x1adab1('0x21')],qs[_0x1adab1('0x1c')](_0x14aece['query']['fields'])),_0x538a03[_0x1adab1('0x15')]=_0x538a03['attributes'][_0x1adab1('0x30')]?_0x538a03[_0x1adab1('0x15')]:_0x4bc299[_0x1adab1('0x21')];typeof _0x14aece[_0x1adab1('0x22')][_0x1adab1('0x28')]===_0x1adab1('0xc')&&(_0x538a03[_0x1adab1('0x9')]=qs['limit'](_0x14aece[_0x1adab1('0x22')][_0x1adab1('0x9')]),_0x538a03[_0x1adab1('0x2f')]=qs[_0x1adab1('0x2f')](_0x14aece[_0x1adab1('0x22')]['offset']));_0x538a03[_0x1adab1('0x2b')]=qs[_0x1adab1('0x14')](_0x14aece[_0x1adab1('0x22')][_0x1adab1('0x14')]),_0x538a03['where']=qs['filters'](_[_0x1adab1('0xe')](_0x14aece[_0x1adab1('0x22')],_0x4bc299[_0x1adab1('0x2e')]),_0xe2f225);_0x14aece[_0x1adab1('0x22')][_0x1adab1('0x29')]&&(_0x538a03[_0x1adab1('0x17')]=_[_0x1adab1('0x2c')](_0x538a03[_0x1adab1('0x17')],{[Op['or']]:_[_0x1adab1('0x25')](_0xe2f225,function(_0x245957){const _0x2095bf=_0x1adab1;if(_0x245957[_0x2095bf('0xa')]!==_0x2095bf('0x5')){const _0x7aed13={};return _0x7aed13[_0x245957[_0x2095bf('0x7')]]={[Op[_0x2095bf('0x23')]]:'%'+_0x14aece['query'][_0x2095bf('0x29')]+'%'},_0x7aed13;}})}));_0x538a03=_['merge']({},_0x538a03,_0x14aece['options']);const _0xcb32b7={'where':_0x538a03[_0x1adab1('0x17')]};return db[_0x1adab1('0x8')][_0x1adab1('0x10')](_0xcb32b7)['then'](function(_0x3cc3f4){const _0x40e5c6=_0x1adab1;return _0x56040e[_0x40e5c6('0x10')]=_0x3cc3f4,_0x14aece[_0x40e5c6('0x22')][_0x40e5c6('0x1e')]&&(_0x538a03[_0x40e5c6('0x32')]=[{'all':!![]}]),db[_0x40e5c6('0x8')][_0x40e5c6('0x11')](_0x538a03);})[_0x1adab1('0x0')](function(_0x3de1ad){const _0x2ba9dc=_0x1adab1;return _0x56040e[_0x2ba9dc('0x3')]=_0x3de1ad,_0x56040e;})['then'](respondWithFilteredResult(_0x3406ba,_0x538a03))[_0x1adab1('0x31')](handleError(_0x3406ba,null));},exports['show']=function(_0x4398ff,_0x49f172){const _0x4da874=_0x51d99f;let _0x1483c6={'raw':!![],'where':{'id':_0x4398ff['params']['id']}};const _0x1f9d13={};return _0x1f9d13[_0x4da874('0x21')]=_[_0x4da874('0x16')](db[_0x4da874('0x8')][_0x4da874('0x1a')]),_0x1f9d13[_0x4da874('0x22')]=_[_0x4da874('0x16')](_0x4398ff[_0x4da874('0x22')]),_0x1f9d13[_0x4da874('0x2e')]=_['intersection'](_0x1f9d13[_0x4da874('0x21')],_0x1f9d13[_0x4da874('0x22')]),_0x1483c6['attributes']=_[_0x4da874('0x20')](_0x1f9d13[_0x4da874('0x21')],qs[_0x4da874('0x1c')](_0x4398ff[_0x4da874('0x22')][_0x4da874('0x1c')])),_0x1483c6['attributes']=_0x1483c6[_0x4da874('0x15')]['length']?_0x1483c6['attributes']:_0x1f9d13[_0x4da874('0x21')],_0x4398ff[_0x4da874('0x22')][_0x4da874('0x1e')]&&(_0x1483c6[_0x4da874('0x32')]=[{'all':!![]}]),_0x1483c6=_['merge']({},_0x1483c6,_0x4398ff[_0x4da874('0x18')]),db[_0x4da874('0x8')][_0x4da874('0x2d')](_0x1483c6)[_0x4da874('0x0')](handleEntityNotFound(_0x49f172,null))[_0x4da874('0x0')](respondWithResult(_0x49f172,null))['catch'](handleError(_0x49f172,null));},exports[_0x51d99f('0x13')]=function(_0x4eddcd,_0x332ac4){const _0x25c305=_0x51d99f;return db[_0x25c305('0x8')][_0x25c305('0x13')](_0x4eddcd[_0x25c305('0x19')],{})[_0x25c305('0x0')](respondWithResult(_0x332ac4,0xc9))[_0x25c305('0x31')](handleError(_0x332ac4,null));},exports[_0x51d99f('0x1b')]=function(_0x2ffc53,_0x2a5633){const _0x382924=_0x51d99f;return _0x2ffc53[_0x382924('0x19')]['id']&&delete _0x2ffc53[_0x382924('0x19')]['id'],db[_0x382924('0x8')][_0x382924('0x2d')]({'where':{'id':_0x2ffc53[_0x382924('0x2')]['id']}})[_0x382924('0x0')](handleEntityNotFound(_0x2a5633,null))[_0x382924('0x0')](saveUpdates(_0x2ffc53['body'],null))['then'](respondWithResult(_0x2a5633,null))[_0x382924('0x31')](handleError(_0x2a5633,null));},exports[_0x51d99f('0xd')]=function(_0x5532f5,_0x3ba697){const _0x54cdbf=_0x51d99f;return db[_0x54cdbf('0x8')][_0x54cdbf('0x2d')]({'where':{'id':_0x5532f5[_0x54cdbf('0x2')]['id']}})['then'](handleEntityNotFound(_0x3ba697,null))[_0x54cdbf('0x0')](removeEntity(_0x3ba697,null))[_0x54cdbf('0x31')](handleError(_0x3ba697,null));}; \ No newline at end of file +const a329_0x1a75=['type','../../components/parsers/qs','map','nolimit','query','fields','findAll','keys','Content-Range','stack','then','lodash','attributes','params','includeAll','name','filters','model','catch','intersection','key','create','set','status','index','body','like','update','pick','json','api','rows','findOne','../../config/logger','count','merge','include','destroy','fieldName','send','length','sequelize','order','rawAttributes','undefined','VtigerField','sort','show','where','offset'];(function(_0x4aa1a2,_0x1a7557){const _0x5f0b79=function(_0xd17f7a){while(--_0xd17f7a){_0x4aa1a2['push'](_0x4aa1a2['shift']());}};_0x5f0b79(++_0x1a7557);}(a329_0x1a75,0xea));const a329_0x5f0b=function(_0x4aa1a2,_0x1a7557){_0x4aa1a2=_0x4aa1a2-0x0;let _0x5f0b79=a329_0x1a75[_0x4aa1a2];return _0x5f0b79;};const _0x2e30d0=a329_0x5f0b;'use strict';const _=require(_0x2e30d0('0x1b')),qs=require(_0x2e30d0('0x11')),logger=require(_0x2e30d0('0x31'))(_0x2e30d0('0x2e')),db=require('../../mysqldb')['db'],{Op}=require(_0x2e30d0('0x7'));function respondWithResult(_0xd17f7a,_0x37f1d9){return _0x37f1d9=_0x37f1d9||0xc8,function(_0x474e41){const _0x5c6f23=a329_0x5f0b;if(_0x474e41)return _0xd17f7a[_0x5c6f23('0x27')](_0x37f1d9)['json'](_0x474e41);};}function respondWithFilteredResult(_0x1f36a3,_0x3d5107){return function(_0x3dcd10){const _0xa0c40c=a329_0x5f0b;if(_0x3dcd10){const _0x2c901d=_0x3dcd10[_0xa0c40c('0x0')],_0x8590e2=_0x3d5107[_0xa0c40c('0xf')];let _0x4790be=_0x3d5107[_0xa0c40c('0xf')]+_0x3d5107['limit'],_0x4d971a;return _0x4790be>=_0x2c901d?(_0x4790be=_0x2c901d,_0x4d971a=0xc8):_0x4d971a=0xce,_0x1f36a3['status'](_0x4d971a),_0x1f36a3[_0xa0c40c('0x26')](_0xa0c40c('0x18'),_0x8590e2+'-'+_0x4790be+'/'+_0x2c901d)[_0xa0c40c('0x2d')](_0x3dcd10);}return null;};}function saveUpdates(_0x4b752f){return function(_0x347412){const _0x352502=a329_0x5f0b;if(_0x347412)return _0x347412[_0x352502('0x2b')](_0x4b752f)[_0x352502('0x1a')](function(_0x2223a6){return _0x2223a6;});return null;};}function removeEntity(_0x2b2de9){return function(_0x273902){const _0x17e1d1=a329_0x5f0b;if(_0x273902)return _0x273902[_0x17e1d1('0x3')]()[_0x17e1d1('0x1a')](function(){const _0x469a4d=_0x17e1d1;_0x2b2de9[_0x469a4d('0x27')](0xcc)['end']();});};}function handleEntityNotFound(_0xa7c28f){return function(_0x1548ae){return!_0x1548ae&&_0xa7c28f['sendStatus'](0x194),_0x1548ae;};}function handleError(_0x142f2c,_0x69c06a){return _0x69c06a=_0x69c06a||0x1f4,function(_0x17529c){const _0x110335=a329_0x5f0b;logger['error'](_0x17529c[_0x110335('0x19')]),_0x17529c[_0x110335('0x1f')]&&delete _0x17529c[_0x110335('0x1f')],_0x142f2c['status'](_0x69c06a)[_0x110335('0x5')](_0x17529c);};}exports[_0x2e30d0('0x28')]=function(_0x145c88,_0x2f72d1){const _0x1fdaa7=_0x2e30d0;let _0x48b975={};const _0x48d79a={},_0x4f6266={'count':0x0,'rows':[]},_0x13b18d=_[_0x1fdaa7('0x12')](db['VtigerField'][_0x1fdaa7('0x9')],function(_0x2c89e1){const _0x96a206=_0x1fdaa7;return{'name':_0x2c89e1[_0x96a206('0x4')],'type':_0x2c89e1[_0x96a206('0x10')][_0x96a206('0x24')]};});_0x48d79a['model']=_[_0x1fdaa7('0x12')](_0x13b18d,_0x1fdaa7('0x1f')),_0x48d79a[_0x1fdaa7('0x14')]=_[_0x1fdaa7('0x17')](_0x145c88[_0x1fdaa7('0x14')]),_0x48d79a[_0x1fdaa7('0x20')]=_[_0x1fdaa7('0x23')](_0x48d79a[_0x1fdaa7('0x21')],_0x48d79a[_0x1fdaa7('0x14')]),_0x48b975[_0x1fdaa7('0x1c')]=_[_0x1fdaa7('0x23')](_0x48d79a['model'],qs['fields'](_0x145c88[_0x1fdaa7('0x14')]['fields'])),_0x48b975[_0x1fdaa7('0x1c')]=_0x48b975['attributes'][_0x1fdaa7('0x6')]?_0x48b975[_0x1fdaa7('0x1c')]:_0x48d79a['model'];typeof _0x145c88['query'][_0x1fdaa7('0x13')]===_0x1fdaa7('0xa')&&(_0x48b975['limit']=qs['limit'](_0x145c88[_0x1fdaa7('0x14')]['limit']),_0x48b975[_0x1fdaa7('0xf')]=qs['offset'](_0x145c88['query'][_0x1fdaa7('0xf')]));_0x48b975[_0x1fdaa7('0x8')]=qs[_0x1fdaa7('0xc')](_0x145c88[_0x1fdaa7('0x14')][_0x1fdaa7('0xc')]),_0x48b975['where']=qs[_0x1fdaa7('0x20')](_[_0x1fdaa7('0x2c')](_0x145c88[_0x1fdaa7('0x14')],_0x48d79a[_0x1fdaa7('0x20')]),_0x13b18d);_0x145c88[_0x1fdaa7('0x14')]['filter']&&(_0x48b975[_0x1fdaa7('0xe')]=_[_0x1fdaa7('0x1')](_0x48b975[_0x1fdaa7('0xe')],{[Op['or']]:_[_0x1fdaa7('0x12')](_0x13b18d,function(_0x350925){const _0x503196=_0x1fdaa7;if(_0x350925[_0x503196('0x10')]!=='VIRTUAL'){const _0x5b2310={};return _0x5b2310[_0x350925[_0x503196('0x1f')]]={[Op[_0x503196('0x2a')]]:'%'+_0x145c88[_0x503196('0x14')]['filter']+'%'},_0x5b2310;}})}));_0x48b975=_[_0x1fdaa7('0x1')]({},_0x48b975,_0x145c88['options']);const _0x49181e={'where':_0x48b975[_0x1fdaa7('0xe')]};return db[_0x1fdaa7('0xb')][_0x1fdaa7('0x0')](_0x49181e)[_0x1fdaa7('0x1a')](function(_0x543d77){const _0x3b5079=_0x1fdaa7;return _0x4f6266[_0x3b5079('0x0')]=_0x543d77,_0x145c88[_0x3b5079('0x14')][_0x3b5079('0x1e')]&&(_0x48b975[_0x3b5079('0x2')]=[{'all':!![]}]),db['VtigerField'][_0x3b5079('0x16')](_0x48b975);})[_0x1fdaa7('0x1a')](function(_0xd2ca39){const _0x4be09e=_0x1fdaa7;return _0x4f6266[_0x4be09e('0x2f')]=_0xd2ca39,_0x4f6266;})[_0x1fdaa7('0x1a')](respondWithFilteredResult(_0x2f72d1,_0x48b975))[_0x1fdaa7('0x22')](handleError(_0x2f72d1,null));},exports[_0x2e30d0('0xd')]=function(_0x29c0d0,_0x24b42b){const _0x6ed267=_0x2e30d0;let _0x2f7a9b={'raw':!![],'where':{'id':_0x29c0d0['params']['id']}};const _0x4278ec={};return _0x4278ec[_0x6ed267('0x21')]=_[_0x6ed267('0x17')](db[_0x6ed267('0xb')][_0x6ed267('0x9')]),_0x4278ec[_0x6ed267('0x14')]=_[_0x6ed267('0x17')](_0x29c0d0[_0x6ed267('0x14')]),_0x4278ec[_0x6ed267('0x20')]=_[_0x6ed267('0x23')](_0x4278ec[_0x6ed267('0x21')],_0x4278ec[_0x6ed267('0x14')]),_0x2f7a9b[_0x6ed267('0x1c')]=_[_0x6ed267('0x23')](_0x4278ec['model'],qs['fields'](_0x29c0d0[_0x6ed267('0x14')][_0x6ed267('0x15')])),_0x2f7a9b[_0x6ed267('0x1c')]=_0x2f7a9b['attributes'][_0x6ed267('0x6')]?_0x2f7a9b[_0x6ed267('0x1c')]:_0x4278ec[_0x6ed267('0x21')],_0x29c0d0[_0x6ed267('0x14')]['includeAll']&&(_0x2f7a9b['include']=[{'all':!![]}]),_0x2f7a9b=_[_0x6ed267('0x1')]({},_0x2f7a9b,_0x29c0d0['options']),db[_0x6ed267('0xb')][_0x6ed267('0x30')](_0x2f7a9b)['then'](handleEntityNotFound(_0x24b42b,null))[_0x6ed267('0x1a')](respondWithResult(_0x24b42b,null))['catch'](handleError(_0x24b42b,null));},exports[_0x2e30d0('0x25')]=function(_0x1e898d,_0x463a40){const _0x3c117b=_0x2e30d0;return db[_0x3c117b('0xb')][_0x3c117b('0x25')](_0x1e898d[_0x3c117b('0x29')],{})[_0x3c117b('0x1a')](respondWithResult(_0x463a40,0xc9))[_0x3c117b('0x22')](handleError(_0x463a40,null));},exports[_0x2e30d0('0x2b')]=function(_0x57d719,_0x19cb1c){const _0x4f9f33=_0x2e30d0;return _0x57d719[_0x4f9f33('0x29')]['id']&&delete _0x57d719['body']['id'],db[_0x4f9f33('0xb')][_0x4f9f33('0x30')]({'where':{'id':_0x57d719['params']['id']}})['then'](handleEntityNotFound(_0x19cb1c,null))[_0x4f9f33('0x1a')](saveUpdates(_0x57d719[_0x4f9f33('0x29')],null))[_0x4f9f33('0x1a')](respondWithResult(_0x19cb1c,null))['catch'](handleError(_0x19cb1c,null));},exports[_0x2e30d0('0x3')]=function(_0x4ab66e,_0x168195){const _0x1266b3=_0x2e30d0;return db[_0x1266b3('0xb')][_0x1266b3('0x30')]({'where':{'id':_0x4ab66e[_0x1266b3('0x1d')]['id']}})[_0x1266b3('0x1a')](handleEntityNotFound(_0x168195,null))[_0x1266b3('0x1a')](removeEntity(_0x168195,null))['catch'](handleError(_0x168195,null));}; \ No newline at end of file diff --git a/server/api/intVtigerField/intVtigerField.model.js b/server/api/intVtigerField/intVtigerField.model.js index 6da8fbb..430d38d 100644 --- a/server/api/intVtigerField/intVtigerField.model.js +++ b/server/api/intVtigerField/intVtigerField.model.js @@ -1 +1 @@ -const a330_0x1a96=['vtiger_unique_index','idField','./intVtigerField.attributes','exports','VtigerField'];(function(_0x49e793,_0x1a965f){const _0x521312=function(_0xb3f011){while(--_0xb3f011){_0x49e793['push'](_0x49e793['shift']());}};_0x521312(++_0x1a965f);}(a330_0x1a96,0x1a3));const a330_0x5213=function(_0x49e793,_0x1a965f){_0x49e793=_0x49e793-0x0;let _0x521312=a330_0x1a96[_0x49e793];return _0x521312;};const _0x170cf8=a330_0x5213;'use strict';const attributes=require(_0x170cf8('0x3'));module[_0x170cf8('0x4')]=function(_0xb3f011){const _0xcd1c16=_0x170cf8,_0x93176b=_0xb3f011['define'](_0xcd1c16('0x0'),attributes,{'tableName':'int_vtiger_fields','paranoid':![],'indexes':[{'name':_0xcd1c16('0x1'),'fields':[_0xcd1c16('0x2'),'FieldId'],'unique':!![]}],'timestamps':!![]});return _0x93176b;}; \ No newline at end of file +const a330_0x3f3b=['exports','FieldId','define','idField','vtiger_unique_index','int_vtiger_fields'];(function(_0x948566,_0x3f3b40){const _0x4741b3=function(_0x5d4d06){while(--_0x5d4d06){_0x948566['push'](_0x948566['shift']());}};_0x4741b3(++_0x3f3b40);}(a330_0x3f3b,0x91));const a330_0x4741=function(_0x948566,_0x3f3b40){_0x948566=_0x948566-0x0;let _0x4741b3=a330_0x3f3b[_0x948566];return _0x4741b3;};const _0x89013e=a330_0x4741;'use strict';const attributes=require('./intVtigerField.attributes');module[_0x89013e('0x5')]=function(_0x5d4d06){const _0x4e0cc6=_0x89013e,_0x4deada=_0x5d4d06[_0x4e0cc6('0x1')]('VtigerField',attributes,{'tableName':_0x4e0cc6('0x4'),'paranoid':![],'indexes':[{'name':_0x4e0cc6('0x3'),'fields':[_0x4e0cc6('0x2'),_0x4e0cc6('0x0')],'unique':!![]}],'timestamps':!![]});return _0x4deada;}; \ No newline at end of file diff --git a/server/api/intZendeskAccount/index.js b/server/api/intZendeskAccount/index.js index b71187c..af4f0f6 100644 --- a/server/api/intZendeskAccount/index.js +++ b/server/api/intZendeskAccount/index.js @@ -1 +1 @@ -const a331_0x3739=['Router','getConfigurations','express','/:id/configurations','/:id','create','./intZendeskAccount.controller','get','exports','update','isAuthenticated','addConfiguration','post','/:id/fields','show','delete'];(function(_0x7ae555,_0x373993){const _0x12247=function(_0x1eb7b0){while(--_0x1eb7b0){_0x7ae555['push'](_0x7ae555['shift']());}};_0x12247(++_0x373993);}(a331_0x3739,0xb7));const a331_0x1224=function(_0x7ae555,_0x373993){_0x7ae555=_0x7ae555-0x0;let _0x12247=a331_0x3739[_0x7ae555];return _0x12247;};const _0x315d40=a331_0x1224;'use strict';const express=require(_0x315d40('0xb')),router=express[_0x315d40('0x9')](),auth=require('../../components/auth/service'),controller=require(_0x315d40('0xf'));router[_0x315d40('0x0')]('/',auth[_0x315d40('0x3')](),controller['index']),router[_0x315d40('0x0')](_0x315d40('0xd'),auth[_0x315d40('0x3')](),controller[_0x315d40('0x7')]),router[_0x315d40('0x0')](_0x315d40('0xc'),auth['isAuthenticated'](),controller[_0x315d40('0xa')]),router[_0x315d40('0x0')](_0x315d40('0x6'),auth[_0x315d40('0x3')](),controller['getFields']),router[_0x315d40('0x5')]('/',auth['isAuthenticated'](),controller[_0x315d40('0xe')]),router[_0x315d40('0x5')]('/:id/configurations',auth['isAuthenticated'](),controller[_0x315d40('0x4')]),router['put'](_0x315d40('0xd'),auth[_0x315d40('0x3')](),controller[_0x315d40('0x2')]),router[_0x315d40('0x8')](_0x315d40('0xd'),auth[_0x315d40('0x3')](),controller['destroy']),module[_0x315d40('0x1')]=router; \ No newline at end of file +const a331_0x33f0=['get','isAuthenticated','destroy','addConfiguration','exports','/:id/fields','getConfigurations','delete','express','Router','put','post','show','../../components/auth/service','/:id','index','/:id/configurations','create','getFields','./intZendeskAccount.controller'];(function(_0x447500,_0x33f01c){const _0x217563=function(_0x490c8d){while(--_0x490c8d){_0x447500['push'](_0x447500['shift']());}};_0x217563(++_0x33f01c);}(a331_0x33f0,0x149));const a331_0x2175=function(_0x447500,_0x33f01c){_0x447500=_0x447500-0x0;let _0x217563=a331_0x33f0[_0x447500];return _0x217563;};const _0x561c7b=a331_0x2175;'use strict';const express=require(_0x561c7b('0x13')),router=express[_0x561c7b('0x0')](),auth=require(_0x561c7b('0x4')),controller=require(_0x561c7b('0xa'));router[_0x561c7b('0xb')]('/',auth['isAuthenticated'](),controller[_0x561c7b('0x6')]),router[_0x561c7b('0xb')]('/:id',auth[_0x561c7b('0xc')](),controller[_0x561c7b('0x3')]),router[_0x561c7b('0xb')]('/:id/configurations',auth[_0x561c7b('0xc')](),controller[_0x561c7b('0x11')]),router[_0x561c7b('0xb')](_0x561c7b('0x10'),auth[_0x561c7b('0xc')](),controller[_0x561c7b('0x9')]),router['post']('/',auth[_0x561c7b('0xc')](),controller[_0x561c7b('0x8')]),router[_0x561c7b('0x2')](_0x561c7b('0x7'),auth[_0x561c7b('0xc')](),controller[_0x561c7b('0xe')]),router[_0x561c7b('0x1')](_0x561c7b('0x5'),auth[_0x561c7b('0xc')](),controller['update']),router[_0x561c7b('0x12')](_0x561c7b('0x5'),auth[_0x561c7b('0xc')](),controller[_0x561c7b('0xd')]),module[_0x561c7b('0xf')]=router; \ No newline at end of file diff --git a/server/api/intZendeskAccount/intZendeskAccount.attributes.js b/server/api/intZendeskAccount/intZendeskAccount.attributes.js index 0a7a51e..06b09e2 100644 --- a/server/api/intZendeskAccount/intZendeskAccount.attributes.js +++ b/server/api/intZendeskAccount/intZendeskAccount.attributes.js @@ -1 +1 @@ -const a332_0x2699=['integrationTab','remoteUri','password','ENUM','STRING','sequelize','token','newTab','username'];(function(_0xd657d6,_0x269985){const _0x56bed4=function(_0xb4883e){while(--_0xb4883e){_0xd657d6['push'](_0xd657d6['shift']());}};_0x56bed4(++_0x269985);}(a332_0x2699,0xdb));const a332_0x56be=function(_0xd657d6,_0x269985){_0xd657d6=_0xd657d6-0x0;let _0x56bed4=a332_0x2699[_0xd657d6];return _0x56bed4;};const _0x528a7f=a332_0x56be;'use strict';const Sequelize=require(_0x528a7f('0x2'));module['exports']={'name':{'type':Sequelize[_0x528a7f('0x1')]},'description':{'type':Sequelize[_0x528a7f('0x1')]},'username':{'type':Sequelize[_0x528a7f('0x1')],'unique':_0x528a7f('0x5')},'password':{'type':Sequelize[_0x528a7f('0x1')]},'token':{'type':Sequelize['STRING']},'remoteUri':{'type':Sequelize[_0x528a7f('0x1')],'unique':_0x528a7f('0x7')},'authType':{'type':Sequelize[_0x528a7f('0x0')](_0x528a7f('0x8'),_0x528a7f('0x3')),'defaultValue':_0x528a7f('0x8')},'serverUrl':{'type':Sequelize['STRING']},'type':{'type':Sequelize[_0x528a7f('0x0')](_0x528a7f('0x6'),_0x528a7f('0x4')),'defaultValue':'integrationTab'}}; \ No newline at end of file +const a332_0x13c0=['username','integrationTab','newTab','password','remoteUri','sequelize','token','ENUM','STRING'];(function(_0x312204,_0x13c0df){const _0x454788=function(_0x1122e6){while(--_0x1122e6){_0x312204['push'](_0x312204['shift']());}};_0x454788(++_0x13c0df);}(a332_0x13c0,0x1a3));const a332_0x4547=function(_0x312204,_0x13c0df){_0x312204=_0x312204-0x0;let _0x454788=a332_0x13c0[_0x312204];return _0x454788;};const _0x168c19=a332_0x4547;'use strict';const Sequelize=require(_0x168c19('0x0'));module['exports']={'name':{'type':Sequelize[_0x168c19('0x3')]},'description':{'type':Sequelize[_0x168c19('0x3')]},'username':{'type':Sequelize[_0x168c19('0x3')],'unique':_0x168c19('0x4')},'password':{'type':Sequelize[_0x168c19('0x3')]},'token':{'type':Sequelize[_0x168c19('0x3')]},'remoteUri':{'type':Sequelize[_0x168c19('0x3')],'unique':_0x168c19('0x8')},'authType':{'type':Sequelize[_0x168c19('0x2')]('password',_0x168c19('0x1')),'defaultValue':_0x168c19('0x7')},'serverUrl':{'type':Sequelize['STRING']},'type':{'type':Sequelize['ENUM'](_0x168c19('0x5'),_0x168c19('0x6')),'defaultValue':_0x168c19('0x5')}}; \ No newline at end of file diff --git a/server/api/intZendeskAccount/intZendeskAccount.controller.js b/server/api/intZendeskAccount/intZendeskAccount.controller.js index a4f36b5..ce1df59 100644 --- a/server/api/intZendeskAccount/intZendeskAccount.controller.js +++ b/server/api/intZendeskAccount/intZendeskAccount.controller.js @@ -1 +1 @@ -const a333_0x410b=['status','where','type','AccountId','destroy','map','system_field_options','Basic\x20%s','undefined','include','statusCode','format','username','sort','api','keys','length','findOne','fields','params','fieldName','key','includeAll','%s/%s','then','custom_field_options','%s/token:%s','addConfiguration','Unknown\x20authentication\x20type','findAll','../../components/integrations/configuration','channel','password','filter','GET','getFields','lodash','query','title','getConfigurations','token','intersection','index','ZendeskConfiguration','error','ZendeskAccount','VIRTUAL','Subjects','create','limit','from','ZendeskField','sendStatus','base64','rows','model','rawAttributes','update','%s:%s','catch','remove','authType','request-promise-native','util','toString','subject','../../config/logger','Content-Range','name','body','group','attributes','order','description','count','send','assignee','json','Descriptions','offset','filters','../../components/parsers/qs','end','headers','pick','merge','ticket_fields','show','sequelize','stringify','nolimit','test'];(function(_0x4b163f,_0x410baa){const _0x4ef522=function(_0x20de5b){while(--_0x20de5b){_0x4b163f['push'](_0x4b163f['shift']());}};_0x4ef522(++_0x410baa);}(a333_0x410b,0x1d1));const a333_0x4ef5=function(_0x4b163f,_0x410baa){_0x4b163f=_0x4b163f-0x0;let _0x4ef522=a333_0x410b[_0x4b163f];return _0x4ef522;};const _0x216396=a333_0x4ef5;'use strict';const rp=require(_0x216396('0x39')),util=require(_0x216396('0x3a')),_=require(_0x216396('0x1f')),qs=require(_0x216396('0x4c')),logger=require(_0x216396('0x3d'))(_0x216396('0x9')),db=require('../../mysqldb')['db'],{Op,ValidationError}=require(_0x216396('0x53')),integrations=require(_0x216396('0x19'));function respondWithResult(_0x20de5b,_0x5d60c1){return _0x5d60c1=_0x5d60c1||0xc8,function(_0x431508){const _0x273579=a333_0x4ef5;if(_0x431508)return _0x20de5b['status'](_0x5d60c1)[_0x273579('0x48')](_0x431508);};}function respondWithFilteredResult(_0x2b8bb1,_0x288501){return function(_0x43a490){const _0x55d812=a333_0x4ef5;if(_0x43a490){const _0x1ebe55=_0x43a490[_0x55d812('0x45')],_0x444a85=_0x288501[_0x55d812('0x4a')];let _0x2ca79a=_0x288501[_0x55d812('0x4a')]+_0x288501[_0x55d812('0x2c')],_0x5a2264;return _0x2ca79a>=_0x1ebe55?(_0x2ca79a=_0x1ebe55,_0x5a2264=0xc8):_0x5a2264=0xce,_0x2b8bb1['status'](_0x5a2264),_0x2b8bb1['set'](_0x55d812('0x3e'),_0x444a85+'-'+_0x2ca79a+'/'+_0x1ebe55)[_0x55d812('0x48')](_0x43a490);}return null;};}function saveUpdates(_0x4e3aae){return function(_0x1f1da6){const _0x2cc303=a333_0x4ef5;if(_0x1f1da6)return _0x1f1da6[_0x2cc303('0x34')](_0x4e3aae)['then'](function(_0x20a069){return _0x20a069;});return null;};}function removeEntity(_0x2b3326){return function(_0x5413ed){const _0x1aa2dd=a333_0x4ef5;if(_0x5413ed)return _0x5413ed[_0x1aa2dd('0x5b')]()[_0x1aa2dd('0x13')](function(){const _0x1bfcd0=_0x1aa2dd;_0x2b3326[_0x1bfcd0('0x57')](0xcc)[_0x1bfcd0('0x4d')]();});};}function handleEntityNotFound(_0x359c48){return function(_0x5768e2){const _0x5c52f9=a333_0x4ef5;return!_0x5768e2&&_0x359c48[_0x5c52f9('0x2f')](0x194),_0x5768e2;};}function handleError(_0x146829,_0x1fda91){return _0x1fda91=_0x1fda91||0x1f4,function(_0x169891){const _0x3ab296=a333_0x4ef5;logger[_0x3ab296('0x27')](_0x169891['stack']),_0x169891[_0x3ab296('0x3f')]&&delete _0x169891[_0x3ab296('0x3f')],_0x146829[_0x3ab296('0x57')](_0x1fda91)[_0x3ab296('0x46')](_0x169891);};}exports[_0x216396('0x25')]=function(_0x4eed21,_0x1853ac){const _0x14bf55=_0x216396;let _0x55203a={};const _0x546c95={},_0x596298={'count':0x0,'rows':[]},_0xfcd3ae=_[_0x14bf55('0x0')](db[_0x14bf55('0x28')][_0x14bf55('0x33')],function(_0x4cecd6){const _0x4308eb=_0x14bf55;return{'name':_0x4cecd6[_0x4308eb('0xf')],'type':_0x4cecd6[_0x4308eb('0x59')][_0x4308eb('0x10')]};});_0x546c95[_0x14bf55('0x32')]=_['map'](_0xfcd3ae,_0x14bf55('0x3f')),_0x546c95['query']=_[_0x14bf55('0xa')](_0x4eed21[_0x14bf55('0x20')]),_0x546c95[_0x14bf55('0x4b')]=_['intersection'](_0x546c95[_0x14bf55('0x32')],_0x546c95[_0x14bf55('0x20')]),_0x55203a['attributes']=_[_0x14bf55('0x24')](_0x546c95[_0x14bf55('0x32')],qs[_0x14bf55('0xd')](_0x4eed21[_0x14bf55('0x20')]['fields'])),_0x55203a['attributes']=_0x55203a[_0x14bf55('0x42')][_0x14bf55('0xb')]?_0x55203a[_0x14bf55('0x42')]:_0x546c95[_0x14bf55('0x32')];typeof _0x4eed21[_0x14bf55('0x20')][_0x14bf55('0x55')]===_0x14bf55('0x3')&&(_0x55203a[_0x14bf55('0x2c')]=qs[_0x14bf55('0x2c')](_0x4eed21[_0x14bf55('0x20')]['limit']),_0x55203a[_0x14bf55('0x4a')]=qs['offset'](_0x4eed21[_0x14bf55('0x20')][_0x14bf55('0x4a')]));_0x55203a[_0x14bf55('0x43')]=qs[_0x14bf55('0x8')](_0x4eed21[_0x14bf55('0x20')][_0x14bf55('0x8')]),_0x55203a[_0x14bf55('0x58')]=qs[_0x14bf55('0x4b')](_[_0x14bf55('0x4f')](_0x4eed21[_0x14bf55('0x20')],_0x546c95[_0x14bf55('0x4b')]),_0xfcd3ae);_0x4eed21[_0x14bf55('0x20')][_0x14bf55('0x1c')]&&(_0x55203a[_0x14bf55('0x58')]=_[_0x14bf55('0x50')](_0x55203a['where'],{[Op['or']]:_[_0x14bf55('0x0')](_0xfcd3ae,function(_0x1227f5){const _0x335ad4=_0x14bf55;if(_0x1227f5[_0x335ad4('0x59')]!==_0x335ad4('0x29')){const _0x5ce0ca={};return _0x5ce0ca[_0x1227f5[_0x335ad4('0x3f')]]={[Op['like']]:'%'+_0x4eed21['query'][_0x335ad4('0x1c')]+'%'},_0x5ce0ca;}})}));_0x55203a=_[_0x14bf55('0x50')]({},_0x55203a,_0x4eed21['options']);const _0x4578eb={'where':_0x55203a[_0x14bf55('0x58')]};return db[_0x14bf55('0x28')][_0x14bf55('0x45')](_0x4578eb)['then'](function(_0x349afe){const _0x14b779=_0x14bf55;return _0x596298[_0x14b779('0x45')]=_0x349afe,_0x4eed21[_0x14b779('0x20')][_0x14b779('0x11')]&&(_0x55203a[_0x14b779('0x4')]=[{'all':!![]}]),db[_0x14b779('0x28')][_0x14b779('0x18')](_0x55203a);})[_0x14bf55('0x13')](function(_0x98accd){const _0x14715e=_0x14bf55;return _0x596298[_0x14715e('0x31')]=_0x98accd,_0x596298;})['then'](respondWithFilteredResult(_0x1853ac,_0x55203a))['catch'](handleError(_0x1853ac,null));},exports[_0x216396('0x52')]=function(_0x2da7a7,_0x12f8a4){const _0x58e3f7=_0x216396;let _0x1ca3a9={'raw':![],'where':{'id':_0x2da7a7[_0x58e3f7('0xe')]['id']}};const _0x2ca73e={};return _0x2ca73e[_0x58e3f7('0x32')]=_['keys'](db[_0x58e3f7('0x28')]['rawAttributes']),_0x2ca73e[_0x58e3f7('0x20')]=_[_0x58e3f7('0xa')](_0x2da7a7[_0x58e3f7('0x20')]),_0x2ca73e['filters']=_[_0x58e3f7('0x24')](_0x2ca73e['model'],_0x2ca73e[_0x58e3f7('0x20')]),_0x1ca3a9[_0x58e3f7('0x42')]=_[_0x58e3f7('0x24')](_0x2ca73e[_0x58e3f7('0x32')],qs[_0x58e3f7('0xd')](_0x2da7a7[_0x58e3f7('0x20')]['fields'])),_0x1ca3a9['attributes']=_0x1ca3a9[_0x58e3f7('0x42')][_0x58e3f7('0xb')]?_0x1ca3a9[_0x58e3f7('0x42')]:_0x2ca73e[_0x58e3f7('0x32')],_0x2da7a7['query'][_0x58e3f7('0x11')]&&(_0x1ca3a9[_0x58e3f7('0x4')]=[{'all':!![]}]),_0x1ca3a9=_['merge']({},_0x1ca3a9,_0x2da7a7['options']),db[_0x58e3f7('0x28')]['findOne'](_0x1ca3a9)[_0x58e3f7('0x13')](handleEntityNotFound(_0x12f8a4,null))[_0x58e3f7('0x13')](respondWithResult(_0x12f8a4,null))[_0x58e3f7('0x36')](handleError(_0x12f8a4,null));},exports[_0x216396('0x2b')]=function(_0x292f11,_0x7e574d){const _0x8b11cc=_0x216396;return db[_0x8b11cc('0x28')]['create'](_0x292f11[_0x8b11cc('0x40')],{})[_0x8b11cc('0x13')](respondWithResult(_0x7e574d,0xc9))[_0x8b11cc('0x36')](handleError(_0x7e574d,null));},exports[_0x216396('0x34')]=function(_0x2454be,_0x2a6b7f){const _0x5350e5=_0x216396;return _0x2454be[_0x5350e5('0x40')]['id']&&delete _0x2454be[_0x5350e5('0x40')]['id'],db['ZendeskAccount'][_0x5350e5('0xc')]({'where':{'id':_0x2454be[_0x5350e5('0xe')]['id']}})[_0x5350e5('0x13')](handleEntityNotFound(_0x2a6b7f,null))['then'](saveUpdates(_0x2454be[_0x5350e5('0x40')],null))[_0x5350e5('0x13')](respondWithResult(_0x2a6b7f,null))[_0x5350e5('0x36')](handleError(_0x2a6b7f,null));},exports[_0x216396('0x5b')]=function(_0x585542,_0x4f7180){const _0x1548f3=_0x216396;return db['ZendeskAccount']['findOne']({'where':{'id':_0x585542[_0x1548f3('0xe')]['id']}})[_0x1548f3('0x13')](handleEntityNotFound(_0x4f7180,null))[_0x1548f3('0x13')](removeEntity(_0x4f7180,null))[_0x1548f3('0x36')](handleError(_0x4f7180,null));},exports['getConfigurations']=function(_0x12c17d,_0x8edc67){const _0x3e08a3=_0x216396;let _0x5c837a={};const _0x35047b={};let _0x51566b,_0x1ea5a9;return db[_0x3e08a3('0x28')][_0x3e08a3('0xc')]({'where':{'id':_0x12c17d['params']['id']}})[_0x3e08a3('0x13')](handleEntityNotFound(_0x8edc67,null))[_0x3e08a3('0x13')](function(_0x352774){const _0x216452=_0x3e08a3;if(_0x352774)return _0x51566b=_0x352774,_0x35047b['model']=_[_0x216452('0xa')](db[_0x216452('0x26')][_0x216452('0x33')]),_0x35047b[_0x216452('0x20')]=_[_0x216452('0xa')](_0x12c17d[_0x216452('0x20')]),_0x35047b['filters']=_[_0x216452('0x24')](_0x35047b[_0x216452('0x32')],_0x35047b[_0x216452('0x20')]),_0x5c837a[_0x216452('0x42')]=_[_0x216452('0x24')](_0x35047b[_0x216452('0x32')],qs[_0x216452('0xd')](_0x12c17d[_0x216452('0x20')][_0x216452('0xd')])),_0x5c837a[_0x216452('0x42')]=_0x5c837a[_0x216452('0x42')][_0x216452('0xb')]?_0x5c837a['attributes']:_0x35047b[_0x216452('0x32')],_0x5c837a['order']=qs['sort'](_0x12c17d[_0x216452('0x20')][_0x216452('0x8')]),_0x5c837a[_0x216452('0x58')]=qs[_0x216452('0x4b')](_[_0x216452('0x4f')](_0x12c17d[_0x216452('0x20')],_0x35047b['filters'])),_0x12c17d[_0x216452('0x20')][_0x216452('0x1c')]&&(_0x5c837a[_0x216452('0x58')]=_[_0x216452('0x50')](_0x5c837a[_0x216452('0x58')],{[Op['or']]:_[_0x216452('0x0')](_0x5c837a[_0x216452('0x42')],function(_0x183e45){const _0x2714b5=_0x216452,_0x230db6={};return _0x230db6[_0x183e45]={[Op['like']]:'%'+_0x12c17d[_0x2714b5('0x20')]['filter']+'%'},_0x230db6;})})),_0x5c837a=_[_0x216452('0x50')]({},_0x5c837a,_0x12c17d['options']),_0x51566b[_0x216452('0x22')](_0x5c837a);})['then'](function(_0x19eaf5){const _0x2b0af7=_0x3e08a3;if(_0x19eaf5)return _0x1ea5a9=_0x19eaf5['length'],typeof _0x12c17d['query'][_0x2b0af7('0x55')]===_0x2b0af7('0x3')&&(_0x5c837a['limit']=qs[_0x2b0af7('0x2c')](_0x12c17d[_0x2b0af7('0x20')][_0x2b0af7('0x2c')]),_0x5c837a[_0x2b0af7('0x4a')]=qs[_0x2b0af7('0x4a')](_0x12c17d[_0x2b0af7('0x20')][_0x2b0af7('0x4a')])),_0x51566b[_0x2b0af7('0x22')](_0x5c837a);})['then'](function(_0x595676){if(_0x595676)return _0x595676?{'count':_0x1ea5a9,'rows':_0x595676}:null;})[_0x3e08a3('0x13')](respondWithResult(_0x8edc67,null))[_0x3e08a3('0x36')](handleError(_0x8edc67,null));},exports[_0x216396('0x16')]=function(_0x160fa8,_0xad9b28){const _0x274984=_0x216396;return _0x160fa8[_0x274984('0x40')]['id']&&delete _0x160fa8[_0x274984('0x40')]['id'],db[_0x274984('0x28')][_0x274984('0xc')]({'where':{'id':_0x160fa8[_0x274984('0xe')]['id']}})[_0x274984('0x13')](handleEntityNotFound(_0xad9b28,null))[_0x274984('0x13')](function(_0x37dadf){const _0x329251=_0x274984;if(_0x37dadf)return _0x160fa8[_0x329251('0x40')][_0x329251('0x5a')]=_0x37dadf['id'],_0x160fa8[_0x329251('0x40')][_0x329251('0x2a')]=integrations['getSubjects'](_0x160fa8[_0x329251('0x40')][_0x329251('0x1a')],_0x160fa8[_0x329251('0x40')][_0x329251('0x59')]),_0x160fa8['body'][_0x329251('0x49')]=integrations['getDescriptions'](_0x160fa8[_0x329251('0x40')][_0x329251('0x1a')],_0x160fa8[_0x329251('0x40')][_0x329251('0x59')]),db[_0x329251('0x26')]['create'](_0x160fa8[_0x329251('0x40')],{'include':[{'model':db[_0x329251('0x2e')],'as':'Subjects'},{'model':db[_0x329251('0x2e')],'as':'Descriptions'}]});return null;})['then'](respondWithResult(_0xad9b28,null))[_0x274984('0x36')](handleError(_0xad9b28,null));},exports[_0x216396('0x1e')]=function(_0x408e80,_0x175936){const _0x2cd95b=_0x216396;let _0x65a45f='';return db[_0x2cd95b('0x28')][_0x2cd95b('0xc')]({'where':{'id':_0x408e80[_0x2cd95b('0xe')]['id']},'attributes':['id','username',_0x2cd95b('0x1b'),_0x2cd95b('0x23'),_0x2cd95b('0x38'),'remoteUri']})['then'](handleEntityNotFound(_0x175936,null))[_0x2cd95b('0x13')](function(_0x572cdf){const _0xac14f6=_0x2cd95b;if(_0x572cdf){_0x65a45f=_0x572cdf['remoteUri'];const _0x23de95=_0x65a45f['slice'](-0x1);_0x23de95==='/'&&(_0x65a45f=_0x65a45f['substring'](0x0,_0x65a45f['lastIndexOf'](_0x23de95)));const _0x1349c9={'method':_0xac14f6('0x1d'),'uri':util[_0xac14f6('0x6')](_0xac14f6('0x12'),_0x65a45f,_0xac14f6('0x51')),'json':!![]};switch(_0x572cdf['authType']){case _0xac14f6('0x1b'):_0x1349c9[_0xac14f6('0x4e')]={'Authorization':util[_0xac14f6('0x6')](_0xac14f6('0x2'),Buffer[_0xac14f6('0x2d')](util[_0xac14f6('0x6')](_0xac14f6('0x35'),_0x572cdf[_0xac14f6('0x7')],_0x572cdf[_0xac14f6('0x1b')]))[_0xac14f6('0x3b')](_0xac14f6('0x30')))};break;case _0xac14f6('0x23'):_0x1349c9[_0xac14f6('0x4e')]={'Authorization':util[_0xac14f6('0x6')]('Basic\x20%s',Buffer['from'](util[_0xac14f6('0x6')](_0xac14f6('0x15'),_0x572cdf[_0xac14f6('0x7')],_0x572cdf[_0xac14f6('0x23')]))[_0xac14f6('0x3b')](_0xac14f6('0x30')))};break;default:throw new ValidationError(_0xac14f6('0x17'));}return rp(_0x1349c9);}})[_0x2cd95b('0x13')](function(_0x211224){const _0x37e937=_0x2cd95b;if(_0x211224){const _0x564079=[_0x37e937('0x3c'),_0x37e937('0x44'),_0x37e937('0x41'),_0x37e937('0x47')];return _[_0x37e937('0x37')](_0x211224[_0x37e937('0x51')],function(_0xa55627){return _0x564079['includes'](_0xa55627['type']);}),{'count':_0x211224[_0x37e937('0x51')][_0x37e937('0xb')],'rows':_[_0x37e937('0x0')](_0x211224[_0x37e937('0x51')],function(_0x1fc14e){const _0x23c638=_0x37e937;return{'id':_0x1fc14e['id'],'name':_0x1fc14e['position']>0x7?_0x1fc14e[_0x23c638('0x21')]:_0x1fc14e[_0x23c638('0x59')],'custom':_0x1fc14e['position']>0x7?!![]:![],'options':_0x1fc14e[_0x23c638('0x1')]?_0x1fc14e[_0x23c638('0x1')]:_0x1fc14e[_0x23c638('0x14')]?_0x1fc14e[_0x23c638('0x14')]:[]};})};}})[_0x2cd95b('0x13')](respondWithResult(_0x175936,null))[_0x2cd95b('0x36')](function(_0x5ea171){const _0x4c006a=_0x2cd95b;let _0x4bbf58=_0x408e80[_0x4c006a('0x20')]['test']?0x1f4:_0x5ea171['statusCode']||0x1f4;logger[_0x4c006a('0x27')]('getFields,\x20%s,\x20%s,\x20%s',_0x4c006a('0x1e'),_0x4bbf58,JSON[_0x4c006a('0x54')](_0x5ea171)),delete _0x5ea171[_0x4c006a('0x3f')],_0x4bbf58===0x191&&(_0x4bbf58=0x190),_0x175936[_0x4c006a('0x57')](_0x4bbf58)[_0x4c006a('0x46')](_0x408e80['query'][_0x4c006a('0x56')]?{'message':'Wrong\x20credentials','statusCode':_0x5ea171[_0x4c006a('0x5')]}:_0x5ea171);});}; \ No newline at end of file +const a333_0x4152=['rows','destroy','then','keys','fields','system_field_options','update','like','params','GET','Descriptions','ZendeskAccount','type','format','channel','key','intersection','error','../../components/integrations/configuration','getSubjects','length','Wrong\x20credentials','set','filter','toString','index','includeAll','position','getFields','limit','subject','map','Content-Range','show','undefined','../../components/parsers/qs','options','findOne','end','findAll','ZendeskConfiguration','catch','filters','statusCode','headers','%s/token:%s','addConfiguration','name','test','token','substring','username','create','count','lodash','Unknown\x20authentication\x20type','getConfigurations','remoteUri','sendStatus','../../mysqldb','../../config/logger','Basic\x20%s','body','assignee','attributes','merge','includes','%s:%s','rawAttributes','stringify','authType','where','fieldName','VIRTUAL','sort','password','slice','remove','order','offset','Subjects','model','json','api','status','include','sequelize','query','lastIndexOf','custom_field_options','ticket_fields','pick','AccountId','util','nolimit'];(function(_0xf74993,_0x41520e){const _0x435726=function(_0x37ad3a){while(--_0x37ad3a){_0xf74993['push'](_0xf74993['shift']());}};_0x435726(++_0x41520e);}(a333_0x4152,0xe4));const a333_0x4357=function(_0xf74993,_0x41520e){_0xf74993=_0xf74993-0x0;let _0x435726=a333_0x4152[_0xf74993];return _0x435726;};const _0x4d292d=a333_0x4357;'use strict';const rp=require('request-promise-native'),util=require(_0x4d292d('0x37')),_=require(_0x4d292d('0x10')),qs=require(_0x4d292d('0x5c')),logger=require(_0x4d292d('0x16'))(_0x4d292d('0x2d')),db=require(_0x4d292d('0x15'))['db'],{Op,ValidationError}=require(_0x4d292d('0x30')),integrations=require(_0x4d292d('0x4b'));function respondWithResult(_0x37ad3a,_0x4f09e3){return _0x4f09e3=_0x4f09e3||0xc8,function(_0x17adc1){const _0x52080d=a333_0x4357;if(_0x17adc1)return _0x37ad3a[_0x52080d('0x2e')](_0x4f09e3)[_0x52080d('0x2c')](_0x17adc1);};}function respondWithFilteredResult(_0x38a695,_0x517e71){return function(_0x2153b0){const _0x518754=a333_0x4357;if(_0x2153b0){const _0xbd4d9e=_0x2153b0[_0x518754('0xf')],_0x39ff3f=_0x517e71[_0x518754('0x29')];let _0x1dd3e9=_0x517e71['offset']+_0x517e71['limit'],_0x4eab7f;return _0x1dd3e9>=_0xbd4d9e?(_0x1dd3e9=_0xbd4d9e,_0x4eab7f=0xc8):_0x4eab7f=0xce,_0x38a695[_0x518754('0x2e')](_0x4eab7f),_0x38a695[_0x518754('0x4f')](_0x518754('0x59'),_0x39ff3f+'-'+_0x1dd3e9+'/'+_0xbd4d9e)[_0x518754('0x2c')](_0x2153b0);}return null;};}function saveUpdates(_0x821cb2){return function(_0x3c3d7c){const _0x52947d=a333_0x4357;if(_0x3c3d7c)return _0x3c3d7c['update'](_0x821cb2)[_0x52947d('0x3b')](function(_0x2714c4){return _0x2714c4;});return null;};}function removeEntity(_0x485531){return function(_0x2b3944){const _0x4ba2d7=a333_0x4357;if(_0x2b3944)return _0x2b3944[_0x4ba2d7('0x3a')]()[_0x4ba2d7('0x3b')](function(){const _0x47c7e7=_0x4ba2d7;_0x485531[_0x47c7e7('0x2e')](0xcc)[_0x47c7e7('0x0')]();});};}function handleEntityNotFound(_0x579ca6){return function(_0x27d3ab){const _0x147abe=a333_0x4357;return!_0x27d3ab&&_0x579ca6[_0x147abe('0x14')](0x194),_0x27d3ab;};}function handleError(_0x4a8751,_0x444865){return _0x444865=_0x444865||0x1f4,function(_0x6a42fc){const _0x200654=a333_0x4357;logger[_0x200654('0x4a')](_0x6a42fc['stack']),_0x6a42fc[_0x200654('0x9')]&&delete _0x6a42fc['name'],_0x4a8751[_0x200654('0x2e')](_0x444865)['send'](_0x6a42fc);};}exports[_0x4d292d('0x52')]=function(_0x427350,_0x15eaff){const _0x14e02b=_0x4d292d;let _0x68259e={};const _0xc91309={},_0x1daf9a={'count':0x0,'rows':[]},_0x3051d6=_[_0x14e02b('0x58')](db[_0x14e02b('0x44')][_0x14e02b('0x1e')],function(_0x52a7ed){const _0x1430db=_0x14e02b;return{'name':_0x52a7ed[_0x1430db('0x22')],'type':_0x52a7ed[_0x1430db('0x45')][_0x1430db('0x48')]};});_0xc91309[_0x14e02b('0x2b')]=_[_0x14e02b('0x58')](_0x3051d6,_0x14e02b('0x9')),_0xc91309['query']=_['keys'](_0x427350[_0x14e02b('0x31')]),_0xc91309[_0x14e02b('0x4')]=_[_0x14e02b('0x49')](_0xc91309[_0x14e02b('0x2b')],_0xc91309['query']),_0x68259e[_0x14e02b('0x1a')]=_[_0x14e02b('0x49')](_0xc91309[_0x14e02b('0x2b')],qs[_0x14e02b('0x3d')](_0x427350[_0x14e02b('0x31')][_0x14e02b('0x3d')])),_0x68259e[_0x14e02b('0x1a')]=_0x68259e[_0x14e02b('0x1a')][_0x14e02b('0x4d')]?_0x68259e[_0x14e02b('0x1a')]:_0xc91309[_0x14e02b('0x2b')];typeof _0x427350['query'][_0x14e02b('0x38')]==='undefined'&&(_0x68259e[_0x14e02b('0x56')]=qs['limit'](_0x427350['query'][_0x14e02b('0x56')]),_0x68259e[_0x14e02b('0x29')]=qs[_0x14e02b('0x29')](_0x427350[_0x14e02b('0x31')][_0x14e02b('0x29')]));_0x68259e[_0x14e02b('0x28')]=qs[_0x14e02b('0x24')](_0x427350[_0x14e02b('0x31')][_0x14e02b('0x24')]),_0x68259e[_0x14e02b('0x21')]=qs[_0x14e02b('0x4')](_[_0x14e02b('0x35')](_0x427350['query'],_0xc91309[_0x14e02b('0x4')]),_0x3051d6);_0x427350[_0x14e02b('0x31')]['filter']&&(_0x68259e[_0x14e02b('0x21')]=_[_0x14e02b('0x1b')](_0x68259e[_0x14e02b('0x21')],{[Op['or']]:_['map'](_0x3051d6,function(_0x34adce){const _0x5cdc3b=_0x14e02b;if(_0x34adce['type']!==_0x5cdc3b('0x23')){const _0x2a1a49={};return _0x2a1a49[_0x34adce['name']]={[Op[_0x5cdc3b('0x40')]]:'%'+_0x427350[_0x5cdc3b('0x31')]['filter']+'%'},_0x2a1a49;}})}));_0x68259e=_[_0x14e02b('0x1b')]({},_0x68259e,_0x427350[_0x14e02b('0x5d')]);const _0x337fa6={'where':_0x68259e[_0x14e02b('0x21')]};return db[_0x14e02b('0x44')][_0x14e02b('0xf')](_0x337fa6)[_0x14e02b('0x3b')](function(_0x34c37f){const _0x4c8490=_0x14e02b;return _0x1daf9a['count']=_0x34c37f,_0x427350[_0x4c8490('0x31')][_0x4c8490('0x53')]&&(_0x68259e['include']=[{'all':!![]}]),db[_0x4c8490('0x44')][_0x4c8490('0x1')](_0x68259e);})[_0x14e02b('0x3b')](function(_0x40e108){const _0x331c85=_0x14e02b;return _0x1daf9a[_0x331c85('0x39')]=_0x40e108,_0x1daf9a;})[_0x14e02b('0x3b')](respondWithFilteredResult(_0x15eaff,_0x68259e))[_0x14e02b('0x3')](handleError(_0x15eaff,null));},exports[_0x4d292d('0x5a')]=function(_0x165c5b,_0x2f3e6d){const _0x293d04=_0x4d292d;let _0x3aa14c={'raw':![],'where':{'id':_0x165c5b[_0x293d04('0x41')]['id']}};const _0x3a9880={};return _0x3a9880[_0x293d04('0x2b')]=_[_0x293d04('0x3c')](db[_0x293d04('0x44')]['rawAttributes']),_0x3a9880[_0x293d04('0x31')]=_['keys'](_0x165c5b[_0x293d04('0x31')]),_0x3a9880[_0x293d04('0x4')]=_['intersection'](_0x3a9880[_0x293d04('0x2b')],_0x3a9880[_0x293d04('0x31')]),_0x3aa14c[_0x293d04('0x1a')]=_[_0x293d04('0x49')](_0x3a9880[_0x293d04('0x2b')],qs[_0x293d04('0x3d')](_0x165c5b['query'][_0x293d04('0x3d')])),_0x3aa14c['attributes']=_0x3aa14c['attributes'][_0x293d04('0x4d')]?_0x3aa14c['attributes']:_0x3a9880[_0x293d04('0x2b')],_0x165c5b[_0x293d04('0x31')][_0x293d04('0x53')]&&(_0x3aa14c[_0x293d04('0x2f')]=[{'all':!![]}]),_0x3aa14c=_[_0x293d04('0x1b')]({},_0x3aa14c,_0x165c5b[_0x293d04('0x5d')]),db[_0x293d04('0x44')]['findOne'](_0x3aa14c)['then'](handleEntityNotFound(_0x2f3e6d,null))[_0x293d04('0x3b')](respondWithResult(_0x2f3e6d,null))[_0x293d04('0x3')](handleError(_0x2f3e6d,null));},exports['create']=function(_0xb79c0f,_0x35beff){const _0x4abe51=_0x4d292d;return db[_0x4abe51('0x44')]['create'](_0xb79c0f['body'],{})[_0x4abe51('0x3b')](respondWithResult(_0x35beff,0xc9))[_0x4abe51('0x3')](handleError(_0x35beff,null));},exports[_0x4d292d('0x3f')]=function(_0x32a13e,_0x469e47){const _0x7daca7=_0x4d292d;return _0x32a13e['body']['id']&&delete _0x32a13e['body']['id'],db[_0x7daca7('0x44')][_0x7daca7('0x5e')]({'where':{'id':_0x32a13e[_0x7daca7('0x41')]['id']}})[_0x7daca7('0x3b')](handleEntityNotFound(_0x469e47,null))[_0x7daca7('0x3b')](saveUpdates(_0x32a13e[_0x7daca7('0x18')],null))['then'](respondWithResult(_0x469e47,null))[_0x7daca7('0x3')](handleError(_0x469e47,null));},exports['destroy']=function(_0x4bae6e,_0x24f7f1){const _0x40dd1e=_0x4d292d;return db[_0x40dd1e('0x44')][_0x40dd1e('0x5e')]({'where':{'id':_0x4bae6e[_0x40dd1e('0x41')]['id']}})[_0x40dd1e('0x3b')](handleEntityNotFound(_0x24f7f1,null))[_0x40dd1e('0x3b')](removeEntity(_0x24f7f1,null))[_0x40dd1e('0x3')](handleError(_0x24f7f1,null));},exports[_0x4d292d('0x12')]=function(_0x520629,_0x539c3c){const _0x5d052f=_0x4d292d;let _0x150c97={};const _0x2cafde={};let _0xa448d2,_0x1faac5;return db['ZendeskAccount'][_0x5d052f('0x5e')]({'where':{'id':_0x520629['params']['id']}})[_0x5d052f('0x3b')](handleEntityNotFound(_0x539c3c,null))[_0x5d052f('0x3b')](function(_0x5c09b0){const _0x485c96=_0x5d052f;if(_0x5c09b0)return _0xa448d2=_0x5c09b0,_0x2cafde[_0x485c96('0x2b')]=_[_0x485c96('0x3c')](db[_0x485c96('0x2')][_0x485c96('0x1e')]),_0x2cafde[_0x485c96('0x31')]=_[_0x485c96('0x3c')](_0x520629[_0x485c96('0x31')]),_0x2cafde[_0x485c96('0x4')]=_[_0x485c96('0x49')](_0x2cafde['model'],_0x2cafde[_0x485c96('0x31')]),_0x150c97[_0x485c96('0x1a')]=_[_0x485c96('0x49')](_0x2cafde['model'],qs[_0x485c96('0x3d')](_0x520629[_0x485c96('0x31')]['fields'])),_0x150c97['attributes']=_0x150c97['attributes'][_0x485c96('0x4d')]?_0x150c97[_0x485c96('0x1a')]:_0x2cafde[_0x485c96('0x2b')],_0x150c97[_0x485c96('0x28')]=qs[_0x485c96('0x24')](_0x520629['query'][_0x485c96('0x24')]),_0x150c97['where']=qs[_0x485c96('0x4')](_[_0x485c96('0x35')](_0x520629['query'],_0x2cafde['filters'])),_0x520629[_0x485c96('0x31')][_0x485c96('0x50')]&&(_0x150c97[_0x485c96('0x21')]=_['merge'](_0x150c97[_0x485c96('0x21')],{[Op['or']]:_[_0x485c96('0x58')](_0x150c97['attributes'],function(_0x1e928c){const _0x5e8a4f=_0x485c96,_0xde7440={};return _0xde7440[_0x1e928c]={[Op['like']]:'%'+_0x520629[_0x5e8a4f('0x31')]['filter']+'%'},_0xde7440;})})),_0x150c97=_[_0x485c96('0x1b')]({},_0x150c97,_0x520629[_0x485c96('0x5d')]),_0xa448d2['getConfigurations'](_0x150c97);})['then'](function(_0x1fedb3){const _0x160fc4=_0x5d052f;if(_0x1fedb3)return _0x1faac5=_0x1fedb3[_0x160fc4('0x4d')],typeof _0x520629['query'][_0x160fc4('0x38')]===_0x160fc4('0x5b')&&(_0x150c97['limit']=qs[_0x160fc4('0x56')](_0x520629[_0x160fc4('0x31')][_0x160fc4('0x56')]),_0x150c97[_0x160fc4('0x29')]=qs[_0x160fc4('0x29')](_0x520629[_0x160fc4('0x31')][_0x160fc4('0x29')])),_0xa448d2[_0x160fc4('0x12')](_0x150c97);})['then'](function(_0x9d682b){if(_0x9d682b)return _0x9d682b?{'count':_0x1faac5,'rows':_0x9d682b}:null;})['then'](respondWithResult(_0x539c3c,null))['catch'](handleError(_0x539c3c,null));},exports[_0x4d292d('0x8')]=function(_0x3a7dd2,_0x54e3c2){const _0x196806=_0x4d292d;return _0x3a7dd2['body']['id']&&delete _0x3a7dd2['body']['id'],db[_0x196806('0x44')][_0x196806('0x5e')]({'where':{'id':_0x3a7dd2[_0x196806('0x41')]['id']}})[_0x196806('0x3b')](handleEntityNotFound(_0x54e3c2,null))['then'](function(_0x96b647){const _0x3c955b=_0x196806;if(_0x96b647)return _0x3a7dd2[_0x3c955b('0x18')][_0x3c955b('0x36')]=_0x96b647['id'],_0x3a7dd2[_0x3c955b('0x18')]['Subjects']=integrations[_0x3c955b('0x4c')](_0x3a7dd2[_0x3c955b('0x18')][_0x3c955b('0x47')],_0x3a7dd2['body'][_0x3c955b('0x45')]),_0x3a7dd2[_0x3c955b('0x18')]['Descriptions']=integrations['getDescriptions'](_0x3a7dd2['body'][_0x3c955b('0x47')],_0x3a7dd2[_0x3c955b('0x18')][_0x3c955b('0x45')]),db[_0x3c955b('0x2')][_0x3c955b('0xe')](_0x3a7dd2[_0x3c955b('0x18')],{'include':[{'model':db['ZendeskField'],'as':_0x3c955b('0x2a')},{'model':db['ZendeskField'],'as':_0x3c955b('0x43')}]});return null;})[_0x196806('0x3b')](respondWithResult(_0x54e3c2,null))[_0x196806('0x3')](handleError(_0x54e3c2,null));},exports[_0x4d292d('0x55')]=function(_0xa38e35,_0x4b19ab){const _0x41359f=_0x4d292d;let _0x479075='';return db['ZendeskAccount'][_0x41359f('0x5e')]({'where':{'id':_0xa38e35[_0x41359f('0x41')]['id']},'attributes':['id',_0x41359f('0xd'),_0x41359f('0x25'),'token',_0x41359f('0x20'),_0x41359f('0x13')]})[_0x41359f('0x3b')](handleEntityNotFound(_0x4b19ab,null))[_0x41359f('0x3b')](function(_0x1aef59){const _0x4a68a8=_0x41359f;if(_0x1aef59){_0x479075=_0x1aef59['remoteUri'];const _0x3d02c6=_0x479075[_0x4a68a8('0x26')](-0x1);_0x3d02c6==='/'&&(_0x479075=_0x479075[_0x4a68a8('0xc')](0x0,_0x479075[_0x4a68a8('0x32')](_0x3d02c6)));const _0x4be84a={'method':_0x4a68a8('0x42'),'uri':util[_0x4a68a8('0x46')]('%s/%s',_0x479075,_0x4a68a8('0x34')),'json':!![]};switch(_0x1aef59[_0x4a68a8('0x20')]){case'password':_0x4be84a['headers']={'Authorization':util[_0x4a68a8('0x46')](_0x4a68a8('0x17'),Buffer['from'](util[_0x4a68a8('0x46')](_0x4a68a8('0x1d'),_0x1aef59[_0x4a68a8('0xd')],_0x1aef59[_0x4a68a8('0x25')]))[_0x4a68a8('0x51')]('base64'))};break;case _0x4a68a8('0xb'):_0x4be84a[_0x4a68a8('0x6')]={'Authorization':util['format']('Basic\x20%s',Buffer['from'](util[_0x4a68a8('0x46')](_0x4a68a8('0x7'),_0x1aef59[_0x4a68a8('0xd')],_0x1aef59[_0x4a68a8('0xb')]))['toString']('base64'))};break;default:throw new ValidationError(_0x4a68a8('0x11'));}return rp(_0x4be84a);}})['then'](function(_0xd91d0e){const _0x1fb2d9=_0x41359f;if(_0xd91d0e){const _0xc179c0=[_0x1fb2d9('0x57'),'description','group',_0x1fb2d9('0x19')];return _[_0x1fb2d9('0x27')](_0xd91d0e[_0x1fb2d9('0x34')],function(_0x4be3bb){const _0x65976f=_0x1fb2d9;return _0xc179c0[_0x65976f('0x1c')](_0x4be3bb[_0x65976f('0x45')]);}),{'count':_0xd91d0e['ticket_fields'][_0x1fb2d9('0x4d')],'rows':_[_0x1fb2d9('0x58')](_0xd91d0e[_0x1fb2d9('0x34')],function(_0x3ddb91){const _0x368031=_0x1fb2d9;return{'id':_0x3ddb91['id'],'name':_0x3ddb91[_0x368031('0x54')]>0x7?_0x3ddb91['title']:_0x3ddb91['type'],'custom':_0x3ddb91['position']>0x7?!![]:![],'options':_0x3ddb91[_0x368031('0x3e')]?_0x3ddb91[_0x368031('0x3e')]:_0x3ddb91['custom_field_options']?_0x3ddb91[_0x368031('0x33')]:[]};})};}})[_0x41359f('0x3b')](respondWithResult(_0x4b19ab,null))['catch'](function(_0x4c7d60){const _0x49b1da=_0x41359f;let _0x23b2aa=_0xa38e35[_0x49b1da('0x31')][_0x49b1da('0xa')]?0x1f4:_0x4c7d60[_0x49b1da('0x5')]||0x1f4;logger[_0x49b1da('0x4a')]('getFields,\x20%s,\x20%s,\x20%s','getFields',_0x23b2aa,JSON[_0x49b1da('0x1f')](_0x4c7d60)),delete _0x4c7d60[_0x49b1da('0x9')],_0x23b2aa===0x191&&(_0x23b2aa=0x190),_0x4b19ab[_0x49b1da('0x2e')](_0x23b2aa)['send'](_0xa38e35['query'][_0x49b1da('0xa')]?{'message':_0x49b1da('0x4e'),'statusCode':_0x4c7d60[_0x49b1da('0x5')]}:_0x4c7d60);});}; \ No newline at end of file diff --git a/server/api/intZendeskAccount/intZendeskAccount.model.js b/server/api/intZendeskAccount/intZendeskAccount.model.js index 74d29bc..13710eb 100644 --- a/server/api/intZendeskAccount/intZendeskAccount.model.js +++ b/server/api/intZendeskAccount/intZendeskAccount.model.js @@ -1 +1 @@ -const a334_0x4535=['ZendeskAccount','define','int_zendesk_accounts','exports'];(function(_0x2ade3c,_0x45351d){const _0x269f42=function(_0x489fda){while(--_0x489fda){_0x2ade3c['push'](_0x2ade3c['shift']());}};_0x269f42(++_0x45351d);}(a334_0x4535,0x129));const a334_0x269f=function(_0x2ade3c,_0x45351d){_0x2ade3c=_0x2ade3c-0x0;let _0x269f42=a334_0x4535[_0x2ade3c];return _0x269f42;};const _0x2e9d7f=a334_0x269f;'use strict';const attributes=require('./intZendeskAccount.attributes');module[_0x2e9d7f('0x2')]=function(_0x489fda){const _0x5c7a1b=_0x2e9d7f,_0x549700=_0x489fda[_0x5c7a1b('0x0')](_0x5c7a1b('0x3'),attributes,{'tableName':_0x5c7a1b('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x549700;}; \ No newline at end of file +const a334_0x1d3a=['ZendeskAccount','define','./intZendeskAccount.attributes','int_zendesk_accounts'];(function(_0x2a91ca,_0x1d3afb){const _0x366f64=function(_0x392f65){while(--_0x392f65){_0x2a91ca['push'](_0x2a91ca['shift']());}};_0x366f64(++_0x1d3afb);}(a334_0x1d3a,0x1a1));const a334_0x366f=function(_0x2a91ca,_0x1d3afb){_0x2a91ca=_0x2a91ca-0x0;let _0x366f64=a334_0x1d3a[_0x2a91ca];return _0x366f64;};const _0x1265af=a334_0x366f;'use strict';const attributes=require(_0x1265af('0x1'));module['exports']=function(_0x392f65){const _0x105b4e=_0x1265af,_0x31d8f4=_0x392f65[_0x105b4e('0x0')](_0x105b4e('0x3'),attributes,{'tableName':_0x105b4e('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x31d8f4;}; \ No newline at end of file diff --git a/server/api/intZendeskAccount/intZendeskAccount.rpc.js b/server/api/intZendeskAccount/intZendeskAccount.rpc.js index c25f807..18cc0e7 100644 --- a/server/api/intZendeskAccount/intZendeskAccount.rpc.js +++ b/server/api/intZendeskAccount/intZendeskAccount.rpc.js @@ -1 +1 @@ -const a335_0x45d9=['GetZendeskAccount','ShowZendeskAccount','then','info','model','findOne','stringify','rpc','../../mysqldb','catch','where','map','debug','options','ZendeskAccount','lodash','include','message','raw','attributes','error','findAll'];(function(_0x10a75a,_0x45d9dd){const _0x270f71=function(_0x38d592){while(--_0x38d592){_0x10a75a['push'](_0x10a75a['shift']());}};_0x270f71(++_0x45d9dd);}(a335_0x45d9,0xfd));const a335_0x270f=function(_0x10a75a,_0x45d9dd){_0x10a75a=_0x10a75a-0x0;let _0x270f71=a335_0x45d9[_0x10a75a];return _0x270f71;};const _0x4a72ca=a335_0x270f;'use strict';const _=require(_0x4a72ca('0x4')),db=require(_0x4a72ca('0x13'))['db'],logger=require('../../config/logger')(_0x4a72ca('0x12'));exports[_0x4a72ca('0xb')]=function(_0x38d592){const _0x403820=this;return new Promise(function(_0xfe9b58,_0x4718e5){const _0x4e7748=a335_0x270f;return db[_0x4e7748('0x3')][_0x4e7748('0xa')]({'raw':_0x38d592[_0x4e7748('0x2')]?_0x38d592[_0x4e7748('0x2')][_0x4e7748('0x7')]===undefined?!![]:![]:!![],'where':_0x38d592['options']?_0x38d592[_0x4e7748('0x2')][_0x4e7748('0x15')]||null:null,'attributes':_0x38d592[_0x4e7748('0x2')]?_0x38d592[_0x4e7748('0x2')][_0x4e7748('0x8')]||null:null,'limit':_0x38d592[_0x4e7748('0x2')]?_0x38d592[_0x4e7748('0x2')]['limit']||null:null,'include':_0x38d592['options']?_0x38d592[_0x4e7748('0x2')][_0x4e7748('0x5')]?_[_0x4e7748('0x0')](_0x38d592[_0x4e7748('0x2')]['include'],function(_0x258ba5){const _0x452b5e=_0x4e7748;return{'model':db[_0x258ba5[_0x452b5e('0xf')]],'as':_0x258ba5['as'],'attributes':_0x258ba5[_0x452b5e('0x8')],'include':_0x258ba5['include']?_['map'](_0x258ba5['include'],function(_0x4525c3){const _0x1915e2=_0x452b5e;return{'model':db[_0x4525c3[_0x1915e2('0xf')]],'as':_0x4525c3['as'],'attributes':_0x4525c3['attributes'],'include':_0x4525c3['include']?_[_0x1915e2('0x0')](_0x4525c3[_0x1915e2('0x5')],function(_0x3dd997){const _0x2b8f4f=_0x1915e2;return{'model':db[_0x3dd997[_0x2b8f4f('0xf')]],'as':_0x3dd997['as'],'attributes':_0x3dd997[_0x2b8f4f('0x8')]};}):[]};}):[]};}):[]:[]})[_0x4e7748('0xd')](function(_0x433e27){const _0x381b5d=_0x4e7748;logger['info'](_0x381b5d('0xb'),_0x38d592),logger[_0x381b5d('0x1')](_0x381b5d('0xb'),_0x38d592,JSON[_0x381b5d('0x11')](_0x433e27)),_0xfe9b58(_0x433e27);})[_0x4e7748('0x14')](function(_0x5e8949){const _0x2a0e19=_0x4e7748;logger[_0x2a0e19('0x9')](_0x2a0e19('0xb'),_0x5e8949[_0x2a0e19('0x6')],_0x38d592),_0x4718e5(_0x403820[_0x2a0e19('0x9')](0x1f4,_0x5e8949[_0x2a0e19('0x6')]));});});},exports[_0x4a72ca('0xc')]=function(_0x4a7ddb){const _0x54f455=this;return new Promise(function(_0x3d3b0f,_0x4d49ba){const _0x45e2e1=a335_0x270f;return db[_0x45e2e1('0x3')][_0x45e2e1('0x10')]({'raw':_0x4a7ddb[_0x45e2e1('0x2')]?_0x4a7ddb[_0x45e2e1('0x2')][_0x45e2e1('0x7')]===undefined?!![]:![]:!![],'where':_0x4a7ddb[_0x45e2e1('0x2')]?_0x4a7ddb['options']['where']||null:null,'attributes':_0x4a7ddb[_0x45e2e1('0x2')]?_0x4a7ddb[_0x45e2e1('0x2')][_0x45e2e1('0x8')]||null:null,'include':_0x4a7ddb[_0x45e2e1('0x2')]?_0x4a7ddb[_0x45e2e1('0x2')][_0x45e2e1('0x5')]?_[_0x45e2e1('0x0')](_0x4a7ddb[_0x45e2e1('0x2')][_0x45e2e1('0x5')],function(_0x5c9acf){const _0x12404a=_0x45e2e1;return{'model':db[_0x5c9acf['model']],'as':_0x5c9acf['as'],'attributes':_0x5c9acf[_0x12404a('0x8')],'include':_0x5c9acf[_0x12404a('0x5')]?_['map'](_0x5c9acf[_0x12404a('0x5')],function(_0x551398){const _0x27be35=_0x12404a;return{'model':db[_0x551398['model']],'as':_0x551398['as'],'attributes':_0x551398['attributes'],'include':_0x551398[_0x27be35('0x5')]?_[_0x27be35('0x0')](_0x551398['include'],function(_0x1fed91){const _0x10f0ea=_0x27be35;return{'model':db[_0x1fed91[_0x10f0ea('0xf')]],'as':_0x1fed91['as'],'attributes':_0x1fed91['attributes']};}):[]};}):[]};}):[]:[]})[_0x45e2e1('0xd')](function(_0x2291a8){const _0x69d216=_0x45e2e1;logger[_0x69d216('0xe')]('ShowZendeskAccount',_0x4a7ddb),logger[_0x69d216('0x1')](_0x69d216('0xc'),_0x4a7ddb,JSON[_0x69d216('0x11')](_0x2291a8)),_0x3d3b0f(_0x2291a8);})['catch'](function(_0x37f81d){const _0x235ee6=_0x45e2e1;logger[_0x235ee6('0x9')]('ShowZendeskAccount',_0x37f81d[_0x235ee6('0x6')],_0x4a7ddb),_0x4d49ba(_0x54f455[_0x235ee6('0x9')](0x1f4,_0x37f81d[_0x235ee6('0x6')]));});});}; \ No newline at end of file +const a335_0x5ebe=['model','raw','debug','findAll','where','message','attributes','lodash','info','../../mysqldb','stringify','GetZendeskAccount','rpc','include','then','ZendeskAccount','ShowZendeskAccount','map','error','options','catch'];(function(_0x1dac87,_0x5ebeff){const _0x1b5ba2=function(_0x229aab){while(--_0x229aab){_0x1dac87['push'](_0x1dac87['shift']());}};_0x1b5ba2(++_0x5ebeff);}(a335_0x5ebe,0xe6));const a335_0x1b5b=function(_0x1dac87,_0x5ebeff){_0x1dac87=_0x1dac87-0x0;let _0x1b5ba2=a335_0x5ebe[_0x1dac87];return _0x1b5ba2;};const _0x3b1eae=a335_0x1b5b;'use strict';const _=require(_0x3b1eae('0x8')),db=require(_0x3b1eae('0xa'))['db'],logger=require('../../config/logger')(_0x3b1eae('0xd'));exports[_0x3b1eae('0xc')]=function(_0x229aab){const _0x2473c4=this;return new Promise(function(_0x236e6a,_0x264c63){const _0x11a188=a335_0x1b5b;return db[_0x11a188('0x10')][_0x11a188('0x4')]({'raw':_0x229aab['options']?_0x229aab[_0x11a188('0x14')]['raw']===undefined?!![]:![]:!![],'where':_0x229aab[_0x11a188('0x14')]?_0x229aab['options'][_0x11a188('0x5')]||null:null,'attributes':_0x229aab[_0x11a188('0x14')]?_0x229aab[_0x11a188('0x14')][_0x11a188('0x7')]||null:null,'limit':_0x229aab[_0x11a188('0x14')]?_0x229aab[_0x11a188('0x14')]['limit']||null:null,'include':_0x229aab['options']?_0x229aab[_0x11a188('0x14')][_0x11a188('0xe')]?_['map'](_0x229aab[_0x11a188('0x14')]['include'],function(_0x595a9f){const _0x3ef52d=_0x11a188;return{'model':db[_0x595a9f[_0x3ef52d('0x1')]],'as':_0x595a9f['as'],'attributes':_0x595a9f[_0x3ef52d('0x7')],'include':_0x595a9f[_0x3ef52d('0xe')]?_[_0x3ef52d('0x12')](_0x595a9f[_0x3ef52d('0xe')],function(_0x47e5fb){const _0x2ea26d=_0x3ef52d;return{'model':db[_0x47e5fb[_0x2ea26d('0x1')]],'as':_0x47e5fb['as'],'attributes':_0x47e5fb['attributes'],'include':_0x47e5fb['include']?_[_0x2ea26d('0x12')](_0x47e5fb[_0x2ea26d('0xe')],function(_0x15fd33){const _0x25b27a=_0x2ea26d;return{'model':db[_0x15fd33['model']],'as':_0x15fd33['as'],'attributes':_0x15fd33[_0x25b27a('0x7')]};}):[]};}):[]};}):[]:[]})[_0x11a188('0xf')](function(_0x306a4b){const _0x145748=_0x11a188;logger[_0x145748('0x9')](_0x145748('0xc'),_0x229aab),logger[_0x145748('0x3')](_0x145748('0xc'),_0x229aab,JSON['stringify'](_0x306a4b)),_0x236e6a(_0x306a4b);})[_0x11a188('0x0')](function(_0x440811){const _0x4d86ad=_0x11a188;logger['error'](_0x4d86ad('0xc'),_0x440811[_0x4d86ad('0x6')],_0x229aab),_0x264c63(_0x2473c4[_0x4d86ad('0x13')](0x1f4,_0x440811[_0x4d86ad('0x6')]));});});},exports[_0x3b1eae('0x11')]=function(_0x5712bf){const _0x28d9af=this;return new Promise(function(_0xd01e3f,_0x4460ae){const _0x1b5c39=a335_0x1b5b;return db['ZendeskAccount']['findOne']({'raw':_0x5712bf[_0x1b5c39('0x14')]?_0x5712bf[_0x1b5c39('0x14')][_0x1b5c39('0x2')]===undefined?!![]:![]:!![],'where':_0x5712bf[_0x1b5c39('0x14')]?_0x5712bf[_0x1b5c39('0x14')][_0x1b5c39('0x5')]||null:null,'attributes':_0x5712bf[_0x1b5c39('0x14')]?_0x5712bf[_0x1b5c39('0x14')][_0x1b5c39('0x7')]||null:null,'include':_0x5712bf[_0x1b5c39('0x14')]?_0x5712bf[_0x1b5c39('0x14')][_0x1b5c39('0xe')]?_[_0x1b5c39('0x12')](_0x5712bf[_0x1b5c39('0x14')][_0x1b5c39('0xe')],function(_0x146c82){const _0x2df718=_0x1b5c39;return{'model':db[_0x146c82[_0x2df718('0x1')]],'as':_0x146c82['as'],'attributes':_0x146c82[_0x2df718('0x7')],'include':_0x146c82[_0x2df718('0xe')]?_['map'](_0x146c82[_0x2df718('0xe')],function(_0x3fe987){const _0x34b70b=_0x2df718;return{'model':db[_0x3fe987[_0x34b70b('0x1')]],'as':_0x3fe987['as'],'attributes':_0x3fe987[_0x34b70b('0x7')],'include':_0x3fe987[_0x34b70b('0xe')]?_['map'](_0x3fe987[_0x34b70b('0xe')],function(_0x235b75){const _0x2fdd82=_0x34b70b;return{'model':db[_0x235b75['model']],'as':_0x235b75['as'],'attributes':_0x235b75[_0x2fdd82('0x7')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x15c1e7){const _0xb755d1=_0x1b5c39;logger[_0xb755d1('0x9')](_0xb755d1('0x11'),_0x5712bf),logger[_0xb755d1('0x3')](_0xb755d1('0x11'),_0x5712bf,JSON[_0xb755d1('0xb')](_0x15c1e7)),_0xd01e3f(_0x15c1e7);})['catch'](function(_0x2515bd){const _0x10330f=_0x1b5c39;logger[_0x10330f('0x13')](_0x10330f('0x11'),_0x2515bd[_0x10330f('0x6')],_0x5712bf),_0x4460ae(_0x28d9af[_0x10330f('0x13')](0x1f4,_0x2515bd[_0x10330f('0x6')]));});});}; \ No newline at end of file diff --git a/server/api/intZendeskConfiguration/index.js b/server/api/intZendeskConfiguration/index.js index 04849dc..4e1b19b 100644 --- a/server/api/intZendeskConfiguration/index.js +++ b/server/api/intZendeskConfiguration/index.js @@ -1 +1 @@ -const a336_0x5bc9=['index','destroy','getFields','put','/:id','/:id/tags','/:id/subjects','getTags','exports','isAuthenticated','setTags','create','update','get','post','express','getDescriptions','delete','/:id/fields'];(function(_0x5d4aa3,_0x5bc95a){const _0x409146=function(_0x3ceef9){while(--_0x3ceef9){_0x5d4aa3['push'](_0x5d4aa3['shift']());}};_0x409146(++_0x5bc95a);}(a336_0x5bc9,0x1af));const a336_0x4091=function(_0x5d4aa3,_0x5bc95a){_0x5d4aa3=_0x5d4aa3-0x0;let _0x409146=a336_0x5bc9[_0x5d4aa3];return _0x409146;};const _0x290c62=a336_0x4091;'use strict';const express=require(_0x290c62('0x2')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require('./intZendeskConfiguration.controller');router[_0x290c62('0x0')]('/',auth[_0x290c62('0xf')](),controller[_0x290c62('0x6')]),router[_0x290c62('0x0')](_0x290c62('0xa'),auth[_0x290c62('0xf')](),controller['show']),router[_0x290c62('0x0')](_0x290c62('0x5'),auth[_0x290c62('0xf')](),controller[_0x290c62('0x8')]),router[_0x290c62('0x0')](_0x290c62('0xc'),auth[_0x290c62('0xf')](),controller['getSubjects']),router['get']('/:id/descriptions',auth[_0x290c62('0xf')](),controller[_0x290c62('0x3')]),router[_0x290c62('0x0')](_0x290c62('0xb'),auth[_0x290c62('0xf')](),controller[_0x290c62('0xd')]),router[_0x290c62('0x1')]('/',auth[_0x290c62('0xf')](),controller[_0x290c62('0x11')]),router[_0x290c62('0x1')](_0x290c62('0xb'),auth[_0x290c62('0xf')](),controller[_0x290c62('0x10')]),router[_0x290c62('0x9')](_0x290c62('0xa'),auth[_0x290c62('0xf')](),controller[_0x290c62('0x12')]),router[_0x290c62('0x4')](_0x290c62('0xa'),auth[_0x290c62('0xf')](),controller[_0x290c62('0x7')]),module[_0x290c62('0xe')]=router; \ No newline at end of file +const a336_0x4eb5=['express','index','get','/:id/descriptions','getSubjects','getFields','getDescriptions','getTags','/:id/subjects','show','/:id','/:id/tags','/:id/fields','create','delete','isAuthenticated','post','./intZendeskConfiguration.controller','put'];(function(_0x2b91bf,_0x4eb596){const _0x158580=function(_0x1c3ddc){while(--_0x1c3ddc){_0x2b91bf['push'](_0x2b91bf['shift']());}};_0x158580(++_0x4eb596);}(a336_0x4eb5,0x169));const a336_0x1585=function(_0x2b91bf,_0x4eb596){_0x2b91bf=_0x2b91bf-0x0;let _0x158580=a336_0x4eb5[_0x2b91bf];return _0x158580;};const _0x1c31ae=a336_0x1585;'use strict';const express=require(_0x1c31ae('0x0')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x1c31ae('0x11'));router[_0x1c31ae('0x2')]('/',auth[_0x1c31ae('0xf')](),controller[_0x1c31ae('0x1')]),router[_0x1c31ae('0x2')](_0x1c31ae('0xa'),auth['isAuthenticated'](),controller[_0x1c31ae('0x9')]),router['get'](_0x1c31ae('0xc'),auth[_0x1c31ae('0xf')](),controller[_0x1c31ae('0x5')]),router['get'](_0x1c31ae('0x8'),auth[_0x1c31ae('0xf')](),controller[_0x1c31ae('0x4')]),router[_0x1c31ae('0x2')](_0x1c31ae('0x3'),auth[_0x1c31ae('0xf')](),controller[_0x1c31ae('0x6')]),router[_0x1c31ae('0x2')](_0x1c31ae('0xb'),auth[_0x1c31ae('0xf')](),controller[_0x1c31ae('0x7')]),router[_0x1c31ae('0x10')]('/',auth[_0x1c31ae('0xf')](),controller[_0x1c31ae('0xd')]),router[_0x1c31ae('0x10')](_0x1c31ae('0xb'),auth[_0x1c31ae('0xf')](),controller['setTags']),router[_0x1c31ae('0x12')](_0x1c31ae('0xa'),auth[_0x1c31ae('0xf')](),controller['update']),router[_0x1c31ae('0xe')](_0x1c31ae('0xa'),auth['isAuthenticated'](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/intZendeskConfiguration/intZendeskConfiguration.attributes.js b/server/api/intZendeskConfiguration/intZendeskConfiguration.attributes.js index c49d619..242b81d 100644 --- a/server/api/intZendeskConfiguration/intZendeskConfiguration.attributes.js +++ b/server/api/intZendeskConfiguration/intZendeskConfiguration.attributes.js @@ -1 +1 @@ -const a337_0x4e5d=['STRING'];(function(_0x4584d4,_0x4e5d45){const _0x580953=function(_0x5553f5){while(--_0x5553f5){_0x4584d4['push'](_0x4584d4['shift']());}};_0x580953(++_0x4e5d45);}(a337_0x4e5d,0x1ad));const a337_0x5809=function(_0x4584d4,_0x4e5d45){_0x4584d4=_0x4584d4-0x0;let _0x580953=a337_0x4e5d[_0x4584d4];return _0x580953;};const _0x250449=a337_0x5809;'use strict';const Sequelize=require('sequelize');module['exports']={'name':{'type':Sequelize[_0x250449('0x0')]},'description':{'type':Sequelize[_0x250449('0x0')]}}; \ No newline at end of file +const a337_0x10f6=['exports','STRING'];(function(_0x5e4352,_0x10f6bb){const _0x39b90b=function(_0x488126){while(--_0x488126){_0x5e4352['push'](_0x5e4352['shift']());}};_0x39b90b(++_0x10f6bb);}(a337_0x10f6,0xac));const a337_0x39b9=function(_0x5e4352,_0x10f6bb){_0x5e4352=_0x5e4352-0x0;let _0x39b90b=a337_0x10f6[_0x5e4352];return _0x39b90b;};const _0x28fa30=a337_0x39b9;'use strict';const Sequelize=require('sequelize');module[_0x28fa30('0x0')]={'name':{'type':Sequelize[_0x28fa30('0x1')]},'description':{'type':Sequelize[_0x28fa30('0x1')]}}; \ No newline at end of file diff --git a/server/api/intZendeskConfiguration/intZendeskConfiguration.controller.js b/server/api/intZendeskConfiguration/intZendeskConfiguration.controller.js index e37a76f..450a30b 100644 --- a/server/api/intZendeskConfiguration/intZendeskConfiguration.controller.js +++ b/server/api/intZendeskConfiguration/intZendeskConfiguration.controller.js @@ -1 +1 @@ -const a338_0x5929=['sendStatus','json','send','undefined','length','type','error','query','ids','../../config/logger','sort','params','end','where','offset','getSubjects','status','then','VIRTUAL','limit','show','rows','ZendeskField','merge','body','nolimit','fieldName','Tag','getTags','map','like','getDescriptions','options','include','index','update','setTags','model','attributes','pick','../../components/parsers/qs','sequelize','set','rawAttributes','name','destroy','catch','stack','count','filters','filter','intersection','Content-Range','order','keys','lodash','create','ZendeskConfiguration','findOne','fields','findAll','getFields','includeAll'];(function(_0x4dd2a3,_0x592956){const _0x4f94c7=function(_0x51f02b){while(--_0x51f02b){_0x4dd2a3['push'](_0x4dd2a3['shift']());}};_0x4f94c7(++_0x592956);}(a338_0x5929,0xaa));const a338_0x4f94=function(_0x4dd2a3,_0x592956){_0x4dd2a3=_0x4dd2a3-0x0;let _0x4f94c7=a338_0x5929[_0x4dd2a3];return _0x4f94c7;};const _0xd52586=a338_0x4f94;'use strict';const _=require(_0xd52586('0xb')),qs=require(_0xd52586('0x3b')),logger=require(_0xd52586('0x1c'))('api'),db=require('../../mysqldb')['db'],{Op}=require(_0xd52586('0x3c'));function respondWithResult(_0x51f02b,_0x51a54d){return _0x51a54d=_0x51a54d||0xc8,function(_0x16c395){const _0x1a0030=a338_0x4f94;if(_0x16c395)return _0x51f02b[_0x1a0030('0x23')](_0x51a54d)[_0x1a0030('0x14')](_0x16c395);};}function respondWithFilteredResult(_0x1e30c1,_0xd78dd9){return function(_0x784d3a){const _0x5aba6f=a338_0x4f94;if(_0x784d3a){const _0x4b1cff=_0x784d3a[_0x5aba6f('0x4')],_0x65fd53=_0xd78dd9['offset'];let _0x5c6159=_0xd78dd9['offset']+_0xd78dd9['limit'],_0x2c62c7;return _0x5c6159>=_0x4b1cff?(_0x5c6159=_0x4b1cff,_0x2c62c7=0xc8):_0x2c62c7=0xce,_0x1e30c1[_0x5aba6f('0x23')](_0x2c62c7),_0x1e30c1[_0x5aba6f('0x3d')](_0x5aba6f('0x8'),_0x65fd53+'-'+_0x5c6159+'/'+_0x4b1cff)[_0x5aba6f('0x14')](_0x784d3a);}return null;};}function saveUpdates(_0x55079d){return function(_0x1d1347){const _0x3e20ba=a338_0x4f94;if(_0x1d1347)return _0x1d1347[_0x3e20ba('0x36')](_0x55079d)[_0x3e20ba('0x24')](function(_0x175ad8){return _0x175ad8;});return null;};}function removeEntity(_0x238e42){return function(_0x4df55d){const _0x32f392=a338_0x4f94;if(_0x4df55d)return _0x4df55d[_0x32f392('0x1')]()[_0x32f392('0x24')](function(){const _0x5e3329=_0x32f392;_0x238e42[_0x5e3329('0x23')](0xcc)[_0x5e3329('0x1f')]();});};}function handleEntityNotFound(_0x5a6e2a){return function(_0x308c1d){const _0x5bfd57=a338_0x4f94;return!_0x308c1d&&_0x5a6e2a[_0x5bfd57('0x13')](0x194),_0x308c1d;};}function handleError(_0x4b00b1,_0x3a3bcb){return _0x3a3bcb=_0x3a3bcb||0x1f4,function(_0x3bd5ac){const _0x3bdc12=a338_0x4f94;logger[_0x3bdc12('0x19')](_0x3bd5ac[_0x3bdc12('0x3')]),_0x3bd5ac[_0x3bdc12('0x0')]&&delete _0x3bd5ac[_0x3bdc12('0x0')],_0x4b00b1[_0x3bdc12('0x23')](_0x3a3bcb)[_0x3bdc12('0x15')](_0x3bd5ac);};}exports[_0xd52586('0x35')]=function(_0x2b1bea,_0x2c541a){const _0xc17f66=_0xd52586;let _0x4a1412={};const _0x3c452b={},_0x3f4ada={'count':0x0,'rows':[]},_0x48456d=_[_0xc17f66('0x30')](db[_0xc17f66('0xd')][_0xc17f66('0x3e')],function(_0x5b0ebb){const _0x5e6bd0=_0xc17f66;return{'name':_0x5b0ebb[_0x5e6bd0('0x2d')],'type':_0x5b0ebb[_0x5e6bd0('0x18')]['key']};});_0x3c452b[_0xc17f66('0x38')]=_[_0xc17f66('0x30')](_0x48456d,_0xc17f66('0x0')),_0x3c452b['query']=_['keys'](_0x2b1bea[_0xc17f66('0x1a')]),_0x3c452b[_0xc17f66('0x5')]=_[_0xc17f66('0x7')](_0x3c452b[_0xc17f66('0x38')],_0x3c452b[_0xc17f66('0x1a')]),_0x4a1412['attributes']=_[_0xc17f66('0x7')](_0x3c452b['model'],qs[_0xc17f66('0xf')](_0x2b1bea[_0xc17f66('0x1a')][_0xc17f66('0xf')])),_0x4a1412[_0xc17f66('0x39')]=_0x4a1412[_0xc17f66('0x39')][_0xc17f66('0x17')]?_0x4a1412[_0xc17f66('0x39')]:_0x3c452b[_0xc17f66('0x38')];typeof _0x2b1bea[_0xc17f66('0x1a')][_0xc17f66('0x2c')]===_0xc17f66('0x16')&&(_0x4a1412[_0xc17f66('0x26')]=qs[_0xc17f66('0x26')](_0x2b1bea[_0xc17f66('0x1a')]['limit']),_0x4a1412[_0xc17f66('0x21')]=qs[_0xc17f66('0x21')](_0x2b1bea[_0xc17f66('0x1a')][_0xc17f66('0x21')]));_0x4a1412[_0xc17f66('0x9')]=qs[_0xc17f66('0x1d')](_0x2b1bea[_0xc17f66('0x1a')][_0xc17f66('0x1d')]),_0x4a1412[_0xc17f66('0x20')]=qs[_0xc17f66('0x5')](_[_0xc17f66('0x3a')](_0x2b1bea[_0xc17f66('0x1a')],_0x3c452b[_0xc17f66('0x5')]),_0x48456d);_0x2b1bea[_0xc17f66('0x1a')][_0xc17f66('0x6')]&&(_0x4a1412[_0xc17f66('0x20')]=_['merge'](_0x4a1412[_0xc17f66('0x20')],{[Op['or']]:_[_0xc17f66('0x30')](_0x48456d,function(_0x1b1137){const _0x4ede96=_0xc17f66;if(_0x1b1137[_0x4ede96('0x18')]!==_0x4ede96('0x25')){const _0x3de792={};return _0x3de792[_0x1b1137[_0x4ede96('0x0')]]={[Op[_0x4ede96('0x31')]]:'%'+_0x2b1bea['query'][_0x4ede96('0x6')]+'%'},_0x3de792;}})}));_0x4a1412=_[_0xc17f66('0x2a')]({},_0x4a1412,_0x2b1bea[_0xc17f66('0x33')]);const _0x2c0972={'where':_0x4a1412[_0xc17f66('0x20')]};return db[_0xc17f66('0xd')][_0xc17f66('0x4')](_0x2c0972)[_0xc17f66('0x24')](function(_0x142b87){const _0x1ed756=_0xc17f66;return _0x3f4ada['count']=_0x142b87,_0x2b1bea[_0x1ed756('0x1a')][_0x1ed756('0x12')]&&(_0x4a1412[_0x1ed756('0x34')]=[{'all':!![]}]),db['ZendeskConfiguration'][_0x1ed756('0x10')](_0x4a1412);})['then'](function(_0x63dec3){const _0x5923cf=_0xc17f66;return _0x3f4ada[_0x5923cf('0x28')]=_0x63dec3,_0x3f4ada;})[_0xc17f66('0x24')](respondWithFilteredResult(_0x2c541a,_0x4a1412))[_0xc17f66('0x2')](handleError(_0x2c541a,null));},exports[_0xd52586('0x27')]=function(_0x5ca50f,_0x4e942c){const _0x329436=_0xd52586;let _0x2e0774={'raw':![],'where':{'id':_0x5ca50f[_0x329436('0x1e')]['id']}};const _0x4ae06f={};return _0x4ae06f['model']=_[_0x329436('0xa')](db['ZendeskConfiguration'][_0x329436('0x3e')]),_0x4ae06f[_0x329436('0x1a')]=_[_0x329436('0xa')](_0x5ca50f[_0x329436('0x1a')]),_0x4ae06f[_0x329436('0x5')]=_['intersection'](_0x4ae06f[_0x329436('0x38')],_0x4ae06f[_0x329436('0x1a')]),_0x2e0774[_0x329436('0x39')]=_[_0x329436('0x7')](_0x4ae06f[_0x329436('0x38')],qs[_0x329436('0xf')](_0x5ca50f[_0x329436('0x1a')][_0x329436('0xf')])),_0x2e0774['attributes']=_0x2e0774[_0x329436('0x39')][_0x329436('0x17')]?_0x2e0774[_0x329436('0x39')]:_0x4ae06f[_0x329436('0x38')],_0x5ca50f[_0x329436('0x1a')][_0x329436('0x12')]&&(_0x2e0774['include']=[{'all':!![]}]),_0x2e0774=_['merge']({},_0x2e0774,_0x5ca50f['options']),db[_0x329436('0xd')]['findOne'](_0x2e0774)[_0x329436('0x24')](handleEntityNotFound(_0x4e942c,null))[_0x329436('0x24')](respondWithResult(_0x4e942c,null))[_0x329436('0x2')](handleError(_0x4e942c,null));},exports[_0xd52586('0xc')]=function(_0x26249c,_0x24a068){const _0x17bac0=_0xd52586;return db[_0x17bac0('0xd')]['create'](_0x26249c['body'],{})[_0x17bac0('0x24')](respondWithResult(_0x24a068,0xc9))[_0x17bac0('0x2')](handleError(_0x24a068,null));},exports[_0xd52586('0x36')]=function(_0x1921a6,_0x30e97b){const _0xdb3666=_0xd52586;return _0x1921a6[_0xdb3666('0x2b')]['id']&&delete _0x1921a6[_0xdb3666('0x2b')]['id'],db[_0xdb3666('0xd')][_0xdb3666('0xe')]({'where':{'id':_0x1921a6[_0xdb3666('0x1e')]['id']}})[_0xdb3666('0x24')](handleEntityNotFound(_0x30e97b,null))[_0xdb3666('0x24')](saveUpdates(_0x1921a6[_0xdb3666('0x2b')],null))[_0xdb3666('0x24')](respondWithResult(_0x30e97b,null))[_0xdb3666('0x2')](handleError(_0x30e97b,null));},exports[_0xd52586('0x1')]=function(_0x494e6b,_0x4f325d){const _0x383a32=_0xd52586;return db[_0x383a32('0xd')][_0x383a32('0xe')]({'where':{'id':_0x494e6b[_0x383a32('0x1e')]['id']}})[_0x383a32('0x24')](handleEntityNotFound(_0x4f325d,null))[_0x383a32('0x24')](removeEntity(_0x4f325d,null))[_0x383a32('0x2')](handleError(_0x4f325d,null));},exports['getFields']=function(_0x263e34,_0x5cc266){const _0x479474=_0xd52586;let _0x5e362b={};const _0x39af2f={};let _0xaec017,_0xc94bda;return db[_0x479474('0xd')][_0x479474('0xe')]({'where':{'id':_0x263e34[_0x479474('0x1e')]['id']}})[_0x479474('0x24')](handleEntityNotFound(_0x5cc266,null))[_0x479474('0x24')](function(_0x4558b5){const _0x3e6209=_0x479474;if(_0x4558b5)return _0xaec017=_0x4558b5,_0x39af2f['model']=_['keys'](db[_0x3e6209('0x29')][_0x3e6209('0x3e')]),_0x39af2f['query']=_[_0x3e6209('0xa')](_0x263e34[_0x3e6209('0x1a')]),_0x39af2f['filters']=_[_0x3e6209('0x7')](_0x39af2f[_0x3e6209('0x38')],_0x39af2f[_0x3e6209('0x1a')]),_0x5e362b[_0x3e6209('0x39')]=_['intersection'](_0x39af2f[_0x3e6209('0x38')],qs[_0x3e6209('0xf')](_0x263e34['query'][_0x3e6209('0xf')])),_0x5e362b[_0x3e6209('0x39')]=_0x5e362b[_0x3e6209('0x39')][_0x3e6209('0x17')]?_0x5e362b[_0x3e6209('0x39')]:_0x39af2f[_0x3e6209('0x38')],_0x5e362b['order']=qs[_0x3e6209('0x1d')](_0x263e34[_0x3e6209('0x1a')][_0x3e6209('0x1d')]),_0x5e362b[_0x3e6209('0x20')]=qs['filters'](_['pick'](_0x263e34[_0x3e6209('0x1a')],_0x39af2f[_0x3e6209('0x5')])),_0x263e34[_0x3e6209('0x1a')][_0x3e6209('0x6')]&&(_0x5e362b[_0x3e6209('0x20')]=_[_0x3e6209('0x2a')](_0x5e362b[_0x3e6209('0x20')],{[Op['or']]:_[_0x3e6209('0x30')](_0x5e362b[_0x3e6209('0x39')],function(_0x43f9bc){const _0x148897=_0x3e6209,_0x2b633a={};return _0x2b633a[_0x43f9bc]={[Op['like']]:'%'+_0x263e34['query'][_0x148897('0x6')]+'%'},_0x2b633a;})})),_0x5e362b=_[_0x3e6209('0x2a')]({},_0x5e362b,_0x263e34[_0x3e6209('0x33')]),_0xaec017[_0x3e6209('0x11')](_0x5e362b);})[_0x479474('0x24')](function(_0x49baeb){const _0x4966ab=_0x479474;if(_0x49baeb)return _0xc94bda=_0x49baeb['length'],typeof _0x263e34[_0x4966ab('0x1a')][_0x4966ab('0x2c')]===_0x4966ab('0x16')&&(_0x5e362b['limit']=qs[_0x4966ab('0x26')](_0x263e34['query'][_0x4966ab('0x26')]),_0x5e362b['offset']=qs['offset'](_0x263e34[_0x4966ab('0x1a')][_0x4966ab('0x21')])),_0xaec017[_0x4966ab('0x11')](_0x5e362b);})[_0x479474('0x24')](function(_0x3c350a){if(_0x3c350a)return _0x3c350a?{'count':_0xc94bda,'rows':_0x3c350a}:null;})[_0x479474('0x24')](respondWithResult(_0x5cc266,null))[_0x479474('0x2')](handleError(_0x5cc266,null));},exports[_0xd52586('0x22')]=function(_0x5ae483,_0x26ad1c){const _0x3ef0e2=_0xd52586;let _0x506f67={};const _0xebf1b={};let _0x2c088b,_0x383ffd;return db[_0x3ef0e2('0xd')][_0x3ef0e2('0xe')]({'where':{'id':_0x5ae483[_0x3ef0e2('0x1e')]['id']}})[_0x3ef0e2('0x24')](handleEntityNotFound(_0x26ad1c,null))[_0x3ef0e2('0x24')](function(_0x201f73){const _0x17d033=_0x3ef0e2;if(_0x201f73)return _0x2c088b=_0x201f73,_0xebf1b['model']=_[_0x17d033('0xa')](db[_0x17d033('0x29')][_0x17d033('0x3e')]),_0xebf1b[_0x17d033('0x1a')]=_[_0x17d033('0xa')](_0x5ae483[_0x17d033('0x1a')]),_0xebf1b[_0x17d033('0x5')]=_['intersection'](_0xebf1b[_0x17d033('0x38')],_0xebf1b['query']),_0x506f67['attributes']=_[_0x17d033('0x7')](_0xebf1b[_0x17d033('0x38')],qs[_0x17d033('0xf')](_0x5ae483[_0x17d033('0x1a')][_0x17d033('0xf')])),_0x506f67[_0x17d033('0x39')]=_0x506f67['attributes'][_0x17d033('0x17')]?_0x506f67[_0x17d033('0x39')]:_0xebf1b['model'],_0x506f67[_0x17d033('0x9')]=qs['sort'](_0x5ae483[_0x17d033('0x1a')][_0x17d033('0x1d')]),_0x506f67[_0x17d033('0x20')]=qs[_0x17d033('0x5')](_[_0x17d033('0x3a')](_0x5ae483[_0x17d033('0x1a')],_0xebf1b['filters'])),_0x5ae483['query']['filter']&&(_0x506f67['where']=_[_0x17d033('0x2a')](_0x506f67[_0x17d033('0x20')],{[Op['or']]:_[_0x17d033('0x30')](_0x506f67['attributes'],function(_0x344611){const _0x2b52ae=_0x17d033,_0x1bc7f4={};return _0x1bc7f4[_0x344611]={[Op[_0x2b52ae('0x31')]]:'%'+_0x5ae483[_0x2b52ae('0x1a')][_0x2b52ae('0x6')]+'%'},_0x1bc7f4;})})),_0x506f67=_[_0x17d033('0x2a')]({},_0x506f67,_0x5ae483[_0x17d033('0x33')]),_0x2c088b[_0x17d033('0x22')](_0x506f67);})[_0x3ef0e2('0x24')](function(_0x9ef1f9){const _0x465529=_0x3ef0e2;if(_0x9ef1f9)return _0x383ffd=_0x9ef1f9['length'],typeof _0x5ae483['query']['nolimit']===_0x465529('0x16')&&(_0x506f67[_0x465529('0x26')]=qs['limit'](_0x5ae483[_0x465529('0x1a')][_0x465529('0x26')]),_0x506f67['offset']=qs['offset'](_0x5ae483[_0x465529('0x1a')][_0x465529('0x21')])),_0x2c088b[_0x465529('0x22')](_0x506f67);})[_0x3ef0e2('0x24')](function(_0x48367c){if(_0x48367c)return _0x48367c?{'count':_0x383ffd,'rows':_0x48367c}:null;})['then'](respondWithResult(_0x26ad1c,null))[_0x3ef0e2('0x2')](handleError(_0x26ad1c,null));},exports[_0xd52586('0x32')]=function(_0x52c66e,_0x2608f4){const _0x581856=_0xd52586;let _0x201d10={};const _0x365a59={};let _0x9fcd1d,_0x10794e;return db[_0x581856('0xd')]['findOne']({'where':{'id':_0x52c66e[_0x581856('0x1e')]['id']}})[_0x581856('0x24')](handleEntityNotFound(_0x2608f4,null))[_0x581856('0x24')](function(_0x5972ea){const _0x2bb41d=_0x581856;if(_0x5972ea)return _0x9fcd1d=_0x5972ea,_0x365a59[_0x2bb41d('0x38')]=_['keys'](db[_0x2bb41d('0x29')][_0x2bb41d('0x3e')]),_0x365a59[_0x2bb41d('0x1a')]=_[_0x2bb41d('0xa')](_0x52c66e[_0x2bb41d('0x1a')]),_0x365a59['filters']=_[_0x2bb41d('0x7')](_0x365a59[_0x2bb41d('0x38')],_0x365a59[_0x2bb41d('0x1a')]),_0x201d10['attributes']=_[_0x2bb41d('0x7')](_0x365a59[_0x2bb41d('0x38')],qs[_0x2bb41d('0xf')](_0x52c66e[_0x2bb41d('0x1a')][_0x2bb41d('0xf')])),_0x201d10[_0x2bb41d('0x39')]=_0x201d10[_0x2bb41d('0x39')][_0x2bb41d('0x17')]?_0x201d10[_0x2bb41d('0x39')]:_0x365a59[_0x2bb41d('0x38')],_0x201d10['order']=qs[_0x2bb41d('0x1d')](_0x52c66e[_0x2bb41d('0x1a')][_0x2bb41d('0x1d')]),_0x201d10[_0x2bb41d('0x20')]=qs['filters'](_[_0x2bb41d('0x3a')](_0x52c66e['query'],_0x365a59[_0x2bb41d('0x5')])),_0x52c66e[_0x2bb41d('0x1a')][_0x2bb41d('0x6')]&&(_0x201d10[_0x2bb41d('0x20')]=_['merge'](_0x201d10[_0x2bb41d('0x20')],{[Op['or']]:_['map'](_0x201d10[_0x2bb41d('0x39')],function(_0x1a84ed){const _0x170168=_0x2bb41d,_0x39f2e8={};return _0x39f2e8[_0x1a84ed]={[Op['like']]:'%'+_0x52c66e[_0x170168('0x1a')]['filter']+'%'},_0x39f2e8;})})),_0x201d10=_[_0x2bb41d('0x2a')]({},_0x201d10,_0x52c66e['options']),_0x9fcd1d['getDescriptions'](_0x201d10);})['then'](function(_0xc3f8e3){const _0x100fd1=_0x581856;if(_0xc3f8e3)return _0x10794e=_0xc3f8e3[_0x100fd1('0x17')],typeof _0x52c66e[_0x100fd1('0x1a')]['nolimit']===_0x100fd1('0x16')&&(_0x201d10[_0x100fd1('0x26')]=qs['limit'](_0x52c66e[_0x100fd1('0x1a')]['limit']),_0x201d10[_0x100fd1('0x21')]=qs['offset'](_0x52c66e[_0x100fd1('0x1a')]['offset'])),_0x9fcd1d[_0x100fd1('0x32')](_0x201d10);})[_0x581856('0x24')](function(_0x28c53f){if(_0x28c53f)return _0x28c53f?{'count':_0x10794e,'rows':_0x28c53f}:null;})['then'](respondWithResult(_0x2608f4,null))[_0x581856('0x2')](handleError(_0x2608f4,null));},exports[_0xd52586('0x2f')]=function(_0x2f6706,_0xcfdc67){const _0x5fac57=_0xd52586;let _0x5538f9={};const _0x245d0b={};let _0x306b12,_0x3aef98;return db[_0x5fac57('0xd')][_0x5fac57('0xe')]({'where':{'id':_0x2f6706[_0x5fac57('0x1e')]['id']}})['then'](handleEntityNotFound(_0xcfdc67,null))[_0x5fac57('0x24')](function(_0x6d6f2c){const _0x49fcd1=_0x5fac57;if(_0x6d6f2c)return _0x306b12=_0x6d6f2c,_0x245d0b[_0x49fcd1('0x38')]=_[_0x49fcd1('0xa')](db[_0x49fcd1('0x2e')][_0x49fcd1('0x3e')]),_0x245d0b['query']=_['keys'](_0x2f6706[_0x49fcd1('0x1a')]),_0x245d0b['filters']=_['intersection'](_0x245d0b[_0x49fcd1('0x38')],_0x245d0b[_0x49fcd1('0x1a')]),_0x5538f9[_0x49fcd1('0x39')]=_['intersection'](_0x245d0b['model'],qs[_0x49fcd1('0xf')](_0x2f6706[_0x49fcd1('0x1a')][_0x49fcd1('0xf')])),_0x5538f9[_0x49fcd1('0x39')]=_0x5538f9[_0x49fcd1('0x39')]['length']?_0x5538f9['attributes']:_0x245d0b[_0x49fcd1('0x38')],_0x5538f9[_0x49fcd1('0x9')]=qs['sort'](_0x2f6706['query']['sort']),_0x5538f9[_0x49fcd1('0x20')]=qs['filters'](_[_0x49fcd1('0x3a')](_0x2f6706[_0x49fcd1('0x1a')],_0x245d0b[_0x49fcd1('0x5')])),_0x2f6706['query']['filter']&&(_0x5538f9[_0x49fcd1('0x20')]=_[_0x49fcd1('0x2a')](_0x5538f9[_0x49fcd1('0x20')],{[Op['or']]:_[_0x49fcd1('0x30')](_0x5538f9[_0x49fcd1('0x39')],function(_0x1332d7){const _0x1eb4e7=_0x49fcd1,_0x5ea231={};return _0x5ea231[_0x1332d7]={[Op[_0x1eb4e7('0x31')]]:'%'+_0x2f6706[_0x1eb4e7('0x1a')][_0x1eb4e7('0x6')]+'%'},_0x5ea231;})})),_0x5538f9=_['merge']({},_0x5538f9,_0x2f6706[_0x49fcd1('0x33')]),_0x306b12[_0x49fcd1('0x2f')](_0x5538f9);})['then'](function(_0x334c43){const _0x485e42=_0x5fac57;if(_0x334c43)return _0x3aef98=_0x334c43[_0x485e42('0x17')],typeof _0x2f6706[_0x485e42('0x1a')][_0x485e42('0x2c')]==='undefined'&&(_0x5538f9['limit']=qs['limit'](_0x2f6706['query']['limit']),_0x5538f9[_0x485e42('0x21')]=qs[_0x485e42('0x21')](_0x2f6706[_0x485e42('0x1a')][_0x485e42('0x21')])),_0x306b12['getTags'](_0x5538f9);})[_0x5fac57('0x24')](function(_0x1b79e0){if(_0x1b79e0)return _0x1b79e0?{'count':_0x3aef98,'rows':_0x1b79e0}:null;})[_0x5fac57('0x24')](respondWithResult(_0xcfdc67,null))[_0x5fac57('0x2')](handleError(_0xcfdc67,null));},exports[_0xd52586('0x37')]=function(_0x51548f,_0x38296b){const _0x60d22=_0xd52586;return _0x51548f[_0x60d22('0x2b')]['id']&&delete _0x51548f[_0x60d22('0x2b')]['id'],db[_0x60d22('0xd')][_0x60d22('0xe')]({'where':{'id':_0x51548f[_0x60d22('0x1e')]['id']}})[_0x60d22('0x24')](handleEntityNotFound(_0x38296b,null))[_0x60d22('0x24')](function(_0x4eb000){const _0x47e21b=_0x60d22;if(_0x4eb000)return _0x4eb000[_0x47e21b('0x37')](_0x51548f[_0x47e21b('0x2b')][_0x47e21b('0x1b')]||[]);return null;})[_0x60d22('0x24')](respondWithResult(_0x38296b,null))[_0x60d22('0x2')](handleError(_0x38296b,null));}; \ No newline at end of file +const a338_0x5df6=['body','status','sort','error','filters','attributes','query','like','send','catch','show','fields','name','keys','params','includeAll','index','create','key','api','undefined','ZendeskField','merge','getTags','end','offset','intersection','set','pick','rows','ZendeskConfiguration','options','findOne','ids','stack','getDescriptions','setTags','order','fieldName','count','limit','json','nolimit','length','map','../../components/parsers/qs','filter','where','then','../../config/logger','getSubjects','model','update','type','rawAttributes','getFields','lodash'];(function(_0x37615e,_0x5df68b){const _0x25900f=function(_0x421d37){while(--_0x421d37){_0x37615e['push'](_0x37615e['shift']());}};_0x25900f(++_0x5df68b);}(a338_0x5df6,0x1f4));const a338_0x2590=function(_0x37615e,_0x5df68b){_0x37615e=_0x37615e-0x0;let _0x25900f=a338_0x5df6[_0x37615e];return _0x25900f;};const _0x23b449=a338_0x2590;'use strict';const _=require(_0x23b449('0xc')),qs=require(_0x23b449('0x1')),logger=require(_0x23b449('0x5'))(_0x23b449('0x20')),db=require('../../mysqldb')['db'],{Op}=require('sequelize');function respondWithResult(_0x421d37,_0x51a3b2){return _0x51a3b2=_0x51a3b2||0xc8,function(_0x1c95aa){if(_0x1c95aa)return _0x421d37['status'](_0x51a3b2)['json'](_0x1c95aa);};}function respondWithFilteredResult(_0x75d86e,_0x20dbf0){return function(_0x559f27){const _0x544a73=a338_0x2590;if(_0x559f27){const _0x7fe302=_0x559f27[_0x544a73('0x34')],_0x2638eb=_0x20dbf0['offset'];let _0x452b18=_0x20dbf0[_0x544a73('0x26')]+_0x20dbf0[_0x544a73('0x35')],_0x447dd3;return _0x452b18>=_0x7fe302?(_0x452b18=_0x7fe302,_0x447dd3=0xc8):_0x447dd3=0xce,_0x75d86e[_0x544a73('0xe')](_0x447dd3),_0x75d86e[_0x544a73('0x28')]('Content-Range',_0x2638eb+'-'+_0x452b18+'/'+_0x7fe302)[_0x544a73('0x36')](_0x559f27);}return null;};}function saveUpdates(_0x37ebc9){return function(_0x364c5b){const _0x4ea762=a338_0x2590;if(_0x364c5b)return _0x364c5b[_0x4ea762('0x8')](_0x37ebc9)[_0x4ea762('0x4')](function(_0x6bd6f0){return _0x6bd6f0;});return null;};}function removeEntity(_0x20c912){return function(_0x251845){const _0x398a6f=a338_0x2590;if(_0x251845)return _0x251845['destroy']()[_0x398a6f('0x4')](function(){const _0xc6eb39=_0x398a6f;_0x20c912[_0xc6eb39('0xe')](0xcc)[_0xc6eb39('0x25')]();});};}function handleEntityNotFound(_0x551167){return function(_0x510965){return!_0x510965&&_0x551167['sendStatus'](0x194),_0x510965;};}function handleError(_0x13c1b9,_0x578399){return _0x578399=_0x578399||0x1f4,function(_0x1059c8){const _0x4855e5=a338_0x2590;logger[_0x4855e5('0x10')](_0x1059c8[_0x4855e5('0x2f')]),_0x1059c8[_0x4855e5('0x19')]&&delete _0x1059c8[_0x4855e5('0x19')],_0x13c1b9[_0x4855e5('0xe')](_0x578399)[_0x4855e5('0x15')](_0x1059c8);};}exports[_0x23b449('0x1d')]=function(_0x440842,_0x542999){const _0x715cf8=_0x23b449;let _0x461200={};const _0x5d511c={},_0xef802={'count':0x0,'rows':[]},_0x491535=_['map'](db[_0x715cf8('0x2b')]['rawAttributes'],function(_0x185fa4){const _0x1b2d82=_0x715cf8;return{'name':_0x185fa4[_0x1b2d82('0x33')],'type':_0x185fa4[_0x1b2d82('0x9')][_0x1b2d82('0x1f')]};});_0x5d511c[_0x715cf8('0x7')]=_[_0x715cf8('0x0')](_0x491535,'name'),_0x5d511c[_0x715cf8('0x13')]=_[_0x715cf8('0x1a')](_0x440842[_0x715cf8('0x13')]),_0x5d511c[_0x715cf8('0x11')]=_[_0x715cf8('0x27')](_0x5d511c['model'],_0x5d511c[_0x715cf8('0x13')]),_0x461200[_0x715cf8('0x12')]=_[_0x715cf8('0x27')](_0x5d511c['model'],qs[_0x715cf8('0x18')](_0x440842['query'][_0x715cf8('0x18')])),_0x461200[_0x715cf8('0x12')]=_0x461200[_0x715cf8('0x12')][_0x715cf8('0x38')]?_0x461200['attributes']:_0x5d511c['model'];typeof _0x440842['query'][_0x715cf8('0x37')]===_0x715cf8('0x21')&&(_0x461200['limit']=qs[_0x715cf8('0x35')](_0x440842[_0x715cf8('0x13')]['limit']),_0x461200[_0x715cf8('0x26')]=qs[_0x715cf8('0x26')](_0x440842['query'][_0x715cf8('0x26')]));_0x461200[_0x715cf8('0x32')]=qs[_0x715cf8('0xf')](_0x440842[_0x715cf8('0x13')][_0x715cf8('0xf')]),_0x461200['where']=qs[_0x715cf8('0x11')](_[_0x715cf8('0x29')](_0x440842[_0x715cf8('0x13')],_0x5d511c[_0x715cf8('0x11')]),_0x491535);_0x440842[_0x715cf8('0x13')][_0x715cf8('0x2')]&&(_0x461200[_0x715cf8('0x3')]=_['merge'](_0x461200[_0x715cf8('0x3')],{[Op['or']]:_[_0x715cf8('0x0')](_0x491535,function(_0x224a9f){const _0x3e9f38=_0x715cf8;if(_0x224a9f[_0x3e9f38('0x9')]!=='VIRTUAL'){const _0x113eb6={};return _0x113eb6[_0x224a9f[_0x3e9f38('0x19')]]={[Op[_0x3e9f38('0x14')]]:'%'+_0x440842[_0x3e9f38('0x13')]['filter']+'%'},_0x113eb6;}})}));_0x461200=_[_0x715cf8('0x23')]({},_0x461200,_0x440842[_0x715cf8('0x2c')]);const _0x40af24={'where':_0x461200[_0x715cf8('0x3')]};return db['ZendeskConfiguration'][_0x715cf8('0x34')](_0x40af24)[_0x715cf8('0x4')](function(_0x2a67e6){const _0x45c418=_0x715cf8;return _0xef802[_0x45c418('0x34')]=_0x2a67e6,_0x440842['query'][_0x45c418('0x1c')]&&(_0x461200['include']=[{'all':!![]}]),db[_0x45c418('0x2b')]['findAll'](_0x461200);})['then'](function(_0x1744b6){const _0x575eb6=_0x715cf8;return _0xef802[_0x575eb6('0x2a')]=_0x1744b6,_0xef802;})['then'](respondWithFilteredResult(_0x542999,_0x461200))[_0x715cf8('0x16')](handleError(_0x542999,null));},exports[_0x23b449('0x17')]=function(_0x37a126,_0x106ac2){const _0x46acce=_0x23b449;let _0x3602b5={'raw':![],'where':{'id':_0x37a126[_0x46acce('0x1b')]['id']}};const _0x2f237f={};return _0x2f237f[_0x46acce('0x7')]=_['keys'](db[_0x46acce('0x2b')][_0x46acce('0xa')]),_0x2f237f[_0x46acce('0x13')]=_['keys'](_0x37a126[_0x46acce('0x13')]),_0x2f237f[_0x46acce('0x11')]=_[_0x46acce('0x27')](_0x2f237f['model'],_0x2f237f[_0x46acce('0x13')]),_0x3602b5[_0x46acce('0x12')]=_[_0x46acce('0x27')](_0x2f237f[_0x46acce('0x7')],qs['fields'](_0x37a126[_0x46acce('0x13')][_0x46acce('0x18')])),_0x3602b5[_0x46acce('0x12')]=_0x3602b5[_0x46acce('0x12')]['length']?_0x3602b5[_0x46acce('0x12')]:_0x2f237f[_0x46acce('0x7')],_0x37a126[_0x46acce('0x13')][_0x46acce('0x1c')]&&(_0x3602b5['include']=[{'all':!![]}]),_0x3602b5=_[_0x46acce('0x23')]({},_0x3602b5,_0x37a126['options']),db['ZendeskConfiguration']['findOne'](_0x3602b5)['then'](handleEntityNotFound(_0x106ac2,null))['then'](respondWithResult(_0x106ac2,null))[_0x46acce('0x16')](handleError(_0x106ac2,null));},exports[_0x23b449('0x1e')]=function(_0x4eee64,_0x47d331){const _0x5daa4d=_0x23b449;return db[_0x5daa4d('0x2b')]['create'](_0x4eee64[_0x5daa4d('0xd')],{})[_0x5daa4d('0x4')](respondWithResult(_0x47d331,0xc9))[_0x5daa4d('0x16')](handleError(_0x47d331,null));},exports[_0x23b449('0x8')]=function(_0x3ac296,_0x3b10e5){const _0x1ab48d=_0x23b449;return _0x3ac296[_0x1ab48d('0xd')]['id']&&delete _0x3ac296[_0x1ab48d('0xd')]['id'],db[_0x1ab48d('0x2b')]['findOne']({'where':{'id':_0x3ac296[_0x1ab48d('0x1b')]['id']}})['then'](handleEntityNotFound(_0x3b10e5,null))['then'](saveUpdates(_0x3ac296[_0x1ab48d('0xd')],null))[_0x1ab48d('0x4')](respondWithResult(_0x3b10e5,null))['catch'](handleError(_0x3b10e5,null));},exports['destroy']=function(_0x4e1ada,_0xf7ec66){const _0x28acad=_0x23b449;return db[_0x28acad('0x2b')][_0x28acad('0x2d')]({'where':{'id':_0x4e1ada[_0x28acad('0x1b')]['id']}})[_0x28acad('0x4')](handleEntityNotFound(_0xf7ec66,null))[_0x28acad('0x4')](removeEntity(_0xf7ec66,null))['catch'](handleError(_0xf7ec66,null));},exports[_0x23b449('0xb')]=function(_0x125b00,_0x20050f){const _0x3c9c14=_0x23b449;let _0x5edbae={};const _0x5668d1={};let _0x46289e,_0x17a8b8;return db[_0x3c9c14('0x2b')][_0x3c9c14('0x2d')]({'where':{'id':_0x125b00['params']['id']}})['then'](handleEntityNotFound(_0x20050f,null))[_0x3c9c14('0x4')](function(_0x552c77){const _0x3bcd9a=_0x3c9c14;if(_0x552c77)return _0x46289e=_0x552c77,_0x5668d1['model']=_[_0x3bcd9a('0x1a')](db[_0x3bcd9a('0x22')][_0x3bcd9a('0xa')]),_0x5668d1[_0x3bcd9a('0x13')]=_[_0x3bcd9a('0x1a')](_0x125b00['query']),_0x5668d1['filters']=_[_0x3bcd9a('0x27')](_0x5668d1[_0x3bcd9a('0x7')],_0x5668d1[_0x3bcd9a('0x13')]),_0x5edbae[_0x3bcd9a('0x12')]=_['intersection'](_0x5668d1[_0x3bcd9a('0x7')],qs['fields'](_0x125b00['query'][_0x3bcd9a('0x18')])),_0x5edbae['attributes']=_0x5edbae[_0x3bcd9a('0x12')]['length']?_0x5edbae[_0x3bcd9a('0x12')]:_0x5668d1[_0x3bcd9a('0x7')],_0x5edbae[_0x3bcd9a('0x32')]=qs[_0x3bcd9a('0xf')](_0x125b00[_0x3bcd9a('0x13')][_0x3bcd9a('0xf')]),_0x5edbae[_0x3bcd9a('0x3')]=qs[_0x3bcd9a('0x11')](_[_0x3bcd9a('0x29')](_0x125b00['query'],_0x5668d1['filters'])),_0x125b00[_0x3bcd9a('0x13')][_0x3bcd9a('0x2')]&&(_0x5edbae[_0x3bcd9a('0x3')]=_[_0x3bcd9a('0x23')](_0x5edbae['where'],{[Op['or']]:_['map'](_0x5edbae['attributes'],function(_0x29b1e0){const _0x538179=_0x3bcd9a,_0x2c49f6={};return _0x2c49f6[_0x29b1e0]={[Op['like']]:'%'+_0x125b00['query'][_0x538179('0x2')]+'%'},_0x2c49f6;})})),_0x5edbae=_['merge']({},_0x5edbae,_0x125b00[_0x3bcd9a('0x2c')]),_0x46289e[_0x3bcd9a('0xb')](_0x5edbae);})[_0x3c9c14('0x4')](function(_0x33eec8){const _0x2fb71b=_0x3c9c14;if(_0x33eec8)return _0x17a8b8=_0x33eec8[_0x2fb71b('0x38')],typeof _0x125b00[_0x2fb71b('0x13')][_0x2fb71b('0x37')]===_0x2fb71b('0x21')&&(_0x5edbae['limit']=qs[_0x2fb71b('0x35')](_0x125b00['query'][_0x2fb71b('0x35')]),_0x5edbae[_0x2fb71b('0x26')]=qs[_0x2fb71b('0x26')](_0x125b00[_0x2fb71b('0x13')][_0x2fb71b('0x26')])),_0x46289e[_0x2fb71b('0xb')](_0x5edbae);})[_0x3c9c14('0x4')](function(_0x3fd1b3){if(_0x3fd1b3)return _0x3fd1b3?{'count':_0x17a8b8,'rows':_0x3fd1b3}:null;})[_0x3c9c14('0x4')](respondWithResult(_0x20050f,null))[_0x3c9c14('0x16')](handleError(_0x20050f,null));},exports[_0x23b449('0x6')]=function(_0x142af6,_0x52365f){const _0x528ee6=_0x23b449;let _0x29a57f={};const _0x52212b={};let _0x4dd002,_0x523112;return db[_0x528ee6('0x2b')][_0x528ee6('0x2d')]({'where':{'id':_0x142af6[_0x528ee6('0x1b')]['id']}})[_0x528ee6('0x4')](handleEntityNotFound(_0x52365f,null))[_0x528ee6('0x4')](function(_0x41b2ba){const _0x4d9684=_0x528ee6;if(_0x41b2ba)return _0x4dd002=_0x41b2ba,_0x52212b['model']=_['keys'](db['ZendeskField'][_0x4d9684('0xa')]),_0x52212b[_0x4d9684('0x13')]=_[_0x4d9684('0x1a')](_0x142af6[_0x4d9684('0x13')]),_0x52212b[_0x4d9684('0x11')]=_[_0x4d9684('0x27')](_0x52212b[_0x4d9684('0x7')],_0x52212b[_0x4d9684('0x13')]),_0x29a57f['attributes']=_[_0x4d9684('0x27')](_0x52212b[_0x4d9684('0x7')],qs[_0x4d9684('0x18')](_0x142af6[_0x4d9684('0x13')]['fields'])),_0x29a57f[_0x4d9684('0x12')]=_0x29a57f['attributes'][_0x4d9684('0x38')]?_0x29a57f[_0x4d9684('0x12')]:_0x52212b[_0x4d9684('0x7')],_0x29a57f[_0x4d9684('0x32')]=qs[_0x4d9684('0xf')](_0x142af6[_0x4d9684('0x13')][_0x4d9684('0xf')]),_0x29a57f['where']=qs[_0x4d9684('0x11')](_[_0x4d9684('0x29')](_0x142af6[_0x4d9684('0x13')],_0x52212b[_0x4d9684('0x11')])),_0x142af6[_0x4d9684('0x13')]['filter']&&(_0x29a57f['where']=_[_0x4d9684('0x23')](_0x29a57f[_0x4d9684('0x3')],{[Op['or']]:_['map'](_0x29a57f[_0x4d9684('0x12')],function(_0x56bccd){const _0x3f298d=_0x4d9684,_0x1a24bc={};return _0x1a24bc[_0x56bccd]={[Op['like']]:'%'+_0x142af6[_0x3f298d('0x13')][_0x3f298d('0x2')]+'%'},_0x1a24bc;})})),_0x29a57f=_[_0x4d9684('0x23')]({},_0x29a57f,_0x142af6['options']),_0x4dd002[_0x4d9684('0x6')](_0x29a57f);})[_0x528ee6('0x4')](function(_0x5db12f){const _0x525d47=_0x528ee6;if(_0x5db12f)return _0x523112=_0x5db12f[_0x525d47('0x38')],typeof _0x142af6[_0x525d47('0x13')]['nolimit']===_0x525d47('0x21')&&(_0x29a57f['limit']=qs[_0x525d47('0x35')](_0x142af6[_0x525d47('0x13')][_0x525d47('0x35')]),_0x29a57f['offset']=qs['offset'](_0x142af6['query']['offset'])),_0x4dd002['getSubjects'](_0x29a57f);})[_0x528ee6('0x4')](function(_0x5a6534){if(_0x5a6534)return _0x5a6534?{'count':_0x523112,'rows':_0x5a6534}:null;})[_0x528ee6('0x4')](respondWithResult(_0x52365f,null))[_0x528ee6('0x16')](handleError(_0x52365f,null));},exports[_0x23b449('0x30')]=function(_0x373aa7,_0x3c3b50){const _0x58eaf1=_0x23b449;let _0x44f07a={};const _0x43d11f={};let _0x1cccf4,_0x48ff32;return db[_0x58eaf1('0x2b')][_0x58eaf1('0x2d')]({'where':{'id':_0x373aa7['params']['id']}})[_0x58eaf1('0x4')](handleEntityNotFound(_0x3c3b50,null))[_0x58eaf1('0x4')](function(_0x6a7448){const _0x3a3384=_0x58eaf1;if(_0x6a7448)return _0x1cccf4=_0x6a7448,_0x43d11f[_0x3a3384('0x7')]=_['keys'](db[_0x3a3384('0x22')]['rawAttributes']),_0x43d11f[_0x3a3384('0x13')]=_[_0x3a3384('0x1a')](_0x373aa7[_0x3a3384('0x13')]),_0x43d11f[_0x3a3384('0x11')]=_[_0x3a3384('0x27')](_0x43d11f['model'],_0x43d11f[_0x3a3384('0x13')]),_0x44f07a['attributes']=_[_0x3a3384('0x27')](_0x43d11f['model'],qs[_0x3a3384('0x18')](_0x373aa7['query'][_0x3a3384('0x18')])),_0x44f07a[_0x3a3384('0x12')]=_0x44f07a[_0x3a3384('0x12')][_0x3a3384('0x38')]?_0x44f07a['attributes']:_0x43d11f[_0x3a3384('0x7')],_0x44f07a[_0x3a3384('0x32')]=qs[_0x3a3384('0xf')](_0x373aa7['query'][_0x3a3384('0xf')]),_0x44f07a[_0x3a3384('0x3')]=qs['filters'](_['pick'](_0x373aa7['query'],_0x43d11f[_0x3a3384('0x11')])),_0x373aa7[_0x3a3384('0x13')][_0x3a3384('0x2')]&&(_0x44f07a[_0x3a3384('0x3')]=_[_0x3a3384('0x23')](_0x44f07a[_0x3a3384('0x3')],{[Op['or']]:_[_0x3a3384('0x0')](_0x44f07a[_0x3a3384('0x12')],function(_0x3b838f){const _0x2d9609=_0x3a3384,_0x1698d2={};return _0x1698d2[_0x3b838f]={[Op[_0x2d9609('0x14')]]:'%'+_0x373aa7['query']['filter']+'%'},_0x1698d2;})})),_0x44f07a=_[_0x3a3384('0x23')]({},_0x44f07a,_0x373aa7[_0x3a3384('0x2c')]),_0x1cccf4[_0x3a3384('0x30')](_0x44f07a);})[_0x58eaf1('0x4')](function(_0x39cb6a){const _0x4b3a3e=_0x58eaf1;if(_0x39cb6a)return _0x48ff32=_0x39cb6a[_0x4b3a3e('0x38')],typeof _0x373aa7[_0x4b3a3e('0x13')][_0x4b3a3e('0x37')]===_0x4b3a3e('0x21')&&(_0x44f07a[_0x4b3a3e('0x35')]=qs[_0x4b3a3e('0x35')](_0x373aa7[_0x4b3a3e('0x13')][_0x4b3a3e('0x35')]),_0x44f07a[_0x4b3a3e('0x26')]=qs[_0x4b3a3e('0x26')](_0x373aa7[_0x4b3a3e('0x13')][_0x4b3a3e('0x26')])),_0x1cccf4['getDescriptions'](_0x44f07a);})[_0x58eaf1('0x4')](function(_0x5d2e15){if(_0x5d2e15)return _0x5d2e15?{'count':_0x48ff32,'rows':_0x5d2e15}:null;})[_0x58eaf1('0x4')](respondWithResult(_0x3c3b50,null))['catch'](handleError(_0x3c3b50,null));},exports['getTags']=function(_0x1b449e,_0x3af3a1){const _0xb6bf9=_0x23b449;let _0x51ef13={};const _0x35891a={};let _0x3fbdc3,_0x3931d8;return db[_0xb6bf9('0x2b')]['findOne']({'where':{'id':_0x1b449e[_0xb6bf9('0x1b')]['id']}})[_0xb6bf9('0x4')](handleEntityNotFound(_0x3af3a1,null))[_0xb6bf9('0x4')](function(_0x4ea23d){const _0x3067d8=_0xb6bf9;if(_0x4ea23d)return _0x3fbdc3=_0x4ea23d,_0x35891a[_0x3067d8('0x7')]=_[_0x3067d8('0x1a')](db['Tag'][_0x3067d8('0xa')]),_0x35891a['query']=_[_0x3067d8('0x1a')](_0x1b449e[_0x3067d8('0x13')]),_0x35891a[_0x3067d8('0x11')]=_[_0x3067d8('0x27')](_0x35891a[_0x3067d8('0x7')],_0x35891a[_0x3067d8('0x13')]),_0x51ef13['attributes']=_[_0x3067d8('0x27')](_0x35891a[_0x3067d8('0x7')],qs[_0x3067d8('0x18')](_0x1b449e[_0x3067d8('0x13')][_0x3067d8('0x18')])),_0x51ef13[_0x3067d8('0x12')]=_0x51ef13[_0x3067d8('0x12')]['length']?_0x51ef13[_0x3067d8('0x12')]:_0x35891a[_0x3067d8('0x7')],_0x51ef13['order']=qs[_0x3067d8('0xf')](_0x1b449e[_0x3067d8('0x13')][_0x3067d8('0xf')]),_0x51ef13['where']=qs[_0x3067d8('0x11')](_[_0x3067d8('0x29')](_0x1b449e[_0x3067d8('0x13')],_0x35891a['filters'])),_0x1b449e[_0x3067d8('0x13')]['filter']&&(_0x51ef13[_0x3067d8('0x3')]=_['merge'](_0x51ef13[_0x3067d8('0x3')],{[Op['or']]:_['map'](_0x51ef13[_0x3067d8('0x12')],function(_0x53b3db){const _0x5ca90c=_0x3067d8,_0x2cacfe={};return _0x2cacfe[_0x53b3db]={[Op['like']]:'%'+_0x1b449e[_0x5ca90c('0x13')][_0x5ca90c('0x2')]+'%'},_0x2cacfe;})})),_0x51ef13=_['merge']({},_0x51ef13,_0x1b449e['options']),_0x3fbdc3[_0x3067d8('0x24')](_0x51ef13);})[_0xb6bf9('0x4')](function(_0x26554b){const _0x36639b=_0xb6bf9;if(_0x26554b)return _0x3931d8=_0x26554b['length'],typeof _0x1b449e[_0x36639b('0x13')][_0x36639b('0x37')]===_0x36639b('0x21')&&(_0x51ef13['limit']=qs[_0x36639b('0x35')](_0x1b449e[_0x36639b('0x13')]['limit']),_0x51ef13['offset']=qs[_0x36639b('0x26')](_0x1b449e[_0x36639b('0x13')][_0x36639b('0x26')])),_0x3fbdc3[_0x36639b('0x24')](_0x51ef13);})[_0xb6bf9('0x4')](function(_0x32fabc){if(_0x32fabc)return _0x32fabc?{'count':_0x3931d8,'rows':_0x32fabc}:null;})['then'](respondWithResult(_0x3af3a1,null))[_0xb6bf9('0x16')](handleError(_0x3af3a1,null));},exports[_0x23b449('0x31')]=function(_0x1ba6c9,_0x4494c0){const _0x1dc85d=_0x23b449;return _0x1ba6c9[_0x1dc85d('0xd')]['id']&&delete _0x1ba6c9[_0x1dc85d('0xd')]['id'],db['ZendeskConfiguration'][_0x1dc85d('0x2d')]({'where':{'id':_0x1ba6c9[_0x1dc85d('0x1b')]['id']}})[_0x1dc85d('0x4')](handleEntityNotFound(_0x4494c0,null))[_0x1dc85d('0x4')](function(_0x3c5c0c){const _0x9d80d7=_0x1dc85d;if(_0x3c5c0c)return _0x3c5c0c[_0x9d80d7('0x31')](_0x1ba6c9[_0x9d80d7('0xd')][_0x9d80d7('0x2e')]||[]);return null;})[_0x1dc85d('0x4')](respondWithResult(_0x4494c0,null))[_0x1dc85d('0x16')](handleError(_0x4494c0,null));}; \ No newline at end of file diff --git a/server/api/intZendeskConfiguration/intZendeskConfiguration.model.js b/server/api/intZendeskConfiguration/intZendeskConfiguration.model.js index 581fd7c..b2eab48 100644 --- a/server/api/intZendeskConfiguration/intZendeskConfiguration.model.js +++ b/server/api/intZendeskConfiguration/intZendeskConfiguration.model.js @@ -1 +1 @@ -const a339_0x3fb3=['int_zendesk_configurations','define'];(function(_0xf54702,_0x3fb310){const _0x175575=function(_0x49929b){while(--_0x49929b){_0xf54702['push'](_0xf54702['shift']());}};_0x175575(++_0x3fb310);}(a339_0x3fb3,0x154));const a339_0x1755=function(_0xf54702,_0x3fb310){_0xf54702=_0xf54702-0x0;let _0x175575=a339_0x3fb3[_0xf54702];return _0x175575;};'use strict';const attributes=require('./intZendeskConfiguration.attributes');module['exports']=function(_0x49929b){const _0xb5c414=a339_0x1755,_0x1548d8=_0x49929b[_0xb5c414('0x1')]('ZendeskConfiguration',attributes,{'tableName':_0xb5c414('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1548d8;}; \ No newline at end of file +const a339_0x2770=['int_zendesk_configurations','exports','ZendeskConfiguration','./intZendeskConfiguration.attributes'];(function(_0x11d350,_0x2770f2){const _0x5d9f2f=function(_0x133854){while(--_0x133854){_0x11d350['push'](_0x11d350['shift']());}};_0x5d9f2f(++_0x2770f2);}(a339_0x2770,0xce));const a339_0x5d9f=function(_0x11d350,_0x2770f2){_0x11d350=_0x11d350-0x0;let _0x5d9f2f=a339_0x2770[_0x11d350];return _0x5d9f2f;};const _0x306d7e=a339_0x5d9f;'use strict';const attributes=require(_0x306d7e('0x1'));module[_0x306d7e('0x3')]=function(_0x133854){const _0x1e5e63=_0x306d7e,_0x2b4e6a=_0x133854['define'](_0x1e5e63('0x0'),attributes,{'tableName':_0x1e5e63('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2b4e6a;}; \ No newline at end of file diff --git a/server/api/intZendeskField/index.js b/server/api/intZendeskField/index.js index 6798cba..b477bdf 100644 --- a/server/api/intZendeskField/index.js +++ b/server/api/intZendeskField/index.js @@ -1 +1 @@ -const a340_0x58fa=['../../components/auth/service','create','update','get','post','put','/:id','express','./intZendeskField.controller','delete','exports','destroy','isAuthenticated','Router'];(function(_0x3632a9,_0x58faa4){const _0xe0aaa5=function(_0x128c49){while(--_0x128c49){_0x3632a9['push'](_0x3632a9['shift']());}};_0xe0aaa5(++_0x58faa4);}(a340_0x58fa,0xfd));const a340_0xe0aa=function(_0x3632a9,_0x58faa4){_0x3632a9=_0x3632a9-0x0;let _0xe0aaa5=a340_0x58fa[_0x3632a9];return _0xe0aaa5;};const _0x9a5ae1=a340_0xe0aa;'use strict';const express=require(_0x9a5ae1('0x6')),router=express[_0x9a5ae1('0xc')](),auth=require(_0x9a5ae1('0xd')),controller=require(_0x9a5ae1('0x7'));router[_0x9a5ae1('0x2')]('/',auth[_0x9a5ae1('0xb')](),controller['index']),router[_0x9a5ae1('0x2')]('/:id',auth[_0x9a5ae1('0xb')](),controller['show']),router[_0x9a5ae1('0x3')]('/',auth[_0x9a5ae1('0xb')](),controller[_0x9a5ae1('0x0')]),router[_0x9a5ae1('0x4')](_0x9a5ae1('0x5'),auth['isAuthenticated'](),controller[_0x9a5ae1('0x1')]),router[_0x9a5ae1('0x8')](_0x9a5ae1('0x5'),auth[_0x9a5ae1('0xb')](),controller[_0x9a5ae1('0xa')]),module[_0x9a5ae1('0x9')]=router; \ No newline at end of file +const a340_0xe7e7=['destroy','exports','/:id','isAuthenticated','../../components/auth/service','get','post','express','delete','Router','./intZendeskField.controller','show','create','put','update'];(function(_0xb601c4,_0xe7e7f7){const _0x3eea52=function(_0x2f1b0e){while(--_0x2f1b0e){_0xb601c4['push'](_0xb601c4['shift']());}};_0x3eea52(++_0xe7e7f7);}(a340_0xe7e7,0x181));const a340_0x3eea=function(_0xb601c4,_0xe7e7f7){_0xb601c4=_0xb601c4-0x0;let _0x3eea52=a340_0xe7e7[_0xb601c4];return _0x3eea52;};const _0x142303=a340_0x3eea;'use strict';const express=require(_0x142303('0xc')),router=express[_0x142303('0xe')](),auth=require(_0x142303('0x9')),controller=require(_0x142303('0x0'));router[_0x142303('0xa')]('/',auth[_0x142303('0x8')](),controller['index']),router[_0x142303('0xa')]('/:id',auth[_0x142303('0x8')](),controller[_0x142303('0x1')]),router[_0x142303('0xb')]('/',auth[_0x142303('0x8')](),controller[_0x142303('0x2')]),router[_0x142303('0x3')](_0x142303('0x7'),auth[_0x142303('0x8')](),controller[_0x142303('0x4')]),router[_0x142303('0xd')](_0x142303('0x7'),auth[_0x142303('0x8')](),controller[_0x142303('0x5')]),module[_0x142303('0x6')]=router; \ No newline at end of file diff --git a/server/api/intZendeskField/intZendeskField.attributes.js b/server/api/intZendeskField/intZendeskField.attributes.js index ca7ee38..a2c11e6 100644 --- a/server/api/intZendeskField/intZendeskField.attributes.js +++ b/server/api/intZendeskField/intZendeskField.attributes.js @@ -1 +1 @@ -const a341_0x3562=['sequelize','ENUM','STRING','customVariable','exports','string','keyValue'];(function(_0x17e534,_0x356221){const _0x36bc4f=function(_0x10352b){while(--_0x10352b){_0x17e534['push'](_0x17e534['shift']());}};_0x36bc4f(++_0x356221);}(a341_0x3562,0x144));const a341_0x36bc=function(_0x17e534,_0x356221){_0x17e534=_0x17e534-0x0;let _0x36bc4f=a341_0x3562[_0x17e534];return _0x36bc4f;};const _0x5c8af6=a341_0x36bc;'use strict';const Sequelize=require(_0x5c8af6('0x5'));module[_0x5c8af6('0x2')]={'type':{'type':Sequelize[_0x5c8af6('0x6')](_0x5c8af6('0x3'),'variable',_0x5c8af6('0x1'),_0x5c8af6('0x4')),'defaultValue':_0x5c8af6('0x3')},'content':{'type':Sequelize[_0x5c8af6('0x0')]},'key':{'type':Sequelize[_0x5c8af6('0x0')]},'keyType':{'type':Sequelize['ENUM'](_0x5c8af6('0x3'),'variable',_0x5c8af6('0x1'))},'keyContent':{'type':Sequelize[_0x5c8af6('0x0')]},'idField':{'type':Sequelize['STRING']},'nameField':{'type':Sequelize[_0x5c8af6('0x0')]},'customField':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x5c8af6('0x0')]}}; \ No newline at end of file +const a341_0x3154=['ENUM','keyValue','variable','STRING','BOOLEAN','customVariable','string','sequelize'];(function(_0x871399,_0x315412){const _0x1ca50e=function(_0x3a7ede){while(--_0x3a7ede){_0x871399['push'](_0x871399['shift']());}};_0x1ca50e(++_0x315412);}(a341_0x3154,0x1aa));const a341_0x1ca5=function(_0x871399,_0x315412){_0x871399=_0x871399-0x0;let _0x1ca50e=a341_0x3154[_0x871399];return _0x1ca50e;};const _0x4a08f1=a341_0x1ca5;'use strict';const Sequelize=require(_0x4a08f1('0x5'));module['exports']={'type':{'type':Sequelize[_0x4a08f1('0x6')](_0x4a08f1('0x4'),_0x4a08f1('0x0'),_0x4a08f1('0x3'),_0x4a08f1('0x7')),'defaultValue':_0x4a08f1('0x4')},'content':{'type':Sequelize['STRING']},'key':{'type':Sequelize[_0x4a08f1('0x1')]},'keyType':{'type':Sequelize[_0x4a08f1('0x6')]('string','variable','customVariable')},'keyContent':{'type':Sequelize[_0x4a08f1('0x1')]},'idField':{'type':Sequelize[_0x4a08f1('0x1')]},'nameField':{'type':Sequelize[_0x4a08f1('0x1')]},'customField':{'type':Sequelize[_0x4a08f1('0x2')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x4a08f1('0x1')]}}; \ No newline at end of file diff --git a/server/api/intZendeskField/intZendeskField.controller.js b/server/api/intZendeskField/intZendeskField.controller.js index 634c67c..c9b0746 100644 --- a/server/api/intZendeskField/intZendeskField.controller.js +++ b/server/api/intZendeskField/intZendeskField.controller.js @@ -1 +1 @@ -const a342_0x3b27=['query','undefined','then','json','map','key','show','findOne','stack','include','rows','model','body','order','name','catch','fieldName','end','../../components/parsers/qs','../../mysqldb','api','filters','set','index','rawAttributes','sequelize','findAll','includeAll','merge','type','like','Content-Range','limit','where','count','create','ZendeskField','pick','attributes','../../config/logger','nolimit','fields','intersection','update','options','status','sort','params','filter','keys','offset','destroy','send'];(function(_0x43000d,_0x3b27c0){const _0x5e1f60=function(_0x2a64c1){while(--_0x2a64c1){_0x43000d['push'](_0x43000d['shift']());}};_0x5e1f60(++_0x3b27c0);}(a342_0x3b27,0xf8));const a342_0x5e1f=function(_0x43000d,_0x3b27c0){_0x43000d=_0x43000d-0x0;let _0x5e1f60=a342_0x3b27[_0x43000d];return _0x5e1f60;};const _0x3289e=a342_0x5e1f;'use strict';const _=require('lodash'),qs=require(_0x3289e('0x23')),logger=require(_0x3289e('0x3'))(_0x3289e('0x25')),db=require(_0x3289e('0x24'))['db'],{Op}=require(_0x3289e('0x2a'));function respondWithResult(_0x2a64c1,_0x43886e){return _0x43886e=_0x43886e||0xc8,function(_0x46a102){const _0xd829d=a342_0x5e1f;if(_0x46a102)return _0x2a64c1[_0xd829d('0x9')](_0x43886e)[_0xd829d('0x14')](_0x46a102);};}function respondWithFilteredResult(_0x3b0609,_0x4a5d32){return function(_0x5b4272){const _0x3cbb69=a342_0x5e1f;if(_0x5b4272){const _0x47c207=_0x5b4272[_0x3cbb69('0x33')],_0x1f039d=_0x4a5d32[_0x3cbb69('0xe')];let _0xb8845a=_0x4a5d32[_0x3cbb69('0xe')]+_0x4a5d32['limit'],_0x5ca9c3;return _0xb8845a>=_0x47c207?(_0xb8845a=_0x47c207,_0x5ca9c3=0xc8):_0x5ca9c3=0xce,_0x3b0609[_0x3cbb69('0x9')](_0x5ca9c3),_0x3b0609[_0x3cbb69('0x27')](_0x3cbb69('0x30'),_0x1f039d+'-'+_0xb8845a+'/'+_0x47c207)[_0x3cbb69('0x14')](_0x5b4272);}return null;};}function saveUpdates(_0x316226){return function(_0xfeb33c){const _0x2c131d=a342_0x5e1f;if(_0xfeb33c)return _0xfeb33c[_0x2c131d('0x7')](_0x316226)['then'](function(_0x1dd98f){return _0x1dd98f;});return null;};}function removeEntity(_0x293340){return function(_0x4a9905){const _0x370831=a342_0x5e1f;if(_0x4a9905)return _0x4a9905[_0x370831('0xf')]()[_0x370831('0x13')](function(){const _0x77b2c1=_0x370831;_0x293340[_0x77b2c1('0x9')](0xcc)[_0x77b2c1('0x22')]();});};}function handleEntityNotFound(_0x1ec541){return function(_0x3fba75){return!_0x3fba75&&_0x1ec541['sendStatus'](0x194),_0x3fba75;};}function handleError(_0x12da99,_0x4dde0b){return _0x4dde0b=_0x4dde0b||0x1f4,function(_0x117ce8){const _0x41ad62=a342_0x5e1f;logger['error'](_0x117ce8[_0x41ad62('0x19')]),_0x117ce8[_0x41ad62('0x1f')]&&delete _0x117ce8['name'],_0x12da99['status'](_0x4dde0b)[_0x41ad62('0x10')](_0x117ce8);};}exports[_0x3289e('0x28')]=function(_0x193b1a,_0x153772){const _0x3988a0=_0x3289e;let _0x4e948d={};const _0x175714={},_0x30372d={'count':0x0,'rows':[]},_0x4cf4bd=_[_0x3988a0('0x15')](db['ZendeskField'][_0x3988a0('0x29')],function(_0x38078d){const _0x41d49c=_0x3988a0;return{'name':_0x38078d[_0x41d49c('0x21')],'type':_0x38078d[_0x41d49c('0x2e')][_0x41d49c('0x16')]};});_0x175714[_0x3988a0('0x1c')]=_['map'](_0x4cf4bd,_0x3988a0('0x1f')),_0x175714[_0x3988a0('0x11')]=_['keys'](_0x193b1a[_0x3988a0('0x11')]),_0x175714[_0x3988a0('0x26')]=_[_0x3988a0('0x6')](_0x175714['model'],_0x175714[_0x3988a0('0x11')]),_0x4e948d[_0x3988a0('0x2')]=_[_0x3988a0('0x6')](_0x175714[_0x3988a0('0x1c')],qs[_0x3988a0('0x5')](_0x193b1a[_0x3988a0('0x11')]['fields'])),_0x4e948d[_0x3988a0('0x2')]=_0x4e948d[_0x3988a0('0x2')]['length']?_0x4e948d[_0x3988a0('0x2')]:_0x175714['model'];typeof _0x193b1a[_0x3988a0('0x11')][_0x3988a0('0x4')]===_0x3988a0('0x12')&&(_0x4e948d[_0x3988a0('0x31')]=qs[_0x3988a0('0x31')](_0x193b1a['query'][_0x3988a0('0x31')]),_0x4e948d['offset']=qs[_0x3988a0('0xe')](_0x193b1a[_0x3988a0('0x11')]['offset']));_0x4e948d[_0x3988a0('0x1e')]=qs[_0x3988a0('0xa')](_0x193b1a[_0x3988a0('0x11')][_0x3988a0('0xa')]),_0x4e948d['where']=qs[_0x3988a0('0x26')](_[_0x3988a0('0x1')](_0x193b1a[_0x3988a0('0x11')],_0x175714['filters']),_0x4cf4bd);_0x193b1a[_0x3988a0('0x11')][_0x3988a0('0xc')]&&(_0x4e948d['where']=_[_0x3988a0('0x2d')](_0x4e948d[_0x3988a0('0x32')],{[Op['or']]:_[_0x3988a0('0x15')](_0x4cf4bd,function(_0x2f48be){const _0x57519a=_0x3988a0;if(_0x2f48be[_0x57519a('0x2e')]!=='VIRTUAL'){const _0x47f2ae={};return _0x47f2ae[_0x2f48be[_0x57519a('0x1f')]]={[Op[_0x57519a('0x2f')]]:'%'+_0x193b1a[_0x57519a('0x11')][_0x57519a('0xc')]+'%'},_0x47f2ae;}})}));_0x4e948d=_[_0x3988a0('0x2d')]({},_0x4e948d,_0x193b1a[_0x3988a0('0x8')]);const _0x56d5e5={'where':_0x4e948d[_0x3988a0('0x32')]};return db['ZendeskField'][_0x3988a0('0x33')](_0x56d5e5)['then'](function(_0x3b8643){const _0x3172d3=_0x3988a0;return _0x30372d['count']=_0x3b8643,_0x193b1a['query'][_0x3172d3('0x2c')]&&(_0x4e948d['include']=[{'all':!![]}]),db[_0x3172d3('0x0')][_0x3172d3('0x2b')](_0x4e948d);})['then'](function(_0x51a0b5){const _0x1fd509=_0x3988a0;return _0x30372d[_0x1fd509('0x1b')]=_0x51a0b5,_0x30372d;})[_0x3988a0('0x13')](respondWithFilteredResult(_0x153772,_0x4e948d))[_0x3988a0('0x20')](handleError(_0x153772,null));},exports[_0x3289e('0x17')]=function(_0x2af051,_0x383c5f){const _0x506d2a=_0x3289e;let _0x25ff9a={'raw':!![],'where':{'id':_0x2af051[_0x506d2a('0xb')]['id']}};const _0x3098f4={};return _0x3098f4[_0x506d2a('0x1c')]=_[_0x506d2a('0xd')](db[_0x506d2a('0x0')]['rawAttributes']),_0x3098f4[_0x506d2a('0x11')]=_[_0x506d2a('0xd')](_0x2af051[_0x506d2a('0x11')]),_0x3098f4[_0x506d2a('0x26')]=_['intersection'](_0x3098f4['model'],_0x3098f4[_0x506d2a('0x11')]),_0x25ff9a[_0x506d2a('0x2')]=_[_0x506d2a('0x6')](_0x3098f4[_0x506d2a('0x1c')],qs[_0x506d2a('0x5')](_0x2af051[_0x506d2a('0x11')][_0x506d2a('0x5')])),_0x25ff9a['attributes']=_0x25ff9a[_0x506d2a('0x2')]['length']?_0x25ff9a[_0x506d2a('0x2')]:_0x3098f4['model'],_0x2af051[_0x506d2a('0x11')][_0x506d2a('0x2c')]&&(_0x25ff9a[_0x506d2a('0x1a')]=[{'all':!![]}]),_0x25ff9a=_[_0x506d2a('0x2d')]({},_0x25ff9a,_0x2af051[_0x506d2a('0x8')]),db[_0x506d2a('0x0')][_0x506d2a('0x18')](_0x25ff9a)[_0x506d2a('0x13')](handleEntityNotFound(_0x383c5f,null))[_0x506d2a('0x13')](respondWithResult(_0x383c5f,null))[_0x506d2a('0x20')](handleError(_0x383c5f,null));},exports['create']=function(_0x40bd4f,_0x17938d){const _0x454874=_0x3289e;return db[_0x454874('0x0')][_0x454874('0x34')](_0x40bd4f[_0x454874('0x1d')],{})[_0x454874('0x13')](respondWithResult(_0x17938d,0xc9))[_0x454874('0x20')](handleError(_0x17938d,null));},exports[_0x3289e('0x7')]=function(_0x158c92,_0x2b3ca7){const _0x4117d9=_0x3289e;return _0x158c92[_0x4117d9('0x1d')]['id']&&delete _0x158c92[_0x4117d9('0x1d')]['id'],db[_0x4117d9('0x0')][_0x4117d9('0x18')]({'where':{'id':_0x158c92[_0x4117d9('0xb')]['id']}})[_0x4117d9('0x13')](handleEntityNotFound(_0x2b3ca7,null))[_0x4117d9('0x13')](saveUpdates(_0x158c92[_0x4117d9('0x1d')],null))[_0x4117d9('0x13')](respondWithResult(_0x2b3ca7,null))[_0x4117d9('0x20')](handleError(_0x2b3ca7,null));},exports[_0x3289e('0xf')]=function(_0x1b0667,_0xed0c17){const _0x370b66=_0x3289e;return db[_0x370b66('0x0')][_0x370b66('0x18')]({'where':{'id':_0x1b0667[_0x370b66('0xb')]['id']}})[_0x370b66('0x13')](handleEntityNotFound(_0xed0c17,null))[_0x370b66('0x13')](removeEntity(_0xed0c17,null))[_0x370b66('0x20')](handleError(_0xed0c17,null));}; \ No newline at end of file +const a342_0x1ea4=['map','catch','intersection','fields','Content-Range','sendStatus','rows','stack','offset','rawAttributes','where','show','nolimit','options','sort','json','name','body','query','order','ZendeskField','length','undefined','send','api','set','key','merge','findOne','like','end','../../components/parsers/qs','destroy','../../config/logger','count','then','includeAll','filters','limit','attributes','update','params','create','index','type','status','keys','include','findAll','model','../../mysqldb'];(function(_0x3b8325,_0x1ea426){const _0x55d6c8=function(_0x4101d9){while(--_0x4101d9){_0x3b8325['push'](_0x3b8325['shift']());}};_0x55d6c8(++_0x1ea426);}(a342_0x1ea4,0xd6));const a342_0x55d6=function(_0x3b8325,_0x1ea426){_0x3b8325=_0x3b8325-0x0;let _0x55d6c8=a342_0x1ea4[_0x3b8325];return _0x55d6c8;};const _0x1439fc=a342_0x55d6;'use strict';const _=require('lodash'),qs=require(_0x1439fc('0x15')),logger=require(_0x1439fc('0x17'))(_0x1439fc('0xe')),db=require(_0x1439fc('0x28'))['db'],{Op}=require('sequelize');function respondWithResult(_0x4101d9,_0x14dc4b){return _0x14dc4b=_0x14dc4b||0xc8,function(_0xfaf9db){const _0x23bd7e=a342_0x55d6;if(_0xfaf9db)return _0x4101d9[_0x23bd7e('0x23')](_0x14dc4b)[_0x23bd7e('0x5')](_0xfaf9db);};}function respondWithFilteredResult(_0x249722,_0x659ff2){return function(_0x3d0c8f){const _0xd57929=a342_0x55d6;if(_0x3d0c8f){const _0x5ec84f=_0x3d0c8f[_0xd57929('0x18')],_0x1474bf=_0x659ff2['offset'];let _0x2cff28=_0x659ff2['offset']+_0x659ff2[_0xd57929('0x1c')],_0x2cb1ec;return _0x2cff28>=_0x5ec84f?(_0x2cff28=_0x5ec84f,_0x2cb1ec=0xc8):_0x2cb1ec=0xce,_0x249722['status'](_0x2cb1ec),_0x249722[_0xd57929('0xf')](_0xd57929('0x2d'),_0x1474bf+'-'+_0x2cff28+'/'+_0x5ec84f)[_0xd57929('0x5')](_0x3d0c8f);}return null;};}function saveUpdates(_0x20a3f9){return function(_0x582ed8){const _0x239690=a342_0x55d6;if(_0x582ed8)return _0x582ed8[_0x239690('0x1e')](_0x20a3f9)[_0x239690('0x19')](function(_0x1993a6){return _0x1993a6;});return null;};}function removeEntity(_0x3387bf){return function(_0xe36a98){const _0x38a1fa=a342_0x55d6;if(_0xe36a98)return _0xe36a98[_0x38a1fa('0x16')]()[_0x38a1fa('0x19')](function(){const _0x5d6d95=_0x38a1fa;_0x3387bf[_0x5d6d95('0x23')](0xcc)[_0x5d6d95('0x14')]();});};}function handleEntityNotFound(_0x2e43fd){return function(_0x21abef){const _0x2c7965=a342_0x55d6;return!_0x21abef&&_0x2e43fd[_0x2c7965('0x2e')](0x194),_0x21abef;};}function handleError(_0x2fe87d,_0x542d92){return _0x542d92=_0x542d92||0x1f4,function(_0x49c811){const _0x4bdd10=a342_0x55d6;logger['error'](_0x49c811[_0x4bdd10('0x30')]),_0x49c811['name']&&delete _0x49c811['name'],_0x2fe87d[_0x4bdd10('0x23')](_0x542d92)[_0x4bdd10('0xd')](_0x49c811);};}exports[_0x1439fc('0x21')]=function(_0x57c93a,_0x122701){const _0x312a53=_0x1439fc;let _0xc9c8bc={};const _0x348f36={},_0x590235={'count':0x0,'rows':[]},_0x5474ae=_['map'](db[_0x312a53('0xa')][_0x312a53('0x32')],function(_0x24e21c){const _0x34cc77=_0x312a53;return{'name':_0x24e21c['fieldName'],'type':_0x24e21c[_0x34cc77('0x22')][_0x34cc77('0x10')]};});_0x348f36[_0x312a53('0x27')]=_[_0x312a53('0x29')](_0x5474ae,_0x312a53('0x6')),_0x348f36[_0x312a53('0x8')]=_[_0x312a53('0x24')](_0x57c93a[_0x312a53('0x8')]),_0x348f36[_0x312a53('0x1b')]=_[_0x312a53('0x2b')](_0x348f36[_0x312a53('0x27')],_0x348f36[_0x312a53('0x8')]),_0xc9c8bc[_0x312a53('0x1d')]=_[_0x312a53('0x2b')](_0x348f36[_0x312a53('0x27')],qs[_0x312a53('0x2c')](_0x57c93a[_0x312a53('0x8')][_0x312a53('0x2c')])),_0xc9c8bc['attributes']=_0xc9c8bc[_0x312a53('0x1d')]['length']?_0xc9c8bc[_0x312a53('0x1d')]:_0x348f36[_0x312a53('0x27')];typeof _0x57c93a[_0x312a53('0x8')][_0x312a53('0x2')]===_0x312a53('0xc')&&(_0xc9c8bc[_0x312a53('0x1c')]=qs[_0x312a53('0x1c')](_0x57c93a['query'][_0x312a53('0x1c')]),_0xc9c8bc[_0x312a53('0x31')]=qs['offset'](_0x57c93a[_0x312a53('0x8')][_0x312a53('0x31')]));_0xc9c8bc[_0x312a53('0x9')]=qs['sort'](_0x57c93a[_0x312a53('0x8')][_0x312a53('0x4')]),_0xc9c8bc['where']=qs['filters'](_['pick'](_0x57c93a[_0x312a53('0x8')],_0x348f36[_0x312a53('0x1b')]),_0x5474ae);_0x57c93a[_0x312a53('0x8')]['filter']&&(_0xc9c8bc[_0x312a53('0x0')]=_[_0x312a53('0x11')](_0xc9c8bc['where'],{[Op['or']]:_['map'](_0x5474ae,function(_0x1a49f3){const _0x1fc4a1=_0x312a53;if(_0x1a49f3[_0x1fc4a1('0x22')]!=='VIRTUAL'){const _0x17d7e0={};return _0x17d7e0[_0x1a49f3['name']]={[Op[_0x1fc4a1('0x13')]]:'%'+_0x57c93a['query']['filter']+'%'},_0x17d7e0;}})}));_0xc9c8bc=_[_0x312a53('0x11')]({},_0xc9c8bc,_0x57c93a[_0x312a53('0x3')]);const _0x13df24={'where':_0xc9c8bc[_0x312a53('0x0')]};return db[_0x312a53('0xa')][_0x312a53('0x18')](_0x13df24)['then'](function(_0x40cdf0){const _0x119d7e=_0x312a53;return _0x590235[_0x119d7e('0x18')]=_0x40cdf0,_0x57c93a[_0x119d7e('0x8')][_0x119d7e('0x1a')]&&(_0xc9c8bc[_0x119d7e('0x25')]=[{'all':!![]}]),db['ZendeskField'][_0x119d7e('0x26')](_0xc9c8bc);})['then'](function(_0x43dbc0){const _0x3f1c59=_0x312a53;return _0x590235[_0x3f1c59('0x2f')]=_0x43dbc0,_0x590235;})[_0x312a53('0x19')](respondWithFilteredResult(_0x122701,_0xc9c8bc))[_0x312a53('0x2a')](handleError(_0x122701,null));},exports[_0x1439fc('0x1')]=function(_0x20067b,_0x32f10d){const _0x2aaea7=_0x1439fc;let _0x36f3e6={'raw':!![],'where':{'id':_0x20067b['params']['id']}};const _0x2e0cc9={};return _0x2e0cc9[_0x2aaea7('0x27')]=_[_0x2aaea7('0x24')](db[_0x2aaea7('0xa')][_0x2aaea7('0x32')]),_0x2e0cc9[_0x2aaea7('0x8')]=_['keys'](_0x20067b[_0x2aaea7('0x8')]),_0x2e0cc9[_0x2aaea7('0x1b')]=_[_0x2aaea7('0x2b')](_0x2e0cc9[_0x2aaea7('0x27')],_0x2e0cc9['query']),_0x36f3e6['attributes']=_[_0x2aaea7('0x2b')](_0x2e0cc9[_0x2aaea7('0x27')],qs[_0x2aaea7('0x2c')](_0x20067b['query'][_0x2aaea7('0x2c')])),_0x36f3e6[_0x2aaea7('0x1d')]=_0x36f3e6['attributes'][_0x2aaea7('0xb')]?_0x36f3e6[_0x2aaea7('0x1d')]:_0x2e0cc9['model'],_0x20067b[_0x2aaea7('0x8')][_0x2aaea7('0x1a')]&&(_0x36f3e6['include']=[{'all':!![]}]),_0x36f3e6=_[_0x2aaea7('0x11')]({},_0x36f3e6,_0x20067b[_0x2aaea7('0x3')]),db[_0x2aaea7('0xa')][_0x2aaea7('0x12')](_0x36f3e6)['then'](handleEntityNotFound(_0x32f10d,null))[_0x2aaea7('0x19')](respondWithResult(_0x32f10d,null))[_0x2aaea7('0x2a')](handleError(_0x32f10d,null));},exports[_0x1439fc('0x20')]=function(_0xab28f5,_0x167704){const _0x48fb05=_0x1439fc;return db[_0x48fb05('0xa')][_0x48fb05('0x20')](_0xab28f5[_0x48fb05('0x7')],{})['then'](respondWithResult(_0x167704,0xc9))[_0x48fb05('0x2a')](handleError(_0x167704,null));},exports[_0x1439fc('0x1e')]=function(_0x575692,_0x5cc03d){const _0x4d0657=_0x1439fc;return _0x575692[_0x4d0657('0x7')]['id']&&delete _0x575692[_0x4d0657('0x7')]['id'],db['ZendeskField'][_0x4d0657('0x12')]({'where':{'id':_0x575692['params']['id']}})[_0x4d0657('0x19')](handleEntityNotFound(_0x5cc03d,null))['then'](saveUpdates(_0x575692[_0x4d0657('0x7')],null))['then'](respondWithResult(_0x5cc03d,null))['catch'](handleError(_0x5cc03d,null));},exports[_0x1439fc('0x16')]=function(_0x8b3205,_0x501ed0){const _0x4da57c=_0x1439fc;return db[_0x4da57c('0xa')][_0x4da57c('0x12')]({'where':{'id':_0x8b3205[_0x4da57c('0x1f')]['id']}})[_0x4da57c('0x19')](handleEntityNotFound(_0x501ed0,null))[_0x4da57c('0x19')](removeEntity(_0x501ed0,null))[_0x4da57c('0x2a')](handleError(_0x501ed0,null));}; \ No newline at end of file diff --git a/server/api/intZendeskField/intZendeskField.model.js b/server/api/intZendeskField/intZendeskField.model.js index fd5e0be..e1f922d 100644 --- a/server/api/intZendeskField/intZendeskField.model.js +++ b/server/api/intZendeskField/intZendeskField.model.js @@ -1 +1 @@ -const a343_0x3943=['define','zendesk_unique_index','./intZendeskField.attributes','FieldId','ZendeskField','idField','int_zendesk_fields'];(function(_0x975d06,_0x394362){const _0x218c98=function(_0x2cd71e){while(--_0x2cd71e){_0x975d06['push'](_0x975d06['shift']());}};_0x218c98(++_0x394362);}(a343_0x3943,0x92));const a343_0x218c=function(_0x975d06,_0x394362){_0x975d06=_0x975d06-0x0;let _0x218c98=a343_0x3943[_0x975d06];return _0x218c98;};const _0x41373e=a343_0x218c;'use strict';const attributes=require(_0x41373e('0x3'));module['exports']=function(_0x2cd71e){const _0x23db30=_0x41373e,_0x2ced45=_0x2cd71e[_0x23db30('0x1')](_0x23db30('0x5'),attributes,{'tableName':_0x23db30('0x0'),'paranoid':![],'indexes':[{'name':_0x23db30('0x2'),'fields':[_0x23db30('0x6'),_0x23db30('0x4')],'unique':!![]}],'timestamps':!![]});return _0x2ced45;}; \ No newline at end of file +const a343_0x3236=['zendesk_unique_index','FieldId','./intZendeskField.attributes','ZendeskField','int_zendesk_fields'];(function(_0x9c3875,_0x3236e8){const _0xfdf5c0=function(_0x36fd40){while(--_0x36fd40){_0x9c3875['push'](_0x9c3875['shift']());}};_0xfdf5c0(++_0x3236e8);}(a343_0x3236,0x72));const a343_0xfdf5=function(_0x9c3875,_0x3236e8){_0x9c3875=_0x9c3875-0x0;let _0xfdf5c0=a343_0x3236[_0x9c3875];return _0xfdf5c0;};const _0x2b349f=a343_0xfdf5;'use strict';const attributes=require(_0x2b349f('0x3'));module['exports']=function(_0x36fd40){const _0x16eba7=_0x2b349f,_0x2ca878=_0x36fd40['define'](_0x16eba7('0x4'),attributes,{'tableName':_0x16eba7('0x0'),'paranoid':![],'indexes':[{'name':_0x16eba7('0x1'),'fields':['idField',_0x16eba7('0x2')],'unique':!![]}],'timestamps':!![]});return _0x2ca878;}; \ No newline at end of file diff --git a/server/api/intZohoAccount/index.js b/server/api/intZohoAccount/index.js index 10bab8a..92092d7 100644 --- a/server/api/intZohoAccount/index.js +++ b/server/api/intZohoAccount/index.js @@ -1 +1 @@ -const a344_0x7b18=['getConfigurations','../../components/auth/service','/:id/configurations','post','put','getFields','/:id','addConfiguration','Router','show','express','index','exports','delete','isAuthenticated','get','destroy'];(function(_0x3f1505,_0x7b1870){const _0x50b2b4=function(_0x17774b){while(--_0x17774b){_0x3f1505['push'](_0x3f1505['shift']());}};_0x50b2b4(++_0x7b1870);}(a344_0x7b18,0x1b5));const a344_0x50b2=function(_0x3f1505,_0x7b1870){_0x3f1505=_0x3f1505-0x0;let _0x50b2b4=a344_0x7b18[_0x3f1505];return _0x50b2b4;};const _0x41ad9e=a344_0x50b2;'use strict';const express=require(_0x41ad9e('0xf')),router=express[_0x41ad9e('0xd')](),auth=require(_0x41ad9e('0x6')),controller=require('./intZohoAccount.controller');router[_0x41ad9e('0x3')]('/',auth[_0x41ad9e('0x2')](),controller[_0x41ad9e('0x10')]),router[_0x41ad9e('0x3')](_0x41ad9e('0xb'),auth[_0x41ad9e('0x2')](),controller[_0x41ad9e('0xe')]),router[_0x41ad9e('0x3')](_0x41ad9e('0x7'),auth[_0x41ad9e('0x2')](),controller[_0x41ad9e('0x5')]),router[_0x41ad9e('0x3')]('/:id/fields',auth[_0x41ad9e('0x2')](),controller[_0x41ad9e('0xa')]),router['post']('/',auth[_0x41ad9e('0x2')](),controller['create']),router[_0x41ad9e('0x8')]('/:id/configurations',auth[_0x41ad9e('0x2')](),controller[_0x41ad9e('0xc')]),router[_0x41ad9e('0x9')](_0x41ad9e('0xb'),auth[_0x41ad9e('0x2')](),controller['update']),router[_0x41ad9e('0x1')](_0x41ad9e('0xb'),auth[_0x41ad9e('0x2')](),controller[_0x41ad9e('0x4')]),module[_0x41ad9e('0x0')]=router; \ No newline at end of file +const a344_0x2f8d=['delete','express','destroy','/:id','getFields','Router','isAuthenticated','show','../../components/auth/service','update','exports','index','/:id/configurations','./intZohoAccount.controller','addConfiguration','/:id/fields','get','post','create'];(function(_0x4783b8,_0x2f8db5){const _0x2013f1=function(_0x117495){while(--_0x117495){_0x4783b8['push'](_0x4783b8['shift']());}};_0x2013f1(++_0x2f8db5);}(a344_0x2f8d,0x1a1));const a344_0x2013=function(_0x4783b8,_0x2f8db5){_0x4783b8=_0x4783b8-0x0;let _0x2013f1=a344_0x2f8d[_0x4783b8];return _0x2013f1;};const _0x577b23=a344_0x2013;'use strict';const express=require(_0x577b23('0x2')),router=express[_0x577b23('0x6')](),auth=require(_0x577b23('0x9')),controller=require(_0x577b23('0xe'));router['get']('/',auth['isAuthenticated'](),controller[_0x577b23('0xc')]),router[_0x577b23('0x11')](_0x577b23('0x4'),auth[_0x577b23('0x7')](),controller[_0x577b23('0x8')]),router[_0x577b23('0x11')]('/:id/configurations',auth['isAuthenticated'](),controller['getConfigurations']),router[_0x577b23('0x11')](_0x577b23('0x10'),auth[_0x577b23('0x7')](),controller[_0x577b23('0x5')]),router['post']('/',auth[_0x577b23('0x7')](),controller[_0x577b23('0x0')]),router[_0x577b23('0x12')](_0x577b23('0xd'),auth[_0x577b23('0x7')](),controller[_0x577b23('0xf')]),router['put'](_0x577b23('0x4'),auth['isAuthenticated'](),controller[_0x577b23('0xa')]),router[_0x577b23('0x1')]('/:id',auth[_0x577b23('0x7')](),controller[_0x577b23('0x3')]),module[_0x577b23('0xb')]=router; \ No newline at end of file diff --git a/server/api/intZohoAccount/intZohoAccount.attributes.js b/server/api/intZohoAccount/intZohoAccount.attributes.js index 58b00d4..2245473 100644 --- a/server/api/intZohoAccount/intZohoAccount.attributes.js +++ b/server/api/intZohoAccount/intZohoAccount.attributes.js @@ -1 +1 @@ -const a345_0x1d42=['exports','STRING','sequelize'];(function(_0x39dfe5,_0x1d42c0){const _0x370875=function(_0x409b63){while(--_0x409b63){_0x39dfe5['push'](_0x39dfe5['shift']());}};_0x370875(++_0x1d42c0);}(a345_0x1d42,0x19e));const a345_0x3708=function(_0x39dfe5,_0x1d42c0){_0x39dfe5=_0x39dfe5-0x0;let _0x370875=a345_0x1d42[_0x39dfe5];return _0x370875;};const _0x20d259=a345_0x3708;'use strict';const Sequelize=require(_0x20d259('0x2'));module[_0x20d259('0x0')]={'name':{'type':Sequelize['STRING']},'description':{'type':Sequelize[_0x20d259('0x1')]},'host':{'type':Sequelize['STRING']},'zone':{'type':Sequelize[_0x20d259('0x1')]},'clientId':{'type':Sequelize[_0x20d259('0x1')]},'clientSecret':{'type':Sequelize[_0x20d259('0x1')]},'serverUrl':{'type':Sequelize[_0x20d259('0x1')]},'code':{'type':Sequelize[_0x20d259('0x1')]},'refreshToken':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a345_0x5dbb=['exports','STRING'];(function(_0x4bafd2,_0x5dbbbb){const _0x4760cd=function(_0x4aabf1){while(--_0x4aabf1){_0x4bafd2['push'](_0x4bafd2['shift']());}};_0x4760cd(++_0x5dbbbb);}(a345_0x5dbb,0x72));const a345_0x4760=function(_0x4bafd2,_0x5dbbbb){_0x4bafd2=_0x4bafd2-0x0;let _0x4760cd=a345_0x5dbb[_0x4bafd2];return _0x4760cd;};const _0x4f8868=a345_0x4760;'use strict';const Sequelize=require('sequelize');module[_0x4f8868('0x0')]={'name':{'type':Sequelize[_0x4f8868('0x1')]},'description':{'type':Sequelize[_0x4f8868('0x1')]},'host':{'type':Sequelize[_0x4f8868('0x1')]},'zone':{'type':Sequelize[_0x4f8868('0x1')]},'clientId':{'type':Sequelize['STRING']},'clientSecret':{'type':Sequelize[_0x4f8868('0x1')]},'serverUrl':{'type':Sequelize['STRING']},'code':{'type':Sequelize[_0x4f8868('0x1')]},'refreshToken':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/intZohoAccount/intZohoAccount.controller.js b/server/api/intZohoAccount/intZohoAccount.controller.js index 42ef588..f766da9 100644 --- a/server/api/intZohoAccount/intZohoAccount.controller.js +++ b/server/api/intZohoAccount/intZohoAccount.controller.js @@ -1 +1 @@ -const a346_0x1032=['Subject','host','undefined','includes','filter','rows','ZohoConfiguration','model','request-promise-native','nolimit','Description','attributes','intersection','params','util','includeAll','AccountId','limit','Subjects','Owner','getFields,\x20%s,\x20%s,\x20%s','include','data_type','api','offset','com','../../mysqldb','statusCode','order','ZohoField','stack','getFields','POST','sequelize','json','ZohoAccount','key','picklist','code','fieldName','findAll','lodash','https://accounts.zoho.in','Call_Result','format','merge','options','Call_Start_Time','Refresh\x20Token\x20not\x20available\x20for\x20the\x20account','custom_field','catch','channel','map','VIRTUAL','create','error','system_mandatory','pick_list_values','type','end','filters','response','serverUrl','name','show','zone','Zoho-oauthtoken\x20','rawAttributes','Call_Duration','keys','../../components/integrations/configuration','count','https://accounts.zoho.com','sort','sendStatus','../../components/parsers/qs','where','body','lastIndexOf','then','remove','push','Wrong\x20credentials','set','addConfiguration','pick','test','update','index','refresh_token','GET','fields','refreshToken','https://www.zohoapis.%s/crm/v2/settings/fields','https://accounts.zoho.eu','destroy','slice','substring','Content-Range','query','like','status','length','getConfigurations','findOne','Descriptions'];(function(_0x101ce3,_0x1032fb){const _0x347822=function(_0x592cce){while(--_0x592cce){_0x101ce3['push'](_0x101ce3['shift']());}};_0x347822(++_0x1032fb);}(a346_0x1032,0xa4));const a346_0x3478=function(_0x101ce3,_0x1032fb){_0x101ce3=_0x101ce3-0x0;let _0x347822=a346_0x1032[_0x101ce3];return _0x347822;};const _0x5481c1=a346_0x3478;'use strict';const rp=require(_0x5481c1('0x38')),util=require(_0x5481c1('0x3e')),_=require(_0x5481c1('0x59')),qs=require(_0x5481c1('0x11')),logger=require('../../config/logger')(_0x5481c1('0x47')),db=require(_0x5481c1('0x4a'))['db'],{Op}=require(_0x5481c1('0x51')),integrations=require(_0x5481c1('0xc'));function respondWithResult(_0x592cce,_0x4ba479){return _0x4ba479=_0x4ba479||0xc8,function(_0x8a4f5d){const _0x212a78=a346_0x3478;if(_0x8a4f5d)return _0x592cce[_0x212a78('0x2b')](_0x4ba479)[_0x212a78('0x52')](_0x8a4f5d);};}function respondWithFilteredResult(_0x2ffbda,_0x2a5a13){return function(_0x27029d){const _0x51a46f=a346_0x3478;if(_0x27029d){const _0x34ef7f=_0x27029d[_0x51a46f('0xd')],_0x119664=_0x2a5a13[_0x51a46f('0x48')];let _0x247c04=_0x2a5a13['offset']+_0x2a5a13[_0x51a46f('0x41')],_0xcce7d4;return _0x247c04>=_0x34ef7f?(_0x247c04=_0x34ef7f,_0xcce7d4=0xc8):_0xcce7d4=0xce,_0x2ffbda[_0x51a46f('0x2b')](_0xcce7d4),_0x2ffbda[_0x51a46f('0x19')](_0x51a46f('0x28'),_0x119664+'-'+_0x247c04+'/'+_0x34ef7f)['json'](_0x27029d);}return null;};}function saveUpdates(_0x5e8894){return function(_0x18cb9e){const _0x6d4f5c=a346_0x3478;if(_0x18cb9e)return _0x18cb9e[_0x6d4f5c('0x1d')](_0x5e8894)[_0x6d4f5c('0x15')](function(_0x233362){return _0x233362;});return null;};}function removeEntity(_0x2097af){return function(_0x24fe7c){const _0x398a37=a346_0x3478;if(_0x24fe7c)return _0x24fe7c[_0x398a37('0x25')]()[_0x398a37('0x15')](function(){const _0x50da36=_0x398a37;_0x2097af['status'](0xcc)[_0x50da36('0x1')]();});};}function handleEntityNotFound(_0x4ca292){return function(_0x5250dc){const _0x317206=a346_0x3478;return!_0x5250dc&&_0x4ca292[_0x317206('0x10')](0x194),_0x5250dc;};}function handleError(_0x12ab5c,_0x1e2fb1){return _0x1e2fb1=_0x1e2fb1||0x1f4,function(_0x3c8472){const _0x165742=a346_0x3478;logger[_0x165742('0x67')](_0x3c8472[_0x165742('0x4e')]),_0x3c8472['name']&&delete _0x3c8472[_0x165742('0x5')],_0x12ab5c[_0x165742('0x2b')](_0x1e2fb1)['send'](_0x3c8472);};}exports[_0x5481c1('0x1e')]=function(_0x1fdd7e,_0x5dab55){const _0x4dc828=_0x5481c1;let _0x5d0bf5={};const _0x48c21c={},_0x2169a2={'count':0x0,'rows':[]},_0x43a040=_[_0x4dc828('0x64')](db['ZohoAccount'][_0x4dc828('0x9')],function(_0x5c6f74){const _0x1382e2=_0x4dc828;return{'name':_0x5c6f74[_0x1382e2('0x57')],'type':_0x5c6f74[_0x1382e2('0x0')][_0x1382e2('0x54')]};});_0x48c21c[_0x4dc828('0x37')]=_[_0x4dc828('0x64')](_0x43a040,_0x4dc828('0x5')),_0x48c21c[_0x4dc828('0x29')]=_[_0x4dc828('0xb')](_0x1fdd7e['query']),_0x48c21c[_0x4dc828('0x2')]=_[_0x4dc828('0x3c')](_0x48c21c['model'],_0x48c21c[_0x4dc828('0x29')]),_0x5d0bf5[_0x4dc828('0x3b')]=_['intersection'](_0x48c21c[_0x4dc828('0x37')],qs[_0x4dc828('0x21')](_0x1fdd7e[_0x4dc828('0x29')][_0x4dc828('0x21')])),_0x5d0bf5[_0x4dc828('0x3b')]=_0x5d0bf5[_0x4dc828('0x3b')][_0x4dc828('0x2c')]?_0x5d0bf5[_0x4dc828('0x3b')]:_0x48c21c[_0x4dc828('0x37')];typeof _0x1fdd7e[_0x4dc828('0x29')][_0x4dc828('0x39')]===_0x4dc828('0x32')&&(_0x5d0bf5['limit']=qs[_0x4dc828('0x41')](_0x1fdd7e[_0x4dc828('0x29')]['limit']),_0x5d0bf5[_0x4dc828('0x48')]=qs[_0x4dc828('0x48')](_0x1fdd7e[_0x4dc828('0x29')][_0x4dc828('0x48')]));_0x5d0bf5[_0x4dc828('0x4c')]=qs[_0x4dc828('0xf')](_0x1fdd7e[_0x4dc828('0x29')][_0x4dc828('0xf')]),_0x5d0bf5[_0x4dc828('0x12')]=qs[_0x4dc828('0x2')](_[_0x4dc828('0x1b')](_0x1fdd7e['query'],_0x48c21c[_0x4dc828('0x2')]),_0x43a040);_0x1fdd7e[_0x4dc828('0x29')][_0x4dc828('0x34')]&&(_0x5d0bf5[_0x4dc828('0x12')]=_[_0x4dc828('0x5d')](_0x5d0bf5[_0x4dc828('0x12')],{[Op['or']]:_[_0x4dc828('0x64')](_0x43a040,function(_0x414e7e){const _0x2b1783=_0x4dc828;if(_0x414e7e[_0x2b1783('0x0')]!==_0x2b1783('0x65')){const _0x393d4a={};return _0x393d4a[_0x414e7e[_0x2b1783('0x5')]]={[Op[_0x2b1783('0x2a')]]:'%'+_0x1fdd7e[_0x2b1783('0x29')]['filter']+'%'},_0x393d4a;}})}));_0x5d0bf5=_[_0x4dc828('0x5d')]({},_0x5d0bf5,_0x1fdd7e[_0x4dc828('0x5e')]);const _0x4b2bfd={'where':_0x5d0bf5[_0x4dc828('0x12')]};return db[_0x4dc828('0x53')][_0x4dc828('0xd')](_0x4b2bfd)[_0x4dc828('0x15')](function(_0x2b8bfa){const _0x266c2c=_0x4dc828;return _0x2169a2['count']=_0x2b8bfa,_0x1fdd7e[_0x266c2c('0x29')][_0x266c2c('0x3f')]&&(_0x5d0bf5[_0x266c2c('0x45')]=[{'all':!![]}]),db[_0x266c2c('0x53')][_0x266c2c('0x58')](_0x5d0bf5);})[_0x4dc828('0x15')](function(_0x3ac613){const _0x1bab8c=_0x4dc828;return _0x2169a2[_0x1bab8c('0x35')]=_0x3ac613,_0x2169a2;})[_0x4dc828('0x15')](respondWithFilteredResult(_0x5dab55,_0x5d0bf5))[_0x4dc828('0x62')](handleError(_0x5dab55,null));},exports[_0x5481c1('0x6')]=function(_0x9a1cea,_0x34d032){const _0x572d1b=_0x5481c1;let _0x2ae5ee={'raw':![],'where':{'id':_0x9a1cea[_0x572d1b('0x3d')]['id']}};const _0x824f09={};return _0x824f09[_0x572d1b('0x37')]=_['keys'](db[_0x572d1b('0x53')][_0x572d1b('0x9')]),_0x824f09[_0x572d1b('0x29')]=_[_0x572d1b('0xb')](_0x9a1cea[_0x572d1b('0x29')]),_0x824f09[_0x572d1b('0x2')]=_[_0x572d1b('0x3c')](_0x824f09['model'],_0x824f09[_0x572d1b('0x29')]),_0x2ae5ee['attributes']=_[_0x572d1b('0x3c')](_0x824f09['model'],qs[_0x572d1b('0x21')](_0x9a1cea[_0x572d1b('0x29')][_0x572d1b('0x21')])),_0x2ae5ee[_0x572d1b('0x3b')]=_0x2ae5ee[_0x572d1b('0x3b')][_0x572d1b('0x2c')]?_0x2ae5ee[_0x572d1b('0x3b')]:_0x824f09[_0x572d1b('0x37')],_0x9a1cea['query'][_0x572d1b('0x3f')]&&(_0x2ae5ee[_0x572d1b('0x45')]=[{'all':!![]}]),_0x2ae5ee=_[_0x572d1b('0x5d')]({},_0x2ae5ee,_0x9a1cea[_0x572d1b('0x5e')]),db['ZohoAccount'][_0x572d1b('0x2e')](_0x2ae5ee)['then'](handleEntityNotFound(_0x34d032,null))[_0x572d1b('0x15')](respondWithResult(_0x34d032,null))[_0x572d1b('0x62')](handleError(_0x34d032,null));},exports[_0x5481c1('0x66')]=function(_0x5870b2,_0x24c46b){const _0x5aecaf=_0x5481c1;return db['ZohoAccount'][_0x5aecaf('0x66')](_0x5870b2['body'],{})[_0x5aecaf('0x15')](respondWithResult(_0x24c46b,0xc9))[_0x5aecaf('0x62')](handleError(_0x24c46b,null));},exports[_0x5481c1('0x1d')]=function(_0x2e2fe0,_0x4da461){const _0x91ac9f=_0x5481c1;return _0x2e2fe0[_0x91ac9f('0x13')]['id']&&delete _0x2e2fe0[_0x91ac9f('0x13')]['id'],db[_0x91ac9f('0x53')]['findOne']({'where':{'id':_0x2e2fe0[_0x91ac9f('0x3d')]['id']}})[_0x91ac9f('0x15')](handleEntityNotFound(_0x4da461,null))[_0x91ac9f('0x15')](saveUpdates(_0x2e2fe0['body'],null))['then'](respondWithResult(_0x4da461,null))[_0x91ac9f('0x62')](handleError(_0x4da461,null));},exports[_0x5481c1('0x25')]=function(_0x33edf3,_0x585c24){const _0x3fa519=_0x5481c1;return db[_0x3fa519('0x53')][_0x3fa519('0x2e')]({'where':{'id':_0x33edf3[_0x3fa519('0x3d')]['id']}})[_0x3fa519('0x15')](handleEntityNotFound(_0x585c24,null))[_0x3fa519('0x15')](removeEntity(_0x585c24,null))[_0x3fa519('0x62')](handleError(_0x585c24,null));},exports[_0x5481c1('0x2d')]=function(_0x2de115,_0x103f1a){const _0x12a95b=_0x5481c1;let _0x20a275={};const _0x32c610={};let _0x3b3e34,_0x5ab9e4;return db[_0x12a95b('0x53')]['findOne']({'where':{'id':_0x2de115['params']['id']}})[_0x12a95b('0x15')](handleEntityNotFound(_0x103f1a,null))['then'](function(_0x59d660){const _0x4012a7=_0x12a95b;if(_0x59d660)return _0x3b3e34=_0x59d660,_0x32c610['model']=_[_0x4012a7('0xb')](db[_0x4012a7('0x36')]['rawAttributes']),_0x32c610['query']=_[_0x4012a7('0xb')](_0x2de115[_0x4012a7('0x29')]),_0x32c610[_0x4012a7('0x2')]=_[_0x4012a7('0x3c')](_0x32c610['model'],_0x32c610[_0x4012a7('0x29')]),_0x20a275[_0x4012a7('0x3b')]=_[_0x4012a7('0x3c')](_0x32c610[_0x4012a7('0x37')],qs[_0x4012a7('0x21')](_0x2de115[_0x4012a7('0x29')][_0x4012a7('0x21')])),_0x20a275[_0x4012a7('0x3b')]=_0x20a275[_0x4012a7('0x3b')]['length']?_0x20a275[_0x4012a7('0x3b')]:_0x32c610[_0x4012a7('0x37')],_0x20a275[_0x4012a7('0x4c')]=qs[_0x4012a7('0xf')](_0x2de115[_0x4012a7('0x29')][_0x4012a7('0xf')]),_0x20a275['where']=qs[_0x4012a7('0x2')](_[_0x4012a7('0x1b')](_0x2de115[_0x4012a7('0x29')],_0x32c610[_0x4012a7('0x2')])),_0x2de115[_0x4012a7('0x29')][_0x4012a7('0x34')]&&(_0x20a275[_0x4012a7('0x12')]=_[_0x4012a7('0x5d')](_0x20a275[_0x4012a7('0x12')],{[Op['or']]:_[_0x4012a7('0x64')](_0x20a275['attributes'],function(_0x572774){const _0x2abc95=_0x4012a7,_0x50a26d={};return _0x50a26d[_0x572774]={[Op[_0x2abc95('0x2a')]]:'%'+_0x2de115[_0x2abc95('0x29')]['filter']+'%'},_0x50a26d;})})),_0x20a275=_[_0x4012a7('0x5d')]({},_0x20a275,_0x2de115[_0x4012a7('0x5e')]),_0x3b3e34[_0x4012a7('0x2d')](_0x20a275);})[_0x12a95b('0x15')](function(_0x55fff4){const _0x57703a=_0x12a95b;if(_0x55fff4)return _0x5ab9e4=_0x55fff4[_0x57703a('0x2c')],typeof _0x2de115[_0x57703a('0x29')][_0x57703a('0x39')]==='undefined'&&(_0x20a275[_0x57703a('0x41')]=qs['limit'](_0x2de115[_0x57703a('0x29')][_0x57703a('0x41')]),_0x20a275[_0x57703a('0x48')]=qs[_0x57703a('0x48')](_0x2de115[_0x57703a('0x29')][_0x57703a('0x48')])),_0x3b3e34[_0x57703a('0x2d')](_0x20a275);})[_0x12a95b('0x15')](function(_0x349f1e){if(_0x349f1e)return _0x349f1e?{'count':_0x5ab9e4,'rows':_0x349f1e}:null;})[_0x12a95b('0x15')](respondWithResult(_0x103f1a,null))[_0x12a95b('0x62')](handleError(_0x103f1a,null));},exports[_0x5481c1('0x1a')]=function(_0x4ffb0f,_0x4d5930){const _0x3eb9b7=_0x5481c1;return _0x4ffb0f[_0x3eb9b7('0x13')]['id']&&delete _0x4ffb0f[_0x3eb9b7('0x13')]['id'],db[_0x3eb9b7('0x53')][_0x3eb9b7('0x2e')]({'where':{'id':_0x4ffb0f[_0x3eb9b7('0x3d')]['id']}})[_0x3eb9b7('0x15')](handleEntityNotFound(_0x4d5930,null))[_0x3eb9b7('0x15')](function(_0x2e472c){const _0x18d23d=_0x3eb9b7;if(_0x2e472c)return _0x4ffb0f[_0x18d23d('0x13')][_0x18d23d('0x40')]=_0x2e472c['id'],_0x4ffb0f[_0x18d23d('0x13')][_0x18d23d('0x42')]=integrations['getSubjects'](_0x4ffb0f[_0x18d23d('0x13')][_0x18d23d('0x63')],_0x4ffb0f['body'][_0x18d23d('0x0')]),_0x4ffb0f[_0x18d23d('0x13')][_0x18d23d('0x2f')]=integrations['getDescriptions'](_0x4ffb0f[_0x18d23d('0x13')][_0x18d23d('0x63')],_0x4ffb0f['body']['type']),db[_0x18d23d('0x36')]['create'](_0x4ffb0f[_0x18d23d('0x13')],{'include':[{'model':db[_0x18d23d('0x4d')],'as':_0x18d23d('0x42')},{'model':db[_0x18d23d('0x4d')],'as':_0x18d23d('0x2f')}]});return null;})[_0x3eb9b7('0x15')](respondWithResult(_0x4d5930,null))[_0x3eb9b7('0x62')](handleError(_0x4d5930,null));};function getAccessToken(_0xbd1b0b){return new Promise(function(_0x3a391f,_0x1a4f9f){const _0x57a5e7=a346_0x3478;let _0x4b3f9d;switch(_0xbd1b0b[_0x57a5e7('0x7')]){case'US':_0x4b3f9d=_0x57a5e7('0xe');break;case'AU':_0x4b3f9d='https://accounts.zoho.com.au';break;case'EU':_0x4b3f9d=_0x57a5e7('0x24');break;case'IN':_0x4b3f9d=_0x57a5e7('0x5a');break;case'CN':_0x4b3f9d='https://accounts.zoho.com.cn';break;default:_0x4b3f9d=_0x57a5e7('0x24');break;}const _0x50fbd3={'method':_0x57a5e7('0x50'),'uri':_0x4b3f9d+'/oauth/v2/token','qs':{'refresh_token':_0xbd1b0b[_0x57a5e7('0x22')],'client_id':_0xbd1b0b['clientId'],'client_secret':_0xbd1b0b['clientSecret'],'grant_type':_0x57a5e7('0x1f')},'json':!![]};return rp(_0x50fbd3)[_0x57a5e7('0x15')](function(_0x4d55c8){_0x4d55c8['access_token']?_0x3a391f(_0x4d55c8['access_token']):_0x1a4f9f('Unable\x20to\x20retrieve\x20the\x20access\x20token');})[_0x57a5e7('0x62')](function(_0x333e1d){_0x1a4f9f(_0x333e1d);});});}exports['getFields']=function(_0x4b37ca,_0x112a8a){const _0x5f2a45=_0x5481c1;let _0x34ff09,_0x24a9e7,_0x4761fe,_0x4988bf;return db[_0x5f2a45('0x53')][_0x5f2a45('0x2e')]({'where':{'id':_0x4b37ca['params']['id']},'attributes':['id',_0x5f2a45('0x31'),'zone','clientId','clientSecret',_0x5f2a45('0x4'),_0x5f2a45('0x56'),_0x5f2a45('0x22')]})['then'](handleEntityNotFound(_0x112a8a,null))[_0x5f2a45('0x15')](function(_0x17bce1){const _0x4a293c=_0x5f2a45;_0x4988bf=_0x17bce1,_0x34ff09=_0x4988bf[_0x4a293c('0x31')],_0x24a9e7=_0x34ff09==='zoho.eu'?'eu':_0x4a293c('0x49'),_0x4761fe=_0x4988bf[_0x4a293c('0x4')];const _0xc5c32d=_0x4761fe[_0x4a293c('0x26')](-0x1);(_0xc5c32d==='/'||_0xc5c32d==='\x5c'||_0xc5c32d===':')&&(_0x4761fe=_0x4761fe[_0x4a293c('0x27')](0x0,_0x4761fe[_0x4a293c('0x14')](_0xc5c32d)));if(!_0x4988bf[_0x4a293c('0x22')])throw new Error(_0x4a293c('0x60'));return getAccessToken(_0x4988bf);})[_0x5f2a45('0x15')](function(_0x1e68c3){const _0x32c97d=_0x5f2a45;if(_0x1e68c3)return rp({'method':_0x32c97d('0x20'),'uri':util[_0x32c97d('0x5c')](_0x32c97d('0x23'),_0x24a9e7),'qs':{'module':'Calls'},'headers':{'Authorization':_0x32c97d('0x8')+_0x1e68c3},'json':!![]});})[_0x5f2a45('0x15')](function(_0x25b9ec){const _0x135a58=_0x5f2a45;if(_0x25b9ec){if(_0x25b9ec[_0x135a58('0x3')]&&_0x25b9ec['response']['error'])throw new Error(_0x25b9ec[_0x135a58('0x3')][_0x135a58('0x67')]['message']);const _0x4ba1f1=[];let _0x48fb89=[];const _0x116d6b=[_0x135a58('0x43'),_0x135a58('0x30'),_0x135a58('0x3a'),'WhoId',_0x135a58('0xa'),_0x135a58('0x5b'),_0x135a58('0x5f'),'Call_Type'];_0x48fb89=_[_0x135a58('0x16')](_0x25b9ec['fields'],function(_0x20ca58){const _0x3b9588=_0x135a58;return _0x116d6b[_0x3b9588('0x33')](_0x20ca58['api_name']);});for(let _0x4e5f9c=0x0;_0x4e5f9c<_0x48fb89['length'];_0x4e5f9c++){_0x48fb89[_0x4e5f9c][_0x135a58('0x68')]===![]&&_0x4ba1f1[_0x135a58('0x17')]({'id':_0x48fb89[_0x4e5f9c]['id'],'name':_0x48fb89[_0x4e5f9c]['display_label'],'custom':_0x48fb89[_0x4e5f9c][_0x135a58('0x61')],'options':_0x48fb89[_0x4e5f9c][_0x135a58('0x46')]===_0x135a58('0x55')&&_0x48fb89[_0x4e5f9c][_0x135a58('0x69')][_0x135a58('0x2c')]>-0x1?_[_0x135a58('0x64')](_0x48fb89[_0x4e5f9c]['pick_list_values'],function(_0x1fb41e){return{'name':_0x1fb41e,'value':_0x1fb41e};}):[]});}return{'count':_0x4ba1f1[_0x135a58('0x2c')],'rows':_0x4ba1f1};}else return{'count':0x0,'rows':[]};})[_0x5f2a45('0x15')](respondWithResult(_0x112a8a,null))['catch'](function(_0x29e2b6){const _0x3aef9b=_0x5f2a45;let _0x5cdeb0=_0x4b37ca[_0x3aef9b('0x29')][_0x3aef9b('0x1c')]?0x1f4:_0x29e2b6[_0x3aef9b('0x4b')]||0x1f4;logger[_0x3aef9b('0x67')](_0x3aef9b('0x44'),_0x3aef9b('0x4f'),_0x5cdeb0,JSON['stringify'](_0x29e2b6)),delete _0x29e2b6[_0x3aef9b('0x5')],_0x5cdeb0===0x191&&(_0x5cdeb0=0x190),_0x112a8a[_0x3aef9b('0x2b')](_0x5cdeb0)['send'](_0x4b37ca[_0x3aef9b('0x29')][_0x3aef9b('0x1c')]?{'message':_0x3aef9b('0x18'),'statusCode':_0x29e2b6[_0x3aef9b('0x4b')]}:_0x29e2b6);});}; \ No newline at end of file +const a346_0x5d58=['pick_list_values','test','error','https://accounts.zoho.com.cn','stack','https://www.zohoapis.%s/crm/v2/settings/fields','fieldName','order','statusCode','query','create','filter','code','getFields,\x20%s,\x20%s,\x20%s','type','update','zone','json','https://accounts.zoho.in','https://accounts.zoho.eu','/oauth/v2/token','like','stringify','ZohoField','filters','rawAttributes','Call_Type','params','attributes','../../config/logger','intersection','GET','request-promise-native','include','pick','host','count','https://accounts.zoho.com','channel','addConfiguration','WhoId','limit','map','key','serverUrl','send','Content-Range','includes','refreshToken','keys','fields','picklist','findAll','format','model','offset','then','Wrong\x20credentials','Call_Start_Time','options','VIRTUAL','sort','api','Subjects','sequelize','api_name','nolimit','response','length','clientId','show','merge','destroy','getFields','ZohoAccount','Unable\x20to\x20retrieve\x20the\x20access\x20token','where','message','getDescriptions','set','util','com','getConfigurations','Description','body','lastIndexOf','catch','findOne','sendStatus','end','undefined','Descriptions','ZohoConfiguration','Subject','status','zoho.eu','access_token','refresh_token','display_label','name','clientSecret','../../mysqldb','Call_Result'];(function(_0x46b278,_0x5d5822){const _0x286d4c=function(_0x6bd96e){while(--_0x6bd96e){_0x46b278['push'](_0x46b278['shift']());}};_0x286d4c(++_0x5d5822);}(a346_0x5d58,0x6e));const a346_0x286d=function(_0x46b278,_0x5d5822){_0x46b278=_0x46b278-0x0;let _0x286d4c=a346_0x5d58[_0x46b278];return _0x286d4c;};const _0x226009=a346_0x286d;'use strict';const rp=require(_0x226009('0x19')),util=require(_0x226009('0x49')),_=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x226009('0x16'))(_0x226009('0x37')),db=require(_0x226009('0x5e'))['db'],{Op}=require(_0x226009('0x39')),integrations=require('../../components/integrations/configuration');function respondWithResult(_0x6bd96e,_0x50edcd){return _0x50edcd=_0x50edcd||0xc8,function(_0x384fd3){const _0x390cec=a346_0x286d;if(_0x384fd3)return _0x6bd96e[_0x390cec('0x57')](_0x50edcd)[_0x390cec('0xa')](_0x384fd3);};}function respondWithFilteredResult(_0x30a355,_0x3ce170){return function(_0x175050){const _0x3ec4e0=a346_0x286d;if(_0x175050){const _0x59f4b6=_0x175050[_0x3ec4e0('0x1d')],_0x555a73=_0x3ce170['offset'];let _0x239519=_0x3ce170[_0x3ec4e0('0x30')]+_0x3ce170[_0x3ec4e0('0x22')],_0x340aad;return _0x239519>=_0x59f4b6?(_0x239519=_0x59f4b6,_0x340aad=0xc8):_0x340aad=0xce,_0x30a355[_0x3ec4e0('0x57')](_0x340aad),_0x30a355[_0x3ec4e0('0x48')](_0x3ec4e0('0x27'),_0x555a73+'-'+_0x239519+'/'+_0x59f4b6)[_0x3ec4e0('0xa')](_0x175050);}return null;};}function saveUpdates(_0x3931c1){return function(_0x357c1d){const _0xc73b95=a346_0x286d;if(_0x357c1d)return _0x357c1d['update'](_0x3931c1)[_0xc73b95('0x31')](function(_0x493247){return _0x493247;});return null;};}function removeEntity(_0x5094c8){return function(_0x1b5339){const _0x3d28b2=a346_0x286d;if(_0x1b5339)return _0x1b5339[_0x3d28b2('0x41')]()[_0x3d28b2('0x31')](function(){const _0x19aafd=_0x3d28b2;_0x5094c8[_0x19aafd('0x57')](0xcc)[_0x19aafd('0x52')]();});};}function handleEntityNotFound(_0x2279dd){return function(_0x387c82){const _0x207a00=a346_0x286d;return!_0x387c82&&_0x2279dd[_0x207a00('0x51')](0x194),_0x387c82;};}function handleError(_0x5d96d8,_0x458122){return _0x458122=_0x458122||0x1f4,function(_0x50c15f){const _0x28391f=a346_0x286d;logger[_0x28391f('0x62')](_0x50c15f[_0x28391f('0x64')]),_0x50c15f[_0x28391f('0x5c')]&&delete _0x50c15f[_0x28391f('0x5c')],_0x5d96d8[_0x28391f('0x57')](_0x458122)[_0x28391f('0x26')](_0x50c15f);};}exports['index']=function(_0x2402bb,_0x2f2bad){const _0x39c099=_0x226009;let _0x5f4130={};const _0x302eb9={},_0x3793f9={'count':0x0,'rows':[]},_0x167316=_[_0x39c099('0x23')](db[_0x39c099('0x43')][_0x39c099('0x12')],function(_0x400310){const _0x384395=_0x39c099;return{'name':_0x400310[_0x384395('0x66')],'type':_0x400310[_0x384395('0x7')][_0x384395('0x24')]};});_0x302eb9[_0x39c099('0x2f')]=_[_0x39c099('0x23')](_0x167316,_0x39c099('0x5c')),_0x302eb9[_0x39c099('0x2')]=_['keys'](_0x2402bb['query']),_0x302eb9[_0x39c099('0x11')]=_[_0x39c099('0x17')](_0x302eb9[_0x39c099('0x2f')],_0x302eb9[_0x39c099('0x2')]),_0x5f4130['attributes']=_['intersection'](_0x302eb9[_0x39c099('0x2f')],qs[_0x39c099('0x2b')](_0x2402bb['query'][_0x39c099('0x2b')])),_0x5f4130[_0x39c099('0x15')]=_0x5f4130['attributes'][_0x39c099('0x3d')]?_0x5f4130[_0x39c099('0x15')]:_0x302eb9[_0x39c099('0x2f')];typeof _0x2402bb['query'][_0x39c099('0x3b')]===_0x39c099('0x53')&&(_0x5f4130['limit']=qs['limit'](_0x2402bb[_0x39c099('0x2')][_0x39c099('0x22')]),_0x5f4130['offset']=qs[_0x39c099('0x30')](_0x2402bb[_0x39c099('0x2')][_0x39c099('0x30')]));_0x5f4130[_0x39c099('0x0')]=qs[_0x39c099('0x36')](_0x2402bb[_0x39c099('0x2')][_0x39c099('0x36')]),_0x5f4130[_0x39c099('0x45')]=qs[_0x39c099('0x11')](_[_0x39c099('0x1b')](_0x2402bb[_0x39c099('0x2')],_0x302eb9[_0x39c099('0x11')]),_0x167316);_0x2402bb[_0x39c099('0x2')]['filter']&&(_0x5f4130[_0x39c099('0x45')]=_[_0x39c099('0x40')](_0x5f4130['where'],{[Op['or']]:_[_0x39c099('0x23')](_0x167316,function(_0x356728){const _0x49985c=_0x39c099;if(_0x356728[_0x49985c('0x7')]!==_0x49985c('0x35')){const _0x5adcca={};return _0x5adcca[_0x356728[_0x49985c('0x5c')]]={[Op[_0x49985c('0xe')]]:'%'+_0x2402bb[_0x49985c('0x2')][_0x49985c('0x4')]+'%'},_0x5adcca;}})}));_0x5f4130=_[_0x39c099('0x40')]({},_0x5f4130,_0x2402bb[_0x39c099('0x34')]);const _0x51857b={'where':_0x5f4130[_0x39c099('0x45')]};return db[_0x39c099('0x43')]['count'](_0x51857b)[_0x39c099('0x31')](function(_0x41f2c7){const _0x250857=_0x39c099;return _0x3793f9['count']=_0x41f2c7,_0x2402bb[_0x250857('0x2')]['includeAll']&&(_0x5f4130['include']=[{'all':!![]}]),db[_0x250857('0x43')][_0x250857('0x2d')](_0x5f4130);})[_0x39c099('0x31')](function(_0x308755){return _0x3793f9['rows']=_0x308755,_0x3793f9;})[_0x39c099('0x31')](respondWithFilteredResult(_0x2f2bad,_0x5f4130))[_0x39c099('0x4f')](handleError(_0x2f2bad,null));},exports[_0x226009('0x3f')]=function(_0x3bedf0,_0x3365f8){const _0x883925=_0x226009;let _0x562752={'raw':![],'where':{'id':_0x3bedf0[_0x883925('0x14')]['id']}};const _0x26f5b0={};return _0x26f5b0[_0x883925('0x2f')]=_[_0x883925('0x2a')](db[_0x883925('0x43')][_0x883925('0x12')]),_0x26f5b0[_0x883925('0x2')]=_[_0x883925('0x2a')](_0x3bedf0[_0x883925('0x2')]),_0x26f5b0['filters']=_[_0x883925('0x17')](_0x26f5b0[_0x883925('0x2f')],_0x26f5b0['query']),_0x562752[_0x883925('0x15')]=_[_0x883925('0x17')](_0x26f5b0[_0x883925('0x2f')],qs[_0x883925('0x2b')](_0x3bedf0[_0x883925('0x2')][_0x883925('0x2b')])),_0x562752[_0x883925('0x15')]=_0x562752['attributes']['length']?_0x562752[_0x883925('0x15')]:_0x26f5b0[_0x883925('0x2f')],_0x3bedf0['query']['includeAll']&&(_0x562752[_0x883925('0x1a')]=[{'all':!![]}]),_0x562752=_[_0x883925('0x40')]({},_0x562752,_0x3bedf0[_0x883925('0x34')]),db['ZohoAccount'][_0x883925('0x50')](_0x562752)[_0x883925('0x31')](handleEntityNotFound(_0x3365f8,null))['then'](respondWithResult(_0x3365f8,null))[_0x883925('0x4f')](handleError(_0x3365f8,null));},exports[_0x226009('0x3')]=function(_0xa82d56,_0x548c3c){const _0x16dbcb=_0x226009;return db['ZohoAccount']['create'](_0xa82d56[_0x16dbcb('0x4d')],{})[_0x16dbcb('0x31')](respondWithResult(_0x548c3c,0xc9))[_0x16dbcb('0x4f')](handleError(_0x548c3c,null));},exports[_0x226009('0x8')]=function(_0x5032f2,_0x3a4861){const _0x522177=_0x226009;return _0x5032f2[_0x522177('0x4d')]['id']&&delete _0x5032f2['body']['id'],db[_0x522177('0x43')][_0x522177('0x50')]({'where':{'id':_0x5032f2[_0x522177('0x14')]['id']}})['then'](handleEntityNotFound(_0x3a4861,null))[_0x522177('0x31')](saveUpdates(_0x5032f2['body'],null))['then'](respondWithResult(_0x3a4861,null))['catch'](handleError(_0x3a4861,null));},exports['destroy']=function(_0x304abf,_0x34fea3){const _0x58d3b1=_0x226009;return db[_0x58d3b1('0x43')]['findOne']({'where':{'id':_0x304abf[_0x58d3b1('0x14')]['id']}})[_0x58d3b1('0x31')](handleEntityNotFound(_0x34fea3,null))[_0x58d3b1('0x31')](removeEntity(_0x34fea3,null))['catch'](handleError(_0x34fea3,null));},exports[_0x226009('0x4b')]=function(_0x46681a,_0x4c9807){const _0x2502e3=_0x226009;let _0x34e7ed={};const _0x5d07ce={};let _0x27ea42,_0x591957;return db[_0x2502e3('0x43')][_0x2502e3('0x50')]({'where':{'id':_0x46681a['params']['id']}})[_0x2502e3('0x31')](handleEntityNotFound(_0x4c9807,null))[_0x2502e3('0x31')](function(_0x5e272c){const _0x36a250=_0x2502e3;if(_0x5e272c)return _0x27ea42=_0x5e272c,_0x5d07ce['model']=_[_0x36a250('0x2a')](db[_0x36a250('0x55')][_0x36a250('0x12')]),_0x5d07ce[_0x36a250('0x2')]=_[_0x36a250('0x2a')](_0x46681a['query']),_0x5d07ce['filters']=_['intersection'](_0x5d07ce[_0x36a250('0x2f')],_0x5d07ce[_0x36a250('0x2')]),_0x34e7ed['attributes']=_[_0x36a250('0x17')](_0x5d07ce['model'],qs[_0x36a250('0x2b')](_0x46681a[_0x36a250('0x2')][_0x36a250('0x2b')])),_0x34e7ed[_0x36a250('0x15')]=_0x34e7ed[_0x36a250('0x15')][_0x36a250('0x3d')]?_0x34e7ed[_0x36a250('0x15')]:_0x5d07ce[_0x36a250('0x2f')],_0x34e7ed[_0x36a250('0x0')]=qs[_0x36a250('0x36')](_0x46681a['query'][_0x36a250('0x36')]),_0x34e7ed['where']=qs[_0x36a250('0x11')](_[_0x36a250('0x1b')](_0x46681a[_0x36a250('0x2')],_0x5d07ce[_0x36a250('0x11')])),_0x46681a[_0x36a250('0x2')][_0x36a250('0x4')]&&(_0x34e7ed[_0x36a250('0x45')]=_[_0x36a250('0x40')](_0x34e7ed[_0x36a250('0x45')],{[Op['or']]:_['map'](_0x34e7ed['attributes'],function(_0x1b3bdb){const _0x1c244f=_0x36a250,_0x156351={};return _0x156351[_0x1b3bdb]={[Op[_0x1c244f('0xe')]]:'%'+_0x46681a[_0x1c244f('0x2')][_0x1c244f('0x4')]+'%'},_0x156351;})})),_0x34e7ed=_[_0x36a250('0x40')]({},_0x34e7ed,_0x46681a[_0x36a250('0x34')]),_0x27ea42[_0x36a250('0x4b')](_0x34e7ed);})[_0x2502e3('0x31')](function(_0x3f2fce){const _0x1870fb=_0x2502e3;if(_0x3f2fce)return _0x591957=_0x3f2fce[_0x1870fb('0x3d')],typeof _0x46681a[_0x1870fb('0x2')][_0x1870fb('0x3b')]===_0x1870fb('0x53')&&(_0x34e7ed['limit']=qs[_0x1870fb('0x22')](_0x46681a[_0x1870fb('0x2')][_0x1870fb('0x22')]),_0x34e7ed[_0x1870fb('0x30')]=qs[_0x1870fb('0x30')](_0x46681a[_0x1870fb('0x2')][_0x1870fb('0x30')])),_0x27ea42[_0x1870fb('0x4b')](_0x34e7ed);})[_0x2502e3('0x31')](function(_0x20d508){if(_0x20d508)return _0x20d508?{'count':_0x591957,'rows':_0x20d508}:null;})[_0x2502e3('0x31')](respondWithResult(_0x4c9807,null))['catch'](handleError(_0x4c9807,null));},exports[_0x226009('0x20')]=function(_0x3cccd5,_0x1d0ac1){const _0x95278d=_0x226009;return _0x3cccd5[_0x95278d('0x4d')]['id']&&delete _0x3cccd5['body']['id'],db[_0x95278d('0x43')][_0x95278d('0x50')]({'where':{'id':_0x3cccd5['params']['id']}})['then'](handleEntityNotFound(_0x1d0ac1,null))[_0x95278d('0x31')](function(_0x45004c){const _0x354384=_0x95278d;if(_0x45004c)return _0x3cccd5['body']['AccountId']=_0x45004c['id'],_0x3cccd5[_0x354384('0x4d')][_0x354384('0x38')]=integrations['getSubjects'](_0x3cccd5[_0x354384('0x4d')]['channel'],_0x3cccd5[_0x354384('0x4d')][_0x354384('0x7')]),_0x3cccd5[_0x354384('0x4d')][_0x354384('0x54')]=integrations[_0x354384('0x47')](_0x3cccd5[_0x354384('0x4d')][_0x354384('0x1f')],_0x3cccd5[_0x354384('0x4d')][_0x354384('0x7')]),db['ZohoConfiguration'][_0x354384('0x3')](_0x3cccd5[_0x354384('0x4d')],{'include':[{'model':db[_0x354384('0x10')],'as':'Subjects'},{'model':db[_0x354384('0x10')],'as':'Descriptions'}]});return null;})[_0x95278d('0x31')](respondWithResult(_0x1d0ac1,null))[_0x95278d('0x4f')](handleError(_0x1d0ac1,null));};function getAccessToken(_0x2295c3){return new Promise(function(_0xfe79d3,_0x25601d){const _0x381bf7=a346_0x286d;let _0x48fab2;switch(_0x2295c3['zone']){case'US':_0x48fab2=_0x381bf7('0x1e');break;case'AU':_0x48fab2='https://accounts.zoho.com.au';break;case'EU':_0x48fab2=_0x381bf7('0xc');break;case'IN':_0x48fab2=_0x381bf7('0xb');break;case'CN':_0x48fab2=_0x381bf7('0x63');break;default:_0x48fab2=_0x381bf7('0xc');break;}const _0x44b9cf={'method':'POST','uri':_0x48fab2+_0x381bf7('0xd'),'qs':{'refresh_token':_0x2295c3[_0x381bf7('0x29')],'client_id':_0x2295c3[_0x381bf7('0x3e')],'client_secret':_0x2295c3[_0x381bf7('0x5d')],'grant_type':_0x381bf7('0x5a')},'json':!![]};return rp(_0x44b9cf)[_0x381bf7('0x31')](function(_0xe03d78){const _0x58e8bc=_0x381bf7;_0xe03d78[_0x58e8bc('0x59')]?_0xfe79d3(_0xe03d78[_0x58e8bc('0x59')]):_0x25601d(_0x58e8bc('0x44'));})['catch'](function(_0x44a8b8){_0x25601d(_0x44a8b8);});});}exports[_0x226009('0x42')]=function(_0x1f1f76,_0xd97047){const _0x29cff4=_0x226009;let _0x11e1bf,_0x52d854,_0x6e848f,_0x2a93c3;return db['ZohoAccount']['findOne']({'where':{'id':_0x1f1f76['params']['id']},'attributes':['id',_0x29cff4('0x1c'),_0x29cff4('0x9'),'clientId',_0x29cff4('0x5d'),_0x29cff4('0x25'),_0x29cff4('0x5'),_0x29cff4('0x29')]})[_0x29cff4('0x31')](handleEntityNotFound(_0xd97047,null))[_0x29cff4('0x31')](function(_0x18fe33){const _0x8a58e1=_0x29cff4;_0x2a93c3=_0x18fe33,_0x11e1bf=_0x2a93c3['host'],_0x52d854=_0x11e1bf===_0x8a58e1('0x58')?'eu':_0x8a58e1('0x4a'),_0x6e848f=_0x2a93c3[_0x8a58e1('0x25')];const _0x5b02d1=_0x6e848f['slice'](-0x1);(_0x5b02d1==='/'||_0x5b02d1==='\x5c'||_0x5b02d1===':')&&(_0x6e848f=_0x6e848f['substring'](0x0,_0x6e848f[_0x8a58e1('0x4e')](_0x5b02d1)));if(!_0x2a93c3[_0x8a58e1('0x29')])throw new Error('Refresh\x20Token\x20not\x20available\x20for\x20the\x20account');return getAccessToken(_0x2a93c3);})[_0x29cff4('0x31')](function(_0x4b74a3){const _0x4ff8cc=_0x29cff4;if(_0x4b74a3)return rp({'method':_0x4ff8cc('0x18'),'uri':util[_0x4ff8cc('0x2e')](_0x4ff8cc('0x65'),_0x52d854),'qs':{'module':'Calls'},'headers':{'Authorization':'Zoho-oauthtoken\x20'+_0x4b74a3},'json':!![]});})[_0x29cff4('0x31')](function(_0x27c3dd){const _0x2f45fc=_0x29cff4;if(_0x27c3dd){if(_0x27c3dd[_0x2f45fc('0x3c')]&&_0x27c3dd[_0x2f45fc('0x3c')][_0x2f45fc('0x62')])throw new Error(_0x27c3dd['response'][_0x2f45fc('0x62')][_0x2f45fc('0x46')]);const _0x210a5c=[];let _0x3dcaff=[];const _0x1db51f=['Owner',_0x2f45fc('0x56'),_0x2f45fc('0x4c'),_0x2f45fc('0x21'),'Call_Duration',_0x2f45fc('0x5f'),_0x2f45fc('0x33'),_0x2f45fc('0x13')];_0x3dcaff=_['remove'](_0x27c3dd[_0x2f45fc('0x2b')],function(_0x2953bc){const _0x3bb947=_0x2f45fc;return _0x1db51f[_0x3bb947('0x28')](_0x2953bc[_0x3bb947('0x3a')]);});for(let _0x2f2b4d=0x0;_0x2f2b4d<_0x3dcaff['length'];_0x2f2b4d++){_0x3dcaff[_0x2f2b4d]['system_mandatory']===![]&&_0x210a5c['push']({'id':_0x3dcaff[_0x2f2b4d]['id'],'name':_0x3dcaff[_0x2f2b4d][_0x2f45fc('0x5b')],'custom':_0x3dcaff[_0x2f2b4d]['custom_field'],'options':_0x3dcaff[_0x2f2b4d]['data_type']===_0x2f45fc('0x2c')&&_0x3dcaff[_0x2f2b4d]['pick_list_values']['length']>-0x1?_[_0x2f45fc('0x23')](_0x3dcaff[_0x2f2b4d][_0x2f45fc('0x60')],function(_0xbb2e7e){return{'name':_0xbb2e7e,'value':_0xbb2e7e};}):[]});}return{'count':_0x210a5c['length'],'rows':_0x210a5c};}else return{'count':0x0,'rows':[]};})[_0x29cff4('0x31')](respondWithResult(_0xd97047,null))[_0x29cff4('0x4f')](function(_0x1b31d1){const _0x5d8522=_0x29cff4;let _0x2966d7=_0x1f1f76[_0x5d8522('0x2')]['test']?0x1f4:_0x1b31d1[_0x5d8522('0x1')]||0x1f4;logger[_0x5d8522('0x62')](_0x5d8522('0x6'),_0x5d8522('0x42'),_0x2966d7,JSON[_0x5d8522('0xf')](_0x1b31d1)),delete _0x1b31d1[_0x5d8522('0x5c')],_0x2966d7===0x191&&(_0x2966d7=0x190),_0xd97047['status'](_0x2966d7)['send'](_0x1f1f76['query'][_0x5d8522('0x61')]?{'message':_0x5d8522('0x32'),'statusCode':_0x1b31d1[_0x5d8522('0x1')]}:_0x1b31d1);});}; \ No newline at end of file diff --git a/server/api/intZohoAccount/intZohoAccount.model.js b/server/api/intZohoAccount/intZohoAccount.model.js index 9dd8d38..e8eda48 100644 --- a/server/api/intZohoAccount/intZohoAccount.model.js +++ b/server/api/intZohoAccount/intZohoAccount.model.js @@ -1 +1 @@ -const a347_0x196a=['https://accounts.zoho.eu','clientId','ZohoAccount,\x20Refresh\x20token\x20successfully\x20generated\x20for\x20account\x20\x22%s\x22\x20#%d','zone','application/x-www-form-urlencoded','then','name','./intZohoAccount.attributes','exports','define','error','/oauth/v2/token','parse','ZohoAccount,\x20Unable\x20to\x20generate\x20the\x20refresh\x20token\x20for\x20account\x20\x22%s\x22\x20#%d','https://accounts.zoho.in','refreshToken','code','serverUrl','substring','slice','clientSecret','refresh_token','lastIndexOf','util','request-promise-native','format','https://accounts.zoho.com','changed','inspect','catch','host','https://accounts.zoho.com.cn','info','authorization_code','POST','api','https://accounts.zoho.com.au'];(function(_0x320e15,_0x196ac5){const _0x4a4736=function(_0x343a99){while(--_0x343a99){_0x320e15['push'](_0x320e15['shift']());}};_0x4a4736(++_0x196ac5);}(a347_0x196a,0x176));const a347_0x4a47=function(_0x320e15,_0x196ac5){_0x320e15=_0x320e15-0x0;let _0x4a4736=a347_0x196a[_0x320e15];return _0x4a4736;};const _0x3614cc=a347_0x4a47;'use strict';const util=require(_0x3614cc('0x13')),logger=require('../../config/logger')(_0x3614cc('0x1f')),rp=require(_0x3614cc('0x14')),attributes=require(_0x3614cc('0x3'));module[_0x3614cc('0x4')]=function(_0x343a99){const _0x48ed65=_0x3614cc,_0x2b61e0=_0x343a99[_0x48ed65('0x5')]('ZohoAccount',attributes,{'tableName':'int_zoho_accounts','paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeCreate':function(_0x1bef7b){const _0x1abc3=_0x48ed65;if(_0x1bef7b[_0x1abc3('0x17')]('zone')||_0x1bef7b[_0x1abc3('0x17')]('serverUrl')||_0x1bef7b[_0x1abc3('0x17')](_0x1abc3('0x22'))||_0x1bef7b['changed']('clientSecret')||_0x1bef7b[_0x1abc3('0x17')](_0x1abc3('0xc'))||_0x1bef7b[_0x1abc3('0x17')](_0x1abc3('0x1a'))){let _0xd8e140,_0x17f41c;_0xd8e140=_0x1bef7b[_0x1abc3('0xd')];const _0x127ef3=_0xd8e140[_0x1abc3('0xf')](-0x1);(_0x127ef3==='/'||_0x127ef3==='\x5c'||_0x127ef3===':')&&(_0xd8e140=_0xd8e140[_0x1abc3('0xe')](0x0,_0xd8e140[_0x1abc3('0x12')](_0x127ef3)));switch(_0x1bef7b[_0x1abc3('0x24')]){case'US':_0x17f41c='https://accounts.zoho.com';break;case'AU':_0x17f41c='https://accounts.zoho.com.au';break;case'IN':_0x17f41c=_0x1abc3('0xa');break;case'CN':_0x17f41c=_0x1abc3('0x1b');break;default:_0x17f41c=_0x1abc3('0x21');break;}const _0x5a3c59={'method':_0x1abc3('0x1e'),'uri':_0x17f41c+_0x1abc3('0x7'),'form':{'grant_type':_0x1abc3('0x1d'),'client_id':_0x1bef7b[_0x1abc3('0x22')],'client_secret':_0x1bef7b[_0x1abc3('0x10')],'redirect_uri':_0x1bef7b[_0x1abc3('0xd')],'code':_0x1bef7b['code']},'headers':{'Content-Type':_0x1abc3('0x0')}};let _0x2abf7d=null;return rp(_0x5a3c59)[_0x1abc3('0x1')](function(_0xf8e538){const _0x1ab67a=_0x1abc3;return _0x2abf7d=JSON[_0x1ab67a('0x8')](_0xf8e538),_0x2abf7d[_0x1ab67a('0x11')]?(_0x1bef7b[_0x1ab67a('0xb')]=_0x2abf7d[_0x1ab67a('0x11')],logger[_0x1ab67a('0x1c')](util[_0x1ab67a('0x15')](_0x1ab67a('0x23'),_0x1bef7b[_0x1ab67a('0x2')],_0x1bef7b['id']))):logger[_0x1ab67a('0x6')](util[_0x1ab67a('0x15')](_0x1ab67a('0x9'),_0x1bef7b['name'],_0x1bef7b['id']),util[_0x1ab67a('0x18')](_0x2abf7d,{'showHidden':![],'depth':null})),null;})[_0x1abc3('0x19')](function(_0x1bdcf9){const _0x3d74b8=_0x1abc3;return logger[_0x3d74b8('0x6')](util[_0x3d74b8('0x15')](_0x3d74b8('0x9'),_0x1bef7b['name'],_0x1bef7b['id']),util[_0x3d74b8('0x18')](_0x2abf7d,{'showHidden':![],'depth':null})),_0x1bdcf9;});}else return null;},'beforeUpdate':function(_0x33a25e){const _0x22f8ed=_0x48ed65;if(_0x33a25e['changed'](_0x22f8ed('0x24'))||_0x33a25e[_0x22f8ed('0x17')]('serverUrl')||_0x33a25e[_0x22f8ed('0x17')](_0x22f8ed('0x22'))||_0x33a25e['changed']('clientSecret')||_0x33a25e['changed'](_0x22f8ed('0xc'))||_0x33a25e[_0x22f8ed('0x17')](_0x22f8ed('0x1a'))){let _0x1f15da,_0x1d4ece;_0x1f15da=_0x33a25e[_0x22f8ed('0xd')];const _0x9049ff=_0x1f15da[_0x22f8ed('0xf')](-0x1);(_0x9049ff==='/'||_0x9049ff==='\x5c'||_0x9049ff===':')&&(_0x1f15da=_0x1f15da[_0x22f8ed('0xe')](0x0,_0x1f15da[_0x22f8ed('0x12')](_0x9049ff)));switch(_0x33a25e[_0x22f8ed('0x24')]){case'US':_0x1d4ece=_0x22f8ed('0x16');break;case'AU':_0x1d4ece=_0x22f8ed('0x20');break;case'IN':_0x1d4ece=_0x22f8ed('0xa');break;case'CN':_0x1d4ece=_0x22f8ed('0x1b');break;default:_0x1d4ece='https://accounts.zoho.eu';break;}const _0x3bad1d={'method':_0x22f8ed('0x1e'),'uri':_0x1d4ece+'/oauth/v2/token','form':{'grant_type':'authorization_code','client_id':_0x33a25e['clientId'],'client_secret':_0x33a25e[_0x22f8ed('0x10')],'redirect_uri':_0x33a25e[_0x22f8ed('0xd')],'code':_0x33a25e[_0x22f8ed('0xc')]},'headers':{'Content-Type':_0x22f8ed('0x0')}};let _0x68bce6=null;return rp(_0x3bad1d)[_0x22f8ed('0x1')](function(_0x27869a){const _0x172b63=_0x22f8ed;return _0x68bce6=JSON[_0x172b63('0x8')](_0x27869a),_0x68bce6[_0x172b63('0x11')]?(_0x33a25e[_0x172b63('0xb')]=_0x68bce6[_0x172b63('0x11')],logger[_0x172b63('0x1c')](util[_0x172b63('0x15')](_0x172b63('0x23'),_0x33a25e[_0x172b63('0x2')],_0x33a25e['id']))):logger[_0x172b63('0x6')](util[_0x172b63('0x15')](_0x172b63('0x9'),_0x33a25e[_0x172b63('0x2')],_0x33a25e['id']),util[_0x172b63('0x18')](_0x68bce6,{'showHidden':![],'depth':null})),null;})[_0x22f8ed('0x19')](function(_0x184268){const _0x5a7dce=_0x22f8ed;return logger['error'](util[_0x5a7dce('0x15')](_0x5a7dce('0x9'),_0x33a25e['name'],_0x33a25e['id']),util[_0x5a7dce('0x18')](_0x68bce6,{'showHidden':![],'depth':null})),_0x184268;});}else return null;}}});return _0x2b61e0;}; \ No newline at end of file +const a347_0x4889=['format','slice','exports','authorization_code','error','clientId','define','ZohoAccount,\x20Unable\x20to\x20generate\x20the\x20refresh\x20token\x20for\x20account\x20\x22%s\x22\x20#%d','then','request-promise-native','zone','https://accounts.zoho.com.au','code','ZohoAccount,\x20Refresh\x20token\x20successfully\x20generated\x20for\x20account\x20\x22%s\x22\x20#%d','clientSecret','https://accounts.zoho.com','/oauth/v2/token','parse','refreshToken','serverUrl','https://accounts.zoho.com.cn','util','api','int_zoho_accounts','host','https://accounts.zoho.in','https://accounts.zoho.eu','POST','inspect','name','catch','substring','refresh_token','changed','lastIndexOf'];(function(_0x30dc9b,_0x488926){const _0x57be46=function(_0x4ff9cf){while(--_0x4ff9cf){_0x30dc9b['push'](_0x30dc9b['shift']());}};_0x57be46(++_0x488926);}(a347_0x4889,0x1b5));const a347_0x57be=function(_0x30dc9b,_0x488926){_0x30dc9b=_0x30dc9b-0x0;let _0x57be46=a347_0x4889[_0x30dc9b];return _0x57be46;};const _0x52bc50=a347_0x57be;'use strict';const util=require(_0x52bc50('0x4')),logger=require('../../config/logger')(_0x52bc50('0x5')),rp=require(_0x52bc50('0x1b')),attributes=require('./intZohoAccount.attributes');module[_0x52bc50('0x14')]=function(_0x4ff9cf){const _0x27b209=_0x52bc50,_0x14a18e=_0x4ff9cf[_0x27b209('0x18')]('ZohoAccount',attributes,{'tableName':_0x27b209('0x6'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeCreate':function(_0x1bb2b1){const _0x2791b1=_0x27b209;if(_0x1bb2b1[_0x2791b1('0x10')]('zone')||_0x1bb2b1[_0x2791b1('0x10')]('serverUrl')||_0x1bb2b1[_0x2791b1('0x10')](_0x2791b1('0x17'))||_0x1bb2b1[_0x2791b1('0x10')]('clientSecret')||_0x1bb2b1[_0x2791b1('0x10')](_0x2791b1('0x1e'))||_0x1bb2b1[_0x2791b1('0x10')](_0x2791b1('0x7'))){let _0x353e00,_0xfaeb94;_0x353e00=_0x1bb2b1[_0x2791b1('0x2')];const _0x2a4691=_0x353e00[_0x2791b1('0x13')](-0x1);(_0x2a4691==='/'||_0x2a4691==='\x5c'||_0x2a4691===':')&&(_0x353e00=_0x353e00[_0x2791b1('0xe')](0x0,_0x353e00[_0x2791b1('0x11')](_0x2a4691)));switch(_0x1bb2b1[_0x2791b1('0x1c')]){case'US':_0xfaeb94=_0x2791b1('0x21');break;case'AU':_0xfaeb94='https://accounts.zoho.com.au';break;case'IN':_0xfaeb94=_0x2791b1('0x8');break;case'CN':_0xfaeb94=_0x2791b1('0x3');break;default:_0xfaeb94=_0x2791b1('0x9');break;}const _0x310853={'method':'POST','uri':_0xfaeb94+_0x2791b1('0x22'),'form':{'grant_type':_0x2791b1('0x15'),'client_id':_0x1bb2b1[_0x2791b1('0x17')],'client_secret':_0x1bb2b1[_0x2791b1('0x20')],'redirect_uri':_0x1bb2b1[_0x2791b1('0x2')],'code':_0x1bb2b1[_0x2791b1('0x1e')]},'headers':{'Content-Type':'application/x-www-form-urlencoded'}};let _0x255703=null;return rp(_0x310853)[_0x2791b1('0x1a')](function(_0x4022a5){const _0x3ca794=_0x2791b1;return _0x255703=JSON[_0x3ca794('0x0')](_0x4022a5),_0x255703[_0x3ca794('0xf')]?(_0x1bb2b1[_0x3ca794('0x1')]=_0x255703['refresh_token'],logger['info'](util['format'](_0x3ca794('0x1f'),_0x1bb2b1[_0x3ca794('0xc')],_0x1bb2b1['id']))):logger[_0x3ca794('0x16')](util[_0x3ca794('0x12')](_0x3ca794('0x19'),_0x1bb2b1[_0x3ca794('0xc')],_0x1bb2b1['id']),util[_0x3ca794('0xb')](_0x255703,{'showHidden':![],'depth':null})),null;})[_0x2791b1('0xd')](function(_0x59093c){const _0x5f09c4=_0x2791b1;return logger[_0x5f09c4('0x16')](util[_0x5f09c4('0x12')]('ZohoAccount,\x20Unable\x20to\x20generate\x20the\x20refresh\x20token\x20for\x20account\x20\x22%s\x22\x20#%d',_0x1bb2b1[_0x5f09c4('0xc')],_0x1bb2b1['id']),util['inspect'](_0x255703,{'showHidden':![],'depth':null})),_0x59093c;});}else return null;},'beforeUpdate':function(_0x36fee0){const _0x12959e=_0x27b209;if(_0x36fee0[_0x12959e('0x10')]('zone')||_0x36fee0[_0x12959e('0x10')](_0x12959e('0x2'))||_0x36fee0[_0x12959e('0x10')](_0x12959e('0x17'))||_0x36fee0[_0x12959e('0x10')](_0x12959e('0x20'))||_0x36fee0['changed'](_0x12959e('0x1e'))||_0x36fee0[_0x12959e('0x10')]('host')){let _0x446819,_0x5b5e9e;_0x446819=_0x36fee0[_0x12959e('0x2')];const _0x5871e9=_0x446819['slice'](-0x1);(_0x5871e9==='/'||_0x5871e9==='\x5c'||_0x5871e9===':')&&(_0x446819=_0x446819[_0x12959e('0xe')](0x0,_0x446819[_0x12959e('0x11')](_0x5871e9)));switch(_0x36fee0[_0x12959e('0x1c')]){case'US':_0x5b5e9e=_0x12959e('0x21');break;case'AU':_0x5b5e9e=_0x12959e('0x1d');break;case'IN':_0x5b5e9e=_0x12959e('0x8');break;case'CN':_0x5b5e9e=_0x12959e('0x3');break;default:_0x5b5e9e='https://accounts.zoho.eu';break;}const _0x38e2fb={'method':_0x12959e('0xa'),'uri':_0x5b5e9e+'/oauth/v2/token','form':{'grant_type':'authorization_code','client_id':_0x36fee0['clientId'],'client_secret':_0x36fee0[_0x12959e('0x20')],'redirect_uri':_0x36fee0[_0x12959e('0x2')],'code':_0x36fee0['code']},'headers':{'Content-Type':'application/x-www-form-urlencoded'}};let _0x59deb7=null;return rp(_0x38e2fb)[_0x12959e('0x1a')](function(_0x56dcb1){const _0x310e00=_0x12959e;return _0x59deb7=JSON[_0x310e00('0x0')](_0x56dcb1),_0x59deb7[_0x310e00('0xf')]?(_0x36fee0[_0x310e00('0x1')]=_0x59deb7[_0x310e00('0xf')],logger['info'](util['format']('ZohoAccount,\x20Refresh\x20token\x20successfully\x20generated\x20for\x20account\x20\x22%s\x22\x20#%d',_0x36fee0[_0x310e00('0xc')],_0x36fee0['id']))):logger[_0x310e00('0x16')](util[_0x310e00('0x12')](_0x310e00('0x19'),_0x36fee0['name'],_0x36fee0['id']),util[_0x310e00('0xb')](_0x59deb7,{'showHidden':![],'depth':null})),null;})['catch'](function(_0x182dfa){const _0x52b92c=_0x12959e;return logger[_0x52b92c('0x16')](util['format']('ZohoAccount,\x20Unable\x20to\x20generate\x20the\x20refresh\x20token\x20for\x20account\x20\x22%s\x22\x20#%d',_0x36fee0[_0x52b92c('0xc')],_0x36fee0['id']),util[_0x52b92c('0xb')](_0x59deb7,{'showHidden':![],'depth':null})),_0x182dfa;});}else return null;}}});return _0x14a18e;}; \ No newline at end of file diff --git a/server/api/intZohoAccount/intZohoAccount.rpc.js b/server/api/intZohoAccount/intZohoAccount.rpc.js index 316db61..45d1548 100644 --- a/server/api/intZohoAccount/intZohoAccount.rpc.js +++ b/server/api/intZohoAccount/intZohoAccount.rpc.js @@ -1 +1 @@ -const a348_0x2240=['attributes','map','model','rpc','catch','info','stringify','raw','where','debug','message','ShowZohoAccount','error','include','../../mysqldb','GetZohoAccount','then','findOne','options','findAll','limit'];(function(_0xda7c91,_0x224098){const _0x2ca418=function(_0x5794b8){while(--_0x5794b8){_0xda7c91['push'](_0xda7c91['shift']());}};_0x2ca418(++_0x224098);}(a348_0x2240,0x123));const a348_0x2ca4=function(_0xda7c91,_0x224098){_0xda7c91=_0xda7c91-0x0;let _0x2ca418=a348_0x2240[_0xda7c91];return _0x2ca418;};const _0x3ccc1f=a348_0x2ca4;'use strict';const _=require('lodash'),db=require(_0x3ccc1f('0x11'))['db'],logger=require('../../config/logger')(_0x3ccc1f('0x6'));exports['GetZohoAccount']=function(_0x5794b8){const _0x373417=this;return new Promise(function(_0x57da24,_0x3bc45c){const _0x4c05fe=a348_0x2ca4;return db['ZohoAccount'][_0x4c05fe('0x1')]({'raw':_0x5794b8[_0x4c05fe('0x0')]?_0x5794b8[_0x4c05fe('0x0')][_0x4c05fe('0xa')]===undefined?!![]:![]:!![],'where':_0x5794b8[_0x4c05fe('0x0')]?_0x5794b8['options'][_0x4c05fe('0xb')]||null:null,'attributes':_0x5794b8[_0x4c05fe('0x0')]?_0x5794b8['options']['attributes']||null:null,'limit':_0x5794b8[_0x4c05fe('0x0')]?_0x5794b8[_0x4c05fe('0x0')][_0x4c05fe('0x2')]||null:null,'include':_0x5794b8[_0x4c05fe('0x0')]?_0x5794b8['options']['include']?_[_0x4c05fe('0x4')](_0x5794b8[_0x4c05fe('0x0')][_0x4c05fe('0x10')],function(_0x57e8e1){const _0x14b510=_0x4c05fe;return{'model':db[_0x57e8e1['model']],'as':_0x57e8e1['as'],'attributes':_0x57e8e1[_0x14b510('0x3')],'include':_0x57e8e1[_0x14b510('0x10')]?_['map'](_0x57e8e1[_0x14b510('0x10')],function(_0xd49c33){const _0x2323f3=_0x14b510;return{'model':db[_0xd49c33[_0x2323f3('0x5')]],'as':_0xd49c33['as'],'attributes':_0xd49c33[_0x2323f3('0x3')],'include':_0xd49c33[_0x2323f3('0x10')]?_[_0x2323f3('0x4')](_0xd49c33[_0x2323f3('0x10')],function(_0x55819){const _0x296f0e=_0x2323f3;return{'model':db[_0x55819[_0x296f0e('0x5')]],'as':_0x55819['as'],'attributes':_0x55819[_0x296f0e('0x3')]};}):[]};}):[]};}):[]:[]})[_0x4c05fe('0x13')](function(_0xb0475c){const _0x20c748=_0x4c05fe;logger[_0x20c748('0x8')](_0x20c748('0x12'),_0x5794b8),logger[_0x20c748('0xc')]('GetZohoAccount',_0x5794b8,JSON['stringify'](_0xb0475c)),_0x57da24(_0xb0475c);})[_0x4c05fe('0x7')](function(_0x43094b){const _0x257603=_0x4c05fe;logger[_0x257603('0xf')]('GetZohoAccount',_0x43094b['message'],_0x5794b8),_0x3bc45c(_0x373417[_0x257603('0xf')](0x1f4,_0x43094b[_0x257603('0xd')]));});});},exports['ShowZohoAccount']=function(_0x1e5946){const _0x51b4ad=this;return new Promise(function(_0x1c1797,_0x4fc65a){const _0x412615=a348_0x2ca4;return db['ZohoAccount'][_0x412615('0x14')]({'raw':_0x1e5946[_0x412615('0x0')]?_0x1e5946[_0x412615('0x0')][_0x412615('0xa')]===undefined?!![]:![]:!![],'where':_0x1e5946['options']?_0x1e5946[_0x412615('0x0')]['where']||null:null,'attributes':_0x1e5946['options']?_0x1e5946['options'][_0x412615('0x3')]||null:null,'include':_0x1e5946[_0x412615('0x0')]?_0x1e5946[_0x412615('0x0')][_0x412615('0x10')]?_[_0x412615('0x4')](_0x1e5946[_0x412615('0x0')]['include'],function(_0x13720b){const _0x5d6da7=_0x412615;return{'model':db[_0x13720b[_0x5d6da7('0x5')]],'as':_0x13720b['as'],'attributes':_0x13720b[_0x5d6da7('0x3')],'include':_0x13720b[_0x5d6da7('0x10')]?_['map'](_0x13720b[_0x5d6da7('0x10')],function(_0x19a4f2){const _0x2e96d9=_0x5d6da7;return{'model':db[_0x19a4f2[_0x2e96d9('0x5')]],'as':_0x19a4f2['as'],'attributes':_0x19a4f2['attributes'],'include':_0x19a4f2[_0x2e96d9('0x10')]?_[_0x2e96d9('0x4')](_0x19a4f2['include'],function(_0x4daea2){const _0x51f676=_0x2e96d9;return{'model':db[_0x4daea2[_0x51f676('0x5')]],'as':_0x4daea2['as'],'attributes':_0x4daea2[_0x51f676('0x3')]};}):[]};}):[]};}):[]:[]})[_0x412615('0x13')](function(_0x3b1e94){const _0x342f1b=_0x412615;logger[_0x342f1b('0x8')](_0x342f1b('0xe'),_0x1e5946),logger[_0x342f1b('0xc')](_0x342f1b('0xe'),_0x1e5946,JSON[_0x342f1b('0x9')](_0x3b1e94)),_0x1c1797(_0x3b1e94);})['catch'](function(_0x298d6e){const _0x5465dd=_0x412615;logger[_0x5465dd('0xf')](_0x5465dd('0xe'),_0x298d6e['message'],_0x1e5946),_0x4fc65a(_0x51b4ad[_0x5465dd('0xf')](0x1f4,_0x298d6e['message']));});});}; \ No newline at end of file +const a348_0x3e50=['message','map','stringify','raw','ShowZohoAccount','options','GetZohoAccount','include','ZohoAccount','lodash','attributes','catch','model','rpc','debug','where','error','then','info'];(function(_0x1a3bcb,_0x3e5094){const _0xc75eb2=function(_0x3bd9dc){while(--_0x3bd9dc){_0x1a3bcb['push'](_0x1a3bcb['shift']());}};_0xc75eb2(++_0x3e5094);}(a348_0x3e50,0xf2));const a348_0xc75e=function(_0x1a3bcb,_0x3e5094){_0x1a3bcb=_0x1a3bcb-0x0;let _0xc75eb2=a348_0x3e50[_0x1a3bcb];return _0xc75eb2;};const _0x3c0735=a348_0xc75e;'use strict';const _=require(_0x3c0735('0xe')),db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x3c0735('0x12'));exports[_0x3c0735('0xb')]=function(_0x3bd9dc){const _0x3e6b38=this;return new Promise(function(_0x4c2902,_0x464e8b){const _0x498e85=a348_0xc75e;return db[_0x498e85('0xd')]['findAll']({'raw':_0x3bd9dc[_0x498e85('0xa')]?_0x3bd9dc[_0x498e85('0xa')][_0x498e85('0x8')]===undefined?!![]:![]:!![],'where':_0x3bd9dc[_0x498e85('0xa')]?_0x3bd9dc[_0x498e85('0xa')][_0x498e85('0x1')]||null:null,'attributes':_0x3bd9dc[_0x498e85('0xa')]?_0x3bd9dc[_0x498e85('0xa')][_0x498e85('0xf')]||null:null,'limit':_0x3bd9dc[_0x498e85('0xa')]?_0x3bd9dc[_0x498e85('0xa')]['limit']||null:null,'include':_0x3bd9dc['options']?_0x3bd9dc['options']['include']?_[_0x498e85('0x6')](_0x3bd9dc[_0x498e85('0xa')]['include'],function(_0x13d3f5){const _0x3bc503=_0x498e85;return{'model':db[_0x13d3f5[_0x3bc503('0x11')]],'as':_0x13d3f5['as'],'attributes':_0x13d3f5[_0x3bc503('0xf')],'include':_0x13d3f5[_0x3bc503('0xc')]?_[_0x3bc503('0x6')](_0x13d3f5[_0x3bc503('0xc')],function(_0x1862cf){const _0x3cb12b=_0x3bc503;return{'model':db[_0x1862cf[_0x3cb12b('0x11')]],'as':_0x1862cf['as'],'attributes':_0x1862cf[_0x3cb12b('0xf')],'include':_0x1862cf[_0x3cb12b('0xc')]?_[_0x3cb12b('0x6')](_0x1862cf['include'],function(_0x3fe9a6){const _0x1c2b32=_0x3cb12b;return{'model':db[_0x3fe9a6[_0x1c2b32('0x11')]],'as':_0x3fe9a6['as'],'attributes':_0x3fe9a6[_0x1c2b32('0xf')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x38a397){const _0x56ba7a=_0x498e85;logger[_0x56ba7a('0x4')]('GetZohoAccount',_0x3bd9dc),logger[_0x56ba7a('0x0')](_0x56ba7a('0xb'),_0x3bd9dc,JSON['stringify'](_0x38a397)),_0x4c2902(_0x38a397);})[_0x498e85('0x10')](function(_0x1f36cb){const _0x29c95e=_0x498e85;logger[_0x29c95e('0x2')](_0x29c95e('0xb'),_0x1f36cb['message'],_0x3bd9dc),_0x464e8b(_0x3e6b38[_0x29c95e('0x2')](0x1f4,_0x1f36cb['message']));});});},exports[_0x3c0735('0x9')]=function(_0x120dca){const _0x5975da=this;return new Promise(function(_0xdd2f8b,_0x33fbb3){const _0x492523=a348_0xc75e;return db[_0x492523('0xd')]['findOne']({'raw':_0x120dca[_0x492523('0xa')]?_0x120dca['options'][_0x492523('0x8')]===undefined?!![]:![]:!![],'where':_0x120dca['options']?_0x120dca[_0x492523('0xa')][_0x492523('0x1')]||null:null,'attributes':_0x120dca['options']?_0x120dca[_0x492523('0xa')]['attributes']||null:null,'include':_0x120dca[_0x492523('0xa')]?_0x120dca[_0x492523('0xa')]['include']?_[_0x492523('0x6')](_0x120dca[_0x492523('0xa')]['include'],function(_0x40e420){const _0x318042=_0x492523;return{'model':db[_0x40e420[_0x318042('0x11')]],'as':_0x40e420['as'],'attributes':_0x40e420[_0x318042('0xf')],'include':_0x40e420['include']?_[_0x318042('0x6')](_0x40e420['include'],function(_0x20d0e2){const _0x3574ab=_0x318042;return{'model':db[_0x20d0e2[_0x3574ab('0x11')]],'as':_0x20d0e2['as'],'attributes':_0x20d0e2[_0x3574ab('0xf')],'include':_0x20d0e2[_0x3574ab('0xc')]?_[_0x3574ab('0x6')](_0x20d0e2[_0x3574ab('0xc')],function(_0x4034a9){const _0x2b10dd=_0x3574ab;return{'model':db[_0x4034a9[_0x2b10dd('0x11')]],'as':_0x4034a9['as'],'attributes':_0x4034a9[_0x2b10dd('0xf')]};}):[]};}):[]};}):[]:[]})[_0x492523('0x3')](function(_0x1b9fcf){const _0x129295=_0x492523;logger['info'](_0x129295('0x9'),_0x120dca),logger['debug'](_0x129295('0x9'),_0x120dca,JSON[_0x129295('0x7')](_0x1b9fcf)),_0xdd2f8b(_0x1b9fcf);})[_0x492523('0x10')](function(_0x56813b){const _0x412cd6=_0x492523;logger[_0x412cd6('0x2')](_0x412cd6('0x9'),_0x56813b[_0x412cd6('0x5')],_0x120dca),_0x33fbb3(_0x5975da[_0x412cd6('0x2')](0x1f4,_0x56813b[_0x412cd6('0x5')]));});});}; \ No newline at end of file diff --git a/server/api/intZohoConfiguration/index.js b/server/api/intZohoConfiguration/index.js index 9cd9ef6..0542700 100644 --- a/server/api/intZohoConfiguration/index.js +++ b/server/api/intZohoConfiguration/index.js @@ -1 +1 @@ -const a349_0x367e=['/:id/fields','/:id/subjects','getFields','put','post','./intZohoConfiguration.controller','isAuthenticated','delete','get','index','/:id','destroy','exports'];(function(_0x4dad34,_0x367e76){const _0x366829=function(_0x5e85e6){while(--_0x5e85e6){_0x4dad34['push'](_0x4dad34['shift']());}};_0x366829(++_0x367e76);}(a349_0x367e,0x14c));const a349_0x3668=function(_0x4dad34,_0x367e76){_0x4dad34=_0x4dad34-0x0;let _0x366829=a349_0x367e[_0x4dad34];return _0x366829;};const _0x2023b6=a349_0x3668;'use strict';const express=require('express'),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x2023b6('0xb'));router[_0x2023b6('0x1')]('/',auth[_0x2023b6('0xc')](),controller[_0x2023b6('0x2')]),router[_0x2023b6('0x1')](_0x2023b6('0x3'),auth[_0x2023b6('0xc')](),controller['show']),router['get'](_0x2023b6('0x6'),auth['isAuthenticated'](),controller[_0x2023b6('0x8')]),router['get'](_0x2023b6('0x7'),auth[_0x2023b6('0xc')](),controller['getSubjects']),router[_0x2023b6('0x1')]('/:id/descriptions',auth['isAuthenticated'](),controller['getDescriptions']),router[_0x2023b6('0xa')]('/',auth['isAuthenticated'](),controller['create']),router[_0x2023b6('0x9')](_0x2023b6('0x3'),auth[_0x2023b6('0xc')](),controller['update']),router[_0x2023b6('0x0')](_0x2023b6('0x3'),auth[_0x2023b6('0xc')](),controller[_0x2023b6('0x4')]),module[_0x2023b6('0x5')]=router; \ No newline at end of file +const a349_0x4ca8=['./intZohoConfiguration.controller','getSubjects','show','get','post','create','getFields','/:id/fields','exports','/:id/descriptions','destroy','/:id','update','index','put','isAuthenticated','Router'];(function(_0x5330f1,_0x4ca8bc){const _0x47f558=function(_0x48339c){while(--_0x48339c){_0x5330f1['push'](_0x5330f1['shift']());}};_0x47f558(++_0x4ca8bc);}(a349_0x4ca8,0xa1));const a349_0x47f5=function(_0x5330f1,_0x4ca8bc){_0x5330f1=_0x5330f1-0x0;let _0x47f558=a349_0x4ca8[_0x5330f1];return _0x47f558;};const _0x295515=a349_0x47f5;'use strict';const express=require('express'),router=express[_0x295515('0x8')](),auth=require('../../components/auth/service'),controller=require(_0x295515('0x9'));router['get']('/',auth[_0x295515('0x7')](),controller[_0x295515('0x5')]),router[_0x295515('0xc')](_0x295515('0x3'),auth[_0x295515('0x7')](),controller[_0x295515('0xb')]),router[_0x295515('0xc')](_0x295515('0x10'),auth['isAuthenticated'](),controller[_0x295515('0xf')]),router['get']('/:id/subjects',auth['isAuthenticated'](),controller[_0x295515('0xa')]),router[_0x295515('0xc')](_0x295515('0x1'),auth['isAuthenticated'](),controller['getDescriptions']),router[_0x295515('0xd')]('/',auth[_0x295515('0x7')](),controller[_0x295515('0xe')]),router[_0x295515('0x6')](_0x295515('0x3'),auth[_0x295515('0x7')](),controller[_0x295515('0x4')]),router['delete'](_0x295515('0x3'),auth['isAuthenticated'](),controller[_0x295515('0x2')]),module[_0x295515('0x0')]=router; \ No newline at end of file diff --git a/server/api/intZohoConfiguration/intZohoConfiguration.attributes.js b/server/api/intZohoConfiguration/intZohoConfiguration.attributes.js index 78bc58e..14bac95 100644 --- a/server/api/intZohoConfiguration/intZohoConfiguration.attributes.js +++ b/server/api/intZohoConfiguration/intZohoConfiguration.attributes.js @@ -1 +1 @@ -const a350_0x1d9f=['contact_lead','contact','sequelize','STRING','ENUM','lead'];(function(_0x272a88,_0x1d9f26){const _0x529fc8=function(_0x213fb9){while(--_0x213fb9){_0x272a88['push'](_0x272a88['shift']());}};_0x529fc8(++_0x1d9f26);}(a350_0x1d9f,0x7f));const a350_0x529f=function(_0x272a88,_0x1d9f26){_0x272a88=_0x272a88-0x0;let _0x529fc8=a350_0x1d9f[_0x272a88];return _0x529fc8;};const _0x4a67dc=a350_0x529f;'use strict';const Sequelize=require(_0x4a67dc('0x1'));module['exports']={'name':{'type':Sequelize[_0x4a67dc('0x2')]},'moduleCreate':{'type':Sequelize[_0x4a67dc('0x3')]('lead',_0x4a67dc('0x0'),'nothing'),'defaultValue':'lead'},'moduleSearch':{'type':Sequelize['ENUM'](_0x4a67dc('0x5'),_0x4a67dc('0x0'),_0x4a67dc('0x4')),'defaultValue':_0x4a67dc('0x5')},'description':{'type':Sequelize[_0x4a67dc('0x2')]}}; \ No newline at end of file +const a350_0x22cd=['STRING','contact','exports','lead','sequelize','contact_lead','ENUM'];(function(_0x46ef98,_0x22cd2e){const _0x488801=function(_0x3333c4){while(--_0x3333c4){_0x46ef98['push'](_0x46ef98['shift']());}};_0x488801(++_0x22cd2e);}(a350_0x22cd,0x157));const a350_0x4888=function(_0x46ef98,_0x22cd2e){_0x46ef98=_0x46ef98-0x0;let _0x488801=a350_0x22cd[_0x46ef98];return _0x488801;};const _0x502374=a350_0x4888;'use strict';const Sequelize=require(_0x502374('0x4'));module[_0x502374('0x2')]={'name':{'type':Sequelize['STRING']},'moduleCreate':{'type':Sequelize[_0x502374('0x6')]('lead',_0x502374('0x1'),'nothing'),'defaultValue':_0x502374('0x3')},'moduleSearch':{'type':Sequelize[_0x502374('0x6')](_0x502374('0x5'),_0x502374('0x1'),'lead'),'defaultValue':_0x502374('0x5')},'description':{'type':Sequelize[_0x502374('0x0')]}}; \ No newline at end of file diff --git a/server/api/intZohoConfiguration/intZohoConfiguration.controller.js b/server/api/intZohoConfiguration/intZohoConfiguration.controller.js index e39e811..e20be17 100644 --- a/server/api/intZohoConfiguration/intZohoConfiguration.controller.js +++ b/server/api/intZohoConfiguration/intZohoConfiguration.controller.js @@ -1 +1 @@ -const a351_0x1d7d=['filters','options','nolimit','length','sort','error','count','model','where','api','ZohoConfiguration','map','getSubjects','../../mysqldb','body','like','query','pick','lodash','filter','params','getDescriptions','index','limit','destroy','includeAll','VIRTUAL','rawAttributes','type','ZohoField','findOne','../../components/parsers/qs','offset','order','include','send','findAll','status','name','stack','update','key','keys','json','undefined','getFields','merge','then','intersection','attributes','catch','Content-Range','end','set','fields','sendStatus'];(function(_0x5fffd9,_0x1d7d3b){const _0x44ff18=function(_0x58c417){while(--_0x58c417){_0x5fffd9['push'](_0x5fffd9['shift']());}};_0x44ff18(++_0x1d7d3b);}(a351_0x1d7d,0x1d0));const a351_0x44ff=function(_0x5fffd9,_0x1d7d3b){_0x5fffd9=_0x5fffd9-0x0;let _0x44ff18=a351_0x1d7d[_0x5fffd9];return _0x44ff18;};const _0x19d223=a351_0x44ff;'use strict';const _=require(_0x19d223('0x2')),qs=require(_0x19d223('0xf')),logger=require('../../config/logger')(_0x19d223('0x31')),db=require(_0x19d223('0x35'))['db'],{Op}=require('sequelize');function respondWithResult(_0x58c417,_0x4ae240){return _0x4ae240=_0x4ae240||0xc8,function(_0x4c26cb){const _0x4d2690=a351_0x44ff;if(_0x4c26cb)return _0x58c417[_0x4d2690('0x15')](_0x4ae240)[_0x4d2690('0x1b')](_0x4c26cb);};}function respondWithFilteredResult(_0x44bdc9,_0xec7c99){return function(_0x20e169){const _0x6e136e=a351_0x44ff;if(_0x20e169){const _0x4391e2=_0x20e169[_0x6e136e('0x2e')],_0x23b251=_0xec7c99[_0x6e136e('0x10')];let _0x5428bc=_0xec7c99['offset']+_0xec7c99[_0x6e136e('0x7')],_0x3c9bbd;return _0x5428bc>=_0x4391e2?(_0x5428bc=_0x4391e2,_0x3c9bbd=0xc8):_0x3c9bbd=0xce,_0x44bdc9[_0x6e136e('0x15')](_0x3c9bbd),_0x44bdc9[_0x6e136e('0x25')](_0x6e136e('0x23'),_0x23b251+'-'+_0x5428bc+'/'+_0x4391e2)['json'](_0x20e169);}return null;};}function saveUpdates(_0x285e68){return function(_0x3e12a3){const _0x479b47=a351_0x44ff;if(_0x3e12a3)return _0x3e12a3['update'](_0x285e68)[_0x479b47('0x1f')](function(_0x51225b){return _0x51225b;});return null;};}function removeEntity(_0x5b2763){return function(_0x14c13e){const _0x3e73a9=a351_0x44ff;if(_0x14c13e)return _0x14c13e[_0x3e73a9('0x8')]()['then'](function(){const _0x2653a5=_0x3e73a9;_0x5b2763['status'](0xcc)[_0x2653a5('0x24')]();});};}function handleEntityNotFound(_0x26d273){return function(_0x55ecd2){const _0x3618bf=a351_0x44ff;return!_0x55ecd2&&_0x26d273[_0x3618bf('0x27')](0x194),_0x55ecd2;};}function handleError(_0x2c63e6,_0x17c779){return _0x17c779=_0x17c779||0x1f4,function(_0x40e1bf){const _0x177353=a351_0x44ff;logger[_0x177353('0x2d')](_0x40e1bf[_0x177353('0x17')]),_0x40e1bf[_0x177353('0x16')]&&delete _0x40e1bf[_0x177353('0x16')],_0x2c63e6[_0x177353('0x15')](_0x17c779)[_0x177353('0x13')](_0x40e1bf);};}exports[_0x19d223('0x6')]=function(_0xfbe5e0,_0x447956){const _0x3c30dd=_0x19d223;let _0x27e496={};const _0x41d82d={},_0x22cbc9={'count':0x0,'rows':[]},_0x245ef5=_[_0x3c30dd('0x33')](db[_0x3c30dd('0x32')][_0x3c30dd('0xb')],function(_0x5982b8){const _0x595074=_0x3c30dd;return{'name':_0x5982b8['fieldName'],'type':_0x5982b8[_0x595074('0xc')][_0x595074('0x19')]};});_0x41d82d['model']=_['map'](_0x245ef5,_0x3c30dd('0x16')),_0x41d82d[_0x3c30dd('0x0')]=_[_0x3c30dd('0x1a')](_0xfbe5e0['query']),_0x41d82d[_0x3c30dd('0x28')]=_[_0x3c30dd('0x20')](_0x41d82d['model'],_0x41d82d['query']),_0x27e496['attributes']=_['intersection'](_0x41d82d[_0x3c30dd('0x2f')],qs[_0x3c30dd('0x26')](_0xfbe5e0[_0x3c30dd('0x0')][_0x3c30dd('0x26')])),_0x27e496[_0x3c30dd('0x21')]=_0x27e496[_0x3c30dd('0x21')][_0x3c30dd('0x2b')]?_0x27e496[_0x3c30dd('0x21')]:_0x41d82d['model'];typeof _0xfbe5e0['query']['nolimit']===_0x3c30dd('0x1c')&&(_0x27e496[_0x3c30dd('0x7')]=qs[_0x3c30dd('0x7')](_0xfbe5e0[_0x3c30dd('0x0')][_0x3c30dd('0x7')]),_0x27e496[_0x3c30dd('0x10')]=qs[_0x3c30dd('0x10')](_0xfbe5e0[_0x3c30dd('0x0')][_0x3c30dd('0x10')]));_0x27e496[_0x3c30dd('0x11')]=qs[_0x3c30dd('0x2c')](_0xfbe5e0['query'][_0x3c30dd('0x2c')]),_0x27e496[_0x3c30dd('0x30')]=qs[_0x3c30dd('0x28')](_['pick'](_0xfbe5e0[_0x3c30dd('0x0')],_0x41d82d[_0x3c30dd('0x28')]),_0x245ef5);_0xfbe5e0[_0x3c30dd('0x0')][_0x3c30dd('0x3')]&&(_0x27e496[_0x3c30dd('0x30')]=_[_0x3c30dd('0x1e')](_0x27e496['where'],{[Op['or']]:_[_0x3c30dd('0x33')](_0x245ef5,function(_0x5bca3c){const _0x3e8fa9=_0x3c30dd;if(_0x5bca3c[_0x3e8fa9('0xc')]!==_0x3e8fa9('0xa')){const _0x189ff8={};return _0x189ff8[_0x5bca3c[_0x3e8fa9('0x16')]]={[Op[_0x3e8fa9('0x37')]]:'%'+_0xfbe5e0['query'][_0x3e8fa9('0x3')]+'%'},_0x189ff8;}})}));_0x27e496=_[_0x3c30dd('0x1e')]({},_0x27e496,_0xfbe5e0[_0x3c30dd('0x29')]);const _0x59e35e={'where':_0x27e496[_0x3c30dd('0x30')]};return db[_0x3c30dd('0x32')][_0x3c30dd('0x2e')](_0x59e35e)['then'](function(_0x5709a3){const _0x9c3805=_0x3c30dd;return _0x22cbc9[_0x9c3805('0x2e')]=_0x5709a3,_0xfbe5e0[_0x9c3805('0x0')]['includeAll']&&(_0x27e496['include']=[{'all':!![]}]),db[_0x9c3805('0x32')][_0x9c3805('0x14')](_0x27e496);})[_0x3c30dd('0x1f')](function(_0x1d3d30){return _0x22cbc9['rows']=_0x1d3d30,_0x22cbc9;})[_0x3c30dd('0x1f')](respondWithFilteredResult(_0x447956,_0x27e496))[_0x3c30dd('0x22')](handleError(_0x447956,null));},exports['show']=function(_0x583931,_0x595d55){const _0x2464f9=_0x19d223;let _0x4b7e87={'raw':![],'where':{'id':_0x583931['params']['id']}};const _0x58598c={};return _0x58598c[_0x2464f9('0x2f')]=_[_0x2464f9('0x1a')](db[_0x2464f9('0x32')][_0x2464f9('0xb')]),_0x58598c['query']=_[_0x2464f9('0x1a')](_0x583931['query']),_0x58598c[_0x2464f9('0x28')]=_[_0x2464f9('0x20')](_0x58598c[_0x2464f9('0x2f')],_0x58598c[_0x2464f9('0x0')]),_0x4b7e87['attributes']=_['intersection'](_0x58598c['model'],qs[_0x2464f9('0x26')](_0x583931[_0x2464f9('0x0')]['fields'])),_0x4b7e87[_0x2464f9('0x21')]=_0x4b7e87[_0x2464f9('0x21')][_0x2464f9('0x2b')]?_0x4b7e87['attributes']:_0x58598c[_0x2464f9('0x2f')],_0x583931[_0x2464f9('0x0')][_0x2464f9('0x9')]&&(_0x4b7e87[_0x2464f9('0x12')]=[{'all':!![]}]),_0x4b7e87=_['merge']({},_0x4b7e87,_0x583931[_0x2464f9('0x29')]),db[_0x2464f9('0x32')][_0x2464f9('0xe')](_0x4b7e87)['then'](handleEntityNotFound(_0x595d55,null))[_0x2464f9('0x1f')](respondWithResult(_0x595d55,null))[_0x2464f9('0x22')](handleError(_0x595d55,null));},exports['create']=function(_0x25be94,_0x41a49c){const _0x2dbf36=_0x19d223;return db[_0x2dbf36('0x32')]['create'](_0x25be94[_0x2dbf36('0x36')],{})[_0x2dbf36('0x1f')](respondWithResult(_0x41a49c,0xc9))['catch'](handleError(_0x41a49c,null));},exports[_0x19d223('0x18')]=function(_0x29dd67,_0x22d422){const _0x465f1d=_0x19d223;return _0x29dd67[_0x465f1d('0x36')]['id']&&delete _0x29dd67[_0x465f1d('0x36')]['id'],db['ZohoConfiguration'][_0x465f1d('0xe')]({'where':{'id':_0x29dd67[_0x465f1d('0x4')]['id']}})[_0x465f1d('0x1f')](handleEntityNotFound(_0x22d422,null))['then'](saveUpdates(_0x29dd67[_0x465f1d('0x36')],null))[_0x465f1d('0x1f')](respondWithResult(_0x22d422,null))[_0x465f1d('0x22')](handleError(_0x22d422,null));},exports[_0x19d223('0x8')]=function(_0xfe321,_0x31c0ae){const _0x5e0105=_0x19d223;return db[_0x5e0105('0x32')][_0x5e0105('0xe')]({'where':{'id':_0xfe321[_0x5e0105('0x4')]['id']}})[_0x5e0105('0x1f')](handleEntityNotFound(_0x31c0ae,null))[_0x5e0105('0x1f')](removeEntity(_0x31c0ae,null))[_0x5e0105('0x22')](handleError(_0x31c0ae,null));},exports['getFields']=function(_0x4ea052,_0x122e2f){const _0x55bbb1=_0x19d223;let _0x425844={};const _0x36c987={};let _0x13055c,_0x22582b;return db['ZohoConfiguration'][_0x55bbb1('0xe')]({'where':{'id':_0x4ea052['params']['id']}})[_0x55bbb1('0x1f')](handleEntityNotFound(_0x122e2f,null))['then'](function(_0x432744){const _0x10efe1=_0x55bbb1;if(_0x432744)return _0x13055c=_0x432744,_0x36c987['model']=_[_0x10efe1('0x1a')](db[_0x10efe1('0xd')]['rawAttributes']),_0x36c987[_0x10efe1('0x0')]=_[_0x10efe1('0x1a')](_0x4ea052['query']),_0x36c987[_0x10efe1('0x28')]=_['intersection'](_0x36c987[_0x10efe1('0x2f')],_0x36c987[_0x10efe1('0x0')]),_0x425844[_0x10efe1('0x21')]=_[_0x10efe1('0x20')](_0x36c987[_0x10efe1('0x2f')],qs['fields'](_0x4ea052[_0x10efe1('0x0')][_0x10efe1('0x26')])),_0x425844[_0x10efe1('0x21')]=_0x425844[_0x10efe1('0x21')]['length']?_0x425844[_0x10efe1('0x21')]:_0x36c987[_0x10efe1('0x2f')],_0x425844[_0x10efe1('0x11')]=qs[_0x10efe1('0x2c')](_0x4ea052[_0x10efe1('0x0')][_0x10efe1('0x2c')]),_0x425844['where']=qs['filters'](_[_0x10efe1('0x1')](_0x4ea052[_0x10efe1('0x0')],_0x36c987[_0x10efe1('0x28')])),_0x4ea052[_0x10efe1('0x0')]['filter']&&(_0x425844['where']=_[_0x10efe1('0x1e')](_0x425844[_0x10efe1('0x30')],{[Op['or']]:_[_0x10efe1('0x33')](_0x425844[_0x10efe1('0x21')],function(_0x29ee1d){const _0x46014c=_0x10efe1,_0x1240e0={};return _0x1240e0[_0x29ee1d]={[Op[_0x46014c('0x37')]]:'%'+_0x4ea052['query'][_0x46014c('0x3')]+'%'},_0x1240e0;})})),_0x425844=_[_0x10efe1('0x1e')]({},_0x425844,_0x4ea052[_0x10efe1('0x29')]),_0x13055c[_0x10efe1('0x1d')](_0x425844);})[_0x55bbb1('0x1f')](function(_0x441acf){const _0x45c9a8=_0x55bbb1;if(_0x441acf)return _0x22582b=_0x441acf[_0x45c9a8('0x2b')],typeof _0x4ea052[_0x45c9a8('0x0')][_0x45c9a8('0x2a')]==='undefined'&&(_0x425844[_0x45c9a8('0x7')]=qs[_0x45c9a8('0x7')](_0x4ea052['query'][_0x45c9a8('0x7')]),_0x425844[_0x45c9a8('0x10')]=qs[_0x45c9a8('0x10')](_0x4ea052[_0x45c9a8('0x0')][_0x45c9a8('0x10')])),_0x13055c['getFields'](_0x425844);})[_0x55bbb1('0x1f')](function(_0x2c1421){if(_0x2c1421)return _0x2c1421?{'count':_0x22582b,'rows':_0x2c1421}:null;})['then'](respondWithResult(_0x122e2f,null))[_0x55bbb1('0x22')](handleError(_0x122e2f,null));},exports[_0x19d223('0x34')]=function(_0x53b9a3,_0x2fd5e2){const _0x25a1ff=_0x19d223;let _0x212bd9={};const _0x5bb955={};let _0x31eebf,_0x49f396;return db[_0x25a1ff('0x32')][_0x25a1ff('0xe')]({'where':{'id':_0x53b9a3[_0x25a1ff('0x4')]['id']}})[_0x25a1ff('0x1f')](handleEntityNotFound(_0x2fd5e2,null))[_0x25a1ff('0x1f')](function(_0x58dd8e){const _0x395a3d=_0x25a1ff;if(_0x58dd8e)return _0x31eebf=_0x58dd8e,_0x5bb955[_0x395a3d('0x2f')]=_[_0x395a3d('0x1a')](db[_0x395a3d('0xd')][_0x395a3d('0xb')]),_0x5bb955['query']=_[_0x395a3d('0x1a')](_0x53b9a3[_0x395a3d('0x0')]),_0x5bb955[_0x395a3d('0x28')]=_[_0x395a3d('0x20')](_0x5bb955[_0x395a3d('0x2f')],_0x5bb955['query']),_0x212bd9[_0x395a3d('0x21')]=_['intersection'](_0x5bb955[_0x395a3d('0x2f')],qs['fields'](_0x53b9a3['query'][_0x395a3d('0x26')])),_0x212bd9['attributes']=_0x212bd9[_0x395a3d('0x21')][_0x395a3d('0x2b')]?_0x212bd9[_0x395a3d('0x21')]:_0x5bb955[_0x395a3d('0x2f')],_0x212bd9[_0x395a3d('0x11')]=qs[_0x395a3d('0x2c')](_0x53b9a3['query'][_0x395a3d('0x2c')]),_0x212bd9[_0x395a3d('0x30')]=qs[_0x395a3d('0x28')](_[_0x395a3d('0x1')](_0x53b9a3['query'],_0x5bb955['filters'])),_0x53b9a3['query'][_0x395a3d('0x3')]&&(_0x212bd9[_0x395a3d('0x30')]=_[_0x395a3d('0x1e')](_0x212bd9[_0x395a3d('0x30')],{[Op['or']]:_[_0x395a3d('0x33')](_0x212bd9[_0x395a3d('0x21')],function(_0x3f8883){const _0x184e09=_0x395a3d,_0x3da2a5={};return _0x3da2a5[_0x3f8883]={[Op[_0x184e09('0x37')]]:'%'+_0x53b9a3[_0x184e09('0x0')][_0x184e09('0x3')]+'%'},_0x3da2a5;})})),_0x212bd9=_[_0x395a3d('0x1e')]({},_0x212bd9,_0x53b9a3['options']),_0x31eebf[_0x395a3d('0x34')](_0x212bd9);})[_0x25a1ff('0x1f')](function(_0x23f6a6){const _0x456f2a=_0x25a1ff;if(_0x23f6a6)return _0x49f396=_0x23f6a6['length'],typeof _0x53b9a3[_0x456f2a('0x0')][_0x456f2a('0x2a')]===_0x456f2a('0x1c')&&(_0x212bd9[_0x456f2a('0x7')]=qs[_0x456f2a('0x7')](_0x53b9a3['query'][_0x456f2a('0x7')]),_0x212bd9[_0x456f2a('0x10')]=qs[_0x456f2a('0x10')](_0x53b9a3[_0x456f2a('0x0')]['offset'])),_0x31eebf[_0x456f2a('0x34')](_0x212bd9);})['then'](function(_0x1fdd2d){if(_0x1fdd2d)return _0x1fdd2d?{'count':_0x49f396,'rows':_0x1fdd2d}:null;})[_0x25a1ff('0x1f')](respondWithResult(_0x2fd5e2,null))['catch'](handleError(_0x2fd5e2,null));},exports[_0x19d223('0x5')]=function(_0x46d515,_0x3f36cd){const _0x3a4359=_0x19d223;let _0x897d76={};const _0x3be32b={};let _0x331fcd,_0x227c32;return db[_0x3a4359('0x32')][_0x3a4359('0xe')]({'where':{'id':_0x46d515[_0x3a4359('0x4')]['id']}})[_0x3a4359('0x1f')](handleEntityNotFound(_0x3f36cd,null))['then'](function(_0x15658f){const _0x359dcd=_0x3a4359;if(_0x15658f)return _0x331fcd=_0x15658f,_0x3be32b[_0x359dcd('0x2f')]=_[_0x359dcd('0x1a')](db[_0x359dcd('0xd')][_0x359dcd('0xb')]),_0x3be32b[_0x359dcd('0x0')]=_[_0x359dcd('0x1a')](_0x46d515['query']),_0x3be32b[_0x359dcd('0x28')]=_[_0x359dcd('0x20')](_0x3be32b[_0x359dcd('0x2f')],_0x3be32b['query']),_0x897d76[_0x359dcd('0x21')]=_['intersection'](_0x3be32b[_0x359dcd('0x2f')],qs[_0x359dcd('0x26')](_0x46d515[_0x359dcd('0x0')][_0x359dcd('0x26')])),_0x897d76[_0x359dcd('0x21')]=_0x897d76['attributes']['length']?_0x897d76[_0x359dcd('0x21')]:_0x3be32b['model'],_0x897d76[_0x359dcd('0x11')]=qs[_0x359dcd('0x2c')](_0x46d515[_0x359dcd('0x0')][_0x359dcd('0x2c')]),_0x897d76[_0x359dcd('0x30')]=qs[_0x359dcd('0x28')](_[_0x359dcd('0x1')](_0x46d515['query'],_0x3be32b[_0x359dcd('0x28')])),_0x46d515[_0x359dcd('0x0')][_0x359dcd('0x3')]&&(_0x897d76[_0x359dcd('0x30')]=_[_0x359dcd('0x1e')](_0x897d76[_0x359dcd('0x30')],{[Op['or']]:_[_0x359dcd('0x33')](_0x897d76[_0x359dcd('0x21')],function(_0x1a37bb){const _0x353280=_0x359dcd,_0x25bc66={};return _0x25bc66[_0x1a37bb]={[Op[_0x353280('0x37')]]:'%'+_0x46d515[_0x353280('0x0')]['filter']+'%'},_0x25bc66;})})),_0x897d76=_[_0x359dcd('0x1e')]({},_0x897d76,_0x46d515[_0x359dcd('0x29')]),_0x331fcd[_0x359dcd('0x5')](_0x897d76);})[_0x3a4359('0x1f')](function(_0x5e94f0){const _0x4fa2a9=_0x3a4359;if(_0x5e94f0)return _0x227c32=_0x5e94f0[_0x4fa2a9('0x2b')],typeof _0x46d515[_0x4fa2a9('0x0')][_0x4fa2a9('0x2a')]==='undefined'&&(_0x897d76[_0x4fa2a9('0x7')]=qs[_0x4fa2a9('0x7')](_0x46d515['query'][_0x4fa2a9('0x7')]),_0x897d76[_0x4fa2a9('0x10')]=qs['offset'](_0x46d515[_0x4fa2a9('0x0')][_0x4fa2a9('0x10')])),_0x331fcd['getDescriptions'](_0x897d76);})[_0x3a4359('0x1f')](function(_0x543983){if(_0x543983)return _0x543983?{'count':_0x227c32,'rows':_0x543983}:null;})[_0x3a4359('0x1f')](respondWithResult(_0x3f36cd,null))[_0x3a4359('0x22')](handleError(_0x3f36cd,null));}; \ No newline at end of file +const a351_0x3468=['../../components/parsers/qs','includeAll','getDescriptions','count','rawAttributes','include','getSubjects','getFields','body','destroy','fieldName','sort','findOne','attributes','error','intersection','length','params','VIRTUAL','ZohoConfiguration','fields','filters','pick','map','sendStatus','undefined','../../mysqldb','limit','type','send','model','order','offset','nolimit','filter','catch','../../config/logger','set','status','then','where','query','name','merge','create','end','key','options','rows','keys','like','update','stack','ZohoField'];(function(_0x2282ba,_0x346822){const _0x5937a7=function(_0x3816fc){while(--_0x3816fc){_0x2282ba['push'](_0x2282ba['shift']());}};_0x5937a7(++_0x346822);}(a351_0x3468,0x171));const a351_0x5937=function(_0x2282ba,_0x346822){_0x2282ba=_0x2282ba-0x0;let _0x5937a7=a351_0x3468[_0x2282ba];return _0x5937a7;};const _0xa40167=a351_0x5937;'use strict';const _=require('lodash'),qs=require(_0xa40167('0x9')),logger=require(_0xa40167('0x2d'))('api'),db=require(_0xa40167('0x23'))['db'],{Op}=require('sequelize');function respondWithResult(_0x3816fc,_0x452435){return _0x452435=_0x452435||0xc8,function(_0x508e68){const _0x23367d=a351_0x5937;if(_0x508e68)return _0x3816fc[_0x23367d('0x2f')](_0x452435)['json'](_0x508e68);};}function respondWithFilteredResult(_0x143e3b,_0x4a84a6){return function(_0x4aede9){const _0x19ae36=a351_0x5937;if(_0x4aede9){const _0x2147f4=_0x4aede9[_0x19ae36('0xc')],_0x16284d=_0x4a84a6[_0x19ae36('0x29')];let _0x2ceb9a=_0x4a84a6[_0x19ae36('0x29')]+_0x4a84a6[_0x19ae36('0x24')],_0x3b5656;return _0x2ceb9a>=_0x2147f4?(_0x2ceb9a=_0x2147f4,_0x3b5656=0xc8):_0x3b5656=0xce,_0x143e3b['status'](_0x3b5656),_0x143e3b[_0x19ae36('0x2e')]('Content-Range',_0x16284d+'-'+_0x2ceb9a+'/'+_0x2147f4)['json'](_0x4aede9);}return null;};}function saveUpdates(_0x1a5b32){return function(_0x411e13){const _0x3fd6ec=a351_0x5937;if(_0x411e13)return _0x411e13[_0x3fd6ec('0x6')](_0x1a5b32)['then'](function(_0x214581){return _0x214581;});return null;};}function removeEntity(_0x1ccf5c){return function(_0x35ffba){const _0x7a5fdd=a351_0x5937;if(_0x35ffba)return _0x35ffba[_0x7a5fdd('0x12')]()[_0x7a5fdd('0x30')](function(){const _0x16e691=_0x7a5fdd;_0x1ccf5c[_0x16e691('0x2f')](0xcc)[_0x16e691('0x0')]();});};}function handleEntityNotFound(_0x274500){return function(_0x321f5c){const _0x326aa9=a351_0x5937;return!_0x321f5c&&_0x274500[_0x326aa9('0x21')](0x194),_0x321f5c;};}function handleError(_0x5eed05,_0x3e06d0){return _0x3e06d0=_0x3e06d0||0x1f4,function(_0x22ca9f){const _0x56a536=a351_0x5937;logger[_0x56a536('0x17')](_0x22ca9f[_0x56a536('0x7')]),_0x22ca9f['name']&&delete _0x22ca9f[_0x56a536('0x33')],_0x5eed05[_0x56a536('0x2f')](_0x3e06d0)[_0x56a536('0x26')](_0x22ca9f);};}exports['index']=function(_0x589e61,_0x3b2830){const _0x453a58=_0xa40167;let _0x29004d={};const _0x3062ee={},_0x49d91={'count':0x0,'rows':[]},_0x22253c=_[_0x453a58('0x20')](db[_0x453a58('0x1c')][_0x453a58('0xd')],function(_0x24f4b7){const _0x22010d=_0x453a58;return{'name':_0x24f4b7[_0x22010d('0x13')],'type':_0x24f4b7[_0x22010d('0x25')][_0x22010d('0x1')]};});_0x3062ee['model']=_[_0x453a58('0x20')](_0x22253c,_0x453a58('0x33')),_0x3062ee[_0x453a58('0x32')]=_[_0x453a58('0x4')](_0x589e61[_0x453a58('0x32')]),_0x3062ee[_0x453a58('0x1e')]=_[_0x453a58('0x18')](_0x3062ee[_0x453a58('0x27')],_0x3062ee['query']),_0x29004d['attributes']=_[_0x453a58('0x18')](_0x3062ee[_0x453a58('0x27')],qs[_0x453a58('0x1d')](_0x589e61[_0x453a58('0x32')]['fields'])),_0x29004d['attributes']=_0x29004d['attributes']['length']?_0x29004d[_0x453a58('0x16')]:_0x3062ee[_0x453a58('0x27')];typeof _0x589e61['query'][_0x453a58('0x2a')]===_0x453a58('0x22')&&(_0x29004d['limit']=qs[_0x453a58('0x24')](_0x589e61[_0x453a58('0x32')][_0x453a58('0x24')]),_0x29004d[_0x453a58('0x29')]=qs[_0x453a58('0x29')](_0x589e61[_0x453a58('0x32')][_0x453a58('0x29')]));_0x29004d[_0x453a58('0x28')]=qs['sort'](_0x589e61['query'][_0x453a58('0x14')]),_0x29004d['where']=qs[_0x453a58('0x1e')](_['pick'](_0x589e61[_0x453a58('0x32')],_0x3062ee[_0x453a58('0x1e')]),_0x22253c);_0x589e61[_0x453a58('0x32')]['filter']&&(_0x29004d['where']=_[_0x453a58('0x34')](_0x29004d['where'],{[Op['or']]:_[_0x453a58('0x20')](_0x22253c,function(_0x18b59e){const _0x51f0df=_0x453a58;if(_0x18b59e[_0x51f0df('0x25')]!==_0x51f0df('0x1b')){const _0x4f61d9={};return _0x4f61d9[_0x18b59e[_0x51f0df('0x33')]]={[Op[_0x51f0df('0x5')]]:'%'+_0x589e61[_0x51f0df('0x32')][_0x51f0df('0x2b')]+'%'},_0x4f61d9;}})}));_0x29004d=_['merge']({},_0x29004d,_0x589e61['options']);const _0x8dce9e={'where':_0x29004d[_0x453a58('0x31')]};return db[_0x453a58('0x1c')]['count'](_0x8dce9e)['then'](function(_0x36dc19){const _0x17ef7f=_0x453a58;return _0x49d91[_0x17ef7f('0xc')]=_0x36dc19,_0x589e61[_0x17ef7f('0x32')][_0x17ef7f('0xa')]&&(_0x29004d[_0x17ef7f('0xe')]=[{'all':!![]}]),db['ZohoConfiguration']['findAll'](_0x29004d);})[_0x453a58('0x30')](function(_0x4ec03e){const _0x319a76=_0x453a58;return _0x49d91[_0x319a76('0x3')]=_0x4ec03e,_0x49d91;})[_0x453a58('0x30')](respondWithFilteredResult(_0x3b2830,_0x29004d))['catch'](handleError(_0x3b2830,null));},exports['show']=function(_0x690689,_0x413a4e){const _0x1058ba=_0xa40167;let _0x3f28fc={'raw':![],'where':{'id':_0x690689['params']['id']}};const _0x422fed={};return _0x422fed[_0x1058ba('0x27')]=_[_0x1058ba('0x4')](db[_0x1058ba('0x1c')][_0x1058ba('0xd')]),_0x422fed['query']=_[_0x1058ba('0x4')](_0x690689[_0x1058ba('0x32')]),_0x422fed[_0x1058ba('0x1e')]=_[_0x1058ba('0x18')](_0x422fed[_0x1058ba('0x27')],_0x422fed[_0x1058ba('0x32')]),_0x3f28fc[_0x1058ba('0x16')]=_[_0x1058ba('0x18')](_0x422fed[_0x1058ba('0x27')],qs[_0x1058ba('0x1d')](_0x690689[_0x1058ba('0x32')][_0x1058ba('0x1d')])),_0x3f28fc['attributes']=_0x3f28fc['attributes'][_0x1058ba('0x19')]?_0x3f28fc[_0x1058ba('0x16')]:_0x422fed[_0x1058ba('0x27')],_0x690689[_0x1058ba('0x32')][_0x1058ba('0xa')]&&(_0x3f28fc[_0x1058ba('0xe')]=[{'all':!![]}]),_0x3f28fc=_['merge']({},_0x3f28fc,_0x690689[_0x1058ba('0x2')]),db[_0x1058ba('0x1c')][_0x1058ba('0x15')](_0x3f28fc)[_0x1058ba('0x30')](handleEntityNotFound(_0x413a4e,null))[_0x1058ba('0x30')](respondWithResult(_0x413a4e,null))['catch'](handleError(_0x413a4e,null));},exports[_0xa40167('0x35')]=function(_0x173246,_0x1f403d){const _0x1b0e03=_0xa40167;return db[_0x1b0e03('0x1c')][_0x1b0e03('0x35')](_0x173246['body'],{})[_0x1b0e03('0x30')](respondWithResult(_0x1f403d,0xc9))[_0x1b0e03('0x2c')](handleError(_0x1f403d,null));},exports[_0xa40167('0x6')]=function(_0x17a7c6,_0x50e4ec){const _0x3e3081=_0xa40167;return _0x17a7c6[_0x3e3081('0x11')]['id']&&delete _0x17a7c6[_0x3e3081('0x11')]['id'],db[_0x3e3081('0x1c')]['findOne']({'where':{'id':_0x17a7c6[_0x3e3081('0x1a')]['id']}})['then'](handleEntityNotFound(_0x50e4ec,null))[_0x3e3081('0x30')](saveUpdates(_0x17a7c6['body'],null))[_0x3e3081('0x30')](respondWithResult(_0x50e4ec,null))[_0x3e3081('0x2c')](handleError(_0x50e4ec,null));},exports[_0xa40167('0x12')]=function(_0x14e61b,_0x25e758){const _0x20ad6d=_0xa40167;return db[_0x20ad6d('0x1c')][_0x20ad6d('0x15')]({'where':{'id':_0x14e61b[_0x20ad6d('0x1a')]['id']}})[_0x20ad6d('0x30')](handleEntityNotFound(_0x25e758,null))[_0x20ad6d('0x30')](removeEntity(_0x25e758,null))['catch'](handleError(_0x25e758,null));},exports['getFields']=function(_0x459920,_0x3b2826){const _0x1548b8=_0xa40167;let _0x4b3292={};const _0x172533={};let _0x493ac6,_0x400ccd;return db[_0x1548b8('0x1c')]['findOne']({'where':{'id':_0x459920[_0x1548b8('0x1a')]['id']}})[_0x1548b8('0x30')](handleEntityNotFound(_0x3b2826,null))[_0x1548b8('0x30')](function(_0x290b3a){const _0x176087=_0x1548b8;if(_0x290b3a)return _0x493ac6=_0x290b3a,_0x172533[_0x176087('0x27')]=_[_0x176087('0x4')](db['ZohoField'][_0x176087('0xd')]),_0x172533[_0x176087('0x32')]=_[_0x176087('0x4')](_0x459920[_0x176087('0x32')]),_0x172533[_0x176087('0x1e')]=_[_0x176087('0x18')](_0x172533[_0x176087('0x27')],_0x172533[_0x176087('0x32')]),_0x4b3292[_0x176087('0x16')]=_[_0x176087('0x18')](_0x172533[_0x176087('0x27')],qs[_0x176087('0x1d')](_0x459920[_0x176087('0x32')]['fields'])),_0x4b3292[_0x176087('0x16')]=_0x4b3292[_0x176087('0x16')]['length']?_0x4b3292['attributes']:_0x172533['model'],_0x4b3292['order']=qs[_0x176087('0x14')](_0x459920['query']['sort']),_0x4b3292['where']=qs['filters'](_[_0x176087('0x1f')](_0x459920[_0x176087('0x32')],_0x172533['filters'])),_0x459920['query'][_0x176087('0x2b')]&&(_0x4b3292['where']=_[_0x176087('0x34')](_0x4b3292[_0x176087('0x31')],{[Op['or']]:_[_0x176087('0x20')](_0x4b3292[_0x176087('0x16')],function(_0x5ca819){const _0x5dbbe9=_0x176087,_0x49e695={};return _0x49e695[_0x5ca819]={[Op[_0x5dbbe9('0x5')]]:'%'+_0x459920[_0x5dbbe9('0x32')]['filter']+'%'},_0x49e695;})})),_0x4b3292=_[_0x176087('0x34')]({},_0x4b3292,_0x459920[_0x176087('0x2')]),_0x493ac6['getFields'](_0x4b3292);})['then'](function(_0x58bb26){const _0x55163e=_0x1548b8;if(_0x58bb26)return _0x400ccd=_0x58bb26[_0x55163e('0x19')],typeof _0x459920['query'][_0x55163e('0x2a')]===_0x55163e('0x22')&&(_0x4b3292[_0x55163e('0x24')]=qs[_0x55163e('0x24')](_0x459920[_0x55163e('0x32')]['limit']),_0x4b3292[_0x55163e('0x29')]=qs['offset'](_0x459920[_0x55163e('0x32')]['offset'])),_0x493ac6[_0x55163e('0x10')](_0x4b3292);})[_0x1548b8('0x30')](function(_0x3fd5c6){if(_0x3fd5c6)return _0x3fd5c6?{'count':_0x400ccd,'rows':_0x3fd5c6}:null;})[_0x1548b8('0x30')](respondWithResult(_0x3b2826,null))[_0x1548b8('0x2c')](handleError(_0x3b2826,null));},exports[_0xa40167('0xf')]=function(_0xe6f894,_0x2abb51){const _0x3b0e1c=_0xa40167;let _0x2de96a={};const _0x153f23={};let _0x20c3d5,_0x5e6649;return db[_0x3b0e1c('0x1c')][_0x3b0e1c('0x15')]({'where':{'id':_0xe6f894[_0x3b0e1c('0x1a')]['id']}})[_0x3b0e1c('0x30')](handleEntityNotFound(_0x2abb51,null))[_0x3b0e1c('0x30')](function(_0x766def){const _0x398a05=_0x3b0e1c;if(_0x766def)return _0x20c3d5=_0x766def,_0x153f23[_0x398a05('0x27')]=_[_0x398a05('0x4')](db[_0x398a05('0x8')][_0x398a05('0xd')]),_0x153f23[_0x398a05('0x32')]=_[_0x398a05('0x4')](_0xe6f894[_0x398a05('0x32')]),_0x153f23[_0x398a05('0x1e')]=_[_0x398a05('0x18')](_0x153f23[_0x398a05('0x27')],_0x153f23[_0x398a05('0x32')]),_0x2de96a[_0x398a05('0x16')]=_['intersection'](_0x153f23['model'],qs[_0x398a05('0x1d')](_0xe6f894[_0x398a05('0x32')][_0x398a05('0x1d')])),_0x2de96a[_0x398a05('0x16')]=_0x2de96a['attributes']['length']?_0x2de96a[_0x398a05('0x16')]:_0x153f23[_0x398a05('0x27')],_0x2de96a['order']=qs[_0x398a05('0x14')](_0xe6f894[_0x398a05('0x32')][_0x398a05('0x14')]),_0x2de96a[_0x398a05('0x31')]=qs['filters'](_['pick'](_0xe6f894[_0x398a05('0x32')],_0x153f23[_0x398a05('0x1e')])),_0xe6f894[_0x398a05('0x32')][_0x398a05('0x2b')]&&(_0x2de96a['where']=_['merge'](_0x2de96a['where'],{[Op['or']]:_['map'](_0x2de96a['attributes'],function(_0x4effec){const _0x2ee80c=_0x398a05,_0x2f8174={};return _0x2f8174[_0x4effec]={[Op['like']]:'%'+_0xe6f894[_0x2ee80c('0x32')]['filter']+'%'},_0x2f8174;})})),_0x2de96a=_['merge']({},_0x2de96a,_0xe6f894[_0x398a05('0x2')]),_0x20c3d5[_0x398a05('0xf')](_0x2de96a);})[_0x3b0e1c('0x30')](function(_0x2772ef){const _0x16d8d8=_0x3b0e1c;if(_0x2772ef)return _0x5e6649=_0x2772ef[_0x16d8d8('0x19')],typeof _0xe6f894[_0x16d8d8('0x32')]['nolimit']==='undefined'&&(_0x2de96a['limit']=qs['limit'](_0xe6f894[_0x16d8d8('0x32')]['limit']),_0x2de96a[_0x16d8d8('0x29')]=qs[_0x16d8d8('0x29')](_0xe6f894[_0x16d8d8('0x32')][_0x16d8d8('0x29')])),_0x20c3d5['getSubjects'](_0x2de96a);})[_0x3b0e1c('0x30')](function(_0x371efc){if(_0x371efc)return _0x371efc?{'count':_0x5e6649,'rows':_0x371efc}:null;})[_0x3b0e1c('0x30')](respondWithResult(_0x2abb51,null))[_0x3b0e1c('0x2c')](handleError(_0x2abb51,null));},exports[_0xa40167('0xb')]=function(_0x164a94,_0x25afdb){const _0x436d16=_0xa40167;let _0x34051d={};const _0x474596={};let _0x59e675,_0x4f139e;return db['ZohoConfiguration']['findOne']({'where':{'id':_0x164a94[_0x436d16('0x1a')]['id']}})[_0x436d16('0x30')](handleEntityNotFound(_0x25afdb,null))[_0x436d16('0x30')](function(_0x514bcc){const _0x150fc7=_0x436d16;if(_0x514bcc)return _0x59e675=_0x514bcc,_0x474596[_0x150fc7('0x27')]=_[_0x150fc7('0x4')](db[_0x150fc7('0x8')][_0x150fc7('0xd')]),_0x474596[_0x150fc7('0x32')]=_['keys'](_0x164a94[_0x150fc7('0x32')]),_0x474596['filters']=_[_0x150fc7('0x18')](_0x474596[_0x150fc7('0x27')],_0x474596['query']),_0x34051d[_0x150fc7('0x16')]=_[_0x150fc7('0x18')](_0x474596[_0x150fc7('0x27')],qs[_0x150fc7('0x1d')](_0x164a94[_0x150fc7('0x32')][_0x150fc7('0x1d')])),_0x34051d['attributes']=_0x34051d[_0x150fc7('0x16')]['length']?_0x34051d[_0x150fc7('0x16')]:_0x474596[_0x150fc7('0x27')],_0x34051d[_0x150fc7('0x28')]=qs[_0x150fc7('0x14')](_0x164a94['query'][_0x150fc7('0x14')]),_0x34051d[_0x150fc7('0x31')]=qs['filters'](_[_0x150fc7('0x1f')](_0x164a94[_0x150fc7('0x32')],_0x474596['filters'])),_0x164a94[_0x150fc7('0x32')]['filter']&&(_0x34051d['where']=_[_0x150fc7('0x34')](_0x34051d[_0x150fc7('0x31')],{[Op['or']]:_['map'](_0x34051d[_0x150fc7('0x16')],function(_0x509c6f){const _0x595afc=_0x150fc7,_0x41efde={};return _0x41efde[_0x509c6f]={[Op[_0x595afc('0x5')]]:'%'+_0x164a94[_0x595afc('0x32')][_0x595afc('0x2b')]+'%'},_0x41efde;})})),_0x34051d=_[_0x150fc7('0x34')]({},_0x34051d,_0x164a94[_0x150fc7('0x2')]),_0x59e675[_0x150fc7('0xb')](_0x34051d);})['then'](function(_0x2aa99d){const _0x526428=_0x436d16;if(_0x2aa99d)return _0x4f139e=_0x2aa99d[_0x526428('0x19')],typeof _0x164a94[_0x526428('0x32')][_0x526428('0x2a')]===_0x526428('0x22')&&(_0x34051d[_0x526428('0x24')]=qs['limit'](_0x164a94[_0x526428('0x32')][_0x526428('0x24')]),_0x34051d[_0x526428('0x29')]=qs[_0x526428('0x29')](_0x164a94[_0x526428('0x32')][_0x526428('0x29')])),_0x59e675[_0x526428('0xb')](_0x34051d);})[_0x436d16('0x30')](function(_0xea1a56){if(_0xea1a56)return _0xea1a56?{'count':_0x4f139e,'rows':_0xea1a56}:null;})[_0x436d16('0x30')](respondWithResult(_0x25afdb,null))[_0x436d16('0x2c')](handleError(_0x25afdb,null));}; \ No newline at end of file diff --git a/server/api/intZohoConfiguration/intZohoConfiguration.model.js b/server/api/intZohoConfiguration/intZohoConfiguration.model.js index a702c2c..a40b721 100644 --- a/server/api/intZohoConfiguration/intZohoConfiguration.model.js +++ b/server/api/intZohoConfiguration/intZohoConfiguration.model.js @@ -1 +1 @@ -const a352_0x3195=['define','int_zoho_configurations','./intZohoConfiguration.attributes','ZohoConfiguration','exports'];(function(_0x14a13d,_0x319576){const _0x493854=function(_0x658f85){while(--_0x658f85){_0x14a13d['push'](_0x14a13d['shift']());}};_0x493854(++_0x319576);}(a352_0x3195,0x1da));const a352_0x4938=function(_0x14a13d,_0x319576){_0x14a13d=_0x14a13d-0x0;let _0x493854=a352_0x3195[_0x14a13d];return _0x493854;};const _0x10b4a5=a352_0x4938;'use strict';const attributes=require(_0x10b4a5('0x3'));module[_0x10b4a5('0x0')]=function(_0x658f85){const _0xf967f5=_0x10b4a5,_0x35dcf2=_0x658f85[_0xf967f5('0x1')](_0xf967f5('0x4'),attributes,{'tableName':_0xf967f5('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x35dcf2;}; \ No newline at end of file +const a352_0x45ff=['./intZohoConfiguration.attributes','int_zoho_configurations','ZohoConfiguration','define'];(function(_0x177089,_0x45ff17){const _0x61f43c=function(_0x2d31e5){while(--_0x2d31e5){_0x177089['push'](_0x177089['shift']());}};_0x61f43c(++_0x45ff17);}(a352_0x45ff,0xa5));const a352_0x61f4=function(_0x177089,_0x45ff17){_0x177089=_0x177089-0x0;let _0x61f43c=a352_0x45ff[_0x177089];return _0x61f43c;};const _0x15ad1c=a352_0x61f4;'use strict';const attributes=require(_0x15ad1c('0x3'));module['exports']=function(_0x2d31e5){const _0x2a2f97=_0x15ad1c,_0x2a141c=_0x2d31e5[_0x2a2f97('0x2')](_0x2a2f97('0x1'),attributes,{'tableName':_0x2a2f97('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2a141c;}; \ No newline at end of file diff --git a/server/api/intZohoField/index.js b/server/api/intZohoField/index.js index ea55db5..c7a83b0 100644 --- a/server/api/intZohoField/index.js +++ b/server/api/intZohoField/index.js @@ -1 +1 @@ -const a353_0x27ef=['destroy','put','express','./intZohoField.controller','show','get','create','update','/:id','Router','exports','index','isAuthenticated','../../components/auth/service','delete'];(function(_0x12e6c6,_0x27eff6){const _0x17641d=function(_0x2b3679){while(--_0x2b3679){_0x12e6c6['push'](_0x12e6c6['shift']());}};_0x17641d(++_0x27eff6);}(a353_0x27ef,0x1b2));const a353_0x1764=function(_0x12e6c6,_0x27eff6){_0x12e6c6=_0x12e6c6-0x0;let _0x17641d=a353_0x27ef[_0x12e6c6];return _0x17641d;};const _0x2a9139=a353_0x1764;'use strict';const express=require(_0x2a9139('0x3')),router=express[_0x2a9139('0xa')](),auth=require(_0x2a9139('0xe')),controller=require(_0x2a9139('0x4'));router[_0x2a9139('0x6')]('/',auth[_0x2a9139('0xd')](),controller[_0x2a9139('0xc')]),router[_0x2a9139('0x6')]('/:id',auth[_0x2a9139('0xd')](),controller[_0x2a9139('0x5')]),router['post']('/',auth['isAuthenticated'](),controller[_0x2a9139('0x7')]),router[_0x2a9139('0x2')]('/:id',auth['isAuthenticated'](),controller[_0x2a9139('0x8')]),router[_0x2a9139('0x0')](_0x2a9139('0x9'),auth[_0x2a9139('0xd')](),controller[_0x2a9139('0x1')]),module[_0x2a9139('0xb')]=router; \ No newline at end of file +const a353_0x49c3=['/:id','put','index','update','./intZohoField.controller','Router','delete','create','../../components/auth/service','post','destroy','isAuthenticated','express','show'];(function(_0x480ba6,_0x49c358){const _0x2697ec=function(_0x46a8ec){while(--_0x46a8ec){_0x480ba6['push'](_0x480ba6['shift']());}};_0x2697ec(++_0x49c358);}(a353_0x49c3,0x116));const a353_0x2697=function(_0x480ba6,_0x49c358){_0x480ba6=_0x480ba6-0x0;let _0x2697ec=a353_0x49c3[_0x480ba6];return _0x2697ec;};const _0x5b9207=a353_0x2697;'use strict';const express=require(_0x5b9207('0x0')),router=express[_0x5b9207('0x7')](),auth=require(_0x5b9207('0xa')),controller=require(_0x5b9207('0x6'));router['get']('/',auth['isAuthenticated'](),controller[_0x5b9207('0x4')]),router['get']('/:id',auth[_0x5b9207('0xd')](),controller[_0x5b9207('0x1')]),router[_0x5b9207('0xb')]('/',auth[_0x5b9207('0xd')](),controller[_0x5b9207('0x9')]),router[_0x5b9207('0x3')](_0x5b9207('0x2'),auth[_0x5b9207('0xd')](),controller[_0x5b9207('0x5')]),router[_0x5b9207('0x8')](_0x5b9207('0x2'),auth[_0x5b9207('0xd')](),controller[_0x5b9207('0xc')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/intZohoField/intZohoField.attributes.js b/server/api/intZohoField/intZohoField.attributes.js index 86b4cb7..2e1bbf2 100644 --- a/server/api/intZohoField/intZohoField.attributes.js +++ b/server/api/intZohoField/intZohoField.attributes.js @@ -1 +1 @@ -const a354_0x2988=['string','sequelize','BOOLEAN','variable','exports','customVariable','STRING','ENUM'];(function(_0xff3e81,_0x2988e4){const _0x104f43=function(_0x44ecf9){while(--_0x44ecf9){_0xff3e81['push'](_0xff3e81['shift']());}};_0x104f43(++_0x2988e4);}(a354_0x2988,0x1c1));const a354_0x104f=function(_0xff3e81,_0x2988e4){_0xff3e81=_0xff3e81-0x0;let _0x104f43=a354_0x2988[_0xff3e81];return _0x104f43;};const _0x39f524=a354_0x104f;'use strict';const Sequelize=require(_0x39f524('0x0'));module[_0x39f524('0x3')]={'type':{'type':Sequelize['ENUM']('string',_0x39f524('0x2'),_0x39f524('0x4'),'keyValue'),'defaultValue':_0x39f524('0x7')},'content':{'type':Sequelize[_0x39f524('0x5')]},'key':{'type':Sequelize[_0x39f524('0x5')]},'keyType':{'type':Sequelize[_0x39f524('0x6')](_0x39f524('0x7'),_0x39f524('0x2'),_0x39f524('0x4'))},'keyContent':{'type':Sequelize[_0x39f524('0x5')]},'idField':{'type':Sequelize[_0x39f524('0x5')]},'nameField':{'type':Sequelize[_0x39f524('0x5')]},'customField':{'type':Sequelize[_0x39f524('0x1')],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x39f524('0x5')]}}; \ No newline at end of file +const a354_0x393d=['STRING','ENUM','exports','sequelize','keyValue','string','variable','customVariable'];(function(_0x50cead,_0x393dde){const _0x2fbb53=function(_0x2d5d37){while(--_0x2d5d37){_0x50cead['push'](_0x50cead['shift']());}};_0x2fbb53(++_0x393dde);}(a354_0x393d,0x119));const a354_0x2fbb=function(_0x50cead,_0x393dde){_0x50cead=_0x50cead-0x0;let _0x2fbb53=a354_0x393d[_0x50cead];return _0x2fbb53;};const _0x176c6b=a354_0x2fbb;'use strict';const Sequelize=require(_0x176c6b('0x2'));module[_0x176c6b('0x1')]={'type':{'type':Sequelize[_0x176c6b('0x0')]('string','variable',_0x176c6b('0x6'),_0x176c6b('0x3')),'defaultValue':_0x176c6b('0x4')},'content':{'type':Sequelize['STRING']},'key':{'type':Sequelize['STRING']},'keyType':{'type':Sequelize[_0x176c6b('0x0')]('string',_0x176c6b('0x5'),_0x176c6b('0x6'))},'keyContent':{'type':Sequelize['STRING']},'idField':{'type':Sequelize[_0x176c6b('0x7')]},'nameField':{'type':Sequelize['STRING']},'customField':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'variableName':{'type':Sequelize[_0x176c6b('0x7')]}}; \ No newline at end of file diff --git a/server/api/intZohoField/intZohoField.controller.js b/server/api/intZohoField/intZohoField.controller.js index d7e40ce..8e4a912 100644 --- a/server/api/intZohoField/intZohoField.controller.js +++ b/server/api/intZohoField/intZohoField.controller.js @@ -1 +1 @@ -const a355_0x53f9=['sendStatus','then','VIRTUAL','end','body','map','sequelize','sort','../../components/parsers/qs','order','where','rows','include','send','api','like','limit','includeAll','params','filters','rawAttributes','stack','create','findAll','../../mysqldb','attributes','model','type','ZohoField','intersection','set','nolimit','index','status','count','findOne','update','options','fieldName','lodash','fields','keys','length','query','undefined','../../config/logger','offset','filter','destroy','merge','catch'];(function(_0x1cb3e0,_0x53f968){const _0x1b9259=function(_0x3b2856){while(--_0x3b2856){_0x1cb3e0['push'](_0x1cb3e0['shift']());}};_0x1b9259(++_0x53f968);}(a355_0x53f9,0x1ab));const a355_0x1b92=function(_0x1cb3e0,_0x53f968){_0x1cb3e0=_0x1cb3e0-0x0;let _0x1b9259=a355_0x53f9[_0x1cb3e0];return _0x1b9259;};const _0x34f2f6=a355_0x1b92;'use strict';const _=require(_0x34f2f6('0x14')),qs=require(_0x34f2f6('0x28')),logger=require(_0x34f2f6('0x1a'))(_0x34f2f6('0x2e')),db=require(_0x34f2f6('0x5'))['db'],{Op}=require(_0x34f2f6('0x26'));function respondWithResult(_0x3b2856,_0x53fc11){return _0x53fc11=_0x53fc11||0xc8,function(_0xce8bd8){if(_0xce8bd8)return _0x3b2856['status'](_0x53fc11)['json'](_0xce8bd8);};}function respondWithFilteredResult(_0x433d1f,_0x2a331f){return function(_0x4c52f8){const _0x58b790=a355_0x1b92;if(_0x4c52f8){const _0x3a7b62=_0x4c52f8[_0x58b790('0xf')],_0x449f4f=_0x2a331f[_0x58b790('0x1b')];let _0x2ce891=_0x2a331f[_0x58b790('0x1b')]+_0x2a331f[_0x58b790('0x30')],_0x17ec38;return _0x2ce891>=_0x3a7b62?(_0x2ce891=_0x3a7b62,_0x17ec38=0xc8):_0x17ec38=0xce,_0x433d1f['status'](_0x17ec38),_0x433d1f[_0x58b790('0xb')]('Content-Range',_0x449f4f+'-'+_0x2ce891+'/'+_0x3a7b62)['json'](_0x4c52f8);}return null;};}function saveUpdates(_0x229695){return function(_0x31c083){const _0x191300=a355_0x1b92;if(_0x31c083)return _0x31c083[_0x191300('0x11')](_0x229695)[_0x191300('0x21')](function(_0x4c3536){return _0x4c3536;});return null;};}function removeEntity(_0x211494){return function(_0x4357d2){const _0x5d81bd=a355_0x1b92;if(_0x4357d2)return _0x4357d2[_0x5d81bd('0x1d')]()[_0x5d81bd('0x21')](function(){const _0x2c6e7c=_0x5d81bd;_0x211494[_0x2c6e7c('0xe')](0xcc)[_0x2c6e7c('0x23')]();});};}function handleEntityNotFound(_0x37b06e){return function(_0x5b4fcb){const _0x3a7769=a355_0x1b92;return!_0x5b4fcb&&_0x37b06e[_0x3a7769('0x20')](0x194),_0x5b4fcb;};}function handleError(_0x28f253,_0x2f385a){return _0x2f385a=_0x2f385a||0x1f4,function(_0x32a45f){const _0x97b1e5=a355_0x1b92;logger['error'](_0x32a45f[_0x97b1e5('0x2')]),_0x32a45f['name']&&delete _0x32a45f['name'],_0x28f253[_0x97b1e5('0xe')](_0x2f385a)[_0x97b1e5('0x2d')](_0x32a45f);};}exports[_0x34f2f6('0xd')]=function(_0x3f70a7,_0x39e949){const _0x337594=_0x34f2f6;let _0xb9e6b7={};const _0x229aad={},_0x2d5a68={'count':0x0,'rows':[]},_0x15343c=_[_0x337594('0x25')](db[_0x337594('0x9')]['rawAttributes'],function(_0x5ea0bb){const _0x3dc1af=_0x337594;return{'name':_0x5ea0bb[_0x3dc1af('0x13')],'type':_0x5ea0bb[_0x3dc1af('0x8')]['key']};});_0x229aad[_0x337594('0x7')]=_[_0x337594('0x25')](_0x15343c,'name'),_0x229aad['query']=_[_0x337594('0x16')](_0x3f70a7[_0x337594('0x18')]),_0x229aad[_0x337594('0x0')]=_[_0x337594('0xa')](_0x229aad['model'],_0x229aad[_0x337594('0x18')]),_0xb9e6b7['attributes']=_['intersection'](_0x229aad[_0x337594('0x7')],qs['fields'](_0x3f70a7[_0x337594('0x18')][_0x337594('0x15')])),_0xb9e6b7[_0x337594('0x6')]=_0xb9e6b7[_0x337594('0x6')][_0x337594('0x17')]?_0xb9e6b7[_0x337594('0x6')]:_0x229aad[_0x337594('0x7')];typeof _0x3f70a7['query'][_0x337594('0xc')]===_0x337594('0x19')&&(_0xb9e6b7[_0x337594('0x30')]=qs['limit'](_0x3f70a7[_0x337594('0x18')][_0x337594('0x30')]),_0xb9e6b7[_0x337594('0x1b')]=qs[_0x337594('0x1b')](_0x3f70a7[_0x337594('0x18')][_0x337594('0x1b')]));_0xb9e6b7[_0x337594('0x29')]=qs[_0x337594('0x27')](_0x3f70a7['query'][_0x337594('0x27')]),_0xb9e6b7[_0x337594('0x2a')]=qs[_0x337594('0x0')](_['pick'](_0x3f70a7[_0x337594('0x18')],_0x229aad[_0x337594('0x0')]),_0x15343c);_0x3f70a7[_0x337594('0x18')]['filter']&&(_0xb9e6b7['where']=_[_0x337594('0x1e')](_0xb9e6b7['where'],{[Op['or']]:_[_0x337594('0x25')](_0x15343c,function(_0x9f2fb7){const _0x4ba015=_0x337594;if(_0x9f2fb7[_0x4ba015('0x8')]!==_0x4ba015('0x22')){const _0xd81cd={};return _0xd81cd[_0x9f2fb7['name']]={[Op[_0x4ba015('0x2f')]]:'%'+_0x3f70a7[_0x4ba015('0x18')][_0x4ba015('0x1c')]+'%'},_0xd81cd;}})}));_0xb9e6b7=_[_0x337594('0x1e')]({},_0xb9e6b7,_0x3f70a7['options']);const _0x4bb839={'where':_0xb9e6b7['where']};return db[_0x337594('0x9')]['count'](_0x4bb839)[_0x337594('0x21')](function(_0x3fb996){const _0x3433c2=_0x337594;return _0x2d5a68['count']=_0x3fb996,_0x3f70a7[_0x3433c2('0x18')][_0x3433c2('0x31')]&&(_0xb9e6b7[_0x3433c2('0x2c')]=[{'all':!![]}]),db['ZohoField'][_0x3433c2('0x4')](_0xb9e6b7);})[_0x337594('0x21')](function(_0x4cd950){const _0x293220=_0x337594;return _0x2d5a68[_0x293220('0x2b')]=_0x4cd950,_0x2d5a68;})[_0x337594('0x21')](respondWithFilteredResult(_0x39e949,_0xb9e6b7))[_0x337594('0x1f')](handleError(_0x39e949,null));},exports['show']=function(_0x1bf733,_0x546f48){const _0x53812a=_0x34f2f6;let _0x30681a={'raw':!![],'where':{'id':_0x1bf733['params']['id']}};const _0x20e0c3={};return _0x20e0c3[_0x53812a('0x7')]=_[_0x53812a('0x16')](db[_0x53812a('0x9')][_0x53812a('0x1')]),_0x20e0c3[_0x53812a('0x18')]=_['keys'](_0x1bf733[_0x53812a('0x18')]),_0x20e0c3['filters']=_['intersection'](_0x20e0c3[_0x53812a('0x7')],_0x20e0c3[_0x53812a('0x18')]),_0x30681a[_0x53812a('0x6')]=_[_0x53812a('0xa')](_0x20e0c3[_0x53812a('0x7')],qs[_0x53812a('0x15')](_0x1bf733[_0x53812a('0x18')][_0x53812a('0x15')])),_0x30681a['attributes']=_0x30681a[_0x53812a('0x6')]['length']?_0x30681a[_0x53812a('0x6')]:_0x20e0c3['model'],_0x1bf733['query']['includeAll']&&(_0x30681a[_0x53812a('0x2c')]=[{'all':!![]}]),_0x30681a=_[_0x53812a('0x1e')]({},_0x30681a,_0x1bf733[_0x53812a('0x12')]),db[_0x53812a('0x9')]['findOne'](_0x30681a)[_0x53812a('0x21')](handleEntityNotFound(_0x546f48,null))[_0x53812a('0x21')](respondWithResult(_0x546f48,null))['catch'](handleError(_0x546f48,null));},exports[_0x34f2f6('0x3')]=function(_0x3be3a7,_0x2f24cb){const _0x36a0dc=_0x34f2f6;return db[_0x36a0dc('0x9')][_0x36a0dc('0x3')](_0x3be3a7[_0x36a0dc('0x24')],{})[_0x36a0dc('0x21')](respondWithResult(_0x2f24cb,0xc9))[_0x36a0dc('0x1f')](handleError(_0x2f24cb,null));},exports[_0x34f2f6('0x11')]=function(_0x13a0c8,_0xd6693d){const _0x9a774e=_0x34f2f6;return _0x13a0c8[_0x9a774e('0x24')]['id']&&delete _0x13a0c8[_0x9a774e('0x24')]['id'],db[_0x9a774e('0x9')][_0x9a774e('0x10')]({'where':{'id':_0x13a0c8[_0x9a774e('0x32')]['id']}})[_0x9a774e('0x21')](handleEntityNotFound(_0xd6693d,null))[_0x9a774e('0x21')](saveUpdates(_0x13a0c8[_0x9a774e('0x24')],null))[_0x9a774e('0x21')](respondWithResult(_0xd6693d,null))['catch'](handleError(_0xd6693d,null));},exports[_0x34f2f6('0x1d')]=function(_0x4cea21,_0x1becfa){const _0x77003a=_0x34f2f6;return db[_0x77003a('0x9')][_0x77003a('0x10')]({'where':{'id':_0x4cea21[_0x77003a('0x32')]['id']}})[_0x77003a('0x21')](handleEntityNotFound(_0x1becfa,null))[_0x77003a('0x21')](removeEntity(_0x1becfa,null))[_0x77003a('0x1f')](handleError(_0x1becfa,null));}; \ No newline at end of file +const a355_0x3032=['status','ZohoField','query','nolimit','index','offset','create','model','name','json','undefined','Content-Range','type','sort','keys','findAll','rawAttributes','length','options','error','filter','rows','like','include','body','count','sendStatus','intersection','update','findOne','then','order','fields','includeAll','limit','merge','stack','catch','where','map','filters','VIRTUAL','show','end','destroy','send','attributes','fieldName','api','params'];(function(_0x1c019d,_0x3032bf){const _0x4f2adc=function(_0x2cc755){while(--_0x2cc755){_0x1c019d['push'](_0x1c019d['shift']());}};_0x4f2adc(++_0x3032bf);}(a355_0x3032,0x1cc));const a355_0x4f2a=function(_0x1c019d,_0x3032bf){_0x1c019d=_0x1c019d-0x0;let _0x4f2adc=a355_0x3032[_0x1c019d];return _0x4f2adc;};const _0xd1db2d=a355_0x4f2a;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0xd1db2d('0x26')),db=require('../../mysqldb')['db'],{Op}=require('sequelize');function respondWithResult(_0x2cc755,_0x227cfb){return _0x227cfb=_0x227cfb||0xc8,function(_0x11c787){const _0x1e9826=a355_0x4f2a;if(_0x11c787)return _0x2cc755[_0x1e9826('0x28')](_0x227cfb)['json'](_0x11c787);};}function respondWithFilteredResult(_0x3895fe,_0x364c4c){return function(_0x1fba45){const _0x55853c=a355_0x4f2a;if(_0x1fba45){const _0xe313a4=_0x1fba45[_0x55853c('0xf')],_0x3c8c8c=_0x364c4c['offset'];let _0x5b365f=_0x364c4c[_0x55853c('0x2d')]+_0x364c4c[_0x55853c('0x18')],_0x2e55e0;return _0x5b365f>=_0xe313a4?(_0x5b365f=_0xe313a4,_0x2e55e0=0xc8):_0x2e55e0=0xce,_0x3895fe[_0x55853c('0x28')](_0x2e55e0),_0x3895fe['set'](_0x55853c('0x1'),_0x3c8c8c+'-'+_0x5b365f+'/'+_0xe313a4)[_0x55853c('0x31')](_0x1fba45);}return null;};}function saveUpdates(_0x51d9ad){return function(_0x529df4){const _0x47bc3d=a355_0x4f2a;if(_0x529df4)return _0x529df4[_0x47bc3d('0x12')](_0x51d9ad)[_0x47bc3d('0x14')](function(_0x2b72e0){return _0x2b72e0;});return null;};}function removeEntity(_0x16222c){return function(_0x2997c9){const _0x26987f=a355_0x4f2a;if(_0x2997c9)return _0x2997c9['destroy']()[_0x26987f('0x14')](function(){const _0xa7daec=_0x26987f;_0x16222c[_0xa7daec('0x28')](0xcc)[_0xa7daec('0x21')]();});};}function handleEntityNotFound(_0x43f03f){return function(_0x46ca28){const _0xace332=a355_0x4f2a;return!_0x46ca28&&_0x43f03f[_0xace332('0x10')](0x194),_0x46ca28;};}function handleError(_0x27a8ef,_0x55e3dd){return _0x55e3dd=_0x55e3dd||0x1f4,function(_0x1e4019){const _0x4cfdae=a355_0x4f2a;logger[_0x4cfdae('0x9')](_0x1e4019[_0x4cfdae('0x1a')]),_0x1e4019['name']&&delete _0x1e4019[_0x4cfdae('0x30')],_0x27a8ef[_0x4cfdae('0x28')](_0x55e3dd)[_0x4cfdae('0x23')](_0x1e4019);};}exports[_0xd1db2d('0x2c')]=function(_0x567639,_0x5ec052){const _0xf1e8e0=_0xd1db2d;let _0x1d3a81={};const _0x35d40f={},_0x16bb8e={'count':0x0,'rows':[]},_0x23541c=_[_0xf1e8e0('0x1d')](db[_0xf1e8e0('0x29')][_0xf1e8e0('0x6')],function(_0x1817b9){const _0x12258c=_0xf1e8e0;return{'name':_0x1817b9[_0x12258c('0x25')],'type':_0x1817b9[_0x12258c('0x2')]['key']};});_0x35d40f[_0xf1e8e0('0x2f')]=_[_0xf1e8e0('0x1d')](_0x23541c,_0xf1e8e0('0x30')),_0x35d40f['query']=_['keys'](_0x567639[_0xf1e8e0('0x2a')]),_0x35d40f['filters']=_['intersection'](_0x35d40f['model'],_0x35d40f[_0xf1e8e0('0x2a')]),_0x1d3a81[_0xf1e8e0('0x24')]=_['intersection'](_0x35d40f['model'],qs[_0xf1e8e0('0x16')](_0x567639[_0xf1e8e0('0x2a')][_0xf1e8e0('0x16')])),_0x1d3a81[_0xf1e8e0('0x24')]=_0x1d3a81[_0xf1e8e0('0x24')][_0xf1e8e0('0x7')]?_0x1d3a81[_0xf1e8e0('0x24')]:_0x35d40f[_0xf1e8e0('0x2f')];typeof _0x567639[_0xf1e8e0('0x2a')][_0xf1e8e0('0x2b')]===_0xf1e8e0('0x0')&&(_0x1d3a81[_0xf1e8e0('0x18')]=qs[_0xf1e8e0('0x18')](_0x567639[_0xf1e8e0('0x2a')][_0xf1e8e0('0x18')]),_0x1d3a81['offset']=qs[_0xf1e8e0('0x2d')](_0x567639[_0xf1e8e0('0x2a')]['offset']));_0x1d3a81[_0xf1e8e0('0x15')]=qs[_0xf1e8e0('0x3')](_0x567639[_0xf1e8e0('0x2a')]['sort']),_0x1d3a81[_0xf1e8e0('0x1c')]=qs[_0xf1e8e0('0x1e')](_['pick'](_0x567639[_0xf1e8e0('0x2a')],_0x35d40f['filters']),_0x23541c);_0x567639[_0xf1e8e0('0x2a')][_0xf1e8e0('0xa')]&&(_0x1d3a81['where']=_[_0xf1e8e0('0x19')](_0x1d3a81[_0xf1e8e0('0x1c')],{[Op['or']]:_[_0xf1e8e0('0x1d')](_0x23541c,function(_0x28ca3a){const _0x557549=_0xf1e8e0;if(_0x28ca3a[_0x557549('0x2')]!==_0x557549('0x1f')){const _0x2ebc8e={};return _0x2ebc8e[_0x28ca3a[_0x557549('0x30')]]={[Op[_0x557549('0xc')]]:'%'+_0x567639[_0x557549('0x2a')]['filter']+'%'},_0x2ebc8e;}})}));_0x1d3a81=_[_0xf1e8e0('0x19')]({},_0x1d3a81,_0x567639['options']);const _0x94146a={'where':_0x1d3a81[_0xf1e8e0('0x1c')]};return db[_0xf1e8e0('0x29')][_0xf1e8e0('0xf')](_0x94146a)[_0xf1e8e0('0x14')](function(_0x12a8fd){const _0x48374e=_0xf1e8e0;return _0x16bb8e[_0x48374e('0xf')]=_0x12a8fd,_0x567639[_0x48374e('0x2a')][_0x48374e('0x17')]&&(_0x1d3a81[_0x48374e('0xd')]=[{'all':!![]}]),db[_0x48374e('0x29')][_0x48374e('0x5')](_0x1d3a81);})[_0xf1e8e0('0x14')](function(_0x35f86e){const _0x3b2585=_0xf1e8e0;return _0x16bb8e[_0x3b2585('0xb')]=_0x35f86e,_0x16bb8e;})[_0xf1e8e0('0x14')](respondWithFilteredResult(_0x5ec052,_0x1d3a81))[_0xf1e8e0('0x1b')](handleError(_0x5ec052,null));},exports[_0xd1db2d('0x20')]=function(_0x46ceb7,_0x381264){const _0x597487=_0xd1db2d;let _0x38f372={'raw':!![],'where':{'id':_0x46ceb7['params']['id']}};const _0x429ebc={};return _0x429ebc[_0x597487('0x2f')]=_[_0x597487('0x4')](db[_0x597487('0x29')][_0x597487('0x6')]),_0x429ebc[_0x597487('0x2a')]=_[_0x597487('0x4')](_0x46ceb7[_0x597487('0x2a')]),_0x429ebc[_0x597487('0x1e')]=_[_0x597487('0x11')](_0x429ebc[_0x597487('0x2f')],_0x429ebc[_0x597487('0x2a')]),_0x38f372[_0x597487('0x24')]=_[_0x597487('0x11')](_0x429ebc[_0x597487('0x2f')],qs[_0x597487('0x16')](_0x46ceb7[_0x597487('0x2a')]['fields'])),_0x38f372['attributes']=_0x38f372[_0x597487('0x24')][_0x597487('0x7')]?_0x38f372[_0x597487('0x24')]:_0x429ebc[_0x597487('0x2f')],_0x46ceb7['query'][_0x597487('0x17')]&&(_0x38f372['include']=[{'all':!![]}]),_0x38f372=_[_0x597487('0x19')]({},_0x38f372,_0x46ceb7[_0x597487('0x8')]),db[_0x597487('0x29')][_0x597487('0x13')](_0x38f372)[_0x597487('0x14')](handleEntityNotFound(_0x381264,null))[_0x597487('0x14')](respondWithResult(_0x381264,null))[_0x597487('0x1b')](handleError(_0x381264,null));},exports[_0xd1db2d('0x2e')]=function(_0xbdfbe8,_0x26feae){const _0x56dc60=_0xd1db2d;return db[_0x56dc60('0x29')][_0x56dc60('0x2e')](_0xbdfbe8[_0x56dc60('0xe')],{})[_0x56dc60('0x14')](respondWithResult(_0x26feae,0xc9))[_0x56dc60('0x1b')](handleError(_0x26feae,null));},exports[_0xd1db2d('0x12')]=function(_0x8c419f,_0x3cfae9){const _0x699320=_0xd1db2d;return _0x8c419f[_0x699320('0xe')]['id']&&delete _0x8c419f[_0x699320('0xe')]['id'],db['ZohoField'][_0x699320('0x13')]({'where':{'id':_0x8c419f['params']['id']}})['then'](handleEntityNotFound(_0x3cfae9,null))['then'](saveUpdates(_0x8c419f[_0x699320('0xe')],null))[_0x699320('0x14')](respondWithResult(_0x3cfae9,null))[_0x699320('0x1b')](handleError(_0x3cfae9,null));},exports[_0xd1db2d('0x22')]=function(_0x345c,_0x34151a){const _0x37c69d=_0xd1db2d;return db['ZohoField'][_0x37c69d('0x13')]({'where':{'id':_0x345c[_0x37c69d('0x27')]['id']}})[_0x37c69d('0x14')](handleEntityNotFound(_0x34151a,null))[_0x37c69d('0x14')](removeEntity(_0x34151a,null))[_0x37c69d('0x1b')](handleError(_0x34151a,null));}; \ No newline at end of file diff --git a/server/api/intZohoField/intZohoField.model.js b/server/api/intZohoField/intZohoField.model.js index 7ffa046..1a7a58d 100644 --- a/server/api/intZohoField/intZohoField.model.js +++ b/server/api/intZohoField/intZohoField.model.js @@ -1 +1 @@ -const a356_0xff8f=['define','./intZohoField.attributes','zoho_unique_index','FieldId','int_zoho_fields','ZohoField'];(function(_0xc36b82,_0xff8f69){const _0x17a6e4=function(_0x2f1808){while(--_0x2f1808){_0xc36b82['push'](_0xc36b82['shift']());}};_0x17a6e4(++_0xff8f69);}(a356_0xff8f,0x12c));const a356_0x17a6=function(_0xc36b82,_0xff8f69){_0xc36b82=_0xc36b82-0x0;let _0x17a6e4=a356_0xff8f[_0xc36b82];return _0x17a6e4;};const _0xf47f4d=a356_0x17a6;'use strict';const attributes=require(_0xf47f4d('0x1'));module['exports']=function(_0x2f1808){const _0x22769c=_0xf47f4d,_0x3a6a87=_0x2f1808[_0x22769c('0x0')](_0x22769c('0x5'),attributes,{'tableName':_0x22769c('0x4'),'paranoid':![],'indexes':[{'name':_0x22769c('0x2'),'fields':['idField',_0x22769c('0x3')],'unique':!![]}],'timestamps':!![]});return _0x3a6a87;}; \ No newline at end of file +const a356_0x5def=['ZohoField','./intZohoField.attributes','int_zoho_fields','zoho_unique_index','idField'];(function(_0x42e0a8,_0x5defc2){const _0x523e5a=function(_0x24ccac){while(--_0x24ccac){_0x42e0a8['push'](_0x42e0a8['shift']());}};_0x523e5a(++_0x5defc2);}(a356_0x5def,0xe0));const a356_0x523e=function(_0x42e0a8,_0x5defc2){_0x42e0a8=_0x42e0a8-0x0;let _0x523e5a=a356_0x5def[_0x42e0a8];return _0x523e5a;};const _0x529ed0=a356_0x523e;'use strict';const attributes=require(_0x529ed0('0x2'));module['exports']=function(_0x24ccac){const _0x5bd048=_0x529ed0,_0x5e3895=_0x24ccac['define'](_0x5bd048('0x1'),attributes,{'tableName':_0x5bd048('0x3'),'paranoid':![],'indexes':[{'name':_0x5bd048('0x4'),'fields':[_0x5bd048('0x0'),'FieldId'],'unique':!![]}],'timestamps':!![]});return _0x5e3895;}; \ No newline at end of file diff --git a/server/api/integration/index.js b/server/api/integration/index.js index 712ad9d..3bb897e 100644 --- a/server/api/integration/index.js +++ b/server/api/integration/index.js @@ -1 +1 @@ -const a357_0x8af8=['Router','exports','express'];(function(_0x3aa711,_0x8af81c){const _0x301d92=function(_0x3fc935){while(--_0x3fc935){_0x3aa711['push'](_0x3aa711['shift']());}};_0x301d92(++_0x8af81c);}(a357_0x8af8,0x172));const a357_0x301d=function(_0x3aa711,_0x8af81c){_0x3aa711=_0x3aa711-0x0;let _0x301d92=a357_0x8af8[_0x3aa711];return _0x301d92;};const _0x3b3191=a357_0x301d;'use strict';const express=require(_0x3b3191('0x1')),router=express[_0x3b3191('0x2')]();module[_0x3b3191('0x0')]=router; \ No newline at end of file +const a357_0x529c=['exports','Router','express'];(function(_0x4ddda9,_0x529c28){const _0x270226=function(_0x268dc8){while(--_0x268dc8){_0x4ddda9['push'](_0x4ddda9['shift']());}};_0x270226(++_0x529c28);}(a357_0x529c,0xa8));const a357_0x2702=function(_0x4ddda9,_0x529c28){_0x4ddda9=_0x4ddda9-0x0;let _0x270226=a357_0x529c[_0x4ddda9];return _0x270226;};const _0x4fc5a4=a357_0x2702;'use strict';const express=require(_0x4fc5a4('0x2')),router=express[_0x4fc5a4('0x1')]();module[_0x4fc5a4('0x0')]=router; \ No newline at end of file diff --git a/server/api/integration/integration.attributes.js b/server/api/integration/integration.attributes.js index 4f56935..558ceb3 100644 --- a/server/api/integration/integration.attributes.js +++ b/server/api/integration/integration.attributes.js @@ -1 +1 @@ -const a358_0x24d3=['app.js','state','sequelize','exports','STRING','INTEGER','unique_name_and_version'];(function(_0x3c5d69,_0x24d35e){const _0x207e06=function(_0x337159){while(--_0x337159){_0x3c5d69['push'](_0x3c5d69['shift']());}};_0x207e06(++_0x24d35e);}(a358_0x24d3,0x1ea));const a358_0x207e=function(_0x3c5d69,_0x24d35e){_0x3c5d69=_0x3c5d69-0x0;let _0x207e06=a358_0x24d3[_0x3c5d69];return _0x207e06;};const _0x268b00=a358_0x207e;'use strict';const Sequelize=require(_0x268b00('0x2'));module[_0x268b00('0x3')]={'name':{'type':Sequelize[_0x268b00('0x4')],'allowNull':![],'unique':_0x268b00('0x6')},'version':{'type':Sequelize[_0x268b00('0x4')],'allowNull':![],'unique':_0x268b00('0x6')},'main':{'type':Sequelize[_0x268b00('0x4')],'defaultValue':_0x268b00('0x0')},'filename':{'type':Sequelize['STRING']},'path':{'type':Sequelize[_0x268b00('0x4')]},'type':{'type':Sequelize[_0x268b00('0x4')]},'size':{'type':Sequelize[_0x268b00('0x5')]},'active':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'author':{'type':Sequelize[_0x268b00('0x4')]},'logo':{'type':Sequelize[_0x268b00('0x4')]},'state':{'type':Sequelize[_0x268b00('0x4')],'unique':_0x268b00('0x1')},'description':{'type':Sequelize[_0x268b00('0x4')]},'title':{'type':Sequelize['STRING']},'remoteUri':{'type':Sequelize[_0x268b00('0x4')]},'link':{'type':Sequelize[_0x268b00('0x4')],'defaultValue':'#'}}; \ No newline at end of file +const a358_0x146b=['BOOLEAN','INTEGER','unique_name_and_version','sequelize','STRING'];(function(_0x5c04f8,_0x146ba8){const _0x272a9a=function(_0x148241){while(--_0x148241){_0x5c04f8['push'](_0x5c04f8['shift']());}};_0x272a9a(++_0x146ba8);}(a358_0x146b,0x139));const a358_0x272a=function(_0x5c04f8,_0x146ba8){_0x5c04f8=_0x5c04f8-0x0;let _0x272a9a=a358_0x146b[_0x5c04f8];return _0x272a9a;};const _0x57d3b6=a358_0x272a;'use strict';const Sequelize=require(_0x57d3b6('0x0'));module['exports']={'name':{'type':Sequelize[_0x57d3b6('0x1')],'allowNull':![],'unique':'unique_name_and_version'},'version':{'type':Sequelize[_0x57d3b6('0x1')],'allowNull':![],'unique':_0x57d3b6('0x4')},'main':{'type':Sequelize['STRING'],'defaultValue':'app.js'},'filename':{'type':Sequelize['STRING']},'path':{'type':Sequelize[_0x57d3b6('0x1')]},'type':{'type':Sequelize['STRING']},'size':{'type':Sequelize[_0x57d3b6('0x3')]},'active':{'type':Sequelize[_0x57d3b6('0x2')],'defaultValue':![]},'author':{'type':Sequelize[_0x57d3b6('0x1')]},'logo':{'type':Sequelize['STRING']},'state':{'type':Sequelize['STRING'],'unique':'state'},'description':{'type':Sequelize['STRING']},'title':{'type':Sequelize[_0x57d3b6('0x1')]},'remoteUri':{'type':Sequelize[_0x57d3b6('0x1')]},'link':{'type':Sequelize['STRING'],'defaultValue':'#'}}; \ No newline at end of file diff --git a/server/api/integration/integration.controller.js b/server/api/integration/integration.controller.js index d4363c8..d53a9c6 100644 --- a/server/api/integration/integration.controller.js +++ b/server/api/integration/integration.controller.js @@ -1 +1 @@ -const a359_0x2c8d=['rows','undefined','fieldName','create','like','set','api','VIRTUAL','attributes','length','lodash','model','key','update','catch','filter','destroy','error','count','keys','sort','params','include','sequelize','intersection','merge','map','offset','show','rawAttributes','Integration','options','index','name','query','body','nolimit','pick','send','filters','limit','includeAll','json','type','where','fields','then','status','../../components/parsers/qs'];(function(_0x2dba4c,_0x2c8d38){const _0x84c585=function(_0x308d32){while(--_0x308d32){_0x2dba4c['push'](_0x2dba4c['shift']());}};_0x84c585(++_0x2c8d38);}(a359_0x2c8d,0x1d3));const a359_0x84c5=function(_0x2dba4c,_0x2c8d38){_0x2dba4c=_0x2dba4c-0x0;let _0x84c585=a359_0x2c8d[_0x2dba4c];return _0x84c585;};const _0x175997=a359_0x84c5;'use strict';const _=require(_0x175997('0x21')),qs=require(_0x175997('0x16')),logger=require('../../config/logger')(_0x175997('0x1d')),db=require('../../mysqldb')['db'],{Op}=require(_0x175997('0x2e'));function respondWithResult(_0x308d32,_0x5a677b){return _0x5a677b=_0x5a677b||0xc8,function(_0x29eea8){const _0xf47b41=a359_0x84c5;if(_0x29eea8)return _0x308d32[_0xf47b41('0x15')](_0x5a677b)[_0xf47b41('0x10')](_0x29eea8);};}function respondWithFilteredResult(_0x176a8a,_0x2fb9e8){return function(_0x230f60){const _0x1d1a47=a359_0x84c5;if(_0x230f60){const _0x3377a6=_0x230f60[_0x1d1a47('0x29')],_0x878630=_0x2fb9e8[_0x1d1a47('0x1')];let _0x34ba27=_0x2fb9e8['offset']+_0x2fb9e8[_0x1d1a47('0xe')],_0xde2a04;return _0x34ba27>=_0x3377a6?(_0x34ba27=_0x3377a6,_0xde2a04=0xc8):_0xde2a04=0xce,_0x176a8a[_0x1d1a47('0x15')](_0xde2a04),_0x176a8a[_0x1d1a47('0x1c')]('Content-Range',_0x878630+'-'+_0x34ba27+'/'+_0x3377a6)[_0x1d1a47('0x10')](_0x230f60);}return null;};}function saveUpdates(_0xf6a518){return function(_0x5bed0a){const _0x5e364b=a359_0x84c5;if(_0x5bed0a)return _0x5bed0a[_0x5e364b('0x24')](_0xf6a518)[_0x5e364b('0x14')](function(_0x282e74){return _0x282e74;});return null;};}function removeEntity(_0x285a56){return function(_0x24eda4){if(_0x24eda4)return _0x24eda4['destroy']()['then'](function(){_0x285a56['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x289ab9){return function(_0x39c959){return!_0x39c959&&_0x289ab9['sendStatus'](0x194),_0x39c959;};}function handleError(_0x12b389,_0x3c2013){return _0x3c2013=_0x3c2013||0x1f4,function(_0x38cc5c){const _0x4e8d3d=a359_0x84c5;logger[_0x4e8d3d('0x28')](_0x38cc5c['stack']),_0x38cc5c[_0x4e8d3d('0x7')]&&delete _0x38cc5c[_0x4e8d3d('0x7')],_0x12b389['status'](_0x3c2013)[_0x4e8d3d('0xc')](_0x38cc5c);};}exports[_0x175997('0x6')]=function(_0xd6c06c,_0x4f06ee){const _0x352c91=_0x175997;let _0x34d8de={};const _0x2bde07={},_0x1f7b90={'count':0x0,'rows':[]},_0x501b1f=_[_0x352c91('0x0')](db['Integration']['rawAttributes'],function(_0x1ebb80){const _0x234e12=_0x352c91;return{'name':_0x1ebb80[_0x234e12('0x19')],'type':_0x1ebb80[_0x234e12('0x11')][_0x234e12('0x23')]};});_0x2bde07[_0x352c91('0x22')]=_[_0x352c91('0x0')](_0x501b1f,'name'),_0x2bde07[_0x352c91('0x8')]=_['keys'](_0xd6c06c[_0x352c91('0x8')]),_0x2bde07[_0x352c91('0xd')]=_['intersection'](_0x2bde07['model'],_0x2bde07[_0x352c91('0x8')]),_0x34d8de['attributes']=_['intersection'](_0x2bde07[_0x352c91('0x22')],qs[_0x352c91('0x13')](_0xd6c06c[_0x352c91('0x8')][_0x352c91('0x13')])),_0x34d8de[_0x352c91('0x1f')]=_0x34d8de[_0x352c91('0x1f')][_0x352c91('0x20')]?_0x34d8de[_0x352c91('0x1f')]:_0x2bde07[_0x352c91('0x22')];typeof _0xd6c06c[_0x352c91('0x8')][_0x352c91('0xa')]===_0x352c91('0x18')&&(_0x34d8de[_0x352c91('0xe')]=qs[_0x352c91('0xe')](_0xd6c06c[_0x352c91('0x8')][_0x352c91('0xe')]),_0x34d8de[_0x352c91('0x1')]=qs[_0x352c91('0x1')](_0xd6c06c[_0x352c91('0x8')][_0x352c91('0x1')]));_0x34d8de['order']=qs[_0x352c91('0x2b')](_0xd6c06c[_0x352c91('0x8')][_0x352c91('0x2b')]),_0x34d8de[_0x352c91('0x12')]=qs['filters'](_[_0x352c91('0xb')](_0xd6c06c[_0x352c91('0x8')],_0x2bde07[_0x352c91('0xd')]),_0x501b1f);_0xd6c06c[_0x352c91('0x8')][_0x352c91('0x26')]&&(_0x34d8de[_0x352c91('0x12')]=_[_0x352c91('0x30')](_0x34d8de['where'],{[Op['or']]:_[_0x352c91('0x0')](_0x501b1f,function(_0x355c4){const _0x4e306c=_0x352c91;if(_0x355c4[_0x4e306c('0x11')]!==_0x4e306c('0x1e')){const _0x54b3cc={};return _0x54b3cc[_0x355c4['name']]={[Op[_0x4e306c('0x1b')]]:'%'+_0xd6c06c[_0x4e306c('0x8')]['filter']+'%'},_0x54b3cc;}})}));_0x34d8de=_[_0x352c91('0x30')]({},_0x34d8de,_0xd6c06c[_0x352c91('0x5')]);const _0x438724={'where':_0x34d8de[_0x352c91('0x12')]};return db[_0x352c91('0x4')]['count'](_0x438724)[_0x352c91('0x14')](function(_0x3e217b){const _0x46b44e=_0x352c91;return _0x1f7b90['count']=_0x3e217b,_0xd6c06c['query'][_0x46b44e('0xf')]&&(_0x34d8de[_0x46b44e('0x2d')]=[{'all':!![]}]),db[_0x46b44e('0x4')]['findAll'](_0x34d8de);})[_0x352c91('0x14')](function(_0x10bbf9){const _0x45c489=_0x352c91;return _0x1f7b90[_0x45c489('0x17')]=_0x10bbf9,_0x1f7b90;})[_0x352c91('0x14')](respondWithFilteredResult(_0x4f06ee,_0x34d8de))[_0x352c91('0x25')](handleError(_0x4f06ee,null));},exports[_0x175997('0x2')]=function(_0xe1fe8f,_0x188e61){const _0x25500a=_0x175997;let _0x4c5a03={'raw':![],'where':{'id':_0xe1fe8f['params']['id']}};const _0x2765e3={};return _0x2765e3[_0x25500a('0x22')]=_[_0x25500a('0x2a')](db[_0x25500a('0x4')][_0x25500a('0x3')]),_0x2765e3[_0x25500a('0x8')]=_[_0x25500a('0x2a')](_0xe1fe8f[_0x25500a('0x8')]),_0x2765e3[_0x25500a('0xd')]=_[_0x25500a('0x2f')](_0x2765e3[_0x25500a('0x22')],_0x2765e3[_0x25500a('0x8')]),_0x4c5a03[_0x25500a('0x1f')]=_[_0x25500a('0x2f')](_0x2765e3[_0x25500a('0x22')],qs[_0x25500a('0x13')](_0xe1fe8f[_0x25500a('0x8')][_0x25500a('0x13')])),_0x4c5a03[_0x25500a('0x1f')]=_0x4c5a03[_0x25500a('0x1f')][_0x25500a('0x20')]?_0x4c5a03[_0x25500a('0x1f')]:_0x2765e3[_0x25500a('0x22')],_0xe1fe8f[_0x25500a('0x8')][_0x25500a('0xf')]&&(_0x4c5a03['include']=[{'all':!![]}]),_0x4c5a03=_['merge']({},_0x4c5a03,_0xe1fe8f[_0x25500a('0x5')]),db[_0x25500a('0x4')]['findOne'](_0x4c5a03)['then'](handleEntityNotFound(_0x188e61,null))[_0x25500a('0x14')](respondWithResult(_0x188e61,null))[_0x25500a('0x25')](handleError(_0x188e61,null));},exports[_0x175997('0x1a')]=function(_0x1f3a38,_0x2f442a){const _0x95a986=_0x175997;return db['Integration'][_0x95a986('0x1a')](_0x1f3a38[_0x95a986('0x9')],{})['then'](respondWithResult(_0x2f442a,0xc9))[_0x95a986('0x25')](handleError(_0x2f442a,null));},exports[_0x175997('0x24')]=function(_0x4d1b63,_0x2984b9){const _0x3dcb5d=_0x175997;return _0x4d1b63[_0x3dcb5d('0x9')]['id']&&delete _0x4d1b63[_0x3dcb5d('0x9')]['id'],db[_0x3dcb5d('0x4')]['findOne']({'where':{'id':_0x4d1b63[_0x3dcb5d('0x2c')]['id']}})[_0x3dcb5d('0x14')](handleEntityNotFound(_0x2984b9,null))['then'](saveUpdates(_0x4d1b63[_0x3dcb5d('0x9')],null))[_0x3dcb5d('0x14')](respondWithResult(_0x2984b9,null))[_0x3dcb5d('0x25')](handleError(_0x2984b9,null));},exports[_0x175997('0x27')]=function(_0x277294,_0x55aeb9){const _0x5574da=_0x175997;return db[_0x5574da('0x4')]['findOne']({'where':{'id':_0x277294[_0x5574da('0x2c')]['id']}})['then'](handleEntityNotFound(_0x55aeb9,null))[_0x5574da('0x14')](removeEntity(_0x55aeb9,null))['catch'](handleError(_0x55aeb9,null));}; \ No newline at end of file +const a359_0x8151=['set','undefined','params','query','where','offset','limit','pick','rows','nolimit','attributes','map','name','body','VIRTUAL','order','fields','lodash','include','index','json','../../mysqldb','filters','sequelize','findAll','then','intersection','merge','includeAll','filter','error','create','update','options','findOne','rawAttributes','count','fieldName','model','length','Integration','type','end','catch','keys','status','../../components/parsers/qs'];(function(_0xa96807,_0x8151a1){const _0x1bc8b9=function(_0x5dd057){while(--_0x5dd057){_0xa96807['push'](_0xa96807['shift']());}};_0x1bc8b9(++_0x8151a1);}(a359_0x8151,0x140));const a359_0x1bc8=function(_0xa96807,_0x8151a1){_0xa96807=_0xa96807-0x0;let _0x1bc8b9=a359_0x8151[_0xa96807];return _0x1bc8b9;};const _0x36076e=a359_0x1bc8;'use strict';const _=require(_0x36076e('0x1a')),qs=require(_0x36076e('0x8')),logger=require('../../config/logger')('api'),db=require(_0x36076e('0x1e'))['db'],{Op}=require(_0x36076e('0x20'));function respondWithResult(_0x5dd057,_0x288067){return _0x288067=_0x288067||0xc8,function(_0x5d66af){const _0xf98a2=a359_0x1bc8;if(_0x5d66af)return _0x5dd057['status'](_0x288067)[_0xf98a2('0x1d')](_0x5d66af);};}function respondWithFilteredResult(_0x1b9fb0,_0x2e0a77){return function(_0x2be77f){const _0xd90f34=a359_0x1bc8;if(_0x2be77f){const _0x51f855=_0x2be77f['count'],_0x266e06=_0x2e0a77[_0xd90f34('0xe')];let _0x530d0f=_0x2e0a77[_0xd90f34('0xe')]+_0x2e0a77[_0xd90f34('0xf')],_0x14bef4;return _0x530d0f>=_0x51f855?(_0x530d0f=_0x51f855,_0x14bef4=0xc8):_0x14bef4=0xce,_0x1b9fb0[_0xd90f34('0x7')](_0x14bef4),_0x1b9fb0[_0xd90f34('0x9')]('Content-Range',_0x266e06+'-'+_0x530d0f+'/'+_0x51f855)['json'](_0x2be77f);}return null;};}function saveUpdates(_0x1b2645){return function(_0x22393c){const _0x5dff97=a359_0x1bc8;if(_0x22393c)return _0x22393c[_0x5dff97('0x29')](_0x1b2645)[_0x5dff97('0x22')](function(_0x3d097e){return _0x3d097e;});return null;};}function removeEntity(_0x45b9ac){return function(_0x152b8d){if(_0x152b8d)return _0x152b8d['destroy']()['then'](function(){const _0x3a773b=a359_0x1bc8;_0x45b9ac[_0x3a773b('0x7')](0xcc)[_0x3a773b('0x4')]();});};}function handleEntityNotFound(_0x44b941){return function(_0x149489){return!_0x149489&&_0x44b941['sendStatus'](0x194),_0x149489;};}function handleError(_0x138936,_0x3d043a){return _0x3d043a=_0x3d043a||0x1f4,function(_0x276f4f){const _0x1a21d6=a359_0x1bc8;logger[_0x1a21d6('0x27')](_0x276f4f['stack']),_0x276f4f[_0x1a21d6('0x15')]&&delete _0x276f4f[_0x1a21d6('0x15')],_0x138936['status'](_0x3d043a)['send'](_0x276f4f);};}exports[_0x36076e('0x1c')]=function(_0x2d7718,_0x2f83eb){const _0x45f1d9=_0x36076e;let _0x4fa1b5={};const _0xc10597={},_0x1797ba={'count':0x0,'rows':[]},_0x18c53a=_[_0x45f1d9('0x14')](db[_0x45f1d9('0x2')][_0x45f1d9('0x2c')],function(_0x21c731){const _0xce5a1e=_0x45f1d9;return{'name':_0x21c731[_0xce5a1e('0x2e')],'type':_0x21c731[_0xce5a1e('0x3')]['key']};});_0xc10597[_0x45f1d9('0x0')]=_[_0x45f1d9('0x14')](_0x18c53a,'name'),_0xc10597['query']=_[_0x45f1d9('0x6')](_0x2d7718[_0x45f1d9('0xc')]),_0xc10597[_0x45f1d9('0x1f')]=_[_0x45f1d9('0x23')](_0xc10597[_0x45f1d9('0x0')],_0xc10597[_0x45f1d9('0xc')]),_0x4fa1b5['attributes']=_[_0x45f1d9('0x23')](_0xc10597[_0x45f1d9('0x0')],qs[_0x45f1d9('0x19')](_0x2d7718[_0x45f1d9('0xc')]['fields'])),_0x4fa1b5[_0x45f1d9('0x13')]=_0x4fa1b5['attributes'][_0x45f1d9('0x1')]?_0x4fa1b5[_0x45f1d9('0x13')]:_0xc10597[_0x45f1d9('0x0')];typeof _0x2d7718[_0x45f1d9('0xc')][_0x45f1d9('0x12')]===_0x45f1d9('0xa')&&(_0x4fa1b5[_0x45f1d9('0xf')]=qs[_0x45f1d9('0xf')](_0x2d7718[_0x45f1d9('0xc')]['limit']),_0x4fa1b5[_0x45f1d9('0xe')]=qs[_0x45f1d9('0xe')](_0x2d7718['query'][_0x45f1d9('0xe')]));_0x4fa1b5[_0x45f1d9('0x18')]=qs['sort'](_0x2d7718[_0x45f1d9('0xc')]['sort']),_0x4fa1b5[_0x45f1d9('0xd')]=qs[_0x45f1d9('0x1f')](_[_0x45f1d9('0x10')](_0x2d7718[_0x45f1d9('0xc')],_0xc10597[_0x45f1d9('0x1f')]),_0x18c53a);_0x2d7718['query'][_0x45f1d9('0x26')]&&(_0x4fa1b5['where']=_['merge'](_0x4fa1b5['where'],{[Op['or']]:_[_0x45f1d9('0x14')](_0x18c53a,function(_0x2739e8){const _0x2db7f3=_0x45f1d9;if(_0x2739e8[_0x2db7f3('0x3')]!==_0x2db7f3('0x17')){const _0xd0d68d={};return _0xd0d68d[_0x2739e8['name']]={[Op['like']]:'%'+_0x2d7718['query'][_0x2db7f3('0x26')]+'%'},_0xd0d68d;}})}));_0x4fa1b5=_[_0x45f1d9('0x24')]({},_0x4fa1b5,_0x2d7718[_0x45f1d9('0x2a')]);const _0x3c04bd={'where':_0x4fa1b5['where']};return db[_0x45f1d9('0x2')][_0x45f1d9('0x2d')](_0x3c04bd)[_0x45f1d9('0x22')](function(_0x3624ce){const _0x57cc27=_0x45f1d9;return _0x1797ba[_0x57cc27('0x2d')]=_0x3624ce,_0x2d7718[_0x57cc27('0xc')][_0x57cc27('0x25')]&&(_0x4fa1b5[_0x57cc27('0x1b')]=[{'all':!![]}]),db[_0x57cc27('0x2')][_0x57cc27('0x21')](_0x4fa1b5);})[_0x45f1d9('0x22')](function(_0x24b7cb){const _0x15fd73=_0x45f1d9;return _0x1797ba[_0x15fd73('0x11')]=_0x24b7cb,_0x1797ba;})['then'](respondWithFilteredResult(_0x2f83eb,_0x4fa1b5))[_0x45f1d9('0x5')](handleError(_0x2f83eb,null));},exports['show']=function(_0x332765,_0x23083d){const _0x8d1bbf=_0x36076e;let _0x33f475={'raw':![],'where':{'id':_0x332765[_0x8d1bbf('0xb')]['id']}};const _0x31869c={};return _0x31869c[_0x8d1bbf('0x0')]=_[_0x8d1bbf('0x6')](db[_0x8d1bbf('0x2')]['rawAttributes']),_0x31869c[_0x8d1bbf('0xc')]=_[_0x8d1bbf('0x6')](_0x332765[_0x8d1bbf('0xc')]),_0x31869c['filters']=_[_0x8d1bbf('0x23')](_0x31869c['model'],_0x31869c['query']),_0x33f475[_0x8d1bbf('0x13')]=_[_0x8d1bbf('0x23')](_0x31869c['model'],qs[_0x8d1bbf('0x19')](_0x332765[_0x8d1bbf('0xc')][_0x8d1bbf('0x19')])),_0x33f475[_0x8d1bbf('0x13')]=_0x33f475[_0x8d1bbf('0x13')]['length']?_0x33f475[_0x8d1bbf('0x13')]:_0x31869c[_0x8d1bbf('0x0')],_0x332765[_0x8d1bbf('0xc')]['includeAll']&&(_0x33f475[_0x8d1bbf('0x1b')]=[{'all':!![]}]),_0x33f475=_[_0x8d1bbf('0x24')]({},_0x33f475,_0x332765[_0x8d1bbf('0x2a')]),db['Integration'][_0x8d1bbf('0x2b')](_0x33f475)[_0x8d1bbf('0x22')](handleEntityNotFound(_0x23083d,null))[_0x8d1bbf('0x22')](respondWithResult(_0x23083d,null))[_0x8d1bbf('0x5')](handleError(_0x23083d,null));},exports[_0x36076e('0x28')]=function(_0x505e87,_0x1cdffb){const _0x4806ca=_0x36076e;return db[_0x4806ca('0x2')]['create'](_0x505e87[_0x4806ca('0x16')],{})[_0x4806ca('0x22')](respondWithResult(_0x1cdffb,0xc9))[_0x4806ca('0x5')](handleError(_0x1cdffb,null));},exports[_0x36076e('0x29')]=function(_0x46c5f4,_0x5c49c7){const _0x347cb0=_0x36076e;return _0x46c5f4[_0x347cb0('0x16')]['id']&&delete _0x46c5f4[_0x347cb0('0x16')]['id'],db['Integration'][_0x347cb0('0x2b')]({'where':{'id':_0x46c5f4['params']['id']}})['then'](handleEntityNotFound(_0x5c49c7,null))[_0x347cb0('0x22')](saveUpdates(_0x46c5f4['body'],null))[_0x347cb0('0x22')](respondWithResult(_0x5c49c7,null))[_0x347cb0('0x5')](handleError(_0x5c49c7,null));},exports['destroy']=function(_0xb70afe,_0x54e41d){const _0x79c33e=_0x36076e;return db[_0x79c33e('0x2')]['findOne']({'where':{'id':_0xb70afe[_0x79c33e('0xb')]['id']}})[_0x79c33e('0x22')](handleEntityNotFound(_0x54e41d,null))[_0x79c33e('0x22')](removeEntity(_0x54e41d,null))[_0x79c33e('0x5')](handleError(_0x54e41d,null));}; \ No newline at end of file diff --git a/server/api/integration/integration.model.js b/server/api/integration/integration.model.js index 0c27163..2fc2777 100644 --- a/server/api/integration/integration.model.js +++ b/server/api/integration/integration.model.js @@ -1 +1 @@ -const a360_0x2257=['./integration.attributes','define','Integration','exports','integrations'];(function(_0xd0c319,_0x22575b){const _0x235996=function(_0x19ef6c){while(--_0x19ef6c){_0xd0c319['push'](_0xd0c319['shift']());}};_0x235996(++_0x22575b);}(a360_0x2257,0xbe));const a360_0x2359=function(_0xd0c319,_0x22575b){_0xd0c319=_0xd0c319-0x0;let _0x235996=a360_0x2257[_0xd0c319];return _0x235996;};const _0x1b7d30=a360_0x2359;'use strict';const attributes=require(_0x1b7d30('0x0'));module[_0x1b7d30('0x3')]=function(_0x19ef6c){const _0x325b0f=_0x1b7d30,_0x436f58=_0x19ef6c[_0x325b0f('0x1')](_0x325b0f('0x2'),attributes,{'tableName':_0x325b0f('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x436f58;}; \ No newline at end of file +const a360_0x504c=['define','integrations','exports'];(function(_0x54453d,_0x504cef){const _0x156284=function(_0x281ef5){while(--_0x281ef5){_0x54453d['push'](_0x54453d['shift']());}};_0x156284(++_0x504cef);}(a360_0x504c,0x120));const a360_0x1562=function(_0x54453d,_0x504cef){_0x54453d=_0x54453d-0x0;let _0x156284=a360_0x504c[_0x54453d];return _0x156284;};const _0x25782e=a360_0x1562;'use strict';const attributes=require('./integration.attributes');module[_0x25782e('0x2')]=function(_0x281ef5){const _0x37aa58=_0x25782e,_0x4ac4f8=_0x281ef5[_0x37aa58('0x0')]('Integration',attributes,{'tableName':_0x37aa58('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x4ac4f8;}; \ No newline at end of file diff --git a/server/api/integrationReport/index.js b/server/api/integrationReport/index.js index c4f1925..2e529c3 100644 --- a/server/api/integrationReport/index.js +++ b/server/api/integrationReport/index.js @@ -1 +1 @@ -const a361_0x4142=['show','put','express','get','post','update','./integrationReport.controller','/describe','/:id','index','isAuthenticated','destroy','Router','delete','../../components/auth/service','exports','describe'];(function(_0x2cd8ba,_0x414229){const _0x56936b=function(_0x24ac19){while(--_0x24ac19){_0x2cd8ba['push'](_0x2cd8ba['shift']());}};_0x56936b(++_0x414229);}(a361_0x4142,0xce));const a361_0x5693=function(_0x2cd8ba,_0x414229){_0x2cd8ba=_0x2cd8ba-0x0;let _0x56936b=a361_0x4142[_0x2cd8ba];return _0x56936b;};const _0x4c7478=a361_0x5693;'use strict';const express=require(_0x4c7478('0x0')),router=express[_0x4c7478('0xa')](),auth=require(_0x4c7478('0xc')),controller=require(_0x4c7478('0x4'));router[_0x4c7478('0x1')]('/',auth['isAuthenticated'](),controller[_0x4c7478('0x7')]),router['get'](_0x4c7478('0x5'),auth[_0x4c7478('0x8')](),controller[_0x4c7478('0xe')]),router[_0x4c7478('0x1')]('/:id',auth[_0x4c7478('0x8')](),controller[_0x4c7478('0xf')]),router[_0x4c7478('0x2')]('/',auth[_0x4c7478('0x8')](),controller['create']),router[_0x4c7478('0x10')](_0x4c7478('0x6'),auth[_0x4c7478('0x8')](),controller[_0x4c7478('0x3')]),router[_0x4c7478('0xb')]('/:id',auth['isAuthenticated'](),controller[_0x4c7478('0x9')]),module[_0x4c7478('0xd')]=router; \ No newline at end of file +const a361_0x3166=['isAuthenticated','get','update','Router','destroy','/:id','../../components/auth/service','exports','/describe','create','describe','express','put','delete','post'];(function(_0x1df4a3,_0x3166c9){const _0x53b596=function(_0x1f709f){while(--_0x1f709f){_0x1df4a3['push'](_0x1df4a3['shift']());}};_0x53b596(++_0x3166c9);}(a361_0x3166,0x1d4));const a361_0x53b5=function(_0x1df4a3,_0x3166c9){_0x1df4a3=_0x1df4a3-0x0;let _0x53b596=a361_0x3166[_0x1df4a3];return _0x53b596;};const _0x3651e8=a361_0x53b5;'use strict';const express=require(_0x3651e8('0x8')),router=express[_0x3651e8('0x0')](),auth=require(_0x3651e8('0x3')),controller=require('./integrationReport.controller');router[_0x3651e8('0xd')]('/',auth[_0x3651e8('0xc')](),controller['index']),router[_0x3651e8('0xd')](_0x3651e8('0x5'),auth[_0x3651e8('0xc')](),controller[_0x3651e8('0x7')]),router[_0x3651e8('0xd')]('/:id',auth[_0x3651e8('0xc')](),controller['show']),router[_0x3651e8('0xb')]('/',auth[_0x3651e8('0xc')](),controller[_0x3651e8('0x6')]),router[_0x3651e8('0x9')](_0x3651e8('0x2'),auth[_0x3651e8('0xc')](),controller[_0x3651e8('0xe')]),router[_0x3651e8('0xa')](_0x3651e8('0x2'),auth[_0x3651e8('0xc')](),controller[_0x3651e8('0x1')]),module[_0x3651e8('0x4')]=router; \ No newline at end of file diff --git a/server/api/integrationReport/integrationReport.attributes.js b/server/api/integrationReport/integrationReport.attributes.js index 02c174e..faeb1c2 100644 --- a/server/api/integrationReport/integrationReport.attributes.js +++ b/server/api/integrationReport/integrationReport.attributes.js @@ -1 +1 @@ -const a362_0x52e2=['SENDING','FAILED','ENUM','DATE','STRING','TEXT','BOOLEAN','INTEGER'];(function(_0x3485a3,_0x52e231){const _0x19a045=function(_0x575b63){while(--_0x575b63){_0x3485a3['push'](_0x3485a3['shift']());}};_0x19a045(++_0x52e231);}(a362_0x52e2,0x7f));const a362_0x19a0=function(_0x3485a3,_0x52e231){_0x3485a3=_0x3485a3-0x0;let _0x19a045=a362_0x52e2[_0x3485a3];return _0x19a045;};const _0x1c7869=a362_0x19a0;'use strict';const Sequelize=require('sequelize');module['exports']={'integration':{'type':Sequelize[_0x1c7869('0x5')]},'eventChannel':{'type':Sequelize['STRING']},'exitStatus':{'type':Sequelize['STRING']},'ticketId':{'type':Sequelize['STRING']},'integrationId':{'type':Sequelize[_0x1c7869('0x0')]},'contacts':{'type':Sequelize[_0x1c7869('0x5')]},'uniqueid':{'type':Sequelize[_0x1c7869('0x5')]},'calleridnum':{'type':Sequelize[_0x1c7869('0x5')]},'calleridname':{'type':Sequelize[_0x1c7869('0x5')]},'queue':{'type':Sequelize[_0x1c7869('0x5')]},'interface':{'type':Sequelize[_0x1c7869('0x5')]},'membername':{'type':Sequelize[_0x1c7869('0x5')]},'agentcalledAt':{'type':Sequelize[_0x1c7869('0x4')]},'agentconnectAt':{'type':Sequelize[_0x1c7869('0x4')]},'holdtime':{'type':Sequelize[_0x1c7869('0x0')]},'agentcomplete':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'agentcompleteAt':{'type':Sequelize[_0x1c7869('0x4')]},'talktime':{'type':Sequelize[_0x1c7869('0x0')]},'agentacw':{'type':Sequelize[_0x1c7869('0x7')],'defaultValue':![]},'acwtime':{'type':Sequelize[_0x1c7869('0x0')]},'reason':{'type':Sequelize['STRING']},'agentringnoanswer':{'type':Sequelize[_0x1c7869('0x7')],'defaultValue':![]},'agentringnoanswerAt':{'type':Sequelize[_0x1c7869('0x4')]},'agentdump':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'agentdumpAt':{'type':Sequelize[_0x1c7869('0x4')]},'lastevent':{'type':Sequelize[_0x1c7869('0x5')]},'channel':{'type':Sequelize[_0x1c7869('0x5')]},'channelstate':{'type':Sequelize[_0x1c7869('0x0')]},'channelstatedesc':{'type':Sequelize['STRING']},'connectedlinenum':{'type':Sequelize[_0x1c7869('0x5')]},'connectedlinename':{'type':Sequelize[_0x1c7869('0x5')]},'language':{'type':Sequelize['STRING']},'accountcode':{'type':Sequelize['STRING']},'context':{'type':Sequelize[_0x1c7869('0x5')]},'exten':{'type':Sequelize[_0x1c7869('0x5')]},'priority':{'type':Sequelize[_0x1c7869('0x5')]},'destchannel':{'type':Sequelize[_0x1c7869('0x5')]},'destchannelstate':{'type':Sequelize[_0x1c7869('0x0')]},'destchannelstatedesc':{'type':Sequelize[_0x1c7869('0x5')]},'destcalleridnum':{'type':Sequelize[_0x1c7869('0x5')]},'destcalleridname':{'type':Sequelize[_0x1c7869('0x5')]},'destconnectedlinenum':{'type':Sequelize[_0x1c7869('0x5')]},'destconnectedlinename':{'type':Sequelize['STRING']},'destlanguage':{'type':Sequelize['STRING']},'destaccountcode':{'type':Sequelize[_0x1c7869('0x5')]},'destcontext':{'type':Sequelize[_0x1c7869('0x5')]},'destexten':{'type':Sequelize['STRING']},'destpriority':{'type':Sequelize[_0x1c7869('0x5')]},'destuniqueid':{'type':Sequelize['STRING']},'messageId':{'type':Sequelize[_0x1c7869('0x5')]},'inReplyTo':{'type':Sequelize[_0x1c7869('0x5')]},'subject':{'type':Sequelize['STRING']},'from':{'type':Sequelize[_0x1c7869('0x5')]},'to':{'type':Sequelize['STRING']},'cc':{'type':Sequelize['STRING']},'attachment':{'type':Sequelize[_0x1c7869('0x6')]},'html':{'type':Sequelize[_0x1c7869('0x6')]},'text':{'type':Sequelize['TEXT']},'status':{'type':Sequelize[_0x1c7869('0x3')]('SENT',_0x1c7869('0x1'),'RECEIVED',_0x1c7869('0x2'))},'url':{'type':Sequelize[_0x1c7869('0x5')]},'app':{'type':Sequelize[_0x1c7869('0x5')]},'appdata':{'type':Sequelize[_0x1c7869('0x5')]},'projectId':{'type':Sequelize[_0x1c7869('0x0')]}}; \ No newline at end of file +const a362_0x5d8a=['SENDING','RECEIVED','exports','SENT','INTEGER','FAILED','BOOLEAN','ENUM','TEXT','DATE','STRING'];(function(_0x30fa3e,_0x5d8a01){const _0x328de7=function(_0x4a9497){while(--_0x4a9497){_0x30fa3e['push'](_0x30fa3e['shift']());}};_0x328de7(++_0x5d8a01);}(a362_0x5d8a,0xce));const a362_0x328d=function(_0x30fa3e,_0x5d8a01){_0x30fa3e=_0x30fa3e-0x0;let _0x328de7=a362_0x5d8a[_0x30fa3e];return _0x328de7;};const _0x1c4047=a362_0x328d;'use strict';const Sequelize=require('sequelize');module[_0x1c4047('0x5')]={'integration':{'type':Sequelize['STRING']},'eventChannel':{'type':Sequelize[_0x1c4047('0x2')]},'exitStatus':{'type':Sequelize[_0x1c4047('0x2')]},'ticketId':{'type':Sequelize[_0x1c4047('0x2')]},'integrationId':{'type':Sequelize[_0x1c4047('0x7')]},'contacts':{'type':Sequelize[_0x1c4047('0x2')]},'uniqueid':{'type':Sequelize[_0x1c4047('0x2')]},'calleridnum':{'type':Sequelize[_0x1c4047('0x2')]},'calleridname':{'type':Sequelize[_0x1c4047('0x2')]},'queue':{'type':Sequelize[_0x1c4047('0x2')]},'interface':{'type':Sequelize[_0x1c4047('0x2')]},'membername':{'type':Sequelize[_0x1c4047('0x2')]},'agentcalledAt':{'type':Sequelize[_0x1c4047('0x1')]},'agentconnectAt':{'type':Sequelize[_0x1c4047('0x1')]},'holdtime':{'type':Sequelize[_0x1c4047('0x7')]},'agentcomplete':{'type':Sequelize[_0x1c4047('0x9')],'defaultValue':![]},'agentcompleteAt':{'type':Sequelize[_0x1c4047('0x1')]},'talktime':{'type':Sequelize[_0x1c4047('0x7')]},'agentacw':{'type':Sequelize[_0x1c4047('0x9')],'defaultValue':![]},'acwtime':{'type':Sequelize[_0x1c4047('0x7')]},'reason':{'type':Sequelize[_0x1c4047('0x2')]},'agentringnoanswer':{'type':Sequelize[_0x1c4047('0x9')],'defaultValue':![]},'agentringnoanswerAt':{'type':Sequelize[_0x1c4047('0x1')]},'agentdump':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'agentdumpAt':{'type':Sequelize['DATE']},'lastevent':{'type':Sequelize[_0x1c4047('0x2')]},'channel':{'type':Sequelize[_0x1c4047('0x2')]},'channelstate':{'type':Sequelize['INTEGER']},'channelstatedesc':{'type':Sequelize[_0x1c4047('0x2')]},'connectedlinenum':{'type':Sequelize[_0x1c4047('0x2')]},'connectedlinename':{'type':Sequelize[_0x1c4047('0x2')]},'language':{'type':Sequelize['STRING']},'accountcode':{'type':Sequelize[_0x1c4047('0x2')]},'context':{'type':Sequelize['STRING']},'exten':{'type':Sequelize[_0x1c4047('0x2')]},'priority':{'type':Sequelize['STRING']},'destchannel':{'type':Sequelize['STRING']},'destchannelstate':{'type':Sequelize[_0x1c4047('0x7')]},'destchannelstatedesc':{'type':Sequelize[_0x1c4047('0x2')]},'destcalleridnum':{'type':Sequelize[_0x1c4047('0x2')]},'destcalleridname':{'type':Sequelize[_0x1c4047('0x2')]},'destconnectedlinenum':{'type':Sequelize['STRING']},'destconnectedlinename':{'type':Sequelize[_0x1c4047('0x2')]},'destlanguage':{'type':Sequelize[_0x1c4047('0x2')]},'destaccountcode':{'type':Sequelize['STRING']},'destcontext':{'type':Sequelize[_0x1c4047('0x2')]},'destexten':{'type':Sequelize['STRING']},'destpriority':{'type':Sequelize['STRING']},'destuniqueid':{'type':Sequelize[_0x1c4047('0x2')]},'messageId':{'type':Sequelize[_0x1c4047('0x2')]},'inReplyTo':{'type':Sequelize[_0x1c4047('0x2')]},'subject':{'type':Sequelize['STRING']},'from':{'type':Sequelize[_0x1c4047('0x2')]},'to':{'type':Sequelize[_0x1c4047('0x2')]},'cc':{'type':Sequelize[_0x1c4047('0x2')]},'attachment':{'type':Sequelize[_0x1c4047('0x0')]},'html':{'type':Sequelize['TEXT']},'text':{'type':Sequelize[_0x1c4047('0x0')]},'status':{'type':Sequelize[_0x1c4047('0xa')](_0x1c4047('0x6'),_0x1c4047('0x3'),_0x1c4047('0x4'),_0x1c4047('0x8'))},'url':{'type':Sequelize[_0x1c4047('0x2')]},'app':{'type':Sequelize['STRING']},'appdata':{'type':Sequelize[_0x1c4047('0x2')]},'projectId':{'type':Sequelize[_0x1c4047('0x7')]}}; \ No newline at end of file diff --git a/server/api/integrationReport/integrationReport.controller.js b/server/api/integrationReport/integrationReport.controller.js index 7f34c5b..f2b0d45 100644 --- a/server/api/integrationReport/integrationReport.controller.js +++ b/server/api/integrationReport/integrationReport.controller.js @@ -1 +1 @@ -const a363_0x17b2=['destroy','type','then','sendStatus','rawAttributes','IntegrationReport','sequelize','show','attributes','stack','includeAll','model','filter','findOne','status','describe','merge','query','../../components/parsers/qs','update','params','map','where','end','lodash','name','error','nolimit','undefined','fields','keys','offset','create','Content-Range','intersection','catch','like','pick','options','include','index','body','filters','count','limit','fieldName','send','sort','length','json','rows'];(function(_0x3ab153,_0x17b218){const _0x25ce81=function(_0x1dc6d1){while(--_0x1dc6d1){_0x3ab153['push'](_0x3ab153['shift']());}};_0x25ce81(++_0x17b218);}(a363_0x17b2,0x1be));const a363_0x25ce=function(_0x3ab153,_0x17b218){_0x3ab153=_0x3ab153-0x0;let _0x25ce81=a363_0x17b2[_0x3ab153];return _0x25ce81;};const _0x583d01=a363_0x25ce;'use strict';const _=require(_0x583d01('0x25')),qs=require(_0x583d01('0x1f')),logger=require('../../config/logger')('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x583d01('0x13'));function respondWithResult(_0x1dc6d1,_0x3f682e){return _0x3f682e=_0x3f682e||0xc8,function(_0xa48040){const _0x50b710=a363_0x25ce;if(_0xa48040)return _0x1dc6d1['status'](_0x3f682e)[_0x50b710('0xb')](_0xa48040);};}function respondWithFilteredResult(_0x59ee1d,_0x3f4701){return function(_0x4ef052){const _0x46f8f0=a363_0x25ce;if(_0x4ef052){const _0x9eca31=_0x4ef052[_0x46f8f0('0x5')],_0x5bcf93=_0x3f4701[_0x46f8f0('0x2c')];let _0x43cfb8=_0x3f4701[_0x46f8f0('0x2c')]+_0x3f4701[_0x46f8f0('0x6')],_0x5381b9;return _0x43cfb8>=_0x9eca31?(_0x43cfb8=_0x9eca31,_0x5381b9=0xc8):_0x5381b9=0xce,_0x59ee1d[_0x46f8f0('0x1b')](_0x5381b9),_0x59ee1d['set'](_0x46f8f0('0x2e'),_0x5bcf93+'-'+_0x43cfb8+'/'+_0x9eca31)['json'](_0x4ef052);}return null;};}function saveUpdates(_0x3b5dc5){return function(_0x69d460){const _0x18f033=a363_0x25ce;if(_0x69d460)return _0x69d460[_0x18f033('0x20')](_0x3b5dc5)[_0x18f033('0xf')](function(_0x7dee2c){return _0x7dee2c;});return null;};}function removeEntity(_0xfa6f6f){return function(_0x2fe02b){const _0x4b22d1=a363_0x25ce;if(_0x2fe02b)return _0x2fe02b[_0x4b22d1('0xd')]()[_0x4b22d1('0xf')](function(){const _0x1d7fa9=_0x4b22d1;_0xfa6f6f['status'](0xcc)[_0x1d7fa9('0x24')]();});};}function handleEntityNotFound(_0x1bdc6c){return function(_0x50b75c){const _0x5dc4ba=a363_0x25ce;return!_0x50b75c&&_0x1bdc6c[_0x5dc4ba('0x10')](0x194),_0x50b75c;};}function handleError(_0x583602,_0x3e2fad){return _0x3e2fad=_0x3e2fad||0x1f4,function(_0x19b141){const _0x44da74=a363_0x25ce;logger[_0x44da74('0x27')](_0x19b141[_0x44da74('0x16')]),_0x19b141['name']&&delete _0x19b141[_0x44da74('0x26')],_0x583602['status'](_0x3e2fad)[_0x44da74('0x8')](_0x19b141);};}exports[_0x583d01('0x2')]=function(_0x3f1c4d,_0x52139d){const _0x344982=_0x583d01;let _0x182ac9={};const _0x7a6452={},_0x50c955={'count':0x0,'rows':[]},_0x1f87a8=_[_0x344982('0x22')](db['IntegrationReport']['rawAttributes'],function(_0xcedb28){const _0x72dc1c=_0x344982;return{'name':_0xcedb28[_0x72dc1c('0x7')],'type':_0xcedb28[_0x72dc1c('0xe')]['key']};});_0x7a6452[_0x344982('0x18')]=_[_0x344982('0x22')](_0x1f87a8,_0x344982('0x26')),_0x7a6452['query']=_['keys'](_0x3f1c4d['query']),_0x7a6452[_0x344982('0x4')]=_[_0x344982('0x2f')](_0x7a6452[_0x344982('0x18')],_0x7a6452[_0x344982('0x1e')]),_0x182ac9['attributes']=_[_0x344982('0x2f')](_0x7a6452[_0x344982('0x18')],qs[_0x344982('0x2a')](_0x3f1c4d['query'][_0x344982('0x2a')])),_0x182ac9['attributes']=_0x182ac9['attributes']['length']?_0x182ac9[_0x344982('0x15')]:_0x7a6452['model'];typeof _0x3f1c4d[_0x344982('0x1e')][_0x344982('0x28')]===_0x344982('0x29')&&(_0x182ac9[_0x344982('0x6')]=qs[_0x344982('0x6')](_0x3f1c4d['query'][_0x344982('0x6')]),_0x182ac9[_0x344982('0x2c')]=qs['offset'](_0x3f1c4d[_0x344982('0x1e')][_0x344982('0x2c')]));_0x182ac9['order']=qs[_0x344982('0x9')](_0x3f1c4d[_0x344982('0x1e')][_0x344982('0x9')]),_0x182ac9[_0x344982('0x23')]=qs['filters'](_[_0x344982('0x32')](_0x3f1c4d[_0x344982('0x1e')],_0x7a6452[_0x344982('0x4')]),_0x1f87a8);_0x3f1c4d['query'][_0x344982('0x19')]&&(_0x182ac9[_0x344982('0x23')]=_[_0x344982('0x1d')](_0x182ac9[_0x344982('0x23')],{[Op['or']]:_[_0x344982('0x22')](_0x1f87a8,function(_0x29f6ca){const _0x3f5738=_0x344982;if(_0x29f6ca[_0x3f5738('0xe')]!=='VIRTUAL'){const _0x3ffdc8={};return _0x3ffdc8[_0x29f6ca[_0x3f5738('0x26')]]={[Op[_0x3f5738('0x31')]]:'%'+_0x3f1c4d[_0x3f5738('0x1e')]['filter']+'%'},_0x3ffdc8;}})}));_0x182ac9=_[_0x344982('0x1d')]({},_0x182ac9,_0x3f1c4d[_0x344982('0x0')]);const _0x28a7f7={'where':_0x182ac9['where']};return db[_0x344982('0x12')][_0x344982('0x5')](_0x28a7f7)[_0x344982('0xf')](function(_0x527a86){const _0x2f4118=_0x344982;return _0x50c955[_0x2f4118('0x5')]=_0x527a86,_0x3f1c4d[_0x2f4118('0x1e')][_0x2f4118('0x17')]&&(_0x182ac9[_0x2f4118('0x1')]=[{'all':!![]}]),db[_0x2f4118('0x12')]['findAll'](_0x182ac9);})[_0x344982('0xf')](function(_0x4f6614){const _0xa93090=_0x344982;return _0x50c955[_0xa93090('0xc')]=_0x4f6614,_0x50c955;})[_0x344982('0xf')](respondWithFilteredResult(_0x52139d,_0x182ac9))[_0x344982('0x30')](handleError(_0x52139d,null));},exports[_0x583d01('0x14')]=function(_0x4d96eb,_0x2bf35c){const _0x550429=_0x583d01;let _0x36553f={'raw':![],'where':{'id':_0x4d96eb['params']['id']}};const _0x4e6f51={};return _0x4e6f51['model']=_[_0x550429('0x2b')](db[_0x550429('0x12')][_0x550429('0x11')]),_0x4e6f51['query']=_[_0x550429('0x2b')](_0x4d96eb[_0x550429('0x1e')]),_0x4e6f51[_0x550429('0x4')]=_[_0x550429('0x2f')](_0x4e6f51[_0x550429('0x18')],_0x4e6f51['query']),_0x36553f[_0x550429('0x15')]=_[_0x550429('0x2f')](_0x4e6f51[_0x550429('0x18')],qs[_0x550429('0x2a')](_0x4d96eb[_0x550429('0x1e')]['fields'])),_0x36553f[_0x550429('0x15')]=_0x36553f[_0x550429('0x15')][_0x550429('0xa')]?_0x36553f[_0x550429('0x15')]:_0x4e6f51[_0x550429('0x18')],_0x4d96eb[_0x550429('0x1e')]['includeAll']&&(_0x36553f[_0x550429('0x1')]=[{'all':!![]}]),_0x36553f=_[_0x550429('0x1d')]({},_0x36553f,_0x4d96eb[_0x550429('0x0')]),db[_0x550429('0x12')]['findOne'](_0x36553f)[_0x550429('0xf')](handleEntityNotFound(_0x2bf35c,null))[_0x550429('0xf')](respondWithResult(_0x2bf35c,null))[_0x550429('0x30')](handleError(_0x2bf35c,null));},exports[_0x583d01('0x2d')]=function(_0x5af74b,_0x2386bf){const _0x245847=_0x583d01;return db[_0x245847('0x12')][_0x245847('0x2d')](_0x5af74b[_0x245847('0x3')],{})[_0x245847('0xf')](respondWithResult(_0x2386bf,0xc9))[_0x245847('0x30')](handleError(_0x2386bf,null));},exports['update']=function(_0x4988e4,_0x4d7bc6){const _0x1c4f55=_0x583d01;return _0x4988e4[_0x1c4f55('0x3')]['id']&&delete _0x4988e4[_0x1c4f55('0x3')]['id'],db['IntegrationReport'][_0x1c4f55('0x1a')]({'where':{'id':_0x4988e4['params']['id']}})[_0x1c4f55('0xf')](handleEntityNotFound(_0x4d7bc6,null))[_0x1c4f55('0xf')](saveUpdates(_0x4988e4[_0x1c4f55('0x3')],null))[_0x1c4f55('0xf')](respondWithResult(_0x4d7bc6,null))['catch'](handleError(_0x4d7bc6,null));},exports[_0x583d01('0xd')]=function(_0x349c44,_0x1dfd6d){const _0x1a22c7=_0x583d01;return db[_0x1a22c7('0x12')]['findOne']({'where':{'id':_0x349c44[_0x1a22c7('0x21')]['id']}})[_0x1a22c7('0xf')](handleEntityNotFound(_0x1dfd6d,null))[_0x1a22c7('0xf')](removeEntity(_0x1dfd6d,null))[_0x1a22c7('0x30')](handleError(_0x1dfd6d,null));},exports['describe']=function(_0xee12a3,_0x2379da){const _0x264bde=_0x583d01;return db[_0x264bde('0x12')][_0x264bde('0x1c')]()['then'](respondWithResult(_0x2379da,null))[_0x264bde('0x30')](handleError(_0x2379da,null));}; \ No newline at end of file +const a363_0x28f4=['key','IntegrationReport','sendStatus','includeAll','map','params','count','merge','Content-Range','attributes','../../config/logger','then','error','filters','rows','set','filter','findAll','../../components/parsers/qs','query','json','update','status','lodash','name','create','undefined','catch','send','keys','like','limit','sort','show','where','describe','body','findOne','pick','VIRTUAL','fieldName','sequelize','options','type','order','length','destroy','model','rawAttributes','offset','intersection','fields','end'];(function(_0x3bbe6c,_0x28f450){const _0x33f582=function(_0x30e66e){while(--_0x30e66e){_0x3bbe6c['push'](_0x3bbe6c['shift']());}};_0x33f582(++_0x28f450);}(a363_0x28f4,0x1b4));const a363_0x33f5=function(_0x3bbe6c,_0x28f450){_0x3bbe6c=_0x3bbe6c-0x0;let _0x33f582=a363_0x28f4[_0x3bbe6c];return _0x33f582;};const _0x1764aa=a363_0x33f5;'use strict';const _=require(_0x1764aa('0xb')),qs=require(_0x1764aa('0x6')),logger=require(_0x1764aa('0x33'))('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x1764aa('0x1d'));function respondWithResult(_0x30e66e,_0x5bee09){return _0x5bee09=_0x5bee09||0xc8,function(_0x523c5b){const _0x461acb=a363_0x33f5;if(_0x523c5b)return _0x30e66e[_0x461acb('0xa')](_0x5bee09)[_0x461acb('0x8')](_0x523c5b);};}function respondWithFilteredResult(_0x42ac55,_0x493eba){return function(_0x670f17){const _0x34689a=a363_0x33f5;if(_0x670f17){const _0x36ed60=_0x670f17[_0x34689a('0x2f')],_0x2931c6=_0x493eba['offset'];let _0x5b2a60=_0x493eba[_0x34689a('0x25')]+_0x493eba[_0x34689a('0x13')],_0x52ab94;return _0x5b2a60>=_0x36ed60?(_0x5b2a60=_0x36ed60,_0x52ab94=0xc8):_0x52ab94=0xce,_0x42ac55[_0x34689a('0xa')](_0x52ab94),_0x42ac55[_0x34689a('0x3')](_0x34689a('0x31'),_0x2931c6+'-'+_0x5b2a60+'/'+_0x36ed60)[_0x34689a('0x8')](_0x670f17);}return null;};}function saveUpdates(_0x2c1c15){return function(_0x91e159){const _0xda3443=a363_0x33f5;if(_0x91e159)return _0x91e159['update'](_0x2c1c15)[_0xda3443('0x34')](function(_0x4be8d7){return _0x4be8d7;});return null;};}function removeEntity(_0x3a3a52){return function(_0x8d37b8){const _0x205195=a363_0x33f5;if(_0x8d37b8)return _0x8d37b8[_0x205195('0x22')]()[_0x205195('0x34')](function(){const _0x1a9f94=_0x205195;_0x3a3a52[_0x1a9f94('0xa')](0xcc)[_0x1a9f94('0x28')]();});};}function handleEntityNotFound(_0x10afad){return function(_0x3ab637){const _0x386f3f=a363_0x33f5;return!_0x3ab637&&_0x10afad[_0x386f3f('0x2b')](0x194),_0x3ab637;};}function handleError(_0x538e72,_0xfad22c){return _0xfad22c=_0xfad22c||0x1f4,function(_0x11e195){const _0x3432a6=a363_0x33f5;logger[_0x3432a6('0x0')](_0x11e195['stack']),_0x11e195[_0x3432a6('0xc')]&&delete _0x11e195['name'],_0x538e72[_0x3432a6('0xa')](_0xfad22c)[_0x3432a6('0x10')](_0x11e195);};}exports['index']=function(_0xe3dcca,_0x301806){const _0x518a5c=_0x1764aa;let _0xbcbf1c={};const _0x58ba70={},_0x439362={'count':0x0,'rows':[]},_0x59d0c=_[_0x518a5c('0x2d')](db[_0x518a5c('0x2a')][_0x518a5c('0x24')],function(_0x55ad82){const _0x307009=_0x518a5c;return{'name':_0x55ad82[_0x307009('0x1c')],'type':_0x55ad82['type'][_0x307009('0x29')]};});_0x58ba70[_0x518a5c('0x23')]=_[_0x518a5c('0x2d')](_0x59d0c,_0x518a5c('0xc')),_0x58ba70[_0x518a5c('0x7')]=_[_0x518a5c('0x11')](_0xe3dcca[_0x518a5c('0x7')]),_0x58ba70[_0x518a5c('0x1')]=_[_0x518a5c('0x26')](_0x58ba70[_0x518a5c('0x23')],_0x58ba70['query']),_0xbcbf1c[_0x518a5c('0x32')]=_['intersection'](_0x58ba70['model'],qs[_0x518a5c('0x27')](_0xe3dcca[_0x518a5c('0x7')][_0x518a5c('0x27')])),_0xbcbf1c['attributes']=_0xbcbf1c['attributes']['length']?_0xbcbf1c['attributes']:_0x58ba70[_0x518a5c('0x23')];typeof _0xe3dcca['query']['nolimit']===_0x518a5c('0xe')&&(_0xbcbf1c[_0x518a5c('0x13')]=qs[_0x518a5c('0x13')](_0xe3dcca[_0x518a5c('0x7')][_0x518a5c('0x13')]),_0xbcbf1c['offset']=qs[_0x518a5c('0x25')](_0xe3dcca[_0x518a5c('0x7')][_0x518a5c('0x25')]));_0xbcbf1c[_0x518a5c('0x20')]=qs['sort'](_0xe3dcca[_0x518a5c('0x7')][_0x518a5c('0x14')]),_0xbcbf1c['where']=qs['filters'](_[_0x518a5c('0x1a')](_0xe3dcca[_0x518a5c('0x7')],_0x58ba70[_0x518a5c('0x1')]),_0x59d0c);_0xe3dcca['query'][_0x518a5c('0x4')]&&(_0xbcbf1c['where']=_[_0x518a5c('0x30')](_0xbcbf1c[_0x518a5c('0x16')],{[Op['or']]:_[_0x518a5c('0x2d')](_0x59d0c,function(_0x2bb91f){const _0x5edc2e=_0x518a5c;if(_0x2bb91f[_0x5edc2e('0x1f')]!==_0x5edc2e('0x1b')){const _0x31d958={};return _0x31d958[_0x2bb91f['name']]={[Op[_0x5edc2e('0x12')]]:'%'+_0xe3dcca[_0x5edc2e('0x7')][_0x5edc2e('0x4')]+'%'},_0x31d958;}})}));_0xbcbf1c=_[_0x518a5c('0x30')]({},_0xbcbf1c,_0xe3dcca[_0x518a5c('0x1e')]);const _0x28a810={'where':_0xbcbf1c[_0x518a5c('0x16')]};return db[_0x518a5c('0x2a')][_0x518a5c('0x2f')](_0x28a810)[_0x518a5c('0x34')](function(_0x4cbf97){const _0x568383=_0x518a5c;return _0x439362['count']=_0x4cbf97,_0xe3dcca['query'][_0x568383('0x2c')]&&(_0xbcbf1c['include']=[{'all':!![]}]),db[_0x568383('0x2a')][_0x568383('0x5')](_0xbcbf1c);})[_0x518a5c('0x34')](function(_0x584274){const _0x5cdcc0=_0x518a5c;return _0x439362[_0x5cdcc0('0x2')]=_0x584274,_0x439362;})[_0x518a5c('0x34')](respondWithFilteredResult(_0x301806,_0xbcbf1c))['catch'](handleError(_0x301806,null));},exports[_0x1764aa('0x15')]=function(_0xc93dfe,_0x545194){const _0x65e39=_0x1764aa;let _0x5f0597={'raw':![],'where':{'id':_0xc93dfe[_0x65e39('0x2e')]['id']}};const _0x382d1e={};return _0x382d1e['model']=_['keys'](db[_0x65e39('0x2a')][_0x65e39('0x24')]),_0x382d1e['query']=_[_0x65e39('0x11')](_0xc93dfe[_0x65e39('0x7')]),_0x382d1e[_0x65e39('0x1')]=_[_0x65e39('0x26')](_0x382d1e['model'],_0x382d1e[_0x65e39('0x7')]),_0x5f0597[_0x65e39('0x32')]=_['intersection'](_0x382d1e['model'],qs['fields'](_0xc93dfe[_0x65e39('0x7')][_0x65e39('0x27')])),_0x5f0597[_0x65e39('0x32')]=_0x5f0597[_0x65e39('0x32')][_0x65e39('0x21')]?_0x5f0597[_0x65e39('0x32')]:_0x382d1e['model'],_0xc93dfe[_0x65e39('0x7')][_0x65e39('0x2c')]&&(_0x5f0597['include']=[{'all':!![]}]),_0x5f0597=_['merge']({},_0x5f0597,_0xc93dfe[_0x65e39('0x1e')]),db['IntegrationReport'][_0x65e39('0x19')](_0x5f0597)['then'](handleEntityNotFound(_0x545194,null))[_0x65e39('0x34')](respondWithResult(_0x545194,null))[_0x65e39('0xf')](handleError(_0x545194,null));},exports[_0x1764aa('0xd')]=function(_0x527585,_0x3e2f42){const _0x2bf289=_0x1764aa;return db[_0x2bf289('0x2a')]['create'](_0x527585[_0x2bf289('0x18')],{})[_0x2bf289('0x34')](respondWithResult(_0x3e2f42,0xc9))[_0x2bf289('0xf')](handleError(_0x3e2f42,null));},exports[_0x1764aa('0x9')]=function(_0x3d265a,_0x4d75f5){const _0x47f662=_0x1764aa;return _0x3d265a[_0x47f662('0x18')]['id']&&delete _0x3d265a[_0x47f662('0x18')]['id'],db[_0x47f662('0x2a')]['findOne']({'where':{'id':_0x3d265a['params']['id']}})[_0x47f662('0x34')](handleEntityNotFound(_0x4d75f5,null))[_0x47f662('0x34')](saveUpdates(_0x3d265a[_0x47f662('0x18')],null))[_0x47f662('0x34')](respondWithResult(_0x4d75f5,null))['catch'](handleError(_0x4d75f5,null));},exports[_0x1764aa('0x22')]=function(_0x19e958,_0x4261d8){const _0x483dda=_0x1764aa;return db[_0x483dda('0x2a')][_0x483dda('0x19')]({'where':{'id':_0x19e958[_0x483dda('0x2e')]['id']}})['then'](handleEntityNotFound(_0x4261d8,null))[_0x483dda('0x34')](removeEntity(_0x4261d8,null))[_0x483dda('0xf')](handleError(_0x4261d8,null));},exports[_0x1764aa('0x17')]=function(_0x15b508,_0x2c10c2){const _0x200433=_0x1764aa;return db['IntegrationReport'][_0x200433('0x17')]()[_0x200433('0x34')](respondWithResult(_0x2c10c2,null))[_0x200433('0xf')](handleError(_0x2c10c2,null));}; \ No newline at end of file diff --git a/server/api/integrationReport/integrationReport.model.js b/server/api/integrationReport/integrationReport.model.js index e356289..6ee3492 100644 --- a/server/api/integrationReport/integrationReport.model.js +++ b/server/api/integrationReport/integrationReport.model.js @@ -1 +1 @@ -const a364_0x16dd=['exports','./integrationReport.attributes','IntegrationReport','define','report_integration'];(function(_0x33a95c,_0x16dd7a){const _0x283af6=function(_0xeb45ec){while(--_0xeb45ec){_0x33a95c['push'](_0x33a95c['shift']());}};_0x283af6(++_0x16dd7a);}(a364_0x16dd,0xcd));const a364_0x283a=function(_0x33a95c,_0x16dd7a){_0x33a95c=_0x33a95c-0x0;let _0x283af6=a364_0x16dd[_0x33a95c];return _0x283af6;};const _0x2b520e=a364_0x283a;'use strict';const attributes=require(_0x2b520e('0x1'));module[_0x2b520e('0x0')]=function(_0xeb45ec){const _0x13e4d6=_0x2b520e,_0xac4a18=_0xeb45ec[_0x13e4d6('0x3')](_0x13e4d6('0x2'),attributes,{'tableName':_0x13e4d6('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xac4a18;}; \ No newline at end of file +const a364_0x47c3=['./integrationReport.attributes','report_integration','IntegrationReport','exports','define'];(function(_0x575faa,_0x47c356){const _0x149f9c=function(_0x566375){while(--_0x566375){_0x575faa['push'](_0x575faa['shift']());}};_0x149f9c(++_0x47c356);}(a364_0x47c3,0x1cd));const a364_0x149f=function(_0x575faa,_0x47c356){_0x575faa=_0x575faa-0x0;let _0x149f9c=a364_0x47c3[_0x575faa];return _0x149f9c;};const _0x73cfd2=a364_0x149f;'use strict';const attributes=require(_0x73cfd2('0x4'));module[_0x73cfd2('0x2')]=function(_0x566375){const _0x1439dd=_0x73cfd2,_0x95bbd5=_0x566375[_0x1439dd('0x3')](_0x1439dd('0x1'),attributes,{'tableName':_0x1439dd('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x95bbd5;}; \ No newline at end of file diff --git a/server/api/interval/index.js b/server/api/interval/index.js index 23d5f94..80b04e6 100644 --- a/server/api/interval/index.js +++ b/server/api/interval/index.js @@ -1 +1 @@ -const a365_0xf3ca=['destroy','show','isAuthenticated','/:id/sub_intervals','../../components/auth/service','delete','put','getIntervals','post','/:id','/:id/sub_intervals/create_many','index','create','./interval.controller','express','update','exports','get'];(function(_0x4e4824,_0xf3caaa){const _0x2b9524=function(_0x45b643){while(--_0x45b643){_0x4e4824['push'](_0x4e4824['shift']());}};_0x2b9524(++_0xf3caaa);}(a365_0xf3ca,0x1ae));const a365_0x2b95=function(_0x4e4824,_0xf3caaa){_0x4e4824=_0x4e4824-0x0;let _0x2b9524=a365_0xf3ca[_0x4e4824];return _0x2b9524;};const _0x592f96=a365_0x2b95;'use strict';const express=require(_0x592f96('0x10')),router=express['Router'](),auth=require(_0x592f96('0x6')),controller=require(_0x592f96('0xf'));router[_0x592f96('0x1')]('/',auth[_0x592f96('0x4')](),controller[_0x592f96('0xd')]),router[_0x592f96('0x1')]('/:id',auth['isAuthenticated'](),controller[_0x592f96('0x3')]),router['get'](_0x592f96('0x5'),auth[_0x592f96('0x4')](),controller[_0x592f96('0x9')]),router[_0x592f96('0xa')]('/',auth[_0x592f96('0x4')](),controller[_0x592f96('0xe')]),router['post'](_0x592f96('0x5'),auth[_0x592f96('0x4')](),controller['addInterval']),router['post'](_0x592f96('0xc'),auth['isAuthenticated'](),controller['addIntervals']),router[_0x592f96('0x8')](_0x592f96('0xb'),auth[_0x592f96('0x4')](),controller[_0x592f96('0x11')]),router[_0x592f96('0x7')](_0x592f96('0xb'),auth[_0x592f96('0x4')](),controller[_0x592f96('0x2')]),module[_0x592f96('0x0')]=router; \ No newline at end of file +const a365_0x49db=['getIntervals','destroy','put','isAuthenticated','delete','get','/:id','update','post','/:id/sub_intervals','./interval.controller','addIntervals','index','Router','/:id/sub_intervals/create_many'];(function(_0x432a66,_0x49db8c){const _0x4e9702=function(_0x4ef6aa){while(--_0x4ef6aa){_0x432a66['push'](_0x432a66['shift']());}};_0x4e9702(++_0x49db8c);}(a365_0x49db,0x10b));const a365_0x4e97=function(_0x432a66,_0x49db8c){_0x432a66=_0x432a66-0x0;let _0x4e9702=a365_0x49db[_0x432a66];return _0x4e9702;};const _0x351378=a365_0x4e97;'use strict';const express=require('express'),router=express[_0x351378('0x1')](),auth=require('../../components/auth/service'),controller=require(_0x351378('0xd'));router[_0x351378('0x8')]('/',auth[_0x351378('0x6')](),controller[_0x351378('0x0')]),router[_0x351378('0x8')](_0x351378('0x9'),auth['isAuthenticated'](),controller['show']),router[_0x351378('0x8')](_0x351378('0xc'),auth[_0x351378('0x6')](),controller[_0x351378('0x3')]),router['post']('/',auth['isAuthenticated'](),controller['create']),router[_0x351378('0xb')](_0x351378('0xc'),auth['isAuthenticated'](),controller['addInterval']),router[_0x351378('0xb')](_0x351378('0x2'),auth[_0x351378('0x6')](),controller[_0x351378('0xe')]),router[_0x351378('0x5')](_0x351378('0x9'),auth[_0x351378('0x6')](),controller[_0x351378('0xa')]),router[_0x351378('0x7')](_0x351378('0x9'),auth[_0x351378('0x6')](),controller[_0x351378('0x4')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/interval/interval.attributes.js b/server/api/interval/interval.attributes.js index 7e7c8e5..909ab0b 100644 --- a/server/api/interval/interval.attributes.js +++ b/server/api/interval/interval.attributes.js @@ -1 +1 @@ -const a366_0x3fc1=['sequelize','exports','STRING'];(function(_0x5a4256,_0x3fc1eb){const _0x1aba59=function(_0x37719e){while(--_0x37719e){_0x5a4256['push'](_0x5a4256['shift']());}};_0x1aba59(++_0x3fc1eb);}(a366_0x3fc1,0xd1));const a366_0x1aba=function(_0x5a4256,_0x3fc1eb){_0x5a4256=_0x5a4256-0x0;let _0x1aba59=a366_0x3fc1[_0x5a4256];return _0x1aba59;};const _0x5dfcdd=a366_0x1aba;'use strict';const Sequelize=require(_0x5dfcdd('0x1'));module[_0x5dfcdd('0x2')]={'name':{'type':Sequelize[_0x5dfcdd('0x0')]},'description':{'type':Sequelize[_0x5dfcdd('0x0')]},'interval':{'type':Sequelize[_0x5dfcdd('0x0')],'allowNull':!![]}}; \ No newline at end of file +const a366_0x160d=['exports','STRING','sequelize'];(function(_0x511c61,_0x160d99){const _0x151c75=function(_0x9d299d){while(--_0x9d299d){_0x511c61['push'](_0x511c61['shift']());}};_0x151c75(++_0x160d99);}(a366_0x160d,0x186));const a366_0x151c=function(_0x511c61,_0x160d99){_0x511c61=_0x511c61-0x0;let _0x151c75=a366_0x160d[_0x511c61];return _0x151c75;};const _0x75fead=a366_0x151c;'use strict';const Sequelize=require(_0x75fead('0x2'));module[_0x75fead('0x0')]={'name':{'type':Sequelize[_0x75fead('0x1')]},'description':{'type':Sequelize[_0x75fead('0x1')]},'interval':{'type':Sequelize[_0x75fead('0x1')],'allowNull':!![]}}; \ No newline at end of file diff --git a/server/api/interval/interval.controller.js b/server/api/interval/interval.controller.js index 395f96a..41cabdc 100644 --- a/server/api/interval/interval.controller.js +++ b/server/api/interval/interval.controller.js @@ -1 +1 @@ -const a367_0x1824=['sequelize','userProfileId','rawAttributes','VIRTUAL','filter','map','options','Content-Range','filters','body','get','keys','rows','getIntervals','then','user','fields','order','../../config/logger','send','show','attributes','findOne','status','pick','api','json','merge','../../components/parsers/qs','index','type','IntervalId','create','update','model','count','bulkCreate','addIntervals','query','end','sendStatus','transaction','Unable\x20to\x20retrieve\x20the\x20current\x20user','UserProfileResource','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','Intervals','key','include','params','destroy','sort','like','offset','Interval','where','limit','catch','intersection','fieldName','undefined','nolimit','../../mysqldb','name','findAll','length','lodash','error'];(function(_0x29a1ad,_0x1824c4){const _0x1cdcfa=function(_0x396e7e){while(--_0x396e7e){_0x29a1ad['push'](_0x29a1ad['shift']());}};_0x1cdcfa(++_0x1824c4);}(a367_0x1824,0x1e5));const a367_0x1cdc=function(_0x29a1ad,_0x1824c4){_0x29a1ad=_0x29a1ad-0x0;let _0x1cdcfa=a367_0x1824[_0x29a1ad];return _0x1cdcfa;};const _0x16533b=a367_0x1cdc;'use strict';const _=require(_0x16533b('0x31')),qs=require(_0x16533b('0xc')),logger=require(_0x16533b('0x2'))(_0x16533b('0x9')),db=require(_0x16533b('0x2d'))['db'],{Op}=require(_0x16533b('0x33'));function respondWithResult(_0x396e7e,_0xe62f1c){return _0xe62f1c=_0xe62f1c||0xc8,function(_0x48d7b9){const _0x524f35=a367_0x1cdc;if(_0x48d7b9)return _0x396e7e[_0x524f35('0x7')](_0xe62f1c)[_0x524f35('0xa')](_0x48d7b9);};}function respondWithFilteredResult(_0x99ce1e,_0x4d0d1c){return function(_0x10af18){const _0x379154=a367_0x1cdc;if(_0x10af18){const _0x2f60d2=_0x10af18['count'],_0x346331=_0x4d0d1c['offset'];let _0x394f0f=_0x4d0d1c[_0x379154('0x24')]+_0x4d0d1c['limit'],_0x4df6bd;return _0x394f0f>=_0x2f60d2?(_0x394f0f=_0x2f60d2,_0x4df6bd=0xc8):_0x4df6bd=0xce,_0x99ce1e[_0x379154('0x7')](_0x4df6bd),_0x99ce1e['set'](_0x379154('0x3a'),_0x346331+'-'+_0x394f0f+'/'+_0x2f60d2)[_0x379154('0xa')](_0x10af18);}return null;};}function saveUpdates(_0x37781a){return function(_0x29b3c1){const _0x47eb41=a367_0x1cdc;if(_0x29b3c1)return _0x29b3c1[_0x47eb41('0x11')](_0x37781a)[_0x47eb41('0x41')](function(_0x4f0fad){return _0x4f0fad;});return null;};}function removeEntity(_0xd63047){return function(_0xf5554b){const _0x1b79b7=a367_0x1cdc;if(_0xf5554b)return _0xf5554b[_0x1b79b7('0x21')]()[_0x1b79b7('0x41')](function(){const _0x597c75=_0x1b79b7,_0x49973b=_0xf5554b['get']({'plain':!![]}),_0x275fd1=_0x597c75('0x1d');return db[_0x597c75('0x1b')][_0x597c75('0x21')]({'where':{'type':_0x275fd1,'resourceId':_0x49973b['id']}})['then'](function(){return _0xf5554b;});})[_0x1b79b7('0x41')](function(){const _0x4a8ae4=_0x1b79b7;_0xd63047[_0x4a8ae4('0x7')](0xcc)[_0x4a8ae4('0x17')]();});};}function handleEntityNotFound(_0xbb2fa){return function(_0x5b84f0){const _0x4a9105=a367_0x1cdc;return!_0x5b84f0&&_0xbb2fa[_0x4a9105('0x18')](0x194),_0x5b84f0;};}function handleError(_0x1d8301,_0x339b68){return _0x339b68=_0x339b68||0x1f4,function(_0x1db2fa){const _0x5bfd99=a367_0x1cdc;logger['error'](_0x1db2fa['stack']),_0x1db2fa[_0x5bfd99('0x2e')]&&delete _0x1db2fa[_0x5bfd99('0x2e')],_0x1d8301[_0x5bfd99('0x7')](_0x339b68)[_0x5bfd99('0x3')](_0x1db2fa);};}exports[_0x16533b('0xd')]=function(_0x152fbb,_0x481f11){const _0x5bdfeb=_0x16533b;let _0x1b1b36={};const _0x1c4aca={},_0x2b6d47={'count':0x0,'rows':[]},_0x444bf8=_[_0x5bdfeb('0x38')](db[_0x5bdfeb('0x25')][_0x5bdfeb('0x35')],function(_0x1b1244){const _0x3afef5=_0x5bdfeb;return{'name':_0x1b1244[_0x3afef5('0x2a')],'type':_0x1b1244[_0x3afef5('0xe')][_0x3afef5('0x1e')]};});_0x1c4aca[_0x5bdfeb('0x12')]=_[_0x5bdfeb('0x38')](_0x444bf8,_0x5bdfeb('0x2e')),_0x1c4aca[_0x5bdfeb('0x16')]=_['keys'](_0x152fbb[_0x5bdfeb('0x16')]),_0x1c4aca[_0x5bdfeb('0x3b')]=_['intersection'](_0x1c4aca['model'],_0x1c4aca[_0x5bdfeb('0x16')]),_0x1b1b36['attributes']=_['intersection'](_0x1c4aca[_0x5bdfeb('0x12')],qs[_0x5bdfeb('0x0')](_0x152fbb['query'][_0x5bdfeb('0x0')])),_0x1b1b36[_0x5bdfeb('0x5')]=_0x1b1b36[_0x5bdfeb('0x5')][_0x5bdfeb('0x30')]?_0x1b1b36['attributes']:_0x1c4aca[_0x5bdfeb('0x12')];typeof _0x152fbb['query'][_0x5bdfeb('0x2c')]===_0x5bdfeb('0x2b')&&(_0x1b1b36[_0x5bdfeb('0x27')]=qs[_0x5bdfeb('0x27')](_0x152fbb[_0x5bdfeb('0x16')][_0x5bdfeb('0x27')]),_0x1b1b36[_0x5bdfeb('0x24')]=qs[_0x5bdfeb('0x24')](_0x152fbb[_0x5bdfeb('0x16')]['offset']));_0x1b1b36[_0x5bdfeb('0x1')]=qs[_0x5bdfeb('0x22')](_0x152fbb[_0x5bdfeb('0x16')][_0x5bdfeb('0x22')]),_0x1b1b36['where']=qs[_0x5bdfeb('0x3b')](_[_0x5bdfeb('0x8')](_0x152fbb[_0x5bdfeb('0x16')],_0x1c4aca[_0x5bdfeb('0x3b')]),_0x444bf8);_0x152fbb[_0x5bdfeb('0x16')][_0x5bdfeb('0x37')]&&(_0x1b1b36[_0x5bdfeb('0x26')]=_[_0x5bdfeb('0xb')](_0x1b1b36[_0x5bdfeb('0x26')],{[Op['or']]:_['map'](_0x444bf8,function(_0x56a868){const _0x3b0f7f=_0x5bdfeb;if(_0x56a868[_0x3b0f7f('0xe')]!==_0x3b0f7f('0x36')){const _0x1c1081={};return _0x1c1081[_0x56a868[_0x3b0f7f('0x2e')]]={[Op['like']]:'%'+_0x152fbb['query'][_0x3b0f7f('0x37')]+'%'},_0x1c1081;}})}));_0x1b1b36=_[_0x5bdfeb('0xb')]({},_0x1b1b36,_0x152fbb[_0x5bdfeb('0x39')]);const _0x3196a7={'where':_0x1b1b36[_0x5bdfeb('0x26')]};return db[_0x5bdfeb('0x25')][_0x5bdfeb('0x13')](_0x3196a7)[_0x5bdfeb('0x41')](function(_0x5d04d3){const _0x39b918=_0x5bdfeb;return _0x2b6d47[_0x39b918('0x13')]=_0x5d04d3,_0x152fbb[_0x39b918('0x16')]['includeAll']&&(_0x1b1b36[_0x39b918('0x1f')]=[{'all':!![]}]),db[_0x39b918('0x25')][_0x39b918('0x2f')](_0x1b1b36);})[_0x5bdfeb('0x41')](function(_0x1298a4){const _0x5a43fd=_0x5bdfeb;return _0x2b6d47[_0x5a43fd('0x3f')]=_0x1298a4,_0x2b6d47;})[_0x5bdfeb('0x41')](respondWithFilteredResult(_0x481f11,_0x1b1b36))[_0x5bdfeb('0x28')](handleError(_0x481f11,null));},exports[_0x16533b('0x4')]=function(_0x3527d9,_0x48e57e){const _0x5ae938=_0x16533b;let _0x58129a={'raw':!![],'where':{'id':_0x3527d9[_0x5ae938('0x20')]['id']}};const _0x7c63d5={};return _0x7c63d5[_0x5ae938('0x12')]=_[_0x5ae938('0x3e')](db[_0x5ae938('0x25')][_0x5ae938('0x35')]),_0x7c63d5[_0x5ae938('0x16')]=_[_0x5ae938('0x3e')](_0x3527d9['query']),_0x7c63d5['filters']=_[_0x5ae938('0x29')](_0x7c63d5['model'],_0x7c63d5[_0x5ae938('0x16')]),_0x58129a[_0x5ae938('0x5')]=_[_0x5ae938('0x29')](_0x7c63d5[_0x5ae938('0x12')],qs['fields'](_0x3527d9[_0x5ae938('0x16')][_0x5ae938('0x0')])),_0x58129a[_0x5ae938('0x5')]=_0x58129a[_0x5ae938('0x5')][_0x5ae938('0x30')]?_0x58129a[_0x5ae938('0x5')]:_0x7c63d5['model'],_0x3527d9[_0x5ae938('0x16')]['includeAll']&&(_0x58129a[_0x5ae938('0x1f')]=[{'all':!![]}]),_0x58129a=_['merge']({},_0x58129a,_0x3527d9[_0x5ae938('0x39')]),db[_0x5ae938('0x25')][_0x5ae938('0x6')](_0x58129a)[_0x5ae938('0x41')](handleEntityNotFound(_0x48e57e,null))[_0x5ae938('0x41')](respondWithResult(_0x48e57e,null))['catch'](handleError(_0x48e57e,null));},exports[_0x16533b('0x10')]=function(_0xc48d2e,_0xc64a6a){const _0x2cde89=_0x16533b;return db[_0x2cde89('0x25')]['create'](_0xc48d2e[_0x2cde89('0x3c')],{})['then'](function(_0x58a9af){const _0x13c3e6=_0x2cde89,_0x15c864=_0xc48d2e[_0x13c3e6('0x42')][_0x13c3e6('0x3d')]({'plain':!![]});if(!_0x15c864)throw new Error(_0x13c3e6('0x1a'));if(_0x15c864['role']===_0x13c3e6('0x42')){const _0x906ed1=_0x58a9af[_0x13c3e6('0x3d')]({'plain':!![]}),_0x438b4d='Intervals';return db['UserProfileSection'][_0x13c3e6('0x6')]({'where':{'name':_0x438b4d,'userProfileId':_0x15c864[_0x13c3e6('0x34')]},'raw':!![]})[_0x13c3e6('0x41')](function(_0x73e609){const _0x988730=_0x13c3e6;return _0x73e609&&_0x73e609['autoAssociation']===0x0?db['UserProfileResource'][_0x988730('0x10')]({'name':_0x906ed1[_0x988730('0x2e')],'resourceId':_0x906ed1['id'],'type':_0x73e609['name'],'sectionId':_0x73e609['id']},{})[_0x988730('0x41')](function(){return _0x58a9af;}):_0x58a9af;})['catch'](function(_0x477c13){const _0x252e9e=_0x13c3e6;logger[_0x252e9e('0x32')](_0x252e9e('0x1c'),_0x477c13);throw _0x477c13;});}return _0x58a9af;})[_0x2cde89('0x41')](respondWithResult(_0xc64a6a,0xc9))[_0x2cde89('0x28')](handleError(_0xc64a6a,null));},exports[_0x16533b('0x11')]=function(_0x237adb,_0x43441d){const _0x1c0de1=_0x16533b;return _0x237adb[_0x1c0de1('0x3c')]['id']&&delete _0x237adb[_0x1c0de1('0x3c')]['id'],db['Interval']['findOne']({'where':{'id':_0x237adb['params']['id']}})[_0x1c0de1('0x41')](handleEntityNotFound(_0x43441d,null))['then'](saveUpdates(_0x237adb[_0x1c0de1('0x3c')],null))[_0x1c0de1('0x41')](respondWithResult(_0x43441d,null))[_0x1c0de1('0x28')](handleError(_0x43441d,null));},exports[_0x16533b('0x21')]=function(_0x1ea71c,_0x48f232){const _0x1a49f0=_0x16533b;return db['Interval']['findOne']({'where':{'id':_0x1ea71c[_0x1a49f0('0x20')]['id']}})[_0x1a49f0('0x41')](handleEntityNotFound(_0x48f232,null))[_0x1a49f0('0x41')](removeEntity(_0x48f232,null))[_0x1a49f0('0x28')](handleError(_0x48f232,null));},exports['addInterval']=function(_0x1351e3,_0x257dfa){const _0x37dfe5=_0x16533b;return _0x1351e3[_0x37dfe5('0x3c')]['id']&&delete _0x1351e3[_0x37dfe5('0x3c')]['id'],db[_0x37dfe5('0x25')][_0x37dfe5('0x6')]({'where':{'id':_0x1351e3[_0x37dfe5('0x20')]['id']}})[_0x37dfe5('0x41')](handleEntityNotFound(_0x257dfa,null))[_0x37dfe5('0x41')](function(_0x43f848){const _0x1dac0c=_0x37dfe5;if(_0x43f848)return _0x1351e3['body']['IntervalId']=_0x43f848['id'],db['Interval'][_0x1dac0c('0x10')](_0x1351e3[_0x1dac0c('0x3c')]);})[_0x37dfe5('0x41')](respondWithResult(_0x257dfa,null))[_0x37dfe5('0x28')](handleError(_0x257dfa,null));},exports[_0x16533b('0x40')]=function(_0x80d00c,_0x15fc82){const _0x31cf19=_0x16533b;let _0x15d6fc={};const _0x421edd={};let _0x4c6758,_0x3dcc85;return db[_0x31cf19('0x25')][_0x31cf19('0x6')]({'where':{'id':_0x80d00c[_0x31cf19('0x20')]['id']}})[_0x31cf19('0x41')](handleEntityNotFound(_0x15fc82,null))[_0x31cf19('0x41')](function(_0xbbf48c){const _0x8060b9=_0x31cf19;if(_0xbbf48c)return _0x4c6758=_0xbbf48c,_0x421edd['model']=_[_0x8060b9('0x3e')](db[_0x8060b9('0x25')]['rawAttributes']),_0x421edd[_0x8060b9('0x16')]=_[_0x8060b9('0x3e')](_0x80d00c[_0x8060b9('0x16')]),_0x421edd['filters']=_[_0x8060b9('0x29')](_0x421edd[_0x8060b9('0x12')],_0x421edd['query']),_0x15d6fc[_0x8060b9('0x5')]=_['intersection'](_0x421edd[_0x8060b9('0x12')],qs[_0x8060b9('0x0')](_0x80d00c['query'][_0x8060b9('0x0')])),_0x15d6fc['attributes']=_0x15d6fc[_0x8060b9('0x5')]['length']?_0x15d6fc[_0x8060b9('0x5')]:_0x421edd['model'],_0x15d6fc[_0x8060b9('0x1')]=qs[_0x8060b9('0x22')](_0x80d00c[_0x8060b9('0x16')]['sort']),_0x15d6fc['where']=qs[_0x8060b9('0x3b')](_[_0x8060b9('0x8')](_0x80d00c['query'],_0x421edd[_0x8060b9('0x3b')])),_0x80d00c['query'][_0x8060b9('0x37')]&&(_0x15d6fc[_0x8060b9('0x26')]=_[_0x8060b9('0xb')](_0x15d6fc[_0x8060b9('0x26')],{[Op['or']]:_[_0x8060b9('0x38')](_0x15d6fc['attributes'],function(_0x301b55){const _0x34bf=_0x8060b9,_0x23331e={};return _0x23331e[_0x301b55]={[Op[_0x34bf('0x23')]]:'%'+_0x80d00c[_0x34bf('0x16')]['filter']+'%'},_0x23331e;})})),_0x15d6fc=_[_0x8060b9('0xb')]({},_0x15d6fc,_0x80d00c['options']),_0x4c6758['getIntervals'](_0x15d6fc);})[_0x31cf19('0x41')](function(_0x135429){const _0x11f7a0=_0x31cf19;if(_0x135429)return _0x3dcc85=_0x135429[_0x11f7a0('0x30')],typeof _0x80d00c[_0x11f7a0('0x16')][_0x11f7a0('0x2c')]===_0x11f7a0('0x2b')&&(_0x15d6fc[_0x11f7a0('0x27')]=qs['limit'](_0x80d00c[_0x11f7a0('0x16')]['limit']),_0x15d6fc['offset']=qs[_0x11f7a0('0x24')](_0x80d00c[_0x11f7a0('0x16')]['offset'])),_0x4c6758[_0x11f7a0('0x40')](_0x15d6fc);})['then'](function(_0x49c8e3){if(_0x49c8e3)return _0x49c8e3?{'count':_0x3dcc85,'rows':_0x49c8e3}:null;})[_0x31cf19('0x41')](respondWithResult(_0x15fc82,null))[_0x31cf19('0x28')](handleError(_0x15fc82,null));},exports[_0x16533b('0x15')]=function(_0x1281fc,_0x45c4ec){const _0x40308e=_0x16533b;return db[_0x40308e('0x25')][_0x40308e('0x6')]({'where':{'id':_0x1281fc[_0x40308e('0x20')]['id']}})[_0x40308e('0x41')](handleEntityNotFound(_0x45c4ec,null))[_0x40308e('0x41')](function(_0x43630c){const _0x278989=_0x40308e;if(_0x43630c)return db[_0x278989('0x33')][_0x278989('0x19')](function(_0x3340d2){const _0x45ffc3=_0x278989;return db['Interval'][_0x45ffc3('0x21')]({'where':{'IntervalId':_0x1281fc['params']['id']},'transaction':_0x3340d2})[_0x45ffc3('0x41')](function(){const _0x2a7044=_0x45ffc3,_0x59b3e1=_[_0x2a7044('0x38')](_0x1281fc[_0x2a7044('0x3c')],function(_0x3abee8){const _0x214559=_0x2a7044;return delete _0x3abee8['id'],_0x3abee8[_0x214559('0xf')]=_0x1281fc[_0x214559('0x20')]['id'],_0x3abee8;});return db['Interval'][_0x2a7044('0x14')](_0x59b3e1,{'transaction':_0x3340d2});});})[_0x278989('0x41')](function(){const _0x4a37d6=_0x278989;return db[_0x4a37d6('0x25')][_0x4a37d6('0x2f')]({'where':{'IntervalId':_0x1281fc[_0x4a37d6('0x20')]['id']}});});})[_0x40308e('0x41')](respondWithResult(_0x45c4ec,null))['catch'](handleError(_0x45c4ec,null));}; \ No newline at end of file +const a367_0x443d=['key','IntervalId','include','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','show','get','findAll','nolimit','transaction','type','undefined','getIntervals','attributes','Unable\x20to\x20retrieve\x20the\x20current\x20user','sendStatus','includeAll','like','catch','pick','name','end','body','options','Content-Range','UserProfileResource','model','create','then','api','autoAssociation','fieldName','../../components/parsers/qs','map','../../config/logger','params','where','fields','lodash','length','filter','findOne','intersection','query','Interval','json','destroy','UserProfileSection','Intervals','status','merge','offset','update','rawAttributes','keys','send','set','index','sequelize','error','limit','sort','addInterval','VIRTUAL','order','filters','rows','count'];(function(_0x4a039a,_0x443d51){const _0x207130=function(_0x3115e0){while(--_0x3115e0){_0x4a039a['push'](_0x4a039a['shift']());}};_0x207130(++_0x443d51);}(a367_0x443d,0xd8));const a367_0x2071=function(_0x4a039a,_0x443d51){_0x4a039a=_0x4a039a-0x0;let _0x207130=a367_0x443d[_0x4a039a];return _0x207130;};const _0x55404b=a367_0x2071;'use strict';const _=require(_0x55404b('0x16')),qs=require(_0x55404b('0x10')),logger=require(_0x55404b('0x12'))(_0x55404b('0xd')),db=require('../../mysqldb')['db'],{Op}=require(_0x55404b('0x2a'));function respondWithResult(_0x3115e0,_0x4bc235){return _0x4bc235=_0x4bc235||0xc8,function(_0x31575c){const _0x722615=a367_0x2071;if(_0x31575c)return _0x3115e0['status'](_0x4bc235)[_0x722615('0x1d')](_0x31575c);};}function respondWithFilteredResult(_0x3abf6a,_0x2645dc){return function(_0x333493){const _0x345e15=a367_0x2071;if(_0x333493){const _0x253a1c=_0x333493[_0x345e15('0x33')],_0x3170e7=_0x2645dc[_0x345e15('0x23')];let _0x2d6e39=_0x2645dc[_0x345e15('0x23')]+_0x2645dc[_0x345e15('0x2c')],_0x5c1fd1;return _0x2d6e39>=_0x253a1c?(_0x2d6e39=_0x253a1c,_0x5c1fd1=0xc8):_0x5c1fd1=0xce,_0x3abf6a['status'](_0x5c1fd1),_0x3abf6a[_0x345e15('0x28')](_0x345e15('0x8'),_0x3170e7+'-'+_0x2d6e39+'/'+_0x253a1c)['json'](_0x333493);}return null;};}function saveUpdates(_0x30ea60){return function(_0x3366fb){const _0x21da5=a367_0x2071;if(_0x3366fb)return _0x3366fb[_0x21da5('0x24')](_0x30ea60)[_0x21da5('0xc')](function(_0x4ac219){return _0x4ac219;});return null;};}function removeEntity(_0x28b8ed){return function(_0x206942){const _0x3b3a46=a367_0x2071;if(_0x206942)return _0x206942[_0x3b3a46('0x1e')]()[_0x3b3a46('0xc')](function(){const _0x4fff83=_0x3b3a46,_0x4fb120=_0x206942[_0x4fff83('0x39')]({'plain':!![]}),_0x270870='Intervals';return db[_0x4fff83('0x9')][_0x4fff83('0x1e')]({'where':{'type':_0x270870,'resourceId':_0x4fb120['id']}})['then'](function(){return _0x206942;});})['then'](function(){const _0x48a238=_0x3b3a46;_0x28b8ed['status'](0xcc)[_0x48a238('0x5')]();});};}function handleEntityNotFound(_0xbc996){return function(_0x418b34){const _0x2ec628=a367_0x2071;return!_0x418b34&&_0xbc996[_0x2ec628('0x42')](0x194),_0x418b34;};}function handleError(_0x584131,_0x267c9f){return _0x267c9f=_0x267c9f||0x1f4,function(_0x3ebd22){const _0x3315f1=a367_0x2071;logger[_0x3315f1('0x2b')](_0x3ebd22['stack']),_0x3ebd22[_0x3315f1('0x4')]&&delete _0x3ebd22[_0x3315f1('0x4')],_0x584131[_0x3315f1('0x21')](_0x267c9f)[_0x3315f1('0x27')](_0x3ebd22);};}exports[_0x55404b('0x29')]=function(_0xde27cf,_0x389dab){const _0x34bac5=_0x55404b;let _0x379d9a={};const _0x3bbb6b={},_0x155718={'count':0x0,'rows':[]},_0x489890=_[_0x34bac5('0x11')](db[_0x34bac5('0x1c')][_0x34bac5('0x25')],function(_0x1023b3){const _0x539481=_0x34bac5;return{'name':_0x1023b3[_0x539481('0xf')],'type':_0x1023b3['type'][_0x539481('0x34')]};});_0x3bbb6b[_0x34bac5('0xa')]=_[_0x34bac5('0x11')](_0x489890,'name'),_0x3bbb6b[_0x34bac5('0x1b')]=_[_0x34bac5('0x26')](_0xde27cf[_0x34bac5('0x1b')]),_0x3bbb6b[_0x34bac5('0x31')]=_[_0x34bac5('0x1a')](_0x3bbb6b[_0x34bac5('0xa')],_0x3bbb6b['query']),_0x379d9a[_0x34bac5('0x40')]=_[_0x34bac5('0x1a')](_0x3bbb6b['model'],qs[_0x34bac5('0x15')](_0xde27cf['query'][_0x34bac5('0x15')])),_0x379d9a[_0x34bac5('0x40')]=_0x379d9a[_0x34bac5('0x40')][_0x34bac5('0x17')]?_0x379d9a[_0x34bac5('0x40')]:_0x3bbb6b[_0x34bac5('0xa')];typeof _0xde27cf[_0x34bac5('0x1b')][_0x34bac5('0x3b')]===_0x34bac5('0x3e')&&(_0x379d9a[_0x34bac5('0x2c')]=qs['limit'](_0xde27cf['query'][_0x34bac5('0x2c')]),_0x379d9a[_0x34bac5('0x23')]=qs[_0x34bac5('0x23')](_0xde27cf[_0x34bac5('0x1b')][_0x34bac5('0x23')]));_0x379d9a[_0x34bac5('0x30')]=qs[_0x34bac5('0x2d')](_0xde27cf[_0x34bac5('0x1b')]['sort']),_0x379d9a['where']=qs[_0x34bac5('0x31')](_[_0x34bac5('0x3')](_0xde27cf[_0x34bac5('0x1b')],_0x3bbb6b['filters']),_0x489890);_0xde27cf[_0x34bac5('0x1b')][_0x34bac5('0x18')]&&(_0x379d9a['where']=_[_0x34bac5('0x22')](_0x379d9a[_0x34bac5('0x14')],{[Op['or']]:_[_0x34bac5('0x11')](_0x489890,function(_0x14b9dc){const _0x47b2b3=_0x34bac5;if(_0x14b9dc[_0x47b2b3('0x3d')]!==_0x47b2b3('0x2f')){const _0x12c986={};return _0x12c986[_0x14b9dc['name']]={[Op[_0x47b2b3('0x1')]]:'%'+_0xde27cf['query'][_0x47b2b3('0x18')]+'%'},_0x12c986;}})}));_0x379d9a=_[_0x34bac5('0x22')]({},_0x379d9a,_0xde27cf[_0x34bac5('0x7')]);const _0xd9fa6c={'where':_0x379d9a[_0x34bac5('0x14')]};return db[_0x34bac5('0x1c')][_0x34bac5('0x33')](_0xd9fa6c)[_0x34bac5('0xc')](function(_0x2d96f6){const _0x27c0c9=_0x34bac5;return _0x155718[_0x27c0c9('0x33')]=_0x2d96f6,_0xde27cf[_0x27c0c9('0x1b')][_0x27c0c9('0x0')]&&(_0x379d9a[_0x27c0c9('0x36')]=[{'all':!![]}]),db['Interval']['findAll'](_0x379d9a);})[_0x34bac5('0xc')](function(_0x5d5515){const _0x4e1fbb=_0x34bac5;return _0x155718[_0x4e1fbb('0x32')]=_0x5d5515,_0x155718;})['then'](respondWithFilteredResult(_0x389dab,_0x379d9a))[_0x34bac5('0x2')](handleError(_0x389dab,null));},exports[_0x55404b('0x38')]=function(_0x4cf725,_0x2bef3a){const _0x4c227c=_0x55404b;let _0x50dcdf={'raw':!![],'where':{'id':_0x4cf725[_0x4c227c('0x13')]['id']}};const _0x1ee821={};return _0x1ee821['model']=_[_0x4c227c('0x26')](db[_0x4c227c('0x1c')][_0x4c227c('0x25')]),_0x1ee821['query']=_[_0x4c227c('0x26')](_0x4cf725[_0x4c227c('0x1b')]),_0x1ee821['filters']=_[_0x4c227c('0x1a')](_0x1ee821[_0x4c227c('0xa')],_0x1ee821['query']),_0x50dcdf[_0x4c227c('0x40')]=_['intersection'](_0x1ee821['model'],qs['fields'](_0x4cf725['query'][_0x4c227c('0x15')])),_0x50dcdf['attributes']=_0x50dcdf[_0x4c227c('0x40')][_0x4c227c('0x17')]?_0x50dcdf['attributes']:_0x1ee821['model'],_0x4cf725['query'][_0x4c227c('0x0')]&&(_0x50dcdf[_0x4c227c('0x36')]=[{'all':!![]}]),_0x50dcdf=_['merge']({},_0x50dcdf,_0x4cf725[_0x4c227c('0x7')]),db[_0x4c227c('0x1c')]['findOne'](_0x50dcdf)[_0x4c227c('0xc')](handleEntityNotFound(_0x2bef3a,null))[_0x4c227c('0xc')](respondWithResult(_0x2bef3a,null))[_0x4c227c('0x2')](handleError(_0x2bef3a,null));},exports[_0x55404b('0xb')]=function(_0x5198c6,_0x49956d){const _0x51a412=_0x55404b;return db[_0x51a412('0x1c')]['create'](_0x5198c6['body'],{})['then'](function(_0x5a847f){const _0x10aeee=_0x51a412,_0x3f124e=_0x5198c6['user'][_0x10aeee('0x39')]({'plain':!![]});if(!_0x3f124e)throw new Error(_0x10aeee('0x41'));if(_0x3f124e['role']==='user'){const _0x93f106=_0x5a847f['get']({'plain':!![]}),_0x5dca32=_0x10aeee('0x20');return db[_0x10aeee('0x1f')][_0x10aeee('0x19')]({'where':{'name':_0x5dca32,'userProfileId':_0x3f124e['userProfileId']},'raw':!![]})[_0x10aeee('0xc')](function(_0x1ef4b7){const _0x450288=_0x10aeee;return _0x1ef4b7&&_0x1ef4b7[_0x450288('0xe')]===0x0?db['UserProfileResource'][_0x450288('0xb')]({'name':_0x93f106[_0x450288('0x4')],'resourceId':_0x93f106['id'],'type':_0x1ef4b7[_0x450288('0x4')],'sectionId':_0x1ef4b7['id']},{})['then'](function(){return _0x5a847f;}):_0x5a847f;})[_0x10aeee('0x2')](function(_0x2636e5){const _0x415e1e=_0x10aeee;logger[_0x415e1e('0x2b')](_0x415e1e('0x37'),_0x2636e5);throw _0x2636e5;});}return _0x5a847f;})[_0x51a412('0xc')](respondWithResult(_0x49956d,0xc9))[_0x51a412('0x2')](handleError(_0x49956d,null));},exports['update']=function(_0x575d39,_0x21295c){const _0x3c4bc9=_0x55404b;return _0x575d39[_0x3c4bc9('0x6')]['id']&&delete _0x575d39[_0x3c4bc9('0x6')]['id'],db[_0x3c4bc9('0x1c')][_0x3c4bc9('0x19')]({'where':{'id':_0x575d39[_0x3c4bc9('0x13')]['id']}})[_0x3c4bc9('0xc')](handleEntityNotFound(_0x21295c,null))[_0x3c4bc9('0xc')](saveUpdates(_0x575d39['body'],null))[_0x3c4bc9('0xc')](respondWithResult(_0x21295c,null))[_0x3c4bc9('0x2')](handleError(_0x21295c,null));},exports[_0x55404b('0x1e')]=function(_0x3e04f3,_0xe54fce){const _0x40b825=_0x55404b;return db[_0x40b825('0x1c')][_0x40b825('0x19')]({'where':{'id':_0x3e04f3[_0x40b825('0x13')]['id']}})['then'](handleEntityNotFound(_0xe54fce,null))[_0x40b825('0xc')](removeEntity(_0xe54fce,null))['catch'](handleError(_0xe54fce,null));},exports[_0x55404b('0x2e')]=function(_0x3c7592,_0x4c4c85){const _0x4dd307=_0x55404b;return _0x3c7592['body']['id']&&delete _0x3c7592[_0x4dd307('0x6')]['id'],db[_0x4dd307('0x1c')][_0x4dd307('0x19')]({'where':{'id':_0x3c7592[_0x4dd307('0x13')]['id']}})[_0x4dd307('0xc')](handleEntityNotFound(_0x4c4c85,null))[_0x4dd307('0xc')](function(_0x4f9097){const _0x45f5f7=_0x4dd307;if(_0x4f9097)return _0x3c7592['body'][_0x45f5f7('0x35')]=_0x4f9097['id'],db[_0x45f5f7('0x1c')][_0x45f5f7('0xb')](_0x3c7592[_0x45f5f7('0x6')]);})[_0x4dd307('0xc')](respondWithResult(_0x4c4c85,null))[_0x4dd307('0x2')](handleError(_0x4c4c85,null));},exports[_0x55404b('0x3f')]=function(_0x5fcbf,_0x2156cb){const _0x47e5b2=_0x55404b;let _0x25cede={};const _0x31fdc3={};let _0x50c116,_0x11301f;return db[_0x47e5b2('0x1c')][_0x47e5b2('0x19')]({'where':{'id':_0x5fcbf[_0x47e5b2('0x13')]['id']}})[_0x47e5b2('0xc')](handleEntityNotFound(_0x2156cb,null))[_0x47e5b2('0xc')](function(_0x40cac6){const _0x2d6940=_0x47e5b2;if(_0x40cac6)return _0x50c116=_0x40cac6,_0x31fdc3[_0x2d6940('0xa')]=_['keys'](db[_0x2d6940('0x1c')][_0x2d6940('0x25')]),_0x31fdc3[_0x2d6940('0x1b')]=_['keys'](_0x5fcbf['query']),_0x31fdc3['filters']=_[_0x2d6940('0x1a')](_0x31fdc3[_0x2d6940('0xa')],_0x31fdc3[_0x2d6940('0x1b')]),_0x25cede[_0x2d6940('0x40')]=_['intersection'](_0x31fdc3[_0x2d6940('0xa')],qs[_0x2d6940('0x15')](_0x5fcbf[_0x2d6940('0x1b')][_0x2d6940('0x15')])),_0x25cede[_0x2d6940('0x40')]=_0x25cede[_0x2d6940('0x40')][_0x2d6940('0x17')]?_0x25cede[_0x2d6940('0x40')]:_0x31fdc3[_0x2d6940('0xa')],_0x25cede[_0x2d6940('0x30')]=qs[_0x2d6940('0x2d')](_0x5fcbf[_0x2d6940('0x1b')]['sort']),_0x25cede[_0x2d6940('0x14')]=qs[_0x2d6940('0x31')](_[_0x2d6940('0x3')](_0x5fcbf[_0x2d6940('0x1b')],_0x31fdc3[_0x2d6940('0x31')])),_0x5fcbf[_0x2d6940('0x1b')][_0x2d6940('0x18')]&&(_0x25cede[_0x2d6940('0x14')]=_[_0x2d6940('0x22')](_0x25cede[_0x2d6940('0x14')],{[Op['or']]:_[_0x2d6940('0x11')](_0x25cede[_0x2d6940('0x40')],function(_0x1fb3d2){const _0x409763=_0x2d6940,_0x20f2eb={};return _0x20f2eb[_0x1fb3d2]={[Op['like']]:'%'+_0x5fcbf[_0x409763('0x1b')][_0x409763('0x18')]+'%'},_0x20f2eb;})})),_0x25cede=_[_0x2d6940('0x22')]({},_0x25cede,_0x5fcbf[_0x2d6940('0x7')]),_0x50c116[_0x2d6940('0x3f')](_0x25cede);})['then'](function(_0x1a1515){const _0x4e34ad=_0x47e5b2;if(_0x1a1515)return _0x11301f=_0x1a1515[_0x4e34ad('0x17')],typeof _0x5fcbf[_0x4e34ad('0x1b')][_0x4e34ad('0x3b')]===_0x4e34ad('0x3e')&&(_0x25cede[_0x4e34ad('0x2c')]=qs[_0x4e34ad('0x2c')](_0x5fcbf['query']['limit']),_0x25cede[_0x4e34ad('0x23')]=qs[_0x4e34ad('0x23')](_0x5fcbf[_0x4e34ad('0x1b')][_0x4e34ad('0x23')])),_0x50c116[_0x4e34ad('0x3f')](_0x25cede);})[_0x47e5b2('0xc')](function(_0x4a1c0e){if(_0x4a1c0e)return _0x4a1c0e?{'count':_0x11301f,'rows':_0x4a1c0e}:null;})[_0x47e5b2('0xc')](respondWithResult(_0x2156cb,null))[_0x47e5b2('0x2')](handleError(_0x2156cb,null));},exports['addIntervals']=function(_0x31dd23,_0x389594){const _0x36d3a1=_0x55404b;return db[_0x36d3a1('0x1c')][_0x36d3a1('0x19')]({'where':{'id':_0x31dd23['params']['id']}})[_0x36d3a1('0xc')](handleEntityNotFound(_0x389594,null))[_0x36d3a1('0xc')](function(_0xccb49e){const _0x34d5ef=_0x36d3a1;if(_0xccb49e)return db[_0x34d5ef('0x2a')][_0x34d5ef('0x3c')](function(_0x4b077b){const _0x405575=_0x34d5ef;return db[_0x405575('0x1c')][_0x405575('0x1e')]({'where':{'IntervalId':_0x31dd23[_0x405575('0x13')]['id']},'transaction':_0x4b077b})['then'](function(){const _0x2f87a8=_0x405575,_0x36cd5c=_[_0x2f87a8('0x11')](_0x31dd23[_0x2f87a8('0x6')],function(_0x903fbd){return delete _0x903fbd['id'],_0x903fbd['IntervalId']=_0x31dd23['params']['id'],_0x903fbd;});return db[_0x2f87a8('0x1c')]['bulkCreate'](_0x36cd5c,{'transaction':_0x4b077b});});})[_0x34d5ef('0xc')](function(){const _0x4e68d6=_0x34d5ef;return db[_0x4e68d6('0x1c')][_0x4e68d6('0x3a')]({'where':{'IntervalId':_0x31dd23['params']['id']}});});})[_0x36d3a1('0xc')](respondWithResult(_0x389594,null))[_0x36d3a1('0x2')](handleError(_0x389594,null));}; \ No newline at end of file diff --git a/server/api/interval/interval.model.js b/server/api/interval/interval.model.js index f4721e6..3d9d6e1 100644 --- a/server/api/interval/interval.model.js +++ b/server/api/interval/interval.model.js @@ -1 +1 @@ -const a368_0x2e0c=['../../components/extensions/rewrite','rewrite','define','./interval.attributes','exports'];(function(_0x2b71f3,_0x2e0c56){const _0x5e6d17=function(_0x1911bf){while(--_0x1911bf){_0x2b71f3['push'](_0x2b71f3['shift']());}};_0x5e6d17(++_0x2e0c56);}(a368_0x2e0c,0x150));const a368_0x5e6d=function(_0x2b71f3,_0x2e0c56){_0x2b71f3=_0x2b71f3-0x0;let _0x5e6d17=a368_0x2e0c[_0x2b71f3];return _0x5e6d17;};const _0x12ccf3=a368_0x5e6d;'use strict';const attributes=require(_0x12ccf3('0x2')),extensions=require(_0x12ccf3('0x4'));module[_0x12ccf3('0x3')]=function(_0x1911bf){const _0x3f2671=_0x12ccf3,_0x5466a3=_0x1911bf[_0x3f2671('0x1')]('Interval',attributes,{'tableName':'tools_intervals','paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'afterCreate':function(_0x5d74fb){const _0x2ead62=_0x3f2671;extensions[_0x2ead62('0x0')](_0x1911bf,_0x5d74fb);},'afterBulkCreate':function(_0x22bf5e){extensions['rewrite'](_0x1911bf,_0x22bf5e[0x0]);},'afterUpdate':function(_0x265af1){const _0x5baafb=_0x3f2671;extensions[_0x5baafb('0x0')](_0x1911bf,_0x265af1);},'afterDestroy':function(_0x3746fb){const _0x1713bd=_0x3f2671;extensions[_0x1713bd('0x0')](_0x1911bf,_0x3746fb);}}});return _0x5466a3;}; \ No newline at end of file +const a368_0x19da=['exports','./interval.attributes','tools_intervals','../../components/extensions/rewrite','rewrite','define'];(function(_0x319160,_0x19da26){const _0xceeb71=function(_0x158b68){while(--_0x158b68){_0x319160['push'](_0x319160['shift']());}};_0xceeb71(++_0x19da26);}(a368_0x19da,0x19c));const a368_0xceeb=function(_0x319160,_0x19da26){_0x319160=_0x319160-0x0;let _0xceeb71=a368_0x19da[_0x319160];return _0xceeb71;};const _0x320ebd=a368_0xceeb;'use strict';const attributes=require(_0x320ebd('0x3')),extensions=require(_0x320ebd('0x5'));module[_0x320ebd('0x2')]=function(_0x158b68){const _0x1a4c7e=_0x320ebd,_0x289789=_0x158b68[_0x1a4c7e('0x1')]('Interval',attributes,{'tableName':_0x1a4c7e('0x4'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'afterCreate':function(_0x5c06da){const _0x57a350=_0x1a4c7e;extensions[_0x57a350('0x0')](_0x158b68,_0x5c06da);},'afterBulkCreate':function(_0x6c8176){const _0x214e63=_0x1a4c7e;extensions[_0x214e63('0x0')](_0x158b68,_0x6c8176[0x0]);},'afterUpdate':function(_0x2b4fd1){const _0x412934=_0x1a4c7e;extensions[_0x412934('0x0')](_0x158b68,_0x2b4fd1);},'afterDestroy':function(_0x1063a3){extensions['rewrite'](_0x158b68,_0x1063a3);}}});return _0x289789;}; \ No newline at end of file diff --git a/server/api/interval/interval.rpc.js b/server/api/interval/interval.rpc.js index 8e17178..5ec9d61 100644 --- a/server/api/interval/interval.rpc.js +++ b/server/api/interval/interval.rpc.js @@ -1 +1 @@ -const a369_0x23f2=['info','findAll','lodash','map','where','ShowInterval','rpc','then','model','GetInterval','error','options','message','../../config/logger','Interval','limit','attributes','include','stringify','../../mysqldb'];(function(_0x376fa8,_0x23f206){const _0xdcda30=function(_0x311b1e){while(--_0x311b1e){_0x376fa8['push'](_0x376fa8['shift']());}};_0xdcda30(++_0x23f206);}(a369_0x23f2,0xb7));const a369_0xdcda=function(_0x376fa8,_0x23f206){_0x376fa8=_0x376fa8-0x0;let _0xdcda30=a369_0x23f2[_0x376fa8];return _0xdcda30;};const _0x4de4e0=a369_0xdcda;'use strict';const _=require(_0x4de4e0('0x13')),db=require(_0x4de4e0('0x10'))['db'],logger=require(_0x4de4e0('0xa'))(_0x4de4e0('0x3'));exports[_0x4de4e0('0x6')]=function(_0x311b1e){const _0x4b70ca=this;return new Promise(function(_0x4508eb,_0x48d566){const _0x1c12fd=a369_0xdcda;return db['Interval'][_0x1c12fd('0x12')]({'raw':_0x311b1e[_0x1c12fd('0x8')]?_0x311b1e[_0x1c12fd('0x8')]['raw']===undefined?!![]:![]:!![],'where':_0x311b1e['options']?_0x311b1e['options'][_0x1c12fd('0x1')]||null:null,'attributes':_0x311b1e[_0x1c12fd('0x8')]?_0x311b1e[_0x1c12fd('0x8')][_0x1c12fd('0xd')]||null:null,'limit':_0x311b1e[_0x1c12fd('0x8')]?_0x311b1e[_0x1c12fd('0x8')][_0x1c12fd('0xc')]||null:null,'include':_0x311b1e['options']?_0x311b1e[_0x1c12fd('0x8')][_0x1c12fd('0xe')]?_['map'](_0x311b1e[_0x1c12fd('0x8')]['include'],function(_0x608888){const _0x5e60b8=_0x1c12fd;return{'model':db[_0x608888[_0x5e60b8('0x5')]],'as':_0x608888['as'],'attributes':_0x608888['attributes'],'include':_0x608888[_0x5e60b8('0xe')]?_[_0x5e60b8('0x0')](_0x608888[_0x5e60b8('0xe')],function(_0x584886){const _0x18250c=_0x5e60b8;return{'model':db[_0x584886[_0x18250c('0x5')]],'as':_0x584886['as'],'attributes':_0x584886[_0x18250c('0xd')],'include':_0x584886[_0x18250c('0xe')]?_[_0x18250c('0x0')](_0x584886[_0x18250c('0xe')],function(_0x12c631){const _0x31a564=_0x18250c;return{'model':db[_0x12c631[_0x31a564('0x5')]],'as':_0x12c631['as'],'attributes':_0x12c631[_0x31a564('0xd')]};}):[]};}):[]};}):[]:[]})[_0x1c12fd('0x4')](function(_0x9c118c){const _0x13215d=_0x1c12fd;logger[_0x13215d('0x11')](_0x13215d('0x6'),_0x311b1e),logger['debug'](_0x13215d('0x6'),_0x311b1e,JSON[_0x13215d('0xf')](_0x9c118c)),_0x4508eb(_0x9c118c);})['catch'](function(_0x17ef14){const _0x5b1aed=_0x1c12fd;logger[_0x5b1aed('0x7')]('GetInterval',_0x17ef14[_0x5b1aed('0x9')],_0x311b1e),_0x48d566(_0x4b70ca['error'](0x1f4,_0x17ef14['message']));});});},exports['ShowInterval']=function(_0x4ef8e8){const _0x2d896e=this;return new Promise(function(_0xd5628d,_0x20c331){const _0x16f722=a369_0xdcda;return db[_0x16f722('0xb')]['findOne']({'raw':_0x4ef8e8[_0x16f722('0x8')]?_0x4ef8e8[_0x16f722('0x8')]['raw']===undefined?!![]:![]:!![],'where':_0x4ef8e8[_0x16f722('0x8')]?_0x4ef8e8[_0x16f722('0x8')][_0x16f722('0x1')]||null:null,'attributes':_0x4ef8e8['options']?_0x4ef8e8[_0x16f722('0x8')][_0x16f722('0xd')]||null:null,'include':_0x4ef8e8['options']?_0x4ef8e8['options'][_0x16f722('0xe')]?_[_0x16f722('0x0')](_0x4ef8e8[_0x16f722('0x8')][_0x16f722('0xe')],function(_0x466f8d){const _0x61b291=_0x16f722;return{'model':db[_0x466f8d[_0x61b291('0x5')]],'as':_0x466f8d['as'],'attributes':_0x466f8d['attributes'],'include':_0x466f8d[_0x61b291('0xe')]?_['map'](_0x466f8d[_0x61b291('0xe')],function(_0xe67ee4){const _0x53b474=_0x61b291;return{'model':db[_0xe67ee4[_0x53b474('0x5')]],'as':_0xe67ee4['as'],'attributes':_0xe67ee4['attributes'],'include':_0xe67ee4[_0x53b474('0xe')]?_['map'](_0xe67ee4['include'],function(_0x4eff82){const _0x532dd7=_0x53b474;return{'model':db[_0x4eff82[_0x532dd7('0x5')]],'as':_0x4eff82['as'],'attributes':_0x4eff82['attributes']};}):[]};}):[]};}):[]:[]})[_0x16f722('0x4')](function(_0x50c4f2){const _0x5970f3=_0x16f722;logger[_0x5970f3('0x11')](_0x5970f3('0x2'),_0x4ef8e8),logger['debug'](_0x5970f3('0x2'),_0x4ef8e8,JSON[_0x5970f3('0xf')](_0x50c4f2)),_0xd5628d(_0x50c4f2);})['catch'](function(_0x476d25){const _0x142d31=_0x16f722;logger[_0x142d31('0x7')](_0x142d31('0x2'),_0x476d25[_0x142d31('0x9')],_0x4ef8e8),_0x20c331(_0x2d896e[_0x142d31('0x7')](0x1f4,_0x476d25[_0x142d31('0x9')]));});});}; \ No newline at end of file +const a369_0x338a=['lodash','limit','findAll','map','then','catch','info','rpc','stringify','raw','model','ShowInterval','where','options','debug','error','../../config/logger','../../mysqldb','message','attributes','findOne','include','GetInterval'];(function(_0x1a48f1,_0x338a9e){const _0x178b4e=function(_0x47a5f0){while(--_0x47a5f0){_0x1a48f1['push'](_0x1a48f1['shift']());}};_0x178b4e(++_0x338a9e);}(a369_0x338a,0x1c6));const a369_0x178b=function(_0x1a48f1,_0x338a9e){_0x1a48f1=_0x1a48f1-0x0;let _0x178b4e=a369_0x338a[_0x1a48f1];return _0x178b4e;};const _0x5a7cec=a369_0x178b;'use strict';const _=require(_0x5a7cec('0x6')),db=require(_0x5a7cec('0x0'))['db'],logger=require(_0x5a7cec('0x16'))(_0x5a7cec('0xd'));exports['GetInterval']=function(_0x47a5f0){const _0x550857=this;return new Promise(function(_0x51d9f7,_0x269da8){const _0x233f2c=a369_0x178b;return db['Interval'][_0x233f2c('0x8')]({'raw':_0x47a5f0[_0x233f2c('0x13')]?_0x47a5f0[_0x233f2c('0x13')][_0x233f2c('0xf')]===undefined?!![]:![]:!![],'where':_0x47a5f0[_0x233f2c('0x13')]?_0x47a5f0['options'][_0x233f2c('0x12')]||null:null,'attributes':_0x47a5f0['options']?_0x47a5f0[_0x233f2c('0x13')][_0x233f2c('0x2')]||null:null,'limit':_0x47a5f0[_0x233f2c('0x13')]?_0x47a5f0[_0x233f2c('0x13')][_0x233f2c('0x7')]||null:null,'include':_0x47a5f0[_0x233f2c('0x13')]?_0x47a5f0[_0x233f2c('0x13')][_0x233f2c('0x4')]?_[_0x233f2c('0x9')](_0x47a5f0[_0x233f2c('0x13')][_0x233f2c('0x4')],function(_0x43ee18){const _0x3b2468=_0x233f2c;return{'model':db[_0x43ee18[_0x3b2468('0x10')]],'as':_0x43ee18['as'],'attributes':_0x43ee18['attributes'],'include':_0x43ee18[_0x3b2468('0x4')]?_[_0x3b2468('0x9')](_0x43ee18['include'],function(_0x347a38){const _0x4f2837=_0x3b2468;return{'model':db[_0x347a38[_0x4f2837('0x10')]],'as':_0x347a38['as'],'attributes':_0x347a38[_0x4f2837('0x2')],'include':_0x347a38[_0x4f2837('0x4')]?_[_0x4f2837('0x9')](_0x347a38['include'],function(_0xd9b622){const _0x55e269=_0x4f2837;return{'model':db[_0xd9b622['model']],'as':_0xd9b622['as'],'attributes':_0xd9b622[_0x55e269('0x2')]};}):[]};}):[]};}):[]:[]})[_0x233f2c('0xa')](function(_0x2cccdd){const _0x22d118=_0x233f2c;logger['info'](_0x22d118('0x5'),_0x47a5f0),logger[_0x22d118('0x14')](_0x22d118('0x5'),_0x47a5f0,JSON['stringify'](_0x2cccdd)),_0x51d9f7(_0x2cccdd);})[_0x233f2c('0xb')](function(_0x1e30d2){const _0x4a1b2c=_0x233f2c;logger[_0x4a1b2c('0x15')](_0x4a1b2c('0x5'),_0x1e30d2[_0x4a1b2c('0x1')],_0x47a5f0),_0x269da8(_0x550857[_0x4a1b2c('0x15')](0x1f4,_0x1e30d2['message']));});});},exports['ShowInterval']=function(_0x457f7d){const _0x48b124=this;return new Promise(function(_0x5984e2,_0x1cbfc6){const _0x2cbebc=a369_0x178b;return db['Interval'][_0x2cbebc('0x3')]({'raw':_0x457f7d[_0x2cbebc('0x13')]?_0x457f7d[_0x2cbebc('0x13')]['raw']===undefined?!![]:![]:!![],'where':_0x457f7d[_0x2cbebc('0x13')]?_0x457f7d[_0x2cbebc('0x13')]['where']||null:null,'attributes':_0x457f7d['options']?_0x457f7d[_0x2cbebc('0x13')][_0x2cbebc('0x2')]||null:null,'include':_0x457f7d[_0x2cbebc('0x13')]?_0x457f7d[_0x2cbebc('0x13')][_0x2cbebc('0x4')]?_[_0x2cbebc('0x9')](_0x457f7d['options'][_0x2cbebc('0x4')],function(_0x4ee023){const _0x254b2f=_0x2cbebc;return{'model':db[_0x4ee023[_0x254b2f('0x10')]],'as':_0x4ee023['as'],'attributes':_0x4ee023[_0x254b2f('0x2')],'include':_0x4ee023[_0x254b2f('0x4')]?_[_0x254b2f('0x9')](_0x4ee023['include'],function(_0x172a86){const _0x481578=_0x254b2f;return{'model':db[_0x172a86['model']],'as':_0x172a86['as'],'attributes':_0x172a86[_0x481578('0x2')],'include':_0x172a86[_0x481578('0x4')]?_[_0x481578('0x9')](_0x172a86[_0x481578('0x4')],function(_0x23e955){const _0x2a448d=_0x481578;return{'model':db[_0x23e955[_0x2a448d('0x10')]],'as':_0x23e955['as'],'attributes':_0x23e955['attributes']};}):[]};}):[]};}):[]:[]})[_0x2cbebc('0xa')](function(_0x598829){const _0x3a6b00=_0x2cbebc;logger[_0x3a6b00('0xc')](_0x3a6b00('0x11'),_0x457f7d),logger[_0x3a6b00('0x14')]('ShowInterval',_0x457f7d,JSON[_0x3a6b00('0xe')](_0x598829)),_0x5984e2(_0x598829);})[_0x2cbebc('0xb')](function(_0x3fffac){const _0x34a09c=_0x2cbebc;logger[_0x34a09c('0x15')](_0x34a09c('0x11'),_0x3fffac['message'],_0x457f7d),_0x1cbfc6(_0x48b124[_0x34a09c('0x15')](0x1f4,_0x3fffac[_0x34a09c('0x1')]));});});}; \ No newline at end of file diff --git a/server/api/jira/index.js b/server/api/jira/index.js index 0afe35f..d7f8fc3 100644 --- a/server/api/jira/index.js +++ b/server/api/jira/index.js @@ -1 +1 @@ -const a370_0xb869=['post','express','send','Router','exports'];(function(_0x3eae69,_0xb8698f){const _0x3edffd=function(_0x4041b8){while(--_0x4041b8){_0x3eae69['push'](_0x3eae69['shift']());}};_0x3edffd(++_0xb8698f);}(a370_0xb869,0xe9));const a370_0x3edf=function(_0x3eae69,_0xb8698f){_0x3eae69=_0x3eae69-0x0;let _0x3edffd=a370_0xb869[_0x3eae69];return _0x3edffd;};const _0x162d38=a370_0x3edf;'use strict';const express=require(_0x162d38('0x3')),router=express[_0x162d38('0x0')](),auth=require('../../components/auth/service'),controller=require('./jira.controller');router[_0x162d38('0x2')]('/',auth['isAuthenticated'](),controller[_0x162d38('0x4')]),module[_0x162d38('0x1')]=router; \ No newline at end of file +const a370_0x30e7=['send','post','../../components/auth/service','Router','isAuthenticated','express'];(function(_0x4acd4c,_0x30e7cd){const _0x23da95=function(_0x25b7a2){while(--_0x25b7a2){_0x4acd4c['push'](_0x4acd4c['shift']());}};_0x23da95(++_0x30e7cd);}(a370_0x30e7,0x1ef));const a370_0x23da=function(_0x4acd4c,_0x30e7cd){_0x4acd4c=_0x4acd4c-0x0;let _0x23da95=a370_0x30e7[_0x4acd4c];return _0x23da95;};const _0x26bcad=a370_0x23da;'use strict';const express=require(_0x26bcad('0x2')),router=express[_0x26bcad('0x0')](),auth=require(_0x26bcad('0x5')),controller=require('./jira.controller');router[_0x26bcad('0x4')]('/',auth[_0x26bcad('0x1')](),controller[_0x26bcad('0x3')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/jira/jira.controller.js b/server/api/jira/jira.controller.js index 04e010e..cd79b2b 100644 --- a/server/api/jira/jira.controller.js +++ b/server/api/jira/jira.controller.js @@ -1 +1 @@ -const a371_0x1faf=['data','openIssue','customfield_11504','connection','end','\x20from\x20','3eAmWpBVP0','issuetype','name','Report','track.xcallymotion.com','Basic\x20','customfield_11503','customfield_11500','statusCode','fields','newToken','email','api.jira','customfield_11501','socket','summary','Error\x20during\x20license\x20request.\x20Please\x20contact\x20our\x20license\x20team\x20at\x20license@xcally.com\x20with\x20your\x20request','status','base64','write','https','key','json','support','from','Bug','body','request','description','remoteAddress','stringify'];(function(_0x56ee63,_0x1faf0a){const _0x4d8474=function(_0x5d2834){while(--_0x5d2834){_0x56ee63['push'](_0x56ee63['shift']());}};_0x4d8474(++_0x1faf0a);}(a371_0x1faf,0x126));const a371_0x4d84=function(_0x56ee63,_0x1faf0a){_0x56ee63=_0x56ee63-0x0;let _0x4d8474=a371_0x1faf[_0x56ee63];return _0x4d8474;};const _0x4e02e0=a371_0x4d84;'use strict';const https=require(_0x4e02e0('0x1c')),USERNAME=_0x4e02e0('0x1f'),PASSWORD=_0x4e02e0('0x8');function openIssue(_0x5d2834,_0x39b967){const _0xb1a1f8=_0x4e02e0,_0x334919={'fields':{'project':{'key':_0x5d2834[_0xb1a1f8('0x1d')]||'MOTGUI'},'summary':(_0x5d2834[_0xb1a1f8('0x17')]||_0xb1a1f8('0xb'))+_0xb1a1f8('0x7')+_0x5d2834['ip'],'description':_0x5d2834[_0xb1a1f8('0x24')]||JSON[_0xb1a1f8('0x1')](_0x5d2834),'issuetype':{'name':_0x5d2834[_0xb1a1f8('0x9')]||_0xb1a1f8('0x21')}}};_0x334919[_0xb1a1f8('0x11')][_0xb1a1f8('0xf')]=_0x5d2834[_0xb1a1f8('0x13')],_0x334919[_0xb1a1f8('0x11')][_0xb1a1f8('0x15')]=_0x5d2834['oldToken'],_0x334919[_0xb1a1f8('0x11')]['customfield_11502']=_0x5d2834[_0xb1a1f8('0x12')],_0x334919[_0xb1a1f8('0x11')][_0xb1a1f8('0xe')]=_0x5d2834[_0xb1a1f8('0xa')],_0x334919[_0xb1a1f8('0x11')][_0xb1a1f8('0x4')]=_0x5d2834['reason'],_0x334919[_0xb1a1f8('0x11')]['customfield_10102']=_0x5d2834['ip'];const _0x50d78e={'host':_0xb1a1f8('0xc'),'port':0x1bb,'path':'/rest/api/2/issue','method':'POST','timeout':0x4e20,'headers':{'Content-Type':'application/json','Authorization':_0xb1a1f8('0xd')+Buffer[_0xb1a1f8('0x20')](USERNAME+':'+PASSWORD)['toString'](_0xb1a1f8('0x1a'))}},_0x3d0694=JSON['stringify'](_0x334919),_0x3d5dd4=https[_0xb1a1f8('0x23')](_0x50d78e,function(_0x2e73e1){const _0x36f61f=_0xb1a1f8;_0x2e73e1['setEncoding']('utf8');let _0x2bdfa7='';_0x2e73e1['on'](_0x36f61f('0x2'),function(_0x46e9bc){_0x2bdfa7+=_0x46e9bc;}),_0x2e73e1['on']('end',function(){const _0x53855b=_0x36f61f;if(_0x39b967)return _0x39b967['status'](_0x2e73e1[_0x53855b('0x10')])['json'](JSON['parse'](_0x2bdfa7));});});_0x3d5dd4['on']('error',function(){const _0x316e25=_0xb1a1f8;if(_0x39b967)return _0x39b967[_0x316e25('0x19')](0x1f4)[_0x316e25('0x1e')]({'errors':[{'message':_0x316e25('0x18'),'type':_0x316e25('0x14')}]});}),_0x3d5dd4[_0xb1a1f8('0x1b')](_0x3d0694),_0x3d5dd4[_0xb1a1f8('0x6')]();}exports[_0x4e02e0('0x3')]=openIssue,exports['send']=function(_0x25a194,_0x25dc29){const _0x1bfcad=_0x4e02e0;return _0x25a194[_0x1bfcad('0x22')]['ip']=_0x25a194['headers']['x-forwarded-for']||_0x25a194[_0x1bfcad('0x5')][_0x1bfcad('0x0')]||_0x25a194[_0x1bfcad('0x16')][_0x1bfcad('0x0')]||_0x25a194['connection'][_0x1bfcad('0x16')][_0x1bfcad('0x0')],openIssue(_0x25a194[_0x1bfcad('0x22')],_0x25dc29);}; \ No newline at end of file +const a371_0x4661=['stringify','/rest/api/2/issue','customfield_11500','email','https','toString','reason','3eAmWpBVP0','statusCode','issuetype','parse','connection','json','remoteAddress','send','write','request','Error\x20during\x20license\x20request.\x20Please\x20contact\x20our\x20license\x20team\x20at\x20license@xcally.com\x20with\x20your\x20request','socket','end','customfield_11503','application/json','POST','customfield_11504','utf8','oldToken','headers','api.jira','customfield_11501','name','MOTGUI','summary','openIssue','key','Bug','from','body','support','status','Basic\x20','base64','newToken','fields','error'];(function(_0xe9d8b2,_0x46613b){const _0x512839=function(_0x18e1a8){while(--_0x18e1a8){_0xe9d8b2['push'](_0xe9d8b2['shift']());}};_0x512839(++_0x46613b);}(a371_0x4661,0xe3));const a371_0x5128=function(_0xe9d8b2,_0x46613b){_0xe9d8b2=_0xe9d8b2-0x0;let _0x512839=a371_0x4661[_0xe9d8b2];return _0x512839;};const _0x263230=a371_0x5128;'use strict';const https=require(_0x263230('0x29')),USERNAME=_0x263230('0x1e'),PASSWORD=_0x263230('0x0');function openIssue(_0x18e1a8,_0x5ab8fc){const _0xcff3c2=_0x263230,_0x4ed22d={'fields':{'project':{'key':_0x18e1a8[_0xcff3c2('0x1a')]||_0xcff3c2('0x17')},'summary':(_0x18e1a8[_0xcff3c2('0x18')]||'Report')+'\x20from\x20'+_0x18e1a8['ip'],'description':_0x18e1a8['description']||JSON['stringify'](_0x18e1a8),'issuetype':{'name':_0x18e1a8[_0xcff3c2('0x2')]||_0xcff3c2('0x1b')}}};_0x4ed22d[_0xcff3c2('0x23')][_0xcff3c2('0x27')]=_0x18e1a8[_0xcff3c2('0x28')],_0x4ed22d['fields'][_0xcff3c2('0x15')]=_0x18e1a8[_0xcff3c2('0x12')],_0x4ed22d['fields']['customfield_11502']=_0x18e1a8[_0xcff3c2('0x22')],_0x4ed22d['fields'][_0xcff3c2('0xd')]=_0x18e1a8[_0xcff3c2('0x16')],_0x4ed22d[_0xcff3c2('0x23')][_0xcff3c2('0x10')]=_0x18e1a8[_0xcff3c2('0x2b')],_0x4ed22d[_0xcff3c2('0x23')]['customfield_10102']=_0x18e1a8['ip'];const _0x48cd22={'host':'track.xcallymotion.com','port':0x1bb,'path':_0xcff3c2('0x26'),'method':_0xcff3c2('0xf'),'timeout':0x4e20,'headers':{'Content-Type':_0xcff3c2('0xe'),'Authorization':_0xcff3c2('0x20')+Buffer[_0xcff3c2('0x1c')](USERNAME+':'+PASSWORD)[_0xcff3c2('0x2a')](_0xcff3c2('0x21'))}},_0x274471=JSON[_0xcff3c2('0x25')](_0x4ed22d),_0x42356c=https[_0xcff3c2('0x9')](_0x48cd22,function(_0x3d9a0a){const _0x27c23d=_0xcff3c2;_0x3d9a0a['setEncoding'](_0x27c23d('0x11'));let _0x29fe19='';_0x3d9a0a['on']('data',function(_0x4d4dae){_0x29fe19+=_0x4d4dae;}),_0x3d9a0a['on'](_0x27c23d('0xc'),function(){const _0x4788e2=_0x27c23d;if(_0x5ab8fc)return _0x5ab8fc[_0x4788e2('0x1f')](_0x3d9a0a[_0x4788e2('0x1')])[_0x4788e2('0x5')](JSON[_0x4788e2('0x3')](_0x29fe19));});});_0x42356c['on'](_0xcff3c2('0x24'),function(){const _0x4016e9=_0xcff3c2;if(_0x5ab8fc)return _0x5ab8fc[_0x4016e9('0x1f')](0x1f4)[_0x4016e9('0x5')]({'errors':[{'message':_0x4016e9('0xa'),'type':_0x4016e9('0x14')}]});}),_0x42356c[_0xcff3c2('0x8')](_0x274471),_0x42356c[_0xcff3c2('0xc')]();}exports[_0x263230('0x19')]=openIssue,exports[_0x263230('0x7')]=function(_0x3ce8c1,_0x478778){const _0x359c0a=_0x263230;return _0x3ce8c1[_0x359c0a('0x1d')]['ip']=_0x3ce8c1[_0x359c0a('0x13')]['x-forwarded-for']||_0x3ce8c1[_0x359c0a('0x4')][_0x359c0a('0x6')]||_0x3ce8c1[_0x359c0a('0xb')][_0x359c0a('0x6')]||_0x3ce8c1[_0x359c0a('0x4')]['socket'][_0x359c0a('0x6')],openIssue(_0x3ce8c1['body'],_0x478778);}; \ No newline at end of file diff --git a/server/api/jscriptyAnswerReport/index.js b/server/api/jscriptyAnswerReport/index.js index fcf7b93..42c6cca 100644 --- a/server/api/jscriptyAnswerReport/index.js +++ b/server/api/jscriptyAnswerReport/index.js @@ -1 +1 @@ -const a372_0x234e=['update','show','express','Router','./jscriptyAnswerReport.controller','isAuthenticated','destroy','describe','get','index','post','/describe','../../components/auth/service','put'];(function(_0x3ef01e,_0x234e34){const _0x338153=function(_0xc6d782){while(--_0xc6d782){_0x3ef01e['push'](_0x3ef01e['shift']());}};_0x338153(++_0x234e34);}(a372_0x234e,0x7d));const a372_0x3381=function(_0x3ef01e,_0x234e34){_0x3ef01e=_0x3ef01e-0x0;let _0x338153=a372_0x234e[_0x3ef01e];return _0x338153;};const _0x2edfc5=a372_0x3381;'use strict';const express=require(_0x2edfc5('0x3')),router=express[_0x2edfc5('0x4')](),auth=require(_0x2edfc5('0xd')),controller=require(_0x2edfc5('0x5'));router[_0x2edfc5('0x9')]('/',auth[_0x2edfc5('0x6')](),controller[_0x2edfc5('0xa')]),router[_0x2edfc5('0x9')](_0x2edfc5('0xc'),auth[_0x2edfc5('0x6')](),controller[_0x2edfc5('0x8')]),router[_0x2edfc5('0x9')]('/:id',auth[_0x2edfc5('0x6')](),controller[_0x2edfc5('0x2')]),router[_0x2edfc5('0xb')]('/',auth['isAuthenticated'](),controller['create']),router[_0x2edfc5('0x0')]('/:id',auth[_0x2edfc5('0x6')](),controller[_0x2edfc5('0x1')]),router['delete']('/:id',auth[_0x2edfc5('0x6')](),controller[_0x2edfc5('0x7')]),module['exports']=router; \ No newline at end of file +const a372_0x5733=['../../components/auth/service','describe','delete','index','Router','exports','show','create','/describe','./jscriptyAnswerReport.controller','get','isAuthenticated','update','/:id','express'];(function(_0xdddee8,_0x5733a9){const _0x39c24f=function(_0x8e7d1){while(--_0x8e7d1){_0xdddee8['push'](_0xdddee8['shift']());}};_0x39c24f(++_0x5733a9);}(a372_0x5733,0x66));const a372_0x39c2=function(_0xdddee8,_0x5733a9){_0xdddee8=_0xdddee8-0x0;let _0x39c24f=a372_0x5733[_0xdddee8];return _0x39c24f;};const _0x129cfc=a372_0x39c2;'use strict';const express=require(_0x129cfc('0x2')),router=express[_0x129cfc('0x7')](),auth=require(_0x129cfc('0x3')),controller=require(_0x129cfc('0xc'));router[_0x129cfc('0xd')]('/',auth['isAuthenticated'](),controller[_0x129cfc('0x6')]),router['get'](_0x129cfc('0xb'),auth[_0x129cfc('0xe')](),controller[_0x129cfc('0x4')]),router[_0x129cfc('0xd')]('/:id',auth[_0x129cfc('0xe')](),controller[_0x129cfc('0x9')]),router['post']('/',auth[_0x129cfc('0xe')](),controller[_0x129cfc('0xa')]),router['put'](_0x129cfc('0x1'),auth['isAuthenticated'](),controller[_0x129cfc('0x0')]),router[_0x129cfc('0x5')](_0x129cfc('0x1'),auth['isAuthenticated'](),controller['destroy']),module[_0x129cfc('0x8')]=router; \ No newline at end of file diff --git a/server/api/jscriptyAnswerReport/jscriptyAnswerReport.attributes.js b/server/api/jscriptyAnswerReport/jscriptyAnswerReport.attributes.js index 0547472..4b94718 100644 --- a/server/api/jscriptyAnswerReport/jscriptyAnswerReport.attributes.js +++ b/server/api/jscriptyAnswerReport/jscriptyAnswerReport.attributes.js @@ -1 +1 @@ -const a373_0x4f6e=['long','STRING','exports','TEXT'];(function(_0x166d47,_0x4f6e75){const _0x3c2491=function(_0x5bc46b){while(--_0x5bc46b){_0x166d47['push'](_0x166d47['shift']());}};_0x3c2491(++_0x4f6e75);}(a373_0x4f6e,0x1b8));const a373_0x3c24=function(_0x166d47,_0x4f6e75){_0x166d47=_0x166d47-0x0;let _0x3c2491=a373_0x4f6e[_0x166d47];return _0x3c2491;};const _0x52a21a=a373_0x3c24;'use strict';const Sequelize=require('sequelize');module[_0x52a21a('0x2')]={'question':{'type':Sequelize['STRING']},'answer':{'type':Sequelize[_0x52a21a('0x3')](_0x52a21a('0x0'))},'membername':{'type':Sequelize[_0x52a21a('0x1')]},'projectname':{'type':Sequelize['STRING']},'queue':{'type':Sequelize[_0x52a21a('0x1')]},'uniqueid':{'type':Sequelize[_0x52a21a('0x1')]},'calleridname':{'type':Sequelize[_0x52a21a('0x1')]},'calleridnum':{'type':Sequelize[_0x52a21a('0x1')]},'questionId':{'type':Sequelize[_0x52a21a('0x1')]}}; \ No newline at end of file +const a373_0xa264=['STRING','sequelize','long','exports','TEXT'];(function(_0x2791f4,_0xa26452){const _0x2864ed=function(_0x12c4c2){while(--_0x12c4c2){_0x2791f4['push'](_0x2791f4['shift']());}};_0x2864ed(++_0xa26452);}(a373_0xa264,0x19b));const a373_0x2864=function(_0x2791f4,_0xa26452){_0x2791f4=_0x2791f4-0x0;let _0x2864ed=a373_0xa264[_0x2791f4];return _0x2864ed;};const _0x470360=a373_0x2864;'use strict';const Sequelize=require(_0x470360('0x0'));module[_0x470360('0x2')]={'question':{'type':Sequelize['STRING']},'answer':{'type':Sequelize[_0x470360('0x3')](_0x470360('0x1'))},'membername':{'type':Sequelize[_0x470360('0x4')]},'projectname':{'type':Sequelize[_0x470360('0x4')]},'queue':{'type':Sequelize[_0x470360('0x4')]},'uniqueid':{'type':Sequelize['STRING']},'calleridname':{'type':Sequelize['STRING']},'calleridnum':{'type':Sequelize[_0x470360('0x4')]},'questionId':{'type':Sequelize[_0x470360('0x4')]}}; \ No newline at end of file diff --git a/server/api/jscriptyAnswerReport/jscriptyAnswerReport.controller.js b/server/api/jscriptyAnswerReport/jscriptyAnswerReport.controller.js index db721e1..c76d153 100644 --- a/server/api/jscriptyAnswerReport/jscriptyAnswerReport.controller.js +++ b/server/api/jscriptyAnswerReport/jscriptyAnswerReport.controller.js @@ -1 +1 @@ -const a374_0x5482=['body','key','nolimit','keys','filter','offset','findAll','Content-Range','includeAll','findOne','destroy','model','fields','index','describe','send','../../mysqldb','name','JscriptyAnswerReport','show','map','lodash','json','set','update','merge','create','rows','params','../../config/logger','like','then','sendStatus','catch','status','stack','api','rawAttributes','sequelize','intersection','pick','include','filters','undefined','../../components/parsers/qs','limit','VIRTUAL','sort','where','attributes','query','length','count'];(function(_0x953215,_0x54823e){const _0x3dbe2f=function(_0x1fe99d){while(--_0x1fe99d){_0x953215['push'](_0x953215['shift']());}};_0x3dbe2f(++_0x54823e);}(a374_0x5482,0xb3));const a374_0x3dbe=function(_0x953215,_0x54823e){_0x953215=_0x953215-0x0;let _0x3dbe2f=a374_0x5482[_0x953215];return _0x3dbe2f;};const _0x580581=a374_0x3dbe;'use strict';const _=require(_0x580581('0x1')),qs=require(_0x580581('0x18')),logger=require(_0x580581('0x9'))(_0x580581('0x10')),db=require(_0x580581('0x31'))['db'],{Op}=require(_0x580581('0x12'));function respondWithResult(_0x1fe99d,_0x573bf0){return _0x573bf0=_0x573bf0||0xc8,function(_0x557120){const _0x391376=a374_0x3dbe;if(_0x557120)return _0x1fe99d[_0x391376('0xe')](_0x573bf0)[_0x391376('0x2')](_0x557120);};}function respondWithFilteredResult(_0x209dcc,_0x2d7eda){return function(_0x158e52){const _0x9973c=a374_0x3dbe;if(_0x158e52){const _0x4a3f92=_0x158e52[_0x9973c('0x20')],_0x72ffc=_0x2d7eda[_0x9973c('0x26')];let _0x45aa62=_0x2d7eda[_0x9973c('0x26')]+_0x2d7eda[_0x9973c('0x19')],_0x1ca27a;return _0x45aa62>=_0x4a3f92?(_0x45aa62=_0x4a3f92,_0x1ca27a=0xc8):_0x1ca27a=0xce,_0x209dcc[_0x9973c('0xe')](_0x1ca27a),_0x209dcc[_0x9973c('0x3')](_0x9973c('0x28'),_0x72ffc+'-'+_0x45aa62+'/'+_0x4a3f92)[_0x9973c('0x2')](_0x158e52);}return null;};}function saveUpdates(_0x2731bd){return function(_0x33f133){const _0x12fc88=a374_0x3dbe;if(_0x33f133)return _0x33f133[_0x12fc88('0x4')](_0x2731bd)['then'](function(_0x243c6f){return _0x243c6f;});return null;};}function removeEntity(_0x1e4dee){return function(_0x2194cc){const _0x303365=a374_0x3dbe;if(_0x2194cc)return _0x2194cc[_0x303365('0x2b')]()['then'](function(){const _0x3e919c=_0x303365;_0x1e4dee[_0x3e919c('0xe')](0xcc)['end']();});};}function handleEntityNotFound(_0x57f2cc){return function(_0x367139){const _0x441adb=a374_0x3dbe;return!_0x367139&&_0x57f2cc[_0x441adb('0xc')](0x194),_0x367139;};}function handleError(_0x3b2243,_0x320225){return _0x320225=_0x320225||0x1f4,function(_0xa49236){const _0x300d32=a374_0x3dbe;logger['error'](_0xa49236[_0x300d32('0xf')]),_0xa49236[_0x300d32('0x32')]&&delete _0xa49236[_0x300d32('0x32')],_0x3b2243[_0x300d32('0xe')](_0x320225)[_0x300d32('0x30')](_0xa49236);};}exports[_0x580581('0x2e')]=function(_0x4e4f84,_0x58aaff){const _0x2bc21a=_0x580581;let _0x2b9b5f={};const _0x463d63={},_0x533455={'count':0x0,'rows':[]},_0xdede64=_[_0x2bc21a('0x0')](db[_0x2bc21a('0x33')][_0x2bc21a('0x11')],function(_0x5ac76e){const _0x4dbf0a=_0x2bc21a;return{'name':_0x5ac76e['fieldName'],'type':_0x5ac76e['type'][_0x4dbf0a('0x22')]};});_0x463d63['model']=_['map'](_0xdede64,'name'),_0x463d63[_0x2bc21a('0x1e')]=_[_0x2bc21a('0x24')](_0x4e4f84[_0x2bc21a('0x1e')]),_0x463d63[_0x2bc21a('0x16')]=_[_0x2bc21a('0x13')](_0x463d63[_0x2bc21a('0x2c')],_0x463d63['query']),_0x2b9b5f[_0x2bc21a('0x1d')]=_[_0x2bc21a('0x13')](_0x463d63[_0x2bc21a('0x2c')],qs[_0x2bc21a('0x2d')](_0x4e4f84['query'][_0x2bc21a('0x2d')])),_0x2b9b5f[_0x2bc21a('0x1d')]=_0x2b9b5f[_0x2bc21a('0x1d')]['length']?_0x2b9b5f['attributes']:_0x463d63[_0x2bc21a('0x2c')];typeof _0x4e4f84[_0x2bc21a('0x1e')][_0x2bc21a('0x23')]===_0x2bc21a('0x17')&&(_0x2b9b5f[_0x2bc21a('0x19')]=qs[_0x2bc21a('0x19')](_0x4e4f84[_0x2bc21a('0x1e')][_0x2bc21a('0x19')]),_0x2b9b5f['offset']=qs[_0x2bc21a('0x26')](_0x4e4f84[_0x2bc21a('0x1e')]['offset']));_0x2b9b5f['order']=qs[_0x2bc21a('0x1b')](_0x4e4f84[_0x2bc21a('0x1e')][_0x2bc21a('0x1b')]),_0x2b9b5f[_0x2bc21a('0x1c')]=qs[_0x2bc21a('0x16')](_[_0x2bc21a('0x14')](_0x4e4f84[_0x2bc21a('0x1e')],_0x463d63[_0x2bc21a('0x16')]),_0xdede64);_0x4e4f84['query'][_0x2bc21a('0x25')]&&(_0x2b9b5f[_0x2bc21a('0x1c')]=_[_0x2bc21a('0x5')](_0x2b9b5f[_0x2bc21a('0x1c')],{[Op['or']]:_[_0x2bc21a('0x0')](_0xdede64,function(_0x48e792){const _0x5b7ba0=_0x2bc21a;if(_0x48e792['type']!==_0x5b7ba0('0x1a')){const _0x5d3362={};return _0x5d3362[_0x48e792[_0x5b7ba0('0x32')]]={[Op[_0x5b7ba0('0xa')]]:'%'+_0x4e4f84[_0x5b7ba0('0x1e')][_0x5b7ba0('0x25')]+'%'},_0x5d3362;}})}));_0x2b9b5f=_[_0x2bc21a('0x5')]({},_0x2b9b5f,_0x4e4f84['options']);const _0x46435b={'where':_0x2b9b5f['where']};return db['JscriptyAnswerReport'][_0x2bc21a('0x20')](_0x46435b)['then'](function(_0x194487){const _0x882d7f=_0x2bc21a;return _0x533455['count']=_0x194487,_0x4e4f84[_0x882d7f('0x1e')][_0x882d7f('0x29')]&&(_0x2b9b5f[_0x882d7f('0x15')]=[{'all':!![]}]),db[_0x882d7f('0x33')][_0x882d7f('0x27')](_0x2b9b5f);})['then'](function(_0x2e0c99){const _0x4256fa=_0x2bc21a;return _0x533455[_0x4256fa('0x7')]=_0x2e0c99,_0x533455;})[_0x2bc21a('0xb')](respondWithFilteredResult(_0x58aaff,_0x2b9b5f))[_0x2bc21a('0xd')](handleError(_0x58aaff,null));},exports[_0x580581('0x34')]=function(_0x5c7d13,_0x3206a7){const _0x2349c5=_0x580581;let _0x144a09={'raw':!![],'where':{'id':_0x5c7d13[_0x2349c5('0x8')]['id']}};const _0x325935={};return _0x325935[_0x2349c5('0x2c')]=_['keys'](db[_0x2349c5('0x33')][_0x2349c5('0x11')]),_0x325935['query']=_[_0x2349c5('0x24')](_0x5c7d13['query']),_0x325935[_0x2349c5('0x16')]=_[_0x2349c5('0x13')](_0x325935['model'],_0x325935[_0x2349c5('0x1e')]),_0x144a09['attributes']=_[_0x2349c5('0x13')](_0x325935['model'],qs['fields'](_0x5c7d13[_0x2349c5('0x1e')][_0x2349c5('0x2d')])),_0x144a09[_0x2349c5('0x1d')]=_0x144a09[_0x2349c5('0x1d')][_0x2349c5('0x1f')]?_0x144a09[_0x2349c5('0x1d')]:_0x325935[_0x2349c5('0x2c')],_0x5c7d13[_0x2349c5('0x1e')][_0x2349c5('0x29')]&&(_0x144a09[_0x2349c5('0x15')]=[{'all':!![]}]),_0x144a09=_['merge']({},_0x144a09,_0x5c7d13['options']),db[_0x2349c5('0x33')]['findOne'](_0x144a09)[_0x2349c5('0xb')](handleEntityNotFound(_0x3206a7,null))[_0x2349c5('0xb')](respondWithResult(_0x3206a7,null))[_0x2349c5('0xd')](handleError(_0x3206a7,null));},exports[_0x580581('0x6')]=function(_0x202577,_0x1447b8){const _0x2c0d26=_0x580581;return db[_0x2c0d26('0x33')][_0x2c0d26('0x6')](_0x202577[_0x2c0d26('0x21')],{})[_0x2c0d26('0xb')](respondWithResult(_0x1447b8,0xc9))['catch'](handleError(_0x1447b8,null));},exports[_0x580581('0x4')]=function(_0x335369,_0x1604f3){const _0x86fde7=_0x580581;return _0x335369[_0x86fde7('0x21')]['id']&&delete _0x335369[_0x86fde7('0x21')]['id'],db[_0x86fde7('0x33')][_0x86fde7('0x2a')]({'where':{'id':_0x335369[_0x86fde7('0x8')]['id']}})[_0x86fde7('0xb')](handleEntityNotFound(_0x1604f3,null))['then'](saveUpdates(_0x335369[_0x86fde7('0x21')],null))[_0x86fde7('0xb')](respondWithResult(_0x1604f3,null))[_0x86fde7('0xd')](handleError(_0x1604f3,null));},exports['destroy']=function(_0x9a3073,_0x2007d4){const _0x2b04e4=_0x580581;return db[_0x2b04e4('0x33')][_0x2b04e4('0x2a')]({'where':{'id':_0x9a3073[_0x2b04e4('0x8')]['id']}})[_0x2b04e4('0xb')](handleEntityNotFound(_0x2007d4,null))[_0x2b04e4('0xb')](removeEntity(_0x2007d4,null))[_0x2b04e4('0xd')](handleError(_0x2007d4,null));},exports[_0x580581('0x2f')]=function(_0x147eed,_0x36b33b){const _0x484e4c=_0x580581;return db[_0x484e4c('0x33')][_0x484e4c('0x2f')]()[_0x484e4c('0xb')](respondWithResult(_0x36b33b,null))[_0x484e4c('0xd')](handleError(_0x36b33b,null));}; \ No newline at end of file +const a374_0x56fc=['intersection','catch','../../components/parsers/qs','pick','fields','nolimit','json','sort','keys','Content-Range','lodash','set','destroy','like','type','VIRTUAL','show','stack','rawAttributes','rows','sendStatus','../../mysqldb','count','where','describe','body','findAll','create','name','model','JscriptyAnswerReport','index','attributes','merge','order','../../config/logger','findOne','filter','length','includeAll','offset','filters','fieldName','limit','status','update','then','include','undefined','query','params'];(function(_0x3316b1,_0x56fcae){const _0x385f78=function(_0xe7549){while(--_0xe7549){_0x3316b1['push'](_0x3316b1['shift']());}};_0x385f78(++_0x56fcae);}(a374_0x56fc,0x172));const a374_0x385f=function(_0x3316b1,_0x56fcae){_0x3316b1=_0x3316b1-0x0;let _0x385f78=a374_0x56fc[_0x3316b1];return _0x385f78;};const _0x2d7974=a374_0x385f;'use strict';const _=require(_0x2d7974('0x30')),qs=require(_0x2d7974('0x28')),logger=require(_0x2d7974('0x16'))('api'),db=require(_0x2d7974('0x8'))['db'],{Op}=require('sequelize');function respondWithResult(_0xe7549,_0x215173){return _0x215173=_0x215173||0xc8,function(_0x1f662a){const _0x40e4b5=a374_0x385f;if(_0x1f662a)return _0xe7549['status'](_0x215173)[_0x40e4b5('0x2c')](_0x1f662a);};}function respondWithFilteredResult(_0x1b6827,_0xf9e9d7){return function(_0x22fde2){const _0x38ab40=a374_0x385f;if(_0x22fde2){const _0x518ad8=_0x22fde2[_0x38ab40('0x9')],_0x56ead9=_0xf9e9d7[_0x38ab40('0x1b')];let _0x2c9256=_0xf9e9d7[_0x38ab40('0x1b')]+_0xf9e9d7[_0x38ab40('0x1e')],_0x4f582a;return _0x2c9256>=_0x518ad8?(_0x2c9256=_0x518ad8,_0x4f582a=0xc8):_0x4f582a=0xce,_0x1b6827[_0x38ab40('0x1f')](_0x4f582a),_0x1b6827[_0x38ab40('0x31')](_0x38ab40('0x2f'),_0x56ead9+'-'+_0x2c9256+'/'+_0x518ad8)[_0x38ab40('0x2c')](_0x22fde2);}return null;};}function saveUpdates(_0xf44be3){return function(_0x2be240){const _0x1ddf12=a374_0x385f;if(_0x2be240)return _0x2be240[_0x1ddf12('0x20')](_0xf44be3)['then'](function(_0x312a7f){return _0x312a7f;});return null;};}function removeEntity(_0x5976fb){return function(_0x119475){const _0x57a398=a374_0x385f;if(_0x119475)return _0x119475[_0x57a398('0x32')]()['then'](function(){const _0x1db972=_0x57a398;_0x5976fb[_0x1db972('0x1f')](0xcc)['end']();});};}function handleEntityNotFound(_0x48e1dd){return function(_0x1c7c51){const _0x4acb66=a374_0x385f;return!_0x1c7c51&&_0x48e1dd[_0x4acb66('0x7')](0x194),_0x1c7c51;};}function handleError(_0x5e7d6f,_0x526274){return _0x526274=_0x526274||0x1f4,function(_0x512249){const _0x1c5cee=a374_0x385f;logger['error'](_0x512249[_0x1c5cee('0x4')]),_0x512249[_0x1c5cee('0xf')]&&delete _0x512249[_0x1c5cee('0xf')],_0x5e7d6f[_0x1c5cee('0x1f')](_0x526274)['send'](_0x512249);};}exports[_0x2d7974('0x12')]=function(_0x518605,_0x5b20fb){const _0x4e54b8=_0x2d7974;let _0x144bd3={};const _0xeee7d2={},_0x52be04={'count':0x0,'rows':[]},_0x576bba=_['map'](db[_0x4e54b8('0x11')][_0x4e54b8('0x5')],function(_0x2a7d37){const _0x363233=_0x4e54b8;return{'name':_0x2a7d37[_0x363233('0x1d')],'type':_0x2a7d37[_0x363233('0x1')]['key']};});_0xeee7d2['model']=_['map'](_0x576bba,'name'),_0xeee7d2[_0x4e54b8('0x24')]=_['keys'](_0x518605[_0x4e54b8('0x24')]),_0xeee7d2[_0x4e54b8('0x1c')]=_[_0x4e54b8('0x26')](_0xeee7d2[_0x4e54b8('0x10')],_0xeee7d2[_0x4e54b8('0x24')]),_0x144bd3[_0x4e54b8('0x13')]=_['intersection'](_0xeee7d2['model'],qs[_0x4e54b8('0x2a')](_0x518605['query']['fields'])),_0x144bd3['attributes']=_0x144bd3['attributes'][_0x4e54b8('0x19')]?_0x144bd3[_0x4e54b8('0x13')]:_0xeee7d2[_0x4e54b8('0x10')];typeof _0x518605[_0x4e54b8('0x24')][_0x4e54b8('0x2b')]===_0x4e54b8('0x23')&&(_0x144bd3[_0x4e54b8('0x1e')]=qs[_0x4e54b8('0x1e')](_0x518605['query'][_0x4e54b8('0x1e')]),_0x144bd3[_0x4e54b8('0x1b')]=qs[_0x4e54b8('0x1b')](_0x518605[_0x4e54b8('0x24')][_0x4e54b8('0x1b')]));_0x144bd3[_0x4e54b8('0x15')]=qs[_0x4e54b8('0x2d')](_0x518605[_0x4e54b8('0x24')][_0x4e54b8('0x2d')]),_0x144bd3[_0x4e54b8('0xa')]=qs[_0x4e54b8('0x1c')](_[_0x4e54b8('0x29')](_0x518605['query'],_0xeee7d2['filters']),_0x576bba);_0x518605['query'][_0x4e54b8('0x18')]&&(_0x144bd3['where']=_['merge'](_0x144bd3['where'],{[Op['or']]:_['map'](_0x576bba,function(_0x32b765){const _0x4b3a13=_0x4e54b8;if(_0x32b765[_0x4b3a13('0x1')]!==_0x4b3a13('0x2')){const _0xf68e0={};return _0xf68e0[_0x32b765['name']]={[Op[_0x4b3a13('0x0')]]:'%'+_0x518605[_0x4b3a13('0x24')]['filter']+'%'},_0xf68e0;}})}));_0x144bd3=_[_0x4e54b8('0x14')]({},_0x144bd3,_0x518605['options']);const _0x240e4={'where':_0x144bd3['where']};return db[_0x4e54b8('0x11')]['count'](_0x240e4)['then'](function(_0x4d7319){const _0x33e9f9=_0x4e54b8;return _0x52be04[_0x33e9f9('0x9')]=_0x4d7319,_0x518605['query'][_0x33e9f9('0x1a')]&&(_0x144bd3[_0x33e9f9('0x22')]=[{'all':!![]}]),db[_0x33e9f9('0x11')][_0x33e9f9('0xd')](_0x144bd3);})[_0x4e54b8('0x21')](function(_0x38ca6a){const _0x3e4222=_0x4e54b8;return _0x52be04[_0x3e4222('0x6')]=_0x38ca6a,_0x52be04;})[_0x4e54b8('0x21')](respondWithFilteredResult(_0x5b20fb,_0x144bd3))['catch'](handleError(_0x5b20fb,null));},exports[_0x2d7974('0x3')]=function(_0xa1a0c7,_0x143143){const _0x1a9b75=_0x2d7974;let _0x324e41={'raw':!![],'where':{'id':_0xa1a0c7['params']['id']}};const _0x555a37={};return _0x555a37['model']=_['keys'](db[_0x1a9b75('0x11')][_0x1a9b75('0x5')]),_0x555a37[_0x1a9b75('0x24')]=_[_0x1a9b75('0x2e')](_0xa1a0c7[_0x1a9b75('0x24')]),_0x555a37[_0x1a9b75('0x1c')]=_['intersection'](_0x555a37['model'],_0x555a37[_0x1a9b75('0x24')]),_0x324e41['attributes']=_[_0x1a9b75('0x26')](_0x555a37[_0x1a9b75('0x10')],qs[_0x1a9b75('0x2a')](_0xa1a0c7[_0x1a9b75('0x24')][_0x1a9b75('0x2a')])),_0x324e41[_0x1a9b75('0x13')]=_0x324e41[_0x1a9b75('0x13')][_0x1a9b75('0x19')]?_0x324e41['attributes']:_0x555a37[_0x1a9b75('0x10')],_0xa1a0c7[_0x1a9b75('0x24')][_0x1a9b75('0x1a')]&&(_0x324e41[_0x1a9b75('0x22')]=[{'all':!![]}]),_0x324e41=_[_0x1a9b75('0x14')]({},_0x324e41,_0xa1a0c7['options']),db['JscriptyAnswerReport'][_0x1a9b75('0x17')](_0x324e41)[_0x1a9b75('0x21')](handleEntityNotFound(_0x143143,null))[_0x1a9b75('0x21')](respondWithResult(_0x143143,null))['catch'](handleError(_0x143143,null));},exports[_0x2d7974('0xe')]=function(_0x5a9fdb,_0x3deecb){const _0x3c86d3=_0x2d7974;return db[_0x3c86d3('0x11')][_0x3c86d3('0xe')](_0x5a9fdb[_0x3c86d3('0xc')],{})[_0x3c86d3('0x21')](respondWithResult(_0x3deecb,0xc9))[_0x3c86d3('0x27')](handleError(_0x3deecb,null));},exports[_0x2d7974('0x20')]=function(_0xac7ea9,_0x362bf4){const _0x56425d=_0x2d7974;return _0xac7ea9['body']['id']&&delete _0xac7ea9[_0x56425d('0xc')]['id'],db[_0x56425d('0x11')][_0x56425d('0x17')]({'where':{'id':_0xac7ea9['params']['id']}})[_0x56425d('0x21')](handleEntityNotFound(_0x362bf4,null))[_0x56425d('0x21')](saveUpdates(_0xac7ea9[_0x56425d('0xc')],null))[_0x56425d('0x21')](respondWithResult(_0x362bf4,null))[_0x56425d('0x27')](handleError(_0x362bf4,null));},exports[_0x2d7974('0x32')]=function(_0x336d26,_0x3e374b){const _0x5322fb=_0x2d7974;return db['JscriptyAnswerReport'][_0x5322fb('0x17')]({'where':{'id':_0x336d26[_0x5322fb('0x25')]['id']}})[_0x5322fb('0x21')](handleEntityNotFound(_0x3e374b,null))[_0x5322fb('0x21')](removeEntity(_0x3e374b,null))[_0x5322fb('0x27')](handleError(_0x3e374b,null));},exports[_0x2d7974('0xb')]=function(_0x4c7e95,_0x1ffe9e){const _0x51e0bb=_0x2d7974;return db['JscriptyAnswerReport'][_0x51e0bb('0xb')]()[_0x51e0bb('0x21')](respondWithResult(_0x1ffe9e,null))[_0x51e0bb('0x27')](handleError(_0x1ffe9e,null));}; \ No newline at end of file diff --git a/server/api/jscriptyAnswerReport/jscriptyAnswerReport.model.js b/server/api/jscriptyAnswerReport/jscriptyAnswerReport.model.js index e940a26..50984c2 100644 --- a/server/api/jscriptyAnswerReport/jscriptyAnswerReport.model.js +++ b/server/api/jscriptyAnswerReport/jscriptyAnswerReport.model.js @@ -1 +1 @@ -const a375_0x5aad=['report_jscripty_answers','exports','./jscriptyAnswerReport.attributes','define'];(function(_0x3b85b6,_0x5aad0c){const _0x1d2242=function(_0x31ad25){while(--_0x31ad25){_0x3b85b6['push'](_0x3b85b6['shift']());}};_0x1d2242(++_0x5aad0c);}(a375_0x5aad,0x1b4));const a375_0x1d22=function(_0x3b85b6,_0x5aad0c){_0x3b85b6=_0x3b85b6-0x0;let _0x1d2242=a375_0x5aad[_0x3b85b6];return _0x1d2242;};const _0x3cfa97=a375_0x1d22;'use strict';const attributes=require(_0x3cfa97('0x2'));module[_0x3cfa97('0x1')]=function(_0x31ad25){const _0x264738=_0x3cfa97,_0x282021=_0x31ad25[_0x264738('0x3')]('JscriptyAnswerReport',attributes,{'tableName':_0x264738('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x282021;}; \ No newline at end of file +const a375_0x1bb2=['report_jscripty_answers','./jscriptyAnswerReport.attributes','define','JscriptyAnswerReport','exports'];(function(_0xb6d40f,_0x1bb21e){const _0x589ba3=function(_0x4a8e19){while(--_0x4a8e19){_0xb6d40f['push'](_0xb6d40f['shift']());}};_0x589ba3(++_0x1bb21e);}(a375_0x1bb2,0x13e));const a375_0x589b=function(_0xb6d40f,_0x1bb21e){_0xb6d40f=_0xb6d40f-0x0;let _0x589ba3=a375_0x1bb2[_0xb6d40f];return _0x589ba3;};const _0x56b6df=a375_0x589b;'use strict';const attributes=require(_0x56b6df('0x3'));module[_0x56b6df('0x1')]=function(_0x4a8e19){const _0x14b07a=_0x56b6df,_0x1b3fe6=_0x4a8e19[_0x14b07a('0x4')](_0x14b07a('0x0'),attributes,{'tableName':_0x14b07a('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1b3fe6;}; \ No newline at end of file diff --git a/server/api/jscriptyProject/index.js b/server/api/jscriptyProject/index.js index 790f095..2d0dbca 100644 --- a/server/api/jscriptyProject/index.js +++ b/server/api/jscriptyProject/index.js @@ -1 +1 @@ -const a376_0x1c5b=['update','Router','exports','put','30s','post','getSummary','create','getAnswers','clone','/:id','express','./jscriptyProject.controller','get','delete','connect-timeout','show','isAuthenticated','/:id/summary','index','../../components/auth/service','/:id/answers'];(function(_0x543e45,_0x1c5b4f){const _0x1c2011=function(_0x323ee1){while(--_0x323ee1){_0x543e45['push'](_0x543e45['shift']());}};_0x1c2011(++_0x1c5b4f);}(a376_0x1c5b,0xd2));const a376_0x1c20=function(_0x543e45,_0x1c5b4f){_0x543e45=_0x543e45-0x0;let _0x1c2011=a376_0x1c5b[_0x543e45];return _0x1c2011;};const _0x45d2d0=a376_0x1c20;'use strict';const timeout=require(_0x45d2d0('0x3')),express=require(_0x45d2d0('0x15')),router=express[_0x45d2d0('0xb')](),auth=require(_0x45d2d0('0x8')),controller=require(_0x45d2d0('0x0'));router[_0x45d2d0('0x1')]('/',auth['isAuthenticated'](),controller[_0x45d2d0('0x7')]),router['get']('/:id',auth[_0x45d2d0('0x5')](),controller[_0x45d2d0('0x4')]),router['get']('/:id/sessions',auth[_0x45d2d0('0x5')](),controller['getSessions']),router[_0x45d2d0('0x1')](_0x45d2d0('0x9'),auth[_0x45d2d0('0x5')](),controller[_0x45d2d0('0x12')]),router[_0x45d2d0('0x1')](_0x45d2d0('0x6'),auth[_0x45d2d0('0x5')](),timeout(_0x45d2d0('0xe')),controller[_0x45d2d0('0x10')]),router[_0x45d2d0('0xf')]('/',auth[_0x45d2d0('0x5')](),controller[_0x45d2d0('0x11')]),router['post']('/:id/clone',auth[_0x45d2d0('0x5')](),controller[_0x45d2d0('0x13')]),router[_0x45d2d0('0xd')]('/:id',auth[_0x45d2d0('0x5')](),controller[_0x45d2d0('0xa')]),router[_0x45d2d0('0x2')](_0x45d2d0('0x14'),auth['isAuthenticated'](),controller['destroy']),module[_0x45d2d0('0xc')]=router; \ No newline at end of file +const a376_0x2325=['/:id','../../components/auth/service','connect-timeout','/:id/sessions','destroy','express','isAuthenticated','get','put','show','/:id/answers','/:id/clone','getAnswers','getSummary','getSessions','30s','Router','/:id/summary','create','clone','delete','post'];(function(_0x2e9ffc,_0x2325d8){const _0x6aa96e=function(_0x2a0ba5){while(--_0x2a0ba5){_0x2e9ffc['push'](_0x2e9ffc['shift']());}};_0x6aa96e(++_0x2325d8);}(a376_0x2325,0x66));const a376_0x6aa9=function(_0x2e9ffc,_0x2325d8){_0x2e9ffc=_0x2e9ffc-0x0;let _0x6aa96e=a376_0x2325[_0x2e9ffc];return _0x6aa96e;};const _0x1d0d51=a376_0x6aa9;'use strict';const timeout=require(_0x1d0d51('0xa')),express=require(_0x1d0d51('0xd')),router=express[_0x1d0d51('0x2')](),auth=require(_0x1d0d51('0x9')),controller=require('./jscriptyProject.controller');router[_0x1d0d51('0xf')]('/',auth[_0x1d0d51('0xe')](),controller['index']),router[_0x1d0d51('0xf')](_0x1d0d51('0x8'),auth['isAuthenticated'](),controller[_0x1d0d51('0x11')]),router['get'](_0x1d0d51('0xb'),auth[_0x1d0d51('0xe')](),controller[_0x1d0d51('0x0')]),router['get'](_0x1d0d51('0x12'),auth[_0x1d0d51('0xe')](),controller[_0x1d0d51('0x14')]),router['get'](_0x1d0d51('0x3'),auth[_0x1d0d51('0xe')](),timeout(_0x1d0d51('0x1')),controller[_0x1d0d51('0x15')]),router[_0x1d0d51('0x7')]('/',auth[_0x1d0d51('0xe')](),controller[_0x1d0d51('0x4')]),router[_0x1d0d51('0x7')](_0x1d0d51('0x13'),auth[_0x1d0d51('0xe')](),controller[_0x1d0d51('0x5')]),router[_0x1d0d51('0x10')](_0x1d0d51('0x8'),auth[_0x1d0d51('0xe')](),controller['update']),router[_0x1d0d51('0x6')](_0x1d0d51('0x8'),auth[_0x1d0d51('0xe')](),controller[_0x1d0d51('0xc')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/jscriptyProject/jscriptyProject.attributes.js b/server/api/jscriptyProject/jscriptyProject.attributes.js index b027a40..ade9daa 100644 --- a/server/api/jscriptyProject/jscriptyProject.attributes.js +++ b/server/api/jscriptyProject/jscriptyProject.attributes.js @@ -1 +1 @@ -const a377_0x5ed7=['format','lodash','STRING','BOOLEAN','formData','getDataValue','exports','setDataValue','long','name','sequelize','{\x22name\x22:\x22%s\x22,\x22description\x22:\x22%s\x22,\x22pages\x22:[]}','isString','TEXT','util','isObjectLike'];(function(_0x561a83,_0x5ed7d9){const _0x8f97e9=function(_0x1f3f1f){while(--_0x1f3f1f){_0x561a83['push'](_0x561a83['shift']());}};_0x8f97e9(++_0x5ed7d9);}(a377_0x5ed7,0x107));const a377_0x8f97=function(_0x561a83,_0x5ed7d9){_0x561a83=_0x561a83-0x0;let _0x8f97e9=a377_0x5ed7[_0x561a83];return _0x8f97e9;};const _0xd1d75f=a377_0x8f97;'use strict';const Sequelize=require(_0xd1d75f('0x3')),_=require(_0xd1d75f('0xa')),util=require(_0xd1d75f('0x7'));module[_0xd1d75f('0xf')]={'name':{'type':Sequelize[_0xd1d75f('0xb')],'unique':_0xd1d75f('0x2')},'description':{'type':Sequelize[_0xd1d75f('0xb')]},'formData':{'type':Sequelize[_0xd1d75f('0x6')](_0xd1d75f('0x1')),'set':function(_0x1f3f1f){const _0xf1335b=_0xd1d75f;if(_[_0xf1335b('0x8')](_0x1f3f1f))this[_0xf1335b('0x0')](_0xf1335b('0xd'),JSON['stringify'](_0x1f3f1f));else _[_0xf1335b('0x5')](_0x1f3f1f)?this[_0xf1335b('0x0')](_0xf1335b('0xd'),_0x1f3f1f):this['setDataValue'](_0xf1335b('0xd'),util[_0xf1335b('0x9')](_0xf1335b('0x4'),this[_0xf1335b('0xe')](_0xf1335b('0x2'))||'',this[_0xf1335b('0xe')]('description')||''));}},'enableUncompleteSave':{'type':Sequelize[_0xd1d75f('0xc')],'defaultValue':!![]},'sendUnpauseOnSubmit':{'type':Sequelize[_0xd1d75f('0xc')],'defaultValue':![]}}; \ No newline at end of file +const a377_0xd448=['isObjectLike','long','sequelize','STRING','getDataValue','isString','exports','BOOLEAN','formData','{\x22name\x22:\x22%s\x22,\x22description\x22:\x22%s\x22,\x22pages\x22:[]}','lodash','stringify','util','description','name','setDataValue','format'];(function(_0x450098,_0xd4486f){const _0x19b015=function(_0x4ad3f6){while(--_0x4ad3f6){_0x450098['push'](_0x450098['shift']());}};_0x19b015(++_0xd4486f);}(a377_0xd448,0x1a9));const a377_0x19b0=function(_0x450098,_0xd4486f){_0x450098=_0x450098-0x0;let _0x19b015=a377_0xd448[_0x450098];return _0x19b015;};const _0x4be53a=a377_0x19b0;'use strict';const Sequelize=require(_0x4be53a('0x2')),_=require(_0x4be53a('0xa')),util=require(_0x4be53a('0xc'));module[_0x4be53a('0x6')]={'name':{'type':Sequelize[_0x4be53a('0x3')],'unique':_0x4be53a('0xe')},'description':{'type':Sequelize[_0x4be53a('0x3')]},'formData':{'type':Sequelize['TEXT'](_0x4be53a('0x1')),'set':function(_0x4ad3f6){const _0x5dc3db=_0x4be53a;if(_[_0x5dc3db('0x0')](_0x4ad3f6))this[_0x5dc3db('0xf')](_0x5dc3db('0x8'),JSON[_0x5dc3db('0xb')](_0x4ad3f6));else _[_0x5dc3db('0x5')](_0x4ad3f6)?this[_0x5dc3db('0xf')](_0x5dc3db('0x8'),_0x4ad3f6):this[_0x5dc3db('0xf')](_0x5dc3db('0x8'),util[_0x5dc3db('0x10')](_0x5dc3db('0x9'),this[_0x5dc3db('0x4')]('name')||'',this[_0x5dc3db('0x4')](_0x5dc3db('0xd'))||''));}},'enableUncompleteSave':{'type':Sequelize[_0x4be53a('0x7')],'defaultValue':!![]},'sendUnpauseOnSubmit':{'type':Sequelize[_0x4be53a('0x7')],'defaultValue':![]}}; \ No newline at end of file diff --git a/server/api/jscriptyProject/jscriptyProject.controller.js b/server/api/jscriptyProject/jscriptyProject.controller.js index 6d3f7f5..6e55c01 100644 --- a/server/api/jscriptyProject/jscriptyProject.controller.js +++ b/server/api/jscriptyProject/jscriptyProject.controller.js @@ -1 +1 @@ -const a378_0x12dd=['index','fieldName','get','model','JscriptyProject','then','api','/tmp/Jscripty_Project_%d_Summary_%s.csv','merge','number','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','sequelize','params','clone','findOne','SessionId','Projects','writeFileSync','fields','send','omit','to-csv','undefined','answer','count','util','YYYY-MM-DD\x20HH:mm:ss','UserProfileSection','type','JscriptyAnswerReport','ProjectId','sort','../../config/logger','JscriptyQuestionReport','limit','attributes','role','JscriptySessionReport','error','filter','status','update','../../mysqldb','offset','isEmpty','toString','map','rows','format','destroy','starttime','include','filters','apply','rawAttributes','keys','questionId','attachment;\x20filename=','body','parse','set','download','length','query','startTime','setHeader','text/csv','create','question','indexOf','sendStatus','createdAt','order','findAll','../../components/parsers/qs','Content-type','getSummary','Unable\x20to\x20retrieve\x20the\x20current\x20user','name','includeAll','where','getAnswers','-createdAt','updatedAt','userProfileId','like','nolimit','end','Content-disposition','pick','replace','user','UserProfileResource','options','show','catch','intersection'];(function(_0x3d5c89,_0x12ddb1){const _0x2d6790=function(_0x282ed3){while(--_0x282ed3){_0x3d5c89['push'](_0x3d5c89['shift']());}};_0x2d6790(++_0x12ddb1);}(a378_0x12dd,0xac));const a378_0x2d67=function(_0x3d5c89,_0x12ddb1){_0x3d5c89=_0x3d5c89-0x0;let _0x2d6790=a378_0x12dd[_0x3d5c89];return _0x2d6790;};const _0x4b1d42=a378_0x2d67;'use strict';const moment=require('moment'),util=require(_0x4b1d42('0x2f')),fs=require('fs'),_=require('lodash'),toCsv=require(_0x4b1d42('0x2b')),qs=require(_0x4b1d42('0x60')),logger=require(_0x4b1d42('0x36'))(_0x4b1d42('0x1c')),db=require(_0x4b1d42('0x40'))['db'],{Op}=require(_0x4b1d42('0x21'));function respondWithResult(_0x282ed3,_0x4a7d1a){return _0x4a7d1a=_0x4a7d1a||0xc8,function(_0x42f52e){const _0x46860e=a378_0x2d67;if(_0x42f52e)return _0x282ed3[_0x46860e('0x3e')](_0x4a7d1a)['json'](_0x42f52e);};}function respondWithFilteredResult(_0x491e91,_0x2f3f04){return function(_0x44b3de){const _0x306069=a378_0x2d67;if(_0x44b3de){const _0x2fadc2=_0x44b3de[_0x306069('0x2e')],_0x3a56f7=_0x2f3f04[_0x306069('0x41')];let _0x347707=_0x2f3f04[_0x306069('0x41')]+_0x2f3f04[_0x306069('0x38')],_0x4f92c3;return _0x347707>=_0x2fadc2?(_0x347707=_0x2fadc2,_0x4f92c3=0xc8):_0x4f92c3=0xce,_0x491e91[_0x306069('0x3e')](_0x4f92c3),_0x491e91[_0x306069('0x52')]('Content-Range',_0x3a56f7+'-'+_0x347707+'/'+_0x2fadc2)['json'](_0x44b3de);}return null;};}function saveUpdates(_0x956109){return function(_0x23e50c){const _0x2fdb94=a378_0x2d67;if(_0x23e50c)return _0x23e50c[_0x2fdb94('0x3f')](_0x956109)[_0x2fdb94('0x1b')](function(_0x158a1e){return _0x158a1e;});return null;};}function removeEntity(_0x4875d2){return function(_0x14a40d){const _0x2becda=a378_0x2d67;if(_0x14a40d)return _0x14a40d[_0x2becda('0x47')]()[_0x2becda('0x1b')](function(){const _0x1650fe=_0x2becda,_0x46ff17=_0x14a40d[_0x1650fe('0x18')]({'plain':!![]}),_0xcc7e4f=_0x1650fe('0x26');return db[_0x1650fe('0x11')]['destroy']({'where':{'type':_0xcc7e4f,'resourceId':_0x46ff17['id']}})[_0x1650fe('0x1b')](function(){return _0x14a40d;});})[_0x2becda('0x1b')](function(){const _0x14f080=_0x2becda;_0x4875d2[_0x14f080('0x3e')](0xcc)[_0x14f080('0xc')]();});};}function handleEntityNotFound(_0x5b0c98){return function(_0x460c72){const _0x3149f0=a378_0x2d67;return!_0x460c72&&_0x5b0c98[_0x3149f0('0x5c')](0x194),_0x460c72;};}function handleError(_0x2fb1f6,_0x9b0354){return _0x9b0354=_0x9b0354||0x1f4,function(_0x2dfcbe){const _0x222e67=a378_0x2d67;logger['error'](_0x2dfcbe['stack']),_0x2dfcbe[_0x222e67('0x3')]&&delete _0x2dfcbe[_0x222e67('0x3')],_0x2fb1f6[_0x222e67('0x3e')](_0x9b0354)[_0x222e67('0x29')](_0x2dfcbe);};}exports[_0x4b1d42('0x16')]=function(_0x5d67e7,_0x3c85ff){const _0x1fd980=_0x4b1d42;let _0x4c5c3f={};const _0x99a72d={},_0x29a62c={'count':0x0,'rows':[]},_0x436414=_[_0x1fd980('0x44')](db[_0x1fd980('0x1a')]['rawAttributes'],function(_0x569ecc){const _0x2c0dc2=_0x1fd980;return{'name':_0x569ecc[_0x2c0dc2('0x17')],'type':_0x569ecc[_0x2c0dc2('0x32')]['key']};});_0x99a72d[_0x1fd980('0x19')]=_[_0x1fd980('0x44')](_0x436414,_0x1fd980('0x3')),_0x99a72d[_0x1fd980('0x55')]=_[_0x1fd980('0x4d')](_0x5d67e7['query']),_0x99a72d[_0x1fd980('0x4a')]=_[_0x1fd980('0x15')](_0x99a72d[_0x1fd980('0x19')],_0x99a72d[_0x1fd980('0x55')]),_0x4c5c3f[_0x1fd980('0x39')]=_[_0x1fd980('0x15')](_0x99a72d[_0x1fd980('0x19')],qs['fields'](_0x5d67e7[_0x1fd980('0x55')][_0x1fd980('0x28')])),_0x4c5c3f[_0x1fd980('0x39')]=_0x4c5c3f[_0x1fd980('0x39')][_0x1fd980('0x54')]?_0x4c5c3f['attributes']:_0x99a72d[_0x1fd980('0x19')];typeof _0x5d67e7['query'][_0x1fd980('0xb')]===_0x1fd980('0x2c')&&(_0x4c5c3f[_0x1fd980('0x38')]=qs[_0x1fd980('0x38')](_0x5d67e7['query'][_0x1fd980('0x38')]),_0x4c5c3f[_0x1fd980('0x41')]=qs[_0x1fd980('0x41')](_0x5d67e7['query'][_0x1fd980('0x41')]));_0x4c5c3f['order']=qs[_0x1fd980('0x35')](_0x5d67e7[_0x1fd980('0x55')][_0x1fd980('0x35')]),_0x4c5c3f[_0x1fd980('0x5')]=qs[_0x1fd980('0x4a')](_[_0x1fd980('0xe')](_0x5d67e7[_0x1fd980('0x55')],_0x99a72d[_0x1fd980('0x4a')]),_0x436414);_0x5d67e7['query']['filter']&&(_0x4c5c3f['where']=_[_0x1fd980('0x1e')](_0x4c5c3f['where'],{[Op['or']]:_['map'](_0x436414,function(_0x7e8d6){const _0x4511e1=_0x1fd980;if(_0x7e8d6['type']!=='VIRTUAL'){const _0x556ab6={};return _0x556ab6[_0x7e8d6['name']]={[Op[_0x4511e1('0xa')]]:'%'+_0x5d67e7[_0x4511e1('0x55')]['filter']+'%'},_0x556ab6;}})}));_0x4c5c3f=_[_0x1fd980('0x1e')]({},_0x4c5c3f,_0x5d67e7[_0x1fd980('0x12')]);const _0x5061c6={'where':_0x4c5c3f[_0x1fd980('0x5')]};return db[_0x1fd980('0x1a')][_0x1fd980('0x2e')](_0x5061c6)[_0x1fd980('0x1b')](function(_0x144378){const _0x508e18=_0x1fd980;return _0x29a62c[_0x508e18('0x2e')]=_0x144378,_0x5d67e7[_0x508e18('0x55')][_0x508e18('0x4')]&&(_0x4c5c3f[_0x508e18('0x49')]=[{'all':!![]}]),db[_0x508e18('0x1a')][_0x508e18('0x5f')](_0x4c5c3f);})['then'](function(_0x27b0ca){const _0x17f3a7=_0x1fd980;return _0x29a62c[_0x17f3a7('0x45')]=_0x27b0ca,_0x29a62c;})[_0x1fd980('0x1b')](respondWithFilteredResult(_0x3c85ff,_0x4c5c3f))[_0x1fd980('0x14')](handleError(_0x3c85ff,null));},exports[_0x4b1d42('0x13')]=function(_0x21e207,_0x2fcc2c){const _0x16c387=_0x4b1d42;let _0x41ffee={'raw':![],'where':{'id':_0x21e207['params']['id']}};const _0x1b54d9={};return _0x1b54d9['model']=_[_0x16c387('0x4d')](db[_0x16c387('0x1a')][_0x16c387('0x4c')]),_0x1b54d9[_0x16c387('0x55')]=_['keys'](_0x21e207[_0x16c387('0x55')]),_0x1b54d9[_0x16c387('0x4a')]=_['intersection'](_0x1b54d9[_0x16c387('0x19')],_0x1b54d9['query']),_0x41ffee[_0x16c387('0x39')]=_[_0x16c387('0x15')](_0x1b54d9['model'],qs[_0x16c387('0x28')](_0x21e207[_0x16c387('0x55')]['fields'])),_0x41ffee[_0x16c387('0x39')]=_0x41ffee['attributes'][_0x16c387('0x54')]?_0x41ffee[_0x16c387('0x39')]:_0x1b54d9['model'],_0x21e207[_0x16c387('0x55')][_0x16c387('0x4')]&&(_0x41ffee['include']=[{'all':!![]}]),_0x41ffee=_[_0x16c387('0x1e')]({},_0x41ffee,_0x21e207[_0x16c387('0x12')]),db[_0x16c387('0x1a')]['findOne'](_0x41ffee)[_0x16c387('0x1b')](handleEntityNotFound(_0x2fcc2c,null))['then'](respondWithResult(_0x2fcc2c,null))[_0x16c387('0x14')](handleError(_0x2fcc2c,null));},exports[_0x4b1d42('0x59')]=function(_0x16d856,_0x29be24){const _0x2f67ac=_0x4b1d42;return db['JscriptyProject']['create'](_0x16d856[_0x2f67ac('0x50')],{})[_0x2f67ac('0x1b')](function(_0x12af12){const _0x5ef8cb=_0x2f67ac,_0x4e611d=_0x16d856['user']['get']({'plain':!![]});if(!_0x4e611d)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x4e611d[_0x5ef8cb('0x3a')]==='user'){const _0x470bee=_0x12af12['get']({'plain':!![]}),_0xee3ee7='Projects';return db[_0x5ef8cb('0x31')][_0x5ef8cb('0x24')]({'where':{'name':_0xee3ee7,'userProfileId':_0x4e611d[_0x5ef8cb('0x9')]},'raw':!![]})['then'](function(_0x57b668){const _0x4a65d8=_0x5ef8cb;return _0x57b668&&_0x57b668['autoAssociation']===0x0?db[_0x4a65d8('0x11')][_0x4a65d8('0x59')]({'name':_0x470bee[_0x4a65d8('0x3')],'resourceId':_0x470bee['id'],'type':_0x57b668['name'],'sectionId':_0x57b668['id']},{})['then'](function(){return _0x12af12;}):_0x12af12;})[_0x5ef8cb('0x14')](function(_0x4dc4b9){const _0x4b7278=_0x5ef8cb;logger[_0x4b7278('0x3c')](_0x4b7278('0x20'),_0x4dc4b9);throw _0x4dc4b9;});}return _0x12af12;})[_0x2f67ac('0x1b')](respondWithResult(_0x29be24,0xc9))[_0x2f67ac('0x14')](handleError(_0x29be24,null));},exports[_0x4b1d42('0x23')]=function(_0x4c11da,_0x191401){const _0x336ddf=_0x4b1d42;let _0x3d757d={'where':{'id':_0x4c11da['params']['id']}};const _0x12fa94={};return _0x12fa94['model']=_[_0x336ddf('0x4d')](db['JscriptyProject'][_0x336ddf('0x4c')]),_0x3d757d['attributes']=_['intersection'](_0x12fa94['model'],qs[_0x336ddf('0x28')](_0x4c11da['query']['fields'])),_0x3d757d['attributes']=_0x3d757d['attributes'][_0x336ddf('0x54')]?_0x3d757d[_0x336ddf('0x39')]:_0x12fa94[_0x336ddf('0x19')],_0x4c11da[_0x336ddf('0x55')]['includeAll']&&(_0x3d757d[_0x336ddf('0x49')]=[{'all':!![]}]),_0x3d757d=_['merge']({},_0x3d757d,_0x4c11da[_0x336ddf('0x12')]),db[_0x336ddf('0x1a')][_0x336ddf('0x24')](_0x3d757d)['then'](handleEntityNotFound(_0x191401,null))[_0x336ddf('0x1b')](function(_0x51a652){const _0x1954ca=_0x336ddf;if(_0x51a652){let _0x4fbec1=_0x51a652['get']({'plain':!![]});return _0x4fbec1=qs[_0x1954ca('0x2a')](_0x4fbec1,['id',_0x1954ca('0x5d'),_0x1954ca('0x8')]),_0x4c11da[_0x1954ca('0x50')]=_[_0x1954ca('0x2a')](_0x4c11da[_0x1954ca('0x50')],['id',_0x1954ca('0x5d'),_0x1954ca('0x8')]),db[_0x1954ca('0x1a')][_0x1954ca('0x59')](_[_0x1954ca('0x1e')](_0x4fbec1,_0x4c11da[_0x1954ca('0x50')]),{'include':_0x4c11da[_0x1954ca('0x55')][_0x1954ca('0x4')]?[{'all':!![]}]:undefined})[_0x1954ca('0x1b')](function(_0x331ee4){const _0xb81b2f=_0x1954ca,_0x106890=_0x4c11da[_0xb81b2f('0x10')]['get']({'plain':!![]});if(!_0x106890)throw new Error(_0xb81b2f('0x2'));if(_0x106890[_0xb81b2f('0x3a')]===_0xb81b2f('0x10')){const _0x48bb67=_0x331ee4['get']({'plain':!![]}),_0x78f0a=_0xb81b2f('0x26');return db[_0xb81b2f('0x31')][_0xb81b2f('0x24')]({'where':{'name':_0x78f0a,'userProfileId':_0x106890[_0xb81b2f('0x9')]},'raw':!![]})[_0xb81b2f('0x1b')](function(_0x43acd7){const _0x5c5232=_0xb81b2f;return _0x43acd7&&_0x43acd7['autoAssociation']===0x0?db[_0x5c5232('0x11')][_0x5c5232('0x59')]({'name':_0x48bb67[_0x5c5232('0x3')],'resourceId':_0x48bb67['id'],'type':_0x43acd7[_0x5c5232('0x3')],'sectionId':_0x43acd7['id']},{})['then'](function(){return _0x331ee4;}):_0x331ee4;})[_0xb81b2f('0x14')](function(_0x2b6ce5){const _0x42a52e=_0xb81b2f;logger[_0x42a52e('0x3c')](_0x42a52e('0x20'),_0x2b6ce5);throw _0x2b6ce5;});}return _0x331ee4;});}})[_0x336ddf('0x1b')](respondWithResult(_0x191401,0xc9))[_0x336ddf('0x14')](handleError(_0x191401,null));},exports[_0x4b1d42('0x3f')]=function(_0x224343,_0x4ed993){const _0x175b53=_0x4b1d42;return _0x224343[_0x175b53('0x50')]['id']&&delete _0x224343[_0x175b53('0x50')]['id'],db[_0x175b53('0x1a')][_0x175b53('0x24')]({'where':{'id':_0x224343[_0x175b53('0x22')]['id']}})[_0x175b53('0x1b')](handleEntityNotFound(_0x4ed993,null))[_0x175b53('0x1b')](saveUpdates(_0x224343['body'],null))['then'](respondWithResult(_0x4ed993,null))[_0x175b53('0x14')](handleError(_0x4ed993,null));},exports[_0x4b1d42('0x47')]=function(_0x38ea5b,_0x34e67c){const _0x4745e4=_0x4b1d42;return db[_0x4745e4('0x1a')][_0x4745e4('0x24')]({'where':{'id':_0x38ea5b[_0x4745e4('0x22')]['id']}})[_0x4745e4('0x1b')](handleEntityNotFound(_0x34e67c,null))[_0x4745e4('0x1b')](removeEntity(_0x34e67c,null))[_0x4745e4('0x14')](handleError(_0x34e67c,null));},exports['getSessions']=function(_0x41efdb,_0x52a5e9){const _0x17dd18=_0x4b1d42;let _0x5a60c8={'raw':!![],'where':{}};const _0x27b0b1={},_0x4f42e2={'count':0x0,'rows':[]};return db['JscriptyProject'][_0x17dd18('0x24')]({'where':{'id':_0x41efdb[_0x17dd18('0x22')]['id']}})[_0x17dd18('0x1b')](handleEntityNotFound(_0x52a5e9,null))[_0x17dd18('0x1b')](function(_0x57ed23){const _0x4869f9=_0x17dd18;if(_0x57ed23)return _0x27b0b1[_0x4869f9('0x19')]=_[_0x4869f9('0x4d')](db[_0x4869f9('0x3b')]['rawAttributes']),_0x27b0b1['query']=_[_0x4869f9('0x4d')](_0x41efdb[_0x4869f9('0x55')]),_0x27b0b1['filters']=_[_0x4869f9('0x15')](_0x27b0b1['model'],_0x27b0b1['query']),_0x5a60c8['attributes']=_[_0x4869f9('0x15')](_0x27b0b1[_0x4869f9('0x19')],qs[_0x4869f9('0x28')](_0x41efdb[_0x4869f9('0x55')]['fields'])),_0x5a60c8[_0x4869f9('0x39')]=_0x5a60c8['attributes']['length']?_0x5a60c8[_0x4869f9('0x39')]:_0x27b0b1[_0x4869f9('0x19')],typeof _0x41efdb['query']['nolimit']===_0x4869f9('0x2c')&&(_0x5a60c8[_0x4869f9('0x38')]=qs[_0x4869f9('0x38')](_0x41efdb['query'][_0x4869f9('0x38')]),_0x5a60c8['offset']=qs['offset'](_0x41efdb[_0x4869f9('0x55')][_0x4869f9('0x41')])),_0x5a60c8[_0x4869f9('0x5e')]=qs[_0x4869f9('0x35')](_0x41efdb[_0x4869f9('0x55')][_0x4869f9('0x35')]),_0x5a60c8[_0x4869f9('0x5')]=qs[_0x4869f9('0x4a')](_['pick'](_0x41efdb[_0x4869f9('0x55')],_0x27b0b1[_0x4869f9('0x4a')])),_0x5a60c8['where'][_0x4869f9('0x34')]=_0x57ed23['id'],_0x41efdb[_0x4869f9('0x55')][_0x4869f9('0x3d')]&&(_0x5a60c8[_0x4869f9('0x5')]=_[_0x4869f9('0x1e')](_0x5a60c8[_0x4869f9('0x5')],{[Op['or']]:_['map'](_0x5a60c8[_0x4869f9('0x39')],function(_0x1e345d){const _0x364f9f=_0x4869f9,_0x24d593={};return _0x24d593[_0x1e345d]={[Op[_0x364f9f('0xa')]]:'%'+_0x41efdb['query'][_0x364f9f('0x3d')]+'%'},_0x24d593;})})),_0x5a60c8=_[_0x4869f9('0x1e')]({},_0x5a60c8,_0x41efdb[_0x4869f9('0x12')]),db[_0x4869f9('0x3b')]['count']({'where':_0x5a60c8[_0x4869f9('0x5')]})[_0x4869f9('0x1b')](function(_0x1a0ace){const _0x164963=_0x4869f9;return _0x4f42e2[_0x164963('0x2e')]=_0x1a0ace,_0x41efdb[_0x164963('0x55')][_0x164963('0x4')]&&(_0x5a60c8[_0x164963('0x49')]=[{'all':!![]}]),db[_0x164963('0x3b')][_0x164963('0x5f')](_0x5a60c8);})[_0x4869f9('0x1b')](function(_0x22c64d){return _0x4f42e2['rows']=_0x22c64d,_0x4f42e2;});})[_0x17dd18('0x1b')](respondWithFilteredResult(_0x52a5e9,_0x5a60c8))[_0x17dd18('0x14')](handleError(_0x52a5e9,null));},exports[_0x4b1d42('0x6')]=function(_0x5a1443,_0x1084eb){const _0x1e87c2=_0x4b1d42;let _0x2a0b96={'raw':!![],'where':{}};const _0x1e8641={},_0x213ed7={'count':0x0,'rows':[]};return db[_0x1e87c2('0x1a')][_0x1e87c2('0x24')]({'where':{'id':_0x5a1443[_0x1e87c2('0x22')]['id']}})['then'](handleEntityNotFound(_0x1084eb,null))['then'](function(_0x553834){const _0x4e8591=_0x1e87c2;if(_0x553834)return _0x1e8641[_0x4e8591('0x19')]=_['keys'](db[_0x4e8591('0x33')][_0x4e8591('0x4c')]),_0x1e8641[_0x4e8591('0x55')]=_['keys'](_0x5a1443[_0x4e8591('0x55')]),_0x1e8641[_0x4e8591('0x4a')]=_['intersection'](_0x1e8641[_0x4e8591('0x19')],_0x1e8641[_0x4e8591('0x55')]),_0x2a0b96[_0x4e8591('0x39')]=_[_0x4e8591('0x15')](_0x1e8641[_0x4e8591('0x19')],qs[_0x4e8591('0x28')](_0x5a1443['query'][_0x4e8591('0x28')])),_0x2a0b96['attributes']=_0x2a0b96[_0x4e8591('0x39')][_0x4e8591('0x54')]?_0x2a0b96[_0x4e8591('0x39')]:_0x1e8641[_0x4e8591('0x19')],typeof _0x5a1443[_0x4e8591('0x55')]['nolimit']===_0x4e8591('0x2c')&&(_0x2a0b96[_0x4e8591('0x38')]=qs['limit'](_0x5a1443[_0x4e8591('0x55')][_0x4e8591('0x38')]),_0x2a0b96[_0x4e8591('0x41')]=qs[_0x4e8591('0x41')](_0x5a1443[_0x4e8591('0x55')][_0x4e8591('0x41')])),_0x2a0b96[_0x4e8591('0x5e')]=qs[_0x4e8591('0x35')](_0x5a1443[_0x4e8591('0x55')][_0x4e8591('0x35')]),_0x2a0b96[_0x4e8591('0x5')]=qs[_0x4e8591('0x4a')](_[_0x4e8591('0xe')](_0x5a1443[_0x4e8591('0x55')],_0x1e8641[_0x4e8591('0x4a')])),_0x2a0b96[_0x4e8591('0x5')][_0x4e8591('0x34')]=_0x553834['id'],_0x5a1443[_0x4e8591('0x55')][_0x4e8591('0x3d')]&&(_0x2a0b96['where']=_[_0x4e8591('0x1e')](_0x2a0b96['where'],{[Op['or']]:_['map'](_0x2a0b96['attributes'],function(_0x42b610){const _0x57ff0b=_0x4e8591,_0x1fa9e2={};return _0x1fa9e2[_0x42b610]={[Op[_0x57ff0b('0xa')]]:'%'+_0x5a1443['query']['filter']+'%'},_0x1fa9e2;})})),_0x2a0b96=_[_0x4e8591('0x1e')]({},_0x2a0b96,_0x5a1443[_0x4e8591('0x12')]),db[_0x4e8591('0x33')]['count']({'where':_0x2a0b96[_0x4e8591('0x5')]})[_0x4e8591('0x1b')](function(_0x193c59){const _0x4d8ae3=_0x4e8591;return _0x213ed7[_0x4d8ae3('0x2e')]=_0x193c59,_0x5a1443[_0x4d8ae3('0x55')]['includeAll']&&(_0x2a0b96[_0x4d8ae3('0x49')]=[{'all':!![]}]),db[_0x4d8ae3('0x33')]['findAll'](_0x2a0b96);})['then'](function(_0x323a9c){return _0x213ed7['rows']=_0x323a9c,_0x213ed7;});})[_0x1e87c2('0x1b')](respondWithFilteredResult(_0x1084eb,_0x2a0b96))['catch'](handleError(_0x1084eb,null));};function char(_0x3e461c){const _0x204728=_0x4b1d42;return _0x204728('0x1f')===typeof _0x3e461c?String['fromCharCode'][_0x204728('0x4b')](null,arguments):_0x3e461c;}function needsEncapsulation(_0x1b1aae){const _0x36fc30=_0x4b1d42;return!!_0x1b1aae&&(_0x1b1aae[_0x36fc30('0x43')]()['indexOf'](char(0xd))>=0x0||_0x1b1aae['toString']()[_0x36fc30('0x5b')](char(0xa))>=0x0||_0x1b1aae['toString']()[_0x36fc30('0x5b')](char(0x2c))>=0x0||_0x1b1aae[_0x36fc30('0x43')]()['indexOf'](char(0x22))>=0x0);}function encapsulate(_0x43d725){const _0x28e1d8=_0x4b1d42,_0x1cbad3=char(0x22),_0x11097a='\x5c'+char(0x22),_0x1b0d56=_0x43d725[_0x28e1d8('0x43')]()[_0x28e1d8('0xf')](new RegExp(_0x1cbad3,'g'),_0x11097a);return _0x1cbad3+_0x1b0d56+_0x1cbad3;}exports[_0x4b1d42('0x1')]=function(_0x461d4f,_0x4c5388){const _0xfbe261=_0x4b1d42;let _0x783e45,_0x2c9387;const _0x2b8a18={'where':{'ProjectId':_0x461d4f[_0xfbe261('0x22')]['id']}};return _0x461d4f[_0xfbe261('0x55')][_0xfbe261('0x56')]&&(_0x2b8a18[_0xfbe261('0x5')][_0xfbe261('0x48')]=JSON[_0xfbe261('0x51')](_0x461d4f[_0xfbe261('0x55')][_0xfbe261('0x56')])),db['JscriptySessionReport'][_0xfbe261('0x5f')](_0x2b8a18)['then'](handleEntityNotFound(_0x4c5388,null))[_0xfbe261('0x1b')](function(_0x503438){const _0x30f5c3=_0xfbe261;if(_0x503438)return _0x783e45=_0x503438,db[_0x30f5c3('0x37')][_0x30f5c3('0x5f')]({'where':{'SessionId':{[Op['in']]:_[_0x30f5c3('0x44')](_0x783e45,'id')},'ProjectId':_0x461d4f[_0x30f5c3('0x22')]['id']},'order':_0x30f5c3('0x7')});})['then'](handleEntityNotFound(_0x4c5388,null))[_0xfbe261('0x1b')](function(_0x13c29d){const _0x16c8f6=_0xfbe261;if(_0x13c29d){_0x2c9387=_0x13c29d;const _0x5abac9={};for(let _0xf47045=0x0,_0x3d4782=_0x2c9387[_0x16c8f6('0x54')];_0xf47045<_0x3d4782;_0xf47045++){typeof _0x5abac9[_0x2c9387[_0xf47045][_0x16c8f6('0x4e')]]===_0x16c8f6('0x2c')&&(_0x5abac9[_0x2c9387[_0xf47045][_0x16c8f6('0x4e')]]=needsEncapsulation(_0x2c9387[_0xf47045][_0x16c8f6('0x5a')])?encapsulate(_0x2c9387[_0xf47045][_0x16c8f6('0x5a')]):_0x2c9387[_0xf47045][_0x16c8f6('0x5a')]);}const _0x1fb622=[];let _0x1a9d5f={};for(let _0x3775df=0x0,_0x5b3eb4=_0x783e45[_0x16c8f6('0x54')];_0x3775df<_0x5b3eb4;_0x3775df++){_0x1a9d5f={'ProjectId':_0x461d4f[_0x16c8f6('0x22')]['id'],'SessionId':_0x783e45[_0x3775df]['id'],'StartTime':moment(_0x783e45[_0x3775df][_0x16c8f6('0x48')])[_0x16c8f6('0x46')](_0x16c8f6('0x30'))};for(let _0x372dbd=0x0,_0x3336fb=_0x2c9387[_0x16c8f6('0x54')];_0x372dbd<_0x3336fb;_0x372dbd++){_0x2c9387[_0x372dbd][_0x16c8f6('0x25')]===_0x783e45[_0x3775df]['id']&&typeof _0x5abac9[_0x2c9387[_0x372dbd][_0x16c8f6('0x4e')]]!==_0x16c8f6('0x2c')&&(_0x1a9d5f[_0x5abac9[_0x2c9387[_0x372dbd]['questionId']]]=_0x2c9387[_0x372dbd][_0x16c8f6('0x2d')]);}for(const _0x1e42e8 in _0x5abac9){typeof _0x1a9d5f[_0x5abac9[_0x1e42e8]]===_0x16c8f6('0x2c')&&(_0x1a9d5f[_0x5abac9[_0x1e42e8]]=null);}_0x1fb622['push'](_0x1a9d5f);}return _0x1fb622;}})[_0xfbe261('0x1b')](function(_0x25d2e0){const _0x1aaf3f=_0xfbe261;if(!_[_0x1aaf3f('0x42')](_0x25d2e0)){const _0x5eae29=toCsv(_0x25d2e0),_0x5e08f4=Date['now']();return fs[_0x1aaf3f('0x27')](util['format'](_0x1aaf3f('0x1d'),_0x461d4f[_0x1aaf3f('0x22')]['id'],_0x5e08f4),_0x5eae29),_0x4c5388[_0x1aaf3f('0x57')](_0x1aaf3f('0xd'),_0x1aaf3f('0x4f')+util['format']('Jscripty_Project_%d_Summary_%s.csv',_0x461d4f['params']['id'],_0x5e08f4)),_0x4c5388[_0x1aaf3f('0x57')](_0x1aaf3f('0x0'),_0x1aaf3f('0x58')),_0x4c5388[_0x1aaf3f('0x53')](util[_0x1aaf3f('0x46')]('/tmp/Jscripty_Project_%d_Summary_%s.csv',_0x461d4f[_0x1aaf3f('0x22')]['id'],_0x5e08f4));}else return _0x4c5388[_0x1aaf3f('0x5c')](0xcc);})[_0xfbe261('0x14')](handleError(_0x4c5388,null));}; \ No newline at end of file +const a378_0x4b19=['role','attributes','JscriptyProject','sort','setHeader','isEmpty','name','json','startTime','options','rawAttributes','count','userProfileId','order','keys','JscriptySessionReport','then','writeFileSync','end','Unable\x20to\x20retrieve\x20the\x20current\x20user','../../components/parsers/qs','merge','parse','length','sequelize','toString','apply','question','create','status','like','filter','findOne','omit','offset','key','include','text/csv','/tmp/Jscripty_Project_%d_Summary_%s.csv','updatedAt','questionId','getAnswers','where','indexOf','destroy','undefined','JscriptyAnswerReport','fields','clone','intersection','autoAssociation','map','VIRTUAL','Content-disposition','Jscripty_Project_%d_Summary_%s.csv','params','findAll','get','YYYY-MM-DD\x20HH:mm:ss','format','UserProfileResource','filters','fromCharCode','replace','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','error','../../config/logger','show','lodash','Content-type','type','limit','api','stack','answer','includeAll','starttime','pick','nolimit','getSessions','Projects','catch','getSummary','model','SessionId','JscriptyQuestionReport','user','to-csv','UserProfileSection','index','fieldName','body','../../mysqldb','rows','push','query','createdAt','attachment;\x20filename=','Content-Range','ProjectId','sendStatus'];(function(_0x50d3e3,_0x4b19d1){const _0x4d0936=function(_0x4a1ee0){while(--_0x4a1ee0){_0x50d3e3['push'](_0x50d3e3['shift']());}};_0x4d0936(++_0x4b19d1);}(a378_0x4b19,0x12f));const a378_0x4d09=function(_0x50d3e3,_0x4b19d1){_0x50d3e3=_0x50d3e3-0x0;let _0x4d0936=a378_0x4b19[_0x50d3e3];return _0x4d0936;};const _0x1f979b=a378_0x4d09;'use strict';const moment=require('moment'),util=require('util'),fs=require('fs'),_=require(_0x1f979b('0x44')),toCsv=require(_0x1f979b('0x57')),qs=require(_0x1f979b('0x14')),logger=require(_0x1f979b('0x42'))(_0x1f979b('0x48')),db=require(_0x1f979b('0x5c'))['db'],{Op}=require(_0x1f979b('0x18'));function respondWithResult(_0x4a1ee0,_0x4075c1){return _0x4075c1=_0x4075c1||0xc8,function(_0x2985e4){const _0x2b7469=a378_0x4d09;if(_0x2985e4)return _0x4a1ee0[_0x2b7469('0x1d')](_0x4075c1)['json'](_0x2985e4);};}function respondWithFilteredResult(_0x1afe64,_0x1431e1){return function(_0x360690){const _0x15e154=a378_0x4d09;if(_0x360690){const _0x537d33=_0x360690[_0x15e154('0xb')],_0x3aeff3=_0x1431e1[_0x15e154('0x22')];let _0x42d2c1=_0x1431e1[_0x15e154('0x22')]+_0x1431e1[_0x15e154('0x47')],_0x15fe81;return _0x42d2c1>=_0x537d33?(_0x42d2c1=_0x537d33,_0x15fe81=0xc8):_0x15fe81=0xce,_0x1afe64['status'](_0x15fe81),_0x1afe64['set'](_0x15e154('0x62'),_0x3aeff3+'-'+_0x42d2c1+'/'+_0x537d33)[_0x15e154('0x7')](_0x360690);}return null;};}function saveUpdates(_0x1a50e0){return function(_0x315bab){const _0x51966c=a378_0x4d09;if(_0x315bab)return _0x315bab['update'](_0x1a50e0)[_0x51966c('0x10')](function(_0x1a9c74){return _0x1a9c74;});return null;};}function removeEntity(_0x50c283){return function(_0x5b09be){const _0x3c3d73=a378_0x4d09;if(_0x5b09be)return _0x5b09be[_0x3c3d73('0x2c')]()[_0x3c3d73('0x10')](function(){const _0x432e0a=_0x3c3d73,_0x3e6ca0=_0x5b09be[_0x432e0a('0x39')]({'plain':!![]}),_0x124ff1=_0x432e0a('0x50');return db[_0x432e0a('0x3c')][_0x432e0a('0x2c')]({'where':{'type':_0x124ff1,'resourceId':_0x3e6ca0['id']}})['then'](function(){return _0x5b09be;});})[_0x3c3d73('0x10')](function(){const _0x27700a=_0x3c3d73;_0x50c283[_0x27700a('0x1d')](0xcc)[_0x27700a('0x12')]();});};}function handleEntityNotFound(_0x4f64e3){return function(_0x1216ef){const _0x8fb6f6=a378_0x4d09;return!_0x1216ef&&_0x4f64e3[_0x8fb6f6('0x64')](0x194),_0x1216ef;};}function handleError(_0x29eb95,_0x3166e4){return _0x3166e4=_0x3166e4||0x1f4,function(_0x49dd17){const _0x506255=a378_0x4d09;logger[_0x506255('0x41')](_0x49dd17[_0x506255('0x49')]),_0x49dd17[_0x506255('0x6')]&&delete _0x49dd17[_0x506255('0x6')],_0x29eb95[_0x506255('0x1d')](_0x3166e4)['send'](_0x49dd17);};}exports[_0x1f979b('0x59')]=function(_0x3deb1b,_0x321274){const _0x4b4a4f=_0x1f979b;let _0x7652b7={};const _0x196bea={},_0x5352f2={'count':0x0,'rows':[]},_0x524a6b=_[_0x4b4a4f('0x33')](db[_0x4b4a4f('0x2')][_0x4b4a4f('0xa')],function(_0xc230f2){const _0x1d5646=_0x4b4a4f;return{'name':_0xc230f2[_0x1d5646('0x5a')],'type':_0xc230f2[_0x1d5646('0x46')][_0x1d5646('0x23')]};});_0x196bea['model']=_[_0x4b4a4f('0x33')](_0x524a6b,_0x4b4a4f('0x6')),_0x196bea[_0x4b4a4f('0x5f')]=_[_0x4b4a4f('0xe')](_0x3deb1b[_0x4b4a4f('0x5f')]),_0x196bea['filters']=_[_0x4b4a4f('0x31')](_0x196bea[_0x4b4a4f('0x53')],_0x196bea[_0x4b4a4f('0x5f')]),_0x7652b7[_0x4b4a4f('0x1')]=_[_0x4b4a4f('0x31')](_0x196bea[_0x4b4a4f('0x53')],qs[_0x4b4a4f('0x2f')](_0x3deb1b['query'][_0x4b4a4f('0x2f')])),_0x7652b7[_0x4b4a4f('0x1')]=_0x7652b7[_0x4b4a4f('0x1')][_0x4b4a4f('0x17')]?_0x7652b7[_0x4b4a4f('0x1')]:_0x196bea[_0x4b4a4f('0x53')];typeof _0x3deb1b['query'][_0x4b4a4f('0x4e')]==='undefined'&&(_0x7652b7[_0x4b4a4f('0x47')]=qs[_0x4b4a4f('0x47')](_0x3deb1b[_0x4b4a4f('0x5f')][_0x4b4a4f('0x47')]),_0x7652b7['offset']=qs[_0x4b4a4f('0x22')](_0x3deb1b[_0x4b4a4f('0x5f')][_0x4b4a4f('0x22')]));_0x7652b7[_0x4b4a4f('0xd')]=qs[_0x4b4a4f('0x3')](_0x3deb1b['query']['sort']),_0x7652b7[_0x4b4a4f('0x2a')]=qs['filters'](_[_0x4b4a4f('0x4d')](_0x3deb1b[_0x4b4a4f('0x5f')],_0x196bea[_0x4b4a4f('0x3d')]),_0x524a6b);_0x3deb1b[_0x4b4a4f('0x5f')][_0x4b4a4f('0x1f')]&&(_0x7652b7[_0x4b4a4f('0x2a')]=_[_0x4b4a4f('0x15')](_0x7652b7[_0x4b4a4f('0x2a')],{[Op['or']]:_[_0x4b4a4f('0x33')](_0x524a6b,function(_0x501ed9){const _0x1b9a93=_0x4b4a4f;if(_0x501ed9[_0x1b9a93('0x46')]!==_0x1b9a93('0x34')){const _0x5ab4cc={};return _0x5ab4cc[_0x501ed9[_0x1b9a93('0x6')]]={[Op['like']]:'%'+_0x3deb1b[_0x1b9a93('0x5f')][_0x1b9a93('0x1f')]+'%'},_0x5ab4cc;}})}));_0x7652b7=_[_0x4b4a4f('0x15')]({},_0x7652b7,_0x3deb1b['options']);const _0x21c99b={'where':_0x7652b7[_0x4b4a4f('0x2a')]};return db[_0x4b4a4f('0x2')]['count'](_0x21c99b)[_0x4b4a4f('0x10')](function(_0x3b3bcc){const _0x1dd0b9=_0x4b4a4f;return _0x5352f2[_0x1dd0b9('0xb')]=_0x3b3bcc,_0x3deb1b[_0x1dd0b9('0x5f')][_0x1dd0b9('0x4b')]&&(_0x7652b7[_0x1dd0b9('0x24')]=[{'all':!![]}]),db['JscriptyProject']['findAll'](_0x7652b7);})[_0x4b4a4f('0x10')](function(_0x4e7c8a){const _0x3c8c32=_0x4b4a4f;return _0x5352f2[_0x3c8c32('0x5d')]=_0x4e7c8a,_0x5352f2;})[_0x4b4a4f('0x10')](respondWithFilteredResult(_0x321274,_0x7652b7))[_0x4b4a4f('0x51')](handleError(_0x321274,null));},exports[_0x1f979b('0x43')]=function(_0x263b94,_0x35a700){const _0x4f1792=_0x1f979b;let _0x5319f3={'raw':![],'where':{'id':_0x263b94[_0x4f1792('0x37')]['id']}};const _0x11673c={};return _0x11673c[_0x4f1792('0x53')]=_[_0x4f1792('0xe')](db['JscriptyProject'][_0x4f1792('0xa')]),_0x11673c[_0x4f1792('0x5f')]=_[_0x4f1792('0xe')](_0x263b94['query']),_0x11673c[_0x4f1792('0x3d')]=_[_0x4f1792('0x31')](_0x11673c[_0x4f1792('0x53')],_0x11673c[_0x4f1792('0x5f')]),_0x5319f3['attributes']=_[_0x4f1792('0x31')](_0x11673c[_0x4f1792('0x53')],qs['fields'](_0x263b94[_0x4f1792('0x5f')][_0x4f1792('0x2f')])),_0x5319f3[_0x4f1792('0x1')]=_0x5319f3[_0x4f1792('0x1')]['length']?_0x5319f3[_0x4f1792('0x1')]:_0x11673c[_0x4f1792('0x53')],_0x263b94['query']['includeAll']&&(_0x5319f3[_0x4f1792('0x24')]=[{'all':!![]}]),_0x5319f3=_[_0x4f1792('0x15')]({},_0x5319f3,_0x263b94[_0x4f1792('0x9')]),db[_0x4f1792('0x2')][_0x4f1792('0x20')](_0x5319f3)['then'](handleEntityNotFound(_0x35a700,null))[_0x4f1792('0x10')](respondWithResult(_0x35a700,null))[_0x4f1792('0x51')](handleError(_0x35a700,null));},exports[_0x1f979b('0x1c')]=function(_0x5be708,_0x25b850){const _0x153d9e=_0x1f979b;return db[_0x153d9e('0x2')][_0x153d9e('0x1c')](_0x5be708[_0x153d9e('0x5b')],{})[_0x153d9e('0x10')](function(_0x5865c9){const _0x494c4e=_0x153d9e,_0x352297=_0x5be708[_0x494c4e('0x56')][_0x494c4e('0x39')]({'plain':!![]});if(!_0x352297)throw new Error(_0x494c4e('0x13'));if(_0x352297[_0x494c4e('0x0')]===_0x494c4e('0x56')){const _0x38acc7=_0x5865c9[_0x494c4e('0x39')]({'plain':!![]}),_0x24ab73='Projects';return db[_0x494c4e('0x58')][_0x494c4e('0x20')]({'where':{'name':_0x24ab73,'userProfileId':_0x352297[_0x494c4e('0xc')]},'raw':!![]})[_0x494c4e('0x10')](function(_0x159f01){const _0x432485=_0x494c4e;return _0x159f01&&_0x159f01[_0x432485('0x32')]===0x0?db[_0x432485('0x3c')][_0x432485('0x1c')]({'name':_0x38acc7[_0x432485('0x6')],'resourceId':_0x38acc7['id'],'type':_0x159f01[_0x432485('0x6')],'sectionId':_0x159f01['id']},{})['then'](function(){return _0x5865c9;}):_0x5865c9;})[_0x494c4e('0x51')](function(_0x1360cc){const _0x26a2ac=_0x494c4e;logger[_0x26a2ac('0x41')](_0x26a2ac('0x40'),_0x1360cc);throw _0x1360cc;});}return _0x5865c9;})[_0x153d9e('0x10')](respondWithResult(_0x25b850,0xc9))[_0x153d9e('0x51')](handleError(_0x25b850,null));},exports[_0x1f979b('0x30')]=function(_0x2e8f81,_0x333531){const _0x3ff8df=_0x1f979b;let _0x468931={'where':{'id':_0x2e8f81[_0x3ff8df('0x37')]['id']}};const _0x294e3e={};return _0x294e3e[_0x3ff8df('0x53')]=_[_0x3ff8df('0xe')](db[_0x3ff8df('0x2')]['rawAttributes']),_0x468931['attributes']=_[_0x3ff8df('0x31')](_0x294e3e[_0x3ff8df('0x53')],qs[_0x3ff8df('0x2f')](_0x2e8f81[_0x3ff8df('0x5f')][_0x3ff8df('0x2f')])),_0x468931['attributes']=_0x468931[_0x3ff8df('0x1')][_0x3ff8df('0x17')]?_0x468931['attributes']:_0x294e3e['model'],_0x2e8f81['query'][_0x3ff8df('0x4b')]&&(_0x468931[_0x3ff8df('0x24')]=[{'all':!![]}]),_0x468931=_[_0x3ff8df('0x15')]({},_0x468931,_0x2e8f81['options']),db['JscriptyProject']['findOne'](_0x468931)[_0x3ff8df('0x10')](handleEntityNotFound(_0x333531,null))[_0x3ff8df('0x10')](function(_0x4aaa6b){const _0x3f6ca8=_0x3ff8df;if(_0x4aaa6b){let _0x42ed41=_0x4aaa6b['get']({'plain':!![]});return _0x42ed41=qs['omit'](_0x42ed41,['id',_0x3f6ca8('0x60'),_0x3f6ca8('0x27')]),_0x2e8f81[_0x3f6ca8('0x5b')]=_[_0x3f6ca8('0x21')](_0x2e8f81[_0x3f6ca8('0x5b')],['id',_0x3f6ca8('0x60'),_0x3f6ca8('0x27')]),db[_0x3f6ca8('0x2')]['create'](_['merge'](_0x42ed41,_0x2e8f81[_0x3f6ca8('0x5b')]),{'include':_0x2e8f81[_0x3f6ca8('0x5f')]['includeAll']?[{'all':!![]}]:undefined})[_0x3f6ca8('0x10')](function(_0x3f2ac4){const _0x30bfff=_0x3f6ca8,_0x1573e2=_0x2e8f81[_0x30bfff('0x56')][_0x30bfff('0x39')]({'plain':!![]});if(!_0x1573e2)throw new Error(_0x30bfff('0x13'));if(_0x1573e2[_0x30bfff('0x0')]===_0x30bfff('0x56')){const _0x538268=_0x3f2ac4[_0x30bfff('0x39')]({'plain':!![]}),_0x246ff1=_0x30bfff('0x50');return db[_0x30bfff('0x58')]['findOne']({'where':{'name':_0x246ff1,'userProfileId':_0x1573e2[_0x30bfff('0xc')]},'raw':!![]})['then'](function(_0x143722){const _0x5790d8=_0x30bfff;return _0x143722&&_0x143722['autoAssociation']===0x0?db['UserProfileResource'][_0x5790d8('0x1c')]({'name':_0x538268[_0x5790d8('0x6')],'resourceId':_0x538268['id'],'type':_0x143722[_0x5790d8('0x6')],'sectionId':_0x143722['id']},{})[_0x5790d8('0x10')](function(){return _0x3f2ac4;}):_0x3f2ac4;})['catch'](function(_0x1519b6){const _0x44d427=_0x30bfff;logger[_0x44d427('0x41')](_0x44d427('0x40'),_0x1519b6);throw _0x1519b6;});}return _0x3f2ac4;});}})['then'](respondWithResult(_0x333531,0xc9))[_0x3ff8df('0x51')](handleError(_0x333531,null));},exports['update']=function(_0x4e8e21,_0x3432a8){const _0x1a80d1=_0x1f979b;return _0x4e8e21['body']['id']&&delete _0x4e8e21[_0x1a80d1('0x5b')]['id'],db[_0x1a80d1('0x2')][_0x1a80d1('0x20')]({'where':{'id':_0x4e8e21[_0x1a80d1('0x37')]['id']}})[_0x1a80d1('0x10')](handleEntityNotFound(_0x3432a8,null))[_0x1a80d1('0x10')](saveUpdates(_0x4e8e21[_0x1a80d1('0x5b')],null))[_0x1a80d1('0x10')](respondWithResult(_0x3432a8,null))[_0x1a80d1('0x51')](handleError(_0x3432a8,null));},exports['destroy']=function(_0x1a23c5,_0x4d9a4f){const _0x34651b=_0x1f979b;return db[_0x34651b('0x2')]['findOne']({'where':{'id':_0x1a23c5['params']['id']}})['then'](handleEntityNotFound(_0x4d9a4f,null))[_0x34651b('0x10')](removeEntity(_0x4d9a4f,null))[_0x34651b('0x51')](handleError(_0x4d9a4f,null));},exports[_0x1f979b('0x4f')]=function(_0x1ebe8f,_0xa784f8){const _0x2d9dff=_0x1f979b;let _0x18c645={'raw':!![],'where':{}};const _0x588b39={},_0x50caf2={'count':0x0,'rows':[]};return db[_0x2d9dff('0x2')][_0x2d9dff('0x20')]({'where':{'id':_0x1ebe8f[_0x2d9dff('0x37')]['id']}})[_0x2d9dff('0x10')](handleEntityNotFound(_0xa784f8,null))[_0x2d9dff('0x10')](function(_0x26e9e6){const _0x2dc764=_0x2d9dff;if(_0x26e9e6)return _0x588b39[_0x2dc764('0x53')]=_['keys'](db[_0x2dc764('0xf')][_0x2dc764('0xa')]),_0x588b39[_0x2dc764('0x5f')]=_[_0x2dc764('0xe')](_0x1ebe8f['query']),_0x588b39['filters']=_[_0x2dc764('0x31')](_0x588b39['model'],_0x588b39[_0x2dc764('0x5f')]),_0x18c645['attributes']=_[_0x2dc764('0x31')](_0x588b39[_0x2dc764('0x53')],qs[_0x2dc764('0x2f')](_0x1ebe8f['query'][_0x2dc764('0x2f')])),_0x18c645[_0x2dc764('0x1')]=_0x18c645[_0x2dc764('0x1')][_0x2dc764('0x17')]?_0x18c645[_0x2dc764('0x1')]:_0x588b39['model'],typeof _0x1ebe8f[_0x2dc764('0x5f')][_0x2dc764('0x4e')]===_0x2dc764('0x2d')&&(_0x18c645[_0x2dc764('0x47')]=qs['limit'](_0x1ebe8f['query']['limit']),_0x18c645[_0x2dc764('0x22')]=qs['offset'](_0x1ebe8f[_0x2dc764('0x5f')]['offset'])),_0x18c645[_0x2dc764('0xd')]=qs['sort'](_0x1ebe8f[_0x2dc764('0x5f')][_0x2dc764('0x3')]),_0x18c645[_0x2dc764('0x2a')]=qs[_0x2dc764('0x3d')](_[_0x2dc764('0x4d')](_0x1ebe8f[_0x2dc764('0x5f')],_0x588b39[_0x2dc764('0x3d')])),_0x18c645['where']['ProjectId']=_0x26e9e6['id'],_0x1ebe8f[_0x2dc764('0x5f')][_0x2dc764('0x1f')]&&(_0x18c645[_0x2dc764('0x2a')]=_[_0x2dc764('0x15')](_0x18c645[_0x2dc764('0x2a')],{[Op['or']]:_[_0x2dc764('0x33')](_0x18c645['attributes'],function(_0xbeb0b3){const _0x45022b=_0x2dc764,_0x54ef86={};return _0x54ef86[_0xbeb0b3]={[Op[_0x45022b('0x1e')]]:'%'+_0x1ebe8f['query']['filter']+'%'},_0x54ef86;})})),_0x18c645=_['merge']({},_0x18c645,_0x1ebe8f[_0x2dc764('0x9')]),db[_0x2dc764('0xf')]['count']({'where':_0x18c645[_0x2dc764('0x2a')]})['then'](function(_0x33f384){const _0x2d1dd7=_0x2dc764;return _0x50caf2['count']=_0x33f384,_0x1ebe8f['query']['includeAll']&&(_0x18c645[_0x2d1dd7('0x24')]=[{'all':!![]}]),db[_0x2d1dd7('0xf')][_0x2d1dd7('0x38')](_0x18c645);})[_0x2dc764('0x10')](function(_0x500319){const _0x1dc152=_0x2dc764;return _0x50caf2[_0x1dc152('0x5d')]=_0x500319,_0x50caf2;});})['then'](respondWithFilteredResult(_0xa784f8,_0x18c645))['catch'](handleError(_0xa784f8,null));},exports[_0x1f979b('0x29')]=function(_0x25f5c4,_0x5c0f06){const _0x3cefa6=_0x1f979b;let _0x5d11c8={'raw':!![],'where':{}};const _0x5bf97b={},_0x2e85f7={'count':0x0,'rows':[]};return db[_0x3cefa6('0x2')]['findOne']({'where':{'id':_0x25f5c4[_0x3cefa6('0x37')]['id']}})[_0x3cefa6('0x10')](handleEntityNotFound(_0x5c0f06,null))[_0x3cefa6('0x10')](function(_0x3c6646){const _0x5445ea=_0x3cefa6;if(_0x3c6646)return _0x5bf97b[_0x5445ea('0x53')]=_[_0x5445ea('0xe')](db[_0x5445ea('0x2e')]['rawAttributes']),_0x5bf97b[_0x5445ea('0x5f')]=_[_0x5445ea('0xe')](_0x25f5c4['query']),_0x5bf97b[_0x5445ea('0x3d')]=_['intersection'](_0x5bf97b[_0x5445ea('0x53')],_0x5bf97b[_0x5445ea('0x5f')]),_0x5d11c8[_0x5445ea('0x1')]=_[_0x5445ea('0x31')](_0x5bf97b[_0x5445ea('0x53')],qs[_0x5445ea('0x2f')](_0x25f5c4[_0x5445ea('0x5f')][_0x5445ea('0x2f')])),_0x5d11c8['attributes']=_0x5d11c8[_0x5445ea('0x1')][_0x5445ea('0x17')]?_0x5d11c8[_0x5445ea('0x1')]:_0x5bf97b[_0x5445ea('0x53')],typeof _0x25f5c4[_0x5445ea('0x5f')][_0x5445ea('0x4e')]==='undefined'&&(_0x5d11c8[_0x5445ea('0x47')]=qs[_0x5445ea('0x47')](_0x25f5c4['query']['limit']),_0x5d11c8['offset']=qs['offset'](_0x25f5c4[_0x5445ea('0x5f')][_0x5445ea('0x22')])),_0x5d11c8['order']=qs[_0x5445ea('0x3')](_0x25f5c4['query'][_0x5445ea('0x3')]),_0x5d11c8['where']=qs[_0x5445ea('0x3d')](_['pick'](_0x25f5c4['query'],_0x5bf97b[_0x5445ea('0x3d')])),_0x5d11c8['where'][_0x5445ea('0x63')]=_0x3c6646['id'],_0x25f5c4[_0x5445ea('0x5f')][_0x5445ea('0x1f')]&&(_0x5d11c8[_0x5445ea('0x2a')]=_[_0x5445ea('0x15')](_0x5d11c8[_0x5445ea('0x2a')],{[Op['or']]:_[_0x5445ea('0x33')](_0x5d11c8[_0x5445ea('0x1')],function(_0x24d5cd){const _0x25804e=_0x5445ea,_0x3d4562={};return _0x3d4562[_0x24d5cd]={[Op['like']]:'%'+_0x25f5c4[_0x25804e('0x5f')][_0x25804e('0x1f')]+'%'},_0x3d4562;})})),_0x5d11c8=_[_0x5445ea('0x15')]({},_0x5d11c8,_0x25f5c4[_0x5445ea('0x9')]),db[_0x5445ea('0x2e')][_0x5445ea('0xb')]({'where':_0x5d11c8[_0x5445ea('0x2a')]})[_0x5445ea('0x10')](function(_0x539db8){const _0x4ad3c7=_0x5445ea;return _0x2e85f7[_0x4ad3c7('0xb')]=_0x539db8,_0x25f5c4['query'][_0x4ad3c7('0x4b')]&&(_0x5d11c8[_0x4ad3c7('0x24')]=[{'all':!![]}]),db[_0x4ad3c7('0x2e')][_0x4ad3c7('0x38')](_0x5d11c8);})[_0x5445ea('0x10')](function(_0x323450){const _0x1a0653=_0x5445ea;return _0x2e85f7[_0x1a0653('0x5d')]=_0x323450,_0x2e85f7;});})[_0x3cefa6('0x10')](respondWithFilteredResult(_0x5c0f06,_0x5d11c8))[_0x3cefa6('0x51')](handleError(_0x5c0f06,null));};function char(_0x1b5127){const _0x1d49f9=_0x1f979b;return'number'===typeof _0x1b5127?String[_0x1d49f9('0x3e')][_0x1d49f9('0x1a')](null,arguments):_0x1b5127;}function needsEncapsulation(_0x12979c){const _0x275ebd=_0x1f979b;return!!_0x12979c&&(_0x12979c[_0x275ebd('0x19')]()[_0x275ebd('0x2b')](char(0xd))>=0x0||_0x12979c['toString']()[_0x275ebd('0x2b')](char(0xa))>=0x0||_0x12979c[_0x275ebd('0x19')]()[_0x275ebd('0x2b')](char(0x2c))>=0x0||_0x12979c[_0x275ebd('0x19')]()[_0x275ebd('0x2b')](char(0x22))>=0x0);}function encapsulate(_0x356adc){const _0x1216dd=_0x1f979b,_0x1afb52=char(0x22),_0x5431a0='\x5c'+char(0x22),_0x4a76a9=_0x356adc[_0x1216dd('0x19')]()[_0x1216dd('0x3f')](new RegExp(_0x1afb52,'g'),_0x5431a0);return _0x1afb52+_0x4a76a9+_0x1afb52;}exports[_0x1f979b('0x52')]=function(_0x89378d,_0x1d6bf2){const _0x5165c0=_0x1f979b;let _0x581233,_0x4c5ce4;const _0x377f72={'where':{'ProjectId':_0x89378d[_0x5165c0('0x37')]['id']}};return _0x89378d[_0x5165c0('0x5f')][_0x5165c0('0x8')]&&(_0x377f72[_0x5165c0('0x2a')][_0x5165c0('0x4c')]=JSON[_0x5165c0('0x16')](_0x89378d[_0x5165c0('0x5f')][_0x5165c0('0x8')])),db[_0x5165c0('0xf')]['findAll'](_0x377f72)[_0x5165c0('0x10')](handleEntityNotFound(_0x1d6bf2,null))[_0x5165c0('0x10')](function(_0x2d871e){const _0x303fcd=_0x5165c0;if(_0x2d871e)return _0x581233=_0x2d871e,db[_0x303fcd('0x55')][_0x303fcd('0x38')]({'where':{'SessionId':{[Op['in']]:_[_0x303fcd('0x33')](_0x581233,'id')},'ProjectId':_0x89378d[_0x303fcd('0x37')]['id']},'order':'-createdAt'});})[_0x5165c0('0x10')](handleEntityNotFound(_0x1d6bf2,null))['then'](function(_0x3a651d){const _0x44f65d=_0x5165c0;if(_0x3a651d){_0x4c5ce4=_0x3a651d;const _0x183c8c={};for(let _0x32e651=0x0,_0x21ec13=_0x4c5ce4[_0x44f65d('0x17')];_0x32e651<_0x21ec13;_0x32e651++){typeof _0x183c8c[_0x4c5ce4[_0x32e651][_0x44f65d('0x28')]]==='undefined'&&(_0x183c8c[_0x4c5ce4[_0x32e651]['questionId']]=needsEncapsulation(_0x4c5ce4[_0x32e651][_0x44f65d('0x1b')])?encapsulate(_0x4c5ce4[_0x32e651][_0x44f65d('0x1b')]):_0x4c5ce4[_0x32e651]['question']);}const _0x425f4a=[];let _0x17c791={};for(let _0x33ff32=0x0,_0x3940a4=_0x581233[_0x44f65d('0x17')];_0x33ff32<_0x3940a4;_0x33ff32++){_0x17c791={'ProjectId':_0x89378d['params']['id'],'SessionId':_0x581233[_0x33ff32]['id'],'StartTime':moment(_0x581233[_0x33ff32]['starttime'])[_0x44f65d('0x3b')](_0x44f65d('0x3a'))};for(let _0x3674c8=0x0,_0x3ec49a=_0x4c5ce4[_0x44f65d('0x17')];_0x3674c8<_0x3ec49a;_0x3674c8++){_0x4c5ce4[_0x3674c8][_0x44f65d('0x54')]===_0x581233[_0x33ff32]['id']&&typeof _0x183c8c[_0x4c5ce4[_0x3674c8]['questionId']]!==_0x44f65d('0x2d')&&(_0x17c791[_0x183c8c[_0x4c5ce4[_0x3674c8][_0x44f65d('0x28')]]]=_0x4c5ce4[_0x3674c8][_0x44f65d('0x4a')]);}for(const _0x1a3700 in _0x183c8c){typeof _0x17c791[_0x183c8c[_0x1a3700]]===_0x44f65d('0x2d')&&(_0x17c791[_0x183c8c[_0x1a3700]]=null);}_0x425f4a[_0x44f65d('0x5e')](_0x17c791);}return _0x425f4a;}})[_0x5165c0('0x10')](function(_0x4b2810){const _0x3623d5=_0x5165c0;if(!_[_0x3623d5('0x5')](_0x4b2810)){const _0x253614=toCsv(_0x4b2810),_0x1bd946=Date['now']();return fs[_0x3623d5('0x11')](util[_0x3623d5('0x3b')]('/tmp/Jscripty_Project_%d_Summary_%s.csv',_0x89378d[_0x3623d5('0x37')]['id'],_0x1bd946),_0x253614),_0x1d6bf2['setHeader'](_0x3623d5('0x35'),_0x3623d5('0x61')+util[_0x3623d5('0x3b')](_0x3623d5('0x36'),_0x89378d[_0x3623d5('0x37')]['id'],_0x1bd946)),_0x1d6bf2[_0x3623d5('0x4')](_0x3623d5('0x45'),_0x3623d5('0x25')),_0x1d6bf2['download'](util[_0x3623d5('0x3b')](_0x3623d5('0x26'),_0x89378d[_0x3623d5('0x37')]['id'],_0x1bd946));}else return _0x1d6bf2['sendStatus'](0xcc);})[_0x5165c0('0x51')](handleError(_0x1d6bf2,null));}; \ No newline at end of file diff --git a/server/api/jscriptyProject/jscriptyProject.model.js b/server/api/jscriptyProject/jscriptyProject.model.js index e92dd87..2f16732 100644 --- a/server/api/jscriptyProject/jscriptyProject.model.js +++ b/server/api/jscriptyProject/jscriptyProject.model.js @@ -1 +1 @@ -const a379_0x5676=['exports','jscripty_projects'];(function(_0x38b3fb,_0x567614){const _0x190d75=function(_0x5ac445){while(--_0x5ac445){_0x38b3fb['push'](_0x38b3fb['shift']());}};_0x190d75(++_0x567614);}(a379_0x5676,0x10f));const a379_0x190d=function(_0x38b3fb,_0x567614){_0x38b3fb=_0x38b3fb-0x0;let _0x190d75=a379_0x5676[_0x38b3fb];return _0x190d75;};const _0x116c85=a379_0x190d;'use strict';const attributes=require('./jscriptyProject.attributes');module[_0x116c85('0x1')]=function(_0x5ac445){const _0x24a3a4=_0x116c85,_0x416351=_0x5ac445['define']('JscriptyProject',attributes,{'tableName':_0x24a3a4('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x416351;}; \ No newline at end of file +const a379_0xe05e=['exports','./jscriptyProject.attributes'];(function(_0x16cb27,_0xe05e79){const _0x4a3a56=function(_0x31325f){while(--_0x31325f){_0x16cb27['push'](_0x16cb27['shift']());}};_0x4a3a56(++_0xe05e79);}(a379_0xe05e,0xdc));const a379_0x4a3a=function(_0x16cb27,_0xe05e79){_0x16cb27=_0x16cb27-0x0;let _0x4a3a56=a379_0xe05e[_0x16cb27];return _0x4a3a56;};const _0x15a316=a379_0x4a3a;'use strict';const attributes=require(_0x15a316('0x1'));module[_0x15a316('0x0')]=function(_0x31325f){const _0x5b41b8=_0x31325f['define']('JscriptyProject',attributes,{'tableName':'jscripty_projects','paranoid':![],'indexes':[],'timestamps':!![]});return _0x5b41b8;}; \ No newline at end of file diff --git a/server/api/jscriptyQuestionReport/index.js b/server/api/jscriptyQuestionReport/index.js index 80c2900..093c042 100644 --- a/server/api/jscriptyQuestionReport/index.js +++ b/server/api/jscriptyQuestionReport/index.js @@ -1 +1 @@ -const a380_0x2944=['index','Router','destroy','isAuthenticated','../../components/auth/service','put','show','/describe','./jscriptyQuestionReport.controller','/:id','get','post','express','describe'];(function(_0x31faaf,_0x2944fd){const _0x29fd78=function(_0x30455d){while(--_0x30455d){_0x31faaf['push'](_0x31faaf['shift']());}};_0x29fd78(++_0x2944fd);}(a380_0x2944,0x185));const a380_0x29fd=function(_0x31faaf,_0x2944fd){_0x31faaf=_0x31faaf-0x0;let _0x29fd78=a380_0x2944[_0x31faaf];return _0x29fd78;};const _0x245906=a380_0x29fd;'use strict';const express=require(_0x245906('0x1')),router=express[_0x245906('0x4')](),auth=require(_0x245906('0x7')),controller=require(_0x245906('0xb'));router['get']('/',auth[_0x245906('0x6')](),controller[_0x245906('0x3')]),router['get'](_0x245906('0xa'),auth[_0x245906('0x6')](),controller[_0x245906('0x2')]),router[_0x245906('0xd')]('/:id',auth[_0x245906('0x6')](),controller[_0x245906('0x9')]),router[_0x245906('0x0')]('/',auth[_0x245906('0x6')](),controller['create']),router[_0x245906('0x8')](_0x245906('0xc'),auth['isAuthenticated'](),controller['update']),router['delete'](_0x245906('0xc'),auth[_0x245906('0x6')](),controller[_0x245906('0x5')]),module['exports']=router; \ No newline at end of file +const a380_0xd199=['exports','show','isAuthenticated','destroy','./jscriptyQuestionReport.controller','get','Router','express','/:id','delete','create','describe','index','../../components/auth/service','update'];(function(_0x4cc18e,_0xd19952){const _0x5b830e=function(_0x3282ea){while(--_0x3282ea){_0x4cc18e['push'](_0x4cc18e['shift']());}};_0x5b830e(++_0xd19952);}(a380_0xd199,0x13b));const a380_0x5b83=function(_0x4cc18e,_0xd19952){_0x4cc18e=_0x4cc18e-0x0;let _0x5b830e=a380_0xd199[_0x4cc18e];return _0x5b830e;};const _0x421269=a380_0x5b83;'use strict';const express=require(_0x421269('0x7')),router=express[_0x421269('0x6')](),auth=require(_0x421269('0xd')),controller=require(_0x421269('0x4'));router[_0x421269('0x5')]('/',auth[_0x421269('0x2')](),controller[_0x421269('0xc')]),router[_0x421269('0x5')]('/describe',auth['isAuthenticated'](),controller[_0x421269('0xb')]),router[_0x421269('0x5')](_0x421269('0x8'),auth[_0x421269('0x2')](),controller[_0x421269('0x1')]),router['post']('/',auth[_0x421269('0x2')](),controller[_0x421269('0xa')]),router['put'](_0x421269('0x8'),auth[_0x421269('0x2')](),controller[_0x421269('0xe')]),router[_0x421269('0x9')](_0x421269('0x8'),auth['isAuthenticated'](),controller[_0x421269('0x3')]),module[_0x421269('0x0')]=router; \ No newline at end of file diff --git a/server/api/jscriptyQuestionReport/jscriptyQuestionReport.attributes.js b/server/api/jscriptyQuestionReport/jscriptyQuestionReport.attributes.js index 9542da1..ff94908 100644 --- a/server/api/jscriptyQuestionReport/jscriptyQuestionReport.attributes.js +++ b/server/api/jscriptyQuestionReport/jscriptyQuestionReport.attributes.js @@ -1 +1 @@ -const a381_0x530a=['long','sequelize','exports','STRING'];(function(_0x1e011d,_0x530a3){const _0x46a63e=function(_0x407014){while(--_0x407014){_0x1e011d['push'](_0x1e011d['shift']());}};_0x46a63e(++_0x530a3);}(a381_0x530a,0x17a));const a381_0x46a6=function(_0x1e011d,_0x530a3){_0x1e011d=_0x1e011d-0x0;let _0x46a63e=a381_0x530a[_0x1e011d];return _0x46a63e;};const _0xf58c3c=a381_0x46a6;'use strict';const Sequelize=require(_0xf58c3c('0x3'));module[_0xf58c3c('0x0')]={'question':{'type':Sequelize[_0xf58c3c('0x1')]},'answer':{'type':Sequelize['TEXT'](_0xf58c3c('0x2'))},'membername':{'type':Sequelize[_0xf58c3c('0x1')]},'projectname':{'type':Sequelize[_0xf58c3c('0x1')]},'queue':{'type':Sequelize['STRING']},'uniqueid':{'type':Sequelize['STRING']},'calleridname':{'type':Sequelize[_0xf58c3c('0x1')]},'calleridnum':{'type':Sequelize[_0xf58c3c('0x1')]},'questionId':{'type':Sequelize[_0xf58c3c('0x1')]}}; \ No newline at end of file +const a381_0xbcdd=['long','TEXT','STRING','sequelize'];(function(_0x266c3b,_0xbcdd4f){const _0x5e7438=function(_0x1f3a21){while(--_0x1f3a21){_0x266c3b['push'](_0x266c3b['shift']());}};_0x5e7438(++_0xbcdd4f);}(a381_0xbcdd,0x15b));const a381_0x5e74=function(_0x266c3b,_0xbcdd4f){_0x266c3b=_0x266c3b-0x0;let _0x5e7438=a381_0xbcdd[_0x266c3b];return _0x5e7438;};const _0x5aaf3f=a381_0x5e74;'use strict';const Sequelize=require(_0x5aaf3f('0x0'));module['exports']={'question':{'type':Sequelize['STRING']},'answer':{'type':Sequelize[_0x5aaf3f('0x2')](_0x5aaf3f('0x1'))},'membername':{'type':Sequelize['STRING']},'projectname':{'type':Sequelize[_0x5aaf3f('0x3')]},'queue':{'type':Sequelize[_0x5aaf3f('0x3')]},'uniqueid':{'type':Sequelize['STRING']},'calleridname':{'type':Sequelize[_0x5aaf3f('0x3')]},'calleridnum':{'type':Sequelize[_0x5aaf3f('0x3')]},'questionId':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/jscriptyQuestionReport/jscriptyQuestionReport.controller.js b/server/api/jscriptyQuestionReport/jscriptyQuestionReport.controller.js index e348243..790f549 100644 --- a/server/api/jscriptyQuestionReport/jscriptyQuestionReport.controller.js +++ b/server/api/jscriptyQuestionReport/jscriptyQuestionReport.controller.js @@ -1 +1 @@ -const a382_0x2dc4=['JscriptyQuestionReport','filters','lodash','sort','key','error','set','rows','include','sequelize','stack','rawAttributes','like','order','index','model','then','json','query','VIRTUAL','Content-Range','create','catch','map','findOne','merge','name','limit','type','findAll','includeAll','where','keys','destroy','offset','undefined','count','fields','status','options','attributes','nolimit','body','show','length','../../mysqldb','describe','pick','../../config/logger','params','intersection','sendStatus','../../components/parsers/qs'];(function(_0x423ef6,_0x2dc495){const _0x1040a2=function(_0x10d72f){while(--_0x10d72f){_0x423ef6['push'](_0x423ef6['shift']());}};_0x1040a2(++_0x2dc495);}(a382_0x2dc4,0x1c1));const a382_0x1040=function(_0x423ef6,_0x2dc495){_0x423ef6=_0x423ef6-0x0;let _0x1040a2=a382_0x2dc4[_0x423ef6];return _0x1040a2;};const _0x462713=a382_0x1040;'use strict';const _=require(_0x462713('0x1e')),qs=require(_0x462713('0x1b')),logger=require(_0x462713('0x17'))('api'),db=require(_0x462713('0x14'))['db'],{Op}=require(_0x462713('0x25'));function respondWithResult(_0x10d72f,_0x48fdb6){return _0x48fdb6=_0x48fdb6||0xc8,function(_0x143feb){const _0x1d1d13=a382_0x1040;if(_0x143feb)return _0x10d72f[_0x1d1d13('0xd')](_0x48fdb6)[_0x1d1d13('0x2d')](_0x143feb);};}function respondWithFilteredResult(_0x1c227a,_0x4974bd){return function(_0x580010){const _0x2e1d4d=a382_0x1040;if(_0x580010){const _0x5dc9c2=_0x580010['count'],_0x4bb571=_0x4974bd[_0x2e1d4d('0x9')];let _0xb289c3=_0x4974bd[_0x2e1d4d('0x9')]+_0x4974bd[_0x2e1d4d('0x2')],_0x405fa4;return _0xb289c3>=_0x5dc9c2?(_0xb289c3=_0x5dc9c2,_0x405fa4=0xc8):_0x405fa4=0xce,_0x1c227a[_0x2e1d4d('0xd')](_0x405fa4),_0x1c227a[_0x2e1d4d('0x22')](_0x2e1d4d('0x30'),_0x4bb571+'-'+_0xb289c3+'/'+_0x5dc9c2)[_0x2e1d4d('0x2d')](_0x580010);}return null;};}function saveUpdates(_0x2afcf5){return function(_0x746ba1){const _0x4cdb2c=a382_0x1040;if(_0x746ba1)return _0x746ba1['update'](_0x2afcf5)[_0x4cdb2c('0x2c')](function(_0x14c10b){return _0x14c10b;});return null;};}function removeEntity(_0x347f32){return function(_0x4dedc1){const _0x473b7d=a382_0x1040;if(_0x4dedc1)return _0x4dedc1[_0x473b7d('0x8')]()[_0x473b7d('0x2c')](function(){const _0x176b5f=_0x473b7d;_0x347f32[_0x176b5f('0xd')](0xcc)['end']();});};}function handleEntityNotFound(_0x3595d0){return function(_0x47819a){const _0x3a756b=a382_0x1040;return!_0x47819a&&_0x3595d0[_0x3a756b('0x1a')](0x194),_0x47819a;};}function handleError(_0xad0b1f,_0x4414f6){return _0x4414f6=_0x4414f6||0x1f4,function(_0x13becf){const _0x517810=a382_0x1040;logger[_0x517810('0x21')](_0x13becf[_0x517810('0x26')]),_0x13becf[_0x517810('0x1')]&&delete _0x13becf[_0x517810('0x1')],_0xad0b1f[_0x517810('0xd')](_0x4414f6)['send'](_0x13becf);};}exports[_0x462713('0x2a')]=function(_0x2af426,_0x186ce3){const _0x221e5e=_0x462713;let _0x278b20={};const _0x3166ae={},_0x4bfaf9={'count':0x0,'rows':[]},_0x2eb50e=_[_0x221e5e('0x33')](db[_0x221e5e('0x1c')][_0x221e5e('0x27')],function(_0x4f42ac){const _0x5e17f2=_0x221e5e;return{'name':_0x4f42ac['fieldName'],'type':_0x4f42ac[_0x5e17f2('0x3')][_0x5e17f2('0x20')]};});_0x3166ae[_0x221e5e('0x2b')]=_[_0x221e5e('0x33')](_0x2eb50e,_0x221e5e('0x1')),_0x3166ae['query']=_['keys'](_0x2af426['query']),_0x3166ae[_0x221e5e('0x1d')]=_[_0x221e5e('0x19')](_0x3166ae[_0x221e5e('0x2b')],_0x3166ae[_0x221e5e('0x2e')]),_0x278b20[_0x221e5e('0xf')]=_['intersection'](_0x3166ae[_0x221e5e('0x2b')],qs[_0x221e5e('0xc')](_0x2af426[_0x221e5e('0x2e')][_0x221e5e('0xc')])),_0x278b20[_0x221e5e('0xf')]=_0x278b20['attributes'][_0x221e5e('0x13')]?_0x278b20[_0x221e5e('0xf')]:_0x3166ae[_0x221e5e('0x2b')];typeof _0x2af426['query'][_0x221e5e('0x10')]===_0x221e5e('0xa')&&(_0x278b20[_0x221e5e('0x2')]=qs['limit'](_0x2af426['query'][_0x221e5e('0x2')]),_0x278b20[_0x221e5e('0x9')]=qs['offset'](_0x2af426[_0x221e5e('0x2e')][_0x221e5e('0x9')]));_0x278b20[_0x221e5e('0x29')]=qs[_0x221e5e('0x1f')](_0x2af426[_0x221e5e('0x2e')]['sort']),_0x278b20[_0x221e5e('0x6')]=qs['filters'](_[_0x221e5e('0x16')](_0x2af426[_0x221e5e('0x2e')],_0x3166ae[_0x221e5e('0x1d')]),_0x2eb50e);_0x2af426[_0x221e5e('0x2e')]['filter']&&(_0x278b20[_0x221e5e('0x6')]=_[_0x221e5e('0x0')](_0x278b20['where'],{[Op['or']]:_[_0x221e5e('0x33')](_0x2eb50e,function(_0x3e6e5a){const _0x57f92d=_0x221e5e;if(_0x3e6e5a['type']!==_0x57f92d('0x2f')){const _0x54adf5={};return _0x54adf5[_0x3e6e5a['name']]={[Op[_0x57f92d('0x28')]]:'%'+_0x2af426['query']['filter']+'%'},_0x54adf5;}})}));_0x278b20=_[_0x221e5e('0x0')]({},_0x278b20,_0x2af426[_0x221e5e('0xe')]);const _0xe298f={'where':_0x278b20[_0x221e5e('0x6')]};return db[_0x221e5e('0x1c')][_0x221e5e('0xb')](_0xe298f)[_0x221e5e('0x2c')](function(_0x1a7c30){const _0x13366f=_0x221e5e;return _0x4bfaf9[_0x13366f('0xb')]=_0x1a7c30,_0x2af426[_0x13366f('0x2e')][_0x13366f('0x5')]&&(_0x278b20[_0x13366f('0x24')]=[{'all':!![]}]),db[_0x13366f('0x1c')][_0x13366f('0x4')](_0x278b20);})['then'](function(_0x42f44b){const _0x5c4ed5=_0x221e5e;return _0x4bfaf9[_0x5c4ed5('0x23')]=_0x42f44b,_0x4bfaf9;})[_0x221e5e('0x2c')](respondWithFilteredResult(_0x186ce3,_0x278b20))['catch'](handleError(_0x186ce3,null));},exports[_0x462713('0x12')]=function(_0x306432,_0xe1708){const _0x167d03=_0x462713;let _0x32dbc1={'raw':!![],'where':{'id':_0x306432[_0x167d03('0x18')]['id']}};const _0xff7f99={};return _0xff7f99[_0x167d03('0x2b')]=_['keys'](db[_0x167d03('0x1c')][_0x167d03('0x27')]),_0xff7f99[_0x167d03('0x2e')]=_[_0x167d03('0x7')](_0x306432[_0x167d03('0x2e')]),_0xff7f99[_0x167d03('0x1d')]=_[_0x167d03('0x19')](_0xff7f99[_0x167d03('0x2b')],_0xff7f99['query']),_0x32dbc1[_0x167d03('0xf')]=_['intersection'](_0xff7f99[_0x167d03('0x2b')],qs['fields'](_0x306432[_0x167d03('0x2e')][_0x167d03('0xc')])),_0x32dbc1[_0x167d03('0xf')]=_0x32dbc1[_0x167d03('0xf')][_0x167d03('0x13')]?_0x32dbc1['attributes']:_0xff7f99[_0x167d03('0x2b')],_0x306432['query'][_0x167d03('0x5')]&&(_0x32dbc1[_0x167d03('0x24')]=[{'all':!![]}]),_0x32dbc1=_[_0x167d03('0x0')]({},_0x32dbc1,_0x306432['options']),db['JscriptyQuestionReport'][_0x167d03('0x34')](_0x32dbc1)['then'](handleEntityNotFound(_0xe1708,null))[_0x167d03('0x2c')](respondWithResult(_0xe1708,null))[_0x167d03('0x32')](handleError(_0xe1708,null));},exports[_0x462713('0x31')]=function(_0x14a935,_0x3a64fb){const _0x26c32d=_0x462713;return db[_0x26c32d('0x1c')][_0x26c32d('0x31')](_0x14a935[_0x26c32d('0x11')],{})[_0x26c32d('0x2c')](respondWithResult(_0x3a64fb,0xc9))[_0x26c32d('0x32')](handleError(_0x3a64fb,null));},exports['update']=function(_0x13de6e,_0x524020){const _0x2b6c3c=_0x462713;return _0x13de6e[_0x2b6c3c('0x11')]['id']&&delete _0x13de6e[_0x2b6c3c('0x11')]['id'],db[_0x2b6c3c('0x1c')][_0x2b6c3c('0x34')]({'where':{'id':_0x13de6e['params']['id']}})[_0x2b6c3c('0x2c')](handleEntityNotFound(_0x524020,null))[_0x2b6c3c('0x2c')](saveUpdates(_0x13de6e[_0x2b6c3c('0x11')],null))['then'](respondWithResult(_0x524020,null))[_0x2b6c3c('0x32')](handleError(_0x524020,null));},exports[_0x462713('0x8')]=function(_0x44a54e,_0x43c3e3){const _0x351e9b=_0x462713;return db['JscriptyQuestionReport'][_0x351e9b('0x34')]({'where':{'id':_0x44a54e[_0x351e9b('0x18')]['id']}})[_0x351e9b('0x2c')](handleEntityNotFound(_0x43c3e3,null))[_0x351e9b('0x2c')](removeEntity(_0x43c3e3,null))[_0x351e9b('0x32')](handleError(_0x43c3e3,null));},exports[_0x462713('0x15')]=function(_0x4c3036,_0x22157a){const _0x344b67=_0x462713;return db[_0x344b67('0x1c')][_0x344b67('0x15')]()[_0x344b67('0x2c')](respondWithResult(_0x22157a,null))[_0x344b67('0x32')](handleError(_0x22157a,null));}; \ No newline at end of file +const a382_0x2aa1=['sequelize','destroy','intersection','set','body','count','describe','keys','merge','rows','JscriptyQuestionReport','options','sendStatus','query','limit','params','update','offset','findOne','name','json','then','findAll','status','length','show','type','key','stack','rawAttributes','model','create','nolimit','catch','lodash','attributes','sort','include','where','like','includeAll','fields','../../config/logger','../../components/parsers/qs','Content-Range','api','pick','filters','fieldName','map','send'];(function(_0x12df3b,_0x2aa1ef){const _0x1c99bf=function(_0xa911fe){while(--_0xa911fe){_0x12df3b['push'](_0x12df3b['shift']());}};_0x1c99bf(++_0x2aa1ef);}(a382_0x2aa1,0xb6));const a382_0x1c99=function(_0x12df3b,_0x2aa1ef){_0x12df3b=_0x12df3b-0x0;let _0x1c99bf=a382_0x2aa1[_0x12df3b];return _0x1c99bf;};const _0x1840ad=a382_0x1c99;'use strict';const _=require(_0x1840ad('0x5')),qs=require(_0x1840ad('0xe')),logger=require(_0x1840ad('0xd'))(_0x1840ad('0x10')),db=require('../../mysqldb')['db'],{Op}=require(_0x1840ad('0x16'));function respondWithResult(_0xa911fe,_0x3df499){return _0x3df499=_0x3df499||0xc8,function(_0x3f2c49){if(_0x3f2c49)return _0xa911fe['status'](_0x3df499)['json'](_0x3f2c49);};}function respondWithFilteredResult(_0xfd0972,_0x585941){return function(_0x2baaa4){const _0xb91597=a382_0x1c99;if(_0x2baaa4){const _0xfa3b4e=_0x2baaa4[_0xb91597('0x1b')],_0x48d0a0=_0x585941[_0xb91597('0x27')];let _0x449c62=_0x585941[_0xb91597('0x27')]+_0x585941[_0xb91597('0x24')],_0x1dbb5a;return _0x449c62>=_0xfa3b4e?(_0x449c62=_0xfa3b4e,_0x1dbb5a=0xc8):_0x1dbb5a=0xce,_0xfd0972['status'](_0x1dbb5a),_0xfd0972[_0xb91597('0x19')](_0xb91597('0xf'),_0x48d0a0+'-'+_0x449c62+'/'+_0xfa3b4e)[_0xb91597('0x2a')](_0x2baaa4);}return null;};}function saveUpdates(_0x56381e){return function(_0x25c8a7){const _0x2eab9c=a382_0x1c99;if(_0x25c8a7)return _0x25c8a7[_0x2eab9c('0x26')](_0x56381e)[_0x2eab9c('0x2b')](function(_0x4f5600){return _0x4f5600;});return null;};}function removeEntity(_0x8836bb){return function(_0x178397){const _0x56a03e=a382_0x1c99;if(_0x178397)return _0x178397[_0x56a03e('0x17')]()[_0x56a03e('0x2b')](function(){const _0x50bef4=_0x56a03e;_0x8836bb[_0x50bef4('0x2d')](0xcc)['end']();});};}function handleEntityNotFound(_0x47afa2){return function(_0x130817){const _0xf2253a=a382_0x1c99;return!_0x130817&&_0x47afa2[_0xf2253a('0x22')](0x194),_0x130817;};}function handleError(_0x4a6d56,_0x2d5dcb){return _0x2d5dcb=_0x2d5dcb||0x1f4,function(_0x528047){const _0x2a9794=a382_0x1c99;logger['error'](_0x528047[_0x2a9794('0x32')]),_0x528047[_0x2a9794('0x29')]&&delete _0x528047[_0x2a9794('0x29')],_0x4a6d56['status'](_0x2d5dcb)[_0x2a9794('0x15')](_0x528047);};}exports['index']=function(_0x5ef54e,_0x13dedf){const _0x2aced8=_0x1840ad;let _0x35b75a={};const _0x405612={},_0x1a5dff={'count':0x0,'rows':[]},_0x249545=_[_0x2aced8('0x14')](db[_0x2aced8('0x20')]['rawAttributes'],function(_0x459983){const _0x32e337=_0x2aced8;return{'name':_0x459983[_0x32e337('0x13')],'type':_0x459983[_0x32e337('0x30')][_0x32e337('0x31')]};});_0x405612[_0x2aced8('0x1')]=_[_0x2aced8('0x14')](_0x249545,'name'),_0x405612[_0x2aced8('0x23')]=_[_0x2aced8('0x1d')](_0x5ef54e[_0x2aced8('0x23')]),_0x405612[_0x2aced8('0x12')]=_[_0x2aced8('0x18')](_0x405612[_0x2aced8('0x1')],_0x405612[_0x2aced8('0x23')]),_0x35b75a[_0x2aced8('0x6')]=_[_0x2aced8('0x18')](_0x405612[_0x2aced8('0x1')],qs[_0x2aced8('0xc')](_0x5ef54e[_0x2aced8('0x23')][_0x2aced8('0xc')])),_0x35b75a['attributes']=_0x35b75a['attributes']['length']?_0x35b75a[_0x2aced8('0x6')]:_0x405612[_0x2aced8('0x1')];typeof _0x5ef54e[_0x2aced8('0x23')][_0x2aced8('0x3')]==='undefined'&&(_0x35b75a[_0x2aced8('0x24')]=qs[_0x2aced8('0x24')](_0x5ef54e['query']['limit']),_0x35b75a[_0x2aced8('0x27')]=qs[_0x2aced8('0x27')](_0x5ef54e[_0x2aced8('0x23')][_0x2aced8('0x27')]));_0x35b75a['order']=qs[_0x2aced8('0x7')](_0x5ef54e[_0x2aced8('0x23')]['sort']),_0x35b75a[_0x2aced8('0x9')]=qs[_0x2aced8('0x12')](_[_0x2aced8('0x11')](_0x5ef54e[_0x2aced8('0x23')],_0x405612[_0x2aced8('0x12')]),_0x249545);_0x5ef54e[_0x2aced8('0x23')]['filter']&&(_0x35b75a['where']=_[_0x2aced8('0x1e')](_0x35b75a[_0x2aced8('0x9')],{[Op['or']]:_[_0x2aced8('0x14')](_0x249545,function(_0x31d482){const _0xf25536=_0x2aced8;if(_0x31d482[_0xf25536('0x30')]!=='VIRTUAL'){const _0x95ec76={};return _0x95ec76[_0x31d482[_0xf25536('0x29')]]={[Op[_0xf25536('0xa')]]:'%'+_0x5ef54e[_0xf25536('0x23')]['filter']+'%'},_0x95ec76;}})}));_0x35b75a=_[_0x2aced8('0x1e')]({},_0x35b75a,_0x5ef54e[_0x2aced8('0x21')]);const _0x3cdae5={'where':_0x35b75a['where']};return db[_0x2aced8('0x20')][_0x2aced8('0x1b')](_0x3cdae5)[_0x2aced8('0x2b')](function(_0x4dce25){const _0x509f69=_0x2aced8;return _0x1a5dff[_0x509f69('0x1b')]=_0x4dce25,_0x5ef54e[_0x509f69('0x23')][_0x509f69('0xb')]&&(_0x35b75a['include']=[{'all':!![]}]),db[_0x509f69('0x20')][_0x509f69('0x2c')](_0x35b75a);})[_0x2aced8('0x2b')](function(_0x87e15e){const _0x4a6e5d=_0x2aced8;return _0x1a5dff[_0x4a6e5d('0x1f')]=_0x87e15e,_0x1a5dff;})['then'](respondWithFilteredResult(_0x13dedf,_0x35b75a))[_0x2aced8('0x4')](handleError(_0x13dedf,null));},exports[_0x1840ad('0x2f')]=function(_0x5a2be7,_0x365457){const _0x2b56d1=_0x1840ad;let _0x5f5c60={'raw':!![],'where':{'id':_0x5a2be7[_0x2b56d1('0x25')]['id']}};const _0x3b4786={};return _0x3b4786['model']=_[_0x2b56d1('0x1d')](db['JscriptyQuestionReport'][_0x2b56d1('0x0')]),_0x3b4786[_0x2b56d1('0x23')]=_[_0x2b56d1('0x1d')](_0x5a2be7[_0x2b56d1('0x23')]),_0x3b4786[_0x2b56d1('0x12')]=_[_0x2b56d1('0x18')](_0x3b4786['model'],_0x3b4786[_0x2b56d1('0x23')]),_0x5f5c60[_0x2b56d1('0x6')]=_[_0x2b56d1('0x18')](_0x3b4786[_0x2b56d1('0x1')],qs[_0x2b56d1('0xc')](_0x5a2be7['query'][_0x2b56d1('0xc')])),_0x5f5c60['attributes']=_0x5f5c60[_0x2b56d1('0x6')][_0x2b56d1('0x2e')]?_0x5f5c60[_0x2b56d1('0x6')]:_0x3b4786['model'],_0x5a2be7['query']['includeAll']&&(_0x5f5c60[_0x2b56d1('0x8')]=[{'all':!![]}]),_0x5f5c60=_[_0x2b56d1('0x1e')]({},_0x5f5c60,_0x5a2be7[_0x2b56d1('0x21')]),db['JscriptyQuestionReport'][_0x2b56d1('0x28')](_0x5f5c60)[_0x2b56d1('0x2b')](handleEntityNotFound(_0x365457,null))['then'](respondWithResult(_0x365457,null))[_0x2b56d1('0x4')](handleError(_0x365457,null));},exports['create']=function(_0x44cf45,_0x2751ec){const _0x5bbff5=_0x1840ad;return db[_0x5bbff5('0x20')][_0x5bbff5('0x2')](_0x44cf45[_0x5bbff5('0x1a')],{})[_0x5bbff5('0x2b')](respondWithResult(_0x2751ec,0xc9))[_0x5bbff5('0x4')](handleError(_0x2751ec,null));},exports[_0x1840ad('0x26')]=function(_0x1991f2,_0x104022){const _0x3d42e0=_0x1840ad;return _0x1991f2[_0x3d42e0('0x1a')]['id']&&delete _0x1991f2['body']['id'],db[_0x3d42e0('0x20')][_0x3d42e0('0x28')]({'where':{'id':_0x1991f2[_0x3d42e0('0x25')]['id']}})[_0x3d42e0('0x2b')](handleEntityNotFound(_0x104022,null))[_0x3d42e0('0x2b')](saveUpdates(_0x1991f2['body'],null))[_0x3d42e0('0x2b')](respondWithResult(_0x104022,null))[_0x3d42e0('0x4')](handleError(_0x104022,null));},exports[_0x1840ad('0x17')]=function(_0x56a3ca,_0xee2df2){const _0x2dbe5a=_0x1840ad;return db['JscriptyQuestionReport'][_0x2dbe5a('0x28')]({'where':{'id':_0x56a3ca[_0x2dbe5a('0x25')]['id']}})[_0x2dbe5a('0x2b')](handleEntityNotFound(_0xee2df2,null))['then'](removeEntity(_0xee2df2,null))[_0x2dbe5a('0x4')](handleError(_0xee2df2,null));},exports['describe']=function(_0x5c71a3,_0x4c5fc7){const _0x15c1e2=_0x1840ad;return db[_0x15c1e2('0x20')][_0x15c1e2('0x1c')]()[_0x15c1e2('0x2b')](respondWithResult(_0x4c5fc7,null))['catch'](handleError(_0x4c5fc7,null));}; \ No newline at end of file diff --git a/server/api/jscriptyQuestionReport/jscriptyQuestionReport.model.js b/server/api/jscriptyQuestionReport/jscriptyQuestionReport.model.js index 191b5b1..c735129 100644 --- a/server/api/jscriptyQuestionReport/jscriptyQuestionReport.model.js +++ b/server/api/jscriptyQuestionReport/jscriptyQuestionReport.model.js @@ -1 +1 @@ -const a383_0x1402=['exports','./jscriptyQuestionReport.attributes','report_jscripty_questions'];(function(_0x27757e,_0x14022e){const _0x17bc1f=function(_0x2b01b4){while(--_0x2b01b4){_0x27757e['push'](_0x27757e['shift']());}};_0x17bc1f(++_0x14022e);}(a383_0x1402,0xa7));const a383_0x17bc=function(_0x27757e,_0x14022e){_0x27757e=_0x27757e-0x0;let _0x17bc1f=a383_0x1402[_0x27757e];return _0x17bc1f;};const _0x4b3547=a383_0x17bc;'use strict';const attributes=require(_0x4b3547('0x2'));module[_0x4b3547('0x1')]=function(_0x2b01b4){const _0x4163fe=_0x4b3547,_0x2080c1=_0x2b01b4['define']('JscriptyQuestionReport',attributes,{'tableName':_0x4163fe('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2080c1;}; \ No newline at end of file +const a383_0x2f44=['exports','report_jscripty_questions','JscriptyQuestionReport'];(function(_0x3c96e2,_0x2f44f3){const _0x41055f=function(_0x588adc){while(--_0x588adc){_0x3c96e2['push'](_0x3c96e2['shift']());}};_0x41055f(++_0x2f44f3);}(a383_0x2f44,0x169));const a383_0x4105=function(_0x3c96e2,_0x2f44f3){_0x3c96e2=_0x3c96e2-0x0;let _0x41055f=a383_0x2f44[_0x3c96e2];return _0x41055f;};const _0xa78c47=a383_0x4105;'use strict';const attributes=require('./jscriptyQuestionReport.attributes');module[_0xa78c47('0x2')]=function(_0x588adc){const _0x1eedbf=_0xa78c47,_0x8d82b=_0x588adc['define'](_0x1eedbf('0x1'),attributes,{'tableName':_0x1eedbf('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x8d82b;}; \ No newline at end of file diff --git a/server/api/jscriptySessionReport/index.js b/server/api/jscriptySessionReport/index.js index b23cf05..e2b9419 100644 --- a/server/api/jscriptySessionReport/index.js +++ b/server/api/jscriptySessionReport/index.js @@ -1 +1 @@ -const a384_0x2e2a=['put','Router','get','post','express','/:id','/describe','update','isAuthenticated','/:id/questions','getQuestions','index','show','../../components/auth/service','destroy'];(function(_0x48d9c1,_0x2e2a5f){const _0x1cf0a1=function(_0x3a97f8){while(--_0x3a97f8){_0x48d9c1['push'](_0x48d9c1['shift']());}};_0x1cf0a1(++_0x2e2a5f);}(a384_0x2e2a,0x72));const a384_0x1cf0=function(_0x48d9c1,_0x2e2a5f){_0x48d9c1=_0x48d9c1-0x0;let _0x1cf0a1=a384_0x2e2a[_0x48d9c1];return _0x1cf0a1;};const _0x10b0fe=a384_0x1cf0;'use strict';const express=require(_0x10b0fe('0xa')),router=express[_0x10b0fe('0x7')](),auth=require(_0x10b0fe('0x4')),controller=require('./jscriptySessionReport.controller');router[_0x10b0fe('0x8')]('/',auth[_0x10b0fe('0xe')](),controller[_0x10b0fe('0x2')]),router['get'](_0x10b0fe('0xc'),auth[_0x10b0fe('0xe')](),controller['describe']),router[_0x10b0fe('0x8')](_0x10b0fe('0xb'),auth[_0x10b0fe('0xe')](),controller[_0x10b0fe('0x3')]),router['get'](_0x10b0fe('0x0'),auth[_0x10b0fe('0xe')](),controller[_0x10b0fe('0x1')]),router[_0x10b0fe('0x9')]('/',auth[_0x10b0fe('0xe')](),controller['create']),router[_0x10b0fe('0x6')]('/:id',auth[_0x10b0fe('0xe')](),controller[_0x10b0fe('0xd')]),router['delete'](_0x10b0fe('0xb'),auth[_0x10b0fe('0xe')](),controller[_0x10b0fe('0x5')]),module['exports']=router; \ No newline at end of file +const a384_0x11a8=['describe','isAuthenticated','../../components/auth/service','/:id','delete','get','express','exports','index','post','Router','show','./jscriptySessionReport.controller','destroy','put','create','/describe'];(function(_0x110cf0,_0x11a8e){const _0x102025=function(_0x205772){while(--_0x205772){_0x110cf0['push'](_0x110cf0['shift']());}};_0x102025(++_0x11a8e);}(a384_0x11a8,0x17e));const a384_0x1020=function(_0x110cf0,_0x11a8e){_0x110cf0=_0x110cf0-0x0;let _0x102025=a384_0x11a8[_0x110cf0];return _0x102025;};const _0x440081=a384_0x1020;'use strict';const express=require(_0x440081('0xf')),router=express[_0x440081('0x2')](),auth=require(_0x440081('0xb')),controller=require(_0x440081('0x4'));router[_0x440081('0xe')]('/',auth[_0x440081('0xa')](),controller[_0x440081('0x0')]),router[_0x440081('0xe')](_0x440081('0x8'),auth['isAuthenticated'](),controller[_0x440081('0x9')]),router[_0x440081('0xe')](_0x440081('0xc'),auth['isAuthenticated'](),controller[_0x440081('0x3')]),router[_0x440081('0xe')]('/:id/questions',auth['isAuthenticated'](),controller['getQuestions']),router[_0x440081('0x1')]('/',auth[_0x440081('0xa')](),controller[_0x440081('0x7')]),router[_0x440081('0x6')](_0x440081('0xc'),auth[_0x440081('0xa')](),controller['update']),router[_0x440081('0xd')]('/:id',auth[_0x440081('0xa')](),controller[_0x440081('0x5')]),module[_0x440081('0x10')]=router; \ No newline at end of file diff --git a/server/api/jscriptySessionReport/jscriptySessionReport.attributes.js b/server/api/jscriptySessionReport/jscriptySessionReport.attributes.js index ad33287..f95a48f 100644 --- a/server/api/jscriptySessionReport/jscriptySessionReport.attributes.js +++ b/server/api/jscriptySessionReport/jscriptySessionReport.attributes.js @@ -1 +1 @@ -const a385_0x328d=['DATE','moment','STRING','sequelize','endtime','starttime','YYYY-MM-DD\x20HH:mm:ss','format','exports','BOOLEAN'];(function(_0x37d62a,_0x328df5){const _0x1ff5fa=function(_0x42575e){while(--_0x42575e){_0x37d62a['push'](_0x37d62a['shift']());}};_0x1ff5fa(++_0x328df5);}(a385_0x328d,0x120));const a385_0x1ff5=function(_0x37d62a,_0x328df5){_0x37d62a=_0x37d62a-0x0;let _0x1ff5fa=a385_0x328d[_0x37d62a];return _0x1ff5fa;};const _0x378c49=a385_0x1ff5;'use strict';const moment=require(_0x378c49('0x3')),Sequelize=require(_0x378c49('0x5'));module[_0x378c49('0x0')]={'starttime':{'type':Sequelize[_0x378c49('0x2')],'set':function(_0x42575e){const _0x5ab4ea=_0x378c49;this['setDataValue'](_0x5ab4ea('0x7'),_0x42575e),this['setDataValue'](_0x5ab4ea('0x6'),moment()[_0x5ab4ea('0x9')](_0x5ab4ea('0x8')));}},'endtime':{'type':Sequelize['DATE']},'membername':{'type':Sequelize[_0x378c49('0x4')]},'projectname':{'type':Sequelize[_0x378c49('0x4')]},'queue':{'type':Sequelize[_0x378c49('0x4')]},'uniqueid':{'type':Sequelize[_0x378c49('0x4')]},'calleridname':{'type':Sequelize[_0x378c49('0x4')]},'calleridnum':{'type':Sequelize['STRING']},'completed':{'type':Sequelize[_0x378c49('0x1')],'defaultValue':![]}}; \ No newline at end of file +const a385_0x451f=['moment','setDataValue','starttime','STRING','BOOLEAN','sequelize','DATE','exports','format'];(function(_0x55cb72,_0x451ffa){const _0x8da68c=function(_0x322bdf){while(--_0x322bdf){_0x55cb72['push'](_0x55cb72['shift']());}};_0x8da68c(++_0x451ffa);}(a385_0x451f,0x1f0));const a385_0x8da6=function(_0x55cb72,_0x451ffa){_0x55cb72=_0x55cb72-0x0;let _0x8da68c=a385_0x451f[_0x55cb72];return _0x8da68c;};const _0x122e8f=a385_0x8da6;'use strict';const moment=require(_0x122e8f('0x8')),Sequelize=require(_0x122e8f('0x4'));module[_0x122e8f('0x6')]={'starttime':{'type':Sequelize[_0x122e8f('0x5')],'set':function(_0x322bdf){const _0x37477b=_0x122e8f;this[_0x37477b('0x0')](_0x37477b('0x1'),_0x322bdf),this[_0x37477b('0x0')]('endtime',moment()[_0x37477b('0x7')]('YYYY-MM-DD\x20HH:mm:ss'));}},'endtime':{'type':Sequelize[_0x122e8f('0x5')]},'membername':{'type':Sequelize[_0x122e8f('0x2')]},'projectname':{'type':Sequelize[_0x122e8f('0x2')]},'queue':{'type':Sequelize['STRING']},'uniqueid':{'type':Sequelize['STRING']},'calleridname':{'type':Sequelize[_0x122e8f('0x2')]},'calleridnum':{'type':Sequelize['STRING']},'completed':{'type':Sequelize[_0x122e8f('0x3')],'defaultValue':![]}}; \ No newline at end of file diff --git a/server/api/jscriptySessionReport/jscriptySessionReport.controller.js b/server/api/jscriptySessionReport/jscriptySessionReport.controller.js index dac8c10..344b4af 100644 --- a/server/api/jscriptySessionReport/jscriptySessionReport.controller.js +++ b/server/api/jscriptySessionReport/jscriptySessionReport.controller.js @@ -1 +1 @@ -const a386_0xb471=['set','rawAttributes','limit','keys','undefined','VIRTUAL','pick','catch','map','findOne','like','order','error','includeAll','where','stack','count','query','create','sendStatus','json','api','show','then','offset','sort','rows','status','../../components/parsers/qs','merge','describe','include','intersection','../../mysqldb','filters','lodash','JscriptyQuestionReport','SessionId','getQuestions','destroy','key','options','end','update','JscriptySessionReport','body','attributes','length','filter','name','fieldName','fields','model','params','type','../../config/logger'];(function(_0x59ff7f,_0xb471aa){const _0x37795f=function(_0x1be118){while(--_0x1be118){_0x59ff7f['push'](_0x59ff7f['shift']());}};_0x37795f(++_0xb471aa);}(a386_0xb471,0x7a));const a386_0x3779=function(_0x59ff7f,_0xb471aa){_0x59ff7f=_0x59ff7f-0x0;let _0x37795f=a386_0xb471[_0x59ff7f];return _0x37795f;};const _0x119e59=a386_0x3779;'use strict';const _=require(_0x119e59('0x19')),qs=require(_0x119e59('0x12')),logger=require(_0x119e59('0x2d'))(_0x119e59('0xb')),db=require(_0x119e59('0x17'))['db'],{Op}=require('sequelize');function respondWithResult(_0x1be118,_0x5f4156){return _0x5f4156=_0x5f4156||0xc8,function(_0x1eceb5){const _0x4cd39e=a386_0x3779;if(_0x1eceb5)return _0x1be118[_0x4cd39e('0x11')](_0x5f4156)[_0x4cd39e('0xa')](_0x1eceb5);};}function respondWithFilteredResult(_0x5b7f65,_0x4a724f){return function(_0xaff360){const _0x480314=a386_0x3779;if(_0xaff360){const _0x1203fa=_0xaff360[_0x480314('0x6')],_0x2be0c2=_0x4a724f['offset'];let _0x333083=_0x4a724f[_0x480314('0xe')]+_0x4a724f[_0x480314('0x30')],_0x2097a3;return _0x333083>=_0x1203fa?(_0x333083=_0x1203fa,_0x2097a3=0xc8):_0x2097a3=0xce,_0x5b7f65['status'](_0x2097a3),_0x5b7f65[_0x480314('0x2e')]('Content-Range',_0x2be0c2+'-'+_0x333083+'/'+_0x1203fa)[_0x480314('0xa')](_0xaff360);}return null;};}function saveUpdates(_0x46347e){return function(_0x9b4dd3){const _0x26e6e9=a386_0x3779;if(_0x9b4dd3)return _0x9b4dd3[_0x26e6e9('0x21')](_0x46347e)['then'](function(_0x2bf7bb){return _0x2bf7bb;});return null;};}function removeEntity(_0xd33260){return function(_0x307b5c){const _0x2cc3eb=a386_0x3779;if(_0x307b5c)return _0x307b5c[_0x2cc3eb('0x1d')]()['then'](function(){const _0x20e6af=_0x2cc3eb;_0xd33260[_0x20e6af('0x11')](0xcc)[_0x20e6af('0x20')]();});};}function handleEntityNotFound(_0x19bdbc){return function(_0x5d9e01){const _0x5f36cb=a386_0x3779;return!_0x5d9e01&&_0x19bdbc[_0x5f36cb('0x9')](0x194),_0x5d9e01;};}function handleError(_0x5cc9a3,_0x1d3b26){return _0x1d3b26=_0x1d3b26||0x1f4,function(_0xc43974){const _0x146e89=a386_0x3779;logger[_0x146e89('0x2')](_0xc43974[_0x146e89('0x5')]),_0xc43974[_0x146e89('0x27')]&&delete _0xc43974[_0x146e89('0x27')],_0x5cc9a3[_0x146e89('0x11')](_0x1d3b26)['send'](_0xc43974);};}exports['index']=function(_0x1020a0,_0x538ed3){const _0x28df1d=_0x119e59;let _0x48f0cc={};const _0x1462c1={},_0x4dd974={'count':0x0,'rows':[]},_0x4454d1=_[_0x28df1d('0x36')](db[_0x28df1d('0x22')][_0x28df1d('0x2f')],function(_0x25e62e){const _0x1386a6=_0x28df1d;return{'name':_0x25e62e[_0x1386a6('0x28')],'type':_0x25e62e[_0x1386a6('0x2c')][_0x1386a6('0x1e')]};});_0x1462c1[_0x28df1d('0x2a')]=_[_0x28df1d('0x36')](_0x4454d1,'name'),_0x1462c1[_0x28df1d('0x7')]=_[_0x28df1d('0x31')](_0x1020a0['query']),_0x1462c1[_0x28df1d('0x18')]=_[_0x28df1d('0x16')](_0x1462c1[_0x28df1d('0x2a')],_0x1462c1[_0x28df1d('0x7')]),_0x48f0cc[_0x28df1d('0x24')]=_['intersection'](_0x1462c1['model'],qs[_0x28df1d('0x29')](_0x1020a0[_0x28df1d('0x7')][_0x28df1d('0x29')])),_0x48f0cc['attributes']=_0x48f0cc['attributes'][_0x28df1d('0x25')]?_0x48f0cc[_0x28df1d('0x24')]:_0x1462c1[_0x28df1d('0x2a')];typeof _0x1020a0[_0x28df1d('0x7')]['nolimit']===_0x28df1d('0x32')&&(_0x48f0cc[_0x28df1d('0x30')]=qs['limit'](_0x1020a0[_0x28df1d('0x7')][_0x28df1d('0x30')]),_0x48f0cc[_0x28df1d('0xe')]=qs[_0x28df1d('0xe')](_0x1020a0[_0x28df1d('0x7')][_0x28df1d('0xe')]));_0x48f0cc[_0x28df1d('0x1')]=qs['sort'](_0x1020a0[_0x28df1d('0x7')]['sort']),_0x48f0cc['where']=qs['filters'](_[_0x28df1d('0x34')](_0x1020a0[_0x28df1d('0x7')],_0x1462c1['filters']),_0x4454d1);_0x1020a0[_0x28df1d('0x7')][_0x28df1d('0x26')]&&(_0x48f0cc[_0x28df1d('0x4')]=_['merge'](_0x48f0cc[_0x28df1d('0x4')],{[Op['or']]:_[_0x28df1d('0x36')](_0x4454d1,function(_0x5ca428){const _0xf7d09f=_0x28df1d;if(_0x5ca428[_0xf7d09f('0x2c')]!==_0xf7d09f('0x33')){const _0x1784b8={};return _0x1784b8[_0x5ca428[_0xf7d09f('0x27')]]={[Op[_0xf7d09f('0x0')]]:'%'+_0x1020a0[_0xf7d09f('0x7')][_0xf7d09f('0x26')]+'%'},_0x1784b8;}})}));_0x48f0cc=_[_0x28df1d('0x13')]({},_0x48f0cc,_0x1020a0[_0x28df1d('0x1f')]);const _0x3f2daf={'where':_0x48f0cc[_0x28df1d('0x4')]};return db[_0x28df1d('0x22')][_0x28df1d('0x6')](_0x3f2daf)[_0x28df1d('0xd')](function(_0x5832a1){const _0x117edd=_0x28df1d;return _0x4dd974[_0x117edd('0x6')]=_0x5832a1,_0x1020a0['query'][_0x117edd('0x3')]&&(_0x48f0cc[_0x117edd('0x15')]=[{'all':!![]}]),db['JscriptySessionReport']['findAll'](_0x48f0cc);})[_0x28df1d('0xd')](function(_0x58c613){const _0x52578e=_0x28df1d;return _0x4dd974[_0x52578e('0x10')]=_0x58c613,_0x4dd974;})[_0x28df1d('0xd')](respondWithFilteredResult(_0x538ed3,_0x48f0cc))[_0x28df1d('0x35')](handleError(_0x538ed3,null));},exports[_0x119e59('0xc')]=function(_0x45fad3,_0xc538b){const _0x4d51c1=_0x119e59;let _0x22a40c={'raw':!![],'where':{'id':_0x45fad3[_0x4d51c1('0x2b')]['id']}};const _0x550815={};return _0x550815[_0x4d51c1('0x2a')]=_[_0x4d51c1('0x31')](db[_0x4d51c1('0x22')]['rawAttributes']),_0x550815[_0x4d51c1('0x7')]=_[_0x4d51c1('0x31')](_0x45fad3['query']),_0x550815['filters']=_['intersection'](_0x550815[_0x4d51c1('0x2a')],_0x550815[_0x4d51c1('0x7')]),_0x22a40c[_0x4d51c1('0x24')]=_[_0x4d51c1('0x16')](_0x550815[_0x4d51c1('0x2a')],qs[_0x4d51c1('0x29')](_0x45fad3['query'][_0x4d51c1('0x29')])),_0x22a40c['attributes']=_0x22a40c['attributes'][_0x4d51c1('0x25')]?_0x22a40c[_0x4d51c1('0x24')]:_0x550815['model'],_0x45fad3['query'][_0x4d51c1('0x3')]&&(_0x22a40c['include']=[{'all':!![]}]),_0x22a40c=_[_0x4d51c1('0x13')]({},_0x22a40c,_0x45fad3['options']),db[_0x4d51c1('0x22')][_0x4d51c1('0x37')](_0x22a40c)[_0x4d51c1('0xd')](handleEntityNotFound(_0xc538b,null))['then'](respondWithResult(_0xc538b,null))['catch'](handleError(_0xc538b,null));},exports[_0x119e59('0x8')]=function(_0x23ba98,_0x5b609f){const _0x16de59=_0x119e59;return db[_0x16de59('0x22')][_0x16de59('0x8')](_0x23ba98['body'],{})['then'](respondWithResult(_0x5b609f,0xc9))[_0x16de59('0x35')](handleError(_0x5b609f,null));},exports[_0x119e59('0x21')]=function(_0x11549e,_0x43b9e0){const _0x129f5d=_0x119e59;return _0x11549e[_0x129f5d('0x23')]['id']&&delete _0x11549e[_0x129f5d('0x23')]['id'],db['JscriptySessionReport'][_0x129f5d('0x37')]({'where':{'id':_0x11549e['params']['id']}})['then'](handleEntityNotFound(_0x43b9e0,null))[_0x129f5d('0xd')](saveUpdates(_0x11549e[_0x129f5d('0x23')],null))[_0x129f5d('0xd')](respondWithResult(_0x43b9e0,null))[_0x129f5d('0x35')](handleError(_0x43b9e0,null));},exports[_0x119e59('0x1d')]=function(_0x1ff129,_0xcd1dfa){const _0x852d99=_0x119e59;return db[_0x852d99('0x22')][_0x852d99('0x37')]({'where':{'id':_0x1ff129['params']['id']}})[_0x852d99('0xd')](handleEntityNotFound(_0xcd1dfa,null))[_0x852d99('0xd')](removeEntity(_0xcd1dfa,null))[_0x852d99('0x35')](handleError(_0xcd1dfa,null));},exports['describe']=function(_0x1427f3,_0x4ecb35){const _0x262707=_0x119e59;return db[_0x262707('0x22')][_0x262707('0x14')]()[_0x262707('0xd')](respondWithResult(_0x4ecb35,null))[_0x262707('0x35')](handleError(_0x4ecb35,null));},exports[_0x119e59('0x1c')]=function(_0x466e42,_0x3422db){const _0x17e31d=_0x119e59;let _0xf69385={'raw':!![],'where':{}};const _0x744555={},_0x286caa={'count':0x0,'rows':[]};return db[_0x17e31d('0x22')][_0x17e31d('0x37')]({'where':{'id':_0x466e42[_0x17e31d('0x2b')]['id']}})[_0x17e31d('0xd')](handleEntityNotFound(_0x3422db,null))[_0x17e31d('0xd')](function(_0x1bfa19){const _0x5ed308=_0x17e31d;if(_0x1bfa19)return _0x744555[_0x5ed308('0x2a')]=_['keys'](db[_0x5ed308('0x1a')]['rawAttributes']),_0x744555[_0x5ed308('0x7')]=_['keys'](_0x466e42[_0x5ed308('0x7')]),_0x744555[_0x5ed308('0x18')]=_[_0x5ed308('0x16')](_0x744555[_0x5ed308('0x2a')],_0x744555[_0x5ed308('0x7')]),_0xf69385[_0x5ed308('0x24')]=_[_0x5ed308('0x16')](_0x744555[_0x5ed308('0x2a')],qs[_0x5ed308('0x29')](_0x466e42[_0x5ed308('0x7')]['fields'])),_0xf69385[_0x5ed308('0x24')]=_0xf69385[_0x5ed308('0x24')][_0x5ed308('0x25')]?_0xf69385['attributes']:_0x744555[_0x5ed308('0x2a')],typeof _0x466e42[_0x5ed308('0x7')]['nolimit']===_0x5ed308('0x32')&&(_0xf69385[_0x5ed308('0x30')]=qs[_0x5ed308('0x30')](_0x466e42['query'][_0x5ed308('0x30')]),_0xf69385[_0x5ed308('0xe')]=qs[_0x5ed308('0xe')](_0x466e42[_0x5ed308('0x7')][_0x5ed308('0xe')])),_0xf69385[_0x5ed308('0x1')]=qs[_0x5ed308('0xf')](_0x466e42[_0x5ed308('0x7')][_0x5ed308('0xf')]),_0xf69385[_0x5ed308('0x4')]=qs['filters'](_['pick'](_0x466e42[_0x5ed308('0x7')],_0x744555[_0x5ed308('0x18')])),_0xf69385['where'][_0x5ed308('0x1b')]=_0x1bfa19['id'],_0x466e42[_0x5ed308('0x7')][_0x5ed308('0x26')]&&(_0xf69385[_0x5ed308('0x4')]=_[_0x5ed308('0x13')](_0xf69385[_0x5ed308('0x4')],{[Op['or']]:_[_0x5ed308('0x36')](_0xf69385[_0x5ed308('0x24')],function(_0xf8009e){const _0x22effd=_0x5ed308,_0x472e5e={};return _0x472e5e[_0xf8009e]={[Op[_0x22effd('0x0')]]:'%'+_0x466e42[_0x22effd('0x7')][_0x22effd('0x26')]+'%'},_0x472e5e;})})),_0xf69385=_['merge']({},_0xf69385,_0x466e42['options']),db['JscriptyQuestionReport'][_0x5ed308('0x6')]({'where':_0xf69385[_0x5ed308('0x4')]})[_0x5ed308('0xd')](function(_0x401d52){const _0x3026ee=_0x5ed308;return _0x286caa[_0x3026ee('0x6')]=_0x401d52,_0x466e42[_0x3026ee('0x7')]['includeAll']&&(_0xf69385[_0x3026ee('0x15')]=[{'all':!![]}]),db[_0x3026ee('0x1a')]['findAll'](_0xf69385);})['then'](function(_0x5924c3){return _0x286caa['rows']=_0x5924c3,_0x286caa;});})[_0x17e31d('0xd')](respondWithFilteredResult(_0x3422db,_0xf69385))[_0x17e31d('0x35')](handleError(_0x3422db,null));}; \ No newline at end of file +const a386_0x4096=['findOne','fields','set','sort','attributes','key','catch','undefined','merge','name','order','pick','JscriptySessionReport','where','intersection','Content-Range','index','options','filters','keys','fieldName','../../config/logger','describe','findAll','json','include','filter','like','create','type','then','send','sendStatus','count','rows','VIRTUAL','length','stack','body','nolimit','model','SessionId','lodash','status','rawAttributes','params','../../mysqldb','query','show','map','sequelize','destroy','api','JscriptyQuestionReport','includeAll','error','update','../../components/parsers/qs','limit','offset'];(function(_0x378915,_0x40960a){const _0x46cae3=function(_0x46423b){while(--_0x46423b){_0x378915['push'](_0x378915['shift']());}};_0x46cae3(++_0x40960a);}(a386_0x4096,0x135));const a386_0x46ca=function(_0x378915,_0x40960a){_0x378915=_0x378915-0x0;let _0x46cae3=a386_0x4096[_0x378915];return _0x46cae3;};const _0x41d78b=a386_0x46ca;'use strict';const _=require(_0x41d78b('0x21')),qs=require(_0x41d78b('0x30')),logger=require(_0x41d78b('0xc'))(_0x41d78b('0x2b')),db=require(_0x41d78b('0x25'))['db'],{Op}=require(_0x41d78b('0x29'));function respondWithResult(_0x46423b,_0x4431a1){return _0x4431a1=_0x4431a1||0xc8,function(_0x452aed){const _0x3e1313=a386_0x46ca;if(_0x452aed)return _0x46423b[_0x3e1313('0x22')](_0x4431a1)['json'](_0x452aed);};}function respondWithFilteredResult(_0xc4b91b,_0x59d073){return function(_0x37cd48){const _0x1e010d=a386_0x46ca;if(_0x37cd48){const _0x5b4c60=_0x37cd48['count'],_0x35d79d=_0x59d073[_0x1e010d('0x32')];let _0x521f11=_0x59d073[_0x1e010d('0x32')]+_0x59d073[_0x1e010d('0x31')],_0x265320;return _0x521f11>=_0x5b4c60?(_0x521f11=_0x5b4c60,_0x265320=0xc8):_0x265320=0xce,_0xc4b91b[_0x1e010d('0x22')](_0x265320),_0xc4b91b[_0x1e010d('0x35')](_0x1e010d('0x6'),_0x35d79d+'-'+_0x521f11+'/'+_0x5b4c60)[_0x1e010d('0xf')](_0x37cd48);}return null;};}function saveUpdates(_0x12231b){return function(_0x165a31){const _0x2c1c9e=a386_0x46ca;if(_0x165a31)return _0x165a31[_0x2c1c9e('0x2f')](_0x12231b)[_0x2c1c9e('0x15')](function(_0x5c788a){return _0x5c788a;});return null;};}function removeEntity(_0xe419cc){return function(_0x4b6ae5){const _0x297614=a386_0x46ca;if(_0x4b6ae5)return _0x4b6ae5[_0x297614('0x2a')]()['then'](function(){const _0x30657a=_0x297614;_0xe419cc[_0x30657a('0x22')](0xcc)['end']();});};}function handleEntityNotFound(_0x48f6ca){return function(_0x576948){const _0xffb7ba=a386_0x46ca;return!_0x576948&&_0x48f6ca[_0xffb7ba('0x17')](0x194),_0x576948;};}function handleError(_0x2c6cae,_0x21f8d8){return _0x21f8d8=_0x21f8d8||0x1f4,function(_0x588f75){const _0x3aa496=a386_0x46ca;logger[_0x3aa496('0x2e')](_0x588f75[_0x3aa496('0x1c')]),_0x588f75['name']&&delete _0x588f75[_0x3aa496('0x0')],_0x2c6cae['status'](_0x21f8d8)[_0x3aa496('0x16')](_0x588f75);};}exports[_0x41d78b('0x7')]=function(_0x3ca0b9,_0x12412b){const _0x2c71cd=_0x41d78b;let _0x33c8de={};const _0x5747da={},_0x5c9b33={'count':0x0,'rows':[]},_0x55fd1d=_[_0x2c71cd('0x28')](db['JscriptySessionReport']['rawAttributes'],function(_0x211db4){const _0x8d0f03=_0x2c71cd;return{'name':_0x211db4[_0x8d0f03('0xb')],'type':_0x211db4[_0x8d0f03('0x14')][_0x8d0f03('0x38')]};});_0x5747da[_0x2c71cd('0x1f')]=_[_0x2c71cd('0x28')](_0x55fd1d,'name'),_0x5747da['query']=_['keys'](_0x3ca0b9[_0x2c71cd('0x26')]),_0x5747da[_0x2c71cd('0x9')]=_['intersection'](_0x5747da[_0x2c71cd('0x1f')],_0x5747da[_0x2c71cd('0x26')]),_0x33c8de[_0x2c71cd('0x37')]=_['intersection'](_0x5747da['model'],qs['fields'](_0x3ca0b9[_0x2c71cd('0x26')]['fields'])),_0x33c8de[_0x2c71cd('0x37')]=_0x33c8de[_0x2c71cd('0x37')][_0x2c71cd('0x1b')]?_0x33c8de[_0x2c71cd('0x37')]:_0x5747da[_0x2c71cd('0x1f')];typeof _0x3ca0b9[_0x2c71cd('0x26')][_0x2c71cd('0x1e')]===_0x2c71cd('0x3a')&&(_0x33c8de[_0x2c71cd('0x31')]=qs[_0x2c71cd('0x31')](_0x3ca0b9['query'][_0x2c71cd('0x31')]),_0x33c8de[_0x2c71cd('0x32')]=qs[_0x2c71cd('0x32')](_0x3ca0b9[_0x2c71cd('0x26')]['offset']));_0x33c8de[_0x2c71cd('0x1')]=qs[_0x2c71cd('0x36')](_0x3ca0b9['query'][_0x2c71cd('0x36')]),_0x33c8de['where']=qs[_0x2c71cd('0x9')](_['pick'](_0x3ca0b9[_0x2c71cd('0x26')],_0x5747da['filters']),_0x55fd1d);_0x3ca0b9[_0x2c71cd('0x26')][_0x2c71cd('0x11')]&&(_0x33c8de[_0x2c71cd('0x4')]=_[_0x2c71cd('0x3b')](_0x33c8de['where'],{[Op['or']]:_[_0x2c71cd('0x28')](_0x55fd1d,function(_0x13fc49){const _0x453df4=_0x2c71cd;if(_0x13fc49['type']!==_0x453df4('0x1a')){const _0x3324fb={};return _0x3324fb[_0x13fc49[_0x453df4('0x0')]]={[Op[_0x453df4('0x12')]]:'%'+_0x3ca0b9['query'][_0x453df4('0x11')]+'%'},_0x3324fb;}})}));_0x33c8de=_[_0x2c71cd('0x3b')]({},_0x33c8de,_0x3ca0b9[_0x2c71cd('0x8')]);const _0x41731b={'where':_0x33c8de[_0x2c71cd('0x4')]};return db[_0x2c71cd('0x3')][_0x2c71cd('0x18')](_0x41731b)['then'](function(_0x22eb98){const _0x287463=_0x2c71cd;return _0x5c9b33['count']=_0x22eb98,_0x3ca0b9[_0x287463('0x26')][_0x287463('0x2d')]&&(_0x33c8de['include']=[{'all':!![]}]),db['JscriptySessionReport'][_0x287463('0xe')](_0x33c8de);})['then'](function(_0x330451){const _0x1d9077=_0x2c71cd;return _0x5c9b33[_0x1d9077('0x19')]=_0x330451,_0x5c9b33;})[_0x2c71cd('0x15')](respondWithFilteredResult(_0x12412b,_0x33c8de))[_0x2c71cd('0x39')](handleError(_0x12412b,null));},exports[_0x41d78b('0x27')]=function(_0x4e7ec5,_0x426adf){const _0x2cf5c7=_0x41d78b;let _0x7a444={'raw':!![],'where':{'id':_0x4e7ec5[_0x2cf5c7('0x24')]['id']}};const _0x26aa40={};return _0x26aa40[_0x2cf5c7('0x1f')]=_['keys'](db[_0x2cf5c7('0x3')][_0x2cf5c7('0x23')]),_0x26aa40['query']=_[_0x2cf5c7('0xa')](_0x4e7ec5[_0x2cf5c7('0x26')]),_0x26aa40[_0x2cf5c7('0x9')]=_[_0x2cf5c7('0x5')](_0x26aa40['model'],_0x26aa40['query']),_0x7a444[_0x2cf5c7('0x37')]=_[_0x2cf5c7('0x5')](_0x26aa40[_0x2cf5c7('0x1f')],qs[_0x2cf5c7('0x34')](_0x4e7ec5['query'][_0x2cf5c7('0x34')])),_0x7a444[_0x2cf5c7('0x37')]=_0x7a444[_0x2cf5c7('0x37')][_0x2cf5c7('0x1b')]?_0x7a444[_0x2cf5c7('0x37')]:_0x26aa40['model'],_0x4e7ec5[_0x2cf5c7('0x26')][_0x2cf5c7('0x2d')]&&(_0x7a444[_0x2cf5c7('0x10')]=[{'all':!![]}]),_0x7a444=_[_0x2cf5c7('0x3b')]({},_0x7a444,_0x4e7ec5[_0x2cf5c7('0x8')]),db[_0x2cf5c7('0x3')][_0x2cf5c7('0x33')](_0x7a444)[_0x2cf5c7('0x15')](handleEntityNotFound(_0x426adf,null))['then'](respondWithResult(_0x426adf,null))['catch'](handleError(_0x426adf,null));},exports[_0x41d78b('0x13')]=function(_0x5c655b,_0x15f507){const _0x1367e3=_0x41d78b;return db[_0x1367e3('0x3')]['create'](_0x5c655b[_0x1367e3('0x1d')],{})[_0x1367e3('0x15')](respondWithResult(_0x15f507,0xc9))[_0x1367e3('0x39')](handleError(_0x15f507,null));},exports['update']=function(_0x359004,_0x554221){const _0x5c9c38=_0x41d78b;return _0x359004[_0x5c9c38('0x1d')]['id']&&delete _0x359004['body']['id'],db['JscriptySessionReport'][_0x5c9c38('0x33')]({'where':{'id':_0x359004[_0x5c9c38('0x24')]['id']}})[_0x5c9c38('0x15')](handleEntityNotFound(_0x554221,null))[_0x5c9c38('0x15')](saveUpdates(_0x359004[_0x5c9c38('0x1d')],null))[_0x5c9c38('0x15')](respondWithResult(_0x554221,null))['catch'](handleError(_0x554221,null));},exports[_0x41d78b('0x2a')]=function(_0x21c4a9,_0x3b94fa){const _0x2fa8bc=_0x41d78b;return db[_0x2fa8bc('0x3')][_0x2fa8bc('0x33')]({'where':{'id':_0x21c4a9[_0x2fa8bc('0x24')]['id']}})[_0x2fa8bc('0x15')](handleEntityNotFound(_0x3b94fa,null))[_0x2fa8bc('0x15')](removeEntity(_0x3b94fa,null))[_0x2fa8bc('0x39')](handleError(_0x3b94fa,null));},exports['describe']=function(_0x2f14a6,_0x4ed2d3){const _0x470791=_0x41d78b;return db[_0x470791('0x3')][_0x470791('0xd')]()[_0x470791('0x15')](respondWithResult(_0x4ed2d3,null))[_0x470791('0x39')](handleError(_0x4ed2d3,null));},exports['getQuestions']=function(_0x281d8a,_0xa065ee){const _0x4278d3=_0x41d78b;let _0x2a78a9={'raw':!![],'where':{}};const _0x152f86={},_0x26ed8f={'count':0x0,'rows':[]};return db[_0x4278d3('0x3')][_0x4278d3('0x33')]({'where':{'id':_0x281d8a[_0x4278d3('0x24')]['id']}})[_0x4278d3('0x15')](handleEntityNotFound(_0xa065ee,null))[_0x4278d3('0x15')](function(_0x358d48){const _0x402788=_0x4278d3;if(_0x358d48)return _0x152f86[_0x402788('0x1f')]=_[_0x402788('0xa')](db['JscriptyQuestionReport'][_0x402788('0x23')]),_0x152f86['query']=_[_0x402788('0xa')](_0x281d8a['query']),_0x152f86[_0x402788('0x9')]=_['intersection'](_0x152f86[_0x402788('0x1f')],_0x152f86[_0x402788('0x26')]),_0x2a78a9['attributes']=_[_0x402788('0x5')](_0x152f86[_0x402788('0x1f')],qs[_0x402788('0x34')](_0x281d8a[_0x402788('0x26')][_0x402788('0x34')])),_0x2a78a9['attributes']=_0x2a78a9['attributes'][_0x402788('0x1b')]?_0x2a78a9[_0x402788('0x37')]:_0x152f86[_0x402788('0x1f')],typeof _0x281d8a[_0x402788('0x26')][_0x402788('0x1e')]===_0x402788('0x3a')&&(_0x2a78a9['limit']=qs[_0x402788('0x31')](_0x281d8a[_0x402788('0x26')]['limit']),_0x2a78a9[_0x402788('0x32')]=qs[_0x402788('0x32')](_0x281d8a[_0x402788('0x26')]['offset'])),_0x2a78a9[_0x402788('0x1')]=qs['sort'](_0x281d8a[_0x402788('0x26')][_0x402788('0x36')]),_0x2a78a9[_0x402788('0x4')]=qs[_0x402788('0x9')](_[_0x402788('0x2')](_0x281d8a[_0x402788('0x26')],_0x152f86[_0x402788('0x9')])),_0x2a78a9[_0x402788('0x4')][_0x402788('0x20')]=_0x358d48['id'],_0x281d8a[_0x402788('0x26')][_0x402788('0x11')]&&(_0x2a78a9['where']=_[_0x402788('0x3b')](_0x2a78a9['where'],{[Op['or']]:_[_0x402788('0x28')](_0x2a78a9[_0x402788('0x37')],function(_0x174b5d){const _0x3b3534=_0x402788,_0x4214a3={};return _0x4214a3[_0x174b5d]={[Op[_0x3b3534('0x12')]]:'%'+_0x281d8a[_0x3b3534('0x26')][_0x3b3534('0x11')]+'%'},_0x4214a3;})})),_0x2a78a9=_[_0x402788('0x3b')]({},_0x2a78a9,_0x281d8a[_0x402788('0x8')]),db['JscriptyQuestionReport'][_0x402788('0x18')]({'where':_0x2a78a9['where']})[_0x402788('0x15')](function(_0x2095ec){const _0x169122=_0x402788;return _0x26ed8f[_0x169122('0x18')]=_0x2095ec,_0x281d8a[_0x169122('0x26')]['includeAll']&&(_0x2a78a9[_0x169122('0x10')]=[{'all':!![]}]),db[_0x169122('0x2c')][_0x169122('0xe')](_0x2a78a9);})['then'](function(_0x3e80b9){const _0x45911a=_0x402788;return _0x26ed8f[_0x45911a('0x19')]=_0x3e80b9,_0x26ed8f;});})['then'](respondWithFilteredResult(_0xa065ee,_0x2a78a9))['catch'](handleError(_0xa065ee,null));}; \ No newline at end of file diff --git a/server/api/jscriptySessionReport/jscriptySessionReport.model.js b/server/api/jscriptySessionReport/jscriptySessionReport.model.js index 6c63e21..d3a1abb 100644 --- a/server/api/jscriptySessionReport/jscriptySessionReport.model.js +++ b/server/api/jscriptySessionReport/jscriptySessionReport.model.js @@ -1 +1 @@ -const a387_0x5627=['exports','JscriptySessionReport'];(function(_0x4a3728,_0x562720){const _0x54eff4=function(_0x373efe){while(--_0x373efe){_0x4a3728['push'](_0x4a3728['shift']());}};_0x54eff4(++_0x562720);}(a387_0x5627,0xd0));const a387_0x54ef=function(_0x4a3728,_0x562720){_0x4a3728=_0x4a3728-0x0;let _0x54eff4=a387_0x5627[_0x4a3728];return _0x54eff4;};const _0x46411c=a387_0x54ef;'use strict';const attributes=require('./jscriptySessionReport.attributes');module[_0x46411c('0x0')]=function(_0x373efe){const _0x2919f0=_0x46411c,_0x1ff6ad=_0x373efe['define'](_0x2919f0('0x1'),attributes,{'tableName':'report_jscripty_sessions','paranoid':![],'indexes':[],'timestamps':!![]});return _0x1ff6ad;}; \ No newline at end of file +const a387_0x32fd=['exports','define','JscriptySessionReport'];(function(_0x538fe0,_0x32fde0){const _0x52fca7=function(_0x182829){while(--_0x182829){_0x538fe0['push'](_0x538fe0['shift']());}};_0x52fca7(++_0x32fde0);}(a387_0x32fd,0x11b));const a387_0x52fc=function(_0x538fe0,_0x32fde0){_0x538fe0=_0x538fe0-0x0;let _0x52fca7=a387_0x32fd[_0x538fe0];return _0x52fca7;};const _0x2c1f69=a387_0x52fc;'use strict';const attributes=require('./jscriptySessionReport.attributes');module[_0x2c1f69('0x2')]=function(_0x182829){const _0x5c295e=_0x2c1f69,_0x17cd30=_0x182829[_0x5c295e('0x0')](_0x5c295e('0x1'),attributes,{'tableName':'report_jscripty_sessions','paranoid':![],'indexes':[],'timestamps':!![]});return _0x17cd30;}; \ No newline at end of file diff --git a/server/api/license/index.js b/server/api/license/index.js index 3899dd8..5b0354a 100644 --- a/server/api/license/index.js +++ b/server/api/license/index.js @@ -1 +1 @@ -const a388_0x4812=['index','isAuthenticated','update','exports','/:id','put','../../components/auth/service'];(function(_0x8ff16d,_0x48124d){const _0x14d5a8=function(_0x5b771d){while(--_0x5b771d){_0x8ff16d['push'](_0x8ff16d['shift']());}};_0x14d5a8(++_0x48124d);}(a388_0x4812,0xd0));const a388_0x14d5=function(_0x8ff16d,_0x48124d){_0x8ff16d=_0x8ff16d-0x0;let _0x14d5a8=a388_0x4812[_0x8ff16d];return _0x14d5a8;};const _0x27894f=a388_0x14d5;'use strict';const express=require('express'),router=express['Router'](),auth=require(_0x27894f('0x1')),controller=require('./license.controller');router['get']('/',controller[_0x27894f('0x2')]),router[_0x27894f('0x0')](_0x27894f('0x6'),auth[_0x27894f('0x3')](),controller[_0x27894f('0x4')]),module[_0x27894f('0x5')]=router; \ No newline at end of file +const a388_0x25e1=['put','update','exports','Router','get','isAuthenticated','../../components/auth/service'];(function(_0xab5d56,_0x25e169){const _0x3b8cb4=function(_0x4fd2f3){while(--_0x4fd2f3){_0xab5d56['push'](_0xab5d56['shift']());}};_0x3b8cb4(++_0x25e169);}(a388_0x25e1,0xfb));const a388_0x3b8c=function(_0xab5d56,_0x25e169){_0xab5d56=_0xab5d56-0x0;let _0x3b8cb4=a388_0x25e1[_0xab5d56];return _0x3b8cb4;};const _0x3899fa=a388_0x3b8c;'use strict';const express=require('express'),router=express[_0x3899fa('0x4')](),auth=require(_0x3899fa('0x0')),controller=require('./license.controller');router[_0x3899fa('0x5')]('/',controller['index']),router[_0x3899fa('0x1')]('/:id',auth[_0x3899fa('0x6')](),controller[_0x3899fa('0x2')]),module[_0x3899fa('0x3')]=router; \ No newline at end of file diff --git a/server/api/license/license.attributes.js b/server/api/license/license.attributes.js index ba18ad7..34e73ba 100644 --- a/server/api/license/license.attributes.js +++ b/server/api/license/license.attributes.js @@ -1 +1 @@ -const a389_0x1f83=['STRING','INTEGER','exports','sequelize','TEXT'];(function(_0x1e17f0,_0x1f8366){const _0x3c794=function(_0x26a4c0){while(--_0x26a4c0){_0x1e17f0['push'](_0x1e17f0['shift']());}};_0x3c794(++_0x1f8366);}(a389_0x1f83,0x12d));const a389_0x3c79=function(_0x1e17f0,_0x1f8366){_0x1e17f0=_0x1e17f0-0x0;let _0x3c794=a389_0x1f83[_0x1e17f0];return _0x3c794;};const _0x4b2cc3=a389_0x3c79;'use strict';const Sequelize=require(_0x4b2cc3('0x2'));module[_0x4b2cc3('0x1')]={'license':{'type':Sequelize[_0x4b2cc3('0x3')]},'data1':{'type':Sequelize['STRING']},'data2':{'type':Sequelize[_0x4b2cc3('0x4')]},'chatLicenseExceeded':{'type':Sequelize[_0x4b2cc3('0x0')],'defaultValue':0x0}}; \ No newline at end of file +const a389_0xa0c9=['TEXT','exports','INTEGER','STRING'];(function(_0x4c8053,_0xa0c9b){const _0x3abc76=function(_0x5e643c){while(--_0x5e643c){_0x4c8053['push'](_0x4c8053['shift']());}};_0x3abc76(++_0xa0c9b);}(a389_0xa0c9,0xf2));const a389_0x3abc=function(_0x4c8053,_0xa0c9b){_0x4c8053=_0x4c8053-0x0;let _0x3abc76=a389_0xa0c9[_0x4c8053];return _0x3abc76;};const _0x534210=a389_0x3abc;'use strict';const Sequelize=require('sequelize');module[_0x534210('0x3')]={'license':{'type':Sequelize[_0x534210('0x2')]},'data1':{'type':Sequelize[_0x534210('0x1')]},'data2':{'type':Sequelize['STRING']},'chatLicenseExceeded':{'type':Sequelize[_0x534210('0x0')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/license/license.controller.js b/server/api/license/license.controller.js index 01284cc..da2e520 100644 --- a/server/api/license/license.controller.js +++ b/server/api/license/license.controller.js @@ -1 +1 @@ -const a390_0x12bb=['name','../../mysqldb','body','query','lodash','findOne','sendStatus','error','fields','merge','keys','update','api','catch','attributes','json','License','length','model','../../config/license/util','get','../../components/parsers/qs','intersection','checkLicense','key','status','stack','getLicense','then','../../config/logger'];(function(_0x2ce064,_0x12bb22){const _0x21a4f7=function(_0x564d39){while(--_0x564d39){_0x2ce064['push'](_0x2ce064['shift']());}};_0x21a4f7(++_0x12bb22);}(a390_0x12bb,0x1bc));const a390_0x21a4=function(_0x2ce064,_0x12bb22){_0x2ce064=_0x2ce064-0x0;let _0x21a4f7=a390_0x12bb[_0x2ce064];return _0x21a4f7;};const _0x413387=a390_0x21a4;'use strict';const _=require(_0x413387('0xa')),qs=require(_0x413387('0x1b')),logger=require(_0x413387('0x5'))(_0x413387('0x12')),db=require(_0x413387('0x7'))['db'];function respondWithResult(_0x564d39,_0x56d548){return _0x56d548=_0x56d548||0xc8,function(_0x23f9b4){const _0x13c81d=a390_0x21a4;if(_0x23f9b4)return _0x564d39[_0x13c81d('0x1')](_0x56d548)[_0x13c81d('0x15')](_0x23f9b4);};}function saveUpdates(_0x608e27){return function(_0x3c375c){const _0x251a81=a390_0x21a4;if(_0x3c375c)return _0x3c375c[_0x251a81('0x11')](_0x608e27)[_0x251a81('0x4')](function(_0x229309){return _0x229309;});return null;};}function handleEntityNotFound(_0x3bb65c){return function(_0x1cbc84){const _0x17130c=a390_0x21a4;return!_0x1cbc84&&_0x3bb65c[_0x17130c('0xc')](0x194),_0x1cbc84;};}function handleError(_0x5c3499,_0x14debc){return _0x14debc=_0x14debc||0x1f4,function(_0x299f3f){const _0x4cbc30=a390_0x21a4;logger[_0x4cbc30('0xd')](_0x299f3f[_0x4cbc30('0x2')]),_0x299f3f[_0x4cbc30('0x6')]&&delete _0x299f3f[_0x4cbc30('0x6')],_0x5c3499[_0x4cbc30('0x1')](_0x14debc)['send'](_0x299f3f);};}const utilLicense=require(_0x413387('0x19'));exports['index']=function(_0x6d34ee,_0x2ca999){const _0x157e68=_0x413387;let _0x27d4c5={'raw':!![],'where':{'id':0x1}};const _0x347f47={};return _0x347f47['model']=_[_0x157e68('0x10')](db[_0x157e68('0x16')]['rawAttributes']),_0x347f47[_0x157e68('0x9')]=_[_0x157e68('0x10')](_0x6d34ee[_0x157e68('0x9')]),_0x347f47['filters']=_[_0x157e68('0x1c')](_0x347f47['model'],_0x347f47['query']),_0x27d4c5[_0x157e68('0x14')]=_['intersection'](_0x347f47[_0x157e68('0x18')],qs['fields'](_0x6d34ee[_0x157e68('0x9')][_0x157e68('0xe')])),_0x27d4c5[_0x157e68('0x14')]=_0x27d4c5[_0x157e68('0x14')][_0x157e68('0x17')]?_0x27d4c5[_0x157e68('0x14')]:_0x347f47[_0x157e68('0x18')],_0x27d4c5=_[_0x157e68('0xf')]({},_0x27d4c5,_0x6d34ee['options']),utilLicense[_0x157e68('0x3')](_0x27d4c5)[_0x157e68('0x4')](respondWithResult(_0x2ca999,null))[_0x157e68('0x13')](handleError(_0x2ca999,null));},exports[_0x413387('0x11')]=function(_0xa6361d,_0x5d59f7){const _0x525561=_0x413387;return _0xa6361d[_0x525561('0x8')]['id']&&delete _0xa6361d[_0x525561('0x8')]['id'],db[_0x525561('0x16')][_0x525561('0xb')]({'where':{'id':_0xa6361d['params']['id']}})[_0x525561('0x4')](handleEntityNotFound(_0x5d59f7,null))[_0x525561('0x4')](function(_0x5a0898){const _0x18b850=_0x525561,_0x3b9b99=_0x5a0898[_0x18b850('0x1a')]({'plain':!![]});return utilLicense[_0x18b850('0x1d')](_0x3b9b99,_0xa6361d[_0x18b850('0x8')][_0x18b850('0x0')]);})[_0x525561('0x4')](function(_0x16ee41){if(!_0x16ee41['demo'])return saveUpdates(_0xa6361d['body'],null);return _0x16ee41;})[_0x525561('0x4')](respondWithResult(_0x5d59f7,null))[_0x525561('0x13')](handleError(_0x5d59f7,null));}; \ No newline at end of file +const a390_0x1a7a=['send','sendStatus','lodash','name','checkLicense','status','query','stack','keys','json','attributes','options','length','then','rawAttributes','model','body','getLicense','catch','key','../../config/logger','update','findOne','demo','../../components/parsers/qs','License','api','intersection','fields','index'];(function(_0x352ba5,_0x1a7adb){const _0x5cde90=function(_0x174c97){while(--_0x174c97){_0x352ba5['push'](_0x352ba5['shift']());}};_0x5cde90(++_0x1a7adb);}(a390_0x1a7a,0xb0));const a390_0x5cde=function(_0x352ba5,_0x1a7adb){_0x352ba5=_0x352ba5-0x0;let _0x5cde90=a390_0x1a7a[_0x352ba5];return _0x5cde90;};const _0x9d6ff9=a390_0x5cde;'use strict';const _=require(_0x9d6ff9('0x6')),qs=require(_0x9d6ff9('0x1c')),logger=require(_0x9d6ff9('0x18'))(_0x9d6ff9('0x0')),db=require('../../mysqldb')['db'];function respondWithResult(_0x174c97,_0x2d74be){return _0x2d74be=_0x2d74be||0xc8,function(_0x814438){const _0x172431=a390_0x5cde;if(_0x814438)return _0x174c97[_0x172431('0x9')](_0x2d74be)[_0x172431('0xd')](_0x814438);};}function saveUpdates(_0x26cd66){return function(_0x4f8eb2){const _0x24fcaf=a390_0x5cde;if(_0x4f8eb2)return _0x4f8eb2[_0x24fcaf('0x19')](_0x26cd66)['then'](function(_0x5fb236){return _0x5fb236;});return null;};}function handleEntityNotFound(_0x361ecd){return function(_0x21105f){const _0x155fd2=a390_0x5cde;return!_0x21105f&&_0x361ecd[_0x155fd2('0x5')](0x194),_0x21105f;};}function handleError(_0x5c7ce3,_0x2d0e88){return _0x2d0e88=_0x2d0e88||0x1f4,function(_0x35933d){const _0x206b14=a390_0x5cde;logger['error'](_0x35933d[_0x206b14('0xb')]),_0x35933d[_0x206b14('0x7')]&&delete _0x35933d[_0x206b14('0x7')],_0x5c7ce3['status'](_0x2d0e88)[_0x206b14('0x4')](_0x35933d);};}const utilLicense=require('../../config/license/util');exports[_0x9d6ff9('0x3')]=function(_0x461b67,_0x5c5564){const _0x5c58f1=_0x9d6ff9;let _0x2aedef={'raw':!![],'where':{'id':0x1}};const _0x72f9c8={};return _0x72f9c8[_0x5c58f1('0x13')]=_[_0x5c58f1('0xc')](db[_0x5c58f1('0x1d')][_0x5c58f1('0x12')]),_0x72f9c8[_0x5c58f1('0xa')]=_[_0x5c58f1('0xc')](_0x461b67['query']),_0x72f9c8['filters']=_[_0x5c58f1('0x1')](_0x72f9c8[_0x5c58f1('0x13')],_0x72f9c8[_0x5c58f1('0xa')]),_0x2aedef['attributes']=_[_0x5c58f1('0x1')](_0x72f9c8[_0x5c58f1('0x13')],qs[_0x5c58f1('0x2')](_0x461b67[_0x5c58f1('0xa')][_0x5c58f1('0x2')])),_0x2aedef['attributes']=_0x2aedef[_0x5c58f1('0xe')][_0x5c58f1('0x10')]?_0x2aedef[_0x5c58f1('0xe')]:_0x72f9c8['model'],_0x2aedef=_['merge']({},_0x2aedef,_0x461b67[_0x5c58f1('0xf')]),utilLicense[_0x5c58f1('0x15')](_0x2aedef)['then'](respondWithResult(_0x5c5564,null))[_0x5c58f1('0x16')](handleError(_0x5c5564,null));},exports['update']=function(_0x16d683,_0x100e8d){const _0xdd35eb=_0x9d6ff9;return _0x16d683[_0xdd35eb('0x14')]['id']&&delete _0x16d683[_0xdd35eb('0x14')]['id'],db[_0xdd35eb('0x1d')][_0xdd35eb('0x1a')]({'where':{'id':_0x16d683['params']['id']}})[_0xdd35eb('0x11')](handleEntityNotFound(_0x100e8d,null))[_0xdd35eb('0x11')](function(_0x2f2132){const _0x4305da=_0xdd35eb,_0x4dfd81=_0x2f2132['get']({'plain':!![]});return utilLicense[_0x4305da('0x8')](_0x4dfd81,_0x16d683[_0x4305da('0x14')][_0x4305da('0x17')]);})[_0xdd35eb('0x11')](function(_0x2fed00){const _0x34cd9f=_0xdd35eb;if(!_0x2fed00[_0x34cd9f('0x1b')])return saveUpdates(_0x16d683[_0x34cd9f('0x14')],null);return _0x2fed00;})[_0xdd35eb('0x11')](respondWithResult(_0x100e8d,null))['catch'](handleError(_0x100e8d,null));}; \ No newline at end of file diff --git a/server/api/license/license.model.js b/server/api/license/license.model.js index fb75d48..c5d31c1 100644 --- a/server/api/license/license.model.js +++ b/server/api/license/license.model.js @@ -1 +1 @@ -const a391_0x1e81=['license','define','./license.attributes','License'];(function(_0x3b6b7e,_0x1e813f){const _0x4d4343=function(_0x51890f){while(--_0x51890f){_0x3b6b7e['push'](_0x3b6b7e['shift']());}};_0x4d4343(++_0x1e813f);}(a391_0x1e81,0x118));const a391_0x4d43=function(_0x3b6b7e,_0x1e813f){_0x3b6b7e=_0x3b6b7e-0x0;let _0x4d4343=a391_0x1e81[_0x3b6b7e];return _0x4d4343;};const _0x3fbd4b=a391_0x4d43;'use strict';const attributes=require(_0x3fbd4b('0x2'));module['exports']=function(_0x51890f){const _0x30e369=_0x3fbd4b,_0x211c68=_0x51890f[_0x30e369('0x1')](_0x30e369('0x3'),attributes,{'tableName':_0x30e369('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x211c68;}; \ No newline at end of file +const a391_0x2d9c=['./license.attributes','License','exports'];(function(_0x3afca0,_0x2d9c04){const _0x18b3f1=function(_0x31a41c){while(--_0x31a41c){_0x3afca0['push'](_0x3afca0['shift']());}};_0x18b3f1(++_0x2d9c04);}(a391_0x2d9c,0x1bb));const a391_0x18b3=function(_0x3afca0,_0x2d9c04){_0x3afca0=_0x3afca0-0x0;let _0x18b3f1=a391_0x2d9c[_0x3afca0];return _0x18b3f1;};const _0x40ad94=a391_0x18b3;'use strict';const attributes=require(_0x40ad94('0x1'));module[_0x40ad94('0x0')]=function(_0x31a41c){const _0x11f139=_0x40ad94,_0x462097=_0x31a41c['define'](_0x11f139('0x2'),attributes,{'tableName':'license','paranoid':![],'indexes':[],'timestamps':!![]});return _0x462097;}; \ No newline at end of file diff --git a/server/api/mailAccount/index.js b/server/api/mailAccount/index.js index d04d71e..a451d07 100644 --- a/server/api/mailAccount/index.js +++ b/server/api/mailAccount/index.js @@ -1 +1 @@ -const a392_0x5d52=['removeAnswers','get','verifySmtp','show','addSmtp','destroy','create','getDispositions','getInteractions','getImap','delete','getSmtp','describe','/:id/verify','removeImap','/:id/in_servers','/:id/out_servers','addDisposition','/:id/applications','/:id','/:id/users','send','getMessages','/:id/interactions','/:id/canned_answers','isAuthenticated','post','../../components/auth/service','removeSmtp','getApplications','/:id/dispositions','addInteraction','addApplications','getAgents','/:id/messages','put'];(function(_0x4c0d50,_0x5d525a){const _0x2938a5=function(_0x4baa05){while(--_0x4baa05){_0x4c0d50['push'](_0x4c0d50['shift']());}};_0x2938a5(++_0x5d525a);}(a392_0x5d52,0xb3));const a392_0x2938=function(_0x4c0d50,_0x5d525a){_0x4c0d50=_0x4c0d50-0x0;let _0x2938a5=a392_0x5d52[_0x4c0d50];return _0x2938a5;};const _0x316fc7=a392_0x2938;'use strict';const express=require('express'),router=express['Router'](),auth=require(_0x316fc7('0x1c')),controller=require('./mailAccount.controller');router[_0x316fc7('0x2')]('/',auth[_0x316fc7('0x1a')](),controller['index']),router[_0x316fc7('0x2')]('/describe',auth['isAuthenticated'](),controller[_0x316fc7('0xd')]),router[_0x316fc7('0x2')](_0x316fc7('0x14'),auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x4')]),router[_0x316fc7('0x2')](_0x316fc7('0x1f'),auth['isAuthenticated'](),controller[_0x316fc7('0x8')]),router[_0x316fc7('0x2')]('/:id/canned_answers',auth['isAuthenticated'](),controller['getAnswers']),router['get'](_0x316fc7('0x10'),auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0xa')]),router[_0x316fc7('0x2')]('/:id/out_servers',auth['isAuthenticated'](),controller[_0x316fc7('0xc')]),router[_0x316fc7('0x2')](_0x316fc7('0x18'),auth['isAuthenticated'](),controller[_0x316fc7('0x9')]),router[_0x316fc7('0x2')](_0x316fc7('0x13'),auth['isAuthenticated'](),controller[_0x316fc7('0x1e')]),router[_0x316fc7('0x2')](_0x316fc7('0x23'),auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x17')]),router['get'](_0x316fc7('0xe'),auth['isAuthenticated'](),controller[_0x316fc7('0x3')]),router[_0x316fc7('0x2')]('/:id/users',auth['isAuthenticated'](),controller[_0x316fc7('0x22')]),router[_0x316fc7('0x1b')]('/:id/dispositions',auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x12')]),router[_0x316fc7('0x1b')](_0x316fc7('0x19'),auth[_0x316fc7('0x1a')](),controller['addAnswer']),router[_0x316fc7('0x1b')]('/',auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x7')]),router[_0x316fc7('0x1b')]('/:id/in_servers',auth[_0x316fc7('0x1a')](),controller['addImap']),router[_0x316fc7('0x1b')]('/:id/out_servers',auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x5')]),router[_0x316fc7('0x1b')](_0x316fc7('0x18'),auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x20')]),router[_0x316fc7('0x1b')](_0x316fc7('0x13'),auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x21')]),router[_0x316fc7('0x1b')]('/:id/send',auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x16')]),router[_0x316fc7('0x1b')](_0x316fc7('0x15'),auth[_0x316fc7('0x1a')](),controller['addAgents']),router[_0x316fc7('0x0')](_0x316fc7('0x14'),auth[_0x316fc7('0x1a')](),controller['update']),router[_0x316fc7('0xb')](_0x316fc7('0x1f'),auth[_0x316fc7('0x1a')](),controller['removeDispositions']),router[_0x316fc7('0xb')](_0x316fc7('0x19'),auth['isAuthenticated'](),controller[_0x316fc7('0x1')]),router[_0x316fc7('0xb')](_0x316fc7('0x10'),auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0xf')]),router[_0x316fc7('0xb')](_0x316fc7('0x11'),auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x1d')]),router[_0x316fc7('0xb')](_0x316fc7('0x14'),auth[_0x316fc7('0x1a')](),controller[_0x316fc7('0x6')]),router[_0x316fc7('0xb')]('/:id/users',auth[_0x316fc7('0x1a')](),controller['removeAgents']),module['exports']=router; \ No newline at end of file +const a392_0x2ba7=['/:id/dispositions','addApplications','getMessages','removeDispositions','/:id/canned_answers','/:id/in_servers','destroy','describe','getImap','post','/:id/messages','express','/describe','/:id','exports','get','isAuthenticated','addAnswer','getApplications','getSmtp','/:id/verify','addImap','removeAgents','verifySmtp','removeSmtp','index','send','addAgents','../../components/auth/service','/:id/users','getDispositions','addSmtp','show','put','/:id/out_servers','getInteractions','/:id/interactions','delete','removeAnswers','/:id/send','getAgents'];(function(_0x59d211,_0x2ba797){const _0x5b9667=function(_0x26caf7){while(--_0x26caf7){_0x59d211['push'](_0x59d211['shift']());}};_0x5b9667(++_0x2ba797);}(a392_0x2ba7,0x1de));const a392_0x5b96=function(_0x59d211,_0x2ba797){_0x59d211=_0x59d211-0x0;let _0x5b9667=a392_0x2ba7[_0x59d211];return _0x5b9667;};const _0x7bdeca=a392_0x5b96;'use strict';const express=require(_0x7bdeca('0x19')),router=express['Router'](),auth=require(_0x7bdeca('0x1')),controller=require('./mailAccount.controller');router[_0x7bdeca('0x1d')]('/',auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x27')]),router[_0x7bdeca('0x1d')](_0x7bdeca('0x1a'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x15')]),router[_0x7bdeca('0x1d')](_0x7bdeca('0x1b'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x5')]),router[_0x7bdeca('0x1d')]('/:id/dispositions',auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x3')]),router[_0x7bdeca('0x1d')](_0x7bdeca('0x12'),auth[_0x7bdeca('0x1e')](),controller['getAnswers']),router[_0x7bdeca('0x1d')]('/:id/in_servers',auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x16')]),router[_0x7bdeca('0x1d')]('/:id/out_servers',auth['isAuthenticated'](),controller[_0x7bdeca('0x21')]),router['get']('/:id/interactions',auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x8')]),router[_0x7bdeca('0x1d')]('/:id/applications',auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x20')]),router['get'](_0x7bdeca('0x18'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x10')]),router[_0x7bdeca('0x1d')](_0x7bdeca('0x22'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x25')]),router[_0x7bdeca('0x1d')](_0x7bdeca('0x2'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0xd')]),router[_0x7bdeca('0x17')](_0x7bdeca('0xe'),auth['isAuthenticated'](),controller['addDisposition']),router[_0x7bdeca('0x17')](_0x7bdeca('0x12'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x1f')]),router['post']('/',auth[_0x7bdeca('0x1e')](),controller['create']),router[_0x7bdeca('0x17')](_0x7bdeca('0x13'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x23')]),router[_0x7bdeca('0x17')](_0x7bdeca('0x7'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x4')]),router[_0x7bdeca('0x17')](_0x7bdeca('0x9'),auth['isAuthenticated'](),controller['addInteraction']),router[_0x7bdeca('0x17')]('/:id/applications',auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0xf')]),router[_0x7bdeca('0x17')](_0x7bdeca('0xc'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x28')]),router[_0x7bdeca('0x17')](_0x7bdeca('0x2'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x0')]),router[_0x7bdeca('0x6')](_0x7bdeca('0x1b'),auth['isAuthenticated'](),controller['update']),router[_0x7bdeca('0xa')]('/:id/dispositions',auth['isAuthenticated'](),controller[_0x7bdeca('0x11')]),router['delete'](_0x7bdeca('0x12'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0xb')]),router[_0x7bdeca('0xa')](_0x7bdeca('0x13'),auth['isAuthenticated'](),controller['removeImap']),router[_0x7bdeca('0xa')](_0x7bdeca('0x7'),auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x26')]),router[_0x7bdeca('0xa')]('/:id',auth['isAuthenticated'](),controller[_0x7bdeca('0x14')]),router[_0x7bdeca('0xa')]('/:id/users',auth[_0x7bdeca('0x1e')](),controller[_0x7bdeca('0x24')]),module[_0x7bdeca('0x1c')]=router; \ No newline at end of file diff --git a/server/api/mailAccount/mailAccount.attributes.js b/server/api/mailAccount/mailAccount.attributes.js index c2a911d..860bbe7 100644 --- a/server/api/mailAccount/mailAccount.attributes.js +++ b/server/api/mailAccount/mailAccount.attributes.js @@ -1 +1 @@ -const a393_0x5639=['exports','Arial,Helvetica,sans-serif','sequelize','mandatoryDisposition','TEXT','setDataValue','BOOLEAN','Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}
Subject\x20:\x20{{message.subject}}','INTEGER','STRING','mandatoryDispositionPauseId','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','UNSIGNED','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled'];(function(_0xb5d213,_0x5639cd){const _0x1370ab=function(_0x259141){while(--_0x259141){_0xb5d213['push'](_0xb5d213['shift']());}};_0x1370ab(++_0x5639cd);}(a393_0x5639,0x14c));const a393_0x1370=function(_0xb5d213,_0x5639cd){_0xb5d213=_0xb5d213-0x0;let _0x1370ab=a393_0x5639[_0xb5d213];return _0x1370ab;};const _0x4047e7=a393_0x1370;'use strict';const Sequelize=require(_0x4047e7('0x6'));module[_0x4047e7('0x4')]={'description':{'type':Sequelize[_0x4047e7('0xd')]},'name':{'type':Sequelize[_0x4047e7('0xd')],'allowNull':![]},'service':{'type':Sequelize[_0x4047e7('0xa')],'defaultValue':![]},'email':{'type':Sequelize[_0x4047e7('0xd')],'validate':{'isEmail':!![]}},'active':{'type':Sequelize[_0x4047e7('0xa')],'defaultValue':!![]},'key':{'type':Sequelize['STRING'],'allowNull':![]},'template':{'type':Sequelize[_0x4047e7('0x8')]},'markAsUnread':{'type':Sequelize[_0x4047e7('0xa')],'defaultValue':![]},'fontFamily':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x4047e7('0x5')},'fontSize':{'type':Sequelize[_0x4047e7('0xc')](0x2)[_0x4047e7('0x2')],'defaultValue':0xd,'validate':{'min':0x8,'max':0x48}},'notificationTemplate':{'type':Sequelize[_0x4047e7('0x8')],'defaultValue':function(){const _0x2db610=_0x4047e7;return _0x2db610('0xb');}},'notificationSound':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'notificationShake':{'type':Sequelize[_0x4047e7('0xa')],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x4047e7('0xc')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'queueTransfer':{'type':Sequelize[_0x4047e7('0xa')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x4047e7('0xc')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0x4047e7('0xc')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'mandatoryDispositionPauseId':{'type':Sequelize['INTEGER'],'allowNull':!![],'defaultValue':null,'comment':_0x4047e7('0x3')},'mandatoryDisposition':{'type':Sequelize[_0x4047e7('0xa')],'defaultValue':![],'comment':_0x4047e7('0x1'),'set':function(_0x259141){const _0x1ca434=_0x4047e7;if(!_0x259141)this[_0x1ca434('0x9')](_0x1ca434('0x0'),null);this[_0x1ca434('0x9')](_0x1ca434('0x7'),_0x259141);}}}; \ No newline at end of file +const a393_0x8dcc=['sequelize','exports','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','BOOLEAN','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}
Subject\x20:\x20{{message.subject}}','UNSIGNED','mandatoryDisposition','STRING','setDataValue','INTEGER'];(function(_0x470e5d,_0x8dcc8f){const _0x1a27a2=function(_0x447b17){while(--_0x447b17){_0x470e5d['push'](_0x470e5d['shift']());}};_0x1a27a2(++_0x8dcc8f);}(a393_0x8dcc,0x136));const a393_0x1a27=function(_0x470e5d,_0x8dcc8f){_0x470e5d=_0x470e5d-0x0;let _0x1a27a2=a393_0x8dcc[_0x470e5d];return _0x1a27a2;};const _0x5e8084=a393_0x1a27;'use strict';const Sequelize=require(_0x5e8084('0x9'));module[_0x5e8084('0xa')]={'description':{'type':Sequelize[_0x5e8084('0x6')]},'name':{'type':Sequelize[_0x5e8084('0x6')],'allowNull':![]},'service':{'type':Sequelize[_0x5e8084('0x1')],'defaultValue':![]},'email':{'type':Sequelize[_0x5e8084('0x6')],'validate':{'isEmail':!![]}},'active':{'type':Sequelize[_0x5e8084('0x1')],'defaultValue':!![]},'key':{'type':Sequelize[_0x5e8084('0x6')],'allowNull':![]},'template':{'type':Sequelize['TEXT']},'markAsUnread':{'type':Sequelize[_0x5e8084('0x1')],'defaultValue':![]},'fontFamily':{'type':Sequelize[_0x5e8084('0x6')],'allowNull':![],'defaultValue':'Arial,Helvetica,sans-serif'},'fontSize':{'type':Sequelize[_0x5e8084('0x8')](0x2)[_0x5e8084('0x4')],'defaultValue':0xd,'validate':{'min':0x8,'max':0x48}},'notificationTemplate':{'type':Sequelize['TEXT'],'defaultValue':function(){const _0x2d8b76=_0x5e8084;return _0x2d8b76('0x3');}},'notificationSound':{'type':Sequelize[_0x5e8084('0x1')],'defaultValue':!![]},'notificationShake':{'type':Sequelize[_0x5e8084('0x1')],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x5e8084('0x8')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'queueTransfer':{'type':Sequelize[_0x5e8084('0x1')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x5e8084('0x8')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize[_0x5e8084('0x1')],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize['INTEGER'],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'mandatoryDispositionPauseId':{'type':Sequelize[_0x5e8084('0x8')],'allowNull':!![],'defaultValue':null,'comment':_0x5e8084('0x2')},'mandatoryDisposition':{'type':Sequelize[_0x5e8084('0x1')],'defaultValue':![],'comment':_0x5e8084('0x0'),'set':function(_0x447b17){const _0x5b93b1=_0x5e8084;if(!_0x447b17)this[_0x5b93b1('0x7')]('mandatoryDispositionPauseId',null);this[_0x5b93b1('0x7')](_0x5b93b1('0x5'),_0x447b17);}}}; \ No newline at end of file diff --git a/server/api/mailAccount/mailAccount.controller.js b/server/api/mailAccount/mailAccount.controller.js index 4163d1c..8cecec9 100644 --- a/server/api/mailAccount/mailAccount.controller.js +++ b/server/api/mailAccount/mailAccount.controller.js @@ -1 +1 @@ -const a394_0x23c4=['VIRTUAL','removeImap','error','from','Contacts','user','getImap','attributes','fullname','$gte','debug','MailApplication','host','cpassword','password','addAgents','description','MailServerIn','mandatoryDispositionPause','attach','List\x20not\x20found','port','MailAccount,\x20%s,\x20%s','MailAccount,\x20%s,\x20%s,\x20%s','Disposition','YYYY-MM-DD\x20HH:mm:ss','path','addDisposition','attachments','catch','filter','query','userMailAccount:save','SendMail','rawAttributes','UserProfileSection','UserProfileResource','cauthentication','MailInteraction','verifySmtp','set','end','limit','split','getDispositions','removeAgents','setSmtp','../../config/environment','body','stringify','update','include','MailAccount','where','api','removeDispositions','merge','info','key','Smtp','findAndCountAll','User','Imap','CmList','sendMail','includeAll','map','model','Messages','tag','server/files/attachments','MailMessage','Interaction','jayson/promise','pick','cuser','addInteraction','count','getApplications','sequelize','CannedAnswer','options','length','CmContact','getAgents','json','MailServerOut','fieldName','bulkCreate','emit','MailAccounts','filters','MailAccountId','getSmtp','./mailAccount.socket','color','ListId','keys','VerifySmtp','role','result','pass','userProfileId','../../config/logger','name','secure','status','Owner','autoAssociation','Pause','../../rediscache','userMailAccount:remove','then','send','DESC','basename','like','removeSmtp','auth','root','type','../../components/parsers/qs','message','priority','isNil','addSmtp','Content-Range','nolimit','http','format','index','register','order','code','active','request\x20sent','offset','moment','updatedAt','You\x20can\x27t\x20remove\x20the\x20mail\x20service\x20account','sendStatus','destroy','cservice','service','findOne','List','describe','params','lodash','getAnswers','util','sort','../../mysqldb','findAll','%s\x20<%s>','defaults','addAnswer','fields','get','rows','create','email','subject','intersection','messageId','ids','out','authentication','undefined','removeAnswers','show','client','join','setImap'];(function(_0x182e85,_0x23c474){const _0x46d808=function(_0x590dbd){while(--_0x590dbd){_0x182e85['push'](_0x182e85['shift']());}};_0x46d808(++_0x23c474);}(a394_0x23c4,0x153));const a394_0x46d8=function(_0x182e85,_0x23c474){_0x182e85=_0x182e85-0x0;let _0x46d808=a394_0x23c4[_0x182e85];return _0x46d808;};const _0x59b80f=a394_0x46d8;'use strict';const moment=require(_0x59b80f('0x92')),util=require(_0x59b80f('0x9f')),path=require(_0x59b80f('0x23')),_=require(_0x59b80f('0x9d')),{getSocket}=require(_0x59b80f('0x77')),socket=getSocket(),qs=require(_0x59b80f('0x82')),logger=require(_0x59b80f('0x70'))(_0x59b80f('0x3f')),config=require(_0x59b80f('0x38')),db=require(_0x59b80f('0xa1'))['db'],{Op,ValidationError}=require(_0x59b80f('0x58'));require(_0x59b80f('0x67'))[_0x59b80f('0x8c')](socket);const jayson=require(_0x59b80f('0x52')),client=jayson[_0x59b80f('0x6')][_0x59b80f('0x89')]({'port':0x232b});function respondWithRpcPromise(_0x590dbd,_0x3bd097,_0x3ecf6c,_0x299e3b){return new Promise(function(_0x10c5f9,_0x469119){const _0x556415=a394_0x46d8,_0x2e63b0=_0x299e3b||client;return _0x2e63b0['request'](_0x590dbd,_0x3ecf6c)['then'](function(_0x1c9f62){const _0x4d6777=a394_0x46d8;logger[_0x4d6777('0x42')](_0x4d6777('0x1f'),_0x3bd097,_0x4d6777('0x90')),logger[_0x4d6777('0x13')](_0x4d6777('0x20'),_0x3bd097,_0x4d6777('0x90'),JSON[_0x4d6777('0x3a')](_0x1c9f62));if(_0x1c9f62['error']){if(_0x1c9f62[_0x4d6777('0xb')][_0x4d6777('0x8e')]===0x1f4)return logger[_0x4d6777('0xb')](_0x4d6777('0x1f'),_0x3bd097,_0x1c9f62[_0x4d6777('0xb')][_0x4d6777('0x83')]),_0x469119(_0x1c9f62['error'][_0x4d6777('0x83')]);return logger['error']('MailAccount,\x20%s,\x20%s',_0x3bd097,_0x1c9f62['error'][_0x4d6777('0x83')]),_0x10c5f9(_0x1c9f62[_0x4d6777('0xb')]['message']);}else logger[_0x4d6777('0x42')](_0x4d6777('0x1f'),_0x3bd097,_0x4d6777('0x90')),_0x10c5f9(_0x1c9f62[_0x4d6777('0x6d')][_0x4d6777('0x83')]);})[_0x556415('0x26')](function(_0x32818e){const _0x1e4004=_0x556415;logger[_0x1e4004('0xb')]('MailAccount,\x20%s,\x20%s',_0x3bd097,_0x32818e),_0x469119(_0x32818e);});});}function respondWithStatusCode(_0x30ffc0,_0x2eb69a){return _0x2eb69a=_0x2eb69a||0xcc,function(_0x568ab5){const _0x4f88ee=a394_0x46d8;if(_0x568ab5)return _0x30ffc0[_0x4f88ee('0x95')](_0x2eb69a);return _0x30ffc0['status'](_0x2eb69a)[_0x4f88ee('0x32')]();};}function respondWithResult(_0x4957c2,_0x2db7f7){return _0x2db7f7=_0x2db7f7||0xc8,function(_0x3757a9){const _0x22200e=a394_0x46d8;if(_0x3757a9)return _0x4957c2[_0x22200e('0x73')](_0x2db7f7)[_0x22200e('0x5e')](_0x3757a9);};}function respondWithFilteredResult(_0x371f46,_0x313df7){return function(_0x2cd26f){const _0x241675=a394_0x46d8;if(_0x2cd26f){const _0x343d7d=_0x2cd26f[_0x241675('0x56')],_0x5de078=_0x313df7[_0x241675('0x91')];let _0x467a88=_0x313df7[_0x241675('0x91')]+_0x313df7['limit'],_0x57b5c4;return _0x467a88>=_0x343d7d?(_0x467a88=_0x343d7d,_0x57b5c4=0xc8):_0x57b5c4=0xce,_0x371f46['status'](_0x57b5c4),_0x371f46[_0x241675('0x31')](_0x241675('0x87'),_0x5de078+'-'+_0x467a88+'/'+_0x343d7d)[_0x241675('0x5e')](_0x2cd26f);}return null;};}function saveUpdates(_0x1fdcca){return function(_0x151f26){if(_0x151f26)return _0x151f26['update'](_0x1fdcca)['then'](function(_0x5dcbdb){return _0x5dcbdb;});return null;};}function removeEntity(_0xc178fb){return function(_0x402189){const _0x4f38fd=a394_0x46d8;if(_0x402189)return _0x402189[_0x4f38fd('0x96')]()[_0x4f38fd('0x79')](function(){const _0x4269a4=_0x4f38fd,_0x9ea0fd=_0x402189[_0x4269a4('0xa7')]({'plain':!![]}),_0x39008e='MailAccounts';return db[_0x4269a4('0x2d')][_0x4269a4('0x96')]({'where':{'type':_0x39008e,'resourceId':_0x9ea0fd['id']}})[_0x4269a4('0x79')](function(){return _0x402189;});})[_0x4f38fd('0x79')](function(){const _0x3437ab=_0x4f38fd;_0xc178fb['status'](0xcc)[_0x3437ab('0x32')]();});};}function handleEntityNotFound(_0x2bbf90){return function(_0x1546b8){return!_0x1546b8&&_0x2bbf90['sendStatus'](0x194),_0x1546b8;};}function handleError(_0x565065,_0x35478){return _0x35478=_0x35478||0x1f4,function(_0x4c65a0){const _0xac5da=a394_0x46d8;logger[_0xac5da('0xb')](_0x4c65a0['stack']),_0x4c65a0[_0xac5da('0x71')]&&delete _0x4c65a0[_0xac5da('0x71')],_0x565065[_0xac5da('0x73')](_0x35478)[_0xac5da('0x7a')](_0x4c65a0);};}exports[_0x59b80f('0x8b')]=function(_0x1f37c7,_0x353ff4){const _0x2d23ef=_0x59b80f;let _0x346cb2={'include':[{'model':db[_0x2d23ef('0x1a')],'as':_0x2d23ef('0x47')},{'model':db[_0x2d23ef('0x5f')],'as':_0x2d23ef('0x44')},{'model':db[_0x2d23ef('0x76')],'as':_0x2d23ef('0x1b')}]};const _0xe73c77={},_0x14eca0={'count':0x0,'rows':[]},_0x1f4e47=_[_0x2d23ef('0x4b')](db['MailAccount'][_0x2d23ef('0x2b')],function(_0x44ba58){const _0x20afce=_0x2d23ef;return{'name':_0x44ba58[_0x20afce('0x60')],'type':_0x44ba58[_0x20afce('0x81')][_0x20afce('0x43')]};});_0xe73c77[_0x2d23ef('0x4c')]=_[_0x2d23ef('0x4b')](_0x1f4e47,_0x2d23ef('0x71')),_0xe73c77[_0x2d23ef('0x28')]=_[_0x2d23ef('0x6a')](_0x1f37c7[_0x2d23ef('0x28')]),_0xe73c77[_0x2d23ef('0x64')]=_[_0x2d23ef('0xac')](_0xe73c77[_0x2d23ef('0x4c')],_0xe73c77[_0x2d23ef('0x28')]),_0x346cb2['attributes']=_['intersection'](_0xe73c77[_0x2d23ef('0x4c')],qs['fields'](_0x1f37c7[_0x2d23ef('0x28')]['fields'])),_0x346cb2['attributes']=_0x346cb2['attributes'][_0x2d23ef('0x5b')]?_0x346cb2[_0x2d23ef('0x10')]:_0xe73c77[_0x2d23ef('0x4c')];typeof _0x1f37c7['query'][_0x2d23ef('0x88')]===_0x2d23ef('0x3')&&(_0x346cb2[_0x2d23ef('0x33')]=qs[_0x2d23ef('0x33')](_0x1f37c7[_0x2d23ef('0x28')]['limit']),_0x346cb2[_0x2d23ef('0x91')]=qs[_0x2d23ef('0x91')](_0x1f37c7[_0x2d23ef('0x28')][_0x2d23ef('0x91')]));_0x346cb2[_0x2d23ef('0x8d')]=qs[_0x2d23ef('0xa0')](_0x1f37c7[_0x2d23ef('0x28')][_0x2d23ef('0xa0')]),_0x346cb2['where']=qs['filters'](_['pick'](_0x1f37c7[_0x2d23ef('0x28')],_0xe73c77[_0x2d23ef('0x64')]),_0x1f4e47);_0x1f37c7[_0x2d23ef('0x28')][_0x2d23ef('0x27')]&&(_0x346cb2[_0x2d23ef('0x3e')]=_[_0x2d23ef('0x41')](_0x346cb2['where'],{[Op['or']]:_[_0x2d23ef('0x4b')](_0x1f4e47,function(_0x4cabf4){const _0x337851=_0x2d23ef;if(_0x4cabf4[_0x337851('0x81')]!==_0x337851('0x9')){const _0x56a4b0={};return _0x56a4b0[_0x4cabf4[_0x337851('0x71')]]={[Op[_0x337851('0x7d')]]:'%'+_0x1f37c7['query'][_0x337851('0x27')]+'%'},_0x56a4b0;}})}));_0x346cb2=_[_0x2d23ef('0x41')]({},_0x346cb2,_0x1f37c7[_0x2d23ef('0x5a')]);const _0x2ca790={'where':_0x346cb2[_0x2d23ef('0x3e')]};return db[_0x2d23ef('0x3d')]['count'](_0x2ca790)['then'](function(_0x20f714){const _0x100ff5=_0x2d23ef;return _0x14eca0['count']=_0x20f714,_0x1f37c7[_0x100ff5('0x28')][_0x100ff5('0x4a')]&&(_0x346cb2['include']=[{'all':!![]}]),db['MailAccount']['findAll'](_0x346cb2);})[_0x2d23ef('0x79')](function(_0x502c0b){const _0x3dd5e6=_0x2d23ef;return _0x14eca0[_0x3dd5e6('0xa8')]=_0x502c0b,_0x14eca0;})[_0x2d23ef('0x79')](respondWithFilteredResult(_0x353ff4,_0x346cb2))[_0x2d23ef('0x26')](handleError(_0x353ff4,null));},exports[_0x59b80f('0x5')]=function(_0x373930,_0x1e5f8f){const _0x1f1a81=_0x59b80f;let _0x508aeb={'raw':![],'where':{'id':_0x373930[_0x1f1a81('0x9c')]['id']},'include':[{'model':db['MailServerIn'],'as':'Imap'},{'model':db[_0x1f1a81('0x5f')],'as':_0x1f1a81('0x44')},{'model':db['Pause'],'as':_0x1f1a81('0x1b')}]};const _0x2723dd={};return _0x2723dd['model']=_[_0x1f1a81('0x6a')](db[_0x1f1a81('0x3d')][_0x1f1a81('0x2b')]),_0x2723dd['query']=_['keys'](_0x373930[_0x1f1a81('0x28')]),_0x2723dd[_0x1f1a81('0x64')]=_['intersection'](_0x2723dd[_0x1f1a81('0x4c')],_0x2723dd[_0x1f1a81('0x28')]),_0x508aeb['attributes']=_['intersection'](_0x2723dd[_0x1f1a81('0x4c')],qs[_0x1f1a81('0xa6')](_0x373930['query'][_0x1f1a81('0xa6')])),_0x508aeb[_0x1f1a81('0x10')]=_0x508aeb['attributes'][_0x1f1a81('0x5b')]?_0x508aeb[_0x1f1a81('0x10')]:_0x2723dd[_0x1f1a81('0x4c')],_0x373930['query'][_0x1f1a81('0x4a')]&&(_0x508aeb['include']=[{'all':!![]}]),_0x508aeb=_[_0x1f1a81('0x41')]({},_0x508aeb,_0x373930[_0x1f1a81('0x5a')]),db['MailAccount'][_0x1f1a81('0x99')](_0x508aeb)['then'](handleEntityNotFound(_0x1e5f8f,null))[_0x1f1a81('0x79')](respondWithResult(_0x1e5f8f,null))['catch'](handleError(_0x1e5f8f,null));},exports['update']=function(_0x361e72,_0x21eef9){const _0x2b6f75=_0x59b80f;return _0x361e72[_0x2b6f75('0x39')]['id']&&delete _0x361e72['body']['id'],db[_0x2b6f75('0x3d')][_0x2b6f75('0x99')]({'where':{'id':_0x361e72['params']['id']},'include':[{'model':db[_0x2b6f75('0x1a')],'as':_0x2b6f75('0x47')},{'model':db[_0x2b6f75('0x5f')],'as':_0x2b6f75('0x44')},{'model':db['Pause'],'as':_0x2b6f75('0x1b')}]})[_0x2b6f75('0x79')](handleEntityNotFound(_0x21eef9,null))[_0x2b6f75('0x79')](saveUpdates(_0x361e72[_0x2b6f75('0x39')],null))[_0x2b6f75('0x79')](function(_0x9b09ab){const _0x2d0c7a=_0x2b6f75;if(_0x9b09ab&&_0x361e72[_0x2d0c7a('0x39')]['Imap'])return db[_0x2d0c7a('0x1a')][_0x2d0c7a('0x3b')](_0x361e72['body']['Imap'],{'where':{'MailAccountId':_0x9b09ab['id']}})['then'](function(){return _0x9b09ab;});return _0x9b09ab;})[_0x2b6f75('0x79')](function(_0x186524){const _0x2f5e38=_0x2b6f75;if(_0x186524&&_0x361e72[_0x2f5e38('0x39')][_0x2f5e38('0x44')])return db[_0x2f5e38('0x5f')][_0x2f5e38('0x3b')](_0x361e72[_0x2f5e38('0x39')][_0x2f5e38('0x44')],{'where':{'MailAccountId':_0x186524['id']}})[_0x2f5e38('0x79')](function(){return _0x186524;});return _0x186524;})[_0x2b6f75('0x79')](respondWithResult(_0x21eef9,null))[_0x2b6f75('0x26')](handleError(_0x21eef9,null));},exports[_0x59b80f('0x9b')]=function(_0x43f354,_0x12c51d){const _0x37e3c5=_0x59b80f;return db[_0x37e3c5('0x3d')][_0x37e3c5('0x9b')]()[_0x37e3c5('0x79')](respondWithResult(_0x12c51d,null))[_0x37e3c5('0x26')](handleError(_0x12c51d,null));},exports[_0x59b80f('0x24')]=function(_0x4b9388,_0x642cb){const _0xcfb97a=_0x59b80f;return _0x4b9388['body']['id']&&delete _0x4b9388['body']['id'],db['MailAccount'][_0xcfb97a('0x99')]({'where':{'id':_0x4b9388[_0xcfb97a('0x9c')]['id']}})[_0xcfb97a('0x79')](handleEntityNotFound(_0x642cb,null))[_0xcfb97a('0x79')](function(_0x2325c9){const _0x42df69=_0xcfb97a;if(_0x2325c9)return _0x4b9388[_0x42df69('0x39')][_0x42df69('0x65')]=_0x2325c9['id'],db[_0x42df69('0x21')]['create'](_0x4b9388['body']);})['then'](respondWithResult(_0x642cb,null))[_0xcfb97a('0x26')](handleError(_0x642cb,null));},exports[_0x59b80f('0x35')]=function(_0x48bbc3,_0x3c393c){const _0x551a2b=_0x59b80f;let _0x43bd82={'raw':![],'where':{}};const _0x414a84={},_0xe2db0c={'count':0x0,'rows':[]};return db[_0x551a2b('0x3d')]['findOne']({'where':{'id':_0x48bbc3[_0x551a2b('0x9c')]['id']}})[_0x551a2b('0x79')](handleEntityNotFound(_0x3c393c,null))['then'](function(_0x546653){const _0xeb5b14=_0x551a2b;if(_0x546653)return _0x414a84[_0xeb5b14('0x4c')]=_['keys'](db[_0xeb5b14('0x21')][_0xeb5b14('0x2b')]),_0x414a84[_0xeb5b14('0x28')]=_['keys'](_0x48bbc3[_0xeb5b14('0x28')]),_0x414a84[_0xeb5b14('0x64')]=_['intersection'](_0x414a84[_0xeb5b14('0x4c')],_0x414a84[_0xeb5b14('0x28')]),_0x43bd82[_0xeb5b14('0x10')]=_[_0xeb5b14('0xac')](_0x414a84[_0xeb5b14('0x4c')],qs['fields'](_0x48bbc3[_0xeb5b14('0x28')][_0xeb5b14('0xa6')])),_0x43bd82[_0xeb5b14('0x10')]=_0x43bd82[_0xeb5b14('0x10')]['length']?_0x43bd82[_0xeb5b14('0x10')]:_0x414a84[_0xeb5b14('0x4c')],typeof _0x48bbc3[_0xeb5b14('0x28')][_0xeb5b14('0x88')]===_0xeb5b14('0x3')&&(_0x43bd82[_0xeb5b14('0x33')]=qs[_0xeb5b14('0x33')](_0x48bbc3[_0xeb5b14('0x28')][_0xeb5b14('0x33')]),_0x43bd82[_0xeb5b14('0x91')]=qs['offset'](_0x48bbc3[_0xeb5b14('0x28')][_0xeb5b14('0x91')])),_0x43bd82['order']=qs[_0xeb5b14('0xa0')](_0x48bbc3['query'][_0xeb5b14('0xa0')]),_0x43bd82['where']=qs[_0xeb5b14('0x64')](_[_0xeb5b14('0x53')](_0x48bbc3['query'],_0x414a84[_0xeb5b14('0x64')])),_0x43bd82[_0xeb5b14('0x3e')]['MailAccountId']=_0x546653['id'],_0x48bbc3['query'][_0xeb5b14('0x27')]&&(_0x43bd82['where']=_[_0xeb5b14('0x41')](_0x43bd82[_0xeb5b14('0x3e')],{[Op['or']]:_[_0xeb5b14('0x4b')](_0x43bd82[_0xeb5b14('0x10')],function(_0x36c9e6){const _0x4ed012=_0xeb5b14,_0x1e963d={};return _0x1e963d[_0x36c9e6]={[Op[_0x4ed012('0x7d')]]:'%'+_0x48bbc3[_0x4ed012('0x28')][_0x4ed012('0x27')]+'%'},_0x1e963d;})})),_0x43bd82=_[_0xeb5b14('0x41')]({},_0x43bd82,_0x48bbc3[_0xeb5b14('0x5a')]),db[_0xeb5b14('0x21')][_0xeb5b14('0x56')]({'where':_0x43bd82['where']})[_0xeb5b14('0x79')](function(_0xf968e5){const _0x45a74a=_0xeb5b14;return _0xe2db0c['count']=_0xf968e5,_0x48bbc3['query'][_0x45a74a('0x4a')]&&(_0x43bd82[_0x45a74a('0x3c')]=[{'all':!![]}]),db['Disposition']['findAll'](_0x43bd82);})['then'](function(_0x2fac59){const _0x1c12e9=_0xeb5b14;return _0xe2db0c[_0x1c12e9('0xa8')]=_0x2fac59,_0xe2db0c;});})['then'](respondWithFilteredResult(_0x3c393c,_0x43bd82))['catch'](handleError(_0x3c393c,null));},exports[_0x59b80f('0x40')]=function(_0x4770d2,_0x2a18fa){const _0x628150=_0x59b80f;return db[_0x628150('0x3d')]['findOne']({'where':{'id':_0x4770d2[_0x628150('0x9c')]['id']}})[_0x628150('0x79')](handleEntityNotFound(_0x2a18fa,null))[_0x628150('0x79')](function(_0x538d78){const _0x38593b=_0x628150;if(_0x538d78)return _0x538d78[_0x38593b('0x40')](_0x4770d2[_0x38593b('0x28')][_0x38593b('0x0')]);})[_0x628150('0x79')](respondWithStatusCode(_0x2a18fa,null))[_0x628150('0x26')](handleError(_0x2a18fa,null));},exports[_0x59b80f('0xa5')]=function(_0x1eed29,_0x321d2e){const _0xd7bc37=_0x59b80f;return _0x1eed29[_0xd7bc37('0x39')]['id']&&delete _0x1eed29[_0xd7bc37('0x39')]['id'],db[_0xd7bc37('0x3d')][_0xd7bc37('0x99')]({'where':{'id':_0x1eed29[_0xd7bc37('0x9c')]['id']}})[_0xd7bc37('0x79')](handleEntityNotFound(_0x321d2e,null))['then'](function(_0x473aef){const _0x5b901b=_0xd7bc37;if(_0x473aef)return _0x1eed29['body'][_0x5b901b('0x65')]=_0x473aef['id'],db[_0x5b901b('0x59')][_0x5b901b('0xa9')](_0x1eed29[_0x5b901b('0x39')]);})[_0xd7bc37('0x79')](respondWithResult(_0x321d2e,null))[_0xd7bc37('0x26')](handleError(_0x321d2e,null));},exports[_0x59b80f('0x9e')]=function(_0x309680,_0x1a068c){const _0x4fd7ec=_0x59b80f;let _0x4b0b31={'raw':![],'where':{}};const _0xbce2d={},_0x28a36b={'count':0x0,'rows':[]};return db[_0x4fd7ec('0x3d')][_0x4fd7ec('0x99')]({'where':{'id':_0x309680[_0x4fd7ec('0x9c')]['id']}})[_0x4fd7ec('0x79')](handleEntityNotFound(_0x1a068c,null))[_0x4fd7ec('0x79')](function(_0x258933){const _0x26de80=_0x4fd7ec;if(_0x258933)return _0xbce2d[_0x26de80('0x4c')]=_[_0x26de80('0x6a')](db[_0x26de80('0x59')][_0x26de80('0x2b')]),_0xbce2d[_0x26de80('0x28')]=_['keys'](_0x309680['query']),_0xbce2d[_0x26de80('0x64')]=_[_0x26de80('0xac')](_0xbce2d[_0x26de80('0x4c')],_0xbce2d['query']),_0x4b0b31[_0x26de80('0x10')]=_['intersection'](_0xbce2d[_0x26de80('0x4c')],qs[_0x26de80('0xa6')](_0x309680['query'][_0x26de80('0xa6')])),_0x4b0b31[_0x26de80('0x10')]=_0x4b0b31['attributes'][_0x26de80('0x5b')]?_0x4b0b31[_0x26de80('0x10')]:_0xbce2d[_0x26de80('0x4c')],typeof _0x309680[_0x26de80('0x28')][_0x26de80('0x88')]===_0x26de80('0x3')&&(_0x4b0b31[_0x26de80('0x33')]=qs[_0x26de80('0x33')](_0x309680[_0x26de80('0x28')]['limit']),_0x4b0b31[_0x26de80('0x91')]=qs[_0x26de80('0x91')](_0x309680[_0x26de80('0x28')]['offset'])),_0x4b0b31[_0x26de80('0x8d')]=qs['sort'](_0x309680[_0x26de80('0x28')]['sort']),_0x4b0b31[_0x26de80('0x3e')]=qs['filters'](_[_0x26de80('0x53')](_0x309680[_0x26de80('0x28')],_0xbce2d[_0x26de80('0x64')])),_0x4b0b31[_0x26de80('0x3e')]['MailAccountId']=_0x258933['id'],_0x309680[_0x26de80('0x28')]['filter']&&(_0x4b0b31[_0x26de80('0x3e')]=_[_0x26de80('0x41')](_0x4b0b31[_0x26de80('0x3e')],{[Op['or']]:_['map'](_0x4b0b31['attributes'],function(_0x577196){const _0x2894a7=_0x26de80,_0xd8dc55={};return _0xd8dc55[_0x577196]={[Op[_0x2894a7('0x7d')]]:'%'+_0x309680[_0x2894a7('0x28')]['filter']+'%'},_0xd8dc55;})})),_0x4b0b31=_[_0x26de80('0x41')]({},_0x4b0b31,_0x309680[_0x26de80('0x5a')]),db['CannedAnswer'][_0x26de80('0x56')]({'where':_0x4b0b31[_0x26de80('0x3e')]})['then'](function(_0x7a0c2c){const _0xd022a3=_0x26de80;return _0x28a36b[_0xd022a3('0x56')]=_0x7a0c2c,_0x309680[_0xd022a3('0x28')][_0xd022a3('0x4a')]&&(_0x4b0b31[_0xd022a3('0x3c')]=[{'all':!![]}]),db[_0xd022a3('0x59')]['findAll'](_0x4b0b31);})[_0x26de80('0x79')](function(_0x382723){const _0x1de8b3=_0x26de80;return _0x28a36b[_0x1de8b3('0xa8')]=_0x382723,_0x28a36b;});})['then'](respondWithFilteredResult(_0x1a068c,_0x4b0b31))[_0x4fd7ec('0x26')](handleError(_0x1a068c,null));},exports[_0x59b80f('0x4')]=function(_0x27c4b7,_0x2eeb25){const _0x280d8a=_0x59b80f;return db[_0x280d8a('0x3d')][_0x280d8a('0x99')]({'where':{'id':_0x27c4b7['params']['id']}})['then'](handleEntityNotFound(_0x2eeb25,null))[_0x280d8a('0x79')](function(_0x5074e8){const _0x329139=_0x280d8a;if(_0x5074e8)return _0x5074e8[_0x329139('0x4')](_0x27c4b7['query'][_0x329139('0x0')]);})[_0x280d8a('0x79')](respondWithStatusCode(_0x2eeb25,null))[_0x280d8a('0x26')](handleError(_0x2eeb25,null));},exports[_0x59b80f('0xa9')]=function(_0x546df4,_0x5ae20e){const _0x4b3fc2=_0x59b80f,_0x435401={'name':_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x71')],'key':_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x43')],'email':_0x546df4[_0x4b3fc2('0x39')]['email'],'ListId':_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x69')],'active':!_[_0x4b3fc2('0x85')](_0x546df4[_0x4b3fc2('0x39')]['active'])?_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x8f')]:!![],'description':_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x19')]||null,'Imap':{},'Smtp':{}};return _['isNil'](_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x97')])?(_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x2e')]?(_0x435401[_0x4b3fc2('0x47')]['user']=_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x54')],_0x435401['Smtp'][_0x4b3fc2('0xe')]=_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x54')],_0x435401[_0x4b3fc2('0x47')]['password']=_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x16')],_0x435401[_0x4b3fc2('0x44')][_0x4b3fc2('0x6e')]=_0x546df4[_0x4b3fc2('0x39')]['cpassword']):(_0x435401[_0x4b3fc2('0x47')][_0x4b3fc2('0x2')]=![],_0x435401[_0x4b3fc2('0x44')]['authentication']=![]),_0x435401[_0x4b3fc2('0x47')][_0x4b3fc2('0x15')]=_0x546df4[_0x4b3fc2('0x39')]['Imap'][_0x4b3fc2('0x15')],_0x435401[_0x4b3fc2('0x47')][_0x4b3fc2('0x1e')]=_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x47')][_0x4b3fc2('0x1e')],_0x435401[_0x4b3fc2('0x44')]['host']=_0x546df4['body'][_0x4b3fc2('0x44')][_0x4b3fc2('0x15')],_0x435401[_0x4b3fc2('0x44')]['port']=_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x44')][_0x4b3fc2('0x1e')]):(_0x435401[_0x4b3fc2('0x47')][_0x4b3fc2('0x98')]=_0x546df4['body'][_0x4b3fc2('0x97')],_0x435401[_0x4b3fc2('0x44')]['service']=_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x97')],_0x435401[_0x4b3fc2('0x47')][_0x4b3fc2('0xe')]=_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x54')],_0x435401['Smtp'][_0x4b3fc2('0xe')]=_0x546df4[_0x4b3fc2('0x39')][_0x4b3fc2('0x54')],_0x435401['Imap'][_0x4b3fc2('0x17')]=_0x546df4[_0x4b3fc2('0x39')]['cpassword'],_0x435401[_0x4b3fc2('0x44')][_0x4b3fc2('0x6e')]=_0x546df4[_0x4b3fc2('0x39')]['cpassword']),db['MailAccount'][_0x4b3fc2('0xa9')](_0x435401,{'include':[{'model':db[_0x4b3fc2('0x5f')],'as':_0x4b3fc2('0x44')},{'model':db[_0x4b3fc2('0x1a')],'as':_0x4b3fc2('0x47')}]})[_0x4b3fc2('0x79')](function(_0x2e25b5){const _0x36df4e=_0x4b3fc2,_0x537b33=_0x546df4[_0x36df4e('0xe')][_0x36df4e('0xa7')]({'plain':!![]});if(!_0x537b33)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x537b33[_0x36df4e('0x6c')]===_0x36df4e('0xe')){const _0x10e708=_0x2e25b5[_0x36df4e('0xa7')]({'plain':!![]});return db[_0x36df4e('0x2c')][_0x36df4e('0x99')]({'where':{'name':_0x36df4e('0x63'),'userProfileId':_0x537b33[_0x36df4e('0x6f')]},'raw':!![]})[_0x36df4e('0x79')](function(_0x3c2310){const _0x4fb8ea=_0x36df4e;return _0x3c2310&&_0x3c2310[_0x4fb8ea('0x75')]===0x0?db['UserProfileResource']['create']({'name':_0x10e708[_0x4fb8ea('0x71')],'resourceId':_0x10e708['id'],'type':_0x3c2310[_0x4fb8ea('0x71')],'sectionId':_0x3c2310['id']},{})[_0x4fb8ea('0x79')](function(){return _0x2e25b5;}):_0x2e25b5;})[_0x36df4e('0x26')](function(_0x1881c9){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x1881c9);throw _0x1881c9;});}return _0x2e25b5;})[_0x4b3fc2('0x79')](respondWithResult(_0x5ae20e,0xc9))['catch'](handleError(_0x5ae20e,null));},exports[_0x59b80f('0xf')]=function(_0x133725,_0x50e3ae){const _0xb062ca=_0x59b80f;return db[_0xb062ca('0x3d')][_0xb062ca('0x99')]({'where':{'id':_0x133725['params']['id']}})[_0xb062ca('0x79')](handleEntityNotFound(_0x50e3ae,null))[_0xb062ca('0x79')](function(_0x4f2125){if(_0x4f2125)return _0x4f2125['getImap']();return null;})[_0xb062ca('0x79')](respondWithResult(_0x50e3ae,null))[_0xb062ca('0x26')](handleError(_0x50e3ae,null));},exports['addImap']=function(_0xc76d16,_0x5f28fc){const _0x272d1f=_0x59b80f;return _0xc76d16[_0x272d1f('0x39')]['id']&&delete _0xc76d16[_0x272d1f('0x39')]['id'],db[_0x272d1f('0x3d')]['findOne']({'where':{'id':_0xc76d16[_0x272d1f('0x9c')]['id']}})[_0x272d1f('0x79')](handleEntityNotFound(_0x5f28fc,null))[_0x272d1f('0x79')](function(_0x3f840a){const _0x34061c=_0x272d1f;if(_0x3f840a)return _0xc76d16['body'][_0x34061c('0x65')]=_0x3f840a['id'],db[_0x34061c('0x1a')]['create'](_0xc76d16['body']);})[_0x272d1f('0x79')](respondWithResult(_0x5f28fc,null))[_0x272d1f('0x26')](handleError(_0x5f28fc,null));},exports[_0x59b80f('0xa')]=function(_0x3c27a6,_0x5d6d90){const _0x3d67d4=_0x59b80f;return db[_0x3d67d4('0x3d')]['findOne']({'where':{'id':_0x3c27a6['params']['id']}})[_0x3d67d4('0x79')](handleEntityNotFound(_0x5d6d90,null))[_0x3d67d4('0x79')](function(_0x43b688){const _0xf370b9=_0x3d67d4;if(_0x43b688)return _0x43b688[_0xf370b9('0x8')](null);return null;})[_0x3d67d4('0x79')](respondWithStatusCode(_0x5d6d90,null))[_0x3d67d4('0x26')](handleError(_0x5d6d90,null));},exports[_0x59b80f('0x66')]=function(_0x299a7b,_0x1b9eda){const _0x1190a2=_0x59b80f;return db[_0x1190a2('0x3d')][_0x1190a2('0x99')]({'where':{'id':_0x299a7b['params']['id']}})[_0x1190a2('0x79')](handleEntityNotFound(_0x1b9eda,null))[_0x1190a2('0x79')](function(_0x35eccf){const _0x242c1f=_0x1190a2;if(_0x35eccf)return _0x35eccf[_0x242c1f('0x66')]();return null;})[_0x1190a2('0x79')](respondWithResult(_0x1b9eda,null))[_0x1190a2('0x26')](handleError(_0x1b9eda,null));},exports[_0x59b80f('0x86')]=function(_0x444bcd,_0x235fe7){const _0x3ed359=_0x59b80f;return _0x444bcd[_0x3ed359('0x39')]['id']&&delete _0x444bcd[_0x3ed359('0x39')]['id'],db[_0x3ed359('0x3d')][_0x3ed359('0x99')]({'where':{'id':_0x444bcd[_0x3ed359('0x9c')]['id']}})[_0x3ed359('0x79')](handleEntityNotFound(_0x235fe7,null))[_0x3ed359('0x79')](function(_0x7a411e){const _0x3ca628=_0x3ed359;if(_0x7a411e)return _0x444bcd[_0x3ca628('0x39')][_0x3ca628('0x65')]=_0x7a411e['id'],db[_0x3ca628('0x5f')][_0x3ca628('0xa9')](_0x444bcd[_0x3ca628('0x39')]);})[_0x3ed359('0x79')](respondWithResult(_0x235fe7,null))[_0x3ed359('0x26')](handleError(_0x235fe7,null));},exports[_0x59b80f('0x7e')]=function(_0x2ab4b1,_0x694ca9){const _0x111f6c=_0x59b80f;return db[_0x111f6c('0x3d')][_0x111f6c('0x99')]({'where':{'id':_0x2ab4b1[_0x111f6c('0x9c')]['id']}})[_0x111f6c('0x79')](handleEntityNotFound(_0x694ca9,null))[_0x111f6c('0x79')](function(_0x242c92){const _0x212eea=_0x111f6c;if(_0x242c92)return _0x242c92[_0x212eea('0x37')](null);return null;})[_0x111f6c('0x79')](respondWithStatusCode(_0x694ca9,null))['catch'](handleError(_0x694ca9,null));},exports[_0x59b80f('0x55')]=function(_0x984217,_0x57325c){const _0x21c7de=_0x59b80f;return db[_0x21c7de('0x2f')][_0x21c7de('0x99')]({'where':{'id':_0x984217[_0x21c7de('0x9c')]['id']}})[_0x21c7de('0x79')](function(_0x954eae){const _0x5f5963=_0x21c7de;if(_0x954eae)return _0x954eae['addInteraction'](_0x984217[_0x5f5963('0x39')][_0x5f5963('0x0')],{'through':_['omit'](_0x984217[_0x5f5963('0x39')],['ids','id'])});})[_0x21c7de('0x79')](respondWithResult(_0x57325c,null))[_0x21c7de('0x26')](handleError(_0x57325c,null));},exports['getInteractions']=function(_0x2df096,_0x18238c){const _0x1364ee=_0x59b80f;let _0x4981de={'raw':![],'where':{}};const _0x28b2a1={},_0xe3e967={'count':0x0,'rows':[]};return db['MailAccount'][_0x1364ee('0x99')]({'where':{'id':_0x2df096[_0x1364ee('0x9c')]['id']}})[_0x1364ee('0x79')](handleEntityNotFound(_0x18238c,null))[_0x1364ee('0x79')](function(_0x31b47c){const _0x56d678=_0x1364ee;if(_0x31b47c)return _0x28b2a1['model']=_['keys'](db[_0x56d678('0x2f')]['rawAttributes']),_0x28b2a1[_0x56d678('0x28')]=_[_0x56d678('0x6a')](_0x2df096[_0x56d678('0x28')]),_0x28b2a1['filters']=_[_0x56d678('0xac')](_0x28b2a1[_0x56d678('0x4c')],_0x28b2a1[_0x56d678('0x28')]),_0x4981de[_0x56d678('0x10')]=_[_0x56d678('0xac')](_0x28b2a1[_0x56d678('0x4c')],qs[_0x56d678('0xa6')](_0x2df096['query']['fields'])),_0x4981de[_0x56d678('0x10')]=_0x4981de[_0x56d678('0x10')][_0x56d678('0x5b')]?_0x4981de[_0x56d678('0x10')]:_0x28b2a1[_0x56d678('0x4c')],typeof _0x2df096[_0x56d678('0x28')][_0x56d678('0x88')]===_0x56d678('0x3')&&(_0x4981de[_0x56d678('0x33')]=qs['limit'](_0x2df096['query'][_0x56d678('0x33')]),_0x4981de[_0x56d678('0x91')]=qs['offset'](_0x2df096[_0x56d678('0x28')]['offset'])),_0x4981de['order']=qs[_0x56d678('0xa0')](_0x2df096[_0x56d678('0x28')]['sort']),_0x4981de['where']=qs[_0x56d678('0x64')](_['pick'](_0x2df096['query'],_0x28b2a1[_0x56d678('0x64')])),_0x4981de[_0x56d678('0x3e')][_0x56d678('0x65')]=_0x31b47c['id'],_0x2df096[_0x56d678('0x28')][_0x56d678('0x27')]&&(_0x4981de[_0x56d678('0x3e')]=_['merge'](_0x4981de['where'],{[Op['or']]:_[_0x56d678('0x4b')](_0x4981de['attributes'],function(_0x2640e8){const _0x18598a=_0x56d678,_0x4eb549={};return _0x4eb549[_0x2640e8]={[Op[_0x18598a('0x7d')]]:'%'+_0x2df096['query'][_0x18598a('0x27')]+'%'},_0x4eb549;})})),_0x4981de=_[_0x56d678('0x41')]({},_0x4981de,_0x2df096['options']),db['MailInteraction']['count']({'where':_0x4981de[_0x56d678('0x3e')]})['then'](function(_0x4be488){const _0x1f6c28=_0x56d678;return _0xe3e967[_0x1f6c28('0x56')]=_0x4be488,_0x2df096['query'][_0x1f6c28('0x4a')]&&(_0x4981de[_0x1f6c28('0x3c')]=[{'model':db[_0x1f6c28('0x5c')],'as':'Contact','required':![]},{'model':db[_0x1f6c28('0x46')],'as':_0x1f6c28('0x74'),'attributes':['name',_0x1f6c28('0x11'),'internal'],'required':![]},{'model':db['Tag'],'as':'Tags','attributes':['id',_0x1f6c28('0x71'),_0x1f6c28('0x68')],'where':_0x2df096[_0x1f6c28('0x28')]['tag']?{'id':_0x2df096[_0x1f6c28('0x28')][_0x1f6c28('0x4e')]}:undefined,'required':_0x2df096[_0x1f6c28('0x28')]['tag']?!![]:![]}]),db[_0x1f6c28('0x2f')]['findAll'](_0x4981de);})['then'](function(_0x42a42b){const _0x402b78=_0x56d678;return _0xe3e967[_0x402b78('0xa8')]=_0x42a42b,_0xe3e967;});})[_0x1364ee('0x79')](respondWithFilteredResult(_0x18238c,_0x4981de))[_0x1364ee('0x26')](handleError(_0x18238c,null));},exports['addApplications']=function(_0x1c7cfb,_0xd9d057){const _0x17e387=_0x59b80f;return db[_0x17e387('0x3d')][_0x17e387('0x99')]({'where':{'id':_0x1c7cfb[_0x17e387('0x9c')]['id']}})[_0x17e387('0x79')](handleEntityNotFound(_0xd9d057,null))[_0x17e387('0x79')](function(_0x54ece4){const _0x5b92d9=_0x17e387;if(_0x54ece4)return db['sequelize']['transaction'](function(_0x5ec121){const _0x35a9a9=a394_0x46d8;return db[_0x35a9a9('0x14')]['destroy']({'where':{'MailAccountId':_0x1c7cfb['params']['id']},'transaction':_0x5ec121})[_0x35a9a9('0x79')](function(){const _0x36e1f4=_0x35a9a9,_0x28fb75=_[_0x36e1f4('0x4b')](_0x1c7cfb[_0x36e1f4('0x39')],function(_0x23f669){const _0x16bf7f=_0x36e1f4;return _0x23f669[_0x16bf7f('0x65')]=_0x1c7cfb[_0x16bf7f('0x9c')]['id'],_0x23f669;});return db[_0x36e1f4('0x14')][_0x36e1f4('0x61')](_0x28fb75,{'transaction':_0x5ec121});});})[_0x5b92d9('0x79')](function(){const _0x4ff956=_0x5b92d9;return db[_0x4ff956('0x14')][_0x4ff956('0x45')]({'where':{'MailAccountId':_0x1c7cfb[_0x4ff956('0x9c')]['id']},'order':_0x4ff956('0x84')});});})[_0x17e387('0x79')](respondWithResult(_0xd9d057,null))['catch'](handleError(_0xd9d057,null));},exports[_0x59b80f('0x57')]=function(_0x4449df,_0x393a7b){const _0x1b1d79=_0x59b80f;let _0x330bcd={};const _0x16ceea={};let _0x29fc77,_0xd6ff26;return db[_0x1b1d79('0x3d')]['findOne']({'where':{'id':_0x4449df[_0x1b1d79('0x9c')]['id']}})[_0x1b1d79('0x79')](handleEntityNotFound(_0x393a7b,null))[_0x1b1d79('0x79')](function(_0x487ab7){const _0x3ccc77=_0x1b1d79;if(_0x487ab7)return _0x29fc77=_0x487ab7,_0x16ceea[_0x3ccc77('0x4c')]=_[_0x3ccc77('0x6a')](db['MailApplication'][_0x3ccc77('0x2b')]),_0x16ceea[_0x3ccc77('0x28')]=_[_0x3ccc77('0x6a')](_0x4449df[_0x3ccc77('0x28')]),_0x16ceea[_0x3ccc77('0x64')]=_[_0x3ccc77('0xac')](_0x16ceea[_0x3ccc77('0x4c')],_0x16ceea[_0x3ccc77('0x28')]),_0x330bcd[_0x3ccc77('0x10')]=_[_0x3ccc77('0xac')](_0x16ceea[_0x3ccc77('0x4c')],qs[_0x3ccc77('0xa6')](_0x4449df[_0x3ccc77('0x28')][_0x3ccc77('0xa6')])),_0x330bcd[_0x3ccc77('0x10')]=_0x330bcd[_0x3ccc77('0x10')][_0x3ccc77('0x5b')]?_0x330bcd['attributes']:_0x16ceea['model'],_0x330bcd['order']=qs[_0x3ccc77('0xa0')](_0x4449df[_0x3ccc77('0x28')][_0x3ccc77('0xa0')]),_0x330bcd['where']=qs[_0x3ccc77('0x64')](_[_0x3ccc77('0x53')](_0x4449df['query'],_0x16ceea['filters'])),_0x4449df['query'][_0x3ccc77('0x27')]&&(_0x330bcd['where']=_[_0x3ccc77('0x41')](_0x330bcd['where'],{[Op['or']]:_['map'](_0x330bcd[_0x3ccc77('0x10')],function(_0x5003c5){const _0x2f5ddb=_0x3ccc77,_0x28c9b6={};return _0x28c9b6[_0x5003c5]={[Op[_0x2f5ddb('0x7d')]]:'%'+_0x4449df[_0x2f5ddb('0x28')]['filter']+'%'},_0x28c9b6;})})),_0x330bcd=_[_0x3ccc77('0x41')]({},_0x330bcd,_0x4449df['options']),_0x29fc77['getApplications'](_0x330bcd);})['then'](function(_0x34a9a8){const _0x662de0=_0x1b1d79;if(_0x34a9a8)return _0xd6ff26=_0x34a9a8[_0x662de0('0x5b')],typeof _0x4449df[_0x662de0('0x28')][_0x662de0('0x88')]===_0x662de0('0x3')&&(_0x330bcd[_0x662de0('0x33')]=qs[_0x662de0('0x33')](_0x4449df[_0x662de0('0x28')]['limit']),_0x330bcd[_0x662de0('0x91')]=qs[_0x662de0('0x91')](_0x4449df[_0x662de0('0x28')][_0x662de0('0x91')])),_0x29fc77[_0x662de0('0x57')](_0x330bcd);})[_0x1b1d79('0x79')](function(_0x4b2f65){if(_0x4b2f65)return _0x4b2f65?{'count':_0xd6ff26,'rows':_0x4b2f65}:null;})[_0x1b1d79('0x79')](respondWithResult(_0x393a7b,null))[_0x1b1d79('0x26')](handleError(_0x393a7b,null));},exports['getMessages']=function(_0x4e4357,_0x100704){const _0x48efd8=_0x59b80f;let _0x234ae9={'raw':!![],'where':{}};const _0x4036f4={},_0x22ed03={'count':0x0,'rows':[]};return db[_0x48efd8('0x3d')][_0x48efd8('0x99')]({'where':{'id':_0x4e4357[_0x48efd8('0x9c')]['id']}})[_0x48efd8('0x79')](handleEntityNotFound(_0x100704,null))[_0x48efd8('0x79')](function(_0x2a2b17){const _0x2523b3=_0x48efd8;if(_0x2a2b17){_0x4036f4[_0x2523b3('0x4c')]=_[_0x2523b3('0x6a')](db['MailMessage'][_0x2523b3('0x2b')]),_0x4036f4[_0x2523b3('0x28')]=_['keys'](_0x4e4357[_0x2523b3('0x28')]),_0x4036f4[_0x2523b3('0x64')]=_[_0x2523b3('0xac')](_0x4036f4['model'],_0x4036f4['query']),_0x234ae9[_0x2523b3('0x10')]=_[_0x2523b3('0xac')](_0x4036f4[_0x2523b3('0x4c')],qs['fields'](_0x4e4357['query'][_0x2523b3('0xa6')])),_0x234ae9[_0x2523b3('0x10')]=_0x234ae9[_0x2523b3('0x10')][_0x2523b3('0x5b')]?_0x234ae9[_0x2523b3('0x10')]:_0x4036f4[_0x2523b3('0x4c')];typeof _0x4e4357[_0x2523b3('0x28')][_0x2523b3('0x88')]==='undefined'&&(_0x234ae9[_0x2523b3('0x33')]=qs[_0x2523b3('0x33')](_0x4e4357[_0x2523b3('0x28')][_0x2523b3('0x33')]),_0x234ae9[_0x2523b3('0x91')]=qs['offset'](_0x4e4357['query'][_0x2523b3('0x91')]));_0x234ae9[_0x2523b3('0x8d')]=qs[_0x2523b3('0xa0')](_0x4e4357['query'][_0x2523b3('0xa0')]),_0x234ae9[_0x2523b3('0x3e')]=qs[_0x2523b3('0x64')](_[_0x2523b3('0x53')](_0x4e4357[_0x2523b3('0x28')],_0x4036f4['filters'])),_0x234ae9['where'][_0x2523b3('0x65')]=_0x2a2b17['id'];_0x4e4357[_0x2523b3('0x28')][_0x2523b3('0x27')]&&(_0x234ae9[_0x2523b3('0x3e')]=_['merge'](_0x234ae9['where'],{[Op['or']]:_[_0x2523b3('0x4b')](_0x234ae9[_0x2523b3('0x10')],function(_0x5187a8){const _0x3172d1=_0x2523b3,_0xa7b0fd={};return _0xa7b0fd[_0x5187a8]={[Op[_0x3172d1('0x7d')]]:'%'+_0x4e4357['query'][_0x3172d1('0x27')]+'%'},_0xa7b0fd;})}));if(_0x4e4357['query'][_0x2523b3('0x12')]){const _0x3641a3=_0x4e4357[_0x2523b3('0x28')]['$gte'][_0x2523b3('0x34')](','),_0x88a8c3={};_0x88a8c3[_0x3641a3[0x0]]={[Op['gte']]:moment(_0x3641a3[0x1])[_0x2523b3('0x8a')]('YYYY-MM-DD\x20HH:mm:ss')},_0x234ae9[_0x2523b3('0x3e')]=_[_0x2523b3('0x41')](_0x234ae9[_0x2523b3('0x3e')],_0x88a8c3);}return _0x234ae9=_[_0x2523b3('0x41')]({},_0x234ae9,_0x4e4357[_0x2523b3('0x5a')]),db['MailMessage'][_0x2523b3('0x56')]({'where':_0x234ae9['where']})[_0x2523b3('0x79')](function(_0x38190b){const _0x158b54=_0x2523b3;return _0x22ed03[_0x158b54('0x56')]=_0x38190b,_0x4e4357[_0x158b54('0x28')][_0x158b54('0x4a')]&&(_0x234ae9[_0x158b54('0x3c')]=[{'all':!![]}]),db[_0x158b54('0x50')][_0x158b54('0xa2')](_0x234ae9);})[_0x2523b3('0x79')](function(_0x32685d){const _0x1aa47a=_0x2523b3;return _0x22ed03[_0x1aa47a('0xa8')]=_0x32685d,_0x22ed03;});}})['then'](respondWithFilteredResult(_0x100704,_0x234ae9))[_0x48efd8('0x26')](handleError(_0x100704,null));},exports[_0x59b80f('0x7a')]=function(_0x281675,_0x46c6c4){const _0x23592c=_0x59b80f;let _0x20e33b,_0x1dd779={},_0x3218f5;return _0x281675[_0x23592c('0x39')]['to']&&(_0x3218f5=_0x281675[_0x23592c('0x39')]['to'][_0x23592c('0x34')](',')[0x0]),db['MailAccount'][_0x23592c('0x99')]({'where':{'id':_0x281675[_0x23592c('0x9c')]['id']},'include':[{'model':db[_0x23592c('0x48')],'as':_0x23592c('0x9a'),'include':[{'model':db['CmContact'],'as':'Contacts','where':{'email':_0x3218f5},'limit':0x1,'order':[[_0x23592c('0x93'),_0x23592c('0x7b')]]}]},{'model':db['MailServerOut'],'as':_0x23592c('0x44'),'raw':!![]}]})[_0x23592c('0x79')](handleEntityNotFound(_0x46c6c4,null))['then'](function(_0x31403f){const _0x48e1ba=_0x23592c;if(_0x31403f){_0x20e33b=_0x31403f;if(_0x31403f[_0x48e1ba('0x44')]){_[_0x48e1ba('0x85')](_0x281675[_0x48e1ba('0x39')][_0x48e1ba('0xc')])&&(_0x281675[_0x48e1ba('0x39')][_0x48e1ba('0xc')]=util[_0x48e1ba('0x8a')](_0x48e1ba('0xa3'),_0x31403f[_0x48e1ba('0x71')],_0x31403f[_0x48e1ba('0xaa')]||_0x31403f[_0x48e1ba('0x44')][_0x48e1ba('0xe')]));if(_0x281675[_0x48e1ba('0x39')][_0x48e1ba('0x25')]&&_0x281675[_0x48e1ba('0x39')]['attachments']['length'])for(let _0x1404f2=0x0;_0x1404f2<_0x281675[_0x48e1ba('0x39')][_0x48e1ba('0x25')][_0x48e1ba('0x5b')];_0x1404f2+=0x1){_0x281675[_0x48e1ba('0x39')]['attachments'][_0x1404f2]={'filename':_0x281675[_0x48e1ba('0x39')][_0x48e1ba('0x25')][_0x1404f2][_0x48e1ba('0x71')],'path':path[_0x48e1ba('0x7')](config[_0x48e1ba('0x80')],_0x48e1ba('0x4f'),_0x281675['body'][_0x48e1ba('0x25')][_0x1404f2][_0x48e1ba('0x7c')])};}const _0x418ed8={'tls':{'rejectUnauthorized':![]}};return _[_0x48e1ba('0x85')](_0x31403f[_0x48e1ba('0x44')][_0x48e1ba('0x98')])?(_0x31403f[_0x48e1ba('0x44')][_0x48e1ba('0x2')]&&(_0x418ed8['auth']={'user':_0x31403f[_0x48e1ba('0x44')][_0x48e1ba('0xe')],'pass':_0x31403f['Smtp'][_0x48e1ba('0x6e')]}),_0x418ed8[_0x48e1ba('0x15')]=_0x31403f[_0x48e1ba('0x44')]['host'],_0x418ed8['port']=_0x31403f[_0x48e1ba('0x44')][_0x48e1ba('0x1e')],_0x418ed8['secure']=_0x31403f[_0x48e1ba('0x44')][_0x48e1ba('0x72')]):(_0x418ed8[_0x48e1ba('0x98')]=_0x31403f[_0x48e1ba('0x44')][_0x48e1ba('0x98')],_0x418ed8[_0x48e1ba('0x7f')]={'user':_0x31403f[_0x48e1ba('0x44')]['user'],'pass':_0x31403f[_0x48e1ba('0x44')]['pass']}),respondWithRpcPromise(_0x48e1ba('0x2a'),_0x48e1ba('0x49'),{'account':_0x418ed8,'message':_0x281675[_0x48e1ba('0x39')]});}else throw new Error(_0x48e1ba('0x1d'));}})[_0x23592c('0x79')](function(_0x4eaae3){const _0x137251=_0x23592c;if(_0x4eaae3){_0x1dd779=_0x4eaae3;if(_0x20e33b[_0x137251('0x9a')])return _0x20e33b[_0x137251('0x9a')][_0x137251('0xd')][_0x137251('0x5b')]?_0x20e33b['List'][_0x137251('0xd')][0x0]:db[_0x137251('0x5c')]['create'](_[_0x137251('0xa4')](_0x281675[_0x137251('0x39')],{'firstName':_0x281675[_0x137251('0x39')]['to'],'email':_0x281675[_0x137251('0x39')]['to'],'phone':_0x281675['body']['to'],'ListId':_0x20e33b[_0x137251('0x69')]}));else throw new Error(_0x137251('0x1d'));}})[_0x23592c('0x79')](function(_0x30b00a){const _0x7d02fd=_0x23592c;if(_0x30b00a){let _0xb4261f={'UserId':_0x281675['user']['id'],'ContactId':_0x30b00a['id'],'MailAccountId':_0x20e33b['id'],'inReplyTo':_0x1dd779[_0x7d02fd('0xad')],'to':_0x281675['body'][_0x7d02fd('0xc')],'cc':_0x281675['body']['cc'],'subject':_0x281675[_0x7d02fd('0x39')][_0x7d02fd('0xab')],'attach':_0x281675[_0x7d02fd('0x39')][_0x7d02fd('0x1c')],'firstMsgDirection':'out','lastMsgAt':moment()[_0x7d02fd('0x8a')](_0x7d02fd('0x22')),'lastMsgDirection':_0x7d02fd('0x1'),'lastMsgBody':_0x281675[_0x7d02fd('0x39')][_0x7d02fd('0x39')],'Messages':[_[_0x7d02fd('0x41')](_0x281675[_0x7d02fd('0x39')],{'messageId':_0x1dd779[_0x7d02fd('0xad')],'sentAt':moment()[_0x7d02fd('0x8a')](_0x7d02fd('0x22')),'read':!![],'MailAccountId':_0x20e33b['id'],'UserId':_0x281675[_0x7d02fd('0xe')]['id'],'ContactId':_0x30b00a['id']})]};return _0x281675['body'][_0x7d02fd('0x51')]&&(_0xb4261f=_[_0x7d02fd('0x41')](_0xb4261f,_0x281675['body']['Interaction'])),db['MailInteraction'][_0x7d02fd('0xa9')](_0xb4261f,{'include':[{'model':db[_0x7d02fd('0x50')],'as':_0x7d02fd('0x4d')}]});}})['then'](respondWithResult(_0x46c6c4,null))[_0x23592c('0x26')](handleError(_0x46c6c4,null));},exports[_0x59b80f('0x30')]=function(_0x385955,_0x20d67e){const _0xa764b8=_0x59b80f;return db['MailAccount'][_0xa764b8('0x99')]({'where':{'id':_0x385955['params']['id']},'include':[{'model':db[_0xa764b8('0x5f')],'as':_0xa764b8('0x44'),'raw':!![]}]})[_0xa764b8('0x79')](handleEntityNotFound(_0x20d67e,null))['then'](function(_0x5a6bff){const _0x4d425e=_0xa764b8;if(_0x5a6bff&&_0x5a6bff[_0x4d425e('0x44')]){const _0x283d9b={'id':_0x5a6bff['id'],'tls':{'rejectUnauthorized':![]}};return _0x5a6bff[_0x4d425e('0x44')]['service']?_0x283d9b[_0x4d425e('0x98')]=_0x5a6bff[_0x4d425e('0x44')][_0x4d425e('0x98')]:(_0x283d9b[_0x4d425e('0x15')]=_0x5a6bff[_0x4d425e('0x44')]['host'],_0x283d9b[_0x4d425e('0x1e')]=_0x5a6bff[_0x4d425e('0x44')][_0x4d425e('0x1e')],_0x283d9b[_0x4d425e('0x72')]=_0x5a6bff[_0x4d425e('0x44')][_0x4d425e('0x72')]),_0x5a6bff['Smtp'][_0x4d425e('0x2')]&&(_0x283d9b[_0x4d425e('0x7f')]={'user':_0x5a6bff[_0x4d425e('0x44')][_0x4d425e('0xe')],'pass':_0x5a6bff[_0x4d425e('0x44')][_0x4d425e('0x6e')]}),respondWithRpcPromise(_0x4d425e('0x6b'),_0x4d425e('0x30'),{'account':_0x283d9b});}})[_0xa764b8('0x79')](respondWithResult(_0x20d67e,null))['catch'](handleError(_0x20d67e,null));},exports[_0x59b80f('0x96')]=function(_0x76d269,_0x2e2eab){const _0x4b3fc3=_0x59b80f;return db['MailAccount']['findOne']({'where':{'id':_0x76d269[_0x4b3fc3('0x9c')]['id']}})[_0x4b3fc3('0x79')](handleEntityNotFound(_0x2e2eab,null))[_0x4b3fc3('0x79')](function(_0x15b675){const _0x5be591=_0x4b3fc3;if(_0x15b675&&_0x15b675[_0x5be591('0x98')])throw new ValidationError(_0x5be591('0x94'));return _0x15b675;})['then'](removeEntity(_0x2e2eab,null))[_0x4b3fc3('0x26')](handleError(_0x2e2eab,null));},exports[_0x59b80f('0x18')]=function(_0x57ea56,_0x59a8a6){const _0x4e518d=_0x59b80f;return db[_0x4e518d('0x3d')][_0x4e518d('0x99')]({'where':{'id':_0x57ea56[_0x4e518d('0x9c')]['id']}})[_0x4e518d('0x79')](function(_0x16f5e9){const _0x2f5f75=_0x4e518d;if(_0x16f5e9)return _0x16f5e9[_0x2f5f75('0x18')](_0x57ea56[_0x2f5f75('0x39')]['ids'],{'through':_['omit'](_0x57ea56[_0x2f5f75('0x39')],[_0x2f5f75('0x0'),'id'])})['then'](function(_0x1159f7){const _0x16bc80=_0x2f5f75;for(let _0x1eb6c6=0x0;_0x1eb6c6<_0x57ea56[_0x16bc80('0x39')]['ids'][_0x16bc80('0x5b')];_0x1eb6c6+=0x1){socket[_0x16bc80('0x62')](_0x16bc80('0x29'),{'UserId':_0x57ea56[_0x16bc80('0x39')]['ids'][_0x1eb6c6],'MailAccountId':_0x57ea56[_0x16bc80('0x9c')]['id']});}return _0x1159f7;});})[_0x4e518d('0x79')](respondWithResult(_0x59a8a6,null))[_0x4e518d('0x26')](handleError(_0x59a8a6,null));},exports['removeAgents']=function(_0x1c82d5,_0x271af4){const _0x4e3945=_0x59b80f;return db[_0x4e3945('0x3d')][_0x4e3945('0x99')]({'where':{'id':_0x1c82d5['params']['id']}})['then'](handleEntityNotFound(_0x271af4,null))[_0x4e3945('0x79')](function(_0xc1b53e){const _0x974648=_0x4e3945;if(_0xc1b53e)return _0xc1b53e[_0x974648('0x36')](_0x1c82d5[_0x974648('0x28')]['ids'])[_0x974648('0x79')](function(){const _0xddffb3=_0x974648;if(_['isArray'](_0x1c82d5[_0xddffb3('0x28')][_0xddffb3('0x0')]))for(let _0x343d20=0x0;_0x343d20<_0x1c82d5['query']['ids'][_0xddffb3('0x5b')];_0x343d20+=0x1){socket[_0xddffb3('0x62')](_0xddffb3('0x78'),{'UserId':Number(_0x1c82d5[_0xddffb3('0x28')][_0xddffb3('0x0')][_0x343d20]),'MailAccountId':Number(_0x1c82d5[_0xddffb3('0x9c')]['id'])});}else socket['emit'](_0xddffb3('0x78'),{'UserId':Number(_0x1c82d5[_0xddffb3('0x28')][_0xddffb3('0x0')]),'MailAccountId':Number(_0x1c82d5[_0xddffb3('0x9c')]['id'])});});})[_0x4e3945('0x79')](respondWithStatusCode(_0x271af4,null))[_0x4e3945('0x26')](handleError(_0x271af4,null));},exports[_0x59b80f('0x5d')]=function(_0x48ec69,_0x3136bc){const _0x30a16c=_0x59b80f;let _0x930bd0={};const _0x8f09da={};let _0x5da27e,_0x1688c2;return db['MailAccount'][_0x30a16c('0x99')]({'where':{'id':_0x48ec69['params']['id']}})[_0x30a16c('0x79')](handleEntityNotFound(_0x3136bc,null))[_0x30a16c('0x79')](function(_0x9aa0cb){const _0x55801c=_0x30a16c;if(_0x9aa0cb)return _0x5da27e=_0x9aa0cb,_0x8f09da[_0x55801c('0x4c')]=_[_0x55801c('0x6a')](db['User'][_0x55801c('0x2b')]),_0x8f09da[_0x55801c('0x28')]=_['keys'](_0x48ec69['query']),_0x8f09da[_0x55801c('0x64')]=_[_0x55801c('0xac')](_0x8f09da[_0x55801c('0x4c')],_0x8f09da[_0x55801c('0x28')]),_0x930bd0['attributes']=_[_0x55801c('0xac')](_0x8f09da[_0x55801c('0x4c')],qs[_0x55801c('0xa6')](_0x48ec69[_0x55801c('0x28')][_0x55801c('0xa6')])),_0x930bd0[_0x55801c('0x10')]=_0x930bd0[_0x55801c('0x10')][_0x55801c('0x5b')]?_0x930bd0[_0x55801c('0x10')]:_0x8f09da[_0x55801c('0x4c')],_0x930bd0[_0x55801c('0x8d')]=qs[_0x55801c('0xa0')](_0x48ec69[_0x55801c('0x28')][_0x55801c('0xa0')]),_0x930bd0[_0x55801c('0x3e')]=qs[_0x55801c('0x64')](_[_0x55801c('0x53')](_0x48ec69[_0x55801c('0x28')],_0x8f09da[_0x55801c('0x64')])),_0x48ec69[_0x55801c('0x28')][_0x55801c('0x27')]&&(_0x930bd0[_0x55801c('0x3e')]=_['merge'](_0x930bd0[_0x55801c('0x3e')],{[Op['or']]:_[_0x55801c('0x4b')](_0x930bd0[_0x55801c('0x10')],function(_0x4e8dfd){const _0x246774=_0x55801c,_0x54ee7b={};return _0x54ee7b[_0x4e8dfd]={[Op[_0x246774('0x7d')]]:'%'+_0x48ec69[_0x246774('0x28')]['filter']+'%'},_0x54ee7b;})})),_0x930bd0=_[_0x55801c('0x41')]({},_0x930bd0,_0x48ec69[_0x55801c('0x5a')]),_0x5da27e['getAgents'](_0x930bd0);})['then'](function(_0xe66266){const _0x3dd067=_0x30a16c;if(_0xe66266)return _0x1688c2=_0xe66266[_0x3dd067('0x5b')],typeof _0x48ec69[_0x3dd067('0x28')][_0x3dd067('0x88')]===_0x3dd067('0x3')&&(_0x930bd0[_0x3dd067('0x33')]=qs[_0x3dd067('0x33')](_0x48ec69[_0x3dd067('0x28')]['limit']),_0x930bd0[_0x3dd067('0x91')]=qs['offset'](_0x48ec69[_0x3dd067('0x28')]['offset'])),_0x5da27e[_0x3dd067('0x5d')](_0x930bd0);})[_0x30a16c('0x79')](function(_0x5b5dc2){if(_0x5b5dc2)return _0x5b5dc2?{'count':_0x1688c2,'rows':_0x5b5dc2}:null;})[_0x30a16c('0x79')](respondWithResult(_0x3136bc,null))[_0x30a16c('0x26')](handleError(_0x3136bc,null));}; \ No newline at end of file +const a394_0xc5a4=['error','catch','removeDispositions','client','findOne','status','updatedAt','Smtp','set','cauthentication','addImap','removeSmtp','CmList','addInteraction','Tag','update','sendMail','like','cpassword','addApplications','cuser','get','mandatoryDispositionPause','merge','color','join','body','name','keys','autoAssociation','undefined','result','isNil','sequelize','service','UserProfileResource','./mailAccount.socket','rawAttributes','getMessages','../../rediscache','attributes','api','json','options','format','getSmtp','params','UserProfileSection','List','VerifySmtp','moment','MailInteraction','where','map','Contacts','pick','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','util','user','describe','count','destroy','Interaction','register','CmContact','MailApplication','send','bulkCreate','You\x20can\x27t\x20remove\x20the\x20mail\x20service\x20account','auth','Tags','info','password','removeAnswers','ids','getAgents','show','key','verifySmtp','nolimit','active','subject','addAgents','intersection','authentication','index','gte','removeAgents','emit','includeAll','%s\x20<%s>','offset','pass','cservice','DESC','addSmtp','include','priority','tag','userProfileId','getDispositions','sort','fieldName','Disposition','defaults','then','MailServerIn','from','Contact','../../config/environment','SendMail','email','getApplications','CannedAnswer','ListId','filters','findAll','secure','request\x20sent','transaction','userMailAccount:remove','$gte','getImap','MailAccounts','code','../../config/logger','../../mysqldb','stringify','host','MailAccount','Imap','MailServerOut','MailMessage','Unable\x20to\x20retrieve\x20the\x20current\x20user','attachments','model','port','omit','List\x20not\x20found','fields','request','message','create','sendStatus','lodash','out','order','setImap','Owner','length','MailAccount,\x20%s,\x20%s,\x20%s','type','server/files/attachments','removeImap','rows','query','MailAccount,\x20%s,\x20%s','end','attach','YYYY-MM-DD\x20HH:mm:ss','split','MailAccountId','limit','path','Pause','description','filter'];(function(_0x30a1a4,_0xc5a42e){const _0x5e95e2=function(_0x110809){while(--_0x110809){_0x30a1a4['push'](_0x30a1a4['shift']());}};_0x5e95e2(++_0xc5a42e);}(a394_0xc5a4,0x174));const a394_0x5e95=function(_0x30a1a4,_0xc5a42e){_0x30a1a4=_0x30a1a4-0x0;let _0x5e95e2=a394_0xc5a4[_0x30a1a4];return _0x5e95e2;};const _0x479f12=a394_0x5e95;'use strict';const moment=require(_0x479f12('0xc')),util=require(_0x479f12('0x13')),path=require(_0x479f12('0x7d')),_=require(_0x479f12('0x6a')),{getSocket}=require(_0x479f12('0x1')),socket=getSocket(),qs=require('../../components/parsers/qs'),logger=require(_0x479f12('0x57'))(_0x479f12('0x3')),config=require(_0x479f12('0x47')),db=require(_0x479f12('0x58'))['db'],{Op,ValidationError}=require('sequelize');require(_0x479f12('0xa5'))[_0x479f12('0x19')](socket);const jayson=require('jayson/promise'),client=jayson[_0x479f12('0x84')]['http']({'port':0x232b});function respondWithRpcPromise(_0x110809,_0x467fc7,_0x114557,_0x5e71c7){return new Promise(function(_0x405d8a,_0xe1bc47){const _0x49f166=a394_0x5e95,_0x28a17c=_0x5e71c7||client;return _0x28a17c[_0x49f166('0x66')](_0x110809,_0x114557)['then'](function(_0x5d3b30){const _0x339b99=_0x49f166;logger[_0x339b99('0x21')](_0x339b99('0x76'),_0x467fc7,'request\x20sent'),logger['debug'](_0x339b99('0x70'),_0x467fc7,_0x339b99('0x50'),JSON[_0x339b99('0x59')](_0x5d3b30));if(_0x5d3b30['error']){if(_0x5d3b30[_0x339b99('0x81')][_0x339b99('0x56')]===0x1f4)return logger[_0x339b99('0x81')]('MailAccount,\x20%s,\x20%s',_0x467fc7,_0x5d3b30[_0x339b99('0x81')][_0x339b99('0x67')]),_0xe1bc47(_0x5d3b30[_0x339b99('0x81')][_0x339b99('0x67')]);return logger[_0x339b99('0x81')](_0x339b99('0x76'),_0x467fc7,_0x5d3b30[_0x339b99('0x81')]['message']),_0x405d8a(_0x5d3b30['error'][_0x339b99('0x67')]);}else logger[_0x339b99('0x21')](_0x339b99('0x76'),_0x467fc7,_0x339b99('0x50')),_0x405d8a(_0x5d3b30[_0x339b99('0xa0')]['message']);})[_0x49f166('0x82')](function(_0x28fe4a){const _0xc0257c=_0x49f166;logger['error'](_0xc0257c('0x76'),_0x467fc7,_0x28fe4a),_0xe1bc47(_0x28fe4a);});});}function respondWithStatusCode(_0x4265b2,_0x192866){return _0x192866=_0x192866||0xcc,function(_0x13c786){const _0x2cb065=a394_0x5e95;if(_0x13c786)return _0x4265b2['sendStatus'](_0x192866);return _0x4265b2[_0x2cb065('0x86')](_0x192866)[_0x2cb065('0x77')]();};}function respondWithResult(_0x2225b2,_0x6f17a3){return _0x6f17a3=_0x6f17a3||0xc8,function(_0x1fd8bf){const _0x201854=a394_0x5e95;if(_0x1fd8bf)return _0x2225b2[_0x201854('0x86')](_0x6f17a3)[_0x201854('0x4')](_0x1fd8bf);};}function respondWithFilteredResult(_0x304091,_0x45e76b){return function(_0x3243cc){const _0x6641ae=a394_0x5e95;if(_0x3243cc){const _0x5e4574=_0x3243cc[_0x6641ae('0x16')],_0x1c988e=_0x45e76b['offset'];let _0x2cc478=_0x45e76b[_0x6641ae('0x35')]+_0x45e76b['limit'],_0x4e8633;return _0x2cc478>=_0x5e4574?(_0x2cc478=_0x5e4574,_0x4e8633=0xc8):_0x4e8633=0xce,_0x304091[_0x6641ae('0x86')](_0x4e8633),_0x304091[_0x6641ae('0x89')]('Content-Range',_0x1c988e+'-'+_0x2cc478+'/'+_0x5e4574)[_0x6641ae('0x4')](_0x3243cc);}return null;};}function saveUpdates(_0x1856d6){return function(_0x5dd67c){const _0x2eb870=a394_0x5e95;if(_0x5dd67c)return _0x5dd67c[_0x2eb870('0x90')](_0x1856d6)[_0x2eb870('0x43')](function(_0x7bffd2){return _0x7bffd2;});return null;};}function removeEntity(_0x5354f4){return function(_0x359a64){const _0x738c6c=a394_0x5e95;if(_0x359a64)return _0x359a64[_0x738c6c('0x17')]()['then'](function(){const _0x4cbe4d=_0x738c6c,_0x491406=_0x359a64[_0x4cbe4d('0x96')]({'plain':!![]}),_0x42701d=_0x4cbe4d('0x55');return db[_0x4cbe4d('0xa4')][_0x4cbe4d('0x17')]({'where':{'type':_0x42701d,'resourceId':_0x491406['id']}})[_0x4cbe4d('0x43')](function(){return _0x359a64;});})[_0x738c6c('0x43')](function(){_0x5354f4['status'](0xcc)['end']();});};}function handleEntityNotFound(_0xfb6ab1){return function(_0x1ed28f){const _0x58c6bb=a394_0x5e95;return!_0x1ed28f&&_0xfb6ab1[_0x58c6bb('0x69')](0x194),_0x1ed28f;};}function handleError(_0x531bd2,_0x297930){return _0x297930=_0x297930||0x1f4,function(_0x3dde3e){const _0x41d7c5=a394_0x5e95;logger[_0x41d7c5('0x81')](_0x3dde3e['stack']),_0x3dde3e[_0x41d7c5('0x9c')]&&delete _0x3dde3e['name'],_0x531bd2[_0x41d7c5('0x86')](_0x297930)[_0x41d7c5('0x1c')](_0x3dde3e);};}exports[_0x479f12('0x2f')]=function(_0x4d096f,_0x2ff8a6){const _0x34d784=_0x479f12;let _0x256804={'include':[{'model':db[_0x34d784('0x44')],'as':_0x34d784('0x5c')},{'model':db[_0x34d784('0x5d')],'as':'Smtp'},{'model':db[_0x34d784('0x7e')],'as':_0x34d784('0x97')}]};const _0x2ed55c={},_0x20f74a={'count':0x0,'rows':[]},_0x58ce31=_[_0x34d784('0xf')](db['MailAccount'][_0x34d784('0xa6')],function(_0x23fd28){const _0x2e096c=_0x34d784;return{'name':_0x23fd28[_0x2e096c('0x40')],'type':_0x23fd28['type'][_0x2e096c('0x27')]};});_0x2ed55c[_0x34d784('0x61')]=_[_0x34d784('0xf')](_0x58ce31,_0x34d784('0x9c')),_0x2ed55c['query']=_[_0x34d784('0x9d')](_0x4d096f[_0x34d784('0x75')]),_0x2ed55c['filters']=_[_0x34d784('0x2d')](_0x2ed55c[_0x34d784('0x61')],_0x2ed55c[_0x34d784('0x75')]),_0x256804['attributes']=_[_0x34d784('0x2d')](_0x2ed55c['model'],qs[_0x34d784('0x65')](_0x4d096f['query'][_0x34d784('0x65')])),_0x256804[_0x34d784('0x2')]=_0x256804[_0x34d784('0x2')]['length']?_0x256804[_0x34d784('0x2')]:_0x2ed55c[_0x34d784('0x61')];typeof _0x4d096f[_0x34d784('0x75')]['nolimit']==='undefined'&&(_0x256804[_0x34d784('0x7c')]=qs[_0x34d784('0x7c')](_0x4d096f['query'][_0x34d784('0x7c')]),_0x256804[_0x34d784('0x35')]=qs[_0x34d784('0x35')](_0x4d096f['query'][_0x34d784('0x35')]));_0x256804[_0x34d784('0x6c')]=qs[_0x34d784('0x3f')](_0x4d096f[_0x34d784('0x75')][_0x34d784('0x3f')]),_0x256804['where']=qs[_0x34d784('0x4d')](_[_0x34d784('0x11')](_0x4d096f['query'],_0x2ed55c[_0x34d784('0x4d')]),_0x58ce31);_0x4d096f[_0x34d784('0x75')][_0x34d784('0x80')]&&(_0x256804[_0x34d784('0xe')]=_[_0x34d784('0x98')](_0x256804[_0x34d784('0xe')],{[Op['or']]:_[_0x34d784('0xf')](_0x58ce31,function(_0x560533){const _0x11f4e6=_0x34d784;if(_0x560533[_0x11f4e6('0x71')]!=='VIRTUAL'){const _0xf9faa={};return _0xf9faa[_0x560533[_0x11f4e6('0x9c')]]={[Op[_0x11f4e6('0x92')]]:'%'+_0x4d096f['query'][_0x11f4e6('0x80')]+'%'},_0xf9faa;}})}));_0x256804=_[_0x34d784('0x98')]({},_0x256804,_0x4d096f[_0x34d784('0x5')]);const _0x377489={'where':_0x256804[_0x34d784('0xe')]};return db[_0x34d784('0x5b')]['count'](_0x377489)[_0x34d784('0x43')](function(_0x3bec4b){const _0x55e305=_0x34d784;return _0x20f74a[_0x55e305('0x16')]=_0x3bec4b,_0x4d096f[_0x55e305('0x75')][_0x55e305('0x33')]&&(_0x256804[_0x55e305('0x3a')]=[{'all':!![]}]),db[_0x55e305('0x5b')]['findAll'](_0x256804);})[_0x34d784('0x43')](function(_0x5f33eb){const _0x448747=_0x34d784;return _0x20f74a[_0x448747('0x74')]=_0x5f33eb,_0x20f74a;})[_0x34d784('0x43')](respondWithFilteredResult(_0x2ff8a6,_0x256804))[_0x34d784('0x82')](handleError(_0x2ff8a6,null));},exports[_0x479f12('0x26')]=function(_0x46172a,_0x1ae48a){const _0xf597e=_0x479f12;let _0x358d87={'raw':![],'where':{'id':_0x46172a[_0xf597e('0x8')]['id']},'include':[{'model':db[_0xf597e('0x44')],'as':_0xf597e('0x5c')},{'model':db[_0xf597e('0x5d')],'as':_0xf597e('0x88')},{'model':db[_0xf597e('0x7e')],'as':_0xf597e('0x97')}]};const _0x2c7ddf={};return _0x2c7ddf['model']=_['keys'](db['MailAccount'][_0xf597e('0xa6')]),_0x2c7ddf[_0xf597e('0x75')]=_[_0xf597e('0x9d')](_0x46172a[_0xf597e('0x75')]),_0x2c7ddf[_0xf597e('0x4d')]=_[_0xf597e('0x2d')](_0x2c7ddf[_0xf597e('0x61')],_0x2c7ddf['query']),_0x358d87[_0xf597e('0x2')]=_['intersection'](_0x2c7ddf[_0xf597e('0x61')],qs['fields'](_0x46172a[_0xf597e('0x75')][_0xf597e('0x65')])),_0x358d87[_0xf597e('0x2')]=_0x358d87[_0xf597e('0x2')][_0xf597e('0x6f')]?_0x358d87['attributes']:_0x2c7ddf[_0xf597e('0x61')],_0x46172a[_0xf597e('0x75')][_0xf597e('0x33')]&&(_0x358d87[_0xf597e('0x3a')]=[{'all':!![]}]),_0x358d87=_['merge']({},_0x358d87,_0x46172a[_0xf597e('0x5')]),db['MailAccount']['findOne'](_0x358d87)[_0xf597e('0x43')](handleEntityNotFound(_0x1ae48a,null))['then'](respondWithResult(_0x1ae48a,null))[_0xf597e('0x82')](handleError(_0x1ae48a,null));},exports[_0x479f12('0x90')]=function(_0x519099,_0x2216a9){const _0x2a75d9=_0x479f12;return _0x519099[_0x2a75d9('0x9b')]['id']&&delete _0x519099['body']['id'],db[_0x2a75d9('0x5b')]['findOne']({'where':{'id':_0x519099[_0x2a75d9('0x8')]['id']},'include':[{'model':db[_0x2a75d9('0x44')],'as':_0x2a75d9('0x5c')},{'model':db['MailServerOut'],'as':_0x2a75d9('0x88')},{'model':db[_0x2a75d9('0x7e')],'as':_0x2a75d9('0x97')}]})['then'](handleEntityNotFound(_0x2216a9,null))[_0x2a75d9('0x43')](saveUpdates(_0x519099[_0x2a75d9('0x9b')],null))[_0x2a75d9('0x43')](function(_0x414816){const _0x2c0b15=_0x2a75d9;if(_0x414816&&_0x519099['body']['Imap'])return db[_0x2c0b15('0x44')][_0x2c0b15('0x90')](_0x519099[_0x2c0b15('0x9b')][_0x2c0b15('0x5c')],{'where':{'MailAccountId':_0x414816['id']}})[_0x2c0b15('0x43')](function(){return _0x414816;});return _0x414816;})[_0x2a75d9('0x43')](function(_0xf98826){const _0x4085d6=_0x2a75d9;if(_0xf98826&&_0x519099[_0x4085d6('0x9b')][_0x4085d6('0x88')])return db[_0x4085d6('0x5d')]['update'](_0x519099[_0x4085d6('0x9b')][_0x4085d6('0x88')],{'where':{'MailAccountId':_0xf98826['id']}})[_0x4085d6('0x43')](function(){return _0xf98826;});return _0xf98826;})[_0x2a75d9('0x43')](respondWithResult(_0x2216a9,null))[_0x2a75d9('0x82')](handleError(_0x2216a9,null));},exports['describe']=function(_0x10780a,_0x4df480){const _0x51d6f4=_0x479f12;return db[_0x51d6f4('0x5b')][_0x51d6f4('0x15')]()['then'](respondWithResult(_0x4df480,null))[_0x51d6f4('0x82')](handleError(_0x4df480,null));},exports['addDisposition']=function(_0x3a3078,_0x2934d2){const _0x3da718=_0x479f12;return _0x3a3078[_0x3da718('0x9b')]['id']&&delete _0x3a3078[_0x3da718('0x9b')]['id'],db[_0x3da718('0x5b')]['findOne']({'where':{'id':_0x3a3078[_0x3da718('0x8')]['id']}})[_0x3da718('0x43')](handleEntityNotFound(_0x2934d2,null))[_0x3da718('0x43')](function(_0x1ebefd){const _0x2a214c=_0x3da718;if(_0x1ebefd)return _0x3a3078['body']['MailAccountId']=_0x1ebefd['id'],db[_0x2a214c('0x41')][_0x2a214c('0x68')](_0x3a3078[_0x2a214c('0x9b')]);})[_0x3da718('0x43')](respondWithResult(_0x2934d2,null))[_0x3da718('0x82')](handleError(_0x2934d2,null));},exports[_0x479f12('0x3e')]=function(_0x124fec,_0x40866f){const _0x36fa7c=_0x479f12;let _0xcb8f04={'raw':![],'where':{}};const _0x477876={},_0x5666f2={'count':0x0,'rows':[]};return db[_0x36fa7c('0x5b')]['findOne']({'where':{'id':_0x124fec['params']['id']}})[_0x36fa7c('0x43')](handleEntityNotFound(_0x40866f,null))[_0x36fa7c('0x43')](function(_0x3de9aa){const _0x375744=_0x36fa7c;if(_0x3de9aa)return _0x477876[_0x375744('0x61')]=_['keys'](db['Disposition']['rawAttributes']),_0x477876[_0x375744('0x75')]=_['keys'](_0x124fec['query']),_0x477876[_0x375744('0x4d')]=_[_0x375744('0x2d')](_0x477876[_0x375744('0x61')],_0x477876[_0x375744('0x75')]),_0xcb8f04['attributes']=_[_0x375744('0x2d')](_0x477876[_0x375744('0x61')],qs[_0x375744('0x65')](_0x124fec['query'][_0x375744('0x65')])),_0xcb8f04['attributes']=_0xcb8f04[_0x375744('0x2')]['length']?_0xcb8f04[_0x375744('0x2')]:_0x477876['model'],typeof _0x124fec['query'][_0x375744('0x29')]===_0x375744('0x9f')&&(_0xcb8f04[_0x375744('0x7c')]=qs[_0x375744('0x7c')](_0x124fec[_0x375744('0x75')][_0x375744('0x7c')]),_0xcb8f04[_0x375744('0x35')]=qs[_0x375744('0x35')](_0x124fec[_0x375744('0x75')][_0x375744('0x35')])),_0xcb8f04['order']=qs[_0x375744('0x3f')](_0x124fec[_0x375744('0x75')]['sort']),_0xcb8f04['where']=qs[_0x375744('0x4d')](_[_0x375744('0x11')](_0x124fec[_0x375744('0x75')],_0x477876[_0x375744('0x4d')])),_0xcb8f04[_0x375744('0xe')][_0x375744('0x7b')]=_0x3de9aa['id'],_0x124fec[_0x375744('0x75')]['filter']&&(_0xcb8f04[_0x375744('0xe')]=_[_0x375744('0x98')](_0xcb8f04[_0x375744('0xe')],{[Op['or']]:_[_0x375744('0xf')](_0xcb8f04['attributes'],function(_0x4698c0){const _0x2f94e6=_0x375744,_0x584959={};return _0x584959[_0x4698c0]={[Op[_0x2f94e6('0x92')]]:'%'+_0x124fec['query'][_0x2f94e6('0x80')]+'%'},_0x584959;})})),_0xcb8f04=_['merge']({},_0xcb8f04,_0x124fec['options']),db[_0x375744('0x41')]['count']({'where':_0xcb8f04['where']})[_0x375744('0x43')](function(_0x5a7d02){const _0x812c47=_0x375744;return _0x5666f2[_0x812c47('0x16')]=_0x5a7d02,_0x124fec['query'][_0x812c47('0x33')]&&(_0xcb8f04[_0x812c47('0x3a')]=[{'all':!![]}]),db['Disposition'][_0x812c47('0x4e')](_0xcb8f04);})['then'](function(_0x4e3f63){const _0x394425=_0x375744;return _0x5666f2[_0x394425('0x74')]=_0x4e3f63,_0x5666f2;});})[_0x36fa7c('0x43')](respondWithFilteredResult(_0x40866f,_0xcb8f04))[_0x36fa7c('0x82')](handleError(_0x40866f,null));},exports[_0x479f12('0x83')]=function(_0x3bfcca,_0x1fae72){const _0x13541b=_0x479f12;return db[_0x13541b('0x5b')][_0x13541b('0x85')]({'where':{'id':_0x3bfcca['params']['id']}})['then'](handleEntityNotFound(_0x1fae72,null))[_0x13541b('0x43')](function(_0x78869e){const _0x14ec73=_0x13541b;if(_0x78869e)return _0x78869e[_0x14ec73('0x83')](_0x3bfcca['query']['ids']);})[_0x13541b('0x43')](respondWithStatusCode(_0x1fae72,null))[_0x13541b('0x82')](handleError(_0x1fae72,null));},exports['addAnswer']=function(_0x27ec87,_0xbe7070){const _0x180e68=_0x479f12;return _0x27ec87[_0x180e68('0x9b')]['id']&&delete _0x27ec87[_0x180e68('0x9b')]['id'],db[_0x180e68('0x5b')][_0x180e68('0x85')]({'where':{'id':_0x27ec87['params']['id']}})[_0x180e68('0x43')](handleEntityNotFound(_0xbe7070,null))['then'](function(_0x14a1b0){const _0xe5dd2f=_0x180e68;if(_0x14a1b0)return _0x27ec87[_0xe5dd2f('0x9b')][_0xe5dd2f('0x7b')]=_0x14a1b0['id'],db[_0xe5dd2f('0x4b')][_0xe5dd2f('0x68')](_0x27ec87[_0xe5dd2f('0x9b')]);})[_0x180e68('0x43')](respondWithResult(_0xbe7070,null))['catch'](handleError(_0xbe7070,null));},exports['getAnswers']=function(_0x206a44,_0x128e1f){const _0xfc9358=_0x479f12;let _0x23dc8c={'raw':![],'where':{}};const _0x2d7884={},_0x470c8b={'count':0x0,'rows':[]};return db[_0xfc9358('0x5b')][_0xfc9358('0x85')]({'where':{'id':_0x206a44['params']['id']}})[_0xfc9358('0x43')](handleEntityNotFound(_0x128e1f,null))[_0xfc9358('0x43')](function(_0x3e6c66){const _0x5a34d2=_0xfc9358;if(_0x3e6c66)return _0x2d7884[_0x5a34d2('0x61')]=_['keys'](db[_0x5a34d2('0x4b')][_0x5a34d2('0xa6')]),_0x2d7884[_0x5a34d2('0x75')]=_[_0x5a34d2('0x9d')](_0x206a44['query']),_0x2d7884[_0x5a34d2('0x4d')]=_[_0x5a34d2('0x2d')](_0x2d7884['model'],_0x2d7884[_0x5a34d2('0x75')]),_0x23dc8c['attributes']=_[_0x5a34d2('0x2d')](_0x2d7884[_0x5a34d2('0x61')],qs[_0x5a34d2('0x65')](_0x206a44[_0x5a34d2('0x75')][_0x5a34d2('0x65')])),_0x23dc8c[_0x5a34d2('0x2')]=_0x23dc8c[_0x5a34d2('0x2')]['length']?_0x23dc8c[_0x5a34d2('0x2')]:_0x2d7884[_0x5a34d2('0x61')],typeof _0x206a44[_0x5a34d2('0x75')][_0x5a34d2('0x29')]===_0x5a34d2('0x9f')&&(_0x23dc8c[_0x5a34d2('0x7c')]=qs[_0x5a34d2('0x7c')](_0x206a44[_0x5a34d2('0x75')][_0x5a34d2('0x7c')]),_0x23dc8c[_0x5a34d2('0x35')]=qs['offset'](_0x206a44[_0x5a34d2('0x75')][_0x5a34d2('0x35')])),_0x23dc8c[_0x5a34d2('0x6c')]=qs[_0x5a34d2('0x3f')](_0x206a44[_0x5a34d2('0x75')]['sort']),_0x23dc8c['where']=qs[_0x5a34d2('0x4d')](_[_0x5a34d2('0x11')](_0x206a44[_0x5a34d2('0x75')],_0x2d7884[_0x5a34d2('0x4d')])),_0x23dc8c[_0x5a34d2('0xe')][_0x5a34d2('0x7b')]=_0x3e6c66['id'],_0x206a44[_0x5a34d2('0x75')]['filter']&&(_0x23dc8c[_0x5a34d2('0xe')]=_[_0x5a34d2('0x98')](_0x23dc8c['where'],{[Op['or']]:_[_0x5a34d2('0xf')](_0x23dc8c[_0x5a34d2('0x2')],function(_0x3585a1){const _0x5c75e7=_0x5a34d2,_0x3e4ab1={};return _0x3e4ab1[_0x3585a1]={[Op[_0x5c75e7('0x92')]]:'%'+_0x206a44[_0x5c75e7('0x75')][_0x5c75e7('0x80')]+'%'},_0x3e4ab1;})})),_0x23dc8c=_[_0x5a34d2('0x98')]({},_0x23dc8c,_0x206a44[_0x5a34d2('0x5')]),db[_0x5a34d2('0x4b')]['count']({'where':_0x23dc8c[_0x5a34d2('0xe')]})['then'](function(_0x576e9b){const _0x42a5f0=_0x5a34d2;return _0x470c8b[_0x42a5f0('0x16')]=_0x576e9b,_0x206a44[_0x42a5f0('0x75')][_0x42a5f0('0x33')]&&(_0x23dc8c[_0x42a5f0('0x3a')]=[{'all':!![]}]),db['CannedAnswer']['findAll'](_0x23dc8c);})[_0x5a34d2('0x43')](function(_0x460f2d){const _0x5a81c3=_0x5a34d2;return _0x470c8b[_0x5a81c3('0x74')]=_0x460f2d,_0x470c8b;});})[_0xfc9358('0x43')](respondWithFilteredResult(_0x128e1f,_0x23dc8c))['catch'](handleError(_0x128e1f,null));},exports[_0x479f12('0x23')]=function(_0x3a4c66,_0x26d145){const _0x419690=_0x479f12;return db[_0x419690('0x5b')][_0x419690('0x85')]({'where':{'id':_0x3a4c66[_0x419690('0x8')]['id']}})[_0x419690('0x43')](handleEntityNotFound(_0x26d145,null))[_0x419690('0x43')](function(_0x381c5a){const _0x342459=_0x419690;if(_0x381c5a)return _0x381c5a[_0x342459('0x23')](_0x3a4c66[_0x342459('0x75')][_0x342459('0x24')]);})[_0x419690('0x43')](respondWithStatusCode(_0x26d145,null))[_0x419690('0x82')](handleError(_0x26d145,null));},exports[_0x479f12('0x68')]=function(_0x404369,_0x53c7aa){const _0x248e2c=_0x479f12,_0xfdbabb={'name':_0x404369['body'][_0x248e2c('0x9c')],'key':_0x404369['body'][_0x248e2c('0x27')],'email':_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x49')],'ListId':_0x404369[_0x248e2c('0x9b')]['ListId'],'active':!_[_0x248e2c('0xa1')](_0x404369['body']['active'])?_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x2a')]:!![],'description':_0x404369['body'][_0x248e2c('0x7f')]||null,'Imap':{},'Smtp':{}};return _[_0x248e2c('0xa1')](_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x37')])?(_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x8a')]?(_0xfdbabb[_0x248e2c('0x5c')][_0x248e2c('0x14')]=_0x404369['body']['cuser'],_0xfdbabb['Smtp']['user']=_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x95')],_0xfdbabb[_0x248e2c('0x5c')][_0x248e2c('0x22')]=_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x93')],_0xfdbabb['Smtp'][_0x248e2c('0x36')]=_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x93')]):(_0xfdbabb[_0x248e2c('0x5c')][_0x248e2c('0x2e')]=![],_0xfdbabb[_0x248e2c('0x88')]['authentication']=![]),_0xfdbabb[_0x248e2c('0x5c')][_0x248e2c('0x5a')]=_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x5c')]['host'],_0xfdbabb['Imap'][_0x248e2c('0x62')]=_0x404369['body'][_0x248e2c('0x5c')][_0x248e2c('0x62')],_0xfdbabb[_0x248e2c('0x88')][_0x248e2c('0x5a')]=_0x404369['body'][_0x248e2c('0x88')]['host'],_0xfdbabb[_0x248e2c('0x88')][_0x248e2c('0x62')]=_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x88')][_0x248e2c('0x62')]):(_0xfdbabb['Imap'][_0x248e2c('0xa3')]=_0x404369['body'][_0x248e2c('0x37')],_0xfdbabb[_0x248e2c('0x88')]['service']=_0x404369['body'][_0x248e2c('0x37')],_0xfdbabb['Imap']['user']=_0x404369[_0x248e2c('0x9b')]['cuser'],_0xfdbabb['Smtp']['user']=_0x404369[_0x248e2c('0x9b')]['cuser'],_0xfdbabb[_0x248e2c('0x5c')]['password']=_0x404369[_0x248e2c('0x9b')][_0x248e2c('0x93')],_0xfdbabb[_0x248e2c('0x88')][_0x248e2c('0x36')]=_0x404369['body'][_0x248e2c('0x93')]),db[_0x248e2c('0x5b')]['create'](_0xfdbabb,{'include':[{'model':db[_0x248e2c('0x5d')],'as':'Smtp'},{'model':db[_0x248e2c('0x44')],'as':_0x248e2c('0x5c')}]})[_0x248e2c('0x43')](function(_0x3b1d06){const _0x3472bd=_0x248e2c,_0x5d9745=_0x404369[_0x3472bd('0x14')][_0x3472bd('0x96')]({'plain':!![]});if(!_0x5d9745)throw new Error(_0x3472bd('0x5f'));if(_0x5d9745['role']===_0x3472bd('0x14')){const _0x3c4912=_0x3b1d06[_0x3472bd('0x96')]({'plain':!![]});return db[_0x3472bd('0x9')][_0x3472bd('0x85')]({'where':{'name':_0x3472bd('0x55'),'userProfileId':_0x5d9745[_0x3472bd('0x3d')]},'raw':!![]})['then'](function(_0x3f759a){const _0x3da000=_0x3472bd;return _0x3f759a&&_0x3f759a[_0x3da000('0x9e')]===0x0?db[_0x3da000('0xa4')][_0x3da000('0x68')]({'name':_0x3c4912['name'],'resourceId':_0x3c4912['id'],'type':_0x3f759a[_0x3da000('0x9c')],'sectionId':_0x3f759a['id']},{})['then'](function(){return _0x3b1d06;}):_0x3b1d06;})['catch'](function(_0x3e23ba){const _0x3b1051=_0x3472bd;logger[_0x3b1051('0x81')](_0x3b1051('0x12'),_0x3e23ba);throw _0x3e23ba;});}return _0x3b1d06;})['then'](respondWithResult(_0x53c7aa,0xc9))[_0x248e2c('0x82')](handleError(_0x53c7aa,null));},exports[_0x479f12('0x54')]=function(_0x41d50c,_0x82aa7b){const _0x4c6acc=_0x479f12;return db[_0x4c6acc('0x5b')]['findOne']({'where':{'id':_0x41d50c['params']['id']}})[_0x4c6acc('0x43')](handleEntityNotFound(_0x82aa7b,null))['then'](function(_0x238131){const _0x4b179d=_0x4c6acc;if(_0x238131)return _0x238131[_0x4b179d('0x54')]();return null;})[_0x4c6acc('0x43')](respondWithResult(_0x82aa7b,null))[_0x4c6acc('0x82')](handleError(_0x82aa7b,null));},exports[_0x479f12('0x8b')]=function(_0x1d6e88,_0x114e50){const _0x7017bc=_0x479f12;return _0x1d6e88[_0x7017bc('0x9b')]['id']&&delete _0x1d6e88[_0x7017bc('0x9b')]['id'],db[_0x7017bc('0x5b')]['findOne']({'where':{'id':_0x1d6e88[_0x7017bc('0x8')]['id']}})[_0x7017bc('0x43')](handleEntityNotFound(_0x114e50,null))[_0x7017bc('0x43')](function(_0x5e7418){const _0x397db3=_0x7017bc;if(_0x5e7418)return _0x1d6e88['body'][_0x397db3('0x7b')]=_0x5e7418['id'],db[_0x397db3('0x44')][_0x397db3('0x68')](_0x1d6e88[_0x397db3('0x9b')]);})[_0x7017bc('0x43')](respondWithResult(_0x114e50,null))[_0x7017bc('0x82')](handleError(_0x114e50,null));},exports[_0x479f12('0x73')]=function(_0x51a8ee,_0x583949){const _0x478af6=_0x479f12;return db['MailAccount']['findOne']({'where':{'id':_0x51a8ee['params']['id']}})[_0x478af6('0x43')](handleEntityNotFound(_0x583949,null))[_0x478af6('0x43')](function(_0x264a7f){const _0x572fa1=_0x478af6;if(_0x264a7f)return _0x264a7f[_0x572fa1('0x6d')](null);return null;})[_0x478af6('0x43')](respondWithStatusCode(_0x583949,null))[_0x478af6('0x82')](handleError(_0x583949,null));},exports[_0x479f12('0x7')]=function(_0x467b57,_0x124949){const _0x3b5c62=_0x479f12;return db[_0x3b5c62('0x5b')][_0x3b5c62('0x85')]({'where':{'id':_0x467b57[_0x3b5c62('0x8')]['id']}})[_0x3b5c62('0x43')](handleEntityNotFound(_0x124949,null))['then'](function(_0x53a1d8){const _0x4e5c08=_0x3b5c62;if(_0x53a1d8)return _0x53a1d8[_0x4e5c08('0x7')]();return null;})['then'](respondWithResult(_0x124949,null))[_0x3b5c62('0x82')](handleError(_0x124949,null));},exports[_0x479f12('0x39')]=function(_0xd39929,_0x25a621){const _0x113fb2=_0x479f12;return _0xd39929[_0x113fb2('0x9b')]['id']&&delete _0xd39929[_0x113fb2('0x9b')]['id'],db[_0x113fb2('0x5b')][_0x113fb2('0x85')]({'where':{'id':_0xd39929[_0x113fb2('0x8')]['id']}})[_0x113fb2('0x43')](handleEntityNotFound(_0x25a621,null))['then'](function(_0x485a4f){const _0x2f8eb0=_0x113fb2;if(_0x485a4f)return _0xd39929[_0x2f8eb0('0x9b')][_0x2f8eb0('0x7b')]=_0x485a4f['id'],db[_0x2f8eb0('0x5d')][_0x2f8eb0('0x68')](_0xd39929[_0x2f8eb0('0x9b')]);})[_0x113fb2('0x43')](respondWithResult(_0x25a621,null))[_0x113fb2('0x82')](handleError(_0x25a621,null));},exports[_0x479f12('0x8c')]=function(_0x32d78a,_0x586682){const _0x4029a=_0x479f12;return db[_0x4029a('0x5b')][_0x4029a('0x85')]({'where':{'id':_0x32d78a[_0x4029a('0x8')]['id']}})[_0x4029a('0x43')](handleEntityNotFound(_0x586682,null))[_0x4029a('0x43')](function(_0x50669e){if(_0x50669e)return _0x50669e['setSmtp'](null);return null;})['then'](respondWithStatusCode(_0x586682,null))[_0x4029a('0x82')](handleError(_0x586682,null));},exports[_0x479f12('0x8e')]=function(_0xf175a3,_0x27d2fc){const _0x27af40=_0x479f12;return db[_0x27af40('0xd')]['findOne']({'where':{'id':_0xf175a3[_0x27af40('0x8')]['id']}})[_0x27af40('0x43')](function(_0x349170){const _0x3b6bee=_0x27af40;if(_0x349170)return _0x349170[_0x3b6bee('0x8e')](_0xf175a3[_0x3b6bee('0x9b')][_0x3b6bee('0x24')],{'through':_['omit'](_0xf175a3['body'],[_0x3b6bee('0x24'),'id'])});})[_0x27af40('0x43')](respondWithResult(_0x27d2fc,null))[_0x27af40('0x82')](handleError(_0x27d2fc,null));},exports['getInteractions']=function(_0x4dbee2,_0x52ab72){const _0x7c677c=_0x479f12;let _0x217cdf={'raw':![],'where':{}};const _0x585504={},_0x27016f={'count':0x0,'rows':[]};return db[_0x7c677c('0x5b')]['findOne']({'where':{'id':_0x4dbee2[_0x7c677c('0x8')]['id']}})[_0x7c677c('0x43')](handleEntityNotFound(_0x52ab72,null))[_0x7c677c('0x43')](function(_0x281d9c){const _0x1fcbb9=_0x7c677c;if(_0x281d9c)return _0x585504[_0x1fcbb9('0x61')]=_['keys'](db[_0x1fcbb9('0xd')][_0x1fcbb9('0xa6')]),_0x585504[_0x1fcbb9('0x75')]=_[_0x1fcbb9('0x9d')](_0x4dbee2[_0x1fcbb9('0x75')]),_0x585504[_0x1fcbb9('0x4d')]=_[_0x1fcbb9('0x2d')](_0x585504['model'],_0x585504[_0x1fcbb9('0x75')]),_0x217cdf[_0x1fcbb9('0x2')]=_[_0x1fcbb9('0x2d')](_0x585504['model'],qs[_0x1fcbb9('0x65')](_0x4dbee2[_0x1fcbb9('0x75')][_0x1fcbb9('0x65')])),_0x217cdf[_0x1fcbb9('0x2')]=_0x217cdf[_0x1fcbb9('0x2')][_0x1fcbb9('0x6f')]?_0x217cdf[_0x1fcbb9('0x2')]:_0x585504[_0x1fcbb9('0x61')],typeof _0x4dbee2['query']['nolimit']===_0x1fcbb9('0x9f')&&(_0x217cdf['limit']=qs[_0x1fcbb9('0x7c')](_0x4dbee2[_0x1fcbb9('0x75')][_0x1fcbb9('0x7c')]),_0x217cdf[_0x1fcbb9('0x35')]=qs['offset'](_0x4dbee2['query'][_0x1fcbb9('0x35')])),_0x217cdf[_0x1fcbb9('0x6c')]=qs[_0x1fcbb9('0x3f')](_0x4dbee2[_0x1fcbb9('0x75')]['sort']),_0x217cdf[_0x1fcbb9('0xe')]=qs[_0x1fcbb9('0x4d')](_['pick'](_0x4dbee2[_0x1fcbb9('0x75')],_0x585504['filters'])),_0x217cdf['where'][_0x1fcbb9('0x7b')]=_0x281d9c['id'],_0x4dbee2[_0x1fcbb9('0x75')]['filter']&&(_0x217cdf[_0x1fcbb9('0xe')]=_[_0x1fcbb9('0x98')](_0x217cdf[_0x1fcbb9('0xe')],{[Op['or']]:_['map'](_0x217cdf['attributes'],function(_0x4b9ede){const _0x2b082b=_0x1fcbb9,_0x2d1c55={};return _0x2d1c55[_0x4b9ede]={[Op[_0x2b082b('0x92')]]:'%'+_0x4dbee2[_0x2b082b('0x75')][_0x2b082b('0x80')]+'%'},_0x2d1c55;})})),_0x217cdf=_['merge']({},_0x217cdf,_0x4dbee2[_0x1fcbb9('0x5')]),db[_0x1fcbb9('0xd')][_0x1fcbb9('0x16')]({'where':_0x217cdf['where']})['then'](function(_0xfd52a5){const _0xf40081=_0x1fcbb9;return _0x27016f[_0xf40081('0x16')]=_0xfd52a5,_0x4dbee2[_0xf40081('0x75')][_0xf40081('0x33')]&&(_0x217cdf[_0xf40081('0x3a')]=[{'model':db[_0xf40081('0x1a')],'as':_0xf40081('0x46'),'required':![]},{'model':db['User'],'as':_0xf40081('0x6e'),'attributes':[_0xf40081('0x9c'),'fullname','internal'],'required':![]},{'model':db[_0xf40081('0x8f')],'as':_0xf40081('0x20'),'attributes':['id',_0xf40081('0x9c'),_0xf40081('0x99')],'where':_0x4dbee2['query'][_0xf40081('0x3c')]?{'id':_0x4dbee2[_0xf40081('0x75')]['tag']}:undefined,'required':_0x4dbee2['query'][_0xf40081('0x3c')]?!![]:![]}]),db['MailInteraction'][_0xf40081('0x4e')](_0x217cdf);})[_0x1fcbb9('0x43')](function(_0x293271){const _0x33a17e=_0x1fcbb9;return _0x27016f[_0x33a17e('0x74')]=_0x293271,_0x27016f;});})[_0x7c677c('0x43')](respondWithFilteredResult(_0x52ab72,_0x217cdf))[_0x7c677c('0x82')](handleError(_0x52ab72,null));},exports[_0x479f12('0x94')]=function(_0x409698,_0x46fbac){const _0x257590=_0x479f12;return db['MailAccount'][_0x257590('0x85')]({'where':{'id':_0x409698[_0x257590('0x8')]['id']}})[_0x257590('0x43')](handleEntityNotFound(_0x46fbac,null))[_0x257590('0x43')](function(_0x15036e){const _0x559f6c=_0x257590;if(_0x15036e)return db[_0x559f6c('0xa2')][_0x559f6c('0x51')](function(_0xbe46d1){const _0x5297d8=_0x559f6c;return db[_0x5297d8('0x1b')][_0x5297d8('0x17')]({'where':{'MailAccountId':_0x409698['params']['id']},'transaction':_0xbe46d1})[_0x5297d8('0x43')](function(){const _0x58b52b=_0x5297d8,_0x30c32e=_['map'](_0x409698[_0x58b52b('0x9b')],function(_0x2ca96c){return _0x2ca96c['MailAccountId']=_0x409698['params']['id'],_0x2ca96c;});return db[_0x58b52b('0x1b')][_0x58b52b('0x1d')](_0x30c32e,{'transaction':_0xbe46d1});});})[_0x559f6c('0x43')](function(){const _0x794f96=_0x559f6c;return db[_0x794f96('0x1b')]['findAndCountAll']({'where':{'MailAccountId':_0x409698['params']['id']},'order':_0x794f96('0x3b')});});})[_0x257590('0x43')](respondWithResult(_0x46fbac,null))['catch'](handleError(_0x46fbac,null));},exports['getApplications']=function(_0x4f0d17,_0x1f4424){const _0x56cf62=_0x479f12;let _0xcd29ed={};const _0x4da90c={};let _0x11908c,_0xe7fa7a;return db[_0x56cf62('0x5b')][_0x56cf62('0x85')]({'where':{'id':_0x4f0d17[_0x56cf62('0x8')]['id']}})[_0x56cf62('0x43')](handleEntityNotFound(_0x1f4424,null))[_0x56cf62('0x43')](function(_0x4ef0c2){const _0x5f33ba=_0x56cf62;if(_0x4ef0c2)return _0x11908c=_0x4ef0c2,_0x4da90c['model']=_[_0x5f33ba('0x9d')](db[_0x5f33ba('0x1b')][_0x5f33ba('0xa6')]),_0x4da90c[_0x5f33ba('0x75')]=_[_0x5f33ba('0x9d')](_0x4f0d17[_0x5f33ba('0x75')]),_0x4da90c[_0x5f33ba('0x4d')]=_['intersection'](_0x4da90c['model'],_0x4da90c['query']),_0xcd29ed[_0x5f33ba('0x2')]=_[_0x5f33ba('0x2d')](_0x4da90c[_0x5f33ba('0x61')],qs['fields'](_0x4f0d17['query'][_0x5f33ba('0x65')])),_0xcd29ed['attributes']=_0xcd29ed[_0x5f33ba('0x2')][_0x5f33ba('0x6f')]?_0xcd29ed['attributes']:_0x4da90c['model'],_0xcd29ed[_0x5f33ba('0x6c')]=qs['sort'](_0x4f0d17[_0x5f33ba('0x75')][_0x5f33ba('0x3f')]),_0xcd29ed[_0x5f33ba('0xe')]=qs[_0x5f33ba('0x4d')](_[_0x5f33ba('0x11')](_0x4f0d17['query'],_0x4da90c[_0x5f33ba('0x4d')])),_0x4f0d17[_0x5f33ba('0x75')][_0x5f33ba('0x80')]&&(_0xcd29ed[_0x5f33ba('0xe')]=_[_0x5f33ba('0x98')](_0xcd29ed[_0x5f33ba('0xe')],{[Op['or']]:_['map'](_0xcd29ed[_0x5f33ba('0x2')],function(_0x2a9b4d){const _0x556ec=_0x5f33ba,_0x59a79d={};return _0x59a79d[_0x2a9b4d]={[Op[_0x556ec('0x92')]]:'%'+_0x4f0d17[_0x556ec('0x75')][_0x556ec('0x80')]+'%'},_0x59a79d;})})),_0xcd29ed=_[_0x5f33ba('0x98')]({},_0xcd29ed,_0x4f0d17[_0x5f33ba('0x5')]),_0x11908c['getApplications'](_0xcd29ed);})[_0x56cf62('0x43')](function(_0x2e1124){const _0x264c72=_0x56cf62;if(_0x2e1124)return _0xe7fa7a=_0x2e1124[_0x264c72('0x6f')],typeof _0x4f0d17[_0x264c72('0x75')][_0x264c72('0x29')]===_0x264c72('0x9f')&&(_0xcd29ed[_0x264c72('0x7c')]=qs[_0x264c72('0x7c')](_0x4f0d17['query']['limit']),_0xcd29ed[_0x264c72('0x35')]=qs[_0x264c72('0x35')](_0x4f0d17[_0x264c72('0x75')]['offset'])),_0x11908c[_0x264c72('0x4a')](_0xcd29ed);})[_0x56cf62('0x43')](function(_0x191570){if(_0x191570)return _0x191570?{'count':_0xe7fa7a,'rows':_0x191570}:null;})[_0x56cf62('0x43')](respondWithResult(_0x1f4424,null))['catch'](handleError(_0x1f4424,null));},exports[_0x479f12('0x0')]=function(_0x5d5294,_0x25f02c){const _0x4b8f2f=_0x479f12;let _0x5f56cc={'raw':!![],'where':{}};const _0x3e92fd={},_0x32913f={'count':0x0,'rows':[]};return db[_0x4b8f2f('0x5b')]['findOne']({'where':{'id':_0x5d5294['params']['id']}})[_0x4b8f2f('0x43')](handleEntityNotFound(_0x25f02c,null))[_0x4b8f2f('0x43')](function(_0x398bae){const _0x5bc319=_0x4b8f2f;if(_0x398bae){_0x3e92fd[_0x5bc319('0x61')]=_[_0x5bc319('0x9d')](db['MailMessage'][_0x5bc319('0xa6')]),_0x3e92fd[_0x5bc319('0x75')]=_[_0x5bc319('0x9d')](_0x5d5294['query']),_0x3e92fd[_0x5bc319('0x4d')]=_[_0x5bc319('0x2d')](_0x3e92fd[_0x5bc319('0x61')],_0x3e92fd[_0x5bc319('0x75')]),_0x5f56cc[_0x5bc319('0x2')]=_[_0x5bc319('0x2d')](_0x3e92fd[_0x5bc319('0x61')],qs[_0x5bc319('0x65')](_0x5d5294[_0x5bc319('0x75')][_0x5bc319('0x65')])),_0x5f56cc['attributes']=_0x5f56cc[_0x5bc319('0x2')][_0x5bc319('0x6f')]?_0x5f56cc['attributes']:_0x3e92fd[_0x5bc319('0x61')];typeof _0x5d5294['query'][_0x5bc319('0x29')]===_0x5bc319('0x9f')&&(_0x5f56cc[_0x5bc319('0x7c')]=qs[_0x5bc319('0x7c')](_0x5d5294['query'][_0x5bc319('0x7c')]),_0x5f56cc[_0x5bc319('0x35')]=qs[_0x5bc319('0x35')](_0x5d5294['query']['offset']));_0x5f56cc[_0x5bc319('0x6c')]=qs[_0x5bc319('0x3f')](_0x5d5294[_0x5bc319('0x75')][_0x5bc319('0x3f')]),_0x5f56cc[_0x5bc319('0xe')]=qs[_0x5bc319('0x4d')](_[_0x5bc319('0x11')](_0x5d5294[_0x5bc319('0x75')],_0x3e92fd[_0x5bc319('0x4d')])),_0x5f56cc[_0x5bc319('0xe')]['MailAccountId']=_0x398bae['id'];_0x5d5294[_0x5bc319('0x75')][_0x5bc319('0x80')]&&(_0x5f56cc['where']=_[_0x5bc319('0x98')](_0x5f56cc[_0x5bc319('0xe')],{[Op['or']]:_[_0x5bc319('0xf')](_0x5f56cc['attributes'],function(_0x8b3580){const _0xa70f31=_0x5bc319,_0x2a559a={};return _0x2a559a[_0x8b3580]={[Op['like']]:'%'+_0x5d5294[_0xa70f31('0x75')][_0xa70f31('0x80')]+'%'},_0x2a559a;})}));if(_0x5d5294['query']['$gte']){const _0x5344a8=_0x5d5294['query'][_0x5bc319('0x53')][_0x5bc319('0x7a')](','),_0x24e313={};_0x24e313[_0x5344a8[0x0]]={[Op[_0x5bc319('0x30')]]:moment(_0x5344a8[0x1])[_0x5bc319('0x6')]('YYYY-MM-DD\x20HH:mm:ss')},_0x5f56cc[_0x5bc319('0xe')]=_[_0x5bc319('0x98')](_0x5f56cc['where'],_0x24e313);}return _0x5f56cc=_['merge']({},_0x5f56cc,_0x5d5294['options']),db['MailMessage'][_0x5bc319('0x16')]({'where':_0x5f56cc[_0x5bc319('0xe')]})['then'](function(_0x43e0dd){const _0xf407ac=_0x5bc319;return _0x32913f[_0xf407ac('0x16')]=_0x43e0dd,_0x5d5294[_0xf407ac('0x75')][_0xf407ac('0x33')]&&(_0x5f56cc[_0xf407ac('0x3a')]=[{'all':!![]}]),db['MailMessage']['findAll'](_0x5f56cc);})['then'](function(_0x9e718f){const _0x19bdb7=_0x5bc319;return _0x32913f[_0x19bdb7('0x74')]=_0x9e718f,_0x32913f;});}})['then'](respondWithFilteredResult(_0x25f02c,_0x5f56cc))[_0x4b8f2f('0x82')](handleError(_0x25f02c,null));},exports[_0x479f12('0x1c')]=function(_0x3d9ad5,_0x152090){const _0x55d9cf=_0x479f12;let _0x44cb39,_0x3e80df={},_0x2b7407;return _0x3d9ad5['body']['to']&&(_0x2b7407=_0x3d9ad5[_0x55d9cf('0x9b')]['to'][_0x55d9cf('0x7a')](',')[0x0]),db[_0x55d9cf('0x5b')][_0x55d9cf('0x85')]({'where':{'id':_0x3d9ad5[_0x55d9cf('0x8')]['id']},'include':[{'model':db[_0x55d9cf('0x8d')],'as':_0x55d9cf('0xa'),'include':[{'model':db[_0x55d9cf('0x1a')],'as':'Contacts','where':{'email':_0x2b7407},'limit':0x1,'order':[[_0x55d9cf('0x87'),_0x55d9cf('0x38')]]}]},{'model':db[_0x55d9cf('0x5d')],'as':_0x55d9cf('0x88'),'raw':!![]}]})['then'](handleEntityNotFound(_0x152090,null))[_0x55d9cf('0x43')](function(_0x35ee47){const _0x51ee4c=_0x55d9cf;if(_0x35ee47){_0x44cb39=_0x35ee47;if(_0x35ee47[_0x51ee4c('0x88')]){_[_0x51ee4c('0xa1')](_0x3d9ad5[_0x51ee4c('0x9b')][_0x51ee4c('0x45')])&&(_0x3d9ad5['body'][_0x51ee4c('0x45')]=util[_0x51ee4c('0x6')](_0x51ee4c('0x34'),_0x35ee47[_0x51ee4c('0x9c')],_0x35ee47['email']||_0x35ee47[_0x51ee4c('0x88')][_0x51ee4c('0x14')]));if(_0x3d9ad5['body'][_0x51ee4c('0x60')]&&_0x3d9ad5[_0x51ee4c('0x9b')]['attachments'][_0x51ee4c('0x6f')])for(let _0x838777=0x0;_0x838777<_0x3d9ad5[_0x51ee4c('0x9b')][_0x51ee4c('0x60')]['length'];_0x838777+=0x1){_0x3d9ad5[_0x51ee4c('0x9b')]['attachments'][_0x838777]={'filename':_0x3d9ad5[_0x51ee4c('0x9b')][_0x51ee4c('0x60')][_0x838777][_0x51ee4c('0x9c')],'path':path[_0x51ee4c('0x9a')](config['root'],_0x51ee4c('0x72'),_0x3d9ad5[_0x51ee4c('0x9b')]['attachments'][_0x838777]['basename'])};}const _0x33c73b={'tls':{'rejectUnauthorized':![]}};return _[_0x51ee4c('0xa1')](_0x35ee47['Smtp']['service'])?(_0x35ee47[_0x51ee4c('0x88')]['authentication']&&(_0x33c73b[_0x51ee4c('0x1f')]={'user':_0x35ee47[_0x51ee4c('0x88')][_0x51ee4c('0x14')],'pass':_0x35ee47[_0x51ee4c('0x88')]['pass']}),_0x33c73b[_0x51ee4c('0x5a')]=_0x35ee47[_0x51ee4c('0x88')][_0x51ee4c('0x5a')],_0x33c73b[_0x51ee4c('0x62')]=_0x35ee47[_0x51ee4c('0x88')][_0x51ee4c('0x62')],_0x33c73b[_0x51ee4c('0x4f')]=_0x35ee47['Smtp']['secure']):(_0x33c73b[_0x51ee4c('0xa3')]=_0x35ee47[_0x51ee4c('0x88')]['service'],_0x33c73b[_0x51ee4c('0x1f')]={'user':_0x35ee47[_0x51ee4c('0x88')][_0x51ee4c('0x14')],'pass':_0x35ee47['Smtp'][_0x51ee4c('0x36')]}),respondWithRpcPromise(_0x51ee4c('0x48'),_0x51ee4c('0x91'),{'account':_0x33c73b,'message':_0x3d9ad5['body']});}else throw new Error(_0x51ee4c('0x64'));}})[_0x55d9cf('0x43')](function(_0x4a2b14){const _0x59be43=_0x55d9cf;if(_0x4a2b14){_0x3e80df=_0x4a2b14;if(_0x44cb39[_0x59be43('0xa')])return _0x44cb39[_0x59be43('0xa')]['Contacts'][_0x59be43('0x6f')]?_0x44cb39[_0x59be43('0xa')][_0x59be43('0x10')][0x0]:db[_0x59be43('0x1a')]['create'](_[_0x59be43('0x42')](_0x3d9ad5[_0x59be43('0x9b')],{'firstName':_0x3d9ad5[_0x59be43('0x9b')]['to'],'email':_0x3d9ad5[_0x59be43('0x9b')]['to'],'phone':_0x3d9ad5[_0x59be43('0x9b')]['to'],'ListId':_0x44cb39[_0x59be43('0x4c')]}));else throw new Error(_0x59be43('0x64'));}})[_0x55d9cf('0x43')](function(_0x1d9bcb){const _0x492359=_0x55d9cf;if(_0x1d9bcb){let _0x5ab193={'UserId':_0x3d9ad5['user']['id'],'ContactId':_0x1d9bcb['id'],'MailAccountId':_0x44cb39['id'],'inReplyTo':_0x3e80df['messageId'],'to':_0x3d9ad5[_0x492359('0x9b')][_0x492359('0x45')],'cc':_0x3d9ad5['body']['cc'],'subject':_0x3d9ad5[_0x492359('0x9b')][_0x492359('0x2b')],'attach':_0x3d9ad5[_0x492359('0x9b')][_0x492359('0x78')],'firstMsgDirection':_0x492359('0x6b'),'lastMsgAt':moment()[_0x492359('0x6')](_0x492359('0x79')),'lastMsgDirection':_0x492359('0x6b'),'lastMsgBody':_0x3d9ad5['body'][_0x492359('0x9b')],'Messages':[_[_0x492359('0x98')](_0x3d9ad5[_0x492359('0x9b')],{'messageId':_0x3e80df['messageId'],'sentAt':moment()['format'](_0x492359('0x79')),'read':!![],'MailAccountId':_0x44cb39['id'],'UserId':_0x3d9ad5[_0x492359('0x14')]['id'],'ContactId':_0x1d9bcb['id']})]};return _0x3d9ad5[_0x492359('0x9b')][_0x492359('0x18')]&&(_0x5ab193=_['merge'](_0x5ab193,_0x3d9ad5[_0x492359('0x9b')]['Interaction'])),db[_0x492359('0xd')][_0x492359('0x68')](_0x5ab193,{'include':[{'model':db[_0x492359('0x5e')],'as':'Messages'}]});}})[_0x55d9cf('0x43')](respondWithResult(_0x152090,null))[_0x55d9cf('0x82')](handleError(_0x152090,null));},exports[_0x479f12('0x28')]=function(_0x72d254,_0x553a62){const _0x1dc62a=_0x479f12;return db['MailAccount']['findOne']({'where':{'id':_0x72d254['params']['id']},'include':[{'model':db[_0x1dc62a('0x5d')],'as':_0x1dc62a('0x88'),'raw':!![]}]})[_0x1dc62a('0x43')](handleEntityNotFound(_0x553a62,null))[_0x1dc62a('0x43')](function(_0x28251d){const _0x216cb3=_0x1dc62a;if(_0x28251d&&_0x28251d['Smtp']){const _0x2cc0aa={'id':_0x28251d['id'],'tls':{'rejectUnauthorized':![]}};return _0x28251d[_0x216cb3('0x88')][_0x216cb3('0xa3')]?_0x2cc0aa[_0x216cb3('0xa3')]=_0x28251d[_0x216cb3('0x88')][_0x216cb3('0xa3')]:(_0x2cc0aa[_0x216cb3('0x5a')]=_0x28251d[_0x216cb3('0x88')][_0x216cb3('0x5a')],_0x2cc0aa[_0x216cb3('0x62')]=_0x28251d['Smtp'][_0x216cb3('0x62')],_0x2cc0aa['secure']=_0x28251d['Smtp'][_0x216cb3('0x4f')]),_0x28251d[_0x216cb3('0x88')][_0x216cb3('0x2e')]&&(_0x2cc0aa[_0x216cb3('0x1f')]={'user':_0x28251d['Smtp']['user'],'pass':_0x28251d['Smtp'][_0x216cb3('0x36')]}),respondWithRpcPromise(_0x216cb3('0xb'),_0x216cb3('0x28'),{'account':_0x2cc0aa});}})[_0x1dc62a('0x43')](respondWithResult(_0x553a62,null))[_0x1dc62a('0x82')](handleError(_0x553a62,null));},exports['destroy']=function(_0x2f45f6,_0x4d5334){const _0x258c71=_0x479f12;return db[_0x258c71('0x5b')]['findOne']({'where':{'id':_0x2f45f6[_0x258c71('0x8')]['id']}})['then'](handleEntityNotFound(_0x4d5334,null))['then'](function(_0x1a8132){const _0x33e745=_0x258c71;if(_0x1a8132&&_0x1a8132['service'])throw new ValidationError(_0x33e745('0x1e'));return _0x1a8132;})['then'](removeEntity(_0x4d5334,null))[_0x258c71('0x82')](handleError(_0x4d5334,null));},exports[_0x479f12('0x2c')]=function(_0x290410,_0x252daf){const _0x17f2ae=_0x479f12;return db[_0x17f2ae('0x5b')][_0x17f2ae('0x85')]({'where':{'id':_0x290410[_0x17f2ae('0x8')]['id']}})[_0x17f2ae('0x43')](function(_0x1b0da8){const _0x5445e8=_0x17f2ae;if(_0x1b0da8)return _0x1b0da8[_0x5445e8('0x2c')](_0x290410[_0x5445e8('0x9b')][_0x5445e8('0x24')],{'through':_[_0x5445e8('0x63')](_0x290410[_0x5445e8('0x9b')],[_0x5445e8('0x24'),'id'])})[_0x5445e8('0x43')](function(_0x20e02f){const _0x1c71c1=_0x5445e8;for(let _0x551350=0x0;_0x551350<_0x290410[_0x1c71c1('0x9b')][_0x1c71c1('0x24')][_0x1c71c1('0x6f')];_0x551350+=0x1){socket[_0x1c71c1('0x32')]('userMailAccount:save',{'UserId':_0x290410[_0x1c71c1('0x9b')]['ids'][_0x551350],'MailAccountId':_0x290410[_0x1c71c1('0x8')]['id']});}return _0x20e02f;});})[_0x17f2ae('0x43')](respondWithResult(_0x252daf,null))[_0x17f2ae('0x82')](handleError(_0x252daf,null));},exports[_0x479f12('0x31')]=function(_0x4a14f5,_0x54e05f){const _0x50370a=_0x479f12;return db['MailAccount']['findOne']({'where':{'id':_0x4a14f5[_0x50370a('0x8')]['id']}})['then'](handleEntityNotFound(_0x54e05f,null))[_0x50370a('0x43')](function(_0x1944b9){const _0x4ede2f=_0x50370a;if(_0x1944b9)return _0x1944b9[_0x4ede2f('0x31')](_0x4a14f5[_0x4ede2f('0x75')][_0x4ede2f('0x24')])['then'](function(){const _0x3ad054=_0x4ede2f;if(_['isArray'](_0x4a14f5[_0x3ad054('0x75')][_0x3ad054('0x24')]))for(let _0x10e49f=0x0;_0x10e49f<_0x4a14f5[_0x3ad054('0x75')]['ids'][_0x3ad054('0x6f')];_0x10e49f+=0x1){socket[_0x3ad054('0x32')](_0x3ad054('0x52'),{'UserId':Number(_0x4a14f5['query'][_0x3ad054('0x24')][_0x10e49f]),'MailAccountId':Number(_0x4a14f5[_0x3ad054('0x8')]['id'])});}else socket[_0x3ad054('0x32')]('userMailAccount:remove',{'UserId':Number(_0x4a14f5['query']['ids']),'MailAccountId':Number(_0x4a14f5[_0x3ad054('0x8')]['id'])});});})[_0x50370a('0x43')](respondWithStatusCode(_0x54e05f,null))['catch'](handleError(_0x54e05f,null));},exports[_0x479f12('0x25')]=function(_0x159c9f,_0x4ce4f2){const _0x585e8b=_0x479f12;let _0x331321={};const _0x53a5c8={};let _0x18548e,_0x5996aa;return db[_0x585e8b('0x5b')][_0x585e8b('0x85')]({'where':{'id':_0x159c9f[_0x585e8b('0x8')]['id']}})['then'](handleEntityNotFound(_0x4ce4f2,null))['then'](function(_0x50ddd8){const _0x577cc4=_0x585e8b;if(_0x50ddd8)return _0x18548e=_0x50ddd8,_0x53a5c8[_0x577cc4('0x61')]=_[_0x577cc4('0x9d')](db['User'][_0x577cc4('0xa6')]),_0x53a5c8[_0x577cc4('0x75')]=_['keys'](_0x159c9f[_0x577cc4('0x75')]),_0x53a5c8['filters']=_['intersection'](_0x53a5c8[_0x577cc4('0x61')],_0x53a5c8[_0x577cc4('0x75')]),_0x331321[_0x577cc4('0x2')]=_['intersection'](_0x53a5c8['model'],qs[_0x577cc4('0x65')](_0x159c9f[_0x577cc4('0x75')][_0x577cc4('0x65')])),_0x331321[_0x577cc4('0x2')]=_0x331321[_0x577cc4('0x2')][_0x577cc4('0x6f')]?_0x331321[_0x577cc4('0x2')]:_0x53a5c8[_0x577cc4('0x61')],_0x331321['order']=qs[_0x577cc4('0x3f')](_0x159c9f['query']['sort']),_0x331321[_0x577cc4('0xe')]=qs[_0x577cc4('0x4d')](_['pick'](_0x159c9f[_0x577cc4('0x75')],_0x53a5c8['filters'])),_0x159c9f[_0x577cc4('0x75')][_0x577cc4('0x80')]&&(_0x331321[_0x577cc4('0xe')]=_[_0x577cc4('0x98')](_0x331321[_0x577cc4('0xe')],{[Op['or']]:_['map'](_0x331321[_0x577cc4('0x2')],function(_0x3be1d1){const _0x45056a=_0x577cc4,_0x54be03={};return _0x54be03[_0x3be1d1]={[Op[_0x45056a('0x92')]]:'%'+_0x159c9f['query']['filter']+'%'},_0x54be03;})})),_0x331321=_[_0x577cc4('0x98')]({},_0x331321,_0x159c9f['options']),_0x18548e[_0x577cc4('0x25')](_0x331321);})[_0x585e8b('0x43')](function(_0x39f81d){const _0x2b9a0c=_0x585e8b;if(_0x39f81d)return _0x5996aa=_0x39f81d[_0x2b9a0c('0x6f')],typeof _0x159c9f[_0x2b9a0c('0x75')][_0x2b9a0c('0x29')]===_0x2b9a0c('0x9f')&&(_0x331321[_0x2b9a0c('0x7c')]=qs[_0x2b9a0c('0x7c')](_0x159c9f[_0x2b9a0c('0x75')][_0x2b9a0c('0x7c')]),_0x331321['offset']=qs[_0x2b9a0c('0x35')](_0x159c9f[_0x2b9a0c('0x75')]['offset'])),_0x18548e[_0x2b9a0c('0x25')](_0x331321);})[_0x585e8b('0x43')](function(_0x1e079f){if(_0x1e079f)return _0x1e079f?{'count':_0x5996aa,'rows':_0x1e079f}:null;})[_0x585e8b('0x43')](respondWithResult(_0x4ce4f2,null))[_0x585e8b('0x82')](handleError(_0x4ce4f2,null));}; \ No newline at end of file diff --git a/server/api/mailAccount/mailAccount.events.js b/server/api/mailAccount/mailAccount.events.js index c541eb6..5da4e64 100644 --- a/server/api/mailAccount/mailAccount.events.js +++ b/server/api/mailAccount/mailAccount.events.js @@ -1 +1 @@ -const a395_0x585c=['update','emit','undefined','remove','save','../../mysqldb','events','exports','addHook','setMaxListeners'];(function(_0x1afeb1,_0x585c17){const _0x1882ee=function(_0x12a988){while(--_0x12a988){_0x1afeb1['push'](_0x1afeb1['shift']());}};_0x1882ee(++_0x585c17);}(a395_0x585c,0x10e));const a395_0x1882=function(_0x1afeb1,_0x585c17){_0x1afeb1=_0x1afeb1-0x0;let _0x1882ee=a395_0x585c[_0x1afeb1];return _0x1882ee;};const _0x4bdbef=a395_0x1882;'use strict';const EventEmitter=require(_0x4bdbef('0x6')),MailAccount=require(_0x4bdbef('0x5'))['db']['MailAccount'],MailAccountEvents=new EventEmitter();MailAccountEvents[_0x4bdbef('0x9')](0x0);const events={'afterCreate':_0x4bdbef('0x4'),'afterUpdate':_0x4bdbef('0x0'),'afterDestroy':_0x4bdbef('0x3')};function emitEvent(_0x12a988){return function(_0x14ee84){const _0xd28ecf=a395_0x1882;MailAccountEvents[_0xd28ecf('0x1')](_0x12a988+':'+_0x14ee84['id'],_0x14ee84),MailAccountEvents[_0xd28ecf('0x1')](_0x12a988,_0x14ee84);};}for(const e in events){if(typeof events[e]!==_0x4bdbef('0x2')){const event=events[e];MailAccount[_0x4bdbef('0x8')](e,emitEvent(event));}}module[_0x4bdbef('0x7')]=MailAccountEvents; \ No newline at end of file +const a395_0xc7ba=['update','exports','events','undefined','save','setMaxListeners','emit','addHook'];(function(_0xbf0d64,_0xc7ba75){const _0x5c2c48=function(_0x140303){while(--_0x140303){_0xbf0d64['push'](_0xbf0d64['shift']());}};_0x5c2c48(++_0xc7ba75);}(a395_0xc7ba,0x1f2));const a395_0x5c2c=function(_0xbf0d64,_0xc7ba75){_0xbf0d64=_0xbf0d64-0x0;let _0x5c2c48=a395_0xc7ba[_0xbf0d64];return _0x5c2c48;};const _0x44dc91=a395_0x5c2c;'use strict';const EventEmitter=require(_0x44dc91('0x0')),MailAccount=require('../../mysqldb')['db']['MailAccount'],MailAccountEvents=new EventEmitter();MailAccountEvents[_0x44dc91('0x3')](0x0);const events={'afterCreate':_0x44dc91('0x2'),'afterUpdate':_0x44dc91('0x6'),'afterDestroy':'remove'};function emitEvent(_0x140303){return function(_0x2531cd){const _0x3565de=a395_0x5c2c;MailAccountEvents['emit'](_0x140303+':'+_0x2531cd['id'],_0x2531cd),MailAccountEvents[_0x3565de('0x4')](_0x140303,_0x2531cd);};}for(const e in events){if(typeof events[e]!==_0x44dc91('0x1')){const event=events[e];MailAccount[_0x44dc91('0x5')](e,emitEvent(event));}}module[_0x44dc91('0x7')]=MailAccountEvents; \ No newline at end of file diff --git a/server/api/mailAccount/mailAccount.model.js b/server/api/mailAccount/mailAccount.model.js index ee247a4..8c416e6 100644 --- a/server/api/mailAccount/mailAccount.model.js +++ b/server/api/mailAccount/mailAccount.model.js @@ -1 +1 @@ -const a396_0x3faa=['MailAccount','mail_accounts','exports','./mailAccount.attributes','define'];(function(_0x5827f7,_0x3faa9d){const _0x3f0dd2=function(_0x28a554){while(--_0x28a554){_0x5827f7['push'](_0x5827f7['shift']());}};_0x3f0dd2(++_0x3faa9d);}(a396_0x3faa,0x1e7));const a396_0x3f0d=function(_0x5827f7,_0x3faa9d){_0x5827f7=_0x5827f7-0x0;let _0x3f0dd2=a396_0x3faa[_0x5827f7];return _0x3f0dd2;};const _0x43c94d=a396_0x3f0d;'use strict';const attributes=require(_0x43c94d('0x1'));module[_0x43c94d('0x0')]=function(_0x28a554){const _0x2bd55e=_0x43c94d,_0x1bdafb=_0x28a554[_0x2bd55e('0x2')](_0x2bd55e('0x3'),attributes,{'tableName':_0x2bd55e('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1bdafb;}; \ No newline at end of file +const a396_0x1422=['exports','mail_accounts','./mailAccount.attributes'];(function(_0x49cc66,_0x142218){const _0x162d6b=function(_0xb2acf3){while(--_0xb2acf3){_0x49cc66['push'](_0x49cc66['shift']());}};_0x162d6b(++_0x142218);}(a396_0x1422,0x1e0));const a396_0x162d=function(_0x49cc66,_0x142218){_0x49cc66=_0x49cc66-0x0;let _0x162d6b=a396_0x1422[_0x49cc66];return _0x162d6b;};const _0x544db1=a396_0x162d;'use strict';const attributes=require(_0x544db1('0x2'));module[_0x544db1('0x0')]=function(_0xb2acf3){const _0x534c89=_0x544db1,_0x29de0a=_0xb2acf3['define']('MailAccount',attributes,{'tableName':_0x534c89('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x29de0a;}; \ No newline at end of file diff --git a/server/api/mailAccount/mailAccount.rpc.js b/server/api/mailAccount/mailAccount.rpc.js index ad0151c..fb0beb1 100644 --- a/server/api/mailAccount/mailAccount.rpc.js +++ b/server/api/mailAccount/mailAccount.rpc.js @@ -1 +1 @@ -const a397_0x2254=['*,*,*,*','./mailAccount.socket','CmContact','map','mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','messageId','name','from\x20is\x20mandatory','includes','subject','debug','attach','request\x20sent','MailApplication','close','NotifyMailAccount','then','moment','from','push','mail','generate','code','account','request','List','agent','../../mysqldb','Applications','Smtp','CompanyId','model','createdAt','result','list','MailAccount,\x20%s,\x20%s','limit','contact','../../config/logger','bcc','mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20','MailAccount','register','User','UserId','updatedAt','unshift','List\x20not\x20found','Start','Messages','asc','jayson/promise','raw','message','create','length','client','catch','stringify','GetMailAccount','applications','waitForTheAssignedAgent','YYYY-MM-DD\x20HH:mm:ss','DESC','Attachment','startRouting','body','difference','body\x20is\x20mandatory\x20and\x20not\x20empty','isNil','MailAccount,\x20%s,\x20%s,\x20%s','autoclose','attributes','findAll','mapKey','error','info','Contacts','include','options','CmList','originTo','randomstring','where','orderBy','interaction','get','rpc','MailInteraction','priority','format','ShowMailAccount','rawAttributes','MailMessage','lodash','Attachments','inReplyTo','findOne'];(function(_0x465220,_0x22547a){const _0x532d10=function(_0x428204){while(--_0x428204){_0x465220['push'](_0x465220['shift']());}};_0x532d10(++_0x22547a);}(a397_0x2254,0x197));const a397_0x532d=function(_0x465220,_0x22547a){_0x465220=_0x465220-0x0;let _0x532d10=a397_0x2254[_0x465220];return _0x532d10;};const _0x533e75=a397_0x532d;'use strict';const _=require(_0x533e75('0x4f')),db=require(_0x533e75('0xc'))['db'],logger=require(_0x533e75('0x17'))(_0x533e75('0x48')),{getSocket}=require('../../rediscache'),socket=getSocket(),rs=require(_0x533e75('0x43')),moment=require(_0x533e75('0x2')),jayson=require(_0x533e75('0x24')),client=jayson[_0x533e75('0x29')]['http']({'port':0x232c});require(_0x533e75('0x54'))[_0x533e75('0x1b')](socket);function respondWithRpcPromise(_0x428204,_0x5d06af,_0x17c449){return new Promise(function(_0x225992,_0x5e825b){const _0x211ed2=a397_0x532d;return client[_0x211ed2('0x9')](_0x428204,_0x17c449)[_0x211ed2('0x1')](function(_0x199ad4){const _0x631e46=_0x211ed2;logger[_0x631e46('0x3d')](_0x631e46('0x14'),_0x5d06af,'request\x20sent'),logger[_0x631e46('0x5d')](_0x631e46('0x37'),_0x5d06af,_0x631e46('0x5f'),JSON[_0x631e46('0x2b')](_0x199ad4));if(_0x199ad4[_0x631e46('0x3c')]){if(_0x199ad4['error'][_0x631e46('0x7')]===0x1f4)return logger[_0x631e46('0x3c')](_0x631e46('0x14'),_0x5d06af,_0x199ad4[_0x631e46('0x3c')][_0x631e46('0x26')]),_0x5e825b(_0x199ad4[_0x631e46('0x3c')]['message']);return logger[_0x631e46('0x3c')]('MailAccount,\x20%s,\x20%s',_0x5d06af,_0x199ad4[_0x631e46('0x3c')][_0x631e46('0x26')]),_0x225992(_0x199ad4[_0x631e46('0x3c')][_0x631e46('0x26')]);}else logger['info'](_0x631e46('0x14'),_0x5d06af,'request\x20sent'),_0x225992(_0x199ad4[_0x631e46('0x12')][_0x631e46('0x26')]);})[_0x211ed2('0x2a')](function(_0x2f76e2){const _0x31ae2c=_0x211ed2;logger[_0x31ae2c('0x3c')]('MailAccount,\x20%s,\x20%s',_0x5d06af,_0x2f76e2),_0x5e825b(_0x2f76e2);});});}exports[_0x533e75('0x2c')]=function(_0x5dbed8){const _0x56c973=this;return new Promise(function(_0x1d60f6,_0x20353d){const _0xd7aa7e=a397_0x532d;return db[_0xd7aa7e('0x1a')][_0xd7aa7e('0x3a')]({'raw':_0x5dbed8[_0xd7aa7e('0x40')]?_0x5dbed8[_0xd7aa7e('0x40')][_0xd7aa7e('0x25')]===undefined?!![]:![]:!![],'where':_0x5dbed8[_0xd7aa7e('0x40')]?_0x5dbed8[_0xd7aa7e('0x40')][_0xd7aa7e('0x44')]||null:null,'attributes':_0x5dbed8['options']?_0x5dbed8[_0xd7aa7e('0x40')]['attributes']||null:null,'limit':_0x5dbed8[_0xd7aa7e('0x40')]?_0x5dbed8[_0xd7aa7e('0x40')][_0xd7aa7e('0x15')]||null:null,'include':_0x5dbed8[_0xd7aa7e('0x40')]?_0x5dbed8[_0xd7aa7e('0x40')][_0xd7aa7e('0x3f')]?_[_0xd7aa7e('0x56')](_0x5dbed8[_0xd7aa7e('0x40')]['include'],function(_0x40bb30){const _0x2c89b1=_0xd7aa7e;return{'model':db[_0x40bb30[_0x2c89b1('0x10')]],'as':_0x40bb30['as'],'attributes':_0x40bb30[_0x2c89b1('0x39')],'include':_0x40bb30[_0x2c89b1('0x3f')]?_['map'](_0x40bb30['include'],function(_0x5411f4){const _0x2130ac=_0x2c89b1;return{'model':db[_0x5411f4[_0x2130ac('0x10')]],'as':_0x5411f4['as'],'attributes':_0x5411f4['attributes'],'include':_0x5411f4['include']?_[_0x2130ac('0x56')](_0x5411f4['include'],function(_0x3797bf){const _0x43c2b9=_0x2130ac;return{'model':db[_0x3797bf[_0x43c2b9('0x10')]],'as':_0x3797bf['as'],'attributes':_0x3797bf[_0x43c2b9('0x39')]};}):[]};}):[]};}):[]:[]})[_0xd7aa7e('0x1')](function(_0xe642fd){const _0x39a486=_0xd7aa7e;logger[_0x39a486('0x3d')](_0x39a486('0x2c'),_0x5dbed8),logger[_0x39a486('0x5d')]('GetMailAccount',_0x5dbed8,JSON['stringify'](_0xe642fd)),_0x1d60f6(_0xe642fd);})[_0xd7aa7e('0x2a')](function(_0x3cf31c){const _0x58c3ec=_0xd7aa7e;logger[_0x58c3ec('0x3c')](_0x58c3ec('0x2c'),_0x3cf31c[_0x58c3ec('0x26')],_0x5dbed8),_0x20353d(_0x56c973[_0x58c3ec('0x3c')](0x1f4,_0x3cf31c[_0x58c3ec('0x26')]));});});},exports[_0x533e75('0x4c')]=function(_0xc1bfa){const _0x55cc5a=this;return new Promise(function(_0x2308dd,_0x25adfd){const _0x1c817e=a397_0x532d;return db[_0x1c817e('0x1a')][_0x1c817e('0x52')]({'raw':_0xc1bfa[_0x1c817e('0x40')]?_0xc1bfa[_0x1c817e('0x40')][_0x1c817e('0x25')]===undefined?!![]:![]:!![],'where':_0xc1bfa[_0x1c817e('0x40')]?_0xc1bfa['options'][_0x1c817e('0x44')]||null:null,'attributes':_0xc1bfa[_0x1c817e('0x40')]?_0xc1bfa[_0x1c817e('0x40')][_0x1c817e('0x39')]||null:null,'include':_0xc1bfa['options']?_0xc1bfa[_0x1c817e('0x40')][_0x1c817e('0x3f')]?_[_0x1c817e('0x56')](_0xc1bfa[_0x1c817e('0x40')]['include'],function(_0x2d59a1){const _0x2c2f6b=_0x1c817e;return{'model':db[_0x2d59a1[_0x2c2f6b('0x10')]],'as':_0x2d59a1['as'],'attributes':_0x2d59a1[_0x2c2f6b('0x39')],'include':_0x2d59a1['include']?_[_0x2c2f6b('0x56')](_0x2d59a1[_0x2c2f6b('0x3f')],function(_0x22639e){const _0xba9575=_0x2c2f6b;return{'model':db[_0x22639e[_0xba9575('0x10')]],'as':_0x22639e['as'],'attributes':_0x22639e[_0xba9575('0x39')],'include':_0x22639e[_0xba9575('0x3f')]?_['map'](_0x22639e[_0xba9575('0x3f')],function(_0x8ad0f1){const _0x4a2ef6=_0xba9575;return{'model':db[_0x8ad0f1[_0x4a2ef6('0x10')]],'as':_0x8ad0f1['as'],'attributes':_0x8ad0f1[_0x4a2ef6('0x39')]};}):[]};}):[]};}):[]:[]})[_0x1c817e('0x1')](function(_0x2114a0){const _0x11d05f=_0x1c817e;logger[_0x11d05f('0x3d')](_0x11d05f('0x4c'),_0xc1bfa),logger[_0x11d05f('0x5d')](_0x11d05f('0x4c'),_0xc1bfa,JSON[_0x11d05f('0x2b')](_0x2114a0)),_0x2308dd(_0x2114a0);})[_0x1c817e('0x2a')](function(_0x58c321){const _0x778e3=_0x1c817e;logger[_0x778e3('0x3c')](_0x778e3('0x4c'),_0x58c321[_0x778e3('0x26')],_0xc1bfa),_0x25adfd(_0x55cc5a[_0x778e3('0x3c')](0x1f4,_0x58c321[_0x778e3('0x26')]));});});},exports[_0x533e75('0x0')]=function(_0xcdf491){const _0x235588=this;return new Promise(function(_0x2e5e4a,_0x2c9758){const _0x599c47=a397_0x532d,_0x28850f={'body':_0xcdf491[_0x599c47('0x33')],'channel':_0x599c47('0x5')},_0x52c8f6=_[_0x599c47('0x34')](_['keys'](db[_0x599c47('0x55')][_0x599c47('0x4d')]),[_0x599c47('0x11'),_0x599c47('0x1e'),_0x599c47('0xf'),'ListId']);let _0x5722d0=![];_0xcdf491[_0x599c47('0x33')]['id']&&delete _0xcdf491['body']['id'];if(_[_0x599c47('0x36')](_0xcdf491[_0x599c47('0x33')]['from']))return _0x2c9758(_0x235588['error'](0x1f4,_0x599c47('0x5a')));if(_[_0x599c47('0x36')](_0xcdf491[_0x599c47('0x33')]['body'])||_0xcdf491[_0x599c47('0x33')][_0x599c47('0x33')]==='')return _0x2c9758(_0x235588['error'](0x1f4,_0x599c47('0x35')));if(_['isNil'](_0xcdf491[_0x599c47('0x33')][_0x599c47('0x3b')]))return _0x2c9758(_0x235588[_0x599c47('0x3c')](0x1f4,_0x599c47('0x19')+_0x52c8f6));if(!_[_0x599c47('0x5b')](_0x52c8f6,_0xcdf491['body'][_0x599c47('0x3b')]))return _0x2c9758(_0x235588[_0x599c47('0x3c')](0x1f4,_0x599c47('0x57')+_0x52c8f6));const _0x4a2caa={};return _0x4a2caa[_0xcdf491['body'][_0x599c47('0x3b')]]=_0xcdf491[_0x599c47('0x33')][_0x599c47('0x3')],db[_0x599c47('0x1a')]['findOne']({'where':{'id':_0xcdf491[_0x599c47('0x8')]['id']},'include':[{'model':db[_0x599c47('0x41')],'as':_0x599c47('0xa'),'include':[{'model':db['CmContact'],'as':'Contacts','where':_0x4a2caa,'limit':0x1,'order':[['updatedAt',_0x599c47('0x30')]]}]},{'model':db[_0x599c47('0x60')],'as':'Applications'},{'model':db['MailServerOut'],'as':_0x599c47('0xe')}]})[_0x599c47('0x1')](function(_0x48d661){const _0x482d1c=_0x599c47;if(_0x48d661&&_0x48d661[_0x482d1c('0xa')]){const _0x4f5fc0=_0x48d661[_0x482d1c('0x47')]({'plain':!![]});_0x28850f[_0x482d1c('0x8')]=_['omit'](_0x4f5fc0,[_0x482d1c('0xd'),_0x482d1c('0xa')]),_0x28850f[_0x482d1c('0x2d')]=_0x4f5fc0[_0x482d1c('0xd')],_0x28850f[_0x482d1c('0x13')]=_0x4f5fc0[_0x482d1c('0xa')],_0x28850f[_0x482d1c('0x2d')]=_[_0x482d1c('0x45')](_0x28850f[_0x482d1c('0x2d')],[_0x482d1c('0x4a')],[_0x482d1c('0x23')]);_0x28850f[_0x482d1c('0x8')]&&_0x28850f[_0x482d1c('0x8')]['autoclose']&&_0x28850f[_0x482d1c('0x2d')][_0x482d1c('0x4')]({'id':0x0,'priority':_0x28850f[_0x482d1c('0x2d')][_0x482d1c('0x28')]+0x1,'app':_0x482d1c('0x61'),'appdata':_0x482d1c('0x38'),'interval':_0x482d1c('0x53')});_0x28850f[_0x482d1c('0x8')]['Applications']&&delete _0x28850f[_0x482d1c('0x8')][_0x482d1c('0xd')];_0x28850f[_0x482d1c('0x8')][_0x482d1c('0xa')]&&delete _0x28850f[_0x482d1c('0x8')][_0x482d1c('0xa')];if(_0x4f5fc0[_0x482d1c('0xa')][_0x482d1c('0x3e')][_0x482d1c('0x28')])return _0x4f5fc0[_0x482d1c('0xa')][_0x482d1c('0x3e')][0x0];const _0x4dc3ab=_['defaults'](_0xcdf491[_0x482d1c('0x33')],{'firstName':_0xcdf491['body']['from'],'ListId':_0x4f5fc0['ListId']});return _0x4dc3ab[_0xcdf491[_0x482d1c('0x33')][_0x482d1c('0x3b')]]=_0xcdf491['body']['from'],db[_0x482d1c('0x55')][_0x482d1c('0x27')](_0x4dc3ab);}else throw new Error(_0x482d1c('0x20'));})[_0x599c47('0x1')](function(_0x1ff420){const _0x1409d7=_0x599c47;_0x28850f[_0x1409d7('0x16')]=_0x1ff420;if(_0x1ff420){!_0xcdf491[_0x1409d7('0x33')][_0x1409d7('0x26')][_0x1409d7('0x58')]&&(_0xcdf491['body'][_0x1409d7('0x26')][_0x1409d7('0x58')]=rs[_0x1409d7('0x6')]()+'\x20'+_0xcdf491[_0x1409d7('0x33')][_0x1409d7('0x26')][_0x1409d7('0x3')]);const _0x54ccae={'ContactId':_0x1ff420['id'],'MailAccountId':_0xcdf491[_0x1409d7('0x8')]['id'],'inReplyTo':_0xcdf491[_0x1409d7('0x33')][_0x1409d7('0x26')][_0x1409d7('0x58')],'to':_0xcdf491['body'][_0x1409d7('0x26')][_0x1409d7('0x3')],'cc':_0xcdf491[_0x1409d7('0x33')][_0x1409d7('0x26')]['cc'],'subject':_0xcdf491['body'][_0x1409d7('0x26')][_0x1409d7('0x5c')],'attach':_0xcdf491[_0x1409d7('0x33')][_0x1409d7('0x26')][_0x1409d7('0x5e')],'lastMsgAt':moment()[_0x1409d7('0x4b')](_0x1409d7('0x2f')),'lastMsgDirection':'in','lastMsgBody':_0xcdf491[_0x1409d7('0x33')][_0x1409d7('0x33')]};return db[_0x1409d7('0x49')][_0x1409d7('0x52')]({'where':{'closed':![],'MailAccountId':_0xcdf491['account']['id']},'include':[{'model':db[_0x1409d7('0x4e')],'as':_0x1409d7('0x22'),'attributes':[_0x1409d7('0x58')],'where':{'messageId':_0xcdf491[_0x1409d7('0x33')][_0x1409d7('0x26')][_0x1409d7('0x51')]}}]})[_0x1409d7('0x1')](function(_0x3df70e){const _0x36cd90=_0x1409d7;if(_0x3df70e)return[_0x3df70e,![]];return db[_0x36cd90('0x49')][_0x36cd90('0x27')](_0x54ccae)[_0x36cd90('0x1')](function(_0x1491c2){return[_0x1491c2,!![]];});});}else throw new Error('Contact\x20not\x20found');})[_0x599c47('0x1')](function([_0x383855,_0x2d8877]){const _0x3d9201=_0x599c47;if(_0x383855)return _0x5722d0=_0x2d8877,!_0x2d8877?_0x383855['update']({'inReplyTo':_0xcdf491[_0x3d9201('0x33')][_0x3d9201('0x26')]['messageId'],'to':_0xcdf491[_0x3d9201('0x33')][_0x3d9201('0x26')][_0x3d9201('0x3')],'cc':_0xcdf491[_0x3d9201('0x33')]['message']['cc'],'subject':_0xcdf491[_0x3d9201('0x33')][_0x3d9201('0x26')][_0x3d9201('0x5c')],'attach':_0x383855[_0x3d9201('0x5e')]?_0x383855['attach']:_0xcdf491[_0x3d9201('0x33')][_0x3d9201('0x26')][_0x3d9201('0x5e')],'substatus':null,'substatusAt':moment()['format'](_0x3d9201('0x2f')),'lastMsgAt':moment()[_0x3d9201('0x4b')]('YYYY-MM-DD\x20HH:mm:ss'),'lastMsgDirection':'in','lastMsgBody':_0xcdf491[_0x3d9201('0x33')][_0x3d9201('0x33')]}):_0x383855;})[_0x599c47('0x1')](function(_0x194481){const _0x3bd3ae=_0x599c47;return _0x28850f['interaction']=_0x194481[_0x3bd3ae('0x47')]({'plain':!![]}),_0x28850f[_0x3bd3ae('0x46')]['created']=_0x5722d0,db[_0x3bd3ae('0x4e')][_0x3bd3ae('0x27')]({'body':_0xcdf491[_0x3bd3ae('0x33')][_0x3bd3ae('0x33')],'MailAccountId':_0xcdf491[_0x3bd3ae('0x8')]['id'],'MailInteractionId':_0x194481['id'],'direction':'in','ContactId':_0x28850f[_0x3bd3ae('0x16')]['id'],'messageId':_0xcdf491['body'][_0x3bd3ae('0x26')][_0x3bd3ae('0x58')],'from':_0xcdf491[_0x3bd3ae('0x33')][_0x3bd3ae('0x26')][_0x3bd3ae('0x3')],'to':_0xcdf491['body'][_0x3bd3ae('0x26')]['to'],'cc':_0xcdf491['body']['message']['cc'],'subject':_0xcdf491[_0x3bd3ae('0x33')][_0x3bd3ae('0x26')][_0x3bd3ae('0x5c')],'attach':_0xcdf491[_0x3bd3ae('0x33')][_0x3bd3ae('0x26')][_0x3bd3ae('0x5e')],'Attachments':_0xcdf491['body'][_0x3bd3ae('0x26')]['attachments'],'originTo':_0xcdf491[_0x3bd3ae('0x33')][_0x3bd3ae('0x26')][_0x3bd3ae('0x42')],'originCc':_0xcdf491[_0x3bd3ae('0x33')][_0x3bd3ae('0x26')]['originCc'],'bcc':_0xcdf491[_0x3bd3ae('0x33')]['message'][_0x3bd3ae('0x18')]},{'include':[{'model':db[_0x3bd3ae('0x31')],'as':_0x3bd3ae('0x50')}]});})['then'](function(_0x1dea42){const _0x19dc8d=_0x599c47;_0x28850f[_0x19dc8d('0x26')]=_0x1dea42;if(_0x28850f[_0x19dc8d('0x46')][_0x19dc8d('0x1d')])return db[_0x19dc8d('0x1c')][_0x19dc8d('0x52')]({'attributes':['id','name'],'where':{'id':_0x28850f[_0x19dc8d('0x46')][_0x19dc8d('0x1d')]}})['then'](function(_0x4ead9d){const _0x1f8f48=_0x19dc8d;return _0x4ead9d&&_0x28850f[_0x1f8f48('0x2d')][_0x1f8f48('0x1f')]({'id':0x0,'priority':0x0,'app':_0x1f8f48('0xb'),'appdata':_0x4ead9d[_0x1f8f48('0x59')]+','+(_0x28850f[_0x1f8f48('0x8')][_0x1f8f48('0x2e')]||0xa),'interval':'*,*,*,*'}),respondWithRpcPromise(_0x1f8f48('0x21'),_0x1f8f48('0x32'),_0x28850f);});return respondWithRpcPromise(_0x19dc8d('0x21'),_0x19dc8d('0x32'),_0x28850f);})['then'](function(_0x10a13c){_0x2e5e4a(_0x10a13c);})[_0x599c47('0x2a')](function(_0x3ad645){const _0x4ab964=_0x599c47;_0x2c9758(_0x235588[_0x4ab964('0x3c')](0x1f4,_0x3ad645[_0x4ab964('0x26')]));});});}; \ No newline at end of file +const a397_0xa9bd=['format','unshift','NotifyMailAccount','../../config/logger','model','asc','mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','List','User','Smtp','request','findOne','list','attachments','mapKey','rawAttributes','stringify','YYYY-MM-DD\x20HH:mm:ss','interaction','mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20','get','ShowMailAccount','bcc','applications','push','http','CmList','defaults','./mailAccount.socket','updatedAt','Attachments','Messages','GetMailAccount','ListId','Applications','message','catch','CmContact','error','update','orderBy','request\x20sent','close','result','attributes','difference','create','originTo','Start','where','MailAccount','findAll','priority','waitForTheAssignedAgent','lodash','from\x20is\x20mandatory','MailServerOut','options','attach','inReplyTo','info','register','MailAccount,\x20%s,\x20%s','then','../../mysqldb','MailApplication','UserId','limit','contact','debug','Attachment','omit','map','MailInteraction','Contacts','include','from','generate','isNil','MailAccount,\x20%s,\x20%s,\x20%s','MailMessage','length','jayson/promise','originCc','includes','autoclose','raw','body','createdAt','account','name','startRouting','*,*,*,*','moment','messageId','subject','../../rediscache','DESC'];(function(_0x3b814f,_0xa9bda6){const _0x4628ff=function(_0x481d6d){while(--_0x481d6d){_0x3b814f['push'](_0x3b814f['shift']());}};_0x4628ff(++_0xa9bda6);}(a397_0xa9bd,0x183));const a397_0x4628=function(_0x3b814f,_0xa9bda6){_0x3b814f=_0x3b814f-0x0;let _0x4628ff=a397_0xa9bd[_0x3b814f];return _0x4628ff;};const _0x206311=a397_0x4628;'use strict';const _=require(_0x206311('0x3b')),db=require(_0x206311('0x45'))['db'],logger=require(_0x206311('0x8'))('rpc'),{getSocket}=require(_0x206311('0x3')),socket=getSocket(),rs=require('randomstring'),moment=require(_0x206311('0x0')),jayson=require(_0x206311('0x57')),client=jayson['client'][_0x206311('0x1e')]({'port':0x232c});require(_0x206311('0x21'))[_0x206311('0x42')](socket);function respondWithRpcPromise(_0x481d6d,_0x55f2f5,_0x388756){return new Promise(function(_0x87adc0,_0x1f4dd5){const _0x3ccae1=a397_0x4628;return client[_0x3ccae1('0xf')](_0x481d6d,_0x388756)[_0x3ccae1('0x44')](function(_0x5f3841){const _0x51a8a4=_0x3ccae1;logger[_0x51a8a4('0x41')](_0x51a8a4('0x43'),_0x55f2f5,_0x51a8a4('0x2e')),logger[_0x51a8a4('0x4a')](_0x51a8a4('0x54'),_0x55f2f5,_0x51a8a4('0x2e'),JSON[_0x51a8a4('0x15')](_0x5f3841));if(_0x5f3841[_0x51a8a4('0x2b')]){if(_0x5f3841[_0x51a8a4('0x2b')]['code']===0x1f4)return logger[_0x51a8a4('0x2b')](_0x51a8a4('0x43'),_0x55f2f5,_0x5f3841['error'][_0x51a8a4('0x28')]),_0x1f4dd5(_0x5f3841[_0x51a8a4('0x2b')][_0x51a8a4('0x28')]);return logger[_0x51a8a4('0x2b')](_0x51a8a4('0x43'),_0x55f2f5,_0x5f3841['error'][_0x51a8a4('0x28')]),_0x87adc0(_0x5f3841[_0x51a8a4('0x2b')]['message']);}else logger[_0x51a8a4('0x41')]('MailAccount,\x20%s,\x20%s',_0x55f2f5,_0x51a8a4('0x2e')),_0x87adc0(_0x5f3841[_0x51a8a4('0x30')][_0x51a8a4('0x28')]);})[_0x3ccae1('0x29')](function(_0x590da4){const _0x306f58=_0x3ccae1;logger['error'](_0x306f58('0x43'),_0x55f2f5,_0x590da4),_0x1f4dd5(_0x590da4);});});}exports[_0x206311('0x25')]=function(_0x271ede){const _0x10a064=this;return new Promise(function(_0x2c1ab2,_0x339468){const _0x585eb2=a397_0x4628;return db[_0x585eb2('0x37')][_0x585eb2('0x38')]({'raw':_0x271ede[_0x585eb2('0x3e')]?_0x271ede[_0x585eb2('0x3e')][_0x585eb2('0x5b')]===undefined?!![]:![]:!![],'where':_0x271ede[_0x585eb2('0x3e')]?_0x271ede[_0x585eb2('0x3e')][_0x585eb2('0x36')]||null:null,'attributes':_0x271ede[_0x585eb2('0x3e')]?_0x271ede['options'][_0x585eb2('0x31')]||null:null,'limit':_0x271ede[_0x585eb2('0x3e')]?_0x271ede[_0x585eb2('0x3e')][_0x585eb2('0x48')]||null:null,'include':_0x271ede[_0x585eb2('0x3e')]?_0x271ede[_0x585eb2('0x3e')]['include']?_[_0x585eb2('0x4d')](_0x271ede[_0x585eb2('0x3e')]['include'],function(_0x1f5ed8){const _0x213e49=_0x585eb2;return{'model':db[_0x1f5ed8[_0x213e49('0x9')]],'as':_0x1f5ed8['as'],'attributes':_0x1f5ed8[_0x213e49('0x31')],'include':_0x1f5ed8[_0x213e49('0x50')]?_[_0x213e49('0x4d')](_0x1f5ed8[_0x213e49('0x50')],function(_0x431a86){const _0x48e29e=_0x213e49;return{'model':db[_0x431a86[_0x48e29e('0x9')]],'as':_0x431a86['as'],'attributes':_0x431a86[_0x48e29e('0x31')],'include':_0x431a86[_0x48e29e('0x50')]?_[_0x48e29e('0x4d')](_0x431a86['include'],function(_0x2770aa){const _0x300c9a=_0x48e29e;return{'model':db[_0x2770aa['model']],'as':_0x2770aa['as'],'attributes':_0x2770aa[_0x300c9a('0x31')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x3bdbe9){const _0x2d929f=_0x585eb2;logger[_0x2d929f('0x41')](_0x2d929f('0x25'),_0x271ede),logger[_0x2d929f('0x4a')](_0x2d929f('0x25'),_0x271ede,JSON[_0x2d929f('0x15')](_0x3bdbe9)),_0x2c1ab2(_0x3bdbe9);})[_0x585eb2('0x29')](function(_0xdc677b){const _0x4885bd=_0x585eb2;logger[_0x4885bd('0x2b')](_0x4885bd('0x25'),_0xdc677b[_0x4885bd('0x28')],_0x271ede),_0x339468(_0x10a064[_0x4885bd('0x2b')](0x1f4,_0xdc677b[_0x4885bd('0x28')]));});});},exports[_0x206311('0x1a')]=function(_0xeef068){const _0x2c7231=this;return new Promise(function(_0x32f32e,_0x5b7d8d){const _0x12590b=a397_0x4628;return db[_0x12590b('0x37')][_0x12590b('0x10')]({'raw':_0xeef068[_0x12590b('0x3e')]?_0xeef068[_0x12590b('0x3e')][_0x12590b('0x5b')]===undefined?!![]:![]:!![],'where':_0xeef068['options']?_0xeef068[_0x12590b('0x3e')]['where']||null:null,'attributes':_0xeef068[_0x12590b('0x3e')]?_0xeef068[_0x12590b('0x3e')]['attributes']||null:null,'include':_0xeef068[_0x12590b('0x3e')]?_0xeef068['options'][_0x12590b('0x50')]?_[_0x12590b('0x4d')](_0xeef068[_0x12590b('0x3e')]['include'],function(_0x3abf36){const _0xd1aca3=_0x12590b;return{'model':db[_0x3abf36[_0xd1aca3('0x9')]],'as':_0x3abf36['as'],'attributes':_0x3abf36[_0xd1aca3('0x31')],'include':_0x3abf36[_0xd1aca3('0x50')]?_[_0xd1aca3('0x4d')](_0x3abf36[_0xd1aca3('0x50')],function(_0x3f0e18){const _0x4f88ad=_0xd1aca3;return{'model':db[_0x3f0e18[_0x4f88ad('0x9')]],'as':_0x3f0e18['as'],'attributes':_0x3f0e18[_0x4f88ad('0x31')],'include':_0x3f0e18['include']?_[_0x4f88ad('0x4d')](_0x3f0e18[_0x4f88ad('0x50')],function(_0x471478){const _0x112033=_0x4f88ad;return{'model':db[_0x471478[_0x112033('0x9')]],'as':_0x471478['as'],'attributes':_0x471478[_0x112033('0x31')]};}):[]};}):[]};}):[]:[]})[_0x12590b('0x44')](function(_0xa80a1d){const _0x39a89a=_0x12590b;logger[_0x39a89a('0x41')]('ShowMailAccount',_0xeef068),logger[_0x39a89a('0x4a')](_0x39a89a('0x1a'),_0xeef068,JSON[_0x39a89a('0x15')](_0xa80a1d)),_0x32f32e(_0xa80a1d);})[_0x12590b('0x29')](function(_0x22cc65){const _0x582eb4=_0x12590b;logger[_0x582eb4('0x2b')](_0x582eb4('0x1a'),_0x22cc65['message'],_0xeef068),_0x5b7d8d(_0x2c7231[_0x582eb4('0x2b')](0x1f4,_0x22cc65['message']));});});},exports[_0x206311('0x7')]=function(_0x4bf74c){const _0x4e0f57=this;return new Promise(function(_0x5c66a5,_0x5905c0){const _0x571970=a397_0x4628,_0x5a7b6b={'body':_0x4bf74c[_0x571970('0x5c')],'channel':'mail'},_0x5efe38=_[_0x571970('0x32')](_['keys'](db['CmContact'][_0x571970('0x14')]),[_0x571970('0x5d'),_0x571970('0x22'),'CompanyId',_0x571970('0x26')]);let _0x5ee776=![];_0x4bf74c[_0x571970('0x5c')]['id']&&delete _0x4bf74c[_0x571970('0x5c')]['id'];if(_[_0x571970('0x53')](_0x4bf74c[_0x571970('0x5c')][_0x571970('0x51')]))return _0x5905c0(_0x4e0f57['error'](0x1f4,_0x571970('0x3c')));if(_[_0x571970('0x53')](_0x4bf74c[_0x571970('0x5c')]['body'])||_0x4bf74c[_0x571970('0x5c')][_0x571970('0x5c')]==='')return _0x5905c0(_0x4e0f57[_0x571970('0x2b')](0x1f4,'body\x20is\x20mandatory\x20and\x20not\x20empty'));if(_[_0x571970('0x53')](_0x4bf74c[_0x571970('0x5c')][_0x571970('0x13')]))return _0x5905c0(_0x4e0f57['error'](0x1f4,_0x571970('0x18')+_0x5efe38));if(!_[_0x571970('0x59')](_0x5efe38,_0x4bf74c[_0x571970('0x5c')]['mapKey']))return _0x5905c0(_0x4e0f57[_0x571970('0x2b')](0x1f4,_0x571970('0xb')+_0x5efe38));const _0x506612={};return _0x506612[_0x4bf74c[_0x571970('0x5c')]['mapKey']]=_0x4bf74c['body'][_0x571970('0x51')],db['MailAccount'][_0x571970('0x10')]({'where':{'id':_0x4bf74c['account']['id']},'include':[{'model':db[_0x571970('0x1f')],'as':'List','include':[{'model':db[_0x571970('0x2a')],'as':_0x571970('0x4f'),'where':_0x506612,'limit':0x1,'order':[['updatedAt',_0x571970('0x4')]]}]},{'model':db[_0x571970('0x46')],'as':_0x571970('0x27')},{'model':db[_0x571970('0x3d')],'as':_0x571970('0xe')}]})[_0x571970('0x44')](function(_0x1a55d3){const _0x245c85=_0x571970;if(_0x1a55d3&&_0x1a55d3[_0x245c85('0xc')]){const _0x292dea=_0x1a55d3[_0x245c85('0x19')]({'plain':!![]});_0x5a7b6b[_0x245c85('0x5e')]=_[_0x245c85('0x4c')](_0x292dea,[_0x245c85('0x27'),_0x245c85('0xc')]),_0x5a7b6b[_0x245c85('0x1c')]=_0x292dea[_0x245c85('0x27')],_0x5a7b6b[_0x245c85('0x11')]=_0x292dea['List'],_0x5a7b6b[_0x245c85('0x1c')]=_[_0x245c85('0x2d')](_0x5a7b6b[_0x245c85('0x1c')],[_0x245c85('0x39')],[_0x245c85('0xa')]);_0x5a7b6b['account']&&_0x5a7b6b['account'][_0x245c85('0x5a')]&&_0x5a7b6b[_0x245c85('0x1c')][_0x245c85('0x1d')]({'id':0x0,'priority':_0x5a7b6b[_0x245c85('0x1c')]['length']+0x1,'app':_0x245c85('0x2f'),'appdata':_0x245c85('0x5a'),'interval':_0x245c85('0x61')});_0x5a7b6b[_0x245c85('0x5e')][_0x245c85('0x27')]&&delete _0x5a7b6b['account']['Applications'];_0x5a7b6b[_0x245c85('0x5e')][_0x245c85('0xc')]&&delete _0x5a7b6b[_0x245c85('0x5e')][_0x245c85('0xc')];if(_0x292dea[_0x245c85('0xc')][_0x245c85('0x4f')][_0x245c85('0x56')])return _0x292dea[_0x245c85('0xc')][_0x245c85('0x4f')][0x0];const _0x212765=_[_0x245c85('0x20')](_0x4bf74c[_0x245c85('0x5c')],{'firstName':_0x4bf74c[_0x245c85('0x5c')][_0x245c85('0x51')],'ListId':_0x292dea[_0x245c85('0x26')]});return _0x212765[_0x4bf74c[_0x245c85('0x5c')][_0x245c85('0x13')]]=_0x4bf74c[_0x245c85('0x5c')][_0x245c85('0x51')],db[_0x245c85('0x2a')]['create'](_0x212765);}else throw new Error('List\x20not\x20found');})[_0x571970('0x44')](function(_0x1d32e9){const _0x28a79d=_0x571970;_0x5a7b6b[_0x28a79d('0x49')]=_0x1d32e9;if(_0x1d32e9){!_0x4bf74c[_0x28a79d('0x5c')]['message'][_0x28a79d('0x1')]&&(_0x4bf74c[_0x28a79d('0x5c')][_0x28a79d('0x28')]['messageId']=rs[_0x28a79d('0x52')]()+'\x20'+_0x4bf74c[_0x28a79d('0x5c')][_0x28a79d('0x28')][_0x28a79d('0x51')]);const _0x3010ed={'ContactId':_0x1d32e9['id'],'MailAccountId':_0x4bf74c['account']['id'],'inReplyTo':_0x4bf74c[_0x28a79d('0x5c')]['message'][_0x28a79d('0x1')],'to':_0x4bf74c[_0x28a79d('0x5c')][_0x28a79d('0x28')]['from'],'cc':_0x4bf74c[_0x28a79d('0x5c')][_0x28a79d('0x28')]['cc'],'subject':_0x4bf74c['body'][_0x28a79d('0x28')][_0x28a79d('0x2')],'attach':_0x4bf74c[_0x28a79d('0x5c')][_0x28a79d('0x28')][_0x28a79d('0x3f')],'lastMsgAt':moment()[_0x28a79d('0x5')](_0x28a79d('0x16')),'lastMsgDirection':'in','lastMsgBody':_0x4bf74c[_0x28a79d('0x5c')][_0x28a79d('0x5c')]};return db[_0x28a79d('0x4e')][_0x28a79d('0x10')]({'where':{'closed':![],'MailAccountId':_0x4bf74c['account']['id']},'include':[{'model':db[_0x28a79d('0x55')],'as':_0x28a79d('0x24'),'attributes':[_0x28a79d('0x1')],'where':{'messageId':_0x4bf74c[_0x28a79d('0x5c')][_0x28a79d('0x28')][_0x28a79d('0x40')]}}]})[_0x28a79d('0x44')](function(_0x16d103){const _0x5b1551=_0x28a79d;if(_0x16d103)return[_0x16d103,![]];return db[_0x5b1551('0x4e')][_0x5b1551('0x33')](_0x3010ed)['then'](function(_0xdced89){return[_0xdced89,!![]];});});}else throw new Error('Contact\x20not\x20found');})[_0x571970('0x44')](function([_0x2a1c4d,_0x58eb54]){const _0x10dc65=_0x571970;if(_0x2a1c4d)return _0x5ee776=_0x58eb54,!_0x58eb54?_0x2a1c4d[_0x10dc65('0x2c')]({'inReplyTo':_0x4bf74c[_0x10dc65('0x5c')][_0x10dc65('0x28')]['messageId'],'to':_0x4bf74c[_0x10dc65('0x5c')][_0x10dc65('0x28')][_0x10dc65('0x51')],'cc':_0x4bf74c[_0x10dc65('0x5c')][_0x10dc65('0x28')]['cc'],'subject':_0x4bf74c[_0x10dc65('0x5c')][_0x10dc65('0x28')]['subject'],'attach':_0x2a1c4d['attach']?_0x2a1c4d[_0x10dc65('0x3f')]:_0x4bf74c[_0x10dc65('0x5c')][_0x10dc65('0x28')]['attach'],'substatus':null,'substatusAt':moment()[_0x10dc65('0x5')]('YYYY-MM-DD\x20HH:mm:ss'),'lastMsgAt':moment()['format'](_0x10dc65('0x16')),'lastMsgDirection':'in','lastMsgBody':_0x4bf74c[_0x10dc65('0x5c')][_0x10dc65('0x5c')]}):_0x2a1c4d;})[_0x571970('0x44')](function(_0x52c1a9){const _0x1ad30a=_0x571970;return _0x5a7b6b[_0x1ad30a('0x17')]=_0x52c1a9['get']({'plain':!![]}),_0x5a7b6b['interaction']['created']=_0x5ee776,db[_0x1ad30a('0x55')][_0x1ad30a('0x33')]({'body':_0x4bf74c[_0x1ad30a('0x5c')][_0x1ad30a('0x5c')],'MailAccountId':_0x4bf74c[_0x1ad30a('0x5e')]['id'],'MailInteractionId':_0x52c1a9['id'],'direction':'in','ContactId':_0x5a7b6b['contact']['id'],'messageId':_0x4bf74c['body'][_0x1ad30a('0x28')][_0x1ad30a('0x1')],'from':_0x4bf74c[_0x1ad30a('0x5c')][_0x1ad30a('0x28')]['from'],'to':_0x4bf74c[_0x1ad30a('0x5c')][_0x1ad30a('0x28')]['to'],'cc':_0x4bf74c[_0x1ad30a('0x5c')][_0x1ad30a('0x28')]['cc'],'subject':_0x4bf74c[_0x1ad30a('0x5c')]['message'][_0x1ad30a('0x2')],'attach':_0x4bf74c[_0x1ad30a('0x5c')][_0x1ad30a('0x28')][_0x1ad30a('0x3f')],'Attachments':_0x4bf74c['body']['message'][_0x1ad30a('0x12')],'originTo':_0x4bf74c[_0x1ad30a('0x5c')]['message'][_0x1ad30a('0x34')],'originCc':_0x4bf74c['body'][_0x1ad30a('0x28')][_0x1ad30a('0x58')],'bcc':_0x4bf74c[_0x1ad30a('0x5c')][_0x1ad30a('0x28')][_0x1ad30a('0x1b')]},{'include':[{'model':db[_0x1ad30a('0x4b')],'as':_0x1ad30a('0x23')}]});})[_0x571970('0x44')](function(_0x56d838){const _0x277fac=_0x571970;_0x5a7b6b[_0x277fac('0x28')]=_0x56d838;if(_0x5a7b6b[_0x277fac('0x17')][_0x277fac('0x47')])return db[_0x277fac('0xd')][_0x277fac('0x10')]({'attributes':['id',_0x277fac('0x5f')],'where':{'id':_0x5a7b6b[_0x277fac('0x17')][_0x277fac('0x47')]}})['then'](function(_0x579ac9){const _0x458003=_0x277fac;return _0x579ac9&&_0x5a7b6b[_0x458003('0x1c')][_0x458003('0x6')]({'id':0x0,'priority':0x0,'app':'agent','appdata':_0x579ac9[_0x458003('0x5f')]+','+(_0x5a7b6b[_0x458003('0x5e')][_0x458003('0x3a')]||0xa),'interval':_0x458003('0x61')}),respondWithRpcPromise('Start',_0x458003('0x60'),_0x5a7b6b);});return respondWithRpcPromise(_0x277fac('0x35'),'startRouting',_0x5a7b6b);})[_0x571970('0x44')](function(_0xf750ff){_0x5c66a5(_0xf750ff);})[_0x571970('0x29')](function(_0x47187d){const _0x561401=_0x571970;_0x5905c0(_0x4e0f57['error'](0x1f4,_0x47187d[_0x561401('0x28')]));});});}; \ No newline at end of file diff --git a/server/api/mailAccount/mailAccount.socket.js b/server/api/mailAccount/mailAccount.socket.js index f1cec29..67692f6 100644 --- a/server/api/mailAccount/mailAccount.socket.js +++ b/server/api/mailAccount/mailAccount.socket.js @@ -1 +1 @@ -const a398_0x36dd=['./mailAccount.events','save','update'];(function(_0x27cabd,_0x36dd1e){const _0x105d89=function(_0x123561){while(--_0x123561){_0x27cabd['push'](_0x27cabd['shift']());}};_0x105d89(++_0x36dd1e);}(a398_0x36dd,0x1bf));const a398_0x105d=function(_0x27cabd,_0x36dd1e){_0x27cabd=_0x27cabd-0x0;let _0x105d89=a398_0x36dd[_0x27cabd];return _0x105d89;};const _0x3d7438=a398_0x105d;'use strict';const MailAccountEvents=require(_0x3d7438('0x0')),events=[_0x3d7438('0x1'),'remove',_0x3d7438('0x2')];function createListener(_0x123561,_0x14c130){return function(_0x55e4ca){_0x14c130['emit'](_0x123561,_0x55e4ca);};}exports['register']=function(_0x4b16d4){for(let _0x2b9efe=0x0,_0x26ab37=events['length'];_0x2b9efe<_0x26ab37;_0x2b9efe++){const _0xb6b7ef=events[_0x2b9efe],_0x56a9b0=createListener('mailAccount:'+_0xb6b7ef,_0x4b16d4);MailAccountEvents['on'](_0xb6b7ef,_0x56a9b0);}}; \ No newline at end of file +const a398_0x88d5=['length','save','remove','./mailAccount.events','update'];(function(_0x4ca554,_0x88d50e){const _0x37eeea=function(_0x8b4108){while(--_0x8b4108){_0x4ca554['push'](_0x4ca554['shift']());}};_0x37eeea(++_0x88d50e);}(a398_0x88d5,0x1e2));const a398_0x37ee=function(_0x4ca554,_0x88d50e){_0x4ca554=_0x4ca554-0x0;let _0x37eeea=a398_0x88d5[_0x4ca554];return _0x37eeea;};const _0x164e11=a398_0x37ee;'use strict';const MailAccountEvents=require(_0x164e11('0x1')),events=[_0x164e11('0x4'),_0x164e11('0x0'),_0x164e11('0x2')];function createListener(_0x8b4108,_0x2d680d){return function(_0x1c9bb0){_0x2d680d['emit'](_0x8b4108,_0x1c9bb0);};}exports['register']=function(_0x310ceb){const _0x1fb279=_0x164e11;for(let _0x12b216=0x0,_0x1824b8=events[_0x1fb279('0x3')];_0x12b216<_0x1824b8;_0x12b216++){const _0x1c9d84=events[_0x12b216],_0x393403=createListener('mailAccount:'+_0x1c9d84,_0x310ceb);MailAccountEvents['on'](_0x1c9d84,_0x393403);}}; \ No newline at end of file diff --git a/server/api/mailApplication/index.js b/server/api/mailApplication/index.js index ca75b89..1bc2780 100644 --- a/server/api/mailApplication/index.js +++ b/server/api/mailApplication/index.js @@ -1 +1 @@ -const a399_0x5801=['/:id','get','delete','isAuthenticated','update','destroy','../../components/auth/service','exports','./mailApplication.controller','put','express','show'];(function(_0x30eb4a,_0x5801ed){const _0xba3e6c=function(_0x4513e4){while(--_0x4513e4){_0x30eb4a['push'](_0x30eb4a['shift']());}};_0xba3e6c(++_0x5801ed);}(a399_0x5801,0x74));const a399_0xba3e=function(_0x30eb4a,_0x5801ed){_0x30eb4a=_0x30eb4a-0x0;let _0xba3e6c=a399_0x5801[_0x30eb4a];return _0xba3e6c;};const _0x1e92e1=a399_0xba3e;'use strict';const express=require(_0x1e92e1('0x2')),router=express['Router'](),auth=require(_0x1e92e1('0xa')),controller=require(_0x1e92e1('0x0'));router[_0x1e92e1('0x5')](_0x1e92e1('0x4'),auth[_0x1e92e1('0x7')](),controller[_0x1e92e1('0x3')]),router[_0x1e92e1('0x1')](_0x1e92e1('0x4'),auth[_0x1e92e1('0x7')](),controller[_0x1e92e1('0x8')]),router[_0x1e92e1('0x6')](_0x1e92e1('0x4'),auth[_0x1e92e1('0x7')](),controller[_0x1e92e1('0x9')]),module[_0x1e92e1('0xb')]=router; \ No newline at end of file +const a399_0x4937=['get','put','isAuthenticated','/:id','update','exports','./mailApplication.controller','show','delete','../../components/auth/service'];(function(_0x2038fa,_0x493762){const _0x4b155b=function(_0x587ace){while(--_0x587ace){_0x2038fa['push'](_0x2038fa['shift']());}};_0x4b155b(++_0x493762);}(a399_0x4937,0x9f));const a399_0x4b15=function(_0x2038fa,_0x493762){_0x2038fa=_0x2038fa-0x0;let _0x4b155b=a399_0x4937[_0x2038fa];return _0x4b155b;};const _0xa95c41=a399_0x4b15;'use strict';const express=require('express'),router=express['Router'](),auth=require(_0xa95c41('0x0')),controller=require(_0xa95c41('0x7'));router[_0xa95c41('0x1')](_0xa95c41('0x4'),auth[_0xa95c41('0x3')](),controller[_0xa95c41('0x8')]),router[_0xa95c41('0x2')](_0xa95c41('0x4'),auth[_0xa95c41('0x3')](),controller[_0xa95c41('0x5')]),router[_0xa95c41('0x9')]('/:id',auth[_0xa95c41('0x3')](),controller['destroy']),module[_0xa95c41('0x6')]=router; \ No newline at end of file diff --git a/server/api/mailApplication/mailApplication.attributes.js b/server/api/mailApplication/mailApplication.attributes.js index b56b418..918064b 100644 --- a/server/api/mailApplication/mailApplication.attributes.js +++ b/server/api/mailApplication/mailApplication.attributes.js @@ -1 +1 @@ -const a400_0x30c6=['exports','*,*,*,*','STRING','TEXT','noop'];(function(_0x74014c,_0x30c611){const _0x4557eb=function(_0x5ecf85){while(--_0x5ecf85){_0x74014c['push'](_0x74014c['shift']());}};_0x4557eb(++_0x30c611);}(a400_0x30c6,0x1db));const a400_0x4557=function(_0x74014c,_0x30c611){_0x74014c=_0x74014c-0x0;let _0x4557eb=a400_0x30c6[_0x74014c];return _0x4557eb;};const _0xd5cc78=a400_0x4557;'use strict';const Sequelize=require('sequelize');module[_0xd5cc78('0x0')]={'priority':{'type':Sequelize['INTEGER'],'allowNull':![]},'app':{'type':Sequelize[_0xd5cc78('0x2')],'allowNull':![],'defaultValue':_0xd5cc78('0x4')},'appdata':{'type':Sequelize[_0xd5cc78('0x3')]()},'description':{'type':Sequelize[_0xd5cc78('0x2')]},'interval':{'type':Sequelize[_0xd5cc78('0x2')],'defaultValue':_0xd5cc78('0x1')}}; \ No newline at end of file +const a400_0x1118=['TEXT','noop','STRING'];(function(_0x4703a5,_0x1118b2){const _0x3bb82e=function(_0x583636){while(--_0x583636){_0x4703a5['push'](_0x4703a5['shift']());}};_0x3bb82e(++_0x1118b2);}(a400_0x1118,0x1da));const a400_0x3bb8=function(_0x4703a5,_0x1118b2){_0x4703a5=_0x4703a5-0x0;let _0x3bb82e=a400_0x1118[_0x4703a5];return _0x3bb82e;};const _0x157755=a400_0x3bb8;'use strict';const Sequelize=require('sequelize');module['exports']={'priority':{'type':Sequelize['INTEGER'],'allowNull':![]},'app':{'type':Sequelize[_0x157755('0x2')],'allowNull':![],'defaultValue':_0x157755('0x1')},'appdata':{'type':Sequelize[_0x157755('0x0')]()},'description':{'type':Sequelize[_0x157755('0x2')]},'interval':{'type':Sequelize['STRING'],'defaultValue':'*,*,*,*'}}; \ No newline at end of file diff --git a/server/api/mailApplication/mailApplication.controller.js b/server/api/mailApplication/mailApplication.controller.js index 51b4cf0..a6de91e 100644 --- a/server/api/mailApplication/mailApplication.controller.js +++ b/server/api/mailApplication/mailApplication.controller.js @@ -1 +1 @@ -const a401_0x11dc=['includeAll','fields','stack','model','../../config/logger','query','length','send','error','MailApplication','catch','include','options','filters','api','destroy','rawAttributes','name','body','attributes','then','../../components/parsers/qs','show','keys','findOne','end','intersection','lodash','params','update','status'];(function(_0x18f39b,_0x11dc48){const _0x59860e=function(_0x2e653d){while(--_0x2e653d){_0x18f39b['push'](_0x18f39b['shift']());}};_0x59860e(++_0x11dc48);}(a401_0x11dc,0xc2));const a401_0x5986=function(_0x18f39b,_0x11dc48){_0x18f39b=_0x18f39b-0x0;let _0x59860e=a401_0x11dc[_0x18f39b];return _0x59860e;};const _0x13fbe2=a401_0x5986;'use strict';const _=require(_0x13fbe2('0x13')),qs=require(_0x13fbe2('0xd')),logger=require(_0x13fbe2('0x1b'))(_0x13fbe2('0x6')),db=require('../../mysqldb')['db'];function respondWithResult(_0x2e653d,_0x4062e9){return _0x4062e9=_0x4062e9||0xc8,function(_0x5afa8a){if(_0x5afa8a)return _0x2e653d['status'](_0x4062e9)['json'](_0x5afa8a);};}function saveUpdates(_0x272656){return function(_0x540685){const _0x239ad1=a401_0x5986;if(_0x540685)return _0x540685[_0x239ad1('0x15')](_0x272656)[_0x239ad1('0xc')](function(_0x41f2d5){return _0x41f2d5;});return null;};}function removeEntity(_0x597307){return function(_0x37c97c){const _0x42f46f=a401_0x5986;if(_0x37c97c)return _0x37c97c['destroy']()[_0x42f46f('0xc')](function(){const _0x5a78ba=_0x42f46f;_0x597307['status'](0xcc)[_0x5a78ba('0x11')]();});};}function handleEntityNotFound(_0x57eaf3){return function(_0x4c5b68){return!_0x4c5b68&&_0x57eaf3['sendStatus'](0x194),_0x4c5b68;};}function handleError(_0x1f63e4,_0x5f1f42){return _0x5f1f42=_0x5f1f42||0x1f4,function(_0x41f047){const _0x216e24=a401_0x5986;logger[_0x216e24('0x0')](_0x41f047[_0x216e24('0x19')]),_0x41f047['name']&&delete _0x41f047[_0x216e24('0x9')],_0x1f63e4[_0x216e24('0x16')](_0x5f1f42)[_0x216e24('0x1e')](_0x41f047);};}exports[_0x13fbe2('0xe')]=function(_0x5e034a,_0x475769){const _0x3676f0=_0x13fbe2;let _0x5c8a01={'raw':!![],'where':{'id':_0x5e034a[_0x3676f0('0x14')]['id']}};const _0x476415={};return _0x476415['model']=_[_0x3676f0('0xf')](db[_0x3676f0('0x1')][_0x3676f0('0x8')]),_0x476415[_0x3676f0('0x1c')]=_[_0x3676f0('0xf')](_0x5e034a[_0x3676f0('0x1c')]),_0x476415[_0x3676f0('0x5')]=_[_0x3676f0('0x12')](_0x476415[_0x3676f0('0x1a')],_0x476415['query']),_0x5c8a01[_0x3676f0('0xb')]=_['intersection'](_0x476415[_0x3676f0('0x1a')],qs[_0x3676f0('0x18')](_0x5e034a[_0x3676f0('0x1c')][_0x3676f0('0x18')])),_0x5c8a01[_0x3676f0('0xb')]=_0x5c8a01[_0x3676f0('0xb')][_0x3676f0('0x1d')]?_0x5c8a01[_0x3676f0('0xb')]:_0x476415['model'],_0x5e034a['query'][_0x3676f0('0x17')]&&(_0x5c8a01[_0x3676f0('0x3')]=[{'all':!![]}]),_0x5c8a01=_['merge']({},_0x5c8a01,_0x5e034a[_0x3676f0('0x4')]),db['MailApplication'][_0x3676f0('0x10')](_0x5c8a01)[_0x3676f0('0xc')](handleEntityNotFound(_0x475769,null))[_0x3676f0('0xc')](respondWithResult(_0x475769,null))['catch'](handleError(_0x475769,null));},exports[_0x13fbe2('0x15')]=function(_0x5cc1ea,_0x131f25){const _0x23ebcc=_0x13fbe2;return _0x5cc1ea[_0x23ebcc('0xa')]['id']&&delete _0x5cc1ea[_0x23ebcc('0xa')]['id'],db[_0x23ebcc('0x1')][_0x23ebcc('0x10')]({'where':{'id':_0x5cc1ea[_0x23ebcc('0x14')]['id']}})[_0x23ebcc('0xc')](handleEntityNotFound(_0x131f25,null))[_0x23ebcc('0xc')](saveUpdates(_0x5cc1ea[_0x23ebcc('0xa')],null))[_0x23ebcc('0xc')](respondWithResult(_0x131f25,null))[_0x23ebcc('0x2')](handleError(_0x131f25,null));},exports[_0x13fbe2('0x7')]=function(_0x1c7451,_0x4e7442){const _0x27bb3c=_0x13fbe2;return db[_0x27bb3c('0x1')]['findOne']({'where':{'id':_0x1c7451[_0x27bb3c('0x14')]['id']}})['then'](handleEntityNotFound(_0x4e7442,null))[_0x27bb3c('0xc')](removeEntity(_0x4e7442,null))[_0x27bb3c('0x2')](handleError(_0x4e7442,null));}; \ No newline at end of file +const a401_0x45a2=['keys','lodash','includeAll','MailApplication','json','send','error','catch','params','update','merge','destroy','filters','then','findOne','query','fields','rawAttributes','attributes','length','intersection','model','sendStatus','body','../../components/parsers/qs','name','show','../../mysqldb','status','stack'];(function(_0x12e8e7,_0x45a21c){const _0x2ec6aa=function(_0x549ddb){while(--_0x549ddb){_0x12e8e7['push'](_0x12e8e7['shift']());}};_0x2ec6aa(++_0x45a21c);}(a401_0x45a2,0x190));const a401_0x2ec6=function(_0x12e8e7,_0x45a21c){_0x12e8e7=_0x12e8e7-0x0;let _0x2ec6aa=a401_0x45a2[_0x12e8e7];return _0x2ec6aa;};const _0xd2d997=a401_0x2ec6;'use strict';const _=require(_0xd2d997('0x15')),qs=require(_0xd2d997('0xe')),logger=require('../../config/logger')('api'),db=require(_0xd2d997('0x11'))['db'];function respondWithResult(_0x549ddb,_0x4d8325){return _0x4d8325=_0x4d8325||0xc8,function(_0x7aa6cb){const _0x40674a=a401_0x2ec6;if(_0x7aa6cb)return _0x549ddb[_0x40674a('0x12')](_0x4d8325)[_0x40674a('0x18')](_0x7aa6cb);};}function saveUpdates(_0x58604f){return function(_0x3d5099){const _0x55e3ce=a401_0x2ec6;if(_0x3d5099)return _0x3d5099[_0x55e3ce('0x1d')](_0x58604f)[_0x55e3ce('0x3')](function(_0x1d2ff8){return _0x1d2ff8;});return null;};}function removeEntity(_0x3f7f2e){return function(_0x11cac6){const _0x30f22a=a401_0x2ec6;if(_0x11cac6)return _0x11cac6[_0x30f22a('0x1')]()['then'](function(){_0x3f7f2e['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x29b6d4){return function(_0x383ccd){const _0x53bed2=a401_0x2ec6;return!_0x383ccd&&_0x29b6d4[_0x53bed2('0xc')](0x194),_0x383ccd;};}function handleError(_0x2006c2,_0xff0934){return _0xff0934=_0xff0934||0x1f4,function(_0x5a35dd){const _0x44008f=a401_0x2ec6;logger[_0x44008f('0x1a')](_0x5a35dd[_0x44008f('0x13')]),_0x5a35dd['name']&&delete _0x5a35dd[_0x44008f('0xf')],_0x2006c2[_0x44008f('0x12')](_0xff0934)[_0x44008f('0x19')](_0x5a35dd);};}exports[_0xd2d997('0x10')]=function(_0x10177e,_0x144a77){const _0x18e248=_0xd2d997;let _0x3181f4={'raw':!![],'where':{'id':_0x10177e['params']['id']}};const _0x360307={};return _0x360307[_0x18e248('0xb')]=_[_0x18e248('0x14')](db[_0x18e248('0x17')][_0x18e248('0x7')]),_0x360307[_0x18e248('0x5')]=_[_0x18e248('0x14')](_0x10177e[_0x18e248('0x5')]),_0x360307[_0x18e248('0x2')]=_[_0x18e248('0xa')](_0x360307['model'],_0x360307[_0x18e248('0x5')]),_0x3181f4[_0x18e248('0x8')]=_[_0x18e248('0xa')](_0x360307[_0x18e248('0xb')],qs[_0x18e248('0x6')](_0x10177e['query']['fields'])),_0x3181f4[_0x18e248('0x8')]=_0x3181f4[_0x18e248('0x8')][_0x18e248('0x9')]?_0x3181f4[_0x18e248('0x8')]:_0x360307[_0x18e248('0xb')],_0x10177e[_0x18e248('0x5')][_0x18e248('0x16')]&&(_0x3181f4['include']=[{'all':!![]}]),_0x3181f4=_[_0x18e248('0x0')]({},_0x3181f4,_0x10177e['options']),db[_0x18e248('0x17')][_0x18e248('0x4')](_0x3181f4)[_0x18e248('0x3')](handleEntityNotFound(_0x144a77,null))[_0x18e248('0x3')](respondWithResult(_0x144a77,null))[_0x18e248('0x1b')](handleError(_0x144a77,null));},exports['update']=function(_0x508447,_0x4b70ad){const _0x51c8be=_0xd2d997;return _0x508447[_0x51c8be('0xd')]['id']&&delete _0x508447[_0x51c8be('0xd')]['id'],db['MailApplication'][_0x51c8be('0x4')]({'where':{'id':_0x508447[_0x51c8be('0x1c')]['id']}})[_0x51c8be('0x3')](handleEntityNotFound(_0x4b70ad,null))[_0x51c8be('0x3')](saveUpdates(_0x508447[_0x51c8be('0xd')],null))[_0x51c8be('0x3')](respondWithResult(_0x4b70ad,null))['catch'](handleError(_0x4b70ad,null));},exports[_0xd2d997('0x1')]=function(_0x575c31,_0x1553cf){const _0x3e468d=_0xd2d997;return db['MailApplication'][_0x3e468d('0x4')]({'where':{'id':_0x575c31['params']['id']}})[_0x3e468d('0x3')](handleEntityNotFound(_0x1553cf,null))[_0x3e468d('0x3')](removeEntity(_0x1553cf,null))[_0x3e468d('0x1b')](handleError(_0x1553cf,null));}; \ No newline at end of file diff --git a/server/api/mailApplication/mailApplication.model.js b/server/api/mailApplication/mailApplication.model.js index e8963dd..fc6d814 100644 --- a/server/api/mailApplication/mailApplication.model.js +++ b/server/api/mailApplication/mailApplication.model.js @@ -1 +1 @@ -const a402_0x11d6=['utf8mb4_unicode_ci','exports','MailApplication','utf8mb4','./mailApplication.attributes','define'];(function(_0x441d79,_0x11d630){const _0x3e58dd=function(_0x2ac8da){while(--_0x2ac8da){_0x441d79['push'](_0x441d79['shift']());}};_0x3e58dd(++_0x11d630);}(a402_0x11d6,0xa5));const a402_0x3e58=function(_0x441d79,_0x11d630){_0x441d79=_0x441d79-0x0;let _0x3e58dd=a402_0x11d6[_0x441d79];return _0x3e58dd;};const _0x3b996e=a402_0x3e58;'use strict';const attributes=require(_0x3b996e('0x1'));module[_0x3b996e('0x4')]=function(_0x2ac8da){const _0x97fe53=_0x3b996e,_0x229b74=_0x2ac8da[_0x97fe53('0x2')](_0x97fe53('0x5'),attributes,{'tableName':'mail_applications','paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x97fe53('0x0'),'collate':_0x97fe53('0x3')});return _0x229b74;}; \ No newline at end of file +const a402_0x132d=['MailApplication','exports','./mailApplication.attributes','utf8mb4','define','mail_applications'];(function(_0x2dc4b5,_0x132d80){const _0x1ca1a3=function(_0x278c82){while(--_0x278c82){_0x2dc4b5['push'](_0x2dc4b5['shift']());}};_0x1ca1a3(++_0x132d80);}(a402_0x132d,0x1bd));const a402_0x1ca1=function(_0x2dc4b5,_0x132d80){_0x2dc4b5=_0x2dc4b5-0x0;let _0x1ca1a3=a402_0x132d[_0x2dc4b5];return _0x1ca1a3;};const _0x87961e=a402_0x1ca1;'use strict';const attributes=require(_0x87961e('0x1'));module[_0x87961e('0x0')]=function(_0x278c82){const _0x40da24=_0x87961e,_0x463782=_0x278c82[_0x40da24('0x3')](_0x40da24('0x5'),attributes,{'tableName':_0x40da24('0x4'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x40da24('0x2'),'collate':'utf8mb4_unicode_ci'});return _0x463782;}; \ No newline at end of file diff --git a/server/api/mailApplication/mailApplication.rpc.js b/server/api/mailApplication/mailApplication.rpc.js index 00fe9d9..81adc8b 100644 --- a/server/api/mailApplication/mailApplication.rpc.js +++ b/server/api/mailApplication/mailApplication.rpc.js @@ -1 +1 @@ -const a403_0x58d2=['../../config/logger','../../mysqldb','options','MailApplication','error','attributes','info','debug','then','stringify','rpc','update','body','UpdateMailApplication','catch','message','raw','where'];(function(_0x37d262,_0x58d2f5){const _0x3e4457=function(_0x4aff1d){while(--_0x4aff1d){_0x37d262['push'](_0x37d262['shift']());}};_0x3e4457(++_0x58d2f5);}(a403_0x58d2,0x165));const a403_0x3e44=function(_0x37d262,_0x58d2f5){_0x37d262=_0x37d262-0x0;let _0x3e4457=a403_0x58d2[_0x37d262];return _0x3e4457;};const _0x1d1831=a403_0x3e44;'use strict';const db=require(_0x1d1831('0x4'))['db'],logger=require(_0x1d1831('0x3'))(_0x1d1831('0xd'));exports[_0x1d1831('0x10')]=function(_0x4aff1d){const _0x1f1428=this;return new Promise(function(_0x100635,_0x29c7fa){const _0x37d6e7=a403_0x3e44;return db[_0x37d6e7('0x6')][_0x37d6e7('0xe')](_0x4aff1d[_0x37d6e7('0xf')],{'raw':_0x4aff1d[_0x37d6e7('0x5')]?_0x4aff1d[_0x37d6e7('0x5')][_0x37d6e7('0x1')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x4aff1d['options']?_0x4aff1d['options'][_0x37d6e7('0x2')]||null:null,'attributes':_0x4aff1d[_0x37d6e7('0x5')]?_0x4aff1d['options'][_0x37d6e7('0x8')]||null:null,'limit':_0x4aff1d['options']?_0x4aff1d[_0x37d6e7('0x5')]['limit']||null:null})[_0x37d6e7('0xb')](function(_0x30ae70){const _0x404602=_0x37d6e7;logger[_0x404602('0x9')]('UpdateMailApplication',_0x4aff1d),logger[_0x404602('0xa')]('UpdateMailApplication',_0x4aff1d,JSON[_0x404602('0xc')](_0x30ae70)),_0x100635(_0x30ae70);})[_0x37d6e7('0x11')](function(_0x5404ff){const _0x22afef=_0x37d6e7;logger[_0x22afef('0x7')](_0x22afef('0x10'),_0x5404ff[_0x22afef('0x0')],_0x4aff1d),_0x29c7fa(_0x1f1428['error'](0x1f4,_0x5404ff['message']));});});}; \ No newline at end of file +const a403_0x4b0a=['where','error','stringify','catch','rpc','message','MailApplication','attributes','debug','limit','info','update','options','UpdateMailApplication'];(function(_0x26d2ba,_0x4b0a4f){const _0x183998=function(_0x5ba233){while(--_0x5ba233){_0x26d2ba['push'](_0x26d2ba['shift']());}};_0x183998(++_0x4b0a4f);}(a403_0x4b0a,0x1d9));const a403_0x1839=function(_0x26d2ba,_0x4b0a4f){_0x26d2ba=_0x26d2ba-0x0;let _0x183998=a403_0x4b0a[_0x26d2ba];return _0x183998;};const _0x363e66=a403_0x1839;'use strict';const db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x363e66('0x7'));exports[_0x363e66('0x2')]=function(_0x5ba233){const _0x5086f3=this;return new Promise(function(_0x11a593,_0x3622fe){const _0x12df99=a403_0x1839;return db[_0x12df99('0x9')][_0x12df99('0x0')](_0x5ba233['body'],{'raw':_0x5ba233[_0x12df99('0x1')]?_0x5ba233[_0x12df99('0x1')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x5ba233['options']?_0x5ba233[_0x12df99('0x1')][_0x12df99('0x3')]||null:null,'attributes':_0x5ba233[_0x12df99('0x1')]?_0x5ba233['options'][_0x12df99('0xa')]||null:null,'limit':_0x5ba233['options']?_0x5ba233[_0x12df99('0x1')][_0x12df99('0xc')]||null:null})['then'](function(_0x3e92cd){const _0x978fdc=_0x12df99;logger[_0x978fdc('0xd')](_0x978fdc('0x2'),_0x5ba233),logger[_0x978fdc('0xb')](_0x978fdc('0x2'),_0x5ba233,JSON[_0x978fdc('0x5')](_0x3e92cd)),_0x11a593(_0x3e92cd);})[_0x12df99('0x6')](function(_0x5438a0){const _0x3ffac2=_0x12df99;logger['error'](_0x3ffac2('0x2'),_0x5438a0[_0x3ffac2('0x8')],_0x5ba233),_0x3622fe(_0x5086f3[_0x3ffac2('0x4')](0x1f4,_0x5438a0[_0x3ffac2('0x8')]));});});}; \ No newline at end of file diff --git a/server/api/mailInteraction/index.js b/server/api/mailInteraction/index.js index 0f88ccd..3e888ca 100644 --- a/server/api/mailInteraction/index.js +++ b/server/api/mailInteraction/index.js @@ -1 +1 @@ -const a404_0x2972=['index','tracked','/:id/messages','mailinteraction:update','addTags','exports','get','mail','/:id/tags','isAuthenticated','describe','update','express','../../components/interaction/service','download','/:id','addMessage','delete','/describe','getMessages','post','Router'];(function(_0x8e25ab,_0x29720b){const _0x1da02b=function(_0xade32d){while(--_0xade32d){_0x8e25ab['push'](_0x8e25ab['shift']());}};_0x1da02b(++_0x29720b);}(a404_0x2972,0x117));const a404_0x1da0=function(_0x8e25ab,_0x29720b){_0x8e25ab=_0x8e25ab-0x0;let _0x1da02b=a404_0x2972[_0x8e25ab];return _0x1da02b;};const _0x3f3845=a404_0x1da0;'use strict';const express=require(_0x3f3845('0x13')),router=express[_0x3f3845('0x6')](),auth=require('../../components/auth/service'),interaction=require(_0x3f3845('0x14')),controller=require('./mailInteraction.controller');router[_0x3f3845('0xd')]('/',auth[_0x3f3845('0x10')](),controller[_0x3f3845('0x7')]),router[_0x3f3845('0xd')](_0x3f3845('0x3'),auth['isAuthenticated'](),controller[_0x3f3845('0x11')]),router[_0x3f3845('0xd')](_0x3f3845('0x0'),auth[_0x3f3845('0x10')](),controller['show']),router[_0x3f3845('0xd')]('/:id/messages',auth[_0x3f3845('0x10')](),controller[_0x3f3845('0x4')]),router[_0x3f3845('0xd')]('/:id/download',auth['isAuthenticated'](),controller[_0x3f3845('0x15')]),router[_0x3f3845('0x5')]('/',auth[_0x3f3845('0x10')](),controller['create']),router['post'](_0x3f3845('0x9'),auth[_0x3f3845('0x10')](),controller[_0x3f3845('0x1')]),router[_0x3f3845('0x5')](_0x3f3845('0xf'),auth['isAuthenticated'](),interaction[_0x3f3845('0x8')](_0x3f3845('0xe'),'mailinteraction:addtags'),controller[_0x3f3845('0xb')]),router['put']('/:id',auth[_0x3f3845('0x10')](),interaction[_0x3f3845('0x8')](_0x3f3845('0xe'),_0x3f3845('0xa')),controller[_0x3f3845('0x12')]),router[_0x3f3845('0x2')]('/:id',auth[_0x3f3845('0x10')](),interaction[_0x3f3845('0x8')](_0x3f3845('0xe'),'mailinteraction:destroy'),controller['destroy']),router[_0x3f3845('0x2')](_0x3f3845('0xf'),auth[_0x3f3845('0x10')](),controller['removeTags']),module[_0x3f3845('0xc')]=router; \ No newline at end of file +const a404_0x1c09=['getMessages','mailinteraction:update','addTags','download','/:id/messages','create','get','delete','Router','/describe','mailinteraction:destroy','../../components/interaction/service','removeTags','post','destroy','express','exports','mailinteraction:addtags','/:id','show','put','/:id/tags','tracked','isAuthenticated','../../components/auth/service','addMessage','mail','update','/:id/download'];(function(_0xdbf340,_0x1c0991){const _0x3a85a7=function(_0x31554f){while(--_0x31554f){_0xdbf340['push'](_0xdbf340['shift']());}};_0x3a85a7(++_0x1c0991);}(a404_0x1c09,0x1b4));const a404_0x3a85=function(_0xdbf340,_0x1c0991){_0xdbf340=_0xdbf340-0x0;let _0x3a85a7=a404_0x1c09[_0xdbf340];return _0x3a85a7;};const _0x59e290=a404_0x3a85;'use strict';const express=require(_0x59e290('0xe')),router=express[_0x59e290('0x7')](),auth=require(_0x59e290('0x17')),interaction=require(_0x59e290('0xa')),controller=require('./mailInteraction.controller');router[_0x59e290('0x5')]('/',auth[_0x59e290('0x16')](),controller['index']),router[_0x59e290('0x5')](_0x59e290('0x8'),auth[_0x59e290('0x16')](),controller['describe']),router[_0x59e290('0x5')]('/:id',auth[_0x59e290('0x16')](),controller[_0x59e290('0x12')]),router[_0x59e290('0x5')](_0x59e290('0x3'),auth[_0x59e290('0x16')](),controller[_0x59e290('0x1c')]),router['get'](_0x59e290('0x1b'),auth[_0x59e290('0x16')](),controller[_0x59e290('0x2')]),router[_0x59e290('0xc')]('/',auth['isAuthenticated'](),controller[_0x59e290('0x4')]),router[_0x59e290('0xc')](_0x59e290('0x3'),auth[_0x59e290('0x16')](),controller[_0x59e290('0x18')]),router['post'](_0x59e290('0x14'),auth[_0x59e290('0x16')](),interaction['tracked'](_0x59e290('0x19'),_0x59e290('0x10')),controller[_0x59e290('0x1')]),router[_0x59e290('0x13')](_0x59e290('0x11'),auth[_0x59e290('0x16')](),interaction[_0x59e290('0x15')]('mail',_0x59e290('0x0')),controller[_0x59e290('0x1a')]),router[_0x59e290('0x6')](_0x59e290('0x11'),auth['isAuthenticated'](),interaction[_0x59e290('0x15')](_0x59e290('0x19'),_0x59e290('0x9')),controller[_0x59e290('0xd')]),router[_0x59e290('0x6')](_0x59e290('0x14'),auth['isAuthenticated'](),controller[_0x59e290('0xb')]),module[_0x59e290('0xf')]=router; \ No newline at end of file diff --git a/server/api/mailInteraction/mailInteraction.attributes.js b/server/api/mailInteraction/mailInteraction.attributes.js index 3a028af..b1edc83 100644 --- a/server/api/mailInteraction/mailInteraction.attributes.js +++ b/server/api/mailInteraction/mailInteraction.attributes.js @@ -1 +1 @@ -const a405_0x5971=['STRING','BOOLEAN','long','ENUM','TEXT','sequelize','exports','out','DATE'];(function(_0x3aa949,_0x5971e2){const _0x51edc3=function(_0x2391da){while(--_0x2391da){_0x3aa949['push'](_0x3aa949['shift']());}};_0x51edc3(++_0x5971e2);}(a405_0x5971,0xf6));const a405_0x51ed=function(_0x3aa949,_0x5971e2){_0x3aa949=_0x3aa949-0x0;let _0x51edc3=a405_0x5971[_0x3aa949];return _0x51edc3;};const _0x251faf=a405_0x51ed;'use strict';const Sequelize=require(_0x251faf('0x2'));module[_0x251faf('0x3')]={'closed':{'type':Sequelize[_0x251faf('0x7')],'defaultValue':![]},'closedAt':{'type':Sequelize[_0x251faf('0x5')]},'disposition':{'type':Sequelize['STRING']},'secondDisposition':{'type':Sequelize['STRING']},'thirdDisposition':{'type':Sequelize[_0x251faf('0x6')]},'note':{'type':Sequelize[_0x251faf('0x6')]},'inReplyTo':{'type':Sequelize[_0x251faf('0x6')](0x1fe)},'to':{'type':Sequelize[_0x251faf('0x6')]},'cc':{'type':Sequelize['TEXT'](_0x251faf('0x8'))},'subject':{'type':Sequelize['TEXT']()},'attach':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'read1stAt':{'type':Sequelize[_0x251faf('0x5')]},'substatus':{'type':Sequelize[_0x251faf('0x6')](0x3c)},'substatusAt':{'type':Sequelize[_0x251faf('0x5')]},'firstMsgDirection':{'type':Sequelize['ENUM']('in',_0x251faf('0x4')),'defaultValue':'in','allowNull':![]},'lastMsgAt':{'type':Sequelize['DATE']},'lastMsgDirection':{'type':Sequelize[_0x251faf('0x0')]('in',_0x251faf('0x4')),'defaultValue':'in','allowNull':![]},'lastMsgBody':{'type':Sequelize[_0x251faf('0x1')]('long')},'lastMsgText':{'type':Sequelize[_0x251faf('0x1')](_0x251faf('0x8'))}}; \ No newline at end of file +const a405_0xfed3=['out','long','exports','DATE','STRING','sequelize','TEXT','BOOLEAN'];(function(_0x561cc1,_0xfed3fc){const _0x25514a=function(_0x29ebfe){while(--_0x29ebfe){_0x561cc1['push'](_0x561cc1['shift']());}};_0x25514a(++_0xfed3fc);}(a405_0xfed3,0xa7));const a405_0x2551=function(_0x561cc1,_0xfed3fc){_0x561cc1=_0x561cc1-0x0;let _0x25514a=a405_0xfed3[_0x561cc1];return _0x25514a;};const _0x1346a2=a405_0x2551;'use strict';const Sequelize=require(_0x1346a2('0x6'));module[_0x1346a2('0x3')]={'closed':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'closedAt':{'type':Sequelize[_0x1346a2('0x4')]},'disposition':{'type':Sequelize['STRING']},'secondDisposition':{'type':Sequelize[_0x1346a2('0x5')]},'thirdDisposition':{'type':Sequelize[_0x1346a2('0x5')]},'note':{'type':Sequelize['STRING']},'inReplyTo':{'type':Sequelize[_0x1346a2('0x5')](0x1fe)},'to':{'type':Sequelize['STRING']},'cc':{'type':Sequelize['TEXT'](_0x1346a2('0x2'))},'subject':{'type':Sequelize[_0x1346a2('0x7')]()},'attach':{'type':Sequelize[_0x1346a2('0x0')],'defaultValue':![]},'read1stAt':{'type':Sequelize[_0x1346a2('0x4')]},'substatus':{'type':Sequelize['STRING'](0x3c)},'substatusAt':{'type':Sequelize['DATE']},'firstMsgDirection':{'type':Sequelize['ENUM']('in',_0x1346a2('0x1')),'defaultValue':'in','allowNull':![]},'lastMsgAt':{'type':Sequelize[_0x1346a2('0x4')]},'lastMsgDirection':{'type':Sequelize['ENUM']('in',_0x1346a2('0x1')),'defaultValue':'in','allowNull':![]},'lastMsgBody':{'type':Sequelize[_0x1346a2('0x7')](_0x1346a2('0x2'))},'lastMsgText':{'type':Sequelize[_0x1346a2('0x7')](_0x1346a2('0x2'))}}; \ No newline at end of file diff --git a/server/api/mailInteraction/mailInteraction.controller.js b/server/api/mailInteraction/mailInteraction.controller.js index 6829dc1..b6d9c3d 100644 --- a/server/api/mailInteraction/mailInteraction.controller.js +++ b/server/api/mailInteraction/mailInteraction.controller.js @@ -1 +1 @@ -const a406_0x3fac=['html-to-text','user_has_mail_interactions','bcc','Bcc','i.ContactId','unreadMessages','omit','options','../../mysqldb','operator','conditions','i.MailAccountId\x20IN\x20?','api','addMessage','getMailAccounts','i.closed','Setting','DESC','nolimit','findAll','Messages','ContactId','existsSync','having','ids','filters','`unreadMessages`\x20>\x200','tag','group','keyBy','Tag','params','`\x20=\x200','Contact.phone','Contact.lastName','c.fax','Attachments','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL','path','body','expr','send','rawAttributes','read','setTags','Tags','ddd,\x20DD\x20MMM\x20YYYY\x20HH:mm:ss\x20ZZ','i.UserId','sqlOperator','\x27\x27\x27\x27','isNumeric','limit','destroy','filter','`unreadMessages`\x20=\x200','c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?','MailAccountId','attributes','i.subject','type','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','Account.mandatoryDisposition','c.firstName','Account.key','Users','resolve','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','Owner.fullname','order','set','c.lastName','i.createdAt\x20BETWEEN\x20?\x20AND\x20?','end','ui.MailInteractionId','sendStatus','u.id','i.updatedAt','getFullTextValue','t.id\x20=\x20it.TagId','get','join','\x20IS\x20NULL','i.to','format','lodash','keys','toString','trimStart','root','transcript-%d-%s.zip','sort','zip-dir','util','describe','i.MailAccountId\x20IS\x20NOT\x20NULL','$lte','rimraf','o.fullname','attachments','QueryTypes','GROUP_CONCAT(DISTINCT\x20t.id)','a.id\x20=\x20i.MailAccountId','getMessages','users','MailInteractionId','update','sequelize','tools_tags','./mailInteraction.socket','register','MATCH\x20(me.plainBody,\x20me.subject)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','removeTags','i.substatus','journey','tmp','lastMsgBody','find','i.id','value','Sequelize','text','me.MailInteractionId\x20=\x20i.id','undefined','groupBy','parse','status','cm_contacts','select','$substring','clone','from','model','split','i.attach','writeFileSync','subject','mkdirSync','i.lastMsgDirection','build','fieldName','plainBody','c.email','UserId','Attachment','lastMsgText','Contact','`\x20>\x200','field','parseSearch','index','error','query','a.mandatoryDisposition','isArray','union','like','pick','MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','all','Owner.internal','then','fields','where','rows','c.mobile','findOne','user','Contact.mobile','mail_messages','json','length','push','include','enableEmailPreview','download','compact','eml-format','isEmpty','includeAll','MATCH\x20(i.to,\x20i.subject)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','headers','createdAt','readFileSync','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','left_join','files','$gte','unlinkSync','map','mail_interactions','name','search','some','MailMessage','null','TagIds','message%d.eml','offset','merge','concat','catch','replace','a.key','Contact.firstName','server','fullname','basename','intersection','u.fullname','addTags','key','gte','i.createdAt','../../components/parsers/advancedSearch','it.MailInteractionId\x20=\x20i.id','color','Contact.email','forEach','each','buildExpression','u.id\x20=\x20ui.UserId','i.lastMsgAt','ui.MailInteractionId\x20IN\x20?','count','User','emit','start','MailInteraction','log','mailInteractionTags:save'];(function(_0x512c79,_0x3fac1c){const _0x415fdf=function(_0x16ef5a){while(--_0x16ef5a){_0x512c79['push'](_0x512c79['shift']());}};_0x415fdf(++_0x3fac1c);}(a406_0x3fac,0xe2));const a406_0x415f=function(_0x512c79,_0x3fac1c){_0x512c79=_0x512c79-0x0;let _0x415fdf=a406_0x3fac[_0x512c79];return _0x415fdf;};const _0x567c49=a406_0x415f;'use strict';const emlformat=require(_0x567c49('0xb4')),rimraf=require(_0x567c49('0x64')),zipdir=require(_0x567c49('0x5f')),moment=require('moment'),util=require(_0x567c49('0x60')),path=require(_0x567c49('0x2a')),fs=require('fs'),_=require(_0x567c49('0x58')),squel=require('squel'),{htmlToText}=require(_0x567c49('0x4')),{getSocket}=require('../../rediscache'),socket=getSocket(),qs=require('../../components/parsers/qs'),as=require(_0x567c49('0xd9')),logger=require('../../config/logger')(_0x567c49('0x10')),config=require('../../config/environment'),db=require(_0x567c49('0xc'))['db'],{Op}=require(_0x567c49('0x6e'));require(_0x567c49('0x70'))[_0x567c49('0x71')](socket);function respondWithStatusCode(_0x16ef5a,_0x222ccf){return _0x222ccf=_0x222ccf||0xcc,function(_0x301237){if(_0x301237)return _0x16ef5a['sendStatus'](_0x222ccf);return _0x16ef5a['status'](_0x222ccf)['end']();};}function respondWithResult(_0x35abd5,_0x22ab21){return _0x22ab21=_0x22ab21||0xc8,function(_0x53bace){const _0x6d38c1=a406_0x415f;if(_0x53bace)return _0x35abd5[_0x6d38c1('0x81')](_0x22ab21)[_0x6d38c1('0xad')](_0x53bace);};}function respondWithFilteredResult(_0x3a2554,_0x3069a1){return function(_0x1eabd5){const _0x380dd7=a406_0x415f;if(_0x1eabd5){const _0x214e4f=_0x1eabd5[_0x380dd7('0xe3')],_0x2c7edb=_0x3069a1['offset'];let _0x2d2d1d=_0x3069a1[_0x380dd7('0xc9')]+_0x3069a1[_0x380dd7('0x37')],_0x37fcd9;return _0x2d2d1d>=_0x214e4f?(_0x2d2d1d=_0x214e4f,_0x37fcd9=0xc8):_0x37fcd9=0xce,_0x3a2554[_0x380dd7('0x81')](_0x37fcd9),_0x3a2554[_0x380dd7('0x49')]('Content-Range',_0x2c7edb+'-'+_0x2d2d1d+'/'+_0x214e4f)['json'](_0x1eabd5);}return null;};}function saveUpdates(_0x415b39){return function(_0x4738fc){const _0x463205=a406_0x415f;if(_0x4738fc)return _0x4738fc[_0x463205('0x6d')](_0x415b39)['then'](function(_0x1408e1){return _0x1408e1;});return null;};}function removeEntity(_0x1b80a0){return function(_0x115605){const _0x252608=a406_0x415f;if(_0x115605)return _0x115605[_0x252608('0x38')]()['then'](function(){const _0x349f04=_0x252608;_0x1b80a0[_0x349f04('0x81')](0xcc)[_0x349f04('0x4c')]();});};}function handleEntityNotFound(_0x48af84){return function(_0x2e9dd3){const _0x4e8328=a406_0x415f;return!_0x2e9dd3&&_0x48af84[_0x4e8328('0x4e')](0x194),_0x2e9dd3;};}function handleError(_0xf956bb,_0x5e6562){return _0x5e6562=_0x5e6562||0x1f4,function(_0x14206f){const _0x5e9ce2=a406_0x415f;logger[_0x5e9ce2('0x9a')](_0x14206f['stack']),_0x14206f[_0x5e9ce2('0xc2')]&&delete _0x14206f[_0x5e9ce2('0xc2')],_0xf956bb[_0x5e9ce2('0x81')](_0x5e6562)[_0x5e9ce2('0x2d')](_0x14206f);};}function getInteractionUsers(_0x38e9f8,_0xf793ac){return new Promise(function(_0x50dc6a,_0x302eee){const _0x4eee79=a406_0x415f;try{_0xf793ac[_0x38e9f8['id']]&&(_0x38e9f8[_0x4eee79('0x44')]=_[_0x4eee79('0xc0')](_0xf793ac[_0x38e9f8['id']],function(_0x2a381e){const _0x12b6d5=_0x4eee79;return{'id':_0x2a381e['id'],'fullname':_0x2a381e[_0x12b6d5('0xd1')]};}));}catch(_0x3aba5e){_0x302eee(_0x3aba5e);}_0x50dc6a(_0x38e9f8);});}function getInteractionTags(_0x5ec96b,_0x597aed){return new Promise(function(_0x52a1bf,_0x26f210){const _0x145bb0=a406_0x415f;try{_0x5ec96b[_0x145bb0('0xc7')]&&(_0x5ec96b[_0x145bb0('0x31')]=[],_0x5ec96b['TagIds'][_0x145bb0('0x88')](',')[_0x145bb0('0xdd')](function(_0x2a1484){_0x5ec96b['Tags']['push'](_0x597aed[_0x2a1484]);})),delete _0x5ec96b[_0x145bb0('0xc7')];}catch(_0x2f784a){_0x26f210(_0x2f784a);}_0x52a1bf(_0x5ec96b);});}function getLastMessageText(_0x58fccd){return new Promise(function(_0x5c1f92,_0x379511){const _0x45964e=a406_0x415f;return db[_0x45964e('0x1')][_0x45964e('0xa9')]({'where':{'id':_0x58fccd['id']},'attributes':[_0x45964e('0x77'),_0x45964e('0x94')],'raw':!![]})[_0x45964e('0xa4')](function(_0x8b64a){const _0xcae6da=_0x45964e;!_0x8b64a[_0xcae6da('0x94')]?_0x58fccd['lastMsgText']=_[_0xcae6da('0x5b')](htmlToText(_0x8b64a[_0xcae6da('0x77')],{'preserveNewlines':!![],'singleNewLineParagraphs':!![],'uppercaseHeadings':![],'noLinkBrackets':!![],'ignoreImage':!![]})):_0x58fccd[_0xcae6da('0x94')]=_0x8b64a[_0xcae6da('0x94')],_0x5c1f92(_0x58fccd);})[_0x45964e('0xcc')](function(_0x2941d7){_0x379511(_0x2941d7);});});}function updateMailInteraction(_0x5557eb,_0x5ba816,_0x5721a8,_0x21b265){return new Promise(function(_0x1089f5,_0x4eacaa){const _0xa608f2=a406_0x415f;return getInteractionUsers(_0x5557eb,_0x5721a8)[_0xa608f2('0xa4')](function(_0x534e19){return getInteractionTags(_0x534e19,_0x5ba816);})[_0xa608f2('0xa4')](function(_0x13b464){_0x21b265?_0x1089f5(getLastMessageText(_0x13b464)):_0x1089f5(_0x13b464);})[_0xa608f2('0xcc')](function(_0x43b5d5){_0x4eacaa(_0x43b5d5);});});}exports[_0x567c49('0x99')]=function(_0x432b9d,_0x1168bc){const _0x765819=_0x567c49,_0x4b00fc={},_0x223975={},_0x583fe3={'count':0x0,'rows':[]},_0x446d14=_[_0x765819('0xc0')](db['MailInteraction']['rawAttributes'],function(_0x6087f4){const _0x5036a9=_0x765819;return{'name':_0x6087f4[_0x5036a9('0x8f')],'type':_0x6087f4['type'][_0x5036a9('0xd6')]};});_0x223975[_0x765819('0x87')]=_['map'](_0x446d14,_0x765819('0xc2')),_0x223975[_0x765819('0x9b')]=_['keys'](_0x432b9d[_0x765819('0x9b')]),_0x223975[_0x765819('0x1d')]=_[_0x765819('0xd3')](_0x223975[_0x765819('0x87')],_0x223975[_0x765819('0x9b')]),_0x4b00fc['attributes']=_['intersection'](_0x223975[_0x765819('0x87')],qs['fields'](_0x432b9d[_0x765819('0x9b')][_0x765819('0xa5')])),_0x4b00fc[_0x765819('0x3d')]=_0x4b00fc['attributes'][_0x765819('0xae')]?_0x4b00fc[_0x765819('0x3d')]:_0x223975['model'];typeof _0x432b9d[_0x765819('0x9b')][_0x765819('0x16')]===_0x765819('0x7e')&&(_0x4b00fc[_0x765819('0x37')]=qs[_0x765819('0x37')](_0x432b9d[_0x765819('0x9b')][_0x765819('0x37')]),_0x4b00fc[_0x765819('0xc9')]=qs['offset'](_0x432b9d[_0x765819('0x9b')][_0x765819('0xc9')]));_0x4b00fc[_0x765819('0x48')]=qs['sort'](_0x432b9d[_0x765819('0x9b')][_0x765819('0x5e')]),_0x4b00fc[_0x765819('0xa6')]=qs[_0x765819('0x1d')](_[_0x765819('0xa0')](_0x432b9d['query'],_0x223975['filters']),_0x446d14);let _0xdad73a=[];const _0x75090d=squel[_0x765819('0x83')]()[_0x765819('0x97')]('id')[_0x765819('0x97')](_0x765819('0xc2'))[_0x765819('0x97')](_0x765819('0xdb'))['from'](_0x765819('0x6f')),_0x2ea691=squel[_0x765819('0x83')]()[_0x765819('0x97')](_0x765819('0x4f'))['field'](_0x765819('0xd4'))[_0x765819('0x97')](_0x765819('0x4d'))['from'](_0x765819('0x5'),'ui')[_0x765819('0xbc')]('users','u',_0x765819('0xe0')),_0x4c95d1=squel[_0x765819('0x83')]()[_0x765819('0x86')](_0x765819('0xc1'),'i')['left_join'](_0x765819('0x82'),'c',_0x765819('0x29'))['left_join'](_0x765819('0x6b'),'o','o.id\x20=\x20i.UserId')['left_join']('mail_accounts','a',_0x765819('0x69'))[_0x765819('0xbc')](_0x765819('0xac'),'me',_0x765819('0x7d'))['left_join']('mail_interaction_has_tags','it',_0x765819('0xda'))[_0x765819('0xbc')]('tools_tags','t',_0x765819('0x52')),_0x5e9ba5=squel[_0x765819('0x2c')]();let _0xda6982=[];const _0x4e3659=squel[_0x765819('0x2c')]();let _0x2ae6b0;if(_0x432b9d[_0x765819('0x9b')]['search']){_0x2ae6b0=as[_0x765819('0x98')](_0x432b9d[_0x765819('0x9b')][_0x765819('0xc3')]);const _0x284742=_0x2ae6b0[_0x765819('0x34')];for(let _0x64e270=0x0;_0x64e270<_0x2ae6b0[_0x765819('0xe')][_0x765819('0xae')];_0x64e270++){const _0x2252f7=_0x2ae6b0[_0x765819('0xe')][_0x64e270],_0x30807e='i';let _0xe7c81e,_0x1c614f=_[_0x765819('0x78')](_0x446d14,['name',_0x2252f7['field']]);if(!_0x1c614f)switch(_0x2252f7[_0x765819('0x97')]){case _0x765819('0x9'):_0x2252f7[_0x765819('0x7a')]==0x1?_0x4c95d1[_0x765819('0x1b')]('`'+_0x2252f7[_0x765819('0x97')]+_0x765819('0x24')):_0x4c95d1[_0x765819('0x1b')]('`'+_0x2252f7[_0x765819('0x97')]+_0x765819('0x96'));break;case _0x765819('0x95'):if(_0x2252f7['operator']===_0x765819('0x84')){if(_0x2252f7[_0x765819('0x7a')][_0x765819('0x88')]('\x20')[_0x765819('0xae')]>0x1)_0x5e9ba5[_0x284742](_0x765819('0xa1'),qs[_0x765819('0x51')](_0x2252f7[_0x765819('0x7a')]),null);else{const _0x5e1314='%'+_0x2252f7[_0x765819('0x7a')]+'%';_0x5e9ba5[_0x284742](_0x765819('0x3b'),_0x5e1314,_0x5e1314,_0x5e1314);}}else _0x1c614f=_['find'](_0x446d14,[_0x765819('0xc2'),_0x765819('0x19')]),_0x2252f7['field']=_0x765819('0x19'),_0xe7c81e=as[_0x765819('0xdf')](_0x30807e,_0x1c614f[_0x765819('0x3f')],_0x2252f7),_0x5e9ba5[_0x284742](_0xe7c81e[_0x765819('0x7c')],_0xe7c81e['value'][_0x765819('0x0')],_0xe7c81e[_0x765819('0x7a')]['end']);break;case _0x765819('0x22'):{const _0x54871a=_0x2252f7[_0x765819('0x7a')]['split'](',')['map'](function(_0x3f1402){return Number(_0x3f1402);});_0x54871a[_0x765819('0xdd')](function(_0x2c7f84){const _0xddbbaa=_0x765819;_0x4e3659['or'](_0xddbbaa('0xbb'),'%,'+_0x2c7f84+',%');}),_0xda6982=_[_0x765819('0x9e')](_0xda6982,_0x54871a);}break;case _0x765819('0xe4'):_0x2252f7[_0x765819('0xd')]===_0x765819('0x84')?_0x5e9ba5[_0x284742](_0x765819('0x46'),'%'+_0x2252f7[_0x765819('0x7a')]+'%',null):(_0x1c614f=_[_0x765819('0x78')](_0x446d14,['name',_0x765819('0x92')]),_0x2252f7[_0x765819('0x97')]='UserId',_0xe7c81e=as[_0x765819('0xdf')](_0x30807e,_0x1c614f[_0x765819('0x3f')],_0x2252f7),_0x5e9ba5[_0x284742](_0xe7c81e[_0x765819('0x7c')],_0xe7c81e[_0x765819('0x7a')][_0x765819('0x0')],_0xe7c81e[_0x765819('0x7a')][_0x765819('0x4c')]));break;case _0x765819('0x90'):_0xe7c81e=as[_0x765819('0xdf')]('me',null,_0x2252f7),_0x5e9ba5[_0x284742](_0xe7c81e[_0x765819('0x7c')],_0xe7c81e[_0x765819('0x7a')]['start'],_0xe7c81e[_0x765819('0x7a')][_0x765819('0x4c')]);break;}else _0xe7c81e=as[_0x765819('0xdf')](_0x30807e,_0x1c614f['type'],_0x2252f7),_0x5e9ba5[_0x284742](_0xe7c81e[_0x765819('0x7c')],_0xe7c81e[_0x765819('0x7a')]['start'],_0xe7c81e[_0x765819('0x7a')][_0x765819('0x4c')]);}}else{const _0x35d7cd=_(_0x432b9d[_0x765819('0x9b')])[_0x765819('0x59')]()[_0x765819('0xc0')](function(_0x372d79){const _0x28b5ab=_0x765819;return _[_0x28b5ab('0xc4')](_0x446d14,['name',_0x372d79])?_0x372d79:undefined;})[_0x765819('0xb3')]()[_0x765819('0x7a')]();!_['isEmpty'](_0x35d7cd)&&_0x35d7cd['forEach'](function(_0x51f7b2){const _0x1c0f3e=_0x765819;if(_0x51f7b2===_0x1c0f3e('0x3c'))_0x4c95d1['where'](_0x1c0f3e('0xf'),[][_0x1c0f3e('0xcb')](_0x432b9d[_0x1c0f3e('0x9b')][_0x51f7b2]));else{if(_0x51f7b2===_0x1c0f3e('0xb9')){const _0x47d587=JSON[_0x1c0f3e('0x80')](_0x432b9d[_0x1c0f3e('0x9b')][_0x51f7b2])[_0x1c0f3e('0xbe')],_0x3f3e29=JSON['parse'](_0x432b9d[_0x1c0f3e('0x9b')][_0x51f7b2])[_0x1c0f3e('0x63')];_0x4c95d1[_0x1c0f3e('0xa6')](_0x1c0f3e('0x4b'),_0x47d587,_0x3f3e29);}else _0x432b9d[_0x1c0f3e('0x9b')][_0x51f7b2]===_0x1c0f3e('0xc6')?_0x4c95d1['where']('i.'+_0x51f7b2+_0x1c0f3e('0x55')):_0x4c95d1[_0x1c0f3e('0xa6')]('i.'+_0x51f7b2+'\x20=\x20?',_0x432b9d[_0x1c0f3e('0x9b')][_0x51f7b2]);}});_0x432b9d[_0x765819('0x9b')][_0x765819('0x2f')]&&(_0x432b9d[_0x765819('0x9b')][_0x765819('0x2f')]==0x1?_0x4c95d1[_0x765819('0x1b')](_0x765819('0x3a')):_0x4c95d1[_0x765819('0x1b')](_0x765819('0x1e')));_0x432b9d[_0x765819('0x9b')][_0x765819('0x1f')]&&(_0xda6982=_[_0x765819('0x9d')](_0x432b9d['query'][_0x765819('0x1f')])?_0x432b9d[_0x765819('0x9b')][_0x765819('0x1f')]:new Array(_0x432b9d['query']['tag']),_0xda6982['forEach'](function(_0x1715d5){const _0x538fcd=_0x765819;_0x4e3659['or'](_0x538fcd('0xbb'),'%,'+_0x1715d5+',%');}));if(_0x432b9d[_0x765819('0x9b')][_0x765819('0x39')]){const _0x9dbf78=_0x432b9d['query'][_0x765819('0x39')][_0x765819('0xcd')]('\x5c','\x5c\x5c')['replace']('\x27\x27',_0x765819('0x35'));if(qs[_0x765819('0x36')](_0x9dbf78))_0x5e9ba5['or']('i.id\x20LIKE\x20?',_0x9dbf78+'%');else qs['isEmail'](_0x9dbf78)?_0x5e9ba5['or']('c.email\x20LIKE\x20?',_0x9dbf78+'%'):_0x5e9ba5['or'](_0x765819('0xb7'),qs[_0x765819('0x51')](_0x9dbf78))['or'](_0x765819('0x72'),qs[_0x765819('0x51')](_0x9dbf78));}}_0x4c95d1['where'](_0x5e9ba5),_0x4c95d1[_0x765819('0x20')](_0x765819('0x79'));let _0x322696={'type':db[_0x765819('0x7b')][_0x765819('0x67')]['SELECT'],'raw':!![]};const _0x5aacbd=_0x4c95d1[_0x765819('0x85')]();_0x5aacbd[_0x765819('0x97')](_0x765819('0x79')),_0x5aacbd[_0x765819('0x97')](_0x765819('0x40'),_0x765819('0x9')),_0x4b00fc['order']&&_0x4b00fc[_0x765819('0x48')][_0x765819('0xdd')](function(_0x896cd7){const _0x174890=_0x765819;_0x4c95d1[_0x174890('0x48')]('i.'+_0x896cd7[0x0],_0x896cd7[0x1]===_0x174890('0x15')?![]:!![]);}),!_['isEmpty'](_0xda6982)&&(_0x4c95d1[_0x765819('0x1b')](_0x4e3659),_0x5aacbd[_0x765819('0xa6')]('t.id\x20IN\x20?',_0xda6982)),Promise[_0x765819('0x45')]()[_0x765819('0xa4')](function(){const _0x152d33=_0x765819;if(!_0x2ae6b0){if(_0x432b9d[_0x152d33('0x9b')][_0x152d33('0x3c')]||_0x432b9d[_0x152d33('0x9b')][_0x152d33('0x75')])return;_0x5aacbd[_0x152d33('0xa6')](_0x152d33('0x62')),_0x4c95d1[_0x152d33('0xa6')](_0x152d33('0x62'));return;}return _0x432b9d[_0x152d33('0xaa')][_0x152d33('0x12')]({'attributes':['id'],'raw':!![]})[_0x152d33('0xa4')](function(_0x1a0e7c){const _0x56fd74=_0x152d33;_[_0x56fd74('0xb5')](_0x1a0e7c)?(_0x5aacbd[_0x56fd74('0xa6')]('i.MailAccountId\x20IS\x20NULL'),_0x4c95d1[_0x56fd74('0xa6')]('i.MailAccountId\x20IS\x20NULL')):(_0x5aacbd[_0x56fd74('0xa6')](_0x56fd74('0xf'),_['map'](_0x1a0e7c,'id')),_0x4c95d1[_0x56fd74('0xa6')](_0x56fd74('0xf'),_[_0x56fd74('0xc0')](_0x1a0e7c,'id')));});})[_0x765819('0xa4')](function(){const _0x2faa82=_0x765819;db[_0x2faa82('0x6e')]['query'](_0x5aacbd['toString'](),_0x322696)[_0x2faa82('0xa4')](function(_0x66ee13){const _0x423e4a=_0x2faa82;_0x583fe3[_0x423e4a('0xe3')]=_0x66ee13[_0x423e4a('0xae')];if(_0x583fe3[_0x423e4a('0xe3')]===0x0)return[];return db['sequelize'][_0x423e4a('0x9b')](_0x75090d[_0x423e4a('0x5a')](),_0x322696)[_0x423e4a('0xa4')](function(_0xd8e56d){const _0x21cf3d=_0x423e4a;_0xdad73a=_[_0x21cf3d('0x21')](_0xd8e56d,'id'),_0x322696=_['merge'](_0x322696,{'model':db['MailInteraction'],'mapToModel':!![],'raw':!![],'nest':!![]});_0x432b9d[_0x21cf3d('0x9b')][_0x21cf3d('0xa5')]?_0x4b00fc[_0x21cf3d('0x3d')][_0x21cf3d('0xdd')](function(_0x384e24){const _0x50b898=_0x21cf3d;_0x4c95d1[_0x50b898('0x97')]('i.'+_0x384e24);}):(_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x40'),_0x21cf3d('0x9')),_0x4c95d1['field'](_0x21cf3d('0xce'),_0x21cf3d('0x43')),_0x4c95d1['field'](_0x21cf3d('0x9c'),_0x21cf3d('0x41')),_0x4c95d1[_0x21cf3d('0x97')]('i.id'),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0xd8')),_0x4c95d1['field'](_0x21cf3d('0x50')),_0x4c95d1['field'](_0x21cf3d('0x13')),_0x4c95d1[_0x21cf3d('0x97')]('i.closedAt'),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x89')),_0x4c95d1['field'](_0x21cf3d('0xe1')),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x8d')),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x3e')),_0x4c95d1['field']('i.disposition'),_0x4c95d1[_0x21cf3d('0x97')]('i.secondDisposition'),_0x4c95d1[_0x21cf3d('0x97')]('i.thirdDisposition'),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x74')),_0x4c95d1['field'](_0x21cf3d('0x56')),_0x4c95d1['field'](_0x21cf3d('0x8')),_0x4c95d1[_0x21cf3d('0x97')]('i.MailAccountId'),_0x4c95d1['field'](_0x21cf3d('0x33')),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x42'),_0x21cf3d('0xcf')),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x4a'),_0x21cf3d('0x26')),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x91'),_0x21cf3d('0xdc')),_0x4c95d1['field']('c.phone',_0x21cf3d('0x25')),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0xa8'),_0x21cf3d('0xab')),_0x4c95d1['field'](_0x21cf3d('0x27'),'Contact.fax'),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x65'),_0x21cf3d('0x47')),_0x4c95d1['field']('o.internal',_0x21cf3d('0xa3')),_0x4c95d1[_0x21cf3d('0x97')](_0x21cf3d('0x68'),_0x21cf3d('0xc7')));if(_0x4b00fc[_0x21cf3d('0x37')])_0x4c95d1[_0x21cf3d('0x37')](_0x4b00fc[_0x21cf3d('0x37')]);if(_0x4b00fc[_0x21cf3d('0xc9')])_0x4c95d1[_0x21cf3d('0xc9')](_0x4b00fc['offset']);return db[_0x21cf3d('0x6e')][_0x21cf3d('0x9b')](_0x4c95d1[_0x21cf3d('0x5a')](),_0x322696);})['then'](function(_0x2fad05){const _0x491b24=_0x423e4a;return _0x2ea691['where'](_0x491b24('0xe2'),_['map'](_0x2fad05,'id')),db[_0x491b24('0x6e')]['query'](_0x2ea691[_0x491b24('0x5a')](),_0x322696)[_0x491b24('0xa4')](function(_0x298b43){const _0x3c2d10=_0x491b24,_0x5e3613=_[_0x3c2d10('0x7f')](_0x298b43,_0x3c2d10('0x6c')),_0x946b3c=[];return db[_0x3c2d10('0x14')]['findOne']({'attributes':['enableEmailPreview'],'raw':!![]})['then'](function(_0x4190ab){const _0x2c02fc=_0x3c2d10,_0x37cad7=_0x4190ab[_0x2c02fc('0xb1')];return _0x2fad05[_0x2c02fc('0xdd')](function(_0x4dd023){const _0x2b5235=_0x2c02fc;_0x946b3c[_0x2b5235('0xaf')](updateMailInteraction(_0x4dd023,_0xdad73a,_0x5e3613,_0x37cad7));}),Promise[_0x2c02fc('0xa2')](_0x946b3c);});});});})[_0x2faa82('0xa4')](function(_0x290706){const _0x127cf6=_0x2faa82;return _0x583fe3[_0x127cf6('0xa7')]=_0x290706,_0x583fe3;})['then'](respondWithFilteredResult(_0x1168bc,_0x4b00fc));})['catch'](handleError(_0x1168bc,null));},exports['show']=function(_0xc826fb,_0xf3a063){const _0x3ed795=_0x567c49;let _0x336bba={'raw':![],'where':{'id':_0xc826fb[_0x3ed795('0x23')]['id']}};const _0x44d122={};return _0x44d122['model']=_[_0x3ed795('0x59')](db[_0x3ed795('0x1')]['rawAttributes']),_0x44d122[_0x3ed795('0x9b')]=_[_0x3ed795('0x59')](_0xc826fb[_0x3ed795('0x9b')]),_0x44d122['filters']=_[_0x3ed795('0xd3')](_0x44d122['model'],_0x44d122[_0x3ed795('0x9b')]),_0x336bba[_0x3ed795('0x3d')]=_[_0x3ed795('0xd3')](_0x44d122[_0x3ed795('0x87')],qs[_0x3ed795('0xa5')](_0xc826fb[_0x3ed795('0x9b')][_0x3ed795('0xa5')])),_0x336bba[_0x3ed795('0x3d')]=_0x336bba[_0x3ed795('0x3d')][_0x3ed795('0xae')]?_0x336bba[_0x3ed795('0x3d')]:_0x44d122['model'],_0xc826fb[_0x3ed795('0x9b')][_0x3ed795('0xb6')]&&(_0x336bba[_0x3ed795('0xb0')]=[{'all':!![]}]),_0x336bba=_['merge']({},_0x336bba,_0xc826fb[_0x3ed795('0xb')]),db[_0x3ed795('0x1')][_0x3ed795('0xa9')](_0x336bba)[_0x3ed795('0xa4')](handleEntityNotFound(_0xf3a063,null))[_0x3ed795('0xa4')](respondWithResult(_0xf3a063,null))[_0x3ed795('0xcc')](handleError(_0xf3a063,null));},exports['create']=function(_0x34a9c8,_0x151409){const _0x3d320c=_0x567c49;return db[_0x3d320c('0x1')]['create'](_0x34a9c8[_0x3d320c('0x2b')],{})[_0x3d320c('0xa4')](respondWithResult(_0x151409,0xc9))[_0x3d320c('0xcc')](handleError(_0x151409,null));},exports[_0x567c49('0x6d')]=function(_0x3468ce,_0x4a374c){const _0x35ecd1=_0x567c49;return _0x3468ce['body']['id']&&delete _0x3468ce[_0x35ecd1('0x2b')]['id'],db[_0x35ecd1('0x1')][_0x35ecd1('0xa9')]({'where':{'id':_0x3468ce['params']['id']}})[_0x35ecd1('0xa4')](handleEntityNotFound(_0x4a374c,null))[_0x35ecd1('0xa4')](saveUpdates(_0x3468ce[_0x35ecd1('0x2b')],null))['then'](respondWithResult(_0x4a374c,null))['catch'](handleError(_0x4a374c,null));},exports[_0x567c49('0x38')]=function(_0x49a9a1,_0x1f1d01){const _0x521552=_0x567c49;return db['MailInteraction']['findOne']({'where':{'id':_0x49a9a1['params']['id']}})[_0x521552('0xa4')](handleEntityNotFound(_0x1f1d01,null))[_0x521552('0xa4')](removeEntity(_0x1f1d01,null))[_0x521552('0xcc')](handleError(_0x1f1d01,null));},exports[_0x567c49('0x61')]=function(_0x1c5b31,_0x11f199){const _0x2fb23d=_0x567c49;return db[_0x2fb23d('0x1')][_0x2fb23d('0x61')]()[_0x2fb23d('0xa4')](respondWithResult(_0x11f199,null))[_0x2fb23d('0xcc')](handleError(_0x11f199,null));},exports[_0x567c49('0x11')]=function(_0xd237e8,_0x5830ae){const _0x49aa38=_0x567c49;return db[_0x49aa38('0xc5')][_0x49aa38('0xa9')]({'where':{'id':_0xd237e8[_0x49aa38('0x23')]['id']}})[_0x49aa38('0xa4')](function(_0x4c6963){const _0x61016a=_0x49aa38;if(_0x4c6963)return _0x4c6963[_0x61016a('0x11')](_0xd237e8[_0x61016a('0x2b')][_0x61016a('0x1c')],{'through':_[_0x61016a('0xa')](_0xd237e8['body'],[_0x61016a('0x1c'),'id'])});})[_0x49aa38('0xa4')](respondWithResult(_0x5830ae,null))[_0x49aa38('0xcc')](handleError(_0x5830ae,null));},exports[_0x567c49('0x6a')]=function(_0x560a84,_0x553000){const _0x29c86b=_0x567c49;let _0x5eedee={'raw':![],'where':{}};const _0x517068={},_0x3f807d={'count':0x0,'rows':[]};return db[_0x29c86b('0x1')][_0x29c86b('0xa9')]({'where':{'id':_0x560a84[_0x29c86b('0x23')]['id']}})['then'](handleEntityNotFound(_0x553000,null))[_0x29c86b('0xa4')](function(_0x51ba93){const _0x2b2dbb=_0x29c86b;if(_0x51ba93){_0x517068[_0x2b2dbb('0x87')]=_[_0x2b2dbb('0x59')](db[_0x2b2dbb('0xc5')][_0x2b2dbb('0x2e')]),_0x517068[_0x2b2dbb('0x9b')]=_[_0x2b2dbb('0x59')](_0x560a84[_0x2b2dbb('0x9b')]),_0x517068['filters']=_[_0x2b2dbb('0xd3')](_0x517068[_0x2b2dbb('0x87')],_0x517068[_0x2b2dbb('0x9b')]),_0x5eedee[_0x2b2dbb('0x3d')]=_[_0x2b2dbb('0xd3')](_0x517068[_0x2b2dbb('0x87')],qs['fields'](_0x560a84[_0x2b2dbb('0x9b')][_0x2b2dbb('0xa5')])),_0x5eedee[_0x2b2dbb('0x3d')]=_0x5eedee[_0x2b2dbb('0x3d')]['length']?_0x5eedee[_0x2b2dbb('0x3d')]:_0x517068['model'];typeof _0x560a84[_0x2b2dbb('0x9b')][_0x2b2dbb('0x16')]==='undefined'&&(_0x5eedee['limit']=qs[_0x2b2dbb('0x37')](_0x560a84[_0x2b2dbb('0x9b')][_0x2b2dbb('0x37')]),_0x5eedee['offset']=qs['offset'](_0x560a84[_0x2b2dbb('0x9b')][_0x2b2dbb('0xc9')]));_0x5eedee[_0x2b2dbb('0x48')]=qs[_0x2b2dbb('0x5e')](_0x560a84[_0x2b2dbb('0x9b')]['sort']),_0x5eedee[_0x2b2dbb('0xa6')]=qs['filters'](_[_0x2b2dbb('0xa0')](_0x560a84['query'],_0x517068['filters'])),_0x5eedee[_0x2b2dbb('0xa6')][_0x2b2dbb('0x6c')]=_0x51ba93['id'];_0x560a84['query']['filter']&&(_0x5eedee['where']=_[_0x2b2dbb('0xca')](_0x5eedee[_0x2b2dbb('0xa6')],{[Op['or']]:_[_0x2b2dbb('0xc0')](_0x5eedee[_0x2b2dbb('0x3d')],function(_0x574a43){const _0x1e07c5=_0x2b2dbb,_0x2ed6bf={};return _0x2ed6bf[_0x574a43]={[Op[_0x1e07c5('0x9f')]]:'%'+_0x560a84[_0x1e07c5('0x9b')][_0x1e07c5('0x39')]+'%'},_0x2ed6bf;})}));if(_0x560a84[_0x2b2dbb('0x9b')]['$gte']){const _0x278d52=_0x560a84['query'][_0x2b2dbb('0xbe')][_0x2b2dbb('0x88')](','),_0x3115b5={};_0x3115b5[_0x278d52[0x0]]={[Op[_0x2b2dbb('0xd7')]]:moment(_0x278d52[0x1])[_0x2b2dbb('0x57')]('YYYY-MM-DD\x20HH:mm:ss')},_0x5eedee[_0x2b2dbb('0xa6')]=_[_0x2b2dbb('0xca')](_0x5eedee[_0x2b2dbb('0xa6')],_0x3115b5);}return _0x5eedee=_[_0x2b2dbb('0xca')]({},_0x5eedee,_0x560a84[_0x2b2dbb('0xb')]),db[_0x2b2dbb('0xc5')][_0x2b2dbb('0xe3')]({'where':_0x5eedee[_0x2b2dbb('0xa6')]})['then'](function(_0x5ee712){const _0x235515=_0x2b2dbb;return _0x3f807d['count']=_0x5ee712,_0x560a84[_0x235515('0x9b')][_0x235515('0xb6')]&&(_0x5eedee['include']=[{'all':!![]}]),db['MailMessage']['findAll'](_0x5eedee);})[_0x2b2dbb('0xa4')](function(_0x469763){return _0x3f807d['rows']=_0x469763,_0x3f807d;});}})[_0x29c86b('0xa4')](respondWithFilteredResult(_0x553000,_0x5eedee))[_0x29c86b('0xcc')](handleError(_0x553000,null));},exports[_0x567c49('0xd5')]=function(_0x3d2947,_0x33da98){const _0x102f0a=_0x567c49;return db['MailInteraction'][_0x102f0a('0xa9')]({'where':{'id':_0x3d2947[_0x102f0a('0x23')]['id']}})['then'](function(_0x580f62){const _0x4ab64a=_0x102f0a;if(_0x580f62)return _0x580f62[_0x4ab64a('0x30')](_0x3d2947[_0x4ab64a('0x2b')][_0x4ab64a('0x1c')],{'through':_[_0x4ab64a('0xa')](_0x3d2947[_0x4ab64a('0x2b')],[_0x4ab64a('0x1c'),'id'])})[_0x4ab64a('0xa4')](function(){const _0x1f79b7=_0x4ab64a;return db[_0x1f79b7('0x22')][_0x1f79b7('0x17')]({'attributes':['id',_0x1f79b7('0xc2'),_0x1f79b7('0xdb')],'where':{'id':_0x3d2947[_0x1f79b7('0x2b')]['ids']}});})[_0x4ab64a('0xa4')](function(_0x326cd2){const _0x18cf98=_0x4ab64a;return socket[_0x18cf98('0xe5')](_0x18cf98('0x3'),{'id':Number(_0x3d2947['params']['id']),'tags':_0x326cd2||[]}),{'id':Number(_0x3d2947[_0x18cf98('0x23')]['id']),'tags':_0x326cd2||[]};});})['then'](respondWithResult(_0x33da98,null))['catch'](handleError(_0x33da98,null));},exports[_0x567c49('0x73')]=function(_0x5d5368,_0xc1d016){const _0x11090e=_0x567c49;return db[_0x11090e('0x1')][_0x11090e('0xa9')]({'where':{'id':_0x5d5368[_0x11090e('0x23')]['id']}})['then'](handleEntityNotFound(_0xc1d016,null))[_0x11090e('0xa4')](function(_0x3893ef){const _0x29a141=_0x11090e;if(_0x3893ef)return _0x3893ef[_0x29a141('0x73')](_0x5d5368[_0x29a141('0x9b')][_0x29a141('0x1c')]);})['then'](respondWithStatusCode(_0xc1d016,null))[_0x11090e('0xcc')](handleError(_0xc1d016,null));},exports[_0x567c49('0xb2')]=function(_0x9923b7,_0x2e66de){const _0x536ff1=_0x567c49,_0x5742d1=moment()['unix']()[_0x536ff1('0x5a')](),_0x1e5d20=path['join'](config[_0x536ff1('0x5c')],_0x536ff1('0xbd'),_0x536ff1('0x76')),_0xdf8d91=path[_0x536ff1('0x54')](config[_0x536ff1('0x5c')],_0x536ff1('0xd0'),_0x536ff1('0xbd'),_0x536ff1('0x66')),_0x587330=path[_0x536ff1('0x54')](_0x1e5d20,_0x5742d1),_0xfbad10=util[_0x536ff1('0x57')](_0x536ff1('0x5d'),_0x9923b7[_0x536ff1('0x23')]['id'],_0x5742d1),_0x5160af=path['join'](_0x1e5d20,_0xfbad10),_0x4e4644=[];_0x9923b7[_0x536ff1('0x9b')][_0x536ff1('0x66')]&&_0x4e4644['push']({'model':db[_0x536ff1('0x93')],'as':_0x536ff1('0x28'),'raw':!![]});const _0x522243=[{'model':db[_0x536ff1('0xc5')],'as':'Messages','attributes':['id','body',_0x536ff1('0x86'),'to','cc',_0x536ff1('0x6'),_0x536ff1('0x8b'),_0x536ff1('0xb9')],'where':{'secret':![]},'order':qs[_0x536ff1('0x5e')]('id'),'include':_0x4e4644}];return db['MailInteraction']['findOne']({'where':{'id':_0x9923b7['params']['id']},'include':_0x522243})[_0x536ff1('0xa4')](handleEntityNotFound(_0x2e66de,null))[_0x536ff1('0xa4')](function(_0x22690c){const _0xa08d57=_0x536ff1;if(_0x22690c&&_0x22690c[_0xa08d57('0x18')]){const _0x441e4a=_0x22690c[_0xa08d57('0x53')]({'plain':!![]});return fs[_0xa08d57('0x8c')](_0x587330),Promise[_0xa08d57('0xde')](_0x441e4a['Messages'],function(_0x439e1a,_0x3ee5a6){const _0x125fe8=_0xa08d57,_0x8fa474={'from':_0x439e1a[_0x125fe8('0x86')],'to':_0x439e1a['to'],'subject':_0x439e1a['subject'],'html':_0x439e1a['body'],'headers':{'Date':moment(_0x439e1a[_0x125fe8('0xb9')])[_0x125fe8('0x57')](_0x125fe8('0x32'))},'attachments':[]};return _0x439e1a['cc']&&(_0x8fa474[_0x125fe8('0xb8')]['Cc']=_0x439e1a['cc']),_0x439e1a['bcc']&&(_0x8fa474['headers'][_0x125fe8('0x7')]=_0x439e1a[_0x125fe8('0x6')]),new Promise(function(_0x2ed839,_0x3a29c2){const _0x4dcef7=_0x125fe8;if(_0x439e1a['Attachments'])for(let _0xbf6353=0x0;_0xbf6353<_0x439e1a[_0x4dcef7('0x28')][_0x4dcef7('0xae')];_0xbf6353++){const _0x2f64c8=_0x439e1a['Attachments'][_0xbf6353],_0x3d42b2=path['join'](_0xdf8d91,_0x2f64c8[_0x4dcef7('0xd2')]);fs[_0x4dcef7('0x1a')](_0x3d42b2)&&_0x8fa474['attachments'][_0x4dcef7('0xaf')]({'name':_0x2f64c8[_0x4dcef7('0xc2')],'contentType':_0x2f64c8[_0x4dcef7('0x3f')],'data':fs[_0x4dcef7('0xba')](_0x3d42b2)});}emlformat[_0x4dcef7('0x8e')](_0x8fa474,function(_0x120162,_0x3c8bc4){const _0x4363e3=_0x4dcef7;if(_0x120162)return _0x3a29c2(_0x120162);return fs[_0x4363e3('0x8a')](path[_0x4363e3('0x54')](_0x587330,util[_0x4363e3('0x57')](_0x4363e3('0xc8'),_0x3ee5a6)),_0x3c8bc4),_0x2ed839(_0x3c8bc4);});});})[_0xa08d57('0xa4')](function(){const _0x49a77b=_0xa08d57;return new Promise(function(_0x3532f2,_0x56460c){zipdir(_0x587330,{'saveTo':_0x5160af},function(_0x1d7c68,_0x247238){if(_0x1d7c68)return _0x56460c(_0x1d7c68);return _0x3532f2(_0x247238);});})[_0x49a77b('0xa4')](function(){return new Promise(function(_0x4db322,_0x8ff948){rimraf(_0x587330,function(_0x3f6531){if(_0x3f6531)_0x8ff948(_0x3f6531);return _0x4db322();});});})[_0x49a77b('0xa4')](function(){const _0x8b620f=_0x49a77b;return _0x2e66de[_0x8b620f('0xb2')](_0x5160af,_0xfbad10,function(_0x1658f2){const _0x48a3ac=_0x8b620f;_0x1658f2?console[_0x48a3ac('0x2')]('err',_0x1658f2):fs[_0x48a3ac('0xbf')](_0x5160af);});});});}else return _0x2e66de[_0xa08d57('0x4e')](0xc8);})[_0x536ff1('0xcc')](handleError(_0x2e66de,null));}; \ No newline at end of file +const a406_0x33a3=['Attachment','forEach','$lte','concat','end','tag','c.lastName','Setting','subject','\x20IS\x20NULL','intersection','sendStatus','groupBy','model','color','read','include','value','transcript-%d-%s.zip','all','undefined','rimraf','MATCH\x20(i.to,\x20i.subject)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','o.fullname','eml-format','split','nolimit','update','createdAt','i.thirdDisposition','attributes','format','$substring','destroy','merge','Contact.mobile','i.MailAccountId','getMessages','i.MailAccountId\x20IS\x20NULL','basename','i.createdAt','util','i.disposition','join','getFullTextValue','name','root','mail_interactions','sequelize','each','path','text','toString','body','then','Owner.fullname','zip-dir','DESC','c.fax','from','Sequelize','i.lastMsgAt','send','message%d.eml','server','Messages','parse','html-to-text','MailInteractionId','omit','u.id\x20=\x20ui.UserId','c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?','filters','addTags','Contact.lastName','it.MailInteractionId\x20=\x20i.id','search','addMessage','rawAttributes','tools_tags','unix','Contact.fax','Attachments','ContactId','key','i.id','ui.MailInteractionId\x20IN\x20?','moment','ui.MailInteractionId','err','length','operator','i.secondDisposition','users','`\x20>\x200','push','describe','i.id\x20LIKE\x20?','union','c.firstName','findAll','c.email\x20LIKE\x20?','ids','GROUP_CONCAT(DISTINCT\x20t.id)','$gte','attachments','conditions','user_has_mail_interactions','parseSearch','me.MailInteractionId\x20=\x20i.id','SELECT','sort','MailMessage','filter','keyBy','catch','lodash','rows','options','./mailInteraction.socket','unreadMessages','o.id\x20=\x20i.UserId','c.email','mkdirSync','MailAccountId','Tags','enableEmailPreview','Account.mandatoryDisposition','show','fieldName','c.mobile','../../config/logger','having','find','left_join','`unreadMessages`\x20=\x200','download','../../components/parsers/qs','index','i.UserId','build','i.to','a.key','mail_messages','i.MailAccountId\x20IN\x20?','null','start','plainBody','emit','t.id\x20=\x20it.TagId','writeFileSync','gte','tmp','c.phone','where','Contact','Bcc','api','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','bcc','t.id\x20IN\x20?','type','json','sqlOperator','Users','removeTags','YYYY-MM-DD\x20HH:mm:ss','TagIds','i.substatus','status','Contact.phone','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','order','Account.key','log','existsSync','i.closed','../../components/parsers/advancedSearch','lastMsgText','../../config/environment','\x20=\x20?','mail_interaction_has_tags','Tag','findOne','get','replace','create','isEmpty','lastMsgBody','isEmail','`unreadMessages`\x20>\x200','pick','Contact.firstName','unlinkSync','select','keys','readFileSync','../../mysqldb','params','fields','field','limit','includeAll','map','expr','count','i.ContactId','MailInteraction','some','buildExpression','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','query','files','offset','journey'];(function(_0x87c4e1,_0x33a3a4){const _0x58faf5=function(_0x2270ff){while(--_0x2270ff){_0x87c4e1['push'](_0x87c4e1['shift']());}};_0x58faf5(++_0x33a3a4);}(a406_0x33a3,0x112));const a406_0x58fa=function(_0x87c4e1,_0x33a3a4){_0x87c4e1=_0x87c4e1-0x0;let _0x58faf5=a406_0x33a3[_0x87c4e1];return _0x58faf5;};const _0x721b48=a406_0x58fa;'use strict';const emlformat=require(_0x721b48('0xb4')),rimraf=require(_0x721b48('0xb1')),zipdir=require(_0x721b48('0xd4')),moment=require(_0x721b48('0x1c')),util=require(_0x721b48('0xc5')),path=require(_0x721b48('0xce')),fs=require('fs'),_=require(_0x721b48('0x39')),squel=require('squel'),{htmlToText}=require(_0x721b48('0x8')),{getSocket}=require('../../rediscache'),socket=getSocket(),qs=require(_0x721b48('0x4e')),as=require(_0x721b48('0x76')),logger=require(_0x721b48('0x48'))(_0x721b48('0x62')),config=require(_0x721b48('0x78')),db=require(_0x721b48('0x8a'))['db'],{Op}=require(_0x721b48('0xcc'));require(_0x721b48('0x3c'))['register'](socket);function respondWithStatusCode(_0x2270ff,_0x2e4b66){return _0x2e4b66=_0x2e4b66||0xcc,function(_0x26f6eb){const _0x23cb22=a406_0x58fa;if(_0x26f6eb)return _0x2270ff[_0x23cb22('0xa7')](_0x2e4b66);return _0x2270ff[_0x23cb22('0x6e')](_0x2e4b66)[_0x23cb22('0xa0')]();};}function respondWithResult(_0x25780b,_0x4bfb3d){return _0x4bfb3d=_0x4bfb3d||0xc8,function(_0x1d2104){const _0x1f13d1=a406_0x58fa;if(_0x1d2104)return _0x25780b[_0x1f13d1('0x6e')](_0x4bfb3d)[_0x1f13d1('0x67')](_0x1d2104);};}function respondWithFilteredResult(_0x3685e9,_0x5f096f){return function(_0x15502b){const _0x2b7928=a406_0x58fa;if(_0x15502b){const _0x3ed40f=_0x15502b['count'],_0x400f78=_0x5f096f[_0x2b7928('0x9a')];let _0x4226f3=_0x5f096f[_0x2b7928('0x9a')]+_0x5f096f[_0x2b7928('0x8e')],_0x72054d;return _0x4226f3>=_0x3ed40f?(_0x4226f3=_0x3ed40f,_0x72054d=0xc8):_0x72054d=0xce,_0x3685e9[_0x2b7928('0x6e')](_0x72054d),_0x3685e9['set']('Content-Range',_0x400f78+'-'+_0x4226f3+'/'+_0x3ed40f)[_0x2b7928('0x67')](_0x15502b);}return null;};}function saveUpdates(_0x5d704e){return function(_0x4ea38d){const _0x3d899c=a406_0x58fa;if(_0x4ea38d)return _0x4ea38d[_0x3d899c('0xb7')](_0x5d704e)[_0x3d899c('0xd2')](function(_0x2b5a35){return _0x2b5a35;});return null;};}function removeEntity(_0x17cb97){return function(_0x44a5f6){const _0x29af65=a406_0x58fa;if(_0x44a5f6)return _0x44a5f6[_0x29af65('0xbd')]()[_0x29af65('0xd2')](function(){const _0x24c4d4=_0x29af65;_0x17cb97[_0x24c4d4('0x6e')](0xcc)[_0x24c4d4('0xa0')]();});};}function handleEntityNotFound(_0x2322ef){return function(_0x35aac2){const _0xe25ac7=a406_0x58fa;return!_0x35aac2&&_0x2322ef[_0xe25ac7('0xa7')](0x194),_0x35aac2;};}function handleError(_0x49a31f,_0x43a925){return _0x43a925=_0x43a925||0x1f4,function(_0x3611e5){const _0x1fca43=a406_0x58fa;logger['error'](_0x3611e5['stack']),_0x3611e5[_0x1fca43('0xc9')]&&delete _0x3611e5[_0x1fca43('0xc9')],_0x49a31f['status'](_0x43a925)[_0x1fca43('0x3')](_0x3611e5);};}function getInteractionUsers(_0x2daf14,_0x14a19b){return new Promise(function(_0x12c47b,_0x36e38a){const _0x377742=a406_0x58fa;try{_0x14a19b[_0x2daf14['id']]&&(_0x2daf14[_0x377742('0x69')]=_[_0x377742('0x90')](_0x14a19b[_0x2daf14['id']],function(_0x2f0338){return{'id':_0x2f0338['id'],'fullname':_0x2f0338['fullname']};}));}catch(_0x1ecead){_0x36e38a(_0x1ecead);}_0x12c47b(_0x2daf14);});}function getInteractionTags(_0x9afaa8,_0x1d2a69){return new Promise(function(_0x26fb5b,_0x3bcc43){const _0x1e062f=a406_0x58fa;try{_0x9afaa8['TagIds']&&(_0x9afaa8[_0x1e062f('0x42')]=[],_0x9afaa8[_0x1e062f('0x6c')][_0x1e062f('0xb5')](',')[_0x1e062f('0x9d')](function(_0x252362){const _0x545d1c=_0x1e062f;_0x9afaa8[_0x545d1c('0x42')]['push'](_0x1d2a69[_0x252362]);})),delete _0x9afaa8[_0x1e062f('0x6c')];}catch(_0x132302){_0x3bcc43(_0x132302);}_0x26fb5b(_0x9afaa8);});}function getLastMessageText(_0x9f1cc){return new Promise(function(_0x2e23dc,_0x1d54c4){const _0x1f8e26=a406_0x58fa;return db['MailInteraction'][_0x1f8e26('0x7c')]({'where':{'id':_0x9f1cc['id']},'attributes':[_0x1f8e26('0x81'),'lastMsgText'],'raw':!![]})[_0x1f8e26('0xd2')](function(_0x2226b8){const _0x41be90=_0x1f8e26;!_0x2226b8[_0x41be90('0x77')]?_0x9f1cc['lastMsgText']=_['trimStart'](htmlToText(_0x2226b8['lastMsgBody'],{'preserveNewlines':!![],'singleNewLineParagraphs':!![],'uppercaseHeadings':![],'noLinkBrackets':!![],'ignoreImage':!![]})):_0x9f1cc[_0x41be90('0x77')]=_0x2226b8[_0x41be90('0x77')],_0x2e23dc(_0x9f1cc);})[_0x1f8e26('0x38')](function(_0x17dfe9){_0x1d54c4(_0x17dfe9);});});}function updateMailInteraction(_0x352964,_0x16bb4d,_0x188796,_0x12aad2){return new Promise(function(_0x3a9a6a,_0x7287ff){const _0xc62b98=a406_0x58fa;return getInteractionUsers(_0x352964,_0x188796)[_0xc62b98('0xd2')](function(_0x10723f){return getInteractionTags(_0x10723f,_0x16bb4d);})[_0xc62b98('0xd2')](function(_0x417408){_0x12aad2?_0x3a9a6a(getLastMessageText(_0x417408)):_0x3a9a6a(_0x417408);})[_0xc62b98('0x38')](function(_0x32d7e3){_0x7287ff(_0x32d7e3);});});}exports[_0x721b48('0x4f')]=function(_0x25ffd5,_0x4a45c4){const _0x4ae996=_0x721b48,_0x25274d={},_0x6cc5e0={},_0x5e6273={'count':0x0,'rows':[]},_0x57ad02=_[_0x4ae996('0x90')](db['MailInteraction'][_0x4ae996('0x13')],function(_0x37065d){const _0x1573fc=_0x4ae996;return{'name':_0x37065d[_0x1573fc('0x46')],'type':_0x37065d[_0x1573fc('0x66')][_0x1573fc('0x19')]};});_0x6cc5e0[_0x4ae996('0xa9')]=_[_0x4ae996('0x90')](_0x57ad02,_0x4ae996('0xc9')),_0x6cc5e0['query']=_['keys'](_0x25ffd5['query']),_0x6cc5e0[_0x4ae996('0xd')]=_['intersection'](_0x6cc5e0[_0x4ae996('0xa9')],_0x6cc5e0[_0x4ae996('0x98')]),_0x25274d[_0x4ae996('0xba')]=_[_0x4ae996('0xa6')](_0x6cc5e0[_0x4ae996('0xa9')],qs[_0x4ae996('0x8c')](_0x25ffd5['query'][_0x4ae996('0x8c')])),_0x25274d[_0x4ae996('0xba')]=_0x25274d['attributes'][_0x4ae996('0x1f')]?_0x25274d[_0x4ae996('0xba')]:_0x6cc5e0[_0x4ae996('0xa9')];typeof _0x25ffd5[_0x4ae996('0x98')]['nolimit']==='undefined'&&(_0x25274d['limit']=qs[_0x4ae996('0x8e')](_0x25ffd5['query'][_0x4ae996('0x8e')]),_0x25274d['offset']=qs[_0x4ae996('0x9a')](_0x25ffd5[_0x4ae996('0x98')][_0x4ae996('0x9a')]));_0x25274d['order']=qs['sort'](_0x25ffd5[_0x4ae996('0x98')][_0x4ae996('0x34')]),_0x25274d[_0x4ae996('0x5f')]=qs[_0x4ae996('0xd')](_[_0x4ae996('0x84')](_0x25ffd5[_0x4ae996('0x98')],_0x6cc5e0[_0x4ae996('0xd')]),_0x57ad02);let _0xba21dc=[];const _0x374e48=squel[_0x4ae996('0x87')]()['field']('id')[_0x4ae996('0x8d')](_0x4ae996('0xc9'))[_0x4ae996('0x8d')](_0x4ae996('0xaa'))[_0x4ae996('0x0')](_0x4ae996('0x14')),_0x3846b8=squel[_0x4ae996('0x87')]()[_0x4ae996('0x8d')]('u.id')['field']('u.fullname')[_0x4ae996('0x8d')](_0x4ae996('0x1d'))['from'](_0x4ae996('0x30'),'ui')[_0x4ae996('0x4b')](_0x4ae996('0x22'),'u',_0x4ae996('0xb')),_0x12f3ba=squel[_0x4ae996('0x87')]()[_0x4ae996('0x0')](_0x4ae996('0xcb'),'i')['left_join']('cm_contacts','c','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL')[_0x4ae996('0x4b')](_0x4ae996('0x22'),'o',_0x4ae996('0x3e'))['left_join']('mail_accounts','a','a.id\x20=\x20i.MailAccountId')[_0x4ae996('0x4b')](_0x4ae996('0x54'),'me',_0x4ae996('0x32'))[_0x4ae996('0x4b')](_0x4ae996('0x7a'),'it',_0x4ae996('0x10'))[_0x4ae996('0x4b')](_0x4ae996('0x14'),'t',_0x4ae996('0x5a')),_0x3ab1bd=squel[_0x4ae996('0x91')]();let _0x43269b=[];const _0x5c1c61=squel[_0x4ae996('0x91')]();let _0x46916f;if(_0x25ffd5['query'][_0x4ae996('0x11')]){_0x46916f=as[_0x4ae996('0x31')](_0x25ffd5[_0x4ae996('0x98')]['search']);const _0x208f54=_0x46916f[_0x4ae996('0x68')];for(let _0x29dfe2=0x0;_0x29dfe2<_0x46916f[_0x4ae996('0x2f')][_0x4ae996('0x1f')];_0x29dfe2++){const _0x495f7e=_0x46916f['conditions'][_0x29dfe2],_0x22132d='i';let _0x56fcde,_0x438452=_['find'](_0x57ad02,[_0x4ae996('0xc9'),_0x495f7e[_0x4ae996('0x8d')]]);if(!_0x438452)switch(_0x495f7e[_0x4ae996('0x8d')]){case _0x4ae996('0x3d'):_0x495f7e[_0x4ae996('0xad')]==0x1?_0x12f3ba[_0x4ae996('0x49')]('`'+_0x495f7e['field']+'`\x20=\x200'):_0x12f3ba['having']('`'+_0x495f7e[_0x4ae996('0x8d')]+_0x4ae996('0x23'));break;case _0x4ae996('0x60'):if(_0x495f7e[_0x4ae996('0x20')]===_0x4ae996('0xbc')){if(_0x495f7e[_0x4ae996('0xad')][_0x4ae996('0xb5')]('\x20')[_0x4ae996('0x1f')]>0x1)_0x3ab1bd[_0x208f54]('MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs[_0x4ae996('0xc8')](_0x495f7e[_0x4ae996('0xad')]),null);else{const _0x4cc563='%'+_0x495f7e['value']+'%';_0x3ab1bd[_0x208f54](_0x4ae996('0xc'),_0x4cc563,_0x4cc563,_0x4cc563);}}else _0x438452=_[_0x4ae996('0x4a')](_0x57ad02,['name',_0x4ae996('0x18')]),_0x495f7e[_0x4ae996('0x8d')]=_0x4ae996('0x18'),_0x56fcde=as['buildExpression'](_0x22132d,_0x438452[_0x4ae996('0x66')],_0x495f7e),_0x3ab1bd[_0x208f54](_0x56fcde[_0x4ae996('0xcf')],_0x56fcde[_0x4ae996('0xad')]['start'],_0x56fcde['value']['end']);break;case _0x4ae996('0x7b'):{const _0x4e75aa=_0x495f7e[_0x4ae996('0xad')][_0x4ae996('0xb5')](',')['map'](function(_0x293a50){return Number(_0x293a50);});_0x4e75aa[_0x4ae996('0x9d')](function(_0x512614){const _0x2d431e=_0x4ae996;_0x5c1c61['or'](_0x2d431e('0x63'),'%,'+_0x512614+',%');}),_0x43269b=_[_0x4ae996('0x27')](_0x43269b,_0x4e75aa);}break;case'User':_0x495f7e['operator']==='$substring'?_0x3ab1bd[_0x208f54](_0x4ae996('0x70'),'%'+_0x495f7e[_0x4ae996('0xad')]+'%',null):(_0x438452=_[_0x4ae996('0x4a')](_0x57ad02,['name','UserId']),_0x495f7e[_0x4ae996('0x8d')]='UserId',_0x56fcde=as[_0x4ae996('0x96')](_0x22132d,_0x438452[_0x4ae996('0x66')],_0x495f7e),_0x3ab1bd[_0x208f54](_0x56fcde[_0x4ae996('0xcf')],_0x56fcde[_0x4ae996('0xad')][_0x4ae996('0x57')],_0x56fcde[_0x4ae996('0xad')][_0x4ae996('0xa0')]));break;case _0x4ae996('0x58'):_0x56fcde=as[_0x4ae996('0x96')]('me',null,_0x495f7e),_0x3ab1bd[_0x208f54](_0x56fcde[_0x4ae996('0xcf')],_0x56fcde[_0x4ae996('0xad')][_0x4ae996('0x57')],_0x56fcde[_0x4ae996('0xad')][_0x4ae996('0xa0')]);break;}else _0x56fcde=as['buildExpression'](_0x22132d,_0x438452[_0x4ae996('0x66')],_0x495f7e),_0x3ab1bd[_0x208f54](_0x56fcde[_0x4ae996('0xcf')],_0x56fcde[_0x4ae996('0xad')][_0x4ae996('0x57')],_0x56fcde['value']['end']);}}else{const _0x5ccde4=_(_0x25ffd5[_0x4ae996('0x98')])[_0x4ae996('0x88')]()['map'](function(_0x5dc6ed){const _0x5d7e0e=_0x4ae996;return _[_0x5d7e0e('0x95')](_0x57ad02,[_0x5d7e0e('0xc9'),_0x5dc6ed])?_0x5dc6ed:undefined;})['compact']()[_0x4ae996('0xad')]();!_[_0x4ae996('0x80')](_0x5ccde4)&&_0x5ccde4[_0x4ae996('0x9d')](function(_0xcbeb63){const _0x5b6c9b=_0x4ae996;if(_0xcbeb63===_0x5b6c9b('0x41'))_0x12f3ba[_0x5b6c9b('0x5f')](_0x5b6c9b('0x55'),[][_0x5b6c9b('0x9f')](_0x25ffd5[_0x5b6c9b('0x98')][_0xcbeb63]));else{if(_0xcbeb63===_0x5b6c9b('0xb8')){const _0x3c2bff=JSON[_0x5b6c9b('0x7')](_0x25ffd5['query'][_0xcbeb63])[_0x5b6c9b('0x2d')],_0x30f1ff=JSON[_0x5b6c9b('0x7')](_0x25ffd5['query'][_0xcbeb63])[_0x5b6c9b('0x9e')];_0x12f3ba[_0x5b6c9b('0x5f')]('i.createdAt\x20BETWEEN\x20?\x20AND\x20?',_0x3c2bff,_0x30f1ff);}else _0x25ffd5[_0x5b6c9b('0x98')][_0xcbeb63]===_0x5b6c9b('0x56')?_0x12f3ba[_0x5b6c9b('0x5f')]('i.'+_0xcbeb63+_0x5b6c9b('0xa5')):_0x12f3ba[_0x5b6c9b('0x5f')]('i.'+_0xcbeb63+_0x5b6c9b('0x79'),_0x25ffd5['query'][_0xcbeb63]);}});_0x25ffd5[_0x4ae996('0x98')][_0x4ae996('0xab')]&&(_0x25ffd5[_0x4ae996('0x98')][_0x4ae996('0xab')]==0x1?_0x12f3ba[_0x4ae996('0x49')](_0x4ae996('0x4c')):_0x12f3ba[_0x4ae996('0x49')](_0x4ae996('0x83')));_0x25ffd5[_0x4ae996('0x98')][_0x4ae996('0xa1')]&&(_0x43269b=_['isArray'](_0x25ffd5[_0x4ae996('0x98')][_0x4ae996('0xa1')])?_0x25ffd5['query']['tag']:new Array(_0x25ffd5[_0x4ae996('0x98')][_0x4ae996('0xa1')]),_0x43269b[_0x4ae996('0x9d')](function(_0x112747){const _0x5a7709=_0x4ae996;_0x5c1c61['or'](_0x5a7709('0x63'),'%,'+_0x112747+',%');}));if(_0x25ffd5[_0x4ae996('0x98')][_0x4ae996('0x36')]){const _0x5cbd3c=_0x25ffd5[_0x4ae996('0x98')]['filter'][_0x4ae996('0x7e')]('\x5c','\x5c\x5c')[_0x4ae996('0x7e')]('\x27\x27','\x27\x27\x27\x27');if(qs['isNumeric'](_0x5cbd3c))_0x3ab1bd['or'](_0x4ae996('0x26'),_0x5cbd3c+'%');else qs[_0x4ae996('0x82')](_0x5cbd3c)?_0x3ab1bd['or'](_0x4ae996('0x2a'),_0x5cbd3c+'%'):_0x3ab1bd['or'](_0x4ae996('0xb2'),qs['getFullTextValue'](_0x5cbd3c))['or']('MATCH\x20(me.plainBody,\x20me.subject)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs[_0x4ae996('0xc8')](_0x5cbd3c));}}_0x12f3ba[_0x4ae996('0x5f')](_0x3ab1bd),_0x12f3ba['group'](_0x4ae996('0x1a'));let _0x5b28ea={'type':db[_0x4ae996('0x1')]['QueryTypes'][_0x4ae996('0x33')],'raw':!![]};const _0x3e97f2=_0x12f3ba['clone']();_0x3e97f2[_0x4ae996('0x8d')](_0x4ae996('0x1a')),_0x3e97f2['field'](_0x4ae996('0x97'),'unreadMessages'),_0x25274d[_0x4ae996('0x71')]&&_0x25274d[_0x4ae996('0x71')]['forEach'](function(_0xe963fb){const _0xe2691d=_0x4ae996;_0x12f3ba[_0xe2691d('0x71')]('i.'+_0xe963fb[0x0],_0xe963fb[0x1]===_0xe2691d('0xd5')?![]:!![]);}),!_['isEmpty'](_0x43269b)&&(_0x12f3ba[_0x4ae996('0x49')](_0x5c1c61),_0x3e97f2[_0x4ae996('0x5f')](_0x4ae996('0x65'),_0x43269b)),Promise['resolve']()[_0x4ae996('0xd2')](function(){const _0x580913=_0x4ae996;if(!_0x46916f){if(_0x25ffd5[_0x580913('0x98')][_0x580913('0x41')]||_0x25ffd5['query'][_0x580913('0x9b')])return;_0x3e97f2[_0x580913('0x5f')]('i.MailAccountId\x20IS\x20NOT\x20NULL'),_0x12f3ba[_0x580913('0x5f')]('i.MailAccountId\x20IS\x20NOT\x20NULL');return;}return _0x25ffd5['user']['getMailAccounts']({'attributes':['id'],'raw':!![]})['then'](function(_0x40c872){const _0x47b230=_0x580913;_[_0x47b230('0x80')](_0x40c872)?(_0x3e97f2['where'](_0x47b230('0xc2')),_0x12f3ba[_0x47b230('0x5f')](_0x47b230('0xc2'))):(_0x3e97f2[_0x47b230('0x5f')](_0x47b230('0x55'),_[_0x47b230('0x90')](_0x40c872,'id')),_0x12f3ba['where'](_0x47b230('0x55'),_[_0x47b230('0x90')](_0x40c872,'id')));});})[_0x4ae996('0xd2')](function(){const _0xfa6d38=_0x4ae996;db[_0xfa6d38('0xcc')][_0xfa6d38('0x98')](_0x3e97f2[_0xfa6d38('0xd0')](),_0x5b28ea)[_0xfa6d38('0xd2')](function(_0xf44dd9){const _0x1aed6b=_0xfa6d38;_0x5e6273[_0x1aed6b('0x92')]=_0xf44dd9[_0x1aed6b('0x1f')];if(_0x5e6273[_0x1aed6b('0x92')]===0x0)return[];return db['sequelize'][_0x1aed6b('0x98')](_0x374e48['toString'](),_0x5b28ea)['then'](function(_0x4acd4a){const _0x3d9f60=_0x1aed6b;_0xba21dc=_[_0x3d9f60('0x37')](_0x4acd4a,'id'),_0x5b28ea=_[_0x3d9f60('0xbe')](_0x5b28ea,{'model':db['MailInteraction'],'mapToModel':!![],'raw':!![],'nest':!![]});_0x25ffd5[_0x3d9f60('0x98')][_0x3d9f60('0x8c')]?_0x25274d[_0x3d9f60('0xba')][_0x3d9f60('0x9d')](function(_0x35a339){const _0x18253b=_0x3d9f60;_0x12f3ba[_0x18253b('0x8d')]('i.'+_0x35a339);}):(_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x97'),_0x3d9f60('0x3d')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x53'),_0x3d9f60('0x72')),_0x12f3ba[_0x3d9f60('0x8d')]('a.mandatoryDisposition',_0x3d9f60('0x44')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x1a')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0xc4')),_0x12f3ba['field']('i.updatedAt'),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x75')),_0x12f3ba[_0x3d9f60('0x8d')]('i.closedAt'),_0x12f3ba[_0x3d9f60('0x8d')]('i.attach'),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x2')),_0x12f3ba[_0x3d9f60('0x8d')]('i.lastMsgDirection'),_0x12f3ba[_0x3d9f60('0x8d')]('i.subject'),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0xc6')),_0x12f3ba['field'](_0x3d9f60('0x21')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0xb9')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x6d')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x52')),_0x12f3ba['field'](_0x3d9f60('0x93')),_0x12f3ba['field'](_0x3d9f60('0xc0')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x50')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x28'),_0x3d9f60('0x85')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0xa2'),_0x3d9f60('0xf')),_0x12f3ba['field'](_0x3d9f60('0x3f'),'Contact.email'),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x5e'),_0x3d9f60('0x6f')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x47'),_0x3d9f60('0xbf')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0xd6'),_0x3d9f60('0x16')),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0xb3'),_0x3d9f60('0xd3')),_0x12f3ba[_0x3d9f60('0x8d')]('o.internal','Owner.internal'),_0x12f3ba[_0x3d9f60('0x8d')](_0x3d9f60('0x2c'),_0x3d9f60('0x6c')));if(_0x25274d[_0x3d9f60('0x8e')])_0x12f3ba[_0x3d9f60('0x8e')](_0x25274d[_0x3d9f60('0x8e')]);if(_0x25274d[_0x3d9f60('0x9a')])_0x12f3ba[_0x3d9f60('0x9a')](_0x25274d[_0x3d9f60('0x9a')]);return db[_0x3d9f60('0xcc')][_0x3d9f60('0x98')](_0x12f3ba[_0x3d9f60('0xd0')](),_0x5b28ea);})[_0x1aed6b('0xd2')](function(_0x8861b4){const _0x5157ed=_0x1aed6b;return _0x3846b8['where'](_0x5157ed('0x1b'),_[_0x5157ed('0x90')](_0x8861b4,'id')),db[_0x5157ed('0xcc')][_0x5157ed('0x98')](_0x3846b8['toString'](),_0x5b28ea)[_0x5157ed('0xd2')](function(_0x5c7440){const _0x355132=_0x5157ed,_0x33ad6f=_[_0x355132('0xa8')](_0x5c7440,_0x355132('0x9')),_0x5d3a04=[];return db[_0x355132('0xa3')][_0x355132('0x7c')]({'attributes':[_0x355132('0x43')],'raw':!![]})[_0x355132('0xd2')](function(_0xa95b3){const _0x1ae1c1=_0x355132,_0x200f55=_0xa95b3[_0x1ae1c1('0x43')];return _0x8861b4[_0x1ae1c1('0x9d')](function(_0x3d3f2a){const _0x12f92a=_0x1ae1c1;_0x5d3a04[_0x12f92a('0x24')](updateMailInteraction(_0x3d3f2a,_0xba21dc,_0x33ad6f,_0x200f55));}),Promise[_0x1ae1c1('0xaf')](_0x5d3a04);});});});})[_0xfa6d38('0xd2')](function(_0x494cf0){const _0x467837=_0xfa6d38;return _0x5e6273[_0x467837('0x3a')]=_0x494cf0,_0x5e6273;})[_0xfa6d38('0xd2')](respondWithFilteredResult(_0x4a45c4,_0x25274d));})[_0x4ae996('0x38')](handleError(_0x4a45c4,null));},exports[_0x721b48('0x45')]=function(_0x41e5bc,_0x2f062c){const _0x5bfb80=_0x721b48;let _0x187a99={'raw':![],'where':{'id':_0x41e5bc[_0x5bfb80('0x8b')]['id']}};const _0x26b72d={};return _0x26b72d['model']=_[_0x5bfb80('0x88')](db[_0x5bfb80('0x94')]['rawAttributes']),_0x26b72d[_0x5bfb80('0x98')]=_[_0x5bfb80('0x88')](_0x41e5bc['query']),_0x26b72d['filters']=_[_0x5bfb80('0xa6')](_0x26b72d[_0x5bfb80('0xa9')],_0x26b72d['query']),_0x187a99[_0x5bfb80('0xba')]=_['intersection'](_0x26b72d[_0x5bfb80('0xa9')],qs['fields'](_0x41e5bc[_0x5bfb80('0x98')][_0x5bfb80('0x8c')])),_0x187a99[_0x5bfb80('0xba')]=_0x187a99['attributes'][_0x5bfb80('0x1f')]?_0x187a99[_0x5bfb80('0xba')]:_0x26b72d[_0x5bfb80('0xa9')],_0x41e5bc[_0x5bfb80('0x98')][_0x5bfb80('0x8f')]&&(_0x187a99[_0x5bfb80('0xac')]=[{'all':!![]}]),_0x187a99=_['merge']({},_0x187a99,_0x41e5bc[_0x5bfb80('0x3b')]),db[_0x5bfb80('0x94')][_0x5bfb80('0x7c')](_0x187a99)[_0x5bfb80('0xd2')](handleEntityNotFound(_0x2f062c,null))['then'](respondWithResult(_0x2f062c,null))[_0x5bfb80('0x38')](handleError(_0x2f062c,null));},exports[_0x721b48('0x7f')]=function(_0x5d7b64,_0x479189){const _0x26272f=_0x721b48;return db[_0x26272f('0x94')]['create'](_0x5d7b64['body'],{})[_0x26272f('0xd2')](respondWithResult(_0x479189,0xc9))[_0x26272f('0x38')](handleError(_0x479189,null));},exports['update']=function(_0x5e2acb,_0x4b140e){const _0x266e9e=_0x721b48;return _0x5e2acb[_0x266e9e('0xd1')]['id']&&delete _0x5e2acb[_0x266e9e('0xd1')]['id'],db[_0x266e9e('0x94')][_0x266e9e('0x7c')]({'where':{'id':_0x5e2acb[_0x266e9e('0x8b')]['id']}})[_0x266e9e('0xd2')](handleEntityNotFound(_0x4b140e,null))[_0x266e9e('0xd2')](saveUpdates(_0x5e2acb[_0x266e9e('0xd1')],null))[_0x266e9e('0xd2')](respondWithResult(_0x4b140e,null))['catch'](handleError(_0x4b140e,null));},exports[_0x721b48('0xbd')]=function(_0x11554f,_0x374682){const _0x7784d1=_0x721b48;return db[_0x7784d1('0x94')][_0x7784d1('0x7c')]({'where':{'id':_0x11554f[_0x7784d1('0x8b')]['id']}})[_0x7784d1('0xd2')](handleEntityNotFound(_0x374682,null))[_0x7784d1('0xd2')](removeEntity(_0x374682,null))['catch'](handleError(_0x374682,null));},exports[_0x721b48('0x25')]=function(_0x3c5177,_0x41477d){const _0x24ee57=_0x721b48;return db[_0x24ee57('0x94')][_0x24ee57('0x25')]()[_0x24ee57('0xd2')](respondWithResult(_0x41477d,null))['catch'](handleError(_0x41477d,null));},exports[_0x721b48('0x12')]=function(_0x10357d,_0x21e926){const _0x34de01=_0x721b48;return db[_0x34de01('0x35')][_0x34de01('0x7c')]({'where':{'id':_0x10357d[_0x34de01('0x8b')]['id']}})[_0x34de01('0xd2')](function(_0x12606f){const _0x30bbde=_0x34de01;if(_0x12606f)return _0x12606f[_0x30bbde('0x12')](_0x10357d[_0x30bbde('0xd1')][_0x30bbde('0x2b')],{'through':_[_0x30bbde('0xa')](_0x10357d['body'],[_0x30bbde('0x2b'),'id'])});})[_0x34de01('0xd2')](respondWithResult(_0x21e926,null))[_0x34de01('0x38')](handleError(_0x21e926,null));},exports[_0x721b48('0xc1')]=function(_0x3c2a62,_0x3e4d94){const _0x54e535=_0x721b48;let _0x1e5d4={'raw':![],'where':{}};const _0x410cf5={},_0x56036b={'count':0x0,'rows':[]};return db['MailInteraction'][_0x54e535('0x7c')]({'where':{'id':_0x3c2a62[_0x54e535('0x8b')]['id']}})[_0x54e535('0xd2')](handleEntityNotFound(_0x3e4d94,null))[_0x54e535('0xd2')](function(_0x1e89d7){const _0x33578e=_0x54e535;if(_0x1e89d7){_0x410cf5[_0x33578e('0xa9')]=_[_0x33578e('0x88')](db['MailMessage'][_0x33578e('0x13')]),_0x410cf5[_0x33578e('0x98')]=_[_0x33578e('0x88')](_0x3c2a62['query']),_0x410cf5[_0x33578e('0xd')]=_[_0x33578e('0xa6')](_0x410cf5['model'],_0x410cf5[_0x33578e('0x98')]),_0x1e5d4[_0x33578e('0xba')]=_[_0x33578e('0xa6')](_0x410cf5[_0x33578e('0xa9')],qs['fields'](_0x3c2a62[_0x33578e('0x98')][_0x33578e('0x8c')])),_0x1e5d4['attributes']=_0x1e5d4['attributes'][_0x33578e('0x1f')]?_0x1e5d4['attributes']:_0x410cf5['model'];typeof _0x3c2a62[_0x33578e('0x98')][_0x33578e('0xb6')]===_0x33578e('0xb0')&&(_0x1e5d4['limit']=qs[_0x33578e('0x8e')](_0x3c2a62[_0x33578e('0x98')][_0x33578e('0x8e')]),_0x1e5d4[_0x33578e('0x9a')]=qs[_0x33578e('0x9a')](_0x3c2a62[_0x33578e('0x98')][_0x33578e('0x9a')]));_0x1e5d4['order']=qs[_0x33578e('0x34')](_0x3c2a62['query'][_0x33578e('0x34')]),_0x1e5d4['where']=qs[_0x33578e('0xd')](_[_0x33578e('0x84')](_0x3c2a62['query'],_0x410cf5[_0x33578e('0xd')])),_0x1e5d4[_0x33578e('0x5f')][_0x33578e('0x9')]=_0x1e89d7['id'];_0x3c2a62['query'][_0x33578e('0x36')]&&(_0x1e5d4[_0x33578e('0x5f')]=_[_0x33578e('0xbe')](_0x1e5d4['where'],{[Op['or']]:_[_0x33578e('0x90')](_0x1e5d4[_0x33578e('0xba')],function(_0x285cbf){const _0x473050=_0x33578e,_0x42ec3d={};return _0x42ec3d[_0x285cbf]={[Op['like']]:'%'+_0x3c2a62[_0x473050('0x98')]['filter']+'%'},_0x42ec3d;})}));if(_0x3c2a62[_0x33578e('0x98')][_0x33578e('0x2d')]){const _0x4f5643=_0x3c2a62[_0x33578e('0x98')][_0x33578e('0x2d')]['split'](','),_0xc45c86={};_0xc45c86[_0x4f5643[0x0]]={[Op[_0x33578e('0x5c')]]:moment(_0x4f5643[0x1])[_0x33578e('0xbb')](_0x33578e('0x6b'))},_0x1e5d4['where']=_[_0x33578e('0xbe')](_0x1e5d4[_0x33578e('0x5f')],_0xc45c86);}return _0x1e5d4=_[_0x33578e('0xbe')]({},_0x1e5d4,_0x3c2a62[_0x33578e('0x3b')]),db[_0x33578e('0x35')][_0x33578e('0x92')]({'where':_0x1e5d4[_0x33578e('0x5f')]})[_0x33578e('0xd2')](function(_0x3ad44c){const _0x508893=_0x33578e;return _0x56036b['count']=_0x3ad44c,_0x3c2a62['query'][_0x508893('0x8f')]&&(_0x1e5d4['include']=[{'all':!![]}]),db[_0x508893('0x35')]['findAll'](_0x1e5d4);})[_0x33578e('0xd2')](function(_0x4785d9){return _0x56036b['rows']=_0x4785d9,_0x56036b;});}})[_0x54e535('0xd2')](respondWithFilteredResult(_0x3e4d94,_0x1e5d4))['catch'](handleError(_0x3e4d94,null));},exports[_0x721b48('0xe')]=function(_0x4ceeda,_0x236b13){const _0x485129=_0x721b48;return db[_0x485129('0x94')][_0x485129('0x7c')]({'where':{'id':_0x4ceeda[_0x485129('0x8b')]['id']}})[_0x485129('0xd2')](function(_0x2a482b){const _0x17da30=_0x485129;if(_0x2a482b)return _0x2a482b['setTags'](_0x4ceeda[_0x17da30('0xd1')][_0x17da30('0x2b')],{'through':_[_0x17da30('0xa')](_0x4ceeda[_0x17da30('0xd1')],[_0x17da30('0x2b'),'id'])})['then'](function(){const _0xe0f2c1=_0x17da30;return db[_0xe0f2c1('0x7b')][_0xe0f2c1('0x29')]({'attributes':['id',_0xe0f2c1('0xc9'),_0xe0f2c1('0xaa')],'where':{'id':_0x4ceeda[_0xe0f2c1('0xd1')][_0xe0f2c1('0x2b')]}});})['then'](function(_0x39d952){const _0x59ba8b=_0x17da30;return socket[_0x59ba8b('0x59')]('mailInteractionTags:save',{'id':Number(_0x4ceeda[_0x59ba8b('0x8b')]['id']),'tags':_0x39d952||[]}),{'id':Number(_0x4ceeda['params']['id']),'tags':_0x39d952||[]};});})[_0x485129('0xd2')](respondWithResult(_0x236b13,null))[_0x485129('0x38')](handleError(_0x236b13,null));},exports[_0x721b48('0x6a')]=function(_0x1d85ee,_0x3cb4f0){const _0x1026bd=_0x721b48;return db[_0x1026bd('0x94')][_0x1026bd('0x7c')]({'where':{'id':_0x1d85ee['params']['id']}})[_0x1026bd('0xd2')](handleEntityNotFound(_0x3cb4f0,null))[_0x1026bd('0xd2')](function(_0x29dfbc){const _0x1020fc=_0x1026bd;if(_0x29dfbc)return _0x29dfbc[_0x1020fc('0x6a')](_0x1d85ee['query'][_0x1020fc('0x2b')]);})['then'](respondWithStatusCode(_0x3cb4f0,null))[_0x1026bd('0x38')](handleError(_0x3cb4f0,null));},exports['download']=function(_0x3dc40e,_0x594250){const _0x4c4886=_0x721b48,_0x402d2d=moment()[_0x4c4886('0x15')]()['toString'](),_0x538cc6=path[_0x4c4886('0xc7')](config[_0x4c4886('0xca')],'files',_0x4c4886('0x5d')),_0x517a6c=path[_0x4c4886('0xc7')](config[_0x4c4886('0xca')],_0x4c4886('0x5'),_0x4c4886('0x99'),'attachments'),_0x44809b=path['join'](_0x538cc6,_0x402d2d),_0x576d77=util[_0x4c4886('0xbb')](_0x4c4886('0xae'),_0x3dc40e[_0x4c4886('0x8b')]['id'],_0x402d2d),_0x597f2b=path['join'](_0x538cc6,_0x576d77),_0x14d4f7=[];_0x3dc40e[_0x4c4886('0x98')][_0x4c4886('0x2e')]&&_0x14d4f7['push']({'model':db[_0x4c4886('0x9c')],'as':_0x4c4886('0x17'),'raw':!![]});const _0x45a485=[{'model':db['MailMessage'],'as':_0x4c4886('0x6'),'attributes':['id','body',_0x4c4886('0x0'),'to','cc',_0x4c4886('0x64'),_0x4c4886('0xa4'),'createdAt'],'where':{'secret':![]},'order':qs[_0x4c4886('0x34')]('id'),'include':_0x14d4f7}];return db['MailInteraction']['findOne']({'where':{'id':_0x3dc40e['params']['id']},'include':_0x45a485})[_0x4c4886('0xd2')](handleEntityNotFound(_0x594250,null))[_0x4c4886('0xd2')](function(_0x48cf5f){const _0x1a94e6=_0x4c4886;if(_0x48cf5f&&_0x48cf5f[_0x1a94e6('0x6')]){const _0x2dec59=_0x48cf5f[_0x1a94e6('0x7d')]({'plain':!![]});return fs[_0x1a94e6('0x40')](_0x44809b),Promise[_0x1a94e6('0xcd')](_0x2dec59[_0x1a94e6('0x6')],function(_0x3595c6,_0x1f4af4){const _0x38bf4a=_0x1a94e6,_0x13d567={'from':_0x3595c6[_0x38bf4a('0x0')],'to':_0x3595c6['to'],'subject':_0x3595c6[_0x38bf4a('0xa4')],'html':_0x3595c6['body'],'headers':{'Date':moment(_0x3595c6['createdAt'])[_0x38bf4a('0xbb')]('ddd,\x20DD\x20MMM\x20YYYY\x20HH:mm:ss\x20ZZ')},'attachments':[]};return _0x3595c6['cc']&&(_0x13d567['headers']['Cc']=_0x3595c6['cc']),_0x3595c6[_0x38bf4a('0x64')]&&(_0x13d567['headers'][_0x38bf4a('0x61')]=_0x3595c6[_0x38bf4a('0x64')]),new Promise(function(_0x551dab,_0xad6ec1){const _0x1b49f4=_0x38bf4a;if(_0x3595c6[_0x1b49f4('0x17')])for(let _0x2ce0aa=0x0;_0x2ce0aa<_0x3595c6['Attachments'][_0x1b49f4('0x1f')];_0x2ce0aa++){const _0x47d380=_0x3595c6[_0x1b49f4('0x17')][_0x2ce0aa],_0x598786=path[_0x1b49f4('0xc7')](_0x517a6c,_0x47d380[_0x1b49f4('0xc3')]);fs[_0x1b49f4('0x74')](_0x598786)&&_0x13d567[_0x1b49f4('0x2e')]['push']({'name':_0x47d380[_0x1b49f4('0xc9')],'contentType':_0x47d380[_0x1b49f4('0x66')],'data':fs[_0x1b49f4('0x89')](_0x598786)});}emlformat[_0x1b49f4('0x51')](_0x13d567,function(_0x5561d7,_0x349c71){const _0x3db53f=_0x1b49f4;if(_0x5561d7)return _0xad6ec1(_0x5561d7);return fs[_0x3db53f('0x5b')](path[_0x3db53f('0xc7')](_0x44809b,util[_0x3db53f('0xbb')](_0x3db53f('0x4'),_0x1f4af4)),_0x349c71),_0x551dab(_0x349c71);});});})[_0x1a94e6('0xd2')](function(){const _0x1867c5=_0x1a94e6;return new Promise(function(_0x2a77b2,_0x5a61fe){zipdir(_0x44809b,{'saveTo':_0x597f2b},function(_0x4531c5,_0x2dee60){if(_0x4531c5)return _0x5a61fe(_0x4531c5);return _0x2a77b2(_0x2dee60);});})['then'](function(){return new Promise(function(_0x130e0f,_0x350159){rimraf(_0x44809b,function(_0x7eabd){if(_0x7eabd)_0x350159(_0x7eabd);return _0x130e0f();});});})[_0x1867c5('0xd2')](function(){const _0x2023fa=_0x1867c5;return _0x594250[_0x2023fa('0x4d')](_0x597f2b,_0x576d77,function(_0x505d7f){const _0x5bf7e2=_0x2023fa;_0x505d7f?console[_0x5bf7e2('0x73')](_0x5bf7e2('0x1e'),_0x505d7f):fs[_0x5bf7e2('0x86')](_0x597f2b);});});});}else return _0x594250[_0x1a94e6('0xa7')](0xc8);})[_0x4c4886('0x38')](handleError(_0x594250,null));}; \ No newline at end of file diff --git a/server/api/mailInteraction/mailInteraction.events.js b/server/api/mailInteraction/mailInteraction.events.js index 8cd3b0f..38b2d1b 100644 --- a/server/api/mailInteraction/mailInteraction.events.js +++ b/server/api/mailInteraction/mailInteraction.events.js @@ -1 +1 @@ -const a407_0x37b4=['setDataValue','length','emit','findAll','MailMessage','Users','catch','update','unreadMessages','map','../../mysqldb','setMaxListeners','events'];(function(_0x31c5f0,_0x37b4f8){const _0x2cd056=function(_0x128f25){while(--_0x128f25){_0x31c5f0['push'](_0x31c5f0['shift']());}};_0x2cd056(++_0x37b4f8);}(a407_0x37b4,0x1b2));const a407_0x2cd0=function(_0x31c5f0,_0x37b4f8){_0x31c5f0=_0x31c5f0-0x0;let _0x2cd056=a407_0x37b4[_0x31c5f0];return _0x2cd056;};const _0x21e34c=a407_0x2cd0;'use strict';const EventEmitter=require(_0x21e34c('0x7')),MailInteraction=require(_0x21e34c('0x5'))['db']['MailInteraction'],MailMessage=require(_0x21e34c('0x5'))['db'][_0x21e34c('0xc')],MailInteractionEvents=new EventEmitter();MailInteractionEvents[_0x21e34c('0x6')](0x0);const events={'afterCreate':'save','afterUpdate':_0x21e34c('0x2'),'afterDestroy':'remove'};function emitEvent(_0x128f25){return function(_0x4a691e){const _0x3aa890=a407_0x2cd0;_0x4a691e['getUsers']({'attributes':['id'],'raw':!![]})['then'](function(_0x5d0c09){const _0x2b13ec=a407_0x2cd0;return _0x4a691e[_0x2b13ec('0x8')](_0x2b13ec('0x0'),_0x5d0c09[_0x2b13ec('0x4')](function(_0x24a274){return{'id':_0x24a274['id']};})),MailMessage[_0x2b13ec('0xb')]({'where':{'MailInteractionId':_0x4a691e['id'],'direction':'in','read':![]},'raw':!![]});})['then'](function(_0x381151){const _0x346f1b=a407_0x2cd0;_0x4a691e[_0x346f1b('0x8')](_0x346f1b('0x3'),_0x381151[_0x346f1b('0x9')]),MailInteractionEvents['emit'](_0x128f25+':'+_0x4a691e['id'],_0x4a691e),MailInteractionEvents[_0x346f1b('0xa')](_0x128f25,_0x4a691e);})[_0x3aa890('0x1')](()=>{});};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];MailInteraction['addHook'](e,emitEvent(event));}}module['exports']=MailInteractionEvents; \ No newline at end of file +const a407_0x4e01=['exports','getUsers','addHook','findAll','then','emit','length','MailMessage','../../mysqldb','setDataValue','catch','MailInteraction','Users','setMaxListeners','unreadMessages','map','save'];(function(_0x1e512d,_0x4e01a0){const _0x573634=function(_0x50f2f5){while(--_0x50f2f5){_0x1e512d['push'](_0x1e512d['shift']());}};_0x573634(++_0x4e01a0);}(a407_0x4e01,0x16b));const a407_0x5736=function(_0x1e512d,_0x4e01a0){_0x1e512d=_0x1e512d-0x0;let _0x573634=a407_0x4e01[_0x1e512d];return _0x573634;};const _0x232c26=a407_0x5736;'use strict';const EventEmitter=require('events'),MailInteraction=require(_0x232c26('0x2'))['db'][_0x232c26('0x5')],MailMessage=require(_0x232c26('0x2'))['db'][_0x232c26('0x1')],MailInteractionEvents=new EventEmitter();MailInteractionEvents[_0x232c26('0x7')](0x0);const events={'afterCreate':_0x232c26('0xa'),'afterUpdate':'update','afterDestroy':'remove'};function emitEvent(_0x50f2f5){return function(_0x20b290){const _0x2f35f2=a407_0x5736;_0x20b290[_0x2f35f2('0xc')]({'attributes':['id'],'raw':!![]})['then'](function(_0x40d656){const _0x46f2b0=_0x2f35f2;return _0x20b290[_0x46f2b0('0x3')](_0x46f2b0('0x6'),_0x40d656[_0x46f2b0('0x9')](function(_0x2ceaf7){return{'id':_0x2ceaf7['id']};})),MailMessage[_0x46f2b0('0xe')]({'where':{'MailInteractionId':_0x20b290['id'],'direction':'in','read':![]},'raw':!![]});})[_0x2f35f2('0xf')](function(_0x1fcf5d){const _0x1edd8c=_0x2f35f2;_0x20b290['setDataValue'](_0x1edd8c('0x8'),_0x1fcf5d[_0x1edd8c('0x0')]),MailInteractionEvents[_0x1edd8c('0x10')](_0x50f2f5+':'+_0x20b290['id'],_0x20b290),MailInteractionEvents[_0x1edd8c('0x10')](_0x50f2f5,_0x20b290);})[_0x2f35f2('0x4')](()=>{});};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];MailInteraction[_0x232c26('0xd')](e,emitEvent(event));}}module[_0x232c26('0xb')]=MailInteractionEvents; \ No newline at end of file diff --git a/server/api/mailInteraction/mailInteraction.model.js b/server/api/mailInteraction/mailInteraction.model.js index 5127aaa..db07676 100644 --- a/server/api/mailInteraction/mailInteraction.model.js +++ b/server/api/mailInteraction/mailInteraction.model.js @@ -1 +1 @@ -const a408_0x523c=['utf8mb4_unicode_ci','subject','catch','get','MailInteraction','closed','moment','MailMessage','substatusAt','YYYY-MM-DD\x20HH:mm:ss','models','exports','closedAt','fti_mail_interactions','changed','substatus','update','format','FULLTEXT','utf8mb4','define'];(function(_0x4e0c98,_0x523ced){const _0x18812f=function(_0x424d75){while(--_0x424d75){_0x4e0c98['push'](_0x4e0c98['shift']());}};_0x18812f(++_0x523ced);}(a408_0x523c,0xab));const a408_0x1881=function(_0x4e0c98,_0x523ced){_0x4e0c98=_0x4e0c98-0x0;let _0x18812f=a408_0x523c[_0x4e0c98];return _0x18812f;};const _0x7b135c=a408_0x1881;'use strict';const moment=require(_0x7b135c('0x3')),attributes=require('./mailInteraction.attributes');module[_0x7b135c('0x8')]=function(_0x424d75){const _0x25f097=_0x7b135c,_0x30ffce=_0x424d75[_0x25f097('0x7')],_0x45e98a=_0x424d75[_0x25f097('0x11')](_0x25f097('0x1'),attributes,{'tableName':'mail_interactions','paranoid':![],'indexes':[{'name':_0x25f097('0xa'),'fields':[_0x25f097('0x13'),'to'],'type':_0x25f097('0xf')}],'timestamps':!![],'hooks':{'beforeCreate':function(_0xba3a0c){const _0x240d0d=_0x25f097;_0xba3a0c[_0x240d0d('0xc')]&&(_0xba3a0c[_0x240d0d('0x5')]=moment()['format'](_0x240d0d('0x6'))),_0xba3a0c['closed']&&(_0xba3a0c['closedAt']=moment()[_0x240d0d('0xe')]('YYYY-MM-DD\x20HH:mm:ss'));},'beforeUpdate':function(_0x4f6afd){const _0x1c24c5=_0x25f097;_0x4f6afd[_0x1c24c5('0xb')](_0x1c24c5('0xc'))&&(_0x4f6afd['substatusAt']=_0x4f6afd[_0x1c24c5('0xc')]?moment()[_0x1c24c5('0xe')]('YYYY-MM-DD\x20HH:mm:ss'):null),_0x4f6afd[_0x1c24c5('0xb')](_0x1c24c5('0x2'))&&(_0x4f6afd[_0x1c24c5('0x9')]=moment()['format'](_0x1c24c5('0x6')),_0x4f6afd[_0x1c24c5('0xc')]=null,_0x4f6afd[_0x1c24c5('0x5')]=null);},'afterUpdate':function(_0x261d45){const _0x199e9f=_0x25f097,_0x2a0151=_0x261d45[_0x199e9f('0x0')]({'plain':!![]});if(_0x2a0151['closed'])return _0x30ffce[_0x199e9f('0x4')][_0x199e9f('0xd')]({'read':!![]},{'where':{'MailInteractionId':_0x2a0151['id']}})[_0x199e9f('0x14')](function(_0x38cc35){return _0x38cc35;});}},'charset':_0x25f097('0x10'),'collate':_0x25f097('0x12')});return _0x45e98a;}; \ No newline at end of file +const a408_0x3d61=['update','get','changed','exports','utf8mb4','substatus','utf8mb4_unicode_ci','fti_mail_interactions','closed','subject','./mailInteraction.attributes','closedAt','catch','FULLTEXT','MailInteraction','substatusAt','MailMessage','format','define','YYYY-MM-DD\x20HH:mm:ss','models','moment'];(function(_0x16e9c3,_0x3d6114){const _0x214c76=function(_0x120d69){while(--_0x120d69){_0x16e9c3['push'](_0x16e9c3['shift']());}};_0x214c76(++_0x3d6114);}(a408_0x3d61,0xe8));const a408_0x214c=function(_0x16e9c3,_0x3d6114){_0x16e9c3=_0x16e9c3-0x0;let _0x214c76=a408_0x3d61[_0x16e9c3];return _0x214c76;};const _0x182e7b=a408_0x214c;'use strict';const moment=require(_0x182e7b('0x9')),attributes=require(_0x182e7b('0x14'));module[_0x182e7b('0xd')]=function(_0x120d69){const _0x300fbc=_0x182e7b,_0x3a6f81=_0x120d69[_0x300fbc('0x8')],_0x38928d=_0x120d69[_0x300fbc('0x6')](_0x300fbc('0x2'),attributes,{'tableName':'mail_interactions','paranoid':![],'indexes':[{'name':_0x300fbc('0x11'),'fields':[_0x300fbc('0x13'),'to'],'type':_0x300fbc('0x1')}],'timestamps':!![],'hooks':{'beforeCreate':function(_0x3bce20){const _0xcac649=_0x300fbc;_0x3bce20[_0xcac649('0xf')]&&(_0x3bce20[_0xcac649('0x3')]=moment()[_0xcac649('0x5')](_0xcac649('0x7'))),_0x3bce20['closed']&&(_0x3bce20['closedAt']=moment()[_0xcac649('0x5')](_0xcac649('0x7')));},'beforeUpdate':function(_0x1fbb97){const _0x5689d5=_0x300fbc;_0x1fbb97[_0x5689d5('0xc')]('substatus')&&(_0x1fbb97['substatusAt']=_0x1fbb97[_0x5689d5('0xf')]?moment()[_0x5689d5('0x5')]('YYYY-MM-DD\x20HH:mm:ss'):null),_0x1fbb97[_0x5689d5('0xc')](_0x5689d5('0x12'))&&(_0x1fbb97[_0x5689d5('0x15')]=moment()[_0x5689d5('0x5')]('YYYY-MM-DD\x20HH:mm:ss'),_0x1fbb97[_0x5689d5('0xf')]=null,_0x1fbb97[_0x5689d5('0x3')]=null);},'afterUpdate':function(_0x3577b1){const _0x56160c=_0x300fbc,_0x3b13fc=_0x3577b1[_0x56160c('0xb')]({'plain':!![]});if(_0x3b13fc[_0x56160c('0x12')])return _0x3a6f81[_0x56160c('0x4')][_0x56160c('0xa')]({'read':!![]},{'where':{'MailInteractionId':_0x3b13fc['id']}})[_0x56160c('0x0')](function(_0x1b3e9a){return _0x1b3e9a;});}},'charset':_0x300fbc('0xe'),'collate':_0x300fbc('0x10')});return _0x38928d;}; \ No newline at end of file diff --git a/server/api/mailInteraction/mailInteraction.rpc.js b/server/api/mailInteraction/mailInteraction.rpc.js index f2e330f..f0b273f 100644 --- a/server/api/mailInteraction/mailInteraction.rpc.js +++ b/server/api/mailInteraction/mailInteraction.rpc.js @@ -1 +1 @@ -const a409_0x1ac7=['./mailInteraction.socket','options','where','rpc','register','../../rediscache','addTags','AddTags','update','MailInteraction','error','attributes','../../config/logger','body','then','../../mysqldb','findOne','UpdateMailInteraction','catch','message','lodash','omit','stringify','debug','AddTagsToMailInteraction'];(function(_0x1f15c4,_0x1ac743){const _0x43a7bb=function(_0x2996a4){while(--_0x2996a4){_0x1f15c4['push'](_0x1f15c4['shift']());}};_0x43a7bb(++_0x1ac743);}(a409_0x1ac7,0xf3));const a409_0x43a7=function(_0x1f15c4,_0x1ac743){_0x1f15c4=_0x1f15c4-0x0;let _0x43a7bb=a409_0x1ac7[_0x1f15c4];return _0x43a7bb;};const _0x3ea6d0=a409_0x43a7;'use strict';const _=require(_0x3ea6d0('0x2')),db=require(_0x3ea6d0('0x16'))['db'],logger=require(_0x3ea6d0('0x13'))(_0x3ea6d0('0xa')),{getSocket}=require(_0x3ea6d0('0xc')),socket=getSocket();require(_0x3ea6d0('0x7'))[_0x3ea6d0('0xb')](socket),exports['UpdateMailInteraction']=function(_0x2996a4){const _0x3aa20c=this;return new Promise(function(_0x19ce87,_0x392a21){const _0x5a37f0=a409_0x43a7;return db[_0x5a37f0('0x10')][_0x5a37f0('0xf')](_0x2996a4[_0x5a37f0('0x14')],{'raw':_0x2996a4[_0x5a37f0('0x8')]?_0x2996a4[_0x5a37f0('0x8')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x2996a4[_0x5a37f0('0x8')]?_0x2996a4[_0x5a37f0('0x8')][_0x5a37f0('0x9')]||null:null,'attributes':_0x2996a4[_0x5a37f0('0x8')]?_0x2996a4[_0x5a37f0('0x8')][_0x5a37f0('0x12')]||null:null,'limit':_0x2996a4[_0x5a37f0('0x8')]?_0x2996a4[_0x5a37f0('0x8')]['limit']||null:null})[_0x5a37f0('0x15')](function(_0x22638c){const _0xf29c0b=_0x5a37f0;logger['info'](_0xf29c0b('0x18'),_0x2996a4),logger['debug'](_0xf29c0b('0x18'),_0x2996a4,JSON[_0xf29c0b('0x4')](_0x22638c)),_0x19ce87(_0x22638c);})[_0x5a37f0('0x0')](function(_0x2abafb){const _0x3d22d7=_0x5a37f0;logger[_0x3d22d7('0x11')](_0x3d22d7('0x18'),_0x2abafb['message'],_0x2996a4),_0x392a21(_0x3aa20c['error'](0x1f4,_0x2abafb[_0x3d22d7('0x1')]));});});},exports[_0x3ea6d0('0x6')]=function(_0xa9ce88){const _0x12df27=this;return new Promise(function(_0x9d9384,_0x49030f){const _0x58ee2e=a409_0x43a7;return db[_0x58ee2e('0x10')][_0x58ee2e('0x17')]({'where':_0xa9ce88[_0x58ee2e('0x8')]?_0xa9ce88[_0x58ee2e('0x8')]['where']||null:null})['then'](function(_0x385e78){const _0x2a6a5e=_0x58ee2e;if(_0x385e78)return _0x385e78[_0x2a6a5e('0xd')](_0xa9ce88[_0x2a6a5e('0x14')]['ids'],{'through':_[_0x2a6a5e('0x3')](_0xa9ce88[_0x2a6a5e('0x14')],['ids','id'])});})['then'](function([_0x579005]){const _0x26e0b0=_0x58ee2e;logger['info'](_0x26e0b0('0xe'),_0xa9ce88),logger[_0x26e0b0('0x5')](_0x26e0b0('0xe'),_0xa9ce88,JSON[_0x26e0b0('0x4')](_0x579005)),_0x9d9384(_0x579005);})[_0x58ee2e('0x0')](function(_0x1b6a1e){const _0x57dcdd=_0x58ee2e;logger[_0x57dcdd('0x11')](_0x57dcdd('0xe'),_0x1b6a1e['message'],_0xa9ce88),_0x49030f(_0x12df27['error'](0x1f4,_0x1b6a1e[_0x57dcdd('0x1')]));});});}; \ No newline at end of file +const a409_0x34a1=['ids','AddTags','attributes','stringify','lodash','update','catch','then','findOne','MailInteraction','UpdateMailInteraction','options','where','../../mysqldb','addTags','message','../../config/logger','./mailInteraction.socket','info','rpc','AddTagsToMailInteraction','body','register','limit','debug','error'];(function(_0x218c6c,_0x34a1ce){const _0x4a261a=function(_0x3a3152){while(--_0x3a3152){_0x218c6c['push'](_0x218c6c['shift']());}};_0x4a261a(++_0x34a1ce);}(a409_0x34a1,0x1e7));const a409_0x4a26=function(_0x218c6c,_0x34a1ce){_0x218c6c=_0x218c6c-0x0;let _0x4a261a=a409_0x34a1[_0x218c6c];return _0x4a261a;};const _0x1137c4=a409_0x4a26;'use strict';const _=require(_0x1137c4('0xb')),db=require(_0x1137c4('0x14'))['db'],logger=require(_0x1137c4('0x17'))(_0x1137c4('0x0')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x1137c4('0x18'))[_0x1137c4('0x3')](socket),exports[_0x1137c4('0x11')]=function(_0x3a3152){const _0xc4aa47=this;return new Promise(function(_0x1d85c4,_0xd1e188){const _0x2d0781=a409_0x4a26;return db['MailInteraction'][_0x2d0781('0xc')](_0x3a3152[_0x2d0781('0x2')],{'raw':_0x3a3152['options']?_0x3a3152[_0x2d0781('0x12')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x3a3152[_0x2d0781('0x12')]?_0x3a3152['options'][_0x2d0781('0x13')]||null:null,'attributes':_0x3a3152[_0x2d0781('0x12')]?_0x3a3152['options'][_0x2d0781('0x9')]||null:null,'limit':_0x3a3152[_0x2d0781('0x12')]?_0x3a3152[_0x2d0781('0x12')][_0x2d0781('0x4')]||null:null})[_0x2d0781('0xe')](function(_0x269319){const _0x3b9410=_0x2d0781;logger[_0x3b9410('0x19')](_0x3b9410('0x11'),_0x3a3152),logger['debug'](_0x3b9410('0x11'),_0x3a3152,JSON[_0x3b9410('0xa')](_0x269319)),_0x1d85c4(_0x269319);})[_0x2d0781('0xd')](function(_0xd3a8d1){const _0x4c9afd=_0x2d0781;logger[_0x4c9afd('0x6')](_0x4c9afd('0x11'),_0xd3a8d1['message'],_0x3a3152),_0xd1e188(_0xc4aa47['error'](0x1f4,_0xd3a8d1[_0x4c9afd('0x16')]));});});},exports[_0x1137c4('0x1')]=function(_0x4ed957){const _0x3a0eb4=this;return new Promise(function(_0x1d5dc8,_0xd16b6b){const _0x54b6d8=a409_0x4a26;return db[_0x54b6d8('0x10')][_0x54b6d8('0xf')]({'where':_0x4ed957[_0x54b6d8('0x12')]?_0x4ed957[_0x54b6d8('0x12')][_0x54b6d8('0x13')]||null:null})[_0x54b6d8('0xe')](function(_0x1aef7a){const _0x3cd77b=_0x54b6d8;if(_0x1aef7a)return _0x1aef7a[_0x3cd77b('0x15')](_0x4ed957[_0x3cd77b('0x2')]['ids'],{'through':_['omit'](_0x4ed957['body'],[_0x3cd77b('0x7'),'id'])});})[_0x54b6d8('0xe')](function([_0xad7e8d]){const _0x3eef43=_0x54b6d8;logger[_0x3eef43('0x19')](_0x3eef43('0x8'),_0x4ed957),logger[_0x3eef43('0x5')](_0x3eef43('0x8'),_0x4ed957,JSON['stringify'](_0xad7e8d)),_0x1d5dc8(_0xad7e8d);})['catch'](function(_0xf312b2){const _0x26103b=_0x54b6d8;logger[_0x26103b('0x6')](_0x26103b('0x8'),_0xf312b2[_0x26103b('0x16')],_0x4ed957),_0xd16b6b(_0x3a0eb4[_0x26103b('0x6')](0x1f4,_0xf312b2[_0x26103b('0x16')]));});});}; \ No newline at end of file diff --git a/server/api/mailInteraction/mailInteraction.socket.js b/server/api/mailInteraction/mailInteraction.socket.js index c38f849..16967aa 100644 --- a/server/api/mailInteraction/mailInteraction.socket.js +++ b/server/api/mailInteraction/mailInteraction.socket.js @@ -1 +1 @@ -const a410_0x1506=['update','remove','register','./mailInteraction.events','length','emit'];(function(_0x48e907,_0x150671){const _0x5b3d65=function(_0x3f6b85){while(--_0x3f6b85){_0x48e907['push'](_0x48e907['shift']());}};_0x5b3d65(++_0x150671);}(a410_0x1506,0x12c));const a410_0x5b3d=function(_0x48e907,_0x150671){_0x48e907=_0x48e907-0x0;let _0x5b3d65=a410_0x1506[_0x48e907];return _0x5b3d65;};const _0x404a8b=a410_0x5b3d;'use strict';const MailInteractionEvents=require(_0x404a8b('0x3')),events=['save',_0x404a8b('0x1'),_0x404a8b('0x0')];function createListener(_0x3f6b85,_0x4d6a47){return function(_0x4e243b){const _0x24d8ac=a410_0x5b3d;_0x4d6a47[_0x24d8ac('0x5')](_0x3f6b85,_0x4e243b);};}exports[_0x404a8b('0x2')]=function(_0x4f0b33){const _0x188e04=_0x404a8b;for(let _0x3541ed=0x0,_0x3a8dce=events[_0x188e04('0x4')];_0x3541ed<_0x3a8dce;_0x3541ed++){const _0x890b41=events[_0x3541ed],_0x591fb2=createListener('mailInteraction:'+_0x890b41,_0x4f0b33);MailInteractionEvents['on'](_0x890b41,_0x591fb2);}}; \ No newline at end of file +const a410_0x52d9=['emit','register','length','save','update'];(function(_0x576679,_0x52d916){const _0x482d75=function(_0x5403a7){while(--_0x5403a7){_0x576679['push'](_0x576679['shift']());}};_0x482d75(++_0x52d916);}(a410_0x52d9,0x64));const a410_0x482d=function(_0x576679,_0x52d916){_0x576679=_0x576679-0x0;let _0x482d75=a410_0x52d9[_0x576679];return _0x482d75;};const _0x124b68=a410_0x482d;'use strict';const MailInteractionEvents=require('./mailInteraction.events'),events=[_0x124b68('0x3'),'remove',_0x124b68('0x4')];function createListener(_0x5403a7,_0x22407c){return function(_0x514043){const _0x1cdeb5=a410_0x482d;_0x22407c[_0x1cdeb5('0x0')](_0x5403a7,_0x514043);};}exports[_0x124b68('0x1')]=function(_0x6b7ce4){const _0x45827e=_0x124b68;for(let _0x3a9691=0x0,_0x228af7=events[_0x45827e('0x2')];_0x3a9691<_0x228af7;_0x3a9691++){const _0x42e907=events[_0x3a9691],_0x392b84=createListener('mailInteraction:'+_0x42e907,_0x6b7ce4);MailInteractionEvents['on'](_0x42e907,_0x392b84);}}; \ No newline at end of file diff --git a/server/api/mailMessage/index.js b/server/api/mailMessage/index.js index cc476ce..841c14d 100644 --- a/server/api/mailMessage/index.js +++ b/server/api/mailMessage/index.js @@ -1 +1 @@ -const a411_0xedc5=['update','index','destroy','create','show','/:id','mail','express','delete','get','isAuthenticated','/:id/accept','reject','post','mailmessage:create','/describe','Router','exports','describe','put','../../components/auth/service'];(function(_0x5c19c6,_0xedc5ff){const _0x57f2f9=function(_0x9d611e){while(--_0x9d611e){_0x5c19c6['push'](_0x5c19c6['shift']());}};_0x57f2f9(++_0xedc5ff);}(a411_0xedc5,0xa4));const a411_0x57f2=function(_0x5c19c6,_0xedc5ff){_0x5c19c6=_0x5c19c6-0x0;let _0x57f2f9=a411_0xedc5[_0x5c19c6];return _0x57f2f9;};const _0x19fac7=a411_0x57f2;'use strict';const express=require(_0x19fac7('0xb')),router=express[_0x19fac7('0x14')](),auth=require(_0x19fac7('0x3')),interaction=require('../../components/interaction/service'),controller=require('./mailMessage.controller');router[_0x19fac7('0xd')]('/',auth[_0x19fac7('0xe')](),controller[_0x19fac7('0x5')]),router['get'](_0x19fac7('0x13'),auth[_0x19fac7('0xe')](),controller[_0x19fac7('0x1')]),router[_0x19fac7('0xd')](_0x19fac7('0x9'),auth['isAuthenticated'](),controller[_0x19fac7('0x8')]),router[_0x19fac7('0xd')]('/:id/download',auth[_0x19fac7('0xe')](),controller['download']),router[_0x19fac7('0x11')]('/',auth['isAuthenticated'](),interaction['tracked'](_0x19fac7('0xa'),_0x19fac7('0x12')),controller[_0x19fac7('0x7')]),router[_0x19fac7('0x2')]('/:id',auth[_0x19fac7('0xe')](),controller[_0x19fac7('0x4')]),router[_0x19fac7('0x2')](_0x19fac7('0xf'),auth[_0x19fac7('0xe')](),controller['accept']),router['put']('/:id/reject',auth[_0x19fac7('0xe')](),controller[_0x19fac7('0x10')]),router[_0x19fac7('0xc')](_0x19fac7('0x9'),auth[_0x19fac7('0xe')](),controller[_0x19fac7('0x6')]),module[_0x19fac7('0x0')]=router; \ No newline at end of file +const a411_0x242b=['mail','delete','express','show','describe','create','../../components/interaction/service','put','Router','/:id','/:id/reject','./mailMessage.controller','get','/describe','reject','mailmessage:create','accept','tracked','post','/:id/accept','destroy','isAuthenticated'];(function(_0x2b207f,_0x242bac){const _0x267be7=function(_0x648e44){while(--_0x648e44){_0x2b207f['push'](_0x2b207f['shift']());}};_0x267be7(++_0x242bac);}(a411_0x242b,0x13c));const a411_0x267b=function(_0x2b207f,_0x242bac){_0x2b207f=_0x2b207f-0x0;let _0x267be7=a411_0x242b[_0x2b207f];return _0x267be7;};const _0x277732=a411_0x267b;'use strict';const express=require(_0x277732('0x10')),router=express[_0x277732('0x0')](),auth=require('../../components/auth/service'),interaction=require(_0x277732('0x14')),controller=require(_0x277732('0x3'));router[_0x277732('0x4')]('/',auth[_0x277732('0xd')](),controller['index']),router['get'](_0x277732('0x5'),auth[_0x277732('0xd')](),controller[_0x277732('0x12')]),router[_0x277732('0x4')](_0x277732('0x1'),auth[_0x277732('0xd')](),controller[_0x277732('0x11')]),router[_0x277732('0x4')]('/:id/download',auth['isAuthenticated'](),controller['download']),router[_0x277732('0xa')]('/',auth[_0x277732('0xd')](),interaction[_0x277732('0x9')](_0x277732('0xe'),_0x277732('0x7')),controller[_0x277732('0x13')]),router['put'](_0x277732('0x1'),auth[_0x277732('0xd')](),controller['update']),router['put'](_0x277732('0xb'),auth[_0x277732('0xd')](),controller[_0x277732('0x8')]),router[_0x277732('0x15')](_0x277732('0x2'),auth['isAuthenticated'](),controller[_0x277732('0x6')]),router[_0x277732('0xf')](_0x277732('0x1'),auth[_0x277732('0xd')](),controller[_0x277732('0xc')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/mailMessage/mailMessage.attributes.js b/server/api/mailMessage/mailMessage.attributes.js index 0de5bd4..3ceffa6 100644 --- a/server/api/mailMessage/mailMessage.attributes.js +++ b/server/api/mailMessage/mailMessage.attributes.js @@ -1 +1 @@ -const a412_0x2469=['medium','TEXT','exports','out','STRING','sequelize','INTEGER','BOOLEAN','DATE','long'];(function(_0x593b08,_0x24698f){const _0x49ae4a=function(_0x18f6c6){while(--_0x18f6c6){_0x593b08['push'](_0x593b08['shift']());}};_0x49ae4a(++_0x24698f);}(a412_0x2469,0x1ce));const a412_0x49ae=function(_0x593b08,_0x24698f){_0x593b08=_0x593b08-0x0;let _0x49ae4a=a412_0x2469[_0x593b08];return _0x49ae4a;};const _0x2c3b3e=a412_0x49ae;'use strict';const Sequelize=require(_0x2c3b3e('0x3'));module[_0x2c3b3e('0x0')]={'body':{'type':Sequelize[_0x2c3b3e('0x9')](_0x2c3b3e('0x7')),'allowNull':![]},'plainBody':{'type':Sequelize[_0x2c3b3e('0x9')](_0x2c3b3e('0x8'))},'read':{'type':Sequelize[_0x2c3b3e('0x5')],'defaultValue':![]},'direction':{'type':Sequelize['ENUM']('in','out'),'defaultValue':_0x2c3b3e('0x1'),'allowNull':![]},'messageId':{'type':Sequelize[_0x2c3b3e('0x2')](0x1fe)},'from':{'type':Sequelize[_0x2c3b3e('0x2')]},'to':{'type':Sequelize[_0x2c3b3e('0x9')](_0x2c3b3e('0x7'))},'cc':{'type':Sequelize[_0x2c3b3e('0x9')](_0x2c3b3e('0x7'))},'bcc':{'type':Sequelize[_0x2c3b3e('0x9')]('long')},'subject':{'type':Sequelize['TEXT']},'sentAt':{'type':Sequelize[_0x2c3b3e('0x6')]},'attach':{'type':Sequelize[_0x2c3b3e('0x4')],'defaultValue':0x0},'secret':{'type':Sequelize[_0x2c3b3e('0x5')],'defaultValue':![]},'readAt':{'type':Sequelize[_0x2c3b3e('0x6')]},'originTo':{'type':Sequelize[_0x2c3b3e('0x9')](_0x2c3b3e('0x7'))},'originCc':{'type':Sequelize[_0x2c3b3e('0x9')](_0x2c3b3e('0x7'))}}; \ No newline at end of file +const a412_0x342a=['DATE','BOOLEAN','out','long','STRING','INTEGER','exports','TEXT','ENUM','sequelize','medium'];(function(_0x17d892,_0x342a91){const _0x2c8ae8=function(_0x6d3c93){while(--_0x6d3c93){_0x17d892['push'](_0x17d892['shift']());}};_0x2c8ae8(++_0x342a91);}(a412_0x342a,0x122));const a412_0x2c8a=function(_0x17d892,_0x342a91){_0x17d892=_0x17d892-0x0;let _0x2c8ae8=a412_0x342a[_0x17d892];return _0x2c8ae8;};const _0x357906=a412_0x2c8a;'use strict';const Sequelize=require(_0x357906('0x5'));module[_0x357906('0x2')]={'body':{'type':Sequelize['TEXT'](_0x357906('0xa')),'allowNull':![]},'plainBody':{'type':Sequelize[_0x357906('0x3')](_0x357906('0x6'))},'read':{'type':Sequelize[_0x357906('0x8')],'defaultValue':![]},'direction':{'type':Sequelize[_0x357906('0x4')]('in',_0x357906('0x9')),'defaultValue':_0x357906('0x9'),'allowNull':![]},'messageId':{'type':Sequelize['STRING'](0x1fe)},'from':{'type':Sequelize[_0x357906('0x0')]},'to':{'type':Sequelize[_0x357906('0x3')](_0x357906('0xa'))},'cc':{'type':Sequelize[_0x357906('0x3')](_0x357906('0xa'))},'bcc':{'type':Sequelize[_0x357906('0x3')](_0x357906('0xa'))},'subject':{'type':Sequelize['TEXT']},'sentAt':{'type':Sequelize[_0x357906('0x7')]},'attach':{'type':Sequelize[_0x357906('0x1')],'defaultValue':0x0},'secret':{'type':Sequelize[_0x357906('0x8')],'defaultValue':![]},'readAt':{'type':Sequelize[_0x357906('0x7')]},'originTo':{'type':Sequelize[_0x357906('0x3')](_0x357906('0xa'))},'originCc':{'type':Sequelize[_0x357906('0x3')](_0x357906('0xa'))}}; \ No newline at end of file diff --git a/server/api/mailMessage/mailMessage.controller.js b/server/api/mailMessage/mailMessage.controller.js index c92a3ad..d017134 100644 --- a/server/api/mailMessage/mailMessage.controller.js +++ b/server/api/mailMessage/mailMessage.controller.js @@ -1 +1 @@ -const a413_0x1cde=['code','interface','limit','model','basename','index','get','bcc','register','[MAILMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','secret','List','CmContact','read','acceptmessage','stack','path','unix','key','findOne','undefined','CmList','accept','../../config/logger','result','send','reject','body','request','interaction','format','push','end','where','map','fields','user','authentication','Bcc','EventManager','YYYY-MM-DD\x20HH:mm:ss','readAt','Content-Range','request\x20sent','sendStatus','message','MailMessage,\x20%s,\x20%s,\x20%s','mail','port','SendMail','acceptMessage','lodash','merge','existsSync','offset','pass','name','RejectMessage','sendMail','SIP/%s','defaults','DESC','set','attributes','api','ListId','headers','mail-interactions','server/files/attachments','fieldName','status','tmp','filter','host','MailInteraction','create','read1stAt','join','role','nolimit','pick','include','length','AcceptMessage','isNil','./mailMessage.socket','null','server','keys','event','List\x20not\x20found','download','../../rediscache','updatedAt','log','options','direction','Contacts','attachments','subject','VIRTUAL','../../mysqldb','service','then','rejectmessage','stringify','MailServerOut','MailAccount','moment','info','update','MailInteractionId','MailMessage','describe','filters','sort','agent','writeFileSync','Attachments','params','unlinkSync','Smtp','intersection','query','auth','message-%s.eml','includeAll','out','rejectMessage','root','catch','http','MailAccountId','UserId','from','readFileSync','client','jayson/promise','count','createdAt','files','err','[MAILMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','secure','type','error','channel','destroy','MailMessage,\x20%s,\x20%s','rawAttributes','json','messageId','../../components/parsers/qs','debug'];(function(_0x221556,_0x1cde09){const _0x18c9d4=function(_0x35f7b2){while(--_0x35f7b2){_0x221556['push'](_0x221556['shift']());}};_0x18c9d4(++_0x1cde09);}(a413_0x1cde,0x107));const a413_0x18c9=function(_0x221556,_0x1cde09){_0x221556=_0x221556-0x0;let _0x18c9d4=a413_0x1cde[_0x221556];return _0x18c9d4;};const _0x23de70=a413_0x18c9;'use strict';const emlformat=require('eml-format'),moment=require(_0x23de70('0x99')),util=require('util'),path=require(_0x23de70('0x3d')),fs=require('fs'),_=require(_0x23de70('0x60')),{getSocket}=require(_0x23de70('0x89')),socket=getSocket(),qs=require(_0x23de70('0x2b')),logger=require(_0x23de70('0x44'))(_0x23de70('0x6d')),config=require('../../config/environment'),interaction_log=require('../../config/logger')(_0x23de70('0x70')),db=require(_0x23de70('0x92'))['db'],{Op}=require('sequelize');require(_0x23de70('0x82'))[_0x23de70('0x35')](socket);const jayson=require(_0x23de70('0x1c')),client=jayson[_0x23de70('0x1b')][_0x23de70('0x16')]({'port':0x232c}),client9003=jayson[_0x23de70('0x1b')]['http']({'port':0x232b}),client9002=jayson['client']['http']({'port':0x232a});function respondWithRpcPromise(_0x35f7b2,_0xf1a469,_0x46ab31,_0x661142){return new Promise(function(_0x5b28f1,_0x45e98a){const _0x12c884=a413_0x18c9,_0x4bde0b=_0x661142||client;return _0x4bde0b[_0x12c884('0x49')](_0x35f7b2,_0x46ab31)[_0x12c884('0x94')](function(_0x55cfe1){const _0x331063=_0x12c884;logger[_0x331063('0x0')](_0x331063('0x27'),_0xf1a469,'request\x20sent'),logger[_0x331063('0x2c')](_0x331063('0x5b'),_0xf1a469,_0x331063('0x58'),JSON[_0x331063('0x96')](_0x55cfe1));if(_0x55cfe1[_0x331063('0x24')]){if(_0x55cfe1['error'][_0x331063('0x2d')]===0x1f4)return logger[_0x331063('0x24')](_0x331063('0x27'),_0xf1a469,_0x55cfe1[_0x331063('0x24')][_0x331063('0x5a')]),_0x45e98a(_0x55cfe1[_0x331063('0x24')][_0x331063('0x5a')]);return logger[_0x331063('0x24')](_0x331063('0x27'),_0xf1a469,_0x55cfe1[_0x331063('0x24')][_0x331063('0x5a')]),_0x5b28f1(_0x55cfe1[_0x331063('0x24')][_0x331063('0x5a')]);}else logger['info'](_0x331063('0x27'),_0xf1a469,_0x331063('0x58')),_0x5b28f1(_0x55cfe1[_0x331063('0x45')][_0x331063('0x5a')]);})[_0x12c884('0x15')](function(_0x2232dd){const _0x36f73d=_0x12c884;logger[_0x36f73d('0x24')]('MailMessage,\x20%s,\x20%s',_0xf1a469,_0x2232dd),_0x45e98a(_0x2232dd);});});}function respondWithResult(_0x216fcc,_0x155248){return _0x155248=_0x155248||0xc8,function(_0xb079ed){const _0x44ab9a=a413_0x18c9;if(_0xb079ed)return _0x216fcc[_0x44ab9a('0x73')](_0x155248)[_0x44ab9a('0x29')](_0xb079ed);};}function respondWithFilteredResult(_0x1ddad6,_0x57db88){return function(_0x4f62c2){const _0x53e3a6=a413_0x18c9;if(_0x4f62c2){const _0x409f7f=_0x4f62c2[_0x53e3a6('0x1d')],_0x261aa4=_0x57db88[_0x53e3a6('0x63')];let _0x2eb3c3=_0x57db88[_0x53e3a6('0x63')]+_0x57db88[_0x53e3a6('0x2f')],_0x858dca;return _0x2eb3c3>=_0x409f7f?(_0x2eb3c3=_0x409f7f,_0x858dca=0xc8):_0x858dca=0xce,_0x1ddad6[_0x53e3a6('0x73')](_0x858dca),_0x1ddad6[_0x53e3a6('0x6b')](_0x53e3a6('0x57'),_0x261aa4+'-'+_0x2eb3c3+'/'+_0x409f7f)[_0x53e3a6('0x29')](_0x4f62c2);}return null;};}function saveUpdates(_0x3e7599){return function(_0x749040){const _0x1e7a53=a413_0x18c9;if(_0x749040)return _0x749040['update'](_0x3e7599)[_0x1e7a53('0x94')](function(_0x360c35){return _0x360c35;});return null;};}function removeEntity(_0x306e19){return function(_0x40a396){const _0x1bd2c9=a413_0x18c9;if(_0x40a396)return _0x40a396[_0x1bd2c9('0x26')]()[_0x1bd2c9('0x94')](function(){const _0x1f3111=_0x1bd2c9;_0x306e19[_0x1f3111('0x73')](0xcc)[_0x1f3111('0x4d')]();});};}function handleEntityNotFound(_0x2e5527){return function(_0x39556b){const _0x2de2fa=a413_0x18c9;return!_0x39556b&&_0x2e5527[_0x2de2fa('0x59')](0x194),_0x39556b;};}function handleError(_0x1a1fac,_0x53452a){return _0x53452a=_0x53452a||0x1f4,function(_0x126876){const _0x26dfa0=a413_0x18c9;logger[_0x26dfa0('0x24')](_0x126876[_0x26dfa0('0x3c')]),_0x126876[_0x26dfa0('0x65')]&&delete _0x126876[_0x26dfa0('0x65')],_0x1a1fac['status'](_0x53452a)[_0x26dfa0('0x46')](_0x126876);};}exports[_0x23de70('0x32')]=function(_0x51f8e8,_0x9b0cfd){const _0x2206f3=_0x23de70;let _0x5019dc={};const _0x249014={},_0x47466a={'count':0x0,'rows':[]},_0x3283b0=_['map'](db[_0x2206f3('0x3')][_0x2206f3('0x28')],function(_0x33756e){const _0x5e6970=_0x2206f3;return{'name':_0x33756e[_0x5e6970('0x72')],'type':_0x33756e[_0x5e6970('0x23')][_0x5e6970('0x3f')]};});_0x249014[_0x2206f3('0x30')]=_[_0x2206f3('0x4f')](_0x3283b0,_0x2206f3('0x65')),_0x249014[_0x2206f3('0xe')]=_[_0x2206f3('0x85')](_0x51f8e8[_0x2206f3('0xe')]),_0x249014[_0x2206f3('0x5')]=_['intersection'](_0x249014['model'],_0x249014['query']),_0x5019dc['attributes']=_[_0x2206f3('0xd')](_0x249014[_0x2206f3('0x30')],qs[_0x2206f3('0x50')](_0x51f8e8['query']['fields'])),_0x5019dc[_0x2206f3('0x6c')]=_0x5019dc[_0x2206f3('0x6c')][_0x2206f3('0x7f')]?_0x5019dc['attributes']:_0x249014['model'];typeof _0x51f8e8[_0x2206f3('0xe')][_0x2206f3('0x7c')]===_0x2206f3('0x41')&&(_0x5019dc['limit']=qs['limit'](_0x51f8e8[_0x2206f3('0xe')][_0x2206f3('0x2f')]),_0x5019dc[_0x2206f3('0x63')]=qs['offset'](_0x51f8e8[_0x2206f3('0xe')][_0x2206f3('0x63')]));_0x5019dc['order']=qs[_0x2206f3('0x6')](_0x51f8e8[_0x2206f3('0xe')][_0x2206f3('0x6')]),_0x5019dc[_0x2206f3('0x4e')]=qs[_0x2206f3('0x5')](_[_0x2206f3('0x7d')](_0x51f8e8[_0x2206f3('0xe')],_0x249014[_0x2206f3('0x5')]),_0x3283b0);_0x51f8e8[_0x2206f3('0xe')][_0x2206f3('0x75')]&&(_0x5019dc[_0x2206f3('0x4e')]=_[_0x2206f3('0x61')](_0x5019dc[_0x2206f3('0x4e')],{[Op['or']]:_[_0x2206f3('0x4f')](_0x3283b0,function(_0x4cdb0c){const _0x4b4109=_0x2206f3;if(_0x4cdb0c[_0x4b4109('0x23')]!==_0x4b4109('0x91')){const _0x4a0b90={};return _0x4a0b90[_0x4cdb0c[_0x4b4109('0x65')]]={[Op['like']]:'%'+_0x51f8e8[_0x4b4109('0xe')][_0x4b4109('0x75')]+'%'},_0x4a0b90;}})}));_0x5019dc=_[_0x2206f3('0x61')]({},_0x5019dc,_0x51f8e8[_0x2206f3('0x8c')]);const _0x366b8c={'where':_0x5019dc['where']};return db[_0x2206f3('0x3')][_0x2206f3('0x1d')](_0x366b8c)[_0x2206f3('0x94')](function(_0x145b16){const _0x211e35=_0x2206f3;return _0x47466a['count']=_0x145b16,_0x51f8e8[_0x211e35('0xe')][_0x211e35('0x11')]&&(_0x5019dc['include']=[{'all':!![]}]),db[_0x211e35('0x3')]['findAll'](_0x5019dc);})['then'](function(_0x313f38){return _0x47466a['rows']=_0x313f38,_0x47466a;})['then'](respondWithFilteredResult(_0x9b0cfd,_0x5019dc))[_0x2206f3('0x15')](handleError(_0x9b0cfd,null));},exports['show']=function(_0x39393a,_0xac8086){const _0x553292=_0x23de70;let _0x56ef80={'raw':!![],'where':{'id':_0x39393a[_0x553292('0xa')]['id']}};const _0x4fdf7f={};return _0x4fdf7f[_0x553292('0x30')]=_[_0x553292('0x85')](db['MailMessage']['rawAttributes']),_0x4fdf7f[_0x553292('0xe')]=_[_0x553292('0x85')](_0x39393a[_0x553292('0xe')]),_0x4fdf7f['filters']=_[_0x553292('0xd')](_0x4fdf7f[_0x553292('0x30')],_0x4fdf7f[_0x553292('0xe')]),_0x56ef80[_0x553292('0x6c')]=_['intersection'](_0x4fdf7f['model'],qs[_0x553292('0x50')](_0x39393a[_0x553292('0xe')][_0x553292('0x50')])),_0x56ef80[_0x553292('0x6c')]=_0x56ef80[_0x553292('0x6c')][_0x553292('0x7f')]?_0x56ef80[_0x553292('0x6c')]:_0x4fdf7f[_0x553292('0x30')],_0x39393a[_0x553292('0xe')][_0x553292('0x11')]&&(_0x56ef80[_0x553292('0x7e')]=[{'all':!![]}]),_0x56ef80=_['merge']({},_0x56ef80,_0x39393a[_0x553292('0x8c')]),db['MailMessage'][_0x553292('0x40')](_0x56ef80)[_0x553292('0x94')](handleEntityNotFound(_0xac8086,null))[_0x553292('0x94')](respondWithResult(_0xac8086,null))[_0x553292('0x15')](handleError(_0xac8086,null));},exports[_0x23de70('0x1')]=function(_0x4173bb,_0x4b6fa1){const _0x263d1d=_0x23de70;return _0x4173bb[_0x263d1d('0x48')]['id']&&delete _0x4173bb[_0x263d1d('0x48')]['id'],db['MailMessage']['findOne']({'where':{'id':_0x4173bb[_0x263d1d('0xa')]['id']}})['then'](handleEntityNotFound(_0x4b6fa1,null))[_0x263d1d('0x94')](saveUpdates(_0x4173bb['body'],null))[_0x263d1d('0x94')](respondWithResult(_0x4b6fa1,null))[_0x263d1d('0x15')](handleError(_0x4b6fa1,null));},exports['destroy']=function(_0x40c457,_0x5dd3cb){const _0x2635ff=_0x23de70;return db[_0x2635ff('0x3')][_0x2635ff('0x40')]({'where':{'id':_0x40c457[_0x2635ff('0xa')]['id']}})[_0x2635ff('0x94')](handleEntityNotFound(_0x5dd3cb,null))['then'](removeEntity(_0x5dd3cb,null))[_0x2635ff('0x15')](handleError(_0x5dd3cb,null));},exports[_0x23de70('0x4')]=function(_0x4ca4a7,_0x34907a){const _0x2e8259=_0x23de70;return db[_0x2e8259('0x3')]['describe']()[_0x2e8259('0x94')](respondWithResult(_0x34907a,null))[_0x2e8259('0x15')](handleError(_0x34907a,null));},exports[_0x23de70('0x78')]=function(_0x32bf85,_0x13cf86){const _0x59878c=_0x23de70;return db[_0x59878c('0x3')][_0x59878c('0x78')](_0x32bf85[_0x59878c('0x48')])[_0x59878c('0x94')](function(_0x9d9375){const _0x1c2402=_0x59878c;if(_0x9d9375){if(_0x9d9375[_0x1c2402('0x8d')]===_0x1c2402('0x12')&&!_0x9d9375[_0x1c2402('0x37')]){let _0x2faaca,_0x47e619,_0x3d4f80;return _0x32bf85[_0x1c2402('0x48')]['to']&&(_0x47e619=_0x32bf85[_0x1c2402('0x48')]['to']['split'](',')[0x0]),db[_0x1c2402('0x98')][_0x1c2402('0x40')]({'where':{'id':_0x9d9375[_0x1c2402('0x17')]},'include':[{'model':db[_0x1c2402('0x42')],'as':_0x1c2402('0x38'),'include':[{'model':db['CmContact'],'as':_0x1c2402('0x8e'),'where':{'email':_0x47e619},'limit':0x1,'order':[[_0x1c2402('0x8a'),_0x1c2402('0x6a')]]}]},{'model':db[_0x1c2402('0x97')],'as':_0x1c2402('0xc'),'raw':!![]}]})[_0x1c2402('0x94')](function(_0xbbb36d){const _0x52263b=_0x1c2402;_0x2faaca=_0xbbb36d;if(_0x2faaca&&_0x2faaca[_0x52263b('0xc')]){const _0xefa668={'tls':{'rejectUnauthorized':![]}};_['isNil'](_0x2faaca[_0x52263b('0xc')][_0x52263b('0x93')])?(_0xefa668[_0x52263b('0x76')]=_0x2faaca[_0x52263b('0xc')][_0x52263b('0x76')],_0xefa668['port']=_0x2faaca[_0x52263b('0xc')][_0x52263b('0x5d')],_0xefa668[_0x52263b('0x22')]=_0x2faaca[_0x52263b('0xc')][_0x52263b('0x22')],_0x2faaca['Smtp'][_0x52263b('0x52')]&&(_0xefa668[_0x52263b('0xf')]={'user':_0x2faaca[_0x52263b('0xc')][_0x52263b('0x51')],'pass':_0x2faaca[_0x52263b('0xc')][_0x52263b('0x64')]})):(_0xefa668[_0x52263b('0x93')]=_0x2faaca[_0x52263b('0xc')][_0x52263b('0x93')],_0xefa668['auth']={'user':_0x2faaca[_0x52263b('0xc')][_0x52263b('0x51')],'pass':_0x2faaca[_0x52263b('0xc')][_0x52263b('0x64')]},_0xefa668[_0x52263b('0x22')]=_0x2faaca[_0x52263b('0xc')][_0x52263b('0x22')]);if(_0x32bf85[_0x52263b('0x48')][_0x52263b('0x8f')]&&_0x32bf85['body']['attachments'][_0x52263b('0x7f')])for(let _0x873901=0x0;_0x873901<_0x32bf85['body']['attachments'][_0x52263b('0x7f')];_0x873901+=0x1){_0x32bf85[_0x52263b('0x48')][_0x52263b('0x8f')][_0x873901]={'filename':_0x32bf85[_0x52263b('0x48')]['attachments'][_0x873901]['name'],'path':path[_0x52263b('0x7a')](config[_0x52263b('0x14')],_0x52263b('0x71'),_0x32bf85['body'][_0x52263b('0x8f')][_0x873901][_0x52263b('0x31')])};}_0x3d4f80={'account':_0xefa668,'message':_0x32bf85['body']};return;}})[_0x1c2402('0x94')](function(){const _0x25306d=_0x1c2402;if(_0x2faaca['List'])return _0x2faaca[_0x25306d('0x38')][_0x25306d('0x8e')][_0x25306d('0x7f')]?_0x2faaca[_0x25306d('0x38')]['Contacts'][0x0]:db[_0x25306d('0x39')][_0x25306d('0x78')](_[_0x25306d('0x69')](_0x32bf85['body'],{'firstName':_0x32bf85[_0x25306d('0x48')]['to'],'email':_0x32bf85[_0x25306d('0x48')]['to'],'phone':_0x32bf85[_0x25306d('0x48')]['to'],'ListId':_0x2faaca[_0x25306d('0x6e')]}));else throw new Error(_0x25306d('0x87'));})['then'](function(){const _0x444035=_0x1c2402;if(_0x3d4f80)return respondWithRpcPromise(_0x444035('0x5e'),_0x444035('0x67'),_0x3d4f80,client9003)[_0x444035('0x94')](function(_0x2a741b){const _0x412196=_0x444035;return _0x9d9375[_0x412196('0x1')]({'read':!![],'messageId':_0x2a741b[_0x412196('0x2a')],'sentAt':moment()[_0x412196('0x4b')](_0x412196('0x55'))});})[_0x444035('0x15')](function(_0x26b278){const _0x4d011b=_0x444035;return logger[_0x4d011b('0x24')]('%s',JSON[_0x4d011b('0x96')](_0x26b278)),_0x9d9375;});return _0x9d9375;});}return _0x9d9375;}})[_0x59878c('0x94')](respondWithResult(_0x13cf86,0xc9))[_0x59878c('0x15')](handleError(_0x13cf86,null));},exports[_0x23de70('0x43')]=function(_0x334120,_0x4f9d56){const _0x55a404=_0x23de70,_0x5fc020={'channel':'mail'};return _0x334120['body']['id']&&delete _0x334120['body']['id'],_0x334120[_0x55a404('0x48')][_0x55a404('0x3a')]=!![],_0x334120[_0x55a404('0x48')][_0x55a404('0x56')]=moment()[_0x55a404('0x4b')](_0x55a404('0x55')),_0x334120['body'][_0x55a404('0x18')]=_0x334120[_0x55a404('0x48')]['UserId']||_0x334120[_0x55a404('0x51')]['id'],db[_0x55a404('0x3')][_0x55a404('0x40')]({'where':{'id':_0x334120[_0x55a404('0xa')]['id'],'UserId':null},'include':[{'model':db[_0x55a404('0x39')],'as':'Contact'}]})[_0x55a404('0x94')](handleEntityNotFound(_0x4f9d56,null))[_0x55a404('0x94')](saveUpdates(_0x334120[_0x55a404('0x48')],null))[_0x55a404('0x94')](function(_0x41df6b){const _0x38ffb7=_0x55a404;if(_0x41df6b)return _0x5fc020['message']=_0x41df6b['get']({'plain':!![]}),db[_0x38ffb7('0x77')][_0x38ffb7('0x40')]({'where':{'id':_0x41df6b[_0x38ffb7('0x2')]}});return null;})['then'](handleEntityNotFound(_0x4f9d56,null))[_0x55a404('0x94')](function(_0x20e5e5){const _0x144bcb=_0x55a404;if(_0x20e5e5)return _0x20e5e5['update']({'UserId':_0x334120[_0x144bcb('0x48')][_0x144bcb('0x18')],'read1stAt':_[_0x144bcb('0x81')](_0x20e5e5[_0x144bcb('0x79')])?moment()[_0x144bcb('0x4b')](_0x144bcb('0x55')):undefined});return null;})[_0x55a404('0x94')](function(_0x22b12a){const _0x28417f=_0x55a404;if(_0x22b12a)return _0x5fc020[_0x28417f('0x4a')]=_0x22b12a[_0x28417f('0x33')]({'plain':!![]}),interaction_log['info'](_0x28417f('0x21'),_0x334120[_0x28417f('0x51')]['id'],_0x334120[_0x28417f('0x51')]['name'],_0x334120[_0x28417f('0x51')][_0x28417f('0x7b')],_0x5fc020[_0x28417f('0x4a')]['id'],_0x334120[_0x28417f('0x48')]?JSON['stringify'](_0x334120[_0x28417f('0x48')]):'null'),respondWithRpcPromise(_0x28417f('0x80'),_0x28417f('0x5f'),_0x5fc020);return null;})['then'](function(_0x4998e7){const _0x5b987d=_0x55a404;if(_0x4998e7){if(_0x334120[_0x5b987d('0x48')]['manual'])return _0x5fc020['message'][_0x5b987d('0x2e')]=util[_0x5b987d('0x4b')]('SIP/%s',_0x334120[_0x5b987d('0x51')][_0x5b987d('0x65')]),_0x5fc020[_0x5b987d('0x5a')][_0x5b987d('0x25')]=_0x5fc020[_0x5b987d('0x25')],_0x5fc020[_0x5b987d('0x5a')]['event']=_0x5b987d('0x43'),respondWithRpcPromise('EventManager',_0x5b987d('0x54'),{'event':_0x5b987d('0x3b'),'message':_0x5fc020[_0x5b987d('0x5a')]},client9002)[_0x5b987d('0x94')](function(){return _0x5fc020;});return _0x5fc020;}return null;})[_0x55a404('0x94')](respondWithResult(_0x4f9d56,null))['catch'](handleError(_0x4f9d56,null));},exports[_0x23de70('0x47')]=function(_0x19597b,_0x105fdf){const _0x1244ac=_0x23de70,_0x1c47bd={'agent':{},'channel':_0x1244ac('0x5c')};return _0x19597b[_0x1244ac('0x48')]['id']&&delete _0x19597b[_0x1244ac('0x48')]['id'],_0x19597b[_0x1244ac('0x48')][_0x1244ac('0x18')]=_0x19597b[_0x1244ac('0x48')]['UserId']||_0x19597b['user']['id'],_0x1c47bd[_0x1244ac('0x7')]['id']=_0x19597b['body'][_0x1244ac('0x18')],db[_0x1244ac('0x3')][_0x1244ac('0x40')]({'where':{'id':_0x19597b['params']['id'],'UserId':null}})[_0x1244ac('0x94')](handleEntityNotFound(_0x105fdf,null))[_0x1244ac('0x94')](function(_0x375d88){const _0x3d1de4=_0x1244ac;if(_0x375d88)return _0x1c47bd[_0x3d1de4('0x5a')]=_0x375d88['get']({'plain':!![]}),db[_0x3d1de4('0x77')][_0x3d1de4('0x40')]({'where':{'id':_0x375d88[_0x3d1de4('0x2')]}});return null;})[_0x1244ac('0x94')](handleEntityNotFound(_0x105fdf,null))['then'](function(_0x4973f2){const _0x248ad3=_0x1244ac;if(_0x4973f2)return _0x1c47bd[_0x248ad3('0x4a')]=_0x4973f2[_0x248ad3('0x33')]({'plain':!![]}),interaction_log[_0x248ad3('0x0')](_0x248ad3('0x36'),_0x19597b['user']['id'],_0x19597b[_0x248ad3('0x51')][_0x248ad3('0x65')],_0x19597b[_0x248ad3('0x51')][_0x248ad3('0x7b')],_0x1c47bd[_0x248ad3('0x4a')]['id'],_0x19597b[_0x248ad3('0x48')]?JSON[_0x248ad3('0x96')](_0x19597b[_0x248ad3('0x48')]):_0x248ad3('0x83')),respondWithRpcPromise(_0x248ad3('0x66'),_0x248ad3('0x13'),_0x1c47bd);return null;})[_0x1244ac('0x94')](function(_0x541136){const _0x345f18=_0x1244ac;if(_0x541136)return _0x541136[_0x345f18('0x5a')][_0x345f18('0x2e')]=util[_0x345f18('0x4b')](_0x345f18('0x68'),_0x19597b['user']['name']),_0x541136[_0x345f18('0x5a')][_0x345f18('0x25')]=_0x1c47bd[_0x345f18('0x25')],_0x541136[_0x345f18('0x5a')][_0x345f18('0x86')]=_0x345f18('0x47'),respondWithRpcPromise('EventManager',_0x345f18('0x54'),{'event':_0x345f18('0x95'),'message':_0x541136['message']},client9002),_0x1c47bd;return null;})['then'](respondWithResult(_0x105fdf,null))[_0x1244ac('0x15')](handleError(_0x105fdf,null));},exports[_0x23de70('0x88')]=function(_0x50a156,_0x451691){const _0x4a397b=_0x23de70,_0x2d3a85=moment()[_0x4a397b('0x3e')]()['toString'](),_0x475648=path[_0x4a397b('0x7a')](config['root'],_0x4a397b('0x1f'),_0x4a397b('0x74')),_0xa814ee=path[_0x4a397b('0x7a')](config[_0x4a397b('0x14')],_0x4a397b('0x84'),_0x4a397b('0x1f'),'attachments'),_0x45f5e5=util[_0x4a397b('0x4b')](_0x4a397b('0x10'),_0x2d3a85);return db['MailMessage'][_0x4a397b('0x40')]({'where':{'id':_0x50a156[_0x4a397b('0xa')]['id']},'attributes':['id',_0x4a397b('0x48'),'from','to','cc',_0x4a397b('0x34'),_0x4a397b('0x90'),_0x4a397b('0x1e')],'include':_0x50a156[_0x4a397b('0xe')][_0x4a397b('0x8f')]?[{'model':db['Attachment'],'as':_0x4a397b('0x9')}]:undefined})[_0x4a397b('0x94')](handleEntityNotFound(_0x451691,null))['then'](function(_0x588c18){const _0x39c22a=_0x4a397b;if(_0x588c18){const _0x5cee39=_0x588c18,_0x3a3bfc={'from':_0x5cee39[_0x39c22a('0x19')],'to':_0x5cee39['to'],'subject':_0x5cee39['subject'],'html':_0x5cee39[_0x39c22a('0x48')],'headers':{'Date':moment(_0x5cee39[_0x39c22a('0x1e')])[_0x39c22a('0x4b')]('ddd,\x20DD\x20MMM\x20YYYY\x20HH:mm:ss\x20ZZ')},'attachments':[]};return _0x588c18['cc']&&(_0x3a3bfc[_0x39c22a('0x6f')]['Cc']=_0x588c18['cc']),_0x588c18[_0x39c22a('0x34')]&&(_0x3a3bfc[_0x39c22a('0x6f')][_0x39c22a('0x53')]=_0x588c18[_0x39c22a('0x34')]),new Promise(function(_0xec4d8f,_0x14f2c3){const _0xb6850c=_0x39c22a;if(_0x588c18[_0xb6850c('0x9')])for(let _0x4f1b69=0x0;_0x4f1b69<_0x588c18[_0xb6850c('0x9')][_0xb6850c('0x7f')];_0x4f1b69++){const _0x3b2aeb=_0x588c18[_0xb6850c('0x9')][_0x4f1b69],_0x2d9ba4=path['join'](_0xa814ee,_0x3b2aeb[_0xb6850c('0x31')]);fs[_0xb6850c('0x62')](_0x2d9ba4)&&_0x3a3bfc[_0xb6850c('0x8f')][_0xb6850c('0x4c')]({'name':_0x3b2aeb[_0xb6850c('0x65')],'contentType':_0x3b2aeb[_0xb6850c('0x23')],'data':fs[_0xb6850c('0x1a')](_0x2d9ba4)});}emlformat['build'](_0x3a3bfc,function(_0x3337a2,_0x447ac5){const _0x2edb16=_0xb6850c;if(_0x3337a2)return _0x14f2c3(_0x3337a2);return fs[_0x2edb16('0x8')](path[_0x2edb16('0x7a')](_0x475648,_0x45f5e5),_0x447ac5),_0xec4d8f(_0x447ac5);});});}})[_0x4a397b('0x94')](function(_0x5870d6){const _0x174a13=_0x4a397b;if(_0x5870d6)return _0x451691[_0x174a13('0x88')](path[_0x174a13('0x7a')](_0x475648,_0x45f5e5),_0x45f5e5,function(_0x13c3c1){const _0x367850=_0x174a13;_0x13c3c1?console[_0x367850('0x8b')](_0x367850('0x20'),_0x13c3c1):fs[_0x367850('0xb')](path[_0x367850('0x7a')](_0x475648,_0x45f5e5));});})['catch'](handleError(_0x451691,null));}; \ No newline at end of file +const a413_0x195f=['readAt','describe','attributes','include','update','root','eml-format','rawAttributes','includeAll','split','agent','subject','channel','rejectMessage','AcceptMessage','end','direction','offset','jayson/promise','secure','api','query','read','createdAt','rows','Attachments','MailAccountId','acceptMessage','count','log','client','where','order','RejectMessage','accept','Attachment','from','defaults','index','name','destroy','findAll','manual','then','MailInteraction','keys','register','push','auth','unix','http','files','../../components/parsers/qs','updatedAt','merge','format','List','options','send','map','interaction','length','util','reject','key','./mailMessage.socket','intersection','[MAILMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','MailInteractionId','host','sort','out','port','sendMail','body','type','bcc','EventManager','pass','pick','server/files/attachments','authentication','Bcc','List\x20not\x20found','ListId','lodash','mail','stringify','MailMessage,\x20%s,\x20%s,\x20%s','interface','info','basename','SIP/%s','secret','error','mail-interactions','sendStatus','MailMessage','MailServerOut','findOne','like','catch','undefined','YYYY-MM-DD\x20HH:mm:ss','isNil','event','SendMail','service','ddd,\x20DD\x20MMM\x20YYYY\x20HH:mm:ss\x20ZZ','CmContact','filter','../../rediscache','server','get','model','create','status','role','debug','fields','readFileSync','[MAILMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','stack','limit','rejectmessage','filters','user','unlinkSync','params','fieldName','message-%s.eml','nolimit','download','headers','request\x20sent','Contact','MailMessage,\x20%s,\x20%s','null','join','Contacts','build','message','json','UserId','attachments','Smtp','../../config/logger','path','VIRTUAL'];(function(_0x431057,_0x195fe4){const _0x57e798=function(_0x3d7911){while(--_0x3d7911){_0x431057['push'](_0x431057['shift']());}};_0x57e798(++_0x195fe4);}(a413_0x195f,0x14d));const a413_0x57e7=function(_0x431057,_0x195fe4){_0x431057=_0x431057-0x0;let _0x57e798=a413_0x195f[_0x431057];return _0x57e798;};const _0x4cb1a0=a413_0x57e7;'use strict';const emlformat=require(_0x4cb1a0('0x78')),moment=require('moment'),util=require(_0x4cb1a0('0x1b')),path=require(_0x4cb1a0('0x70')),fs=require('fs'),_=require(_0x4cb1a0('0x32')),{getSocket}=require(_0x4cb1a0('0x4c')),socket=getSocket(),qs=require(_0x4cb1a0('0x11')),logger=require(_0x4cb1a0('0x6f'))(_0x4cb1a0('0x86')),config=require('../../config/environment'),interaction_log=require(_0x4cb1a0('0x6f'))(_0x4cb1a0('0x3c')),db=require('../../mysqldb')['db'],{Op}=require('sequelize');require(_0x4cb1a0('0x1e'))[_0x4cb1a0('0xb')](socket);const jayson=require(_0x4cb1a0('0x84')),client=jayson[_0x4cb1a0('0x90')][_0x4cb1a0('0xf')]({'port':0x232c}),client9003=jayson['client']['http']({'port':0x232b}),client9002=jayson[_0x4cb1a0('0x90')][_0x4cb1a0('0xf')]({'port':0x232a});function respondWithRpcPromise(_0x3d7911,_0xa8ae56,_0x5d5542,_0x1128f0){return new Promise(function(_0x363c25,_0x518726){const _0x584cad=a413_0x57e7,_0x537a15=_0x1128f0||client;return _0x537a15['request'](_0x3d7911,_0x5d5542)[_0x584cad('0x8')](function(_0x3b423e){const _0x552cda=_0x584cad;logger['info'](_0x552cda('0x65'),_0xa8ae56,_0x552cda('0x63')),logger[_0x552cda('0x53')](_0x552cda('0x35'),_0xa8ae56,'request\x20sent',JSON[_0x552cda('0x34')](_0x3b423e));if(_0x3b423e[_0x552cda('0x3b')]){if(_0x3b423e[_0x552cda('0x3b')]['code']===0x1f4)return logger[_0x552cda('0x3b')](_0x552cda('0x65'),_0xa8ae56,_0x3b423e[_0x552cda('0x3b')]['message']),_0x518726(_0x3b423e['error']['message']);return logger['error'](_0x552cda('0x65'),_0xa8ae56,_0x3b423e[_0x552cda('0x3b')][_0x552cda('0x6a')]),_0x363c25(_0x3b423e['error']['message']);}else logger[_0x552cda('0x37')](_0x552cda('0x65'),_0xa8ae56,_0x552cda('0x63')),_0x363c25(_0x3b423e['result'][_0x552cda('0x6a')]);})[_0x584cad('0x42')](function(_0x1ed834){const _0x6826d1=_0x584cad;logger[_0x6826d1('0x3b')](_0x6826d1('0x65'),_0xa8ae56,_0x1ed834),_0x518726(_0x1ed834);});});}function respondWithResult(_0xf05005,_0x5e8974){return _0x5e8974=_0x5e8974||0xc8,function(_0x379c10){const _0x1810c5=a413_0x57e7;if(_0x379c10)return _0xf05005['status'](_0x5e8974)[_0x1810c5('0x6b')](_0x379c10);};}function respondWithFilteredResult(_0x514216,_0x3caa93){return function(_0x31cc7e){const _0x27d8c9=a413_0x57e7;if(_0x31cc7e){const _0x323b05=_0x31cc7e[_0x27d8c9('0x8e')],_0x795419=_0x3caa93[_0x27d8c9('0x83')];let _0x479f25=_0x3caa93[_0x27d8c9('0x83')]+_0x3caa93[_0x27d8c9('0x58')],_0x5dc01f;return _0x479f25>=_0x323b05?(_0x479f25=_0x323b05,_0x5dc01f=0xc8):_0x5dc01f=0xce,_0x514216[_0x27d8c9('0x51')](_0x5dc01f),_0x514216['set']('Content-Range',_0x795419+'-'+_0x479f25+'/'+_0x323b05)['json'](_0x31cc7e);}return null;};}function saveUpdates(_0x261912){return function(_0x17171f){const _0x5c9d0a=a413_0x57e7;if(_0x17171f)return _0x17171f[_0x5c9d0a('0x76')](_0x261912)['then'](function(_0x46b18c){return _0x46b18c;});return null;};}function removeEntity(_0x363f9a){return function(_0x11fc1a){const _0x48a717=a413_0x57e7;if(_0x11fc1a)return _0x11fc1a[_0x48a717('0x5')]()[_0x48a717('0x8')](function(){const _0x1eac52=_0x48a717;_0x363f9a[_0x1eac52('0x51')](0xcc)[_0x1eac52('0x81')]();});};}function handleEntityNotFound(_0x4fb1b5){return function(_0x31b984){const _0x1edcf2=a413_0x57e7;return!_0x31b984&&_0x4fb1b5[_0x1edcf2('0x3d')](0x194),_0x31b984;};}function handleError(_0x1cc7ef,_0xb47145){return _0xb47145=_0xb47145||0x1f4,function(_0x37b125){const _0x211602=a413_0x57e7;logger['error'](_0x37b125[_0x211602('0x57')]),_0x37b125['name']&&delete _0x37b125[_0x211602('0x4')],_0x1cc7ef[_0x211602('0x51')](_0xb47145)[_0x211602('0x17')](_0x37b125);};}exports[_0x4cb1a0('0x3')]=function(_0x2cd0f9,_0x33aa1b){const _0x4ef064=_0x4cb1a0;let _0x221bb6={};const _0x2700d4={},_0xbe63a6={'count':0x0,'rows':[]},_0x5c764c=_['map'](db[_0x4ef064('0x3e')][_0x4ef064('0x79')],function(_0x187bde){const _0x347a99=_0x4ef064;return{'name':_0x187bde[_0x347a99('0x5e')],'type':_0x187bde[_0x347a99('0x28')][_0x347a99('0x1d')]};});_0x2700d4[_0x4ef064('0x4f')]=_[_0x4ef064('0x18')](_0x5c764c,_0x4ef064('0x4')),_0x2700d4[_0x4ef064('0x87')]=_[_0x4ef064('0xa')](_0x2cd0f9[_0x4ef064('0x87')]),_0x2700d4[_0x4ef064('0x5a')]=_['intersection'](_0x2700d4[_0x4ef064('0x4f')],_0x2700d4['query']),_0x221bb6[_0x4ef064('0x74')]=_[_0x4ef064('0x1f')](_0x2700d4[_0x4ef064('0x4f')],qs['fields'](_0x2cd0f9[_0x4ef064('0x87')]['fields'])),_0x221bb6[_0x4ef064('0x74')]=_0x221bb6[_0x4ef064('0x74')][_0x4ef064('0x1a')]?_0x221bb6[_0x4ef064('0x74')]:_0x2700d4[_0x4ef064('0x4f')];typeof _0x2cd0f9[_0x4ef064('0x87')][_0x4ef064('0x60')]===_0x4ef064('0x43')&&(_0x221bb6[_0x4ef064('0x58')]=qs[_0x4ef064('0x58')](_0x2cd0f9[_0x4ef064('0x87')][_0x4ef064('0x58')]),_0x221bb6[_0x4ef064('0x83')]=qs[_0x4ef064('0x83')](_0x2cd0f9['query'][_0x4ef064('0x83')]));_0x221bb6[_0x4ef064('0x92')]=qs[_0x4ef064('0x23')](_0x2cd0f9[_0x4ef064('0x87')][_0x4ef064('0x23')]),_0x221bb6['where']=qs['filters'](_[_0x4ef064('0x2c')](_0x2cd0f9[_0x4ef064('0x87')],_0x2700d4[_0x4ef064('0x5a')]),_0x5c764c);_0x2cd0f9[_0x4ef064('0x87')][_0x4ef064('0x4b')]&&(_0x221bb6['where']=_[_0x4ef064('0x13')](_0x221bb6[_0x4ef064('0x91')],{[Op['or']]:_[_0x4ef064('0x18')](_0x5c764c,function(_0x2e984d){const _0x1fba6c=_0x4ef064;if(_0x2e984d[_0x1fba6c('0x28')]!==_0x1fba6c('0x71')){const _0x4511c8={};return _0x4511c8[_0x2e984d[_0x1fba6c('0x4')]]={[Op[_0x1fba6c('0x41')]]:'%'+_0x2cd0f9['query']['filter']+'%'},_0x4511c8;}})}));_0x221bb6=_[_0x4ef064('0x13')]({},_0x221bb6,_0x2cd0f9[_0x4ef064('0x16')]);const _0xe70b0f={'where':_0x221bb6[_0x4ef064('0x91')]};return db[_0x4ef064('0x3e')]['count'](_0xe70b0f)[_0x4ef064('0x8')](function(_0x57cf1c){const _0x40d17a=_0x4ef064;return _0xbe63a6['count']=_0x57cf1c,_0x2cd0f9[_0x40d17a('0x87')][_0x40d17a('0x7a')]&&(_0x221bb6[_0x40d17a('0x75')]=[{'all':!![]}]),db[_0x40d17a('0x3e')][_0x40d17a('0x6')](_0x221bb6);})[_0x4ef064('0x8')](function(_0x4c2236){const _0x33256e=_0x4ef064;return _0xbe63a6[_0x33256e('0x8a')]=_0x4c2236,_0xbe63a6;})[_0x4ef064('0x8')](respondWithFilteredResult(_0x33aa1b,_0x221bb6))[_0x4ef064('0x42')](handleError(_0x33aa1b,null));},exports['show']=function(_0xd05fcd,_0x2a100b){const _0x3e23e7=_0x4cb1a0;let _0x54c71c={'raw':!![],'where':{'id':_0xd05fcd['params']['id']}};const _0x2009a9={};return _0x2009a9[_0x3e23e7('0x4f')]=_[_0x3e23e7('0xa')](db[_0x3e23e7('0x3e')][_0x3e23e7('0x79')]),_0x2009a9[_0x3e23e7('0x87')]=_[_0x3e23e7('0xa')](_0xd05fcd[_0x3e23e7('0x87')]),_0x2009a9[_0x3e23e7('0x5a')]=_[_0x3e23e7('0x1f')](_0x2009a9[_0x3e23e7('0x4f')],_0x2009a9[_0x3e23e7('0x87')]),_0x54c71c[_0x3e23e7('0x74')]=_[_0x3e23e7('0x1f')](_0x2009a9['model'],qs['fields'](_0xd05fcd[_0x3e23e7('0x87')][_0x3e23e7('0x54')])),_0x54c71c[_0x3e23e7('0x74')]=_0x54c71c[_0x3e23e7('0x74')]['length']?_0x54c71c[_0x3e23e7('0x74')]:_0x2009a9['model'],_0xd05fcd[_0x3e23e7('0x87')]['includeAll']&&(_0x54c71c[_0x3e23e7('0x75')]=[{'all':!![]}]),_0x54c71c=_[_0x3e23e7('0x13')]({},_0x54c71c,_0xd05fcd[_0x3e23e7('0x16')]),db['MailMessage'][_0x3e23e7('0x40')](_0x54c71c)[_0x3e23e7('0x8')](handleEntityNotFound(_0x2a100b,null))[_0x3e23e7('0x8')](respondWithResult(_0x2a100b,null))['catch'](handleError(_0x2a100b,null));},exports[_0x4cb1a0('0x76')]=function(_0x47c7c0,_0x5e8d37){const _0x15750d=_0x4cb1a0;return _0x47c7c0['body']['id']&&delete _0x47c7c0['body']['id'],db[_0x15750d('0x3e')][_0x15750d('0x40')]({'where':{'id':_0x47c7c0[_0x15750d('0x5d')]['id']}})['then'](handleEntityNotFound(_0x5e8d37,null))[_0x15750d('0x8')](saveUpdates(_0x47c7c0[_0x15750d('0x27')],null))[_0x15750d('0x8')](respondWithResult(_0x5e8d37,null))['catch'](handleError(_0x5e8d37,null));},exports[_0x4cb1a0('0x5')]=function(_0x1f9ea9,_0x2703cf){const _0x5ace73=_0x4cb1a0;return db['MailMessage'][_0x5ace73('0x40')]({'where':{'id':_0x1f9ea9[_0x5ace73('0x5d')]['id']}})[_0x5ace73('0x8')](handleEntityNotFound(_0x2703cf,null))[_0x5ace73('0x8')](removeEntity(_0x2703cf,null))['catch'](handleError(_0x2703cf,null));},exports[_0x4cb1a0('0x73')]=function(_0xd810e9,_0x17a58c){const _0x5bc784=_0x4cb1a0;return db[_0x5bc784('0x3e')][_0x5bc784('0x73')]()[_0x5bc784('0x8')](respondWithResult(_0x17a58c,null))[_0x5bc784('0x42')](handleError(_0x17a58c,null));},exports[_0x4cb1a0('0x50')]=function(_0x3c05d7,_0x79a375){const _0x296415=_0x4cb1a0;return db[_0x296415('0x3e')]['create'](_0x3c05d7[_0x296415('0x27')])[_0x296415('0x8')](function(_0x426364){const _0x83347=_0x296415;if(_0x426364){if(_0x426364[_0x83347('0x82')]===_0x83347('0x24')&&!_0x426364[_0x83347('0x3a')]){let _0x48f580,_0x11e5aa,_0x3d1f28;return _0x3c05d7[_0x83347('0x27')]['to']&&(_0x11e5aa=_0x3c05d7[_0x83347('0x27')]['to'][_0x83347('0x7b')](',')[0x0]),db['MailAccount'][_0x83347('0x40')]({'where':{'id':_0x426364[_0x83347('0x8c')]},'include':[{'model':db['CmList'],'as':'List','include':[{'model':db['CmContact'],'as':_0x83347('0x68'),'where':{'email':_0x11e5aa},'limit':0x1,'order':[[_0x83347('0x12'),'DESC']]}]},{'model':db[_0x83347('0x3f')],'as':_0x83347('0x6e'),'raw':!![]}]})['then'](function(_0x373972){const _0x9735c6=_0x83347;_0x48f580=_0x373972;if(_0x48f580&&_0x48f580[_0x9735c6('0x6e')]){const _0x18c951={'tls':{'rejectUnauthorized':![]}};_[_0x9735c6('0x45')](_0x48f580[_0x9735c6('0x6e')][_0x9735c6('0x48')])?(_0x18c951[_0x9735c6('0x22')]=_0x48f580['Smtp'][_0x9735c6('0x22')],_0x18c951[_0x9735c6('0x25')]=_0x48f580[_0x9735c6('0x6e')][_0x9735c6('0x25')],_0x18c951[_0x9735c6('0x85')]=_0x48f580[_0x9735c6('0x6e')]['secure'],_0x48f580['Smtp'][_0x9735c6('0x2e')]&&(_0x18c951[_0x9735c6('0xd')]={'user':_0x48f580[_0x9735c6('0x6e')][_0x9735c6('0x5b')],'pass':_0x48f580[_0x9735c6('0x6e')][_0x9735c6('0x2b')]})):(_0x18c951[_0x9735c6('0x48')]=_0x48f580[_0x9735c6('0x6e')][_0x9735c6('0x48')],_0x18c951[_0x9735c6('0xd')]={'user':_0x48f580['Smtp'][_0x9735c6('0x5b')],'pass':_0x48f580[_0x9735c6('0x6e')][_0x9735c6('0x2b')]},_0x18c951[_0x9735c6('0x85')]=_0x48f580[_0x9735c6('0x6e')][_0x9735c6('0x85')]);if(_0x3c05d7['body'][_0x9735c6('0x6d')]&&_0x3c05d7['body'][_0x9735c6('0x6d')]['length'])for(let _0x2e0540=0x0;_0x2e0540<_0x3c05d7[_0x9735c6('0x27')][_0x9735c6('0x6d')][_0x9735c6('0x1a')];_0x2e0540+=0x1){_0x3c05d7[_0x9735c6('0x27')]['attachments'][_0x2e0540]={'filename':_0x3c05d7['body'][_0x9735c6('0x6d')][_0x2e0540]['name'],'path':path[_0x9735c6('0x67')](config['root'],_0x9735c6('0x2d'),_0x3c05d7[_0x9735c6('0x27')][_0x9735c6('0x6d')][_0x2e0540]['basename'])};}_0x3d1f28={'account':_0x18c951,'message':_0x3c05d7[_0x9735c6('0x27')]};return;}})['then'](function(){const _0x5844c3=_0x83347;if(_0x48f580[_0x5844c3('0x15')])return _0x48f580[_0x5844c3('0x15')][_0x5844c3('0x68')][_0x5844c3('0x1a')]?_0x48f580[_0x5844c3('0x15')][_0x5844c3('0x68')][0x0]:db['CmContact'][_0x5844c3('0x50')](_[_0x5844c3('0x2')](_0x3c05d7[_0x5844c3('0x27')],{'firstName':_0x3c05d7[_0x5844c3('0x27')]['to'],'email':_0x3c05d7[_0x5844c3('0x27')]['to'],'phone':_0x3c05d7[_0x5844c3('0x27')]['to'],'ListId':_0x48f580[_0x5844c3('0x31')]}));else throw new Error(_0x5844c3('0x30'));})[_0x83347('0x8')](function(){const _0x5b3385=_0x83347;if(_0x3d1f28)return respondWithRpcPromise(_0x5b3385('0x47'),_0x5b3385('0x26'),_0x3d1f28,client9003)[_0x5b3385('0x8')](function(_0x139341){const _0x583b8a=_0x5b3385;return _0x426364[_0x583b8a('0x76')]({'read':!![],'messageId':_0x139341['messageId'],'sentAt':moment()['format']('YYYY-MM-DD\x20HH:mm:ss')});})[_0x5b3385('0x42')](function(_0x22d2e3){const _0x491424=_0x5b3385;return logger[_0x491424('0x3b')]('%s',JSON[_0x491424('0x34')](_0x22d2e3)),_0x426364;});return _0x426364;});}return _0x426364;}})['then'](respondWithResult(_0x79a375,0xc9))[_0x296415('0x42')](handleError(_0x79a375,null));},exports[_0x4cb1a0('0x94')]=function(_0x39a892,_0x59b4ab){const _0x2d25ac=_0x4cb1a0,_0x1010b0={'channel':_0x2d25ac('0x33')};return _0x39a892['body']['id']&&delete _0x39a892[_0x2d25ac('0x27')]['id'],_0x39a892[_0x2d25ac('0x27')][_0x2d25ac('0x88')]=!![],_0x39a892[_0x2d25ac('0x27')][_0x2d25ac('0x72')]=moment()[_0x2d25ac('0x14')](_0x2d25ac('0x44')),_0x39a892[_0x2d25ac('0x27')][_0x2d25ac('0x6c')]=_0x39a892[_0x2d25ac('0x27')][_0x2d25ac('0x6c')]||_0x39a892['user']['id'],db[_0x2d25ac('0x3e')]['findOne']({'where':{'id':_0x39a892[_0x2d25ac('0x5d')]['id'],'UserId':null},'include':[{'model':db[_0x2d25ac('0x4a')],'as':_0x2d25ac('0x64')}]})[_0x2d25ac('0x8')](handleEntityNotFound(_0x59b4ab,null))[_0x2d25ac('0x8')](saveUpdates(_0x39a892[_0x2d25ac('0x27')],null))[_0x2d25ac('0x8')](function(_0x503816){const _0xd21839=_0x2d25ac;if(_0x503816)return _0x1010b0[_0xd21839('0x6a')]=_0x503816['get']({'plain':!![]}),db[_0xd21839('0x9')]['findOne']({'where':{'id':_0x503816['MailInteractionId']}});return null;})[_0x2d25ac('0x8')](handleEntityNotFound(_0x59b4ab,null))[_0x2d25ac('0x8')](function(_0x3499a9){const _0x48309b=_0x2d25ac;if(_0x3499a9)return _0x3499a9[_0x48309b('0x76')]({'UserId':_0x39a892[_0x48309b('0x27')][_0x48309b('0x6c')],'read1stAt':_[_0x48309b('0x45')](_0x3499a9['read1stAt'])?moment()['format'](_0x48309b('0x44')):undefined});return null;})[_0x2d25ac('0x8')](function(_0x29141a){const _0x4566c9=_0x2d25ac;if(_0x29141a)return _0x1010b0[_0x4566c9('0x19')]=_0x29141a[_0x4566c9('0x4e')]({'plain':!![]}),interaction_log[_0x4566c9('0x37')](_0x4566c9('0x20'),_0x39a892[_0x4566c9('0x5b')]['id'],_0x39a892[_0x4566c9('0x5b')]['name'],_0x39a892[_0x4566c9('0x5b')][_0x4566c9('0x52')],_0x1010b0[_0x4566c9('0x19')]['id'],_0x39a892[_0x4566c9('0x27')]?JSON['stringify'](_0x39a892[_0x4566c9('0x27')]):_0x4566c9('0x66')),respondWithRpcPromise(_0x4566c9('0x80'),_0x4566c9('0x8d'),_0x1010b0);return null;})[_0x2d25ac('0x8')](function(_0x3d13c5){const _0x3cf776=_0x2d25ac;if(_0x3d13c5){if(_0x39a892[_0x3cf776('0x27')][_0x3cf776('0x7')])return _0x1010b0[_0x3cf776('0x6a')][_0x3cf776('0x36')]=util[_0x3cf776('0x14')](_0x3cf776('0x39'),_0x39a892['user'][_0x3cf776('0x4')]),_0x1010b0['message'][_0x3cf776('0x7e')]=_0x1010b0[_0x3cf776('0x7e')],_0x1010b0[_0x3cf776('0x6a')][_0x3cf776('0x46')]='accept',respondWithRpcPromise('EventManager',_0x3cf776('0x2a'),{'event':'acceptmessage','message':_0x1010b0['message']},client9002)['then'](function(){return _0x1010b0;});return _0x1010b0;}return null;})['then'](respondWithResult(_0x59b4ab,null))[_0x2d25ac('0x42')](handleError(_0x59b4ab,null));},exports[_0x4cb1a0('0x1c')]=function(_0x30a1e2,_0x270904){const _0x1613a2=_0x4cb1a0,_0x6e92c6={'agent':{},'channel':_0x1613a2('0x33')};return _0x30a1e2[_0x1613a2('0x27')]['id']&&delete _0x30a1e2[_0x1613a2('0x27')]['id'],_0x30a1e2['body'][_0x1613a2('0x6c')]=_0x30a1e2[_0x1613a2('0x27')][_0x1613a2('0x6c')]||_0x30a1e2[_0x1613a2('0x5b')]['id'],_0x6e92c6[_0x1613a2('0x7c')]['id']=_0x30a1e2[_0x1613a2('0x27')][_0x1613a2('0x6c')],db[_0x1613a2('0x3e')][_0x1613a2('0x40')]({'where':{'id':_0x30a1e2['params']['id'],'UserId':null}})['then'](handleEntityNotFound(_0x270904,null))[_0x1613a2('0x8')](function(_0x2f3bfe){const _0x3057fd=_0x1613a2;if(_0x2f3bfe)return _0x6e92c6['message']=_0x2f3bfe[_0x3057fd('0x4e')]({'plain':!![]}),db[_0x3057fd('0x9')][_0x3057fd('0x40')]({'where':{'id':_0x2f3bfe[_0x3057fd('0x21')]}});return null;})['then'](handleEntityNotFound(_0x270904,null))[_0x1613a2('0x8')](function(_0x12f10e){const _0x535e1a=_0x1613a2;if(_0x12f10e)return _0x6e92c6['interaction']=_0x12f10e['get']({'plain':!![]}),interaction_log[_0x535e1a('0x37')](_0x535e1a('0x56'),_0x30a1e2[_0x535e1a('0x5b')]['id'],_0x30a1e2['user']['name'],_0x30a1e2['user'][_0x535e1a('0x52')],_0x6e92c6['interaction']['id'],_0x30a1e2['body']?JSON[_0x535e1a('0x34')](_0x30a1e2['body']):_0x535e1a('0x66')),respondWithRpcPromise(_0x535e1a('0x93'),_0x535e1a('0x7f'),_0x6e92c6);return null;})[_0x1613a2('0x8')](function(_0x15e0b4){const _0x592d34=_0x1613a2;if(_0x15e0b4)return _0x15e0b4[_0x592d34('0x6a')][_0x592d34('0x36')]=util[_0x592d34('0x14')]('SIP/%s',_0x30a1e2[_0x592d34('0x5b')]['name']),_0x15e0b4['message'][_0x592d34('0x7e')]=_0x6e92c6[_0x592d34('0x7e')],_0x15e0b4[_0x592d34('0x6a')][_0x592d34('0x46')]=_0x592d34('0x1c'),respondWithRpcPromise(_0x592d34('0x2a'),_0x592d34('0x2a'),{'event':_0x592d34('0x59'),'message':_0x15e0b4['message']},client9002),_0x6e92c6;return null;})[_0x1613a2('0x8')](respondWithResult(_0x270904,null))[_0x1613a2('0x42')](handleError(_0x270904,null));},exports[_0x4cb1a0('0x61')]=function(_0x26049e,_0x20feeb){const _0x5f411f=_0x4cb1a0,_0x3ccc99=moment()[_0x5f411f('0xe')]()['toString'](),_0x167f67=path[_0x5f411f('0x67')](config[_0x5f411f('0x77')],_0x5f411f('0x10'),'tmp'),_0x3643a4=path[_0x5f411f('0x67')](config[_0x5f411f('0x77')],_0x5f411f('0x4d'),_0x5f411f('0x10'),_0x5f411f('0x6d')),_0x358673=util[_0x5f411f('0x14')](_0x5f411f('0x5f'),_0x3ccc99);return db[_0x5f411f('0x3e')][_0x5f411f('0x40')]({'where':{'id':_0x26049e[_0x5f411f('0x5d')]['id']},'attributes':['id',_0x5f411f('0x27'),_0x5f411f('0x1'),'to','cc',_0x5f411f('0x29'),'subject',_0x5f411f('0x89')],'include':_0x26049e[_0x5f411f('0x87')][_0x5f411f('0x6d')]?[{'model':db[_0x5f411f('0x0')],'as':_0x5f411f('0x8b')}]:undefined})['then'](handleEntityNotFound(_0x20feeb,null))[_0x5f411f('0x8')](function(_0x30fe62){const _0x1c7649=_0x5f411f;if(_0x30fe62){const _0x20a2f1=_0x30fe62,_0x19bc63={'from':_0x20a2f1[_0x1c7649('0x1')],'to':_0x20a2f1['to'],'subject':_0x20a2f1[_0x1c7649('0x7d')],'html':_0x20a2f1['body'],'headers':{'Date':moment(_0x20a2f1[_0x1c7649('0x89')])['format'](_0x1c7649('0x49'))},'attachments':[]};return _0x30fe62['cc']&&(_0x19bc63[_0x1c7649('0x62')]['Cc']=_0x30fe62['cc']),_0x30fe62[_0x1c7649('0x29')]&&(_0x19bc63['headers'][_0x1c7649('0x2f')]=_0x30fe62[_0x1c7649('0x29')]),new Promise(function(_0x3c2d08,_0x23658c){const _0x55213b=_0x1c7649;if(_0x30fe62[_0x55213b('0x8b')])for(let _0x47e4d1=0x0;_0x47e4d1<_0x30fe62['Attachments'][_0x55213b('0x1a')];_0x47e4d1++){const _0x23f90b=_0x30fe62[_0x55213b('0x8b')][_0x47e4d1],_0x12a8e0=path['join'](_0x3643a4,_0x23f90b[_0x55213b('0x38')]);fs['existsSync'](_0x12a8e0)&&_0x19bc63[_0x55213b('0x6d')][_0x55213b('0xc')]({'name':_0x23f90b[_0x55213b('0x4')],'contentType':_0x23f90b[_0x55213b('0x28')],'data':fs[_0x55213b('0x55')](_0x12a8e0)});}emlformat[_0x55213b('0x69')](_0x19bc63,function(_0x91329c,_0x2add65){const _0x2d66b2=_0x55213b;if(_0x91329c)return _0x23658c(_0x91329c);return fs['writeFileSync'](path[_0x2d66b2('0x67')](_0x167f67,_0x358673),_0x2add65),_0x3c2d08(_0x2add65);});});}})[_0x5f411f('0x8')](function(_0x446389){const _0x3c836a=_0x5f411f;if(_0x446389)return _0x20feeb['download'](path[_0x3c836a('0x67')](_0x167f67,_0x358673),_0x358673,function(_0x6fd0c2){const _0x79018b=_0x3c836a;_0x6fd0c2?console[_0x79018b('0x8f')]('err',_0x6fd0c2):fs[_0x79018b('0x5c')](path[_0x79018b('0x67')](_0x167f67,_0x358673));});})[_0x5f411f('0x42')](handleError(_0x20feeb,null));}; \ No newline at end of file diff --git a/server/api/mailMessage/mailMessage.events.js b/server/api/mailMessage/mailMessage.events.js index 19101bd..6a7011a 100644 --- a/server/api/mailMessage/mailMessage.events.js +++ b/server/api/mailMessage/mailMessage.events.js @@ -1 +1 @@ -const a414_0x2806=['emit','setMaxListeners','events','update','MailMessage','exports','save','remove','undefined','../../mysqldb'];(function(_0x2361d3,_0x28062f){const _0x3954f1=function(_0x500e1d){while(--_0x500e1d){_0x2361d3['push'](_0x2361d3['shift']());}};_0x3954f1(++_0x28062f);}(a414_0x2806,0x155));const a414_0x3954=function(_0x2361d3,_0x28062f){_0x2361d3=_0x2361d3-0x0;let _0x3954f1=a414_0x2806[_0x2361d3];return _0x3954f1;};const _0x15586f=a414_0x3954;'use strict';const EventEmitter=require(_0x15586f('0x1')),MailMessage=require(_0x15586f('0x8'))['db'][_0x15586f('0x3')],MailMessageEvents=new EventEmitter();MailMessageEvents[_0x15586f('0x0')](0x0);const events={'afterCreate':_0x15586f('0x5'),'afterUpdate':_0x15586f('0x2'),'afterDestroy':_0x15586f('0x6')};function emitEvent(_0x500e1d){return function(_0x58f61e){const _0x505472=a414_0x3954;MailMessageEvents['emit'](_0x500e1d+':'+_0x58f61e['id'],_0x58f61e),MailMessageEvents[_0x505472('0x9')](_0x500e1d,_0x58f61e);};}for(const e in events){if(typeof events[e]!==_0x15586f('0x7')){const event=events[e];MailMessage['addHook'](e,emitEvent(event));}}module[_0x15586f('0x4')]=MailMessageEvents; \ No newline at end of file +const a414_0x2ced=['events','undefined','emit','../../mysqldb','MailMessage','update','exports'];(function(_0x7d7489,_0x2ced6d){const _0x532317=function(_0x46aa70){while(--_0x46aa70){_0x7d7489['push'](_0x7d7489['shift']());}};_0x532317(++_0x2ced6d);}(a414_0x2ced,0x10c));const a414_0x5323=function(_0x7d7489,_0x2ced6d){_0x7d7489=_0x7d7489-0x0;let _0x532317=a414_0x2ced[_0x7d7489];return _0x532317;};const _0x12727c=a414_0x5323;'use strict';const EventEmitter=require(_0x12727c('0x5')),MailMessage=require(_0x12727c('0x1'))['db'][_0x12727c('0x2')],MailMessageEvents=new EventEmitter();MailMessageEvents['setMaxListeners'](0x0);const events={'afterCreate':'save','afterUpdate':_0x12727c('0x3'),'afterDestroy':'remove'};function emitEvent(_0x46aa70){return function(_0x3b1463){const _0x49cfae=a414_0x5323;MailMessageEvents[_0x49cfae('0x0')](_0x46aa70+':'+_0x3b1463['id'],_0x3b1463),MailMessageEvents[_0x49cfae('0x0')](_0x46aa70,_0x3b1463);};}for(const e in events){if(typeof events[e]!==_0x12727c('0x6')){const event=events[e];MailMessage['addHook'](e,emitEvent(event));}}module[_0x12727c('0x4')]=MailMessageEvents; \ No newline at end of file diff --git a/server/api/mailMessage/mailMessage.model.js b/server/api/mailMessage/mailMessage.model.js index a1a8fb6..095b28b 100644 --- a/server/api/mailMessage/mailMessage.model.js +++ b/server/api/mailMessage/mailMessage.model.js @@ -1 +1 @@ -const a415_0xd7b8=['exports','error','subject','html-to-text','utf8mb4','MailInteraction','body','catch','findOne','MailMessage','plainBody','get','direction','createdAt','MailInteractionId','toLowerCase','isNil','lodash','out','UserId','FULLTEXT','define'];(function(_0x3567d8,_0xd7b89c){const _0x4e20aa=function(_0x5f57af){while(--_0x5f57af){_0x3567d8['push'](_0x3567d8['shift']());}};_0x4e20aa(++_0xd7b89c);}(a415_0xd7b8,0x16b));const a415_0x4e20=function(_0x3567d8,_0xd7b89c){_0x3567d8=_0x3567d8-0x0;let _0x4e20aa=a415_0xd7b8[_0x3567d8];return _0x4e20aa;};const _0x3cec00=a415_0x4e20;'use strict';const _=require(_0x3cec00('0x6')),{htmlToText}=require(_0x3cec00('0xe')),attributes=require('./mailMessage.attributes');module[_0x3cec00('0xb')]=function(_0x5f57af){const _0x1a2d3e=_0x3cec00,_0x5c6f97=_0x5f57af['models'],_0x17f1db=_0x5f57af[_0x1a2d3e('0xa')](_0x1a2d3e('0x14'),attributes,{'tableName':'mail_messages','paranoid':![],'indexes':[{'name':'messageId','fields':['messageId']},{'name':'fti_mail_messages','fields':[_0x1a2d3e('0x15'),_0x1a2d3e('0xd')],'type':_0x1a2d3e('0x9')}],'timestamps':!![],'hooks':{'beforeCreate':function(_0x42a275){const _0x4328e0=_0x1a2d3e;_0x42a275[_0x4328e0('0x11')]&&(_0x42a275[_0x4328e0('0x15')]=htmlToText(_0x42a275[_0x4328e0('0x11')],{'preserveNewlines':!![],'singleNewLineParagraphs':!![],'uppercaseHeadings':![],'noLinkBrackets':!![],'ignoreImage':!![]}));},'afterCreate':function(_0x550a45){const _0x3cbf40=_0x1a2d3e,_0x3a7bc4=_0x550a45[_0x3cbf40('0x0')]({'plain':!![]});(_0x3a7bc4['direction'][_0x3cbf40('0x4')]()==='in'||_0x3a7bc4[_0x3cbf40('0x1')]['toLowerCase']()===_0x3cbf40('0x7')&&!_0x3a7bc4['secret']&&!_[_0x3cbf40('0x5')](_0x3a7bc4[_0x3cbf40('0x8')]))&&_0x5c6f97[_0x3cbf40('0x10')][_0x3cbf40('0x13')]({'where':{'id':_0x3a7bc4[_0x3cbf40('0x3')]}})['then'](function(_0x149627){const _0xa1a126=_0x3cbf40;_0x149627&&_0x149627['update']({'lastMsgAt':_0x3a7bc4[_0xa1a126('0x2')],'lastMsgDirection':_0x3a7bc4[_0xa1a126('0x1')][_0xa1a126('0x4')](),'lastMsgBody':_0x3a7bc4[_0xa1a126('0x11')]});})[_0x3cbf40('0x12')](function(_0x592ae9){const _0x3981ad=_0x3cbf40;console[_0x3981ad('0xc')](_0x592ae9);});}},'charset':_0x1a2d3e('0xf'),'collate':'utf8mb4_unicode_ci'});return _0x17f1db;}; \ No newline at end of file +const a415_0x1ce8=['subject','direction','FULLTEXT','exports','then','out','utf8mb4_unicode_ci','utf8mb4','models','MailInteractionId','get','define','createdAt','lodash','messageId','mail_messages','body','plainBody','MailInteraction','secret','update','fti_mail_messages','./mailMessage.attributes','toLowerCase'];(function(_0x2524f7,_0x1ce8f2){const _0x112b06=function(_0x386ec7){while(--_0x386ec7){_0x2524f7['push'](_0x2524f7['shift']());}};_0x112b06(++_0x1ce8f2);}(a415_0x1ce8,0x96));const a415_0x112b=function(_0x2524f7,_0x1ce8f2){_0x2524f7=_0x2524f7-0x0;let _0x112b06=a415_0x1ce8[_0x2524f7];return _0x112b06;};const _0x5c1ba0=a415_0x112b;'use strict';const _=require(_0x5c1ba0('0x7')),{htmlToText}=require('html-to-text'),attributes=require(_0x5c1ba0('0x10'));module[_0x5c1ba0('0x15')]=function(_0x386ec7){const _0x120b0c=_0x5c1ba0,_0x744941=_0x386ec7[_0x120b0c('0x2')],_0x342890=_0x386ec7[_0x120b0c('0x5')]('MailMessage',attributes,{'tableName':_0x120b0c('0x9'),'paranoid':![],'indexes':[{'name':_0x120b0c('0x8'),'fields':[_0x120b0c('0x8')]},{'name':_0x120b0c('0xf'),'fields':[_0x120b0c('0xb'),_0x120b0c('0x12')],'type':_0x120b0c('0x14')}],'timestamps':!![],'hooks':{'beforeCreate':function(_0x203f00){const _0x3eda2a=_0x120b0c;_0x203f00[_0x3eda2a('0xa')]&&(_0x203f00['plainBody']=htmlToText(_0x203f00[_0x3eda2a('0xa')],{'preserveNewlines':!![],'singleNewLineParagraphs':!![],'uppercaseHeadings':![],'noLinkBrackets':!![],'ignoreImage':!![]}));},'afterCreate':function(_0x12942d){const _0x3f0585=_0x120b0c,_0x3bd781=_0x12942d[_0x3f0585('0x4')]({'plain':!![]});(_0x3bd781[_0x3f0585('0x13')][_0x3f0585('0x11')]()==='in'||_0x3bd781['direction'][_0x3f0585('0x11')]()===_0x3f0585('0x17')&&!_0x3bd781[_0x3f0585('0xd')]&&!_['isNil'](_0x3bd781['UserId']))&&_0x744941[_0x3f0585('0xc')]['findOne']({'where':{'id':_0x3bd781[_0x3f0585('0x3')]}})[_0x3f0585('0x16')](function(_0x50ac80){const _0x4089c8=_0x3f0585;_0x50ac80&&_0x50ac80[_0x4089c8('0xe')]({'lastMsgAt':_0x3bd781[_0x4089c8('0x6')],'lastMsgDirection':_0x3bd781['direction'][_0x4089c8('0x11')](),'lastMsgBody':_0x3bd781['body']});})['catch'](function(_0x43b860){console['error'](_0x43b860);});}},'charset':_0x120b0c('0x1'),'collate':_0x120b0c('0x0')});return _0x342890;}; \ No newline at end of file diff --git a/server/api/mailMessage/mailMessage.rpc.js b/server/api/mailMessage/mailMessage.rpc.js index 3c711da..9728bb4 100644 --- a/server/api/mailMessage/mailMessage.rpc.js +++ b/server/api/mailMessage/mailMessage.rpc.js @@ -1 +1 @@ -const a416_0x17ea=['../../mysqldb','message','../../config/logger','debug','raw','create','MailMessage','CreateMailMessage','rpc','info','../../rediscache','catch','register','error','stringify','then'];(function(_0x4a2c9b,_0x17ea40){const _0x38980f=function(_0x246d28){while(--_0x246d28){_0x4a2c9b['push'](_0x4a2c9b['shift']());}};_0x38980f(++_0x17ea40);}(a416_0x17ea,0x184));const a416_0x3898=function(_0x4a2c9b,_0x17ea40){_0x4a2c9b=_0x4a2c9b-0x0;let _0x38980f=a416_0x17ea[_0x4a2c9b];return _0x38980f;};const _0x5d9905=a416_0x3898;'use strict';const db=require(_0x5d9905('0xc'))['db'],logger=require(_0x5d9905('0xe'))(_0x5d9905('0x4')),{getSocket}=require(_0x5d9905('0x6')),socket=getSocket();require('./mailMessage.socket')[_0x5d9905('0x8')](socket),exports[_0x5d9905('0x3')]=function(_0x246d28){const _0x37f91d=this;return new Promise(function(_0x3e444c,_0x324976){const _0x1e2886=a416_0x3898;return db[_0x1e2886('0x2')][_0x1e2886('0x1')](_0x246d28['body'],{'raw':_0x246d28['options']?_0x246d28['options'][_0x1e2886('0x0')]===undefined?!![]:![]:!![]})[_0x1e2886('0xb')](function(_0x45f0d8){const _0x12c187=_0x1e2886;logger[_0x12c187('0x5')]('CreateMailMessage',_0x246d28),logger[_0x12c187('0xf')]('CreateMailMessage',_0x246d28,JSON[_0x12c187('0xa')](_0x45f0d8)),_0x3e444c(_0x45f0d8);})[_0x1e2886('0x7')](function(_0x2133fa){const _0x37f63f=_0x1e2886;logger[_0x37f63f('0x9')]('CreateMailMessage',_0x2133fa[_0x37f63f('0xd')],_0x246d28),_0x324976(_0x37f91d[_0x37f63f('0x9')](0x1f4,_0x2133fa[_0x37f63f('0xd')]));});});}; \ No newline at end of file +const a416_0x1d24=['rpc','then','message','stringify','error','options','register','../../rediscache','raw','create','CreateMailMessage','body'];(function(_0x5882a7,_0x1d240b){const _0x1b9ac4=function(_0x1d9b33){while(--_0x1d9b33){_0x5882a7['push'](_0x5882a7['shift']());}};_0x1b9ac4(++_0x1d240b);}(a416_0x1d24,0x9c));const a416_0x1b9a=function(_0x5882a7,_0x1d240b){_0x5882a7=_0x5882a7-0x0;let _0x1b9ac4=a416_0x1d24[_0x5882a7];return _0x1b9ac4;};const _0x1b2ab0=a416_0x1b9a;'use strict';const db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x1b2ab0('0x0')),{getSocket}=require(_0x1b2ab0('0x7')),socket=getSocket();require('./mailMessage.socket')[_0x1b2ab0('0x6')](socket),exports['CreateMailMessage']=function(_0x1d9b33){const _0x18dc3f=this;return new Promise(function(_0x58a612,_0x35f1e0){const _0x1bac3d=a416_0x1b9a;return db['MailMessage'][_0x1bac3d('0x9')](_0x1d9b33[_0x1bac3d('0xb')],{'raw':_0x1d9b33[_0x1bac3d('0x5')]?_0x1d9b33[_0x1bac3d('0x5')][_0x1bac3d('0x8')]===undefined?!![]:![]:!![]})[_0x1bac3d('0x1')](function(_0x32d696){const _0x1cbf87=_0x1bac3d;logger['info'](_0x1cbf87('0xa'),_0x1d9b33),logger['debug'](_0x1cbf87('0xa'),_0x1d9b33,JSON[_0x1cbf87('0x3')](_0x32d696)),_0x58a612(_0x32d696);})['catch'](function(_0x22d0cf){const _0x4f87b0=_0x1bac3d;logger[_0x4f87b0('0x4')](_0x4f87b0('0xa'),_0x22d0cf[_0x4f87b0('0x2')],_0x1d9b33),_0x35f1e0(_0x18dc3f[_0x4f87b0('0x4')](0x1f4,_0x22d0cf[_0x4f87b0('0x2')]));});});}; \ No newline at end of file diff --git a/server/api/mailMessage/mailMessage.socket.js b/server/api/mailMessage/mailMessage.socket.js index ae854aa..6abe197 100644 --- a/server/api/mailMessage/mailMessage.socket.js +++ b/server/api/mailMessage/mailMessage.socket.js @@ -1 +1 @@ -const a417_0x1136=['length','remove','update','mailMessage:','register','./mailMessage.events','emit'];(function(_0x5b00fa,_0x1136be){const _0x567e10=function(_0x26f256){while(--_0x26f256){_0x5b00fa['push'](_0x5b00fa['shift']());}};_0x567e10(++_0x1136be);}(a417_0x1136,0x178));const a417_0x567e=function(_0x5b00fa,_0x1136be){_0x5b00fa=_0x5b00fa-0x0;let _0x567e10=a417_0x1136[_0x5b00fa];return _0x567e10;};const _0x3be19a=a417_0x567e;'use strict';const MailMessageEvents=require(_0x3be19a('0x0')),events=['save',_0x3be19a('0x3'),_0x3be19a('0x4')];function createListener(_0x26f256,_0x2b62f6){return function(_0x3d1c56){const _0xd5ef69=a417_0x567e;_0x2b62f6[_0xd5ef69('0x1')](_0x26f256,_0x3d1c56);};}exports[_0x3be19a('0x6')]=function(_0x38199a){const _0x3ff6db=_0x3be19a;for(let _0x55baea=0x0,_0x330b67=events[_0x3ff6db('0x2')];_0x55baea<_0x330b67;_0x55baea++){const _0x24923f=events[_0x55baea],_0x58f4e0=createListener(_0x3ff6db('0x5')+_0x24923f,_0x38199a);MailMessageEvents['on'](_0x24923f,_0x58f4e0);}}; \ No newline at end of file +const a417_0xcc48=['mailMessage:','remove','register','save','./mailMessage.events','length','update','emit'];(function(_0x551128,_0xcc4822){const _0x4a7df6=function(_0x578bbb){while(--_0x578bbb){_0x551128['push'](_0x551128['shift']());}};_0x4a7df6(++_0xcc4822);}(a417_0xcc48,0x183));const a417_0x4a7d=function(_0x551128,_0xcc4822){_0x551128=_0x551128-0x0;let _0x4a7df6=a417_0xcc48[_0x551128];return _0x4a7df6;};const _0x162a67=a417_0x4a7d;'use strict';const MailMessageEvents=require(_0x162a67('0x1')),events=[_0x162a67('0x0'),_0x162a67('0x6'),_0x162a67('0x3')];function createListener(_0x578bbb,_0x4b4390){return function(_0x163497){const _0x28e683=a417_0x4a7d;_0x4b4390[_0x28e683('0x4')](_0x578bbb,_0x163497);};}exports[_0x162a67('0x7')]=function(_0x14e019){const _0x2738d3=_0x162a67;for(let _0x2949b4=0x0,_0x18ea6d=events[_0x2738d3('0x2')];_0x2949b4<_0x18ea6d;_0x2949b4++){const _0x22d3be=events[_0x2949b4],_0x54bf99=createListener(_0x2738d3('0x5')+_0x22d3be,_0x14e019);MailMessageEvents['on'](_0x22d3be,_0x54bf99);}}; \ No newline at end of file diff --git a/server/api/mailQueue/index.js b/server/api/mailQueue/index.js index 14c37ea..b211706 100644 --- a/server/api/mailQueue/index.js +++ b/server/api/mailQueue/index.js @@ -1 +1 @@ -const a418_0x2eed=['removeAgents','get','/describe','create','/:id/teams','describe','put','/:id/members','getAgents','delete','./mailQueue.controller','getTeams','/:id','update','removeTeams','isAuthenticated','Router','../../components/auth/service','addTeams','/:id/users','destroy','post','addAgents','show','exports'];(function(_0x27ff2c,_0x2eed67){const _0x3174b8=function(_0x47e506){while(--_0x47e506){_0x27ff2c['push'](_0x27ff2c['shift']());}};_0x3174b8(++_0x2eed67);}(a418_0x2eed,0x175));const a418_0x3174=function(_0x27ff2c,_0x2eed67){_0x27ff2c=_0x27ff2c-0x0;let _0x3174b8=a418_0x2eed[_0x27ff2c];return _0x3174b8;};const _0x4984f9=a418_0x3174;'use strict';const express=require('express'),router=express[_0x4984f9('0x12')](),auth=require(_0x4984f9('0x13')),controller=require(_0x4984f9('0xc'));router['get']('/',auth[_0x4984f9('0x11')](),controller['index']),router[_0x4984f9('0x3')](_0x4984f9('0x4'),auth[_0x4984f9('0x11')](),controller[_0x4984f9('0x7')]),router[_0x4984f9('0x3')](_0x4984f9('0xe'),auth[_0x4984f9('0x11')](),controller[_0x4984f9('0x0')]),router[_0x4984f9('0x3')](_0x4984f9('0x9'),auth[_0x4984f9('0x11')](),controller['getMembers']),router[_0x4984f9('0x3')](_0x4984f9('0x6'),auth['isAuthenticated'](),controller[_0x4984f9('0xd')]),router[_0x4984f9('0x3')](_0x4984f9('0x15'),auth['isAuthenticated'](),controller[_0x4984f9('0xa')]),router[_0x4984f9('0x17')]('/',auth[_0x4984f9('0x11')](),controller[_0x4984f9('0x5')]),router[_0x4984f9('0x17')](_0x4984f9('0x6'),auth[_0x4984f9('0x11')](),controller[_0x4984f9('0x14')]),router[_0x4984f9('0x17')]('/:id/users',auth[_0x4984f9('0x11')](),controller[_0x4984f9('0x18')]),router[_0x4984f9('0x8')]('/:id',auth[_0x4984f9('0x11')](),controller[_0x4984f9('0xf')]),router[_0x4984f9('0xb')](_0x4984f9('0xe'),auth['isAuthenticated'](),controller[_0x4984f9('0x16')]),router[_0x4984f9('0xb')](_0x4984f9('0x6'),auth[_0x4984f9('0x11')](),controller[_0x4984f9('0x10')]),router[_0x4984f9('0xb')]('/:id/users',auth[_0x4984f9('0x11')](),controller[_0x4984f9('0x2')]),module[_0x4984f9('0x1')]=router; \ No newline at end of file +const a418_0x467b=['express','../../components/auth/service','Router','update','describe','put','removeTeams','/:id/members','/:id','post','destroy','delete','get','isAuthenticated','getTeams','show','getMembers','/:id/teams','/:id/users','index','./mailQueue.controller','addAgents'];(function(_0x4d192b,_0x467b85){const _0x18007e=function(_0x744f37){while(--_0x744f37){_0x4d192b['push'](_0x4d192b['shift']());}};_0x18007e(++_0x467b85);}(a418_0x467b,0x7d));const a418_0x1800=function(_0x4d192b,_0x467b85){_0x4d192b=_0x4d192b-0x0;let _0x18007e=a418_0x467b[_0x4d192b];return _0x18007e;};const _0x5c0a92=a418_0x1800;'use strict';const express=require(_0x5c0a92('0x7')),router=express[_0x5c0a92('0x9')](),auth=require(_0x5c0a92('0x8')),controller=require(_0x5c0a92('0x5'));router['get']('/',auth[_0x5c0a92('0x14')](),controller[_0x5c0a92('0x4')]),router[_0x5c0a92('0x13')]('/describe',auth[_0x5c0a92('0x14')](),controller[_0x5c0a92('0xb')]),router[_0x5c0a92('0x13')]('/:id',auth['isAuthenticated'](),controller[_0x5c0a92('0x0')]),router[_0x5c0a92('0x13')](_0x5c0a92('0xe'),auth[_0x5c0a92('0x14')](),controller[_0x5c0a92('0x1')]),router[_0x5c0a92('0x13')](_0x5c0a92('0x2'),auth[_0x5c0a92('0x14')](),controller[_0x5c0a92('0x15')]),router[_0x5c0a92('0x13')](_0x5c0a92('0x3'),auth[_0x5c0a92('0x14')](),controller['getAgents']),router[_0x5c0a92('0x10')]('/',auth[_0x5c0a92('0x14')](),controller['create']),router[_0x5c0a92('0x10')](_0x5c0a92('0x2'),auth[_0x5c0a92('0x14')](),controller['addTeams']),router[_0x5c0a92('0x10')]('/:id/users',auth[_0x5c0a92('0x14')](),controller[_0x5c0a92('0x6')]),router[_0x5c0a92('0xc')](_0x5c0a92('0xf'),auth[_0x5c0a92('0x14')](),controller[_0x5c0a92('0xa')]),router[_0x5c0a92('0x12')](_0x5c0a92('0xf'),auth[_0x5c0a92('0x14')](),controller[_0x5c0a92('0x11')]),router['delete'](_0x5c0a92('0x2'),auth[_0x5c0a92('0x14')](),controller[_0x5c0a92('0xd')]),router[_0x5c0a92('0x12')](_0x5c0a92('0x3'),auth['isAuthenticated'](),controller['removeAgents']),module['exports']=router; \ No newline at end of file diff --git a/server/api/mailQueue/mailQueue.attributes.js b/server/api/mailQueue/mailQueue.attributes.js index 406cff8..88b3c5a 100644 --- a/server/api/mailQueue/mailQueue.attributes.js +++ b/server/api/mailQueue/mailQueue.attributes.js @@ -1 +1 @@ -const a419_0x12b5=['exports','beepall','INTEGER','roundrobin','ENUM'];(function(_0x1241a7,_0x12b5b4){const _0x190f7c=function(_0x503fa7){while(--_0x503fa7){_0x1241a7['push'](_0x1241a7['shift']());}};_0x190f7c(++_0x12b5b4);}(a419_0x12b5,0x15a));const a419_0x190f=function(_0x1241a7,_0x12b5b4){_0x1241a7=_0x1241a7-0x0;let _0x190f7c=a419_0x12b5[_0x1241a7];return _0x190f7c;};const _0x321e13=a419_0x190f;'use strict';const Sequelize=require('sequelize');module[_0x321e13('0x4')]={'name':{'type':Sequelize['STRING'],'unique':'name','validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize['STRING']},'timeout':{'type':Sequelize[_0x321e13('0x1')],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x321e13('0x3')]('rrmemory',_0x321e13('0x0'),_0x321e13('0x2'))}}; \ No newline at end of file +const a419_0x144c=['INTEGER','ENUM','STRING','name','sequelize','rrmemory','beepall','exports'];(function(_0x522db5,_0x144cee){const _0x24cab3=function(_0x3d73b0){while(--_0x3d73b0){_0x522db5['push'](_0x522db5['shift']());}};_0x24cab3(++_0x144cee);}(a419_0x144c,0x12a));const a419_0x24ca=function(_0x522db5,_0x144cee){_0x522db5=_0x522db5-0x0;let _0x24cab3=a419_0x144c[_0x522db5];return _0x24cab3;};const _0x1bf0c7=a419_0x24ca;'use strict';const Sequelize=require(_0x1bf0c7('0x2'));module[_0x1bf0c7('0x5')]={'name':{'type':Sequelize[_0x1bf0c7('0x0')],'unique':_0x1bf0c7('0x1'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize[_0x1bf0c7('0x0')]},'timeout':{'type':Sequelize[_0x1bf0c7('0x6')],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x1bf0c7('0x7')](_0x1bf0c7('0x3'),_0x1bf0c7('0x4'),'roundrobin')}}; \ No newline at end of file diff --git a/server/api/mailQueue/mailQueue.controller.js b/server/api/mailQueue/mailQueue.controller.js index 9c31460..58f27ed 100644 --- a/server/api/mailQueue/mailQueue.controller.js +++ b/server/api/mailQueue/mailQueue.controller.js @@ -1 +1 @@ -const a420_0x3322=['all','SIP','index','key','send','./mailQueue.socket','isEmpty','api','filter','UserProfileResource','%s/%s','Team','Content-Range','query','type','error','ids','createdAt','MailQueueId\x20=\x20?','MailQueueId','ut.TeamId\x20=\x20tq.TeamId','map','format','each','stack','fields','fieldName','order','intersection','../../config/logger','includeAll','agent','findAndCountAll','addTeams','team_has_mail_queues','rows','includes','update','sort','sequelize','userMailQueue:remove','TeamId','join','status','removeTeams','role','sendStatus','SELECT','value','attributes','User','mailPause','online','register','UserProfileSection','userMailQueue:save','../../components/parsers/qs','nolimit','voicePause','squel','VIRTUAL','field','util','getMembers','keys','length','get','options','user_has_teams','rawAttributes','../../rediscache','count','MailQueues','merge','forEach','undefined','clone','destroy','getAgents','UserMailQueue','end','push','params','Unable\x20to\x20retrieve\x20the\x20current\x20user','userProfileId','limit','updatedAt','every','MailQueue','name','pick','model','union','body','addAgents','transaction','catch','../../mysqldb','emit','tq.TeamId','describe','user','then','json','Agents','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','offset','getTeams','where','filters','create','interface','findAll','findOne','from','like','include','removeAgents'];(function(_0x149221,_0x3322ac){const _0x32d6e6=function(_0x20aafb){while(--_0x20aafb){_0x149221['push'](_0x149221['shift']());}};_0x32d6e6(++_0x3322ac);}(a420_0x3322,0x164));const a420_0x32d6=function(_0x149221,_0x3322ac){_0x149221=_0x149221-0x0;let _0x32d6e6=a420_0x3322[_0x149221];return _0x32d6e6;};const _0x50dda0=a420_0x32d6;'use strict';const util=require(_0x50dda0('0x3c')),_=require('lodash'),squel=require(_0x50dda0('0x39')),qs=require(_0x50dda0('0x36')),logger=require(_0x50dda0('0x1b'))(_0x50dda0('0x5')),{getSocket}=require(_0x50dda0('0x44')),socket=getSocket(),db=require(_0x50dda0('0x5f'))['db'],{Op,QueryTypes}=require(_0x50dda0('0x25'));require(_0x50dda0('0x3'))[_0x50dda0('0x33')](socket);function respondWithStatusCode(_0x20aafb,_0x69f137){return _0x69f137=_0x69f137||0xcc,function(_0x4e529b){const _0x5aeeef=a420_0x32d6;if(_0x4e529b)return _0x20aafb[_0x5aeeef('0x2c')](_0x69f137);return _0x20aafb[_0x5aeeef('0x29')](_0x69f137)['end']();};}function respondWithResult(_0x66466a,_0x541af1){return _0x541af1=_0x541af1||0xc8,function(_0x579941){const _0x1eecbf=a420_0x32d6;if(_0x579941)return _0x66466a[_0x1eecbf('0x29')](_0x541af1)['json'](_0x579941);};}function respondWithFilteredResult(_0x505ef9,_0x3a7184){return function(_0x3a74b2){const _0x50b6a1=a420_0x32d6;if(_0x3a74b2){const _0x19b1aa=_0x3a74b2['count'],_0x3e30d7=_0x3a7184[_0x50b6a1('0x68')];let _0x3b6841=_0x3a7184['offset']+_0x3a7184[_0x50b6a1('0x53')],_0x393f22;return _0x3b6841>=_0x19b1aa?(_0x3b6841=_0x19b1aa,_0x393f22=0xc8):_0x393f22=0xce,_0x505ef9[_0x50b6a1('0x29')](_0x393f22),_0x505ef9['set'](_0x50b6a1('0xa'),_0x3e30d7+'-'+_0x3b6841+'/'+_0x19b1aa)[_0x50b6a1('0x65')](_0x3a74b2);}return null;};}function saveUpdates(_0x54f867){return function(_0x3db91d){const _0x1afbdd=a420_0x32d6;if(_0x3db91d)return _0x3db91d[_0x1afbdd('0x23')](_0x54f867)[_0x1afbdd('0x64')](function(_0x1aaf8d){return _0x1aaf8d;});return null;};}function removeEntity(_0x4f8b9e){return function(_0x127f85){const _0x397fa3=a420_0x32d6;if(_0x127f85)return _0x127f85[_0x397fa3('0x4b')]()[_0x397fa3('0x64')](function(){const _0x373c03=_0x397fa3,_0x1c1534=_0x127f85[_0x373c03('0x40')]({'plain':!![]}),_0x2de757=_0x373c03('0x46');return db[_0x373c03('0x7')]['destroy']({'where':{'type':_0x2de757,'resourceId':_0x1c1534['id']}})['then'](function(){return _0x127f85;});})[_0x397fa3('0x64')](function(){const _0x481176=_0x397fa3;_0x4f8b9e[_0x481176('0x29')](0xcc)[_0x481176('0x4e')]();});};}function handleEntityNotFound(_0x197676){return function(_0x7a274b){const _0x3187ac=a420_0x32d6;return!_0x7a274b&&_0x197676[_0x3187ac('0x2c')](0x194),_0x7a274b;};}function handleError(_0x1c6e6c,_0x55bbce){return _0x55bbce=_0x55bbce||0x1f4,function(_0x35a836){const _0x24b78d=a420_0x32d6;logger[_0x24b78d('0xd')](_0x35a836[_0x24b78d('0x16')]),_0x35a836['name']&&delete _0x35a836[_0x24b78d('0x57')],_0x1c6e6c['status'](_0x55bbce)[_0x24b78d('0x2')](_0x35a836);};}exports[_0x50dda0('0x0')]=function(_0x5343cf,_0x3e8b91){const _0x4b4898=_0x50dda0;let _0x50d84c={};const _0x24785d={},_0x10a749={'count':0x0,'rows':[]},_0x2cd658=_[_0x4b4898('0x13')](db[_0x4b4898('0x56')]['rawAttributes'],function(_0x1f20fe){const _0x21c726=_0x4b4898;return{'name':_0x1f20fe[_0x21c726('0x18')],'type':_0x1f20fe[_0x21c726('0xc')][_0x21c726('0x1')]};});_0x24785d[_0x4b4898('0x59')]=_[_0x4b4898('0x13')](_0x2cd658,_0x4b4898('0x57')),_0x24785d[_0x4b4898('0xb')]=_[_0x4b4898('0x3e')](_0x5343cf[_0x4b4898('0xb')]),_0x24785d[_0x4b4898('0x6b')]=_[_0x4b4898('0x1a')](_0x24785d[_0x4b4898('0x59')],_0x24785d[_0x4b4898('0xb')]),_0x50d84c[_0x4b4898('0x2f')]=_[_0x4b4898('0x1a')](_0x24785d['model'],qs[_0x4b4898('0x17')](_0x5343cf[_0x4b4898('0xb')]['fields'])),_0x50d84c['attributes']=_0x50d84c[_0x4b4898('0x2f')][_0x4b4898('0x3f')]?_0x50d84c[_0x4b4898('0x2f')]:_0x24785d[_0x4b4898('0x59')];typeof _0x5343cf[_0x4b4898('0xb')][_0x4b4898('0x37')]==='undefined'&&(_0x50d84c[_0x4b4898('0x53')]=qs[_0x4b4898('0x53')](_0x5343cf[_0x4b4898('0xb')][_0x4b4898('0x53')]),_0x50d84c[_0x4b4898('0x68')]=qs['offset'](_0x5343cf[_0x4b4898('0xb')][_0x4b4898('0x68')]));_0x50d84c[_0x4b4898('0x19')]=qs[_0x4b4898('0x24')](_0x5343cf[_0x4b4898('0xb')][_0x4b4898('0x24')]),_0x50d84c[_0x4b4898('0x6a')]=qs[_0x4b4898('0x6b')](_[_0x4b4898('0x58')](_0x5343cf[_0x4b4898('0xb')],_0x24785d[_0x4b4898('0x6b')]),_0x2cd658);_0x5343cf[_0x4b4898('0xb')][_0x4b4898('0x6')]&&(_0x50d84c[_0x4b4898('0x6a')]=_[_0x4b4898('0x47')](_0x50d84c[_0x4b4898('0x6a')],{[Op['or']]:_[_0x4b4898('0x13')](_0x2cd658,function(_0x50005d){const _0x727954=_0x4b4898;if(_0x50005d[_0x727954('0xc')]!==_0x727954('0x3a')){const _0x5f53da={};return _0x5f53da[_0x50005d[_0x727954('0x57')]]={[Op[_0x727954('0x71')]]:'%'+_0x5343cf[_0x727954('0xb')][_0x727954('0x6')]+'%'},_0x5f53da;}})}));_0x50d84c=_[_0x4b4898('0x47')]({},_0x50d84c,_0x5343cf[_0x4b4898('0x41')]);const _0x5ac441={'where':_0x50d84c[_0x4b4898('0x6a')]};return db['MailQueue'][_0x4b4898('0x45')](_0x5ac441)[_0x4b4898('0x64')](function(_0x2f1f13){const _0x234b32=_0x4b4898;return _0x10a749[_0x234b32('0x45')]=_0x2f1f13,_0x5343cf[_0x234b32('0xb')][_0x234b32('0x1c')]&&(_0x50d84c['include']=[{'all':!![]}]),db[_0x234b32('0x56')][_0x234b32('0x6e')](_0x50d84c);})['then'](function(_0x5b38e2){const _0x381486=_0x4b4898;return _0x10a749[_0x381486('0x21')]=_0x5b38e2,_0x10a749;})['then'](respondWithFilteredResult(_0x3e8b91,_0x50d84c))[_0x4b4898('0x5e')](handleError(_0x3e8b91,null));},exports['show']=function(_0x533f1c,_0x19660d){const _0x11d724=_0x50dda0;let _0x1578fd={'raw':!![],'where':{'id':_0x533f1c[_0x11d724('0x50')]['id']}};const _0x5790aa={};return _0x5790aa[_0x11d724('0x59')]=_[_0x11d724('0x3e')](db[_0x11d724('0x56')][_0x11d724('0x43')]),_0x5790aa[_0x11d724('0xb')]=_[_0x11d724('0x3e')](_0x533f1c[_0x11d724('0xb')]),_0x5790aa[_0x11d724('0x6b')]=_['intersection'](_0x5790aa['model'],_0x5790aa[_0x11d724('0xb')]),_0x1578fd[_0x11d724('0x2f')]=_[_0x11d724('0x1a')](_0x5790aa[_0x11d724('0x59')],qs['fields'](_0x533f1c[_0x11d724('0xb')][_0x11d724('0x17')])),_0x1578fd['attributes']=_0x1578fd[_0x11d724('0x2f')][_0x11d724('0x3f')]?_0x1578fd[_0x11d724('0x2f')]:_0x5790aa['model'],_0x533f1c[_0x11d724('0xb')]['includeAll']&&(_0x1578fd[_0x11d724('0x72')]=[{'all':!![]}]),_0x1578fd=_['merge']({},_0x1578fd,_0x533f1c[_0x11d724('0x41')]),db[_0x11d724('0x56')][_0x11d724('0x6f')](_0x1578fd)[_0x11d724('0x64')](handleEntityNotFound(_0x19660d,null))[_0x11d724('0x64')](respondWithResult(_0x19660d,null))[_0x11d724('0x5e')](handleError(_0x19660d,null));},exports[_0x50dda0('0x6c')]=function(_0x32f52b,_0x340f03){const _0x3819b5=_0x50dda0;return db[_0x3819b5('0x56')][_0x3819b5('0x6c')](_0x32f52b['body'],{})[_0x3819b5('0x64')](function(_0x58d6e7){const _0x407346=_0x3819b5,_0x379a1f=_0x32f52b[_0x407346('0x63')][_0x407346('0x40')]({'plain':!![]});if(!_0x379a1f)throw new Error(_0x407346('0x51'));if(_0x379a1f[_0x407346('0x2b')]===_0x407346('0x63')){const _0x487e44=_0x58d6e7[_0x407346('0x40')]({'plain':!![]}),_0x3d357e='MailQueues';return db[_0x407346('0x34')][_0x407346('0x6f')]({'where':{'name':_0x3d357e,'userProfileId':_0x379a1f[_0x407346('0x52')]},'raw':!![]})['then'](function(_0x129ff6){const _0x3b8d8c=_0x407346;return _0x129ff6&&_0x129ff6['autoAssociation']===0x0?db[_0x3b8d8c('0x7')]['create']({'name':_0x487e44[_0x3b8d8c('0x57')],'resourceId':_0x487e44['id'],'type':_0x129ff6['name'],'sectionId':_0x129ff6['id']},{})['then'](function(){return _0x58d6e7;}):_0x58d6e7;})['catch'](function(_0x29147f){const _0x227a4f=_0x407346;logger[_0x227a4f('0xd')](_0x227a4f('0x67'),_0x29147f);throw _0x29147f;});}return _0x58d6e7;})[_0x3819b5('0x64')](respondWithResult(_0x340f03,0xc9))[_0x3819b5('0x5e')](handleError(_0x340f03,null));},exports['update']=function(_0x29a059,_0x1ad4a9){const _0x39177b=_0x50dda0;return _0x29a059['body']['id']&&delete _0x29a059[_0x39177b('0x5b')]['id'],db['MailQueue'][_0x39177b('0x6f')]({'where':{'id':_0x29a059[_0x39177b('0x50')]['id']}})[_0x39177b('0x64')](handleEntityNotFound(_0x1ad4a9,null))[_0x39177b('0x64')](saveUpdates(_0x29a059[_0x39177b('0x5b')],null))[_0x39177b('0x64')](respondWithResult(_0x1ad4a9,null))[_0x39177b('0x5e')](handleError(_0x1ad4a9,null));},exports[_0x50dda0('0x4b')]=function(_0x5b5a50,_0x34fb61){const _0x24d4d0=_0x50dda0;return db[_0x24d4d0('0x56')]['findOne']({'where':{'id':_0x5b5a50[_0x24d4d0('0x50')]['id']}})[_0x24d4d0('0x64')](handleEntityNotFound(_0x34fb61,null))[_0x24d4d0('0x64')](removeEntity(_0x34fb61,null))[_0x24d4d0('0x5e')](handleError(_0x34fb61,null));},exports['describe']=function(_0x3d11b1,_0x15fe4d){const _0x2bf9bc=_0x50dda0;return db[_0x2bf9bc('0x56')][_0x2bf9bc('0x62')]()[_0x2bf9bc('0x64')](respondWithResult(_0x15fe4d,null))['catch'](handleError(_0x15fe4d,null));},exports[_0x50dda0('0x3d')]=function(_0x1f3b99,_0x51fac1){const _0x2a5e1e=_0x50dda0;let _0x2d69f3={'raw':!![],'where':{}};const _0xde55={};let _0xc3df8c;return db['MailQueue']['findOne']({'where':{'id':_0x1f3b99['params']['id']}})[_0x2a5e1e('0x64')](handleEntityNotFound(_0x51fac1,null))[_0x2a5e1e('0x64')](function(_0x5d6b7e){const _0x113bbe=_0x2a5e1e;if(_0x5d6b7e)return _0xc3df8c=_0x5d6b7e[_0x113bbe('0x40')]({'plain':!![]}),_0xde55[_0x113bbe('0x59')]=_[_0x113bbe('0x3e')](db[_0x113bbe('0x4d')][_0x113bbe('0x43')]),_0xde55['query']=_[_0x113bbe('0x3e')](_0x1f3b99[_0x113bbe('0xb')]),_0xde55[_0x113bbe('0x6b')]=_[_0x113bbe('0x1a')](_0xde55['model'],_0xde55[_0x113bbe('0xb')]),_0x2d69f3[_0x113bbe('0x2f')]=_[_0x113bbe('0x1a')](_0xde55[_0x113bbe('0x59')],qs[_0x113bbe('0x17')](_0x1f3b99[_0x113bbe('0xb')]['fields'])),_0x2d69f3['attributes']=_0x2d69f3[_0x113bbe('0x2f')][_0x113bbe('0x3f')]?_0x2d69f3[_0x113bbe('0x2f')]:_0xde55[_0x113bbe('0x59')],typeof _0x1f3b99[_0x113bbe('0xb')]['nolimit']==='undefined'&&(_0x2d69f3[_0x113bbe('0x53')]=qs['limit'](_0x1f3b99['query']['limit']),_0x2d69f3[_0x113bbe('0x68')]=qs[_0x113bbe('0x68')](_0x1f3b99['query'][_0x113bbe('0x68')])),_0x2d69f3['order']=qs['sort'](_0x1f3b99[_0x113bbe('0xb')]['sort']),_0x2d69f3[_0x113bbe('0x6a')]=qs[_0x113bbe('0x6b')](_[_0x113bbe('0x58')](_0x1f3b99[_0x113bbe('0xb')],_0xde55[_0x113bbe('0x6b')])),_0x2d69f3[_0x113bbe('0x6a')][_0x113bbe('0x11')]=_0x5d6b7e['id'],_0x1f3b99[_0x113bbe('0xb')][_0x113bbe('0x6')]&&(_0x2d69f3[_0x113bbe('0x6a')]=_[_0x113bbe('0x47')](_0x2d69f3[_0x113bbe('0x6a')],{[Op['or']]:_[_0x113bbe('0x13')](_0x2d69f3[_0x113bbe('0x2f')],function(_0x57f776){const _0x4a9b82=_0x113bbe,_0x4f0114={};return _0x4f0114[_0x57f776]={[Op[_0x4a9b82('0x71')]]:'%'+_0x1f3b99[_0x4a9b82('0xb')][_0x4a9b82('0x6')]+'%'},_0x4f0114;})})),_0x2d69f3=_[_0x113bbe('0x47')]({},_0x2d69f3,_0x1f3b99[_0x113bbe('0x41')]),db[_0x113bbe('0x4d')]['findAll'](_0x2d69f3);})['then'](function(_0x1365ad){const _0x25c6dd=_0x2a5e1e;if(_0x1365ad)return db[_0x25c6dd('0x30')][_0x25c6dd('0x1e')]({'where':{'id':_['map'](_0x1365ad,'UserId'),'role':_0x25c6dd('0x1d')},'attributes':['id',_0x25c6dd('0x57'),_0x25c6dd('0x31'),_0x25c6dd('0x54'),_0x25c6dd('0xf')]});})['then'](function(_0x3dee1c){const _0xb51451=_0x2a5e1e;return _0x3dee1c?{'count':_0x3dee1c[_0xb51451('0x45')],'rows':_[_0xb51451('0x13')](_0x3dee1c[_0xb51451('0x21')],function(_0x48fb20){const _0x1514aa=_0xb51451;return{'membername':_0x48fb20[_0x1514aa('0x57')],'UserId':_0x48fb20['id'],'queue_name':_0xc3df8c[_0x1514aa('0x57')],'MailQueueId':_0xc3df8c['id'],'interface':util[_0x1514aa('0x14')](_0x1514aa('0x8'),_0x1514aa('0x75'),_0x48fb20['name']),'penalty':0x0,'paused':_0x48fb20['mailPause'],'createdAt':_0x48fb20[_0x1514aa('0xf')],'updatedAt':_0x48fb20[_0x1514aa('0x54')]};})}:{'count':0x0,'rows':[]};})[_0x2a5e1e('0x64')](respondWithFilteredResult(_0x51fac1,_0x2d69f3))[_0x2a5e1e('0x5e')](handleError(_0x51fac1,null));},exports[_0x50dda0('0x69')]=function(_0x531256,_0x22b2ba){const _0x237c3e=_0x50dda0;let _0x276d61={};const _0x3f2b8c={};let _0x1a7444,_0x32a80e;return db[_0x237c3e('0x56')]['findOne']({'where':{'id':_0x531256[_0x237c3e('0x50')]['id']}})[_0x237c3e('0x64')](handleEntityNotFound(_0x22b2ba,null))[_0x237c3e('0x64')](function(_0x3ec9bb){const _0x3dc116=_0x237c3e;if(_0x3ec9bb)return _0x1a7444=_0x3ec9bb,_0x3f2b8c[_0x3dc116('0x59')]=_[_0x3dc116('0x3e')](db[_0x3dc116('0x9')][_0x3dc116('0x43')]),_0x3f2b8c[_0x3dc116('0xb')]=_[_0x3dc116('0x3e')](_0x531256[_0x3dc116('0xb')]),_0x3f2b8c[_0x3dc116('0x6b')]=_[_0x3dc116('0x1a')](_0x3f2b8c[_0x3dc116('0x59')],_0x3f2b8c[_0x3dc116('0xb')]),_0x276d61['attributes']=_[_0x3dc116('0x1a')](_0x3f2b8c[_0x3dc116('0x59')],qs[_0x3dc116('0x17')](_0x531256[_0x3dc116('0xb')]['fields'])),_0x276d61[_0x3dc116('0x2f')]=_0x276d61[_0x3dc116('0x2f')]['length']?_0x276d61['attributes']:_0x3f2b8c[_0x3dc116('0x59')],_0x276d61['order']=qs[_0x3dc116('0x24')](_0x531256[_0x3dc116('0xb')][_0x3dc116('0x24')]),_0x276d61['where']=qs[_0x3dc116('0x6b')](_[_0x3dc116('0x58')](_0x531256[_0x3dc116('0xb')],_0x3f2b8c[_0x3dc116('0x6b')])),_0x531256[_0x3dc116('0xb')][_0x3dc116('0x6')]&&(_0x276d61[_0x3dc116('0x6a')]=_[_0x3dc116('0x47')](_0x276d61[_0x3dc116('0x6a')],{[Op['or']]:_[_0x3dc116('0x13')](_0x276d61[_0x3dc116('0x2f')],function(_0x38b9b4){const _0x272c84=_0x3dc116,_0x4f4fe1={};return _0x4f4fe1[_0x38b9b4]={[Op[_0x272c84('0x71')]]:'%'+_0x531256[_0x272c84('0xb')][_0x272c84('0x6')]+'%'},_0x4f4fe1;})})),_0x276d61=_[_0x3dc116('0x47')]({},_0x276d61,_0x531256[_0x3dc116('0x41')]),_0x1a7444[_0x3dc116('0x69')](_0x276d61);})['then'](function(_0xa8c1f1){const _0x410479=_0x237c3e;if(_0xa8c1f1)return _0x32a80e=_0xa8c1f1[_0x410479('0x3f')],typeof _0x531256['query']['nolimit']==='undefined'&&(_0x276d61[_0x410479('0x53')]=qs[_0x410479('0x53')](_0x531256[_0x410479('0xb')]['limit']),_0x276d61[_0x410479('0x68')]=qs[_0x410479('0x68')](_0x531256[_0x410479('0xb')][_0x410479('0x68')])),_0x1a7444[_0x410479('0x69')](_0x276d61);})[_0x237c3e('0x64')](function(_0x389cd4){if(_0x389cd4)return _0x389cd4?{'count':_0x32a80e,'rows':_0x389cd4}:null;})[_0x237c3e('0x64')](respondWithResult(_0x22b2ba,null))['catch'](handleError(_0x22b2ba,null));},exports[_0x50dda0('0x1f')]=function(_0x11ff66,_0x4dedc8){const _0x53ed20=_0x50dda0,_0x2cbc6a=_0x11ff66[_0x53ed20('0x5b')][_0x53ed20('0xe')];return db[_0x53ed20('0x9')]['findAll']({'where':{'id':_0x2cbc6a},'attributes':['id'],'include':[{'model':db[_0x53ed20('0x30')],'as':_0x53ed20('0x66'),'attributes':['id',_0x53ed20('0x57'),_0x53ed20('0x32'),_0x53ed20('0x38'),_0x53ed20('0x6d')],'raw':!![]}]})[_0x53ed20('0x64')](function(_0x5d4f82){const _0x1c4c2a=_0x53ed20;if(_0x5d4f82){const _0x36c54a=_['flatMap'](_0x5d4f82,function(_0x2a5b2a){const _0x294a0c=a420_0x32d6,_0x53d96c=_0x2a5b2a['get']({'plain':!![]});return _0x53d96c[_0x294a0c('0x66')];});return db[_0x1c4c2a('0x56')]['findOne']({'where':{'id':_0x11ff66[_0x1c4c2a('0x50')]['id']}})['then'](function(_0x32ea9d){const _0x37f5fa=_0x1c4c2a;return db[_0x37f5fa('0x25')][_0x37f5fa('0x5d')](function(_0x2bd5dc){const _0x66e287=_0x37f5fa;return _0x32ea9d[_0x66e287('0x1f')](_0x2cbc6a,{'transaction':_0x2bd5dc})[_0x66e287('0x64')](function(){const _0xb07dc6=_0x66e287;return Promise[_0xb07dc6('0x15')](_0x36c54a,function(_0x243bd1){const _0x18f896=_0xb07dc6;return db[_0x18f896('0x4d')]['findOrCreate']({'where':{'UserId':_0x243bd1['id'],'MailQueueId':_0x11ff66['params']['id']},'transaction':_0x2bd5dc});});})['then'](function(){const _0x13c0e7=_0x66e287;_0x36c54a[_0x13c0e7('0x48')](function(_0x43968b){const _0x1e3022=_0x13c0e7;socket[_0x1e3022('0x60')]('userMailQueue:save',{'UserId':_0x43968b['id'],'MailQueueId':_0x32ea9d['id']});});});});});}})[_0x53ed20('0x64')](respondWithStatusCode(_0x4dedc8,null))[_0x53ed20('0x5e')](handleError(_0x4dedc8,null));},exports[_0x50dda0('0x2a')]=function(_0x405422,_0x2ad9cc){const _0x12736b=_0x50dda0;return db[_0x12736b('0x9')][_0x12736b('0x6e')]({'where':{'id':_0x405422[_0x12736b('0xb')]['ids']},'attributes':['id'],'include':[{'model':db['User'],'as':'Agents','attributes':['id'],'raw':!![]}]})['then'](handleEntityNotFound(_0x2ad9cc,null))[_0x12736b('0x64')](function(_0x3ed83f){const _0xb138f9=_0x12736b,_0x3109cb=_[_0xb138f9('0x13')](_0x3ed83f,'id');let _0x3bd200=[];const _0x48c408=[],_0x2cc4a8=squel['select']();_0x2cc4a8[_0xb138f9('0x3b')](_0xb138f9('0x61'))[_0xb138f9('0x70')](_0xb138f9('0x20'),'tq')[_0xb138f9('0x28')](_0xb138f9('0x42'),'ut',_0xb138f9('0x12'))['where'](_0xb138f9('0x10'),_0x405422['params']['id']);for(let _0xd42551=0x0;_0xd42551<_0x3ed83f['length'];_0xd42551+=0x1){const _0x12759c=_0x3ed83f[_0xd42551];for(let _0x564db3=0x0;_0x564db3<_0x12759c['Agents'][_0xb138f9('0x3f')];_0x564db3+=0x1){const _0x246f57=_0x12759c[_0xb138f9('0x66')][_0x564db3],_0x13d9bb=_0x2cc4a8[_0xb138f9('0x4a')]();_0x13d9bb['where']('ut.UserId\x20=\x20?',_0x246f57['id']),_0x48c408[_0xb138f9('0x4f')](db['sequelize'][_0xb138f9('0xb')](_0x13d9bb['toString'](),{'type':QueryTypes[_0xb138f9('0x2d')]})[_0xb138f9('0x64')](function(_0x41a1cc){const _0x2a840f=_0xb138f9;if(_0x41a1cc[_0x2a840f('0x3f')]===0x1)return _0x246f57['id'];else{const _0x137f4c=_[_0x2a840f('0x55')](_[_0x2a840f('0x13')](_0x41a1cc,_0x2a840f('0x27')),function(_0x3ee67f){const _0x75a62f=_0x2a840f;return _[_0x75a62f('0x22')](_0x3109cb,_0x3ee67f);});if(_0x137f4c)return _0x246f57['id'];}}));}}return Promise[_0xb138f9('0x74')](_0x48c408)[_0xb138f9('0x64')](function(_0x3a0f7d){const _0x3dd1a9=_0xb138f9;return _0x3bd200=_(_0x3bd200)[_0x3dd1a9('0x5a')](_0x3a0f7d)['compact']()[_0x3dd1a9('0x2e')](),db[_0x3dd1a9('0x56')][_0x3dd1a9('0x6f')]({'where':{'id':_0x405422[_0x3dd1a9('0x50')]['id']}})[_0x3dd1a9('0x64')](function(_0x22e11f){const _0x11ab10=_0x3dd1a9;return db['sequelize'][_0x11ab10('0x5d')](function(_0x202c0c){const _0x4efa88=_0x11ab10;return _0x22e11f['removeTeams'](_0x405422[_0x4efa88('0xb')][_0x4efa88('0xe')],{'transaction':_0x202c0c})[_0x4efa88('0x64')](function(){const _0x3a3331=_0x4efa88;if(!_[_0x3a3331('0x4')](_0x3bd200))return _0x22e11f[_0x3a3331('0x73')](_0x3bd200,{'transaction':_0x202c0c});})[_0x4efa88('0x64')](function(){_0x3bd200['forEach'](function(_0x540c8c){const _0x579e30=a420_0x32d6;socket[_0x579e30('0x60')](_0x579e30('0x26'),{'UserId':_0x540c8c,'MailQueueId':_0x22e11f['id']});});});});});});})[_0x12736b('0x64')](respondWithStatusCode(_0x2ad9cc,null))[_0x12736b('0x5e')](handleError(_0x2ad9cc,null));},exports[_0x50dda0('0x5c')]=function(_0x478134,_0xa1380f){const _0x3e7596=_0x50dda0;return db[_0x3e7596('0x56')]['findOne']({'where':{'id':_0x478134[_0x3e7596('0x50')]['id']}})[_0x3e7596('0x64')](function(_0x110241){const _0x2e7169=_0x3e7596;if(_0x110241)return _0x110241[_0x2e7169('0x5c')](_0x478134[_0x2e7169('0x5b')][_0x2e7169('0xe')],{'through':_['omit'](_0x478134['body'],['ids','id'])})['then'](function(_0x3323ac){const _0x4b466d=_0x2e7169;for(let _0x12e8da=0x0;_0x12e8da<_0x478134['body'][_0x4b466d('0xe')][_0x4b466d('0x3f')];_0x12e8da+=0x1){socket[_0x4b466d('0x60')](_0x4b466d('0x35'),{'UserId':_0x478134[_0x4b466d('0x5b')][_0x4b466d('0xe')][_0x12e8da],'MailQueueId':_0x478134[_0x4b466d('0x50')]['id']});}return _0x3323ac;});})[_0x3e7596('0x64')](respondWithResult(_0xa1380f,null))[_0x3e7596('0x5e')](handleError(_0xa1380f,null));},exports[_0x50dda0('0x73')]=function(_0x5e8010,_0x73830){const _0x4887b7=_0x50dda0;return db[_0x4887b7('0x56')][_0x4887b7('0x6f')]({'where':{'id':_0x5e8010[_0x4887b7('0x50')]['id']}})['then'](handleEntityNotFound(_0x73830,null))[_0x4887b7('0x64')](function(_0x1ca97d){const _0xd7559a=_0x4887b7;if(_0x1ca97d)return _0x1ca97d[_0xd7559a('0x73')](_0x5e8010[_0xd7559a('0xb')][_0xd7559a('0xe')])[_0xd7559a('0x64')](function(){const _0x353305=_0xd7559a;if(_['isArray'](_0x5e8010[_0x353305('0xb')]['ids']))for(let _0x1c0ca6=0x0;_0x1c0ca6<_0x5e8010[_0x353305('0xb')]['ids'][_0x353305('0x3f')];_0x1c0ca6+=0x1){socket['emit'](_0x353305('0x26'),{'UserId':Number(_0x5e8010[_0x353305('0xb')][_0x353305('0xe')][_0x1c0ca6]),'MailQueueId':Number(_0x5e8010[_0x353305('0x50')]['id'])});}else socket[_0x353305('0x60')](_0x353305('0x26'),{'UserId':Number(_0x5e8010[_0x353305('0xb')][_0x353305('0xe')]),'MailQueueId':Number(_0x5e8010[_0x353305('0x50')]['id'])});});})[_0x4887b7('0x64')](respondWithStatusCode(_0x73830,null))['catch'](handleError(_0x73830,null));},exports[_0x50dda0('0x4c')]=function(_0x1596ed,_0x1b66df){const _0xf1c5f8=_0x50dda0;let _0x199781={};const _0x3df6e9={};let _0x3be212,_0x93b14d;return db[_0xf1c5f8('0x56')][_0xf1c5f8('0x6f')]({'where':{'id':_0x1596ed[_0xf1c5f8('0x50')]['id']}})[_0xf1c5f8('0x64')](handleEntityNotFound(_0x1b66df,null))[_0xf1c5f8('0x64')](function(_0x123fc5){const _0x4a2ae2=_0xf1c5f8;if(_0x123fc5)return _0x3be212=_0x123fc5,_0x3df6e9['model']=_[_0x4a2ae2('0x3e')](db[_0x4a2ae2('0x30')]['rawAttributes']),_0x3df6e9[_0x4a2ae2('0xb')]=_['keys'](_0x1596ed['query']),_0x3df6e9['filters']=_[_0x4a2ae2('0x1a')](_0x3df6e9['model'],_0x3df6e9[_0x4a2ae2('0xb')]),_0x199781[_0x4a2ae2('0x2f')]=_['intersection'](_0x3df6e9[_0x4a2ae2('0x59')],qs[_0x4a2ae2('0x17')](_0x1596ed[_0x4a2ae2('0xb')][_0x4a2ae2('0x17')])),_0x199781['attributes']=_0x199781[_0x4a2ae2('0x2f')][_0x4a2ae2('0x3f')]?_0x199781[_0x4a2ae2('0x2f')]:_0x3df6e9[_0x4a2ae2('0x59')],_0x199781['order']=qs[_0x4a2ae2('0x24')](_0x1596ed[_0x4a2ae2('0xb')]['sort']),_0x199781[_0x4a2ae2('0x6a')]=qs[_0x4a2ae2('0x6b')](_[_0x4a2ae2('0x58')](_0x1596ed[_0x4a2ae2('0xb')],_0x3df6e9[_0x4a2ae2('0x6b')])),_0x1596ed[_0x4a2ae2('0xb')]['filter']&&(_0x199781[_0x4a2ae2('0x6a')]=_['merge'](_0x199781[_0x4a2ae2('0x6a')],{[Op['or']]:_[_0x4a2ae2('0x13')](_0x199781[_0x4a2ae2('0x2f')],function(_0x16a15b){const _0xa6cb98=_0x4a2ae2,_0x45729a={};return _0x45729a[_0x16a15b]={[Op[_0xa6cb98('0x71')]]:'%'+_0x1596ed[_0xa6cb98('0xb')][_0xa6cb98('0x6')]+'%'},_0x45729a;})})),_0x199781=_['merge']({},_0x199781,_0x1596ed[_0x4a2ae2('0x41')]),_0x3be212['getAgents'](_0x199781);})[_0xf1c5f8('0x64')](function(_0x223c31){const _0x3b5a47=_0xf1c5f8;if(_0x223c31)return _0x93b14d=_0x223c31[_0x3b5a47('0x3f')],typeof _0x1596ed['query'][_0x3b5a47('0x37')]===_0x3b5a47('0x49')&&(_0x199781[_0x3b5a47('0x53')]=qs['limit'](_0x1596ed[_0x3b5a47('0xb')][_0x3b5a47('0x53')]),_0x199781[_0x3b5a47('0x68')]=qs[_0x3b5a47('0x68')](_0x1596ed[_0x3b5a47('0xb')][_0x3b5a47('0x68')])),_0x3be212[_0x3b5a47('0x4c')](_0x199781);})[_0xf1c5f8('0x64')](function(_0x336cba){if(_0x336cba)return _0x336cba?{'count':_0x93b14d,'rows':_0x336cba}:null;})[_0xf1c5f8('0x64')](respondWithResult(_0x1b66df,null))[_0xf1c5f8('0x5e')](handleError(_0x1b66df,null));}; \ No newline at end of file +const a420_0x1362=['length','updatedAt','set','sequelize','where','SIP','SELECT','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','status','userMailQueue:save','select','user','../../rediscache','transaction','ids','filters','create','UserId','query','destroy','like','error','MailQueues','union','getAgents','agent','findAndCountAll','every','map','each','all','name','join','findOne','clone','sendStatus','userMailQueue:remove','team_has_mail_queues','emit','VIRTUAL','params','sort','util','./mailQueue.socket','include','tq.TeamId','MailQueue','model','rows','userProfileId','removeAgents','Team','User','catch','%s/%s','merge','filter','fieldName','forEach','../../config/logger','fields','getTeams','ut.TeamId\x20=\x20tq.TeamId','format','mailPause','undefined','../../components/parsers/qs','then','removeTeams','count','includeAll','pick','limit','body','Unable\x20to\x20retrieve\x20the\x20current\x20user','voicePause','user_has_teams','createdAt','order','get','keys','end','UserProfileResource','update','Agents','role','from','nolimit','addAgents','addTeams','options','api','findAll','TeamId','isArray','UserMailQueue','intersection','offset','attributes','interface','MailQueueId\x20=\x20?','../../mysqldb','json','describe','autoAssociation','Content-Range','flatMap','lodash','rawAttributes'];(function(_0x29c65f,_0x1362c2){const _0x2be1dc=function(_0x47f5f4){while(--_0x47f5f4){_0x29c65f['push'](_0x29c65f['shift']());}};_0x2be1dc(++_0x1362c2);}(a420_0x1362,0x87));const a420_0x2be1=function(_0x29c65f,_0x1362c2){_0x29c65f=_0x29c65f-0x0;let _0x2be1dc=a420_0x1362[_0x29c65f];return _0x2be1dc;};const _0x1c7dd1=a420_0x2be1;'use strict';const util=require(_0x1c7dd1('0x10')),_=require(_0x1c7dd1('0x51')),squel=require('squel'),qs=require(_0x1c7dd1('0x28')),logger=require(_0x1c7dd1('0x21'))(_0x1c7dd1('0x41')),{getSocket}=require(_0x1c7dd1('0x5f')),socket=getSocket(),db=require(_0x1c7dd1('0x4b'))['db'],{Op,QueryTypes}=require(_0x1c7dd1('0x56'));require(_0x1c7dd1('0x11'))['register'](socket);function respondWithStatusCode(_0x47f5f4,_0x276cb9){return _0x276cb9=_0x276cb9||0xcc,function(_0x45f30e){const _0xc926e3=a420_0x2be1;if(_0x45f30e)return _0x47f5f4[_0xc926e3('0x9')](_0x276cb9);return _0x47f5f4['status'](_0x276cb9)[_0xc926e3('0x37')]();};}function respondWithResult(_0x1c6e6d,_0xf686b6){return _0xf686b6=_0xf686b6||0xc8,function(_0x568311){const _0x447b4f=a420_0x2be1;if(_0x568311)return _0x1c6e6d[_0x447b4f('0x5b')](_0xf686b6)[_0x447b4f('0x4c')](_0x568311);};}function respondWithFilteredResult(_0x4b69ef,_0x21fbaf){return function(_0xffb98f){const _0x1f0fe6=a420_0x2be1;if(_0xffb98f){const _0x2538c6=_0xffb98f[_0x1f0fe6('0x2b')],_0x25c82d=_0x21fbaf['offset'];let _0x22a4c7=_0x21fbaf[_0x1f0fe6('0x47')]+_0x21fbaf['limit'],_0x4e3762;return _0x22a4c7>=_0x2538c6?(_0x22a4c7=_0x2538c6,_0x4e3762=0xc8):_0x4e3762=0xce,_0x4b69ef[_0x1f0fe6('0x5b')](_0x4e3762),_0x4b69ef[_0x1f0fe6('0x55')](_0x1f0fe6('0x4f'),_0x25c82d+'-'+_0x22a4c7+'/'+_0x2538c6)[_0x1f0fe6('0x4c')](_0xffb98f);}return null;};}function saveUpdates(_0x3c51d7){return function(_0x2a8b62){const _0x4ebd47=a420_0x2be1;if(_0x2a8b62)return _0x2a8b62[_0x4ebd47('0x39')](_0x3c51d7)[_0x4ebd47('0x29')](function(_0x1c7f7c){return _0x1c7f7c;});return null;};}function removeEntity(_0x569c0b){return function(_0x24e368){const _0x4fc7f9=a420_0x2be1;if(_0x24e368)return _0x24e368['destroy']()[_0x4fc7f9('0x29')](function(){const _0x3a119f=_0x4fc7f9,_0x162660=_0x24e368[_0x3a119f('0x35')]({'plain':!![]}),_0x1c518a=_0x3a119f('0x69');return db['UserProfileResource'][_0x3a119f('0x66')]({'where':{'type':_0x1c518a,'resourceId':_0x162660['id']}})[_0x3a119f('0x29')](function(){return _0x24e368;});})[_0x4fc7f9('0x29')](function(){const _0x41f723=_0x4fc7f9;_0x569c0b[_0x41f723('0x5b')](0xcc)[_0x41f723('0x37')]();});};}function handleEntityNotFound(_0xc78f4c){return function(_0x149162){return!_0x149162&&_0xc78f4c['sendStatus'](0x194),_0x149162;};}function handleError(_0x137648,_0x399be7){return _0x399be7=_0x399be7||0x1f4,function(_0x17de9f){const _0x1fdb33=a420_0x2be1;logger['error'](_0x17de9f['stack']),_0x17de9f[_0x1fdb33('0x5')]&&delete _0x17de9f[_0x1fdb33('0x5')],_0x137648[_0x1fdb33('0x5b')](_0x399be7)['send'](_0x17de9f);};}exports['index']=function(_0x2f6690,_0x5454bd){const _0x4adc5f=_0x1c7dd1;let _0x6d061f={};const _0x1774af={},_0x489690={'count':0x0,'rows':[]},_0x2a86f7=_[_0x4adc5f('0x2')](db[_0x4adc5f('0x14')][_0x4adc5f('0x52')],function(_0x3db704){const _0xcb4fba=_0x4adc5f;return{'name':_0x3db704[_0xcb4fba('0x1f')],'type':_0x3db704['type']['key']};});_0x1774af[_0x4adc5f('0x15')]=_[_0x4adc5f('0x2')](_0x2a86f7,_0x4adc5f('0x5')),_0x1774af[_0x4adc5f('0x65')]=_[_0x4adc5f('0x36')](_0x2f6690['query']),_0x1774af['filters']=_[_0x4adc5f('0x46')](_0x1774af['model'],_0x1774af['query']),_0x6d061f[_0x4adc5f('0x48')]=_[_0x4adc5f('0x46')](_0x1774af[_0x4adc5f('0x15')],qs['fields'](_0x2f6690['query'][_0x4adc5f('0x22')])),_0x6d061f[_0x4adc5f('0x48')]=_0x6d061f['attributes']['length']?_0x6d061f[_0x4adc5f('0x48')]:_0x1774af['model'];typeof _0x2f6690[_0x4adc5f('0x65')][_0x4adc5f('0x3d')]===_0x4adc5f('0x27')&&(_0x6d061f[_0x4adc5f('0x2e')]=qs[_0x4adc5f('0x2e')](_0x2f6690['query'][_0x4adc5f('0x2e')]),_0x6d061f[_0x4adc5f('0x47')]=qs[_0x4adc5f('0x47')](_0x2f6690[_0x4adc5f('0x65')][_0x4adc5f('0x47')]));_0x6d061f['order']=qs[_0x4adc5f('0xf')](_0x2f6690[_0x4adc5f('0x65')][_0x4adc5f('0xf')]),_0x6d061f[_0x4adc5f('0x57')]=qs['filters'](_[_0x4adc5f('0x2d')](_0x2f6690[_0x4adc5f('0x65')],_0x1774af[_0x4adc5f('0x62')]),_0x2a86f7);_0x2f6690[_0x4adc5f('0x65')][_0x4adc5f('0x1e')]&&(_0x6d061f[_0x4adc5f('0x57')]=_['merge'](_0x6d061f['where'],{[Op['or']]:_[_0x4adc5f('0x2')](_0x2a86f7,function(_0xc4d8ea){const _0x1cdb07=_0x4adc5f;if(_0xc4d8ea['type']!==_0x1cdb07('0xd')){const _0x161ba5={};return _0x161ba5[_0xc4d8ea[_0x1cdb07('0x5')]]={[Op[_0x1cdb07('0x67')]]:'%'+_0x2f6690['query'][_0x1cdb07('0x1e')]+'%'},_0x161ba5;}})}));_0x6d061f=_['merge']({},_0x6d061f,_0x2f6690['options']);const _0x1177df={'where':_0x6d061f[_0x4adc5f('0x57')]};return db[_0x4adc5f('0x14')][_0x4adc5f('0x2b')](_0x1177df)[_0x4adc5f('0x29')](function(_0x4326c5){const _0xd0813d=_0x4adc5f;return _0x489690[_0xd0813d('0x2b')]=_0x4326c5,_0x2f6690['query']['includeAll']&&(_0x6d061f[_0xd0813d('0x12')]=[{'all':!![]}]),db[_0xd0813d('0x14')][_0xd0813d('0x42')](_0x6d061f);})['then'](function(_0x562994){const _0x67afe3=_0x4adc5f;return _0x489690[_0x67afe3('0x16')]=_0x562994,_0x489690;})[_0x4adc5f('0x29')](respondWithFilteredResult(_0x5454bd,_0x6d061f))[_0x4adc5f('0x1b')](handleError(_0x5454bd,null));},exports['show']=function(_0x2c0ab4,_0x51e598){const _0x4e3aca=_0x1c7dd1;let _0x37b5f8={'raw':!![],'where':{'id':_0x2c0ab4[_0x4e3aca('0xe')]['id']}};const _0x265088={};return _0x265088[_0x4e3aca('0x15')]=_[_0x4e3aca('0x36')](db['MailQueue']['rawAttributes']),_0x265088[_0x4e3aca('0x65')]=_['keys'](_0x2c0ab4[_0x4e3aca('0x65')]),_0x265088['filters']=_[_0x4e3aca('0x46')](_0x265088['model'],_0x265088[_0x4e3aca('0x65')]),_0x37b5f8[_0x4e3aca('0x48')]=_[_0x4e3aca('0x46')](_0x265088[_0x4e3aca('0x15')],qs['fields'](_0x2c0ab4['query'][_0x4e3aca('0x22')])),_0x37b5f8['attributes']=_0x37b5f8['attributes']['length']?_0x37b5f8[_0x4e3aca('0x48')]:_0x265088[_0x4e3aca('0x15')],_0x2c0ab4[_0x4e3aca('0x65')][_0x4e3aca('0x2c')]&&(_0x37b5f8[_0x4e3aca('0x12')]=[{'all':!![]}]),_0x37b5f8=_['merge']({},_0x37b5f8,_0x2c0ab4['options']),db['MailQueue'][_0x4e3aca('0x7')](_0x37b5f8)[_0x4e3aca('0x29')](handleEntityNotFound(_0x51e598,null))[_0x4e3aca('0x29')](respondWithResult(_0x51e598,null))[_0x4e3aca('0x1b')](handleError(_0x51e598,null));},exports[_0x1c7dd1('0x63')]=function(_0x48532f,_0x1b1947){const _0xdef833=_0x1c7dd1;return db[_0xdef833('0x14')][_0xdef833('0x63')](_0x48532f['body'],{})[_0xdef833('0x29')](function(_0x2d5191){const _0x2a3994=_0xdef833,_0x594f8a=_0x48532f[_0x2a3994('0x5e')]['get']({'plain':!![]});if(!_0x594f8a)throw new Error(_0x2a3994('0x30'));if(_0x594f8a[_0x2a3994('0x3b')]==='user'){const _0xca8cac=_0x2d5191['get']({'plain':!![]}),_0x337987=_0x2a3994('0x69');return db['UserProfileSection'][_0x2a3994('0x7')]({'where':{'name':_0x337987,'userProfileId':_0x594f8a[_0x2a3994('0x17')]},'raw':!![]})[_0x2a3994('0x29')](function(_0x2d5167){const _0x4b1ff0=_0x2a3994;return _0x2d5167&&_0x2d5167[_0x4b1ff0('0x4e')]===0x0?db[_0x4b1ff0('0x38')][_0x4b1ff0('0x63')]({'name':_0xca8cac[_0x4b1ff0('0x5')],'resourceId':_0xca8cac['id'],'type':_0x2d5167[_0x4b1ff0('0x5')],'sectionId':_0x2d5167['id']},{})[_0x4b1ff0('0x29')](function(){return _0x2d5191;}):_0x2d5191;})[_0x2a3994('0x1b')](function(_0x23d137){const _0x5a3da2=_0x2a3994;logger[_0x5a3da2('0x68')](_0x5a3da2('0x5a'),_0x23d137);throw _0x23d137;});}return _0x2d5191;})['then'](respondWithResult(_0x1b1947,0xc9))[_0xdef833('0x1b')](handleError(_0x1b1947,null));},exports[_0x1c7dd1('0x39')]=function(_0x215be3,_0x1eb926){const _0x1dd4f8=_0x1c7dd1;return _0x215be3[_0x1dd4f8('0x2f')]['id']&&delete _0x215be3[_0x1dd4f8('0x2f')]['id'],db['MailQueue'][_0x1dd4f8('0x7')]({'where':{'id':_0x215be3[_0x1dd4f8('0xe')]['id']}})[_0x1dd4f8('0x29')](handleEntityNotFound(_0x1eb926,null))['then'](saveUpdates(_0x215be3['body'],null))[_0x1dd4f8('0x29')](respondWithResult(_0x1eb926,null))[_0x1dd4f8('0x1b')](handleError(_0x1eb926,null));},exports[_0x1c7dd1('0x66')]=function(_0x2a09f0,_0x475938){const _0x4e18d1=_0x1c7dd1;return db[_0x4e18d1('0x14')][_0x4e18d1('0x7')]({'where':{'id':_0x2a09f0['params']['id']}})['then'](handleEntityNotFound(_0x475938,null))['then'](removeEntity(_0x475938,null))[_0x4e18d1('0x1b')](handleError(_0x475938,null));},exports['describe']=function(_0x28cce2,_0x38fdf9){const _0x2cf1e4=_0x1c7dd1;return db[_0x2cf1e4('0x14')][_0x2cf1e4('0x4d')]()[_0x2cf1e4('0x29')](respondWithResult(_0x38fdf9,null))[_0x2cf1e4('0x1b')](handleError(_0x38fdf9,null));},exports['getMembers']=function(_0xcaba7b,_0x4126f1){const _0x54ff3a=_0x1c7dd1;let _0x643af={'raw':!![],'where':{}};const _0xfdc6a7={};let _0x648fc4;return db[_0x54ff3a('0x14')][_0x54ff3a('0x7')]({'where':{'id':_0xcaba7b[_0x54ff3a('0xe')]['id']}})[_0x54ff3a('0x29')](handleEntityNotFound(_0x4126f1,null))['then'](function(_0x52abeb){const _0x2ba603=_0x54ff3a;if(_0x52abeb)return _0x648fc4=_0x52abeb[_0x2ba603('0x35')]({'plain':!![]}),_0xfdc6a7[_0x2ba603('0x15')]=_[_0x2ba603('0x36')](db[_0x2ba603('0x45')][_0x2ba603('0x52')]),_0xfdc6a7[_0x2ba603('0x65')]=_['keys'](_0xcaba7b[_0x2ba603('0x65')]),_0xfdc6a7[_0x2ba603('0x62')]=_[_0x2ba603('0x46')](_0xfdc6a7[_0x2ba603('0x15')],_0xfdc6a7[_0x2ba603('0x65')]),_0x643af['attributes']=_[_0x2ba603('0x46')](_0xfdc6a7[_0x2ba603('0x15')],qs[_0x2ba603('0x22')](_0xcaba7b[_0x2ba603('0x65')][_0x2ba603('0x22')])),_0x643af[_0x2ba603('0x48')]=_0x643af['attributes'][_0x2ba603('0x53')]?_0x643af[_0x2ba603('0x48')]:_0xfdc6a7['model'],typeof _0xcaba7b[_0x2ba603('0x65')][_0x2ba603('0x3d')]===_0x2ba603('0x27')&&(_0x643af[_0x2ba603('0x2e')]=qs[_0x2ba603('0x2e')](_0xcaba7b[_0x2ba603('0x65')][_0x2ba603('0x2e')]),_0x643af[_0x2ba603('0x47')]=qs[_0x2ba603('0x47')](_0xcaba7b[_0x2ba603('0x65')]['offset'])),_0x643af[_0x2ba603('0x34')]=qs[_0x2ba603('0xf')](_0xcaba7b[_0x2ba603('0x65')][_0x2ba603('0xf')]),_0x643af[_0x2ba603('0x57')]=qs[_0x2ba603('0x62')](_[_0x2ba603('0x2d')](_0xcaba7b[_0x2ba603('0x65')],_0xfdc6a7[_0x2ba603('0x62')])),_0x643af[_0x2ba603('0x57')]['MailQueueId']=_0x52abeb['id'],_0xcaba7b[_0x2ba603('0x65')][_0x2ba603('0x1e')]&&(_0x643af[_0x2ba603('0x57')]=_['merge'](_0x643af[_0x2ba603('0x57')],{[Op['or']]:_[_0x2ba603('0x2')](_0x643af[_0x2ba603('0x48')],function(_0x1590d9){const _0x4a7ac4=_0x2ba603,_0x48f05a={};return _0x48f05a[_0x1590d9]={[Op[_0x4a7ac4('0x67')]]:'%'+_0xcaba7b[_0x4a7ac4('0x65')][_0x4a7ac4('0x1e')]+'%'},_0x48f05a;})})),_0x643af=_[_0x2ba603('0x1d')]({},_0x643af,_0xcaba7b[_0x2ba603('0x40')]),db[_0x2ba603('0x45')][_0x2ba603('0x42')](_0x643af);})[_0x54ff3a('0x29')](function(_0x5631b9){const _0x8bb481=_0x54ff3a;if(_0x5631b9)return db['User'][_0x8bb481('0x0')]({'where':{'id':_[_0x8bb481('0x2')](_0x5631b9,_0x8bb481('0x64')),'role':_0x8bb481('0x6c')},'attributes':['id',_0x8bb481('0x5'),_0x8bb481('0x26'),'updatedAt','createdAt']});})[_0x54ff3a('0x29')](function(_0x4a78e1){const _0x2a5555=_0x54ff3a;return _0x4a78e1?{'count':_0x4a78e1[_0x2a5555('0x2b')],'rows':_[_0x2a5555('0x2')](_0x4a78e1[_0x2a5555('0x16')],function(_0x45aa17){const _0x3cf0a1=_0x2a5555;return{'membername':_0x45aa17[_0x3cf0a1('0x5')],'UserId':_0x45aa17['id'],'queue_name':_0x648fc4[_0x3cf0a1('0x5')],'MailQueueId':_0x648fc4['id'],'interface':util[_0x3cf0a1('0x25')](_0x3cf0a1('0x1c'),_0x3cf0a1('0x58'),_0x45aa17[_0x3cf0a1('0x5')]),'penalty':0x0,'paused':_0x45aa17[_0x3cf0a1('0x26')],'createdAt':_0x45aa17[_0x3cf0a1('0x33')],'updatedAt':_0x45aa17[_0x3cf0a1('0x54')]};})}:{'count':0x0,'rows':[]};})[_0x54ff3a('0x29')](respondWithFilteredResult(_0x4126f1,_0x643af))[_0x54ff3a('0x1b')](handleError(_0x4126f1,null));},exports[_0x1c7dd1('0x23')]=function(_0x3570d2,_0xedf28a){const _0x4c53c5=_0x1c7dd1;let _0x944695={};const _0xcd92bb={};let _0x214b9a,_0x40ec60;return db[_0x4c53c5('0x14')][_0x4c53c5('0x7')]({'where':{'id':_0x3570d2[_0x4c53c5('0xe')]['id']}})['then'](handleEntityNotFound(_0xedf28a,null))['then'](function(_0x1c6722){const _0x5ae3c0=_0x4c53c5;if(_0x1c6722)return _0x214b9a=_0x1c6722,_0xcd92bb[_0x5ae3c0('0x15')]=_[_0x5ae3c0('0x36')](db[_0x5ae3c0('0x19')][_0x5ae3c0('0x52')]),_0xcd92bb[_0x5ae3c0('0x65')]=_[_0x5ae3c0('0x36')](_0x3570d2[_0x5ae3c0('0x65')]),_0xcd92bb[_0x5ae3c0('0x62')]=_[_0x5ae3c0('0x46')](_0xcd92bb['model'],_0xcd92bb[_0x5ae3c0('0x65')]),_0x944695[_0x5ae3c0('0x48')]=_[_0x5ae3c0('0x46')](_0xcd92bb[_0x5ae3c0('0x15')],qs[_0x5ae3c0('0x22')](_0x3570d2[_0x5ae3c0('0x65')][_0x5ae3c0('0x22')])),_0x944695[_0x5ae3c0('0x48')]=_0x944695['attributes'][_0x5ae3c0('0x53')]?_0x944695['attributes']:_0xcd92bb['model'],_0x944695[_0x5ae3c0('0x34')]=qs[_0x5ae3c0('0xf')](_0x3570d2[_0x5ae3c0('0x65')]['sort']),_0x944695[_0x5ae3c0('0x57')]=qs[_0x5ae3c0('0x62')](_[_0x5ae3c0('0x2d')](_0x3570d2[_0x5ae3c0('0x65')],_0xcd92bb[_0x5ae3c0('0x62')])),_0x3570d2[_0x5ae3c0('0x65')][_0x5ae3c0('0x1e')]&&(_0x944695[_0x5ae3c0('0x57')]=_[_0x5ae3c0('0x1d')](_0x944695[_0x5ae3c0('0x57')],{[Op['or']]:_['map'](_0x944695[_0x5ae3c0('0x48')],function(_0x267526){const _0x2396b4=_0x5ae3c0,_0x5a0810={};return _0x5a0810[_0x267526]={[Op[_0x2396b4('0x67')]]:'%'+_0x3570d2[_0x2396b4('0x65')][_0x2396b4('0x1e')]+'%'},_0x5a0810;})})),_0x944695=_[_0x5ae3c0('0x1d')]({},_0x944695,_0x3570d2[_0x5ae3c0('0x40')]),_0x214b9a[_0x5ae3c0('0x23')](_0x944695);})['then'](function(_0x24b606){const _0x3ce8b6=_0x4c53c5;if(_0x24b606)return _0x40ec60=_0x24b606[_0x3ce8b6('0x53')],typeof _0x3570d2['query'][_0x3ce8b6('0x3d')]==='undefined'&&(_0x944695['limit']=qs[_0x3ce8b6('0x2e')](_0x3570d2['query'][_0x3ce8b6('0x2e')]),_0x944695['offset']=qs[_0x3ce8b6('0x47')](_0x3570d2[_0x3ce8b6('0x65')][_0x3ce8b6('0x47')])),_0x214b9a[_0x3ce8b6('0x23')](_0x944695);})[_0x4c53c5('0x29')](function(_0x304040){if(_0x304040)return _0x304040?{'count':_0x40ec60,'rows':_0x304040}:null;})[_0x4c53c5('0x29')](respondWithResult(_0xedf28a,null))[_0x4c53c5('0x1b')](handleError(_0xedf28a,null));},exports[_0x1c7dd1('0x3f')]=function(_0x4e4fd6,_0x383554){const _0x539371=_0x1c7dd1,_0x2ba678=_0x4e4fd6[_0x539371('0x2f')][_0x539371('0x61')];return db[_0x539371('0x19')][_0x539371('0x42')]({'where':{'id':_0x2ba678},'attributes':['id'],'include':[{'model':db[_0x539371('0x1a')],'as':_0x539371('0x3a'),'attributes':['id',_0x539371('0x5'),'online',_0x539371('0x31'),_0x539371('0x49')],'raw':!![]}]})['then'](function(_0x1a7923){const _0x17ca91=_0x539371;if(_0x1a7923){const _0x47191f=_[_0x17ca91('0x50')](_0x1a7923,function(_0x2f9598){const _0x4c5b7c=_0x17ca91,_0x587672=_0x2f9598[_0x4c5b7c('0x35')]({'plain':!![]});return _0x587672[_0x4c5b7c('0x3a')];});return db[_0x17ca91('0x14')][_0x17ca91('0x7')]({'where':{'id':_0x4e4fd6['params']['id']}})[_0x17ca91('0x29')](function(_0x31cf27){const _0x40195d=_0x17ca91;return db['sequelize'][_0x40195d('0x60')](function(_0x4ba0cc){const _0x2389a0=_0x40195d;return _0x31cf27[_0x2389a0('0x3f')](_0x2ba678,{'transaction':_0x4ba0cc})[_0x2389a0('0x29')](function(){const _0x35279a=_0x2389a0;return Promise[_0x35279a('0x3')](_0x47191f,function(_0x474990){const _0x58b48c=_0x35279a;return db[_0x58b48c('0x45')]['findOrCreate']({'where':{'UserId':_0x474990['id'],'MailQueueId':_0x4e4fd6[_0x58b48c('0xe')]['id']},'transaction':_0x4ba0cc});});})[_0x2389a0('0x29')](function(){const _0x5127db=_0x2389a0;_0x47191f[_0x5127db('0x20')](function(_0x215cc9){const _0x13bffd=_0x5127db;socket[_0x13bffd('0xc')](_0x13bffd('0x5c'),{'UserId':_0x215cc9['id'],'MailQueueId':_0x31cf27['id']});});});});});}})[_0x539371('0x29')](respondWithStatusCode(_0x383554,null))[_0x539371('0x1b')](handleError(_0x383554,null));},exports[_0x1c7dd1('0x2a')]=function(_0x402f98,_0x289433){const _0x46ae92=_0x1c7dd1;return db[_0x46ae92('0x19')][_0x46ae92('0x42')]({'where':{'id':_0x402f98[_0x46ae92('0x65')][_0x46ae92('0x61')]},'attributes':['id'],'include':[{'model':db[_0x46ae92('0x1a')],'as':_0x46ae92('0x3a'),'attributes':['id'],'raw':!![]}]})[_0x46ae92('0x29')](handleEntityNotFound(_0x289433,null))[_0x46ae92('0x29')](function(_0x44be8b){const _0x1f6740=_0x46ae92,_0x403621=_[_0x1f6740('0x2')](_0x44be8b,'id');let _0x2e4ddb=[];const _0x26a64e=[],_0x3e2fdc=squel[_0x1f6740('0x5d')]();_0x3e2fdc['field'](_0x1f6740('0x13'))[_0x1f6740('0x3c')](_0x1f6740('0xb'),'tq')[_0x1f6740('0x6')](_0x1f6740('0x32'),'ut',_0x1f6740('0x24'))[_0x1f6740('0x57')](_0x1f6740('0x4a'),_0x402f98[_0x1f6740('0xe')]['id']);for(let _0x341d52=0x0;_0x341d52<_0x44be8b[_0x1f6740('0x53')];_0x341d52+=0x1){const _0x9fbc7e=_0x44be8b[_0x341d52];for(let _0x4ed5f4=0x0;_0x4ed5f4<_0x9fbc7e[_0x1f6740('0x3a')][_0x1f6740('0x53')];_0x4ed5f4+=0x1){const _0x482eeb=_0x9fbc7e[_0x1f6740('0x3a')][_0x4ed5f4],_0x429afc=_0x3e2fdc[_0x1f6740('0x8')]();_0x429afc[_0x1f6740('0x57')]('ut.UserId\x20=\x20?',_0x482eeb['id']),_0x26a64e['push'](db[_0x1f6740('0x56')][_0x1f6740('0x65')](_0x429afc['toString'](),{'type':QueryTypes[_0x1f6740('0x59')]})[_0x1f6740('0x29')](function(_0x264b34){const _0x46c1d7=_0x1f6740;if(_0x264b34[_0x46c1d7('0x53')]===0x1)return _0x482eeb['id'];else{const _0x17463b=_[_0x46c1d7('0x1')](_[_0x46c1d7('0x2')](_0x264b34,_0x46c1d7('0x43')),function(_0x2b2e94){return _['includes'](_0x403621,_0x2b2e94);});if(_0x17463b)return _0x482eeb['id'];}}));}}return Promise[_0x1f6740('0x4')](_0x26a64e)[_0x1f6740('0x29')](function(_0x13c659){const _0x6eddc0=_0x1f6740;return _0x2e4ddb=_(_0x2e4ddb)[_0x6eddc0('0x6a')](_0x13c659)['compact']()['value'](),db['MailQueue']['findOne']({'where':{'id':_0x402f98[_0x6eddc0('0xe')]['id']}})[_0x6eddc0('0x29')](function(_0x2d930f){const _0x4e50aa=_0x6eddc0;return db[_0x4e50aa('0x56')][_0x4e50aa('0x60')](function(_0x5744d4){const _0x53ed1e=_0x4e50aa;return _0x2d930f['removeTeams'](_0x402f98[_0x53ed1e('0x65')][_0x53ed1e('0x61')],{'transaction':_0x5744d4})[_0x53ed1e('0x29')](function(){const _0x4ee92d=_0x53ed1e;if(!_['isEmpty'](_0x2e4ddb))return _0x2d930f[_0x4ee92d('0x18')](_0x2e4ddb,{'transaction':_0x5744d4});})[_0x53ed1e('0x29')](function(){const _0x25f76f=_0x53ed1e;_0x2e4ddb[_0x25f76f('0x20')](function(_0x5013f5){const _0x233dec=_0x25f76f;socket[_0x233dec('0xc')](_0x233dec('0xa'),{'UserId':_0x5013f5,'MailQueueId':_0x2d930f['id']});});});});});});})[_0x46ae92('0x29')](respondWithStatusCode(_0x289433,null))[_0x46ae92('0x1b')](handleError(_0x289433,null));},exports['addAgents']=function(_0x11e746,_0x252641){const _0x106852=_0x1c7dd1;return db['MailQueue'][_0x106852('0x7')]({'where':{'id':_0x11e746[_0x106852('0xe')]['id']}})[_0x106852('0x29')](function(_0x122af8){const _0x492c6b=_0x106852;if(_0x122af8)return _0x122af8[_0x492c6b('0x3e')](_0x11e746[_0x492c6b('0x2f')]['ids'],{'through':_['omit'](_0x11e746['body'],[_0x492c6b('0x61'),'id'])})[_0x492c6b('0x29')](function(_0x36e6b9){const _0x899b1d=_0x492c6b;for(let _0x2d4955=0x0;_0x2d4955<_0x11e746[_0x899b1d('0x2f')][_0x899b1d('0x61')][_0x899b1d('0x53')];_0x2d4955+=0x1){socket['emit']('userMailQueue:save',{'UserId':_0x11e746[_0x899b1d('0x2f')][_0x899b1d('0x61')][_0x2d4955],'MailQueueId':_0x11e746[_0x899b1d('0xe')]['id']});}return _0x36e6b9;});})['then'](respondWithResult(_0x252641,null))[_0x106852('0x1b')](handleError(_0x252641,null));},exports['removeAgents']=function(_0x5e0f6b,_0xe8eb31){const _0x494f78=_0x1c7dd1;return db['MailQueue']['findOne']({'where':{'id':_0x5e0f6b[_0x494f78('0xe')]['id']}})[_0x494f78('0x29')](handleEntityNotFound(_0xe8eb31,null))['then'](function(_0xd720e2){const _0x3fa75f=_0x494f78;if(_0xd720e2)return _0xd720e2['removeAgents'](_0x5e0f6b[_0x3fa75f('0x65')][_0x3fa75f('0x61')])[_0x3fa75f('0x29')](function(){const _0x487b02=_0x3fa75f;if(_[_0x487b02('0x44')](_0x5e0f6b[_0x487b02('0x65')]['ids']))for(let _0x15251b=0x0;_0x15251b<_0x5e0f6b[_0x487b02('0x65')][_0x487b02('0x61')][_0x487b02('0x53')];_0x15251b+=0x1){socket[_0x487b02('0xc')](_0x487b02('0xa'),{'UserId':Number(_0x5e0f6b[_0x487b02('0x65')][_0x487b02('0x61')][_0x15251b]),'MailQueueId':Number(_0x5e0f6b[_0x487b02('0xe')]['id'])});}else socket[_0x487b02('0xc')](_0x487b02('0xa'),{'UserId':Number(_0x5e0f6b[_0x487b02('0x65')]['ids']),'MailQueueId':Number(_0x5e0f6b[_0x487b02('0xe')]['id'])});});})['then'](respondWithStatusCode(_0xe8eb31,null))[_0x494f78('0x1b')](handleError(_0xe8eb31,null));},exports[_0x1c7dd1('0x6b')]=function(_0x31e890,_0x422045){const _0x55b368=_0x1c7dd1;let _0x3247be={};const _0x59cc4d={};let _0x4aedcd,_0x34dc18;return db[_0x55b368('0x14')][_0x55b368('0x7')]({'where':{'id':_0x31e890[_0x55b368('0xe')]['id']}})['then'](handleEntityNotFound(_0x422045,null))[_0x55b368('0x29')](function(_0x16e8e3){const _0x240308=_0x55b368;if(_0x16e8e3)return _0x4aedcd=_0x16e8e3,_0x59cc4d['model']=_['keys'](db[_0x240308('0x1a')][_0x240308('0x52')]),_0x59cc4d[_0x240308('0x65')]=_[_0x240308('0x36')](_0x31e890[_0x240308('0x65')]),_0x59cc4d['filters']=_[_0x240308('0x46')](_0x59cc4d[_0x240308('0x15')],_0x59cc4d[_0x240308('0x65')]),_0x3247be['attributes']=_[_0x240308('0x46')](_0x59cc4d[_0x240308('0x15')],qs[_0x240308('0x22')](_0x31e890[_0x240308('0x65')][_0x240308('0x22')])),_0x3247be['attributes']=_0x3247be[_0x240308('0x48')][_0x240308('0x53')]?_0x3247be['attributes']:_0x59cc4d['model'],_0x3247be[_0x240308('0x34')]=qs[_0x240308('0xf')](_0x31e890['query'][_0x240308('0xf')]),_0x3247be[_0x240308('0x57')]=qs['filters'](_[_0x240308('0x2d')](_0x31e890[_0x240308('0x65')],_0x59cc4d[_0x240308('0x62')])),_0x31e890[_0x240308('0x65')][_0x240308('0x1e')]&&(_0x3247be[_0x240308('0x57')]=_[_0x240308('0x1d')](_0x3247be[_0x240308('0x57')],{[Op['or']]:_['map'](_0x3247be[_0x240308('0x48')],function(_0x4dd321){const _0x1f746a=_0x240308,_0x1aac39={};return _0x1aac39[_0x4dd321]={[Op[_0x1f746a('0x67')]]:'%'+_0x31e890['query']['filter']+'%'},_0x1aac39;})})),_0x3247be=_['merge']({},_0x3247be,_0x31e890[_0x240308('0x40')]),_0x4aedcd[_0x240308('0x6b')](_0x3247be);})['then'](function(_0x4a82d2){const _0x5565c9=_0x55b368;if(_0x4a82d2)return _0x34dc18=_0x4a82d2[_0x5565c9('0x53')],typeof _0x31e890[_0x5565c9('0x65')][_0x5565c9('0x3d')]==='undefined'&&(_0x3247be[_0x5565c9('0x2e')]=qs['limit'](_0x31e890[_0x5565c9('0x65')][_0x5565c9('0x2e')]),_0x3247be[_0x5565c9('0x47')]=qs[_0x5565c9('0x47')](_0x31e890[_0x5565c9('0x65')][_0x5565c9('0x47')])),_0x4aedcd[_0x5565c9('0x6b')](_0x3247be);})[_0x55b368('0x29')](function(_0x5c97a2){if(_0x5c97a2)return _0x5c97a2?{'count':_0x34dc18,'rows':_0x5c97a2}:null;})[_0x55b368('0x29')](respondWithResult(_0x422045,null))[_0x55b368('0x1b')](handleError(_0x422045,null));}; \ No newline at end of file diff --git a/server/api/mailQueue/mailQueue.events.js b/server/api/mailQueue/mailQueue.events.js index b99f510..bfacbfd 100644 --- a/server/api/mailQueue/mailQueue.events.js +++ b/server/api/mailQueue/mailQueue.events.js @@ -1 +1 @@ -const a421_0x2a37=['setMaxListeners','MailQueue','update','../../mysqldb','save','undefined','remove','exports','emit'];(function(_0x5e6962,_0x2a3764){const _0x2e77f4=function(_0x4feefe){while(--_0x4feefe){_0x5e6962['push'](_0x5e6962['shift']());}};_0x2e77f4(++_0x2a3764);}(a421_0x2a37,0x1c2));const a421_0x2e77=function(_0x5e6962,_0x2a3764){_0x5e6962=_0x5e6962-0x0;let _0x2e77f4=a421_0x2a37[_0x5e6962];return _0x2e77f4;};const _0x1caa85=a421_0x2e77;'use strict';const EventEmitter=require('events'),MailQueue=require(_0x1caa85('0x3'))['db'][_0x1caa85('0x1')],MailQueueEvents=new EventEmitter();MailQueueEvents[_0x1caa85('0x0')](0x0);const events={'afterCreate':_0x1caa85('0x4'),'afterUpdate':_0x1caa85('0x2'),'afterDestroy':_0x1caa85('0x6')};function emitEvent(_0x4feefe){return function(_0x45d7dc){const _0x52f192=a421_0x2e77;MailQueueEvents[_0x52f192('0x8')](_0x4feefe+':'+_0x45d7dc['id'],_0x45d7dc),MailQueueEvents[_0x52f192('0x8')](_0x4feefe,_0x45d7dc);};}for(const e in events){if(typeof events[e]!==_0x1caa85('0x5')){const event=events[e];MailQueue['addHook'](e,emitEvent(event));}}module[_0x1caa85('0x7')]=MailQueueEvents; \ No newline at end of file +const a421_0x5eac=['undefined','exports','addHook','MailQueue','emit','events','remove','update','../../mysqldb'];(function(_0x422b3f,_0x5eac07){const _0xa3b7f9=function(_0x44553b){while(--_0x44553b){_0x422b3f['push'](_0x422b3f['shift']());}};_0xa3b7f9(++_0x5eac07);}(a421_0x5eac,0x155));const a421_0xa3b7=function(_0x422b3f,_0x5eac07){_0x422b3f=_0x422b3f-0x0;let _0xa3b7f9=a421_0x5eac[_0x422b3f];return _0xa3b7f9;};const _0x1210fb=a421_0xa3b7;'use strict';const EventEmitter=require(_0x1210fb('0x6')),MailQueue=require(_0x1210fb('0x0'))['db'][_0x1210fb('0x4')],MailQueueEvents=new EventEmitter();MailQueueEvents['setMaxListeners'](0x0);const events={'afterCreate':'save','afterUpdate':_0x1210fb('0x8'),'afterDestroy':_0x1210fb('0x7')};function emitEvent(_0x44553b){return function(_0x49b366){const _0x73f807=a421_0xa3b7;MailQueueEvents[_0x73f807('0x5')](_0x44553b+':'+_0x49b366['id'],_0x49b366),MailQueueEvents[_0x73f807('0x5')](_0x44553b,_0x49b366);};}for(const e in events){if(typeof events[e]!==_0x1210fb('0x1')){const event=events[e];MailQueue[_0x1210fb('0x3')](e,emitEvent(event));}}module[_0x1210fb('0x2')]=MailQueueEvents; \ No newline at end of file diff --git a/server/api/mailQueue/mailQueue.model.js b/server/api/mailQueue/mailQueue.model.js index a9e5950..90fd9a0 100644 --- a/server/api/mailQueue/mailQueue.model.js +++ b/server/api/mailQueue/mailQueue.model.js @@ -1 +1 @@ -const a422_0x4e5b=['mail_queues','define','exports','MailQueue'];(function(_0x3736fd,_0x4e5b29){const _0x3f974f=function(_0x933def){while(--_0x933def){_0x3736fd['push'](_0x3736fd['shift']());}};_0x3f974f(++_0x4e5b29);}(a422_0x4e5b,0x1d5));const a422_0x3f97=function(_0x3736fd,_0x4e5b29){_0x3736fd=_0x3736fd-0x0;let _0x3f974f=a422_0x4e5b[_0x3736fd];return _0x3f974f;};const _0x5371cb=a422_0x3f97;'use strict';const attributes=require('./mailQueue.attributes');module[_0x5371cb('0x1')]=function(_0x933def){const _0x41ab62=_0x5371cb,_0x1c0860=_0x933def[_0x41ab62('0x0')](_0x41ab62('0x2'),attributes,{'tableName':_0x41ab62('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1c0860;}; \ No newline at end of file +const a422_0x5523=['MailQueue','./mailQueue.attributes','exports'];(function(_0x31c27a,_0x5523f5){const _0x3150a8=function(_0x142c31){while(--_0x142c31){_0x31c27a['push'](_0x31c27a['shift']());}};_0x3150a8(++_0x5523f5);}(a422_0x5523,0xf2));const a422_0x3150=function(_0x31c27a,_0x5523f5){_0x31c27a=_0x31c27a-0x0;let _0x3150a8=a422_0x5523[_0x31c27a];return _0x3150a8;};const _0x281d20=a422_0x3150;'use strict';const attributes=require(_0x281d20('0x2'));module[_0x281d20('0x0')]=function(_0x142c31){const _0x4351db=_0x281d20,_0x20480c=_0x142c31['define'](_0x4351db('0x1'),attributes,{'tableName':'mail_queues','paranoid':![],'indexes':[],'timestamps':!![]});return _0x20480c;}; \ No newline at end of file diff --git a/server/api/mailQueue/mailQueue.rpc.js b/server/api/mailQueue/mailQueue.rpc.js index cbc8f49..1737aca 100644 --- a/server/api/mailQueue/mailQueue.rpc.js +++ b/server/api/mailQueue/mailQueue.rpc.js @@ -1 +1 @@ -const a423_0x3c93=['../../config/logger','options','./mailQueue.socket','where','../../rediscache','include','raw','attributes','ShowMailQueue','rpc','model','debug','MailQueue','then','register','stringify','GetMailQueue','info','../../mysqldb','limit','error','findOne','lodash','map','findAll','message','catch'];(function(_0x280455,_0x3c93b6){const _0x394cea=function(_0x1efc03){while(--_0x1efc03){_0x280455['push'](_0x280455['shift']());}};_0x394cea(++_0x3c93b6);}(a423_0x3c93,0x1d2));const a423_0x394c=function(_0x280455,_0x3c93b6){_0x280455=_0x280455-0x0;let _0x394cea=a423_0x3c93[_0x280455];return _0x394cea;};const _0x9a41d=a423_0x394c;'use strict';const _=require(_0x9a41d('0xf')),db=require(_0x9a41d('0xb'))['db'],logger=require(_0x9a41d('0x14'))(_0x9a41d('0x2')),{getSocket}=require(_0x9a41d('0x18')),socket=getSocket();require(_0x9a41d('0x16'))[_0x9a41d('0x7')](socket),exports['GetMailQueue']=function(_0x1efc03){const _0x406457=this;return new Promise(function(_0x301d6f,_0x2e3d13){const _0x54d57d=a423_0x394c;return db[_0x54d57d('0x5')][_0x54d57d('0x11')]({'raw':_0x1efc03[_0x54d57d('0x15')]?_0x1efc03[_0x54d57d('0x15')]['raw']===undefined?!![]:![]:!![],'where':_0x1efc03['options']?_0x1efc03[_0x54d57d('0x15')][_0x54d57d('0x17')]||null:null,'attributes':_0x1efc03['options']?_0x1efc03[_0x54d57d('0x15')]['attributes']||null:null,'limit':_0x1efc03[_0x54d57d('0x15')]?_0x1efc03[_0x54d57d('0x15')][_0x54d57d('0xc')]||null:null,'include':_0x1efc03[_0x54d57d('0x15')]?_0x1efc03[_0x54d57d('0x15')][_0x54d57d('0x19')]?_['map'](_0x1efc03['options'][_0x54d57d('0x19')],function(_0x1b1fc4){const _0x445830=_0x54d57d;return{'model':db[_0x1b1fc4['model']],'as':_0x1b1fc4['as'],'attributes':_0x1b1fc4[_0x445830('0x0')],'include':_0x1b1fc4[_0x445830('0x19')]?_[_0x445830('0x10')](_0x1b1fc4[_0x445830('0x19')],function(_0x15ddc2){const _0x5155c5=_0x445830;return{'model':db[_0x15ddc2[_0x5155c5('0x3')]],'as':_0x15ddc2['as'],'attributes':_0x15ddc2['attributes'],'include':_0x15ddc2[_0x5155c5('0x19')]?_[_0x5155c5('0x10')](_0x15ddc2[_0x5155c5('0x19')],function(_0x31d547){const _0x29b809=_0x5155c5;return{'model':db[_0x31d547[_0x29b809('0x3')]],'as':_0x31d547['as'],'attributes':_0x31d547[_0x29b809('0x0')]};}):[]};}):[]};}):[]:[]})[_0x54d57d('0x6')](function(_0x55e870){const _0x5a22a7=_0x54d57d;logger[_0x5a22a7('0xa')](_0x5a22a7('0x9'),_0x1efc03),logger[_0x5a22a7('0x4')](_0x5a22a7('0x9'),_0x1efc03,JSON[_0x5a22a7('0x8')](_0x55e870)),_0x301d6f(_0x55e870);})[_0x54d57d('0x13')](function(_0x53ed1c){const _0xcc541f=_0x54d57d;logger[_0xcc541f('0xd')](_0xcc541f('0x9'),_0x53ed1c[_0xcc541f('0x12')],_0x1efc03),_0x2e3d13(_0x406457[_0xcc541f('0xd')](0x1f4,_0x53ed1c[_0xcc541f('0x12')]));});});},exports[_0x9a41d('0x1')]=function(_0x24db7d){const _0x3db2b0=this;return new Promise(function(_0x20fc98,_0x3cf901){const _0x3443e5=a423_0x394c;return db[_0x3443e5('0x5')][_0x3443e5('0xe')]({'raw':_0x24db7d[_0x3443e5('0x15')]?_0x24db7d[_0x3443e5('0x15')][_0x3443e5('0x1a')]===undefined?!![]:![]:!![],'where':_0x24db7d[_0x3443e5('0x15')]?_0x24db7d[_0x3443e5('0x15')][_0x3443e5('0x17')]||null:null,'attributes':_0x24db7d['options']?_0x24db7d[_0x3443e5('0x15')]['attributes']||null:null,'include':_0x24db7d[_0x3443e5('0x15')]?_0x24db7d[_0x3443e5('0x15')][_0x3443e5('0x19')]?_['map'](_0x24db7d['options'][_0x3443e5('0x19')],function(_0x3e1a8e){const _0x4cbacf=_0x3443e5;return{'model':db[_0x3e1a8e[_0x4cbacf('0x3')]],'as':_0x3e1a8e['as'],'attributes':_0x3e1a8e[_0x4cbacf('0x0')],'include':_0x3e1a8e[_0x4cbacf('0x19')]?_['map'](_0x3e1a8e[_0x4cbacf('0x19')],function(_0x235eff){const _0x206ccf=_0x4cbacf;return{'model':db[_0x235eff['model']],'as':_0x235eff['as'],'attributes':_0x235eff[_0x206ccf('0x0')],'include':_0x235eff[_0x206ccf('0x19')]?_[_0x206ccf('0x10')](_0x235eff['include'],function(_0x1a0d29){return{'model':db[_0x1a0d29['model']],'as':_0x1a0d29['as'],'attributes':_0x1a0d29['attributes']};}):[]};}):[]};}):[]:[]})[_0x3443e5('0x6')](function(_0x50ec4a){const _0x27b4d4=_0x3443e5;logger[_0x27b4d4('0xa')](_0x27b4d4('0x1'),_0x24db7d),logger[_0x27b4d4('0x4')](_0x27b4d4('0x1'),_0x24db7d,JSON[_0x27b4d4('0x8')](_0x50ec4a)),_0x20fc98(_0x50ec4a);})[_0x3443e5('0x13')](function(_0x3c8b2f){const _0x11cf05=_0x3443e5;logger[_0x11cf05('0xd')](_0x11cf05('0x1'),_0x3c8b2f['message'],_0x24db7d),_0x3cf901(_0x3db2b0[_0x11cf05('0xd')](0x1f4,_0x3c8b2f[_0x11cf05('0x12')]));});});}; \ No newline at end of file +const a423_0x8efb=['MailQueue','findAll','then','raw','stringify','catch','message','debug','../../config/logger','map','register','../../mysqldb','../../rediscache','error','model','info','rpc','where','options','findOne','ShowMailQueue','GetMailQueue','include','attributes'];(function(_0x275e61,_0x8efbf0){const _0x293041=function(_0x34c723){while(--_0x34c723){_0x275e61['push'](_0x275e61['shift']());}};_0x293041(++_0x8efbf0);}(a423_0x8efb,0x65));const a423_0x2930=function(_0x275e61,_0x8efbf0){_0x275e61=_0x275e61-0x0;let _0x293041=a423_0x8efb[_0x275e61];return _0x293041;};const _0x1dd5cd=a423_0x2930;'use strict';const _=require('lodash'),db=require(_0x1dd5cd('0x6'))['db'],logger=require(_0x1dd5cd('0x3'))(_0x1dd5cd('0xb')),{getSocket}=require(_0x1dd5cd('0x7')),socket=getSocket();require('./mailQueue.socket')[_0x1dd5cd('0x5')](socket),exports['GetMailQueue']=function(_0x34c723){const _0x5d5082=this;return new Promise(function(_0x6b22fa,_0x21ea11){const _0x5465fd=a423_0x2930;return db[_0x5465fd('0x13')][_0x5465fd('0x14')]({'raw':_0x34c723[_0x5465fd('0xd')]?_0x34c723[_0x5465fd('0xd')][_0x5465fd('0x16')]===undefined?!![]:![]:!![],'where':_0x34c723['options']?_0x34c723['options'][_0x5465fd('0xc')]||null:null,'attributes':_0x34c723[_0x5465fd('0xd')]?_0x34c723[_0x5465fd('0xd')][_0x5465fd('0x12')]||null:null,'limit':_0x34c723['options']?_0x34c723[_0x5465fd('0xd')]['limit']||null:null,'include':_0x34c723[_0x5465fd('0xd')]?_0x34c723[_0x5465fd('0xd')][_0x5465fd('0x11')]?_['map'](_0x34c723[_0x5465fd('0xd')][_0x5465fd('0x11')],function(_0x3ee3f1){const _0x20b185=_0x5465fd;return{'model':db[_0x3ee3f1[_0x20b185('0x9')]],'as':_0x3ee3f1['as'],'attributes':_0x3ee3f1[_0x20b185('0x12')],'include':_0x3ee3f1[_0x20b185('0x11')]?_[_0x20b185('0x4')](_0x3ee3f1[_0x20b185('0x11')],function(_0xaa0285){const _0x3fe030=_0x20b185;return{'model':db[_0xaa0285[_0x3fe030('0x9')]],'as':_0xaa0285['as'],'attributes':_0xaa0285[_0x3fe030('0x12')],'include':_0xaa0285[_0x3fe030('0x11')]?_['map'](_0xaa0285['include'],function(_0x4aa451){const _0x2760c7=_0x3fe030;return{'model':db[_0x4aa451[_0x2760c7('0x9')]],'as':_0x4aa451['as'],'attributes':_0x4aa451[_0x2760c7('0x12')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x5397fb){const _0x5b09b=_0x5465fd;logger[_0x5b09b('0xa')](_0x5b09b('0x10'),_0x34c723),logger[_0x5b09b('0x2')](_0x5b09b('0x10'),_0x34c723,JSON['stringify'](_0x5397fb)),_0x6b22fa(_0x5397fb);})[_0x5465fd('0x0')](function(_0x4c45c5){const _0x2b9f28=_0x5465fd;logger[_0x2b9f28('0x8')](_0x2b9f28('0x10'),_0x4c45c5['message'],_0x34c723),_0x21ea11(_0x5d5082[_0x2b9f28('0x8')](0x1f4,_0x4c45c5[_0x2b9f28('0x1')]));});});},exports['ShowMailQueue']=function(_0x2c0c07){const _0x160034=this;return new Promise(function(_0x7a0c96,_0x217d6c){const _0xd931dc=a423_0x2930;return db[_0xd931dc('0x13')][_0xd931dc('0xe')]({'raw':_0x2c0c07[_0xd931dc('0xd')]?_0x2c0c07['options'][_0xd931dc('0x16')]===undefined?!![]:![]:!![],'where':_0x2c0c07[_0xd931dc('0xd')]?_0x2c0c07['options']['where']||null:null,'attributes':_0x2c0c07[_0xd931dc('0xd')]?_0x2c0c07[_0xd931dc('0xd')][_0xd931dc('0x12')]||null:null,'include':_0x2c0c07[_0xd931dc('0xd')]?_0x2c0c07[_0xd931dc('0xd')][_0xd931dc('0x11')]?_[_0xd931dc('0x4')](_0x2c0c07['options']['include'],function(_0xc2b0d7){const _0x2b6204=_0xd931dc;return{'model':db[_0xc2b0d7[_0x2b6204('0x9')]],'as':_0xc2b0d7['as'],'attributes':_0xc2b0d7[_0x2b6204('0x12')],'include':_0xc2b0d7[_0x2b6204('0x11')]?_['map'](_0xc2b0d7[_0x2b6204('0x11')],function(_0x4bb66d){const _0x1f7963=_0x2b6204;return{'model':db[_0x4bb66d[_0x1f7963('0x9')]],'as':_0x4bb66d['as'],'attributes':_0x4bb66d['attributes'],'include':_0x4bb66d['include']?_[_0x1f7963('0x4')](_0x4bb66d['include'],function(_0x55477e){const _0x50ed05=_0x1f7963;return{'model':db[_0x55477e[_0x50ed05('0x9')]],'as':_0x55477e['as'],'attributes':_0x55477e[_0x50ed05('0x12')]};}):[]};}):[]};}):[]:[]})[_0xd931dc('0x15')](function(_0x3f488e){const _0x2dc3a4=_0xd931dc;logger['info'](_0x2dc3a4('0xf'),_0x2c0c07),logger[_0x2dc3a4('0x2')](_0x2dc3a4('0xf'),_0x2c0c07,JSON[_0x2dc3a4('0x17')](_0x3f488e)),_0x7a0c96(_0x3f488e);})[_0xd931dc('0x0')](function(_0x2ceac6){const _0x419bc1=_0xd931dc;logger[_0x419bc1('0x8')](_0x419bc1('0xf'),_0x2ceac6[_0x419bc1('0x1')],_0x2c0c07),_0x217d6c(_0x160034[_0x419bc1('0x8')](0x1f4,_0x2ceac6[_0x419bc1('0x1')]));});});}; \ No newline at end of file diff --git a/server/api/mailQueue/mailQueue.socket.js b/server/api/mailQueue/mailQueue.socket.js index c9a17b8..280c7ce 100644 --- a/server/api/mailQueue/mailQueue.socket.js +++ b/server/api/mailQueue/mailQueue.socket.js @@ -1 +1 @@ -const a424_0x4ff9=['save','update','./mailQueue.events'];(function(_0x331e84,_0x4ff940){const _0x46793c=function(_0x2e5867){while(--_0x2e5867){_0x331e84['push'](_0x331e84['shift']());}};_0x46793c(++_0x4ff940);}(a424_0x4ff9,0x141));const a424_0x4679=function(_0x331e84,_0x4ff940){_0x331e84=_0x331e84-0x0;let _0x46793c=a424_0x4ff9[_0x331e84];return _0x46793c;};const _0x40b1e3=a424_0x4679;'use strict';const MailQueueEvents=require(_0x40b1e3('0x2')),events=[_0x40b1e3('0x0'),'remove',_0x40b1e3('0x1')];function createListener(_0x2e5867,_0x50e066){return function(_0x2d7c03){_0x50e066['emit'](_0x2e5867,_0x2d7c03);};}exports['register']=function(_0x4941f9){for(let _0x507f33=0x0,_0x43bc0f=events['length'];_0x507f33<_0x43bc0f;_0x507f33++){const _0x1d7be9=events[_0x507f33],_0x310ac3=createListener('mailQueue:'+_0x1d7be9,_0x4941f9);MailQueueEvents['on'](_0x1d7be9,_0x310ac3);}}; \ No newline at end of file +const a424_0x4427=['register','mailQueue:','update','emit','./mailQueue.events'];(function(_0x3007da,_0x442730){const _0x3fc282=function(_0x31d956){while(--_0x31d956){_0x3007da['push'](_0x3007da['shift']());}};_0x3fc282(++_0x442730);}(a424_0x4427,0x1ad));const a424_0x3fc2=function(_0x3007da,_0x442730){_0x3007da=_0x3007da-0x0;let _0x3fc282=a424_0x4427[_0x3007da];return _0x3fc282;};const _0x4731b8=a424_0x3fc2;'use strict';const MailQueueEvents=require(_0x4731b8('0x0')),events=['save','remove',_0x4731b8('0x3')];function createListener(_0x31d956,_0x31045b){return function(_0x123866){const _0x2c8fac=a424_0x3fc2;_0x31045b[_0x2c8fac('0x4')](_0x31d956,_0x123866);};}exports[_0x4731b8('0x1')]=function(_0x85f171){const _0x2df0dd=_0x4731b8;for(let _0x5c8da7=0x0,_0x39314a=events['length'];_0x5c8da7<_0x39314a;_0x5c8da7++){const _0x1531dc=events[_0x5c8da7],_0x2f35a8=createListener(_0x2df0dd('0x2')+_0x1531dc,_0x85f171);MailQueueEvents['on'](_0x1531dc,_0x2f35a8);}}; \ No newline at end of file diff --git a/server/api/mailQueueReport/index.js b/server/api/mailQueueReport/index.js index a23a6af..8f587dd 100644 --- a/server/api/mailQueueReport/index.js +++ b/server/api/mailQueueReport/index.js @@ -1 +1 @@ -const a425_0x22c1=['destroy','show','../../components/auth/service','express','/:id','Router','get','exports','index','describe','create','put','/describe','isAuthenticated'];(function(_0x4fdb74,_0x22c1d0){const _0x6cc05a=function(_0x2c8f0f){while(--_0x2c8f0f){_0x4fdb74['push'](_0x4fdb74['shift']());}};_0x6cc05a(++_0x22c1d0);}(a425_0x22c1,0x129));const a425_0x6cc0=function(_0x4fdb74,_0x22c1d0){_0x4fdb74=_0x4fdb74-0x0;let _0x6cc05a=a425_0x22c1[_0x4fdb74];return _0x6cc05a;};const _0x1d2da1=a425_0x6cc0;'use strict';const express=require(_0x1d2da1('0x0')),router=express[_0x1d2da1('0x2')](),auth=require(_0x1d2da1('0xd')),controller=require('./mailQueueReport.controller');router['get']('/',auth['isAuthenticated'](),controller[_0x1d2da1('0x5')]),router[_0x1d2da1('0x3')](_0x1d2da1('0x9'),auth[_0x1d2da1('0xa')](),controller[_0x1d2da1('0x6')]),router[_0x1d2da1('0x3')]('/:id',auth[_0x1d2da1('0xa')](),controller[_0x1d2da1('0xc')]),router['post']('/',auth[_0x1d2da1('0xa')](),controller[_0x1d2da1('0x7')]),router[_0x1d2da1('0x8')](_0x1d2da1('0x1'),auth[_0x1d2da1('0xa')](),controller['update']),router['delete'](_0x1d2da1('0x1'),auth[_0x1d2da1('0xa')](),controller[_0x1d2da1('0xb')]),module[_0x1d2da1('0x4')]=router; \ No newline at end of file +const a425_0x50f3=['create','post','isAuthenticated','../../components/auth/service','get','describe','/describe','/:id','index','put','update','Router','show','delete'];(function(_0x5bdbe6,_0x50f34c){const _0x588938=function(_0x55cd78){while(--_0x55cd78){_0x5bdbe6['push'](_0x5bdbe6['shift']());}};_0x588938(++_0x50f34c);}(a425_0x50f3,0x182));const a425_0x5889=function(_0x5bdbe6,_0x50f34c){_0x5bdbe6=_0x5bdbe6-0x0;let _0x588938=a425_0x50f3[_0x5bdbe6];return _0x588938;};const _0x380b9e=a425_0x5889;'use strict';const express=require('express'),router=express[_0x380b9e('0x3')](),auth=require(_0x380b9e('0x9')),controller=require('./mailQueueReport.controller');router[_0x380b9e('0xa')]('/',auth[_0x380b9e('0x8')](),controller[_0x380b9e('0x0')]),router[_0x380b9e('0xa')](_0x380b9e('0xc'),auth['isAuthenticated'](),controller[_0x380b9e('0xb')]),router[_0x380b9e('0xa')](_0x380b9e('0xd'),auth[_0x380b9e('0x8')](),controller[_0x380b9e('0x4')]),router[_0x380b9e('0x7')]('/',auth[_0x380b9e('0x8')](),controller[_0x380b9e('0x6')]),router[_0x380b9e('0x1')](_0x380b9e('0xd'),auth['isAuthenticated'](),controller[_0x380b9e('0x2')]),router[_0x380b9e('0x5')](_0x380b9e('0xd'),auth[_0x380b9e('0x8')](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/mailQueueReport/mailQueueReport.attributes.js b/server/api/mailQueueReport/mailQueueReport.attributes.js index 37c1713..55c017e 100644 --- a/server/api/mailQueueReport/mailQueueReport.attributes.js +++ b/server/api/mailQueueReport/mailQueueReport.attributes.js @@ -1 +1 @@ -const a426_0x2cae=['sequelize','DATE','STRING'];(function(_0x15ea54,_0x2cae32){const _0x196ce3=function(_0xc04b6){while(--_0xc04b6){_0x15ea54['push'](_0x15ea54['shift']());}};_0x196ce3(++_0x2cae32);}(a426_0x2cae,0x14c));const a426_0x196c=function(_0x15ea54,_0x2cae32){_0x15ea54=_0x15ea54-0x0;let _0x196ce3=a426_0x2cae[_0x15ea54];return _0x196ce3;};const _0x3e5a22=a426_0x196c;'use strict';const Sequelize=require(_0x3e5a22('0x1'));module['exports']={'uniqueid':{'type':Sequelize[_0x3e5a22('0x0')],'allowNull':![]},'from':{'type':Sequelize['STRING']},'joinAt':{'type':Sequelize[_0x3e5a22('0x2')]},'leaveAt':{'type':Sequelize[_0x3e5a22('0x2')]},'acceptAt':{'type':Sequelize[_0x3e5a22('0x2')]},'exitAt':{'type':Sequelize[_0x3e5a22('0x2')]},'reason':{'type':Sequelize[_0x3e5a22('0x0')]}}; \ No newline at end of file +const a426_0x54f3=['exports','sequelize','DATE','STRING'];(function(_0x5d9613,_0x54f3fc){const _0x5973c4=function(_0x45033e){while(--_0x45033e){_0x5d9613['push'](_0x5d9613['shift']());}};_0x5973c4(++_0x54f3fc);}(a426_0x54f3,0xe9));const a426_0x5973=function(_0x5d9613,_0x54f3fc){_0x5d9613=_0x5d9613-0x0;let _0x5973c4=a426_0x54f3[_0x5d9613];return _0x5973c4;};const _0x32f31b=a426_0x5973;'use strict';const Sequelize=require(_0x32f31b('0x0'));module[_0x32f31b('0x3')]={'uniqueid':{'type':Sequelize[_0x32f31b('0x2')],'allowNull':![]},'from':{'type':Sequelize[_0x32f31b('0x2')]},'joinAt':{'type':Sequelize[_0x32f31b('0x1')]},'leaveAt':{'type':Sequelize[_0x32f31b('0x1')]},'acceptAt':{'type':Sequelize[_0x32f31b('0x1')]},'exitAt':{'type':Sequelize[_0x32f31b('0x1')]},'reason':{'type':Sequelize[_0x32f31b('0x2')]}}; \ No newline at end of file diff --git a/server/api/mailQueueReport/mailQueueReport.controller.js b/server/api/mailQueueReport/mailQueueReport.controller.js index 5121845..8549629 100644 --- a/server/api/mailQueueReport/mailQueueReport.controller.js +++ b/server/api/mailQueueReport/mailQueueReport.controller.js @@ -1 +1 @@ -const a427_0x20a5=['rows','keys','api','attributes','count','key','params','send','model','describe','limit','like','MailQueueReport','map','query','create','show','catch','undefined','body','where','rawAttributes','findOne','then','status','json','intersection','name','offset','nolimit','includeAll','../../mysqldb','options','include','fields','destroy','sequelize','length','merge','filter','../../components/parsers/qs','sort','filters'];(function(_0x41af1a,_0x20a5a5){const _0x558739=function(_0x279d0e){while(--_0x279d0e){_0x41af1a['push'](_0x41af1a['shift']());}};_0x558739(++_0x20a5a5);}(a427_0x20a5,0x16a));const a427_0x5587=function(_0x41af1a,_0x20a5a5){_0x41af1a=_0x41af1a-0x0;let _0x558739=a427_0x20a5[_0x41af1a];return _0x558739;};const _0x254422=a427_0x5587;'use strict';const _=require('lodash'),qs=require(_0x254422('0x16')),logger=require('../../config/logger')(_0x254422('0x1b')),db=require(_0x254422('0xd'))['db'],{Op}=require(_0x254422('0x12'));function respondWithResult(_0x279d0e,_0x4d6967){return _0x4d6967=_0x4d6967||0xc8,function(_0x53db32){const _0x1e704d=a427_0x5587;if(_0x53db32)return _0x279d0e[_0x1e704d('0x6')](_0x4d6967)[_0x1e704d('0x7')](_0x53db32);};}function respondWithFilteredResult(_0x2dd347,_0x21156c){return function(_0x1ce3d0){const _0x24c513=a427_0x5587;if(_0x1ce3d0){const _0x2f3d17=_0x1ce3d0['count'],_0x595c37=_0x21156c[_0x24c513('0xa')];let _0x101758=_0x21156c[_0x24c513('0xa')]+_0x21156c[_0x24c513('0x23')],_0x151a8a;return _0x101758>=_0x2f3d17?(_0x101758=_0x2f3d17,_0x151a8a=0xc8):_0x151a8a=0xce,_0x2dd347[_0x24c513('0x6')](_0x151a8a),_0x2dd347['set']('Content-Range',_0x595c37+'-'+_0x101758+'/'+_0x2f3d17)[_0x24c513('0x7')](_0x1ce3d0);}return null;};}function saveUpdates(_0x5e43e3){return function(_0x462a0d){if(_0x462a0d)return _0x462a0d['update'](_0x5e43e3)['then'](function(_0x1233af){return _0x1233af;});return null;};}function removeEntity(_0x3341fd){return function(_0x21fc7f){const _0xc027d3=a427_0x5587;if(_0x21fc7f)return _0x21fc7f[_0xc027d3('0x11')]()[_0xc027d3('0x5')](function(){const _0xe3c1f0=_0xc027d3;_0x3341fd[_0xe3c1f0('0x6')](0xcc)['end']();});};}function handleEntityNotFound(_0x5485ce){return function(_0x34abd9){return!_0x34abd9&&_0x5485ce['sendStatus'](0x194),_0x34abd9;};}function handleError(_0x1dbe5a,_0x47416e){return _0x47416e=_0x47416e||0x1f4,function(_0x1a8cf3){const _0x2185e4=a427_0x5587;logger['error'](_0x1a8cf3['stack']),_0x1a8cf3[_0x2185e4('0x9')]&&delete _0x1a8cf3[_0x2185e4('0x9')],_0x1dbe5a[_0x2185e4('0x6')](_0x47416e)[_0x2185e4('0x20')](_0x1a8cf3);};}exports['index']=function(_0x477552,_0x43e31d){const _0x3555e7=_0x254422;let _0x2809da={};const _0x43f6af={},_0x569fc4={'count':0x0,'rows':[]},_0x3a13bf=_[_0x3555e7('0x26')](db[_0x3555e7('0x25')]['rawAttributes'],function(_0x309b4a){const _0x1813d9=_0x3555e7;return{'name':_0x309b4a['fieldName'],'type':_0x309b4a['type'][_0x1813d9('0x1e')]};});_0x43f6af[_0x3555e7('0x21')]=_[_0x3555e7('0x26')](_0x3a13bf,_0x3555e7('0x9')),_0x43f6af[_0x3555e7('0x27')]=_[_0x3555e7('0x1a')](_0x477552[_0x3555e7('0x27')]),_0x43f6af[_0x3555e7('0x18')]=_['intersection'](_0x43f6af['model'],_0x43f6af['query']),_0x2809da['attributes']=_[_0x3555e7('0x8')](_0x43f6af['model'],qs['fields'](_0x477552[_0x3555e7('0x27')][_0x3555e7('0x10')])),_0x2809da['attributes']=_0x2809da[_0x3555e7('0x1c')][_0x3555e7('0x13')]?_0x2809da[_0x3555e7('0x1c')]:_0x43f6af[_0x3555e7('0x21')];typeof _0x477552[_0x3555e7('0x27')][_0x3555e7('0xb')]===_0x3555e7('0x0')&&(_0x2809da[_0x3555e7('0x23')]=qs['limit'](_0x477552[_0x3555e7('0x27')][_0x3555e7('0x23')]),_0x2809da[_0x3555e7('0xa')]=qs['offset'](_0x477552['query']['offset']));_0x2809da['order']=qs['sort'](_0x477552[_0x3555e7('0x27')][_0x3555e7('0x17')]),_0x2809da[_0x3555e7('0x2')]=qs[_0x3555e7('0x18')](_['pick'](_0x477552['query'],_0x43f6af['filters']),_0x3a13bf);_0x477552['query'][_0x3555e7('0x15')]&&(_0x2809da['where']=_[_0x3555e7('0x14')](_0x2809da['where'],{[Op['or']]:_[_0x3555e7('0x26')](_0x3a13bf,function(_0xac9d7a){const _0x1c6675=_0x3555e7;if(_0xac9d7a['type']!=='VIRTUAL'){const _0x5b188d={};return _0x5b188d[_0xac9d7a[_0x1c6675('0x9')]]={[Op[_0x1c6675('0x24')]]:'%'+_0x477552[_0x1c6675('0x27')][_0x1c6675('0x15')]+'%'},_0x5b188d;}})}));_0x2809da=_['merge']({},_0x2809da,_0x477552[_0x3555e7('0xe')]);const _0x28bd2b={'where':_0x2809da[_0x3555e7('0x2')]};return db[_0x3555e7('0x25')]['count'](_0x28bd2b)[_0x3555e7('0x5')](function(_0x3e01c1){const _0x482181=_0x3555e7;return _0x569fc4[_0x482181('0x1d')]=_0x3e01c1,_0x477552[_0x482181('0x27')][_0x482181('0xc')]&&(_0x2809da['include']=[{'all':!![]}]),db[_0x482181('0x25')]['findAll'](_0x2809da);})[_0x3555e7('0x5')](function(_0x718804){const _0x32037f=_0x3555e7;return _0x569fc4[_0x32037f('0x19')]=_0x718804,_0x569fc4;})['then'](respondWithFilteredResult(_0x43e31d,_0x2809da))['catch'](handleError(_0x43e31d,null));},exports[_0x254422('0x29')]=function(_0x99022,_0x24cce8){const _0xb4343c=_0x254422;let _0x1c78a9={'raw':!![],'where':{'id':_0x99022[_0xb4343c('0x1f')]['id']}};const _0x27ecd3={};return _0x27ecd3['model']=_[_0xb4343c('0x1a')](db[_0xb4343c('0x25')][_0xb4343c('0x3')]),_0x27ecd3[_0xb4343c('0x27')]=_['keys'](_0x99022['query']),_0x27ecd3[_0xb4343c('0x18')]=_[_0xb4343c('0x8')](_0x27ecd3['model'],_0x27ecd3[_0xb4343c('0x27')]),_0x1c78a9['attributes']=_[_0xb4343c('0x8')](_0x27ecd3[_0xb4343c('0x21')],qs[_0xb4343c('0x10')](_0x99022[_0xb4343c('0x27')][_0xb4343c('0x10')])),_0x1c78a9['attributes']=_0x1c78a9[_0xb4343c('0x1c')]['length']?_0x1c78a9['attributes']:_0x27ecd3['model'],_0x99022[_0xb4343c('0x27')][_0xb4343c('0xc')]&&(_0x1c78a9[_0xb4343c('0xf')]=[{'all':!![]}]),_0x1c78a9=_['merge']({},_0x1c78a9,_0x99022['options']),db[_0xb4343c('0x25')][_0xb4343c('0x4')](_0x1c78a9)[_0xb4343c('0x5')](handleEntityNotFound(_0x24cce8,null))['then'](respondWithResult(_0x24cce8,null))['catch'](handleError(_0x24cce8,null));},exports[_0x254422('0x28')]=function(_0xe03135,_0x683552){const _0x2af0e3=_0x254422;return db[_0x2af0e3('0x25')][_0x2af0e3('0x28')](_0xe03135[_0x2af0e3('0x1')],{})['then'](respondWithResult(_0x683552,0xc9))['catch'](handleError(_0x683552,null));},exports['update']=function(_0x4a2350,_0x450500){const _0x53a3cc=_0x254422;return _0x4a2350[_0x53a3cc('0x1')]['id']&&delete _0x4a2350[_0x53a3cc('0x1')]['id'],db['MailQueueReport'][_0x53a3cc('0x4')]({'where':{'id':_0x4a2350[_0x53a3cc('0x1f')]['id']}})[_0x53a3cc('0x5')](handleEntityNotFound(_0x450500,null))[_0x53a3cc('0x5')](saveUpdates(_0x4a2350[_0x53a3cc('0x1')],null))['then'](respondWithResult(_0x450500,null))[_0x53a3cc('0x2a')](handleError(_0x450500,null));},exports['destroy']=function(_0x215f0d,_0x28ab6b){const _0x5a7e6b=_0x254422;return db['MailQueueReport'][_0x5a7e6b('0x4')]({'where':{'id':_0x215f0d[_0x5a7e6b('0x1f')]['id']}})[_0x5a7e6b('0x5')](handleEntityNotFound(_0x28ab6b,null))[_0x5a7e6b('0x5')](removeEntity(_0x28ab6b,null))[_0x5a7e6b('0x2a')](handleError(_0x28ab6b,null));},exports[_0x254422('0x22')]=function(_0x454a16,_0x275307){const _0x14ed4b=_0x254422;return db[_0x14ed4b('0x25')][_0x14ed4b('0x22')]()[_0x14ed4b('0x5')](respondWithResult(_0x275307,null))['catch'](handleError(_0x275307,null));}; \ No newline at end of file +const a427_0x2ca4=['then','Content-Range','name','type','../../mysqldb','sendStatus','end','attributes','like','show','sequelize','../../components/parsers/qs','model','MailQueueReport','body','params','update','fields','destroy','key','include','where','json','filter','rawAttributes','catch','order','options','lodash','rows','describe','map','intersection','index','undefined','query','merge','create','../../config/logger','keys','send','status','limit','length','findAll','filters','offset','api','count','sort','pick','set','stack','includeAll'];(function(_0x21927b,_0x2ca45d){const _0x1f7bfa=function(_0x7b1c17){while(--_0x7b1c17){_0x21927b['push'](_0x21927b['shift']());}};_0x1f7bfa(++_0x2ca45d);}(a427_0x2ca4,0x19f));const a427_0x1f7b=function(_0x21927b,_0x2ca45d){_0x21927b=_0x21927b-0x0;let _0x1f7bfa=a427_0x2ca4[_0x21927b];return _0x1f7bfa;};const _0x3d890f=a427_0x1f7b;'use strict';const _=require(_0x3d890f('0x2d')),qs=require(_0x3d890f('0x1c')),logger=require(_0x3d890f('0x1'))(_0x3d890f('0xa')),db=require(_0x3d890f('0x15'))['db'],{Op}=require(_0x3d890f('0x1b'));function respondWithResult(_0x7b1c17,_0x111af1){return _0x111af1=_0x111af1||0xc8,function(_0x42f066){const _0x46e95e=a427_0x1f7b;if(_0x42f066)return _0x7b1c17['status'](_0x111af1)[_0x46e95e('0x27')](_0x42f066);};}function respondWithFilteredResult(_0x3901f7,_0x1a405b){return function(_0x102689){const _0xf665ab=a427_0x1f7b;if(_0x102689){const _0x29e5b2=_0x102689[_0xf665ab('0xb')],_0x38aedb=_0x1a405b['offset'];let _0x403dbb=_0x1a405b[_0xf665ab('0x9')]+_0x1a405b[_0xf665ab('0x5')],_0x4ea4db;return _0x403dbb>=_0x29e5b2?(_0x403dbb=_0x29e5b2,_0x4ea4db=0xc8):_0x4ea4db=0xce,_0x3901f7[_0xf665ab('0x4')](_0x4ea4db),_0x3901f7[_0xf665ab('0xe')](_0xf665ab('0x12'),_0x38aedb+'-'+_0x403dbb+'/'+_0x29e5b2)[_0xf665ab('0x27')](_0x102689);}return null;};}function saveUpdates(_0x215260){return function(_0x1e0b02){const _0x498362=a427_0x1f7b;if(_0x1e0b02)return _0x1e0b02[_0x498362('0x21')](_0x215260)[_0x498362('0x11')](function(_0x5bbcc7){return _0x5bbcc7;});return null;};}function removeEntity(_0x71b04b){return function(_0x148a26){const _0x32412a=a427_0x1f7b;if(_0x148a26)return _0x148a26[_0x32412a('0x23')]()[_0x32412a('0x11')](function(){const _0x213bce=_0x32412a;_0x71b04b[_0x213bce('0x4')](0xcc)[_0x213bce('0x17')]();});};}function handleEntityNotFound(_0x36c0ba){return function(_0x196cd5){const _0x1ce473=a427_0x1f7b;return!_0x196cd5&&_0x36c0ba[_0x1ce473('0x16')](0x194),_0x196cd5;};}function handleError(_0x41849c,_0x2519ed){return _0x2519ed=_0x2519ed||0x1f4,function(_0x194b02){const _0x95f7c2=a427_0x1f7b;logger['error'](_0x194b02[_0x95f7c2('0xf')]),_0x194b02[_0x95f7c2('0x13')]&&delete _0x194b02[_0x95f7c2('0x13')],_0x41849c['status'](_0x2519ed)[_0x95f7c2('0x3')](_0x194b02);};}exports[_0x3d890f('0x32')]=function(_0x1895bc,_0x30adb1){const _0x4bc35b=_0x3d890f;let _0x449591={};const _0x15edfb={},_0x2e3821={'count':0x0,'rows':[]},_0x48dc06=_[_0x4bc35b('0x30')](db['MailQueueReport'][_0x4bc35b('0x29')],function(_0x4467a){const _0x34a664=_0x4bc35b;return{'name':_0x4467a['fieldName'],'type':_0x4467a['type'][_0x34a664('0x24')]};});_0x15edfb[_0x4bc35b('0x1d')]=_[_0x4bc35b('0x30')](_0x48dc06,_0x4bc35b('0x13')),_0x15edfb['query']=_[_0x4bc35b('0x2')](_0x1895bc[_0x4bc35b('0x34')]),_0x15edfb['filters']=_[_0x4bc35b('0x31')](_0x15edfb['model'],_0x15edfb[_0x4bc35b('0x34')]),_0x449591['attributes']=_[_0x4bc35b('0x31')](_0x15edfb['model'],qs[_0x4bc35b('0x22')](_0x1895bc[_0x4bc35b('0x34')][_0x4bc35b('0x22')])),_0x449591[_0x4bc35b('0x18')]=_0x449591[_0x4bc35b('0x18')][_0x4bc35b('0x6')]?_0x449591['attributes']:_0x15edfb[_0x4bc35b('0x1d')];typeof _0x1895bc['query']['nolimit']===_0x4bc35b('0x33')&&(_0x449591['limit']=qs['limit'](_0x1895bc['query'][_0x4bc35b('0x5')]),_0x449591['offset']=qs[_0x4bc35b('0x9')](_0x1895bc[_0x4bc35b('0x34')]['offset']));_0x449591[_0x4bc35b('0x2b')]=qs['sort'](_0x1895bc['query'][_0x4bc35b('0xc')]),_0x449591[_0x4bc35b('0x26')]=qs['filters'](_[_0x4bc35b('0xd')](_0x1895bc['query'],_0x15edfb['filters']),_0x48dc06);_0x1895bc[_0x4bc35b('0x34')]['filter']&&(_0x449591['where']=_[_0x4bc35b('0x35')](_0x449591[_0x4bc35b('0x26')],{[Op['or']]:_[_0x4bc35b('0x30')](_0x48dc06,function(_0x10eb8b){const _0x376c0d=_0x4bc35b;if(_0x10eb8b[_0x376c0d('0x14')]!=='VIRTUAL'){const _0x1bfa92={};return _0x1bfa92[_0x10eb8b[_0x376c0d('0x13')]]={[Op[_0x376c0d('0x19')]]:'%'+_0x1895bc[_0x376c0d('0x34')][_0x376c0d('0x28')]+'%'},_0x1bfa92;}})}));_0x449591=_[_0x4bc35b('0x35')]({},_0x449591,_0x1895bc['options']);const _0x126861={'where':_0x449591[_0x4bc35b('0x26')]};return db[_0x4bc35b('0x1e')][_0x4bc35b('0xb')](_0x126861)['then'](function(_0x4f153c){const _0x39b5b3=_0x4bc35b;return _0x2e3821['count']=_0x4f153c,_0x1895bc[_0x39b5b3('0x34')]['includeAll']&&(_0x449591['include']=[{'all':!![]}]),db[_0x39b5b3('0x1e')][_0x39b5b3('0x7')](_0x449591);})[_0x4bc35b('0x11')](function(_0x1b2444){const _0x18ea4d=_0x4bc35b;return _0x2e3821[_0x18ea4d('0x2e')]=_0x1b2444,_0x2e3821;})[_0x4bc35b('0x11')](respondWithFilteredResult(_0x30adb1,_0x449591))[_0x4bc35b('0x2a')](handleError(_0x30adb1,null));},exports[_0x3d890f('0x1a')]=function(_0x5140a6,_0x4ce130){const _0x422529=_0x3d890f;let _0x40a30b={'raw':!![],'where':{'id':_0x5140a6[_0x422529('0x20')]['id']}};const _0x51e260={};return _0x51e260[_0x422529('0x1d')]=_['keys'](db[_0x422529('0x1e')][_0x422529('0x29')]),_0x51e260[_0x422529('0x34')]=_[_0x422529('0x2')](_0x5140a6[_0x422529('0x34')]),_0x51e260[_0x422529('0x8')]=_[_0x422529('0x31')](_0x51e260[_0x422529('0x1d')],_0x51e260['query']),_0x40a30b[_0x422529('0x18')]=_[_0x422529('0x31')](_0x51e260['model'],qs[_0x422529('0x22')](_0x5140a6[_0x422529('0x34')][_0x422529('0x22')])),_0x40a30b[_0x422529('0x18')]=_0x40a30b[_0x422529('0x18')]['length']?_0x40a30b[_0x422529('0x18')]:_0x51e260[_0x422529('0x1d')],_0x5140a6[_0x422529('0x34')][_0x422529('0x10')]&&(_0x40a30b[_0x422529('0x25')]=[{'all':!![]}]),_0x40a30b=_[_0x422529('0x35')]({},_0x40a30b,_0x5140a6[_0x422529('0x2c')]),db[_0x422529('0x1e')]['findOne'](_0x40a30b)[_0x422529('0x11')](handleEntityNotFound(_0x4ce130,null))[_0x422529('0x11')](respondWithResult(_0x4ce130,null))[_0x422529('0x2a')](handleError(_0x4ce130,null));},exports[_0x3d890f('0x0')]=function(_0x481dbc,_0x10aea6){const _0x3413c4=_0x3d890f;return db[_0x3413c4('0x1e')][_0x3413c4('0x0')](_0x481dbc['body'],{})[_0x3413c4('0x11')](respondWithResult(_0x10aea6,0xc9))['catch'](handleError(_0x10aea6,null));},exports[_0x3d890f('0x21')]=function(_0x4b8f18,_0x212fc4){const _0x5965ef=_0x3d890f;return _0x4b8f18[_0x5965ef('0x1f')]['id']&&delete _0x4b8f18[_0x5965ef('0x1f')]['id'],db[_0x5965ef('0x1e')]['findOne']({'where':{'id':_0x4b8f18[_0x5965ef('0x20')]['id']}})[_0x5965ef('0x11')](handleEntityNotFound(_0x212fc4,null))['then'](saveUpdates(_0x4b8f18[_0x5965ef('0x1f')],null))[_0x5965ef('0x11')](respondWithResult(_0x212fc4,null))[_0x5965ef('0x2a')](handleError(_0x212fc4,null));},exports[_0x3d890f('0x23')]=function(_0x22c88b,_0x490f7a){const _0x1e05c7=_0x3d890f;return db[_0x1e05c7('0x1e')]['findOne']({'where':{'id':_0x22c88b[_0x1e05c7('0x20')]['id']}})['then'](handleEntityNotFound(_0x490f7a,null))[_0x1e05c7('0x11')](removeEntity(_0x490f7a,null))[_0x1e05c7('0x2a')](handleError(_0x490f7a,null));},exports['describe']=function(_0x358ff6,_0xc64e10){const _0x2e1968=_0x3d890f;return db[_0x2e1968('0x1e')][_0x2e1968('0x2f')]()[_0x2e1968('0x11')](respondWithResult(_0xc64e10,null))[_0x2e1968('0x2a')](handleError(_0xc64e10,null));}; \ No newline at end of file diff --git a/server/api/mailQueueReport/mailQueueReport.model.js b/server/api/mailQueueReport/mailQueueReport.model.js index 50dfb52..378d9fe 100644 --- a/server/api/mailQueueReport/mailQueueReport.model.js +++ b/server/api/mailQueueReport/mailQueueReport.model.js @@ -1 +1 @@ -const a428_0x32b5=['MailQueueReport','report_mail_queue','uniqueid','exports','define'];(function(_0x26a67c,_0x32b535){const _0x166d8f=function(_0x2cb41a){while(--_0x2cb41a){_0x26a67c['push'](_0x26a67c['shift']());}};_0x166d8f(++_0x32b535);}(a428_0x32b5,0x1d3));const a428_0x166d=function(_0x26a67c,_0x32b535){_0x26a67c=_0x26a67c-0x0;let _0x166d8f=a428_0x32b5[_0x26a67c];return _0x166d8f;};const _0x135f44=a428_0x166d;'use strict';const attributes=require('./mailQueueReport.attributes');module[_0x135f44('0x1')]=function(_0x2cb41a){const _0x425827=_0x135f44,_0x173d22=_0x2cb41a[_0x425827('0x2')](_0x425827('0x3'),attributes,{'tableName':_0x425827('0x4'),'paranoid':![],'indexes':[{'name':_0x425827('0x0'),'fields':[_0x425827('0x0')]}],'timestamps':!![]});return _0x173d22;}; \ No newline at end of file +const a428_0x7ad7=['MailQueueReport','exports','./mailQueueReport.attributes','uniqueid','report_mail_queue'];(function(_0x5d05db,_0x7ad75){const _0x11c746=function(_0x1917ae){while(--_0x1917ae){_0x5d05db['push'](_0x5d05db['shift']());}};_0x11c746(++_0x7ad75);}(a428_0x7ad7,0x125));const a428_0x11c7=function(_0x5d05db,_0x7ad75){_0x5d05db=_0x5d05db-0x0;let _0x11c746=a428_0x7ad7[_0x5d05db];return _0x11c746;};const _0x2edb5e=a428_0x11c7;'use strict';const attributes=require(_0x2edb5e('0x4'));module[_0x2edb5e('0x3')]=function(_0x1917ae){const _0x4d38c8=_0x2edb5e,_0x38df63=_0x1917ae['define'](_0x4d38c8('0x2'),attributes,{'tableName':_0x4d38c8('0x1'),'paranoid':![],'indexes':[{'name':_0x4d38c8('0x0'),'fields':[_0x4d38c8('0x0')]}],'timestamps':!![]});return _0x38df63;}; \ No newline at end of file diff --git a/server/api/mailQueueReport/mailQueueReport.rpc.js b/server/api/mailQueueReport/mailQueueReport.rpc.js index bb36d21..3037d7c 100644 --- a/server/api/mailQueueReport/mailQueueReport.rpc.js +++ b/server/api/mailQueueReport/mailQueueReport.rpc.js @@ -1 +1 @@ -const a429_0xc7a2=['info','message','MailQueueReport','create','UpdateMailQueueReport','stringify','rpc','raw','CreateMailQueueReport','../../mysqldb','options','../../config/logger','attributes','catch','body','debug','error','then','update'];(function(_0x5fd2e1,_0xc7a205){const _0x4df7eb=function(_0xb80243){while(--_0xb80243){_0x5fd2e1['push'](_0x5fd2e1['shift']());}};_0x4df7eb(++_0xc7a205);}(a429_0xc7a2,0xeb));const a429_0x4df7=function(_0x5fd2e1,_0xc7a205){_0x5fd2e1=_0x5fd2e1-0x0;let _0x4df7eb=a429_0xc7a2[_0x5fd2e1];return _0x4df7eb;};const _0x31ffb5=a429_0x4df7;'use strict';const db=require(_0x31ffb5('0x2'))['db'],logger=require(_0x31ffb5('0x4'))(_0x31ffb5('0x12'));exports['CreateMailQueueReport']=function(_0xb80243){const _0x494a59=this;return new Promise(function(_0xb417eb,_0x5f45a9){const _0x320c4e=a429_0x4df7;return db[_0x320c4e('0xe')][_0x320c4e('0xf')](_0xb80243[_0x320c4e('0x7')],{'raw':_0xb80243['options']?_0xb80243[_0x320c4e('0x3')][_0x320c4e('0x0')]===undefined?!![]:![]:!![]})[_0x320c4e('0xa')](function(_0x575e81){const _0x247d0a=_0x320c4e;logger[_0x247d0a('0xc')](_0x247d0a('0x1'),_0xb80243),logger[_0x247d0a('0x8')](_0x247d0a('0x1'),_0xb80243,JSON[_0x247d0a('0x11')](_0x575e81)),_0xb417eb(_0x575e81);})[_0x320c4e('0x6')](function(_0x3d7343){const _0x194829=_0x320c4e;logger[_0x194829('0x9')](_0x194829('0x1'),_0x3d7343[_0x194829('0xd')],_0xb80243),_0x5f45a9(_0x494a59['error'](0x1f4,_0x3d7343['message']));});});},exports[_0x31ffb5('0x10')]=function(_0x420af3){const _0x225472=this;return new Promise(function(_0x39d7b8,_0x404dd0){const _0x313ff9=a429_0x4df7;return db[_0x313ff9('0xe')][_0x313ff9('0xb')](_0x420af3[_0x313ff9('0x7')],{'raw':_0x420af3['options']?_0x420af3['options'][_0x313ff9('0x0')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x420af3[_0x313ff9('0x3')]?_0x420af3[_0x313ff9('0x3')]['where']||null:null,'attributes':_0x420af3['options']?_0x420af3[_0x313ff9('0x3')][_0x313ff9('0x5')]||null:null,'limit':_0x420af3[_0x313ff9('0x3')]?_0x420af3[_0x313ff9('0x3')]['limit']||null:null})[_0x313ff9('0xa')](function(_0x4143e3){const _0x4c9908=_0x313ff9;logger[_0x4c9908('0xc')]('UpdateMailQueueReport',_0x420af3),logger['debug']('UpdateMailQueueReport',_0x420af3,JSON[_0x4c9908('0x11')](_0x4143e3)),_0x39d7b8(_0x4143e3);})[_0x313ff9('0x6')](function(_0x5b6f12){const _0x473742=_0x313ff9;logger[_0x473742('0x9')](_0x473742('0x10'),_0x5b6f12['message'],_0x420af3),_0x404dd0(_0x225472[_0x473742('0x9')](0x1f4,_0x5b6f12['message']));});});}; \ No newline at end of file +const a429_0x46e1=['options','info','../../mysqldb','message','where','limit','attributes','body','UpdateMailQueueReport','raw','error','CreateMailQueueReport','then','stringify','MailQueueReport','create','rpc','catch'];(function(_0x44535f,_0x46e121){const _0x479a3b=function(_0x32c111){while(--_0x32c111){_0x44535f['push'](_0x44535f['shift']());}};_0x479a3b(++_0x46e121);}(a429_0x46e1,0x189));const a429_0x479a=function(_0x44535f,_0x46e121){_0x44535f=_0x44535f-0x0;let _0x479a3b=a429_0x46e1[_0x44535f];return _0x479a3b;};const _0x40eca2=a429_0x479a;'use strict';const db=require(_0x40eca2('0x5'))['db'],logger=require('../../config/logger')(_0x40eca2('0x1'));exports[_0x40eca2('0xe')]=function(_0x32c111){const _0x56a4f1=this;return new Promise(function(_0x26ad2c,_0x34559a){const _0x18f40f=a429_0x479a;return db[_0x18f40f('0x11')][_0x18f40f('0x0')](_0x32c111[_0x18f40f('0xa')],{'raw':_0x32c111['options']?_0x32c111[_0x18f40f('0x3')][_0x18f40f('0xc')]===undefined?!![]:![]:!![]})['then'](function(_0x3432c7){const _0x2b1afd=_0x18f40f;logger[_0x2b1afd('0x4')]('CreateMailQueueReport',_0x32c111),logger['debug'](_0x2b1afd('0xe'),_0x32c111,JSON[_0x2b1afd('0x10')](_0x3432c7)),_0x26ad2c(_0x3432c7);})[_0x18f40f('0x2')](function(_0x26ba2d){const _0x1bfefc=_0x18f40f;logger[_0x1bfefc('0xd')](_0x1bfefc('0xe'),_0x26ba2d['message'],_0x32c111),_0x34559a(_0x56a4f1[_0x1bfefc('0xd')](0x1f4,_0x26ba2d[_0x1bfefc('0x6')]));});});},exports['UpdateMailQueueReport']=function(_0x408c3a){const _0x49fcc8=this;return new Promise(function(_0x5d911e,_0x518b60){const _0x42dce9=a429_0x479a;return db[_0x42dce9('0x11')]['update'](_0x408c3a[_0x42dce9('0xa')],{'raw':_0x408c3a[_0x42dce9('0x3')]?_0x408c3a[_0x42dce9('0x3')][_0x42dce9('0xc')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x408c3a[_0x42dce9('0x3')]?_0x408c3a['options'][_0x42dce9('0x7')]||null:null,'attributes':_0x408c3a[_0x42dce9('0x3')]?_0x408c3a[_0x42dce9('0x3')][_0x42dce9('0x9')]||null:null,'limit':_0x408c3a[_0x42dce9('0x3')]?_0x408c3a[_0x42dce9('0x3')][_0x42dce9('0x8')]||null:null})[_0x42dce9('0xf')](function(_0x53bfcc){const _0x1b6b33=_0x42dce9;logger[_0x1b6b33('0x4')](_0x1b6b33('0xb'),_0x408c3a),logger['debug'](_0x1b6b33('0xb'),_0x408c3a,JSON[_0x1b6b33('0x10')](_0x53bfcc)),_0x5d911e(_0x53bfcc);})[_0x42dce9('0x2')](function(_0x1564c6){const _0x1db28a=_0x42dce9;logger['error'](_0x1db28a('0xb'),_0x1564c6[_0x1db28a('0x6')],_0x408c3a),_0x518b60(_0x49fcc8[_0x1db28a('0xd')](0x1f4,_0x1564c6['message']));});});}; \ No newline at end of file diff --git a/server/api/mailServerIn/index.js b/server/api/mailServerIn/index.js index 5034f6c..f7b5aae 100644 --- a/server/api/mailServerIn/index.js +++ b/server/api/mailServerIn/index.js @@ -1 +1 @@ -const a430_0x3945=['Router','express'];(function(_0x462886,_0x394534){const _0x51aa83=function(_0xa5014d){while(--_0xa5014d){_0x462886['push'](_0x462886['shift']());}};_0x51aa83(++_0x394534);}(a430_0x3945,0x192));const a430_0x51aa=function(_0x462886,_0x394534){_0x462886=_0x462886-0x0;let _0x51aa83=a430_0x3945[_0x462886];return _0x51aa83;};const _0x4ebf52=a430_0x51aa;'use strict';const express=require(_0x4ebf52('0x1')),router=express[_0x4ebf52('0x0')]();module['exports']=router; \ No newline at end of file +const a430_0x35fe=['Router','express','exports'];(function(_0x3f0c4e,_0x35fe62){const _0x2a9a3b=function(_0x228f2e){while(--_0x228f2e){_0x3f0c4e['push'](_0x3f0c4e['shift']());}};_0x2a9a3b(++_0x35fe62);}(a430_0x35fe,0xda));const a430_0x2a9a=function(_0x3f0c4e,_0x35fe62){_0x3f0c4e=_0x3f0c4e-0x0;let _0x2a9a3b=a430_0x35fe[_0x3f0c4e];return _0x2a9a3b;};const _0x115608=a430_0x2a9a;'use strict';const express=require(_0x115608('0x2')),router=express[_0x115608('0x1')]();module[_0x115608('0x0')]=router; \ No newline at end of file diff --git a/server/api/mailServerIn/mailServerIn.attributes.js b/server/api/mailServerIn/mailServerIn.attributes.js index 729051c..ee4db5f 100644 --- a/server/api/mailServerIn/mailServerIn.attributes.js +++ b/server/api/mailServerIn/mailServerIn.attributes.js @@ -1 +1 @@ -const a431_0x5020=['exports','STRING','INTEGER','sequelize','BOOLEAN','username','INBOX'];(function(_0x4307fc,_0x5020b1){const _0x447b23=function(_0x2006e2){while(--_0x2006e2){_0x4307fc['push'](_0x4307fc['shift']());}};_0x447b23(++_0x5020b1);}(a431_0x5020,0x1c2));const a431_0x447b=function(_0x4307fc,_0x5020b1){_0x4307fc=_0x4307fc-0x0;let _0x447b23=a431_0x5020[_0x4307fc];return _0x447b23;};const _0x11b302=a431_0x447b;'use strict';const Sequelize=require(_0x11b302('0x1'));module[_0x11b302('0x5')]={'description':{'type':Sequelize[_0x11b302('0x6')]},'host':{'type':Sequelize['STRING']},'authentication':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'user':{'type':Sequelize[_0x11b302('0x6')],'unique':_0x11b302('0x3')},'password':{'type':Sequelize[_0x11b302('0x6')]},'port':{'type':Sequelize['INTEGER']},'tls':{'type':Sequelize[_0x11b302('0x2')],'defaultValue':!![]},'mailbox':{'type':Sequelize['STRING'],'defaultValue':_0x11b302('0x4')},'connTimeout':{'type':Sequelize[_0x11b302('0x0')],'defaultValue':0xa},'authTimeout':{'type':Sequelize[_0x11b302('0x0')],'defaultValue':0x5},'service':{'type':Sequelize[_0x11b302('0x6')]}}; \ No newline at end of file +const a431_0x1f6c=['INBOX','exports','sequelize','username','INTEGER','STRING','BOOLEAN'];(function(_0x96c2af,_0x1f6cee){const _0x547518=function(_0x2dc1bb){while(--_0x2dc1bb){_0x96c2af['push'](_0x96c2af['shift']());}};_0x547518(++_0x1f6cee);}(a431_0x1f6c,0xc4));const a431_0x5475=function(_0x96c2af,_0x1f6cee){_0x96c2af=_0x96c2af-0x0;let _0x547518=a431_0x1f6c[_0x96c2af];return _0x547518;};const _0xcd7288=a431_0x5475;'use strict';const Sequelize=require(_0xcd7288('0x2'));module[_0xcd7288('0x1')]={'description':{'type':Sequelize[_0xcd7288('0x5')]},'host':{'type':Sequelize[_0xcd7288('0x5')]},'authentication':{'type':Sequelize[_0xcd7288('0x6')],'defaultValue':!![]},'user':{'type':Sequelize['STRING'],'unique':_0xcd7288('0x3')},'password':{'type':Sequelize[_0xcd7288('0x5')]},'port':{'type':Sequelize[_0xcd7288('0x4')]},'tls':{'type':Sequelize[_0xcd7288('0x6')],'defaultValue':!![]},'mailbox':{'type':Sequelize[_0xcd7288('0x5')],'defaultValue':_0xcd7288('0x0')},'connTimeout':{'type':Sequelize[_0xcd7288('0x4')],'defaultValue':0xa},'authTimeout':{'type':Sequelize[_0xcd7288('0x4')],'defaultValue':0x5},'service':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/mailServerIn/mailServerIn.model.js b/server/api/mailServerIn/mailServerIn.model.js index a10b836..939f9d3 100644 --- a/server/api/mailServerIn/mailServerIn.model.js +++ b/server/api/mailServerIn/mailServerIn.model.js @@ -1 +1 @@ -const a432_0x5a5c=['define','MailServerIn','./mailServerIn.attributes','mail_servers_in','exports'];(function(_0x427cf4,_0x5a5c24){const _0x23d2ec=function(_0x27ee3e){while(--_0x27ee3e){_0x427cf4['push'](_0x427cf4['shift']());}};_0x23d2ec(++_0x5a5c24);}(a432_0x5a5c,0x101));const a432_0x23d2=function(_0x427cf4,_0x5a5c24){_0x427cf4=_0x427cf4-0x0;let _0x23d2ec=a432_0x5a5c[_0x427cf4];return _0x23d2ec;};const _0x5901cc=a432_0x23d2;'use strict';const attributes=require(_0x5901cc('0x0'));module[_0x5901cc('0x2')]=function(_0x27ee3e){const _0x51920d=_0x5901cc,_0x55af7b=_0x27ee3e[_0x51920d('0x3')](_0x51920d('0x4'),attributes,{'tableName':_0x51920d('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x55af7b;}; \ No newline at end of file +const a432_0x1c80=['MailServerIn','exports'];(function(_0x5ab15c,_0x1c80bf){const _0x55439a=function(_0x2b2140){while(--_0x2b2140){_0x5ab15c['push'](_0x5ab15c['shift']());}};_0x55439a(++_0x1c80bf);}(a432_0x1c80,0xa5));const a432_0x5543=function(_0x5ab15c,_0x1c80bf){_0x5ab15c=_0x5ab15c-0x0;let _0x55439a=a432_0x1c80[_0x5ab15c];return _0x55439a;};const _0x8162f5=a432_0x5543;'use strict';const attributes=require('./mailServerIn.attributes');module[_0x8162f5('0x0')]=function(_0x2b2140){const _0x14a4ee=_0x8162f5,_0x48e12a=_0x2b2140['define'](_0x14a4ee('0x1'),attributes,{'tableName':'mail_servers_in','paranoid':![],'indexes':[],'timestamps':!![]});return _0x48e12a;}; \ No newline at end of file diff --git a/server/api/mailServerIn/mailServerIn.rpc.js b/server/api/mailServerIn/mailServerIn.rpc.js index 90c24a4..daf3117 100644 --- a/server/api/mailServerIn/mailServerIn.rpc.js +++ b/server/api/mailServerIn/mailServerIn.rpc.js @@ -1 +1 @@ -const a433_0x5b73=['map','then','model','GetMailServerIn','lodash','error','message','../../config/logger','info','attributes','stringify','../../mysqldb','options','debug','include'];(function(_0x48315c,_0x5b7334){const _0x497d66=function(_0x21a754){while(--_0x21a754){_0x48315c['push'](_0x48315c['shift']());}};_0x497d66(++_0x5b7334);}(a433_0x5b73,0x1ba));const a433_0x497d=function(_0x48315c,_0x5b7334){_0x48315c=_0x48315c-0x0;let _0x497d66=a433_0x5b73[_0x48315c];return _0x497d66;};const _0x3f647d=a433_0x497d;'use strict';const _=require(_0x3f647d('0xc')),db=require(_0x3f647d('0x4'))['db'],logger=require(_0x3f647d('0x0'))('rpc');exports[_0x3f647d('0xb')]=function(_0x21a754){const _0x2e0778=this;return new Promise(function(_0x49aca9,_0x10b65a){const _0xd8c36c=a433_0x497d;return db['MailServerIn']['findAll']({'raw':_0x21a754['options']?_0x21a754[_0xd8c36c('0x5')]['raw']===undefined?!![]:![]:!![],'where':_0x21a754[_0xd8c36c('0x5')]?_0x21a754[_0xd8c36c('0x5')]['where']||null:null,'attributes':_0x21a754[_0xd8c36c('0x5')]?_0x21a754[_0xd8c36c('0x5')][_0xd8c36c('0x2')]||null:null,'limit':_0x21a754[_0xd8c36c('0x5')]?_0x21a754['options']['limit']||null:null,'include':_0x21a754['options']?_0x21a754['options'][_0xd8c36c('0x7')]?_['map'](_0x21a754['options']['include'],function(_0x17cae6){const _0x1bf979=_0xd8c36c;return{'model':db[_0x17cae6[_0x1bf979('0xa')]],'as':_0x17cae6['as'],'attributes':_0x17cae6['attributes'],'include':_0x17cae6[_0x1bf979('0x7')]?_[_0x1bf979('0x8')](_0x17cae6[_0x1bf979('0x7')],function(_0x2af11f){const _0x15a0e=_0x1bf979;return{'model':db[_0x2af11f[_0x15a0e('0xa')]],'as':_0x2af11f['as'],'attributes':_0x2af11f[_0x15a0e('0x2')],'include':_0x2af11f['include']?_['map'](_0x2af11f[_0x15a0e('0x7')],function(_0x3a3220){const _0x207793=_0x15a0e;return{'model':db[_0x3a3220['model']],'as':_0x3a3220['as'],'attributes':_0x3a3220[_0x207793('0x2')]};}):[]};}):[]};}):[]:[]})[_0xd8c36c('0x9')](function(_0x5ed59d){const _0x41517e=_0xd8c36c;logger[_0x41517e('0x1')](_0x41517e('0xb'),_0x21a754),logger[_0x41517e('0x6')](_0x41517e('0xb'),_0x21a754,JSON[_0x41517e('0x3')](_0x5ed59d)),_0x49aca9(_0x5ed59d);})['catch'](function(_0x35b1b2){const _0x24741c=_0xd8c36c;logger[_0x24741c('0xd')](_0x24741c('0xb'),_0x35b1b2[_0x24741c('0xe')],_0x21a754),_0x10b65a(_0x2e0778[_0x24741c('0xd')](0x1f4,_0x35b1b2[_0x24741c('0xe')]));});});}; \ No newline at end of file +const a433_0xdc2e=['message','MailServerIn','catch','stringify','lodash','model','../../config/logger','map','include','raw','rpc','error','info','attributes','../../mysqldb','options','GetMailServerIn','findAll'];(function(_0x26e6fe,_0xdc2ea5){const _0x2b805e=function(_0x43808e){while(--_0x43808e){_0x26e6fe['push'](_0x26e6fe['shift']());}};_0x2b805e(++_0xdc2ea5);}(a433_0xdc2e,0x19f));const a433_0x2b80=function(_0x26e6fe,_0xdc2ea5){_0x26e6fe=_0x26e6fe-0x0;let _0x2b805e=a433_0xdc2e[_0x26e6fe];return _0x2b805e;};const _0x55f066=a433_0x2b80;'use strict';const _=require(_0x55f066('0x3')),db=require(_0x55f066('0xd'))['db'],logger=require(_0x55f066('0x5'))(_0x55f066('0x9'));exports[_0x55f066('0xf')]=function(_0x43808e){const _0x49a0df=this;return new Promise(function(_0x55de64,_0x4da1a4){const _0x2731dc=a433_0x2b80;return db[_0x2731dc('0x0')][_0x2731dc('0x10')]({'raw':_0x43808e[_0x2731dc('0xe')]?_0x43808e['options'][_0x2731dc('0x8')]===undefined?!![]:![]:!![],'where':_0x43808e[_0x2731dc('0xe')]?_0x43808e[_0x2731dc('0xe')]['where']||null:null,'attributes':_0x43808e[_0x2731dc('0xe')]?_0x43808e[_0x2731dc('0xe')][_0x2731dc('0xc')]||null:null,'limit':_0x43808e[_0x2731dc('0xe')]?_0x43808e[_0x2731dc('0xe')]['limit']||null:null,'include':_0x43808e[_0x2731dc('0xe')]?_0x43808e[_0x2731dc('0xe')][_0x2731dc('0x7')]?_[_0x2731dc('0x6')](_0x43808e[_0x2731dc('0xe')][_0x2731dc('0x7')],function(_0xf14dc8){const _0x1c9756=_0x2731dc;return{'model':db[_0xf14dc8['model']],'as':_0xf14dc8['as'],'attributes':_0xf14dc8[_0x1c9756('0xc')],'include':_0xf14dc8[_0x1c9756('0x7')]?_['map'](_0xf14dc8[_0x1c9756('0x7')],function(_0x353a5b){const _0xe4fc6e=_0x1c9756;return{'model':db[_0x353a5b[_0xe4fc6e('0x4')]],'as':_0x353a5b['as'],'attributes':_0x353a5b[_0xe4fc6e('0xc')],'include':_0x353a5b['include']?_[_0xe4fc6e('0x6')](_0x353a5b[_0xe4fc6e('0x7')],function(_0x4b5880){const _0x20aadd=_0xe4fc6e;return{'model':db[_0x4b5880[_0x20aadd('0x4')]],'as':_0x4b5880['as'],'attributes':_0x4b5880[_0x20aadd('0xc')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x32278a){const _0x1295e2=_0x2731dc;logger[_0x1295e2('0xb')]('GetMailServerIn',_0x43808e),logger['debug']('GetMailServerIn',_0x43808e,JSON[_0x1295e2('0x2')](_0x32278a)),_0x55de64(_0x32278a);})[_0x2731dc('0x1')](function(_0x2a3049){const _0x2144d8=_0x2731dc;logger[_0x2144d8('0xa')](_0x2144d8('0xf'),_0x2a3049[_0x2144d8('0x11')],_0x43808e),_0x4da1a4(_0x49a0df[_0x2144d8('0xa')](0x1f4,_0x2a3049[_0x2144d8('0x11')]));});});}; \ No newline at end of file diff --git a/server/api/mailServerOut/index.js b/server/api/mailServerOut/index.js index dc4543a..ad7c088 100644 --- a/server/api/mailServerOut/index.js +++ b/server/api/mailServerOut/index.js @@ -1 +1 @@ -const a434_0x1e86=['delete','Router','isAuthenticated','update','./mailServerOut.controller','post','put','get','exports','/:id'];(function(_0x391a36,_0x1e8696){const _0x467915=function(_0x491ca7){while(--_0x491ca7){_0x391a36['push'](_0x391a36['shift']());}};_0x467915(++_0x1e8696);}(a434_0x1e86,0x193));const a434_0x4679=function(_0x391a36,_0x1e8696){_0x391a36=_0x391a36-0x0;let _0x467915=a434_0x1e86[_0x391a36];return _0x467915;};const _0x252135=a434_0x4679;'use strict';const express=require('express'),router=express[_0x252135('0x8')](),auth=require('../../components/auth/service'),controller=require(_0x252135('0x1'));router[_0x252135('0x4')]('/',auth[_0x252135('0x9')](),controller['index']),router[_0x252135('0x4')]('/:id',auth[_0x252135('0x9')](),controller['show']),router[_0x252135('0x2')]('/',auth[_0x252135('0x9')](),controller['create']),router[_0x252135('0x3')]('/:id',auth[_0x252135('0x9')](),controller[_0x252135('0x0')]),router[_0x252135('0x7')](_0x252135('0x6'),auth[_0x252135('0x9')](),controller['destroy']),module[_0x252135('0x5')]=router; \ No newline at end of file +const a434_0x44ce=['isAuthenticated','index','post','./mailServerOut.controller','delete','exports','../../components/auth/service','/:id','get','create','express','destroy','update'];(function(_0x1fad33,_0x44ceb3){const _0x4b8ae3=function(_0x139cda){while(--_0x139cda){_0x1fad33['push'](_0x1fad33['shift']());}};_0x4b8ae3(++_0x44ceb3);}(a434_0x44ce,0x192));const a434_0x4b8a=function(_0x1fad33,_0x44ceb3){_0x1fad33=_0x1fad33-0x0;let _0x4b8ae3=a434_0x44ce[_0x1fad33];return _0x4b8ae3;};const _0x100387=a434_0x4b8a;'use strict';const express=require(_0x100387('0xb')),router=express['Router'](),auth=require(_0x100387('0x7')),controller=require(_0x100387('0x4'));router[_0x100387('0x9')]('/',auth[_0x100387('0x1')](),controller[_0x100387('0x2')]),router['get'](_0x100387('0x8'),auth[_0x100387('0x1')](),controller['show']),router[_0x100387('0x3')]('/',auth[_0x100387('0x1')](),controller[_0x100387('0xa')]),router['put'](_0x100387('0x8'),auth[_0x100387('0x1')](),controller[_0x100387('0x0')]),router[_0x100387('0x5')](_0x100387('0x8'),auth['isAuthenticated'](),controller[_0x100387('0xc')]),module[_0x100387('0x6')]=router; \ No newline at end of file diff --git a/server/api/mailServerOut/mailServerOut.attributes.js b/server/api/mailServerOut/mailServerOut.attributes.js index 4961823..6d545f7 100644 --- a/server/api/mailServerOut/mailServerOut.attributes.js +++ b/server/api/mailServerOut/mailServerOut.attributes.js @@ -1 +1 @@ -const a435_0x25b1=['sequelize','STRING','INTEGER','exports','BOOLEAN'];(function(_0x16d3db,_0x25b1f8){const _0xfe5488=function(_0xd408aa){while(--_0xd408aa){_0x16d3db['push'](_0x16d3db['shift']());}};_0xfe5488(++_0x25b1f8);}(a435_0x25b1,0x9b));const a435_0xfe54=function(_0x16d3db,_0x25b1f8){_0x16d3db=_0x16d3db-0x0;let _0xfe5488=a435_0x25b1[_0x16d3db];return _0xfe5488;};const _0x4f3d1d=a435_0xfe54;'use strict';const Sequelize=require(_0x4f3d1d('0x0'));module[_0x4f3d1d('0x3')]={'description':{'type':Sequelize[_0x4f3d1d('0x1')]},'host':{'type':Sequelize[_0x4f3d1d('0x1')]},'user':{'type':Sequelize[_0x4f3d1d('0x1')]},'pass':{'type':Sequelize[_0x4f3d1d('0x1')]},'port':{'type':Sequelize[_0x4f3d1d('0x2')]},'secure':{'type':Sequelize[_0x4f3d1d('0x4')],'defaultValue':![]},'service':{'type':Sequelize[_0x4f3d1d('0x1')]},'authentication':{'type':Sequelize[_0x4f3d1d('0x4')],'defaultValue':!![]}}; \ No newline at end of file +const a435_0x88be=['sequelize','INTEGER','STRING','exports'];(function(_0x4a6649,_0x88be88){const _0x5a74ad=function(_0x46bb0b){while(--_0x46bb0b){_0x4a6649['push'](_0x4a6649['shift']());}};_0x5a74ad(++_0x88be88);}(a435_0x88be,0x1b7));const a435_0x5a74=function(_0x4a6649,_0x88be88){_0x4a6649=_0x4a6649-0x0;let _0x5a74ad=a435_0x88be[_0x4a6649];return _0x5a74ad;};const _0x5543f1=a435_0x5a74;'use strict';const Sequelize=require(_0x5543f1('0x1'));module[_0x5543f1('0x0')]={'description':{'type':Sequelize['STRING']},'host':{'type':Sequelize[_0x5543f1('0x3')]},'user':{'type':Sequelize[_0x5543f1('0x3')]},'pass':{'type':Sequelize['STRING']},'port':{'type':Sequelize[_0x5543f1('0x2')]},'secure':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'service':{'type':Sequelize[_0x5543f1('0x3')]},'authentication':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]}}; \ No newline at end of file diff --git a/server/api/mailServerOut/mailServerOut.controller.js b/server/api/mailServerOut/mailServerOut.controller.js index 68464ff..300ea56 100644 --- a/server/api/mailServerOut/mailServerOut.controller.js +++ b/server/api/mailServerOut/mailServerOut.controller.js @@ -1 +1 @@ -const a436_0x4972=['length','filters','fieldName','error','show','name','offset','includeAll','include','MailServerOut','lodash','fields','body','index','../../components/parsers/qs','sort','attributes','status','json','merge','keys','../../config/logger','intersection','undefined','count','order','rawAttributes','query','sendStatus','map','limit','findAll','api','rows','pick','where','create','findOne','end','catch','like','then','params','update','filter','sequelize','destroy','stack','VIRTUAL','model','set'];(function(_0x27bbde,_0x4972e2){const _0x3f4685=function(_0x147128){while(--_0x147128){_0x27bbde['push'](_0x27bbde['shift']());}};_0x3f4685(++_0x4972e2);}(a436_0x4972,0x129));const a436_0x3f46=function(_0x27bbde,_0x4972e2){_0x27bbde=_0x27bbde-0x0;let _0x3f4685=a436_0x4972[_0x27bbde];return _0x3f4685;};const _0x451ad6=a436_0x3f46;'use strict';const _=require(_0x451ad6('0x13')),qs=require(_0x451ad6('0x17')),logger=require(_0x451ad6('0x1e'))(_0x451ad6('0x29')),db=require('../../mysqldb')['db'],{Op}=require(_0x451ad6('0x3'));function respondWithResult(_0x147128,_0x54a13d){return _0x54a13d=_0x54a13d||0xc8,function(_0x16f020){const _0x977cb5=a436_0x3f46;if(_0x16f020)return _0x147128[_0x977cb5('0x1a')](_0x54a13d)[_0x977cb5('0x1b')](_0x16f020);};}function respondWithFilteredResult(_0x2fc52d,_0x14288a){return function(_0x4532a2){const _0x21a72b=a436_0x3f46;if(_0x4532a2){const _0x491bdb=_0x4532a2['count'],_0x2fb088=_0x14288a[_0x21a72b('0xf')];let _0xfe0f95=_0x14288a['offset']+_0x14288a[_0x21a72b('0x27')],_0x2b3b10;return _0xfe0f95>=_0x491bdb?(_0xfe0f95=_0x491bdb,_0x2b3b10=0xc8):_0x2b3b10=0xce,_0x2fc52d['status'](_0x2b3b10),_0x2fc52d[_0x21a72b('0x8')]('Content-Range',_0x2fb088+'-'+_0xfe0f95+'/'+_0x491bdb)[_0x21a72b('0x1b')](_0x4532a2);}return null;};}function saveUpdates(_0xed94c5){return function(_0x45df7b){if(_0x45df7b)return _0x45df7b['update'](_0xed94c5)['then'](function(_0x7d0f49){return _0x7d0f49;});return null;};}function removeEntity(_0x376e00){return function(_0x2ce7ae){const _0x1c5916=a436_0x3f46;if(_0x2ce7ae)return _0x2ce7ae[_0x1c5916('0x4')]()[_0x1c5916('0x32')](function(){const _0x356d47=_0x1c5916;_0x376e00[_0x356d47('0x1a')](0xcc)[_0x356d47('0x2f')]();});};}function handleEntityNotFound(_0x1bbe14){return function(_0x586468){const _0x27eeec=a436_0x3f46;return!_0x586468&&_0x1bbe14[_0x27eeec('0x25')](0x194),_0x586468;};}function handleError(_0x414d5f,_0x4db6f6){return _0x4db6f6=_0x4db6f6||0x1f4,function(_0x161d50){const _0x431aa3=a436_0x3f46;logger[_0x431aa3('0xc')](_0x161d50[_0x431aa3('0x5')]),_0x161d50[_0x431aa3('0xe')]&&delete _0x161d50[_0x431aa3('0xe')],_0x414d5f[_0x431aa3('0x1a')](_0x4db6f6)['send'](_0x161d50);};}exports[_0x451ad6('0x16')]=function(_0x41fd50,_0x97055f){const _0x5f49bf=_0x451ad6;let _0x10a87e={};const _0x2db624={},_0xe2fc89={'count':0x0,'rows':[]},_0x19e8ff=_['map'](db['MailServerOut']['rawAttributes'],function(_0x7eb30e){const _0x12389d=a436_0x3f46;return{'name':_0x7eb30e[_0x12389d('0xb')],'type':_0x7eb30e['type']['key']};});_0x2db624['model']=_[_0x5f49bf('0x26')](_0x19e8ff,_0x5f49bf('0xe')),_0x2db624['query']=_['keys'](_0x41fd50[_0x5f49bf('0x24')]),_0x2db624['filters']=_['intersection'](_0x2db624['model'],_0x2db624[_0x5f49bf('0x24')]),_0x10a87e[_0x5f49bf('0x19')]=_[_0x5f49bf('0x1f')](_0x2db624['model'],qs[_0x5f49bf('0x14')](_0x41fd50[_0x5f49bf('0x24')][_0x5f49bf('0x14')])),_0x10a87e[_0x5f49bf('0x19')]=_0x10a87e[_0x5f49bf('0x19')]['length']?_0x10a87e['attributes']:_0x2db624[_0x5f49bf('0x7')];typeof _0x41fd50[_0x5f49bf('0x24')]['nolimit']===_0x5f49bf('0x20')&&(_0x10a87e[_0x5f49bf('0x27')]=qs[_0x5f49bf('0x27')](_0x41fd50[_0x5f49bf('0x24')]['limit']),_0x10a87e[_0x5f49bf('0xf')]=qs[_0x5f49bf('0xf')](_0x41fd50[_0x5f49bf('0x24')][_0x5f49bf('0xf')]));_0x10a87e[_0x5f49bf('0x22')]=qs[_0x5f49bf('0x18')](_0x41fd50['query'][_0x5f49bf('0x18')]),_0x10a87e['where']=qs['filters'](_[_0x5f49bf('0x2b')](_0x41fd50[_0x5f49bf('0x24')],_0x2db624[_0x5f49bf('0xa')]),_0x19e8ff);_0x41fd50[_0x5f49bf('0x24')][_0x5f49bf('0x2')]&&(_0x10a87e[_0x5f49bf('0x2c')]=_[_0x5f49bf('0x1c')](_0x10a87e['where'],{[Op['or']]:_[_0x5f49bf('0x26')](_0x19e8ff,function(_0x1c86ef){const _0x2a8840=_0x5f49bf;if(_0x1c86ef['type']!==_0x2a8840('0x6')){const _0x442414={};return _0x442414[_0x1c86ef['name']]={[Op[_0x2a8840('0x31')]]:'%'+_0x41fd50[_0x2a8840('0x24')][_0x2a8840('0x2')]+'%'},_0x442414;}})}));_0x10a87e=_[_0x5f49bf('0x1c')]({},_0x10a87e,_0x41fd50['options']);const _0x3683f0={'where':_0x10a87e[_0x5f49bf('0x2c')]};return db[_0x5f49bf('0x12')][_0x5f49bf('0x21')](_0x3683f0)[_0x5f49bf('0x32')](function(_0x4bf9c0){const _0x3caa6e=_0x5f49bf;return _0xe2fc89[_0x3caa6e('0x21')]=_0x4bf9c0,_0x41fd50['query'][_0x3caa6e('0x10')]&&(_0x10a87e[_0x3caa6e('0x11')]=[{'all':!![]}]),db[_0x3caa6e('0x12')][_0x3caa6e('0x28')](_0x10a87e);})[_0x5f49bf('0x32')](function(_0x352833){const _0xb7c2d9=_0x5f49bf;return _0xe2fc89[_0xb7c2d9('0x2a')]=_0x352833,_0xe2fc89;})[_0x5f49bf('0x32')](respondWithFilteredResult(_0x97055f,_0x10a87e))['catch'](handleError(_0x97055f,null));},exports[_0x451ad6('0xd')]=function(_0x57cd5e,_0x21c47c){const _0x26f7c4=_0x451ad6;let _0x2ead36={'raw':!![],'where':{'id':_0x57cd5e['params']['id']}};const _0x2cceb2={};return _0x2cceb2[_0x26f7c4('0x7')]=_[_0x26f7c4('0x1d')](db[_0x26f7c4('0x12')][_0x26f7c4('0x23')]),_0x2cceb2['query']=_[_0x26f7c4('0x1d')](_0x57cd5e[_0x26f7c4('0x24')]),_0x2cceb2['filters']=_[_0x26f7c4('0x1f')](_0x2cceb2[_0x26f7c4('0x7')],_0x2cceb2[_0x26f7c4('0x24')]),_0x2ead36['attributes']=_[_0x26f7c4('0x1f')](_0x2cceb2[_0x26f7c4('0x7')],qs['fields'](_0x57cd5e[_0x26f7c4('0x24')][_0x26f7c4('0x14')])),_0x2ead36[_0x26f7c4('0x19')]=_0x2ead36[_0x26f7c4('0x19')][_0x26f7c4('0x9')]?_0x2ead36[_0x26f7c4('0x19')]:_0x2cceb2[_0x26f7c4('0x7')],_0x57cd5e[_0x26f7c4('0x24')][_0x26f7c4('0x10')]&&(_0x2ead36[_0x26f7c4('0x11')]=[{'all':!![]}]),_0x2ead36=_['merge']({},_0x2ead36,_0x57cd5e['options']),db[_0x26f7c4('0x12')][_0x26f7c4('0x2e')](_0x2ead36)['then'](handleEntityNotFound(_0x21c47c,null))[_0x26f7c4('0x32')](respondWithResult(_0x21c47c,null))[_0x26f7c4('0x30')](handleError(_0x21c47c,null));},exports[_0x451ad6('0x2d')]=function(_0x399d3a,_0x56ab51){const _0x15f548=_0x451ad6;return db[_0x15f548('0x12')]['create'](_0x399d3a[_0x15f548('0x15')],{})[_0x15f548('0x32')](respondWithResult(_0x56ab51,0xc9))['catch'](handleError(_0x56ab51,null));},exports[_0x451ad6('0x1')]=function(_0x48928a,_0x3f5834){const _0x2a35c7=_0x451ad6;return _0x48928a[_0x2a35c7('0x15')]['id']&&delete _0x48928a[_0x2a35c7('0x15')]['id'],db[_0x2a35c7('0x12')][_0x2a35c7('0x2e')]({'where':{'id':_0x48928a[_0x2a35c7('0x0')]['id']}})[_0x2a35c7('0x32')](handleEntityNotFound(_0x3f5834,null))[_0x2a35c7('0x32')](saveUpdates(_0x48928a['body'],null))[_0x2a35c7('0x32')](respondWithResult(_0x3f5834,null))['catch'](handleError(_0x3f5834,null));},exports[_0x451ad6('0x4')]=function(_0x1e5915,_0x448023){const _0x5c9d91=_0x451ad6;return db['MailServerOut']['findOne']({'where':{'id':_0x1e5915[_0x5c9d91('0x0')]['id']}})[_0x5c9d91('0x32')](handleEntityNotFound(_0x448023,null))['then'](removeEntity(_0x448023,null))[_0x5c9d91('0x30')](handleError(_0x448023,null));}; \ No newline at end of file +const a436_0x4b35=['type','stack','key','offset','body','keys','includeAll','filter','fieldName','end','merge','lodash','findAll','Content-Range','index','limit','where','filters','sort','set','catch','query','rows','intersection','error','sequelize','destroy','send','name','status','fields','count','create','../../components/parsers/qs','json','model','MailServerOut','length','update','params','attributes','map','options','findOne','sendStatus','include','show','then'];(function(_0x33aedf,_0x4b350f){const _0x2b5b45=function(_0x2c2b44){while(--_0x2c2b44){_0x33aedf['push'](_0x33aedf['shift']());}};_0x2b5b45(++_0x4b350f);}(a436_0x4b35,0x1cb));const a436_0x2b5b=function(_0x33aedf,_0x4b350f){_0x33aedf=_0x33aedf-0x0;let _0x2b5b45=a436_0x4b35[_0x33aedf];return _0x2b5b45;};const _0x48c851=a436_0x2b5b;'use strict';const _=require(_0x48c851('0x20')),qs=require(_0x48c851('0x6')),logger=require('../../config/logger')('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x48c851('0x2e'));function respondWithResult(_0x2c2b44,_0x2ad191){return _0x2ad191=_0x2ad191||0xc8,function(_0x1ee82e){const _0x5ade73=a436_0x2b5b;if(_0x1ee82e)return _0x2c2b44[_0x5ade73('0x2')](_0x2ad191)[_0x5ade73('0x7')](_0x1ee82e);};}function respondWithFilteredResult(_0xd4003,_0x473e54){return function(_0x3d16f4){const _0x2498b4=a436_0x2b5b;if(_0x3d16f4){const _0x3b054a=_0x3d16f4[_0x2498b4('0x4')],_0x4d956e=_0x473e54[_0x2498b4('0x18')];let _0x5db6b7=_0x473e54[_0x2498b4('0x18')]+_0x473e54[_0x2498b4('0x24')],_0x3378c4;return _0x5db6b7>=_0x3b054a?(_0x5db6b7=_0x3b054a,_0x3378c4=0xc8):_0x3378c4=0xce,_0xd4003['status'](_0x3378c4),_0xd4003[_0x2498b4('0x28')](_0x2498b4('0x22'),_0x4d956e+'-'+_0x5db6b7+'/'+_0x3b054a)[_0x2498b4('0x7')](_0x3d16f4);}return null;};}function saveUpdates(_0x51dc41){return function(_0x2f6ef3){const _0x3d35f0=a436_0x2b5b;if(_0x2f6ef3)return _0x2f6ef3[_0x3d35f0('0xb')](_0x51dc41)[_0x3d35f0('0x14')](function(_0xabfa1b){return _0xabfa1b;});return null;};}function removeEntity(_0x10d94e){return function(_0x36ab58){const _0x24bfbb=a436_0x2b5b;if(_0x36ab58)return _0x36ab58[_0x24bfbb('0x2f')]()[_0x24bfbb('0x14')](function(){const _0x46f30e=_0x24bfbb;_0x10d94e[_0x46f30e('0x2')](0xcc)[_0x46f30e('0x1e')]();});};}function handleEntityNotFound(_0x2886e1){return function(_0x54328c){const _0x11d59f=a436_0x2b5b;return!_0x54328c&&_0x2886e1[_0x11d59f('0x11')](0x194),_0x54328c;};}function handleError(_0x4bb649,_0x540cf5){return _0x540cf5=_0x540cf5||0x1f4,function(_0x107452){const _0x8d91f0=a436_0x2b5b;logger[_0x8d91f0('0x2d')](_0x107452[_0x8d91f0('0x16')]),_0x107452[_0x8d91f0('0x1')]&&delete _0x107452[_0x8d91f0('0x1')],_0x4bb649[_0x8d91f0('0x2')](_0x540cf5)[_0x8d91f0('0x0')](_0x107452);};}exports[_0x48c851('0x23')]=function(_0x243c6e,_0x3381d1){const _0x38f971=_0x48c851;let _0x856772={};const _0x1845ed={},_0x30ffa4={'count':0x0,'rows':[]},_0x3fd0ee=_[_0x38f971('0xe')](db['MailServerOut']['rawAttributes'],function(_0x2d4f93){const _0x547585=_0x38f971;return{'name':_0x2d4f93[_0x547585('0x1d')],'type':_0x2d4f93[_0x547585('0x15')][_0x547585('0x17')]};});_0x1845ed[_0x38f971('0x8')]=_[_0x38f971('0xe')](_0x3fd0ee,_0x38f971('0x1')),_0x1845ed[_0x38f971('0x2a')]=_[_0x38f971('0x1a')](_0x243c6e[_0x38f971('0x2a')]),_0x1845ed[_0x38f971('0x26')]=_[_0x38f971('0x2c')](_0x1845ed['model'],_0x1845ed[_0x38f971('0x2a')]),_0x856772['attributes']=_[_0x38f971('0x2c')](_0x1845ed[_0x38f971('0x8')],qs['fields'](_0x243c6e[_0x38f971('0x2a')][_0x38f971('0x3')])),_0x856772[_0x38f971('0xd')]=_0x856772['attributes'][_0x38f971('0xa')]?_0x856772['attributes']:_0x1845ed['model'];typeof _0x243c6e[_0x38f971('0x2a')]['nolimit']==='undefined'&&(_0x856772[_0x38f971('0x24')]=qs[_0x38f971('0x24')](_0x243c6e[_0x38f971('0x2a')][_0x38f971('0x24')]),_0x856772[_0x38f971('0x18')]=qs[_0x38f971('0x18')](_0x243c6e[_0x38f971('0x2a')][_0x38f971('0x18')]));_0x856772['order']=qs[_0x38f971('0x27')](_0x243c6e[_0x38f971('0x2a')]['sort']),_0x856772[_0x38f971('0x25')]=qs[_0x38f971('0x26')](_['pick'](_0x243c6e[_0x38f971('0x2a')],_0x1845ed[_0x38f971('0x26')]),_0x3fd0ee);_0x243c6e[_0x38f971('0x2a')][_0x38f971('0x1c')]&&(_0x856772[_0x38f971('0x25')]=_[_0x38f971('0x1f')](_0x856772[_0x38f971('0x25')],{[Op['or']]:_[_0x38f971('0xe')](_0x3fd0ee,function(_0xe2f7e4){const _0x4d75ed=_0x38f971;if(_0xe2f7e4[_0x4d75ed('0x15')]!=='VIRTUAL'){const _0xccc1f9={};return _0xccc1f9[_0xe2f7e4[_0x4d75ed('0x1')]]={[Op['like']]:'%'+_0x243c6e[_0x4d75ed('0x2a')][_0x4d75ed('0x1c')]+'%'},_0xccc1f9;}})}));_0x856772=_[_0x38f971('0x1f')]({},_0x856772,_0x243c6e[_0x38f971('0xf')]);const _0x56074a={'where':_0x856772[_0x38f971('0x25')]};return db[_0x38f971('0x9')][_0x38f971('0x4')](_0x56074a)[_0x38f971('0x14')](function(_0x3eac6d){const _0xe7aa1a=_0x38f971;return _0x30ffa4[_0xe7aa1a('0x4')]=_0x3eac6d,_0x243c6e[_0xe7aa1a('0x2a')][_0xe7aa1a('0x1b')]&&(_0x856772[_0xe7aa1a('0x12')]=[{'all':!![]}]),db['MailServerOut'][_0xe7aa1a('0x21')](_0x856772);})[_0x38f971('0x14')](function(_0x4679c9){const _0x42945d=_0x38f971;return _0x30ffa4[_0x42945d('0x2b')]=_0x4679c9,_0x30ffa4;})['then'](respondWithFilteredResult(_0x3381d1,_0x856772))['catch'](handleError(_0x3381d1,null));},exports[_0x48c851('0x13')]=function(_0x3865eb,_0x19c7c0){const _0x39c1c9=_0x48c851;let _0xec7d4={'raw':!![],'where':{'id':_0x3865eb[_0x39c1c9('0xc')]['id']}};const _0x3606a8={};return _0x3606a8[_0x39c1c9('0x8')]=_[_0x39c1c9('0x1a')](db[_0x39c1c9('0x9')]['rawAttributes']),_0x3606a8[_0x39c1c9('0x2a')]=_[_0x39c1c9('0x1a')](_0x3865eb[_0x39c1c9('0x2a')]),_0x3606a8['filters']=_[_0x39c1c9('0x2c')](_0x3606a8[_0x39c1c9('0x8')],_0x3606a8['query']),_0xec7d4[_0x39c1c9('0xd')]=_[_0x39c1c9('0x2c')](_0x3606a8[_0x39c1c9('0x8')],qs[_0x39c1c9('0x3')](_0x3865eb['query'][_0x39c1c9('0x3')])),_0xec7d4[_0x39c1c9('0xd')]=_0xec7d4[_0x39c1c9('0xd')][_0x39c1c9('0xa')]?_0xec7d4[_0x39c1c9('0xd')]:_0x3606a8['model'],_0x3865eb[_0x39c1c9('0x2a')][_0x39c1c9('0x1b')]&&(_0xec7d4[_0x39c1c9('0x12')]=[{'all':!![]}]),_0xec7d4=_[_0x39c1c9('0x1f')]({},_0xec7d4,_0x3865eb[_0x39c1c9('0xf')]),db['MailServerOut']['findOne'](_0xec7d4)['then'](handleEntityNotFound(_0x19c7c0,null))[_0x39c1c9('0x14')](respondWithResult(_0x19c7c0,null))[_0x39c1c9('0x29')](handleError(_0x19c7c0,null));},exports[_0x48c851('0x5')]=function(_0x2b9d2a,_0x1b5aeb){const _0x282944=_0x48c851;return db['MailServerOut'][_0x282944('0x5')](_0x2b9d2a[_0x282944('0x19')],{})['then'](respondWithResult(_0x1b5aeb,0xc9))[_0x282944('0x29')](handleError(_0x1b5aeb,null));},exports[_0x48c851('0xb')]=function(_0x37e701,_0x4ead87){const _0x21c431=_0x48c851;return _0x37e701[_0x21c431('0x19')]['id']&&delete _0x37e701['body']['id'],db[_0x21c431('0x9')][_0x21c431('0x10')]({'where':{'id':_0x37e701[_0x21c431('0xc')]['id']}})[_0x21c431('0x14')](handleEntityNotFound(_0x4ead87,null))[_0x21c431('0x14')](saveUpdates(_0x37e701[_0x21c431('0x19')],null))['then'](respondWithResult(_0x4ead87,null))[_0x21c431('0x29')](handleError(_0x4ead87,null));},exports[_0x48c851('0x2f')]=function(_0x23de73,_0x105e14){const _0x517e6c=_0x48c851;return db[_0x517e6c('0x9')]['findOne']({'where':{'id':_0x23de73[_0x517e6c('0xc')]['id']}})[_0x517e6c('0x14')](handleEntityNotFound(_0x105e14,null))[_0x517e6c('0x14')](removeEntity(_0x105e14,null))[_0x517e6c('0x29')](handleError(_0x105e14,null));}; \ No newline at end of file diff --git a/server/api/mailServerOut/mailServerOut.model.js b/server/api/mailServerOut/mailServerOut.model.js index ac540c3..c7e23af 100644 --- a/server/api/mailServerOut/mailServerOut.model.js +++ b/server/api/mailServerOut/mailServerOut.model.js @@ -1 +1 @@ -const a437_0x16c9=['define','./mailServerOut.attributes','mail_servers_out'];(function(_0x2c2226,_0x16c9e3){const _0x4d6cec=function(_0x5bd047){while(--_0x5bd047){_0x2c2226['push'](_0x2c2226['shift']());}};_0x4d6cec(++_0x16c9e3);}(a437_0x16c9,0x1a0));const a437_0x4d6c=function(_0x2c2226,_0x16c9e3){_0x2c2226=_0x2c2226-0x0;let _0x4d6cec=a437_0x16c9[_0x2c2226];return _0x4d6cec;};const _0x55545e=a437_0x4d6c;'use strict';const attributes=require(_0x55545e('0x2'));module['exports']=function(_0x5bd047){const _0xc27d40=_0x55545e,_0x4d98e9=_0x5bd047[_0xc27d40('0x1')]('MailServerOut',attributes,{'tableName':_0xc27d40('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x4d98e9;}; \ No newline at end of file +const a437_0xbd01=['./mailServerOut.attributes','mail_servers_out','MailServerOut'];(function(_0x45be7a,_0xbd01de){const _0x43e817=function(_0x353fd5){while(--_0x353fd5){_0x45be7a['push'](_0x45be7a['shift']());}};_0x43e817(++_0xbd01de);}(a437_0xbd01,0x67));const a437_0x43e8=function(_0x45be7a,_0xbd01de){_0x45be7a=_0x45be7a-0x0;let _0x43e817=a437_0xbd01[_0x45be7a];return _0x43e817;};const _0x4510eb=a437_0x43e8;'use strict';const attributes=require(_0x4510eb('0x2'));module['exports']=function(_0x353fd5){const _0x3a70e7=_0x4510eb,_0x1d45fc=_0x353fd5['define'](_0x3a70e7('0x1'),attributes,{'tableName':_0x3a70e7('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1d45fc;}; \ No newline at end of file diff --git a/server/api/mailSubstatus/index.js b/server/api/mailSubstatus/index.js index 7a4011d..18acb63 100644 --- a/server/api/mailSubstatus/index.js +++ b/server/api/mailSubstatus/index.js @@ -1 +1 @@ -const a438_0x2b61=['Router','describe','get','isAuthenticated','index','delete','express','put','/describe','../../components/auth/service','/:id','update','./mailSubstatus.controller','create'];(function(_0x34dd62,_0x2b61e9){const _0x300886=function(_0x25a775){while(--_0x25a775){_0x34dd62['push'](_0x34dd62['shift']());}};_0x300886(++_0x2b61e9);}(a438_0x2b61,0x184));const a438_0x3008=function(_0x34dd62,_0x2b61e9){_0x34dd62=_0x34dd62-0x0;let _0x300886=a438_0x2b61[_0x34dd62];return _0x300886;};const _0x2026bc=a438_0x3008;'use strict';const express=require(_0x2026bc('0xa')),router=express[_0x2026bc('0x4')](),auth=require(_0x2026bc('0xd')),controller=require(_0x2026bc('0x2'));router['get']('/',auth[_0x2026bc('0x7')](),controller[_0x2026bc('0x8')]),router[_0x2026bc('0x6')](_0x2026bc('0xc'),auth['isAuthenticated'](),controller[_0x2026bc('0x5')]),router[_0x2026bc('0x6')]('/:id',auth['isAuthenticated'](),controller['show']),router['post']('/',auth[_0x2026bc('0x7')](),controller[_0x2026bc('0x3')]),router[_0x2026bc('0xb')](_0x2026bc('0x0'),auth[_0x2026bc('0x7')](),controller[_0x2026bc('0x1')]),router[_0x2026bc('0x9')](_0x2026bc('0x0'),auth[_0x2026bc('0x7')](),controller['destroy']),module['exports']=router; \ No newline at end of file +const a438_0x514f=['Router','post','get','express','describe','index','./mailSubstatus.controller','/describe','isAuthenticated','create','../../components/auth/service','update','destroy','put','delete','exports','show'];(function(_0x57e74a,_0x514f03){const _0x46d196=function(_0x33f157){while(--_0x33f157){_0x57e74a['push'](_0x57e74a['shift']());}};_0x46d196(++_0x514f03);}(a438_0x514f,0x1bb));const a438_0x46d1=function(_0x57e74a,_0x514f03){_0x57e74a=_0x57e74a-0x0;let _0x46d196=a438_0x514f[_0x57e74a];return _0x46d196;};const _0x2cd3cf=a438_0x46d1;'use strict';const express=require(_0x2cd3cf('0x2')),router=express[_0x2cd3cf('0x10')](),auth=require(_0x2cd3cf('0x9')),controller=require(_0x2cd3cf('0x5'));router[_0x2cd3cf('0x1')]('/',auth[_0x2cd3cf('0x7')](),controller[_0x2cd3cf('0x4')]),router[_0x2cd3cf('0x1')](_0x2cd3cf('0x6'),auth[_0x2cd3cf('0x7')](),controller[_0x2cd3cf('0x3')]),router[_0x2cd3cf('0x1')]('/:id',auth[_0x2cd3cf('0x7')](),controller[_0x2cd3cf('0xf')]),router[_0x2cd3cf('0x0')]('/',auth[_0x2cd3cf('0x7')](),controller[_0x2cd3cf('0x8')]),router[_0x2cd3cf('0xc')]('/:id',auth[_0x2cd3cf('0x7')](),controller[_0x2cd3cf('0xa')]),router[_0x2cd3cf('0xd')]('/:id',auth[_0x2cd3cf('0x7')](),controller[_0x2cd3cf('0xb')]),module[_0x2cd3cf('0xe')]=router; \ No newline at end of file diff --git a/server/api/mailSubstatus/mailSubstatus.attributes.js b/server/api/mailSubstatus/mailSubstatus.attributes.js index fe0acfc..1dbbacd 100644 --- a/server/api/mailSubstatus/mailSubstatus.attributes.js +++ b/server/api/mailSubstatus/mailSubstatus.attributes.js @@ -1 +1 @@ -const a439_0x3547=['sequelize','exports','name','STRING'];(function(_0x5bae7f,_0x35471e){const _0x405f82=function(_0x33cb31){while(--_0x33cb31){_0x5bae7f['push'](_0x5bae7f['shift']());}};_0x405f82(++_0x35471e);}(a439_0x3547,0xe9));const a439_0x405f=function(_0x5bae7f,_0x35471e){_0x5bae7f=_0x5bae7f-0x0;let _0x405f82=a439_0x3547[_0x5bae7f];return _0x405f82;};const _0x5a818f=a439_0x405f;'use strict';const Sequelize=require(_0x5a818f('0x3'));module[_0x5a818f('0x0')]={'name':{'type':Sequelize[_0x5a818f('0x2')],'unique':_0x5a818f('0x1'),'allowNull':![],'validate':{'notEmpty':!![]}},'description':{'type':Sequelize[_0x5a818f('0x2')]}}; \ No newline at end of file +const a439_0x3360=['STRING','exports'];(function(_0x2d5efc,_0x3360c7){const _0x2145b2=function(_0x500adc){while(--_0x500adc){_0x2d5efc['push'](_0x2d5efc['shift']());}};_0x2145b2(++_0x3360c7);}(a439_0x3360,0xc2));const a439_0x2145=function(_0x2d5efc,_0x3360c7){_0x2d5efc=_0x2d5efc-0x0;let _0x2145b2=a439_0x3360[_0x2d5efc];return _0x2145b2;};const _0x5025c4=a439_0x2145;'use strict';const Sequelize=require('sequelize');module[_0x5025c4('0x1')]={'name':{'type':Sequelize['STRING'],'unique':'name','allowNull':![],'validate':{'notEmpty':!![]}},'description':{'type':Sequelize[_0x5025c4('0x0')]}}; \ No newline at end of file diff --git a/server/api/mailSubstatus/mailSubstatus.controller.js b/server/api/mailSubstatus/mailSubstatus.controller.js index bc88623..ed3e057 100644 --- a/server/api/mailSubstatus/mailSubstatus.controller.js +++ b/server/api/mailSubstatus/mailSubstatus.controller.js @@ -1 +1 @@ -const a440_0x1b59=['options','rows','type','params','model','MailSubstatus','keys','sort','update','sendStatus','then','length','like','count','describe','error','merge','end','attributes','query','includeAll','show','sequelize','key','intersection','destroy','findOne','create','body','catch','order','filter','findAll','limit','Content-Range','offset','filters','status','undefined','fieldName','json','rawAttributes','../../components/parsers/qs','map','where','include','stack','name','fields','api'];(function(_0x139640,_0x1b595f){const _0x21a6c9=function(_0x482c93){while(--_0x482c93){_0x139640['push'](_0x139640['shift']());}};_0x21a6c9(++_0x1b595f);}(a440_0x1b59,0x170));const a440_0x21a6=function(_0x139640,_0x1b595f){_0x139640=_0x139640-0x0;let _0x21a6c9=a440_0x1b59[_0x139640];return _0x21a6c9;};const _0x332902=a440_0x21a6;'use strict';const _=require('lodash'),qs=require(_0x332902('0x18')),logger=require('../../config/logger')(_0x332902('0x1f')),db=require('../../mysqldb')['db'],{Op}=require(_0x332902('0x4'));function respondWithResult(_0x482c93,_0x2cd459){return _0x2cd459=_0x2cd459||0xc8,function(_0x26af07){const _0x466c12=a440_0x21a6;if(_0x26af07)return _0x482c93['status'](_0x2cd459)[_0x466c12('0x16')](_0x26af07);};}function respondWithFilteredResult(_0x52c8a7,_0x545b73){return function(_0x32ad47){const _0x42a1ca=a440_0x21a6;if(_0x32ad47){const _0x36ad35=_0x32ad47['count'],_0x490255=_0x545b73[_0x42a1ca('0x11')];let _0x3c28a6=_0x545b73[_0x42a1ca('0x11')]+_0x545b73[_0x42a1ca('0xf')],_0x2550e6;return _0x3c28a6>=_0x36ad35?(_0x3c28a6=_0x36ad35,_0x2550e6=0xc8):_0x2550e6=0xce,_0x52c8a7[_0x42a1ca('0x13')](_0x2550e6),_0x52c8a7['set'](_0x42a1ca('0x10'),_0x490255+'-'+_0x3c28a6+'/'+_0x36ad35)[_0x42a1ca('0x16')](_0x32ad47);}return null;};}function saveUpdates(_0x122192){return function(_0x2d2e3e){const _0x3d7e09=a440_0x21a6;if(_0x2d2e3e)return _0x2d2e3e[_0x3d7e09('0x28')](_0x122192)['then'](function(_0x7dfe4b){return _0x7dfe4b;});return null;};}function removeEntity(_0x172dc7){return function(_0x49a072){const _0x5dd70e=a440_0x21a6;if(_0x49a072)return _0x49a072[_0x5dd70e('0x7')]()[_0x5dd70e('0x2a')](function(){const _0x2e2681=_0x5dd70e;_0x172dc7[_0x2e2681('0x13')](0xcc)[_0x2e2681('0x31')]();});};}function handleEntityNotFound(_0x305344){return function(_0xf46b7e){const _0x321525=a440_0x21a6;return!_0xf46b7e&&_0x305344[_0x321525('0x29')](0x194),_0xf46b7e;};}function handleError(_0x3e7628,_0x3e4d54){return _0x3e4d54=_0x3e4d54||0x1f4,function(_0x554c63){const _0x18e4ec=a440_0x21a6;logger[_0x18e4ec('0x2f')](_0x554c63[_0x18e4ec('0x1c')]),_0x554c63[_0x18e4ec('0x1d')]&&delete _0x554c63[_0x18e4ec('0x1d')],_0x3e7628[_0x18e4ec('0x13')](_0x3e4d54)['send'](_0x554c63);};}exports['index']=function(_0x19e313,_0x416db3){const _0x5789cf=_0x332902;let _0x2b0c1b={};const _0x4cdaf5={},_0x5e86ad={'count':0x0,'rows':[]},_0x487220=_[_0x5789cf('0x19')](db[_0x5789cf('0x25')][_0x5789cf('0x17')],function(_0x33ea23){const _0x24d56d=_0x5789cf;return{'name':_0x33ea23[_0x24d56d('0x15')],'type':_0x33ea23[_0x24d56d('0x22')][_0x24d56d('0x5')]};});_0x4cdaf5[_0x5789cf('0x24')]=_['map'](_0x487220,'name'),_0x4cdaf5[_0x5789cf('0x1')]=_[_0x5789cf('0x26')](_0x19e313[_0x5789cf('0x1')]),_0x4cdaf5[_0x5789cf('0x12')]=_[_0x5789cf('0x6')](_0x4cdaf5['model'],_0x4cdaf5[_0x5789cf('0x1')]),_0x2b0c1b[_0x5789cf('0x0')]=_[_0x5789cf('0x6')](_0x4cdaf5['model'],qs[_0x5789cf('0x1e')](_0x19e313[_0x5789cf('0x1')][_0x5789cf('0x1e')])),_0x2b0c1b[_0x5789cf('0x0')]=_0x2b0c1b[_0x5789cf('0x0')][_0x5789cf('0x2b')]?_0x2b0c1b['attributes']:_0x4cdaf5[_0x5789cf('0x24')];typeof _0x19e313[_0x5789cf('0x1')]['nolimit']===_0x5789cf('0x14')&&(_0x2b0c1b['limit']=qs[_0x5789cf('0xf')](_0x19e313['query'][_0x5789cf('0xf')]),_0x2b0c1b['offset']=qs['offset'](_0x19e313[_0x5789cf('0x1')][_0x5789cf('0x11')]));_0x2b0c1b[_0x5789cf('0xc')]=qs[_0x5789cf('0x27')](_0x19e313[_0x5789cf('0x1')][_0x5789cf('0x27')]),_0x2b0c1b[_0x5789cf('0x1a')]=qs[_0x5789cf('0x12')](_['pick'](_0x19e313['query'],_0x4cdaf5[_0x5789cf('0x12')]),_0x487220);_0x19e313[_0x5789cf('0x1')][_0x5789cf('0xd')]&&(_0x2b0c1b[_0x5789cf('0x1a')]=_[_0x5789cf('0x30')](_0x2b0c1b[_0x5789cf('0x1a')],{[Op['or']]:_['map'](_0x487220,function(_0x5b94a3){const _0x1d242c=_0x5789cf;if(_0x5b94a3[_0x1d242c('0x22')]!=='VIRTUAL'){const _0x4f3614={};return _0x4f3614[_0x5b94a3['name']]={[Op[_0x1d242c('0x2c')]]:'%'+_0x19e313[_0x1d242c('0x1')]['filter']+'%'},_0x4f3614;}})}));_0x2b0c1b=_[_0x5789cf('0x30')]({},_0x2b0c1b,_0x19e313[_0x5789cf('0x20')]);const _0x252198={'where':_0x2b0c1b[_0x5789cf('0x1a')]};return db[_0x5789cf('0x25')][_0x5789cf('0x2d')](_0x252198)[_0x5789cf('0x2a')](function(_0x3d8962){const _0x1403a2=_0x5789cf;return _0x5e86ad[_0x1403a2('0x2d')]=_0x3d8962,_0x19e313[_0x1403a2('0x1')][_0x1403a2('0x2')]&&(_0x2b0c1b['include']=[{'all':!![]}]),db[_0x1403a2('0x25')][_0x1403a2('0xe')](_0x2b0c1b);})[_0x5789cf('0x2a')](function(_0x3b8ca9){const _0x1a9865=_0x5789cf;return _0x5e86ad[_0x1a9865('0x21')]=_0x3b8ca9,_0x5e86ad;})[_0x5789cf('0x2a')](respondWithFilteredResult(_0x416db3,_0x2b0c1b))[_0x5789cf('0xb')](handleError(_0x416db3,null));},exports[_0x332902('0x3')]=function(_0x38090b,_0x3438eb){const _0x4ce9d6=_0x332902;let _0x2686dd={'raw':!![],'where':{'id':_0x38090b[_0x4ce9d6('0x23')]['id']}};const _0x380641={};return _0x380641['model']=_[_0x4ce9d6('0x26')](db['MailSubstatus'][_0x4ce9d6('0x17')]),_0x380641[_0x4ce9d6('0x1')]=_[_0x4ce9d6('0x26')](_0x38090b[_0x4ce9d6('0x1')]),_0x380641[_0x4ce9d6('0x12')]=_['intersection'](_0x380641[_0x4ce9d6('0x24')],_0x380641[_0x4ce9d6('0x1')]),_0x2686dd['attributes']=_['intersection'](_0x380641[_0x4ce9d6('0x24')],qs[_0x4ce9d6('0x1e')](_0x38090b[_0x4ce9d6('0x1')][_0x4ce9d6('0x1e')])),_0x2686dd[_0x4ce9d6('0x0')]=_0x2686dd[_0x4ce9d6('0x0')][_0x4ce9d6('0x2b')]?_0x2686dd[_0x4ce9d6('0x0')]:_0x380641[_0x4ce9d6('0x24')],_0x38090b[_0x4ce9d6('0x1')]['includeAll']&&(_0x2686dd[_0x4ce9d6('0x1b')]=[{'all':!![]}]),_0x2686dd=_[_0x4ce9d6('0x30')]({},_0x2686dd,_0x38090b[_0x4ce9d6('0x20')]),db['MailSubstatus'][_0x4ce9d6('0x8')](_0x2686dd)[_0x4ce9d6('0x2a')](handleEntityNotFound(_0x3438eb,null))[_0x4ce9d6('0x2a')](respondWithResult(_0x3438eb,null))[_0x4ce9d6('0xb')](handleError(_0x3438eb,null));},exports[_0x332902('0x9')]=function(_0x183561,_0x4fe6a9){const _0x46a695=_0x332902;return db['MailSubstatus'][_0x46a695('0x9')](_0x183561['body'],{})[_0x46a695('0x2a')](respondWithResult(_0x4fe6a9,0xc9))[_0x46a695('0xb')](handleError(_0x4fe6a9,null));},exports['update']=function(_0x191b17,_0x5b1519){const _0x1e90c3=_0x332902;return _0x191b17[_0x1e90c3('0xa')]['id']&&delete _0x191b17[_0x1e90c3('0xa')]['id'],db[_0x1e90c3('0x25')][_0x1e90c3('0x8')]({'where':{'id':_0x191b17['params']['id']}})[_0x1e90c3('0x2a')](handleEntityNotFound(_0x5b1519,null))[_0x1e90c3('0x2a')](saveUpdates(_0x191b17[_0x1e90c3('0xa')],null))['then'](respondWithResult(_0x5b1519,null))[_0x1e90c3('0xb')](handleError(_0x5b1519,null));},exports[_0x332902('0x7')]=function(_0xdb1b84,_0x4facae){const _0x5decc7=_0x332902;return db['MailSubstatus']['findOne']({'where':{'id':_0xdb1b84[_0x5decc7('0x23')]['id']}})[_0x5decc7('0x2a')](handleEntityNotFound(_0x4facae,null))[_0x5decc7('0x2a')](removeEntity(_0x4facae,null))[_0x5decc7('0xb')](handleError(_0x4facae,null));},exports[_0x332902('0x2e')]=function(_0x5a4c7c,_0xfe7a5c){const _0x1d2b3e=_0x332902;return db[_0x1d2b3e('0x25')][_0x1d2b3e('0x2e')]()[_0x1d2b3e('0x2a')](respondWithResult(_0xfe7a5c,null))['catch'](handleError(_0xfe7a5c,null));}; \ No newline at end of file +const a440_0x36e0=['intersection','sendStatus','rawAttributes','sort','../../config/logger','keys','findAll','fields','findOne','where','sequelize','end','catch','limit','length','pick','MailSubstatus','include','options','model','like','VIRTUAL','undefined','describe','params','api','key','type','offset','status','update','merge','json','show','filter','fieldName','name','count','filters','map','body','stack','../../mysqldb','send','includeAll','nolimit','query','create','attributes','then','../../components/parsers/qs','lodash'];(function(_0x55f9b5,_0x36e0b8){const _0x334871=function(_0x1033d6){while(--_0x1033d6){_0x55f9b5['push'](_0x55f9b5['shift']());}};_0x334871(++_0x36e0b8);}(a440_0x36e0,0x76));const a440_0x3348=function(_0x55f9b5,_0x36e0b8){_0x55f9b5=_0x55f9b5-0x0;let _0x334871=a440_0x36e0[_0x55f9b5];return _0x334871;};const _0x4737b0=a440_0x3348;'use strict';const _=require(_0x4737b0('0x25')),qs=require(_0x4737b0('0x24')),logger=require(_0x4737b0('0x2a'))(_0x4737b0('0xb')),db=require(_0x4737b0('0x1c'))['db'],{Op}=require(_0x4737b0('0x30'));function respondWithResult(_0x1033d6,_0x355e6c){return _0x355e6c=_0x355e6c||0xc8,function(_0x30eff2){const _0x437c6b=a440_0x3348;if(_0x30eff2)return _0x1033d6[_0x437c6b('0xf')](_0x355e6c)[_0x437c6b('0x12')](_0x30eff2);};}function respondWithFilteredResult(_0xa1e583,_0x10d7f2){return function(_0x2503b6){const _0xcbda0e=a440_0x3348;if(_0x2503b6){const _0x2ef0ef=_0x2503b6[_0xcbda0e('0x17')],_0x49d586=_0x10d7f2[_0xcbda0e('0xe')];let _0x401469=_0x10d7f2[_0xcbda0e('0xe')]+_0x10d7f2['limit'],_0x3f66ee;return _0x401469>=_0x2ef0ef?(_0x401469=_0x2ef0ef,_0x3f66ee=0xc8):_0x3f66ee=0xce,_0xa1e583[_0xcbda0e('0xf')](_0x3f66ee),_0xa1e583['set']('Content-Range',_0x49d586+'-'+_0x401469+'/'+_0x2ef0ef)['json'](_0x2503b6);}return null;};}function saveUpdates(_0x2d0ca2){return function(_0x3cdfb2){const _0x559592=a440_0x3348;if(_0x3cdfb2)return _0x3cdfb2[_0x559592('0x10')](_0x2d0ca2)[_0x559592('0x23')](function(_0x2cb679){return _0x2cb679;});return null;};}function removeEntity(_0x912ce1){return function(_0x13f416){if(_0x13f416)return _0x13f416['destroy']()['then'](function(){const _0x10edeb=a440_0x3348;_0x912ce1['status'](0xcc)[_0x10edeb('0x31')]();});};}function handleEntityNotFound(_0x14dc83){return function(_0x3df4b1){const _0xdb62eb=a440_0x3348;return!_0x3df4b1&&_0x14dc83[_0xdb62eb('0x27')](0x194),_0x3df4b1;};}function handleError(_0x5dd478,_0x12d05f){return _0x12d05f=_0x12d05f||0x1f4,function(_0x16df8b){const _0x294364=a440_0x3348;logger['error'](_0x16df8b[_0x294364('0x1b')]),_0x16df8b[_0x294364('0x16')]&&delete _0x16df8b[_0x294364('0x16')],_0x5dd478[_0x294364('0xf')](_0x12d05f)[_0x294364('0x1d')](_0x16df8b);};}exports['index']=function(_0x2835fb,_0x5beca9){const _0x3f7620=_0x4737b0;let _0x20484d={};const _0x4e2d78={},_0x442e22={'count':0x0,'rows':[]},_0x16bf7d=_[_0x3f7620('0x19')](db[_0x3f7620('0x2')][_0x3f7620('0x28')],function(_0x48c78c){const _0x44b4b6=_0x3f7620;return{'name':_0x48c78c[_0x44b4b6('0x15')],'type':_0x48c78c[_0x44b4b6('0xd')][_0x44b4b6('0xc')]};});_0x4e2d78['model']=_['map'](_0x16bf7d,_0x3f7620('0x16')),_0x4e2d78[_0x3f7620('0x20')]=_[_0x3f7620('0x2b')](_0x2835fb[_0x3f7620('0x20')]),_0x4e2d78['filters']=_[_0x3f7620('0x26')](_0x4e2d78[_0x3f7620('0x5')],_0x4e2d78[_0x3f7620('0x20')]),_0x20484d[_0x3f7620('0x22')]=_[_0x3f7620('0x26')](_0x4e2d78[_0x3f7620('0x5')],qs[_0x3f7620('0x2d')](_0x2835fb[_0x3f7620('0x20')][_0x3f7620('0x2d')])),_0x20484d[_0x3f7620('0x22')]=_0x20484d[_0x3f7620('0x22')][_0x3f7620('0x0')]?_0x20484d[_0x3f7620('0x22')]:_0x4e2d78[_0x3f7620('0x5')];typeof _0x2835fb[_0x3f7620('0x20')][_0x3f7620('0x1f')]===_0x3f7620('0x8')&&(_0x20484d[_0x3f7620('0x33')]=qs[_0x3f7620('0x33')](_0x2835fb[_0x3f7620('0x20')][_0x3f7620('0x33')]),_0x20484d[_0x3f7620('0xe')]=qs[_0x3f7620('0xe')](_0x2835fb[_0x3f7620('0x20')]['offset']));_0x20484d['order']=qs['sort'](_0x2835fb[_0x3f7620('0x20')][_0x3f7620('0x29')]),_0x20484d[_0x3f7620('0x2f')]=qs[_0x3f7620('0x18')](_[_0x3f7620('0x1')](_0x2835fb[_0x3f7620('0x20')],_0x4e2d78['filters']),_0x16bf7d);_0x2835fb['query']['filter']&&(_0x20484d['where']=_[_0x3f7620('0x11')](_0x20484d[_0x3f7620('0x2f')],{[Op['or']]:_[_0x3f7620('0x19')](_0x16bf7d,function(_0x460d5d){const _0x9fba58=_0x3f7620;if(_0x460d5d[_0x9fba58('0xd')]!==_0x9fba58('0x7')){const _0xe3b35b={};return _0xe3b35b[_0x460d5d['name']]={[Op[_0x9fba58('0x6')]]:'%'+_0x2835fb['query'][_0x9fba58('0x14')]+'%'},_0xe3b35b;}})}));_0x20484d=_[_0x3f7620('0x11')]({},_0x20484d,_0x2835fb[_0x3f7620('0x4')]);const _0x1ad287={'where':_0x20484d['where']};return db[_0x3f7620('0x2')][_0x3f7620('0x17')](_0x1ad287)[_0x3f7620('0x23')](function(_0x3b27ad){const _0x3ed3d4=_0x3f7620;return _0x442e22['count']=_0x3b27ad,_0x2835fb[_0x3ed3d4('0x20')][_0x3ed3d4('0x1e')]&&(_0x20484d[_0x3ed3d4('0x3')]=[{'all':!![]}]),db[_0x3ed3d4('0x2')][_0x3ed3d4('0x2c')](_0x20484d);})[_0x3f7620('0x23')](function(_0x52402e){return _0x442e22['rows']=_0x52402e,_0x442e22;})[_0x3f7620('0x23')](respondWithFilteredResult(_0x5beca9,_0x20484d))[_0x3f7620('0x32')](handleError(_0x5beca9,null));},exports[_0x4737b0('0x13')]=function(_0x58b494,_0x48f987){const _0x41f5ea=_0x4737b0;let _0x5df7a9={'raw':!![],'where':{'id':_0x58b494[_0x41f5ea('0xa')]['id']}};const _0x12d5ce={};return _0x12d5ce[_0x41f5ea('0x5')]=_['keys'](db[_0x41f5ea('0x2')][_0x41f5ea('0x28')]),_0x12d5ce[_0x41f5ea('0x20')]=_['keys'](_0x58b494[_0x41f5ea('0x20')]),_0x12d5ce[_0x41f5ea('0x18')]=_[_0x41f5ea('0x26')](_0x12d5ce[_0x41f5ea('0x5')],_0x12d5ce[_0x41f5ea('0x20')]),_0x5df7a9[_0x41f5ea('0x22')]=_['intersection'](_0x12d5ce[_0x41f5ea('0x5')],qs['fields'](_0x58b494['query'][_0x41f5ea('0x2d')])),_0x5df7a9[_0x41f5ea('0x22')]=_0x5df7a9[_0x41f5ea('0x22')]['length']?_0x5df7a9[_0x41f5ea('0x22')]:_0x12d5ce[_0x41f5ea('0x5')],_0x58b494[_0x41f5ea('0x20')]['includeAll']&&(_0x5df7a9[_0x41f5ea('0x3')]=[{'all':!![]}]),_0x5df7a9=_[_0x41f5ea('0x11')]({},_0x5df7a9,_0x58b494[_0x41f5ea('0x4')]),db[_0x41f5ea('0x2')][_0x41f5ea('0x2e')](_0x5df7a9)[_0x41f5ea('0x23')](handleEntityNotFound(_0x48f987,null))[_0x41f5ea('0x23')](respondWithResult(_0x48f987,null))['catch'](handleError(_0x48f987,null));},exports['create']=function(_0x3579c5,_0x2e05b7){const _0x101823=_0x4737b0;return db[_0x101823('0x2')][_0x101823('0x21')](_0x3579c5[_0x101823('0x1a')],{})[_0x101823('0x23')](respondWithResult(_0x2e05b7,0xc9))[_0x101823('0x32')](handleError(_0x2e05b7,null));},exports[_0x4737b0('0x10')]=function(_0x4f960e,_0x163a75){const _0x3b8a2c=_0x4737b0;return _0x4f960e[_0x3b8a2c('0x1a')]['id']&&delete _0x4f960e[_0x3b8a2c('0x1a')]['id'],db[_0x3b8a2c('0x2')][_0x3b8a2c('0x2e')]({'where':{'id':_0x4f960e[_0x3b8a2c('0xa')]['id']}})[_0x3b8a2c('0x23')](handleEntityNotFound(_0x163a75,null))[_0x3b8a2c('0x23')](saveUpdates(_0x4f960e[_0x3b8a2c('0x1a')],null))[_0x3b8a2c('0x23')](respondWithResult(_0x163a75,null))['catch'](handleError(_0x163a75,null));},exports['destroy']=function(_0x49d213,_0x42a463){const _0x170f29=_0x4737b0;return db[_0x170f29('0x2')][_0x170f29('0x2e')]({'where':{'id':_0x49d213[_0x170f29('0xa')]['id']}})[_0x170f29('0x23')](handleEntityNotFound(_0x42a463,null))[_0x170f29('0x23')](removeEntity(_0x42a463,null))[_0x170f29('0x32')](handleError(_0x42a463,null));},exports[_0x4737b0('0x9')]=function(_0x33f75d,_0x8cacf){const _0x2c15a2=_0x4737b0;return db[_0x2c15a2('0x2')][_0x2c15a2('0x9')]()[_0x2c15a2('0x23')](respondWithResult(_0x8cacf,null))[_0x2c15a2('0x32')](handleError(_0x8cacf,null));}; \ No newline at end of file diff --git a/server/api/mailSubstatus/mailSubstatus.model.js b/server/api/mailSubstatus/mailSubstatus.model.js index 101601c..0b31edc 100644 --- a/server/api/mailSubstatus/mailSubstatus.model.js +++ b/server/api/mailSubstatus/mailSubstatus.model.js @@ -1 +1 @@ -const a441_0x2197=['MailSubstatus','./mailSubstatus.attributes','mail_substatuses','define','exports'];(function(_0x5060ab,_0x219725){const _0x31cb6c=function(_0x21d1fc){while(--_0x21d1fc){_0x5060ab['push'](_0x5060ab['shift']());}};_0x31cb6c(++_0x219725);}(a441_0x2197,0x16e));const a441_0x31cb=function(_0x5060ab,_0x219725){_0x5060ab=_0x5060ab-0x0;let _0x31cb6c=a441_0x2197[_0x5060ab];return _0x31cb6c;};const _0x4bec52=a441_0x31cb;'use strict';const attributes=require(_0x4bec52('0x0'));module[_0x4bec52('0x3')]=function(_0x21d1fc){const _0x4575ae=_0x4bec52,_0x44dde5=_0x21d1fc[_0x4575ae('0x2')](_0x4575ae('0x4'),attributes,{'tableName':_0x4575ae('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x44dde5;}; \ No newline at end of file +const a441_0x30dc=['mail_substatuses','define','./mailSubstatus.attributes','exports','MailSubstatus'];(function(_0x57a9e1,_0x30dcdf){const _0x7180b=function(_0x3b24e2){while(--_0x3b24e2){_0x57a9e1['push'](_0x57a9e1['shift']());}};_0x7180b(++_0x30dcdf);}(a441_0x30dc,0x152));const a441_0x7180=function(_0x57a9e1,_0x30dcdf){_0x57a9e1=_0x57a9e1-0x0;let _0x7180b=a441_0x30dc[_0x57a9e1];return _0x7180b;};const _0x4589a2=a441_0x7180;'use strict';const attributes=require(_0x4589a2('0x4'));module[_0x4589a2('0x0')]=function(_0x3b24e2){const _0xba7472=_0x4589a2,_0x3be5c9=_0x3b24e2[_0xba7472('0x3')](_0xba7472('0x1'),attributes,{'tableName':_0xba7472('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3be5c9;}; \ No newline at end of file diff --git a/server/api/mailTransferReport/index.js b/server/api/mailTransferReport/index.js index c8275ee..904b405 100644 --- a/server/api/mailTransferReport/index.js +++ b/server/api/mailTransferReport/index.js @@ -1 +1 @@ -const a442_0x3f88=['update','./mailTransferReport.controller','index','isAuthenticated','create','show','express','/describe','describe','destroy','Router','/:id','get','exports','post'];(function(_0x3e78d2,_0x3f88c7){const _0x5ced3b=function(_0x1650c1){while(--_0x1650c1){_0x3e78d2['push'](_0x3e78d2['shift']());}};_0x5ced3b(++_0x3f88c7);}(a442_0x3f88,0x1bd));const a442_0x5ced=function(_0x3e78d2,_0x3f88c7){_0x3e78d2=_0x3e78d2-0x0;let _0x5ced3b=a442_0x3f88[_0x3e78d2];return _0x5ced3b;};const _0x5003a2=a442_0x5ced;'use strict';const express=require(_0x5003a2('0xb')),router=express[_0x5003a2('0x0')](),auth=require('../../components/auth/service'),controller=require(_0x5003a2('0x6'));router[_0x5003a2('0x2')]('/',auth['isAuthenticated'](),controller[_0x5003a2('0x7')]),router['get'](_0x5003a2('0xc'),auth['isAuthenticated'](),controller[_0x5003a2('0xd')]),router['get'](_0x5003a2('0x1'),auth['isAuthenticated'](),controller[_0x5003a2('0xa')]),router[_0x5003a2('0x4')]('/',auth[_0x5003a2('0x8')](),controller[_0x5003a2('0x9')]),router['put'](_0x5003a2('0x1'),auth[_0x5003a2('0x8')](),controller[_0x5003a2('0x5')]),router['delete'](_0x5003a2('0x1'),auth[_0x5003a2('0x8')](),controller[_0x5003a2('0xe')]),module[_0x5003a2('0x3')]=router; \ No newline at end of file +const a442_0x4a71=['Router','destroy','/describe','get','../../components/auth/service','/:id','describe','exports','isAuthenticated','show','./mailTransferReport.controller','update','delete'];(function(_0x35607b,_0x4a7102){const _0x3cccf6=function(_0x4b1289){while(--_0x4b1289){_0x35607b['push'](_0x35607b['shift']());}};_0x3cccf6(++_0x4a7102);}(a442_0x4a71,0xfd));const a442_0x3ccc=function(_0x35607b,_0x4a7102){_0x35607b=_0x35607b-0x0;let _0x3cccf6=a442_0x4a71[_0x35607b];return _0x3cccf6;};const _0x544173=a442_0x3ccc;'use strict';const express=require('express'),router=express[_0x544173('0x7')](),auth=require(_0x544173('0xb')),controller=require(_0x544173('0x4'));router[_0x544173('0xa')]('/',auth[_0x544173('0x2')](),controller['index']),router[_0x544173('0xa')](_0x544173('0x9'),auth['isAuthenticated'](),controller[_0x544173('0x0')]),router[_0x544173('0xa')](_0x544173('0xc'),auth[_0x544173('0x2')](),controller[_0x544173('0x3')]),router['post']('/',auth[_0x544173('0x2')](),controller['create']),router['put']('/:id',auth[_0x544173('0x2')](),controller[_0x544173('0x5')]),router[_0x544173('0x6')](_0x544173('0xc'),auth[_0x544173('0x2')](),controller[_0x544173('0x8')]),module[_0x544173('0x1')]=router; \ No newline at end of file diff --git a/server/api/mailTransferReport/mailTransferReport.attributes.js b/server/api/mailTransferReport/mailTransferReport.attributes.js index 68ca517..2d58664 100644 --- a/server/api/mailTransferReport/mailTransferReport.attributes.js +++ b/server/api/mailTransferReport/mailTransferReport.attributes.js @@ -1 +1 @@ -const a443_0x3a3a=['agent','exports','DATE','ENUM','queue','NOW','account','sequelize','STRING'];(function(_0x20818e,_0x3a3a10){const _0x455732=function(_0x2c6551){while(--_0x2c6551){_0x20818e['push'](_0x20818e['shift']());}};_0x455732(++_0x3a3a10);}(a443_0x3a3a,0x99));const a443_0x4557=function(_0x20818e,_0x3a3a10){_0x20818e=_0x20818e-0x0;let _0x455732=a443_0x3a3a[_0x20818e];return _0x455732;};const _0x3bd967=a443_0x4557;'use strict';const Sequelize=require(_0x3bd967('0x7'));module[_0x3bd967('0x1')]={'uniqueid':{'type':Sequelize[_0x3bd967('0x8')],'allowNull':![]},'type':{'type':Sequelize[_0x3bd967('0x3')](_0x3bd967('0x6'),_0x3bd967('0x0'),_0x3bd967('0x4')),'allowNull':![],'defaultValue':_0x3bd967('0x4')},'transferredAt':{'type':Sequelize[_0x3bd967('0x2')],'allowNull':![],'defaultValue':Sequelize[_0x3bd967('0x5')]}}; \ No newline at end of file +const a443_0x24aa=['NOW','DATE','sequelize','ENUM','exports','queue','account','STRING','agent'];(function(_0x1c3319,_0x24aa9a){const _0x6cb0a1=function(_0x217163){while(--_0x217163){_0x1c3319['push'](_0x1c3319['shift']());}};_0x6cb0a1(++_0x24aa9a);}(a443_0x24aa,0x13a));const a443_0x6cb0=function(_0x1c3319,_0x24aa9a){_0x1c3319=_0x1c3319-0x0;let _0x6cb0a1=a443_0x24aa[_0x1c3319];return _0x6cb0a1;};const _0x3440b3=a443_0x6cb0;'use strict';const Sequelize=require(_0x3440b3('0x3'));module[_0x3440b3('0x5')]={'uniqueid':{'type':Sequelize[_0x3440b3('0x8')],'allowNull':![]},'type':{'type':Sequelize[_0x3440b3('0x4')](_0x3440b3('0x7'),_0x3440b3('0x0'),_0x3440b3('0x6')),'allowNull':![],'defaultValue':'queue'},'transferredAt':{'type':Sequelize[_0x3440b3('0x2')],'allowNull':![],'defaultValue':Sequelize[_0x3440b3('0x1')]}}; \ No newline at end of file diff --git a/server/api/mailTransferReport/mailTransferReport.controller.js b/server/api/mailTransferReport/mailTransferReport.controller.js index f40eb48..8d7522b 100644 --- a/server/api/mailTransferReport/mailTransferReport.controller.js +++ b/server/api/mailTransferReport/mailTransferReport.controller.js @@ -1 +1 @@ -const a444_0x1a8c=['update','limit','length','include','lodash','../../mysqldb','send','findAll','where','nolimit','filters','destroy','../../components/parsers/qs','status','model','count','stack','attributes','merge','undefined','../../config/logger','includeAll','options','intersection','Content-Range','sequelize','MailTransferReport','catch','name','sort','sendStatus','VIRTUAL','order','index','then','rows','describe','set','end','filter','type','json','query','body','map','pick','keys','create','offset','findOne','params','fields'];(function(_0x3d7233,_0x1a8cc8){const _0x2b7f17=function(_0x4d52cf){while(--_0x4d52cf){_0x3d7233['push'](_0x3d7233['shift']());}};_0x2b7f17(++_0x1a8cc8);}(a444_0x1a8c,0x118));const a444_0x2b7f=function(_0x3d7233,_0x1a8cc8){_0x3d7233=_0x3d7233-0x0;let _0x2b7f17=a444_0x1a8c[_0x3d7233];return _0x2b7f17;};const _0x408c84=a444_0x2b7f;'use strict';const _=require(_0x408c84('0x24')),qs=require(_0x408c84('0x2c')),logger=require(_0x408c84('0x0'))('api'),db=require(_0x408c84('0x25'))['db'],{Op}=require(_0x408c84('0x5'));function respondWithResult(_0x4d52cf,_0x38bb7){return _0x38bb7=_0x38bb7||0xc8,function(_0x21f995){const _0x333e37=a444_0x2b7f;if(_0x21f995)return _0x4d52cf['status'](_0x38bb7)[_0x333e37('0x15')](_0x21f995);};}function respondWithFilteredResult(_0x5ae988,_0x178109){return function(_0x27a4fe){const _0x59befe=a444_0x2b7f;if(_0x27a4fe){const _0x54faa0=_0x27a4fe[_0x59befe('0x2f')],_0x1e8fbf=_0x178109['offset'];let _0xe1a4b8=_0x178109[_0x59befe('0x1c')]+_0x178109[_0x59befe('0x21')],_0x4a972a;return _0xe1a4b8>=_0x54faa0?(_0xe1a4b8=_0x54faa0,_0x4a972a=0xc8):_0x4a972a=0xce,_0x5ae988[_0x59befe('0x2d')](_0x4a972a),_0x5ae988[_0x59befe('0x11')](_0x59befe('0x4'),_0x1e8fbf+'-'+_0xe1a4b8+'/'+_0x54faa0)['json'](_0x27a4fe);}return null;};}function saveUpdates(_0x182e24){return function(_0x1cb4b3){const _0x1f7265=a444_0x2b7f;if(_0x1cb4b3)return _0x1cb4b3[_0x1f7265('0x20')](_0x182e24)[_0x1f7265('0xe')](function(_0x7e30dc){return _0x7e30dc;});return null;};}function removeEntity(_0x1c12d4){return function(_0x2685be){const _0x5e4e50=a444_0x2b7f;if(_0x2685be)return _0x2685be[_0x5e4e50('0x2b')]()['then'](function(){const _0x2b6e1f=_0x5e4e50;_0x1c12d4[_0x2b6e1f('0x2d')](0xcc)[_0x2b6e1f('0x12')]();});};}function handleEntityNotFound(_0x31e354){return function(_0x4331f7){const _0x5334d7=a444_0x2b7f;return!_0x4331f7&&_0x31e354[_0x5334d7('0xa')](0x194),_0x4331f7;};}function handleError(_0x518810,_0x1c881a){return _0x1c881a=_0x1c881a||0x1f4,function(_0x280a9b){const _0x306462=a444_0x2b7f;logger['error'](_0x280a9b[_0x306462('0x30')]),_0x280a9b[_0x306462('0x8')]&&delete _0x280a9b[_0x306462('0x8')],_0x518810[_0x306462('0x2d')](_0x1c881a)[_0x306462('0x26')](_0x280a9b);};}exports[_0x408c84('0xd')]=function(_0x49219f,_0x31cd73){const _0x211de0=_0x408c84;let _0x318a63={};const _0x32dc98={},_0x143763={'count':0x0,'rows':[]},_0x209fef=_['map'](db[_0x211de0('0x6')]['rawAttributes'],function(_0x385a8b){const _0x2128f8=_0x211de0;return{'name':_0x385a8b['fieldName'],'type':_0x385a8b[_0x2128f8('0x14')]['key']};});_0x32dc98[_0x211de0('0x2e')]=_[_0x211de0('0x18')](_0x209fef,_0x211de0('0x8')),_0x32dc98[_0x211de0('0x16')]=_[_0x211de0('0x1a')](_0x49219f['query']),_0x32dc98[_0x211de0('0x2a')]=_[_0x211de0('0x3')](_0x32dc98['model'],_0x32dc98[_0x211de0('0x16')]),_0x318a63[_0x211de0('0x31')]=_['intersection'](_0x32dc98[_0x211de0('0x2e')],qs[_0x211de0('0x1f')](_0x49219f[_0x211de0('0x16')][_0x211de0('0x1f')])),_0x318a63['attributes']=_0x318a63[_0x211de0('0x31')]['length']?_0x318a63[_0x211de0('0x31')]:_0x32dc98[_0x211de0('0x2e')];typeof _0x49219f['query'][_0x211de0('0x29')]===_0x211de0('0x33')&&(_0x318a63[_0x211de0('0x21')]=qs[_0x211de0('0x21')](_0x49219f[_0x211de0('0x16')][_0x211de0('0x21')]),_0x318a63['offset']=qs[_0x211de0('0x1c')](_0x49219f[_0x211de0('0x16')][_0x211de0('0x1c')]));_0x318a63[_0x211de0('0xc')]=qs['sort'](_0x49219f[_0x211de0('0x16')][_0x211de0('0x9')]),_0x318a63['where']=qs['filters'](_[_0x211de0('0x19')](_0x49219f[_0x211de0('0x16')],_0x32dc98[_0x211de0('0x2a')]),_0x209fef);_0x49219f[_0x211de0('0x16')][_0x211de0('0x13')]&&(_0x318a63['where']=_['merge'](_0x318a63['where'],{[Op['or']]:_['map'](_0x209fef,function(_0x5a3464){const _0x4be0d0=_0x211de0;if(_0x5a3464[_0x4be0d0('0x14')]!==_0x4be0d0('0xb')){const _0x303291={};return _0x303291[_0x5a3464['name']]={[Op['like']]:'%'+_0x49219f[_0x4be0d0('0x16')]['filter']+'%'},_0x303291;}})}));_0x318a63=_[_0x211de0('0x32')]({},_0x318a63,_0x49219f[_0x211de0('0x2')]);const _0x2d4bb1={'where':_0x318a63[_0x211de0('0x28')]};return db['MailTransferReport'][_0x211de0('0x2f')](_0x2d4bb1)['then'](function(_0x190afb){const _0x27ee6e=_0x211de0;return _0x143763['count']=_0x190afb,_0x49219f[_0x27ee6e('0x16')]['includeAll']&&(_0x318a63['include']=[{'all':!![]}]),db[_0x27ee6e('0x6')][_0x27ee6e('0x27')](_0x318a63);})[_0x211de0('0xe')](function(_0x589c2c){const _0x25281d=_0x211de0;return _0x143763[_0x25281d('0xf')]=_0x589c2c,_0x143763;})['then'](respondWithFilteredResult(_0x31cd73,_0x318a63))[_0x211de0('0x7')](handleError(_0x31cd73,null));},exports['show']=function(_0x5058d8,_0x38a75c){const _0x4ab619=_0x408c84;let _0x4731c1={'raw':!![],'where':{'id':_0x5058d8[_0x4ab619('0x1e')]['id']}};const _0x58a9b1={};return _0x58a9b1[_0x4ab619('0x2e')]=_['keys'](db[_0x4ab619('0x6')]['rawAttributes']),_0x58a9b1['query']=_[_0x4ab619('0x1a')](_0x5058d8['query']),_0x58a9b1[_0x4ab619('0x2a')]=_[_0x4ab619('0x3')](_0x58a9b1[_0x4ab619('0x2e')],_0x58a9b1[_0x4ab619('0x16')]),_0x4731c1['attributes']=_[_0x4ab619('0x3')](_0x58a9b1[_0x4ab619('0x2e')],qs[_0x4ab619('0x1f')](_0x5058d8['query'][_0x4ab619('0x1f')])),_0x4731c1['attributes']=_0x4731c1[_0x4ab619('0x31')][_0x4ab619('0x22')]?_0x4731c1[_0x4ab619('0x31')]:_0x58a9b1[_0x4ab619('0x2e')],_0x5058d8[_0x4ab619('0x16')][_0x4ab619('0x1')]&&(_0x4731c1[_0x4ab619('0x23')]=[{'all':!![]}]),_0x4731c1=_[_0x4ab619('0x32')]({},_0x4731c1,_0x5058d8['options']),db[_0x4ab619('0x6')][_0x4ab619('0x1d')](_0x4731c1)['then'](handleEntityNotFound(_0x38a75c,null))[_0x4ab619('0xe')](respondWithResult(_0x38a75c,null))[_0x4ab619('0x7')](handleError(_0x38a75c,null));},exports[_0x408c84('0x1b')]=function(_0x1d78d8,_0x34f433){const _0x692694=_0x408c84;return db['MailTransferReport']['create'](_0x1d78d8[_0x692694('0x17')],{})[_0x692694('0xe')](respondWithResult(_0x34f433,0xc9))[_0x692694('0x7')](handleError(_0x34f433,null));},exports['update']=function(_0x278ea5,_0x23bbcd){const _0x4c1b59=_0x408c84;return _0x278ea5[_0x4c1b59('0x17')]['id']&&delete _0x278ea5[_0x4c1b59('0x17')]['id'],db[_0x4c1b59('0x6')][_0x4c1b59('0x1d')]({'where':{'id':_0x278ea5[_0x4c1b59('0x1e')]['id']}})['then'](handleEntityNotFound(_0x23bbcd,null))[_0x4c1b59('0xe')](saveUpdates(_0x278ea5[_0x4c1b59('0x17')],null))[_0x4c1b59('0xe')](respondWithResult(_0x23bbcd,null))['catch'](handleError(_0x23bbcd,null));},exports[_0x408c84('0x2b')]=function(_0x4d285c,_0x4abb72){const _0x37d4aa=_0x408c84;return db['MailTransferReport'][_0x37d4aa('0x1d')]({'where':{'id':_0x4d285c[_0x37d4aa('0x1e')]['id']}})['then'](handleEntityNotFound(_0x4abb72,null))['then'](removeEntity(_0x4abb72,null))['catch'](handleError(_0x4abb72,null));},exports[_0x408c84('0x10')]=function(_0x3b5b60,_0x1be98){const _0x1f0a9f=_0x408c84;return db['MailTransferReport'][_0x1f0a9f('0x10')]()['then'](respondWithResult(_0x1be98,null))['catch'](handleError(_0x1be98,null));}; \ No newline at end of file +const a444_0x51a1=['index','length','type','MailTransferReport','pick','rows','keys','update','describe','undefined','where','Content-Range','count','filter','lodash','params','fields','key','like','model','map','offset','limit','intersection','then','includeAll','catch','status','body','show','order','name','set','json','nolimit','query','error','sequelize','rawAttributes','end','options','../../mysqldb','destroy','findOne','send','attributes','api','include','filters'];(function(_0x1f087f,_0x51a101){const _0x2dd682=function(_0x959d6){while(--_0x959d6){_0x1f087f['push'](_0x1f087f['shift']());}};_0x2dd682(++_0x51a101);}(a444_0x51a1,0x7a));const a444_0x2dd6=function(_0x1f087f,_0x51a101){_0x1f087f=_0x1f087f-0x0;let _0x2dd682=a444_0x51a1[_0x1f087f];return _0x2dd682;};const _0x42e3f3=a444_0x2dd6;'use strict';const _=require(_0x42e3f3('0x27')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x42e3f3('0x16')),db=require(_0x42e3f3('0x11'))['db'],{Op}=require(_0x42e3f3('0xd'));function respondWithResult(_0x959d6,_0x472191){return _0x472191=_0x472191||0xc8,function(_0x14406b){const _0x44fcf0=a444_0x2dd6;if(_0x14406b)return _0x959d6[_0x44fcf0('0x3')](_0x472191)[_0x44fcf0('0x9')](_0x14406b);};}function respondWithFilteredResult(_0x51c3bf,_0x2dd45b){return function(_0x6eea16){const _0x31a8b8=a444_0x2dd6;if(_0x6eea16){const _0x4cf58b=_0x6eea16[_0x31a8b8('0x25')],_0x2d9757=_0x2dd45b[_0x31a8b8('0x2e')];let _0x4b8970=_0x2dd45b[_0x31a8b8('0x2e')]+_0x2dd45b['limit'],_0x29067a;return _0x4b8970>=_0x4cf58b?(_0x4b8970=_0x4cf58b,_0x29067a=0xc8):_0x29067a=0xce,_0x51c3bf[_0x31a8b8('0x3')](_0x29067a),_0x51c3bf[_0x31a8b8('0x8')](_0x31a8b8('0x24'),_0x2d9757+'-'+_0x4b8970+'/'+_0x4cf58b)[_0x31a8b8('0x9')](_0x6eea16);}return null;};}function saveUpdates(_0x393fd4){return function(_0x8694d3){const _0x38bea8=a444_0x2dd6;if(_0x8694d3)return _0x8694d3['update'](_0x393fd4)[_0x38bea8('0x0')](function(_0x110c13){return _0x110c13;});return null;};}function removeEntity(_0x4f2155){return function(_0x1c3274){const _0x7de490=a444_0x2dd6;if(_0x1c3274)return _0x1c3274[_0x7de490('0x12')]()[_0x7de490('0x0')](function(){const _0x4c250c=_0x7de490;_0x4f2155[_0x4c250c('0x3')](0xcc)[_0x4c250c('0xf')]();});};}function handleEntityNotFound(_0x58ce84){return function(_0x3657fb){return!_0x3657fb&&_0x58ce84['sendStatus'](0x194),_0x3657fb;};}function handleError(_0x378c2c,_0x12a795){return _0x12a795=_0x12a795||0x1f4,function(_0x38f35b){const _0x279e40=a444_0x2dd6;logger[_0x279e40('0xc')](_0x38f35b['stack']),_0x38f35b[_0x279e40('0x7')]&&delete _0x38f35b[_0x279e40('0x7')],_0x378c2c[_0x279e40('0x3')](_0x12a795)[_0x279e40('0x14')](_0x38f35b);};}exports[_0x42e3f3('0x19')]=function(_0x3c2af8,_0x5984af){const _0x57bcd8=_0x42e3f3;let _0x3b2749={};const _0x20349c={},_0x2d7da2={'count':0x0,'rows':[]},_0x162bc1=_[_0x57bcd8('0x2d')](db[_0x57bcd8('0x1c')][_0x57bcd8('0xe')],function(_0x5bd3e5){const _0x5c58bc=_0x57bcd8;return{'name':_0x5bd3e5['fieldName'],'type':_0x5bd3e5['type'][_0x5c58bc('0x2a')]};});_0x20349c['model']=_[_0x57bcd8('0x2d')](_0x162bc1,_0x57bcd8('0x7')),_0x20349c[_0x57bcd8('0xb')]=_[_0x57bcd8('0x1f')](_0x3c2af8[_0x57bcd8('0xb')]),_0x20349c['filters']=_[_0x57bcd8('0x30')](_0x20349c[_0x57bcd8('0x2c')],_0x20349c[_0x57bcd8('0xb')]),_0x3b2749['attributes']=_[_0x57bcd8('0x30')](_0x20349c[_0x57bcd8('0x2c')],qs[_0x57bcd8('0x29')](_0x3c2af8[_0x57bcd8('0xb')][_0x57bcd8('0x29')])),_0x3b2749[_0x57bcd8('0x15')]=_0x3b2749['attributes']['length']?_0x3b2749[_0x57bcd8('0x15')]:_0x20349c[_0x57bcd8('0x2c')];typeof _0x3c2af8[_0x57bcd8('0xb')][_0x57bcd8('0xa')]===_0x57bcd8('0x22')&&(_0x3b2749[_0x57bcd8('0x2f')]=qs[_0x57bcd8('0x2f')](_0x3c2af8['query']['limit']),_0x3b2749[_0x57bcd8('0x2e')]=qs[_0x57bcd8('0x2e')](_0x3c2af8[_0x57bcd8('0xb')][_0x57bcd8('0x2e')]));_0x3b2749[_0x57bcd8('0x6')]=qs['sort'](_0x3c2af8['query']['sort']),_0x3b2749['where']=qs[_0x57bcd8('0x18')](_[_0x57bcd8('0x1d')](_0x3c2af8['query'],_0x20349c[_0x57bcd8('0x18')]),_0x162bc1);_0x3c2af8[_0x57bcd8('0xb')][_0x57bcd8('0x26')]&&(_0x3b2749[_0x57bcd8('0x23')]=_['merge'](_0x3b2749['where'],{[Op['or']]:_[_0x57bcd8('0x2d')](_0x162bc1,function(_0xac2c0){const _0x2a958b=_0x57bcd8;if(_0xac2c0[_0x2a958b('0x1b')]!=='VIRTUAL'){const _0x2b6ec7={};return _0x2b6ec7[_0xac2c0[_0x2a958b('0x7')]]={[Op[_0x2a958b('0x2b')]]:'%'+_0x3c2af8[_0x2a958b('0xb')][_0x2a958b('0x26')]+'%'},_0x2b6ec7;}})}));_0x3b2749=_['merge']({},_0x3b2749,_0x3c2af8['options']);const _0x15101c={'where':_0x3b2749[_0x57bcd8('0x23')]};return db[_0x57bcd8('0x1c')][_0x57bcd8('0x25')](_0x15101c)[_0x57bcd8('0x0')](function(_0x217dcf){const _0x1d532b=_0x57bcd8;return _0x2d7da2[_0x1d532b('0x25')]=_0x217dcf,_0x3c2af8['query'][_0x1d532b('0x1')]&&(_0x3b2749[_0x1d532b('0x17')]=[{'all':!![]}]),db['MailTransferReport']['findAll'](_0x3b2749);})[_0x57bcd8('0x0')](function(_0x2111bf){const _0x4e03fd=_0x57bcd8;return _0x2d7da2[_0x4e03fd('0x1e')]=_0x2111bf,_0x2d7da2;})['then'](respondWithFilteredResult(_0x5984af,_0x3b2749))[_0x57bcd8('0x2')](handleError(_0x5984af,null));},exports[_0x42e3f3('0x5')]=function(_0x25f5ee,_0x554ce9){const _0x55fbdf=_0x42e3f3;let _0x1c44f3={'raw':!![],'where':{'id':_0x25f5ee['params']['id']}};const _0x56ea1a={};return _0x56ea1a['model']=_[_0x55fbdf('0x1f')](db[_0x55fbdf('0x1c')][_0x55fbdf('0xe')]),_0x56ea1a[_0x55fbdf('0xb')]=_[_0x55fbdf('0x1f')](_0x25f5ee[_0x55fbdf('0xb')]),_0x56ea1a[_0x55fbdf('0x18')]=_['intersection'](_0x56ea1a[_0x55fbdf('0x2c')],_0x56ea1a['query']),_0x1c44f3[_0x55fbdf('0x15')]=_[_0x55fbdf('0x30')](_0x56ea1a[_0x55fbdf('0x2c')],qs['fields'](_0x25f5ee[_0x55fbdf('0xb')][_0x55fbdf('0x29')])),_0x1c44f3[_0x55fbdf('0x15')]=_0x1c44f3[_0x55fbdf('0x15')][_0x55fbdf('0x1a')]?_0x1c44f3[_0x55fbdf('0x15')]:_0x56ea1a['model'],_0x25f5ee[_0x55fbdf('0xb')][_0x55fbdf('0x1')]&&(_0x1c44f3['include']=[{'all':!![]}]),_0x1c44f3=_['merge']({},_0x1c44f3,_0x25f5ee[_0x55fbdf('0x10')]),db[_0x55fbdf('0x1c')][_0x55fbdf('0x13')](_0x1c44f3)['then'](handleEntityNotFound(_0x554ce9,null))[_0x55fbdf('0x0')](respondWithResult(_0x554ce9,null))['catch'](handleError(_0x554ce9,null));},exports['create']=function(_0x2eb9b9,_0x3e2361){const _0x884a70=_0x42e3f3;return db[_0x884a70('0x1c')]['create'](_0x2eb9b9['body'],{})[_0x884a70('0x0')](respondWithResult(_0x3e2361,0xc9))['catch'](handleError(_0x3e2361,null));},exports[_0x42e3f3('0x20')]=function(_0xcff880,_0x570037){const _0xa208b9=_0x42e3f3;return _0xcff880['body']['id']&&delete _0xcff880['body']['id'],db['MailTransferReport'][_0xa208b9('0x13')]({'where':{'id':_0xcff880[_0xa208b9('0x28')]['id']}})[_0xa208b9('0x0')](handleEntityNotFound(_0x570037,null))[_0xa208b9('0x0')](saveUpdates(_0xcff880[_0xa208b9('0x4')],null))[_0xa208b9('0x0')](respondWithResult(_0x570037,null))[_0xa208b9('0x2')](handleError(_0x570037,null));},exports[_0x42e3f3('0x12')]=function(_0x6c7ba,_0x2e499f){const _0x1549fc=_0x42e3f3;return db[_0x1549fc('0x1c')][_0x1549fc('0x13')]({'where':{'id':_0x6c7ba[_0x1549fc('0x28')]['id']}})[_0x1549fc('0x0')](handleEntityNotFound(_0x2e499f,null))[_0x1549fc('0x0')](removeEntity(_0x2e499f,null))[_0x1549fc('0x2')](handleError(_0x2e499f,null));},exports[_0x42e3f3('0x21')]=function(_0x36e7a8,_0x424396){const _0x566f19=_0x42e3f3;return db['MailTransferReport'][_0x566f19('0x21')]()[_0x566f19('0x0')](respondWithResult(_0x424396,null))[_0x566f19('0x2')](handleError(_0x424396,null));}; \ No newline at end of file diff --git a/server/api/mailTransferReport/mailTransferReport.model.js b/server/api/mailTransferReport/mailTransferReport.model.js index 2d4605e..f5667d3 100644 --- a/server/api/mailTransferReport/mailTransferReport.model.js +++ b/server/api/mailTransferReport/mailTransferReport.model.js @@ -1 +1 @@ -const a445_0x896a=['./mailTransferReport.attributes','MailTransferReport','define','uniqueid','report_mail_transfer','exports'];(function(_0x1aa58e,_0x896a90){const _0x79eca2=function(_0x2de90a){while(--_0x2de90a){_0x1aa58e['push'](_0x1aa58e['shift']());}};_0x79eca2(++_0x896a90);}(a445_0x896a,0x15d));const a445_0x79ec=function(_0x1aa58e,_0x896a90){_0x1aa58e=_0x1aa58e-0x0;let _0x79eca2=a445_0x896a[_0x1aa58e];return _0x79eca2;};const _0x3a87c5=a445_0x79ec;'use strict';const attributes=require(_0x3a87c5('0x5'));module[_0x3a87c5('0x4')]=function(_0x2de90a){const _0xf0c4d0=_0x3a87c5,_0x3815e1=_0x2de90a[_0xf0c4d0('0x1')](_0xf0c4d0('0x0'),attributes,{'tableName':_0xf0c4d0('0x3'),'paranoid':![],'indexes':[{'name':_0xf0c4d0('0x2'),'fields':['uniqueid']}],'timestamps':!![]});return _0x3815e1;}; \ No newline at end of file +const a445_0x27a2=['./mailTransferReport.attributes','uniqueid','exports','report_mail_transfer','define','MailTransferReport'];(function(_0x23e731,_0x27a2d4){const _0x2e119c=function(_0x250854){while(--_0x250854){_0x23e731['push'](_0x23e731['shift']());}};_0x2e119c(++_0x27a2d4);}(a445_0x27a2,0x1c0));const a445_0x2e11=function(_0x23e731,_0x27a2d4){_0x23e731=_0x23e731-0x0;let _0x2e119c=a445_0x27a2[_0x23e731];return _0x2e119c;};const _0x15eadb=a445_0x2e11;'use strict';const attributes=require(_0x15eadb('0x2'));module[_0x15eadb('0x4')]=function(_0x250854){const _0x41118c=_0x15eadb,_0x1cdcba=_0x250854[_0x41118c('0x0')](_0x41118c('0x1'),attributes,{'tableName':_0x41118c('0x5'),'paranoid':![],'indexes':[{'name':_0x41118c('0x3'),'fields':[_0x41118c('0x3')]}],'timestamps':!![]});return _0x1cdcba;}; \ No newline at end of file diff --git a/server/api/memberReport/index.js b/server/api/memberReport/index.js index 7bc86ed..c2ba568 100644 --- a/server/api/memberReport/index.js +++ b/server/api/memberReport/index.js @@ -1 +1 @@ -const a446_0x1943=['destroy','describe','express','get','show','../../components/auth/service','Router','./memberReport.controller','isAuthenticated','/:id','exports','update'];(function(_0x3c974d,_0x194324){const _0x1180d7=function(_0x11f913){while(--_0x11f913){_0x3c974d['push'](_0x3c974d['shift']());}};_0x1180d7(++_0x194324);}(a446_0x1943,0x1d0));const a446_0x1180=function(_0x3c974d,_0x194324){_0x3c974d=_0x3c974d-0x0;let _0x1180d7=a446_0x1943[_0x3c974d];return _0x1180d7;};const _0xbcbdc0=a446_0x1180;'use strict';const express=require(_0xbcbdc0('0x6')),router=express[_0xbcbdc0('0xa')](),auth=require(_0xbcbdc0('0x9')),controller=require(_0xbcbdc0('0xb'));router[_0xbcbdc0('0x7')]('/',auth[_0xbcbdc0('0x0')](),controller['index']),router['get']('/describe',auth[_0xbcbdc0('0x0')](),controller[_0xbcbdc0('0x5')]),router[_0xbcbdc0('0x7')]('/:id',auth['isAuthenticated'](),controller[_0xbcbdc0('0x8')]),router['post']('/',auth['isAuthenticated'](),controller['create']),router['put'](_0xbcbdc0('0x1'),auth[_0xbcbdc0('0x0')](),controller[_0xbcbdc0('0x3')]),router['delete'](_0xbcbdc0('0x1'),auth[_0xbcbdc0('0x0')](),controller[_0xbcbdc0('0x4')]),module[_0xbcbdc0('0x2')]=router; \ No newline at end of file +const a446_0x22da=['../../components/auth/service','Router','describe','exports','./memberReport.controller','isAuthenticated','destroy','update','index','delete','/describe','get','express','show','create','/:id','post'];(function(_0x364387,_0x22da65){const _0x2ae960=function(_0x42e976){while(--_0x42e976){_0x364387['push'](_0x364387['shift']());}};_0x2ae960(++_0x22da65);}(a446_0x22da,0xb5));const a446_0x2ae9=function(_0x364387,_0x22da65){_0x364387=_0x364387-0x0;let _0x2ae960=a446_0x22da[_0x364387];return _0x2ae960;};const _0x397bc1=a446_0x2ae9;'use strict';const express=require(_0x397bc1('0x1')),router=express[_0x397bc1('0x7')](),auth=require(_0x397bc1('0x6')),controller=require(_0x397bc1('0xa'));router[_0x397bc1('0x0')]('/',auth[_0x397bc1('0xb')](),controller[_0x397bc1('0xe')]),router[_0x397bc1('0x0')](_0x397bc1('0x10'),auth[_0x397bc1('0xb')](),controller[_0x397bc1('0x8')]),router['get'](_0x397bc1('0x4'),auth[_0x397bc1('0xb')](),controller[_0x397bc1('0x2')]),router[_0x397bc1('0x5')]('/',auth[_0x397bc1('0xb')](),controller[_0x397bc1('0x3')]),router['put']('/:id',auth[_0x397bc1('0xb')](),controller[_0x397bc1('0xd')]),router[_0x397bc1('0xf')](_0x397bc1('0x4'),auth[_0x397bc1('0xb')](),controller[_0x397bc1('0xc')]),module[_0x397bc1('0x9')]=router; \ No newline at end of file diff --git a/server/api/memberReport/memberReport.attributes.js b/server/api/memberReport/memberReport.attributes.js index 2ed8b0d..2f202fb 100644 --- a/server/api/memberReport/memberReport.attributes.js +++ b/server/api/memberReport/memberReport.attributes.js @@ -1 +1 @@ -const a447_0x5b9b=['talk:[dial\x20string]','talk:[inbound,\x20outbound],\x20pause:[reason]','getDataValue','talk:[destination]','seconds','moment','STRING','exitAt','sequelize','INTEGER','diff','talk:[start]','exports','setDataValue','talk:[queue]'];(function(_0x40f189,_0x5b9b95){const _0x34f8c6=function(_0x3ed97a){while(--_0x3ed97a){_0x40f189['push'](_0x40f189['shift']());}};_0x34f8c6(++_0x5b9b95);}(a447_0x5b9b,0x1d6));const a447_0x34f8=function(_0x40f189,_0x5b9b95){_0x40f189=_0x40f189-0x0;let _0x34f8c6=a447_0x5b9b[_0x40f189];return _0x34f8c6;};const _0x1c10bb=a447_0x34f8;'use strict';const Sequelize=require(_0x1c10bb('0x3')),moment=require(_0x1c10bb('0x0'));module[_0x1c10bb('0x7')]={'channel':{'type':Sequelize[_0x1c10bb('0x1')]},'membername':{'type':Sequelize[_0x1c10bb('0x1')]},'interface':{'type':Sequelize['STRING']},'type':{'type':Sequelize[_0x1c10bb('0x1')],'defaultValue':'DEFAULT\x20PAUSE','comment':'LOGIN,\x20PAUSE,\x20TALKING'},'duration':{'type':Sequelize[_0x1c10bb('0x4')]},'enterAt':{'type':Sequelize['DATE']},'exitAt':{'type':Sequelize['DATE'],'set':function(_0x3ed97a){const _0x36a828=_0x1c10bb,_0x485302=moment(_0x3ed97a),_0xbb3b9e=moment(this[_0x36a828('0xc')]('enterAt')),_0x5c3bdc=_0x485302[_0x36a828('0x5')](_0xbb3b9e,_0x36a828('0xe'));this['setDataValue'](_0x36a828('0x2'),_0x3ed97a),this[_0x36a828('0x8')]('duration',_0x5c3bdc||null);}},'data1':{'type':Sequelize['STRING'],'comment':_0x1c10bb('0xb')},'data2':{'type':Sequelize[_0x1c10bb('0x1')],'comment':_0x1c10bb('0x6')},'data3':{'type':Sequelize[_0x1c10bb('0x1')],'comment':_0x1c10bb('0xd')},'data4':{'type':Sequelize[_0x1c10bb('0x1')],'comment':_0x1c10bb('0xa')},'data5':{'type':Sequelize[_0x1c10bb('0x1')],'comment':_0x1c10bb('0x9')},'role':{'type':Sequelize[_0x1c10bb('0x1')]},'internal':{'type':Sequelize[_0x1c10bb('0x4')]},'uniqueid':{'type':Sequelize[_0x1c10bb('0x1')]}}; \ No newline at end of file +const a447_0x4256=['duration','talk:[inbound,\x20outbound],\x20pause:[reason]','STRING','getDataValue','setDataValue','talk:[dial\x20string]','sequelize','DATE','seconds','DEFAULT\x20PAUSE','talk:[queue]','talk:[destination]','talk:[start]','INTEGER','diff'];(function(_0x1cda85,_0x425640){const _0x594d68=function(_0x2103f2){while(--_0x2103f2){_0x1cda85['push'](_0x1cda85['shift']());}};_0x594d68(++_0x425640);}(a447_0x4256,0x198));const a447_0x594d=function(_0x1cda85,_0x425640){_0x1cda85=_0x1cda85-0x0;let _0x594d68=a447_0x4256[_0x1cda85];return _0x594d68;};const _0x2dc4c1=a447_0x594d;'use strict';const Sequelize=require(_0x2dc4c1('0x3')),moment=require('moment');module['exports']={'channel':{'type':Sequelize[_0x2dc4c1('0xe')]},'membername':{'type':Sequelize['STRING']},'interface':{'type':Sequelize[_0x2dc4c1('0xe')]},'type':{'type':Sequelize[_0x2dc4c1('0xe')],'defaultValue':_0x2dc4c1('0x6'),'comment':'LOGIN,\x20PAUSE,\x20TALKING'},'duration':{'type':Sequelize[_0x2dc4c1('0xa')]},'enterAt':{'type':Sequelize[_0x2dc4c1('0x4')]},'exitAt':{'type':Sequelize[_0x2dc4c1('0x4')],'set':function(_0x2103f2){const _0x33bdbf=_0x2dc4c1,_0x18fdd0=moment(_0x2103f2),_0x2efb42=moment(this[_0x33bdbf('0x0')]('enterAt')),_0x4906eb=_0x18fdd0[_0x33bdbf('0xb')](_0x2efb42,_0x33bdbf('0x5'));this['setDataValue']('exitAt',_0x2103f2),this[_0x33bdbf('0x1')](_0x33bdbf('0xc'),_0x4906eb||null);}},'data1':{'type':Sequelize[_0x2dc4c1('0xe')],'comment':_0x2dc4c1('0xd')},'data2':{'type':Sequelize[_0x2dc4c1('0xe')],'comment':_0x2dc4c1('0x9')},'data3':{'type':Sequelize[_0x2dc4c1('0xe')],'comment':_0x2dc4c1('0x8')},'data4':{'type':Sequelize['STRING'],'comment':_0x2dc4c1('0x2')},'data5':{'type':Sequelize[_0x2dc4c1('0xe')],'comment':_0x2dc4c1('0x7')},'role':{'type':Sequelize[_0x2dc4c1('0xe')]},'internal':{'type':Sequelize[_0x2dc4c1('0xa')]},'uniqueid':{'type':Sequelize[_0x2dc4c1('0xe')]}}; \ No newline at end of file diff --git a/server/api/memberReport/memberReport.controller.js b/server/api/memberReport/memberReport.controller.js index e3fee6d..8589ff7 100644 --- a/server/api/memberReport/memberReport.controller.js +++ b/server/api/memberReport/memberReport.controller.js @@ -1 +1 @@ -const a448_0x4fcc=['where','../../mysqldb','sort','includeAll','intersection','end','MemberReport','api','show','model','count','key','status','fields','filter','VIRTUAL','limit','query','merge','lodash','index','pick','../../components/parsers/qs','name','options','fieldName','create','send','offset','map','length','body','destroy','undefined','describe','keys','like','stack','order','then','sendStatus','findOne','set','attributes','include','catch','type','rawAttributes','filters','rows','update'];(function(_0x5133d4,_0x4fccb7){const _0x4c9eef=function(_0x40574b){while(--_0x40574b){_0x5133d4['push'](_0x5133d4['shift']());}};_0x4c9eef(++_0x4fccb7);}(a448_0x4fcc,0xd3));const a448_0x4c9e=function(_0x5133d4,_0x4fccb7){_0x5133d4=_0x5133d4-0x0;let _0x4c9eef=a448_0x4fcc[_0x5133d4];return _0x4c9eef;};const _0x55f16c=a448_0x4c9e;'use strict';const _=require(_0x55f16c('0xc')),qs=require(_0x55f16c('0xf')),logger=require('../../config/logger')(_0x55f16c('0x0')),db=require(_0x55f16c('0x2d'))['db'],{Op}=require('sequelize');function respondWithResult(_0x40574b,_0x3cf6d6){return _0x3cf6d6=_0x3cf6d6||0xc8,function(_0x35cc0e){if(_0x35cc0e)return _0x40574b['status'](_0x3cf6d6)['json'](_0x35cc0e);};}function respondWithFilteredResult(_0x483fce,_0x47018b){return function(_0x2ccb90){const _0x41f472=a448_0x4c9e;if(_0x2ccb90){const _0x178a4f=_0x2ccb90['count'],_0x5257d2=_0x47018b[_0x41f472('0x15')];let _0xbfe87a=_0x47018b[_0x41f472('0x15')]+_0x47018b['limit'],_0x120923;return _0xbfe87a>=_0x178a4f?(_0xbfe87a=_0x178a4f,_0x120923=0xc8):_0x120923=0xce,_0x483fce[_0x41f472('0x5')](_0x120923),_0x483fce[_0x41f472('0x23')]('Content-Range',_0x5257d2+'-'+_0xbfe87a+'/'+_0x178a4f)['json'](_0x2ccb90);}return null;};}function saveUpdates(_0x4fe9dd){return function(_0x228f03){const _0x169dda=a448_0x4c9e;if(_0x228f03)return _0x228f03[_0x169dda('0x2b')](_0x4fe9dd)[_0x169dda('0x20')](function(_0x5cb3bd){return _0x5cb3bd;});return null;};}function removeEntity(_0x149ab5){return function(_0x53eb28){const _0x1ec20e=a448_0x4c9e;if(_0x53eb28)return _0x53eb28[_0x1ec20e('0x19')]()[_0x1ec20e('0x20')](function(){const _0x5e1ff6=_0x1ec20e;_0x149ab5[_0x5e1ff6('0x5')](0xcc)[_0x5e1ff6('0x31')]();});};}function handleEntityNotFound(_0x54bee8){return function(_0x294275){const _0x29906f=a448_0x4c9e;return!_0x294275&&_0x54bee8[_0x29906f('0x21')](0x194),_0x294275;};}function handleError(_0x342a84,_0x83d43e){return _0x83d43e=_0x83d43e||0x1f4,function(_0x2ca786){const _0x23197c=a448_0x4c9e;logger['error'](_0x2ca786[_0x23197c('0x1e')]),_0x2ca786[_0x23197c('0x10')]&&delete _0x2ca786[_0x23197c('0x10')],_0x342a84[_0x23197c('0x5')](_0x83d43e)[_0x23197c('0x14')](_0x2ca786);};}exports[_0x55f16c('0xd')]=function(_0x417f7e,_0x4d0d29){const _0x3be5ef=_0x55f16c;let _0x9b1ae1={};const _0x2cf472={},_0x3badeb={'count':0x0,'rows':[]},_0x63670b=_[_0x3be5ef('0x16')](db[_0x3be5ef('0x32')][_0x3be5ef('0x28')],function(_0x588c9b){const _0x359528=_0x3be5ef;return{'name':_0x588c9b[_0x359528('0x12')],'type':_0x588c9b[_0x359528('0x27')][_0x359528('0x4')]};});_0x2cf472[_0x3be5ef('0x2')]=_['map'](_0x63670b,_0x3be5ef('0x10')),_0x2cf472['query']=_['keys'](_0x417f7e[_0x3be5ef('0xa')]),_0x2cf472[_0x3be5ef('0x29')]=_[_0x3be5ef('0x30')](_0x2cf472[_0x3be5ef('0x2')],_0x2cf472['query']),_0x9b1ae1[_0x3be5ef('0x24')]=_[_0x3be5ef('0x30')](_0x2cf472[_0x3be5ef('0x2')],qs[_0x3be5ef('0x6')](_0x417f7e[_0x3be5ef('0xa')][_0x3be5ef('0x6')])),_0x9b1ae1[_0x3be5ef('0x24')]=_0x9b1ae1[_0x3be5ef('0x24')][_0x3be5ef('0x17')]?_0x9b1ae1[_0x3be5ef('0x24')]:_0x2cf472['model'];typeof _0x417f7e['query']['nolimit']===_0x3be5ef('0x1a')&&(_0x9b1ae1['limit']=qs[_0x3be5ef('0x9')](_0x417f7e[_0x3be5ef('0xa')]['limit']),_0x9b1ae1[_0x3be5ef('0x15')]=qs[_0x3be5ef('0x15')](_0x417f7e['query'][_0x3be5ef('0x15')]));_0x9b1ae1[_0x3be5ef('0x1f')]=qs[_0x3be5ef('0x2e')](_0x417f7e[_0x3be5ef('0xa')]['sort']),_0x9b1ae1[_0x3be5ef('0x2c')]=qs[_0x3be5ef('0x29')](_[_0x3be5ef('0xe')](_0x417f7e['query'],_0x2cf472['filters']),_0x63670b);_0x417f7e[_0x3be5ef('0xa')][_0x3be5ef('0x7')]&&(_0x9b1ae1['where']=_[_0x3be5ef('0xb')](_0x9b1ae1[_0x3be5ef('0x2c')],{[Op['or']]:_[_0x3be5ef('0x16')](_0x63670b,function(_0x3803ce){const _0x200bfe=_0x3be5ef;if(_0x3803ce[_0x200bfe('0x27')]!==_0x200bfe('0x8')){const _0x176872={};return _0x176872[_0x3803ce['name']]={[Op[_0x200bfe('0x1d')]]:'%'+_0x417f7e['query'][_0x200bfe('0x7')]+'%'},_0x176872;}})}));_0x9b1ae1=_[_0x3be5ef('0xb')]({},_0x9b1ae1,_0x417f7e[_0x3be5ef('0x11')]);const _0x70b299={'where':_0x9b1ae1[_0x3be5ef('0x2c')]};return db[_0x3be5ef('0x32')][_0x3be5ef('0x3')](_0x70b299)[_0x3be5ef('0x20')](function(_0x23a879){const _0x35525c=_0x3be5ef;return _0x3badeb[_0x35525c('0x3')]=_0x23a879,_0x417f7e[_0x35525c('0xa')]['includeAll']&&(_0x9b1ae1[_0x35525c('0x25')]=[{'all':!![]}]),db[_0x35525c('0x32')]['findAll'](_0x9b1ae1);})['then'](function(_0x30aa94){const _0x36d76f=_0x3be5ef;return _0x3badeb[_0x36d76f('0x2a')]=_0x30aa94,_0x3badeb;})[_0x3be5ef('0x20')](respondWithFilteredResult(_0x4d0d29,_0x9b1ae1))[_0x3be5ef('0x26')](handleError(_0x4d0d29,null));},exports[_0x55f16c('0x1')]=function(_0x2d9257,_0x161d02){const _0x3cc28c=_0x55f16c;let _0x47bef1={'raw':!![],'where':{'id':_0x2d9257['params']['id']}};const _0x4705c1={};return _0x4705c1['model']=_[_0x3cc28c('0x1c')](db[_0x3cc28c('0x32')]['rawAttributes']),_0x4705c1[_0x3cc28c('0xa')]=_[_0x3cc28c('0x1c')](_0x2d9257[_0x3cc28c('0xa')]),_0x4705c1['filters']=_[_0x3cc28c('0x30')](_0x4705c1[_0x3cc28c('0x2')],_0x4705c1[_0x3cc28c('0xa')]),_0x47bef1[_0x3cc28c('0x24')]=_[_0x3cc28c('0x30')](_0x4705c1[_0x3cc28c('0x2')],qs[_0x3cc28c('0x6')](_0x2d9257[_0x3cc28c('0xa')][_0x3cc28c('0x6')])),_0x47bef1['attributes']=_0x47bef1[_0x3cc28c('0x24')][_0x3cc28c('0x17')]?_0x47bef1[_0x3cc28c('0x24')]:_0x4705c1[_0x3cc28c('0x2')],_0x2d9257[_0x3cc28c('0xa')][_0x3cc28c('0x2f')]&&(_0x47bef1[_0x3cc28c('0x25')]=[{'all':!![]}]),_0x47bef1=_['merge']({},_0x47bef1,_0x2d9257['options']),db['MemberReport'][_0x3cc28c('0x22')](_0x47bef1)[_0x3cc28c('0x20')](handleEntityNotFound(_0x161d02,null))[_0x3cc28c('0x20')](respondWithResult(_0x161d02,null))['catch'](handleError(_0x161d02,null));},exports[_0x55f16c('0x13')]=function(_0xae28c0,_0x4e9d8d){const _0x47e54d=_0x55f16c;return db['MemberReport'][_0x47e54d('0x13')](_0xae28c0[_0x47e54d('0x18')],{})[_0x47e54d('0x20')](respondWithResult(_0x4e9d8d,0xc9))[_0x47e54d('0x26')](handleError(_0x4e9d8d,null));},exports[_0x55f16c('0x2b')]=function(_0x319bc1,_0x3e2150){const _0x2a0b52=_0x55f16c;return _0x319bc1[_0x2a0b52('0x18')]['id']&&delete _0x319bc1[_0x2a0b52('0x18')]['id'],db[_0x2a0b52('0x32')][_0x2a0b52('0x22')]({'where':{'id':_0x319bc1['params']['id']}})[_0x2a0b52('0x20')](handleEntityNotFound(_0x3e2150,null))['then'](saveUpdates(_0x319bc1['body'],null))['then'](respondWithResult(_0x3e2150,null))['catch'](handleError(_0x3e2150,null));},exports[_0x55f16c('0x19')]=function(_0x5a0ad3,_0x1fa9d9){const _0x2ce9b9=_0x55f16c;return db[_0x2ce9b9('0x32')][_0x2ce9b9('0x22')]({'where':{'id':_0x5a0ad3['params']['id']}})[_0x2ce9b9('0x20')](handleEntityNotFound(_0x1fa9d9,null))[_0x2ce9b9('0x20')](removeEntity(_0x1fa9d9,null))[_0x2ce9b9('0x26')](handleError(_0x1fa9d9,null));},exports[_0x55f16c('0x1b')]=function(_0x7be4b7,_0x4a941a){const _0x52011a=_0x55f16c;return db[_0x52011a('0x32')][_0x52011a('0x1b')]()[_0x52011a('0x20')](respondWithResult(_0x4a941a,null))['catch'](handleError(_0x4a941a,null));}; \ No newline at end of file +const a448_0x1213=['../../components/parsers/qs','Content-Range','model','lodash','update','MemberReport','keys','describe','set','json','sort','then','end','show','limit','attributes','options','where','length','../../config/logger','rows','filter','params','filters','findOne','fieldName','like','error','status','name','rawAttributes','sequelize','intersection','map','catch','send','../../mysqldb','type','stack','fields','include','key','offset','api','count','body','query','order','merge','create'];(function(_0x300bda,_0x1213c3){const _0x2383e2=function(_0x411a06){while(--_0x411a06){_0x300bda['push'](_0x300bda['shift']());}};_0x2383e2(++_0x1213c3);}(a448_0x1213,0x163));const a448_0x2383=function(_0x300bda,_0x1213c3){_0x300bda=_0x300bda-0x0;let _0x2383e2=a448_0x1213[_0x300bda];return _0x2383e2;};const _0xce2b52=a448_0x2383;'use strict';const _=require(_0xce2b52('0x30')),qs=require(_0xce2b52('0x2d')),logger=require(_0xce2b52('0xe'))(_0xce2b52('0x26')),db=require(_0xce2b52('0x1f'))['db'],{Op}=require(_0xce2b52('0x1a'));function respondWithResult(_0x411a06,_0x90e904){return _0x90e904=_0x90e904||0xc8,function(_0x26f9e0){const _0x5df40b=a448_0x2383;if(_0x26f9e0)return _0x411a06[_0x5df40b('0x17')](_0x90e904)[_0x5df40b('0x4')](_0x26f9e0);};}function respondWithFilteredResult(_0x2c0c39,_0x951e4b){return function(_0x2f8673){const _0x4f2d63=a448_0x2383;if(_0x2f8673){const _0x362c27=_0x2f8673[_0x4f2d63('0x27')],_0x1993a0=_0x951e4b[_0x4f2d63('0x25')];let _0x2a7f51=_0x951e4b[_0x4f2d63('0x25')]+_0x951e4b[_0x4f2d63('0x9')],_0x486835;return _0x2a7f51>=_0x362c27?(_0x2a7f51=_0x362c27,_0x486835=0xc8):_0x486835=0xce,_0x2c0c39[_0x4f2d63('0x17')](_0x486835),_0x2c0c39[_0x4f2d63('0x3')](_0x4f2d63('0x2e'),_0x1993a0+'-'+_0x2a7f51+'/'+_0x362c27)[_0x4f2d63('0x4')](_0x2f8673);}return null;};}function saveUpdates(_0x5951b5){return function(_0xbadb0){const _0xd7cb8a=a448_0x2383;if(_0xbadb0)return _0xbadb0[_0xd7cb8a('0x31')](_0x5951b5)[_0xd7cb8a('0x6')](function(_0x2755f6){return _0x2755f6;});return null;};}function removeEntity(_0x425443){return function(_0x3cfd0d){const _0xedf05d=a448_0x2383;if(_0x3cfd0d)return _0x3cfd0d['destroy']()[_0xedf05d('0x6')](function(){const _0x30d70a=_0xedf05d;_0x425443['status'](0xcc)[_0x30d70a('0x7')]();});};}function handleEntityNotFound(_0x12527d){return function(_0x14da7f){return!_0x14da7f&&_0x12527d['sendStatus'](0x194),_0x14da7f;};}function handleError(_0x316839,_0x1b9c61){return _0x1b9c61=_0x1b9c61||0x1f4,function(_0x5f2a14){const _0x3c58e8=a448_0x2383;logger[_0x3c58e8('0x16')](_0x5f2a14[_0x3c58e8('0x21')]),_0x5f2a14['name']&&delete _0x5f2a14[_0x3c58e8('0x18')],_0x316839[_0x3c58e8('0x17')](_0x1b9c61)[_0x3c58e8('0x1e')](_0x5f2a14);};}exports['index']=function(_0x1141e3,_0x35f788){const _0x1fa698=_0xce2b52;let _0x2a7af0={};const _0x3e4d53={},_0x5e6c9c={'count':0x0,'rows':[]},_0x40b2a1=_[_0x1fa698('0x1c')](db[_0x1fa698('0x0')][_0x1fa698('0x19')],function(_0x2cdde1){const _0x346c9c=_0x1fa698;return{'name':_0x2cdde1[_0x346c9c('0x14')],'type':_0x2cdde1['type'][_0x346c9c('0x24')]};});_0x3e4d53[_0x1fa698('0x2f')]=_[_0x1fa698('0x1c')](_0x40b2a1,_0x1fa698('0x18')),_0x3e4d53[_0x1fa698('0x29')]=_[_0x1fa698('0x1')](_0x1141e3[_0x1fa698('0x29')]),_0x3e4d53[_0x1fa698('0x12')]=_[_0x1fa698('0x1b')](_0x3e4d53['model'],_0x3e4d53[_0x1fa698('0x29')]),_0x2a7af0['attributes']=_[_0x1fa698('0x1b')](_0x3e4d53[_0x1fa698('0x2f')],qs['fields'](_0x1141e3[_0x1fa698('0x29')][_0x1fa698('0x22')])),_0x2a7af0[_0x1fa698('0xa')]=_0x2a7af0['attributes'][_0x1fa698('0xd')]?_0x2a7af0[_0x1fa698('0xa')]:_0x3e4d53[_0x1fa698('0x2f')];typeof _0x1141e3[_0x1fa698('0x29')]['nolimit']==='undefined'&&(_0x2a7af0[_0x1fa698('0x9')]=qs['limit'](_0x1141e3[_0x1fa698('0x29')][_0x1fa698('0x9')]),_0x2a7af0[_0x1fa698('0x25')]=qs[_0x1fa698('0x25')](_0x1141e3[_0x1fa698('0x29')]['offset']));_0x2a7af0[_0x1fa698('0x2a')]=qs[_0x1fa698('0x5')](_0x1141e3[_0x1fa698('0x29')][_0x1fa698('0x5')]),_0x2a7af0[_0x1fa698('0xc')]=qs[_0x1fa698('0x12')](_['pick'](_0x1141e3[_0x1fa698('0x29')],_0x3e4d53[_0x1fa698('0x12')]),_0x40b2a1);_0x1141e3[_0x1fa698('0x29')][_0x1fa698('0x10')]&&(_0x2a7af0[_0x1fa698('0xc')]=_['merge'](_0x2a7af0[_0x1fa698('0xc')],{[Op['or']]:_[_0x1fa698('0x1c')](_0x40b2a1,function(_0x5a7984){const _0x5f1d80=_0x1fa698;if(_0x5a7984[_0x5f1d80('0x20')]!=='VIRTUAL'){const _0x1c9b42={};return _0x1c9b42[_0x5a7984['name']]={[Op[_0x5f1d80('0x15')]]:'%'+_0x1141e3[_0x5f1d80('0x29')]['filter']+'%'},_0x1c9b42;}})}));_0x2a7af0=_[_0x1fa698('0x2b')]({},_0x2a7af0,_0x1141e3['options']);const _0x42021e={'where':_0x2a7af0[_0x1fa698('0xc')]};return db[_0x1fa698('0x0')][_0x1fa698('0x27')](_0x42021e)[_0x1fa698('0x6')](function(_0x5dfb79){const _0x6ba8a=_0x1fa698;return _0x5e6c9c['count']=_0x5dfb79,_0x1141e3[_0x6ba8a('0x29')]['includeAll']&&(_0x2a7af0[_0x6ba8a('0x23')]=[{'all':!![]}]),db[_0x6ba8a('0x0')]['findAll'](_0x2a7af0);})[_0x1fa698('0x6')](function(_0x257966){const _0x3d704e=_0x1fa698;return _0x5e6c9c[_0x3d704e('0xf')]=_0x257966,_0x5e6c9c;})[_0x1fa698('0x6')](respondWithFilteredResult(_0x35f788,_0x2a7af0))['catch'](handleError(_0x35f788,null));},exports[_0xce2b52('0x8')]=function(_0x357b83,_0x1d30cf){const _0x49320b=_0xce2b52;let _0x1c3d46={'raw':!![],'where':{'id':_0x357b83[_0x49320b('0x11')]['id']}};const _0x33054b={};return _0x33054b[_0x49320b('0x2f')]=_[_0x49320b('0x1')](db[_0x49320b('0x0')][_0x49320b('0x19')]),_0x33054b[_0x49320b('0x29')]=_[_0x49320b('0x1')](_0x357b83[_0x49320b('0x29')]),_0x33054b[_0x49320b('0x12')]=_['intersection'](_0x33054b[_0x49320b('0x2f')],_0x33054b[_0x49320b('0x29')]),_0x1c3d46['attributes']=_['intersection'](_0x33054b[_0x49320b('0x2f')],qs[_0x49320b('0x22')](_0x357b83['query'][_0x49320b('0x22')])),_0x1c3d46[_0x49320b('0xa')]=_0x1c3d46['attributes'][_0x49320b('0xd')]?_0x1c3d46[_0x49320b('0xa')]:_0x33054b[_0x49320b('0x2f')],_0x357b83[_0x49320b('0x29')]['includeAll']&&(_0x1c3d46[_0x49320b('0x23')]=[{'all':!![]}]),_0x1c3d46=_[_0x49320b('0x2b')]({},_0x1c3d46,_0x357b83[_0x49320b('0xb')]),db[_0x49320b('0x0')][_0x49320b('0x13')](_0x1c3d46)['then'](handleEntityNotFound(_0x1d30cf,null))[_0x49320b('0x6')](respondWithResult(_0x1d30cf,null))['catch'](handleError(_0x1d30cf,null));},exports[_0xce2b52('0x2c')]=function(_0x47b641,_0x346b38){const _0x3f07e6=_0xce2b52;return db[_0x3f07e6('0x0')][_0x3f07e6('0x2c')](_0x47b641[_0x3f07e6('0x28')],{})[_0x3f07e6('0x6')](respondWithResult(_0x346b38,0xc9))[_0x3f07e6('0x1d')](handleError(_0x346b38,null));},exports['update']=function(_0x89f5ad,_0x23d2a2){const _0x5cadd8=_0xce2b52;return _0x89f5ad[_0x5cadd8('0x28')]['id']&&delete _0x89f5ad['body']['id'],db[_0x5cadd8('0x0')][_0x5cadd8('0x13')]({'where':{'id':_0x89f5ad[_0x5cadd8('0x11')]['id']}})[_0x5cadd8('0x6')](handleEntityNotFound(_0x23d2a2,null))['then'](saveUpdates(_0x89f5ad['body'],null))['then'](respondWithResult(_0x23d2a2,null))[_0x5cadd8('0x1d')](handleError(_0x23d2a2,null));},exports['destroy']=function(_0x25c395,_0x1677d2){const _0xf1eb30=_0xce2b52;return db[_0xf1eb30('0x0')][_0xf1eb30('0x13')]({'where':{'id':_0x25c395[_0xf1eb30('0x11')]['id']}})[_0xf1eb30('0x6')](handleEntityNotFound(_0x1677d2,null))[_0xf1eb30('0x6')](removeEntity(_0x1677d2,null))[_0xf1eb30('0x1d')](handleError(_0x1677d2,null));},exports[_0xce2b52('0x2')]=function(_0x31e67c,_0x302436){const _0x2f9ffa=_0xce2b52;return db[_0x2f9ffa('0x0')]['describe']()[_0x2f9ffa('0x6')](respondWithResult(_0x302436,null))[_0x2f9ffa('0x1d')](handleError(_0x302436,null));}; \ No newline at end of file diff --git a/server/api/memberReport/memberReport.model.js b/server/api/memberReport/memberReport.model.js index f870a44..0fc704b 100644 --- a/server/api/memberReport/memberReport.model.js +++ b/server/api/memberReport/memberReport.model.js @@ -1 +1 @@ -const a449_0x424c=['interface','exports','MemberReport','report_member','membername_interface','define','./memberReport.attributes'];(function(_0x57a4f6,_0x424c19){const _0x247021=function(_0x55d5f8){while(--_0x55d5f8){_0x57a4f6['push'](_0x57a4f6['shift']());}};_0x247021(++_0x424c19);}(a449_0x424c,0xec));const a449_0x2470=function(_0x57a4f6,_0x424c19){_0x57a4f6=_0x57a4f6-0x0;let _0x247021=a449_0x424c[_0x57a4f6];return _0x247021;};const _0x2f84a3=a449_0x2470;'use strict';const attributes=require(_0x2f84a3('0x1'));module[_0x2f84a3('0x3')]=function(_0x55d5f8){const _0x336e41=_0x2f84a3,_0x198ede=_0x55d5f8[_0x336e41('0x0')](_0x336e41('0x4'),attributes,{'tableName':_0x336e41('0x5'),'paranoid':![],'indexes':[{'name':_0x336e41('0x6'),'fields':['membername',_0x336e41('0x2')]}],'timestamps':!![]});return _0x198ede;}; \ No newline at end of file +const a449_0x1761=['report_member','MemberReport','interface','membername_interface','exports','membername','./memberReport.attributes','define'];(function(_0x2b541a,_0x1761f5){const _0x553b0e=function(_0x2cc7b0){while(--_0x2cc7b0){_0x2b541a['push'](_0x2b541a['shift']());}};_0x553b0e(++_0x1761f5);}(a449_0x1761,0xdb));const a449_0x553b=function(_0x2b541a,_0x1761f5){_0x2b541a=_0x2b541a-0x0;let _0x553b0e=a449_0x1761[_0x2b541a];return _0x553b0e;};const _0x5cf958=a449_0x553b;'use strict';const attributes=require(_0x5cf958('0x3'));module[_0x5cf958('0x1')]=function(_0x2cc7b0){const _0x506c64=_0x5cf958,_0x3bbf89=_0x2cc7b0[_0x506c64('0x4')](_0x506c64('0x6'),attributes,{'tableName':_0x506c64('0x5'),'paranoid':![],'indexes':[{'name':_0x506c64('0x0'),'fields':[_0x506c64('0x2'),_0x506c64('0x7')]}],'timestamps':!![]});return _0x3bbf89;}; \ No newline at end of file diff --git a/server/api/memberReport/memberReport.rpc.js b/server/api/memberReport/memberReport.rpc.js index 319e387..cfc38db 100644 --- a/server/api/memberReport/memberReport.rpc.js +++ b/server/api/memberReport/memberReport.rpc.js @@ -1 +1 @@ -const a450_0x1479=['findAll','debug','options','create','MemberReport','../../config/logger','then','stringify','lodash','include','model','CreateMemberReport','info','../../mysqldb','error','catch','body','limit','GetMemberReport','where','map','attributes','message','raw','UpdateMemberReport','update'];(function(_0x2ab463,_0x14792e){const _0xaf37cf=function(_0x383d98){while(--_0x383d98){_0x2ab463['push'](_0x2ab463['shift']());}};_0xaf37cf(++_0x14792e);}(a450_0x1479,0x78));const a450_0xaf37=function(_0x2ab463,_0x14792e){_0x2ab463=_0x2ab463-0x0;let _0xaf37cf=a450_0x1479[_0x2ab463];return _0xaf37cf;};const _0x4957ac=a450_0xaf37;'use strict';const _=require(_0x4957ac('0x12')),db=require(_0x4957ac('0x17'))['db'],logger=require(_0x4957ac('0xf'))('rpc');exports[_0x4957ac('0x2')]=function(_0x383d98){const _0x3b5a26=this;return new Promise(function(_0x5a1f0e,_0x3435b0){const _0x586445=a450_0xaf37;return db[_0x586445('0xe')][_0x586445('0xa')]({'raw':_0x383d98[_0x586445('0xc')]?_0x383d98['options'][_0x586445('0x7')]===undefined?!![]:![]:!![],'where':_0x383d98['options']?_0x383d98[_0x586445('0xc')][_0x586445('0x3')]||null:null,'attributes':_0x383d98['options']?_0x383d98[_0x586445('0xc')][_0x586445('0x5')]||null:null,'limit':_0x383d98['options']?_0x383d98[_0x586445('0xc')][_0x586445('0x1')]||null:null,'include':_0x383d98[_0x586445('0xc')]?_0x383d98[_0x586445('0xc')]['include']?_[_0x586445('0x4')](_0x383d98[_0x586445('0xc')][_0x586445('0x13')],function(_0x3535fd){const _0x2d0278=_0x586445;return{'model':db[_0x3535fd[_0x2d0278('0x14')]],'as':_0x3535fd['as'],'attributes':_0x3535fd[_0x2d0278('0x5')],'include':_0x3535fd[_0x2d0278('0x13')]?_[_0x2d0278('0x4')](_0x3535fd[_0x2d0278('0x13')],function(_0x7d82da){const _0x8a44e5=_0x2d0278;return{'model':db[_0x7d82da[_0x8a44e5('0x14')]],'as':_0x7d82da['as'],'attributes':_0x7d82da[_0x8a44e5('0x5')],'include':_0x7d82da[_0x8a44e5('0x13')]?_[_0x8a44e5('0x4')](_0x7d82da['include'],function(_0x5e7c76){const _0x3ad98f=_0x8a44e5;return{'model':db[_0x5e7c76[_0x3ad98f('0x14')]],'as':_0x5e7c76['as'],'attributes':_0x5e7c76[_0x3ad98f('0x5')]};}):[]};}):[]};}):[]:[]})[_0x586445('0x10')](function(_0x6c152b){const _0x4fc2dc=_0x586445;logger[_0x4fc2dc('0x16')](_0x4fc2dc('0x2'),_0x383d98),logger[_0x4fc2dc('0xb')](_0x4fc2dc('0x2'),_0x383d98,JSON[_0x4fc2dc('0x11')](_0x6c152b)),_0x5a1f0e(_0x6c152b);})[_0x586445('0x19')](function(_0x213f6d){const _0x4d219e=_0x586445;logger[_0x4d219e('0x18')](_0x4d219e('0x2'),_0x213f6d[_0x4d219e('0x6')],_0x383d98),_0x3435b0(_0x3b5a26['error'](0x1f4,_0x213f6d['message']));});});},exports[_0x4957ac('0x15')]=function(_0x1fa648){const _0xdc6470=this;return new Promise(function(_0xc337b6,_0x2f084b){const _0x449fed=a450_0xaf37;return db[_0x449fed('0xe')][_0x449fed('0xd')](_0x1fa648[_0x449fed('0x0')],{'raw':_0x1fa648[_0x449fed('0xc')]?_0x1fa648[_0x449fed('0xc')]['raw']===undefined?!![]:![]:!![]})[_0x449fed('0x10')](function(_0x17ba12){const _0x2d2a55=_0x449fed;logger['info'](_0x2d2a55('0x15'),_0x1fa648),logger['debug'](_0x2d2a55('0x15'),_0x1fa648,JSON[_0x2d2a55('0x11')](_0x17ba12)),_0xc337b6(_0x17ba12);})[_0x449fed('0x19')](function(_0xa743ec){const _0x56352c=_0x449fed;logger[_0x56352c('0x18')](_0x56352c('0x15'),_0xa743ec[_0x56352c('0x6')],_0x1fa648),_0x2f084b(_0xdc6470[_0x56352c('0x18')](0x1f4,_0xa743ec[_0x56352c('0x6')]));});});},exports[_0x4957ac('0x8')]=function(_0x20e715){const _0x45e3b2=this;return new Promise(function(_0x3769cf,_0x49ebbd){const _0x4a9624=a450_0xaf37;return db[_0x4a9624('0xe')][_0x4a9624('0x9')](_0x20e715[_0x4a9624('0x0')],{'raw':_0x20e715['options']?_0x20e715[_0x4a9624('0xc')][_0x4a9624('0x7')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x20e715[_0x4a9624('0xc')]?_0x20e715[_0x4a9624('0xc')][_0x4a9624('0x3')]||null:null,'attributes':_0x20e715[_0x4a9624('0xc')]?_0x20e715[_0x4a9624('0xc')]['attributes']||null:null,'limit':_0x20e715[_0x4a9624('0xc')]?_0x20e715[_0x4a9624('0xc')][_0x4a9624('0x1')]||null:null})[_0x4a9624('0x10')](function(_0x55eb7f){const _0x57219b=_0x4a9624;logger[_0x57219b('0x16')](_0x57219b('0x8'),_0x20e715),logger[_0x57219b('0xb')](_0x57219b('0x8'),_0x20e715,JSON[_0x57219b('0x11')](_0x55eb7f)),_0x3769cf(_0x55eb7f);})['catch'](function(_0x4aec8f){const _0x1b8c65=_0x4a9624;logger[_0x1b8c65('0x18')](_0x1b8c65('0x8'),_0x4aec8f['message'],_0x20e715),_0x49ebbd(_0x45e3b2[_0x1b8c65('0x18')](0x1f4,_0x4aec8f['message']));});});}; \ No newline at end of file +const a450_0x1c9b=['raw','CreateMemberReport','error','map','then','attributes','limit','create','where','update','../../mysqldb','lodash','UpdateMemberReport','options','../../config/logger','debug','rpc','MemberReport','findAll','message','stringify','GetMemberReport','info','include','catch','body'];(function(_0xb185c5,_0x1c9b2d){const _0x5852a6=function(_0x4b7d05){while(--_0x4b7d05){_0xb185c5['push'](_0xb185c5['shift']());}};_0x5852a6(++_0x1c9b2d);}(a450_0x1c9b,0x1a7));const a450_0x5852=function(_0xb185c5,_0x1c9b2d){_0xb185c5=_0xb185c5-0x0;let _0x5852a6=a450_0x1c9b[_0xb185c5];return _0x5852a6;};const _0x25a332=a450_0x5852;'use strict';const _=require(_0x25a332('0x4')),db=require(_0x25a332('0x3'))['db'],logger=require(_0x25a332('0x7'))(_0x25a332('0x9'));exports[_0x25a332('0xe')]=function(_0x4b7d05){const _0x39da73=this;return new Promise(function(_0x4ead3b,_0x3343b3){const _0x1befd5=a450_0x5852;return db[_0x1befd5('0xa')][_0x1befd5('0xb')]({'raw':_0x4b7d05['options']?_0x4b7d05[_0x1befd5('0x6')][_0x1befd5('0x13')]===undefined?!![]:![]:!![],'where':_0x4b7d05[_0x1befd5('0x6')]?_0x4b7d05['options'][_0x1befd5('0x1')]||null:null,'attributes':_0x4b7d05[_0x1befd5('0x6')]?_0x4b7d05[_0x1befd5('0x6')][_0x1befd5('0x18')]||null:null,'limit':_0x4b7d05['options']?_0x4b7d05[_0x1befd5('0x6')]['limit']||null:null,'include':_0x4b7d05[_0x1befd5('0x6')]?_0x4b7d05[_0x1befd5('0x6')][_0x1befd5('0x10')]?_[_0x1befd5('0x16')](_0x4b7d05['options'][_0x1befd5('0x10')],function(_0x8a4d62){const _0x34f1d1=_0x1befd5;return{'model':db[_0x8a4d62['model']],'as':_0x8a4d62['as'],'attributes':_0x8a4d62[_0x34f1d1('0x18')],'include':_0x8a4d62['include']?_[_0x34f1d1('0x16')](_0x8a4d62[_0x34f1d1('0x10')],function(_0x140571){const _0x3d208d=_0x34f1d1;return{'model':db[_0x140571['model']],'as':_0x140571['as'],'attributes':_0x140571[_0x3d208d('0x18')],'include':_0x140571['include']?_[_0x3d208d('0x16')](_0x140571[_0x3d208d('0x10')],function(_0x2ea5c3){const _0x4ed236=_0x3d208d;return{'model':db[_0x2ea5c3['model']],'as':_0x2ea5c3['as'],'attributes':_0x2ea5c3[_0x4ed236('0x18')]};}):[]};}):[]};}):[]:[]})[_0x1befd5('0x17')](function(_0x340461){const _0x4870f5=_0x1befd5;logger[_0x4870f5('0xf')](_0x4870f5('0xe'),_0x4b7d05),logger[_0x4870f5('0x8')](_0x4870f5('0xe'),_0x4b7d05,JSON['stringify'](_0x340461)),_0x4ead3b(_0x340461);})[_0x1befd5('0x11')](function(_0x84ae12){const _0x2b9a08=_0x1befd5;logger['error'](_0x2b9a08('0xe'),_0x84ae12[_0x2b9a08('0xc')],_0x4b7d05),_0x3343b3(_0x39da73['error'](0x1f4,_0x84ae12[_0x2b9a08('0xc')]));});});},exports[_0x25a332('0x14')]=function(_0x1249c5){const _0x21a6c6=this;return new Promise(function(_0x44020e,_0x384dc5){const _0x351278=a450_0x5852;return db[_0x351278('0xa')][_0x351278('0x0')](_0x1249c5[_0x351278('0x12')],{'raw':_0x1249c5['options']?_0x1249c5[_0x351278('0x6')]['raw']===undefined?!![]:![]:!![]})[_0x351278('0x17')](function(_0x52e26c){const _0x4879ff=_0x351278;logger[_0x4879ff('0xf')]('CreateMemberReport',_0x1249c5),logger[_0x4879ff('0x8')](_0x4879ff('0x14'),_0x1249c5,JSON['stringify'](_0x52e26c)),_0x44020e(_0x52e26c);})[_0x351278('0x11')](function(_0x143c70){const _0x595c54=_0x351278;logger[_0x595c54('0x15')](_0x595c54('0x14'),_0x143c70[_0x595c54('0xc')],_0x1249c5),_0x384dc5(_0x21a6c6[_0x595c54('0x15')](0x1f4,_0x143c70[_0x595c54('0xc')]));});});},exports[_0x25a332('0x5')]=function(_0x110352){const _0x47b8ab=this;return new Promise(function(_0x103d5b,_0x51d8d8){const _0xc5fb1a=a450_0x5852;return db[_0xc5fb1a('0xa')][_0xc5fb1a('0x2')](_0x110352[_0xc5fb1a('0x12')],{'raw':_0x110352[_0xc5fb1a('0x6')]?_0x110352[_0xc5fb1a('0x6')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x110352[_0xc5fb1a('0x6')]?_0x110352['options'][_0xc5fb1a('0x1')]||null:null,'attributes':_0x110352[_0xc5fb1a('0x6')]?_0x110352[_0xc5fb1a('0x6')]['attributes']||null:null,'limit':_0x110352[_0xc5fb1a('0x6')]?_0x110352[_0xc5fb1a('0x6')][_0xc5fb1a('0x19')]||null:null})[_0xc5fb1a('0x17')](function(_0x2d7980){const _0x52c3e9=_0xc5fb1a;logger[_0x52c3e9('0xf')]('UpdateMemberReport',_0x110352),logger[_0x52c3e9('0x8')](_0x52c3e9('0x5'),_0x110352,JSON[_0x52c3e9('0xd')](_0x2d7980)),_0x103d5b(_0x2d7980);})['catch'](function(_0x5889f9){const _0x2e4ac9=_0xc5fb1a;logger[_0x2e4ac9('0x15')](_0x2e4ac9('0x5'),_0x5889f9[_0x2e4ac9('0xc')],_0x110352),_0x51d8d8(_0x47b8ab[_0x2e4ac9('0x15')](0x1f4,_0x5889f9[_0x2e4ac9('0xc')]));});});}; \ No newline at end of file diff --git a/server/api/migration/index.js b/server/api/migration/index.js index 58432e4..300a202 100644 --- a/server/api/migration/index.js +++ b/server/api/migration/index.js @@ -1 +1 @@ -const a451_0x409b=['Router','express','get','exports','./migration.controller'];(function(_0x28b1db,_0x409bd1){const _0x5a2fe9=function(_0x407578){while(--_0x407578){_0x28b1db['push'](_0x28b1db['shift']());}};_0x5a2fe9(++_0x409bd1);}(a451_0x409b,0x115));const a451_0x5a2f=function(_0x28b1db,_0x409bd1){_0x28b1db=_0x28b1db-0x0;let _0x5a2fe9=a451_0x409b[_0x28b1db];return _0x5a2fe9;};const _0x4c927a=a451_0x5a2f;'use strict';const express=require(_0x4c927a('0x4')),router=express[_0x4c927a('0x3')](),controller=require(_0x4c927a('0x2'));router[_0x4c927a('0x0')]('/',controller['index']),module[_0x4c927a('0x1')]=router; \ No newline at end of file +const a451_0x330f=['index','get','./migration.controller','exports','Router','express'];(function(_0x3a83c1,_0x330ff1){const _0x2dd5ca=function(_0x39cba7){while(--_0x39cba7){_0x3a83c1['push'](_0x3a83c1['shift']());}};_0x2dd5ca(++_0x330ff1);}(a451_0x330f,0x1b4));const a451_0x2dd5=function(_0x3a83c1,_0x330ff1){_0x3a83c1=_0x3a83c1-0x0;let _0x2dd5ca=a451_0x330f[_0x3a83c1];return _0x2dd5ca;};const _0x49888d=a451_0x2dd5;'use strict';const express=require(_0x49888d('0x1')),router=express[_0x49888d('0x0')](),controller=require(_0x49888d('0x4'));router[_0x49888d('0x3')]('/',controller[_0x49888d('0x2')]),module[_0x49888d('0x5')]=router; \ No newline at end of file diff --git a/server/api/migration/migration.attributes.js b/server/api/migration/migration.attributes.js index 3f13ea2..f926de4 100644 --- a/server/api/migration/migration.attributes.js +++ b/server/api/migration/migration.attributes.js @@ -1 +1 @@ -const a452_0xd977=['sequelize','exports','version'];(function(_0x3ce377,_0xd977c9){const _0x333b49=function(_0x2a083b){while(--_0x2a083b){_0x3ce377['push'](_0x3ce377['shift']());}};_0x333b49(++_0xd977c9);}(a452_0xd977,0xd2));const a452_0x333b=function(_0x3ce377,_0xd977c9){_0x3ce377=_0x3ce377-0x0;let _0x333b49=a452_0xd977[_0x3ce377];return _0x333b49;};const _0x2ff24f=a452_0x333b;'use strict';const Sequelize=require(_0x2ff24f('0x0'));module[_0x2ff24f('0x1')]={'version':{'type':Sequelize['STRING'],'unique':_0x2ff24f('0x2')}}; \ No newline at end of file +const a452_0x25b3=['version','exports','STRING'];(function(_0x31e830,_0x25b3f7){const _0xf0dee5=function(_0x4bf7a6){while(--_0x4bf7a6){_0x31e830['push'](_0x31e830['shift']());}};_0xf0dee5(++_0x25b3f7);}(a452_0x25b3,0x1db));const a452_0xf0de=function(_0x31e830,_0x25b3f7){_0x31e830=_0x31e830-0x0;let _0xf0dee5=a452_0x25b3[_0x31e830];return _0xf0dee5;};const _0x540415=a452_0xf0de;'use strict';const Sequelize=require('sequelize');module[_0x540415('0x0')]={'version':{'type':Sequelize[_0x540415('0x1')],'unique':_0x540415('0x2')}}; \ No newline at end of file diff --git a/server/api/migration/migration.controller.js b/server/api/migration/migration.controller.js index d0a1f72..16f0daa 100644 --- a/server/api/migration/migration.controller.js +++ b/server/api/migration/migration.controller.js @@ -1 +1 @@ -const a453_0x248e=['fields','order','status','Migration','include','sort','VIRTUAL','options','error','model','send','catch','then','limit','../../config/logger','rawAttributes','filter','api','set','undefined','length','intersection','pick','key','../../mysqldb','attributes','query','map','name','lodash','Content-Range','index','filters','stack','offset','like','count','json','merge','includeAll','rows','type','where'];(function(_0x2d09af,_0x248e02){const _0x69f0a8=function(_0x971f41){while(--_0x971f41){_0x2d09af['push'](_0x2d09af['shift']());}};_0x69f0a8(++_0x248e02);}(a453_0x248e,0x1e9));const a453_0x69f0=function(_0x2d09af,_0x248e02){_0x2d09af=_0x2d09af-0x0;let _0x69f0a8=a453_0x248e[_0x2d09af];return _0x69f0a8;};const _0x6ac1f1=a453_0x69f0;'use strict';const _=require(_0x6ac1f1('0xd')),qs=require('../../components/parsers/qs'),logger=require(_0x6ac1f1('0x29'))(_0x6ac1f1('0x1')),db=require(_0x6ac1f1('0x8'))['db'],{Op}=require('sequelize');function respondWithFilteredResult(_0x971f41,_0x48a357){return function(_0x2e5ae4){const _0x2e1d0d=a453_0x69f0;if(_0x2e5ae4){const _0x5c1970=_0x2e5ae4[_0x2e1d0d('0x14')],_0x1aa995=_0x48a357[_0x2e1d0d('0x12')];let _0x4c4980=_0x48a357[_0x2e1d0d('0x12')]+_0x48a357[_0x2e1d0d('0x28')],_0x5a65d9;return _0x4c4980>=_0x5c1970?(_0x4c4980=_0x5c1970,_0x5a65d9=0xc8):_0x5a65d9=0xce,_0x971f41[_0x2e1d0d('0x1d')](_0x5a65d9),_0x971f41[_0x2e1d0d('0x2')](_0x2e1d0d('0xe'),_0x1aa995+'-'+_0x4c4980+'/'+_0x5c1970)[_0x2e1d0d('0x15')](_0x2e5ae4);}return null;};}function handleError(_0x4dc585,_0xd9e542){return _0xd9e542=_0xd9e542||0x1f4,function(_0x41451f){const _0x313ea0=a453_0x69f0;logger[_0x313ea0('0x23')](_0x41451f[_0x313ea0('0x11')]),_0x41451f[_0x313ea0('0xc')]&&delete _0x41451f[_0x313ea0('0xc')],_0x4dc585[_0x313ea0('0x1d')](_0xd9e542)[_0x313ea0('0x25')](_0x41451f);};}exports[_0x6ac1f1('0xf')]=function(_0x3ddd5d,_0x5636c2){const _0x375202=_0x6ac1f1;let _0x2fb9a4={};const _0x5e3706={},_0x2abcb4={'count':0x0,'rows':[]},_0x294b7b=_[_0x375202('0xb')](db[_0x375202('0x1e')][_0x375202('0x2a')],function(_0x3f5217){const _0x2b60fe=_0x375202;return{'name':_0x3f5217['fieldName'],'type':_0x3f5217[_0x2b60fe('0x19')][_0x2b60fe('0x7')]};});_0x5e3706[_0x375202('0x24')]=_[_0x375202('0xb')](_0x294b7b,_0x375202('0xc')),_0x5e3706['query']=_['keys'](_0x3ddd5d[_0x375202('0xa')]),_0x5e3706['filters']=_[_0x375202('0x5')](_0x5e3706[_0x375202('0x24')],_0x5e3706[_0x375202('0xa')]),_0x2fb9a4[_0x375202('0x9')]=_['intersection'](_0x5e3706[_0x375202('0x24')],qs[_0x375202('0x1b')](_0x3ddd5d[_0x375202('0xa')][_0x375202('0x1b')])),_0x2fb9a4[_0x375202('0x9')]=_0x2fb9a4['attributes'][_0x375202('0x4')]?_0x2fb9a4['attributes']:_0x5e3706[_0x375202('0x24')];typeof _0x3ddd5d[_0x375202('0xa')]['nolimit']===_0x375202('0x3')&&(_0x2fb9a4[_0x375202('0x28')]=qs[_0x375202('0x28')](_0x3ddd5d[_0x375202('0xa')][_0x375202('0x28')]),_0x2fb9a4[_0x375202('0x12')]=qs[_0x375202('0x12')](_0x3ddd5d['query'][_0x375202('0x12')]));_0x2fb9a4[_0x375202('0x1c')]=qs['sort'](_0x3ddd5d[_0x375202('0xa')][_0x375202('0x20')]),_0x2fb9a4['where']=qs[_0x375202('0x10')](_[_0x375202('0x6')](_0x3ddd5d[_0x375202('0xa')],_0x5e3706[_0x375202('0x10')]),_0x294b7b);_0x3ddd5d[_0x375202('0xa')]['filter']&&(_0x2fb9a4[_0x375202('0x1a')]=_['merge'](_0x2fb9a4[_0x375202('0x1a')],{[Op['or']]:_['map'](_0x294b7b,function(_0x116e59){const _0x439bc6=_0x375202;if(_0x116e59[_0x439bc6('0x19')]!==_0x439bc6('0x21')){const _0x16a7b3={};return _0x16a7b3[_0x116e59['name']]={[Op[_0x439bc6('0x13')]]:'%'+_0x3ddd5d['query'][_0x439bc6('0x0')]+'%'},_0x16a7b3;}})}));_0x2fb9a4=_[_0x375202('0x16')]({},_0x2fb9a4,_0x3ddd5d[_0x375202('0x22')]);const _0x31af5b={'where':_0x2fb9a4[_0x375202('0x1a')]};return db[_0x375202('0x1e')][_0x375202('0x14')](_0x31af5b)[_0x375202('0x27')](function(_0x4b1f0e){const _0x430835=_0x375202;return _0x2abcb4['count']=_0x4b1f0e,_0x3ddd5d[_0x430835('0xa')][_0x430835('0x17')]&&(_0x2fb9a4[_0x430835('0x1f')]=[{'all':!![]}]),db[_0x430835('0x1e')]['findAll'](_0x2fb9a4);})[_0x375202('0x27')](function(_0x46469c){const _0xc833e2=_0x375202;return _0x2abcb4[_0xc833e2('0x18')]=_0x46469c,_0x2abcb4;})[_0x375202('0x27')](respondWithFilteredResult(_0x5636c2,_0x2fb9a4))[_0x375202('0x26')](handleError(_0x5636c2,null));}; \ No newline at end of file +const a453_0x3dea=['rows','filters','fields','status','merge','../../config/logger','name','sequelize','like','api','order','set','length','filter','index','intersection','type','findAll','attributes','count','where','fieldName','Migration','limit','pick','catch','undefined','key','includeAll','Content-Range','VIRTUAL','model','lodash','error','map','../../components/parsers/qs','offset','../../mysqldb','json','sort','rawAttributes','then','query'];(function(_0x3d6310,_0x3dea09){const _0x33e0a6=function(_0x115c90){while(--_0x115c90){_0x3d6310['push'](_0x3d6310['shift']());}};_0x33e0a6(++_0x3dea09);}(a453_0x3dea,0xeb));const a453_0x33e0=function(_0x3d6310,_0x3dea09){_0x3d6310=_0x3d6310-0x0;let _0x33e0a6=a453_0x3dea[_0x3d6310];return _0x33e0a6;};const _0x348ea4=a453_0x33e0;'use strict';const _=require(_0x348ea4('0xc')),qs=require(_0x348ea4('0xf')),logger=require(_0x348ea4('0x1c'))(_0x348ea4('0x20')),db=require(_0x348ea4('0x11'))['db'],{Op}=require(_0x348ea4('0x1e'));function respondWithFilteredResult(_0x115c90,_0x531592){return function(_0x223fb0){const _0x4422de=a453_0x33e0;if(_0x223fb0){const _0x260985=_0x223fb0['count'],_0x324618=_0x531592[_0x4422de('0x10')];let _0x4aea12=_0x531592['offset']+_0x531592['limit'],_0x5876e2;return _0x4aea12>=_0x260985?(_0x4aea12=_0x260985,_0x5876e2=0xc8):_0x5876e2=0xce,_0x115c90[_0x4422de('0x1a')](_0x5876e2),_0x115c90[_0x4422de('0x22')](_0x4422de('0x9'),_0x324618+'-'+_0x4aea12+'/'+_0x260985)[_0x4422de('0x12')](_0x223fb0);}return null;};}function handleError(_0x34c039,_0x598bb2){return _0x598bb2=_0x598bb2||0x1f4,function(_0x1e3337){const _0x36490d=a453_0x33e0;logger[_0x36490d('0xd')](_0x1e3337['stack']),_0x1e3337[_0x36490d('0x1d')]&&delete _0x1e3337['name'],_0x34c039[_0x36490d('0x1a')](_0x598bb2)['send'](_0x1e3337);};}exports[_0x348ea4('0x25')]=function(_0xd80666,_0x1f2246){const _0x98a63b=_0x348ea4;let _0x242b70={};const _0x169b26={},_0x4256b5={'count':0x0,'rows':[]},_0x50171c=_['map'](db[_0x98a63b('0x2')][_0x98a63b('0x14')],function(_0x2647c8){const _0x49925d=_0x98a63b;return{'name':_0x2647c8[_0x49925d('0x1')],'type':_0x2647c8[_0x49925d('0x27')][_0x49925d('0x7')]};});_0x169b26[_0x98a63b('0xb')]=_[_0x98a63b('0xe')](_0x50171c,'name'),_0x169b26['query']=_['keys'](_0xd80666['query']),_0x169b26[_0x98a63b('0x18')]=_[_0x98a63b('0x26')](_0x169b26['model'],_0x169b26[_0x98a63b('0x16')]),_0x242b70[_0x98a63b('0x29')]=_[_0x98a63b('0x26')](_0x169b26[_0x98a63b('0xb')],qs[_0x98a63b('0x19')](_0xd80666[_0x98a63b('0x16')][_0x98a63b('0x19')])),_0x242b70[_0x98a63b('0x29')]=_0x242b70['attributes'][_0x98a63b('0x23')]?_0x242b70[_0x98a63b('0x29')]:_0x169b26[_0x98a63b('0xb')];typeof _0xd80666[_0x98a63b('0x16')]['nolimit']===_0x98a63b('0x6')&&(_0x242b70[_0x98a63b('0x3')]=qs[_0x98a63b('0x3')](_0xd80666[_0x98a63b('0x16')][_0x98a63b('0x3')]),_0x242b70['offset']=qs[_0x98a63b('0x10')](_0xd80666[_0x98a63b('0x16')][_0x98a63b('0x10')]));_0x242b70[_0x98a63b('0x21')]=qs['sort'](_0xd80666['query'][_0x98a63b('0x13')]),_0x242b70[_0x98a63b('0x0')]=qs[_0x98a63b('0x18')](_[_0x98a63b('0x4')](_0xd80666[_0x98a63b('0x16')],_0x169b26[_0x98a63b('0x18')]),_0x50171c);_0xd80666[_0x98a63b('0x16')][_0x98a63b('0x24')]&&(_0x242b70[_0x98a63b('0x0')]=_[_0x98a63b('0x1b')](_0x242b70[_0x98a63b('0x0')],{[Op['or']]:_[_0x98a63b('0xe')](_0x50171c,function(_0x27853f){const _0x18e16e=_0x98a63b;if(_0x27853f[_0x18e16e('0x27')]!==_0x18e16e('0xa')){const _0xd386f0={};return _0xd386f0[_0x27853f[_0x18e16e('0x1d')]]={[Op[_0x18e16e('0x1f')]]:'%'+_0xd80666[_0x18e16e('0x16')][_0x18e16e('0x24')]+'%'},_0xd386f0;}})}));_0x242b70=_[_0x98a63b('0x1b')]({},_0x242b70,_0xd80666['options']);const _0x407240={'where':_0x242b70[_0x98a63b('0x0')]};return db['Migration'][_0x98a63b('0x2a')](_0x407240)[_0x98a63b('0x15')](function(_0x2a470a){const _0x8f8c33=_0x98a63b;return _0x4256b5[_0x8f8c33('0x2a')]=_0x2a470a,_0xd80666['query'][_0x8f8c33('0x8')]&&(_0x242b70['include']=[{'all':!![]}]),db['Migration'][_0x8f8c33('0x28')](_0x242b70);})['then'](function(_0x3047fa){const _0x2ddd91=_0x98a63b;return _0x4256b5[_0x2ddd91('0x17')]=_0x3047fa,_0x4256b5;})[_0x98a63b('0x15')](respondWithFilteredResult(_0x1f2246,_0x242b70))[_0x98a63b('0x5')](handleError(_0x1f2246,null));}; \ No newline at end of file diff --git a/server/api/migration/migration.model.js b/server/api/migration/migration.model.js index 7c6a000..4b67b84 100644 --- a/server/api/migration/migration.model.js +++ b/server/api/migration/migration.model.js @@ -1 +1 @@ -const a454_0x3d2c=['Migration','migrations','./migration.attributes'];(function(_0x5aa5df,_0x3d2c52){const _0x434f6e=function(_0x380343){while(--_0x380343){_0x5aa5df['push'](_0x5aa5df['shift']());}};_0x434f6e(++_0x3d2c52);}(a454_0x3d2c,0xc9));const a454_0x434f=function(_0x5aa5df,_0x3d2c52){_0x5aa5df=_0x5aa5df-0x0;let _0x434f6e=a454_0x3d2c[_0x5aa5df];return _0x434f6e;};const _0x444bcc=a454_0x434f;'use strict';const attributes=require(_0x444bcc('0x2'));module['exports']=function(_0x380343){const _0x4b4a43=_0x444bcc,_0x523cde=_0x380343['define'](_0x4b4a43('0x0'),attributes,{'tableName':_0x4b4a43('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x523cde;}; \ No newline at end of file +const a454_0x1494=['migrations','exports','define','./migration.attributes','Migration'];(function(_0xefc669,_0x14945b){const _0xe13023=function(_0x2ca71a){while(--_0x2ca71a){_0xefc669['push'](_0xefc669['shift']());}};_0xe13023(++_0x14945b);}(a454_0x1494,0x9d));const a454_0xe130=function(_0xefc669,_0x14945b){_0xefc669=_0xefc669-0x0;let _0xe13023=a454_0x1494[_0xefc669];return _0xe13023;};const _0x5c9878=a454_0xe130;'use strict';const attributes=require(_0x5c9878('0x1'));module[_0x5c9878('0x4')]=function(_0x2ca71a){const _0x977a3d=_0x5c9878,_0x48dcf1=_0x2ca71a[_0x977a3d('0x0')](_0x977a3d('0x2'),attributes,{'tableName':_0x977a3d('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x48dcf1;}; \ No newline at end of file diff --git a/server/api/network/index.js b/server/api/network/index.js index 8b943ff..5df2d4c 100644 --- a/server/api/network/index.js +++ b/server/api/network/index.js @@ -1 +1 @@ -const a455_0x97c4=['update','Router','show','isAuthenticated','create','exports','put','express','destroy','index','./network.controller','get','delete','post','/:id'];(function(_0x1beeb6,_0x97c4d4){const _0x182015=function(_0x36ecd2){while(--_0x36ecd2){_0x1beeb6['push'](_0x1beeb6['shift']());}};_0x182015(++_0x97c4d4);}(a455_0x97c4,0x1c9));const a455_0x1820=function(_0x1beeb6,_0x97c4d4){_0x1beeb6=_0x1beeb6-0x0;let _0x182015=a455_0x97c4[_0x1beeb6];return _0x182015;};const _0x15cb20=a455_0x1820;'use strict';const express=require(_0x15cb20('0x0')),router=express[_0x15cb20('0x9')](),auth=require('../../components/auth/service'),controller=require(_0x15cb20('0x3'));router['get']('/',auth[_0x15cb20('0xb')](),controller[_0x15cb20('0x2')]),router[_0x15cb20('0x4')](_0x15cb20('0x7'),auth[_0x15cb20('0xb')](),controller[_0x15cb20('0xa')]),router[_0x15cb20('0x6')]('/',auth[_0x15cb20('0xb')](),controller[_0x15cb20('0xc')]),router[_0x15cb20('0xe')](_0x15cb20('0x7'),auth[_0x15cb20('0xb')](),controller[_0x15cb20('0x8')]),router[_0x15cb20('0x5')](_0x15cb20('0x7'),auth['isAuthenticated'](),controller[_0x15cb20('0x1')]),module[_0x15cb20('0xd')]=router; \ No newline at end of file +const a455_0x4df2=['../../components/auth/service','get','destroy','express','put','create','delete','./network.controller','exports','/:id','update','isAuthenticated','index'];(function(_0x440499,_0x4df2ad){const _0x890ab2=function(_0x2a1420){while(--_0x2a1420){_0x440499['push'](_0x440499['shift']());}};_0x890ab2(++_0x4df2ad);}(a455_0x4df2,0x1d0));const a455_0x890a=function(_0x440499,_0x4df2ad){_0x440499=_0x440499-0x0;let _0x890ab2=a455_0x4df2[_0x440499];return _0x890ab2;};const _0x1ab08a=a455_0x890a;'use strict';const express=require(_0x1ab08a('0x7')),router=express['Router'](),auth=require(_0x1ab08a('0x4')),controller=require(_0x1ab08a('0xb'));router[_0x1ab08a('0x5')]('/',auth[_0x1ab08a('0x2')](),controller[_0x1ab08a('0x3')]),router[_0x1ab08a('0x5')]('/:id',auth[_0x1ab08a('0x2')](),controller['show']),router['post']('/',auth[_0x1ab08a('0x2')](),controller[_0x1ab08a('0x9')]),router[_0x1ab08a('0x8')](_0x1ab08a('0x0'),auth[_0x1ab08a('0x2')](),controller[_0x1ab08a('0x1')]),router[_0x1ab08a('0xa')](_0x1ab08a('0x0'),auth[_0x1ab08a('0x2')](),controller[_0x1ab08a('0x6')]),module[_0x1ab08a('0xc')]=router; \ No newline at end of file diff --git a/server/api/network/network.attributes.js b/server/api/network/network.attributes.js index c0d16c0..486a3f8 100644 --- a/server/api/network/network.attributes.js +++ b/server/api/network/network.attributes.js @@ -1 +1 @@ -const a456_0x3c39=['sequelize','stun','ENUM','turn','externip','STRING','exports'];(function(_0x530212,_0x3c394c){const _0x4ef9e0=function(_0x1e29dc){while(--_0x1e29dc){_0x530212['push'](_0x530212['shift']());}};_0x4ef9e0(++_0x3c394c);}(a456_0x3c39,0x12f));const a456_0x4ef9=function(_0x530212,_0x3c394c){_0x530212=_0x530212-0x0;let _0x4ef9e0=a456_0x3c39[_0x530212];return _0x4ef9e0;};const _0x26b692=a456_0x4ef9;'use strict';const Sequelize=require(_0x26b692('0x5'));module[_0x26b692('0x4')]={'type':{'type':Sequelize[_0x26b692('0x0')]('localnet',_0x26b692('0x2'),_0x26b692('0x6'),_0x26b692('0x1'))},'value':{'type':Sequelize[_0x26b692('0x3')]},'username':{'type':Sequelize[_0x26b692('0x3')]},'password':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a456_0x1a65=['localnet','ENUM','STRING','exports','sequelize','turn'];(function(_0x1bf910,_0x1a6513){const _0x6b616d=function(_0x298e65){while(--_0x298e65){_0x1bf910['push'](_0x1bf910['shift']());}};_0x6b616d(++_0x1a6513);}(a456_0x1a65,0x197));const a456_0x6b61=function(_0x1bf910,_0x1a6513){_0x1bf910=_0x1bf910-0x0;let _0x6b616d=a456_0x1a65[_0x1bf910];return _0x6b616d;};const _0x534b85=a456_0x6b61;'use strict';const Sequelize=require(_0x534b85('0x5'));module[_0x534b85('0x4')]={'type':{'type':Sequelize[_0x534b85('0x2')](_0x534b85('0x1'),'externip','stun',_0x534b85('0x0'))},'value':{'type':Sequelize['STRING']},'username':{'type':Sequelize[_0x534b85('0x3')]},'password':{'type':Sequelize[_0x534b85('0x3')]}}; \ No newline at end of file diff --git a/server/api/network/network.controller.js b/server/api/network/network.controller.js index de7bd20..284bcab 100644 --- a/server/api/network/network.controller.js +++ b/server/api/network/network.controller.js @@ -1 +1 @@ -const a457_0x1ef4=['Content-Range','body','request','show','error','client','utf8','order','../../config/logger','findAll','map','destroy','../../mysqldb','writeFileSync','files/templates/network.ejs','Network','limit','rows','options','pick','set','includeAll','attributes','rawAttributes','where','message','Network,\x20%s,\x20%s','readFileSync','server/files/templates/turn_multiple.ejs','catch','create','offset','chan_sip.so','render','type','stack','STUN','name','model','/etc/asterisk/stun_xcally.conf','then','debug','lodash','params','sendStatus','path','update','Network,\x20%s,\x20%s,\x20%s','root','filters','api','toUpperCase','res_stun_monitor.so','/etc/asterisk/sip_xcally_%s.conf','sequelize','server/files/templates/stun_multiple.ejs','files/templates/stun_multiple.ejs','toLowerCase','intersection','include','transaction','ejs','info','join','count','TURN','query','result','index','format','sort','fields','like','json','http','findOne','status','/etc/asterisk/turn_xcally.conf','filter','keys','merge','Reload','nolimit','length','../../config/environment'];(function(_0x3ca130,_0x1ef44e){const _0x3396cc=function(_0x43b42f){while(--_0x43b42f){_0x3ca130['push'](_0x3ca130['shift']());}};_0x3396cc(++_0x1ef44e);}(a457_0x1ef4,0xe1));const a457_0x3396=function(_0x3ca130,_0x1ef44e){_0x3ca130=_0x3ca130-0x0;let _0x3396cc=a457_0x1ef4[_0x3ca130];return _0x3396cc;};const _0x2379f8=a457_0x3396;'use strict';const util=require('util'),path=require(_0x2379f8('0x4b')),ejs=require(_0x2379f8('0x6')),fs=require('fs'),_=require(_0x2379f8('0x48')),qs=require('../../components/parsers/qs'),logger=require(_0x2379f8('0x26'))(_0x2379f8('0x50')),config=require(_0x2379f8('0x1d')),db=require(_0x2379f8('0x2a'))['db'],{Op}=require(_0x2379f8('0x54')),jayson=require('jayson/promise'),client=jayson[_0x2379f8('0x23')][_0x2379f8('0x13')]({'port':0x232a});function respondWithRpcPromise(_0x43b42f,_0x699dfc,_0x2b6022,_0x3046c7){return new Promise(function(_0x50aa3b,_0x513a46){const _0x68dbed=a457_0x3396,_0x30b7fe=_0x3046c7||client;return _0x30b7fe[_0x68dbed('0x20')](_0x43b42f,_0x2b6022)[_0x68dbed('0x46')](function(_0x1cd6bb){const _0x540dc8=_0x68dbed;logger[_0x540dc8('0x7')](_0x540dc8('0x38'),_0x699dfc,'request\x20sent'),logger[_0x540dc8('0x47')](_0x540dc8('0x4d'),_0x699dfc,'request\x20sent',JSON['stringify'](_0x1cd6bb));if(_0x1cd6bb[_0x540dc8('0x22')]){if(_0x1cd6bb[_0x540dc8('0x22')]['code']===0x1f4)return logger['error'](_0x540dc8('0x38'),_0x699dfc,_0x1cd6bb['error'][_0x540dc8('0x37')]),_0x513a46(_0x1cd6bb[_0x540dc8('0x22')][_0x540dc8('0x37')]);return logger[_0x540dc8('0x22')]('Network,\x20%s,\x20%s',_0x699dfc,_0x1cd6bb[_0x540dc8('0x22')]['message']),_0x50aa3b(_0x1cd6bb[_0x540dc8('0x22')]['message']);}else logger['info'](_0x540dc8('0x38'),_0x699dfc,'request\x20sent'),_0x50aa3b(_0x1cd6bb[_0x540dc8('0xc')]['message']);})['catch'](function(_0x4c737f){const _0x294207=_0x68dbed;logger[_0x294207('0x22')]('Network,\x20%s,\x20%s',_0x699dfc,_0x4c737f),_0x513a46(_0x4c737f);});});}function respondWithResult(_0x2f5e02,_0x1236f0){return _0x1236f0=_0x1236f0||0xc8,function(_0x5b58c5){const _0x14b673=a457_0x3396;if(_0x5b58c5)return _0x2f5e02[_0x14b673('0x15')](_0x1236f0)['json'](_0x5b58c5);};}function respondWithFilteredResult(_0x578693,_0x447b43){return function(_0x528399){const _0x3ac170=a457_0x3396;if(_0x528399){const _0x206779=_0x528399['count'],_0x1f8e23=_0x447b43['offset'];let _0x2ea2f9=_0x447b43[_0x3ac170('0x3d')]+_0x447b43['limit'],_0x3eadc3;return _0x2ea2f9>=_0x206779?(_0x2ea2f9=_0x206779,_0x3eadc3=0xc8):_0x3eadc3=0xce,_0x578693['status'](_0x3eadc3),_0x578693[_0x3ac170('0x32')](_0x3ac170('0x1e'),_0x1f8e23+'-'+_0x2ea2f9+'/'+_0x206779)[_0x3ac170('0x12')](_0x528399);}return null;};}function saveUpdates(_0x3b5ca4){return function(_0x155e72){const _0x4a195a=a457_0x3396;if(_0x155e72)return _0x155e72['update'](_0x3b5ca4)[_0x4a195a('0x46')](function(_0x43b39c){return _0x43b39c;});return null;};}function removeEntity(_0x29eefb){return function(_0x5214f8){const _0x159d47=a457_0x3396;if(_0x5214f8)return _0x5214f8[_0x159d47('0x29')]()[_0x159d47('0x46')](function(){const _0x2038de=_0x159d47;_0x29eefb[_0x2038de('0x15')](0xcc)['end']();});};}function handleEntityNotFound(_0x46753f){return function(_0x34dcc1){const _0x4a449f=a457_0x3396;return!_0x34dcc1&&_0x46753f[_0x4a449f('0x4a')](0x194),_0x34dcc1;};}function handleError(_0x1b7d2a,_0x417e69){return _0x417e69=_0x417e69||0x1f4,function(_0x411083){const _0x83b5a8=a457_0x3396;logger[_0x83b5a8('0x22')](_0x411083[_0x83b5a8('0x41')]),_0x411083[_0x83b5a8('0x43')]&&delete _0x411083['name'],_0x1b7d2a['status'](_0x417e69)['send'](_0x411083);};}exports[_0x2379f8('0xd')]=function(_0x191244,_0x2af925){const _0x33c22b=_0x2379f8;let _0x23ce2f={};const _0x3e8b2e={},_0x4c1617={'count':0x0,'rows':[]},_0x3f72a7=_[_0x33c22b('0x28')](db[_0x33c22b('0x2d')][_0x33c22b('0x35')],function(_0x3d4441){const _0x450df6=_0x33c22b;return{'name':_0x3d4441['fieldName'],'type':_0x3d4441[_0x450df6('0x40')]['key']};});_0x3e8b2e[_0x33c22b('0x44')]=_[_0x33c22b('0x28')](_0x3f72a7,'name'),_0x3e8b2e[_0x33c22b('0xb')]=_[_0x33c22b('0x18')](_0x191244[_0x33c22b('0xb')]),_0x3e8b2e[_0x33c22b('0x4f')]=_[_0x33c22b('0x3')](_0x3e8b2e[_0x33c22b('0x44')],_0x3e8b2e['query']),_0x23ce2f[_0x33c22b('0x34')]=_[_0x33c22b('0x3')](_0x3e8b2e[_0x33c22b('0x44')],qs['fields'](_0x191244[_0x33c22b('0xb')][_0x33c22b('0x10')])),_0x23ce2f[_0x33c22b('0x34')]=_0x23ce2f[_0x33c22b('0x34')][_0x33c22b('0x1c')]?_0x23ce2f[_0x33c22b('0x34')]:_0x3e8b2e['model'];typeof _0x191244['query'][_0x33c22b('0x1b')]==='undefined'&&(_0x23ce2f[_0x33c22b('0x2e')]=qs[_0x33c22b('0x2e')](_0x191244[_0x33c22b('0xb')][_0x33c22b('0x2e')]),_0x23ce2f['offset']=qs[_0x33c22b('0x3d')](_0x191244[_0x33c22b('0xb')][_0x33c22b('0x3d')]));_0x23ce2f[_0x33c22b('0x25')]=qs[_0x33c22b('0xf')](_0x191244[_0x33c22b('0xb')][_0x33c22b('0xf')]),_0x23ce2f[_0x33c22b('0x36')]=qs['filters'](_[_0x33c22b('0x31')](_0x191244[_0x33c22b('0xb')],_0x3e8b2e[_0x33c22b('0x4f')]),_0x3f72a7);_0x191244[_0x33c22b('0xb')][_0x33c22b('0x17')]&&(_0x23ce2f[_0x33c22b('0x36')]=_[_0x33c22b('0x19')](_0x23ce2f['where'],{[Op['or']]:_[_0x33c22b('0x28')](_0x3f72a7,function(_0x2e5bdb){const _0x498840=_0x33c22b;if(_0x2e5bdb[_0x498840('0x40')]!=='VIRTUAL'){const _0x46486e={};return _0x46486e[_0x2e5bdb['name']]={[Op[_0x498840('0x11')]]:'%'+_0x191244[_0x498840('0xb')][_0x498840('0x17')]+'%'},_0x46486e;}})}));_0x23ce2f=_[_0x33c22b('0x19')]({},_0x23ce2f,_0x191244['options']);const _0x1d9b3d={'where':_0x23ce2f['where']};return db['Network'][_0x33c22b('0x9')](_0x1d9b3d)[_0x33c22b('0x46')](function(_0x431b37){const _0x417e90=_0x33c22b;return _0x4c1617['count']=_0x431b37,_0x191244['query'][_0x417e90('0x33')]&&(_0x23ce2f[_0x417e90('0x4')]=[{'all':!![]}]),db[_0x417e90('0x2d')]['findAll'](_0x23ce2f);})[_0x33c22b('0x46')](function(_0x1e03f9){const _0x1910fb=_0x33c22b;return _0x4c1617[_0x1910fb('0x2f')]=_0x1e03f9,_0x4c1617;})[_0x33c22b('0x46')](respondWithFilteredResult(_0x2af925,_0x23ce2f))[_0x33c22b('0x3b')](handleError(_0x2af925,null));},exports[_0x2379f8('0x21')]=function(_0x2a2a79,_0x29d958){const _0x3fc3c0=_0x2379f8;let _0x77b0b7={'raw':!![],'where':{'id':_0x2a2a79['params']['id']}};const _0x25b609={};return _0x25b609[_0x3fc3c0('0x44')]=_[_0x3fc3c0('0x18')](db['Network'][_0x3fc3c0('0x35')]),_0x25b609[_0x3fc3c0('0xb')]=_[_0x3fc3c0('0x18')](_0x2a2a79[_0x3fc3c0('0xb')]),_0x25b609[_0x3fc3c0('0x4f')]=_['intersection'](_0x25b609['model'],_0x25b609[_0x3fc3c0('0xb')]),_0x77b0b7[_0x3fc3c0('0x34')]=_['intersection'](_0x25b609[_0x3fc3c0('0x44')],qs[_0x3fc3c0('0x10')](_0x2a2a79[_0x3fc3c0('0xb')][_0x3fc3c0('0x10')])),_0x77b0b7[_0x3fc3c0('0x34')]=_0x77b0b7[_0x3fc3c0('0x34')][_0x3fc3c0('0x1c')]?_0x77b0b7[_0x3fc3c0('0x34')]:_0x25b609[_0x3fc3c0('0x44')],_0x2a2a79['query']['includeAll']&&(_0x77b0b7[_0x3fc3c0('0x4')]=[{'all':!![]}]),_0x77b0b7=_[_0x3fc3c0('0x19')]({},_0x77b0b7,_0x2a2a79[_0x3fc3c0('0x30')]),db[_0x3fc3c0('0x2d')][_0x3fc3c0('0x14')](_0x77b0b7)[_0x3fc3c0('0x46')](handleEntityNotFound(_0x29d958,null))['then'](respondWithResult(_0x29d958,null))[_0x3fc3c0('0x3b')](handleError(_0x29d958,null));},exports[_0x2379f8('0x3c')]=function(_0x548668,_0x5c4418){const _0x15e5c9=_0x2379f8;let _0x1510f4;return db['sequelize'][_0x15e5c9('0x5')](function(){const _0x283802=_0x15e5c9;return db[_0x283802('0x2d')][_0x283802('0x3c')](_0x548668[_0x283802('0x1f')],{'raw':!![]})[_0x283802('0x46')](function(_0x31e652){const _0x19ad28=_0x283802;return _0x1510f4=_0x31e652,db[_0x19ad28('0x2d')][_0x19ad28('0x27')]({'where':{'type':_0x548668[_0x19ad28('0x1f')][_0x19ad28('0x40')]},'raw':!![]});})[_0x283802('0x46')](function(_0x4fff97){const _0x20f60c=_0x283802;if(_0x1510f4['type'][_0x20f60c('0x51')]()=='STUN'){const _0x169f1a=fs[_0x20f60c('0x39')](path[_0x20f60c('0x8')](config[_0x20f60c('0x4e')],_0x20f60c('0x0')),_0x20f60c('0x24')),_0x24e4bc=ejs['render'](_0x169f1a,{'networks':_0x4fff97||[]});return fs[_0x20f60c('0x2b')]('/etc/asterisk/stun_xcally.conf',_0x24e4bc),respondWithRpcPromise(_0x20f60c('0x1a'),_0x20f60c('0x3c'),{'module':_0x20f60c('0x52')});}else{if(_0x1510f4[_0x20f60c('0x40')][_0x20f60c('0x51')]()=='TURN'){const _0x43b677=fs['readFileSync'](path[_0x20f60c('0x8')](config[_0x20f60c('0x4e')],_0x20f60c('0x3a')),_0x20f60c('0x24')),_0x2654e6=ejs[_0x20f60c('0x3f')](_0x43b677,{'networks':_0x4fff97||[]});return fs['writeFileSync'](_0x20f60c('0x16'),_0x2654e6),respondWithRpcPromise('Reload',_0x20f60c('0x3c'),{'module':'res_stun_monitor.so'});}else{const _0x31ca68=fs[_0x20f60c('0x39')](path[_0x20f60c('0x8')](config[_0x20f60c('0x4e')],_0x20f60c('0x2c')),'utf8'),_0xd7741=ejs[_0x20f60c('0x3f')](_0x31ca68,{'networks':_0x4fff97||[]});return fs[_0x20f60c('0x2b')](util[_0x20f60c('0xe')](_0x20f60c('0x53'),_0x548668[_0x20f60c('0x1f')][_0x20f60c('0x40')][_0x20f60c('0x2')]()),_0xd7741),respondWithRpcPromise(_0x20f60c('0x1a'),_0x20f60c('0x3c'),{'module':_0x20f60c('0x3e')});}}})[_0x283802('0x46')](function(){return _0x1510f4;});})[_0x15e5c9('0x46')](respondWithResult(_0x5c4418,0xc9))[_0x15e5c9('0x3b')](handleError(_0x5c4418,null));},exports[_0x2379f8('0x4c')]=function(_0x3b19f5,_0x4f7cb0){const _0x275fb9=_0x2379f8;let _0x4d2026;return db['sequelize']['transaction'](function(){const _0x5012d1=a457_0x3396;return db[_0x5012d1('0x2d')][_0x5012d1('0x14')]({'where':{'id':_0x3b19f5['params']['id']}})[_0x5012d1('0x46')](handleEntityNotFound(_0x4f7cb0,null))['then'](saveUpdates(_0x3b19f5['body'],null))[_0x5012d1('0x46')](function(_0x27f794){const _0x334090=_0x5012d1;if(_0x27f794)return _0x4d2026=_0x27f794,db['Network'][_0x334090('0x27')]({'where':{'type':_0x4d2026[_0x334090('0x40')]},'raw':!![]});return null;})[_0x5012d1('0x46')](function(_0x48d752){const _0x309413=_0x5012d1;if(_0x4d2026['type']['toUpperCase']()==_0x309413('0x42')){const _0x59662f=fs[_0x309413('0x39')](path[_0x309413('0x8')](config[_0x309413('0x4e')],_0x309413('0x0')),_0x309413('0x24')),_0x508818=ejs[_0x309413('0x3f')](_0x59662f,{'networks':_0x48d752||[]});return fs[_0x309413('0x2b')](_0x309413('0x45'),_0x508818),respondWithRpcPromise(_0x309413('0x1a'),_0x309413('0x4c'),{'module':_0x309413('0x52')});}else{if(_0x4d2026[_0x309413('0x40')][_0x309413('0x51')]()==_0x309413('0xa')){const _0x3a8f28=fs[_0x309413('0x39')](path[_0x309413('0x8')](config[_0x309413('0x4e')],_0x309413('0x3a')),'utf8'),_0x18e7b2=ejs[_0x309413('0x3f')](_0x3a8f28,{'networks':_0x48d752||[]});return fs[_0x309413('0x2b')]('/etc/asterisk/turn_xcally.conf',_0x18e7b2),respondWithRpcPromise(_0x309413('0x1a'),_0x309413('0x4c'),{'module':_0x309413('0x52')});}else{const _0xb32448=fs[_0x309413('0x39')](path['join'](config[_0x309413('0x4e')],_0x309413('0x2c')),'utf8'),_0x387d93=ejs[_0x309413('0x3f')](_0xb32448,{'networks':_0x48d752||[]});return fs[_0x309413('0x2b')](util[_0x309413('0xe')](_0x309413('0x53'),_0x3b19f5[_0x309413('0x1f')]['type'][_0x309413('0x2')]()),_0x387d93),respondWithRpcPromise('Reload',_0x309413('0x4c'),{'module':_0x309413('0x3e')});}}})[_0x5012d1('0x46')](function(_0x44597c){if(_0x44597c)return _0x4d2026;return null;});})[_0x275fb9('0x46')](respondWithResult(_0x4f7cb0,null))[_0x275fb9('0x3b')](handleError(_0x4f7cb0,null));},exports['destroy']=function(_0xc6d1c4,_0x2456eb){const _0x4b9168=_0x2379f8;let _0x80c15c;return db[_0x4b9168('0x2d')][_0x4b9168('0x14')]({'where':{'id':_0xc6d1c4[_0x4b9168('0x49')]['id']}})[_0x4b9168('0x46')](function(_0x17c27e){return _0x80c15c=_0x17c27e,_0x17c27e;})[_0x4b9168('0x46')](handleEntityNotFound(_0x2456eb,null))[_0x4b9168('0x46')](removeEntity(_0x2456eb,null))[_0x4b9168('0x46')](function(){const _0x56b116=_0x4b9168;if(_0x80c15c)return db[_0x56b116('0x2d')][_0x56b116('0x27')]({'where':{'type':_0x80c15c['type']},'raw':!![]});})[_0x4b9168('0x46')](function(_0x616578){const _0x50f734=_0x4b9168;if(_0x80c15c[_0x50f734('0x40')][_0x50f734('0x51')]()=='STUN'){const _0x21a8f1=fs[_0x50f734('0x39')](path[_0x50f734('0x8')](config[_0x50f734('0x4e')],_0x50f734('0x1')),_0x50f734('0x24')),_0x5826c0=ejs['render'](_0x21a8f1,{'networks':_0x616578||[]});return fs[_0x50f734('0x2b')](_0x50f734('0x45'),_0x5826c0),respondWithRpcPromise('Reload',_0x50f734('0x29'),{'module':_0x50f734('0x52')});}else{if(_0x80c15c[_0x50f734('0x40')]['toUpperCase']()=='TURN'){const _0x502e9a=fs['readFileSync'](path[_0x50f734('0x8')](config[_0x50f734('0x4e')],'files/templates/turn_multiple.ejs'),_0x50f734('0x24')),_0x4a3d1d=ejs['render'](_0x502e9a,{'networks':_0x616578||[]});return fs[_0x50f734('0x2b')](_0x50f734('0x16'),_0x4a3d1d),respondWithRpcPromise(_0x50f734('0x1a'),_0x50f734('0x29'),{'module':'res_stun_monitor.so'});}else{const _0x10038b=fs['readFileSync'](path['join'](config['root'],_0x50f734('0x2c')),_0x50f734('0x24')),_0x1293a4=ejs['render'](_0x10038b,{'networks':_0x616578||[]});return fs[_0x50f734('0x2b')](util[_0x50f734('0xe')](_0x50f734('0x53'),_0xc6d1c4[_0x50f734('0x1f')]['type'][_0x50f734('0x2')]()),_0x1293a4),respondWithRpcPromise(_0x50f734('0x1a'),_0x50f734('0x29'),{'module':_0x50f734('0x3e')});}}})['catch'](handleError(_0x2456eb,null));}; \ No newline at end of file +const a457_0x4410=['like','sort','filter','files/templates/network.ejs','root','filters','client','api','send','lodash','create','findOne','/etc/asterisk/sip_xcally_%s.conf','params','key','transaction','end','status','length','request','utf8','nolimit','TURN','body','fields','destroy','attributes','undefined','type','keys','chan_sip.so','findAll','limit','includeAll','Network','res_stun_monitor.so','util','name','catch','stringify','/etc/asterisk/turn_xcally.conf','readFileSync','join','http','where','toUpperCase','offset','count','request\x20sent','json','info','writeFileSync','include','server/files/templates/turn_multiple.ejs','Network,\x20%s,\x20%s,\x20%s','format','merge','debug','order','Reload','update','../../components/parsers/qs','then','files/templates/stun_multiple.ejs','path','query','pick','show','index','toLowerCase','/etc/asterisk/stun_xcally.conf','code','ejs','options','render','intersection','message','error','model','Network,\x20%s,\x20%s','map','STUN'];(function(_0x11d432,_0x441046){const _0x42e1d3=function(_0x55e119){while(--_0x55e119){_0x11d432['push'](_0x11d432['shift']());}};_0x42e1d3(++_0x441046);}(a457_0x4410,0x17c));const a457_0x42e1=function(_0x11d432,_0x441046){_0x11d432=_0x11d432-0x0;let _0x42e1d3=a457_0x4410[_0x11d432];return _0x42e1d3;};const _0x54bebc=a457_0x42e1;'use strict';const util=require(_0x54bebc('0x42')),path=require(_0x54bebc('0xc')),ejs=require(_0x54bebc('0x14')),fs=require('fs'),_=require(_0x54bebc('0x27')),qs=require(_0x54bebc('0x9')),logger=require('../../config/logger')(_0x54bebc('0x25')),config=require('../../config/environment'),db=require('../../mysqldb')['db'],{Op}=require('sequelize'),jayson=require('jayson/promise'),client=jayson[_0x54bebc('0x24')][_0x54bebc('0x49')]({'port':0x232a});function respondWithRpcPromise(_0x55e119,_0x511d43,_0x326eb0,_0xd17e2a){return new Promise(function(_0x32b5b4,_0x7d1d04){const _0x5cf6c7=a457_0x42e1,_0x25de0b=_0xd17e2a||client;return _0x25de0b[_0x5cf6c7('0x31')](_0x55e119,_0x326eb0)[_0x5cf6c7('0xa')](function(_0x184949){const _0x4633dd=_0x5cf6c7;logger[_0x4633dd('0x50')](_0x4633dd('0x1b'),_0x511d43,'request\x20sent'),logger[_0x4633dd('0x5')](_0x4633dd('0x2'),_0x511d43,_0x4633dd('0x4e'),JSON[_0x4633dd('0x45')](_0x184949));if(_0x184949[_0x4633dd('0x19')]){if(_0x184949['error'][_0x4633dd('0x13')]===0x1f4)return logger[_0x4633dd('0x19')](_0x4633dd('0x1b'),_0x511d43,_0x184949[_0x4633dd('0x19')][_0x4633dd('0x18')]),_0x7d1d04(_0x184949['error'][_0x4633dd('0x18')]);return logger['error'](_0x4633dd('0x1b'),_0x511d43,_0x184949[_0x4633dd('0x19')][_0x4633dd('0x18')]),_0x32b5b4(_0x184949[_0x4633dd('0x19')]['message']);}else logger[_0x4633dd('0x50')](_0x4633dd('0x1b'),_0x511d43,_0x4633dd('0x4e')),_0x32b5b4(_0x184949['result'][_0x4633dd('0x18')]);})[_0x5cf6c7('0x44')](function(_0x26d0c){logger['error']('Network,\x20%s,\x20%s',_0x511d43,_0x26d0c),_0x7d1d04(_0x26d0c);});});}function respondWithResult(_0x2fca09,_0x1314bb){return _0x1314bb=_0x1314bb||0xc8,function(_0x41dee3){const _0xa51c5d=a457_0x42e1;if(_0x41dee3)return _0x2fca09[_0xa51c5d('0x2f')](_0x1314bb)[_0xa51c5d('0x4f')](_0x41dee3);};}function respondWithFilteredResult(_0x2d338c,_0x2b3d9f){return function(_0x512a64){const _0x29bf61=a457_0x42e1;if(_0x512a64){const _0x2548c4=_0x512a64[_0x29bf61('0x4d')],_0x51b790=_0x2b3d9f[_0x29bf61('0x4c')];let _0x354df6=_0x2b3d9f[_0x29bf61('0x4c')]+_0x2b3d9f['limit'],_0x5ae6f8;return _0x354df6>=_0x2548c4?(_0x354df6=_0x2548c4,_0x5ae6f8=0xc8):_0x5ae6f8=0xce,_0x2d338c['status'](_0x5ae6f8),_0x2d338c['set']('Content-Range',_0x51b790+'-'+_0x354df6+'/'+_0x2548c4)['json'](_0x512a64);}return null;};}function saveUpdates(_0xf2da49){return function(_0x26640f){const _0xd465a0=a457_0x42e1;if(_0x26640f)return _0x26640f[_0xd465a0('0x8')](_0xf2da49)[_0xd465a0('0xa')](function(_0xb83da8){return _0xb83da8;});return null;};}function removeEntity(_0x23f1b9){return function(_0x2525e3){const _0x5a6ddc=a457_0x42e1;if(_0x2525e3)return _0x2525e3[_0x5a6ddc('0x37')]()[_0x5a6ddc('0xa')](function(){const _0x19d994=_0x5a6ddc;_0x23f1b9['status'](0xcc)[_0x19d994('0x2e')]();});};}function handleEntityNotFound(_0x52a325){return function(_0x5af7a8){return!_0x5af7a8&&_0x52a325['sendStatus'](0x194),_0x5af7a8;};}function handleError(_0x2f9ca8,_0x4fd996){return _0x4fd996=_0x4fd996||0x1f4,function(_0xbc15cf){const _0x3b756e=a457_0x42e1;logger[_0x3b756e('0x19')](_0xbc15cf['stack']),_0xbc15cf[_0x3b756e('0x43')]&&delete _0xbc15cf[_0x3b756e('0x43')],_0x2f9ca8[_0x3b756e('0x2f')](_0x4fd996)[_0x3b756e('0x26')](_0xbc15cf);};}exports[_0x54bebc('0x10')]=function(_0x488bc0,_0x4ee496){const _0xcd891e=_0x54bebc;let _0x534ad7={};const _0x1fc8d3={},_0x136a1c={'count':0x0,'rows':[]},_0xc1f456=_['map'](db['Network']['rawAttributes'],function(_0xd991a0){const _0x5c07d7=a457_0x42e1;return{'name':_0xd991a0['fieldName'],'type':_0xd991a0['type'][_0x5c07d7('0x2c')]};});_0x1fc8d3['model']=_[_0xcd891e('0x1c')](_0xc1f456,_0xcd891e('0x43')),_0x1fc8d3[_0xcd891e('0xd')]=_[_0xcd891e('0x3b')](_0x488bc0['query']),_0x1fc8d3['filters']=_[_0xcd891e('0x17')](_0x1fc8d3[_0xcd891e('0x1a')],_0x1fc8d3[_0xcd891e('0xd')]),_0x534ad7['attributes']=_['intersection'](_0x1fc8d3[_0xcd891e('0x1a')],qs[_0xcd891e('0x36')](_0x488bc0[_0xcd891e('0xd')][_0xcd891e('0x36')])),_0x534ad7['attributes']=_0x534ad7[_0xcd891e('0x38')][_0xcd891e('0x30')]?_0x534ad7[_0xcd891e('0x38')]:_0x1fc8d3[_0xcd891e('0x1a')];typeof _0x488bc0[_0xcd891e('0xd')][_0xcd891e('0x33')]===_0xcd891e('0x39')&&(_0x534ad7[_0xcd891e('0x3e')]=qs[_0xcd891e('0x3e')](_0x488bc0[_0xcd891e('0xd')]['limit']),_0x534ad7['offset']=qs[_0xcd891e('0x4c')](_0x488bc0[_0xcd891e('0xd')][_0xcd891e('0x4c')]));_0x534ad7[_0xcd891e('0x6')]=qs[_0xcd891e('0x1f')](_0x488bc0[_0xcd891e('0xd')]['sort']),_0x534ad7[_0xcd891e('0x4a')]=qs['filters'](_[_0xcd891e('0xe')](_0x488bc0['query'],_0x1fc8d3[_0xcd891e('0x23')]),_0xc1f456);_0x488bc0[_0xcd891e('0xd')]['filter']&&(_0x534ad7[_0xcd891e('0x4a')]=_['merge'](_0x534ad7[_0xcd891e('0x4a')],{[Op['or']]:_[_0xcd891e('0x1c')](_0xc1f456,function(_0x2c4a49){const _0x2f8610=_0xcd891e;if(_0x2c4a49[_0x2f8610('0x3a')]!=='VIRTUAL'){const _0x21489a={};return _0x21489a[_0x2c4a49['name']]={[Op[_0x2f8610('0x1e')]]:'%'+_0x488bc0[_0x2f8610('0xd')][_0x2f8610('0x20')]+'%'},_0x21489a;}})}));_0x534ad7=_[_0xcd891e('0x4')]({},_0x534ad7,_0x488bc0[_0xcd891e('0x15')]);const _0x16a22d={'where':_0x534ad7['where']};return db[_0xcd891e('0x40')][_0xcd891e('0x4d')](_0x16a22d)[_0xcd891e('0xa')](function(_0x364860){const _0x4bf266=_0xcd891e;return _0x136a1c[_0x4bf266('0x4d')]=_0x364860,_0x488bc0[_0x4bf266('0xd')]['includeAll']&&(_0x534ad7[_0x4bf266('0x0')]=[{'all':!![]}]),db[_0x4bf266('0x40')]['findAll'](_0x534ad7);})[_0xcd891e('0xa')](function(_0x34eb1b){return _0x136a1c['rows']=_0x34eb1b,_0x136a1c;})[_0xcd891e('0xa')](respondWithFilteredResult(_0x4ee496,_0x534ad7))[_0xcd891e('0x44')](handleError(_0x4ee496,null));},exports[_0x54bebc('0xf')]=function(_0x592001,_0x58bca1){const _0x389920=_0x54bebc;let _0x5c4478={'raw':!![],'where':{'id':_0x592001['params']['id']}};const _0x550299={};return _0x550299[_0x389920('0x1a')]=_[_0x389920('0x3b')](db[_0x389920('0x40')]['rawAttributes']),_0x550299[_0x389920('0xd')]=_[_0x389920('0x3b')](_0x592001[_0x389920('0xd')]),_0x550299[_0x389920('0x23')]=_[_0x389920('0x17')](_0x550299[_0x389920('0x1a')],_0x550299[_0x389920('0xd')]),_0x5c4478[_0x389920('0x38')]=_[_0x389920('0x17')](_0x550299[_0x389920('0x1a')],qs['fields'](_0x592001[_0x389920('0xd')][_0x389920('0x36')])),_0x5c4478['attributes']=_0x5c4478[_0x389920('0x38')][_0x389920('0x30')]?_0x5c4478[_0x389920('0x38')]:_0x550299[_0x389920('0x1a')],_0x592001[_0x389920('0xd')][_0x389920('0x3f')]&&(_0x5c4478['include']=[{'all':!![]}]),_0x5c4478=_[_0x389920('0x4')]({},_0x5c4478,_0x592001[_0x389920('0x15')]),db[_0x389920('0x40')][_0x389920('0x29')](_0x5c4478)[_0x389920('0xa')](handleEntityNotFound(_0x58bca1,null))['then'](respondWithResult(_0x58bca1,null))[_0x389920('0x44')](handleError(_0x58bca1,null));},exports[_0x54bebc('0x28')]=function(_0x5da237,_0x3f066e){const _0x20d014=_0x54bebc;let _0x592c16;return db['sequelize'][_0x20d014('0x2d')](function(){const _0x283ecd=_0x20d014;return db[_0x283ecd('0x40')][_0x283ecd('0x28')](_0x5da237[_0x283ecd('0x35')],{'raw':!![]})[_0x283ecd('0xa')](function(_0x4bc783){const _0x4e7321=_0x283ecd;return _0x592c16=_0x4bc783,db[_0x4e7321('0x40')]['findAll']({'where':{'type':_0x5da237[_0x4e7321('0x35')][_0x4e7321('0x3a')]},'raw':!![]});})['then'](function(_0x2a18a5){const _0xea763d=_0x283ecd;if(_0x592c16[_0xea763d('0x3a')]['toUpperCase']()==_0xea763d('0x1d')){const _0xe63b84=fs[_0xea763d('0x47')](path[_0xea763d('0x48')](config[_0xea763d('0x22')],'server/files/templates/stun_multiple.ejs'),'utf8'),_0x2c34d5=ejs[_0xea763d('0x16')](_0xe63b84,{'networks':_0x2a18a5||[]});return fs[_0xea763d('0x51')]('/etc/asterisk/stun_xcally.conf',_0x2c34d5),respondWithRpcPromise(_0xea763d('0x7'),'create',{'module':_0xea763d('0x41')});}else{if(_0x592c16[_0xea763d('0x3a')][_0xea763d('0x4b')]()=='TURN'){const _0x33495a=fs[_0xea763d('0x47')](path[_0xea763d('0x48')](config[_0xea763d('0x22')],_0xea763d('0x1')),_0xea763d('0x32')),_0x521b87=ejs[_0xea763d('0x16')](_0x33495a,{'networks':_0x2a18a5||[]});return fs['writeFileSync'](_0xea763d('0x46'),_0x521b87),respondWithRpcPromise(_0xea763d('0x7'),_0xea763d('0x28'),{'module':_0xea763d('0x41')});}else{const _0x11f486=fs[_0xea763d('0x47')](path[_0xea763d('0x48')](config[_0xea763d('0x22')],_0xea763d('0x21')),_0xea763d('0x32')),_0x13a196=ejs[_0xea763d('0x16')](_0x11f486,{'networks':_0x2a18a5||[]});return fs[_0xea763d('0x51')](util[_0xea763d('0x3')](_0xea763d('0x2a'),_0x5da237[_0xea763d('0x35')]['type'][_0xea763d('0x11')]()),_0x13a196),respondWithRpcPromise('Reload',_0xea763d('0x28'),{'module':_0xea763d('0x3c')});}}})[_0x283ecd('0xa')](function(){return _0x592c16;});})[_0x20d014('0xa')](respondWithResult(_0x3f066e,0xc9))['catch'](handleError(_0x3f066e,null));},exports[_0x54bebc('0x8')]=function(_0x323bf5,_0x5cf5f8){const _0x25c11d=_0x54bebc;let _0x1c68a0;return db['sequelize'][_0x25c11d('0x2d')](function(){const _0x3a0785=_0x25c11d;return db['Network'][_0x3a0785('0x29')]({'where':{'id':_0x323bf5['params']['id']}})[_0x3a0785('0xa')](handleEntityNotFound(_0x5cf5f8,null))['then'](saveUpdates(_0x323bf5[_0x3a0785('0x35')],null))[_0x3a0785('0xa')](function(_0x485453){const _0x3b2f1c=_0x3a0785;if(_0x485453)return _0x1c68a0=_0x485453,db[_0x3b2f1c('0x40')][_0x3b2f1c('0x3d')]({'where':{'type':_0x1c68a0['type']},'raw':!![]});return null;})[_0x3a0785('0xa')](function(_0x27f69f){const _0x2cbde8=_0x3a0785;if(_0x1c68a0['type'][_0x2cbde8('0x4b')]()==_0x2cbde8('0x1d')){const _0x5bb4dc=fs[_0x2cbde8('0x47')](path[_0x2cbde8('0x48')](config[_0x2cbde8('0x22')],'server/files/templates/stun_multiple.ejs'),_0x2cbde8('0x32')),_0xbc3793=ejs[_0x2cbde8('0x16')](_0x5bb4dc,{'networks':_0x27f69f||[]});return fs[_0x2cbde8('0x51')]('/etc/asterisk/stun_xcally.conf',_0xbc3793),respondWithRpcPromise(_0x2cbde8('0x7'),_0x2cbde8('0x8'),{'module':'res_stun_monitor.so'});}else{if(_0x1c68a0[_0x2cbde8('0x3a')][_0x2cbde8('0x4b')]()==_0x2cbde8('0x34')){const _0x355bb3=fs[_0x2cbde8('0x47')](path[_0x2cbde8('0x48')](config[_0x2cbde8('0x22')],'server/files/templates/turn_multiple.ejs'),_0x2cbde8('0x32')),_0x2de846=ejs[_0x2cbde8('0x16')](_0x355bb3,{'networks':_0x27f69f||[]});return fs[_0x2cbde8('0x51')]('/etc/asterisk/turn_xcally.conf',_0x2de846),respondWithRpcPromise(_0x2cbde8('0x7'),_0x2cbde8('0x8'),{'module':_0x2cbde8('0x41')});}else{const _0x43bb15=fs[_0x2cbde8('0x47')](path[_0x2cbde8('0x48')](config[_0x2cbde8('0x22')],_0x2cbde8('0x21')),_0x2cbde8('0x32')),_0x50fc16=ejs['render'](_0x43bb15,{'networks':_0x27f69f||[]});return fs[_0x2cbde8('0x51')](util[_0x2cbde8('0x3')](_0x2cbde8('0x2a'),_0x323bf5[_0x2cbde8('0x35')][_0x2cbde8('0x3a')][_0x2cbde8('0x11')]()),_0x50fc16),respondWithRpcPromise(_0x2cbde8('0x7'),_0x2cbde8('0x8'),{'module':_0x2cbde8('0x3c')});}}})[_0x3a0785('0xa')](function(_0x1df576){if(_0x1df576)return _0x1c68a0;return null;});})[_0x25c11d('0xa')](respondWithResult(_0x5cf5f8,null))['catch'](handleError(_0x5cf5f8,null));},exports[_0x54bebc('0x37')]=function(_0x232766,_0x28eb18){const _0x5e4c20=_0x54bebc;let _0x4ec5f4;return db[_0x5e4c20('0x40')]['findOne']({'where':{'id':_0x232766[_0x5e4c20('0x2b')]['id']}})[_0x5e4c20('0xa')](function(_0x26e37d){return _0x4ec5f4=_0x26e37d,_0x26e37d;})[_0x5e4c20('0xa')](handleEntityNotFound(_0x28eb18,null))[_0x5e4c20('0xa')](removeEntity(_0x28eb18,null))['then'](function(){const _0x465ffb=_0x5e4c20;if(_0x4ec5f4)return db[_0x465ffb('0x40')][_0x465ffb('0x3d')]({'where':{'type':_0x4ec5f4['type']},'raw':!![]});})[_0x5e4c20('0xa')](function(_0x3a8f6c){const _0x611584=_0x5e4c20;if(_0x4ec5f4[_0x611584('0x3a')][_0x611584('0x4b')]()=='STUN'){const _0x149123=fs['readFileSync'](path[_0x611584('0x48')](config[_0x611584('0x22')],_0x611584('0xb')),_0x611584('0x32')),_0x789ac4=ejs[_0x611584('0x16')](_0x149123,{'networks':_0x3a8f6c||[]});return fs[_0x611584('0x51')](_0x611584('0x12'),_0x789ac4),respondWithRpcPromise(_0x611584('0x7'),_0x611584('0x37'),{'module':_0x611584('0x41')});}else{if(_0x4ec5f4['type']['toUpperCase']()==_0x611584('0x34')){const _0x546633=fs[_0x611584('0x47')](path[_0x611584('0x48')](config[_0x611584('0x22')],'files/templates/turn_multiple.ejs'),'utf8'),_0x78623c=ejs[_0x611584('0x16')](_0x546633,{'networks':_0x3a8f6c||[]});return fs['writeFileSync'](_0x611584('0x46'),_0x78623c),respondWithRpcPromise(_0x611584('0x7'),_0x611584('0x37'),{'module':_0x611584('0x41')});}else{const _0x5183f5=fs['readFileSync'](path['join'](config['root'],'files/templates/network.ejs'),_0x611584('0x32')),_0x114a24=ejs['render'](_0x5183f5,{'networks':_0x3a8f6c||[]});return fs[_0x611584('0x51')](util['format'](_0x611584('0x2a'),_0x232766[_0x611584('0x35')][_0x611584('0x3a')][_0x611584('0x11')]()),_0x114a24),respondWithRpcPromise(_0x611584('0x7'),_0x611584('0x37'),{'module':_0x611584('0x3c')});}}})['catch'](handleError(_0x28eb18,null));}; \ No newline at end of file diff --git a/server/api/network/network.model.js b/server/api/network/network.model.js index 167d54f..f4ad1ed 100644 --- a/server/api/network/network.model.js +++ b/server/api/network/network.model.js @@ -1 +1 @@ -const a458_0x592a=['network','exports','./network.attributes'];(function(_0x15e208,_0x592a0d){const _0x51aae7=function(_0x3ef77c){while(--_0x3ef77c){_0x15e208['push'](_0x15e208['shift']());}};_0x51aae7(++_0x592a0d);}(a458_0x592a,0xe7));const a458_0x51aa=function(_0x15e208,_0x592a0d){_0x15e208=_0x15e208-0x0;let _0x51aae7=a458_0x592a[_0x15e208];return _0x51aae7;};const _0x576d1f=a458_0x51aa;'use strict';const attributes=require(_0x576d1f('0x2'));module[_0x576d1f('0x1')]=function(_0x3ef77c){const _0xcaa852=_0x576d1f,_0x2f7997=_0x3ef77c['define']('Network',attributes,{'tableName':_0xcaa852('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2f7997;}; \ No newline at end of file +const a458_0x2f25=['exports','network','./network.attributes'];(function(_0x302db5,_0x2f2543){const _0x2de3f3=function(_0x3d3dfb){while(--_0x3d3dfb){_0x302db5['push'](_0x302db5['shift']());}};_0x2de3f3(++_0x2f2543);}(a458_0x2f25,0x1e1));const a458_0x2de3=function(_0x302db5,_0x2f2543){_0x302db5=_0x302db5-0x0;let _0x2de3f3=a458_0x2f25[_0x302db5];return _0x2de3f3;};const _0x4b3170=a458_0x2de3;'use strict';const attributes=require(_0x4b3170('0x1'));module[_0x4b3170('0x2')]=function(_0x3d3dfb){const _0x37a749=_0x4b3170,_0x451c33=_0x3d3dfb['define']('Network',attributes,{'tableName':_0x37a749('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x451c33;}; \ No newline at end of file diff --git a/server/api/notification/index.js b/server/api/notification/index.js index c31f6bf..0467000 100644 --- a/server/api/notification/index.js +++ b/server/api/notification/index.js @@ -1 +1 @@ -const a459_0x1979=['sendNotification','./notification.controller','post','express','Router','exports','../../components/auth/service','isAuthenticated'];(function(_0x12aa5c,_0x1979b6){const _0x13648e=function(_0x1fa786){while(--_0x1fa786){_0x12aa5c['push'](_0x12aa5c['shift']());}};_0x13648e(++_0x1979b6);}(a459_0x1979,0x1a5));const a459_0x1364=function(_0x12aa5c,_0x1979b6){_0x12aa5c=_0x12aa5c-0x0;let _0x13648e=a459_0x1979[_0x12aa5c];return _0x13648e;};const _0x1b54b6=a459_0x1364;'use strict';const express=require(_0x1b54b6('0x6')),router=express[_0x1b54b6('0x7')](),auth=require(_0x1b54b6('0x1')),controller=require(_0x1b54b6('0x4'));router[_0x1b54b6('0x5')]('/',auth[_0x1b54b6('0x2')](),controller[_0x1b54b6('0x3')]),module[_0x1b54b6('0x0')]=router; \ No newline at end of file +const a459_0x54a6=['express','exports','post','sendNotification'];(function(_0x12a9d7,_0x54a60f){const _0x25055c=function(_0x30f669){while(--_0x30f669){_0x12a9d7['push'](_0x12a9d7['shift']());}};_0x25055c(++_0x54a60f);}(a459_0x54a6,0xbe));const a459_0x2505=function(_0x12a9d7,_0x54a60f){_0x12a9d7=_0x12a9d7-0x0;let _0x25055c=a459_0x54a6[_0x12a9d7];return _0x25055c;};const _0x5b4729=a459_0x2505;'use strict';const express=require(_0x5b4729('0x2')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require('./notification.controller');router[_0x5b4729('0x0')]('/',auth['isAuthenticated'](),controller[_0x5b4729('0x1')]),module[_0x5b4729('0x3')]=router; \ No newline at end of file diff --git a/server/api/notification/notification.attributes.js b/server/api/notification/notification.attributes.js index 1ef87ea..c63ff4d 100644 --- a/server/api/notification/notification.attributes.js +++ b/server/api/notification/notification.attributes.js @@ -1 +1 @@ -const a460_0x42ea=['BOOLEAN','STRING','sequelize','TEXT'];(function(_0x3eba61,_0x42ea47){const _0x285526=function(_0x41f9a4){while(--_0x41f9a4){_0x3eba61['push'](_0x3eba61['shift']());}};_0x285526(++_0x42ea47);}(a460_0x42ea,0x168));const a460_0x2855=function(_0x3eba61,_0x42ea47){_0x3eba61=_0x3eba61-0x0;let _0x285526=a460_0x42ea[_0x3eba61];return _0x285526;};const _0x5a2b96=a460_0x2855;'use strict';const Sequelize=require(_0x5a2b96('0x2'));module['exports']={'body':{'type':Sequelize[_0x5a2b96('0x3')]},'senderName':{'type':Sequelize[_0x5a2b96('0x1')]},'recipientsId':{'type':Sequelize[_0x5a2b96('0x3')]},'recipientsDescription':{'type':Sequelize[_0x5a2b96('0x1')]},'beep':{'type':Sequelize[_0x5a2b96('0x0')]}}; \ No newline at end of file +const a460_0x419a=['STRING','BOOLEAN','exports','TEXT'];(function(_0x5cff0e,_0x419aab){const _0x3bfddb=function(_0x47b166){while(--_0x47b166){_0x5cff0e['push'](_0x5cff0e['shift']());}};_0x3bfddb(++_0x419aab);}(a460_0x419a,0x68));const a460_0x3bfd=function(_0x5cff0e,_0x419aab){_0x5cff0e=_0x5cff0e-0x0;let _0x3bfddb=a460_0x419a[_0x5cff0e];return _0x3bfddb;};const _0x17b075=a460_0x3bfd;'use strict';const Sequelize=require('sequelize');module[_0x17b075('0x2')]={'body':{'type':Sequelize[_0x17b075('0x3')]},'senderName':{'type':Sequelize[_0x17b075('0x0')]},'recipientsId':{'type':Sequelize['TEXT']},'recipientsDescription':{'type':Sequelize[_0x17b075('0x0')]},'beep':{'type':Sequelize[_0x17b075('0x1')]}}; \ No newline at end of file diff --git a/server/api/notification/notification.controller.js b/server/api/notification/notification.controller.js index 94091f9..f292c45 100644 --- a/server/api/notification/notification.controller.js +++ b/server/api/notification/notification.controller.js @@ -1 +1 @@ -const a461_0x39fc=['union','some','Invalid\x20\x27TemplateId\x27\x20parameter','senderName','openchannelqueue','register','chatqueue','Notification','status','forEach','./notification.socket','flatten','TemplateId','Template','join','recipientsId','undefined','html','emit','then','fullname','../../rediscache','Queue','lodash','../../config/logger','findOne','body','Missing\x20\x27recipients\x27\x20parameter','queue','name','SenderId','mailqueue','json','smsqueue','user','sendNotification','recipientsDescription','error','includes','sortBy','ids','catch','model','startCase','replace','getAgents','Invalid\x20\x27recipients\x27\x20object','Missing\x20\x27view\x27\x20parameter','mustache','api','transaction','Invalid\x20model\x20in\x20\x27recipients\x27\x20object','toLowerCase','../../mysqldb','sequelize','text','beep','render'];(function(_0x4a1e41,_0x39fcb4){const _0x3f5ad2=function(_0x17c98c){while(--_0x17c98c){_0x4a1e41['push'](_0x4a1e41['shift']());}};_0x3f5ad2(++_0x39fcb4);}(a461_0x39fc,0x168));const a461_0x3f5a=function(_0x4a1e41,_0x39fcb4){_0x4a1e41=_0x4a1e41-0x0;let _0x3f5ad2=a461_0x39fc[_0x4a1e41];return _0x3f5ad2;};const _0x4e9fe3=a461_0x3f5a;'use strict';const Mustache=require(_0x4e9fe3('0x24')),_=require(_0x4e9fe3('0xb')),logger=require(_0x4e9fe3('0xc'))(_0x4e9fe3('0x25')),{getSocket}=require(_0x4e9fe3('0x9')),socket=getSocket(),db=require(_0x4e9fe3('0x29'))['db'],{ValidationError}=require(_0x4e9fe3('0x2a'));require(_0x4e9fe3('0x38'))[_0x4e9fe3('0x33')](socket);function respondWithResult(_0x17c98c,_0x94eb2b){return _0x94eb2b=_0x94eb2b||0xc8,function(_0x5104c7){const _0x28838c=a461_0x3f5a;if(_0x5104c7)return _0x17c98c[_0x28838c('0x36')](_0x94eb2b)[_0x28838c('0x14')](_0x5104c7);};}function handleError(_0x5418a2,_0x3685de){return _0x3685de=_0x3685de||0x1f4,function(_0x29eedf){const _0x31c281=a461_0x3f5a;logger[_0x31c281('0x19')](_0x29eedf['stack']),_0x29eedf[_0x31c281('0x11')]&&delete _0x29eedf['name'],_0x5418a2[_0x31c281('0x36')](_0x3685de)['send'](_0x29eedf);};}exports[_0x4e9fe3('0x17')]=function(_0x1ec10f,_0x5598ba){const _0x3e753f=_0x4e9fe3;let _0x350bb9=[];if(typeof _0x1ec10f[_0x3e753f('0xe')][_0x3e753f('0x2b')]===_0x3e753f('0x4')&&typeof _0x1ec10f['body'][_0x3e753f('0x0')]===_0x3e753f('0x4'))throw new ValidationError('Must\x20specify\x20at\x20least\x20one\x20argument\x20for\x20\x27text\x27\x20or\x20\x27TemplateId\x27');else{if(typeof _0x1ec10f[_0x3e753f('0xe')]['TemplateId']!==_0x3e753f('0x4')&&typeof _0x1ec10f[_0x3e753f('0xe')]['view']==='undefined')throw new ValidationError(_0x3e753f('0x23'));if(typeof _0x1ec10f['body']['recipients']===_0x3e753f('0x4'))throw new ValidationError(_0x3e753f('0xf'));else{try{_0x350bb9=JSON['parse'](_0x1ec10f['body']['recipients']);}catch(_0x219bdd){logger[_0x3e753f('0x19')](_0x219bdd);throw new ValidationError(_0x3e753f('0x22'));}const _0x4f9565=[_0x3e753f('0x34'),'faxqueue',_0x3e753f('0x13'),_0x3e753f('0x32'),_0x3e753f('0x15'),'voicequeue','whatsappqueue','team',_0x3e753f('0x16')];if(_[_0x3e753f('0x2f')](_0x350bb9,function(_0x4a1e84){const _0x1a858a=_0x3e753f;return!_[_0x1a858a('0x1a')](_0x4f9565,_0x4a1e84[_0x1a858a('0x1e')][_0x1a858a('0x28')]());}))throw new ValidationError(_0x3e753f('0x27'));}}const _0x5c7428={};return _0x5c7428[_0x3e753f('0x31')]=_0x1ec10f[_0x3e753f('0xe')][_0x3e753f('0x31')]?_0x1ec10f[_0x3e753f('0xe')][_0x3e753f('0x31')]:_0x1ec10f[_0x3e753f('0x16')][_0x3e753f('0x8')],_0x5c7428[_0x3e753f('0x18')]=_['isEmpty'](_0x1ec10f['body'][_0x3e753f('0x18')])?null:_0x1ec10f[_0x3e753f('0xe')][_0x3e753f('0x18')],_0x5c7428['beep']=_0x1ec10f[_0x3e753f('0xe')][_0x3e753f('0x2c')]||![],_0x5c7428[_0x3e753f('0x12')]=_0x1ec10f[_0x3e753f('0x16')]['id'],getContent(_0x1ec10f[_0x3e753f('0xe')])[_0x3e753f('0x7')](function(_0xecf3dd){return _0x5c7428['body']=_0xecf3dd,getRecipients(_0x350bb9);})[_0x3e753f('0x7')](function(_0x4ae6af){const _0x1006ed=_0x3e753f;return _0x5c7428[_0x1006ed('0x3')]=_[_0x1006ed('0x1b')](_0x4ae6af)[_0x1006ed('0x2')](','),db[_0x1006ed('0x2a')][_0x1006ed('0x26')](function(_0x814fa5){const _0x485e85=_0x1006ed;return db[_0x485e85('0x35')]['create'](_0x5c7428,{'raw':!![],'transaction':_0x814fa5})[_0x485e85('0x7')](function(_0x50ed7b){const _0x5cb9fb=_0x485e85,_0x4bab53={'sender':_0x5c7428[_0x5cb9fb('0x31')],'description':_0x5c7428[_0x5cb9fb('0x18')],'content':_0x5c7428['body'],'beep':_0x5c7428[_0x5cb9fb('0x2c')]};return _0x4ae6af[_0x5cb9fb('0x37')](function(_0x3df941){const _0x402d86=_0x5cb9fb;_0x4bab53['recipient']=_0x3df941,socket[_0x402d86('0x6')]('notification:send',_0x4bab53);}),_0x50ed7b;});});})[_0x3e753f('0x7')](respondWithResult(_0x5598ba,0xc9))[_0x3e753f('0x1d')](handleError(_0x5598ba,null));};function getContent(_0x39d70f){return new Promise(function(_0x3e668c,_0x1070f4){const _0x24b563=a461_0x3f5a;if(_0x39d70f[_0x24b563('0x2b')]){_0x3e668c(_0x39d70f[_0x24b563('0x2b')]);return;}return db[_0x24b563('0x1')][_0x24b563('0xd')]({'attributes':[_0x24b563('0x5')],'where':{'id':_0x39d70f[_0x24b563('0x0')]},'raw':!![]})[_0x24b563('0x7')](function(_0x51c1c9){const _0xc0418b=_0x24b563;if(!_0x51c1c9)throw new ValidationError(_0xc0418b('0x30'));const _0x43cfde=Mustache[_0xc0418b('0x2d')](_0x51c1c9[_0xc0418b('0x5')],_0x39d70f['view']);_0x3e668c(_0x43cfde);})['catch'](function(_0x1ac212){_0x1070f4(_0x1ac212);});});}function getRecipients(_0x15784d){return new Promise(function(_0x4b5aa8,_0x52f9dc){const _0x3a3c32=a461_0x3f5a;let _0x1e1a7e=[];const _0x2fa05d=[];return _0x15784d[_0x3a3c32('0x37')](function(_0x41aab7){const _0x47c552=_0x3a3c32;let _0x3475ac=_[_0x47c552('0x1f')](_0x41aab7[_0x47c552('0x1e')][_0x47c552('0x28')]());if(_0x3475ac==='User')_0x1e1a7e=_[_0x47c552('0x2e')](_0x1e1a7e,_0x41aab7[_0x47c552('0x1c')]);else{if(_['includes'](_0x3475ac,'queue'))_0x3475ac=_0x3475ac[_0x47c552('0x20')](_0x47c552('0x10'),_0x47c552('0xa'));_0x41aab7[_0x47c552('0x1c')][_0x47c552('0x37')](function(_0x4368cf){_0x2fa05d['push'](getAgents(_0x3475ac,_0x4368cf));});}}),Promise['all'](_0x2fa05d)[_0x3a3c32('0x7')](function(_0x49bd3d){const _0xde6238=_0x3a3c32;_0x1e1a7e=_[_0xde6238('0x2e')](_0x1e1a7e,_[_0xde6238('0x39')](_0x49bd3d)),_0x4b5aa8(_0x1e1a7e);})[_0x3a3c32('0x1d')](function(_0x495226){_0x52f9dc(_0x495226);});});}function getAgents(_0x35614f,_0x4ae805){return new Promise(function(_0x10a059,_0x3660bd){const _0x3e2042=a461_0x3f5a;return db[_0x35614f][_0x3e2042('0xd')]({'where':{'id':_0x4ae805}})['then'](function(_0x1df7fb){const _0x31e197=_0x3e2042;return _0x1df7fb[_0x31e197('0x21')]({'attributes':['id'],'raw':!![]})[_0x31e197('0x7')](function(_0x1f277c){const _0x1630ee=_['map'](_0x1f277c,'id');_0x10a059(_0x1630ee);});})[_0x3e2042('0x1d')](function(_0x5771f2){_0x3660bd(_0x5771f2);});});} \ No newline at end of file +const a461_0xe7d5=['User','body','sendNotification','Queue','Notification','Missing\x20\x27view\x27\x20parameter','undefined','flatten','Missing\x20\x27recipients\x27\x20parameter','text','smsqueue','transaction','Template','then','findOne','forEach','create','stack','startCase','mustache','ids','sequelize','lodash','faxqueue','mailqueue','register','catch','chatqueue','name','./notification.socket','view','user','openchannelqueue','Invalid\x20model\x20in\x20\x27recipients\x27\x20object','recipientsId','fullname','status','senderName','emit','../../mysqldb','notification:send','whatsappqueue','error','recipientsDescription','voicequeue','sortBy','model','map','some','recipients','api','team','beep','recipient','Must\x20specify\x20at\x20least\x20one\x20argument\x20for\x20\x27text\x27\x20or\x20\x27TemplateId\x27','TemplateId','all','includes','union','join','html','json','Invalid\x20\x27recipients\x27\x20object','push'];(function(_0x56271c,_0xe7d5a3){const _0xe7f88b=function(_0x239cf7){while(--_0x239cf7){_0x56271c['push'](_0x56271c['shift']());}};_0xe7f88b(++_0xe7d5a3);}(a461_0xe7d5,0x1d5));const a461_0xe7f8=function(_0x56271c,_0xe7d5a3){_0x56271c=_0x56271c-0x0;let _0xe7f88b=a461_0xe7d5[_0x56271c];return _0xe7f88b;};const _0x28aba0=a461_0xe7f8;'use strict';const Mustache=require(_0x28aba0('0x3e')),_=require(_0x28aba0('0x1')),logger=require('../../config/logger')(_0x28aba0('0x1d')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x28aba0('0x12'))['db'],{ValidationError}=require(_0x28aba0('0x0'));require(_0x28aba0('0x8'))[_0x28aba0('0x4')](socket);function respondWithResult(_0x239cf7,_0x2054af){return _0x2054af=_0x2054af||0xc8,function(_0x5907f9){const _0x4594d0=a461_0xe7f8;if(_0x5907f9)return _0x239cf7[_0x4594d0('0xf')](_0x2054af)[_0x4594d0('0x28')](_0x5907f9);};}function handleError(_0x18ae64,_0x5a0b38){return _0x5a0b38=_0x5a0b38||0x1f4,function(_0x76ca5b){const _0xd22cf4=a461_0xe7f8;logger[_0xd22cf4('0x15')](_0x76ca5b[_0xd22cf4('0x3c')]),_0x76ca5b['name']&&delete _0x76ca5b[_0xd22cf4('0x7')],_0x18ae64[_0xd22cf4('0xf')](_0x5a0b38)['send'](_0x76ca5b);};}exports[_0x28aba0('0x2d')]=function(_0x5d113f,_0x1f6c25){const _0x147e49=_0x28aba0;let _0x115cfe=[];if(typeof _0x5d113f['body'][_0x147e49('0x34')]==='undefined'&&typeof _0x5d113f['body']['TemplateId']==='undefined')throw new ValidationError(_0x147e49('0x21'));else{if(typeof _0x5d113f['body'][_0x147e49('0x22')]!=='undefined'&&typeof _0x5d113f['body']['view']==='undefined')throw new ValidationError(_0x147e49('0x30'));if(typeof _0x5d113f[_0x147e49('0x2c')][_0x147e49('0x1c')]===_0x147e49('0x31'))throw new ValidationError(_0x147e49('0x33'));else{try{_0x115cfe=JSON['parse'](_0x5d113f['body'][_0x147e49('0x1c')]);}catch(_0x17c237){logger[_0x147e49('0x15')](_0x17c237);throw new ValidationError(_0x147e49('0x29'));}const _0x1892ba=[_0x147e49('0x6'),_0x147e49('0x2'),_0x147e49('0x3'),_0x147e49('0xb'),_0x147e49('0x35'),_0x147e49('0x17'),_0x147e49('0x14'),_0x147e49('0x1e'),_0x147e49('0xa')];if(_[_0x147e49('0x1b')](_0x115cfe,function(_0x514b17){const _0x2c6061=_0x147e49;return!_[_0x2c6061('0x24')](_0x1892ba,_0x514b17['model']['toLowerCase']());}))throw new ValidationError(_0x147e49('0xc'));}}const _0xceed09={};return _0xceed09[_0x147e49('0x10')]=_0x5d113f[_0x147e49('0x2c')][_0x147e49('0x10')]?_0x5d113f[_0x147e49('0x2c')]['senderName']:_0x5d113f[_0x147e49('0xa')][_0x147e49('0xe')],_0xceed09[_0x147e49('0x16')]=_['isEmpty'](_0x5d113f[_0x147e49('0x2c')][_0x147e49('0x16')])?null:_0x5d113f[_0x147e49('0x2c')][_0x147e49('0x16')],_0xceed09[_0x147e49('0x1f')]=_0x5d113f[_0x147e49('0x2c')][_0x147e49('0x1f')]||![],_0xceed09['SenderId']=_0x5d113f[_0x147e49('0xa')]['id'],getContent(_0x5d113f['body'])[_0x147e49('0x38')](function(_0x5f16ce){const _0xc7f82b=_0x147e49;return _0xceed09[_0xc7f82b('0x2c')]=_0x5f16ce,getRecipients(_0x115cfe);})[_0x147e49('0x38')](function(_0x1df372){const _0x1a0ff8=_0x147e49;return _0xceed09[_0x1a0ff8('0xd')]=_[_0x1a0ff8('0x18')](_0x1df372)[_0x1a0ff8('0x26')](','),db[_0x1a0ff8('0x0')][_0x1a0ff8('0x36')](function(_0x40889f){const _0x19cc85=_0x1a0ff8;return db[_0x19cc85('0x2f')][_0x19cc85('0x3b')](_0xceed09,{'raw':!![],'transaction':_0x40889f})[_0x19cc85('0x38')](function(_0x3a4598){const _0x57d824=_0x19cc85,_0x5f0f71={'sender':_0xceed09[_0x57d824('0x10')],'description':_0xceed09[_0x57d824('0x16')],'content':_0xceed09[_0x57d824('0x2c')],'beep':_0xceed09[_0x57d824('0x1f')]};return _0x1df372[_0x57d824('0x3a')](function(_0x2805d6){const _0x4f2cbe=_0x57d824;_0x5f0f71[_0x4f2cbe('0x20')]=_0x2805d6,socket[_0x4f2cbe('0x11')](_0x4f2cbe('0x13'),_0x5f0f71);}),_0x3a4598;});});})[_0x147e49('0x38')](respondWithResult(_0x1f6c25,0xc9))[_0x147e49('0x5')](handleError(_0x1f6c25,null));};function getContent(_0x5eee6f){return new Promise(function(_0x9283fe,_0x3be914){const _0x158867=a461_0xe7f8;if(_0x5eee6f[_0x158867('0x34')]){_0x9283fe(_0x5eee6f[_0x158867('0x34')]);return;}return db[_0x158867('0x37')][_0x158867('0x39')]({'attributes':[_0x158867('0x27')],'where':{'id':_0x5eee6f[_0x158867('0x22')]},'raw':!![]})['then'](function(_0x9ca506){const _0x586046=_0x158867;if(!_0x9ca506)throw new ValidationError('Invalid\x20\x27TemplateId\x27\x20parameter');const _0x54bf67=Mustache['render'](_0x9ca506['html'],_0x5eee6f[_0x586046('0x9')]);_0x9283fe(_0x54bf67);})['catch'](function(_0x4fd3a1){_0x3be914(_0x4fd3a1);});});}function getRecipients(_0x307283){return new Promise(function(_0xe3f670,_0x5f3008){const _0x1cb402=a461_0xe7f8;let _0x41ca0d=[];const _0x2bd596=[];return _0x307283[_0x1cb402('0x3a')](function(_0xef2f1c){const _0x5555ce=_0x1cb402;let _0x5c482f=_[_0x5555ce('0x3d')](_0xef2f1c[_0x5555ce('0x19')]['toLowerCase']());if(_0x5c482f===_0x5555ce('0x2b'))_0x41ca0d=_[_0x5555ce('0x25')](_0x41ca0d,_0xef2f1c[_0x5555ce('0x3f')]);else{if(_[_0x5555ce('0x24')](_0x5c482f,'queue'))_0x5c482f=_0x5c482f['replace']('queue',_0x5555ce('0x2e'));_0xef2f1c[_0x5555ce('0x3f')]['forEach'](function(_0x15808d){const _0x13a568=_0x5555ce;_0x2bd596[_0x13a568('0x2a')](getAgents(_0x5c482f,_0x15808d));});}}),Promise[_0x1cb402('0x23')](_0x2bd596)['then'](function(_0x56e853){const _0xb29e66=_0x1cb402;_0x41ca0d=_['union'](_0x41ca0d,_[_0xb29e66('0x32')](_0x56e853)),_0xe3f670(_0x41ca0d);})[_0x1cb402('0x5')](function(_0x93489b){_0x5f3008(_0x93489b);});});}function getAgents(_0x1b7324,_0x1bb595){return new Promise(function(_0x352be5,_0x398865){const _0x442324=a461_0xe7f8;return db[_0x1b7324]['findOne']({'where':{'id':_0x1bb595}})['then'](function(_0x164b0d){const _0x213777=a461_0xe7f8;return _0x164b0d['getAgents']({'attributes':['id'],'raw':!![]})[_0x213777('0x38')](function(_0x59d3ac){const _0x53dffd=_0x213777,_0x5467a0=_[_0x53dffd('0x1a')](_0x59d3ac,'id');_0x352be5(_0x5467a0);});})[_0x442324('0x5')](function(_0x183ba5){_0x398865(_0x183ba5);});});} \ No newline at end of file diff --git a/server/api/notification/notification.events.js b/server/api/notification/notification.events.js index 8d4d5d8..b875535 100644 --- a/server/api/notification/notification.events.js +++ b/server/api/notification/notification.events.js @@ -1 +1 @@ -const a462_0x63f8=['emit','save','exports','addHook','../../mysqldb','update','undefined','Notification','remove'];(function(_0x3bf50b,_0x63f814){const _0x25129c=function(_0x1740d3){while(--_0x1740d3){_0x3bf50b['push'](_0x3bf50b['shift']());}};_0x25129c(++_0x63f814);}(a462_0x63f8,0x1d1));const a462_0x2512=function(_0x3bf50b,_0x63f814){_0x3bf50b=_0x3bf50b-0x0;let _0x25129c=a462_0x63f8[_0x3bf50b];return _0x25129c;};const _0x1b563e=a462_0x2512;'use strict';const EventEmitter=require('events'),Notification=require(_0x1b563e('0x7'))['db'][_0x1b563e('0x1')],NotificationEvents=new EventEmitter();NotificationEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x1b563e('0x4'),'afterUpdate':_0x1b563e('0x8'),'afterDestroy':_0x1b563e('0x2')};function emitEvent(_0x1740d3){return function(_0x1fbf8d){const _0x559bd9=a462_0x2512;NotificationEvents[_0x559bd9('0x3')](_0x1740d3+':'+_0x1fbf8d['id'],_0x1fbf8d),NotificationEvents[_0x559bd9('0x3')](_0x1740d3,_0x1fbf8d);};}for(const e in events){if(typeof events[e]!==_0x1b563e('0x0')){const event=events[e];Notification[_0x1b563e('0x6')](e,emitEvent(event));}}module[_0x1b563e('0x5')]=NotificationEvents; \ No newline at end of file +const a462_0x4f19=['events','save','addHook','../../mysqldb','update','setMaxListeners','undefined','emit','remove','exports'];(function(_0x1bfa7a,_0x4f19ba){const _0x2bce3d=function(_0x4d2e2b){while(--_0x4d2e2b){_0x1bfa7a['push'](_0x1bfa7a['shift']());}};_0x2bce3d(++_0x4f19ba);}(a462_0x4f19,0xbb));const a462_0x2bce=function(_0x1bfa7a,_0x4f19ba){_0x1bfa7a=_0x1bfa7a-0x0;let _0x2bce3d=a462_0x4f19[_0x1bfa7a];return _0x2bce3d;};const _0x3af7ea=a462_0x2bce;'use strict';const EventEmitter=require(_0x3af7ea('0x3')),Notification=require(_0x3af7ea('0x6'))['db']['Notification'],NotificationEvents=new EventEmitter();NotificationEvents[_0x3af7ea('0x8')](0x0);const events={'afterCreate':_0x3af7ea('0x4'),'afterUpdate':_0x3af7ea('0x7'),'afterDestroy':_0x3af7ea('0x1')};function emitEvent(_0x4d2e2b){return function(_0x1db5bb){const _0x536dbd=a462_0x2bce;NotificationEvents[_0x536dbd('0x0')](_0x4d2e2b+':'+_0x1db5bb['id'],_0x1db5bb),NotificationEvents[_0x536dbd('0x0')](_0x4d2e2b,_0x1db5bb);};}for(const e in events){if(typeof events[e]!==_0x3af7ea('0x9')){const event=events[e];Notification[_0x3af7ea('0x5')](e,emitEvent(event));}}module[_0x3af7ea('0x2')]=NotificationEvents; \ No newline at end of file diff --git a/server/api/notification/notification.model.js b/server/api/notification/notification.model.js index 06ed132..9a29606 100644 --- a/server/api/notification/notification.model.js +++ b/server/api/notification/notification.model.js @@ -1 +1 @@ -const a463_0x505b=['./notification.attributes','utf8mb4_unicode_ci','utf8mb4','notifications','exports','define','Notification'];(function(_0x9fe6fc,_0x505bdd){const _0xbb8ab8=function(_0x4625ae){while(--_0x4625ae){_0x9fe6fc['push'](_0x9fe6fc['shift']());}};_0xbb8ab8(++_0x505bdd);}(a463_0x505b,0x107));const a463_0xbb8a=function(_0x9fe6fc,_0x505bdd){_0x9fe6fc=_0x9fe6fc-0x0;let _0xbb8ab8=a463_0x505b[_0x9fe6fc];return _0xbb8ab8;};const _0x52029f=a463_0xbb8a;'use strict';const attributes=require(_0x52029f('0x3'));module[_0x52029f('0x0')]=function(_0x4625ae){const _0x5cbf41=_0x52029f,_0x4e947c=_0x4625ae[_0x5cbf41('0x1')](_0x5cbf41('0x2'),attributes,{'tableName':_0x5cbf41('0x6'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x5cbf41('0x5'),'collate':_0x5cbf41('0x4')});return _0x4e947c;}; \ No newline at end of file +const a463_0x2ac5=['utf8mb4','define','utf8mb4_unicode_ci','notifications','./notification.attributes'];(function(_0xf3418,_0x2ac58b){const _0x49d4d5=function(_0x245a5){while(--_0x245a5){_0xf3418['push'](_0xf3418['shift']());}};_0x49d4d5(++_0x2ac58b);}(a463_0x2ac5,0x1cc));const a463_0x49d4=function(_0xf3418,_0x2ac58b){_0xf3418=_0xf3418-0x0;let _0x49d4d5=a463_0x2ac5[_0xf3418];return _0x49d4d5;};const _0x39a08b=a463_0x49d4;'use strict';const attributes=require(_0x39a08b('0x4'));module['exports']=function(_0x245a5){const _0x282e4d=_0x39a08b,_0x3df8de=_0x245a5[_0x282e4d('0x1')]('Notification',attributes,{'tableName':_0x282e4d('0x3'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x282e4d('0x0'),'collate':_0x282e4d('0x2')});return _0x3df8de;}; \ No newline at end of file diff --git a/server/api/notification/notification.rpc.js b/server/api/notification/notification.rpc.js index 4d5ff37..dd1abd2 100644 --- a/server/api/notification/notification.rpc.js +++ b/server/api/notification/notification.rpc.js @@ -1 +1 @@ -const a464_0x2684=['./notification.socket','../../rediscache','register'];(function(_0x4f6ca6,_0x268485){const _0xfcb5e0=function(_0x3f9b4c){while(--_0x3f9b4c){_0x4f6ca6['push'](_0x4f6ca6['shift']());}};_0xfcb5e0(++_0x268485);}(a464_0x2684,0x65));const a464_0xfcb5=function(_0x4f6ca6,_0x268485){_0x4f6ca6=_0x4f6ca6-0x0;let _0xfcb5e0=a464_0x2684[_0x4f6ca6];return _0xfcb5e0;};const _0xb8ab25=a464_0xfcb5;'use strict';const {getSocket}=require(_0xb8ab25('0x2')),socket=getSocket();require(_0xb8ab25('0x1'))[_0xb8ab25('0x0')](socket); \ No newline at end of file +const a464_0x13c0=['./notification.socket'];(function(_0x2aa1c6,_0x13c034){const _0x193741=function(_0x591a27){while(--_0x591a27){_0x2aa1c6['push'](_0x2aa1c6['shift']());}};_0x193741(++_0x13c034);}(a464_0x13c0,0x1a9));const a464_0x1937=function(_0x2aa1c6,_0x13c034){_0x2aa1c6=_0x2aa1c6-0x0;let _0x193741=a464_0x13c0[_0x2aa1c6];return _0x193741;};const _0x3df769=a464_0x1937;'use strict';const {getSocket}=require('../../rediscache'),socket=getSocket();require(_0x3df769('0x0'))['register'](socket); \ No newline at end of file diff --git a/server/api/notification/notification.socket.js b/server/api/notification/notification.socket.js index c84c0bc..72e7dd5 100644 --- a/server/api/notification/notification.socket.js +++ b/server/api/notification/notification.socket.js @@ -1 +1 @@ -const a465_0x4f99=['./notification.events','update','length','register'];(function(_0x4dba3c,_0x4f998c){const _0x40ec91=function(_0x3ac081){while(--_0x3ac081){_0x4dba3c['push'](_0x4dba3c['shift']());}};_0x40ec91(++_0x4f998c);}(a465_0x4f99,0xa9));const a465_0x40ec=function(_0x4dba3c,_0x4f998c){_0x4dba3c=_0x4dba3c-0x0;let _0x40ec91=a465_0x4f99[_0x4dba3c];return _0x40ec91;};const _0x155b13=a465_0x40ec;'use strict';const NotificationEvents=require(_0x155b13('0x3')),events=['save','remove',_0x155b13('0x0')];function createListener(_0x3ac081,_0x322c11){return function(_0x810baf){_0x322c11['emit'](_0x3ac081,_0x810baf);};}exports[_0x155b13('0x2')]=function(_0x2e8b1c){const _0x3b3794=_0x155b13;for(let _0x5bc353=0x0,_0x42f3b8=events[_0x3b3794('0x1')];_0x5bc353<_0x42f3b8;_0x5bc353++){const _0x400426=events[_0x5bc353],_0x4b37bb=createListener('notification:'+_0x400426,_0x2e8b1c);NotificationEvents['on'](_0x400426,_0x4b37bb);}}; \ No newline at end of file +const a465_0x1f1b=['register','emit','remove','save'];(function(_0x42d2db,_0x1f1bc3){const _0x75c57e=function(_0x597039){while(--_0x597039){_0x42d2db['push'](_0x42d2db['shift']());}};_0x75c57e(++_0x1f1bc3);}(a465_0x1f1b,0x6b));const a465_0x75c5=function(_0x42d2db,_0x1f1bc3){_0x42d2db=_0x42d2db-0x0;let _0x75c57e=a465_0x1f1b[_0x42d2db];return _0x75c57e;};const _0x2d63d7=a465_0x75c5;'use strict';const NotificationEvents=require('./notification.events'),events=[_0x2d63d7('0x0'),_0x2d63d7('0x3'),'update'];function createListener(_0x597039,_0x1043c0){return function(_0x32a5e2){const _0x3c2e73=a465_0x75c5;_0x1043c0[_0x3c2e73('0x2')](_0x597039,_0x32a5e2);};}exports[_0x2d63d7('0x1')]=function(_0x53154a){for(let _0x48a549=0x0,_0x2a9bab=events['length'];_0x48a549<_0x2a9bab;_0x48a549++){const _0x18c8f2=events[_0x48a549],_0x1ae69d=createListener('notification:'+_0x18c8f2,_0x53154a);NotificationEvents['on'](_0x18c8f2,_0x1ae69d);}}; \ No newline at end of file diff --git a/server/api/openchannelAccount/index.js b/server/api/openchannelAccount/index.js index 4270a06..0d46b06 100644 --- a/server/api/openchannelAccount/index.js +++ b/server/api/openchannelAccount/index.js @@ -1 +1 @@ -const a466_0x4509=['send','express','getDispositions','put','/:id/dispositions','removeAnswers','/:id/interactions','/:id','notify','addAgents','describe','/:id/users','getAgents','getApplications','/describe','addDisposition','get','getInteractions','index','removeDispositions','show','isAuthenticated','/:id/canned_answers','destroy','delete','/:id/applications','post','removeAgents','/:id/notify','../../components/auth/service','getAnswers'];(function(_0x48571d,_0x45099d){const _0x2f6110=function(_0x176386){while(--_0x176386){_0x48571d['push'](_0x48571d['shift']());}};_0x2f6110(++_0x45099d);}(a466_0x4509,0x17d));const a466_0x2f61=function(_0x48571d,_0x45099d){_0x48571d=_0x48571d-0x0;let _0x2f6110=a466_0x4509[_0x48571d];return _0x2f6110;};const _0x3825e5=a466_0x2f61;'use strict';const express=require(_0x3825e5('0x17')),router=express['Router'](),auth=require(_0x3825e5('0x14')),controller=require('./openchannelAccount.controller');router[_0x3825e5('0x7')]('/',auth[_0x3825e5('0xc')](),controller[_0x3825e5('0x9')]),router[_0x3825e5('0x7')](_0x3825e5('0x5'),auth['isAuthenticated'](),controller[_0x3825e5('0x1')]),router[_0x3825e5('0x7')](_0x3825e5('0x1d'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0xb')]),router[_0x3825e5('0x7')](_0x3825e5('0x1a'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0x18')]),router[_0x3825e5('0x7')](_0x3825e5('0xd'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0x15')]),router['get'](_0x3825e5('0x10'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0x4')]),router[_0x3825e5('0x7')](_0x3825e5('0x1c'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0x8')]),router[_0x3825e5('0x7')](_0x3825e5('0x2'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0x3')]),router[_0x3825e5('0x11')]('/',auth[_0x3825e5('0xc')](),controller['create']),router['post'](_0x3825e5('0x1a'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0x6')]),router[_0x3825e5('0x11')](_0x3825e5('0xd'),auth['isAuthenticated'](),controller['addAnswer']),router['post'](_0x3825e5('0x13'),controller[_0x3825e5('0x1e')]),router['post'](_0x3825e5('0x10'),auth['isAuthenticated'](),controller['addApplications']),router[_0x3825e5('0x11')](_0x3825e5('0x2'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0x0')]),router[_0x3825e5('0x11')]('/:id/send',auth['isAuthenticated'](),controller[_0x3825e5('0x16')]),router[_0x3825e5('0x19')](_0x3825e5('0x1d'),auth['isAuthenticated'](),controller['update']),router[_0x3825e5('0xf')](_0x3825e5('0x1d'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0xe')]),router[_0x3825e5('0xf')](_0x3825e5('0x1a'),auth['isAuthenticated'](),controller[_0x3825e5('0xa')]),router[_0x3825e5('0xf')](_0x3825e5('0xd'),auth[_0x3825e5('0xc')](),controller[_0x3825e5('0x1b')]),router[_0x3825e5('0xf')]('/:id/users',auth['isAuthenticated'](),controller[_0x3825e5('0x12')]),module['exports']=router; \ No newline at end of file +const a466_0xeec3=['/:id/users','getApplications','getDispositions','addAnswer','/:id/notify','removeAgents','destroy','./openchannelAccount.controller','exports','getInteractions','removeDispositions','getAgents','/:id/dispositions','isAuthenticated','/describe','post','update','create','Router','describe','/:id/canned_answers','addAgents','/:id/interactions','delete','get','addDisposition','show','addApplications','put','/:id','/:id/applications','notify','express','getAnswers'];(function(_0x2a135d,_0xeec3eb){const _0x192a0a=function(_0x19f372){while(--_0x19f372){_0x2a135d['push'](_0x2a135d['shift']());}};_0x192a0a(++_0xeec3eb);}(a466_0xeec3,0x184));const a466_0x192a=function(_0x2a135d,_0xeec3eb){_0x2a135d=_0x2a135d-0x0;let _0x192a0a=a466_0xeec3[_0x2a135d];return _0x192a0a;};const _0x177810=a466_0x192a;'use strict';const express=require(_0x177810('0x12')),router=express[_0x177810('0x4')](),auth=require('../../components/auth/service'),controller=require(_0x177810('0x1b'));router[_0x177810('0xa')]('/',auth[_0x177810('0x21')](),controller['index']),router[_0x177810('0xa')](_0x177810('0x0'),auth[_0x177810('0x21')](),controller[_0x177810('0x5')]),router[_0x177810('0xa')](_0x177810('0xf'),auth[_0x177810('0x21')](),controller[_0x177810('0xc')]),router[_0x177810('0xa')]('/:id/dispositions',auth[_0x177810('0x21')](),controller[_0x177810('0x16')]),router['get'](_0x177810('0x6'),auth[_0x177810('0x21')](),controller[_0x177810('0x13')]),router['get'](_0x177810('0x10'),auth[_0x177810('0x21')](),controller[_0x177810('0x15')]),router['get'](_0x177810('0x8'),auth[_0x177810('0x21')](),controller[_0x177810('0x1d')]),router[_0x177810('0xa')](_0x177810('0x14'),auth[_0x177810('0x21')](),controller[_0x177810('0x1f')]),router['post']('/',auth['isAuthenticated'](),controller[_0x177810('0x3')]),router['post'](_0x177810('0x20'),auth[_0x177810('0x21')](),controller[_0x177810('0xb')]),router[_0x177810('0x1')](_0x177810('0x6'),auth['isAuthenticated'](),controller[_0x177810('0x17')]),router[_0x177810('0x1')](_0x177810('0x18'),controller[_0x177810('0x11')]),router[_0x177810('0x1')]('/:id/applications',auth[_0x177810('0x21')](),controller[_0x177810('0xd')]),router[_0x177810('0x1')](_0x177810('0x14'),auth[_0x177810('0x21')](),controller[_0x177810('0x7')]),router[_0x177810('0x1')]('/:id/send',auth['isAuthenticated'](),controller['send']),router[_0x177810('0xe')](_0x177810('0xf'),auth['isAuthenticated'](),controller[_0x177810('0x2')]),router[_0x177810('0x9')](_0x177810('0xf'),auth['isAuthenticated'](),controller[_0x177810('0x1a')]),router[_0x177810('0x9')]('/:id/dispositions',auth[_0x177810('0x21')](),controller[_0x177810('0x1e')]),router[_0x177810('0x9')]('/:id/canned_answers',auth[_0x177810('0x21')](),controller['removeAnswers']),router[_0x177810('0x9')](_0x177810('0x14'),auth[_0x177810('0x21')](),controller[_0x177810('0x19')]),module[_0x177810('0x1c')]=router; \ No newline at end of file diff --git a/server/api/openchannelAccount/openchannelAccount.attributes.js b/server/api/openchannelAccount/openchannelAccount.attributes.js index 7ce5cb2..2c20645 100644 --- a/server/api/openchannelAccount/openchannelAccount.attributes.js +++ b/server/api/openchannelAccount/openchannelAccount.attributes.js @@ -1 +1 @@ -const a467_0x462a=['exports','Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}','name','BOOLEAN','INTEGER','generate','STRING','mandatoryDisposition','sequelize','mandatoryDispositionPauseId','randomstring','setDataValue','TEXT'];(function(_0x3dad78,_0x462a97){const _0x310066=function(_0x42efd2){while(--_0x42efd2){_0x3dad78['push'](_0x3dad78['shift']());}};_0x310066(++_0x462a97);}(a467_0x462a,0x1e6));const a467_0x3100=function(_0x3dad78,_0x462a97){_0x3dad78=_0x3dad78-0x0;let _0x310066=a467_0x462a[_0x3dad78];return _0x310066;};const _0x5f5c4c=a467_0x3100;'use strict';const Sequelize=require(_0x5f5c4c('0x3')),rs=require(_0x5f5c4c('0x5'));module[_0x5f5c4c('0x8')]={'name':{'type':Sequelize[_0x5f5c4c('0x1')],'unique':_0x5f5c4c('0xa'),'allowNull':![]},'description':{'type':Sequelize['STRING']},'token':{'type':Sequelize[_0x5f5c4c('0x1')],'defaultValue':function(){const _0x6fca8b=_0x5f5c4c;return rs[_0x6fca8b('0x0')]();}},'replyUri':{'type':Sequelize[_0x5f5c4c('0x1')],'validate':{'isUrl':!![]}},'key':{'type':Sequelize[_0x5f5c4c('0x1')],'allowNull':![]},'notificationTemplate':{'type':Sequelize[_0x5f5c4c('0x7')],'defaultValue':function(){const _0x195581=_0x5f5c4c;return _0x195581('0x9');}},'notificationSound':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'notificationShake':{'type':Sequelize[_0x5f5c4c('0xb')],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x5f5c4c('0xc')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'mapKey':{'type':Sequelize[_0x5f5c4c('0x1')]},'queueTransfer':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x5f5c4c('0xc')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize[_0x5f5c4c('0xb')],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize['INTEGER'],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'mandatoryDispositionPauseId':{'type':Sequelize[_0x5f5c4c('0xc')],'allowNull':!![],'defaultValue':null,'comment':'Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled'},'mandatoryDisposition':{'type':Sequelize[_0x5f5c4c('0xb')],'defaultValue':![],'comment':'Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','set':function(_0x42efd2){const _0x24be0c=_0x5f5c4c;if(!_0x42efd2)this[_0x24be0c('0x6')](_0x24be0c('0x4'),null);this[_0x24be0c('0x6')](_0x24be0c('0x2'),_0x42efd2);}}}; \ No newline at end of file +const a467_0x113d=['setDataValue','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','STRING','randomstring','BOOLEAN','INTEGER','exports','mandatoryDisposition','Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}','generate'];(function(_0x3f085f,_0x113d61){const _0x1cb888=function(_0x3d93c7){while(--_0x3d93c7){_0x3f085f['push'](_0x3f085f['shift']());}};_0x1cb888(++_0x113d61);}(a467_0x113d,0x13b));const a467_0x1cb8=function(_0x3f085f,_0x113d61){_0x3f085f=_0x3f085f-0x0;let _0x1cb888=a467_0x113d[_0x3f085f];return _0x1cb888;};const _0x267619=a467_0x1cb8;'use strict';const Sequelize=require('sequelize'),rs=require(_0x267619('0x8'));module[_0x267619('0x0')]={'name':{'type':Sequelize[_0x267619('0x7')],'unique':'name','allowNull':![]},'description':{'type':Sequelize[_0x267619('0x7')]},'token':{'type':Sequelize[_0x267619('0x7')],'defaultValue':function(){const _0x4664d0=_0x267619;return rs[_0x4664d0('0x3')]();}},'replyUri':{'type':Sequelize['STRING'],'validate':{'isUrl':!![]}},'key':{'type':Sequelize[_0x267619('0x7')],'allowNull':![]},'notificationTemplate':{'type':Sequelize['TEXT'],'defaultValue':function(){const _0x22e9ee=_0x267619;return _0x22e9ee('0x2');}},'notificationSound':{'type':Sequelize[_0x267619('0x9')],'defaultValue':!![]},'notificationShake':{'type':Sequelize[_0x267619('0x9')],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x267619('0xa')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'mapKey':{'type':Sequelize[_0x267619('0x7')]},'queueTransfer':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x267619('0xa')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0x267619('0xa')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'mandatoryDispositionPauseId':{'type':Sequelize[_0x267619('0xa')],'allowNull':!![],'defaultValue':null,'comment':_0x267619('0x5')},'mandatoryDisposition':{'type':Sequelize[_0x267619('0x9')],'defaultValue':![],'comment':_0x267619('0x6'),'set':function(_0x3d93c7){const _0x3ab6a1=_0x267619;if(!_0x3d93c7)this[_0x3ab6a1('0x4')]('mandatoryDispositionPauseId',null);this[_0x3ab6a1('0x4')](_0x3ab6a1('0x1'),_0x3d93c7);}}}; \ No newline at end of file diff --git a/server/api/openchannelAccount/openchannelAccount.controller.js b/server/api/openchannelAccount/openchannelAccount.controller.js index b3d4422..842c6b9 100644 --- a/server/api/openchannelAccount/openchannelAccount.controller.js +++ b/server/api/openchannelAccount/openchannelAccount.controller.js @@ -1 +1 @@ -const a468_0xdd88=['emit','updatedAt','mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','addDisposition','code','OpenchannelAccount','role','isNil','no\x20available\x20attributes','sort','Disposition','removeAnswers','createdAt','nolimit','../../components/parsers/qs','undefined','notify','VIRTUAL','getApplications','ContactId','count','result','pick','error','keys','CmList','order','findAll','Applications','UserProfileSection','body','show','OpenchannelAccountId','api','OpenchannelAccount,\x20%s,\x20%s','../../mysqldb','findOne','OpenchannelMessage','http','rawAttributes','type','Contacts','lastName','transaction','then','rows','unmanaged','asc','message','dataValues','Start','isArray','fieldName','addAnswer','getDispositions','getAgents','UserProfileResource','model','User','options','difference','../../config/logger','where','catch','push','account','color','Owner','addApplications','offset','sendStatus','findAndCountAll','applications','describe','created','merge','threadId','name','CannedAnswer','include','jayson/promise','waitForTheAssignedAgent','ListId','filters','query','limit','*,*,*,*','startRouting','bulkCreate','from','sequelize','status','omit','user','get','map','CmContact','params','like','fields','EventManager','removeDispositions','attributes','length','defaults','userOpenchannelAccount:remove','json','request\x20sent','removeAgents','debug','messageId','userOpenchannelAccount:save','destroy','Messages','Content-Range','from\x20is\x20mandatory','client','mandatoryDispositionPause','request','update','unshift','includes','getInteractions','stack','./openchannelAccount.socket','filter','ids','addAgents','Pause','body\x20is\x20mandatory\x20and\x20not\x20empty','tag','contact','interaction','send','intersection','OpenchannelApplication','UserId','priority','autoclose','OpenchannelInteraction','includeAll','firstName','mapKey','getAnswers','externalUrl','List','register','create','OpenchannelAccounts','Contact','key','AttachmentId','end','info','orderBy'];(function(_0x45f6a2,_0xdd880e){const _0x40406d=function(_0x279889){while(--_0x279889){_0x45f6a2['push'](_0x45f6a2['shift']());}};_0x40406d(++_0xdd880e);}(a468_0xdd88,0x165));const a468_0x4040=function(_0x45f6a2,_0xdd880e){_0x45f6a2=_0x45f6a2-0x0;let _0x40406d=a468_0xdd88[_0x45f6a2];return _0x40406d;};const _0x4dcd09=a468_0x4040;'use strict';const _=require('lodash'),qs=require(_0x4dcd09('0x7a')),logger=require(_0x4dcd09('0xe'))(_0x4dcd09('0x8d')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x4dcd09('0x8f'))['db'],{Op,ValidationError}=require(_0x4dcd09('0x2b'));require(_0x4dcd09('0x4d'))[_0x4dcd09('0x63')](socket);const jayson=require(_0x4dcd09('0x21')),client=jayson[_0x4dcd09('0x45')][_0x4dcd09('0x92')]({'port':0x232c}),client9002=jayson[_0x4dcd09('0x45')][_0x4dcd09('0x92')]({'port':0x232a});function respondWithRpcPromise(_0x279889,_0x332e68,_0x45ab09,_0x4566b1){return new Promise(function(_0x67f8a,_0x501df4){const _0x1c042c=a468_0x4040,_0x410c46=_0x4566b1||client;return _0x410c46[_0x1c042c('0x47')](_0x279889,_0x45ab09)[_0x1c042c('0x98')](function(_0x4342e3){const _0x5977fe=_0x1c042c;logger[_0x5977fe('0x6a')](_0x5977fe('0x8e'),_0x332e68,_0x5977fe('0x3c')),logger[_0x5977fe('0x3e')]('OpenchannelAccount,\x20%s,\x20%s,\x20%s',_0x332e68,_0x5977fe('0x3c'),JSON['stringify'](_0x4342e3));if(_0x4342e3['error']){if(_0x4342e3[_0x5977fe('0x83')][_0x5977fe('0x70')]===0x1f4)return logger[_0x5977fe('0x83')]('OpenchannelAccount,\x20%s,\x20%s',_0x332e68,_0x4342e3['error'][_0x5977fe('0x1')]),_0x501df4(_0x4342e3[_0x5977fe('0x83')][_0x5977fe('0x1')]);return logger[_0x5977fe('0x83')]('OpenchannelAccount,\x20%s,\x20%s',_0x332e68,_0x4342e3[_0x5977fe('0x83')][_0x5977fe('0x1')]),_0x67f8a(_0x4342e3[_0x5977fe('0x83')][_0x5977fe('0x1')]);}else logger[_0x5977fe('0x6a')](_0x5977fe('0x8e'),_0x332e68,_0x5977fe('0x3c')),_0x67f8a(_0x4342e3[_0x5977fe('0x81')][_0x5977fe('0x1')]);})['catch'](function(_0x156ad5){const _0x131d2b=_0x1c042c;logger[_0x131d2b('0x83')](_0x131d2b('0x8e'),_0x332e68,_0x156ad5),_0x501df4(_0x156ad5);});});}function respondWithStatusCode(_0x143877,_0x4b4cc1){return _0x4b4cc1=_0x4b4cc1||0xcc,function(_0x5cd3ab){const _0x3808a4=a468_0x4040;if(_0x5cd3ab)return _0x143877['sendStatus'](_0x4b4cc1);return _0x143877[_0x3808a4('0x2c')](_0x4b4cc1)[_0x3808a4('0x69')]();};}function respondWithResult(_0x29adb6,_0x1a6230){return _0x1a6230=_0x1a6230||0xc8,function(_0x2e498c){if(_0x2e498c)return _0x29adb6['status'](_0x1a6230)['json'](_0x2e498c);};}function respondWithFilteredResult(_0x571fd9,_0x18c4b3){return function(_0x38e738){const _0x1a1d8b=a468_0x4040;if(_0x38e738){const _0x1ffa8b=_0x38e738[_0x1a1d8b('0x80')],_0x45ccae=_0x18c4b3[_0x1a1d8b('0x16')];let _0x3798c8=_0x18c4b3['offset']+_0x18c4b3[_0x1a1d8b('0x26')],_0x56faa8;return _0x3798c8>=_0x1ffa8b?(_0x3798c8=_0x1ffa8b,_0x56faa8=0xc8):_0x56faa8=0xce,_0x571fd9[_0x1a1d8b('0x2c')](_0x56faa8),_0x571fd9['set'](_0x1a1d8b('0x43'),_0x45ccae+'-'+_0x3798c8+'/'+_0x1ffa8b)[_0x1a1d8b('0x3b')](_0x38e738);}return null;};}function saveUpdates(_0x329a14){return function(_0x41d1b9){const _0x44e7e8=a468_0x4040;if(_0x41d1b9)return _0x41d1b9[_0x44e7e8('0x48')](_0x329a14)[_0x44e7e8('0x98')](function(_0x215473){return _0x215473;});return null;};}function removeEntity(_0x5d1f95){return function(_0x313aa7){const _0x27feb3=a468_0x4040;if(_0x313aa7)return _0x313aa7['destroy']()[_0x27feb3('0x98')](function(){const _0x235619=_0x27feb3,_0x190390=_0x313aa7[_0x235619('0x2f')]({'plain':!![]}),_0x4722e4=_0x235619('0x65');return db[_0x235619('0x9')][_0x235619('0x41')]({'where':{'type':_0x4722e4,'resourceId':_0x190390['id']}})[_0x235619('0x98')](function(){return _0x313aa7;});})[_0x27feb3('0x98')](function(){const _0x547f13=_0x27feb3;_0x5d1f95[_0x547f13('0x2c')](0xcc)[_0x547f13('0x69')]();});};}function handleEntityNotFound(_0x46c5d9){return function(_0x583d42){const _0x305ebf=a468_0x4040;return!_0x583d42&&_0x46c5d9[_0x305ebf('0x17')](0x194),_0x583d42;};}function handleError(_0x7b2f16,_0xc9ca69){return _0xc9ca69=_0xc9ca69||0x1f4,function(_0x35e87b){const _0x560c33=a468_0x4040;logger['error'](_0x35e87b[_0x560c33('0x4c')]),_0x35e87b[_0x560c33('0x1e')]&&delete _0x35e87b[_0x560c33('0x1e')],_0x7b2f16[_0x560c33('0x2c')](_0xc9ca69)[_0x560c33('0x56')](_0x35e87b);};}exports['index']=function(_0x314384,_0x565b3f){const _0xbaf7a3=_0x4dcd09;let _0x2f965a={'include':[{'model':db['Pause'],'as':_0xbaf7a3('0x46')}]};const _0x4f5d05={},_0x31b17d={'count':0x0,'rows':[]},_0x4ed4b5=_['map'](db[_0xbaf7a3('0x71')][_0xbaf7a3('0x93')],function(_0x2f9e04){const _0x16fef5=_0xbaf7a3;return{'name':_0x2f9e04[_0x16fef5('0x5')],'type':_0x2f9e04[_0x16fef5('0x94')][_0x16fef5('0x67')]};});_0x4f5d05[_0xbaf7a3('0xa')]=_[_0xbaf7a3('0x30')](_0x4ed4b5,_0xbaf7a3('0x1e')),_0x4f5d05[_0xbaf7a3('0x25')]=_[_0xbaf7a3('0x84')](_0x314384[_0xbaf7a3('0x25')]),_0x4f5d05[_0xbaf7a3('0x24')]=_[_0xbaf7a3('0x57')](_0x4f5d05[_0xbaf7a3('0xa')],_0x4f5d05[_0xbaf7a3('0x25')]),_0x2f965a[_0xbaf7a3('0x37')]=_['intersection'](_0x4f5d05[_0xbaf7a3('0xa')],qs[_0xbaf7a3('0x34')](_0x314384['query'][_0xbaf7a3('0x34')])),_0x2f965a['attributes']=_0x2f965a[_0xbaf7a3('0x37')][_0xbaf7a3('0x38')]?_0x2f965a[_0xbaf7a3('0x37')]:_0x4f5d05['model'];typeof _0x314384[_0xbaf7a3('0x25')][_0xbaf7a3('0x79')]===_0xbaf7a3('0x7b')&&(_0x2f965a[_0xbaf7a3('0x26')]=qs[_0xbaf7a3('0x26')](_0x314384['query'][_0xbaf7a3('0x26')]),_0x2f965a['offset']=qs[_0xbaf7a3('0x16')](_0x314384[_0xbaf7a3('0x25')][_0xbaf7a3('0x16')]));_0x2f965a[_0xbaf7a3('0x86')]=qs[_0xbaf7a3('0x75')](_0x314384['query'][_0xbaf7a3('0x75')]),_0x2f965a['where']=qs[_0xbaf7a3('0x24')](_[_0xbaf7a3('0x82')](_0x314384[_0xbaf7a3('0x25')],_0x4f5d05[_0xbaf7a3('0x24')]),_0x4ed4b5);_0x314384[_0xbaf7a3('0x25')]['filter']&&(_0x2f965a[_0xbaf7a3('0xf')]=_[_0xbaf7a3('0x1c')](_0x2f965a[_0xbaf7a3('0xf')],{[Op['or']]:_['map'](_0x4ed4b5,function(_0x304e04){const _0x546bf5=_0xbaf7a3;if(_0x304e04[_0x546bf5('0x94')]!==_0x546bf5('0x7d')){const _0x1074b4={};return _0x1074b4[_0x304e04[_0x546bf5('0x1e')]]={[Op[_0x546bf5('0x33')]]:'%'+_0x314384['query'][_0x546bf5('0x4e')]+'%'},_0x1074b4;}})}));_0x2f965a=_['merge']({},_0x2f965a,_0x314384[_0xbaf7a3('0xc')]);const _0xcb9fc6={'where':_0x2f965a[_0xbaf7a3('0xf')]};return db[_0xbaf7a3('0x71')]['count'](_0xcb9fc6)['then'](function(_0x4f7dd0){const _0x2fafc5=_0xbaf7a3;return _0x31b17d[_0x2fafc5('0x80')]=_0x4f7dd0,_0x314384[_0x2fafc5('0x25')][_0x2fafc5('0x5d')]&&(_0x2f965a[_0x2fafc5('0x20')]=[{'all':!![]}]),db[_0x2fafc5('0x71')][_0x2fafc5('0x87')](_0x2f965a);})[_0xbaf7a3('0x98')](function(_0x66426e){return _0x31b17d['rows']=_0x66426e,_0x31b17d;})[_0xbaf7a3('0x98')](respondWithFilteredResult(_0x565b3f,_0x2f965a))['catch'](handleError(_0x565b3f,null));},exports[_0x4dcd09('0x8b')]=function(_0x5b7076,_0x366694){const _0x55cbed=_0x4dcd09;let _0x4e2f95={'raw':![],'where':{'id':_0x5b7076[_0x55cbed('0x32')]['id']},'include':[{'model':db[_0x55cbed('0x51')],'as':_0x55cbed('0x46')}]};const _0x3154e9={};return _0x3154e9[_0x55cbed('0xa')]=_[_0x55cbed('0x84')](db[_0x55cbed('0x71')][_0x55cbed('0x93')]),_0x3154e9[_0x55cbed('0x25')]=_[_0x55cbed('0x84')](_0x5b7076['query']),_0x3154e9[_0x55cbed('0x24')]=_[_0x55cbed('0x57')](_0x3154e9['model'],_0x3154e9[_0x55cbed('0x25')]),_0x4e2f95[_0x55cbed('0x37')]=_[_0x55cbed('0x57')](_0x3154e9['model'],qs[_0x55cbed('0x34')](_0x5b7076[_0x55cbed('0x25')][_0x55cbed('0x34')])),_0x4e2f95['attributes']=_0x4e2f95[_0x55cbed('0x37')][_0x55cbed('0x38')]?_0x4e2f95[_0x55cbed('0x37')]:_0x3154e9['model'],_0x5b7076['query'][_0x55cbed('0x5d')]&&(_0x4e2f95[_0x55cbed('0x20')]=[{'all':!![]}]),_0x4e2f95=_[_0x55cbed('0x1c')]({},_0x4e2f95,_0x5b7076[_0x55cbed('0xc')]),db[_0x55cbed('0x71')]['findOne'](_0x4e2f95)['then'](handleEntityNotFound(_0x366694,null))['then'](respondWithResult(_0x366694,null))[_0x55cbed('0x10')](handleError(_0x366694,null));},exports['create']=function(_0x1694cc,_0x5f2684){const _0x50530c=_0x4dcd09;return db[_0x50530c('0x71')][_0x50530c('0x64')](_0x1694cc[_0x50530c('0x8a')],{})[_0x50530c('0x98')](function(_0x59e653){const _0x5a58a4=_0x50530c,_0x3e94d9=_0x1694cc[_0x5a58a4('0x2e')][_0x5a58a4('0x2f')]({'plain':!![]});if(!_0x3e94d9)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x3e94d9[_0x5a58a4('0x72')]===_0x5a58a4('0x2e')){const _0x1de1f3=_0x59e653[_0x5a58a4('0x2f')]({'plain':!![]}),_0x702ff6='OpenchannelAccounts';return db[_0x5a58a4('0x89')][_0x5a58a4('0x90')]({'where':{'name':_0x702ff6,'userProfileId':_0x3e94d9['userProfileId']},'raw':!![]})[_0x5a58a4('0x98')](function(_0x5a1590){const _0x5cf29a=_0x5a58a4;return _0x5a1590&&_0x5a1590['autoAssociation']===0x0?db['UserProfileResource'][_0x5cf29a('0x64')]({'name':_0x1de1f3[_0x5cf29a('0x1e')],'resourceId':_0x1de1f3['id'],'type':_0x5a1590['name'],'sectionId':_0x5a1590['id']},{})[_0x5cf29a('0x98')](function(){return _0x59e653;}):_0x59e653;})[_0x5a58a4('0x10')](function(_0x126447){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x126447);throw _0x126447;});}return _0x59e653;})[_0x50530c('0x98')](respondWithResult(_0x5f2684,0xc9))[_0x50530c('0x10')](handleError(_0x5f2684,null));},exports[_0x4dcd09('0x48')]=function(_0x4b501c,_0x4b57ac){const _0x205373=_0x4dcd09;return _0x4b501c[_0x205373('0x8a')]['id']&&delete _0x4b501c['body']['id'],db[_0x205373('0x71')][_0x205373('0x90')]({'where':{'id':_0x4b501c[_0x205373('0x32')]['id']},'include':[{'model':db[_0x205373('0x51')],'as':_0x205373('0x46')}]})[_0x205373('0x98')](handleEntityNotFound(_0x4b57ac,null))[_0x205373('0x98')](saveUpdates(_0x4b501c[_0x205373('0x8a')],null))[_0x205373('0x98')](respondWithResult(_0x4b57ac,null))[_0x205373('0x10')](handleError(_0x4b57ac,null));},exports['destroy']=function(_0x5a4716,_0x1d317d){const _0x245e9e=_0x4dcd09;return db[_0x245e9e('0x71')][_0x245e9e('0x90')]({'where':{'id':_0x5a4716[_0x245e9e('0x32')]['id']}})[_0x245e9e('0x98')](handleEntityNotFound(_0x1d317d,null))['then'](removeEntity(_0x1d317d,null))[_0x245e9e('0x10')](handleError(_0x1d317d,null));},exports[_0x4dcd09('0x1a')]=function(_0x5e162c,_0x40aa01){const _0x61e16d=_0x4dcd09;return db[_0x61e16d('0x71')][_0x61e16d('0x1a')]()[_0x61e16d('0x98')](respondWithResult(_0x40aa01,null))[_0x61e16d('0x10')](handleError(_0x40aa01,null));},exports[_0x4dcd09('0x6f')]=function(_0x2bbd50,_0x5d08d7){const _0xb37a84=_0x4dcd09;return _0x2bbd50[_0xb37a84('0x8a')]['id']&&delete _0x2bbd50[_0xb37a84('0x8a')]['id'],db['OpenchannelAccount'][_0xb37a84('0x90')]({'where':{'id':_0x2bbd50['params']['id']}})[_0xb37a84('0x98')](handleEntityNotFound(_0x5d08d7,null))[_0xb37a84('0x98')](function(_0x10dfcf){const _0x5367e0=_0xb37a84;if(_0x10dfcf)return _0x2bbd50['body']['OpenchannelAccountId']=_0x10dfcf['id'],db[_0x5367e0('0x76')][_0x5367e0('0x64')](_0x2bbd50['body']);})[_0xb37a84('0x98')](respondWithResult(_0x5d08d7,null))['catch'](handleError(_0x5d08d7,null));},exports[_0x4dcd09('0x7')]=function(_0x4c24b1,_0x3f2a04){const _0xa78e4a=_0x4dcd09;let _0x4c987c={'raw':![],'where':{}};const _0x5a10e5={},_0x4df3b9={'count':0x0,'rows':[]};return db['OpenchannelAccount'][_0xa78e4a('0x90')]({'where':{'id':_0x4c24b1[_0xa78e4a('0x32')]['id']}})['then'](handleEntityNotFound(_0x3f2a04,null))[_0xa78e4a('0x98')](function(_0x17562a){const _0x4229a2=_0xa78e4a;if(_0x17562a)return _0x5a10e5[_0x4229a2('0xa')]=_[_0x4229a2('0x84')](db[_0x4229a2('0x76')]['rawAttributes']),_0x5a10e5[_0x4229a2('0x25')]=_[_0x4229a2('0x84')](_0x4c24b1[_0x4229a2('0x25')]),_0x5a10e5[_0x4229a2('0x24')]=_[_0x4229a2('0x57')](_0x5a10e5[_0x4229a2('0xa')],_0x5a10e5[_0x4229a2('0x25')]),_0x4c987c['attributes']=_[_0x4229a2('0x57')](_0x5a10e5[_0x4229a2('0xa')],qs[_0x4229a2('0x34')](_0x4c24b1[_0x4229a2('0x25')][_0x4229a2('0x34')])),_0x4c987c[_0x4229a2('0x37')]=_0x4c987c[_0x4229a2('0x37')][_0x4229a2('0x38')]?_0x4c987c[_0x4229a2('0x37')]:_0x5a10e5[_0x4229a2('0xa')],typeof _0x4c24b1[_0x4229a2('0x25')]['nolimit']==='undefined'&&(_0x4c987c[_0x4229a2('0x26')]=qs[_0x4229a2('0x26')](_0x4c24b1[_0x4229a2('0x25')][_0x4229a2('0x26')]),_0x4c987c[_0x4229a2('0x16')]=qs[_0x4229a2('0x16')](_0x4c24b1[_0x4229a2('0x25')][_0x4229a2('0x16')])),_0x4c987c[_0x4229a2('0x86')]=qs['sort'](_0x4c24b1[_0x4229a2('0x25')][_0x4229a2('0x75')]),_0x4c987c[_0x4229a2('0xf')]=qs[_0x4229a2('0x24')](_[_0x4229a2('0x82')](_0x4c24b1['query'],_0x5a10e5['filters'])),_0x4c987c[_0x4229a2('0xf')][_0x4229a2('0x8c')]=_0x17562a['id'],_0x4c24b1[_0x4229a2('0x25')]['filter']&&(_0x4c987c[_0x4229a2('0xf')]=_[_0x4229a2('0x1c')](_0x4c987c[_0x4229a2('0xf')],{[Op['or']]:_['map'](_0x4c987c[_0x4229a2('0x37')],function(_0x9129d6){const _0x387c46=_0x4229a2,_0x42d958={};return _0x42d958[_0x9129d6]={[Op[_0x387c46('0x33')]]:'%'+_0x4c24b1[_0x387c46('0x25')][_0x387c46('0x4e')]+'%'},_0x42d958;})})),_0x4c987c=_[_0x4229a2('0x1c')]({},_0x4c987c,_0x4c24b1[_0x4229a2('0xc')]),db[_0x4229a2('0x76')][_0x4229a2('0x80')]({'where':_0x4c987c[_0x4229a2('0xf')]})[_0x4229a2('0x98')](function(_0xe3323c){const _0x37c56e=_0x4229a2;return _0x4df3b9['count']=_0xe3323c,_0x4c24b1[_0x37c56e('0x25')][_0x37c56e('0x5d')]&&(_0x4c987c[_0x37c56e('0x20')]=[{'all':!![]}]),db[_0x37c56e('0x76')][_0x37c56e('0x87')](_0x4c987c);})[_0x4229a2('0x98')](function(_0x4c1571){const _0x56e83e=_0x4229a2;return _0x4df3b9[_0x56e83e('0x99')]=_0x4c1571,_0x4df3b9;});})['then'](respondWithFilteredResult(_0x3f2a04,_0x4c987c))[_0xa78e4a('0x10')](handleError(_0x3f2a04,null));},exports[_0x4dcd09('0x36')]=function(_0x3147a7,_0x1fd4a2){const _0x18c986=_0x4dcd09;return db[_0x18c986('0x71')][_0x18c986('0x90')]({'where':{'id':_0x3147a7['params']['id']}})[_0x18c986('0x98')](handleEntityNotFound(_0x1fd4a2,null))['then'](function(_0x33c226){const _0x3a9bbd=_0x18c986;if(_0x33c226)return _0x33c226[_0x3a9bbd('0x36')](_0x3147a7[_0x3a9bbd('0x25')][_0x3a9bbd('0x4f')]);})[_0x18c986('0x98')](respondWithStatusCode(_0x1fd4a2,null))['catch'](handleError(_0x1fd4a2,null));},exports[_0x4dcd09('0x6')]=function(_0x483547,_0x2c1066){const _0x3c512d=_0x4dcd09;return _0x483547[_0x3c512d('0x8a')]['id']&&delete _0x483547[_0x3c512d('0x8a')]['id'],db[_0x3c512d('0x71')]['findOne']({'where':{'id':_0x483547[_0x3c512d('0x32')]['id']}})[_0x3c512d('0x98')](handleEntityNotFound(_0x2c1066,null))['then'](function(_0x25ffa7){const _0x470a1f=_0x3c512d;if(_0x25ffa7)return _0x483547[_0x470a1f('0x8a')][_0x470a1f('0x8c')]=_0x25ffa7['id'],db[_0x470a1f('0x1f')][_0x470a1f('0x64')](_0x483547['body']);})['then'](respondWithResult(_0x2c1066,null))[_0x3c512d('0x10')](handleError(_0x2c1066,null));},exports[_0x4dcd09('0x60')]=function(_0x3bf6b3,_0x4ac0df){const _0x55e12a=_0x4dcd09;let _0x2a8e92={'raw':![],'where':{}};const _0x372993={},_0xbc594a={'count':0x0,'rows':[]};return db[_0x55e12a('0x71')][_0x55e12a('0x90')]({'where':{'id':_0x3bf6b3[_0x55e12a('0x32')]['id']}})[_0x55e12a('0x98')](handleEntityNotFound(_0x4ac0df,null))[_0x55e12a('0x98')](function(_0xfd8c4e){const _0x2feed8=_0x55e12a;if(_0xfd8c4e)return _0x372993[_0x2feed8('0xa')]=_[_0x2feed8('0x84')](db[_0x2feed8('0x1f')]['rawAttributes']),_0x372993[_0x2feed8('0x25')]=_['keys'](_0x3bf6b3[_0x2feed8('0x25')]),_0x372993[_0x2feed8('0x24')]=_[_0x2feed8('0x57')](_0x372993['model'],_0x372993[_0x2feed8('0x25')]),_0x2a8e92['attributes']=_[_0x2feed8('0x57')](_0x372993[_0x2feed8('0xa')],qs[_0x2feed8('0x34')](_0x3bf6b3['query'][_0x2feed8('0x34')])),_0x2a8e92[_0x2feed8('0x37')]=_0x2a8e92[_0x2feed8('0x37')][_0x2feed8('0x38')]?_0x2a8e92[_0x2feed8('0x37')]:_0x372993[_0x2feed8('0xa')],typeof _0x3bf6b3[_0x2feed8('0x25')]['nolimit']===_0x2feed8('0x7b')&&(_0x2a8e92[_0x2feed8('0x26')]=qs[_0x2feed8('0x26')](_0x3bf6b3[_0x2feed8('0x25')]['limit']),_0x2a8e92['offset']=qs['offset'](_0x3bf6b3[_0x2feed8('0x25')][_0x2feed8('0x16')])),_0x2a8e92[_0x2feed8('0x86')]=qs['sort'](_0x3bf6b3[_0x2feed8('0x25')][_0x2feed8('0x75')]),_0x2a8e92[_0x2feed8('0xf')]=qs[_0x2feed8('0x24')](_['pick'](_0x3bf6b3[_0x2feed8('0x25')],_0x372993[_0x2feed8('0x24')])),_0x2a8e92['where'][_0x2feed8('0x8c')]=_0xfd8c4e['id'],_0x3bf6b3[_0x2feed8('0x25')][_0x2feed8('0x4e')]&&(_0x2a8e92[_0x2feed8('0xf')]=_[_0x2feed8('0x1c')](_0x2a8e92[_0x2feed8('0xf')],{[Op['or']]:_[_0x2feed8('0x30')](_0x2a8e92['attributes'],function(_0x5f2d60){const _0x13dbf0=_0x2feed8,_0xb1a193={};return _0xb1a193[_0x5f2d60]={[Op[_0x13dbf0('0x33')]]:'%'+_0x3bf6b3['query']['filter']+'%'},_0xb1a193;})})),_0x2a8e92=_[_0x2feed8('0x1c')]({},_0x2a8e92,_0x3bf6b3[_0x2feed8('0xc')]),db[_0x2feed8('0x1f')][_0x2feed8('0x80')]({'where':_0x2a8e92[_0x2feed8('0xf')]})[_0x2feed8('0x98')](function(_0x526df4){const _0x3ad475=_0x2feed8;return _0xbc594a['count']=_0x526df4,_0x3bf6b3[_0x3ad475('0x25')][_0x3ad475('0x5d')]&&(_0x2a8e92['include']=[{'all':!![]}]),db[_0x3ad475('0x1f')][_0x3ad475('0x87')](_0x2a8e92);})[_0x2feed8('0x98')](function(_0x2a9810){const _0x11c3d7=_0x2feed8;return _0xbc594a[_0x11c3d7('0x99')]=_0x2a9810,_0xbc594a;});})[_0x55e12a('0x98')](respondWithFilteredResult(_0x4ac0df,_0x2a8e92))[_0x55e12a('0x10')](handleError(_0x4ac0df,null));},exports['removeAnswers']=function(_0x72a5a2,_0x2791ed){const _0x23683f=_0x4dcd09;return db[_0x23683f('0x71')][_0x23683f('0x90')]({'where':{'id':_0x72a5a2[_0x23683f('0x32')]['id']}})[_0x23683f('0x98')](handleEntityNotFound(_0x2791ed,null))[_0x23683f('0x98')](function(_0xa9e8eb){const _0x48f774=_0x23683f;if(_0xa9e8eb)return _0xa9e8eb[_0x48f774('0x77')](_0x72a5a2[_0x48f774('0x25')][_0x48f774('0x4f')]);})[_0x23683f('0x98')](respondWithStatusCode(_0x2791ed,null))[_0x23683f('0x10')](handleError(_0x2791ed,null));},exports[_0x4dcd09('0x7c')]=function(_0x576a73,_0x3dd210){const _0x398d2f=_0x4dcd09,_0x2ebce8={'body':_0x576a73[_0x398d2f('0x8a')],'channel':'openchannel'};let _0x2a6739=[],_0x218175=[];const _0x386f0e={};let _0x49be7c=![];return db[_0x398d2f('0x31')][_0x398d2f('0x1a')]()[_0x398d2f('0x98')](function(_0x56f8c1){const _0x1ee0ed=_0x398d2f;if(!_0x56f8c1)throw new ValidationError(_0x1ee0ed('0x74'));_0x2a6739=_[_0x1ee0ed('0xd')](_[_0x1ee0ed('0x84')](_0x56f8c1),[_0x1ee0ed('0x78'),_0x1ee0ed('0x6d')]),_0x218175=_['difference'](_[_0x1ee0ed('0x84')](_0x56f8c1),[_0x1ee0ed('0x78'),_0x1ee0ed('0x6d'),'CompanyId',_0x1ee0ed('0x23')]);_0x576a73[_0x1ee0ed('0x8a')]['id']&&delete _0x576a73[_0x1ee0ed('0x8a')]['id'];if(_[_0x1ee0ed('0x73')](_0x576a73['body']['from']))throw new ValidationError(_0x1ee0ed('0x44'));if(_[_0x1ee0ed('0x73')](_0x576a73['body'][_0x1ee0ed('0x8a')])||_0x576a73[_0x1ee0ed('0x8a')][_0x1ee0ed('0x8a')]==='')throw new ValidationError(_0x1ee0ed('0x52'));if(_[_0x1ee0ed('0x73')](_0x576a73[_0x1ee0ed('0x8a')][_0x1ee0ed('0x5f')]))throw new ValidationError('mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20'+_0x218175);if(!_[_0x1ee0ed('0x4a')](_0x218175,_0x576a73['body'][_0x1ee0ed('0x5f')]))throw new ValidationError(_0x1ee0ed('0x6e')+_0x218175);_0x386f0e[_0x576a73[_0x1ee0ed('0x8a')][_0x1ee0ed('0x5f')]]=_0x576a73['body']['from'];})[_0x398d2f('0x98')](function(){const _0x271622=_0x398d2f;return db[_0x271622('0x71')][_0x271622('0x90')]({'where':{'id':_0x576a73['params']['id']},'include':[{'model':db[_0x271622('0x85')],'as':_0x271622('0x62'),'include':[{'model':db[_0x271622('0x31')],'as':_0x271622('0x95'),'where':_0x386f0e,'limit':0x1,'order':[['updatedAt','DESC']]}]},{'model':db[_0x271622('0x58')],'as':_0x271622('0x88')}]});})[_0x398d2f('0x98')](handleEntityNotFound(_0x3dd210,null))['then'](function(_0x3c0596){const _0x2bcf0e=_0x398d2f;if(_0x3c0596&&_0x3c0596[_0x2bcf0e('0x62')]){_0x2ebce8['account']=_0x3c0596,_0x2ebce8[_0x2bcf0e('0x19')]=_0x3c0596['Applications'],_0x2ebce8['list']=_0x3c0596[_0x2bcf0e('0x62')],_0x2ebce8[_0x2bcf0e('0x19')]=_[_0x2bcf0e('0x6b')](_0x2ebce8[_0x2bcf0e('0x19')],[_0x2bcf0e('0x5a')],[_0x2bcf0e('0x0')]);_0x2ebce8[_0x2bcf0e('0x12')][_0x2bcf0e('0x88')]&&delete _0x2ebce8[_0x2bcf0e('0x12')][_0x2bcf0e('0x88')];if(_0x2ebce8[_0x2bcf0e('0x12')]['List']&&_0x2ebce8[_0x2bcf0e('0x12')]['List'][_0x2bcf0e('0x95')][_0x2bcf0e('0x38')])return _0x2ebce8[_0x2bcf0e('0x12')]['List'][_0x2bcf0e('0x95')][0x0];const _0x260ff6=_[_0x2bcf0e('0x39')](_0x576a73['body'],{'firstName':_0x576a73[_0x2bcf0e('0x8a')]['from'],'ListId':_0x3c0596[_0x2bcf0e('0x23')]});return _0x260ff6[_0x576a73['body']['mapKey']]=_0x576a73[_0x2bcf0e('0x8a')][_0x2bcf0e('0x2a')],db[_0x2bcf0e('0x31')]['create'](_0x260ff6,{'fields':_0x2a6739,'raw':!![]});}})['then'](handleEntityNotFound(_0x3dd210,null))[_0x398d2f('0x98')](function(_0x40ca57){const _0x2260d6=_0x398d2f;_0x2ebce8[_0x2260d6('0x54')]=_0x40ca57;if(_0x40ca57){const _0x297fc2={'ContactId':_0x40ca57['id'],'OpenchannelAccountId':_0x576a73[_0x2260d6('0x32')]['id'],'from':(_0x40ca57[_0x2260d6('0x5e')]||'')+'\x20'+(_0x40ca57[_0x2260d6('0x96')]||'')},_0x1d3c9f={'OpenchannelAccountId':_0x576a73[_0x2260d6('0x32')]['id'],'closed':![]};if(_0x576a73[_0x2260d6('0x8a')]['threadId'])return _0x1d3c9f[_0x2260d6('0x1d')]=_0x576a73[_0x2260d6('0x8a')][_0x2260d6('0x1d')],db[_0x2260d6('0x5c')][_0x2260d6('0x90')]({'where':_0x1d3c9f})[_0x2260d6('0x98')](function(_0x1308ca){const _0x3abdd2=_0x2260d6;if(_0x1308ca)return[_0x1308ca,![]];return _0x297fc2[_0x3abdd2('0x1d')]=_0x576a73['body'][_0x3abdd2('0x1d')],_0x297fc2['externalUrl']=_0x576a73[_0x3abdd2('0x8a')][_0x3abdd2('0x61')],db['OpenchannelInteraction'][_0x3abdd2('0x64')](_0x297fc2)[_0x3abdd2('0x98')](function(_0x2ffd3a){return[_0x2ffd3a,!![]];});});else _0x1d3c9f['threadId']=null;return _0x1d3c9f[_0x2260d6('0x7f')]=_0x40ca57['id'],db[_0x2260d6('0x5c')][_0x2260d6('0x90')]({'where':_0x1d3c9f})[_0x2260d6('0x98')](function(_0x52373f){const _0x7e791f=_0x2260d6;if(_0x52373f)return[_0x52373f,![]];return db['OpenchannelInteraction'][_0x7e791f('0x64')](_0x297fc2)[_0x7e791f('0x98')](function(_0x485f8c){return[_0x485f8c,!![]];});});}})[_0x398d2f('0x98')](function([_0x379882,_0x1bab83]){const _0x47cdd2=_0x398d2f;if(_0x379882){_0x49be7c=_0x1bab83;if(!_0x1bab83){const _0x283451={'from':(_0x2ebce8['contact'][_0x47cdd2('0x5e')]||'')+'\x20'+(_0x2ebce8[_0x47cdd2('0x54')][_0x47cdd2('0x96')]||'')};return _0x576a73[_0x47cdd2('0x8a')]['threadId']&&_0x576a73[_0x47cdd2('0x8a')][_0x47cdd2('0x3f')]&&_0x576a73[_0x47cdd2('0x8a')][_0x47cdd2('0x1d')]!=_0x576a73[_0x47cdd2('0x8a')][_0x47cdd2('0x3f')]&&(_0x283451[_0x47cdd2('0x1d')]=_0x576a73[_0x47cdd2('0x8a')]['messageId']),_0x379882[_0x47cdd2('0x48')](_0x283451);}else return _0x379882;}})[_0x398d2f('0x98')](function(_0x29b411){const _0xca05ee=_0x398d2f;return _0x2ebce8['interaction']=_0x29b411[_0xca05ee('0x2f')]({'plain':!![]}),_0x2ebce8[_0xca05ee('0x55')][_0xca05ee('0x1b')]=_0x49be7c,_0x2ebce8['interaction'][_0xca05ee('0x1b')]&&(_0x2ebce8[_0xca05ee('0x12')][_0xca05ee('0x5b')]&&_0x2ebce8[_0xca05ee('0x19')][_0xca05ee('0x11')]({'id':0x0,'priority':_0x2ebce8[_0xca05ee('0x19')][_0xca05ee('0x38')]+0x1,'app':'close','appdata':_0xca05ee('0x9a'),'interval':'*,*,*,*'})),db[_0xca05ee('0x91')][_0xca05ee('0x64')]({'body':_0x576a73[_0xca05ee('0x8a')][_0xca05ee('0x8a')],'OpenchannelAccountId':_0x576a73[_0xca05ee('0x32')]['id'],'OpenchannelInteractionId':_0x29b411['id'],'direction':'in','ContactId':_0x2ebce8[_0xca05ee('0x54')]['id'],'AttachmentId':_0x576a73[_0xca05ee('0x8a')][_0xca05ee('0x68')]});})[_0x398d2f('0x98')](function(_0x1fe09c){const _0x22e8e9=_0x398d2f;_0x2ebce8[_0x22e8e9('0x1')]=_0x1fe09c;if(_0x2ebce8['interaction'][_0x22e8e9('0x59')])return db[_0x22e8e9('0xb')][_0x22e8e9('0x90')]({'attributes':['id','name'],'where':{'id':_0x2ebce8[_0x22e8e9('0x55')][_0x22e8e9('0x59')]}})['then'](function(_0x1d10dd){const _0x59f1b2=_0x22e8e9;return _0x1d10dd&&(_0x2ebce8[_0x59f1b2('0x19')][_0x59f1b2('0x49')]({'id':0x0,'priority':0x0,'app':'agent','appdata':_0x1d10dd[_0x59f1b2('0x1e')]+','+(_0x2ebce8[_0x59f1b2('0x12')][_0x59f1b2('0x22')]||0xa),'interval':_0x59f1b2('0x27')}),_0x2ebce8['forcedOwnership']=![]),respondWithRpcPromise(_0x59f1b2('0x3'),_0x59f1b2('0x28'),_0x2ebce8);});return respondWithRpcPromise(_0x22e8e9('0x3'),_0x22e8e9('0x28'),_0x2ebce8);})[_0x398d2f('0x98')](function(_0x4210aa){const _0x5569ad=_0x398d2f;return respondWithRpcPromise('EventManager',_0x5569ad('0x35'),{'event':'notify','message':_0x4210aa},client9002),_0x4210aa;})[_0x398d2f('0x98')](respondWithResult(_0x3dd210,null))['catch'](handleError(_0x3dd210,null));},exports[_0x4dcd09('0x15')]=function(_0x469c50,_0x3c57cd){const _0x30ee46=_0x4dcd09;return db[_0x30ee46('0x71')][_0x30ee46('0x90')]({'where':{'id':_0x469c50[_0x30ee46('0x32')]['id']}})[_0x30ee46('0x98')](handleEntityNotFound(_0x3c57cd,null))[_0x30ee46('0x98')](function(_0x4e3e7a){const _0xbc7d3d=_0x30ee46;if(_0x4e3e7a)return db['sequelize'][_0xbc7d3d('0x97')](function(_0x19d18b){const _0x1404e4=_0xbc7d3d;return db[_0x1404e4('0x58')][_0x1404e4('0x41')]({'where':{'OpenchannelAccountId':_0x469c50[_0x1404e4('0x32')]['id']},'transaction':_0x19d18b})[_0x1404e4('0x98')](function(){const _0x502ace=_0x1404e4,_0x8c3ed4=_[_0x502ace('0x30')](_0x469c50['body'],function(_0x24591f){const _0x59721b=_0x502ace;return _0x24591f['OpenchannelAccountId']=_0x469c50[_0x59721b('0x32')]['id'],_0x24591f;});return db['OpenchannelApplication'][_0x502ace('0x29')](_0x8c3ed4,{'transaction':_0x19d18b});});})[_0xbc7d3d('0x98')](function(){const _0x4caccc=_0xbc7d3d;return db[_0x4caccc('0x58')][_0x4caccc('0x18')]({'where':{'OpenchannelAccountId':_0x469c50[_0x4caccc('0x32')]['id']},'order':_0x4caccc('0x5a')});});})[_0x30ee46('0x98')](respondWithResult(_0x3c57cd,null))[_0x30ee46('0x10')](handleError(_0x3c57cd,null));},exports['getApplications']=function(_0x25feab,_0x1609a4){const _0x53ecff=_0x4dcd09;let _0x4a7bf9={};const _0x2a2986={};let _0x73ea64,_0x442fdb;return db['OpenchannelAccount'][_0x53ecff('0x90')]({'where':{'id':_0x25feab[_0x53ecff('0x32')]['id']}})[_0x53ecff('0x98')](handleEntityNotFound(_0x1609a4,null))['then'](function(_0x13cefd){const _0x25b348=_0x53ecff;if(_0x13cefd)return _0x73ea64=_0x13cefd,_0x2a2986[_0x25b348('0xa')]=_[_0x25b348('0x84')](db['OpenchannelApplication'][_0x25b348('0x93')]),_0x2a2986['query']=_[_0x25b348('0x84')](_0x25feab[_0x25b348('0x25')]),_0x2a2986[_0x25b348('0x24')]=_['intersection'](_0x2a2986[_0x25b348('0xa')],_0x2a2986[_0x25b348('0x25')]),_0x4a7bf9['attributes']=_[_0x25b348('0x57')](_0x2a2986[_0x25b348('0xa')],qs[_0x25b348('0x34')](_0x25feab['query']['fields'])),_0x4a7bf9['attributes']=_0x4a7bf9['attributes'][_0x25b348('0x38')]?_0x4a7bf9['attributes']:_0x2a2986[_0x25b348('0xa')],_0x4a7bf9[_0x25b348('0x86')]=qs[_0x25b348('0x75')](_0x25feab['query'][_0x25b348('0x75')]),_0x4a7bf9['where']=qs[_0x25b348('0x24')](_[_0x25b348('0x82')](_0x25feab[_0x25b348('0x25')],_0x2a2986[_0x25b348('0x24')])),_0x25feab['query'][_0x25b348('0x4e')]&&(_0x4a7bf9[_0x25b348('0xf')]=_[_0x25b348('0x1c')](_0x4a7bf9[_0x25b348('0xf')],{[Op['or']]:_[_0x25b348('0x30')](_0x4a7bf9[_0x25b348('0x37')],function(_0x1331bd){const _0x540d2c=_0x25b348,_0x40686f={};return _0x40686f[_0x1331bd]={[Op[_0x540d2c('0x33')]]:'%'+_0x25feab[_0x540d2c('0x25')][_0x540d2c('0x4e')]+'%'},_0x40686f;})})),_0x4a7bf9=_['merge']({},_0x4a7bf9,_0x25feab['options']),_0x73ea64[_0x25b348('0x7e')](_0x4a7bf9);})[_0x53ecff('0x98')](function(_0x340049){const _0x44faa8=_0x53ecff;if(_0x340049)return _0x442fdb=_0x340049[_0x44faa8('0x38')],typeof _0x25feab['query'][_0x44faa8('0x79')]===_0x44faa8('0x7b')&&(_0x4a7bf9['limit']=qs[_0x44faa8('0x26')](_0x25feab['query'][_0x44faa8('0x26')]),_0x4a7bf9[_0x44faa8('0x16')]=qs['offset'](_0x25feab[_0x44faa8('0x25')][_0x44faa8('0x16')])),_0x73ea64[_0x44faa8('0x7e')](_0x4a7bf9);})[_0x53ecff('0x98')](function(_0x1ab160){if(_0x1ab160)return _0x1ab160?{'count':_0x442fdb,'rows':_0x1ab160}:null;})[_0x53ecff('0x98')](respondWithResult(_0x1609a4,null))[_0x53ecff('0x10')](handleError(_0x1609a4,null));},exports[_0x4dcd09('0x4b')]=function(_0x5d19f4,_0x15c2da){const _0x5aa133=_0x4dcd09;let _0x1cf390={'raw':![],'where':{}};const _0x56d3e4={},_0x39263e={'count':0x0,'rows':[]};return db['OpenchannelAccount'][_0x5aa133('0x90')]({'where':{'id':_0x5d19f4[_0x5aa133('0x32')]['id']}})[_0x5aa133('0x98')](handleEntityNotFound(_0x15c2da,null))[_0x5aa133('0x98')](function(_0x1a61e9){const _0x191e4b=_0x5aa133;if(_0x1a61e9)return _0x56d3e4[_0x191e4b('0xa')]=_[_0x191e4b('0x84')](db[_0x191e4b('0x5c')][_0x191e4b('0x93')]),_0x56d3e4[_0x191e4b('0x25')]=_[_0x191e4b('0x84')](_0x5d19f4[_0x191e4b('0x25')]),_0x56d3e4[_0x191e4b('0x24')]=_[_0x191e4b('0x57')](_0x56d3e4['model'],_0x56d3e4[_0x191e4b('0x25')]),_0x1cf390[_0x191e4b('0x37')]=_[_0x191e4b('0x57')](_0x56d3e4[_0x191e4b('0xa')],qs[_0x191e4b('0x34')](_0x5d19f4[_0x191e4b('0x25')]['fields'])),_0x1cf390['attributes']=_0x1cf390['attributes']['length']?_0x1cf390['attributes']:_0x56d3e4[_0x191e4b('0xa')],typeof _0x5d19f4['query']['nolimit']===_0x191e4b('0x7b')&&(_0x1cf390[_0x191e4b('0x26')]=qs[_0x191e4b('0x26')](_0x5d19f4[_0x191e4b('0x25')][_0x191e4b('0x26')]),_0x1cf390[_0x191e4b('0x16')]=qs['offset'](_0x5d19f4[_0x191e4b('0x25')][_0x191e4b('0x16')])),_0x1cf390['order']=qs[_0x191e4b('0x75')](_0x5d19f4[_0x191e4b('0x25')][_0x191e4b('0x75')]),_0x1cf390[_0x191e4b('0xf')]=qs['filters'](_[_0x191e4b('0x82')](_0x5d19f4[_0x191e4b('0x25')],_0x56d3e4['filters'])),_0x1cf390[_0x191e4b('0xf')][_0x191e4b('0x8c')]=_0x1a61e9['id'],_0x5d19f4[_0x191e4b('0x25')][_0x191e4b('0x4e')]&&(_0x1cf390[_0x191e4b('0xf')]=_[_0x191e4b('0x1c')](_0x1cf390[_0x191e4b('0xf')],{[Op['or']]:_['map'](_0x1cf390[_0x191e4b('0x37')],function(_0x3d2fb4){const _0x22a211=_0x191e4b,_0x3f208c={};return _0x3f208c[_0x3d2fb4]={[Op[_0x22a211('0x33')]]:'%'+_0x5d19f4['query'][_0x22a211('0x4e')]+'%'},_0x3f208c;})})),_0x1cf390=_[_0x191e4b('0x1c')]({},_0x1cf390,_0x5d19f4[_0x191e4b('0xc')]),db[_0x191e4b('0x5c')]['count']({'where':_0x1cf390[_0x191e4b('0xf')]})[_0x191e4b('0x98')](function(_0xfbfb28){const _0x52dc29=_0x191e4b;return _0x39263e[_0x52dc29('0x80')]=_0xfbfb28,_0x5d19f4['query']['includeAll']&&(_0x1cf390[_0x52dc29('0x20')]=[{'model':db[_0x52dc29('0x31')],'as':_0x52dc29('0x66'),'required':![]},{'model':db[_0x52dc29('0xb')],'as':_0x52dc29('0x14'),'attributes':['name','fullname','internal'],'required':![]},{'model':db['Tag'],'as':'Tags','attributes':['id',_0x52dc29('0x1e'),_0x52dc29('0x13')],'where':_0x5d19f4['query']['tag']?{'id':_0x5d19f4[_0x52dc29('0x25')][_0x52dc29('0x53')]}:undefined,'required':_0x5d19f4[_0x52dc29('0x25')][_0x52dc29('0x53')]?!![]:![]}]),db[_0x52dc29('0x5c')]['findAll'](_0x1cf390);})[_0x191e4b('0x98')](function(_0x6594a5){const _0x1eb7ee=_0x191e4b;return _0x39263e[_0x1eb7ee('0x99')]=_0x6594a5,_0x39263e;});})[_0x5aa133('0x98')](respondWithFilteredResult(_0x15c2da,_0x1cf390))['catch'](handleError(_0x15c2da,null));},exports['addAgents']=function(_0x4eeaa5,_0x36facc){const _0x47f3ee=_0x4dcd09;return db[_0x47f3ee('0x71')][_0x47f3ee('0x90')]({'where':{'id':_0x4eeaa5['params']['id']}})['then'](function(_0xa16a1f){const _0x47041e=_0x47f3ee;if(_0xa16a1f)return _0xa16a1f[_0x47041e('0x50')](_0x4eeaa5[_0x47041e('0x8a')][_0x47041e('0x4f')],{'through':_[_0x47041e('0x2d')](_0x4eeaa5[_0x47041e('0x8a')],['ids','id'])})['then'](function(_0x370f9a){const _0x126221=_0x47041e;for(let _0x3e256b=0x0;_0x3e256b<_0x4eeaa5[_0x126221('0x8a')][_0x126221('0x4f')][_0x126221('0x38')];_0x3e256b+=0x1){socket[_0x126221('0x6c')](_0x126221('0x40'),{'UserId':_0x4eeaa5['body'][_0x126221('0x4f')][_0x3e256b],'OpenchannelAccountId':_0x4eeaa5[_0x126221('0x32')]['id']});}return _0x370f9a;});})['then'](respondWithResult(_0x36facc,null))[_0x47f3ee('0x10')](handleError(_0x36facc,null));},exports['removeAgents']=function(_0x3c267b,_0x2cfcec){const _0x5c9e14=_0x4dcd09;return db[_0x5c9e14('0x71')]['findOne']({'where':{'id':_0x3c267b[_0x5c9e14('0x32')]['id']}})['then'](handleEntityNotFound(_0x2cfcec,null))[_0x5c9e14('0x98')](function(_0xe3799b){const _0x59a2f8=_0x5c9e14;if(_0xe3799b)return _0xe3799b[_0x59a2f8('0x3d')](_0x3c267b[_0x59a2f8('0x25')][_0x59a2f8('0x4f')])[_0x59a2f8('0x98')](function(){const _0x41b819=_0x59a2f8;if(_[_0x41b819('0x4')](_0x3c267b[_0x41b819('0x25')]['ids']))for(let _0x4ec3b5=0x0;_0x4ec3b5<_0x3c267b[_0x41b819('0x25')][_0x41b819('0x4f')][_0x41b819('0x38')];_0x4ec3b5+=0x1){socket[_0x41b819('0x6c')](_0x41b819('0x3a'),{'UserId':Number(_0x3c267b[_0x41b819('0x25')]['ids'][_0x4ec3b5]),'OpenchannelAccountId':Number(_0x3c267b['params']['id'])});}else socket[_0x41b819('0x6c')](_0x41b819('0x3a'),{'UserId':Number(_0x3c267b[_0x41b819('0x25')][_0x41b819('0x4f')]),'OpenchannelAccountId':Number(_0x3c267b[_0x41b819('0x32')]['id'])});});})['then'](respondWithStatusCode(_0x2cfcec,null))[_0x5c9e14('0x10')](handleError(_0x2cfcec,null));},exports[_0x4dcd09('0x8')]=function(_0x1fc8d6,_0x17cc23){const _0x281b2a=_0x4dcd09;let _0x3f8ab8={};const _0x5b4e4d={};let _0x489a5b,_0x572d49;return db['OpenchannelAccount']['findOne']({'where':{'id':_0x1fc8d6[_0x281b2a('0x32')]['id']}})[_0x281b2a('0x98')](handleEntityNotFound(_0x17cc23,null))['then'](function(_0x592a07){const _0x33a587=_0x281b2a;if(_0x592a07)return _0x489a5b=_0x592a07,_0x5b4e4d[_0x33a587('0xa')]=_[_0x33a587('0x84')](db[_0x33a587('0xb')][_0x33a587('0x93')]),_0x5b4e4d[_0x33a587('0x25')]=_[_0x33a587('0x84')](_0x1fc8d6[_0x33a587('0x25')]),_0x5b4e4d[_0x33a587('0x24')]=_[_0x33a587('0x57')](_0x5b4e4d['model'],_0x5b4e4d[_0x33a587('0x25')]),_0x3f8ab8[_0x33a587('0x37')]=_['intersection'](_0x5b4e4d[_0x33a587('0xa')],qs[_0x33a587('0x34')](_0x1fc8d6['query'][_0x33a587('0x34')])),_0x3f8ab8['attributes']=_0x3f8ab8[_0x33a587('0x37')][_0x33a587('0x38')]?_0x3f8ab8[_0x33a587('0x37')]:_0x5b4e4d[_0x33a587('0xa')],_0x3f8ab8[_0x33a587('0x86')]=qs[_0x33a587('0x75')](_0x1fc8d6['query'][_0x33a587('0x75')]),_0x3f8ab8['where']=qs[_0x33a587('0x24')](_[_0x33a587('0x82')](_0x1fc8d6[_0x33a587('0x25')],_0x5b4e4d[_0x33a587('0x24')])),_0x1fc8d6[_0x33a587('0x25')][_0x33a587('0x4e')]&&(_0x3f8ab8['where']=_['merge'](_0x3f8ab8[_0x33a587('0xf')],{[Op['or']]:_[_0x33a587('0x30')](_0x3f8ab8[_0x33a587('0x37')],function(_0x10ca5a){const _0x4b7f79={};return _0x4b7f79[_0x10ca5a]={[Op['like']]:'%'+_0x1fc8d6['query']['filter']+'%'},_0x4b7f79;})})),_0x3f8ab8=_[_0x33a587('0x1c')]({},_0x3f8ab8,_0x1fc8d6[_0x33a587('0xc')]),_0x489a5b[_0x33a587('0x8')](_0x3f8ab8);})[_0x281b2a('0x98')](function(_0x45ca6d){const _0x32e128=_0x281b2a;if(_0x45ca6d)return _0x572d49=_0x45ca6d[_0x32e128('0x38')],typeof _0x1fc8d6['query'][_0x32e128('0x79')]===_0x32e128('0x7b')&&(_0x3f8ab8[_0x32e128('0x26')]=qs[_0x32e128('0x26')](_0x1fc8d6[_0x32e128('0x25')]['limit']),_0x3f8ab8[_0x32e128('0x16')]=qs['offset'](_0x1fc8d6[_0x32e128('0x25')][_0x32e128('0x16')])),_0x489a5b[_0x32e128('0x8')](_0x3f8ab8);})[_0x281b2a('0x98')](function(_0x506ae3){if(_0x506ae3)return _0x506ae3?{'count':_0x572d49,'rows':_0x506ae3}:null;})[_0x281b2a('0x98')](respondWithResult(_0x17cc23,null))[_0x281b2a('0x10')](handleError(_0x17cc23,null));},exports[_0x4dcd09('0x56')]=function(_0x40ff16,_0xb8f572){const _0x25571d=_0x4dcd09;let _0x4b7422,_0x2be971;if(_[_0x25571d('0x73')](_0x40ff16[_0x25571d('0x8a')]['body'])||_0x40ff16[_0x25571d('0x8a')][_0x25571d('0x8a')]==='')throw new ValidationError(_0x25571d('0x52'));if(_[_0x25571d('0x73')](_0x40ff16['body']['to'])){}const _0x4bef4e=_0x40ff16[_0x25571d('0x8a')]['to'];return db['OpenchannelAccount'][_0x25571d('0x90')]({'where':{'id':_0x40ff16[_0x25571d('0x32')]['id']}})['then'](handleEntityNotFound(_0xb8f572,null))[_0x25571d('0x98')](function(_0x3b9dad){const _0xa36f6f=_0x25571d;if(_0x3b9dad)return db[_0xa36f6f('0x71')][_0xa36f6f('0x90')]({'where':{'id':_0x3b9dad['id']},'include':[{'model':db['CmList'],'as':_0xa36f6f('0x62'),'include':[{'model':db[_0xa36f6f('0x31')],'as':_0xa36f6f('0x95'),'where':{[_0x3b9dad[_0xa36f6f('0x5f')]]:_0x4bef4e},'limit':0x1,'order':[['updatedAt','DESC']]}]}]})[_0xa36f6f('0x98')](handleEntityNotFound(_0xb8f572,null))[_0xa36f6f('0x98')](function(_0x1b5243){const _0x52b9ae=_0xa36f6f;if(_0x1b5243&&_0x1b5243[_0x52b9ae('0x62')]){_0x4b7422=_0x1b5243[_0x52b9ae('0x2f')]({'plain':!![]});if(_0x4b7422[_0x52b9ae('0x62')]&&_0x4b7422['List']['Contacts']['length'])return _0x4b7422[_0x52b9ae('0x62')][_0x52b9ae('0x95')][0x0];return db['CmContact'][_0x52b9ae('0x64')](_[_0x52b9ae('0x39')](_0x40ff16[_0x52b9ae('0x8a')],{'firstName':_0x4bef4e,[_0x1b5243[_0x52b9ae('0x5f')]]:_0x4bef4e,'phone':_0x4bef4e,'ListId':_0x4b7422[_0x52b9ae('0x23')]}));}})[_0xa36f6f('0x98')](handleEntityNotFound(_0xb8f572,null))[_0xa36f6f('0x98')](function(_0x432fca){const _0x413fa6=_0xa36f6f;if(_0x432fca)return _0x2be971=_0x432fca,db[_0x413fa6('0x5c')]['findOne']({'where':{'ContactId':_0x2be971['id'],'closed':![],'OpenchannelAccountId':_0x4b7422['id']}})['then'](function(_0x26f94f){const _0x5d2e6f=_0x413fa6;if(_0x26f94f)return[_0x26f94f,![]];return db[_0x5d2e6f('0x5c')]['create']({'UserId':_0x40ff16[_0x5d2e6f('0x2e')]['id'],'ContactId':_0x2be971['id'],'OpenchannelAccountId':_0x4b7422['id'],'lastMsgDirection':'out','Messages':[_['merge'](_0x40ff16[_0x5d2e6f('0x8a')],{'read':![],'body':_0x40ff16[_0x5d2e6f('0x8a')][_0x5d2e6f('0x8a')],'OpenchannelAccountId':_0x4b7422['id'],'UserId':_0x40ff16[_0x5d2e6f('0x2e')]['id'],'ContactId':_0x2be971['id']})]},{'include':[{'model':db[_0x5d2e6f('0x91')],'as':_0x5d2e6f('0x42')}]})[_0x5d2e6f('0x98')](function(_0x3df0b4){return[_0x3df0b4,!![]];});});})['then'](function([_0x337fbb,_0xc78a90]){const _0x53b62b=_0xa36f6f;if(_0xc78a90)return _0x337fbb;return db[_0x53b62b('0x91')][_0x53b62b('0x64')](_[_0x53b62b('0x1c')](_0x40ff16[_0x53b62b('0x8a')],{'read':![],'body':_0x40ff16['body'][_0x53b62b('0x8a')],'OpenchannelAccountId':_0x4b7422['id'],'OpenchannelInteractionId':_0x337fbb['id'],'UserId':_0x40ff16[_0x53b62b('0x2e')]['id'],'ContactId':_0x2be971['id']}))[_0x53b62b('0x98')](function(_0x342813){const _0x313316=_0x53b62b;return _0x337fbb['dataValues'][_0x313316('0x42')]=[],_0x337fbb[_0x313316('0x2')]['Messages'][_0x313316('0x11')](_0x342813[_0x313316('0x2')]),_0x337fbb;});});})[_0x25571d('0x98')](respondWithResult(_0xb8f572,null))[_0x25571d('0x10')](handleError(_0xb8f572,null));}; \ No newline at end of file +const a468_0x1ebb=['debug','describe','name','OpenchannelAccountId','Contact','user','ids','emit','mapKey','Pause','request\x20sent','offset','startRouting','nolimit','key','transaction','client','OpenchannelAccounts','userOpenchannelAccount:save','OpenchannelAccount,\x20%s,\x20%s,\x20%s','interaction','UserId','update','jayson/promise','Start','mandatoryDispositionPause','CompanyId','priority','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','addAgents','merge','code','externalUrl','created','body','destroy','mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20','User','fields','create','addApplications','message','rawAttributes','*,*,*,*','userOpenchannelAccount:remove','close','includes','forcedOwnership','findAll','http','keys','removeDispositions','register','sort','applications','info','getAgents','DESC','OpenchannelMessage','filter','contact','catch','autoAssociation','removeAnswers','defaults','intersection','omit','index','request','sequelize','map','isNil','model','api','options','fullname','end','stringify','dataValues','findOne','length','firstName','findAndCountAll','Contacts','rows','no\x20available\x20attributes','fieldName','userProfileId','Unable\x20to\x20retrieve\x20the\x20current\x20user','notify','query','list','UserProfileSection','lodash','pick','UserProfileResource','OpenchannelInteraction','VIRTUAL','attributes','Tag','push','like','openchannel','bulkCreate','Applications','order','getAnswers','Owner','includeAll','where','unshift','Content-Range','account','limit','unmanaged','tag','undefined','OpenchannelAccount,\x20%s,\x20%s','type','CannedAnswer','sendStatus','count','getApplications','from','./openchannelAccount.socket','internal','mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','CmContact','Messages','lastName','../../rediscache','waitForTheAssignedAgent','get','stack','OpenchannelAccount','body\x20is\x20mandatory\x20and\x20not\x20empty','agent','List','color','out','OpenchannelApplication','ListId','EventManager','updatedAt','send','params','CmList','from\x20is\x20mandatory','addDisposition','error','threadId','status','filters','then','result','asc','ContactId','Disposition','createdAt','isArray','removeAgents','messageId','include','../../components/parsers/qs'];(function(_0x2a2321,_0x1ebbf0){const _0x4da1dc=function(_0x4adb39){while(--_0x4adb39){_0x2a2321['push'](_0x2a2321['shift']());}};_0x4da1dc(++_0x1ebbf0);}(a468_0x1ebb,0x13b));const a468_0x4da1=function(_0x2a2321,_0x1ebbf0){_0x2a2321=_0x2a2321-0x0;let _0x4da1dc=a468_0x1ebb[_0x2a2321];return _0x4da1dc;};const _0x3304db=a468_0x4da1;'use strict';const _=require(_0x3304db('0x6a')),qs=require(_0x3304db('0xc')),logger=require('../../config/logger')(_0x3304db('0x56')),{getSocket}=require(_0x3304db('0x8f')),socket=getSocket(),db=require('../../mysqldb')['db'],{Op,ValidationError}=require('sequelize');require(_0x3304db('0x89'))[_0x3304db('0x41')](socket);const jayson=require(_0x3304db('0x24')),client=jayson['client']['http']({'port':0x232c}),client9002=jayson[_0x3304db('0x1d')][_0x3304db('0x3e')]({'port':0x232a});function respondWithRpcPromise(_0x4adb39,_0x19a697,_0x7932bb,_0x49e620){return new Promise(function(_0x371398,_0xcb2700){const _0x294dcf=a468_0x4da1,_0x19e2b2=_0x49e620||client;return _0x19e2b2[_0x294dcf('0x51')](_0x4adb39,_0x7932bb)['then'](function(_0x578542){const _0xa577f1=_0x294dcf;logger[_0xa577f1('0x44')](_0xa577f1('0x82'),_0x19a697,_0xa577f1('0x17')),logger[_0xa577f1('0xd')](_0xa577f1('0x20'),_0x19a697,'request\x20sent',JSON[_0xa577f1('0x5a')](_0x578542));if(_0x578542['error']){if(_0x578542['error'][_0xa577f1('0x2c')]===0x1f4)return logger[_0xa577f1('0xa2')](_0xa577f1('0x82'),_0x19a697,_0x578542[_0xa577f1('0xa2')]['message']),_0xcb2700(_0x578542[_0xa577f1('0xa2')][_0xa577f1('0x36')]);return logger[_0xa577f1('0xa2')](_0xa577f1('0x82'),_0x19a697,_0x578542['error']['message']),_0x371398(_0x578542[_0xa577f1('0xa2')][_0xa577f1('0x36')]);}else logger[_0xa577f1('0x44')](_0xa577f1('0x82'),_0x19a697,'request\x20sent'),_0x371398(_0x578542[_0xa577f1('0x3')][_0xa577f1('0x36')]);})['catch'](function(_0x558259){const _0xe6f740=_0x294dcf;logger[_0xe6f740('0xa2')]('OpenchannelAccount,\x20%s,\x20%s',_0x19a697,_0x558259),_0xcb2700(_0x558259);});});}function respondWithStatusCode(_0x28cec0,_0x5e6687){return _0x5e6687=_0x5e6687||0xcc,function(_0x4bfebd){const _0x338205=a468_0x4da1;if(_0x4bfebd)return _0x28cec0[_0x338205('0x85')](_0x5e6687);return _0x28cec0[_0x338205('0x0')](_0x5e6687)[_0x338205('0x59')]();};}function respondWithResult(_0x2f37d6,_0x3c5563){return _0x3c5563=_0x3c5563||0xc8,function(_0x59cea9){if(_0x59cea9)return _0x2f37d6['status'](_0x3c5563)['json'](_0x59cea9);};}function respondWithFilteredResult(_0x18bf5f,_0xb8bd0){return function(_0x4d1969){const _0xe3ea9c=a468_0x4da1;if(_0x4d1969){const _0x1dc47e=_0x4d1969['count'],_0x22d38f=_0xb8bd0[_0xe3ea9c('0x18')];let _0x49bbdd=_0xb8bd0[_0xe3ea9c('0x18')]+_0xb8bd0[_0xe3ea9c('0x7e')],_0x14d0bf;return _0x49bbdd>=_0x1dc47e?(_0x49bbdd=_0x1dc47e,_0x14d0bf=0xc8):_0x14d0bf=0xce,_0x18bf5f['status'](_0x14d0bf),_0x18bf5f['set'](_0xe3ea9c('0x7c'),_0x22d38f+'-'+_0x49bbdd+'/'+_0x1dc47e)['json'](_0x4d1969);}return null;};}function saveUpdates(_0x46c351){return function(_0x2e56f7){const _0x63ea22=a468_0x4da1;if(_0x2e56f7)return _0x2e56f7[_0x63ea22('0x23')](_0x46c351)[_0x63ea22('0x2')](function(_0x4d29eb){return _0x4d29eb;});return null;};}function removeEntity(_0x3174b3){return function(_0x418b50){const _0x4315be=a468_0x4da1;if(_0x418b50)return _0x418b50['destroy']()[_0x4315be('0x2')](function(){const _0xb94706=_0x4315be,_0x4fb4fe=_0x418b50['get']({'plain':!![]}),_0x23bf7d=_0xb94706('0x1e');return db[_0xb94706('0x6c')][_0xb94706('0x30')]({'where':{'type':_0x23bf7d,'resourceId':_0x4fb4fe['id']}})[_0xb94706('0x2')](function(){return _0x418b50;});})[_0x4315be('0x2')](function(){_0x3174b3['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x4eac6b){return function(_0x1e87c2){const _0x51675a=a468_0x4da1;return!_0x1e87c2&&_0x4eac6b[_0x51675a('0x85')](0x194),_0x1e87c2;};}function handleError(_0x54e206,_0x200402){return _0x200402=_0x200402||0x1f4,function(_0x359e80){const _0x3d0260=a468_0x4da1;logger[_0x3d0260('0xa2')](_0x359e80[_0x3d0260('0x92')]),_0x359e80[_0x3d0260('0xf')]&&delete _0x359e80[_0x3d0260('0xf')],_0x54e206[_0x3d0260('0x0')](_0x200402)['send'](_0x359e80);};}exports[_0x3304db('0x50')]=function(_0x466574,_0x1cf643){const _0x41fca7=_0x3304db;let _0x539526={'include':[{'model':db['Pause'],'as':_0x41fca7('0x26')}]};const _0x2d3db9={},_0x466800={'count':0x0,'rows':[]},_0x22a031=_['map'](db[_0x41fca7('0x93')][_0x41fca7('0x37')],function(_0x3f0f1b){const _0x9cc28c=_0x41fca7;return{'name':_0x3f0f1b[_0x9cc28c('0x63')],'type':_0x3f0f1b[_0x9cc28c('0x83')][_0x9cc28c('0x1b')]};});_0x2d3db9[_0x41fca7('0x55')]=_[_0x41fca7('0x53')](_0x22a031,_0x41fca7('0xf')),_0x2d3db9['query']=_[_0x41fca7('0x3f')](_0x466574[_0x41fca7('0x67')]),_0x2d3db9[_0x41fca7('0x1')]=_[_0x41fca7('0x4e')](_0x2d3db9[_0x41fca7('0x55')],_0x2d3db9[_0x41fca7('0x67')]),_0x539526[_0x41fca7('0x6f')]=_[_0x41fca7('0x4e')](_0x2d3db9['model'],qs[_0x41fca7('0x33')](_0x466574[_0x41fca7('0x67')][_0x41fca7('0x33')])),_0x539526['attributes']=_0x539526[_0x41fca7('0x6f')][_0x41fca7('0x5d')]?_0x539526[_0x41fca7('0x6f')]:_0x2d3db9['model'];typeof _0x466574[_0x41fca7('0x67')][_0x41fca7('0x1a')]===_0x41fca7('0x81')&&(_0x539526[_0x41fca7('0x7e')]=qs[_0x41fca7('0x7e')](_0x466574[_0x41fca7('0x67')][_0x41fca7('0x7e')]),_0x539526[_0x41fca7('0x18')]=qs[_0x41fca7('0x18')](_0x466574[_0x41fca7('0x67')]['offset']));_0x539526[_0x41fca7('0x76')]=qs[_0x41fca7('0x42')](_0x466574[_0x41fca7('0x67')][_0x41fca7('0x42')]),_0x539526[_0x41fca7('0x7a')]=qs[_0x41fca7('0x1')](_[_0x41fca7('0x6b')](_0x466574[_0x41fca7('0x67')],_0x2d3db9[_0x41fca7('0x1')]),_0x22a031);_0x466574[_0x41fca7('0x67')]['filter']&&(_0x539526[_0x41fca7('0x7a')]=_[_0x41fca7('0x2b')](_0x539526[_0x41fca7('0x7a')],{[Op['or']]:_[_0x41fca7('0x53')](_0x22a031,function(_0x16c26e){const _0x2b36e0=_0x41fca7;if(_0x16c26e[_0x2b36e0('0x83')]!==_0x2b36e0('0x6e')){const _0x4e76a6={};return _0x4e76a6[_0x16c26e[_0x2b36e0('0xf')]]={[Op[_0x2b36e0('0x72')]]:'%'+_0x466574[_0x2b36e0('0x67')][_0x2b36e0('0x48')]+'%'},_0x4e76a6;}})}));_0x539526=_[_0x41fca7('0x2b')]({},_0x539526,_0x466574['options']);const _0x2199db={'where':_0x539526[_0x41fca7('0x7a')]};return db[_0x41fca7('0x93')]['count'](_0x2199db)[_0x41fca7('0x2')](function(_0x2bde8c){const _0x19ebcd=_0x41fca7;return _0x466800['count']=_0x2bde8c,_0x466574[_0x19ebcd('0x67')]['includeAll']&&(_0x539526[_0x19ebcd('0xb')]=[{'all':!![]}]),db[_0x19ebcd('0x93')][_0x19ebcd('0x3d')](_0x539526);})[_0x41fca7('0x2')](function(_0x23c03f){const _0x26046e=_0x41fca7;return _0x466800[_0x26046e('0x61')]=_0x23c03f,_0x466800;})['then'](respondWithFilteredResult(_0x1cf643,_0x539526))[_0x41fca7('0x4a')](handleError(_0x1cf643,null));},exports['show']=function(_0x3c69fb,_0x2f40e5){const _0x1e01ff=_0x3304db;let _0x15a68a={'raw':![],'where':{'id':_0x3c69fb[_0x1e01ff('0x9e')]['id']},'include':[{'model':db[_0x1e01ff('0x16')],'as':'mandatoryDispositionPause'}]};const _0x8da973={};return _0x8da973[_0x1e01ff('0x55')]=_[_0x1e01ff('0x3f')](db[_0x1e01ff('0x93')][_0x1e01ff('0x37')]),_0x8da973['query']=_[_0x1e01ff('0x3f')](_0x3c69fb[_0x1e01ff('0x67')]),_0x8da973[_0x1e01ff('0x1')]=_[_0x1e01ff('0x4e')](_0x8da973['model'],_0x8da973[_0x1e01ff('0x67')]),_0x15a68a['attributes']=_[_0x1e01ff('0x4e')](_0x8da973['model'],qs[_0x1e01ff('0x33')](_0x3c69fb[_0x1e01ff('0x67')][_0x1e01ff('0x33')])),_0x15a68a[_0x1e01ff('0x6f')]=_0x15a68a[_0x1e01ff('0x6f')][_0x1e01ff('0x5d')]?_0x15a68a['attributes']:_0x8da973['model'],_0x3c69fb[_0x1e01ff('0x67')][_0x1e01ff('0x79')]&&(_0x15a68a[_0x1e01ff('0xb')]=[{'all':!![]}]),_0x15a68a=_[_0x1e01ff('0x2b')]({},_0x15a68a,_0x3c69fb['options']),db[_0x1e01ff('0x93')][_0x1e01ff('0x5c')](_0x15a68a)[_0x1e01ff('0x2')](handleEntityNotFound(_0x2f40e5,null))[_0x1e01ff('0x2')](respondWithResult(_0x2f40e5,null))[_0x1e01ff('0x4a')](handleError(_0x2f40e5,null));},exports[_0x3304db('0x34')]=function(_0x16a8b6,_0x2e2843){const _0x32ba4d=_0x3304db;return db[_0x32ba4d('0x93')][_0x32ba4d('0x34')](_0x16a8b6[_0x32ba4d('0x2f')],{})[_0x32ba4d('0x2')](function(_0x77f385){const _0x2a215a=_0x32ba4d,_0x2efeb7=_0x16a8b6['user'][_0x2a215a('0x91')]({'plain':!![]});if(!_0x2efeb7)throw new Error(_0x2a215a('0x65'));if(_0x2efeb7['role']==='user'){const _0x1f2f8f=_0x77f385[_0x2a215a('0x91')]({'plain':!![]}),_0x52e372=_0x2a215a('0x1e');return db[_0x2a215a('0x69')][_0x2a215a('0x5c')]({'where':{'name':_0x52e372,'userProfileId':_0x2efeb7[_0x2a215a('0x64')]},'raw':!![]})[_0x2a215a('0x2')](function(_0x592edb){const _0x46a926=_0x2a215a;return _0x592edb&&_0x592edb[_0x46a926('0x4b')]===0x0?db[_0x46a926('0x6c')]['create']({'name':_0x1f2f8f[_0x46a926('0xf')],'resourceId':_0x1f2f8f['id'],'type':_0x592edb[_0x46a926('0xf')],'sectionId':_0x592edb['id']},{})[_0x46a926('0x2')](function(){return _0x77f385;}):_0x77f385;})[_0x2a215a('0x4a')](function(_0x7fc46c){const _0x45cdcb=_0x2a215a;logger['error'](_0x45cdcb('0x29'),_0x7fc46c);throw _0x7fc46c;});}return _0x77f385;})[_0x32ba4d('0x2')](respondWithResult(_0x2e2843,0xc9))['catch'](handleError(_0x2e2843,null));},exports[_0x3304db('0x23')]=function(_0x1fd362,_0x375c75){const _0x45f3c1=_0x3304db;return _0x1fd362[_0x45f3c1('0x2f')]['id']&&delete _0x1fd362['body']['id'],db[_0x45f3c1('0x93')][_0x45f3c1('0x5c')]({'where':{'id':_0x1fd362[_0x45f3c1('0x9e')]['id']},'include':[{'model':db[_0x45f3c1('0x16')],'as':_0x45f3c1('0x26')}]})[_0x45f3c1('0x2')](handleEntityNotFound(_0x375c75,null))[_0x45f3c1('0x2')](saveUpdates(_0x1fd362['body'],null))['then'](respondWithResult(_0x375c75,null))['catch'](handleError(_0x375c75,null));},exports[_0x3304db('0x30')]=function(_0x290356,_0x619b70){const _0x2799c3=_0x3304db;return db['OpenchannelAccount'][_0x2799c3('0x5c')]({'where':{'id':_0x290356[_0x2799c3('0x9e')]['id']}})[_0x2799c3('0x2')](handleEntityNotFound(_0x619b70,null))['then'](removeEntity(_0x619b70,null))[_0x2799c3('0x4a')](handleError(_0x619b70,null));},exports[_0x3304db('0xe')]=function(_0x4ee4d6,_0x3de5af){const _0x18cb9e=_0x3304db;return db[_0x18cb9e('0x93')][_0x18cb9e('0xe')]()[_0x18cb9e('0x2')](respondWithResult(_0x3de5af,null))['catch'](handleError(_0x3de5af,null));},exports[_0x3304db('0xa1')]=function(_0x4b5ff0,_0x100a8b){const _0x4222bb=_0x3304db;return _0x4b5ff0[_0x4222bb('0x2f')]['id']&&delete _0x4b5ff0['body']['id'],db['OpenchannelAccount'][_0x4222bb('0x5c')]({'where':{'id':_0x4b5ff0[_0x4222bb('0x9e')]['id']}})[_0x4222bb('0x2')](handleEntityNotFound(_0x100a8b,null))[_0x4222bb('0x2')](function(_0x3cd6c1){const _0x3faa53=_0x4222bb;if(_0x3cd6c1)return _0x4b5ff0[_0x3faa53('0x2f')][_0x3faa53('0x10')]=_0x3cd6c1['id'],db[_0x3faa53('0x6')][_0x3faa53('0x34')](_0x4b5ff0['body']);})[_0x4222bb('0x2')](respondWithResult(_0x100a8b,null))[_0x4222bb('0x4a')](handleError(_0x100a8b,null));},exports['getDispositions']=function(_0x20eabe,_0x2688b6){const _0x292d22=_0x3304db;let _0x59e3da={'raw':![],'where':{}};const _0x18d788={},_0x4fb7c9={'count':0x0,'rows':[]};return db['OpenchannelAccount']['findOne']({'where':{'id':_0x20eabe[_0x292d22('0x9e')]['id']}})[_0x292d22('0x2')](handleEntityNotFound(_0x2688b6,null))[_0x292d22('0x2')](function(_0x5ecf11){const _0x354f09=_0x292d22;if(_0x5ecf11)return _0x18d788[_0x354f09('0x55')]=_[_0x354f09('0x3f')](db[_0x354f09('0x6')][_0x354f09('0x37')]),_0x18d788[_0x354f09('0x67')]=_[_0x354f09('0x3f')](_0x20eabe[_0x354f09('0x67')]),_0x18d788['filters']=_[_0x354f09('0x4e')](_0x18d788['model'],_0x18d788[_0x354f09('0x67')]),_0x59e3da[_0x354f09('0x6f')]=_[_0x354f09('0x4e')](_0x18d788[_0x354f09('0x55')],qs[_0x354f09('0x33')](_0x20eabe['query'][_0x354f09('0x33')])),_0x59e3da[_0x354f09('0x6f')]=_0x59e3da[_0x354f09('0x6f')]['length']?_0x59e3da[_0x354f09('0x6f')]:_0x18d788[_0x354f09('0x55')],typeof _0x20eabe['query'][_0x354f09('0x1a')]===_0x354f09('0x81')&&(_0x59e3da[_0x354f09('0x7e')]=qs['limit'](_0x20eabe[_0x354f09('0x67')][_0x354f09('0x7e')]),_0x59e3da['offset']=qs[_0x354f09('0x18')](_0x20eabe[_0x354f09('0x67')]['offset'])),_0x59e3da['order']=qs['sort'](_0x20eabe['query'][_0x354f09('0x42')]),_0x59e3da[_0x354f09('0x7a')]=qs['filters'](_[_0x354f09('0x6b')](_0x20eabe[_0x354f09('0x67')],_0x18d788['filters'])),_0x59e3da[_0x354f09('0x7a')][_0x354f09('0x10')]=_0x5ecf11['id'],_0x20eabe[_0x354f09('0x67')][_0x354f09('0x48')]&&(_0x59e3da[_0x354f09('0x7a')]=_[_0x354f09('0x2b')](_0x59e3da['where'],{[Op['or']]:_['map'](_0x59e3da[_0x354f09('0x6f')],function(_0x3b9049){const _0x4427a1=_0x354f09,_0xd59f30={};return _0xd59f30[_0x3b9049]={[Op[_0x4427a1('0x72')]]:'%'+_0x20eabe['query'][_0x4427a1('0x48')]+'%'},_0xd59f30;})})),_0x59e3da=_[_0x354f09('0x2b')]({},_0x59e3da,_0x20eabe['options']),db[_0x354f09('0x6')][_0x354f09('0x86')]({'where':_0x59e3da[_0x354f09('0x7a')]})[_0x354f09('0x2')](function(_0x5dc538){const _0x25d2db=_0x354f09;return _0x4fb7c9[_0x25d2db('0x86')]=_0x5dc538,_0x20eabe[_0x25d2db('0x67')][_0x25d2db('0x79')]&&(_0x59e3da['include']=[{'all':!![]}]),db[_0x25d2db('0x6')]['findAll'](_0x59e3da);})[_0x354f09('0x2')](function(_0x19cd86){const _0x23e83d=_0x354f09;return _0x4fb7c9[_0x23e83d('0x61')]=_0x19cd86,_0x4fb7c9;});})[_0x292d22('0x2')](respondWithFilteredResult(_0x2688b6,_0x59e3da))[_0x292d22('0x4a')](handleError(_0x2688b6,null));},exports[_0x3304db('0x40')]=function(_0x3568bf,_0x54d376){const _0xc8ccd0=_0x3304db;return db['OpenchannelAccount'][_0xc8ccd0('0x5c')]({'where':{'id':_0x3568bf['params']['id']}})['then'](handleEntityNotFound(_0x54d376,null))[_0xc8ccd0('0x2')](function(_0x3d37d1){const _0x5131c3=_0xc8ccd0;if(_0x3d37d1)return _0x3d37d1['removeDispositions'](_0x3568bf[_0x5131c3('0x67')][_0x5131c3('0x13')]);})[_0xc8ccd0('0x2')](respondWithStatusCode(_0x54d376,null))[_0xc8ccd0('0x4a')](handleError(_0x54d376,null));},exports['addAnswer']=function(_0x48c4cc,_0x4a5630){const _0x1aa010=_0x3304db;return _0x48c4cc[_0x1aa010('0x2f')]['id']&&delete _0x48c4cc[_0x1aa010('0x2f')]['id'],db[_0x1aa010('0x93')]['findOne']({'where':{'id':_0x48c4cc['params']['id']}})['then'](handleEntityNotFound(_0x4a5630,null))[_0x1aa010('0x2')](function(_0x344f73){const _0x4362d7=_0x1aa010;if(_0x344f73)return _0x48c4cc[_0x4362d7('0x2f')]['OpenchannelAccountId']=_0x344f73['id'],db[_0x4362d7('0x84')][_0x4362d7('0x34')](_0x48c4cc[_0x4362d7('0x2f')]);})['then'](respondWithResult(_0x4a5630,null))[_0x1aa010('0x4a')](handleError(_0x4a5630,null));},exports[_0x3304db('0x77')]=function(_0x3cc6ba,_0x375772){const _0xf7b19b=_0x3304db;let _0x108ae3={'raw':![],'where':{}};const _0x2a77c7={},_0x6e5662={'count':0x0,'rows':[]};return db['OpenchannelAccount'][_0xf7b19b('0x5c')]({'where':{'id':_0x3cc6ba[_0xf7b19b('0x9e')]['id']}})[_0xf7b19b('0x2')](handleEntityNotFound(_0x375772,null))[_0xf7b19b('0x2')](function(_0x5156d8){const _0x589993=_0xf7b19b;if(_0x5156d8)return _0x2a77c7[_0x589993('0x55')]=_['keys'](db['CannedAnswer'][_0x589993('0x37')]),_0x2a77c7[_0x589993('0x67')]=_[_0x589993('0x3f')](_0x3cc6ba['query']),_0x2a77c7[_0x589993('0x1')]=_[_0x589993('0x4e')](_0x2a77c7[_0x589993('0x55')],_0x2a77c7[_0x589993('0x67')]),_0x108ae3[_0x589993('0x6f')]=_[_0x589993('0x4e')](_0x2a77c7[_0x589993('0x55')],qs['fields'](_0x3cc6ba[_0x589993('0x67')][_0x589993('0x33')])),_0x108ae3['attributes']=_0x108ae3['attributes'][_0x589993('0x5d')]?_0x108ae3[_0x589993('0x6f')]:_0x2a77c7[_0x589993('0x55')],typeof _0x3cc6ba[_0x589993('0x67')][_0x589993('0x1a')]==='undefined'&&(_0x108ae3[_0x589993('0x7e')]=qs['limit'](_0x3cc6ba[_0x589993('0x67')][_0x589993('0x7e')]),_0x108ae3['offset']=qs[_0x589993('0x18')](_0x3cc6ba['query'][_0x589993('0x18')])),_0x108ae3['order']=qs['sort'](_0x3cc6ba[_0x589993('0x67')][_0x589993('0x42')]),_0x108ae3['where']=qs['filters'](_[_0x589993('0x6b')](_0x3cc6ba[_0x589993('0x67')],_0x2a77c7[_0x589993('0x1')])),_0x108ae3[_0x589993('0x7a')]['OpenchannelAccountId']=_0x5156d8['id'],_0x3cc6ba[_0x589993('0x67')][_0x589993('0x48')]&&(_0x108ae3[_0x589993('0x7a')]=_[_0x589993('0x2b')](_0x108ae3[_0x589993('0x7a')],{[Op['or']]:_[_0x589993('0x53')](_0x108ae3[_0x589993('0x6f')],function(_0x392d39){const _0x995db2=_0x589993,_0x461676={};return _0x461676[_0x392d39]={[Op[_0x995db2('0x72')]]:'%'+_0x3cc6ba[_0x995db2('0x67')][_0x995db2('0x48')]+'%'},_0x461676;})})),_0x108ae3=_['merge']({},_0x108ae3,_0x3cc6ba['options']),db[_0x589993('0x84')][_0x589993('0x86')]({'where':_0x108ae3[_0x589993('0x7a')]})[_0x589993('0x2')](function(_0x4c745d){const _0x38fb34=_0x589993;return _0x6e5662[_0x38fb34('0x86')]=_0x4c745d,_0x3cc6ba[_0x38fb34('0x67')][_0x38fb34('0x79')]&&(_0x108ae3['include']=[{'all':!![]}]),db[_0x38fb34('0x84')]['findAll'](_0x108ae3);})[_0x589993('0x2')](function(_0x3fee7f){return _0x6e5662['rows']=_0x3fee7f,_0x6e5662;});})[_0xf7b19b('0x2')](respondWithFilteredResult(_0x375772,_0x108ae3))[_0xf7b19b('0x4a')](handleError(_0x375772,null));},exports[_0x3304db('0x4c')]=function(_0x387386,_0x90ac49){const _0x3ed49f=_0x3304db;return db[_0x3ed49f('0x93')][_0x3ed49f('0x5c')]({'where':{'id':_0x387386[_0x3ed49f('0x9e')]['id']}})['then'](handleEntityNotFound(_0x90ac49,null))[_0x3ed49f('0x2')](function(_0x26211a){const _0x534276=_0x3ed49f;if(_0x26211a)return _0x26211a[_0x534276('0x4c')](_0x387386['query'][_0x534276('0x13')]);})[_0x3ed49f('0x2')](respondWithStatusCode(_0x90ac49,null))[_0x3ed49f('0x4a')](handleError(_0x90ac49,null));},exports[_0x3304db('0x66')]=function(_0x265231,_0x3f23e6){const _0x278201=_0x3304db,_0x56e705={'body':_0x265231[_0x278201('0x2f')],'channel':_0x278201('0x73')};let _0x5f02c1=[],_0x29bfc3=[];const _0xbaa02={};let _0x20531c=![];return db[_0x278201('0x8c')][_0x278201('0xe')]()[_0x278201('0x2')](function(_0x357dba){const _0x24e315=_0x278201;if(!_0x357dba)throw new ValidationError(_0x24e315('0x62'));_0x5f02c1=_['difference'](_[_0x24e315('0x3f')](_0x357dba),[_0x24e315('0x7'),'updatedAt']),_0x29bfc3=_['difference'](_['keys'](_0x357dba),[_0x24e315('0x7'),_0x24e315('0x9c'),_0x24e315('0x27'),_0x24e315('0x9a')]);_0x265231[_0x24e315('0x2f')]['id']&&delete _0x265231[_0x24e315('0x2f')]['id'];if(_[_0x24e315('0x54')](_0x265231[_0x24e315('0x2f')][_0x24e315('0x88')]))throw new ValidationError(_0x24e315('0xa0'));if(_[_0x24e315('0x54')](_0x265231[_0x24e315('0x2f')][_0x24e315('0x2f')])||_0x265231[_0x24e315('0x2f')][_0x24e315('0x2f')]==='')throw new ValidationError(_0x24e315('0x94'));if(_[_0x24e315('0x54')](_0x265231['body'][_0x24e315('0x15')]))throw new ValidationError(_0x24e315('0x31')+_0x29bfc3);if(!_[_0x24e315('0x3b')](_0x29bfc3,_0x265231['body'][_0x24e315('0x15')]))throw new ValidationError(_0x24e315('0x8b')+_0x29bfc3);_0xbaa02[_0x265231['body'][_0x24e315('0x15')]]=_0x265231[_0x24e315('0x2f')]['from'];})[_0x278201('0x2')](function(){const _0x1175c5=_0x278201;return db[_0x1175c5('0x93')][_0x1175c5('0x5c')]({'where':{'id':_0x265231[_0x1175c5('0x9e')]['id']},'include':[{'model':db[_0x1175c5('0x9f')],'as':_0x1175c5('0x96'),'include':[{'model':db[_0x1175c5('0x8c')],'as':'Contacts','where':_0xbaa02,'limit':0x1,'order':[[_0x1175c5('0x9c'),_0x1175c5('0x46')]]}]},{'model':db[_0x1175c5('0x99')],'as':'Applications'}]});})[_0x278201('0x2')](handleEntityNotFound(_0x3f23e6,null))['then'](function(_0x3e751c){const _0x268af6=_0x278201;if(_0x3e751c&&_0x3e751c[_0x268af6('0x96')]){_0x56e705[_0x268af6('0x7d')]=_0x3e751c,_0x56e705['applications']=_0x3e751c[_0x268af6('0x75')],_0x56e705[_0x268af6('0x68')]=_0x3e751c[_0x268af6('0x96')],_0x56e705[_0x268af6('0x43')]=_['orderBy'](_0x56e705[_0x268af6('0x43')],['priority'],[_0x268af6('0x4')]);_0x56e705['account'][_0x268af6('0x75')]&&delete _0x56e705[_0x268af6('0x7d')][_0x268af6('0x75')];if(_0x56e705['account'][_0x268af6('0x96')]&&_0x56e705[_0x268af6('0x7d')][_0x268af6('0x96')][_0x268af6('0x60')][_0x268af6('0x5d')])return _0x56e705[_0x268af6('0x7d')][_0x268af6('0x96')]['Contacts'][0x0];const _0x21dd5a=_[_0x268af6('0x4d')](_0x265231[_0x268af6('0x2f')],{'firstName':_0x265231['body']['from'],'ListId':_0x3e751c['ListId']});return _0x21dd5a[_0x265231['body'][_0x268af6('0x15')]]=_0x265231['body'][_0x268af6('0x88')],db[_0x268af6('0x8c')][_0x268af6('0x34')](_0x21dd5a,{'fields':_0x5f02c1,'raw':!![]});}})[_0x278201('0x2')](handleEntityNotFound(_0x3f23e6,null))['then'](function(_0xf3cd1f){const _0x421d5d=_0x278201;_0x56e705[_0x421d5d('0x49')]=_0xf3cd1f;if(_0xf3cd1f){const _0x18a5bd={'ContactId':_0xf3cd1f['id'],'OpenchannelAccountId':_0x265231[_0x421d5d('0x9e')]['id'],'from':(_0xf3cd1f[_0x421d5d('0x5e')]||'')+'\x20'+(_0xf3cd1f[_0x421d5d('0x8e')]||'')},_0x4f7b8d={'OpenchannelAccountId':_0x265231[_0x421d5d('0x9e')]['id'],'closed':![]};if(_0x265231[_0x421d5d('0x2f')]['threadId'])return _0x4f7b8d[_0x421d5d('0xa3')]=_0x265231['body']['threadId'],db[_0x421d5d('0x6d')]['findOne']({'where':_0x4f7b8d})[_0x421d5d('0x2')](function(_0x1ae60f){const _0x146798=_0x421d5d;if(_0x1ae60f)return[_0x1ae60f,![]];return _0x18a5bd[_0x146798('0xa3')]=_0x265231[_0x146798('0x2f')][_0x146798('0xa3')],_0x18a5bd[_0x146798('0x2d')]=_0x265231[_0x146798('0x2f')][_0x146798('0x2d')],db[_0x146798('0x6d')][_0x146798('0x34')](_0x18a5bd)[_0x146798('0x2')](function(_0x1e5735){return[_0x1e5735,!![]];});});else _0x4f7b8d[_0x421d5d('0xa3')]=null;return _0x4f7b8d[_0x421d5d('0x5')]=_0xf3cd1f['id'],db[_0x421d5d('0x6d')][_0x421d5d('0x5c')]({'where':_0x4f7b8d})[_0x421d5d('0x2')](function(_0x19fdb2){const _0x4a6143=_0x421d5d;if(_0x19fdb2)return[_0x19fdb2,![]];return db[_0x4a6143('0x6d')][_0x4a6143('0x34')](_0x18a5bd)[_0x4a6143('0x2')](function(_0x457cad){return[_0x457cad,!![]];});});}})[_0x278201('0x2')](function([_0x488b17,_0x527b0c]){const _0x454580=_0x278201;if(_0x488b17){_0x20531c=_0x527b0c;if(!_0x527b0c){const _0x5accf0={'from':(_0x56e705[_0x454580('0x49')]['firstName']||'')+'\x20'+(_0x56e705[_0x454580('0x49')][_0x454580('0x8e')]||'')};return _0x265231[_0x454580('0x2f')][_0x454580('0xa3')]&&_0x265231[_0x454580('0x2f')]['messageId']&&_0x265231[_0x454580('0x2f')][_0x454580('0xa3')]!=_0x265231[_0x454580('0x2f')][_0x454580('0xa')]&&(_0x5accf0[_0x454580('0xa3')]=_0x265231[_0x454580('0x2f')][_0x454580('0xa')]),_0x488b17[_0x454580('0x23')](_0x5accf0);}else return _0x488b17;}})[_0x278201('0x2')](function(_0x52ca4c){const _0x18c1ac=_0x278201;return _0x56e705['interaction']=_0x52ca4c[_0x18c1ac('0x91')]({'plain':!![]}),_0x56e705[_0x18c1ac('0x21')][_0x18c1ac('0x2e')]=_0x20531c,_0x56e705[_0x18c1ac('0x21')]['created']&&(_0x56e705[_0x18c1ac('0x7d')]['autoclose']&&_0x56e705[_0x18c1ac('0x43')][_0x18c1ac('0x71')]({'id':0x0,'priority':_0x56e705[_0x18c1ac('0x43')]['length']+0x1,'app':_0x18c1ac('0x3a'),'appdata':_0x18c1ac('0x7f'),'interval':_0x18c1ac('0x38')})),db[_0x18c1ac('0x47')]['create']({'body':_0x265231[_0x18c1ac('0x2f')][_0x18c1ac('0x2f')],'OpenchannelAccountId':_0x265231['params']['id'],'OpenchannelInteractionId':_0x52ca4c['id'],'direction':'in','ContactId':_0x56e705[_0x18c1ac('0x49')]['id'],'AttachmentId':_0x265231[_0x18c1ac('0x2f')]['AttachmentId']});})[_0x278201('0x2')](function(_0x122dfc){const _0x3e7cbb=_0x278201;_0x56e705[_0x3e7cbb('0x36')]=_0x122dfc;if(_0x56e705[_0x3e7cbb('0x21')][_0x3e7cbb('0x22')])return db[_0x3e7cbb('0x32')][_0x3e7cbb('0x5c')]({'attributes':['id','name'],'where':{'id':_0x56e705[_0x3e7cbb('0x21')][_0x3e7cbb('0x22')]}})[_0x3e7cbb('0x2')](function(_0x25b156){const _0x42e6b5=_0x3e7cbb;return _0x25b156&&(_0x56e705[_0x42e6b5('0x43')][_0x42e6b5('0x7b')]({'id':0x0,'priority':0x0,'app':_0x42e6b5('0x95'),'appdata':_0x25b156['name']+','+(_0x56e705[_0x42e6b5('0x7d')][_0x42e6b5('0x90')]||0xa),'interval':_0x42e6b5('0x38')}),_0x56e705[_0x42e6b5('0x3c')]=![]),respondWithRpcPromise(_0x42e6b5('0x25'),_0x42e6b5('0x19'),_0x56e705);});return respondWithRpcPromise(_0x3e7cbb('0x25'),_0x3e7cbb('0x19'),_0x56e705);})[_0x278201('0x2')](function(_0x1d04aa){const _0x537e7a=_0x278201;return respondWithRpcPromise(_0x537e7a('0x9b'),_0x537e7a('0x9b'),{'event':'notify','message':_0x1d04aa},client9002),_0x1d04aa;})[_0x278201('0x2')](respondWithResult(_0x3f23e6,null))[_0x278201('0x4a')](handleError(_0x3f23e6,null));},exports[_0x3304db('0x35')]=function(_0x3a4169,_0x18ec70){const _0xd1de87=_0x3304db;return db[_0xd1de87('0x93')][_0xd1de87('0x5c')]({'where':{'id':_0x3a4169[_0xd1de87('0x9e')]['id']}})[_0xd1de87('0x2')](handleEntityNotFound(_0x18ec70,null))['then'](function(_0x47c5bb){const _0x3fdd28=_0xd1de87;if(_0x47c5bb)return db[_0x3fdd28('0x52')][_0x3fdd28('0x1c')](function(_0x12ae04){const _0x4753b8=_0x3fdd28;return db[_0x4753b8('0x99')][_0x4753b8('0x30')]({'where':{'OpenchannelAccountId':_0x3a4169[_0x4753b8('0x9e')]['id']},'transaction':_0x12ae04})[_0x4753b8('0x2')](function(){const _0x27f431=_0x4753b8,_0x5d74a0=_[_0x27f431('0x53')](_0x3a4169[_0x27f431('0x2f')],function(_0x2ddf7f){const _0x4d4ff1=_0x27f431;return _0x2ddf7f[_0x4d4ff1('0x10')]=_0x3a4169[_0x4d4ff1('0x9e')]['id'],_0x2ddf7f;});return db[_0x27f431('0x99')][_0x27f431('0x74')](_0x5d74a0,{'transaction':_0x12ae04});});})[_0x3fdd28('0x2')](function(){const _0x47bf58=_0x3fdd28;return db['OpenchannelApplication'][_0x47bf58('0x5f')]({'where':{'OpenchannelAccountId':_0x3a4169[_0x47bf58('0x9e')]['id']},'order':_0x47bf58('0x28')});});})[_0xd1de87('0x2')](respondWithResult(_0x18ec70,null))[_0xd1de87('0x4a')](handleError(_0x18ec70,null));},exports[_0x3304db('0x87')]=function(_0x18b333,_0x4ccf24){const _0x479ce3=_0x3304db;let _0x556f8f={};const _0x350236={};let _0x3e931a,_0x6cf2c7;return db['OpenchannelAccount'][_0x479ce3('0x5c')]({'where':{'id':_0x18b333[_0x479ce3('0x9e')]['id']}})['then'](handleEntityNotFound(_0x4ccf24,null))[_0x479ce3('0x2')](function(_0x37a0f2){const _0x53aba3=_0x479ce3;if(_0x37a0f2)return _0x3e931a=_0x37a0f2,_0x350236['model']=_['keys'](db[_0x53aba3('0x99')]['rawAttributes']),_0x350236[_0x53aba3('0x67')]=_[_0x53aba3('0x3f')](_0x18b333[_0x53aba3('0x67')]),_0x350236['filters']=_[_0x53aba3('0x4e')](_0x350236[_0x53aba3('0x55')],_0x350236[_0x53aba3('0x67')]),_0x556f8f[_0x53aba3('0x6f')]=_[_0x53aba3('0x4e')](_0x350236[_0x53aba3('0x55')],qs['fields'](_0x18b333['query'][_0x53aba3('0x33')])),_0x556f8f[_0x53aba3('0x6f')]=_0x556f8f['attributes']['length']?_0x556f8f[_0x53aba3('0x6f')]:_0x350236[_0x53aba3('0x55')],_0x556f8f[_0x53aba3('0x76')]=qs[_0x53aba3('0x42')](_0x18b333[_0x53aba3('0x67')][_0x53aba3('0x42')]),_0x556f8f[_0x53aba3('0x7a')]=qs['filters'](_[_0x53aba3('0x6b')](_0x18b333['query'],_0x350236[_0x53aba3('0x1')])),_0x18b333['query'][_0x53aba3('0x48')]&&(_0x556f8f['where']=_[_0x53aba3('0x2b')](_0x556f8f[_0x53aba3('0x7a')],{[Op['or']]:_['map'](_0x556f8f[_0x53aba3('0x6f')],function(_0x4cad12){const _0x4adaaa=_0x53aba3,_0x55b4b9={};return _0x55b4b9[_0x4cad12]={[Op['like']]:'%'+_0x18b333[_0x4adaaa('0x67')][_0x4adaaa('0x48')]+'%'},_0x55b4b9;})})),_0x556f8f=_[_0x53aba3('0x2b')]({},_0x556f8f,_0x18b333[_0x53aba3('0x57')]),_0x3e931a['getApplications'](_0x556f8f);})[_0x479ce3('0x2')](function(_0x39aa52){const _0x5a54f7=_0x479ce3;if(_0x39aa52)return _0x6cf2c7=_0x39aa52[_0x5a54f7('0x5d')],typeof _0x18b333[_0x5a54f7('0x67')][_0x5a54f7('0x1a')]===_0x5a54f7('0x81')&&(_0x556f8f['limit']=qs[_0x5a54f7('0x7e')](_0x18b333[_0x5a54f7('0x67')][_0x5a54f7('0x7e')]),_0x556f8f[_0x5a54f7('0x18')]=qs[_0x5a54f7('0x18')](_0x18b333['query'][_0x5a54f7('0x18')])),_0x3e931a[_0x5a54f7('0x87')](_0x556f8f);})[_0x479ce3('0x2')](function(_0xe66a68){if(_0xe66a68)return _0xe66a68?{'count':_0x6cf2c7,'rows':_0xe66a68}:null;})[_0x479ce3('0x2')](respondWithResult(_0x4ccf24,null))[_0x479ce3('0x4a')](handleError(_0x4ccf24,null));},exports['getInteractions']=function(_0x24cfa5,_0x3df241){const _0x438c78=_0x3304db;let _0x504f83={'raw':![],'where':{}};const _0x289fad={},_0x4f1c0e={'count':0x0,'rows':[]};return db[_0x438c78('0x93')][_0x438c78('0x5c')]({'where':{'id':_0x24cfa5[_0x438c78('0x9e')]['id']}})['then'](handleEntityNotFound(_0x3df241,null))[_0x438c78('0x2')](function(_0x22b1ee){const _0x46748f=_0x438c78;if(_0x22b1ee)return _0x289fad[_0x46748f('0x55')]=_[_0x46748f('0x3f')](db[_0x46748f('0x6d')][_0x46748f('0x37')]),_0x289fad['query']=_[_0x46748f('0x3f')](_0x24cfa5[_0x46748f('0x67')]),_0x289fad[_0x46748f('0x1')]=_[_0x46748f('0x4e')](_0x289fad['model'],_0x289fad[_0x46748f('0x67')]),_0x504f83[_0x46748f('0x6f')]=_[_0x46748f('0x4e')](_0x289fad[_0x46748f('0x55')],qs[_0x46748f('0x33')](_0x24cfa5[_0x46748f('0x67')][_0x46748f('0x33')])),_0x504f83[_0x46748f('0x6f')]=_0x504f83[_0x46748f('0x6f')][_0x46748f('0x5d')]?_0x504f83['attributes']:_0x289fad[_0x46748f('0x55')],typeof _0x24cfa5[_0x46748f('0x67')][_0x46748f('0x1a')]==='undefined'&&(_0x504f83[_0x46748f('0x7e')]=qs[_0x46748f('0x7e')](_0x24cfa5['query']['limit']),_0x504f83['offset']=qs['offset'](_0x24cfa5[_0x46748f('0x67')][_0x46748f('0x18')])),_0x504f83[_0x46748f('0x76')]=qs['sort'](_0x24cfa5[_0x46748f('0x67')]['sort']),_0x504f83[_0x46748f('0x7a')]=qs[_0x46748f('0x1')](_[_0x46748f('0x6b')](_0x24cfa5[_0x46748f('0x67')],_0x289fad['filters'])),_0x504f83['where'][_0x46748f('0x10')]=_0x22b1ee['id'],_0x24cfa5[_0x46748f('0x67')][_0x46748f('0x48')]&&(_0x504f83[_0x46748f('0x7a')]=_[_0x46748f('0x2b')](_0x504f83[_0x46748f('0x7a')],{[Op['or']]:_[_0x46748f('0x53')](_0x504f83[_0x46748f('0x6f')],function(_0x19f59c){const _0xbb9790=_0x46748f,_0x17fd33={};return _0x17fd33[_0x19f59c]={[Op[_0xbb9790('0x72')]]:'%'+_0x24cfa5[_0xbb9790('0x67')][_0xbb9790('0x48')]+'%'},_0x17fd33;})})),_0x504f83=_[_0x46748f('0x2b')]({},_0x504f83,_0x24cfa5[_0x46748f('0x57')]),db[_0x46748f('0x6d')][_0x46748f('0x86')]({'where':_0x504f83[_0x46748f('0x7a')]})[_0x46748f('0x2')](function(_0x32f822){const _0x1b52bb=_0x46748f;return _0x4f1c0e[_0x1b52bb('0x86')]=_0x32f822,_0x24cfa5[_0x1b52bb('0x67')][_0x1b52bb('0x79')]&&(_0x504f83[_0x1b52bb('0xb')]=[{'model':db[_0x1b52bb('0x8c')],'as':_0x1b52bb('0x11'),'required':![]},{'model':db['User'],'as':_0x1b52bb('0x78'),'attributes':[_0x1b52bb('0xf'),_0x1b52bb('0x58'),_0x1b52bb('0x8a')],'required':![]},{'model':db[_0x1b52bb('0x70')],'as':'Tags','attributes':['id','name',_0x1b52bb('0x97')],'where':_0x24cfa5[_0x1b52bb('0x67')][_0x1b52bb('0x80')]?{'id':_0x24cfa5['query']['tag']}:undefined,'required':_0x24cfa5[_0x1b52bb('0x67')][_0x1b52bb('0x80')]?!![]:![]}]),db[_0x1b52bb('0x6d')]['findAll'](_0x504f83);})['then'](function(_0x1e961c){const _0x562ccc=_0x46748f;return _0x4f1c0e[_0x562ccc('0x61')]=_0x1e961c,_0x4f1c0e;});})[_0x438c78('0x2')](respondWithFilteredResult(_0x3df241,_0x504f83))[_0x438c78('0x4a')](handleError(_0x3df241,null));},exports['addAgents']=function(_0x2642c7,_0x24b7a1){const _0x2a3053=_0x3304db;return db[_0x2a3053('0x93')][_0x2a3053('0x5c')]({'where':{'id':_0x2642c7[_0x2a3053('0x9e')]['id']}})[_0x2a3053('0x2')](function(_0x389738){const _0x1f6da3=_0x2a3053;if(_0x389738)return _0x389738[_0x1f6da3('0x2a')](_0x2642c7[_0x1f6da3('0x2f')][_0x1f6da3('0x13')],{'through':_[_0x1f6da3('0x4f')](_0x2642c7[_0x1f6da3('0x2f')],[_0x1f6da3('0x13'),'id'])})[_0x1f6da3('0x2')](function(_0x5db9a6){const _0x4e9902=_0x1f6da3;for(let _0x59be73=0x0;_0x59be73<_0x2642c7[_0x4e9902('0x2f')][_0x4e9902('0x13')]['length'];_0x59be73+=0x1){socket[_0x4e9902('0x14')](_0x4e9902('0x1f'),{'UserId':_0x2642c7[_0x4e9902('0x2f')][_0x4e9902('0x13')][_0x59be73],'OpenchannelAccountId':_0x2642c7[_0x4e9902('0x9e')]['id']});}return _0x5db9a6;});})[_0x2a3053('0x2')](respondWithResult(_0x24b7a1,null))[_0x2a3053('0x4a')](handleError(_0x24b7a1,null));},exports['removeAgents']=function(_0x182db0,_0x2e5af8){const _0x13a360=_0x3304db;return db[_0x13a360('0x93')][_0x13a360('0x5c')]({'where':{'id':_0x182db0[_0x13a360('0x9e')]['id']}})[_0x13a360('0x2')](handleEntityNotFound(_0x2e5af8,null))['then'](function(_0x120f6f){const _0x972e5b=_0x13a360;if(_0x120f6f)return _0x120f6f[_0x972e5b('0x9')](_0x182db0['query'][_0x972e5b('0x13')])['then'](function(){const _0x2357d9=_0x972e5b;if(_[_0x2357d9('0x8')](_0x182db0[_0x2357d9('0x67')][_0x2357d9('0x13')]))for(let _0x2359c3=0x0;_0x2359c3<_0x182db0[_0x2357d9('0x67')][_0x2357d9('0x13')][_0x2357d9('0x5d')];_0x2359c3+=0x1){socket[_0x2357d9('0x14')](_0x2357d9('0x39'),{'UserId':Number(_0x182db0[_0x2357d9('0x67')]['ids'][_0x2359c3]),'OpenchannelAccountId':Number(_0x182db0['params']['id'])});}else socket[_0x2357d9('0x14')](_0x2357d9('0x39'),{'UserId':Number(_0x182db0[_0x2357d9('0x67')][_0x2357d9('0x13')]),'OpenchannelAccountId':Number(_0x182db0[_0x2357d9('0x9e')]['id'])});});})[_0x13a360('0x2')](respondWithStatusCode(_0x2e5af8,null))[_0x13a360('0x4a')](handleError(_0x2e5af8,null));},exports['getAgents']=function(_0x21b448,_0x112254){const _0x57efeb=_0x3304db;let _0x26df44={};const _0x217678={};let _0x180548,_0x330164;return db[_0x57efeb('0x93')][_0x57efeb('0x5c')]({'where':{'id':_0x21b448['params']['id']}})[_0x57efeb('0x2')](handleEntityNotFound(_0x112254,null))[_0x57efeb('0x2')](function(_0x344b91){const _0x387f07=_0x57efeb;if(_0x344b91)return _0x180548=_0x344b91,_0x217678['model']=_[_0x387f07('0x3f')](db[_0x387f07('0x32')]['rawAttributes']),_0x217678[_0x387f07('0x67')]=_['keys'](_0x21b448[_0x387f07('0x67')]),_0x217678[_0x387f07('0x1')]=_[_0x387f07('0x4e')](_0x217678[_0x387f07('0x55')],_0x217678[_0x387f07('0x67')]),_0x26df44[_0x387f07('0x6f')]=_['intersection'](_0x217678[_0x387f07('0x55')],qs[_0x387f07('0x33')](_0x21b448[_0x387f07('0x67')][_0x387f07('0x33')])),_0x26df44[_0x387f07('0x6f')]=_0x26df44[_0x387f07('0x6f')][_0x387f07('0x5d')]?_0x26df44[_0x387f07('0x6f')]:_0x217678['model'],_0x26df44[_0x387f07('0x76')]=qs[_0x387f07('0x42')](_0x21b448[_0x387f07('0x67')]['sort']),_0x26df44[_0x387f07('0x7a')]=qs[_0x387f07('0x1')](_[_0x387f07('0x6b')](_0x21b448[_0x387f07('0x67')],_0x217678[_0x387f07('0x1')])),_0x21b448[_0x387f07('0x67')][_0x387f07('0x48')]&&(_0x26df44[_0x387f07('0x7a')]=_[_0x387f07('0x2b')](_0x26df44['where'],{[Op['or']]:_[_0x387f07('0x53')](_0x26df44[_0x387f07('0x6f')],function(_0x41f1a6){const _0x49e197=_0x387f07,_0x8beae7={};return _0x8beae7[_0x41f1a6]={[Op[_0x49e197('0x72')]]:'%'+_0x21b448[_0x49e197('0x67')][_0x49e197('0x48')]+'%'},_0x8beae7;})})),_0x26df44=_[_0x387f07('0x2b')]({},_0x26df44,_0x21b448[_0x387f07('0x57')]),_0x180548[_0x387f07('0x45')](_0x26df44);})['then'](function(_0x4e9c92){const _0x160455=_0x57efeb;if(_0x4e9c92)return _0x330164=_0x4e9c92[_0x160455('0x5d')],typeof _0x21b448[_0x160455('0x67')][_0x160455('0x1a')]==='undefined'&&(_0x26df44[_0x160455('0x7e')]=qs[_0x160455('0x7e')](_0x21b448[_0x160455('0x67')][_0x160455('0x7e')]),_0x26df44['offset']=qs[_0x160455('0x18')](_0x21b448[_0x160455('0x67')][_0x160455('0x18')])),_0x180548['getAgents'](_0x26df44);})['then'](function(_0x59c2a9){if(_0x59c2a9)return _0x59c2a9?{'count':_0x330164,'rows':_0x59c2a9}:null;})[_0x57efeb('0x2')](respondWithResult(_0x112254,null))[_0x57efeb('0x4a')](handleError(_0x112254,null));},exports[_0x3304db('0x9d')]=function(_0x4cb3d9,_0x4e9901){const _0x29ade4=_0x3304db;let _0x2a6a7e,_0x5cb6be;if(_[_0x29ade4('0x54')](_0x4cb3d9[_0x29ade4('0x2f')][_0x29ade4('0x2f')])||_0x4cb3d9[_0x29ade4('0x2f')][_0x29ade4('0x2f')]==='')throw new ValidationError(_0x29ade4('0x94'));if(_[_0x29ade4('0x54')](_0x4cb3d9[_0x29ade4('0x2f')]['to'])){}const _0x1091a3=_0x4cb3d9['body']['to'];return db['OpenchannelAccount']['findOne']({'where':{'id':_0x4cb3d9[_0x29ade4('0x9e')]['id']}})['then'](handleEntityNotFound(_0x4e9901,null))[_0x29ade4('0x2')](function(_0x593144){const _0x3931d5=_0x29ade4;if(_0x593144)return db[_0x3931d5('0x93')][_0x3931d5('0x5c')]({'where':{'id':_0x593144['id']},'include':[{'model':db[_0x3931d5('0x9f')],'as':'List','include':[{'model':db[_0x3931d5('0x8c')],'as':_0x3931d5('0x60'),'where':{[_0x593144[_0x3931d5('0x15')]]:_0x1091a3},'limit':0x1,'order':[[_0x3931d5('0x9c'),_0x3931d5('0x46')]]}]}]})['then'](handleEntityNotFound(_0x4e9901,null))[_0x3931d5('0x2')](function(_0x4bf863){const _0xadf75c=_0x3931d5;if(_0x4bf863&&_0x4bf863[_0xadf75c('0x96')]){_0x2a6a7e=_0x4bf863[_0xadf75c('0x91')]({'plain':!![]});if(_0x2a6a7e[_0xadf75c('0x96')]&&_0x2a6a7e[_0xadf75c('0x96')][_0xadf75c('0x60')]['length'])return _0x2a6a7e[_0xadf75c('0x96')][_0xadf75c('0x60')][0x0];return db['CmContact']['create'](_[_0xadf75c('0x4d')](_0x4cb3d9[_0xadf75c('0x2f')],{'firstName':_0x1091a3,[_0x4bf863[_0xadf75c('0x15')]]:_0x1091a3,'phone':_0x1091a3,'ListId':_0x2a6a7e[_0xadf75c('0x9a')]}));}})[_0x3931d5('0x2')](handleEntityNotFound(_0x4e9901,null))[_0x3931d5('0x2')](function(_0x2c4f07){const _0xedc1a3=_0x3931d5;if(_0x2c4f07)return _0x5cb6be=_0x2c4f07,db['OpenchannelInteraction'][_0xedc1a3('0x5c')]({'where':{'ContactId':_0x5cb6be['id'],'closed':![],'OpenchannelAccountId':_0x2a6a7e['id']}})['then'](function(_0x57c091){const _0x1fc6f1=_0xedc1a3;if(_0x57c091)return[_0x57c091,![]];return db[_0x1fc6f1('0x6d')]['create']({'UserId':_0x4cb3d9[_0x1fc6f1('0x12')]['id'],'ContactId':_0x5cb6be['id'],'OpenchannelAccountId':_0x2a6a7e['id'],'lastMsgDirection':_0x1fc6f1('0x98'),'Messages':[_[_0x1fc6f1('0x2b')](_0x4cb3d9[_0x1fc6f1('0x2f')],{'read':![],'body':_0x4cb3d9[_0x1fc6f1('0x2f')][_0x1fc6f1('0x2f')],'OpenchannelAccountId':_0x2a6a7e['id'],'UserId':_0x4cb3d9[_0x1fc6f1('0x12')]['id'],'ContactId':_0x5cb6be['id']})]},{'include':[{'model':db[_0x1fc6f1('0x47')],'as':_0x1fc6f1('0x8d')}]})[_0x1fc6f1('0x2')](function(_0x18322d){return[_0x18322d,!![]];});});})[_0x3931d5('0x2')](function([_0x27eafd,_0x14dada]){const _0x1b7c2f=_0x3931d5;if(_0x14dada)return _0x27eafd;return db[_0x1b7c2f('0x47')][_0x1b7c2f('0x34')](_[_0x1b7c2f('0x2b')](_0x4cb3d9[_0x1b7c2f('0x2f')],{'read':![],'body':_0x4cb3d9[_0x1b7c2f('0x2f')][_0x1b7c2f('0x2f')],'OpenchannelAccountId':_0x2a6a7e['id'],'OpenchannelInteractionId':_0x27eafd['id'],'UserId':_0x4cb3d9[_0x1b7c2f('0x12')]['id'],'ContactId':_0x5cb6be['id']}))[_0x1b7c2f('0x2')](function(_0x3a2bf4){const _0x287acb=_0x1b7c2f;return _0x27eafd[_0x287acb('0x5b')]['Messages']=[],_0x27eafd[_0x287acb('0x5b')][_0x287acb('0x8d')]['push'](_0x3a2bf4[_0x287acb('0x5b')]),_0x27eafd;});});})['then'](respondWithResult(_0x4e9901,null))['catch'](handleError(_0x4e9901,null));}; \ No newline at end of file diff --git a/server/api/openchannelAccount/openchannelAccount.events.js b/server/api/openchannelAccount/openchannelAccount.events.js index 120e0fe..9265d5f 100644 --- a/server/api/openchannelAccount/openchannelAccount.events.js +++ b/server/api/openchannelAccount/openchannelAccount.events.js @@ -1 +1 @@ -const a469_0x5435=['remove','addHook','emit','../../mysqldb','update','save','events','undefined','exports','setMaxListeners'];(function(_0xc769cb,_0x5435fb){const _0x3d4b2f=function(_0xa86229){while(--_0xa86229){_0xc769cb['push'](_0xc769cb['shift']());}};_0x3d4b2f(++_0x5435fb);}(a469_0x5435,0x76));const a469_0x3d4b=function(_0xc769cb,_0x5435fb){_0xc769cb=_0xc769cb-0x0;let _0x3d4b2f=a469_0x5435[_0xc769cb];return _0x3d4b2f;};const _0x43701f=a469_0x3d4b;'use strict';const EventEmitter=require(_0x43701f('0x8')),OpenchannelAccount=require(_0x43701f('0x5'))['db']['OpenchannelAccount'],OpenchannelAccountEvents=new EventEmitter();OpenchannelAccountEvents[_0x43701f('0x1')](0x0);const events={'afterCreate':_0x43701f('0x7'),'afterUpdate':_0x43701f('0x6'),'afterDestroy':_0x43701f('0x2')};function emitEvent(_0xa86229){return function(_0x47523d){const _0x465b56=a469_0x3d4b;OpenchannelAccountEvents[_0x465b56('0x4')](_0xa86229+':'+_0x47523d['id'],_0x47523d),OpenchannelAccountEvents[_0x465b56('0x4')](_0xa86229,_0x47523d);};}for(const e in events){if(typeof events[e]!==_0x43701f('0x9')){const event=events[e];OpenchannelAccount[_0x43701f('0x3')](e,emitEvent(event));}}module[_0x43701f('0x0')]=OpenchannelAccountEvents; \ No newline at end of file +const a469_0x50f4=['exports','addHook','events','remove','../../mysqldb','setMaxListeners','undefined'];(function(_0x706cad,_0x50f4d2){const _0x320b03=function(_0x5aafb9){while(--_0x5aafb9){_0x706cad['push'](_0x706cad['shift']());}};_0x320b03(++_0x50f4d2);}(a469_0x50f4,0x7a));const a469_0x320b=function(_0x706cad,_0x50f4d2){_0x706cad=_0x706cad-0x0;let _0x320b03=a469_0x50f4[_0x706cad];return _0x320b03;};const _0xd7e1de=a469_0x320b;'use strict';const EventEmitter=require(_0xd7e1de('0x6')),OpenchannelAccount=require(_0xd7e1de('0x1'))['db']['OpenchannelAccount'],OpenchannelAccountEvents=new EventEmitter();OpenchannelAccountEvents[_0xd7e1de('0x2')](0x0);const events={'afterCreate':'save','afterUpdate':'update','afterDestroy':_0xd7e1de('0x0')};function emitEvent(_0x5aafb9){return function(_0x1a398e){OpenchannelAccountEvents['emit'](_0x5aafb9+':'+_0x1a398e['id'],_0x1a398e),OpenchannelAccountEvents['emit'](_0x5aafb9,_0x1a398e);};}for(const e in events){if(typeof events[e]!==_0xd7e1de('0x3')){const event=events[e];OpenchannelAccount[_0xd7e1de('0x5')](e,emitEvent(event));}}module[_0xd7e1de('0x4')]=OpenchannelAccountEvents; \ No newline at end of file diff --git a/server/api/openchannelAccount/openchannelAccount.model.js b/server/api/openchannelAccount/openchannelAccount.model.js index b692d6a..f46dde4 100644 --- a/server/api/openchannelAccount/openchannelAccount.model.js +++ b/server/api/openchannelAccount/openchannelAccount.model.js @@ -1 +1 @@ -const a470_0xa005=['OpenchannelAccount','define','openchannel_accounts','exports','./openchannelAccount.attributes'];(function(_0x352f43,_0xa0058b){const _0x4c2b7f=function(_0x4266db){while(--_0x4266db){_0x352f43['push'](_0x352f43['shift']());}};_0x4c2b7f(++_0xa0058b);}(a470_0xa005,0x1d6));const a470_0x4c2b=function(_0x352f43,_0xa0058b){_0x352f43=_0x352f43-0x0;let _0x4c2b7f=a470_0xa005[_0x352f43];return _0x4c2b7f;};const _0xbc0311=a470_0x4c2b;'use strict';const attributes=require(_0xbc0311('0x4'));module[_0xbc0311('0x3')]=function(_0x4266db){const _0xaca2f6=_0xbc0311,_0x466021=_0x4266db[_0xaca2f6('0x1')](_0xaca2f6('0x0'),attributes,{'tableName':_0xaca2f6('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x466021;}; \ No newline at end of file +const a470_0x1ca7=['openchannel_accounts','define','exports','./openchannelAccount.attributes'];(function(_0x545c05,_0x1ca7dd){const _0x9b864b=function(_0x932416){while(--_0x932416){_0x545c05['push'](_0x545c05['shift']());}};_0x9b864b(++_0x1ca7dd);}(a470_0x1ca7,0x107));const a470_0x9b86=function(_0x545c05,_0x1ca7dd){_0x545c05=_0x545c05-0x0;let _0x9b864b=a470_0x1ca7[_0x545c05];return _0x9b864b;};const _0x16485d=a470_0x9b86;'use strict';const attributes=require(_0x16485d('0x0'));module[_0x16485d('0x3')]=function(_0x932416){const _0x3fb54d=_0x16485d,_0x87e739=_0x932416[_0x3fb54d('0x2')]('OpenchannelAccount',attributes,{'tableName':_0x3fb54d('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x87e739;}; \ No newline at end of file diff --git a/server/api/openchannelAccount/openchannelAccount.rpc.js b/server/api/openchannelAccount/openchannelAccount.rpc.js index 07c441a..8faff1c 100644 --- a/server/api/openchannelAccount/openchannelAccount.rpc.js +++ b/server/api/openchannelAccount/openchannelAccount.rpc.js @@ -1 +1 @@ -const a471_0x48df=['../../rediscache','./openchannelAccount.socket'];(function(_0x158b8d,_0x48df85){const _0x2b391f=function(_0x368ee2){while(--_0x368ee2){_0x158b8d['push'](_0x158b8d['shift']());}};_0x2b391f(++_0x48df85);}(a471_0x48df,0x6a));const a471_0x2b39=function(_0x158b8d,_0x48df85){_0x158b8d=_0x158b8d-0x0;let _0x2b391f=a471_0x48df[_0x158b8d];return _0x2b391f;};const _0x1ba413=a471_0x2b39;'use strict';const {getSocket}=require(_0x1ba413('0x0')),socket=getSocket();require(_0x1ba413('0x1'))['register'](socket); \ No newline at end of file +const a471_0x59cd=['../../rediscache','./openchannelAccount.socket','register'];(function(_0x14a1f7,_0x59cd24){const _0x18bf44=function(_0x330605){while(--_0x330605){_0x14a1f7['push'](_0x14a1f7['shift']());}};_0x18bf44(++_0x59cd24);}(a471_0x59cd,0xc6));const a471_0x18bf=function(_0x14a1f7,_0x59cd24){_0x14a1f7=_0x14a1f7-0x0;let _0x18bf44=a471_0x59cd[_0x14a1f7];return _0x18bf44;};const _0x4e78aa=a471_0x18bf;'use strict';const {getSocket}=require(_0x4e78aa('0x0')),socket=getSocket();require(_0x4e78aa('0x1'))[_0x4e78aa('0x2')](socket); \ No newline at end of file diff --git a/server/api/openchannelAccount/openchannelAccount.socket.js b/server/api/openchannelAccount/openchannelAccount.socket.js index 5ff7b09..9736a8f 100644 --- a/server/api/openchannelAccount/openchannelAccount.socket.js +++ b/server/api/openchannelAccount/openchannelAccount.socket.js @@ -1 +1 @@ -const a472_0x51c5=['openchannelAccount:','save','./openchannelAccount.events','register','update','length'];(function(_0x414683,_0x51c5a1){const _0x1b2e75=function(_0x3603bf){while(--_0x3603bf){_0x414683['push'](_0x414683['shift']());}};_0x1b2e75(++_0x51c5a1);}(a472_0x51c5,0x19b));const a472_0x1b2e=function(_0x414683,_0x51c5a1){_0x414683=_0x414683-0x0;let _0x1b2e75=a472_0x51c5[_0x414683];return _0x1b2e75;};const _0x2f84ec=a472_0x1b2e;'use strict';const OpenchannelAccountEvents=require(_0x2f84ec('0x5')),events=[_0x2f84ec('0x4'),'remove',_0x2f84ec('0x1')];function createListener(_0x3603bf,_0x158e82){return function(_0x51d2a5){_0x158e82['emit'](_0x3603bf,_0x51d2a5);};}exports[_0x2f84ec('0x0')]=function(_0x68c82c){const _0xa18e8a=_0x2f84ec;for(let _0x3ea2a1=0x0,_0x2d38e=events[_0xa18e8a('0x2')];_0x3ea2a1<_0x2d38e;_0x3ea2a1++){const _0x37886d=events[_0x3ea2a1],_0x46b462=createListener(_0xa18e8a('0x3')+_0x37886d,_0x68c82c);OpenchannelAccountEvents['on'](_0x37886d,_0x46b462);}}; \ No newline at end of file +const a472_0x28e1=['save','length','emit','openchannelAccount:','./openchannelAccount.events','update','register','remove'];(function(_0x14dccf,_0x28e1e0){const _0x26739d=function(_0x760bbc){while(--_0x760bbc){_0x14dccf['push'](_0x14dccf['shift']());}};_0x26739d(++_0x28e1e0);}(a472_0x28e1,0xb0));const a472_0x2673=function(_0x14dccf,_0x28e1e0){_0x14dccf=_0x14dccf-0x0;let _0x26739d=a472_0x28e1[_0x14dccf];return _0x26739d;};const _0x38b968=a472_0x2673;'use strict';const OpenchannelAccountEvents=require(_0x38b968('0x4')),events=[_0x38b968('0x0'),_0x38b968('0x7'),_0x38b968('0x5')];function createListener(_0x760bbc,_0x41013d){return function(_0x92e503){const _0x1ba8dc=a472_0x2673;_0x41013d[_0x1ba8dc('0x2')](_0x760bbc,_0x92e503);};}exports[_0x38b968('0x6')]=function(_0x4ef2de){const _0xa38c13=_0x38b968;for(let _0x11449b=0x0,_0x5eccca=events[_0xa38c13('0x1')];_0x11449b<_0x5eccca;_0x11449b++){const _0x23884d=events[_0x11449b],_0x803f0c=createListener(_0xa38c13('0x3')+_0x23884d,_0x4ef2de);OpenchannelAccountEvents['on'](_0x23884d,_0x803f0c);}}; \ No newline at end of file diff --git a/server/api/openchannelApplication/index.js b/server/api/openchannelApplication/index.js index 91fb674..15c37f9 100644 --- a/server/api/openchannelApplication/index.js +++ b/server/api/openchannelApplication/index.js @@ -1 +1 @@ -const a473_0x4310=['destroy','./openchannelApplication.controller','post','create','isAuthenticated','exports','index','get','put','express','show','/:id','Router','update','../../components/auth/service'];(function(_0x422b39,_0x43103a){const _0x3d558a=function(_0x104c95){while(--_0x104c95){_0x422b39['push'](_0x422b39['shift']());}};_0x3d558a(++_0x43103a);}(a473_0x4310,0x1e6));const a473_0x3d55=function(_0x422b39,_0x43103a){_0x422b39=_0x422b39-0x0;let _0x3d558a=a473_0x4310[_0x422b39];return _0x3d558a;};const _0x3655ba=a473_0x3d55;'use strict';const express=require(_0x3655ba('0x3')),router=express[_0x3655ba('0x6')](),auth=require(_0x3655ba('0x8')),controller=require(_0x3655ba('0xa'));router['get']('/',auth[_0x3655ba('0xd')](),controller[_0x3655ba('0x0')]),router[_0x3655ba('0x1')](_0x3655ba('0x5'),auth[_0x3655ba('0xd')](),controller[_0x3655ba('0x4')]),router[_0x3655ba('0xb')]('/',auth[_0x3655ba('0xd')](),controller[_0x3655ba('0xc')]),router[_0x3655ba('0x2')](_0x3655ba('0x5'),auth[_0x3655ba('0xd')](),controller[_0x3655ba('0x7')]),router['delete']('/:id',auth[_0x3655ba('0xd')](),controller[_0x3655ba('0x9')]),module[_0x3655ba('0xe')]=router; \ No newline at end of file +const a473_0x530b=['./openchannelApplication.controller','index','/:id','create','update','show','post','put','express','exports','Router','delete','isAuthenticated','../../components/auth/service'];(function(_0x188384,_0x530b02){const _0xc803f9=function(_0x4ce1c5){while(--_0x4ce1c5){_0x188384['push'](_0x188384['shift']());}};_0xc803f9(++_0x530b02);}(a473_0x530b,0x14e));const a473_0xc803=function(_0x188384,_0x530b02){_0x188384=_0x188384-0x0;let _0xc803f9=a473_0x530b[_0x188384];return _0xc803f9;};const _0x4003f8=a473_0xc803;'use strict';const express=require(_0x4003f8('0xa')),router=express[_0x4003f8('0xc')](),auth=require(_0x4003f8('0x1')),controller=require(_0x4003f8('0x2'));router['get']('/',auth[_0x4003f8('0x0')](),controller[_0x4003f8('0x3')]),router['get'](_0x4003f8('0x4'),auth[_0x4003f8('0x0')](),controller[_0x4003f8('0x7')]),router[_0x4003f8('0x8')]('/',auth['isAuthenticated'](),controller[_0x4003f8('0x5')]),router[_0x4003f8('0x9')]('/:id',auth[_0x4003f8('0x0')](),controller[_0x4003f8('0x6')]),router[_0x4003f8('0xd')]('/:id',auth[_0x4003f8('0x0')](),controller['destroy']),module[_0x4003f8('0xb')]=router; \ No newline at end of file diff --git a/server/api/openchannelApplication/openchannelApplication.attributes.js b/server/api/openchannelApplication/openchannelApplication.attributes.js index ba1af2c..7898d32 100644 --- a/server/api/openchannelApplication/openchannelApplication.attributes.js +++ b/server/api/openchannelApplication/openchannelApplication.attributes.js @@ -1 +1 @@ -const a474_0x3ab8=['TEXT','sequelize','STRING','exports','noop','INTEGER'];(function(_0x2d631f,_0x3ab84f){const _0x277408=function(_0x31d8ef){while(--_0x31d8ef){_0x2d631f['push'](_0x2d631f['shift']());}};_0x277408(++_0x3ab84f);}(a474_0x3ab8,0x19b));const a474_0x2774=function(_0x2d631f,_0x3ab84f){_0x2d631f=_0x2d631f-0x0;let _0x277408=a474_0x3ab8[_0x2d631f];return _0x277408;};const _0x77dcbe=a474_0x2774;'use strict';const Sequelize=require(_0x77dcbe('0x4'));module[_0x77dcbe('0x0')]={'priority':{'type':Sequelize[_0x77dcbe('0x2')],'allowNull':![]},'app':{'type':Sequelize[_0x77dcbe('0x5')],'allowNull':![],'defaultValue':_0x77dcbe('0x1')},'appdata':{'type':Sequelize[_0x77dcbe('0x3')]()},'description':{'type':Sequelize[_0x77dcbe('0x5')]},'interval':{'type':Sequelize[_0x77dcbe('0x5')],'defaultValue':'*,*,*,*'}}; \ No newline at end of file +const a474_0x5353=['TEXT','noop','exports','STRING','*,*,*,*'];(function(_0x5b73d3,_0x5353c2){const _0x4753da=function(_0x499074){while(--_0x499074){_0x5b73d3['push'](_0x5b73d3['shift']());}};_0x4753da(++_0x5353c2);}(a474_0x5353,0x12d));const a474_0x4753=function(_0x5b73d3,_0x5353c2){_0x5b73d3=_0x5b73d3-0x0;let _0x4753da=a474_0x5353[_0x5b73d3];return _0x4753da;};const _0x200ac5=a474_0x4753;'use strict';const Sequelize=require('sequelize');module[_0x200ac5('0x1')]={'priority':{'type':Sequelize['INTEGER'],'allowNull':![]},'app':{'type':Sequelize[_0x200ac5('0x2')],'allowNull':![],'defaultValue':_0x200ac5('0x0')},'appdata':{'type':Sequelize[_0x200ac5('0x4')]()},'description':{'type':Sequelize[_0x200ac5('0x2')]},'interval':{'type':Sequelize[_0x200ac5('0x2')],'defaultValue':_0x200ac5('0x3')}}; \ No newline at end of file diff --git a/server/api/openchannelApplication/openchannelApplication.controller.js b/server/api/openchannelApplication/openchannelApplication.controller.js index a13a730..d7827a4 100644 --- a/server/api/openchannelApplication/openchannelApplication.controller.js +++ b/server/api/openchannelApplication/openchannelApplication.controller.js @@ -1 +1 @@ -const a475_0x2acc=['destroy','type','keys','includeAll','options','intersection','catch','offset','params','then','merge','../../components/parsers/qs','sort','nolimit','count','create','Content-Range','status','sequelize','VIRTUAL','findAll','rawAttributes','model','undefined','map','rows','end','filter','json','send','where','pick','../../mysqldb','findOne','name','OpenchannelApplication','../../config/logger','body','api','length','update','stack','attributes','include','key','fields','query','filters','index','fieldName'];(function(_0x4d016e,_0x2acc41){const _0x29c18a=function(_0x592110){while(--_0x592110){_0x4d016e['push'](_0x4d016e['shift']());}};_0x29c18a(++_0x2acc41);}(a475_0x2acc,0x65));const a475_0x29c1=function(_0x4d016e,_0x2acc41){_0x4d016e=_0x4d016e-0x0;let _0x29c18a=a475_0x2acc[_0x4d016e];return _0x29c18a;};const _0x3ee434=a475_0x29c1;'use strict';const _=require('lodash'),qs=require(_0x3ee434('0xa')),logger=require(_0x3ee434('0x23'))(_0x3ee434('0x25')),db=require(_0x3ee434('0x1f'))['db'],{Op}=require(_0x3ee434('0x11'));function respondWithResult(_0x592110,_0x564b2c){return _0x564b2c=_0x564b2c||0xc8,function(_0x376936){const _0x165495=a475_0x29c1;if(_0x376936)return _0x592110[_0x165495('0x10')](_0x564b2c)[_0x165495('0x1b')](_0x376936);};}function respondWithFilteredResult(_0x45ff87,_0x18d2aa){return function(_0x2c186c){const _0x53a2bd=a475_0x29c1;if(_0x2c186c){const _0x3bb1e1=_0x2c186c[_0x53a2bd('0xd')],_0x3cd06d=_0x18d2aa[_0x53a2bd('0x6')];let _0x204560=_0x18d2aa['offset']+_0x18d2aa['limit'],_0x181411;return _0x204560>=_0x3bb1e1?(_0x204560=_0x3bb1e1,_0x181411=0xc8):_0x181411=0xce,_0x45ff87[_0x53a2bd('0x10')](_0x181411),_0x45ff87['set'](_0x53a2bd('0xf'),_0x3cd06d+'-'+_0x204560+'/'+_0x3bb1e1)['json'](_0x2c186c);}return null;};}function saveUpdates(_0x5a017f){return function(_0x57d968){const _0x10be6b=a475_0x29c1;if(_0x57d968)return _0x57d968[_0x10be6b('0x27')](_0x5a017f)['then'](function(_0x534173){return _0x534173;});return null;};}function removeEntity(_0x542c9c){return function(_0x39e968){const _0x97268a=a475_0x29c1;if(_0x39e968)return _0x39e968[_0x97268a('0x31')]()[_0x97268a('0x8')](function(){const _0x1d3dcb=_0x97268a;_0x542c9c[_0x1d3dcb('0x10')](0xcc)[_0x1d3dcb('0x19')]();});};}function handleEntityNotFound(_0x7f3291){return function(_0x3fcc18){return!_0x3fcc18&&_0x7f3291['sendStatus'](0x194),_0x3fcc18;};}function handleError(_0x9316eb,_0x1f29b7){return _0x1f29b7=_0x1f29b7||0x1f4,function(_0x5b1637){const _0x40352a=a475_0x29c1;logger['error'](_0x5b1637[_0x40352a('0x28')]),_0x5b1637[_0x40352a('0x21')]&&delete _0x5b1637[_0x40352a('0x21')],_0x9316eb[_0x40352a('0x10')](_0x1f29b7)[_0x40352a('0x1c')](_0x5b1637);};}exports[_0x3ee434('0x2f')]=function(_0x4b4cdd,_0x17e7b5){const _0x24445=_0x3ee434;let _0x4fef01={};const _0x11a232={},_0x402f93={'count':0x0,'rows':[]},_0x39b071=_[_0x24445('0x17')](db['OpenchannelApplication'][_0x24445('0x14')],function(_0x163754){const _0x5a8bab=_0x24445;return{'name':_0x163754[_0x5a8bab('0x30')],'type':_0x163754[_0x5a8bab('0x0')][_0x5a8bab('0x2b')]};});_0x11a232[_0x24445('0x15')]=_[_0x24445('0x17')](_0x39b071,_0x24445('0x21')),_0x11a232[_0x24445('0x2d')]=_[_0x24445('0x1')](_0x4b4cdd[_0x24445('0x2d')]),_0x11a232[_0x24445('0x2e')]=_[_0x24445('0x4')](_0x11a232[_0x24445('0x15')],_0x11a232['query']),_0x4fef01['attributes']=_['intersection'](_0x11a232['model'],qs[_0x24445('0x2c')](_0x4b4cdd[_0x24445('0x2d')][_0x24445('0x2c')])),_0x4fef01['attributes']=_0x4fef01[_0x24445('0x29')][_0x24445('0x26')]?_0x4fef01[_0x24445('0x29')]:_0x11a232[_0x24445('0x15')];typeof _0x4b4cdd[_0x24445('0x2d')][_0x24445('0xc')]===_0x24445('0x16')&&(_0x4fef01['limit']=qs['limit'](_0x4b4cdd[_0x24445('0x2d')]['limit']),_0x4fef01[_0x24445('0x6')]=qs[_0x24445('0x6')](_0x4b4cdd[_0x24445('0x2d')][_0x24445('0x6')]));_0x4fef01['order']=qs[_0x24445('0xb')](_0x4b4cdd[_0x24445('0x2d')][_0x24445('0xb')]),_0x4fef01[_0x24445('0x1d')]=qs[_0x24445('0x2e')](_[_0x24445('0x1e')](_0x4b4cdd[_0x24445('0x2d')],_0x11a232['filters']),_0x39b071);_0x4b4cdd[_0x24445('0x2d')]['filter']&&(_0x4fef01[_0x24445('0x1d')]=_['merge'](_0x4fef01[_0x24445('0x1d')],{[Op['or']]:_['map'](_0x39b071,function(_0x286854){const _0x6f2bb3=_0x24445;if(_0x286854[_0x6f2bb3('0x0')]!==_0x6f2bb3('0x12')){const _0x5a6206={};return _0x5a6206[_0x286854['name']]={[Op['like']]:'%'+_0x4b4cdd[_0x6f2bb3('0x2d')][_0x6f2bb3('0x1a')]+'%'},_0x5a6206;}})}));_0x4fef01=_[_0x24445('0x9')]({},_0x4fef01,_0x4b4cdd[_0x24445('0x3')]);const _0x30a7fb={'where':_0x4fef01[_0x24445('0x1d')]};return db[_0x24445('0x22')][_0x24445('0xd')](_0x30a7fb)['then'](function(_0x557af1){const _0x309b41=_0x24445;return _0x402f93[_0x309b41('0xd')]=_0x557af1,_0x4b4cdd['query'][_0x309b41('0x2')]&&(_0x4fef01[_0x309b41('0x2a')]=[{'all':!![]}]),db[_0x309b41('0x22')][_0x309b41('0x13')](_0x4fef01);})['then'](function(_0x314834){const _0x2362e9=_0x24445;return _0x402f93[_0x2362e9('0x18')]=_0x314834,_0x402f93;})['then'](respondWithFilteredResult(_0x17e7b5,_0x4fef01))[_0x24445('0x5')](handleError(_0x17e7b5,null));},exports['show']=function(_0x4314ec,_0x2a3575){const _0x394797=_0x3ee434;let _0x107eb1={'raw':!![],'where':{'id':_0x4314ec['params']['id']}};const _0x4bad4f={};return _0x4bad4f[_0x394797('0x15')]=_[_0x394797('0x1')](db[_0x394797('0x22')][_0x394797('0x14')]),_0x4bad4f[_0x394797('0x2d')]=_[_0x394797('0x1')](_0x4314ec[_0x394797('0x2d')]),_0x4bad4f['filters']=_[_0x394797('0x4')](_0x4bad4f['model'],_0x4bad4f[_0x394797('0x2d')]),_0x107eb1[_0x394797('0x29')]=_[_0x394797('0x4')](_0x4bad4f[_0x394797('0x15')],qs[_0x394797('0x2c')](_0x4314ec[_0x394797('0x2d')][_0x394797('0x2c')])),_0x107eb1[_0x394797('0x29')]=_0x107eb1[_0x394797('0x29')]['length']?_0x107eb1[_0x394797('0x29')]:_0x4bad4f['model'],_0x4314ec[_0x394797('0x2d')][_0x394797('0x2')]&&(_0x107eb1[_0x394797('0x2a')]=[{'all':!![]}]),_0x107eb1=_[_0x394797('0x9')]({},_0x107eb1,_0x4314ec[_0x394797('0x3')]),db[_0x394797('0x22')][_0x394797('0x20')](_0x107eb1)['then'](handleEntityNotFound(_0x2a3575,null))[_0x394797('0x8')](respondWithResult(_0x2a3575,null))['catch'](handleError(_0x2a3575,null));},exports[_0x3ee434('0xe')]=function(_0x47bb73,_0x54027f){const _0x5a3bac=_0x3ee434;return db['OpenchannelApplication'][_0x5a3bac('0xe')](_0x47bb73[_0x5a3bac('0x24')],{})[_0x5a3bac('0x8')](respondWithResult(_0x54027f,0xc9))['catch'](handleError(_0x54027f,null));},exports[_0x3ee434('0x27')]=function(_0x1d43bf,_0x141cdc){const _0x57d344=_0x3ee434;return _0x1d43bf['body']['id']&&delete _0x1d43bf[_0x57d344('0x24')]['id'],db['OpenchannelApplication'][_0x57d344('0x20')]({'where':{'id':_0x1d43bf[_0x57d344('0x7')]['id']}})[_0x57d344('0x8')](handleEntityNotFound(_0x141cdc,null))[_0x57d344('0x8')](saveUpdates(_0x1d43bf['body'],null))[_0x57d344('0x8')](respondWithResult(_0x141cdc,null))[_0x57d344('0x5')](handleError(_0x141cdc,null));},exports[_0x3ee434('0x31')]=function(_0x392ea2,_0x2d9bed){const _0x203f61=_0x3ee434;return db[_0x203f61('0x22')][_0x203f61('0x20')]({'where':{'id':_0x392ea2['params']['id']}})[_0x203f61('0x8')](handleEntityNotFound(_0x2d9bed,null))[_0x203f61('0x8')](removeEntity(_0x2d9bed,null))[_0x203f61('0x5')](handleError(_0x2d9bed,null));}; \ No newline at end of file +const a475_0x56fd=['keys','fields','json','type','stack','set','status','sendStatus','key','limit','../../components/parsers/qs','model','filter','where','nolimit','fieldName','include','create','name','OpenchannelApplication','../../mysqldb','pick','params','api','order','then','findOne','catch','sort','update','filters','merge','show','offset','length','map','destroy','query','options','rawAttributes','lodash','count','body','VIRTUAL','findAll','end','intersection','attributes','error'];(function(_0x42f232,_0x56fd33){const _0x4e4e92=function(_0x4fbf73){while(--_0x4fbf73){_0x42f232['push'](_0x42f232['shift']());}};_0x4e4e92(++_0x56fd33);}(a475_0x56fd,0x125));const a475_0x4e4e=function(_0x42f232,_0x56fd33){_0x42f232=_0x42f232-0x0;let _0x4e4e92=a475_0x56fd[_0x42f232];return _0x4e4e92;};const _0x12f12c=a475_0x4e4e;'use strict';const _=require(_0x12f12c('0x29')),qs=require(_0x12f12c('0xb')),logger=require('../../config/logger')(_0x12f12c('0x18')),db=require(_0x12f12c('0x15'))['db'],{Op}=require('sequelize');function respondWithResult(_0x4fbf73,_0x39f4f9){return _0x39f4f9=_0x39f4f9||0xc8,function(_0xadef33){const _0x2e393d=a475_0x4e4e;if(_0xadef33)return _0x4fbf73['status'](_0x39f4f9)[_0x2e393d('0x3')](_0xadef33);};}function respondWithFilteredResult(_0x2ed23e,_0x3081e6){return function(_0x2c6a61){const _0x233e8d=a475_0x4e4e;if(_0x2c6a61){const _0x1972e=_0x2c6a61[_0x233e8d('0x2a')],_0x5d3139=_0x3081e6[_0x233e8d('0x22')];let _0x27cc4d=_0x3081e6[_0x233e8d('0x22')]+_0x3081e6[_0x233e8d('0xa')],_0x53e4f4;return _0x27cc4d>=_0x1972e?(_0x27cc4d=_0x1972e,_0x53e4f4=0xc8):_0x53e4f4=0xce,_0x2ed23e['status'](_0x53e4f4),_0x2ed23e[_0x233e8d('0x6')]('Content-Range',_0x5d3139+'-'+_0x27cc4d+'/'+_0x1972e)[_0x233e8d('0x3')](_0x2c6a61);}return null;};}function saveUpdates(_0x4a2cd9){return function(_0x5b8c8b){const _0x51c330=a475_0x4e4e;if(_0x5b8c8b)return _0x5b8c8b['update'](_0x4a2cd9)[_0x51c330('0x1a')](function(_0x51ef68){return _0x51ef68;});return null;};}function removeEntity(_0x591a8b){return function(_0x3ad9b0){const _0x2330d6=a475_0x4e4e;if(_0x3ad9b0)return _0x3ad9b0[_0x2330d6('0x25')]()['then'](function(){const _0x4f9557=_0x2330d6;_0x591a8b[_0x4f9557('0x7')](0xcc)[_0x4f9557('0x2e')]();});};}function handleEntityNotFound(_0x478008){return function(_0x325f7e){const _0x19602a=a475_0x4e4e;return!_0x325f7e&&_0x478008[_0x19602a('0x8')](0x194),_0x325f7e;};}function handleError(_0x25a927,_0x483878){return _0x483878=_0x483878||0x1f4,function(_0x596197){const _0xbe7339=a475_0x4e4e;logger[_0xbe7339('0x0')](_0x596197[_0xbe7339('0x5')]),_0x596197[_0xbe7339('0x13')]&&delete _0x596197['name'],_0x25a927[_0xbe7339('0x7')](_0x483878)['send'](_0x596197);};}exports['index']=function(_0x269513,_0x413582){const _0x448e85=_0x12f12c;let _0x345217={};const _0x52e424={},_0x2db18d={'count':0x0,'rows':[]},_0x49cc46=_['map'](db[_0x448e85('0x14')][_0x448e85('0x28')],function(_0x56b34e){const _0x5020f8=_0x448e85;return{'name':_0x56b34e[_0x5020f8('0x10')],'type':_0x56b34e[_0x5020f8('0x4')][_0x5020f8('0x9')]};});_0x52e424['model']=_[_0x448e85('0x24')](_0x49cc46,_0x448e85('0x13')),_0x52e424[_0x448e85('0x26')]=_[_0x448e85('0x1')](_0x269513['query']),_0x52e424['filters']=_[_0x448e85('0x2f')](_0x52e424[_0x448e85('0xc')],_0x52e424[_0x448e85('0x26')]),_0x345217['attributes']=_['intersection'](_0x52e424[_0x448e85('0xc')],qs[_0x448e85('0x2')](_0x269513[_0x448e85('0x26')][_0x448e85('0x2')])),_0x345217[_0x448e85('0x30')]=_0x345217[_0x448e85('0x30')]['length']?_0x345217['attributes']:_0x52e424[_0x448e85('0xc')];typeof _0x269513['query'][_0x448e85('0xf')]==='undefined'&&(_0x345217[_0x448e85('0xa')]=qs[_0x448e85('0xa')](_0x269513[_0x448e85('0x26')][_0x448e85('0xa')]),_0x345217[_0x448e85('0x22')]=qs['offset'](_0x269513[_0x448e85('0x26')][_0x448e85('0x22')]));_0x345217[_0x448e85('0x19')]=qs[_0x448e85('0x1d')](_0x269513[_0x448e85('0x26')]['sort']),_0x345217[_0x448e85('0xe')]=qs['filters'](_[_0x448e85('0x16')](_0x269513[_0x448e85('0x26')],_0x52e424[_0x448e85('0x1f')]),_0x49cc46);_0x269513[_0x448e85('0x26')]['filter']&&(_0x345217[_0x448e85('0xe')]=_['merge'](_0x345217[_0x448e85('0xe')],{[Op['or']]:_[_0x448e85('0x24')](_0x49cc46,function(_0x5613e1){const _0x3f847a=_0x448e85;if(_0x5613e1[_0x3f847a('0x4')]!==_0x3f847a('0x2c')){const _0x48b74c={};return _0x48b74c[_0x5613e1['name']]={[Op['like']]:'%'+_0x269513[_0x3f847a('0x26')][_0x3f847a('0xd')]+'%'},_0x48b74c;}})}));_0x345217=_[_0x448e85('0x20')]({},_0x345217,_0x269513[_0x448e85('0x27')]);const _0x33d26a={'where':_0x345217[_0x448e85('0xe')]};return db[_0x448e85('0x14')][_0x448e85('0x2a')](_0x33d26a)[_0x448e85('0x1a')](function(_0x28ae88){const _0x29b375=_0x448e85;return _0x2db18d[_0x29b375('0x2a')]=_0x28ae88,_0x269513[_0x29b375('0x26')]['includeAll']&&(_0x345217[_0x29b375('0x11')]=[{'all':!![]}]),db[_0x29b375('0x14')][_0x29b375('0x2d')](_0x345217);})[_0x448e85('0x1a')](function(_0x4732b1){return _0x2db18d['rows']=_0x4732b1,_0x2db18d;})[_0x448e85('0x1a')](respondWithFilteredResult(_0x413582,_0x345217))['catch'](handleError(_0x413582,null));},exports[_0x12f12c('0x21')]=function(_0x3f783c,_0xe99055){const _0x23c635=_0x12f12c;let _0x2612eb={'raw':!![],'where':{'id':_0x3f783c[_0x23c635('0x17')]['id']}};const _0x2c7cee={};return _0x2c7cee[_0x23c635('0xc')]=_[_0x23c635('0x1')](db[_0x23c635('0x14')][_0x23c635('0x28')]),_0x2c7cee[_0x23c635('0x26')]=_[_0x23c635('0x1')](_0x3f783c['query']),_0x2c7cee[_0x23c635('0x1f')]=_['intersection'](_0x2c7cee['model'],_0x2c7cee[_0x23c635('0x26')]),_0x2612eb[_0x23c635('0x30')]=_[_0x23c635('0x2f')](_0x2c7cee[_0x23c635('0xc')],qs[_0x23c635('0x2')](_0x3f783c[_0x23c635('0x26')][_0x23c635('0x2')])),_0x2612eb[_0x23c635('0x30')]=_0x2612eb[_0x23c635('0x30')][_0x23c635('0x23')]?_0x2612eb['attributes']:_0x2c7cee[_0x23c635('0xc')],_0x3f783c['query']['includeAll']&&(_0x2612eb['include']=[{'all':!![]}]),_0x2612eb=_[_0x23c635('0x20')]({},_0x2612eb,_0x3f783c[_0x23c635('0x27')]),db[_0x23c635('0x14')]['findOne'](_0x2612eb)[_0x23c635('0x1a')](handleEntityNotFound(_0xe99055,null))[_0x23c635('0x1a')](respondWithResult(_0xe99055,null))[_0x23c635('0x1c')](handleError(_0xe99055,null));},exports[_0x12f12c('0x12')]=function(_0x31364d,_0xb2db6a){const _0x132c28=_0x12f12c;return db[_0x132c28('0x14')][_0x132c28('0x12')](_0x31364d[_0x132c28('0x2b')],{})[_0x132c28('0x1a')](respondWithResult(_0xb2db6a,0xc9))['catch'](handleError(_0xb2db6a,null));},exports[_0x12f12c('0x1e')]=function(_0x34da83,_0x24ea28){const _0x464a04=_0x12f12c;return _0x34da83['body']['id']&&delete _0x34da83[_0x464a04('0x2b')]['id'],db[_0x464a04('0x14')][_0x464a04('0x1b')]({'where':{'id':_0x34da83[_0x464a04('0x17')]['id']}})['then'](handleEntityNotFound(_0x24ea28,null))[_0x464a04('0x1a')](saveUpdates(_0x34da83[_0x464a04('0x2b')],null))[_0x464a04('0x1a')](respondWithResult(_0x24ea28,null))[_0x464a04('0x1c')](handleError(_0x24ea28,null));},exports[_0x12f12c('0x25')]=function(_0x439942,_0x33a79a){const _0x285ef7=_0x12f12c;return db[_0x285ef7('0x14')][_0x285ef7('0x1b')]({'where':{'id':_0x439942['params']['id']}})['then'](handleEntityNotFound(_0x33a79a,null))[_0x285ef7('0x1a')](removeEntity(_0x33a79a,null))[_0x285ef7('0x1c')](handleError(_0x33a79a,null));}; \ No newline at end of file diff --git a/server/api/openchannelApplication/openchannelApplication.model.js b/server/api/openchannelApplication/openchannelApplication.model.js index c72be16..78f6956 100644 --- a/server/api/openchannelApplication/openchannelApplication.model.js +++ b/server/api/openchannelApplication/openchannelApplication.model.js @@ -1 +1 @@ -const a476_0x4d3a=['utf8mb4','./openchannelApplication.attributes','exports','define','utf8mb4_unicode_ci','openchannel_applications'];(function(_0x531c7e,_0x4d3a56){const _0x621a6f=function(_0x21031c){while(--_0x21031c){_0x531c7e['push'](_0x531c7e['shift']());}};_0x621a6f(++_0x4d3a56);}(a476_0x4d3a,0xb1));const a476_0x621a=function(_0x531c7e,_0x4d3a56){_0x531c7e=_0x531c7e-0x0;let _0x621a6f=a476_0x4d3a[_0x531c7e];return _0x621a6f;};const _0x23dd39=a476_0x621a;'use strict';const attributes=require(_0x23dd39('0x4'));module[_0x23dd39('0x5')]=function(_0x21031c){const _0x4f95c6=_0x23dd39,_0x1c514f=_0x21031c[_0x4f95c6('0x0')]('OpenchannelApplication',attributes,{'tableName':_0x4f95c6('0x2'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x4f95c6('0x3'),'collate':_0x4f95c6('0x1')});return _0x1c514f;}; \ No newline at end of file +const a476_0x162a=['utf8mb4','define','OpenchannelApplication','utf8mb4_unicode_ci'];(function(_0x2db672,_0x162a12){const _0x13fb16=function(_0x310cca){while(--_0x310cca){_0x2db672['push'](_0x2db672['shift']());}};_0x13fb16(++_0x162a12);}(a476_0x162a,0x9a));const a476_0x13fb=function(_0x2db672,_0x162a12){_0x2db672=_0x2db672-0x0;let _0x13fb16=a476_0x162a[_0x2db672];return _0x13fb16;};'use strict';const attributes=require('./openchannelApplication.attributes');module['exports']=function(_0x310cca){const _0x1f3284=a476_0x13fb,_0xd7a527=_0x310cca[_0x1f3284('0x3')](_0x1f3284('0x0'),attributes,{'tableName':'openchannel_applications','paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x1f3284('0x2'),'collate':_0x1f3284('0x1')});return _0xd7a527;}; \ No newline at end of file diff --git a/server/api/openchannelApplication/openchannelApplication.rpc.js b/server/api/openchannelApplication/openchannelApplication.rpc.js index c368450..dea7e06 100644 --- a/server/api/openchannelApplication/openchannelApplication.rpc.js +++ b/server/api/openchannelApplication/openchannelApplication.rpc.js @@ -1 +1 @@ -const a477_0x47ec=['UpdateOpenchannelApplication','message','../../mysqldb','limit','debug','update','options','where','body','raw','info','stringify','attributes','error','../../config/logger'];(function(_0x536a13,_0x47ecb5){const _0x342934=function(_0x150d97){while(--_0x150d97){_0x536a13['push'](_0x536a13['shift']());}};_0x342934(++_0x47ecb5);}(a477_0x47ec,0x152));const a477_0x3429=function(_0x536a13,_0x47ecb5){_0x536a13=_0x536a13-0x0;let _0x342934=a477_0x47ec[_0x536a13];return _0x342934;};const _0x1540fd=a477_0x3429;'use strict';const db=require(_0x1540fd('0x9'))['db'],logger=require(_0x1540fd('0x6'))('rpc');exports[_0x1540fd('0x7')]=function(_0x150d97){const _0x5338ca=this;return new Promise(function(_0x4c9754,_0x36eee8){const _0x281210=a477_0x3429;return db['OpenchannelApplication'][_0x281210('0xc')](_0x150d97[_0x281210('0x0')],{'raw':_0x150d97[_0x281210('0xd')]?_0x150d97['options'][_0x281210('0x1')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x150d97[_0x281210('0xd')]?_0x150d97[_0x281210('0xd')][_0x281210('0xe')]||null:null,'attributes':_0x150d97['options']?_0x150d97[_0x281210('0xd')][_0x281210('0x4')]||null:null,'limit':_0x150d97[_0x281210('0xd')]?_0x150d97['options'][_0x281210('0xa')]||null:null})['then'](function(_0x27602f){const _0x5aa9ac=_0x281210;logger[_0x5aa9ac('0x2')](_0x5aa9ac('0x7'),_0x150d97),logger[_0x5aa9ac('0xb')]('UpdateOpenchannelApplication',_0x150d97,JSON[_0x5aa9ac('0x3')](_0x27602f)),_0x4c9754(_0x27602f);})['catch'](function(_0x68082f){const _0x269e64=_0x281210;logger[_0x269e64('0x5')]('UpdateOpenchannelApplication',_0x68082f[_0x269e64('0x8')],_0x150d97),_0x36eee8(_0x5338ca['error'](0x1f4,_0x68082f[_0x269e64('0x8')]));});});}; \ No newline at end of file +const a477_0x1a94=['options','raw','limit','info','../../mysqldb','where','body','debug','UpdateOpenchannelApplication','stringify','rpc','error'];(function(_0x4d7806,_0x1a94ef){const _0x12be92=function(_0x5124b9){while(--_0x5124b9){_0x4d7806['push'](_0x4d7806['shift']());}};_0x12be92(++_0x1a94ef);}(a477_0x1a94,0xf9));const a477_0x12be=function(_0x4d7806,_0x1a94ef){_0x4d7806=_0x4d7806-0x0;let _0x12be92=a477_0x1a94[_0x4d7806];return _0x12be92;};const _0xe12c06=a477_0x12be;'use strict';const db=require(_0xe12c06('0x7'))['db'],logger=require('../../config/logger')(_0xe12c06('0x1'));exports[_0xe12c06('0xb')]=function(_0x5124b9){const _0x2dd5a5=this;return new Promise(function(_0x18d085,_0x1d2ac6){const _0xb7232e=a477_0x12be;return db['OpenchannelApplication']['update'](_0x5124b9[_0xb7232e('0x9')],{'raw':_0x5124b9[_0xb7232e('0x3')]?_0x5124b9[_0xb7232e('0x3')][_0xb7232e('0x4')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x5124b9[_0xb7232e('0x3')]?_0x5124b9['options'][_0xb7232e('0x8')]||null:null,'attributes':_0x5124b9[_0xb7232e('0x3')]?_0x5124b9['options']['attributes']||null:null,'limit':_0x5124b9[_0xb7232e('0x3')]?_0x5124b9['options'][_0xb7232e('0x5')]||null:null})['then'](function(_0x3ff77c){const _0x393bbd=_0xb7232e;logger[_0x393bbd('0x6')](_0x393bbd('0xb'),_0x5124b9),logger[_0x393bbd('0xa')]('UpdateOpenchannelApplication',_0x5124b9,JSON[_0x393bbd('0x0')](_0x3ff77c)),_0x18d085(_0x3ff77c);})['catch'](function(_0x1654b9){const _0xc947f5=_0xb7232e;logger[_0xc947f5('0x2')]('UpdateOpenchannelApplication',_0x1654b9['message'],_0x5124b9),_0x1d2ac6(_0x2dd5a5[_0xc947f5('0x2')](0x1f4,_0x1654b9['message']));});});}; \ No newline at end of file diff --git a/server/api/openchannelInteraction/index.js b/server/api/openchannelInteraction/index.js index 9957465..77dfaf7 100644 --- a/server/api/openchannelInteraction/index.js +++ b/server/api/openchannelInteraction/index.js @@ -1 +1 @@ -const a478_0x1b0b=['download','isAuthenticated','addMessage','openchannelinteraction:destroy','delete','/:id/messages','put','../../components/interaction/service','removeTags','destroy','update','openchannelinteraction:addtags','post','Router','show','get','express','tracked','/:id','describe','create','openchannel','getMessages','/:id/tags','./openchannelInteraction.controller','openchannelinteraction:update','index'];(function(_0x302349,_0x1b0b80){const _0x5381e0=function(_0x3c7500){while(--_0x3c7500){_0x302349['push'](_0x302349['shift']());}};_0x5381e0(++_0x1b0b80);}(a478_0x1b0b,0xd1));const a478_0x5381=function(_0x302349,_0x1b0b80){_0x302349=_0x302349-0x0;let _0x5381e0=a478_0x1b0b[_0x302349];return _0x5381e0;};const _0x48a5c2=a478_0x5381;'use strict';const express=require(_0x48a5c2('0x17')),router=express[_0x48a5c2('0x14')](),auth=require('../../components/auth/service'),interaction=require(_0x48a5c2('0xe')),controller=require(_0x48a5c2('0x4'));router[_0x48a5c2('0x16')]('/',auth['isAuthenticated'](),controller[_0x48a5c2('0x6')]),router[_0x48a5c2('0x16')]('/describe',auth[_0x48a5c2('0x8')](),controller[_0x48a5c2('0x1a')]),router['get'](_0x48a5c2('0x19'),auth['isAuthenticated'](),controller[_0x48a5c2('0x15')]),router['get'](_0x48a5c2('0xc'),auth[_0x48a5c2('0x8')](),controller[_0x48a5c2('0x2')]),router['get']('/:id/download',auth['isAuthenticated'](),controller[_0x48a5c2('0x7')]),router[_0x48a5c2('0x13')]('/',auth[_0x48a5c2('0x8')](),controller[_0x48a5c2('0x0')]),router['post']('/:id/messages',auth[_0x48a5c2('0x8')](),controller[_0x48a5c2('0x9')]),router[_0x48a5c2('0x13')](_0x48a5c2('0x3'),auth[_0x48a5c2('0x8')](),interaction[_0x48a5c2('0x18')](_0x48a5c2('0x1'),_0x48a5c2('0x12')),controller['addTags']),router[_0x48a5c2('0xd')](_0x48a5c2('0x19'),auth['isAuthenticated'](),interaction[_0x48a5c2('0x18')](_0x48a5c2('0x1'),_0x48a5c2('0x5')),controller[_0x48a5c2('0x11')]),router[_0x48a5c2('0xb')](_0x48a5c2('0x19'),auth[_0x48a5c2('0x8')](),interaction[_0x48a5c2('0x18')](_0x48a5c2('0x1'),_0x48a5c2('0xa')),controller[_0x48a5c2('0x10')]),router[_0x48a5c2('0xb')](_0x48a5c2('0x3'),auth[_0x48a5c2('0x8')](),controller[_0x48a5c2('0xf')]),module['exports']=router; \ No newline at end of file +const a478_0x4fcd=['/:id','/:id/tags','destroy','/:id/download','getMessages','Router','/:id/messages','create','index','get','./openchannelInteraction.controller','openchannelinteraction:destroy','put','openchannel','openchannelinteraction:addtags','delete','isAuthenticated','../../components/interaction/service','post','show','exports','tracked','update','addTags','describe','removeTags','/describe'];(function(_0x293916,_0x4fcd07){const _0x516e4e=function(_0x50fdae){while(--_0x50fdae){_0x293916['push'](_0x293916['shift']());}};_0x516e4e(++_0x4fcd07);}(a478_0x4fcd,0x117));const a478_0x516e=function(_0x293916,_0x4fcd07){_0x293916=_0x293916-0x0;let _0x516e4e=a478_0x4fcd[_0x293916];return _0x516e4e;};const _0x32dad9=a478_0x516e;'use strict';const express=require('express'),router=express[_0x32dad9('0x17')](),auth=require('../../components/auth/service'),interaction=require(_0x32dad9('0x8')),controller=require(_0x32dad9('0x1'));router['get']('/',auth['isAuthenticated'](),controller[_0x32dad9('0x1a')]),router[_0x32dad9('0x0')](_0x32dad9('0x11'),auth[_0x32dad9('0x7')](),controller[_0x32dad9('0xf')]),router[_0x32dad9('0x0')](_0x32dad9('0x12'),auth[_0x32dad9('0x7')](),controller[_0x32dad9('0xa')]),router[_0x32dad9('0x0')](_0x32dad9('0x18'),auth['isAuthenticated'](),controller[_0x32dad9('0x16')]),router['get'](_0x32dad9('0x15'),auth[_0x32dad9('0x7')](),controller['download']),router[_0x32dad9('0x9')]('/',auth['isAuthenticated'](),controller[_0x32dad9('0x19')]),router[_0x32dad9('0x9')](_0x32dad9('0x18'),auth[_0x32dad9('0x7')](),controller['addMessage']),router['post']('/:id/tags',auth['isAuthenticated'](),interaction[_0x32dad9('0xc')]('openchannel',_0x32dad9('0x5')),controller[_0x32dad9('0xe')]),router[_0x32dad9('0x3')]('/:id',auth['isAuthenticated'](),interaction[_0x32dad9('0xc')](_0x32dad9('0x4'),'openchannelinteraction:update'),controller[_0x32dad9('0xd')]),router[_0x32dad9('0x6')](_0x32dad9('0x12'),auth['isAuthenticated'](),interaction[_0x32dad9('0xc')]('openchannel',_0x32dad9('0x2')),controller[_0x32dad9('0x14')]),router['delete'](_0x32dad9('0x13'),auth[_0x32dad9('0x7')](),controller[_0x32dad9('0x10')]),module[_0x32dad9('0xb')]=router; \ No newline at end of file diff --git a/server/api/openchannelInteraction/openchannelInteraction.attributes.js b/server/api/openchannelInteraction/openchannelInteraction.attributes.js index ec74d5d..777ee4b 100644 --- a/server/api/openchannelInteraction/openchannelInteraction.attributes.js +++ b/server/api/openchannelInteraction/openchannelInteraction.attributes.js @@ -1 +1 @@ -const a479_0x58c5=['BOOLEAN','STRING','DATE','ENUM'];(function(_0x256d64,_0x58c502){const _0x91a6bb=function(_0x4838c0){while(--_0x4838c0){_0x256d64['push'](_0x256d64['shift']());}};_0x91a6bb(++_0x58c502);}(a479_0x58c5,0x12b));const a479_0x91a6=function(_0x256d64,_0x58c502){_0x256d64=_0x256d64-0x0;let _0x91a6bb=a479_0x58c5[_0x256d64];return _0x91a6bb;};const _0x20729b=a479_0x91a6;'use strict';const Sequelize=require('sequelize');module['exports']={'closed':{'type':Sequelize[_0x20729b('0x1')],'defaultValue':![]},'closedAt':{'type':Sequelize[_0x20729b('0x3')]},'disposition':{'type':Sequelize['STRING']},'secondDisposition':{'type':Sequelize[_0x20729b('0x2')]},'thirdDisposition':{'type':Sequelize[_0x20729b('0x2')]},'note':{'type':Sequelize['STRING']},'read1stAt':{'type':Sequelize[_0x20729b('0x3')]},'threadId':{'type':Sequelize['STRING']},'externalUrl':{'type':Sequelize[_0x20729b('0x2')]},'lastMsgAt':{'type':Sequelize[_0x20729b('0x3')]},'lastMsgDirection':{'type':Sequelize[_0x20729b('0x0')]('in','out'),'defaultValue':'in','allowNull':![]},'from':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a479_0x4886=['DATE','STRING','sequelize','ENUM'];(function(_0x1398a9,_0x488609){const _0x54aa09=function(_0x117480){while(--_0x117480){_0x1398a9['push'](_0x1398a9['shift']());}};_0x54aa09(++_0x488609);}(a479_0x4886,0x1dc));const a479_0x54aa=function(_0x1398a9,_0x488609){_0x1398a9=_0x1398a9-0x0;let _0x54aa09=a479_0x4886[_0x1398a9];return _0x54aa09;};const _0x53e7fa=a479_0x54aa;'use strict';const Sequelize=require(_0x53e7fa('0x2'));module['exports']={'closed':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'closedAt':{'type':Sequelize['DATE']},'disposition':{'type':Sequelize[_0x53e7fa('0x1')]},'secondDisposition':{'type':Sequelize['STRING']},'thirdDisposition':{'type':Sequelize[_0x53e7fa('0x1')]},'note':{'type':Sequelize['STRING']},'read1stAt':{'type':Sequelize[_0x53e7fa('0x0')]},'threadId':{'type':Sequelize[_0x53e7fa('0x1')]},'externalUrl':{'type':Sequelize[_0x53e7fa('0x1')]},'lastMsgAt':{'type':Sequelize[_0x53e7fa('0x0')]},'lastMsgDirection':{'type':Sequelize[_0x53e7fa('0x3')]('in','out'),'defaultValue':'in','allowNull':![]},'from':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/openchannelInteraction/openchannelInteraction.controller.js b/server/api/openchannelInteraction/openchannelInteraction.controller.js index 7d92a23..d87cbee 100644 --- a/server/api/openchannelInteraction/openchannelInteraction.controller.js +++ b/server/api/openchannelInteraction/openchannelInteraction.controller.js @@ -1 +1 @@ -const a480_0x55fb=['downloadInteraction.html','end','params','i.id','map','lodash','server','replace','Owner.internal','having','Contact.email','createWriteStream','i.id\x20LIKE\x20?','getOpenchannelAccounts','read','count','it.OpenchannelInteractionId\x20=\x20i.id','toString','../../config/environment','color','model','`unreadMessages`\x20=\x200','omit','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{page}}/{{pages}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','Owner.fullname','OpenchannelMessage','text','html-pdf','toFile','get','User','err','OpenchannelInteractionId','views','tmp','unlinkSync','threadId','stack','a.key','clone','rawAttributes','all','compact','destroy','OpenchannelAccountId','attributes','o.internal','select','existsSync','files','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','type','groupBy','emit','openchannel_interactions','operator','System','Owner','mkdirSync','c.lastName','`\x20>\x200','`unreadMessages`\x20>\x200','then','$lte','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL','includeAll','%s\x20#%d','ids','rows','merge','\x20IS\x20NULL','buildExpression','direction','u.id','TagIds','getMessages','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
Interaction\x20Transcript
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','QueryTypes','show','Private','search','t.id\x20=\x20it.TagId','unreadMessages','util','ContactId','openchannel_messages','expr','error','sequelize','createdAt','o.id\x20=\x20i.UserId','limit','like','null','Openchannel','Attachment','start','value','index','Messages','CmContact','set','YYYY-MM-DD\x20HH:mm:ss','name','tools_tags','zip-dir','u.id\x20=\x20ui.UserId','left_join','i.*','SELECT','firstName','format','attachments','../../config/logger','unix','Tags','i.createdAt\x20BETWEEN\x20?\x20AND\x20?','../../rediscache','c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?','me.OpenchannelInteractionId\x20=\x20i.id','lastName','user','30px','sendStatus','gte','isArray','OpenchannelInteraction','Account','ui.OpenchannelInteractionId\x20IN\x20?','c.fax','status','union','from','split','pick','filters','length','push','fullname','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','renderFile','users','Contact.firstName','query','keys','nolimit','path','create','parse','c.phone','transcript-','MATCH\x20(me.body)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','order','keyBy','Content-Range','getFullTextValue','c.mobile','sort','conditions','tag','offset','Tag','addTags','findAll','find','Contact.fax','removeTags','update','../../mysqldb','setTags','c.firstName','secret','Contact','\x27\x27\x27\x27','out','undefined','findOne','$gte','parseSearch','o.fullname','addMessage','Account.key','i.OpenchannelAccountId\x20IS\x20NOT\x20NULL','forEach','key','join','json','options','resolve','i.OpenchannelAccountId\x20IN\x20?','download','intersection','isEmpty','fields','i.OpenchannelAccountId\x20IS\x20NULL','field','openchannel_interaction_has_tags','Account.mandatoryDisposition','openchannelInteractionTags:save','catch','i.from\x20LIKE\x20?','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','`\x20=\x200','basename','moment','cm_contacts','ejs','u.fullname','include','a.id\x20=\x20i.OpenchannelAccountId','Contact.phone','where','N.A.','concat','root','40px','GROUP_CONCAT(DISTINCT\x20t.id)','../../components/parsers/qs','CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?','describe','$substring','body','filter','t.id\x20IN\x20?','fieldName','Public'];(function(_0x436a5b,_0x55fbfe){const _0x483183=function(_0x17df2d){while(--_0x17df2d){_0x436a5b['push'](_0x436a5b['shift']());}};_0x483183(++_0x55fbfe);}(a480_0x55fb,0x10d));const a480_0x4831=function(_0x436a5b,_0x55fbfe){_0x436a5b=_0x436a5b-0x0;let _0x483183=a480_0x55fb[_0x436a5b];return _0x483183;};const _0x124cbb=a480_0x4831;'use strict';const pdf=require(_0x124cbb('0xd2')),rimraf=require('rimraf'),zipdir=require(_0x124cbb('0x3e')),moment=require(_0x124cbb('0xa1')),util=require(_0x124cbb('0x28')),path=require(_0x124cbb('0x67')),ejs=require(_0x124cbb('0xa3')),fs=require('fs'),_=require(_0x124cbb('0xbc')),squel=require('squel'),{getSocket}=require(_0x124cbb('0x4a')),socket=getSocket(),qs=require(_0x124cbb('0xae')),as=require('../../components/parsers/advancedSearch'),logger=require(_0x124cbb('0x46'))('api'),config=require(_0x124cbb('0xc9')),db=require(_0x124cbb('0x7d'))['db'],{Op}=require('sequelize');require('./openchannelInteraction.socket')['register'](socket);function respondWithStatusCode(_0x17df2d,_0x2602ff){return _0x2602ff=_0x2602ff||0xcc,function(_0x5dd7b2){const _0x4dbd7e=a480_0x4831;if(_0x5dd7b2)return _0x17df2d[_0x4dbd7e('0x50')](_0x2602ff);return _0x17df2d[_0x4dbd7e('0x57')](_0x2602ff)['end']();};}function respondWithResult(_0x129dce,_0x5352f8){return _0x5352f8=_0x5352f8||0xc8,function(_0x44fc8d){const _0x32c2f5=a480_0x4831;if(_0x44fc8d)return _0x129dce[_0x32c2f5('0x57')](_0x5352f8)[_0x32c2f5('0x8f')](_0x44fc8d);};}function respondWithFilteredResult(_0x5bc04c,_0x2bbbc1){return function(_0x5305f4){const _0x55b9e2=a480_0x4831;if(_0x5305f4){const _0x199df6=_0x5305f4['count'],_0x3c3a86=_0x2bbbc1[_0x55b9e2('0x75')];let _0x14592c=_0x2bbbc1[_0x55b9e2('0x75')]+_0x2bbbc1[_0x55b9e2('0x30')],_0x3c0db2;return _0x14592c>=_0x199df6?(_0x14592c=_0x199df6,_0x3c0db2=0xc8):_0x3c0db2=0xce,_0x5bc04c[_0x55b9e2('0x57')](_0x3c0db2),_0x5bc04c[_0x55b9e2('0x3a')](_0x55b9e2('0x6f'),_0x3c3a86+'-'+_0x14592c+'/'+_0x199df6)[_0x55b9e2('0x8f')](_0x5305f4);}return null;};}function saveUpdates(_0x3016cc){return function(_0x472c01){const _0xd98f5b=a480_0x4831;if(_0x472c01)return _0x472c01[_0xd98f5b('0x7c')](_0x3016cc)[_0xd98f5b('0x13')](function(_0x1092d6){return _0x1092d6;});return null;};}function removeEntity(_0x5c2e62){return function(_0x87dd46){const _0x8da353=a480_0x4831;if(_0x87dd46)return _0x87dd46[_0x8da353('0x0')]()[_0x8da353('0x13')](function(){const _0x3d79b9=_0x8da353;_0x5c2e62[_0x3d79b9('0x57')](0xcc)['end']();});};}function handleEntityNotFound(_0x315ef2){return function(_0x5951cd){return!_0x5951cd&&_0x315ef2['sendStatus'](0x194),_0x5951cd;};}function handleError(_0x34acfb,_0x5237bb){return _0x5237bb=_0x5237bb||0x1f4,function(_0xe62be3){const _0x5030cc=a480_0x4831;logger[_0x5030cc('0x2c')](_0xe62be3[_0x5030cc('0xdc')]),_0xe62be3[_0x5030cc('0x3c')]&&delete _0xe62be3[_0x5030cc('0x3c')],_0x34acfb[_0x5030cc('0x57')](_0x5237bb)['send'](_0xe62be3);};}function getInteractionUsers(_0x1a8d59,_0x11fdf5){return new Promise(function(_0x1b4181,_0x338d16){const _0x219fb1=a480_0x4831;try{_0x11fdf5[_0x1a8d59['id']]&&(_0x1a8d59['Users']=_[_0x219fb1('0xbb')](_0x11fdf5[_0x1a8d59['id']],function(_0x4b8644){const _0x2ea86a=_0x219fb1;return{'id':_0x4b8644['id'],'fullname':_0x4b8644[_0x2ea86a('0x5f')]};}));}catch(_0x1c250c){_0x338d16(_0x1c250c);}_0x1b4181(_0x1a8d59);});}function getInteractionTags(_0x482a81,_0x13f397){return new Promise(function(_0x544ac9,_0xaa3487){const _0x3a2aaa=a480_0x4831;try{_0x482a81[_0x3a2aaa('0x1f')]&&(_0x482a81['Tags']=[],_0x482a81[_0x3a2aaa('0x1f')][_0x3a2aaa('0x5a')](',')[_0x3a2aaa('0x8c')](function(_0xe70b6a){const _0x43f3bd=_0x3a2aaa;_0x482a81[_0x43f3bd('0x48')][_0x43f3bd('0x5e')](_0x13f397[_0xe70b6a]);})),delete _0x482a81[_0x3a2aaa('0x1f')];}catch(_0x1a0fd0){_0xaa3487(_0x1a0fd0);}_0x544ac9(_0x482a81);});}function updateOpenchannelInteraction(_0x3a4841,_0x2ba17f,_0x2aecfd){return new Promise(function(_0x143811,_0x4c9196){const _0x2f0c73=a480_0x4831;return getInteractionUsers(_0x3a4841,_0x2aecfd)[_0x2f0c73('0x13')](function(_0x3dca58){return getInteractionTags(_0x3dca58,_0x2ba17f);})[_0x2f0c73('0x13')](function(_0x4d77f0){_0x143811(_0x4d77f0);})['catch'](function(_0x3b9bd6){_0x4c9196(_0x3b9bd6);});});}exports[_0x124cbb('0x37')]=function(_0x38e20d,_0x468317){const _0x4bbbe5=_0x124cbb,_0xcacc60={},_0x27c428={},_0x6ce902={'count':0x0,'rows':[]},_0x4abbd5=_[_0x4bbbe5('0xbb')](db['OpenchannelInteraction'][_0x4bbbe5('0xdf')],function(_0x23eb62){const _0x9b4744=_0x4bbbe5;return{'name':_0x23eb62[_0x9b4744('0xb5')],'type':_0x23eb62['type'][_0x9b4744('0x8d')]};});_0x27c428['model']=_['map'](_0x4abbd5,_0x4bbbe5('0x3c')),_0x27c428[_0x4bbbe5('0x64')]=_['keys'](_0x38e20d[_0x4bbbe5('0x64')]),_0x27c428['filters']=_[_0x4bbbe5('0x94')](_0x27c428[_0x4bbbe5('0xcb')],_0x27c428[_0x4bbbe5('0x64')]),_0xcacc60[_0x4bbbe5('0x2')]=_[_0x4bbbe5('0x94')](_0x27c428[_0x4bbbe5('0xcb')],qs['fields'](_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0x96')])),_0xcacc60[_0x4bbbe5('0x2')]=_0xcacc60['attributes'][_0x4bbbe5('0x5d')]?_0xcacc60[_0x4bbbe5('0x2')]:_0x27c428[_0x4bbbe5('0xcb')];typeof _0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0x66')]===_0x4bbbe5('0x84')&&(_0xcacc60[_0x4bbbe5('0x30')]=qs[_0x4bbbe5('0x30')](_0x38e20d['query'][_0x4bbbe5('0x30')]),_0xcacc60[_0x4bbbe5('0x75')]=qs[_0x4bbbe5('0x75')](_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0x75')]));_0xcacc60[_0x4bbbe5('0x6d')]=qs[_0x4bbbe5('0x72')](_0x38e20d['query'][_0x4bbbe5('0x72')]),_0xcacc60[_0x4bbbe5('0xa8')]=qs[_0x4bbbe5('0x5c')](_[_0x4bbbe5('0x5b')](_0x38e20d[_0x4bbbe5('0x64')],_0x27c428[_0x4bbbe5('0x5c')]),_0x4abbd5);let _0x3a801f=[];const _0x566c84=squel[_0x4bbbe5('0x4')]()[_0x4bbbe5('0x98')]('id')[_0x4bbbe5('0x98')](_0x4bbbe5('0x3c'))[_0x4bbbe5('0x98')](_0x4bbbe5('0xca'))[_0x4bbbe5('0x59')]('tools_tags'),_0x2ba6db=squel[_0x4bbbe5('0x4')]()[_0x4bbbe5('0x98')](_0x4bbbe5('0x1e'))[_0x4bbbe5('0x98')](_0x4bbbe5('0xa4'))[_0x4bbbe5('0x98')]('ui.OpenchannelInteractionId')[_0x4bbbe5('0x59')]('user_has_openchannel_interactions','ui')['left_join']('users','u',_0x4bbbe5('0x3f')),_0x355149=squel[_0x4bbbe5('0x4')]()[_0x4bbbe5('0x59')](_0x4bbbe5('0xb'),'i')['left_join'](_0x4bbbe5('0xa2'),'c',_0x4bbbe5('0x15'))[_0x4bbbe5('0x40')](_0x4bbbe5('0x62'),'o',_0x4bbbe5('0x2f'))[_0x4bbbe5('0x40')]('openchannel_accounts','a',_0x4bbbe5('0xa6'))['left_join'](_0x4bbbe5('0x2a'),'me',_0x4bbbe5('0x4c'))[_0x4bbbe5('0x40')](_0x4bbbe5('0x99'),'it',_0x4bbbe5('0xc7'))[_0x4bbbe5('0x40')](_0x4bbbe5('0x3d'),'t',_0x4bbbe5('0x26')),_0x36362d=squel[_0x4bbbe5('0x2b')]();let _0x1e79a1=[];const _0x7ccaba=squel[_0x4bbbe5('0x2b')]();let _0x7fad05;if(_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0x25')]){_0x7fad05=as[_0x4bbbe5('0x87')](_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0x25')]);const _0x39b3f2=_0x7fad05['sqlOperator'];for(let _0x2b2b78=0x0;_0x2b2b78<_0x7fad05[_0x4bbbe5('0x73')][_0x4bbbe5('0x5d')];_0x2b2b78++){const _0x102930=_0x7fad05['conditions'][_0x2b2b78],_0x9796f9='i';let _0x236d3a,_0x2b5510=_['find'](_0x4abbd5,[_0x4bbbe5('0x3c'),_0x102930[_0x4bbbe5('0x98')]]);if(!_0x2b5510)switch(_0x102930[_0x4bbbe5('0x98')]){case _0x4bbbe5('0x27'):_0x102930[_0x4bbbe5('0x36')]==0x1?_0x355149['having']('`'+_0x102930[_0x4bbbe5('0x98')]+_0x4bbbe5('0x9f')):_0x355149['having']('`'+_0x102930[_0x4bbbe5('0x98')]+_0x4bbbe5('0x11'));break;case _0x4bbbe5('0x81'):if(_0x102930['operator']==='$substring'){if(_0x102930[_0x4bbbe5('0x36')][_0x4bbbe5('0x5a')]('\x20')[_0x4bbbe5('0x5d')]>0x1)_0x36362d[_0x39b3f2]('MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs[_0x4bbbe5('0x70')](_0x102930['value']),null);else{const _0x4bf735='%'+_0x102930[_0x4bbbe5('0x36')]+'%';_0x36362d[_0x39b3f2](_0x4bbbe5('0x4b'),_0x4bf735,_0x4bf735,_0x4bf735);}}else _0x2b5510=_[_0x4bbbe5('0x79')](_0x4abbd5,[_0x4bbbe5('0x3c'),_0x4bbbe5('0x29')]),_0x102930[_0x4bbbe5('0x98')]=_0x4bbbe5('0x29'),_0x236d3a=as[_0x4bbbe5('0x1c')](_0x9796f9,_0x2b5510[_0x4bbbe5('0x8')],_0x102930),_0x36362d[_0x39b3f2](_0x236d3a[_0x4bbbe5('0xd1')],_0x236d3a['value'][_0x4bbbe5('0x35')],_0x236d3a[_0x4bbbe5('0x36')][_0x4bbbe5('0xb8')]);break;case _0x4bbbe5('0x76'):{const _0x35c236=_0x102930[_0x4bbbe5('0x36')][_0x4bbbe5('0x5a')](',')[_0x4bbbe5('0xbb')](function(_0x5d2289){return Number(_0x5d2289);});_0x35c236[_0x4bbbe5('0x8c')](function(_0x486b6f){const _0x7bd65d=_0x4bbbe5;_0x7ccaba['or'](_0x7bd65d('0x60'),'%,'+_0x486b6f+',%');}),_0x1e79a1=_[_0x4bbbe5('0x58')](_0x1e79a1,_0x35c236);}break;case'User':_0x102930[_0x4bbbe5('0xc')]===_0x4bbbe5('0xb1')?_0x36362d[_0x39b3f2](_0x4bbbe5('0x9e'),'%'+_0x102930[_0x4bbbe5('0x36')]+'%',null):(_0x2b5510=_[_0x4bbbe5('0x79')](_0x4abbd5,['name','UserId']),_0x102930['field']='UserId',_0x236d3a=as['buildExpression'](_0x9796f9,_0x2b5510[_0x4bbbe5('0x8')],_0x102930),_0x36362d[_0x39b3f2](_0x236d3a[_0x4bbbe5('0xd1')],_0x236d3a[_0x4bbbe5('0x36')][_0x4bbbe5('0x35')],_0x236d3a[_0x4bbbe5('0x36')][_0x4bbbe5('0xb8')]));break;case'body':_0x236d3a=as[_0x4bbbe5('0x1c')]('me',null,_0x102930),_0x36362d[_0x39b3f2](_0x236d3a[_0x4bbbe5('0xd1')],_0x236d3a['value'][_0x4bbbe5('0x35')],_0x236d3a['value'][_0x4bbbe5('0xb8')]);break;}else _0x236d3a=as['buildExpression'](_0x9796f9,_0x2b5510[_0x4bbbe5('0x8')],_0x102930),_0x36362d[_0x39b3f2](_0x236d3a[_0x4bbbe5('0xd1')],_0x236d3a[_0x4bbbe5('0x36')]['start'],_0x236d3a[_0x4bbbe5('0x36')]['end']);}}else{const _0x5db7e6=_(_0x38e20d[_0x4bbbe5('0x64')])[_0x4bbbe5('0x65')]()[_0x4bbbe5('0xbb')](function(_0xec382f){const _0x3b1b30=_0x4bbbe5;return _['some'](_0x4abbd5,[_0x3b1b30('0x3c'),_0xec382f])?_0xec382f:undefined;})[_0x4bbbe5('0xe1')]()[_0x4bbbe5('0x36')]();!_[_0x4bbbe5('0x95')](_0x5db7e6)&&_0x5db7e6['forEach'](function(_0x20c3a0){const _0x572d76=_0x4bbbe5;if(_0x20c3a0===_0x572d76('0x1'))_0x355149['where'](_0x572d76('0x92'),[][_0x572d76('0xaa')](_0x38e20d[_0x572d76('0x64')][_0x20c3a0]));else{if(_0x20c3a0==='createdAt'){const _0x29e669=JSON[_0x572d76('0x69')](_0x38e20d[_0x572d76('0x64')][_0x20c3a0])[_0x572d76('0x86')],_0x570cf6=JSON[_0x572d76('0x69')](_0x38e20d['query'][_0x20c3a0])[_0x572d76('0x14')];_0x355149[_0x572d76('0xa8')](_0x572d76('0x49'),_0x29e669,_0x570cf6);}else _0x38e20d[_0x572d76('0x64')][_0x20c3a0]===_0x572d76('0x32')?_0x355149[_0x572d76('0xa8')]('i.'+_0x20c3a0+_0x572d76('0x1b')):_0x355149[_0x572d76('0xa8')]('i.'+_0x20c3a0+'\x20=\x20?',_0x38e20d[_0x572d76('0x64')][_0x20c3a0]);}});_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0xc5')]&&(_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0xc5')]==0x1?_0x355149['having'](_0x4bbbe5('0xcc')):_0x355149[_0x4bbbe5('0xc0')](_0x4bbbe5('0x12')));_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0x74')]&&(_0x1e79a1=_[_0x4bbbe5('0x52')](_0x38e20d['query']['tag'])?_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0x74')]:new Array(_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0x74')]),_0x1e79a1[_0x4bbbe5('0x8c')](function(_0x40828e){const _0x269611=_0x4bbbe5;_0x7ccaba['or'](_0x269611('0x60'),'%,'+_0x40828e+',%');}));if(_0x38e20d[_0x4bbbe5('0x64')][_0x4bbbe5('0xb3')]){const _0xf3d5d5=_0x38e20d['query'][_0x4bbbe5('0xb3')][_0x4bbbe5('0xbe')]('\x5c','\x5c\x5c')[_0x4bbbe5('0xbe')]('\x27\x27',_0x4bbbe5('0x82'));qs['isNumeric'](_0xf3d5d5)?_0x36362d['or'](_0x4bbbe5('0xc3'),_0xf3d5d5+'%'):_0x36362d['or'](_0x4bbbe5('0x6c'),qs[_0x4bbbe5('0x70')](_0xf3d5d5))['or'](_0x4bbbe5('0x9d'),_0xf3d5d5+'%')['or'](_0x4bbbe5('0xaf'),_0xf3d5d5+'%');}}_0x355149[_0x4bbbe5('0xa8')](_0x36362d),_0x355149['group'](_0x4bbbe5('0xba'));let _0xbe6652={'type':db['Sequelize'][_0x4bbbe5('0x22')][_0x4bbbe5('0x42')],'raw':!![]};const _0x896c18=_0x355149[_0x4bbbe5('0xde')]();_0x896c18['field'](_0x4bbbe5('0xba')),_0x896c18['field']('SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)',_0x4bbbe5('0x27')),_0xcacc60['order']&&_0xcacc60[_0x4bbbe5('0x6d')][_0x4bbbe5('0x8c')](function(_0x2df19a){_0x355149['order']('i.'+_0x2df19a[0x0],_0x2df19a[0x1]==='DESC'?![]:!![]);}),!_[_0x4bbbe5('0x95')](_0x1e79a1)&&(_0x355149[_0x4bbbe5('0xc0')](_0x7ccaba),_0x896c18[_0x4bbbe5('0xa8')](_0x4bbbe5('0xb4'),_0x1e79a1)),Promise[_0x4bbbe5('0x91')]()['then'](function(){const _0x561dde=_0x4bbbe5;if(!_0x7fad05){if(_0x38e20d[_0x561dde('0x64')][_0x561dde('0x1')]||_0x38e20d[_0x561dde('0x64')]['journey'])return;_0x896c18[_0x561dde('0xa8')](_0x561dde('0x8b')),_0x355149[_0x561dde('0xa8')](_0x561dde('0x8b'));return;}return _0x38e20d[_0x561dde('0x4e')][_0x561dde('0xc4')]({'attributes':['id'],'raw':!![]})['then'](function(_0x2a74e1){const _0x25efab=_0x561dde;_[_0x25efab('0x95')](_0x2a74e1)?(_0x896c18[_0x25efab('0xa8')]('i.OpenchannelAccountId\x20IS\x20NULL'),_0x355149[_0x25efab('0xa8')](_0x25efab('0x97'))):(_0x896c18[_0x25efab('0xa8')](_0x25efab('0x92'),_[_0x25efab('0xbb')](_0x2a74e1,'id')),_0x355149[_0x25efab('0xa8')](_0x25efab('0x92'),_['map'](_0x2a74e1,'id')));});})['then'](function(){const _0x5cc16b=_0x4bbbe5;db['sequelize']['query'](_0x896c18[_0x5cc16b('0xc8')](),_0xbe6652)['then'](function(_0x2fb68c){const _0x483f9e=_0x5cc16b;_0x6ce902['count']=_0x2fb68c[_0x483f9e('0x5d')];if(_0x6ce902['count']===0x0)return[];return db[_0x483f9e('0x2d')][_0x483f9e('0x64')](_0x566c84[_0x483f9e('0xc8')](),_0xbe6652)[_0x483f9e('0x13')](function(_0x10eb21){const _0x15e051=_0x483f9e;_0x3a801f=_[_0x15e051('0x6e')](_0x10eb21,'id'),_0xbe6652=_[_0x15e051('0x1a')](_0xbe6652,{'model':db[_0x15e051('0x53')],'mapToModel':!![],'raw':!![],'nest':!![]});_0x38e20d[_0x15e051('0x64')][_0x15e051('0x96')]?_0xcacc60[_0x15e051('0x2')][_0x15e051('0x8c')](function(_0x11d5c3){const _0x5c9db1=_0x15e051;_0x355149[_0x5c9db1('0x98')]('i.'+_0x11d5c3);}):(_0x355149['field'](_0x15e051('0x7'),_0x15e051('0x27')),_0x355149[_0x15e051('0x98')](_0x15e051('0xdd'),_0x15e051('0x8a')),_0x355149[_0x15e051('0x98')]('a.mandatoryDisposition',_0x15e051('0x9a')),_0x355149[_0x15e051('0x98')](_0x15e051('0x41')),_0x355149['field'](_0x15e051('0x7f'),_0x15e051('0x63')),_0x355149[_0x15e051('0x98')](_0x15e051('0x10'),'Contact.lastName'),_0x355149[_0x15e051('0x98')]('c.email',_0x15e051('0xc1')),_0x355149[_0x15e051('0x98')](_0x15e051('0x6a'),_0x15e051('0xa7')),_0x355149[_0x15e051('0x98')](_0x15e051('0x71'),'Contact.mobile'),_0x355149[_0x15e051('0x98')](_0x15e051('0x56'),_0x15e051('0x7a')),_0x355149[_0x15e051('0x98')](_0x15e051('0x88'),_0x15e051('0xcf')),_0x355149[_0x15e051('0x98')](_0x15e051('0x3'),_0x15e051('0xbf')),_0x355149[_0x15e051('0x98')](_0x15e051('0xad'),'TagIds'));if(_0xcacc60[_0x15e051('0x30')])_0x355149[_0x15e051('0x30')](_0xcacc60['limit']);if(_0xcacc60[_0x15e051('0x75')])_0x355149[_0x15e051('0x75')](_0xcacc60[_0x15e051('0x75')]);return db['sequelize'][_0x15e051('0x64')](_0x355149[_0x15e051('0xc8')](),_0xbe6652);})[_0x483f9e('0x13')](function(_0x3ea4d9){const _0x193af6=_0x483f9e;return _0x2ba6db[_0x193af6('0xa8')](_0x193af6('0x55'),_[_0x193af6('0xbb')](_0x3ea4d9,'id')),db[_0x193af6('0x2d')][_0x193af6('0x64')](_0x2ba6db[_0x193af6('0xc8')](),_0xbe6652)[_0x193af6('0x13')](function(_0x1e3f92){const _0xcf332b=_0x193af6,_0x5022f9=_[_0xcf332b('0x9')](_0x1e3f92,'OpenchannelInteractionId'),_0x2d3ded=[];return _0x3ea4d9[_0xcf332b('0x8c')](function(_0x5c5db1){const _0x333f17=_0xcf332b;_0x2d3ded[_0x333f17('0x5e')](updateOpenchannelInteraction(_0x5c5db1,_0x3a801f,_0x5022f9));}),Promise[_0xcf332b('0xe0')](_0x2d3ded);});});})[_0x5cc16b('0x13')](function(_0x4ec379){const _0x3e00f3=_0x5cc16b;return _0x6ce902[_0x3e00f3('0x19')]=_0x4ec379,_0x6ce902;})['then'](respondWithFilteredResult(_0x468317,_0xcacc60));})[_0x4bbbe5('0x9c')](handleError(_0x468317,null));},exports[_0x124cbb('0x23')]=function(_0x38d941,_0xb4cb34){const _0x53ed10=_0x124cbb,_0x3e051b={};_0x38d941['query'][_0x53ed10('0x8')]&&_0x38d941[_0x53ed10('0x64')][_0x53ed10('0x8')]===_0x53ed10('0x59')?_0x3e051b[_0x53ed10('0x59')]=_0x38d941[_0x53ed10('0xb9')]['id']:_0x3e051b['id']=_0x38d941['params']['id'];let _0x324d12={'raw':![],'where':_0x3e051b};const _0x2f491a={};return _0x2f491a[_0x53ed10('0xcb')]=_[_0x53ed10('0x65')](db['OpenchannelInteraction'][_0x53ed10('0xdf')]),_0x2f491a[_0x53ed10('0x64')]=_[_0x53ed10('0x65')](_0x38d941['query']),_0x2f491a[_0x53ed10('0x5c')]=_['intersection'](_0x2f491a[_0x53ed10('0xcb')],_0x2f491a['query']),_0x324d12[_0x53ed10('0x2')]=_['intersection'](_0x2f491a['model'],qs['fields'](_0x38d941[_0x53ed10('0x64')][_0x53ed10('0x96')])),_0x324d12['attributes']=_0x324d12[_0x53ed10('0x2')][_0x53ed10('0x5d')]?_0x324d12[_0x53ed10('0x2')]:_0x2f491a[_0x53ed10('0xcb')],_0x38d941[_0x53ed10('0x64')][_0x53ed10('0x16')]&&(_0x324d12[_0x53ed10('0xa5')]=[{'all':!![]}]),_0x324d12=_[_0x53ed10('0x1a')]({},_0x324d12,_0x38d941[_0x53ed10('0x90')]),db[_0x53ed10('0x53')][_0x53ed10('0x85')](_0x324d12)[_0x53ed10('0x13')](handleEntityNotFound(_0xb4cb34,null))[_0x53ed10('0x13')](respondWithResult(_0xb4cb34,null))['catch'](handleError(_0xb4cb34,null));},exports[_0x124cbb('0x68')]=function(_0x27ac3a,_0x36fa1d){const _0xbe9869=_0x124cbb;return db[_0xbe9869('0x53')]['create'](_0x27ac3a['body'],{})[_0xbe9869('0x13')](respondWithResult(_0x36fa1d,0xc9))['catch'](handleError(_0x36fa1d,null));},exports[_0x124cbb('0x7c')]=function(_0x2290b4,_0x53ebb9){const _0x3cb9be=_0x124cbb;return _0x2290b4[_0x3cb9be('0xb2')]['id']&&delete _0x2290b4[_0x3cb9be('0xb2')]['id'],db[_0x3cb9be('0x53')]['findOne']({'where':{'id':_0x2290b4[_0x3cb9be('0xb9')]['id']}})[_0x3cb9be('0x13')](handleEntityNotFound(_0x53ebb9,null))[_0x3cb9be('0x13')](saveUpdates(_0x2290b4[_0x3cb9be('0xb2')],null))['then'](respondWithResult(_0x53ebb9,null))[_0x3cb9be('0x9c')](handleError(_0x53ebb9,null));},exports[_0x124cbb('0x0')]=function(_0x236de6,_0x1e3d14){const _0x2f3ee1=_0x124cbb;return db[_0x2f3ee1('0x53')][_0x2f3ee1('0x85')]({'where':{'id':_0x236de6[_0x2f3ee1('0xb9')]['id']}})[_0x2f3ee1('0x13')](handleEntityNotFound(_0x1e3d14,null))['then'](removeEntity(_0x1e3d14,null))['catch'](handleError(_0x1e3d14,null));},exports[_0x124cbb('0xb0')]=function(_0x408ad3,_0x5e4889){const _0x2f439b=_0x124cbb;return db[_0x2f439b('0x53')][_0x2f439b('0xb0')]()[_0x2f439b('0x13')](respondWithResult(_0x5e4889,null))['catch'](handleError(_0x5e4889,null));},exports[_0x124cbb('0x89')]=function(_0x15b9f3,_0x651052){const _0x4d5911=_0x124cbb;return db['OpenchannelMessage'][_0x4d5911('0x85')]({'where':{'id':_0x15b9f3[_0x4d5911('0xb9')]['id']}})[_0x4d5911('0x13')](function(_0x2560b1){const _0x2c0269=_0x4d5911;if(_0x2560b1)return _0x2560b1[_0x2c0269('0x89')](_0x15b9f3['body']['ids'],{'through':_[_0x2c0269('0xcd')](_0x15b9f3[_0x2c0269('0xb2')],[_0x2c0269('0x18'),'id'])});})['then'](respondWithResult(_0x651052,null))[_0x4d5911('0x9c')](handleError(_0x651052,null));},exports[_0x124cbb('0x20')]=function(_0x31029f,_0x5210b5){const _0x168b86=_0x124cbb;let _0x415600={'raw':![],'where':{}};const _0x1d8827={},_0x5a3532={'count':0x0,'rows':[]};return db[_0x168b86('0x53')][_0x168b86('0x85')]({'where':{'id':_0x31029f[_0x168b86('0xb9')]['id']}})['then'](handleEntityNotFound(_0x5210b5,null))[_0x168b86('0x13')](function(_0x27bae6){const _0x37782c=_0x168b86;if(_0x27bae6){_0x1d8827['model']=_[_0x37782c('0x65')](db[_0x37782c('0xd0')][_0x37782c('0xdf')]),_0x1d8827[_0x37782c('0x64')]=_[_0x37782c('0x65')](_0x31029f['query']),_0x1d8827[_0x37782c('0x5c')]=_[_0x37782c('0x94')](_0x1d8827[_0x37782c('0xcb')],_0x1d8827[_0x37782c('0x64')]),_0x415600[_0x37782c('0x2')]=_[_0x37782c('0x94')](_0x1d8827['model'],qs[_0x37782c('0x96')](_0x31029f[_0x37782c('0x64')][_0x37782c('0x96')])),_0x415600[_0x37782c('0x2')]=_0x415600[_0x37782c('0x2')][_0x37782c('0x5d')]?_0x415600['attributes']:_0x1d8827[_0x37782c('0xcb')];typeof _0x31029f[_0x37782c('0x64')][_0x37782c('0x66')]===_0x37782c('0x84')&&(_0x415600['limit']=qs[_0x37782c('0x30')](_0x31029f[_0x37782c('0x64')]['limit']),_0x415600[_0x37782c('0x75')]=qs['offset'](_0x31029f[_0x37782c('0x64')]['offset']));_0x415600['order']=qs[_0x37782c('0x72')](_0x31029f[_0x37782c('0x64')]['sort']),_0x415600['where']=qs[_0x37782c('0x5c')](_[_0x37782c('0x5b')](_0x31029f[_0x37782c('0x64')],_0x1d8827['filters'])),_0x415600[_0x37782c('0xa8')][_0x37782c('0xd7')]=_0x27bae6['id'];_0x31029f['query'][_0x37782c('0xb3')]&&(_0x415600[_0x37782c('0xa8')]=_['merge'](_0x415600[_0x37782c('0xa8')],{[Op['or']]:_['map'](_0x415600[_0x37782c('0x2')],function(_0x447129){const _0x4cf6cd=_0x37782c,_0x8e7ae9={};return _0x8e7ae9[_0x447129]={[Op[_0x4cf6cd('0x31')]]:'%'+_0x31029f[_0x4cf6cd('0x64')][_0x4cf6cd('0xb3')]+'%'},_0x8e7ae9;})}));if(_0x31029f[_0x37782c('0x64')][_0x37782c('0x86')]){const _0x2e278f=_0x31029f[_0x37782c('0x64')]['$gte'][_0x37782c('0x5a')](','),_0x185c16={};_0x185c16[_0x2e278f[0x0]]={[Op[_0x37782c('0x51')]]:moment(_0x2e278f[0x1])['format'](_0x37782c('0x3b'))},_0x415600[_0x37782c('0xa8')]=_[_0x37782c('0x1a')](_0x415600[_0x37782c('0xa8')],_0x185c16);}return _0x415600=_[_0x37782c('0x1a')]({},_0x415600,_0x31029f[_0x37782c('0x90')]),db['OpenchannelMessage'][_0x37782c('0xc6')]({'where':_0x415600[_0x37782c('0xa8')]})[_0x37782c('0x13')](function(_0xd91491){const _0x377b53=_0x37782c;return _0x5a3532['count']=_0xd91491,_0x31029f[_0x377b53('0x64')][_0x377b53('0x16')]&&(_0x415600[_0x377b53('0xa5')]=[{'all':!![]}]),db['OpenchannelMessage'][_0x377b53('0x78')](_0x415600);})[_0x37782c('0x13')](function(_0x3bebb0){const _0x23553c=_0x37782c;return _0x5a3532[_0x23553c('0x19')]=_0x3bebb0,_0x5a3532;});}})[_0x168b86('0x13')](respondWithFilteredResult(_0x5210b5,_0x415600))[_0x168b86('0x9c')](handleError(_0x5210b5,null));},exports[_0x124cbb('0x77')]=function(_0x212bfc,_0xf5cfa6){const _0x75d2e=_0x124cbb;return db[_0x75d2e('0x53')]['findOne']({'where':{'id':_0x212bfc[_0x75d2e('0xb9')]['id']}})['then'](function(_0x35ee75){const _0x5e08af=_0x75d2e;if(_0x35ee75)return _0x35ee75[_0x5e08af('0x7e')](_0x212bfc[_0x5e08af('0xb2')][_0x5e08af('0x18')],{'through':_['omit'](_0x212bfc['body'],[_0x5e08af('0x18'),'id'])})['then'](function(){const _0x37046f=_0x5e08af;return db['Tag'][_0x37046f('0x78')]({'attributes':['id',_0x37046f('0x3c'),'color'],'where':{'id':_0x212bfc[_0x37046f('0xb2')]['ids']}});})[_0x5e08af('0x13')](function(_0x254686){const _0xce19af=_0x5e08af;return socket[_0xce19af('0xa')](_0xce19af('0x9b'),{'id':Number(_0x212bfc[_0xce19af('0xb9')]['id']),'tags':_0x254686||[]}),{'id':Number(_0x212bfc[_0xce19af('0xb9')]['id']),'tags':_0x254686||[]};});})[_0x75d2e('0x13')](respondWithResult(_0xf5cfa6,null))[_0x75d2e('0x9c')](handleError(_0xf5cfa6,null));},exports[_0x124cbb('0x7b')]=function(_0x34bf40,_0x663a3f){const _0x3c5bfa=_0x124cbb;return db['OpenchannelInteraction']['findOne']({'where':{'id':_0x34bf40[_0x3c5bfa('0xb9')]['id']}})['then'](handleEntityNotFound(_0x663a3f,null))['then'](function(_0x129279){const _0x1ce292=_0x3c5bfa;if(_0x129279)return _0x129279[_0x1ce292('0x7b')](_0x34bf40[_0x1ce292('0x64')][_0x1ce292('0x18')]);})[_0x3c5bfa('0x13')](respondWithStatusCode(_0x663a3f,null))[_0x3c5bfa('0x9c')](handleError(_0x663a3f,null));},exports[_0x124cbb('0x93')]=function(_0x34fe02,_0x1dd965){const _0x44b782=_0x124cbb,_0x5b4dae=moment()[_0x44b782('0x47')]()['toString'](),_0x256f03=path['join'](config[_0x44b782('0xab')],_0x44b782('0x6'),_0x44b782('0xd9')),_0x46926a=path['join'](config[_0x44b782('0xab')],_0x44b782('0xbd'),_0x44b782('0x6'),_0x44b782('0x45')),_0x5f38a2=path[_0x44b782('0x8e')](_0x256f03,_0x5b4dae),_0x3625bb=util[_0x44b782('0x44')]('transcript-%d-%s.zip',_0x34fe02[_0x44b782('0xb9')]['id'],_0x5b4dae),_0x3325e4=path['join'](_0x256f03,_0x3625bb),_0x4afc23=[];_0x4afc23[_0x44b782('0x5e')]({'model':db[_0x44b782('0xd5')],'as':_0x44b782('0xd5'),'attributes':['id',_0x44b782('0x5f')],'raw':!![]}),_0x4afc23['push']({'model':db[_0x44b782('0x39')],'as':_0x44b782('0x81'),'attributes':['id','firstName','lastName'],'raw':!![]});_0x34fe02[_0x44b782('0x64')][_0x44b782('0x45')]&&_0x4afc23['push']({'model':db[_0x44b782('0x34')],'as':_0x44b782('0x34'),'raw':!![]});const _0x4351d5=[{'model':db[_0x44b782('0xd0')],'as':_0x44b782('0x38'),'attributes':['id','body',_0x44b782('0x2e'),_0x44b782('0x1d'),_0x44b782('0x80'),_0x44b782('0xc5')],'include':_0x4afc23}];return _0x4351d5[_0x44b782('0x5e')]({'model':db['OpenchannelAccount'],'as':_0x44b782('0x54'),'attributes':['id','name']}),_0x4351d5['push']({'model':db[_0x44b782('0xd5')],'as':'Owner','attributes':['id',_0x44b782('0x5f')]}),db[_0x44b782('0x53')]['findOne']({'where':{'id':_0x34fe02['params']['id']},'include':_0x4351d5})['then'](handleEntityNotFound(_0x1dd965,null))[_0x44b782('0x13')](function(_0x23eeb2){const _0xc59661=_0x44b782;if(_0x23eeb2){const _0x1617b3=_0x23eeb2[_0xc59661('0xd4')]({'plain':!![]});fs[_0xc59661('0xf')](_0x5f38a2);const _0x1e3359={'format':'A4','border':'10px','header':{'height':_0xc59661('0xac'),'contents':{'first':_0xc59661('0x21')}},'footer':{'height':_0xc59661('0x4f'),'contents':{'default':util[_0xc59661('0x44')](_0xc59661('0xce'),util[_0xc59661('0x44')](_0xc59661('0x17'),'Openchannel',_0x1617b3['id']),moment()[_0xc59661('0x44')]('YYYY-MM-DD')[_0xc59661('0xc8')]())}}},_0x4e0b93={'channel':_0xc59661('0x33'),'account':_0x1617b3['Account']['name'],'agent':_0x1617b3[_0xc59661('0xe')]?_0x1617b3[_0xc59661('0xe')]['fullname']:_0xc59661('0xa9'),'createdAt':moment(_0x1617b3[_0xc59661('0x2e')])[_0xc59661('0x44')](_0xc59661('0x3b'))[_0xc59661('0xc8')](),'closedAt':_0x1617b3['closed']?moment(_0x1617b3['closedAt'])[_0xc59661('0x44')](_0xc59661('0x3b'))[_0xc59661('0xc8')]():'','disposition':_0x1617b3['disposition'],'visibility':_0x1617b3[_0xc59661('0xdb')]?_0xc59661('0xb6'):_0xc59661('0x24'),'messages':_(_0x1617b3[_0xc59661('0x38')])[_0xc59661('0xb3')]({'secret':![]})['map'](function(_0x589f55){const _0x5a51e2=_0xc59661;if(_0x589f55[_0x5a51e2('0x34')]){const _0x30c52c=path['join'](_0x46926a,_0x589f55[_0x5a51e2('0x34')]['basename']);fs[_0x5a51e2('0x5')](_0x30c52c)&&fs['createReadStream'](_0x30c52c)['pipe'](fs[_0x5a51e2('0xc2')](path[_0x5a51e2('0x8e')](_0x5f38a2,_0x589f55[_0x5a51e2('0x34')]['basename'])));}return{'date':moment(_0x589f55[_0x5a51e2('0x2e')])[_0x5a51e2('0x44')](_0x5a51e2('0x3b'))['toString'](),'sender':_0x589f55[_0x5a51e2('0x1d')]===_0x5a51e2('0x83')?_0x589f55[_0x5a51e2('0xd5')]?_0x589f55['User']['fullname']:_0x5a51e2('0xd'):_0x589f55[_0x5a51e2('0x81')][_0x5a51e2('0x43')]+(_0x589f55[_0x5a51e2('0x81')][_0x5a51e2('0x4d')]?'\x20'+_0x589f55[_0x5a51e2('0x81')][_0x5a51e2('0x4d')]:''),'body':_0x589f55[_0x5a51e2('0x34')]?_0x589f55['Attachment'][_0x5a51e2('0xa0')]:_0x589f55[_0x5a51e2('0xb2')],'direction':_0x589f55[_0x5a51e2('0x1d')]===_0x5a51e2('0x83')?'A':'C','secret':_0x589f55[_0x5a51e2('0x80')],'read':_0x589f55['read'],'attachment':_0x589f55[_0x5a51e2('0x34')]};})[_0xc59661('0x36')]()};return ejs[_0xc59661('0x61')](path[_0xc59661('0x8e')](config[_0xc59661('0xab')],_0xc59661('0xbd'),_0xc59661('0xd8'),_0xc59661('0xb7')),{'interaction':_0x4e0b93})['then'](function(_0xe388d4){return new Promise(function(_0x1dff02,_0x15c96e){const _0x260350=a480_0x4831;pdf[_0x260350('0x68')](_0xe388d4,_0x1e3359)[_0x260350('0xd3')](path['join'](_0x5f38a2,_0x260350('0x6b')+_0x1617b3['id']+'-'+_0x5b4dae+'.pdf'),function(_0x491db6,_0x4620fa){if(_0x491db6)return _0x15c96e(_0x491db6);_0x1dff02(_0x4620fa);});});})[_0xc59661('0x13')](function(){const _0x47f456=_0xc59661;return new Promise(function(_0x5b76b6,_0x4865dc){zipdir(_0x5f38a2,{'saveTo':_0x3325e4},function(_0x16f276,_0x40eb81){if(_0x16f276)return _0x4865dc(_0x16f276);return _0x5b76b6(_0x40eb81);});})[_0x47f456('0x13')](function(){return new Promise(function(_0x4f69b8,_0xe6ac03){rimraf(_0x5f38a2,function(_0x361101){if(_0x361101)_0xe6ac03(_0x361101);return _0x4f69b8();});});})[_0x47f456('0x13')](function(){return _0x1dd965['download'](_0x3325e4,_0x3625bb,function(_0x24f7ac){const _0x472512=a480_0x4831;_0x24f7ac?console['log'](_0x472512('0xd6'),_0x24f7ac):fs[_0x472512('0xda')](_0x3325e4);});});});}else return _0x1dd965[_0xc59661('0x50')](0xc8);})['catch'](handleError(_0x1dd965,null));}; \ No newline at end of file +const a480_0x5622=['all','40px','it.OpenchannelInteractionId\x20=\x20i.id','%s\x20#%d','include','format','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL','download','openchannel_interaction_has_tags','i.OpenchannelAccountId\x20IN\x20?','30px','expr','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
Interaction\x20Transcript
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','findAll','OpenchannelInteraction','Contact.lastName','OpenchannelAccount','\x20=\x20?','tools_tags','TagIds','Owner','getOpenchannelAccounts','downloadInteraction.html','`unreadMessages`\x20>\x200','create','sqlOperator','openchannelInteractionTags:save','secret','N.A.','fields','OpenchannelInteractionId','body','basename','filter','i.id','ui.OpenchannelInteractionId\x20IN\x20?','SELECT','openchannel_messages','Owner.internal','CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?','u.id\x20=\x20ui.UserId','i.OpenchannelAccountId\x20IS\x20NULL','MATCH\x20(me.body)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','createWriteStream','send','includeAll','i.from\x20LIKE\x20?','fullname','journey','YYYY-MM-DD','offset','createdAt','ejs','Contact.email','color','value','existsSync','fieldName','me.OpenchannelInteractionId\x20=\x20i.id','field','Contact.fax','Account','find','lodash','10px','concat','addTags','sort','cm_contacts','zip-dir','Contact','buildExpression','like','pick','closed','split','null','Sequelize','moment','limit','ids','map','omit','group','a.mandatoryDisposition','c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?','undefined','Attachment','replace','Content-Range','findOne','err','type','i.createdAt\x20BETWEEN\x20?\x20AND\x20?','pipe','mkdirSync','Openchannel','json','keys','u.id','join','gte','update','register','status','isArray','./openchannelInteraction.socket','transcript-%d-%s.zip','model','.pdf','sendStatus','filters','user_has_openchannel_interactions','t.id\x20IN\x20?','unreadMessages','c.phone','Tag','compact','having','describe','catch','o.id\x20=\x20i.UserId','i.OpenchannelAccountId\x20IS\x20NOT\x20NULL','System','UserId','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{page}}/{{pages}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','isEmpty','start','o.fullname','User','name','order','../../components/parsers/qs','`\x20>\x200','\x20IS\x20NULL','rimraf','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','$lte','then','../../rediscache','clone','nolimit','params','$substring','Tags','addMessage','closedAt','length','query','tmp','../../mysqldb','Account.key','DESC','ContactId','`\x20=\x200','text','keyBy','getMessages','count','transcript-','attributes','set','from','openchannel_interactions','out','end','intersection','push','../../config/environment','conditions','search','files','options','Owner.fullname','forEach','error','tag','attachments','removeTags','disposition','users','rawAttributes','../../config/logger','YYYY-MM-DD\x20HH:mm:ss','toString','left_join','sequelize','api','OpenchannelMessage','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','squel','firstName','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','read','isNumeric','direction','Messages','parse','index','t.id\x20=\x20it.TagId','merge','Contact.mobile','c.firstName','QueryTypes','where','stack','getFullTextValue','toFile','path','destroy','select','u.fullname','root','../../components/parsers/advancedSearch','OpenchannelAccountId','createReadStream','$gte'];(function(_0x499d59,_0x562266){const _0x4c8fe6=function(_0x570c54){while(--_0x570c54){_0x499d59['push'](_0x499d59['shift']());}};_0x4c8fe6(++_0x562266);}(a480_0x5622,0x17d));const a480_0x4c8f=function(_0x499d59,_0x562266){_0x499d59=_0x499d59-0x0;let _0x4c8fe6=a480_0x5622[_0x499d59];return _0x4c8fe6;};const _0x5e7605=a480_0x4c8f;'use strict';const pdf=require('html-pdf'),rimraf=require(_0x5e7605('0xbc')),zipdir=require(_0x5e7605('0x7a')),moment=require(_0x5e7605('0x83')),util=require('util'),path=require(_0x5e7605('0x2c')),ejs=require(_0x5e7605('0x69')),fs=require('fs'),_=require(_0x5e7605('0x74')),squel=require(_0x5e7605('0x1a')),{getSocket}=require(_0x5e7605('0xc0')),socket=getSocket(),qs=require(_0x5e7605('0xb9')),as=require(_0x5e7605('0x31')),logger=require(_0x5e7605('0x12'))(_0x5e7605('0x17')),config=require(_0x5e7605('0x4')),db=require(_0x5e7605('0xcb'))['db'],{Op}=require('sequelize');require(_0x5e7605('0x9f'))[_0x5e7605('0x9c')](socket);function respondWithStatusCode(_0x570c54,_0x121c0a){return _0x121c0a=_0x121c0a||0xcc,function(_0x314d2e){const _0x2e09e5=a480_0x4c8f;if(_0x314d2e)return _0x570c54[_0x2e09e5('0xa3')](_0x121c0a);return _0x570c54['status'](_0x121c0a)[_0x2e09e5('0x1')]();};}function respondWithResult(_0x544cdf,_0xdb64ff){return _0xdb64ff=_0xdb64ff||0xc8,function(_0x545835){const _0x494817=a480_0x4c8f;if(_0x545835)return _0x544cdf[_0x494817('0x9d')](_0xdb64ff)[_0x494817('0x96')](_0x545835);};}function respondWithFilteredResult(_0x4c3a2b,_0x4430ca){return function(_0x4f4838){const _0x5a450c=a480_0x4c8f;if(_0x4f4838){const _0x41c1aa=_0x4f4838['count'],_0x5236c6=_0x4430ca[_0x5a450c('0x67')];let _0x379023=_0x4430ca[_0x5a450c('0x67')]+_0x4430ca[_0x5a450c('0x84')],_0x522ced;return _0x379023>=_0x41c1aa?(_0x379023=_0x41c1aa,_0x522ced=0xc8):_0x522ced=0xce,_0x4c3a2b[_0x5a450c('0x9d')](_0x522ced),_0x4c3a2b[_0x5a450c('0xd6')](_0x5a450c('0x8e'),_0x5236c6+'-'+_0x379023+'/'+_0x41c1aa)[_0x5a450c('0x96')](_0x4f4838);}return null;};}function saveUpdates(_0xe208ed){return function(_0x59d894){const _0x31bc26=a480_0x4c8f;if(_0x59d894)return _0x59d894['update'](_0xe208ed)[_0x31bc26('0xbf')](function(_0x1f3d15){return _0x1f3d15;});return null;};}function removeEntity(_0x11d05c){return function(_0x2b68f1){const _0x12ebfe=a480_0x4c8f;if(_0x2b68f1)return _0x2b68f1['destroy']()[_0x12ebfe('0xbf')](function(){_0x11d05c['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x3a4b9a){return function(_0x118928){const _0xf4e743=a480_0x4c8f;return!_0x118928&&_0x3a4b9a[_0xf4e743('0xa3')](0x194),_0x118928;};}function handleError(_0x3e0d7a,_0x3e41d6){return _0x3e41d6=_0x3e41d6||0x1f4,function(_0x2e3d56){const _0x26de62=a480_0x4c8f;logger[_0x26de62('0xb')](_0x2e3d56[_0x26de62('0x29')]),_0x2e3d56[_0x26de62('0xb7')]&&delete _0x2e3d56[_0x26de62('0xb7')],_0x3e0d7a[_0x26de62('0x9d')](_0x3e41d6)[_0x26de62('0x61')](_0x2e3d56);};}function getInteractionUsers(_0x1a9427,_0x41d56a){return new Promise(function(_0x2ee472,_0x9ce541){const _0x2f2efc=a480_0x4c8f;try{_0x41d56a[_0x1a9427['id']]&&(_0x1a9427['Users']=_[_0x2f2efc('0x86')](_0x41d56a[_0x1a9427['id']],function(_0xd2b3d4){const _0x79e4a8=_0x2f2efc;return{'id':_0xd2b3d4['id'],'fullname':_0xd2b3d4[_0x79e4a8('0x64')]};}));}catch(_0x196207){_0x9ce541(_0x196207);}_0x2ee472(_0x1a9427);});}function getInteractionTags(_0x5efc92,_0x264af8){return new Promise(function(_0x9aaf6c,_0x5d990a){const _0x3355b1=a480_0x4c8f;try{_0x5efc92[_0x3355b1('0x48')]&&(_0x5efc92['Tags']=[],_0x5efc92[_0x3355b1('0x48')][_0x3355b1('0x80')](',')[_0x3355b1('0xa')](function(_0x14dbb9){const _0x102271=_0x3355b1;_0x5efc92[_0x102271('0xc5')][_0x102271('0x3')](_0x264af8[_0x14dbb9]);})),delete _0x5efc92['TagIds'];}catch(_0x3c6c4c){_0x5d990a(_0x3c6c4c);}_0x9aaf6c(_0x5efc92);});}function updateOpenchannelInteraction(_0x261525,_0x1226bf,_0x2dc1dc){return new Promise(function(_0x124ee9,_0x366109){const _0x354fa2=a480_0x4c8f;return getInteractionUsers(_0x261525,_0x2dc1dc)['then'](function(_0x2e4c52){return getInteractionTags(_0x2e4c52,_0x1226bf);})[_0x354fa2('0xbf')](function(_0x2b3cdd){_0x124ee9(_0x2b3cdd);})['catch'](function(_0x106ab3){_0x366109(_0x106ab3);});});}exports[_0x5e7605('0x22')]=function(_0x522722,_0xdb8c0){const _0x494dc5=_0x5e7605,_0x3dc536={},_0x29ad15={},_0xe4d7a={'count':0x0,'rows':[]},_0x25af9b=_[_0x494dc5('0x86')](db[_0x494dc5('0x43')][_0x494dc5('0x11')],function(_0x35f247){const _0x1b3a0c=_0x494dc5;return{'name':_0x35f247[_0x1b3a0c('0x6e')],'type':_0x35f247[_0x1b3a0c('0x91')]['key']};});_0x29ad15[_0x494dc5('0xa1')]=_['map'](_0x25af9b,_0x494dc5('0xb7')),_0x29ad15[_0x494dc5('0xc9')]=_['keys'](_0x522722[_0x494dc5('0xc9')]),_0x29ad15[_0x494dc5('0xa4')]=_[_0x494dc5('0x2')](_0x29ad15[_0x494dc5('0xa1')],_0x29ad15['query']),_0x3dc536[_0x494dc5('0xd5')]=_[_0x494dc5('0x2')](_0x29ad15[_0x494dc5('0xa1')],qs[_0x494dc5('0x52')](_0x522722[_0x494dc5('0xc9')][_0x494dc5('0x52')])),_0x3dc536[_0x494dc5('0xd5')]=_0x3dc536[_0x494dc5('0xd5')][_0x494dc5('0xc8')]?_0x3dc536[_0x494dc5('0xd5')]:_0x29ad15[_0x494dc5('0xa1')];typeof _0x522722[_0x494dc5('0xc9')][_0x494dc5('0xc2')]===_0x494dc5('0x8b')&&(_0x3dc536[_0x494dc5('0x84')]=qs['limit'](_0x522722[_0x494dc5('0xc9')]['limit']),_0x3dc536['offset']=qs['offset'](_0x522722['query'][_0x494dc5('0x67')]));_0x3dc536[_0x494dc5('0xb8')]=qs[_0x494dc5('0x78')](_0x522722[_0x494dc5('0xc9')]['sort']),_0x3dc536[_0x494dc5('0x28')]=qs[_0x494dc5('0xa4')](_[_0x494dc5('0x7e')](_0x522722[_0x494dc5('0xc9')],_0x29ad15[_0x494dc5('0xa4')]),_0x25af9b);let _0x537cb5=[];const _0x2cf059=squel[_0x494dc5('0x2e')]()[_0x494dc5('0x70')]('id')[_0x494dc5('0x70')](_0x494dc5('0xb7'))['field']('color')['from'](_0x494dc5('0x47')),_0x2cb42b=squel['select']()[_0x494dc5('0x70')](_0x494dc5('0x98'))[_0x494dc5('0x70')](_0x494dc5('0x2f'))['field']('ui.OpenchannelInteractionId')[_0x494dc5('0xd7')](_0x494dc5('0xa5'),'ui')[_0x494dc5('0x15')](_0x494dc5('0x10'),'u',_0x494dc5('0x5d')),_0x1b38ab=squel[_0x494dc5('0x2e')]()['from'](_0x494dc5('0xd8'),'i')[_0x494dc5('0x15')](_0x494dc5('0x79'),'c',_0x494dc5('0x3b'))['left_join'](_0x494dc5('0x10'),'o',_0x494dc5('0xae'))[_0x494dc5('0x15')]('openchannel_accounts','a','a.id\x20=\x20i.OpenchannelAccountId')['left_join'](_0x494dc5('0x5a'),'me',_0x494dc5('0x6f'))[_0x494dc5('0x15')](_0x494dc5('0x3d'),'it',_0x494dc5('0x37'))[_0x494dc5('0x15')](_0x494dc5('0x47'),'t',_0x494dc5('0x23')),_0x54c250=squel[_0x494dc5('0x40')]();let _0x221b39=[];const _0x306c37=squel[_0x494dc5('0x40')]();let _0x40d138;if(_0x522722[_0x494dc5('0xc9')][_0x494dc5('0x6')]){_0x40d138=as['parseSearch'](_0x522722[_0x494dc5('0xc9')]['search']);const _0x4ecc94=_0x40d138[_0x494dc5('0x4e')];for(let _0x27bbc2=0x0;_0x27bbc2<_0x40d138[_0x494dc5('0x5')][_0x494dc5('0xc8')];_0x27bbc2++){const _0x3d2b61=_0x40d138[_0x494dc5('0x5')][_0x27bbc2],_0x575043='i';let _0x170fa4,_0x51eb81=_[_0x494dc5('0x73')](_0x25af9b,['name',_0x3d2b61[_0x494dc5('0x70')]]);if(!_0x51eb81)switch(_0x3d2b61[_0x494dc5('0x70')]){case _0x494dc5('0xa7'):_0x3d2b61['value']==0x1?_0x1b38ab['having']('`'+_0x3d2b61['field']+_0x494dc5('0xcf')):_0x1b38ab[_0x494dc5('0xab')]('`'+_0x3d2b61[_0x494dc5('0x70')]+_0x494dc5('0xba'));break;case _0x494dc5('0x7b'):if(_0x3d2b61['operator']===_0x494dc5('0xc4')){if(_0x3d2b61[_0x494dc5('0x6c')][_0x494dc5('0x80')]('\x20')[_0x494dc5('0xc8')]>0x1)_0x54c250[_0x4ecc94]('MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs[_0x494dc5('0x2a')](_0x3d2b61['value']),null);else{const _0xbb4668='%'+_0x3d2b61[_0x494dc5('0x6c')]+'%';_0x54c250[_0x4ecc94](_0x494dc5('0x8a'),_0xbb4668,_0xbb4668,_0xbb4668);}}else _0x51eb81=_[_0x494dc5('0x73')](_0x25af9b,['name','ContactId']),_0x3d2b61[_0x494dc5('0x70')]=_0x494dc5('0xce'),_0x170fa4=as['buildExpression'](_0x575043,_0x51eb81['type'],_0x3d2b61),_0x54c250[_0x4ecc94](_0x170fa4['text'],_0x170fa4[_0x494dc5('0x6c')][_0x494dc5('0xb4')],_0x170fa4[_0x494dc5('0x6c')]['end']);break;case _0x494dc5('0xa9'):{const _0x530786=_0x3d2b61[_0x494dc5('0x6c')][_0x494dc5('0x80')](',')[_0x494dc5('0x86')](function(_0x4e4529){return Number(_0x4e4529);});_0x530786[_0x494dc5('0xa')](function(_0x360888){const _0x38db5b=_0x494dc5;_0x306c37['or'](_0x38db5b('0xbd'),'%,'+_0x360888+',%');}),_0x221b39=_['union'](_0x221b39,_0x530786);}break;case _0x494dc5('0xb6'):_0x3d2b61['operator']===_0x494dc5('0xc4')?_0x54c250[_0x4ecc94](_0x494dc5('0x19'),'%'+_0x3d2b61[_0x494dc5('0x6c')]+'%',null):(_0x51eb81=_[_0x494dc5('0x73')](_0x25af9b,[_0x494dc5('0xb7'),_0x494dc5('0xb1')]),_0x3d2b61[_0x494dc5('0x70')]='UserId',_0x170fa4=as[_0x494dc5('0x7c')](_0x575043,_0x51eb81[_0x494dc5('0x91')],_0x3d2b61),_0x54c250[_0x4ecc94](_0x170fa4[_0x494dc5('0xd0')],_0x170fa4[_0x494dc5('0x6c')][_0x494dc5('0xb4')],_0x170fa4[_0x494dc5('0x6c')]['end']));break;case'body':_0x170fa4=as[_0x494dc5('0x7c')]('me',null,_0x3d2b61),_0x54c250[_0x4ecc94](_0x170fa4[_0x494dc5('0xd0')],_0x170fa4[_0x494dc5('0x6c')]['start'],_0x170fa4[_0x494dc5('0x6c')][_0x494dc5('0x1')]);break;}else _0x170fa4=as[_0x494dc5('0x7c')](_0x575043,_0x51eb81[_0x494dc5('0x91')],_0x3d2b61),_0x54c250[_0x4ecc94](_0x170fa4[_0x494dc5('0xd0')],_0x170fa4['value'][_0x494dc5('0xb4')],_0x170fa4[_0x494dc5('0x6c')]['end']);}}else{const _0x575c92=_(_0x522722[_0x494dc5('0xc9')])[_0x494dc5('0x97')]()[_0x494dc5('0x86')](function(_0x269dd3){const _0x32e960=_0x494dc5;return _['some'](_0x25af9b,[_0x32e960('0xb7'),_0x269dd3])?_0x269dd3:undefined;})[_0x494dc5('0xaa')]()[_0x494dc5('0x6c')]();!_['isEmpty'](_0x575c92)&&_0x575c92[_0x494dc5('0xa')](function(_0x23bf1d){const _0x37e5d1=_0x494dc5;if(_0x23bf1d==='OpenchannelAccountId')_0x1b38ab[_0x37e5d1('0x28')](_0x37e5d1('0x3e'),[][_0x37e5d1('0x76')](_0x522722[_0x37e5d1('0xc9')][_0x23bf1d]));else{if(_0x23bf1d===_0x37e5d1('0x68')){const _0x3ea4e1=JSON[_0x37e5d1('0x21')](_0x522722['query'][_0x23bf1d])[_0x37e5d1('0x34')],_0x10a977=JSON['parse'](_0x522722[_0x37e5d1('0xc9')][_0x23bf1d])[_0x37e5d1('0xbe')];_0x1b38ab[_0x37e5d1('0x28')](_0x37e5d1('0x92'),_0x3ea4e1,_0x10a977);}else _0x522722[_0x37e5d1('0xc9')][_0x23bf1d]===_0x37e5d1('0x81')?_0x1b38ab[_0x37e5d1('0x28')]('i.'+_0x23bf1d+_0x37e5d1('0xbb')):_0x1b38ab['where']('i.'+_0x23bf1d+_0x37e5d1('0x46'),_0x522722[_0x37e5d1('0xc9')][_0x23bf1d]);}});_0x522722['query'][_0x494dc5('0x1d')]&&(_0x522722[_0x494dc5('0xc9')][_0x494dc5('0x1d')]==0x1?_0x1b38ab[_0x494dc5('0xab')]('`unreadMessages`\x20=\x200'):_0x1b38ab[_0x494dc5('0xab')](_0x494dc5('0x4c')));_0x522722['query'][_0x494dc5('0xc')]&&(_0x221b39=_[_0x494dc5('0x9e')](_0x522722[_0x494dc5('0xc9')]['tag'])?_0x522722['query'][_0x494dc5('0xc')]:new Array(_0x522722['query'][_0x494dc5('0xc')]),_0x221b39[_0x494dc5('0xa')](function(_0x4163a6){const _0x5eb62f=_0x494dc5;_0x306c37['or'](_0x5eb62f('0xbd'),'%,'+_0x4163a6+',%');}));if(_0x522722[_0x494dc5('0xc9')][_0x494dc5('0x56')]){const _0x1ac064=_0x522722['query'][_0x494dc5('0x56')][_0x494dc5('0x8d')]('\x5c','\x5c\x5c')[_0x494dc5('0x8d')]('\x27\x27','\x27\x27\x27\x27');qs[_0x494dc5('0x1e')](_0x1ac064)?_0x54c250['or']('i.id\x20LIKE\x20?',_0x1ac064+'%'):_0x54c250['or'](_0x494dc5('0x5f'),qs['getFullTextValue'](_0x1ac064))['or'](_0x494dc5('0x63'),_0x1ac064+'%')['or'](_0x494dc5('0x5c'),_0x1ac064+'%');}}_0x1b38ab[_0x494dc5('0x28')](_0x54c250),_0x1b38ab[_0x494dc5('0x88')]('i.id');let _0x48ebe3={'type':db[_0x494dc5('0x82')][_0x494dc5('0x27')][_0x494dc5('0x59')],'raw':!![]};const _0x6f3341=_0x1b38ab[_0x494dc5('0xc1')]();_0x6f3341[_0x494dc5('0x70')](_0x494dc5('0x57')),_0x6f3341['field'](_0x494dc5('0x1c'),_0x494dc5('0xa7')),_0x3dc536[_0x494dc5('0xb8')]&&_0x3dc536['order'][_0x494dc5('0xa')](function(_0x32288b){const _0x266b80=_0x494dc5;_0x1b38ab['order']('i.'+_0x32288b[0x0],_0x32288b[0x1]===_0x266b80('0xcd')?![]:!![]);}),!_[_0x494dc5('0xb3')](_0x221b39)&&(_0x1b38ab[_0x494dc5('0xab')](_0x306c37),_0x6f3341[_0x494dc5('0x28')](_0x494dc5('0xa6'),_0x221b39)),Promise['resolve']()[_0x494dc5('0xbf')](function(){const _0x4ccc65=_0x494dc5;if(!_0x40d138){if(_0x522722[_0x4ccc65('0xc9')][_0x4ccc65('0x32')]||_0x522722[_0x4ccc65('0xc9')][_0x4ccc65('0x65')])return;_0x6f3341[_0x4ccc65('0x28')]('i.OpenchannelAccountId\x20IS\x20NOT\x20NULL'),_0x1b38ab[_0x4ccc65('0x28')](_0x4ccc65('0xaf'));return;}return _0x522722['user'][_0x4ccc65('0x4a')]({'attributes':['id'],'raw':!![]})[_0x4ccc65('0xbf')](function(_0x3f7295){const _0x2e659b=_0x4ccc65;_[_0x2e659b('0xb3')](_0x3f7295)?(_0x6f3341[_0x2e659b('0x28')](_0x2e659b('0x5e')),_0x1b38ab[_0x2e659b('0x28')](_0x2e659b('0x5e'))):(_0x6f3341[_0x2e659b('0x28')]('i.OpenchannelAccountId\x20IN\x20?',_[_0x2e659b('0x86')](_0x3f7295,'id')),_0x1b38ab['where'](_0x2e659b('0x3e'),_[_0x2e659b('0x86')](_0x3f7295,'id')));});})[_0x494dc5('0xbf')](function(){const _0x13042b=_0x494dc5;db[_0x13042b('0x16')][_0x13042b('0xc9')](_0x6f3341['toString'](),_0x48ebe3)[_0x13042b('0xbf')](function(_0x35c302){const _0x57d50f=_0x13042b;_0xe4d7a[_0x57d50f('0xd3')]=_0x35c302[_0x57d50f('0xc8')];if(_0xe4d7a[_0x57d50f('0xd3')]===0x0)return[];return db[_0x57d50f('0x16')][_0x57d50f('0xc9')](_0x2cf059[_0x57d50f('0x14')](),_0x48ebe3)[_0x57d50f('0xbf')](function(_0x529ecd){const _0x158093=_0x57d50f;_0x537cb5=_[_0x158093('0xd1')](_0x529ecd,'id'),_0x48ebe3=_['merge'](_0x48ebe3,{'model':db['OpenchannelInteraction'],'mapToModel':!![],'raw':!![],'nest':!![]});_0x522722[_0x158093('0xc9')][_0x158093('0x52')]?_0x3dc536[_0x158093('0xd5')][_0x158093('0xa')](function(_0x3f3c54){const _0x3ce576=_0x158093;_0x1b38ab[_0x3ce576('0x70')]('i.'+_0x3f3c54);}):(_0x1b38ab[_0x158093('0x70')](_0x158093('0x1c'),_0x158093('0xa7')),_0x1b38ab['field']('a.key',_0x158093('0xcc')),_0x1b38ab[_0x158093('0x70')](_0x158093('0x89'),'Account.mandatoryDisposition'),_0x1b38ab[_0x158093('0x70')]('i.*'),_0x1b38ab[_0x158093('0x70')](_0x158093('0x26'),'Contact.firstName'),_0x1b38ab[_0x158093('0x70')]('c.lastName',_0x158093('0x44')),_0x1b38ab[_0x158093('0x70')]('c.email',_0x158093('0x6a')),_0x1b38ab['field'](_0x158093('0xa8'),'Contact.phone'),_0x1b38ab['field']('c.mobile',_0x158093('0x25')),_0x1b38ab[_0x158093('0x70')]('c.fax',_0x158093('0x71')),_0x1b38ab[_0x158093('0x70')](_0x158093('0xb5'),_0x158093('0x9')),_0x1b38ab[_0x158093('0x70')]('o.internal',_0x158093('0x5b')),_0x1b38ab[_0x158093('0x70')]('GROUP_CONCAT(DISTINCT\x20t.id)',_0x158093('0x48')));if(_0x3dc536[_0x158093('0x84')])_0x1b38ab[_0x158093('0x84')](_0x3dc536[_0x158093('0x84')]);if(_0x3dc536[_0x158093('0x67')])_0x1b38ab[_0x158093('0x67')](_0x3dc536[_0x158093('0x67')]);return db[_0x158093('0x16')][_0x158093('0xc9')](_0x1b38ab[_0x158093('0x14')](),_0x48ebe3);})[_0x57d50f('0xbf')](function(_0x5ccc98){const _0x2077c0=_0x57d50f;return _0x2cb42b[_0x2077c0('0x28')](_0x2077c0('0x58'),_[_0x2077c0('0x86')](_0x5ccc98,'id')),db[_0x2077c0('0x16')][_0x2077c0('0xc9')](_0x2cb42b['toString'](),_0x48ebe3)[_0x2077c0('0xbf')](function(_0x1b9d14){const _0x50cbb9=_0x2077c0,_0x4a61f4=_['groupBy'](_0x1b9d14,'OpenchannelInteractionId'),_0x509200=[];return _0x5ccc98[_0x50cbb9('0xa')](function(_0x1dfef4){const _0x51a5bc=_0x50cbb9;_0x509200[_0x51a5bc('0x3')](updateOpenchannelInteraction(_0x1dfef4,_0x537cb5,_0x4a61f4));}),Promise[_0x50cbb9('0x35')](_0x509200);});});})['then'](function(_0x3a87d0){return _0xe4d7a['rows']=_0x3a87d0,_0xe4d7a;})[_0x13042b('0xbf')](respondWithFilteredResult(_0xdb8c0,_0x3dc536));})[_0x494dc5('0xad')](handleError(_0xdb8c0,null));},exports['show']=function(_0x2155ad,_0x2e96c7){const _0x588b04=_0x5e7605,_0x18d359={};_0x2155ad[_0x588b04('0xc9')][_0x588b04('0x91')]&&_0x2155ad['query'][_0x588b04('0x91')]===_0x588b04('0xd7')?_0x18d359[_0x588b04('0xd7')]=_0x2155ad['params']['id']:_0x18d359['id']=_0x2155ad[_0x588b04('0xc3')]['id'];let _0x285363={'raw':![],'where':_0x18d359};const _0x1b2d4f={};return _0x1b2d4f[_0x588b04('0xa1')]=_[_0x588b04('0x97')](db[_0x588b04('0x43')][_0x588b04('0x11')]),_0x1b2d4f[_0x588b04('0xc9')]=_['keys'](_0x2155ad['query']),_0x1b2d4f[_0x588b04('0xa4')]=_[_0x588b04('0x2')](_0x1b2d4f[_0x588b04('0xa1')],_0x1b2d4f['query']),_0x285363[_0x588b04('0xd5')]=_['intersection'](_0x1b2d4f['model'],qs[_0x588b04('0x52')](_0x2155ad[_0x588b04('0xc9')][_0x588b04('0x52')])),_0x285363[_0x588b04('0xd5')]=_0x285363[_0x588b04('0xd5')]['length']?_0x285363[_0x588b04('0xd5')]:_0x1b2d4f['model'],_0x2155ad['query'][_0x588b04('0x62')]&&(_0x285363[_0x588b04('0x39')]=[{'all':!![]}]),_0x285363=_[_0x588b04('0x24')]({},_0x285363,_0x2155ad[_0x588b04('0x8')]),db[_0x588b04('0x43')][_0x588b04('0x8f')](_0x285363)[_0x588b04('0xbf')](handleEntityNotFound(_0x2e96c7,null))[_0x588b04('0xbf')](respondWithResult(_0x2e96c7,null))[_0x588b04('0xad')](handleError(_0x2e96c7,null));},exports[_0x5e7605('0x4d')]=function(_0x3fb755,_0x20192c){const _0x2a0336=_0x5e7605;return db[_0x2a0336('0x43')][_0x2a0336('0x4d')](_0x3fb755['body'],{})[_0x2a0336('0xbf')](respondWithResult(_0x20192c,0xc9))[_0x2a0336('0xad')](handleError(_0x20192c,null));},exports[_0x5e7605('0x9b')]=function(_0xf9def5,_0x1ec4f3){const _0x54a781=_0x5e7605;return _0xf9def5[_0x54a781('0x54')]['id']&&delete _0xf9def5[_0x54a781('0x54')]['id'],db['OpenchannelInteraction'][_0x54a781('0x8f')]({'where':{'id':_0xf9def5['params']['id']}})[_0x54a781('0xbf')](handleEntityNotFound(_0x1ec4f3,null))[_0x54a781('0xbf')](saveUpdates(_0xf9def5[_0x54a781('0x54')],null))[_0x54a781('0xbf')](respondWithResult(_0x1ec4f3,null))[_0x54a781('0xad')](handleError(_0x1ec4f3,null));},exports[_0x5e7605('0x2d')]=function(_0x35d394,_0x258c50){const _0x402a52=_0x5e7605;return db['OpenchannelInteraction']['findOne']({'where':{'id':_0x35d394[_0x402a52('0xc3')]['id']}})['then'](handleEntityNotFound(_0x258c50,null))[_0x402a52('0xbf')](removeEntity(_0x258c50,null))[_0x402a52('0xad')](handleError(_0x258c50,null));},exports['describe']=function(_0x5c8a06,_0x5e0d6a){const _0x4faeb8=_0x5e7605;return db['OpenchannelInteraction'][_0x4faeb8('0xac')]()[_0x4faeb8('0xbf')](respondWithResult(_0x5e0d6a,null))[_0x4faeb8('0xad')](handleError(_0x5e0d6a,null));},exports[_0x5e7605('0xc6')]=function(_0x5e8251,_0x2b7de0){const _0x2842d7=_0x5e7605;return db['OpenchannelMessage'][_0x2842d7('0x8f')]({'where':{'id':_0x5e8251[_0x2842d7('0xc3')]['id']}})[_0x2842d7('0xbf')](function(_0x19a17a){const _0x5c3b05=_0x2842d7;if(_0x19a17a)return _0x19a17a[_0x5c3b05('0xc6')](_0x5e8251[_0x5c3b05('0x54')][_0x5c3b05('0x85')],{'through':_[_0x5c3b05('0x87')](_0x5e8251[_0x5c3b05('0x54')],['ids','id'])});})[_0x2842d7('0xbf')](respondWithResult(_0x2b7de0,null))[_0x2842d7('0xad')](handleError(_0x2b7de0,null));},exports[_0x5e7605('0xd2')]=function(_0xe07cf8,_0x1b72f7){const _0x177bc2=_0x5e7605;let _0x5c5d9a={'raw':![],'where':{}};const _0x2cfc88={},_0x227bfb={'count':0x0,'rows':[]};return db[_0x177bc2('0x43')][_0x177bc2('0x8f')]({'where':{'id':_0xe07cf8[_0x177bc2('0xc3')]['id']}})[_0x177bc2('0xbf')](handleEntityNotFound(_0x1b72f7,null))[_0x177bc2('0xbf')](function(_0xaaa434){const _0x5f2ac9=_0x177bc2;if(_0xaaa434){_0x2cfc88[_0x5f2ac9('0xa1')]=_['keys'](db['OpenchannelMessage'][_0x5f2ac9('0x11')]),_0x2cfc88['query']=_['keys'](_0xe07cf8[_0x5f2ac9('0xc9')]),_0x2cfc88[_0x5f2ac9('0xa4')]=_[_0x5f2ac9('0x2')](_0x2cfc88['model'],_0x2cfc88[_0x5f2ac9('0xc9')]),_0x5c5d9a[_0x5f2ac9('0xd5')]=_[_0x5f2ac9('0x2')](_0x2cfc88[_0x5f2ac9('0xa1')],qs[_0x5f2ac9('0x52')](_0xe07cf8[_0x5f2ac9('0xc9')][_0x5f2ac9('0x52')])),_0x5c5d9a['attributes']=_0x5c5d9a['attributes'][_0x5f2ac9('0xc8')]?_0x5c5d9a[_0x5f2ac9('0xd5')]:_0x2cfc88[_0x5f2ac9('0xa1')];typeof _0xe07cf8[_0x5f2ac9('0xc9')][_0x5f2ac9('0xc2')]===_0x5f2ac9('0x8b')&&(_0x5c5d9a['limit']=qs[_0x5f2ac9('0x84')](_0xe07cf8['query'][_0x5f2ac9('0x84')]),_0x5c5d9a[_0x5f2ac9('0x67')]=qs[_0x5f2ac9('0x67')](_0xe07cf8[_0x5f2ac9('0xc9')][_0x5f2ac9('0x67')]));_0x5c5d9a['order']=qs['sort'](_0xe07cf8[_0x5f2ac9('0xc9')][_0x5f2ac9('0x78')]),_0x5c5d9a['where']=qs[_0x5f2ac9('0xa4')](_['pick'](_0xe07cf8[_0x5f2ac9('0xc9')],_0x2cfc88[_0x5f2ac9('0xa4')])),_0x5c5d9a[_0x5f2ac9('0x28')][_0x5f2ac9('0x53')]=_0xaaa434['id'];_0xe07cf8[_0x5f2ac9('0xc9')][_0x5f2ac9('0x56')]&&(_0x5c5d9a[_0x5f2ac9('0x28')]=_[_0x5f2ac9('0x24')](_0x5c5d9a[_0x5f2ac9('0x28')],{[Op['or']]:_[_0x5f2ac9('0x86')](_0x5c5d9a[_0x5f2ac9('0xd5')],function(_0x1a89a4){const _0x2443e1=_0x5f2ac9,_0x3e8eaa={};return _0x3e8eaa[_0x1a89a4]={[Op[_0x2443e1('0x7d')]]:'%'+_0xe07cf8[_0x2443e1('0xc9')][_0x2443e1('0x56')]+'%'},_0x3e8eaa;})}));if(_0xe07cf8[_0x5f2ac9('0xc9')][_0x5f2ac9('0x34')]){const _0x21bee4=_0xe07cf8[_0x5f2ac9('0xc9')][_0x5f2ac9('0x34')]['split'](','),_0x228c6b={};_0x228c6b[_0x21bee4[0x0]]={[Op[_0x5f2ac9('0x9a')]]:moment(_0x21bee4[0x1])['format'](_0x5f2ac9('0x13'))},_0x5c5d9a[_0x5f2ac9('0x28')]=_[_0x5f2ac9('0x24')](_0x5c5d9a[_0x5f2ac9('0x28')],_0x228c6b);}return _0x5c5d9a=_['merge']({},_0x5c5d9a,_0xe07cf8[_0x5f2ac9('0x8')]),db['OpenchannelMessage']['count']({'where':_0x5c5d9a[_0x5f2ac9('0x28')]})[_0x5f2ac9('0xbf')](function(_0x278bdf){const _0x565c56=_0x5f2ac9;return _0x227bfb[_0x565c56('0xd3')]=_0x278bdf,_0xe07cf8[_0x565c56('0xc9')]['includeAll']&&(_0x5c5d9a[_0x565c56('0x39')]=[{'all':!![]}]),db[_0x565c56('0x18')]['findAll'](_0x5c5d9a);})[_0x5f2ac9('0xbf')](function(_0x2eca81){return _0x227bfb['rows']=_0x2eca81,_0x227bfb;});}})[_0x177bc2('0xbf')](respondWithFilteredResult(_0x1b72f7,_0x5c5d9a))[_0x177bc2('0xad')](handleError(_0x1b72f7,null));},exports[_0x5e7605('0x77')]=function(_0x1e64a3,_0x563c7c){const _0x48556e=_0x5e7605;return db[_0x48556e('0x43')][_0x48556e('0x8f')]({'where':{'id':_0x1e64a3[_0x48556e('0xc3')]['id']}})['then'](function(_0x22ec04){const _0x447769=_0x48556e;if(_0x22ec04)return _0x22ec04['setTags'](_0x1e64a3['body'][_0x447769('0x85')],{'through':_['omit'](_0x1e64a3[_0x447769('0x54')],[_0x447769('0x85'),'id'])})['then'](function(){const _0x366ec8=_0x447769;return db[_0x366ec8('0xa9')][_0x366ec8('0x42')]({'attributes':['id','name',_0x366ec8('0x6b')],'where':{'id':_0x1e64a3['body'][_0x366ec8('0x85')]}});})[_0x447769('0xbf')](function(_0x5bbdc2){const _0x5df215=_0x447769;return socket['emit'](_0x5df215('0x4f'),{'id':Number(_0x1e64a3[_0x5df215('0xc3')]['id']),'tags':_0x5bbdc2||[]}),{'id':Number(_0x1e64a3[_0x5df215('0xc3')]['id']),'tags':_0x5bbdc2||[]};});})['then'](respondWithResult(_0x563c7c,null))[_0x48556e('0xad')](handleError(_0x563c7c,null));},exports['removeTags']=function(_0x1a74d6,_0x30ac2a){const _0x1620e3=_0x5e7605;return db['OpenchannelInteraction'][_0x1620e3('0x8f')]({'where':{'id':_0x1a74d6[_0x1620e3('0xc3')]['id']}})[_0x1620e3('0xbf')](handleEntityNotFound(_0x30ac2a,null))[_0x1620e3('0xbf')](function(_0x4ea649){const _0x204b23=_0x1620e3;if(_0x4ea649)return _0x4ea649[_0x204b23('0xe')](_0x1a74d6[_0x204b23('0xc9')][_0x204b23('0x85')]);})[_0x1620e3('0xbf')](respondWithStatusCode(_0x30ac2a,null))[_0x1620e3('0xad')](handleError(_0x30ac2a,null));},exports['download']=function(_0x19acbf,_0x2c7832){const _0x25b6d2=_0x5e7605,_0x3dd1d8=moment()['unix']()[_0x25b6d2('0x14')](),_0x5935fb=path[_0x25b6d2('0x99')](config[_0x25b6d2('0x30')],_0x25b6d2('0x7'),_0x25b6d2('0xca')),_0x5b12d0=path[_0x25b6d2('0x99')](config[_0x25b6d2('0x30')],'server',_0x25b6d2('0x7'),_0x25b6d2('0xd')),_0x9c2fc8=path[_0x25b6d2('0x99')](_0x5935fb,_0x3dd1d8),_0x402810=util[_0x25b6d2('0x3a')](_0x25b6d2('0xa0'),_0x19acbf[_0x25b6d2('0xc3')]['id'],_0x3dd1d8),_0x106cca=path[_0x25b6d2('0x99')](_0x5935fb,_0x402810),_0x4f936b=[];_0x4f936b['push']({'model':db[_0x25b6d2('0xb6')],'as':'User','attributes':['id',_0x25b6d2('0x64')],'raw':!![]}),_0x4f936b['push']({'model':db['CmContact'],'as':_0x25b6d2('0x7b'),'attributes':['id',_0x25b6d2('0x1b'),'lastName'],'raw':!![]});_0x19acbf[_0x25b6d2('0xc9')][_0x25b6d2('0xd')]&&_0x4f936b[_0x25b6d2('0x3')]({'model':db['Attachment'],'as':'Attachment','raw':!![]});const _0x365fa1=[{'model':db[_0x25b6d2('0x18')],'as':_0x25b6d2('0x20'),'attributes':['id',_0x25b6d2('0x54'),'createdAt',_0x25b6d2('0x1f'),_0x25b6d2('0x50'),_0x25b6d2('0x1d')],'include':_0x4f936b}];return _0x365fa1[_0x25b6d2('0x3')]({'model':db[_0x25b6d2('0x45')],'as':'Account','attributes':['id',_0x25b6d2('0xb7')]}),_0x365fa1['push']({'model':db[_0x25b6d2('0xb6')],'as':_0x25b6d2('0x49'),'attributes':['id',_0x25b6d2('0x64')]}),db['OpenchannelInteraction'][_0x25b6d2('0x8f')]({'where':{'id':_0x19acbf['params']['id']},'include':_0x365fa1})['then'](handleEntityNotFound(_0x2c7832,null))[_0x25b6d2('0xbf')](function(_0x1bbfe2){const _0x1ffb03=_0x25b6d2;if(_0x1bbfe2){const _0x2185cc=_0x1bbfe2['get']({'plain':!![]});fs[_0x1ffb03('0x94')](_0x9c2fc8);const _0x168322={'format':'A4','border':_0x1ffb03('0x75'),'header':{'height':_0x1ffb03('0x36'),'contents':{'first':_0x1ffb03('0x41')}},'footer':{'height':_0x1ffb03('0x3f'),'contents':{'default':util[_0x1ffb03('0x3a')](_0x1ffb03('0xb2'),util[_0x1ffb03('0x3a')](_0x1ffb03('0x38'),'Openchannel',_0x2185cc['id']),moment()[_0x1ffb03('0x3a')](_0x1ffb03('0x66'))[_0x1ffb03('0x14')]())}}},_0x4830d3={'channel':_0x1ffb03('0x95'),'account':_0x2185cc[_0x1ffb03('0x72')]['name'],'agent':_0x2185cc[_0x1ffb03('0x49')]?_0x2185cc[_0x1ffb03('0x49')][_0x1ffb03('0x64')]:_0x1ffb03('0x51'),'createdAt':moment(_0x2185cc[_0x1ffb03('0x68')])[_0x1ffb03('0x3a')](_0x1ffb03('0x13'))['toString'](),'closedAt':_0x2185cc[_0x1ffb03('0x7f')]?moment(_0x2185cc[_0x1ffb03('0xc7')])['format'](_0x1ffb03('0x13'))[_0x1ffb03('0x14')]():'','disposition':_0x2185cc[_0x1ffb03('0xf')],'visibility':_0x2185cc['threadId']?'Public':'Private','messages':_(_0x2185cc[_0x1ffb03('0x20')])['filter']({'secret':![]})['map'](function(_0x21430a){const _0x4a5388=_0x1ffb03;if(_0x21430a['Attachment']){const _0x3fe179=path[_0x4a5388('0x99')](_0x5b12d0,_0x21430a[_0x4a5388('0x8c')][_0x4a5388('0x55')]);fs[_0x4a5388('0x6d')](_0x3fe179)&&fs[_0x4a5388('0x33')](_0x3fe179)[_0x4a5388('0x93')](fs[_0x4a5388('0x60')](path[_0x4a5388('0x99')](_0x9c2fc8,_0x21430a[_0x4a5388('0x8c')][_0x4a5388('0x55')])));}return{'date':moment(_0x21430a[_0x4a5388('0x68')])[_0x4a5388('0x3a')](_0x4a5388('0x13'))[_0x4a5388('0x14')](),'sender':_0x21430a['direction']===_0x4a5388('0x0')?_0x21430a['User']?_0x21430a[_0x4a5388('0xb6')][_0x4a5388('0x64')]:_0x4a5388('0xb0'):_0x21430a[_0x4a5388('0x7b')][_0x4a5388('0x1b')]+(_0x21430a[_0x4a5388('0x7b')]['lastName']?'\x20'+_0x21430a[_0x4a5388('0x7b')]['lastName']:''),'body':_0x21430a[_0x4a5388('0x8c')]?_0x21430a['Attachment'][_0x4a5388('0x55')]:_0x21430a['body'],'direction':_0x21430a['direction']===_0x4a5388('0x0')?'A':'C','secret':_0x21430a[_0x4a5388('0x50')],'read':_0x21430a[_0x4a5388('0x1d')],'attachment':_0x21430a['Attachment']};})[_0x1ffb03('0x6c')]()};return ejs['renderFile'](path['join'](config['root'],'server','views',_0x1ffb03('0x4b')),{'interaction':_0x4830d3})['then'](function(_0x5ce13e){return new Promise(function(_0x3f915b,_0x98cb7e){const _0x54eac5=a480_0x4c8f;pdf['create'](_0x5ce13e,_0x168322)[_0x54eac5('0x2b')](path[_0x54eac5('0x99')](_0x9c2fc8,_0x54eac5('0xd4')+_0x2185cc['id']+'-'+_0x3dd1d8+_0x54eac5('0xa2')),function(_0x20b560,_0x2e94a7){if(_0x20b560)return _0x98cb7e(_0x20b560);_0x3f915b(_0x2e94a7);});});})[_0x1ffb03('0xbf')](function(){const _0x53856a=_0x1ffb03;return new Promise(function(_0x43c1d7,_0x263798){zipdir(_0x9c2fc8,{'saveTo':_0x106cca},function(_0x58cfc9,_0x179711){if(_0x58cfc9)return _0x263798(_0x58cfc9);return _0x43c1d7(_0x179711);});})[_0x53856a('0xbf')](function(){return new Promise(function(_0x55aebd,_0x33523a){rimraf(_0x9c2fc8,function(_0x317f53){if(_0x317f53)_0x33523a(_0x317f53);return _0x55aebd();});});})[_0x53856a('0xbf')](function(){const _0x3ce03c=_0x53856a;return _0x2c7832[_0x3ce03c('0x3c')](_0x106cca,_0x402810,function(_0xbd459b){const _0x9d889=_0x3ce03c;_0xbd459b?console['log'](_0x9d889('0x90'),_0xbd459b):fs['unlinkSync'](_0x106cca);});});});}else return _0x2c7832[_0x1ffb03('0xa3')](0xc8);})[_0x25b6d2('0xad')](handleError(_0x2c7832,null));}; \ No newline at end of file diff --git a/server/api/openchannelInteraction/openchannelInteraction.events.js b/server/api/openchannelInteraction/openchannelInteraction.events.js index 7aa58bf..2324221 100644 --- a/server/api/openchannelInteraction/openchannelInteraction.events.js +++ b/server/api/openchannelInteraction/openchannelInteraction.events.js @@ -1 +1 @@ -const a481_0x3477=['findAll','setMaxListeners','then','OpenchannelInteraction','Users','emit','save','setDataValue','unreadMessages','getUsers','remove','../../mysqldb','addHook','exports','length'];(function(_0xd85760,_0x3477ec){const _0x574e10=function(_0x17bcbf){while(--_0x17bcbf){_0xd85760['push'](_0xd85760['shift']());}};_0x574e10(++_0x3477ec);}(a481_0x3477,0x75));const a481_0x574e=function(_0xd85760,_0x3477ec){_0xd85760=_0xd85760-0x0;let _0x574e10=a481_0x3477[_0xd85760];return _0x574e10;};const _0x299848=a481_0x574e;'use strict';const EventEmitter=require('events'),OpenchannelInteraction=require(_0x299848('0xe'))['db'][_0x299848('0x6')],OpenchannelMessage=require(_0x299848('0xe'))['db']['OpenchannelMessage'],OpenchannelInteractionEvents=new EventEmitter();OpenchannelInteractionEvents[_0x299848('0x4')](0x0);const events={'afterCreate':_0x299848('0x9'),'afterUpdate':'update','afterDestroy':_0x299848('0xd')};function emitEvent(_0x17bcbf){return function(_0x44a3cb){const _0x39020d=a481_0x574e;_0x44a3cb[_0x39020d('0xc')]({'attributes':['id'],'raw':!![]})['then'](function(_0x5390af){const _0x371be9=_0x39020d;return _0x44a3cb['setDataValue'](_0x371be9('0x7'),_0x5390af['map'](function(_0x3fdd1f){return{'id':_0x3fdd1f['id']};})),OpenchannelMessage[_0x371be9('0x3')]({'where':{'OpenchannelInteractionId':_0x44a3cb['id'],'direction':'in','read':![]},'raw':!![]});})[_0x39020d('0x5')](function(_0x3e0ab0){const _0x190e2d=_0x39020d;_0x44a3cb[_0x190e2d('0xa')](_0x190e2d('0xb'),_0x3e0ab0[_0x190e2d('0x2')]),OpenchannelInteractionEvents[_0x190e2d('0x8')](_0x17bcbf+':'+_0x44a3cb['id'],_0x44a3cb),OpenchannelInteractionEvents[_0x190e2d('0x8')](_0x17bcbf,_0x44a3cb);})['catch'](()=>{});};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];OpenchannelInteraction[_0x299848('0x0')](e,emitEvent(event));}}module[_0x299848('0x1')]=OpenchannelInteractionEvents; \ No newline at end of file +const a481_0x39fd=['findAll','getUsers','addHook','OpenchannelInteraction','unreadMessages','../../mysqldb','exports','length','undefined','remove','OpenchannelMessage','then','setDataValue','emit'];(function(_0xea8dd7,_0x39fd98){const _0x205c60=function(_0x4b0180){while(--_0x4b0180){_0xea8dd7['push'](_0xea8dd7['shift']());}};_0x205c60(++_0x39fd98);}(a481_0x39fd,0x96));const a481_0x205c=function(_0xea8dd7,_0x39fd98){_0xea8dd7=_0xea8dd7-0x0;let _0x205c60=a481_0x39fd[_0xea8dd7];return _0x205c60;};const _0x1c6d94=a481_0x205c;'use strict';const EventEmitter=require('events'),OpenchannelInteraction=require('../../mysqldb')['db'][_0x1c6d94('0x7')],OpenchannelMessage=require(_0x1c6d94('0x9'))['db'][_0x1c6d94('0x0')],OpenchannelInteractionEvents=new EventEmitter();OpenchannelInteractionEvents['setMaxListeners'](0x0);const events={'afterCreate':'save','afterUpdate':'update','afterDestroy':_0x1c6d94('0xd')};function emitEvent(_0x4b0180){return function(_0x160905){const _0x279def=a481_0x205c;_0x160905[_0x279def('0x5')]({'attributes':['id'],'raw':!![]})[_0x279def('0x1')](function(_0x2f500c){const _0x24f332=_0x279def;return _0x160905['setDataValue']('Users',_0x2f500c['map'](function(_0x19410a){return{'id':_0x19410a['id']};})),OpenchannelMessage[_0x24f332('0x4')]({'where':{'OpenchannelInteractionId':_0x160905['id'],'direction':'in','read':![]},'raw':!![]});})[_0x279def('0x1')](function(_0x5a39c2){const _0x4d7512=_0x279def;_0x160905[_0x4d7512('0x2')](_0x4d7512('0x8'),_0x5a39c2[_0x4d7512('0xb')]),OpenchannelInteractionEvents['emit'](_0x4b0180+':'+_0x160905['id'],_0x160905),OpenchannelInteractionEvents[_0x4d7512('0x3')](_0x4b0180,_0x160905);})['catch'](()=>{});};}for(const e in events){if(typeof events[e]!==_0x1c6d94('0xc')){const event=events[e];OpenchannelInteraction[_0x1c6d94('0x6')](e,emitEvent(event));}}module[_0x1c6d94('0xa')]=OpenchannelInteractionEvents; \ No newline at end of file diff --git a/server/api/openchannelInteraction/openchannelInteraction.model.js b/server/api/openchannelInteraction/openchannelInteraction.model.js index 5b0cc07..de36669 100644 --- a/server/api/openchannelInteraction/openchannelInteraction.model.js +++ b/server/api/openchannelInteraction/openchannelInteraction.model.js @@ -1 +1 @@ -const a482_0x3ec2=['closedAt','moment','YYYY-MM-DD\x20HH:mm:ss','define','OpenchannelInteraction','format','exports'];(function(_0x42fdcd,_0x3ec2bc){const _0x3180d0=function(_0x3b999b){while(--_0x3b999b){_0x42fdcd['push'](_0x42fdcd['shift']());}};_0x3180d0(++_0x3ec2bc);}(a482_0x3ec2,0x176));const a482_0x3180=function(_0x42fdcd,_0x3ec2bc){_0x42fdcd=_0x42fdcd-0x0;let _0x3180d0=a482_0x3ec2[_0x42fdcd];return _0x3180d0;};const _0x2810d6=a482_0x3180;'use strict';const moment=require(_0x2810d6('0x5')),attributes=require('./openchannelInteraction.attributes');module[_0x2810d6('0x3')]=function(_0x3b999b){const _0x39618a=_0x2810d6,_0x3dc495=_0x3b999b[_0x39618a('0x0')](_0x39618a('0x1'),attributes,{'tableName':'openchannel_interactions','paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x1a44fe){const _0x2c2f62=_0x39618a;_0x1a44fe['changed']('closed')&&(_0x1a44fe[_0x2c2f62('0x4')]=moment()[_0x2c2f62('0x2')](_0x2c2f62('0x6')));}}});return _0x3dc495;}; \ No newline at end of file +const a482_0x4e90=['openchannel_interactions','exports','define','./openchannelInteraction.attributes','moment','closedAt'];(function(_0x22cac1,_0x4e90c0){const _0x2a7a55=function(_0x16fa88){while(--_0x16fa88){_0x22cac1['push'](_0x22cac1['shift']());}};_0x2a7a55(++_0x4e90c0);}(a482_0x4e90,0x1be));const a482_0x2a7a=function(_0x22cac1,_0x4e90c0){_0x22cac1=_0x22cac1-0x0;let _0x2a7a55=a482_0x4e90[_0x22cac1];return _0x2a7a55;};const _0x822121=a482_0x2a7a;'use strict';const moment=require(_0x822121('0x2')),attributes=require(_0x822121('0x1'));module[_0x822121('0x5')]=function(_0x16fa88){const _0x1527e1=_0x822121,_0x16935b=_0x16fa88[_0x1527e1('0x0')]('OpenchannelInteraction',attributes,{'tableName':_0x1527e1('0x4'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x5f50ec){const _0x2fef0d=_0x1527e1;_0x5f50ec['changed']('closed')&&(_0x5f50ec[_0x2fef0d('0x3')]=moment()['format']('YYYY-MM-DD\x20HH:mm:ss'));}}});return _0x16935b;}; \ No newline at end of file diff --git a/server/api/openchannelInteraction/openchannelInteraction.rpc.js b/server/api/openchannelInteraction/openchannelInteraction.rpc.js index 6eb0ca2..357e798 100644 --- a/server/api/openchannelInteraction/openchannelInteraction.rpc.js +++ b/server/api/openchannelInteraction/openchannelInteraction.rpc.js @@ -1 +1 @@ -const a483_0x1343=['options','stringify','where','info','findOne','register','update','then','body','attributes','AddTagsToOpenchannelInteraction','catch','../../config/logger','./openchannelInteraction.socket','UpdateOpenchannelInteraction','lodash','omit','rpc','OpenchannelInteraction','addTags','../../mysqldb','error','AddTags','message','ids'];(function(_0x457c60,_0x1343c7){const _0x443c5b=function(_0x1a0e15){while(--_0x1a0e15){_0x457c60['push'](_0x457c60['shift']());}};_0x443c5b(++_0x1343c7);}(a483_0x1343,0x6c));const a483_0x443c=function(_0x457c60,_0x1343c7){_0x457c60=_0x457c60-0x0;let _0x443c5b=a483_0x1343[_0x457c60];return _0x443c5b;};const _0x3bbfb4=a483_0x443c;'use strict';const _=require(_0x3bbfb4('0x7')),db=require(_0x3bbfb4('0xc'))['db'],logger=require(_0x3bbfb4('0x4'))(_0x3bbfb4('0x9')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x3bbfb4('0x5'))[_0x3bbfb4('0x16')](socket),exports[_0x3bbfb4('0x6')]=function(_0x1a0e15){const _0x4cf677=this;return new Promise(function(_0x96eec6,_0x5a4a2b){const _0x401555=a483_0x443c;return db[_0x401555('0xa')][_0x401555('0x17')](_0x1a0e15['body'],{'raw':_0x1a0e15['options']?_0x1a0e15[_0x401555('0x11')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x1a0e15['options']?_0x1a0e15[_0x401555('0x11')]['where']||null:null,'attributes':_0x1a0e15[_0x401555('0x11')]?_0x1a0e15[_0x401555('0x11')][_0x401555('0x1')]||null:null,'limit':_0x1a0e15[_0x401555('0x11')]?_0x1a0e15['options']['limit']||null:null})['then'](function(_0x2adfb4){const _0x106d76=_0x401555;logger[_0x106d76('0x14')]('UpdateOpenchannelInteraction',_0x1a0e15),logger['debug'](_0x106d76('0x6'),_0x1a0e15,JSON[_0x106d76('0x12')](_0x2adfb4)),_0x96eec6(_0x2adfb4);})[_0x401555('0x3')](function(_0x3038df){const _0x8b92dd=_0x401555;logger[_0x8b92dd('0xd')](_0x8b92dd('0x6'),_0x3038df['message'],_0x1a0e15),_0x5a4a2b(_0x4cf677['error'](0x1f4,_0x3038df[_0x8b92dd('0xf')]));});});},exports[_0x3bbfb4('0x2')]=function(_0x59abde){const _0x24d9ea=this;return new Promise(function(_0x39df4f,_0x2f2654){const _0x4bbb98=a483_0x443c;return db[_0x4bbb98('0xa')][_0x4bbb98('0x15')]({'where':_0x59abde[_0x4bbb98('0x11')]?_0x59abde['options'][_0x4bbb98('0x13')]||null:null})[_0x4bbb98('0x18')](function(_0x14486b){const _0x1d6124=_0x4bbb98;if(_0x14486b)return _0x14486b[_0x1d6124('0xb')](_0x59abde['body'][_0x1d6124('0x10')],{'through':_[_0x1d6124('0x8')](_0x59abde[_0x1d6124('0x0')],[_0x1d6124('0x10'),'id'])});})[_0x4bbb98('0x18')](function([_0x2a67a4]){const _0x55d5d4=_0x4bbb98;logger[_0x55d5d4('0x14')](_0x55d5d4('0xe'),_0x59abde),logger['debug'](_0x55d5d4('0xe'),_0x59abde,JSON[_0x55d5d4('0x12')](_0x2a67a4)),_0x39df4f(_0x2a67a4);})[_0x4bbb98('0x3')](function(_0x4af4c5){const _0x3cc975=_0x4bbb98;logger[_0x3cc975('0xd')](_0x3cc975('0xe'),_0x4af4c5[_0x3cc975('0xf')],_0x59abde),_0x2f2654(_0x24d9ea[_0x3cc975('0xd')](0x1f4,_0x4af4c5['message']));});});}; \ No newline at end of file +const a483_0x1b2b=['../../mysqldb','raw','omit','../../config/logger','AddTagsToOpenchannelInteraction','rpc','message','info','UpdateOpenchannelInteraction','then','AddTags','debug','error','OpenchannelInteraction','update','ids','options','addTags','where','./openchannelInteraction.socket','catch','stringify','body','../../rediscache'];(function(_0x2fd4cb,_0x1b2bd7){const _0x3e02c5=function(_0x4f0988){while(--_0x4f0988){_0x2fd4cb['push'](_0x2fd4cb['shift']());}};_0x3e02c5(++_0x1b2bd7);}(a483_0x1b2b,0x1b8));const a483_0x3e02=function(_0x2fd4cb,_0x1b2bd7){_0x2fd4cb=_0x2fd4cb-0x0;let _0x3e02c5=a483_0x1b2b[_0x2fd4cb];return _0x3e02c5;};const _0x46a673=a483_0x3e02;'use strict';const _=require('lodash'),db=require(_0x46a673('0x10'))['db'],logger=require(_0x46a673('0x13'))(_0x46a673('0x15')),{getSocket}=require(_0x46a673('0xf')),socket=getSocket();require(_0x46a673('0xb'))['register'](socket),exports[_0x46a673('0x0')]=function(_0x4f0988){const _0x21a545=this;return new Promise(function(_0x1ed075,_0x20d02c){const _0x148603=a483_0x3e02;return db[_0x148603('0x5')][_0x148603('0x6')](_0x4f0988[_0x148603('0xe')],{'raw':_0x4f0988[_0x148603('0x8')]?_0x4f0988[_0x148603('0x8')][_0x148603('0x11')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x4f0988[_0x148603('0x8')]?_0x4f0988[_0x148603('0x8')][_0x148603('0xa')]||null:null,'attributes':_0x4f0988[_0x148603('0x8')]?_0x4f0988[_0x148603('0x8')]['attributes']||null:null,'limit':_0x4f0988[_0x148603('0x8')]?_0x4f0988[_0x148603('0x8')]['limit']||null:null})[_0x148603('0x1')](function(_0xe8cf47){const _0x41eb4e=_0x148603;logger[_0x41eb4e('0x17')](_0x41eb4e('0x0'),_0x4f0988),logger[_0x41eb4e('0x3')](_0x41eb4e('0x0'),_0x4f0988,JSON[_0x41eb4e('0xd')](_0xe8cf47)),_0x1ed075(_0xe8cf47);})[_0x148603('0xc')](function(_0x3a7a38){const _0x3d2e30=_0x148603;logger[_0x3d2e30('0x4')](_0x3d2e30('0x0'),_0x3a7a38[_0x3d2e30('0x16')],_0x4f0988),_0x20d02c(_0x21a545[_0x3d2e30('0x4')](0x1f4,_0x3a7a38[_0x3d2e30('0x16')]));});});},exports[_0x46a673('0x14')]=function(_0x3dd0c7){const _0x2e2218=this;return new Promise(function(_0x563017,_0x57c256){const _0x1dcf5e=a483_0x3e02;return db[_0x1dcf5e('0x5')]['findOne']({'where':_0x3dd0c7[_0x1dcf5e('0x8')]?_0x3dd0c7[_0x1dcf5e('0x8')][_0x1dcf5e('0xa')]||null:null})[_0x1dcf5e('0x1')](function(_0x4d5963){const _0x337b02=_0x1dcf5e;if(_0x4d5963)return _0x4d5963[_0x337b02('0x9')](_0x3dd0c7[_0x337b02('0xe')]['ids'],{'through':_[_0x337b02('0x12')](_0x3dd0c7[_0x337b02('0xe')],[_0x337b02('0x7'),'id'])});})[_0x1dcf5e('0x1')](function([_0x443f76]){const _0x5cb13b=_0x1dcf5e;logger[_0x5cb13b('0x17')](_0x5cb13b('0x2'),_0x3dd0c7),logger['debug'](_0x5cb13b('0x2'),_0x3dd0c7,JSON[_0x5cb13b('0xd')](_0x443f76)),_0x563017(_0x443f76);})[_0x1dcf5e('0xc')](function(_0x359d47){const _0x2492fe=_0x1dcf5e;logger[_0x2492fe('0x4')](_0x2492fe('0x2'),_0x359d47[_0x2492fe('0x16')],_0x3dd0c7),_0x57c256(_0x2e2218[_0x2492fe('0x4')](0x1f4,_0x359d47[_0x2492fe('0x16')]));});});}; \ No newline at end of file diff --git a/server/api/openchannelInteraction/openchannelInteraction.socket.js b/server/api/openchannelInteraction/openchannelInteraction.socket.js index fa5ea34..e7ae00d 100644 --- a/server/api/openchannelInteraction/openchannelInteraction.socket.js +++ b/server/api/openchannelInteraction/openchannelInteraction.socket.js @@ -1 +1 @@ -const a484_0x52aa=['save','emit','./openchannelInteraction.events','register','update','remove','openchannelInteraction:'];(function(_0x762599,_0x52aa52){const _0x452b68=function(_0x54e0ac){while(--_0x54e0ac){_0x762599['push'](_0x762599['shift']());}};_0x452b68(++_0x52aa52);}(a484_0x52aa,0x118));const a484_0x452b=function(_0x762599,_0x52aa52){_0x762599=_0x762599-0x0;let _0x452b68=a484_0x52aa[_0x762599];return _0x452b68;};const _0x3f006c=a484_0x452b;'use strict';const OpenchannelInteractionEvents=require(_0x3f006c('0x2')),events=[_0x3f006c('0x0'),_0x3f006c('0x5'),_0x3f006c('0x4')];function createListener(_0x54e0ac,_0x3055ef){return function(_0x124998){const _0x39e46b=a484_0x452b;_0x3055ef[_0x39e46b('0x1')](_0x54e0ac,_0x124998);};}exports[_0x3f006c('0x3')]=function(_0x407acd){const _0x4c49d6=_0x3f006c;for(let _0x47253e=0x0,_0x24f03c=events['length'];_0x47253e<_0x24f03c;_0x47253e++){const _0x13f17d=events[_0x47253e],_0x5737f7=createListener(_0x4c49d6('0x6')+_0x13f17d,_0x407acd);OpenchannelInteractionEvents['on'](_0x13f17d,_0x5737f7);}}; \ No newline at end of file +const a484_0x2d8f=['remove','./openchannelInteraction.events','update','save','register','emit','length'];(function(_0x4a0a26,_0x2d8f5f){const _0x1d40f6=function(_0x5df08f){while(--_0x5df08f){_0x4a0a26['push'](_0x4a0a26['shift']());}};_0x1d40f6(++_0x2d8f5f);}(a484_0x2d8f,0x11c));const a484_0x1d40=function(_0x4a0a26,_0x2d8f5f){_0x4a0a26=_0x4a0a26-0x0;let _0x1d40f6=a484_0x2d8f[_0x4a0a26];return _0x1d40f6;};const _0x164db2=a484_0x1d40;'use strict';const OpenchannelInteractionEvents=require(_0x164db2('0x4')),events=[_0x164db2('0x6'),_0x164db2('0x3'),_0x164db2('0x5')];function createListener(_0x5df08f,_0x5bd881){return function(_0x50dfa5){const _0x492bf1=a484_0x1d40;_0x5bd881[_0x492bf1('0x1')](_0x5df08f,_0x50dfa5);};}exports[_0x164db2('0x0')]=function(_0xcdd8fe){const _0x583677=_0x164db2;for(let _0x20ff56=0x0,_0x2af3ad=events[_0x583677('0x2')];_0x20ff56<_0x2af3ad;_0x20ff56++){const _0x4c5b14=events[_0x20ff56],_0x1a863e=createListener('openchannelInteraction:'+_0x4c5b14,_0xcdd8fe);OpenchannelInteractionEvents['on'](_0x4c5b14,_0x1a863e);}}; \ No newline at end of file diff --git a/server/api/openchannelMessage/index.js b/server/api/openchannelMessage/index.js index 7f349ea..73a66b2 100644 --- a/server/api/openchannelMessage/index.js +++ b/server/api/openchannelMessage/index.js @@ -1 +1 @@ -const a485_0x1a7e=['destroy','delete','isAuthenticated','./openchannelMessage.controller','/:id','../../components/interaction/service','create','show','exports','update','index','put','describe','reject','get','/:id/accept','/describe','openchannel','openchannelmessage:create','accept'];(function(_0x13e934,_0x1a7e44){const _0x313662=function(_0x5dde11){while(--_0x5dde11){_0x13e934['push'](_0x13e934['shift']());}};_0x313662(++_0x1a7e44);}(a485_0x1a7e,0x1af));const a485_0x3136=function(_0x13e934,_0x1a7e44){_0x13e934=_0x13e934-0x0;let _0x313662=a485_0x1a7e[_0x13e934];return _0x313662;};const _0x179469=a485_0x3136;'use strict';const express=require('express'),router=express['Router'](),auth=require('../../components/auth/service'),interaction=require(_0x179469('0xe')),controller=require(_0x179469('0xc'));router[_0x179469('0x3')]('/',auth[_0x179469('0xb')](),controller[_0x179469('0x13')]),router['get'](_0x179469('0x5'),auth['isAuthenticated'](),controller[_0x179469('0x1')]),router[_0x179469('0x3')](_0x179469('0xd'),auth['isAuthenticated'](),controller[_0x179469('0x10')]),router['post']('/',auth[_0x179469('0xb')](),interaction['tracked'](_0x179469('0x6'),_0x179469('0x7')),controller[_0x179469('0xf')]),router[_0x179469('0x0')](_0x179469('0xd'),auth[_0x179469('0xb')](),controller[_0x179469('0x12')]),router['put'](_0x179469('0x4'),auth[_0x179469('0xb')](),controller[_0x179469('0x8')]),router[_0x179469('0x0')]('/:id/reject',auth[_0x179469('0xb')](),controller[_0x179469('0x2')]),router[_0x179469('0xa')](_0x179469('0xd'),auth[_0x179469('0xb')](),controller[_0x179469('0x9')]),module[_0x179469('0x11')]=router; \ No newline at end of file +const a485_0x2241=['delete','exports','create','express','accept','/:id','index','tracked','/:id/accept','../../components/auth/service','put','openchannelmessage:create','post','/:id/reject','isAuthenticated','destroy','update','reject','get','Router'];(function(_0x17fbea,_0x2241f8){const _0x5d8fee=function(_0x20d7a8){while(--_0x20d7a8){_0x17fbea['push'](_0x17fbea['shift']());}};_0x5d8fee(++_0x2241f8);}(a485_0x2241,0x65));const a485_0x5d8f=function(_0x17fbea,_0x2241f8){_0x17fbea=_0x17fbea-0x0;let _0x5d8fee=a485_0x2241[_0x17fbea];return _0x5d8fee;};const _0x5f064f=a485_0x5d8f;'use strict';const express=require(_0x5f064f('0x2')),router=express[_0x5f064f('0x12')](),auth=require(_0x5f064f('0x8')),interaction=require('../../components/interaction/service'),controller=require('./openchannelMessage.controller');router[_0x5f064f('0x11')]('/',auth[_0x5f064f('0xd')](),controller[_0x5f064f('0x5')]),router[_0x5f064f('0x11')]('/describe',auth[_0x5f064f('0xd')](),controller['describe']),router[_0x5f064f('0x11')](_0x5f064f('0x4'),auth[_0x5f064f('0xd')](),controller['show']),router[_0x5f064f('0xb')]('/',auth[_0x5f064f('0xd')](),interaction[_0x5f064f('0x6')]('openchannel',_0x5f064f('0xa')),controller[_0x5f064f('0x1')]),router[_0x5f064f('0x9')](_0x5f064f('0x4'),auth[_0x5f064f('0xd')](),controller[_0x5f064f('0xf')]),router[_0x5f064f('0x9')](_0x5f064f('0x7'),auth[_0x5f064f('0xd')](),controller[_0x5f064f('0x3')]),router['put'](_0x5f064f('0xc'),auth[_0x5f064f('0xd')](),controller[_0x5f064f('0x10')]),router[_0x5f064f('0x13')](_0x5f064f('0x4'),auth[_0x5f064f('0xd')](),controller[_0x5f064f('0xe')]),module[_0x5f064f('0x0')]=router; \ No newline at end of file diff --git a/server/api/openchannelMessage/openchannelMessage.attributes.js b/server/api/openchannelMessage/openchannelMessage.attributes.js index 1d3bf51..fdc5c5e 100644 --- a/server/api/openchannelMessage/openchannelMessage.attributes.js +++ b/server/api/openchannelMessage/openchannelMessage.attributes.js @@ -1 +1 @@ -const a486_0x47f6=['out','ENUM','TEXT','medium','STRING','exports','sequelize','DATE','BOOLEAN'];(function(_0x19d563,_0x47f6aa){const _0x9e45e=function(_0x29eaec){while(--_0x29eaec){_0x19d563['push'](_0x19d563['shift']());}};_0x9e45e(++_0x47f6aa);}(a486_0x47f6,0x81));const a486_0x9e45=function(_0x19d563,_0x47f6aa){_0x19d563=_0x19d563-0x0;let _0x9e45e=a486_0x47f6[_0x19d563];return _0x9e45e;};const _0x1f8ade=a486_0x9e45;'use strict';const Sequelize=require(_0x1f8ade('0x3'));module[_0x1f8ade('0x2')]={'body':{'type':Sequelize[_0x1f8ade('0x8')](_0x1f8ade('0x0')),'allowNull':![]},'read':{'type':Sequelize[_0x1f8ade('0x5')],'defaultValue':![]},'secret':{'type':Sequelize[_0x1f8ade('0x5')],'defaultValue':![]},'direction':{'type':Sequelize[_0x1f8ade('0x7')]('in',_0x1f8ade('0x6')),'defaultValue':'out','allowNull':![]},'readAt':{'type':Sequelize[_0x1f8ade('0x4')]},'providerName':{'type':Sequelize[_0x1f8ade('0x1')]},'providerResponse':{'type':Sequelize['TEXT']}}; \ No newline at end of file +const a486_0x2d1c=['STRING','out','medium','BOOLEAN','exports','TEXT'];(function(_0x42ebcb,_0x2d1cef){const _0x152b4c=function(_0x480813){while(--_0x480813){_0x42ebcb['push'](_0x42ebcb['shift']());}};_0x152b4c(++_0x2d1cef);}(a486_0x2d1c,0x163));const a486_0x152b=function(_0x42ebcb,_0x2d1cef){_0x42ebcb=_0x42ebcb-0x0;let _0x152b4c=a486_0x2d1c[_0x42ebcb];return _0x152b4c;};const _0x3edffb=a486_0x152b;'use strict';const Sequelize=require('sequelize');module[_0x3edffb('0x3')]={'body':{'type':Sequelize[_0x3edffb('0x4')](_0x3edffb('0x1')),'allowNull':![]},'read':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'secret':{'type':Sequelize[_0x3edffb('0x2')],'defaultValue':![]},'direction':{'type':Sequelize['ENUM']('in',_0x3edffb('0x0')),'defaultValue':_0x3edffb('0x0'),'allowNull':![]},'readAt':{'type':Sequelize['DATE']},'providerName':{'type':Sequelize[_0x3edffb('0x5')]},'providerResponse':{'type':Sequelize[_0x3edffb('0x4')]}}; \ No newline at end of file diff --git a/server/api/openchannelMessage/openchannelMessage.controller.js b/server/api/openchannelMessage/openchannelMessage.controller.js index 46eae3b..e23b0e8 100644 --- a/server/api/openchannelMessage/openchannelMessage.controller.js +++ b/server/api/openchannelMessage/openchannelMessage.controller.js @@ -1 +1 @@ -const a487_0x2c87=['key','interaction','role','then','client','rejectMessage','fields','openchannel-interactions','includeAll','manual','[OPENCHANNELMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','OpenchannelMessage,\x20%s,\x20%s','show','map','util','destroy','type','params','merge','acceptmessage','jayson/promise','VIRTUAL','result','catch','describe','../../config/logger','length','error','null','options','keys','lodash','agent','isNil','index','Contact','./openchannelMessage.socket','rejectmessage','request','like','message','findAll','OpenchannelInteractionId','undefined','set','../../rediscache','status','../../components/parsers/qs','EventManager','filters','event','stringify','end','format','interface','SIP/%s','../../mysqldb','json','include','read1stAt','readAt','get','pick','channel','accept','rows','order','user','register','OpenchannelMessage','limit','body','offset','create','findOne','read','count','reject','CmContact','where','update','info','attributes','request\x20sent','query','Content-Range','sequelize','intersection','fieldName','filter','rawAttributes','name','http','UserId','[OPENCHANNELMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','OpenchannelInteraction','nolimit','send','OpenchannelMessage,\x20%s,\x20%s,\x20%s','model','api','sort','openchannel'];(function(_0x21e480,_0x2c8738){const _0x332199=function(_0x45f9b9){while(--_0x45f9b9){_0x21e480['push'](_0x21e480['shift']());}};_0x332199(++_0x2c8738);}(a487_0x2c87,0x13a));const a487_0x3321=function(_0x21e480,_0x2c8738){_0x21e480=_0x21e480-0x0;let _0x332199=a487_0x2c87[_0x21e480];return _0x332199;};const _0x52805c=a487_0x3321;'use strict';const moment=require('moment'),util=require(_0x52805c('0x9')),_=require(_0x52805c('0x1a')),qs=require(_0x52805c('0x2a')),logger=require(_0x52805c('0x14'))(_0x52805c('0x5f')),{getSocket}=require(_0x52805c('0x28')),socket=getSocket(),interaction_log=require(_0x52805c('0x14'))(_0x52805c('0x2')),db=require(_0x52805c('0x33'))['db'],{Op}=require(_0x52805c('0x51'));require(_0x52805c('0x1f'))[_0x52805c('0x3f')](socket);const jayson=require(_0x52805c('0xf')),client=jayson[_0x52805c('0x66')][_0x52805c('0x57')]({'port':0x232c}),client9002=jayson[_0x52805c('0x66')][_0x52805c('0x57')]({'port':0x232a});function respondWithRpcPromise(_0x45f9b9,_0x1b1582,_0x3536fc,_0x32128b){return new Promise(function(_0x19bab5,_0x5bd92c){const _0x1f8b60=a487_0x3321,_0x518350=_0x32128b||client;return _0x518350[_0x1f8b60('0x21')](_0x45f9b9,_0x3536fc)[_0x1f8b60('0x65')](function(_0x339e87){const _0x34386d=_0x1f8b60;logger['info']('OpenchannelMessage,\x20%s,\x20%s',_0x1b1582,_0x34386d('0x4e')),logger['debug'](_0x34386d('0x5d'),_0x1b1582,_0x34386d('0x4e'),JSON[_0x34386d('0x2e')](_0x339e87));if(_0x339e87[_0x34386d('0x16')]){if(_0x339e87[_0x34386d('0x16')]['code']===0x1f4)return logger['error'](_0x34386d('0x6'),_0x1b1582,_0x339e87['error']['message']),_0x5bd92c(_0x339e87[_0x34386d('0x16')][_0x34386d('0x23')]);return logger[_0x34386d('0x16')](_0x34386d('0x6'),_0x1b1582,_0x339e87[_0x34386d('0x16')][_0x34386d('0x23')]),_0x19bab5(_0x339e87[_0x34386d('0x16')][_0x34386d('0x23')]);}else logger[_0x34386d('0x4c')]('OpenchannelMessage,\x20%s,\x20%s',_0x1b1582,_0x34386d('0x4e')),_0x19bab5(_0x339e87[_0x34386d('0x11')][_0x34386d('0x23')]);})[_0x1f8b60('0x12')](function(_0x1c03c9){const _0x1d2e1d=_0x1f8b60;logger[_0x1d2e1d('0x16')](_0x1d2e1d('0x6'),_0x1b1582,_0x1c03c9),_0x5bd92c(_0x1c03c9);});});}function respondWithResult(_0x5d4221,_0x455af2){return _0x455af2=_0x455af2||0xc8,function(_0x31f9d7){const _0x2fb733=a487_0x3321;if(_0x31f9d7)return _0x5d4221[_0x2fb733('0x29')](_0x455af2)['json'](_0x31f9d7);};}function respondWithFilteredResult(_0x1a65e2,_0x2f9ed3){return function(_0x32ff9c){const _0x3170c2=a487_0x3321;if(_0x32ff9c){const _0x56d89a=_0x32ff9c[_0x3170c2('0x47')],_0x3b9610=_0x2f9ed3[_0x3170c2('0x43')];let _0x33d74b=_0x2f9ed3[_0x3170c2('0x43')]+_0x2f9ed3[_0x3170c2('0x41')],_0x334445;return _0x33d74b>=_0x56d89a?(_0x33d74b=_0x56d89a,_0x334445=0xc8):_0x334445=0xce,_0x1a65e2[_0x3170c2('0x29')](_0x334445),_0x1a65e2[_0x3170c2('0x27')](_0x3170c2('0x50'),_0x3b9610+'-'+_0x33d74b+'/'+_0x56d89a)[_0x3170c2('0x34')](_0x32ff9c);}return null;};}function saveUpdates(_0x3191ad){return function(_0x4be06e){const _0x2d183b=a487_0x3321;if(_0x4be06e)return _0x4be06e['update'](_0x3191ad)[_0x2d183b('0x65')](function(_0x631068){return _0x631068;});return null;};}function removeEntity(_0x39fe97){return function(_0x1530c9){const _0x534b3f=a487_0x3321;if(_0x1530c9)return _0x1530c9[_0x534b3f('0xa')]()['then'](function(){const _0x3e06a5=_0x534b3f;_0x39fe97[_0x3e06a5('0x29')](0xcc)[_0x3e06a5('0x2f')]();});};}function handleEntityNotFound(_0x3d5029){return function(_0x1bec72){return!_0x1bec72&&_0x3d5029['sendStatus'](0x194),_0x1bec72;};}function handleError(_0x479d0d,_0x489126){return _0x489126=_0x489126||0x1f4,function(_0x134ee6){const _0x31728f=a487_0x3321;logger[_0x31728f('0x16')](_0x134ee6['stack']),_0x134ee6[_0x31728f('0x56')]&&delete _0x134ee6[_0x31728f('0x56')],_0x479d0d[_0x31728f('0x29')](_0x489126)[_0x31728f('0x5c')](_0x134ee6);};}exports[_0x52805c('0x1d')]=function(_0x1c0677,_0x24e1cc){const _0x33dcdb=_0x52805c;let _0x2039c5={};const _0x5160b9={},_0xede0d6={'count':0x0,'rows':[]},_0x2d0c92=_[_0x33dcdb('0x8')](db['OpenchannelMessage'][_0x33dcdb('0x55')],function(_0x133713){const _0xcd9093=_0x33dcdb;return{'name':_0x133713[_0xcd9093('0x53')],'type':_0x133713[_0xcd9093('0xb')][_0xcd9093('0x62')]};});_0x5160b9[_0x33dcdb('0x5e')]=_[_0x33dcdb('0x8')](_0x2d0c92,_0x33dcdb('0x56')),_0x5160b9[_0x33dcdb('0x4f')]=_[_0x33dcdb('0x19')](_0x1c0677['query']),_0x5160b9['filters']=_[_0x33dcdb('0x52')](_0x5160b9[_0x33dcdb('0x5e')],_0x5160b9[_0x33dcdb('0x4f')]),_0x2039c5[_0x33dcdb('0x4d')]=_[_0x33dcdb('0x52')](_0x5160b9['model'],qs['fields'](_0x1c0677[_0x33dcdb('0x4f')][_0x33dcdb('0x1')])),_0x2039c5[_0x33dcdb('0x4d')]=_0x2039c5[_0x33dcdb('0x4d')][_0x33dcdb('0x15')]?_0x2039c5['attributes']:_0x5160b9[_0x33dcdb('0x5e')];typeof _0x1c0677[_0x33dcdb('0x4f')][_0x33dcdb('0x5b')]===_0x33dcdb('0x26')&&(_0x2039c5[_0x33dcdb('0x41')]=qs['limit'](_0x1c0677[_0x33dcdb('0x4f')][_0x33dcdb('0x41')]),_0x2039c5[_0x33dcdb('0x43')]=qs[_0x33dcdb('0x43')](_0x1c0677['query'][_0x33dcdb('0x43')]));_0x2039c5[_0x33dcdb('0x3d')]=qs[_0x33dcdb('0x60')](_0x1c0677['query'][_0x33dcdb('0x60')]),_0x2039c5[_0x33dcdb('0x4a')]=qs[_0x33dcdb('0x2c')](_[_0x33dcdb('0x39')](_0x1c0677['query'],_0x5160b9[_0x33dcdb('0x2c')]),_0x2d0c92);_0x1c0677[_0x33dcdb('0x4f')]['filter']&&(_0x2039c5[_0x33dcdb('0x4a')]=_[_0x33dcdb('0xd')](_0x2039c5[_0x33dcdb('0x4a')],{[Op['or']]:_[_0x33dcdb('0x8')](_0x2d0c92,function(_0x3290eb){const _0x1106f9=_0x33dcdb;if(_0x3290eb[_0x1106f9('0xb')]!==_0x1106f9('0x10')){const _0x3e6206={};return _0x3e6206[_0x3290eb['name']]={[Op[_0x1106f9('0x22')]]:'%'+_0x1c0677['query'][_0x1106f9('0x54')]+'%'},_0x3e6206;}})}));_0x2039c5=_[_0x33dcdb('0xd')]({},_0x2039c5,_0x1c0677[_0x33dcdb('0x18')]);const _0x32e9aa={'where':_0x2039c5['where']};return db[_0x33dcdb('0x40')][_0x33dcdb('0x47')](_0x32e9aa)[_0x33dcdb('0x65')](function(_0x2a06af){const _0x2cb076=_0x33dcdb;return _0xede0d6['count']=_0x2a06af,_0x1c0677['query'][_0x2cb076('0x3')]&&(_0x2039c5[_0x2cb076('0x35')]=[{'all':!![]}]),db[_0x2cb076('0x40')][_0x2cb076('0x24')](_0x2039c5);})[_0x33dcdb('0x65')](function(_0x2b6e79){const _0x1e07e5=_0x33dcdb;return _0xede0d6[_0x1e07e5('0x3c')]=_0x2b6e79,_0xede0d6;})[_0x33dcdb('0x65')](respondWithFilteredResult(_0x24e1cc,_0x2039c5))['catch'](handleError(_0x24e1cc,null));},exports[_0x52805c('0x7')]=function(_0x4dd2d5,_0xbef974){const _0x19625d=_0x52805c;let _0x1d1e39={'raw':!![],'where':{'id':_0x4dd2d5[_0x19625d('0xc')]['id']}};const _0x574c80={};return _0x574c80['model']=_[_0x19625d('0x19')](db[_0x19625d('0x40')][_0x19625d('0x55')]),_0x574c80[_0x19625d('0x4f')]=_[_0x19625d('0x19')](_0x4dd2d5[_0x19625d('0x4f')]),_0x574c80[_0x19625d('0x2c')]=_[_0x19625d('0x52')](_0x574c80[_0x19625d('0x5e')],_0x574c80['query']),_0x1d1e39['attributes']=_['intersection'](_0x574c80[_0x19625d('0x5e')],qs[_0x19625d('0x1')](_0x4dd2d5[_0x19625d('0x4f')]['fields'])),_0x1d1e39[_0x19625d('0x4d')]=_0x1d1e39['attributes'][_0x19625d('0x15')]?_0x1d1e39[_0x19625d('0x4d')]:_0x574c80[_0x19625d('0x5e')],_0x4dd2d5['query'][_0x19625d('0x3')]&&(_0x1d1e39[_0x19625d('0x35')]=[{'all':!![]}]),_0x1d1e39=_[_0x19625d('0xd')]({},_0x1d1e39,_0x4dd2d5['options']),db[_0x19625d('0x40')][_0x19625d('0x45')](_0x1d1e39)[_0x19625d('0x65')](handleEntityNotFound(_0xbef974,null))[_0x19625d('0x65')](respondWithResult(_0xbef974,null))[_0x19625d('0x12')](handleError(_0xbef974,null));},exports[_0x52805c('0x44')]=function(_0xb99e51,_0x123a30){const _0x3b9aab=_0x52805c;return db[_0x3b9aab('0x40')][_0x3b9aab('0x44')](_0xb99e51['body'],{})['then'](respondWithResult(_0x123a30,0xc9))[_0x3b9aab('0x12')](handleError(_0x123a30,null));},exports[_0x52805c('0x4b')]=function(_0x4c9703,_0x56ec62){const _0x404af5=_0x52805c;return _0x4c9703[_0x404af5('0x42')]['id']&&delete _0x4c9703[_0x404af5('0x42')]['id'],db[_0x404af5('0x40')][_0x404af5('0x45')]({'where':{'id':_0x4c9703['params']['id']}})[_0x404af5('0x65')](handleEntityNotFound(_0x56ec62,null))['then'](saveUpdates(_0x4c9703[_0x404af5('0x42')],null))[_0x404af5('0x65')](respondWithResult(_0x56ec62,null))[_0x404af5('0x12')](handleError(_0x56ec62,null));},exports[_0x52805c('0xa')]=function(_0xce68a5,_0x4bb9d3){const _0x31ab55=_0x52805c;return db['OpenchannelMessage']['findOne']({'where':{'id':_0xce68a5[_0x31ab55('0xc')]['id']}})['then'](handleEntityNotFound(_0x4bb9d3,null))['then'](removeEntity(_0x4bb9d3,null))['catch'](handleError(_0x4bb9d3,null));},exports[_0x52805c('0x13')]=function(_0x2fd77e,_0x4544c8){const _0x1451f7=_0x52805c;return db[_0x1451f7('0x40')][_0x1451f7('0x13')]()['then'](respondWithResult(_0x4544c8,null))['catch'](handleError(_0x4544c8,null));},exports['accept']=function(_0x1fb8de,_0xae705a){const _0x4067bf=_0x52805c,_0x17ea7b={'channel':_0x4067bf('0x61')};return _0x1fb8de[_0x4067bf('0x42')]['id']&&delete _0x1fb8de[_0x4067bf('0x42')]['id'],_0x1fb8de[_0x4067bf('0x42')][_0x4067bf('0x46')]=!![],_0x1fb8de[_0x4067bf('0x42')][_0x4067bf('0x37')]=moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),_0x1fb8de[_0x4067bf('0x42')]['UserId']=_0x1fb8de['body'][_0x4067bf('0x58')]||_0x1fb8de[_0x4067bf('0x3e')]['id'],db['OpenchannelMessage'][_0x4067bf('0x45')]({'where':{'id':_0x1fb8de[_0x4067bf('0xc')]['id'],'UserId':null},'include':[{'model':db[_0x4067bf('0x49')],'as':_0x4067bf('0x1e')}]})[_0x4067bf('0x65')](handleEntityNotFound(_0xae705a,null))[_0x4067bf('0x65')](saveUpdates(_0x1fb8de[_0x4067bf('0x42')],null))[_0x4067bf('0x65')](function(_0x235008){const _0x274bd2=_0x4067bf;if(_0x235008)return _0x17ea7b[_0x274bd2('0x23')]=_0x235008['get']({'plain':!![]}),db[_0x274bd2('0x5a')][_0x274bd2('0x45')]({'where':{'id':_0x235008[_0x274bd2('0x25')]}});return null;})[_0x4067bf('0x65')](handleEntityNotFound(_0xae705a,null))['then'](function(_0x31c1f6){const _0x10e30f=_0x4067bf;if(_0x31c1f6)return _0x31c1f6[_0x10e30f('0x4b')]({'UserId':_0x1fb8de[_0x10e30f('0x42')][_0x10e30f('0x58')],'read1stAt':_[_0x10e30f('0x1c')](_0x31c1f6[_0x10e30f('0x36')])?moment()[_0x10e30f('0x30')]('YYYY-MM-DD\x20HH:mm:ss'):undefined});return null;})[_0x4067bf('0x65')](function(_0x473295){const _0x5d2d2f=_0x4067bf;if(_0x473295)return _0x17ea7b[_0x5d2d2f('0x63')]=_0x473295[_0x5d2d2f('0x38')]({'plain':!![]}),interaction_log[_0x5d2d2f('0x4c')](_0x5d2d2f('0x5'),_0x1fb8de[_0x5d2d2f('0x3e')]['id'],_0x1fb8de[_0x5d2d2f('0x3e')][_0x5d2d2f('0x56')],_0x1fb8de[_0x5d2d2f('0x3e')][_0x5d2d2f('0x64')],_0x17ea7b[_0x5d2d2f('0x63')]['id'],_0x1fb8de[_0x5d2d2f('0x42')]?JSON[_0x5d2d2f('0x2e')](_0x1fb8de[_0x5d2d2f('0x42')]):_0x5d2d2f('0x17')),respondWithRpcPromise('AcceptMessage','acceptMessage',_0x17ea7b);return null;})[_0x4067bf('0x65')](function(_0x29c1aa){const _0x11dac6=_0x4067bf;if(_0x29c1aa){if(_0x1fb8de['body'][_0x11dac6('0x4')])return _0x17ea7b['message'][_0x11dac6('0x31')]=util['format']('SIP/%s',_0x1fb8de[_0x11dac6('0x3e')][_0x11dac6('0x56')]),_0x17ea7b[_0x11dac6('0x23')][_0x11dac6('0x3a')]=_0x17ea7b[_0x11dac6('0x3a')],_0x17ea7b['message']['event']=_0x11dac6('0x3b'),respondWithRpcPromise(_0x11dac6('0x2b'),_0x11dac6('0x2b'),{'event':_0x11dac6('0xe'),'message':_0x17ea7b[_0x11dac6('0x23')]},client9002)[_0x11dac6('0x65')](function(){return _0x17ea7b;});return _0x17ea7b;}return null;})[_0x4067bf('0x65')](respondWithResult(_0xae705a,null))[_0x4067bf('0x12')](handleError(_0xae705a,null));},exports[_0x52805c('0x48')]=function(_0x1eb070,_0x1e45c5){const _0x39e8b8=_0x52805c,_0x120739={'agent':{},'channel':'openchannel'};return _0x1eb070[_0x39e8b8('0x42')]['id']&&delete _0x1eb070[_0x39e8b8('0x42')]['id'],_0x1eb070[_0x39e8b8('0x42')][_0x39e8b8('0x58')]=_0x1eb070[_0x39e8b8('0x42')][_0x39e8b8('0x58')]||_0x1eb070[_0x39e8b8('0x3e')]['id'],_0x120739[_0x39e8b8('0x1b')]['id']=_0x1eb070['body'][_0x39e8b8('0x58')],db[_0x39e8b8('0x40')][_0x39e8b8('0x45')]({'where':{'id':_0x1eb070[_0x39e8b8('0xc')]['id'],'UserId':null}})['then'](handleEntityNotFound(_0x1e45c5,null))[_0x39e8b8('0x65')](function(_0x550f88){const _0xa547be=_0x39e8b8;if(_0x550f88)return _0x120739['message']=_0x550f88['get']({'plain':!![]}),db[_0xa547be('0x5a')][_0xa547be('0x45')]({'where':{'id':_0x550f88['OpenchannelInteractionId']}});return null;})[_0x39e8b8('0x65')](handleEntityNotFound(_0x1e45c5,null))['then'](function(_0x532188){const _0x598d1d=_0x39e8b8;if(_0x532188)return _0x120739[_0x598d1d('0x63')]=_0x532188[_0x598d1d('0x38')]({'plain':!![]}),interaction_log[_0x598d1d('0x4c')](_0x598d1d('0x59'),_0x1eb070[_0x598d1d('0x3e')]['id'],_0x1eb070['user'][_0x598d1d('0x56')],_0x1eb070[_0x598d1d('0x3e')][_0x598d1d('0x64')],_0x120739['interaction']['id'],_0x1eb070[_0x598d1d('0x42')]?JSON[_0x598d1d('0x2e')](_0x1eb070[_0x598d1d('0x42')]):_0x598d1d('0x17')),respondWithRpcPromise('RejectMessage',_0x598d1d('0x0'),_0x120739);return null;})[_0x39e8b8('0x65')](function(_0x43034e){const _0x3db479=_0x39e8b8;if(_0x43034e)return _0x43034e['message']['interface']=util['format'](_0x3db479('0x32'),_0x1eb070[_0x3db479('0x3e')][_0x3db479('0x56')]),_0x43034e[_0x3db479('0x23')][_0x3db479('0x3a')]=_0x120739[_0x3db479('0x3a')],_0x43034e[_0x3db479('0x23')][_0x3db479('0x2d')]=_0x3db479('0x48'),respondWithRpcPromise(_0x3db479('0x2b'),'EventManager',{'event':_0x3db479('0x20'),'message':_0x43034e[_0x3db479('0x23')]},client9002),_0x120739;return null;})['then'](respondWithResult(_0x1e45c5,null))[_0x39e8b8('0x12')](handleError(_0x1e45c5,null));}; \ No newline at end of file +const a487_0x26cf=['debug','end','user','fields','UserId','OpenchannelInteraction','message','options','intersection','acceptMessage','OpenchannelInteractionId','sort','offset','isNil','readAt','[OPENCHANNELMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','model','OpenchannelMessage','VIRTUAL','undefined','query','interaction','info','then','error','OpenchannelMessage,\x20%s,\x20%s','pick','sendStatus','../../config/logger','agent','update','result','request','openchannel','destroy','reject','findAll','set','format','count','map','create','jayson/promise','AcceptMessage','request\x20sent','catch','role','get','status','name','http','accept','manual','length','channel','null','read1stAt','filter','EventManager','../../mysqldb','rawAttributes','Contact','where','./openchannelMessage.socket','rejectMessage','fieldName','interface','SIP/%s','rejectmessage','limit','keys','attributes','body','nolimit','client','YYYY-MM-DD\x20HH:mm:ss','../../rediscache','stack','filters','register','moment','describe','includeAll','Content-Range','sequelize','code','stringify','params','type','show','include','index','acceptmessage','like','event','openchannel-interactions','json','findOne','[OPENCHANNELMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','RejectMessage','util','key','api'];(function(_0x1e2f36,_0x26cf27){const _0x16ac78=function(_0x26e987){while(--_0x26e987){_0x1e2f36['push'](_0x1e2f36['shift']());}};_0x16ac78(++_0x26cf27);}(a487_0x26cf,0x1da));const a487_0x16ac=function(_0x1e2f36,_0x26cf27){_0x1e2f36=_0x1e2f36-0x0;let _0x16ac78=a487_0x26cf[_0x1e2f36];return _0x16ac78;};const _0x4a8521=a487_0x16ac;'use strict';const moment=require(_0x4a8521('0x12')),util=require(_0x4a8521('0x26')),_=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x4a8521('0x45'))(_0x4a8521('0x28')),{getSocket}=require(_0x4a8521('0xe')),socket=getSocket(),interaction_log=require(_0x4a8521('0x45'))(_0x4a8521('0x21')),db=require(_0x4a8521('0x64'))['db'],{Op}=require(_0x4a8521('0x16'));require(_0x4a8521('0x1'))[_0x4a8521('0x11')](socket);const jayson=require(_0x4a8521('0x53')),client=jayson[_0x4a8521('0xc')][_0x4a8521('0x5b')]({'port':0x232c}),client9002=jayson[_0x4a8521('0xc')][_0x4a8521('0x5b')]({'port':0x232a});function respondWithRpcPromise(_0x26e987,_0x4ec5ba,_0x22349,_0x4e22f7){return new Promise(function(_0x498e26,_0x5192a7){const _0x415bc5=a487_0x16ac,_0x1e3487=_0x4e22f7||client;return _0x1e3487[_0x415bc5('0x49')](_0x26e987,_0x22349)[_0x415bc5('0x40')](function(_0x229734){const _0x5add5f=_0x415bc5;logger[_0x5add5f('0x3f')]('OpenchannelMessage,\x20%s,\x20%s',_0x4ec5ba,_0x5add5f('0x55')),logger[_0x5add5f('0x29')]('OpenchannelMessage,\x20%s,\x20%s,\x20%s',_0x4ec5ba,_0x5add5f('0x55'),JSON[_0x5add5f('0x18')](_0x229734));if(_0x229734[_0x5add5f('0x41')]){if(_0x229734['error'][_0x5add5f('0x17')]===0x1f4)return logger['error'](_0x5add5f('0x42'),_0x4ec5ba,_0x229734[_0x5add5f('0x41')]['message']),_0x5192a7(_0x229734[_0x5add5f('0x41')][_0x5add5f('0x2f')]);return logger[_0x5add5f('0x41')]('OpenchannelMessage,\x20%s,\x20%s',_0x4ec5ba,_0x229734['error'][_0x5add5f('0x2f')]),_0x498e26(_0x229734[_0x5add5f('0x41')][_0x5add5f('0x2f')]);}else logger['info']('OpenchannelMessage,\x20%s,\x20%s',_0x4ec5ba,_0x5add5f('0x55')),_0x498e26(_0x229734[_0x5add5f('0x48')]['message']);})['catch'](function(_0x41be1b){const _0x583b6d=_0x415bc5;logger[_0x583b6d('0x41')](_0x583b6d('0x42'),_0x4ec5ba,_0x41be1b),_0x5192a7(_0x41be1b);});});}function respondWithResult(_0x517eaf,_0x2b4f8f){return _0x2b4f8f=_0x2b4f8f||0xc8,function(_0x1f3a93){const _0x2bac9e=a487_0x16ac;if(_0x1f3a93)return _0x517eaf[_0x2bac9e('0x59')](_0x2b4f8f)[_0x2bac9e('0x22')](_0x1f3a93);};}function respondWithFilteredResult(_0x41e327,_0x2e111c){return function(_0x45a73a){const _0x3d9dd4=a487_0x16ac;if(_0x45a73a){const _0x115529=_0x45a73a[_0x3d9dd4('0x50')],_0x47ab0b=_0x2e111c[_0x3d9dd4('0x35')];let _0xd11a55=_0x2e111c[_0x3d9dd4('0x35')]+_0x2e111c[_0x3d9dd4('0x7')],_0x3867fe;return _0xd11a55>=_0x115529?(_0xd11a55=_0x115529,_0x3867fe=0xc8):_0x3867fe=0xce,_0x41e327['status'](_0x3867fe),_0x41e327[_0x3d9dd4('0x4e')](_0x3d9dd4('0x15'),_0x47ab0b+'-'+_0xd11a55+'/'+_0x115529)[_0x3d9dd4('0x22')](_0x45a73a);}return null;};}function saveUpdates(_0x20f8e6){return function(_0xec4da5){const _0x24a697=a487_0x16ac;if(_0xec4da5)return _0xec4da5[_0x24a697('0x47')](_0x20f8e6)[_0x24a697('0x40')](function(_0x34119c){return _0x34119c;});return null;};}function removeEntity(_0x1fea92){return function(_0x2f225c){const _0xf0f591=a487_0x16ac;if(_0x2f225c)return _0x2f225c[_0xf0f591('0x4b')]()[_0xf0f591('0x40')](function(){const _0x54a62d=_0xf0f591;_0x1fea92['status'](0xcc)[_0x54a62d('0x2a')]();});};}function handleEntityNotFound(_0x4384d5){return function(_0x5a1bf1){const _0x4f5dce=a487_0x16ac;return!_0x5a1bf1&&_0x4384d5[_0x4f5dce('0x44')](0x194),_0x5a1bf1;};}function handleError(_0x1a344d,_0x3da02b){return _0x3da02b=_0x3da02b||0x1f4,function(_0xcfc2ed){const _0x1d104a=a487_0x16ac;logger[_0x1d104a('0x41')](_0xcfc2ed[_0x1d104a('0xf')]),_0xcfc2ed['name']&&delete _0xcfc2ed['name'],_0x1a344d[_0x1d104a('0x59')](_0x3da02b)['send'](_0xcfc2ed);};}exports[_0x4a8521('0x1d')]=function(_0xdbc3a9,_0x23edaa){const _0x15b559=_0x4a8521;let _0x22384b={};const _0x289b75={},_0x2b5a7e={'count':0x0,'rows':[]},_0x25b884=_['map'](db[_0x15b559('0x3a')][_0x15b559('0x65')],function(_0x1913da){const _0x4a22ee=_0x15b559;return{'name':_0x1913da[_0x4a22ee('0x3')],'type':_0x1913da['type'][_0x4a22ee('0x27')]};});_0x289b75[_0x15b559('0x39')]=_[_0x15b559('0x51')](_0x25b884,'name'),_0x289b75[_0x15b559('0x3d')]=_[_0x15b559('0x8')](_0xdbc3a9[_0x15b559('0x3d')]),_0x289b75[_0x15b559('0x10')]=_[_0x15b559('0x31')](_0x289b75['model'],_0x289b75['query']),_0x22384b[_0x15b559('0x9')]=_['intersection'](_0x289b75['model'],qs['fields'](_0xdbc3a9['query']['fields'])),_0x22384b[_0x15b559('0x9')]=_0x22384b[_0x15b559('0x9')]['length']?_0x22384b[_0x15b559('0x9')]:_0x289b75['model'];typeof _0xdbc3a9[_0x15b559('0x3d')][_0x15b559('0xb')]===_0x15b559('0x3c')&&(_0x22384b['limit']=qs[_0x15b559('0x7')](_0xdbc3a9[_0x15b559('0x3d')][_0x15b559('0x7')]),_0x22384b['offset']=qs['offset'](_0xdbc3a9[_0x15b559('0x3d')][_0x15b559('0x35')]));_0x22384b['order']=qs[_0x15b559('0x34')](_0xdbc3a9[_0x15b559('0x3d')][_0x15b559('0x34')]),_0x22384b[_0x15b559('0x0')]=qs[_0x15b559('0x10')](_[_0x15b559('0x43')](_0xdbc3a9['query'],_0x289b75[_0x15b559('0x10')]),_0x25b884);_0xdbc3a9[_0x15b559('0x3d')]['filter']&&(_0x22384b[_0x15b559('0x0')]=_['merge'](_0x22384b[_0x15b559('0x0')],{[Op['or']]:_[_0x15b559('0x51')](_0x25b884,function(_0x3188a1){const _0x2766c4=_0x15b559;if(_0x3188a1[_0x2766c4('0x1a')]!==_0x2766c4('0x3b')){const _0x2125a1={};return _0x2125a1[_0x3188a1[_0x2766c4('0x5a')]]={[Op[_0x2766c4('0x1f')]]:'%'+_0xdbc3a9[_0x2766c4('0x3d')][_0x2766c4('0x62')]+'%'},_0x2125a1;}})}));_0x22384b=_['merge']({},_0x22384b,_0xdbc3a9[_0x15b559('0x30')]);const _0x2d7b9b={'where':_0x22384b[_0x15b559('0x0')]};return db['OpenchannelMessage']['count'](_0x2d7b9b)['then'](function(_0x4db54f){const _0x1ebba6=_0x15b559;return _0x2b5a7e[_0x1ebba6('0x50')]=_0x4db54f,_0xdbc3a9[_0x1ebba6('0x3d')][_0x1ebba6('0x14')]&&(_0x22384b[_0x1ebba6('0x1c')]=[{'all':!![]}]),db[_0x1ebba6('0x3a')][_0x1ebba6('0x4d')](_0x22384b);})['then'](function(_0x1f0a6b){return _0x2b5a7e['rows']=_0x1f0a6b,_0x2b5a7e;})['then'](respondWithFilteredResult(_0x23edaa,_0x22384b))[_0x15b559('0x56')](handleError(_0x23edaa,null));},exports[_0x4a8521('0x1b')]=function(_0x166db8,_0x69425b){const _0x3ea1c1=_0x4a8521;let _0x33a5d3={'raw':!![],'where':{'id':_0x166db8[_0x3ea1c1('0x19')]['id']}};const _0x2ead14={};return _0x2ead14[_0x3ea1c1('0x39')]=_[_0x3ea1c1('0x8')](db[_0x3ea1c1('0x3a')][_0x3ea1c1('0x65')]),_0x2ead14['query']=_[_0x3ea1c1('0x8')](_0x166db8['query']),_0x2ead14[_0x3ea1c1('0x10')]=_['intersection'](_0x2ead14[_0x3ea1c1('0x39')],_0x2ead14[_0x3ea1c1('0x3d')]),_0x33a5d3[_0x3ea1c1('0x9')]=_[_0x3ea1c1('0x31')](_0x2ead14['model'],qs[_0x3ea1c1('0x2c')](_0x166db8[_0x3ea1c1('0x3d')][_0x3ea1c1('0x2c')])),_0x33a5d3[_0x3ea1c1('0x9')]=_0x33a5d3[_0x3ea1c1('0x9')][_0x3ea1c1('0x5e')]?_0x33a5d3[_0x3ea1c1('0x9')]:_0x2ead14[_0x3ea1c1('0x39')],_0x166db8[_0x3ea1c1('0x3d')][_0x3ea1c1('0x14')]&&(_0x33a5d3[_0x3ea1c1('0x1c')]=[{'all':!![]}]),_0x33a5d3=_['merge']({},_0x33a5d3,_0x166db8[_0x3ea1c1('0x30')]),db[_0x3ea1c1('0x3a')][_0x3ea1c1('0x23')](_0x33a5d3)['then'](handleEntityNotFound(_0x69425b,null))['then'](respondWithResult(_0x69425b,null))[_0x3ea1c1('0x56')](handleError(_0x69425b,null));},exports[_0x4a8521('0x52')]=function(_0x274bba,_0x598948){const _0x17f7f2=_0x4a8521;return db['OpenchannelMessage'][_0x17f7f2('0x52')](_0x274bba[_0x17f7f2('0xa')],{})[_0x17f7f2('0x40')](respondWithResult(_0x598948,0xc9))[_0x17f7f2('0x56')](handleError(_0x598948,null));},exports['update']=function(_0x6c4af5,_0x5d74ad){const _0x572778=_0x4a8521;return _0x6c4af5['body']['id']&&delete _0x6c4af5[_0x572778('0xa')]['id'],db['OpenchannelMessage'][_0x572778('0x23')]({'where':{'id':_0x6c4af5[_0x572778('0x19')]['id']}})['then'](handleEntityNotFound(_0x5d74ad,null))[_0x572778('0x40')](saveUpdates(_0x6c4af5[_0x572778('0xa')],null))[_0x572778('0x40')](respondWithResult(_0x5d74ad,null))[_0x572778('0x56')](handleError(_0x5d74ad,null));},exports[_0x4a8521('0x4b')]=function(_0x3db3d5,_0x48c75d){const _0x2b308e=_0x4a8521;return db['OpenchannelMessage'][_0x2b308e('0x23')]({'where':{'id':_0x3db3d5['params']['id']}})[_0x2b308e('0x40')](handleEntityNotFound(_0x48c75d,null))[_0x2b308e('0x40')](removeEntity(_0x48c75d,null))[_0x2b308e('0x56')](handleError(_0x48c75d,null));},exports[_0x4a8521('0x13')]=function(_0x403d29,_0x6e7a75){const _0x4fe4f1=_0x4a8521;return db['OpenchannelMessage'][_0x4fe4f1('0x13')]()[_0x4fe4f1('0x40')](respondWithResult(_0x6e7a75,null))[_0x4fe4f1('0x56')](handleError(_0x6e7a75,null));},exports[_0x4a8521('0x5c')]=function(_0x5dbf10,_0x376e31){const _0x58abdf=_0x4a8521,_0x161242={'channel':_0x58abdf('0x4a')};return _0x5dbf10['body']['id']&&delete _0x5dbf10[_0x58abdf('0xa')]['id'],_0x5dbf10[_0x58abdf('0xa')]['read']=!![],_0x5dbf10[_0x58abdf('0xa')][_0x58abdf('0x37')]=moment()[_0x58abdf('0x4f')]('YYYY-MM-DD\x20HH:mm:ss'),_0x5dbf10[_0x58abdf('0xa')][_0x58abdf('0x2d')]=_0x5dbf10[_0x58abdf('0xa')]['UserId']||_0x5dbf10[_0x58abdf('0x2b')]['id'],db[_0x58abdf('0x3a')]['findOne']({'where':{'id':_0x5dbf10[_0x58abdf('0x19')]['id'],'UserId':null},'include':[{'model':db['CmContact'],'as':_0x58abdf('0x66')}]})['then'](handleEntityNotFound(_0x376e31,null))[_0x58abdf('0x40')](saveUpdates(_0x5dbf10[_0x58abdf('0xa')],null))['then'](function(_0x1b9e64){const _0x1fc82b=_0x58abdf;if(_0x1b9e64)return _0x161242[_0x1fc82b('0x2f')]=_0x1b9e64[_0x1fc82b('0x58')]({'plain':!![]}),db[_0x1fc82b('0x2e')][_0x1fc82b('0x23')]({'where':{'id':_0x1b9e64[_0x1fc82b('0x33')]}});return null;})[_0x58abdf('0x40')](handleEntityNotFound(_0x376e31,null))[_0x58abdf('0x40')](function(_0x6017ae){const _0x185e43=_0x58abdf;if(_0x6017ae)return _0x6017ae[_0x185e43('0x47')]({'UserId':_0x5dbf10[_0x185e43('0xa')][_0x185e43('0x2d')],'read1stAt':_[_0x185e43('0x36')](_0x6017ae[_0x185e43('0x61')])?moment()[_0x185e43('0x4f')](_0x185e43('0xd')):undefined});return null;})[_0x58abdf('0x40')](function(_0x28e442){const _0x3fd2d5=_0x58abdf;if(_0x28e442)return _0x161242[_0x3fd2d5('0x3e')]=_0x28e442[_0x3fd2d5('0x58')]({'plain':!![]}),interaction_log[_0x3fd2d5('0x3f')](_0x3fd2d5('0x38'),_0x5dbf10[_0x3fd2d5('0x2b')]['id'],_0x5dbf10['user']['name'],_0x5dbf10[_0x3fd2d5('0x2b')]['role'],_0x161242[_0x3fd2d5('0x3e')]['id'],_0x5dbf10[_0x3fd2d5('0xa')]?JSON['stringify'](_0x5dbf10[_0x3fd2d5('0xa')]):_0x3fd2d5('0x60')),respondWithRpcPromise(_0x3fd2d5('0x54'),_0x3fd2d5('0x32'),_0x161242);return null;})[_0x58abdf('0x40')](function(_0x46b669){const _0x345a84=_0x58abdf;if(_0x46b669){if(_0x5dbf10[_0x345a84('0xa')][_0x345a84('0x5d')])return _0x161242[_0x345a84('0x2f')][_0x345a84('0x4')]=util['format']('SIP/%s',_0x5dbf10[_0x345a84('0x2b')][_0x345a84('0x5a')]),_0x161242[_0x345a84('0x2f')][_0x345a84('0x5f')]=_0x161242[_0x345a84('0x5f')],_0x161242[_0x345a84('0x2f')][_0x345a84('0x20')]='accept',respondWithRpcPromise(_0x345a84('0x63'),_0x345a84('0x63'),{'event':_0x345a84('0x1e'),'message':_0x161242[_0x345a84('0x2f')]},client9002)[_0x345a84('0x40')](function(){return _0x161242;});return _0x161242;}return null;})['then'](respondWithResult(_0x376e31,null))['catch'](handleError(_0x376e31,null));},exports[_0x4a8521('0x4c')]=function(_0xc34ec4,_0x4edff7){const _0x4b7f95=_0x4a8521,_0x41aae1={'agent':{},'channel':_0x4b7f95('0x4a')};return _0xc34ec4[_0x4b7f95('0xa')]['id']&&delete _0xc34ec4['body']['id'],_0xc34ec4[_0x4b7f95('0xa')][_0x4b7f95('0x2d')]=_0xc34ec4[_0x4b7f95('0xa')][_0x4b7f95('0x2d')]||_0xc34ec4[_0x4b7f95('0x2b')]['id'],_0x41aae1[_0x4b7f95('0x46')]['id']=_0xc34ec4[_0x4b7f95('0xa')][_0x4b7f95('0x2d')],db[_0x4b7f95('0x3a')][_0x4b7f95('0x23')]({'where':{'id':_0xc34ec4[_0x4b7f95('0x19')]['id'],'UserId':null}})['then'](handleEntityNotFound(_0x4edff7,null))[_0x4b7f95('0x40')](function(_0x5d50e4){const _0x4d333f=_0x4b7f95;if(_0x5d50e4)return _0x41aae1[_0x4d333f('0x2f')]=_0x5d50e4['get']({'plain':!![]}),db['OpenchannelInteraction'][_0x4d333f('0x23')]({'where':{'id':_0x5d50e4[_0x4d333f('0x33')]}});return null;})[_0x4b7f95('0x40')](handleEntityNotFound(_0x4edff7,null))[_0x4b7f95('0x40')](function(_0x99158b){const _0x37d3b5=_0x4b7f95;if(_0x99158b)return _0x41aae1[_0x37d3b5('0x3e')]=_0x99158b['get']({'plain':!![]}),interaction_log[_0x37d3b5('0x3f')](_0x37d3b5('0x24'),_0xc34ec4[_0x37d3b5('0x2b')]['id'],_0xc34ec4[_0x37d3b5('0x2b')][_0x37d3b5('0x5a')],_0xc34ec4['user'][_0x37d3b5('0x57')],_0x41aae1['interaction']['id'],_0xc34ec4[_0x37d3b5('0xa')]?JSON[_0x37d3b5('0x18')](_0xc34ec4[_0x37d3b5('0xa')]):_0x37d3b5('0x60')),respondWithRpcPromise(_0x37d3b5('0x25'),_0x37d3b5('0x2'),_0x41aae1);return null;})[_0x4b7f95('0x40')](function(_0x26bbf8){const _0x3cdda8=_0x4b7f95;if(_0x26bbf8)return _0x26bbf8[_0x3cdda8('0x2f')][_0x3cdda8('0x4')]=util[_0x3cdda8('0x4f')](_0x3cdda8('0x5'),_0xc34ec4[_0x3cdda8('0x2b')]['name']),_0x26bbf8['message'][_0x3cdda8('0x5f')]=_0x41aae1['channel'],_0x26bbf8[_0x3cdda8('0x2f')][_0x3cdda8('0x20')]=_0x3cdda8('0x4c'),respondWithRpcPromise('EventManager','EventManager',{'event':_0x3cdda8('0x6'),'message':_0x26bbf8[_0x3cdda8('0x2f')]},client9002),_0x41aae1;return null;})[_0x4b7f95('0x40')](respondWithResult(_0x4edff7,null))[_0x4b7f95('0x56')](handleError(_0x4edff7,null));}; \ No newline at end of file diff --git a/server/api/openchannelMessage/openchannelMessage.events.js b/server/api/openchannelMessage/openchannelMessage.events.js index ce23dfd..10bf4da 100644 --- a/server/api/openchannelMessage/openchannelMessage.events.js +++ b/server/api/openchannelMessage/openchannelMessage.events.js @@ -1 +1 @@ -const a488_0x4d8f=['emit','addHook','OpenchannelMessage','../../mysqldb','undefined','exports'];(function(_0x2ca831,_0x4d8f1f){const _0x47ef76=function(_0x4af754){while(--_0x4af754){_0x2ca831['push'](_0x2ca831['shift']());}};_0x47ef76(++_0x4d8f1f);}(a488_0x4d8f,0x1b7));const a488_0x47ef=function(_0x2ca831,_0x4d8f1f){_0x2ca831=_0x2ca831-0x0;let _0x47ef76=a488_0x4d8f[_0x2ca831];return _0x47ef76;};const _0x29286d=a488_0x47ef;'use strict';const EventEmitter=require('events'),OpenchannelMessage=require(_0x29286d('0x2'))['db'][_0x29286d('0x1')],OpenchannelMessageEvents=new EventEmitter();OpenchannelMessageEvents['setMaxListeners'](0x0);const events={'afterCreate':'save','afterUpdate':'update','afterDestroy':'remove'};function emitEvent(_0x4af754){return function(_0x4f59c1){const _0x4d6307=a488_0x47ef;OpenchannelMessageEvents[_0x4d6307('0x5')](_0x4af754+':'+_0x4f59c1['id'],_0x4f59c1),OpenchannelMessageEvents['emit'](_0x4af754,_0x4f59c1);};}for(const e in events){if(typeof events[e]!==_0x29286d('0x3')){const event=events[e];OpenchannelMessage[_0x29286d('0x0')](e,emitEvent(event));}}module[_0x29286d('0x4')]=OpenchannelMessageEvents; \ No newline at end of file +const a488_0x5d46=['events','setMaxListeners','exports','emit','OpenchannelMessage','remove','undefined','save','../../mysqldb','update'];(function(_0x404cbe,_0x5d4697){const _0x1d2177=function(_0x19474f){while(--_0x19474f){_0x404cbe['push'](_0x404cbe['shift']());}};_0x1d2177(++_0x5d4697);}(a488_0x5d46,0x19f));const a488_0x1d21=function(_0x404cbe,_0x5d4697){_0x404cbe=_0x404cbe-0x0;let _0x1d2177=a488_0x5d46[_0x404cbe];return _0x1d2177;};const _0x562bd3=a488_0x1d21;'use strict';const EventEmitter=require(_0x562bd3('0x5')),OpenchannelMessage=require(_0x562bd3('0x3'))['db'][_0x562bd3('0x9')],OpenchannelMessageEvents=new EventEmitter();OpenchannelMessageEvents[_0x562bd3('0x6')](0x0);const events={'afterCreate':_0x562bd3('0x2'),'afterUpdate':_0x562bd3('0x4'),'afterDestroy':_0x562bd3('0x0')};function emitEvent(_0x19474f){return function(_0x133ff3){const _0x38d16e=a488_0x1d21;OpenchannelMessageEvents[_0x38d16e('0x8')](_0x19474f+':'+_0x133ff3['id'],_0x133ff3),OpenchannelMessageEvents['emit'](_0x19474f,_0x133ff3);};}for(const e in events){if(typeof events[e]!==_0x562bd3('0x1')){const event=events[e];OpenchannelMessage['addHook'](e,emitEvent(event));}}module[_0x562bd3('0x7')]=OpenchannelMessageEvents; \ No newline at end of file diff --git a/server/api/openchannelMessage/openchannelMessage.model.js b/server/api/openchannelMessage/openchannelMessage.model.js index b880d08..bb2454b 100644 --- a/server/api/openchannelMessage/openchannelMessage.model.js +++ b/server/api/openchannelMessage/openchannelMessage.model.js @@ -1 +1 @@ -const a489_0x5e0a=['Interactions','toLowerCase','isNil','GET','format','exports','OpenchannelMessage,\x20%s,\x20%s','get','Message\x20%d\x20forwarded\x20to\x20%s','utf8mb4_unicode_ci','Interaction','models','openchannel_messages','util','then','../../config/logger','UserId','OpenchannelInteractionId','update','describe','OpenchannelAccountId','body','createdAt','fti_openchannel_messages','out','direction','OpenchannelAccount','Contact','keys','OpenchannelInteraction','secret','error','info','inspect','utf8mb4','FULLTEXT','findOne','threadId','Forwarding\x20message\x20%d\x20to\x20%s','POST','./openchannelMessage.attributes','length','catch','replyUri','CmContact'];(function(_0x33b994,_0x5e0a0f){const _0x36de96=function(_0x4cf00a){while(--_0x4cf00a){_0x33b994['push'](_0x33b994['shift']());}};_0x36de96(++_0x5e0a0f);}(a489_0x5e0a,0x1d2));const a489_0x36de=function(_0x33b994,_0x5e0a0f){_0x33b994=_0x33b994-0x0;let _0x36de96=a489_0x5e0a[_0x33b994];return _0x36de96;};const _0x38da73=a489_0x36de;'use strict';const _=require('lodash'),util=require(_0x38da73('0x2a')),logger=require(_0x38da73('0x2c'))('api'),rp=require('request-promise-native'),attributes=require(_0x38da73('0x18'));module[_0x38da73('0x22')]=function(_0x4cf00a){const _0x5c1ff6=_0x38da73,_0x4aaeee=_0x4cf00a[_0x5c1ff6('0x28')],_0xbbcdaa=_0x4cf00a['define']('OpenchannelMessage',attributes,{'tableName':_0x5c1ff6('0x29'),'paranoid':![],'indexes':[{'name':_0x5c1ff6('0x7'),'fields':[_0x5c1ff6('0x5')],'type':_0x5c1ff6('0x13')}],'timestamps':!![],'hooks':{'afterCreate':function(_0x27c07a){const _0x3cbd10=_0x5c1ff6,_0xac8681=_0x27c07a['get']({'plain':!![]});(_0xac8681[_0x3cbd10('0x9')][_0x3cbd10('0x1e')]()==='in'||_0xac8681[_0x3cbd10('0x9')][_0x3cbd10('0x1e')]()===_0x3cbd10('0x8')&&!_0xac8681[_0x3cbd10('0xe')]&&!_[_0x3cbd10('0x1f')](_0xac8681[_0x3cbd10('0x0')]))&&_0x4aaeee[_0x3cbd10('0xd')]['findOne']({'where':{'id':_0xac8681[_0x3cbd10('0x1')]}})['then'](function(_0x3784a6){const _0x279f36=_0x3cbd10;_0x3784a6&&_0x3784a6[_0x279f36('0x2')]({'lastMsgAt':_0xac8681[_0x279f36('0x6')],'lastMsgDirection':_0xac8681[_0x279f36('0x9')][_0x279f36('0x1e')]()});})[_0x3cbd10('0x1a')](function(_0x53e066){console['error'](_0x53e066);});if(_0xac8681[_0x3cbd10('0x9')]==='out'&&!_0xac8681['secret']){let _0x234f5c;_0x4aaeee[_0x3cbd10('0x1c')][_0x3cbd10('0x3')]()[_0x3cbd10('0x2b')](function(_0x28c066){const _0x44cb18=_0x3cbd10;return _0x4aaeee[_0x44cb18('0xa')][_0x44cb18('0x14')]({'where':{'id':_0xac8681[_0x44cb18('0x4')]},'include':[{'model':_0x4aaeee['OpenchannelInteraction'],'as':'Interactions','where':{'id':_0xac8681[_0x44cb18('0x1')]},'limit':0x1,'include':[{'model':_0x4aaeee['CmContact'],'as':_0x44cb18('0xb'),'attributes':_[_0x44cb18('0xc')](_0x28c066)}]}]});})[_0x3cbd10('0x2b')](function(_0x2b308f){const _0x58872b=_0x3cbd10;_0x234f5c=_0x2b308f[_0x58872b('0x24')]({'plain':!![]});if(_0x234f5c&&_0x234f5c[_0x58872b('0x1b')]){logger[_0x58872b('0x10')](_0x58872b('0x23'),'afterCreate',util[_0x58872b('0x21')](_0x58872b('0x16'),_0xac8681['id'],_0x234f5c['replyUri']));_0x234f5c[_0x58872b('0x1d')]&&_0x234f5c[_0x58872b('0x1d')][_0x58872b('0x19')]&&(_0xac8681[_0x58872b('0x27')]=_['omit'](_0x234f5c[_0x58872b('0x1d')][0x0],'Contact'),_0xac8681[_0x58872b('0xb')]=_0x234f5c[_0x58872b('0x1d')][0x0]['Contact']);const _0x30a119={'method':_0x58872b('0x17'),'uri':encodeURI(_0x234f5c[_0x58872b('0x1b')]),'json':!![],'resolveWithFullResponse':!![]};switch(_0x30a119['method']){case _0x58872b('0x20'):_0x30a119['qs']=_0xac8681;break;case _0x58872b('0x17'):_0x30a119[_0x58872b('0x5')]=_0xac8681;break;}return rp(_0x30a119)[_0x58872b('0x2b')](function(_0x27e637){const _0x3e108b=_0x58872b;logger['info'](_0x3e108b('0x23'),'afterCreate',util['format'](_0x3e108b('0x25'),_0xac8681['id'],_0x234f5c[_0x3e108b('0x1b')]));if(_0x27e637[_0x3e108b('0x5')][_0x3e108b('0x15')]&&_0x27e637[_0x3e108b('0x5')][_0x3e108b('0x15')]!=_0xac8681[_0x3e108b('0x27')][_0x3e108b('0x15')])return _0x4aaeee[_0x3e108b('0xd')][_0x3e108b('0x2')]({'threadId':_0x27e637['body']['threadId']},{'logging':!![],'where':{'id':_0xac8681['Interaction']['id']}});else return;})[_0x58872b('0x2b')](function(){return _0x27c07a['update']({'read':!![]});})[_0x58872b('0x1a')](function(_0x1882ff){const _0x19f717=_0x58872b;logger[_0x19f717('0xf')](_0x19f717('0x23'),'afterCreate',util[_0x19f717('0x11')](_0x1882ff,{'showHidden':![],'depth':null}));});}})['finally'](function(){return null;});}else return null;}},'charset':_0x5c1ff6('0x12'),'collate':_0x5c1ff6('0x26')});return _0xbbcdaa;}; \ No newline at end of file +const a489_0x5e3f=['length','define','Message\x20%d\x20forwarded\x20to\x20%s','update','FULLTEXT','replyUri','OpenchannelMessage','catch','afterCreate','util','models','isNil','out','Interactions','format','describe','OpenchannelAccountId','OpenchannelInteractionId','get','finally','fti_openchannel_messages','toLowerCase','direction','error','threadId','GET','createdAt','Interaction','method','body','OpenchannelMessage,\x20%s,\x20%s','info','POST','api','secret','OpenchannelAccount','then','keys','CmContact','Contact','Forwarding\x20message\x20%d\x20to\x20%s','./openchannelMessage.attributes','utf8mb4_unicode_ci','OpenchannelInteraction','utf8mb4','lodash'];(function(_0x37cc57,_0x5e3f97){const _0x38fe28=function(_0x3e117f){while(--_0x3e117f){_0x37cc57['push'](_0x37cc57['shift']());}};_0x38fe28(++_0x5e3f97);}(a489_0x5e3f,0xd5));const a489_0x38fe=function(_0x37cc57,_0x5e3f97){_0x37cc57=_0x37cc57-0x0;let _0x38fe28=a489_0x5e3f[_0x37cc57];return _0x38fe28;};const _0x5a08d6=a489_0x38fe;'use strict';const _=require(_0x5a08d6('0x10')),util=require(_0x5a08d6('0x1a')),logger=require('../../config/logger')(_0x5a08d6('0x4')),rp=require('request-promise-native'),attributes=require(_0x5a08d6('0xc'));module['exports']=function(_0x3e117f){const _0x2c19a9=_0x5a08d6,_0xac924b=_0x3e117f[_0x2c19a9('0x1b')],_0x2078a1=_0x3e117f[_0x2c19a9('0x12')](_0x2c19a9('0x17'),attributes,{'tableName':'openchannel_messages','paranoid':![],'indexes':[{'name':_0x2c19a9('0x25'),'fields':['body'],'type':_0x2c19a9('0x15')}],'timestamps':!![],'hooks':{'afterCreate':function(_0x1f54f3){const _0xccc1f2=_0x2c19a9,_0x1bcd5b=_0x1f54f3['get']({'plain':!![]});(_0x1bcd5b[_0xccc1f2('0x27')][_0xccc1f2('0x26')]()==='in'||_0x1bcd5b['direction']['toLowerCase']()==='out'&&!_0x1bcd5b['secret']&&!_[_0xccc1f2('0x1c')](_0x1bcd5b['UserId']))&&_0xac924b[_0xccc1f2('0xe')]['findOne']({'where':{'id':_0x1bcd5b['OpenchannelInteractionId']}})[_0xccc1f2('0x7')](function(_0x23d296){const _0xfb0abb=_0xccc1f2;_0x23d296&&_0x23d296[_0xfb0abb('0x14')]({'lastMsgAt':_0x1bcd5b[_0xfb0abb('0x2b')],'lastMsgDirection':_0x1bcd5b[_0xfb0abb('0x27')][_0xfb0abb('0x26')]()});})[_0xccc1f2('0x18')](function(_0x40aaba){const _0x2fbc30=_0xccc1f2;console[_0x2fbc30('0x28')](_0x40aaba);});if(_0x1bcd5b[_0xccc1f2('0x27')]===_0xccc1f2('0x1d')&&!_0x1bcd5b[_0xccc1f2('0x5')]){let _0x57ed49;_0xac924b[_0xccc1f2('0x9')][_0xccc1f2('0x20')]()[_0xccc1f2('0x7')](function(_0x4b548c){const _0x233edf=_0xccc1f2;return _0xac924b[_0x233edf('0x6')]['findOne']({'where':{'id':_0x1bcd5b[_0x233edf('0x21')]},'include':[{'model':_0xac924b['OpenchannelInteraction'],'as':_0x233edf('0x1e'),'where':{'id':_0x1bcd5b[_0x233edf('0x22')]},'limit':0x1,'include':[{'model':_0xac924b[_0x233edf('0x9')],'as':_0x233edf('0xa'),'attributes':_[_0x233edf('0x8')](_0x4b548c)}]}]});})[_0xccc1f2('0x7')](function(_0x4ba3c0){const _0x20a7ab=_0xccc1f2;_0x57ed49=_0x4ba3c0[_0x20a7ab('0x23')]({'plain':!![]});if(_0x57ed49&&_0x57ed49[_0x20a7ab('0x16')]){logger['info'](_0x20a7ab('0x1'),_0x20a7ab('0x19'),util[_0x20a7ab('0x1f')](_0x20a7ab('0xb'),_0x1bcd5b['id'],_0x57ed49[_0x20a7ab('0x16')]));_0x57ed49[_0x20a7ab('0x1e')]&&_0x57ed49[_0x20a7ab('0x1e')][_0x20a7ab('0x11')]&&(_0x1bcd5b[_0x20a7ab('0x2c')]=_['omit'](_0x57ed49['Interactions'][0x0],_0x20a7ab('0xa')),_0x1bcd5b['Contact']=_0x57ed49[_0x20a7ab('0x1e')][0x0][_0x20a7ab('0xa')]);const _0x43cd53={'method':_0x20a7ab('0x3'),'uri':encodeURI(_0x57ed49['replyUri']),'json':!![],'resolveWithFullResponse':!![]};switch(_0x43cd53[_0x20a7ab('0x2d')]){case _0x20a7ab('0x2a'):_0x43cd53['qs']=_0x1bcd5b;break;case _0x20a7ab('0x3'):_0x43cd53[_0x20a7ab('0x0')]=_0x1bcd5b;break;}return rp(_0x43cd53)['then'](function(_0x49b0e6){const _0x78e18a=_0x20a7ab;logger[_0x78e18a('0x2')](_0x78e18a('0x1'),'afterCreate',util[_0x78e18a('0x1f')](_0x78e18a('0x13'),_0x1bcd5b['id'],_0x57ed49[_0x78e18a('0x16')]));if(_0x49b0e6['body'][_0x78e18a('0x29')]&&_0x49b0e6['body']['threadId']!=_0x1bcd5b[_0x78e18a('0x2c')][_0x78e18a('0x29')])return _0xac924b[_0x78e18a('0xe')]['update']({'threadId':_0x49b0e6[_0x78e18a('0x0')][_0x78e18a('0x29')]},{'logging':!![],'where':{'id':_0x1bcd5b[_0x78e18a('0x2c')]['id']}});else return;})[_0x20a7ab('0x7')](function(){const _0x43b86d=_0x20a7ab;return _0x1f54f3[_0x43b86d('0x14')]({'read':!![]});})[_0x20a7ab('0x18')](function(_0x26de2b){const _0x3d3e2b=_0x20a7ab;logger['error'](_0x3d3e2b('0x1'),_0x3d3e2b('0x19'),util['inspect'](_0x26de2b,{'showHidden':![],'depth':null}));});}})[_0xccc1f2('0x24')](function(){return null;});}else return null;}},'charset':_0x2c19a9('0xf'),'collate':_0x2c19a9('0xd')});return _0x2078a1;}; \ No newline at end of file diff --git a/server/api/openchannelMessage/openchannelMessage.rpc.js b/server/api/openchannelMessage/openchannelMessage.rpc.js index e1b2c42..944484c 100644 --- a/server/api/openchannelMessage/openchannelMessage.rpc.js +++ b/server/api/openchannelMessage/openchannelMessage.rpc.js @@ -1 +1 @@ -const a490_0x4138=['register','catch','raw','./openchannelMessage.socket','../../config/logger','rpc','create','then','info','body','OpenchannelMessage','../../mysqldb','debug','../../rediscache','options','CreateOpenchannelMessage','error'];(function(_0x5890c6,_0x413896){const _0x235222=function(_0x30efd0){while(--_0x30efd0){_0x5890c6['push'](_0x5890c6['shift']());}};_0x235222(++_0x413896);}(a490_0x4138,0x19f));const a490_0x2352=function(_0x5890c6,_0x413896){_0x5890c6=_0x5890c6-0x0;let _0x235222=a490_0x4138[_0x5890c6];return _0x235222;};const _0x4ad7fd=a490_0x2352;'use strict';const db=require(_0x4ad7fd('0x4'))['db'],logger=require(_0x4ad7fd('0xe'))(_0x4ad7fd('0xf')),{getSocket}=require(_0x4ad7fd('0x6')),socket=getSocket();require(_0x4ad7fd('0xd'))[_0x4ad7fd('0xa')](socket),exports[_0x4ad7fd('0x8')]=function(_0x30efd0){const _0x4b155b=this;return new Promise(function(_0x290426,_0xdfe6f9){const _0x5a5cfe=a490_0x2352;return db[_0x5a5cfe('0x3')][_0x5a5cfe('0x10')](_0x30efd0[_0x5a5cfe('0x2')],{'raw':_0x30efd0[_0x5a5cfe('0x7')]?_0x30efd0['options'][_0x5a5cfe('0xc')]===undefined?!![]:![]:!![]})[_0x5a5cfe('0x0')](function(_0x178095){const _0x26024b=_0x5a5cfe;logger[_0x26024b('0x1')](_0x26024b('0x8'),_0x30efd0),logger[_0x26024b('0x5')](_0x26024b('0x8'),_0x30efd0,JSON['stringify'](_0x178095)),_0x290426(_0x178095);})[_0x5a5cfe('0xb')](function(_0x31ae85){const _0x555287=_0x5a5cfe;logger[_0x555287('0x9')](_0x555287('0x8'),_0x31ae85['message'],_0x30efd0),_0xdfe6f9(_0x4b155b[_0x555287('0x9')](0x1f4,_0x31ae85['message']));});});}; \ No newline at end of file +const a490_0x338e=['./openchannelMessage.socket','raw','../../mysqldb','options','error','debug','then','CreateOpenchannelMessage','catch','rpc','../../rediscache','message','../../config/logger'];(function(_0x48582e,_0x338e15){const _0x764135=function(_0x3b9eca){while(--_0x3b9eca){_0x48582e['push'](_0x48582e['shift']());}};_0x764135(++_0x338e15);}(a490_0x338e,0x8a));const a490_0x7641=function(_0x48582e,_0x338e15){_0x48582e=_0x48582e-0x0;let _0x764135=a490_0x338e[_0x48582e];return _0x764135;};const _0x211acb=a490_0x7641;'use strict';const db=require(_0x211acb('0x7'))['db'],logger=require(_0x211acb('0x4'))(_0x211acb('0x1')),{getSocket}=require(_0x211acb('0x2')),socket=getSocket();require(_0x211acb('0x5'))['register'](socket),exports[_0x211acb('0xc')]=function(_0x3b9eca){const _0xaaf5e0=this;return new Promise(function(_0x40cd06,_0x5626b7){const _0x1a1ab3=a490_0x7641;return db['OpenchannelMessage']['create'](_0x3b9eca['body'],{'raw':_0x3b9eca[_0x1a1ab3('0x8')]?_0x3b9eca[_0x1a1ab3('0x8')][_0x1a1ab3('0x6')]===undefined?!![]:![]:!![]})[_0x1a1ab3('0xb')](function(_0x119b84){const _0x69abaf=_0x1a1ab3;logger['info'](_0x69abaf('0xc'),_0x3b9eca),logger[_0x69abaf('0xa')](_0x69abaf('0xc'),_0x3b9eca,JSON['stringify'](_0x119b84)),_0x40cd06(_0x119b84);})[_0x1a1ab3('0x0')](function(_0x4f684a){const _0x29c9fe=_0x1a1ab3;logger[_0x29c9fe('0x9')](_0x29c9fe('0xc'),_0x4f684a[_0x29c9fe('0x3')],_0x3b9eca),_0x5626b7(_0xaaf5e0['error'](0x1f4,_0x4f684a[_0x29c9fe('0x3')]));});});}; \ No newline at end of file diff --git a/server/api/openchannelMessage/openchannelMessage.socket.js b/server/api/openchannelMessage/openchannelMessage.socket.js index 28fd890..649c404 100644 --- a/server/api/openchannelMessage/openchannelMessage.socket.js +++ b/server/api/openchannelMessage/openchannelMessage.socket.js @@ -1 +1 @@ -const a491_0x1dde=['register','emit','openchannelMessage:','save','./openchannelMessage.events','remove','length','update'];(function(_0x26da6b,_0x1dde1a){const _0x3ec222=function(_0x18f5ec){while(--_0x18f5ec){_0x26da6b['push'](_0x26da6b['shift']());}};_0x3ec222(++_0x1dde1a);}(a491_0x1dde,0x14d));const a491_0x3ec2=function(_0x26da6b,_0x1dde1a){_0x26da6b=_0x26da6b-0x0;let _0x3ec222=a491_0x1dde[_0x26da6b];return _0x3ec222;};const _0x574eca=a491_0x3ec2;'use strict';const OpenchannelMessageEvents=require(_0x574eca('0x7')),events=[_0x574eca('0x6'),_0x574eca('0x0'),_0x574eca('0x2')];function createListener(_0x18f5ec,_0x319fe8){return function(_0x57d6ae){const _0x595b69=a491_0x3ec2;_0x319fe8[_0x595b69('0x4')](_0x18f5ec,_0x57d6ae);};}exports[_0x574eca('0x3')]=function(_0x1be741){const _0x513969=_0x574eca;for(let _0x43a155=0x0,_0x1608ad=events[_0x513969('0x1')];_0x43a155<_0x1608ad;_0x43a155++){const _0x217fae=events[_0x43a155],_0x1afc88=createListener(_0x513969('0x5')+_0x217fae,_0x1be741);OpenchannelMessageEvents['on'](_0x217fae,_0x1afc88);}}; \ No newline at end of file +const a491_0x23c6=['save','length','./openchannelMessage.events','openchannelMessage:'];(function(_0x7b68b7,_0x23c6ff){const _0x397adb=function(_0x2e31f8){while(--_0x2e31f8){_0x7b68b7['push'](_0x7b68b7['shift']());}};_0x397adb(++_0x23c6ff);}(a491_0x23c6,0x17d));const a491_0x397a=function(_0x7b68b7,_0x23c6ff){_0x7b68b7=_0x7b68b7-0x0;let _0x397adb=a491_0x23c6[_0x7b68b7];return _0x397adb;};const _0x50495d=a491_0x397a;'use strict';const OpenchannelMessageEvents=require(_0x50495d('0x1')),events=[_0x50495d('0x3'),'remove','update'];function createListener(_0x2e31f8,_0x1831df){return function(_0x5dccbb){_0x1831df['emit'](_0x2e31f8,_0x5dccbb);};}exports['register']=function(_0x41e350){const _0x14fd39=_0x50495d;for(let _0x4be312=0x0,_0xc5904b=events[_0x14fd39('0x0')];_0x4be312<_0xc5904b;_0x4be312++){const _0x4e93a2=events[_0x4be312],_0x3c73eb=createListener(_0x14fd39('0x2')+_0x4e93a2,_0x41e350);OpenchannelMessageEvents['on'](_0x4e93a2,_0x3c73eb);}}; \ No newline at end of file diff --git a/server/api/openchannelQueue/index.js b/server/api/openchannelQueue/index.js index ceca24d..41071cc 100644 --- a/server/api/openchannelQueue/index.js +++ b/server/api/openchannelQueue/index.js @@ -1 +1 @@ -const a492_0x32ef=['put','/:id/teams','/describe','isAuthenticated','express','/:id','Router','show','removeAgents','index','destroy','getMembers','delete','addAgents','create','describe','post','removeTeams','get','../../components/auth/service','/:id/users','exports','addTeams','getTeams','getAgents'];(function(_0x286abc,_0x32ef83){const _0x5de725=function(_0x2dffe2){while(--_0x2dffe2){_0x286abc['push'](_0x286abc['shift']());}};_0x5de725(++_0x32ef83);}(a492_0x32ef,0x78));const a492_0x5de7=function(_0x286abc,_0x32ef83){_0x286abc=_0x286abc-0x0;let _0x5de725=a492_0x32ef[_0x286abc];return _0x5de725;};const _0x1e3a3f=a492_0x5de7;'use strict';const express=require(_0x1e3a3f('0x9')),router=express[_0x1e3a3f('0xb')](),auth=require(_0x1e3a3f('0x18')),controller=require('./openchannelQueue.controller');router[_0x1e3a3f('0x17')]('/',auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0xe')]),router[_0x1e3a3f('0x17')](_0x1e3a3f('0x7'),auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0x14')]),router['get'](_0x1e3a3f('0xa'),auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0xc')]),router[_0x1e3a3f('0x17')]('/:id/members',auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0x10')]),router[_0x1e3a3f('0x17')](_0x1e3a3f('0x6'),auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0x3')]),router[_0x1e3a3f('0x17')]('/:id/users',auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0x4')]),router[_0x1e3a3f('0x15')]('/',auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0x13')]),router[_0x1e3a3f('0x15')]('/:id/teams',auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0x2')]),router[_0x1e3a3f('0x15')](_0x1e3a3f('0x0'),auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0x12')]),router[_0x1e3a3f('0x5')]('/:id',auth[_0x1e3a3f('0x8')](),controller['update']),router[_0x1e3a3f('0x11')](_0x1e3a3f('0xa'),auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0xf')]),router[_0x1e3a3f('0x11')](_0x1e3a3f('0x6'),auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0x16')]),router['delete'](_0x1e3a3f('0x0'),auth[_0x1e3a3f('0x8')](),controller[_0x1e3a3f('0xd')]),module[_0x1e3a3f('0x1')]=router; \ No newline at end of file +const a492_0x5086=['removeAgents','update','/:id','destroy','Router','delete','./openchannelQueue.controller','express','post','/:id/users','put','removeTeams','getMembers','index','/:id/teams','/describe','getAgents','create','addTeams','../../components/auth/service','get','addAgents','getTeams','describe','isAuthenticated'];(function(_0x458795,_0x5086a6){const _0x4588f7=function(_0xa99ab9){while(--_0xa99ab9){_0x458795['push'](_0x458795['shift']());}};_0x4588f7(++_0x5086a6);}(a492_0x5086,0x14c));const a492_0x4588=function(_0x458795,_0x5086a6){_0x458795=_0x458795-0x0;let _0x4588f7=a492_0x5086[_0x458795];return _0x4588f7;};const _0x38bfd3=a492_0x4588;'use strict';const express=require(_0x38bfd3('0x0')),router=express[_0x38bfd3('0x16')](),auth=require(_0x38bfd3('0xc')),controller=require(_0x38bfd3('0x18'));router[_0x38bfd3('0xd')]('/',auth[_0x38bfd3('0x11')](),controller[_0x38bfd3('0x6')]),router[_0x38bfd3('0xd')](_0x38bfd3('0x8'),auth[_0x38bfd3('0x11')](),controller[_0x38bfd3('0x10')]),router[_0x38bfd3('0xd')](_0x38bfd3('0x14'),auth[_0x38bfd3('0x11')](),controller['show']),router['get']('/:id/members',auth['isAuthenticated'](),controller[_0x38bfd3('0x5')]),router[_0x38bfd3('0xd')](_0x38bfd3('0x7'),auth['isAuthenticated'](),controller[_0x38bfd3('0xf')]),router['get'](_0x38bfd3('0x2'),auth[_0x38bfd3('0x11')](),controller[_0x38bfd3('0x9')]),router['post']('/',auth['isAuthenticated'](),controller[_0x38bfd3('0xa')]),router[_0x38bfd3('0x1')](_0x38bfd3('0x7'),auth[_0x38bfd3('0x11')](),controller[_0x38bfd3('0xb')]),router[_0x38bfd3('0x1')](_0x38bfd3('0x2'),auth[_0x38bfd3('0x11')](),controller[_0x38bfd3('0xe')]),router[_0x38bfd3('0x3')](_0x38bfd3('0x14'),auth[_0x38bfd3('0x11')](),controller[_0x38bfd3('0x13')]),router[_0x38bfd3('0x17')](_0x38bfd3('0x14'),auth[_0x38bfd3('0x11')](),controller[_0x38bfd3('0x15')]),router[_0x38bfd3('0x17')](_0x38bfd3('0x7'),auth[_0x38bfd3('0x11')](),controller[_0x38bfd3('0x4')]),router[_0x38bfd3('0x17')](_0x38bfd3('0x2'),auth[_0x38bfd3('0x11')](),controller[_0x38bfd3('0x12')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/openchannelQueue/openchannelQueue.attributes.js b/server/api/openchannelQueue/openchannelQueue.attributes.js index c718541..99e8d69 100644 --- a/server/api/openchannelQueue/openchannelQueue.attributes.js +++ b/server/api/openchannelQueue/openchannelQueue.attributes.js @@ -1 +1 @@ -const a493_0x4071=['INTEGER','exports','STRING','name','beepall','ENUM','roundrobin','sequelize'];(function(_0x36563a,_0x4071c5){const _0x26e628=function(_0x3d0815){while(--_0x3d0815){_0x36563a['push'](_0x36563a['shift']());}};_0x26e628(++_0x4071c5);}(a493_0x4071,0x1eb));const a493_0x26e6=function(_0x36563a,_0x4071c5){_0x36563a=_0x36563a-0x0;let _0x26e628=a493_0x4071[_0x36563a];return _0x26e628;};const _0x56a09a=a493_0x26e6;'use strict';const Sequelize=require(_0x56a09a('0x4'));module[_0x56a09a('0x6')]={'name':{'type':Sequelize[_0x56a09a('0x7')],'unique':_0x56a09a('0x0'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize[_0x56a09a('0x7')]},'timeout':{'type':Sequelize[_0x56a09a('0x5')],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x56a09a('0x2')]('rrmemory',_0x56a09a('0x1'),_0x56a09a('0x3'))}}; \ No newline at end of file +const a493_0xb8bb=['rrmemory','INTEGER','sequelize','ENUM','STRING','name','exports','beepall'];(function(_0x410965,_0xb8bb0f){const _0x4ae6de=function(_0x370e28){while(--_0x370e28){_0x410965['push'](_0x410965['shift']());}};_0x4ae6de(++_0xb8bb0f);}(a493_0xb8bb,0xd8));const a493_0x4ae6=function(_0x410965,_0xb8bb0f){_0x410965=_0x410965-0x0;let _0x4ae6de=a493_0xb8bb[_0x410965];return _0x4ae6de;};const _0x4747a5=a493_0x4ae6;'use strict';const Sequelize=require(_0x4747a5('0x2'));module[_0x4747a5('0x6')]={'name':{'type':Sequelize[_0x4747a5('0x4')],'unique':_0x4747a5('0x5'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize[_0x4747a5('0x4')]},'timeout':{'type':Sequelize[_0x4747a5('0x1')],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x4747a5('0x3')](_0x4747a5('0x0'),_0x4747a5('0x7'),'roundrobin')}}; \ No newline at end of file diff --git a/server/api/openchannelQueue/openchannelQueue.controller.js b/server/api/openchannelQueue/openchannelQueue.controller.js index eed29ed..0126206 100644 --- a/server/api/openchannelQueue/openchannelQueue.controller.js +++ b/server/api/openchannelQueue/openchannelQueue.controller.js @@ -1 +1 @@ -const a494_0x2c5f=['SELECT','UserProfileResource','openchannelPause','get','ids','isEmpty','sort','every','describe','online','destroy','user_has_teams','getTeams','flatMap','removeTeams','json','TeamId','includes','from','role','params','sequelize','OpenchannelQueueId\x20=\x20?','Unable\x20to\x20retrieve\x20the\x20current\x20user','keys','transaction','type','all','userOpenchannelQueue:save','then','../../rediscache','push','../../config/logger','nolimit','merge','isArray','sendStatus','key','addAgents','ut.TeamId\x20=\x20tq.TeamId','voicePause','stack','set','like','query','OpenchannelQueue','status','removeAgents','UserOpenchannelQueue','error','select','length','VIRTUAL','end','forEach','where','interface','rawAttributes','UserProfileSection','offset','body','count','findOrCreate','ut.UserId\x20=\x20?','filters','filter','limit','create','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','getAgents','toString','findAll','intersection','send','addTeams','util','OpenchannelQueueId','clone','catch','Team','autoAssociation','union','model','register','squel','Agents','index','./openchannelQueue.socket','update','options','updatedAt','include','name','map','Content-Range','getMembers','emit','format','pick','findOne','User','omit','SIP','%s/%s','OpenchannelQueues','findAndCountAll','attributes','createdAt','userOpenchannelQueue:remove','fields','compact','../../components/parsers/qs','order','undefined','rows'];(function(_0x2f693e,_0x2c5faa){const _0x455c45=function(_0x34b012){while(--_0x34b012){_0x2f693e['push'](_0x2f693e['shift']());}};_0x455c45(++_0x2c5faa);}(a494_0x2c5f,0x16c));const a494_0x455c=function(_0x2f693e,_0x2c5faa){_0x2f693e=_0x2f693e-0x0;let _0x455c45=a494_0x2c5f[_0x2f693e];return _0x455c45;};const _0x2b51f4=a494_0x455c;'use strict';const util=require(_0x2b51f4('0x38')),_=require('lodash'),squel=require(_0x2b51f4('0x41')),qs=require(_0x2b51f4('0x5c')),logger=require(_0x2b51f4('0xd'))('api'),{getSocket}=require(_0x2b51f4('0xb')),socket=getSocket(),db=require('../../mysqldb')['db'],{Op,QueryTypes}=require(_0x2b51f4('0x2'));require(_0x2b51f4('0x44'))[_0x2b51f4('0x40')](socket);function respondWithStatusCode(_0x34b012,_0x169f9f){return _0x169f9f=_0x169f9f||0xcc,function(_0x18128d){const _0x579243=a494_0x455c;if(_0x18128d)return _0x34b012[_0x579243('0x11')](_0x169f9f);return _0x34b012[_0x579243('0x1b')](_0x169f9f)[_0x579243('0x22')]();};}function respondWithResult(_0x47d3ba,_0x392882){return _0x392882=_0x392882||0xc8,function(_0x307fe4){if(_0x307fe4)return _0x47d3ba['status'](_0x392882)['json'](_0x307fe4);};}function respondWithFilteredResult(_0x237c8b,_0x5451c4){return function(_0x80f3a5){const _0x24e809=a494_0x455c;if(_0x80f3a5){const _0x445127=_0x80f3a5['count'],_0x23cd7a=_0x5451c4[_0x24e809('0x28')];let _0x78164e=_0x5451c4[_0x24e809('0x28')]+_0x5451c4['limit'],_0xd55095;return _0x78164e>=_0x445127?(_0x78164e=_0x445127,_0xd55095=0xc8):_0xd55095=0xce,_0x237c8b[_0x24e809('0x1b')](_0xd55095),_0x237c8b[_0x24e809('0x17')](_0x24e809('0x4b'),_0x23cd7a+'-'+_0x78164e+'/'+_0x445127)[_0x24e809('0x6f')](_0x80f3a5);}return null;};}function saveUpdates(_0x5a1e3b){return function(_0x21bc15){const _0x23394c=a494_0x455c;if(_0x21bc15)return _0x21bc15[_0x23394c('0x45')](_0x5a1e3b)['then'](function(_0x1419c6){return _0x1419c6;});return null;};}function removeEntity(_0x4f9742){return function(_0x25920e){const _0x44bf4c=a494_0x455c;if(_0x25920e)return _0x25920e[_0x44bf4c('0x6a')]()[_0x44bf4c('0xa')](function(){const _0x3e6809=_0x44bf4c,_0x2e9269=_0x25920e[_0x3e6809('0x63')]({'plain':!![]}),_0x10ce61=_0x3e6809('0x55');return db[_0x3e6809('0x61')][_0x3e6809('0x6a')]({'where':{'type':_0x10ce61,'resourceId':_0x2e9269['id']}})[_0x3e6809('0xa')](function(){return _0x25920e;});})[_0x44bf4c('0xa')](function(){const _0x8fd972=_0x44bf4c;_0x4f9742[_0x8fd972('0x1b')](0xcc)[_0x8fd972('0x22')]();});};}function handleEntityNotFound(_0x1f5c11){return function(_0x51bb00){const _0x539234=a494_0x455c;return!_0x51bb00&&_0x1f5c11[_0x539234('0x11')](0x194),_0x51bb00;};}function handleError(_0x65aede,_0x4651f7){return _0x4651f7=_0x4651f7||0x1f4,function(_0x4677e7){const _0x43e13f=a494_0x455c;logger['error'](_0x4677e7[_0x43e13f('0x16')]),_0x4677e7['name']&&delete _0x4677e7['name'],_0x65aede[_0x43e13f('0x1b')](_0x4651f7)[_0x43e13f('0x36')](_0x4677e7);};}exports[_0x2b51f4('0x43')]=function(_0x16f54e,_0x24a464){const _0x4d442d=_0x2b51f4;let _0x4f2f85={};const _0x46a009={},_0x417a49={'count':0x0,'rows':[]},_0x4dea91=_['map'](db[_0x4d442d('0x1a')][_0x4d442d('0x26')],function(_0x4095a8){const _0x238d00=_0x4d442d;return{'name':_0x4095a8['fieldName'],'type':_0x4095a8[_0x238d00('0x7')][_0x238d00('0x12')]};});_0x46a009[_0x4d442d('0x3f')]=_[_0x4d442d('0x4a')](_0x4dea91,_0x4d442d('0x49')),_0x46a009[_0x4d442d('0x19')]=_[_0x4d442d('0x5')](_0x16f54e[_0x4d442d('0x19')]),_0x46a009[_0x4d442d('0x2d')]=_[_0x4d442d('0x35')](_0x46a009[_0x4d442d('0x3f')],_0x46a009[_0x4d442d('0x19')]),_0x4f2f85['attributes']=_[_0x4d442d('0x35')](_0x46a009[_0x4d442d('0x3f')],qs['fields'](_0x16f54e[_0x4d442d('0x19')]['fields'])),_0x4f2f85[_0x4d442d('0x57')]=_0x4f2f85[_0x4d442d('0x57')][_0x4d442d('0x20')]?_0x4f2f85[_0x4d442d('0x57')]:_0x46a009[_0x4d442d('0x3f')];typeof _0x16f54e[_0x4d442d('0x19')][_0x4d442d('0xe')]===_0x4d442d('0x5e')&&(_0x4f2f85['limit']=qs['limit'](_0x16f54e[_0x4d442d('0x19')][_0x4d442d('0x2f')]),_0x4f2f85[_0x4d442d('0x28')]=qs[_0x4d442d('0x28')](_0x16f54e[_0x4d442d('0x19')][_0x4d442d('0x28')]));_0x4f2f85[_0x4d442d('0x5d')]=qs[_0x4d442d('0x66')](_0x16f54e[_0x4d442d('0x19')][_0x4d442d('0x66')]),_0x4f2f85[_0x4d442d('0x24')]=qs[_0x4d442d('0x2d')](_['pick'](_0x16f54e['query'],_0x46a009[_0x4d442d('0x2d')]),_0x4dea91);_0x16f54e[_0x4d442d('0x19')][_0x4d442d('0x2e')]&&(_0x4f2f85[_0x4d442d('0x24')]=_[_0x4d442d('0xf')](_0x4f2f85[_0x4d442d('0x24')],{[Op['or']]:_[_0x4d442d('0x4a')](_0x4dea91,function(_0x2f8dbd){const _0x244510=_0x4d442d;if(_0x2f8dbd[_0x244510('0x7')]!==_0x244510('0x21')){const _0xe60615={};return _0xe60615[_0x2f8dbd[_0x244510('0x49')]]={[Op['like']]:'%'+_0x16f54e[_0x244510('0x19')][_0x244510('0x2e')]+'%'},_0xe60615;}})}));_0x4f2f85=_[_0x4d442d('0xf')]({},_0x4f2f85,_0x16f54e['options']);const _0x57bd68={'where':_0x4f2f85[_0x4d442d('0x24')]};return db['OpenchannelQueue'][_0x4d442d('0x2a')](_0x57bd68)[_0x4d442d('0xa')](function(_0x165b14){const _0x58cadd=_0x4d442d;return _0x417a49[_0x58cadd('0x2a')]=_0x165b14,_0x16f54e[_0x58cadd('0x19')]['includeAll']&&(_0x4f2f85[_0x58cadd('0x48')]=[{'all':!![]}]),db['OpenchannelQueue']['findAll'](_0x4f2f85);})[_0x4d442d('0xa')](function(_0x5190b2){const _0x7187a2=_0x4d442d;return _0x417a49[_0x7187a2('0x5f')]=_0x5190b2,_0x417a49;})['then'](respondWithFilteredResult(_0x24a464,_0x4f2f85))[_0x4d442d('0x3b')](handleError(_0x24a464,null));},exports['show']=function(_0xeeed90,_0x4732ee){const _0xaef7df=_0x2b51f4;let _0xd06359={'raw':!![],'where':{'id':_0xeeed90[_0xaef7df('0x1')]['id']}};const _0x1badf2={};return _0x1badf2[_0xaef7df('0x3f')]=_[_0xaef7df('0x5')](db['OpenchannelQueue'][_0xaef7df('0x26')]),_0x1badf2[_0xaef7df('0x19')]=_['keys'](_0xeeed90[_0xaef7df('0x19')]),_0x1badf2[_0xaef7df('0x2d')]=_[_0xaef7df('0x35')](_0x1badf2[_0xaef7df('0x3f')],_0x1badf2['query']),_0xd06359[_0xaef7df('0x57')]=_['intersection'](_0x1badf2[_0xaef7df('0x3f')],qs[_0xaef7df('0x5a')](_0xeeed90[_0xaef7df('0x19')][_0xaef7df('0x5a')])),_0xd06359['attributes']=_0xd06359[_0xaef7df('0x57')]['length']?_0xd06359[_0xaef7df('0x57')]:_0x1badf2['model'],_0xeeed90['query']['includeAll']&&(_0xd06359[_0xaef7df('0x48')]=[{'all':!![]}]),_0xd06359=_[_0xaef7df('0xf')]({},_0xd06359,_0xeeed90[_0xaef7df('0x46')]),db['OpenchannelQueue'][_0xaef7df('0x50')](_0xd06359)[_0xaef7df('0xa')](handleEntityNotFound(_0x4732ee,null))['then'](respondWithResult(_0x4732ee,null))[_0xaef7df('0x3b')](handleError(_0x4732ee,null));},exports['create']=function(_0x5b909a,_0x2f27be){const _0x5829a8=_0x2b51f4;return db[_0x5829a8('0x1a')][_0x5829a8('0x30')](_0x5b909a[_0x5829a8('0x29')],{})['then'](function(_0x54b56a){const _0x11be6d=_0x5829a8,_0x5bf78f=_0x5b909a['user'][_0x11be6d('0x63')]({'plain':!![]});if(!_0x5bf78f)throw new Error(_0x11be6d('0x4'));if(_0x5bf78f[_0x11be6d('0x0')]==='user'){const _0x22307a=_0x54b56a['get']({'plain':!![]}),_0x4dd5d9=_0x11be6d('0x55');return db[_0x11be6d('0x27')][_0x11be6d('0x50')]({'where':{'name':_0x4dd5d9,'userProfileId':_0x5bf78f['userProfileId']},'raw':!![]})[_0x11be6d('0xa')](function(_0x42a666){const _0x57bc10=_0x11be6d;return _0x42a666&&_0x42a666[_0x57bc10('0x3d')]===0x0?db[_0x57bc10('0x61')][_0x57bc10('0x30')]({'name':_0x22307a[_0x57bc10('0x49')],'resourceId':_0x22307a['id'],'type':_0x42a666[_0x57bc10('0x49')],'sectionId':_0x42a666['id']},{})[_0x57bc10('0xa')](function(){return _0x54b56a;}):_0x54b56a;})['catch'](function(_0x679a50){const _0x14a968=_0x11be6d;logger[_0x14a968('0x1e')](_0x14a968('0x31'),_0x679a50);throw _0x679a50;});}return _0x54b56a;})[_0x5829a8('0xa')](respondWithResult(_0x2f27be,0xc9))[_0x5829a8('0x3b')](handleError(_0x2f27be,null));},exports[_0x2b51f4('0x45')]=function(_0x5a4455,_0x4022f7){const _0x3626c6=_0x2b51f4;return _0x5a4455[_0x3626c6('0x29')]['id']&&delete _0x5a4455[_0x3626c6('0x29')]['id'],db[_0x3626c6('0x1a')][_0x3626c6('0x50')]({'where':{'id':_0x5a4455[_0x3626c6('0x1')]['id']}})[_0x3626c6('0xa')](handleEntityNotFound(_0x4022f7,null))['then'](saveUpdates(_0x5a4455[_0x3626c6('0x29')],null))['then'](respondWithResult(_0x4022f7,null))['catch'](handleError(_0x4022f7,null));},exports['destroy']=function(_0x3e1119,_0x2cdb1e){const _0x253f69=_0x2b51f4;return db[_0x253f69('0x1a')][_0x253f69('0x50')]({'where':{'id':_0x3e1119[_0x253f69('0x1')]['id']}})['then'](handleEntityNotFound(_0x2cdb1e,null))[_0x253f69('0xa')](removeEntity(_0x2cdb1e,null))[_0x253f69('0x3b')](handleError(_0x2cdb1e,null));},exports[_0x2b51f4('0x68')]=function(_0x59d47b,_0x174b4d){const _0xb76ea4=_0x2b51f4;return db['OpenchannelQueue']['describe']()[_0xb76ea4('0xa')](respondWithResult(_0x174b4d,null))[_0xb76ea4('0x3b')](handleError(_0x174b4d,null));},exports[_0x2b51f4('0x4c')]=function(_0x55b4be,_0x317105){const _0x353120=_0x2b51f4;let _0xaba6e9={'raw':!![],'where':{}};const _0xbfb9c0={};let _0x262170;return db[_0x353120('0x1a')][_0x353120('0x50')]({'where':{'id':_0x55b4be[_0x353120('0x1')]['id']}})['then'](handleEntityNotFound(_0x317105,null))[_0x353120('0xa')](function(_0x3ddb14){const _0x41d35d=_0x353120;if(_0x3ddb14)return _0x262170=_0x3ddb14['get']({'plain':!![]}),_0xbfb9c0[_0x41d35d('0x3f')]=_['keys'](db[_0x41d35d('0x1d')]['rawAttributes']),_0xbfb9c0[_0x41d35d('0x19')]=_[_0x41d35d('0x5')](_0x55b4be[_0x41d35d('0x19')]),_0xbfb9c0[_0x41d35d('0x2d')]=_[_0x41d35d('0x35')](_0xbfb9c0[_0x41d35d('0x3f')],_0xbfb9c0[_0x41d35d('0x19')]),_0xaba6e9['attributes']=_['intersection'](_0xbfb9c0[_0x41d35d('0x3f')],qs['fields'](_0x55b4be[_0x41d35d('0x19')]['fields'])),_0xaba6e9[_0x41d35d('0x57')]=_0xaba6e9['attributes'][_0x41d35d('0x20')]?_0xaba6e9[_0x41d35d('0x57')]:_0xbfb9c0['model'],typeof _0x55b4be[_0x41d35d('0x19')][_0x41d35d('0xe')]===_0x41d35d('0x5e')&&(_0xaba6e9['limit']=qs['limit'](_0x55b4be[_0x41d35d('0x19')]['limit']),_0xaba6e9['offset']=qs[_0x41d35d('0x28')](_0x55b4be[_0x41d35d('0x19')][_0x41d35d('0x28')])),_0xaba6e9[_0x41d35d('0x5d')]=qs[_0x41d35d('0x66')](_0x55b4be[_0x41d35d('0x19')][_0x41d35d('0x66')]),_0xaba6e9[_0x41d35d('0x24')]=qs['filters'](_[_0x41d35d('0x4f')](_0x55b4be[_0x41d35d('0x19')],_0xbfb9c0['filters'])),_0xaba6e9[_0x41d35d('0x24')][_0x41d35d('0x39')]=_0x3ddb14['id'],_0x55b4be['query'][_0x41d35d('0x2e')]&&(_0xaba6e9[_0x41d35d('0x24')]=_[_0x41d35d('0xf')](_0xaba6e9[_0x41d35d('0x24')],{[Op['or']]:_[_0x41d35d('0x4a')](_0xaba6e9[_0x41d35d('0x57')],function(_0x450d48){const _0x4d4e28=_0x41d35d,_0x43c0a6={};return _0x43c0a6[_0x450d48]={[Op[_0x4d4e28('0x18')]]:'%'+_0x55b4be[_0x4d4e28('0x19')][_0x4d4e28('0x2e')]+'%'},_0x43c0a6;})})),_0xaba6e9=_[_0x41d35d('0xf')]({},_0xaba6e9,_0x55b4be[_0x41d35d('0x46')]),db[_0x41d35d('0x1d')][_0x41d35d('0x34')](_0xaba6e9);})[_0x353120('0xa')](function(_0x47e4ed){const _0x18267b=_0x353120;if(_0x47e4ed)return db[_0x18267b('0x51')][_0x18267b('0x56')]({'where':{'id':_[_0x18267b('0x4a')](_0x47e4ed,'UserId'),'role':'agent'},'attributes':['id',_0x18267b('0x49'),_0x18267b('0x62'),_0x18267b('0x47'),_0x18267b('0x58')]});})[_0x353120('0xa')](function(_0x3d3f18){const _0x2342f1=_0x353120;return _0x3d3f18?{'count':_0x3d3f18[_0x2342f1('0x2a')],'rows':_['map'](_0x3d3f18[_0x2342f1('0x5f')],function(_0x384cae){const _0x42da52=_0x2342f1;return{'membername':_0x384cae[_0x42da52('0x49')],'UserId':_0x384cae['id'],'queue_name':_0x262170['name'],'OpenchannelQueueId':_0x262170['id'],'interface':util[_0x42da52('0x4e')](_0x42da52('0x54'),_0x42da52('0x53'),_0x384cae['name']),'penalty':0x0,'paused':_0x384cae[_0x42da52('0x62')],'createdAt':_0x384cae[_0x42da52('0x58')],'updatedAt':_0x384cae['updatedAt']};})}:{'count':0x0,'rows':[]};})[_0x353120('0xa')](respondWithFilteredResult(_0x317105,_0xaba6e9))[_0x353120('0x3b')](handleError(_0x317105,null));},exports['getTeams']=function(_0xb7e884,_0x118b63){const _0x96beaf=_0x2b51f4;let _0x4fa60d={};const _0x2c94d4={};let _0x36b027,_0x5306c8;return db[_0x96beaf('0x1a')][_0x96beaf('0x50')]({'where':{'id':_0xb7e884[_0x96beaf('0x1')]['id']}})['then'](handleEntityNotFound(_0x118b63,null))[_0x96beaf('0xa')](function(_0x3465e5){const _0x294d4a=_0x96beaf;if(_0x3465e5)return _0x36b027=_0x3465e5,_0x2c94d4[_0x294d4a('0x3f')]=_['keys'](db[_0x294d4a('0x3c')][_0x294d4a('0x26')]),_0x2c94d4['query']=_[_0x294d4a('0x5')](_0xb7e884[_0x294d4a('0x19')]),_0x2c94d4[_0x294d4a('0x2d')]=_[_0x294d4a('0x35')](_0x2c94d4[_0x294d4a('0x3f')],_0x2c94d4[_0x294d4a('0x19')]),_0x4fa60d[_0x294d4a('0x57')]=_[_0x294d4a('0x35')](_0x2c94d4['model'],qs['fields'](_0xb7e884[_0x294d4a('0x19')]['fields'])),_0x4fa60d[_0x294d4a('0x57')]=_0x4fa60d['attributes'][_0x294d4a('0x20')]?_0x4fa60d[_0x294d4a('0x57')]:_0x2c94d4['model'],_0x4fa60d[_0x294d4a('0x5d')]=qs[_0x294d4a('0x66')](_0xb7e884[_0x294d4a('0x19')][_0x294d4a('0x66')]),_0x4fa60d['where']=qs[_0x294d4a('0x2d')](_[_0x294d4a('0x4f')](_0xb7e884['query'],_0x2c94d4['filters'])),_0xb7e884['query']['filter']&&(_0x4fa60d[_0x294d4a('0x24')]=_['merge'](_0x4fa60d[_0x294d4a('0x24')],{[Op['or']]:_[_0x294d4a('0x4a')](_0x4fa60d['attributes'],function(_0x566373){const _0x2c62eb=_0x294d4a,_0x18bb36={};return _0x18bb36[_0x566373]={[Op[_0x2c62eb('0x18')]]:'%'+_0xb7e884['query']['filter']+'%'},_0x18bb36;})})),_0x4fa60d=_[_0x294d4a('0xf')]({},_0x4fa60d,_0xb7e884[_0x294d4a('0x46')]),_0x36b027[_0x294d4a('0x6c')](_0x4fa60d);})[_0x96beaf('0xa')](function(_0x249a2c){const _0x232773=_0x96beaf;if(_0x249a2c)return _0x5306c8=_0x249a2c[_0x232773('0x20')],typeof _0xb7e884['query'][_0x232773('0xe')]===_0x232773('0x5e')&&(_0x4fa60d[_0x232773('0x2f')]=qs['limit'](_0xb7e884['query'][_0x232773('0x2f')]),_0x4fa60d['offset']=qs[_0x232773('0x28')](_0xb7e884[_0x232773('0x19')][_0x232773('0x28')])),_0x36b027[_0x232773('0x6c')](_0x4fa60d);})[_0x96beaf('0xa')](function(_0x319222){if(_0x319222)return _0x319222?{'count':_0x5306c8,'rows':_0x319222}:null;})[_0x96beaf('0xa')](respondWithResult(_0x118b63,null))['catch'](handleError(_0x118b63,null));},exports[_0x2b51f4('0x37')]=function(_0x2d2f10,_0xf3b573){const _0x253bb5=_0x2b51f4,_0x465a85=_0x2d2f10[_0x253bb5('0x29')][_0x253bb5('0x64')];return db[_0x253bb5('0x3c')][_0x253bb5('0x34')]({'where':{'id':_0x465a85},'attributes':['id'],'include':[{'model':db[_0x253bb5('0x51')],'as':_0x253bb5('0x42'),'attributes':['id',_0x253bb5('0x49'),_0x253bb5('0x69'),_0x253bb5('0x15'),_0x253bb5('0x25')],'raw':!![]}]})['then'](function(_0x4299d2){const _0x256feb=_0x253bb5;if(_0x4299d2){const _0x2b7009=_[_0x256feb('0x6d')](_0x4299d2,function(_0x51964e){const _0x432af4=_0x256feb,_0x141ec4=_0x51964e['get']({'plain':!![]});return _0x141ec4[_0x432af4('0x42')];});return db[_0x256feb('0x1a')][_0x256feb('0x50')]({'where':{'id':_0x2d2f10[_0x256feb('0x1')]['id']}})['then'](function(_0x1ef209){const _0x3d24a1=_0x256feb;return db[_0x3d24a1('0x2')][_0x3d24a1('0x6')](function(_0x1fa6ac){const _0x4acf12=_0x3d24a1;return _0x1ef209['addTeams'](_0x465a85,{'transaction':_0x1fa6ac})['then'](function(){return Promise['each'](_0x2b7009,function(_0x54ba8d){const _0xc2688e=a494_0x455c;return db[_0xc2688e('0x1d')][_0xc2688e('0x2b')]({'where':{'UserId':_0x54ba8d['id'],'OpenchannelQueueId':_0x2d2f10[_0xc2688e('0x1')]['id']},'transaction':_0x1fa6ac});});})[_0x4acf12('0xa')](function(){const _0xf5bc83=_0x4acf12;_0x2b7009[_0xf5bc83('0x23')](function(_0x3298f6){const _0x2b42ae=_0xf5bc83;socket[_0x2b42ae('0x4d')](_0x2b42ae('0x9'),{'UserId':_0x3298f6['id'],'OpenchannelQueueId':_0x1ef209['id']});});});});});}})[_0x253bb5('0xa')](respondWithStatusCode(_0xf3b573,null))[_0x253bb5('0x3b')](handleError(_0xf3b573,null));},exports[_0x2b51f4('0x6e')]=function(_0x4ec8ed,_0x4d6f0f){const _0x278bf3=_0x2b51f4;return db[_0x278bf3('0x3c')][_0x278bf3('0x34')]({'where':{'id':_0x4ec8ed[_0x278bf3('0x19')][_0x278bf3('0x64')]},'attributes':['id'],'include':[{'model':db['User'],'as':_0x278bf3('0x42'),'attributes':['id'],'raw':!![]}]})['then'](handleEntityNotFound(_0x4d6f0f,null))['then'](function(_0x4330f0){const _0x45cca2=_0x278bf3,_0x21a445=_[_0x45cca2('0x4a')](_0x4330f0,'id');let _0x231c44=[];const _0x33aa36=[],_0x2e26e9=squel[_0x45cca2('0x1f')]();_0x2e26e9['field']('tq.TeamId')[_0x45cca2('0x72')]('team_has_openchannel_queues','tq')['join'](_0x45cca2('0x6b'),'ut',_0x45cca2('0x14'))[_0x45cca2('0x24')](_0x45cca2('0x3'),_0x4ec8ed[_0x45cca2('0x1')]['id']);for(let _0x4b5659=0x0;_0x4b5659<_0x4330f0['length'];_0x4b5659+=0x1){const _0x3d8342=_0x4330f0[_0x4b5659];for(let _0x8c0ce8=0x0;_0x8c0ce8<_0x3d8342[_0x45cca2('0x42')]['length'];_0x8c0ce8+=0x1){const _0x2d734b=_0x3d8342['Agents'][_0x8c0ce8],_0x48fb27=_0x2e26e9[_0x45cca2('0x3a')]();_0x48fb27[_0x45cca2('0x24')](_0x45cca2('0x2c'),_0x2d734b['id']),_0x33aa36[_0x45cca2('0xc')](db['sequelize'][_0x45cca2('0x19')](_0x48fb27[_0x45cca2('0x33')](),{'type':QueryTypes[_0x45cca2('0x60')]})[_0x45cca2('0xa')](function(_0x2148fc){const _0x26f4c7=_0x45cca2;if(_0x2148fc[_0x26f4c7('0x20')]===0x1)return _0x2d734b['id'];else{const _0x19e349=_[_0x26f4c7('0x67')](_[_0x26f4c7('0x4a')](_0x2148fc,_0x26f4c7('0x70')),function(_0x38b386){const _0x324d51=_0x26f4c7;return _[_0x324d51('0x71')](_0x21a445,_0x38b386);});if(_0x19e349)return _0x2d734b['id'];}}));}}return Promise[_0x45cca2('0x8')](_0x33aa36)['then'](function(_0xa91ba3){const _0x56951d=_0x45cca2;return _0x231c44=_(_0x231c44)[_0x56951d('0x3e')](_0xa91ba3)[_0x56951d('0x5b')]()['value'](),db[_0x56951d('0x1a')][_0x56951d('0x50')]({'where':{'id':_0x4ec8ed[_0x56951d('0x1')]['id']}})[_0x56951d('0xa')](function(_0x2f034d){const _0x597f50=_0x56951d;return db[_0x597f50('0x2')][_0x597f50('0x6')](function(_0x330799){const _0x2bf42f=_0x597f50;return _0x2f034d[_0x2bf42f('0x6e')](_0x4ec8ed['query'][_0x2bf42f('0x64')],{'transaction':_0x330799})[_0x2bf42f('0xa')](function(){const _0x1792cf=_0x2bf42f;if(!_[_0x1792cf('0x65')](_0x231c44))return _0x2f034d[_0x1792cf('0x1c')](_0x231c44,{'transaction':_0x330799});})['then'](function(){const _0x3c2b50=_0x2bf42f;_0x231c44[_0x3c2b50('0x23')](function(_0x391567){const _0x594d74=_0x3c2b50;socket[_0x594d74('0x4d')]('userOpenchannelQueue:remove',{'UserId':_0x391567,'OpenchannelQueueId':_0x2f034d['id']});});});});});});})[_0x278bf3('0xa')](respondWithStatusCode(_0x4d6f0f,null))[_0x278bf3('0x3b')](handleError(_0x4d6f0f,null));},exports[_0x2b51f4('0x13')]=function(_0x7c37f3,_0x1216e5){const _0x3b9d40=_0x2b51f4;return db[_0x3b9d40('0x1a')][_0x3b9d40('0x50')]({'where':{'id':_0x7c37f3[_0x3b9d40('0x1')]['id']}})['then'](function(_0x3448ec){const _0x1b97e3=_0x3b9d40;if(_0x3448ec)return _0x3448ec[_0x1b97e3('0x13')](_0x7c37f3[_0x1b97e3('0x29')][_0x1b97e3('0x64')],{'through':_[_0x1b97e3('0x52')](_0x7c37f3[_0x1b97e3('0x29')],['ids','id'])})[_0x1b97e3('0xa')](function(_0x179d17){const _0x449dcb=_0x1b97e3;for(let _0xe71e65=0x0;_0xe71e65<_0x7c37f3['body'][_0x449dcb('0x64')][_0x449dcb('0x20')];_0xe71e65+=0x1){socket[_0x449dcb('0x4d')](_0x449dcb('0x9'),{'UserId':_0x7c37f3[_0x449dcb('0x29')][_0x449dcb('0x64')][_0xe71e65],'OpenchannelQueueId':_0x7c37f3[_0x449dcb('0x1')]['id']});}return _0x179d17;});})[_0x3b9d40('0xa')](respondWithResult(_0x1216e5,null))[_0x3b9d40('0x3b')](handleError(_0x1216e5,null));},exports['removeAgents']=function(_0x566b6c,_0x54f8fe){const _0x321378=_0x2b51f4;return db[_0x321378('0x1a')]['findOne']({'where':{'id':_0x566b6c[_0x321378('0x1')]['id']}})[_0x321378('0xa')](handleEntityNotFound(_0x54f8fe,null))[_0x321378('0xa')](function(_0x5b6dba){const _0x3a5dbf=_0x321378;if(_0x5b6dba)return _0x5b6dba[_0x3a5dbf('0x1c')](_0x566b6c['query'][_0x3a5dbf('0x64')])['then'](function(){const _0x1cb492=_0x3a5dbf;if(_[_0x1cb492('0x10')](_0x566b6c[_0x1cb492('0x19')][_0x1cb492('0x64')]))for(let _0x165ced=0x0;_0x165ced<_0x566b6c['query']['ids']['length'];_0x165ced+=0x1){socket['emit'](_0x1cb492('0x59'),{'UserId':Number(_0x566b6c[_0x1cb492('0x19')][_0x1cb492('0x64')][_0x165ced]),'OpenchannelQueueId':Number(_0x566b6c[_0x1cb492('0x1')]['id'])});}else socket['emit'](_0x1cb492('0x59'),{'UserId':Number(_0x566b6c['query']['ids']),'OpenchannelQueueId':Number(_0x566b6c['params']['id'])});});})[_0x321378('0xa')](respondWithStatusCode(_0x54f8fe,null))[_0x321378('0x3b')](handleError(_0x54f8fe,null));},exports[_0x2b51f4('0x32')]=function(_0xc96148,_0x50ed90){const _0x1e6fa0=_0x2b51f4;let _0x544de6={};const _0x4dfc4b={};let _0xfd2d44,_0x334890;return db[_0x1e6fa0('0x1a')][_0x1e6fa0('0x50')]({'where':{'id':_0xc96148['params']['id']}})[_0x1e6fa0('0xa')](handleEntityNotFound(_0x50ed90,null))[_0x1e6fa0('0xa')](function(_0x18e1bf){const _0x4f93b5=_0x1e6fa0;if(_0x18e1bf)return _0xfd2d44=_0x18e1bf,_0x4dfc4b['model']=_[_0x4f93b5('0x5')](db[_0x4f93b5('0x51')][_0x4f93b5('0x26')]),_0x4dfc4b['query']=_[_0x4f93b5('0x5')](_0xc96148[_0x4f93b5('0x19')]),_0x4dfc4b[_0x4f93b5('0x2d')]=_[_0x4f93b5('0x35')](_0x4dfc4b['model'],_0x4dfc4b[_0x4f93b5('0x19')]),_0x544de6[_0x4f93b5('0x57')]=_[_0x4f93b5('0x35')](_0x4dfc4b[_0x4f93b5('0x3f')],qs[_0x4f93b5('0x5a')](_0xc96148[_0x4f93b5('0x19')][_0x4f93b5('0x5a')])),_0x544de6['attributes']=_0x544de6[_0x4f93b5('0x57')][_0x4f93b5('0x20')]?_0x544de6[_0x4f93b5('0x57')]:_0x4dfc4b[_0x4f93b5('0x3f')],_0x544de6[_0x4f93b5('0x5d')]=qs[_0x4f93b5('0x66')](_0xc96148[_0x4f93b5('0x19')]['sort']),_0x544de6['where']=qs[_0x4f93b5('0x2d')](_[_0x4f93b5('0x4f')](_0xc96148[_0x4f93b5('0x19')],_0x4dfc4b[_0x4f93b5('0x2d')])),_0xc96148[_0x4f93b5('0x19')]['filter']&&(_0x544de6['where']=_[_0x4f93b5('0xf')](_0x544de6[_0x4f93b5('0x24')],{[Op['or']]:_['map'](_0x544de6[_0x4f93b5('0x57')],function(_0x26320a){const _0x46a32d=_0x4f93b5,_0x11c6d9={};return _0x11c6d9[_0x26320a]={[Op[_0x46a32d('0x18')]]:'%'+_0xc96148[_0x46a32d('0x19')]['filter']+'%'},_0x11c6d9;})})),_0x544de6=_[_0x4f93b5('0xf')]({},_0x544de6,_0xc96148[_0x4f93b5('0x46')]),_0xfd2d44[_0x4f93b5('0x32')](_0x544de6);})['then'](function(_0x17183b){const _0x238ea0=_0x1e6fa0;if(_0x17183b)return _0x334890=_0x17183b[_0x238ea0('0x20')],typeof _0xc96148['query']['nolimit']==='undefined'&&(_0x544de6[_0x238ea0('0x2f')]=qs[_0x238ea0('0x2f')](_0xc96148[_0x238ea0('0x19')][_0x238ea0('0x2f')]),_0x544de6[_0x238ea0('0x28')]=qs[_0x238ea0('0x28')](_0xc96148[_0x238ea0('0x19')][_0x238ea0('0x28')])),_0xfd2d44['getAgents'](_0x544de6);})[_0x1e6fa0('0xa')](function(_0x300244){if(_0x300244)return _0x300244?{'count':_0x334890,'rows':_0x300244}:null;})[_0x1e6fa0('0xa')](respondWithResult(_0x50ed90,null))[_0x1e6fa0('0x3b')](handleError(_0x50ed90,null));}; \ No newline at end of file +const a494_0x2304=['UserId','sendStatus','model','type','value','keys','clone','findAll','name','all','key','addAgents','index','UserProfileResource','join','catch','offset','nolimit','isArray','TeamId','set','%s/%s','Agents','get','ut.TeamId\x20=\x20tq.TeamId','userOpenchannelQueue:save','role','json','transaction','status','util','voicePause','OpenchannelQueueId','user','undefined','SELECT','OpenchannelQueue','includes','options','ut.UserId\x20=\x20?','emit','limit','merge','body','./openchannelQueue.socket','toString','findAndCountAll','like','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','sort','OpenchannelQueueId\x20=\x20?','format','sequelize','../../mysqldb','order','autoAssociation','UserProfileSection','UserOpenchannelQueue','fields','then','createdAt','tq.TeamId','addTeams','VIRTUAL','destroy','api','Team','field','findOne','include','user_has_teams','interface','update','fieldName','SIP','updatedAt','agent','online','isEmpty','lodash','userProfileId','intersection','Unable\x20to\x20retrieve\x20the\x20current\x20user','includeAll','each','describe','query','../../components/parsers/qs','create','push','attributes','openchannelPause','squel','register','filters','params','where','rows','pick','ids','map','count','omit','getTeams','length','User','removeTeams','getAgents','Content-Range','rawAttributes','userOpenchannelQueue:remove','removeAgents','filter','end','forEach','every'];(function(_0x1c03df,_0x2304f8){const _0x5049e3=function(_0x3fd220){while(--_0x3fd220){_0x1c03df['push'](_0x1c03df['shift']());}};_0x5049e3(++_0x2304f8);}(a494_0x2304,0x18d));const a494_0x5049=function(_0x1c03df,_0x2304f8){_0x1c03df=_0x1c03df-0x0;let _0x5049e3=a494_0x2304[_0x1c03df];return _0x5049e3;};const _0x571e20=a494_0x5049;'use strict';const util=require(_0x571e20('0x61')),_=require(_0x571e20('0x1e')),squel=require(_0x571e20('0x2b')),qs=require(_0x571e20('0x26')),logger=require('../../config/logger')(_0x571e20('0x10')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x571e20('0x4'))['db'],{Op,QueryTypes}=require('sequelize');require(_0x571e20('0x6f'))[_0x571e20('0x2c')](socket);function respondWithStatusCode(_0x3fd220,_0x375571){return _0x375571=_0x375571||0xcc,function(_0x1344ab){const _0x5e1b66=a494_0x5049;if(_0x1344ab)return _0x3fd220[_0x5e1b66('0x44')](_0x375571);return _0x3fd220[_0x5e1b66('0x60')](_0x375571)[_0x5e1b66('0x40')]();};}function respondWithResult(_0x4746c7,_0x3bff62){return _0x3bff62=_0x3bff62||0xc8,function(_0x303a69){const _0x10e6e1=a494_0x5049;if(_0x303a69)return _0x4746c7[_0x10e6e1('0x60')](_0x3bff62)[_0x10e6e1('0x5e')](_0x303a69);};}function respondWithFilteredResult(_0x2a8ea0,_0x111576){return function(_0x3d0447){const _0x3270a1=a494_0x5049;if(_0x3d0447){const _0xf8de3e=_0x3d0447[_0x3270a1('0x34')],_0x1855d5=_0x111576['offset'];let _0x478823=_0x111576[_0x3270a1('0x53')]+_0x111576[_0x3270a1('0x6c')],_0x4512bc;return _0x478823>=_0xf8de3e?(_0x478823=_0xf8de3e,_0x4512bc=0xc8):_0x4512bc=0xce,_0x2a8ea0[_0x3270a1('0x60')](_0x4512bc),_0x2a8ea0[_0x3270a1('0x57')](_0x3270a1('0x3b'),_0x1855d5+'-'+_0x478823+'/'+_0xf8de3e)['json'](_0x3d0447);}return null;};}function saveUpdates(_0x305910){return function(_0x573c38){const _0xf0a207=a494_0x5049;if(_0x573c38)return _0x573c38[_0xf0a207('0x17')](_0x305910)[_0xf0a207('0xa')](function(_0x57f47f){return _0x57f47f;});return null;};}function removeEntity(_0x3d2081){return function(_0x524413){const _0x488a7b=a494_0x5049;if(_0x524413)return _0x524413[_0x488a7b('0xf')]()['then'](function(){const _0x57fc8e=_0x488a7b,_0x3d3eb6=_0x524413[_0x57fc8e('0x5a')]({'plain':!![]}),_0x256066='OpenchannelQueues';return db[_0x57fc8e('0x50')][_0x57fc8e('0xf')]({'where':{'type':_0x256066,'resourceId':_0x3d3eb6['id']}})['then'](function(){return _0x524413;});})[_0x488a7b('0xa')](function(){const _0x902917=_0x488a7b;_0x3d2081[_0x902917('0x60')](0xcc)[_0x902917('0x40')]();});};}function handleEntityNotFound(_0x221ab6){return function(_0x2081b4){const _0x17e93a=a494_0x5049;return!_0x2081b4&&_0x221ab6[_0x17e93a('0x44')](0x194),_0x2081b4;};}function handleError(_0x3bbb6a,_0x5dc6b0){return _0x5dc6b0=_0x5dc6b0||0x1f4,function(_0x32b2b1){const _0x3d2c83=a494_0x5049;logger['error'](_0x32b2b1['stack']),_0x32b2b1[_0x3d2c83('0x4b')]&&delete _0x32b2b1[_0x3d2c83('0x4b')],_0x3bbb6a[_0x3d2c83('0x60')](_0x5dc6b0)['send'](_0x32b2b1);};}exports[_0x571e20('0x4f')]=function(_0xd6cd52,_0x55b606){const _0x13b2ef=_0x571e20;let _0xde5f01={};const _0x1f4e9a={},_0x972f52={'count':0x0,'rows':[]},_0x24b224=_[_0x13b2ef('0x33')](db['OpenchannelQueue'][_0x13b2ef('0x3c')],function(_0x155bea){const _0x5d4072=_0x13b2ef;return{'name':_0x155bea[_0x5d4072('0x18')],'type':_0x155bea['type'][_0x5d4072('0x4d')]};});_0x1f4e9a['model']=_[_0x13b2ef('0x33')](_0x24b224,_0x13b2ef('0x4b')),_0x1f4e9a['query']=_[_0x13b2ef('0x48')](_0xd6cd52[_0x13b2ef('0x25')]),_0x1f4e9a['filters']=_[_0x13b2ef('0x20')](_0x1f4e9a[_0x13b2ef('0x45')],_0x1f4e9a['query']),_0xde5f01['attributes']=_[_0x13b2ef('0x20')](_0x1f4e9a[_0x13b2ef('0x45')],qs[_0x13b2ef('0x9')](_0xd6cd52[_0x13b2ef('0x25')][_0x13b2ef('0x9')])),_0xde5f01[_0x13b2ef('0x29')]=_0xde5f01['attributes'][_0x13b2ef('0x37')]?_0xde5f01[_0x13b2ef('0x29')]:_0x1f4e9a[_0x13b2ef('0x45')];typeof _0xd6cd52['query'][_0x13b2ef('0x54')]===_0x13b2ef('0x65')&&(_0xde5f01['limit']=qs[_0x13b2ef('0x6c')](_0xd6cd52['query']['limit']),_0xde5f01[_0x13b2ef('0x53')]=qs[_0x13b2ef('0x53')](_0xd6cd52[_0x13b2ef('0x25')][_0x13b2ef('0x53')]));_0xde5f01[_0x13b2ef('0x5')]=qs['sort'](_0xd6cd52['query'][_0x13b2ef('0x0')]),_0xde5f01['where']=qs[_0x13b2ef('0x2d')](_[_0x13b2ef('0x31')](_0xd6cd52['query'],_0x1f4e9a[_0x13b2ef('0x2d')]),_0x24b224);_0xd6cd52[_0x13b2ef('0x25')]['filter']&&(_0xde5f01[_0x13b2ef('0x2f')]=_[_0x13b2ef('0x6d')](_0xde5f01[_0x13b2ef('0x2f')],{[Op['or']]:_[_0x13b2ef('0x33')](_0x24b224,function(_0xd4447a){const _0x51450a=_0x13b2ef;if(_0xd4447a[_0x51450a('0x46')]!==_0x51450a('0xe')){const _0x4aa4f4={};return _0x4aa4f4[_0xd4447a['name']]={[Op[_0x51450a('0x72')]]:'%'+_0xd6cd52[_0x51450a('0x25')][_0x51450a('0x3f')]+'%'},_0x4aa4f4;}})}));_0xde5f01=_[_0x13b2ef('0x6d')]({},_0xde5f01,_0xd6cd52[_0x13b2ef('0x69')]);const _0x52d29a={'where':_0xde5f01[_0x13b2ef('0x2f')]};return db['OpenchannelQueue'][_0x13b2ef('0x34')](_0x52d29a)[_0x13b2ef('0xa')](function(_0xda2e8a){const _0x4c09ca=_0x13b2ef;return _0x972f52[_0x4c09ca('0x34')]=_0xda2e8a,_0xd6cd52[_0x4c09ca('0x25')][_0x4c09ca('0x22')]&&(_0xde5f01[_0x4c09ca('0x14')]=[{'all':!![]}]),db[_0x4c09ca('0x67')][_0x4c09ca('0x4a')](_0xde5f01);})[_0x13b2ef('0xa')](function(_0x44505f){return _0x972f52['rows']=_0x44505f,_0x972f52;})[_0x13b2ef('0xa')](respondWithFilteredResult(_0x55b606,_0xde5f01))[_0x13b2ef('0x52')](handleError(_0x55b606,null));},exports['show']=function(_0x2e3f45,_0x233dc9){const _0xfe08bf=_0x571e20;let _0x757a24={'raw':!![],'where':{'id':_0x2e3f45[_0xfe08bf('0x2e')]['id']}};const _0x5cda8d={};return _0x5cda8d[_0xfe08bf('0x45')]=_[_0xfe08bf('0x48')](db[_0xfe08bf('0x67')]['rawAttributes']),_0x5cda8d[_0xfe08bf('0x25')]=_['keys'](_0x2e3f45[_0xfe08bf('0x25')]),_0x5cda8d[_0xfe08bf('0x2d')]=_[_0xfe08bf('0x20')](_0x5cda8d[_0xfe08bf('0x45')],_0x5cda8d['query']),_0x757a24[_0xfe08bf('0x29')]=_[_0xfe08bf('0x20')](_0x5cda8d[_0xfe08bf('0x45')],qs['fields'](_0x2e3f45[_0xfe08bf('0x25')]['fields'])),_0x757a24[_0xfe08bf('0x29')]=_0x757a24[_0xfe08bf('0x29')]['length']?_0x757a24[_0xfe08bf('0x29')]:_0x5cda8d[_0xfe08bf('0x45')],_0x2e3f45[_0xfe08bf('0x25')][_0xfe08bf('0x22')]&&(_0x757a24[_0xfe08bf('0x14')]=[{'all':!![]}]),_0x757a24=_[_0xfe08bf('0x6d')]({},_0x757a24,_0x2e3f45[_0xfe08bf('0x69')]),db[_0xfe08bf('0x67')][_0xfe08bf('0x13')](_0x757a24)['then'](handleEntityNotFound(_0x233dc9,null))[_0xfe08bf('0xa')](respondWithResult(_0x233dc9,null))[_0xfe08bf('0x52')](handleError(_0x233dc9,null));},exports[_0x571e20('0x27')]=function(_0x328a41,_0x5c75bb){const _0x41cb9c=_0x571e20;return db[_0x41cb9c('0x67')]['create'](_0x328a41['body'],{})[_0x41cb9c('0xa')](function(_0x3e8dab){const _0x55d092=_0x41cb9c,_0xcf1049=_0x328a41[_0x55d092('0x64')]['get']({'plain':!![]});if(!_0xcf1049)throw new Error(_0x55d092('0x21'));if(_0xcf1049[_0x55d092('0x5d')]===_0x55d092('0x64')){const _0x5ea59d=_0x3e8dab[_0x55d092('0x5a')]({'plain':!![]}),_0x1ca2d9='OpenchannelQueues';return db[_0x55d092('0x7')]['findOne']({'where':{'name':_0x1ca2d9,'userProfileId':_0xcf1049[_0x55d092('0x1f')]},'raw':!![]})[_0x55d092('0xa')](function(_0x14a7ce){const _0x417229=_0x55d092;return _0x14a7ce&&_0x14a7ce[_0x417229('0x6')]===0x0?db['UserProfileResource']['create']({'name':_0x5ea59d['name'],'resourceId':_0x5ea59d['id'],'type':_0x14a7ce[_0x417229('0x4b')],'sectionId':_0x14a7ce['id']},{})[_0x417229('0xa')](function(){return _0x3e8dab;}):_0x3e8dab;})[_0x55d092('0x52')](function(_0x3b3587){const _0x4402cd=_0x55d092;logger['error'](_0x4402cd('0x73'),_0x3b3587);throw _0x3b3587;});}return _0x3e8dab;})[_0x41cb9c('0xa')](respondWithResult(_0x5c75bb,0xc9))[_0x41cb9c('0x52')](handleError(_0x5c75bb,null));},exports['update']=function(_0x5b40e3,_0x3ca858){const _0x2e65ca=_0x571e20;return _0x5b40e3[_0x2e65ca('0x6e')]['id']&&delete _0x5b40e3[_0x2e65ca('0x6e')]['id'],db[_0x2e65ca('0x67')][_0x2e65ca('0x13')]({'where':{'id':_0x5b40e3[_0x2e65ca('0x2e')]['id']}})[_0x2e65ca('0xa')](handleEntityNotFound(_0x3ca858,null))['then'](saveUpdates(_0x5b40e3[_0x2e65ca('0x6e')],null))[_0x2e65ca('0xa')](respondWithResult(_0x3ca858,null))['catch'](handleError(_0x3ca858,null));},exports[_0x571e20('0xf')]=function(_0x557a0f,_0x2bd935){const _0x102b48=_0x571e20;return db[_0x102b48('0x67')][_0x102b48('0x13')]({'where':{'id':_0x557a0f['params']['id']}})['then'](handleEntityNotFound(_0x2bd935,null))[_0x102b48('0xa')](removeEntity(_0x2bd935,null))[_0x102b48('0x52')](handleError(_0x2bd935,null));},exports[_0x571e20('0x24')]=function(_0x2ca8ad,_0x21d047){const _0x15a5c6=_0x571e20;return db[_0x15a5c6('0x67')][_0x15a5c6('0x24')]()[_0x15a5c6('0xa')](respondWithResult(_0x21d047,null))['catch'](handleError(_0x21d047,null));},exports['getMembers']=function(_0x26b428,_0x3af1ec){const _0x2ef6a6=_0x571e20;let _0x2f15d6={'raw':!![],'where':{}};const _0x194331={};let _0x3a5868;return db['OpenchannelQueue'][_0x2ef6a6('0x13')]({'where':{'id':_0x26b428[_0x2ef6a6('0x2e')]['id']}})[_0x2ef6a6('0xa')](handleEntityNotFound(_0x3af1ec,null))[_0x2ef6a6('0xa')](function(_0x1f4e96){const _0x3e0ccd=_0x2ef6a6;if(_0x1f4e96)return _0x3a5868=_0x1f4e96[_0x3e0ccd('0x5a')]({'plain':!![]}),_0x194331[_0x3e0ccd('0x45')]=_[_0x3e0ccd('0x48')](db['UserOpenchannelQueue'][_0x3e0ccd('0x3c')]),_0x194331[_0x3e0ccd('0x25')]=_[_0x3e0ccd('0x48')](_0x26b428[_0x3e0ccd('0x25')]),_0x194331[_0x3e0ccd('0x2d')]=_[_0x3e0ccd('0x20')](_0x194331[_0x3e0ccd('0x45')],_0x194331[_0x3e0ccd('0x25')]),_0x2f15d6[_0x3e0ccd('0x29')]=_[_0x3e0ccd('0x20')](_0x194331['model'],qs['fields'](_0x26b428[_0x3e0ccd('0x25')][_0x3e0ccd('0x9')])),_0x2f15d6[_0x3e0ccd('0x29')]=_0x2f15d6['attributes'][_0x3e0ccd('0x37')]?_0x2f15d6[_0x3e0ccd('0x29')]:_0x194331[_0x3e0ccd('0x45')],typeof _0x26b428[_0x3e0ccd('0x25')]['nolimit']===_0x3e0ccd('0x65')&&(_0x2f15d6[_0x3e0ccd('0x6c')]=qs[_0x3e0ccd('0x6c')](_0x26b428['query'][_0x3e0ccd('0x6c')]),_0x2f15d6[_0x3e0ccd('0x53')]=qs[_0x3e0ccd('0x53')](_0x26b428[_0x3e0ccd('0x25')][_0x3e0ccd('0x53')])),_0x2f15d6[_0x3e0ccd('0x5')]=qs[_0x3e0ccd('0x0')](_0x26b428[_0x3e0ccd('0x25')][_0x3e0ccd('0x0')]),_0x2f15d6['where']=qs['filters'](_['pick'](_0x26b428['query'],_0x194331[_0x3e0ccd('0x2d')])),_0x2f15d6[_0x3e0ccd('0x2f')][_0x3e0ccd('0x63')]=_0x1f4e96['id'],_0x26b428[_0x3e0ccd('0x25')]['filter']&&(_0x2f15d6[_0x3e0ccd('0x2f')]=_[_0x3e0ccd('0x6d')](_0x2f15d6[_0x3e0ccd('0x2f')],{[Op['or']]:_['map'](_0x2f15d6['attributes'],function(_0x13cc99){const _0x4d7e99=_0x3e0ccd,_0x547193={};return _0x547193[_0x13cc99]={[Op['like']]:'%'+_0x26b428[_0x4d7e99('0x25')][_0x4d7e99('0x3f')]+'%'},_0x547193;})})),_0x2f15d6=_['merge']({},_0x2f15d6,_0x26b428[_0x3e0ccd('0x69')]),db['UserOpenchannelQueue']['findAll'](_0x2f15d6);})[_0x2ef6a6('0xa')](function(_0x3ee0b3){const _0xbbb2c=_0x2ef6a6;if(_0x3ee0b3)return db['User'][_0xbbb2c('0x71')]({'where':{'id':_['map'](_0x3ee0b3,_0xbbb2c('0x43')),'role':_0xbbb2c('0x1b')},'attributes':['id',_0xbbb2c('0x4b'),_0xbbb2c('0x2a'),_0xbbb2c('0x1a'),_0xbbb2c('0xb')]});})[_0x2ef6a6('0xa')](function(_0x3dd604){const _0x4cae08=_0x2ef6a6;return _0x3dd604?{'count':_0x3dd604['count'],'rows':_[_0x4cae08('0x33')](_0x3dd604[_0x4cae08('0x30')],function(_0x208c31){const _0x2dbe4b=_0x4cae08;return{'membername':_0x208c31[_0x2dbe4b('0x4b')],'UserId':_0x208c31['id'],'queue_name':_0x3a5868[_0x2dbe4b('0x4b')],'OpenchannelQueueId':_0x3a5868['id'],'interface':util[_0x2dbe4b('0x2')](_0x2dbe4b('0x58'),_0x2dbe4b('0x19'),_0x208c31[_0x2dbe4b('0x4b')]),'penalty':0x0,'paused':_0x208c31[_0x2dbe4b('0x2a')],'createdAt':_0x208c31['createdAt'],'updatedAt':_0x208c31['updatedAt']};})}:{'count':0x0,'rows':[]};})[_0x2ef6a6('0xa')](respondWithFilteredResult(_0x3af1ec,_0x2f15d6))[_0x2ef6a6('0x52')](handleError(_0x3af1ec,null));},exports['getTeams']=function(_0x599be9,_0x9bc87){const _0x85ddfb=_0x571e20;let _0x48c9a7={};const _0x5dbfe8={};let _0x22a481,_0x52bffb;return db[_0x85ddfb('0x67')][_0x85ddfb('0x13')]({'where':{'id':_0x599be9['params']['id']}})['then'](handleEntityNotFound(_0x9bc87,null))['then'](function(_0x55e93b){const _0x18cb5f=_0x85ddfb;if(_0x55e93b)return _0x22a481=_0x55e93b,_0x5dbfe8[_0x18cb5f('0x45')]=_[_0x18cb5f('0x48')](db[_0x18cb5f('0x11')]['rawAttributes']),_0x5dbfe8[_0x18cb5f('0x25')]=_[_0x18cb5f('0x48')](_0x599be9[_0x18cb5f('0x25')]),_0x5dbfe8['filters']=_[_0x18cb5f('0x20')](_0x5dbfe8[_0x18cb5f('0x45')],_0x5dbfe8['query']),_0x48c9a7[_0x18cb5f('0x29')]=_[_0x18cb5f('0x20')](_0x5dbfe8[_0x18cb5f('0x45')],qs[_0x18cb5f('0x9')](_0x599be9['query'][_0x18cb5f('0x9')])),_0x48c9a7['attributes']=_0x48c9a7[_0x18cb5f('0x29')]['length']?_0x48c9a7[_0x18cb5f('0x29')]:_0x5dbfe8[_0x18cb5f('0x45')],_0x48c9a7[_0x18cb5f('0x5')]=qs[_0x18cb5f('0x0')](_0x599be9['query']['sort']),_0x48c9a7[_0x18cb5f('0x2f')]=qs[_0x18cb5f('0x2d')](_[_0x18cb5f('0x31')](_0x599be9[_0x18cb5f('0x25')],_0x5dbfe8[_0x18cb5f('0x2d')])),_0x599be9[_0x18cb5f('0x25')][_0x18cb5f('0x3f')]&&(_0x48c9a7['where']=_[_0x18cb5f('0x6d')](_0x48c9a7[_0x18cb5f('0x2f')],{[Op['or']]:_[_0x18cb5f('0x33')](_0x48c9a7[_0x18cb5f('0x29')],function(_0x38708b){const _0xff15eb=_0x18cb5f,_0x54e063={};return _0x54e063[_0x38708b]={[Op[_0xff15eb('0x72')]]:'%'+_0x599be9[_0xff15eb('0x25')][_0xff15eb('0x3f')]+'%'},_0x54e063;})})),_0x48c9a7=_['merge']({},_0x48c9a7,_0x599be9['options']),_0x22a481[_0x18cb5f('0x36')](_0x48c9a7);})[_0x85ddfb('0xa')](function(_0x31448a){const _0x569025=_0x85ddfb;if(_0x31448a)return _0x52bffb=_0x31448a[_0x569025('0x37')],typeof _0x599be9[_0x569025('0x25')][_0x569025('0x54')]===_0x569025('0x65')&&(_0x48c9a7[_0x569025('0x6c')]=qs[_0x569025('0x6c')](_0x599be9[_0x569025('0x25')][_0x569025('0x6c')]),_0x48c9a7['offset']=qs[_0x569025('0x53')](_0x599be9[_0x569025('0x25')][_0x569025('0x53')])),_0x22a481[_0x569025('0x36')](_0x48c9a7);})[_0x85ddfb('0xa')](function(_0x4b73ce){if(_0x4b73ce)return _0x4b73ce?{'count':_0x52bffb,'rows':_0x4b73ce}:null;})[_0x85ddfb('0xa')](respondWithResult(_0x9bc87,null))['catch'](handleError(_0x9bc87,null));},exports[_0x571e20('0xd')]=function(_0x337cc7,_0x55de0c){const _0x1ccbad=_0x571e20,_0x228285=_0x337cc7['body']['ids'];return db[_0x1ccbad('0x11')]['findAll']({'where':{'id':_0x228285},'attributes':['id'],'include':[{'model':db['User'],'as':_0x1ccbad('0x59'),'attributes':['id',_0x1ccbad('0x4b'),_0x1ccbad('0x1c'),_0x1ccbad('0x62'),_0x1ccbad('0x16')],'raw':!![]}]})['then'](function(_0x22c6b2){const _0x530aeb=_0x1ccbad;if(_0x22c6b2){const _0x2d0dbe=_['flatMap'](_0x22c6b2,function(_0x539f60){const _0x2f0cc4=a494_0x5049,_0xf9584b=_0x539f60[_0x2f0cc4('0x5a')]({'plain':!![]});return _0xf9584b[_0x2f0cc4('0x59')];});return db[_0x530aeb('0x67')][_0x530aeb('0x13')]({'where':{'id':_0x337cc7[_0x530aeb('0x2e')]['id']}})['then'](function(_0x402290){const _0x5aef28=_0x530aeb;return db['sequelize'][_0x5aef28('0x5f')](function(_0x27ceb3){const _0x149629=_0x5aef28;return _0x402290[_0x149629('0xd')](_0x228285,{'transaction':_0x27ceb3})[_0x149629('0xa')](function(){const _0x485821=_0x149629;return Promise[_0x485821('0x23')](_0x2d0dbe,function(_0x590cf2){const _0x42610b=_0x485821;return db[_0x42610b('0x8')]['findOrCreate']({'where':{'UserId':_0x590cf2['id'],'OpenchannelQueueId':_0x337cc7[_0x42610b('0x2e')]['id']},'transaction':_0x27ceb3});});})[_0x149629('0xa')](function(){_0x2d0dbe['forEach'](function(_0x56eee4){const _0x5b5a5d=a494_0x5049;socket[_0x5b5a5d('0x6b')](_0x5b5a5d('0x5c'),{'UserId':_0x56eee4['id'],'OpenchannelQueueId':_0x402290['id']});});});});});}})['then'](respondWithStatusCode(_0x55de0c,null))[_0x1ccbad('0x52')](handleError(_0x55de0c,null));},exports[_0x571e20('0x39')]=function(_0x117762,_0x21f042){const _0x43b42f=_0x571e20;return db[_0x43b42f('0x11')][_0x43b42f('0x4a')]({'where':{'id':_0x117762[_0x43b42f('0x25')]['ids']},'attributes':['id'],'include':[{'model':db[_0x43b42f('0x38')],'as':_0x43b42f('0x59'),'attributes':['id'],'raw':!![]}]})[_0x43b42f('0xa')](handleEntityNotFound(_0x21f042,null))['then'](function(_0x47a235){const _0x3a59ee=_0x43b42f,_0xf9392f=_[_0x3a59ee('0x33')](_0x47a235,'id');let _0x3e4eae=[];const _0xb63baf=[],_0x20dfc1=squel['select']();_0x20dfc1[_0x3a59ee('0x12')](_0x3a59ee('0xc'))['from']('team_has_openchannel_queues','tq')[_0x3a59ee('0x51')](_0x3a59ee('0x15'),'ut',_0x3a59ee('0x5b'))[_0x3a59ee('0x2f')](_0x3a59ee('0x1'),_0x117762['params']['id']);for(let _0xd8034d=0x0;_0xd8034d<_0x47a235[_0x3a59ee('0x37')];_0xd8034d+=0x1){const _0x36f440=_0x47a235[_0xd8034d];for(let _0x4f025f=0x0;_0x4f025f<_0x36f440[_0x3a59ee('0x59')]['length'];_0x4f025f+=0x1){const _0x389856=_0x36f440[_0x3a59ee('0x59')][_0x4f025f],_0x3d9639=_0x20dfc1[_0x3a59ee('0x49')]();_0x3d9639[_0x3a59ee('0x2f')](_0x3a59ee('0x6a'),_0x389856['id']),_0xb63baf[_0x3a59ee('0x28')](db[_0x3a59ee('0x3')]['query'](_0x3d9639[_0x3a59ee('0x70')](),{'type':QueryTypes[_0x3a59ee('0x66')]})[_0x3a59ee('0xa')](function(_0x2271a2){const _0x5a57ec=_0x3a59ee;if(_0x2271a2[_0x5a57ec('0x37')]===0x1)return _0x389856['id'];else{const _0x5b056f=_[_0x5a57ec('0x42')](_['map'](_0x2271a2,_0x5a57ec('0x56')),function(_0x56b6c2){const _0x2e4e0f=_0x5a57ec;return _[_0x2e4e0f('0x68')](_0xf9392f,_0x56b6c2);});if(_0x5b056f)return _0x389856['id'];}}));}}return Promise[_0x3a59ee('0x4c')](_0xb63baf)[_0x3a59ee('0xa')](function(_0x2a2858){const _0x3311e2=_0x3a59ee;return _0x3e4eae=_(_0x3e4eae)['union'](_0x2a2858)['compact']()[_0x3311e2('0x47')](),db[_0x3311e2('0x67')][_0x3311e2('0x13')]({'where':{'id':_0x117762[_0x3311e2('0x2e')]['id']}})[_0x3311e2('0xa')](function(_0x2f10cf){const _0x1356e9=_0x3311e2;return db[_0x1356e9('0x3')][_0x1356e9('0x5f')](function(_0x42f313){const _0x47a528=_0x1356e9;return _0x2f10cf[_0x47a528('0x39')](_0x117762[_0x47a528('0x25')][_0x47a528('0x32')],{'transaction':_0x42f313})[_0x47a528('0xa')](function(){const _0xbff7ab=_0x47a528;if(!_[_0xbff7ab('0x1d')](_0x3e4eae))return _0x2f10cf[_0xbff7ab('0x3e')](_0x3e4eae,{'transaction':_0x42f313});})[_0x47a528('0xa')](function(){const _0x51da72=_0x47a528;_0x3e4eae[_0x51da72('0x41')](function(_0x16a730){const _0x265c0c=_0x51da72;socket['emit'](_0x265c0c('0x3d'),{'UserId':_0x16a730,'OpenchannelQueueId':_0x2f10cf['id']});});});});});});})['then'](respondWithStatusCode(_0x21f042,null))['catch'](handleError(_0x21f042,null));},exports[_0x571e20('0x4e')]=function(_0x637d06,_0x148824){const _0x3c6d56=_0x571e20;return db[_0x3c6d56('0x67')][_0x3c6d56('0x13')]({'where':{'id':_0x637d06[_0x3c6d56('0x2e')]['id']}})[_0x3c6d56('0xa')](function(_0x67426f){const _0x4cfef0=_0x3c6d56;if(_0x67426f)return _0x67426f['addAgents'](_0x637d06[_0x4cfef0('0x6e')][_0x4cfef0('0x32')],{'through':_[_0x4cfef0('0x35')](_0x637d06[_0x4cfef0('0x6e')],['ids','id'])})[_0x4cfef0('0xa')](function(_0x16e4fc){const _0x4d1e35=_0x4cfef0;for(let _0x5f4eef=0x0;_0x5f4eef<_0x637d06[_0x4d1e35('0x6e')][_0x4d1e35('0x32')]['length'];_0x5f4eef+=0x1){socket[_0x4d1e35('0x6b')](_0x4d1e35('0x5c'),{'UserId':_0x637d06[_0x4d1e35('0x6e')]['ids'][_0x5f4eef],'OpenchannelQueueId':_0x637d06[_0x4d1e35('0x2e')]['id']});}return _0x16e4fc;});})[_0x3c6d56('0xa')](respondWithResult(_0x148824,null))[_0x3c6d56('0x52')](handleError(_0x148824,null));},exports['removeAgents']=function(_0x5a025c,_0x5c6a26){const _0x1762c6=_0x571e20;return db[_0x1762c6('0x67')][_0x1762c6('0x13')]({'where':{'id':_0x5a025c[_0x1762c6('0x2e')]['id']}})[_0x1762c6('0xa')](handleEntityNotFound(_0x5c6a26,null))['then'](function(_0x454d76){const _0x5cec0e=_0x1762c6;if(_0x454d76)return _0x454d76['removeAgents'](_0x5a025c[_0x5cec0e('0x25')][_0x5cec0e('0x32')])[_0x5cec0e('0xa')](function(){const _0x37465f=_0x5cec0e;if(_[_0x37465f('0x55')](_0x5a025c[_0x37465f('0x25')][_0x37465f('0x32')]))for(let _0x2b754b=0x0;_0x2b754b<_0x5a025c[_0x37465f('0x25')][_0x37465f('0x32')][_0x37465f('0x37')];_0x2b754b+=0x1){socket[_0x37465f('0x6b')](_0x37465f('0x3d'),{'UserId':Number(_0x5a025c[_0x37465f('0x25')][_0x37465f('0x32')][_0x2b754b]),'OpenchannelQueueId':Number(_0x5a025c[_0x37465f('0x2e')]['id'])});}else socket[_0x37465f('0x6b')](_0x37465f('0x3d'),{'UserId':Number(_0x5a025c['query'][_0x37465f('0x32')]),'OpenchannelQueueId':Number(_0x5a025c[_0x37465f('0x2e')]['id'])});});})['then'](respondWithStatusCode(_0x5c6a26,null))[_0x1762c6('0x52')](handleError(_0x5c6a26,null));},exports[_0x571e20('0x3a')]=function(_0x3a8b1a,_0x2dd9f4){const _0x1c6311=_0x571e20;let _0x2869ce={};const _0x2782ab={};let _0xd94874,_0x25af5c;return db['OpenchannelQueue'][_0x1c6311('0x13')]({'where':{'id':_0x3a8b1a[_0x1c6311('0x2e')]['id']}})['then'](handleEntityNotFound(_0x2dd9f4,null))['then'](function(_0x9cb4ca){const _0x51cfc7=_0x1c6311;if(_0x9cb4ca)return _0xd94874=_0x9cb4ca,_0x2782ab[_0x51cfc7('0x45')]=_[_0x51cfc7('0x48')](db['User'][_0x51cfc7('0x3c')]),_0x2782ab[_0x51cfc7('0x25')]=_[_0x51cfc7('0x48')](_0x3a8b1a[_0x51cfc7('0x25')]),_0x2782ab[_0x51cfc7('0x2d')]=_[_0x51cfc7('0x20')](_0x2782ab[_0x51cfc7('0x45')],_0x2782ab['query']),_0x2869ce[_0x51cfc7('0x29')]=_[_0x51cfc7('0x20')](_0x2782ab[_0x51cfc7('0x45')],qs[_0x51cfc7('0x9')](_0x3a8b1a['query']['fields'])),_0x2869ce[_0x51cfc7('0x29')]=_0x2869ce[_0x51cfc7('0x29')][_0x51cfc7('0x37')]?_0x2869ce[_0x51cfc7('0x29')]:_0x2782ab[_0x51cfc7('0x45')],_0x2869ce[_0x51cfc7('0x5')]=qs[_0x51cfc7('0x0')](_0x3a8b1a[_0x51cfc7('0x25')]['sort']),_0x2869ce[_0x51cfc7('0x2f')]=qs['filters'](_[_0x51cfc7('0x31')](_0x3a8b1a[_0x51cfc7('0x25')],_0x2782ab[_0x51cfc7('0x2d')])),_0x3a8b1a[_0x51cfc7('0x25')][_0x51cfc7('0x3f')]&&(_0x2869ce[_0x51cfc7('0x2f')]=_[_0x51cfc7('0x6d')](_0x2869ce['where'],{[Op['or']]:_[_0x51cfc7('0x33')](_0x2869ce['attributes'],function(_0x38f1da){const _0x6fafce=_0x51cfc7,_0x2bec18={};return _0x2bec18[_0x38f1da]={[Op[_0x6fafce('0x72')]]:'%'+_0x3a8b1a[_0x6fafce('0x25')][_0x6fafce('0x3f')]+'%'},_0x2bec18;})})),_0x2869ce=_[_0x51cfc7('0x6d')]({},_0x2869ce,_0x3a8b1a[_0x51cfc7('0x69')]),_0xd94874[_0x51cfc7('0x3a')](_0x2869ce);})['then'](function(_0xcc9fd1){const _0x23b1b2=_0x1c6311;if(_0xcc9fd1)return _0x25af5c=_0xcc9fd1[_0x23b1b2('0x37')],typeof _0x3a8b1a[_0x23b1b2('0x25')][_0x23b1b2('0x54')]===_0x23b1b2('0x65')&&(_0x2869ce[_0x23b1b2('0x6c')]=qs[_0x23b1b2('0x6c')](_0x3a8b1a[_0x23b1b2('0x25')]['limit']),_0x2869ce[_0x23b1b2('0x53')]=qs['offset'](_0x3a8b1a['query']['offset'])),_0xd94874[_0x23b1b2('0x3a')](_0x2869ce);})[_0x1c6311('0xa')](function(_0x22d8e5){if(_0x22d8e5)return _0x22d8e5?{'count':_0x25af5c,'rows':_0x22d8e5}:null;})['then'](respondWithResult(_0x2dd9f4,null))['catch'](handleError(_0x2dd9f4,null));}; \ No newline at end of file diff --git a/server/api/openchannelQueue/openchannelQueue.events.js b/server/api/openchannelQueue/openchannelQueue.events.js index 856ea4a..afd1609 100644 --- a/server/api/openchannelQueue/openchannelQueue.events.js +++ b/server/api/openchannelQueue/openchannelQueue.events.js @@ -1 +1 @@ -const a495_0x2989=['undefined','addHook','remove','OpenchannelQueue','save','events','update','../../mysqldb','emit','exports'];(function(_0x4c4337,_0x298995){const _0x2639cf=function(_0x5761df){while(--_0x5761df){_0x4c4337['push'](_0x4c4337['shift']());}};_0x2639cf(++_0x298995);}(a495_0x2989,0x145));const a495_0x2639=function(_0x4c4337,_0x298995){_0x4c4337=_0x4c4337-0x0;let _0x2639cf=a495_0x2989[_0x4c4337];return _0x2639cf;};const _0x301855=a495_0x2639;'use strict';const EventEmitter=require(_0x301855('0x0')),OpenchannelQueue=require(_0x301855('0x2'))['db'][_0x301855('0x8')],OpenchannelQueueEvents=new EventEmitter();OpenchannelQueueEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x301855('0x9'),'afterUpdate':_0x301855('0x1'),'afterDestroy':_0x301855('0x7')};function emitEvent(_0x5761df){return function(_0x3f36c4){const _0x16bb15=a495_0x2639;OpenchannelQueueEvents[_0x16bb15('0x3')](_0x5761df+':'+_0x3f36c4['id'],_0x3f36c4),OpenchannelQueueEvents[_0x16bb15('0x3')](_0x5761df,_0x3f36c4);};}for(const e in events){if(typeof events[e]!==_0x301855('0x5')){const event=events[e];OpenchannelQueue[_0x301855('0x6')](e,emitEvent(event));}}module[_0x301855('0x4')]=OpenchannelQueueEvents; \ No newline at end of file +const a495_0x56f5=['exports','events','OpenchannelQueue','addHook','save','../../mysqldb','undefined','update','remove'];(function(_0x430967,_0x56f5a0){const _0x246716=function(_0x5405d2){while(--_0x5405d2){_0x430967['push'](_0x430967['shift']());}};_0x246716(++_0x56f5a0);}(a495_0x56f5,0x68));const a495_0x2467=function(_0x430967,_0x56f5a0){_0x430967=_0x430967-0x0;let _0x246716=a495_0x56f5[_0x430967];return _0x246716;};const _0x5e16b5=a495_0x2467;'use strict';const EventEmitter=require(_0x5e16b5('0x5')),OpenchannelQueue=require(_0x5e16b5('0x0'))['db'][_0x5e16b5('0x6')],OpenchannelQueueEvents=new EventEmitter();OpenchannelQueueEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x5e16b5('0x8'),'afterUpdate':_0x5e16b5('0x2'),'afterDestroy':_0x5e16b5('0x3')};function emitEvent(_0x5405d2){return function(_0x33cbbf){OpenchannelQueueEvents['emit'](_0x5405d2+':'+_0x33cbbf['id'],_0x33cbbf),OpenchannelQueueEvents['emit'](_0x5405d2,_0x33cbbf);};}for(const e in events){if(typeof events[e]!==_0x5e16b5('0x1')){const event=events[e];OpenchannelQueue[_0x5e16b5('0x7')](e,emitEvent(event));}}module[_0x5e16b5('0x4')]=OpenchannelQueueEvents; \ No newline at end of file diff --git a/server/api/openchannelQueue/openchannelQueue.model.js b/server/api/openchannelQueue/openchannelQueue.model.js index 3c13ec5..101da42 100644 --- a/server/api/openchannelQueue/openchannelQueue.model.js +++ b/server/api/openchannelQueue/openchannelQueue.model.js @@ -1 +1 @@ -const a496_0x53b9=['openchannel_queues','OpenchannelQueue','exports'];(function(_0x30da7d,_0x53b971){const _0x4633bd=function(_0x1f5b50){while(--_0x1f5b50){_0x30da7d['push'](_0x30da7d['shift']());}};_0x4633bd(++_0x53b971);}(a496_0x53b9,0xe9));const a496_0x4633=function(_0x30da7d,_0x53b971){_0x30da7d=_0x30da7d-0x0;let _0x4633bd=a496_0x53b9[_0x30da7d];return _0x4633bd;};const _0x5b8075=a496_0x4633;'use strict';const attributes=require('./openchannelQueue.attributes');module[_0x5b8075('0x0')]=function(_0x1f5b50){const _0x545cec=_0x5b8075,_0x451346=_0x1f5b50['define'](_0x545cec('0x2'),attributes,{'tableName':_0x545cec('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x451346;}; \ No newline at end of file +const a496_0x2e2e=['exports','openchannel_queues','OpenchannelQueue','./openchannelQueue.attributes','define'];(function(_0x212de2,_0x2e2e0f){const _0x396ac5=function(_0x2ff374){while(--_0x2ff374){_0x212de2['push'](_0x212de2['shift']());}};_0x396ac5(++_0x2e2e0f);}(a496_0x2e2e,0xb4));const a496_0x396a=function(_0x212de2,_0x2e2e0f){_0x212de2=_0x212de2-0x0;let _0x396ac5=a496_0x2e2e[_0x212de2];return _0x396ac5;};const _0x54afc9=a496_0x396a;'use strict';const attributes=require(_0x54afc9('0x3'));module[_0x54afc9('0x0')]=function(_0x2ff374){const _0x44377b=_0x54afc9,_0x59b55b=_0x2ff374[_0x44377b('0x4')](_0x44377b('0x2'),attributes,{'tableName':_0x44377b('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x59b55b;}; \ No newline at end of file diff --git a/server/api/openchannelQueue/openchannelQueue.rpc.js b/server/api/openchannelQueue/openchannelQueue.rpc.js index 59949e3..c754483 100644 --- a/server/api/openchannelQueue/openchannelQueue.rpc.js +++ b/server/api/openchannelQueue/openchannelQueue.rpc.js @@ -1 +1 @@ -const a497_0x2e0f=['lodash','info','OpenchannelQueue','../../config/logger','map','limit','findAll','rpc','then','register','GetOpenchannelQueue','message','debug','../../rediscache','where','../../mysqldb','stringify','options','findOne','error','catch','ShowOpenchannelQueue','raw','model','attributes','include','./openchannelQueue.socket'];(function(_0x1974b0,_0x2e0f59){const _0x3e33ea=function(_0x42784e){while(--_0x42784e){_0x1974b0['push'](_0x1974b0['shift']());}};_0x3e33ea(++_0x2e0f59);}(a497_0x2e0f,0x1de));const a497_0x3e33=function(_0x1974b0,_0x2e0f59){_0x1974b0=_0x1974b0-0x0;let _0x3e33ea=a497_0x2e0f[_0x1974b0];return _0x3e33ea;};const _0x5cb0b4=a497_0x3e33;'use strict';const _=require(_0x5cb0b4('0x8')),db=require(_0x5cb0b4('0x17'))['db'],logger=require(_0x5cb0b4('0xb'))(_0x5cb0b4('0xf')),{getSocket}=require(_0x5cb0b4('0x15')),socket=getSocket();require(_0x5cb0b4('0x7'))[_0x5cb0b4('0x11')](socket),exports[_0x5cb0b4('0x12')]=function(_0x42784e){const _0x8c70ff=this;return new Promise(function(_0x2ce008,_0xc8214){const _0x43bf0e=a497_0x3e33;return db['OpenchannelQueue'][_0x43bf0e('0xe')]({'raw':_0x42784e[_0x43bf0e('0x19')]?_0x42784e['options'][_0x43bf0e('0x3')]===undefined?!![]:![]:!![],'where':_0x42784e[_0x43bf0e('0x19')]?_0x42784e[_0x43bf0e('0x19')][_0x43bf0e('0x16')]||null:null,'attributes':_0x42784e['options']?_0x42784e['options'][_0x43bf0e('0x5')]||null:null,'limit':_0x42784e[_0x43bf0e('0x19')]?_0x42784e['options'][_0x43bf0e('0xd')]||null:null,'include':_0x42784e[_0x43bf0e('0x19')]?_0x42784e['options']['include']?_[_0x43bf0e('0xc')](_0x42784e[_0x43bf0e('0x19')][_0x43bf0e('0x6')],function(_0x5957ff){const _0x3b6255=_0x43bf0e;return{'model':db[_0x5957ff[_0x3b6255('0x4')]],'as':_0x5957ff['as'],'attributes':_0x5957ff[_0x3b6255('0x5')],'include':_0x5957ff[_0x3b6255('0x6')]?_[_0x3b6255('0xc')](_0x5957ff[_0x3b6255('0x6')],function(_0x43af4f){const _0x51b03e=_0x3b6255;return{'model':db[_0x43af4f[_0x51b03e('0x4')]],'as':_0x43af4f['as'],'attributes':_0x43af4f[_0x51b03e('0x5')],'include':_0x43af4f['include']?_[_0x51b03e('0xc')](_0x43af4f['include'],function(_0x256ddc){const _0x49d014=_0x51b03e;return{'model':db[_0x256ddc[_0x49d014('0x4')]],'as':_0x256ddc['as'],'attributes':_0x256ddc[_0x49d014('0x5')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x37a127){const _0x896954=_0x43bf0e;logger[_0x896954('0x9')](_0x896954('0x12'),_0x42784e),logger[_0x896954('0x14')]('GetOpenchannelQueue',_0x42784e,JSON[_0x896954('0x18')](_0x37a127)),_0x2ce008(_0x37a127);})[_0x43bf0e('0x1')](function(_0x424d72){const _0x7cf722=_0x43bf0e;logger[_0x7cf722('0x0')](_0x7cf722('0x12'),_0x424d72[_0x7cf722('0x13')],_0x42784e),_0xc8214(_0x8c70ff[_0x7cf722('0x0')](0x1f4,_0x424d72[_0x7cf722('0x13')]));});});},exports['ShowOpenchannelQueue']=function(_0x404bd9){const _0xec09fe=this;return new Promise(function(_0x51c9dc,_0x52bbbd){const _0x2e26eb=a497_0x3e33;return db[_0x2e26eb('0xa')][_0x2e26eb('0x1a')]({'raw':_0x404bd9[_0x2e26eb('0x19')]?_0x404bd9[_0x2e26eb('0x19')][_0x2e26eb('0x3')]===undefined?!![]:![]:!![],'where':_0x404bd9['options']?_0x404bd9[_0x2e26eb('0x19')][_0x2e26eb('0x16')]||null:null,'attributes':_0x404bd9[_0x2e26eb('0x19')]?_0x404bd9[_0x2e26eb('0x19')][_0x2e26eb('0x5')]||null:null,'include':_0x404bd9['options']?_0x404bd9[_0x2e26eb('0x19')][_0x2e26eb('0x6')]?_[_0x2e26eb('0xc')](_0x404bd9['options'][_0x2e26eb('0x6')],function(_0x460ccb){const _0x18a364=_0x2e26eb;return{'model':db[_0x460ccb[_0x18a364('0x4')]],'as':_0x460ccb['as'],'attributes':_0x460ccb[_0x18a364('0x5')],'include':_0x460ccb[_0x18a364('0x6')]?_[_0x18a364('0xc')](_0x460ccb[_0x18a364('0x6')],function(_0xfbc86a){const _0x462edf=_0x18a364;return{'model':db[_0xfbc86a[_0x462edf('0x4')]],'as':_0xfbc86a['as'],'attributes':_0xfbc86a[_0x462edf('0x5')],'include':_0xfbc86a[_0x462edf('0x6')]?_['map'](_0xfbc86a['include'],function(_0x1ef0f6){const _0x5181f6=_0x462edf;return{'model':db[_0x1ef0f6[_0x5181f6('0x4')]],'as':_0x1ef0f6['as'],'attributes':_0x1ef0f6[_0x5181f6('0x5')]};}):[]};}):[]};}):[]:[]})[_0x2e26eb('0x10')](function(_0x639925){const _0x468de2=_0x2e26eb;logger[_0x468de2('0x9')]('ShowOpenchannelQueue',_0x404bd9),logger[_0x468de2('0x14')](_0x468de2('0x2'),_0x404bd9,JSON[_0x468de2('0x18')](_0x639925)),_0x51c9dc(_0x639925);})[_0x2e26eb('0x1')](function(_0x54e933){const _0x10398c=_0x2e26eb;logger['error']('ShowOpenchannelQueue',_0x54e933[_0x10398c('0x13')],_0x404bd9),_0x52bbbd(_0xec09fe[_0x10398c('0x0')](0x1f4,_0x54e933[_0x10398c('0x13')]));});});}; \ No newline at end of file +const a497_0x3030=['register','catch','then','map','limit','message','OpenchannelQueue','model','info','rpc','raw','findAll','../../mysqldb','attributes','GetOpenchannelQueue','ShowOpenchannelQueue','error','../../rediscache','../../config/logger','where','include','stringify','./openchannelQueue.socket','options','debug'];(function(_0x2fae24,_0x303030){const _0x366fc8=function(_0x58876c){while(--_0x58876c){_0x2fae24['push'](_0x2fae24['shift']());}};_0x366fc8(++_0x303030);}(a497_0x3030,0x8f));const a497_0x366f=function(_0x2fae24,_0x303030){_0x2fae24=_0x2fae24-0x0;let _0x366fc8=a497_0x3030[_0x2fae24];return _0x366fc8;};const _0x5d3be9=a497_0x366f;'use strict';const _=require('lodash'),db=require(_0x5d3be9('0x13'))['db'],logger=require(_0x5d3be9('0x0'))(_0x5d3be9('0x10')),{getSocket}=require(_0x5d3be9('0x18')),socket=getSocket();require(_0x5d3be9('0x4'))[_0x5d3be9('0x7')](socket),exports[_0x5d3be9('0x15')]=function(_0x58876c){const _0x33740e=this;return new Promise(function(_0x332d45,_0x5a23f8){const _0x3c4549=a497_0x366f;return db[_0x3c4549('0xd')][_0x3c4549('0x12')]({'raw':_0x58876c[_0x3c4549('0x5')]?_0x58876c[_0x3c4549('0x5')][_0x3c4549('0x11')]===undefined?!![]:![]:!![],'where':_0x58876c[_0x3c4549('0x5')]?_0x58876c['options'][_0x3c4549('0x1')]||null:null,'attributes':_0x58876c[_0x3c4549('0x5')]?_0x58876c[_0x3c4549('0x5')][_0x3c4549('0x14')]||null:null,'limit':_0x58876c[_0x3c4549('0x5')]?_0x58876c[_0x3c4549('0x5')][_0x3c4549('0xb')]||null:null,'include':_0x58876c['options']?_0x58876c['options'][_0x3c4549('0x2')]?_[_0x3c4549('0xa')](_0x58876c[_0x3c4549('0x5')][_0x3c4549('0x2')],function(_0x4cef3d){const _0x42f399=_0x3c4549;return{'model':db[_0x4cef3d[_0x42f399('0xe')]],'as':_0x4cef3d['as'],'attributes':_0x4cef3d[_0x42f399('0x14')],'include':_0x4cef3d['include']?_[_0x42f399('0xa')](_0x4cef3d[_0x42f399('0x2')],function(_0x5245b8){const _0x1b300f=_0x42f399;return{'model':db[_0x5245b8[_0x1b300f('0xe')]],'as':_0x5245b8['as'],'attributes':_0x5245b8[_0x1b300f('0x14')],'include':_0x5245b8[_0x1b300f('0x2')]?_['map'](_0x5245b8[_0x1b300f('0x2')],function(_0x1e3ea0){const _0x41ad84=_0x1b300f;return{'model':db[_0x1e3ea0[_0x41ad84('0xe')]],'as':_0x1e3ea0['as'],'attributes':_0x1e3ea0[_0x41ad84('0x14')]};}):[]};}):[]};}):[]:[]})[_0x3c4549('0x9')](function(_0x342693){const _0x575259=_0x3c4549;logger['info'](_0x575259('0x15'),_0x58876c),logger[_0x575259('0x6')](_0x575259('0x15'),_0x58876c,JSON[_0x575259('0x3')](_0x342693)),_0x332d45(_0x342693);})[_0x3c4549('0x8')](function(_0x2b4cc7){const _0x4ddcbe=_0x3c4549;logger[_0x4ddcbe('0x17')](_0x4ddcbe('0x15'),_0x2b4cc7[_0x4ddcbe('0xc')],_0x58876c),_0x5a23f8(_0x33740e['error'](0x1f4,_0x2b4cc7[_0x4ddcbe('0xc')]));});});},exports[_0x5d3be9('0x16')]=function(_0x4c475e){const _0x459f58=this;return new Promise(function(_0x46a24c,_0x14ce4b){const _0x521888=a497_0x366f;return db[_0x521888('0xd')]['findOne']({'raw':_0x4c475e[_0x521888('0x5')]?_0x4c475e[_0x521888('0x5')][_0x521888('0x11')]===undefined?!![]:![]:!![],'where':_0x4c475e[_0x521888('0x5')]?_0x4c475e['options'][_0x521888('0x1')]||null:null,'attributes':_0x4c475e[_0x521888('0x5')]?_0x4c475e[_0x521888('0x5')][_0x521888('0x14')]||null:null,'include':_0x4c475e[_0x521888('0x5')]?_0x4c475e[_0x521888('0x5')]['include']?_['map'](_0x4c475e[_0x521888('0x5')][_0x521888('0x2')],function(_0x4ae899){const _0x470062=_0x521888;return{'model':db[_0x4ae899[_0x470062('0xe')]],'as':_0x4ae899['as'],'attributes':_0x4ae899[_0x470062('0x14')],'include':_0x4ae899[_0x470062('0x2')]?_[_0x470062('0xa')](_0x4ae899[_0x470062('0x2')],function(_0x44df5d){const _0x4f20fa=_0x470062;return{'model':db[_0x44df5d[_0x4f20fa('0xe')]],'as':_0x44df5d['as'],'attributes':_0x44df5d[_0x4f20fa('0x14')],'include':_0x44df5d[_0x4f20fa('0x2')]?_[_0x4f20fa('0xa')](_0x44df5d[_0x4f20fa('0x2')],function(_0x14140a){const _0x32925c=_0x4f20fa;return{'model':db[_0x14140a[_0x32925c('0xe')]],'as':_0x14140a['as'],'attributes':_0x14140a[_0x32925c('0x14')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x5cd088){const _0x1ac716=_0x521888;logger[_0x1ac716('0xf')](_0x1ac716('0x16'),_0x4c475e),logger['debug'](_0x1ac716('0x16'),_0x4c475e,JSON['stringify'](_0x5cd088)),_0x46a24c(_0x5cd088);})[_0x521888('0x8')](function(_0x10d820){const _0x67330d=_0x521888;logger[_0x67330d('0x17')](_0x67330d('0x16'),_0x10d820['message'],_0x4c475e),_0x14ce4b(_0x459f58[_0x67330d('0x17')](0x1f4,_0x10d820[_0x67330d('0xc')]));});});}; \ No newline at end of file diff --git a/server/api/openchannelQueue/openchannelQueue.socket.js b/server/api/openchannelQueue/openchannelQueue.socket.js index 0b2e0fd..7468be7 100644 --- a/server/api/openchannelQueue/openchannelQueue.socket.js +++ b/server/api/openchannelQueue/openchannelQueue.socket.js @@ -1 +1 @@ -const a498_0x3141=['length','register','save','./openchannelQueue.events','update','openchannelQueue:','remove'];(function(_0x80dbd5,_0x3141ec){const _0x5b735e=function(_0x5ddca9){while(--_0x5ddca9){_0x80dbd5['push'](_0x80dbd5['shift']());}};_0x5b735e(++_0x3141ec);}(a498_0x3141,0xa4));const a498_0x5b73=function(_0x80dbd5,_0x3141ec){_0x80dbd5=_0x80dbd5-0x0;let _0x5b735e=a498_0x3141[_0x80dbd5];return _0x5b735e;};const _0x28e1bf=a498_0x5b73;'use strict';const OpenchannelQueueEvents=require(_0x28e1bf('0x0')),events=[_0x28e1bf('0x6'),_0x28e1bf('0x3'),_0x28e1bf('0x1')];function createListener(_0x5ddca9,_0x4f1589){return function(_0x491d7a){_0x4f1589['emit'](_0x5ddca9,_0x491d7a);};}exports[_0x28e1bf('0x5')]=function(_0x490002){const _0x476273=_0x28e1bf;for(let _0x1e50ec=0x0,_0x56be0a=events[_0x476273('0x4')];_0x1e50ec<_0x56be0a;_0x1e50ec++){const _0x2c91ae=events[_0x1e50ec],_0x172d87=createListener(_0x476273('0x2')+_0x2c91ae,_0x490002);OpenchannelQueueEvents['on'](_0x2c91ae,_0x172d87);}}; \ No newline at end of file +const a498_0x36ff=['update','length','remove','emit','save','./openchannelQueue.events','register','openchannelQueue:'];(function(_0x12af62,_0x36ffe5){const _0x193195=function(_0x1ffc2c){while(--_0x1ffc2c){_0x12af62['push'](_0x12af62['shift']());}};_0x193195(++_0x36ffe5);}(a498_0x36ff,0x16e));const a498_0x1931=function(_0x12af62,_0x36ffe5){_0x12af62=_0x12af62-0x0;let _0x193195=a498_0x36ff[_0x12af62];return _0x193195;};const _0x57dc01=a498_0x1931;'use strict';const OpenchannelQueueEvents=require(_0x57dc01('0x7')),events=[_0x57dc01('0x6'),_0x57dc01('0x4'),_0x57dc01('0x2')];function createListener(_0x1ffc2c,_0x149bfd){return function(_0x56af4d){const _0x401c85=a498_0x1931;_0x149bfd[_0x401c85('0x5')](_0x1ffc2c,_0x56af4d);};}exports[_0x57dc01('0x0')]=function(_0x9643cf){const _0x8cddb0=_0x57dc01;for(let _0x445f55=0x0,_0x54755f=events[_0x8cddb0('0x3')];_0x445f55<_0x54755f;_0x445f55++){const _0x4cbf31=events[_0x445f55],_0x525dff=createListener(_0x8cddb0('0x1')+_0x4cbf31,_0x9643cf);OpenchannelQueueEvents['on'](_0x4cbf31,_0x525dff);}}; \ No newline at end of file diff --git a/server/api/openchannelQueueReport/index.js b/server/api/openchannelQueueReport/index.js index 96b1bb6..1d0b580 100644 --- a/server/api/openchannelQueueReport/index.js +++ b/server/api/openchannelQueueReport/index.js @@ -1 +1 @@ -const a499_0x6a52=['destroy','get','delete','isAuthenticated','post','put','/:id','express','index','../../components/auth/service','./openchannelQueueReport.controller','create','update','Router','/describe'];(function(_0x1f28a3,_0x6a5230){const _0x5b5878=function(_0x26fe1e){while(--_0x26fe1e){_0x1f28a3['push'](_0x1f28a3['shift']());}};_0x5b5878(++_0x6a5230);}(a499_0x6a52,0x103));const a499_0x5b58=function(_0x1f28a3,_0x6a5230){_0x1f28a3=_0x1f28a3-0x0;let _0x5b5878=a499_0x6a52[_0x1f28a3];return _0x5b5878;};const _0x38219e=a499_0x5b58;'use strict';const express=require(_0x38219e('0x3')),router=express[_0x38219e('0x9')](),auth=require(_0x38219e('0x5')),controller=require(_0x38219e('0x6'));router[_0x38219e('0xc')]('/',auth[_0x38219e('0xe')](),controller[_0x38219e('0x4')]),router[_0x38219e('0xc')](_0x38219e('0xa'),auth[_0x38219e('0xe')](),controller['describe']),router['get'](_0x38219e('0x2'),auth[_0x38219e('0xe')](),controller['show']),router[_0x38219e('0x0')]('/',auth[_0x38219e('0xe')](),controller[_0x38219e('0x7')]),router[_0x38219e('0x1')](_0x38219e('0x2'),auth['isAuthenticated'](),controller[_0x38219e('0x8')]),router[_0x38219e('0xd')](_0x38219e('0x2'),auth[_0x38219e('0xe')](),controller[_0x38219e('0xb')]),module['exports']=router; \ No newline at end of file +const a499_0x3f86=['isAuthenticated','post','get','put','create','show','describe','../../components/auth/service','update','express','exports','Router','/:id','./openchannelQueueReport.controller','delete','index','/describe'];(function(_0x4815fe,_0x3f860b){const _0x3764d0=function(_0x38d6ec){while(--_0x38d6ec){_0x4815fe['push'](_0x4815fe['shift']());}};_0x3764d0(++_0x3f860b);}(a499_0x3f86,0x7f));const a499_0x3764=function(_0x4815fe,_0x3f860b){_0x4815fe=_0x4815fe-0x0;let _0x3764d0=a499_0x3f86[_0x4815fe];return _0x3764d0;};const _0x212508=a499_0x3764;'use strict';const express=require(_0x212508('0x1')),router=express[_0x212508('0x3')](),auth=require(_0x212508('0x10')),controller=require(_0x212508('0x5'));router['get']('/',auth[_0x212508('0x9')](),controller[_0x212508('0x7')]),router[_0x212508('0xb')](_0x212508('0x8'),auth[_0x212508('0x9')](),controller[_0x212508('0xf')]),router[_0x212508('0xb')](_0x212508('0x4'),auth['isAuthenticated'](),controller[_0x212508('0xe')]),router[_0x212508('0xa')]('/',auth[_0x212508('0x9')](),controller[_0x212508('0xd')]),router[_0x212508('0xc')](_0x212508('0x4'),auth['isAuthenticated'](),controller[_0x212508('0x0')]),router[_0x212508('0x6')]('/:id',auth[_0x212508('0x9')](),controller['destroy']),module[_0x212508('0x2')]=router; \ No newline at end of file diff --git a/server/api/openchannelQueueReport/openchannelQueueReport.attributes.js b/server/api/openchannelQueueReport/openchannelQueueReport.attributes.js index 8bcd5c6..d443639 100644 --- a/server/api/openchannelQueueReport/openchannelQueueReport.attributes.js +++ b/server/api/openchannelQueueReport/openchannelQueueReport.attributes.js @@ -1 +1 @@ -const a500_0x3e5c=['DATE','STRING'];(function(_0xa045a2,_0x3e5c68){const _0xbf1f9=function(_0x54e0a3){while(--_0x54e0a3){_0xa045a2['push'](_0xa045a2['shift']());}};_0xbf1f9(++_0x3e5c68);}(a500_0x3e5c,0x1c2));const a500_0xbf1f=function(_0xa045a2,_0x3e5c68){_0xa045a2=_0xa045a2-0x0;let _0xbf1f9=a500_0x3e5c[_0xa045a2];return _0xbf1f9;};const _0x419040=a500_0xbf1f;'use strict';const Sequelize=require('sequelize');module['exports']={'uniqueid':{'type':Sequelize[_0x419040('0x1')],'allowNull':![]},'from':{'type':Sequelize[_0x419040('0x1')]},'joinAt':{'type':Sequelize[_0x419040('0x0')]},'leaveAt':{'type':Sequelize[_0x419040('0x0')]},'acceptAt':{'type':Sequelize[_0x419040('0x0')]},'exitAt':{'type':Sequelize['DATE']},'reason':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a500_0xa598=['DATE','sequelize','STRING'];(function(_0x227fd1,_0xa598a7){const _0x483524=function(_0x263ada){while(--_0x263ada){_0x227fd1['push'](_0x227fd1['shift']());}};_0x483524(++_0xa598a7);}(a500_0xa598,0x115));const a500_0x4835=function(_0x227fd1,_0xa598a7){_0x227fd1=_0x227fd1-0x0;let _0x483524=a500_0xa598[_0x227fd1];return _0x483524;};const _0x15d699=a500_0x4835;'use strict';const Sequelize=require(_0x15d699('0x0'));module['exports']={'uniqueid':{'type':Sequelize['STRING'],'allowNull':![]},'from':{'type':Sequelize[_0x15d699('0x1')]},'joinAt':{'type':Sequelize[_0x15d699('0x2')]},'leaveAt':{'type':Sequelize[_0x15d699('0x2')]},'acceptAt':{'type':Sequelize[_0x15d699('0x2')]},'exitAt':{'type':Sequelize[_0x15d699('0x2')]},'reason':{'type':Sequelize[_0x15d699('0x1')]}}; \ No newline at end of file diff --git a/server/api/openchannelQueueReport/openchannelQueueReport.controller.js b/server/api/openchannelQueueReport/openchannelQueueReport.controller.js index dd8fce2..4691ef4 100644 --- a/server/api/openchannelQueueReport/openchannelQueueReport.controller.js +++ b/server/api/openchannelQueueReport/openchannelQueueReport.controller.js @@ -1 +1 @@ -const a501_0x4f97=['query','merge','findOne','pick','undefined','options','end','rawAttributes','attributes','body','params','set','json','sort','model','Content-Range','where','../../mysqldb','stack','type','status','send','update','lodash','map','name','create','filters','include','../../components/parsers/qs','filter','rows','show','keys','limit','fieldName','findAll','OpenchannelQueueReport','intersection','describe','then','length','like','../../config/logger','destroy','fields','sequelize','catch','offset','count','includeAll'];(function(_0x27da2f,_0x4f973b){const _0x53724e=function(_0x3ed150){while(--_0x3ed150){_0x27da2f['push'](_0x27da2f['shift']());}};_0x53724e(++_0x4f973b);}(a501_0x4f97,0x1d1));const a501_0x5372=function(_0x27da2f,_0x4f973b){_0x27da2f=_0x27da2f-0x0;let _0x53724e=a501_0x4f97[_0x27da2f];return _0x53724e;};const _0xd2f2ca=a501_0x5372;'use strict';const _=require(_0xd2f2ca('0x11')),qs=require(_0xd2f2ca('0x17')),logger=require(_0xd2f2ca('0x25'))('api'),db=require(_0xd2f2ca('0xb'))['db'],{Op}=require(_0xd2f2ca('0x28'));function respondWithResult(_0x3ed150,_0x482996){return _0x482996=_0x482996||0xc8,function(_0x5f4add){const _0x4cc8c3=a501_0x5372;if(_0x5f4add)return _0x3ed150[_0x4cc8c3('0xe')](_0x482996)[_0x4cc8c3('0x6')](_0x5f4add);};}function respondWithFilteredResult(_0x2e7ecd,_0x5c47c3){return function(_0x2491e1){const _0x496bcc=a501_0x5372;if(_0x2491e1){const _0x41a155=_0x2491e1[_0x496bcc('0x2b')],_0x556b0f=_0x5c47c3['offset'];let _0x313817=_0x5c47c3[_0x496bcc('0x2a')]+_0x5c47c3['limit'],_0x3bcf25;return _0x313817>=_0x41a155?(_0x313817=_0x41a155,_0x3bcf25=0xc8):_0x3bcf25=0xce,_0x2e7ecd[_0x496bcc('0xe')](_0x3bcf25),_0x2e7ecd[_0x496bcc('0x5')](_0x496bcc('0x9'),_0x556b0f+'-'+_0x313817+'/'+_0x41a155)[_0x496bcc('0x6')](_0x2491e1);}return null;};}function saveUpdates(_0x53d41a){return function(_0x113f2a){const _0x2985ac=a501_0x5372;if(_0x113f2a)return _0x113f2a[_0x2985ac('0x10')](_0x53d41a)['then'](function(_0x150eea){return _0x150eea;});return null;};}function removeEntity(_0x4ffa87){return function(_0x599359){const _0x30a10a=a501_0x5372;if(_0x599359)return _0x599359[_0x30a10a('0x26')]()[_0x30a10a('0x22')](function(){const _0x39f81b=_0x30a10a;_0x4ffa87[_0x39f81b('0xe')](0xcc)[_0x39f81b('0x0')]();});};}function handleEntityNotFound(_0x31a827){return function(_0x3f4eef){return!_0x3f4eef&&_0x31a827['sendStatus'](0x194),_0x3f4eef;};}function handleError(_0x33affe,_0x18a34d){return _0x18a34d=_0x18a34d||0x1f4,function(_0x4a35d8){const _0x3a04ba=a501_0x5372;logger['error'](_0x4a35d8[_0x3a04ba('0xc')]),_0x4a35d8[_0x3a04ba('0x13')]&&delete _0x4a35d8['name'],_0x33affe[_0x3a04ba('0xe')](_0x18a34d)[_0x3a04ba('0xf')](_0x4a35d8);};}exports['index']=function(_0x19db1b,_0x3e23c0){const _0x2104ff=_0xd2f2ca;let _0x384a1b={};const _0xa4fa9c={},_0x155607={'count':0x0,'rows':[]},_0x20893f=_[_0x2104ff('0x12')](db[_0x2104ff('0x1f')][_0x2104ff('0x1')],function(_0x82a1d4){const _0x51d172=_0x2104ff;return{'name':_0x82a1d4[_0x51d172('0x1d')],'type':_0x82a1d4[_0x51d172('0xd')]['key']};});_0xa4fa9c['model']=_['map'](_0x20893f,_0x2104ff('0x13')),_0xa4fa9c[_0x2104ff('0x2d')]=_[_0x2104ff('0x1b')](_0x19db1b['query']),_0xa4fa9c[_0x2104ff('0x15')]=_[_0x2104ff('0x20')](_0xa4fa9c['model'],_0xa4fa9c[_0x2104ff('0x2d')]),_0x384a1b[_0x2104ff('0x2')]=_[_0x2104ff('0x20')](_0xa4fa9c['model'],qs[_0x2104ff('0x27')](_0x19db1b[_0x2104ff('0x2d')]['fields'])),_0x384a1b[_0x2104ff('0x2')]=_0x384a1b[_0x2104ff('0x2')][_0x2104ff('0x23')]?_0x384a1b[_0x2104ff('0x2')]:_0xa4fa9c[_0x2104ff('0x8')];typeof _0x19db1b[_0x2104ff('0x2d')]['nolimit']===_0x2104ff('0x31')&&(_0x384a1b['limit']=qs[_0x2104ff('0x1c')](_0x19db1b['query'][_0x2104ff('0x1c')]),_0x384a1b[_0x2104ff('0x2a')]=qs[_0x2104ff('0x2a')](_0x19db1b[_0x2104ff('0x2d')][_0x2104ff('0x2a')]));_0x384a1b['order']=qs[_0x2104ff('0x7')](_0x19db1b[_0x2104ff('0x2d')][_0x2104ff('0x7')]),_0x384a1b['where']=qs['filters'](_[_0x2104ff('0x30')](_0x19db1b[_0x2104ff('0x2d')],_0xa4fa9c[_0x2104ff('0x15')]),_0x20893f);_0x19db1b['query'][_0x2104ff('0x18')]&&(_0x384a1b[_0x2104ff('0xa')]=_[_0x2104ff('0x2e')](_0x384a1b['where'],{[Op['or']]:_[_0x2104ff('0x12')](_0x20893f,function(_0x5b57df){const _0xac4c93=_0x2104ff;if(_0x5b57df[_0xac4c93('0xd')]!=='VIRTUAL'){const _0x3b1382={};return _0x3b1382[_0x5b57df[_0xac4c93('0x13')]]={[Op[_0xac4c93('0x24')]]:'%'+_0x19db1b[_0xac4c93('0x2d')][_0xac4c93('0x18')]+'%'},_0x3b1382;}})}));_0x384a1b=_['merge']({},_0x384a1b,_0x19db1b[_0x2104ff('0x32')]);const _0xe8dfb={'where':_0x384a1b['where']};return db['OpenchannelQueueReport'][_0x2104ff('0x2b')](_0xe8dfb)[_0x2104ff('0x22')](function(_0x31cff2){const _0x5d2f36=_0x2104ff;return _0x155607['count']=_0x31cff2,_0x19db1b[_0x5d2f36('0x2d')][_0x5d2f36('0x2c')]&&(_0x384a1b[_0x5d2f36('0x16')]=[{'all':!![]}]),db['OpenchannelQueueReport'][_0x5d2f36('0x1e')](_0x384a1b);})['then'](function(_0x5e5c44){const _0x1a2807=_0x2104ff;return _0x155607[_0x1a2807('0x19')]=_0x5e5c44,_0x155607;})[_0x2104ff('0x22')](respondWithFilteredResult(_0x3e23c0,_0x384a1b))['catch'](handleError(_0x3e23c0,null));},exports[_0xd2f2ca('0x1a')]=function(_0x5af322,_0x3592f7){const _0x42817f=_0xd2f2ca;let _0x402296={'raw':!![],'where':{'id':_0x5af322['params']['id']}};const _0x407c32={};return _0x407c32[_0x42817f('0x8')]=_['keys'](db[_0x42817f('0x1f')][_0x42817f('0x1')]),_0x407c32[_0x42817f('0x2d')]=_[_0x42817f('0x1b')](_0x5af322['query']),_0x407c32['filters']=_[_0x42817f('0x20')](_0x407c32[_0x42817f('0x8')],_0x407c32['query']),_0x402296['attributes']=_['intersection'](_0x407c32[_0x42817f('0x8')],qs[_0x42817f('0x27')](_0x5af322['query'][_0x42817f('0x27')])),_0x402296[_0x42817f('0x2')]=_0x402296[_0x42817f('0x2')][_0x42817f('0x23')]?_0x402296['attributes']:_0x407c32[_0x42817f('0x8')],_0x5af322['query'][_0x42817f('0x2c')]&&(_0x402296[_0x42817f('0x16')]=[{'all':!![]}]),_0x402296=_['merge']({},_0x402296,_0x5af322[_0x42817f('0x32')]),db['OpenchannelQueueReport'][_0x42817f('0x2f')](_0x402296)[_0x42817f('0x22')](handleEntityNotFound(_0x3592f7,null))[_0x42817f('0x22')](respondWithResult(_0x3592f7,null))[_0x42817f('0x29')](handleError(_0x3592f7,null));},exports[_0xd2f2ca('0x14')]=function(_0x512c39,_0x5a1dd6){const _0x3788a8=_0xd2f2ca;return db[_0x3788a8('0x1f')][_0x3788a8('0x14')](_0x512c39[_0x3788a8('0x3')],{})[_0x3788a8('0x22')](respondWithResult(_0x5a1dd6,0xc9))[_0x3788a8('0x29')](handleError(_0x5a1dd6,null));},exports['update']=function(_0x401c53,_0x5b0239){const _0xed6d2d=_0xd2f2ca;return _0x401c53[_0xed6d2d('0x3')]['id']&&delete _0x401c53[_0xed6d2d('0x3')]['id'],db[_0xed6d2d('0x1f')][_0xed6d2d('0x2f')]({'where':{'id':_0x401c53['params']['id']}})[_0xed6d2d('0x22')](handleEntityNotFound(_0x5b0239,null))[_0xed6d2d('0x22')](saveUpdates(_0x401c53[_0xed6d2d('0x3')],null))[_0xed6d2d('0x22')](respondWithResult(_0x5b0239,null))[_0xed6d2d('0x29')](handleError(_0x5b0239,null));},exports[_0xd2f2ca('0x26')]=function(_0x490b8a,_0x107404){const _0x9ba9c=_0xd2f2ca;return db[_0x9ba9c('0x1f')][_0x9ba9c('0x2f')]({'where':{'id':_0x490b8a[_0x9ba9c('0x4')]['id']}})[_0x9ba9c('0x22')](handleEntityNotFound(_0x107404,null))[_0x9ba9c('0x22')](removeEntity(_0x107404,null))[_0x9ba9c('0x29')](handleError(_0x107404,null));},exports[_0xd2f2ca('0x21')]=function(_0x3b6a23,_0x23b655){const _0x2b35d3=_0xd2f2ca;return db[_0x2b35d3('0x1f')][_0x2b35d3('0x21')]()['then'](respondWithResult(_0x23b655,null))['catch'](handleError(_0x23b655,null));}; \ No newline at end of file +const a501_0x5b4d=['keys','fields','end','show','status','../../config/logger','offset','findAll','create','rawAttributes','send','destroy','where','describe','options','params','catch','includeAll','error','like','then','index','Content-Range','type','include','sequelize','count','filter','length','set','api','nolimit','../../mysqldb','json','intersection','filters','query','order','sort','attributes','merge','stack','limit','body','model','OpenchannelQueueReport','pick','rows','../../components/parsers/qs','key','name','update','map','lodash','findOne'];(function(_0x1cb988,_0x5b4dd9){const _0x14cb73=function(_0x3c0475){while(--_0x3c0475){_0x1cb988['push'](_0x1cb988['shift']());}};_0x14cb73(++_0x5b4dd9);}(a501_0x5b4d,0xd3));const a501_0x14cb=function(_0x1cb988,_0x5b4dd9){_0x1cb988=_0x1cb988-0x0;let _0x14cb73=a501_0x5b4d[_0x1cb988];return _0x14cb73;};const _0xb8fc4=a501_0x14cb;'use strict';const _=require(_0xb8fc4('0x7')),qs=require(_0xb8fc4('0x2')),logger=require(_0xb8fc4('0xe'))(_0xb8fc4('0x27')),db=require(_0xb8fc4('0x29'))['db'],{Op}=require(_0xb8fc4('0x22'));function respondWithResult(_0x3c0475,_0x4eef4d){return _0x4eef4d=_0x4eef4d||0xc8,function(_0x3f3d64){const _0x37a02f=a501_0x14cb;if(_0x3f3d64)return _0x3c0475['status'](_0x4eef4d)[_0x37a02f('0x2a')](_0x3f3d64);};}function respondWithFilteredResult(_0x58b172,_0x1e4b31){return function(_0x3a162b){const _0x58cbc9=a501_0x14cb;if(_0x3a162b){const _0x3ba917=_0x3a162b['count'],_0xb239d9=_0x1e4b31[_0x58cbc9('0xf')];let _0x1e20b5=_0x1e4b31[_0x58cbc9('0xf')]+_0x1e4b31[_0x58cbc9('0x33')],_0x17e5d8;return _0x1e20b5>=_0x3ba917?(_0x1e20b5=_0x3ba917,_0x17e5d8=0xc8):_0x17e5d8=0xce,_0x58b172[_0x58cbc9('0xd')](_0x17e5d8),_0x58b172[_0x58cbc9('0x26')](_0x58cbc9('0x1f'),_0xb239d9+'-'+_0x1e20b5+'/'+_0x3ba917)[_0x58cbc9('0x2a')](_0x3a162b);}return null;};}function saveUpdates(_0x55b334){return function(_0xb90c93){const _0x360004=a501_0x14cb;if(_0xb90c93)return _0xb90c93[_0x360004('0x5')](_0x55b334)[_0x360004('0x1d')](function(_0x3339eb){return _0x3339eb;});return null;};}function removeEntity(_0x23ee8a){return function(_0xe6d034){const _0x5481dc=a501_0x14cb;if(_0xe6d034)return _0xe6d034[_0x5481dc('0x14')]()[_0x5481dc('0x1d')](function(){const _0x17c3cc=_0x5481dc;_0x23ee8a[_0x17c3cc('0xd')](0xcc)[_0x17c3cc('0xb')]();});};}function handleEntityNotFound(_0x4efb9f){return function(_0x646875){return!_0x646875&&_0x4efb9f['sendStatus'](0x194),_0x646875;};}function handleError(_0x1bfe7f,_0x4558eb){return _0x4558eb=_0x4558eb||0x1f4,function(_0xbbeda){const _0x3607d9=a501_0x14cb;logger[_0x3607d9('0x1b')](_0xbbeda[_0x3607d9('0x32')]),_0xbbeda[_0x3607d9('0x4')]&&delete _0xbbeda[_0x3607d9('0x4')],_0x1bfe7f[_0x3607d9('0xd')](_0x4558eb)[_0x3607d9('0x13')](_0xbbeda);};}exports[_0xb8fc4('0x1e')]=function(_0x20e285,_0x2dd578){const _0x414adf=_0xb8fc4;let _0x3375e5={};const _0x576704={},_0x266bd9={'count':0x0,'rows':[]},_0x2e2bc0=_[_0x414adf('0x6')](db[_0x414adf('0x36')][_0x414adf('0x12')],function(_0x5c4dba){const _0x27c5b4=_0x414adf;return{'name':_0x5c4dba['fieldName'],'type':_0x5c4dba[_0x27c5b4('0x20')][_0x27c5b4('0x3')]};});_0x576704[_0x414adf('0x35')]=_[_0x414adf('0x6')](_0x2e2bc0,_0x414adf('0x4')),_0x576704[_0x414adf('0x2d')]=_[_0x414adf('0x9')](_0x20e285[_0x414adf('0x2d')]),_0x576704[_0x414adf('0x2c')]=_[_0x414adf('0x2b')](_0x576704['model'],_0x576704[_0x414adf('0x2d')]),_0x3375e5['attributes']=_['intersection'](_0x576704[_0x414adf('0x35')],qs[_0x414adf('0xa')](_0x20e285[_0x414adf('0x2d')][_0x414adf('0xa')])),_0x3375e5[_0x414adf('0x30')]=_0x3375e5[_0x414adf('0x30')]['length']?_0x3375e5[_0x414adf('0x30')]:_0x576704[_0x414adf('0x35')];typeof _0x20e285[_0x414adf('0x2d')][_0x414adf('0x28')]==='undefined'&&(_0x3375e5['limit']=qs[_0x414adf('0x33')](_0x20e285['query'][_0x414adf('0x33')]),_0x3375e5['offset']=qs[_0x414adf('0xf')](_0x20e285[_0x414adf('0x2d')]['offset']));_0x3375e5[_0x414adf('0x2e')]=qs['sort'](_0x20e285[_0x414adf('0x2d')][_0x414adf('0x2f')]),_0x3375e5[_0x414adf('0x15')]=qs[_0x414adf('0x2c')](_[_0x414adf('0x0')](_0x20e285['query'],_0x576704[_0x414adf('0x2c')]),_0x2e2bc0);_0x20e285['query'][_0x414adf('0x24')]&&(_0x3375e5[_0x414adf('0x15')]=_[_0x414adf('0x31')](_0x3375e5[_0x414adf('0x15')],{[Op['or']]:_[_0x414adf('0x6')](_0x2e2bc0,function(_0x4b1507){const _0x1debbd=_0x414adf;if(_0x4b1507['type']!=='VIRTUAL'){const _0x4ffaa6={};return _0x4ffaa6[_0x4b1507[_0x1debbd('0x4')]]={[Op[_0x1debbd('0x1c')]]:'%'+_0x20e285['query']['filter']+'%'},_0x4ffaa6;}})}));_0x3375e5=_['merge']({},_0x3375e5,_0x20e285['options']);const _0x5c8a18={'where':_0x3375e5[_0x414adf('0x15')]};return db['OpenchannelQueueReport']['count'](_0x5c8a18)[_0x414adf('0x1d')](function(_0x16ddfc){const _0x49dbe1=_0x414adf;return _0x266bd9[_0x49dbe1('0x23')]=_0x16ddfc,_0x20e285['query']['includeAll']&&(_0x3375e5[_0x49dbe1('0x21')]=[{'all':!![]}]),db[_0x49dbe1('0x36')][_0x49dbe1('0x10')](_0x3375e5);})[_0x414adf('0x1d')](function(_0x4cdd7f){const _0x1bba9d=_0x414adf;return _0x266bd9[_0x1bba9d('0x1')]=_0x4cdd7f,_0x266bd9;})[_0x414adf('0x1d')](respondWithFilteredResult(_0x2dd578,_0x3375e5))['catch'](handleError(_0x2dd578,null));},exports[_0xb8fc4('0xc')]=function(_0x1c3e9f,_0x5d2039){const _0x442ffc=_0xb8fc4;let _0x791b0d={'raw':!![],'where':{'id':_0x1c3e9f[_0x442ffc('0x18')]['id']}};const _0x30ec08={};return _0x30ec08['model']=_[_0x442ffc('0x9')](db[_0x442ffc('0x36')]['rawAttributes']),_0x30ec08[_0x442ffc('0x2d')]=_[_0x442ffc('0x9')](_0x1c3e9f[_0x442ffc('0x2d')]),_0x30ec08[_0x442ffc('0x2c')]=_[_0x442ffc('0x2b')](_0x30ec08[_0x442ffc('0x35')],_0x30ec08[_0x442ffc('0x2d')]),_0x791b0d[_0x442ffc('0x30')]=_[_0x442ffc('0x2b')](_0x30ec08['model'],qs['fields'](_0x1c3e9f['query'][_0x442ffc('0xa')])),_0x791b0d[_0x442ffc('0x30')]=_0x791b0d[_0x442ffc('0x30')][_0x442ffc('0x25')]?_0x791b0d[_0x442ffc('0x30')]:_0x30ec08[_0x442ffc('0x35')],_0x1c3e9f[_0x442ffc('0x2d')][_0x442ffc('0x1a')]&&(_0x791b0d['include']=[{'all':!![]}]),_0x791b0d=_[_0x442ffc('0x31')]({},_0x791b0d,_0x1c3e9f[_0x442ffc('0x17')]),db[_0x442ffc('0x36')][_0x442ffc('0x8')](_0x791b0d)[_0x442ffc('0x1d')](handleEntityNotFound(_0x5d2039,null))[_0x442ffc('0x1d')](respondWithResult(_0x5d2039,null))['catch'](handleError(_0x5d2039,null));},exports[_0xb8fc4('0x11')]=function(_0x3491db,_0x262ea4){const _0x5ca07b=_0xb8fc4;return db['OpenchannelQueueReport'][_0x5ca07b('0x11')](_0x3491db[_0x5ca07b('0x34')],{})['then'](respondWithResult(_0x262ea4,0xc9))[_0x5ca07b('0x19')](handleError(_0x262ea4,null));},exports[_0xb8fc4('0x5')]=function(_0x4a2c75,_0x46256b){const _0x1f7219=_0xb8fc4;return _0x4a2c75['body']['id']&&delete _0x4a2c75[_0x1f7219('0x34')]['id'],db[_0x1f7219('0x36')]['findOne']({'where':{'id':_0x4a2c75[_0x1f7219('0x18')]['id']}})[_0x1f7219('0x1d')](handleEntityNotFound(_0x46256b,null))[_0x1f7219('0x1d')](saveUpdates(_0x4a2c75['body'],null))['then'](respondWithResult(_0x46256b,null))[_0x1f7219('0x19')](handleError(_0x46256b,null));},exports[_0xb8fc4('0x14')]=function(_0x4d63e5,_0x19cd24){const _0xd2dd71=_0xb8fc4;return db[_0xd2dd71('0x36')]['findOne']({'where':{'id':_0x4d63e5['params']['id']}})[_0xd2dd71('0x1d')](handleEntityNotFound(_0x19cd24,null))[_0xd2dd71('0x1d')](removeEntity(_0x19cd24,null))[_0xd2dd71('0x19')](handleError(_0x19cd24,null));},exports[_0xb8fc4('0x16')]=function(_0x1c631f,_0x287ee0){const _0x249dd0=_0xb8fc4;return db[_0x249dd0('0x36')][_0x249dd0('0x16')]()['then'](respondWithResult(_0x287ee0,null))[_0x249dd0('0x19')](handleError(_0x287ee0,null));}; \ No newline at end of file diff --git a/server/api/openchannelQueueReport/openchannelQueueReport.model.js b/server/api/openchannelQueueReport/openchannelQueueReport.model.js index 41ccd12..57f0c53 100644 --- a/server/api/openchannelQueueReport/openchannelQueueReport.model.js +++ b/server/api/openchannelQueueReport/openchannelQueueReport.model.js @@ -1 +1 @@ -const a502_0x81bc=['OpenchannelQueueReport','./openchannelQueueReport.attributes','report_openchannel_queue','exports','define','uniqueid'];(function(_0x21e755,_0x81bc6c){const _0x1f4fc9=function(_0x10a762){while(--_0x10a762){_0x21e755['push'](_0x21e755['shift']());}};_0x1f4fc9(++_0x81bc6c);}(a502_0x81bc,0x1b4));const a502_0x1f4f=function(_0x21e755,_0x81bc6c){_0x21e755=_0x21e755-0x0;let _0x1f4fc9=a502_0x81bc[_0x21e755];return _0x1f4fc9;};const _0x5a4ae7=a502_0x1f4f;'use strict';const attributes=require(_0x5a4ae7('0x3'));module[_0x5a4ae7('0x5')]=function(_0x10a762){const _0xf4908e=_0x5a4ae7,_0x6c3f2b=_0x10a762[_0xf4908e('0x0')](_0xf4908e('0x2'),attributes,{'tableName':_0xf4908e('0x4'),'paranoid':![],'indexes':[{'name':_0xf4908e('0x1'),'fields':[_0xf4908e('0x1')]}],'timestamps':!![]});return _0x6c3f2b;}; \ No newline at end of file +const a502_0x54ab=['./openchannelQueueReport.attributes','exports','OpenchannelQueueReport','uniqueid','define'];(function(_0x51d92d,_0x54ab1c){const _0x47e20b=function(_0x13c1bd){while(--_0x13c1bd){_0x51d92d['push'](_0x51d92d['shift']());}};_0x47e20b(++_0x54ab1c);}(a502_0x54ab,0x6d));const a502_0x47e2=function(_0x51d92d,_0x54ab1c){_0x51d92d=_0x51d92d-0x0;let _0x47e20b=a502_0x54ab[_0x51d92d];return _0x47e20b;};const _0x348af6=a502_0x47e2;'use strict';const attributes=require(_0x348af6('0x1'));module[_0x348af6('0x2')]=function(_0x13c1bd){const _0x571943=_0x348af6,_0x389746=_0x13c1bd[_0x571943('0x0')](_0x571943('0x3'),attributes,{'tableName':'report_openchannel_queue','paranoid':![],'indexes':[{'name':'uniqueid','fields':[_0x571943('0x4')]}],'timestamps':!![]});return _0x389746;}; \ No newline at end of file diff --git a/server/api/openchannelQueueReport/openchannelQueueReport.rpc.js b/server/api/openchannelQueueReport/openchannelQueueReport.rpc.js index 99a593c..27345fc 100644 --- a/server/api/openchannelQueueReport/openchannelQueueReport.rpc.js +++ b/server/api/openchannelQueueReport/openchannelQueueReport.rpc.js @@ -1 +1 @@ -const a503_0x4209=['options','info','attributes','debug','CreateOpenchannelQueueReport','../../config/logger','body','../../mysqldb','then','OpenchannelQueueReport','error','stringify','raw','message','catch','limit','UpdateOpenchannelQueueReport','where','update'];(function(_0x589a59,_0x4209e8){const _0x3947eb=function(_0x1c0726){while(--_0x1c0726){_0x589a59['push'](_0x589a59['shift']());}};_0x3947eb(++_0x4209e8);}(a503_0x4209,0x1b3));const a503_0x3947=function(_0x589a59,_0x4209e8){_0x589a59=_0x589a59-0x0;let _0x3947eb=a503_0x4209[_0x589a59];return _0x3947eb;};const _0x154337=a503_0x3947;'use strict';const db=require(_0x154337('0x9'))['db'],logger=require(_0x154337('0x7'))('rpc');exports[_0x154337('0x6')]=function(_0x1c0726){const _0x65ee06=this;return new Promise(function(_0x5a6de9,_0x363e69){const _0xaba599=a503_0x3947;return db[_0xaba599('0xb')]['create'](_0x1c0726[_0xaba599('0x8')],{'raw':_0x1c0726[_0xaba599('0x2')]?_0x1c0726['options'][_0xaba599('0xe')]===undefined?!![]:![]:!![]})['then'](function(_0x34b876){const _0x564bff=_0xaba599;logger[_0x564bff('0x3')](_0x564bff('0x6'),_0x1c0726),logger[_0x564bff('0x5')](_0x564bff('0x6'),_0x1c0726,JSON['stringify'](_0x34b876)),_0x5a6de9(_0x34b876);})['catch'](function(_0x516db6){const _0x3b17dd=_0xaba599;logger[_0x3b17dd('0xc')]('CreateOpenchannelQueueReport',_0x516db6['message'],_0x1c0726),_0x363e69(_0x65ee06[_0x3b17dd('0xc')](0x1f4,_0x516db6['message']));});});},exports[_0x154337('0x12')]=function(_0x5340aa){const _0x5a5c92=this;return new Promise(function(_0x23bebe,_0x56ec16){const _0x9355ef=a503_0x3947;return db[_0x9355ef('0xb')][_0x9355ef('0x1')](_0x5340aa[_0x9355ef('0x8')],{'raw':_0x5340aa[_0x9355ef('0x2')]?_0x5340aa[_0x9355ef('0x2')][_0x9355ef('0xe')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x5340aa['options']?_0x5340aa[_0x9355ef('0x2')][_0x9355ef('0x0')]||null:null,'attributes':_0x5340aa[_0x9355ef('0x2')]?_0x5340aa['options'][_0x9355ef('0x4')]||null:null,'limit':_0x5340aa[_0x9355ef('0x2')]?_0x5340aa['options'][_0x9355ef('0x11')]||null:null})[_0x9355ef('0xa')](function(_0x2780cf){const _0x2679fb=_0x9355ef;logger['info'](_0x2679fb('0x12'),_0x5340aa),logger[_0x2679fb('0x5')]('UpdateOpenchannelQueueReport',_0x5340aa,JSON[_0x2679fb('0xd')](_0x2780cf)),_0x23bebe(_0x2780cf);})[_0x9355ef('0x10')](function(_0x3d3120){const _0x444774=_0x9355ef;logger['error'](_0x444774('0x12'),_0x3d3120[_0x444774('0xf')],_0x5340aa),_0x56ec16(_0x5a5c92[_0x444774('0xc')](0x1f4,_0x3d3120['message']));});});}; \ No newline at end of file +const a503_0x4a8b=['raw','CreateOpenchannelQueueReport','info','update','OpenchannelQueueReport','debug','then','../../mysqldb','UpdateOpenchannelQueueReport','create','message','limit','stringify','../../config/logger','body','options','error','catch','attributes','where'];(function(_0x1ced75,_0x4a8b69){const _0xafd036=function(_0x22c63e){while(--_0x22c63e){_0x1ced75['push'](_0x1ced75['shift']());}};_0xafd036(++_0x4a8b69);}(a503_0x4a8b,0xcf));const a503_0xafd0=function(_0x1ced75,_0x4a8b69){_0x1ced75=_0x1ced75-0x0;let _0xafd036=a503_0x4a8b[_0x1ced75];return _0xafd036;};const _0x98a74f=a503_0xafd0;'use strict';const db=require(_0x98a74f('0x0'))['db'],logger=require(_0x98a74f('0x6'))('rpc');exports[_0x98a74f('0xe')]=function(_0x22c63e){const _0x2ddae6=this;return new Promise(function(_0x594513,_0x58aad3){const _0x274373=a503_0xafd0;return db[_0x274373('0x11')][_0x274373('0x2')](_0x22c63e[_0x274373('0x7')],{'raw':_0x22c63e['options']?_0x22c63e[_0x274373('0x8')][_0x274373('0xd')]===undefined?!![]:![]:!![]})['then'](function(_0x1b8d3e){const _0x265b40=_0x274373;logger[_0x265b40('0xf')](_0x265b40('0xe'),_0x22c63e),logger['debug'](_0x265b40('0xe'),_0x22c63e,JSON['stringify'](_0x1b8d3e)),_0x594513(_0x1b8d3e);})[_0x274373('0xa')](function(_0x31f85b){const _0x2d7ba3=_0x274373;logger['error'](_0x2d7ba3('0xe'),_0x31f85b[_0x2d7ba3('0x3')],_0x22c63e),_0x58aad3(_0x2ddae6[_0x2d7ba3('0x9')](0x1f4,_0x31f85b['message']));});});},exports[_0x98a74f('0x1')]=function(_0x50aefa){const _0x2394ce=this;return new Promise(function(_0x305c09,_0x5163a2){const _0x42f010=a503_0xafd0;return db[_0x42f010('0x11')][_0x42f010('0x10')](_0x50aefa['body'],{'raw':_0x50aefa[_0x42f010('0x8')]?_0x50aefa[_0x42f010('0x8')][_0x42f010('0xd')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x50aefa[_0x42f010('0x8')]?_0x50aefa[_0x42f010('0x8')][_0x42f010('0xc')]||null:null,'attributes':_0x50aefa['options']?_0x50aefa[_0x42f010('0x8')][_0x42f010('0xb')]||null:null,'limit':_0x50aefa[_0x42f010('0x8')]?_0x50aefa[_0x42f010('0x8')][_0x42f010('0x4')]||null:null})[_0x42f010('0x13')](function(_0x475ef7){const _0x3695d5=_0x42f010;logger[_0x3695d5('0xf')](_0x3695d5('0x1'),_0x50aefa),logger[_0x3695d5('0x12')](_0x3695d5('0x1'),_0x50aefa,JSON[_0x3695d5('0x5')](_0x475ef7)),_0x305c09(_0x475ef7);})['catch'](function(_0x446200){const _0x575d2c=_0x42f010;logger['error'](_0x575d2c('0x1'),_0x446200['message'],_0x50aefa),_0x5163a2(_0x2394ce['error'](0x1f4,_0x446200['message']));});});}; \ No newline at end of file diff --git a/server/api/openchannelTransferReport/index.js b/server/api/openchannelTransferReport/index.js index 551a04c..fb2daeb 100644 --- a/server/api/openchannelTransferReport/index.js +++ b/server/api/openchannelTransferReport/index.js @@ -1 +1 @@ -const a504_0x3d6a=['../../components/auth/service','exports','get','post','Router','/:id','delete','/describe','index','isAuthenticated','update','create'];(function(_0x375395,_0x3d6a38){const _0x41acb6=function(_0x522046){while(--_0x522046){_0x375395['push'](_0x375395['shift']());}};_0x41acb6(++_0x3d6a38);}(a504_0x3d6a,0x116));const a504_0x41ac=function(_0x375395,_0x3d6a38){_0x375395=_0x375395-0x0;let _0x41acb6=a504_0x3d6a[_0x375395];return _0x41acb6;};const _0x2b5cb9=a504_0x41ac;'use strict';const express=require('express'),router=express[_0x2b5cb9('0x2')](),auth=require(_0x2b5cb9('0xa')),controller=require('./openchannelTransferReport.controller');router[_0x2b5cb9('0x0')]('/',auth[_0x2b5cb9('0x7')](),controller[_0x2b5cb9('0x6')]),router[_0x2b5cb9('0x0')](_0x2b5cb9('0x5'),auth[_0x2b5cb9('0x7')](),controller['describe']),router['get'](_0x2b5cb9('0x3'),auth[_0x2b5cb9('0x7')](),controller['show']),router[_0x2b5cb9('0x1')]('/',auth[_0x2b5cb9('0x7')](),controller[_0x2b5cb9('0x9')]),router['put'](_0x2b5cb9('0x3'),auth[_0x2b5cb9('0x7')](),controller[_0x2b5cb9('0x8')]),router[_0x2b5cb9('0x4')]('/:id',auth['isAuthenticated'](),controller['destroy']),module[_0x2b5cb9('0xb')]=router; \ No newline at end of file +const a504_0x4aee=['get','put','../../components/auth/service','exports','/:id','Router','show','/describe','delete','./openchannelTransferReport.controller','express','destroy','post','isAuthenticated'];(function(_0x1569d0,_0x4aee3b){const _0x57b183=function(_0x445304){while(--_0x445304){_0x1569d0['push'](_0x1569d0['shift']());}};_0x57b183(++_0x4aee3b);}(a504_0x4aee,0xe7));const a504_0x57b1=function(_0x1569d0,_0x4aee3b){_0x1569d0=_0x1569d0-0x0;let _0x57b183=a504_0x4aee[_0x1569d0];return _0x57b183;};const _0x1a2e7f=a504_0x57b1;'use strict';const express=require(_0x1a2e7f('0x3')),router=express[_0x1a2e7f('0xc')](),auth=require(_0x1a2e7f('0x9')),controller=require(_0x1a2e7f('0x2'));router[_0x1a2e7f('0x7')]('/',auth[_0x1a2e7f('0x6')](),controller['index']),router['get'](_0x1a2e7f('0x0'),auth[_0x1a2e7f('0x6')](),controller['describe']),router[_0x1a2e7f('0x7')](_0x1a2e7f('0xb'),auth[_0x1a2e7f('0x6')](),controller[_0x1a2e7f('0xd')]),router[_0x1a2e7f('0x5')]('/',auth[_0x1a2e7f('0x6')](),controller['create']),router[_0x1a2e7f('0x8')](_0x1a2e7f('0xb'),auth[_0x1a2e7f('0x6')](),controller['update']),router[_0x1a2e7f('0x1')](_0x1a2e7f('0xb'),auth[_0x1a2e7f('0x6')](),controller[_0x1a2e7f('0x4')]),module[_0x1a2e7f('0xa')]=router; \ No newline at end of file diff --git a/server/api/openchannelTransferReport/openchannelTransferReport.attributes.js b/server/api/openchannelTransferReport/openchannelTransferReport.attributes.js index 5f1fed3..03a2f57 100644 --- a/server/api/openchannelTransferReport/openchannelTransferReport.attributes.js +++ b/server/api/openchannelTransferReport/openchannelTransferReport.attributes.js @@ -1 +1 @@ -const a505_0x54fc=['DATE','account','STRING','sequelize','NOW','ENUM','exports','queue','agent'];(function(_0x4ceac3,_0x54fcd1){const _0x2d8a75=function(_0xa9039e){while(--_0xa9039e){_0x4ceac3['push'](_0x4ceac3['shift']());}};_0x2d8a75(++_0x54fcd1);}(a505_0x54fc,0x1ad));const a505_0x2d8a=function(_0x4ceac3,_0x54fcd1){_0x4ceac3=_0x4ceac3-0x0;let _0x2d8a75=a505_0x54fc[_0x4ceac3];return _0x2d8a75;};const _0x2941d9=a505_0x2d8a;'use strict';const Sequelize=require(_0x2941d9('0x6'));module[_0x2941d9('0x0')]={'uniqueid':{'type':Sequelize[_0x2941d9('0x5')],'allowNull':![]},'type':{'type':Sequelize[_0x2941d9('0x8')](_0x2941d9('0x4'),_0x2941d9('0x2'),_0x2941d9('0x1')),'allowNull':![],'defaultValue':_0x2941d9('0x1')},'transferredAt':{'type':Sequelize[_0x2941d9('0x3')],'allowNull':![],'defaultValue':Sequelize[_0x2941d9('0x7')]}}; \ No newline at end of file +const a505_0x4aa6=['queue','DATE','agent','STRING','account','sequelize','ENUM'];(function(_0x1019d7,_0x4aa63f){const _0x9fe038=function(_0x143814){while(--_0x143814){_0x1019d7['push'](_0x1019d7['shift']());}};_0x9fe038(++_0x4aa63f);}(a505_0x4aa6,0x129));const a505_0x9fe0=function(_0x1019d7,_0x4aa63f){_0x1019d7=_0x1019d7-0x0;let _0x9fe038=a505_0x4aa6[_0x1019d7];return _0x9fe038;};const _0x350779=a505_0x9fe0;'use strict';const Sequelize=require(_0x350779('0x2'));module['exports']={'uniqueid':{'type':Sequelize[_0x350779('0x0')],'allowNull':![]},'type':{'type':Sequelize[_0x350779('0x3')](_0x350779('0x1'),_0x350779('0x6'),_0x350779('0x4')),'allowNull':![],'defaultValue':_0x350779('0x4')},'transferredAt':{'type':Sequelize[_0x350779('0x5')],'allowNull':![],'defaultValue':Sequelize['NOW']}}; \ No newline at end of file diff --git a/server/api/openchannelTransferReport/openchannelTransferReport.controller.js b/server/api/openchannelTransferReport/openchannelTransferReport.controller.js index 2bef50b..af6dfe7 100644 --- a/server/api/openchannelTransferReport/openchannelTransferReport.controller.js +++ b/server/api/openchannelTransferReport/openchannelTransferReport.controller.js @@ -1 +1 @@ -const a506_0x5719=['nolimit','offset','attributes','key','status','sort','index','../../components/parsers/qs','error','query','keys','order','create','limit','catch','set','Content-Range','destroy','rawAttributes','body','params','type','length','intersection','include','map','options','../../mysqldb','merge','json','describe','where','name','update','undefined','findOne','api','OpenchannelTransferReport','fields','filter','model','pick','then','filters','includeAll','count','VIRTUAL','sendStatus','send'];(function(_0x51832a,_0x57190e){const _0x28885a=function(_0x118b22){while(--_0x118b22){_0x51832a['push'](_0x51832a['shift']());}};_0x28885a(++_0x57190e);}(a506_0x5719,0x153));const a506_0x2888=function(_0x51832a,_0x57190e){_0x51832a=_0x51832a-0x0;let _0x28885a=a506_0x5719[_0x51832a];return _0x28885a;};const _0x31a194=a506_0x2888;'use strict';const _=require('lodash'),qs=require(_0x31a194('0xb')),logger=require('../../config/logger')(_0x31a194('0x28')),db=require(_0x31a194('0x1f'))['db'],{Op}=require('sequelize');function respondWithResult(_0x118b22,_0x3b6ef5){return _0x3b6ef5=_0x3b6ef5||0xc8,function(_0x170a74){const _0x3bc8be=a506_0x2888;if(_0x170a74)return _0x118b22[_0x3bc8be('0x8')](_0x3b6ef5)[_0x3bc8be('0x21')](_0x170a74);};}function respondWithFilteredResult(_0x15f46e,_0x48b729){return function(_0x25f751){const _0x4a4756=a506_0x2888;if(_0x25f751){const _0x4da534=_0x25f751[_0x4a4756('0x0')],_0x82a4bb=_0x48b729[_0x4a4756('0x5')];let _0x52973a=_0x48b729[_0x4a4756('0x5')]+_0x48b729[_0x4a4756('0x11')],_0x156795;return _0x52973a>=_0x4da534?(_0x52973a=_0x4da534,_0x156795=0xc8):_0x156795=0xce,_0x15f46e[_0x4a4756('0x8')](_0x156795),_0x15f46e[_0x4a4756('0x13')](_0x4a4756('0x14'),_0x82a4bb+'-'+_0x52973a+'/'+_0x4da534)[_0x4a4756('0x21')](_0x25f751);}return null;};}function saveUpdates(_0x8cf146){return function(_0x21e24a){const _0x6fcdd=a506_0x2888;if(_0x21e24a)return _0x21e24a[_0x6fcdd('0x25')](_0x8cf146)[_0x6fcdd('0x2e')](function(_0xe73bd2){return _0xe73bd2;});return null;};}function removeEntity(_0x45f87c){return function(_0x36151a){if(_0x36151a)return _0x36151a['destroy']()['then'](function(){_0x45f87c['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x1bd2bf){return function(_0x22285e){const _0x16d7e5=a506_0x2888;return!_0x22285e&&_0x1bd2bf[_0x16d7e5('0x2')](0x194),_0x22285e;};}function handleError(_0x1b06e5,_0x4538e0){return _0x4538e0=_0x4538e0||0x1f4,function(_0x5f42c7){const _0xc3a7d4=a506_0x2888;logger[_0xc3a7d4('0xc')](_0x5f42c7['stack']),_0x5f42c7[_0xc3a7d4('0x24')]&&delete _0x5f42c7['name'],_0x1b06e5[_0xc3a7d4('0x8')](_0x4538e0)[_0xc3a7d4('0x3')](_0x5f42c7);};}exports[_0x31a194('0xa')]=function(_0x2c01fe,_0x1885de){const _0x1fdd19=_0x31a194;let _0x2e2422={};const _0x237689={},_0x24af34={'count':0x0,'rows':[]},_0x4f7047=_[_0x1fdd19('0x1d')](db[_0x1fdd19('0x29')]['rawAttributes'],function(_0x27e3e5){const _0x17b198=_0x1fdd19;return{'name':_0x27e3e5['fieldName'],'type':_0x27e3e5[_0x17b198('0x19')][_0x17b198('0x7')]};});_0x237689['model']=_[_0x1fdd19('0x1d')](_0x4f7047,'name'),_0x237689['query']=_[_0x1fdd19('0xe')](_0x2c01fe[_0x1fdd19('0xd')]),_0x237689[_0x1fdd19('0x2f')]=_[_0x1fdd19('0x1b')](_0x237689[_0x1fdd19('0x2c')],_0x237689[_0x1fdd19('0xd')]),_0x2e2422[_0x1fdd19('0x6')]=_[_0x1fdd19('0x1b')](_0x237689['model'],qs[_0x1fdd19('0x2a')](_0x2c01fe[_0x1fdd19('0xd')][_0x1fdd19('0x2a')])),_0x2e2422[_0x1fdd19('0x6')]=_0x2e2422[_0x1fdd19('0x6')][_0x1fdd19('0x1a')]?_0x2e2422[_0x1fdd19('0x6')]:_0x237689[_0x1fdd19('0x2c')];typeof _0x2c01fe[_0x1fdd19('0xd')][_0x1fdd19('0x4')]===_0x1fdd19('0x26')&&(_0x2e2422[_0x1fdd19('0x11')]=qs[_0x1fdd19('0x11')](_0x2c01fe[_0x1fdd19('0xd')][_0x1fdd19('0x11')]),_0x2e2422[_0x1fdd19('0x5')]=qs['offset'](_0x2c01fe[_0x1fdd19('0xd')][_0x1fdd19('0x5')]));_0x2e2422[_0x1fdd19('0xf')]=qs['sort'](_0x2c01fe[_0x1fdd19('0xd')][_0x1fdd19('0x9')]),_0x2e2422['where']=qs['filters'](_[_0x1fdd19('0x2d')](_0x2c01fe[_0x1fdd19('0xd')],_0x237689['filters']),_0x4f7047);_0x2c01fe['query'][_0x1fdd19('0x2b')]&&(_0x2e2422[_0x1fdd19('0x23')]=_[_0x1fdd19('0x20')](_0x2e2422[_0x1fdd19('0x23')],{[Op['or']]:_[_0x1fdd19('0x1d')](_0x4f7047,function(_0x3ea0fd){const _0x1e4267=_0x1fdd19;if(_0x3ea0fd[_0x1e4267('0x19')]!==_0x1e4267('0x1')){const _0x5adf51={};return _0x5adf51[_0x3ea0fd[_0x1e4267('0x24')]]={[Op['like']]:'%'+_0x2c01fe[_0x1e4267('0xd')][_0x1e4267('0x2b')]+'%'},_0x5adf51;}})}));_0x2e2422=_[_0x1fdd19('0x20')]({},_0x2e2422,_0x2c01fe[_0x1fdd19('0x1e')]);const _0x4becd5={'where':_0x2e2422[_0x1fdd19('0x23')]};return db[_0x1fdd19('0x29')]['count'](_0x4becd5)[_0x1fdd19('0x2e')](function(_0x5e0d17){const _0x186e76=_0x1fdd19;return _0x24af34['count']=_0x5e0d17,_0x2c01fe[_0x186e76('0xd')]['includeAll']&&(_0x2e2422[_0x186e76('0x1c')]=[{'all':!![]}]),db[_0x186e76('0x29')]['findAll'](_0x2e2422);})[_0x1fdd19('0x2e')](function(_0xca47d9){return _0x24af34['rows']=_0xca47d9,_0x24af34;})['then'](respondWithFilteredResult(_0x1885de,_0x2e2422))['catch'](handleError(_0x1885de,null));},exports['show']=function(_0x4f098c,_0x2a71f2){const _0x5ca5a5=_0x31a194;let _0x2ae15b={'raw':!![],'where':{'id':_0x4f098c[_0x5ca5a5('0x18')]['id']}};const _0xfea11a={};return _0xfea11a[_0x5ca5a5('0x2c')]=_['keys'](db[_0x5ca5a5('0x29')][_0x5ca5a5('0x16')]),_0xfea11a[_0x5ca5a5('0xd')]=_['keys'](_0x4f098c['query']),_0xfea11a[_0x5ca5a5('0x2f')]=_['intersection'](_0xfea11a[_0x5ca5a5('0x2c')],_0xfea11a[_0x5ca5a5('0xd')]),_0x2ae15b[_0x5ca5a5('0x6')]=_['intersection'](_0xfea11a['model'],qs[_0x5ca5a5('0x2a')](_0x4f098c[_0x5ca5a5('0xd')]['fields'])),_0x2ae15b[_0x5ca5a5('0x6')]=_0x2ae15b[_0x5ca5a5('0x6')][_0x5ca5a5('0x1a')]?_0x2ae15b[_0x5ca5a5('0x6')]:_0xfea11a[_0x5ca5a5('0x2c')],_0x4f098c[_0x5ca5a5('0xd')][_0x5ca5a5('0x30')]&&(_0x2ae15b[_0x5ca5a5('0x1c')]=[{'all':!![]}]),_0x2ae15b=_[_0x5ca5a5('0x20')]({},_0x2ae15b,_0x4f098c[_0x5ca5a5('0x1e')]),db['OpenchannelTransferReport'][_0x5ca5a5('0x27')](_0x2ae15b)[_0x5ca5a5('0x2e')](handleEntityNotFound(_0x2a71f2,null))[_0x5ca5a5('0x2e')](respondWithResult(_0x2a71f2,null))['catch'](handleError(_0x2a71f2,null));},exports[_0x31a194('0x10')]=function(_0x52db38,_0x49edd0){const _0x412554=_0x31a194;return db[_0x412554('0x29')][_0x412554('0x10')](_0x52db38[_0x412554('0x17')],{})[_0x412554('0x2e')](respondWithResult(_0x49edd0,0xc9))['catch'](handleError(_0x49edd0,null));},exports[_0x31a194('0x25')]=function(_0x4646f5,_0x4c9687){const _0x3dfeac=_0x31a194;return _0x4646f5[_0x3dfeac('0x17')]['id']&&delete _0x4646f5['body']['id'],db['OpenchannelTransferReport']['findOne']({'where':{'id':_0x4646f5[_0x3dfeac('0x18')]['id']}})[_0x3dfeac('0x2e')](handleEntityNotFound(_0x4c9687,null))['then'](saveUpdates(_0x4646f5[_0x3dfeac('0x17')],null))[_0x3dfeac('0x2e')](respondWithResult(_0x4c9687,null))[_0x3dfeac('0x12')](handleError(_0x4c9687,null));},exports[_0x31a194('0x15')]=function(_0x42f733,_0x44691c){const _0x79c9b0=_0x31a194;return db[_0x79c9b0('0x29')]['findOne']({'where':{'id':_0x42f733[_0x79c9b0('0x18')]['id']}})[_0x79c9b0('0x2e')](handleEntityNotFound(_0x44691c,null))[_0x79c9b0('0x2e')](removeEntity(_0x44691c,null))[_0x79c9b0('0x12')](handleError(_0x44691c,null));},exports[_0x31a194('0x22')]=function(_0x4bcdc2,_0x48c289){const _0x4b056b=_0x31a194;return db[_0x4b056b('0x29')][_0x4b056b('0x22')]()[_0x4b056b('0x2e')](respondWithResult(_0x48c289,null))['catch'](handleError(_0x48c289,null));}; \ No newline at end of file +const a506_0x3335=['intersection','body','pick','name','VIRTUAL','offset','catch','where','sort','findOne','Content-Range','OpenchannelTransferReport','status','undefined','index','limit','../../config/logger','params','includeAll','lodash','../../mysqldb','create','model','count','destroy','attributes','json','key','filters','../../components/parsers/qs','length','fields','query','stack','like','map','update','keys','options','set','sequelize','show','describe','rawAttributes','sendStatus','type','then'];(function(_0x14d999,_0x333510){const _0x5f3c46=function(_0x2b8be9){while(--_0x2b8be9){_0x14d999['push'](_0x14d999['shift']());}};_0x5f3c46(++_0x333510);}(a506_0x3335,0x141));const a506_0x5f3c=function(_0x14d999,_0x333510){_0x14d999=_0x14d999-0x0;let _0x5f3c46=a506_0x3335[_0x14d999];return _0x5f3c46;};const _0xda1a64=a506_0x5f3c;'use strict';const _=require(_0xda1a64('0x1b')),qs=require(_0xda1a64('0x25')),logger=require(_0xda1a64('0x18'))('api'),db=require(_0xda1a64('0x1c'))['db'],{Op}=require(_0xda1a64('0x1'));function respondWithResult(_0x2b8be9,_0x4219b3){return _0x4219b3=_0x4219b3||0xc8,function(_0x49467d){const _0x1ec62e=a506_0x5f3c;if(_0x49467d)return _0x2b8be9[_0x1ec62e('0x14')](_0x4219b3)[_0x1ec62e('0x22')](_0x49467d);};}function respondWithFilteredResult(_0x13ec90,_0x7ca8f3){return function(_0x4b3cb1){const _0x4ea4d1=a506_0x5f3c;if(_0x4b3cb1){const _0xc0f17b=_0x4b3cb1[_0x4ea4d1('0x1f')],_0x335913=_0x7ca8f3['offset'];let _0x17c807=_0x7ca8f3['offset']+_0x7ca8f3['limit'],_0x453dee;return _0x17c807>=_0xc0f17b?(_0x17c807=_0xc0f17b,_0x453dee=0xc8):_0x453dee=0xce,_0x13ec90[_0x4ea4d1('0x14')](_0x453dee),_0x13ec90[_0x4ea4d1('0x0')](_0x4ea4d1('0x12'),_0x335913+'-'+_0x17c807+'/'+_0xc0f17b)[_0x4ea4d1('0x22')](_0x4b3cb1);}return null;};}function saveUpdates(_0x2c65df){return function(_0x4f622a){if(_0x4f622a)return _0x4f622a['update'](_0x2c65df)['then'](function(_0x2d51e1){return _0x2d51e1;});return null;};}function removeEntity(_0x43436b){return function(_0x3962b4){const _0x3820cf=a506_0x5f3c;if(_0x3962b4)return _0x3962b4[_0x3820cf('0x20')]()[_0x3820cf('0x7')](function(){const _0x459920=_0x3820cf;_0x43436b[_0x459920('0x14')](0xcc)['end']();});};}function handleEntityNotFound(_0x38beb5){return function(_0x2649f3){const _0x41393f=a506_0x5f3c;return!_0x2649f3&&_0x38beb5[_0x41393f('0x5')](0x194),_0x2649f3;};}function handleError(_0x3cec31,_0x56f406){return _0x56f406=_0x56f406||0x1f4,function(_0x94342){const _0x5aa262=a506_0x5f3c;logger['error'](_0x94342[_0x5aa262('0x29')]),_0x94342[_0x5aa262('0xb')]&&delete _0x94342[_0x5aa262('0xb')],_0x3cec31[_0x5aa262('0x14')](_0x56f406)['send'](_0x94342);};}exports[_0xda1a64('0x16')]=function(_0x11ad61,_0x1f15de){const _0x5507d1=_0xda1a64;let _0x343627={};const _0x2718dd={},_0xbaf20b={'count':0x0,'rows':[]},_0x1d2903=_['map'](db['OpenchannelTransferReport'][_0x5507d1('0x4')],function(_0x25901c){const _0x10bad4=_0x5507d1;return{'name':_0x25901c['fieldName'],'type':_0x25901c[_0x10bad4('0x6')][_0x10bad4('0x23')]};});_0x2718dd[_0x5507d1('0x1e')]=_['map'](_0x1d2903,_0x5507d1('0xb')),_0x2718dd[_0x5507d1('0x28')]=_['keys'](_0x11ad61[_0x5507d1('0x28')]),_0x2718dd[_0x5507d1('0x24')]=_[_0x5507d1('0x8')](_0x2718dd[_0x5507d1('0x1e')],_0x2718dd[_0x5507d1('0x28')]),_0x343627[_0x5507d1('0x21')]=_[_0x5507d1('0x8')](_0x2718dd[_0x5507d1('0x1e')],qs[_0x5507d1('0x27')](_0x11ad61[_0x5507d1('0x28')]['fields'])),_0x343627[_0x5507d1('0x21')]=_0x343627[_0x5507d1('0x21')][_0x5507d1('0x26')]?_0x343627[_0x5507d1('0x21')]:_0x2718dd[_0x5507d1('0x1e')];typeof _0x11ad61[_0x5507d1('0x28')]['nolimit']===_0x5507d1('0x15')&&(_0x343627[_0x5507d1('0x17')]=qs[_0x5507d1('0x17')](_0x11ad61[_0x5507d1('0x28')]['limit']),_0x343627['offset']=qs[_0x5507d1('0xd')](_0x11ad61[_0x5507d1('0x28')][_0x5507d1('0xd')]));_0x343627['order']=qs[_0x5507d1('0x10')](_0x11ad61[_0x5507d1('0x28')]['sort']),_0x343627[_0x5507d1('0xf')]=qs['filters'](_[_0x5507d1('0xa')](_0x11ad61[_0x5507d1('0x28')],_0x2718dd[_0x5507d1('0x24')]),_0x1d2903);_0x11ad61[_0x5507d1('0x28')]['filter']&&(_0x343627[_0x5507d1('0xf')]=_['merge'](_0x343627[_0x5507d1('0xf')],{[Op['or']]:_[_0x5507d1('0x2b')](_0x1d2903,function(_0x364d13){const _0x3d3772=_0x5507d1;if(_0x364d13[_0x3d3772('0x6')]!==_0x3d3772('0xc')){const _0x24fe80={};return _0x24fe80[_0x364d13[_0x3d3772('0xb')]]={[Op[_0x3d3772('0x2a')]]:'%'+_0x11ad61[_0x3d3772('0x28')]['filter']+'%'},_0x24fe80;}})}));_0x343627=_['merge']({},_0x343627,_0x11ad61[_0x5507d1('0x2e')]);const _0x5c6aea={'where':_0x343627[_0x5507d1('0xf')]};return db[_0x5507d1('0x13')]['count'](_0x5c6aea)[_0x5507d1('0x7')](function(_0x4cbcac){const _0xc02de1=_0x5507d1;return _0xbaf20b[_0xc02de1('0x1f')]=_0x4cbcac,_0x11ad61[_0xc02de1('0x28')][_0xc02de1('0x1a')]&&(_0x343627['include']=[{'all':!![]}]),db[_0xc02de1('0x13')]['findAll'](_0x343627);})['then'](function(_0x22055c){return _0xbaf20b['rows']=_0x22055c,_0xbaf20b;})[_0x5507d1('0x7')](respondWithFilteredResult(_0x1f15de,_0x343627))[_0x5507d1('0xe')](handleError(_0x1f15de,null));},exports[_0xda1a64('0x2')]=function(_0x5a1a8a,_0x304b54){const _0x482544=_0xda1a64;let _0x1e6fab={'raw':!![],'where':{'id':_0x5a1a8a[_0x482544('0x19')]['id']}};const _0x2aec48={};return _0x2aec48['model']=_[_0x482544('0x2d')](db['OpenchannelTransferReport'][_0x482544('0x4')]),_0x2aec48[_0x482544('0x28')]=_[_0x482544('0x2d')](_0x5a1a8a['query']),_0x2aec48[_0x482544('0x24')]=_[_0x482544('0x8')](_0x2aec48[_0x482544('0x1e')],_0x2aec48[_0x482544('0x28')]),_0x1e6fab[_0x482544('0x21')]=_['intersection'](_0x2aec48[_0x482544('0x1e')],qs[_0x482544('0x27')](_0x5a1a8a['query'][_0x482544('0x27')])),_0x1e6fab[_0x482544('0x21')]=_0x1e6fab[_0x482544('0x21')][_0x482544('0x26')]?_0x1e6fab[_0x482544('0x21')]:_0x2aec48[_0x482544('0x1e')],_0x5a1a8a['query'][_0x482544('0x1a')]&&(_0x1e6fab['include']=[{'all':!![]}]),_0x1e6fab=_['merge']({},_0x1e6fab,_0x5a1a8a[_0x482544('0x2e')]),db[_0x482544('0x13')][_0x482544('0x11')](_0x1e6fab)[_0x482544('0x7')](handleEntityNotFound(_0x304b54,null))['then'](respondWithResult(_0x304b54,null))[_0x482544('0xe')](handleError(_0x304b54,null));},exports['create']=function(_0x3cb1ea,_0x2cf073){const _0x42ec29=_0xda1a64;return db[_0x42ec29('0x13')][_0x42ec29('0x1d')](_0x3cb1ea[_0x42ec29('0x9')],{})[_0x42ec29('0x7')](respondWithResult(_0x2cf073,0xc9))[_0x42ec29('0xe')](handleError(_0x2cf073,null));},exports[_0xda1a64('0x2c')]=function(_0x186ee9,_0xff0585){const _0x46b891=_0xda1a64;return _0x186ee9[_0x46b891('0x9')]['id']&&delete _0x186ee9[_0x46b891('0x9')]['id'],db[_0x46b891('0x13')]['findOne']({'where':{'id':_0x186ee9['params']['id']}})['then'](handleEntityNotFound(_0xff0585,null))[_0x46b891('0x7')](saveUpdates(_0x186ee9[_0x46b891('0x9')],null))[_0x46b891('0x7')](respondWithResult(_0xff0585,null))[_0x46b891('0xe')](handleError(_0xff0585,null));},exports[_0xda1a64('0x20')]=function(_0x3a1e67,_0x3c0214){const _0xede5c8=_0xda1a64;return db[_0xede5c8('0x13')][_0xede5c8('0x11')]({'where':{'id':_0x3a1e67[_0xede5c8('0x19')]['id']}})[_0xede5c8('0x7')](handleEntityNotFound(_0x3c0214,null))[_0xede5c8('0x7')](removeEntity(_0x3c0214,null))[_0xede5c8('0xe')](handleError(_0x3c0214,null));},exports[_0xda1a64('0x3')]=function(_0xe6cb6f,_0x5b4afe){const _0x124fa6=_0xda1a64;return db[_0x124fa6('0x13')][_0x124fa6('0x3')]()['then'](respondWithResult(_0x5b4afe,null))[_0x124fa6('0xe')](handleError(_0x5b4afe,null));}; \ No newline at end of file diff --git a/server/api/openchannelTransferReport/openchannelTransferReport.model.js b/server/api/openchannelTransferReport/openchannelTransferReport.model.js index f59ff78..c6cb729 100644 --- a/server/api/openchannelTransferReport/openchannelTransferReport.model.js +++ b/server/api/openchannelTransferReport/openchannelTransferReport.model.js @@ -1 +1 @@ -const a507_0x5bf7=['report_openchannel_transfer','OpenchannelTransferReport','exports','uniqueid','./openchannelTransferReport.attributes'];(function(_0x290461,_0x5bf76e){const _0x59610e=function(_0x3019ff){while(--_0x3019ff){_0x290461['push'](_0x290461['shift']());}};_0x59610e(++_0x5bf76e);}(a507_0x5bf7,0xb6));const a507_0x5961=function(_0x290461,_0x5bf76e){_0x290461=_0x290461-0x0;let _0x59610e=a507_0x5bf7[_0x290461];return _0x59610e;};const _0x545b4e=a507_0x5961;'use strict';const attributes=require(_0x545b4e('0x2'));module[_0x545b4e('0x0')]=function(_0x3019ff){const _0x2e45a3=_0x545b4e,_0x5c7885=_0x3019ff['define'](_0x2e45a3('0x4'),attributes,{'tableName':_0x2e45a3('0x3'),'paranoid':![],'indexes':[{'name':_0x2e45a3('0x1'),'fields':[_0x2e45a3('0x1')]}],'timestamps':!![]});return _0x5c7885;}; \ No newline at end of file +const a507_0xaf72=['exports','define','uniqueid','OpenchannelTransferReport','report_openchannel_transfer'];(function(_0x328cc6,_0xaf7221){const _0x3760b4=function(_0x492682){while(--_0x492682){_0x328cc6['push'](_0x328cc6['shift']());}};_0x3760b4(++_0xaf7221);}(a507_0xaf72,0x1f0));const a507_0x3760=function(_0x328cc6,_0xaf7221){_0x328cc6=_0x328cc6-0x0;let _0x3760b4=a507_0xaf72[_0x328cc6];return _0x3760b4;};const _0x13eb75=a507_0x3760;'use strict';const attributes=require('./openchannelTransferReport.attributes');module[_0x13eb75('0x4')]=function(_0x492682){const _0x462532=_0x13eb75,_0x590cd4=_0x492682[_0x462532('0x0')](_0x462532('0x2'),attributes,{'tableName':_0x462532('0x3'),'paranoid':![],'indexes':[{'name':_0x462532('0x1'),'fields':[_0x462532('0x1')]}],'timestamps':!![]});return _0x590cd4;}; \ No newline at end of file diff --git a/server/api/pause/index.js b/server/api/pause/index.js index 632dbb5..3dde39b 100644 --- a/server/api/pause/index.js +++ b/server/api/pause/index.js @@ -1 +1 @@ -const a508_0x36d7=['update','express','./pause.controller','destroy','put','create','/:id','../../components/auth/service','index','Router','delete','exports','isAuthenticated','show','get'];(function(_0x91c5c6,_0x36d704){const _0xb116ae=function(_0x996724){while(--_0x996724){_0x91c5c6['push'](_0x91c5c6['shift']());}};_0xb116ae(++_0x36d704);}(a508_0x36d7,0x1c9));const a508_0xb116=function(_0x91c5c6,_0x36d704){_0x91c5c6=_0x91c5c6-0x0;let _0xb116ae=a508_0x36d7[_0x91c5c6];return _0xb116ae;};const _0x2e3557=a508_0xb116;'use strict';const express=require(_0x2e3557('0x9')),router=express[_0x2e3557('0x2')](),auth=require(_0x2e3557('0x0')),controller=require(_0x2e3557('0xa'));router[_0x2e3557('0x7')]('/',auth[_0x2e3557('0x5')](),controller[_0x2e3557('0x1')]),router[_0x2e3557('0x7')](_0x2e3557('0xe'),auth['isAuthenticated'](),controller[_0x2e3557('0x6')]),router['post']('/',auth[_0x2e3557('0x5')](),controller[_0x2e3557('0xd')]),router[_0x2e3557('0xc')](_0x2e3557('0xe'),auth[_0x2e3557('0x5')](),controller[_0x2e3557('0x8')]),router[_0x2e3557('0x3')](_0x2e3557('0xe'),auth[_0x2e3557('0x5')](),controller[_0x2e3557('0xb')]),module[_0x2e3557('0x4')]=router; \ No newline at end of file +const a508_0x3d23=['post','get','/:id','../../components/auth/service','exports','./pause.controller','destroy','index','update','isAuthenticated','show'];(function(_0x2ccb70,_0x3d2390){const _0x2ba923=function(_0x4be5bd){while(--_0x4be5bd){_0x2ccb70['push'](_0x2ccb70['shift']());}};_0x2ba923(++_0x3d2390);}(a508_0x3d23,0x134));const a508_0x2ba9=function(_0x2ccb70,_0x3d2390){_0x2ccb70=_0x2ccb70-0x0;let _0x2ba923=a508_0x3d23[_0x2ccb70];return _0x2ba923;};const _0x3376ab=a508_0x2ba9;'use strict';const express=require('express'),router=express['Router'](),auth=require(_0x3376ab('0x3')),controller=require(_0x3376ab('0x5'));router['get']('/',auth[_0x3376ab('0x9')](),controller[_0x3376ab('0x7')]),router[_0x3376ab('0x1')](_0x3376ab('0x2'),auth['isAuthenticated'](),controller[_0x3376ab('0xa')]),router[_0x3376ab('0x0')]('/',auth['isAuthenticated'](),controller['create']),router['put']('/:id',auth[_0x3376ab('0x9')](),controller[_0x3376ab('0x8')]),router['delete'](_0x3376ab('0x2'),auth['isAuthenticated'](),controller[_0x3376ab('0x6')]),module[_0x3376ab('0x4')]=router; \ No newline at end of file diff --git a/server/api/pause/pause.attributes.js b/server/api/pause/pause.attributes.js index a8f7e4c..ed1d819 100644 --- a/server/api/pause/pause.attributes.js +++ b/server/api/pause/pause.attributes.js @@ -1 +1 @@ -const a509_0x297b=['name','sequelize','STRING'];(function(_0x4509e2,_0x297bf0){const _0x24797f=function(_0x1655d5){while(--_0x1655d5){_0x4509e2['push'](_0x4509e2['shift']());}};_0x24797f(++_0x297bf0);}(a509_0x297b,0x1c5));const a509_0x2479=function(_0x4509e2,_0x297bf0){_0x4509e2=_0x4509e2-0x0;let _0x24797f=a509_0x297b[_0x4509e2];return _0x24797f;};const _0x388db2=a509_0x2479;'use strict';const Sequelize=require(_0x388db2('0x1'));module['exports']={'name':{'type':Sequelize[_0x388db2('0x2')],'unique':_0x388db2('0x0'),'allowNull':![]},'description':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a509_0x11be=['STRING','exports','sequelize'];(function(_0x8b00e9,_0x11bea4){const _0x222ba6=function(_0x2f72ed){while(--_0x2f72ed){_0x8b00e9['push'](_0x8b00e9['shift']());}};_0x222ba6(++_0x11bea4);}(a509_0x11be,0x175));const a509_0x222b=function(_0x8b00e9,_0x11bea4){_0x8b00e9=_0x8b00e9-0x0;let _0x222ba6=a509_0x11be[_0x8b00e9];return _0x222ba6;};const _0x137988=a509_0x222b;'use strict';const Sequelize=require(_0x137988('0x1'));module[_0x137988('0x0')]={'name':{'type':Sequelize[_0x137988('0x2')],'unique':'name','allowNull':![]},'description':{'type':Sequelize[_0x137988('0x2')]}}; \ No newline at end of file diff --git a/server/api/pause/pause.controller.js b/server/api/pause/pause.controller.js index b3dda01..42cf342 100644 --- a/server/api/pause/pause.controller.js +++ b/server/api/pause/pause.controller.js @@ -1 +1 @@ -const a510_0x155a=['body','destroy','order','index','merge','sendStatus','type','key','pick','map','fields','get','rows','filter','status','model','keys','update','count','UserProfileResource','where','findOne','api','then','json','name','offset','stack','length','catch','query','sort','../../mysqldb','like','user','Unable\x20to\x20retrieve\x20the\x20current\x20user','attributes','include','Pauses','filters','end','includeAll','undefined','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','UserProfileSection','error','VIRTUAL','Content-Range','limit','nolimit','findAll','params','Pause','create','send','show'];(function(_0x487a2c,_0x155a96){const _0x10cb8e=function(_0x5956b0){while(--_0x5956b0){_0x487a2c['push'](_0x487a2c['shift']());}};_0x10cb8e(++_0x155a96);}(a510_0x155a,0x96));const a510_0x10cb=function(_0x487a2c,_0x155a96){_0x487a2c=_0x487a2c-0x0;let _0x10cb8e=a510_0x155a[_0x487a2c];return _0x10cb8e;};const _0x14bf7c=a510_0x10cb;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x14bf7c('0x28')),db=require(_0x14bf7c('0x32'))['db'],{Op}=require('sequelize');function respondWithResult(_0x5956b0,_0x2588da){return _0x2588da=_0x2588da||0xc8,function(_0x485a81){const _0x21748e=a510_0x10cb;if(_0x485a81)return _0x5956b0[_0x21748e('0x20')](_0x2588da)[_0x21748e('0x2a')](_0x485a81);};}function respondWithFilteredResult(_0x32c646,_0x55edd9){return function(_0x38b802){const _0x360980=a510_0x10cb;if(_0x38b802){const _0x5ef4ed=_0x38b802[_0x360980('0x24')],_0x3e00f1=_0x55edd9[_0x360980('0x2c')];let _0x51c098=_0x55edd9[_0x360980('0x2c')]+_0x55edd9['limit'],_0x1e3dcf;return _0x51c098>=_0x5ef4ed?(_0x51c098=_0x5ef4ed,_0x1e3dcf=0xc8):_0x1e3dcf=0xce,_0x32c646[_0x360980('0x20')](_0x1e3dcf),_0x32c646['set'](_0x360980('0x9'),_0x3e00f1+'-'+_0x51c098+'/'+_0x5ef4ed)[_0x360980('0x2a')](_0x38b802);}return null;};}function saveUpdates(_0x800c29){return function(_0x10aa0d){const _0x2d3fa8=a510_0x10cb;if(_0x10aa0d)return _0x10aa0d[_0x2d3fa8('0x23')](_0x800c29)[_0x2d3fa8('0x29')](function(_0x39dbf7){return _0x39dbf7;});return null;};}function removeEntity(_0x793351){return function(_0x262378){const _0x1eccda=a510_0x10cb;if(_0x262378)return _0x262378[_0x1eccda('0x13')]()[_0x1eccda('0x29')](function(){const _0x649aed=_0x1eccda,_0x57a643=_0x262378[_0x649aed('0x1d')]({'plain':!![]}),_0xcdad2b=_0x649aed('0x0');return db[_0x649aed('0x25')][_0x649aed('0x13')]({'where':{'type':_0xcdad2b,'resourceId':_0x57a643['id']}})['then'](function(){return _0x262378;});})['then'](function(){const _0x94095e=_0x1eccda;_0x793351[_0x94095e('0x20')](0xcc)[_0x94095e('0x2')]();});};}function handleEntityNotFound(_0x1aa317){return function(_0x208273){const _0x262f3d=a510_0x10cb;return!_0x208273&&_0x1aa317[_0x262f3d('0x17')](0x194),_0x208273;};}function handleError(_0x150ef4,_0x216f03){return _0x216f03=_0x216f03||0x1f4,function(_0x43a5a3){const _0x4dfeac=a510_0x10cb;logger[_0x4dfeac('0x7')](_0x43a5a3[_0x4dfeac('0x2d')]),_0x43a5a3['name']&&delete _0x43a5a3[_0x4dfeac('0x2b')],_0x150ef4[_0x4dfeac('0x20')](_0x216f03)[_0x4dfeac('0x10')](_0x43a5a3);};}exports[_0x14bf7c('0x15')]=function(_0x46b843,_0x2e865c){const _0x1e66b3=_0x14bf7c;let _0x984052={};const _0x12c7cb={},_0x1a5e51={'count':0x0,'rows':[]},_0x4ba4e0=_[_0x1e66b3('0x1b')](db[_0x1e66b3('0xe')]['rawAttributes'],function(_0x246774){const _0x390444=_0x1e66b3;return{'name':_0x246774['fieldName'],'type':_0x246774[_0x390444('0x18')][_0x390444('0x19')]};});_0x12c7cb[_0x1e66b3('0x21')]=_[_0x1e66b3('0x1b')](_0x4ba4e0,_0x1e66b3('0x2b')),_0x12c7cb[_0x1e66b3('0x30')]=_['keys'](_0x46b843[_0x1e66b3('0x30')]),_0x12c7cb['filters']=_['intersection'](_0x12c7cb['model'],_0x12c7cb[_0x1e66b3('0x30')]),_0x984052[_0x1e66b3('0x36')]=_['intersection'](_0x12c7cb[_0x1e66b3('0x21')],qs[_0x1e66b3('0x1c')](_0x46b843['query'][_0x1e66b3('0x1c')])),_0x984052['attributes']=_0x984052[_0x1e66b3('0x36')][_0x1e66b3('0x2e')]?_0x984052[_0x1e66b3('0x36')]:_0x12c7cb['model'];typeof _0x46b843['query'][_0x1e66b3('0xb')]===_0x1e66b3('0x4')&&(_0x984052[_0x1e66b3('0xa')]=qs[_0x1e66b3('0xa')](_0x46b843[_0x1e66b3('0x30')][_0x1e66b3('0xa')]),_0x984052[_0x1e66b3('0x2c')]=qs['offset'](_0x46b843['query'][_0x1e66b3('0x2c')]));_0x984052[_0x1e66b3('0x14')]=qs[_0x1e66b3('0x31')](_0x46b843[_0x1e66b3('0x30')][_0x1e66b3('0x31')]),_0x984052[_0x1e66b3('0x26')]=qs[_0x1e66b3('0x1')](_[_0x1e66b3('0x1a')](_0x46b843[_0x1e66b3('0x30')],_0x12c7cb[_0x1e66b3('0x1')]),_0x4ba4e0);_0x46b843['query'][_0x1e66b3('0x1f')]&&(_0x984052[_0x1e66b3('0x26')]=_[_0x1e66b3('0x16')](_0x984052[_0x1e66b3('0x26')],{[Op['or']]:_[_0x1e66b3('0x1b')](_0x4ba4e0,function(_0x2ae7a9){const _0x1560e6=_0x1e66b3;if(_0x2ae7a9[_0x1560e6('0x18')]!==_0x1560e6('0x8')){const _0x40bdf9={};return _0x40bdf9[_0x2ae7a9[_0x1560e6('0x2b')]]={[Op[_0x1560e6('0x33')]]:'%'+_0x46b843['query']['filter']+'%'},_0x40bdf9;}})}));_0x984052=_[_0x1e66b3('0x16')]({},_0x984052,_0x46b843['options']);const _0x35ddfa={'where':_0x984052['where']};return db[_0x1e66b3('0xe')]['count'](_0x35ddfa)[_0x1e66b3('0x29')](function(_0xdb05b2){const _0x96a90d=_0x1e66b3;return _0x1a5e51[_0x96a90d('0x24')]=_0xdb05b2,_0x46b843[_0x96a90d('0x30')][_0x96a90d('0x3')]&&(_0x984052[_0x96a90d('0x37')]=[{'all':!![]}]),db['Pause'][_0x96a90d('0xc')](_0x984052);})['then'](function(_0x3e24b4){const _0x1d42c2=_0x1e66b3;return _0x1a5e51[_0x1d42c2('0x1e')]=_0x3e24b4,_0x1a5e51;})[_0x1e66b3('0x29')](respondWithFilteredResult(_0x2e865c,_0x984052))[_0x1e66b3('0x2f')](handleError(_0x2e865c,null));},exports[_0x14bf7c('0x11')]=function(_0x29a80e,_0x20cd6e){const _0x3f2bc3=_0x14bf7c;let _0x38cef6={'raw':!![],'where':{'id':_0x29a80e[_0x3f2bc3('0xd')]['id']}};const _0x2b6ef2={};return _0x2b6ef2[_0x3f2bc3('0x21')]=_[_0x3f2bc3('0x22')](db[_0x3f2bc3('0xe')]['rawAttributes']),_0x2b6ef2[_0x3f2bc3('0x30')]=_['keys'](_0x29a80e[_0x3f2bc3('0x30')]),_0x2b6ef2[_0x3f2bc3('0x1')]=_['intersection'](_0x2b6ef2[_0x3f2bc3('0x21')],_0x2b6ef2[_0x3f2bc3('0x30')]),_0x38cef6['attributes']=_['intersection'](_0x2b6ef2[_0x3f2bc3('0x21')],qs[_0x3f2bc3('0x1c')](_0x29a80e[_0x3f2bc3('0x30')][_0x3f2bc3('0x1c')])),_0x38cef6['attributes']=_0x38cef6[_0x3f2bc3('0x36')][_0x3f2bc3('0x2e')]?_0x38cef6[_0x3f2bc3('0x36')]:_0x2b6ef2['model'],_0x29a80e[_0x3f2bc3('0x30')][_0x3f2bc3('0x3')]&&(_0x38cef6['include']=[{'all':!![]}]),_0x38cef6=_[_0x3f2bc3('0x16')]({},_0x38cef6,_0x29a80e['options']),db[_0x3f2bc3('0xe')][_0x3f2bc3('0x27')](_0x38cef6)['then'](handleEntityNotFound(_0x20cd6e,null))[_0x3f2bc3('0x29')](respondWithResult(_0x20cd6e,null))['catch'](handleError(_0x20cd6e,null));},exports['create']=function(_0x490be7,_0x3ad362){const _0xc5cee9=_0x14bf7c;return db['Pause'][_0xc5cee9('0xf')](_0x490be7[_0xc5cee9('0x12')],{})[_0xc5cee9('0x29')](function(_0x46bef3){const _0x1c52af=_0xc5cee9,_0x466429=_0x490be7[_0x1c52af('0x34')]['get']({'plain':!![]});if(!_0x466429)throw new Error(_0x1c52af('0x35'));if(_0x466429['role']===_0x1c52af('0x34')){const _0x5afc2a=_0x46bef3[_0x1c52af('0x1d')]({'plain':!![]}),_0x54a2c2=_0x1c52af('0x0');return db[_0x1c52af('0x6')][_0x1c52af('0x27')]({'where':{'name':_0x54a2c2,'userProfileId':_0x466429['userProfileId']},'raw':!![]})[_0x1c52af('0x29')](function(_0x314b90){const _0x526ce2=_0x1c52af;return _0x314b90&&_0x314b90['autoAssociation']===0x0?db['UserProfileResource'][_0x526ce2('0xf')]({'name':_0x5afc2a['name'],'resourceId':_0x5afc2a['id'],'type':_0x314b90['name'],'sectionId':_0x314b90['id']},{})['then'](function(){return _0x46bef3;}):_0x46bef3;})[_0x1c52af('0x2f')](function(_0x4db1a9){const _0x11f306=_0x1c52af;logger['error'](_0x11f306('0x5'),_0x4db1a9);throw _0x4db1a9;});}return _0x46bef3;})[_0xc5cee9('0x29')](respondWithResult(_0x3ad362,0xc9))[_0xc5cee9('0x2f')](handleError(_0x3ad362,null));},exports[_0x14bf7c('0x23')]=function(_0x19d0a5,_0x3b36cc){const _0x223010=_0x14bf7c;return _0x19d0a5[_0x223010('0x12')]['id']&&delete _0x19d0a5[_0x223010('0x12')]['id'],db[_0x223010('0xe')][_0x223010('0x27')]({'where':{'id':_0x19d0a5[_0x223010('0xd')]['id']}})['then'](handleEntityNotFound(_0x3b36cc,null))[_0x223010('0x29')](saveUpdates(_0x19d0a5[_0x223010('0x12')],null))[_0x223010('0x29')](respondWithResult(_0x3b36cc,null))[_0x223010('0x2f')](handleError(_0x3b36cc,null));},exports[_0x14bf7c('0x13')]=function(_0x46fc61,_0x4cef70){const _0x523712=_0x14bf7c;return db['Pause']['findOne']({'where':{'id':_0x46fc61[_0x523712('0xd')]['id']}})[_0x523712('0x29')](handleEntityNotFound(_0x4cef70,null))[_0x523712('0x29')](removeEntity(_0x4cef70,null))[_0x523712('0x2f')](handleError(_0x4cef70,null));}; \ No newline at end of file +const a510_0x115b=['undefined','rawAttributes','set','catch','like','merge','end','filter','send','include','intersection','model','sequelize','order','options','offset','rows','count','type','sendStatus','length','role','nolimit','UserProfileResource','create','params','Pauses','stack','map','Pause','sort','includeAll','../../components/parsers/qs','filters','fieldName','keys','where','findOne','findAll','json','body','key','user','index','fields','Unable\x20to\x20retrieve\x20the\x20current\x20user','query','pick','get','Content-Range','then','limit','attributes','lodash','userProfileId','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','../../config/logger','show','status','destroy','name'];(function(_0xcffff8,_0x115b0d){const _0x4068d3=function(_0x4926d7){while(--_0x4926d7){_0xcffff8['push'](_0xcffff8['shift']());}};_0x4068d3(++_0x115b0d);}(a510_0x115b,0x1c3));const a510_0x4068=function(_0xcffff8,_0x115b0d){_0xcffff8=_0xcffff8-0x0;let _0x4068d3=a510_0x115b[_0xcffff8];return _0x4068d3;};const _0x31afed=a510_0x4068;'use strict';const _=require(_0x31afed('0x1d')),qs=require(_0x31afed('0x8')),logger=require(_0x31afed('0x20'))('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x31afed('0x31'));function respondWithResult(_0x4926d7,_0x4fb502){return _0x4fb502=_0x4fb502||0xc8,function(_0x93cf8b){const _0x1571db=a510_0x4068;if(_0x93cf8b)return _0x4926d7[_0x1571db('0x22')](_0x4fb502)[_0x1571db('0xf')](_0x93cf8b);};}function respondWithFilteredResult(_0x46ba88,_0xcfede9){return function(_0x3ae1f8){const _0x49c46c=a510_0x4068;if(_0x3ae1f8){const _0x4b0e50=_0x3ae1f8[_0x49c46c('0x36')],_0x370df9=_0xcfede9[_0x49c46c('0x34')];let _0x261a74=_0xcfede9[_0x49c46c('0x34')]+_0xcfede9[_0x49c46c('0x1b')],_0x96858a;return _0x261a74>=_0x4b0e50?(_0x261a74=_0x4b0e50,_0x96858a=0xc8):_0x96858a=0xce,_0x46ba88['status'](_0x96858a),_0x46ba88[_0x49c46c('0x27')](_0x49c46c('0x19'),_0x370df9+'-'+_0x261a74+'/'+_0x4b0e50)[_0x49c46c('0xf')](_0x3ae1f8);}return null;};}function saveUpdates(_0x1f1e94){return function(_0x27abe2){const _0x5da97b=a510_0x4068;if(_0x27abe2)return _0x27abe2['update'](_0x1f1e94)[_0x5da97b('0x1a')](function(_0x1e5c6a){return _0x1e5c6a;});return null;};}function removeEntity(_0x54d10e){return function(_0x3ce0b9){const _0x48beee=a510_0x4068;if(_0x3ce0b9)return _0x3ce0b9['destroy']()[_0x48beee('0x1a')](function(){const _0x442e06=_0x48beee,_0x22d49a=_0x3ce0b9['get']({'plain':!![]}),_0x570b9c='Pauses';return db[_0x442e06('0x3c')][_0x442e06('0x23')]({'where':{'type':_0x570b9c,'resourceId':_0x22d49a['id']}})[_0x442e06('0x1a')](function(){return _0x3ce0b9;});})['then'](function(){const _0x348300=_0x48beee;_0x54d10e[_0x348300('0x22')](0xcc)[_0x348300('0x2b')]();});};}function handleEntityNotFound(_0x1da341){return function(_0x12f4c9){const _0x799450=a510_0x4068;return!_0x12f4c9&&_0x1da341[_0x799450('0x38')](0x194),_0x12f4c9;};}function handleError(_0x50016e,_0x1c120d){return _0x1c120d=_0x1c120d||0x1f4,function(_0x1007f5){const _0x5a0c10=a510_0x4068;logger['error'](_0x1007f5[_0x5a0c10('0x3')]),_0x1007f5[_0x5a0c10('0x24')]&&delete _0x1007f5[_0x5a0c10('0x24')],_0x50016e['status'](_0x1c120d)[_0x5a0c10('0x2d')](_0x1007f5);};}exports[_0x31afed('0x13')]=function(_0x584fdc,_0x26db14){const _0x27dd8a=_0x31afed;let _0x28ad0f={};const _0x45e26b={},_0x4ec560={'count':0x0,'rows':[]},_0x447547=_['map'](db['Pause'][_0x27dd8a('0x26')],function(_0x491621){const _0x40d4de=_0x27dd8a;return{'name':_0x491621[_0x40d4de('0xa')],'type':_0x491621[_0x40d4de('0x37')][_0x40d4de('0x11')]};});_0x45e26b[_0x27dd8a('0x30')]=_[_0x27dd8a('0x4')](_0x447547,_0x27dd8a('0x24')),_0x45e26b[_0x27dd8a('0x16')]=_[_0x27dd8a('0xb')](_0x584fdc['query']),_0x45e26b[_0x27dd8a('0x9')]=_[_0x27dd8a('0x2f')](_0x45e26b[_0x27dd8a('0x30')],_0x45e26b[_0x27dd8a('0x16')]),_0x28ad0f['attributes']=_[_0x27dd8a('0x2f')](_0x45e26b[_0x27dd8a('0x30')],qs[_0x27dd8a('0x14')](_0x584fdc[_0x27dd8a('0x16')]['fields'])),_0x28ad0f['attributes']=_0x28ad0f[_0x27dd8a('0x1c')][_0x27dd8a('0x39')]?_0x28ad0f[_0x27dd8a('0x1c')]:_0x45e26b['model'];typeof _0x584fdc['query'][_0x27dd8a('0x3b')]===_0x27dd8a('0x25')&&(_0x28ad0f[_0x27dd8a('0x1b')]=qs[_0x27dd8a('0x1b')](_0x584fdc['query']['limit']),_0x28ad0f[_0x27dd8a('0x34')]=qs[_0x27dd8a('0x34')](_0x584fdc['query'][_0x27dd8a('0x34')]));_0x28ad0f[_0x27dd8a('0x32')]=qs[_0x27dd8a('0x6')](_0x584fdc[_0x27dd8a('0x16')][_0x27dd8a('0x6')]),_0x28ad0f[_0x27dd8a('0xc')]=qs[_0x27dd8a('0x9')](_[_0x27dd8a('0x17')](_0x584fdc[_0x27dd8a('0x16')],_0x45e26b['filters']),_0x447547);_0x584fdc[_0x27dd8a('0x16')]['filter']&&(_0x28ad0f[_0x27dd8a('0xc')]=_[_0x27dd8a('0x2a')](_0x28ad0f['where'],{[Op['or']]:_['map'](_0x447547,function(_0x4e0513){const _0x3cbeda=_0x27dd8a;if(_0x4e0513[_0x3cbeda('0x37')]!=='VIRTUAL'){const _0x57d194={};return _0x57d194[_0x4e0513['name']]={[Op[_0x3cbeda('0x29')]]:'%'+_0x584fdc[_0x3cbeda('0x16')][_0x3cbeda('0x2c')]+'%'},_0x57d194;}})}));_0x28ad0f=_['merge']({},_0x28ad0f,_0x584fdc[_0x27dd8a('0x33')]);const _0x230459={'where':_0x28ad0f['where']};return db[_0x27dd8a('0x5')][_0x27dd8a('0x36')](_0x230459)[_0x27dd8a('0x1a')](function(_0x4390d1){const _0x59f4e9=_0x27dd8a;return _0x4ec560[_0x59f4e9('0x36')]=_0x4390d1,_0x584fdc[_0x59f4e9('0x16')][_0x59f4e9('0x7')]&&(_0x28ad0f[_0x59f4e9('0x2e')]=[{'all':!![]}]),db[_0x59f4e9('0x5')][_0x59f4e9('0xe')](_0x28ad0f);})[_0x27dd8a('0x1a')](function(_0x20767a){const _0x3dec2f=_0x27dd8a;return _0x4ec560[_0x3dec2f('0x35')]=_0x20767a,_0x4ec560;})[_0x27dd8a('0x1a')](respondWithFilteredResult(_0x26db14,_0x28ad0f))[_0x27dd8a('0x28')](handleError(_0x26db14,null));},exports[_0x31afed('0x21')]=function(_0x2da149,_0x5bce53){const _0x2a9f1e=_0x31afed;let _0x3834c8={'raw':!![],'where':{'id':_0x2da149['params']['id']}};const _0x573a76={};return _0x573a76['model']=_['keys'](db[_0x2a9f1e('0x5')][_0x2a9f1e('0x26')]),_0x573a76[_0x2a9f1e('0x16')]=_[_0x2a9f1e('0xb')](_0x2da149['query']),_0x573a76[_0x2a9f1e('0x9')]=_[_0x2a9f1e('0x2f')](_0x573a76[_0x2a9f1e('0x30')],_0x573a76['query']),_0x3834c8[_0x2a9f1e('0x1c')]=_[_0x2a9f1e('0x2f')](_0x573a76[_0x2a9f1e('0x30')],qs[_0x2a9f1e('0x14')](_0x2da149['query'][_0x2a9f1e('0x14')])),_0x3834c8[_0x2a9f1e('0x1c')]=_0x3834c8[_0x2a9f1e('0x1c')][_0x2a9f1e('0x39')]?_0x3834c8['attributes']:_0x573a76[_0x2a9f1e('0x30')],_0x2da149[_0x2a9f1e('0x16')][_0x2a9f1e('0x7')]&&(_0x3834c8[_0x2a9f1e('0x2e')]=[{'all':!![]}]),_0x3834c8=_[_0x2a9f1e('0x2a')]({},_0x3834c8,_0x2da149[_0x2a9f1e('0x33')]),db[_0x2a9f1e('0x5')][_0x2a9f1e('0xd')](_0x3834c8)[_0x2a9f1e('0x1a')](handleEntityNotFound(_0x5bce53,null))[_0x2a9f1e('0x1a')](respondWithResult(_0x5bce53,null))['catch'](handleError(_0x5bce53,null));},exports[_0x31afed('0x0')]=function(_0x4ec047,_0x41ac21){const _0x43b58b=_0x31afed;return db[_0x43b58b('0x5')]['create'](_0x4ec047[_0x43b58b('0x10')],{})['then'](function(_0x275da0){const _0x3f1133=_0x43b58b,_0x3e104d=_0x4ec047[_0x3f1133('0x12')][_0x3f1133('0x18')]({'plain':!![]});if(!_0x3e104d)throw new Error(_0x3f1133('0x15'));if(_0x3e104d[_0x3f1133('0x3a')]===_0x3f1133('0x12')){const _0x117f24=_0x275da0[_0x3f1133('0x18')]({'plain':!![]}),_0x2d549d=_0x3f1133('0x2');return db['UserProfileSection'][_0x3f1133('0xd')]({'where':{'name':_0x2d549d,'userProfileId':_0x3e104d[_0x3f1133('0x1e')]},'raw':!![]})[_0x3f1133('0x1a')](function(_0x30c42e){const _0x500896=_0x3f1133;return _0x30c42e&&_0x30c42e['autoAssociation']===0x0?db[_0x500896('0x3c')][_0x500896('0x0')]({'name':_0x117f24[_0x500896('0x24')],'resourceId':_0x117f24['id'],'type':_0x30c42e['name'],'sectionId':_0x30c42e['id']},{})[_0x500896('0x1a')](function(){return _0x275da0;}):_0x275da0;})[_0x3f1133('0x28')](function(_0x49d09e){const _0x511af1=_0x3f1133;logger['error'](_0x511af1('0x1f'),_0x49d09e);throw _0x49d09e;});}return _0x275da0;})[_0x43b58b('0x1a')](respondWithResult(_0x41ac21,0xc9))[_0x43b58b('0x28')](handleError(_0x41ac21,null));},exports['update']=function(_0xf1a62b,_0xde22cf){const _0x50ef68=_0x31afed;return _0xf1a62b['body']['id']&&delete _0xf1a62b[_0x50ef68('0x10')]['id'],db[_0x50ef68('0x5')][_0x50ef68('0xd')]({'where':{'id':_0xf1a62b[_0x50ef68('0x1')]['id']}})[_0x50ef68('0x1a')](handleEntityNotFound(_0xde22cf,null))[_0x50ef68('0x1a')](saveUpdates(_0xf1a62b['body'],null))[_0x50ef68('0x1a')](respondWithResult(_0xde22cf,null))[_0x50ef68('0x28')](handleError(_0xde22cf,null));},exports[_0x31afed('0x23')]=function(_0xb71f6e,_0x1791f4){const _0xa06a2d=_0x31afed;return db['Pause'][_0xa06a2d('0xd')]({'where':{'id':_0xb71f6e[_0xa06a2d('0x1')]['id']}})[_0xa06a2d('0x1a')](handleEntityNotFound(_0x1791f4,null))[_0xa06a2d('0x1a')](removeEntity(_0x1791f4,null))['catch'](handleError(_0x1791f4,null));}; \ No newline at end of file diff --git a/server/api/pause/pause.model.js b/server/api/pause/pause.model.js index b630054..95fdb4e 100644 --- a/server/api/pause/pause.model.js +++ b/server/api/pause/pause.model.js @@ -1 +1 @@ -const a511_0x5af6=['./pause.attributes','exports','Pause','tools_pauses'];(function(_0x42cc3e,_0x5af644){const _0x26c451=function(_0x7acaca){while(--_0x7acaca){_0x42cc3e['push'](_0x42cc3e['shift']());}};_0x26c451(++_0x5af644);}(a511_0x5af6,0x172));const a511_0x26c4=function(_0x42cc3e,_0x5af644){_0x42cc3e=_0x42cc3e-0x0;let _0x26c451=a511_0x5af6[_0x42cc3e];return _0x26c451;};const _0x176e41=a511_0x26c4;'use strict';const attributes=require(_0x176e41('0x2'));module[_0x176e41('0x3')]=function(_0x7acaca){const _0x4094d1=_0x176e41,_0x77312d=_0x7acaca['define'](_0x4094d1('0x0'),attributes,{'tableName':_0x4094d1('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x77312d;}; \ No newline at end of file +const a511_0x17e0=['Pause','define','./pause.attributes','exports'];(function(_0x3b620f,_0x17e0d9){const _0x5167b9=function(_0x160523){while(--_0x160523){_0x3b620f['push'](_0x3b620f['shift']());}};_0x5167b9(++_0x17e0d9);}(a511_0x17e0,0x1b8));const a511_0x5167=function(_0x3b620f,_0x17e0d9){_0x3b620f=_0x3b620f-0x0;let _0x5167b9=a511_0x17e0[_0x3b620f];return _0x5167b9;};const _0x3dd10b=a511_0x5167;'use strict';const attributes=require(_0x3dd10b('0x2'));module[_0x3dd10b('0x3')]=function(_0x160523){const _0xade2c=_0x3dd10b,_0x472297=_0x160523[_0xade2c('0x1')](_0xade2c('0x0'),attributes,{'tableName':'tools_pauses','paranoid':![],'indexes':[],'timestamps':!![]});return _0x472297;}; \ No newline at end of file diff --git a/server/api/pause/pause.rpc.js b/server/api/pause/pause.rpc.js index 536e64d..e55f395 100644 --- a/server/api/pause/pause.rpc.js +++ b/server/api/pause/pause.rpc.js @@ -1 +1 @@ -const a512_0x2130=['raw','attributes','../../config/logger','info','then','lodash','ShowPause','Pause','../../mysqldb','message','error','include','model','map','debug','catch','options','where'];(function(_0x338982,_0x213043){const _0x334be1=function(_0x5aa49d){while(--_0x5aa49d){_0x338982['push'](_0x338982['shift']());}};_0x334be1(++_0x213043);}(a512_0x2130,0x1a8));const a512_0x334b=function(_0x338982,_0x213043){_0x338982=_0x338982-0x0;let _0x334be1=a512_0x2130[_0x338982];return _0x334be1;};const _0x2b9864=a512_0x334b;'use strict';const db=require(_0x2b9864('0x10'))['db'],logger=require(_0x2b9864('0xa'))('rpc'),_=require(_0x2b9864('0xd'));exports['ShowPause']=function(_0x5aa49d){const _0x1b1354=this;return new Promise(function(_0x572c43,_0x4f21c6){const _0x3b91e0=a512_0x334b;return db[_0x3b91e0('0xf')]['findOne']({'raw':_0x5aa49d[_0x3b91e0('0x6')]?_0x5aa49d[_0x3b91e0('0x6')][_0x3b91e0('0x8')]===undefined?!![]:![]:!![],'where':_0x5aa49d[_0x3b91e0('0x6')]?_0x5aa49d['options'][_0x3b91e0('0x7')]||null:null,'attributes':_0x5aa49d[_0x3b91e0('0x6')]?_0x5aa49d['options'][_0x3b91e0('0x9')]||null:null,'include':_0x5aa49d[_0x3b91e0('0x6')]?_0x5aa49d[_0x3b91e0('0x6')][_0x3b91e0('0x1')]?_[_0x3b91e0('0x3')](_0x5aa49d[_0x3b91e0('0x6')]['include'],function(_0x119017){const _0x150f77=_0x3b91e0;return{'model':db[_0x119017[_0x150f77('0x2')]],'as':_0x119017['as'],'attributes':_0x119017[_0x150f77('0x9')],'include':_0x119017[_0x150f77('0x1')]?_[_0x150f77('0x3')](_0x119017[_0x150f77('0x1')],function(_0x27190b){const _0x51ba27=_0x150f77;return{'model':db[_0x27190b[_0x51ba27('0x2')]],'as':_0x27190b['as'],'attributes':_0x27190b[_0x51ba27('0x9')],'include':_0x27190b[_0x51ba27('0x1')]?_[_0x51ba27('0x3')](_0x27190b[_0x51ba27('0x1')],function(_0x3b2d0c){const _0x3c294c=_0x51ba27;return{'model':db[_0x3b2d0c[_0x3c294c('0x2')]],'as':_0x3b2d0c['as'],'attributes':_0x3b2d0c['attributes']};}):[]};}):[]};}):[]:[]})[_0x3b91e0('0xc')](function(_0x40cc38){const _0x9bd436=_0x3b91e0;logger[_0x9bd436('0xb')](_0x9bd436('0xe'),_0x5aa49d),logger[_0x9bd436('0x4')](_0x9bd436('0xe'),_0x5aa49d,JSON['stringify'](_0x40cc38)),_0x572c43(_0x40cc38);})[_0x3b91e0('0x5')](function(_0x4c0141){const _0x30fc41=_0x3b91e0;logger[_0x30fc41('0x0')](_0x30fc41('0xe'),_0x4c0141['message'],_0x5aa49d),_0x4f21c6(_0x1b1354[_0x30fc41('0x0')](0x1f4,_0x4c0141[_0x30fc41('0x11')]));});});}; \ No newline at end of file +const a512_0x298b=['then','attributes','findOne','model','Pause','catch','options','info','ShowPause','map','rpc','../../mysqldb','message','include','error','where','raw','lodash'];(function(_0x4149d7,_0x298ba5){const _0x4461cc=function(_0x58f113){while(--_0x58f113){_0x4149d7['push'](_0x4149d7['shift']());}};_0x4461cc(++_0x298ba5);}(a512_0x298b,0x158));const a512_0x4461=function(_0x4149d7,_0x298ba5){_0x4149d7=_0x4149d7-0x0;let _0x4461cc=a512_0x298b[_0x4149d7];return _0x4461cc;};const _0x5ba0ab=a512_0x4461;'use strict';const db=require(_0x5ba0ab('0x9'))['db'],logger=require('../../config/logger')(_0x5ba0ab('0x8')),_=require(_0x5ba0ab('0xf'));exports['ShowPause']=function(_0x58f113){const _0x350650=this;return new Promise(function(_0x66d0ec,_0x471b75){const _0x1281fd=a512_0x4461;return db[_0x1281fd('0x2')][_0x1281fd('0x0')]({'raw':_0x58f113[_0x1281fd('0x4')]?_0x58f113[_0x1281fd('0x4')][_0x1281fd('0xe')]===undefined?!![]:![]:!![],'where':_0x58f113['options']?_0x58f113['options'][_0x1281fd('0xd')]||null:null,'attributes':_0x58f113[_0x1281fd('0x4')]?_0x58f113[_0x1281fd('0x4')][_0x1281fd('0x11')]||null:null,'include':_0x58f113[_0x1281fd('0x4')]?_0x58f113[_0x1281fd('0x4')][_0x1281fd('0xb')]?_[_0x1281fd('0x7')](_0x58f113[_0x1281fd('0x4')]['include'],function(_0x5ae95e){const _0x5db111=_0x1281fd;return{'model':db[_0x5ae95e[_0x5db111('0x1')]],'as':_0x5ae95e['as'],'attributes':_0x5ae95e[_0x5db111('0x11')],'include':_0x5ae95e[_0x5db111('0xb')]?_[_0x5db111('0x7')](_0x5ae95e['include'],function(_0xf79333){const _0x2629e9=_0x5db111;return{'model':db[_0xf79333[_0x2629e9('0x1')]],'as':_0xf79333['as'],'attributes':_0xf79333[_0x2629e9('0x11')],'include':_0xf79333[_0x2629e9('0xb')]?_[_0x2629e9('0x7')](_0xf79333[_0x2629e9('0xb')],function(_0x445533){const _0x59d330=_0x2629e9;return{'model':db[_0x445533[_0x59d330('0x1')]],'as':_0x445533['as'],'attributes':_0x445533[_0x59d330('0x11')]};}):[]};}):[]};}):[]:[]})[_0x1281fd('0x10')](function(_0x51a800){const _0x3883be=_0x1281fd;logger[_0x3883be('0x5')]('ShowPause',_0x58f113),logger['debug']('ShowPause',_0x58f113,JSON['stringify'](_0x51a800)),_0x66d0ec(_0x51a800);})[_0x1281fd('0x3')](function(_0x29182c){const _0x1be532=_0x1281fd;logger[_0x1be532('0xc')](_0x1be532('0x6'),_0x29182c[_0x1be532('0xa')],_0x58f113),_0x471b75(_0x350650[_0x1be532('0xc')](0x1f4,_0x29182c[_0x1be532('0xa')]));});});}; \ No newline at end of file diff --git a/server/api/plugin/index.js b/server/api/plugin/index.js index f76190b..c2114ff 100644 --- a/server/api/plugin/index.js +++ b/server/api/plugin/index.js @@ -1 +1 @@ -const a513_0x10d1=['./plugin.controller','webhookPost','extname','Router','express','get','root','format','files/plugins','put','webhookGet','post','/:id/download','file','/:id','/webhook','delete','multer','upload','../../config/environment','update','index','join','../../components/auth/service','originalname','diskStorage','isAuthenticated','exports','replace'];(function(_0x20bb51,_0x10d1d5){const _0x18cffd=function(_0x53bf3b){while(--_0x53bf3b){_0x20bb51['push'](_0x20bb51['shift']());}};_0x18cffd(++_0x10d1d5);}(a513_0x10d1,0x15c));const a513_0x18cf=function(_0x20bb51,_0x10d1d5){_0x20bb51=_0x20bb51-0x0;let _0x18cffd=a513_0x10d1[_0x20bb51];return _0x18cffd;};const _0xfb5361=a513_0x18cf;'use strict';const multer=require(_0xfb5361('0x11')),util=require('util'),path=require('path'),express=require(_0xfb5361('0x4')),router=express[_0xfb5361('0x3')](),auth=require(_0xfb5361('0x17')),config=require(_0xfb5361('0x13')),controller=require(_0xfb5361('0x0'));router[_0xfb5361('0x5')]('/',auth[_0xfb5361('0x1a')](),controller[_0xfb5361('0x15')]),router[_0xfb5361('0x5')]('/webhook',controller[_0xfb5361('0xa')]),router[_0xfb5361('0x5')]('/:id',auth[_0xfb5361('0x1a')](),controller['show']),router[_0xfb5361('0x5')](_0xfb5361('0xc'),auth['isAuthenticated'](),controller['download']);const upload=multer({'storage':multer[_0xfb5361('0x19')]({'destination':function(_0x53bf3b,_0x50f66d,_0xb08e21){const _0x1732e5=_0xfb5361;_0xb08e21(null,path[_0x1732e5('0x16')](config[_0x1732e5('0x6')],_0x1732e5('0x8')));},'filename':function(_0x3fdbf8,_0x5c47f2,_0xf2a440){const _0x13df49=_0xfb5361;_0x5c47f2[_0x13df49('0x18')]=_0x5c47f2[_0x13df49('0x18')][_0x13df49('0x1c')](/[+@&/\\#,+()$~%'":*?<>{}\s\\|]/g,'-'),_0xf2a440(null,util[_0x13df49('0x7')]('%s-%s%s',path['basename'](_0x5c47f2[_0x13df49('0x18')],path['extname'](_0x5c47f2[_0x13df49('0x18')])),Date['now'](),path[_0x13df49('0x2')](_0x5c47f2[_0x13df49('0x18')])));}})});router[_0xfb5361('0xb')]('/',upload['single'](_0xfb5361('0xd')),controller[_0xfb5361('0x12')]),router[_0xfb5361('0xb')](_0xfb5361('0xf'),controller[_0xfb5361('0x1')]),router[_0xfb5361('0x9')](_0xfb5361('0xe'),auth[_0xfb5361('0x1a')](),controller[_0xfb5361('0x14')]),router[_0xfb5361('0x10')](_0xfb5361('0xe'),auth[_0xfb5361('0x1a')](),controller['delete']),module[_0xfb5361('0x1b')]=router; \ No newline at end of file +const a513_0x2fcf=['isAuthenticated','../../config/environment','files/plugins','path','../../components/auth/service','show','/webhook','express','exports','get','download','index','webhookGet','root','join','post','%s-%s%s','replace','single','diskStorage','format','./plugin.controller','Router','update','file','now','originalname','/:id','extname'];(function(_0x3f5895,_0x2fcf87){const _0x5b3e5f=function(_0x37f163){while(--_0x37f163){_0x3f5895['push'](_0x3f5895['shift']());}};_0x5b3e5f(++_0x2fcf87);}(a513_0x2fcf,0x14f));const a513_0x5b3e=function(_0x3f5895,_0x2fcf87){_0x3f5895=_0x3f5895-0x0;let _0x5b3e5f=a513_0x2fcf[_0x3f5895];return _0x5b3e5f;};const _0x1239c3=a513_0x5b3e;'use strict';const multer=require('multer'),util=require('util'),path=require(_0x1239c3('0x10')),express=require(_0x1239c3('0x14')),router=express[_0x1239c3('0x6')](),auth=require(_0x1239c3('0x11')),config=require(_0x1239c3('0xe')),controller=require(_0x1239c3('0x5'));router['get']('/',auth['isAuthenticated'](),controller[_0x1239c3('0x18')]),router[_0x1239c3('0x16')]('/webhook',controller[_0x1239c3('0x19')]),router[_0x1239c3('0x16')](_0x1239c3('0xb'),auth[_0x1239c3('0xd')](),controller[_0x1239c3('0x12')]),router[_0x1239c3('0x16')]('/:id/download',auth[_0x1239c3('0xd')](),controller[_0x1239c3('0x17')]);const upload=multer({'storage':multer[_0x1239c3('0x3')]({'destination':function(_0x37f163,_0x279cfc,_0x228087){const _0x5bbe59=_0x1239c3;_0x228087(null,path[_0x5bbe59('0x1b')](config[_0x5bbe59('0x1a')],_0x5bbe59('0xf')));},'filename':function(_0x52cb7d,_0x105647,_0x3f6e10){const _0x330d45=_0x1239c3;_0x105647[_0x330d45('0xa')]=_0x105647[_0x330d45('0xa')][_0x330d45('0x1')](/[+@&/\\#,+()$~%'":*?<>{}\s\\|]/g,'-'),_0x3f6e10(null,util[_0x330d45('0x4')](_0x330d45('0x0'),path['basename'](_0x105647[_0x330d45('0xa')],path[_0x330d45('0xc')](_0x105647[_0x330d45('0xa')])),Date[_0x330d45('0x9')](),path[_0x330d45('0xc')](_0x105647[_0x330d45('0xa')])));}})});router[_0x1239c3('0x1c')]('/',upload[_0x1239c3('0x2')](_0x1239c3('0x8')),controller['upload']),router[_0x1239c3('0x1c')](_0x1239c3('0x13'),controller['webhookPost']),router['put'](_0x1239c3('0xb'),auth[_0x1239c3('0xd')](),controller[_0x1239c3('0x7')]),router['delete'](_0x1239c3('0xb'),auth[_0x1239c3('0xd')](),controller['delete']),module[_0x1239c3('0x15')]=router; \ No newline at end of file diff --git a/server/api/plugin/plugin.attributes.js b/server/api/plugin/plugin.attributes.js index 56c1b35..9e8d062 100644 --- a/server/api/plugin/plugin.attributes.js +++ b/server/api/plugin/plugin.attributes.js @@ -1 +1 @@ -const a514_0x420d=['exports','STRING','never','always','TEXT','Indicates\x20whether\x20the\x20plugin\x20is\x20installed.\x20Updated\x20when\x20the\x20plugin\x20is\x20installed/uninstalled.','agentOnly','script','ENUM','adminOnly','The\x20physical\x20path\x20where\x20the\x20plugin\x20is\x20stored.','sequelize','html','Indicates\x20whether\x20to\x20display\x20the\x20plugin\x20in\x20the\x20sidebar.'];(function(_0x3b3384,_0x420db8){const _0x4038d4=function(_0x2ce849){while(--_0x2ce849){_0x3b3384['push'](_0x3b3384['shift']());}};_0x4038d4(++_0x420db8);}(a514_0x420d,0x73));const a514_0x4038=function(_0x3b3384,_0x420db8){_0x3b3384=_0x3b3384-0x0;let _0x4038d4=a514_0x420d[_0x3b3384];return _0x4038d4;};const _0x54f2c1=a514_0x4038;'use strict';const Sequelize=require(_0x54f2c1('0x8'));module[_0x54f2c1('0xb')]={'name':{'type':Sequelize[_0x54f2c1('0xc')]},'type':{'type':Sequelize[_0x54f2c1('0x5')](_0x54f2c1('0x9'),_0x54f2c1('0x4'))},'description':{'type':Sequelize[_0x54f2c1('0x1')]},'version':{'type':Sequelize[_0x54f2c1('0x1')]},'path':{'type':Sequelize[_0x54f2c1('0xc')],'comment':_0x54f2c1('0x7')},'active':{'type':Sequelize['BOOLEAN'],'defaultValue':0x0,'comment':_0x54f2c1('0x2')},'sidebar':{'type':Sequelize['ENUM'](_0x54f2c1('0x6'),_0x54f2c1('0x3'),_0x54f2c1('0x0'),_0x54f2c1('0xd')),'defaultValue':'always','comment':_0x54f2c1('0xa')},'icon':{'type':Sequelize[_0x54f2c1('0xc')]},'adminUrl':{'type':Sequelize[_0x54f2c1('0xc')]},'agentUrl':{'type':Sequelize['STRING']},'scriptName':{'type':Sequelize['STRING']},'scriptPath':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a514_0x2528=['BOOLEAN','ENUM','Indicates\x20whether\x20to\x20display\x20the\x20plugin\x20in\x20the\x20sidebar.','agentOnly','STRING','always','The\x20physical\x20path\x20where\x20the\x20plugin\x20is\x20stored.','script','sequelize','never','html','TEXT'];(function(_0x1ae4ea,_0x25282d){const _0x43ae74=function(_0x6f21a9){while(--_0x6f21a9){_0x1ae4ea['push'](_0x1ae4ea['shift']());}};_0x43ae74(++_0x25282d);}(a514_0x2528,0x1d7));const a514_0x43ae=function(_0x1ae4ea,_0x25282d){_0x1ae4ea=_0x1ae4ea-0x0;let _0x43ae74=a514_0x2528[_0x1ae4ea];return _0x43ae74;};const _0xcaee45=a514_0x43ae;'use strict';const Sequelize=require(_0xcaee45('0x5'));module['exports']={'name':{'type':Sequelize['STRING']},'type':{'type':Sequelize['ENUM'](_0xcaee45('0x7'),_0xcaee45('0x4'))},'description':{'type':Sequelize[_0xcaee45('0x8')]},'version':{'type':Sequelize[_0xcaee45('0x8')]},'path':{'type':Sequelize['STRING'],'comment':_0xcaee45('0x3')},'active':{'type':Sequelize[_0xcaee45('0x9')],'defaultValue':0x0,'comment':'Indicates\x20whether\x20the\x20plugin\x20is\x20installed.\x20Updated\x20when\x20the\x20plugin\x20is\x20installed/uninstalled.'},'sidebar':{'type':Sequelize[_0xcaee45('0xa')]('adminOnly',_0xcaee45('0x0'),_0xcaee45('0x2'),_0xcaee45('0x6')),'defaultValue':_0xcaee45('0x2'),'comment':_0xcaee45('0xb')},'icon':{'type':Sequelize[_0xcaee45('0x1')]},'adminUrl':{'type':Sequelize[_0xcaee45('0x1')]},'agentUrl':{'type':Sequelize[_0xcaee45('0x1')]},'scriptName':{'type':Sequelize[_0xcaee45('0x1')]},'scriptPath':{'type':Sequelize[_0xcaee45('0x1')]}}; \ No newline at end of file diff --git a/server/api/plugin/plugin.controller.js b/server/api/plugin/plugin.controller.js index 49825b3..147b9d5 100644 --- a/server/api/plugin/plugin.controller.js +++ b/server/api/plugin/plugin.controller.js @@ -1 +1 @@ -const a515_0x471c=['resolve','icon-apps','ENOENT','options','model','version','Plugin','Invalid\x20manifest:\x20invalid\x20type','Error','../../config/environment','statusCode','encoding','Plugin\x20manifest\x20missing','sendStatus','archiver','show','close','chmodSync','order','params','extname','userProfileId','0777','zip','like','icon','**/*','file','upload','dirname','create','end','Invalid\x20manifest:\x20type\x20missing','manifest.json','nolimit','unlinkSync','download','type','include','intersection','headers','set','Plugin\x20upload\x20filepath:\x20%s','includeAll','Invalid\x20plugin\x20structure','finalize','status','%s.zip','files/plugins','Error\x20while\x20generating\x20the\x20zip\x20archive','Download\x20completed','extract-zip','pick','html','UserProfileSection','admin','where','attachments/**/*','findOne','Sequelize','sequelize','update','query','UserProfileResource','format','error','join','Plugin\x20not\x20found','body','merge','filename','filters','role','webhookGet','then','Warning:\x20agent\x20view\x20not\x20specified','%s%s','plugins','readFileSync','undefined','Plugin\x20upload\x20destination:\x20%s','rimraf','delete','test','always','Temporary\x20file\x20removed','content-type','sidebar','count','sort','json','info','http://localhost:','warning','createWriteStream','fieldName','map','basename','Invalid\x20manifest:\x20no\x20view\x20specified','code','Invalid\x20manifest:\x20views\x20missing','filter','endsWith','limit','offset','util','views','pipe','webhookPost','method','../../rediscache','rawAttributes','content-length','../../mysqldb','\x27PORT\x27\x20parameter\x20not\x20specified','glob','name','path','scriptPath','length','get','agent','destroy','scriptName','send','\x27PATH\x27\x20parameter\x20not\x20specified','keys','hostname','Plugins','user','some','parameters','attributes','catch','root','readdirSync','script','port','Invalid\x20manifest:\x20name\x20missing','api','VIRTUAL','Invalid\x20manifest:\x20script\x20path\x20missing','isFile','rows','Extracted\x20folder\x20removed','../../components/parsers/qs','server/files/plugins','fields'];(function(_0x54122d,_0x471c86){const _0x43fd92=function(_0x1e60c0){while(--_0x1e60c0){_0x54122d['push'](_0x54122d['shift']());}};_0x43fd92(++_0x471c86);}(a515_0x471c,0xa9));const a515_0x43fd=function(_0x54122d,_0x471c86){_0x54122d=_0x54122d-0x0;let _0x43fd92=a515_0x471c[_0x54122d];return _0x43fd92;};const _0x575a64=a515_0x43fd;'use strict';const rp=require('request-promise-native'),util=require(_0x575a64('0x54')),path=require(_0x575a64('0x60')),fs=require('fs'),_=require('lodash'),extract=require(_0x575a64('0x1e')),rimraf=require(_0x575a64('0x3c')),archiver=require(_0x575a64('0x8d')),{getSocket}=require(_0x575a64('0x59')),socket=getSocket(),qs=require(_0x575a64('0x7c')),logger=require('../../config/logger')(_0x575a64('0x76')),config=require(_0x575a64('0x88')),db=require(_0x575a64('0x5c'))['db'],{Op}=require(_0x575a64('0x27'));require('./plugin.socket')['register'](socket);function respondWithStatusCode(_0x1e60c0,_0x24225c){return _0x24225c=_0x24225c||0xcc,function(_0x359408){const _0x2df1cb=a515_0x43fd;if(_0x359408)return _0x1e60c0[_0x2df1cb('0x8c')](_0x24225c);return _0x1e60c0[_0x2df1cb('0x19')](_0x24225c)[_0x2df1cb('0xa')]();};}function respondWithResult(_0x36c2a2,_0x24a6bd){return _0x24a6bd=_0x24a6bd||0xc8,function(_0x39557a){const _0xf30aff=a515_0x43fd;if(_0x39557a)return _0x36c2a2['status'](_0x24a6bd)[_0xf30aff('0x45')](_0x39557a);};}function respondWithFilteredResult(_0x537e8e,_0x2f59de){return function(_0x28c16d){const _0x30f4c3=a515_0x43fd;if(_0x28c16d){const _0x159a9e=_0x28c16d[_0x30f4c3('0x43')],_0x46f6eb=_0x2f59de['offset'];let _0x3dcad0=_0x2f59de['offset']+_0x2f59de[_0x30f4c3('0x52')],_0x43fd9f;return _0x3dcad0>=_0x159a9e?(_0x3dcad0=_0x159a9e,_0x43fd9f=0xc8):_0x43fd9f=0xce,_0x537e8e[_0x30f4c3('0x19')](_0x43fd9f),_0x537e8e['set']('Content-Range',_0x46f6eb+'-'+_0x3dcad0+'/'+_0x159a9e)[_0x30f4c3('0x45')](_0x28c16d);}return null;};}function saveUpdates(_0x51021e){return function(_0x269751){const _0x53d85a=a515_0x43fd;if(_0x269751)return _0x269751['update'](_0x51021e)[_0x53d85a('0x35')](function(_0x4f8720){return _0x4f8720;});return null;};}function handleEntityNotFound(_0x1de3f3){return function(_0x3b9777){const _0x2079dd=a515_0x43fd;return!_0x3b9777&&_0x1de3f3[_0x2079dd('0x8c')](0x194),_0x3b9777;};}function handleError(_0x511f7b,_0x33b67a){return _0x33b67a=_0x33b67a||0x1f4,function(_0x159156){const _0x3ae023=a515_0x43fd;logger['error'](_0x159156['stack']),_0x159156[_0x3ae023('0x5f')]&&delete _0x159156[_0x3ae023('0x5f')],_0x511f7b[_0x3ae023('0x19')](_0x33b67a)[_0x3ae023('0x67')](_0x159156);};}exports['index']=function(_0x17f102,_0x39839){const _0x2f17df=_0x575a64;let _0x5811f2={};const _0x5a4415={},_0x26df8e={'count':0x0,'rows':[]},_0x5149f4=_['map'](db[_0x2f17df('0x85')][_0x2f17df('0x5a')],function(_0x1c4273){const _0x495792=_0x2f17df;return{'name':_0x1c4273[_0x495792('0x4a')],'type':_0x1c4273[_0x495792('0x10')]['key']};});_0x5a4415[_0x2f17df('0x83')]=_[_0x2f17df('0x4b')](_0x5149f4,'name'),_0x5a4415['query']=_[_0x2f17df('0x69')](_0x17f102['query']),_0x5a4415[_0x2f17df('0x32')]=_[_0x2f17df('0x12')](_0x5a4415[_0x2f17df('0x83')],_0x5a4415[_0x2f17df('0x29')]),_0x5811f2[_0x2f17df('0x6f')]=_[_0x2f17df('0x12')](_0x5a4415[_0x2f17df('0x83')],qs[_0x2f17df('0x7e')](_0x17f102['query'][_0x2f17df('0x7e')])),_0x5811f2[_0x2f17df('0x6f')]=_0x5811f2['attributes'][_0x2f17df('0x62')]?_0x5811f2['attributes']:_0x5a4415[_0x2f17df('0x83')];typeof _0x17f102[_0x2f17df('0x29')][_0x2f17df('0xd')]===_0x2f17df('0x3a')&&(_0x5811f2['limit']=qs[_0x2f17df('0x52')](_0x17f102['query'][_0x2f17df('0x52')]),_0x5811f2[_0x2f17df('0x53')]=qs['offset'](_0x17f102[_0x2f17df('0x29')]['offset']));_0x5811f2[_0x2f17df('0x91')]=qs[_0x2f17df('0x44')](_0x17f102[_0x2f17df('0x29')]['sort']),_0x5811f2[_0x2f17df('0x23')]=qs[_0x2f17df('0x32')](_[_0x2f17df('0x1f')](_0x17f102[_0x2f17df('0x29')],_0x5a4415[_0x2f17df('0x32')]),_0x5149f4);_0x17f102[_0x2f17df('0x29')][_0x2f17df('0x50')]&&(_0x5811f2['where']=_['merge'](_0x5811f2[_0x2f17df('0x23')],{[Op['or']]:_['map'](_0x5149f4,function(_0x1241e8){const _0x5d409c=_0x2f17df;if(_0x1241e8['type']!==_0x5d409c('0x77')){const _0x52b23a={};return _0x52b23a[_0x1241e8[_0x5d409c('0x5f')]]={[Op[_0x5d409c('0x3')]]:'%'+_0x17f102[_0x5d409c('0x29')][_0x5d409c('0x50')]+'%'},_0x52b23a;}})}));_0x5811f2=_[_0x2f17df('0x30')]({},_0x5811f2,_0x17f102[_0x2f17df('0x82')]);const _0x54fb78={'where':_0x5811f2[_0x2f17df('0x23')]};return db[_0x2f17df('0x85')][_0x2f17df('0x43')](_0x54fb78)['then'](function(_0x1d6bf2){const _0x22abae=_0x2f17df;return _0x26df8e[_0x22abae('0x43')]=_0x1d6bf2,_0x17f102[_0x22abae('0x29')][_0x22abae('0x16')]&&(_0x5811f2[_0x22abae('0x11')]=[{'all':!![]}]),db[_0x22abae('0x85')]['findAll'](_0x5811f2);})[_0x2f17df('0x35')](function(_0x4951e0){const _0x4fa2d9=_0x2f17df;return _0x26df8e[_0x4fa2d9('0x7a')]=_0x4951e0,_0x26df8e;})[_0x2f17df('0x35')](respondWithFilteredResult(_0x39839,_0x5811f2))[_0x2f17df('0x70')](handleError(_0x39839,null));},exports[_0x575a64('0x8e')]=function(_0x2b54e6,_0x23c4e0){const _0x38c535=_0x575a64;let _0x20cf4c={'raw':!![],'where':{'id':_0x2b54e6[_0x38c535('0x92')]['id']}};const _0x1af908={};return _0x1af908[_0x38c535('0x83')]=_['keys'](db[_0x38c535('0x85')][_0x38c535('0x5a')]),_0x1af908[_0x38c535('0x29')]=_[_0x38c535('0x69')](_0x2b54e6[_0x38c535('0x29')]),_0x1af908[_0x38c535('0x32')]=_[_0x38c535('0x12')](_0x1af908[_0x38c535('0x83')],_0x1af908['query']),_0x20cf4c[_0x38c535('0x6f')]=_[_0x38c535('0x12')](_0x1af908[_0x38c535('0x83')],qs[_0x38c535('0x7e')](_0x2b54e6[_0x38c535('0x29')][_0x38c535('0x7e')])),_0x20cf4c['attributes']=_0x20cf4c[_0x38c535('0x6f')][_0x38c535('0x62')]?_0x20cf4c[_0x38c535('0x6f')]:_0x1af908[_0x38c535('0x83')],_0x2b54e6[_0x38c535('0x29')][_0x38c535('0x16')]&&(_0x20cf4c[_0x38c535('0x11')]=[{'all':!![]}]),_0x20cf4c=_[_0x38c535('0x30')]({},_0x20cf4c,_0x2b54e6[_0x38c535('0x82')]),db[_0x38c535('0x85')][_0x38c535('0x25')](_0x20cf4c)[_0x38c535('0x35')](handleEntityNotFound(_0x23c4e0))[_0x38c535('0x35')](respondWithResult(_0x23c4e0,null))[_0x38c535('0x70')](handleError(_0x23c4e0,null));},exports[_0x575a64('0xf')]=function(_0x266294,_0x19dcd5){const _0x3abbcc=_0x575a64;return db[_0x3abbcc('0x85')][_0x3abbcc('0x25')]({'where':{'id':_0x266294['params']['id']},'attributes':[_0x3abbcc('0x5f'),_0x3abbcc('0x60')],'raw':!![]})[_0x3abbcc('0x35')](handleEntityNotFound(_0x19dcd5))[_0x3abbcc('0x35')](function(_0x276f28){const _0x31215f=_0x3abbcc;if(_0x276f28){const _0x155bec=path['join'](config[_0x31215f('0x71')],_0x31215f('0x7d'),util['format'](_0x31215f('0x1a'),path[_0x31215f('0x4c')](_0x276f28[_0x31215f('0x60')]))),_0x55eadc=fs[_0x31215f('0x49')](_0x155bec),_0x5ae0a2=archiver(_0x31215f('0x2'),{'zlib':{'level':0x9}});_0x5ae0a2['on'](_0x31215f('0x48'),function(_0x46b3ee){const _0x2682c9=_0x31215f;if(_0x46b3ee[_0x2682c9('0x4e')]===_0x2682c9('0x81'))logger['error'](_0x46b3ee);else throw new db[(_0x2682c9('0x26'))]['Error'](_0x2682c9('0x1c'));}),_0x5ae0a2['on']('error',function(){const _0x58ebac=_0x31215f;throw new db[(_0x58ebac('0x26'))][(_0x58ebac('0x87'))](_0x58ebac('0x1c'));}),_0x5ae0a2[_0x31215f('0x56')](_0x55eadc),_0x5ae0a2[_0x31215f('0x5e')](_0x31215f('0x5'),{'cwd':path[_0x31215f('0x2d')](config[_0x31215f('0x71')],'server/files/plugins',path[_0x31215f('0x8')](_0x276f28['path'])),'ignore':[path[_0x31215f('0x2d')](path[_0x31215f('0x4c')](_0x276f28[_0x31215f('0x60')]),'node_modules/**/*'),path['join'](path[_0x31215f('0x4c')](_0x276f28[_0x31215f('0x60')]),_0x31215f('0x24'))],'nodir':!![]})[_0x31215f('0x18')](),_0x55eadc['on'](_0x31215f('0x8f'),function(){const _0x2fb587=_0x31215f;if(!fs['existsSync'](_0x155bec))throw new db[(_0x2fb587('0x26'))][(_0x2fb587('0x87'))](_0x2fb587('0x2e'));return _0x19dcd5[_0x2fb587('0xf')](_0x155bec,util['format']('%s.zip',path[_0x2fb587('0x4c')](_0x276f28[_0x2fb587('0x60')])),function(_0x4d003f){const _0x282e0f=_0x2fb587;if(_0x4d003f)throw new db['Sequelize']['Error']('Error\x20while\x20downloading\x20the\x20plugin');fs[_0x282e0f('0xe')](_0x155bec),logger[_0x282e0f('0x46')](_0x282e0f('0x1d')),logger['info'](_0x282e0f('0x40'));});});}return null;})[_0x3abbcc('0x70')](handleError(_0x19dcd5,null));},exports[_0x575a64('0x7')]=function(_0x1821ce,_0x58e043,_0x5d3a3c){const _0xd556a5=_0x575a64,_0xc3ef63=path[_0xd556a5('0x4c')](_0x1821ce['file'][_0xd556a5('0x31')],path[_0xd556a5('0x93')](_0x1821ce['file']['filename'])),_0x380643=path['join'](config[_0xd556a5('0x71')],_0xd556a5('0x7d'),_0x1821ce[_0xd556a5('0x6')][_0xd556a5('0x31')]),_0x37c39b=path[_0xd556a5('0x2d')](config[_0xd556a5('0x71')],_0xd556a5('0x1b'),_0xc3ef63);logger[_0xd556a5('0x46')](_0xd556a5('0x15'),_0x380643),logger[_0xd556a5('0x46')](_0xd556a5('0x3b'),_0x37c39b);try{fs[_0xd556a5('0x90')](_0x380643,parseInt(_0xd556a5('0x1'),0x8)),extract(_0x380643,{'dir':_0x37c39b},function(_0x20e423){const _0x2bb008=_0xd556a5;_0x20e423&&(logger[_0x2bb008('0x2c')](_0x20e423),handleError(_0x20e423,!![]));const _0x3479f7=fs['readdirSync'](_0x37c39b);if(_0x3479f7[_0x2bb008('0x62')]>0x1)return removeReferences(_0x380643,_0x37c39b),logger[_0x2bb008('0x2c')](_0x2bb008('0x17')),_0x5d3a3c(new Error(_0x2bb008('0x17')));const _0x5b4944=fs['lstatSync'](path['join'](_0x37c39b,_0x3479f7[0x0]));if(_0x5b4944[_0x2bb008('0x79')]())return removeReferences(_0x380643,_0x37c39b),logger[_0x2bb008('0x2c')](_0x2bb008('0x17')),_0x5d3a3c(new Error(_0x2bb008('0x17')));if(_0x5b4944['isDirectory']()){const _0x4c7d88=fs[_0x2bb008('0x72')](path[_0x2bb008('0x2d')](_0x37c39b,_0x3479f7[0x0]));if(_0x4c7d88[_0x2bb008('0x62')]===0x0)return removeReferences(_0x380643,_0x37c39b),logger[_0x2bb008('0x2c')](_0x2bb008('0x17')),_0x5d3a3c(new Error(_0x2bb008('0x17')));const _0x5eee4d=_0x4c7d88[_0x2bb008('0x6d')](function(_0x2fde68){const _0x18a95f=_0x2bb008;return _0x2fde68===_0x18a95f('0xc');});if(!_0x5eee4d)return _0x5d3a3c(new Error(_0x2bb008('0x8b')));const _0x2ec8d9=fs[_0x2bb008('0x39')](path['join'](_0x37c39b,_0x3479f7[0x0],_0x2bb008('0xc'))),_0xa3a6f=JSON['parse'](_0x2ec8d9);if(_0x2bb008('0x3a')==typeof _0xa3a6f[_0x2bb008('0x5f')])return _0x5d3a3c(new Error(_0x2bb008('0x75')));if(_0x2bb008('0x3a')==typeof _0xa3a6f[_0x2bb008('0x10')])return _0x5d3a3c(new Error(_0x2bb008('0xb')));if('undefined'==typeof _0xa3a6f[_0x2bb008('0x84')])return _0x5d3a3c(new Error('Invalid\x20manifest:\x20version\x20not\x20specified'));if(_0x2bb008('0x3a')==typeof _0xa3a6f['parameters'])return _0x5d3a3c(new Error('Invalid\x20manifest:\x20parameters\x20missing'));if(_0xa3a6f[_0x2bb008('0x10')]===_0x2bb008('0x20')){if(_0x2bb008('0x3a')==typeof _0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x55')])return _0x5d3a3c(new Error(_0x2bb008('0x4f')));if(_0x2bb008('0x3a')==typeof _0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x55')][_0x2bb008('0x22')]&&_0x2bb008('0x3a')==typeof _0xa3a6f['parameters']['views'][_0x2bb008('0x64')])return _0x5d3a3c(new Error(_0x2bb008('0x4d')));}else{if(_0xa3a6f[_0x2bb008('0x10')]===_0x2bb008('0x73')){if(_0x2bb008('0x3a')==typeof _0xa3a6f[_0x2bb008('0x6e')]['scriptName'])return _0x5d3a3c(new Error('Invalid\x20manifest:\x20script\x20name\x20missing'));if(_0x2bb008('0x3a')==typeof _0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x61')])return _0x5d3a3c(new Error(_0x2bb008('0x78')));}else return _0x5d3a3c(new Error(_0x2bb008('0x86')));}const _0x5f2490=_0xa3a6f[_0x2bb008('0x5f')],_0x55bd0f=_0xa3a6f['description'],_0x3ea8ae=_0xa3a6f[_0x2bb008('0x10')],_0x4e59ef=_0xa3a6f[_0x2bb008('0x42')]?_0xa3a6f[_0x2bb008('0x42')]:_0x2bb008('0x3f'),_0x20b083=_0xa3a6f[_0x2bb008('0x4')]?_0xa3a6f[_0x2bb008('0x4')]:_0x2bb008('0x80');let _0x3b1989='',_0x3b516a='',_0x2ab506='',_0x1df377='';const _0x50baaf=_0xa3a6f[_0x2bb008('0x84')];if(_0x3ea8ae===_0x2bb008('0x20')){if(_0x2bb008('0x3a')!=typeof _0xa3a6f['parameters']['views'][_0x2bb008('0x22')]){const _0x49dff7=_0xa3a6f[_0x2bb008('0x6e')]['views'][_0x2bb008('0x22')];!/^(f|ht)tps?:\/\//i['test'](_0x49dff7)?_0x3b1989=path[_0x2bb008('0x2d')](_0x2bb008('0x38'),_0xc3ef63,_0x3479f7[0x0],_0x49dff7):_0x3b1989=_0x49dff7;}else logger['info']('Warning:\x20admin\x20view\x20not\x20specified');if(_0x2bb008('0x3a')!=typeof _0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x55')][_0x2bb008('0x64')]){const _0x386a2f=_0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x55')][_0x2bb008('0x64')];!/^(f|ht)tps?:\/\//i[_0x2bb008('0x3e')](_0x386a2f)?_0x3b516a=path[_0x2bb008('0x2d')](_0x2bb008('0x38'),_0xc3ef63,_0x3479f7[0x0],_0x386a2f):_0x3b516a=_0x386a2f;}else logger[_0x2bb008('0x46')](_0x2bb008('0x36'));}else{if(_0x3ea8ae===_0x2bb008('0x73')){_0x2ab506=_0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x66')],_0x1df377=_0xa3a6f[_0x2bb008('0x6e')]['scriptPath'];if('undefined'!=typeof _0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x55')]){if(_0x2bb008('0x3a')!=typeof _0xa3a6f['parameters'][_0x2bb008('0x55')][_0x2bb008('0x22')]){const _0xd38661=_0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x55')]['admin'];!/^(f|ht)tps?:\/\//i[_0x2bb008('0x3e')](_0xd38661)?_0x3b1989=path[_0x2bb008('0x2d')](_0x2bb008('0x38'),_0xc3ef63,_0x3479f7[0x0],_0xd38661):_0x3b1989=_0xd38661;}if(_0x2bb008('0x3a')!=typeof _0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x55')][_0x2bb008('0x64')]){const _0x349689=_0xa3a6f[_0x2bb008('0x6e')][_0x2bb008('0x55')][_0x2bb008('0x64')];!/^(f|ht)tps?:\/\//i['test'](_0x349689)?_0x3b516a=path[_0x2bb008('0x2d')](_0x2bb008('0x38'),_0xc3ef63,_0x3479f7[0x0],_0x349689):_0x3b516a=_0x349689;}}}}const _0x4efe8a={'name':_0x5f2490,'description':_0x55bd0f,'path':path[_0x2bb008('0x2d')](_0xc3ef63,_0x3479f7[0x0]),'type':_0x3ea8ae,'sidebar':_0x4e59ef,'icon':_0x20b083,'adminUrl':_0x3b1989,'agentUrl':_0x3b516a,'scriptName':_0x2ab506,'scriptPath':_0x1df377,'version':_0x50baaf};return removeReferences(_0x380643,null),db['Plugin'][_0x2bb008('0x9')](_0x4efe8a)[_0x2bb008('0x35')](function(_0x2ceac6){const _0x461750=_0x2bb008,_0x32f2d9={'role':_0x1821ce['body'][_0x461750('0x33')],'userProfileId':_0x1821ce[_0x461750('0x2f')]['userProfileId']};if(!_0x32f2d9)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x32f2d9[_0x461750('0x33')]===_0x461750('0x6c')){const _0x41ad7d=_0x2ceac6[_0x461750('0x63')]({'plain':!![]});return db[_0x461750('0x21')][_0x461750('0x25')]({'where':{'name':_0x461750('0x6b'),'userProfileId':_0x32f2d9[_0x461750('0x0')]},'raw':!![]})[_0x461750('0x35')](function(_0x22358d){const _0x1fd0d0=_0x461750;return _0x22358d&&_0x22358d['autoAssociation']===0x0?db[_0x1fd0d0('0x2a')]['create']({'name':_0x41ad7d[_0x1fd0d0('0x5f')],'resourceId':_0x41ad7d['id'],'type':_0x22358d[_0x1fd0d0('0x5f')],'sectionId':_0x22358d['id']},{})[_0x1fd0d0('0x35')](function(){return _0x2ceac6;}):_0x2ceac6;})[_0x461750('0x70')](function(_0x1c8d28){const _0x3c442d=_0x461750;logger[_0x3c442d('0x2c')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x1c8d28);throw _0x1c8d28;});}return _0x2ceac6;})[_0x2bb008('0x35')](respondWithResult(_0x58e043,null))[_0x2bb008('0x70')](handleError(_0x58e043,null));}});}catch(_0x2dfeee){_0x58e043[_0xd556a5('0x19')](0x1f4)[_0xd556a5('0x67')](_0x2dfeee);}};function removeReferences(_0x24759d,_0x2e8651){const _0x24ee71=_0x575a64;try{_0x24759d&&(fs[_0x24ee71('0xe')](_0x24759d),logger[_0x24ee71('0x46')]('Zip\x20archive\x20removed')),_0x2e8651&&(rimraf(_0x2e8651,function(){}),logger[_0x24ee71('0x46')](_0x24ee71('0x7b')));}catch(_0xf1bc03){logger[_0x24ee71('0x2c')](_0xf1bc03);}}exports[_0x575a64('0x28')]=function(_0x285a97,_0xb22664){const _0x2f7e1a=_0x575a64;return db[_0x2f7e1a('0x85')]['findOne']({'where':{'id':_0x285a97['params']['id']}})[_0x2f7e1a('0x35')](handleEntityNotFound(_0xb22664))['then'](saveUpdates(_0x285a97[_0x2f7e1a('0x2f')]))[_0x2f7e1a('0x35')](respondWithResult(_0xb22664,null))['catch'](handleError(_0xb22664,null));},exports[_0x575a64('0x3d')]=function(_0x21157e,_0x3877df){const _0x52a637=_0x575a64;return db['Plugin'][_0x52a637('0x25')]({'where':{'id':_0x21157e[_0x52a637('0x92')]['id']}})['then'](function(_0x2bb0e6){const _0x1e19e4=_0x52a637;if(_0x2bb0e6)return _0x2bb0e6[_0x1e19e4('0x65')]();})[_0x52a637('0x35')](function(_0x1a84d3){const _0x248cbc=_0x52a637;return rimraf(path['join'](config[_0x248cbc('0x71')],_0x248cbc('0x7d'),path['dirname'](_0x1a84d3[_0x248cbc('0x60')])),function(){}),_0x1a84d3;})[_0x52a637('0x35')](handleEntityNotFound(_0x3877df))[_0x52a637('0x35')](respondWithStatusCode(_0x3877df,null))[_0x52a637('0x70')](handleError(_0x3877df,null));},exports[_0x575a64('0x34')]=function(_0x50abf9,_0x5a6020){const _0x489272=_0x575a64;return Promise[_0x489272('0x7f')]()[_0x489272('0x35')](function(){const _0xbc9b33=_0x489272;if(!_0x50abf9[_0xbc9b33('0x29')]['path'])throw new Error(_0xbc9b33('0x68'));if(!_0x50abf9[_0xbc9b33('0x29')][_0xbc9b33('0x74')])throw new Error(_0xbc9b33('0x5d'));const _0x356c93=_0x50abf9[_0xbc9b33('0x29')]['hostname']?_0x50abf9[_0xbc9b33('0x29')][_0xbc9b33('0x6a')]+':'+_0x50abf9[_0xbc9b33('0x29')][_0xbc9b33('0x74')]:'http://localhost:'+_0x50abf9[_0xbc9b33('0x29')][_0xbc9b33('0x74')],_0xe17c0=_0x50abf9['query'][_0xbc9b33('0x45')]?_0x50abf9[_0xbc9b33('0x29')][_0xbc9b33('0x45')]:!![],_0x4bbcd8=_0x50abf9['query']['encoding']?_0x50abf9[_0xbc9b33('0x29')][_0xbc9b33('0x8a')]:null,_0x39d611={'method':_0x50abf9[_0xbc9b33('0x58')],'uri':util['format'](_0xbc9b33('0x37'),_0x356c93,_0x50abf9['query']['path']),'json':_0xe17c0,'resolveWithFullResponse':!![],'encoding':_0x4bbcd8,'qs':_0x50abf9[_0xbc9b33('0x29')]};return _0x50abf9[_0xbc9b33('0x13')]&&(_0x39d611[_0xbc9b33('0x13')]=_0x50abf9[_0xbc9b33('0x13')],_0x39d611[_0xbc9b33('0x13')][_0xbc9b33('0x5b')]&&delete _0x39d611[_0xbc9b33('0x13')][_0xbc9b33('0x5b')]),_0x39d611['headers'][_0xbc9b33('0x41')]&&delete _0x39d611[_0xbc9b33('0x13')]['content-type'],rp(_0x39d611);})[_0x489272('0x35')](function(_0x2f1ce3){const _0x5c287e=_0x489272;return _0x2f1ce3?(_0x5a6020[_0x5c287e('0x14')](_0x2f1ce3[_0x5c287e('0x13')]),logger[_0x5c287e('0x46')](_0x2f1ce3['body']),_[_0x5c287e('0x51')](_0x50abf9[_0x5c287e('0x29')][_0x5c287e('0x60')],_0x5c287e('0xf'))&&_0x2f1ce3[_0x5c287e('0x89')]==0x1f4?_0x5a6020['sendStatus'](_0x2f1ce3[_0x5c287e('0x89')]):_0x5a6020[_0x5c287e('0x19')](_0x2f1ce3[_0x5c287e('0x89')])[_0x5c287e('0x67')](_0x2f1ce3[_0x5c287e('0x2f')])):_0x5a6020[_0x5c287e('0x8c')](0xc8);})[_0x489272('0x70')](handleError(_0x5a6020,null));},exports[_0x575a64('0x57')]=function(_0x50ca65,_0xb78dba){const _0x4ef666=_0x575a64;return Promise[_0x4ef666('0x7f')]()[_0x4ef666('0x35')](function(){const _0x3e9850=_0x4ef666;if(!_0x50ca65[_0x3e9850('0x29')][_0x3e9850('0x60')])throw new Error(_0x3e9850('0x68'));if(!_0x50ca65['query'][_0x3e9850('0x74')])throw new Error(_0x3e9850('0x5d'));const _0x48c246=_0x50ca65[_0x3e9850('0x29')][_0x3e9850('0x6a')]?_0x50ca65['query']['hostname']+':'+_0x50ca65[_0x3e9850('0x29')][_0x3e9850('0x74')]:_0x3e9850('0x47')+_0x50ca65[_0x3e9850('0x29')][_0x3e9850('0x74')],_0x24ccf7=_0x50ca65['query'][_0x3e9850('0x45')]?_0x50ca65[_0x3e9850('0x29')][_0x3e9850('0x45')]:!![],_0x849043=_0x50ca65['query'][_0x3e9850('0x8a')]?_0x50ca65[_0x3e9850('0x29')][_0x3e9850('0x8a')]:null,_0x222de2={'method':_0x50ca65[_0x3e9850('0x58')],'uri':util[_0x3e9850('0x2b')]('%s%s',_0x48c246,_0x50ca65[_0x3e9850('0x29')][_0x3e9850('0x60')]),'json':_0x24ccf7,'resolveWithFullResponse':!![],'encoding':_0x849043,'body':_0x50ca65['body']};return _0x50ca65['headers']&&(_0x222de2[_0x3e9850('0x13')]=_0x50ca65['headers'],_0x222de2[_0x3e9850('0x13')][_0x3e9850('0x5b')]&&delete _0x222de2['headers']['content-length']),_0x222de2[_0x3e9850('0x13')][_0x3e9850('0x41')]&&delete _0x222de2['headers'][_0x3e9850('0x41')],rp(_0x222de2);})[_0x4ef666('0x35')](function(_0x19dd38){const _0x440b6a=_0x4ef666;return _0x19dd38?(_0xb78dba[_0x440b6a('0x14')](_0x19dd38['headers']),logger[_0x440b6a('0x46')](_0x19dd38['body']),_0xb78dba[_0x440b6a('0x19')](_0x19dd38['statusCode'])[_0x440b6a('0x67')](_0x19dd38[_0x440b6a('0x2f')])):_0xb78dba[_0x440b6a('0x8c')](0xc8);})['catch'](handleError(_0xb78dba,null));}; \ No newline at end of file +const a515_0x558e=['api','Plugin\x20upload\x20destination:\x20%s','format','admin','Invalid\x20manifest:\x20parameters\x20missing','Invalid\x20plugin\x20structure','Download\x20completed','sort','Invalid\x20manifest:\x20name\x20missing','get','archiver','Extracted\x20folder\x20removed','plugins','Unable\x20to\x20retrieve\x20the\x20current\x20user','Invalid\x20manifest:\x20invalid\x20type','version','resolve','sequelize','index','pick','pipe','file','headers','**/*','undefined','intersection','Invalid\x20manifest:\x20no\x20view\x20specified','delete','isDirectory','encoding','readdirSync','some','Zip\x20archive\x20removed','Error','%s.zip','lodash','close','name','findOne','Plugins','../../components/parsers/qs','\x27PATH\x27\x20parameter\x20not\x20specified','autoAssociation','map','chmodSync','readFileSync','Plugin\x20upload\x20filepath:\x20%s','download','Error\x20while\x20generating\x20the\x20zip\x20archive','body','agent','util','method','Invalid\x20manifest:\x20version\x20not\x20specified','options','merge','set','sendStatus','icon-apps','extract-zip','offset','limit','files/plugins','manifest.json','unlinkSync','test','statusCode','info','count','attachments/**/*','filter','server/files/plugins','node_modules/**/*','params','model','root','script','isFile','VIRTUAL','basename','show','then','\x27PORT\x27\x20parameter\x20not\x20specified','includeAll','glob','type','query','UserProfileResource','include','content-type','Warning:\x20agent\x20view\x20not\x20specified','rimraf','0777','../../config/environment','Invalid\x20manifest:\x20script\x20name\x20missing','filename','views','./plugin.socket','stack','icon','path','port','../../mysqldb','Invalid\x20manifest:\x20script\x20path\x20missing','parameters','userProfileId','where','code','finalize','dirname','catch','%s%s','hostname','attributes','order','http://localhost:','update','rawAttributes','extname','json','parse','html','nolimit','Content-Range','scriptName','error','always','Warning:\x20admin\x20view\x20not\x20specified','existsSync','filters','Invalid\x20manifest:\x20type\x20missing','status','request-promise-native','rows','join','fields','endsWith','length','scriptPath','Error\x20while\x20downloading\x20the\x20plugin','fieldName','role','destroy','ENOENT','send','Plugin','content-length','sidebar','Temporary\x20file\x20removed','like','UserProfileSection','keys','Sequelize','createWriteStream','register'];(function(_0x53bdda,_0x558e01){const _0x5722bb=function(_0x3ebffd){while(--_0x3ebffd){_0x53bdda['push'](_0x53bdda['shift']());}};_0x5722bb(++_0x558e01);}(a515_0x558e,0x109));const a515_0x5722=function(_0x53bdda,_0x558e01){_0x53bdda=_0x53bdda-0x0;let _0x5722bb=a515_0x558e[_0x53bdda];return _0x5722bb;};const _0x4d7cfe=a515_0x5722;'use strict';const rp=require(_0x4d7cfe('0x16')),util=require(_0x4d7cfe('0x60')),path=require(_0x4d7cfe('0x91')),fs=require('fs'),_=require(_0x4d7cfe('0x50')),extract=require(_0x4d7cfe('0x68')),rimraf=require(_0x4d7cfe('0x88')),archiver=require(_0x4d7cfe('0x37')),{getSocket}=require('../../rediscache'),socket=getSocket(),qs=require(_0x4d7cfe('0x55')),logger=require('../../config/logger')(_0x4d7cfe('0x2d')),config=require(_0x4d7cfe('0x8a')),db=require(_0x4d7cfe('0x93'))['db'],{Op}=require(_0x4d7cfe('0x3e'));require(_0x4d7cfe('0x8e'))[_0x4d7cfe('0x2c')](socket);function respondWithStatusCode(_0x3ebffd,_0x299dd3){return _0x299dd3=_0x299dd3||0xcc,function(_0x5c507d){const _0x203e7e=a515_0x5722;if(_0x5c507d)return _0x3ebffd[_0x203e7e('0x66')](_0x299dd3);return _0x3ebffd[_0x203e7e('0x15')](_0x299dd3)['end']();};}function respondWithResult(_0x2d5b00,_0x3c5392){return _0x3c5392=_0x3c5392||0xc8,function(_0x16f0d2){const _0x1a76de=a515_0x5722;if(_0x16f0d2)return _0x2d5b00[_0x1a76de('0x15')](_0x3c5392)[_0x1a76de('0x9')](_0x16f0d2);};}function respondWithFilteredResult(_0x104cf4,_0x3600c1){return function(_0x5d4b1b){const _0x18ef35=a515_0x5722;if(_0x5d4b1b){const _0x167ca7=_0x5d4b1b[_0x18ef35('0x71')],_0xc027dd=_0x3600c1[_0x18ef35('0x69')];let _0x3e0237=_0x3600c1[_0x18ef35('0x69')]+_0x3600c1[_0x18ef35('0x6a')],_0x1ab988;return _0x3e0237>=_0x167ca7?(_0x3e0237=_0x167ca7,_0x1ab988=0xc8):_0x1ab988=0xce,_0x104cf4['status'](_0x1ab988),_0x104cf4['set'](_0x18ef35('0xd'),_0xc027dd+'-'+_0x3e0237+'/'+_0x167ca7)[_0x18ef35('0x9')](_0x5d4b1b);}return null;};}function saveUpdates(_0x1d360c){return function(_0x2f7d97){const _0x3c28fa=a515_0x5722;if(_0x2f7d97)return _0x2f7d97['update'](_0x1d360c)[_0x3c28fa('0x7e')](function(_0x5b9c34){return _0x5b9c34;});return null;};}function handleEntityNotFound(_0x566470){return function(_0x4ecbce){return!_0x4ecbce&&_0x566470['sendStatus'](0x194),_0x4ecbce;};}function handleError(_0x5cae75,_0x48e0e1){return _0x48e0e1=_0x48e0e1||0x1f4,function(_0x36df23){const _0x2443ce=a515_0x5722;logger[_0x2443ce('0xf')](_0x36df23[_0x2443ce('0x8f')]),_0x36df23[_0x2443ce('0x52')]&&delete _0x36df23['name'],_0x5cae75[_0x2443ce('0x15')](_0x48e0e1)[_0x2443ce('0x22')](_0x36df23);};}exports[_0x4d7cfe('0x3f')]=function(_0x18f25a,_0x4ae1c4){const _0x3eba7d=_0x4d7cfe;let _0x3246a0={};const _0x389250={},_0x9e51ac={'count':0x0,'rows':[]},_0x2082eb=_[_0x3eba7d('0x58')](db[_0x3eba7d('0x23')][_0x3eba7d('0x7')],function(_0x4c6301){const _0x1ebcb1=_0x3eba7d;return{'name':_0x4c6301[_0x1ebcb1('0x1e')],'type':_0x4c6301[_0x1ebcb1('0x82')]['key']};});_0x389250[_0x3eba7d('0x77')]=_['map'](_0x2082eb,_0x3eba7d('0x52')),_0x389250[_0x3eba7d('0x83')]=_[_0x3eba7d('0x29')](_0x18f25a[_0x3eba7d('0x83')]),_0x389250[_0x3eba7d('0x13')]=_[_0x3eba7d('0x46')](_0x389250['model'],_0x389250['query']),_0x3246a0[_0x3eba7d('0x3')]=_[_0x3eba7d('0x46')](_0x389250['model'],qs[_0x3eba7d('0x19')](_0x18f25a['query'][_0x3eba7d('0x19')])),_0x3246a0[_0x3eba7d('0x3')]=_0x3246a0[_0x3eba7d('0x3')]['length']?_0x3246a0[_0x3eba7d('0x3')]:_0x389250['model'];typeof _0x18f25a['query'][_0x3eba7d('0xc')]===_0x3eba7d('0x45')&&(_0x3246a0[_0x3eba7d('0x6a')]=qs[_0x3eba7d('0x6a')](_0x18f25a[_0x3eba7d('0x83')][_0x3eba7d('0x6a')]),_0x3246a0[_0x3eba7d('0x69')]=qs[_0x3eba7d('0x69')](_0x18f25a[_0x3eba7d('0x83')]['offset']));_0x3246a0[_0x3eba7d('0x4')]=qs[_0x3eba7d('0x34')](_0x18f25a[_0x3eba7d('0x83')][_0x3eba7d('0x34')]),_0x3246a0[_0x3eba7d('0x97')]=qs[_0x3eba7d('0x13')](_[_0x3eba7d('0x40')](_0x18f25a['query'],_0x389250[_0x3eba7d('0x13')]),_0x2082eb);_0x18f25a[_0x3eba7d('0x83')]['filter']&&(_0x3246a0[_0x3eba7d('0x97')]=_['merge'](_0x3246a0[_0x3eba7d('0x97')],{[Op['or']]:_[_0x3eba7d('0x58')](_0x2082eb,function(_0x77bceb){const _0x4cfc7c=_0x3eba7d;if(_0x77bceb[_0x4cfc7c('0x82')]!==_0x4cfc7c('0x7b')){const _0x31735d={};return _0x31735d[_0x77bceb['name']]={[Op[_0x4cfc7c('0x27')]]:'%'+_0x18f25a[_0x4cfc7c('0x83')][_0x4cfc7c('0x73')]+'%'},_0x31735d;}})}));_0x3246a0=_[_0x3eba7d('0x64')]({},_0x3246a0,_0x18f25a[_0x3eba7d('0x63')]);const _0x1d911a={'where':_0x3246a0[_0x3eba7d('0x97')]};return db['Plugin']['count'](_0x1d911a)[_0x3eba7d('0x7e')](function(_0xdaa48){const _0x36b15b=_0x3eba7d;return _0x9e51ac[_0x36b15b('0x71')]=_0xdaa48,_0x18f25a['query']['includeAll']&&(_0x3246a0['include']=[{'all':!![]}]),db['Plugin']['findAll'](_0x3246a0);})[_0x3eba7d('0x7e')](function(_0x515a40){const _0x1681f1=_0x3eba7d;return _0x9e51ac[_0x1681f1('0x17')]=_0x515a40,_0x9e51ac;})[_0x3eba7d('0x7e')](respondWithFilteredResult(_0x4ae1c4,_0x3246a0))['catch'](handleError(_0x4ae1c4,null));},exports[_0x4d7cfe('0x7d')]=function(_0xecc9ca,_0x416502){const _0x1352ba=_0x4d7cfe;let _0x2dce9e={'raw':!![],'where':{'id':_0xecc9ca[_0x1352ba('0x76')]['id']}};const _0x5358c3={};return _0x5358c3[_0x1352ba('0x77')]=_['keys'](db['Plugin'][_0x1352ba('0x7')]),_0x5358c3['query']=_[_0x1352ba('0x29')](_0xecc9ca[_0x1352ba('0x83')]),_0x5358c3[_0x1352ba('0x13')]=_[_0x1352ba('0x46')](_0x5358c3[_0x1352ba('0x77')],_0x5358c3[_0x1352ba('0x83')]),_0x2dce9e[_0x1352ba('0x3')]=_[_0x1352ba('0x46')](_0x5358c3['model'],qs[_0x1352ba('0x19')](_0xecc9ca[_0x1352ba('0x83')]['fields'])),_0x2dce9e[_0x1352ba('0x3')]=_0x2dce9e['attributes'][_0x1352ba('0x1b')]?_0x2dce9e['attributes']:_0x5358c3[_0x1352ba('0x77')],_0xecc9ca[_0x1352ba('0x83')][_0x1352ba('0x80')]&&(_0x2dce9e[_0x1352ba('0x85')]=[{'all':!![]}]),_0x2dce9e=_[_0x1352ba('0x64')]({},_0x2dce9e,_0xecc9ca['options']),db[_0x1352ba('0x23')]['findOne'](_0x2dce9e)['then'](handleEntityNotFound(_0x416502))[_0x1352ba('0x7e')](respondWithResult(_0x416502,null))[_0x1352ba('0x0')](handleError(_0x416502,null));},exports[_0x4d7cfe('0x5c')]=function(_0x4c71e7,_0x45a746){const _0x129b47=_0x4d7cfe;return db[_0x129b47('0x23')][_0x129b47('0x53')]({'where':{'id':_0x4c71e7[_0x129b47('0x76')]['id']},'attributes':[_0x129b47('0x52'),_0x129b47('0x91')],'raw':!![]})['then'](handleEntityNotFound(_0x45a746))[_0x129b47('0x7e')](function(_0x2497e5){const _0x348560=_0x129b47;if(_0x2497e5){const _0x485b06=path['join'](config['root'],'server/files/plugins',util[_0x348560('0x2f')](_0x348560('0x4f'),path[_0x348560('0x7c')](_0x2497e5[_0x348560('0x91')]))),_0x2b9fb7=fs[_0x348560('0x2b')](_0x485b06),_0x51ab57=archiver('zip',{'zlib':{'level':0x9}});_0x51ab57['on']('warning',function(_0xff345f){const _0x5b971d=_0x348560;if(_0xff345f[_0x5b971d('0x98')]===_0x5b971d('0x21'))logger[_0x5b971d('0xf')](_0xff345f);else throw new db[(_0x5b971d('0x2a'))]['Error'](_0x5b971d('0x5d'));}),_0x51ab57['on'](_0x348560('0xf'),function(){const _0x55c9ca=_0x348560;throw new db[(_0x55c9ca('0x2a'))]['Error'](_0x55c9ca('0x5d'));}),_0x51ab57[_0x348560('0x41')](_0x2b9fb7),_0x51ab57[_0x348560('0x81')](_0x348560('0x44'),{'cwd':path[_0x348560('0x18')](config[_0x348560('0x78')],_0x348560('0x74'),path[_0x348560('0x9a')](_0x2497e5[_0x348560('0x91')])),'ignore':[path[_0x348560('0x18')](path[_0x348560('0x7c')](_0x2497e5[_0x348560('0x91')]),_0x348560('0x75')),path[_0x348560('0x18')](path[_0x348560('0x7c')](_0x2497e5[_0x348560('0x91')]),_0x348560('0x72'))],'nodir':!![]})[_0x348560('0x99')](),_0x2b9fb7['on'](_0x348560('0x51'),function(){const _0xa03074=_0x348560;if(!fs[_0xa03074('0x12')](_0x485b06))throw new db['Sequelize']['Error']('Plugin\x20not\x20found');return _0x45a746[_0xa03074('0x5c')](_0x485b06,util[_0xa03074('0x2f')](_0xa03074('0x4f'),path[_0xa03074('0x7c')](_0x2497e5[_0xa03074('0x91')])),function(_0x5f4e6c){const _0x577b62=_0xa03074;if(_0x5f4e6c)throw new db[(_0x577b62('0x2a'))][(_0x577b62('0x4e'))](_0x577b62('0x1d'));fs[_0x577b62('0x6d')](_0x485b06),logger[_0x577b62('0x70')](_0x577b62('0x33')),logger[_0x577b62('0x70')](_0x577b62('0x26'));});});}return null;})[_0x129b47('0x0')](handleError(_0x45a746,null));},exports['upload']=function(_0x19e6d,_0x70b256,_0x34f7a3){const _0x2d3585=_0x4d7cfe,_0x351516=path[_0x2d3585('0x7c')](_0x19e6d[_0x2d3585('0x42')][_0x2d3585('0x8c')],path[_0x2d3585('0x8')](_0x19e6d[_0x2d3585('0x42')][_0x2d3585('0x8c')])),_0x22abd3=path[_0x2d3585('0x18')](config[_0x2d3585('0x78')],_0x2d3585('0x74'),_0x19e6d[_0x2d3585('0x42')][_0x2d3585('0x8c')]),_0x179651=path[_0x2d3585('0x18')](config['root'],_0x2d3585('0x6b'),_0x351516);logger[_0x2d3585('0x70')](_0x2d3585('0x5b'),_0x22abd3),logger[_0x2d3585('0x70')](_0x2d3585('0x2e'),_0x179651);try{fs[_0x2d3585('0x59')](_0x22abd3,parseInt(_0x2d3585('0x89'),0x8)),extract(_0x22abd3,{'dir':_0x179651},function(_0x3afcce){const _0x325b6f=_0x2d3585;_0x3afcce&&(logger[_0x325b6f('0xf')](_0x3afcce),handleError(_0x3afcce,!![]));const _0xa53493=fs[_0x325b6f('0x4b')](_0x179651);if(_0xa53493[_0x325b6f('0x1b')]>0x1)return removeReferences(_0x22abd3,_0x179651),logger[_0x325b6f('0xf')](_0x325b6f('0x32')),_0x34f7a3(new Error(_0x325b6f('0x32')));const _0x5d9822=fs['lstatSync'](path[_0x325b6f('0x18')](_0x179651,_0xa53493[0x0]));if(_0x5d9822[_0x325b6f('0x7a')]())return removeReferences(_0x22abd3,_0x179651),logger[_0x325b6f('0xf')](_0x325b6f('0x32')),_0x34f7a3(new Error('Invalid\x20plugin\x20structure'));if(_0x5d9822[_0x325b6f('0x49')]()){const _0x9c7e62=fs[_0x325b6f('0x4b')](path[_0x325b6f('0x18')](_0x179651,_0xa53493[0x0]));if(_0x9c7e62[_0x325b6f('0x1b')]===0x0)return removeReferences(_0x22abd3,_0x179651),logger[_0x325b6f('0xf')](_0x325b6f('0x32')),_0x34f7a3(new Error('Invalid\x20plugin\x20structure'));const _0x2973aa=_0x9c7e62[_0x325b6f('0x4c')](function(_0x157232){return _0x157232==='manifest.json';});if(!_0x2973aa)return _0x34f7a3(new Error('Plugin\x20manifest\x20missing'));const _0x35a180=fs[_0x325b6f('0x5a')](path[_0x325b6f('0x18')](_0x179651,_0xa53493[0x0],_0x325b6f('0x6c'))),_0xbf1deb=JSON[_0x325b6f('0xa')](_0x35a180);if(_0x325b6f('0x45')==typeof _0xbf1deb[_0x325b6f('0x52')])return _0x34f7a3(new Error(_0x325b6f('0x35')));if('undefined'==typeof _0xbf1deb[_0x325b6f('0x82')])return _0x34f7a3(new Error(_0x325b6f('0x14')));if(_0x325b6f('0x45')==typeof _0xbf1deb['version'])return _0x34f7a3(new Error(_0x325b6f('0x62')));if(_0x325b6f('0x45')==typeof _0xbf1deb[_0x325b6f('0x95')])return _0x34f7a3(new Error(_0x325b6f('0x31')));if(_0xbf1deb[_0x325b6f('0x82')]===_0x325b6f('0xb')){if(_0x325b6f('0x45')==typeof _0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x8d')])return _0x34f7a3(new Error('Invalid\x20manifest:\x20views\x20missing'));if(_0x325b6f('0x45')==typeof _0xbf1deb[_0x325b6f('0x95')]['views']['admin']&&_0x325b6f('0x45')==typeof _0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x8d')]['agent'])return _0x34f7a3(new Error(_0x325b6f('0x47')));}else{if(_0xbf1deb[_0x325b6f('0x82')]===_0x325b6f('0x79')){if(_0x325b6f('0x45')==typeof _0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0xe')])return _0x34f7a3(new Error(_0x325b6f('0x8b')));if(_0x325b6f('0x45')==typeof _0xbf1deb['parameters'][_0x325b6f('0x1c')])return _0x34f7a3(new Error(_0x325b6f('0x94')));}else return _0x34f7a3(new Error(_0x325b6f('0x3b')));}const _0x1d7f99=_0xbf1deb[_0x325b6f('0x52')],_0x6b6d23=_0xbf1deb['description'],_0x4adb97=_0xbf1deb['type'],_0x57431f=_0xbf1deb[_0x325b6f('0x25')]?_0xbf1deb['sidebar']:_0x325b6f('0x10'),_0x3f7800=_0xbf1deb[_0x325b6f('0x90')]?_0xbf1deb[_0x325b6f('0x90')]:_0x325b6f('0x67');let _0xa6f17c='',_0x420e95='',_0x47b017='',_0x42d215='';const _0x3208f0=_0xbf1deb[_0x325b6f('0x3c')];if(_0x4adb97===_0x325b6f('0xb')){if(_0x325b6f('0x45')!=typeof _0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x8d')][_0x325b6f('0x30')]){const _0x45f946=_0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x8d')][_0x325b6f('0x30')];!/^(f|ht)tps?:\/\//i[_0x325b6f('0x6e')](_0x45f946)?_0xa6f17c=path[_0x325b6f('0x18')](_0x325b6f('0x39'),_0x351516,_0xa53493[0x0],_0x45f946):_0xa6f17c=_0x45f946;}else logger[_0x325b6f('0x70')](_0x325b6f('0x11'));if('undefined'!=typeof _0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x8d')][_0x325b6f('0x5f')]){const _0x35da90=_0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x8d')]['agent'];!/^(f|ht)tps?:\/\//i[_0x325b6f('0x6e')](_0x35da90)?_0x420e95=path[_0x325b6f('0x18')](_0x325b6f('0x39'),_0x351516,_0xa53493[0x0],_0x35da90):_0x420e95=_0x35da90;}else logger[_0x325b6f('0x70')](_0x325b6f('0x87'));}else{if(_0x4adb97===_0x325b6f('0x79')){_0x47b017=_0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0xe')],_0x42d215=_0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x1c')];if(_0x325b6f('0x45')!=typeof _0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x8d')]){if('undefined'!=typeof _0xbf1deb['parameters'][_0x325b6f('0x8d')]['admin']){const _0x24ec4d=_0xbf1deb[_0x325b6f('0x95')]['views'][_0x325b6f('0x30')];!/^(f|ht)tps?:\/\//i[_0x325b6f('0x6e')](_0x24ec4d)?_0xa6f17c=path[_0x325b6f('0x18')](_0x325b6f('0x39'),_0x351516,_0xa53493[0x0],_0x24ec4d):_0xa6f17c=_0x24ec4d;}if('undefined'!=typeof _0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x8d')][_0x325b6f('0x5f')]){const _0x284192=_0xbf1deb[_0x325b6f('0x95')][_0x325b6f('0x8d')][_0x325b6f('0x5f')];!/^(f|ht)tps?:\/\//i[_0x325b6f('0x6e')](_0x284192)?_0x420e95=path[_0x325b6f('0x18')]('plugins',_0x351516,_0xa53493[0x0],_0x284192):_0x420e95=_0x284192;}}}}const _0x485e75={'name':_0x1d7f99,'description':_0x6b6d23,'path':path[_0x325b6f('0x18')](_0x351516,_0xa53493[0x0]),'type':_0x4adb97,'sidebar':_0x57431f,'icon':_0x3f7800,'adminUrl':_0xa6f17c,'agentUrl':_0x420e95,'scriptName':_0x47b017,'scriptPath':_0x42d215,'version':_0x3208f0};return removeReferences(_0x22abd3,null),db[_0x325b6f('0x23')]['create'](_0x485e75)[_0x325b6f('0x7e')](function(_0x35ff8d){const _0x22ede8=_0x325b6f,_0x500789={'role':_0x19e6d[_0x22ede8('0x5e')][_0x22ede8('0x1f')],'userProfileId':_0x19e6d[_0x22ede8('0x5e')][_0x22ede8('0x96')]};if(!_0x500789)throw new Error(_0x22ede8('0x3a'));if(_0x500789['role']==='user'){const _0x20820b=_0x35ff8d[_0x22ede8('0x36')]({'plain':!![]});return db[_0x22ede8('0x28')][_0x22ede8('0x53')]({'where':{'name':_0x22ede8('0x54'),'userProfileId':_0x500789[_0x22ede8('0x96')]},'raw':!![]})[_0x22ede8('0x7e')](function(_0x5cba25){const _0x4c893c=_0x22ede8;return _0x5cba25&&_0x5cba25[_0x4c893c('0x57')]===0x0?db[_0x4c893c('0x84')]['create']({'name':_0x20820b[_0x4c893c('0x52')],'resourceId':_0x20820b['id'],'type':_0x5cba25[_0x4c893c('0x52')],'sectionId':_0x5cba25['id']},{})[_0x4c893c('0x7e')](function(){return _0x35ff8d;}):_0x35ff8d;})['catch'](function(_0xcfc7d6){const _0x5afe57=_0x22ede8;logger[_0x5afe57('0xf')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0xcfc7d6);throw _0xcfc7d6;});}return _0x35ff8d;})[_0x325b6f('0x7e')](respondWithResult(_0x70b256,null))['catch'](handleError(_0x70b256,null));}});}catch(_0x168f58){_0x70b256[_0x2d3585('0x15')](0x1f4)[_0x2d3585('0x22')](_0x168f58);}};function removeReferences(_0x4bc618,_0x5dec0d){const _0xb55c53=_0x4d7cfe;try{_0x4bc618&&(fs[_0xb55c53('0x6d')](_0x4bc618),logger[_0xb55c53('0x70')](_0xb55c53('0x4d'))),_0x5dec0d&&(rimraf(_0x5dec0d,function(){}),logger[_0xb55c53('0x70')](_0xb55c53('0x38')));}catch(_0x10fc95){logger[_0xb55c53('0xf')](_0x10fc95);}}exports[_0x4d7cfe('0x6')]=function(_0x1296c7,_0x4fdc87){const _0x65a6b7=_0x4d7cfe;return db[_0x65a6b7('0x23')]['findOne']({'where':{'id':_0x1296c7[_0x65a6b7('0x76')]['id']}})[_0x65a6b7('0x7e')](handleEntityNotFound(_0x4fdc87))[_0x65a6b7('0x7e')](saveUpdates(_0x1296c7[_0x65a6b7('0x5e')]))[_0x65a6b7('0x7e')](respondWithResult(_0x4fdc87,null))[_0x65a6b7('0x0')](handleError(_0x4fdc87,null));},exports[_0x4d7cfe('0x48')]=function(_0x1f1cb5,_0x5ad37e){const _0x6cf72=_0x4d7cfe;return db[_0x6cf72('0x23')][_0x6cf72('0x53')]({'where':{'id':_0x1f1cb5[_0x6cf72('0x76')]['id']}})[_0x6cf72('0x7e')](function(_0x249287){const _0x175526=_0x6cf72;if(_0x249287)return _0x249287[_0x175526('0x20')]();})[_0x6cf72('0x7e')](function(_0x5c6e46){const _0x2a0e0d=_0x6cf72;return rimraf(path[_0x2a0e0d('0x18')](config[_0x2a0e0d('0x78')],'server/files/plugins',path[_0x2a0e0d('0x9a')](_0x5c6e46[_0x2a0e0d('0x91')])),function(){}),_0x5c6e46;})[_0x6cf72('0x7e')](handleEntityNotFound(_0x5ad37e))[_0x6cf72('0x7e')](respondWithStatusCode(_0x5ad37e,null))['catch'](handleError(_0x5ad37e,null));},exports['webhookGet']=function(_0xcef1b3,_0x523b19){const _0x3d0011=_0x4d7cfe;return Promise[_0x3d0011('0x3d')]()[_0x3d0011('0x7e')](function(){const _0x130b17=_0x3d0011;if(!_0xcef1b3['query'][_0x130b17('0x91')])throw new Error(_0x130b17('0x56'));if(!_0xcef1b3[_0x130b17('0x83')][_0x130b17('0x92')])throw new Error(_0x130b17('0x7f'));const _0x41bdab=_0xcef1b3['query'][_0x130b17('0x2')]?_0xcef1b3[_0x130b17('0x83')]['hostname']+':'+_0xcef1b3['query'][_0x130b17('0x92')]:'http://localhost:'+_0xcef1b3[_0x130b17('0x83')][_0x130b17('0x92')],_0x227a26=_0xcef1b3[_0x130b17('0x83')][_0x130b17('0x9')]?_0xcef1b3[_0x130b17('0x83')]['json']:!![],_0x25862d=_0xcef1b3[_0x130b17('0x83')][_0x130b17('0x4a')]?_0xcef1b3['query'][_0x130b17('0x4a')]:null,_0x890209={'method':_0xcef1b3[_0x130b17('0x61')],'uri':util['format'](_0x130b17('0x1'),_0x41bdab,_0xcef1b3[_0x130b17('0x83')][_0x130b17('0x91')]),'json':_0x227a26,'resolveWithFullResponse':!![],'encoding':_0x25862d,'qs':_0xcef1b3[_0x130b17('0x83')]};return _0xcef1b3[_0x130b17('0x43')]&&(_0x890209['headers']=_0xcef1b3[_0x130b17('0x43')],_0x890209[_0x130b17('0x43')][_0x130b17('0x24')]&&delete _0x890209[_0x130b17('0x43')]['content-length']),_0x890209[_0x130b17('0x43')][_0x130b17('0x86')]&&delete _0x890209[_0x130b17('0x43')][_0x130b17('0x86')],rp(_0x890209);})[_0x3d0011('0x7e')](function(_0x52c861){const _0x59aaa2=_0x3d0011;return _0x52c861?(_0x523b19[_0x59aaa2('0x65')](_0x52c861[_0x59aaa2('0x43')]),logger['info'](_0x52c861['body']),_[_0x59aaa2('0x1a')](_0xcef1b3[_0x59aaa2('0x83')][_0x59aaa2('0x91')],'download')&&_0x52c861[_0x59aaa2('0x6f')]==0x1f4?_0x523b19['sendStatus'](_0x52c861[_0x59aaa2('0x6f')]):_0x523b19['status'](_0x52c861[_0x59aaa2('0x6f')])[_0x59aaa2('0x22')](_0x52c861[_0x59aaa2('0x5e')])):_0x523b19[_0x59aaa2('0x66')](0xc8);})['catch'](handleError(_0x523b19,null));},exports['webhookPost']=function(_0x5e6bcb,_0x135cff){const _0x2b81fe=_0x4d7cfe;return Promise[_0x2b81fe('0x3d')]()[_0x2b81fe('0x7e')](function(){const _0x8015cb=_0x2b81fe;if(!_0x5e6bcb['query'][_0x8015cb('0x91')])throw new Error('\x27PATH\x27\x20parameter\x20not\x20specified');if(!_0x5e6bcb['query'][_0x8015cb('0x92')])throw new Error(_0x8015cb('0x7f'));const _0x21044b=_0x5e6bcb[_0x8015cb('0x83')][_0x8015cb('0x2')]?_0x5e6bcb[_0x8015cb('0x83')][_0x8015cb('0x2')]+':'+_0x5e6bcb[_0x8015cb('0x83')][_0x8015cb('0x92')]:_0x8015cb('0x5')+_0x5e6bcb['query']['port'],_0xdd2383=_0x5e6bcb[_0x8015cb('0x83')]['json']?_0x5e6bcb['query'][_0x8015cb('0x9')]:!![],_0x329dcf=_0x5e6bcb['query']['encoding']?_0x5e6bcb[_0x8015cb('0x83')][_0x8015cb('0x4a')]:null,_0x2dcd19={'method':_0x5e6bcb[_0x8015cb('0x61')],'uri':util[_0x8015cb('0x2f')](_0x8015cb('0x1'),_0x21044b,_0x5e6bcb['query'][_0x8015cb('0x91')]),'json':_0xdd2383,'resolveWithFullResponse':!![],'encoding':_0x329dcf,'body':_0x5e6bcb[_0x8015cb('0x5e')]};return _0x5e6bcb[_0x8015cb('0x43')]&&(_0x2dcd19[_0x8015cb('0x43')]=_0x5e6bcb[_0x8015cb('0x43')],_0x2dcd19[_0x8015cb('0x43')][_0x8015cb('0x24')]&&delete _0x2dcd19['headers']['content-length']),_0x2dcd19['headers'][_0x8015cb('0x86')]&&delete _0x2dcd19[_0x8015cb('0x43')][_0x8015cb('0x86')],rp(_0x2dcd19);})[_0x2b81fe('0x7e')](function(_0x5c58f5){const _0x1abb71=_0x2b81fe;return _0x5c58f5?(_0x135cff[_0x1abb71('0x65')](_0x5c58f5[_0x1abb71('0x43')]),logger[_0x1abb71('0x70')](_0x5c58f5[_0x1abb71('0x5e')]),_0x135cff['status'](_0x5c58f5[_0x1abb71('0x6f')])[_0x1abb71('0x22')](_0x5c58f5[_0x1abb71('0x5e')])):_0x135cff['sendStatus'](0xc8);})[_0x2b81fe('0x0')](handleError(_0x135cff,null));}; \ No newline at end of file diff --git a/server/api/plugin/plugin.events.js b/server/api/plugin/plugin.events.js index 787e430..c2b4722 100644 --- a/server/api/plugin/plugin.events.js +++ b/server/api/plugin/plugin.events.js @@ -1 +1 @@ -const a516_0x101d=['undefined','emit','../../mysqldb','save','Plugin','addHook','update','exports','events'];(function(_0x20fe9d,_0x101d49){const _0x15b596=function(_0x3ee902){while(--_0x3ee902){_0x20fe9d['push'](_0x20fe9d['shift']());}};_0x15b596(++_0x101d49);}(a516_0x101d,0x1f1));const a516_0x15b5=function(_0x20fe9d,_0x101d49){_0x20fe9d=_0x20fe9d-0x0;let _0x15b596=a516_0x101d[_0x20fe9d];return _0x15b596;};const _0x29f760=a516_0x15b5;'use strict';const EventEmitter=require(_0x29f760('0x6')),Plugin=require(_0x29f760('0x0'))['db'][_0x29f760('0x2')],PluginEvents=new EventEmitter();PluginEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x29f760('0x1'),'afterUpdate':_0x29f760('0x4'),'afterDestroy':'remove'};function emitEvent(_0x3ee902){return function(_0x31707a){const _0x3ef27a=a516_0x15b5;PluginEvents[_0x3ef27a('0x8')](_0x3ee902+':'+_0x31707a['id'],_0x31707a),PluginEvents[_0x3ef27a('0x8')](_0x3ee902,_0x31707a);};}for(const e in events){if(typeof events[e]!==_0x29f760('0x7')){const event=events[e];Plugin[_0x29f760('0x3')](e,emitEvent(event));}}module[_0x29f760('0x5')]=PluginEvents; \ No newline at end of file +const a516_0x2e5b=['update','exports','setMaxListeners','undefined','addHook','events','save','../../mysqldb','emit','Plugin'];(function(_0x318008,_0x2e5b73){const _0x4b4e4c=function(_0x475248){while(--_0x475248){_0x318008['push'](_0x318008['shift']());}};_0x4b4e4c(++_0x2e5b73);}(a516_0x2e5b,0x10c));const a516_0x4b4e=function(_0x318008,_0x2e5b73){_0x318008=_0x318008-0x0;let _0x4b4e4c=a516_0x2e5b[_0x318008];return _0x4b4e4c;};const _0x13d0da=a516_0x4b4e;'use strict';const EventEmitter=require(_0x13d0da('0x7')),Plugin=require(_0x13d0da('0x9'))['db'][_0x13d0da('0x1')],PluginEvents=new EventEmitter();PluginEvents[_0x13d0da('0x4')](0x0);const events={'afterCreate':_0x13d0da('0x8'),'afterUpdate':_0x13d0da('0x2'),'afterDestroy':'remove'};function emitEvent(_0x475248){return function(_0x1d7dae){const _0x5d0d6e=a516_0x4b4e;PluginEvents[_0x5d0d6e('0x0')](_0x475248+':'+_0x1d7dae['id'],_0x1d7dae),PluginEvents[_0x5d0d6e('0x0')](_0x475248,_0x1d7dae);};}for(const e in events){if(typeof events[e]!==_0x13d0da('0x5')){const event=events[e];Plugin[_0x13d0da('0x6')](e,emitEvent(event));}}module[_0x13d0da('0x3')]=PluginEvents; \ No newline at end of file diff --git a/server/api/plugin/plugin.model.js b/server/api/plugin/plugin.model.js index 9f07127..5c467e6 100644 --- a/server/api/plugin/plugin.model.js +++ b/server/api/plugin/plugin.model.js @@ -1 +1 @@ -const a517_0x5995=['Plugin','exports','plugins','./plugin.attributes','define'];(function(_0x11075d,_0x599555){const _0x474efc=function(_0x14b506){while(--_0x14b506){_0x11075d['push'](_0x11075d['shift']());}};_0x474efc(++_0x599555);}(a517_0x5995,0x199));const a517_0x474e=function(_0x11075d,_0x599555){_0x11075d=_0x11075d-0x0;let _0x474efc=a517_0x5995[_0x11075d];return _0x474efc;};const _0x19ceb6=a517_0x474e;'use strict';const attributes=require(_0x19ceb6('0x4'));module[_0x19ceb6('0x2')]=function(_0x14b506){const _0x1783a1=_0x19ceb6,_0x327d02=_0x14b506[_0x1783a1('0x0')](_0x1783a1('0x1'),attributes,{'tableName':_0x1783a1('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x327d02;}; \ No newline at end of file +const a517_0x4df2=['define','./plugin.attributes','Plugin','plugins','exports'];(function(_0x24a494,_0x4df2a5){const _0xe9e297=function(_0x2efc7a){while(--_0x2efc7a){_0x24a494['push'](_0x24a494['shift']());}};_0xe9e297(++_0x4df2a5);}(a517_0x4df2,0xb6));const a517_0xe9e2=function(_0x24a494,_0x4df2a5){_0x24a494=_0x24a494-0x0;let _0xe9e297=a517_0x4df2[_0x24a494];return _0xe9e297;};const _0x5ad87c=a517_0xe9e2;'use strict';const attributes=require(_0x5ad87c('0x4'));module[_0x5ad87c('0x2')]=function(_0x2efc7a){const _0x378d46=_0x5ad87c,_0x28abfe=_0x2efc7a[_0x378d46('0x3')](_0x378d46('0x0'),attributes,{'tableName':_0x378d46('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x28abfe;}; \ No newline at end of file diff --git a/server/api/plugin/plugin.rpc.js b/server/api/plugin/plugin.rpc.js index b65b89b..1e90c4a 100644 --- a/server/api/plugin/plugin.rpc.js +++ b/server/api/plugin/plugin.rpc.js @@ -1 +1 @@ -const a518_0x3b12=['info','rpc','raw','message','body','options','../../rediscache','./plugin.socket','../../config/logger','create','catch','debug','error','stringify','CreatePlugin','then'];(function(_0x4126b5,_0x3b1286){const _0x4fbe01=function(_0x129e56){while(--_0x129e56){_0x4126b5['push'](_0x4126b5['shift']());}};_0x4fbe01(++_0x3b1286);}(a518_0x3b12,0x193));const a518_0x4fbe=function(_0x4126b5,_0x3b1286){_0x4126b5=_0x4126b5-0x0;let _0x4fbe01=a518_0x3b12[_0x4126b5];return _0x4fbe01;};const _0x57aa17=a518_0x4fbe;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x57aa17('0x5'))(_0x57aa17('0xe')),{getSocket}=require(_0x57aa17('0x3')),socket=getSocket();require(_0x57aa17('0x4'))['register'](socket),exports[_0x57aa17('0xb')]=function(_0x129e56){const _0x4f46a8=this;return new Promise(function(_0x4b23ce,_0x1c9bb5){const _0x17cb0d=a518_0x4fbe;return db['Plugin'][_0x17cb0d('0x6')](_0x129e56[_0x17cb0d('0x1')],{'raw':_0x129e56[_0x17cb0d('0x2')]?_0x129e56[_0x17cb0d('0x2')][_0x17cb0d('0xf')]===undefined?!![]:![]:!![]})[_0x17cb0d('0xc')](function(_0xf37c12){const _0x2fbfff=_0x17cb0d;logger[_0x2fbfff('0xd')](_0x2fbfff('0xb'),_0x129e56),logger[_0x2fbfff('0x8')](_0x2fbfff('0xb'),_0x129e56,JSON[_0x2fbfff('0xa')](_0xf37c12)),_0x4b23ce(_0xf37c12);})[_0x17cb0d('0x7')](function(_0xc102ec){const _0xcf1ce4=_0x17cb0d;logger[_0xcf1ce4('0x9')](_0xcf1ce4('0xb'),_0xc102ec[_0xcf1ce4('0x0')],_0x129e56),_0x1c9bb5(_0x4f46a8[_0xcf1ce4('0x9')](0x1f4,_0xc102ec[_0xcf1ce4('0x0')]));});});}; \ No newline at end of file +const a518_0x1488=['then','../../config/logger','error','debug','../../mysqldb','options','catch','raw','message','stringify','./plugin.socket','create','Plugin','CreatePlugin','body'];(function(_0x3fe7c4,_0x14887c){const _0x60c7aa=function(_0xa45e3b){while(--_0xa45e3b){_0x3fe7c4['push'](_0x3fe7c4['shift']());}};_0x60c7aa(++_0x14887c);}(a518_0x1488,0x195));const a518_0x60c7=function(_0x3fe7c4,_0x14887c){_0x3fe7c4=_0x3fe7c4-0x0;let _0x60c7aa=a518_0x1488[_0x3fe7c4];return _0x60c7aa;};const _0x257e78=a518_0x60c7;'use strict';const db=require(_0x257e78('0x4'))['db'],logger=require(_0x257e78('0x1'))('rpc'),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x257e78('0xa'))['register'](socket),exports[_0x257e78('0xd')]=function(_0xa45e3b){const _0x340e31=this;return new Promise(function(_0x21141e,_0x2f0dca){const _0x22e0e4=a518_0x60c7;return db[_0x22e0e4('0xc')][_0x22e0e4('0xb')](_0xa45e3b[_0x22e0e4('0xe')],{'raw':_0xa45e3b[_0x22e0e4('0x5')]?_0xa45e3b[_0x22e0e4('0x5')][_0x22e0e4('0x7')]===undefined?!![]:![]:!![]})[_0x22e0e4('0x0')](function(_0x313c8f){const _0xd55b3d=_0x22e0e4;logger['info'](_0xd55b3d('0xd'),_0xa45e3b),logger[_0xd55b3d('0x3')](_0xd55b3d('0xd'),_0xa45e3b,JSON[_0xd55b3d('0x9')](_0x313c8f)),_0x21141e(_0x313c8f);})[_0x22e0e4('0x6')](function(_0x3500b4){const _0x200cf6=_0x22e0e4;logger[_0x200cf6('0x2')](_0x200cf6('0xd'),_0x3500b4[_0x200cf6('0x8')],_0xa45e3b),_0x2f0dca(_0x340e31[_0x200cf6('0x2')](0x1f4,_0x3500b4[_0x200cf6('0x8')]));});});}; \ No newline at end of file diff --git a/server/api/plugin/plugin.socket.js b/server/api/plugin/plugin.socket.js index 8eaab07..9be0d16 100644 --- a/server/api/plugin/plugin.socket.js +++ b/server/api/plugin/plugin.socket.js @@ -1 +1 @@ -const a519_0x276f=['remove','length','plugin:','register','update','emit'];(function(_0x3e308d,_0x276faf){const _0x29ea5c=function(_0x20da57){while(--_0x20da57){_0x3e308d['push'](_0x3e308d['shift']());}};_0x29ea5c(++_0x276faf);}(a519_0x276f,0xa9));const a519_0x29ea=function(_0x3e308d,_0x276faf){_0x3e308d=_0x3e308d-0x0;let _0x29ea5c=a519_0x276f[_0x3e308d];return _0x29ea5c;};const _0x57260c=a519_0x29ea;'use strict';const PluginEvents=require('./plugin.events'),events=['save',_0x57260c('0x5'),_0x57260c('0x3')];function createListener(_0x20da57,_0x5c72e1){return function(_0x99886d){const _0x56b09a=a519_0x29ea;_0x5c72e1[_0x56b09a('0x4')](_0x20da57,_0x99886d);};}exports[_0x57260c('0x2')]=function(_0x47514a){const _0x5cb623=_0x57260c;for(let _0x51de64=0x0,_0x5f5ae0=events[_0x5cb623('0x0')];_0x51de64<_0x5f5ae0;_0x51de64++){const _0x8a3a05=events[_0x51de64],_0xc01fb8=createListener(_0x5cb623('0x1')+_0x8a3a05,_0x47514a);PluginEvents['on'](_0x8a3a05,_0xc01fb8);}}; \ No newline at end of file +const a519_0x3acb=['remove','register','save','length','update'];(function(_0x1bd28b,_0x3acbf0){const _0x3bfade=function(_0xf8d476){while(--_0xf8d476){_0x1bd28b['push'](_0x1bd28b['shift']());}};_0x3bfade(++_0x3acbf0);}(a519_0x3acb,0xe7));const a519_0x3bfa=function(_0x1bd28b,_0x3acbf0){_0x1bd28b=_0x1bd28b-0x0;let _0x3bfade=a519_0x3acb[_0x1bd28b];return _0x3bfade;};const _0x23027b=a519_0x3bfa;'use strict';const PluginEvents=require('./plugin.events'),events=[_0x23027b('0x1'),_0x23027b('0x4'),_0x23027b('0x3')];function createListener(_0xf8d476,_0x39c8e6){return function(_0x5a4f85){_0x39c8e6['emit'](_0xf8d476,_0x5a4f85);};}exports[_0x23027b('0x0')]=function(_0x4b61ca){const _0x3596aa=_0x23027b;for(let _0x2cbd17=0x0,_0x2ab187=events[_0x3596aa('0x2')];_0x2cbd17<_0x2ab187;_0x2cbd17++){const _0x153d61=events[_0x2cbd17],_0x384b66=createListener('plugin:'+_0x153d61,_0x4b61ca);PluginEvents['on'](_0x153d61,_0x384b66);}}; \ No newline at end of file diff --git a/server/api/pm2/index.js b/server/api/pm2/index.js index 3a9da89..91b0da9 100644 --- a/server/api/pm2/index.js +++ b/server/api/pm2/index.js @@ -1 +1 @@ -const a520_0x2e12=['../../components/auth/service','create','destroy','post','express','Router','/:id','isAuthenticated','get','./pm2.controller','delete','update','exports'];(function(_0x4caf4e,_0x2e12cb){const _0x1130ba=function(_0x31d6d5){while(--_0x31d6d5){_0x4caf4e['push'](_0x4caf4e['shift']());}};_0x1130ba(++_0x2e12cb);}(a520_0x2e12,0x1c2));const a520_0x1130=function(_0x4caf4e,_0x2e12cb){_0x4caf4e=_0x4caf4e-0x0;let _0x1130ba=a520_0x2e12[_0x4caf4e];return _0x1130ba;};const _0x6e4d39=a520_0x1130;'use strict';const express=require(_0x6e4d39('0x9')),router=express[_0x6e4d39('0xa')](),auth=require(_0x6e4d39('0x5')),controller=require(_0x6e4d39('0x1'));router[_0x6e4d39('0x0')]('/',auth[_0x6e4d39('0xc')](),controller['index']),router[_0x6e4d39('0x0')]('/:id',auth[_0x6e4d39('0xc')](),controller['show']),router[_0x6e4d39('0x8')]('/',auth['isAuthenticated'](),controller[_0x6e4d39('0x6')]),router['put'](_0x6e4d39('0xb'),auth[_0x6e4d39('0xc')](),controller[_0x6e4d39('0x3')]),router[_0x6e4d39('0x2')](_0x6e4d39('0xb'),auth[_0x6e4d39('0xc')](),controller[_0x6e4d39('0x7')]),module[_0x6e4d39('0x4')]=router; \ No newline at end of file +const a520_0x58e0=['create','destroy','isAuthenticated','update','../../components/auth/service','index','delete','get','Router','/:id','post','./pm2.controller','exports'];(function(_0xf34ed9,_0x58e048){const _0xc14d4e=function(_0x59ba53){while(--_0x59ba53){_0xf34ed9['push'](_0xf34ed9['shift']());}};_0xc14d4e(++_0x58e048);}(a520_0x58e0,0xe4));const a520_0xc14d=function(_0xf34ed9,_0x58e048){_0xf34ed9=_0xf34ed9-0x0;let _0xc14d4e=a520_0x58e0[_0xf34ed9];return _0xc14d4e;};const _0x487138=a520_0xc14d;'use strict';const express=require('express'),router=express[_0x487138('0x1')](),auth=require(_0x487138('0xa')),controller=require(_0x487138('0x4'));router[_0x487138('0x0')]('/',auth[_0x487138('0x8')](),controller[_0x487138('0xb')]),router[_0x487138('0x0')](_0x487138('0x2'),auth[_0x487138('0x8')](),controller['show']),router[_0x487138('0x3')]('/',auth['isAuthenticated'](),controller[_0x487138('0x6')]),router['put'](_0x487138('0x2'),auth[_0x487138('0x8')](),controller[_0x487138('0x9')]),router[_0x487138('0xc')](_0x487138('0x2'),auth[_0x487138('0x8')](),controller[_0x487138('0x7')]),module[_0x487138('0x5')]=router; \ No newline at end of file diff --git a/server/api/pm2/pm2.controller.js b/server/api/pm2/pm2.controller.js index a60a475..cbe7a24 100644 --- a/server/api/pm2/pm2.controller.js +++ b/server/api/pm2/pm2.controller.js @@ -1 +1 @@ -const a521_0x326c=['npm\x20install','lodash','then','create','stop','name','child_process','restart','motion2','show','join','Unknown\x20status','../../config/logger','start','chdir','status','params','stack','json','send','catch','body','api','index','path','express','destroy','list','error','Missing\x20name\x20and/or\x20path','../../files/plugins','length','delete','update','exec','Unknown\x20id','script','dump','undefined','reject','info'];(function(_0x1ea797,_0x326cdf){const _0x442abf=function(_0x452c03){while(--_0x452c03){_0x1ea797['push'](_0x1ea797['shift']());}};_0x442abf(++_0x326cdf);}(a521_0x326c,0x17e));const a521_0x442a=function(_0x1ea797,_0x326cdf){_0x1ea797=_0x1ea797-0x0;let _0x442abf=a521_0x326c[_0x1ea797];return _0x442abf;};const _0x5061a4=a521_0x442a;'use strict';const _=require(_0x5061a4('0x1d')),pm2=require('../../config/pm2'),logger=require(_0x5061a4('0x28'))(_0x5061a4('0x9')),path=require(_0x5061a4('0xb')),exec=require(_0x5061a4('0x22'))[_0x5061a4('0x15')];function handleEntityNotFound(_0x452c03){return function(_0x5bd3d8){return!_0x5bd3d8&&_0x452c03['sendStatus'](0x194),_0x5bd3d8;};}function respondWithResult(_0x2a782b,_0x2e9f23){return _0x2e9f23=_0x2e9f23||0xc8,function(_0x40d2dd){const _0x23f763=a521_0x442a;if(_0x40d2dd)return _0x2a782b[_0x23f763('0x2')](_0x2e9f23)[_0x23f763('0x5')](_0x40d2dd);return null;};}function handleError(_0x36e87f,_0x24be2c){return _0x24be2c=_0x24be2c||0x1f4,function(_0x21fc3f){const _0x75bb30=a521_0x442a;logger[_0x75bb30('0xf')](_0x21fc3f[_0x75bb30('0x4')]),_0x21fc3f[_0x75bb30('0x21')]&&delete _0x21fc3f[_0x75bb30('0x21')],_0x36e87f[_0x75bb30('0x2')](_0x24be2c)[_0x75bb30('0x6')](_0x21fc3f);};}function execChildProcess(){return new Promise(function(_0x4e8b7a,_0x3d9ded){const _0x32c4c4=a521_0x442a;exec(_0x32c4c4('0x1c'),function(_0x591129,_0x728f51,_0x190705){const _0x4fa03c=_0x32c4c4;logger[_0x4fa03c('0x1b')](_0x728f51),logger[_0x4fa03c('0x1b')](_0x190705);if(_0x591129)return logger[_0x4fa03c('0xf')](_0x591129),_0x3d9ded(_0x591129);return _0x4e8b7a(_0x728f51);});});}exports[_0x5061a4('0xa')]=function(_0x50742c,_0x4c2dcc){const _0x39ec0e=_0x5061a4;return pm2[_0x39ec0e('0xe')]()[_0x39ec0e('0x1e')](function(_0x12656a){const _0x528740=_0x39ec0e;if(_0x12656a){const _0x43100b=_[_0x528740('0x1a')](_0x12656a,function(_0x452689){const _0x234d18=_0x528740;return _0x452689['name']===_0x234d18('0xc')||_0x452689[_0x234d18('0x21')]===_0x234d18('0x24');});return{'rows':_0x43100b,'count':_0x43100b[_0x528740('0x12')]};}return null;})['then'](respondWithResult(_0x4c2dcc,null))[_0x39ec0e('0x7')](handleError(_0x4c2dcc,null));},exports[_0x5061a4('0x25')]=function(_0x48c88c,_0x29652d){const _0x5593ff=_0x5061a4;return pm2['describe'](_0x48c88c['params']['id'])[_0x5593ff('0x1e')](respondWithResult(_0x29652d,null))['then'](handleEntityNotFound(_0x29652d,null))[_0x5593ff('0x7')](handleError(_0x29652d,null));},exports[_0x5061a4('0x1f')]=function(_0x49fb41,_0x326dbf){const _0x1b4819=_0x5061a4;if(_0x49fb41[_0x1b4819('0x8')][_0x1b4819('0x21')]&&_0x49fb41[_0x1b4819('0x8')][_0x1b4819('0x17')]){const _0x5904e6=path[_0x1b4819('0x26')](__dirname,_0x1b4819('0x11'),_0x49fb41[_0x1b4819('0x8')]['script']),_0x24fc7f=process['cwd']();return process[_0x1b4819('0x1')](path['dirname'](_0x5904e6)),execChildProcess()[_0x1b4819('0x1e')](function(){const _0x31d1d5=_0x1b4819;return process['chdir'](_0x24fc7f),pm2[_0x31d1d5('0x0')]({'name':_0x49fb41[_0x31d1d5('0x8')][_0x31d1d5('0x21')],'script':_0x5904e6});})[_0x1b4819('0x1e')](function(_0x61f2ce){const _0x16a0ef=_0x1b4819;return pm2[_0x16a0ef('0x18')](),_0x61f2ce[0x0];})[_0x1b4819('0x1e')](respondWithResult(_0x326dbf,0xc9))[_0x1b4819('0x7')](handleError(_0x326dbf,null));}else return _0x326dbf[_0x1b4819('0x2')](0x1f4)[_0x1b4819('0x6')]({'message':_0x1b4819('0x10')});},exports[_0x5061a4('0x14')]=function(_0x43d014,_0x4d4c93){const _0x34e4d=_0x5061a4;_0x43d014[_0x34e4d('0x8')]['id']&&delete _0x43d014[_0x34e4d('0x8')]['id'];const _0x113c0d={'online':_0x34e4d('0x23'),'stopped':_0x34e4d('0x20')};return typeof _0x113c0d[_0x43d014[_0x34e4d('0x8')][_0x34e4d('0x2')]]!==_0x34e4d('0x19')?pm2[_0x113c0d[_0x43d014['body']['status']]](_0x43d014[_0x34e4d('0x3')]['id'])[_0x34e4d('0x1e')](respondWithResult(_0x4d4c93,0xc8))[_0x34e4d('0x7')](handleError(_0x4d4c93,null)):_0x4d4c93[_0x34e4d('0x2')](0x1f4)[_0x34e4d('0x6')]({'message':_0x34e4d('0x27')});},exports[_0x5061a4('0xd')]=function(_0x43e68f,_0x251d73){const _0x378d7c=_0x5061a4;return _0x43e68f[_0x378d7c('0x8')]['id']&&delete _0x43e68f[_0x378d7c('0x8')]['id'],_0x43e68f['params']['id']?pm2[_0x378d7c('0x13')](_0x43e68f[_0x378d7c('0x3')]['id'])[_0x378d7c('0x1e')](function(_0xb81fd9){return pm2['dump'](),_0xb81fd9[0x0];})[_0x378d7c('0x1e')](respondWithResult(_0x251d73,null))[_0x378d7c('0x7')](handleError(_0x251d73,null)):_0x251d73[_0x378d7c('0x2')](0x1f4)[_0x378d7c('0x6')]({'message':_0x378d7c('0x16')});}; \ No newline at end of file +const a521_0x15bd=['exec','../../config/pm2','api','lodash','dirname','list','dump','body','create','npm\x20install','child_process','restart','destroy','sendStatus','path','then','name','Unknown\x20status','../../files/plugins','delete','params','undefined','info','chdir','update','send','express','Unknown\x20id','script','../../config/logger','show','catch','error','status'];(function(_0x5272b7,_0x15bd81){const _0x8e4612=function(_0x16a5dc){while(--_0x16a5dc){_0x5272b7['push'](_0x5272b7['shift']());}};_0x8e4612(++_0x15bd81);}(a521_0x15bd,0x1ee));const a521_0x8e46=function(_0x5272b7,_0x15bd81){_0x5272b7=_0x5272b7-0x0;let _0x8e4612=a521_0x15bd[_0x5272b7];return _0x8e4612;};const _0x1568b2=a521_0x8e46;'use strict';const _=require(_0x1568b2('0x13')),pm2=require(_0x1568b2('0x11')),logger=require(_0x1568b2('0xb'))(_0x1568b2('0x12')),path=require(_0x1568b2('0x1e')),exec=require(_0x1568b2('0x1a'))[_0x1568b2('0x10')];function handleEntityNotFound(_0x16a5dc){return function(_0x418c7c){const _0x1a16bb=a521_0x8e46;return!_0x418c7c&&_0x16a5dc[_0x1a16bb('0x1d')](0x194),_0x418c7c;};}function respondWithResult(_0x5b39fd,_0x59b438){return _0x59b438=_0x59b438||0xc8,function(_0x1cdbd6){if(_0x1cdbd6)return _0x5b39fd['status'](_0x59b438)['json'](_0x1cdbd6);return null;};}function handleError(_0x30159d,_0x5b586c){return _0x5b586c=_0x5b586c||0x1f4,function(_0x42f13f){const _0x57903f=a521_0x8e46;logger[_0x57903f('0xe')](_0x42f13f['stack']),_0x42f13f[_0x57903f('0x20')]&&delete _0x42f13f[_0x57903f('0x20')],_0x30159d[_0x57903f('0xf')](_0x5b586c)[_0x57903f('0x7')](_0x42f13f);};}function execChildProcess(){return new Promise(function(_0x15bb9d,_0x3e8acc){const _0x1b64c3=a521_0x8e46;exec(_0x1b64c3('0x19'),function(_0x9b0432,_0x50af7f,_0x122fb2){const _0x2edd11=_0x1b64c3;logger[_0x2edd11('0x4')](_0x50af7f),logger[_0x2edd11('0x4')](_0x122fb2);if(_0x9b0432)return logger['error'](_0x9b0432),_0x3e8acc(_0x9b0432);return _0x15bb9d(_0x50af7f);});});}exports['index']=function(_0x302c4c,_0x1099da){const _0x389c6d=_0x1568b2;return pm2[_0x389c6d('0x15')]()[_0x389c6d('0x1f')](function(_0x1afb74){if(_0x1afb74){const _0xbdfafa=_['reject'](_0x1afb74,function(_0x403173){const _0x357452=a521_0x8e46;return _0x403173[_0x357452('0x20')]===_0x357452('0x8')||_0x403173[_0x357452('0x20')]==='motion2';});return{'rows':_0xbdfafa,'count':_0xbdfafa['length']};}return null;})[_0x389c6d('0x1f')](respondWithResult(_0x1099da,null))['catch'](handleError(_0x1099da,null));},exports[_0x1568b2('0xc')]=function(_0x3a470e,_0x2f9d61){const _0x17d970=_0x1568b2;return pm2['describe'](_0x3a470e['params']['id'])[_0x17d970('0x1f')](respondWithResult(_0x2f9d61,null))[_0x17d970('0x1f')](handleEntityNotFound(_0x2f9d61,null))[_0x17d970('0xd')](handleError(_0x2f9d61,null));},exports[_0x1568b2('0x18')]=function(_0x5c65f2,_0x56bc70){const _0x4dbcae=_0x1568b2;if(_0x5c65f2[_0x4dbcae('0x17')]['name']&&_0x5c65f2[_0x4dbcae('0x17')][_0x4dbcae('0xa')]){const _0x570de3=path['join'](__dirname,_0x4dbcae('0x0'),_0x5c65f2[_0x4dbcae('0x17')][_0x4dbcae('0xa')]),_0x3ce3eb=process['cwd']();return process['chdir'](path[_0x4dbcae('0x14')](_0x570de3)),execChildProcess()[_0x4dbcae('0x1f')](function(){const _0x25d39e=_0x4dbcae;return process[_0x25d39e('0x5')](_0x3ce3eb),pm2['start']({'name':_0x5c65f2[_0x25d39e('0x17')]['name'],'script':_0x570de3});})[_0x4dbcae('0x1f')](function(_0x141713){const _0x1aa359=_0x4dbcae;return pm2[_0x1aa359('0x16')](),_0x141713[0x0];})[_0x4dbcae('0x1f')](respondWithResult(_0x56bc70,0xc9))[_0x4dbcae('0xd')](handleError(_0x56bc70,null));}else return _0x56bc70[_0x4dbcae('0xf')](0x1f4)[_0x4dbcae('0x7')]({'message':'Missing\x20name\x20and/or\x20path'});},exports[_0x1568b2('0x6')]=function(_0x5b4da6,_0x430a0c){const _0x40d702=_0x1568b2;_0x5b4da6['body']['id']&&delete _0x5b4da6[_0x40d702('0x17')]['id'];const _0x35b36f={'online':_0x40d702('0x1b'),'stopped':'stop'};return typeof _0x35b36f[_0x5b4da6['body']['status']]!==_0x40d702('0x3')?pm2[_0x35b36f[_0x5b4da6[_0x40d702('0x17')][_0x40d702('0xf')]]](_0x5b4da6[_0x40d702('0x2')]['id'])[_0x40d702('0x1f')](respondWithResult(_0x430a0c,0xc8))['catch'](handleError(_0x430a0c,null)):_0x430a0c[_0x40d702('0xf')](0x1f4)[_0x40d702('0x7')]({'message':_0x40d702('0x21')});},exports[_0x1568b2('0x1c')]=function(_0x13eeeb,_0x572cdb){const _0x4e1c0e=_0x1568b2;return _0x13eeeb[_0x4e1c0e('0x17')]['id']&&delete _0x13eeeb[_0x4e1c0e('0x17')]['id'],_0x13eeeb[_0x4e1c0e('0x2')]['id']?pm2[_0x4e1c0e('0x1')](_0x13eeeb[_0x4e1c0e('0x2')]['id'])['then'](function(_0x29adbd){return pm2['dump'](),_0x29adbd[0x0];})[_0x4e1c0e('0x1f')](respondWithResult(_0x572cdb,null))[_0x4e1c0e('0xd')](handleError(_0x572cdb,null)):_0x572cdb[_0x4e1c0e('0xf')](0x1f4)[_0x4e1c0e('0x7')]({'message':_0x4e1c0e('0x9')});}; \ No newline at end of file diff --git a/server/api/reportAgentPreview/index.js b/server/api/reportAgentPreview/index.js index 384f338..475a169 100644 --- a/server/api/reportAgentPreview/index.js +++ b/server/api/reportAgentPreview/index.js @@ -1 +1 @@ -const a522_0x3e6d=['exports','express','Router'];(function(_0x3ad14e,_0x3e6db5){const _0x22e9ad=function(_0x43e1a8){while(--_0x43e1a8){_0x3ad14e['push'](_0x3ad14e['shift']());}};_0x22e9ad(++_0x3e6db5);}(a522_0x3e6d,0xd1));const a522_0x22e9=function(_0x3ad14e,_0x3e6db5){_0x3ad14e=_0x3ad14e-0x0;let _0x22e9ad=a522_0x3e6d[_0x3ad14e];return _0x22e9ad;};const _0x569137=a522_0x22e9;'use strict';const express=require(_0x569137('0x2')),router=express[_0x569137('0x0')]();module[_0x569137('0x1')]=router; \ No newline at end of file +const a522_0x2997=['express'];(function(_0x2f3642,_0x299758){const _0x233823=function(_0x1ae9b1){while(--_0x1ae9b1){_0x2f3642['push'](_0x2f3642['shift']());}};_0x233823(++_0x299758);}(a522_0x2997,0x1ba));const a522_0x2338=function(_0x2f3642,_0x299758){_0x2f3642=_0x2f3642-0x0;let _0x233823=a522_0x2997[_0x2f3642];return _0x233823;};const _0x2807bd=a522_0x2338;'use strict';const express=require(_0x2807bd('0x0')),router=express['Router']();module['exports']=router; \ No newline at end of file diff --git a/server/api/reportAgentPreview/reportAgentPreview.attributes.js b/server/api/reportAgentPreview/reportAgentPreview.attributes.js index b60f567..2789c63 100644 --- a/server/api/reportAgentPreview/reportAgentPreview.attributes.js +++ b/server/api/reportAgentPreview/reportAgentPreview.attributes.js @@ -1 +1 @@ -const a523_0x4bca=['DATE','STRING','sequelize','exports','INTEGER'];(function(_0x2b19de,_0x4bca0b){const _0x197c7f=function(_0x3f2b62){while(--_0x3f2b62){_0x2b19de['push'](_0x2b19de['shift']());}};_0x197c7f(++_0x4bca0b);}(a523_0x4bca,0x158));const a523_0x197c=function(_0x2b19de,_0x4bca0b){_0x2b19de=_0x2b19de-0x0;let _0x197c7f=a523_0x4bca[_0x2b19de];return _0x197c7f;};const _0x38bc72=a523_0x197c;'use strict';const Sequelize=require(_0x38bc72('0x3'));module[_0x38bc72('0x4')]={'state':{'type':Sequelize['INTEGER'](0x2)},'statedesc':{'type':Sequelize[_0x38bc72('0x2')]},'scheduledat':{'type':Sequelize[_0x38bc72('0x1')]},'uniqueid':{'type':Sequelize['STRING']},'starttime':{'type':Sequelize['DATE']},'responsetime':{'type':Sequelize[_0x38bc72('0x1')]},'ringtime':{'type':Sequelize[_0x38bc72('0x0')],'defaultValue':0x0},'campaign':{'type':Sequelize[_0x38bc72('0x2')]},'campaigntype':{'type':Sequelize['STRING']},'membername':{'type':Sequelize[_0x38bc72('0x2')]}}; \ No newline at end of file +const a523_0x1981=['exports','DATE','INTEGER','sequelize','STRING'];(function(_0x3da011,_0x198143){const _0x2af53e=function(_0x3a46a9){while(--_0x3a46a9){_0x3da011['push'](_0x3da011['shift']());}};_0x2af53e(++_0x198143);}(a523_0x1981,0x1ec));const a523_0x2af5=function(_0x3da011,_0x198143){_0x3da011=_0x3da011-0x0;let _0x2af53e=a523_0x1981[_0x3da011];return _0x2af53e;};const _0xa4fe59=a523_0x2af5;'use strict';const Sequelize=require(_0xa4fe59('0x1'));module[_0xa4fe59('0x3')]={'state':{'type':Sequelize[_0xa4fe59('0x0')](0x2)},'statedesc':{'type':Sequelize[_0xa4fe59('0x2')]},'scheduledat':{'type':Sequelize['DATE']},'uniqueid':{'type':Sequelize[_0xa4fe59('0x2')]},'starttime':{'type':Sequelize['DATE']},'responsetime':{'type':Sequelize[_0xa4fe59('0x4')]},'ringtime':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'campaign':{'type':Sequelize[_0xa4fe59('0x2')]},'campaigntype':{'type':Sequelize['STRING']},'membername':{'type':Sequelize[_0xa4fe59('0x2')]}}; \ No newline at end of file diff --git a/server/api/reportAgentPreview/reportAgentPreview.model.js b/server/api/reportAgentPreview/reportAgentPreview.model.js index 49d9112..963ce84 100644 --- a/server/api/reportAgentPreview/reportAgentPreview.model.js +++ b/server/api/reportAgentPreview/reportAgentPreview.model.js @@ -1 +1 @@ -const a524_0x48c5=['report_agent_preview','define','exports','ReportAgentPreview','./reportAgentPreview.attributes'];(function(_0x28e313,_0x48c557){const _0x310fac=function(_0x58c520){while(--_0x58c520){_0x28e313['push'](_0x28e313['shift']());}};_0x310fac(++_0x48c557);}(a524_0x48c5,0x1c7));const a524_0x310f=function(_0x28e313,_0x48c557){_0x28e313=_0x28e313-0x0;let _0x310fac=a524_0x48c5[_0x28e313];return _0x310fac;};const _0x2fe2e0=a524_0x310f;'use strict';const attributes=require(_0x2fe2e0('0x4'));module[_0x2fe2e0('0x2')]=function(_0x58c520){const _0x364781=_0x2fe2e0,_0x28eb66=_0x58c520[_0x364781('0x1')](_0x364781('0x3'),attributes,{'tableName':_0x364781('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x28eb66;}; \ No newline at end of file +const a524_0x2819=['report_agent_preview','define','exports'];(function(_0x3b2ec8,_0x281973){const _0x4a5a8f=function(_0x2076f8){while(--_0x2076f8){_0x3b2ec8['push'](_0x3b2ec8['shift']());}};_0x4a5a8f(++_0x281973);}(a524_0x2819,0xdf));const a524_0x4a5a=function(_0x3b2ec8,_0x281973){_0x3b2ec8=_0x3b2ec8-0x0;let _0x4a5a8f=a524_0x2819[_0x3b2ec8];return _0x4a5a8f;};const _0x1df739=a524_0x4a5a;'use strict';const attributes=require('./reportAgentPreview.attributes');module[_0x1df739('0x1')]=function(_0x2076f8){const _0x1ca8b5=_0x1df739,_0x5b95fe=_0x2076f8[_0x1ca8b5('0x0')]('ReportAgentPreview',attributes,{'tableName':_0x1ca8b5('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5b95fe;}; \ No newline at end of file diff --git a/server/api/reportAgentPreview/reportAgentPreview.rpc.js b/server/api/reportAgentPreview/reportAgentPreview.rpc.js index 459aafb..edb00a9 100644 --- a/server/api/reportAgentPreview/reportAgentPreview.rpc.js +++ b/server/api/reportAgentPreview/reportAgentPreview.rpc.js @@ -1 +1 @@ -const a525_0x489e=['raw','../../config/logger','error','body','then','../../mysqldb','debug','ReportAgentPreview','options','stringify','catch','CreateReportAgentPreview','info','message','create'];(function(_0x361167,_0x489eef){const _0x1e52cf=function(_0xae753c){while(--_0xae753c){_0x361167['push'](_0x361167['shift']());}};_0x1e52cf(++_0x489eef);}(a525_0x489e,0x104));const a525_0x1e52=function(_0x361167,_0x489eef){_0x361167=_0x361167-0x0;let _0x1e52cf=a525_0x489e[_0x361167];return _0x1e52cf;};const _0x4585ca=a525_0x1e52;'use strict';const db=require(_0x4585ca('0x0'))['db'],logger=require(_0x4585ca('0xb'))('rpc');exports[_0x4585ca('0x6')]=function(_0xae753c){const _0x49d24b=this;return new Promise(function(_0x30cf83,_0x452c04){const _0x50eb6e=a525_0x1e52;return db[_0x50eb6e('0x2')][_0x50eb6e('0x9')](_0xae753c[_0x50eb6e('0xd')],{'raw':_0xae753c['options']?_0xae753c[_0x50eb6e('0x3')][_0x50eb6e('0xa')]===undefined?!![]:![]:!![]})[_0x50eb6e('0xe')](function(_0x297103){const _0x3fa0da=_0x50eb6e;logger[_0x3fa0da('0x7')](_0x3fa0da('0x6'),_0xae753c),logger[_0x3fa0da('0x1')]('CreateReportAgentPreview',_0xae753c,JSON[_0x3fa0da('0x4')](_0x297103)),_0x30cf83(_0x297103);})[_0x50eb6e('0x5')](function(_0x41bcf3){const _0x3b62e4=_0x50eb6e;logger[_0x3b62e4('0xc')](_0x3b62e4('0x6'),_0x41bcf3[_0x3b62e4('0x8')],_0xae753c),_0x452c04(_0x49d24b['error'](0x1f4,_0x41bcf3['message']));});});}; \ No newline at end of file +const a525_0x4b6c=['message','rpc','then','../../config/logger','body','error','ReportAgentPreview','create','../../mysqldb','options','catch','CreateReportAgentPreview','raw'];(function(_0x13f607,_0x4b6cf1){const _0x3e74e5=function(_0x2a9c32){while(--_0x2a9c32){_0x13f607['push'](_0x13f607['shift']());}};_0x3e74e5(++_0x4b6cf1);}(a525_0x4b6c,0x76));const a525_0x3e74=function(_0x13f607,_0x4b6cf1){_0x13f607=_0x13f607-0x0;let _0x3e74e5=a525_0x4b6c[_0x13f607];return _0x3e74e5;};const _0x2c423f=a525_0x3e74;'use strict';const db=require(_0x2c423f('0x7'))['db'],logger=require(_0x2c423f('0x2'))(_0x2c423f('0x0'));exports[_0x2c423f('0xa')]=function(_0x2a9c32){const _0x4cbe76=this;return new Promise(function(_0x433fc4,_0x5c50eb){const _0x5531bd=a525_0x3e74;return db[_0x5531bd('0x5')][_0x5531bd('0x6')](_0x2a9c32[_0x5531bd('0x3')],{'raw':_0x2a9c32[_0x5531bd('0x8')]?_0x2a9c32[_0x5531bd('0x8')][_0x5531bd('0xb')]===undefined?!![]:![]:!![]})[_0x5531bd('0x1')](function(_0x99032f){const _0x10af9e=_0x5531bd;logger['info'](_0x10af9e('0xa'),_0x2a9c32),logger['debug'](_0x10af9e('0xa'),_0x2a9c32,JSON['stringify'](_0x99032f)),_0x433fc4(_0x99032f);})[_0x5531bd('0x9')](function(_0x19feec){const _0x1ec19c=_0x5531bd;logger[_0x1ec19c('0x4')](_0x1ec19c('0xa'),_0x19feec['message'],_0x2a9c32),_0x5c50eb(_0x4cbe76[_0x1ec19c('0x4')](0x1f4,_0x19feec[_0x1ec19c('0xc')]));});});}; \ No newline at end of file diff --git a/server/api/rpc/index.js b/server/api/rpc/index.js index 8d26e34..0cc9096 100644 --- a/server/api/rpc/index.js +++ b/server/api/rpc/index.js @@ -1 +1 @@ -const a526_0x17da=['/voice/channels/:uniqueid/stopmixmonitor','voiceQueuesChannels','agentCapacity','/fax/queues','../../components/auth/service','fax','/whatsapp/queues/waitinginteractions','get','faxQueues','/voice/channels/:uniqueid/mixmonitor','/voice/queues/channels','smsQueuesWaitingInteractions','/outbound','/mail/accounts','outboundChannels','showOpenchannelQueues','voiceChannels','chatQueues','trunks','whatsappQueuesWaitingInteractions','/voice/queues/preview/:id','voiceQueues','/mail/queues/:id/notify','post','showVoiceQueues','mailQueuesWaitingInteractions','/whatsapp/queues','openchannel','/chat/queues','/openchannel/queues/:id/notify','/fax/accounts','mail','voiceChannelStopMixMonitor','/voice/queues/channels/:uniqueid','mailAccounts','campaigns','faxQueuesWaitingInteractions','voiceQueuesChannelHangup','/openchannel/queues/waitinginteractions','telephones','smsQueues','/voice/queues/channels/:uniqueid/redirect/:exten','/sms/queues/waitinginteractions','queueNotify','express','/chat/queues/:id','showSmsQueues','/sms/queues/:id','showWhatsappQueues','/openchannel/queues','Router','/sms/queues','/openchannel/queues/:id/waitinginteractions','./rpc.controller','exports','/whatsapp/queues/:id','/mail/queues','put','isAuthenticated','/agents/:id/capacity','/agents','/outbound/channels','/agents/:id/notify','/voice/queues','/mail/queues/waitinginteractions','faxAccounts','/openchannel/queues/:id','showChatQueues','chatQueuesWaitingInteractions','/telephones','/chat/queues/waitinginteractions','whatsapp','/fax/queues/waitinginteractions','/chat/queues/:id/notify','/whatsapp/queues/:id/notify','voiceQueuesChannelRedirect','/fax/queues/:id','/voice/queues/channels/:uniqueid/hangup'];(function(_0x52daa2,_0x17da9a){const _0x53c89f=function(_0x310bc6){while(--_0x310bc6){_0x52daa2['push'](_0x52daa2['shift']());}};_0x53c89f(++_0x17da9a);}(a526_0x17da,0x77));const a526_0x53c8=function(_0x52daa2,_0x17da9a){_0x52daa2=_0x52daa2-0x0;let _0x53c89f=a526_0x17da[_0x52daa2];return _0x53c89f;};const _0x1bc4d3=a526_0x53c8;'use strict';const express=require(_0x1bc4d3('0x3')),router=express[_0x1bc4d3('0x9')](),auth=require(_0x1bc4d3('0x29')),controller=require(_0x1bc4d3('0xc'));router[_0x1bc4d3('0x2c')]('/voice/channels',auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x35')]),router['get'](_0x1bc4d3('0x2e'),auth[_0x1bc4d3('0x11')](),controller['voiceChannelMixMonitor']),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x25'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x45')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x16'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x3a')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x41'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x36')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0xf'),auth[_0x1bc4d3('0x11')](),controller['mailQueues']),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x32'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x47')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x8'),auth[_0x1bc4d3('0x11')](),controller['openchannelQueues']),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0xa'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x4d')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x3f'),auth['isAuthenticated'](),controller['whatsappQueues']),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x28'),auth['isAuthenticated'](),controller[_0x1bc4d3('0x2d')]),router['get'](_0x1bc4d3('0x39'),auth[_0x1bc4d3('0x11')](),controller['voiceQueuesPreview']),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x2f'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x26')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x46'),auth[_0x1bc4d3('0x11')](),controller['voiceQueuesChannel']),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x24'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x4a')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x0'),auth['isAuthenticated'](),controller[_0x1bc4d3('0x22')]),router[_0x1bc4d3('0x2c')]('/voice/queues/:id',auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x3d')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x31'),auth['isAuthenticated'](),controller['outbound']),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x14'),auth['isAuthenticated'](),controller[_0x1bc4d3('0x33')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x13'),auth[_0x1bc4d3('0x11')](),controller['agents']),router[_0x1bc4d3('0x10')](_0x1bc4d3('0x12'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x27')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x1c'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x4c')]),router['get']('/trunks',auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x37')]),router[_0x1bc4d3('0x2c')]('/campaigns',auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x48')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x43'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x18')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x1d'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x1b')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x17'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x3e')]),router['get'](_0x1bc4d3('0x4b'),auth['isAuthenticated'](),controller['openchannelQueuesWaitingInteractions']),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0xb'),auth[_0x1bc4d3('0x11')](),controller['openchannelQueuesIdWaitingInteractions']),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x1'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x30')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x2b'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x38')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x1f'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x49')]),router['post'](_0x1bc4d3('0x3b'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x2')](_0x1bc4d3('0x44'))),router['get']('/mail/queues/:id',auth[_0x1bc4d3('0x11')](),controller['showMailQueues']),router[_0x1bc4d3('0x3c')](_0x1bc4d3('0x20'),auth[_0x1bc4d3('0x11')](),controller['queueNotify']('chat')),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x4'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x1a')]),router[_0x1bc4d3('0x3c')]('/fax/queues/:id/notify',auth['isAuthenticated'](),controller[_0x1bc4d3('0x2')](_0x1bc4d3('0x2a'))),router['get'](_0x1bc4d3('0x23'),auth[_0x1bc4d3('0x11')](),controller['showFaxQueues']),router[_0x1bc4d3('0x3c')](_0x1bc4d3('0x42'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x2')](_0x1bc4d3('0x40'))),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0x19'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x34')]),router[_0x1bc4d3('0x3c')]('/sms/queues/:id/notify',auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x2')]('sms')),router[_0x1bc4d3('0x3c')](_0x1bc4d3('0x21'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x2')](_0x1bc4d3('0x1e'))),router['get'](_0x1bc4d3('0x6'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x5')]),router[_0x1bc4d3('0x2c')](_0x1bc4d3('0xe'),auth[_0x1bc4d3('0x11')](),controller[_0x1bc4d3('0x7')]),router[_0x1bc4d3('0x3c')](_0x1bc4d3('0x15'),auth[_0x1bc4d3('0x11')](),controller['agentNotify']),module[_0x1bc4d3('0xd')]=router; \ No newline at end of file +const a526_0x2057=['/voice/queues/:id','/chat/queues/waitinginteractions','put','outbound','/openchannel/queues','/trunks','/outbound/channels','faxAccounts','whatsappQueues','/chat/queues/:id/notify','/voice/channels/:uniqueid/mixmonitor','faxQueues','outboundChannels','/voice/channels','queueNotify','/openchannel/queues/:id/waitinginteractions','/voice/queues/channels','showChatQueues','/chat/queues/:id','trunks','showWhatsappQueues','/openchannel/queues/waitinginteractions','whatsapp','/voice/queues/preview/:id','openchannelQueuesWaitingInteractions','/fax/queues','/openchannel/queues/:id/notify','telephones','isAuthenticated','post','voiceChannelStopMixMonitor','showFaxQueues','/voice/channels/:uniqueid/stopmixmonitor','/mail/queues/:id/notify','whatsappQueuesWaitingInteractions','/sms/queues/:id/notify','/mail/queues','openchannel','/voice/queues/channels/:uniqueid/redirect/:exten','/mail/accounts','/telephones','/whatsapp/queues/waitinginteractions','showVoiceQueues','/agents/:id/notify','voiceQueues','../../components/auth/service','chat','mailAccounts','/whatsapp/queues','agentCapacity','agentNotify','chatQueuesWaitingInteractions','voiceQueuesChannelRedirect','campaigns','/voice/queues','/fax/queues/waitinginteractions','/sms/queues/:id','get','voiceChannelMixMonitor','sms','/fax/queues/:id','mail','openchannelQueuesIdWaitingInteractions','openchannelQueues','/voice/queues/channels/:uniqueid','faxQueuesWaitingInteractions','/campaigns','voiceQueuesChannels','showMailQueues','mailQueuesWaitingInteractions','showOpenchannelQueues','fax','voiceChannels','/agents','/mail/queues/waitinginteractions'];(function(_0x5f04c3,_0x205779){const _0x5e6e78=function(_0x5c68ba){while(--_0x5c68ba){_0x5f04c3['push'](_0x5f04c3['shift']());}};_0x5e6e78(++_0x205779);}(a526_0x2057,0x182));const a526_0x5e6e=function(_0x5f04c3,_0x205779){_0x5f04c3=_0x5f04c3-0x0;let _0x5e6e78=a526_0x2057[_0x5f04c3];return _0x5e6e78;};const _0x239122=a526_0x5e6e;'use strict';const express=require('express'),router=express['Router'](),auth=require(_0x239122('0x22')),controller=require('./rpc.controller');router[_0x239122('0x2e')](_0x239122('0x2'),auth[_0x239122('0x11')](),controller[_0x239122('0x3d')]),router[_0x239122('0x2e')](_0x239122('0x4a'),auth[_0x239122('0x11')](),controller[_0x239122('0x2f')]),router[_0x239122('0x2e')](_0x239122('0x15'),auth[_0x239122('0x11')](),controller[_0x239122('0x13')]),router[_0x239122('0x2e')](_0x239122('0x2b'),auth[_0x239122('0x11')](),controller[_0x239122('0x21')]),router[_0x239122('0x2e')]('/chat/queues',auth[_0x239122('0x11')](),controller['chatQueues']),router[_0x239122('0x2e')](_0x239122('0x19'),auth[_0x239122('0x11')](),controller['mailQueues']),router[_0x239122('0x2e')](_0x239122('0x1c'),auth[_0x239122('0x11')](),controller[_0x239122('0x24')]),router[_0x239122('0x2e')](_0x239122('0x44'),auth[_0x239122('0x11')](),controller[_0x239122('0x34')]),router[_0x239122('0x2e')]('/sms/queues',auth[_0x239122('0x11')](),controller['smsQueues']),router['get'](_0x239122('0x25'),auth['isAuthenticated'](),controller[_0x239122('0x48')]),router['get'](_0x239122('0xe'),auth[_0x239122('0x11')](),controller[_0x239122('0x0')]),router[_0x239122('0x2e')](_0x239122('0xc'),auth[_0x239122('0x11')](),controller['voiceQueuesPreview']),router[_0x239122('0x2e')](_0x239122('0x5'),auth[_0x239122('0x11')](),controller[_0x239122('0x38')]),router['get'](_0x239122('0x35'),auth[_0x239122('0x11')](),controller['voiceQueuesChannel']),router[_0x239122('0x2e')]('/voice/queues/channels/:uniqueid/hangup',auth[_0x239122('0x11')](),controller['voiceQueuesChannelHangup']),router[_0x239122('0x2e')](_0x239122('0x1b'),auth[_0x239122('0x11')](),controller[_0x239122('0x29')]),router[_0x239122('0x2e')](_0x239122('0x40'),auth[_0x239122('0x11')](),controller[_0x239122('0x1f')]),router['get']('/outbound',auth[_0x239122('0x11')](),controller[_0x239122('0x43')]),router[_0x239122('0x2e')](_0x239122('0x46'),auth[_0x239122('0x11')](),controller[_0x239122('0x1')]),router[_0x239122('0x2e')](_0x239122('0x3e'),auth['isAuthenticated'](),controller['agents']),router[_0x239122('0x42')]('/agents/:id/capacity',auth[_0x239122('0x11')](),controller[_0x239122('0x26')]),router[_0x239122('0x2e')](_0x239122('0x1d'),auth['isAuthenticated'](),controller[_0x239122('0x10')]),router[_0x239122('0x2e')](_0x239122('0x45'),auth[_0x239122('0x11')](),controller[_0x239122('0x8')]),router[_0x239122('0x2e')](_0x239122('0x37'),auth[_0x239122('0x11')](),controller[_0x239122('0x2a')]),router[_0x239122('0x2e')]('/fax/accounts',auth['isAuthenticated'](),controller[_0x239122('0x47')]),router[_0x239122('0x2e')](_0x239122('0x41'),auth[_0x239122('0x11')](),controller[_0x239122('0x28')]),router[_0x239122('0x2e')](_0x239122('0x3f'),auth[_0x239122('0x11')](),controller[_0x239122('0x3a')]),router['get'](_0x239122('0xa'),auth[_0x239122('0x11')](),controller[_0x239122('0xd')]),router[_0x239122('0x2e')](_0x239122('0x4'),auth['isAuthenticated'](),controller[_0x239122('0x33')]),router['get']('/sms/queues/waitinginteractions',auth[_0x239122('0x11')](),controller['smsQueuesWaitingInteractions']),router[_0x239122('0x2e')](_0x239122('0x1e'),auth[_0x239122('0x11')](),controller[_0x239122('0x17')]),router[_0x239122('0x2e')](_0x239122('0x2c'),auth[_0x239122('0x11')](),controller[_0x239122('0x36')]),router['post'](_0x239122('0x16'),auth['isAuthenticated'](),controller['queueNotify'](_0x239122('0x32'))),router[_0x239122('0x2e')]('/mail/queues/:id',auth[_0x239122('0x11')](),controller[_0x239122('0x39')]),router[_0x239122('0x12')](_0x239122('0x49'),auth[_0x239122('0x11')](),controller[_0x239122('0x3')](_0x239122('0x23'))),router[_0x239122('0x2e')](_0x239122('0x7'),auth['isAuthenticated'](),controller[_0x239122('0x6')]),router[_0x239122('0x12')]('/fax/queues/:id/notify',auth['isAuthenticated'](),controller[_0x239122('0x3')](_0x239122('0x3c'))),router['get'](_0x239122('0x31'),auth[_0x239122('0x11')](),controller[_0x239122('0x14')]),router['post'](_0x239122('0xf'),auth[_0x239122('0x11')](),controller[_0x239122('0x3')](_0x239122('0x1a'))),router[_0x239122('0x2e')]('/openchannel/queues/:id',auth['isAuthenticated'](),controller[_0x239122('0x3b')]),router[_0x239122('0x12')](_0x239122('0x18'),auth[_0x239122('0x11')](),controller[_0x239122('0x3')](_0x239122('0x30'))),router['post']('/whatsapp/queues/:id/notify',auth[_0x239122('0x11')](),controller[_0x239122('0x3')](_0x239122('0xb'))),router[_0x239122('0x2e')](_0x239122('0x2d'),auth[_0x239122('0x11')](),controller['showSmsQueues']),router['get']('/whatsapp/queues/:id',auth[_0x239122('0x11')](),controller[_0x239122('0x9')]),router['post'](_0x239122('0x20'),auth[_0x239122('0x11')](),controller[_0x239122('0x27')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/rpc/rpc.controller.js b/server/api/rpc/rpc.controller.js index 58f87b0..ab37607 100644 --- a/server/api/rpc/rpc.controller.js +++ b/server/api/rpc/rpc.controller.js @@ -1 +1 @@ -const a527_0x29ab=['length','SIP/%s','name','VoiceQueuesChannelHangup','queue','smsQueues','interface','internal','VoiceQueuesPreview','showFaxQueues','mailAccounts','WhatsappQueuesWaitingInteractions','chat','agent','OpenchannelQueues','messageId','Channel\x20field\x20is\x20mandatory','../../mysqldb','voiceQueuesPreview','../../config/logger','VoiceQueues','voiceChannelMixMonitor','notIn','Campaigns','showOpenchannelQueues','INTERACTION','SmsQueues','findAll','Agents','interaction','VoiceQueuesChannels','findOrCreate','queueNotify','MemberReport','query','params','faxAccounts','QueueId','queueTransferTimeout','showVoiceQueues','merge','FaxQueuesWaitingInteractions','filter','voiceChannels','client','mailQueuesWaitingInteractions','*,*,*,*','Queue','Website','user','Account','message','VoiceChannelMixMonitor','then','InteractionId','Message','moment','MessageId','value','queue_id','status','ChatQueues','openchannelQueues','\x20Queue\x20not\x20found','\x20Message\x20not\x20found','body','format','isNil','Interaction','YYYY-MM-DD\x20HH:mm:ss','indexOf','Outbound','capitalize','request','mailQueues','find','FaxQueues','Agent\x20not\x20found','create','From','showSmsQueues','jayson/promise','faxQueues','sendStatus','voiceChannelStopMixMonitor','Trunks','openchannelQueuesWaitingInteractions','error','chatQueues','MailQueuesWaitingInteractions','rows','type','outboundChannels','openchannelQueuesIdWaitingInteractions','OutboundChannels','SmsQueuesWaitingInteractions','send','AgentCapacity','findOne','chatQueuesWaitingInteractions','Telephones','telephones','showWhatsappQueues','trunks','MailQueues','showMailQueues','agentCapacity','agentNotify','OpenchannelQueuesWaitingInteractions','FaxAccounts','showChatQueues','catch','voiceQueuesChannel','agents','lodash','sequelize','VoiceQueuesChannel','voiceQueuesChannelHangup','agentTransferTimeout','update','outbound','channel','util','http','TransferReport','WhatsappQueues','code','Start'];(function(_0x30d9ee,_0x29ab29){const _0x2e632=function(_0x130baf){while(--_0x130baf){_0x30d9ee['push'](_0x30d9ee['shift']());}};_0x2e632(++_0x29ab29);}(a527_0x29ab,0x1f0));const a527_0x2e63=function(_0x30d9ee,_0x29ab29){_0x30d9ee=_0x30d9ee-0x0;let _0x2e632=a527_0x29ab[_0x30d9ee];return _0x2e632;};const _0x34e201=a527_0x2e63;'use strict';const moment=require(_0x34e201('0x48')),_=require(_0x34e201('0x2')),util=require(_0x34e201('0xa')),db=require(_0x34e201('0x21'))['db'],{Op}=require(_0x34e201('0x3')),logger=require(_0x34e201('0x23'))('api'),jayson=require(_0x34e201('0x61')),amiClient=jayson[_0x34e201('0x3c')][_0x34e201('0xb')]({'port':0x232a}),mailClient=jayson['client']['http']({'port':0x232b}),routingClient=jayson['client'][_0x34e201('0xb')]({'port':0x232c});function respondWithRpcPromise(_0x130baf,_0x839244,_0x4a94f8){return new Promise(function(_0x35dd38,_0x276b24){const _0x88498e=a527_0x2e63,_0x1332e8=_0x4a94f8?_0x4a94f8:amiClient;return _0x1332e8[_0x88498e('0x59')](_0x130baf,_0x839244)[_0x88498e('0x45')](function(_0x3fabd3){const _0x278c1f=_0x88498e;if(_0x3fabd3['error']){if(_0x3fabd3[_0x278c1f('0x67')][_0x278c1f('0xe')]===0x1f4)return _0x276b24(_0x3fabd3[_0x278c1f('0x67')][_0x278c1f('0x43')]);return _0x35dd38(_0x3fabd3['error'][_0x278c1f('0x43')]);}else _0x35dd38(_0x3fabd3['result']);})[_0x88498e('0x7f')](function(_0x12fa0e){_0x276b24(_0x12fa0e);});});}function respondWithResult(_0x3a348d,_0x43f38b){return _0x43f38b=_0x43f38b||0xc8,function(_0x534f95){const _0x4f6042=a527_0x2e63;if(_0x534f95)return _0x3a348d[_0x4f6042('0x4c')](_0x43f38b)['json'](_0x534f95);return _0x3a348d[_0x4f6042('0x63')](0x194);};}function handleError(_0xd50bc5,_0x534633){return _0x534633=_0x534633||0x1f4,function(_0x290c47){const _0x2f3f88=a527_0x2e63;logger[_0x2f3f88('0x67')](_0x290c47['stack']),_0x290c47[_0x2f3f88('0x12')]&&delete _0x290c47[_0x2f3f88('0x12')],_0xd50bc5[_0x2f3f88('0x4c')](_0x534633)[_0x2f3f88('0x70')](_0x290c47);};}function findById(_0xcbd3b2){return function(_0x1c9087){const _0x4c2adc=a527_0x2e63;if(!_[_0x4c2adc('0x53')](_0xcbd3b2)&&!_[_0x4c2adc('0x53')](_0x1c9087)&&!_[_0x4c2adc('0x53')](_0x1c9087[_0x4c2adc('0x6a')]))return _[_0x4c2adc('0x5b')](_0x1c9087[_0x4c2adc('0x6a')],function(_0x3673a0){return _0x3673a0['id']==_0xcbd3b2;});return null;};}exports[_0x34e201('0x3b')]=function(_0x54de3c,_0x2c430b){const _0x46b470=_0x34e201;return respondWithRpcPromise('VoiceChannels',_0x54de3c['query'])[_0x46b470('0x45')](respondWithResult(_0x2c430b,null))['catch'](handleError(_0x2c430b,null));},exports[_0x34e201('0x25')]=function(_0x111173,_0x705ed){const _0x247ffc=_0x34e201;return respondWithRpcPromise(_0x247ffc('0x44'),_[_0x247ffc('0x38')](_0x111173[_0x247ffc('0x32')],_0x111173['params']))[_0x247ffc('0x45')](respondWithResult(_0x705ed,null))['catch'](handleError(_0x705ed,null));},exports[_0x34e201('0x64')]=function(_0x2f38b1,_0x46f814){const _0x1eeb4d=_0x34e201;return respondWithRpcPromise('VoiceChannelStopMixMonitor',_[_0x1eeb4d('0x38')](_0x2f38b1['query'],_0x2f38b1[_0x1eeb4d('0x33')]))['then'](respondWithResult(_0x46f814,null))[_0x1eeb4d('0x7f')](handleError(_0x46f814,null));},exports['voiceQueues']=function(_0x343370,_0x1a684f){const _0x3b5d39=_0x34e201;return respondWithRpcPromise(_0x3b5d39('0x24'),_0x343370[_0x3b5d39('0x32')])[_0x3b5d39('0x45')](respondWithResult(_0x1a684f,null))[_0x3b5d39('0x7f')](handleError(_0x1a684f,null));},exports[_0x34e201('0x37')]=function(_0x403d33,_0x3fbb8b){const _0x1419ee=_0x34e201;return respondWithRpcPromise('VoiceQueues',_0x403d33[_0x1419ee('0x32')])[_0x1419ee('0x45')](findById(_0x403d33[_0x1419ee('0x33')]['id']))['then'](respondWithResult(_0x3fbb8b,null))[_0x1419ee('0x7f')](handleError(_0x3fbb8b,null));},exports[_0x34e201('0x22')]=function(_0x5259a9,_0x2e0f4e){const _0x2f920a=_0x34e201;return respondWithRpcPromise(_0x2f920a('0x18'),_[_0x2f920a('0x38')](_0x5259a9[_0x2f920a('0x32')],_0x5259a9[_0x2f920a('0x33')]))['then'](respondWithResult(_0x2e0f4e,null))[_0x2f920a('0x7f')](handleError(_0x2e0f4e,null));},exports['voiceQueuesChannels']=function(_0x1943ab,_0x55e672){const _0xf1b47a=_0x34e201;return respondWithRpcPromise(_0xf1b47a('0x2e'),_0x1943ab[_0xf1b47a('0x32')])[_0xf1b47a('0x45')](respondWithResult(_0x55e672,null))['catch'](handleError(_0x55e672,null));},exports[_0x34e201('0x0')]=function(_0x530f10,_0x4f4ec3){const _0x34231a=_0x34e201;return respondWithRpcPromise(_0x34231a('0x4'),_[_0x34231a('0x38')](_0x530f10['query'],_0x530f10[_0x34231a('0x33')]))[_0x34231a('0x45')](respondWithResult(_0x4f4ec3,null))[_0x34231a('0x7f')](handleError(_0x4f4ec3,null));},exports[_0x34e201('0x5')]=function(_0x221154,_0x23fce3){const _0xa08e9e=_0x34e201;return respondWithRpcPromise(_0xa08e9e('0x13'),_[_0xa08e9e('0x38')](_0x221154[_0xa08e9e('0x32')],_0x221154[_0xa08e9e('0x33')]))[_0xa08e9e('0x45')](respondWithResult(_0x23fce3,null))[_0xa08e9e('0x7f')](handleError(_0x23fce3,null));},exports['voiceQueuesChannelRedirect']=function(_0x31b4ee,_0x1c041a){const _0x14d12f=_0x34e201;return respondWithRpcPromise('VoiceQueuesChannelRedirect',_[_0x14d12f('0x38')](_0x31b4ee[_0x14d12f('0x32')],_0x31b4ee[_0x14d12f('0x33')]))[_0x14d12f('0x45')](respondWithResult(_0x1c041a,null))[_0x14d12f('0x7f')](handleError(_0x1c041a,null));},exports[_0x34e201('0x8')]=function(_0x2cabde,_0x36b4d5){const _0x3cc64d=_0x34e201;return respondWithRpcPromise(_0x3cc64d('0x57'),_0x2cabde[_0x3cc64d('0x32')])[_0x3cc64d('0x45')](respondWithResult(_0x36b4d5,null))['catch'](handleError(_0x36b4d5,null));},exports[_0x34e201('0x6c')]=function(_0x413ed9,_0x24e5f7){const _0x346dbf=_0x34e201;return respondWithRpcPromise(_0x346dbf('0x6e'),_0x413ed9[_0x346dbf('0x32')])[_0x346dbf('0x45')](respondWithResult(_0x24e5f7,null))[_0x346dbf('0x7f')](handleError(_0x24e5f7,null));},exports[_0x34e201('0x1')]=function(_0x1a4765,_0x15f971){const _0x151865=_0x34e201;let _0x53c1f3;return respondWithRpcPromise(_0x151865('0x2c'),_0x1a4765[_0x151865('0x32')])[_0x151865('0x45')](function(_0x4b6c98){const _0x1943f5=_0x151865;return _0x53c1f3=_0x4b6c98,respondWithRpcPromise(_0x1943f5('0x2c'),_0x1a4765[_0x1943f5('0x32')],routingClient);})[_0x151865('0x45')](function(_0xd9279d){return _['merge']({},_0xd9279d,_0x53c1f3);})[_0x151865('0x45')](respondWithResult(_0x15f971,null))[_0x151865('0x7f')](handleError(_0x15f971,null));},exports[_0x34e201('0x7a')]=function(_0x43f0ae,_0x15ed1a){const _0x23d500=_0x34e201;if(_0x43f0ae[_0x23d500('0x51')]&&_0x43f0ae[_0x23d500('0x51')]['interaction']&&_0x43f0ae[_0x23d500('0x41')]&&_0x43f0ae[_0x23d500('0x41')]['name'])for(const _0x1fd980 in _0x43f0ae[_0x23d500('0x51')][_0x23d500('0x2d')]){if(typeof _0x43f0ae[_0x23d500('0x51')][_0x23d500('0x2d')][_0x1fd980]!=='undefined'){db[_0x23d500('0x31')][_0x23d500('0x2b')]({'where':{'channel':_0x1fd980,'membername':_0x43f0ae['user'][_0x23d500('0x12')],'type':_0x23d500('0x29'),'exitAt':null,'uniqueid':_0x43f0ae[_0x23d500('0x51')][_0x23d500('0x2d')][_0x1fd980]&&_0x43f0ae[_0x23d500('0x51')][_0x23d500('0x2d')][_0x1fd980][_0x23d500('0x10')]?{[Op[_0x23d500('0x26')]]:_0x43f0ae[_0x23d500('0x51')][_0x23d500('0x2d')][_0x1fd980]}:{[Op['ne']]:null}}})[_0x23d500('0x45')](function(_0x40bafe){const _0x28e002=_0x23d500,_0x37ba26=moment()['format'](_0x28e002('0x55'));for(let _0x101600=0x0,_0x6380e0=_0x40bafe['length'];_0x101600<_0x6380e0;_0x101600+=0x1){_0x40bafe[_0x101600][_0x28e002('0x7')]({'exitAt':_0x37ba26});}});for(let _0x562ae8=0x0;_0x562ae8<_0x43f0ae[_0x23d500('0x51')][_0x23d500('0x2d')][_0x1fd980][_0x23d500('0x10')];_0x562ae8+=0x1){db[_0x23d500('0x31')][_0x23d500('0x2f')]({'where':{'channel':_0x1fd980,'membername':_0x43f0ae[_0x23d500('0x41')][_0x23d500('0x12')],'type':_0x23d500('0x29'),'uniqueid':_0x43f0ae[_0x23d500('0x51')][_0x23d500('0x2d')][_0x1fd980][_0x562ae8],'exitAt':null},'defaults':{'channel':_0x1fd980,'membername':_0x43f0ae[_0x23d500('0x41')][_0x23d500('0x12')],'interface':_[_0x23d500('0x53')](_0x43f0ae[_0x23d500('0x41')][_0x23d500('0x16')])?util['format'](_0x23d500('0x11'),_0x43f0ae['user'][_0x23d500('0x12')]):_0x43f0ae[_0x23d500('0x41')][_0x23d500('0x16')],'type':_0x23d500('0x29'),'enterAt':moment()[_0x23d500('0x52')](_0x23d500('0x55')),'role':_0x23d500('0x1d'),'internal':_0x43f0ae[_0x23d500('0x41')][_0x23d500('0x17')],'uniqueid':_0x43f0ae[_0x23d500('0x51')][_0x23d500('0x2d')][_0x1fd980][_0x562ae8]}});}}}return respondWithRpcPromise(_0x23d500('0x71'),{'id':_0x43f0ae[_0x23d500('0x33')]['id'],'capacity':_0x43f0ae[_0x23d500('0x51')]['capacity']},routingClient)[_0x23d500('0x45')](respondWithResult(_0x15ed1a,null))[_0x23d500('0x7f')](handleError(_0x15ed1a,null));},exports[_0x34e201('0x75')]=function(_0xaf9848,_0x4e0230){const _0x4213b3=_0x34e201;return respondWithRpcPromise(_0x4213b3('0x74'),_0xaf9848[_0x4213b3('0x32')])[_0x4213b3('0x45')](respondWithResult(_0x4e0230,null))['catch'](handleError(_0x4e0230,null));},exports[_0x34e201('0x77')]=function(_0x7965a1,_0x288e06){const _0x25eba4=_0x34e201;return respondWithRpcPromise(_0x25eba4('0x65'),_0x7965a1[_0x25eba4('0x32')])[_0x25eba4('0x45')](respondWithResult(_0x288e06,null))[_0x25eba4('0x7f')](handleError(_0x288e06,null));},exports['campaigns']=function(_0x3d68ed,_0x3bd96c){const _0x183831=_0x34e201;return respondWithRpcPromise(_0x183831('0x27'),_0x3d68ed[_0x183831('0x32')])[_0x183831('0x45')](respondWithResult(_0x3bd96c,null))[_0x183831('0x7f')](handleError(_0x3bd96c,null));},exports[_0x34e201('0x68')]=function(_0x119077,_0x3a84d8){const _0x53053f=_0x34e201;return respondWithRpcPromise(_0x53053f('0x4d'),_0x119077['query'],routingClient)[_0x53053f('0x45')](respondWithResult(_0x3a84d8,null))['catch'](handleError(_0x3a84d8,null));},exports[_0x34e201('0x7e')]=function(_0x157c7b,_0x29f487){const _0x5d55f9=_0x34e201;return respondWithRpcPromise(_0x5d55f9('0x4d'),_0x157c7b[_0x5d55f9('0x32')],routingClient)['then'](findById(_0x157c7b['params']['id']))['then'](respondWithResult(_0x29f487,null))[_0x5d55f9('0x7f')](handleError(_0x29f487,null));},exports[_0x34e201('0x5a')]=function(_0x567fc9,_0x551254){const _0x40a6e7=_0x34e201;return respondWithRpcPromise(_0x40a6e7('0x78'),_0x567fc9['query'],routingClient)[_0x40a6e7('0x45')](respondWithResult(_0x551254,null))[_0x40a6e7('0x7f')](handleError(_0x551254,null));},exports[_0x34e201('0x79')]=function(_0x139704,_0x39981e){const _0x5be3f3=_0x34e201;return respondWithRpcPromise(_0x5be3f3('0x78'),_0x139704[_0x5be3f3('0x32')],routingClient)[_0x5be3f3('0x45')](findById(_0x139704[_0x5be3f3('0x33')]['id']))[_0x5be3f3('0x45')](respondWithResult(_0x39981e,null))[_0x5be3f3('0x7f')](handleError(_0x39981e,null));},exports[_0x34e201('0x1a')]=function(_0x1ca0cc,_0x2ff880){const _0x2eaf43=_0x34e201;return respondWithRpcPromise('MailAccounts',_0x1ca0cc[_0x2eaf43('0x32')],mailClient)[_0x2eaf43('0x45')](respondWithResult(_0x2ff880,null))[_0x2eaf43('0x7f')](handleError(_0x2ff880,null));},exports[_0x34e201('0x4e')]=function(_0xbc3df1,_0x2bc003){const _0x578bdc=_0x34e201;return respondWithRpcPromise('OpenchannelQueues',_0xbc3df1['query'],routingClient)[_0x578bdc('0x45')](respondWithResult(_0x2bc003,null))[_0x578bdc('0x7f')](handleError(_0x2bc003,null));},exports[_0x34e201('0x28')]=function(_0x21ca15,_0x4276ba){const _0x34849f=_0x34e201;return respondWithRpcPromise(_0x34849f('0x1e'),_0x21ca15[_0x34849f('0x32')],routingClient)['then'](findById(_0x21ca15[_0x34849f('0x33')]['id']))[_0x34849f('0x45')](respondWithResult(_0x4276ba,null))[_0x34849f('0x7f')](handleError(_0x4276ba,null));},exports[_0x34e201('0x15')]=function(_0x2b1ce9,_0x35bc9a){const _0x361a2b=_0x34e201;return respondWithRpcPromise(_0x361a2b('0x2a'),_0x2b1ce9['query'],routingClient)[_0x361a2b('0x45')](respondWithResult(_0x35bc9a,null))[_0x361a2b('0x7f')](handleError(_0x35bc9a,null));},exports[_0x34e201('0x60')]=function(_0x2c6a8f,_0x325fd3){const _0x2d7d80=_0x34e201;return respondWithRpcPromise(_0x2d7d80('0x2a'),_0x2c6a8f[_0x2d7d80('0x32')],routingClient)[_0x2d7d80('0x45')](findById(_0x2c6a8f[_0x2d7d80('0x33')]['id']))[_0x2d7d80('0x45')](respondWithResult(_0x325fd3,null))[_0x2d7d80('0x7f')](handleError(_0x325fd3,null));},exports['whatsappQueues']=function(_0x10a0b5,_0x4cb3b2){const _0x21b6f8=_0x34e201;return respondWithRpcPromise(_0x21b6f8('0xd'),_0x10a0b5[_0x21b6f8('0x32')],routingClient)[_0x21b6f8('0x45')](respondWithResult(_0x4cb3b2,null))[_0x21b6f8('0x7f')](handleError(_0x4cb3b2,null));},exports[_0x34e201('0x76')]=function(_0x48fd06,_0xb5634){const _0x3b691f=_0x34e201;return respondWithRpcPromise(_0x3b691f('0xd'),_0x48fd06[_0x3b691f('0x32')],routingClient)['then'](findById(_0x48fd06[_0x3b691f('0x33')]['id']))[_0x3b691f('0x45')](respondWithResult(_0xb5634,null))[_0x3b691f('0x7f')](handleError(_0xb5634,null));},exports[_0x34e201('0x62')]=function(_0x41272a,_0x341caf){const _0x2d6354=_0x34e201;return respondWithRpcPromise(_0x2d6354('0x5c'),_0x41272a[_0x2d6354('0x32')],routingClient)[_0x2d6354('0x45')](respondWithResult(_0x341caf,null))[_0x2d6354('0x7f')](handleError(_0x341caf,null));},exports[_0x34e201('0x19')]=function(_0x341779,_0xa1521e){const _0x438b35=_0x34e201;return respondWithRpcPromise(_0x438b35('0x5c'),_0x341779['query'],routingClient)[_0x438b35('0x45')](findById(_0x341779[_0x438b35('0x33')]['id']))[_0x438b35('0x45')](respondWithResult(_0xa1521e,null))[_0x438b35('0x7f')](handleError(_0xa1521e,null));},exports[_0x34e201('0x34')]=function(_0x1b2f2d,_0x18b924){const _0x515ffa=_0x34e201;return respondWithRpcPromise(_0x515ffa('0x7d'),_0x1b2f2d[_0x515ffa('0x32')])[_0x515ffa('0x45')](respondWithResult(_0x18b924,null))['catch'](handleError(_0x18b924,null));},exports[_0x34e201('0x73')]=function(_0x28f726,_0x565df2){const _0x5120f5=_0x34e201;return respondWithRpcPromise('ChatQueuesWaitingInteractions',_0x28f726[_0x5120f5('0x32')],routingClient)[_0x5120f5('0x45')](respondWithResult(_0x565df2,null))[_0x5120f5('0x7f')](handleError(_0x565df2,null));},exports[_0x34e201('0x3d')]=function(_0x438d66,_0x17665b){const _0x2790b0=_0x34e201;return respondWithRpcPromise(_0x2790b0('0x69'),_0x438d66[_0x2790b0('0x32')],routingClient)[_0x2790b0('0x45')](respondWithResult(_0x17665b,null))[_0x2790b0('0x7f')](handleError(_0x17665b,null));},exports[_0x34e201('0x66')]=function(_0x200396,_0x3f3e7c){const _0x4a77a3=_0x34e201;return respondWithRpcPromise(_0x4a77a3('0x7c'),_0x200396[_0x4a77a3('0x32')],routingClient)[_0x4a77a3('0x45')](respondWithResult(_0x3f3e7c,null))[_0x4a77a3('0x7f')](handleError(_0x3f3e7c,null));},exports[_0x34e201('0x6d')]=function(_0x565d59,_0x25ae01){const _0x8e3702=_0x34e201;return respondWithRpcPromise('OpenchannelQueuesWaitingInteractions',_0x565d59['query'],routingClient)[_0x8e3702('0x45')](function(_0x4c7d62){const _0x2a6d3f=_0x8e3702;if(_0x565d59['query'][_0x2a6d3f('0x6b')]!==undefined){const _0x51300f=_(_0x4c7d62[_0x2a6d3f('0x6a')])[_0x2a6d3f('0x3a')]([_0x565d59[_0x2a6d3f('0x32')][_0x2a6d3f('0x6b')],_0x565d59[_0x2a6d3f('0x33')]['id']])['map']('queue_id')['uniq']()[_0x2a6d3f('0x4a')]();return _0x4c7d62['rows'][_0x2a6d3f('0x3a')](function(_0x54f6d7){const _0xcedd63=_0x2a6d3f;return _0x51300f[_0xcedd63('0x56')](_0x54f6d7[_0xcedd63('0x4b')])>-0x1;});}else return _0x4c7d62[_0x2a6d3f('0x6a')][_0x2a6d3f('0x3a')](function(_0x24fe16){const _0x319bdd=_0x2a6d3f;return _0x24fe16[_0x319bdd('0x4b')]===parseInt(_0x565d59[_0x319bdd('0x33')]['id']);});})[_0x8e3702('0x45')](respondWithResult(_0x25ae01,null))[_0x8e3702('0x7f')](handleError(_0x25ae01,null));},exports['smsQueuesWaitingInteractions']=function(_0xc9945e,_0x4190a8){const _0x5cab8d=_0x34e201;return respondWithRpcPromise(_0x5cab8d('0x6f'),_0xc9945e[_0x5cab8d('0x32')],routingClient)[_0x5cab8d('0x45')](respondWithResult(_0x4190a8,null))[_0x5cab8d('0x7f')](handleError(_0x4190a8,null));},exports['whatsappQueuesWaitingInteractions']=function(_0x270c29,_0x121078){const _0x4fbbb5=_0x34e201;return respondWithRpcPromise(_0x4fbbb5('0x1b'),_0x270c29[_0x4fbbb5('0x32')],routingClient)[_0x4fbbb5('0x45')](respondWithResult(_0x121078,null))['catch'](handleError(_0x121078,null));},exports['faxQueuesWaitingInteractions']=function(_0x5be1f7,_0x2da671){const _0x433ccc=_0x34e201;return respondWithRpcPromise(_0x433ccc('0x39'),_0x5be1f7[_0x433ccc('0x32')],routingClient)['then'](respondWithResult(_0x2da671,null))['catch'](handleError(_0x2da671,null));},exports[_0x34e201('0x30')]=function(_0x5b19db){return function(_0xfa65d1,_0x46b82d){const _0x4d51b2=a527_0x2e63;let _0x4f6413,_0x26eb10;const _0x533f36=_['capitalize'](_0x5b19db),_0x22241d=_0x5b19db==='chat'?_0x4d51b2('0x40'):_0x4d51b2('0x42');return db[_0x533f36+_0x4d51b2('0x3f')][_0x4d51b2('0x72')]({'raw':!![],'where':{'id':_0xfa65d1['params']['id']}})[_0x4d51b2('0x45')](function(_0x3568b3){const _0x1ff44e=_0x4d51b2;if(_[_0x1ff44e('0x53')](_0x3568b3))throw new Error(_0x533f36+_0x1ff44e('0x4f'));return _0x4f6413=_0x3568b3,db[_0x533f36+'Message'][_0x1ff44e('0x72')]({'where':{'id':_0xfa65d1[_0x1ff44e('0x51')][_0x1ff44e('0x1f')]},'include':[{'model':db[_0x533f36+_0x1ff44e('0x54')],'as':_0x1ff44e('0x54')},{'model':db[_0x533f36+_0x22241d],'as':_0x1ff44e('0x42')}]});})['then'](function(_0x2f28a1){const _0x213aee=_0x4d51b2;if(_['isNil'](_0x2f28a1))throw new Error(_0x533f36+'\x20Message\x20not\x20found');return _0x26eb10=_0x2f28a1,_0x2f28a1[_0x213aee('0x7')]({'read':0x0,'readAt':null,'UserId':null});})[_0x4d51b2('0x45')](function(){const _0x12e478=_0x4d51b2,_0x5a259f={'uniqueid':_0x5b19db+'.'+_0x26eb10['id']+'.'+_0x26eb10[_0x12e478('0x54')]['id'],'FromUserId':_0xfa65d1[_0x12e478('0x41')]['id'],'type':_0x12e478('0x14')};return _0x5a259f[_0x533f36+_0x12e478('0x49')]=_0x26eb10['id'],_0x5a259f[_0x533f36+_0x12e478('0x46')]=_0x26eb10[_0x12e478('0x54')]['id'],_0x5a259f[_0x12e478('0x5f')+_0x533f36+_0x22241d+'Id']=_0x26eb10[_0x12e478('0x42')]['id'],_0x5a259f['To'+_0x533f36+_0x12e478('0x35')]=_0x4f6413['id'],db[_0x533f36+_0x12e478('0xc')][_0x12e478('0x5e')](_0x5a259f);})[_0x4d51b2('0x45')](function(){const _0xf6bdbd=_0x4d51b2;return respondWithRpcPromise('Start',{'channel':_0x5b19db,'interaction':_0x26eb10['Interaction'],'message':_0x26eb10,'account':_0x26eb10['Account'],'applications':[{'id':0x0,'priority':0x1,'app':_0xf6bdbd('0x14'),'appdata':_0x4f6413[_0xf6bdbd('0x12')]+','+(_0x26eb10[_0xf6bdbd('0x42')][_0xf6bdbd('0x36')]||0x12c),'interval':_0xf6bdbd('0x3e')}]},routingClient);})['then'](respondWithResult(_0x46b82d,null))[_0x4d51b2('0x7f')](handleError(_0x46b82d,null));};},exports[_0x34e201('0x7b')]=function(_0x4ab74a,_0x442b3e){const _0x5d332e=_0x34e201;let _0x890a3c,_0x494224;if(_['isNil'](_0x4ab74a[_0x5d332e('0x51')][_0x5d332e('0x9')]))throw new Error(_0x5d332e('0x20'));const _0x522e5e=_0x4ab74a[_0x5d332e('0x51')][_0x5d332e('0x9')],_0x28b9a1=_[_0x5d332e('0x58')](_0x522e5e),_0x493433=_0x522e5e===_0x5d332e('0x1c')?_0x5d332e('0x40'):'Account';return db['User']['findOne']({'raw':!![],'where':{'id':_0x4ab74a['params']['id'],'role':_0x5d332e('0x1d')}})[_0x5d332e('0x45')](function(_0x2d62b0){const _0x5514aa=_0x5d332e;if(_['isNil'](_0x2d62b0))throw new Error(_0x5514aa('0x5d'));return _0x890a3c=_0x2d62b0,db[_0x28b9a1+_0x5514aa('0x47')][_0x5514aa('0x72')]({'where':{'id':_0x4ab74a[_0x5514aa('0x51')][_0x5514aa('0x1f')]},'include':[{'model':db[_0x28b9a1+'Interaction'],'as':_0x5514aa('0x54')},{'model':db[_0x28b9a1+_0x493433],'as':'Account'}]});})[_0x5d332e('0x45')](function(_0x23340b){const _0x2160af=_0x5d332e;if(_[_0x2160af('0x53')](_0x23340b))throw new Error(_0x28b9a1+_0x2160af('0x50'));return _0x494224=_0x23340b,_0x23340b[_0x2160af('0x7')]({'read':0x0,'readAt':null,'UserId':null});})['then'](function(){const _0x519cd8=_0x5d332e,_0x3f41b3={'uniqueid':_0x522e5e+'.'+_0x494224['id']+'.'+_0x494224[_0x519cd8('0x54')]['id'],'FromUserId':_0x4ab74a['user']['id'],'type':_0x519cd8('0x14'),'ToUserId':_0x890a3c['id']};return _0x3f41b3[_0x28b9a1+'MessageId']=_0x494224['id'],_0x3f41b3[_0x28b9a1+_0x519cd8('0x46')]=_0x494224[_0x519cd8('0x54')]['id'],_0x3f41b3['From'+_0x28b9a1+_0x493433+'Id']=_0x494224[_0x519cd8('0x42')]['id'],db[_0x28b9a1+_0x519cd8('0xc')][_0x519cd8('0x5e')](_0x3f41b3);})[_0x5d332e('0x45')](function(){const _0x1cf389=_0x5d332e;return respondWithRpcPromise(_0x1cf389('0xf'),{'channel':_0x522e5e,'interaction':_0x494224['Interaction'],'message':_0x494224,'account':_0x494224[_0x1cf389('0x42')],'applications':[{'id':0x0,'priority':0x1,'app':_0x1cf389('0x1d'),'appdata':_0x890a3c[_0x1cf389('0x12')]+','+(_0x494224['Account'][_0x1cf389('0x6')]||0x12c),'interval':_0x1cf389('0x3e')}]},routingClient);})[_0x5d332e('0x45')](respondWithResult(_0x442b3e,null))[_0x5d332e('0x7f')](handleError(_0x442b3e,null));}; \ No newline at end of file +const a527_0x1409=['WhatsappQueues','agents','openchannelQueuesWaitingInteractions','whatsappQueues','outboundChannels','Telephones','MailAccounts','campaigns','FaxQueuesWaitingInteractions','rows','INTERACTION','interaction','WhatsappQueuesWaitingInteractions','\x20Queue\x20not\x20found','outbound','showOpenchannelQueues','OpenchannelQueuesWaitingInteractions','uniq','VoiceChannels','faxAccounts','ChatQueuesWaitingInteractions','From','ChatQueues','indexOf','VoiceQueuesChannelRedirect','params','voiceChannels','showWhatsappQueues','voiceQueuesChannel','agentNotify','chatQueuesWaitingInteractions','queueTransferTimeout','catch','util','User','Channel\x20field\x20is\x20mandatory','merge','isNil','findOne','../../mysqldb','Campaigns','update','smsQueues','error','interface','voiceChannelStopMixMonitor','Agent\x20not\x20found','VoiceQueuesChannels','showChatQueues','mailAccounts','format','find','map','TransferReport','showFaxQueues','InteractionId','../../config/logger','*,*,*,*','VoiceChannelMixMonitor','create','Website','client','filter','voiceQueuesPreview','VoiceQueues','result','Message','showSmsQueues','Start','code','MailQueuesWaitingInteractions','messageId','length','AgentCapacity','http','capitalize','OpenchannelQueues','YYYY-MM-DD\x20HH:mm:ss','agentTransferTimeout','smsQueuesWaitingInteractions','FaxQueues','queue_id','Queue','SmsQueues','QueueId','lodash','internal','Outbound','json','SIP/%s','Account','Interaction','findOrCreate','channel','then','faxQueues','user','name','voiceQueuesChannels','status','queue','moment','showMailQueues','send','faxQueuesWaitingInteractions','\x20Message\x20not\x20found','MailQueues','agentCapacity','type','sendStatus','MessageId','queueNotify','stack','api','findAll','body','voiceQueuesChannelRedirect','trunks','Agents','chat','value','query'];(function(_0x26ed07,_0x14092f){const _0xdb764c=function(_0x861c85){while(--_0x861c85){_0x26ed07['push'](_0x26ed07['shift']());}};_0xdb764c(++_0x14092f);}(a527_0x1409,0x18d));const a527_0xdb76=function(_0x26ed07,_0x14092f){_0x26ed07=_0x26ed07-0x0;let _0xdb764c=a527_0x1409[_0x26ed07];return _0xdb764c;};const _0x4b6ac4=a527_0xdb76;'use strict';const moment=require(_0x4b6ac4('0x46')),_=require(_0x4b6ac4('0x36')),util=require(_0x4b6ac4('0x2')),db=require(_0x4b6ac4('0x8'))['db'],{Op}=require('sequelize'),logger=require(_0x4b6ac4('0x19'))(_0x4b6ac4('0x52')),jayson=require('jayson/promise'),amiClient=jayson[_0x4b6ac4('0x1e')][_0x4b6ac4('0x2b')]({'port':0x232a}),mailClient=jayson['client'][_0x4b6ac4('0x2b')]({'port':0x232b}),routingClient=jayson[_0x4b6ac4('0x1e')][_0x4b6ac4('0x2b')]({'port':0x232c});function respondWithRpcPromise(_0x861c85,_0x500817,_0x268bba){return new Promise(function(_0x39603e,_0x3eefb6){const _0x1c32c5=a527_0xdb76,_0xf4d9aa=_0x268bba?_0x268bba:amiClient;return _0xf4d9aa['request'](_0x861c85,_0x500817)[_0x1c32c5('0x3f')](function(_0xc39c22){const _0x4816a4=_0x1c32c5;if(_0xc39c22['error']){if(_0xc39c22[_0x4816a4('0xc')][_0x4816a4('0x26')]===0x1f4)return _0x3eefb6(_0xc39c22['error']['message']);return _0x39603e(_0xc39c22['error']['message']);}else _0x39603e(_0xc39c22[_0x4816a4('0x22')]);})['catch'](function(_0x487a33){_0x3eefb6(_0x487a33);});});}function respondWithResult(_0x11a240,_0x37f476){return _0x37f476=_0x37f476||0xc8,function(_0x2255b4){const _0x2874bb=a527_0xdb76;if(_0x2255b4)return _0x11a240['status'](_0x37f476)[_0x2874bb('0x39')](_0x2255b4);return _0x11a240[_0x2874bb('0x4e')](0x194);};}function handleError(_0x1a2e4c,_0x45891a){return _0x45891a=_0x45891a||0x1f4,function(_0x29da60){const _0x3988f7=a527_0xdb76;logger[_0x3988f7('0xc')](_0x29da60[_0x3988f7('0x51')]),_0x29da60[_0x3988f7('0x42')]&&delete _0x29da60[_0x3988f7('0x42')],_0x1a2e4c[_0x3988f7('0x44')](_0x45891a)[_0x3988f7('0x48')](_0x29da60);};}function findById(_0x4ec7b4){return function(_0x358dd9){const _0x2d5c56=a527_0xdb76;if(!_[_0x2d5c56('0x6')](_0x4ec7b4)&&!_[_0x2d5c56('0x6')](_0x358dd9)&&!_[_0x2d5c56('0x6')](_0x358dd9['rows']))return _[_0x2d5c56('0x14')](_0x358dd9[_0x2d5c56('0x64')],function(_0x10de12){return _0x10de12['id']==_0x4ec7b4;});return null;};}exports[_0x4b6ac4('0x75')]=function(_0x20f0ff,_0x2d47a6){const _0x4198e6=_0x4b6ac4;return respondWithRpcPromise(_0x4198e6('0x6d'),_0x20f0ff[_0x4198e6('0x5a')])['then'](respondWithResult(_0x2d47a6,null))[_0x4198e6('0x1')](handleError(_0x2d47a6,null));},exports['voiceChannelMixMonitor']=function(_0x599cc3,_0x49a843){const _0x2ef4fc=_0x4b6ac4;return respondWithRpcPromise(_0x2ef4fc('0x1b'),_[_0x2ef4fc('0x5')](_0x599cc3[_0x2ef4fc('0x5a')],_0x599cc3[_0x2ef4fc('0x74')]))[_0x2ef4fc('0x3f')](respondWithResult(_0x49a843,null))[_0x2ef4fc('0x1')](handleError(_0x49a843,null));},exports[_0x4b6ac4('0xe')]=function(_0x2737f5,_0x24d8fa){const _0x1c4e61=_0x4b6ac4;return respondWithRpcPromise('VoiceChannelStopMixMonitor',_[_0x1c4e61('0x5')](_0x2737f5['query'],_0x2737f5[_0x1c4e61('0x74')]))['then'](respondWithResult(_0x24d8fa,null))[_0x1c4e61('0x1')](handleError(_0x24d8fa,null));},exports['voiceQueues']=function(_0x2f5fc4,_0x4a0ee0){const _0x4a6e2c=_0x4b6ac4;return respondWithRpcPromise(_0x4a6e2c('0x21'),_0x2f5fc4[_0x4a6e2c('0x5a')])['then'](respondWithResult(_0x4a0ee0,null))[_0x4a6e2c('0x1')](handleError(_0x4a0ee0,null));},exports['showVoiceQueues']=function(_0x3b05a5,_0x40f6fc){const _0x5e5f46=_0x4b6ac4;return respondWithRpcPromise(_0x5e5f46('0x21'),_0x3b05a5[_0x5e5f46('0x5a')])[_0x5e5f46('0x3f')](findById(_0x3b05a5[_0x5e5f46('0x74')]['id']))[_0x5e5f46('0x3f')](respondWithResult(_0x40f6fc,null))[_0x5e5f46('0x1')](handleError(_0x40f6fc,null));},exports[_0x4b6ac4('0x20')]=function(_0x5478ab,_0x5643c0){const _0x3dcb3e=_0x4b6ac4;return respondWithRpcPromise('VoiceQueuesPreview',_[_0x3dcb3e('0x5')](_0x5478ab[_0x3dcb3e('0x5a')],_0x5478ab[_0x3dcb3e('0x74')]))['then'](respondWithResult(_0x5643c0,null))['catch'](handleError(_0x5643c0,null));},exports[_0x4b6ac4('0x43')]=function(_0x58be1e,_0x19fff6){const _0x42ad89=_0x4b6ac4;return respondWithRpcPromise(_0x42ad89('0x10'),_0x58be1e[_0x42ad89('0x5a')])['then'](respondWithResult(_0x19fff6,null))[_0x42ad89('0x1')](handleError(_0x19fff6,null));},exports[_0x4b6ac4('0x77')]=function(_0x359225,_0x47aab9){const _0x129215=_0x4b6ac4;return respondWithRpcPromise('VoiceQueuesChannel',_[_0x129215('0x5')](_0x359225[_0x129215('0x5a')],_0x359225[_0x129215('0x74')]))[_0x129215('0x3f')](respondWithResult(_0x47aab9,null))[_0x129215('0x1')](handleError(_0x47aab9,null));},exports['voiceQueuesChannelHangup']=function(_0x805b8,_0x3d64e5){const _0x168c3a=_0x4b6ac4;return respondWithRpcPromise('VoiceQueuesChannelHangup',_[_0x168c3a('0x5')](_0x805b8[_0x168c3a('0x5a')],_0x805b8[_0x168c3a('0x74')]))[_0x168c3a('0x3f')](respondWithResult(_0x3d64e5,null))[_0x168c3a('0x1')](handleError(_0x3d64e5,null));},exports[_0x4b6ac4('0x55')]=function(_0xe7a0fb,_0x35927f){const _0x49955b=_0x4b6ac4;return respondWithRpcPromise(_0x49955b('0x73'),_['merge'](_0xe7a0fb['query'],_0xe7a0fb[_0x49955b('0x74')]))[_0x49955b('0x3f')](respondWithResult(_0x35927f,null))[_0x49955b('0x1')](handleError(_0x35927f,null));},exports[_0x4b6ac4('0x69')]=function(_0xf4ebd0,_0x22ff0f){const _0x406074=_0x4b6ac4;return respondWithRpcPromise(_0x406074('0x38'),_0xf4ebd0[_0x406074('0x5a')])[_0x406074('0x3f')](respondWithResult(_0x22ff0f,null))[_0x406074('0x1')](handleError(_0x22ff0f,null));},exports[_0x4b6ac4('0x5f')]=function(_0x3257ef,_0x56962e){const _0x5ad901=_0x4b6ac4;return respondWithRpcPromise('OutboundChannels',_0x3257ef['query'])[_0x5ad901('0x3f')](respondWithResult(_0x56962e,null))[_0x5ad901('0x1')](handleError(_0x56962e,null));},exports[_0x4b6ac4('0x5c')]=function(_0x216599,_0x1a62a3){const _0x1469a7=_0x4b6ac4;let _0x21e090;return respondWithRpcPromise(_0x1469a7('0x57'),_0x216599[_0x1469a7('0x5a')])['then'](function(_0x387246){const _0x5067a0=_0x1469a7;return _0x21e090=_0x387246,respondWithRpcPromise('Agents',_0x216599[_0x5067a0('0x5a')],routingClient);})[_0x1469a7('0x3f')](function(_0x4b546e){const _0x3f3645=_0x1469a7;return _[_0x3f3645('0x5')]({},_0x4b546e,_0x21e090);})[_0x1469a7('0x3f')](respondWithResult(_0x1a62a3,null))[_0x1469a7('0x1')](handleError(_0x1a62a3,null));},exports[_0x4b6ac4('0x4c')]=function(_0xf18af6,_0x12d590){const _0x1baa73=_0x4b6ac4;if(_0xf18af6[_0x1baa73('0x54')]&&_0xf18af6[_0x1baa73('0x54')][_0x1baa73('0x66')]&&_0xf18af6[_0x1baa73('0x41')]&&_0xf18af6['user'][_0x1baa73('0x42')])for(const _0x2d0c55 in _0xf18af6[_0x1baa73('0x54')][_0x1baa73('0x66')]){if(typeof _0xf18af6[_0x1baa73('0x54')][_0x1baa73('0x66')][_0x2d0c55]!=='undefined'){db['MemberReport'][_0x1baa73('0x53')]({'where':{'channel':_0x2d0c55,'membername':_0xf18af6[_0x1baa73('0x41')][_0x1baa73('0x42')],'type':_0x1baa73('0x65'),'exitAt':null,'uniqueid':_0xf18af6[_0x1baa73('0x54')]['interaction'][_0x2d0c55]&&_0xf18af6[_0x1baa73('0x54')]['interaction'][_0x2d0c55][_0x1baa73('0x29')]?{[Op['notIn']]:_0xf18af6[_0x1baa73('0x54')][_0x1baa73('0x66')][_0x2d0c55]}:{[Op['ne']]:null}}})[_0x1baa73('0x3f')](function(_0x6521b6){const _0x49c067=_0x1baa73,_0x18f767=moment()[_0x49c067('0x13')](_0x49c067('0x2e'));for(let _0x37a5b8=0x0,_0x1a9f26=_0x6521b6[_0x49c067('0x29')];_0x37a5b8<_0x1a9f26;_0x37a5b8+=0x1){_0x6521b6[_0x37a5b8][_0x49c067('0xa')]({'exitAt':_0x18f767});}});for(let _0x1a5a39=0x0;_0x1a5a39<_0xf18af6[_0x1baa73('0x54')][_0x1baa73('0x66')][_0x2d0c55]['length'];_0x1a5a39+=0x1){db['MemberReport'][_0x1baa73('0x3d')]({'where':{'channel':_0x2d0c55,'membername':_0xf18af6['user'][_0x1baa73('0x42')],'type':_0x1baa73('0x65'),'uniqueid':_0xf18af6['body'][_0x1baa73('0x66')][_0x2d0c55][_0x1a5a39],'exitAt':null},'defaults':{'channel':_0x2d0c55,'membername':_0xf18af6['user'][_0x1baa73('0x42')],'interface':_['isNil'](_0xf18af6[_0x1baa73('0x41')][_0x1baa73('0xd')])?util[_0x1baa73('0x13')](_0x1baa73('0x3a'),_0xf18af6[_0x1baa73('0x41')]['name']):_0xf18af6[_0x1baa73('0x41')]['interface'],'type':_0x1baa73('0x65'),'enterAt':moment()[_0x1baa73('0x13')](_0x1baa73('0x2e')),'role':'agent','internal':_0xf18af6[_0x1baa73('0x41')][_0x1baa73('0x37')],'uniqueid':_0xf18af6['body'][_0x1baa73('0x66')][_0x2d0c55][_0x1a5a39]}});}}}return respondWithRpcPromise(_0x1baa73('0x2a'),{'id':_0xf18af6[_0x1baa73('0x74')]['id'],'capacity':_0xf18af6['body']['capacity']},routingClient)[_0x1baa73('0x3f')](respondWithResult(_0x12d590,null))[_0x1baa73('0x1')](handleError(_0x12d590,null));},exports['telephones']=function(_0x4c5eda,_0x2619aa){const _0x356ade=_0x4b6ac4;return respondWithRpcPromise(_0x356ade('0x60'),_0x4c5eda[_0x356ade('0x5a')])[_0x356ade('0x3f')](respondWithResult(_0x2619aa,null))[_0x356ade('0x1')](handleError(_0x2619aa,null));},exports[_0x4b6ac4('0x56')]=function(_0xd38e31,_0x1315d6){const _0x3e0c42=_0x4b6ac4;return respondWithRpcPromise('Trunks',_0xd38e31[_0x3e0c42('0x5a')])[_0x3e0c42('0x3f')](respondWithResult(_0x1315d6,null))[_0x3e0c42('0x1')](handleError(_0x1315d6,null));},exports[_0x4b6ac4('0x62')]=function(_0x5df029,_0x2d7690){const _0x32c79f=_0x4b6ac4;return respondWithRpcPromise(_0x32c79f('0x9'),_0x5df029[_0x32c79f('0x5a')])[_0x32c79f('0x3f')](respondWithResult(_0x2d7690,null))[_0x32c79f('0x1')](handleError(_0x2d7690,null));},exports['chatQueues']=function(_0x345a08,_0x6b4394){const _0xdf6e5b=_0x4b6ac4;return respondWithRpcPromise(_0xdf6e5b('0x71'),_0x345a08['query'],routingClient)[_0xdf6e5b('0x3f')](respondWithResult(_0x6b4394,null))[_0xdf6e5b('0x1')](handleError(_0x6b4394,null));},exports[_0x4b6ac4('0x11')]=function(_0x3e8b35,_0xe39d02){const _0x4d89ca=_0x4b6ac4;return respondWithRpcPromise(_0x4d89ca('0x71'),_0x3e8b35[_0x4d89ca('0x5a')],routingClient)['then'](findById(_0x3e8b35[_0x4d89ca('0x74')]['id']))[_0x4d89ca('0x3f')](respondWithResult(_0xe39d02,null))['catch'](handleError(_0xe39d02,null));},exports['mailQueues']=function(_0x2e393b,_0x474368){const _0x2be8ab=_0x4b6ac4;return respondWithRpcPromise(_0x2be8ab('0x4b'),_0x2e393b[_0x2be8ab('0x5a')],routingClient)[_0x2be8ab('0x3f')](respondWithResult(_0x474368,null))[_0x2be8ab('0x1')](handleError(_0x474368,null));},exports[_0x4b6ac4('0x47')]=function(_0x126d63,_0x580e98){const _0x438145=_0x4b6ac4;return respondWithRpcPromise(_0x438145('0x4b'),_0x126d63[_0x438145('0x5a')],routingClient)[_0x438145('0x3f')](findById(_0x126d63[_0x438145('0x74')]['id']))[_0x438145('0x3f')](respondWithResult(_0x580e98,null))[_0x438145('0x1')](handleError(_0x580e98,null));},exports[_0x4b6ac4('0x12')]=function(_0xfe023d,_0x11d1f1){const _0x2df4f0=_0x4b6ac4;return respondWithRpcPromise(_0x2df4f0('0x61'),_0xfe023d[_0x2df4f0('0x5a')],mailClient)[_0x2df4f0('0x3f')](respondWithResult(_0x11d1f1,null))[_0x2df4f0('0x1')](handleError(_0x11d1f1,null));},exports['openchannelQueues']=function(_0x363fb3,_0x329d8a){const _0x57fef4=_0x4b6ac4;return respondWithRpcPromise(_0x57fef4('0x2d'),_0x363fb3[_0x57fef4('0x5a')],routingClient)[_0x57fef4('0x3f')](respondWithResult(_0x329d8a,null))[_0x57fef4('0x1')](handleError(_0x329d8a,null));},exports[_0x4b6ac4('0x6a')]=function(_0x50d293,_0x3b6567){const _0xdf084d=_0x4b6ac4;return respondWithRpcPromise(_0xdf084d('0x2d'),_0x50d293['query'],routingClient)[_0xdf084d('0x3f')](findById(_0x50d293[_0xdf084d('0x74')]['id']))[_0xdf084d('0x3f')](respondWithResult(_0x3b6567,null))[_0xdf084d('0x1')](handleError(_0x3b6567,null));},exports[_0x4b6ac4('0xb')]=function(_0x2b6f14,_0x12f374){const _0x41cbd6=_0x4b6ac4;return respondWithRpcPromise(_0x41cbd6('0x34'),_0x2b6f14[_0x41cbd6('0x5a')],routingClient)[_0x41cbd6('0x3f')](respondWithResult(_0x12f374,null))['catch'](handleError(_0x12f374,null));},exports[_0x4b6ac4('0x24')]=function(_0x371492,_0x2b694d){const _0x3e1366=_0x4b6ac4;return respondWithRpcPromise(_0x3e1366('0x34'),_0x371492['query'],routingClient)['then'](findById(_0x371492[_0x3e1366('0x74')]['id']))[_0x3e1366('0x3f')](respondWithResult(_0x2b694d,null))['catch'](handleError(_0x2b694d,null));},exports[_0x4b6ac4('0x5e')]=function(_0x48e39c,_0x5c3d4c){const _0x464ace=_0x4b6ac4;return respondWithRpcPromise(_0x464ace('0x5b'),_0x48e39c['query'],routingClient)[_0x464ace('0x3f')](respondWithResult(_0x5c3d4c,null))[_0x464ace('0x1')](handleError(_0x5c3d4c,null));},exports[_0x4b6ac4('0x76')]=function(_0x47b816,_0x3cbfcc){const _0x7a8d4d=_0x4b6ac4;return respondWithRpcPromise(_0x7a8d4d('0x5b'),_0x47b816[_0x7a8d4d('0x5a')],routingClient)[_0x7a8d4d('0x3f')](findById(_0x47b816[_0x7a8d4d('0x74')]['id']))[_0x7a8d4d('0x3f')](respondWithResult(_0x3cbfcc,null))[_0x7a8d4d('0x1')](handleError(_0x3cbfcc,null));},exports[_0x4b6ac4('0x40')]=function(_0x3289c2,_0xc65fbc){const _0x32cf51=_0x4b6ac4;return respondWithRpcPromise(_0x32cf51('0x31'),_0x3289c2['query'],routingClient)[_0x32cf51('0x3f')](respondWithResult(_0xc65fbc,null))[_0x32cf51('0x1')](handleError(_0xc65fbc,null));},exports[_0x4b6ac4('0x17')]=function(_0x496d8c,_0x4839c9){const _0x2e92e4=_0x4b6ac4;return respondWithRpcPromise(_0x2e92e4('0x31'),_0x496d8c[_0x2e92e4('0x5a')],routingClient)[_0x2e92e4('0x3f')](findById(_0x496d8c[_0x2e92e4('0x74')]['id']))[_0x2e92e4('0x3f')](respondWithResult(_0x4839c9,null))[_0x2e92e4('0x1')](handleError(_0x4839c9,null));},exports[_0x4b6ac4('0x6e')]=function(_0x5c1153,_0x47b65d){const _0xbd0b12=_0x4b6ac4;return respondWithRpcPromise('FaxAccounts',_0x5c1153[_0xbd0b12('0x5a')])['then'](respondWithResult(_0x47b65d,null))[_0xbd0b12('0x1')](handleError(_0x47b65d,null));},exports[_0x4b6ac4('0x79')]=function(_0x1ba31c,_0x14b65c){const _0x4c0e5b=_0x4b6ac4;return respondWithRpcPromise(_0x4c0e5b('0x6f'),_0x1ba31c[_0x4c0e5b('0x5a')],routingClient)[_0x4c0e5b('0x3f')](respondWithResult(_0x14b65c,null))[_0x4c0e5b('0x1')](handleError(_0x14b65c,null));},exports['mailQueuesWaitingInteractions']=function(_0x17f07c,_0x296c97){const _0xeafab1=_0x4b6ac4;return respondWithRpcPromise(_0xeafab1('0x27'),_0x17f07c[_0xeafab1('0x5a')],routingClient)['then'](respondWithResult(_0x296c97,null))[_0xeafab1('0x1')](handleError(_0x296c97,null));},exports[_0x4b6ac4('0x5d')]=function(_0x1ddf80,_0x37e53c){const _0x4c86cd=_0x4b6ac4;return respondWithRpcPromise(_0x4c86cd('0x6b'),_0x1ddf80[_0x4c86cd('0x5a')],routingClient)[_0x4c86cd('0x3f')](respondWithResult(_0x37e53c,null))['catch'](handleError(_0x37e53c,null));},exports['openchannelQueuesIdWaitingInteractions']=function(_0x469fcb,_0x121dd0){const _0x978fbb=_0x4b6ac4;return respondWithRpcPromise(_0x978fbb('0x6b'),_0x469fcb[_0x978fbb('0x5a')],routingClient)['then'](function(_0x1b5bdd){const _0x91b5e0=_0x978fbb;if(_0x469fcb[_0x91b5e0('0x5a')][_0x91b5e0('0x4d')]!==undefined){const _0x1a2b4a=_(_0x1b5bdd[_0x91b5e0('0x64')])[_0x91b5e0('0x1f')]([_0x469fcb[_0x91b5e0('0x5a')]['type'],_0x469fcb['params']['id']])[_0x91b5e0('0x15')](_0x91b5e0('0x32'))[_0x91b5e0('0x6c')]()[_0x91b5e0('0x59')]();return _0x1b5bdd[_0x91b5e0('0x64')][_0x91b5e0('0x1f')](function(_0xef61ef){const _0x7178a9=_0x91b5e0;return _0x1a2b4a[_0x7178a9('0x72')](_0xef61ef[_0x7178a9('0x32')])>-0x1;});}else return _0x1b5bdd[_0x91b5e0('0x64')][_0x91b5e0('0x1f')](function(_0x1282a0){const _0x36a9d9=_0x91b5e0;return _0x1282a0[_0x36a9d9('0x32')]===parseInt(_0x469fcb[_0x36a9d9('0x74')]['id']);});})['then'](respondWithResult(_0x121dd0,null))[_0x978fbb('0x1')](handleError(_0x121dd0,null));},exports[_0x4b6ac4('0x30')]=function(_0x53a81c,_0x2eba5a){const _0x3df075=_0x4b6ac4;return respondWithRpcPromise('SmsQueuesWaitingInteractions',_0x53a81c[_0x3df075('0x5a')],routingClient)['then'](respondWithResult(_0x2eba5a,null))['catch'](handleError(_0x2eba5a,null));},exports['whatsappQueuesWaitingInteractions']=function(_0x1487ff,_0x1efe94){const _0xc2d309=_0x4b6ac4;return respondWithRpcPromise(_0xc2d309('0x67'),_0x1487ff['query'],routingClient)['then'](respondWithResult(_0x1efe94,null))[_0xc2d309('0x1')](handleError(_0x1efe94,null));},exports[_0x4b6ac4('0x49')]=function(_0xbc7b5,_0x1f0934){const _0x39bf98=_0x4b6ac4;return respondWithRpcPromise(_0x39bf98('0x63'),_0xbc7b5[_0x39bf98('0x5a')],routingClient)[_0x39bf98('0x3f')](respondWithResult(_0x1f0934,null))[_0x39bf98('0x1')](handleError(_0x1f0934,null));},exports[_0x4b6ac4('0x50')]=function(_0x4bc5fc){return function(_0x4d289a,_0x59b843){const _0x55c19a=a527_0xdb76;let _0x306537,_0x2195f5;const _0x5e5f0e=_[_0x55c19a('0x2c')](_0x4bc5fc),_0x3ae116=_0x4bc5fc===_0x55c19a('0x58')?_0x55c19a('0x1d'):_0x55c19a('0x3b');return db[_0x5e5f0e+_0x55c19a('0x33')][_0x55c19a('0x7')]({'raw':!![],'where':{'id':_0x4d289a[_0x55c19a('0x74')]['id']}})['then'](function(_0x4336eb){const _0x217d04=_0x55c19a;if(_[_0x217d04('0x6')](_0x4336eb))throw new Error(_0x5e5f0e+_0x217d04('0x68'));return _0x306537=_0x4336eb,db[_0x5e5f0e+_0x217d04('0x23')][_0x217d04('0x7')]({'where':{'id':_0x4d289a['body']['messageId']},'include':[{'model':db[_0x5e5f0e+_0x217d04('0x3c')],'as':'Interaction'},{'model':db[_0x5e5f0e+_0x3ae116],'as':_0x217d04('0x3b')}]});})[_0x55c19a('0x3f')](function(_0x376e05){const _0x2ea739=_0x55c19a;if(_[_0x2ea739('0x6')](_0x376e05))throw new Error(_0x5e5f0e+_0x2ea739('0x4a'));return _0x2195f5=_0x376e05,_0x376e05[_0x2ea739('0xa')]({'read':0x0,'readAt':null,'UserId':null});})[_0x55c19a('0x3f')](function(){const _0x2ec14a=_0x55c19a,_0x21b54a={'uniqueid':_0x4bc5fc+'.'+_0x2195f5['id']+'.'+_0x2195f5[_0x2ec14a('0x3c')]['id'],'FromUserId':_0x4d289a['user']['id'],'type':_0x2ec14a('0x45')};return _0x21b54a[_0x5e5f0e+_0x2ec14a('0x4f')]=_0x2195f5['id'],_0x21b54a[_0x5e5f0e+'InteractionId']=_0x2195f5[_0x2ec14a('0x3c')]['id'],_0x21b54a[_0x2ec14a('0x70')+_0x5e5f0e+_0x3ae116+'Id']=_0x2195f5['Account']['id'],_0x21b54a['To'+_0x5e5f0e+_0x2ec14a('0x35')]=_0x306537['id'],db[_0x5e5f0e+_0x2ec14a('0x16')][_0x2ec14a('0x1c')](_0x21b54a);})[_0x55c19a('0x3f')](function(){const _0x18bcf4=_0x55c19a;return respondWithRpcPromise('Start',{'channel':_0x4bc5fc,'interaction':_0x2195f5[_0x18bcf4('0x3c')],'message':_0x2195f5,'account':_0x2195f5[_0x18bcf4('0x3b')],'applications':[{'id':0x0,'priority':0x1,'app':_0x18bcf4('0x45'),'appdata':_0x306537[_0x18bcf4('0x42')]+','+(_0x2195f5[_0x18bcf4('0x3b')][_0x18bcf4('0x0')]||0x12c),'interval':_0x18bcf4('0x1a')}]},routingClient);})[_0x55c19a('0x3f')](respondWithResult(_0x59b843,null))[_0x55c19a('0x1')](handleError(_0x59b843,null));};},exports[_0x4b6ac4('0x78')]=function(_0x401e61,_0x1ed216){const _0x1b2038=_0x4b6ac4;let _0x4a05f4,_0x448307;if(_[_0x1b2038('0x6')](_0x401e61['body'][_0x1b2038('0x3e')]))throw new Error(_0x1b2038('0x4'));const _0x5d1c73=_0x401e61[_0x1b2038('0x54')][_0x1b2038('0x3e')],_0x3b9bb6=_[_0x1b2038('0x2c')](_0x5d1c73),_0x4916cf=_0x5d1c73===_0x1b2038('0x58')?_0x1b2038('0x1d'):'Account';return db[_0x1b2038('0x3')]['findOne']({'raw':!![],'where':{'id':_0x401e61[_0x1b2038('0x74')]['id'],'role':'agent'}})[_0x1b2038('0x3f')](function(_0x2b472b){const _0x1011a6=_0x1b2038;if(_['isNil'](_0x2b472b))throw new Error(_0x1011a6('0xf'));return _0x4a05f4=_0x2b472b,db[_0x3b9bb6+_0x1011a6('0x23')][_0x1011a6('0x7')]({'where':{'id':_0x401e61[_0x1011a6('0x54')][_0x1011a6('0x28')]},'include':[{'model':db[_0x3b9bb6+_0x1011a6('0x3c')],'as':_0x1011a6('0x3c')},{'model':db[_0x3b9bb6+_0x4916cf],'as':_0x1011a6('0x3b')}]});})[_0x1b2038('0x3f')](function(_0x3cec0e){const _0x515475=_0x1b2038;if(_['isNil'](_0x3cec0e))throw new Error(_0x3b9bb6+_0x515475('0x4a'));return _0x448307=_0x3cec0e,_0x3cec0e[_0x515475('0xa')]({'read':0x0,'readAt':null,'UserId':null});})[_0x1b2038('0x3f')](function(){const _0x2bf9f3=_0x1b2038,_0x483123={'uniqueid':_0x5d1c73+'.'+_0x448307['id']+'.'+_0x448307[_0x2bf9f3('0x3c')]['id'],'FromUserId':_0x401e61['user']['id'],'type':_0x2bf9f3('0x45'),'ToUserId':_0x4a05f4['id']};return _0x483123[_0x3b9bb6+_0x2bf9f3('0x4f')]=_0x448307['id'],_0x483123[_0x3b9bb6+_0x2bf9f3('0x18')]=_0x448307[_0x2bf9f3('0x3c')]['id'],_0x483123[_0x2bf9f3('0x70')+_0x3b9bb6+_0x4916cf+'Id']=_0x448307[_0x2bf9f3('0x3b')]['id'],db[_0x3b9bb6+_0x2bf9f3('0x16')][_0x2bf9f3('0x1c')](_0x483123);})['then'](function(){const _0x17bc1b=_0x1b2038;return respondWithRpcPromise(_0x17bc1b('0x25'),{'channel':_0x5d1c73,'interaction':_0x448307['Interaction'],'message':_0x448307,'account':_0x448307[_0x17bc1b('0x3b')],'applications':[{'id':0x0,'priority':0x1,'app':'agent','appdata':_0x4a05f4[_0x17bc1b('0x42')]+','+(_0x448307[_0x17bc1b('0x3b')][_0x17bc1b('0x2f')]||0x12c),'interval':_0x17bc1b('0x1a')}]},routingClient);})[_0x1b2038('0x3f')](respondWithResult(_0x1ed216,null))[_0x1b2038('0x1')](handleError(_0x1ed216,null));}; \ No newline at end of file diff --git a/server/api/schedule/index.js b/server/api/schedule/index.js index 12de998..8bb7b2b 100644 --- a/server/api/schedule/index.js +++ b/server/api/schedule/index.js @@ -1 +1 @@ -const a528_0x2c76=['get','isAuthenticated','create','/:id','./schedule.controller','put','show','delete','Router','express','exports','destroy','index','run','../../components/auth/service'];(function(_0xcc0cd4,_0x2c76f2){const _0x4d22d2=function(_0xaac450){while(--_0xaac450){_0xcc0cd4['push'](_0xcc0cd4['shift']());}};_0x4d22d2(++_0x2c76f2);}(a528_0x2c76,0x1d7));const a528_0x4d22=function(_0xcc0cd4,_0x2c76f2){_0xcc0cd4=_0xcc0cd4-0x0;let _0x4d22d2=a528_0x2c76[_0xcc0cd4];return _0x4d22d2;};const _0x4d8a3a=a528_0x4d22;'use strict';const express=require(_0x4d8a3a('0x3')),router=express[_0x4d8a3a('0x2')](),auth=require(_0x4d8a3a('0x8')),controller=require(_0x4d8a3a('0xd'));router['get']('/',auth[_0x4d8a3a('0xa')](),controller[_0x4d8a3a('0x6')]),router[_0x4d8a3a('0x9')](_0x4d8a3a('0xc'),auth[_0x4d8a3a('0xa')](),controller[_0x4d8a3a('0x0')]),router['get']('/:id/run',auth[_0x4d8a3a('0xa')](),controller[_0x4d8a3a('0x7')]),router['post']('/',auth[_0x4d8a3a('0xa')](),controller[_0x4d8a3a('0xb')]),router[_0x4d8a3a('0xe')]('/:id',auth[_0x4d8a3a('0xa')](),controller['update']),router[_0x4d8a3a('0x1')](_0x4d8a3a('0xc'),auth['isAuthenticated'](),controller[_0x4d8a3a('0x5')]),module[_0x4d8a3a('0x4')]=router; \ No newline at end of file +const a528_0x5e19=['put','index','/:id','/:id/run','get','isAuthenticated','../../components/auth/service','post','update','Router','express','exports','create','delete','destroy'];(function(_0x45d172,_0x5e1922){const _0x5cbcbe=function(_0x161198){while(--_0x161198){_0x45d172['push'](_0x45d172['shift']());}};_0x5cbcbe(++_0x5e1922);}(a528_0x5e19,0x11c));const a528_0x5cbc=function(_0x45d172,_0x5e1922){_0x45d172=_0x45d172-0x0;let _0x5cbcbe=a528_0x5e19[_0x45d172];return _0x5cbcbe;};const _0x1626a6=a528_0x5cbc;'use strict';const express=require(_0x1626a6('0xb')),router=express[_0x1626a6('0xa')](),auth=require(_0x1626a6('0x7')),controller=require('./schedule.controller');router[_0x1626a6('0x5')]('/',auth['isAuthenticated'](),controller[_0x1626a6('0x2')]),router[_0x1626a6('0x5')](_0x1626a6('0x3'),auth[_0x1626a6('0x6')](),controller['show']),router[_0x1626a6('0x5')](_0x1626a6('0x4'),auth[_0x1626a6('0x6')](),controller['run']),router[_0x1626a6('0x8')]('/',auth[_0x1626a6('0x6')](),controller[_0x1626a6('0xd')]),router[_0x1626a6('0x1')](_0x1626a6('0x3'),auth['isAuthenticated'](),controller[_0x1626a6('0x9')]),router[_0x1626a6('0xe')]('/:id',auth[_0x1626a6('0x6')](),controller[_0x1626a6('0x0')]),module[_0x1626a6('0xc')]=router; \ No newline at end of file diff --git a/server/api/schedule/schedule.attributes.js b/server/api/schedule/schedule.attributes.js index 8a07a37..05e6af4 100644 --- a/server/api/schedule/schedule.attributes.js +++ b/server/api/schedule/schedule.attributes.js @@ -1 +1 @@ -const a529_0x57f0=['DATE','pdf','years','xlsx','TEXT','custom','csv','exports','STRING','INTEGER','weeks','BOOLEAN','ENUM','hours','minutes','quarters','months','days'];(function(_0x227c9e,_0x57f098){const _0x2a2bdd=function(_0x57dad2){while(--_0x57dad2){_0x227c9e['push'](_0x227c9e['shift']());}};_0x2a2bdd(++_0x57f098);}(a529_0x57f0,0x1b1));const a529_0x2a2b=function(_0x227c9e,_0x57f098){_0x227c9e=_0x227c9e-0x0;let _0x2a2bdd=a529_0x57f0[_0x227c9e];return _0x2a2bdd;};const _0x1de3ba=a529_0x2a2b;'use strict';const Sequelize=require('sequelize');module[_0x1de3ba('0x6')]={'name':{'type':Sequelize['STRING'],'allowNull':![]},'description':{'type':Sequelize['STRING']},'active':{'type':Sequelize[_0x1de3ba('0xa')],'allowNull':![],'defaultValue':![]},'cron':{'type':Sequelize[_0x1de3ba('0x7')],'allowNull':![],'defaultValue':'0\x200\x20*\x20*\x20*'},'startAt':{'type':Sequelize[_0x1de3ba('0x11')],'allowNull':![]},'endAt':{'type':Sequelize[_0x1de3ba('0x11')],'allowNull':![]},'subtractNumber':{'type':Sequelize[_0x1de3ba('0x8')],'allowNull':![],'defaultValue':0x1,'validate':{'min':0x1}},'subtractUnit':{'type':Sequelize[_0x1de3ba('0xb')](_0x1de3ba('0x1'),_0x1de3ba('0xe'),_0x1de3ba('0xf'),_0x1de3ba('0x9'),_0x1de3ba('0x10'),_0x1de3ba('0xc'),_0x1de3ba('0xd')),'allowNull':![],'defaultValue':_0x1de3ba('0x10')},'output':{'type':Sequelize[_0x1de3ba('0xb')]('csv',_0x1de3ba('0x0'),_0x1de3ba('0x2')),'allowNull':![],'defaultValue':_0x1de3ba('0x5')},'type':{'type':Sequelize[_0x1de3ba('0xb')](_0x1de3ba('0x4'),'default'),'allowNull':![],'defaultValue':_0x1de3ba('0x4')},'sendMail':{'type':Sequelize[_0x1de3ba('0xa')],'defaultValue':![]},'email':{'type':Sequelize[_0x1de3ba('0x7')]},'cc':{'type':Sequelize[_0x1de3ba('0x3')]},'bcc':{'type':Sequelize[_0x1de3ba('0x3')]},'sendIfEmpty':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]}}; \ No newline at end of file +const a529_0x43f2=['hours','minutes','exports','ENUM','default','sequelize','weeks','DATE','STRING','custom','days','quarters','INTEGER','pdf','TEXT','BOOLEAN'];(function(_0x9bf40,_0x43f299){const _0x5f166f=function(_0x35dbe7){while(--_0x35dbe7){_0x9bf40['push'](_0x9bf40['shift']());}};_0x5f166f(++_0x43f299);}(a529_0x43f2,0x1ca));const a529_0x5f16=function(_0x9bf40,_0x43f299){_0x9bf40=_0x9bf40-0x0;let _0x5f166f=a529_0x43f2[_0x9bf40];return _0x5f166f;};const _0x4406ac=a529_0x5f16;'use strict';const Sequelize=require(_0x4406ac('0xb'));module[_0x4406ac('0x8')]={'name':{'type':Sequelize[_0x4406ac('0xe')],'allowNull':![]},'description':{'type':Sequelize[_0x4406ac('0xe')]},'active':{'type':Sequelize[_0x4406ac('0x5')],'allowNull':![],'defaultValue':![]},'cron':{'type':Sequelize[_0x4406ac('0xe')],'allowNull':![],'defaultValue':'0\x200\x20*\x20*\x20*'},'startAt':{'type':Sequelize[_0x4406ac('0xd')],'allowNull':![]},'endAt':{'type':Sequelize[_0x4406ac('0xd')],'allowNull':![]},'subtractNumber':{'type':Sequelize[_0x4406ac('0x2')],'allowNull':![],'defaultValue':0x1,'validate':{'min':0x1}},'subtractUnit':{'type':Sequelize[_0x4406ac('0x9')]('years',_0x4406ac('0x1'),'months',_0x4406ac('0xc'),'days',_0x4406ac('0x6'),_0x4406ac('0x7')),'allowNull':![],'defaultValue':_0x4406ac('0x0')},'output':{'type':Sequelize[_0x4406ac('0x9')]('csv',_0x4406ac('0x3'),'xlsx'),'allowNull':![],'defaultValue':'csv'},'type':{'type':Sequelize[_0x4406ac('0x9')]('custom',_0x4406ac('0xa')),'allowNull':![],'defaultValue':_0x4406ac('0xf')},'sendMail':{'type':Sequelize[_0x4406ac('0x5')],'defaultValue':![]},'email':{'type':Sequelize[_0x4406ac('0xe')]},'cc':{'type':Sequelize[_0x4406ac('0x4')]},'bcc':{'type':Sequelize[_0x4406ac('0x4')]},'sendIfEmpty':{'type':Sequelize[_0x4406ac('0x5')],'defaultValue':!![]}}; \ No newline at end of file diff --git a/server/api/schedule/schedule.controller.js b/server/api/schedule/schedule.controller.js index e620381..157b9ed 100644 --- a/server/api/schedule/schedule.controller.js +++ b/server/api/schedule/schedule.controller.js @@ -1 +1 @@ -const a530_0x4747=['model','attributes','length','UserProfileSection','Schedule','findOne','where','api','then','catch','json','end','fieldName','../../config/logger','UserProfileResource','destroy','create','limit','offset','VIRTUAL','params','role','sort','fields','user','show','order','get','filters','map','Content-Range','filter','intersection','update','lodash','../../config/schedule','includeAll','name','error','sequelize','sendStatus','../../mysqldb','include','rows','merge','query','rawAttributes','run','../../components/parsers/qs','like','type','set','send','body','keys','stack','options','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','pick','status','nolimit','count'];(function(_0x1a5bec,_0x474707){const _0x29016c=function(_0x5e0285){while(--_0x5e0285){_0x1a5bec['push'](_0x1a5bec['shift']());}};_0x29016c(++_0x474707);}(a530_0x4747,0x88));const a530_0x2901=function(_0x1a5bec,_0x474707){_0x1a5bec=_0x1a5bec-0x0;let _0x29016c=a530_0x4747[_0x1a5bec];return _0x29016c;};const _0x2f8c9a=a530_0x2901;'use strict';const _=require(_0x2f8c9a('0x16')),qs=require(_0x2f8c9a('0x24')),logger=require(_0x2f8c9a('0x1'))(_0x2f8c9a('0x39')),db=require(_0x2f8c9a('0x1d'))['db'],{Op}=require(_0x2f8c9a('0x1b'));function respondWithStatusCode(_0x5e0285,_0x2f641a){return _0x2f641a=_0x2f641a||0xcc,function(_0x136508){const _0x33e716=a530_0x2901;if(_0x136508)return _0x5e0285[_0x33e716('0x1c')](_0x2f641a);return _0x5e0285[_0x33e716('0x2f')](_0x2f641a)[_0x33e716('0x3d')]();};}function respondWithResult(_0x3a38d,_0x5e531b){return _0x5e531b=_0x5e531b||0xc8,function(_0x17cf70){const _0x18fc38=a530_0x2901;if(_0x17cf70)return _0x3a38d[_0x18fc38('0x2f')](_0x5e531b)['json'](_0x17cf70);};}function respondWithFilteredResult(_0xfbc3e5,_0x125306){return function(_0x27c6f3){const _0x9fd7c5=a530_0x2901;if(_0x27c6f3){const _0x1fc3d1=_0x27c6f3[_0x9fd7c5('0x31')],_0x445633=_0x125306[_0x9fd7c5('0x6')];let _0x8b1963=_0x125306[_0x9fd7c5('0x6')]+_0x125306['limit'],_0x23d12f;return _0x8b1963>=_0x1fc3d1?(_0x8b1963=_0x1fc3d1,_0x23d12f=0xc8):_0x23d12f=0xce,_0xfbc3e5[_0x9fd7c5('0x2f')](_0x23d12f),_0xfbc3e5[_0x9fd7c5('0x27')](_0x9fd7c5('0x12'),_0x445633+'-'+_0x8b1963+'/'+_0x1fc3d1)[_0x9fd7c5('0x3c')](_0x27c6f3);}return null;};}function saveUpdates(_0x51061d){return function(_0x286433){const _0x2c866a=a530_0x2901;if(_0x286433)return _0x286433[_0x2c866a('0x15')](_0x51061d)['then'](function(_0x5de048){return _0x5de048;});return null;};}function removeEntity(_0x4134d7){return function(_0x4c4959){const _0x217fe3=a530_0x2901;if(_0x4c4959)return _0x4c4959[_0x217fe3('0x3')]()[_0x217fe3('0x3a')](function(){const _0x15e276=_0x217fe3,_0x562fc3=_0x4c4959[_0x15e276('0xf')]({'plain':!![]}),_0x3a87ca='Scheduler';return db[_0x15e276('0x2')][_0x15e276('0x3')]({'where':{'type':_0x3a87ca,'resourceId':_0x562fc3['id']}})[_0x15e276('0x3a')](function(){return _0x4c4959;});})[_0x217fe3('0x3a')](function(){const _0x3894a3=_0x217fe3;_0x4134d7[_0x3894a3('0x2f')](0xcc)[_0x3894a3('0x3d')]();});};}function handleEntityNotFound(_0x15022f){return function(_0x407270){const _0x2f9da3=a530_0x2901;return!_0x407270&&_0x15022f[_0x2f9da3('0x1c')](0x194),_0x407270;};}function handleError(_0x2faff4,_0x4083e1){return _0x4083e1=_0x4083e1||0x1f4,function(_0xf00fe4){const _0xffc3ca=a530_0x2901;logger['error'](_0xf00fe4[_0xffc3ca('0x2b')]),_0xf00fe4[_0xffc3ca('0x19')]&&delete _0xf00fe4[_0xffc3ca('0x19')],_0x2faff4[_0xffc3ca('0x2f')](_0x4083e1)[_0xffc3ca('0x28')](_0xf00fe4);};}exports['index']=function(_0x335c90,_0x56c266){const _0x3d7deb=_0x2f8c9a;let _0x21710b={};const _0x294c6b={},_0x52d0e9={'count':0x0,'rows':[]},_0x442888=_[_0x3d7deb('0x11')](db['Schedule'][_0x3d7deb('0x22')],function(_0x47c799){const _0x1273a8=_0x3d7deb;return{'name':_0x47c799[_0x1273a8('0x0')],'type':_0x47c799[_0x1273a8('0x26')]['key']};});_0x294c6b[_0x3d7deb('0x32')]=_['map'](_0x442888,_0x3d7deb('0x19')),_0x294c6b['query']=_[_0x3d7deb('0x2a')](_0x335c90[_0x3d7deb('0x21')]),_0x294c6b[_0x3d7deb('0x10')]=_[_0x3d7deb('0x14')](_0x294c6b['model'],_0x294c6b[_0x3d7deb('0x21')]),_0x21710b['attributes']=_[_0x3d7deb('0x14')](_0x294c6b[_0x3d7deb('0x32')],qs[_0x3d7deb('0xb')](_0x335c90[_0x3d7deb('0x21')]['fields'])),_0x21710b[_0x3d7deb('0x33')]=_0x21710b[_0x3d7deb('0x33')][_0x3d7deb('0x34')]?_0x21710b[_0x3d7deb('0x33')]:_0x294c6b[_0x3d7deb('0x32')];typeof _0x335c90[_0x3d7deb('0x21')][_0x3d7deb('0x30')]==='undefined'&&(_0x21710b[_0x3d7deb('0x5')]=qs['limit'](_0x335c90['query']['limit']),_0x21710b[_0x3d7deb('0x6')]=qs['offset'](_0x335c90[_0x3d7deb('0x21')]['offset']));_0x21710b[_0x3d7deb('0xe')]=qs[_0x3d7deb('0xa')](_0x335c90['query'][_0x3d7deb('0xa')]),_0x21710b[_0x3d7deb('0x38')]=qs[_0x3d7deb('0x10')](_[_0x3d7deb('0x2e')](_0x335c90[_0x3d7deb('0x21')],_0x294c6b[_0x3d7deb('0x10')]),_0x442888);_0x335c90[_0x3d7deb('0x21')][_0x3d7deb('0x13')]&&(_0x21710b[_0x3d7deb('0x38')]=_[_0x3d7deb('0x20')](_0x21710b[_0x3d7deb('0x38')],{[Op['or']]:_['map'](_0x442888,function(_0x54e74b){const _0x2ca18a=_0x3d7deb;if(_0x54e74b[_0x2ca18a('0x26')]!==_0x2ca18a('0x7')){const _0x37c522={};return _0x37c522[_0x54e74b[_0x2ca18a('0x19')]]={[Op[_0x2ca18a('0x25')]]:'%'+_0x335c90['query'][_0x2ca18a('0x13')]+'%'},_0x37c522;}})}));_0x21710b=_[_0x3d7deb('0x20')]({},_0x21710b,_0x335c90[_0x3d7deb('0x2c')]);const _0x2b06f5={'where':_0x21710b[_0x3d7deb('0x38')]};return db['Schedule'][_0x3d7deb('0x31')](_0x2b06f5)['then'](function(_0x3a09be){const _0x3313ed=_0x3d7deb;return _0x52d0e9[_0x3313ed('0x31')]=_0x3a09be,_0x335c90['query'][_0x3313ed('0x18')]&&(_0x21710b['include']=[{'all':!![]}]),db[_0x3313ed('0x36')]['findAll'](_0x21710b);})[_0x3d7deb('0x3a')](function(_0x16a814){const _0x391f67=_0x3d7deb;return _0x52d0e9[_0x391f67('0x1f')]=_0x16a814,_0x52d0e9;})['then'](respondWithFilteredResult(_0x56c266,_0x21710b))['catch'](handleError(_0x56c266,null));},exports[_0x2f8c9a('0xd')]=function(_0x1339f8,_0x438c1b){const _0x3754f7=_0x2f8c9a;let _0x558b06={'raw':![],'where':{'id':_0x1339f8[_0x3754f7('0x8')]['id']}};const _0x580228={};return _0x580228[_0x3754f7('0x32')]=_[_0x3754f7('0x2a')](db[_0x3754f7('0x36')][_0x3754f7('0x22')]),_0x580228[_0x3754f7('0x21')]=_['keys'](_0x1339f8[_0x3754f7('0x21')]),_0x580228[_0x3754f7('0x10')]=_[_0x3754f7('0x14')](_0x580228[_0x3754f7('0x32')],_0x580228[_0x3754f7('0x21')]),_0x558b06[_0x3754f7('0x33')]=_[_0x3754f7('0x14')](_0x580228[_0x3754f7('0x32')],qs['fields'](_0x1339f8[_0x3754f7('0x21')][_0x3754f7('0xb')])),_0x558b06[_0x3754f7('0x33')]=_0x558b06[_0x3754f7('0x33')][_0x3754f7('0x34')]?_0x558b06['attributes']:_0x580228[_0x3754f7('0x32')],_0x1339f8[_0x3754f7('0x21')][_0x3754f7('0x18')]&&(_0x558b06[_0x3754f7('0x1e')]=[{'all':!![]}]),_0x558b06=_[_0x3754f7('0x20')]({},_0x558b06,_0x1339f8[_0x3754f7('0x2c')]),db[_0x3754f7('0x36')][_0x3754f7('0x37')](_0x558b06)['then'](handleEntityNotFound(_0x438c1b,null))[_0x3754f7('0x3a')](respondWithResult(_0x438c1b,null))[_0x3754f7('0x3b')](handleError(_0x438c1b,null));},exports[_0x2f8c9a('0x4')]=function(_0x18f707,_0x4d156f){const _0x1ab4c0=_0x2f8c9a;return db['Schedule'][_0x1ab4c0('0x4')](_0x18f707[_0x1ab4c0('0x29')],{})[_0x1ab4c0('0x3a')](function(_0x1baee3){const _0x59acfa=_0x1ab4c0,_0x3b42f9=_0x18f707[_0x59acfa('0xc')][_0x59acfa('0xf')]({'plain':!![]});if(!_0x3b42f9)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x3b42f9[_0x59acfa('0x9')]===_0x59acfa('0xc')){const _0x592a5e=_0x1baee3[_0x59acfa('0xf')]({'plain':!![]}),_0x5ae9e3='Scheduler';return db[_0x59acfa('0x35')]['findOne']({'where':{'name':_0x5ae9e3,'userProfileId':_0x3b42f9['userProfileId']},'raw':!![]})[_0x59acfa('0x3a')](function(_0x2f8c2b){const _0x2ccd57=_0x59acfa;return _0x2f8c2b&&_0x2f8c2b['autoAssociation']===0x0?db['UserProfileResource'][_0x2ccd57('0x4')]({'name':_0x592a5e[_0x2ccd57('0x19')],'resourceId':_0x592a5e['id'],'type':_0x2f8c2b[_0x2ccd57('0x19')],'sectionId':_0x2f8c2b['id']},{})[_0x2ccd57('0x3a')](function(){return _0x1baee3;}):_0x1baee3;})[_0x59acfa('0x3b')](function(_0x2275d7){const _0x25408b=_0x59acfa;logger[_0x25408b('0x1a')](_0x25408b('0x2d'),_0x2275d7);throw _0x2275d7;});}return _0x1baee3;})['then'](respondWithResult(_0x4d156f,0xc9))[_0x1ab4c0('0x3b')](handleError(_0x4d156f,null));},exports['update']=function(_0x57faed,_0x4d6883){const _0x348487=_0x2f8c9a;return _0x57faed[_0x348487('0x29')]['id']&&delete _0x57faed['body']['id'],db[_0x348487('0x36')][_0x348487('0x37')]({'where':{'id':_0x57faed[_0x348487('0x8')]['id']}})['then'](handleEntityNotFound(_0x4d6883,null))[_0x348487('0x3a')](saveUpdates(_0x57faed[_0x348487('0x29')],null))[_0x348487('0x3a')](respondWithResult(_0x4d6883,null))['catch'](handleError(_0x4d6883,null));},exports['destroy']=function(_0x283729,_0x57983f){const _0xd5b23d=_0x2f8c9a;return db[_0xd5b23d('0x36')][_0xd5b23d('0x37')]({'where':{'id':_0x283729[_0xd5b23d('0x8')]['id']}})['then'](handleEntityNotFound(_0x57983f,null))[_0xd5b23d('0x3a')](removeEntity(_0x57983f,null))['catch'](handleError(_0x57983f,null));},exports['run']=function(_0x3f3eca,_0x46e5d5){const _0x12a4c8=_0x2f8c9a,_0x5013dd=require(_0x12a4c8('0x17'));return db[_0x12a4c8('0x36')][_0x12a4c8('0x37')]({'where':{'id':_0x3f3eca['params']['id']},'raw':!![]})[_0x12a4c8('0x3a')](handleEntityNotFound(_0x46e5d5,null))[_0x12a4c8('0x3a')](function(){const _0x34cee5=_0x12a4c8;_0x5013dd[_0x34cee5('0x23')](_0x3f3eca[_0x34cee5('0x8')]['id']);})[_0x12a4c8('0x3a')](respondWithStatusCode(_0x46e5d5,null))[_0x12a4c8('0x3b')](handleError(_0x46e5d5,null));}; \ No newline at end of file +const a530_0x5950=['like','userProfileId','catch','../../mysqldb','params','attributes','role','Scheduler','Unable\x20to\x20retrieve\x20the\x20current\x20user','../../components/parsers/qs','update','merge','where','options','stack','keys','UserProfileSection','type','filters','create','fieldName','query','Schedule','count','UserProfileResource','rawAttributes','VIRTUAL','body','name','sendStatus','end','limit','includeAll','fields','key','filter','run','show','order','get','autoAssociation','findOne','json','destroy','nolimit','model','include','index','sequelize','api','../../config/schedule','status','user','error','Content-Range','intersection','length','map','then','lodash','../../config/logger','offset','rows','sort','pick','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s'];(function(_0x50b73f,_0x5950b2){const _0x5a02f5=function(_0x1ce5e7){while(--_0x1ce5e7){_0x50b73f['push'](_0x50b73f['shift']());}};_0x5a02f5(++_0x5950b2);}(a530_0x5950,0x157));const a530_0x5a02=function(_0x50b73f,_0x5950b2){_0x50b73f=_0x50b73f-0x0;let _0x5a02f5=a530_0x5950[_0x50b73f];return _0x5a02f5;};const _0x50b947=a530_0x5a02;'use strict';const _=require(_0x50b947('0x2e')),qs=require(_0x50b947('0x3e')),logger=require(_0x50b947('0x2f'))(_0x50b947('0x24')),db=require(_0x50b947('0x38'))['db'],{Op}=require(_0x50b947('0x23'));function respondWithStatusCode(_0x1ce5e7,_0x473c38){return _0x473c38=_0x473c38||0xcc,function(_0x274bba){const _0x2c6f0d=a530_0x5a02;if(_0x274bba)return _0x1ce5e7[_0x2c6f0d('0x10')](_0x473c38);return _0x1ce5e7[_0x2c6f0d('0x26')](_0x473c38)[_0x2c6f0d('0x11')]();};}function respondWithResult(_0x43d8ea,_0x266180){return _0x266180=_0x266180||0xc8,function(_0x3ba2ed){const _0xd3ca87=a530_0x5a02;if(_0x3ba2ed)return _0x43d8ea[_0xd3ca87('0x26')](_0x266180)[_0xd3ca87('0x1d')](_0x3ba2ed);};}function respondWithFilteredResult(_0x7c47f6,_0x4fe98e){return function(_0x688e15){const _0x55a118=a530_0x5a02;if(_0x688e15){const _0x4aa9d4=_0x688e15[_0x55a118('0xa')],_0x5a9598=_0x4fe98e['offset'];let _0x3f7bda=_0x4fe98e[_0x55a118('0x30')]+_0x4fe98e[_0x55a118('0x12')],_0x3341f4;return _0x3f7bda>=_0x4aa9d4?(_0x3f7bda=_0x4aa9d4,_0x3341f4=0xc8):_0x3341f4=0xce,_0x7c47f6[_0x55a118('0x26')](_0x3341f4),_0x7c47f6['set'](_0x55a118('0x29'),_0x5a9598+'-'+_0x3f7bda+'/'+_0x4aa9d4)[_0x55a118('0x1d')](_0x688e15);}return null;};}function saveUpdates(_0x432228){return function(_0x359318){const _0x5ef8bc=a530_0x5a02;if(_0x359318)return _0x359318[_0x5ef8bc('0x3f')](_0x432228)[_0x5ef8bc('0x2d')](function(_0x28d067){return _0x28d067;});return null;};}function removeEntity(_0x42443e){return function(_0x77d708){const _0xd19a5=a530_0x5a02;if(_0x77d708)return _0x77d708['destroy']()[_0xd19a5('0x2d')](function(){const _0x9b6f81=_0xd19a5,_0xde7412=_0x77d708[_0x9b6f81('0x1a')]({'plain':!![]}),_0x38fa32=_0x9b6f81('0x3c');return db[_0x9b6f81('0xb')][_0x9b6f81('0x1e')]({'where':{'type':_0x38fa32,'resourceId':_0xde7412['id']}})[_0x9b6f81('0x2d')](function(){return _0x77d708;});})[_0xd19a5('0x2d')](function(){const _0x1838ac=_0xd19a5;_0x42443e[_0x1838ac('0x26')](0xcc)['end']();});};}function handleEntityNotFound(_0x510770){return function(_0x35ffe7){const _0x2f58e6=a530_0x5a02;return!_0x35ffe7&&_0x510770[_0x2f58e6('0x10')](0x194),_0x35ffe7;};}function handleError(_0x511281,_0x81f02){return _0x81f02=_0x81f02||0x1f4,function(_0x415d88){const _0x544393=a530_0x5a02;logger[_0x544393('0x28')](_0x415d88[_0x544393('0x1')]),_0x415d88[_0x544393('0xf')]&&delete _0x415d88[_0x544393('0xf')],_0x511281[_0x544393('0x26')](_0x81f02)['send'](_0x415d88);};}exports[_0x50b947('0x22')]=function(_0x1779ea,_0x2c5fbe){const _0x148a90=_0x50b947;let _0x5a361f={};const _0xe46b92={},_0x40607d={'count':0x0,'rows':[]},_0x27d473=_[_0x148a90('0x2c')](db[_0x148a90('0x9')][_0x148a90('0xc')],function(_0x26949c){const _0x59423d=_0x148a90;return{'name':_0x26949c[_0x59423d('0x7')],'type':_0x26949c[_0x59423d('0x4')][_0x59423d('0x15')]};});_0xe46b92[_0x148a90('0x20')]=_[_0x148a90('0x2c')](_0x27d473,_0x148a90('0xf')),_0xe46b92[_0x148a90('0x8')]=_[_0x148a90('0x2')](_0x1779ea[_0x148a90('0x8')]),_0xe46b92['filters']=_[_0x148a90('0x2a')](_0xe46b92[_0x148a90('0x20')],_0xe46b92['query']),_0x5a361f[_0x148a90('0x3a')]=_['intersection'](_0xe46b92['model'],qs[_0x148a90('0x14')](_0x1779ea[_0x148a90('0x8')][_0x148a90('0x14')])),_0x5a361f[_0x148a90('0x3a')]=_0x5a361f[_0x148a90('0x3a')][_0x148a90('0x2b')]?_0x5a361f['attributes']:_0xe46b92[_0x148a90('0x20')];typeof _0x1779ea[_0x148a90('0x8')][_0x148a90('0x1f')]==='undefined'&&(_0x5a361f['limit']=qs[_0x148a90('0x12')](_0x1779ea[_0x148a90('0x8')][_0x148a90('0x12')]),_0x5a361f['offset']=qs[_0x148a90('0x30')](_0x1779ea[_0x148a90('0x8')]['offset']));_0x5a361f[_0x148a90('0x19')]=qs['sort'](_0x1779ea['query'][_0x148a90('0x32')]),_0x5a361f['where']=qs[_0x148a90('0x5')](_[_0x148a90('0x33')](_0x1779ea[_0x148a90('0x8')],_0xe46b92[_0x148a90('0x5')]),_0x27d473);_0x1779ea['query'][_0x148a90('0x16')]&&(_0x5a361f[_0x148a90('0x41')]=_[_0x148a90('0x40')](_0x5a361f[_0x148a90('0x41')],{[Op['or']]:_[_0x148a90('0x2c')](_0x27d473,function(_0x5ae27e){const _0x408a87=_0x148a90;if(_0x5ae27e[_0x408a87('0x4')]!==_0x408a87('0xd')){const _0x24df24={};return _0x24df24[_0x5ae27e[_0x408a87('0xf')]]={[Op[_0x408a87('0x35')]]:'%'+_0x1779ea['query'][_0x408a87('0x16')]+'%'},_0x24df24;}})}));_0x5a361f=_['merge']({},_0x5a361f,_0x1779ea['options']);const _0x54aed7={'where':_0x5a361f[_0x148a90('0x41')]};return db['Schedule'][_0x148a90('0xa')](_0x54aed7)[_0x148a90('0x2d')](function(_0xd812a2){const _0x33ce6d=_0x148a90;return _0x40607d[_0x33ce6d('0xa')]=_0xd812a2,_0x1779ea[_0x33ce6d('0x8')]['includeAll']&&(_0x5a361f[_0x33ce6d('0x21')]=[{'all':!![]}]),db[_0x33ce6d('0x9')]['findAll'](_0x5a361f);})['then'](function(_0x46e8fb){const _0x2f1a40=_0x148a90;return _0x40607d[_0x2f1a40('0x31')]=_0x46e8fb,_0x40607d;})[_0x148a90('0x2d')](respondWithFilteredResult(_0x2c5fbe,_0x5a361f))[_0x148a90('0x37')](handleError(_0x2c5fbe,null));},exports[_0x50b947('0x18')]=function(_0x8f4ec9,_0x9a8701){const _0x2e0b12=_0x50b947;let _0x5312c0={'raw':![],'where':{'id':_0x8f4ec9['params']['id']}};const _0x54854e={};return _0x54854e[_0x2e0b12('0x20')]=_[_0x2e0b12('0x2')](db['Schedule'][_0x2e0b12('0xc')]),_0x54854e[_0x2e0b12('0x8')]=_[_0x2e0b12('0x2')](_0x8f4ec9[_0x2e0b12('0x8')]),_0x54854e['filters']=_[_0x2e0b12('0x2a')](_0x54854e[_0x2e0b12('0x20')],_0x54854e[_0x2e0b12('0x8')]),_0x5312c0[_0x2e0b12('0x3a')]=_[_0x2e0b12('0x2a')](_0x54854e[_0x2e0b12('0x20')],qs[_0x2e0b12('0x14')](_0x8f4ec9[_0x2e0b12('0x8')][_0x2e0b12('0x14')])),_0x5312c0[_0x2e0b12('0x3a')]=_0x5312c0['attributes'][_0x2e0b12('0x2b')]?_0x5312c0[_0x2e0b12('0x3a')]:_0x54854e[_0x2e0b12('0x20')],_0x8f4ec9[_0x2e0b12('0x8')][_0x2e0b12('0x13')]&&(_0x5312c0[_0x2e0b12('0x21')]=[{'all':!![]}]),_0x5312c0=_[_0x2e0b12('0x40')]({},_0x5312c0,_0x8f4ec9[_0x2e0b12('0x0')]),db['Schedule']['findOne'](_0x5312c0)[_0x2e0b12('0x2d')](handleEntityNotFound(_0x9a8701,null))[_0x2e0b12('0x2d')](respondWithResult(_0x9a8701,null))[_0x2e0b12('0x37')](handleError(_0x9a8701,null));},exports[_0x50b947('0x6')]=function(_0x417e68,_0x485f77){const _0x5459df=_0x50b947;return db[_0x5459df('0x9')][_0x5459df('0x6')](_0x417e68['body'],{})[_0x5459df('0x2d')](function(_0xbb4ab7){const _0x2bd161=_0x5459df,_0x4adc8c=_0x417e68['user'][_0x2bd161('0x1a')]({'plain':!![]});if(!_0x4adc8c)throw new Error(_0x2bd161('0x3d'));if(_0x4adc8c[_0x2bd161('0x3b')]===_0x2bd161('0x27')){const _0x21e0c4=_0xbb4ab7[_0x2bd161('0x1a')]({'plain':!![]}),_0xf34ee1=_0x2bd161('0x3c');return db[_0x2bd161('0x3')][_0x2bd161('0x1c')]({'where':{'name':_0xf34ee1,'userProfileId':_0x4adc8c[_0x2bd161('0x36')]},'raw':!![]})[_0x2bd161('0x2d')](function(_0x2bf230){const _0x562eaa=_0x2bd161;return _0x2bf230&&_0x2bf230[_0x562eaa('0x1b')]===0x0?db[_0x562eaa('0xb')][_0x562eaa('0x6')]({'name':_0x21e0c4[_0x562eaa('0xf')],'resourceId':_0x21e0c4['id'],'type':_0x2bf230[_0x562eaa('0xf')],'sectionId':_0x2bf230['id']},{})['then'](function(){return _0xbb4ab7;}):_0xbb4ab7;})['catch'](function(_0x28f5db){const _0x364a8b=_0x2bd161;logger[_0x364a8b('0x28')](_0x364a8b('0x34'),_0x28f5db);throw _0x28f5db;});}return _0xbb4ab7;})['then'](respondWithResult(_0x485f77,0xc9))[_0x5459df('0x37')](handleError(_0x485f77,null));},exports[_0x50b947('0x3f')]=function(_0x1b38e3,_0x56516b){const _0x17034d=_0x50b947;return _0x1b38e3[_0x17034d('0xe')]['id']&&delete _0x1b38e3['body']['id'],db[_0x17034d('0x9')]['findOne']({'where':{'id':_0x1b38e3[_0x17034d('0x39')]['id']}})['then'](handleEntityNotFound(_0x56516b,null))[_0x17034d('0x2d')](saveUpdates(_0x1b38e3[_0x17034d('0xe')],null))['then'](respondWithResult(_0x56516b,null))[_0x17034d('0x37')](handleError(_0x56516b,null));},exports[_0x50b947('0x1e')]=function(_0x50124e,_0xfcbc19){const _0x3abad5=_0x50b947;return db[_0x3abad5('0x9')][_0x3abad5('0x1c')]({'where':{'id':_0x50124e[_0x3abad5('0x39')]['id']}})[_0x3abad5('0x2d')](handleEntityNotFound(_0xfcbc19,null))[_0x3abad5('0x2d')](removeEntity(_0xfcbc19,null))['catch'](handleError(_0xfcbc19,null));},exports[_0x50b947('0x17')]=function(_0x802c37,_0x232fcb){const _0x114231=_0x50b947,_0x34992d=require(_0x114231('0x25'));return db[_0x114231('0x9')][_0x114231('0x1c')]({'where':{'id':_0x802c37[_0x114231('0x39')]['id']},'raw':!![]})[_0x114231('0x2d')](handleEntityNotFound(_0x232fcb,null))[_0x114231('0x2d')](function(){const _0x33092d=_0x114231;_0x34992d[_0x33092d('0x17')](_0x802c37[_0x33092d('0x39')]['id']);})[_0x114231('0x2d')](respondWithStatusCode(_0x232fcb,null))[_0x114231('0x37')](handleError(_0x232fcb,null));}; \ No newline at end of file diff --git a/server/api/schedule/schedule.model.js b/server/api/schedule/schedule.model.js index bad2484..c5d9184 100644 --- a/server/api/schedule/schedule.model.js +++ b/server/api/schedule/schedule.model.js @@ -1 +1 @@ -const a531_0x28e6=['tools_schedules','./schedule.attributes','exports'];(function(_0x451585,_0x28e637){const _0x465d5b=function(_0x1d1b41){while(--_0x1d1b41){_0x451585['push'](_0x451585['shift']());}};_0x465d5b(++_0x28e637);}(a531_0x28e6,0x157));const a531_0x465d=function(_0x451585,_0x28e637){_0x451585=_0x451585-0x0;let _0x465d5b=a531_0x28e6[_0x451585];return _0x465d5b;};const _0x31064f=a531_0x465d;'use strict';const attributes=require(_0x31064f('0x0'));module[_0x31064f('0x1')]=function(_0x1d1b41){const _0x144717=_0x31064f,_0x20004b=_0x1d1b41['define']('Schedule',attributes,{'tableName':_0x144717('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x20004b;}; \ No newline at end of file +const a531_0xa0fb=['Schedule','tools_schedules'];(function(_0x3ad37b,_0xa0fb93){const _0x586a05=function(_0x3fdd61){while(--_0x3fdd61){_0x3ad37b['push'](_0x3ad37b['shift']());}};_0x586a05(++_0xa0fb93);}(a531_0xa0fb,0x79));const a531_0x586a=function(_0x3ad37b,_0xa0fb93){_0x3ad37b=_0x3ad37b-0x0;let _0x586a05=a531_0xa0fb[_0x3ad37b];return _0x586a05;};'use strict';const attributes=require('./schedule.attributes');module['exports']=function(_0x3fdd61){const _0x941c77=a531_0x586a,_0x667acb=_0x3fdd61['define'](_0x941c77('0x1'),attributes,{'tableName':_0x941c77('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x667acb;}; \ No newline at end of file diff --git a/server/api/screenRecording/index.js b/server/api/screenRecording/index.js index 97b9370..6df050b 100644 --- a/server/api/screenRecording/index.js +++ b/server/api/screenRecording/index.js @@ -1 +1 @@ -const a532_0xc54c=['express','destroy','describe','index','update','get','./screenRecording.controller','Router','/describe','put','post','/:id','/:id/download','download','../../components/auth/service','show','isAuthenticated'];(function(_0x19778b,_0xc54cee){const _0x1285f8=function(_0x1da701){while(--_0x1da701){_0x19778b['push'](_0x19778b['shift']());}};_0x1285f8(++_0xc54cee);}(a532_0xc54c,0xae));const a532_0x1285=function(_0x19778b,_0xc54cee){_0x19778b=_0x19778b-0x0;let _0x1285f8=a532_0xc54c[_0x19778b];return _0x1285f8;};const _0x49760e=a532_0x1285;'use strict';const express=require(_0x49760e('0xd')),router=express[_0x49760e('0x3')](),auth=require(_0x49760e('0xa')),controller=require(_0x49760e('0x2'));router[_0x49760e('0x1')]('/',auth['isAuthenticated'](),controller[_0x49760e('0x10')]),router['get'](_0x49760e('0x4'),auth[_0x49760e('0xc')](),controller[_0x49760e('0xf')]),router[_0x49760e('0x1')](_0x49760e('0x7'),auth['isAuthenticated'](),controller[_0x49760e('0xb')]),router[_0x49760e('0x1')](_0x49760e('0x8'),auth['isAuthenticated'](),controller[_0x49760e('0x9')]),router[_0x49760e('0x6')]('/',auth[_0x49760e('0xc')](),controller['create']),router[_0x49760e('0x5')]('/:id',auth['isAuthenticated'](),controller[_0x49760e('0x0')]),router['delete'](_0x49760e('0x7'),auth['isAuthenticated'](),controller[_0x49760e('0xe')]),module['exports']=router; \ No newline at end of file +const a532_0x5985=['exports','create','destroy','isAuthenticated','get','/:id','post','show','/:id/download','download','./screenRecording.controller','express','Router','index','/describe','put'];(function(_0xa94bfb,_0x59854e){const _0x18761b=function(_0x46ed72){while(--_0x46ed72){_0xa94bfb['push'](_0xa94bfb['shift']());}};_0x18761b(++_0x59854e);}(a532_0x5985,0x166));const a532_0x1876=function(_0xa94bfb,_0x59854e){_0xa94bfb=_0xa94bfb-0x0;let _0x18761b=a532_0x5985[_0xa94bfb];return _0x18761b;};const _0x2c3567=a532_0x1876;'use strict';const express=require(_0x2c3567('0x5')),router=express[_0x2c3567('0x6')](),auth=require('../../components/auth/service'),controller=require(_0x2c3567('0x4'));router[_0x2c3567('0xe')]('/',auth['isAuthenticated'](),controller[_0x2c3567('0x7')]),router['get'](_0x2c3567('0x8'),auth['isAuthenticated'](),controller['describe']),router[_0x2c3567('0xe')](_0x2c3567('0xf'),auth['isAuthenticated'](),controller[_0x2c3567('0x1')]),router[_0x2c3567('0xe')](_0x2c3567('0x2'),auth[_0x2c3567('0xd')](),controller[_0x2c3567('0x3')]),router[_0x2c3567('0x0')]('/',auth['isAuthenticated'](),controller[_0x2c3567('0xb')]),router[_0x2c3567('0x9')](_0x2c3567('0xf'),auth['isAuthenticated'](),controller['update']),router['delete'](_0x2c3567('0xf'),auth[_0x2c3567('0xd')](),controller[_0x2c3567('0xc')]),module[_0x2c3567('0xa')]=router; \ No newline at end of file diff --git a/server/api/screenRecording/screenRecording.attributes.js b/server/api/screenRecording/screenRecording.attributes.js index d0057c1..688d1f3 100644 --- a/server/api/screenRecording/screenRecording.attributes.js +++ b/server/api/screenRecording/screenRecording.attributes.js @@ -1 +1 @@ -const a533_0x361e=['STRING','value','replace','exports','sequelize','closedAt','path','moment','DATE','MM-DD-YYYY\x20HH:mm','INTEGER','setDataValue','createdAt','getDataValue','format','subtract','toString','VIRTUAL'];(function(_0x29d5dc,_0x361e55){const _0x162350=function(_0x3f522d){while(--_0x3f522d){_0x29d5dc['push'](_0x29d5dc['shift']());}};_0x162350(++_0x361e55);}(a533_0x361e,0xb4));const a533_0x1623=function(_0x29d5dc,_0x361e55){_0x29d5dc=_0x29d5dc-0x0;let _0x162350=a533_0x361e[_0x29d5dc];return _0x162350;};const _0x1573d8=a533_0x1623;'use strict';const Sequelize=require(_0x1573d8('0x4')),moment=require(_0x1573d8('0x7')),path=require(_0x1573d8('0x6'));module[_0x1573d8('0x3')]={'format':{'type':Sequelize[_0x1573d8('0x11')],'get':function(){const _0x32fb7e=_0x1573d8;return this[_0x32fb7e('0xd')](_0x32fb7e('0x1'))?path['extname'](this[_0x32fb7e('0xd')](_0x32fb7e('0x1'))):undefined;}},'interactionid':{'type':Sequelize[_0x1573d8('0x0')]},'channel':{'type':Sequelize[_0x1573d8('0x0')]},'value':{'type':Sequelize[_0x1573d8('0x0')],'set':function(_0x3f522d){const _0x30590d=_0x1573d8,_0x1cd765=_0x3f522d[_0x30590d('0x2')](/\\/g,'/');this[_0x30590d('0xb')]('value',_0x1cd765);}},'rating':{'type':Sequelize[_0x1573d8('0xa')],'validate':{'max':0x5,'min':0x0}},'duration':{'type':Sequelize[_0x1573d8('0xa')],'set':function(_0x2b4c87){const _0x2bd60d=_0x1573d8;this[_0x2bd60d('0xb')]('startedAt',moment()[_0x2bd60d('0xf')](_0x2b4c87,'ms')),this[_0x2bd60d('0xb')](_0x2bd60d('0x5'),moment()),this[_0x2bd60d('0xb')]('duration',_0x2b4c87);}},'startedAt':{'type':Sequelize[_0x1573d8('0x8')],'get':function(){const _0x531cee=_0x1573d8;return moment(this['getDataValue']('startedAt'))['format'](_0x531cee('0x9'))[_0x531cee('0x10')]();}},'closedAt':{'type':Sequelize['DATE'],'get':function(){const _0x118df9=_0x1573d8;return moment(this[_0x118df9('0xd')](_0x118df9('0x5')))[_0x118df9('0xe')](_0x118df9('0x9'))[_0x118df9('0x10')]();}},'createdAt':{'type':Sequelize['DATE'],'get':function(){const _0x261b51=_0x1573d8;return moment(this[_0x261b51('0xd')](_0x261b51('0xc')))[_0x261b51('0xe')](_0x261b51('0x9'))[_0x261b51('0x10')]();}},'updatedAt':{'type':Sequelize[_0x1573d8('0x8')],'get':function(){const _0x420cbf=_0x1573d8;return moment(this[_0x420cbf('0xd')]('updatedAt'))[_0x420cbf('0xe')](_0x420cbf('0x9'))[_0x420cbf('0x10')]();}}}; \ No newline at end of file +const a533_0x542d=['createdAt','extname','exports','sequelize','MM-DD-YYYY\x20HH:mm','INTEGER','startedAt','closedAt','replace','STRING','getDataValue','path','setDataValue','format','toString','updatedAt','duration','DATE','subtract','VIRTUAL','value'];(function(_0x11e3fe,_0x542de8){const _0x1215e6=function(_0xbec884){while(--_0xbec884){_0x11e3fe['push'](_0x11e3fe['shift']());}};_0x1215e6(++_0x542de8);}(a533_0x542d,0x1af));const a533_0x1215=function(_0x11e3fe,_0x542de8){_0x11e3fe=_0x11e3fe-0x0;let _0x1215e6=a533_0x542d[_0x11e3fe];return _0x1215e6;};const _0x434514=a533_0x1215;'use strict';const Sequelize=require(_0x434514('0xd')),moment=require('moment'),path=require(_0x434514('0x0'));module[_0x434514('0xc')]={'format':{'type':Sequelize[_0x434514('0x8')],'get':function(){const _0x1e68a4=_0x434514;return this['getDataValue'](_0x1e68a4('0x9'))?path[_0x1e68a4('0xb')](this[_0x1e68a4('0x14')]('value')):undefined;}},'interactionid':{'type':Sequelize[_0x434514('0x13')]},'channel':{'type':Sequelize[_0x434514('0x13')]},'value':{'type':Sequelize[_0x434514('0x13')],'set':function(_0xbec884){const _0x352e04=_0x434514,_0x7cd661=_0xbec884[_0x352e04('0x12')](/\\/g,'/');this[_0x352e04('0x1')](_0x352e04('0x9'),_0x7cd661);}},'rating':{'type':Sequelize['INTEGER'],'validate':{'max':0x5,'min':0x0}},'duration':{'type':Sequelize[_0x434514('0xf')],'set':function(_0x2ea7b7){const _0x11c9c4=_0x434514;this['setDataValue'](_0x11c9c4('0x10'),moment()[_0x11c9c4('0x7')](_0x2ea7b7,'ms')),this[_0x11c9c4('0x1')]('closedAt',moment()),this[_0x11c9c4('0x1')](_0x11c9c4('0x5'),_0x2ea7b7);}},'startedAt':{'type':Sequelize['DATE'],'get':function(){const _0x582443=_0x434514;return moment(this[_0x582443('0x14')]('startedAt'))[_0x582443('0x2')](_0x582443('0xe'))[_0x582443('0x3')]();}},'closedAt':{'type':Sequelize['DATE'],'get':function(){const _0x3420a4=_0x434514;return moment(this['getDataValue'](_0x3420a4('0x11')))[_0x3420a4('0x2')]('MM-DD-YYYY\x20HH:mm')[_0x3420a4('0x3')]();}},'createdAt':{'type':Sequelize['DATE'],'get':function(){const _0x56ab4a=_0x434514;return moment(this[_0x56ab4a('0x14')](_0x56ab4a('0xa')))[_0x56ab4a('0x2')](_0x56ab4a('0xe'))[_0x56ab4a('0x3')]();}},'updatedAt':{'type':Sequelize[_0x434514('0x6')],'get':function(){const _0x5e5d84=_0x434514;return moment(this[_0x5e5d84('0x14')](_0x5e5d84('0x4')))[_0x5e5d84('0x2')](_0x5e5d84('0xe'))[_0x5e5d84('0x3')]();}}}; \ No newline at end of file diff --git a/server/api/screenRecording/screenRecording.controller.js b/server/api/screenRecording/screenRecording.controller.js index 8dd4f35..987267d 100644 --- a/server/api/screenRecording/screenRecording.controller.js +++ b/server/api/screenRecording/screenRecording.controller.js @@ -1 +1 @@ -const a534_0x4a62=['send','create','value','isNil','filter','Content-Range','offset','server/files/screen_recordings','query','map','params','describe','intersection','body','count','api','closedAt','uniqueid','download','Entity\x20not\x20found','length','attributes','limit','type','key','sendStatus','sort','existsSync','where','decryptFile','info','join','path','update','ScreenRecording\x20not\x20found','catch','set','like','destroy','includeAll','fieldName','filters','fields','extname','root','message','unlink','createdAt','\x22\x20trovato\x20eseguo\x20la\x20cancellazione','rawAttributes','cancellazione\x20fisica\x20documento\x20%s','order','model','%s.cypher','duration','../../config/environment','util','stack','merge','findOne','../../mysqldb','include','status','.cypher','sequelize','pick','filename','error-middleware/errors','lodash','nolimit','../../components/parsers/qs','ScreenRecording','name','unlinkSync','json','index','rows','recording','then','differenceBy','File:\x20\x22','keys'];(function(_0x414692,_0x4a62bb){const _0x4d02fe=function(_0x21a305){while(--_0x21a305){_0x414692['push'](_0x414692['shift']());}};_0x4d02fe(++_0x4a62bb);}(a534_0x4a62,0xba));const a534_0x4d02=function(_0x414692,_0x4a62bb){_0x414692=_0x414692-0x0;let _0x4d02fe=a534_0x4a62[_0x414692];return _0x4d02fe;};const _0x1c677b=a534_0x4d02;'use strict';const util=require(_0x1c677b('0x22')),path=require(_0x1c677b('0xa')),fs=require('fs'),_=require(_0x1c677b('0x2e')),qs=require(_0x1c677b('0x30')),logger=require('../../config/logger')(_0x1c677b('0x4b')),config=require(_0x1c677b('0x21')),db=require(_0x1c677b('0x26'))['db'],{Op,ValidationError}=require(_0x1c677b('0x2a')),{InternalError}=require(_0x1c677b('0x2d'));function respondWithResult(_0x21a305,_0x874eb8){return _0x874eb8=_0x874eb8||0xc8,function(_0x917096){const _0x22d70c=a534_0x4d02;if(_0x917096)return _0x21a305[_0x22d70c('0x28')](_0x874eb8)[_0x22d70c('0x34')](_0x917096);};}function respondWithFilteredResult(_0x1177c1,_0x22e22e){return function(_0x26253b){const _0x271bf3=a534_0x4d02;if(_0x26253b){const _0x2841f3=_0x26253b[_0x271bf3('0x4a')],_0x17fd05=_0x22e22e['offset'];let _0x1e465e=_0x22e22e['offset']+_0x22e22e[_0x271bf3('0x0')],_0x36d1e3;return _0x1e465e>=_0x2841f3?(_0x1e465e=_0x2841f3,_0x36d1e3=0xc8):_0x36d1e3=0xce,_0x1177c1[_0x271bf3('0x28')](_0x36d1e3),_0x1177c1[_0x271bf3('0xe')](_0x271bf3('0x41'),_0x17fd05+'-'+_0x1e465e+'/'+_0x2841f3)[_0x271bf3('0x34')](_0x26253b);}return null;};}function saveUpdates(_0x18db7d){return function(_0x47f577){const _0x36e525=a534_0x4d02;if(_0x47f577)return _0x47f577[_0x36e525('0xb')](_0x18db7d)[_0x36e525('0x38')](function(_0xf49d34){return _0xf49d34;});return null;};}function handleEntityNotFound(_0x1e340c){return function(_0x5758ba){const _0x1893e7=a534_0x4d02;return!_0x5758ba&&_0x1e340c[_0x1893e7('0x3')](0x194),_0x5758ba;};}function handleError(_0x4f32fe,_0x1de1da){return _0x1de1da=_0x1de1da||0x1f4,function(_0x596091){const _0x258fef=a534_0x4d02;logger['error'](_0x596091[_0x258fef('0x23')]),_0x596091[_0x258fef('0x32')]&&delete _0x596091['name'],_0x4f32fe[_0x258fef('0x28')](_0x1de1da)[_0x258fef('0x3c')](_0x596091);};}exports[_0x1c677b('0x35')]=function(_0x261a6b,_0x56b5ea){const _0xd49f71=_0x1c677b;let _0x4dad27={};const _0x127ab2={},_0x21f3bc={'count':0x0,'rows':[]},_0x46f3ea=_[_0xd49f71('0x45')](db[_0xd49f71('0x31')][_0xd49f71('0x1b')],function(_0x62c2a9){const _0x1b7235=_0xd49f71;return{'name':_0x62c2a9[_0x1b7235('0x12')],'type':_0x62c2a9[_0x1b7235('0x1')][_0x1b7235('0x2')]};});_0x127ab2[_0xd49f71('0x1e')]=_[_0xd49f71('0x39')](_[_0xd49f71('0x45')](_0x46f3ea,_0xd49f71('0x32')),['format']),_0x127ab2[_0xd49f71('0x44')]=_[_0xd49f71('0x3b')](_0x261a6b[_0xd49f71('0x44')]),_0x127ab2['filters']=_['intersection'](_0x127ab2[_0xd49f71('0x1e')],_0x127ab2[_0xd49f71('0x44')]),_0x4dad27[_0xd49f71('0x51')]=_[_0xd49f71('0x48')](_0x127ab2[_0xd49f71('0x1e')],qs[_0xd49f71('0x14')](_0x261a6b['query']['fields'])),_0x4dad27[_0xd49f71('0x51')]=_0x4dad27[_0xd49f71('0x51')][_0xd49f71('0x50')]?_0x4dad27[_0xd49f71('0x51')]:_0x127ab2[_0xd49f71('0x1e')];typeof _0x261a6b['query'][_0xd49f71('0x2f')]==='undefined'&&(_0x4dad27[_0xd49f71('0x0')]=qs[_0xd49f71('0x0')](_0x261a6b[_0xd49f71('0x44')][_0xd49f71('0x0')]),_0x4dad27['offset']=qs[_0xd49f71('0x42')](_0x261a6b[_0xd49f71('0x44')][_0xd49f71('0x42')]));_0x4dad27[_0xd49f71('0x1d')]=qs[_0xd49f71('0x4')](_0x261a6b[_0xd49f71('0x44')][_0xd49f71('0x4')]),_0x4dad27[_0xd49f71('0x6')]=qs['filters'](_[_0xd49f71('0x2b')](_0x261a6b[_0xd49f71('0x44')],_0x127ab2[_0xd49f71('0x13')]),_0x46f3ea);_0x261a6b[_0xd49f71('0x44')]['filter']&&(_0x4dad27[_0xd49f71('0x6')]=_['merge'](_0x4dad27[_0xd49f71('0x6')],{[Op['or']]:_[_0xd49f71('0x45')](_0x46f3ea,function(_0x2b3daf){const _0x29e473=_0xd49f71;if(_0x2b3daf['type']!=='VIRTUAL'){const _0x4a5d28={};return _0x4a5d28[_0x2b3daf['name']]={[Op[_0x29e473('0xf')]]:'%'+_0x261a6b['query'][_0x29e473('0x40')]+'%'},_0x4a5d28;}})}));_0x4dad27=_[_0xd49f71('0x24')]({},_0x4dad27,_0x261a6b['options']);const _0x4ba675={'where':_0x4dad27[_0xd49f71('0x6')]};return db[_0xd49f71('0x31')][_0xd49f71('0x4a')](_0x4ba675)[_0xd49f71('0x38')](function(_0x1b3939){const _0x105b56=_0xd49f71;return _0x21f3bc[_0x105b56('0x4a')]=_0x1b3939,_0x261a6b[_0x105b56('0x44')][_0x105b56('0x11')]&&(_0x4dad27[_0x105b56('0x27')]=[{'all':!![]}]),db[_0x105b56('0x31')]['findAll'](_0x4dad27);})['then'](function(_0x10ce98){const _0x4b2b8d=_0xd49f71;return _0x21f3bc[_0x4b2b8d('0x36')]=_0x10ce98,_0x21f3bc;})[_0xd49f71('0x38')](respondWithFilteredResult(_0x56b5ea,_0x4dad27))[_0xd49f71('0xd')](handleError(_0x56b5ea,null));},exports['show']=function(_0x365a8a,_0x32ccc1){const _0x279684=_0x1c677b;let _0x32e669={'raw':![],'where':{'id':_0x365a8a[_0x279684('0x46')]['id']}};const _0x5c24f5={};return _0x5c24f5[_0x279684('0x1e')]=_[_0x279684('0x3b')](db[_0x279684('0x31')][_0x279684('0x1b')]),_0x5c24f5[_0x279684('0x44')]=_['keys'](_0x365a8a[_0x279684('0x44')]),_0x5c24f5[_0x279684('0x13')]=_['intersection'](_0x5c24f5[_0x279684('0x1e')],_0x5c24f5[_0x279684('0x44')]),_0x32e669[_0x279684('0x51')]=_[_0x279684('0x48')](_0x5c24f5[_0x279684('0x1e')],qs[_0x279684('0x14')](_0x365a8a[_0x279684('0x44')][_0x279684('0x14')])),_0x32e669[_0x279684('0x51')]=_0x32e669[_0x279684('0x51')]['length']?_0x32e669['attributes']:_0x5c24f5[_0x279684('0x1e')],_0x365a8a[_0x279684('0x44')][_0x279684('0x11')]&&(_0x32e669[_0x279684('0x27')]=[{'all':!![]}]),_0x32e669=_[_0x279684('0x24')]({},_0x32e669,_0x365a8a['options']),db[_0x279684('0x31')][_0x279684('0x25')](_0x32e669)['then'](handleEntityNotFound(_0x32ccc1,null))[_0x279684('0x38')](respondWithResult(_0x32ccc1,null))['catch'](handleError(_0x32ccc1,null));},exports[_0x1c677b('0x3d')]=function(_0x307d88,_0x344643){const _0x194fff=_0x1c677b;return db[_0x194fff('0x31')][_0x194fff('0x3d')](_0x307d88[_0x194fff('0x49')],{})['then'](respondWithResult(_0x344643,0xc9))[_0x194fff('0xd')](handleError(_0x344643,null));},exports[_0x1c677b('0xb')]=function(_0x4e76e9,_0x1782e1){const _0x14c024=_0x1c677b;return _0x4e76e9[_0x14c024('0x49')]['id']&&delete _0x4e76e9[_0x14c024('0x49')]['id'],delete _0x4e76e9[_0x14c024('0x49')][_0x14c024('0x20')],delete _0x4e76e9[_0x14c024('0x49')][_0x14c024('0x19')],delete _0x4e76e9['body'][_0x14c024('0x4c')],delete _0x4e76e9[_0x14c024('0x49')][_0x14c024('0x3e')],db[_0x14c024('0x31')]['findOne']({'where':{'id':_0x4e76e9[_0x14c024('0x46')]['id']}})[_0x14c024('0x38')](handleEntityNotFound(_0x1782e1,null))[_0x14c024('0x38')](saveUpdates(_0x4e76e9['body'],null))['then'](respondWithResult(_0x1782e1,null))[_0x14c024('0xd')](handleError(_0x1782e1,null));},exports[_0x1c677b('0x47')]=function(_0x556e8c,_0x403a13){const _0x4753f9=_0x1c677b;return db[_0x4753f9('0x31')][_0x4753f9('0x47')]()[_0x4753f9('0x38')](respondWithResult(_0x403a13,null))[_0x4753f9('0xd')](handleError(_0x403a13,null));},exports[_0x1c677b('0x4e')]=function(_0x5504a4,_0x54d52d){const _0x2fa4a4=_0x1c677b,_0x5f5df2=require('../../components/encryptor');let _0x1c5e32=![];const _0x23e6f6={};return _0x5504a4[_0x2fa4a4('0x44')][_0x2fa4a4('0x1')]&&_0x5504a4[_0x2fa4a4('0x44')][_0x2fa4a4('0x1')]===_0x2fa4a4('0x4d')?_0x23e6f6[_0x2fa4a4('0x4d')]=_0x5504a4['params']['id']:_0x23e6f6['id']=_0x5504a4[_0x2fa4a4('0x46')]['id'],db[_0x2fa4a4('0x31')][_0x2fa4a4('0x25')]({'where':_0x23e6f6,'attributes':['id','value'],'raw':!![]})['then'](handleEntityNotFound(_0x54d52d,null))[_0x2fa4a4('0x38')](function(_0xdc9ef2){const _0x312123=_0x2fa4a4;if(_0xdc9ef2){const _0x316674=path[_0x312123('0x9')](config[_0x312123('0x16')],'server/files/screen_recordings',_0xdc9ef2[_0x312123('0x3e')]),_0x4bfb06=util['format'](_0x312123('0x1f'),_0x316674);if(fs['existsSync'](_0x4bfb06))return _0x1c5e32=!![],_0x5f5df2[_0x312123('0x7')](_0x4bfb06,_0x316674,config['secrets'][_0x312123('0x37')])[_0x312123('0x38')](function(){return _0xdc9ef2;});return _0xdc9ef2;}})[_0x2fa4a4('0x38')](function(_0x150f37){const _0x3ae42d=_0x2fa4a4;if(_0x150f37){const _0xc526a5=path[_0x3ae42d('0x9')](config[_0x3ae42d('0x16')],_0x3ae42d('0x43'),_0x150f37['value']);if(!fs[_0x3ae42d('0x5')](_0xc526a5))throw new ValidationError(_0x3ae42d('0xc'));return _0x150f37['filename']?_0x54d52d[_0x3ae42d('0x4e')](_0xc526a5,_0x150f37[_0x3ae42d('0x2c')]+path[_0x3ae42d('0x15')](_0xc526a5),function(){const _0x36a81b=_0x3ae42d;_0x1c5e32&&fs[_0x36a81b('0x18')](_0xc526a5);}):_0x54d52d[_0x3ae42d('0x4e')](_0xc526a5,function(){const _0xe7d631=_0x3ae42d;_0x1c5e32&&fs[_0xe7d631('0x18')](_0xc526a5);});}})['catch'](function(_0x3d55d3){const _0x6698ef=_0x2fa4a4;if(_0x3d55d3[_0x6698ef('0x17')]===_0x6698ef('0xc'))_0x54d52d['status'](0x194)[_0x6698ef('0x3c')]('Not\x20found');else return handleError(_0x54d52d,null);});},exports[_0x1c677b('0x10')]=function(_0x314458,_0xca6b71){const _0x11b0aa=_0x1c677b;return db[_0x11b0aa('0x31')]['findOne']({'where':{'id':_0x314458[_0x11b0aa('0x46')]['id']}})[_0x11b0aa('0x38')](function(_0x42353c){const _0x551c5a=_0x11b0aa;if(!_0x42353c)throw new ReferenceError(_0x551c5a('0x4f'));return _0x42353c;})[_0x11b0aa('0x38')](function(_0x15fd4a){const _0x5c05b6=_0x11b0aa;let _0x366af2=path[_0x5c05b6('0x9')](config[_0x5c05b6('0x16')],'server/files/screen_recordings',_0x15fd4a[_0x5c05b6('0x3e')]);return logger['info'](_0x5c05b6('0x1c'),_0x366af2),!_['isNil'](_0x15fd4a[_0x5c05b6('0x3e')])&&fs[_0x5c05b6('0x5')](_0x366af2)&&(logger['info'](_0x5c05b6('0x3a')+_0x366af2+_0x5c05b6('0x1a')),fs['unlinkSync'](_0x366af2)),_0x366af2=_0x366af2+_0x5c05b6('0x29'),!_[_0x5c05b6('0x3f')](_0x15fd4a[_0x5c05b6('0x3e')])&&fs[_0x5c05b6('0x5')](_0x366af2)&&(logger[_0x5c05b6('0x8')](_0x5c05b6('0x3a')+_0x366af2+_0x5c05b6('0x1a')),fs[_0x5c05b6('0x33')](_0x366af2)),_0x15fd4a;})[_0x11b0aa('0x38')](function(_0x3ee4d6){const _0x273c42=_0x11b0aa;if(!_0x3ee4d6)throw new InternalError();return _0x3ee4d6[_0x273c42('0x10')]();})['then'](function(){const _0x2e5a4a=_0x11b0aa;_0xca6b71[_0x2e5a4a('0x28')](0xcc)['end']();})[_0x11b0aa('0xd')](handleError(_0xca6b71,null));}; \ No newline at end of file +const a534_0x3d71=['limit','map','recording','pick','rows','message','unlinkSync','json','catch','describe','join','include','cancellazione\x20fisica\x20documento\x20%s','createdAt','uniqueid','root','findOne','merge','ScreenRecording','error-middleware/errors','stack','then','filter','isNil','intersection','keys','order','lodash','error','Not\x20found','includeAll','../../config/environment','ScreenRecording\x20not\x20found','fields','server/files/screen_recordings','rawAttributes','api','download','fieldName','end','Entity\x20not\x20found','update','closedAt','send','format','sendStatus','like','index','File:\x20\x22','sequelize','options','name','count','body','attributes','findAll','type','where','../../mysqldb','status','destroy','offset','info','sort','\x22\x20trovato\x20eseguo\x20la\x20cancellazione','create','%s.cypher','decryptFile','VIRTUAL','params','model','filename','value','existsSync','util','unlink','../../config/logger','query','undefined','key','extname','filters'];(function(_0x454f11,_0x3d7157){const _0x38357e=function(_0x15d788){while(--_0x15d788){_0x454f11['push'](_0x454f11['shift']());}};_0x38357e(++_0x3d7157);}(a534_0x3d71,0x98));const a534_0x3835=function(_0x454f11,_0x3d7157){_0x454f11=_0x454f11-0x0;let _0x38357e=a534_0x3d71[_0x454f11];return _0x38357e;};const _0x33581a=a534_0x3835;'use strict';const util=require(_0x33581a('0x4')),path=require('path'),fs=require('fs'),_=require(_0x33581a('0x27')),qs=require('../../components/parsers/qs'),logger=require(_0x33581a('0x6'))(_0x33581a('0x30')),config=require(_0x33581a('0x2b')),db=require(_0x33581a('0x46'))['db'],{Op,ValidationError}=require(_0x33581a('0x3d')),{InternalError}=require(_0x33581a('0x1f'));function respondWithResult(_0x15d788,_0x3cdd07){return _0x3cdd07=_0x3cdd07||0xc8,function(_0x2abf03){const _0xa59a3e=a534_0x3835;if(_0x2abf03)return _0x15d788['status'](_0x3cdd07)[_0xa59a3e('0x13')](_0x2abf03);};}function respondWithFilteredResult(_0x257297,_0x5db979){return function(_0x2160a4){const _0x494b44=a534_0x3835;if(_0x2160a4){const _0xbcfa22=_0x2160a4[_0x494b44('0x40')],_0x22a6bf=_0x5db979[_0x494b44('0x49')];let _0x574676=_0x5db979[_0x494b44('0x49')]+_0x5db979[_0x494b44('0xc')],_0x4adf7e;return _0x574676>=_0xbcfa22?(_0x574676=_0xbcfa22,_0x4adf7e=0xc8):_0x4adf7e=0xce,_0x257297['status'](_0x4adf7e),_0x257297['set']('Content-Range',_0x22a6bf+'-'+_0x574676+'/'+_0xbcfa22)[_0x494b44('0x13')](_0x2160a4);}return null;};}function saveUpdates(_0x352c2a){return function(_0x3566b7){const _0x577bbd=a534_0x3835;if(_0x3566b7)return _0x3566b7[_0x577bbd('0x35')](_0x352c2a)['then'](function(_0x5604c5){return _0x5604c5;});return null;};}function handleEntityNotFound(_0x117626){return function(_0x2807d8){const _0x10b768=a534_0x3835;return!_0x2807d8&&_0x117626[_0x10b768('0x39')](0x194),_0x2807d8;};}function handleError(_0x4e0b88,_0x16f71e){return _0x16f71e=_0x16f71e||0x1f4,function(_0x14fdae){const _0x3e5997=a534_0x3835;logger[_0x3e5997('0x28')](_0x14fdae[_0x3e5997('0x20')]),_0x14fdae['name']&&delete _0x14fdae['name'],_0x4e0b88[_0x3e5997('0x47')](_0x16f71e)[_0x3e5997('0x37')](_0x14fdae);};}exports[_0x33581a('0x3b')]=function(_0x45a83b,_0x1e9d93){const _0x445fd2=_0x33581a;let _0x34b83e={};const _0x254ddd={},_0x367d8a={'count':0x0,'rows':[]},_0x3bed91=_['map'](db[_0x445fd2('0x1e')]['rawAttributes'],function(_0x3a1de8){const _0x5d7a67=_0x445fd2;return{'name':_0x3a1de8[_0x5d7a67('0x32')],'type':_0x3a1de8[_0x5d7a67('0x44')][_0x5d7a67('0x9')]};});_0x254ddd['model']=_['differenceBy'](_[_0x445fd2('0xd')](_0x3bed91,_0x445fd2('0x3f')),[_0x445fd2('0x38')]),_0x254ddd[_0x445fd2('0x7')]=_['keys'](_0x45a83b[_0x445fd2('0x7')]),_0x254ddd[_0x445fd2('0xb')]=_[_0x445fd2('0x24')](_0x254ddd[_0x445fd2('0x0')],_0x254ddd[_0x445fd2('0x7')]),_0x34b83e['attributes']=_[_0x445fd2('0x24')](_0x254ddd[_0x445fd2('0x0')],qs[_0x445fd2('0x2d')](_0x45a83b['query'][_0x445fd2('0x2d')])),_0x34b83e['attributes']=_0x34b83e[_0x445fd2('0x42')]['length']?_0x34b83e[_0x445fd2('0x42')]:_0x254ddd[_0x445fd2('0x0')];typeof _0x45a83b[_0x445fd2('0x7')]['nolimit']===_0x445fd2('0x8')&&(_0x34b83e[_0x445fd2('0xc')]=qs[_0x445fd2('0xc')](_0x45a83b[_0x445fd2('0x7')]['limit']),_0x34b83e[_0x445fd2('0x49')]=qs[_0x445fd2('0x49')](_0x45a83b['query'][_0x445fd2('0x49')]));_0x34b83e[_0x445fd2('0x26')]=qs[_0x445fd2('0x4b')](_0x45a83b[_0x445fd2('0x7')]['sort']),_0x34b83e[_0x445fd2('0x45')]=qs[_0x445fd2('0xb')](_[_0x445fd2('0xf')](_0x45a83b['query'],_0x254ddd[_0x445fd2('0xb')]),_0x3bed91);_0x45a83b[_0x445fd2('0x7')][_0x445fd2('0x22')]&&(_0x34b83e['where']=_[_0x445fd2('0x1d')](_0x34b83e[_0x445fd2('0x45')],{[Op['or']]:_[_0x445fd2('0xd')](_0x3bed91,function(_0x52dbe7){const _0x45968e=_0x445fd2;if(_0x52dbe7[_0x45968e('0x44')]!==_0x45968e('0x50')){const _0x4975c7={};return _0x4975c7[_0x52dbe7[_0x45968e('0x3f')]]={[Op[_0x45968e('0x3a')]]:'%'+_0x45a83b[_0x45968e('0x7')]['filter']+'%'},_0x4975c7;}})}));_0x34b83e=_[_0x445fd2('0x1d')]({},_0x34b83e,_0x45a83b[_0x445fd2('0x3e')]);const _0x428617={'where':_0x34b83e[_0x445fd2('0x45')]};return db[_0x445fd2('0x1e')][_0x445fd2('0x40')](_0x428617)[_0x445fd2('0x21')](function(_0x4742b8){const _0x9089f1=_0x445fd2;return _0x367d8a[_0x9089f1('0x40')]=_0x4742b8,_0x45a83b[_0x9089f1('0x7')][_0x9089f1('0x2a')]&&(_0x34b83e[_0x9089f1('0x17')]=[{'all':!![]}]),db[_0x9089f1('0x1e')][_0x9089f1('0x43')](_0x34b83e);})[_0x445fd2('0x21')](function(_0x195ed2){const _0x16c4c4=_0x445fd2;return _0x367d8a[_0x16c4c4('0x10')]=_0x195ed2,_0x367d8a;})[_0x445fd2('0x21')](respondWithFilteredResult(_0x1e9d93,_0x34b83e))[_0x445fd2('0x14')](handleError(_0x1e9d93,null));},exports['show']=function(_0x1a2dd1,_0x9f90f9){const _0x2b8566=_0x33581a;let _0x326fbe={'raw':![],'where':{'id':_0x1a2dd1[_0x2b8566('0x51')]['id']}};const _0x129f8d={};return _0x129f8d[_0x2b8566('0x0')]=_[_0x2b8566('0x25')](db[_0x2b8566('0x1e')][_0x2b8566('0x2f')]),_0x129f8d[_0x2b8566('0x7')]=_[_0x2b8566('0x25')](_0x1a2dd1[_0x2b8566('0x7')]),_0x129f8d['filters']=_['intersection'](_0x129f8d['model'],_0x129f8d[_0x2b8566('0x7')]),_0x326fbe['attributes']=_[_0x2b8566('0x24')](_0x129f8d['model'],qs['fields'](_0x1a2dd1['query'][_0x2b8566('0x2d')])),_0x326fbe['attributes']=_0x326fbe['attributes']['length']?_0x326fbe[_0x2b8566('0x42')]:_0x129f8d[_0x2b8566('0x0')],_0x1a2dd1['query'][_0x2b8566('0x2a')]&&(_0x326fbe['include']=[{'all':!![]}]),_0x326fbe=_[_0x2b8566('0x1d')]({},_0x326fbe,_0x1a2dd1[_0x2b8566('0x3e')]),db[_0x2b8566('0x1e')][_0x2b8566('0x1c')](_0x326fbe)[_0x2b8566('0x21')](handleEntityNotFound(_0x9f90f9,null))[_0x2b8566('0x21')](respondWithResult(_0x9f90f9,null))[_0x2b8566('0x14')](handleError(_0x9f90f9,null));},exports['create']=function(_0x23fb50,_0x3bc130){const _0x3b4361=_0x33581a;return db[_0x3b4361('0x1e')][_0x3b4361('0x4d')](_0x23fb50[_0x3b4361('0x41')],{})['then'](respondWithResult(_0x3bc130,0xc9))['catch'](handleError(_0x3bc130,null));},exports[_0x33581a('0x35')]=function(_0x468deb,_0x2f4177){const _0x581f2a=_0x33581a;return _0x468deb[_0x581f2a('0x41')]['id']&&delete _0x468deb[_0x581f2a('0x41')]['id'],delete _0x468deb[_0x581f2a('0x41')]['duration'],delete _0x468deb[_0x581f2a('0x41')][_0x581f2a('0x19')],delete _0x468deb[_0x581f2a('0x41')][_0x581f2a('0x36')],delete _0x468deb['body'][_0x581f2a('0x2')],db[_0x581f2a('0x1e')][_0x581f2a('0x1c')]({'where':{'id':_0x468deb[_0x581f2a('0x51')]['id']}})[_0x581f2a('0x21')](handleEntityNotFound(_0x2f4177,null))[_0x581f2a('0x21')](saveUpdates(_0x468deb[_0x581f2a('0x41')],null))[_0x581f2a('0x21')](respondWithResult(_0x2f4177,null))[_0x581f2a('0x14')](handleError(_0x2f4177,null));},exports[_0x33581a('0x15')]=function(_0x28d034,_0x2d4bbc){const _0x2c7a21=_0x33581a;return db[_0x2c7a21('0x1e')][_0x2c7a21('0x15')]()[_0x2c7a21('0x21')](respondWithResult(_0x2d4bbc,null))[_0x2c7a21('0x14')](handleError(_0x2d4bbc,null));},exports[_0x33581a('0x31')]=function(_0x445bff,_0xf76df7){const _0x238788=_0x33581a,_0x2c2e9c=require('../../components/encryptor');let _0x5d1d88=![];const _0x4c7de3={};return _0x445bff['query'][_0x238788('0x44')]&&_0x445bff[_0x238788('0x7')]['type']==='uniqueid'?_0x4c7de3[_0x238788('0x1a')]=_0x445bff[_0x238788('0x51')]['id']:_0x4c7de3['id']=_0x445bff[_0x238788('0x51')]['id'],db[_0x238788('0x1e')][_0x238788('0x1c')]({'where':_0x4c7de3,'attributes':['id','value'],'raw':!![]})[_0x238788('0x21')](handleEntityNotFound(_0xf76df7,null))['then'](function(_0xef4092){const _0x48f678=_0x238788;if(_0xef4092){const _0x3ce89e=path[_0x48f678('0x16')](config[_0x48f678('0x1b')],_0x48f678('0x2e'),_0xef4092[_0x48f678('0x2')]),_0x5d398d=util[_0x48f678('0x38')](_0x48f678('0x4e'),_0x3ce89e);if(fs['existsSync'](_0x5d398d))return _0x5d1d88=!![],_0x2c2e9c[_0x48f678('0x4f')](_0x5d398d,_0x3ce89e,config['secrets'][_0x48f678('0xe')])[_0x48f678('0x21')](function(){return _0xef4092;});return _0xef4092;}})[_0x238788('0x21')](function(_0x508665){const _0x3391ee=_0x238788;if(_0x508665){const _0x4fdcf5=path[_0x3391ee('0x16')](config[_0x3391ee('0x1b')],_0x3391ee('0x2e'),_0x508665[_0x3391ee('0x2')]);if(!fs['existsSync'](_0x4fdcf5))throw new ValidationError(_0x3391ee('0x2c'));return _0x508665['filename']?_0xf76df7[_0x3391ee('0x31')](_0x4fdcf5,_0x508665[_0x3391ee('0x1')]+path[_0x3391ee('0xa')](_0x4fdcf5),function(){const _0x40c9aa=_0x3391ee;_0x5d1d88&&fs[_0x40c9aa('0x5')](_0x4fdcf5);}):_0xf76df7['download'](_0x4fdcf5,function(){const _0x578590=_0x3391ee;_0x5d1d88&&fs[_0x578590('0x5')](_0x4fdcf5);});}})[_0x238788('0x14')](function(_0x4cae22){const _0x2b6df2=_0x238788;if(_0x4cae22[_0x2b6df2('0x11')]==='ScreenRecording\x20not\x20found')_0xf76df7[_0x2b6df2('0x47')](0x194)[_0x2b6df2('0x37')](_0x2b6df2('0x29'));else return handleError(_0xf76df7,null);});},exports[_0x33581a('0x48')]=function(_0x5e9f07,_0x1d4612){const _0x54b1b9=_0x33581a;return db[_0x54b1b9('0x1e')]['findOne']({'where':{'id':_0x5e9f07['params']['id']}})[_0x54b1b9('0x21')](function(_0x501d39){const _0x374a2a=_0x54b1b9;if(!_0x501d39)throw new ReferenceError(_0x374a2a('0x34'));return _0x501d39;})[_0x54b1b9('0x21')](function(_0x2b0e1b){const _0x5aea95=_0x54b1b9;let _0x262d81=path[_0x5aea95('0x16')](config['root'],_0x5aea95('0x2e'),_0x2b0e1b[_0x5aea95('0x2')]);return logger['info'](_0x5aea95('0x18'),_0x262d81),!_[_0x5aea95('0x23')](_0x2b0e1b[_0x5aea95('0x2')])&&fs[_0x5aea95('0x3')](_0x262d81)&&(logger[_0x5aea95('0x4a')](_0x5aea95('0x3c')+_0x262d81+_0x5aea95('0x4c')),fs['unlinkSync'](_0x262d81)),_0x262d81=_0x262d81+'.cypher',!_[_0x5aea95('0x23')](_0x2b0e1b[_0x5aea95('0x2')])&&fs['existsSync'](_0x262d81)&&(logger[_0x5aea95('0x4a')](_0x5aea95('0x3c')+_0x262d81+'\x22\x20trovato\x20eseguo\x20la\x20cancellazione'),fs[_0x5aea95('0x12')](_0x262d81)),_0x2b0e1b;})[_0x54b1b9('0x21')](function(_0x59a3b7){const _0x34afa2=_0x54b1b9;if(!_0x59a3b7)throw new InternalError();return _0x59a3b7[_0x34afa2('0x48')]();})[_0x54b1b9('0x21')](function(){const _0x35dc06=_0x54b1b9;_0x1d4612[_0x35dc06('0x47')](0xcc)[_0x35dc06('0x33')]();})['catch'](handleError(_0x1d4612,null));}; \ No newline at end of file diff --git a/server/api/screenRecording/screenRecording.model.js b/server/api/screenRecording/screenRecording.model.js index ccab665..c9448aa 100644 --- a/server/api/screenRecording/screenRecording.model.js +++ b/server/api/screenRecording/screenRecording.model.js @@ -1 +1 @@ -const a535_0x292e=['ScreenRecording','define','interactionid','screen_recordings'];(function(_0x101405,_0x292efa){const _0x4bc12e=function(_0x57baa4){while(--_0x57baa4){_0x101405['push'](_0x101405['shift']());}};_0x4bc12e(++_0x292efa);}(a535_0x292e,0xa1));const a535_0x4bc1=function(_0x101405,_0x292efa){_0x101405=_0x101405-0x0;let _0x4bc12e=a535_0x292e[_0x101405];return _0x4bc12e;};'use strict';const attributes=require('./screenRecording.attributes');module['exports']=function(_0x57baa4){const _0x2f3b6c=a535_0x4bc1,_0x407260=_0x57baa4[_0x2f3b6c('0x0')](_0x2f3b6c('0x3'),attributes,{'tableName':_0x2f3b6c('0x2'),'paranoid':![],'indexes':[{'name':_0x2f3b6c('0x1'),'fields':[_0x2f3b6c('0x1')]}],'timestamps':!![]});return _0x407260;}; \ No newline at end of file +const a535_0x3e68=['screen_recordings','define','ScreenRecording','interactionid'];(function(_0x1bd0f5,_0x3e6834){const _0x2adc74=function(_0x52eca5){while(--_0x52eca5){_0x1bd0f5['push'](_0x1bd0f5['shift']());}};_0x2adc74(++_0x3e6834);}(a535_0x3e68,0x80));const a535_0x2adc=function(_0x1bd0f5,_0x3e6834){_0x1bd0f5=_0x1bd0f5-0x0;let _0x2adc74=a535_0x3e68[_0x1bd0f5];return _0x2adc74;};'use strict';const attributes=require('./screenRecording.attributes');module['exports']=function(_0x52eca5){const _0x46db60=a535_0x2adc,_0xa15c1a=_0x52eca5[_0x46db60('0x1')](_0x46db60('0x2'),attributes,{'tableName':_0x46db60('0x0'),'paranoid':![],'indexes':[{'name':_0x46db60('0x3'),'fields':[_0x46db60('0x3')]}],'timestamps':!![]});return _0xa15c1a;}; \ No newline at end of file diff --git a/server/api/setting/index.js b/server/api/setting/index.js index 8fc4b38..397a1d2 100644 --- a/server/api/setting/index.js +++ b/server/api/setting/index.js @@ -1 +1 @@ -const a536_0x3e98=['put','format','addLogoLogin','/:id','../../config/environment','/:id/logo','/:id/gdpr','addPreferred','/:id/preferred','update','gdpr','getLogoLogin','isAuthenticated','preferred','getFavicon','exports','path','join','show','../../components/auth/service','/:id/logo_login','single','file','get','extname','index','files/images/logos/','Router','favicon','addFavicon','util','originalname','post','root'];(function(_0x1b4654,_0x3e9867){const _0x119718=function(_0x52ac84){while(--_0x52ac84){_0x1b4654['push'](_0x1b4654['shift']());}};_0x119718(++_0x3e9867);}(a536_0x3e98,0x83));const a536_0x1197=function(_0x1b4654,_0x3e9867){_0x1b4654=_0x1b4654-0x0;let _0x119718=a536_0x3e98[_0x1b4654];return _0x119718;};const _0x340bed=a536_0x1197;'use strict';const multer=require('multer'),util=require(_0x340bed('0x1')),path=require(_0x340bed('0x15')),express=require('express'),router=express[_0x340bed('0x20')](),auth=require(_0x340bed('0x18')),config=require(_0x340bed('0x9')),controller=require('./setting.controller'),upload=_0x52ac84=>multer({'storage':multer['diskStorage']({'destination':function(_0x598fb3,_0x11477d,_0x5e37db){const _0x4ec17c=_0x340bed;_0x5e37db(null,path[_0x4ec17c('0x16')](config[_0x4ec17c('0x4')],_0x4ec17c('0x1f')));},'filename':function(_0x1be6ed,_0x159560,_0x5f56d0){const _0x59e465=_0x340bed;_0x5f56d0(null,util[_0x59e465('0x6')]('%s%s',_0x52ac84,path[_0x59e465('0x1d')](_0x159560[_0x59e465('0x2')])));}})});router[_0x340bed('0x1c')]('/',auth[_0x340bed('0x11')](),controller[_0x340bed('0x1e')]),router[_0x340bed('0x1c')](_0x340bed('0x8'),controller[_0x340bed('0x17')]),router[_0x340bed('0x1c')](_0x340bed('0xa'),controller['getLogo']),router['get'](_0x340bed('0x19'),controller[_0x340bed('0x10')]),router['get'](_0x340bed('0xb'),controller[_0x340bed('0xf')]),router[_0x340bed('0x1c')](_0x340bed('0xd'),controller['getPreferred']),router['get']('/:id/favicon',controller[_0x340bed('0x13')]),router[_0x340bed('0x3')](_0x340bed('0xa'),upload('logo')['single']('file'),controller['addLogo']),router[_0x340bed('0x3')](_0x340bed('0x19'),upload('logologin')[_0x340bed('0x1a')](_0x340bed('0x1b')),controller[_0x340bed('0x7')]),router[_0x340bed('0x3')](_0x340bed('0xd'),upload(_0x340bed('0x12'))['single'](_0x340bed('0x1b')),controller[_0x340bed('0xc')]),router[_0x340bed('0x3')]('/:id/favicon',upload(_0x340bed('0x21'))[_0x340bed('0x1a')]('file'),controller[_0x340bed('0x0')]),router[_0x340bed('0x5')](_0x340bed('0x8'),auth[_0x340bed('0x11')](),controller[_0x340bed('0xe')]),module[_0x340bed('0x14')]=router; \ No newline at end of file +const a536_0x1617=['addLogoLogin','multer','getFavicon','join','favicon','format','getPreferred','addFavicon','../../config/environment','getLogo','show','/:id/preferred','%s%s','getLogoLogin','post','files/images/logos/','path','originalname','/:id','logologin','/:id/logo_login','Router','gdpr','file','put','get','update','exports','extname','express','/:id/logo','./setting.controller','isAuthenticated','root','single'];(function(_0xffae8a,_0x16179a){const _0x1a05e7=function(_0xdd5abe){while(--_0xdd5abe){_0xffae8a['push'](_0xffae8a['shift']());}};_0x1a05e7(++_0x16179a);}(a536_0x1617,0x126));const a536_0x1a05=function(_0xffae8a,_0x16179a){_0xffae8a=_0xffae8a-0x0;let _0x1a05e7=a536_0x1617[_0xffae8a];return _0x1a05e7;};const _0x3c69d4=a536_0x1a05;'use strict';const multer=require(_0x3c69d4('0x16')),util=require('util'),path=require(_0x3c69d4('0x2')),express=require(_0x3c69d4('0xf')),router=express[_0x3c69d4('0x7')](),auth=require('../../components/auth/service'),config=require(_0x3c69d4('0x1d')),controller=require(_0x3c69d4('0x11')),upload=_0xdd5abe=>multer({'storage':multer['diskStorage']({'destination':function(_0xea64d4,_0x36f981,_0x230094){const _0x48b9c2=_0x3c69d4;_0x230094(null,path[_0x48b9c2('0x18')](config[_0x48b9c2('0x13')],_0x48b9c2('0x1')));},'filename':function(_0x616eae,_0x5dec0c,_0x2ed1a8){const _0xe9d96f=_0x3c69d4;_0x2ed1a8(null,util[_0xe9d96f('0x1a')](_0xe9d96f('0x21'),_0xdd5abe,path[_0xe9d96f('0xe')](_0x5dec0c[_0xe9d96f('0x3')])));}})});router[_0x3c69d4('0xb')]('/',auth[_0x3c69d4('0x12')](),controller['index']),router[_0x3c69d4('0xb')](_0x3c69d4('0x4'),controller[_0x3c69d4('0x1f')]),router[_0x3c69d4('0xb')](_0x3c69d4('0x10'),controller[_0x3c69d4('0x1e')]),router[_0x3c69d4('0xb')](_0x3c69d4('0x6'),controller[_0x3c69d4('0x22')]),router['get']('/:id/gdpr',controller[_0x3c69d4('0x8')]),router[_0x3c69d4('0xb')]('/:id/preferred',controller[_0x3c69d4('0x1b')]),router[_0x3c69d4('0xb')]('/:id/favicon',controller[_0x3c69d4('0x17')]),router[_0x3c69d4('0x0')]('/:id/logo',upload('logo')[_0x3c69d4('0x14')](_0x3c69d4('0x9')),controller['addLogo']),router['post'](_0x3c69d4('0x6'),upload(_0x3c69d4('0x5'))['single']('file'),controller[_0x3c69d4('0x15')]),router[_0x3c69d4('0x0')](_0x3c69d4('0x20'),upload('preferred')[_0x3c69d4('0x14')](_0x3c69d4('0x9')),controller['addPreferred']),router['post']('/:id/favicon',upload(_0x3c69d4('0x19'))['single'](_0x3c69d4('0x9')),controller[_0x3c69d4('0x1c')]),router[_0x3c69d4('0xa')](_0x3c69d4('0x4'),auth[_0x3c69d4('0x12')](),controller[_0x3c69d4('0xc')]),module[_0x3c69d4('0xd')]=router; \ No newline at end of file diff --git a/server/api/setting/setting.attributes.js b/server/api/setting/setting.attributes.js index 711c4bf..d704307 100644 --- a/server/api/setting/setting.attributes.js +++ b/server/api/setting/setting.attributes.js @@ -1 +1 @@ -const a537_0x2608=['sequelize','/var/opt/motion2/server/files/sounds/converted','STRING','alternate','BOOLEAN','min_mailbox','min_internal','INTEGER'];(function(_0xf32f68,_0x26080c){const _0x3f5e64=function(_0x18fa04){while(--_0x18fa04){_0xf32f68['push'](_0xf32f68['shift']());}};_0x3f5e64(++_0x26080c);}(a537_0x2608,0x114));const a537_0x3f5e=function(_0xf32f68,_0x26080c){_0xf32f68=_0xf32f68-0x0;let _0x3f5e64=a537_0x2608[_0xf32f68];return _0x3f5e64;};const _0x41ac3c=a537_0x3f5e;'use strict';const Sequelize=require(_0x41ac3c('0x4'));module['exports']={'min_internal':{'type':Sequelize[_0x41ac3c('0x3')](0xb),'unique':_0x41ac3c('0x2'),'defaultValue':0x3e8},'min_mailbox':{'type':Sequelize['INTEGER'](0xb),'unique':_0x41ac3c('0x1'),'defaultValue':0x3e8},'agi_port':{'type':Sequelize[_0x41ac3c('0x3')](0xb),'defaultValue':0x11dd},'soundPath':{'type':Sequelize[_0x41ac3c('0x6')],'defaultValue':_0x41ac3c('0x5')},'logo':{'type':Sequelize[_0x41ac3c('0x6')]},'defaultLogo':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':!![]},'loginLogo':{'type':Sequelize[_0x41ac3c('0x6')]},'defaultLoginLogo':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'headerWhiteLabel':{'type':Sequelize[_0x41ac3c('0x6')]},'defaultHeaderWhiteLabel':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':!![]},'securePassword':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':!![]},'firstSetup':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':!![]},'stunaddr':{'type':Sequelize[_0x41ac3c('0x6')]},'turnaddr':{'type':Sequelize[_0x41ac3c('0x6')]},'turnusername':{'type':Sequelize[_0x41ac3c('0x6')]},'turnpassword':{'type':Sequelize['STRING']},'pageTitle':{'type':Sequelize[_0x41ac3c('0x6')]},'defaultPageTitle':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':!![]},'callRecordingEncryption':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':![]},'passwordExpiresDays':{'type':Sequelize[_0x41ac3c('0x3')](0xb),'defaultValue':0x5a},'phoneBarAutoUpdater':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':!![]},'phoneBarAutoUpdaterUrl':{'type':Sequelize[_0x41ac3c('0x6')],'defaultValue':'https://www.xcally.com/bar/phonebar/autoupdater.xml'},'enableEmailPreview':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':![]},'split':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'splitSizeCsv':{'type':Sequelize[_0x41ac3c('0x3')],'defaultValue':0x1388},'splitSizePdf':{'type':Sequelize[_0x41ac3c('0x3')],'defaultValue':0x1388},'splitSizeXlsx':{'type':Sequelize['INTEGER'],'defaultValue':0x1388},'messagesAlignment':{'type':Sequelize[_0x41ac3c('0x6')],'defaultValue':_0x41ac3c('0x7')},'chatTimeout':{'type':Sequelize['INTEGER'],'defaultValue':0x1e},'phoneBarRememberMeEnabled':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':!![]},'preferred':{'type':Sequelize['STRING']},'defaultPreferred':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'rtlSupport':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':![]},'defaultScreenRecordingPath':{'type':Sequelize[_0x41ac3c('0x6')]},'allowedLoginAttempts':{'type':Sequelize[_0x41ac3c('0x3')],'defaultValue':0x5},'blockDuration':{'type':Sequelize['INTEGER'],'defaultValue':0xa},'favicon':{'type':Sequelize[_0x41ac3c('0x6')]},'defaultFavicon':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':!![]},'loginMailFrequency':{'type':Sequelize[_0x41ac3c('0x3')],'defaultValue':0xa,'validate':{'min':0xa}},'transcribe':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':![]},'automaticTranscribe':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'transcribeAccountId':{'type':Sequelize[_0x41ac3c('0x3')]},'transcribeRegion':{'type':Sequelize['STRING']},'sentiment':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':![]},'automaticSentiment':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':![]},'sentimentAccountId':{'type':Sequelize['INTEGER']},'sentimentRegion':{'type':Sequelize['STRING']},'language':{'type':Sequelize[_0x41ac3c('0x6')]},'bucket':{'type':Sequelize[_0x41ac3c('0x6')]},'googleSsoEnabled':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':![]},'enforcePasswordHistory':{'type':Sequelize[_0x41ac3c('0x0')],'defaultValue':!![]},'passwordHistoryLimit':{'type':Sequelize[_0x41ac3c('0x3')](0x2)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x1,'max':0x5}}}; \ No newline at end of file +const a537_0x1e59=['UNSIGNED','https://www.xcally.com/bar/phonebar/autoupdater.xml','INTEGER','BOOLEAN','alternate','STRING','exports','min_internal'];(function(_0x2e8136,_0x1e5977){const _0x412842=function(_0x48e7e0){while(--_0x48e7e0){_0x2e8136['push'](_0x2e8136['shift']());}};_0x412842(++_0x1e5977);}(a537_0x1e59,0x74));const a537_0x4128=function(_0x2e8136,_0x1e5977){_0x2e8136=_0x2e8136-0x0;let _0x412842=a537_0x1e59[_0x2e8136];return _0x412842;};const _0x2fe576=a537_0x4128;'use strict';const Sequelize=require('sequelize');module[_0x2fe576('0x2')]={'min_internal':{'type':Sequelize['INTEGER'](0xb),'unique':_0x2fe576('0x3'),'defaultValue':0x3e8},'min_mailbox':{'type':Sequelize[_0x2fe576('0x6')](0xb),'unique':'min_mailbox','defaultValue':0x3e8},'agi_port':{'type':Sequelize[_0x2fe576('0x6')](0xb),'defaultValue':0x11dd},'soundPath':{'type':Sequelize[_0x2fe576('0x1')],'defaultValue':'/var/opt/motion2/server/files/sounds/converted'},'logo':{'type':Sequelize[_0x2fe576('0x1')]},'defaultLogo':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'loginLogo':{'type':Sequelize[_0x2fe576('0x1')]},'defaultLoginLogo':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'headerWhiteLabel':{'type':Sequelize['STRING']},'defaultHeaderWhiteLabel':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':!![]},'securePassword':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'firstSetup':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'stunaddr':{'type':Sequelize[_0x2fe576('0x1')]},'turnaddr':{'type':Sequelize[_0x2fe576('0x1')]},'turnusername':{'type':Sequelize[_0x2fe576('0x1')]},'turnpassword':{'type':Sequelize[_0x2fe576('0x1')]},'pageTitle':{'type':Sequelize['STRING']},'defaultPageTitle':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':!![]},'callRecordingEncryption':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':![]},'passwordExpiresDays':{'type':Sequelize[_0x2fe576('0x6')](0xb),'defaultValue':0x5a},'phoneBarAutoUpdater':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':!![]},'phoneBarAutoUpdaterUrl':{'type':Sequelize['STRING'],'defaultValue':_0x2fe576('0x5')},'enableEmailPreview':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':![]},'split':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'splitSizeCsv':{'type':Sequelize[_0x2fe576('0x6')],'defaultValue':0x1388},'splitSizePdf':{'type':Sequelize[_0x2fe576('0x6')],'defaultValue':0x1388},'splitSizeXlsx':{'type':Sequelize[_0x2fe576('0x6')],'defaultValue':0x1388},'messagesAlignment':{'type':Sequelize[_0x2fe576('0x1')],'defaultValue':_0x2fe576('0x0')},'chatTimeout':{'type':Sequelize['INTEGER'],'defaultValue':0x1e},'phoneBarRememberMeEnabled':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'preferred':{'type':Sequelize[_0x2fe576('0x1')]},'defaultPreferred':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':!![]},'rtlSupport':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':![]},'defaultScreenRecordingPath':{'type':Sequelize[_0x2fe576('0x1')]},'allowedLoginAttempts':{'type':Sequelize[_0x2fe576('0x6')],'defaultValue':0x5},'blockDuration':{'type':Sequelize[_0x2fe576('0x6')],'defaultValue':0xa},'favicon':{'type':Sequelize[_0x2fe576('0x1')]},'defaultFavicon':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':!![]},'loginMailFrequency':{'type':Sequelize['INTEGER'],'defaultValue':0xa,'validate':{'min':0xa}},'transcribe':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':![]},'automaticTranscribe':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':![]},'transcribeAccountId':{'type':Sequelize['INTEGER']},'transcribeRegion':{'type':Sequelize[_0x2fe576('0x1')]},'sentiment':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':![]},'automaticSentiment':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':![]},'sentimentAccountId':{'type':Sequelize[_0x2fe576('0x6')]},'sentimentRegion':{'type':Sequelize['STRING']},'language':{'type':Sequelize[_0x2fe576('0x1')]},'bucket':{'type':Sequelize[_0x2fe576('0x1')]},'googleSsoEnabled':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':![]},'enforcePasswordHistory':{'type':Sequelize[_0x2fe576('0x7')],'defaultValue':!![]},'passwordHistoryLimit':{'type':Sequelize['INTEGER'](0x2)[_0x2fe576('0x4')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x5}}}; \ No newline at end of file diff --git a/server/api/setting/setting.controller.js b/server/api/setting/setting.controller.js index a6d320d..8c38871 100644 --- a/server/api/setting/setting.controller.js +++ b/server/api/setting/setting.controller.js @@ -1 +1 @@ -const a538_0x2f0e=['sendStatus','error','undefined','params','getFavicon','nolimit','lodash','\x20not\x20found','pick','defaultFavicon','name','keys','filename','model','then','status','index','count','show','includeAll','../../config/logger','filter','loginLogo','getLicense','default_loginLogo.svg','sort','attributes','default_logo.svg','map','addFavicon','../../components/parsers/qs','merge','include','Setting','../../mysqldb','where','defaultLoginLogo','files/images/logos','join','../../config/environment','toLower','set','fieldName','rawAttributes','update','file','existsSync','favicon','logo','getLogo','root','default_preferred.png','default','query','like','Content-Range','body','default_favicon.ico','filters','upperFirst','length','fields','api','stack','catch','custom','offset','defaultLogo','defaultPreferred','../../config/license/util','download','getPreferred','options','intersection','json','findOne','limit','type','preferred','path','rows'];(function(_0x4cfe49,_0x2f0e96){const _0x2ffc07=function(_0x2922d6){while(--_0x2922d6){_0x4cfe49['push'](_0x4cfe49['shift']());}};_0x2ffc07(++_0x2f0e96);}(a538_0x2f0e,0x1b1));const a538_0x2ffc=function(_0x4cfe49,_0x2f0e96){_0x4cfe49=_0x4cfe49-0x0;let _0x2ffc07=a538_0x2f0e[_0x4cfe49];return _0x2ffc07;};const _0x26816d=a538_0x2ffc;'use strict';const path=require(_0x26816d('0x33')),fs=require('fs'),_=require(_0x26816d('0x3b')),qs=require(_0x26816d('0x2')),logger=require(_0x26816d('0x49'))(_0x26816d('0x22')),config=require(_0x26816d('0xb')),db=require(_0x26816d('0x6'))['db'],{Op,ValidationError}=require('sequelize'),utilLicense=require(_0x26816d('0x29'));function respondWithResult(_0x2922d6,_0x49cfce){return _0x49cfce=_0x49cfce||0xc8,function(_0xe4ff17){const _0x513d0b=a538_0x2ffc;if(_0xe4ff17)return _0x2922d6[_0x513d0b('0x44')](_0x49cfce)['json'](_0xe4ff17);};}function respondWithFilteredResult(_0x5e3ce9,_0xef7c63){return function(_0x5398d8){const _0x29a437=a538_0x2ffc;if(_0x5398d8){const _0x3531db=_0x5398d8[_0x29a437('0x46')],_0x43a097=_0xef7c63[_0x29a437('0x26')];let _0x2801f7=_0xef7c63[_0x29a437('0x26')]+_0xef7c63[_0x29a437('0x30')],_0x46ac8e;return _0x2801f7>=_0x3531db?(_0x2801f7=_0x3531db,_0x46ac8e=0xc8):_0x46ac8e=0xce,_0x5e3ce9[_0x29a437('0x44')](_0x46ac8e),_0x5e3ce9[_0x29a437('0xd')](_0x29a437('0x1b'),_0x43a097+'-'+_0x2801f7+'/'+_0x3531db)[_0x29a437('0x2e')](_0x5398d8);}return null;};}function saveUpdates(_0x153b2f){return function(_0x49fc5d){const _0x53c778=a538_0x2ffc;if(_0x49fc5d)return _0x49fc5d['update'](_0x153b2f)[_0x53c778('0x43')](function(_0x5cc6ca){return _0x5cc6ca;});return null;};}function handleEntityNotFound(_0x2625c3){return function(_0x287e90){const _0x4b39f5=a538_0x2ffc;return!_0x287e90&&_0x2625c3[_0x4b39f5('0x35')](0x194),_0x287e90;};}function handleError(_0x2dc217,_0x430bab){return _0x430bab=_0x430bab||0x1f4,function(_0x3af596){const _0x4af2dc=a538_0x2ffc;logger[_0x4af2dc('0x36')](_0x3af596[_0x4af2dc('0x23')]),_0x3af596[_0x4af2dc('0x3f')]&&delete _0x3af596[_0x4af2dc('0x3f')],_0x2dc217[_0x4af2dc('0x44')](_0x430bab)['send'](_0x3af596);};}exports[_0x26816d('0x45')]=function(_0x4d4ddd,_0x304c35){const _0x575c22=_0x26816d;let _0x3cbad5={};const _0x41ccf7={},_0xa4c8e5={'count':0x0,'rows':[]},_0x51b580=_[_0x575c22('0x0')](db[_0x575c22('0x5')][_0x575c22('0xf')],function(_0x537d00){const _0x45fd41=_0x575c22;return{'name':_0x537d00[_0x45fd41('0xe')],'type':_0x537d00[_0x45fd41('0x31')]['key']};});_0x41ccf7[_0x575c22('0x42')]=_[_0x575c22('0x0')](_0x51b580,_0x575c22('0x3f')),_0x41ccf7[_0x575c22('0x19')]=_[_0x575c22('0x40')](_0x4d4ddd[_0x575c22('0x19')]),_0x41ccf7[_0x575c22('0x1e')]=_['intersection'](_0x41ccf7[_0x575c22('0x42')],_0x41ccf7['query']),_0x3cbad5[_0x575c22('0x4f')]=_[_0x575c22('0x2d')](_0x41ccf7[_0x575c22('0x42')],qs[_0x575c22('0x21')](_0x4d4ddd[_0x575c22('0x19')]['fields'])),_0x3cbad5[_0x575c22('0x4f')]=_0x3cbad5['attributes'][_0x575c22('0x20')]?_0x3cbad5[_0x575c22('0x4f')]:_0x41ccf7[_0x575c22('0x42')];typeof _0x4d4ddd[_0x575c22('0x19')][_0x575c22('0x3a')]===_0x575c22('0x37')&&(_0x3cbad5[_0x575c22('0x30')]=qs[_0x575c22('0x30')](_0x4d4ddd['query']['limit']),_0x3cbad5[_0x575c22('0x26')]=qs['offset'](_0x4d4ddd['query'][_0x575c22('0x26')]));_0x3cbad5['order']=qs[_0x575c22('0x4e')](_0x4d4ddd[_0x575c22('0x19')][_0x575c22('0x4e')]),_0x3cbad5[_0x575c22('0x7')]=qs[_0x575c22('0x1e')](_[_0x575c22('0x3d')](_0x4d4ddd[_0x575c22('0x19')],_0x41ccf7[_0x575c22('0x1e')]),_0x51b580);_0x4d4ddd[_0x575c22('0x19')][_0x575c22('0x4a')]&&(_0x3cbad5[_0x575c22('0x7')]=_[_0x575c22('0x3')](_0x3cbad5[_0x575c22('0x7')],{[Op['or']]:_['map'](_0x51b580,function(_0x8af051){const _0x503f81=_0x575c22;if(_0x8af051[_0x503f81('0x31')]!=='VIRTUAL'){const _0x510ce4={};return _0x510ce4[_0x8af051[_0x503f81('0x3f')]]={[Op[_0x503f81('0x1a')]]:'%'+_0x4d4ddd['query'][_0x503f81('0x4a')]+'%'},_0x510ce4;}})}));_0x3cbad5=_[_0x575c22('0x3')]({},_0x3cbad5,_0x4d4ddd[_0x575c22('0x2c')]);const _0x5b66f6={'where':_0x3cbad5['where']};return db[_0x575c22('0x5')][_0x575c22('0x46')](_0x5b66f6)[_0x575c22('0x43')](function(_0x43ce2d){const _0x46db08=_0x575c22;return _0xa4c8e5[_0x46db08('0x46')]=_0x43ce2d,_0x4d4ddd[_0x46db08('0x19')][_0x46db08('0x48')]&&(_0x3cbad5[_0x46db08('0x4')]=[{'all':!![]}]),db[_0x46db08('0x5')]['findAll'](_0x3cbad5);})[_0x575c22('0x43')](function(_0x220f2e){const _0x5f4fa1=_0x575c22;return _0xa4c8e5[_0x5f4fa1('0x34')]=_0x220f2e,_0xa4c8e5;})[_0x575c22('0x43')](respondWithFilteredResult(_0x304c35,_0x3cbad5))[_0x575c22('0x24')](handleError(_0x304c35,null));},exports[_0x26816d('0x47')]=function(_0x4e8843,_0x31f1f0){const _0x90dd46=_0x26816d;let _0x12abb9={'raw':![],'where':{'id':_0x4e8843[_0x90dd46('0x38')]['id']}};const _0x18f0c8={};return _0x18f0c8[_0x90dd46('0x42')]=_['keys'](db['Setting'][_0x90dd46('0xf')]),_0x18f0c8['query']=_[_0x90dd46('0x40')](_0x4e8843[_0x90dd46('0x19')]),_0x18f0c8[_0x90dd46('0x1e')]=_['intersection'](_0x18f0c8[_0x90dd46('0x42')],_0x18f0c8[_0x90dd46('0x19')]),_0x12abb9[_0x90dd46('0x4f')]=_[_0x90dd46('0x2d')](_0x18f0c8[_0x90dd46('0x42')],qs[_0x90dd46('0x21')](_0x4e8843['query'][_0x90dd46('0x21')])),_0x12abb9['attributes']=_0x12abb9[_0x90dd46('0x4f')][_0x90dd46('0x20')]?_0x12abb9[_0x90dd46('0x4f')]:_0x18f0c8['model'],_0x4e8843[_0x90dd46('0x19')]['includeAll']&&(_0x12abb9[_0x90dd46('0x4')]=[{'all':!![]}]),_0x12abb9=_['merge']({},_0x12abb9,_0x4e8843['options']),db[_0x90dd46('0x5')][_0x90dd46('0x2f')](_0x12abb9)[_0x90dd46('0x43')](handleEntityNotFound(_0x31f1f0,null))['then'](respondWithResult(_0x31f1f0,null))[_0x90dd46('0x24')](handleError(_0x31f1f0,null));},exports[_0x26816d('0x10')]=function(_0x58f661,_0x4c68d0){const _0x52a4c1=_0x26816d;return _0x58f661[_0x52a4c1('0x1c')]['id']&&delete _0x58f661[_0x52a4c1('0x1c')]['id'],db['Setting']['findOne']({'where':{'id':_0x58f661[_0x52a4c1('0x38')]['id']}})['then'](handleEntityNotFound(_0x4c68d0,null))[_0x52a4c1('0x43')](saveUpdates(_0x58f661['body'],null))[_0x52a4c1('0x43')](respondWithResult(_0x4c68d0,null))['catch'](handleError(_0x4c68d0,null));},exports['addLogo']=function(_0x27bd1b,_0x5a664e){const _0x1ad162=_0x26816d;return _0x27bd1b[_0x1ad162('0x11')]&&_0x27bd1b[_0x1ad162('0x11')][_0x1ad162('0x41')]&&(_0x27bd1b[_0x1ad162('0x1c')][_0x1ad162('0x14')]=_0x27bd1b[_0x1ad162('0x11')][_0x1ad162('0x41')]),db[_0x1ad162('0x5')][_0x1ad162('0x2f')]({'where':{'id':_0x27bd1b['params']['id']}})[_0x1ad162('0x43')](handleEntityNotFound(_0x5a664e,null))[_0x1ad162('0x43')](saveUpdates(_0x27bd1b[_0x1ad162('0x1c')],null))[_0x1ad162('0x43')](respondWithResult(_0x5a664e,null))[_0x1ad162('0x24')](handleError(_0x5a664e,null));},exports['addLogoLogin']=function(_0x32996d,_0xcec174){const _0x9de8fa=_0x26816d;return _0x32996d[_0x9de8fa('0x11')]&&_0x32996d[_0x9de8fa('0x11')]['filename']&&(_0x32996d[_0x9de8fa('0x1c')][_0x9de8fa('0x4b')]=_0x32996d[_0x9de8fa('0x11')]['filename']),db['Setting'][_0x9de8fa('0x2f')]({'where':{'id':_0x32996d['params']['id']}})[_0x9de8fa('0x43')](handleEntityNotFound(_0xcec174,null))['then'](saveUpdates(_0x32996d[_0x9de8fa('0x1c')],null))[_0x9de8fa('0x43')](respondWithResult(_0xcec174,null))[_0x9de8fa('0x24')](handleError(_0xcec174,null));},exports[_0x26816d('0x15')]=function(_0x336563,_0x30b939){const _0x434c09=_0x26816d,_0x42d419=path[_0x434c09('0xa')](config[_0x434c09('0x16')],_0x434c09('0x9'));let _0x272a5c={'custom':![]};return utilLicense['getLicense']()[_0x434c09('0x43')](function(_0x3afdb6){const _0x9eb655=_0x434c09;return _0x3afdb6&&(_0x272a5c=_0x3afdb6),db[_0x9eb655('0x5')][_0x9eb655('0x2f')]({'where':{'id':_0x336563['params']['id']},'attributes':[_0x9eb655('0x14'),_0x9eb655('0x4b'),_0x9eb655('0x32'),'favicon',_0x9eb655('0x27'),_0x9eb655('0x8'),_0x9eb655('0x28'),_0x9eb655('0x3e')],'raw':!![]});})[_0x434c09('0x43')](handleEntityNotFound(_0x30b939,null))[_0x434c09('0x43')](function(_0x5130f9){const _0x183fc3=_0x434c09;if(_0x5130f9){let _0x5dd405=_0x5130f9['logo']&&fs['existsSync'](path['join'](_0x42d419,_[_0x183fc3('0xc')](_0x5130f9[_0x183fc3('0x14')])))?path['join'](_0x42d419,_[_0x183fc3('0xc')](_0x5130f9[_0x183fc3('0x14')])):path['join'](_0x42d419,_['toLower'](_0x183fc3('0x50')));const _0x56b539=_0x183fc3('0x18')+_[_0x183fc3('0x1f')](_0x183fc3('0x14'));(_0x5130f9[_0x56b539]||!_0x272a5c[_0x183fc3('0x25')])&&(_0x5dd405=path[_0x183fc3('0xa')](_0x42d419,_[_0x183fc3('0xc')](_0x183fc3('0x50'))));if(!fs['existsSync'](_0x5dd405))throw new ValidationError(_['upperFirst'](_0x183fc3('0x14'))+_0x183fc3('0x3c'));return _0x30b939['download'](_0x5dd405);}})[_0x434c09('0x24')](handleError(_0x30b939,null));},exports['getLogoLogin']=function(_0x101ac6,_0x5030e9){const _0x5e2b7a=_0x26816d,_0x577822=path['join'](config[_0x5e2b7a('0x16')],_0x5e2b7a('0x9'));let _0x56e152={'custom':![]};return utilLicense[_0x5e2b7a('0x4c')]()[_0x5e2b7a('0x43')](function(_0x50f70f){const _0x34a535=_0x5e2b7a;return _0x50f70f&&(_0x56e152=_0x50f70f),db['Setting'][_0x34a535('0x2f')]({'where':{'id':_0x101ac6[_0x34a535('0x38')]['id']},'attributes':[_0x34a535('0x14'),_0x34a535('0x4b'),_0x34a535('0x32'),'favicon',_0x34a535('0x27'),_0x34a535('0x8'),_0x34a535('0x28'),'defaultFavicon'],'raw':!![]});})['then'](handleEntityNotFound(_0x5030e9,null))[_0x5e2b7a('0x43')](function(_0x3d72ec){const _0x11aacf=_0x5e2b7a;if(_0x3d72ec){let _0x35d6bd=_0x3d72ec['loginLogo']&&fs[_0x11aacf('0x12')](path['join'](_0x577822,_[_0x11aacf('0xc')](_0x3d72ec[_0x11aacf('0x4b')])))?path[_0x11aacf('0xa')](_0x577822,_[_0x11aacf('0xc')](_0x3d72ec['loginLogo'])):path[_0x11aacf('0xa')](_0x577822,_[_0x11aacf('0xc')](_0x11aacf('0x4d')));const _0x49b83e=_0x11aacf('0x18')+_[_0x11aacf('0x1f')](_0x11aacf('0x4b'));(_0x3d72ec[_0x49b83e]||!_0x56e152[_0x11aacf('0x25')])&&(_0x35d6bd=path[_0x11aacf('0xa')](_0x577822,_[_0x11aacf('0xc')]('default_loginLogo.svg')));if(!fs[_0x11aacf('0x12')](_0x35d6bd))throw new ValidationError(_[_0x11aacf('0x1f')](_0x11aacf('0x4b'))+'\x20not\x20found');return _0x5030e9['download'](_0x35d6bd);}})[_0x5e2b7a('0x24')](handleError(_0x5030e9,null));},exports['gdpr']=function(_0x4647a6,_0x534932){const _0x2967a0=_0x26816d;return db[_0x2967a0('0x5')][_0x2967a0('0x2f')]({'where':{'id':_0x4647a6[_0x2967a0('0x38')]['id']},'attributes':['securePassword']})['then'](respondWithResult(_0x534932,null))[_0x2967a0('0x24')](handleError(_0x534932,null));},exports['addPreferred']=function(_0x1a3701,_0x371d81){const _0x2c4703=_0x26816d;return _0x1a3701['file']&&_0x1a3701['file'][_0x2c4703('0x41')]&&(_0x1a3701[_0x2c4703('0x1c')][_0x2c4703('0x32')]=_0x1a3701['file'][_0x2c4703('0x41')]),db['Setting']['findOne']({'where':{'id':_0x1a3701['params']['id']}})[_0x2c4703('0x43')](handleEntityNotFound(_0x371d81,null))['then'](saveUpdates(_0x1a3701[_0x2c4703('0x1c')],null))[_0x2c4703('0x43')](respondWithResult(_0x371d81,null))[_0x2c4703('0x24')](handleError(_0x371d81,null));},exports[_0x26816d('0x2b')]=function(_0x27cd59,_0x5d4b9f){const _0x48945d=_0x26816d,_0x11b49f=path[_0x48945d('0xa')](config[_0x48945d('0x16')],_0x48945d('0x9'));let _0x1ca767={'custom':![]};return utilLicense[_0x48945d('0x4c')]()[_0x48945d('0x43')](function(_0x37fbb7){const _0x347d68=_0x48945d;return _0x37fbb7&&(_0x1ca767=_0x37fbb7),db[_0x347d68('0x5')][_0x347d68('0x2f')]({'where':{'id':_0x27cd59[_0x347d68('0x38')]['id']},'attributes':[_0x347d68('0x14'),_0x347d68('0x4b'),_0x347d68('0x32'),_0x347d68('0x13'),'defaultLogo','defaultLoginLogo',_0x347d68('0x28'),_0x347d68('0x3e')],'raw':!![]});})[_0x48945d('0x43')](handleEntityNotFound(_0x5d4b9f,null))[_0x48945d('0x43')](function(_0xaeee75){const _0x4e88c0=_0x48945d;if(_0xaeee75){let _0x1bff39=_0xaeee75[_0x4e88c0('0x32')]&&fs[_0x4e88c0('0x12')](path[_0x4e88c0('0xa')](_0x11b49f,_[_0x4e88c0('0xc')](_0xaeee75[_0x4e88c0('0x32')])))?path[_0x4e88c0('0xa')](_0x11b49f,_[_0x4e88c0('0xc')](_0xaeee75[_0x4e88c0('0x32')])):path['join'](_0x11b49f,_[_0x4e88c0('0xc')]('default_preferred.png'));const _0x2da60b=_0x4e88c0('0x18')+_[_0x4e88c0('0x1f')](_0x4e88c0('0x32'));(_0xaeee75[_0x2da60b]||!_0x1ca767['custom']||!_0x1ca767[_0x4e88c0('0x32')])&&(_0x1bff39=path[_0x4e88c0('0xa')](_0x11b49f,_['toLower'](_0x4e88c0('0x17'))));if(!fs['existsSync'](_0x1bff39))throw new ValidationError(_[_0x4e88c0('0x1f')](_0x4e88c0('0x32'))+'\x20not\x20found');return _0x5d4b9f[_0x4e88c0('0x2a')](_0x1bff39);}})[_0x48945d('0x24')](handleError(_0x5d4b9f,null));},exports[_0x26816d('0x1')]=function(_0x267e2d,_0x577824){const _0x54e7ce=_0x26816d;return _0x267e2d[_0x54e7ce('0x11')]&&_0x267e2d[_0x54e7ce('0x11')][_0x54e7ce('0x41')]&&(_0x267e2d[_0x54e7ce('0x1c')][_0x54e7ce('0x13')]=_0x267e2d[_0x54e7ce('0x11')]['filename']),db[_0x54e7ce('0x5')][_0x54e7ce('0x2f')]({'where':{'id':_0x267e2d[_0x54e7ce('0x38')]['id']}})[_0x54e7ce('0x43')](handleEntityNotFound(_0x577824,null))[_0x54e7ce('0x43')](saveUpdates(_0x267e2d[_0x54e7ce('0x1c')],null))['then'](respondWithResult(_0x577824,null))[_0x54e7ce('0x24')](handleError(_0x577824,null));},exports[_0x26816d('0x39')]=function(_0xf65a86,_0x4d0f43){const _0x2b2d7f=_0x26816d,_0x7e553e=path['join'](config[_0x2b2d7f('0x16')],_0x2b2d7f('0x9'));let _0x2da00e={'custom':![]};return utilLicense[_0x2b2d7f('0x4c')]()[_0x2b2d7f('0x43')](function(_0x4205be){const _0x1fc319=_0x2b2d7f;return _0x4205be&&(_0x2da00e=_0x4205be),db[_0x1fc319('0x5')][_0x1fc319('0x2f')]({'where':{'id':_0xf65a86[_0x1fc319('0x38')]['id']},'attributes':['logo','loginLogo',_0x1fc319('0x32'),_0x1fc319('0x13'),'defaultLogo',_0x1fc319('0x8'),_0x1fc319('0x28'),'defaultFavicon'],'raw':!![]});})[_0x2b2d7f('0x43')](handleEntityNotFound(_0x4d0f43,null))[_0x2b2d7f('0x43')](function(_0x6da176){const _0x350940=_0x2b2d7f;if(_0x6da176){let _0x39f362=_0x6da176['favicon']&&fs['existsSync'](path[_0x350940('0xa')](_0x7e553e,_[_0x350940('0xc')](_0x6da176[_0x350940('0x13')])))?path[_0x350940('0xa')](_0x7e553e,_[_0x350940('0xc')](_0x6da176[_0x350940('0x13')])):path[_0x350940('0xa')](_0x7e553e,_[_0x350940('0xc')](_0x350940('0x1d')));const _0x422c4f='default'+_['upperFirst'](_0x350940('0x13'));(_0x6da176[_0x422c4f]||!_0x2da00e[_0x350940('0x25')])&&(_0x39f362=path['join'](_0x7e553e,_['toLower'](_0x350940('0x1d'))));if(!fs[_0x350940('0x12')](_0x39f362))throw new ValidationError(_[_0x350940('0x1f')](_0x350940('0x13'))+_0x350940('0x3c'));return _0x4d0f43[_0x350940('0x2a')](_0x39f362);}})[_0x2b2d7f('0x24')](handleError(_0x4d0f43,null));}; \ No newline at end of file +const a538_0x1c05=['Content-Range','filename','where','loginLogo','keys','sequelize','index','options','addLogo','findOne','like','files/images/logos','join','default','../../mysqldb','undefined','toLower','existsSync','order','intersection','root','length','getFavicon','defaultLoginLogo','params','defaultLogo','file','stack','map','name','favicon','catch','body','download','default_logo.svg','show','merge','sort','VIRTUAL','../../config/logger','../../components/parsers/qs','logo','json','filter','lodash','status','attributes','securePassword','model','default_favicon.ico','error','fields','Setting','offset','upperFirst','defaultPreferred','findAll','addPreferred','path','includeAll','rawAttributes','pick','custom','getLicense','getLogoLogin','sendStatus','type','defaultFavicon','count','default_preferred.png','\x20not\x20found','then','../../config/environment','filters','limit','getPreferred','query','fieldName','key','../../config/license/util','preferred'];(function(_0x437869,_0x1c055d){const _0x54f059=function(_0x4f027e){while(--_0x4f027e){_0x437869['push'](_0x437869['shift']());}};_0x54f059(++_0x1c055d);}(a538_0x1c05,0xd7));const a538_0x54f0=function(_0x437869,_0x1c055d){_0x437869=_0x437869-0x0;let _0x54f059=a538_0x1c05[_0x437869];return _0x54f059;};const _0x525a05=a538_0x54f0;'use strict';const path=require(_0x525a05('0x5')),fs=require('fs'),_=require(_0x525a05('0x48')),qs=require(_0x525a05('0x44')),logger=require(_0x525a05('0x43'))('api'),config=require(_0x525a05('0x13')),db=require(_0x525a05('0x2a'))['db'],{Op,ValidationError}=require(_0x525a05('0x21')),utilLicense=require(_0x525a05('0x1a'));function respondWithResult(_0x4f027e,_0x31841a){return _0x31841a=_0x31841a||0xc8,function(_0x385f48){const _0x4ac78b=a538_0x54f0;if(_0x385f48)return _0x4f027e[_0x4ac78b('0x49')](_0x31841a)['json'](_0x385f48);};}function respondWithFilteredResult(_0x86abd4,_0x5ab10e){return function(_0xdb30d6){const _0x3e5c12=a538_0x54f0;if(_0xdb30d6){const _0xfd7e6e=_0xdb30d6[_0x3e5c12('0xf')],_0x5d55a0=_0x5ab10e[_0x3e5c12('0x0')];let _0x1699e1=_0x5ab10e['offset']+_0x5ab10e[_0x3e5c12('0x15')],_0x29c645;return _0x1699e1>=_0xfd7e6e?(_0x1699e1=_0xfd7e6e,_0x29c645=0xc8):_0x29c645=0xce,_0x86abd4[_0x3e5c12('0x49')](_0x29c645),_0x86abd4['set'](_0x3e5c12('0x1c'),_0x5d55a0+'-'+_0x1699e1+'/'+_0xfd7e6e)[_0x3e5c12('0x46')](_0xdb30d6);}return null;};}function saveUpdates(_0x94d81f){return function(_0x1ae2b2){const _0x56a8b0=a538_0x54f0;if(_0x1ae2b2)return _0x1ae2b2['update'](_0x94d81f)[_0x56a8b0('0x12')](function(_0x4c6448){return _0x4c6448;});return null;};}function handleEntityNotFound(_0x8857c8){return function(_0x26d0c3){const _0x2b4122=a538_0x54f0;return!_0x26d0c3&&_0x8857c8[_0x2b4122('0xc')](0x194),_0x26d0c3;};}function handleError(_0x5d729b,_0x7f1388){return _0x7f1388=_0x7f1388||0x1f4,function(_0x2bbaca){const _0x137c99=a538_0x54f0;logger[_0x137c99('0x4e')](_0x2bbaca[_0x137c99('0x37')]),_0x2bbaca['name']&&delete _0x2bbaca[_0x137c99('0x39')],_0x5d729b[_0x137c99('0x49')](_0x7f1388)['send'](_0x2bbaca);};}exports[_0x525a05('0x22')]=function(_0x128374,_0x3b09cd){const _0x356e7a=_0x525a05;let _0x3232f1={};const _0x405307={},_0x25829a={'count':0x0,'rows':[]},_0x271106=_[_0x356e7a('0x38')](db[_0x356e7a('0x50')][_0x356e7a('0x7')],function(_0x481ce4){const _0x12922c=_0x356e7a;return{'name':_0x481ce4[_0x12922c('0x18')],'type':_0x481ce4['type'][_0x12922c('0x19')]};});_0x405307[_0x356e7a('0x4c')]=_[_0x356e7a('0x38')](_0x271106,'name'),_0x405307[_0x356e7a('0x17')]=_[_0x356e7a('0x20')](_0x128374[_0x356e7a('0x17')]),_0x405307[_0x356e7a('0x14')]=_[_0x356e7a('0x2f')](_0x405307['model'],_0x405307[_0x356e7a('0x17')]),_0x3232f1[_0x356e7a('0x4a')]=_['intersection'](_0x405307[_0x356e7a('0x4c')],qs['fields'](_0x128374[_0x356e7a('0x17')][_0x356e7a('0x4f')])),_0x3232f1[_0x356e7a('0x4a')]=_0x3232f1['attributes'][_0x356e7a('0x31')]?_0x3232f1[_0x356e7a('0x4a')]:_0x405307['model'];typeof _0x128374[_0x356e7a('0x17')]['nolimit']===_0x356e7a('0x2b')&&(_0x3232f1[_0x356e7a('0x15')]=qs[_0x356e7a('0x15')](_0x128374['query'][_0x356e7a('0x15')]),_0x3232f1[_0x356e7a('0x0')]=qs[_0x356e7a('0x0')](_0x128374['query'][_0x356e7a('0x0')]));_0x3232f1[_0x356e7a('0x2e')]=qs[_0x356e7a('0x41')](_0x128374[_0x356e7a('0x17')][_0x356e7a('0x41')]),_0x3232f1[_0x356e7a('0x1e')]=qs[_0x356e7a('0x14')](_[_0x356e7a('0x8')](_0x128374[_0x356e7a('0x17')],_0x405307[_0x356e7a('0x14')]),_0x271106);_0x128374[_0x356e7a('0x17')][_0x356e7a('0x47')]&&(_0x3232f1[_0x356e7a('0x1e')]=_['merge'](_0x3232f1[_0x356e7a('0x1e')],{[Op['or']]:_['map'](_0x271106,function(_0x3977be){const _0x3a5485=_0x356e7a;if(_0x3977be[_0x3a5485('0xd')]!==_0x3a5485('0x42')){const _0x32951f={};return _0x32951f[_0x3977be['name']]={[Op[_0x3a5485('0x26')]]:'%'+_0x128374[_0x3a5485('0x17')][_0x3a5485('0x47')]+'%'},_0x32951f;}})}));_0x3232f1=_[_0x356e7a('0x40')]({},_0x3232f1,_0x128374['options']);const _0x47ba43={'where':_0x3232f1[_0x356e7a('0x1e')]};return db[_0x356e7a('0x50')][_0x356e7a('0xf')](_0x47ba43)[_0x356e7a('0x12')](function(_0x68a851){const _0x8427b7=_0x356e7a;return _0x25829a[_0x8427b7('0xf')]=_0x68a851,_0x128374['query'][_0x8427b7('0x6')]&&(_0x3232f1['include']=[{'all':!![]}]),db['Setting'][_0x8427b7('0x3')](_0x3232f1);})[_0x356e7a('0x12')](function(_0x4d66da){return _0x25829a['rows']=_0x4d66da,_0x25829a;})['then'](respondWithFilteredResult(_0x3b09cd,_0x3232f1))['catch'](handleError(_0x3b09cd,null));},exports[_0x525a05('0x3f')]=function(_0x555561,_0x37abe3){const _0xea7fb=_0x525a05;let _0x47f15c={'raw':![],'where':{'id':_0x555561[_0xea7fb('0x34')]['id']}};const _0x20e443={};return _0x20e443[_0xea7fb('0x4c')]=_[_0xea7fb('0x20')](db[_0xea7fb('0x50')][_0xea7fb('0x7')]),_0x20e443['query']=_[_0xea7fb('0x20')](_0x555561[_0xea7fb('0x17')]),_0x20e443[_0xea7fb('0x14')]=_[_0xea7fb('0x2f')](_0x20e443[_0xea7fb('0x4c')],_0x20e443['query']),_0x47f15c[_0xea7fb('0x4a')]=_[_0xea7fb('0x2f')](_0x20e443[_0xea7fb('0x4c')],qs[_0xea7fb('0x4f')](_0x555561['query'][_0xea7fb('0x4f')])),_0x47f15c[_0xea7fb('0x4a')]=_0x47f15c[_0xea7fb('0x4a')][_0xea7fb('0x31')]?_0x47f15c[_0xea7fb('0x4a')]:_0x20e443['model'],_0x555561[_0xea7fb('0x17')]['includeAll']&&(_0x47f15c['include']=[{'all':!![]}]),_0x47f15c=_['merge']({},_0x47f15c,_0x555561[_0xea7fb('0x23')]),db[_0xea7fb('0x50')]['findOne'](_0x47f15c)['then'](handleEntityNotFound(_0x37abe3,null))[_0xea7fb('0x12')](respondWithResult(_0x37abe3,null))[_0xea7fb('0x3b')](handleError(_0x37abe3,null));},exports['update']=function(_0x18b649,_0x59eb99){const _0x49dcc7=_0x525a05;return _0x18b649['body']['id']&&delete _0x18b649['body']['id'],db[_0x49dcc7('0x50')][_0x49dcc7('0x25')]({'where':{'id':_0x18b649[_0x49dcc7('0x34')]['id']}})['then'](handleEntityNotFound(_0x59eb99,null))['then'](saveUpdates(_0x18b649['body'],null))[_0x49dcc7('0x12')](respondWithResult(_0x59eb99,null))[_0x49dcc7('0x3b')](handleError(_0x59eb99,null));},exports[_0x525a05('0x24')]=function(_0x53156e,_0x2ad18a){const _0x15c245=_0x525a05;return _0x53156e[_0x15c245('0x36')]&&_0x53156e['file'][_0x15c245('0x1d')]&&(_0x53156e[_0x15c245('0x3c')]['logo']=_0x53156e[_0x15c245('0x36')][_0x15c245('0x1d')]),db[_0x15c245('0x50')][_0x15c245('0x25')]({'where':{'id':_0x53156e['params']['id']}})['then'](handleEntityNotFound(_0x2ad18a,null))[_0x15c245('0x12')](saveUpdates(_0x53156e[_0x15c245('0x3c')],null))['then'](respondWithResult(_0x2ad18a,null))['catch'](handleError(_0x2ad18a,null));},exports['addLogoLogin']=function(_0x447124,_0x2f45f6){const _0x4a12b7=_0x525a05;return _0x447124[_0x4a12b7('0x36')]&&_0x447124['file'][_0x4a12b7('0x1d')]&&(_0x447124[_0x4a12b7('0x3c')][_0x4a12b7('0x1f')]=_0x447124['file']['filename']),db['Setting'][_0x4a12b7('0x25')]({'where':{'id':_0x447124[_0x4a12b7('0x34')]['id']}})[_0x4a12b7('0x12')](handleEntityNotFound(_0x2f45f6,null))['then'](saveUpdates(_0x447124[_0x4a12b7('0x3c')],null))[_0x4a12b7('0x12')](respondWithResult(_0x2f45f6,null))[_0x4a12b7('0x3b')](handleError(_0x2f45f6,null));},exports['getLogo']=function(_0x256514,_0x35642c){const _0x74143d=_0x525a05,_0x3ea187=path['join'](config[_0x74143d('0x30')],_0x74143d('0x27'));let _0x5805d5={'custom':![]};return utilLicense[_0x74143d('0xa')]()[_0x74143d('0x12')](function(_0xc8c9b7){const _0x3d770d=_0x74143d;return _0xc8c9b7&&(_0x5805d5=_0xc8c9b7),db['Setting'][_0x3d770d('0x25')]({'where':{'id':_0x256514[_0x3d770d('0x34')]['id']},'attributes':[_0x3d770d('0x45'),_0x3d770d('0x1f'),_0x3d770d('0x1b'),_0x3d770d('0x3a'),'defaultLogo',_0x3d770d('0x33'),'defaultPreferred',_0x3d770d('0xe')],'raw':!![]});})['then'](handleEntityNotFound(_0x35642c,null))['then'](function(_0x466108){const _0x958de9=_0x74143d;if(_0x466108){let _0x422fa4=_0x466108[_0x958de9('0x45')]&&fs['existsSync'](path[_0x958de9('0x28')](_0x3ea187,_[_0x958de9('0x2c')](_0x466108[_0x958de9('0x45')])))?path[_0x958de9('0x28')](_0x3ea187,_[_0x958de9('0x2c')](_0x466108[_0x958de9('0x45')])):path[_0x958de9('0x28')](_0x3ea187,_[_0x958de9('0x2c')](_0x958de9('0x3e')));const _0x1f9eb1=_0x958de9('0x29')+_['upperFirst'](_0x958de9('0x45'));(_0x466108[_0x1f9eb1]||!_0x5805d5[_0x958de9('0x9')])&&(_0x422fa4=path[_0x958de9('0x28')](_0x3ea187,_['toLower'](_0x958de9('0x3e'))));if(!fs[_0x958de9('0x2d')](_0x422fa4))throw new ValidationError(_[_0x958de9('0x1')](_0x958de9('0x45'))+'\x20not\x20found');return _0x35642c[_0x958de9('0x3d')](_0x422fa4);}})[_0x74143d('0x3b')](handleError(_0x35642c,null));},exports[_0x525a05('0xb')]=function(_0x241b3d,_0x135725){const _0x18ef36=_0x525a05,_0x29a037=path[_0x18ef36('0x28')](config[_0x18ef36('0x30')],_0x18ef36('0x27'));let _0x892f1a={'custom':![]};return utilLicense[_0x18ef36('0xa')]()[_0x18ef36('0x12')](function(_0x4fda3d){const _0x2c6c1d=_0x18ef36;return _0x4fda3d&&(_0x892f1a=_0x4fda3d),db[_0x2c6c1d('0x50')][_0x2c6c1d('0x25')]({'where':{'id':_0x241b3d[_0x2c6c1d('0x34')]['id']},'attributes':[_0x2c6c1d('0x45'),'loginLogo','preferred',_0x2c6c1d('0x3a'),'defaultLogo',_0x2c6c1d('0x33'),'defaultPreferred',_0x2c6c1d('0xe')],'raw':!![]});})[_0x18ef36('0x12')](handleEntityNotFound(_0x135725,null))[_0x18ef36('0x12')](function(_0x13f77d){const _0x496220=_0x18ef36;if(_0x13f77d){let _0x51b24b=_0x13f77d['loginLogo']&&fs[_0x496220('0x2d')](path['join'](_0x29a037,_[_0x496220('0x2c')](_0x13f77d['loginLogo'])))?path['join'](_0x29a037,_[_0x496220('0x2c')](_0x13f77d[_0x496220('0x1f')])):path[_0x496220('0x28')](_0x29a037,_[_0x496220('0x2c')]('default_loginLogo.svg'));const _0x3ffbf6='default'+_[_0x496220('0x1')](_0x496220('0x1f'));(_0x13f77d[_0x3ffbf6]||!_0x892f1a['custom'])&&(_0x51b24b=path[_0x496220('0x28')](_0x29a037,_[_0x496220('0x2c')]('default_loginLogo.svg')));if(!fs[_0x496220('0x2d')](_0x51b24b))throw new ValidationError(_[_0x496220('0x1')](_0x496220('0x1f'))+_0x496220('0x11'));return _0x135725['download'](_0x51b24b);}})[_0x18ef36('0x3b')](handleError(_0x135725,null));},exports['gdpr']=function(_0x5b5633,_0x1a5195){const _0x4a8610=_0x525a05;return db['Setting'][_0x4a8610('0x25')]({'where':{'id':_0x5b5633['params']['id']},'attributes':[_0x4a8610('0x4b')]})['then'](respondWithResult(_0x1a5195,null))[_0x4a8610('0x3b')](handleError(_0x1a5195,null));},exports[_0x525a05('0x4')]=function(_0x4ab897,_0xe3cec9){const _0x282988=_0x525a05;return _0x4ab897[_0x282988('0x36')]&&_0x4ab897[_0x282988('0x36')][_0x282988('0x1d')]&&(_0x4ab897[_0x282988('0x3c')][_0x282988('0x1b')]=_0x4ab897[_0x282988('0x36')][_0x282988('0x1d')]),db[_0x282988('0x50')][_0x282988('0x25')]({'where':{'id':_0x4ab897['params']['id']}})['then'](handleEntityNotFound(_0xe3cec9,null))[_0x282988('0x12')](saveUpdates(_0x4ab897[_0x282988('0x3c')],null))[_0x282988('0x12')](respondWithResult(_0xe3cec9,null))[_0x282988('0x3b')](handleError(_0xe3cec9,null));},exports[_0x525a05('0x16')]=function(_0x5768a1,_0x5af909){const _0x3e0ca9=_0x525a05,_0x104dae=path['join'](config[_0x3e0ca9('0x30')],_0x3e0ca9('0x27'));let _0x5735f8={'custom':![]};return utilLicense[_0x3e0ca9('0xa')]()[_0x3e0ca9('0x12')](function(_0x1cac2e){const _0x1f15ca=_0x3e0ca9;return _0x1cac2e&&(_0x5735f8=_0x1cac2e),db['Setting'][_0x1f15ca('0x25')]({'where':{'id':_0x5768a1['params']['id']},'attributes':[_0x1f15ca('0x45'),'loginLogo',_0x1f15ca('0x1b'),_0x1f15ca('0x3a'),_0x1f15ca('0x35'),'defaultLoginLogo',_0x1f15ca('0x2'),_0x1f15ca('0xe')],'raw':!![]});})[_0x3e0ca9('0x12')](handleEntityNotFound(_0x5af909,null))[_0x3e0ca9('0x12')](function(_0x17467c){const _0x4bff05=_0x3e0ca9;if(_0x17467c){let _0x37e525=_0x17467c[_0x4bff05('0x1b')]&&fs[_0x4bff05('0x2d')](path[_0x4bff05('0x28')](_0x104dae,_[_0x4bff05('0x2c')](_0x17467c['preferred'])))?path[_0x4bff05('0x28')](_0x104dae,_[_0x4bff05('0x2c')](_0x17467c['preferred'])):path[_0x4bff05('0x28')](_0x104dae,_[_0x4bff05('0x2c')](_0x4bff05('0x10')));const _0x185400=_0x4bff05('0x29')+_[_0x4bff05('0x1')](_0x4bff05('0x1b'));(_0x17467c[_0x185400]||!_0x5735f8[_0x4bff05('0x9')]||!_0x5735f8[_0x4bff05('0x1b')])&&(_0x37e525=path[_0x4bff05('0x28')](_0x104dae,_[_0x4bff05('0x2c')](_0x4bff05('0x10'))));if(!fs['existsSync'](_0x37e525))throw new ValidationError(_[_0x4bff05('0x1')]('preferred')+_0x4bff05('0x11'));return _0x5af909['download'](_0x37e525);}})[_0x3e0ca9('0x3b')](handleError(_0x5af909,null));},exports['addFavicon']=function(_0x1e29cb,_0x219c9f){const _0x4fea86=_0x525a05;return _0x1e29cb[_0x4fea86('0x36')]&&_0x1e29cb['file'][_0x4fea86('0x1d')]&&(_0x1e29cb[_0x4fea86('0x3c')][_0x4fea86('0x3a')]=_0x1e29cb[_0x4fea86('0x36')][_0x4fea86('0x1d')]),db['Setting']['findOne']({'where':{'id':_0x1e29cb[_0x4fea86('0x34')]['id']}})[_0x4fea86('0x12')](handleEntityNotFound(_0x219c9f,null))[_0x4fea86('0x12')](saveUpdates(_0x1e29cb[_0x4fea86('0x3c')],null))[_0x4fea86('0x12')](respondWithResult(_0x219c9f,null))[_0x4fea86('0x3b')](handleError(_0x219c9f,null));},exports[_0x525a05('0x32')]=function(_0x4ba2c8,_0x1b7016){const _0x1432a8=_0x525a05,_0x4b70a0=path['join'](config[_0x1432a8('0x30')],_0x1432a8('0x27'));let _0x3e9286={'custom':![]};return utilLicense[_0x1432a8('0xa')]()[_0x1432a8('0x12')](function(_0x338361){const _0x3a399a=_0x1432a8;return _0x338361&&(_0x3e9286=_0x338361),db[_0x3a399a('0x50')]['findOne']({'where':{'id':_0x4ba2c8[_0x3a399a('0x34')]['id']},'attributes':[_0x3a399a('0x45'),_0x3a399a('0x1f'),_0x3a399a('0x1b'),_0x3a399a('0x3a'),'defaultLogo',_0x3a399a('0x33'),'defaultPreferred',_0x3a399a('0xe')],'raw':!![]});})[_0x1432a8('0x12')](handleEntityNotFound(_0x1b7016,null))['then'](function(_0xd8c71a){const _0x155883=_0x1432a8;if(_0xd8c71a){let _0x60dabb=_0xd8c71a['favicon']&&fs[_0x155883('0x2d')](path[_0x155883('0x28')](_0x4b70a0,_[_0x155883('0x2c')](_0xd8c71a[_0x155883('0x3a')])))?path[_0x155883('0x28')](_0x4b70a0,_[_0x155883('0x2c')](_0xd8c71a[_0x155883('0x3a')])):path[_0x155883('0x28')](_0x4b70a0,_[_0x155883('0x2c')](_0x155883('0x4d')));const _0x3683d2='default'+_['upperFirst'](_0x155883('0x3a'));(_0xd8c71a[_0x3683d2]||!_0x3e9286[_0x155883('0x9')])&&(_0x60dabb=path[_0x155883('0x28')](_0x4b70a0,_[_0x155883('0x2c')](_0x155883('0x4d'))));if(!fs['existsSync'](_0x60dabb))throw new ValidationError(_['upperFirst'](_0x155883('0x3a'))+_0x155883('0x11'));return _0x1b7016[_0x155883('0x3d')](_0x60dabb);}})['catch'](handleError(_0x1b7016,null));}; \ No newline at end of file diff --git a/server/api/setting/setting.model.js b/server/api/setting/setting.model.js index 0081af2..b5474f7 100644 --- a/server/api/setting/setting.model.js +++ b/server/api/setting/setting.model.js @@ -1 +1 @@ -const a539_0x303b=['Setting','exports','./setting.attributes','define','settings'];(function(_0x2756e7,_0x303b60){const _0x141cb0=function(_0x49730e){while(--_0x49730e){_0x2756e7['push'](_0x2756e7['shift']());}};_0x141cb0(++_0x303b60);}(a539_0x303b,0x13f));const a539_0x141c=function(_0x2756e7,_0x303b60){_0x2756e7=_0x2756e7-0x0;let _0x141cb0=a539_0x303b[_0x2756e7];return _0x141cb0;};const _0x52d34a=a539_0x141c;'use strict';const attributes=require(_0x52d34a('0x3'));module[_0x52d34a('0x2')]=function(_0x49730e){const _0x343332=_0x52d34a,_0x2b8b5e=_0x49730e[_0x343332('0x4')](_0x343332('0x1'),attributes,{'tableName':_0x343332('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2b8b5e;}; \ No newline at end of file +const a539_0x116c=['./setting.attributes','settings','define','exports','Setting'];(function(_0x15f183,_0x116c50){const _0x48e4fb=function(_0x2735a2){while(--_0x2735a2){_0x15f183['push'](_0x15f183['shift']());}};_0x48e4fb(++_0x116c50);}(a539_0x116c,0xe4));const a539_0x48e4=function(_0x15f183,_0x116c50){_0x15f183=_0x15f183-0x0;let _0x48e4fb=a539_0x116c[_0x15f183];return _0x48e4fb;};const _0x56cdd9=a539_0x48e4;'use strict';const attributes=require(_0x56cdd9('0x2'));module[_0x56cdd9('0x0')]=function(_0x2735a2){const _0xcad84b=_0x56cdd9,_0x226e01=_0x2735a2[_0xcad84b('0x4')](_0xcad84b('0x1'),attributes,{'tableName':_0xcad84b('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x226e01;}; \ No newline at end of file diff --git a/server/api/smsAccount/index.js b/server/api/smsAccount/index.js index a4b7733..288ff78 100644 --- a/server/api/smsAccount/index.js +++ b/server/api/smsAccount/index.js @@ -1 +1 @@ -const a540_0x29e2=['create','removeDispositions','/describe','removeAnswers','/:id/notify','update','show','addAnswer','index','describe','delete','addDisposition','/:id/interactions','getApplications','addApplications','/:id/send','addAgents','statusGet','notify','/:id/applications','../../components/auth/service','/:id/status','express','getAgents','exports','/:id/users','post','/:id/dispositions','./smsAccount.controller','/:id/canned_answers','get','status','put','removeAgents','/:id','isAuthenticated','Router'];(function(_0x1f0e24,_0x29e2d3){const _0x5c48af=function(_0x22d738){while(--_0x22d738){_0x1f0e24['push'](_0x1f0e24['shift']());}};_0x5c48af(++_0x29e2d3);}(a540_0x29e2,0x145));const a540_0x5c48=function(_0x1f0e24,_0x29e2d3){_0x1f0e24=_0x1f0e24-0x0;let _0x5c48af=a540_0x29e2[_0x1f0e24];return _0x5c48af;};const _0x30801e=a540_0x5c48;'use strict';const express=require(_0x30801e('0x1e')),router=express[_0x30801e('0x7')](),auth=require(_0x30801e('0x1c')),controller=require(_0x30801e('0x24'));router[_0x30801e('0x1')]('/',auth[_0x30801e('0x6')](),controller[_0x30801e('0x10')]),router[_0x30801e('0x1')](_0x30801e('0xa'),auth[_0x30801e('0x6')](),controller[_0x30801e('0x11')]),router[_0x30801e('0x1')]('/:id',auth['isAuthenticated'](),controller[_0x30801e('0xe')]),router[_0x30801e('0x1')](_0x30801e('0x23'),auth[_0x30801e('0x6')](),controller['getDispositions']),router[_0x30801e('0x1')](_0x30801e('0x0'),auth[_0x30801e('0x6')](),controller['getAnswers']),router[_0x30801e('0x1')]('/:id/applications',auth['isAuthenticated'](),controller[_0x30801e('0x15')]),router[_0x30801e('0x1')](_0x30801e('0x14'),auth['isAuthenticated'](),controller['getInteractions']),router[_0x30801e('0x1')](_0x30801e('0x1d'),controller[_0x30801e('0x19')]),router[_0x30801e('0x1')]('/:id/users',auth['isAuthenticated'](),controller[_0x30801e('0x1f')]),router[_0x30801e('0x22')]('/',auth[_0x30801e('0x6')](),controller[_0x30801e('0x8')]),router[_0x30801e('0x22')]('/:id/dispositions',auth[_0x30801e('0x6')](),controller[_0x30801e('0x13')]),router['post']('/:id/canned_answers',auth[_0x30801e('0x6')](),controller[_0x30801e('0xf')]),router[_0x30801e('0x22')](_0x30801e('0xc'),controller[_0x30801e('0x1a')]),router[_0x30801e('0x22')](_0x30801e('0x1b'),auth[_0x30801e('0x6')](),controller[_0x30801e('0x16')]),router[_0x30801e('0x22')](_0x30801e('0x17'),auth['isAuthenticated'](),controller['send']),router[_0x30801e('0x22')](_0x30801e('0x1d'),controller[_0x30801e('0x2')]),router[_0x30801e('0x22')](_0x30801e('0x21'),auth[_0x30801e('0x6')](),controller[_0x30801e('0x18')]),router[_0x30801e('0x3')](_0x30801e('0x5'),auth[_0x30801e('0x6')](),controller[_0x30801e('0xd')]),router[_0x30801e('0x12')](_0x30801e('0x5'),auth[_0x30801e('0x6')](),controller['destroy']),router[_0x30801e('0x12')](_0x30801e('0x23'),auth[_0x30801e('0x6')](),controller[_0x30801e('0x9')]),router[_0x30801e('0x12')](_0x30801e('0x0'),auth['isAuthenticated'](),controller[_0x30801e('0xb')]),router['delete'](_0x30801e('0x21'),auth[_0x30801e('0x6')](),controller[_0x30801e('0x4')]),module[_0x30801e('0x20')]=router; \ No newline at end of file +const a540_0x34a9=['/:id/interactions','/describe','getDispositions','post','show','get','put','/:id/dispositions','getApplications','/:id/notify','send','Router','describe','getAnswers','removeAnswers','/:id/applications','/:id/users','/:id','addAgents','/:id/canned_answers','/:id/status','./smsAccount.controller','delete','removeDispositions','update','addAnswer','isAuthenticated','../../components/auth/service','statusGet'];(function(_0x39031c,_0x34a98c){const _0x2e60c8=function(_0x563202){while(--_0x563202){_0x39031c['push'](_0x39031c['shift']());}};_0x2e60c8(++_0x34a98c);}(a540_0x34a9,0x1ef));const a540_0x2e60=function(_0x39031c,_0x34a98c){_0x39031c=_0x39031c-0x0;let _0x2e60c8=a540_0x34a9[_0x39031c];return _0x2e60c8;};const _0x47bead=a540_0x2e60;'use strict';const express=require('express'),router=express[_0x47bead('0x9')](),auth=require(_0x47bead('0x19')),controller=require(_0x47bead('0x13'));router['get']('/',auth['isAuthenticated'](),controller['index']),router[_0x47bead('0x3')](_0x47bead('0x1c'),auth[_0x47bead('0x18')](),controller[_0x47bead('0xa')]),router[_0x47bead('0x3')](_0x47bead('0xf'),auth[_0x47bead('0x18')](),controller[_0x47bead('0x2')]),router['get'](_0x47bead('0x5'),auth[_0x47bead('0x18')](),controller[_0x47bead('0x0')]),router[_0x47bead('0x3')]('/:id/canned_answers',auth['isAuthenticated'](),controller[_0x47bead('0xb')]),router[_0x47bead('0x3')](_0x47bead('0xd'),auth[_0x47bead('0x18')](),controller[_0x47bead('0x6')]),router[_0x47bead('0x3')](_0x47bead('0x1b'),auth['isAuthenticated'](),controller['getInteractions']),router[_0x47bead('0x3')](_0x47bead('0x12'),controller[_0x47bead('0x1a')]),router[_0x47bead('0x3')](_0x47bead('0xe'),auth['isAuthenticated'](),controller['getAgents']),router[_0x47bead('0x1')]('/',auth[_0x47bead('0x18')](),controller['create']),router[_0x47bead('0x1')](_0x47bead('0x5'),auth[_0x47bead('0x18')](),controller['addDisposition']),router[_0x47bead('0x1')](_0x47bead('0x11'),auth['isAuthenticated'](),controller[_0x47bead('0x17')]),router['post'](_0x47bead('0x7'),controller['notify']),router[_0x47bead('0x1')](_0x47bead('0xd'),auth['isAuthenticated'](),controller['addApplications']),router['post']('/:id/send',auth[_0x47bead('0x18')](),controller[_0x47bead('0x8')]),router['post'](_0x47bead('0x12'),controller['status']),router[_0x47bead('0x1')](_0x47bead('0xe'),auth[_0x47bead('0x18')](),controller[_0x47bead('0x10')]),router[_0x47bead('0x4')](_0x47bead('0xf'),auth['isAuthenticated'](),controller[_0x47bead('0x16')]),router['delete'](_0x47bead('0xf'),auth[_0x47bead('0x18')](),controller['destroy']),router['delete'](_0x47bead('0x5'),auth[_0x47bead('0x18')](),controller[_0x47bead('0x15')]),router[_0x47bead('0x14')](_0x47bead('0x11'),auth['isAuthenticated'](),controller[_0x47bead('0xc')]),router['delete']('/:id/users',auth[_0x47bead('0x18')](),controller['removeAgents']),module['exports']=router; \ No newline at end of file diff --git a/server/api/smsAccount/smsAccount.attributes.js b/server/api/smsAccount/smsAccount.attributes.js index 3487762..3888f35 100644 --- a/server/api/smsAccount/smsAccount.attributes.js +++ b/server/api/smsAccount/smsAccount.attributes.js @@ -1 +1 @@ -const a541_0x3474=['Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}','TEXT','INTEGER','name','sequelize','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','intelepeer','setDataValue','generate','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','infobip','csc','BOOLEAN','clicksend','STRING','exports','connectel','skebby','ENUM'];(function(_0x511fe8,_0x3474c0){const _0x4c2a98=function(_0x1b8ec2){while(--_0x1b8ec2){_0x511fe8['push'](_0x511fe8['shift']());}};_0x4c2a98(++_0x3474c0);}(a541_0x3474,0xe8));const a541_0x4c2a=function(_0x511fe8,_0x3474c0){_0x511fe8=_0x511fe8-0x0;let _0x4c2a98=a541_0x3474[_0x511fe8];return _0x4c2a98;};const _0x4a5bac=a541_0x4c2a;'use strict';const Sequelize=require(_0x4a5bac('0x0')),rs=require('randomstring');module[_0x4a5bac('0xb')]={'name':{'type':Sequelize[_0x4a5bac('0xa')],'unique':_0x4a5bac('0x12'),'allowNull':![]},'key':{'type':Sequelize['STRING'],'allowNull':![]},'remote':{'type':Sequelize[_0x4a5bac('0xa')],'allowNull':![]},'token':{'type':Sequelize[_0x4a5bac('0xa')],'defaultValue':function(){const _0x61cf4c=_0x4a5bac;return rs[_0x61cf4c('0x4')]();}},'phone':{'type':Sequelize[_0x4a5bac('0xa')]},'type':{'type':Sequelize[_0x4a5bac('0xe')]('twilio',_0x4a5bac('0xd'),_0x4a5bac('0xc'),_0x4a5bac('0x9'),'plivo','clickatell',_0x4a5bac('0x7'),_0x4a5bac('0x6'),_0x4a5bac('0x2'))},'accountSid':{'type':Sequelize[_0x4a5bac('0xa')]},'authId':{'type':Sequelize[_0x4a5bac('0xa')]},'authToken':{'type':Sequelize[_0x4a5bac('0xa')]},'smsMethod':{'type':Sequelize[_0x4a5bac('0xe')]('SI','TI','GP')},'username':{'type':Sequelize[_0x4a5bac('0xa')]},'password':{'type':Sequelize[_0x4a5bac('0xa')]},'apiKey':{'type':Sequelize[_0x4a5bac('0xa')]},'senderString':{'type':Sequelize[_0x4a5bac('0xa')]},'deliveryReport':{'type':Sequelize[_0x4a5bac('0x8')],'defaultValue':![]},'description':{'type':Sequelize[_0x4a5bac('0xa')]},'notificationTemplate':{'type':Sequelize[_0x4a5bac('0x10')],'defaultValue':function(){const _0x5473ce=_0x4a5bac;return _0x5473ce('0xf');}},'notificationSound':{'type':Sequelize[_0x4a5bac('0x8')],'defaultValue':!![]},'notificationShake':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x4a5bac('0x11')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'queueTransfer':{'type':Sequelize[_0x4a5bac('0x8')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x4a5bac('0x11')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize[_0x4a5bac('0x8')],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0x4a5bac('0x11')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'baseUrl':{'type':Sequelize[_0x4a5bac('0xa')]},'mandatoryDispositionPauseId':{'type':Sequelize[_0x4a5bac('0x11')],'comment':_0x4a5bac('0x1')},'mandatoryDisposition':{'type':Sequelize[_0x4a5bac('0x8')],'defaultValue':![],'comment':_0x4a5bac('0x5'),'set':function(_0x1b8ec2){const _0x404048=_0x4a5bac;if(!_0x1b8ec2)this[_0x404048('0x3')]('mandatoryDispositionPauseId',null);this[_0x404048('0x3')]('mandatoryDisposition',_0x1b8ec2);}}}; \ No newline at end of file +const a541_0x4fec=['Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','sequelize','randomstring','mandatoryDisposition','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','exports','skebby','twilio','clickatell','csc','generate','STRING','BOOLEAN','plivo','INTEGER','setDataValue','intelepeer','ENUM','connectel'];(function(_0x1059e1,_0x4fecfb){const _0x99051a=function(_0x5d37b4){while(--_0x5d37b4){_0x1059e1['push'](_0x1059e1['shift']());}};_0x99051a(++_0x4fecfb);}(a541_0x4fec,0x1e1));const a541_0x9905=function(_0x1059e1,_0x4fecfb){_0x1059e1=_0x1059e1-0x0;let _0x99051a=a541_0x4fec[_0x1059e1];return _0x99051a;};const _0xda038e=a541_0x9905;'use strict';const Sequelize=require(_0xda038e('0xe')),rs=require(_0xda038e('0xf'));module[_0xda038e('0x12')]={'name':{'type':Sequelize['STRING'],'unique':'name','allowNull':![]},'key':{'type':Sequelize[_0xda038e('0x5')],'allowNull':![]},'remote':{'type':Sequelize[_0xda038e('0x5')],'allowNull':![]},'token':{'type':Sequelize[_0xda038e('0x5')],'defaultValue':function(){const _0x101f37=_0xda038e;return rs[_0x101f37('0x4')]();}},'phone':{'type':Sequelize['STRING']},'type':{'type':Sequelize[_0xda038e('0xb')](_0xda038e('0x1'),_0xda038e('0x0'),_0xda038e('0xc'),'clicksend',_0xda038e('0x7'),_0xda038e('0x2'),_0xda038e('0x3'),'infobip',_0xda038e('0xa'))},'accountSid':{'type':Sequelize[_0xda038e('0x5')]},'authId':{'type':Sequelize[_0xda038e('0x5')]},'authToken':{'type':Sequelize[_0xda038e('0x5')]},'smsMethod':{'type':Sequelize[_0xda038e('0xb')]('SI','TI','GP')},'username':{'type':Sequelize[_0xda038e('0x5')]},'password':{'type':Sequelize['STRING']},'apiKey':{'type':Sequelize[_0xda038e('0x5')]},'senderString':{'type':Sequelize['STRING']},'deliveryReport':{'type':Sequelize[_0xda038e('0x6')],'defaultValue':![]},'description':{'type':Sequelize['STRING']},'notificationTemplate':{'type':Sequelize['TEXT'],'defaultValue':function(){return'Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}';}},'notificationSound':{'type':Sequelize[_0xda038e('0x6')],'defaultValue':!![]},'notificationShake':{'type':Sequelize[_0xda038e('0x6')],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0xda038e('0x8')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'queueTransfer':{'type':Sequelize[_0xda038e('0x6')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0xda038e('0x8')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0xda038e('0x8')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'baseUrl':{'type':Sequelize[_0xda038e('0x5')]},'mandatoryDispositionPauseId':{'type':Sequelize[_0xda038e('0x8')],'comment':_0xda038e('0xd')},'mandatoryDisposition':{'type':Sequelize[_0xda038e('0x6')],'defaultValue':![],'comment':_0xda038e('0x11'),'set':function(_0x5d37b4){const _0x56c7ce=_0xda038e;if(!_0x5d37b4)this[_0x56c7ce('0x9')]('mandatoryDispositionPauseId',null);this[_0x56c7ce('0x9')](_0x56c7ce('0x10'),_0x5d37b4);}}}; \ No newline at end of file diff --git a/server/api/smsAccount/smsAccount.controller.js b/server/api/smsAccount/smsAccount.controller.js index 8976952..868b8cf 100644 --- a/server/api/smsAccount/smsAccount.controller.js +++ b/server/api/smsAccount/smsAccount.controller.js @@ -1 +1 @@ -const a542_0x483b=['SmsInteraction','no\x20available\x20attributes','like','Tags','getInteractions','offset','DELIVERED','api','unmanaged','received\x20delivery\x20report\x20from','merge','segmentedMessage','originatingAddress','UserProfileSection','unshift','clicksend','mandatoryDispositionPause','MessageSid','clickatell','findAll','count','ids','notify','List','user','code','SmsAccount,\x20%s,\x20%s,\x20%s','destroy','DESC','skebby','statusInt','orderBy','get','From','DELIVRD','rawAttributes','bulkCreate','Tag','CompanyId','getApplications','filters','request\x20sent','fieldName','RECEIVED_BY_RECIPIENT','text','autoclose','includes','update','Content-Range','sendStatus','sequelize','client','end','stringify','Messages','SmsAccount','intersection','statusGet','infobip','isNil','color','Disposition','VIRTUAL','params','set','jayson/promise','dataValues','./smsAccount.socket','CmList','redif','includeAll','log','debug','twilio','body','attributes','result','register','ListId','SmsAccounts','filter','then','message-id','query','rows','../../rediscache','message','User','model','*,*,*,*','defaults','getDispositions','map','nolimit','status','addDisposition','SmsAccount,\x20%s,\x20%s,\x20%s,\x20%s','findOne','stack','Applications','info','send','ContactId','csc','error_code','emit','AttachmentId','applications','describe','contact','intelepeer','getAnswers','Content-Type','connectel','keys','interaction','SmsAccountId','close','SmsApplication','asc','text/xml','waitForTheAssignedAgent','updatedAt','undefined','SmsMessage','userSmsAccount:save','pick','UserId','where','sender','create','Unable\x20to\x20retrieve\x20the\x20current\x20user','show','refid','push','SmsAccount,\x20%s,\x20%s','include','results','created','DELIVERED_TO_GATEWAY','body\x20is\x20mandatory\x20and\x20not\x20empty','CannedAnswer','tag','omit','transaction','mapKey','difference','http','removeAnswers','list','startRouting','name','error','mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','state','Contacts','priority','Pause','getAgents','skebby_dispatch_id','../../mysqldb','options','sort','addAgents','lodash','receiveMessage','fields','removeDispositions','status_code','length','limit','endpoint\x20/status\x20POST\x20/','internal','UserProfileResource','entity\x20found','requestid','findAndCountAll','inspect','type','Start','index','order','messageId','json','catch','message_id','account','Body','util','groupName','from','autoAssociation','CmContact','addApplications','replyMessageId'];(function(_0x2d206c,_0x483baa){const _0x202c05=function(_0x3dbebf){while(--_0x3dbebf){_0x2d206c['push'](_0x2d206c['shift']());}};_0x202c05(++_0x483baa);}(a542_0x483b,0x1ab));const a542_0x202c=function(_0x2d206c,_0x483baa){_0x2d206c=_0x2d206c-0x0;let _0x202c05=a542_0x483b[_0x2d206c];return _0x202c05;};const _0x43a3a8=a542_0x202c;'use strict';const util=require(_0x43a3a8('0x97')),_=require(_0x43a3a8('0x7f')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x43a3a8('0xa5')),{getSocket}=require(_0x43a3a8('0x30')),socket=getSocket(),db=require(_0x43a3a8('0x7b'))['db'],{Op,ValidationError}=require(_0x43a3a8('0xd'));require(_0x43a3a8('0x1e'))[_0x43a3a8('0x28')](socket);const jayson=require(_0x43a3a8('0x1c')),client=jayson[_0x43a3a8('0xe')][_0x43a3a8('0x6e')]({'port':0x232c});function respondWithRpcPromise(_0x3dbebf,_0x33ba7d,_0x23fa5d,_0x10639f){return new Promise(function(_0x1fad3a,_0x402cbf){const _0x3a7b59=_0x10639f||client;return _0x3a7b59['request'](_0x3dbebf,_0x23fa5d)['then'](function(_0xf24a1f){const _0x57afde=a542_0x202c;logger[_0x57afde('0x3f')](_0x57afde('0x62'),_0x33ba7d,_0x57afde('0x4')),logger[_0x57afde('0x23')]('SmsAccount,\x20%s,\x20%s,\x20%s',_0x33ba7d,_0x57afde('0x4'),JSON[_0x57afde('0x10')](_0xf24a1f));if(_0xf24a1f[_0x57afde('0x73')]){if(_0xf24a1f['error'][_0x57afde('0xb7')]===0x1f4)return logger[_0x57afde('0x73')](_0x57afde('0x62'),_0x33ba7d,_0xf24a1f[_0x57afde('0x73')][_0x57afde('0x31')]),_0x402cbf(_0xf24a1f[_0x57afde('0x73')][_0x57afde('0x31')]);return logger[_0x57afde('0x73')]('SmsAccount,\x20%s,\x20%s',_0x33ba7d,_0xf24a1f[_0x57afde('0x73')][_0x57afde('0x31')]),_0x1fad3a(_0xf24a1f['error'][_0x57afde('0x31')]);}else logger[_0x57afde('0x3f')](_0x57afde('0x62'),_0x33ba7d,_0x57afde('0x4')),_0x1fad3a(_0xf24a1f[_0x57afde('0x27')][_0x57afde('0x31')]);})['catch'](function(_0x437959){const _0x3bae87=a542_0x202c;logger[_0x3bae87('0x73')]('SmsAccount,\x20%s,\x20%s',_0x33ba7d,_0x437959),_0x402cbf(_0x437959);});});}function respondWithStatusCode(_0x13254c,_0x2b2b16){return _0x2b2b16=_0x2b2b16||0xcc,function(_0x23ab29){const _0x3bdefd=a542_0x202c;if(_0x23ab29)return _0x13254c[_0x3bdefd('0xc')](_0x2b2b16);return _0x13254c[_0x3bdefd('0x39')](_0x2b2b16)['end']();};}function respondWithResult(_0x5877bb,_0x4bb6e2){return _0x4bb6e2=_0x4bb6e2||0xc8,function(_0x48f741){const _0xfefbe5=a542_0x202c;if(_0x48f741)return _0x5877bb[_0xfefbe5('0x39')](_0x4bb6e2)['json'](_0x48f741);};}function respondWithFilteredResult(_0x2147aa,_0xb9a4e9){return function(_0x12ff5e){const _0x166508=a542_0x202c;if(_0x12ff5e){const _0x427b72=_0x12ff5e[_0x166508('0xb2')],_0x8970d5=_0xb9a4e9[_0x166508('0xa3')];let _0x57aebc=_0xb9a4e9[_0x166508('0xa3')]+_0xb9a4e9['limit'],_0x429422;return _0x57aebc>=_0x427b72?(_0x57aebc=_0x427b72,_0x429422=0xc8):_0x429422=0xce,_0x2147aa[_0x166508('0x39')](_0x429422),_0x2147aa[_0x166508('0x1b')](_0x166508('0xb'),_0x8970d5+'-'+_0x57aebc+'/'+_0x427b72)[_0x166508('0x92')](_0x12ff5e);}return null;};}function saveUpdates(_0x4271e9){return function(_0x5c0b97){const _0xb862ff=a542_0x202c;if(_0x5c0b97)return _0x5c0b97['update'](_0x4271e9)[_0xb862ff('0x2c')](function(_0x17984d){return _0x17984d;});return null;};}function removeEntity(_0x31e9dc){return function(_0x5a0b32){const _0x2aef3a=a542_0x202c;if(_0x5a0b32)return _0x5a0b32[_0x2aef3a('0xb9')]()[_0x2aef3a('0x2c')](function(){const _0x1c5355=_0x2aef3a,_0x292170=_0x5a0b32[_0x1c5355('0xbe')]({'plain':!![]}),_0x2e0adc=_0x1c5355('0x2a');return db['UserProfileResource']['destroy']({'where':{'type':_0x2e0adc,'resourceId':_0x292170['id']}})['then'](function(){return _0x5a0b32;});})['then'](function(){const _0x44fc23=_0x2aef3a;_0x31e9dc[_0x44fc23('0x39')](0xcc)[_0x44fc23('0xf')]();});};}function handleEntityNotFound(_0x1ed585){return function(_0x5cfb26){const _0x1a638d=a542_0x202c;return!_0x5cfb26&&_0x1ed585[_0x1a638d('0xc')](0x194),_0x5cfb26;};}function handleError(_0x3af1f1,_0x3e4d29){return _0x3e4d29=_0x3e4d29||0x1f4,function(_0x126468){const _0xe1afe0=a542_0x202c;logger[_0xe1afe0('0x73')](_0x126468[_0xe1afe0('0x3d')]),_0x126468[_0xe1afe0('0x72')]&&delete _0x126468['name'],_0x3af1f1[_0xe1afe0('0x39')](_0x3e4d29)[_0xe1afe0('0x40')](_0x126468);};}exports[_0x43a3a8('0x8f')]=function(_0x4fca44,_0x4f694a){const _0x304cce=_0x43a3a8;let _0x425500={'include':[{'model':db[_0x304cce('0x78')],'as':_0x304cce('0xae')}]};const _0x5665cf={},_0x5d8878={'count':0x0,'rows':[]},_0x1dc554=_[_0x304cce('0x37')](db[_0x304cce('0x12')][_0x304cce('0xc1')],function(_0x521d1c){const _0x1428c2=_0x304cce;return{'name':_0x521d1c[_0x1428c2('0x5')],'type':_0x521d1c[_0x1428c2('0x8d')]['key']};});_0x5665cf[_0x304cce('0x33')]=_['map'](_0x1dc554,_0x304cce('0x72')),_0x5665cf['query']=_[_0x304cce('0x4d')](_0x4fca44[_0x304cce('0x2e')]),_0x5665cf[_0x304cce('0x3')]=_[_0x304cce('0x13')](_0x5665cf[_0x304cce('0x33')],_0x5665cf['query']),_0x425500[_0x304cce('0x26')]=_['intersection'](_0x5665cf[_0x304cce('0x33')],qs['fields'](_0x4fca44[_0x304cce('0x2e')][_0x304cce('0x81')])),_0x425500['attributes']=_0x425500[_0x304cce('0x26')][_0x304cce('0x84')]?_0x425500[_0x304cce('0x26')]:_0x5665cf[_0x304cce('0x33')];typeof _0x4fca44['query'][_0x304cce('0x38')]===_0x304cce('0x56')&&(_0x425500[_0x304cce('0x85')]=qs['limit'](_0x4fca44[_0x304cce('0x2e')][_0x304cce('0x85')]),_0x425500[_0x304cce('0xa3')]=qs[_0x304cce('0xa3')](_0x4fca44[_0x304cce('0x2e')][_0x304cce('0xa3')]));_0x425500['order']=qs[_0x304cce('0x7d')](_0x4fca44[_0x304cce('0x2e')][_0x304cce('0x7d')]),_0x425500['where']=qs[_0x304cce('0x3')](_['pick'](_0x4fca44[_0x304cce('0x2e')],_0x5665cf['filters']),_0x1dc554);_0x4fca44[_0x304cce('0x2e')][_0x304cce('0x2b')]&&(_0x425500[_0x304cce('0x5b')]=_[_0x304cce('0xa8')](_0x425500[_0x304cce('0x5b')],{[Op['or']]:_[_0x304cce('0x37')](_0x1dc554,function(_0x20b6ce){const _0x282dc8=_0x304cce;if(_0x20b6ce[_0x282dc8('0x8d')]!==_0x282dc8('0x19')){const _0x315ad5={};return _0x315ad5[_0x20b6ce[_0x282dc8('0x72')]]={[Op[_0x282dc8('0xa0')]]:'%'+_0x4fca44['query'][_0x282dc8('0x2b')]+'%'},_0x315ad5;}})}));_0x425500=_[_0x304cce('0xa8')]({},_0x425500,_0x4fca44['options']);const _0x5ce1bb={'where':_0x425500[_0x304cce('0x5b')]};return db['SmsAccount']['count'](_0x5ce1bb)[_0x304cce('0x2c')](function(_0x451800){const _0x593af4=_0x304cce;return _0x5d8878['count']=_0x451800,_0x4fca44[_0x593af4('0x2e')][_0x593af4('0x21')]&&(_0x425500[_0x593af4('0x63')]=[{'all':!![]}]),db['SmsAccount']['findAll'](_0x425500);})[_0x304cce('0x2c')](function(_0x43b04d){const _0x4785ea=_0x304cce;return _0x5d8878[_0x4785ea('0x2f')]=_0x43b04d,_0x5d8878;})[_0x304cce('0x2c')](respondWithFilteredResult(_0x4f694a,_0x425500))[_0x304cce('0x93')](handleError(_0x4f694a,null));},exports[_0x43a3a8('0x5f')]=function(_0x16e89e,_0x12960b){const _0x5b9804=_0x43a3a8;let _0x4213fc={'raw':![],'where':{'id':_0x16e89e['params']['id']},'include':[{'model':db['Pause'],'as':_0x5b9804('0xae')}]};const _0x72d6e7={};return _0x72d6e7[_0x5b9804('0x33')]=_[_0x5b9804('0x4d')](db[_0x5b9804('0x12')][_0x5b9804('0xc1')]),_0x72d6e7[_0x5b9804('0x2e')]=_['keys'](_0x16e89e[_0x5b9804('0x2e')]),_0x72d6e7[_0x5b9804('0x3')]=_[_0x5b9804('0x13')](_0x72d6e7[_0x5b9804('0x33')],_0x72d6e7[_0x5b9804('0x2e')]),_0x4213fc[_0x5b9804('0x26')]=_[_0x5b9804('0x13')](_0x72d6e7[_0x5b9804('0x33')],qs[_0x5b9804('0x81')](_0x16e89e[_0x5b9804('0x2e')][_0x5b9804('0x81')])),_0x4213fc[_0x5b9804('0x26')]=_0x4213fc[_0x5b9804('0x26')][_0x5b9804('0x84')]?_0x4213fc['attributes']:_0x72d6e7[_0x5b9804('0x33')],_0x16e89e[_0x5b9804('0x2e')][_0x5b9804('0x21')]&&(_0x4213fc[_0x5b9804('0x63')]=[{'all':!![]}]),_0x4213fc=_[_0x5b9804('0xa8')]({},_0x4213fc,_0x16e89e[_0x5b9804('0x7c')]),db[_0x5b9804('0x12')][_0x5b9804('0x3c')](_0x4213fc)[_0x5b9804('0x2c')](handleEntityNotFound(_0x12960b,null))[_0x5b9804('0x2c')](respondWithResult(_0x12960b,null))[_0x5b9804('0x93')](handleError(_0x12960b,null));},exports[_0x43a3a8('0x5d')]=function(_0x2b7b80,_0x593351){const _0x18fa5e=_0x43a3a8;return db[_0x18fa5e('0x12')][_0x18fa5e('0x5d')](_0x2b7b80[_0x18fa5e('0x25')],{})[_0x18fa5e('0x2c')](function(_0x3e3a62){const _0x14dd52=_0x18fa5e,_0xe757c0=_0x2b7b80[_0x14dd52('0xb6')][_0x14dd52('0xbe')]({'plain':!![]});if(!_0xe757c0)throw new Error(_0x14dd52('0x5e'));if(_0xe757c0['role']===_0x14dd52('0xb6')){const _0x323e3d=_0x3e3a62[_0x14dd52('0xbe')]({'plain':!![]}),_0x194316=_0x14dd52('0x2a');return db[_0x14dd52('0xab')][_0x14dd52('0x3c')]({'where':{'name':_0x194316,'userProfileId':_0xe757c0['userProfileId']},'raw':!![]})['then'](function(_0x5a7e3f){const _0x273eaf=_0x14dd52;return _0x5a7e3f&&_0x5a7e3f[_0x273eaf('0x9a')]===0x0?db[_0x273eaf('0x88')][_0x273eaf('0x5d')]({'name':_0x323e3d[_0x273eaf('0x72')],'resourceId':_0x323e3d['id'],'type':_0x5a7e3f['name'],'sectionId':_0x5a7e3f['id']},{})['then'](function(){return _0x3e3a62;}):_0x3e3a62;})[_0x14dd52('0x93')](function(_0x34a60a){const _0xf22f86=_0x14dd52;logger[_0xf22f86('0x73')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x34a60a);throw _0x34a60a;});}return _0x3e3a62;})['then'](respondWithResult(_0x593351,0xc9))[_0x18fa5e('0x93')](handleError(_0x593351,null));},exports[_0x43a3a8('0xa')]=function(_0x27ceec,_0x2346d4){const _0x18467e=_0x43a3a8;return _0x27ceec[_0x18467e('0x25')]['id']&&delete _0x27ceec['body']['id'],db[_0x18467e('0x12')][_0x18467e('0x3c')]({'where':{'id':_0x27ceec[_0x18467e('0x1a')]['id']},'include':[{'model':db[_0x18467e('0x78')],'as':_0x18467e('0xae')}]})[_0x18467e('0x2c')](handleEntityNotFound(_0x2346d4,null))[_0x18467e('0x2c')](saveUpdates(_0x27ceec[_0x18467e('0x25')],null))[_0x18467e('0x2c')](respondWithResult(_0x2346d4,null))[_0x18467e('0x93')](handleError(_0x2346d4,null));},exports[_0x43a3a8('0xb9')]=function(_0x2d80aa,_0x15d6a0){const _0x3709fd=_0x43a3a8;return db[_0x3709fd('0x12')][_0x3709fd('0x3c')]({'where':{'id':_0x2d80aa[_0x3709fd('0x1a')]['id']}})['then'](handleEntityNotFound(_0x15d6a0,null))[_0x3709fd('0x2c')](removeEntity(_0x15d6a0,null))[_0x3709fd('0x93')](handleError(_0x15d6a0,null));},exports['describe']=function(_0x454580,_0x416629){const _0x1ab83d=_0x43a3a8;return db[_0x1ab83d('0x12')][_0x1ab83d('0x47')]()[_0x1ab83d('0x2c')](respondWithResult(_0x416629,null))['catch'](handleError(_0x416629,null));},exports[_0x43a3a8('0x3a')]=function(_0x200c13,_0x5bf7af){const _0x2190b1=_0x43a3a8;return _0x200c13[_0x2190b1('0x25')]['id']&&delete _0x200c13['body']['id'],db[_0x2190b1('0x12')][_0x2190b1('0x3c')]({'where':{'id':_0x200c13[_0x2190b1('0x1a')]['id']}})[_0x2190b1('0x2c')](handleEntityNotFound(_0x5bf7af,null))[_0x2190b1('0x2c')](function(_0x34be7f){const _0x506367=_0x2190b1;if(_0x34be7f)return _0x200c13[_0x506367('0x25')][_0x506367('0x4f')]=_0x34be7f['id'],db['Disposition'][_0x506367('0x5d')](_0x200c13['body']);})['then'](respondWithResult(_0x5bf7af,null))[_0x2190b1('0x93')](handleError(_0x5bf7af,null));},exports[_0x43a3a8('0x36')]=function(_0x13624a,_0x31a337){const _0x1a9abb=_0x43a3a8;let _0x39ef98={'raw':![],'where':{}};const _0x3b2aa6={},_0x196f0f={'count':0x0,'rows':[]};return db[_0x1a9abb('0x12')]['findOne']({'where':{'id':_0x13624a[_0x1a9abb('0x1a')]['id']}})[_0x1a9abb('0x2c')](handleEntityNotFound(_0x31a337,null))['then'](function(_0x4731ca){const _0x403c15=_0x1a9abb;if(_0x4731ca)return _0x3b2aa6[_0x403c15('0x33')]=_[_0x403c15('0x4d')](db[_0x403c15('0x18')][_0x403c15('0xc1')]),_0x3b2aa6['query']=_['keys'](_0x13624a[_0x403c15('0x2e')]),_0x3b2aa6['filters']=_['intersection'](_0x3b2aa6[_0x403c15('0x33')],_0x3b2aa6['query']),_0x39ef98[_0x403c15('0x26')]=_[_0x403c15('0x13')](_0x3b2aa6[_0x403c15('0x33')],qs[_0x403c15('0x81')](_0x13624a[_0x403c15('0x2e')][_0x403c15('0x81')])),_0x39ef98[_0x403c15('0x26')]=_0x39ef98[_0x403c15('0x26')][_0x403c15('0x84')]?_0x39ef98[_0x403c15('0x26')]:_0x3b2aa6[_0x403c15('0x33')],typeof _0x13624a[_0x403c15('0x2e')][_0x403c15('0x38')]==='undefined'&&(_0x39ef98[_0x403c15('0x85')]=qs['limit'](_0x13624a['query']['limit']),_0x39ef98['offset']=qs[_0x403c15('0xa3')](_0x13624a[_0x403c15('0x2e')][_0x403c15('0xa3')])),_0x39ef98[_0x403c15('0x90')]=qs[_0x403c15('0x7d')](_0x13624a[_0x403c15('0x2e')][_0x403c15('0x7d')]),_0x39ef98['where']=qs[_0x403c15('0x3')](_[_0x403c15('0x59')](_0x13624a[_0x403c15('0x2e')],_0x3b2aa6['filters'])),_0x39ef98[_0x403c15('0x5b')][_0x403c15('0x4f')]=_0x4731ca['id'],_0x13624a['query'][_0x403c15('0x2b')]&&(_0x39ef98[_0x403c15('0x5b')]=_[_0x403c15('0xa8')](_0x39ef98[_0x403c15('0x5b')],{[Op['or']]:_[_0x403c15('0x37')](_0x39ef98[_0x403c15('0x26')],function(_0x47b99c){const _0x56a63b=_0x403c15,_0x10e8c3={};return _0x10e8c3[_0x47b99c]={[Op['like']]:'%'+_0x13624a['query'][_0x56a63b('0x2b')]+'%'},_0x10e8c3;})})),_0x39ef98=_['merge']({},_0x39ef98,_0x13624a[_0x403c15('0x7c')]),db[_0x403c15('0x18')]['count']({'where':_0x39ef98[_0x403c15('0x5b')]})['then'](function(_0x1eb6cd){const _0x2a6099=_0x403c15;return _0x196f0f[_0x2a6099('0xb2')]=_0x1eb6cd,_0x13624a['query'][_0x2a6099('0x21')]&&(_0x39ef98['include']=[{'all':!![]}]),db['Disposition'][_0x2a6099('0xb1')](_0x39ef98);})[_0x403c15('0x2c')](function(_0x24cb4b){const _0x5a7398=_0x403c15;return _0x196f0f[_0x5a7398('0x2f')]=_0x24cb4b,_0x196f0f;});})[_0x1a9abb('0x2c')](respondWithFilteredResult(_0x31a337,_0x39ef98))[_0x1a9abb('0x93')](handleError(_0x31a337,null));},exports[_0x43a3a8('0x82')]=function(_0x3f1227,_0x2c5cd5){const _0x16b942=_0x43a3a8;return db['SmsAccount'][_0x16b942('0x3c')]({'where':{'id':_0x3f1227[_0x16b942('0x1a')]['id']}})['then'](handleEntityNotFound(_0x2c5cd5,null))['then'](function(_0x49c479){const _0x57d5eb=_0x16b942;if(_0x49c479)return _0x49c479[_0x57d5eb('0x82')](_0x3f1227[_0x57d5eb('0x2e')][_0x57d5eb('0xb3')]);})[_0x16b942('0x2c')](respondWithStatusCode(_0x2c5cd5,null))[_0x16b942('0x93')](handleError(_0x2c5cd5,null));},exports['addAnswer']=function(_0x4bf25b,_0x5420ec){const _0x3b2ab4=_0x43a3a8;return _0x4bf25b[_0x3b2ab4('0x25')]['id']&&delete _0x4bf25b[_0x3b2ab4('0x25')]['id'],db['SmsAccount']['findOne']({'where':{'id':_0x4bf25b[_0x3b2ab4('0x1a')]['id']}})[_0x3b2ab4('0x2c')](handleEntityNotFound(_0x5420ec,null))[_0x3b2ab4('0x2c')](function(_0x1bedfd){const _0x158029=_0x3b2ab4;if(_0x1bedfd)return _0x4bf25b[_0x158029('0x25')][_0x158029('0x4f')]=_0x1bedfd['id'],db['CannedAnswer'][_0x158029('0x5d')](_0x4bf25b[_0x158029('0x25')]);})[_0x3b2ab4('0x2c')](respondWithResult(_0x5420ec,null))[_0x3b2ab4('0x93')](handleError(_0x5420ec,null));},exports[_0x43a3a8('0x4a')]=function(_0xc4708a,_0x328937){const _0xe711e9=_0x43a3a8;let _0x211267={'raw':![],'where':{}};const _0x23a0e8={},_0x3197db={'count':0x0,'rows':[]};return db[_0xe711e9('0x12')][_0xe711e9('0x3c')]({'where':{'id':_0xc4708a['params']['id']}})[_0xe711e9('0x2c')](handleEntityNotFound(_0x328937,null))[_0xe711e9('0x2c')](function(_0x21ef25){const _0x4a51bd=_0xe711e9;if(_0x21ef25)return _0x23a0e8[_0x4a51bd('0x33')]=_[_0x4a51bd('0x4d')](db[_0x4a51bd('0x68')][_0x4a51bd('0xc1')]),_0x23a0e8['query']=_[_0x4a51bd('0x4d')](_0xc4708a['query']),_0x23a0e8[_0x4a51bd('0x3')]=_[_0x4a51bd('0x13')](_0x23a0e8['model'],_0x23a0e8[_0x4a51bd('0x2e')]),_0x211267[_0x4a51bd('0x26')]=_['intersection'](_0x23a0e8[_0x4a51bd('0x33')],qs[_0x4a51bd('0x81')](_0xc4708a['query'][_0x4a51bd('0x81')])),_0x211267['attributes']=_0x211267['attributes'][_0x4a51bd('0x84')]?_0x211267[_0x4a51bd('0x26')]:_0x23a0e8[_0x4a51bd('0x33')],typeof _0xc4708a[_0x4a51bd('0x2e')]['nolimit']==='undefined'&&(_0x211267[_0x4a51bd('0x85')]=qs[_0x4a51bd('0x85')](_0xc4708a[_0x4a51bd('0x2e')][_0x4a51bd('0x85')]),_0x211267['offset']=qs[_0x4a51bd('0xa3')](_0xc4708a['query']['offset'])),_0x211267[_0x4a51bd('0x90')]=qs['sort'](_0xc4708a['query'][_0x4a51bd('0x7d')]),_0x211267['where']=qs[_0x4a51bd('0x3')](_[_0x4a51bd('0x59')](_0xc4708a[_0x4a51bd('0x2e')],_0x23a0e8[_0x4a51bd('0x3')])),_0x211267[_0x4a51bd('0x5b')][_0x4a51bd('0x4f')]=_0x21ef25['id'],_0xc4708a[_0x4a51bd('0x2e')]['filter']&&(_0x211267[_0x4a51bd('0x5b')]=_[_0x4a51bd('0xa8')](_0x211267[_0x4a51bd('0x5b')],{[Op['or']]:_[_0x4a51bd('0x37')](_0x211267['attributes'],function(_0x31e3d1){const _0x4e082d=_0x4a51bd,_0x1662c8={};return _0x1662c8[_0x31e3d1]={[Op[_0x4e082d('0xa0')]]:'%'+_0xc4708a['query'][_0x4e082d('0x2b')]+'%'},_0x1662c8;})})),_0x211267=_[_0x4a51bd('0xa8')]({},_0x211267,_0xc4708a[_0x4a51bd('0x7c')]),db['CannedAnswer'][_0x4a51bd('0xb2')]({'where':_0x211267[_0x4a51bd('0x5b')]})['then'](function(_0x485d3d){const _0x3f0c30=_0x4a51bd;return _0x3197db['count']=_0x485d3d,_0xc4708a[_0x3f0c30('0x2e')][_0x3f0c30('0x21')]&&(_0x211267[_0x3f0c30('0x63')]=[{'all':!![]}]),db[_0x3f0c30('0x68')]['findAll'](_0x211267);})[_0x4a51bd('0x2c')](function(_0x404405){const _0x54a7a7=_0x4a51bd;return _0x3197db[_0x54a7a7('0x2f')]=_0x404405,_0x3197db;});})[_0xe711e9('0x2c')](respondWithFilteredResult(_0x328937,_0x211267))[_0xe711e9('0x93')](handleError(_0x328937,null));},exports[_0x43a3a8('0x6f')]=function(_0x433fe6,_0x4f7b47){const _0x1317bf=_0x43a3a8;return db[_0x1317bf('0x12')][_0x1317bf('0x3c')]({'where':{'id':_0x433fe6[_0x1317bf('0x1a')]['id']}})['then'](handleEntityNotFound(_0x4f7b47,null))[_0x1317bf('0x2c')](function(_0x5c1370){const _0x260497=_0x1317bf;if(_0x5c1370)return _0x5c1370[_0x260497('0x6f')](_0x433fe6[_0x260497('0x2e')][_0x260497('0xb3')]);})[_0x1317bf('0x2c')](respondWithStatusCode(_0x4f7b47,null))['catch'](handleError(_0x4f7b47,null));},exports[_0x43a3a8('0xb4')]=function(_0xd063da,_0x415754){const _0x123323=_0x43a3a8,_0x1cbbd2={'channel':'sms'};let _0x2a6d1f=[],_0x171761=[];const _0x5705de={};return db[_0x123323('0x12')][_0x123323('0x3c')]({'where':{'id':_0xd063da['params']['id']},'include':[{'model':db['SmsApplication'],'as':_0x123323('0x3e')}]})[_0x123323('0x2c')](handleEntityNotFound(_0x415754,null))[_0x123323('0x2c')](function(_0x4c0cfa){const _0x84f272=_0x123323;return _0x1cbbd2[_0x84f272('0x95')]=_0x4c0cfa,_0x1cbbd2[_0x84f272('0x46')]=_[_0x84f272('0xbd')](_0x4c0cfa[_0x84f272('0x3e')],['priority'],[_0x84f272('0x52')]),_0x1cbbd2['account'][_0x84f272('0x3e')]&&delete _0x1cbbd2['account'][_0x84f272('0x3e')],db[_0x84f272('0x9b')]['describe']();})[_0x123323('0x2c')](function(_0x256ffb){const _0x4bc0db=_0x123323;if(!_0x256ffb)throw new ValidationError(_0x4bc0db('0x9f'));_0x2a6d1f=_[_0x4bc0db('0x6d')](_['keys'](_0x256ffb),['createdAt',_0x4bc0db('0x55')]),_0x171761=_[_0x4bc0db('0x6d')](_[_0x4bc0db('0x4d')](_0x256ffb),['createdAt',_0x4bc0db('0x55'),_0x4bc0db('0x1'),_0x4bc0db('0x29')]),_0x1cbbd2[_0x4bc0db('0x25')]={'mapKey':'mobile'};if(_0x1cbbd2[_0x4bc0db('0x95')][_0x4bc0db('0x8d')])switch(_0x1cbbd2['account'][_0x4bc0db('0x8d')]){case _0x4bc0db('0x24'):_0x1cbbd2['body']['from']=_0xd063da[_0x4bc0db('0x25')]['From'],_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x25')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0x96')],_0x1cbbd2['body'][_0x4bc0db('0x91')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0xaf')];break;case _0x4bc0db('0xbb'):_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x99')]='+'+_0xd063da['body'][_0x4bc0db('0x5c')],_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x25')]=_0xd063da['body']['text'];break;case'connectel':_0x1cbbd2['body'][_0x4bc0db('0x99')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0x99')],_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x25')]=_0xd063da['body'][_0x4bc0db('0x31')];break;case'clicksend':_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x99')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0x99')],_0x1cbbd2[_0x4bc0db('0x25')]['body']=_0xd063da[_0x4bc0db('0x25')]['body'],_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x91')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0x94')];break;case'plivo':_0x1cbbd2['body'][_0x4bc0db('0x99')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0xbf')],_0x1cbbd2['body'][_0x4bc0db('0x25')]=_0xd063da['body']['Text'],_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x91')]=_0xd063da[_0x4bc0db('0x25')]['MessageUUID'];break;case'infobip':_0x1cbbd2['body'][_0x4bc0db('0x99')]='+'+_0xd063da[_0x4bc0db('0x25')]['results'][0x0]['from'],_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x25')]=_0xd063da[_0x4bc0db('0x25')]['results'][0x0][_0x4bc0db('0x7')],_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x91')]=_0xd063da['body'][_0x4bc0db('0x64')][0x0]['messageId'];break;case _0x4bc0db('0x42'):_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x99')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0xaa')],_0x1cbbd2['body']['body']=_0xd063da['body'][_0x4bc0db('0xa9')][_0x4bc0db('0x31')];break;case _0x4bc0db('0xb0'):_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x99')]=_0xd063da['body']['fromNumber'],_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x25')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0x7')],_0x1cbbd2['body'][_0x4bc0db('0x91')]=_0xd063da['body'][_0x4bc0db('0x9d')];break;case _0x4bc0db('0x49'):_0x1cbbd2['body'][_0x4bc0db('0x99')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0x99')],_0x1cbbd2['body'][_0x4bc0db('0x25')]=_0xd063da['body'][_0x4bc0db('0x31')],_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x91')]=_0xd063da[_0x4bc0db('0x25')][_0x4bc0db('0x60')];break;}_0x1cbbd2[_0x4bc0db('0x25')]['id']&&delete _0x1cbbd2[_0x4bc0db('0x25')]['id'];if(_[_0x4bc0db('0x16')](_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x99')]))throw new ValidationError('from\x20is\x20mandatory');if(_[_0x4bc0db('0x16')](_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x25')])||_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x25')]==='')throw new ValidationError(_0x4bc0db('0x67'));if(_[_0x4bc0db('0x16')](_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x6c')]))throw new ValidationError('mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20'+_0x171761);if(!_[_0x4bc0db('0x9')](_0x171761,_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x6c')]))throw new ValidationError(_0x4bc0db('0x74')+_0x171761);return _0x5705de[_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x6c')]]=_0x1cbbd2[_0x4bc0db('0x25')][_0x4bc0db('0x99')],db[_0x4bc0db('0x1f')][_0x4bc0db('0x3c')]({'where':{'id':_0x1cbbd2[_0x4bc0db('0x95')][_0x4bc0db('0x29')]},'include':[{'model':db[_0x4bc0db('0x9b')],'as':_0x4bc0db('0x76'),'where':_0x5705de,'limit':0x1,'order':[[_0x4bc0db('0x55'),_0x4bc0db('0xba')]]}]});})[_0x123323('0x2c')](handleEntityNotFound(_0x415754,null))['then'](function(_0x183aee){const _0x4f838e=_0x123323;if(_0x183aee){_0x1cbbd2[_0x4f838e('0x70')]=_[_0x4f838e('0x6a')](_0x183aee,[_0x4f838e('0x76')]);if(_0x183aee[_0x4f838e('0x76')][_0x4f838e('0x84')])return _0x183aee['Contacts'][0x0];const _0x317973=_[_0x4f838e('0x35')](_0x1cbbd2['body'],{'firstName':_0x1cbbd2[_0x4f838e('0x25')][_0x4f838e('0x99')],'ListId':_0x183aee['id']});return _0x317973[_0x1cbbd2[_0x4f838e('0x25')][_0x4f838e('0x6c')]]=_0x1cbbd2['body'][_0x4f838e('0x99')],db[_0x4f838e('0x9b')]['create'](_0x317973,{'fields':_0x2a6d1f,'raw':!![]});}})['then'](handleEntityNotFound(_0x415754,null))['then'](function(_0x52b215){const _0x7080ce=_0x123323;if(_0x52b215){_0x1cbbd2[_0x7080ce('0x48')]=_0x52b215;const _0x16ed8e={'ContactId':_0x52b215['id'],'phone':_0x1cbbd2['body'][_0x7080ce('0x99')],'SmsAccountId':_0xd063da[_0x7080ce('0x1a')]['id']},_0x2ed155={'ContactId':_0x52b215['id'],'SmsAccountId':_0xd063da[_0x7080ce('0x1a')]['id'],'closed':![]};return db[_0x7080ce('0x9e')]['findOne']({'where':_0x2ed155})[_0x7080ce('0x2c')](function(_0x3b3686){const _0x111e7d=_0x7080ce;if(_0x3b3686)return[_0x3b3686,![]];return db[_0x111e7d('0x9e')]['create'](_0x16ed8e)[_0x111e7d('0x2c')](function(_0x575a9f){return[_0x575a9f,!![]];});});}})[_0x123323('0x2c')](function([_0x160f30,_0x4ab13f]){const _0x462e29=_0x123323;return _0x1cbbd2[_0x462e29('0x4e')]=_0x160f30[_0x462e29('0xbe')]({'plain':!![]}),_0x1cbbd2[_0x462e29('0x4e')][_0x462e29('0x65')]=![],_0x4ab13f&&(_0x1cbbd2[_0x462e29('0x95')][_0x462e29('0x8')]&&_0x1cbbd2[_0x462e29('0x46')][_0x462e29('0x61')]({'id':0x0,'priority':_0x1cbbd2[_0x462e29('0x46')][_0x462e29('0x84')]+0x1,'app':_0x462e29('0x50'),'appdata':_0x462e29('0xa6'),'interval':'*,*,*,*'}),_0x1cbbd2[_0x462e29('0x4e')][_0x462e29('0x65')]=!![]),db[_0x462e29('0x57')][_0x462e29('0x5d')]({'phone':_0x1cbbd2[_0x462e29('0x25')][_0x462e29('0x99')],'messageId':_0x1cbbd2[_0x462e29('0x25')]['messageId'],'body':_0x1cbbd2[_0x462e29('0x25')][_0x462e29('0x25')],'SmsAccountId':_0xd063da[_0x462e29('0x1a')]['id'],'SmsInteractionId':_0x160f30['id'],'direction':'in','ContactId':_0x160f30[_0x462e29('0x41')],'AttachmentId':_0x1cbbd2[_0x462e29('0x25')][_0x462e29('0x45')]});})['then'](function(_0x374c42){const _0x5c404d=_0x123323;_0x1cbbd2[_0x5c404d('0x31')]=_0x374c42;if(_0x1cbbd2[_0x5c404d('0x4e')][_0x5c404d('0x5a')])return db[_0x5c404d('0x32')]['findOne']({'attributes':['id',_0x5c404d('0x72')],'where':{'id':_0x1cbbd2[_0x5c404d('0x4e')][_0x5c404d('0x5a')]}})[_0x5c404d('0x2c')](function(_0x7db29e){const _0x2598d3=_0x5c404d;return _0x7db29e&&_0x1cbbd2[_0x2598d3('0x46')][_0x2598d3('0xac')]({'id':0x0,'priority':0x0,'app':'agent','appdata':_0x7db29e['name']+','+(_0x1cbbd2['account'][_0x2598d3('0x54')]||0xa),'interval':_0x2598d3('0x34')}),respondWithRpcPromise(_0x2598d3('0x8e'),_0x2598d3('0x71'),_0x1cbbd2);});return respondWithRpcPromise(_0x5c404d('0x8e'),_0x5c404d('0x71'),_0x1cbbd2);})[_0x123323('0x2c')](function(_0x4fadfa){const _0x2180dd=_0x123323;if(_0x4fadfa){const _0x359980=0xc8,_0x224850=_0x2180dd('0x80');return logger[_0x2180dd('0x3f')](_0x2180dd('0xb8'),_0x224850,_0x359980,_0x2180dd('0x89')),logger['debug'](_0x2180dd('0x3b'),_0x224850,_0x359980,_0x2180dd('0x89'),JSON[_0x2180dd('0x10')](_0x4fadfa)),_0x1cbbd2[_0x2180dd('0x95')]['type']===_0x2180dd('0x24')?_0x415754[_0x2180dd('0x39')](_0x359980)[_0x2180dd('0x1b')](_0x2180dd('0x4b'),_0x2180dd('0x53'))[_0x2180dd('0x40')]('\x0a'):_0x415754[_0x2180dd('0x39')](_0x359980)[_0x2180dd('0x92')](_0x4fadfa);}})['catch'](handleError(_0x415754,null));},exports[_0x43a3a8('0x9c')]=function(_0x2793fc,_0x3661d4){const _0x2d28e2=_0x43a3a8;return db[_0x2d28e2('0x12')][_0x2d28e2('0x3c')]({'where':{'id':_0x2793fc[_0x2d28e2('0x1a')]['id']}})[_0x2d28e2('0x2c')](handleEntityNotFound(_0x3661d4,null))[_0x2d28e2('0x2c')](function(_0x29c741){const _0x274d77=_0x2d28e2;if(_0x29c741)return db['sequelize'][_0x274d77('0x6b')](function(_0x1203e8){const _0x275bbe=_0x274d77;return db[_0x275bbe('0x51')]['destroy']({'where':{'SmsAccountId':_0x2793fc['params']['id']},'transaction':_0x1203e8})[_0x275bbe('0x2c')](function(){const _0x378ff4=_0x275bbe,_0x49be7d=_['map'](_0x2793fc['body'],function(_0x1bcd79){return _0x1bcd79['SmsAccountId']=_0x2793fc['params']['id'],_0x1bcd79;});return db[_0x378ff4('0x51')][_0x378ff4('0xc2')](_0x49be7d,{'transaction':_0x1203e8});});})[_0x274d77('0x2c')](function(){const _0x1fb954=_0x274d77;return db[_0x1fb954('0x51')][_0x1fb954('0x8b')]({'where':{'SmsAccountId':_0x2793fc['params']['id']},'order':_0x1fb954('0x77')});});})[_0x2d28e2('0x2c')](respondWithResult(_0x3661d4,null))[_0x2d28e2('0x93')](handleError(_0x3661d4,null));},exports[_0x43a3a8('0x2')]=function(_0x3002c2,_0x2da68b){const _0x446133=_0x43a3a8;let _0x1375c7={};const _0x15b7ef={};let _0x716d53,_0x3fc1df;return db[_0x446133('0x12')][_0x446133('0x3c')]({'where':{'id':_0x3002c2[_0x446133('0x1a')]['id']}})[_0x446133('0x2c')](handleEntityNotFound(_0x2da68b,null))[_0x446133('0x2c')](function(_0x1eb1f2){const _0x9fa3e9=_0x446133;if(_0x1eb1f2)return _0x716d53=_0x1eb1f2,_0x15b7ef[_0x9fa3e9('0x33')]=_['keys'](db['SmsApplication'][_0x9fa3e9('0xc1')]),_0x15b7ef[_0x9fa3e9('0x2e')]=_[_0x9fa3e9('0x4d')](_0x3002c2[_0x9fa3e9('0x2e')]),_0x15b7ef[_0x9fa3e9('0x3')]=_[_0x9fa3e9('0x13')](_0x15b7ef[_0x9fa3e9('0x33')],_0x15b7ef[_0x9fa3e9('0x2e')]),_0x1375c7['attributes']=_[_0x9fa3e9('0x13')](_0x15b7ef[_0x9fa3e9('0x33')],qs[_0x9fa3e9('0x81')](_0x3002c2[_0x9fa3e9('0x2e')][_0x9fa3e9('0x81')])),_0x1375c7['attributes']=_0x1375c7[_0x9fa3e9('0x26')]['length']?_0x1375c7[_0x9fa3e9('0x26')]:_0x15b7ef[_0x9fa3e9('0x33')],_0x1375c7[_0x9fa3e9('0x90')]=qs[_0x9fa3e9('0x7d')](_0x3002c2[_0x9fa3e9('0x2e')][_0x9fa3e9('0x7d')]),_0x1375c7[_0x9fa3e9('0x5b')]=qs[_0x9fa3e9('0x3')](_['pick'](_0x3002c2['query'],_0x15b7ef['filters'])),_0x3002c2[_0x9fa3e9('0x2e')][_0x9fa3e9('0x2b')]&&(_0x1375c7['where']=_[_0x9fa3e9('0xa8')](_0x1375c7[_0x9fa3e9('0x5b')],{[Op['or']]:_[_0x9fa3e9('0x37')](_0x1375c7[_0x9fa3e9('0x26')],function(_0x561b8f){const _0x5e8ed4=_0x9fa3e9,_0x35fbc4={};return _0x35fbc4[_0x561b8f]={[Op['like']]:'%'+_0x3002c2[_0x5e8ed4('0x2e')]['filter']+'%'},_0x35fbc4;})})),_0x1375c7=_[_0x9fa3e9('0xa8')]({},_0x1375c7,_0x3002c2[_0x9fa3e9('0x7c')]),_0x716d53[_0x9fa3e9('0x2')](_0x1375c7);})[_0x446133('0x2c')](function(_0x34cc3d){const _0x285b76=_0x446133;if(_0x34cc3d)return _0x3fc1df=_0x34cc3d['length'],typeof _0x3002c2[_0x285b76('0x2e')][_0x285b76('0x38')]==='undefined'&&(_0x1375c7[_0x285b76('0x85')]=qs[_0x285b76('0x85')](_0x3002c2[_0x285b76('0x2e')][_0x285b76('0x85')]),_0x1375c7[_0x285b76('0xa3')]=qs[_0x285b76('0xa3')](_0x3002c2[_0x285b76('0x2e')][_0x285b76('0xa3')])),_0x716d53[_0x285b76('0x2')](_0x1375c7);})[_0x446133('0x2c')](function(_0x2f8dc3){if(_0x2f8dc3)return _0x2f8dc3?{'count':_0x3fc1df,'rows':_0x2f8dc3}:null;})[_0x446133('0x2c')](respondWithResult(_0x2da68b,null))[_0x446133('0x93')](handleError(_0x2da68b,null));},exports[_0x43a3a8('0xa2')]=function(_0x201110,_0x53857f){const _0x5b85b5=_0x43a3a8;let _0x3c3997={'raw':![],'where':{}};const _0x197ce7={},_0x3d634b={'count':0x0,'rows':[]};return db[_0x5b85b5('0x12')]['findOne']({'where':{'id':_0x201110['params']['id']}})[_0x5b85b5('0x2c')](handleEntityNotFound(_0x53857f,null))[_0x5b85b5('0x2c')](function(_0x6bb792){const _0x12fcc9=_0x5b85b5;if(_0x6bb792)return _0x197ce7['model']=_[_0x12fcc9('0x4d')](db[_0x12fcc9('0x9e')][_0x12fcc9('0xc1')]),_0x197ce7[_0x12fcc9('0x2e')]=_[_0x12fcc9('0x4d')](_0x201110['query']),_0x197ce7[_0x12fcc9('0x3')]=_['intersection'](_0x197ce7[_0x12fcc9('0x33')],_0x197ce7[_0x12fcc9('0x2e')]),_0x3c3997[_0x12fcc9('0x26')]=_[_0x12fcc9('0x13')](_0x197ce7['model'],qs[_0x12fcc9('0x81')](_0x201110[_0x12fcc9('0x2e')][_0x12fcc9('0x81')])),_0x3c3997[_0x12fcc9('0x26')]=_0x3c3997[_0x12fcc9('0x26')]['length']?_0x3c3997[_0x12fcc9('0x26')]:_0x197ce7[_0x12fcc9('0x33')],typeof _0x201110['query'][_0x12fcc9('0x38')]==='undefined'&&(_0x3c3997[_0x12fcc9('0x85')]=qs[_0x12fcc9('0x85')](_0x201110[_0x12fcc9('0x2e')][_0x12fcc9('0x85')]),_0x3c3997['offset']=qs[_0x12fcc9('0xa3')](_0x201110[_0x12fcc9('0x2e')][_0x12fcc9('0xa3')])),_0x3c3997[_0x12fcc9('0x90')]=qs[_0x12fcc9('0x7d')](_0x201110['query']['sort']),_0x3c3997[_0x12fcc9('0x5b')]=qs[_0x12fcc9('0x3')](_['pick'](_0x201110[_0x12fcc9('0x2e')],_0x197ce7[_0x12fcc9('0x3')])),_0x3c3997[_0x12fcc9('0x5b')]['SmsAccountId']=_0x6bb792['id'],_0x201110[_0x12fcc9('0x2e')]['filter']&&(_0x3c3997[_0x12fcc9('0x5b')]=_[_0x12fcc9('0xa8')](_0x3c3997[_0x12fcc9('0x5b')],{[Op['or']]:_[_0x12fcc9('0x37')](_0x3c3997[_0x12fcc9('0x26')],function(_0x3251a3){const _0x52537c=_0x12fcc9,_0x41aaec={};return _0x41aaec[_0x3251a3]={[Op[_0x52537c('0xa0')]]:'%'+_0x201110['query'][_0x52537c('0x2b')]+'%'},_0x41aaec;})})),_0x3c3997=_['merge']({},_0x3c3997,_0x201110['options']),db[_0x12fcc9('0x9e')][_0x12fcc9('0xb2')]({'where':_0x3c3997[_0x12fcc9('0x5b')]})['then'](function(_0x50d083){const _0x544486=_0x12fcc9;return _0x3d634b['count']=_0x50d083,_0x201110['query'][_0x544486('0x21')]&&(_0x3c3997['include']=[{'model':db[_0x544486('0x9b')],'as':'Contact','required':![]},{'model':db['User'],'as':'Owner','attributes':[_0x544486('0x72'),'fullname',_0x544486('0x87')],'required':![]},{'model':db[_0x544486('0x0')],'as':_0x544486('0xa1'),'attributes':['id',_0x544486('0x72'),_0x544486('0x17')],'where':_0x201110[_0x544486('0x2e')][_0x544486('0x69')]?{'id':_0x201110[_0x544486('0x2e')][_0x544486('0x69')]}:undefined,'required':_0x201110[_0x544486('0x2e')]['tag']?!![]:![]}]),db[_0x544486('0x9e')]['findAll'](_0x3c3997);})[_0x12fcc9('0x2c')](function(_0x550053){const _0x44a8f7=_0x12fcc9;return _0x3d634b[_0x44a8f7('0x2f')]=_0x550053,_0x3d634b;});})[_0x5b85b5('0x2c')](respondWithFilteredResult(_0x53857f,_0x3c3997))[_0x5b85b5('0x93')](handleError(_0x53857f,null));},exports[_0x43a3a8('0x40')]=function(_0x2e52ee,_0x5d1740){const _0x3d090e=_0x43a3a8;let _0x3441e9,_0x2c1312;if(_[_0x3d090e('0x16')](_0x2e52ee[_0x3d090e('0x25')]['body'])||_0x2e52ee['body'][_0x3d090e('0x25')]==='')throw new ValidationError('body\x20is\x20mandatory\x20and\x20not\x20empty');if(_[_0x3d090e('0x16')](_0x2e52ee['body']['to']))throw new ValidationError('to\x20is\x20mandatory');const _0x5738f5=_0x2e52ee[_0x3d090e('0x25')]['to'];return db['SmsAccount'][_0x3d090e('0x3c')]({'where':{'id':_0x2e52ee[_0x3d090e('0x1a')]['id']},'include':[{'model':db[_0x3d090e('0x1f')],'as':_0x3d090e('0xb5'),'include':[{'model':db[_0x3d090e('0x9b')],'as':_0x3d090e('0x76'),'where':{'mobile':_0x5738f5},'limit':0x1,'order':[[_0x3d090e('0x55'),'DESC']]}]}]})[_0x3d090e('0x2c')](handleEntityNotFound(_0x5d1740,null))[_0x3d090e('0x2c')](function(_0x655680){const _0x4edf75=_0x3d090e;if(_0x655680&&_0x655680[_0x4edf75('0xb5')]){_0x3441e9=_0x655680['get']({'plain':!![]});if(_0x3441e9[_0x4edf75('0xb5')]&&_0x3441e9['List'][_0x4edf75('0x76')][_0x4edf75('0x84')])return _0x3441e9[_0x4edf75('0xb5')][_0x4edf75('0x76')][0x0];return db[_0x4edf75('0x9b')][_0x4edf75('0x5d')](_[_0x4edf75('0x35')](_0x2e52ee[_0x4edf75('0x25')],{'firstName':_0x5738f5,'mobile':_0x5738f5,'phone':_0x5738f5,'ListId':_0x3441e9[_0x4edf75('0x29')]}));}})[_0x3d090e('0x2c')](handleEntityNotFound(_0x5d1740,null))[_0x3d090e('0x2c')](function(_0x5d58e1){const _0x270784=_0x3d090e;if(_0x5d58e1)return _0x2c1312=_0x5d58e1,db['SmsInteraction']['findOne']({'where':{'ContactId':_0x2c1312['id'],'closed':![],'SmsAccountId':_0x3441e9['id']}})[_0x270784('0x2c')](function(_0x302f5a){const _0x459787=_0x270784;if(_0x302f5a)return[_0x302f5a,![]];return db['SmsInteraction'][_0x459787('0x5d')]({'UserId':_0x2e52ee[_0x459787('0xb6')]['id'],'ContactId':_0x2c1312['id'],'SmsAccountId':_0x3441e9['id'],'phone':_0x5738f5,'firstMsgDirection':'out','Messages':[_[_0x459787('0xa8')](_0x2e52ee[_0x459787('0x25')],{'read':![],'body':_0x2e52ee[_0x459787('0x25')][_0x459787('0x25')],'phone':_0x5738f5,'SmsAccountId':_0x3441e9['id'],'UserId':_0x2e52ee[_0x459787('0xb6')]['id'],'ContactId':_0x2c1312['id']})]},{'include':[{'model':db['SmsMessage'],'as':_0x459787('0x11')}]})[_0x459787('0x2c')](function(_0xe0b99e){return[_0xe0b99e,!![]];});});})[_0x3d090e('0x2c')](function([_0x2dce74,_0x31f124]){const _0xc17fc3=_0x3d090e;if(_0x31f124)return _0x2dce74;return db[_0xc17fc3('0x57')][_0xc17fc3('0x5d')](_[_0xc17fc3('0xa8')](_0x2e52ee[_0xc17fc3('0x25')],{'read':![],'body':_0x2e52ee['body']['body'],'phone':_0x5738f5,'SmsAccountId':_0x3441e9['id'],'SmsInteractionId':_0x2dce74['id'],'UserId':_0x2e52ee[_0xc17fc3('0xb6')]['id'],'ContactId':_0x2c1312['id']}))['then'](function(_0x170c11){const _0x1cfc9d=_0xc17fc3;return _0x2dce74[_0x1cfc9d('0x1d')]['Messages']=[],_0x2dce74[_0x1cfc9d('0x1d')]['Messages']['push'](_0x170c11[_0x1cfc9d('0x1d')]),_0x2dce74;});})['then'](respondWithResult(_0x5d1740,null))[_0x3d090e('0x93')](handleError(_0x5d1740,null));},exports[_0x43a3a8('0x39')]=function(_0x168047,_0x47c48a){const _0x31b8c0=_0x43a3a8;_0x168047[_0x31b8c0('0x25')]['id']&&delete _0x168047[_0x31b8c0('0x25')]['id'];console[_0x31b8c0('0x22')](_0x31b8c0('0x86'),_0x168047[_0x31b8c0('0x25')]);let _0x3ba2fc,_0x45004d,_0x2a8a23;return db[_0x31b8c0('0x12')][_0x31b8c0('0x3c')]({'where':{'id':_0x168047[_0x31b8c0('0x1a')]['id']}})[_0x31b8c0('0x2c')](handleEntityNotFound(_0x47c48a,null))[_0x31b8c0('0x2c')](function(_0x3054c3){const _0x53b525=_0x31b8c0;if(_0x3054c3){_0x2a8a23=_0x3054c3,logger[_0x53b525('0x23')]('SmsAccount,\x20%s,\x20%s,\x20%s','status','received\x20delivery\x20report\x20from',_0x3054c3[_0x53b525('0x8d')],util[_0x53b525('0x8c')](_0x168047['body'],{'showHidden':![],'depth':null}));switch(_0x3054c3['type']){case _0x53b525('0xbb'):if(_0x168047[_0x53b525('0x25')][_0x53b525('0x7a')]&&_0x168047[_0x53b525('0x25')][_0x53b525('0x39')])return _0x45004d=_0x168047[_0x53b525('0x25')][_0x53b525('0x39')],db['SmsMessage'][_0x53b525('0x3c')]({'where':{'messageId':_0x168047[_0x53b525('0x25')][_0x53b525('0x7a')]}});break;case _0x53b525('0x4c'):if(_0x168047['body'][_0x53b525('0x8a')]&&_0x168047[_0x53b525('0x25')]['statusInt'])return _0x45004d=_0x168047[_0x53b525('0x25')][_0x53b525('0xbc')],db[_0x53b525('0x57')][_0x53b525('0x3c')]({'where':{'messageId':_0x168047[_0x53b525('0x25')][_0x53b525('0x8a')]}});break;case _0x53b525('0xad'):if(_0x168047[_0x53b525('0x25')][_0x53b525('0x94')]&&_0x168047[_0x53b525('0x25')][_0x53b525('0x83')])return _0x45004d=_0x168047[_0x53b525('0x25')][_0x53b525('0x83')],db[_0x53b525('0x57')][_0x53b525('0x3c')]({'where':{'messageId':_0x168047['body']['message_id']}});break;case'infobip':{const _0x3474f6=_0x168047[_0x53b525('0x25')][_0x53b525('0x64')][0x0];if(_0x3474f6[_0x53b525('0x91')]&&_0x3474f6[_0x53b525('0x39')]['groupName']===_0x53b525('0xa4'))return _0x45004d=_0x3474f6['status'][_0x53b525('0x98')],db['SmsMessage'][_0x53b525('0x3c')]({'where':{'messageId':_0x3474f6[_0x53b525('0x91')]}});}break;case _0x53b525('0xb0'):if(_0x168047[_0x53b525('0x25')][_0x53b525('0x91')]&&_0x168047[_0x53b525('0x25')][_0x53b525('0x39')])return _0x45004d=_0x168047['body'][_0x53b525('0x39')],db[_0x53b525('0x57')][_0x53b525('0x3c')]({'where':{'messageId':_0x168047[_0x53b525('0x25')][_0x53b525('0x91')]}});break;case _0x53b525('0x49'):if(_0x168047[_0x53b525('0x25')][_0x53b525('0x20')]&&_0x168047[_0x53b525('0x25')][_0x53b525('0x39')])return _0x45004d=_0x168047['body'][_0x53b525('0x39')],db[_0x53b525('0x57')][_0x53b525('0x3c')]({'where':{'messageId':_0x168047['body']['redif']}});break;}}})[_0x31b8c0('0x2c')](handleEntityNotFound(_0x47c48a,null))[_0x31b8c0('0x2c')](function(_0x480249){const _0x15fdd1=_0x31b8c0;if(_0x480249){_0x3ba2fc=_0x480249;switch(_0x2a8a23[_0x15fdd1('0x8d')]){case _0x15fdd1('0xbb'):if(_0x45004d===_0x15fdd1('0xa4'))return _0x3ba2fc[_0x15fdd1('0xa')]({'read':!![]});else logger['error'](_0x15fdd1('0xb8'),_0x15fdd1('0x39'),_0x15fdd1('0xbb'),util[_0x15fdd1('0x8c')](_0x168047[_0x15fdd1('0x25')],{'showHidden':![],'depth':null}));break;case _0x15fdd1('0x4c'):if(_0x45004d==='1')return _0x3ba2fc['update']({'read':!![]});else logger[_0x15fdd1('0x73')]('SmsAccount,\x20%s,\x20%s,\x20%s',_0x15fdd1('0x39'),'skebby',util[_0x15fdd1('0x8c')](_0x168047[_0x15fdd1('0x25')],{'showHidden':![],'depth':null}));break;case _0x15fdd1('0xad'):if(!_0x168047[_0x15fdd1('0x25')][_0x15fdd1('0x43')]&&_0x45004d>=0xc8&&_0x45004d<=0xce)return _0x3ba2fc['update']({'read':!![]});else logger[_0x15fdd1('0x73')](_0x15fdd1('0xb8'),_0x15fdd1('0x39'),_0x15fdd1('0xad'),util[_0x15fdd1('0x8c')](_0x168047['body'],{'showHidden':![],'depth':null}));break;case _0x15fdd1('0x15'):{const _0x456926=_0x168047['body'][_0x15fdd1('0x64')][0x0];if(_0x456926[_0x15fdd1('0x39')][_0x15fdd1('0x98')]===_0x15fdd1('0xa4'))return _0x3ba2fc[_0x15fdd1('0xa')]({'read':!![]});else logger[_0x15fdd1('0x73')](_0x15fdd1('0xb8'),_0x15fdd1('0x39'),'infobip',util[_0x15fdd1('0x8c')](_0x168047['body'],{'showHidden':![],'depth':null}));}break;case _0x15fdd1('0xb0'):if(_0x45004d==_0x15fdd1('0x66')||_0x45004d==_0x15fdd1('0x6'))return _0x3ba2fc[_0x15fdd1('0xa')]({'read':!![]});else logger[_0x15fdd1('0x73')](_0x15fdd1('0xb8'),_0x15fdd1('0x39'),_0x15fdd1('0xb0'),util[_0x15fdd1('0x8c')](_0x168047[_0x15fdd1('0x25')],{'showHidden':![],'depth':null}));break;case'intelepeer':if(_0x45004d===_0x15fdd1('0xc0')||_0x45004d==='ACCEPTD')return _0x3ba2fc[_0x15fdd1('0xa')]({'read':!![]});else logger[_0x15fdd1('0x73')](_0x15fdd1('0xb8'),_0x15fdd1('0x39'),_0x15fdd1('0x49'),util[_0x15fdd1('0x8c')](_0x168047[_0x15fdd1('0x25')],{'showHidden':![],'depth':null}));break;}return _0x3ba2fc;}})['then'](respondWithResult(_0x47c48a,null))[_0x31b8c0('0x93')](handleError(_0x47c48a,null));},exports[_0x43a3a8('0x14')]=function(_0x49c2f2,_0x393166){const _0x54f6d8=_0x43a3a8;let _0x510523,_0x1d0569,_0x101ba4;return db[_0x54f6d8('0x12')][_0x54f6d8('0x3c')]({'where':{'id':_0x49c2f2[_0x54f6d8('0x1a')]['id']}})[_0x54f6d8('0x2c')](handleEntityNotFound(_0x393166,null))['then'](function(_0x235e0b){const _0x23acf3=_0x54f6d8;if(_0x235e0b){_0x101ba4=_0x235e0b,logger['debug']('SmsAccount,\x20%s,\x20%s,\x20%s','status',_0x23acf3('0xa7'),_0x235e0b['type'],util['inspect'](_0x49c2f2[_0x23acf3('0x2e')],{'showHidden':![],'depth':null}));switch(_0x235e0b[_0x23acf3('0x8d')]){case _0x23acf3('0x42'):if(_0x49c2f2['query'][_0x23acf3('0x2d')]&&_0x49c2f2['query'][_0x23acf3('0x75')])return _0x1d0569=_0x49c2f2['query'][_0x23acf3('0x75')],db['SmsMessage']['findOne']({'where':{'messageId':_0x49c2f2[_0x23acf3('0x2e')][_0x23acf3('0x2d')]}});break;}}})['then'](handleEntityNotFound(_0x393166,null))[_0x54f6d8('0x2c')](function(_0x1cf75c){const _0x2a68a0=_0x54f6d8;if(_0x1cf75c){_0x510523=_0x1cf75c;switch(_0x101ba4[_0x2a68a0('0x8d')]){case'csc':if(_0x1d0569==='2'||_0x1d0569==='6')return _0x510523[_0x2a68a0('0xa')]({'read':!![]});else logger[_0x2a68a0('0x73')](_0x2a68a0('0xb8'),'status','csc',util['inspect'](_0x49c2f2[_0x2a68a0('0x2e')],{'showHidden':![],'depth':null}));break;}return _0x510523;}})['then'](respondWithResult(_0x393166,null))[_0x54f6d8('0x93')](handleError(_0x393166,null));},exports[_0x43a3a8('0x7e')]=function(_0x3c630d,_0x189135){const _0x3e9785=_0x43a3a8;return db[_0x3e9785('0x12')][_0x3e9785('0x3c')]({'where':{'id':_0x3c630d[_0x3e9785('0x1a')]['id']}})['then'](function(_0xa6a0c9){const _0x5bde19=_0x3e9785;if(_0xa6a0c9)return _0xa6a0c9[_0x5bde19('0x7e')](_0x3c630d[_0x5bde19('0x25')][_0x5bde19('0xb3')],{'through':_[_0x5bde19('0x6a')](_0x3c630d[_0x5bde19('0x25')],[_0x5bde19('0xb3'),'id'])})[_0x5bde19('0x2c')](function(_0xbfd933){const _0x4c9d2a=_0x5bde19;for(let _0x1b6e2d=0x0;_0x1b6e2d<_0x3c630d[_0x4c9d2a('0x25')][_0x4c9d2a('0xb3')][_0x4c9d2a('0x84')];_0x1b6e2d+=0x1){socket['emit'](_0x4c9d2a('0x58'),{'UserId':_0x3c630d[_0x4c9d2a('0x25')][_0x4c9d2a('0xb3')][_0x1b6e2d],'SmsAccountId':_0x3c630d[_0x4c9d2a('0x1a')]['id']});}return _0xbfd933;});})['then'](respondWithResult(_0x189135,null))['catch'](handleError(_0x189135,null));},exports['removeAgents']=function(_0xc104d4,_0x5ec854){const _0x40bcce=_0x43a3a8;return db[_0x40bcce('0x12')][_0x40bcce('0x3c')]({'where':{'id':_0xc104d4[_0x40bcce('0x1a')]['id']}})[_0x40bcce('0x2c')](handleEntityNotFound(_0x5ec854,null))['then'](function(_0x667673){const _0x2a49d7=_0x40bcce;if(_0x667673)return _0x667673['removeAgents'](_0xc104d4[_0x2a49d7('0x2e')]['ids'])['then'](function(){const _0x43af30=_0x2a49d7;if(_['isArray'](_0xc104d4[_0x43af30('0x2e')][_0x43af30('0xb3')]))for(let _0x16153b=0x0;_0x16153b<_0xc104d4[_0x43af30('0x2e')][_0x43af30('0xb3')][_0x43af30('0x84')];_0x16153b+=0x1){socket[_0x43af30('0x44')]('userSmsAccount:remove',{'UserId':Number(_0xc104d4[_0x43af30('0x2e')][_0x43af30('0xb3')][_0x16153b]),'SmsAccountId':Number(_0xc104d4[_0x43af30('0x1a')]['id'])});}else socket[_0x43af30('0x44')]('userSmsAccount:remove',{'UserId':Number(_0xc104d4['query'][_0x43af30('0xb3')]),'SmsAccountId':Number(_0xc104d4[_0x43af30('0x1a')]['id'])});});})[_0x40bcce('0x2c')](respondWithStatusCode(_0x5ec854,null))[_0x40bcce('0x93')](handleError(_0x5ec854,null));},exports[_0x43a3a8('0x79')]=function(_0x2360e7,_0x2bb6bb){const _0x527819=_0x43a3a8;let _0x5c657c={};const _0x526637={};let _0x545c43,_0x271e09;return db[_0x527819('0x12')][_0x527819('0x3c')]({'where':{'id':_0x2360e7['params']['id']}})['then'](handleEntityNotFound(_0x2bb6bb,null))[_0x527819('0x2c')](function(_0x1fa24a){const _0x519fcd=_0x527819;if(_0x1fa24a)return _0x545c43=_0x1fa24a,_0x526637[_0x519fcd('0x33')]=_[_0x519fcd('0x4d')](db[_0x519fcd('0x32')][_0x519fcd('0xc1')]),_0x526637['query']=_[_0x519fcd('0x4d')](_0x2360e7[_0x519fcd('0x2e')]),_0x526637[_0x519fcd('0x3')]=_[_0x519fcd('0x13')](_0x526637[_0x519fcd('0x33')],_0x526637[_0x519fcd('0x2e')]),_0x5c657c[_0x519fcd('0x26')]=_[_0x519fcd('0x13')](_0x526637['model'],qs['fields'](_0x2360e7[_0x519fcd('0x2e')][_0x519fcd('0x81')])),_0x5c657c[_0x519fcd('0x26')]=_0x5c657c[_0x519fcd('0x26')][_0x519fcd('0x84')]?_0x5c657c[_0x519fcd('0x26')]:_0x526637[_0x519fcd('0x33')],_0x5c657c[_0x519fcd('0x90')]=qs['sort'](_0x2360e7[_0x519fcd('0x2e')]['sort']),_0x5c657c[_0x519fcd('0x5b')]=qs['filters'](_[_0x519fcd('0x59')](_0x2360e7['query'],_0x526637['filters'])),_0x2360e7[_0x519fcd('0x2e')]['filter']&&(_0x5c657c[_0x519fcd('0x5b')]=_[_0x519fcd('0xa8')](_0x5c657c[_0x519fcd('0x5b')],{[Op['or']]:_[_0x519fcd('0x37')](_0x5c657c['attributes'],function(_0x5e6720){const _0x55b08c=_0x519fcd,_0x23ab2d={};return _0x23ab2d[_0x5e6720]={[Op['like']]:'%'+_0x2360e7[_0x55b08c('0x2e')][_0x55b08c('0x2b')]+'%'},_0x23ab2d;})})),_0x5c657c=_['merge']({},_0x5c657c,_0x2360e7[_0x519fcd('0x7c')]),_0x545c43['getAgents'](_0x5c657c);})[_0x527819('0x2c')](function(_0x3a663b){const _0x59007a=_0x527819;if(_0x3a663b)return _0x271e09=_0x3a663b[_0x59007a('0x84')],typeof _0x2360e7['query'][_0x59007a('0x38')]===_0x59007a('0x56')&&(_0x5c657c[_0x59007a('0x85')]=qs[_0x59007a('0x85')](_0x2360e7[_0x59007a('0x2e')][_0x59007a('0x85')]),_0x5c657c[_0x59007a('0xa3')]=qs[_0x59007a('0xa3')](_0x2360e7[_0x59007a('0x2e')][_0x59007a('0xa3')])),_0x545c43[_0x59007a('0x79')](_0x5c657c);})[_0x527819('0x2c')](function(_0x3bc5ca){if(_0x3bc5ca)return _0x3bc5ca?{'count':_0x271e09,'rows':_0x3bc5ca}:null;})[_0x527819('0x2c')](respondWithResult(_0x2bb6bb,null))[_0x527819('0x93')](handleError(_0x2bb6bb,null));}; \ No newline at end of file +const a542_0x4f33=['where','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','Applications','client','params','getAgents','log','startRouting','send','filter','Start','from\x20is\x20mandatory','end','UserProfileSection','createdAt','filters','request','originatingAddress','SmsAccount,\x20%s,\x20%s','CmContact','sequelize','destroy','../../rediscache','connectel','plivo','*,*,*,*','asc','index','statusGet','body','omit','nolimit','Messages','VIRTUAL','catch','ids','segmentedMessage','findOne','rawAttributes','type','mandatoryDispositionPause','groupName','status_code','Body','map','query','offset','includeAll','skebby','transaction','state','Pause','removeDispositions','text','message','includes','merge','internal','rows','push','received\x20delivery\x20report\x20from','entity\x20found','SmsAccount,\x20%s,\x20%s,\x20%s,\x20%s','jayson/promise','autoAssociation','MessageUUID','infobip','inspect','receiveMessage','lodash','dataValues','SmsMessage','util','text/xml','info','get','to\x20is\x20mandatory','UserId','close','status','CmList','message-id','from','options','then','skebby_dispatch_id','redif','Disposition','out','limit','addAnswer','waitForTheAssignedAgent','error_code','clicksend','refid','From','bulkCreate','Owner','SmsApplication','message_id','userSmsAccount:remove','UserProfileResource','AttachmentId','count','debug','addApplications','DELIVRD','update','interaction','Contacts','addAgents','unmanaged','json','isNil','SmsAccount,\x20%s,\x20%s,\x20%s','statusInt','orderBy','priority','describe','results','request\x20sent','twilio','mapKey','Text','error','addDisposition','register','fieldName','fromNumber','keys','length','sendStatus','ListId','contact','created','set','../../components/parsers/qs','getInteractions','replyMessageId','autoclose','result','emit','intelepeer','List','stack','applications','pick','stringify','account','csc','getApplications','api','DESC','like','tag','\x0a','model','sort','MessageSid','fields','CannedAnswer','../../mysqldb','SmsAccountId','SmsInteraction','mobile','agent','body\x20is\x20mandatory\x20and\x20not\x20empty','removeAnswers','order','endpoint\x20/status\x20POST\x20/','DELIVERED','updatedAt','messageId','SmsAccounts','list','removeAgents','SmsAccount','Contact','user','intersection','isArray','User','name','findAll','undefined','create','Content-Range','http','clickatell','sender','Content-Type','attributes','Unable\x20to\x20retrieve\x20the\x20current\x20user'];(function(_0x2e3652,_0x4f3349){const _0x1b4d8d=function(_0x63e749){while(--_0x63e749){_0x2e3652['push'](_0x2e3652['shift']());}};_0x1b4d8d(++_0x4f3349);}(a542_0x4f33,0x1e5));const a542_0x1b4d=function(_0x2e3652,_0x4f3349){_0x2e3652=_0x2e3652-0x0;let _0x1b4d8d=a542_0x4f33[_0x2e3652];return _0x1b4d8d;};const _0x22c2fb=a542_0x1b4d;'use strict';const util=require(_0x22c2fb('0xa6')),_=require(_0x22c2fb('0xa3')),qs=require(_0x22c2fb('0x25')),logger=require('../../config/logger')(_0x22c2fb('0x34')),{getSocket}=require(_0x22c2fb('0x74')),socket=getSocket(),db=require(_0x22c2fb('0x3e'))['db'],{Op,ValidationError}=require(_0x22c2fb('0x72'));require('./smsAccount.socket')[_0x22c2fb('0x1b')](socket);const jayson=require(_0x22c2fb('0x9d')),client=jayson[_0x22c2fb('0x61')][_0x22c2fb('0x58')]({'port':0x232c});function respondWithRpcPromise(_0x63e749,_0x4519d9,_0xdd3a00,_0x469b88){return new Promise(function(_0x20fada,_0x3833f3){const _0xc673b3=a542_0x1b4d,_0x2ba95a=_0x469b88||client;return _0x2ba95a[_0xc673b3('0x6e')](_0x63e749,_0xdd3a00)[_0xc673b3('0xb2')](function(_0x44102e){const _0xd43309=_0xc673b3;logger[_0xd43309('0xa8')](_0xd43309('0x70'),_0x4519d9,_0xd43309('0x15')),logger[_0xd43309('0x5')]('SmsAccount,\x20%s,\x20%s,\x20%s',_0x4519d9,_0xd43309('0x15'),JSON[_0xd43309('0x30')](_0x44102e));if(_0x44102e[_0xd43309('0x19')]){if(_0x44102e[_0xd43309('0x19')]['code']===0x1f4)return logger['error'](_0xd43309('0x70'),_0x4519d9,_0x44102e['error']['message']),_0x3833f3(_0x44102e[_0xd43309('0x19')][_0xd43309('0x94')]);return logger['error']('SmsAccount,\x20%s,\x20%s',_0x4519d9,_0x44102e['error'][_0xd43309('0x94')]),_0x20fada(_0x44102e[_0xd43309('0x19')]['message']);}else logger[_0xd43309('0xa8')](_0xd43309('0x70'),_0x4519d9,'request\x20sent'),_0x20fada(_0x44102e[_0xd43309('0x29')]['message']);})['catch'](function(_0x3545e8){const _0x309856=_0xc673b3;logger[_0x309856('0x19')](_0x309856('0x70'),_0x4519d9,_0x3545e8),_0x3833f3(_0x3545e8);});});}function respondWithStatusCode(_0x229519,_0x47f231){return _0x47f231=_0x47f231||0xcc,function(_0x2e9873){const _0x1c16f0=a542_0x1b4d;if(_0x2e9873)return _0x229519[_0x1c16f0('0x20')](_0x47f231);return _0x229519[_0x1c16f0('0xad')](_0x47f231)['end']();};}function respondWithResult(_0x5e1596,_0xa46249){return _0xa46249=_0xa46249||0xc8,function(_0x2e4cae){const _0x247bb0=a542_0x1b4d;if(_0x2e4cae)return _0x5e1596[_0x247bb0('0xad')](_0xa46249)['json'](_0x2e4cae);};}function respondWithFilteredResult(_0x5a3644,_0x353f83){return function(_0x216e33){const _0x503ef9=a542_0x1b4d;if(_0x216e33){const _0x3e89d3=_0x216e33['count'],_0x4c3619=_0x353f83['offset'];let _0x22be0c=_0x353f83[_0x503ef9('0x8c')]+_0x353f83['limit'],_0x2b93fc;return _0x22be0c>=_0x3e89d3?(_0x22be0c=_0x3e89d3,_0x2b93fc=0xc8):_0x2b93fc=0xce,_0x5a3644[_0x503ef9('0xad')](_0x2b93fc),_0x5a3644[_0x503ef9('0x24')](_0x503ef9('0x57'),_0x4c3619+'-'+_0x22be0c+'/'+_0x3e89d3)[_0x503ef9('0xd')](_0x216e33);}return null;};}function saveUpdates(_0xbc2401){return function(_0x3fe663){const _0x58b461=a542_0x1b4d;if(_0x3fe663)return _0x3fe663['update'](_0xbc2401)[_0x58b461('0xb2')](function(_0x3b7d32){return _0x3b7d32;});return null;};}function removeEntity(_0x4d1b67){return function(_0x1299ae){const _0x1b02fb=a542_0x1b4d;if(_0x1299ae)return _0x1299ae['destroy']()[_0x1b02fb('0xb2')](function(){const _0x35e978=_0x1b02fb,_0x2b446e=_0x1299ae[_0x35e978('0xa9')]({'plain':!![]}),_0x41afd7=_0x35e978('0x4a');return db['UserProfileResource'][_0x35e978('0x73')]({'where':{'type':_0x41afd7,'resourceId':_0x2b446e['id']}})[_0x35e978('0xb2')](function(){return _0x1299ae;});})[_0x1b02fb('0xb2')](function(){const _0x44b38e=_0x1b02fb;_0x4d1b67[_0x44b38e('0xad')](0xcc)[_0x44b38e('0x6a')]();});};}function handleEntityNotFound(_0x53eb99){return function(_0x191c7f){return!_0x191c7f&&_0x53eb99['sendStatus'](0x194),_0x191c7f;};}function handleError(_0xd33bd6,_0xb1a3d4){return _0xb1a3d4=_0xb1a3d4||0x1f4,function(_0x466014){const _0x1940c6=a542_0x1b4d;logger[_0x1940c6('0x19')](_0x466014[_0x1940c6('0x2d')]),_0x466014['name']&&delete _0x466014[_0x1940c6('0x53')],_0xd33bd6['status'](_0xb1a3d4)['send'](_0x466014);};}exports[_0x22c2fb('0x79')]=function(_0x452f17,_0x2d6113){const _0x4c1bba=_0x22c2fb;let _0x524c62={'include':[{'model':db['Pause'],'as':'mandatoryDispositionPause'}]};const _0x2942d8={},_0xea241={'count':0x0,'rows':[]},_0x251722=_[_0x4c1bba('0x8a')](db[_0x4c1bba('0x4d')][_0x4c1bba('0x84')],function(_0x3361b9){const _0x1625e2=_0x4c1bba;return{'name':_0x3361b9[_0x1625e2('0x1c')],'type':_0x3361b9[_0x1625e2('0x85')]['key']};});_0x2942d8['model']=_[_0x4c1bba('0x8a')](_0x251722,_0x4c1bba('0x53')),_0x2942d8['query']=_[_0x4c1bba('0x1e')](_0x452f17[_0x4c1bba('0x8b')]),_0x2942d8[_0x4c1bba('0x6d')]=_['intersection'](_0x2942d8['model'],_0x2942d8[_0x4c1bba('0x8b')]),_0x524c62[_0x4c1bba('0x5c')]=_[_0x4c1bba('0x50')](_0x2942d8[_0x4c1bba('0x39')],qs[_0x4c1bba('0x3c')](_0x452f17['query'][_0x4c1bba('0x3c')])),_0x524c62[_0x4c1bba('0x5c')]=_0x524c62[_0x4c1bba('0x5c')]['length']?_0x524c62[_0x4c1bba('0x5c')]:_0x2942d8[_0x4c1bba('0x39')];typeof _0x452f17[_0x4c1bba('0x8b')]['nolimit']==='undefined'&&(_0x524c62['limit']=qs[_0x4c1bba('0xb7')](_0x452f17[_0x4c1bba('0x8b')][_0x4c1bba('0xb7')]),_0x524c62[_0x4c1bba('0x8c')]=qs['offset'](_0x452f17[_0x4c1bba('0x8b')]['offset']));_0x524c62['order']=qs[_0x4c1bba('0x3a')](_0x452f17['query']['sort']),_0x524c62['where']=qs[_0x4c1bba('0x6d')](_[_0x4c1bba('0x2f')](_0x452f17['query'],_0x2942d8['filters']),_0x251722);_0x452f17['query'][_0x4c1bba('0x67')]&&(_0x524c62['where']=_[_0x4c1bba('0x96')](_0x524c62[_0x4c1bba('0x5e')],{[Op['or']]:_[_0x4c1bba('0x8a')](_0x251722,function(_0x4920d9){const _0x31761d=_0x4c1bba;if(_0x4920d9[_0x31761d('0x85')]!==_0x31761d('0x7f')){const _0x5ec49e={};return _0x5ec49e[_0x4920d9[_0x31761d('0x53')]]={[Op[_0x31761d('0x36')]]:'%'+_0x452f17[_0x31761d('0x8b')][_0x31761d('0x67')]+'%'},_0x5ec49e;}})}));_0x524c62=_['merge']({},_0x524c62,_0x452f17['options']);const _0x15a523={'where':_0x524c62[_0x4c1bba('0x5e')]};return db['SmsAccount'][_0x4c1bba('0x4')](_0x15a523)['then'](function(_0x51937e){const _0x2bcedd=_0x4c1bba;return _0xea241['count']=_0x51937e,_0x452f17['query'][_0x2bcedd('0x8d')]&&(_0x524c62['include']=[{'all':!![]}]),db[_0x2bcedd('0x4d')][_0x2bcedd('0x54')](_0x524c62);})[_0x4c1bba('0xb2')](function(_0x1eaff9){const _0x29cc7b=_0x4c1bba;return _0xea241[_0x29cc7b('0x98')]=_0x1eaff9,_0xea241;})[_0x4c1bba('0xb2')](respondWithFilteredResult(_0x2d6113,_0x524c62))['catch'](handleError(_0x2d6113,null));},exports['show']=function(_0x153c98,_0x24a2f8){const _0x353357=_0x22c2fb;let _0x4981f2={'raw':![],'where':{'id':_0x153c98[_0x353357('0x62')]['id']},'include':[{'model':db[_0x353357('0x91')],'as':_0x353357('0x86')}]};const _0x32af58={};return _0x32af58[_0x353357('0x39')]=_[_0x353357('0x1e')](db[_0x353357('0x4d')]['rawAttributes']),_0x32af58[_0x353357('0x8b')]=_[_0x353357('0x1e')](_0x153c98[_0x353357('0x8b')]),_0x32af58['filters']=_[_0x353357('0x50')](_0x32af58[_0x353357('0x39')],_0x32af58[_0x353357('0x8b')]),_0x4981f2['attributes']=_[_0x353357('0x50')](_0x32af58[_0x353357('0x39')],qs['fields'](_0x153c98[_0x353357('0x8b')][_0x353357('0x3c')])),_0x4981f2[_0x353357('0x5c')]=_0x4981f2[_0x353357('0x5c')][_0x353357('0x1f')]?_0x4981f2[_0x353357('0x5c')]:_0x32af58[_0x353357('0x39')],_0x153c98['query'][_0x353357('0x8d')]&&(_0x4981f2['include']=[{'all':!![]}]),_0x4981f2=_['merge']({},_0x4981f2,_0x153c98['options']),db[_0x353357('0x4d')][_0x353357('0x83')](_0x4981f2)[_0x353357('0xb2')](handleEntityNotFound(_0x24a2f8,null))[_0x353357('0xb2')](respondWithResult(_0x24a2f8,null))[_0x353357('0x80')](handleError(_0x24a2f8,null));},exports[_0x22c2fb('0x56')]=function(_0x368ad7,_0x47f004){const _0x3854ec=_0x22c2fb;return db[_0x3854ec('0x4d')][_0x3854ec('0x56')](_0x368ad7[_0x3854ec('0x7b')],{})[_0x3854ec('0xb2')](function(_0x44cca0){const _0x1206e1=_0x3854ec,_0x4fa855=_0x368ad7[_0x1206e1('0x4f')]['get']({'plain':!![]});if(!_0x4fa855)throw new Error(_0x1206e1('0x5d'));if(_0x4fa855['role']===_0x1206e1('0x4f')){const _0x34539c=_0x44cca0[_0x1206e1('0xa9')]({'plain':!![]}),_0x4d1c83=_0x1206e1('0x4a');return db[_0x1206e1('0x6b')]['findOne']({'where':{'name':_0x4d1c83,'userProfileId':_0x4fa855['userProfileId']},'raw':!![]})[_0x1206e1('0xb2')](function(_0x25814a){const _0x1fd59e=_0x1206e1;return _0x25814a&&_0x25814a[_0x1fd59e('0x9e')]===0x0?db[_0x1fd59e('0x2')][_0x1fd59e('0x56')]({'name':_0x34539c[_0x1fd59e('0x53')],'resourceId':_0x34539c['id'],'type':_0x25814a[_0x1fd59e('0x53')],'sectionId':_0x25814a['id']},{})[_0x1fd59e('0xb2')](function(){return _0x44cca0;}):_0x44cca0;})['catch'](function(_0x2d9c80){const _0x2d1d91=_0x1206e1;logger['error'](_0x2d1d91('0x5f'),_0x2d9c80);throw _0x2d9c80;});}return _0x44cca0;})[_0x3854ec('0xb2')](respondWithResult(_0x47f004,0xc9))[_0x3854ec('0x80')](handleError(_0x47f004,null));},exports[_0x22c2fb('0x8')]=function(_0x50a950,_0x587358){const _0x4a800f=_0x22c2fb;return _0x50a950[_0x4a800f('0x7b')]['id']&&delete _0x50a950[_0x4a800f('0x7b')]['id'],db[_0x4a800f('0x4d')][_0x4a800f('0x83')]({'where':{'id':_0x50a950[_0x4a800f('0x62')]['id']},'include':[{'model':db[_0x4a800f('0x91')],'as':_0x4a800f('0x86')}]})[_0x4a800f('0xb2')](handleEntityNotFound(_0x587358,null))['then'](saveUpdates(_0x50a950[_0x4a800f('0x7b')],null))[_0x4a800f('0xb2')](respondWithResult(_0x587358,null))[_0x4a800f('0x80')](handleError(_0x587358,null));},exports[_0x22c2fb('0x73')]=function(_0x110fe6,_0x3cb8e6){const _0x306d12=_0x22c2fb;return db[_0x306d12('0x4d')][_0x306d12('0x83')]({'where':{'id':_0x110fe6[_0x306d12('0x62')]['id']}})[_0x306d12('0xb2')](handleEntityNotFound(_0x3cb8e6,null))[_0x306d12('0xb2')](removeEntity(_0x3cb8e6,null))[_0x306d12('0x80')](handleError(_0x3cb8e6,null));},exports[_0x22c2fb('0x13')]=function(_0x813b3,_0x313229){const _0x59d67d=_0x22c2fb;return db[_0x59d67d('0x4d')][_0x59d67d('0x13')]()[_0x59d67d('0xb2')](respondWithResult(_0x313229,null))[_0x59d67d('0x80')](handleError(_0x313229,null));},exports[_0x22c2fb('0x1a')]=function(_0x4009d3,_0x305551){const _0xe8805d=_0x22c2fb;return _0x4009d3[_0xe8805d('0x7b')]['id']&&delete _0x4009d3[_0xe8805d('0x7b')]['id'],db[_0xe8805d('0x4d')][_0xe8805d('0x83')]({'where':{'id':_0x4009d3['params']['id']}})[_0xe8805d('0xb2')](handleEntityNotFound(_0x305551,null))[_0xe8805d('0xb2')](function(_0x17730d){const _0x51529d=_0xe8805d;if(_0x17730d)return _0x4009d3[_0x51529d('0x7b')][_0x51529d('0x3f')]=_0x17730d['id'],db[_0x51529d('0xb5')][_0x51529d('0x56')](_0x4009d3[_0x51529d('0x7b')]);})[_0xe8805d('0xb2')](respondWithResult(_0x305551,null))[_0xe8805d('0x80')](handleError(_0x305551,null));},exports['getDispositions']=function(_0x198ca9,_0x3ddcdc){const _0x15b207=_0x22c2fb;let _0x390d95={'raw':![],'where':{}};const _0x3fdab1={},_0x2d7870={'count':0x0,'rows':[]};return db['SmsAccount'][_0x15b207('0x83')]({'where':{'id':_0x198ca9[_0x15b207('0x62')]['id']}})['then'](handleEntityNotFound(_0x3ddcdc,null))[_0x15b207('0xb2')](function(_0x160ed9){const _0x5e1e98=_0x15b207;if(_0x160ed9)return _0x3fdab1['model']=_[_0x5e1e98('0x1e')](db[_0x5e1e98('0xb5')][_0x5e1e98('0x84')]),_0x3fdab1[_0x5e1e98('0x8b')]=_['keys'](_0x198ca9['query']),_0x3fdab1['filters']=_[_0x5e1e98('0x50')](_0x3fdab1[_0x5e1e98('0x39')],_0x3fdab1[_0x5e1e98('0x8b')]),_0x390d95[_0x5e1e98('0x5c')]=_[_0x5e1e98('0x50')](_0x3fdab1[_0x5e1e98('0x39')],qs['fields'](_0x198ca9['query'][_0x5e1e98('0x3c')])),_0x390d95[_0x5e1e98('0x5c')]=_0x390d95[_0x5e1e98('0x5c')]['length']?_0x390d95[_0x5e1e98('0x5c')]:_0x3fdab1[_0x5e1e98('0x39')],typeof _0x198ca9[_0x5e1e98('0x8b')][_0x5e1e98('0x7d')]===_0x5e1e98('0x55')&&(_0x390d95[_0x5e1e98('0xb7')]=qs['limit'](_0x198ca9['query'][_0x5e1e98('0xb7')]),_0x390d95['offset']=qs[_0x5e1e98('0x8c')](_0x198ca9[_0x5e1e98('0x8b')][_0x5e1e98('0x8c')])),_0x390d95['order']=qs[_0x5e1e98('0x3a')](_0x198ca9[_0x5e1e98('0x8b')]['sort']),_0x390d95['where']=qs[_0x5e1e98('0x6d')](_['pick'](_0x198ca9[_0x5e1e98('0x8b')],_0x3fdab1[_0x5e1e98('0x6d')])),_0x390d95[_0x5e1e98('0x5e')][_0x5e1e98('0x3f')]=_0x160ed9['id'],_0x198ca9[_0x5e1e98('0x8b')][_0x5e1e98('0x67')]&&(_0x390d95[_0x5e1e98('0x5e')]=_[_0x5e1e98('0x96')](_0x390d95[_0x5e1e98('0x5e')],{[Op['or']]:_[_0x5e1e98('0x8a')](_0x390d95[_0x5e1e98('0x5c')],function(_0x159e58){const _0x4ded06=_0x5e1e98,_0x2a99e8={};return _0x2a99e8[_0x159e58]={[Op['like']]:'%'+_0x198ca9[_0x4ded06('0x8b')]['filter']+'%'},_0x2a99e8;})})),_0x390d95=_['merge']({},_0x390d95,_0x198ca9[_0x5e1e98('0xb1')]),db[_0x5e1e98('0xb5')]['count']({'where':_0x390d95['where']})[_0x5e1e98('0xb2')](function(_0x1e42a4){const _0xf5b76d=_0x5e1e98;return _0x2d7870[_0xf5b76d('0x4')]=_0x1e42a4,_0x198ca9[_0xf5b76d('0x8b')][_0xf5b76d('0x8d')]&&(_0x390d95['include']=[{'all':!![]}]),db['Disposition'][_0xf5b76d('0x54')](_0x390d95);})[_0x5e1e98('0xb2')](function(_0x3433f8){const _0x4115a9=_0x5e1e98;return _0x2d7870[_0x4115a9('0x98')]=_0x3433f8,_0x2d7870;});})[_0x15b207('0xb2')](respondWithFilteredResult(_0x3ddcdc,_0x390d95))[_0x15b207('0x80')](handleError(_0x3ddcdc,null));},exports[_0x22c2fb('0x92')]=function(_0x3f9cff,_0x313149){const _0x25f511=_0x22c2fb;return db[_0x25f511('0x4d')][_0x25f511('0x83')]({'where':{'id':_0x3f9cff[_0x25f511('0x62')]['id']}})[_0x25f511('0xb2')](handleEntityNotFound(_0x313149,null))['then'](function(_0x3cfe97){const _0x12c0bf=_0x25f511;if(_0x3cfe97)return _0x3cfe97[_0x12c0bf('0x92')](_0x3f9cff[_0x12c0bf('0x8b')][_0x12c0bf('0x81')]);})[_0x25f511('0xb2')](respondWithStatusCode(_0x313149,null))[_0x25f511('0x80')](handleError(_0x313149,null));},exports[_0x22c2fb('0xb8')]=function(_0x305903,_0x87a093){const _0x30698a=_0x22c2fb;return _0x305903['body']['id']&&delete _0x305903[_0x30698a('0x7b')]['id'],db['SmsAccount'][_0x30698a('0x83')]({'where':{'id':_0x305903['params']['id']}})[_0x30698a('0xb2')](handleEntityNotFound(_0x87a093,null))[_0x30698a('0xb2')](function(_0x3bae94){const _0x5bbc6f=_0x30698a;if(_0x3bae94)return _0x305903[_0x5bbc6f('0x7b')][_0x5bbc6f('0x3f')]=_0x3bae94['id'],db[_0x5bbc6f('0x3d')][_0x5bbc6f('0x56')](_0x305903[_0x5bbc6f('0x7b')]);})[_0x30698a('0xb2')](respondWithResult(_0x87a093,null))[_0x30698a('0x80')](handleError(_0x87a093,null));},exports['getAnswers']=function(_0xf6e45d,_0x5893b1){const _0x22ebee=_0x22c2fb;let _0x4b8344={'raw':![],'where':{}};const _0x8cc7b5={},_0x530aa8={'count':0x0,'rows':[]};return db[_0x22ebee('0x4d')][_0x22ebee('0x83')]({'where':{'id':_0xf6e45d[_0x22ebee('0x62')]['id']}})['then'](handleEntityNotFound(_0x5893b1,null))[_0x22ebee('0xb2')](function(_0x4b2673){const _0x32935a=_0x22ebee;if(_0x4b2673)return _0x8cc7b5['model']=_['keys'](db[_0x32935a('0x3d')][_0x32935a('0x84')]),_0x8cc7b5['query']=_['keys'](_0xf6e45d[_0x32935a('0x8b')]),_0x8cc7b5[_0x32935a('0x6d')]=_['intersection'](_0x8cc7b5[_0x32935a('0x39')],_0x8cc7b5[_0x32935a('0x8b')]),_0x4b8344[_0x32935a('0x5c')]=_['intersection'](_0x8cc7b5[_0x32935a('0x39')],qs[_0x32935a('0x3c')](_0xf6e45d['query'][_0x32935a('0x3c')])),_0x4b8344[_0x32935a('0x5c')]=_0x4b8344['attributes']['length']?_0x4b8344[_0x32935a('0x5c')]:_0x8cc7b5[_0x32935a('0x39')],typeof _0xf6e45d[_0x32935a('0x8b')][_0x32935a('0x7d')]===_0x32935a('0x55')&&(_0x4b8344[_0x32935a('0xb7')]=qs[_0x32935a('0xb7')](_0xf6e45d[_0x32935a('0x8b')][_0x32935a('0xb7')]),_0x4b8344['offset']=qs[_0x32935a('0x8c')](_0xf6e45d['query']['offset'])),_0x4b8344['order']=qs[_0x32935a('0x3a')](_0xf6e45d['query'][_0x32935a('0x3a')]),_0x4b8344[_0x32935a('0x5e')]=qs['filters'](_[_0x32935a('0x2f')](_0xf6e45d[_0x32935a('0x8b')],_0x8cc7b5[_0x32935a('0x6d')])),_0x4b8344[_0x32935a('0x5e')][_0x32935a('0x3f')]=_0x4b2673['id'],_0xf6e45d[_0x32935a('0x8b')][_0x32935a('0x67')]&&(_0x4b8344[_0x32935a('0x5e')]=_['merge'](_0x4b8344[_0x32935a('0x5e')],{[Op['or']]:_['map'](_0x4b8344[_0x32935a('0x5c')],function(_0x4ec0d2){const _0x157e56=_0x32935a,_0x223c6a={};return _0x223c6a[_0x4ec0d2]={[Op[_0x157e56('0x36')]]:'%'+_0xf6e45d[_0x157e56('0x8b')]['filter']+'%'},_0x223c6a;})})),_0x4b8344=_['merge']({},_0x4b8344,_0xf6e45d[_0x32935a('0xb1')]),db['CannedAnswer']['count']({'where':_0x4b8344[_0x32935a('0x5e')]})[_0x32935a('0xb2')](function(_0x2d6987){const _0x243882=_0x32935a;return _0x530aa8[_0x243882('0x4')]=_0x2d6987,_0xf6e45d[_0x243882('0x8b')]['includeAll']&&(_0x4b8344['include']=[{'all':!![]}]),db[_0x243882('0x3d')][_0x243882('0x54')](_0x4b8344);})[_0x32935a('0xb2')](function(_0x15fd85){return _0x530aa8['rows']=_0x15fd85,_0x530aa8;});})[_0x22ebee('0xb2')](respondWithFilteredResult(_0x5893b1,_0x4b8344))['catch'](handleError(_0x5893b1,null));},exports['removeAnswers']=function(_0x478f42,_0x3a6253){const _0x261533=_0x22c2fb;return db[_0x261533('0x4d')][_0x261533('0x83')]({'where':{'id':_0x478f42[_0x261533('0x62')]['id']}})[_0x261533('0xb2')](handleEntityNotFound(_0x3a6253,null))[_0x261533('0xb2')](function(_0x4ed3f2){const _0x417649=_0x261533;if(_0x4ed3f2)return _0x4ed3f2[_0x417649('0x44')](_0x478f42[_0x417649('0x8b')][_0x417649('0x81')]);})[_0x261533('0xb2')](respondWithStatusCode(_0x3a6253,null))[_0x261533('0x80')](handleError(_0x3a6253,null));},exports['notify']=function(_0x545c46,_0x3b4322){const _0x168e78=_0x22c2fb,_0x3aba45={'channel':'sms'};let _0x260678=[],_0x102be3=[];const _0x3f9edd={};return db[_0x168e78('0x4d')][_0x168e78('0x83')]({'where':{'id':_0x545c46['params']['id']},'include':[{'model':db[_0x168e78('0xc0')],'as':_0x168e78('0x60')}]})[_0x168e78('0xb2')](handleEntityNotFound(_0x3b4322,null))[_0x168e78('0xb2')](function(_0x766e86){const _0x2e8465=_0x168e78;return _0x3aba45[_0x2e8465('0x31')]=_0x766e86,_0x3aba45['applications']=_[_0x2e8465('0x11')](_0x766e86[_0x2e8465('0x60')],[_0x2e8465('0x12')],[_0x2e8465('0x78')]),_0x3aba45[_0x2e8465('0x31')]['Applications']&&delete _0x3aba45['account']['Applications'],db['CmContact'][_0x2e8465('0x13')]();})[_0x168e78('0xb2')](function(_0x14835d){const _0x3503eb=_0x168e78;if(!_0x14835d)throw new ValidationError('no\x20available\x20attributes');_0x260678=_['difference'](_[_0x3503eb('0x1e')](_0x14835d),[_0x3503eb('0x6c'),_0x3503eb('0x48')]),_0x102be3=_['difference'](_[_0x3503eb('0x1e')](_0x14835d),[_0x3503eb('0x6c'),_0x3503eb('0x48'),'CompanyId',_0x3503eb('0x21')]),_0x3aba45[_0x3503eb('0x7b')]={'mapKey':_0x3503eb('0x41')};if(_0x3aba45[_0x3503eb('0x31')]['type'])switch(_0x3aba45[_0x3503eb('0x31')][_0x3503eb('0x85')]){case'twilio':_0x3aba45[_0x3503eb('0x7b')]['from']=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0xbd')],_0x3aba45['body'][_0x3503eb('0x7b')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x89')],_0x3aba45['body'][_0x3503eb('0x49')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x3b')];break;case _0x3503eb('0x8e'):_0x3aba45['body'][_0x3503eb('0xb0')]='+'+_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x5a')],_0x3aba45[_0x3503eb('0x7b')]['body']=_0x545c46[_0x3503eb('0x7b')]['text'];break;case _0x3503eb('0x75'):_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0xb0')]=_0x545c46['body']['from'],_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x7b')]=_0x545c46[_0x3503eb('0x7b')]['message'];break;case _0x3503eb('0xbb'):_0x3aba45['body'][_0x3503eb('0xb0')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0xb0')],_0x3aba45['body'][_0x3503eb('0x7b')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x7b')],_0x3aba45['body'][_0x3503eb('0x49')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x0')];break;case _0x3503eb('0x76'):_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0xb0')]=_0x545c46[_0x3503eb('0x7b')]['From'],_0x3aba45[_0x3503eb('0x7b')]['body']=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x18')],_0x3aba45[_0x3503eb('0x7b')]['messageId']=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x9f')];break;case _0x3503eb('0xa0'):_0x3aba45['body'][_0x3503eb('0xb0')]='+'+_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x14')][0x0][_0x3503eb('0xb0')],_0x3aba45['body']['body']=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x14')][0x0][_0x3503eb('0x93')],_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x49')]=_0x545c46[_0x3503eb('0x7b')]['results'][0x0][_0x3503eb('0x49')];break;case _0x3503eb('0x32'):_0x3aba45['body']['from']=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x6f')],_0x3aba45[_0x3503eb('0x7b')]['body']=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x82')][_0x3503eb('0x94')];break;case'clickatell':_0x3aba45['body'][_0x3503eb('0xb0')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x1d')],_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x7b')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x93')],_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x49')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x27')];break;case'intelepeer':_0x3aba45['body']['from']=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0xb0')],_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x7b')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0x94')],_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x49')]=_0x545c46[_0x3503eb('0x7b')][_0x3503eb('0xbc')];break;}_0x3aba45[_0x3503eb('0x7b')]['id']&&delete _0x3aba45['body']['id'];if(_['isNil'](_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0xb0')]))throw new ValidationError(_0x3503eb('0x69'));if(_[_0x3503eb('0xe')](_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x7b')])||_0x3aba45['body'][_0x3503eb('0x7b')]==='')throw new ValidationError(_0x3503eb('0x43'));if(_[_0x3503eb('0xe')](_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x17')]))throw new ValidationError('mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20'+_0x102be3);if(!_[_0x3503eb('0x95')](_0x102be3,_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x17')]))throw new ValidationError('mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20'+_0x102be3);return _0x3f9edd[_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0x17')]]=_0x3aba45[_0x3503eb('0x7b')][_0x3503eb('0xb0')],db[_0x3503eb('0xae')][_0x3503eb('0x83')]({'where':{'id':_0x3aba45['account'][_0x3503eb('0x21')]},'include':[{'model':db['CmContact'],'as':_0x3503eb('0xa'),'where':_0x3f9edd,'limit':0x1,'order':[['updatedAt','DESC']]}]});})['then'](handleEntityNotFound(_0x3b4322,null))[_0x168e78('0xb2')](function(_0x1c8b23){const _0x42f035=_0x168e78;if(_0x1c8b23){_0x3aba45[_0x42f035('0x4b')]=_['omit'](_0x1c8b23,[_0x42f035('0xa')]);if(_0x1c8b23[_0x42f035('0xa')][_0x42f035('0x1f')])return _0x1c8b23[_0x42f035('0xa')][0x0];const _0x4a18c2=_['defaults'](_0x3aba45[_0x42f035('0x7b')],{'firstName':_0x3aba45[_0x42f035('0x7b')]['from'],'ListId':_0x1c8b23['id']});return _0x4a18c2[_0x3aba45[_0x42f035('0x7b')]['mapKey']]=_0x3aba45[_0x42f035('0x7b')]['from'],db['CmContact']['create'](_0x4a18c2,{'fields':_0x260678,'raw':!![]});}})[_0x168e78('0xb2')](handleEntityNotFound(_0x3b4322,null))['then'](function(_0x5ddaea){const _0x2391fc=_0x168e78;if(_0x5ddaea){_0x3aba45[_0x2391fc('0x22')]=_0x5ddaea;const _0x12d239={'ContactId':_0x5ddaea['id'],'phone':_0x3aba45[_0x2391fc('0x7b')][_0x2391fc('0xb0')],'SmsAccountId':_0x545c46['params']['id']},_0x509289={'ContactId':_0x5ddaea['id'],'SmsAccountId':_0x545c46[_0x2391fc('0x62')]['id'],'closed':![]};return db[_0x2391fc('0x40')]['findOne']({'where':_0x509289})[_0x2391fc('0xb2')](function(_0x45ebfa){const _0x3e5edb=_0x2391fc;if(_0x45ebfa)return[_0x45ebfa,![]];return db['SmsInteraction'][_0x3e5edb('0x56')](_0x12d239)['then'](function(_0x4ad5b2){return[_0x4ad5b2,!![]];});});}})[_0x168e78('0xb2')](function([_0x224d81,_0x472bc1]){const _0x14bd91=_0x168e78;return _0x3aba45['interaction']=_0x224d81[_0x14bd91('0xa9')]({'plain':!![]}),_0x3aba45[_0x14bd91('0x9')][_0x14bd91('0x23')]=![],_0x472bc1&&(_0x3aba45['account'][_0x14bd91('0x28')]&&_0x3aba45[_0x14bd91('0x2e')][_0x14bd91('0x99')]({'id':0x0,'priority':_0x3aba45['applications'][_0x14bd91('0x1f')]+0x1,'app':_0x14bd91('0xac'),'appdata':_0x14bd91('0xc'),'interval':_0x14bd91('0x77')}),_0x3aba45[_0x14bd91('0x9')][_0x14bd91('0x23')]=!![]),db[_0x14bd91('0xa5')][_0x14bd91('0x56')]({'phone':_0x3aba45[_0x14bd91('0x7b')][_0x14bd91('0xb0')],'messageId':_0x3aba45[_0x14bd91('0x7b')][_0x14bd91('0x49')],'body':_0x3aba45[_0x14bd91('0x7b')][_0x14bd91('0x7b')],'SmsAccountId':_0x545c46['params']['id'],'SmsInteractionId':_0x224d81['id'],'direction':'in','ContactId':_0x224d81['ContactId'],'AttachmentId':_0x3aba45['body'][_0x14bd91('0x3')]});})[_0x168e78('0xb2')](function(_0x1c8e86){const _0x1a4278=_0x168e78;_0x3aba45[_0x1a4278('0x94')]=_0x1c8e86;if(_0x3aba45[_0x1a4278('0x9')][_0x1a4278('0xab')])return db[_0x1a4278('0x52')][_0x1a4278('0x83')]({'attributes':['id','name'],'where':{'id':_0x3aba45[_0x1a4278('0x9')][_0x1a4278('0xab')]}})[_0x1a4278('0xb2')](function(_0x52f676){const _0x12f5fe=_0x1a4278;return _0x52f676&&_0x3aba45[_0x12f5fe('0x2e')]['unshift']({'id':0x0,'priority':0x0,'app':_0x12f5fe('0x42'),'appdata':_0x52f676[_0x12f5fe('0x53')]+','+(_0x3aba45[_0x12f5fe('0x31')][_0x12f5fe('0xb9')]||0xa),'interval':_0x12f5fe('0x77')}),respondWithRpcPromise(_0x12f5fe('0x68'),_0x12f5fe('0x65'),_0x3aba45);});return respondWithRpcPromise(_0x1a4278('0x68'),_0x1a4278('0x65'),_0x3aba45);})['then'](function(_0x9b6a64){const _0x24303d=_0x168e78;if(_0x9b6a64){const _0xfad1c0=0xc8,_0x3b6ba0=_0x24303d('0xa2');return logger['info'](_0x24303d('0xf'),_0x3b6ba0,_0xfad1c0,_0x24303d('0x9b')),logger[_0x24303d('0x5')](_0x24303d('0x9c'),_0x3b6ba0,_0xfad1c0,'entity\x20found',JSON[_0x24303d('0x30')](_0x9b6a64)),_0x3aba45[_0x24303d('0x31')][_0x24303d('0x85')]===_0x24303d('0x16')?_0x3b4322[_0x24303d('0xad')](_0xfad1c0)[_0x24303d('0x24')](_0x24303d('0x5b'),_0x24303d('0xa7'))[_0x24303d('0x66')](_0x24303d('0x38')):_0x3b4322[_0x24303d('0xad')](_0xfad1c0)[_0x24303d('0xd')](_0x9b6a64);}})['catch'](handleError(_0x3b4322,null));},exports[_0x22c2fb('0x6')]=function(_0x372950,_0x550234){const _0x2caa59=_0x22c2fb;return db['SmsAccount']['findOne']({'where':{'id':_0x372950['params']['id']}})[_0x2caa59('0xb2')](handleEntityNotFound(_0x550234,null))[_0x2caa59('0xb2')](function(_0x4118f9){const _0x581935=_0x2caa59;if(_0x4118f9)return db['sequelize'][_0x581935('0x8f')](function(_0x1cad74){const _0x2eb1a6=_0x581935;return db['SmsApplication'][_0x2eb1a6('0x73')]({'where':{'SmsAccountId':_0x372950[_0x2eb1a6('0x62')]['id']},'transaction':_0x1cad74})[_0x2eb1a6('0xb2')](function(){const _0x4b7dba=_0x2eb1a6,_0xcedb5d=_[_0x4b7dba('0x8a')](_0x372950[_0x4b7dba('0x7b')],function(_0x521651){const _0x372e26=_0x4b7dba;return _0x521651[_0x372e26('0x3f')]=_0x372950['params']['id'],_0x521651;});return db[_0x4b7dba('0xc0')][_0x4b7dba('0xbe')](_0xcedb5d,{'transaction':_0x1cad74});});})[_0x581935('0xb2')](function(){const _0x4089d9=_0x581935;return db[_0x4089d9('0xc0')]['findAndCountAll']({'where':{'SmsAccountId':_0x372950[_0x4089d9('0x62')]['id']},'order':'priority'});});})[_0x2caa59('0xb2')](respondWithResult(_0x550234,null))['catch'](handleError(_0x550234,null));},exports[_0x22c2fb('0x33')]=function(_0x24979a,_0x2c8804){const _0x3650d3=_0x22c2fb;let _0x3f5c19={};const _0x10c7f8={};let _0x18b7a6,_0x27e148;return db[_0x3650d3('0x4d')]['findOne']({'where':{'id':_0x24979a[_0x3650d3('0x62')]['id']}})[_0x3650d3('0xb2')](handleEntityNotFound(_0x2c8804,null))[_0x3650d3('0xb2')](function(_0x4b7a88){const _0x18ed91=_0x3650d3;if(_0x4b7a88)return _0x18b7a6=_0x4b7a88,_0x10c7f8[_0x18ed91('0x39')]=_[_0x18ed91('0x1e')](db[_0x18ed91('0xc0')][_0x18ed91('0x84')]),_0x10c7f8[_0x18ed91('0x8b')]=_[_0x18ed91('0x1e')](_0x24979a[_0x18ed91('0x8b')]),_0x10c7f8[_0x18ed91('0x6d')]=_[_0x18ed91('0x50')](_0x10c7f8[_0x18ed91('0x39')],_0x10c7f8['query']),_0x3f5c19['attributes']=_[_0x18ed91('0x50')](_0x10c7f8['model'],qs[_0x18ed91('0x3c')](_0x24979a[_0x18ed91('0x8b')][_0x18ed91('0x3c')])),_0x3f5c19[_0x18ed91('0x5c')]=_0x3f5c19[_0x18ed91('0x5c')][_0x18ed91('0x1f')]?_0x3f5c19[_0x18ed91('0x5c')]:_0x10c7f8[_0x18ed91('0x39')],_0x3f5c19['order']=qs[_0x18ed91('0x3a')](_0x24979a['query']['sort']),_0x3f5c19[_0x18ed91('0x5e')]=qs[_0x18ed91('0x6d')](_['pick'](_0x24979a[_0x18ed91('0x8b')],_0x10c7f8[_0x18ed91('0x6d')])),_0x24979a['query'][_0x18ed91('0x67')]&&(_0x3f5c19[_0x18ed91('0x5e')]=_[_0x18ed91('0x96')](_0x3f5c19[_0x18ed91('0x5e')],{[Op['or']]:_[_0x18ed91('0x8a')](_0x3f5c19[_0x18ed91('0x5c')],function(_0x45d6bd){const _0x52a605=_0x18ed91,_0x3da664={};return _0x3da664[_0x45d6bd]={[Op[_0x52a605('0x36')]]:'%'+_0x24979a[_0x52a605('0x8b')][_0x52a605('0x67')]+'%'},_0x3da664;})})),_0x3f5c19=_[_0x18ed91('0x96')]({},_0x3f5c19,_0x24979a[_0x18ed91('0xb1')]),_0x18b7a6[_0x18ed91('0x33')](_0x3f5c19);})[_0x3650d3('0xb2')](function(_0x1445da){const _0x173795=_0x3650d3;if(_0x1445da)return _0x27e148=_0x1445da['length'],typeof _0x24979a[_0x173795('0x8b')][_0x173795('0x7d')]===_0x173795('0x55')&&(_0x3f5c19['limit']=qs['limit'](_0x24979a[_0x173795('0x8b')][_0x173795('0xb7')]),_0x3f5c19[_0x173795('0x8c')]=qs[_0x173795('0x8c')](_0x24979a[_0x173795('0x8b')][_0x173795('0x8c')])),_0x18b7a6['getApplications'](_0x3f5c19);})[_0x3650d3('0xb2')](function(_0x4f6af4){if(_0x4f6af4)return _0x4f6af4?{'count':_0x27e148,'rows':_0x4f6af4}:null;})[_0x3650d3('0xb2')](respondWithResult(_0x2c8804,null))[_0x3650d3('0x80')](handleError(_0x2c8804,null));},exports[_0x22c2fb('0x26')]=function(_0x530a6a,_0x3b71da){const _0x3c3024=_0x22c2fb;let _0x2f0217={'raw':![],'where':{}};const _0x173f88={},_0x130400={'count':0x0,'rows':[]};return db[_0x3c3024('0x4d')][_0x3c3024('0x83')]({'where':{'id':_0x530a6a[_0x3c3024('0x62')]['id']}})[_0x3c3024('0xb2')](handleEntityNotFound(_0x3b71da,null))[_0x3c3024('0xb2')](function(_0x67cdbd){const _0x3c0f5e=_0x3c3024;if(_0x67cdbd)return _0x173f88['model']=_['keys'](db[_0x3c0f5e('0x40')][_0x3c0f5e('0x84')]),_0x173f88['query']=_['keys'](_0x530a6a[_0x3c0f5e('0x8b')]),_0x173f88[_0x3c0f5e('0x6d')]=_[_0x3c0f5e('0x50')](_0x173f88['model'],_0x173f88['query']),_0x2f0217['attributes']=_[_0x3c0f5e('0x50')](_0x173f88[_0x3c0f5e('0x39')],qs[_0x3c0f5e('0x3c')](_0x530a6a['query'][_0x3c0f5e('0x3c')])),_0x2f0217[_0x3c0f5e('0x5c')]=_0x2f0217[_0x3c0f5e('0x5c')][_0x3c0f5e('0x1f')]?_0x2f0217[_0x3c0f5e('0x5c')]:_0x173f88[_0x3c0f5e('0x39')],typeof _0x530a6a['query'][_0x3c0f5e('0x7d')]==='undefined'&&(_0x2f0217[_0x3c0f5e('0xb7')]=qs[_0x3c0f5e('0xb7')](_0x530a6a['query'][_0x3c0f5e('0xb7')]),_0x2f0217['offset']=qs['offset'](_0x530a6a[_0x3c0f5e('0x8b')]['offset'])),_0x2f0217[_0x3c0f5e('0x45')]=qs[_0x3c0f5e('0x3a')](_0x530a6a['query'][_0x3c0f5e('0x3a')]),_0x2f0217[_0x3c0f5e('0x5e')]=qs[_0x3c0f5e('0x6d')](_[_0x3c0f5e('0x2f')](_0x530a6a[_0x3c0f5e('0x8b')],_0x173f88[_0x3c0f5e('0x6d')])),_0x2f0217['where'][_0x3c0f5e('0x3f')]=_0x67cdbd['id'],_0x530a6a[_0x3c0f5e('0x8b')][_0x3c0f5e('0x67')]&&(_0x2f0217[_0x3c0f5e('0x5e')]=_[_0x3c0f5e('0x96')](_0x2f0217[_0x3c0f5e('0x5e')],{[Op['or']]:_['map'](_0x2f0217[_0x3c0f5e('0x5c')],function(_0x57d29d){const _0x102c40=_0x3c0f5e,_0x405ecf={};return _0x405ecf[_0x57d29d]={[Op[_0x102c40('0x36')]]:'%'+_0x530a6a[_0x102c40('0x8b')][_0x102c40('0x67')]+'%'},_0x405ecf;})})),_0x2f0217=_[_0x3c0f5e('0x96')]({},_0x2f0217,_0x530a6a[_0x3c0f5e('0xb1')]),db[_0x3c0f5e('0x40')][_0x3c0f5e('0x4')]({'where':_0x2f0217[_0x3c0f5e('0x5e')]})[_0x3c0f5e('0xb2')](function(_0x2101c5){const _0x3a30b5=_0x3c0f5e;return _0x130400[_0x3a30b5('0x4')]=_0x2101c5,_0x530a6a[_0x3a30b5('0x8b')][_0x3a30b5('0x8d')]&&(_0x2f0217['include']=[{'model':db[_0x3a30b5('0x71')],'as':_0x3a30b5('0x4e'),'required':![]},{'model':db[_0x3a30b5('0x52')],'as':_0x3a30b5('0xbf'),'attributes':[_0x3a30b5('0x53'),'fullname',_0x3a30b5('0x97')],'required':![]},{'model':db['Tag'],'as':'Tags','attributes':['id',_0x3a30b5('0x53'),'color'],'where':_0x530a6a[_0x3a30b5('0x8b')][_0x3a30b5('0x37')]?{'id':_0x530a6a['query'][_0x3a30b5('0x37')]}:undefined,'required':_0x530a6a[_0x3a30b5('0x8b')][_0x3a30b5('0x37')]?!![]:![]}]),db[_0x3a30b5('0x40')][_0x3a30b5('0x54')](_0x2f0217);})[_0x3c0f5e('0xb2')](function(_0x2cfd0b){return _0x130400['rows']=_0x2cfd0b,_0x130400;});})[_0x3c3024('0xb2')](respondWithFilteredResult(_0x3b71da,_0x2f0217))[_0x3c3024('0x80')](handleError(_0x3b71da,null));},exports['send']=function(_0x16c3d6,_0x5ccbf7){const _0xab8c77=_0x22c2fb;let _0x50a747,_0x376338;if(_[_0xab8c77('0xe')](_0x16c3d6['body'][_0xab8c77('0x7b')])||_0x16c3d6[_0xab8c77('0x7b')]['body']==='')throw new ValidationError(_0xab8c77('0x43'));if(_[_0xab8c77('0xe')](_0x16c3d6['body']['to']))throw new ValidationError(_0xab8c77('0xaa'));const _0x229bcb=_0x16c3d6[_0xab8c77('0x7b')]['to'];return db['SmsAccount'][_0xab8c77('0x83')]({'where':{'id':_0x16c3d6[_0xab8c77('0x62')]['id']},'include':[{'model':db[_0xab8c77('0xae')],'as':_0xab8c77('0x2c'),'include':[{'model':db[_0xab8c77('0x71')],'as':'Contacts','where':{'mobile':_0x229bcb},'limit':0x1,'order':[[_0xab8c77('0x48'),_0xab8c77('0x35')]]}]}]})[_0xab8c77('0xb2')](handleEntityNotFound(_0x5ccbf7,null))[_0xab8c77('0xb2')](function(_0x42eecb){const _0x47856f=_0xab8c77;if(_0x42eecb&&_0x42eecb['List']){_0x50a747=_0x42eecb[_0x47856f('0xa9')]({'plain':!![]});if(_0x50a747[_0x47856f('0x2c')]&&_0x50a747[_0x47856f('0x2c')][_0x47856f('0xa')][_0x47856f('0x1f')])return _0x50a747[_0x47856f('0x2c')][_0x47856f('0xa')][0x0];return db[_0x47856f('0x71')][_0x47856f('0x56')](_['defaults'](_0x16c3d6['body'],{'firstName':_0x229bcb,'mobile':_0x229bcb,'phone':_0x229bcb,'ListId':_0x50a747[_0x47856f('0x21')]}));}})[_0xab8c77('0xb2')](handleEntityNotFound(_0x5ccbf7,null))[_0xab8c77('0xb2')](function(_0x1ed513){const _0x18005c=_0xab8c77;if(_0x1ed513)return _0x376338=_0x1ed513,db[_0x18005c('0x40')][_0x18005c('0x83')]({'where':{'ContactId':_0x376338['id'],'closed':![],'SmsAccountId':_0x50a747['id']}})[_0x18005c('0xb2')](function(_0x14ae49){const _0x3f6f84=_0x18005c;if(_0x14ae49)return[_0x14ae49,![]];return db[_0x3f6f84('0x40')][_0x3f6f84('0x56')]({'UserId':_0x16c3d6[_0x3f6f84('0x4f')]['id'],'ContactId':_0x376338['id'],'SmsAccountId':_0x50a747['id'],'phone':_0x229bcb,'firstMsgDirection':_0x3f6f84('0xb6'),'Messages':[_[_0x3f6f84('0x96')](_0x16c3d6[_0x3f6f84('0x7b')],{'read':![],'body':_0x16c3d6[_0x3f6f84('0x7b')][_0x3f6f84('0x7b')],'phone':_0x229bcb,'SmsAccountId':_0x50a747['id'],'UserId':_0x16c3d6[_0x3f6f84('0x4f')]['id'],'ContactId':_0x376338['id']})]},{'include':[{'model':db[_0x3f6f84('0xa5')],'as':_0x3f6f84('0x7e')}]})[_0x3f6f84('0xb2')](function(_0x1961d1){return[_0x1961d1,!![]];});});})[_0xab8c77('0xb2')](function([_0x41c74f,_0x5b70d5]){const _0x50cb28=_0xab8c77;if(_0x5b70d5)return _0x41c74f;return db['SmsMessage'][_0x50cb28('0x56')](_[_0x50cb28('0x96')](_0x16c3d6[_0x50cb28('0x7b')],{'read':![],'body':_0x16c3d6[_0x50cb28('0x7b')][_0x50cb28('0x7b')],'phone':_0x229bcb,'SmsAccountId':_0x50a747['id'],'SmsInteractionId':_0x41c74f['id'],'UserId':_0x16c3d6[_0x50cb28('0x4f')]['id'],'ContactId':_0x376338['id']}))[_0x50cb28('0xb2')](function(_0x5a0f8c){const _0x32cbbb=_0x50cb28;return _0x41c74f['dataValues'][_0x32cbbb('0x7e')]=[],_0x41c74f['dataValues'][_0x32cbbb('0x7e')][_0x32cbbb('0x99')](_0x5a0f8c[_0x32cbbb('0xa4')]),_0x41c74f;});})[_0xab8c77('0xb2')](respondWithResult(_0x5ccbf7,null))['catch'](handleError(_0x5ccbf7,null));},exports['status']=function(_0x5ef7c3,_0x3309a5){const _0x380dac=_0x22c2fb;_0x5ef7c3['body']['id']&&delete _0x5ef7c3[_0x380dac('0x7b')]['id'];console[_0x380dac('0x64')](_0x380dac('0x46'),_0x5ef7c3[_0x380dac('0x7b')]);let _0x12bdba,_0x52967d,_0x4218c7;return db['SmsAccount'][_0x380dac('0x83')]({'where':{'id':_0x5ef7c3[_0x380dac('0x62')]['id']}})[_0x380dac('0xb2')](handleEntityNotFound(_0x3309a5,null))[_0x380dac('0xb2')](function(_0x5978b7){const _0x19c27f=_0x380dac;if(_0x5978b7){_0x4218c7=_0x5978b7,logger[_0x19c27f('0x5')](_0x19c27f('0xf'),'status',_0x19c27f('0x9a'),_0x5978b7[_0x19c27f('0x85')],util[_0x19c27f('0xa1')](_0x5ef7c3[_0x19c27f('0x7b')],{'showHidden':![],'depth':null}));switch(_0x5978b7[_0x19c27f('0x85')]){case _0x19c27f('0x8e'):if(_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0xb3')]&&_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0xad')])return _0x52967d=_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0xad')],db[_0x19c27f('0xa5')][_0x19c27f('0x83')]({'where':{'messageId':_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0xb3')]}});break;case'connectel':if(_0x5ef7c3[_0x19c27f('0x7b')]['requestid']&&_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0x10')])return _0x52967d=_0x5ef7c3['body'][_0x19c27f('0x10')],db[_0x19c27f('0xa5')]['findOne']({'where':{'messageId':_0x5ef7c3[_0x19c27f('0x7b')]['requestid']}});break;case _0x19c27f('0xbb'):if(_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0x0')]&&_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0x88')])return _0x52967d=_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0x88')],db[_0x19c27f('0xa5')]['findOne']({'where':{'messageId':_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0x0')]}});break;case _0x19c27f('0xa0'):{const _0x539e9b=_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0x14')][0x0];if(_0x539e9b['messageId']&&_0x539e9b[_0x19c27f('0xad')][_0x19c27f('0x87')]==='DELIVERED')return _0x52967d=_0x539e9b['status'][_0x19c27f('0x87')],db[_0x19c27f('0xa5')][_0x19c27f('0x83')]({'where':{'messageId':_0x539e9b[_0x19c27f('0x49')]}});}break;case _0x19c27f('0x59'):if(_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0x49')]&&_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0xad')])return _0x52967d=_0x5ef7c3['body'][_0x19c27f('0xad')],db[_0x19c27f('0xa5')][_0x19c27f('0x83')]({'where':{'messageId':_0x5ef7c3['body']['messageId']}});break;case _0x19c27f('0x2b'):if(_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0xb4')]&&_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0xad')])return _0x52967d=_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0xad')],db[_0x19c27f('0xa5')][_0x19c27f('0x83')]({'where':{'messageId':_0x5ef7c3[_0x19c27f('0x7b')][_0x19c27f('0xb4')]}});break;}}})['then'](handleEntityNotFound(_0x3309a5,null))[_0x380dac('0xb2')](function(_0x355fd0){const _0x443119=_0x380dac;if(_0x355fd0){_0x12bdba=_0x355fd0;switch(_0x4218c7[_0x443119('0x85')]){case'skebby':if(_0x52967d===_0x443119('0x47'))return _0x12bdba[_0x443119('0x8')]({'read':!![]});else logger[_0x443119('0x19')](_0x443119('0xf'),'status',_0x443119('0x8e'),util[_0x443119('0xa1')](_0x5ef7c3[_0x443119('0x7b')],{'showHidden':![],'depth':null}));break;case _0x443119('0x75'):if(_0x52967d==='1')return _0x12bdba[_0x443119('0x8')]({'read':!![]});else logger[_0x443119('0x19')](_0x443119('0xf'),_0x443119('0xad'),_0x443119('0x8e'),util[_0x443119('0xa1')](_0x5ef7c3[_0x443119('0x7b')],{'showHidden':![],'depth':null}));break;case _0x443119('0xbb'):if(!_0x5ef7c3[_0x443119('0x7b')][_0x443119('0xba')]&&_0x52967d>=0xc8&&_0x52967d<=0xce)return _0x12bdba[_0x443119('0x8')]({'read':!![]});else logger[_0x443119('0x19')](_0x443119('0xf'),'status',_0x443119('0xbb'),util[_0x443119('0xa1')](_0x5ef7c3[_0x443119('0x7b')],{'showHidden':![],'depth':null}));break;case _0x443119('0xa0'):{const _0x47059e=_0x5ef7c3[_0x443119('0x7b')]['results'][0x0];if(_0x47059e[_0x443119('0xad')][_0x443119('0x87')]===_0x443119('0x47'))return _0x12bdba[_0x443119('0x8')]({'read':!![]});else logger[_0x443119('0x19')](_0x443119('0xf'),_0x443119('0xad'),'infobip',util['inspect'](_0x5ef7c3[_0x443119('0x7b')],{'showHidden':![],'depth':null}));}break;case _0x443119('0x59'):if(_0x52967d=='DELIVERED_TO_GATEWAY'||_0x52967d=='RECEIVED_BY_RECIPIENT')return _0x12bdba[_0x443119('0x8')]({'read':!![]});else logger[_0x443119('0x19')](_0x443119('0xf'),_0x443119('0xad'),_0x443119('0x59'),util[_0x443119('0xa1')](_0x5ef7c3['body'],{'showHidden':![],'depth':null}));break;case _0x443119('0x2b'):if(_0x52967d===_0x443119('0x7')||_0x52967d==='ACCEPTD')return _0x12bdba[_0x443119('0x8')]({'read':!![]});else logger[_0x443119('0x19')](_0x443119('0xf'),_0x443119('0xad'),_0x443119('0x2b'),util[_0x443119('0xa1')](_0x5ef7c3[_0x443119('0x7b')],{'showHidden':![],'depth':null}));break;}return _0x12bdba;}})[_0x380dac('0xb2')](respondWithResult(_0x3309a5,null))[_0x380dac('0x80')](handleError(_0x3309a5,null));},exports[_0x22c2fb('0x7a')]=function(_0x2f1651,_0x39fed0){const _0x69f7ab=_0x22c2fb;let _0x4cc0be,_0x2f0fe0,_0x5b5ea3;return db[_0x69f7ab('0x4d')][_0x69f7ab('0x83')]({'where':{'id':_0x2f1651[_0x69f7ab('0x62')]['id']}})['then'](handleEntityNotFound(_0x39fed0,null))[_0x69f7ab('0xb2')](function(_0x3fb7be){const _0x4e0778=_0x69f7ab;if(_0x3fb7be){_0x5b5ea3=_0x3fb7be,logger['debug'](_0x4e0778('0xf'),_0x4e0778('0xad'),'received\x20delivery\x20report\x20from',_0x3fb7be[_0x4e0778('0x85')],util[_0x4e0778('0xa1')](_0x2f1651[_0x4e0778('0x8b')],{'showHidden':![],'depth':null}));switch(_0x3fb7be[_0x4e0778('0x85')]){case _0x4e0778('0x32'):if(_0x2f1651[_0x4e0778('0x8b')][_0x4e0778('0xaf')]&&_0x2f1651[_0x4e0778('0x8b')][_0x4e0778('0x90')])return _0x2f0fe0=_0x2f1651[_0x4e0778('0x8b')]['state'],db[_0x4e0778('0xa5')][_0x4e0778('0x83')]({'where':{'messageId':_0x2f1651[_0x4e0778('0x8b')][_0x4e0778('0xaf')]}});break;}}})[_0x69f7ab('0xb2')](handleEntityNotFound(_0x39fed0,null))[_0x69f7ab('0xb2')](function(_0x5a37fb){const _0x3bb4a2=_0x69f7ab;if(_0x5a37fb){_0x4cc0be=_0x5a37fb;switch(_0x5b5ea3[_0x3bb4a2('0x85')]){case _0x3bb4a2('0x32'):if(_0x2f0fe0==='2'||_0x2f0fe0==='6')return _0x4cc0be['update']({'read':!![]});else logger[_0x3bb4a2('0x19')]('SmsAccount,\x20%s,\x20%s,\x20%s',_0x3bb4a2('0xad'),_0x3bb4a2('0x32'),util[_0x3bb4a2('0xa1')](_0x2f1651['query'],{'showHidden':![],'depth':null}));break;}return _0x4cc0be;}})[_0x69f7ab('0xb2')](respondWithResult(_0x39fed0,null))['catch'](handleError(_0x39fed0,null));},exports[_0x22c2fb('0xb')]=function(_0x2394da,_0xe4efe4){const _0x5214ed=_0x22c2fb;return db[_0x5214ed('0x4d')][_0x5214ed('0x83')]({'where':{'id':_0x2394da[_0x5214ed('0x62')]['id']}})[_0x5214ed('0xb2')](function(_0x83c37a){const _0xb86b6f=_0x5214ed;if(_0x83c37a)return _0x83c37a[_0xb86b6f('0xb')](_0x2394da[_0xb86b6f('0x7b')][_0xb86b6f('0x81')],{'through':_[_0xb86b6f('0x7c')](_0x2394da[_0xb86b6f('0x7b')],[_0xb86b6f('0x81'),'id'])})[_0xb86b6f('0xb2')](function(_0x1e1da7){const _0x11fce7=_0xb86b6f;for(let _0x427ba9=0x0;_0x427ba9<_0x2394da[_0x11fce7('0x7b')][_0x11fce7('0x81')][_0x11fce7('0x1f')];_0x427ba9+=0x1){socket[_0x11fce7('0x2a')]('userSmsAccount:save',{'UserId':_0x2394da[_0x11fce7('0x7b')]['ids'][_0x427ba9],'SmsAccountId':_0x2394da[_0x11fce7('0x62')]['id']});}return _0x1e1da7;});})['then'](respondWithResult(_0xe4efe4,null))[_0x5214ed('0x80')](handleError(_0xe4efe4,null));},exports[_0x22c2fb('0x4c')]=function(_0x26d0ab,_0x206e17){const _0x1ce471=_0x22c2fb;return db[_0x1ce471('0x4d')][_0x1ce471('0x83')]({'where':{'id':_0x26d0ab[_0x1ce471('0x62')]['id']}})['then'](handleEntityNotFound(_0x206e17,null))['then'](function(_0x31fd13){const _0x38fbef=_0x1ce471;if(_0x31fd13)return _0x31fd13[_0x38fbef('0x4c')](_0x26d0ab['query'][_0x38fbef('0x81')])[_0x38fbef('0xb2')](function(){const _0x4f673f=_0x38fbef;if(_[_0x4f673f('0x51')](_0x26d0ab[_0x4f673f('0x8b')]['ids']))for(let _0x14b64f=0x0;_0x14b64f<_0x26d0ab[_0x4f673f('0x8b')][_0x4f673f('0x81')]['length'];_0x14b64f+=0x1){socket[_0x4f673f('0x2a')](_0x4f673f('0x1'),{'UserId':Number(_0x26d0ab['query'][_0x4f673f('0x81')][_0x14b64f]),'SmsAccountId':Number(_0x26d0ab[_0x4f673f('0x62')]['id'])});}else socket[_0x4f673f('0x2a')]('userSmsAccount:remove',{'UserId':Number(_0x26d0ab[_0x4f673f('0x8b')]['ids']),'SmsAccountId':Number(_0x26d0ab['params']['id'])});});})['then'](respondWithStatusCode(_0x206e17,null))[_0x1ce471('0x80')](handleError(_0x206e17,null));},exports['getAgents']=function(_0x152da6,_0x2744b0){const _0x41a5f8=_0x22c2fb;let _0x2288af={};const _0x24c530={};let _0x31004e,_0x45b5c6;return db[_0x41a5f8('0x4d')]['findOne']({'where':{'id':_0x152da6[_0x41a5f8('0x62')]['id']}})['then'](handleEntityNotFound(_0x2744b0,null))[_0x41a5f8('0xb2')](function(_0x118167){const _0x218305=_0x41a5f8;if(_0x118167)return _0x31004e=_0x118167,_0x24c530[_0x218305('0x39')]=_[_0x218305('0x1e')](db[_0x218305('0x52')][_0x218305('0x84')]),_0x24c530[_0x218305('0x8b')]=_[_0x218305('0x1e')](_0x152da6['query']),_0x24c530[_0x218305('0x6d')]=_[_0x218305('0x50')](_0x24c530[_0x218305('0x39')],_0x24c530['query']),_0x2288af[_0x218305('0x5c')]=_[_0x218305('0x50')](_0x24c530[_0x218305('0x39')],qs[_0x218305('0x3c')](_0x152da6[_0x218305('0x8b')][_0x218305('0x3c')])),_0x2288af[_0x218305('0x5c')]=_0x2288af[_0x218305('0x5c')][_0x218305('0x1f')]?_0x2288af[_0x218305('0x5c')]:_0x24c530[_0x218305('0x39')],_0x2288af[_0x218305('0x45')]=qs[_0x218305('0x3a')](_0x152da6[_0x218305('0x8b')][_0x218305('0x3a')]),_0x2288af[_0x218305('0x5e')]=qs[_0x218305('0x6d')](_['pick'](_0x152da6['query'],_0x24c530[_0x218305('0x6d')])),_0x152da6[_0x218305('0x8b')]['filter']&&(_0x2288af[_0x218305('0x5e')]=_[_0x218305('0x96')](_0x2288af['where'],{[Op['or']]:_[_0x218305('0x8a')](_0x2288af['attributes'],function(_0x46f93c){const _0x3773ed=_0x218305,_0x546e19={};return _0x546e19[_0x46f93c]={[Op[_0x3773ed('0x36')]]:'%'+_0x152da6[_0x3773ed('0x8b')][_0x3773ed('0x67')]+'%'},_0x546e19;})})),_0x2288af=_[_0x218305('0x96')]({},_0x2288af,_0x152da6[_0x218305('0xb1')]),_0x31004e[_0x218305('0x63')](_0x2288af);})['then'](function(_0x2f390e){const _0x170e53=_0x41a5f8;if(_0x2f390e)return _0x45b5c6=_0x2f390e[_0x170e53('0x1f')],typeof _0x152da6[_0x170e53('0x8b')][_0x170e53('0x7d')]==='undefined'&&(_0x2288af[_0x170e53('0xb7')]=qs['limit'](_0x152da6[_0x170e53('0x8b')]['limit']),_0x2288af[_0x170e53('0x8c')]=qs[_0x170e53('0x8c')](_0x152da6[_0x170e53('0x8b')][_0x170e53('0x8c')])),_0x31004e[_0x170e53('0x63')](_0x2288af);})[_0x41a5f8('0xb2')](function(_0x47b953){if(_0x47b953)return _0x47b953?{'count':_0x45b5c6,'rows':_0x47b953}:null;})[_0x41a5f8('0xb2')](respondWithResult(_0x2744b0,null))[_0x41a5f8('0x80')](handleError(_0x2744b0,null));}; \ No newline at end of file diff --git a/server/api/smsAccount/smsAccount.events.js b/server/api/smsAccount/smsAccount.events.js index 10c56b4..a4b3b16 100644 --- a/server/api/smsAccount/smsAccount.events.js +++ b/server/api/smsAccount/smsAccount.events.js @@ -1 +1 @@ -const a543_0x534d=['addHook','remove','SmsAccount','emit','save','exports','setMaxListeners','../../mysqldb'];(function(_0x23e361,_0x534d90){const _0x48796e=function(_0x5cfb30){while(--_0x5cfb30){_0x23e361['push'](_0x23e361['shift']());}};_0x48796e(++_0x534d90);}(a543_0x534d,0x80));const a543_0x4879=function(_0x23e361,_0x534d90){_0x23e361=_0x23e361-0x0;let _0x48796e=a543_0x534d[_0x23e361];return _0x48796e;};const _0x4412af=a543_0x4879;'use strict';const EventEmitter=require('events'),SmsAccount=require(_0x4412af('0x7'))['db'][_0x4412af('0x2')],SmsAccountEvents=new EventEmitter();SmsAccountEvents[_0x4412af('0x6')](0x0);const events={'afterCreate':_0x4412af('0x4'),'afterUpdate':'update','afterDestroy':_0x4412af('0x1')};function emitEvent(_0x5cfb30){return function(_0x59d103){const _0x40e81a=a543_0x4879;SmsAccountEvents[_0x40e81a('0x3')](_0x5cfb30+':'+_0x59d103['id'],_0x59d103),SmsAccountEvents['emit'](_0x5cfb30,_0x59d103);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];SmsAccount[_0x4412af('0x0')](e,emitEvent(event));}}module[_0x4412af('0x5')]=SmsAccountEvents; \ No newline at end of file +const a543_0x1b14=['setMaxListeners','remove','exports','emit','update','addHook','../../mysqldb','undefined'];(function(_0x6e9045,_0x1b1454){const _0x137085=function(_0xbabdd6){while(--_0xbabdd6){_0x6e9045['push'](_0x6e9045['shift']());}};_0x137085(++_0x1b1454);}(a543_0x1b14,0x8b));const a543_0x1370=function(_0x6e9045,_0x1b1454){_0x6e9045=_0x6e9045-0x0;let _0x137085=a543_0x1b14[_0x6e9045];return _0x137085;};const _0x282447=a543_0x1370;'use strict';const EventEmitter=require('events'),SmsAccount=require(_0x282447('0x3'))['db']['SmsAccount'],SmsAccountEvents=new EventEmitter();SmsAccountEvents[_0x282447('0x5')](0x0);const events={'afterCreate':'save','afterUpdate':_0x282447('0x1'),'afterDestroy':_0x282447('0x6')};function emitEvent(_0xbabdd6){return function(_0x2fb3dc){const _0x5c8efc=a543_0x1370;SmsAccountEvents[_0x5c8efc('0x0')](_0xbabdd6+':'+_0x2fb3dc['id'],_0x2fb3dc),SmsAccountEvents['emit'](_0xbabdd6,_0x2fb3dc);};}for(const e in events){if(typeof events[e]!==_0x282447('0x4')){const event=events[e];SmsAccount[_0x282447('0x2')](e,emitEvent(event));}}module[_0x282447('0x7')]=SmsAccountEvents; \ No newline at end of file diff --git a/server/api/smsAccount/smsAccount.model.js b/server/api/smsAccount/smsAccount.model.js index e9fd2d8..a21cfdc 100644 --- a/server/api/smsAccount/smsAccount.model.js +++ b/server/api/smsAccount/smsAccount.model.js @@ -1 +1 @@ -const a544_0x22c8=['exports','define'];(function(_0xf0b285,_0x22c8d3){const _0x598a5a=function(_0x5894fd){while(--_0x5894fd){_0xf0b285['push'](_0xf0b285['shift']());}};_0x598a5a(++_0x22c8d3);}(a544_0x22c8,0x14e));const a544_0x598a=function(_0xf0b285,_0x22c8d3){_0xf0b285=_0xf0b285-0x0;let _0x598a5a=a544_0x22c8[_0xf0b285];return _0x598a5a;};const _0x10c8f2=a544_0x598a;'use strict';const attributes=require('./smsAccount.attributes');module[_0x10c8f2('0x0')]=function(_0x5894fd){const _0x1c368a=_0x10c8f2,_0x4b2c00=_0x5894fd[_0x1c368a('0x1')]('SmsAccount',attributes,{'tableName':'sms_accounts','paranoid':![],'indexes':[],'timestamps':!![]});return _0x4b2c00;}; \ No newline at end of file +const a544_0x2fb8=['define','exports','SmsAccount','./smsAccount.attributes','sms_accounts'];(function(_0x23acd9,_0x2fb8da){const _0x2cbf36=function(_0x1fc9a4){while(--_0x1fc9a4){_0x23acd9['push'](_0x23acd9['shift']());}};_0x2cbf36(++_0x2fb8da);}(a544_0x2fb8,0x139));const a544_0x2cbf=function(_0x23acd9,_0x2fb8da){_0x23acd9=_0x23acd9-0x0;let _0x2cbf36=a544_0x2fb8[_0x23acd9];return _0x2cbf36;};const _0x29de5b=a544_0x2cbf;'use strict';const attributes=require(_0x29de5b('0x0'));module[_0x29de5b('0x3')]=function(_0x1fc9a4){const _0x4ae3a4=_0x29de5b,_0x3e25a6=_0x1fc9a4[_0x4ae3a4('0x2')](_0x4ae3a4('0x4'),attributes,{'tableName':_0x4ae3a4('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3e25a6;}; \ No newline at end of file diff --git a/server/api/smsAccount/smsAccount.rpc.js b/server/api/smsAccount/smsAccount.rpc.js index 38e243a..06d9cca 100644 --- a/server/api/smsAccount/smsAccount.rpc.js +++ b/server/api/smsAccount/smsAccount.rpc.js @@ -1 +1 @@ -const a545_0x244d=['error','map','options','SmsAccount','register','../../rediscache','rpc','ShowSmsAccount','findOne','include','raw','where','message','model','../../config/logger','catch','attributes','then'];(function(_0x142682,_0x244dd2){const _0x434b7f=function(_0x5f411b){while(--_0x5f411b){_0x142682['push'](_0x142682['shift']());}};_0x434b7f(++_0x244dd2);}(a545_0x244d,0xe5));const a545_0x434b=function(_0x142682,_0x244dd2){_0x142682=_0x142682-0x0;let _0x434b7f=a545_0x244d[_0x142682];return _0x434b7f;};const _0x16783b=a545_0x434b;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x16783b('0x1'))(_0x16783b('0xb')),_=require('lodash'),{getSocket}=require(_0x16783b('0xa')),socket=getSocket();require('./smsAccount.socket')[_0x16783b('0x9')](socket),exports[_0x16783b('0xc')]=function(_0x5f411b){const _0x2989ab=this;return new Promise(function(_0x3502bc,_0x2136a4){const _0x6af606=a545_0x434b;return db[_0x6af606('0x8')][_0x6af606('0xd')]({'raw':_0x5f411b[_0x6af606('0x7')]?_0x5f411b[_0x6af606('0x7')][_0x6af606('0xf')]===undefined?!![]:![]:!![],'where':_0x5f411b[_0x6af606('0x7')]?_0x5f411b[_0x6af606('0x7')][_0x6af606('0x10')]||null:null,'attributes':_0x5f411b[_0x6af606('0x7')]?_0x5f411b[_0x6af606('0x7')][_0x6af606('0x3')]||null:null,'include':_0x5f411b[_0x6af606('0x7')]?_0x5f411b['options'][_0x6af606('0xe')]?_[_0x6af606('0x6')](_0x5f411b[_0x6af606('0x7')][_0x6af606('0xe')],function(_0x2dd517){const _0x2d1c80=_0x6af606;return{'model':db[_0x2dd517[_0x2d1c80('0x0')]],'as':_0x2dd517['as'],'attributes':_0x2dd517[_0x2d1c80('0x3')],'include':_0x2dd517[_0x2d1c80('0xe')]?_[_0x2d1c80('0x6')](_0x2dd517[_0x2d1c80('0xe')],function(_0x490646){const _0x100816=_0x2d1c80;return{'model':db[_0x490646['model']],'as':_0x490646['as'],'attributes':_0x490646[_0x100816('0x3')],'include':_0x490646[_0x100816('0xe')]?_[_0x100816('0x6')](_0x490646['include'],function(_0x14d89d){const _0x5c27a8=_0x100816;return{'model':db[_0x14d89d[_0x5c27a8('0x0')]],'as':_0x14d89d['as'],'attributes':_0x14d89d['attributes']};}):[]};}):[]};}):[]:[]})[_0x6af606('0x4')](function(_0x3f0ca8){const _0x1361ab=_0x6af606;logger['info'](_0x1361ab('0xc'),_0x5f411b),logger['debug']('ShowSmsAccount',_0x5f411b,JSON['stringify'](_0x3f0ca8)),_0x3502bc(_0x3f0ca8);})[_0x6af606('0x2')](function(_0x34a5ff){const _0x5c241c=_0x6af606;logger[_0x5c241c('0x5')]('ShowSmsAccount',_0x34a5ff[_0x5c241c('0x11')],_0x5f411b),_0x2136a4(_0x2989ab[_0x5c241c('0x5')](0x1f4,_0x34a5ff[_0x5c241c('0x11')]));});});}; \ No newline at end of file +const a545_0x1688=['include','rpc','error','model','./smsAccount.socket','attributes','SmsAccount','register','catch','map','info','message','where','options','ShowSmsAccount','raw'];(function(_0x34a2d7,_0x1688eb){const _0x33ff7a=function(_0x4439c6){while(--_0x4439c6){_0x34a2d7['push'](_0x34a2d7['shift']());}};_0x33ff7a(++_0x1688eb);}(a545_0x1688,0x1df));const a545_0x33ff=function(_0x34a2d7,_0x1688eb){_0x34a2d7=_0x34a2d7-0x0;let _0x33ff7a=a545_0x1688[_0x34a2d7];return _0x33ff7a;};const _0x8e8cfb=a545_0x33ff;'use strict';const db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x8e8cfb('0x2')),_=require('lodash'),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x8e8cfb('0x5'))[_0x8e8cfb('0x8')](socket),exports[_0x8e8cfb('0xf')]=function(_0x4439c6){const _0x171410=this;return new Promise(function(_0x9af83f,_0x3978fa){const _0x5a382f=a545_0x33ff;return db[_0x5a382f('0x7')]['findOne']({'raw':_0x4439c6['options']?_0x4439c6['options'][_0x5a382f('0x0')]===undefined?!![]:![]:!![],'where':_0x4439c6[_0x5a382f('0xe')]?_0x4439c6[_0x5a382f('0xe')][_0x5a382f('0xd')]||null:null,'attributes':_0x4439c6[_0x5a382f('0xe')]?_0x4439c6['options']['attributes']||null:null,'include':_0x4439c6[_0x5a382f('0xe')]?_0x4439c6['options']['include']?_[_0x5a382f('0xa')](_0x4439c6[_0x5a382f('0xe')][_0x5a382f('0x1')],function(_0xdec4f1){const _0x42abd1=_0x5a382f;return{'model':db[_0xdec4f1['model']],'as':_0xdec4f1['as'],'attributes':_0xdec4f1[_0x42abd1('0x6')],'include':_0xdec4f1['include']?_[_0x42abd1('0xa')](_0xdec4f1[_0x42abd1('0x1')],function(_0x1f795b){const _0x560973=_0x42abd1;return{'model':db[_0x1f795b[_0x560973('0x4')]],'as':_0x1f795b['as'],'attributes':_0x1f795b[_0x560973('0x6')],'include':_0x1f795b[_0x560973('0x1')]?_[_0x560973('0xa')](_0x1f795b['include'],function(_0xa76b6a){const _0xe7c20d=_0x560973;return{'model':db[_0xa76b6a[_0xe7c20d('0x4')]],'as':_0xa76b6a['as'],'attributes':_0xa76b6a['attributes']};}):[]};}):[]};}):[]:[]})['then'](function(_0x54b17f){const _0x297754=_0x5a382f;logger[_0x297754('0xb')](_0x297754('0xf'),_0x4439c6),logger['debug'](_0x297754('0xf'),_0x4439c6,JSON['stringify'](_0x54b17f)),_0x9af83f(_0x54b17f);})[_0x5a382f('0x9')](function(_0x23c987){const _0x4574c0=_0x5a382f;logger[_0x4574c0('0x3')](_0x4574c0('0xf'),_0x23c987[_0x4574c0('0xc')],_0x4439c6),_0x3978fa(_0x171410[_0x4574c0('0x3')](0x1f4,_0x23c987[_0x4574c0('0xc')]));});});}; \ No newline at end of file diff --git a/server/api/smsAccount/smsAccount.socket.js b/server/api/smsAccount/smsAccount.socket.js index 54c914c..17d1344 100644 --- a/server/api/smsAccount/smsAccount.socket.js +++ b/server/api/smsAccount/smsAccount.socket.js @@ -1 +1 @@ -const a546_0x4f3f=['./smsAccount.events','register','update','remove','save','emit'];(function(_0x152ea1,_0x4f3f1d){const _0x1dd547=function(_0x5e8853){while(--_0x5e8853){_0x152ea1['push'](_0x152ea1['shift']());}};_0x1dd547(++_0x4f3f1d);}(a546_0x4f3f,0x165));const a546_0x1dd5=function(_0x152ea1,_0x4f3f1d){_0x152ea1=_0x152ea1-0x0;let _0x1dd547=a546_0x4f3f[_0x152ea1];return _0x1dd547;};const _0xfcf12=a546_0x1dd5;'use strict';const SmsAccountEvents=require(_0xfcf12('0x3')),events=[_0xfcf12('0x1'),_0xfcf12('0x0'),_0xfcf12('0x5')];function createListener(_0x5e8853,_0xdb2c3e){return function(_0x2d0380){const _0x12ddc8=a546_0x1dd5;_0xdb2c3e[_0x12ddc8('0x2')](_0x5e8853,_0x2d0380);};}exports[_0xfcf12('0x4')]=function(_0x5e5a85){for(let _0x108c1e=0x0,_0x592c29=events['length'];_0x108c1e<_0x592c29;_0x108c1e++){const _0x351a6c=events[_0x108c1e],_0x42300d=createListener('smsAccount:'+_0x351a6c,_0x5e5a85);SmsAccountEvents['on'](_0x351a6c,_0x42300d);}}; \ No newline at end of file +const a546_0x4059=['remove','save','./smsAccount.events','register','update','length'];(function(_0x55fe66,_0x405918){const _0x43275e=function(_0x58a54b){while(--_0x58a54b){_0x55fe66['push'](_0x55fe66['shift']());}};_0x43275e(++_0x405918);}(a546_0x4059,0x1ad));const a546_0x4327=function(_0x55fe66,_0x405918){_0x55fe66=_0x55fe66-0x0;let _0x43275e=a546_0x4059[_0x55fe66];return _0x43275e;};const _0x5ccbc2=a546_0x4327;'use strict';const SmsAccountEvents=require(_0x5ccbc2('0x5')),events=[_0x5ccbc2('0x4'),_0x5ccbc2('0x3'),_0x5ccbc2('0x1')];function createListener(_0x58a54b,_0xe4e6d){return function(_0x4a2352){_0xe4e6d['emit'](_0x58a54b,_0x4a2352);};}exports[_0x5ccbc2('0x0')]=function(_0x395ebb){const _0x35903a=_0x5ccbc2;for(let _0x239be0=0x0,_0xa20b59=events[_0x35903a('0x2')];_0x239be0<_0xa20b59;_0x239be0++){const _0x7fbe80=events[_0x239be0],_0x4d1aa3=createListener('smsAccount:'+_0x7fbe80,_0x395ebb);SmsAccountEvents['on'](_0x7fbe80,_0x4d1aa3);}}; \ No newline at end of file diff --git a/server/api/smsApplication/index.js b/server/api/smsApplication/index.js index 6ae9b08..0506587 100644 --- a/server/api/smsApplication/index.js +++ b/server/api/smsApplication/index.js @@ -1 +1 @@ -const a547_0x15ee=['show','delete','Router','index','exports','express','get','../../components/auth/service','create','put','isAuthenticated','/:id','update','./smsApplication.controller'];(function(_0x35134d,_0x15ee32){const _0x5380c3=function(_0x4a3c7a){while(--_0x4a3c7a){_0x35134d['push'](_0x35134d['shift']());}};_0x5380c3(++_0x15ee32);}(a547_0x15ee,0x6c));const a547_0x5380=function(_0x35134d,_0x15ee32){_0x35134d=_0x35134d-0x0;let _0x5380c3=a547_0x15ee[_0x35134d];return _0x5380c3;};const _0x41ae2e=a547_0x5380;'use strict';const express=require(_0x41ae2e('0x9')),router=express[_0x41ae2e('0x6')](),auth=require(_0x41ae2e('0xb')),controller=require(_0x41ae2e('0x3'));router[_0x41ae2e('0xa')]('/',auth[_0x41ae2e('0x0')](),controller[_0x41ae2e('0x7')]),router['get'](_0x41ae2e('0x1'),auth[_0x41ae2e('0x0')](),controller[_0x41ae2e('0x4')]),router['post']('/',auth['isAuthenticated'](),controller[_0x41ae2e('0xc')]),router[_0x41ae2e('0xd')]('/:id',auth[_0x41ae2e('0x0')](),controller[_0x41ae2e('0x2')]),router[_0x41ae2e('0x5')]('/:id',auth[_0x41ae2e('0x0')](),controller['destroy']),module[_0x41ae2e('0x8')]=router; \ No newline at end of file +const a547_0x58df=['delete','/:id','isAuthenticated','express','create','./smsApplication.controller','put','post','Router','exports','get','destroy'];(function(_0x4a6a01,_0x58df16){const _0x13e80b=function(_0x22a5f2){while(--_0x22a5f2){_0x4a6a01['push'](_0x4a6a01['shift']());}};_0x13e80b(++_0x58df16);}(a547_0x58df,0x7e));const a547_0x13e8=function(_0x4a6a01,_0x58df16){_0x4a6a01=_0x4a6a01-0x0;let _0x13e80b=a547_0x58df[_0x4a6a01];return _0x13e80b;};const _0x36ecef=a547_0x13e8;'use strict';const express=require(_0x36ecef('0x9')),router=express[_0x36ecef('0x2')](),auth=require('../../components/auth/service'),controller=require(_0x36ecef('0xb'));router[_0x36ecef('0x4')]('/',auth[_0x36ecef('0x8')](),controller['index']),router[_0x36ecef('0x4')](_0x36ecef('0x7'),auth['isAuthenticated'](),controller['show']),router[_0x36ecef('0x1')]('/',auth[_0x36ecef('0x8')](),controller[_0x36ecef('0xa')]),router[_0x36ecef('0x0')](_0x36ecef('0x7'),auth[_0x36ecef('0x8')](),controller['update']),router[_0x36ecef('0x6')]('/:id',auth[_0x36ecef('0x8')](),controller[_0x36ecef('0x5')]),module[_0x36ecef('0x3')]=router; \ No newline at end of file diff --git a/server/api/smsApplication/smsApplication.attributes.js b/server/api/smsApplication/smsApplication.attributes.js index 0a16ff0..33e0e01 100644 --- a/server/api/smsApplication/smsApplication.attributes.js +++ b/server/api/smsApplication/smsApplication.attributes.js @@ -1 +1 @@ -const a548_0xa1f1=['sequelize','noop','STRING','exports','TEXT'];(function(_0x55bcbe,_0xa1f11f){const _0x3f5626=function(_0xa3615d){while(--_0xa3615d){_0x55bcbe['push'](_0x55bcbe['shift']());}};_0x3f5626(++_0xa1f11f);}(a548_0xa1f1,0x1d8));const a548_0x3f56=function(_0x55bcbe,_0xa1f11f){_0x55bcbe=_0x55bcbe-0x0;let _0x3f5626=a548_0xa1f1[_0x55bcbe];return _0x3f5626;};const _0x292432=a548_0x3f56;'use strict';const Sequelize=require(_0x292432('0x3'));module[_0x292432('0x1')]={'priority':{'type':Sequelize['INTEGER'],'allowNull':![]},'app':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x292432('0x4')},'appdata':{'type':Sequelize[_0x292432('0x2')]()},'description':{'type':Sequelize['STRING']},'interval':{'type':Sequelize[_0x292432('0x0')],'defaultValue':'*,*,*,*'}}; \ No newline at end of file +const a548_0x5b91=['TEXT','noop','*,*,*,*','INTEGER','STRING'];(function(_0x441c7e,_0x5b9193){const _0x3d8746=function(_0x48742e){while(--_0x48742e){_0x441c7e['push'](_0x441c7e['shift']());}};_0x3d8746(++_0x5b9193);}(a548_0x5b91,0x9e));const a548_0x3d87=function(_0x441c7e,_0x5b9193){_0x441c7e=_0x441c7e-0x0;let _0x3d8746=a548_0x5b91[_0x441c7e];return _0x3d8746;};const _0x44fadb=a548_0x3d87;'use strict';const Sequelize=require('sequelize');module['exports']={'priority':{'type':Sequelize[_0x44fadb('0x0')],'allowNull':![]},'app':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x44fadb('0x3')},'appdata':{'type':Sequelize[_0x44fadb('0x2')]()},'description':{'type':Sequelize[_0x44fadb('0x1')]},'interval':{'type':Sequelize['STRING'],'defaultValue':_0x44fadb('0x4')}}; \ No newline at end of file diff --git a/server/api/smsApplication/smsApplication.controller.js b/server/api/smsApplication/smsApplication.controller.js index 990d067..10bbfcd 100644 --- a/server/api/smsApplication/smsApplication.controller.js +++ b/server/api/smsApplication/smsApplication.controller.js @@ -1 +1 @@ -const a549_0x9552=['index','name','fieldName','like','body','destroy','findOne','update','catch','model','stack','create','length','../../config/logger','include','options','attributes','VIRTUAL','undefined','end','../../components/parsers/qs','Content-Range','filter','map','api','then','nolimit','SmsApplication','status','sort','show','json','filters','error','offset','keys','lodash','findAll','query','sequelize','sendStatus','merge','key','order','rawAttributes','fields','where','params','intersection','includeAll','type','limit','count'];(function(_0x667cd0,_0x95527d){const _0x26b279=function(_0x298454){while(--_0x298454){_0x667cd0['push'](_0x667cd0['shift']());}};_0x26b279(++_0x95527d);}(a549_0x9552,0xd7));const a549_0x26b2=function(_0x667cd0,_0x95527d){_0x667cd0=_0x667cd0-0x0;let _0x26b279=a549_0x9552[_0x667cd0];return _0x26b279;};const _0x1a1050=a549_0x26b2;'use strict';const _=require(_0x1a1050('0x21')),qs=require(_0x1a1050('0x11')),logger=require(_0x1a1050('0xa'))(_0x1a1050('0x15')),db=require('../../mysqldb')['db'],{Op}=require(_0x1a1050('0x24'));function respondWithResult(_0x298454,_0x359673){return _0x359673=_0x359673||0xc8,function(_0x405182){const _0x605e6b=a549_0x26b2;if(_0x405182)return _0x298454[_0x605e6b('0x19')](_0x359673)[_0x605e6b('0x1c')](_0x405182);};}function respondWithFilteredResult(_0x1eabe9,_0x1315d9){return function(_0x49c750){const _0xab14f1=a549_0x26b2;if(_0x49c750){const _0x302974=_0x49c750['count'],_0x5054b9=_0x1315d9[_0xab14f1('0x1f')];let _0x3ee707=_0x1315d9['offset']+_0x1315d9[_0xab14f1('0x30')],_0x191c51;return _0x3ee707>=_0x302974?(_0x3ee707=_0x302974,_0x191c51=0xc8):_0x191c51=0xce,_0x1eabe9[_0xab14f1('0x19')](_0x191c51),_0x1eabe9['set'](_0xab14f1('0x12'),_0x5054b9+'-'+_0x3ee707+'/'+_0x302974)[_0xab14f1('0x1c')](_0x49c750);}return null;};}function saveUpdates(_0x3c3283){return function(_0x500451){const _0x4f73dd=a549_0x26b2;if(_0x500451)return _0x500451[_0x4f73dd('0x4')](_0x3c3283)[_0x4f73dd('0x16')](function(_0x5f3fde){return _0x5f3fde;});return null;};}function removeEntity(_0x4a9f37){return function(_0x205ef0){const _0x1d3474=a549_0x26b2;if(_0x205ef0)return _0x205ef0[_0x1d3474('0x2')]()['then'](function(){const _0x14c8b3=_0x1d3474;_0x4a9f37['status'](0xcc)[_0x14c8b3('0x10')]();});};}function handleEntityNotFound(_0x26a43b){return function(_0x1b6e5b){const _0x35876e=a549_0x26b2;return!_0x1b6e5b&&_0x26a43b[_0x35876e('0x25')](0x194),_0x1b6e5b;};}function handleError(_0x1297b3,_0xdee7bb){return _0xdee7bb=_0xdee7bb||0x1f4,function(_0x47d528){const _0x5063e9=a549_0x26b2;logger[_0x5063e9('0x1e')](_0x47d528[_0x5063e9('0x7')]),_0x47d528[_0x5063e9('0x33')]&&delete _0x47d528['name'],_0x1297b3[_0x5063e9('0x19')](_0xdee7bb)['send'](_0x47d528);};}exports[_0x1a1050('0x32')]=function(_0x34011e,_0x47e71a){const _0xe2874f=_0x1a1050;let _0x2b56ce={};const _0x41a8c4={},_0x55a7a0={'count':0x0,'rows':[]},_0x2c8034=_['map'](db[_0xe2874f('0x18')][_0xe2874f('0x29')],function(_0x5a28e8){const _0x4ac02a=_0xe2874f;return{'name':_0x5a28e8[_0x4ac02a('0x34')],'type':_0x5a28e8[_0x4ac02a('0x2f')][_0x4ac02a('0x27')]};});_0x41a8c4[_0xe2874f('0x6')]=_[_0xe2874f('0x14')](_0x2c8034,_0xe2874f('0x33')),_0x41a8c4[_0xe2874f('0x23')]=_[_0xe2874f('0x20')](_0x34011e[_0xe2874f('0x23')]),_0x41a8c4['filters']=_[_0xe2874f('0x2d')](_0x41a8c4[_0xe2874f('0x6')],_0x41a8c4[_0xe2874f('0x23')]),_0x2b56ce[_0xe2874f('0xd')]=_[_0xe2874f('0x2d')](_0x41a8c4['model'],qs['fields'](_0x34011e[_0xe2874f('0x23')][_0xe2874f('0x2a')])),_0x2b56ce[_0xe2874f('0xd')]=_0x2b56ce[_0xe2874f('0xd')][_0xe2874f('0x9')]?_0x2b56ce['attributes']:_0x41a8c4[_0xe2874f('0x6')];typeof _0x34011e[_0xe2874f('0x23')][_0xe2874f('0x17')]===_0xe2874f('0xf')&&(_0x2b56ce['limit']=qs['limit'](_0x34011e['query'][_0xe2874f('0x30')]),_0x2b56ce[_0xe2874f('0x1f')]=qs[_0xe2874f('0x1f')](_0x34011e[_0xe2874f('0x23')]['offset']));_0x2b56ce[_0xe2874f('0x28')]=qs[_0xe2874f('0x1a')](_0x34011e[_0xe2874f('0x23')][_0xe2874f('0x1a')]),_0x2b56ce[_0xe2874f('0x2b')]=qs[_0xe2874f('0x1d')](_['pick'](_0x34011e[_0xe2874f('0x23')],_0x41a8c4[_0xe2874f('0x1d')]),_0x2c8034);_0x34011e['query'][_0xe2874f('0x13')]&&(_0x2b56ce[_0xe2874f('0x2b')]=_[_0xe2874f('0x26')](_0x2b56ce[_0xe2874f('0x2b')],{[Op['or']]:_[_0xe2874f('0x14')](_0x2c8034,function(_0x8553ef){const _0x3bedb3=_0xe2874f;if(_0x8553ef[_0x3bedb3('0x2f')]!==_0x3bedb3('0xe')){const _0x561771={};return _0x561771[_0x8553ef[_0x3bedb3('0x33')]]={[Op[_0x3bedb3('0x0')]]:'%'+_0x34011e[_0x3bedb3('0x23')][_0x3bedb3('0x13')]+'%'},_0x561771;}})}));_0x2b56ce=_[_0xe2874f('0x26')]({},_0x2b56ce,_0x34011e[_0xe2874f('0xc')]);const _0x3cee60={'where':_0x2b56ce[_0xe2874f('0x2b')]};return db[_0xe2874f('0x18')][_0xe2874f('0x31')](_0x3cee60)[_0xe2874f('0x16')](function(_0x595bb0){const _0x5844e7=_0xe2874f;return _0x55a7a0[_0x5844e7('0x31')]=_0x595bb0,_0x34011e[_0x5844e7('0x23')][_0x5844e7('0x2e')]&&(_0x2b56ce[_0x5844e7('0xb')]=[{'all':!![]}]),db['SmsApplication'][_0x5844e7('0x22')](_0x2b56ce);})['then'](function(_0x880e39){return _0x55a7a0['rows']=_0x880e39,_0x55a7a0;})[_0xe2874f('0x16')](respondWithFilteredResult(_0x47e71a,_0x2b56ce))[_0xe2874f('0x5')](handleError(_0x47e71a,null));},exports[_0x1a1050('0x1b')]=function(_0x351fec,_0x17bd0d){const _0x591aa3=_0x1a1050;let _0x2223d3={'raw':!![],'where':{'id':_0x351fec[_0x591aa3('0x2c')]['id']}};const _0x75c89={};return _0x75c89['model']=_[_0x591aa3('0x20')](db[_0x591aa3('0x18')]['rawAttributes']),_0x75c89['query']=_[_0x591aa3('0x20')](_0x351fec['query']),_0x75c89[_0x591aa3('0x1d')]=_['intersection'](_0x75c89['model'],_0x75c89['query']),_0x2223d3[_0x591aa3('0xd')]=_[_0x591aa3('0x2d')](_0x75c89[_0x591aa3('0x6')],qs[_0x591aa3('0x2a')](_0x351fec[_0x591aa3('0x23')][_0x591aa3('0x2a')])),_0x2223d3[_0x591aa3('0xd')]=_0x2223d3[_0x591aa3('0xd')][_0x591aa3('0x9')]?_0x2223d3[_0x591aa3('0xd')]:_0x75c89['model'],_0x351fec[_0x591aa3('0x23')][_0x591aa3('0x2e')]&&(_0x2223d3['include']=[{'all':!![]}]),_0x2223d3=_['merge']({},_0x2223d3,_0x351fec[_0x591aa3('0xc')]),db['SmsApplication'][_0x591aa3('0x3')](_0x2223d3)[_0x591aa3('0x16')](handleEntityNotFound(_0x17bd0d,null))[_0x591aa3('0x16')](respondWithResult(_0x17bd0d,null))[_0x591aa3('0x5')](handleError(_0x17bd0d,null));},exports[_0x1a1050('0x8')]=function(_0x1c9cb8,_0x3a41f6){const _0x150429=_0x1a1050;return db[_0x150429('0x18')][_0x150429('0x8')](_0x1c9cb8[_0x150429('0x1')],{})[_0x150429('0x16')](respondWithResult(_0x3a41f6,0xc9))[_0x150429('0x5')](handleError(_0x3a41f6,null));},exports[_0x1a1050('0x4')]=function(_0x181887,_0x36e636){const _0x403867=_0x1a1050;return _0x181887['body']['id']&&delete _0x181887[_0x403867('0x1')]['id'],db[_0x403867('0x18')][_0x403867('0x3')]({'where':{'id':_0x181887[_0x403867('0x2c')]['id']}})[_0x403867('0x16')](handleEntityNotFound(_0x36e636,null))[_0x403867('0x16')](saveUpdates(_0x181887[_0x403867('0x1')],null))[_0x403867('0x16')](respondWithResult(_0x36e636,null))[_0x403867('0x5')](handleError(_0x36e636,null));},exports[_0x1a1050('0x2')]=function(_0x1a52c6,_0x50daf8){const _0x140590=_0x1a1050;return db[_0x140590('0x18')]['findOne']({'where':{'id':_0x1a52c6[_0x140590('0x2c')]['id']}})[_0x140590('0x16')](handleEntityNotFound(_0x50daf8,null))[_0x140590('0x16')](removeEntity(_0x50daf8,null))['catch'](handleError(_0x50daf8,null));}; \ No newline at end of file +const a549_0x54b9=['type','destroy','filter','model','SmsApplication','merge','offset','fields','query','rawAttributes','count','../../components/parsers/qs','lodash','params','status','includeAll','rows','json','create','map','../../mysqldb','sendStatus','nolimit','keys','stack','error','name','intersection','length','catch','where','end','findOne','filters','attributes','sequelize','include','VIRTUAL','sort','then','body','options','findAll','index','fieldName','limit','api'];(function(_0x28bc02,_0x54b9c1){const _0x40aa12=function(_0x5cd164){while(--_0x5cd164){_0x28bc02['push'](_0x28bc02['shift']());}};_0x40aa12(++_0x54b9c1);}(a549_0x54b9,0x114));const a549_0x40aa=function(_0x28bc02,_0x54b9c1){_0x28bc02=_0x28bc02-0x0;let _0x40aa12=a549_0x54b9[_0x28bc02];return _0x40aa12;};const _0x45594b=a549_0x40aa;'use strict';const _=require(_0x45594b('0x12')),qs=require(_0x45594b('0x11')),logger=require('../../config/logger')(_0x45594b('0x5')),db=require(_0x45594b('0x1a'))['db'],{Op}=require(_0x45594b('0x29'));function respondWithResult(_0x5cd164,_0x24b88a){return _0x24b88a=_0x24b88a||0xc8,function(_0x3d3c01){const _0x5e961e=a549_0x40aa;if(_0x3d3c01)return _0x5cd164[_0x5e961e('0x14')](_0x24b88a)[_0x5e961e('0x17')](_0x3d3c01);};}function respondWithFilteredResult(_0x18728c,_0xfe09a){return function(_0x1dd2ee){const _0x336417=a549_0x40aa;if(_0x1dd2ee){const _0x3a1d57=_0x1dd2ee[_0x336417('0x10')],_0x16bae2=_0xfe09a[_0x336417('0xc')];let _0x4d68fa=_0xfe09a[_0x336417('0xc')]+_0xfe09a['limit'],_0x39039e;return _0x4d68fa>=_0x3a1d57?(_0x4d68fa=_0x3a1d57,_0x39039e=0xc8):_0x39039e=0xce,_0x18728c['status'](_0x39039e),_0x18728c['set']('Content-Range',_0x16bae2+'-'+_0x4d68fa+'/'+_0x3a1d57)[_0x336417('0x17')](_0x1dd2ee);}return null;};}function saveUpdates(_0x53284a){return function(_0x32f37f){if(_0x32f37f)return _0x32f37f['update'](_0x53284a)['then'](function(_0x12e401){return _0x12e401;});return null;};}function removeEntity(_0x7531c2){return function(_0x487e22){const _0x3d1eb8=a549_0x40aa;if(_0x487e22)return _0x487e22['destroy']()[_0x3d1eb8('0x2d')](function(){const _0x536268=_0x3d1eb8;_0x7531c2[_0x536268('0x14')](0xcc)[_0x536268('0x25')]();});};}function handleEntityNotFound(_0x2c1ae4){return function(_0x4e98d5){const _0x468598=a549_0x40aa;return!_0x4e98d5&&_0x2c1ae4[_0x468598('0x1b')](0x194),_0x4e98d5;};}function handleError(_0x59bc53,_0x4107aa){return _0x4107aa=_0x4107aa||0x1f4,function(_0x1e5b2f){const _0x3d95ee=a549_0x40aa;logger[_0x3d95ee('0x1f')](_0x1e5b2f[_0x3d95ee('0x1e')]),_0x1e5b2f['name']&&delete _0x1e5b2f[_0x3d95ee('0x20')],_0x59bc53['status'](_0x4107aa)['send'](_0x1e5b2f);};}exports[_0x45594b('0x2')]=function(_0x1a51ca,_0x545044){const _0x2b2336=_0x45594b;let _0x1adbd6={};const _0xe7cdcb={},_0x140b05={'count':0x0,'rows':[]},_0x5014ff=_['map'](db['SmsApplication'][_0x2b2336('0xf')],function(_0x5a9d34){const _0x4cc22b=_0x2b2336;return{'name':_0x5a9d34[_0x4cc22b('0x3')],'type':_0x5a9d34[_0x4cc22b('0x6')]['key']};});_0xe7cdcb[_0x2b2336('0x9')]=_[_0x2b2336('0x19')](_0x5014ff,_0x2b2336('0x20')),_0xe7cdcb[_0x2b2336('0xe')]=_['keys'](_0x1a51ca['query']),_0xe7cdcb[_0x2b2336('0x27')]=_['intersection'](_0xe7cdcb[_0x2b2336('0x9')],_0xe7cdcb[_0x2b2336('0xe')]),_0x1adbd6[_0x2b2336('0x28')]=_[_0x2b2336('0x21')](_0xe7cdcb['model'],qs['fields'](_0x1a51ca['query'][_0x2b2336('0xd')])),_0x1adbd6[_0x2b2336('0x28')]=_0x1adbd6[_0x2b2336('0x28')][_0x2b2336('0x22')]?_0x1adbd6[_0x2b2336('0x28')]:_0xe7cdcb[_0x2b2336('0x9')];typeof _0x1a51ca[_0x2b2336('0xe')][_0x2b2336('0x1c')]==='undefined'&&(_0x1adbd6[_0x2b2336('0x4')]=qs[_0x2b2336('0x4')](_0x1a51ca[_0x2b2336('0xe')][_0x2b2336('0x4')]),_0x1adbd6[_0x2b2336('0xc')]=qs['offset'](_0x1a51ca[_0x2b2336('0xe')][_0x2b2336('0xc')]));_0x1adbd6['order']=qs[_0x2b2336('0x2c')](_0x1a51ca[_0x2b2336('0xe')][_0x2b2336('0x2c')]),_0x1adbd6['where']=qs['filters'](_['pick'](_0x1a51ca[_0x2b2336('0xe')],_0xe7cdcb[_0x2b2336('0x27')]),_0x5014ff);_0x1a51ca[_0x2b2336('0xe')][_0x2b2336('0x8')]&&(_0x1adbd6[_0x2b2336('0x24')]=_['merge'](_0x1adbd6[_0x2b2336('0x24')],{[Op['or']]:_[_0x2b2336('0x19')](_0x5014ff,function(_0x1c3bcf){const _0x14cc6c=_0x2b2336;if(_0x1c3bcf[_0x14cc6c('0x6')]!==_0x14cc6c('0x2b')){const _0x4002d9={};return _0x4002d9[_0x1c3bcf['name']]={[Op['like']]:'%'+_0x1a51ca[_0x14cc6c('0xe')][_0x14cc6c('0x8')]+'%'},_0x4002d9;}})}));_0x1adbd6=_[_0x2b2336('0xb')]({},_0x1adbd6,_0x1a51ca[_0x2b2336('0x0')]);const _0x352124={'where':_0x1adbd6['where']};return db[_0x2b2336('0xa')]['count'](_0x352124)[_0x2b2336('0x2d')](function(_0xc4d4cf){const _0x1ab7ec=_0x2b2336;return _0x140b05[_0x1ab7ec('0x10')]=_0xc4d4cf,_0x1a51ca['query'][_0x1ab7ec('0x15')]&&(_0x1adbd6[_0x1ab7ec('0x2a')]=[{'all':!![]}]),db[_0x1ab7ec('0xa')][_0x1ab7ec('0x1')](_0x1adbd6);})[_0x2b2336('0x2d')](function(_0x3b1187){const _0x52bd1a=_0x2b2336;return _0x140b05[_0x52bd1a('0x16')]=_0x3b1187,_0x140b05;})['then'](respondWithFilteredResult(_0x545044,_0x1adbd6))['catch'](handleError(_0x545044,null));},exports['show']=function(_0x1a4d59,_0x2ec18d){const _0x3fd390=_0x45594b;let _0x5630ee={'raw':!![],'where':{'id':_0x1a4d59[_0x3fd390('0x13')]['id']}};const _0x57272d={};return _0x57272d[_0x3fd390('0x9')]=_['keys'](db[_0x3fd390('0xa')]['rawAttributes']),_0x57272d[_0x3fd390('0xe')]=_[_0x3fd390('0x1d')](_0x1a4d59['query']),_0x57272d[_0x3fd390('0x27')]=_[_0x3fd390('0x21')](_0x57272d[_0x3fd390('0x9')],_0x57272d[_0x3fd390('0xe')]),_0x5630ee[_0x3fd390('0x28')]=_[_0x3fd390('0x21')](_0x57272d[_0x3fd390('0x9')],qs[_0x3fd390('0xd')](_0x1a4d59['query'][_0x3fd390('0xd')])),_0x5630ee['attributes']=_0x5630ee['attributes'][_0x3fd390('0x22')]?_0x5630ee[_0x3fd390('0x28')]:_0x57272d[_0x3fd390('0x9')],_0x1a4d59[_0x3fd390('0xe')][_0x3fd390('0x15')]&&(_0x5630ee[_0x3fd390('0x2a')]=[{'all':!![]}]),_0x5630ee=_['merge']({},_0x5630ee,_0x1a4d59['options']),db[_0x3fd390('0xa')][_0x3fd390('0x26')](_0x5630ee)[_0x3fd390('0x2d')](handleEntityNotFound(_0x2ec18d,null))[_0x3fd390('0x2d')](respondWithResult(_0x2ec18d,null))[_0x3fd390('0x23')](handleError(_0x2ec18d,null));},exports[_0x45594b('0x18')]=function(_0x29b82f,_0x44a5ce){const _0x486a62=_0x45594b;return db['SmsApplication'][_0x486a62('0x18')](_0x29b82f[_0x486a62('0x2e')],{})['then'](respondWithResult(_0x44a5ce,0xc9))['catch'](handleError(_0x44a5ce,null));},exports['update']=function(_0x2674ea,_0x4eb5db){const _0x21f04d=_0x45594b;return _0x2674ea['body']['id']&&delete _0x2674ea['body']['id'],db[_0x21f04d('0xa')][_0x21f04d('0x26')]({'where':{'id':_0x2674ea[_0x21f04d('0x13')]['id']}})['then'](handleEntityNotFound(_0x4eb5db,null))[_0x21f04d('0x2d')](saveUpdates(_0x2674ea[_0x21f04d('0x2e')],null))[_0x21f04d('0x2d')](respondWithResult(_0x4eb5db,null))[_0x21f04d('0x23')](handleError(_0x4eb5db,null));},exports[_0x45594b('0x7')]=function(_0x36048c,_0x45c657){const _0x56da2c=_0x45594b;return db[_0x56da2c('0xa')][_0x56da2c('0x26')]({'where':{'id':_0x36048c[_0x56da2c('0x13')]['id']}})[_0x56da2c('0x2d')](handleEntityNotFound(_0x45c657,null))[_0x56da2c('0x2d')](removeEntity(_0x45c657,null))['catch'](handleError(_0x45c657,null));}; \ No newline at end of file diff --git a/server/api/smsApplication/smsApplication.model.js b/server/api/smsApplication/smsApplication.model.js index 1acd42a..217602a 100644 --- a/server/api/smsApplication/smsApplication.model.js +++ b/server/api/smsApplication/smsApplication.model.js @@ -1 +1 @@ -const a550_0x227c=['sms_applications','SmsApplication','./smsApplication.attributes','utf8mb4_unicode_ci','utf8mb4','exports','define'];(function(_0x43a0d5,_0x227c75){const _0x5de3d2=function(_0x46b6bb){while(--_0x46b6bb){_0x43a0d5['push'](_0x43a0d5['shift']());}};_0x5de3d2(++_0x227c75);}(a550_0x227c,0xc3));const a550_0x5de3=function(_0x43a0d5,_0x227c75){_0x43a0d5=_0x43a0d5-0x0;let _0x5de3d2=a550_0x227c[_0x43a0d5];return _0x5de3d2;};const _0x572c6b=a550_0x5de3;'use strict';const attributes=require(_0x572c6b('0x3'));module[_0x572c6b('0x6')]=function(_0x46b6bb){const _0x34b005=_0x572c6b,_0x973169=_0x46b6bb[_0x34b005('0x0')](_0x34b005('0x2'),attributes,{'tableName':_0x34b005('0x1'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x34b005('0x5'),'collate':_0x34b005('0x4')});return _0x973169;}; \ No newline at end of file +const a550_0x2090=['utf8mb4','exports','./smsApplication.attributes','sms_applications','utf8mb4_unicode_ci','define','SmsApplication'];(function(_0x3754e0,_0x209007){const _0x20fa42=function(_0xf08316){while(--_0xf08316){_0x3754e0['push'](_0x3754e0['shift']());}};_0x20fa42(++_0x209007);}(a550_0x2090,0x7e));const a550_0x20fa=function(_0x3754e0,_0x209007){_0x3754e0=_0x3754e0-0x0;let _0x20fa42=a550_0x2090[_0x3754e0];return _0x20fa42;};const _0x5ed98b=a550_0x20fa;'use strict';const attributes=require(_0x5ed98b('0x2'));module[_0x5ed98b('0x1')]=function(_0xf08316){const _0x448aae=_0x5ed98b,_0x5ced68=_0xf08316[_0x448aae('0x5')](_0x448aae('0x6'),attributes,{'tableName':_0x448aae('0x3'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x448aae('0x0'),'collate':_0x448aae('0x4')});return _0x5ced68;}; \ No newline at end of file diff --git a/server/api/smsInteraction/index.js b/server/api/smsInteraction/index.js index ee90d43..23af3c4 100644 --- a/server/api/smsInteraction/index.js +++ b/server/api/smsInteraction/index.js @@ -1 +1 @@ -const a551_0x46e3=['smsinteraction:destroy','/:id/messages','isAuthenticated','/describe','create','sms','addTags','/:id/tags','getMessages','./smsInteraction.controller','tracked','destroy','/:id/download','get','/:id','delete','smsinteraction:update','exports','post','../../components/interaction/service','addMessage','index','put','update','../../components/auth/service','removeTags','download','Router','show'];(function(_0x3bdfc0,_0x46e3df){const _0x607c87=function(_0x54f2ce){while(--_0x54f2ce){_0x3bdfc0['push'](_0x3bdfc0['shift']());}};_0x607c87(++_0x46e3df);}(a551_0x46e3,0x1de));const a551_0x607c=function(_0x3bdfc0,_0x46e3df){_0x3bdfc0=_0x3bdfc0-0x0;let _0x607c87=a551_0x46e3[_0x3bdfc0];return _0x607c87;};const _0x5a528b=a551_0x607c;'use strict';const express=require('express'),router=express[_0x5a528b('0xd')](),auth=require(_0x5a528b('0xa')),interaction=require(_0x5a528b('0x5')),controller=require(_0x5a528b('0x18'));router[_0x5a528b('0x1c')]('/',auth[_0x5a528b('0x11')](),controller[_0x5a528b('0x7')]),router['get'](_0x5a528b('0x12'),auth['isAuthenticated'](),controller['describe']),router[_0x5a528b('0x1c')](_0x5a528b('0x0'),auth['isAuthenticated'](),controller[_0x5a528b('0xe')]),router[_0x5a528b('0x1c')](_0x5a528b('0x10'),auth[_0x5a528b('0x11')](),controller[_0x5a528b('0x17')]),router[_0x5a528b('0x1c')](_0x5a528b('0x1b'),auth[_0x5a528b('0x11')](),controller[_0x5a528b('0xc')]),router[_0x5a528b('0x4')]('/',auth[_0x5a528b('0x11')](),controller[_0x5a528b('0x13')]),router[_0x5a528b('0x4')](_0x5a528b('0x10'),auth['isAuthenticated'](),controller[_0x5a528b('0x6')]),router[_0x5a528b('0x4')](_0x5a528b('0x16'),auth[_0x5a528b('0x11')](),interaction[_0x5a528b('0x19')](_0x5a528b('0x14'),'smsinteraction:addtags'),controller[_0x5a528b('0x15')]),router[_0x5a528b('0x8')]('/:id',auth['isAuthenticated'](),interaction[_0x5a528b('0x19')]('sms',_0x5a528b('0x2')),controller[_0x5a528b('0x9')]),router[_0x5a528b('0x1')](_0x5a528b('0x0'),auth[_0x5a528b('0x11')](),interaction['tracked'](_0x5a528b('0x14'),_0x5a528b('0xf')),controller[_0x5a528b('0x1a')]),router['delete'](_0x5a528b('0x16'),auth[_0x5a528b('0x11')](),controller[_0x5a528b('0xb')]),module[_0x5a528b('0x3')]=router; \ No newline at end of file +const a551_0x3091=['tracked','../../components/auth/service','describe','addTags','/:id/messages','express','download','index','/:id','Router','sms','addMessage','post','show','isAuthenticated','get','smsinteraction:addtags','delete','/describe','put','/:id/download','./smsInteraction.controller','getMessages','smsinteraction:update','update'];(function(_0x3934da,_0x3091a1){const _0x441bd3=function(_0x27b100){while(--_0x27b100){_0x3934da['push'](_0x3934da['shift']());}};_0x441bd3(++_0x3091a1);}(a551_0x3091,0x1cb));const a551_0x441b=function(_0x3934da,_0x3091a1){_0x3934da=_0x3934da-0x0;let _0x441bd3=a551_0x3091[_0x3934da];return _0x441bd3;};const _0x534fa8=a551_0x441b;'use strict';const express=require(_0x534fa8('0x15')),router=express[_0x534fa8('0x0')](),auth=require(_0x534fa8('0x11')),interaction=require('../../components/interaction/service'),controller=require(_0x534fa8('0xc'));router[_0x534fa8('0x6')]('/',auth[_0x534fa8('0x5')](),controller[_0x534fa8('0x17')]),router[_0x534fa8('0x6')](_0x534fa8('0x9'),auth[_0x534fa8('0x5')](),controller[_0x534fa8('0x12')]),router[_0x534fa8('0x6')](_0x534fa8('0x18'),auth[_0x534fa8('0x5')](),controller[_0x534fa8('0x4')]),router[_0x534fa8('0x6')]('/:id/messages',auth[_0x534fa8('0x5')](),controller[_0x534fa8('0xd')]),router['get'](_0x534fa8('0xb'),auth['isAuthenticated'](),controller[_0x534fa8('0x16')]),router[_0x534fa8('0x3')]('/',auth['isAuthenticated'](),controller['create']),router[_0x534fa8('0x3')](_0x534fa8('0x14'),auth[_0x534fa8('0x5')](),controller[_0x534fa8('0x2')]),router[_0x534fa8('0x3')]('/:id/tags',auth[_0x534fa8('0x5')](),interaction[_0x534fa8('0x10')](_0x534fa8('0x1'),_0x534fa8('0x7')),controller[_0x534fa8('0x13')]),router[_0x534fa8('0xa')](_0x534fa8('0x18'),auth['isAuthenticated'](),interaction[_0x534fa8('0x10')](_0x534fa8('0x1'),_0x534fa8('0xe')),controller[_0x534fa8('0xf')]),router[_0x534fa8('0x8')](_0x534fa8('0x18'),auth[_0x534fa8('0x5')](),interaction['tracked']('sms','smsinteraction:destroy'),controller['destroy']),router[_0x534fa8('0x8')]('/:id/tags',auth[_0x534fa8('0x5')](),controller['removeTags']),module['exports']=router; \ No newline at end of file diff --git a/server/api/smsInteraction/smsInteraction.attributes.js b/server/api/smsInteraction/smsInteraction.attributes.js index 0dfe576..5c8b618 100644 --- a/server/api/smsInteraction/smsInteraction.attributes.js +++ b/server/api/smsInteraction/smsInteraction.attributes.js @@ -1 +1 @@ -const a552_0x566f=['sequelize','exports','ENUM','BOOLEAN','out','STRING','DATE'];(function(_0x565b3e,_0x566fa7){const _0x409a0d=function(_0x22223c){while(--_0x22223c){_0x565b3e['push'](_0x565b3e['shift']());}};_0x409a0d(++_0x566fa7);}(a552_0x566f,0x12e));const a552_0x409a=function(_0x565b3e,_0x566fa7){_0x565b3e=_0x565b3e-0x0;let _0x409a0d=a552_0x566f[_0x565b3e];return _0x409a0d;};const _0x4d6430=a552_0x409a;'use strict';const Sequelize=require(_0x4d6430('0x6'));module[_0x4d6430('0x0')]={'closed':{'type':Sequelize[_0x4d6430('0x2')],'defaultValue':![]},'closedAt':{'type':Sequelize[_0x4d6430('0x5')]},'disposition':{'type':Sequelize[_0x4d6430('0x4')]},'secondDisposition':{'type':Sequelize[_0x4d6430('0x4')]},'thirdDisposition':{'type':Sequelize[_0x4d6430('0x4')]},'note':{'type':Sequelize[_0x4d6430('0x4')]},'phone':{'type':Sequelize['STRING']},'read1stAt':{'type':Sequelize[_0x4d6430('0x5')]},'firstMsgDirection':{'type':Sequelize[_0x4d6430('0x1')]('in',_0x4d6430('0x3')),'defaultValue':'in','allowNull':![]},'lastMsgAt':{'type':Sequelize[_0x4d6430('0x5')]},'lastMsgDirection':{'type':Sequelize[_0x4d6430('0x1')]('in','out'),'defaultValue':'in','allowNull':![]}}; \ No newline at end of file +const a552_0x3db6=['DATE','out','ENUM','STRING','exports','sequelize'];(function(_0x2f4566,_0x3db6af){const _0x4786bd=function(_0xe10d66){while(--_0xe10d66){_0x2f4566['push'](_0x2f4566['shift']());}};_0x4786bd(++_0x3db6af);}(a552_0x3db6,0x11d));const a552_0x4786=function(_0x2f4566,_0x3db6af){_0x2f4566=_0x2f4566-0x0;let _0x4786bd=a552_0x3db6[_0x2f4566];return _0x4786bd;};const _0x3d21c9=a552_0x4786;'use strict';const Sequelize=require(_0x3d21c9('0x2'));module[_0x3d21c9('0x1')]={'closed':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'closedAt':{'type':Sequelize[_0x3d21c9('0x3')]},'disposition':{'type':Sequelize[_0x3d21c9('0x0')]},'secondDisposition':{'type':Sequelize['STRING']},'thirdDisposition':{'type':Sequelize['STRING']},'note':{'type':Sequelize[_0x3d21c9('0x0')]},'phone':{'type':Sequelize['STRING']},'read1stAt':{'type':Sequelize['DATE']},'firstMsgDirection':{'type':Sequelize[_0x3d21c9('0x5')]('in','out'),'defaultValue':'in','allowNull':![]},'lastMsgAt':{'type':Sequelize[_0x3d21c9('0x3')]},'lastMsgDirection':{'type':Sequelize['ENUM']('in',_0x3d21c9('0x4')),'defaultValue':'in','allowNull':![]}}; \ No newline at end of file diff --git a/server/api/smsInteraction/smsInteraction.controller.js b/server/api/smsInteraction/smsInteraction.controller.js index 2e615aa..3f83380 100644 --- a/server/api/smsInteraction/smsInteraction.controller.js +++ b/server/api/smsInteraction/smsInteraction.controller.js @@ -1 +1 @@ -const a553_0x13ad=['$lte','fullname','catch','stack','util','concat','getMessages','unreadMessages','replace','emit','DESC','parse','direction','isNumeric','Messages','moment','find','Sms','field','i.phone\x20LIKE\x20?','show','index','root','create','format','o.id\x20=\x20i.UserId','c.email','isArray','get','t.id\x20=\x20it.TagId','limit','setTags','c.mobile','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{page}}/{{pages}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','i.SmsAccountId\x20IS\x20NOT\x20NULL','$substring','i.*','map','sqlOperator','Sequelize','filters','intersection','closedAt','sendStatus','users','%s\x20#%d','lastName','SmsInteraction','type','a.mandatoryDisposition','Contact.mobile','sms_accounts','journey','fields','color','includeAll','SmsAccountId','Contact','omit','text','json','all','left_join','getSmsAccounts','operator','start','err','getFullTextValue','null','query','Tag','keyBy','length','server','clone','c.phone','renderFile','10px','end','firstName','include','set','a.key','name','createdAt','Owner','register','../../components/parsers/advancedSearch','../../components/parsers/qs','Owner.internal','closed','log','UserId','squel','like','Account.key','addTags','download','../../config/logger','ids','Tags','sms_interaction_has_tags','params','buildExpression','removeTags','ContactId','toString','pick','lodash','YYYY-MM-DD\x20HH:mm:ss','SmsInteractionId','SmsAccount','$gte','count','user_has_sms_interactions','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
Interaction\x20Transcript
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','o.fullname','u.fullname','unlinkSync','body','t.id\x20IN\x20?','rimraf','sms_interactions','rows','i.SmsAccountId\x20IS\x20NULL','SELECT','read','a.id\x20=\x20i.SmsAccountId','value','join','smsInteractionTags:save','tmp','where','model','transcript-%d-%s.zip','QueryTypes','Owner.fullname','status','from','nolimit','isEmpty','conditions','out','views','c.firstName','Account.mandatoryDisposition','MATCH\x20(me.body)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','User','sequelize','destroy','TagIds','i.createdAt\x20BETWEEN\x20?\x20AND\x20?','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','findAll','Content-Range','findOne','unix','`unreadMessages`\x20=\x200','split','gte','update','GROUP_CONCAT(DISTINCT\x20t.id)','ui.SmsInteractionId','zip-dir','filter','u.id','compact','ui.SmsInteractionId\x20IN\x20?','toFile','i.id\x20LIKE\x20?','search','undefined','downloadInteraction.html','rawAttributes','some','Account','having','sms_messages','CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?','i.SmsAccountId\x20IN\x20?','YYYY-MM-DD','tag','select','sort','parseSearch','30px','../../config/environment','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','forEach','Contact.phone','`\x20>\x200','cm_contacts','user','\x20=\x20?','../../rediscache','api','order','o.internal','secret','key','\x20IS\x20NULL','offset','options','merge','then','Contact.lastName','union','html-pdf','Users','expr','attributes','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','../../mysqldb','SmsMessage','send','push','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL','keys','resolve','tools_tags','disposition'];(function(_0xee7e2d,_0x13ad6c){const _0x28876e=function(_0xb99ecb){while(--_0xb99ecb){_0xee7e2d['push'](_0xee7e2d['shift']());}};_0x28876e(++_0x13ad6c);}(a553_0x13ad,0x1d3));const a553_0x2887=function(_0xee7e2d,_0x13ad6c){_0xee7e2d=_0xee7e2d-0x0;let _0x28876e=a553_0x13ad[_0xee7e2d];return _0x28876e;};const _0x29c6e7=a553_0x2887;'use strict';const pdf=require(_0x29c6e7('0xb6')),rimraf=require(_0x29c6e7('0x60')),zipdir=require(_0x29c6e7('0x8a')),moment=require(_0x29c6e7('0xd3')),util=require(_0x29c6e7('0xc8')),path=require('path'),ejs=require('ejs'),fs=require('fs'),_=require(_0x29c6e7('0x53')),squel=require(_0x29c6e7('0x44')),{getSocket}=require(_0x29c6e7('0xa9')),socket=getSocket(),qs=require(_0x29c6e7('0x3f')),as=require(_0x29c6e7('0x3e')),logger=require(_0x29c6e7('0x49'))(_0x29c6e7('0xaa')),config=require(_0x29c6e7('0xa1')),db=require(_0x29c6e7('0xbb'))['db'],{Op}=require(_0x29c6e7('0x7b'));require('./smsInteraction.socket')[_0x29c6e7('0x3d')](socket);function respondWithStatusCode(_0xb99ecb,_0x2bbef2){return _0x2bbef2=_0x2bbef2||0xcc,function(_0x7045e8){const _0x249870=a553_0x2887;if(_0x7045e8)return _0xb99ecb[_0x249870('0x12')](_0x2bbef2);return _0xb99ecb['status'](_0x2bbef2)[_0x249870('0x35')]();};}function respondWithResult(_0x321a23,_0x50c8af){return _0x50c8af=_0x50c8af||0xc8,function(_0x5737b2){const _0x55a677=a553_0x2887;if(_0x5737b2)return _0x321a23[_0x55a677('0x70')](_0x50c8af)[_0x55a677('0x23')](_0x5737b2);};}function respondWithFilteredResult(_0x2a9e2a,_0x3ebc88){return function(_0x201fa2){const _0x70276d=a553_0x2887;if(_0x201fa2){const _0x40e389=_0x201fa2[_0x70276d('0x58')],_0x445599=_0x3ebc88['offset'];let _0x27a30a=_0x3ebc88[_0x70276d('0xb0')]+_0x3ebc88[_0x70276d('0x5')],_0x4994ed;return _0x27a30a>=_0x40e389?(_0x27a30a=_0x40e389,_0x4994ed=0xc8):_0x4994ed=0xce,_0x2a9e2a['status'](_0x4994ed),_0x2a9e2a[_0x70276d('0x38')](_0x70276d('0x81'),_0x445599+'-'+_0x27a30a+'/'+_0x40e389)[_0x70276d('0x23')](_0x201fa2);}return null;};}function saveUpdates(_0x519ed0){return function(_0x4da692){const _0x39bb3b=a553_0x2887;if(_0x4da692)return _0x4da692['update'](_0x519ed0)[_0x39bb3b('0xb3')](function(_0xd5f8f9){return _0xd5f8f9;});return null;};}function removeEntity(_0x31d9c6){return function(_0xa87273){const _0x2d2de6=a553_0x2887;if(_0xa87273)return _0xa87273[_0x2d2de6('0x7c')]()[_0x2d2de6('0xb3')](function(){const _0x1da3c8=_0x2d2de6;_0x31d9c6[_0x1da3c8('0x70')](0xcc)[_0x1da3c8('0x35')]();});};}function handleEntityNotFound(_0x106ac5){return function(_0x282195){const _0x2c93ae=a553_0x2887;return!_0x282195&&_0x106ac5[_0x2c93ae('0x12')](0x194),_0x282195;};}function handleError(_0x23039c,_0x244046){return _0x244046=_0x244046||0x1f4,function(_0x3ba3b9){const _0x4cc5e3=a553_0x2887;logger['error'](_0x3ba3b9[_0x4cc5e3('0xc7')]),_0x3ba3b9[_0x4cc5e3('0x3a')]&&delete _0x3ba3b9['name'],_0x23039c[_0x4cc5e3('0x70')](_0x244046)[_0x4cc5e3('0xbd')](_0x3ba3b9);};}function getInteractionUsers(_0x3aad8b,_0x4a1475){return new Promise(function(_0x3f7fdc,_0x345731){const _0x466892=a553_0x2887;try{_0x4a1475[_0x3aad8b['id']]&&(_0x3aad8b[_0x466892('0xb7')]=_[_0x466892('0xc')](_0x4a1475[_0x3aad8b['id']],function(_0x35f1c8){return{'id':_0x35f1c8['id'],'fullname':_0x35f1c8['fullname']};}));}catch(_0x5477d1){_0x345731(_0x5477d1);}_0x3f7fdc(_0x3aad8b);});}function getInteractionTags(_0x4ba6af,_0x52fe8e){return new Promise(function(_0x51aae5,_0x6f643a){const _0xe4369a=a553_0x2887;try{_0x4ba6af[_0xe4369a('0x7d')]&&(_0x4ba6af[_0xe4369a('0x4b')]=[],_0x4ba6af[_0xe4369a('0x7d')][_0xe4369a('0x85')](',')[_0xe4369a('0xa3')](function(_0x885fa5){const _0x550b07=_0xe4369a;_0x4ba6af['Tags'][_0x550b07('0xbe')](_0x52fe8e[_0x885fa5]);})),delete _0x4ba6af[_0xe4369a('0x7d')];}catch(_0x4dc213){_0x6f643a(_0x4dc213);}_0x51aae5(_0x4ba6af);});}function updateSmsInteraction(_0x5dcb8d,_0xc6191d,_0x478666){return new Promise(function(_0x35777e,_0x263a80){const _0x1ea781=a553_0x2887;return getInteractionUsers(_0x5dcb8d,_0x478666)['then'](function(_0x5ecc9d){return getInteractionTags(_0x5ecc9d,_0xc6191d);})[_0x1ea781('0xb3')](function(_0x5e43d9){_0x35777e(_0x5e43d9);})['catch'](function(_0x287a07){_0x263a80(_0x287a07);});});}exports[_0x29c6e7('0xd9')]=function(_0x1929c0,_0x332f79){const _0x543d94=_0x29c6e7,_0x190a21={},_0x16a381={},_0xc9680f={'count':0x0,'rows':[]},_0x49c199=_['map'](db['SmsInteraction'][_0x543d94('0x94')],function(_0x3c715f){const _0x53b141=_0x543d94;return{'name':_0x3c715f['fieldName'],'type':_0x3c715f[_0x53b141('0x17')][_0x53b141('0xae')]};});_0x16a381[_0x543d94('0x6c')]=_[_0x543d94('0xc')](_0x49c199,_0x543d94('0x3a')),_0x16a381[_0x543d94('0x2c')]=_['keys'](_0x1929c0[_0x543d94('0x2c')]),_0x16a381[_0x543d94('0xf')]=_[_0x543d94('0x10')](_0x16a381[_0x543d94('0x6c')],_0x16a381[_0x543d94('0x2c')]),_0x190a21[_0x543d94('0xb9')]=_[_0x543d94('0x10')](_0x16a381[_0x543d94('0x6c')],qs[_0x543d94('0x1c')](_0x1929c0[_0x543d94('0x2c')][_0x543d94('0x1c')])),_0x190a21[_0x543d94('0xb9')]=_0x190a21['attributes']['length']?_0x190a21[_0x543d94('0xb9')]:_0x16a381[_0x543d94('0x6c')];typeof _0x1929c0[_0x543d94('0x2c')][_0x543d94('0x72')]===_0x543d94('0x92')&&(_0x190a21[_0x543d94('0x5')]=qs[_0x543d94('0x5')](_0x1929c0['query'][_0x543d94('0x5')]),_0x190a21['offset']=qs[_0x543d94('0xb0')](_0x1929c0[_0x543d94('0x2c')][_0x543d94('0xb0')]));_0x190a21[_0x543d94('0xab')]=qs[_0x543d94('0x9e')](_0x1929c0[_0x543d94('0x2c')][_0x543d94('0x9e')]),_0x190a21[_0x543d94('0x6b')]=qs[_0x543d94('0xf')](_['pick'](_0x1929c0[_0x543d94('0x2c')],_0x16a381[_0x543d94('0xf')]),_0x49c199);let _0xf1658f=[];const _0x552505=squel['select']()[_0x543d94('0xd6')]('id')[_0x543d94('0xd6')](_0x543d94('0x3a'))[_0x543d94('0xd6')]('color')[_0x543d94('0x71')](_0x543d94('0xc2')),_0x3b1c08=squel[_0x543d94('0x9d')]()['field'](_0x543d94('0x8c'))['field'](_0x543d94('0x5c'))[_0x543d94('0xd6')](_0x543d94('0x89'))[_0x543d94('0x71')](_0x543d94('0x59'),'ui')[_0x543d94('0x25')](_0x543d94('0x13'),'u','u.id\x20=\x20ui.UserId'),_0x1ce2bd=squel[_0x543d94('0x9d')]()['from'](_0x543d94('0x61'),'i')['left_join'](_0x543d94('0xa6'),'c',_0x543d94('0xbf'))[_0x543d94('0x25')](_0x543d94('0x13'),'o',_0x543d94('0x0'))[_0x543d94('0x25')](_0x543d94('0x1a'),'a',_0x543d94('0x66'))[_0x543d94('0x25')](_0x543d94('0x98'),'me','me.SmsInteractionId\x20=\x20i.id')[_0x543d94('0x25')](_0x543d94('0x4c'),'it','it.SmsInteractionId\x20=\x20i.id')['left_join'](_0x543d94('0xc2'),'t',_0x543d94('0x4')),_0x361844=squel['expr']();let _0x2bc13e=[];const _0x57a718=squel[_0x543d94('0xb8')]();let _0xe656e6;if(_0x1929c0[_0x543d94('0x2c')][_0x543d94('0x91')]){_0xe656e6=as[_0x543d94('0x9f')](_0x1929c0[_0x543d94('0x2c')][_0x543d94('0x91')]);const _0x5366ba=_0xe656e6[_0x543d94('0xd')];for(let _0x5f1854=0x0;_0x5f1854<_0xe656e6[_0x543d94('0x74')][_0x543d94('0x2f')];_0x5f1854++){const _0x12a0a4=_0xe656e6[_0x543d94('0x74')][_0x5f1854],_0xd82a2c='i';let _0x15b1de,_0x2eea9b=_['find'](_0x49c199,[_0x543d94('0x3a'),_0x12a0a4[_0x543d94('0xd6')]]);if(!_0x2eea9b)switch(_0x12a0a4[_0x543d94('0xd6')]){case _0x543d94('0xcb'):_0x12a0a4[_0x543d94('0x67')]==0x1?_0x1ce2bd['having']('`'+_0x12a0a4['field']+'`\x20=\x200'):_0x1ce2bd['having']('`'+_0x12a0a4[_0x543d94('0xd6')]+_0x543d94('0xa5'));break;case _0x543d94('0x20'):if(_0x12a0a4[_0x543d94('0x27')]===_0x543d94('0xa')){if(_0x12a0a4['value'][_0x543d94('0x85')]('\x20')[_0x543d94('0x2f')]>0x1)_0x361844[_0x5366ba]('MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs['getFullTextValue'](_0x12a0a4[_0x543d94('0x67')]),null);else{const _0x1550b2='%'+_0x12a0a4[_0x543d94('0x67')]+'%';_0x361844[_0x5366ba]('c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?',_0x1550b2,_0x1550b2,_0x1550b2);}}else _0x2eea9b=_['find'](_0x49c199,[_0x543d94('0x3a'),_0x543d94('0x50')]),_0x12a0a4[_0x543d94('0xd6')]=_0x543d94('0x50'),_0x15b1de=as[_0x543d94('0x4e')](_0xd82a2c,_0x2eea9b[_0x543d94('0x17')],_0x12a0a4),_0x361844[_0x5366ba](_0x15b1de[_0x543d94('0x22')],_0x15b1de[_0x543d94('0x67')][_0x543d94('0x28')],_0x15b1de['value'][_0x543d94('0x35')]);break;case _0x543d94('0x2d'):{const _0x54b72e=_0x12a0a4[_0x543d94('0x67')][_0x543d94('0x85')](',')[_0x543d94('0xc')](function(_0x51832b){return Number(_0x51832b);});_0x54b72e[_0x543d94('0xa3')](function(_0x42be14){_0x57a718['or']('CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','%,'+_0x42be14+',%');}),_0x2bc13e=_[_0x543d94('0xb5')](_0x2bc13e,_0x54b72e);}break;case _0x543d94('0x7a'):_0x12a0a4[_0x543d94('0x27')]===_0x543d94('0xa')?_0x361844[_0x5366ba](_0x543d94('0x7f'),'%'+_0x12a0a4[_0x543d94('0x67')]+'%',null):(_0x2eea9b=_[_0x543d94('0xd4')](_0x49c199,['name',_0x543d94('0x43')]),_0x12a0a4['field']=_0x543d94('0x43'),_0x15b1de=as[_0x543d94('0x4e')](_0xd82a2c,_0x2eea9b[_0x543d94('0x17')],_0x12a0a4),_0x361844[_0x5366ba](_0x15b1de[_0x543d94('0x22')],_0x15b1de[_0x543d94('0x67')]['start'],_0x15b1de[_0x543d94('0x67')][_0x543d94('0x35')]));break;case _0x543d94('0x5e'):_0x15b1de=as['buildExpression']('me',null,_0x12a0a4),_0x361844[_0x5366ba](_0x15b1de['text'],_0x15b1de['value'][_0x543d94('0x28')],_0x15b1de['value'][_0x543d94('0x35')]);break;}else _0x15b1de=as[_0x543d94('0x4e')](_0xd82a2c,_0x2eea9b[_0x543d94('0x17')],_0x12a0a4),_0x361844[_0x5366ba](_0x15b1de[_0x543d94('0x22')],_0x15b1de[_0x543d94('0x67')]['start'],_0x15b1de['value']['end']);}}else{const _0x114f79=_(_0x1929c0[_0x543d94('0x2c')])['keys']()[_0x543d94('0xc')](function(_0x49297a){const _0x3f573e=_0x543d94;return _[_0x3f573e('0x95')](_0x49c199,[_0x3f573e('0x3a'),_0x49297a])?_0x49297a:undefined;})[_0x543d94('0x8d')]()['value']();!_['isEmpty'](_0x114f79)&&_0x114f79[_0x543d94('0xa3')](function(_0x8c1082){const _0x39c03d=_0x543d94;if(_0x8c1082===_0x39c03d('0x1f'))_0x1ce2bd[_0x39c03d('0x6b')](_0x39c03d('0x9a'),[][_0x39c03d('0xc9')](_0x1929c0['query'][_0x8c1082]));else{if(_0x8c1082===_0x39c03d('0x3b')){const _0x3ea4a4=JSON[_0x39c03d('0xcf')](_0x1929c0['query'][_0x8c1082])[_0x39c03d('0x57')],_0x116043=JSON[_0x39c03d('0xcf')](_0x1929c0[_0x39c03d('0x2c')][_0x8c1082])[_0x39c03d('0xc4')];_0x1ce2bd[_0x39c03d('0x6b')](_0x39c03d('0x7e'),_0x3ea4a4,_0x116043);}else _0x1929c0[_0x39c03d('0x2c')][_0x8c1082]===_0x39c03d('0x2b')?_0x1ce2bd[_0x39c03d('0x6b')]('i.'+_0x8c1082+_0x39c03d('0xaf')):_0x1ce2bd[_0x39c03d('0x6b')]('i.'+_0x8c1082+_0x39c03d('0xa8'),_0x1929c0[_0x39c03d('0x2c')][_0x8c1082]);}});_0x1929c0[_0x543d94('0x2c')][_0x543d94('0x65')]&&(_0x1929c0[_0x543d94('0x2c')][_0x543d94('0x65')]==0x1?_0x1ce2bd[_0x543d94('0x97')](_0x543d94('0x84')):_0x1ce2bd[_0x543d94('0x97')]('`unreadMessages`\x20>\x200'));_0x1929c0[_0x543d94('0x2c')]['tag']&&(_0x2bc13e=_[_0x543d94('0x2')](_0x1929c0[_0x543d94('0x2c')]['tag'])?_0x1929c0['query'][_0x543d94('0x9c')]:new Array(_0x1929c0[_0x543d94('0x2c')]['tag']),_0x2bc13e['forEach'](function(_0x3f0603){const _0x1f0ea2=_0x543d94;_0x57a718['or'](_0x1f0ea2('0xba'),'%,'+_0x3f0603+',%');}));if(_0x1929c0[_0x543d94('0x2c')][_0x543d94('0x8b')]){const _0x1be226=_0x1929c0[_0x543d94('0x2c')]['filter'][_0x543d94('0xcc')]('\x5c','\x5c\x5c')[_0x543d94('0xcc')]('\x27\x27','\x27\x27\x27\x27');qs[_0x543d94('0xd1')](_0x1be226)?_0x361844['or'](_0x543d94('0x90'),_0x1be226+'%')['or'](_0x543d94('0xd7'),_0x1be226+'%'):_0x361844['or'](_0x543d94('0x79'),qs[_0x543d94('0x2a')](_0x1be226))['or'](_0x543d94('0x99'),_0x1be226+'%');}}_0x1ce2bd[_0x543d94('0x6b')](_0x361844),_0x1ce2bd['group']('i.id');let _0x25c9d6={'type':db[_0x543d94('0xe')][_0x543d94('0x6e')][_0x543d94('0x64')],'raw':!![]};const _0x3931b9=_0x1ce2bd[_0x543d94('0x31')]();_0x3931b9[_0x543d94('0xd6')]('i.id'),_0x3931b9[_0x543d94('0xd6')](_0x543d94('0xa2'),_0x543d94('0xcb')),_0x190a21['order']&&_0x190a21['order'][_0x543d94('0xa3')](function(_0x441ef5){const _0x2a5982=_0x543d94;_0x1ce2bd[_0x2a5982('0xab')]('i.'+_0x441ef5[0x0],_0x441ef5[0x1]===_0x2a5982('0xce')?![]:!![]);}),!_[_0x543d94('0x73')](_0x2bc13e)&&(_0x1ce2bd['having'](_0x57a718),_0x3931b9[_0x543d94('0x6b')](_0x543d94('0x5f'),_0x2bc13e)),Promise[_0x543d94('0xc1')]()[_0x543d94('0xb3')](function(){const _0x1a8b1a=_0x543d94;if(!_0xe656e6){if(_0x1929c0[_0x1a8b1a('0x2c')][_0x1a8b1a('0x1f')]||_0x1929c0[_0x1a8b1a('0x2c')][_0x1a8b1a('0x1b')])return;_0x3931b9[_0x1a8b1a('0x6b')](_0x1a8b1a('0x9')),_0x1ce2bd[_0x1a8b1a('0x6b')](_0x1a8b1a('0x9'));return;}return _0x1929c0[_0x1a8b1a('0xa7')][_0x1a8b1a('0x26')]({'attributes':['id'],'raw':!![]})[_0x1a8b1a('0xb3')](function(_0x5d04b4){const _0x3f2d40=_0x1a8b1a;_[_0x3f2d40('0x73')](_0x5d04b4)?(_0x3931b9[_0x3f2d40('0x6b')](_0x3f2d40('0x63')),_0x1ce2bd['where'](_0x3f2d40('0x63'))):(_0x3931b9[_0x3f2d40('0x6b')]('i.SmsAccountId\x20IN\x20?',_['map'](_0x5d04b4,'id')),_0x1ce2bd[_0x3f2d40('0x6b')](_0x3f2d40('0x9a'),_[_0x3f2d40('0xc')](_0x5d04b4,'id')));});})['then'](function(){const _0x5084b5=_0x543d94;db[_0x5084b5('0x7b')]['query'](_0x3931b9['toString'](),_0x25c9d6)[_0x5084b5('0xb3')](function(_0x11b569){const _0x41b945=_0x5084b5;_0xc9680f[_0x41b945('0x58')]=_0x11b569[_0x41b945('0x2f')];if(_0xc9680f[_0x41b945('0x58')]===0x0)return[];return db[_0x41b945('0x7b')][_0x41b945('0x2c')](_0x552505['toString'](),_0x25c9d6)['then'](function(_0x496814){const _0x2b5953=_0x41b945;_0xf1658f=_[_0x2b5953('0x2e')](_0x496814,'id'),_0x25c9d6=_['merge'](_0x25c9d6,{'model':db[_0x2b5953('0x16')],'mapToModel':!![],'raw':!![],'nest':!![]});_0x1929c0['query']['fields']?_0x190a21[_0x2b5953('0xb9')][_0x2b5953('0xa3')](function(_0x36f0bb){const _0x112afe=_0x2b5953;_0x1ce2bd[_0x112afe('0xd6')]('i.'+_0x36f0bb);}):(_0x1ce2bd[_0x2b5953('0xd6')](_0x2b5953('0xa2'),'unreadMessages'),_0x1ce2bd[_0x2b5953('0xd6')](_0x2b5953('0x39'),_0x2b5953('0x46')),_0x1ce2bd['field'](_0x2b5953('0x18'),_0x2b5953('0x78')),_0x1ce2bd[_0x2b5953('0xd6')](_0x2b5953('0xb')),_0x1ce2bd[_0x2b5953('0xd6')](_0x2b5953('0x77'),'Contact.firstName'),_0x1ce2bd[_0x2b5953('0xd6')]('c.lastName',_0x2b5953('0xb4')),_0x1ce2bd['field'](_0x2b5953('0x1'),'Contact.email'),_0x1ce2bd[_0x2b5953('0xd6')](_0x2b5953('0x32'),_0x2b5953('0xa4')),_0x1ce2bd[_0x2b5953('0xd6')](_0x2b5953('0x7'),_0x2b5953('0x19')),_0x1ce2bd[_0x2b5953('0xd6')]('c.fax','Contact.fax'),_0x1ce2bd[_0x2b5953('0xd6')](_0x2b5953('0x5b'),_0x2b5953('0x6f')),_0x1ce2bd[_0x2b5953('0xd6')](_0x2b5953('0xac'),_0x2b5953('0x40')),_0x1ce2bd[_0x2b5953('0xd6')](_0x2b5953('0x88'),_0x2b5953('0x7d')));if(_0x190a21[_0x2b5953('0x5')])_0x1ce2bd[_0x2b5953('0x5')](_0x190a21[_0x2b5953('0x5')]);if(_0x190a21[_0x2b5953('0xb0')])_0x1ce2bd[_0x2b5953('0xb0')](_0x190a21[_0x2b5953('0xb0')]);return db[_0x2b5953('0x7b')][_0x2b5953('0x2c')](_0x1ce2bd[_0x2b5953('0x51')](),_0x25c9d6);})['then'](function(_0x19894c){const _0x3f4996=_0x41b945;return _0x3b1c08[_0x3f4996('0x6b')](_0x3f4996('0x8e'),_[_0x3f4996('0xc')](_0x19894c,'id')),db[_0x3f4996('0x7b')][_0x3f4996('0x2c')](_0x3b1c08[_0x3f4996('0x51')](),_0x25c9d6)[_0x3f4996('0xb3')](function(_0x440327){const _0x4ddae5=_0x3f4996,_0x5e8cbe=_['groupBy'](_0x440327,_0x4ddae5('0x55')),_0x2aa9a6=[];return _0x19894c[_0x4ddae5('0xa3')](function(_0x271af8){_0x2aa9a6['push'](updateSmsInteraction(_0x271af8,_0xf1658f,_0x5e8cbe));}),Promise[_0x4ddae5('0x24')](_0x2aa9a6);});});})[_0x5084b5('0xb3')](function(_0x5ee9f8){const _0x801a2d=_0x5084b5;return _0xc9680f[_0x801a2d('0x62')]=_0x5ee9f8,_0xc9680f;})['then'](respondWithFilteredResult(_0x332f79,_0x190a21));})[_0x543d94('0xc6')](handleError(_0x332f79,null));},exports[_0x29c6e7('0xd8')]=function(_0x5148ee,_0x4e452a){const _0x40d598=_0x29c6e7;let _0x453170={'raw':![],'where':{'id':_0x5148ee[_0x40d598('0x4d')]['id']}};const _0x595134={};return _0x595134[_0x40d598('0x6c')]=_[_0x40d598('0xc0')](db[_0x40d598('0x16')][_0x40d598('0x94')]),_0x595134[_0x40d598('0x2c')]=_[_0x40d598('0xc0')](_0x5148ee['query']),_0x595134[_0x40d598('0xf')]=_['intersection'](_0x595134[_0x40d598('0x6c')],_0x595134[_0x40d598('0x2c')]),_0x453170['attributes']=_[_0x40d598('0x10')](_0x595134[_0x40d598('0x6c')],qs[_0x40d598('0x1c')](_0x5148ee['query'][_0x40d598('0x1c')])),_0x453170[_0x40d598('0xb9')]=_0x453170['attributes']['length']?_0x453170[_0x40d598('0xb9')]:_0x595134[_0x40d598('0x6c')],_0x5148ee['query'][_0x40d598('0x1e')]&&(_0x453170[_0x40d598('0x37')]=[{'all':!![]}]),_0x453170=_['merge']({},_0x453170,_0x5148ee[_0x40d598('0xb1')]),db[_0x40d598('0x16')][_0x40d598('0x82')](_0x453170)[_0x40d598('0xb3')](handleEntityNotFound(_0x4e452a,null))[_0x40d598('0xb3')](respondWithResult(_0x4e452a,null))[_0x40d598('0xc6')](handleError(_0x4e452a,null));},exports[_0x29c6e7('0xdb')]=function(_0x1a8b6c,_0x512eec){const _0x135385=_0x29c6e7;return db[_0x135385('0x16')]['create'](_0x1a8b6c[_0x135385('0x5e')],{})[_0x135385('0xb3')](respondWithResult(_0x512eec,0xc9))[_0x135385('0xc6')](handleError(_0x512eec,null));},exports[_0x29c6e7('0x87')]=function(_0x4dfc9e,_0x4f56b4){const _0x3dc0fc=_0x29c6e7;return _0x4dfc9e[_0x3dc0fc('0x5e')]['id']&&delete _0x4dfc9e[_0x3dc0fc('0x5e')]['id'],db[_0x3dc0fc('0x16')][_0x3dc0fc('0x82')]({'where':{'id':_0x4dfc9e[_0x3dc0fc('0x4d')]['id']}})[_0x3dc0fc('0xb3')](handleEntityNotFound(_0x4f56b4,null))['then'](saveUpdates(_0x4dfc9e['body'],null))[_0x3dc0fc('0xb3')](respondWithResult(_0x4f56b4,null))[_0x3dc0fc('0xc6')](handleError(_0x4f56b4,null));},exports['destroy']=function(_0x17000a,_0x3d22a7){const _0x1028c1=_0x29c6e7;return db[_0x1028c1('0x16')][_0x1028c1('0x82')]({'where':{'id':_0x17000a[_0x1028c1('0x4d')]['id']}})[_0x1028c1('0xb3')](handleEntityNotFound(_0x3d22a7,null))[_0x1028c1('0xb3')](removeEntity(_0x3d22a7,null))['catch'](handleError(_0x3d22a7,null));},exports['describe']=function(_0xc39a84,_0x54f65c){const _0x22c848=_0x29c6e7;return db['SmsInteraction']['describe']()['then'](respondWithResult(_0x54f65c,null))[_0x22c848('0xc6')](handleError(_0x54f65c,null));},exports['addMessage']=function(_0x40e5ee,_0x23e5cc){const _0x2efd56=_0x29c6e7;return db['SmsMessage']['findOne']({'where':{'id':_0x40e5ee['params']['id']}})[_0x2efd56('0xb3')](function(_0x2f5e22){const _0x341498=_0x2efd56;if(_0x2f5e22)return _0x2f5e22['addMessage'](_0x40e5ee[_0x341498('0x5e')][_0x341498('0x4a')],{'through':_['omit'](_0x40e5ee[_0x341498('0x5e')],[_0x341498('0x4a'),'id'])});})[_0x2efd56('0xb3')](respondWithResult(_0x23e5cc,null))['catch'](handleError(_0x23e5cc,null));},exports[_0x29c6e7('0xca')]=function(_0x36494e,_0x559060){const _0x5eaa71=_0x29c6e7;let _0x21b16b={'raw':![],'where':{}};const _0x2eb1b6={},_0x36c71e={'count':0x0,'rows':[]};return db[_0x5eaa71('0x16')][_0x5eaa71('0x82')]({'where':{'id':_0x36494e[_0x5eaa71('0x4d')]['id']}})[_0x5eaa71('0xb3')](handleEntityNotFound(_0x559060,null))[_0x5eaa71('0xb3')](function(_0x12f5e7){const _0x1bcf2e=_0x5eaa71;if(_0x12f5e7){_0x2eb1b6['model']=_[_0x1bcf2e('0xc0')](db[_0x1bcf2e('0xbc')][_0x1bcf2e('0x94')]),_0x2eb1b6[_0x1bcf2e('0x2c')]=_[_0x1bcf2e('0xc0')](_0x36494e[_0x1bcf2e('0x2c')]),_0x2eb1b6['filters']=_['intersection'](_0x2eb1b6[_0x1bcf2e('0x6c')],_0x2eb1b6['query']),_0x21b16b[_0x1bcf2e('0xb9')]=_['intersection'](_0x2eb1b6[_0x1bcf2e('0x6c')],qs['fields'](_0x36494e[_0x1bcf2e('0x2c')]['fields'])),_0x21b16b[_0x1bcf2e('0xb9')]=_0x21b16b[_0x1bcf2e('0xb9')][_0x1bcf2e('0x2f')]?_0x21b16b[_0x1bcf2e('0xb9')]:_0x2eb1b6[_0x1bcf2e('0x6c')];typeof _0x36494e[_0x1bcf2e('0x2c')][_0x1bcf2e('0x72')]===_0x1bcf2e('0x92')&&(_0x21b16b[_0x1bcf2e('0x5')]=qs[_0x1bcf2e('0x5')](_0x36494e[_0x1bcf2e('0x2c')][_0x1bcf2e('0x5')]),_0x21b16b[_0x1bcf2e('0xb0')]=qs['offset'](_0x36494e[_0x1bcf2e('0x2c')][_0x1bcf2e('0xb0')]));_0x21b16b['order']=qs[_0x1bcf2e('0x9e')](_0x36494e[_0x1bcf2e('0x2c')]['sort']),_0x21b16b[_0x1bcf2e('0x6b')]=qs[_0x1bcf2e('0xf')](_[_0x1bcf2e('0x52')](_0x36494e[_0x1bcf2e('0x2c')],_0x2eb1b6[_0x1bcf2e('0xf')])),_0x21b16b[_0x1bcf2e('0x6b')][_0x1bcf2e('0x55')]=_0x12f5e7['id'];_0x36494e[_0x1bcf2e('0x2c')]['filter']&&(_0x21b16b['where']=_[_0x1bcf2e('0xb2')](_0x21b16b[_0x1bcf2e('0x6b')],{[Op['or']]:_[_0x1bcf2e('0xc')](_0x21b16b[_0x1bcf2e('0xb9')],function(_0x1aabd4){const _0x588ca5=_0x1bcf2e,_0x138868={};return _0x138868[_0x1aabd4]={[Op[_0x588ca5('0x45')]]:'%'+_0x36494e[_0x588ca5('0x2c')][_0x588ca5('0x8b')]+'%'},_0x138868;})}));if(_0x36494e['query']['$gte']){const _0x27659c=_0x36494e['query']['$gte'][_0x1bcf2e('0x85')](','),_0x52d03c={};_0x52d03c[_0x27659c[0x0]]={[Op[_0x1bcf2e('0x86')]]:moment(_0x27659c[0x1])[_0x1bcf2e('0xdc')](_0x1bcf2e('0x54'))},_0x21b16b[_0x1bcf2e('0x6b')]=_['merge'](_0x21b16b[_0x1bcf2e('0x6b')],_0x52d03c);}return _0x21b16b=_['merge']({},_0x21b16b,_0x36494e[_0x1bcf2e('0xb1')]),db['SmsMessage'][_0x1bcf2e('0x58')]({'where':_0x21b16b[_0x1bcf2e('0x6b')]})[_0x1bcf2e('0xb3')](function(_0xcb0775){const _0x3f4268=_0x1bcf2e;return _0x36c71e['count']=_0xcb0775,_0x36494e[_0x3f4268('0x2c')][_0x3f4268('0x1e')]&&(_0x21b16b['include']=[{'all':!![]}]),db[_0x3f4268('0xbc')][_0x3f4268('0x80')](_0x21b16b);})[_0x1bcf2e('0xb3')](function(_0x61ffc2){const _0x10fa3c=_0x1bcf2e;return _0x36c71e[_0x10fa3c('0x62')]=_0x61ffc2,_0x36c71e;});}})[_0x5eaa71('0xb3')](respondWithFilteredResult(_0x559060,_0x21b16b))[_0x5eaa71('0xc6')](handleError(_0x559060,null));},exports[_0x29c6e7('0x47')]=function(_0x4ce36c,_0x32d4b1){const _0x5b2de3=_0x29c6e7;return db['SmsInteraction']['findOne']({'where':{'id':_0x4ce36c['params']['id']}})[_0x5b2de3('0xb3')](function(_0x16f3dd){const _0x19d962=_0x5b2de3;if(_0x16f3dd)return _0x16f3dd[_0x19d962('0x6')](_0x4ce36c[_0x19d962('0x5e')][_0x19d962('0x4a')],{'through':_[_0x19d962('0x21')](_0x4ce36c[_0x19d962('0x5e')],[_0x19d962('0x4a'),'id'])})['then'](function(){const _0x3ee6be=_0x19d962;return db['Tag'][_0x3ee6be('0x80')]({'attributes':['id',_0x3ee6be('0x3a'),_0x3ee6be('0x1d')],'where':{'id':_0x4ce36c[_0x3ee6be('0x5e')][_0x3ee6be('0x4a')]}});})[_0x19d962('0xb3')](function(_0x486420){const _0x5a8f7d=_0x19d962;return socket[_0x5a8f7d('0xcd')](_0x5a8f7d('0x69'),{'id':Number(_0x4ce36c[_0x5a8f7d('0x4d')]['id']),'tags':_0x486420||[]}),{'id':Number(_0x4ce36c['params']['id']),'tags':_0x486420||[]};});})[_0x5b2de3('0xb3')](respondWithResult(_0x32d4b1,null))['catch'](handleError(_0x32d4b1,null));},exports[_0x29c6e7('0x4f')]=function(_0xd2e973,_0x3f8320){const _0x31735f=_0x29c6e7;return db[_0x31735f('0x16')][_0x31735f('0x82')]({'where':{'id':_0xd2e973[_0x31735f('0x4d')]['id']}})[_0x31735f('0xb3')](handleEntityNotFound(_0x3f8320,null))[_0x31735f('0xb3')](function(_0x17d402){const _0x5665bd=_0x31735f;if(_0x17d402)return _0x17d402[_0x5665bd('0x4f')](_0xd2e973['query'][_0x5665bd('0x4a')]);})[_0x31735f('0xb3')](respondWithStatusCode(_0x3f8320,null))[_0x31735f('0xc6')](handleError(_0x3f8320,null));},exports['download']=function(_0x41a36f,_0x319acc){const _0x4da7a7=_0x29c6e7,_0x3c9cd5=moment()[_0x4da7a7('0x83')]()[_0x4da7a7('0x51')](),_0x86c2e2=path[_0x4da7a7('0x68')](config[_0x4da7a7('0xda')],'files',_0x4da7a7('0x6a')),_0x6a6e31=path['join'](_0x86c2e2,_0x3c9cd5),_0x19105b=util['format'](_0x4da7a7('0x6d'),_0x41a36f[_0x4da7a7('0x4d')]['id'],_0x3c9cd5),_0x1841a4=path[_0x4da7a7('0x68')](_0x86c2e2,_0x19105b),_0xb78b98=[];_0xb78b98[_0x4da7a7('0xbe')]({'model':db['User'],'as':_0x4da7a7('0x7a'),'attributes':['id',_0x4da7a7('0xc5')],'raw':!![]}),_0xb78b98['push']({'model':db['CmContact'],'as':_0x4da7a7('0x20'),'attributes':['id',_0x4da7a7('0x36'),_0x4da7a7('0x15')],'raw':!![]});const _0x5132cf=[{'model':db['SmsMessage'],'as':'Messages','attributes':['id',_0x4da7a7('0x5e'),'createdAt',_0x4da7a7('0xd0'),_0x4da7a7('0xad'),'read'],'include':_0xb78b98}];return _0x5132cf[_0x4da7a7('0xbe')]({'model':db[_0x4da7a7('0x56')],'as':_0x4da7a7('0x96'),'attributes':['id',_0x4da7a7('0x3a')]}),_0x5132cf[_0x4da7a7('0xbe')]({'model':db[_0x4da7a7('0x7a')],'as':_0x4da7a7('0x3c'),'attributes':['id',_0x4da7a7('0xc5')]}),db['SmsInteraction'][_0x4da7a7('0x82')]({'where':{'id':_0x41a36f[_0x4da7a7('0x4d')]['id']},'include':_0x5132cf})[_0x4da7a7('0xb3')](handleEntityNotFound(_0x319acc,null))[_0x4da7a7('0xb3')](function(_0x2ad6d5){const _0x30260c=_0x4da7a7;if(_0x2ad6d5){const _0xe4feb1=_0x2ad6d5[_0x30260c('0x3')]({'plain':!![]});fs['mkdirSync'](_0x6a6e31);const _0x10ea75={'format':'A4','border':_0x30260c('0x34'),'header':{'height':'40px','contents':{'first':_0x30260c('0x5a')}},'footer':{'height':_0x30260c('0xa0'),'contents':{'default':util[_0x30260c('0xdc')](_0x30260c('0x8'),util[_0x30260c('0xdc')](_0x30260c('0x14'),_0x30260c('0xd5'),_0xe4feb1['id']),moment()[_0x30260c('0xdc')](_0x30260c('0x9b'))[_0x30260c('0x51')]())}}},_0x2ea2c8={'channel':_0x30260c('0xd5'),'account':_0xe4feb1['Account'][_0x30260c('0x3a')],'agent':_0xe4feb1[_0x30260c('0x3c')]?_0xe4feb1[_0x30260c('0x3c')][_0x30260c('0xc5')]:'N.A.','createdAt':moment(_0xe4feb1['createdAt'])['format'](_0x30260c('0x54'))[_0x30260c('0x51')](),'closedAt':_0xe4feb1[_0x30260c('0x41')]?moment(_0xe4feb1[_0x30260c('0x11')])[_0x30260c('0xdc')](_0x30260c('0x54'))['toString']():'','disposition':_0xe4feb1[_0x30260c('0xc3')],'messages':_(_0xe4feb1[_0x30260c('0xd2')])['filter']({'secret':![]})[_0x30260c('0xc')](function(_0x48d3d3){const _0x21236d=_0x30260c;return{'date':moment(_0x48d3d3[_0x21236d('0x3b')])[_0x21236d('0xdc')](_0x21236d('0x54'))[_0x21236d('0x51')](),'sender':_0x48d3d3[_0x21236d('0xd0')]===_0x21236d('0x75')?_0x48d3d3[_0x21236d('0x7a')]?_0x48d3d3[_0x21236d('0x7a')][_0x21236d('0xc5')]:'System':_0x48d3d3[_0x21236d('0x20')][_0x21236d('0x36')]+(_0x48d3d3['Contact']['lastName']?'\x20'+_0x48d3d3['Contact']['lastName']:''),'body':_0x48d3d3['body'],'direction':_0x48d3d3[_0x21236d('0xd0')]===_0x21236d('0x75')?'A':'C','secret':_0x48d3d3[_0x21236d('0xad')],'read':_0x48d3d3[_0x21236d('0x65')]};})[_0x30260c('0x67')]()};return ejs[_0x30260c('0x33')](path[_0x30260c('0x68')](config[_0x30260c('0xda')],_0x30260c('0x30'),_0x30260c('0x76'),_0x30260c('0x93')),{'interaction':_0x2ea2c8})['then'](function(_0x22155b){return new Promise(function(_0x535aae,_0x413515){const _0x13ebac=a553_0x2887;pdf['create'](_0x22155b,_0x10ea75)[_0x13ebac('0x8f')](path[_0x13ebac('0x68')](_0x6a6e31,'transcript-'+_0xe4feb1['id']+'-'+_0x3c9cd5+'.pdf'),function(_0x285b06,_0x28d0fe){if(_0x285b06)return _0x413515(_0x285b06);_0x535aae(_0x28d0fe);});});})[_0x30260c('0xb3')](function(){const _0x3a68b2=_0x30260c;return new Promise(function(_0x40d807,_0x584dbd){zipdir(_0x6a6e31,{'saveTo':_0x1841a4},function(_0x402886,_0x3e46ce){if(_0x402886)return _0x584dbd(_0x402886);return _0x40d807(_0x3e46ce);});})['then'](function(){return new Promise(function(_0x45e8a6,_0xcf5d07){rimraf(_0x6a6e31,function(_0x264a62){if(_0x264a62)_0xcf5d07(_0x264a62);return _0x45e8a6();});});})[_0x3a68b2('0xb3')](function(){const _0x565782=_0x3a68b2;return _0x319acc[_0x565782('0x48')](_0x1841a4,_0x19105b,function(_0x5244b7){const _0xbbf0fb=_0x565782;_0x5244b7?console[_0xbbf0fb('0x42')](_0xbbf0fb('0x29'),_0x5244b7):fs[_0xbbf0fb('0x5d')](_0x1841a4);});});});}else return _0x319acc[_0x30260c('0x12')](0xc8);})[_0x4da7a7('0xc6')](handleError(_0x319acc,null));}; \ No newline at end of file +const a553_0x558e=['where','tmp','getMessages','Account.key','$substring','`\x20=\x200','findAll','SmsInteraction','replace','util','type','closed','keys','buildExpression','%s\x20#%d','c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?','views','compact','User','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','tools_tags','sort','ui.SmsInteractionId','filter','../../components/parsers/qs','unreadMessages','push','users','10px','count','join','i.createdAt\x20BETWEEN\x20?\x20AND\x20?','describe','attributes','u.id\x20=\x20ui.UserId','fullname','split','isNumeric','merge','update','CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?','sequelize','SmsAccountId','Account','moment','server','c.mobile','parseSearch','files','c.fax','key','i.id','o.internal','Contact.email','GROUP_CONCAT(DISTINCT\x20t.id)','i.SmsAccountId\x20IN\x20?','union','expr','clone','get','zip-dir','\x20=\x20?','`unreadMessages`\x20>\x200','log','`unreadMessages`\x20=\x200','left_join','model','sendStatus','out','u.fullname','having','transcript-','\x27\x27\x27\x27','ContactId','operator','status','error','isEmpty','Tag','field','rawAttributes','stack','it.SmsInteractionId\x20=\x20i.id','u.id','intersection','c.email','SmsInteractionId','query','$gte','name','`\x20>\x200','conditions','Owner','sms_interaction_has_tags','omit','TagIds','unix','user','parse','pick','Owner.fullname','Contact.phone','a.id\x20=\x20i.SmsAccountId','register','firstName','limit','toString','sms_messages','value','N.A.','end','MATCH\x20(me.body)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','api','color','sqlOperator','i.id\x20LIKE\x20?','emit','Contact.fax','root','Contact.mobile','System','disposition','create','../../rediscache','direction','like','includeAll','include','send','c.firstName','then','ids','addMessage','nolimit','40px','err','$lte','body','offset','secret','tag','findOne','Users','catch','destroy','filters','c.lastName','text','UserId','Account.mandatoryDisposition','c.phone','\x20IS\x20NULL','find','squel','lastName','Contact.firstName','SmsMessage','length','YYYY-MM-DD\x20HH:mm:ss','journey','i.SmsAccountId\x20IS\x20NULL','addTags','undefined','search','createdAt','Sms','QueryTypes','fields','getSmsAccounts','params','cm_contacts','getFullTextValue','i.SmsAccountId\x20IS\x20NOT\x20NULL','i.phone\x20LIKE\x20?','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{page}}/{{pages}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','../../mysqldb','rows','transcript-%d-%s.zip','unlinkSync','some','Messages','30px','all','options','renderFile','format','ejs','path','MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','concat','order','sms_interactions','me.SmsInteractionId\x20=\x20i.id','toFile','start','user_has_sms_interactions','./smsInteraction.socket','i.*','null','../../components/parsers/advancedSearch','download','select','resolve','t.id\x20IN\x20?','smsInteractionTags:save','fieldName','index','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','setTags','isArray','Contact','Tags','from','forEach','read','map','o.id\x20=\x20i.UserId','json'];(function(_0x3e2815,_0x558e1a){const _0x1449e8=function(_0x472415){while(--_0x472415){_0x3e2815['push'](_0x3e2815['shift']());}};_0x1449e8(++_0x558e1a);}(a553_0x558e,0x123));const a553_0x1449=function(_0x3e2815,_0x558e1a){_0x3e2815=_0x3e2815-0x0;let _0x1449e8=a553_0x558e[_0x3e2815];return _0x1449e8;};const _0x22d542=a553_0x1449;'use strict';const pdf=require('html-pdf'),rimraf=require('rimraf'),zipdir=require(_0x22d542('0xcd')),moment=require(_0x22d542('0xbd')),util=require(_0x22d542('0x9a')),path=require(_0x22d542('0x72')),ejs=require(_0x22d542('0x71')),fs=require('fs'),_=require('lodash'),squel=require(_0x22d542('0x50')),{getSocket}=require(_0x22d542('0x32')),socket=getSocket(),qs=require(_0x22d542('0xa9')),as=require(_0x22d542('0x7e')),logger=require('../../config/logger')(_0x22d542('0x27')),config=require('../../config/environment'),db=require(_0x22d542('0x66'))['db'],{Op}=require(_0x22d542('0xba'));require(_0x22d542('0x7b'))[_0x22d542('0x1e')](socket);function respondWithStatusCode(_0x472415,_0x14f59a){return _0x14f59a=_0x14f59a||0xcc,function(_0x3b96e0){const _0x321613=a553_0x1449;if(_0x3b96e0)return _0x472415['sendStatus'](_0x14f59a);return _0x472415['status'](_0x14f59a)[_0x321613('0x25')]();};}function respondWithResult(_0x43c886,_0x273491){return _0x273491=_0x273491||0xc8,function(_0x4692c2){const _0x4b78c1=a553_0x1449;if(_0x4692c2)return _0x43c886['status'](_0x273491)[_0x4b78c1('0x90')](_0x4692c2);};}function respondWithFilteredResult(_0x11557a,_0x43bb64){return function(_0xc23473){const _0x1743d5=a553_0x1449;if(_0xc23473){const _0x507297=_0xc23473['count'],_0x1360f0=_0x43bb64['offset'];let _0x4faff1=_0x43bb64[_0x1743d5('0x41')]+_0x43bb64[_0x1743d5('0x20')],_0x322410;return _0x4faff1>=_0x507297?(_0x4faff1=_0x507297,_0x322410=0xc8):_0x322410=0xce,_0x11557a['status'](_0x322410),_0x11557a['set']('Content-Range',_0x1360f0+'-'+_0x4faff1+'/'+_0x507297)[_0x1743d5('0x90')](_0xc23473);}return null;};}function saveUpdates(_0x4229b3){return function(_0xe68988){const _0x13ede6=a553_0x1449;if(_0xe68988)return _0xe68988[_0x13ede6('0xb8')](_0x4229b3)['then'](function(_0x345604){return _0x345604;});return null;};}function removeEntity(_0x131e86){return function(_0x293d53){const _0x59aca6=a553_0x1449;if(_0x293d53)return _0x293d53[_0x59aca6('0x47')]()['then'](function(){const _0x4bdc67=_0x59aca6;_0x131e86[_0x4bdc67('0x2')](0xcc)[_0x4bdc67('0x25')]();});};}function handleEntityNotFound(_0x5357ea){return function(_0x4cb9b9){const _0x45ba61=a553_0x1449;return!_0x4cb9b9&&_0x5357ea[_0x45ba61('0xd4')](0x194),_0x4cb9b9;};}function handleError(_0xa60c27,_0x1bb18a){return _0x1bb18a=_0x1bb18a||0x1f4,function(_0x5d6667){const _0x1dad49=a553_0x1449;logger[_0x1dad49('0x3')](_0x5d6667[_0x1dad49('0x8')]),_0x5d6667['name']&&delete _0x5d6667['name'],_0xa60c27['status'](_0x1bb18a)[_0x1dad49('0x37')](_0x5d6667);};}function getInteractionUsers(_0x567857,_0x5952bd){return new Promise(function(_0x184366,_0x4d745a){const _0x5bb2a0=a553_0x1449;try{_0x5952bd[_0x567857['id']]&&(_0x567857[_0x5bb2a0('0x45')]=_['map'](_0x5952bd[_0x567857['id']],function(_0x5b68a5){const _0x18d83d=_0x5bb2a0;return{'id':_0x5b68a5['id'],'fullname':_0x5b68a5[_0x18d83d('0xb4')]};}));}catch(_0x5d4bcd){_0x4d745a(_0x5d4bcd);}_0x184366(_0x567857);});}function getInteractionTags(_0x130aa7,_0x401bf1){return new Promise(function(_0x35482b,_0x2e49ea){const _0x4c641b=a553_0x1449;try{_0x130aa7[_0x4c641b('0x16')]&&(_0x130aa7[_0x4c641b('0x8a')]=[],_0x130aa7[_0x4c641b('0x16')][_0x4c641b('0xb5')](',')[_0x4c641b('0x8c')](function(_0x3155cb){const _0x4aeae5=_0x4c641b;_0x130aa7[_0x4aeae5('0x8a')][_0x4aeae5('0xab')](_0x401bf1[_0x3155cb]);})),delete _0x130aa7[_0x4c641b('0x16')];}catch(_0x347d58){_0x2e49ea(_0x347d58);}_0x35482b(_0x130aa7);});}function updateSmsInteraction(_0x4cdfa9,_0x32dd33,_0x273efa){return new Promise(function(_0x448ac3,_0x4ef624){const _0x15c4b5=a553_0x1449;return getInteractionUsers(_0x4cdfa9,_0x273efa)['then'](function(_0x2f780a){return getInteractionTags(_0x2f780a,_0x32dd33);})[_0x15c4b5('0x39')](function(_0x3d7c98){_0x448ac3(_0x3d7c98);})['catch'](function(_0x2e6f95){_0x4ef624(_0x2e6f95);});});}exports[_0x22d542('0x85')]=function(_0x3a4895,_0xd92ac6){const _0x526bb5=_0x22d542,_0x1d5dff={},_0x21db3f={},_0x132374={'count':0x0,'rows':[]},_0x2a5868=_['map'](db[_0x526bb5('0x98')][_0x526bb5('0x7')],function(_0x32fbea){const _0x4ca0b6=_0x526bb5;return{'name':_0x32fbea[_0x4ca0b6('0x84')],'type':_0x32fbea[_0x4ca0b6('0x9b')][_0x4ca0b6('0xc3')]};});_0x21db3f[_0x526bb5('0xd3')]=_['map'](_0x2a5868,'name'),_0x21db3f[_0x526bb5('0xe')]=_[_0x526bb5('0x9d')](_0x3a4895[_0x526bb5('0xe')]),_0x21db3f[_0x526bb5('0x48')]=_[_0x526bb5('0xb')](_0x21db3f['model'],_0x21db3f[_0x526bb5('0xe')]),_0x1d5dff[_0x526bb5('0xb2')]=_[_0x526bb5('0xb')](_0x21db3f[_0x526bb5('0xd3')],qs[_0x526bb5('0x5e')](_0x3a4895[_0x526bb5('0xe')][_0x526bb5('0x5e')])),_0x1d5dff[_0x526bb5('0xb2')]=_0x1d5dff[_0x526bb5('0xb2')][_0x526bb5('0x54')]?_0x1d5dff[_0x526bb5('0xb2')]:_0x21db3f[_0x526bb5('0xd3')];typeof _0x3a4895['query'][_0x526bb5('0x3c')]==='undefined'&&(_0x1d5dff[_0x526bb5('0x20')]=qs[_0x526bb5('0x20')](_0x3a4895[_0x526bb5('0xe')][_0x526bb5('0x20')]),_0x1d5dff['offset']=qs[_0x526bb5('0x41')](_0x3a4895[_0x526bb5('0xe')]['offset']));_0x1d5dff[_0x526bb5('0x75')]=qs[_0x526bb5('0xa6')](_0x3a4895[_0x526bb5('0xe')]['sort']),_0x1d5dff[_0x526bb5('0x91')]=qs[_0x526bb5('0x48')](_[_0x526bb5('0x1a')](_0x3a4895[_0x526bb5('0xe')],_0x21db3f[_0x526bb5('0x48')]),_0x2a5868);let _0x597042=[];const _0x99edb6=squel[_0x526bb5('0x80')]()[_0x526bb5('0x6')]('id')[_0x526bb5('0x6')]('name')[_0x526bb5('0x6')](_0x526bb5('0x28'))[_0x526bb5('0x8b')](_0x526bb5('0xa5')),_0xf5ab6d=squel[_0x526bb5('0x80')]()['field'](_0x526bb5('0xa'))[_0x526bb5('0x6')](_0x526bb5('0xd6'))['field'](_0x526bb5('0xa7'))[_0x526bb5('0x8b')](_0x526bb5('0x7a'),'ui')[_0x526bb5('0xd2')]('users','u',_0x526bb5('0xb3')),_0x341a9e=squel[_0x526bb5('0x80')]()['from'](_0x526bb5('0x76'),'i')[_0x526bb5('0xd2')](_0x526bb5('0x61'),'c','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL')[_0x526bb5('0xd2')](_0x526bb5('0xac'),'o',_0x526bb5('0x8f'))[_0x526bb5('0xd2')]('sms_accounts','a',_0x526bb5('0x1d'))[_0x526bb5('0xd2')](_0x526bb5('0x22'),'me',_0x526bb5('0x77'))[_0x526bb5('0xd2')](_0x526bb5('0x14'),'it',_0x526bb5('0x9'))['left_join'](_0x526bb5('0xa5'),'t','t.id\x20=\x20it.TagId'),_0xe071d6=squel[_0x526bb5('0xca')]();let _0x5f24f4=[];const _0x1d75ab=squel[_0x526bb5('0xca')]();let _0x5c155b;if(_0x3a4895['query']['search']){_0x5c155b=as[_0x526bb5('0xc0')](_0x3a4895[_0x526bb5('0xe')][_0x526bb5('0x5a')]);const _0x1fd409=_0x5c155b[_0x526bb5('0x29')];for(let _0xd7be11=0x0;_0xd7be11<_0x5c155b[_0x526bb5('0x12')]['length'];_0xd7be11++){const _0x2947e6=_0x5c155b[_0x526bb5('0x12')][_0xd7be11],_0x526d12='i';let _0x338b7,_0x333271=_[_0x526bb5('0x4f')](_0x2a5868,['name',_0x2947e6[_0x526bb5('0x6')]]);if(!_0x333271)switch(_0x2947e6['field']){case _0x526bb5('0xaa'):_0x2947e6['value']==0x1?_0x341a9e[_0x526bb5('0xd7')]('`'+_0x2947e6[_0x526bb5('0x6')]+_0x526bb5('0x96')):_0x341a9e[_0x526bb5('0xd7')]('`'+_0x2947e6[_0x526bb5('0x6')]+_0x526bb5('0x11'));break;case _0x526bb5('0x89'):if(_0x2947e6[_0x526bb5('0x1')]===_0x526bb5('0x95')){if(_0x2947e6[_0x526bb5('0x23')][_0x526bb5('0xb5')]('\x20')['length']>0x1)_0xe071d6[_0x1fd409](_0x526bb5('0x73'),qs['getFullTextValue'](_0x2947e6[_0x526bb5('0x23')]),null);else{const _0x5550ed='%'+_0x2947e6['value']+'%';_0xe071d6[_0x1fd409](_0x526bb5('0xa0'),_0x5550ed,_0x5550ed,_0x5550ed);}}else _0x333271=_[_0x526bb5('0x4f')](_0x2a5868,[_0x526bb5('0x10'),'ContactId']),_0x2947e6['field']=_0x526bb5('0x0'),_0x338b7=as[_0x526bb5('0x9e')](_0x526d12,_0x333271[_0x526bb5('0x9b')],_0x2947e6),_0xe071d6[_0x1fd409](_0x338b7[_0x526bb5('0x4a')],_0x338b7[_0x526bb5('0x23')][_0x526bb5('0x79')],_0x338b7['value'][_0x526bb5('0x25')]);break;case _0x526bb5('0x5'):{const _0x1422e4=_0x2947e6[_0x526bb5('0x23')][_0x526bb5('0xb5')](',')[_0x526bb5('0x8e')](function(_0x554bfe){return Number(_0x554bfe);});_0x1422e4['forEach'](function(_0x364c91){const _0x246fd4=_0x526bb5;_0x1d75ab['or'](_0x246fd4('0x86'),'%,'+_0x364c91+',%');}),_0x5f24f4=_[_0x526bb5('0xc9')](_0x5f24f4,_0x1422e4);}break;case'User':_0x2947e6['operator']===_0x526bb5('0x95')?_0xe071d6[_0x1fd409](_0x526bb5('0xa4'),'%'+_0x2947e6[_0x526bb5('0x23')]+'%',null):(_0x333271=_['find'](_0x2a5868,[_0x526bb5('0x10'),_0x526bb5('0x4b')]),_0x2947e6[_0x526bb5('0x6')]=_0x526bb5('0x4b'),_0x338b7=as[_0x526bb5('0x9e')](_0x526d12,_0x333271[_0x526bb5('0x9b')],_0x2947e6),_0xe071d6[_0x1fd409](_0x338b7[_0x526bb5('0x4a')],_0x338b7[_0x526bb5('0x23')][_0x526bb5('0x79')],_0x338b7[_0x526bb5('0x23')][_0x526bb5('0x25')]));break;case'body':_0x338b7=as[_0x526bb5('0x9e')]('me',null,_0x2947e6),_0xe071d6[_0x1fd409](_0x338b7[_0x526bb5('0x4a')],_0x338b7['value'][_0x526bb5('0x79')],_0x338b7[_0x526bb5('0x23')][_0x526bb5('0x25')]);break;}else _0x338b7=as[_0x526bb5('0x9e')](_0x526d12,_0x333271['type'],_0x2947e6),_0xe071d6[_0x1fd409](_0x338b7[_0x526bb5('0x4a')],_0x338b7[_0x526bb5('0x23')][_0x526bb5('0x79')],_0x338b7[_0x526bb5('0x23')][_0x526bb5('0x25')]);}}else{const _0x3db90f=_(_0x3a4895[_0x526bb5('0xe')])[_0x526bb5('0x9d')]()[_0x526bb5('0x8e')](function(_0x54c530){const _0x11e341=_0x526bb5;return _[_0x11e341('0x6a')](_0x2a5868,['name',_0x54c530])?_0x54c530:undefined;})[_0x526bb5('0xa2')]()[_0x526bb5('0x23')]();!_[_0x526bb5('0x4')](_0x3db90f)&&_0x3db90f['forEach'](function(_0x1320a7){const _0x2950d3=_0x526bb5;if(_0x1320a7===_0x2950d3('0xbb'))_0x341a9e[_0x2950d3('0x91')](_0x2950d3('0xc8'),[][_0x2950d3('0x74')](_0x3a4895[_0x2950d3('0xe')][_0x1320a7]));else{if(_0x1320a7===_0x2950d3('0x5b')){const _0x235dac=JSON[_0x2950d3('0x19')](_0x3a4895[_0x2950d3('0xe')][_0x1320a7])['$gte'],_0x24be97=JSON['parse'](_0x3a4895[_0x2950d3('0xe')][_0x1320a7])[_0x2950d3('0x3f')];_0x341a9e[_0x2950d3('0x91')](_0x2950d3('0xb0'),_0x235dac,_0x24be97);}else _0x3a4895[_0x2950d3('0xe')][_0x1320a7]===_0x2950d3('0x7d')?_0x341a9e[_0x2950d3('0x91')]('i.'+_0x1320a7+_0x2950d3('0x4e')):_0x341a9e[_0x2950d3('0x91')]('i.'+_0x1320a7+_0x2950d3('0xce'),_0x3a4895[_0x2950d3('0xe')][_0x1320a7]);}});_0x3a4895[_0x526bb5('0xe')][_0x526bb5('0x8d')]&&(_0x3a4895[_0x526bb5('0xe')][_0x526bb5('0x8d')]==0x1?_0x341a9e[_0x526bb5('0xd7')](_0x526bb5('0xd1')):_0x341a9e['having'](_0x526bb5('0xcf')));_0x3a4895['query'][_0x526bb5('0x43')]&&(_0x5f24f4=_[_0x526bb5('0x88')](_0x3a4895['query'][_0x526bb5('0x43')])?_0x3a4895[_0x526bb5('0xe')]['tag']:new Array(_0x3a4895[_0x526bb5('0xe')][_0x526bb5('0x43')]),_0x5f24f4['forEach'](function(_0x560fb5){_0x1d75ab['or']('CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','%,'+_0x560fb5+',%');}));if(_0x3a4895[_0x526bb5('0xe')][_0x526bb5('0xa8')]){const _0x5aae51=_0x3a4895[_0x526bb5('0xe')]['filter'][_0x526bb5('0x99')]('\x5c','\x5c\x5c')[_0x526bb5('0x99')]('\x27\x27',_0x526bb5('0xd9'));qs[_0x526bb5('0xb6')](_0x5aae51)?_0xe071d6['or'](_0x526bb5('0x2a'),_0x5aae51+'%')['or'](_0x526bb5('0x64'),_0x5aae51+'%'):_0xe071d6['or'](_0x526bb5('0x26'),qs[_0x526bb5('0x62')](_0x5aae51))['or'](_0x526bb5('0xb9'),_0x5aae51+'%');}}_0x341a9e[_0x526bb5('0x91')](_0xe071d6),_0x341a9e['group'](_0x526bb5('0xc4'));let _0x25c012={'type':db['Sequelize'][_0x526bb5('0x5d')]['SELECT'],'raw':!![]};const _0x19a5d8=_0x341a9e[_0x526bb5('0xcb')]();_0x19a5d8[_0x526bb5('0x6')](_0x526bb5('0xc4')),_0x19a5d8[_0x526bb5('0x6')]('SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)',_0x526bb5('0xaa')),_0x1d5dff[_0x526bb5('0x75')]&&_0x1d5dff[_0x526bb5('0x75')][_0x526bb5('0x8c')](function(_0x149a82){const _0x131e47=_0x526bb5;_0x341a9e[_0x131e47('0x75')]('i.'+_0x149a82[0x0],_0x149a82[0x1]==='DESC'?![]:!![]);}),!_[_0x526bb5('0x4')](_0x5f24f4)&&(_0x341a9e[_0x526bb5('0xd7')](_0x1d75ab),_0x19a5d8['where'](_0x526bb5('0x82'),_0x5f24f4)),Promise[_0x526bb5('0x81')]()[_0x526bb5('0x39')](function(){const _0x237998=_0x526bb5;if(!_0x5c155b){if(_0x3a4895['query'][_0x237998('0xbb')]||_0x3a4895['query'][_0x237998('0x56')])return;_0x19a5d8[_0x237998('0x91')](_0x237998('0x63')),_0x341a9e['where'](_0x237998('0x63'));return;}return _0x3a4895[_0x237998('0x18')][_0x237998('0x5f')]({'attributes':['id'],'raw':!![]})[_0x237998('0x39')](function(_0x2ee1a5){const _0x256e0f=_0x237998;_[_0x256e0f('0x4')](_0x2ee1a5)?(_0x19a5d8[_0x256e0f('0x91')](_0x256e0f('0x57')),_0x341a9e['where'](_0x256e0f('0x57'))):(_0x19a5d8[_0x256e0f('0x91')](_0x256e0f('0xc8'),_['map'](_0x2ee1a5,'id')),_0x341a9e[_0x256e0f('0x91')](_0x256e0f('0xc8'),_[_0x256e0f('0x8e')](_0x2ee1a5,'id')));});})[_0x526bb5('0x39')](function(){const _0x508134=_0x526bb5;db[_0x508134('0xba')][_0x508134('0xe')](_0x19a5d8[_0x508134('0x21')](),_0x25c012)[_0x508134('0x39')](function(_0x58accf){const _0x87ffc=_0x508134;_0x132374[_0x87ffc('0xae')]=_0x58accf[_0x87ffc('0x54')];if(_0x132374[_0x87ffc('0xae')]===0x0)return[];return db[_0x87ffc('0xba')][_0x87ffc('0xe')](_0x99edb6[_0x87ffc('0x21')](),_0x25c012)[_0x87ffc('0x39')](function(_0x376e44){const _0x49bc93=_0x87ffc;_0x597042=_['keyBy'](_0x376e44,'id'),_0x25c012=_['merge'](_0x25c012,{'model':db['SmsInteraction'],'mapToModel':!![],'raw':!![],'nest':!![]});_0x3a4895[_0x49bc93('0xe')]['fields']?_0x1d5dff[_0x49bc93('0xb2')][_0x49bc93('0x8c')](function(_0x55799b){_0x341a9e['field']('i.'+_0x55799b);}):(_0x341a9e[_0x49bc93('0x6')]('SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','unreadMessages'),_0x341a9e[_0x49bc93('0x6')]('a.key',_0x49bc93('0x94')),_0x341a9e['field']('a.mandatoryDisposition',_0x49bc93('0x4c')),_0x341a9e[_0x49bc93('0x6')](_0x49bc93('0x7c')),_0x341a9e[_0x49bc93('0x6')](_0x49bc93('0x38'),_0x49bc93('0x52')),_0x341a9e[_0x49bc93('0x6')](_0x49bc93('0x49'),'Contact.lastName'),_0x341a9e['field'](_0x49bc93('0xc'),_0x49bc93('0xc6')),_0x341a9e[_0x49bc93('0x6')](_0x49bc93('0x4d'),_0x49bc93('0x1c')),_0x341a9e[_0x49bc93('0x6')](_0x49bc93('0xbf'),_0x49bc93('0x2e')),_0x341a9e[_0x49bc93('0x6')](_0x49bc93('0xc2'),_0x49bc93('0x2c')),_0x341a9e[_0x49bc93('0x6')]('o.fullname',_0x49bc93('0x1b')),_0x341a9e[_0x49bc93('0x6')](_0x49bc93('0xc5'),'Owner.internal'),_0x341a9e['field'](_0x49bc93('0xc7'),'TagIds'));if(_0x1d5dff['limit'])_0x341a9e[_0x49bc93('0x20')](_0x1d5dff['limit']);if(_0x1d5dff['offset'])_0x341a9e[_0x49bc93('0x41')](_0x1d5dff[_0x49bc93('0x41')]);return db[_0x49bc93('0xba')][_0x49bc93('0xe')](_0x341a9e[_0x49bc93('0x21')](),_0x25c012);})[_0x87ffc('0x39')](function(_0x178196){const _0x8bba68=_0x87ffc;return _0xf5ab6d[_0x8bba68('0x91')]('ui.SmsInteractionId\x20IN\x20?',_[_0x8bba68('0x8e')](_0x178196,'id')),db[_0x8bba68('0xba')][_0x8bba68('0xe')](_0xf5ab6d['toString'](),_0x25c012)[_0x8bba68('0x39')](function(_0x4e2849){const _0x8ddf69=_0x8bba68,_0x320849=_['groupBy'](_0x4e2849,_0x8ddf69('0xd')),_0x57d9cc=[];return _0x178196[_0x8ddf69('0x8c')](function(_0x4f405a){const _0x33bf16=_0x8ddf69;_0x57d9cc[_0x33bf16('0xab')](updateSmsInteraction(_0x4f405a,_0x597042,_0x320849));}),Promise[_0x8ddf69('0x6d')](_0x57d9cc);});});})[_0x508134('0x39')](function(_0x5c2b56){const _0x166797=_0x508134;return _0x132374[_0x166797('0x67')]=_0x5c2b56,_0x132374;})[_0x508134('0x39')](respondWithFilteredResult(_0xd92ac6,_0x1d5dff));})[_0x526bb5('0x46')](handleError(_0xd92ac6,null));},exports['show']=function(_0x16e4d3,_0x23963b){const _0x1b624a=_0x22d542;let _0x4d829b={'raw':![],'where':{'id':_0x16e4d3[_0x1b624a('0x60')]['id']}};const _0x4df23f={};return _0x4df23f[_0x1b624a('0xd3')]=_['keys'](db[_0x1b624a('0x98')]['rawAttributes']),_0x4df23f[_0x1b624a('0xe')]=_[_0x1b624a('0x9d')](_0x16e4d3[_0x1b624a('0xe')]),_0x4df23f[_0x1b624a('0x48')]=_[_0x1b624a('0xb')](_0x4df23f[_0x1b624a('0xd3')],_0x4df23f[_0x1b624a('0xe')]),_0x4d829b[_0x1b624a('0xb2')]=_[_0x1b624a('0xb')](_0x4df23f[_0x1b624a('0xd3')],qs[_0x1b624a('0x5e')](_0x16e4d3[_0x1b624a('0xe')]['fields'])),_0x4d829b[_0x1b624a('0xb2')]=_0x4d829b['attributes'][_0x1b624a('0x54')]?_0x4d829b[_0x1b624a('0xb2')]:_0x4df23f[_0x1b624a('0xd3')],_0x16e4d3[_0x1b624a('0xe')][_0x1b624a('0x35')]&&(_0x4d829b['include']=[{'all':!![]}]),_0x4d829b=_[_0x1b624a('0xb7')]({},_0x4d829b,_0x16e4d3[_0x1b624a('0x6e')]),db[_0x1b624a('0x98')][_0x1b624a('0x44')](_0x4d829b)[_0x1b624a('0x39')](handleEntityNotFound(_0x23963b,null))['then'](respondWithResult(_0x23963b,null))['catch'](handleError(_0x23963b,null));},exports[_0x22d542('0x31')]=function(_0x3d6f9a,_0xd730ea){const _0x491513=_0x22d542;return db['SmsInteraction'][_0x491513('0x31')](_0x3d6f9a[_0x491513('0x40')],{})[_0x491513('0x39')](respondWithResult(_0xd730ea,0xc9))['catch'](handleError(_0xd730ea,null));},exports['update']=function(_0x32fa7a,_0x2996d8){const _0x2478d2=_0x22d542;return _0x32fa7a[_0x2478d2('0x40')]['id']&&delete _0x32fa7a[_0x2478d2('0x40')]['id'],db[_0x2478d2('0x98')][_0x2478d2('0x44')]({'where':{'id':_0x32fa7a[_0x2478d2('0x60')]['id']}})[_0x2478d2('0x39')](handleEntityNotFound(_0x2996d8,null))['then'](saveUpdates(_0x32fa7a[_0x2478d2('0x40')],null))['then'](respondWithResult(_0x2996d8,null))[_0x2478d2('0x46')](handleError(_0x2996d8,null));},exports[_0x22d542('0x47')]=function(_0x16724f,_0x3049da){const _0x25be33=_0x22d542;return db['SmsInteraction'][_0x25be33('0x44')]({'where':{'id':_0x16724f[_0x25be33('0x60')]['id']}})['then'](handleEntityNotFound(_0x3049da,null))[_0x25be33('0x39')](removeEntity(_0x3049da,null))[_0x25be33('0x46')](handleError(_0x3049da,null));},exports[_0x22d542('0xb1')]=function(_0x55ab91,_0x4371b9){const _0x2d6a2f=_0x22d542;return db[_0x2d6a2f('0x98')]['describe']()[_0x2d6a2f('0x39')](respondWithResult(_0x4371b9,null))[_0x2d6a2f('0x46')](handleError(_0x4371b9,null));},exports[_0x22d542('0x3b')]=function(_0x59b480,_0x545087){const _0x4ee897=_0x22d542;return db[_0x4ee897('0x53')]['findOne']({'where':{'id':_0x59b480[_0x4ee897('0x60')]['id']}})[_0x4ee897('0x39')](function(_0x1856c8){const _0x35d4aa=_0x4ee897;if(_0x1856c8)return _0x1856c8[_0x35d4aa('0x3b')](_0x59b480[_0x35d4aa('0x40')]['ids'],{'through':_[_0x35d4aa('0x15')](_0x59b480['body'],[_0x35d4aa('0x3a'),'id'])});})['then'](respondWithResult(_0x545087,null))[_0x4ee897('0x46')](handleError(_0x545087,null));},exports[_0x22d542('0x93')]=function(_0x59c3b7,_0x46ba5f){const _0x17c7b2=_0x22d542;let _0x51398f={'raw':![],'where':{}};const _0x1922f4={},_0x1e7d9d={'count':0x0,'rows':[]};return db[_0x17c7b2('0x98')][_0x17c7b2('0x44')]({'where':{'id':_0x59c3b7[_0x17c7b2('0x60')]['id']}})[_0x17c7b2('0x39')](handleEntityNotFound(_0x46ba5f,null))['then'](function(_0x218d24){const _0x3c6ce2=_0x17c7b2;if(_0x218d24){_0x1922f4[_0x3c6ce2('0xd3')]=_[_0x3c6ce2('0x9d')](db[_0x3c6ce2('0x53')][_0x3c6ce2('0x7')]),_0x1922f4[_0x3c6ce2('0xe')]=_[_0x3c6ce2('0x9d')](_0x59c3b7[_0x3c6ce2('0xe')]),_0x1922f4[_0x3c6ce2('0x48')]=_[_0x3c6ce2('0xb')](_0x1922f4[_0x3c6ce2('0xd3')],_0x1922f4[_0x3c6ce2('0xe')]),_0x51398f[_0x3c6ce2('0xb2')]=_['intersection'](_0x1922f4[_0x3c6ce2('0xd3')],qs['fields'](_0x59c3b7[_0x3c6ce2('0xe')][_0x3c6ce2('0x5e')])),_0x51398f[_0x3c6ce2('0xb2')]=_0x51398f[_0x3c6ce2('0xb2')][_0x3c6ce2('0x54')]?_0x51398f[_0x3c6ce2('0xb2')]:_0x1922f4[_0x3c6ce2('0xd3')];typeof _0x59c3b7[_0x3c6ce2('0xe')]['nolimit']===_0x3c6ce2('0x59')&&(_0x51398f['limit']=qs[_0x3c6ce2('0x20')](_0x59c3b7[_0x3c6ce2('0xe')][_0x3c6ce2('0x20')]),_0x51398f[_0x3c6ce2('0x41')]=qs[_0x3c6ce2('0x41')](_0x59c3b7[_0x3c6ce2('0xe')][_0x3c6ce2('0x41')]));_0x51398f[_0x3c6ce2('0x75')]=qs[_0x3c6ce2('0xa6')](_0x59c3b7[_0x3c6ce2('0xe')]['sort']),_0x51398f[_0x3c6ce2('0x91')]=qs['filters'](_['pick'](_0x59c3b7[_0x3c6ce2('0xe')],_0x1922f4[_0x3c6ce2('0x48')])),_0x51398f['where']['SmsInteractionId']=_0x218d24['id'];_0x59c3b7['query'][_0x3c6ce2('0xa8')]&&(_0x51398f[_0x3c6ce2('0x91')]=_['merge'](_0x51398f['where'],{[Op['or']]:_[_0x3c6ce2('0x8e')](_0x51398f['attributes'],function(_0x4e1d4b){const _0x24b36a=_0x3c6ce2,_0x369d43={};return _0x369d43[_0x4e1d4b]={[Op[_0x24b36a('0x34')]]:'%'+_0x59c3b7[_0x24b36a('0xe')][_0x24b36a('0xa8')]+'%'},_0x369d43;})}));if(_0x59c3b7[_0x3c6ce2('0xe')][_0x3c6ce2('0xf')]){const _0x29da29=_0x59c3b7[_0x3c6ce2('0xe')][_0x3c6ce2('0xf')][_0x3c6ce2('0xb5')](','),_0x1f5ef7={};_0x1f5ef7[_0x29da29[0x0]]={[Op['gte']]:moment(_0x29da29[0x1])[_0x3c6ce2('0x70')](_0x3c6ce2('0x55'))},_0x51398f[_0x3c6ce2('0x91')]=_[_0x3c6ce2('0xb7')](_0x51398f[_0x3c6ce2('0x91')],_0x1f5ef7);}return _0x51398f=_[_0x3c6ce2('0xb7')]({},_0x51398f,_0x59c3b7['options']),db['SmsMessage'][_0x3c6ce2('0xae')]({'where':_0x51398f[_0x3c6ce2('0x91')]})['then'](function(_0x3b2790){const _0x54bc6c=_0x3c6ce2;return _0x1e7d9d[_0x54bc6c('0xae')]=_0x3b2790,_0x59c3b7[_0x54bc6c('0xe')][_0x54bc6c('0x35')]&&(_0x51398f[_0x54bc6c('0x36')]=[{'all':!![]}]),db['SmsMessage']['findAll'](_0x51398f);})[_0x3c6ce2('0x39')](function(_0x126699){return _0x1e7d9d['rows']=_0x126699,_0x1e7d9d;});}})[_0x17c7b2('0x39')](respondWithFilteredResult(_0x46ba5f,_0x51398f))['catch'](handleError(_0x46ba5f,null));},exports[_0x22d542('0x58')]=function(_0xad0af3,_0x1ac960){const _0x1fe783=_0x22d542;return db[_0x1fe783('0x98')][_0x1fe783('0x44')]({'where':{'id':_0xad0af3[_0x1fe783('0x60')]['id']}})[_0x1fe783('0x39')](function(_0x487fa8){const _0x394785=_0x1fe783;if(_0x487fa8)return _0x487fa8[_0x394785('0x87')](_0xad0af3[_0x394785('0x40')][_0x394785('0x3a')],{'through':_[_0x394785('0x15')](_0xad0af3['body'],[_0x394785('0x3a'),'id'])})[_0x394785('0x39')](function(){const _0x1568b5=_0x394785;return db[_0x1568b5('0x5')][_0x1568b5('0x97')]({'attributes':['id','name','color'],'where':{'id':_0xad0af3[_0x1568b5('0x40')][_0x1568b5('0x3a')]}});})[_0x394785('0x39')](function(_0x7720a7){const _0x3bbd1f=_0x394785;return socket[_0x3bbd1f('0x2b')](_0x3bbd1f('0x83'),{'id':Number(_0xad0af3[_0x3bbd1f('0x60')]['id']),'tags':_0x7720a7||[]}),{'id':Number(_0xad0af3[_0x3bbd1f('0x60')]['id']),'tags':_0x7720a7||[]};});})[_0x1fe783('0x39')](respondWithResult(_0x1ac960,null))[_0x1fe783('0x46')](handleError(_0x1ac960,null));},exports['removeTags']=function(_0x21965f,_0x53e564){const _0x246a81=_0x22d542;return db['SmsInteraction'][_0x246a81('0x44')]({'where':{'id':_0x21965f['params']['id']}})[_0x246a81('0x39')](handleEntityNotFound(_0x53e564,null))[_0x246a81('0x39')](function(_0x491b35){const _0x5d6154=_0x246a81;if(_0x491b35)return _0x491b35['removeTags'](_0x21965f[_0x5d6154('0xe')][_0x5d6154('0x3a')]);})[_0x246a81('0x39')](respondWithStatusCode(_0x53e564,null))[_0x246a81('0x46')](handleError(_0x53e564,null));},exports[_0x22d542('0x7f')]=function(_0x56b467,_0x3eb67f){const _0x5e3ff7=_0x22d542,_0x579916=moment()[_0x5e3ff7('0x17')]()[_0x5e3ff7('0x21')](),_0x5a2a25=path['join'](config['root'],_0x5e3ff7('0xc1'),_0x5e3ff7('0x92')),_0x4ca8b5=path[_0x5e3ff7('0xaf')](_0x5a2a25,_0x579916),_0xa10b21=util[_0x5e3ff7('0x70')](_0x5e3ff7('0x68'),_0x56b467[_0x5e3ff7('0x60')]['id'],_0x579916),_0x1e3d2e=path[_0x5e3ff7('0xaf')](_0x5a2a25,_0xa10b21),_0x4506f2=[];_0x4506f2[_0x5e3ff7('0xab')]({'model':db['User'],'as':_0x5e3ff7('0xa3'),'attributes':['id',_0x5e3ff7('0xb4')],'raw':!![]}),_0x4506f2[_0x5e3ff7('0xab')]({'model':db['CmContact'],'as':_0x5e3ff7('0x89'),'attributes':['id',_0x5e3ff7('0x1f'),_0x5e3ff7('0x51')],'raw':!![]});const _0x5790e2=[{'model':db[_0x5e3ff7('0x53')],'as':_0x5e3ff7('0x6b'),'attributes':['id',_0x5e3ff7('0x40'),_0x5e3ff7('0x5b'),_0x5e3ff7('0x33'),'secret',_0x5e3ff7('0x8d')],'include':_0x4506f2}];return _0x5790e2[_0x5e3ff7('0xab')]({'model':db['SmsAccount'],'as':'Account','attributes':['id',_0x5e3ff7('0x10')]}),_0x5790e2[_0x5e3ff7('0xab')]({'model':db[_0x5e3ff7('0xa3')],'as':_0x5e3ff7('0x13'),'attributes':['id',_0x5e3ff7('0xb4')]}),db[_0x5e3ff7('0x98')][_0x5e3ff7('0x44')]({'where':{'id':_0x56b467[_0x5e3ff7('0x60')]['id']},'include':_0x5790e2})[_0x5e3ff7('0x39')](handleEntityNotFound(_0x3eb67f,null))[_0x5e3ff7('0x39')](function(_0x33ce39){const _0x3d6e86=_0x5e3ff7;if(_0x33ce39){const _0x22b0dc=_0x33ce39[_0x3d6e86('0xcc')]({'plain':!![]});fs['mkdirSync'](_0x4ca8b5);const _0x24910f={'format':'A4','border':_0x3d6e86('0xad'),'header':{'height':_0x3d6e86('0x3d'),'contents':{'first':'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
Interaction\x20Transcript
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'}},'footer':{'height':_0x3d6e86('0x6c'),'contents':{'default':util[_0x3d6e86('0x70')](_0x3d6e86('0x65'),util[_0x3d6e86('0x70')](_0x3d6e86('0x9f'),_0x3d6e86('0x5c'),_0x22b0dc['id']),moment()[_0x3d6e86('0x70')]('YYYY-MM-DD')[_0x3d6e86('0x21')]())}}},_0x3b2142={'channel':_0x3d6e86('0x5c'),'account':_0x22b0dc[_0x3d6e86('0xbc')][_0x3d6e86('0x10')],'agent':_0x22b0dc[_0x3d6e86('0x13')]?_0x22b0dc[_0x3d6e86('0x13')][_0x3d6e86('0xb4')]:_0x3d6e86('0x24'),'createdAt':moment(_0x22b0dc['createdAt'])[_0x3d6e86('0x70')](_0x3d6e86('0x55'))['toString'](),'closedAt':_0x22b0dc[_0x3d6e86('0x9c')]?moment(_0x22b0dc['closedAt'])[_0x3d6e86('0x70')](_0x3d6e86('0x55'))[_0x3d6e86('0x21')]():'','disposition':_0x22b0dc[_0x3d6e86('0x30')],'messages':_(_0x22b0dc[_0x3d6e86('0x6b')])[_0x3d6e86('0xa8')]({'secret':![]})[_0x3d6e86('0x8e')](function(_0x3eb25f){const _0x569e9b=_0x3d6e86;return{'date':moment(_0x3eb25f['createdAt'])[_0x569e9b('0x70')](_0x569e9b('0x55'))[_0x569e9b('0x21')](),'sender':_0x3eb25f[_0x569e9b('0x33')]===_0x569e9b('0xd5')?_0x3eb25f[_0x569e9b('0xa3')]?_0x3eb25f['User'][_0x569e9b('0xb4')]:_0x569e9b('0x2f'):_0x3eb25f['Contact'][_0x569e9b('0x1f')]+(_0x3eb25f[_0x569e9b('0x89')][_0x569e9b('0x51')]?'\x20'+_0x3eb25f[_0x569e9b('0x89')][_0x569e9b('0x51')]:''),'body':_0x3eb25f[_0x569e9b('0x40')],'direction':_0x3eb25f[_0x569e9b('0x33')]===_0x569e9b('0xd5')?'A':'C','secret':_0x3eb25f[_0x569e9b('0x42')],'read':_0x3eb25f['read']};})[_0x3d6e86('0x23')]()};return ejs[_0x3d6e86('0x6f')](path[_0x3d6e86('0xaf')](config[_0x3d6e86('0x2d')],_0x3d6e86('0xbe'),_0x3d6e86('0xa1'),'downloadInteraction.html'),{'interaction':_0x3b2142})[_0x3d6e86('0x39')](function(_0x4c5a34){return new Promise(function(_0xb23035,_0x57cf10){const _0x1307ff=a553_0x1449;pdf[_0x1307ff('0x31')](_0x4c5a34,_0x24910f)[_0x1307ff('0x78')](path[_0x1307ff('0xaf')](_0x4ca8b5,_0x1307ff('0xd8')+_0x22b0dc['id']+'-'+_0x579916+'.pdf'),function(_0x55b4ee,_0x1a0dcb){if(_0x55b4ee)return _0x57cf10(_0x55b4ee);_0xb23035(_0x1a0dcb);});});})[_0x3d6e86('0x39')](function(){const _0x597f0e=_0x3d6e86;return new Promise(function(_0x1fd531,_0x13af67){zipdir(_0x4ca8b5,{'saveTo':_0x1e3d2e},function(_0x2e7c66,_0x3072ef){if(_0x2e7c66)return _0x13af67(_0x2e7c66);return _0x1fd531(_0x3072ef);});})[_0x597f0e('0x39')](function(){return new Promise(function(_0x1fc7e4,_0x5a8f9a){rimraf(_0x4ca8b5,function(_0x373550){if(_0x373550)_0x5a8f9a(_0x373550);return _0x1fc7e4();});});})[_0x597f0e('0x39')](function(){const _0x54fda1=_0x597f0e;return _0x3eb67f[_0x54fda1('0x7f')](_0x1e3d2e,_0xa10b21,function(_0x21c068){const _0x2ed653=_0x54fda1;_0x21c068?console[_0x2ed653('0xd0')](_0x2ed653('0x3e'),_0x21c068):fs[_0x2ed653('0x69')](_0x1e3d2e);});});});}else return _0x3eb67f['sendStatus'](0xc8);})['catch'](handleError(_0x3eb67f,null));}; \ No newline at end of file diff --git a/server/api/smsInteraction/smsInteraction.events.js b/server/api/smsInteraction/smsInteraction.events.js index 5e804cf..3b40500 100644 --- a/server/api/smsInteraction/smsInteraction.events.js +++ b/server/api/smsInteraction/smsInteraction.events.js @@ -1 +1 @@ -const a554_0x32d6=['Users','SmsMessage','exports','getUsers','findAll','length','emit','then','save','update','remove','map','unreadMessages','setDataValue','undefined','SmsInteraction','../../mysqldb'];(function(_0x26cd57,_0x32d618){const _0x14100d=function(_0x2a834d){while(--_0x2a834d){_0x26cd57['push'](_0x26cd57['shift']());}};_0x14100d(++_0x32d618);}(a554_0x32d6,0x18f));const a554_0x1410=function(_0x26cd57,_0x32d618){_0x26cd57=_0x26cd57-0x0;let _0x14100d=a554_0x32d6[_0x26cd57];return _0x14100d;};const _0x248b85=a554_0x1410;'use strict';const EventEmitter=require('events'),SmsInteraction=require(_0x248b85('0x8'))['db'][_0x248b85('0x7')],SmsMessage=require(_0x248b85('0x8'))['db'][_0x248b85('0xa')],SmsInteractionEvents=new EventEmitter();SmsInteractionEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x248b85('0x0'),'afterUpdate':_0x248b85('0x1'),'afterDestroy':_0x248b85('0x2')};function emitEvent(_0x2a834d){return function(_0x450ff9){const _0x28672a=a554_0x1410;_0x450ff9[_0x28672a('0xc')]({'attributes':['id'],'raw':!![]})[_0x28672a('0x10')](function(_0x36521a){const _0x1014af=_0x28672a;return _0x450ff9[_0x1014af('0x5')](_0x1014af('0x9'),_0x36521a[_0x1014af('0x3')](function(_0x4c2668){return{'id':_0x4c2668['id']};})),SmsMessage[_0x1014af('0xd')]({'where':{'SmsInteractionId':_0x450ff9['id'],'direction':'in','read':![]},'raw':!![]});})['then'](function(_0x1cb0d9){const _0x256b8f=_0x28672a;_0x450ff9[_0x256b8f('0x5')](_0x256b8f('0x4'),_0x1cb0d9[_0x256b8f('0xe')]),SmsInteractionEvents[_0x256b8f('0xf')](_0x2a834d+':'+_0x450ff9['id'],_0x450ff9),SmsInteractionEvents[_0x256b8f('0xf')](_0x2a834d,_0x450ff9);})['catch'](()=>{});};}for(const e in events){if(typeof events[e]!==_0x248b85('0x6')){const event=events[e];SmsInteraction['addHook'](e,emitEvent(event));}}module[_0x248b85('0xb')]=SmsInteractionEvents; \ No newline at end of file +const a554_0x5f21=['catch','setMaxListeners','findAll','emit','undefined','save','unreadMessages','addHook','map','getUsers','remove','length','SmsInteraction','update','setDataValue','Users','events','exports'];(function(_0x298df8,_0x5f2179){const _0x27b897=function(_0x2ac495){while(--_0x2ac495){_0x298df8['push'](_0x298df8['shift']());}};_0x27b897(++_0x5f2179);}(a554_0x5f21,0x104));const a554_0x27b8=function(_0x298df8,_0x5f2179){_0x298df8=_0x298df8-0x0;let _0x27b897=a554_0x5f21[_0x298df8];return _0x27b897;};const _0x4dc6a8=a554_0x27b8;'use strict';const EventEmitter=require(_0x4dc6a8('0x8')),SmsInteraction=require('../../mysqldb')['db'][_0x4dc6a8('0x4')],SmsMessage=require('../../mysqldb')['db']['SmsMessage'],SmsInteractionEvents=new EventEmitter();SmsInteractionEvents[_0x4dc6a8('0xb')](0x0);const events={'afterCreate':_0x4dc6a8('0xf'),'afterUpdate':_0x4dc6a8('0x5'),'afterDestroy':_0x4dc6a8('0x2')};function emitEvent(_0x2ac495){return function(_0x4b99c4){const _0x4877e9=a554_0x27b8;_0x4b99c4[_0x4877e9('0x1')]({'attributes':['id'],'raw':!![]})['then'](function(_0x5ee0e2){const _0x1449f5=_0x4877e9;return _0x4b99c4['setDataValue'](_0x1449f5('0x7'),_0x5ee0e2[_0x1449f5('0x0')](function(_0x30a07b){return{'id':_0x30a07b['id']};})),SmsMessage[_0x1449f5('0xc')]({'where':{'SmsInteractionId':_0x4b99c4['id'],'direction':'in','read':![]},'raw':!![]});})['then'](function(_0x578c25){const _0x206daf=_0x4877e9;_0x4b99c4[_0x206daf('0x6')](_0x206daf('0x10'),_0x578c25[_0x206daf('0x3')]),SmsInteractionEvents['emit'](_0x2ac495+':'+_0x4b99c4['id'],_0x4b99c4),SmsInteractionEvents[_0x206daf('0xd')](_0x2ac495,_0x4b99c4);})[_0x4877e9('0xa')](()=>{});};}for(const e in events){if(typeof events[e]!==_0x4dc6a8('0xe')){const event=events[e];SmsInteraction[_0x4dc6a8('0x11')](e,emitEvent(event));}}module[_0x4dc6a8('0x9')]=SmsInteractionEvents; \ No newline at end of file diff --git a/server/api/smsInteraction/smsInteraction.model.js b/server/api/smsInteraction/smsInteraction.model.js index 655181a..9e5aa02 100644 --- a/server/api/smsInteraction/smsInteraction.model.js +++ b/server/api/smsInteraction/smsInteraction.model.js @@ -1 +1 @@ -const a555_0x4b2a=['./smsInteraction.attributes','moment','exports','YYYY-MM-DD\x20HH:mm:ss','format','closed','closedAt','sms_interactions'];(function(_0x5673c4,_0x4b2a39){const _0x22f078=function(_0x4e09a3){while(--_0x4e09a3){_0x5673c4['push'](_0x5673c4['shift']());}};_0x22f078(++_0x4b2a39);}(a555_0x4b2a,0x83));const a555_0x22f0=function(_0x5673c4,_0x4b2a39){_0x5673c4=_0x5673c4-0x0;let _0x22f078=a555_0x4b2a[_0x5673c4];return _0x22f078;};const _0x1d91e8=a555_0x22f0;'use strict';const moment=require(_0x1d91e8('0x6')),attributes=require(_0x1d91e8('0x5'));module[_0x1d91e8('0x7')]=function(_0x4e09a3){const _0x4115de=_0x1d91e8,_0x8b3677=_0x4e09a3['define']('SmsInteraction',attributes,{'tableName':_0x4115de('0x4'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x5494d5){const _0x205dd7=_0x4115de;_0x5494d5['changed'](_0x205dd7('0x2'))&&(_0x5494d5[_0x205dd7('0x3')]=moment()[_0x205dd7('0x1')](_0x205dd7('0x0')));}}});return _0x8b3677;}; \ No newline at end of file +const a555_0x4096=['closed','define','closedAt','exports','YYYY-MM-DD\x20HH:mm:ss','SmsInteraction','format','sms_interactions','moment'];(function(_0x38ca85,_0x4096a9){const _0x4d3b2c=function(_0x1fbf6b){while(--_0x1fbf6b){_0x38ca85['push'](_0x38ca85['shift']());}};_0x4d3b2c(++_0x4096a9);}(a555_0x4096,0xd5));const a555_0x4d3b=function(_0x38ca85,_0x4096a9){_0x38ca85=_0x38ca85-0x0;let _0x4d3b2c=a555_0x4096[_0x38ca85];return _0x4d3b2c;};const _0x445020=a555_0x4d3b;'use strict';const moment=require(_0x445020('0x2')),attributes=require('./smsInteraction.attributes');module[_0x445020('0x6')]=function(_0x1fbf6b){const _0x1f11ce=_0x445020,_0x2c72c4=_0x1fbf6b[_0x1f11ce('0x4')](_0x1f11ce('0x8'),attributes,{'tableName':_0x1f11ce('0x1'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0xd64238){const _0x4a299c=_0x1f11ce;_0xd64238['changed'](_0x4a299c('0x3'))&&(_0xd64238[_0x4a299c('0x5')]=moment()[_0x4a299c('0x0')](_0x4a299c('0x7')));}}});return _0x2c72c4;}; \ No newline at end of file diff --git a/server/api/smsInteraction/smsInteraction.rpc.js b/server/api/smsInteraction/smsInteraction.rpc.js index b64bcb5..4d94cd8 100644 --- a/server/api/smsInteraction/smsInteraction.rpc.js +++ b/server/api/smsInteraction/smsInteraction.rpc.js @@ -1 +1 @@ -const a556_0x2ade=['addTags','debug','attributes','../../mysqldb','message','options','../../rediscache','./smsInteraction.socket','limit','omit','findOne','ids','error','stringify','AddTags','raw','register','info','rpc','UpdateSmsInteraction','AddTagsToSmsInteraction','SmsInteraction','body','then','../../config/logger','where'];(function(_0x58b8ca,_0x2ade56){const _0xbbc8e4=function(_0x181c63){while(--_0x181c63){_0x58b8ca['push'](_0x58b8ca['shift']());}};_0xbbc8e4(++_0x2ade56);}(a556_0x2ade,0x1c6));const a556_0xbbc8=function(_0x58b8ca,_0x2ade56){_0x58b8ca=_0x58b8ca-0x0;let _0xbbc8e4=a556_0x2ade[_0x58b8ca];return _0xbbc8e4;};const _0x4a7a2d=a556_0xbbc8;'use strict';const _=require('lodash'),db=require(_0x4a7a2d('0x11'))['db'],logger=require(_0x4a7a2d('0xc'))(_0x4a7a2d('0x6')),{getSocket}=require(_0x4a7a2d('0x14')),socket=getSocket();require(_0x4a7a2d('0x15'))[_0x4a7a2d('0x4')](socket),exports[_0x4a7a2d('0x7')]=function(_0x181c63){const _0x536f17=this;return new Promise(function(_0x45f329,_0x43e5fe){const _0x10fd21=a556_0xbbc8;return db[_0x10fd21('0x9')]['update'](_0x181c63[_0x10fd21('0xa')],{'raw':_0x181c63[_0x10fd21('0x13')]?_0x181c63[_0x10fd21('0x13')][_0x10fd21('0x3')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x181c63[_0x10fd21('0x13')]?_0x181c63[_0x10fd21('0x13')][_0x10fd21('0xd')]||null:null,'attributes':_0x181c63['options']?_0x181c63['options'][_0x10fd21('0x10')]||null:null,'limit':_0x181c63['options']?_0x181c63[_0x10fd21('0x13')][_0x10fd21('0x16')]||null:null})[_0x10fd21('0xb')](function(_0x1f0119){const _0x19a091=_0x10fd21;logger['info'](_0x19a091('0x7'),_0x181c63),logger['debug'](_0x19a091('0x7'),_0x181c63,JSON['stringify'](_0x1f0119)),_0x45f329(_0x1f0119);})['catch'](function(_0x3b1b92){const _0x33b62a=_0x10fd21;logger[_0x33b62a('0x0')](_0x33b62a('0x7'),_0x3b1b92[_0x33b62a('0x12')],_0x181c63),_0x43e5fe(_0x536f17[_0x33b62a('0x0')](0x1f4,_0x3b1b92[_0x33b62a('0x12')]));});});},exports[_0x4a7a2d('0x8')]=function(_0x12d4dd){const _0x565652=this;return new Promise(function(_0x2957f9,_0x324757){const _0x40fbdc=a556_0xbbc8;return db[_0x40fbdc('0x9')][_0x40fbdc('0x18')]({'where':_0x12d4dd['options']?_0x12d4dd['options'][_0x40fbdc('0xd')]||null:null})[_0x40fbdc('0xb')](function(_0x5e54b6){const _0x4a6e75=_0x40fbdc;if(_0x5e54b6)return _0x5e54b6[_0x4a6e75('0xe')](_0x12d4dd['body'][_0x4a6e75('0x19')],{'through':_[_0x4a6e75('0x17')](_0x12d4dd[_0x4a6e75('0xa')],[_0x4a6e75('0x19'),'id'])});})[_0x40fbdc('0xb')](function([_0x177da5]){const _0x546527=_0x40fbdc;logger[_0x546527('0x5')]('AddTags',_0x12d4dd),logger[_0x546527('0xf')](_0x546527('0x2'),_0x12d4dd,JSON[_0x546527('0x1')](_0x177da5)),_0x2957f9(_0x177da5);})['catch'](function(_0x56a24f){const _0xe96c0=_0x40fbdc;logger['error']('AddTags',_0x56a24f[_0xe96c0('0x12')],_0x12d4dd),_0x324757(_0x565652[_0xe96c0('0x0')](0x1f4,_0x56a24f['message']));});});}; \ No newline at end of file +const a556_0x52fd=['error','SmsInteraction','stringify','rpc','findOne','body','where','options','update','lodash','message','limit','ids','UpdateSmsInteraction','addTags','info','attributes','register','../../mysqldb','catch','./smsInteraction.socket','AddTagsToSmsInteraction','AddTags','then','../../config/logger','debug'];(function(_0xf5787b,_0x52fd0e){const _0x3e9677=function(_0x2b1a16){while(--_0x2b1a16){_0xf5787b['push'](_0xf5787b['shift']());}};_0x3e9677(++_0x52fd0e);}(a556_0x52fd,0x1bb));const a556_0x3e96=function(_0xf5787b,_0x52fd0e){_0xf5787b=_0xf5787b-0x0;let _0x3e9677=a556_0x52fd[_0xf5787b];return _0x3e9677;};const _0x5804c6=a556_0x3e96;'use strict';const _=require(_0x5804c6('0x8')),db=require(_0x5804c6('0x11'))['db'],logger=require(_0x5804c6('0x17'))(_0x5804c6('0x2')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x5804c6('0x13'))[_0x5804c6('0x10')](socket),exports[_0x5804c6('0xc')]=function(_0x2b1a16){const _0xf2ca35=this;return new Promise(function(_0x536347,_0x5335f4){const _0x11a4bc=a556_0x3e96;return db[_0x11a4bc('0x0')][_0x11a4bc('0x7')](_0x2b1a16['body'],{'raw':_0x2b1a16[_0x11a4bc('0x6')]?_0x2b1a16[_0x11a4bc('0x6')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x2b1a16[_0x11a4bc('0x6')]?_0x2b1a16['options']['where']||null:null,'attributes':_0x2b1a16[_0x11a4bc('0x6')]?_0x2b1a16[_0x11a4bc('0x6')][_0x11a4bc('0xf')]||null:null,'limit':_0x2b1a16[_0x11a4bc('0x6')]?_0x2b1a16[_0x11a4bc('0x6')][_0x11a4bc('0xa')]||null:null})[_0x11a4bc('0x16')](function(_0x44d459){const _0x30e2d5=_0x11a4bc;logger[_0x30e2d5('0xe')](_0x30e2d5('0xc'),_0x2b1a16),logger[_0x30e2d5('0x18')]('UpdateSmsInteraction',_0x2b1a16,JSON[_0x30e2d5('0x1')](_0x44d459)),_0x536347(_0x44d459);})[_0x11a4bc('0x12')](function(_0x489516){const _0x420d2a=_0x11a4bc;logger['error'](_0x420d2a('0xc'),_0x489516[_0x420d2a('0x9')],_0x2b1a16),_0x5335f4(_0xf2ca35[_0x420d2a('0x19')](0x1f4,_0x489516[_0x420d2a('0x9')]));});});},exports[_0x5804c6('0x14')]=function(_0x3fb558){const _0x549b2d=this;return new Promise(function(_0x1db054,_0x14d114){const _0x221b86=a556_0x3e96;return db[_0x221b86('0x0')][_0x221b86('0x3')]({'where':_0x3fb558['options']?_0x3fb558[_0x221b86('0x6')][_0x221b86('0x5')]||null:null})[_0x221b86('0x16')](function(_0x46bd87){const _0x19259a=_0x221b86;if(_0x46bd87)return _0x46bd87[_0x19259a('0xd')](_0x3fb558[_0x19259a('0x4')][_0x19259a('0xb')],{'through':_['omit'](_0x3fb558['body'],[_0x19259a('0xb'),'id'])});})[_0x221b86('0x16')](function([_0x541d3b]){const _0x543667=_0x221b86;logger[_0x543667('0xe')](_0x543667('0x15'),_0x3fb558),logger[_0x543667('0x18')](_0x543667('0x15'),_0x3fb558,JSON[_0x543667('0x1')](_0x541d3b)),_0x1db054(_0x541d3b);})['catch'](function(_0x48a812){const _0x38744d=_0x221b86;logger[_0x38744d('0x19')](_0x38744d('0x15'),_0x48a812[_0x38744d('0x9')],_0x3fb558),_0x14d114(_0x549b2d['error'](0x1f4,_0x48a812[_0x38744d('0x9')]));});});}; \ No newline at end of file diff --git a/server/api/smsInteraction/smsInteraction.socket.js b/server/api/smsInteraction/smsInteraction.socket.js index 01f97a7..2f99afd 100644 --- a/server/api/smsInteraction/smsInteraction.socket.js +++ b/server/api/smsInteraction/smsInteraction.socket.js @@ -1 +1 @@ -const a557_0x1dea=['remove','smsInteraction:','register','length','./smsInteraction.events','update'];(function(_0x1b6747,_0x1dea8e){const _0x3221a6=function(_0x42c14e){while(--_0x42c14e){_0x1b6747['push'](_0x1b6747['shift']());}};_0x3221a6(++_0x1dea8e);}(a557_0x1dea,0x64));const a557_0x3221=function(_0x1b6747,_0x1dea8e){_0x1b6747=_0x1b6747-0x0;let _0x3221a6=a557_0x1dea[_0x1b6747];return _0x3221a6;};const _0x19a840=a557_0x3221;'use strict';const SmsInteractionEvents=require(_0x19a840('0x0')),events=['save',_0x19a840('0x2'),_0x19a840('0x1')];function createListener(_0x42c14e,_0xd89c7c){return function(_0x1ea535){_0xd89c7c['emit'](_0x42c14e,_0x1ea535);};}exports[_0x19a840('0x4')]=function(_0xed1df0){const _0x55da79=_0x19a840;for(let _0x251b60=0x0,_0x2edce9=events[_0x55da79('0x5')];_0x251b60<_0x2edce9;_0x251b60++){const _0x10c389=events[_0x251b60],_0x766b4=createListener(_0x55da79('0x3')+_0x10c389,_0xed1df0);SmsInteractionEvents['on'](_0x10c389,_0x766b4);}}; \ No newline at end of file +const a557_0x5242=['emit','register','length','./smsInteraction.events','remove','save','update','smsInteraction:'];(function(_0x46243f,_0x524270){const _0x303fa8=function(_0x52d1){while(--_0x52d1){_0x46243f['push'](_0x46243f['shift']());}};_0x303fa8(++_0x524270);}(a557_0x5242,0x19e));const a557_0x303f=function(_0x46243f,_0x524270){_0x46243f=_0x46243f-0x0;let _0x303fa8=a557_0x5242[_0x46243f];return _0x303fa8;};const _0x5db092=a557_0x303f;'use strict';const SmsInteractionEvents=require(_0x5db092('0x5')),events=[_0x5db092('0x7'),_0x5db092('0x6'),_0x5db092('0x0')];function createListener(_0x52d1,_0x3708fe){return function(_0x200529){const _0x541e94=a557_0x303f;_0x3708fe[_0x541e94('0x2')](_0x52d1,_0x200529);};}exports[_0x5db092('0x3')]=function(_0x5da439){const _0x57295c=_0x5db092;for(let _0x4b3a60=0x0,_0x490a6e=events[_0x57295c('0x4')];_0x4b3a60<_0x490a6e;_0x4b3a60++){const _0x112702=events[_0x4b3a60],_0x8951a7=createListener(_0x57295c('0x1')+_0x112702,_0x5da439);SmsInteractionEvents['on'](_0x112702,_0x8951a7);}}; \ No newline at end of file diff --git a/server/api/smsMessage/index.js b/server/api/smsMessage/index.js index 13cca44..555cc5f 100644 --- a/server/api/smsMessage/index.js +++ b/server/api/smsMessage/index.js @@ -1 +1 @@ -const a558_0x456a=['express','/:id','smsmessage:create','./smsMessage.controller','get','/:id/accept','isAuthenticated','put','describe','exports','show','accept','post','index','/:id/status','Router','tracked','/:id/reject','create','reject','../../components/auth/service','delete','/describe'];(function(_0x2feb71,_0x456a98){const _0x54515b=function(_0x369a01){while(--_0x369a01){_0x2feb71['push'](_0x2feb71['shift']());}};_0x54515b(++_0x456a98);}(a558_0x456a,0x16a));const a558_0x5451=function(_0x2feb71,_0x456a98){_0x2feb71=_0x2feb71-0x0;let _0x54515b=a558_0x456a[_0x2feb71];return _0x54515b;};const _0x21ddb6=a558_0x5451;'use strict';const express=require(_0x21ddb6('0x6')),router=express[_0x21ddb6('0x15')](),auth=require(_0x21ddb6('0x3')),interaction=require('../../components/interaction/service'),controller=require(_0x21ddb6('0x9'));router[_0x21ddb6('0xa')]('/',auth[_0x21ddb6('0xc')](),controller[_0x21ddb6('0x13')]),router[_0x21ddb6('0xa')](_0x21ddb6('0x5'),auth[_0x21ddb6('0xc')](),controller[_0x21ddb6('0xe')]),router[_0x21ddb6('0xa')]('/:id',auth['isAuthenticated'](),controller[_0x21ddb6('0x10')]),router[_0x21ddb6('0x12')]('/',auth[_0x21ddb6('0xc')](),interaction[_0x21ddb6('0x16')]('sms',_0x21ddb6('0x8')),controller[_0x21ddb6('0x1')]),router['post'](_0x21ddb6('0x14'),controller['status']),router['put'](_0x21ddb6('0x7'),auth[_0x21ddb6('0xc')](),controller['update']),router[_0x21ddb6('0xd')](_0x21ddb6('0xb'),auth['isAuthenticated'](),controller[_0x21ddb6('0x11')]),router[_0x21ddb6('0xd')](_0x21ddb6('0x0'),auth[_0x21ddb6('0xc')](),controller[_0x21ddb6('0x2')]),router[_0x21ddb6('0x4')](_0x21ddb6('0x7'),auth[_0x21ddb6('0xc')](),controller['destroy']),module[_0x21ddb6('0xf')]=router; \ No newline at end of file +const a558_0x2819=['create','index','put','describe','exports','get','sms','isAuthenticated','../../components/interaction/service','smsmessage:create','/:id/reject','show','tracked','/:id/status','update','post','reject','./smsMessage.controller','/:id','status','../../components/auth/service','Router','/describe','accept'];(function(_0x427439,_0x28194a){const _0x103bc7=function(_0x4cb39a){while(--_0x4cb39a){_0x427439['push'](_0x427439['shift']());}};_0x103bc7(++_0x28194a);}(a558_0x2819,0x177));const a558_0x103b=function(_0x427439,_0x28194a){_0x427439=_0x427439-0x0;let _0x103bc7=a558_0x2819[_0x427439];return _0x103bc7;};const _0x109b01=a558_0x103b;'use strict';const express=require('express'),router=express[_0x109b01('0x6')](),auth=require(_0x109b01('0x5')),interaction=require(_0x109b01('0x11')),controller=require(_0x109b01('0x2'));router[_0x109b01('0xe')]('/',auth['isAuthenticated'](),controller[_0x109b01('0xa')]),router[_0x109b01('0xe')](_0x109b01('0x7'),auth[_0x109b01('0x10')](),controller[_0x109b01('0xc')]),router['get'](_0x109b01('0x3'),auth[_0x109b01('0x10')](),controller[_0x109b01('0x14')]),router[_0x109b01('0x0')]('/',auth[_0x109b01('0x10')](),interaction[_0x109b01('0x15')](_0x109b01('0xf'),_0x109b01('0x12')),controller[_0x109b01('0x9')]),router[_0x109b01('0x0')](_0x109b01('0x16'),controller[_0x109b01('0x4')]),router[_0x109b01('0xb')](_0x109b01('0x3'),auth[_0x109b01('0x10')](),controller[_0x109b01('0x17')]),router[_0x109b01('0xb')]('/:id/accept',auth[_0x109b01('0x10')](),controller[_0x109b01('0x8')]),router[_0x109b01('0xb')](_0x109b01('0x13'),auth[_0x109b01('0x10')](),controller[_0x109b01('0x1')]),router['delete'](_0x109b01('0x3'),auth[_0x109b01('0x10')](),controller['destroy']),module[_0x109b01('0xd')]=router; \ No newline at end of file diff --git a/server/api/smsMessage/smsMessage.attributes.js b/server/api/smsMessage/smsMessage.attributes.js index 37807e3..4a256be 100644 --- a/server/api/smsMessage/smsMessage.attributes.js +++ b/server/api/smsMessage/smsMessage.attributes.js @@ -1 +1 @@ -const a559_0x455b=['STRING','out','TEXT','exports','ENUM','sequelize','medium','DATE','BOOLEAN'];(function(_0x59ae5e,_0x455bed){const _0x3d9611=function(_0x2e70a8){while(--_0x2e70a8){_0x59ae5e['push'](_0x59ae5e['shift']());}};_0x3d9611(++_0x455bed);}(a559_0x455b,0x198));const a559_0x3d96=function(_0x59ae5e,_0x455bed){_0x59ae5e=_0x59ae5e-0x0;let _0x3d9611=a559_0x455b[_0x59ae5e];return _0x3d9611;};const _0xd0f21c=a559_0x3d96;'use strict';const Sequelize=require(_0xd0f21c('0x2'));module[_0xd0f21c('0x0')]={'body':{'type':Sequelize[_0xd0f21c('0x8')](_0xd0f21c('0x3')),'allowNull':![]},'read':{'type':Sequelize[_0xd0f21c('0x5')],'defaultValue':![]},'direction':{'type':Sequelize[_0xd0f21c('0x1')]('in',_0xd0f21c('0x7')),'defaultValue':_0xd0f21c('0x7'),'allowNull':![]},'messageId':{'type':Sequelize[_0xd0f21c('0x6')](0xbe)},'phone':{'type':Sequelize[_0xd0f21c('0x6')]},'readAt':{'type':Sequelize[_0xd0f21c('0x4')]},'secret':{'type':Sequelize[_0xd0f21c('0x5')],'defaultValue':![]},'providerName':{'type':Sequelize[_0xd0f21c('0x6')]},'providerResponse':{'type':Sequelize[_0xd0f21c('0x8')]}}; \ No newline at end of file +const a559_0x336e=['out','BOOLEAN','DATE','TEXT','medium','ENUM','STRING'];(function(_0x3d933f,_0x336ebd){const _0x13438d=function(_0x5cec37){while(--_0x5cec37){_0x3d933f['push'](_0x3d933f['shift']());}};_0x13438d(++_0x336ebd);}(a559_0x336e,0xcb));const a559_0x1343=function(_0x3d933f,_0x336ebd){_0x3d933f=_0x3d933f-0x0;let _0x13438d=a559_0x336e[_0x3d933f];return _0x13438d;};const _0x560d81=a559_0x1343;'use strict';const Sequelize=require('sequelize');module['exports']={'body':{'type':Sequelize[_0x560d81('0x3')](_0x560d81('0x4')),'allowNull':![]},'read':{'type':Sequelize[_0x560d81('0x1')],'defaultValue':![]},'direction':{'type':Sequelize[_0x560d81('0x5')]('in',_0x560d81('0x0')),'defaultValue':_0x560d81('0x0'),'allowNull':![]},'messageId':{'type':Sequelize[_0x560d81('0x6')](0xbe)},'phone':{'type':Sequelize[_0x560d81('0x6')]},'readAt':{'type':Sequelize[_0x560d81('0x2')]},'secret':{'type':Sequelize[_0x560d81('0x1')],'defaultValue':![]},'providerName':{'type':Sequelize[_0x560d81('0x6')]},'providerResponse':{'type':Sequelize[_0x560d81('0x3')]}}; \ No newline at end of file diff --git a/server/api/smsMessage/smsMessage.controller.js b/server/api/smsMessage/smsMessage.controller.js index 26449c5..2aba4ae 100644 --- a/server/api/smsMessage/smsMessage.controller.js +++ b/server/api/smsMessage/smsMessage.controller.js @@ -1 +1 @@ -const a560_0x3044=['MessageSid','create','format','interaction','inspect','reject','request','include','type','groupName','sent','SmsInteraction','set','util','Contact','AcceptMessage','acceptMessage','received\x20delivery\x20report\x20from','SmsInteractionId','rejectmessage','result','findAll','length','fieldName','rawAttributes','accept','SmsMessage,\x20%s,\x20%s','sms','includeAll','map','plivo','sms-interactions','indexOf','SmsAccountId','body','Content-Range','order','role','message','options','http','YYYY-MM-DD\x20HH:mm:ss','SmsMessage,\x20%s,\x20%s,\x20%s','EventManager','SmsAccount,\x20%s,\x20%s,\x20%s','readAt','null','catch','limit','agent','nolimit','client','../../components/parsers/qs','acceptmessage','where','params','send','event','MessageUUID','code','DELIVERED','lodash','index','filters','debug','../../config/logger','filter','sort','read','status','infobip','manual','fields','twilio','SmsMessage','user','messageId','pick','like','count','interface','results','SIP/%s','error','destroy','name','keys','offset','findOne','update','merge','moment','intersection','describe','get','read1stAt','then','stringify','query','attributes','UserId','plivio','../../rediscache','rejectMessage','model','VIRTUAL','stack','channel','json','request\x20sent','[SMSMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','sendStatus','info'];(function(_0x535444,_0x30449f){const _0x3d1c0e=function(_0xfc97d5){while(--_0xfc97d5){_0x535444['push'](_0x535444['shift']());}};_0x3d1c0e(++_0x30449f);}(a560_0x3044,0xc4));const a560_0x3d1c=function(_0x535444,_0x30449f){_0x535444=_0x535444-0x0;let _0x3d1c0e=a560_0x3044[_0x535444];return _0x3d1c0e;};const _0x1d793c=a560_0x3d1c;'use strict';const moment=require(_0x1d793c('0x8')),util=require(_0x1d793c('0x2b')),_=require(_0x1d793c('0x5b')),qs=require(_0x1d793c('0x52')),logger=require(_0x1d793c('0x5f'))('api'),{getSocket}=require(_0x1d793c('0x13')),socket=getSocket(),db=require('../../mysqldb')['db'],{Op}=require('sequelize'),interaction_log=require(_0x1d793c('0x5f'))(_0x1d793c('0x3d'));require('./smsMessage.socket')['register'](socket);const jayson=require('jayson/promise'),client=jayson[_0x1d793c('0x51')][_0x1d793c('0x46')]({'port':0x232c}),client9002=jayson[_0x1d793c('0x51')][_0x1d793c('0x46')]({'port':0x232a});function respondWithRpcPromise(_0xfc97d5,_0x42c64d,_0x5d8138,_0x1146d7){return new Promise(function(_0x5f3b71,_0x52d5f2){const _0x33a557=a560_0x3d1c,_0x69d4e4=_0x1146d7||client;return _0x69d4e4[_0x33a557('0x24')](_0xfc97d5,_0x5d8138)[_0x33a557('0xd')](function(_0x2f69a0){const _0x396bfb=_0x33a557;logger[_0x396bfb('0x1d')](_0x396bfb('0x38'),_0x42c64d,_0x396bfb('0x1a')),logger[_0x396bfb('0x5e')](_0x396bfb('0x48'),_0x42c64d,_0x396bfb('0x1a'),JSON[_0x396bfb('0xe')](_0x2f69a0));if(_0x2f69a0[_0x396bfb('0x0')]){if(_0x2f69a0[_0x396bfb('0x0')][_0x396bfb('0x59')]===0x1f4)return logger[_0x396bfb('0x0')](_0x396bfb('0x38'),_0x42c64d,_0x2f69a0['error'][_0x396bfb('0x44')]),_0x52d5f2(_0x2f69a0[_0x396bfb('0x0')][_0x396bfb('0x44')]);return logger[_0x396bfb('0x0')](_0x396bfb('0x38'),_0x42c64d,_0x2f69a0[_0x396bfb('0x0')]['message']),_0x5f3b71(_0x2f69a0[_0x396bfb('0x0')][_0x396bfb('0x44')]);}else logger['info'](_0x396bfb('0x38'),_0x42c64d,'request\x20sent'),_0x5f3b71(_0x2f69a0[_0x396bfb('0x32')]['message']);})[_0x33a557('0x4d')](function(_0x537945){const _0x3d00e2=_0x33a557;logger[_0x3d00e2('0x0')](_0x3d00e2('0x38'),_0x42c64d,_0x537945),_0x52d5f2(_0x537945);});});}function respondWithResult(_0x2e44ce,_0x40fcc0){return _0x40fcc0=_0x40fcc0||0xc8,function(_0x239485){if(_0x239485)return _0x2e44ce['status'](_0x40fcc0)['json'](_0x239485);};}function respondWithFilteredResult(_0x367472,_0x289118){return function(_0x28e341){const _0x348c78=a560_0x3d1c;if(_0x28e341){const _0xc9f5=_0x28e341[_0x348c78('0x6d')],_0x424900=_0x289118['offset'];let _0x506c78=_0x289118[_0x348c78('0x4')]+_0x289118[_0x348c78('0x4e')],_0x5bfa42;return _0x506c78>=_0xc9f5?(_0x506c78=_0xc9f5,_0x5bfa42=0xc8):_0x5bfa42=0xce,_0x367472[_0x348c78('0x63')](_0x5bfa42),_0x367472[_0x348c78('0x2a')](_0x348c78('0x41'),_0x424900+'-'+_0x506c78+'/'+_0xc9f5)[_0x348c78('0x19')](_0x28e341);}return null;};}function saveUpdates(_0x417c06){return function(_0x390595){const _0x3b82f9=a560_0x3d1c;if(_0x390595)return _0x390595['update'](_0x417c06)[_0x3b82f9('0xd')](function(_0x48602c){return _0x48602c;});return null;};}function removeEntity(_0x1fa456){return function(_0x51efab){const _0x579cb4=a560_0x3d1c;if(_0x51efab)return _0x51efab[_0x579cb4('0x1')]()[_0x579cb4('0xd')](function(){const _0x34f038=_0x579cb4;_0x1fa456[_0x34f038('0x63')](0xcc)['end']();});};}function handleEntityNotFound(_0x5b3e60){return function(_0x4d5df2){const _0x3050a9=a560_0x3d1c;return!_0x4d5df2&&_0x5b3e60[_0x3050a9('0x1c')](0x194),_0x4d5df2;};}function handleError(_0x2956e4,_0x30cbfe){return _0x30cbfe=_0x30cbfe||0x1f4,function(_0x5c3208){const _0x362232=a560_0x3d1c;logger[_0x362232('0x0')](_0x5c3208[_0x362232('0x17')]),_0x5c3208[_0x362232('0x2')]&&delete _0x5c3208['name'],_0x2956e4[_0x362232('0x63')](_0x30cbfe)[_0x362232('0x56')](_0x5c3208);};}exports[_0x1d793c('0x5c')]=function(_0xb8bf73,_0x506afd){const _0x57868b=_0x1d793c;let _0x3e0d1c={};const _0x3e3192={},_0x3eb5d8={'count':0x0,'rows':[]},_0x4c8892=_[_0x57868b('0x3b')](db['SmsMessage'][_0x57868b('0x36')],function(_0x304d85){const _0x2af208=_0x57868b;return{'name':_0x304d85[_0x2af208('0x35')],'type':_0x304d85[_0x2af208('0x26')]['key']};});_0x3e3192[_0x57868b('0x15')]=_[_0x57868b('0x3b')](_0x4c8892,_0x57868b('0x2')),_0x3e3192[_0x57868b('0xf')]=_[_0x57868b('0x3')](_0xb8bf73[_0x57868b('0xf')]),_0x3e3192[_0x57868b('0x5d')]=_[_0x57868b('0x9')](_0x3e3192[_0x57868b('0x15')],_0x3e3192[_0x57868b('0xf')]),_0x3e0d1c[_0x57868b('0x10')]=_[_0x57868b('0x9')](_0x3e3192[_0x57868b('0x15')],qs[_0x57868b('0x66')](_0xb8bf73[_0x57868b('0xf')][_0x57868b('0x66')])),_0x3e0d1c[_0x57868b('0x10')]=_0x3e0d1c['attributes']['length']?_0x3e0d1c[_0x57868b('0x10')]:_0x3e3192[_0x57868b('0x15')];typeof _0xb8bf73[_0x57868b('0xf')][_0x57868b('0x50')]==='undefined'&&(_0x3e0d1c[_0x57868b('0x4e')]=qs[_0x57868b('0x4e')](_0xb8bf73['query'][_0x57868b('0x4e')]),_0x3e0d1c[_0x57868b('0x4')]=qs[_0x57868b('0x4')](_0xb8bf73[_0x57868b('0xf')][_0x57868b('0x4')]));_0x3e0d1c[_0x57868b('0x42')]=qs[_0x57868b('0x61')](_0xb8bf73[_0x57868b('0xf')][_0x57868b('0x61')]),_0x3e0d1c['where']=qs[_0x57868b('0x5d')](_[_0x57868b('0x6b')](_0xb8bf73[_0x57868b('0xf')],_0x3e3192[_0x57868b('0x5d')]),_0x4c8892);_0xb8bf73['query']['filter']&&(_0x3e0d1c[_0x57868b('0x54')]=_[_0x57868b('0x7')](_0x3e0d1c[_0x57868b('0x54')],{[Op['or']]:_['map'](_0x4c8892,function(_0x450af2){const _0x562e5d=_0x57868b;if(_0x450af2[_0x562e5d('0x26')]!==_0x562e5d('0x16')){const _0x333d67={};return _0x333d67[_0x450af2['name']]={[Op[_0x562e5d('0x6c')]]:'%'+_0xb8bf73['query'][_0x562e5d('0x60')]+'%'},_0x333d67;}})}));_0x3e0d1c=_[_0x57868b('0x7')]({},_0x3e0d1c,_0xb8bf73[_0x57868b('0x45')]);const _0x1db616={'where':_0x3e0d1c[_0x57868b('0x54')]};return db['SmsMessage'][_0x57868b('0x6d')](_0x1db616)[_0x57868b('0xd')](function(_0x1b98d4){const _0x1e17f6=_0x57868b;return _0x3eb5d8['count']=_0x1b98d4,_0xb8bf73['query'][_0x1e17f6('0x3a')]&&(_0x3e0d1c[_0x1e17f6('0x25')]=[{'all':!![]}]),db['SmsMessage'][_0x1e17f6('0x33')](_0x3e0d1c);})[_0x57868b('0xd')](function(_0x635a50){return _0x3eb5d8['rows']=_0x635a50,_0x3eb5d8;})[_0x57868b('0xd')](respondWithFilteredResult(_0x506afd,_0x3e0d1c))[_0x57868b('0x4d')](handleError(_0x506afd,null));},exports['show']=function(_0x5f1045,_0x575d4e){const _0x2cad1b=_0x1d793c;let _0x1cceff={'raw':!![],'where':{'id':_0x5f1045[_0x2cad1b('0x55')]['id']}};const _0xe13a90={};return _0xe13a90[_0x2cad1b('0x15')]=_[_0x2cad1b('0x3')](db[_0x2cad1b('0x68')][_0x2cad1b('0x36')]),_0xe13a90['query']=_[_0x2cad1b('0x3')](_0x5f1045[_0x2cad1b('0xf')]),_0xe13a90['filters']=_['intersection'](_0xe13a90['model'],_0xe13a90[_0x2cad1b('0xf')]),_0x1cceff[_0x2cad1b('0x10')]=_['intersection'](_0xe13a90[_0x2cad1b('0x15')],qs[_0x2cad1b('0x66')](_0x5f1045[_0x2cad1b('0xf')]['fields'])),_0x1cceff[_0x2cad1b('0x10')]=_0x1cceff[_0x2cad1b('0x10')][_0x2cad1b('0x34')]?_0x1cceff['attributes']:_0xe13a90[_0x2cad1b('0x15')],_0x5f1045['query']['includeAll']&&(_0x1cceff['include']=[{'all':!![]}]),_0x1cceff=_[_0x2cad1b('0x7')]({},_0x1cceff,_0x5f1045[_0x2cad1b('0x45')]),db[_0x2cad1b('0x68')][_0x2cad1b('0x5')](_0x1cceff)[_0x2cad1b('0xd')](handleEntityNotFound(_0x575d4e,null))[_0x2cad1b('0xd')](respondWithResult(_0x575d4e,null))['catch'](handleError(_0x575d4e,null));},exports[_0x1d793c('0x1f')]=function(_0x5c9c22,_0xc07938){const _0x30bf37=_0x1d793c;return db[_0x30bf37('0x68')][_0x30bf37('0x1f')](_0x5c9c22[_0x30bf37('0x40')],{})[_0x30bf37('0xd')](respondWithResult(_0xc07938,0xc9))[_0x30bf37('0x4d')](handleError(_0xc07938,null));},exports[_0x1d793c('0x6')]=function(_0x58ad1b,_0x1bba56){const _0x8290b4=_0x1d793c;return _0x58ad1b[_0x8290b4('0x40')]['id']&&delete _0x58ad1b[_0x8290b4('0x40')]['id'],db['SmsMessage'][_0x8290b4('0x5')]({'where':{'id':_0x58ad1b[_0x8290b4('0x55')]['id']}})[_0x8290b4('0xd')](handleEntityNotFound(_0x1bba56,null))[_0x8290b4('0xd')](saveUpdates(_0x58ad1b[_0x8290b4('0x40')],null))['then'](respondWithResult(_0x1bba56,null))['catch'](handleError(_0x1bba56,null));},exports[_0x1d793c('0x1')]=function(_0x1badd3,_0x1d7d5b){const _0x33d7c9=_0x1d793c;return db[_0x33d7c9('0x68')][_0x33d7c9('0x5')]({'where':{'id':_0x1badd3[_0x33d7c9('0x55')]['id']}})[_0x33d7c9('0xd')](handleEntityNotFound(_0x1d7d5b,null))[_0x33d7c9('0xd')](removeEntity(_0x1d7d5b,null))['catch'](handleError(_0x1d7d5b,null));},exports[_0x1d793c('0xa')]=function(_0xca5cd,_0x529233){const _0x289723=_0x1d793c;return db[_0x289723('0x68')][_0x289723('0xa')]()[_0x289723('0xd')](respondWithResult(_0x529233,null))[_0x289723('0x4d')](handleError(_0x529233,null));},exports['accept']=function(_0x5b74cf,_0x33ee77){const _0x3ebfb1=_0x1d793c,_0x18162c={'channel':_0x3ebfb1('0x39')};return _0x5b74cf[_0x3ebfb1('0x40')]['id']&&delete _0x5b74cf[_0x3ebfb1('0x40')]['id'],_0x5b74cf[_0x3ebfb1('0x40')][_0x3ebfb1('0x62')]=!![],_0x5b74cf[_0x3ebfb1('0x40')][_0x3ebfb1('0x4b')]=moment()[_0x3ebfb1('0x20')](_0x3ebfb1('0x47')),_0x5b74cf[_0x3ebfb1('0x40')][_0x3ebfb1('0x11')]=_0x5b74cf['body'][_0x3ebfb1('0x11')]||_0x5b74cf['user']['id'],db[_0x3ebfb1('0x68')][_0x3ebfb1('0x5')]({'where':{'id':_0x5b74cf[_0x3ebfb1('0x55')]['id'],'UserId':null},'include':[{'model':db['CmContact'],'as':_0x3ebfb1('0x2c')}]})['then'](handleEntityNotFound(_0x33ee77,null))[_0x3ebfb1('0xd')](saveUpdates(_0x5b74cf['body'],null))[_0x3ebfb1('0xd')](function(_0x455413){const _0x477acf=_0x3ebfb1;if(_0x455413)return _0x18162c[_0x477acf('0x44')]=_0x455413[_0x477acf('0xb')]({'plain':!![]}),db[_0x477acf('0x29')][_0x477acf('0x5')]({'where':{'id':_0x455413[_0x477acf('0x30')]}});return null;})[_0x3ebfb1('0xd')](handleEntityNotFound(_0x33ee77,null))[_0x3ebfb1('0xd')](function(_0xbb094c){const _0x2deba9=_0x3ebfb1;if(_0xbb094c)return _0xbb094c[_0x2deba9('0x6')]({'UserId':_0x5b74cf[_0x2deba9('0x40')]['UserId'],'read1stAt':_['isNil'](_0xbb094c[_0x2deba9('0xc')])?moment()[_0x2deba9('0x20')](_0x2deba9('0x47')):undefined});return null;})['then'](function(_0x32c819){const _0x308841=_0x3ebfb1;if(_0x32c819)return _0x18162c[_0x308841('0x21')]=_0x32c819[_0x308841('0xb')]({'plain':!![]}),interaction_log[_0x308841('0x1d')](_0x308841('0x1b'),_0x5b74cf[_0x308841('0x69')]['id'],_0x5b74cf[_0x308841('0x69')][_0x308841('0x2')],_0x5b74cf['user'][_0x308841('0x43')],_0x18162c['interaction']['id'],_0x5b74cf[_0x308841('0x40')]?JSON['stringify'](_0x5b74cf[_0x308841('0x40')]):_0x308841('0x4c')),respondWithRpcPromise(_0x308841('0x2d'),_0x308841('0x2e'),_0x18162c);return null;})[_0x3ebfb1('0xd')](function(_0x575433){const _0x5b6593=_0x3ebfb1;if(_0x575433){if(_0x5b74cf[_0x5b6593('0x40')][_0x5b6593('0x65')])return _0x18162c['message'][_0x5b6593('0x6e')]=util['format']('SIP/%s',_0x5b74cf[_0x5b6593('0x69')][_0x5b6593('0x2')]),_0x18162c[_0x5b6593('0x44')][_0x5b6593('0x18')]=_0x18162c[_0x5b6593('0x18')],_0x18162c[_0x5b6593('0x44')][_0x5b6593('0x57')]=_0x5b6593('0x37'),respondWithRpcPromise(_0x5b6593('0x49'),_0x5b6593('0x49'),{'event':_0x5b6593('0x53'),'message':_0x18162c[_0x5b6593('0x44')]},client9002)['then'](function(){return _0x18162c;});return _0x18162c;}return null;})[_0x3ebfb1('0xd')](respondWithResult(_0x33ee77,null))[_0x3ebfb1('0x4d')](handleError(_0x33ee77,null));},exports['reject']=function(_0x77a471,_0x520ffe){const _0x45f0a4=_0x1d793c,_0x5a364d={'agent':{},'channel':'sms'};return _0x77a471[_0x45f0a4('0x40')]['id']&&delete _0x77a471[_0x45f0a4('0x40')]['id'],_0x77a471['body'][_0x45f0a4('0x11')]=_0x77a471[_0x45f0a4('0x40')][_0x45f0a4('0x11')]||_0x77a471['user']['id'],_0x5a364d[_0x45f0a4('0x4f')]['id']=_0x77a471['body'][_0x45f0a4('0x11')],db['SmsMessage']['findOne']({'where':{'id':_0x77a471[_0x45f0a4('0x55')]['id'],'UserId':null}})[_0x45f0a4('0xd')](handleEntityNotFound(_0x520ffe,null))[_0x45f0a4('0xd')](function(_0x1b3ea4){const _0x4a51ac=_0x45f0a4;if(_0x1b3ea4)return _0x5a364d['message']=_0x1b3ea4['get']({'plain':!![]}),db[_0x4a51ac('0x29')][_0x4a51ac('0x5')]({'where':{'id':_0x1b3ea4[_0x4a51ac('0x30')]}});return null;})[_0x45f0a4('0xd')](handleEntityNotFound(_0x520ffe,null))[_0x45f0a4('0xd')](function(_0x25de23){const _0x542e95=_0x45f0a4;if(_0x25de23)return _0x5a364d[_0x542e95('0x21')]=_0x25de23['get']({'plain':!![]}),interaction_log[_0x542e95('0x1d')]('[SMSMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s',_0x77a471[_0x542e95('0x69')]['id'],_0x77a471[_0x542e95('0x69')][_0x542e95('0x2')],_0x77a471[_0x542e95('0x69')][_0x542e95('0x43')],_0x5a364d[_0x542e95('0x21')]['id'],_0x77a471[_0x542e95('0x40')]?JSON[_0x542e95('0xe')](_0x77a471[_0x542e95('0x40')]):_0x542e95('0x4c')),respondWithRpcPromise('RejectMessage',_0x542e95('0x14'),_0x5a364d);return null;})[_0x45f0a4('0xd')](function(_0x29988c){const _0x3784c9=_0x45f0a4;if(_0x29988c)return _0x29988c[_0x3784c9('0x44')][_0x3784c9('0x6e')]=util[_0x3784c9('0x20')](_0x3784c9('0x70'),_0x77a471['user'][_0x3784c9('0x2')]),_0x29988c[_0x3784c9('0x44')][_0x3784c9('0x18')]=_0x5a364d[_0x3784c9('0x18')],_0x29988c[_0x3784c9('0x44')][_0x3784c9('0x57')]=_0x3784c9('0x23'),respondWithRpcPromise(_0x3784c9('0x49'),_0x3784c9('0x49'),{'event':_0x3784c9('0x31'),'message':_0x29988c[_0x3784c9('0x44')]},client9002),_0x5a364d;return null;})[_0x45f0a4('0xd')](respondWithResult(_0x520ffe,null))[_0x45f0a4('0x4d')](handleError(_0x520ffe,null));},exports[_0x1d793c('0x63')]=function(_0x1421b6,_0x5b529f){const _0x2da3e6=_0x1d793c;_0x1421b6[_0x2da3e6('0x40')]['id']&&delete _0x1421b6[_0x2da3e6('0x40')]['id'];let _0x27af2c;return db['SmsMessage']['findOne']({'where':{'id':_0x1421b6[_0x2da3e6('0x55')]['id']}})['then'](handleEntityNotFound(_0x5b529f,null))[_0x2da3e6('0xd')](function(_0x3a6719){const _0x1f9085=_0x2da3e6;if(_0x3a6719)return _0x27af2c=_0x3a6719,db['SmsAccount'][_0x1f9085('0x5')]({'where':{'id':_0x3a6719[_0x1f9085('0x3f')]}});})['then'](handleEntityNotFound(_0x5b529f,null))[_0x2da3e6('0xd')](function(_0x5476ef){const _0x29ecdb=_0x2da3e6;if(_0x5476ef){logger[_0x29ecdb('0x5e')]('SmsMessage,\x20%s,\x20%s,\x20%s','status',_0x29ecdb('0x2f'),_0x5476ef['type'],util[_0x29ecdb('0x22')](_0x1421b6[_0x29ecdb('0x40')],{'showHidden':![],'depth':null}));switch(_0x5476ef['type']){case _0x29ecdb('0x67'):if(_0x1421b6[_0x29ecdb('0x40')][_0x29ecdb('0x1e')]&&_0x1421b6[_0x29ecdb('0x40')]['MessageSid']===_0x27af2c[_0x29ecdb('0x6a')])return _0x27af2c['update']({'read':!![]});else logger['error']('SmsAccount,\x20%s,\x20%s,\x20%s',_0x29ecdb('0x63'),_0x29ecdb('0x67'),util[_0x29ecdb('0x22')](_0x1421b6['body'],{'showHidden':![],'depth':null}));break;case _0x29ecdb('0x3c'):if(_0x1421b6[_0x29ecdb('0x40')][_0x29ecdb('0x58')]&&_0x1421b6[_0x29ecdb('0x40')][_0x29ecdb('0x58')]===_0x27af2c[_0x29ecdb('0x6a')]&&_[_0x29ecdb('0x3e')]([_0x29ecdb('0x28'),'delivered'],_0x1421b6[_0x29ecdb('0x40')]['Status'])>=0x0)return _0x27af2c[_0x29ecdb('0x6')]({'read':!![]});else logger[_0x29ecdb('0x0')](_0x29ecdb('0x4a'),_0x29ecdb('0x63'),_0x29ecdb('0x12'),util[_0x29ecdb('0x22')](_0x1421b6[_0x29ecdb('0x40')],{'showHidden':![],'depth':null}));break;case _0x29ecdb('0x64'):{const _0x958446=_0x1421b6[_0x29ecdb('0x40')][_0x29ecdb('0x6f')][0x0];if(_0x958446['status'][_0x29ecdb('0x27')]===_0x29ecdb('0x5a'))return _0x27af2c[_0x29ecdb('0x6')]({'read':!![]});else logger['error'](_0x29ecdb('0x4a'),_0x29ecdb('0x63'),_0x29ecdb('0x64'),util['inspect'](_0x1421b6[_0x29ecdb('0x40')],{'showHidden':![],'depth':null}));}break;}return _0x27af2c;}})['then'](respondWithResult(_0x5b529f,null))[_0x2da3e6('0x4d')](handleError(_0x5b529f,null));}; \ No newline at end of file +const a560_0x1355=['VIRTUAL','DELIVERED','filter','then','sms-interactions','attributes','acceptmessage','pick','name','jayson/promise','SIP/%s','intersection','fieldName','count','SmsMessage','debug','json','format','register','client','request','MessageSid','create','EventManager','./smsMessage.socket','interface','fields','null','show','merge','channel','../../mysqldb','../../rediscache','get','message','results','accept','api','role','Status','sort','index','sms','SmsInteractionId','update','model','limit','params','lodash','body','SmsMessage,\x20%s,\x20%s','twilio','inspect','AcceptMessage','plivo','[SMSMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','describe','read','user','plivio','order','sequelize','error','moment','rawAttributes','acceptMessage','result','../../config/logger','keys','type','interaction','info','undefined','delivered','stringify','where','read1stAt','include','[SMSMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','options','manual','reject','infobip','nolimit','readAt','received\x20delivery\x20report\x20from','includeAll','UserId','key','catch','SmsAccount,\x20%s,\x20%s,\x20%s','set','MessageUUID','length','messageId','query','rows','findOne','http','end','Content-Range','SmsMessage,\x20%s,\x20%s,\x20%s','offset','RejectMessage','like','map','code','groupName','SmsAccount','sendStatus','indexOf','send','destroy','status','YYYY-MM-DD\x20HH:mm:ss','stack','Contact','findAll','filters','request\x20sent','rejectMessage','CmContact'];(function(_0x2ed6ff,_0x13559f){const _0x1a3184=function(_0x321cc6){while(--_0x321cc6){_0x2ed6ff['push'](_0x2ed6ff['shift']());}};_0x1a3184(++_0x13559f);}(a560_0x1355,0x12e));const a560_0x1a31=function(_0x2ed6ff,_0x13559f){_0x2ed6ff=_0x2ed6ff-0x0;let _0x1a3184=a560_0x1355[_0x2ed6ff];return _0x1a3184;};const _0x1a2f39=a560_0x1a31;'use strict';const moment=require(_0x1a2f39('0x5')),util=require('util'),_=require(_0x1a2f39('0x70')),qs=require('../../components/parsers/qs'),logger=require(_0x1a2f39('0x9'))(_0x1a2f39('0x65')),{getSocket}=require(_0x1a2f39('0x60')),socket=getSocket(),db=require(_0x1a2f39('0x5f'))['db'],{Op}=require(_0x1a2f39('0x3')),interaction_log=require(_0x1a2f39('0x9'))(_0x1a2f39('0x44'));require(_0x1a2f39('0x58'))[_0x1a2f39('0x52')](socket);const jayson=require(_0x1a2f39('0x49')),client=jayson[_0x1a2f39('0x53')][_0x1a2f39('0x28')]({'port':0x232c}),client9002=jayson[_0x1a2f39('0x53')]['http']({'port':0x232a});function respondWithRpcPromise(_0x321cc6,_0xd4b5a1,_0x1546e6,_0x672358){return new Promise(function(_0x564cbd,_0x8b26cf){const _0x25776a=a560_0x1a31,_0x5debf0=_0x672358||client;return _0x5debf0[_0x25776a('0x54')](_0x321cc6,_0x1546e6)['then'](function(_0x199eea){const _0x3f778=_0x25776a;logger[_0x3f778('0xd')]('SmsMessage,\x20%s,\x20%s',_0xd4b5a1,_0x3f778('0x3d')),logger[_0x3f778('0x4f')](_0x3f778('0x2b'),_0xd4b5a1,_0x3f778('0x3d'),JSON['stringify'](_0x199eea));if(_0x199eea[_0x3f778('0x4')]){if(_0x199eea[_0x3f778('0x4')][_0x3f778('0x30')]===0x1f4)return logger['error'](_0x3f778('0x72'),_0xd4b5a1,_0x199eea[_0x3f778('0x4')][_0x3f778('0x62')]),_0x8b26cf(_0x199eea['error'][_0x3f778('0x62')]);return logger[_0x3f778('0x4')](_0x3f778('0x72'),_0xd4b5a1,_0x199eea['error'][_0x3f778('0x62')]),_0x564cbd(_0x199eea[_0x3f778('0x4')]['message']);}else logger[_0x3f778('0xd')]('SmsMessage,\x20%s,\x20%s',_0xd4b5a1,_0x3f778('0x3d')),_0x564cbd(_0x199eea[_0x3f778('0x8')][_0x3f778('0x62')]);})[_0x25776a('0x1f')](function(_0x110ccd){const _0x125957=_0x25776a;logger[_0x125957('0x4')](_0x125957('0x72'),_0xd4b5a1,_0x110ccd),_0x8b26cf(_0x110ccd);});});}function respondWithResult(_0x162dab,_0x15c6a7){return _0x15c6a7=_0x15c6a7||0xc8,function(_0xd7e6fc){const _0x50c277=a560_0x1a31;if(_0xd7e6fc)return _0x162dab[_0x50c277('0x37')](_0x15c6a7)[_0x50c277('0x50')](_0xd7e6fc);};}function respondWithFilteredResult(_0x270df6,_0x40c475){return function(_0x13d7f4){const _0x53ea9a=a560_0x1a31;if(_0x13d7f4){const _0x55335f=_0x13d7f4[_0x53ea9a('0x4d')],_0x2f559f=_0x40c475[_0x53ea9a('0x2c')];let _0x506c9e=_0x40c475[_0x53ea9a('0x2c')]+_0x40c475[_0x53ea9a('0x6e')],_0x1f99fa;return _0x506c9e>=_0x55335f?(_0x506c9e=_0x55335f,_0x1f99fa=0xc8):_0x1f99fa=0xce,_0x270df6[_0x53ea9a('0x37')](_0x1f99fa),_0x270df6[_0x53ea9a('0x21')](_0x53ea9a('0x2a'),_0x2f559f+'-'+_0x506c9e+'/'+_0x55335f)[_0x53ea9a('0x50')](_0x13d7f4);}return null;};}function saveUpdates(_0x50acfe){return function(_0xf17143){const _0x172be7=a560_0x1a31;if(_0xf17143)return _0xf17143[_0x172be7('0x6c')](_0x50acfe)[_0x172be7('0x43')](function(_0x4ebbe0){return _0x4ebbe0;});return null;};}function removeEntity(_0x368a6a){return function(_0x32121f){const _0x24404e=a560_0x1a31;if(_0x32121f)return _0x32121f[_0x24404e('0x36')]()['then'](function(){const _0x187fa0=_0x24404e;_0x368a6a['status'](0xcc)[_0x187fa0('0x29')]();});};}function handleEntityNotFound(_0x1b96f6){return function(_0x59e7db){const _0x4e9d23=a560_0x1a31;return!_0x59e7db&&_0x1b96f6[_0x4e9d23('0x33')](0x194),_0x59e7db;};}function handleError(_0xfc640c,_0x2ed970){return _0x2ed970=_0x2ed970||0x1f4,function(_0x9551fe){const _0x5cae76=a560_0x1a31;logger[_0x5cae76('0x4')](_0x9551fe[_0x5cae76('0x39')]),_0x9551fe[_0x5cae76('0x48')]&&delete _0x9551fe[_0x5cae76('0x48')],_0xfc640c[_0x5cae76('0x37')](_0x2ed970)[_0x5cae76('0x35')](_0x9551fe);};}exports[_0x1a2f39('0x69')]=function(_0x467da1,_0x4f520d){const _0x38e05a=_0x1a2f39;let _0x355f1f={};const _0x6d655a={},_0x13d07e={'count':0x0,'rows':[]},_0x3e158c=_[_0x38e05a('0x2f')](db[_0x38e05a('0x4e')][_0x38e05a('0x6')],function(_0x540685){const _0x416f99=_0x38e05a;return{'name':_0x540685[_0x416f99('0x4c')],'type':_0x540685[_0x416f99('0xb')][_0x416f99('0x1e')]};});_0x6d655a['model']=_[_0x38e05a('0x2f')](_0x3e158c,_0x38e05a('0x48')),_0x6d655a[_0x38e05a('0x25')]=_['keys'](_0x467da1['query']),_0x6d655a[_0x38e05a('0x3c')]=_[_0x38e05a('0x4b')](_0x6d655a['model'],_0x6d655a[_0x38e05a('0x25')]),_0x355f1f['attributes']=_[_0x38e05a('0x4b')](_0x6d655a[_0x38e05a('0x6d')],qs['fields'](_0x467da1[_0x38e05a('0x25')][_0x38e05a('0x5a')])),_0x355f1f[_0x38e05a('0x45')]=_0x355f1f[_0x38e05a('0x45')][_0x38e05a('0x23')]?_0x355f1f['attributes']:_0x6d655a[_0x38e05a('0x6d')];typeof _0x467da1[_0x38e05a('0x25')][_0x38e05a('0x19')]===_0x38e05a('0xe')&&(_0x355f1f[_0x38e05a('0x6e')]=qs[_0x38e05a('0x6e')](_0x467da1['query'][_0x38e05a('0x6e')]),_0x355f1f[_0x38e05a('0x2c')]=qs[_0x38e05a('0x2c')](_0x467da1[_0x38e05a('0x25')]['offset']));_0x355f1f[_0x38e05a('0x2')]=qs[_0x38e05a('0x68')](_0x467da1[_0x38e05a('0x25')][_0x38e05a('0x68')]),_0x355f1f[_0x38e05a('0x11')]=qs[_0x38e05a('0x3c')](_[_0x38e05a('0x47')](_0x467da1['query'],_0x6d655a[_0x38e05a('0x3c')]),_0x3e158c);_0x467da1['query'][_0x38e05a('0x42')]&&(_0x355f1f['where']=_[_0x38e05a('0x5d')](_0x355f1f[_0x38e05a('0x11')],{[Op['or']]:_[_0x38e05a('0x2f')](_0x3e158c,function(_0x382bc3){const _0x47a4f1=_0x38e05a;if(_0x382bc3[_0x47a4f1('0xb')]!==_0x47a4f1('0x40')){const _0x2db3ed={};return _0x2db3ed[_0x382bc3[_0x47a4f1('0x48')]]={[Op[_0x47a4f1('0x2e')]]:'%'+_0x467da1[_0x47a4f1('0x25')][_0x47a4f1('0x42')]+'%'},_0x2db3ed;}})}));_0x355f1f=_[_0x38e05a('0x5d')]({},_0x355f1f,_0x467da1[_0x38e05a('0x15')]);const _0x5caa2f={'where':_0x355f1f[_0x38e05a('0x11')]};return db[_0x38e05a('0x4e')][_0x38e05a('0x4d')](_0x5caa2f)[_0x38e05a('0x43')](function(_0x2c5025){const _0x1cc3b8=_0x38e05a;return _0x13d07e[_0x1cc3b8('0x4d')]=_0x2c5025,_0x467da1[_0x1cc3b8('0x25')][_0x1cc3b8('0x1c')]&&(_0x355f1f[_0x1cc3b8('0x13')]=[{'all':!![]}]),db[_0x1cc3b8('0x4e')][_0x1cc3b8('0x3b')](_0x355f1f);})['then'](function(_0x5e9771){const _0x3bfc20=_0x38e05a;return _0x13d07e[_0x3bfc20('0x26')]=_0x5e9771,_0x13d07e;})[_0x38e05a('0x43')](respondWithFilteredResult(_0x4f520d,_0x355f1f))['catch'](handleError(_0x4f520d,null));},exports[_0x1a2f39('0x5c')]=function(_0x489cdf,_0x4194be){const _0x3fa280=_0x1a2f39;let _0x5df2b1={'raw':!![],'where':{'id':_0x489cdf[_0x3fa280('0x6f')]['id']}};const _0xa1d9f0={};return _0xa1d9f0[_0x3fa280('0x6d')]=_[_0x3fa280('0xa')](db['SmsMessage']['rawAttributes']),_0xa1d9f0['query']=_[_0x3fa280('0xa')](_0x489cdf[_0x3fa280('0x25')]),_0xa1d9f0[_0x3fa280('0x3c')]=_[_0x3fa280('0x4b')](_0xa1d9f0['model'],_0xa1d9f0['query']),_0x5df2b1[_0x3fa280('0x45')]=_[_0x3fa280('0x4b')](_0xa1d9f0[_0x3fa280('0x6d')],qs['fields'](_0x489cdf[_0x3fa280('0x25')][_0x3fa280('0x5a')])),_0x5df2b1[_0x3fa280('0x45')]=_0x5df2b1[_0x3fa280('0x45')][_0x3fa280('0x23')]?_0x5df2b1[_0x3fa280('0x45')]:_0xa1d9f0['model'],_0x489cdf['query'][_0x3fa280('0x1c')]&&(_0x5df2b1[_0x3fa280('0x13')]=[{'all':!![]}]),_0x5df2b1=_[_0x3fa280('0x5d')]({},_0x5df2b1,_0x489cdf[_0x3fa280('0x15')]),db[_0x3fa280('0x4e')][_0x3fa280('0x27')](_0x5df2b1)[_0x3fa280('0x43')](handleEntityNotFound(_0x4194be,null))[_0x3fa280('0x43')](respondWithResult(_0x4194be,null))[_0x3fa280('0x1f')](handleError(_0x4194be,null));},exports[_0x1a2f39('0x56')]=function(_0x44b493,_0x200b86){const _0x1f6016=_0x1a2f39;return db[_0x1f6016('0x4e')]['create'](_0x44b493[_0x1f6016('0x71')],{})[_0x1f6016('0x43')](respondWithResult(_0x200b86,0xc9))[_0x1f6016('0x1f')](handleError(_0x200b86,null));},exports[_0x1a2f39('0x6c')]=function(_0x309af8,_0x8015d7){const _0x350a75=_0x1a2f39;return _0x309af8[_0x350a75('0x71')]['id']&&delete _0x309af8[_0x350a75('0x71')]['id'],db[_0x350a75('0x4e')][_0x350a75('0x27')]({'where':{'id':_0x309af8[_0x350a75('0x6f')]['id']}})[_0x350a75('0x43')](handleEntityNotFound(_0x8015d7,null))[_0x350a75('0x43')](saveUpdates(_0x309af8[_0x350a75('0x71')],null))[_0x350a75('0x43')](respondWithResult(_0x8015d7,null))[_0x350a75('0x1f')](handleError(_0x8015d7,null));},exports['destroy']=function(_0x509196,_0x23f879){const _0x1be4f9=_0x1a2f39;return db['SmsMessage'][_0x1be4f9('0x27')]({'where':{'id':_0x509196[_0x1be4f9('0x6f')]['id']}})['then'](handleEntityNotFound(_0x23f879,null))[_0x1be4f9('0x43')](removeEntity(_0x23f879,null))[_0x1be4f9('0x1f')](handleError(_0x23f879,null));},exports[_0x1a2f39('0x78')]=function(_0x4d39ee,_0x492cd9){const _0x4950c9=_0x1a2f39;return db['SmsMessage'][_0x4950c9('0x78')]()[_0x4950c9('0x43')](respondWithResult(_0x492cd9,null))[_0x4950c9('0x1f')](handleError(_0x492cd9,null));},exports[_0x1a2f39('0x64')]=function(_0x1a2daa,_0x3e7088){const _0x38b2c5=_0x1a2f39,_0x4f246f={'channel':_0x38b2c5('0x6a')};return _0x1a2daa[_0x38b2c5('0x71')]['id']&&delete _0x1a2daa[_0x38b2c5('0x71')]['id'],_0x1a2daa[_0x38b2c5('0x71')][_0x38b2c5('0x79')]=!![],_0x1a2daa[_0x38b2c5('0x71')][_0x38b2c5('0x1a')]=moment()['format'](_0x38b2c5('0x38')),_0x1a2daa[_0x38b2c5('0x71')][_0x38b2c5('0x1d')]=_0x1a2daa[_0x38b2c5('0x71')][_0x38b2c5('0x1d')]||_0x1a2daa[_0x38b2c5('0x0')]['id'],db[_0x38b2c5('0x4e')][_0x38b2c5('0x27')]({'where':{'id':_0x1a2daa['params']['id'],'UserId':null},'include':[{'model':db[_0x38b2c5('0x3f')],'as':_0x38b2c5('0x3a')}]})[_0x38b2c5('0x43')](handleEntityNotFound(_0x3e7088,null))[_0x38b2c5('0x43')](saveUpdates(_0x1a2daa[_0x38b2c5('0x71')],null))[_0x38b2c5('0x43')](function(_0x52a971){const _0x329d0d=_0x38b2c5;if(_0x52a971)return _0x4f246f[_0x329d0d('0x62')]=_0x52a971[_0x329d0d('0x61')]({'plain':!![]}),db['SmsInteraction']['findOne']({'where':{'id':_0x52a971[_0x329d0d('0x6b')]}});return null;})[_0x38b2c5('0x43')](handleEntityNotFound(_0x3e7088,null))['then'](function(_0x2769b0){const _0x4b049c=_0x38b2c5;if(_0x2769b0)return _0x2769b0[_0x4b049c('0x6c')]({'UserId':_0x1a2daa[_0x4b049c('0x71')][_0x4b049c('0x1d')],'read1stAt':_['isNil'](_0x2769b0[_0x4b049c('0x12')])?moment()['format'](_0x4b049c('0x38')):undefined});return null;})[_0x38b2c5('0x43')](function(_0x42fc59){const _0x3c7e79=_0x38b2c5;if(_0x42fc59)return _0x4f246f[_0x3c7e79('0xc')]=_0x42fc59[_0x3c7e79('0x61')]({'plain':!![]}),interaction_log[_0x3c7e79('0xd')](_0x3c7e79('0x77'),_0x1a2daa[_0x3c7e79('0x0')]['id'],_0x1a2daa[_0x3c7e79('0x0')][_0x3c7e79('0x48')],_0x1a2daa[_0x3c7e79('0x0')][_0x3c7e79('0x66')],_0x4f246f['interaction']['id'],_0x1a2daa['body']?JSON[_0x3c7e79('0x10')](_0x1a2daa['body']):'null'),respondWithRpcPromise(_0x3c7e79('0x75'),_0x3c7e79('0x7'),_0x4f246f);return null;})['then'](function(_0x591a3f){const _0x31217a=_0x38b2c5;if(_0x591a3f){if(_0x1a2daa['body'][_0x31217a('0x16')])return _0x4f246f[_0x31217a('0x62')][_0x31217a('0x59')]=util['format'](_0x31217a('0x4a'),_0x1a2daa[_0x31217a('0x0')][_0x31217a('0x48')]),_0x4f246f[_0x31217a('0x62')]['channel']=_0x4f246f[_0x31217a('0x5e')],_0x4f246f[_0x31217a('0x62')]['event']=_0x31217a('0x64'),respondWithRpcPromise(_0x31217a('0x57'),_0x31217a('0x57'),{'event':_0x31217a('0x46'),'message':_0x4f246f['message']},client9002)['then'](function(){return _0x4f246f;});return _0x4f246f;}return null;})[_0x38b2c5('0x43')](respondWithResult(_0x3e7088,null))[_0x38b2c5('0x1f')](handleError(_0x3e7088,null));},exports[_0x1a2f39('0x17')]=function(_0x10d125,_0x800836){const _0x198111=_0x1a2f39,_0x30695c={'agent':{},'channel':'sms'};return _0x10d125[_0x198111('0x71')]['id']&&delete _0x10d125[_0x198111('0x71')]['id'],_0x10d125[_0x198111('0x71')][_0x198111('0x1d')]=_0x10d125['body'][_0x198111('0x1d')]||_0x10d125[_0x198111('0x0')]['id'],_0x30695c['agent']['id']=_0x10d125[_0x198111('0x71')][_0x198111('0x1d')],db[_0x198111('0x4e')][_0x198111('0x27')]({'where':{'id':_0x10d125[_0x198111('0x6f')]['id'],'UserId':null}})[_0x198111('0x43')](handleEntityNotFound(_0x800836,null))[_0x198111('0x43')](function(_0x3725cc){const _0x13e71d=_0x198111;if(_0x3725cc)return _0x30695c[_0x13e71d('0x62')]=_0x3725cc['get']({'plain':!![]}),db['SmsInteraction'][_0x13e71d('0x27')]({'where':{'id':_0x3725cc[_0x13e71d('0x6b')]}});return null;})['then'](handleEntityNotFound(_0x800836,null))[_0x198111('0x43')](function(_0x3d1de3){const _0x4fcd98=_0x198111;if(_0x3d1de3)return _0x30695c[_0x4fcd98('0xc')]=_0x3d1de3[_0x4fcd98('0x61')]({'plain':!![]}),interaction_log['info'](_0x4fcd98('0x14'),_0x10d125['user']['id'],_0x10d125[_0x4fcd98('0x0')]['name'],_0x10d125['user']['role'],_0x30695c['interaction']['id'],_0x10d125[_0x4fcd98('0x71')]?JSON[_0x4fcd98('0x10')](_0x10d125[_0x4fcd98('0x71')]):_0x4fcd98('0x5b')),respondWithRpcPromise(_0x4fcd98('0x2d'),_0x4fcd98('0x3e'),_0x30695c);return null;})[_0x198111('0x43')](function(_0x492ef0){const _0x1a518e=_0x198111;if(_0x492ef0)return _0x492ef0['message'][_0x1a518e('0x59')]=util[_0x1a518e('0x51')](_0x1a518e('0x4a'),_0x10d125[_0x1a518e('0x0')]['name']),_0x492ef0['message'][_0x1a518e('0x5e')]=_0x30695c['channel'],_0x492ef0[_0x1a518e('0x62')]['event']=_0x1a518e('0x17'),respondWithRpcPromise(_0x1a518e('0x57'),_0x1a518e('0x57'),{'event':'rejectmessage','message':_0x492ef0[_0x1a518e('0x62')]},client9002),_0x30695c;return null;})[_0x198111('0x43')](respondWithResult(_0x800836,null))[_0x198111('0x1f')](handleError(_0x800836,null));},exports[_0x1a2f39('0x37')]=function(_0x5a74fe,_0x347b2d){const _0x3359b3=_0x1a2f39;_0x5a74fe['body']['id']&&delete _0x5a74fe[_0x3359b3('0x71')]['id'];let _0x403181;return db['SmsMessage'][_0x3359b3('0x27')]({'where':{'id':_0x5a74fe['params']['id']}})['then'](handleEntityNotFound(_0x347b2d,null))['then'](function(_0x13ef8d){const _0x456c8a=_0x3359b3;if(_0x13ef8d)return _0x403181=_0x13ef8d,db[_0x456c8a('0x32')]['findOne']({'where':{'id':_0x13ef8d['SmsAccountId']}});})[_0x3359b3('0x43')](handleEntityNotFound(_0x347b2d,null))[_0x3359b3('0x43')](function(_0x45028){const _0x47e090=_0x3359b3;if(_0x45028){logger[_0x47e090('0x4f')]('SmsMessage,\x20%s,\x20%s,\x20%s','status',_0x47e090('0x1b'),_0x45028[_0x47e090('0xb')],util[_0x47e090('0x74')](_0x5a74fe[_0x47e090('0x71')],{'showHidden':![],'depth':null}));switch(_0x45028[_0x47e090('0xb')]){case _0x47e090('0x73'):if(_0x5a74fe[_0x47e090('0x71')][_0x47e090('0x55')]&&_0x5a74fe[_0x47e090('0x71')][_0x47e090('0x55')]===_0x403181[_0x47e090('0x24')])return _0x403181[_0x47e090('0x6c')]({'read':!![]});else logger['error']('SmsAccount,\x20%s,\x20%s,\x20%s',_0x47e090('0x37'),_0x47e090('0x73'),util[_0x47e090('0x74')](_0x5a74fe['body'],{'showHidden':![],'depth':null}));break;case _0x47e090('0x76'):if(_0x5a74fe['body'][_0x47e090('0x22')]&&_0x5a74fe[_0x47e090('0x71')][_0x47e090('0x22')]===_0x403181[_0x47e090('0x24')]&&_[_0x47e090('0x34')](['sent',_0x47e090('0xf')],_0x5a74fe['body'][_0x47e090('0x67')])>=0x0)return _0x403181['update']({'read':!![]});else logger[_0x47e090('0x4')](_0x47e090('0x20'),_0x47e090('0x37'),_0x47e090('0x1'),util[_0x47e090('0x74')](_0x5a74fe[_0x47e090('0x71')],{'showHidden':![],'depth':null}));break;case _0x47e090('0x18'):{const _0x21dc46=_0x5a74fe['body'][_0x47e090('0x63')][0x0];if(_0x21dc46['status'][_0x47e090('0x31')]===_0x47e090('0x41'))return _0x403181[_0x47e090('0x6c')]({'read':!![]});else logger[_0x47e090('0x4')](_0x47e090('0x20'),_0x47e090('0x37'),_0x47e090('0x18'),util[_0x47e090('0x74')](_0x5a74fe['body'],{'showHidden':![],'depth':null}));}break;}return _0x403181;}})[_0x3359b3('0x43')](respondWithResult(_0x347b2d,null))[_0x3359b3('0x1f')](handleError(_0x347b2d,null));}; \ No newline at end of file diff --git a/server/api/smsMessage/smsMessage.events.js b/server/api/smsMessage/smsMessage.events.js index 2df7a1f..2899ca7 100644 --- a/server/api/smsMessage/smsMessage.events.js +++ b/server/api/smsMessage/smsMessage.events.js @@ -1 +1 @@ -const a561_0x392b=['remove','save','addHook','events','../../mysqldb','exports','update','SmsMessage','emit'];(function(_0x42e11d,_0x392bdb){const _0x43e71c=function(_0x11bfd0){while(--_0x11bfd0){_0x42e11d['push'](_0x42e11d['shift']());}};_0x43e71c(++_0x392bdb);}(a561_0x392b,0x19d));const a561_0x43e7=function(_0x42e11d,_0x392bdb){_0x42e11d=_0x42e11d-0x0;let _0x43e71c=a561_0x392b[_0x42e11d];return _0x43e71c;};const _0x4905ce=a561_0x43e7;'use strict';const EventEmitter=require(_0x4905ce('0x4')),SmsMessage=require(_0x4905ce('0x5'))['db'][_0x4905ce('0x8')],SmsMessageEvents=new EventEmitter();SmsMessageEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x4905ce('0x2'),'afterUpdate':_0x4905ce('0x7'),'afterDestroy':_0x4905ce('0x1')};function emitEvent(_0x11bfd0){return function(_0x427141){const _0x4443bc=a561_0x43e7;SmsMessageEvents[_0x4443bc('0x0')](_0x11bfd0+':'+_0x427141['id'],_0x427141),SmsMessageEvents['emit'](_0x11bfd0,_0x427141);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];SmsMessage[_0x4905ce('0x3')](e,emitEvent(event));}}module[_0x4905ce('0x6')]=SmsMessageEvents; \ No newline at end of file +const a561_0x3659=['emit','save','events','undefined','../../mysqldb','remove','exports','SmsMessage','setMaxListeners','addHook'];(function(_0x4ae27c,_0x365944){const _0x4bb590=function(_0x3c522a){while(--_0x3c522a){_0x4ae27c['push'](_0x4ae27c['shift']());}};_0x4bb590(++_0x365944);}(a561_0x3659,0x1e1));const a561_0x4bb5=function(_0x4ae27c,_0x365944){_0x4ae27c=_0x4ae27c-0x0;let _0x4bb590=a561_0x3659[_0x4ae27c];return _0x4bb590;};const _0x3a2f6b=a561_0x4bb5;'use strict';const EventEmitter=require(_0x3a2f6b('0x1')),SmsMessage=require(_0x3a2f6b('0x3'))['db'][_0x3a2f6b('0x6')],SmsMessageEvents=new EventEmitter();SmsMessageEvents[_0x3a2f6b('0x7')](0x0);const events={'afterCreate':_0x3a2f6b('0x0'),'afterUpdate':'update','afterDestroy':_0x3a2f6b('0x4')};function emitEvent(_0x3c522a){return function(_0x139d28){const _0x57ee46=a561_0x4bb5;SmsMessageEvents[_0x57ee46('0x9')](_0x3c522a+':'+_0x139d28['id'],_0x139d28),SmsMessageEvents[_0x57ee46('0x9')](_0x3c522a,_0x139d28);};}for(const e in events){if(typeof events[e]!==_0x3a2f6b('0x2')){const event=events[e];SmsMessage[_0x3a2f6b('0x8')](e,emitEvent(event));}}module[_0x3a2f6b('0x5')]=SmsMessageEvents; \ No newline at end of file diff --git a/server/api/smsMessage/smsMessage.model.js b/server/api/smsMessage/smsMessage.model.js index d6139d9..77474e8 100644 --- a/server/api/smsMessage/smsMessage.model.js +++ b/server/api/smsMessage/smsMessage.model.js @@ -1 +1 @@ -const a562_0x2b3d=['https://platform.clickatell.com/messages','keys','%s:%s','hex','inspect','login','util','phone','message','body','application/json','../../config/logger','message_uuid','deliveryReport','Bearer\x20','UTF-8','catch','Missing\x20parameters:\x20username,\x20password','SmsInteractionId','baseUrl','https://api.intelepeer.com/_rest/v4/app/sms/send','create','clicksend','digest','GET','Token\x20not\x20received','out','apiMessageId','accountSid','direction','format','plivo','infobip','token','utf8mb4_unicode_ci','error','sms','findOne','afterCreate','SmsMessage','models','read','message_id','session_key','/api/sms/messages/','&password=','isNil','https://rest.clicksend.com/v3/sms/send','type','twilio','SmsAccountId','http_code','internal_order_id','createHash','define','update','lodash','https://smsapi.connectel.se/api/v2/send/','Basic\x20%s','POST','SmsAccount','./smsMessage.attributes','UserId','sender','messageId','SmsMessage,\x20%s,\x20%s,\x20%s','connectel','messages','toString','secret','createdAt','from','https://api.plivo.com/v1/Account/%s/Message/','senderString','login?username=','Missing\x20parameters:\x20authToken','then','/sms/2/text/advanced','split','authToken','https://api.intelepeer.com/_rest/v4/app/sms/mdr','sid','api','base64','authId','SmsInteraction','/status?token=','xCALLY\x20Motion','https://api.skebby.it/API/v1.0/REST/','username','requestid','toLowerCase','clickatell','finally','text','queued_count','utf8mb4','user_key','IBSSO\x20','apiKey','intelepeer','clickSend','uuid','FULLTEXT','total_sent','csc','password','data','skebby','get','exports','Missing\x20parameters:\x20base_url','remote','/external/get/send.php?','md5','Missing\x20parameters:\x20apiKey','smsMethod'];(function(_0x387b05,_0x2b3d85){const _0x7cd93=function(_0x12d10e){while(--_0x12d10e){_0x387b05['push'](_0x387b05['shift']());}};_0x7cd93(++_0x2b3d85);}(a562_0x2b3d,0x7d));const a562_0x7cd9=function(_0x387b05,_0x2b3d85){_0x387b05=_0x387b05-0x0;let _0x7cd93=a562_0x2b3d[_0x387b05];return _0x7cd93;};const _0x4212fa=a562_0x7cd9;'use strict';const _=require(_0x4212fa('0x30')),util=require(_0x4212fa('0x73')),logger=require(_0x4212fa('0x3'))(_0x4212fa('0x4a')),rp=require('request-promise-native'),attributes=require(_0x4212fa('0x35'));module[_0x4212fa('0x66')]=function(_0x12d10e){const _0x383b76=_0x4212fa,_0x2cb104=_0x12d10e[_0x383b76('0x20')],_0x5495f8=_0x12d10e[_0x383b76('0x2e')](_0x383b76('0x1f'),attributes,{'tableName':'sms_messages','paranoid':![],'indexes':[{'name':_0x383b76('0x38'),'fields':[_0x383b76('0x38')]},{'name':'fti_sms_messages','fields':['body'],'type':_0x383b76('0x5f')}],'timestamps':!![],'hooks':{'afterCreate':function(_0x479f32){const _0x16a10f=_0x383b76,_0xd4fd72=_0x479f32[_0x16a10f('0x65')]({'plain':!![]});(_0xd4fd72[_0x16a10f('0x15')][_0x16a10f('0x53')]()==='in'||_0xd4fd72[_0x16a10f('0x15')]['toLowerCase']()===_0x16a10f('0x12')&&!_0xd4fd72[_0x16a10f('0x3d')]&&!_[_0x16a10f('0x26')](_0xd4fd72[_0x16a10f('0x36')]))&&_0x2cb104[_0x16a10f('0x4d')][_0x16a10f('0x1d')]({'where':{'id':_0xd4fd72[_0x16a10f('0xa')]}})[_0x16a10f('0x44')](function(_0x58afac){const _0x3023c3=_0x16a10f;_0x58afac&&_0x58afac[_0x3023c3('0x2f')]({'lastMsgAt':_0xd4fd72[_0x3023c3('0x3e')],'lastMsgDirection':_0xd4fd72[_0x3023c3('0x15')][_0x3023c3('0x53')]()});})[_0x16a10f('0x8')](function(_0x186637){const _0x2f87a0=_0x16a10f;console[_0x2f87a0('0x1b')](_0x186637);});if(_0xd4fd72['direction']==='out'&&!_0xd4fd72[_0x16a10f('0x3d')]){let _0x4f07e1;_0x2cb104[_0x16a10f('0x34')][_0x16a10f('0x1d')]({'where':{'id':_0xd4fd72[_0x16a10f('0x2a')]},'raw':!![]})[_0x16a10f('0x44')](function(_0x1039a3){const _0x23b25b=_0x16a10f;_0x4f07e1=_0x1039a3;if(_0x4f07e1&&_0x4f07e1['type'])switch(_0x4f07e1[_0x23b25b('0x28')]){case _0x23b25b('0x29'):{const _0x412904=require('twilio');if(_0x4f07e1[_0x23b25b('0x14')]&&_0x4f07e1[_0x23b25b('0x47')]&&_0x4f07e1[_0x23b25b('0x74')]){const _0x58eb92=new _0x412904(_0x4f07e1[_0x23b25b('0x14')],_0x4f07e1[_0x23b25b('0x47')]);_0x58eb92[_0x23b25b('0x3b')][_0x23b25b('0xd')]({'body':_0xd4fd72[_0x23b25b('0x1')],'to':_0xd4fd72[_0x23b25b('0x74')],'from':_0x4f07e1[_0x23b25b('0x74')],'statusCallback':_0x4f07e1['remote']+_0x23b25b('0x24')+_0xd4fd72['id']+_0x23b25b('0x4e')+_0x4f07e1[_0x23b25b('0x19')]})['then'](function(_0x3f16fb){const _0x942288=_0x23b25b;if(_0x3f16fb[_0x942288('0x49')])return _0x479f32['update']({'messageId':_0x3f16fb[_0x942288('0x49')]});})[_0x23b25b('0x8')](function(_0x2a4844){const _0x55bae3=_0x23b25b;logger[_0x55bae3('0x1b')](_0x55bae3('0x39'),_0x55bae3('0x1e'),'twilio',util[_0x55bae3('0x71')](_0x2a4844,{'showHidden':![],'depth':null}));});}else logger[_0x23b25b('0x1b')]('SmsMessage,\x20%s,\x20%s,\x20%s',_0x23b25b('0x1e'),_0x23b25b('0x29'),'Missing\x20parameters:\x20phone,\x20accountSid\x20or\x20authToken');break;}case _0x23b25b('0x64'):{const _0x1c0eb5=_0x23b25b('0x50');if(_0x4f07e1[_0x23b25b('0x51')]&&_0x4f07e1[_0x23b25b('0x62')]){const _0x384a38={'recipient':[_0xd4fd72[_0x23b25b('0x74')]],'message':_0xd4fd72[_0x23b25b('0x1')],'message_type':_0x4f07e1['smsMethod']};_0x4f07e1[_0x23b25b('0x6c')]&&_0x4f07e1['smsMethod']!=='SI'&&(_0x384a38[_0x23b25b('0x37')]=_0x4f07e1[_0x23b25b('0x74')]);let _0x205873={'url':_0x1c0eb5+_0x23b25b('0x42')+_0x4f07e1['username']+_0x23b25b('0x25')+_0x4f07e1[_0x23b25b('0x62')],'method':_0x23b25b('0x10')};rp(_0x205873)['then'](function(_0x4e9b02){const _0x334dfd=_0x23b25b,_0x4083fe=_0x4e9b02[_0x334dfd('0x46')](';'),_0x546876={'user_key':_0x4083fe[0x0],'session_key':_0x4083fe[0x1]};return _0x205873={'url':_0x1c0eb5+_0x334dfd('0x1c'),'method':_0x334dfd('0x33'),'headers':{'user_key':_0x546876[_0x334dfd('0x59')],'Session_key':_0x546876[_0x334dfd('0x23')]},'json':!![],'body':_0x384a38},rp(_0x205873);})[_0x23b25b('0x44')](function(_0x1d03fc){const _0x4203da=_0x23b25b;if(_0x1d03fc[_0x4203da('0x60')]>=0x1){const _0x2d2e29={'messageId':_0x1d03fc[_0x4203da('0x2c')]};return(_0x4f07e1['smsMethod']!=='GP'||!_0x4f07e1[_0x4203da('0x5')])&&(_0x2d2e29[_0x4203da('0x21')]=!![]),_0x479f32[_0x4203da('0x2f')](_0x2d2e29);}else return logger['error'](_0x4203da('0x39'),_0x4203da('0x1e'),_0x4203da('0x64'),util[_0x4203da('0x71')](_0x1d03fc,{'showHidden':![],'depth':null}));})[_0x23b25b('0x8')](function(_0x5ac50b){const _0x592d88=_0x23b25b;return logger[_0x592d88('0x1b')](_0x592d88('0x39'),_0x592d88('0x1e'),_0x592d88('0x64'),util[_0x592d88('0x71')](_0x5ac50b,{'showHidden':![],'depth':null}));});}else logger[_0x23b25b('0x1b')](_0x23b25b('0x39'),'afterCreate',_0x23b25b('0x64'),_0x23b25b('0x9'));break;}case'connectel':{if(_0x4f07e1[_0x23b25b('0x47')]){const _0x47ab72={'recipient':_0xd4fd72['phone'],'message':_0xd4fd72[_0x23b25b('0x1')],'sender':_0x4f07e1[_0x23b25b('0x41')]||_0x4f07e1[_0x23b25b('0x74')],'authorization':_0x4f07e1[_0x23b25b('0x47')]},_0x437dd2={'method':_0x23b25b('0x33'),'uri':_0x23b25b('0x31'),'body':_0x47ab72,'json':!![]};rp(_0x437dd2)[_0x23b25b('0x44')](function(_0x444b54){const _0xfa1049=_0x23b25b,_0x51b4fb={'messageId':_0x444b54[_0xfa1049('0x52')]};return!_0x4f07e1[_0xfa1049('0x5')]&&(_0x51b4fb[_0xfa1049('0x21')]=!![]),_0x479f32[_0xfa1049('0x2f')](_0x51b4fb);})[_0x23b25b('0x8')](function(_0x2c0b52){const _0x3fc85f=_0x23b25b;logger['error'](_0x3fc85f('0x39'),_0x3fc85f('0x1e'),_0x3fc85f('0x3a'),util[_0x3fc85f('0x71')](_0x2c0b52,{'showHidden':![],'depth':null}));});}else logger[_0x23b25b('0x1b')](_0x23b25b('0x39'),_0x23b25b('0x1e'),_0x23b25b('0x3a'),_0x23b25b('0x43'));break;}case _0x23b25b('0xe'):{if(_0x4f07e1[_0x23b25b('0x51')]&&_0x4f07e1[_0x23b25b('0x62')]){const _0x49f4d9={'messages':[{'source':_0x23b25b('0x4f'),'to':_0xd4fd72[_0x23b25b('0x74')],'body':_0xd4fd72[_0x23b25b('0x1')],'from':_0x4f07e1['senderString']||_0x4f07e1[_0x23b25b('0x74')]}]},_0x4ac32a=util[_0x23b25b('0x16')](_0x23b25b('0x6f'),_0x4f07e1[_0x23b25b('0x51')],_0x4f07e1['password']),_0x32d9a4={'method':'POST','uri':_0x23b25b('0x27'),'body':_0x49f4d9,'headers':{'Authorization':util[_0x23b25b('0x16')](_0x23b25b('0x32'),Buffer[_0x23b25b('0x3f')](_0x4ac32a)[_0x23b25b('0x3c')](_0x23b25b('0x4b')))},'json':!![]};rp(_0x32d9a4)[_0x23b25b('0x44')](function(_0x290feb){const _0x375d3d=_0x23b25b;if(_0x290feb[_0x375d3d('0x2b')]>=0xc8&&_0x290feb['http_code']<=0xce){if(_0x290feb[_0x375d3d('0x63')]&&_0x290feb['data'][_0x375d3d('0x57')]>0x0){const _0x2fbc39=_['head'](_0x290feb[_0x375d3d('0x63')]['messages']),_0xbc810f={'messageId':_0x2fbc39[_0x375d3d('0x22')]};return!_0x4f07e1[_0x375d3d('0x5')]&&(_0xbc810f[_0x375d3d('0x21')]=!![]),_0x479f32[_0x375d3d('0x2f')](_0xbc810f);}else logger[_0x375d3d('0x1b')]('SmsMessage,\x20%s,\x20%s,\x20%s',_0x375d3d('0x1e'),_0x375d3d('0x5d'),util[_0x375d3d('0x71')](_0x290feb,{'showHidden':![],'depth':null}));}else logger['error'](_0x375d3d('0x39'),_0x375d3d('0x1e'),_0x375d3d('0x5d'),util[_0x375d3d('0x71')](_0x290feb,{'showHidden':![],'depth':null}));})['catch'](function(_0x45e20a){const _0x53e236=_0x23b25b;logger['error'](_0x53e236('0x39'),_0x53e236('0x1e'),_0x53e236('0x5d'),util[_0x53e236('0x71')](_0x45e20a,{'showHidden':![],'depth':null}));});}else logger['error'](_0x23b25b('0x39'),'afterCreate',_0x23b25b('0x5d'),_0x23b25b('0x9'));break;}case _0x23b25b('0x17'):{if(_0x4f07e1[_0x23b25b('0x4c')]&&_0x4f07e1[_0x23b25b('0x47')]){const _0x168c61={'dst':_0xd4fd72[_0x23b25b('0x74')],'text':_0xd4fd72[_0x23b25b('0x1')],'src':_0x4f07e1[_0x23b25b('0x41')]||_0x4f07e1['phone'],'url':_0x4f07e1[_0x23b25b('0x68')]+_0x23b25b('0x24')+_0xd4fd72['id']+'/status?token='+_0x4f07e1[_0x23b25b('0x19')]},_0x18e3c8=util[_0x23b25b('0x16')](_0x23b25b('0x6f'),_0x4f07e1['authId'],_0x4f07e1[_0x23b25b('0x47')]),_0x3af8cb={'method':_0x23b25b('0x33'),'uri':util[_0x23b25b('0x16')](_0x23b25b('0x40'),_0x4f07e1[_0x23b25b('0x4c')]),'body':_0x168c61,'headers':{'Authorization':util[_0x23b25b('0x16')]('Basic\x20%s',Buffer['from'](_0x18e3c8)['toString'](_0x23b25b('0x4b')))},'json':!![]};rp(_0x3af8cb)['then'](function(_0x19f134){const _0x37dc72=_0x23b25b,_0x2c7484={'messageId':_0x19f134[_0x37dc72('0x4')][0x0]};return _0x479f32[_0x37dc72('0x2f')](_0x2c7484);})[_0x23b25b('0x8')](function(_0x17431f){const _0x3eaaf8=_0x23b25b;logger['error'](_0x3eaaf8('0x39'),_0x3eaaf8('0x1e'),_0x3eaaf8('0x17'),util[_0x3eaaf8('0x71')](_0x17431f,{'showHidden':![],'depth':null}));});}else logger[_0x23b25b('0x1b')]('SmsMessage,\x20%s,\x20%s,\x20%s',_0x23b25b('0x1e'),'plivo','Missing\x20parameters:\x20authId,\x20authToken');break;}case _0x23b25b('0x18'):{if(_0x4f07e1[_0x23b25b('0x51')]&&_0x4f07e1[_0x23b25b('0x62')]){if(_0x4f07e1[_0x23b25b('0xb')]){const _0x2a69d8={'method':_0x23b25b('0x33'),'uri':_0x4f07e1[_0x23b25b('0xb')]+'/auth/1/session','body':{'username':_0x4f07e1[_0x23b25b('0x51')],'password':_0x4f07e1[_0x23b25b('0x62')]},'json':!![]};return rp(_0x2a69d8)[_0x23b25b('0x44')](function(_0x772a74){const _0x5c38f3=_0x23b25b,_0x14d8b9={'method':_0x5c38f3('0x33'),'uri':_0x4f07e1[_0x5c38f3('0xb')]+_0x5c38f3('0x45'),'body':{'messages':[{'from':_0x4f07e1['phone'],'destinations':[{'to':_0xd4fd72[_0x5c38f3('0x74')]}],'text':_0xd4fd72[_0x5c38f3('0x1')],'notifyUrl':_0x4f07e1[_0x5c38f3('0x68')]+_0x5c38f3('0x24')+_0xd4fd72['id']+_0x5c38f3('0x4e')+_0x4f07e1[_0x5c38f3('0x19')],'notifyContentType':'application/json','callbackData':_0x4f07e1['phone']+';'+_0xd4fd72[_0x5c38f3('0x1')]}]},'headers':{'Authorization':_0x5c38f3('0x5a')+_0x772a74[_0x5c38f3('0x19')]},'json':!![]};return rp(_0x14d8b9)[_0x5c38f3('0x44')](function(_0xf02927){const _0x442d59=_0x5c38f3;if(_0xf02927[_0x442d59('0x3b')]){const _0x1fdc80={'messageId':_0xf02927['messages'][0x0][_0x442d59('0x38')]};return!_0x4f07e1[_0x442d59('0x5')]&&(_0x1fdc80[_0x442d59('0x21')]=!![]),_0x479f32[_0x442d59('0x2f')](_0x1fdc80);}else return logger[_0x442d59('0x1b')](_0x442d59('0x39'),_0x442d59('0x1e'),_0x442d59('0x18'),util['inspect'](_0xf02927,{'showHidden':![],'depth':null}));});})[_0x23b25b('0x8')](function(_0x41bdf3){const _0x1239ff=_0x23b25b;return logger['error'](_0x1239ff('0x39'),_0x1239ff('0x1e'),_0x1239ff('0x18'),util[_0x1239ff('0x71')](_0x41bdf3,{'showHidden':![],'depth':null}));});}else logger[_0x23b25b('0x1b')](_0x23b25b('0x39'),'afterCreate',_0x23b25b('0x18'),_0x23b25b('0x67'));}else logger[_0x23b25b('0x1b')](_0x23b25b('0x39'),'afterCreate',_0x23b25b('0x18'),_0x23b25b('0x9'));break;}case'csc':{const _0x5bdbf3=require('crypto');if(_0x4f07e1[_0x23b25b('0x5b')]){const _0x248680={};_0x248680[_0x23b25b('0x72')]=_0x4f07e1[_0x23b25b('0x51')],_0x248680[_0x23b25b('0x74')]=_0xd4fd72[_0x23b25b('0x74')],_0x248680[_0x23b25b('0x37')]=_0x4f07e1[_0x23b25b('0x74')],_0x248680[_0x23b25b('0x56')]=_0xd4fd72['body'],_0x248680['timestamp']=+new Date();let _0x4e57b1='',_0x16dcf5='';const _0x10662a=Object[_0x23b25b('0x6e')](_0x248680);_0x10662a['sort']();for(let _0x598f1e=0x0;_0x598f1e<_0x10662a['length'];_0x598f1e++){_0x4e57b1!=''&&(_0x4e57b1+='&'),_0x4e57b1+=_0x10662a[_0x598f1e]+'='+encodeURIComponent(_0x248680[_0x10662a[_0x598f1e]]),_0x16dcf5+=_0x248680[_0x10662a[_0x598f1e]];}_0x16dcf5+=_0x4f07e1[_0x23b25b('0x5b')],_0x16dcf5=_0x5bdbf3[_0x23b25b('0x2d')](_0x23b25b('0x6a'))[_0x23b25b('0x2f')](_0x16dcf5)[_0x23b25b('0xf')](_0x23b25b('0x70'));_0x4e57b1!==''&&(_0x4e57b1+='&');_0x4e57b1+='signature='+_0x16dcf5;const _0x494977={'method':_0x23b25b('0x10'),'uri':_0x4f07e1['baseUrl']+_0x23b25b('0x69')+_0x4e57b1,'json':!![]};return rp(_0x494977)[_0x23b25b('0x44')](function(_0x135ff2){const _0x5a343e=_0x23b25b,_0x236ebb=Object[_0x5a343e('0x6e')](_0x135ff2);if(_0x135ff2[_0x236ebb[0x0]][_0x5a343e('0x1b')]&&parseInt(_0x135ff2[_0x236ebb[0x0]]['error'])===0x0){const _0x516ff8={'messageId':_0x135ff2[_0x236ebb[0x0]]['id_sms']};return!_0x4f07e1[_0x5a343e('0x5')]&&(_0x516ff8['read']=!![]),_0x479f32[_0x5a343e('0x2f')](_0x516ff8);}else return logger[_0x5a343e('0x1b')](_0x5a343e('0x39'),_0x5a343e('0x1e'),_0x5a343e('0x61'),util[_0x5a343e('0x71')](_0x135ff2[_0x5a343e('0x1b')],{'showHidden':![],'depth':null}));})[_0x23b25b('0x8')](function(_0x4d454a){const _0x4b3f73=_0x23b25b;return logger[_0x4b3f73('0x1b')](_0x4b3f73('0x39'),_0x4b3f73('0x1e'),_0x4b3f73('0x61'),util['inspect'](_0x4d454a,{'showHidden':![],'depth':null}));});}else logger[_0x23b25b('0x1b')](_0x23b25b('0x39'),_0x23b25b('0x1e'),_0x23b25b('0x61'),_0x23b25b('0x6b'));break;}case'clickatell':{if(_0x4f07e1[_0x23b25b('0x5b')]){const _0x102bcb={'method':_0x23b25b('0x33'),'uri':_0x23b25b('0x6d'),'headers':{'Authorization':_0x4f07e1[_0x23b25b('0x5b')]},'body':{'content':_0xd4fd72['body'],'to':[_0xd4fd72[_0x23b25b('0x74')]],'from':_0x4f07e1[_0x23b25b('0x74')],'binary':![],'clientMessageId':_0x23b25b('0x5e'),'charset':_0x23b25b('0x7')},'json':!![]};rp(_0x102bcb)[_0x23b25b('0x44')](function(_0x1d43e3){const _0x150cad=_0x23b25b;if(!_0x1d43e3[_0x150cad('0x1b')]){const _0x217175={'messageId':_0x1d43e3[_0x150cad('0x3b')][0x0][_0x150cad('0x13')]};return!_0x4f07e1[_0x150cad('0x5')]&&(_0x217175['read']=!![]),_0x479f32[_0x150cad('0x2f')](_0x217175);}else return logger[_0x150cad('0x1b')](_0x150cad('0x39'),'afterCreate',_0x150cad('0x54'),util[_0x150cad('0x71')](_0x1d43e3[_0x150cad('0x1b')],{'showHidden':![],'depth':null}));})[_0x23b25b('0x8')](function(_0x4bf9f6){const _0x7e3929=_0x23b25b;return logger['error']('SmsMessage,\x20%s,\x20%s,\x20%s',_0x7e3929('0x1e'),_0x7e3929('0x54'),util[_0x7e3929('0x71')](_0x4bf9f6,{'showHidden':![],'depth':null}));});}else logger['error'](_0x23b25b('0x39'),'afterCreate','clickatell','Missing\x20parameters:\x20apiKey');break;}case _0x23b25b('0x5c'):if(_0x4f07e1[_0x23b25b('0x5b')]){const _0x2b085d={},_0x1c9dd7={'method':_0x23b25b('0x33'),'uri':_0x23b25b('0xc'),'headers':{'Authorization':'Bearer\x20'+_0x4f07e1[_0x23b25b('0x5b')],'Content-Type':_0x23b25b('0x2')},'body':{'from':_0x4f07e1[_0x23b25b('0x74')],'to':_0xd4fd72[_0x23b25b('0x74')],'text':_0xd4fd72['body']},'json':!![]};return rp(_0x1c9dd7)[_0x23b25b('0x44')](function(_0x163d8c){const _0x19c99e=_0x23b25b;if(_0x163d8c['code']==0xca){_0x2b085d[_0x19c99e('0x0')]=_0x163d8c;const _0x7dfe63={'method':_0x19c99e('0x33'),'uri':_0x19c99e('0x48'),'headers':{'Authorization':_0x19c99e('0x6')+_0x4f07e1[_0x19c99e('0x5b')],'Content-Type':'application/json'},'body':{'refid':_0x2b085d[_0x19c99e('0x0')]['refid']},'json':!![]};return rp(_0x7dfe63)[_0x19c99e('0x44')](function(_0x58b35c){const _0x4ed272=_0x19c99e;_0x2b085d['status']=_0x58b35c;const _0x4b8f1c={'messageId':_0x2b085d[_0x4ed272('0x0')]['refid'],'read':!![]};return _0x479f32[_0x4ed272('0x2f')](_0x4b8f1c);});}else return logger[_0x19c99e('0x1b')](_0x19c99e('0x39'),_0x19c99e('0x1e'),_0x19c99e('0x5c'),util[_0x19c99e('0x71')](_0x163d8c,{'showHidden':![],'depth':null}));})['catch'](function(_0x28037b){const _0x46327d=_0x23b25b;return logger[_0x46327d('0x1b')](_0x46327d('0x39'),_0x46327d('0x1e'),'intelepeer',util['inspect'](_0x28037b,{'showHidden':![],'depth':null}));});}else return logger['error'](_0x23b25b('0x39'),'afterCreate',_0x23b25b('0x5c'),_0x23b25b('0x11'));}})[_0x16a10f('0x55')](function(){return null;});}else return null;}},'charset':_0x383b76('0x58'),'collate':_0x383b76('0x1a')});return _0x5495f8;}; \ No newline at end of file +const a562_0x18d7=['smsMethod','timestamp','findOne','from','keys','../../config/logger','SmsInteractionId','login?username=','authId','user_key','digest','type','SmsMessage','read','isNil','split','messageId','clicksend','https://platform.clickatell.com/messages','md5','sid','out','https://api.intelepeer.com/_rest/v4/app/sms/mdr','session_key','infobip','password','UTF-8','connectel','intelepeer','senderString','csc','Bearer\x20','clickSend','message_id','code','utf8mb4','/sms/2/text/advanced','message','/status?token=','direction','apiMessageId','afterCreate','update','plivo','status','http_code','catch','phone','createHash','request-promise-native','Missing\x20parameters:\x20apiKey','SmsAccount','Basic\x20%s','SmsInteraction','Missing\x20parameters:\x20phone,\x20accountSid\x20or\x20authToken','sender','/api/sms/messages/','clickatell','secret','GET','define','Missing\x20parameters:\x20username,\x20password','https://api.intelepeer.com/_rest/v4/app/sms/send','refid','data','token','util','application/json','head','login','./smsMessage.attributes','SmsMessage,\x20%s,\x20%s,\x20%s','IBSSO\x20','username','fti_sms_messages','inspect','body','twilio','apiKey','https://smsapi.connectel.se/api/v2/send/','authToken','queued_count','message_uuid','baseUrl','hex','sort','toLowerCase','Missing\x20parameters:\x20authToken','text','internal_order_id','messages','FULLTEXT','https://api.plivo.com/v1/Account/%s/Message/','signature=','accountSid','toString','Token\x20not\x20received','crypto','then','lodash','sms_messages','error','deliveryReport','format','models','SmsAccountId','/external/get/send.php?','POST','remote','&password=','skebby','total_sent','exports','utf8mb4_unicode_ci','uuid'];(function(_0x3be148,_0x18d7be){const _0x2137e1=function(_0x1f1f7d){while(--_0x1f1f7d){_0x3be148['push'](_0x3be148['shift']());}};_0x2137e1(++_0x18d7be);}(a562_0x18d7,0x1be));const a562_0x2137=function(_0x3be148,_0x18d7be){_0x3be148=_0x3be148-0x0;let _0x2137e1=a562_0x18d7[_0x3be148];return _0x2137e1;};const _0x53f270=a562_0x2137;'use strict';const _=require(_0x53f270('0x71')),util=require(_0x53f270('0x50')),logger=require(_0x53f270('0x13'))('api'),rp=require(_0x53f270('0x3f')),attributes=require(_0x53f270('0x54'));module[_0x53f270('0xb')]=function(_0x1f1f7d){const _0x561069=_0x53f270,_0x36a91d=_0x1f1f7d[_0x561069('0x3')],_0x51a565=_0x1f1f7d[_0x561069('0x4a')](_0x561069('0x1a'),attributes,{'tableName':_0x561069('0x72'),'paranoid':![],'indexes':[{'name':_0x561069('0x1e'),'fields':[_0x561069('0x1e')]},{'name':_0x561069('0x58'),'fields':[_0x561069('0x5a')],'type':_0x561069('0x69')}],'timestamps':!![],'hooks':{'afterCreate':function(_0x5c0b6c){const _0x24a20b=_0x561069,_0x3d8db1=_0x5c0b6c['get']({'plain':!![]});(_0x3d8db1[_0x24a20b('0x35')][_0x24a20b('0x64')]()==='in'||_0x3d8db1[_0x24a20b('0x35')][_0x24a20b('0x64')]()===_0x24a20b('0x23')&&!_0x3d8db1[_0x24a20b('0x48')]&&!_[_0x24a20b('0x1c')](_0x3d8db1['UserId']))&&_0x36a91d[_0x24a20b('0x43')]['findOne']({'where':{'id':_0x3d8db1[_0x24a20b('0x14')]}})[_0x24a20b('0x70')](function(_0x4f2912){const _0x379e1a=_0x24a20b;_0x4f2912&&_0x4f2912['update']({'lastMsgAt':_0x3d8db1['createdAt'],'lastMsgDirection':_0x3d8db1[_0x379e1a('0x35')][_0x379e1a('0x64')]()});})['catch'](function(_0x343b5e){console['error'](_0x343b5e);});if(_0x3d8db1[_0x24a20b('0x35')]===_0x24a20b('0x23')&&!_0x3d8db1[_0x24a20b('0x48')]){let _0x4310cc;_0x36a91d[_0x24a20b('0x41')][_0x24a20b('0x10')]({'where':{'id':_0x3d8db1[_0x24a20b('0x4')]},'raw':!![]})[_0x24a20b('0x70')](function(_0x2b9005){const _0x4e4895=_0x24a20b;_0x4310cc=_0x2b9005;if(_0x4310cc&&_0x4310cc['type'])switch(_0x4310cc[_0x4e4895('0x19')]){case _0x4e4895('0x5b'):{const _0x10a5c7=require(_0x4e4895('0x5b'));if(_0x4310cc[_0x4e4895('0x6c')]&&_0x4310cc[_0x4e4895('0x5e')]&&_0x4310cc[_0x4e4895('0x3d')]){const _0x43124a=new _0x10a5c7(_0x4310cc[_0x4e4895('0x6c')],_0x4310cc[_0x4e4895('0x5e')]);_0x43124a[_0x4e4895('0x68')]['create']({'body':_0x3d8db1['body'],'to':_0x3d8db1['phone'],'from':_0x4310cc[_0x4e4895('0x3d')],'statusCallback':_0x4310cc[_0x4e4895('0x7')]+_0x4e4895('0x46')+_0x3d8db1['id']+_0x4e4895('0x34')+_0x4310cc[_0x4e4895('0x4f')]})[_0x4e4895('0x70')](function(_0x490200){const _0x35c189=_0x4e4895;if(_0x490200['sid'])return _0x5c0b6c[_0x35c189('0x38')]({'messageId':_0x490200[_0x35c189('0x22')]});})[_0x4e4895('0x3c')](function(_0x3eff44){const _0x20f29f=_0x4e4895;logger[_0x20f29f('0x0')](_0x20f29f('0x55'),_0x20f29f('0x37'),_0x20f29f('0x5b'),util[_0x20f29f('0x59')](_0x3eff44,{'showHidden':![],'depth':null}));});}else logger[_0x4e4895('0x0')](_0x4e4895('0x55'),_0x4e4895('0x37'),'twilio',_0x4e4895('0x44'));break;}case'skebby':{const _0x3c64e5='https://api.skebby.it/API/v1.0/REST/';if(_0x4310cc[_0x4e4895('0x57')]&&_0x4310cc[_0x4e4895('0x27')]){const _0x256aee={'recipient':[_0x3d8db1[_0x4e4895('0x3d')]],'message':_0x3d8db1[_0x4e4895('0x5a')],'message_type':_0x4310cc[_0x4e4895('0xe')]};_0x4310cc['smsMethod']&&_0x4310cc['smsMethod']!=='SI'&&(_0x256aee['sender']=_0x4310cc[_0x4e4895('0x3d')]);let _0x2fc2bf={'url':_0x3c64e5+_0x4e4895('0x15')+_0x4310cc['username']+_0x4e4895('0x8')+_0x4310cc['password'],'method':_0x4e4895('0x49')};rp(_0x2fc2bf)[_0x4e4895('0x70')](function(_0x183fcc){const _0x5b2c7b=_0x4e4895,_0x39ffd1=_0x183fcc[_0x5b2c7b('0x1d')](';'),_0x591d39={'user_key':_0x39ffd1[0x0],'session_key':_0x39ffd1[0x1]};return _0x2fc2bf={'url':_0x3c64e5+'sms','method':_0x5b2c7b('0x6'),'headers':{'user_key':_0x591d39[_0x5b2c7b('0x17')],'Session_key':_0x591d39[_0x5b2c7b('0x25')]},'json':!![],'body':_0x256aee},rp(_0x2fc2bf);})[_0x4e4895('0x70')](function(_0x2e010b){const _0x1720cb=_0x4e4895;if(_0x2e010b[_0x1720cb('0xa')]>=0x1){const _0xa34138={'messageId':_0x2e010b[_0x1720cb('0x67')]};return(_0x4310cc[_0x1720cb('0xe')]!=='GP'||!_0x4310cc[_0x1720cb('0x1')])&&(_0xa34138[_0x1720cb('0x1b')]=!![]),_0x5c0b6c[_0x1720cb('0x38')](_0xa34138);}else return logger[_0x1720cb('0x0')](_0x1720cb('0x55'),_0x1720cb('0x37'),_0x1720cb('0x9'),util[_0x1720cb('0x59')](_0x2e010b,{'showHidden':![],'depth':null}));})['catch'](function(_0x2de421){const _0x3085ca=_0x4e4895;return logger[_0x3085ca('0x0')](_0x3085ca('0x55'),_0x3085ca('0x37'),'skebby',util[_0x3085ca('0x59')](_0x2de421,{'showHidden':![],'depth':null}));});}else logger['error']('SmsMessage,\x20%s,\x20%s,\x20%s',_0x4e4895('0x37'),_0x4e4895('0x9'),_0x4e4895('0x4b'));break;}case _0x4e4895('0x29'):{if(_0x4310cc[_0x4e4895('0x5e')]){const _0x48c38d={'recipient':_0x3d8db1[_0x4e4895('0x3d')],'message':_0x3d8db1[_0x4e4895('0x5a')],'sender':_0x4310cc[_0x4e4895('0x2b')]||_0x4310cc[_0x4e4895('0x3d')],'authorization':_0x4310cc[_0x4e4895('0x5e')]},_0x313ee8={'method':_0x4e4895('0x6'),'uri':_0x4e4895('0x5d'),'body':_0x48c38d,'json':!![]};rp(_0x313ee8)['then'](function(_0x5db1f7){const _0x4f0d18=_0x4e4895,_0x55b6b2={'messageId':_0x5db1f7['requestid']};return!_0x4310cc[_0x4f0d18('0x1')]&&(_0x55b6b2[_0x4f0d18('0x1b')]=!![]),_0x5c0b6c['update'](_0x55b6b2);})[_0x4e4895('0x3c')](function(_0x17a814){const _0x2af954=_0x4e4895;logger[_0x2af954('0x0')](_0x2af954('0x55'),_0x2af954('0x37'),'connectel',util[_0x2af954('0x59')](_0x17a814,{'showHidden':![],'depth':null}));});}else logger[_0x4e4895('0x0')]('SmsMessage,\x20%s,\x20%s,\x20%s',_0x4e4895('0x37'),'connectel',_0x4e4895('0x65'));break;}case _0x4e4895('0x1f'):{if(_0x4310cc[_0x4e4895('0x57')]&&_0x4310cc['password']){const _0x3a3cfc={'messages':[{'source':'xCALLY\x20Motion','to':_0x3d8db1[_0x4e4895('0x3d')],'body':_0x3d8db1[_0x4e4895('0x5a')],'from':_0x4310cc[_0x4e4895('0x2b')]||_0x4310cc[_0x4e4895('0x3d')]}]},_0xa71b0c=util[_0x4e4895('0x2')]('%s:%s',_0x4310cc[_0x4e4895('0x57')],_0x4310cc[_0x4e4895('0x27')]),_0x23814b={'method':_0x4e4895('0x6'),'uri':'https://rest.clicksend.com/v3/sms/send','body':_0x3a3cfc,'headers':{'Authorization':util[_0x4e4895('0x2')]('Basic\x20%s',Buffer[_0x4e4895('0x11')](_0xa71b0c)[_0x4e4895('0x6d')]('base64'))},'json':!![]};rp(_0x23814b)[_0x4e4895('0x70')](function(_0x465d2e){const _0xde6f8d=_0x4e4895;if(_0x465d2e[_0xde6f8d('0x3b')]>=0xc8&&_0x465d2e['http_code']<=0xce){if(_0x465d2e['data']&&_0x465d2e[_0xde6f8d('0x4e')][_0xde6f8d('0x5f')]>0x0){const _0x55b8b7=_[_0xde6f8d('0x52')](_0x465d2e['data'][_0xde6f8d('0x68')]),_0x23b9b3={'messageId':_0x55b8b7[_0xde6f8d('0x2f')]};return!_0x4310cc[_0xde6f8d('0x1')]&&(_0x23b9b3[_0xde6f8d('0x1b')]=!![]),_0x5c0b6c[_0xde6f8d('0x38')](_0x23b9b3);}else logger[_0xde6f8d('0x0')](_0xde6f8d('0x55'),_0xde6f8d('0x37'),_0xde6f8d('0x2e'),util[_0xde6f8d('0x59')](_0x465d2e,{'showHidden':![],'depth':null}));}else logger[_0xde6f8d('0x0')]('SmsMessage,\x20%s,\x20%s,\x20%s','afterCreate',_0xde6f8d('0x2e'),util[_0xde6f8d('0x59')](_0x465d2e,{'showHidden':![],'depth':null}));})[_0x4e4895('0x3c')](function(_0x37134f){const _0x4b9089=_0x4e4895;logger['error'](_0x4b9089('0x55'),'afterCreate',_0x4b9089('0x2e'),util[_0x4b9089('0x59')](_0x37134f,{'showHidden':![],'depth':null}));});}else logger[_0x4e4895('0x0')](_0x4e4895('0x55'),_0x4e4895('0x37'),_0x4e4895('0x2e'),_0x4e4895('0x4b'));break;}case _0x4e4895('0x39'):{if(_0x4310cc[_0x4e4895('0x16')]&&_0x4310cc['authToken']){const _0x772dee={'dst':_0x3d8db1[_0x4e4895('0x3d')],'text':_0x3d8db1[_0x4e4895('0x5a')],'src':_0x4310cc[_0x4e4895('0x2b')]||_0x4310cc[_0x4e4895('0x3d')],'url':_0x4310cc[_0x4e4895('0x7')]+_0x4e4895('0x46')+_0x3d8db1['id']+_0x4e4895('0x34')+_0x4310cc['token']},_0x515d4f=util[_0x4e4895('0x2')]('%s:%s',_0x4310cc['authId'],_0x4310cc[_0x4e4895('0x5e')]),_0x2e74f4={'method':_0x4e4895('0x6'),'uri':util[_0x4e4895('0x2')](_0x4e4895('0x6a'),_0x4310cc[_0x4e4895('0x16')]),'body':_0x772dee,'headers':{'Authorization':util[_0x4e4895('0x2')](_0x4e4895('0x42'),Buffer[_0x4e4895('0x11')](_0x515d4f)[_0x4e4895('0x6d')]('base64'))},'json':!![]};rp(_0x2e74f4)[_0x4e4895('0x70')](function(_0x39ee0f){const _0x1137c8=_0x4e4895,_0x402365={'messageId':_0x39ee0f[_0x1137c8('0x60')][0x0]};return _0x5c0b6c[_0x1137c8('0x38')](_0x402365);})['catch'](function(_0x5cfd55){const _0x471e6f=_0x4e4895;logger['error'](_0x471e6f('0x55'),_0x471e6f('0x37'),_0x471e6f('0x39'),util[_0x471e6f('0x59')](_0x5cfd55,{'showHidden':![],'depth':null}));});}else logger['error'](_0x4e4895('0x55'),_0x4e4895('0x37'),_0x4e4895('0x39'),'Missing\x20parameters:\x20authId,\x20authToken');break;}case'infobip':{if(_0x4310cc[_0x4e4895('0x57')]&&_0x4310cc[_0x4e4895('0x27')]){if(_0x4310cc[_0x4e4895('0x61')]){const _0x1af043={'method':_0x4e4895('0x6'),'uri':_0x4310cc['baseUrl']+'/auth/1/session','body':{'username':_0x4310cc[_0x4e4895('0x57')],'password':_0x4310cc[_0x4e4895('0x27')]},'json':!![]};return rp(_0x1af043)['then'](function(_0x1e326a){const _0x2f57e8=_0x4e4895,_0x3cba0c={'method':_0x2f57e8('0x6'),'uri':_0x4310cc[_0x2f57e8('0x61')]+_0x2f57e8('0x32'),'body':{'messages':[{'from':_0x4310cc['phone'],'destinations':[{'to':_0x3d8db1['phone']}],'text':_0x3d8db1[_0x2f57e8('0x5a')],'notifyUrl':_0x4310cc[_0x2f57e8('0x7')]+'/api/sms/messages/'+_0x3d8db1['id']+'/status?token='+_0x4310cc['token'],'notifyContentType':_0x2f57e8('0x51'),'callbackData':_0x4310cc[_0x2f57e8('0x3d')]+';'+_0x3d8db1[_0x2f57e8('0x5a')]}]},'headers':{'Authorization':_0x2f57e8('0x56')+_0x1e326a[_0x2f57e8('0x4f')]},'json':!![]};return rp(_0x3cba0c)[_0x2f57e8('0x70')](function(_0x237c56){const _0x328138=_0x2f57e8;if(_0x237c56[_0x328138('0x68')]){const _0x12561c={'messageId':_0x237c56[_0x328138('0x68')][0x0][_0x328138('0x1e')]};return!_0x4310cc['deliveryReport']&&(_0x12561c[_0x328138('0x1b')]=!![]),_0x5c0b6c[_0x328138('0x38')](_0x12561c);}else return logger[_0x328138('0x0')]('SmsMessage,\x20%s,\x20%s,\x20%s',_0x328138('0x37'),'infobip',util[_0x328138('0x59')](_0x237c56,{'showHidden':![],'depth':null}));});})[_0x4e4895('0x3c')](function(_0x4f4c2d){const _0x509707=_0x4e4895;return logger[_0x509707('0x0')](_0x509707('0x55'),'afterCreate','infobip',util[_0x509707('0x59')](_0x4f4c2d,{'showHidden':![],'depth':null}));});}else logger['error']('SmsMessage,\x20%s,\x20%s,\x20%s','afterCreate',_0x4e4895('0x26'),'Missing\x20parameters:\x20base_url');}else logger[_0x4e4895('0x0')](_0x4e4895('0x55'),_0x4e4895('0x37'),_0x4e4895('0x26'),_0x4e4895('0x4b'));break;}case'csc':{const _0xf208ea=require(_0x4e4895('0x6f'));if(_0x4310cc[_0x4e4895('0x5c')]){const _0x5d9f9a={};_0x5d9f9a[_0x4e4895('0x53')]=_0x4310cc[_0x4e4895('0x57')],_0x5d9f9a['phone']=_0x3d8db1['phone'],_0x5d9f9a[_0x4e4895('0x45')]=_0x4310cc[_0x4e4895('0x3d')],_0x5d9f9a[_0x4e4895('0x66')]=_0x3d8db1[_0x4e4895('0x5a')],_0x5d9f9a[_0x4e4895('0xf')]=+new Date();let _0x3216d6='',_0x33a790='';const _0x22b74f=Object[_0x4e4895('0x12')](_0x5d9f9a);_0x22b74f[_0x4e4895('0x63')]();for(let _0x1bcab6=0x0;_0x1bcab6<_0x22b74f['length'];_0x1bcab6++){_0x3216d6!=''&&(_0x3216d6+='&'),_0x3216d6+=_0x22b74f[_0x1bcab6]+'='+encodeURIComponent(_0x5d9f9a[_0x22b74f[_0x1bcab6]]),_0x33a790+=_0x5d9f9a[_0x22b74f[_0x1bcab6]];}_0x33a790+=_0x4310cc['apiKey'],_0x33a790=_0xf208ea[_0x4e4895('0x3e')](_0x4e4895('0x21'))['update'](_0x33a790)[_0x4e4895('0x18')](_0x4e4895('0x62'));_0x3216d6!==''&&(_0x3216d6+='&');_0x3216d6+=_0x4e4895('0x6b')+_0x33a790;const _0x3bc230={'method':_0x4e4895('0x49'),'uri':_0x4310cc['baseUrl']+_0x4e4895('0x5')+_0x3216d6,'json':!![]};return rp(_0x3bc230)[_0x4e4895('0x70')](function(_0xe7ebb0){const _0x161084=_0x4e4895,_0x45f8bd=Object['keys'](_0xe7ebb0);if(_0xe7ebb0[_0x45f8bd[0x0]][_0x161084('0x0')]&&parseInt(_0xe7ebb0[_0x45f8bd[0x0]][_0x161084('0x0')])===0x0){const _0x5bf53c={'messageId':_0xe7ebb0[_0x45f8bd[0x0]]['id_sms']};return!_0x4310cc[_0x161084('0x1')]&&(_0x5bf53c['read']=!![]),_0x5c0b6c[_0x161084('0x38')](_0x5bf53c);}else return logger[_0x161084('0x0')](_0x161084('0x55'),_0x161084('0x37'),'csc',util[_0x161084('0x59')](_0xe7ebb0[_0x161084('0x0')],{'showHidden':![],'depth':null}));})['catch'](function(_0x20461a){const _0x1e97b8=_0x4e4895;return logger[_0x1e97b8('0x0')](_0x1e97b8('0x55'),_0x1e97b8('0x37'),_0x1e97b8('0x2c'),util[_0x1e97b8('0x59')](_0x20461a,{'showHidden':![],'depth':null}));});}else logger[_0x4e4895('0x0')]('SmsMessage,\x20%s,\x20%s,\x20%s',_0x4e4895('0x37'),'csc',_0x4e4895('0x40'));break;}case'clickatell':{if(_0x4310cc['apiKey']){const _0x5ab22d={'method':'POST','uri':_0x4e4895('0x20'),'headers':{'Authorization':_0x4310cc['apiKey']},'body':{'content':_0x3d8db1[_0x4e4895('0x5a')],'to':[_0x3d8db1[_0x4e4895('0x3d')]],'from':_0x4310cc[_0x4e4895('0x3d')],'binary':![],'clientMessageId':_0x4e4895('0xd'),'charset':_0x4e4895('0x28')},'json':!![]};rp(_0x5ab22d)[_0x4e4895('0x70')](function(_0x42ddc3){const _0x1a0971=_0x4e4895;if(!_0x42ddc3[_0x1a0971('0x0')]){const _0x365636={'messageId':_0x42ddc3[_0x1a0971('0x68')][0x0][_0x1a0971('0x36')]};return!_0x4310cc['deliveryReport']&&(_0x365636[_0x1a0971('0x1b')]=!![]),_0x5c0b6c[_0x1a0971('0x38')](_0x365636);}else return logger[_0x1a0971('0x0')](_0x1a0971('0x55'),_0x1a0971('0x37'),_0x1a0971('0x47'),util[_0x1a0971('0x59')](_0x42ddc3['error'],{'showHidden':![],'depth':null}));})[_0x4e4895('0x3c')](function(_0x42b8d8){const _0x4d5aac=_0x4e4895;return logger['error'](_0x4d5aac('0x55'),_0x4d5aac('0x37'),_0x4d5aac('0x47'),util['inspect'](_0x42b8d8,{'showHidden':![],'depth':null}));});}else logger[_0x4e4895('0x0')](_0x4e4895('0x55'),'afterCreate','clickatell','Missing\x20parameters:\x20apiKey');break;}case _0x4e4895('0x2a'):if(_0x4310cc[_0x4e4895('0x5c')]){const _0x46bb4f={},_0x4bce71={'method':_0x4e4895('0x6'),'uri':_0x4e4895('0x4c'),'headers':{'Authorization':'Bearer\x20'+_0x4310cc[_0x4e4895('0x5c')],'Content-Type':_0x4e4895('0x51')},'body':{'from':_0x4310cc[_0x4e4895('0x3d')],'to':_0x3d8db1['phone'],'text':_0x3d8db1['body']},'json':!![]};return rp(_0x4bce71)[_0x4e4895('0x70')](function(_0x5dcb2a){const _0x37eeae=_0x4e4895;if(_0x5dcb2a[_0x37eeae('0x30')]==0xca){_0x46bb4f[_0x37eeae('0x33')]=_0x5dcb2a;const _0xf9ba70={'method':'POST','uri':_0x37eeae('0x24'),'headers':{'Authorization':_0x37eeae('0x2d')+_0x4310cc[_0x37eeae('0x5c')],'Content-Type':_0x37eeae('0x51')},'body':{'refid':_0x46bb4f[_0x37eeae('0x33')][_0x37eeae('0x4d')]},'json':!![]};return rp(_0xf9ba70)[_0x37eeae('0x70')](function(_0x52ef7b){const _0x63d8d9=_0x37eeae;_0x46bb4f[_0x63d8d9('0x3a')]=_0x52ef7b;const _0x421f44={'messageId':_0x46bb4f['message'][_0x63d8d9('0x4d')],'read':!![]};return _0x5c0b6c[_0x63d8d9('0x38')](_0x421f44);});}else return logger['error'](_0x37eeae('0x55'),'afterCreate',_0x37eeae('0x2a'),util[_0x37eeae('0x59')](_0x5dcb2a,{'showHidden':![],'depth':null}));})['catch'](function(_0x4a2eb3){const _0x3f8b24=_0x4e4895;return logger['error']('SmsMessage,\x20%s,\x20%s,\x20%s',_0x3f8b24('0x37'),'intelepeer',util[_0x3f8b24('0x59')](_0x4a2eb3,{'showHidden':![],'depth':null}));});}else return logger[_0x4e4895('0x0')]('SmsMessage,\x20%s,\x20%s,\x20%s',_0x4e4895('0x37'),_0x4e4895('0x2a'),_0x4e4895('0x6e'));}})['finally'](function(){return null;});}else return null;}},'charset':_0x561069('0x31'),'collate':_0x561069('0xc')});return _0x51a565;}; \ No newline at end of file diff --git a/server/api/smsMessage/smsMessage.rpc.js b/server/api/smsMessage/smsMessage.rpc.js index d784dff..33be3f7 100644 --- a/server/api/smsMessage/smsMessage.rpc.js +++ b/server/api/smsMessage/smsMessage.rpc.js @@ -1 +1 @@ -const a563_0x541e=['SmsMessage','then','./smsMessage.socket','options','register','message','../../config/logger','CreateSmsMessage','raw','../../rediscache','info','../../mysqldb','stringify','error','body','catch'];(function(_0x24c441,_0x541e4f){const _0x4e97d8=function(_0x2081f0){while(--_0x2081f0){_0x24c441['push'](_0x24c441['shift']());}};_0x4e97d8(++_0x541e4f);}(a563_0x541e,0x126));const a563_0x4e97=function(_0x24c441,_0x541e4f){_0x24c441=_0x24c441-0x0;let _0x4e97d8=a563_0x541e[_0x24c441];return _0x4e97d8;};const _0x415268=a563_0x4e97;'use strict';const db=require(_0x415268('0x5'))['db'],logger=require(_0x415268('0x0'))('rpc'),{getSocket}=require(_0x415268('0x3')),socket=getSocket();require(_0x415268('0xc'))[_0x415268('0xe')](socket),exports['CreateSmsMessage']=function(_0x2081f0){const _0x3aaaf0=this;return new Promise(function(_0x1eca14,_0x4865ef){const _0xb02ec3=a563_0x4e97;return db[_0xb02ec3('0xa')]['create'](_0x2081f0[_0xb02ec3('0x8')],{'raw':_0x2081f0[_0xb02ec3('0xd')]?_0x2081f0[_0xb02ec3('0xd')][_0xb02ec3('0x2')]===undefined?!![]:![]:!![]})[_0xb02ec3('0xb')](function(_0x1773e5){const _0x3157c4=_0xb02ec3;logger[_0x3157c4('0x4')]('CreateSmsMessage',_0x2081f0),logger['debug'](_0x3157c4('0x1'),_0x2081f0,JSON[_0x3157c4('0x6')](_0x1773e5)),_0x1eca14(_0x1773e5);})[_0xb02ec3('0x9')](function(_0x5c6eb9){const _0x207247=_0xb02ec3;logger['error'](_0x207247('0x1'),_0x5c6eb9[_0x207247('0xf')],_0x2081f0),_0x4865ef(_0x3aaaf0[_0x207247('0x7')](0x1f4,_0x5c6eb9[_0x207247('0xf')]));});});}; \ No newline at end of file +const a563_0xcfe0=['options','CreateSmsMessage','SmsMessage','register','create','../../mysqldb','raw','message','body','rpc','catch','./smsMessage.socket','stringify','error','info'];(function(_0x48ea4f,_0xcfe027){const _0x1bd424=function(_0x2509d3){while(--_0x2509d3){_0x48ea4f['push'](_0x48ea4f['shift']());}};_0x1bd424(++_0xcfe027);}(a563_0xcfe0,0x7f));const a563_0x1bd4=function(_0x48ea4f,_0xcfe027){_0x48ea4f=_0x48ea4f-0x0;let _0x1bd424=a563_0xcfe0[_0x48ea4f];return _0x1bd424;};const _0x1450f7=a563_0x1bd4;'use strict';const db=require(_0x1450f7('0xd'))['db'],logger=require('../../config/logger')(_0x1450f7('0x2')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x1450f7('0x4'))[_0x1450f7('0xb')](socket),exports[_0x1450f7('0x9')]=function(_0x2509d3){const _0x4eecbf=this;return new Promise(function(_0x191830,_0x1503cf){const _0x5565de=a563_0x1bd4;return db[_0x5565de('0xa')][_0x5565de('0xc')](_0x2509d3[_0x5565de('0x1')],{'raw':_0x2509d3['options']?_0x2509d3[_0x5565de('0x8')][_0x5565de('0xe')]===undefined?!![]:![]:!![]})['then'](function(_0x380ad6){const _0x541fc8=_0x5565de;logger[_0x541fc8('0x7')](_0x541fc8('0x9'),_0x2509d3),logger['debug'](_0x541fc8('0x9'),_0x2509d3,JSON[_0x541fc8('0x5')](_0x380ad6)),_0x191830(_0x380ad6);})[_0x5565de('0x3')](function(_0x6065d7){const _0x4afb72=_0x5565de;logger['error'](_0x4afb72('0x9'),_0x6065d7['message'],_0x2509d3),_0x1503cf(_0x4eecbf[_0x4afb72('0x6')](0x1f4,_0x6065d7[_0x4afb72('0x0')]));});});}; \ No newline at end of file diff --git a/server/api/smsMessage/smsMessage.socket.js b/server/api/smsMessage/smsMessage.socket.js index e0ecd2a..cbaa4d9 100644 --- a/server/api/smsMessage/smsMessage.socket.js +++ b/server/api/smsMessage/smsMessage.socket.js @@ -1 +1 @@ -const a564_0x37ff=['smsMessage:','save','./smsMessage.events','register','emit','length'];(function(_0x379df1,_0x37ff0e){const _0x1ace29=function(_0x3528f6){while(--_0x3528f6){_0x379df1['push'](_0x379df1['shift']());}};_0x1ace29(++_0x37ff0e);}(a564_0x37ff,0x136));const a564_0x1ace=function(_0x379df1,_0x37ff0e){_0x379df1=_0x379df1-0x0;let _0x1ace29=a564_0x37ff[_0x379df1];return _0x1ace29;};const _0x12f7db=a564_0x1ace;'use strict';const SmsMessageEvents=require(_0x12f7db('0x4')),events=[_0x12f7db('0x3'),'remove','update'];function createListener(_0x3528f6,_0xabf858){return function(_0x193ec1){const _0x2fe41d=a564_0x1ace;_0xabf858[_0x2fe41d('0x0')](_0x3528f6,_0x193ec1);};}exports[_0x12f7db('0x5')]=function(_0x52b8ef){const _0x52462a=_0x12f7db;for(let _0x2346ac=0x0,_0x3bf77f=events[_0x52462a('0x1')];_0x2346ac<_0x3bf77f;_0x2346ac++){const _0x14fce5=events[_0x2346ac],_0x32bf71=createListener(_0x52462a('0x2')+_0x14fce5,_0x52b8ef);SmsMessageEvents['on'](_0x14fce5,_0x32bf71);}}; \ No newline at end of file +const a564_0x4cc9=['register','save','smsMessage:','update'];(function(_0x29afd5,_0x4cc921){const _0x8c839e=function(_0x272c76){while(--_0x272c76){_0x29afd5['push'](_0x29afd5['shift']());}};_0x8c839e(++_0x4cc921);}(a564_0x4cc9,0xd1));const a564_0x8c83=function(_0x29afd5,_0x4cc921){_0x29afd5=_0x29afd5-0x0;let _0x8c839e=a564_0x4cc9[_0x29afd5];return _0x8c839e;};const _0xfcc30b=a564_0x8c83;'use strict';const SmsMessageEvents=require('./smsMessage.events'),events=[_0xfcc30b('0x0'),'remove',_0xfcc30b('0x2')];function createListener(_0x272c76,_0x437839){return function(_0x284092){_0x437839['emit'](_0x272c76,_0x284092);};}exports[_0xfcc30b('0x3')]=function(_0x5a3628){const _0x127e0b=_0xfcc30b;for(let _0x57c174=0x0,_0x250a4a=events['length'];_0x57c174<_0x250a4a;_0x57c174++){const _0x2d9e11=events[_0x57c174],_0x6c23a1=createListener(_0x127e0b('0x1')+_0x2d9e11,_0x5a3628);SmsMessageEvents['on'](_0x2d9e11,_0x6c23a1);}}; \ No newline at end of file diff --git a/server/api/smsQueue/index.js b/server/api/smsQueue/index.js index 8b31841..3d53a72 100644 --- a/server/api/smsQueue/index.js +++ b/server/api/smsQueue/index.js @@ -1 +1 @@ -const a565_0x5a1c=['create','/describe','isAuthenticated','./smsQueue.controller','update','/:id/teams','exports','get','express','getMembers','removeAgents','show','/:id/users','getTeams','destroy','/:id','../../components/auth/service','Router','delete','post'];(function(_0x59848e,_0x5a1c10){const _0x1488b3=function(_0x209664){while(--_0x209664){_0x59848e['push'](_0x59848e['shift']());}};_0x1488b3(++_0x5a1c10);}(a565_0x5a1c,0xb1));const a565_0x1488=function(_0x59848e,_0x5a1c10){_0x59848e=_0x59848e-0x0;let _0x1488b3=a565_0x5a1c[_0x59848e];return _0x1488b3;};const _0x401dfb=a565_0x1488;'use strict';const express=require(_0x401dfb('0xb')),router=express[_0x401dfb('0x0')](),auth=require(_0x401dfb('0x13')),controller=require(_0x401dfb('0x6'));router['get']('/',auth[_0x401dfb('0x5')](),controller['index']),router[_0x401dfb('0xa')](_0x401dfb('0x4'),auth[_0x401dfb('0x5')](),controller['describe']),router[_0x401dfb('0xa')](_0x401dfb('0x12'),auth[_0x401dfb('0x5')](),controller[_0x401dfb('0xe')]),router[_0x401dfb('0xa')]('/:id/members',auth['isAuthenticated'](),controller[_0x401dfb('0xc')]),router[_0x401dfb('0xa')](_0x401dfb('0x8'),auth[_0x401dfb('0x5')](),controller[_0x401dfb('0x10')]),router[_0x401dfb('0xa')](_0x401dfb('0xf'),auth[_0x401dfb('0x5')](),controller['getAgents']),router['post']('/',auth[_0x401dfb('0x5')](),controller[_0x401dfb('0x3')]),router[_0x401dfb('0x2')](_0x401dfb('0x8'),auth['isAuthenticated'](),controller['addTeams']),router[_0x401dfb('0x2')](_0x401dfb('0xf'),auth[_0x401dfb('0x5')](),controller['addAgents']),router['put'](_0x401dfb('0x12'),auth[_0x401dfb('0x5')](),controller[_0x401dfb('0x7')]),router[_0x401dfb('0x1')](_0x401dfb('0x12'),auth['isAuthenticated'](),controller[_0x401dfb('0x11')]),router[_0x401dfb('0x1')](_0x401dfb('0x8'),auth[_0x401dfb('0x5')](),controller['removeTeams']),router[_0x401dfb('0x1')]('/:id/users',auth[_0x401dfb('0x5')](),controller[_0x401dfb('0xd')]),module[_0x401dfb('0x9')]=router; \ No newline at end of file +const a565_0x5b39=['put','/:id/teams','getMembers','/:id/users','express','update','/describe','create','describe','/:id','get','show','isAuthenticated','post','addTeams','destroy','delete','removeAgents','./smsQueue.controller'];(function(_0x59c14c,_0x5b3940){const _0x3e5c8d=function(_0xe8a650){while(--_0xe8a650){_0x59c14c['push'](_0x59c14c['shift']());}};_0x3e5c8d(++_0x5b3940);}(a565_0x5b39,0x168));const a565_0x3e5c=function(_0x59c14c,_0x5b3940){_0x59c14c=_0x59c14c-0x0;let _0x3e5c8d=a565_0x5b39[_0x59c14c];return _0x3e5c8d;};const _0x4fc5a4=a565_0x3e5c;'use strict';const express=require(_0x4fc5a4('0x5')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x4fc5a4('0x0'));router[_0x4fc5a4('0xb')]('/',auth['isAuthenticated'](),controller['index']),router['get'](_0x4fc5a4('0x7'),auth[_0x4fc5a4('0xd')](),controller[_0x4fc5a4('0x9')]),router[_0x4fc5a4('0xb')]('/:id',auth[_0x4fc5a4('0xd')](),controller[_0x4fc5a4('0xc')]),router[_0x4fc5a4('0xb')]('/:id/members',auth[_0x4fc5a4('0xd')](),controller[_0x4fc5a4('0x3')]),router['get']('/:id/teams',auth[_0x4fc5a4('0xd')](),controller['getTeams']),router['get'](_0x4fc5a4('0x4'),auth[_0x4fc5a4('0xd')](),controller['getAgents']),router[_0x4fc5a4('0xe')]('/',auth[_0x4fc5a4('0xd')](),controller[_0x4fc5a4('0x8')]),router[_0x4fc5a4('0xe')](_0x4fc5a4('0x2'),auth[_0x4fc5a4('0xd')](),controller[_0x4fc5a4('0xf')]),router[_0x4fc5a4('0xe')]('/:id/users',auth[_0x4fc5a4('0xd')](),controller['addAgents']),router[_0x4fc5a4('0x1')]('/:id',auth[_0x4fc5a4('0xd')](),controller[_0x4fc5a4('0x6')]),router['delete'](_0x4fc5a4('0xa'),auth[_0x4fc5a4('0xd')](),controller[_0x4fc5a4('0x10')]),router[_0x4fc5a4('0x11')](_0x4fc5a4('0x2'),auth[_0x4fc5a4('0xd')](),controller['removeTeams']),router[_0x4fc5a4('0x11')](_0x4fc5a4('0x4'),auth[_0x4fc5a4('0xd')](),controller[_0x4fc5a4('0x12')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/smsQueue/smsQueue.attributes.js b/server/api/smsQueue/smsQueue.attributes.js index 7bdae32..a951f7c 100644 --- a/server/api/smsQueue/smsQueue.attributes.js +++ b/server/api/smsQueue/smsQueue.attributes.js @@ -1 +1 @@ -const a566_0x2193=['exports','STRING','roundrobin','sequelize','name','INTEGER','ENUM','beepall','rrmemory'];(function(_0x2dfff2,_0x219314){const _0x313e72=function(_0x1a1fbd){while(--_0x1a1fbd){_0x2dfff2['push'](_0x2dfff2['shift']());}};_0x313e72(++_0x219314);}(a566_0x2193,0x133));const a566_0x313e=function(_0x2dfff2,_0x219314){_0x2dfff2=_0x2dfff2-0x0;let _0x313e72=a566_0x2193[_0x2dfff2];return _0x313e72;};const _0x5e7c9d=a566_0x313e;'use strict';const Sequelize=require(_0x5e7c9d('0x2'));module[_0x5e7c9d('0x8')]={'name':{'type':Sequelize[_0x5e7c9d('0x0')],'unique':_0x5e7c9d('0x3'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize[_0x5e7c9d('0x0')]},'timeout':{'type':Sequelize[_0x5e7c9d('0x4')],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x5e7c9d('0x5')](_0x5e7c9d('0x7'),_0x5e7c9d('0x6'),_0x5e7c9d('0x1'))}}; \ No newline at end of file +const a566_0x3011=['name','rrmemory','ENUM','exports','STRING','sequelize','INTEGER','roundrobin'];(function(_0x5bca5e,_0x30118b){const _0x411653=function(_0x14390b){while(--_0x14390b){_0x5bca5e['push'](_0x5bca5e['shift']());}};_0x411653(++_0x30118b);}(a566_0x3011,0x1b0));const a566_0x4116=function(_0x5bca5e,_0x30118b){_0x5bca5e=_0x5bca5e-0x0;let _0x411653=a566_0x3011[_0x5bca5e];return _0x411653;};const _0x360ece=a566_0x4116;'use strict';const Sequelize=require(_0x360ece('0x5'));module[_0x360ece('0x3')]={'name':{'type':Sequelize['STRING'],'unique':_0x360ece('0x0'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'description':{'type':Sequelize[_0x360ece('0x4')]},'timeout':{'type':Sequelize[_0x360ece('0x6')],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x360ece('0x2')](_0x360ece('0x1'),'beepall',_0x360ece('0x7'))}}; \ No newline at end of file diff --git a/server/api/smsQueue/smsQueue.controller.js b/server/api/smsQueue/smsQueue.controller.js index c954ad6..362f7ec 100644 --- a/server/api/smsQueue/smsQueue.controller.js +++ b/server/api/smsQueue/smsQueue.controller.js @@ -1 +1 @@ -const a567_0x361d=['../../config/logger','addAgents','like','SmsQueue','userSmsQueue:remove','UserProfileSection','isArray','createdAt','params','flatMap','findAll','describe','filters','each','%s/%s','api','TeamId','options','every','query','findAndCountAll','interface','ids','findOrCreate','offset','field','index','fieldName','nolimit','push','order','count','type','length','where','Unable\x20to\x20retrieve\x20the\x20current\x20user','Content-Range','lodash','update','tq.TeamId','set','catch','merge','UserSmsQueue','agent','User','union','clone','all','getAgents','addTeams','limit','updatedAt','intersection','SIP','user','isEmpty','SELECT','json','removeAgents','Agents','error','attributes','Team','send','body','show','util','findOne','create','emit','sendStatus','UserProfileResource','getTeams','toString','removeTeams','autoAssociation','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','stack','includes','../../rediscache','ut.TeamId\x20=\x20tq.TeamId','getMembers','transaction','../../components/parsers/qs','status','model','get','rows','filter','value','then','userSmsQueue:save','../../mysqldb','role','destroy','register','pick','undefined','select','keys','sort','map','fields','UserId','rawAttributes','VIRTUAL','userProfileId','omit','sequelize','smsPause','end','includeAll','name'];(function(_0x4aaf38,_0x361dab){const _0x536c64=function(_0x5f4ab9){while(--_0x5f4ab9){_0x4aaf38['push'](_0x4aaf38['shift']());}};_0x536c64(++_0x361dab);}(a567_0x361d,0x134));const a567_0x536c=function(_0x4aaf38,_0x361dab){_0x4aaf38=_0x4aaf38-0x0;let _0x536c64=a567_0x361d[_0x4aaf38];return _0x536c64;};const _0x545801=a567_0x536c;'use strict';const util=require(_0x545801('0x65')),_=require(_0x545801('0x47')),squel=require('squel'),qs=require(_0x545801('0x4')),logger=require(_0x545801('0x22'))(_0x545801('0x31')),{getSocket}=require(_0x545801('0x0')),socket=getSocket(),db=require(_0x545801('0xd'))['db'],{Op,QueryTypes}=require('sequelize');require('./smsQueue.socket')[_0x545801('0x10')](socket);function respondWithStatusCode(_0x5f4ab9,_0x411484){return _0x411484=_0x411484||0xcc,function(_0x1844c6){const _0x377233=a567_0x536c;if(_0x1844c6)return _0x5f4ab9[_0x377233('0x69')](_0x411484);return _0x5f4ab9[_0x377233('0x5')](_0x411484)[_0x377233('0x1f')]();};}function respondWithResult(_0x5cda7b,_0x2fd5d8){return _0x2fd5d8=_0x2fd5d8||0xc8,function(_0x1da6df){const _0x4eabe1=a567_0x536c;if(_0x1da6df)return _0x5cda7b[_0x4eabe1('0x5')](_0x2fd5d8)[_0x4eabe1('0x5c')](_0x1da6df);};}function respondWithFilteredResult(_0x56b924,_0x3a5a04){return function(_0x1a66bb){const _0x5d1344=a567_0x536c;if(_0x1a66bb){const _0x1d7ea8=_0x1a66bb[_0x5d1344('0x41')],_0x352d3d=_0x3a5a04[_0x5d1344('0x3a')];let _0x8ba17e=_0x3a5a04['offset']+_0x3a5a04['limit'],_0x44865b;return _0x8ba17e>=_0x1d7ea8?(_0x8ba17e=_0x1d7ea8,_0x44865b=0xc8):_0x44865b=0xce,_0x56b924['status'](_0x44865b),_0x56b924[_0x5d1344('0x4a')](_0x5d1344('0x46'),_0x352d3d+'-'+_0x8ba17e+'/'+_0x1d7ea8)[_0x5d1344('0x5c')](_0x1a66bb);}return null;};}function saveUpdates(_0x5d6463){return function(_0x54601e){const _0x3409d0=a567_0x536c;if(_0x54601e)return _0x54601e[_0x3409d0('0x48')](_0x5d6463)['then'](function(_0x848091){return _0x848091;});return null;};}function removeEntity(_0x2b5506){return function(_0x426c7d){const _0x4355d0=a567_0x536c;if(_0x426c7d)return _0x426c7d[_0x4355d0('0xf')]()['then'](function(){const _0x2e394b=_0x4355d0,_0x59a317=_0x426c7d[_0x2e394b('0x7')]({'plain':!![]}),_0x1943c4='SmsQueues';return db['UserProfileResource'][_0x2e394b('0xf')]({'where':{'type':_0x1943c4,'resourceId':_0x59a317['id']}})[_0x2e394b('0xb')](function(){return _0x426c7d;});})[_0x4355d0('0xb')](function(){_0x2b5506['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x439f4a){return function(_0x35da74){const _0x3e529f=a567_0x536c;return!_0x35da74&&_0x439f4a[_0x3e529f('0x69')](0x194),_0x35da74;};}function handleError(_0x342117,_0x1dfd87){return _0x1dfd87=_0x1dfd87||0x1f4,function(_0x2e8d9a){const _0x40b6f6=a567_0x536c;logger['error'](_0x2e8d9a[_0x40b6f6('0x70')]),_0x2e8d9a[_0x40b6f6('0x21')]&&delete _0x2e8d9a[_0x40b6f6('0x21')],_0x342117[_0x40b6f6('0x5')](_0x1dfd87)[_0x40b6f6('0x62')](_0x2e8d9a);};}exports[_0x545801('0x3c')]=function(_0x246e90,_0x16e6fe){const _0x10c415=_0x545801;let _0x43cbbd={};const _0x40a5d3={},_0x505661={'count':0x0,'rows':[]},_0x44c5c4=_[_0x10c415('0x16')](db['SmsQueue'][_0x10c415('0x19')],function(_0x49f2d3){const _0x548e2e=_0x10c415;return{'name':_0x49f2d3[_0x548e2e('0x3d')],'type':_0x49f2d3['type']['key']};});_0x40a5d3[_0x10c415('0x6')]=_[_0x10c415('0x16')](_0x44c5c4,_0x10c415('0x21')),_0x40a5d3[_0x10c415('0x35')]=_[_0x10c415('0x14')](_0x246e90[_0x10c415('0x35')]),_0x40a5d3['filters']=_[_0x10c415('0x57')](_0x40a5d3[_0x10c415('0x6')],_0x40a5d3[_0x10c415('0x35')]),_0x43cbbd[_0x10c415('0x60')]=_[_0x10c415('0x57')](_0x40a5d3[_0x10c415('0x6')],qs[_0x10c415('0x17')](_0x246e90[_0x10c415('0x35')]['fields'])),_0x43cbbd['attributes']=_0x43cbbd['attributes']['length']?_0x43cbbd[_0x10c415('0x60')]:_0x40a5d3[_0x10c415('0x6')];typeof _0x246e90[_0x10c415('0x35')][_0x10c415('0x3e')]===_0x10c415('0x12')&&(_0x43cbbd['limit']=qs[_0x10c415('0x55')](_0x246e90[_0x10c415('0x35')]['limit']),_0x43cbbd[_0x10c415('0x3a')]=qs[_0x10c415('0x3a')](_0x246e90['query'][_0x10c415('0x3a')]));_0x43cbbd[_0x10c415('0x40')]=qs[_0x10c415('0x15')](_0x246e90[_0x10c415('0x35')]['sort']),_0x43cbbd[_0x10c415('0x44')]=qs[_0x10c415('0x2e')](_['pick'](_0x246e90[_0x10c415('0x35')],_0x40a5d3['filters']),_0x44c5c4);_0x246e90[_0x10c415('0x35')]['filter']&&(_0x43cbbd[_0x10c415('0x44')]=_['merge'](_0x43cbbd['where'],{[Op['or']]:_[_0x10c415('0x16')](_0x44c5c4,function(_0x3ac654){const _0x4cf5e0=_0x10c415;if(_0x3ac654[_0x4cf5e0('0x42')]!==_0x4cf5e0('0x1a')){const _0xf978be={};return _0xf978be[_0x3ac654[_0x4cf5e0('0x21')]]={[Op[_0x4cf5e0('0x24')]]:'%'+_0x246e90[_0x4cf5e0('0x35')][_0x4cf5e0('0x9')]+'%'},_0xf978be;}})}));_0x43cbbd=_[_0x10c415('0x4c')]({},_0x43cbbd,_0x246e90[_0x10c415('0x33')]);const _0x70b7ab={'where':_0x43cbbd['where']};return db[_0x10c415('0x25')][_0x10c415('0x41')](_0x70b7ab)[_0x10c415('0xb')](function(_0x3201c8){const _0x5a42cb=_0x10c415;return _0x505661[_0x5a42cb('0x41')]=_0x3201c8,_0x246e90[_0x5a42cb('0x35')][_0x5a42cb('0x20')]&&(_0x43cbbd['include']=[{'all':!![]}]),db[_0x5a42cb('0x25')][_0x5a42cb('0x2c')](_0x43cbbd);})[_0x10c415('0xb')](function(_0xf6e4a0){const _0x20e58a=_0x10c415;return _0x505661[_0x20e58a('0x8')]=_0xf6e4a0,_0x505661;})[_0x10c415('0xb')](respondWithFilteredResult(_0x16e6fe,_0x43cbbd))[_0x10c415('0x4b')](handleError(_0x16e6fe,null));},exports[_0x545801('0x64')]=function(_0x9503f6,_0x4b68b1){const _0xb136c2=_0x545801;let _0x9ac47c={'raw':!![],'where':{'id':_0x9503f6[_0xb136c2('0x2a')]['id']}};const _0x4f11b0={};return _0x4f11b0['model']=_[_0xb136c2('0x14')](db['SmsQueue'][_0xb136c2('0x19')]),_0x4f11b0[_0xb136c2('0x35')]=_[_0xb136c2('0x14')](_0x9503f6[_0xb136c2('0x35')]),_0x4f11b0['filters']=_['intersection'](_0x4f11b0[_0xb136c2('0x6')],_0x4f11b0['query']),_0x9ac47c[_0xb136c2('0x60')]=_[_0xb136c2('0x57')](_0x4f11b0[_0xb136c2('0x6')],qs[_0xb136c2('0x17')](_0x9503f6['query'][_0xb136c2('0x17')])),_0x9ac47c[_0xb136c2('0x60')]=_0x9ac47c[_0xb136c2('0x60')][_0xb136c2('0x43')]?_0x9ac47c['attributes']:_0x4f11b0['model'],_0x9503f6[_0xb136c2('0x35')][_0xb136c2('0x20')]&&(_0x9ac47c['include']=[{'all':!![]}]),_0x9ac47c=_['merge']({},_0x9ac47c,_0x9503f6[_0xb136c2('0x33')]),db[_0xb136c2('0x25')][_0xb136c2('0x66')](_0x9ac47c)['then'](handleEntityNotFound(_0x4b68b1,null))[_0xb136c2('0xb')](respondWithResult(_0x4b68b1,null))[_0xb136c2('0x4b')](handleError(_0x4b68b1,null));},exports['create']=function(_0x35da3a,_0x160940){const _0x12b8c6=_0x545801;return db[_0x12b8c6('0x25')]['create'](_0x35da3a[_0x12b8c6('0x63')],{})[_0x12b8c6('0xb')](function(_0x265816){const _0x582ebe=_0x12b8c6,_0x5d836e=_0x35da3a[_0x582ebe('0x59')][_0x582ebe('0x7')]({'plain':!![]});if(!_0x5d836e)throw new Error(_0x582ebe('0x45'));if(_0x5d836e[_0x582ebe('0xe')]===_0x582ebe('0x59')){const _0x3e0f6f=_0x265816[_0x582ebe('0x7')]({'plain':!![]}),_0x154d80='SmsQueues';return db[_0x582ebe('0x27')][_0x582ebe('0x66')]({'where':{'name':_0x154d80,'userProfileId':_0x5d836e[_0x582ebe('0x1b')]},'raw':!![]})[_0x582ebe('0xb')](function(_0x185274){const _0x41ba2b=_0x582ebe;return _0x185274&&_0x185274[_0x41ba2b('0x6e')]===0x0?db[_0x41ba2b('0x6a')][_0x41ba2b('0x67')]({'name':_0x3e0f6f['name'],'resourceId':_0x3e0f6f['id'],'type':_0x185274[_0x41ba2b('0x21')],'sectionId':_0x185274['id']},{})[_0x41ba2b('0xb')](function(){return _0x265816;}):_0x265816;})[_0x582ebe('0x4b')](function(_0x5d22a1){const _0x59d069=_0x582ebe;logger[_0x59d069('0x5f')](_0x59d069('0x6f'),_0x5d22a1);throw _0x5d22a1;});}return _0x265816;})[_0x12b8c6('0xb')](respondWithResult(_0x160940,0xc9))[_0x12b8c6('0x4b')](handleError(_0x160940,null));},exports[_0x545801('0x48')]=function(_0xc374d7,_0x56bac7){const _0xa70162=_0x545801;return _0xc374d7[_0xa70162('0x63')]['id']&&delete _0xc374d7['body']['id'],db['SmsQueue']['findOne']({'where':{'id':_0xc374d7['params']['id']}})['then'](handleEntityNotFound(_0x56bac7,null))[_0xa70162('0xb')](saveUpdates(_0xc374d7[_0xa70162('0x63')],null))[_0xa70162('0xb')](respondWithResult(_0x56bac7,null))['catch'](handleError(_0x56bac7,null));},exports[_0x545801('0xf')]=function(_0x50d1cd,_0x236c81){const _0x77acf5=_0x545801;return db[_0x77acf5('0x25')][_0x77acf5('0x66')]({'where':{'id':_0x50d1cd[_0x77acf5('0x2a')]['id']}})['then'](handleEntityNotFound(_0x236c81,null))[_0x77acf5('0xb')](removeEntity(_0x236c81,null))[_0x77acf5('0x4b')](handleError(_0x236c81,null));},exports[_0x545801('0x2d')]=function(_0x2af161,_0xb6cb08){const _0x2aa510=_0x545801;return db[_0x2aa510('0x25')][_0x2aa510('0x2d')]()[_0x2aa510('0xb')](respondWithResult(_0xb6cb08,null))[_0x2aa510('0x4b')](handleError(_0xb6cb08,null));},exports[_0x545801('0x2')]=function(_0x23b892,_0x3781ac){const _0x143654=_0x545801;let _0x2cfc30={'raw':!![],'where':{}};const _0x1839ac={};let _0x3f95c8;return db[_0x143654('0x25')]['findOne']({'where':{'id':_0x23b892[_0x143654('0x2a')]['id']}})[_0x143654('0xb')](handleEntityNotFound(_0x3781ac,null))[_0x143654('0xb')](function(_0x2951f1){const _0x2dc9dc=_0x143654;if(_0x2951f1)return _0x3f95c8=_0x2951f1['get']({'plain':!![]}),_0x1839ac[_0x2dc9dc('0x6')]=_[_0x2dc9dc('0x14')](db['UserSmsQueue'][_0x2dc9dc('0x19')]),_0x1839ac[_0x2dc9dc('0x35')]=_[_0x2dc9dc('0x14')](_0x23b892[_0x2dc9dc('0x35')]),_0x1839ac[_0x2dc9dc('0x2e')]=_[_0x2dc9dc('0x57')](_0x1839ac['model'],_0x1839ac[_0x2dc9dc('0x35')]),_0x2cfc30['attributes']=_['intersection'](_0x1839ac['model'],qs[_0x2dc9dc('0x17')](_0x23b892['query'][_0x2dc9dc('0x17')])),_0x2cfc30[_0x2dc9dc('0x60')]=_0x2cfc30['attributes'][_0x2dc9dc('0x43')]?_0x2cfc30[_0x2dc9dc('0x60')]:_0x1839ac[_0x2dc9dc('0x6')],typeof _0x23b892[_0x2dc9dc('0x35')][_0x2dc9dc('0x3e')]===_0x2dc9dc('0x12')&&(_0x2cfc30[_0x2dc9dc('0x55')]=qs[_0x2dc9dc('0x55')](_0x23b892[_0x2dc9dc('0x35')][_0x2dc9dc('0x55')]),_0x2cfc30[_0x2dc9dc('0x3a')]=qs[_0x2dc9dc('0x3a')](_0x23b892[_0x2dc9dc('0x35')][_0x2dc9dc('0x3a')])),_0x2cfc30[_0x2dc9dc('0x40')]=qs['sort'](_0x23b892[_0x2dc9dc('0x35')]['sort']),_0x2cfc30[_0x2dc9dc('0x44')]=qs[_0x2dc9dc('0x2e')](_[_0x2dc9dc('0x11')](_0x23b892[_0x2dc9dc('0x35')],_0x1839ac[_0x2dc9dc('0x2e')])),_0x2cfc30['where']['SmsQueueId']=_0x2951f1['id'],_0x23b892[_0x2dc9dc('0x35')][_0x2dc9dc('0x9')]&&(_0x2cfc30['where']=_[_0x2dc9dc('0x4c')](_0x2cfc30['where'],{[Op['or']]:_['map'](_0x2cfc30[_0x2dc9dc('0x60')],function(_0x1de819){const _0x5c9dc0=_0x2dc9dc,_0x10e270={};return _0x10e270[_0x1de819]={[Op[_0x5c9dc0('0x24')]]:'%'+_0x23b892[_0x5c9dc0('0x35')][_0x5c9dc0('0x9')]+'%'},_0x10e270;})})),_0x2cfc30=_[_0x2dc9dc('0x4c')]({},_0x2cfc30,_0x23b892['options']),db[_0x2dc9dc('0x4d')][_0x2dc9dc('0x2c')](_0x2cfc30);})[_0x143654('0xb')](function(_0x9deecc){const _0x1c9d09=_0x143654;if(_0x9deecc)return db['User'][_0x1c9d09('0x36')]({'where':{'id':_[_0x1c9d09('0x16')](_0x9deecc,_0x1c9d09('0x18')),'role':_0x1c9d09('0x4e')},'attributes':['id',_0x1c9d09('0x21'),_0x1c9d09('0x1e'),_0x1c9d09('0x56'),_0x1c9d09('0x29')]});})['then'](function(_0x4f19d7){const _0xb8798=_0x143654;return _0x4f19d7?{'count':_0x4f19d7[_0xb8798('0x41')],'rows':_[_0xb8798('0x16')](_0x4f19d7[_0xb8798('0x8')],function(_0x3f9eb3){const _0x4733a8=_0xb8798;return{'membername':_0x3f9eb3[_0x4733a8('0x21')],'UserId':_0x3f9eb3['id'],'queue_name':_0x3f95c8[_0x4733a8('0x21')],'SmsQueueId':_0x3f95c8['id'],'interface':util['format'](_0x4733a8('0x30'),_0x4733a8('0x58'),_0x3f9eb3[_0x4733a8('0x21')]),'penalty':0x0,'paused':_0x3f9eb3[_0x4733a8('0x1e')],'createdAt':_0x3f9eb3[_0x4733a8('0x29')],'updatedAt':_0x3f9eb3[_0x4733a8('0x56')]};})}:{'count':0x0,'rows':[]};})[_0x143654('0xb')](respondWithFilteredResult(_0x3781ac,_0x2cfc30))[_0x143654('0x4b')](handleError(_0x3781ac,null));},exports[_0x545801('0x6b')]=function(_0xb4d600,_0x11b881){const _0x4498bb=_0x545801;let _0x4e125b={};const _0x36fa32={};let _0xd04582,_0x42046a;return db[_0x4498bb('0x25')]['findOne']({'where':{'id':_0xb4d600[_0x4498bb('0x2a')]['id']}})[_0x4498bb('0xb')](handleEntityNotFound(_0x11b881,null))[_0x4498bb('0xb')](function(_0x4354f4){const _0x3596a0=_0x4498bb;if(_0x4354f4)return _0xd04582=_0x4354f4,_0x36fa32[_0x3596a0('0x6')]=_['keys'](db['Team'][_0x3596a0('0x19')]),_0x36fa32['query']=_[_0x3596a0('0x14')](_0xb4d600[_0x3596a0('0x35')]),_0x36fa32[_0x3596a0('0x2e')]=_[_0x3596a0('0x57')](_0x36fa32[_0x3596a0('0x6')],_0x36fa32['query']),_0x4e125b[_0x3596a0('0x60')]=_[_0x3596a0('0x57')](_0x36fa32[_0x3596a0('0x6')],qs[_0x3596a0('0x17')](_0xb4d600[_0x3596a0('0x35')][_0x3596a0('0x17')])),_0x4e125b['attributes']=_0x4e125b[_0x3596a0('0x60')][_0x3596a0('0x43')]?_0x4e125b['attributes']:_0x36fa32[_0x3596a0('0x6')],_0x4e125b[_0x3596a0('0x40')]=qs[_0x3596a0('0x15')](_0xb4d600[_0x3596a0('0x35')]['sort']),_0x4e125b[_0x3596a0('0x44')]=qs[_0x3596a0('0x2e')](_[_0x3596a0('0x11')](_0xb4d600['query'],_0x36fa32[_0x3596a0('0x2e')])),_0xb4d600[_0x3596a0('0x35')][_0x3596a0('0x9')]&&(_0x4e125b[_0x3596a0('0x44')]=_[_0x3596a0('0x4c')](_0x4e125b[_0x3596a0('0x44')],{[Op['or']]:_['map'](_0x4e125b['attributes'],function(_0x55a067){const _0x1bee6b=_0x3596a0,_0x45f34d={};return _0x45f34d[_0x55a067]={[Op[_0x1bee6b('0x24')]]:'%'+_0xb4d600[_0x1bee6b('0x35')][_0x1bee6b('0x9')]+'%'},_0x45f34d;})})),_0x4e125b=_[_0x3596a0('0x4c')]({},_0x4e125b,_0xb4d600[_0x3596a0('0x33')]),_0xd04582['getTeams'](_0x4e125b);})[_0x4498bb('0xb')](function(_0x3e58b0){const _0x1c323f=_0x4498bb;if(_0x3e58b0)return _0x42046a=_0x3e58b0[_0x1c323f('0x43')],typeof _0xb4d600[_0x1c323f('0x35')]['nolimit']===_0x1c323f('0x12')&&(_0x4e125b[_0x1c323f('0x55')]=qs['limit'](_0xb4d600[_0x1c323f('0x35')][_0x1c323f('0x55')]),_0x4e125b[_0x1c323f('0x3a')]=qs[_0x1c323f('0x3a')](_0xb4d600[_0x1c323f('0x35')][_0x1c323f('0x3a')])),_0xd04582['getTeams'](_0x4e125b);})[_0x4498bb('0xb')](function(_0x338856){if(_0x338856)return _0x338856?{'count':_0x42046a,'rows':_0x338856}:null;})[_0x4498bb('0xb')](respondWithResult(_0x11b881,null))['catch'](handleError(_0x11b881,null));},exports[_0x545801('0x54')]=function(_0x328c43,_0x2ccdea){const _0x8120b0=_0x545801,_0x27535f=_0x328c43['body'][_0x8120b0('0x38')];return db[_0x8120b0('0x61')][_0x8120b0('0x2c')]({'where':{'id':_0x27535f},'attributes':['id'],'include':[{'model':db[_0x8120b0('0x4f')],'as':_0x8120b0('0x5e'),'attributes':['id','name','online','voicePause',_0x8120b0('0x37')],'raw':!![]}]})['then'](function(_0x6b9f0d){const _0x513dca=_0x8120b0;if(_0x6b9f0d){const _0x21459e=_[_0x513dca('0x2b')](_0x6b9f0d,function(_0x1efc8b){const _0x582d6d=_0x513dca,_0x481d0d=_0x1efc8b[_0x582d6d('0x7')]({'plain':!![]});return _0x481d0d[_0x582d6d('0x5e')];});return db[_0x513dca('0x25')][_0x513dca('0x66')]({'where':{'id':_0x328c43[_0x513dca('0x2a')]['id']}})['then'](function(_0x5212bb){const _0x53fbc2=_0x513dca;return db[_0x53fbc2('0x1d')]['transaction'](function(_0x3167da){const _0x2dcd96=_0x53fbc2;return _0x5212bb['addTeams'](_0x27535f,{'transaction':_0x3167da})[_0x2dcd96('0xb')](function(){const _0x317e20=_0x2dcd96;return Promise[_0x317e20('0x2f')](_0x21459e,function(_0x437e10){const _0x2c845e=_0x317e20;return db[_0x2c845e('0x4d')][_0x2c845e('0x39')]({'where':{'UserId':_0x437e10['id'],'SmsQueueId':_0x328c43['params']['id']},'transaction':_0x3167da});});})[_0x2dcd96('0xb')](function(){_0x21459e['forEach'](function(_0x423191){socket['emit']('userSmsQueue:save',{'UserId':_0x423191['id'],'SmsQueueId':_0x5212bb['id']});});});});});}})[_0x8120b0('0xb')](respondWithStatusCode(_0x2ccdea,null))['catch'](handleError(_0x2ccdea,null));},exports[_0x545801('0x6d')]=function(_0x5e139e,_0x1d55f4){const _0x25099a=_0x545801;return db[_0x25099a('0x61')][_0x25099a('0x2c')]({'where':{'id':_0x5e139e[_0x25099a('0x35')][_0x25099a('0x38')]},'attributes':['id'],'include':[{'model':db[_0x25099a('0x4f')],'as':_0x25099a('0x5e'),'attributes':['id'],'raw':!![]}]})[_0x25099a('0xb')](handleEntityNotFound(_0x1d55f4,null))[_0x25099a('0xb')](function(_0x4fa6cb){const _0x4ed4c1=_0x25099a,_0x53f2de=_[_0x4ed4c1('0x16')](_0x4fa6cb,'id');let _0x27c126=[];const _0x44430c=[],_0x21c84c=squel[_0x4ed4c1('0x13')]();_0x21c84c[_0x4ed4c1('0x3b')](_0x4ed4c1('0x49'))['from']('team_has_sms_queues','tq')['join']('user_has_teams','ut',_0x4ed4c1('0x1'))[_0x4ed4c1('0x44')]('SmsQueueId\x20=\x20?',_0x5e139e[_0x4ed4c1('0x2a')]['id']);for(let _0x2b2832=0x0;_0x2b2832<_0x4fa6cb[_0x4ed4c1('0x43')];_0x2b2832+=0x1){const _0x3736bf=_0x4fa6cb[_0x2b2832];for(let _0x468fc0=0x0;_0x468fc0<_0x3736bf[_0x4ed4c1('0x5e')][_0x4ed4c1('0x43')];_0x468fc0+=0x1){const _0x110e9f=_0x3736bf[_0x4ed4c1('0x5e')][_0x468fc0],_0x191c54=_0x21c84c[_0x4ed4c1('0x51')]();_0x191c54[_0x4ed4c1('0x44')]('ut.UserId\x20=\x20?',_0x110e9f['id']),_0x44430c[_0x4ed4c1('0x3f')](db[_0x4ed4c1('0x1d')][_0x4ed4c1('0x35')](_0x191c54[_0x4ed4c1('0x6c')](),{'type':QueryTypes[_0x4ed4c1('0x5b')]})[_0x4ed4c1('0xb')](function(_0x3ae529){const _0x47ab10=_0x4ed4c1;if(_0x3ae529[_0x47ab10('0x43')]===0x1)return _0x110e9f['id'];else{const _0x250437=_[_0x47ab10('0x34')](_['map'](_0x3ae529,_0x47ab10('0x32')),function(_0x5562a1){const _0x540e23=_0x47ab10;return _[_0x540e23('0x71')](_0x53f2de,_0x5562a1);});if(_0x250437)return _0x110e9f['id'];}}));}}return Promise[_0x4ed4c1('0x52')](_0x44430c)[_0x4ed4c1('0xb')](function(_0x3cbe93){const _0x9c2f9c=_0x4ed4c1;return _0x27c126=_(_0x27c126)[_0x9c2f9c('0x50')](_0x3cbe93)['compact']()[_0x9c2f9c('0xa')](),db[_0x9c2f9c('0x25')][_0x9c2f9c('0x66')]({'where':{'id':_0x5e139e[_0x9c2f9c('0x2a')]['id']}})['then'](function(_0x427b1e){const _0x2edb2d=_0x9c2f9c;return db[_0x2edb2d('0x1d')][_0x2edb2d('0x3')](function(_0x360a0c){const _0x3f8d3f=_0x2edb2d;return _0x427b1e[_0x3f8d3f('0x6d')](_0x5e139e['query'][_0x3f8d3f('0x38')],{'transaction':_0x360a0c})['then'](function(){const _0x20919f=_0x3f8d3f;if(!_[_0x20919f('0x5a')](_0x27c126))return _0x427b1e['removeAgents'](_0x27c126,{'transaction':_0x360a0c});})[_0x3f8d3f('0xb')](function(){_0x27c126['forEach'](function(_0x5efa81){const _0xd99485=a567_0x536c;socket['emit'](_0xd99485('0x26'),{'UserId':_0x5efa81,'SmsQueueId':_0x427b1e['id']});});});});});});})[_0x25099a('0xb')](respondWithStatusCode(_0x1d55f4,null))['catch'](handleError(_0x1d55f4,null));},exports[_0x545801('0x23')]=function(_0x3a2fec,_0x2bca15){const _0x30b76a=_0x545801;return db[_0x30b76a('0x25')][_0x30b76a('0x66')]({'where':{'id':_0x3a2fec[_0x30b76a('0x2a')]['id']}})[_0x30b76a('0xb')](function(_0x21e696){const _0x218255=_0x30b76a;if(_0x21e696)return _0x21e696[_0x218255('0x23')](_0x3a2fec[_0x218255('0x63')][_0x218255('0x38')],{'through':_[_0x218255('0x1c')](_0x3a2fec[_0x218255('0x63')],[_0x218255('0x38'),'id'])})['then'](function(_0x5ae4a5){const _0x15adfa=_0x218255;for(let _0x2a72f1=0x0;_0x2a72f1<_0x3a2fec[_0x15adfa('0x63')]['ids']['length'];_0x2a72f1+=0x1){socket[_0x15adfa('0x68')](_0x15adfa('0xc'),{'UserId':_0x3a2fec[_0x15adfa('0x63')][_0x15adfa('0x38')][_0x2a72f1],'SmsQueueId':_0x3a2fec[_0x15adfa('0x2a')]['id']});}return _0x5ae4a5;});})[_0x30b76a('0xb')](respondWithResult(_0x2bca15,null))[_0x30b76a('0x4b')](handleError(_0x2bca15,null));},exports['removeAgents']=function(_0x5e803c,_0x319264){const _0xe7c2ef=_0x545801;return db['SmsQueue'][_0xe7c2ef('0x66')]({'where':{'id':_0x5e803c['params']['id']}})[_0xe7c2ef('0xb')](handleEntityNotFound(_0x319264,null))[_0xe7c2ef('0xb')](function(_0x1e65ac){const _0x3f87ad=_0xe7c2ef;if(_0x1e65ac)return _0x1e65ac[_0x3f87ad('0x5d')](_0x5e803c[_0x3f87ad('0x35')]['ids'])['then'](function(){const _0x296643=_0x3f87ad;if(_[_0x296643('0x28')](_0x5e803c[_0x296643('0x35')][_0x296643('0x38')]))for(let _0x4112fc=0x0;_0x4112fc<_0x5e803c[_0x296643('0x35')][_0x296643('0x38')][_0x296643('0x43')];_0x4112fc+=0x1){socket[_0x296643('0x68')](_0x296643('0x26'),{'UserId':Number(_0x5e803c['query']['ids'][_0x4112fc]),'SmsQueueId':Number(_0x5e803c[_0x296643('0x2a')]['id'])});}else socket['emit'](_0x296643('0x26'),{'UserId':Number(_0x5e803c[_0x296643('0x35')][_0x296643('0x38')]),'SmsQueueId':Number(_0x5e803c[_0x296643('0x2a')]['id'])});});})[_0xe7c2ef('0xb')](respondWithStatusCode(_0x319264,null))[_0xe7c2ef('0x4b')](handleError(_0x319264,null));},exports[_0x545801('0x53')]=function(_0x473408,_0x20dcac){const _0x59ce78=_0x545801;let _0x3900de={};const _0xe90b1b={};let _0x18ccd7,_0x456bce;return db[_0x59ce78('0x25')][_0x59ce78('0x66')]({'where':{'id':_0x473408[_0x59ce78('0x2a')]['id']}})[_0x59ce78('0xb')](handleEntityNotFound(_0x20dcac,null))[_0x59ce78('0xb')](function(_0x2a5b85){const _0x1b6761=_0x59ce78;if(_0x2a5b85)return _0x18ccd7=_0x2a5b85,_0xe90b1b[_0x1b6761('0x6')]=_[_0x1b6761('0x14')](db[_0x1b6761('0x4f')]['rawAttributes']),_0xe90b1b[_0x1b6761('0x35')]=_[_0x1b6761('0x14')](_0x473408['query']),_0xe90b1b[_0x1b6761('0x2e')]=_[_0x1b6761('0x57')](_0xe90b1b[_0x1b6761('0x6')],_0xe90b1b['query']),_0x3900de[_0x1b6761('0x60')]=_[_0x1b6761('0x57')](_0xe90b1b[_0x1b6761('0x6')],qs['fields'](_0x473408['query'][_0x1b6761('0x17')])),_0x3900de['attributes']=_0x3900de[_0x1b6761('0x60')][_0x1b6761('0x43')]?_0x3900de[_0x1b6761('0x60')]:_0xe90b1b[_0x1b6761('0x6')],_0x3900de[_0x1b6761('0x40')]=qs['sort'](_0x473408[_0x1b6761('0x35')][_0x1b6761('0x15')]),_0x3900de[_0x1b6761('0x44')]=qs[_0x1b6761('0x2e')](_[_0x1b6761('0x11')](_0x473408[_0x1b6761('0x35')],_0xe90b1b['filters'])),_0x473408[_0x1b6761('0x35')][_0x1b6761('0x9')]&&(_0x3900de[_0x1b6761('0x44')]=_[_0x1b6761('0x4c')](_0x3900de[_0x1b6761('0x44')],{[Op['or']]:_[_0x1b6761('0x16')](_0x3900de[_0x1b6761('0x60')],function(_0x191d81){const _0x56a05a=_0x1b6761,_0x538983={};return _0x538983[_0x191d81]={[Op[_0x56a05a('0x24')]]:'%'+_0x473408[_0x56a05a('0x35')][_0x56a05a('0x9')]+'%'},_0x538983;})})),_0x3900de=_[_0x1b6761('0x4c')]({},_0x3900de,_0x473408[_0x1b6761('0x33')]),_0x18ccd7[_0x1b6761('0x53')](_0x3900de);})[_0x59ce78('0xb')](function(_0x20e385){const _0x5d9ad1=_0x59ce78;if(_0x20e385)return _0x456bce=_0x20e385[_0x5d9ad1('0x43')],typeof _0x473408[_0x5d9ad1('0x35')]['nolimit']===_0x5d9ad1('0x12')&&(_0x3900de[_0x5d9ad1('0x55')]=qs[_0x5d9ad1('0x55')](_0x473408[_0x5d9ad1('0x35')][_0x5d9ad1('0x55')]),_0x3900de['offset']=qs[_0x5d9ad1('0x3a')](_0x473408['query']['offset'])),_0x18ccd7[_0x5d9ad1('0x53')](_0x3900de);})[_0x59ce78('0xb')](function(_0x335d71){if(_0x335d71)return _0x335d71?{'count':_0x456bce,'rows':_0x335d71}:null;})['then'](respondWithResult(_0x20dcac,null))[_0x59ce78('0x4b')](handleError(_0x20dcac,null));}; \ No newline at end of file +const a567_0xb6a2=['type','filter','autoAssociation','body','status','../../config/logger','filters','getTeams','userProfileId','name','error','findOne','query','updatedAt','getMembers','includeAll','findAll','pick','Team','register','then','all','index','SIP','create','lodash','attributes','transaction','rawAttributes','includes','getAgents','SELECT','VIRTUAL','SmsQueueId','each','ids','undefined','show','UserId','count','SmsQueue','length','limit','../../mysqldb','Content-Range','key','Agents','util','json','addTeams','api','ut.TeamId\x20=\x20tq.TeamId','toString','createdAt','ut.UserId\x20=\x20?','destroy','select','sort','merge','sendStatus','where','compact','Unable\x20to\x20retrieve\x20the\x20current\x20user','interface','role','map','SmsQueues','omit','end','isArray','intersection','catch','user','get','User','voicePause','addAgents','team_has_sms_queues','fieldName','include','UserProfileResource','userSmsQueue:save','emit','user_has_teams','fields','set','smsPause','nolimit','options','UserProfileSection','from','%s/%s','removeAgents','../../rediscache','value','offset','keys','like','clone','update','./smsQueue.socket','UserSmsQueue','params','union','model','sequelize','userSmsQueue:remove','order','online','agent','flatMap','every','squel'];(function(_0x47567e,_0xb6a20b){const _0x18b3d0=function(_0x3c130f){while(--_0x3c130f){_0x47567e['push'](_0x47567e['shift']());}};_0x18b3d0(++_0xb6a20b);}(a567_0xb6a2,0x9f));const a567_0x18b3=function(_0x47567e,_0xb6a20b){_0x47567e=_0x47567e-0x0;let _0x18b3d0=a567_0xb6a2[_0x47567e];return _0x18b3d0;};const _0x5ea51d=a567_0x18b3;'use strict';const util=require(_0x5ea51d('0x1')),_=require(_0x5ea51d('0x5c')),squel=require(_0x5ea51d('0x42')),qs=require('../../components/parsers/qs'),logger=require(_0x5ea51d('0x48'))(_0x5ea51d('0x4')),{getSocket}=require(_0x5ea51d('0x2f')),socket=getSocket(),db=require(_0x5ea51d('0x6e'))['db'],{Op,QueryTypes}=require(_0x5ea51d('0x3b'));require(_0x5ea51d('0x36'))[_0x5ea51d('0x56')](socket);function respondWithStatusCode(_0x3c130f,_0x2de5f1){return _0x2de5f1=_0x2de5f1||0xcc,function(_0x2b1ab1){const _0x5aadfd=a567_0x18b3;if(_0x2b1ab1)return _0x3c130f[_0x5aadfd('0xd')](_0x2de5f1);return _0x3c130f[_0x5aadfd('0x47')](_0x2de5f1)[_0x5aadfd('0x16')]();};}function respondWithResult(_0x48e49f,_0x587777){return _0x587777=_0x587777||0xc8,function(_0xd8b32a){const _0x4c7d7e=a567_0x18b3;if(_0xd8b32a)return _0x48e49f[_0x4c7d7e('0x47')](_0x587777)['json'](_0xd8b32a);};}function respondWithFilteredResult(_0x30c8d7,_0x55af43){return function(_0x5b0c76){const _0x414653=a567_0x18b3;if(_0x5b0c76){const _0x58ebb2=_0x5b0c76[_0x414653('0x6a')],_0x1c3d1b=_0x55af43[_0x414653('0x31')];let _0x5bb450=_0x55af43['offset']+_0x55af43['limit'],_0x16a8dd;return _0x5bb450>=_0x58ebb2?(_0x5bb450=_0x58ebb2,_0x16a8dd=0xc8):_0x16a8dd=0xce,_0x30c8d7['status'](_0x16a8dd),_0x30c8d7[_0x414653('0x27')](_0x414653('0x6f'),_0x1c3d1b+'-'+_0x5bb450+'/'+_0x58ebb2)[_0x414653('0x2')](_0x5b0c76);}return null;};}function saveUpdates(_0x4d6e82){return function(_0x1703c9){const _0xe84ddc=a567_0x18b3;if(_0x1703c9)return _0x1703c9[_0xe84ddc('0x35')](_0x4d6e82)['then'](function(_0x58376f){return _0x58376f;});return null;};}function removeEntity(_0x3f2695){return function(_0x23f0d7){const _0x1d2291=a567_0x18b3;if(_0x23f0d7)return _0x23f0d7[_0x1d2291('0x9')]()[_0x1d2291('0x57')](function(){const _0x3651ae=_0x1d2291,_0x4ee705=_0x23f0d7[_0x3651ae('0x1b')]({'plain':!![]}),_0x573016='SmsQueues';return db[_0x3651ae('0x22')]['destroy']({'where':{'type':_0x573016,'resourceId':_0x4ee705['id']}})[_0x3651ae('0x57')](function(){return _0x23f0d7;});})[_0x1d2291('0x57')](function(){const _0x4e7347=_0x1d2291;_0x3f2695[_0x4e7347('0x47')](0xcc)[_0x4e7347('0x16')]();});};}function handleEntityNotFound(_0x33f118){return function(_0x3d89ca){const _0x55293f=a567_0x18b3;return!_0x3d89ca&&_0x33f118[_0x55293f('0xd')](0x194),_0x3d89ca;};}function handleError(_0xc1ebcc,_0x4f20a8){return _0x4f20a8=_0x4f20a8||0x1f4,function(_0xd77b12){const _0xd3f5c3=a567_0x18b3;logger[_0xd3f5c3('0x4d')](_0xd77b12['stack']),_0xd77b12[_0xd3f5c3('0x4c')]&&delete _0xd77b12[_0xd3f5c3('0x4c')],_0xc1ebcc[_0xd3f5c3('0x47')](_0x4f20a8)['send'](_0xd77b12);};}exports[_0x5ea51d('0x59')]=function(_0xd04b,_0x2ee9ee){const _0xf23df0=_0x5ea51d;let _0x1d39bd={};const _0x33d3c7={},_0x1d8c53={'count':0x0,'rows':[]},_0x310db7=_[_0xf23df0('0x13')](db[_0xf23df0('0x6b')][_0xf23df0('0x5f')],function(_0x1df500){const _0xb2119a=_0xf23df0;return{'name':_0x1df500[_0xb2119a('0x20')],'type':_0x1df500[_0xb2119a('0x43')][_0xb2119a('0x70')]};});_0x33d3c7[_0xf23df0('0x3a')]=_['map'](_0x310db7,_0xf23df0('0x4c')),_0x33d3c7[_0xf23df0('0x4f')]=_[_0xf23df0('0x32')](_0xd04b['query']),_0x33d3c7[_0xf23df0('0x49')]=_[_0xf23df0('0x18')](_0x33d3c7['model'],_0x33d3c7[_0xf23df0('0x4f')]),_0x1d39bd[_0xf23df0('0x5d')]=_['intersection'](_0x33d3c7[_0xf23df0('0x3a')],qs[_0xf23df0('0x26')](_0xd04b[_0xf23df0('0x4f')][_0xf23df0('0x26')])),_0x1d39bd[_0xf23df0('0x5d')]=_0x1d39bd[_0xf23df0('0x5d')]['length']?_0x1d39bd['attributes']:_0x33d3c7[_0xf23df0('0x3a')];typeof _0xd04b[_0xf23df0('0x4f')]['nolimit']===_0xf23df0('0x67')&&(_0x1d39bd['limit']=qs[_0xf23df0('0x6d')](_0xd04b[_0xf23df0('0x4f')][_0xf23df0('0x6d')]),_0x1d39bd[_0xf23df0('0x31')]=qs['offset'](_0xd04b[_0xf23df0('0x4f')][_0xf23df0('0x31')]));_0x1d39bd[_0xf23df0('0x3d')]=qs[_0xf23df0('0xb')](_0xd04b[_0xf23df0('0x4f')]['sort']),_0x1d39bd[_0xf23df0('0xe')]=qs[_0xf23df0('0x49')](_['pick'](_0xd04b[_0xf23df0('0x4f')],_0x33d3c7[_0xf23df0('0x49')]),_0x310db7);_0xd04b['query'][_0xf23df0('0x44')]&&(_0x1d39bd['where']=_[_0xf23df0('0xc')](_0x1d39bd['where'],{[Op['or']]:_[_0xf23df0('0x13')](_0x310db7,function(_0x23a87b){const _0x5e3fe9=_0xf23df0;if(_0x23a87b['type']!==_0x5e3fe9('0x63')){const _0x42b3f8={};return _0x42b3f8[_0x23a87b[_0x5e3fe9('0x4c')]]={[Op[_0x5e3fe9('0x33')]]:'%'+_0xd04b['query'][_0x5e3fe9('0x44')]+'%'},_0x42b3f8;}})}));_0x1d39bd=_['merge']({},_0x1d39bd,_0xd04b[_0xf23df0('0x2a')]);const _0x129664={'where':_0x1d39bd['where']};return db[_0xf23df0('0x6b')][_0xf23df0('0x6a')](_0x129664)[_0xf23df0('0x57')](function(_0x524649){const _0x4d7473=_0xf23df0;return _0x1d8c53[_0x4d7473('0x6a')]=_0x524649,_0xd04b[_0x4d7473('0x4f')][_0x4d7473('0x52')]&&(_0x1d39bd['include']=[{'all':!![]}]),db['SmsQueue'][_0x4d7473('0x53')](_0x1d39bd);})[_0xf23df0('0x57')](function(_0x3018d6){return _0x1d8c53['rows']=_0x3018d6,_0x1d8c53;})['then'](respondWithFilteredResult(_0x2ee9ee,_0x1d39bd))[_0xf23df0('0x19')](handleError(_0x2ee9ee,null));},exports[_0x5ea51d('0x68')]=function(_0x18ed7c,_0x47f3e7){const _0x2ff8e1=_0x5ea51d;let _0x7bab48={'raw':!![],'where':{'id':_0x18ed7c['params']['id']}};const _0x499a1d={};return _0x499a1d[_0x2ff8e1('0x3a')]=_[_0x2ff8e1('0x32')](db[_0x2ff8e1('0x6b')]['rawAttributes']),_0x499a1d[_0x2ff8e1('0x4f')]=_[_0x2ff8e1('0x32')](_0x18ed7c[_0x2ff8e1('0x4f')]),_0x499a1d[_0x2ff8e1('0x49')]=_['intersection'](_0x499a1d[_0x2ff8e1('0x3a')],_0x499a1d[_0x2ff8e1('0x4f')]),_0x7bab48[_0x2ff8e1('0x5d')]=_['intersection'](_0x499a1d[_0x2ff8e1('0x3a')],qs[_0x2ff8e1('0x26')](_0x18ed7c[_0x2ff8e1('0x4f')]['fields'])),_0x7bab48[_0x2ff8e1('0x5d')]=_0x7bab48['attributes'][_0x2ff8e1('0x6c')]?_0x7bab48[_0x2ff8e1('0x5d')]:_0x499a1d[_0x2ff8e1('0x3a')],_0x18ed7c[_0x2ff8e1('0x4f')]['includeAll']&&(_0x7bab48[_0x2ff8e1('0x21')]=[{'all':!![]}]),_0x7bab48=_[_0x2ff8e1('0xc')]({},_0x7bab48,_0x18ed7c[_0x2ff8e1('0x2a')]),db['SmsQueue']['findOne'](_0x7bab48)[_0x2ff8e1('0x57')](handleEntityNotFound(_0x47f3e7,null))[_0x2ff8e1('0x57')](respondWithResult(_0x47f3e7,null))[_0x2ff8e1('0x19')](handleError(_0x47f3e7,null));},exports[_0x5ea51d('0x5b')]=function(_0x1b4132,_0xe91b96){const _0x42b881=_0x5ea51d;return db[_0x42b881('0x6b')][_0x42b881('0x5b')](_0x1b4132[_0x42b881('0x46')],{})[_0x42b881('0x57')](function(_0x43499b){const _0x2eb305=_0x42b881,_0x57719d=_0x1b4132[_0x2eb305('0x1a')][_0x2eb305('0x1b')]({'plain':!![]});if(!_0x57719d)throw new Error(_0x2eb305('0x10'));if(_0x57719d[_0x2eb305('0x12')]===_0x2eb305('0x1a')){const _0x5c06d1=_0x43499b[_0x2eb305('0x1b')]({'plain':!![]}),_0x277adc=_0x2eb305('0x14');return db[_0x2eb305('0x2b')][_0x2eb305('0x4e')]({'where':{'name':_0x277adc,'userProfileId':_0x57719d[_0x2eb305('0x4b')]},'raw':!![]})['then'](function(_0x51f5a4){const _0x426386=_0x2eb305;return _0x51f5a4&&_0x51f5a4[_0x426386('0x45')]===0x0?db['UserProfileResource'][_0x426386('0x5b')]({'name':_0x5c06d1[_0x426386('0x4c')],'resourceId':_0x5c06d1['id'],'type':_0x51f5a4[_0x426386('0x4c')],'sectionId':_0x51f5a4['id']},{})[_0x426386('0x57')](function(){return _0x43499b;}):_0x43499b;})[_0x2eb305('0x19')](function(_0x3c873c){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x3c873c);throw _0x3c873c;});}return _0x43499b;})[_0x42b881('0x57')](respondWithResult(_0xe91b96,0xc9))[_0x42b881('0x19')](handleError(_0xe91b96,null));},exports['update']=function(_0x1e82fe,_0x2e5362){const _0x1dfd01=_0x5ea51d;return _0x1e82fe[_0x1dfd01('0x46')]['id']&&delete _0x1e82fe[_0x1dfd01('0x46')]['id'],db[_0x1dfd01('0x6b')][_0x1dfd01('0x4e')]({'where':{'id':_0x1e82fe[_0x1dfd01('0x38')]['id']}})[_0x1dfd01('0x57')](handleEntityNotFound(_0x2e5362,null))[_0x1dfd01('0x57')](saveUpdates(_0x1e82fe[_0x1dfd01('0x46')],null))[_0x1dfd01('0x57')](respondWithResult(_0x2e5362,null))[_0x1dfd01('0x19')](handleError(_0x2e5362,null));},exports[_0x5ea51d('0x9')]=function(_0xdba2ec,_0x5e29ae){const _0x28315c=_0x5ea51d;return db[_0x28315c('0x6b')][_0x28315c('0x4e')]({'where':{'id':_0xdba2ec[_0x28315c('0x38')]['id']}})[_0x28315c('0x57')](handleEntityNotFound(_0x5e29ae,null))['then'](removeEntity(_0x5e29ae,null))[_0x28315c('0x19')](handleError(_0x5e29ae,null));},exports['describe']=function(_0x29fb1d,_0x2793bd){const _0x1f95c2=_0x5ea51d;return db[_0x1f95c2('0x6b')]['describe']()[_0x1f95c2('0x57')](respondWithResult(_0x2793bd,null))[_0x1f95c2('0x19')](handleError(_0x2793bd,null));},exports[_0x5ea51d('0x51')]=function(_0x2e6fdf,_0x2aec81){const _0x2f017a=_0x5ea51d;let _0x16396b={'raw':!![],'where':{}};const _0x438e20={};let _0x33e59b;return db[_0x2f017a('0x6b')][_0x2f017a('0x4e')]({'where':{'id':_0x2e6fdf['params']['id']}})[_0x2f017a('0x57')](handleEntityNotFound(_0x2aec81,null))[_0x2f017a('0x57')](function(_0x4c914e){const _0x2b44b=_0x2f017a;if(_0x4c914e)return _0x33e59b=_0x4c914e[_0x2b44b('0x1b')]({'plain':!![]}),_0x438e20['model']=_[_0x2b44b('0x32')](db[_0x2b44b('0x37')][_0x2b44b('0x5f')]),_0x438e20['query']=_[_0x2b44b('0x32')](_0x2e6fdf[_0x2b44b('0x4f')]),_0x438e20[_0x2b44b('0x49')]=_[_0x2b44b('0x18')](_0x438e20['model'],_0x438e20[_0x2b44b('0x4f')]),_0x16396b[_0x2b44b('0x5d')]=_[_0x2b44b('0x18')](_0x438e20['model'],qs[_0x2b44b('0x26')](_0x2e6fdf['query'][_0x2b44b('0x26')])),_0x16396b[_0x2b44b('0x5d')]=_0x16396b[_0x2b44b('0x5d')][_0x2b44b('0x6c')]?_0x16396b[_0x2b44b('0x5d')]:_0x438e20[_0x2b44b('0x3a')],typeof _0x2e6fdf[_0x2b44b('0x4f')][_0x2b44b('0x29')]===_0x2b44b('0x67')&&(_0x16396b[_0x2b44b('0x6d')]=qs['limit'](_0x2e6fdf['query'][_0x2b44b('0x6d')]),_0x16396b[_0x2b44b('0x31')]=qs[_0x2b44b('0x31')](_0x2e6fdf['query'][_0x2b44b('0x31')])),_0x16396b[_0x2b44b('0x3d')]=qs[_0x2b44b('0xb')](_0x2e6fdf[_0x2b44b('0x4f')][_0x2b44b('0xb')]),_0x16396b[_0x2b44b('0xe')]=qs[_0x2b44b('0x49')](_[_0x2b44b('0x54')](_0x2e6fdf[_0x2b44b('0x4f')],_0x438e20[_0x2b44b('0x49')])),_0x16396b['where'][_0x2b44b('0x64')]=_0x4c914e['id'],_0x2e6fdf[_0x2b44b('0x4f')]['filter']&&(_0x16396b['where']=_[_0x2b44b('0xc')](_0x16396b[_0x2b44b('0xe')],{[Op['or']]:_[_0x2b44b('0x13')](_0x16396b[_0x2b44b('0x5d')],function(_0xf7bc2e){const _0x324158=_0x2b44b,_0x502b0f={};return _0x502b0f[_0xf7bc2e]={[Op[_0x324158('0x33')]]:'%'+_0x2e6fdf[_0x324158('0x4f')]['filter']+'%'},_0x502b0f;})})),_0x16396b=_[_0x2b44b('0xc')]({},_0x16396b,_0x2e6fdf[_0x2b44b('0x2a')]),db[_0x2b44b('0x37')][_0x2b44b('0x53')](_0x16396b);})['then'](function(_0xec09ec){const _0x5cb344=_0x2f017a;if(_0xec09ec)return db['User']['findAndCountAll']({'where':{'id':_[_0x5cb344('0x13')](_0xec09ec,_0x5cb344('0x69')),'role':_0x5cb344('0x3f')},'attributes':['id',_0x5cb344('0x4c'),'smsPause',_0x5cb344('0x50'),_0x5cb344('0x7')]});})['then'](function(_0x5a8a59){const _0xd15a03=_0x2f017a;return _0x5a8a59?{'count':_0x5a8a59[_0xd15a03('0x6a')],'rows':_[_0xd15a03('0x13')](_0x5a8a59['rows'],function(_0x1212a2){const _0x458880=_0xd15a03;return{'membername':_0x1212a2[_0x458880('0x4c')],'UserId':_0x1212a2['id'],'queue_name':_0x33e59b[_0x458880('0x4c')],'SmsQueueId':_0x33e59b['id'],'interface':util['format'](_0x458880('0x2d'),_0x458880('0x5a'),_0x1212a2['name']),'penalty':0x0,'paused':_0x1212a2[_0x458880('0x28')],'createdAt':_0x1212a2[_0x458880('0x7')],'updatedAt':_0x1212a2[_0x458880('0x50')]};})}:{'count':0x0,'rows':[]};})[_0x2f017a('0x57')](respondWithFilteredResult(_0x2aec81,_0x16396b))[_0x2f017a('0x19')](handleError(_0x2aec81,null));},exports['getTeams']=function(_0x9eb79a,_0x299399){const _0x57edb3=_0x5ea51d;let _0x5034c5={};const _0x1b1262={};let _0xfeb08a,_0x338a88;return db['SmsQueue'][_0x57edb3('0x4e')]({'where':{'id':_0x9eb79a[_0x57edb3('0x38')]['id']}})[_0x57edb3('0x57')](handleEntityNotFound(_0x299399,null))[_0x57edb3('0x57')](function(_0x3fb3ca){const _0x6cf06b=_0x57edb3;if(_0x3fb3ca)return _0xfeb08a=_0x3fb3ca,_0x1b1262[_0x6cf06b('0x3a')]=_[_0x6cf06b('0x32')](db[_0x6cf06b('0x55')][_0x6cf06b('0x5f')]),_0x1b1262[_0x6cf06b('0x4f')]=_[_0x6cf06b('0x32')](_0x9eb79a[_0x6cf06b('0x4f')]),_0x1b1262[_0x6cf06b('0x49')]=_[_0x6cf06b('0x18')](_0x1b1262[_0x6cf06b('0x3a')],_0x1b1262[_0x6cf06b('0x4f')]),_0x5034c5[_0x6cf06b('0x5d')]=_[_0x6cf06b('0x18')](_0x1b1262[_0x6cf06b('0x3a')],qs[_0x6cf06b('0x26')](_0x9eb79a[_0x6cf06b('0x4f')][_0x6cf06b('0x26')])),_0x5034c5[_0x6cf06b('0x5d')]=_0x5034c5[_0x6cf06b('0x5d')][_0x6cf06b('0x6c')]?_0x5034c5[_0x6cf06b('0x5d')]:_0x1b1262[_0x6cf06b('0x3a')],_0x5034c5[_0x6cf06b('0x3d')]=qs[_0x6cf06b('0xb')](_0x9eb79a[_0x6cf06b('0x4f')][_0x6cf06b('0xb')]),_0x5034c5['where']=qs[_0x6cf06b('0x49')](_[_0x6cf06b('0x54')](_0x9eb79a[_0x6cf06b('0x4f')],_0x1b1262['filters'])),_0x9eb79a[_0x6cf06b('0x4f')][_0x6cf06b('0x44')]&&(_0x5034c5['where']=_['merge'](_0x5034c5[_0x6cf06b('0xe')],{[Op['or']]:_[_0x6cf06b('0x13')](_0x5034c5[_0x6cf06b('0x5d')],function(_0x1e39d0){const _0x135281=_0x6cf06b,_0x2840e9={};return _0x2840e9[_0x1e39d0]={[Op['like']]:'%'+_0x9eb79a[_0x135281('0x4f')][_0x135281('0x44')]+'%'},_0x2840e9;})})),_0x5034c5=_[_0x6cf06b('0xc')]({},_0x5034c5,_0x9eb79a[_0x6cf06b('0x2a')]),_0xfeb08a[_0x6cf06b('0x4a')](_0x5034c5);})[_0x57edb3('0x57')](function(_0x5addaf){const _0xecdc40=_0x57edb3;if(_0x5addaf)return _0x338a88=_0x5addaf[_0xecdc40('0x6c')],typeof _0x9eb79a[_0xecdc40('0x4f')][_0xecdc40('0x29')]===_0xecdc40('0x67')&&(_0x5034c5['limit']=qs[_0xecdc40('0x6d')](_0x9eb79a[_0xecdc40('0x4f')]['limit']),_0x5034c5[_0xecdc40('0x31')]=qs[_0xecdc40('0x31')](_0x9eb79a[_0xecdc40('0x4f')][_0xecdc40('0x31')])),_0xfeb08a[_0xecdc40('0x4a')](_0x5034c5);})[_0x57edb3('0x57')](function(_0x116383){if(_0x116383)return _0x116383?{'count':_0x338a88,'rows':_0x116383}:null;})[_0x57edb3('0x57')](respondWithResult(_0x299399,null))[_0x57edb3('0x19')](handleError(_0x299399,null));},exports[_0x5ea51d('0x3')]=function(_0x2beaa8,_0x287d1c){const _0x5070c1=_0x5ea51d,_0x2a322e=_0x2beaa8['body']['ids'];return db[_0x5070c1('0x55')]['findAll']({'where':{'id':_0x2a322e},'attributes':['id'],'include':[{'model':db['User'],'as':_0x5070c1('0x0'),'attributes':['id',_0x5070c1('0x4c'),_0x5070c1('0x3e'),_0x5070c1('0x1d'),_0x5070c1('0x11')],'raw':!![]}]})['then'](function(_0x923d48){const _0x2dd60c=_0x5070c1;if(_0x923d48){const _0x1e8ec9=_[_0x2dd60c('0x40')](_0x923d48,function(_0x11dcdf){const _0x170dfd=_0x2dd60c,_0x474e2d=_0x11dcdf[_0x170dfd('0x1b')]({'plain':!![]});return _0x474e2d[_0x170dfd('0x0')];});return db[_0x2dd60c('0x6b')][_0x2dd60c('0x4e')]({'where':{'id':_0x2beaa8[_0x2dd60c('0x38')]['id']}})['then'](function(_0x3a1518){const _0x4bdfa9=_0x2dd60c;return db[_0x4bdfa9('0x3b')][_0x4bdfa9('0x5e')](function(_0x50cb71){const _0x15461e=_0x4bdfa9;return _0x3a1518[_0x15461e('0x3')](_0x2a322e,{'transaction':_0x50cb71})['then'](function(){const _0x112d62=_0x15461e;return Promise[_0x112d62('0x65')](_0x1e8ec9,function(_0x13f174){const _0x1ca87a=_0x112d62;return db[_0x1ca87a('0x37')]['findOrCreate']({'where':{'UserId':_0x13f174['id'],'SmsQueueId':_0x2beaa8[_0x1ca87a('0x38')]['id']},'transaction':_0x50cb71});});})['then'](function(){_0x1e8ec9['forEach'](function(_0x46f847){const _0x38b343=a567_0x18b3;socket[_0x38b343('0x24')](_0x38b343('0x23'),{'UserId':_0x46f847['id'],'SmsQueueId':_0x3a1518['id']});});});});});}})[_0x5070c1('0x57')](respondWithStatusCode(_0x287d1c,null))[_0x5070c1('0x19')](handleError(_0x287d1c,null));},exports['removeTeams']=function(_0x35455b,_0x4112df){const _0x2e035d=_0x5ea51d;return db['Team'][_0x2e035d('0x53')]({'where':{'id':_0x35455b[_0x2e035d('0x4f')][_0x2e035d('0x66')]},'attributes':['id'],'include':[{'model':db[_0x2e035d('0x1c')],'as':_0x2e035d('0x0'),'attributes':['id'],'raw':!![]}]})[_0x2e035d('0x57')](handleEntityNotFound(_0x4112df,null))[_0x2e035d('0x57')](function(_0x4fd81b){const _0x81257e=_0x2e035d,_0x451250=_[_0x81257e('0x13')](_0x4fd81b,'id');let _0x31398b=[];const _0x169070=[],_0x3fab26=squel[_0x81257e('0xa')]();_0x3fab26['field']('tq.TeamId')[_0x81257e('0x2c')](_0x81257e('0x1f'),'tq')['join'](_0x81257e('0x25'),'ut',_0x81257e('0x5'))['where']('SmsQueueId\x20=\x20?',_0x35455b['params']['id']);for(let _0x5b86dd=0x0;_0x5b86dd<_0x4fd81b['length'];_0x5b86dd+=0x1){const _0x4cc853=_0x4fd81b[_0x5b86dd];for(let _0x488d1e=0x0;_0x488d1e<_0x4cc853[_0x81257e('0x0')]['length'];_0x488d1e+=0x1){const _0x5d8e12=_0x4cc853[_0x81257e('0x0')][_0x488d1e],_0x127729=_0x3fab26[_0x81257e('0x34')]();_0x127729[_0x81257e('0xe')](_0x81257e('0x8'),_0x5d8e12['id']),_0x169070['push'](db[_0x81257e('0x3b')][_0x81257e('0x4f')](_0x127729[_0x81257e('0x6')](),{'type':QueryTypes[_0x81257e('0x62')]})[_0x81257e('0x57')](function(_0x34201d){const _0x110d86=_0x81257e;if(_0x34201d['length']===0x1)return _0x5d8e12['id'];else{const _0x1aecf5=_[_0x110d86('0x41')](_[_0x110d86('0x13')](_0x34201d,'TeamId'),function(_0x5abefc){const _0x6531bc=_0x110d86;return _[_0x6531bc('0x60')](_0x451250,_0x5abefc);});if(_0x1aecf5)return _0x5d8e12['id'];}}));}}return Promise[_0x81257e('0x58')](_0x169070)[_0x81257e('0x57')](function(_0x4b5926){const _0xd745c8=_0x81257e;return _0x31398b=_(_0x31398b)[_0xd745c8('0x39')](_0x4b5926)[_0xd745c8('0xf')]()[_0xd745c8('0x30')](),db['SmsQueue'][_0xd745c8('0x4e')]({'where':{'id':_0x35455b[_0xd745c8('0x38')]['id']}})[_0xd745c8('0x57')](function(_0x4a7138){const _0x1b67d1=_0xd745c8;return db[_0x1b67d1('0x3b')]['transaction'](function(_0x17bf2b){const _0x3ff8b2=_0x1b67d1;return _0x4a7138['removeTeams'](_0x35455b[_0x3ff8b2('0x4f')][_0x3ff8b2('0x66')],{'transaction':_0x17bf2b})[_0x3ff8b2('0x57')](function(){const _0x12791e=_0x3ff8b2;if(!_['isEmpty'](_0x31398b))return _0x4a7138[_0x12791e('0x2e')](_0x31398b,{'transaction':_0x17bf2b});})[_0x3ff8b2('0x57')](function(){_0x31398b['forEach'](function(_0x3bed51){const _0x3bf713=a567_0x18b3;socket[_0x3bf713('0x24')]('userSmsQueue:remove',{'UserId':_0x3bed51,'SmsQueueId':_0x4a7138['id']});});});});});});})[_0x2e035d('0x57')](respondWithStatusCode(_0x4112df,null))[_0x2e035d('0x19')](handleError(_0x4112df,null));},exports[_0x5ea51d('0x1e')]=function(_0x2b63a1,_0x1d95a3){const _0x238499=_0x5ea51d;return db[_0x238499('0x6b')][_0x238499('0x4e')]({'where':{'id':_0x2b63a1['params']['id']}})['then'](function(_0x40844f){const _0x27d545=_0x238499;if(_0x40844f)return _0x40844f[_0x27d545('0x1e')](_0x2b63a1[_0x27d545('0x46')][_0x27d545('0x66')],{'through':_[_0x27d545('0x15')](_0x2b63a1['body'],[_0x27d545('0x66'),'id'])})[_0x27d545('0x57')](function(_0x3f56d0){const _0x4fd673=_0x27d545;for(let _0x4cd930=0x0;_0x4cd930<_0x2b63a1[_0x4fd673('0x46')][_0x4fd673('0x66')][_0x4fd673('0x6c')];_0x4cd930+=0x1){socket[_0x4fd673('0x24')](_0x4fd673('0x23'),{'UserId':_0x2b63a1[_0x4fd673('0x46')]['ids'][_0x4cd930],'SmsQueueId':_0x2b63a1[_0x4fd673('0x38')]['id']});}return _0x3f56d0;});})[_0x238499('0x57')](respondWithResult(_0x1d95a3,null))[_0x238499('0x19')](handleError(_0x1d95a3,null));},exports[_0x5ea51d('0x2e')]=function(_0x28b0b7,_0x3cecae){const _0xddda65=_0x5ea51d;return db[_0xddda65('0x6b')][_0xddda65('0x4e')]({'where':{'id':_0x28b0b7[_0xddda65('0x38')]['id']}})['then'](handleEntityNotFound(_0x3cecae,null))[_0xddda65('0x57')](function(_0x55e7f6){const _0x5a7d9c=_0xddda65;if(_0x55e7f6)return _0x55e7f6[_0x5a7d9c('0x2e')](_0x28b0b7[_0x5a7d9c('0x4f')][_0x5a7d9c('0x66')])[_0x5a7d9c('0x57')](function(){const _0x24f08b=_0x5a7d9c;if(_[_0x24f08b('0x17')](_0x28b0b7['query']['ids']))for(let _0x492020=0x0;_0x492020<_0x28b0b7['query'][_0x24f08b('0x66')][_0x24f08b('0x6c')];_0x492020+=0x1){socket[_0x24f08b('0x24')](_0x24f08b('0x3c'),{'UserId':Number(_0x28b0b7['query'][_0x24f08b('0x66')][_0x492020]),'SmsQueueId':Number(_0x28b0b7[_0x24f08b('0x38')]['id'])});}else socket['emit'](_0x24f08b('0x3c'),{'UserId':Number(_0x28b0b7[_0x24f08b('0x4f')]['ids']),'SmsQueueId':Number(_0x28b0b7[_0x24f08b('0x38')]['id'])});});})[_0xddda65('0x57')](respondWithStatusCode(_0x3cecae,null))['catch'](handleError(_0x3cecae,null));},exports[_0x5ea51d('0x61')]=function(_0x4174be,_0x23bf8e){const _0x5b4b84=_0x5ea51d;let _0x3565fd={};const _0x179b93={};let _0x3d0e28,_0xfb6292;return db[_0x5b4b84('0x6b')][_0x5b4b84('0x4e')]({'where':{'id':_0x4174be['params']['id']}})[_0x5b4b84('0x57')](handleEntityNotFound(_0x23bf8e,null))['then'](function(_0x52bff1){const _0x585eb7=_0x5b4b84;if(_0x52bff1)return _0x3d0e28=_0x52bff1,_0x179b93[_0x585eb7('0x3a')]=_[_0x585eb7('0x32')](db[_0x585eb7('0x1c')][_0x585eb7('0x5f')]),_0x179b93[_0x585eb7('0x4f')]=_[_0x585eb7('0x32')](_0x4174be['query']),_0x179b93[_0x585eb7('0x49')]=_[_0x585eb7('0x18')](_0x179b93[_0x585eb7('0x3a')],_0x179b93[_0x585eb7('0x4f')]),_0x3565fd[_0x585eb7('0x5d')]=_['intersection'](_0x179b93[_0x585eb7('0x3a')],qs[_0x585eb7('0x26')](_0x4174be[_0x585eb7('0x4f')][_0x585eb7('0x26')])),_0x3565fd['attributes']=_0x3565fd['attributes'][_0x585eb7('0x6c')]?_0x3565fd[_0x585eb7('0x5d')]:_0x179b93[_0x585eb7('0x3a')],_0x3565fd[_0x585eb7('0x3d')]=qs[_0x585eb7('0xb')](_0x4174be[_0x585eb7('0x4f')][_0x585eb7('0xb')]),_0x3565fd['where']=qs['filters'](_[_0x585eb7('0x54')](_0x4174be['query'],_0x179b93[_0x585eb7('0x49')])),_0x4174be[_0x585eb7('0x4f')][_0x585eb7('0x44')]&&(_0x3565fd[_0x585eb7('0xe')]=_[_0x585eb7('0xc')](_0x3565fd[_0x585eb7('0xe')],{[Op['or']]:_[_0x585eb7('0x13')](_0x3565fd[_0x585eb7('0x5d')],function(_0x70c268){const _0x73ab96=_0x585eb7,_0x1dcd6e={};return _0x1dcd6e[_0x70c268]={[Op['like']]:'%'+_0x4174be['query'][_0x73ab96('0x44')]+'%'},_0x1dcd6e;})})),_0x3565fd=_[_0x585eb7('0xc')]({},_0x3565fd,_0x4174be[_0x585eb7('0x2a')]),_0x3d0e28[_0x585eb7('0x61')](_0x3565fd);})['then'](function(_0x1fb2a5){const _0x810fe4=_0x5b4b84;if(_0x1fb2a5)return _0xfb6292=_0x1fb2a5[_0x810fe4('0x6c')],typeof _0x4174be[_0x810fe4('0x4f')]['nolimit']===_0x810fe4('0x67')&&(_0x3565fd['limit']=qs[_0x810fe4('0x6d')](_0x4174be['query'][_0x810fe4('0x6d')]),_0x3565fd[_0x810fe4('0x31')]=qs['offset'](_0x4174be[_0x810fe4('0x4f')][_0x810fe4('0x31')])),_0x3d0e28[_0x810fe4('0x61')](_0x3565fd);})[_0x5b4b84('0x57')](function(_0x121b59){if(_0x121b59)return _0x121b59?{'count':_0xfb6292,'rows':_0x121b59}:null;})[_0x5b4b84('0x57')](respondWithResult(_0x23bf8e,null))[_0x5b4b84('0x19')](handleError(_0x23bf8e,null));}; \ No newline at end of file diff --git a/server/api/smsQueue/smsQueue.events.js b/server/api/smsQueue/smsQueue.events.js index 8697970..65aa867 100644 --- a/server/api/smsQueue/smsQueue.events.js +++ b/server/api/smsQueue/smsQueue.events.js @@ -1 +1 @@ -const a568_0x5b9d=['SmsQueue','remove','addHook','../../mysqldb','undefined','emit','events','save','exports'];(function(_0x19820b,_0x5b9d6c){const _0x11675d=function(_0x1b7ea3){while(--_0x1b7ea3){_0x19820b['push'](_0x19820b['shift']());}};_0x11675d(++_0x5b9d6c);}(a568_0x5b9d,0x1bc));const a568_0x1167=function(_0x19820b,_0x5b9d6c){_0x19820b=_0x19820b-0x0;let _0x11675d=a568_0x5b9d[_0x19820b];return _0x11675d;};const _0x11bd55=a568_0x1167;'use strict';const EventEmitter=require(_0x11bd55('0x3')),SmsQueue=require(_0x11bd55('0x0'))['db'][_0x11bd55('0x6')],SmsQueueEvents=new EventEmitter();SmsQueueEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x11bd55('0x4'),'afterUpdate':'update','afterDestroy':_0x11bd55('0x7')};function emitEvent(_0x1b7ea3){return function(_0xe2a98c){const _0x91c842=a568_0x1167;SmsQueueEvents['emit'](_0x1b7ea3+':'+_0xe2a98c['id'],_0xe2a98c),SmsQueueEvents[_0x91c842('0x2')](_0x1b7ea3,_0xe2a98c);};}for(const e in events){if(typeof events[e]!==_0x11bd55('0x1')){const event=events[e];SmsQueue[_0x11bd55('0x8')](e,emitEvent(event));}}module[_0x11bd55('0x5')]=SmsQueueEvents; \ No newline at end of file +const a568_0x3d8c=['../../mysqldb','exports','SmsQueue','update','events','emit','save','undefined','addHook','remove'];(function(_0x2028ec,_0x3d8cc9){const _0x387142=function(_0x336ad7){while(--_0x336ad7){_0x2028ec['push'](_0x2028ec['shift']());}};_0x387142(++_0x3d8cc9);}(a568_0x3d8c,0x1c1));const a568_0x3871=function(_0x2028ec,_0x3d8cc9){_0x2028ec=_0x2028ec-0x0;let _0x387142=a568_0x3d8c[_0x2028ec];return _0x387142;};const _0xf89915=a568_0x3871;'use strict';const EventEmitter=require(_0xf89915('0x5')),SmsQueue=require(_0xf89915('0x1'))['db'][_0xf89915('0x3')],SmsQueueEvents=new EventEmitter();SmsQueueEvents['setMaxListeners'](0x0);const events={'afterCreate':_0xf89915('0x7'),'afterUpdate':_0xf89915('0x4'),'afterDestroy':_0xf89915('0x0')};function emitEvent(_0x336ad7){return function(_0x21b62a){const _0x39be30=a568_0x3871;SmsQueueEvents['emit'](_0x336ad7+':'+_0x21b62a['id'],_0x21b62a),SmsQueueEvents[_0x39be30('0x6')](_0x336ad7,_0x21b62a);};}for(const e in events){if(typeof events[e]!==_0xf89915('0x8')){const event=events[e];SmsQueue[_0xf89915('0x9')](e,emitEvent(event));}}module[_0xf89915('0x2')]=SmsQueueEvents; \ No newline at end of file diff --git a/server/api/smsQueue/smsQueue.model.js b/server/api/smsQueue/smsQueue.model.js index f0b0c20..67d990c 100644 --- a/server/api/smsQueue/smsQueue.model.js +++ b/server/api/smsQueue/smsQueue.model.js @@ -1 +1 @@ -const a569_0x44dc=['SmsQueue','define','exports'];(function(_0x2b256e,_0x44dc58){const _0x35cb2d=function(_0x4854cd){while(--_0x4854cd){_0x2b256e['push'](_0x2b256e['shift']());}};_0x35cb2d(++_0x44dc58);}(a569_0x44dc,0xac));const a569_0x35cb=function(_0x2b256e,_0x44dc58){_0x2b256e=_0x2b256e-0x0;let _0x35cb2d=a569_0x44dc[_0x2b256e];return _0x35cb2d;};const _0x57e359=a569_0x35cb;'use strict';const attributes=require('./smsQueue.attributes');module[_0x57e359('0x1')]=function(_0x4854cd){const _0xe88c22=_0x57e359,_0x917697=_0x4854cd[_0xe88c22('0x0')](_0xe88c22('0x2'),attributes,{'tableName':'sms_queues','paranoid':![],'indexes':[],'timestamps':!![]});return _0x917697;}; \ No newline at end of file +const a569_0xd182=['./smsQueue.attributes','define','sms_queues','SmsQueue'];(function(_0x4c853f,_0xd182bd){const _0x1965d4=function(_0x2640a7){while(--_0x2640a7){_0x4c853f['push'](_0x4c853f['shift']());}};_0x1965d4(++_0xd182bd);}(a569_0xd182,0xd6));const a569_0x1965=function(_0x4c853f,_0xd182bd){_0x4c853f=_0x4c853f-0x0;let _0x1965d4=a569_0xd182[_0x4c853f];return _0x1965d4;};const _0x1e4b7e=a569_0x1965;'use strict';const attributes=require(_0x1e4b7e('0x2'));module['exports']=function(_0x2640a7){const _0x5f2d82=_0x1e4b7e,_0x57d029=_0x2640a7[_0x5f2d82('0x3')](_0x5f2d82('0x1'),attributes,{'tableName':_0x5f2d82('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x57d029;}; \ No newline at end of file diff --git a/server/api/smsQueue/smsQueue.rpc.js b/server/api/smsQueue/smsQueue.rpc.js index e3c8de0..3cdde3a 100644 --- a/server/api/smsQueue/smsQueue.rpc.js +++ b/server/api/smsQueue/smsQueue.rpc.js @@ -1 +1 @@ -const a570_0x2782=['SmsQueue','message','stringify','debug','../../mysqldb','then','options','./smsQueue.socket','../../config/logger','include','findOne','findAll','GetSmsQueue','model','catch','error','raw','lodash','attributes','ShowSmsQueue','map','where','info','register','limit'];(function(_0x339f7c,_0x278205){const _0x54866c=function(_0x3271ee){while(--_0x3271ee){_0x339f7c['push'](_0x339f7c['shift']());}};_0x54866c(++_0x278205);}(a570_0x2782,0x15e));const a570_0x5486=function(_0x339f7c,_0x278205){_0x339f7c=_0x339f7c-0x0;let _0x54866c=a570_0x2782[_0x339f7c];return _0x54866c;};const _0x127b33=a570_0x5486;'use strict';const _=require(_0x127b33('0x11')),db=require(_0x127b33('0x4'))['db'],logger=require(_0x127b33('0x8'))('rpc'),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x127b33('0x7'))[_0x127b33('0x17')](socket),exports['GetSmsQueue']=function(_0x3271ee){const _0x2a76c7=this;return new Promise(function(_0x4caf37,_0x322c9d){const _0x5c38be=a570_0x5486;return db[_0x5c38be('0x0')][_0x5c38be('0xb')]({'raw':_0x3271ee[_0x5c38be('0x6')]?_0x3271ee[_0x5c38be('0x6')][_0x5c38be('0x10')]===undefined?!![]:![]:!![],'where':_0x3271ee[_0x5c38be('0x6')]?_0x3271ee[_0x5c38be('0x6')][_0x5c38be('0x15')]||null:null,'attributes':_0x3271ee['options']?_0x3271ee[_0x5c38be('0x6')][_0x5c38be('0x12')]||null:null,'limit':_0x3271ee[_0x5c38be('0x6')]?_0x3271ee[_0x5c38be('0x6')][_0x5c38be('0x18')]||null:null,'include':_0x3271ee[_0x5c38be('0x6')]?_0x3271ee[_0x5c38be('0x6')][_0x5c38be('0x9')]?_[_0x5c38be('0x14')](_0x3271ee[_0x5c38be('0x6')][_0x5c38be('0x9')],function(_0x34e3ab){const _0x54cdce=_0x5c38be;return{'model':db[_0x34e3ab[_0x54cdce('0xd')]],'as':_0x34e3ab['as'],'attributes':_0x34e3ab[_0x54cdce('0x12')],'include':_0x34e3ab['include']?_[_0x54cdce('0x14')](_0x34e3ab[_0x54cdce('0x9')],function(_0x44e90e){const _0x5586aa=_0x54cdce;return{'model':db[_0x44e90e[_0x5586aa('0xd')]],'as':_0x44e90e['as'],'attributes':_0x44e90e[_0x5586aa('0x12')],'include':_0x44e90e[_0x5586aa('0x9')]?_[_0x5586aa('0x14')](_0x44e90e[_0x5586aa('0x9')],function(_0x2942e9){const _0x17fa06=_0x5586aa;return{'model':db[_0x2942e9[_0x17fa06('0xd')]],'as':_0x2942e9['as'],'attributes':_0x2942e9[_0x17fa06('0x12')]};}):[]};}):[]};}):[]:[]})[_0x5c38be('0x5')](function(_0x43ab97){const _0x493631=_0x5c38be;logger[_0x493631('0x16')](_0x493631('0xc'),_0x3271ee),logger[_0x493631('0x3')](_0x493631('0xc'),_0x3271ee,JSON['stringify'](_0x43ab97)),_0x4caf37(_0x43ab97);})[_0x5c38be('0xe')](function(_0x4a58ff){const _0x5997e7=_0x5c38be;logger[_0x5997e7('0xf')]('GetSmsQueue',_0x4a58ff[_0x5997e7('0x1')],_0x3271ee),_0x322c9d(_0x2a76c7[_0x5997e7('0xf')](0x1f4,_0x4a58ff['message']));});});},exports['ShowSmsQueue']=function(_0x53409d){const _0x9dd7=this;return new Promise(function(_0x3a8127,_0x588295){const _0x42d42c=a570_0x5486;return db[_0x42d42c('0x0')][_0x42d42c('0xa')]({'raw':_0x53409d[_0x42d42c('0x6')]?_0x53409d[_0x42d42c('0x6')]['raw']===undefined?!![]:![]:!![],'where':_0x53409d['options']?_0x53409d[_0x42d42c('0x6')][_0x42d42c('0x15')]||null:null,'attributes':_0x53409d[_0x42d42c('0x6')]?_0x53409d[_0x42d42c('0x6')][_0x42d42c('0x12')]||null:null,'include':_0x53409d[_0x42d42c('0x6')]?_0x53409d['options'][_0x42d42c('0x9')]?_['map'](_0x53409d[_0x42d42c('0x6')]['include'],function(_0x34bf5d){const _0xb26914=_0x42d42c;return{'model':db[_0x34bf5d[_0xb26914('0xd')]],'as':_0x34bf5d['as'],'attributes':_0x34bf5d[_0xb26914('0x12')],'include':_0x34bf5d['include']?_['map'](_0x34bf5d[_0xb26914('0x9')],function(_0x13fee1){const _0x4cd7af=_0xb26914;return{'model':db[_0x13fee1[_0x4cd7af('0xd')]],'as':_0x13fee1['as'],'attributes':_0x13fee1[_0x4cd7af('0x12')],'include':_0x13fee1[_0x4cd7af('0x9')]?_['map'](_0x13fee1['include'],function(_0x5beca5){const _0x3a6f6e=_0x4cd7af;return{'model':db[_0x5beca5[_0x3a6f6e('0xd')]],'as':_0x5beca5['as'],'attributes':_0x5beca5[_0x3a6f6e('0x12')]};}):[]};}):[]};}):[]:[]})[_0x42d42c('0x5')](function(_0x3b0674){const _0x2f2272=_0x42d42c;logger[_0x2f2272('0x16')]('ShowSmsQueue',_0x53409d),logger[_0x2f2272('0x3')](_0x2f2272('0x13'),_0x53409d,JSON[_0x2f2272('0x2')](_0x3b0674)),_0x3a8127(_0x3b0674);})[_0x42d42c('0xe')](function(_0x2fb54b){const _0x44d06b=_0x42d42c;logger[_0x44d06b('0xf')](_0x44d06b('0x13'),_0x2fb54b[_0x44d06b('0x1')],_0x53409d),_0x588295(_0x9dd7[_0x44d06b('0xf')](0x1f4,_0x2fb54b['message']));});});}; \ No newline at end of file +const a570_0x1978=['model','map','SmsQueue','stringify','error','catch','../../mysqldb','message','./smsQueue.socket','limit','lodash','findOne','ShowSmsQueue','GetSmsQueue','options','rpc','register','where','info','attributes','include','../../config/logger','then'];(function(_0x66388f,_0x1978a6){const _0x9cfdaf=function(_0x28100b){while(--_0x28100b){_0x66388f['push'](_0x66388f['shift']());}};_0x9cfdaf(++_0x1978a6);}(a570_0x1978,0x146));const a570_0x9cfd=function(_0x66388f,_0x1978a6){_0x66388f=_0x66388f-0x0;let _0x9cfdaf=a570_0x1978[_0x66388f];return _0x9cfdaf;};const _0xa1788f=a570_0x9cfd;'use strict';const _=require(_0xa1788f('0x6')),db=require(_0xa1788f('0x2'))['db'],logger=require(_0xa1788f('0x11'))(_0xa1788f('0xb')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0xa1788f('0x4'))[_0xa1788f('0xc')](socket),exports[_0xa1788f('0x9')]=function(_0x28100b){const _0x14a2e8=this;return new Promise(function(_0x3ce472,_0x5bc3d9){const _0x194bca=a570_0x9cfd;return db[_0x194bca('0x15')]['findAll']({'raw':_0x28100b[_0x194bca('0xa')]?_0x28100b['options']['raw']===undefined?!![]:![]:!![],'where':_0x28100b[_0x194bca('0xa')]?_0x28100b[_0x194bca('0xa')][_0x194bca('0xd')]||null:null,'attributes':_0x28100b['options']?_0x28100b['options'][_0x194bca('0xf')]||null:null,'limit':_0x28100b[_0x194bca('0xa')]?_0x28100b['options'][_0x194bca('0x5')]||null:null,'include':_0x28100b['options']?_0x28100b[_0x194bca('0xa')]['include']?_[_0x194bca('0x14')](_0x28100b[_0x194bca('0xa')]['include'],function(_0x4eef10){const _0x303bb8=_0x194bca;return{'model':db[_0x4eef10[_0x303bb8('0x13')]],'as':_0x4eef10['as'],'attributes':_0x4eef10[_0x303bb8('0xf')],'include':_0x4eef10[_0x303bb8('0x10')]?_[_0x303bb8('0x14')](_0x4eef10[_0x303bb8('0x10')],function(_0x33829e){const _0x4fc01b=_0x303bb8;return{'model':db[_0x33829e[_0x4fc01b('0x13')]],'as':_0x33829e['as'],'attributes':_0x33829e[_0x4fc01b('0xf')],'include':_0x33829e[_0x4fc01b('0x10')]?_[_0x4fc01b('0x14')](_0x33829e[_0x4fc01b('0x10')],function(_0x40c05e){const _0x43ed32=_0x4fc01b;return{'model':db[_0x40c05e[_0x43ed32('0x13')]],'as':_0x40c05e['as'],'attributes':_0x40c05e[_0x43ed32('0xf')]};}):[]};}):[]};}):[]:[]})[_0x194bca('0x12')](function(_0x2af2b4){const _0x361bd9=_0x194bca;logger[_0x361bd9('0xe')]('GetSmsQueue',_0x28100b),logger['debug'](_0x361bd9('0x9'),_0x28100b,JSON[_0x361bd9('0x16')](_0x2af2b4)),_0x3ce472(_0x2af2b4);})[_0x194bca('0x1')](function(_0x3b92e9){const _0xc6fc4d=_0x194bca;logger['error'](_0xc6fc4d('0x9'),_0x3b92e9[_0xc6fc4d('0x3')],_0x28100b),_0x5bc3d9(_0x14a2e8[_0xc6fc4d('0x0')](0x1f4,_0x3b92e9[_0xc6fc4d('0x3')]));});});},exports[_0xa1788f('0x8')]=function(_0x5b2a53){const _0x3336e9=this;return new Promise(function(_0x58069a,_0x6d43b8){const _0x49761f=a570_0x9cfd;return db[_0x49761f('0x15')][_0x49761f('0x7')]({'raw':_0x5b2a53[_0x49761f('0xa')]?_0x5b2a53[_0x49761f('0xa')]['raw']===undefined?!![]:![]:!![],'where':_0x5b2a53[_0x49761f('0xa')]?_0x5b2a53[_0x49761f('0xa')][_0x49761f('0xd')]||null:null,'attributes':_0x5b2a53[_0x49761f('0xa')]?_0x5b2a53[_0x49761f('0xa')]['attributes']||null:null,'include':_0x5b2a53['options']?_0x5b2a53[_0x49761f('0xa')][_0x49761f('0x10')]?_[_0x49761f('0x14')](_0x5b2a53[_0x49761f('0xa')]['include'],function(_0x521bb9){const _0x1d26f2=_0x49761f;return{'model':db[_0x521bb9['model']],'as':_0x521bb9['as'],'attributes':_0x521bb9[_0x1d26f2('0xf')],'include':_0x521bb9['include']?_[_0x1d26f2('0x14')](_0x521bb9[_0x1d26f2('0x10')],function(_0x3980dc){const _0x17675f=_0x1d26f2;return{'model':db[_0x3980dc[_0x17675f('0x13')]],'as':_0x3980dc['as'],'attributes':_0x3980dc['attributes'],'include':_0x3980dc[_0x17675f('0x10')]?_[_0x17675f('0x14')](_0x3980dc[_0x17675f('0x10')],function(_0x7bd563){const _0x2a24a9=_0x17675f;return{'model':db[_0x7bd563[_0x2a24a9('0x13')]],'as':_0x7bd563['as'],'attributes':_0x7bd563['attributes']};}):[]};}):[]};}):[]:[]})[_0x49761f('0x12')](function(_0x10d6b8){const _0x526641=_0x49761f;logger[_0x526641('0xe')](_0x526641('0x8'),_0x5b2a53),logger['debug'](_0x526641('0x8'),_0x5b2a53,JSON[_0x526641('0x16')](_0x10d6b8)),_0x58069a(_0x10d6b8);})[_0x49761f('0x1')](function(_0x5413c8){const _0x276ab4=_0x49761f;logger[_0x276ab4('0x0')](_0x276ab4('0x8'),_0x5413c8[_0x276ab4('0x3')],_0x5b2a53),_0x6d43b8(_0x3336e9[_0x276ab4('0x0')](0x1f4,_0x5413c8[_0x276ab4('0x3')]));});});}; \ No newline at end of file diff --git a/server/api/smsQueue/smsQueue.socket.js b/server/api/smsQueue/smsQueue.socket.js index 967cb2e..1f1c383 100644 --- a/server/api/smsQueue/smsQueue.socket.js +++ b/server/api/smsQueue/smsQueue.socket.js @@ -1 +1 @@ -const a571_0x21f7=['emit','update','register','./smsQueue.events','length'];(function(_0x59fccf,_0x21f731){const _0x95d575=function(_0x2e152d){while(--_0x2e152d){_0x59fccf['push'](_0x59fccf['shift']());}};_0x95d575(++_0x21f731);}(a571_0x21f7,0x100));const a571_0x95d5=function(_0x59fccf,_0x21f731){_0x59fccf=_0x59fccf-0x0;let _0x95d575=a571_0x21f7[_0x59fccf];return _0x95d575;};const _0x4ef47f=a571_0x95d5;'use strict';const SmsQueueEvents=require(_0x4ef47f('0x2')),events=['save','remove',_0x4ef47f('0x0')];function createListener(_0x2e152d,_0x277b2c){return function(_0x28cb3d){const _0x28e931=a571_0x95d5;_0x277b2c[_0x28e931('0x4')](_0x2e152d,_0x28cb3d);};}exports[_0x4ef47f('0x1')]=function(_0x2077af){const _0x30b595=_0x4ef47f;for(let _0x425164=0x0,_0x4e1918=events[_0x30b595('0x3')];_0x425164<_0x4e1918;_0x425164++){const _0x3fbf7b=events[_0x425164],_0x598697=createListener('smsQueue:'+_0x3fbf7b,_0x2077af);SmsQueueEvents['on'](_0x3fbf7b,_0x598697);}}; \ No newline at end of file +const a571_0x5641=['remove','save','register','emit','length','smsQueue:','./smsQueue.events','update'];(function(_0x24490a,_0x564133){const _0x2b354a=function(_0xb536ab){while(--_0xb536ab){_0x24490a['push'](_0x24490a['shift']());}};_0x2b354a(++_0x564133);}(a571_0x5641,0x132));const a571_0x2b35=function(_0x24490a,_0x564133){_0x24490a=_0x24490a-0x0;let _0x2b354a=a571_0x5641[_0x24490a];return _0x2b354a;};const _0x47fc5a=a571_0x2b35;'use strict';const SmsQueueEvents=require(_0x47fc5a('0x4')),events=[_0x47fc5a('0x7'),_0x47fc5a('0x6'),_0x47fc5a('0x5')];function createListener(_0xb536ab,_0x3aea7b){return function(_0x3756c3){const _0x49ddf6=a571_0x2b35;_0x3aea7b[_0x49ddf6('0x1')](_0xb536ab,_0x3756c3);};}exports[_0x47fc5a('0x0')]=function(_0x5868fa){const _0x49f8ea=_0x47fc5a;for(let _0x19a6c2=0x0,_0x9291d=events[_0x49f8ea('0x2')];_0x19a6c2<_0x9291d;_0x19a6c2++){const _0x3d3ca1=events[_0x19a6c2],_0x5f01a1=createListener(_0x49f8ea('0x3')+_0x3d3ca1,_0x5868fa);SmsQueueEvents['on'](_0x3d3ca1,_0x5f01a1);}}; \ No newline at end of file diff --git a/server/api/smsQueueReport/index.js b/server/api/smsQueueReport/index.js index d2c1c17..9918094 100644 --- a/server/api/smsQueueReport/index.js +++ b/server/api/smsQueueReport/index.js @@ -1 +1 @@ -const a572_0x2107=['show','/:id','put','../../components/auth/service','get','Router','exports','create','destroy','delete','isAuthenticated'];(function(_0x1740b4,_0x2107fb){const _0x3ba7fb=function(_0x598476){while(--_0x598476){_0x1740b4['push'](_0x1740b4['shift']());}};_0x3ba7fb(++_0x2107fb);}(a572_0x2107,0x1b6));const a572_0x3ba7=function(_0x1740b4,_0x2107fb){_0x1740b4=_0x1740b4-0x0;let _0x3ba7fb=a572_0x2107[_0x1740b4];return _0x3ba7fb;};const _0x376ab6=a572_0x3ba7;'use strict';const express=require('express'),router=express[_0x376ab6('0x7')](),auth=require(_0x376ab6('0x5')),controller=require('./smsQueueReport.controller');router[_0x376ab6('0x6')]('/',auth['isAuthenticated'](),controller['index']),router[_0x376ab6('0x6')]('/describe',auth[_0x376ab6('0x1')](),controller['describe']),router['get']('/:id',auth['isAuthenticated'](),controller[_0x376ab6('0x2')]),router['post']('/',auth[_0x376ab6('0x1')](),controller[_0x376ab6('0x9')]),router[_0x376ab6('0x4')](_0x376ab6('0x3'),auth[_0x376ab6('0x1')](),controller['update']),router[_0x376ab6('0x0')](_0x376ab6('0x3'),auth[_0x376ab6('0x1')](),controller[_0x376ab6('0xa')]),module[_0x376ab6('0x8')]=router; \ No newline at end of file +const a572_0x5740=['get','./smsQueueReport.controller','Router','show','index','delete','destroy','post','/describe','isAuthenticated','describe','create'];(function(_0x3ba5f0,_0x574012){const _0x44d593=function(_0x54eb09){while(--_0x54eb09){_0x3ba5f0['push'](_0x3ba5f0['shift']());}};_0x44d593(++_0x574012);}(a572_0x5740,0x13b));const a572_0x44d5=function(_0x3ba5f0,_0x574012){_0x3ba5f0=_0x3ba5f0-0x0;let _0x44d593=a572_0x5740[_0x3ba5f0];return _0x44d593;};const _0x77931e=a572_0x44d5;'use strict';const express=require('express'),router=express[_0x77931e('0xb')](),auth=require('../../components/auth/service'),controller=require(_0x77931e('0xa'));router[_0x77931e('0x9')]('/',auth[_0x77931e('0x6')](),controller[_0x77931e('0x1')]),router[_0x77931e('0x9')](_0x77931e('0x5'),auth['isAuthenticated'](),controller[_0x77931e('0x7')]),router[_0x77931e('0x9')]('/:id',auth[_0x77931e('0x6')](),controller[_0x77931e('0x0')]),router[_0x77931e('0x4')]('/',auth[_0x77931e('0x6')](),controller[_0x77931e('0x8')]),router['put']('/:id',auth['isAuthenticated'](),controller['update']),router[_0x77931e('0x2')]('/:id',auth[_0x77931e('0x6')](),controller[_0x77931e('0x3')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/smsQueueReport/smsQueueReport.attributes.js b/server/api/smsQueueReport/smsQueueReport.attributes.js index 4c1d1dd..99b756b 100644 --- a/server/api/smsQueueReport/smsQueueReport.attributes.js +++ b/server/api/smsQueueReport/smsQueueReport.attributes.js @@ -1 +1 @@ -const a573_0x21e2=['STRING','exports','DATE','sequelize'];(function(_0x49ca69,_0x21e2a1){const _0x235506=function(_0x2bccca){while(--_0x2bccca){_0x49ca69['push'](_0x49ca69['shift']());}};_0x235506(++_0x21e2a1);}(a573_0x21e2,0xa3));const a573_0x2355=function(_0x49ca69,_0x21e2a1){_0x49ca69=_0x49ca69-0x0;let _0x235506=a573_0x21e2[_0x49ca69];return _0x235506;};const _0x302923=a573_0x2355;'use strict';const Sequelize=require(_0x302923('0x0'));module[_0x302923('0x2')]={'uniqueid':{'type':Sequelize[_0x302923('0x1')],'allowNull':![]},'from':{'type':Sequelize['STRING']},'joinAt':{'type':Sequelize[_0x302923('0x3')]},'leaveAt':{'type':Sequelize['DATE']},'acceptAt':{'type':Sequelize[_0x302923('0x3')]},'exitAt':{'type':Sequelize[_0x302923('0x3')]},'reason':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a573_0x3af1=['STRING','DATE','sequelize'];(function(_0x9c65f7,_0x3af1bd){const _0x439e6d=function(_0x158770){while(--_0x158770){_0x9c65f7['push'](_0x9c65f7['shift']());}};_0x439e6d(++_0x3af1bd);}(a573_0x3af1,0x9c));const a573_0x439e=function(_0x9c65f7,_0x3af1bd){_0x9c65f7=_0x9c65f7-0x0;let _0x439e6d=a573_0x3af1[_0x9c65f7];return _0x439e6d;};const _0x4a7f15=a573_0x439e;'use strict';const Sequelize=require(_0x4a7f15('0x2'));module['exports']={'uniqueid':{'type':Sequelize[_0x4a7f15('0x0')],'allowNull':![]},'from':{'type':Sequelize[_0x4a7f15('0x0')]},'joinAt':{'type':Sequelize[_0x4a7f15('0x1')]},'leaveAt':{'type':Sequelize[_0x4a7f15('0x1')]},'acceptAt':{'type':Sequelize[_0x4a7f15('0x1')]},'exitAt':{'type':Sequelize[_0x4a7f15('0x1')]},'reason':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/smsQueueReport/smsQueueReport.controller.js b/server/api/smsQueueReport/smsQueueReport.controller.js index 5392389..7aa7335 100644 --- a/server/api/smsQueueReport/smsQueueReport.controller.js +++ b/server/api/smsQueueReport/smsQueueReport.controller.js @@ -1 +1 @@ -const a574_0x2062=['then','findAll','nolimit','include','Content-Range','type','destroy','fieldName','VIRTUAL','filter','query','findOne','SmsQueueReport','order','count','describe','../../mysqldb','map','sendStatus','create','options','merge','length','rawAttributes','intersection','status','sort','name','undefined','fields','attributes','body','includeAll','filters','where','rows','api','like','update','pick','../../components/parsers/qs','lodash','limit','stack','json','keys','model','params','set','catch','offset','../../config/logger'];(function(_0x4460b1,_0x2062b3){const _0x3aeed4=function(_0x1019fd){while(--_0x1019fd){_0x4460b1['push'](_0x4460b1['shift']());}};_0x3aeed4(++_0x2062b3);}(a574_0x2062,0x133));const a574_0x3aee=function(_0x4460b1,_0x2062b3){_0x4460b1=_0x4460b1-0x0;let _0x3aeed4=a574_0x2062[_0x4460b1];return _0x3aeed4;};const _0x351da0=a574_0x3aee;'use strict';const _=require(_0x351da0('0x2e')),qs=require(_0x351da0('0x2d')),logger=require(_0x351da0('0x4'))(_0x351da0('0x29')),db=require(_0x351da0('0x15'))['db'],{Op}=require('sequelize');function respondWithResult(_0x1019fd,_0x4b7eca){return _0x4b7eca=_0x4b7eca||0xc8,function(_0x25690d){const _0x2edf8e=a574_0x3aee;if(_0x25690d)return _0x1019fd[_0x2edf8e('0x1e')](_0x4b7eca)[_0x2edf8e('0x31')](_0x25690d);};}function respondWithFilteredResult(_0x34156f,_0x46ff4a){return function(_0x6e618c){const _0x5c2a30=a574_0x3aee;if(_0x6e618c){const _0x53d20d=_0x6e618c[_0x5c2a30('0x13')],_0xeae176=_0x46ff4a[_0x5c2a30('0x3')];let _0x45eb3e=_0x46ff4a[_0x5c2a30('0x3')]+_0x46ff4a[_0x5c2a30('0x2f')],_0x5aa082;return _0x45eb3e>=_0x53d20d?(_0x45eb3e=_0x53d20d,_0x5aa082=0xc8):_0x5aa082=0xce,_0x34156f['status'](_0x5aa082),_0x34156f[_0x5c2a30('0x1')](_0x5c2a30('0x9'),_0xeae176+'-'+_0x45eb3e+'/'+_0x53d20d)[_0x5c2a30('0x31')](_0x6e618c);}return null;};}function saveUpdates(_0x521908){return function(_0x90989a){const _0x5677fb=a574_0x3aee;if(_0x90989a)return _0x90989a[_0x5677fb('0x2b')](_0x521908)[_0x5677fb('0x5')](function(_0x507d39){return _0x507d39;});return null;};}function removeEntity(_0x5a73cf){return function(_0x1aaef4){if(_0x1aaef4)return _0x1aaef4['destroy']()['then'](function(){_0x5a73cf['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x10b018){return function(_0x78ac91){const _0x1dcd59=a574_0x3aee;return!_0x78ac91&&_0x10b018[_0x1dcd59('0x17')](0x194),_0x78ac91;};}function handleError(_0x48eea0,_0x18bdff){return _0x18bdff=_0x18bdff||0x1f4,function(_0x40f1b3){const _0x30f8f1=a574_0x3aee;logger['error'](_0x40f1b3[_0x30f8f1('0x30')]),_0x40f1b3['name']&&delete _0x40f1b3[_0x30f8f1('0x20')],_0x48eea0[_0x30f8f1('0x1e')](_0x18bdff)['send'](_0x40f1b3);};}exports['index']=function(_0x4648b7,_0x406e30){const _0x3ffdcc=_0x351da0;let _0x497d3c={};const _0x2652c8={},_0x5e329f={'count':0x0,'rows':[]},_0x50e316=_['map'](db[_0x3ffdcc('0x11')][_0x3ffdcc('0x1c')],function(_0x46dc9b){const _0x502c72=_0x3ffdcc;return{'name':_0x46dc9b[_0x502c72('0xc')],'type':_0x46dc9b[_0x502c72('0xa')]['key']};});_0x2652c8[_0x3ffdcc('0x33')]=_[_0x3ffdcc('0x16')](_0x50e316,'name'),_0x2652c8[_0x3ffdcc('0xf')]=_[_0x3ffdcc('0x32')](_0x4648b7[_0x3ffdcc('0xf')]),_0x2652c8[_0x3ffdcc('0x26')]=_[_0x3ffdcc('0x1d')](_0x2652c8[_0x3ffdcc('0x33')],_0x2652c8[_0x3ffdcc('0xf')]),_0x497d3c[_0x3ffdcc('0x23')]=_[_0x3ffdcc('0x1d')](_0x2652c8[_0x3ffdcc('0x33')],qs[_0x3ffdcc('0x22')](_0x4648b7[_0x3ffdcc('0xf')]['fields'])),_0x497d3c[_0x3ffdcc('0x23')]=_0x497d3c['attributes'][_0x3ffdcc('0x1b')]?_0x497d3c[_0x3ffdcc('0x23')]:_0x2652c8[_0x3ffdcc('0x33')];typeof _0x4648b7[_0x3ffdcc('0xf')][_0x3ffdcc('0x7')]===_0x3ffdcc('0x21')&&(_0x497d3c['limit']=qs[_0x3ffdcc('0x2f')](_0x4648b7[_0x3ffdcc('0xf')][_0x3ffdcc('0x2f')]),_0x497d3c[_0x3ffdcc('0x3')]=qs['offset'](_0x4648b7['query'][_0x3ffdcc('0x3')]));_0x497d3c[_0x3ffdcc('0x12')]=qs[_0x3ffdcc('0x1f')](_0x4648b7[_0x3ffdcc('0xf')]['sort']),_0x497d3c[_0x3ffdcc('0x27')]=qs['filters'](_[_0x3ffdcc('0x2c')](_0x4648b7['query'],_0x2652c8[_0x3ffdcc('0x26')]),_0x50e316);_0x4648b7[_0x3ffdcc('0xf')][_0x3ffdcc('0xe')]&&(_0x497d3c[_0x3ffdcc('0x27')]=_[_0x3ffdcc('0x1a')](_0x497d3c['where'],{[Op['or']]:_['map'](_0x50e316,function(_0x1a2cb1){const _0x33b2a3=_0x3ffdcc;if(_0x1a2cb1[_0x33b2a3('0xa')]!==_0x33b2a3('0xd')){const _0x5ef368={};return _0x5ef368[_0x1a2cb1[_0x33b2a3('0x20')]]={[Op[_0x33b2a3('0x2a')]]:'%'+_0x4648b7['query'][_0x33b2a3('0xe')]+'%'},_0x5ef368;}})}));_0x497d3c=_[_0x3ffdcc('0x1a')]({},_0x497d3c,_0x4648b7[_0x3ffdcc('0x19')]);const _0x5e9b14={'where':_0x497d3c['where']};return db[_0x3ffdcc('0x11')]['count'](_0x5e9b14)[_0x3ffdcc('0x5')](function(_0x39e15b){const _0x327ae4=_0x3ffdcc;return _0x5e329f['count']=_0x39e15b,_0x4648b7['query'][_0x327ae4('0x25')]&&(_0x497d3c[_0x327ae4('0x8')]=[{'all':!![]}]),db[_0x327ae4('0x11')][_0x327ae4('0x6')](_0x497d3c);})[_0x3ffdcc('0x5')](function(_0x363876){const _0x344054=_0x3ffdcc;return _0x5e329f[_0x344054('0x28')]=_0x363876,_0x5e329f;})[_0x3ffdcc('0x5')](respondWithFilteredResult(_0x406e30,_0x497d3c))[_0x3ffdcc('0x2')](handleError(_0x406e30,null));},exports['show']=function(_0x32c8f9,_0x194a20){const _0x2b5913=_0x351da0;let _0x4d8ccd={'raw':!![],'where':{'id':_0x32c8f9[_0x2b5913('0x0')]['id']}};const _0x9ec974={};return _0x9ec974[_0x2b5913('0x33')]=_[_0x2b5913('0x32')](db[_0x2b5913('0x11')][_0x2b5913('0x1c')]),_0x9ec974[_0x2b5913('0xf')]=_['keys'](_0x32c8f9[_0x2b5913('0xf')]),_0x9ec974[_0x2b5913('0x26')]=_[_0x2b5913('0x1d')](_0x9ec974[_0x2b5913('0x33')],_0x9ec974['query']),_0x4d8ccd['attributes']=_[_0x2b5913('0x1d')](_0x9ec974[_0x2b5913('0x33')],qs[_0x2b5913('0x22')](_0x32c8f9[_0x2b5913('0xf')][_0x2b5913('0x22')])),_0x4d8ccd['attributes']=_0x4d8ccd['attributes'][_0x2b5913('0x1b')]?_0x4d8ccd['attributes']:_0x9ec974[_0x2b5913('0x33')],_0x32c8f9[_0x2b5913('0xf')]['includeAll']&&(_0x4d8ccd[_0x2b5913('0x8')]=[{'all':!![]}]),_0x4d8ccd=_[_0x2b5913('0x1a')]({},_0x4d8ccd,_0x32c8f9[_0x2b5913('0x19')]),db[_0x2b5913('0x11')][_0x2b5913('0x10')](_0x4d8ccd)[_0x2b5913('0x5')](handleEntityNotFound(_0x194a20,null))[_0x2b5913('0x5')](respondWithResult(_0x194a20,null))[_0x2b5913('0x2')](handleError(_0x194a20,null));},exports[_0x351da0('0x18')]=function(_0x4803b0,_0x93ea7b){const _0x1c8698=_0x351da0;return db[_0x1c8698('0x11')][_0x1c8698('0x18')](_0x4803b0[_0x1c8698('0x24')],{})[_0x1c8698('0x5')](respondWithResult(_0x93ea7b,0xc9))[_0x1c8698('0x2')](handleError(_0x93ea7b,null));},exports['update']=function(_0x12989f,_0x4664bc){const _0x20b66a=_0x351da0;return _0x12989f[_0x20b66a('0x24')]['id']&&delete _0x12989f['body']['id'],db[_0x20b66a('0x11')][_0x20b66a('0x10')]({'where':{'id':_0x12989f['params']['id']}})['then'](handleEntityNotFound(_0x4664bc,null))[_0x20b66a('0x5')](saveUpdates(_0x12989f[_0x20b66a('0x24')],null))[_0x20b66a('0x5')](respondWithResult(_0x4664bc,null))[_0x20b66a('0x2')](handleError(_0x4664bc,null));},exports[_0x351da0('0xb')]=function(_0x21c308,_0x3790de){const _0x24eab5=_0x351da0;return db['SmsQueueReport']['findOne']({'where':{'id':_0x21c308[_0x24eab5('0x0')]['id']}})[_0x24eab5('0x5')](handleEntityNotFound(_0x3790de,null))[_0x24eab5('0x5')](removeEntity(_0x3790de,null))[_0x24eab5('0x2')](handleError(_0x3790de,null));},exports['describe']=function(_0x1a1a66,_0x1704fc){const _0xa41c7e=_0x351da0;return db[_0xa41c7e('0x11')][_0xa41c7e('0x14')]()[_0xa41c7e('0x5')](respondWithResult(_0x1704fc,null))[_0xa41c7e('0x2')](handleError(_0x1704fc,null));}; \ No newline at end of file +const a574_0x403c=['sendStatus','show','keys','error','filters','name','offset','sort','../../config/logger','destroy','filter','set','rawAttributes','rows','length','map','then','send','../../components/parsers/qs','type','update','options','attributes','pick','findAll','../../mysqldb','params','describe','model','status','SmsQueueReport','like','api','catch','include','intersection','json','limit','query','merge','sequelize','count','order','VIRTUAL','key','fields','end','where','body','lodash','includeAll','create','findOne'];(function(_0x2cb299,_0x403c8e){const _0x22a377=function(_0x24894f){while(--_0x24894f){_0x2cb299['push'](_0x2cb299['shift']());}};_0x22a377(++_0x403c8e);}(a574_0x403c,0xd3));const a574_0x22a3=function(_0x2cb299,_0x403c8e){_0x2cb299=_0x2cb299-0x0;let _0x22a377=a574_0x403c[_0x2cb299];return _0x22a377;};const _0xa79614=a574_0x22a3;'use strict';const _=require(_0xa79614('0x32')),qs=require(_0xa79614('0x13')),logger=require(_0xa79614('0x9'))(_0xa79614('0x21')),db=require(_0xa79614('0x1a'))['db'],{Op}=require(_0xa79614('0x29'));function respondWithResult(_0x24894f,_0x5c7e8f){return _0x5c7e8f=_0x5c7e8f||0xc8,function(_0x128a0a){const _0x9f93d5=a574_0x22a3;if(_0x128a0a)return _0x24894f[_0x9f93d5('0x1e')](_0x5c7e8f)[_0x9f93d5('0x25')](_0x128a0a);};}function respondWithFilteredResult(_0x419d89,_0x4bf7ab){return function(_0x4acc26){const _0x21481b=a574_0x22a3;if(_0x4acc26){const _0x10faea=_0x4acc26['count'],_0x5f0c30=_0x4bf7ab[_0x21481b('0x7')];let _0x7d7dff=_0x4bf7ab['offset']+_0x4bf7ab[_0x21481b('0x26')],_0x3e86de;return _0x7d7dff>=_0x10faea?(_0x7d7dff=_0x10faea,_0x3e86de=0xc8):_0x3e86de=0xce,_0x419d89[_0x21481b('0x1e')](_0x3e86de),_0x419d89[_0x21481b('0xc')]('Content-Range',_0x5f0c30+'-'+_0x7d7dff+'/'+_0x10faea)['json'](_0x4acc26);}return null;};}function saveUpdates(_0x4ab927){return function(_0x321929){const _0x51ae3f=a574_0x22a3;if(_0x321929)return _0x321929[_0x51ae3f('0x15')](_0x4ab927)[_0x51ae3f('0x11')](function(_0xa646fd){return _0xa646fd;});return null;};}function removeEntity(_0x5272c1){return function(_0x54e9a3){if(_0x54e9a3)return _0x54e9a3['destroy']()['then'](function(){const _0x23a522=a574_0x22a3;_0x5272c1[_0x23a522('0x1e')](0xcc)[_0x23a522('0x2f')]();});};}function handleEntityNotFound(_0x54751d){return function(_0x4759f3){const _0x2d4b62=a574_0x22a3;return!_0x4759f3&&_0x54751d[_0x2d4b62('0x1')](0x194),_0x4759f3;};}function handleError(_0x3471fa,_0x13e149){return _0x13e149=_0x13e149||0x1f4,function(_0x57ea7d){const _0x49a0c7=a574_0x22a3;logger[_0x49a0c7('0x4')](_0x57ea7d['stack']),_0x57ea7d[_0x49a0c7('0x6')]&&delete _0x57ea7d[_0x49a0c7('0x6')],_0x3471fa['status'](_0x13e149)[_0x49a0c7('0x12')](_0x57ea7d);};}exports['index']=function(_0x12bc94,_0x77bcb6){const _0x85692f=_0xa79614;let _0x2e3203={};const _0x262922={},_0x4a7960={'count':0x0,'rows':[]},_0x41d309=_[_0x85692f('0x10')](db[_0x85692f('0x1f')]['rawAttributes'],function(_0x3a724e){const _0x36df2e=_0x85692f;return{'name':_0x3a724e['fieldName'],'type':_0x3a724e[_0x36df2e('0x14')][_0x36df2e('0x2d')]};});_0x262922[_0x85692f('0x1d')]=_[_0x85692f('0x10')](_0x41d309,_0x85692f('0x6')),_0x262922['query']=_[_0x85692f('0x3')](_0x12bc94[_0x85692f('0x27')]),_0x262922[_0x85692f('0x5')]=_[_0x85692f('0x24')](_0x262922[_0x85692f('0x1d')],_0x262922['query']),_0x2e3203[_0x85692f('0x17')]=_[_0x85692f('0x24')](_0x262922[_0x85692f('0x1d')],qs[_0x85692f('0x2e')](_0x12bc94[_0x85692f('0x27')][_0x85692f('0x2e')])),_0x2e3203[_0x85692f('0x17')]=_0x2e3203['attributes'][_0x85692f('0xf')]?_0x2e3203[_0x85692f('0x17')]:_0x262922[_0x85692f('0x1d')];typeof _0x12bc94['query']['nolimit']==='undefined'&&(_0x2e3203[_0x85692f('0x26')]=qs['limit'](_0x12bc94[_0x85692f('0x27')][_0x85692f('0x26')]),_0x2e3203[_0x85692f('0x7')]=qs['offset'](_0x12bc94[_0x85692f('0x27')]['offset']));_0x2e3203[_0x85692f('0x2b')]=qs[_0x85692f('0x8')](_0x12bc94[_0x85692f('0x27')][_0x85692f('0x8')]),_0x2e3203[_0x85692f('0x30')]=qs['filters'](_[_0x85692f('0x18')](_0x12bc94['query'],_0x262922[_0x85692f('0x5')]),_0x41d309);_0x12bc94['query'][_0x85692f('0xb')]&&(_0x2e3203[_0x85692f('0x30')]=_[_0x85692f('0x28')](_0x2e3203[_0x85692f('0x30')],{[Op['or']]:_[_0x85692f('0x10')](_0x41d309,function(_0x5df54a){const _0xe1d4b6=_0x85692f;if(_0x5df54a[_0xe1d4b6('0x14')]!==_0xe1d4b6('0x2c')){const _0x152673={};return _0x152673[_0x5df54a[_0xe1d4b6('0x6')]]={[Op[_0xe1d4b6('0x20')]]:'%'+_0x12bc94[_0xe1d4b6('0x27')][_0xe1d4b6('0xb')]+'%'},_0x152673;}})}));_0x2e3203=_[_0x85692f('0x28')]({},_0x2e3203,_0x12bc94['options']);const _0x528c11={'where':_0x2e3203[_0x85692f('0x30')]};return db[_0x85692f('0x1f')][_0x85692f('0x2a')](_0x528c11)['then'](function(_0xb9dccf){const _0x3feb3a=_0x85692f;return _0x4a7960[_0x3feb3a('0x2a')]=_0xb9dccf,_0x12bc94[_0x3feb3a('0x27')][_0x3feb3a('0x33')]&&(_0x2e3203[_0x3feb3a('0x23')]=[{'all':!![]}]),db[_0x3feb3a('0x1f')][_0x3feb3a('0x19')](_0x2e3203);})[_0x85692f('0x11')](function(_0x35939f){const _0x419f64=_0x85692f;return _0x4a7960[_0x419f64('0xe')]=_0x35939f,_0x4a7960;})[_0x85692f('0x11')](respondWithFilteredResult(_0x77bcb6,_0x2e3203))[_0x85692f('0x22')](handleError(_0x77bcb6,null));},exports[_0xa79614('0x2')]=function(_0x6e7810,_0x1a419f){const _0x15dc61=_0xa79614;let _0x3fd0f6={'raw':!![],'where':{'id':_0x6e7810[_0x15dc61('0x1b')]['id']}};const _0xc12630={};return _0xc12630[_0x15dc61('0x1d')]=_['keys'](db['SmsQueueReport'][_0x15dc61('0xd')]),_0xc12630[_0x15dc61('0x27')]=_[_0x15dc61('0x3')](_0x6e7810[_0x15dc61('0x27')]),_0xc12630[_0x15dc61('0x5')]=_[_0x15dc61('0x24')](_0xc12630[_0x15dc61('0x1d')],_0xc12630[_0x15dc61('0x27')]),_0x3fd0f6[_0x15dc61('0x17')]=_[_0x15dc61('0x24')](_0xc12630['model'],qs[_0x15dc61('0x2e')](_0x6e7810['query']['fields'])),_0x3fd0f6[_0x15dc61('0x17')]=_0x3fd0f6[_0x15dc61('0x17')][_0x15dc61('0xf')]?_0x3fd0f6[_0x15dc61('0x17')]:_0xc12630[_0x15dc61('0x1d')],_0x6e7810['query'][_0x15dc61('0x33')]&&(_0x3fd0f6[_0x15dc61('0x23')]=[{'all':!![]}]),_0x3fd0f6=_['merge']({},_0x3fd0f6,_0x6e7810[_0x15dc61('0x16')]),db['SmsQueueReport']['findOne'](_0x3fd0f6)['then'](handleEntityNotFound(_0x1a419f,null))['then'](respondWithResult(_0x1a419f,null))[_0x15dc61('0x22')](handleError(_0x1a419f,null));},exports[_0xa79614('0x34')]=function(_0x1de555,_0x543934){const _0x8ea980=_0xa79614;return db['SmsQueueReport'][_0x8ea980('0x34')](_0x1de555[_0x8ea980('0x31')],{})['then'](respondWithResult(_0x543934,0xc9))[_0x8ea980('0x22')](handleError(_0x543934,null));},exports[_0xa79614('0x15')]=function(_0x878b6,_0x16ca74){const _0x56ca2f=_0xa79614;return _0x878b6[_0x56ca2f('0x31')]['id']&&delete _0x878b6[_0x56ca2f('0x31')]['id'],db['SmsQueueReport'][_0x56ca2f('0x0')]({'where':{'id':_0x878b6['params']['id']}})[_0x56ca2f('0x11')](handleEntityNotFound(_0x16ca74,null))[_0x56ca2f('0x11')](saveUpdates(_0x878b6[_0x56ca2f('0x31')],null))['then'](respondWithResult(_0x16ca74,null))[_0x56ca2f('0x22')](handleError(_0x16ca74,null));},exports[_0xa79614('0xa')]=function(_0x259e1f,_0x36fcdd){const _0x36d303=_0xa79614;return db[_0x36d303('0x1f')][_0x36d303('0x0')]({'where':{'id':_0x259e1f[_0x36d303('0x1b')]['id']}})[_0x36d303('0x11')](handleEntityNotFound(_0x36fcdd,null))[_0x36d303('0x11')](removeEntity(_0x36fcdd,null))[_0x36d303('0x22')](handleError(_0x36fcdd,null));},exports['describe']=function(_0x55d117,_0x19e5d5){const _0x1fefe6=_0xa79614;return db[_0x1fefe6('0x1f')][_0x1fefe6('0x1c')]()[_0x1fefe6('0x11')](respondWithResult(_0x19e5d5,null))[_0x1fefe6('0x22')](handleError(_0x19e5d5,null));}; \ No newline at end of file diff --git a/server/api/smsQueueReport/smsQueueReport.model.js b/server/api/smsQueueReport/smsQueueReport.model.js index f058283..6d660cb 100644 --- a/server/api/smsQueueReport/smsQueueReport.model.js +++ b/server/api/smsQueueReport/smsQueueReport.model.js @@ -1 +1 @@ -const a575_0x2e7f=['exports','report_sms_queue','uniqueid','./smsQueueReport.attributes','SmsQueueReport'];(function(_0x274126,_0x2e7fdc){const _0x386856=function(_0x478f8d){while(--_0x478f8d){_0x274126['push'](_0x274126['shift']());}};_0x386856(++_0x2e7fdc);}(a575_0x2e7f,0xbb));const a575_0x3868=function(_0x274126,_0x2e7fdc){_0x274126=_0x274126-0x0;let _0x386856=a575_0x2e7f[_0x274126];return _0x386856;};const _0x5b7fec=a575_0x3868;'use strict';const attributes=require(_0x5b7fec('0x1'));module[_0x5b7fec('0x3')]=function(_0x478f8d){const _0x3974cc=_0x5b7fec,_0x2b593f=_0x478f8d['define'](_0x3974cc('0x2'),attributes,{'tableName':_0x3974cc('0x4'),'paranoid':![],'indexes':[{'name':_0x3974cc('0x0'),'fields':[_0x3974cc('0x0')]}],'timestamps':!![]});return _0x2b593f;}; \ No newline at end of file +const a575_0xbdcb=['report_sms_queue','exports','uniqueid','SmsQueueReport'];(function(_0x5771bf,_0xbdcba1){const _0x41d88f=function(_0x133740){while(--_0x133740){_0x5771bf['push'](_0x5771bf['shift']());}};_0x41d88f(++_0xbdcba1);}(a575_0xbdcb,0x15a));const a575_0x41d8=function(_0x5771bf,_0xbdcba1){_0x5771bf=_0x5771bf-0x0;let _0x41d88f=a575_0xbdcb[_0x5771bf];return _0x41d88f;};const _0x51b120=a575_0x41d8;'use strict';const attributes=require('./smsQueueReport.attributes');module[_0x51b120('0x3')]=function(_0x133740){const _0x4c2744=_0x51b120,_0x4ecf0a=_0x133740['define'](_0x4c2744('0x1'),attributes,{'tableName':_0x4c2744('0x2'),'paranoid':![],'indexes':[{'name':'uniqueid','fields':[_0x4c2744('0x0')]}],'timestamps':!![]});return _0x4ecf0a;}; \ No newline at end of file diff --git a/server/api/smsQueueReport/smsQueueReport.rpc.js b/server/api/smsQueueReport/smsQueueReport.rpc.js index c668c8b..96b1ec4 100644 --- a/server/api/smsQueueReport/smsQueueReport.rpc.js +++ b/server/api/smsQueueReport/smsQueueReport.rpc.js @@ -1 +1 @@ -const a576_0x1435=['rpc','limit','stringify','debug','message','then','UpdateSmsQueueReport','attributes','catch','where','info','update','error','options','body','SmsQueueReport','raw','CreateSmsQueueReport'];(function(_0x55fc78,_0x1435b7){const _0x1bacfc=function(_0x26b90d){while(--_0x26b90d){_0x55fc78['push'](_0x55fc78['shift']());}};_0x1bacfc(++_0x1435b7);}(a576_0x1435,0x81));const a576_0x1bac=function(_0x55fc78,_0x1435b7){_0x55fc78=_0x55fc78-0x0;let _0x1bacfc=a576_0x1435[_0x55fc78];return _0x1bacfc;};const _0x19b2b1=a576_0x1bac;'use strict';const db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x19b2b1('0xf'));exports['CreateSmsQueueReport']=function(_0x26b90d){const _0x37c541=this;return new Promise(function(_0x4f2d74,_0x159f02){const _0x5aaf68=a576_0x1bac;return db['SmsQueueReport']['create'](_0x26b90d['body'],{'raw':_0x26b90d['options']?_0x26b90d[_0x5aaf68('0xa')][_0x5aaf68('0xd')]===undefined?!![]:![]:!![]})[_0x5aaf68('0x2')](function(_0x127e3a){const _0x1ac6d3=_0x5aaf68;logger[_0x1ac6d3('0x7')](_0x1ac6d3('0xe'),_0x26b90d),logger['debug'](_0x1ac6d3('0xe'),_0x26b90d,JSON[_0x1ac6d3('0x11')](_0x127e3a)),_0x4f2d74(_0x127e3a);})[_0x5aaf68('0x5')](function(_0x47b4eb){const _0x97ba7e=_0x5aaf68;logger[_0x97ba7e('0x9')](_0x97ba7e('0xe'),_0x47b4eb[_0x97ba7e('0x1')],_0x26b90d),_0x159f02(_0x37c541[_0x97ba7e('0x9')](0x1f4,_0x47b4eb[_0x97ba7e('0x1')]));});});},exports[_0x19b2b1('0x3')]=function(_0x5b8eea){const _0x4be7ce=this;return new Promise(function(_0x14c9e4,_0x49ad93){const _0x31cfe9=a576_0x1bac;return db[_0x31cfe9('0xc')][_0x31cfe9('0x8')](_0x5b8eea[_0x31cfe9('0xb')],{'raw':_0x5b8eea['options']?_0x5b8eea[_0x31cfe9('0xa')][_0x31cfe9('0xd')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x5b8eea[_0x31cfe9('0xa')]?_0x5b8eea[_0x31cfe9('0xa')][_0x31cfe9('0x6')]||null:null,'attributes':_0x5b8eea[_0x31cfe9('0xa')]?_0x5b8eea[_0x31cfe9('0xa')][_0x31cfe9('0x4')]||null:null,'limit':_0x5b8eea[_0x31cfe9('0xa')]?_0x5b8eea[_0x31cfe9('0xa')][_0x31cfe9('0x10')]||null:null})[_0x31cfe9('0x2')](function(_0x4a78bc){const _0x5a1688=_0x31cfe9;logger[_0x5a1688('0x7')]('UpdateSmsQueueReport',_0x5b8eea),logger[_0x5a1688('0x0')](_0x5a1688('0x3'),_0x5b8eea,JSON[_0x5a1688('0x11')](_0x4a78bc)),_0x14c9e4(_0x4a78bc);})['catch'](function(_0x3fd353){const _0x14b221=_0x31cfe9;logger[_0x14b221('0x9')]('UpdateSmsQueueReport',_0x3fd353[_0x14b221('0x1')],_0x5b8eea),_0x49ad93(_0x4be7ce[_0x14b221('0x9')](0x1f4,_0x3fd353[_0x14b221('0x1')]));});});}; \ No newline at end of file +const a576_0x502c=['SmsQueueReport','raw','debug','create','UpdateSmsQueueReport','../../mysqldb','stringify','CreateSmsQueueReport','body','then','../../config/logger','where','info','message','options','limit','update','error','catch'];(function(_0x124a14,_0x502c24){const _0x1b7e97=function(_0x19d7b6){while(--_0x19d7b6){_0x124a14['push'](_0x124a14['shift']());}};_0x1b7e97(++_0x502c24);}(a576_0x502c,0x1a9));const a576_0x1b7e=function(_0x124a14,_0x502c24){_0x124a14=_0x124a14-0x0;let _0x1b7e97=a576_0x502c[_0x124a14];return _0x1b7e97;};const _0x56c439=a576_0x1b7e;'use strict';const db=require(_0x56c439('0x11'))['db'],logger=require(_0x56c439('0x3'))('rpc');exports[_0x56c439('0x0')]=function(_0x19d7b6){const _0x54a2aa=this;return new Promise(function(_0x108271,_0x1c70d6){const _0x4a7203=a576_0x1b7e;return db[_0x4a7203('0xc')][_0x4a7203('0xf')](_0x19d7b6[_0x4a7203('0x1')],{'raw':_0x19d7b6[_0x4a7203('0x7')]?_0x19d7b6['options'][_0x4a7203('0xd')]===undefined?!![]:![]:!![]})[_0x4a7203('0x2')](function(_0x386609){const _0x1edc60=_0x4a7203;logger[_0x1edc60('0x5')](_0x1edc60('0x0'),_0x19d7b6),logger[_0x1edc60('0xe')](_0x1edc60('0x0'),_0x19d7b6,JSON[_0x1edc60('0x12')](_0x386609)),_0x108271(_0x386609);})[_0x4a7203('0xb')](function(_0x413663){const _0x15d88e=_0x4a7203;logger['error'](_0x15d88e('0x0'),_0x413663[_0x15d88e('0x6')],_0x19d7b6),_0x1c70d6(_0x54a2aa[_0x15d88e('0xa')](0x1f4,_0x413663[_0x15d88e('0x6')]));});});},exports['UpdateSmsQueueReport']=function(_0x2e4bea){const _0x28d037=this;return new Promise(function(_0x306022,_0x3f2e1b){const _0x3d44f5=a576_0x1b7e;return db[_0x3d44f5('0xc')][_0x3d44f5('0x9')](_0x2e4bea[_0x3d44f5('0x1')],{'raw':_0x2e4bea[_0x3d44f5('0x7')]?_0x2e4bea[_0x3d44f5('0x7')][_0x3d44f5('0xd')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x2e4bea[_0x3d44f5('0x7')]?_0x2e4bea[_0x3d44f5('0x7')][_0x3d44f5('0x4')]||null:null,'attributes':_0x2e4bea[_0x3d44f5('0x7')]?_0x2e4bea[_0x3d44f5('0x7')]['attributes']||null:null,'limit':_0x2e4bea['options']?_0x2e4bea[_0x3d44f5('0x7')][_0x3d44f5('0x8')]||null:null})[_0x3d44f5('0x2')](function(_0x5ddfc1){const _0x589b9d=_0x3d44f5;logger[_0x589b9d('0x5')](_0x589b9d('0x10'),_0x2e4bea),logger['debug'](_0x589b9d('0x10'),_0x2e4bea,JSON[_0x589b9d('0x12')](_0x5ddfc1)),_0x306022(_0x5ddfc1);})[_0x3d44f5('0xb')](function(_0x4cd0b2){const _0x5c2a17=_0x3d44f5;logger[_0x5c2a17('0xa')]('UpdateSmsQueueReport',_0x4cd0b2[_0x5c2a17('0x6')],_0x2e4bea),_0x3f2e1b(_0x28d037[_0x5c2a17('0xa')](0x1f4,_0x4cd0b2[_0x5c2a17('0x6')]));});});}; \ No newline at end of file diff --git a/server/api/smsTransferReport/index.js b/server/api/smsTransferReport/index.js index c2430e6..3408088 100644 --- a/server/api/smsTransferReport/index.js +++ b/server/api/smsTransferReport/index.js @@ -1 +1 @@ -const a577_0x1e9f=['/describe','get','index','./smsTransferReport.controller','delete','exports','show','describe','/:id','isAuthenticated','../../components/auth/service','Router','destroy','express'];(function(_0xf809fe,_0x1e9ffe){const _0x99e9e0=function(_0x18858e){while(--_0x18858e){_0xf809fe['push'](_0xf809fe['shift']());}};_0x99e9e0(++_0x1e9ffe);}(a577_0x1e9f,0x10b));const a577_0x99e9=function(_0xf809fe,_0x1e9ffe){_0xf809fe=_0xf809fe-0x0;let _0x99e9e0=a577_0x1e9f[_0xf809fe];return _0x99e9e0;};const _0x4096e2=a577_0x99e9;'use strict';const express=require(_0x4096e2('0xc')),router=express[_0x4096e2('0xa')](),auth=require(_0x4096e2('0x9')),controller=require(_0x4096e2('0x2'));router[_0x4096e2('0x0')]('/',auth[_0x4096e2('0x8')](),controller[_0x4096e2('0x1')]),router[_0x4096e2('0x0')](_0x4096e2('0xd'),auth[_0x4096e2('0x8')](),controller[_0x4096e2('0x6')]),router[_0x4096e2('0x0')](_0x4096e2('0x7'),auth['isAuthenticated'](),controller[_0x4096e2('0x5')]),router['post']('/',auth['isAuthenticated'](),controller['create']),router['put']('/:id',auth[_0x4096e2('0x8')](),controller['update']),router[_0x4096e2('0x3')](_0x4096e2('0x7'),auth['isAuthenticated'](),controller[_0x4096e2('0xb')]),module[_0x4096e2('0x4')]=router; \ No newline at end of file +const a577_0x5dba=['put','Router','delete','get','isAuthenticated','../../components/auth/service','post','index','destroy','/describe','describe','create','show','express','/:id'];(function(_0xc3af98,_0x5dba64){const _0xc389e7=function(_0x226c19){while(--_0x226c19){_0xc3af98['push'](_0xc3af98['shift']());}};_0xc389e7(++_0x5dba64);}(a577_0x5dba,0xc8));const a577_0xc389=function(_0xc3af98,_0x5dba64){_0xc3af98=_0xc3af98-0x0;let _0xc389e7=a577_0x5dba[_0xc3af98];return _0xc389e7;};const _0x1641f9=a577_0xc389;'use strict';const express=require(_0x1641f9('0x8')),router=express[_0x1641f9('0xb')](),auth=require(_0x1641f9('0x0')),controller=require('./smsTransferReport.controller');router[_0x1641f9('0xd')]('/',auth[_0x1641f9('0xe')](),controller[_0x1641f9('0x2')]),router['get'](_0x1641f9('0x4'),auth[_0x1641f9('0xe')](),controller[_0x1641f9('0x5')]),router[_0x1641f9('0xd')](_0x1641f9('0x9'),auth[_0x1641f9('0xe')](),controller[_0x1641f9('0x7')]),router[_0x1641f9('0x1')]('/',auth[_0x1641f9('0xe')](),controller[_0x1641f9('0x6')]),router[_0x1641f9('0xa')](_0x1641f9('0x9'),auth['isAuthenticated'](),controller['update']),router[_0x1641f9('0xc')](_0x1641f9('0x9'),auth['isAuthenticated'](),controller[_0x1641f9('0x3')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/smsTransferReport/smsTransferReport.attributes.js b/server/api/smsTransferReport/smsTransferReport.attributes.js index 9a43262..7bac4fc 100644 --- a/server/api/smsTransferReport/smsTransferReport.attributes.js +++ b/server/api/smsTransferReport/smsTransferReport.attributes.js @@ -1 +1 @@ -const a578_0x3e72=['queue','sequelize','ENUM','DATE','agent','account','NOW','exports','STRING'];(function(_0x2589f1,_0x3e72e4){const _0x17db36=function(_0x3045cc){while(--_0x3045cc){_0x2589f1['push'](_0x2589f1['shift']());}};_0x17db36(++_0x3e72e4);}(a578_0x3e72,0x1a2));const a578_0x17db=function(_0x2589f1,_0x3e72e4){_0x2589f1=_0x2589f1-0x0;let _0x17db36=a578_0x3e72[_0x2589f1];return _0x17db36;};const _0x4964f3=a578_0x17db;'use strict';const Sequelize=require(_0x4964f3('0x6'));module[_0x4964f3('0x3')]={'uniqueid':{'type':Sequelize[_0x4964f3('0x4')],'allowNull':![]},'type':{'type':Sequelize[_0x4964f3('0x7')](_0x4964f3('0x1'),_0x4964f3('0x0'),_0x4964f3('0x5')),'allowNull':![],'defaultValue':'queue'},'transferredAt':{'type':Sequelize[_0x4964f3('0x8')],'allowNull':![],'defaultValue':Sequelize[_0x4964f3('0x2')]}}; \ No newline at end of file +const a578_0x14e1=['account','queue','DATE','NOW','sequelize','ENUM','exports'];(function(_0x2b4f63,_0x14e1f6){const _0x384d3a=function(_0x3c2825){while(--_0x3c2825){_0x2b4f63['push'](_0x2b4f63['shift']());}};_0x384d3a(++_0x14e1f6);}(a578_0x14e1,0xf4));const a578_0x384d=function(_0x2b4f63,_0x14e1f6){_0x2b4f63=_0x2b4f63-0x0;let _0x384d3a=a578_0x14e1[_0x2b4f63];return _0x384d3a;};const _0x2509df=a578_0x384d;'use strict';const Sequelize=require(_0x2509df('0x5'));module[_0x2509df('0x0')]={'uniqueid':{'type':Sequelize['STRING'],'allowNull':![]},'type':{'type':Sequelize[_0x2509df('0x6')](_0x2509df('0x1'),'agent',_0x2509df('0x2')),'allowNull':![],'defaultValue':_0x2509df('0x2')},'transferredAt':{'type':Sequelize[_0x2509df('0x3')],'allowNull':![],'defaultValue':Sequelize[_0x2509df('0x4')]}}; \ No newline at end of file diff --git a/server/api/smsTransferReport/smsTransferReport.controller.js b/server/api/smsTransferReport/smsTransferReport.controller.js index 0c6e753..4aa7a00 100644 --- a/server/api/smsTransferReport/smsTransferReport.controller.js +++ b/server/api/smsTransferReport/smsTransferReport.controller.js @@ -1 +1 @@ -const a579_0x2a1b=['includeAll','type','attributes','sort','stack','findOne','../../config/logger','create','sequelize','end','fields','then','name','intersection','options','keys','length','map','../../mysqldb','count','filters','error','api','params','status','limit','merge','query','undefined','model','update','destroy','offset','SmsTransferReport','filter','pick','rawAttributes','fieldName','findAll','include','json','catch','where','../../components/parsers/qs','order','sendStatus','lodash','body','send'];(function(_0x2842ad,_0x2a1b63){const _0x5deb51=function(_0x1a5783){while(--_0x1a5783){_0x2842ad['push'](_0x2842ad['shift']());}};_0x5deb51(++_0x2a1b63);}(a579_0x2a1b,0xaf));const a579_0x5deb=function(_0x2842ad,_0x2a1b63){_0x2842ad=_0x2842ad-0x0;let _0x5deb51=a579_0x2a1b[_0x2842ad];return _0x5deb51;};const _0x1df7b0=a579_0x5deb;'use strict';const _=require(_0x1df7b0('0x12')),qs=require(_0x1df7b0('0xf')),logger=require(_0x1df7b0('0x1b'))(_0x1df7b0('0x2b')),db=require(_0x1df7b0('0x27'))['db'],{Op}=require(_0x1df7b0('0x1d'));function respondWithResult(_0x1a5783,_0x22055d){return _0x22055d=_0x22055d||0xc8,function(_0xaf4de5){const _0x4af569=a579_0x5deb;if(_0xaf4de5)return _0x1a5783[_0x4af569('0x2d')](_0x22055d)['json'](_0xaf4de5);};}function respondWithFilteredResult(_0x1f708c,_0x4abf44){return function(_0x3be775){const _0x5846e5=a579_0x5deb;if(_0x3be775){const _0x388bb5=_0x3be775[_0x5846e5('0x28')],_0x7efd3a=_0x4abf44[_0x5846e5('0x4')];let _0x185d6b=_0x4abf44[_0x5846e5('0x4')]+_0x4abf44[_0x5846e5('0x2e')],_0x1d38ec;return _0x185d6b>=_0x388bb5?(_0x185d6b=_0x388bb5,_0x1d38ec=0xc8):_0x1d38ec=0xce,_0x1f708c[_0x5846e5('0x2d')](_0x1d38ec),_0x1f708c['set']('Content-Range',_0x7efd3a+'-'+_0x185d6b+'/'+_0x388bb5)[_0x5846e5('0xc')](_0x3be775);}return null;};}function saveUpdates(_0x22f9c3){return function(_0x59047a){const _0x33f400=a579_0x5deb;if(_0x59047a)return _0x59047a[_0x33f400('0x2')](_0x22f9c3)[_0x33f400('0x20')](function(_0x4d905b){return _0x4d905b;});return null;};}function removeEntity(_0x2306c5){return function(_0x41e56c){const _0x32869b=a579_0x5deb;if(_0x41e56c)return _0x41e56c[_0x32869b('0x3')]()['then'](function(){const _0x4f30ac=_0x32869b;_0x2306c5['status'](0xcc)[_0x4f30ac('0x1e')]();});};}function handleEntityNotFound(_0x34ff6e){return function(_0x40c7bb){const _0x436307=a579_0x5deb;return!_0x40c7bb&&_0x34ff6e[_0x436307('0x11')](0x194),_0x40c7bb;};}function handleError(_0x48185b,_0x1ff97f){return _0x1ff97f=_0x1ff97f||0x1f4,function(_0x11e884){const _0x3836c8=a579_0x5deb;logger[_0x3836c8('0x2a')](_0x11e884[_0x3836c8('0x19')]),_0x11e884['name']&&delete _0x11e884[_0x3836c8('0x21')],_0x48185b['status'](_0x1ff97f)[_0x3836c8('0x14')](_0x11e884);};}exports['index']=function(_0x2dc0d2,_0x4cc33e){const _0x29f5a6=_0x1df7b0;let _0x2294aa={};const _0x152897={},_0x30e4b8={'count':0x0,'rows':[]},_0x8e58ce=_[_0x29f5a6('0x26')](db[_0x29f5a6('0x5')][_0x29f5a6('0x8')],function(_0x4452dd){const _0x140203=_0x29f5a6;return{'name':_0x4452dd[_0x140203('0x9')],'type':_0x4452dd['type']['key']};});_0x152897[_0x29f5a6('0x1')]=_[_0x29f5a6('0x26')](_0x8e58ce,_0x29f5a6('0x21')),_0x152897['query']=_[_0x29f5a6('0x24')](_0x2dc0d2[_0x29f5a6('0x30')]),_0x152897[_0x29f5a6('0x29')]=_['intersection'](_0x152897[_0x29f5a6('0x1')],_0x152897[_0x29f5a6('0x30')]),_0x2294aa[_0x29f5a6('0x17')]=_[_0x29f5a6('0x22')](_0x152897['model'],qs[_0x29f5a6('0x1f')](_0x2dc0d2['query'][_0x29f5a6('0x1f')])),_0x2294aa[_0x29f5a6('0x17')]=_0x2294aa['attributes'][_0x29f5a6('0x25')]?_0x2294aa['attributes']:_0x152897[_0x29f5a6('0x1')];typeof _0x2dc0d2[_0x29f5a6('0x30')]['nolimit']===_0x29f5a6('0x0')&&(_0x2294aa['limit']=qs['limit'](_0x2dc0d2[_0x29f5a6('0x30')]['limit']),_0x2294aa[_0x29f5a6('0x4')]=qs[_0x29f5a6('0x4')](_0x2dc0d2[_0x29f5a6('0x30')]['offset']));_0x2294aa[_0x29f5a6('0x10')]=qs[_0x29f5a6('0x18')](_0x2dc0d2[_0x29f5a6('0x30')][_0x29f5a6('0x18')]),_0x2294aa[_0x29f5a6('0xe')]=qs[_0x29f5a6('0x29')](_[_0x29f5a6('0x7')](_0x2dc0d2[_0x29f5a6('0x30')],_0x152897[_0x29f5a6('0x29')]),_0x8e58ce);_0x2dc0d2[_0x29f5a6('0x30')][_0x29f5a6('0x6')]&&(_0x2294aa['where']=_['merge'](_0x2294aa[_0x29f5a6('0xe')],{[Op['or']]:_['map'](_0x8e58ce,function(_0x53281e){const _0xcba5d5=_0x29f5a6;if(_0x53281e[_0xcba5d5('0x16')]!=='VIRTUAL'){const _0x101181={};return _0x101181[_0x53281e[_0xcba5d5('0x21')]]={[Op['like']]:'%'+_0x2dc0d2[_0xcba5d5('0x30')][_0xcba5d5('0x6')]+'%'},_0x101181;}})}));_0x2294aa=_[_0x29f5a6('0x2f')]({},_0x2294aa,_0x2dc0d2[_0x29f5a6('0x23')]);const _0x430c77={'where':_0x2294aa[_0x29f5a6('0xe')]};return db[_0x29f5a6('0x5')]['count'](_0x430c77)[_0x29f5a6('0x20')](function(_0x25ac55){const _0x5fbe93=_0x29f5a6;return _0x30e4b8[_0x5fbe93('0x28')]=_0x25ac55,_0x2dc0d2[_0x5fbe93('0x30')]['includeAll']&&(_0x2294aa[_0x5fbe93('0xb')]=[{'all':!![]}]),db[_0x5fbe93('0x5')][_0x5fbe93('0xa')](_0x2294aa);})[_0x29f5a6('0x20')](function(_0x3aa88a){return _0x30e4b8['rows']=_0x3aa88a,_0x30e4b8;})[_0x29f5a6('0x20')](respondWithFilteredResult(_0x4cc33e,_0x2294aa))['catch'](handleError(_0x4cc33e,null));},exports['show']=function(_0x11b96b,_0x11d723){const _0x34c719=_0x1df7b0;let _0x466e38={'raw':!![],'where':{'id':_0x11b96b[_0x34c719('0x2c')]['id']}};const _0x435233={};return _0x435233[_0x34c719('0x1')]=_['keys'](db[_0x34c719('0x5')][_0x34c719('0x8')]),_0x435233['query']=_['keys'](_0x11b96b[_0x34c719('0x30')]),_0x435233[_0x34c719('0x29')]=_[_0x34c719('0x22')](_0x435233[_0x34c719('0x1')],_0x435233['query']),_0x466e38[_0x34c719('0x17')]=_['intersection'](_0x435233[_0x34c719('0x1')],qs[_0x34c719('0x1f')](_0x11b96b[_0x34c719('0x30')]['fields'])),_0x466e38[_0x34c719('0x17')]=_0x466e38[_0x34c719('0x17')][_0x34c719('0x25')]?_0x466e38[_0x34c719('0x17')]:_0x435233['model'],_0x11b96b[_0x34c719('0x30')][_0x34c719('0x15')]&&(_0x466e38[_0x34c719('0xb')]=[{'all':!![]}]),_0x466e38=_['merge']({},_0x466e38,_0x11b96b[_0x34c719('0x23')]),db['SmsTransferReport']['findOne'](_0x466e38)[_0x34c719('0x20')](handleEntityNotFound(_0x11d723,null))[_0x34c719('0x20')](respondWithResult(_0x11d723,null))[_0x34c719('0xd')](handleError(_0x11d723,null));},exports[_0x1df7b0('0x1c')]=function(_0x64f467,_0x1f8d6d){const _0x5a7e82=_0x1df7b0;return db['SmsTransferReport'][_0x5a7e82('0x1c')](_0x64f467[_0x5a7e82('0x13')],{})[_0x5a7e82('0x20')](respondWithResult(_0x1f8d6d,0xc9))[_0x5a7e82('0xd')](handleError(_0x1f8d6d,null));},exports['update']=function(_0x355b53,_0x4b14b5){const _0x274170=_0x1df7b0;return _0x355b53[_0x274170('0x13')]['id']&&delete _0x355b53['body']['id'],db[_0x274170('0x5')][_0x274170('0x1a')]({'where':{'id':_0x355b53['params']['id']}})[_0x274170('0x20')](handleEntityNotFound(_0x4b14b5,null))[_0x274170('0x20')](saveUpdates(_0x355b53[_0x274170('0x13')],null))[_0x274170('0x20')](respondWithResult(_0x4b14b5,null))[_0x274170('0xd')](handleError(_0x4b14b5,null));},exports[_0x1df7b0('0x3')]=function(_0x40b00c,_0x5389b9){const _0x5a12f5=_0x1df7b0;return db[_0x5a12f5('0x5')][_0x5a12f5('0x1a')]({'where':{'id':_0x40b00c['params']['id']}})['then'](handleEntityNotFound(_0x5389b9,null))[_0x5a12f5('0x20')](removeEntity(_0x5389b9,null))[_0x5a12f5('0xd')](handleError(_0x5389b9,null));},exports['describe']=function(_0x587b9b,_0x7a4e3b){const _0x28d4b8=_0x1df7b0;return db[_0x28d4b8('0x5')]['describe']()[_0x28d4b8('0x20')](respondWithResult(_0x7a4e3b,null))['catch'](handleError(_0x7a4e3b,null));}; \ No newline at end of file +const a579_0x2c24=['destroy','where','rows','json','findAll','merge','../../mysqldb','fields','end','describe','create','show','lodash','stack','error','like','filters','rawAttributes','attributes','query','order','Content-Range','then','params','undefined','SmsTransferReport','nolimit','map','api','length','model','offset','findOne','../../config/logger','body','fieldName','intersection','name','sort','../../components/parsers/qs','type','limit','key','keys','send','update','sequelize','catch','include','status','includeAll','options','count'];(function(_0x36d93e,_0x2c247a){const _0xc195d3=function(_0x302d0e){while(--_0x302d0e){_0x36d93e['push'](_0x36d93e['shift']());}};_0xc195d3(++_0x2c247a);}(a579_0x2c24,0x1f0));const a579_0xc195=function(_0x36d93e,_0x2c247a){_0x36d93e=_0x36d93e-0x0;let _0xc195d3=a579_0x2c24[_0x36d93e];return _0xc195d3;};const _0x316f4c=a579_0xc195;'use strict';const _=require(_0x316f4c('0x2e')),qs=require(_0x316f4c('0x14')),logger=require(_0x316f4c('0xe'))(_0x316f4c('0x9')),db=require(_0x316f4c('0x28'))['db'],{Op}=require(_0x316f4c('0x1b'));function respondWithResult(_0x302d0e,_0x462c3c){return _0x462c3c=_0x462c3c||0xc8,function(_0xb354ab){const _0x25c65e=a579_0xc195;if(_0xb354ab)return _0x302d0e[_0x25c65e('0x1e')](_0x462c3c)['json'](_0xb354ab);};}function respondWithFilteredResult(_0x9bedfa,_0x48d99e){return function(_0x19f758){const _0xd82759=a579_0xc195;if(_0x19f758){const _0x3c55e5=_0x19f758[_0xd82759('0x21')],_0x2a88d6=_0x48d99e[_0xd82759('0xc')];let _0x42d2d0=_0x48d99e[_0xd82759('0xc')]+_0x48d99e[_0xd82759('0x16')],_0x256e58;return _0x42d2d0>=_0x3c55e5?(_0x42d2d0=_0x3c55e5,_0x256e58=0xc8):_0x256e58=0xce,_0x9bedfa[_0xd82759('0x1e')](_0x256e58),_0x9bedfa['set'](_0xd82759('0x2'),_0x2a88d6+'-'+_0x42d2d0+'/'+_0x3c55e5)[_0xd82759('0x25')](_0x19f758);}return null;};}function saveUpdates(_0x30f925){return function(_0x491b87){const _0x1dbdff=a579_0xc195;if(_0x491b87)return _0x491b87[_0x1dbdff('0x1a')](_0x30f925)[_0x1dbdff('0x3')](function(_0x438008){return _0x438008;});return null;};}function removeEntity(_0x32d797){return function(_0x84e4b2){if(_0x84e4b2)return _0x84e4b2['destroy']()['then'](function(){const _0x286d1a=a579_0xc195;_0x32d797[_0x286d1a('0x1e')](0xcc)[_0x286d1a('0x2a')]();});};}function handleEntityNotFound(_0x2ae10b){return function(_0x8c4543){return!_0x8c4543&&_0x2ae10b['sendStatus'](0x194),_0x8c4543;};}function handleError(_0x2fb413,_0x532e0e){return _0x532e0e=_0x532e0e||0x1f4,function(_0x463d12){const _0xb081c9=a579_0xc195;logger[_0xb081c9('0x30')](_0x463d12[_0xb081c9('0x2f')]),_0x463d12[_0xb081c9('0x12')]&&delete _0x463d12[_0xb081c9('0x12')],_0x2fb413[_0xb081c9('0x1e')](_0x532e0e)[_0xb081c9('0x19')](_0x463d12);};}exports['index']=function(_0xf69901,_0x985bcd){const _0x55deac=_0x316f4c;let _0x49dfba={};const _0x3f04a6={},_0xa83f16={'count':0x0,'rows':[]},_0x3ed8ec=_[_0x55deac('0x8')](db[_0x55deac('0x6')][_0x55deac('0x33')],function(_0x388035){const _0x337b4a=_0x55deac;return{'name':_0x388035[_0x337b4a('0x10')],'type':_0x388035[_0x337b4a('0x15')][_0x337b4a('0x17')]};});_0x3f04a6[_0x55deac('0xb')]=_[_0x55deac('0x8')](_0x3ed8ec,_0x55deac('0x12')),_0x3f04a6[_0x55deac('0x0')]=_['keys'](_0xf69901[_0x55deac('0x0')]),_0x3f04a6['filters']=_[_0x55deac('0x11')](_0x3f04a6[_0x55deac('0xb')],_0x3f04a6[_0x55deac('0x0')]),_0x49dfba[_0x55deac('0x34')]=_['intersection'](_0x3f04a6['model'],qs[_0x55deac('0x29')](_0xf69901[_0x55deac('0x0')][_0x55deac('0x29')])),_0x49dfba['attributes']=_0x49dfba[_0x55deac('0x34')][_0x55deac('0xa')]?_0x49dfba['attributes']:_0x3f04a6[_0x55deac('0xb')];typeof _0xf69901[_0x55deac('0x0')][_0x55deac('0x7')]===_0x55deac('0x5')&&(_0x49dfba[_0x55deac('0x16')]=qs[_0x55deac('0x16')](_0xf69901[_0x55deac('0x0')]['limit']),_0x49dfba[_0x55deac('0xc')]=qs[_0x55deac('0xc')](_0xf69901[_0x55deac('0x0')][_0x55deac('0xc')]));_0x49dfba[_0x55deac('0x1')]=qs['sort'](_0xf69901['query'][_0x55deac('0x13')]),_0x49dfba[_0x55deac('0x23')]=qs[_0x55deac('0x32')](_['pick'](_0xf69901[_0x55deac('0x0')],_0x3f04a6[_0x55deac('0x32')]),_0x3ed8ec);_0xf69901['query']['filter']&&(_0x49dfba[_0x55deac('0x23')]=_[_0x55deac('0x27')](_0x49dfba[_0x55deac('0x23')],{[Op['or']]:_[_0x55deac('0x8')](_0x3ed8ec,function(_0x1575d9){const _0x3221ab=_0x55deac;if(_0x1575d9[_0x3221ab('0x15')]!=='VIRTUAL'){const _0x3ec091={};return _0x3ec091[_0x1575d9[_0x3221ab('0x12')]]={[Op[_0x3221ab('0x31')]]:'%'+_0xf69901[_0x3221ab('0x0')]['filter']+'%'},_0x3ec091;}})}));_0x49dfba=_[_0x55deac('0x27')]({},_0x49dfba,_0xf69901[_0x55deac('0x20')]);const _0x32322d={'where':_0x49dfba[_0x55deac('0x23')]};return db[_0x55deac('0x6')][_0x55deac('0x21')](_0x32322d)['then'](function(_0x99b51c){const _0x544faa=_0x55deac;return _0xa83f16[_0x544faa('0x21')]=_0x99b51c,_0xf69901[_0x544faa('0x0')][_0x544faa('0x1f')]&&(_0x49dfba[_0x544faa('0x1d')]=[{'all':!![]}]),db[_0x544faa('0x6')][_0x544faa('0x26')](_0x49dfba);})[_0x55deac('0x3')](function(_0x5e289d){const _0x255bfc=_0x55deac;return _0xa83f16[_0x255bfc('0x24')]=_0x5e289d,_0xa83f16;})[_0x55deac('0x3')](respondWithFilteredResult(_0x985bcd,_0x49dfba))['catch'](handleError(_0x985bcd,null));},exports[_0x316f4c('0x2d')]=function(_0x4e48d1,_0x4c1b09){const _0x144342=_0x316f4c;let _0x307fa8={'raw':!![],'where':{'id':_0x4e48d1['params']['id']}};const _0x268c63={};return _0x268c63[_0x144342('0xb')]=_[_0x144342('0x18')](db[_0x144342('0x6')][_0x144342('0x33')]),_0x268c63[_0x144342('0x0')]=_['keys'](_0x4e48d1['query']),_0x268c63['filters']=_[_0x144342('0x11')](_0x268c63[_0x144342('0xb')],_0x268c63[_0x144342('0x0')]),_0x307fa8[_0x144342('0x34')]=_['intersection'](_0x268c63[_0x144342('0xb')],qs['fields'](_0x4e48d1['query'][_0x144342('0x29')])),_0x307fa8[_0x144342('0x34')]=_0x307fa8[_0x144342('0x34')][_0x144342('0xa')]?_0x307fa8[_0x144342('0x34')]:_0x268c63[_0x144342('0xb')],_0x4e48d1[_0x144342('0x0')]['includeAll']&&(_0x307fa8[_0x144342('0x1d')]=[{'all':!![]}]),_0x307fa8=_[_0x144342('0x27')]({},_0x307fa8,_0x4e48d1[_0x144342('0x20')]),db[_0x144342('0x6')][_0x144342('0xd')](_0x307fa8)[_0x144342('0x3')](handleEntityNotFound(_0x4c1b09,null))['then'](respondWithResult(_0x4c1b09,null))[_0x144342('0x1c')](handleError(_0x4c1b09,null));},exports[_0x316f4c('0x2c')]=function(_0x477e51,_0x39805d){const _0x172a23=_0x316f4c;return db[_0x172a23('0x6')]['create'](_0x477e51[_0x172a23('0xf')],{})[_0x172a23('0x3')](respondWithResult(_0x39805d,0xc9))[_0x172a23('0x1c')](handleError(_0x39805d,null));},exports[_0x316f4c('0x1a')]=function(_0x26e450,_0x575f07){const _0x304d1b=_0x316f4c;return _0x26e450['body']['id']&&delete _0x26e450[_0x304d1b('0xf')]['id'],db[_0x304d1b('0x6')][_0x304d1b('0xd')]({'where':{'id':_0x26e450['params']['id']}})[_0x304d1b('0x3')](handleEntityNotFound(_0x575f07,null))['then'](saveUpdates(_0x26e450[_0x304d1b('0xf')],null))[_0x304d1b('0x3')](respondWithResult(_0x575f07,null))[_0x304d1b('0x1c')](handleError(_0x575f07,null));},exports[_0x316f4c('0x22')]=function(_0x1e7b69,_0x1c25e1){const _0x40a12a=_0x316f4c;return db[_0x40a12a('0x6')][_0x40a12a('0xd')]({'where':{'id':_0x1e7b69[_0x40a12a('0x4')]['id']}})[_0x40a12a('0x3')](handleEntityNotFound(_0x1c25e1,null))[_0x40a12a('0x3')](removeEntity(_0x1c25e1,null))[_0x40a12a('0x1c')](handleError(_0x1c25e1,null));},exports[_0x316f4c('0x2b')]=function(_0x1b96f0,_0x219ded){const _0x119d93=_0x316f4c;return db[_0x119d93('0x6')][_0x119d93('0x2b')]()[_0x119d93('0x3')](respondWithResult(_0x219ded,null))[_0x119d93('0x1c')](handleError(_0x219ded,null));}; \ No newline at end of file diff --git a/server/api/smsTransferReport/smsTransferReport.model.js b/server/api/smsTransferReport/smsTransferReport.model.js index c431195..9cd5123 100644 --- a/server/api/smsTransferReport/smsTransferReport.model.js +++ b/server/api/smsTransferReport/smsTransferReport.model.js @@ -1 +1 @@ -const a580_0x3849=['exports','SmsTransferReport','uniqueid'];(function(_0x293417,_0x384993){const _0x5544ca=function(_0x1d39b0){while(--_0x1d39b0){_0x293417['push'](_0x293417['shift']());}};_0x5544ca(++_0x384993);}(a580_0x3849,0xfe));const a580_0x5544=function(_0x293417,_0x384993){_0x293417=_0x293417-0x0;let _0x5544ca=a580_0x3849[_0x293417];return _0x5544ca;};const _0x4fe806=a580_0x5544;'use strict';const attributes=require('./smsTransferReport.attributes');module[_0x4fe806('0x1')]=function(_0x1d39b0){const _0x3840b8=_0x4fe806,_0x5a7b29=_0x1d39b0['define'](_0x3840b8('0x2'),attributes,{'tableName':'report_sms_transfer','paranoid':![],'indexes':[{'name':'uniqueid','fields':[_0x3840b8('0x0')]}],'timestamps':!![]});return _0x5a7b29;}; \ No newline at end of file +const a580_0x53ad=['report_sms_transfer','SmsTransferReport','uniqueid'];(function(_0x3b1f40,_0x53ad6b){const _0x45c727=function(_0x141423){while(--_0x141423){_0x3b1f40['push'](_0x3b1f40['shift']());}};_0x45c727(++_0x53ad6b);}(a580_0x53ad,0x116));const a580_0x45c7=function(_0x3b1f40,_0x53ad6b){_0x3b1f40=_0x3b1f40-0x0;let _0x45c727=a580_0x53ad[_0x3b1f40];return _0x45c727;};'use strict';const attributes=require('./smsTransferReport.attributes');module['exports']=function(_0x141423){const _0x2b2d63=a580_0x45c7,_0x869a63=_0x141423['define'](_0x2b2d63('0x2'),attributes,{'tableName':_0x2b2d63('0x1'),'paranoid':![],'indexes':[{'name':'uniqueid','fields':[_0x2b2d63('0x0')]}],'timestamps':!![]});return _0x869a63;}; \ No newline at end of file diff --git a/server/api/sound/index.js b/server/api/sound/index.js index dc60162..4b787d1 100644 --- a/server/api/sound/index.js +++ b/server/api/sound/index.js @@ -1 +1 @@ -const a581_0x4e0f=['replace','get','root','files/sounds/original/','update','file','util','index','delete','extname','Router','diskStorage','/:id/download','post','join','download','path','exports','basename','format','isAuthenticated','%s-%s%s','../../config/environment','/:id','originalname','single','now'];(function(_0x159ccd,_0x4e0f5f){const _0x279709=function(_0x29c3e0){while(--_0x29c3e0){_0x159ccd['push'](_0x159ccd['shift']());}};_0x279709(++_0x4e0f5f);}(a581_0x4e0f,0x155));const a581_0x2797=function(_0x159ccd,_0x4e0f5f){_0x159ccd=_0x159ccd-0x0;let _0x279709=a581_0x4e0f[_0x159ccd];return _0x279709;};const _0x5b1cda=a581_0x2797;'use strict';const multer=require('multer'),util=require(_0x5b1cda('0x10')),path=require(_0x5b1cda('0x1a')),express=require('express'),router=express[_0x5b1cda('0x14')](),auth=require('../../components/auth/service'),config=require(_0x5b1cda('0x5')),controller=require('./sound.controller');router[_0x5b1cda('0xb')]('/',auth[_0x5b1cda('0x3')](),controller[_0x5b1cda('0x11')]),router[_0x5b1cda('0xb')](_0x5b1cda('0x6'),auth[_0x5b1cda('0x3')](),controller['show']),router[_0x5b1cda('0xb')](_0x5b1cda('0x16'),auth[_0x5b1cda('0x3')](),controller[_0x5b1cda('0x19')]);const upload=multer({'storage':multer[_0x5b1cda('0x15')]({'destination':function(_0x29c3e0,_0x49d824,_0x27161a){const _0x2566e3=_0x5b1cda;_0x27161a(null,path[_0x2566e3('0x18')](config[_0x2566e3('0xc')],_0x2566e3('0xd')));},'filename':function(_0x14bee5,_0x586ca6,_0x1e0580){const _0x8f762=_0x5b1cda;_0x586ca6[_0x8f762('0x7')]=_0x586ca6['originalname'][_0x8f762('0xa')](/[+@&/\\#,+()$~%'":*?<>{}\s\\|]/g,'-'),_0x1e0580(null,util[_0x8f762('0x2')](_0x8f762('0x4'),path[_0x8f762('0x1')](_0x586ca6[_0x8f762('0x7')],path[_0x8f762('0x13')](_0x586ca6[_0x8f762('0x7')])),Date[_0x8f762('0x9')](),path[_0x8f762('0x13')](_0x586ca6[_0x8f762('0x7')])));}})});router[_0x5b1cda('0x17')]('/',upload[_0x5b1cda('0x8')](_0x5b1cda('0xf')),controller['create']),router['put']('/:id',auth[_0x5b1cda('0x3')](),controller[_0x5b1cda('0xe')]),router[_0x5b1cda('0x12')](_0x5b1cda('0x6'),auth[_0x5b1cda('0x3')](),controller[_0x5b1cda('0x12')]),module[_0x5b1cda('0x0')]=router; \ No newline at end of file +const a581_0x427c=['post','single','update','exports','isAuthenticated','create','%s-%s%s','multer','../../components/auth/service','get','root','delete','put','/:id/download','originalname','now','../../config/environment','/:id','basename','replace','show','diskStorage','files/sounds/original/','./sound.controller','extname','download','express'];(function(_0x3d560a,_0x427cba){const _0x49eee5=function(_0x1515f7){while(--_0x1515f7){_0x3d560a['push'](_0x3d560a['shift']());}};_0x49eee5(++_0x427cba);}(a581_0x427c,0xdf));const a581_0x49ee=function(_0x3d560a,_0x427cba){_0x3d560a=_0x3d560a-0x0;let _0x49eee5=a581_0x427c[_0x3d560a];return _0x49eee5;};const _0x5cdfa4=a581_0x49ee;'use strict';const multer=require(_0x5cdfa4('0x0')),util=require('util'),path=require('path'),express=require(_0x5cdfa4('0x13')),router=express['Router'](),auth=require(_0x5cdfa4('0x1')),config=require(_0x5cdfa4('0x9')),controller=require(_0x5cdfa4('0x10'));router['get']('/',auth[_0x5cdfa4('0x18')](),controller['index']),router[_0x5cdfa4('0x2')](_0x5cdfa4('0xa'),auth[_0x5cdfa4('0x18')](),controller[_0x5cdfa4('0xd')]),router[_0x5cdfa4('0x2')](_0x5cdfa4('0x6'),auth[_0x5cdfa4('0x18')](),controller[_0x5cdfa4('0x12')]);const upload=multer({'storage':multer[_0x5cdfa4('0xe')]({'destination':function(_0x1515f7,_0x27a898,_0x1d758b){const _0x3fc1cc=_0x5cdfa4;_0x1d758b(null,path['join'](config[_0x3fc1cc('0x3')],_0x3fc1cc('0xf')));},'filename':function(_0x524438,_0xb8f1cc,_0x40a8de){const _0x374bc7=_0x5cdfa4;_0xb8f1cc[_0x374bc7('0x7')]=_0xb8f1cc[_0x374bc7('0x7')][_0x374bc7('0xc')](/[+@&/\\#,+()$~%'":*?<>{}\s\\|]/g,'-'),_0x40a8de(null,util['format'](_0x374bc7('0x1a'),path[_0x374bc7('0xb')](_0xb8f1cc[_0x374bc7('0x7')],path[_0x374bc7('0x11')](_0xb8f1cc[_0x374bc7('0x7')])),Date[_0x374bc7('0x8')](),path[_0x374bc7('0x11')](_0xb8f1cc[_0x374bc7('0x7')])));}})});router[_0x5cdfa4('0x14')]('/',upload[_0x5cdfa4('0x15')]('file'),controller[_0x5cdfa4('0x19')]),router[_0x5cdfa4('0x5')](_0x5cdfa4('0xa'),auth[_0x5cdfa4('0x18')](),controller[_0x5cdfa4('0x16')]),router[_0x5cdfa4('0x4')](_0x5cdfa4('0xa'),auth[_0x5cdfa4('0x18')](),controller['delete']),module[_0x5cdfa4('0x17')]=router; \ No newline at end of file diff --git a/server/api/sound/sound.attributes.js b/server/api/sound/sound.attributes.js index baf566a..7acfebb 100644 --- a/server/api/sound/sound.attributes.js +++ b/server/api/sound/sound.attributes.js @@ -1 +1 @@ -const a582_0x4148=['INTEGER','sequelize','BIGINT','name','STRING','FLOAT'];(function(_0x1c64f9,_0x4148c5){const _0x3d9471=function(_0x2a7196){while(--_0x2a7196){_0x1c64f9['push'](_0x1c64f9['shift']());}};_0x3d9471(++_0x4148c5);}(a582_0x4148,0x13a));const a582_0x3d94=function(_0x1c64f9,_0x4148c5){_0x1c64f9=_0x1c64f9-0x0;let _0x3d9471=a582_0x4148[_0x1c64f9];return _0x3d9471;};const _0x29000c=a582_0x3d94;'use strict';const Sequelize=require(_0x29000c('0x5'));module['exports']={'name':{'type':Sequelize['STRING'],'unique':_0x29000c('0x1'),'allowNull':![]},'save_name':{'type':Sequelize[_0x29000c('0x2')]},'display_name':{'type':Sequelize[_0x29000c('0x2')],'defaultValue':''},'description':{'type':Sequelize[_0x29000c('0x2')]},'original_format':{'type':Sequelize[_0x29000c('0x2')]},'original_duration':{'type':Sequelize['FLOAT']},'original_sampleCount':{'type':Sequelize['BIGINT']},'original_channelCount':{'type':Sequelize[_0x29000c('0x4')]},'original_bitRate':{'type':Sequelize['BIGINT']},'original_sampleRate':{'type':Sequelize[_0x29000c('0x4')]},'converted_format':{'type':Sequelize['STRING']},'converted_duration':{'type':Sequelize[_0x29000c('0x3')]},'converted_sampleCount':{'type':Sequelize[_0x29000c('0x0')]},'converted_channelCount':{'type':Sequelize[_0x29000c('0x4')]},'converted_bitRate':{'type':Sequelize[_0x29000c('0x0')]},'converted_sampleRate':{'type':Sequelize[_0x29000c('0x4')]}}; \ No newline at end of file +const a582_0x316e=['exports','sequelize','INTEGER','FLOAT','BIGINT','STRING'];(function(_0x4771fd,_0x316e50){const _0x6d56eb=function(_0x288a0d){while(--_0x288a0d){_0x4771fd['push'](_0x4771fd['shift']());}};_0x6d56eb(++_0x316e50);}(a582_0x316e,0x128));const a582_0x6d56=function(_0x4771fd,_0x316e50){_0x4771fd=_0x4771fd-0x0;let _0x6d56eb=a582_0x316e[_0x4771fd];return _0x6d56eb;};const _0x5d60ed=a582_0x6d56;'use strict';const Sequelize=require(_0x5d60ed('0x5'));module[_0x5d60ed('0x4')]={'name':{'type':Sequelize[_0x5d60ed('0x3')],'unique':'name','allowNull':![]},'save_name':{'type':Sequelize['STRING']},'display_name':{'type':Sequelize[_0x5d60ed('0x3')],'defaultValue':''},'description':{'type':Sequelize[_0x5d60ed('0x3')]},'original_format':{'type':Sequelize[_0x5d60ed('0x3')]},'original_duration':{'type':Sequelize[_0x5d60ed('0x1')]},'original_sampleCount':{'type':Sequelize[_0x5d60ed('0x2')]},'original_channelCount':{'type':Sequelize[_0x5d60ed('0x0')]},'original_bitRate':{'type':Sequelize[_0x5d60ed('0x2')]},'original_sampleRate':{'type':Sequelize[_0x5d60ed('0x0')]},'converted_format':{'type':Sequelize[_0x5d60ed('0x3')]},'converted_duration':{'type':Sequelize[_0x5d60ed('0x1')]},'converted_sampleCount':{'type':Sequelize[_0x5d60ed('0x2')]},'converted_channelCount':{'type':Sequelize[_0x5d60ed('0x0')]},'converted_bitRate':{'type':Sequelize[_0x5d60ed('0x2')]},'converted_sampleRate':{'type':Sequelize[_0x5d60ed('0x0')]}}; \ No newline at end of file diff --git a/server/api/sound/sound.controller.js b/server/api/sound/sound.controller.js index 2ad3fa7..d5ebc22 100644 --- a/server/api/sound/sound.controller.js +++ b/server/api/sound/sound.controller.js @@ -1 +1 @@ -const a583_0x2ec5=['model','count','../../config/logger','original_format','name','user','bitRate','save_name','filters','merge','start','rows','lodash','order','send','update','keys','intersection','type','Sounds','src','filename','basename','where','Sound\x20upload\x20filepath:\x20%s','info','download','rawAttributes','path','fields','original_bitRate','converted_format','converted_bitRate','sampleRate','catch','../../config/environment','attributes','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','channelCount','findAll','offset','includeAll','length','include','converted_duration','chmodSync','original_channelCount','api','findOne','params','role','Content-Range','then','like','server/files/sounds/original','json','create','converted_channelCount','status','existsSync','Sound','pick','originalname','../../mysqldb','sox','show','get','format','wav','stack','unlinkSync','limit','original_sampleRate','map','join','file','substring','UserProfileResource','error','root','filter','sequelize','UserProfileSection','end','body','userProfileId','duration','0777','set','options','query','sampleCount','Unable\x20to\x20retrieve\x20the\x20current\x20user','server/files/sounds/converted','nolimit','extname','sendStatus','%s.%s','description'];(function(_0x527ff5,_0x2ec5b5){const _0x58bbfe=function(_0x55eca5){while(--_0x55eca5){_0x527ff5['push'](_0x527ff5['shift']());}};_0x58bbfe(++_0x2ec5b5);}(a583_0x2ec5,0x79));const a583_0x58bb=function(_0x527ff5,_0x2ec5b5){_0x527ff5=_0x527ff5-0x0;let _0x58bbfe=a583_0x2ec5[_0x527ff5];return _0x58bbfe;};const _0x193326=a583_0x58bb;'use strict';const util=require('util'),path=require(_0x193326('0x6')),sox=require(_0x193326('0x2a')),fs=require('fs'),_=require(_0x193326('0x59')),qs=require('../../components/parsers/qs'),logger=require(_0x193326('0x4f'))(_0x193326('0x19')),config=require(_0x193326('0xd')),db=require(_0x193326('0x29'))['db'],{Op,ValidationError}=require(_0x193326('0x3b'));function respondWithResult(_0x55eca5,_0x5a81f2){return _0x5a81f2=_0x5a81f2||0xc8,function(_0x2c032d){const _0x43fb5a=a583_0x58bb;if(_0x2c032d)return _0x55eca5['status'](_0x5a81f2)[_0x43fb5a('0x21')](_0x2c032d);};}function respondWithFilteredResult(_0x4d2c72,_0x2fc9c9){return function(_0x2b0d66){const _0x370e67=a583_0x58bb;if(_0x2b0d66){const _0x164cc1=_0x2b0d66[_0x370e67('0x4e')],_0x2703cd=_0x2fc9c9[_0x370e67('0x12')];let _0x45a3c5=_0x2fc9c9[_0x370e67('0x12')]+_0x2fc9c9[_0x370e67('0x31')],_0x3c55c4;return _0x45a3c5>=_0x164cc1?(_0x45a3c5=_0x164cc1,_0x3c55c4=0xc8):_0x3c55c4=0xce,_0x4d2c72[_0x370e67('0x24')](_0x3c55c4),_0x4d2c72[_0x370e67('0x42')](_0x370e67('0x1d'),_0x2703cd+'-'+_0x45a3c5+'/'+_0x164cc1)[_0x370e67('0x21')](_0x2b0d66);}return null;};}function saveUpdates(_0x2f3066){return function(_0x382762){const _0xfa8945=a583_0x58bb;if(_0x382762)return _0x382762[_0xfa8945('0x5c')](_0x2f3066)[_0xfa8945('0x1e')](function(_0x212c5c){return _0x212c5c;});return null;};}function handleEntityNotFound(_0x15646d){return function(_0x4bb1c8){const _0x3e22f3=a583_0x58bb;return!_0x4bb1c8&&_0x15646d[_0x3e22f3('0x4a')](0x194),_0x4bb1c8;};}function handleError(_0x1ec5c5,_0x379fa4){return _0x379fa4=_0x379fa4||0x1f4,function(_0x2af77b){const _0x3a08b2=a583_0x58bb;logger['error'](_0x2af77b[_0x3a08b2('0x2f')]),_0x2af77b[_0x3a08b2('0x51')]&&delete _0x2af77b[_0x3a08b2('0x51')],_0x1ec5c5[_0x3a08b2('0x24')](_0x379fa4)[_0x3a08b2('0x5b')](_0x2af77b);};}exports['index']=function(_0x3e1baf,_0x2c2e93){const _0xc057e5=_0x193326;let _0x365d0e={};const _0x2bb4b6={},_0x45bd15={'count':0x0,'rows':[]},_0x5d9670=_[_0xc057e5('0x33')](db[_0xc057e5('0x26')][_0xc057e5('0x5')],function(_0x2ff899){const _0x460820=_0xc057e5;return{'name':_0x2ff899['fieldName'],'type':_0x2ff899[_0x460820('0x5f')]['key']};});_0x2bb4b6[_0xc057e5('0x4d')]=_[_0xc057e5('0x33')](_0x5d9670,_0xc057e5('0x51')),_0x2bb4b6[_0xc057e5('0x44')]=_[_0xc057e5('0x5d')](_0x3e1baf[_0xc057e5('0x44')]),_0x2bb4b6['filters']=_[_0xc057e5('0x5e')](_0x2bb4b6['model'],_0x2bb4b6[_0xc057e5('0x44')]),_0x365d0e['attributes']=_[_0xc057e5('0x5e')](_0x2bb4b6[_0xc057e5('0x4d')],qs[_0xc057e5('0x7')](_0x3e1baf[_0xc057e5('0x44')][_0xc057e5('0x7')])),_0x365d0e[_0xc057e5('0xe')]=_0x365d0e[_0xc057e5('0xe')]['length']?_0x365d0e[_0xc057e5('0xe')]:_0x2bb4b6[_0xc057e5('0x4d')];typeof _0x3e1baf[_0xc057e5('0x44')][_0xc057e5('0x48')]==='undefined'&&(_0x365d0e[_0xc057e5('0x31')]=qs[_0xc057e5('0x31')](_0x3e1baf[_0xc057e5('0x44')]['limit']),_0x365d0e['offset']=qs[_0xc057e5('0x12')](_0x3e1baf[_0xc057e5('0x44')]['offset']));_0x365d0e[_0xc057e5('0x5a')]=qs['sort'](_0x3e1baf[_0xc057e5('0x44')]['sort']),_0x365d0e[_0xc057e5('0x1')]=qs[_0xc057e5('0x55')](_[_0xc057e5('0x27')](_0x3e1baf['query'],_0x2bb4b6['filters']),_0x5d9670);_0x3e1baf[_0xc057e5('0x44')][_0xc057e5('0x3a')]&&(_0x365d0e[_0xc057e5('0x1')]=_['merge'](_0x365d0e[_0xc057e5('0x1')],{[Op['or']]:_[_0xc057e5('0x33')](_0x5d9670,function(_0x148837){const _0xc7123b=_0xc057e5;if(_0x148837[_0xc7123b('0x5f')]!=='VIRTUAL'){const _0x875ca9={};return _0x875ca9[_0x148837[_0xc7123b('0x51')]]={[Op[_0xc7123b('0x1f')]]:'%'+_0x3e1baf[_0xc7123b('0x44')]['filter']+'%'},_0x875ca9;}})}));_0x365d0e=_[_0xc057e5('0x56')]({},_0x365d0e,_0x3e1baf[_0xc057e5('0x43')]);const _0x16d600={'where':_0x365d0e[_0xc057e5('0x1')]};return db[_0xc057e5('0x26')][_0xc057e5('0x4e')](_0x16d600)[_0xc057e5('0x1e')](function(_0x1a63fd){const _0x1ae35c=_0xc057e5;return _0x45bd15[_0x1ae35c('0x4e')]=_0x1a63fd,_0x3e1baf['query'][_0x1ae35c('0x13')]&&(_0x365d0e['include']=[{'all':!![]}]),db[_0x1ae35c('0x26')][_0x1ae35c('0x11')](_0x365d0e);})['then'](function(_0x42767e){const _0x2aec87=_0xc057e5;return _0x45bd15[_0x2aec87('0x58')]=_0x42767e,_0x45bd15;})[_0xc057e5('0x1e')](respondWithFilteredResult(_0x2c2e93,_0x365d0e))[_0xc057e5('0xc')](handleError(_0x2c2e93,null));},exports[_0x193326('0x2b')]=function(_0x5cc0d9,_0x52065f){const _0x41b4f4=_0x193326;let _0x45db56={'raw':!![],'where':{'id':_0x5cc0d9[_0x41b4f4('0x1b')]['id']}};const _0x2a9813={};return _0x2a9813['model']=_[_0x41b4f4('0x5d')](db[_0x41b4f4('0x26')][_0x41b4f4('0x5')]),_0x2a9813['query']=_[_0x41b4f4('0x5d')](_0x5cc0d9['query']),_0x2a9813[_0x41b4f4('0x55')]=_[_0x41b4f4('0x5e')](_0x2a9813[_0x41b4f4('0x4d')],_0x2a9813['query']),_0x45db56['attributes']=_[_0x41b4f4('0x5e')](_0x2a9813[_0x41b4f4('0x4d')],qs[_0x41b4f4('0x7')](_0x5cc0d9[_0x41b4f4('0x44')][_0x41b4f4('0x7')])),_0x45db56[_0x41b4f4('0xe')]=_0x45db56['attributes'][_0x41b4f4('0x14')]?_0x45db56['attributes']:_0x2a9813[_0x41b4f4('0x4d')],_0x5cc0d9[_0x41b4f4('0x44')][_0x41b4f4('0x13')]&&(_0x45db56[_0x41b4f4('0x15')]=[{'all':!![]}]),_0x45db56=_[_0x41b4f4('0x56')]({},_0x45db56,_0x5cc0d9[_0x41b4f4('0x43')]),db[_0x41b4f4('0x26')][_0x41b4f4('0x1a')](_0x45db56)[_0x41b4f4('0x1e')](handleEntityNotFound(_0x52065f,null))[_0x41b4f4('0x1e')](respondWithResult(_0x52065f,null))[_0x41b4f4('0xc')](handleError(_0x52065f,null));},exports[_0x193326('0x4')]=function(_0x3df113,_0x533325){const _0x4989d5=_0x193326;return db[_0x4989d5('0x26')][_0x4989d5('0x1a')]({'where':{'id':_0x3df113[_0x4989d5('0x1b')]['id']},'attributes':[_0x4989d5('0x51'),'save_name',_0x4989d5('0x9')],'raw':!![]})['then'](handleEntityNotFound(_0x533325,null))[_0x4989d5('0x1e')](function(_0x13ca4f){const _0x115b9d=_0x4989d5;if(_0x13ca4f){if(!fs[_0x115b9d('0x25')](path[_0x115b9d('0x34')](config[_0x115b9d('0x39')],_0x115b9d('0x47'),_0x13ca4f['save_name']+'.'+_0x13ca4f['converted_format'])))throw new ValidationError('Sound\x20not\x20found');return _0x533325['download'](path[_0x115b9d('0x34')](config[_0x115b9d('0x39')],_0x115b9d('0x47'),util[_0x115b9d('0x2d')]('%s.%s',_0x13ca4f[_0x115b9d('0x54')],_0x13ca4f[_0x115b9d('0x9')])),util[_0x115b9d('0x2d')](_0x115b9d('0x4b'),_0x13ca4f[_0x115b9d('0x51')],_0x13ca4f[_0x115b9d('0x9')]));}return null;})[_0x4989d5('0xc')](handleError(_0x533325,null));},exports['create']=function(_0x1361d4,_0x410d9a){const _0x1e8bc3=_0x193326,_0x3cb89a={'name':path[_0x1e8bc3('0x0')](_0x1361d4[_0x1e8bc3('0x35')][_0x1e8bc3('0x28')],path['extname'](_0x1361d4[_0x1e8bc3('0x35')][_0x1e8bc3('0x28')])),'save_name':path[_0x1e8bc3('0x0')](_0x1361d4[_0x1e8bc3('0x35')][_0x1e8bc3('0x62')],path[_0x1e8bc3('0x49')](_0x1361d4['file'][_0x1e8bc3('0x62')])),'original_format':path['extname'](_0x1361d4[_0x1e8bc3('0x35')][_0x1e8bc3('0x28')])[_0x1e8bc3('0x36')](0x1),'converted_format':_0x1e8bc3('0x2e')},_0x58881c=path['join'](config['root'],_0x1e8bc3('0x20'),_0x1361d4[_0x1e8bc3('0x35')][_0x1e8bc3('0x62')]),_0x1b49be=path[_0x1e8bc3('0x34')](config[_0x1e8bc3('0x39')],'server/files/sounds/converted',util['format'](_0x1e8bc3('0x4b'),path[_0x1e8bc3('0x0')](_0x1361d4[_0x1e8bc3('0x35')][_0x1e8bc3('0x62')],path[_0x1e8bc3('0x49')](_0x1361d4['file'][_0x1e8bc3('0x62')])),_0x3cb89a[_0x1e8bc3('0x9')]));logger[_0x1e8bc3('0x3')](_0x1e8bc3('0x2'),_0x58881c),logger[_0x1e8bc3('0x3')]('Sound\x20upload\x20destination:\x20%s',_0x1b49be);try{fs[_0x1e8bc3('0x17')](_0x58881c,parseInt('0777',0x8));const _0x3e0339=sox['transcode'](_0x58881c,_0x1b49be,{'sampleRate':0x1f40,'format':_0x1e8bc3('0x2e'),'channelCount':0x1,'bitRate':0xc0*0x400,'compressionQuality':0x5});_0x3e0339['on'](_0x1e8bc3('0x38'),function(_0x2c80aa){const _0x28ed54=_0x1e8bc3;fs[_0x28ed54('0x30')](_0x58881c),_0x410d9a[_0x28ed54('0x24')](0x1f4)[_0x28ed54('0x5b')](_0x2c80aa);}),_0x3e0339['on'](_0x1e8bc3('0x61'),function(_0x547967){const _0x53ae7=_0x1e8bc3;_0x3cb89a['original_duration']=isNaN(_0x547967[_0x53ae7('0x40')])?null:_0x547967[_0x53ae7('0x40')]*0x3e8,_0x3cb89a['original_sampleCount']=isNaN(_0x547967[_0x53ae7('0x45')])?null:_0x547967['sampleCount'],_0x3cb89a[_0x53ae7('0x18')]=isNaN(_0x547967[_0x53ae7('0x10')])?null:_0x547967[_0x53ae7('0x10')],_0x3cb89a[_0x53ae7('0x8')]=isNaN(_0x547967[_0x53ae7('0x53')])?null:_0x547967['bitRate'],_0x3cb89a[_0x53ae7('0x32')]=isNaN(_0x547967[_0x53ae7('0xb')])?null:_0x547967[_0x53ae7('0xb')];}),_0x3e0339['on']('dest',function(_0x34c6c2){const _0x562019=_0x1e8bc3;_0x3cb89a[_0x562019('0x16')]=isNaN(_0x34c6c2['duration'])?null:_0x34c6c2[_0x562019('0x40')]*0x3e8,_0x3cb89a['converted_sampleCount']=isNaN(_0x34c6c2['sampleCount'])?null:_0x34c6c2[_0x562019('0x45')],_0x3cb89a[_0x562019('0x23')]=isNaN(_0x34c6c2[_0x562019('0x10')])?null:_0x34c6c2[_0x562019('0x10')],_0x3cb89a[_0x562019('0xa')]=isNaN(_0x34c6c2[_0x562019('0x53')])?null:_0x34c6c2['bitRate'],_0x3cb89a['converted_sampleRate']=isNaN(_0x34c6c2[_0x562019('0xb')])?null:_0x34c6c2[_0x562019('0xb')];}),_0x3e0339['on'](_0x1e8bc3('0x3d'),function(){const _0x2b4585=_0x1e8bc3;return fs[_0x2b4585('0x17')](_0x1b49be,parseInt(_0x2b4585('0x41'),0x8)),db['Sound']['create'](_0x3cb89a)[_0x2b4585('0x1e')](function(_0x21c50a){const _0x190e72=_0x2b4585,_0x274f86={'role':_0x1361d4[_0x190e72('0x3e')][_0x190e72('0x1c')],'userProfileId':_0x1361d4[_0x190e72('0x3e')]['userProfileId']};if(!_0x274f86)throw new Error(_0x190e72('0x46'));if(_0x274f86[_0x190e72('0x1c')]===_0x190e72('0x52')){const _0x333b07=_0x21c50a[_0x190e72('0x2c')]({'plain':!![]});return db[_0x190e72('0x3c')][_0x190e72('0x1a')]({'where':{'name':_0x190e72('0x60'),'userProfileId':_0x274f86[_0x190e72('0x3f')]},'raw':!![]})['then'](function(_0x3d0d15){const _0x46b7fe=_0x190e72;return _0x3d0d15&&_0x3d0d15['autoAssociation']===0x0?db[_0x46b7fe('0x37')][_0x46b7fe('0x22')]({'name':_0x333b07[_0x46b7fe('0x51')],'resourceId':_0x333b07['id'],'type':_0x3d0d15[_0x46b7fe('0x51')],'sectionId':_0x3d0d15['id']},{})[_0x46b7fe('0x1e')](function(){return _0x21c50a;}):_0x21c50a;})[_0x190e72('0xc')](function(_0xfede46){const _0x654f30=_0x190e72;logger[_0x654f30('0x38')](_0x654f30('0xf'),_0xfede46);throw _0xfede46;});}return _0x21c50a;})[_0x2b4585('0x1e')](respondWithResult(_0x410d9a,null))[_0x2b4585('0xc')](handleError(_0x410d9a,null));}),_0x3e0339[_0x1e8bc3('0x57')]();}catch(_0x306451){_0x410d9a[_0x1e8bc3('0x24')](0x1f4)[_0x1e8bc3('0x5b')](_0x306451);}},exports['update']=function(_0x46ae13,_0x36a457){const _0x206955=_0x193326;return db[_0x206955('0x26')]['findOne']({'where':{'id':_0x46ae13[_0x206955('0x1b')]['id']}})[_0x206955('0x1e')](handleEntityNotFound(_0x36a457,null))[_0x206955('0x1e')](saveUpdates(_[_0x206955('0x27')](_0x46ae13[_0x206955('0x3e')],[_0x206955('0x51'),_0x206955('0x4c')]),null))[_0x206955('0x1e')](respondWithResult(_0x36a457,null))[_0x206955('0xc')](handleError(_0x36a457,null));},exports['delete']=function(_0x12c134,_0x3c0f44){const _0x52d612=_0x193326;return db[_0x52d612('0x26')][_0x52d612('0x1a')]({'where':{'id':_0x12c134[_0x52d612('0x1b')]['id']}})[_0x52d612('0x1e')](function(_0x327b49){if(_0x327b49)return _0x327b49['destroy']();})[_0x52d612('0x1e')](function(_0x40ecf1){const _0x401b8a=_0x52d612,_0xc92d40=path[_0x401b8a('0x34')](config[_0x401b8a('0x39')],_0x401b8a('0x20'),util[_0x401b8a('0x2d')](_0x401b8a('0x4b'),_0x40ecf1[_0x401b8a('0x54')],_0x40ecf1[_0x401b8a('0x50')])),_0x47691b=path['join'](config[_0x401b8a('0x39')],_0x401b8a('0x47'),util[_0x401b8a('0x2d')](_0x401b8a('0x4b'),_0x40ecf1[_0x401b8a('0x54')],_0x40ecf1[_0x401b8a('0x9')]));return fs[_0x401b8a('0x30')](_0xc92d40),fs[_0x401b8a('0x30')](_0x47691b),_0x40ecf1;})[_0x52d612('0x1e')](function(_0x3000fe){const _0x1a1379=_0x52d612;if(_0x3000fe)return _0x3c0f44[_0x1a1379('0x24')](0xcc)['end']();})[_0x52d612('0x1e')](handleEntityNotFound(_0x3c0f44,null))[_0x52d612('0xc')](handleError(_0x3c0f44,null));}; \ No newline at end of file +const a583_0x4d77=['Sound\x20upload\x20destination:\x20%s','set','api','description','save_name','filter','sort','rows','index','attributes','stack','map','%s.%s','error','original_sampleRate','name','existsSync','UserProfileSection','offset','options','channelCount','bitRate','status','VIRTUAL','merge','undefined','length','keys','json','destroy','wav','catch','root','info','converted_format','0777','chmodSync','nolimit','where','then','start','server/files/sounds/original','original_duration','includeAll','userProfileId','extname','UserProfileResource','Unable\x20to\x20retrieve\x20the\x20current\x20user','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','original_sampleCount','converted_sampleRate','unlinkSync','transcode','filename','server/files/sounds/converted','key','pick','../../mysqldb','send','Sounds','fieldName','count','Sound','fields','basename','create','findOne','params','download','join','limit','Content-Range','duration','show','converted_bitRate','body','delete','get','end','../../components/parsers/qs','originalname','rawAttributes','include','converted_duration','update','file','format','filters','model','path','original_bitRate','type','query','intersection','lodash','sampleRate','sox','sampleCount','role'];(function(_0x448883,_0x4d778d){const _0x1f2586=function(_0x58ea95){while(--_0x58ea95){_0x448883['push'](_0x448883['shift']());}};_0x1f2586(++_0x4d778d);}(a583_0x4d77,0x13c));const a583_0x1f25=function(_0x448883,_0x4d778d){_0x448883=_0x448883-0x0;let _0x1f2586=a583_0x4d77[_0x448883];return _0x1f2586;};const _0x3dcc9b=a583_0x1f25;'use strict';const util=require('util'),path=require(_0x3dcc9b('0x46')),sox=require(_0x3dcc9b('0x4d')),fs=require('fs'),_=require(_0x3dcc9b('0x4b')),qs=require(_0x3dcc9b('0x3c')),logger=require('../../config/logger')(_0x3dcc9b('0x52')),config=require('../../config/environment'),db=require(_0x3dcc9b('0x26'))['db'],{Op,ValidationError}=require('sequelize');function respondWithResult(_0x58ea95,_0x4c101b){return _0x4c101b=_0x4c101b||0xc8,function(_0x40abeb){if(_0x40abeb)return _0x58ea95['status'](_0x4c101b)['json'](_0x40abeb);};}function respondWithFilteredResult(_0x457f9c,_0x597a58){return function(_0x3fbe5c){const _0x336b66=a583_0x1f25;if(_0x3fbe5c){const _0xa6caf7=_0x3fbe5c[_0x336b66('0x2a')],_0x23071c=_0x597a58['offset'];let _0x453ddb=_0x597a58['offset']+_0x597a58[_0x336b66('0x33')],_0x3313c2;return _0x453ddb>=_0xa6caf7?(_0x453ddb=_0xa6caf7,_0x3313c2=0xc8):_0x3313c2=0xce,_0x457f9c[_0x336b66('0x3')](_0x3313c2),_0x457f9c[_0x336b66('0x51')](_0x336b66('0x34'),_0x23071c+'-'+_0x453ddb+'/'+_0xa6caf7)[_0x336b66('0x9')](_0x3fbe5c);}return null;};}function saveUpdates(_0x5b5555){return function(_0x43a628){const _0x503d99=a583_0x1f25;if(_0x43a628)return _0x43a628[_0x503d99('0x41')](_0x5b5555)[_0x503d99('0x14')](function(_0x38768e){return _0x38768e;});return null;};}function handleEntityNotFound(_0x1b7bfc){return function(_0x2404a5){return!_0x2404a5&&_0x1b7bfc['sendStatus'](0x194),_0x2404a5;};}function handleError(_0x1d7e69,_0x1eea95){return _0x1eea95=_0x1eea95||0x1f4,function(_0x3cb90a){const _0x49f93d=a583_0x1f25;logger[_0x49f93d('0x5d')](_0x3cb90a[_0x49f93d('0x5a')]),_0x3cb90a[_0x49f93d('0x5f')]&&delete _0x3cb90a[_0x49f93d('0x5f')],_0x1d7e69[_0x49f93d('0x3')](_0x1eea95)[_0x49f93d('0x27')](_0x3cb90a);};}exports[_0x3dcc9b('0x58')]=function(_0x50a4e3,_0x1580fb){const _0x3ffa27=_0x3dcc9b;let _0x5ef6ab={};const _0x5a8074={},_0xa87cf={'count':0x0,'rows':[]},_0x44fd09=_[_0x3ffa27('0x5b')](db['Sound'][_0x3ffa27('0x3e')],function(_0x4bcde6){const _0x14f5dc=_0x3ffa27;return{'name':_0x4bcde6[_0x14f5dc('0x29')],'type':_0x4bcde6['type'][_0x14f5dc('0x24')]};});_0x5a8074[_0x3ffa27('0x45')]=_[_0x3ffa27('0x5b')](_0x44fd09,_0x3ffa27('0x5f')),_0x5a8074['query']=_[_0x3ffa27('0x8')](_0x50a4e3[_0x3ffa27('0x49')]),_0x5a8074[_0x3ffa27('0x44')]=_[_0x3ffa27('0x4a')](_0x5a8074[_0x3ffa27('0x45')],_0x5a8074[_0x3ffa27('0x49')]),_0x5ef6ab[_0x3ffa27('0x59')]=_[_0x3ffa27('0x4a')](_0x5a8074[_0x3ffa27('0x45')],qs[_0x3ffa27('0x2c')](_0x50a4e3[_0x3ffa27('0x49')][_0x3ffa27('0x2c')])),_0x5ef6ab['attributes']=_0x5ef6ab[_0x3ffa27('0x59')][_0x3ffa27('0x7')]?_0x5ef6ab[_0x3ffa27('0x59')]:_0x5a8074[_0x3ffa27('0x45')];typeof _0x50a4e3[_0x3ffa27('0x49')][_0x3ffa27('0x12')]===_0x3ffa27('0x6')&&(_0x5ef6ab[_0x3ffa27('0x33')]=qs[_0x3ffa27('0x33')](_0x50a4e3[_0x3ffa27('0x49')][_0x3ffa27('0x33')]),_0x5ef6ab[_0x3ffa27('0x62')]=qs['offset'](_0x50a4e3[_0x3ffa27('0x49')][_0x3ffa27('0x62')]));_0x5ef6ab['order']=qs[_0x3ffa27('0x56')](_0x50a4e3['query'][_0x3ffa27('0x56')]),_0x5ef6ab['where']=qs[_0x3ffa27('0x44')](_[_0x3ffa27('0x25')](_0x50a4e3[_0x3ffa27('0x49')],_0x5a8074['filters']),_0x44fd09);_0x50a4e3[_0x3ffa27('0x49')][_0x3ffa27('0x55')]&&(_0x5ef6ab[_0x3ffa27('0x13')]=_[_0x3ffa27('0x5')](_0x5ef6ab[_0x3ffa27('0x13')],{[Op['or']]:_['map'](_0x44fd09,function(_0x59a7cc){const _0x38f8e5=_0x3ffa27;if(_0x59a7cc[_0x38f8e5('0x48')]!==_0x38f8e5('0x4')){const _0x331b8d={};return _0x331b8d[_0x59a7cc[_0x38f8e5('0x5f')]]={[Op['like']]:'%'+_0x50a4e3['query'][_0x38f8e5('0x55')]+'%'},_0x331b8d;}})}));_0x5ef6ab=_[_0x3ffa27('0x5')]({},_0x5ef6ab,_0x50a4e3[_0x3ffa27('0x0')]);const _0x43a275={'where':_0x5ef6ab['where']};return db['Sound'][_0x3ffa27('0x2a')](_0x43a275)[_0x3ffa27('0x14')](function(_0x24a6c5){const _0x2ed983=_0x3ffa27;return _0xa87cf[_0x2ed983('0x2a')]=_0x24a6c5,_0x50a4e3['query'][_0x2ed983('0x18')]&&(_0x5ef6ab[_0x2ed983('0x3f')]=[{'all':!![]}]),db[_0x2ed983('0x2b')]['findAll'](_0x5ef6ab);})['then'](function(_0x5a34cc){const _0x2864c9=_0x3ffa27;return _0xa87cf[_0x2864c9('0x57')]=_0x5a34cc,_0xa87cf;})[_0x3ffa27('0x14')](respondWithFilteredResult(_0x1580fb,_0x5ef6ab))[_0x3ffa27('0xc')](handleError(_0x1580fb,null));},exports[_0x3dcc9b('0x36')]=function(_0x1ab1f4,_0x54324a){const _0x3c29b8=_0x3dcc9b;let _0x2d12fb={'raw':!![],'where':{'id':_0x1ab1f4[_0x3c29b8('0x30')]['id']}};const _0x51aa0f={};return _0x51aa0f['model']=_[_0x3c29b8('0x8')](db[_0x3c29b8('0x2b')][_0x3c29b8('0x3e')]),_0x51aa0f[_0x3c29b8('0x49')]=_['keys'](_0x1ab1f4['query']),_0x51aa0f[_0x3c29b8('0x44')]=_[_0x3c29b8('0x4a')](_0x51aa0f[_0x3c29b8('0x45')],_0x51aa0f[_0x3c29b8('0x49')]),_0x2d12fb[_0x3c29b8('0x59')]=_[_0x3c29b8('0x4a')](_0x51aa0f[_0x3c29b8('0x45')],qs[_0x3c29b8('0x2c')](_0x1ab1f4[_0x3c29b8('0x49')][_0x3c29b8('0x2c')])),_0x2d12fb[_0x3c29b8('0x59')]=_0x2d12fb[_0x3c29b8('0x59')]['length']?_0x2d12fb['attributes']:_0x51aa0f[_0x3c29b8('0x45')],_0x1ab1f4[_0x3c29b8('0x49')][_0x3c29b8('0x18')]&&(_0x2d12fb[_0x3c29b8('0x3f')]=[{'all':!![]}]),_0x2d12fb=_[_0x3c29b8('0x5')]({},_0x2d12fb,_0x1ab1f4[_0x3c29b8('0x0')]),db[_0x3c29b8('0x2b')][_0x3c29b8('0x2f')](_0x2d12fb)[_0x3c29b8('0x14')](handleEntityNotFound(_0x54324a,null))[_0x3c29b8('0x14')](respondWithResult(_0x54324a,null))[_0x3c29b8('0xc')](handleError(_0x54324a,null));},exports[_0x3dcc9b('0x31')]=function(_0x320de9,_0x1e49a4){const _0x17ddd0=_0x3dcc9b;return db[_0x17ddd0('0x2b')][_0x17ddd0('0x2f')]({'where':{'id':_0x320de9['params']['id']},'attributes':[_0x17ddd0('0x5f'),_0x17ddd0('0x54'),'converted_format'],'raw':!![]})[_0x17ddd0('0x14')](handleEntityNotFound(_0x1e49a4,null))[_0x17ddd0('0x14')](function(_0x5cca1e){const _0x375deb=_0x17ddd0;if(_0x5cca1e){if(!fs[_0x375deb('0x60')](path[_0x375deb('0x32')](config[_0x375deb('0xd')],_0x375deb('0x23'),_0x5cca1e['save_name']+'.'+_0x5cca1e['converted_format'])))throw new ValidationError('Sound\x20not\x20found');return _0x1e49a4[_0x375deb('0x31')](path[_0x375deb('0x32')](config[_0x375deb('0xd')],_0x375deb('0x23'),util[_0x375deb('0x43')]('%s.%s',_0x5cca1e[_0x375deb('0x54')],_0x5cca1e[_0x375deb('0xf')])),util[_0x375deb('0x43')](_0x375deb('0x5c'),_0x5cca1e[_0x375deb('0x5f')],_0x5cca1e['converted_format']));}return null;})[_0x17ddd0('0xc')](handleError(_0x1e49a4,null));},exports[_0x3dcc9b('0x2e')]=function(_0x116ddd,_0xab0857){const _0x4ca301=_0x3dcc9b,_0x5cdcea={'name':path[_0x4ca301('0x2d')](_0x116ddd['file']['originalname'],path[_0x4ca301('0x1a')](_0x116ddd[_0x4ca301('0x42')][_0x4ca301('0x3d')])),'save_name':path['basename'](_0x116ddd['file'][_0x4ca301('0x22')],path[_0x4ca301('0x1a')](_0x116ddd[_0x4ca301('0x42')][_0x4ca301('0x22')])),'original_format':path['extname'](_0x116ddd['file'][_0x4ca301('0x3d')])['substring'](0x1),'converted_format':'wav'},_0x4897ae=path[_0x4ca301('0x32')](config[_0x4ca301('0xd')],'server/files/sounds/original',_0x116ddd[_0x4ca301('0x42')]['filename']),_0x1c84ed=path['join'](config['root'],_0x4ca301('0x23'),util[_0x4ca301('0x43')](_0x4ca301('0x5c'),path[_0x4ca301('0x2d')](_0x116ddd['file'][_0x4ca301('0x22')],path[_0x4ca301('0x1a')](_0x116ddd['file'][_0x4ca301('0x22')])),_0x5cdcea[_0x4ca301('0xf')]));logger[_0x4ca301('0xe')]('Sound\x20upload\x20filepath:\x20%s',_0x4897ae),logger['info'](_0x4ca301('0x50'),_0x1c84ed);try{fs[_0x4ca301('0x11')](_0x4897ae,parseInt(_0x4ca301('0x10'),0x8));const _0x53104b=sox[_0x4ca301('0x21')](_0x4897ae,_0x1c84ed,{'sampleRate':0x1f40,'format':_0x4ca301('0xb'),'channelCount':0x1,'bitRate':0xc0*0x400,'compressionQuality':0x5});_0x53104b['on'](_0x4ca301('0x5d'),function(_0x319273){const _0x15a572=_0x4ca301;fs[_0x15a572('0x20')](_0x4897ae),_0xab0857[_0x15a572('0x3')](0x1f4)[_0x15a572('0x27')](_0x319273);}),_0x53104b['on']('src',function(_0x652740){const _0x4a92c9=_0x4ca301;_0x5cdcea[_0x4a92c9('0x17')]=isNaN(_0x652740[_0x4a92c9('0x35')])?null:_0x652740['duration']*0x3e8,_0x5cdcea[_0x4a92c9('0x1e')]=isNaN(_0x652740[_0x4a92c9('0x4e')])?null:_0x652740['sampleCount'],_0x5cdcea['original_channelCount']=isNaN(_0x652740[_0x4a92c9('0x1')])?null:_0x652740[_0x4a92c9('0x1')],_0x5cdcea[_0x4a92c9('0x47')]=isNaN(_0x652740[_0x4a92c9('0x2')])?null:_0x652740[_0x4a92c9('0x2')],_0x5cdcea[_0x4a92c9('0x5e')]=isNaN(_0x652740[_0x4a92c9('0x4c')])?null:_0x652740[_0x4a92c9('0x4c')];}),_0x53104b['on']('dest',function(_0x12a093){const _0x473ee2=_0x4ca301;_0x5cdcea[_0x473ee2('0x40')]=isNaN(_0x12a093[_0x473ee2('0x35')])?null:_0x12a093[_0x473ee2('0x35')]*0x3e8,_0x5cdcea['converted_sampleCount']=isNaN(_0x12a093[_0x473ee2('0x4e')])?null:_0x12a093[_0x473ee2('0x4e')],_0x5cdcea['converted_channelCount']=isNaN(_0x12a093[_0x473ee2('0x1')])?null:_0x12a093['channelCount'],_0x5cdcea[_0x473ee2('0x37')]=isNaN(_0x12a093[_0x473ee2('0x2')])?null:_0x12a093[_0x473ee2('0x2')],_0x5cdcea[_0x473ee2('0x1f')]=isNaN(_0x12a093[_0x473ee2('0x4c')])?null:_0x12a093[_0x473ee2('0x4c')];}),_0x53104b['on'](_0x4ca301('0x3b'),function(){const _0x57fbf1=_0x4ca301;return fs[_0x57fbf1('0x11')](_0x1c84ed,parseInt(_0x57fbf1('0x10'),0x8)),db[_0x57fbf1('0x2b')]['create'](_0x5cdcea)['then'](function(_0x4616ba){const _0x398994=_0x57fbf1,_0x20f343={'role':_0x116ddd[_0x398994('0x38')]['role'],'userProfileId':_0x116ddd[_0x398994('0x38')][_0x398994('0x19')]};if(!_0x20f343)throw new Error(_0x398994('0x1c'));if(_0x20f343[_0x398994('0x4f')]==='user'){const _0x44cee3=_0x4616ba[_0x398994('0x3a')]({'plain':!![]});return db[_0x398994('0x61')]['findOne']({'where':{'name':_0x398994('0x28'),'userProfileId':_0x20f343[_0x398994('0x19')]},'raw':!![]})[_0x398994('0x14')](function(_0x2b7e8b){const _0x10cfcb=_0x398994;return _0x2b7e8b&&_0x2b7e8b['autoAssociation']===0x0?db[_0x10cfcb('0x1b')]['create']({'name':_0x44cee3[_0x10cfcb('0x5f')],'resourceId':_0x44cee3['id'],'type':_0x2b7e8b[_0x10cfcb('0x5f')],'sectionId':_0x2b7e8b['id']},{})[_0x10cfcb('0x14')](function(){return _0x4616ba;}):_0x4616ba;})[_0x398994('0xc')](function(_0x5aeaac){const _0x48f78e=_0x398994;logger[_0x48f78e('0x5d')](_0x48f78e('0x1d'),_0x5aeaac);throw _0x5aeaac;});}return _0x4616ba;})[_0x57fbf1('0x14')](respondWithResult(_0xab0857,null))[_0x57fbf1('0xc')](handleError(_0xab0857,null));}),_0x53104b[_0x4ca301('0x15')]();}catch(_0x248e8f){_0xab0857[_0x4ca301('0x3')](0x1f4)['send'](_0x248e8f);}},exports[_0x3dcc9b('0x41')]=function(_0x5e88cf,_0x2d4aa9){const _0x11187c=_0x3dcc9b;return db[_0x11187c('0x2b')][_0x11187c('0x2f')]({'where':{'id':_0x5e88cf[_0x11187c('0x30')]['id']}})[_0x11187c('0x14')](handleEntityNotFound(_0x2d4aa9,null))[_0x11187c('0x14')](saveUpdates(_[_0x11187c('0x25')](_0x5e88cf[_0x11187c('0x38')],[_0x11187c('0x5f'),_0x11187c('0x53')]),null))[_0x11187c('0x14')](respondWithResult(_0x2d4aa9,null))[_0x11187c('0xc')](handleError(_0x2d4aa9,null));},exports[_0x3dcc9b('0x39')]=function(_0x25b492,_0x48cb83){const _0x2f3036=_0x3dcc9b;return db['Sound']['findOne']({'where':{'id':_0x25b492['params']['id']}})['then'](function(_0x52dd52){const _0x45bdf5=a583_0x1f25;if(_0x52dd52)return _0x52dd52[_0x45bdf5('0xa')]();})[_0x2f3036('0x14')](function(_0x4eb241){const _0x269ee0=_0x2f3036,_0x58716e=path[_0x269ee0('0x32')](config[_0x269ee0('0xd')],_0x269ee0('0x16'),util[_0x269ee0('0x43')](_0x269ee0('0x5c'),_0x4eb241[_0x269ee0('0x54')],_0x4eb241['original_format'])),_0x4f594f=path[_0x269ee0('0x32')](config['root'],'server/files/sounds/converted',util[_0x269ee0('0x43')](_0x269ee0('0x5c'),_0x4eb241[_0x269ee0('0x54')],_0x4eb241[_0x269ee0('0xf')]));return fs[_0x269ee0('0x20')](_0x58716e),fs[_0x269ee0('0x20')](_0x4f594f),_0x4eb241;})['then'](function(_0x1ff806){const _0x5945c9=_0x2f3036;if(_0x1ff806)return _0x48cb83['status'](0xcc)[_0x5945c9('0x3b')]();})[_0x2f3036('0x14')](handleEntityNotFound(_0x48cb83,null))['catch'](handleError(_0x48cb83,null));}; \ No newline at end of file diff --git a/server/api/sound/sound.model.js b/server/api/sound/sound.model.js index d38a5e9..4ddc731 100644 --- a/server/api/sound/sound.model.js +++ b/server/api/sound/sound.model.js @@ -1 +1 @@ -const a584_0xacd6=['Sound','./sound.attributes','tools_sounds','exports','define'];(function(_0x4958d7,_0xacd61c){const _0x3f6743=function(_0x36c6e9){while(--_0x36c6e9){_0x4958d7['push'](_0x4958d7['shift']());}};_0x3f6743(++_0xacd61c);}(a584_0xacd6,0xc1));const a584_0x3f67=function(_0x4958d7,_0xacd61c){_0x4958d7=_0x4958d7-0x0;let _0x3f6743=a584_0xacd6[_0x4958d7];return _0x3f6743;};const _0x637056=a584_0x3f67;'use strict';const attributes=require(_0x637056('0x3'));module[_0x637056('0x0')]=function(_0x36c6e9){const _0x5684af=_0x637056,_0x2078e1=_0x36c6e9[_0x5684af('0x1')](_0x5684af('0x2'),attributes,{'tableName':_0x5684af('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2078e1;}; \ No newline at end of file +const a584_0xb9ec=['Sound','tools_sounds','exports','define','./sound.attributes'];(function(_0x3d8b1d,_0xb9ec0e){const _0x1bd830=function(_0x4789d1){while(--_0x4789d1){_0x3d8b1d['push'](_0x3d8b1d['shift']());}};_0x1bd830(++_0xb9ec0e);}(a584_0xb9ec,0xf4));const a584_0x1bd8=function(_0x3d8b1d,_0xb9ec0e){_0x3d8b1d=_0x3d8b1d-0x0;let _0x1bd830=a584_0xb9ec[_0x3d8b1d];return _0x1bd830;};const _0xdef1bd=a584_0x1bd8;'use strict';const attributes=require(_0xdef1bd('0x0'));module[_0xdef1bd('0x3')]=function(_0x4789d1){const _0x537156=_0xdef1bd,_0x1c9fea=_0x4789d1[_0x537156('0x4')](_0x537156('0x1'),attributes,{'tableName':_0x537156('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x1c9fea;}; \ No newline at end of file diff --git a/server/api/sound/sound.rpc.js b/server/api/sound/sound.rpc.js index d84a726..4250e07 100644 --- a/server/api/sound/sound.rpc.js +++ b/server/api/sound/sound.rpc.js @@ -1 +1 @@ -const a585_0x3043=['info','map','model','stringify','include','findOne','then','debug','message','error','raw','options','rpc','../../mysqldb','lodash','catch','attributes','where','ShowSound','../../config/logger'];(function(_0x135005,_0x304379){const _0x189046=function(_0x1d4c7c){while(--_0x1d4c7c){_0x135005['push'](_0x135005['shift']());}};_0x189046(++_0x304379);}(a585_0x3043,0xad));const a585_0x1890=function(_0x135005,_0x304379){_0x135005=_0x135005-0x0;let _0x189046=a585_0x3043[_0x135005];return _0x189046;};const _0x5b82d3=a585_0x1890;'use strict';const db=require(_0x5b82d3('0x0'))['db'],logger=require(_0x5b82d3('0x6'))(_0x5b82d3('0x13')),_=require(_0x5b82d3('0x1'));exports[_0x5b82d3('0x5')]=function(_0x1d4c7c){const _0x329c38=this;return new Promise(function(_0xdad653,_0x50229f){const _0x6cfb64=a585_0x1890;return db['Sound'][_0x6cfb64('0xc')]({'raw':_0x1d4c7c['options']?_0x1d4c7c['options'][_0x6cfb64('0x11')]===undefined?!![]:![]:!![],'where':_0x1d4c7c[_0x6cfb64('0x12')]?_0x1d4c7c[_0x6cfb64('0x12')][_0x6cfb64('0x4')]||null:null,'attributes':_0x1d4c7c[_0x6cfb64('0x12')]?_0x1d4c7c['options']['attributes']||null:null,'include':_0x1d4c7c[_0x6cfb64('0x12')]?_0x1d4c7c[_0x6cfb64('0x12')]['include']?_[_0x6cfb64('0x8')](_0x1d4c7c['options'][_0x6cfb64('0xb')],function(_0x224814){const _0x19e6b7=_0x6cfb64;return{'model':db[_0x224814['model']],'as':_0x224814['as'],'attributes':_0x224814[_0x19e6b7('0x3')],'include':_0x224814[_0x19e6b7('0xb')]?_[_0x19e6b7('0x8')](_0x224814[_0x19e6b7('0xb')],function(_0x523165){const _0x3186b5=_0x19e6b7;return{'model':db[_0x523165[_0x3186b5('0x9')]],'as':_0x523165['as'],'attributes':_0x523165[_0x3186b5('0x3')],'include':_0x523165[_0x3186b5('0xb')]?_['map'](_0x523165['include'],function(_0x38b37b){const _0x25d4bf=_0x3186b5;return{'model':db[_0x38b37b[_0x25d4bf('0x9')]],'as':_0x38b37b['as'],'attributes':_0x38b37b[_0x25d4bf('0x3')]};}):[]};}):[]};}):[]:[]})[_0x6cfb64('0xd')](function(_0x4da5a0){const _0x51370a=_0x6cfb64;logger[_0x51370a('0x7')](_0x51370a('0x5'),_0x1d4c7c),logger[_0x51370a('0xe')](_0x51370a('0x5'),_0x1d4c7c,JSON[_0x51370a('0xa')](_0x4da5a0)),_0xdad653(_0x4da5a0);})[_0x6cfb64('0x2')](function(_0x19d1d6){const _0x1dcb9a=_0x6cfb64;logger['error'](_0x1dcb9a('0x5'),_0x19d1d6[_0x1dcb9a('0xf')],_0x1d4c7c),_0x50229f(_0x329c38[_0x1dcb9a('0x10')](0x1f4,_0x19d1d6['message']));});});}; \ No newline at end of file +const a585_0x3bad=['findOne','raw','debug','info','../../config/logger','catch','model','ShowSound','map','include','message','options','../../mysqldb','error','where','lodash','attributes','then','Sound','stringify'];(function(_0x44945e,_0x3bad45){const _0x4401a1=function(_0x4a772f){while(--_0x4a772f){_0x44945e['push'](_0x44945e['shift']());}};_0x4401a1(++_0x3bad45);}(a585_0x3bad,0x170));const a585_0x4401=function(_0x44945e,_0x3bad45){_0x44945e=_0x44945e-0x0;let _0x4401a1=a585_0x3bad[_0x44945e];return _0x4401a1;};const _0x5040bf=a585_0x4401;'use strict';const db=require(_0x5040bf('0x4'))['db'],logger=require(_0x5040bf('0x10'))('rpc'),_=require(_0x5040bf('0x7'));exports[_0x5040bf('0x13')]=function(_0x4a772f){const _0x1091f6=this;return new Promise(function(_0xbd612e,_0x2e7d91){const _0x46b33e=a585_0x4401;return db[_0x46b33e('0xa')][_0x46b33e('0xc')]({'raw':_0x4a772f[_0x46b33e('0x3')]?_0x4a772f[_0x46b33e('0x3')][_0x46b33e('0xd')]===undefined?!![]:![]:!![],'where':_0x4a772f[_0x46b33e('0x3')]?_0x4a772f['options'][_0x46b33e('0x6')]||null:null,'attributes':_0x4a772f['options']?_0x4a772f['options'][_0x46b33e('0x8')]||null:null,'include':_0x4a772f['options']?_0x4a772f['options']['include']?_['map'](_0x4a772f[_0x46b33e('0x3')]['include'],function(_0x3351e8){const _0x1aa1b6=_0x46b33e;return{'model':db[_0x3351e8[_0x1aa1b6('0x12')]],'as':_0x3351e8['as'],'attributes':_0x3351e8[_0x1aa1b6('0x8')],'include':_0x3351e8[_0x1aa1b6('0x1')]?_[_0x1aa1b6('0x0')](_0x3351e8[_0x1aa1b6('0x1')],function(_0x315676){const _0x5b7e8d=_0x1aa1b6;return{'model':db[_0x315676[_0x5b7e8d('0x12')]],'as':_0x315676['as'],'attributes':_0x315676['attributes'],'include':_0x315676['include']?_['map'](_0x315676[_0x5b7e8d('0x1')],function(_0x3125da){const _0x1992fd=_0x5b7e8d;return{'model':db[_0x3125da[_0x1992fd('0x12')]],'as':_0x3125da['as'],'attributes':_0x3125da['attributes']};}):[]};}):[]};}):[]:[]})[_0x46b33e('0x9')](function(_0x2b3bd9){const _0x1cbb4a=_0x46b33e;logger[_0x1cbb4a('0xf')](_0x1cbb4a('0x13'),_0x4a772f),logger[_0x1cbb4a('0xe')](_0x1cbb4a('0x13'),_0x4a772f,JSON[_0x1cbb4a('0xb')](_0x2b3bd9)),_0xbd612e(_0x2b3bd9);})[_0x46b33e('0x11')](function(_0x2451c9){const _0x211208=_0x46b33e;logger[_0x211208('0x5')](_0x211208('0x13'),_0x2451c9[_0x211208('0x2')],_0x4a772f),_0x2e7d91(_0x1091f6[_0x211208('0x5')](0x1f4,_0x2451c9['message']));});});}; \ No newline at end of file diff --git a/server/api/squareMessage/index.js b/server/api/squareMessage/index.js index 53498f9..a170992 100644 --- a/server/api/squareMessage/index.js +++ b/server/api/squareMessage/index.js @@ -1 +1 @@ -const a586_0x5d3a=['put','/:id','get','../../components/auth/service','destroy','Router','show','exports','create','isAuthenticated','express'];(function(_0x1212ff,_0x5d3a9c){const _0x20b2b3=function(_0x2793c0){while(--_0x2793c0){_0x1212ff['push'](_0x1212ff['shift']());}};_0x20b2b3(++_0x5d3a9c);}(a586_0x5d3a,0x149));const a586_0x20b2=function(_0x1212ff,_0x5d3a9c){_0x1212ff=_0x1212ff-0x0;let _0x20b2b3=a586_0x5d3a[_0x1212ff];return _0x20b2b3;};const _0x315286=a586_0x20b2;'use strict';const express=require(_0x315286('0x0')),router=express[_0x315286('0x6')](),auth=require(_0x315286('0x4')),controller=require('./squareMessage.controller');router[_0x315286('0x3')]('/',auth[_0x315286('0xa')](),controller['index']),router[_0x315286('0x3')](_0x315286('0x2'),auth[_0x315286('0xa')](),controller[_0x315286('0x7')]),router['post']('/',auth[_0x315286('0xa')](),controller[_0x315286('0x9')]),router[_0x315286('0x1')](_0x315286('0x2'),auth[_0x315286('0xa')](),controller['update']),router['delete'](_0x315286('0x2'),auth[_0x315286('0xa')](),controller[_0x315286('0x5')]),module[_0x315286('0x8')]=router; \ No newline at end of file +const a586_0x847c=['create','exports','../../components/auth/service','post','delete','update','show','/:id','isAuthenticated','get','express','destroy'];(function(_0x48379c,_0x847cc3){const _0x9a5713=function(_0xe55a61){while(--_0xe55a61){_0x48379c['push'](_0x48379c['shift']());}};_0x9a5713(++_0x847cc3);}(a586_0x847c,0xc1));const a586_0x9a57=function(_0x48379c,_0x847cc3){_0x48379c=_0x48379c-0x0;let _0x9a5713=a586_0x847c[_0x48379c];return _0x9a5713;};const _0x3f7ded=a586_0x9a57;'use strict';const express=require(_0x3f7ded('0x9')),router=express['Router'](),auth=require(_0x3f7ded('0x1')),controller=require('./squareMessage.controller');router[_0x3f7ded('0x8')]('/',auth[_0x3f7ded('0x7')](),controller['index']),router[_0x3f7ded('0x8')](_0x3f7ded('0x6'),auth['isAuthenticated'](),controller[_0x3f7ded('0x5')]),router[_0x3f7ded('0x2')]('/',auth[_0x3f7ded('0x7')](),controller[_0x3f7ded('0xb')]),router['put']('/:id',auth[_0x3f7ded('0x7')](),controller[_0x3f7ded('0x4')]),router[_0x3f7ded('0x3')](_0x3f7ded('0x6'),auth['isAuthenticated'](),controller[_0x3f7ded('0xa')]),module[_0x3f7ded('0x0')]=router; \ No newline at end of file diff --git a/server/api/squareMessage/squareMessage.attributes.js b/server/api/squareMessage/squareMessage.attributes.js index 918b43e..38c3aba 100644 --- a/server/api/squareMessage/squareMessage.attributes.js +++ b/server/api/squareMessage/squareMessage.attributes.js @@ -1 +1 @@ -const a587_0x4323=['TEXT','exports','ENUM','sequelize','out'];(function(_0x4e27b4,_0x4323de){const _0x39f9d7=function(_0x2227a5){while(--_0x2227a5){_0x4e27b4['push'](_0x4e27b4['shift']());}};_0x39f9d7(++_0x4323de);}(a587_0x4323,0x1d7));const a587_0x39f9=function(_0x4e27b4,_0x4323de){_0x4e27b4=_0x4e27b4-0x0;let _0x39f9d7=a587_0x4323[_0x4e27b4];return _0x39f9d7;};const _0x49eecf=a587_0x39f9;'use strict';const Sequelize=require(_0x49eecf('0x2'));module[_0x49eecf('0x0')]={'uniqueid':{'type':Sequelize['STRING']},'body':{'type':Sequelize[_0x49eecf('0x4')]('medium'),'allowNull':![]},'direction':{'type':Sequelize[_0x49eecf('0x1')]('in','out'),'defaultValue':_0x49eecf('0x3'),'allowNull':![]},'providerName':{'type':Sequelize['STRING']},'providerResponse':{'type':Sequelize['TEXT']}}; \ No newline at end of file +const a587_0x3661=['exports','TEXT','medium','out','STRING','sequelize'];(function(_0x49c00a,_0x36617d){const _0x25cda6=function(_0x21b6aa){while(--_0x21b6aa){_0x49c00a['push'](_0x49c00a['shift']());}};_0x25cda6(++_0x36617d);}(a587_0x3661,0x154));const a587_0x25cd=function(_0x49c00a,_0x36617d){_0x49c00a=_0x49c00a-0x0;let _0x25cda6=a587_0x3661[_0x49c00a];return _0x25cda6;};const _0x2f51ff=a587_0x25cd;'use strict';const Sequelize=require(_0x2f51ff('0x1'));module[_0x2f51ff('0x2')]={'uniqueid':{'type':Sequelize[_0x2f51ff('0x0')]},'body':{'type':Sequelize[_0x2f51ff('0x3')](_0x2f51ff('0x4')),'allowNull':![]},'direction':{'type':Sequelize['ENUM']('in',_0x2f51ff('0x5')),'defaultValue':_0x2f51ff('0x5'),'allowNull':![]},'providerName':{'type':Sequelize[_0x2f51ff('0x0')]},'providerResponse':{'type':Sequelize[_0x2f51ff('0x3')]}}; \ No newline at end of file diff --git a/server/api/squareMessage/squareMessage.controller.js b/server/api/squareMessage/squareMessage.controller.js index 8eac36b..5146b80 100644 --- a/server/api/squareMessage/squareMessage.controller.js +++ b/server/api/squareMessage/squareMessage.controller.js @@ -1 +1 @@ -const a588_0x4bf1=['params','sendStatus','end','query','index','create','count','filters','name','rows','limit','catch','fieldName','status','model','include','body','filter','show','merge','error','findOne','keys','sort','Content-Range','destroy','like','fields','undefined','../../config/logger','map','nolimit','api','update','key','json','../../components/parsers/qs','findAll','pick','includeAll','type','sequelize','length','rawAttributes','offset','SquareMessage','then','intersection','where','options','order','attributes'];(function(_0x581d83,_0x4bf190){const _0x43236a=function(_0x377c3a){while(--_0x377c3a){_0x581d83['push'](_0x581d83['shift']());}};_0x43236a(++_0x4bf190);}(a588_0x4bf1,0x119));const a588_0x4323=function(_0x581d83,_0x4bf190){_0x581d83=_0x581d83-0x0;let _0x43236a=a588_0x4bf1[_0x581d83];return _0x43236a;};const _0x51447a=a588_0x4323;'use strict';const _=require('lodash'),qs=require(_0x51447a('0xf')),logger=require(_0x51447a('0x8'))(_0x51447a('0xb')),db=require('../../mysqldb')['db'],{Op}=require(_0x51447a('0x14'));function respondWithResult(_0x377c3a,_0x4229b9){return _0x4229b9=_0x4229b9||0xc8,function(_0x367b72){const _0x4a7244=a588_0x4323;if(_0x367b72)return _0x377c3a[_0x4a7244('0x2c')](_0x4229b9)[_0x4a7244('0xe')](_0x367b72);};}function respondWithFilteredResult(_0x244578,_0x209a1e){return function(_0x16d727){const _0x11fbf3=a588_0x4323;if(_0x16d727){const _0x1feb99=_0x16d727[_0x11fbf3('0x25')],_0x3ebebe=_0x209a1e[_0x11fbf3('0x17')];let _0x282e75=_0x209a1e[_0x11fbf3('0x17')]+_0x209a1e[_0x11fbf3('0x29')],_0x443fd1;return _0x282e75>=_0x1feb99?(_0x282e75=_0x1feb99,_0x443fd1=0xc8):_0x443fd1=0xce,_0x244578[_0x11fbf3('0x2c')](_0x443fd1),_0x244578['set'](_0x11fbf3('0x3'),_0x3ebebe+'-'+_0x282e75+'/'+_0x1feb99)[_0x11fbf3('0xe')](_0x16d727);}return null;};}function saveUpdates(_0x288297){return function(_0x10c68b){const _0x4b9d1e=a588_0x4323;if(_0x10c68b)return _0x10c68b[_0x4b9d1e('0xc')](_0x288297)[_0x4b9d1e('0x19')](function(_0x5b9978){return _0x5b9978;});return null;};}function removeEntity(_0x5edb98){return function(_0x21facd){const _0x45720b=a588_0x4323;if(_0x21facd)return _0x21facd[_0x45720b('0x4')]()[_0x45720b('0x19')](function(){const _0x48a5e8=_0x45720b;_0x5edb98[_0x48a5e8('0x2c')](0xcc)[_0x48a5e8('0x21')]();});};}function handleEntityNotFound(_0x46282c){return function(_0x5c4fe7){const _0x13a762=a588_0x4323;return!_0x5c4fe7&&_0x46282c[_0x13a762('0x20')](0x194),_0x5c4fe7;};}function handleError(_0x486ceb,_0x2d0e84){return _0x2d0e84=_0x2d0e84||0x1f4,function(_0x216575){const _0x26036b=a588_0x4323;logger[_0x26036b('0x33')](_0x216575['stack']),_0x216575['name']&&delete _0x216575[_0x26036b('0x27')],_0x486ceb[_0x26036b('0x2c')](_0x2d0e84)['send'](_0x216575);};}exports[_0x51447a('0x23')]=function(_0x3f2d4a,_0x1e80fc){const _0x396f41=_0x51447a;let _0x6f548a={};const _0x5dd2da={},_0x11bab9={'count':0x0,'rows':[]},_0x55e064=_['map'](db['SquareMessage'][_0x396f41('0x16')],function(_0x12c87d){const _0x48e58a=_0x396f41;return{'name':_0x12c87d[_0x48e58a('0x2b')],'type':_0x12c87d['type'][_0x48e58a('0xd')]};});_0x5dd2da[_0x396f41('0x2d')]=_[_0x396f41('0x9')](_0x55e064,_0x396f41('0x27')),_0x5dd2da[_0x396f41('0x22')]=_[_0x396f41('0x1')](_0x3f2d4a['query']),_0x5dd2da[_0x396f41('0x26')]=_[_0x396f41('0x1a')](_0x5dd2da['model'],_0x5dd2da[_0x396f41('0x22')]),_0x6f548a[_0x396f41('0x1e')]=_[_0x396f41('0x1a')](_0x5dd2da[_0x396f41('0x2d')],qs[_0x396f41('0x6')](_0x3f2d4a['query']['fields'])),_0x6f548a['attributes']=_0x6f548a['attributes'][_0x396f41('0x15')]?_0x6f548a[_0x396f41('0x1e')]:_0x5dd2da[_0x396f41('0x2d')];typeof _0x3f2d4a[_0x396f41('0x22')][_0x396f41('0xa')]===_0x396f41('0x7')&&(_0x6f548a['limit']=qs[_0x396f41('0x29')](_0x3f2d4a[_0x396f41('0x22')][_0x396f41('0x29')]),_0x6f548a['offset']=qs['offset'](_0x3f2d4a[_0x396f41('0x22')][_0x396f41('0x17')]));_0x6f548a[_0x396f41('0x1d')]=qs[_0x396f41('0x2')](_0x3f2d4a[_0x396f41('0x22')][_0x396f41('0x2')]),_0x6f548a['where']=qs[_0x396f41('0x26')](_[_0x396f41('0x11')](_0x3f2d4a['query'],_0x5dd2da[_0x396f41('0x26')]),_0x55e064);_0x3f2d4a[_0x396f41('0x22')][_0x396f41('0x30')]&&(_0x6f548a['where']=_[_0x396f41('0x32')](_0x6f548a[_0x396f41('0x1b')],{[Op['or']]:_[_0x396f41('0x9')](_0x55e064,function(_0x45cad2){const _0x160308=_0x396f41;if(_0x45cad2[_0x160308('0x13')]!=='VIRTUAL'){const _0x5669ea={};return _0x5669ea[_0x45cad2['name']]={[Op[_0x160308('0x5')]]:'%'+_0x3f2d4a[_0x160308('0x22')]['filter']+'%'},_0x5669ea;}})}));_0x6f548a=_[_0x396f41('0x32')]({},_0x6f548a,_0x3f2d4a['options']);const _0x32b1a7={'where':_0x6f548a[_0x396f41('0x1b')]};return db[_0x396f41('0x18')][_0x396f41('0x25')](_0x32b1a7)[_0x396f41('0x19')](function(_0x36da36){const _0x304e72=_0x396f41;return _0x11bab9[_0x304e72('0x25')]=_0x36da36,_0x3f2d4a[_0x304e72('0x22')][_0x304e72('0x12')]&&(_0x6f548a[_0x304e72('0x2e')]=[{'all':!![]}]),db[_0x304e72('0x18')][_0x304e72('0x10')](_0x6f548a);})[_0x396f41('0x19')](function(_0x64008d){const _0x214929=_0x396f41;return _0x11bab9[_0x214929('0x28')]=_0x64008d,_0x11bab9;})['then'](respondWithFilteredResult(_0x1e80fc,_0x6f548a))[_0x396f41('0x2a')](handleError(_0x1e80fc,null));},exports[_0x51447a('0x31')]=function(_0x3d9d44,_0x2a6878){const _0x32975a=_0x51447a;let _0x37d48a={'raw':!![],'where':{'id':_0x3d9d44[_0x32975a('0x1f')]['id']}};const _0x19a71a={};return _0x19a71a[_0x32975a('0x2d')]=_[_0x32975a('0x1')](db[_0x32975a('0x18')][_0x32975a('0x16')]),_0x19a71a[_0x32975a('0x22')]=_[_0x32975a('0x1')](_0x3d9d44[_0x32975a('0x22')]),_0x19a71a[_0x32975a('0x26')]=_[_0x32975a('0x1a')](_0x19a71a[_0x32975a('0x2d')],_0x19a71a[_0x32975a('0x22')]),_0x37d48a[_0x32975a('0x1e')]=_[_0x32975a('0x1a')](_0x19a71a[_0x32975a('0x2d')],qs[_0x32975a('0x6')](_0x3d9d44[_0x32975a('0x22')][_0x32975a('0x6')])),_0x37d48a[_0x32975a('0x1e')]=_0x37d48a['attributes']['length']?_0x37d48a[_0x32975a('0x1e')]:_0x19a71a[_0x32975a('0x2d')],_0x3d9d44['query'][_0x32975a('0x12')]&&(_0x37d48a[_0x32975a('0x2e')]=[{'all':!![]}]),_0x37d48a=_[_0x32975a('0x32')]({},_0x37d48a,_0x3d9d44[_0x32975a('0x1c')]),db[_0x32975a('0x18')][_0x32975a('0x0')](_0x37d48a)[_0x32975a('0x19')](handleEntityNotFound(_0x2a6878,null))[_0x32975a('0x19')](respondWithResult(_0x2a6878,null))[_0x32975a('0x2a')](handleError(_0x2a6878,null));},exports[_0x51447a('0x24')]=function(_0x3ce850,_0x48c8db){const _0x46dd49=_0x51447a;return db[_0x46dd49('0x18')][_0x46dd49('0x24')](_0x3ce850[_0x46dd49('0x2f')],{})[_0x46dd49('0x19')](respondWithResult(_0x48c8db,0xc9))['catch'](handleError(_0x48c8db,null));},exports['update']=function(_0xc850b5,_0x5f070a){const _0x33cd7b=_0x51447a;return _0xc850b5[_0x33cd7b('0x2f')]['id']&&delete _0xc850b5['body']['id'],db[_0x33cd7b('0x18')][_0x33cd7b('0x0')]({'where':{'id':_0xc850b5[_0x33cd7b('0x1f')]['id']}})[_0x33cd7b('0x19')](handleEntityNotFound(_0x5f070a,null))[_0x33cd7b('0x19')](saveUpdates(_0xc850b5[_0x33cd7b('0x2f')],null))[_0x33cd7b('0x19')](respondWithResult(_0x5f070a,null))[_0x33cd7b('0x2a')](handleError(_0x5f070a,null));},exports[_0x51447a('0x4')]=function(_0x4ebcab,_0x61e193){const _0x541860=_0x51447a;return db['SquareMessage']['findOne']({'where':{'id':_0x4ebcab[_0x541860('0x1f')]['id']}})[_0x541860('0x19')](handleEntityNotFound(_0x61e193,null))[_0x541860('0x19')](removeEntity(_0x61e193,null))[_0x541860('0x2a')](handleError(_0x61e193,null));}; \ No newline at end of file +const a588_0x5177=['json','include','sendStatus','findOne','offset','type','undefined','count','attributes','length','status','where','filters','body','map','fieldName','../../config/logger','../../mysqldb','set','options','intersection','params','includeAll','sort','stack','key','pick','model','rows','destroy','like','then','update','fields','limit','query','api','SquareMessage','end','catch','sequelize','name','create','show','keys','filter','merge','rawAttributes','findAll'];(function(_0x3da4e1,_0x517762){const _0x42aaf5=function(_0x1a786a){while(--_0x1a786a){_0x3da4e1['push'](_0x3da4e1['shift']());}};_0x42aaf5(++_0x517762);}(a588_0x5177,0x18e));const a588_0x42aa=function(_0x3da4e1,_0x517762){_0x3da4e1=_0x3da4e1-0x0;let _0x42aaf5=a588_0x5177[_0x3da4e1];return _0x42aaf5;};const _0x1566bb=a588_0x42aa;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x1566bb('0xa'))(_0x1566bb('0x1e')),db=require(_0x1566bb('0xb'))['db'],{Op}=require(_0x1566bb('0x22'));function respondWithResult(_0x1a786a,_0x514264){return _0x514264=_0x514264||0xc8,function(_0x186001){const _0x5ee3d5=a588_0x42aa;if(_0x186001)return _0x1a786a[_0x5ee3d5('0x4')](_0x514264)[_0x5ee3d5('0x2b')](_0x186001);};}function respondWithFilteredResult(_0xc605eb,_0x8e2afe){return function(_0x12833b){const _0x5ce7c1=a588_0x42aa;if(_0x12833b){const _0x4597da=_0x12833b['count'],_0x3cc9ba=_0x8e2afe[_0x5ce7c1('0x2f')];let _0x9af93=_0x8e2afe[_0x5ce7c1('0x2f')]+_0x8e2afe['limit'],_0x5cc0ce;return _0x9af93>=_0x4597da?(_0x9af93=_0x4597da,_0x5cc0ce=0xc8):_0x5cc0ce=0xce,_0xc605eb[_0x5ce7c1('0x4')](_0x5cc0ce),_0xc605eb[_0x5ce7c1('0xc')]('Content-Range',_0x3cc9ba+'-'+_0x9af93+'/'+_0x4597da)[_0x5ce7c1('0x2b')](_0x12833b);}return null;};}function saveUpdates(_0x2c9225){return function(_0x259947){const _0xfb67d1=a588_0x42aa;if(_0x259947)return _0x259947[_0xfb67d1('0x1a')](_0x2c9225)[_0xfb67d1('0x19')](function(_0x1b2894){return _0x1b2894;});return null;};}function removeEntity(_0x555950){return function(_0x50f852){const _0x321b8f=a588_0x42aa;if(_0x50f852)return _0x50f852[_0x321b8f('0x17')]()['then'](function(){const _0x1426cd=_0x321b8f;_0x555950['status'](0xcc)[_0x1426cd('0x20')]();});};}function handleEntityNotFound(_0x34c0ec){return function(_0x2cc4db){const _0x327434=a588_0x42aa;return!_0x2cc4db&&_0x34c0ec[_0x327434('0x2d')](0x194),_0x2cc4db;};}function handleError(_0x1d296b,_0x2c3502){return _0x2c3502=_0x2c3502||0x1f4,function(_0x5166ea){const _0x31a156=a588_0x42aa;logger['error'](_0x5166ea[_0x31a156('0x12')]),_0x5166ea[_0x31a156('0x23')]&&delete _0x5166ea[_0x31a156('0x23')],_0x1d296b[_0x31a156('0x4')](_0x2c3502)['send'](_0x5166ea);};}exports['index']=function(_0x1b5be4,_0x535e2e){const _0x231abb=_0x1566bb;let _0xc20e3={};const _0x41ba6b={},_0xc71dd6={'count':0x0,'rows':[]},_0x298224=_[_0x231abb('0x8')](db[_0x231abb('0x1f')][_0x231abb('0x29')],function(_0x58db0b){const _0x19c297=_0x231abb;return{'name':_0x58db0b[_0x19c297('0x9')],'type':_0x58db0b[_0x19c297('0x30')][_0x19c297('0x13')]};});_0x41ba6b[_0x231abb('0x15')]=_[_0x231abb('0x8')](_0x298224,'name'),_0x41ba6b[_0x231abb('0x1d')]=_['keys'](_0x1b5be4['query']),_0x41ba6b['filters']=_[_0x231abb('0xe')](_0x41ba6b['model'],_0x41ba6b[_0x231abb('0x1d')]),_0xc20e3[_0x231abb('0x2')]=_[_0x231abb('0xe')](_0x41ba6b['model'],qs[_0x231abb('0x1b')](_0x1b5be4['query'][_0x231abb('0x1b')])),_0xc20e3[_0x231abb('0x2')]=_0xc20e3[_0x231abb('0x2')][_0x231abb('0x3')]?_0xc20e3[_0x231abb('0x2')]:_0x41ba6b[_0x231abb('0x15')];typeof _0x1b5be4[_0x231abb('0x1d')]['nolimit']===_0x231abb('0x0')&&(_0xc20e3[_0x231abb('0x1c')]=qs[_0x231abb('0x1c')](_0x1b5be4[_0x231abb('0x1d')]['limit']),_0xc20e3[_0x231abb('0x2f')]=qs[_0x231abb('0x2f')](_0x1b5be4[_0x231abb('0x1d')]['offset']));_0xc20e3['order']=qs[_0x231abb('0x11')](_0x1b5be4[_0x231abb('0x1d')]['sort']),_0xc20e3[_0x231abb('0x5')]=qs[_0x231abb('0x6')](_[_0x231abb('0x14')](_0x1b5be4[_0x231abb('0x1d')],_0x41ba6b['filters']),_0x298224);_0x1b5be4['query']['filter']&&(_0xc20e3[_0x231abb('0x5')]=_[_0x231abb('0x28')](_0xc20e3[_0x231abb('0x5')],{[Op['or']]:_['map'](_0x298224,function(_0x5cc2c7){const _0x55e8ac=_0x231abb;if(_0x5cc2c7[_0x55e8ac('0x30')]!=='VIRTUAL'){const _0x56d326={};return _0x56d326[_0x5cc2c7[_0x55e8ac('0x23')]]={[Op[_0x55e8ac('0x18')]]:'%'+_0x1b5be4[_0x55e8ac('0x1d')][_0x55e8ac('0x27')]+'%'},_0x56d326;}})}));_0xc20e3=_[_0x231abb('0x28')]({},_0xc20e3,_0x1b5be4[_0x231abb('0xd')]);const _0x5da97a={'where':_0xc20e3[_0x231abb('0x5')]};return db[_0x231abb('0x1f')][_0x231abb('0x1')](_0x5da97a)[_0x231abb('0x19')](function(_0x306116){const _0x5785d9=_0x231abb;return _0xc71dd6[_0x5785d9('0x1')]=_0x306116,_0x1b5be4[_0x5785d9('0x1d')][_0x5785d9('0x10')]&&(_0xc20e3['include']=[{'all':!![]}]),db[_0x5785d9('0x1f')][_0x5785d9('0x2a')](_0xc20e3);})[_0x231abb('0x19')](function(_0x2c165f){const _0x1697bc=_0x231abb;return _0xc71dd6[_0x1697bc('0x16')]=_0x2c165f,_0xc71dd6;})['then'](respondWithFilteredResult(_0x535e2e,_0xc20e3))[_0x231abb('0x21')](handleError(_0x535e2e,null));},exports[_0x1566bb('0x25')]=function(_0x4b6889,_0x5093d3){const _0x484ba6=_0x1566bb;let _0x1c9b0e={'raw':!![],'where':{'id':_0x4b6889[_0x484ba6('0xf')]['id']}};const _0x11db07={};return _0x11db07[_0x484ba6('0x15')]=_[_0x484ba6('0x26')](db[_0x484ba6('0x1f')]['rawAttributes']),_0x11db07[_0x484ba6('0x1d')]=_[_0x484ba6('0x26')](_0x4b6889['query']),_0x11db07['filters']=_['intersection'](_0x11db07[_0x484ba6('0x15')],_0x11db07[_0x484ba6('0x1d')]),_0x1c9b0e[_0x484ba6('0x2')]=_['intersection'](_0x11db07[_0x484ba6('0x15')],qs[_0x484ba6('0x1b')](_0x4b6889[_0x484ba6('0x1d')]['fields'])),_0x1c9b0e[_0x484ba6('0x2')]=_0x1c9b0e[_0x484ba6('0x2')]['length']?_0x1c9b0e[_0x484ba6('0x2')]:_0x11db07[_0x484ba6('0x15')],_0x4b6889[_0x484ba6('0x1d')][_0x484ba6('0x10')]&&(_0x1c9b0e[_0x484ba6('0x2c')]=[{'all':!![]}]),_0x1c9b0e=_['merge']({},_0x1c9b0e,_0x4b6889[_0x484ba6('0xd')]),db[_0x484ba6('0x1f')]['findOne'](_0x1c9b0e)[_0x484ba6('0x19')](handleEntityNotFound(_0x5093d3,null))[_0x484ba6('0x19')](respondWithResult(_0x5093d3,null))[_0x484ba6('0x21')](handleError(_0x5093d3,null));},exports['create']=function(_0x2a5222,_0x40c3fc){const _0x5b8f64=_0x1566bb;return db[_0x5b8f64('0x1f')][_0x5b8f64('0x24')](_0x2a5222['body'],{})[_0x5b8f64('0x19')](respondWithResult(_0x40c3fc,0xc9))['catch'](handleError(_0x40c3fc,null));},exports[_0x1566bb('0x1a')]=function(_0x59fa38,_0x3528a7){const _0x2965f3=_0x1566bb;return _0x59fa38[_0x2965f3('0x7')]['id']&&delete _0x59fa38[_0x2965f3('0x7')]['id'],db['SquareMessage'][_0x2965f3('0x2e')]({'where':{'id':_0x59fa38[_0x2965f3('0xf')]['id']}})['then'](handleEntityNotFound(_0x3528a7,null))['then'](saveUpdates(_0x59fa38[_0x2965f3('0x7')],null))[_0x2965f3('0x19')](respondWithResult(_0x3528a7,null))[_0x2965f3('0x21')](handleError(_0x3528a7,null));},exports[_0x1566bb('0x17')]=function(_0x552587,_0x8e30e6){const _0xc7759a=_0x1566bb;return db[_0xc7759a('0x1f')][_0xc7759a('0x2e')]({'where':{'id':_0x552587[_0xc7759a('0xf')]['id']}})['then'](handleEntityNotFound(_0x8e30e6,null))['then'](removeEntity(_0x8e30e6,null))[_0xc7759a('0x21')](handleError(_0x8e30e6,null));}; \ No newline at end of file diff --git a/server/api/squareMessage/squareMessage.model.js b/server/api/squareMessage/squareMessage.model.js index 7cefd1c..0b46043 100644 --- a/server/api/squareMessage/squareMessage.model.js +++ b/server/api/squareMessage/squareMessage.model.js @@ -1 +1 @@ -const a589_0x53d4=['SquareMessage','./squareMessage.attributes','define'];(function(_0x2b6d56,_0x53d433){const _0x5555cc=function(_0x3cc1bc){while(--_0x3cc1bc){_0x2b6d56['push'](_0x2b6d56['shift']());}};_0x5555cc(++_0x53d433);}(a589_0x53d4,0xeb));const a589_0x5555=function(_0x2b6d56,_0x53d433){_0x2b6d56=_0x2b6d56-0x0;let _0x5555cc=a589_0x53d4[_0x2b6d56];return _0x5555cc;};const _0x33780d=a589_0x5555;'use strict';const attributes=require(_0x33780d('0x0'));module['exports']=function(_0x3cc1bc){const _0x354c2e=_0x33780d,_0x87c5a9=_0x3cc1bc[_0x354c2e('0x1')](_0x354c2e('0x2'),attributes,{'tableName':'square_messages','paranoid':![],'indexes':[],'timestamps':!![]});return _0x87c5a9;}; \ No newline at end of file +const a589_0x2126=['define','SquareMessage','square_messages'];(function(_0x6d4d63,_0x21264e){const _0x2c5783=function(_0x28a61b){while(--_0x28a61b){_0x6d4d63['push'](_0x6d4d63['shift']());}};_0x2c5783(++_0x21264e);}(a589_0x2126,0x75));const a589_0x2c57=function(_0x6d4d63,_0x21264e){_0x6d4d63=_0x6d4d63-0x0;let _0x2c5783=a589_0x2126[_0x6d4d63];return _0x2c5783;};'use strict';const attributes=require('./squareMessage.attributes');module['exports']=function(_0x28a61b){const _0x4fa117=a589_0x2c57,_0x4ef77f=_0x28a61b[_0x4fa117('0x0')](_0x4fa117('0x1'),attributes,{'tableName':_0x4fa117('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x4ef77f;}; \ No newline at end of file diff --git a/server/api/squareMessage/squareMessage.rpc.js b/server/api/squareMessage/squareMessage.rpc.js index 17e16a3..b0f7af6 100644 --- a/server/api/squareMessage/squareMessage.rpc.js +++ b/server/api/squareMessage/squareMessage.rpc.js @@ -1 +1 @@ -const a590_0x24a9=['message','error','create','rpc','raw','SquareMessage','stringify','CreateSquareMessage','options','then','debug','../../config/logger','catch'];(function(_0xe0a332,_0x24a93e){const _0xbdcfd=function(_0x6fa385){while(--_0x6fa385){_0xe0a332['push'](_0xe0a332['shift']());}};_0xbdcfd(++_0x24a93e);}(a590_0x24a9,0x1df));const a590_0xbdcf=function(_0xe0a332,_0x24a93e){_0xe0a332=_0xe0a332-0x0;let _0xbdcfd=a590_0x24a9[_0xe0a332];return _0xbdcfd;};const _0x5e57e7=a590_0xbdcf;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x5e57e7('0x0'))(_0x5e57e7('0x5'));exports['CreateSquareMessage']=function(_0x6fa385){const _0x36b73a=this;return new Promise(function(_0x4200b6,_0x1d96f4){const _0x11494e=a590_0xbdcf;return db[_0x11494e('0x7')][_0x11494e('0x4')](_0x6fa385['body'],{'raw':_0x6fa385[_0x11494e('0xa')]?_0x6fa385[_0x11494e('0xa')][_0x11494e('0x6')]===undefined?!![]:![]:!![]})[_0x11494e('0xb')](function(_0x3da3db){const _0x2417eb=_0x11494e;logger['info'](_0x2417eb('0x9'),_0x6fa385),logger[_0x2417eb('0xc')](_0x2417eb('0x9'),_0x6fa385,JSON[_0x2417eb('0x8')](_0x3da3db)),_0x4200b6(_0x3da3db);})[_0x11494e('0x1')](function(_0x429f89){const _0x3a8ca1=_0x11494e;logger[_0x3a8ca1('0x3')]('CreateSquareMessage',_0x429f89[_0x3a8ca1('0x2')],_0x6fa385),_0x1d96f4(_0x36b73a[_0x3a8ca1('0x3')](0x1f4,_0x429f89['message']));});});}; \ No newline at end of file +const a590_0x2370=['body','CreateSquareMessage','catch','then','raw','../../config/logger','error','message','debug','create','options','../../mysqldb'];(function(_0x4da08f,_0x2370e4){const _0x78391c=function(_0x1ce4ed){while(--_0x1ce4ed){_0x4da08f['push'](_0x4da08f['shift']());}};_0x78391c(++_0x2370e4);}(a590_0x2370,0x1d1));const a590_0x7839=function(_0x4da08f,_0x2370e4){_0x4da08f=_0x4da08f-0x0;let _0x78391c=a590_0x2370[_0x4da08f];return _0x78391c;};const _0x916b3d=a590_0x7839;'use strict';const db=require(_0x916b3d('0x2'))['db'],logger=require(_0x916b3d('0x8'))('rpc');exports['CreateSquareMessage']=function(_0x1ce4ed){const _0x9d3c4f=this;return new Promise(function(_0x3e5924,_0xd57ac7){const _0x559714=a590_0x7839;return db['SquareMessage'][_0x559714('0x0')](_0x1ce4ed[_0x559714('0x3')],{'raw':_0x1ce4ed['options']?_0x1ce4ed[_0x559714('0x1')][_0x559714('0x7')]===undefined?!![]:![]:!![]})[_0x559714('0x6')](function(_0x32ac2d){const _0x16e18f=_0x559714;logger['info'](_0x16e18f('0x4'),_0x1ce4ed),logger[_0x16e18f('0xb')](_0x16e18f('0x4'),_0x1ce4ed,JSON['stringify'](_0x32ac2d)),_0x3e5924(_0x32ac2d);})[_0x559714('0x5')](function(_0x3a03e2){const _0x3d7e3b=_0x559714;logger[_0x3d7e3b('0x9')](_0x3d7e3b('0x4'),_0x3a03e2['message'],_0x1ce4ed),_0xd57ac7(_0x9d3c4f[_0x3d7e3b('0x9')](0x1f4,_0x3a03e2[_0x3d7e3b('0xa')]));});});}; \ No newline at end of file diff --git a/server/api/squareOdbc/index.js b/server/api/squareOdbc/index.js index b361e69..309692c 100644 --- a/server/api/squareOdbc/index.js +++ b/server/api/squareOdbc/index.js @@ -1 +1 @@ -const a591_0x179d=['express','/:id/test','update','get','./squareOdbc.controller','../../components/auth/service','test','create','connect-timeout','put','post','isAuthenticated','Router','index','delete'];(function(_0x1c4f4b,_0x179dfb){const _0x25dd9a=function(_0x554623){while(--_0x554623){_0x1c4f4b['push'](_0x1c4f4b['shift']());}};_0x25dd9a(++_0x179dfb);}(a591_0x179d,0x14d));const a591_0x25dd=function(_0x1c4f4b,_0x179dfb){_0x1c4f4b=_0x1c4f4b-0x0;let _0x25dd9a=a591_0x179d[_0x1c4f4b];return _0x25dd9a;};const _0x5b8524=a591_0x25dd;'use strict';const timeout=require(_0x5b8524('0x5')),express=require(_0x5b8524('0xc')),router=express[_0x5b8524('0x9')](),auth=require(_0x5b8524('0x2')),controller=require(_0x5b8524('0x1'));router[_0x5b8524('0x0')]('/',auth[_0x5b8524('0x8')](),controller[_0x5b8524('0xa')]),router['get']('/:id',auth[_0x5b8524('0x8')](),controller['show']),router['get'](_0x5b8524('0xd'),auth[_0x5b8524('0x8')](),timeout('15s'),controller[_0x5b8524('0x3')]),router[_0x5b8524('0x7')]('/',auth[_0x5b8524('0x8')](),controller[_0x5b8524('0x4')]),router[_0x5b8524('0x6')]('/:id',auth[_0x5b8524('0x8')](),controller[_0x5b8524('0xe')]),router[_0x5b8524('0xb')]('/:id',auth['isAuthenticated'](),controller['destroy']),module['exports']=router; \ No newline at end of file +const a591_0x4423=['test','index','/:id','post','isAuthenticated','delete','Router','./squareOdbc.controller','put','destroy','show','15s','../../components/auth/service','/:id/test','connect-timeout','get','exports','update'];(function(_0x246907,_0x4423b1){const _0x394402=function(_0x47f99e){while(--_0x47f99e){_0x246907['push'](_0x246907['shift']());}};_0x394402(++_0x4423b1);}(a591_0x4423,0x14b));const a591_0x3944=function(_0x246907,_0x4423b1){_0x246907=_0x246907-0x0;let _0x394402=a591_0x4423[_0x246907];return _0x394402;};const _0x375018=a591_0x3944;'use strict';const timeout=require(_0x375018('0x7')),express=require('express'),router=express[_0x375018('0x11')](),auth=require(_0x375018('0x5')),controller=require(_0x375018('0x0'));router[_0x375018('0x8')]('/',auth[_0x375018('0xf')](),controller[_0x375018('0xc')]),router['get'](_0x375018('0xd'),auth['isAuthenticated'](),controller[_0x375018('0x3')]),router[_0x375018('0x8')](_0x375018('0x6'),auth['isAuthenticated'](),timeout(_0x375018('0x4')),controller[_0x375018('0xb')]),router[_0x375018('0xe')]('/',auth[_0x375018('0xf')](),controller['create']),router[_0x375018('0x1')](_0x375018('0xd'),auth['isAuthenticated'](),controller[_0x375018('0xa')]),router[_0x375018('0x10')](_0x375018('0xd'),auth['isAuthenticated'](),controller[_0x375018('0x2')]),module[_0x375018('0x9')]=router; \ No newline at end of file diff --git a/server/api/squareOdbc/squareOdbc.attributes.js b/server/api/squareOdbc/squareOdbc.attributes.js index 9f6ced3..01351d4 100644 --- a/server/api/squareOdbc/squareOdbc.attributes.js +++ b/server/api/squareOdbc/squareOdbc.attributes.js @@ -1 +1 @@ -const a592_0x526e=['name','exports','sequelize','STRING'];(function(_0x37cc7f,_0x526e51){const _0x435f23=function(_0x158d60){while(--_0x158d60){_0x37cc7f['push'](_0x37cc7f['shift']());}};_0x435f23(++_0x526e51);}(a592_0x526e,0xe9));const a592_0x435f=function(_0x37cc7f,_0x526e51){_0x37cc7f=_0x37cc7f-0x0;let _0x435f23=a592_0x526e[_0x37cc7f];return _0x435f23;};const _0x29e361=a592_0x435f;'use strict';const Sequelize=require(_0x29e361('0x1'));module[_0x29e361('0x0')]={'name':{'type':Sequelize['STRING'],'unique':_0x29e361('0x3'),'allowNull':![]},'dsn':{'type':Sequelize[_0x29e361('0x2')]},'description':{'type':Sequelize[_0x29e361('0x2')]}}; \ No newline at end of file +const a592_0x6c3b=['sequelize','exports','STRING'];(function(_0x56c036,_0x6c3b57){const _0x594e8f=function(_0x3a22b8){while(--_0x3a22b8){_0x56c036['push'](_0x56c036['shift']());}};_0x594e8f(++_0x6c3b57);}(a592_0x6c3b,0x156));const a592_0x594e=function(_0x56c036,_0x6c3b57){_0x56c036=_0x56c036-0x0;let _0x594e8f=a592_0x6c3b[_0x56c036];return _0x594e8f;};const _0x2bda2a=a592_0x594e;'use strict';const Sequelize=require(_0x2bda2a('0x0'));module[_0x2bda2a('0x1')]={'name':{'type':Sequelize[_0x2bda2a('0x2')],'unique':'name','allowNull':![]},'dsn':{'type':Sequelize[_0x2bda2a('0x2')]},'description':{'type':Sequelize[_0x2bda2a('0x2')]}}; \ No newline at end of file diff --git a/server/api/squareOdbc/squareOdbc.controller.js b/server/api/squareOdbc/squareOdbc.controller.js index 02a64f7..6aeb9bb 100644 --- a/server/api/squareOdbc/squareOdbc.controller.js +++ b/server/api/squareOdbc/squareOdbc.controller.js @@ -1 +1 @@ -const a593_0x1ad7=['includeAll','update','intersection','VIRTUAL','attributes','stack','rawAttributes','api','body','nolimit','rows','name','user','destroy','keys','get','create','length','filter','findAll','params','Content-Range','like','json','include','UserProfileSection','userProfileId','key','sequelize','sendStatus','dsn','undefined','error','findOne','type','filters','query','ODBC','UserProfileResource','then','merge','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','map','end','offset','pick','model','fields','status','show','test','SquareOdbc','odbc','options','sort','limit','set','count','index','../../mysqldb','catch','where','send'];(function(_0x41605d,_0x1ad780){const _0x4c71b9=function(_0x515310){while(--_0x515310){_0x41605d['push'](_0x41605d['shift']());}};_0x4c71b9(++_0x1ad780);}(a593_0x1ad7,0x1b8));const a593_0x4c71=function(_0x41605d,_0x1ad780){_0x41605d=_0x41605d-0x0;let _0x4c71b9=a593_0x1ad7[_0x41605d];return _0x4c71b9;};const _0xceeeb6=a593_0x4c71;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0xceeeb6('0x8')),db=require(_0xceeeb6('0x3c'))['db'],{Op}=require(_0xceeeb6('0x1d'));function respondWithResult(_0x515310,_0x3f105e){return _0x3f105e=_0x3f105e||0xc8,function(_0x3f10bd){const _0x369a92=a593_0x4c71;if(_0x3f10bd)return _0x515310[_0x369a92('0x31')](_0x3f105e)[_0x369a92('0x18')](_0x3f10bd);};}function respondWithFilteredResult(_0x15b34b,_0x377ca4){return function(_0x564684){const _0x590f3f=a593_0x4c71;if(_0x564684){const _0x5e12eb=_0x564684[_0x590f3f('0x3a')],_0x5df71c=_0x377ca4[_0x590f3f('0x2d')];let _0x44b4bc=_0x377ca4[_0x590f3f('0x2d')]+_0x377ca4[_0x590f3f('0x38')],_0x14d7dd;return _0x44b4bc>=_0x5e12eb?(_0x44b4bc=_0x5e12eb,_0x14d7dd=0xc8):_0x14d7dd=0xce,_0x15b34b[_0x590f3f('0x31')](_0x14d7dd),_0x15b34b[_0x590f3f('0x39')](_0x590f3f('0x16'),_0x5df71c+'-'+_0x44b4bc+'/'+_0x5e12eb)[_0x590f3f('0x18')](_0x564684);}return null;};}function saveUpdates(_0x1c6429){return function(_0x5016fa){const _0x1acd7a=a593_0x4c71;if(_0x5016fa)return _0x5016fa[_0x1acd7a('0x2')](_0x1c6429)[_0x1acd7a('0x28')](function(_0x51c2e1){return _0x51c2e1;});return null;};}function removeEntity(_0x418ac3){return function(_0x316920){const _0x1167f3=a593_0x4c71;if(_0x316920)return _0x316920[_0x1167f3('0xe')]()[_0x1167f3('0x28')](function(){const _0x3ac646=_0x1167f3,_0x43c38d=_0x316920[_0x3ac646('0x10')]({'plain':!![]}),_0xaf6166=_0x3ac646('0x26');return db[_0x3ac646('0x27')]['destroy']({'where':{'type':_0xaf6166,'resourceId':_0x43c38d['id']}})[_0x3ac646('0x28')](function(){return _0x316920;});})['then'](function(){const _0x527aa7=_0x1167f3;_0x418ac3[_0x527aa7('0x31')](0xcc)[_0x527aa7('0x2c')]();});};}function handleEntityNotFound(_0xbf46d9){return function(_0x51724d){const _0x1655a2=a593_0x4c71;return!_0x51724d&&_0xbf46d9[_0x1655a2('0x1e')](0x194),_0x51724d;};}function handleError(_0x4d8a13,_0x10a438){return _0x10a438=_0x10a438||0x1f4,function(_0x51884e){const _0x192835=a593_0x4c71;logger['error'](_0x51884e[_0x192835('0x6')]),_0x51884e[_0x192835('0xc')]&&delete _0x51884e[_0x192835('0xc')],_0x4d8a13[_0x192835('0x31')](_0x10a438)[_0x192835('0x0')](_0x51884e);};}exports[_0xceeeb6('0x3b')]=function(_0x2f3841,_0x2b7ce4){const _0x1770d1=_0xceeeb6;let _0x2396c7={};const _0x34a8e4={},_0x18f8ad={'count':0x0,'rows':[]},_0x19324f=_[_0x1770d1('0x2b')](db[_0x1770d1('0x34')][_0x1770d1('0x7')],function(_0x16bf04){const _0x24f793=_0x1770d1;return{'name':_0x16bf04['fieldName'],'type':_0x16bf04['type'][_0x24f793('0x1c')]};});_0x34a8e4['model']=_[_0x1770d1('0x2b')](_0x19324f,_0x1770d1('0xc')),_0x34a8e4[_0x1770d1('0x25')]=_['keys'](_0x2f3841[_0x1770d1('0x25')]),_0x34a8e4['filters']=_[_0x1770d1('0x3')](_0x34a8e4['model'],_0x34a8e4[_0x1770d1('0x25')]),_0x2396c7[_0x1770d1('0x5')]=_[_0x1770d1('0x3')](_0x34a8e4['model'],qs['fields'](_0x2f3841[_0x1770d1('0x25')][_0x1770d1('0x30')])),_0x2396c7['attributes']=_0x2396c7[_0x1770d1('0x5')][_0x1770d1('0x12')]?_0x2396c7[_0x1770d1('0x5')]:_0x34a8e4[_0x1770d1('0x2f')];typeof _0x2f3841[_0x1770d1('0x25')][_0x1770d1('0xa')]===_0x1770d1('0x20')&&(_0x2396c7[_0x1770d1('0x38')]=qs[_0x1770d1('0x38')](_0x2f3841[_0x1770d1('0x25')][_0x1770d1('0x38')]),_0x2396c7[_0x1770d1('0x2d')]=qs['offset'](_0x2f3841[_0x1770d1('0x25')][_0x1770d1('0x2d')]));_0x2396c7['order']=qs[_0x1770d1('0x37')](_0x2f3841['query'][_0x1770d1('0x37')]),_0x2396c7['where']=qs[_0x1770d1('0x24')](_[_0x1770d1('0x2e')](_0x2f3841[_0x1770d1('0x25')],_0x34a8e4[_0x1770d1('0x24')]),_0x19324f);_0x2f3841[_0x1770d1('0x25')][_0x1770d1('0x13')]&&(_0x2396c7[_0x1770d1('0x3e')]=_[_0x1770d1('0x29')](_0x2396c7['where'],{[Op['or']]:_[_0x1770d1('0x2b')](_0x19324f,function(_0x49ee6a){const _0x42b08=_0x1770d1;if(_0x49ee6a[_0x42b08('0x23')]!==_0x42b08('0x4')){const _0x3e102d={};return _0x3e102d[_0x49ee6a[_0x42b08('0xc')]]={[Op[_0x42b08('0x17')]]:'%'+_0x2f3841[_0x42b08('0x25')][_0x42b08('0x13')]+'%'},_0x3e102d;}})}));_0x2396c7=_[_0x1770d1('0x29')]({},_0x2396c7,_0x2f3841[_0x1770d1('0x36')]);const _0x4e658c={'where':_0x2396c7['where']};return db['SquareOdbc'][_0x1770d1('0x3a')](_0x4e658c)[_0x1770d1('0x28')](function(_0x44fffd){const _0x25e8c6=_0x1770d1;return _0x18f8ad[_0x25e8c6('0x3a')]=_0x44fffd,_0x2f3841[_0x25e8c6('0x25')][_0x25e8c6('0x1')]&&(_0x2396c7[_0x25e8c6('0x19')]=[{'all':!![]}]),db['SquareOdbc'][_0x25e8c6('0x14')](_0x2396c7);})[_0x1770d1('0x28')](function(_0xa36a5c){const _0x5af0b9=_0x1770d1;return _0x18f8ad[_0x5af0b9('0xb')]=_0xa36a5c,_0x18f8ad;})[_0x1770d1('0x28')](respondWithFilteredResult(_0x2b7ce4,_0x2396c7))[_0x1770d1('0x3d')](handleError(_0x2b7ce4,null));},exports[_0xceeeb6('0x32')]=function(_0x349b91,_0x3bdc71){const _0x1fe0dc=_0xceeeb6;let _0x2b040f={'raw':!![],'where':{'id':_0x349b91[_0x1fe0dc('0x15')]['id']}};const _0xb1c391={};return _0xb1c391[_0x1fe0dc('0x2f')]=_[_0x1fe0dc('0xf')](db[_0x1fe0dc('0x34')][_0x1fe0dc('0x7')]),_0xb1c391[_0x1fe0dc('0x25')]=_[_0x1fe0dc('0xf')](_0x349b91[_0x1fe0dc('0x25')]),_0xb1c391[_0x1fe0dc('0x24')]=_[_0x1fe0dc('0x3')](_0xb1c391[_0x1fe0dc('0x2f')],_0xb1c391[_0x1fe0dc('0x25')]),_0x2b040f[_0x1fe0dc('0x5')]=_['intersection'](_0xb1c391[_0x1fe0dc('0x2f')],qs['fields'](_0x349b91[_0x1fe0dc('0x25')][_0x1fe0dc('0x30')])),_0x2b040f[_0x1fe0dc('0x5')]=_0x2b040f[_0x1fe0dc('0x5')][_0x1fe0dc('0x12')]?_0x2b040f[_0x1fe0dc('0x5')]:_0xb1c391['model'],_0x349b91['query'][_0x1fe0dc('0x1')]&&(_0x2b040f[_0x1fe0dc('0x19')]=[{'all':!![]}]),_0x2b040f=_[_0x1fe0dc('0x29')]({},_0x2b040f,_0x349b91[_0x1fe0dc('0x36')]),db[_0x1fe0dc('0x34')][_0x1fe0dc('0x22')](_0x2b040f)[_0x1fe0dc('0x28')](handleEntityNotFound(_0x3bdc71,null))['then'](respondWithResult(_0x3bdc71,null))['catch'](handleError(_0x3bdc71,null));},exports[_0xceeeb6('0x11')]=function(_0x292a01,_0x5415c5){const _0x44c755=_0xceeeb6;return db[_0x44c755('0x34')][_0x44c755('0x11')](_0x292a01[_0x44c755('0x9')],{})[_0x44c755('0x28')](function(_0x2200b1){const _0x348a5e=_0x44c755,_0x2b2633=_0x292a01['user'][_0x348a5e('0x10')]({'plain':!![]});if(!_0x2b2633)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x2b2633['role']===_0x348a5e('0xd')){const _0x4f1090=_0x2200b1[_0x348a5e('0x10')]({'plain':!![]}),_0x288d74=_0x348a5e('0x26');return db[_0x348a5e('0x1a')][_0x348a5e('0x22')]({'where':{'name':_0x288d74,'userProfileId':_0x2b2633[_0x348a5e('0x1b')]},'raw':!![]})[_0x348a5e('0x28')](function(_0x2b65db){const _0x470446=_0x348a5e;return _0x2b65db&&_0x2b65db['autoAssociation']===0x0?db[_0x470446('0x27')]['create']({'name':_0x4f1090[_0x470446('0xc')],'resourceId':_0x4f1090['id'],'type':_0x2b65db[_0x470446('0xc')],'sectionId':_0x2b65db['id']},{})[_0x470446('0x28')](function(){return _0x2200b1;}):_0x2200b1;})[_0x348a5e('0x3d')](function(_0x5b42f0){const _0x186d6e=_0x348a5e;logger[_0x186d6e('0x21')](_0x186d6e('0x2a'),_0x5b42f0);throw _0x5b42f0;});}return _0x2200b1;})[_0x44c755('0x28')](respondWithResult(_0x5415c5,0xc9))[_0x44c755('0x3d')](handleError(_0x5415c5,null));},exports[_0xceeeb6('0x2')]=function(_0x34501d,_0x50d73c){const _0x53e71e=_0xceeeb6;return _0x34501d['body']['id']&&delete _0x34501d[_0x53e71e('0x9')]['id'],db[_0x53e71e('0x34')][_0x53e71e('0x22')]({'where':{'id':_0x34501d[_0x53e71e('0x15')]['id']}})['then'](handleEntityNotFound(_0x50d73c,null))['then'](saveUpdates(_0x34501d[_0x53e71e('0x9')],null))[_0x53e71e('0x28')](respondWithResult(_0x50d73c,null))[_0x53e71e('0x3d')](handleError(_0x50d73c,null));},exports['destroy']=function(_0x3dd1b6,_0x2245df){const _0x3d6d31=_0xceeeb6;return db[_0x3d6d31('0x34')][_0x3d6d31('0x22')]({'where':{'id':_0x3dd1b6[_0x3d6d31('0x15')]['id']}})[_0x3d6d31('0x28')](handleEntityNotFound(_0x2245df,null))[_0x3d6d31('0x28')](removeEntity(_0x2245df,null))[_0x3d6d31('0x3d')](handleError(_0x2245df,null));},exports[_0xceeeb6('0x33')]=function(_0x557aea,_0x45b1a9){const _0x5ba249=_0xceeeb6;return db[_0x5ba249('0x34')][_0x5ba249('0x22')]({'where':{'id':_0x557aea[_0x5ba249('0x15')]['id']},'attributes':['id',_0x5ba249('0x1f')]})['then'](handleEntityNotFound(_0x45b1a9,null))[_0x5ba249('0x28')](function(_0x2861ee){const _0x50b298=_0x5ba249;if(_0x2861ee){const _0x4af467=require(_0x50b298('0x35'))();return _0x4af467['openSync'](_0x2861ee[_0x50b298('0x1f')]),_0x4af467['closeSync'](),_0x2861ee;}})[_0x5ba249('0x28')](respondWithResult(_0x45b1a9,null))[_0x5ba249('0x3d')](handleError(_0x45b1a9,null));}; \ No newline at end of file +const a593_0x50d7=['offset','create','includeAll','../../config/logger','../../components/parsers/qs','odbc','count','test','closeSync','filters','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','UserProfileResource','autoAssociation','model','error','index','include','catch','send','pick','destroy','SquareOdbc','ODBC','set','dsn','query','rawAttributes','VIRTUAL','options','rows','keys','body','json','map','findOne','limit','undefined','length','../../mysqldb','status','openSync','attributes','nolimit','order','get','where','update','sort','user','show','intersection','name','fields','end','merge','sequelize','role','findAll','then','type','params','fieldName','Content-Range'];(function(_0x5c9123,_0x50d760){const _0x160d49=function(_0x5c1f3e){while(--_0x5c1f3e){_0x5c9123['push'](_0x5c9123['shift']());}};_0x160d49(++_0x50d760);}(a593_0x50d7,0x8e));const a593_0x160d=function(_0x5c9123,_0x50d760){_0x5c9123=_0x5c9123-0x0;let _0x160d49=a593_0x50d7[_0x5c9123];return _0x160d49;};const _0x429fd1=a593_0x160d;'use strict';const _=require('lodash'),qs=require(_0x429fd1('0x33')),logger=require(_0x429fd1('0x32'))('api'),db=require(_0x429fd1('0x16'))['db'],{Op}=require(_0x429fd1('0x27'));function respondWithResult(_0x5c1f3e,_0x208c98){return _0x208c98=_0x208c98||0xc8,function(_0x480cb2){const _0x132d75=a593_0x160d;if(_0x480cb2)return _0x5c1f3e['status'](_0x208c98)[_0x132d75('0x10')](_0x480cb2);};}function respondWithFilteredResult(_0xe4ed36,_0xa2d4a6){return function(_0x2796ed){const _0x4df50d=a593_0x160d;if(_0x2796ed){const _0xa82af4=_0x2796ed[_0x4df50d('0x35')],_0x85e10e=_0xa2d4a6['offset'];let _0x3f02ca=_0xa2d4a6[_0x4df50d('0x2f')]+_0xa2d4a6[_0x4df50d('0x13')],_0x4d4c22;return _0x3f02ca>=_0xa82af4?(_0x3f02ca=_0xa82af4,_0x4d4c22=0xc8):_0x4d4c22=0xce,_0xe4ed36[_0x4df50d('0x17')](_0x4d4c22),_0xe4ed36[_0x4df50d('0x7')](_0x4df50d('0x2e'),_0x85e10e+'-'+_0x3f02ca+'/'+_0xa82af4)[_0x4df50d('0x10')](_0x2796ed);}return null;};}function saveUpdates(_0x3d04f5){return function(_0x571e37){const _0x570d2f=a593_0x160d;if(_0x571e37)return _0x571e37[_0x570d2f('0x1e')](_0x3d04f5)['then'](function(_0x3a24a9){return _0x3a24a9;});return null;};}function removeEntity(_0x4fed83){return function(_0x45daa6){const _0x4ad65d=a593_0x160d;if(_0x45daa6)return _0x45daa6[_0x4ad65d('0x4')]()['then'](function(){const _0x517d34=_0x4ad65d,_0x25dcea=_0x45daa6[_0x517d34('0x1c')]({'plain':!![]}),_0x263548=_0x517d34('0x6');return db[_0x517d34('0x3a')][_0x517d34('0x4')]({'where':{'type':_0x263548,'resourceId':_0x25dcea['id']}})['then'](function(){return _0x45daa6;});})[_0x4ad65d('0x2a')](function(){const _0x127403=_0x4ad65d;_0x4fed83[_0x127403('0x17')](0xcc)[_0x127403('0x25')]();});};}function handleEntityNotFound(_0x3e161a){return function(_0x2d8c31){return!_0x2d8c31&&_0x3e161a['sendStatus'](0x194),_0x2d8c31;};}function handleError(_0x4b2c23,_0x38eff2){return _0x38eff2=_0x38eff2||0x1f4,function(_0x4df524){const _0xd00a06=a593_0x160d;logger[_0xd00a06('0x3d')](_0x4df524['stack']),_0x4df524[_0xd00a06('0x23')]&&delete _0x4df524[_0xd00a06('0x23')],_0x4b2c23['status'](_0x38eff2)[_0xd00a06('0x2')](_0x4df524);};}exports[_0x429fd1('0x3e')]=function(_0x37a7ec,_0x4828df){const _0x4dad0e=_0x429fd1;let _0x469499={};const _0x161053={},_0x5df95e={'count':0x0,'rows':[]},_0x4e6142=_['map'](db[_0x4dad0e('0x5')][_0x4dad0e('0xa')],function(_0x4040e1){const _0x403529=_0x4dad0e;return{'name':_0x4040e1[_0x403529('0x2d')],'type':_0x4040e1['type']['key']};});_0x161053[_0x4dad0e('0x3c')]=_['map'](_0x4e6142,_0x4dad0e('0x23')),_0x161053['query']=_['keys'](_0x37a7ec[_0x4dad0e('0x9')]),_0x161053[_0x4dad0e('0x38')]=_[_0x4dad0e('0x22')](_0x161053[_0x4dad0e('0x3c')],_0x161053[_0x4dad0e('0x9')]),_0x469499[_0x4dad0e('0x19')]=_[_0x4dad0e('0x22')](_0x161053[_0x4dad0e('0x3c')],qs[_0x4dad0e('0x24')](_0x37a7ec['query'][_0x4dad0e('0x24')])),_0x469499[_0x4dad0e('0x19')]=_0x469499[_0x4dad0e('0x19')][_0x4dad0e('0x15')]?_0x469499[_0x4dad0e('0x19')]:_0x161053[_0x4dad0e('0x3c')];typeof _0x37a7ec['query'][_0x4dad0e('0x1a')]===_0x4dad0e('0x14')&&(_0x469499[_0x4dad0e('0x13')]=qs[_0x4dad0e('0x13')](_0x37a7ec[_0x4dad0e('0x9')][_0x4dad0e('0x13')]),_0x469499[_0x4dad0e('0x2f')]=qs['offset'](_0x37a7ec[_0x4dad0e('0x9')][_0x4dad0e('0x2f')]));_0x469499[_0x4dad0e('0x1b')]=qs[_0x4dad0e('0x1f')](_0x37a7ec[_0x4dad0e('0x9')][_0x4dad0e('0x1f')]),_0x469499[_0x4dad0e('0x1d')]=qs[_0x4dad0e('0x38')](_[_0x4dad0e('0x3')](_0x37a7ec[_0x4dad0e('0x9')],_0x161053[_0x4dad0e('0x38')]),_0x4e6142);_0x37a7ec['query']['filter']&&(_0x469499[_0x4dad0e('0x1d')]=_[_0x4dad0e('0x26')](_0x469499[_0x4dad0e('0x1d')],{[Op['or']]:_[_0x4dad0e('0x11')](_0x4e6142,function(_0x2f8771){const _0x4b25ba=_0x4dad0e;if(_0x2f8771[_0x4b25ba('0x2b')]!==_0x4b25ba('0xb')){const _0x5c13df={};return _0x5c13df[_0x2f8771[_0x4b25ba('0x23')]]={[Op['like']]:'%'+_0x37a7ec[_0x4b25ba('0x9')]['filter']+'%'},_0x5c13df;}})}));_0x469499=_[_0x4dad0e('0x26')]({},_0x469499,_0x37a7ec[_0x4dad0e('0xc')]);const _0x19af38={'where':_0x469499['where']};return db['SquareOdbc'][_0x4dad0e('0x35')](_0x19af38)[_0x4dad0e('0x2a')](function(_0xd8819f){const _0xf26eec=_0x4dad0e;return _0x5df95e[_0xf26eec('0x35')]=_0xd8819f,_0x37a7ec['query'][_0xf26eec('0x31')]&&(_0x469499[_0xf26eec('0x0')]=[{'all':!![]}]),db[_0xf26eec('0x5')][_0xf26eec('0x29')](_0x469499);})[_0x4dad0e('0x2a')](function(_0x43db5c){const _0x14ddc9=_0x4dad0e;return _0x5df95e[_0x14ddc9('0xd')]=_0x43db5c,_0x5df95e;})[_0x4dad0e('0x2a')](respondWithFilteredResult(_0x4828df,_0x469499))[_0x4dad0e('0x1')](handleError(_0x4828df,null));},exports[_0x429fd1('0x21')]=function(_0x24583f,_0x4ada3d){const _0x3bfb36=_0x429fd1;let _0x19ee1b={'raw':!![],'where':{'id':_0x24583f['params']['id']}};const _0x20666d={};return _0x20666d[_0x3bfb36('0x3c')]=_[_0x3bfb36('0xe')](db[_0x3bfb36('0x5')][_0x3bfb36('0xa')]),_0x20666d['query']=_[_0x3bfb36('0xe')](_0x24583f[_0x3bfb36('0x9')]),_0x20666d[_0x3bfb36('0x38')]=_[_0x3bfb36('0x22')](_0x20666d[_0x3bfb36('0x3c')],_0x20666d[_0x3bfb36('0x9')]),_0x19ee1b['attributes']=_[_0x3bfb36('0x22')](_0x20666d[_0x3bfb36('0x3c')],qs[_0x3bfb36('0x24')](_0x24583f['query']['fields'])),_0x19ee1b[_0x3bfb36('0x19')]=_0x19ee1b[_0x3bfb36('0x19')]['length']?_0x19ee1b[_0x3bfb36('0x19')]:_0x20666d[_0x3bfb36('0x3c')],_0x24583f[_0x3bfb36('0x9')]['includeAll']&&(_0x19ee1b[_0x3bfb36('0x0')]=[{'all':!![]}]),_0x19ee1b=_[_0x3bfb36('0x26')]({},_0x19ee1b,_0x24583f[_0x3bfb36('0xc')]),db['SquareOdbc'][_0x3bfb36('0x12')](_0x19ee1b)['then'](handleEntityNotFound(_0x4ada3d,null))[_0x3bfb36('0x2a')](respondWithResult(_0x4ada3d,null))[_0x3bfb36('0x1')](handleError(_0x4ada3d,null));},exports['create']=function(_0x3c68f0,_0xf801c7){const _0x2484e6=_0x429fd1;return db[_0x2484e6('0x5')][_0x2484e6('0x30')](_0x3c68f0[_0x2484e6('0xf')],{})[_0x2484e6('0x2a')](function(_0x3a5728){const _0x2c078f=_0x2484e6,_0x1e69cc=_0x3c68f0[_0x2c078f('0x20')]['get']({'plain':!![]});if(!_0x1e69cc)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x1e69cc[_0x2c078f('0x28')]===_0x2c078f('0x20')){const _0x362af9=_0x3a5728['get']({'plain':!![]}),_0x4cb93c=_0x2c078f('0x6');return db['UserProfileSection'][_0x2c078f('0x12')]({'where':{'name':_0x4cb93c,'userProfileId':_0x1e69cc['userProfileId']},'raw':!![]})[_0x2c078f('0x2a')](function(_0x23b279){const _0x3ca6a2=_0x2c078f;return _0x23b279&&_0x23b279[_0x3ca6a2('0x3b')]===0x0?db['UserProfileResource'][_0x3ca6a2('0x30')]({'name':_0x362af9[_0x3ca6a2('0x23')],'resourceId':_0x362af9['id'],'type':_0x23b279[_0x3ca6a2('0x23')],'sectionId':_0x23b279['id']},{})[_0x3ca6a2('0x2a')](function(){return _0x3a5728;}):_0x3a5728;})[_0x2c078f('0x1')](function(_0x14ef36){const _0x4a9313=_0x2c078f;logger['error'](_0x4a9313('0x39'),_0x14ef36);throw _0x14ef36;});}return _0x3a5728;})['then'](respondWithResult(_0xf801c7,0xc9))[_0x2484e6('0x1')](handleError(_0xf801c7,null));},exports[_0x429fd1('0x1e')]=function(_0x1ce869,_0x519067){const _0x921d3d=_0x429fd1;return _0x1ce869[_0x921d3d('0xf')]['id']&&delete _0x1ce869['body']['id'],db[_0x921d3d('0x5')]['findOne']({'where':{'id':_0x1ce869[_0x921d3d('0x2c')]['id']}})[_0x921d3d('0x2a')](handleEntityNotFound(_0x519067,null))[_0x921d3d('0x2a')](saveUpdates(_0x1ce869[_0x921d3d('0xf')],null))[_0x921d3d('0x2a')](respondWithResult(_0x519067,null))[_0x921d3d('0x1')](handleError(_0x519067,null));},exports[_0x429fd1('0x4')]=function(_0x3d1894,_0x4b8ca1){const _0x1f61a9=_0x429fd1;return db['SquareOdbc'][_0x1f61a9('0x12')]({'where':{'id':_0x3d1894[_0x1f61a9('0x2c')]['id']}})[_0x1f61a9('0x2a')](handleEntityNotFound(_0x4b8ca1,null))[_0x1f61a9('0x2a')](removeEntity(_0x4b8ca1,null))[_0x1f61a9('0x1')](handleError(_0x4b8ca1,null));},exports[_0x429fd1('0x36')]=function(_0x46e5f1,_0x567977){const _0x2531a9=_0x429fd1;return db['SquareOdbc']['findOne']({'where':{'id':_0x46e5f1[_0x2531a9('0x2c')]['id']},'attributes':['id',_0x2531a9('0x8')]})[_0x2531a9('0x2a')](handleEntityNotFound(_0x567977,null))[_0x2531a9('0x2a')](function(_0x2baabd){const _0x34329d=_0x2531a9;if(_0x2baabd){const _0x2ed2bd=require(_0x34329d('0x34'))();return _0x2ed2bd[_0x34329d('0x18')](_0x2baabd['dsn']),_0x2ed2bd[_0x34329d('0x37')](),_0x2baabd;}})[_0x2531a9('0x2a')](respondWithResult(_0x567977,null))[_0x2531a9('0x1')](handleError(_0x567977,null));}; \ No newline at end of file diff --git a/server/api/squareOdbc/squareOdbc.model.js b/server/api/squareOdbc/squareOdbc.model.js index f4f40d1..4cab82e 100644 --- a/server/api/squareOdbc/squareOdbc.model.js +++ b/server/api/squareOdbc/squareOdbc.model.js @@ -1 +1 @@ -const a594_0xdbbf=['exports','SquareOdbc','define','./squareOdbc.attributes'];(function(_0x2e40d4,_0xdbbf02){const _0x287ad8=function(_0x139cb2){while(--_0x139cb2){_0x2e40d4['push'](_0x2e40d4['shift']());}};_0x287ad8(++_0xdbbf02);}(a594_0xdbbf,0x1db));const a594_0x287a=function(_0x2e40d4,_0xdbbf02){_0x2e40d4=_0x2e40d4-0x0;let _0x287ad8=a594_0xdbbf[_0x2e40d4];return _0x287ad8;};const _0x7d094b=a594_0x287a;'use strict';const attributes=require(_0x7d094b('0x0'));module[_0x7d094b('0x1')]=function(_0x139cb2){const _0x403426=_0x7d094b,_0xb44c83=_0x139cb2[_0x403426('0x3')](_0x403426('0x2'),attributes,{'tableName':'square_odbc','paranoid':![],'indexes':[],'timestamps':!![]});return _0xb44c83;}; \ No newline at end of file +const a594_0x2047=['exports','./squareOdbc.attributes','square_odbc'];(function(_0x471cf8,_0x2047f5){const _0x10b365=function(_0xe6030d){while(--_0xe6030d){_0x471cf8['push'](_0x471cf8['shift']());}};_0x10b365(++_0x2047f5);}(a594_0x2047,0xaf));const a594_0x10b3=function(_0x471cf8,_0x2047f5){_0x471cf8=_0x471cf8-0x0;let _0x10b365=a594_0x2047[_0x471cf8];return _0x10b365;};const _0x59b2ee=a594_0x10b3;'use strict';const attributes=require(_0x59b2ee('0x0'));module[_0x59b2ee('0x2')]=function(_0xe6030d){const _0x34f80a=_0x59b2ee,_0x5ef50f=_0xe6030d['define']('SquareOdbc',attributes,{'tableName':_0x34f80a('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5ef50f;}; \ No newline at end of file diff --git a/server/api/squareOdbc/squareOdbc.rpc.js b/server/api/squareOdbc/squareOdbc.rpc.js index 9e78117..8d5b5b2 100644 --- a/server/api/squareOdbc/squareOdbc.rpc.js +++ b/server/api/squareOdbc/squareOdbc.rpc.js @@ -1 +1 @@ -const a595_0x46ce=['include','model','catch','stringify','raw','info','then','map','error','../../config/logger','ShowSquareOdbc','attributes','options','message','findOne','where','../../mysqldb','lodash','SquareOdbc'];(function(_0x105524,_0x46ce38){const _0x50c043=function(_0x1bd114){while(--_0x1bd114){_0x105524['push'](_0x105524['shift']());}};_0x50c043(++_0x46ce38);}(a595_0x46ce,0x1c4));const a595_0x50c0=function(_0x105524,_0x46ce38){_0x105524=_0x105524-0x0;let _0x50c043=a595_0x46ce[_0x105524];return _0x50c043;};const _0x1ad00d=a595_0x50c0;'use strict';const db=require(_0x1ad00d('0x1'))['db'],logger=require(_0x1ad00d('0xd'))('rpc'),_=require(_0x1ad00d('0x2'));exports[_0x1ad00d('0xe')]=function(_0x1bd114){const _0x362e05=this;return new Promise(function(_0xa9110c,_0x24738f){const _0x50a579=a595_0x50c0;return db[_0x50a579('0x3')][_0x50a579('0x12')]({'raw':_0x1bd114[_0x50a579('0x10')]?_0x1bd114[_0x50a579('0x10')][_0x50a579('0x8')]===undefined?!![]:![]:!![],'where':_0x1bd114[_0x50a579('0x10')]?_0x1bd114[_0x50a579('0x10')][_0x50a579('0x0')]||null:null,'attributes':_0x1bd114[_0x50a579('0x10')]?_0x1bd114['options'][_0x50a579('0xf')]||null:null,'include':_0x1bd114[_0x50a579('0x10')]?_0x1bd114[_0x50a579('0x10')][_0x50a579('0x4')]?_[_0x50a579('0xb')](_0x1bd114['options'][_0x50a579('0x4')],function(_0x35e885){const _0x559b66=_0x50a579;return{'model':db[_0x35e885[_0x559b66('0x5')]],'as':_0x35e885['as'],'attributes':_0x35e885[_0x559b66('0xf')],'include':_0x35e885[_0x559b66('0x4')]?_[_0x559b66('0xb')](_0x35e885[_0x559b66('0x4')],function(_0x1e9b95){const _0x3cfc75=_0x559b66;return{'model':db[_0x1e9b95[_0x3cfc75('0x5')]],'as':_0x1e9b95['as'],'attributes':_0x1e9b95['attributes'],'include':_0x1e9b95[_0x3cfc75('0x4')]?_[_0x3cfc75('0xb')](_0x1e9b95['include'],function(_0x51e454){return{'model':db[_0x51e454['model']],'as':_0x51e454['as'],'attributes':_0x51e454['attributes']};}):[]};}):[]};}):[]:[]})[_0x50a579('0xa')](function(_0x4f2130){const _0x3b717f=_0x50a579;logger[_0x3b717f('0x9')]('ShowSquareOdbc',_0x1bd114),logger['debug'](_0x3b717f('0xe'),_0x1bd114,JSON[_0x3b717f('0x7')](_0x4f2130)),_0xa9110c(_0x4f2130);})[_0x50a579('0x6')](function(_0x127303){const _0x15ca26=_0x50a579;logger[_0x15ca26('0xc')](_0x15ca26('0xe'),_0x127303['message'],_0x1bd114),_0x24738f(_0x362e05[_0x15ca26('0xc')](0x1f4,_0x127303[_0x15ca26('0x11')]));});});}; \ No newline at end of file +const a595_0x3a56=['../../mysqldb','lodash','message','attributes','model','where','options','ShowSquareOdbc','error','stringify','rpc','map','include','SquareOdbc','findOne','../../config/logger','raw'];(function(_0x37669b,_0x3a5623){const _0x1a1c36=function(_0x33ac52){while(--_0x33ac52){_0x37669b['push'](_0x37669b['shift']());}};_0x1a1c36(++_0x3a5623);}(a595_0x3a56,0x17e));const a595_0x1a1c=function(_0x37669b,_0x3a5623){_0x37669b=_0x37669b-0x0;let _0x1a1c36=a595_0x3a56[_0x37669b];return _0x1a1c36;};const _0x10d992=a595_0x1a1c;'use strict';const db=require(_0x10d992('0x9'))['db'],logger=require(_0x10d992('0x7'))(_0x10d992('0x2')),_=require(_0x10d992('0xa'));exports[_0x10d992('0x10')]=function(_0x33ac52){const _0x238ed2=this;return new Promise(function(_0x1941c9,_0x19ea41){const _0x163a0c=a595_0x1a1c;return db[_0x163a0c('0x5')][_0x163a0c('0x6')]({'raw':_0x33ac52[_0x163a0c('0xf')]?_0x33ac52[_0x163a0c('0xf')][_0x163a0c('0x8')]===undefined?!![]:![]:!![],'where':_0x33ac52[_0x163a0c('0xf')]?_0x33ac52[_0x163a0c('0xf')][_0x163a0c('0xe')]||null:null,'attributes':_0x33ac52[_0x163a0c('0xf')]?_0x33ac52[_0x163a0c('0xf')][_0x163a0c('0xc')]||null:null,'include':_0x33ac52['options']?_0x33ac52[_0x163a0c('0xf')][_0x163a0c('0x4')]?_[_0x163a0c('0x3')](_0x33ac52[_0x163a0c('0xf')]['include'],function(_0x3c8137){const _0x436ceb=_0x163a0c;return{'model':db[_0x3c8137[_0x436ceb('0xd')]],'as':_0x3c8137['as'],'attributes':_0x3c8137[_0x436ceb('0xc')],'include':_0x3c8137['include']?_[_0x436ceb('0x3')](_0x3c8137[_0x436ceb('0x4')],function(_0x420901){const _0x27da1f=_0x436ceb;return{'model':db[_0x420901[_0x27da1f('0xd')]],'as':_0x420901['as'],'attributes':_0x420901[_0x27da1f('0xc')],'include':_0x420901[_0x27da1f('0x4')]?_[_0x27da1f('0x3')](_0x420901[_0x27da1f('0x4')],function(_0x15e0b9){const _0x33c391=_0x27da1f;return{'model':db[_0x15e0b9[_0x33c391('0xd')]],'as':_0x15e0b9['as'],'attributes':_0x15e0b9[_0x33c391('0xc')]};}):[]};}):[]};}):[]:[]})['then'](function(_0xabbd49){const _0xe6a5f=_0x163a0c;logger['info'](_0xe6a5f('0x10'),_0x33ac52),logger['debug']('ShowSquareOdbc',_0x33ac52,JSON[_0xe6a5f('0x1')](_0xabbd49)),_0x1941c9(_0xabbd49);})['catch'](function(_0x160888){const _0x5d2eb5=_0x163a0c;logger['error']('ShowSquareOdbc',_0x160888['message'],_0x33ac52),_0x19ea41(_0x238ed2[_0x5d2eb5('0x0')](0x1f4,_0x160888[_0x5d2eb5('0xb')]));});});}; \ No newline at end of file diff --git a/server/api/squareProject/index.js b/server/api/squareProject/index.js index 7e672cb..509fd14 100644 --- a/server/api/squareProject/index.js +++ b/server/api/squareProject/index.js @@ -1 +1 @@ -const a596_0x21fb=['isAuthenticated','../../components/auth/service','put','getUsers','post','/:id/users','addUsers','create','destroy','removeUsers','express','get','/:id','delete','Router','index','exports'];(function(_0x8b937b,_0x21fbf8){const _0x2bf594=function(_0x1e606f){while(--_0x1e606f){_0x8b937b['push'](_0x8b937b['shift']());}};_0x2bf594(++_0x21fbf8);}(a596_0x21fb,0x14e));const a596_0x2bf5=function(_0x8b937b,_0x21fbf8){_0x8b937b=_0x8b937b-0x0;let _0x2bf594=a596_0x21fb[_0x8b937b];return _0x2bf594;};const _0x3289f4=a596_0x2bf5;'use strict';const express=require(_0x3289f4('0x10')),router=express[_0x3289f4('0x3')](),auth=require(_0x3289f4('0x7')),controller=require('./squareProject.controller');router['get']('/',auth[_0x3289f4('0x6')](),controller[_0x3289f4('0x4')]),router['get'](_0x3289f4('0x1'),auth[_0x3289f4('0x6')](),controller['show']),router[_0x3289f4('0x0')](_0x3289f4('0xb'),auth['isAuthenticated'](),controller[_0x3289f4('0x9')]),router[_0x3289f4('0xa')]('/',auth[_0x3289f4('0x6')](),controller[_0x3289f4('0xd')]),router[_0x3289f4('0xa')](_0x3289f4('0xb'),auth[_0x3289f4('0x6')](),controller[_0x3289f4('0xc')]),router[_0x3289f4('0x8')]('/:id',auth[_0x3289f4('0x6')](),controller['update']),router[_0x3289f4('0x2')](_0x3289f4('0x1'),auth[_0x3289f4('0x6')](),controller[_0x3289f4('0xe')]),router[_0x3289f4('0x2')]('/:id/users',auth[_0x3289f4('0x6')](),controller[_0x3289f4('0xf')]),module[_0x3289f4('0x5')]=router; \ No newline at end of file +const a596_0x3639=['get','getUsers','put','delete','addUsers','show','post','destroy','isAuthenticated','../../components/auth/service','create','/:id/users','/:id','update','./squareProject.controller','Router','express'];(function(_0x53b19c,_0x36393e){const _0x423886=function(_0x24a272){while(--_0x24a272){_0x53b19c['push'](_0x53b19c['shift']());}};_0x423886(++_0x36393e);}(a596_0x3639,0xa1));const a596_0x4238=function(_0x53b19c,_0x36393e){_0x53b19c=_0x53b19c-0x0;let _0x423886=a596_0x3639[_0x53b19c];return _0x423886;};const _0x14aa8f=a596_0x4238;'use strict';const express=require(_0x14aa8f('0x8')),router=express[_0x14aa8f('0x7')](),auth=require(_0x14aa8f('0x1')),controller=require(_0x14aa8f('0x6'));router[_0x14aa8f('0x9')]('/',auth[_0x14aa8f('0x0')](),controller['index']),router[_0x14aa8f('0x9')](_0x14aa8f('0x4'),auth['isAuthenticated'](),controller[_0x14aa8f('0xe')]),router[_0x14aa8f('0x9')](_0x14aa8f('0x3'),auth[_0x14aa8f('0x0')](),controller[_0x14aa8f('0xa')]),router[_0x14aa8f('0xf')]('/',auth['isAuthenticated'](),controller[_0x14aa8f('0x2')]),router[_0x14aa8f('0xf')](_0x14aa8f('0x3'),auth[_0x14aa8f('0x0')](),controller[_0x14aa8f('0xd')]),router[_0x14aa8f('0xb')](_0x14aa8f('0x4'),auth[_0x14aa8f('0x0')](),controller[_0x14aa8f('0x5')]),router[_0x14aa8f('0xc')](_0x14aa8f('0x4'),auth['isAuthenticated'](),controller[_0x14aa8f('0x10')]),router['delete'](_0x14aa8f('0x3'),auth[_0x14aa8f('0x0')](),controller['removeUsers']),module['exports']=router; \ No newline at end of file diff --git a/server/api/squareProject/squareProject.attributes.js b/server/api/squareProject/squareProject.attributes.js index d84314b..846d2a8 100644 --- a/server/api/squareProject/squareProject.attributes.js +++ b/server/api/squareProject/squareProject.attributes.js @@ -1 +1 @@ -const a597_0x3b87=['toString','name','production','getDataValue','exports','preproduction','BLOB','TEXT','STRING','long','utf8'];(function(_0x4a16e4,_0x3b8774){const _0x4991ea=function(_0x4b3424){while(--_0x4b3424){_0x4a16e4['push'](_0x4a16e4['shift']());}};_0x4991ea(++_0x3b8774);}(a597_0x3b87,0x6e));const a597_0x4991=function(_0x4a16e4,_0x3b8774){_0x4a16e4=_0x4a16e4-0x0;let _0x4991ea=a597_0x3b87[_0x4a16e4];return _0x4991ea;};const _0xa3d892=a597_0x4991;'use strict';const Sequelize=require('sequelize');module[_0xa3d892('0x4')]={'name':{'type':Sequelize[_0xa3d892('0x8')],'unique':_0xa3d892('0x1'),'allowNull':![]},'description':{'type':Sequelize['STRING']},'notes':{'type':Sequelize[_0xa3d892('0x7')]},'preproduction':{'type':Sequelize[_0xa3d892('0x6')](_0xa3d892('0x9')),'get':function(){const _0x43d5b1=_0xa3d892;if(this[_0x43d5b1('0x3')](_0x43d5b1('0x5')))return this['getDataValue'](_0x43d5b1('0x5'))['toString'](_0x43d5b1('0xa'));}},'production':{'type':Sequelize[_0xa3d892('0x6')](_0xa3d892('0x9')),'get':function(){const _0x49f151=_0xa3d892;if(this[_0x49f151('0x3')]('production'))return this[_0x49f151('0x3')](_0x49f151('0x2'))[_0x49f151('0x0')](_0x49f151('0xa'));}}}; \ No newline at end of file +const a597_0x4ed7=['TEXT','utf8','BLOB','production','preproduction','toString','sequelize','long','exports','STRING','getDataValue','name'];(function(_0x57d40d,_0x4ed7c1){const _0x61c0a7=function(_0x10727c){while(--_0x10727c){_0x57d40d['push'](_0x57d40d['shift']());}};_0x61c0a7(++_0x4ed7c1);}(a597_0x4ed7,0x1a7));const a597_0x61c0=function(_0x57d40d,_0x4ed7c1){_0x57d40d=_0x57d40d-0x0;let _0x61c0a7=a597_0x4ed7[_0x57d40d];return _0x61c0a7;};const _0x51e307=a597_0x61c0;'use strict';const Sequelize=require(_0x51e307('0x3'));module[_0x51e307('0x5')]={'name':{'type':Sequelize[_0x51e307('0x6')],'unique':_0x51e307('0x8'),'allowNull':![]},'description':{'type':Sequelize[_0x51e307('0x6')]},'notes':{'type':Sequelize[_0x51e307('0x9')]},'preproduction':{'type':Sequelize[_0x51e307('0xb')](_0x51e307('0x4')),'get':function(){const _0x208b1c=_0x51e307;if(this[_0x208b1c('0x7')]('preproduction'))return this[_0x208b1c('0x7')](_0x208b1c('0x1'))[_0x208b1c('0x2')]('utf8');}},'production':{'type':Sequelize['BLOB'](_0x51e307('0x4')),'get':function(){const _0x5d3ef6=_0x51e307;if(this[_0x5d3ef6('0x7')]('production'))return this['getDataValue'](_0x5d3ef6('0x0'))['toString'](_0x5d3ef6('0xa'));}}}; \ No newline at end of file diff --git a/server/api/squareProject/squareProject.controller.js b/server/api/squareProject/squareProject.controller.js index 2e65a17..439cdf6 100644 --- a/server/api/squareProject/squareProject.controller.js +++ b/server/api/squareProject/squareProject.controller.js @@ -1 +1 @@ -const a598_0x3d90=['findOne','stack','include','catch','Content-Range','rawAttributes','count','undefined','intersection','../../components/parsers/qs','User','key','pick','options','lodash','userSquareProject:remove','autoAssociation','register','merge','sendStatus','nolimit','VIRTUAL','show','type','emit','map','error','rows','like','ids','length','filter','get','SquareProjects','api','limit','omit','attributes','user','end','name','sort','../../rediscache','isArray','removeUsers','role','UserProfileResource','addUsers','update','json','../../config/logger','fields','body','then','destroy','params','create','status','Unable\x20to\x20retrieve\x20the\x20current\x20user','findAll','SquareProject','model','order','where','includeAll','userProfileId','./squareProject.socket','query','keys','set','filters','getUsers','offset'];(function(_0x559141,_0x3d90fb){const _0x4dacac=function(_0x46ff2d){while(--_0x46ff2d){_0x559141['push'](_0x559141['shift']());}};_0x4dacac(++_0x3d90fb);}(a598_0x3d90,0xe7));const a598_0x4dac=function(_0x559141,_0x3d90fb){_0x559141=_0x559141-0x0;let _0x4dacac=a598_0x3d90[_0x559141];return _0x4dacac;};const _0x153a89=a598_0x4dac;'use strict';const _=require(_0x153a89('0x2')),qs=require(_0x153a89('0x46')),logger=require(_0x153a89('0x26'))(_0x153a89('0x16')),{getSocket}=require(_0x153a89('0x1e')),socket=getSocket(),db=require('../../mysqldb')['db'],{Op}=require('sequelize');require(_0x153a89('0x36'))[_0x153a89('0x5')](socket);function respondWithStatusCode(_0x46ff2d,_0x25c0ba){return _0x25c0ba=_0x25c0ba||0xcc,function(_0x588ab6){const _0x10aecc=a598_0x4dac;if(_0x588ab6)return _0x46ff2d[_0x10aecc('0x7')](_0x25c0ba);return _0x46ff2d[_0x10aecc('0x2d')](_0x25c0ba)[_0x10aecc('0x1b')]();};}function respondWithResult(_0x5d2d25,_0x11530e){return _0x11530e=_0x11530e||0xc8,function(_0x2b70b8){if(_0x2b70b8)return _0x5d2d25['status'](_0x11530e)['json'](_0x2b70b8);};}function respondWithFilteredResult(_0x5a8927,_0x542759){return function(_0x27b836){const _0x2d85af=a598_0x4dac;if(_0x27b836){const _0x163562=_0x27b836['count'],_0x292905=_0x542759[_0x2d85af('0x3c')];let _0x31b448=_0x542759[_0x2d85af('0x3c')]+_0x542759['limit'],_0x771188;return _0x31b448>=_0x163562?(_0x31b448=_0x163562,_0x771188=0xc8):_0x771188=0xce,_0x5a8927[_0x2d85af('0x2d')](_0x771188),_0x5a8927[_0x2d85af('0x39')](_0x2d85af('0x41'),_0x292905+'-'+_0x31b448+'/'+_0x163562)[_0x2d85af('0x25')](_0x27b836);}return null;};}function saveUpdates(_0x904fed){return function(_0x3770ff){const _0x266ee9=a598_0x4dac;if(_0x3770ff)return _0x3770ff[_0x266ee9('0x24')](_0x904fed)[_0x266ee9('0x29')](function(_0x5643ea){return _0x5643ea;});return null;};}function removeEntity(_0x5bd23e){return function(_0x287b34){const _0x1cc3a3=a598_0x4dac;if(_0x287b34)return _0x287b34[_0x1cc3a3('0x2a')]()[_0x1cc3a3('0x29')](function(){const _0x5a6174=_0x1cc3a3,_0x26708d=_0x287b34[_0x5a6174('0x14')]({'plain':!![]}),_0xc828a9=_0x5a6174('0x15');return db[_0x5a6174('0x22')][_0x5a6174('0x2a')]({'where':{'type':_0xc828a9,'resourceId':_0x26708d['id']}})[_0x5a6174('0x29')](function(){return _0x287b34;});})[_0x1cc3a3('0x29')](function(){const _0x31855a=_0x1cc3a3;_0x5bd23e[_0x31855a('0x2d')](0xcc)[_0x31855a('0x1b')]();});};}function handleEntityNotFound(_0x2930d6){return function(_0x29d89b){return!_0x29d89b&&_0x2930d6['sendStatus'](0x194),_0x29d89b;};}function handleError(_0x21ecc8,_0x354102){return _0x354102=_0x354102||0x1f4,function(_0x584642){const _0x384d7b=a598_0x4dac;logger[_0x384d7b('0xe')](_0x584642[_0x384d7b('0x3e')]),_0x584642[_0x384d7b('0x1c')]&&delete _0x584642[_0x384d7b('0x1c')],_0x21ecc8[_0x384d7b('0x2d')](_0x354102)['send'](_0x584642);};}exports['index']=function(_0x5d78de,_0x435313){const _0x1882b5=_0x153a89;let _0x3e0cf9={};const _0x55f731={},_0x4e07ff={'count':0x0,'rows':[]},_0x21e220=_['map'](db[_0x1882b5('0x30')][_0x1882b5('0x42')],function(_0x1052f4){const _0x537464=_0x1882b5;return{'name':_0x1052f4['fieldName'],'type':_0x1052f4[_0x537464('0xb')][_0x537464('0x48')]};});_0x55f731[_0x1882b5('0x31')]=_[_0x1882b5('0xd')](_0x21e220,'name'),_0x55f731['query']=_[_0x1882b5('0x38')](_0x5d78de[_0x1882b5('0x37')]),_0x55f731[_0x1882b5('0x3a')]=_[_0x1882b5('0x45')](_0x55f731[_0x1882b5('0x31')],_0x55f731['query']),_0x3e0cf9[_0x1882b5('0x19')]=_[_0x1882b5('0x45')](_0x55f731[_0x1882b5('0x31')],qs[_0x1882b5('0x27')](_0x5d78de[_0x1882b5('0x37')][_0x1882b5('0x27')])),_0x3e0cf9[_0x1882b5('0x19')]=_0x3e0cf9[_0x1882b5('0x19')][_0x1882b5('0x12')]?_0x3e0cf9[_0x1882b5('0x19')]:_0x55f731[_0x1882b5('0x31')];typeof _0x5d78de['query'][_0x1882b5('0x8')]===_0x1882b5('0x44')&&(_0x3e0cf9[_0x1882b5('0x17')]=qs[_0x1882b5('0x17')](_0x5d78de[_0x1882b5('0x37')][_0x1882b5('0x17')]),_0x3e0cf9[_0x1882b5('0x3c')]=qs['offset'](_0x5d78de[_0x1882b5('0x37')][_0x1882b5('0x3c')]));_0x3e0cf9[_0x1882b5('0x32')]=qs[_0x1882b5('0x1d')](_0x5d78de[_0x1882b5('0x37')][_0x1882b5('0x1d')]),_0x3e0cf9[_0x1882b5('0x33')]=qs[_0x1882b5('0x3a')](_[_0x1882b5('0x0')](_0x5d78de[_0x1882b5('0x37')],_0x55f731['filters']),_0x21e220);_0x5d78de['query']['filter']&&(_0x3e0cf9['where']=_[_0x1882b5('0x6')](_0x3e0cf9['where'],{[Op['or']]:_[_0x1882b5('0xd')](_0x21e220,function(_0x42938a){const _0xbf842f=_0x1882b5;if(_0x42938a[_0xbf842f('0xb')]!==_0xbf842f('0x9')){const _0x3a1e4e={};return _0x3a1e4e[_0x42938a['name']]={[Op[_0xbf842f('0x10')]]:'%'+_0x5d78de[_0xbf842f('0x37')][_0xbf842f('0x13')]+'%'},_0x3a1e4e;}})}));_0x3e0cf9=_[_0x1882b5('0x6')]({},_0x3e0cf9,_0x5d78de[_0x1882b5('0x1')]);const _0x5e2781={'where':_0x3e0cf9[_0x1882b5('0x33')]};return db['SquareProject'][_0x1882b5('0x43')](_0x5e2781)[_0x1882b5('0x29')](function(_0x533be6){const _0x56b107=_0x1882b5;return _0x4e07ff['count']=_0x533be6,_0x5d78de[_0x56b107('0x37')][_0x56b107('0x34')]&&(_0x3e0cf9[_0x56b107('0x3f')]=[{'all':!![]}]),db[_0x56b107('0x30')][_0x56b107('0x2f')](_0x3e0cf9);})[_0x1882b5('0x29')](function(_0x5cf291){const _0x154627=_0x1882b5;return _0x4e07ff[_0x154627('0xf')]=_0x5cf291,_0x4e07ff;})[_0x1882b5('0x29')](respondWithFilteredResult(_0x435313,_0x3e0cf9))['catch'](handleError(_0x435313,null));},exports[_0x153a89('0xa')]=function(_0x37c53f,_0x1e9361){const _0x2b99dc=_0x153a89;let _0x5729db={'raw':![],'where':{'id':_0x37c53f[_0x2b99dc('0x2b')]['id']}};const _0x270952={};return _0x270952[_0x2b99dc('0x31')]=_[_0x2b99dc('0x38')](db[_0x2b99dc('0x30')][_0x2b99dc('0x42')]),_0x270952[_0x2b99dc('0x37')]=_[_0x2b99dc('0x38')](_0x37c53f[_0x2b99dc('0x37')]),_0x270952[_0x2b99dc('0x3a')]=_[_0x2b99dc('0x45')](_0x270952['model'],_0x270952['query']),_0x5729db[_0x2b99dc('0x19')]=_['intersection'](_0x270952[_0x2b99dc('0x31')],qs[_0x2b99dc('0x27')](_0x37c53f[_0x2b99dc('0x37')][_0x2b99dc('0x27')])),_0x5729db['attributes']=_0x5729db[_0x2b99dc('0x19')][_0x2b99dc('0x12')]?_0x5729db[_0x2b99dc('0x19')]:_0x270952[_0x2b99dc('0x31')],_0x37c53f[_0x2b99dc('0x37')]['includeAll']&&(_0x5729db[_0x2b99dc('0x3f')]=[{'all':!![]}]),_0x5729db=_[_0x2b99dc('0x6')]({},_0x5729db,_0x37c53f['options']),db[_0x2b99dc('0x30')][_0x2b99dc('0x3d')](_0x5729db)[_0x2b99dc('0x29')](handleEntityNotFound(_0x1e9361,null))['then'](respondWithResult(_0x1e9361,null))['catch'](handleError(_0x1e9361,null));},exports[_0x153a89('0x2c')]=function(_0x54a6b5,_0xedad84){const _0x4de467=_0x153a89;return db['SquareProject'][_0x4de467('0x2c')](_0x54a6b5[_0x4de467('0x28')],{})['then'](function(_0x1b6c5b){const _0x52dfdc=_0x4de467,_0x3042fa=_0x54a6b5[_0x52dfdc('0x1a')][_0x52dfdc('0x14')]({'plain':!![]});if(!_0x3042fa)throw new Error(_0x52dfdc('0x2e'));if(_0x3042fa[_0x52dfdc('0x21')]===_0x52dfdc('0x1a')){const _0x3444c6=_0x1b6c5b[_0x52dfdc('0x14')]({'plain':!![]}),_0xe48380=_0x52dfdc('0x15');return db['UserProfileSection'][_0x52dfdc('0x3d')]({'where':{'name':_0xe48380,'userProfileId':_0x3042fa[_0x52dfdc('0x35')]},'raw':!![]})[_0x52dfdc('0x29')](function(_0x2ec54c){const _0x438e00=_0x52dfdc;return _0x2ec54c&&_0x2ec54c[_0x438e00('0x4')]===0x0?db['UserProfileResource'][_0x438e00('0x2c')]({'name':_0x3444c6[_0x438e00('0x1c')],'resourceId':_0x3444c6['id'],'type':_0x2ec54c[_0x438e00('0x1c')],'sectionId':_0x2ec54c['id']},{})['then'](function(){return _0x1b6c5b;}):_0x1b6c5b;})[_0x52dfdc('0x40')](function(_0x4875fc){const _0x19fe8d=_0x52dfdc;logger[_0x19fe8d('0xe')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x4875fc);throw _0x4875fc;});}return _0x1b6c5b;})['then'](respondWithResult(_0xedad84,0xc9))[_0x4de467('0x40')](handleError(_0xedad84,null));},exports['update']=function(_0x3c175b,_0x467674){const _0x29d962=_0x153a89;return _0x3c175b[_0x29d962('0x28')]['id']&&delete _0x3c175b[_0x29d962('0x28')]['id'],db[_0x29d962('0x30')][_0x29d962('0x3d')]({'where':{'id':_0x3c175b['params']['id']}})[_0x29d962('0x29')](handleEntityNotFound(_0x467674,null))['then'](saveUpdates(_0x3c175b['body'],null))[_0x29d962('0x29')](respondWithResult(_0x467674,null))[_0x29d962('0x40')](handleError(_0x467674,null));},exports['destroy']=function(_0x14f368,_0x2049e9){const _0x30a437=_0x153a89;return db[_0x30a437('0x30')][_0x30a437('0x3d')]({'where':{'id':_0x14f368[_0x30a437('0x2b')]['id']}})['then'](handleEntityNotFound(_0x2049e9,null))['then'](removeEntity(_0x2049e9,null))[_0x30a437('0x40')](handleError(_0x2049e9,null));},exports[_0x153a89('0x23')]=function(_0x3cf106,_0x2929dd){const _0x233218=_0x153a89;return db[_0x233218('0x30')]['findOne']({'where':{'id':_0x3cf106[_0x233218('0x2b')]['id']}})[_0x233218('0x29')](function(_0x1bd21b){const _0x377476=_0x233218;if(_0x1bd21b)return _0x1bd21b['addUsers'](_0x3cf106[_0x377476('0x28')][_0x377476('0x11')],{'through':_[_0x377476('0x18')](_0x3cf106[_0x377476('0x28')],[_0x377476('0x11'),'id'])});})['then'](respondWithResult(_0x2929dd,null))[_0x233218('0x40')](handleError(_0x2929dd,null));},exports[_0x153a89('0x20')]=function(_0x58cfc0,_0x308e72){const _0x46f10a=_0x153a89;return db['SquareProject'][_0x46f10a('0x3d')]({'where':{'id':_0x58cfc0['params']['id']}})[_0x46f10a('0x29')](handleEntityNotFound(_0x308e72,null))[_0x46f10a('0x29')](function(_0x804552){const _0x2c884e=_0x46f10a;if(_0x804552)return _0x804552[_0x2c884e('0x20')](_0x58cfc0[_0x2c884e('0x37')][_0x2c884e('0x11')])[_0x2c884e('0x29')](function(){const _0x22afa0=_0x2c884e;if(_[_0x22afa0('0x1f')](_0x58cfc0[_0x22afa0('0x37')][_0x22afa0('0x11')]))for(let _0x2a871d=0x0;_0x2a871d<_0x58cfc0['query'][_0x22afa0('0x11')]['length'];_0x2a871d+=0x1){socket['emit'](_0x22afa0('0x3'),{'UserId':Number(_0x58cfc0[_0x22afa0('0x37')][_0x22afa0('0x11')][_0x2a871d]),'SquareProjectId':Number(_0x58cfc0[_0x22afa0('0x2b')]['id'])});}else socket[_0x22afa0('0xc')](_0x22afa0('0x3'),{'UserId':Number(_0x58cfc0[_0x22afa0('0x37')]['ids']),'SquareProjectId':Number(_0x58cfc0[_0x22afa0('0x2b')]['id'])});});})[_0x46f10a('0x29')](respondWithStatusCode(_0x308e72,null))[_0x46f10a('0x40')](handleError(_0x308e72,null));},exports[_0x153a89('0x3b')]=function(_0x153600,_0x32bfa4){const _0x15145a=_0x153a89;let _0x344b25={};const _0x4d77f1={};let _0x336234,_0x4bf21a;return db['SquareProject'][_0x15145a('0x3d')]({'where':{'id':_0x153600[_0x15145a('0x2b')]['id']}})['then'](handleEntityNotFound(_0x32bfa4,null))[_0x15145a('0x29')](function(_0x31996d){const _0xe4bf70=_0x15145a;if(_0x31996d)return _0x336234=_0x31996d,_0x4d77f1['model']=_[_0xe4bf70('0x38')](db[_0xe4bf70('0x47')][_0xe4bf70('0x42')]),_0x4d77f1[_0xe4bf70('0x37')]=_[_0xe4bf70('0x38')](_0x153600[_0xe4bf70('0x37')]),_0x4d77f1['filters']=_['intersection'](_0x4d77f1[_0xe4bf70('0x31')],_0x4d77f1['query']),_0x344b25['attributes']=_[_0xe4bf70('0x45')](_0x4d77f1[_0xe4bf70('0x31')],qs[_0xe4bf70('0x27')](_0x153600['query'][_0xe4bf70('0x27')])),_0x344b25['attributes']=_0x344b25[_0xe4bf70('0x19')][_0xe4bf70('0x12')]?_0x344b25[_0xe4bf70('0x19')]:_0x4d77f1[_0xe4bf70('0x31')],_0x344b25[_0xe4bf70('0x32')]=qs[_0xe4bf70('0x1d')](_0x153600[_0xe4bf70('0x37')][_0xe4bf70('0x1d')]),_0x344b25[_0xe4bf70('0x33')]=qs[_0xe4bf70('0x3a')](_['pick'](_0x153600[_0xe4bf70('0x37')],_0x4d77f1[_0xe4bf70('0x3a')])),_0x153600['query'][_0xe4bf70('0x13')]&&(_0x344b25[_0xe4bf70('0x33')]=_[_0xe4bf70('0x6')](_0x344b25['where'],{[Op['or']]:_[_0xe4bf70('0xd')](_0x344b25[_0xe4bf70('0x19')],function(_0x4bb7e9){const _0x27bfc6=_0xe4bf70,_0x549b84={};return _0x549b84[_0x4bb7e9]={[Op[_0x27bfc6('0x10')]]:'%'+_0x153600[_0x27bfc6('0x37')][_0x27bfc6('0x13')]+'%'},_0x549b84;})})),_0x344b25=_[_0xe4bf70('0x6')]({},_0x344b25,_0x153600[_0xe4bf70('0x1')]),_0x336234['getUsers'](_0x344b25);})[_0x15145a('0x29')](function(_0x19b1a7){const _0x5a071e=_0x15145a;if(_0x19b1a7)return _0x4bf21a=_0x19b1a7[_0x5a071e('0x12')],typeof _0x153600[_0x5a071e('0x37')][_0x5a071e('0x8')]===_0x5a071e('0x44')&&(_0x344b25[_0x5a071e('0x17')]=qs[_0x5a071e('0x17')](_0x153600[_0x5a071e('0x37')][_0x5a071e('0x17')]),_0x344b25[_0x5a071e('0x3c')]=qs[_0x5a071e('0x3c')](_0x153600[_0x5a071e('0x37')]['offset'])),_0x336234[_0x5a071e('0x3b')](_0x344b25);})['then'](function(_0x19ed87){if(_0x19ed87)return _0x19ed87?{'count':_0x4bf21a,'rows':_0x19ed87}:null;})[_0x15145a('0x29')](respondWithResult(_0x32bfa4,null))['catch'](handleError(_0x32bfa4,null));}; \ No newline at end of file +const a598_0x1352=['UserProfileResource','SquareProjects','error','findOne','body','where','sort','UserProfileSection','order','pick','catch','../../mysqldb','filters','query','fields','include','rawAttributes','./squareProject.socket','intersection','offset','omit','emit','length','show','undefined','includeAll','set','map','count','json','params','end','model','SquareProject','like','options','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','keys','then','status','create','../../config/logger','merge','autoAssociation','Unable\x20to\x20retrieve\x20the\x20current\x20user','removeUsers','rows','../../rediscache','attributes','index','register','filter','addUsers','getUsers','limit','ids','role','lodash','isArray','user','destroy','update','type','get','key','sendStatus','name'];(function(_0x317c13,_0x135247){const _0x24c751=function(_0x833664){while(--_0x833664){_0x317c13['push'](_0x317c13['shift']());}};_0x24c751(++_0x135247);}(a598_0x1352,0x64));const a598_0x24c7=function(_0x317c13,_0x135247){_0x317c13=_0x317c13-0x0;let _0x24c751=a598_0x1352[_0x317c13];return _0x24c751;};const _0xe6eef=a598_0x24c7;'use strict';const _=require(_0xe6eef('0x18')),qs=require('../../components/parsers/qs'),logger=require(_0xe6eef('0x8'))('api'),{getSocket}=require(_0xe6eef('0xe')),socket=getSocket(),db=require(_0xe6eef('0x2d'))['db'],{Op}=require('sequelize');require(_0xe6eef('0x33'))[_0xe6eef('0x11')](socket);function respondWithStatusCode(_0x833664,_0x43557f){return _0x43557f=_0x43557f||0xcc,function(_0x487e2f){const _0x3b6bc6=a598_0x24c7;if(_0x487e2f)return _0x833664[_0x3b6bc6('0x20')](_0x43557f);return _0x833664[_0x3b6bc6('0x6')](_0x43557f)[_0x3b6bc6('0x41')]();};}function respondWithResult(_0x363b5c,_0x502e01){return _0x502e01=_0x502e01||0xc8,function(_0xd8201c){const _0xe292c6=a598_0x24c7;if(_0xd8201c)return _0x363b5c[_0xe292c6('0x6')](_0x502e01)[_0xe292c6('0x3f')](_0xd8201c);};}function respondWithFilteredResult(_0xe9b84a,_0x149522){return function(_0x4249b6){const _0x124dd6=a598_0x24c7;if(_0x4249b6){const _0x3359b3=_0x4249b6[_0x124dd6('0x3e')],_0x495a5d=_0x149522[_0x124dd6('0x35')];let _0x5096c4=_0x149522['offset']+_0x149522[_0x124dd6('0x15')],_0x3c8a24;return _0x5096c4>=_0x3359b3?(_0x5096c4=_0x3359b3,_0x3c8a24=0xc8):_0x3c8a24=0xce,_0xe9b84a[_0x124dd6('0x6')](_0x3c8a24),_0xe9b84a[_0x124dd6('0x3c')]('Content-Range',_0x495a5d+'-'+_0x5096c4+'/'+_0x3359b3)['json'](_0x4249b6);}return null;};}function saveUpdates(_0x2a6dfc){return function(_0x26c307){const _0x1c8dcb=a598_0x24c7;if(_0x26c307)return _0x26c307[_0x1c8dcb('0x1c')](_0x2a6dfc)[_0x1c8dcb('0x5')](function(_0x2491ea){return _0x2491ea;});return null;};}function removeEntity(_0x5429e6){return function(_0x3dafd0){const _0x31f4d2=a598_0x24c7;if(_0x3dafd0)return _0x3dafd0[_0x31f4d2('0x1b')]()['then'](function(){const _0x2e8124=_0x31f4d2,_0x19be33=_0x3dafd0['get']({'plain':!![]}),_0x3d6467=_0x2e8124('0x23');return db[_0x2e8124('0x22')][_0x2e8124('0x1b')]({'where':{'type':_0x3d6467,'resourceId':_0x19be33['id']}})[_0x2e8124('0x5')](function(){return _0x3dafd0;});})[_0x31f4d2('0x5')](function(){_0x5429e6['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x2ba569){return function(_0x1ac4b1){const _0x361d16=a598_0x24c7;return!_0x1ac4b1&&_0x2ba569[_0x361d16('0x20')](0x194),_0x1ac4b1;};}function handleError(_0x4c76b3,_0x5c893d){return _0x5c893d=_0x5c893d||0x1f4,function(_0x2a44b0){const _0x51c955=a598_0x24c7;logger[_0x51c955('0x24')](_0x2a44b0['stack']),_0x2a44b0[_0x51c955('0x21')]&&delete _0x2a44b0[_0x51c955('0x21')],_0x4c76b3[_0x51c955('0x6')](_0x5c893d)['send'](_0x2a44b0);};}exports[_0xe6eef('0x10')]=function(_0x455db2,_0x825c77){const _0x45f37a=_0xe6eef;let _0x3b146e={};const _0x37224d={},_0x13ea37={'count':0x0,'rows':[]},_0x1fd4e2=_[_0x45f37a('0x3d')](db[_0x45f37a('0x0')][_0x45f37a('0x32')],function(_0x13001c){const _0x28fce8=_0x45f37a;return{'name':_0x13001c['fieldName'],'type':_0x13001c[_0x28fce8('0x1d')][_0x28fce8('0x1f')]};});_0x37224d['model']=_[_0x45f37a('0x3d')](_0x1fd4e2,'name'),_0x37224d[_0x45f37a('0x2f')]=_[_0x45f37a('0x4')](_0x455db2[_0x45f37a('0x2f')]),_0x37224d[_0x45f37a('0x2e')]=_['intersection'](_0x37224d[_0x45f37a('0x42')],_0x37224d[_0x45f37a('0x2f')]),_0x3b146e[_0x45f37a('0xf')]=_[_0x45f37a('0x34')](_0x37224d[_0x45f37a('0x42')],qs['fields'](_0x455db2['query'][_0x45f37a('0x30')])),_0x3b146e[_0x45f37a('0xf')]=_0x3b146e['attributes'][_0x45f37a('0x38')]?_0x3b146e[_0x45f37a('0xf')]:_0x37224d[_0x45f37a('0x42')];typeof _0x455db2[_0x45f37a('0x2f')]['nolimit']===_0x45f37a('0x3a')&&(_0x3b146e[_0x45f37a('0x15')]=qs['limit'](_0x455db2[_0x45f37a('0x2f')]['limit']),_0x3b146e['offset']=qs[_0x45f37a('0x35')](_0x455db2['query'][_0x45f37a('0x35')]));_0x3b146e[_0x45f37a('0x2a')]=qs[_0x45f37a('0x28')](_0x455db2[_0x45f37a('0x2f')][_0x45f37a('0x28')]),_0x3b146e[_0x45f37a('0x27')]=qs[_0x45f37a('0x2e')](_[_0x45f37a('0x2b')](_0x455db2[_0x45f37a('0x2f')],_0x37224d[_0x45f37a('0x2e')]),_0x1fd4e2);_0x455db2[_0x45f37a('0x2f')]['filter']&&(_0x3b146e[_0x45f37a('0x27')]=_[_0x45f37a('0x9')](_0x3b146e[_0x45f37a('0x27')],{[Op['or']]:_[_0x45f37a('0x3d')](_0x1fd4e2,function(_0x503cf9){const _0x3f1d11=_0x45f37a;if(_0x503cf9[_0x3f1d11('0x1d')]!=='VIRTUAL'){const _0x4e1338={};return _0x4e1338[_0x503cf9[_0x3f1d11('0x21')]]={[Op[_0x3f1d11('0x1')]]:'%'+_0x455db2['query'][_0x3f1d11('0x12')]+'%'},_0x4e1338;}})}));_0x3b146e=_[_0x45f37a('0x9')]({},_0x3b146e,_0x455db2['options']);const _0x435ded={'where':_0x3b146e[_0x45f37a('0x27')]};return db[_0x45f37a('0x0')][_0x45f37a('0x3e')](_0x435ded)[_0x45f37a('0x5')](function(_0x30e3a4){const _0x30dca4=_0x45f37a;return _0x13ea37[_0x30dca4('0x3e')]=_0x30e3a4,_0x455db2[_0x30dca4('0x2f')][_0x30dca4('0x3b')]&&(_0x3b146e['include']=[{'all':!![]}]),db[_0x30dca4('0x0')]['findAll'](_0x3b146e);})['then'](function(_0x5d496e){const _0x135b9a=_0x45f37a;return _0x13ea37[_0x135b9a('0xd')]=_0x5d496e,_0x13ea37;})[_0x45f37a('0x5')](respondWithFilteredResult(_0x825c77,_0x3b146e))[_0x45f37a('0x2c')](handleError(_0x825c77,null));},exports[_0xe6eef('0x39')]=function(_0x367bb0,_0x3ec52b){const _0x37a9f3=_0xe6eef;let _0x21f388={'raw':![],'where':{'id':_0x367bb0[_0x37a9f3('0x40')]['id']}};const _0x422bec={};return _0x422bec['model']=_['keys'](db[_0x37a9f3('0x0')][_0x37a9f3('0x32')]),_0x422bec['query']=_[_0x37a9f3('0x4')](_0x367bb0[_0x37a9f3('0x2f')]),_0x422bec[_0x37a9f3('0x2e')]=_[_0x37a9f3('0x34')](_0x422bec[_0x37a9f3('0x42')],_0x422bec['query']),_0x21f388[_0x37a9f3('0xf')]=_['intersection'](_0x422bec[_0x37a9f3('0x42')],qs[_0x37a9f3('0x30')](_0x367bb0['query'][_0x37a9f3('0x30')])),_0x21f388['attributes']=_0x21f388['attributes']['length']?_0x21f388[_0x37a9f3('0xf')]:_0x422bec[_0x37a9f3('0x42')],_0x367bb0['query'][_0x37a9f3('0x3b')]&&(_0x21f388[_0x37a9f3('0x31')]=[{'all':!![]}]),_0x21f388=_['merge']({},_0x21f388,_0x367bb0[_0x37a9f3('0x2')]),db[_0x37a9f3('0x0')][_0x37a9f3('0x25')](_0x21f388)[_0x37a9f3('0x5')](handleEntityNotFound(_0x3ec52b,null))[_0x37a9f3('0x5')](respondWithResult(_0x3ec52b,null))['catch'](handleError(_0x3ec52b,null));},exports[_0xe6eef('0x7')]=function(_0x1b0326,_0x52d59a){const _0x5ad39e=_0xe6eef;return db[_0x5ad39e('0x0')]['create'](_0x1b0326['body'],{})[_0x5ad39e('0x5')](function(_0x2d733a){const _0x229608=_0x5ad39e,_0x31ceaf=_0x1b0326['user'][_0x229608('0x1e')]({'plain':!![]});if(!_0x31ceaf)throw new Error(_0x229608('0xb'));if(_0x31ceaf[_0x229608('0x17')]===_0x229608('0x1a')){const _0x57a6dd=_0x2d733a[_0x229608('0x1e')]({'plain':!![]}),_0x310f34=_0x229608('0x23');return db[_0x229608('0x29')][_0x229608('0x25')]({'where':{'name':_0x310f34,'userProfileId':_0x31ceaf['userProfileId']},'raw':!![]})[_0x229608('0x5')](function(_0x3d7c1a){const _0x351bc3=_0x229608;return _0x3d7c1a&&_0x3d7c1a[_0x351bc3('0xa')]===0x0?db['UserProfileResource'][_0x351bc3('0x7')]({'name':_0x57a6dd['name'],'resourceId':_0x57a6dd['id'],'type':_0x3d7c1a[_0x351bc3('0x21')],'sectionId':_0x3d7c1a['id']},{})['then'](function(){return _0x2d733a;}):_0x2d733a;})[_0x229608('0x2c')](function(_0x28bf96){const _0x28b0e8=_0x229608;logger[_0x28b0e8('0x24')](_0x28b0e8('0x3'),_0x28bf96);throw _0x28bf96;});}return _0x2d733a;})[_0x5ad39e('0x5')](respondWithResult(_0x52d59a,0xc9))[_0x5ad39e('0x2c')](handleError(_0x52d59a,null));},exports[_0xe6eef('0x1c')]=function(_0x39557a,_0x1949a9){const _0x5291ef=_0xe6eef;return _0x39557a['body']['id']&&delete _0x39557a[_0x5291ef('0x26')]['id'],db['SquareProject'][_0x5291ef('0x25')]({'where':{'id':_0x39557a[_0x5291ef('0x40')]['id']}})['then'](handleEntityNotFound(_0x1949a9,null))[_0x5291ef('0x5')](saveUpdates(_0x39557a[_0x5291ef('0x26')],null))[_0x5291ef('0x5')](respondWithResult(_0x1949a9,null))[_0x5291ef('0x2c')](handleError(_0x1949a9,null));},exports[_0xe6eef('0x1b')]=function(_0x5cc61d,_0x387623){const _0x3380f8=_0xe6eef;return db[_0x3380f8('0x0')][_0x3380f8('0x25')]({'where':{'id':_0x5cc61d[_0x3380f8('0x40')]['id']}})['then'](handleEntityNotFound(_0x387623,null))[_0x3380f8('0x5')](removeEntity(_0x387623,null))[_0x3380f8('0x2c')](handleError(_0x387623,null));},exports[_0xe6eef('0x13')]=function(_0x199cdc,_0x20453c){const _0x1be7d2=_0xe6eef;return db['SquareProject'][_0x1be7d2('0x25')]({'where':{'id':_0x199cdc[_0x1be7d2('0x40')]['id']}})[_0x1be7d2('0x5')](function(_0x1f9fba){const _0x21b072=_0x1be7d2;if(_0x1f9fba)return _0x1f9fba[_0x21b072('0x13')](_0x199cdc[_0x21b072('0x26')][_0x21b072('0x16')],{'through':_[_0x21b072('0x36')](_0x199cdc['body'],[_0x21b072('0x16'),'id'])});})[_0x1be7d2('0x5')](respondWithResult(_0x20453c,null))[_0x1be7d2('0x2c')](handleError(_0x20453c,null));},exports[_0xe6eef('0xc')]=function(_0x197444,_0x38ecab){const _0x26ccff=_0xe6eef;return db[_0x26ccff('0x0')][_0x26ccff('0x25')]({'where':{'id':_0x197444[_0x26ccff('0x40')]['id']}})['then'](handleEntityNotFound(_0x38ecab,null))[_0x26ccff('0x5')](function(_0x5b5b51){const _0xeb3fb8=_0x26ccff;if(_0x5b5b51)return _0x5b5b51[_0xeb3fb8('0xc')](_0x197444[_0xeb3fb8('0x2f')]['ids'])[_0xeb3fb8('0x5')](function(){const _0x53e344=_0xeb3fb8;if(_[_0x53e344('0x19')](_0x197444[_0x53e344('0x2f')][_0x53e344('0x16')]))for(let _0x2ac4cb=0x0;_0x2ac4cb<_0x197444['query'][_0x53e344('0x16')][_0x53e344('0x38')];_0x2ac4cb+=0x1){socket[_0x53e344('0x37')]('userSquareProject:remove',{'UserId':Number(_0x197444[_0x53e344('0x2f')][_0x53e344('0x16')][_0x2ac4cb]),'SquareProjectId':Number(_0x197444[_0x53e344('0x40')]['id'])});}else socket['emit']('userSquareProject:remove',{'UserId':Number(_0x197444[_0x53e344('0x2f')][_0x53e344('0x16')]),'SquareProjectId':Number(_0x197444[_0x53e344('0x40')]['id'])});});})[_0x26ccff('0x5')](respondWithStatusCode(_0x38ecab,null))[_0x26ccff('0x2c')](handleError(_0x38ecab,null));},exports[_0xe6eef('0x14')]=function(_0x4c4d92,_0x5326ba){const _0x4757b9=_0xe6eef;let _0x3fdc3c={};const _0x2c06fa={};let _0x1b01a3,_0x4e0636;return db[_0x4757b9('0x0')][_0x4757b9('0x25')]({'where':{'id':_0x4c4d92[_0x4757b9('0x40')]['id']}})['then'](handleEntityNotFound(_0x5326ba,null))[_0x4757b9('0x5')](function(_0x33a1a3){const _0x502cea=_0x4757b9;if(_0x33a1a3)return _0x1b01a3=_0x33a1a3,_0x2c06fa[_0x502cea('0x42')]=_[_0x502cea('0x4')](db['User'][_0x502cea('0x32')]),_0x2c06fa[_0x502cea('0x2f')]=_[_0x502cea('0x4')](_0x4c4d92[_0x502cea('0x2f')]),_0x2c06fa[_0x502cea('0x2e')]=_[_0x502cea('0x34')](_0x2c06fa[_0x502cea('0x42')],_0x2c06fa[_0x502cea('0x2f')]),_0x3fdc3c[_0x502cea('0xf')]=_[_0x502cea('0x34')](_0x2c06fa[_0x502cea('0x42')],qs[_0x502cea('0x30')](_0x4c4d92[_0x502cea('0x2f')][_0x502cea('0x30')])),_0x3fdc3c[_0x502cea('0xf')]=_0x3fdc3c[_0x502cea('0xf')][_0x502cea('0x38')]?_0x3fdc3c[_0x502cea('0xf')]:_0x2c06fa['model'],_0x3fdc3c[_0x502cea('0x2a')]=qs[_0x502cea('0x28')](_0x4c4d92[_0x502cea('0x2f')][_0x502cea('0x28')]),_0x3fdc3c[_0x502cea('0x27')]=qs[_0x502cea('0x2e')](_['pick'](_0x4c4d92[_0x502cea('0x2f')],_0x2c06fa[_0x502cea('0x2e')])),_0x4c4d92['query'][_0x502cea('0x12')]&&(_0x3fdc3c['where']=_[_0x502cea('0x9')](_0x3fdc3c['where'],{[Op['or']]:_[_0x502cea('0x3d')](_0x3fdc3c[_0x502cea('0xf')],function(_0x4b1a0c){const _0x847c15=_0x502cea,_0x343503={};return _0x343503[_0x4b1a0c]={[Op[_0x847c15('0x1')]]:'%'+_0x4c4d92[_0x847c15('0x2f')][_0x847c15('0x12')]+'%'},_0x343503;})})),_0x3fdc3c=_[_0x502cea('0x9')]({},_0x3fdc3c,_0x4c4d92[_0x502cea('0x2')]),_0x1b01a3['getUsers'](_0x3fdc3c);})[_0x4757b9('0x5')](function(_0x40b3d9){const _0xbc7be5=_0x4757b9;if(_0x40b3d9)return _0x4e0636=_0x40b3d9[_0xbc7be5('0x38')],typeof _0x4c4d92[_0xbc7be5('0x2f')]['nolimit']===_0xbc7be5('0x3a')&&(_0x3fdc3c[_0xbc7be5('0x15')]=qs[_0xbc7be5('0x15')](_0x4c4d92[_0xbc7be5('0x2f')]['limit']),_0x3fdc3c[_0xbc7be5('0x35')]=qs['offset'](_0x4c4d92[_0xbc7be5('0x2f')][_0xbc7be5('0x35')])),_0x1b01a3[_0xbc7be5('0x14')](_0x3fdc3c);})[_0x4757b9('0x5')](function(_0x39b054){if(_0x39b054)return _0x39b054?{'count':_0x4e0636,'rows':_0x39b054}:null;})[_0x4757b9('0x5')](respondWithResult(_0x5326ba,null))[_0x4757b9('0x2c')](handleError(_0x5326ba,null));}; \ No newline at end of file diff --git a/server/api/squareProject/squareProject.events.js b/server/api/squareProject/squareProject.events.js index b4d6712..55a5d00 100644 --- a/server/api/squareProject/squareProject.events.js +++ b/server/api/squareProject/squareProject.events.js @@ -1 +1 @@ -const a599_0x54d5=['../../mysqldb','update','exports','emit','addHook','setMaxListeners','remove','save','SquareProject'];(function(_0x2688e9,_0x54d503){const _0x41132e=function(_0x2f0611){while(--_0x2f0611){_0x2688e9['push'](_0x2688e9['shift']());}};_0x41132e(++_0x54d503);}(a599_0x54d5,0x17c));const a599_0x4113=function(_0x2688e9,_0x54d503){_0x2688e9=_0x2688e9-0x0;let _0x41132e=a599_0x54d5[_0x2688e9];return _0x41132e;};const _0x370c52=a599_0x4113;'use strict';const EventEmitter=require('events'),SquareProject=require(_0x370c52('0x7'))['db'][_0x370c52('0x6')],SquareProjectEvents=new EventEmitter();SquareProjectEvents[_0x370c52('0x3')](0x0);const events={'afterCreate':_0x370c52('0x5'),'afterUpdate':_0x370c52('0x8'),'afterDestroy':_0x370c52('0x4')};function emitEvent(_0x2f0611){return function(_0x206c0b){const _0x3fea92=a599_0x4113;SquareProjectEvents[_0x3fea92('0x1')](_0x2f0611+':'+_0x206c0b['id'],_0x206c0b),SquareProjectEvents[_0x3fea92('0x1')](_0x2f0611,_0x206c0b);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];SquareProject[_0x370c52('0x2')](e,emitEvent(event));}}module[_0x370c52('0x0')]=SquareProjectEvents; \ No newline at end of file +const a599_0x4608=['addHook','exports','emit','events','../../mysqldb','undefined','setMaxListeners','remove','update'];(function(_0x19d1c5,_0x460839){const _0x4deadd=function(_0x3607d1){while(--_0x3607d1){_0x19d1c5['push'](_0x19d1c5['shift']());}};_0x4deadd(++_0x460839);}(a599_0x4608,0x13f));const a599_0x4dea=function(_0x19d1c5,_0x460839){_0x19d1c5=_0x19d1c5-0x0;let _0x4deadd=a599_0x4608[_0x19d1c5];return _0x4deadd;};const _0x3aa334=a599_0x4dea;'use strict';const EventEmitter=require(_0x3aa334('0x8')),SquareProject=require(_0x3aa334('0x0'))['db']['SquareProject'],SquareProjectEvents=new EventEmitter();SquareProjectEvents[_0x3aa334('0x2')](0x0);const events={'afterCreate':'save','afterUpdate':_0x3aa334('0x4'),'afterDestroy':_0x3aa334('0x3')};function emitEvent(_0x3607d1){return function(_0x3e0504){const _0x2c06c0=a599_0x4dea;SquareProjectEvents[_0x2c06c0('0x7')](_0x3607d1+':'+_0x3e0504['id'],_0x3e0504),SquareProjectEvents[_0x2c06c0('0x7')](_0x3607d1,_0x3e0504);};}for(const e in events){if(typeof events[e]!==_0x3aa334('0x1')){const event=events[e];SquareProject[_0x3aa334('0x5')](e,emitEvent(event));}}module[_0x3aa334('0x6')]=SquareProjectEvents; \ No newline at end of file diff --git a/server/api/squareProject/squareProject.model.js b/server/api/squareProject/squareProject.model.js index 18adaea..317b7a5 100644 --- a/server/api/squareProject/squareProject.model.js +++ b/server/api/squareProject/squareProject.model.js @@ -1 +1 @@ -const a600_0x1851=['./squareProject.attributes','exports','SquareProject','square_projects','define'];(function(_0x447e97,_0x18518d){const _0x15ecac=function(_0x36034f){while(--_0x36034f){_0x447e97['push'](_0x447e97['shift']());}};_0x15ecac(++_0x18518d);}(a600_0x1851,0x11b));const a600_0x15ec=function(_0x447e97,_0x18518d){_0x447e97=_0x447e97-0x0;let _0x15ecac=a600_0x1851[_0x447e97];return _0x15ecac;};const _0x469ba0=a600_0x15ec;'use strict';const attributes=require(_0x469ba0('0x2'));module[_0x469ba0('0x3')]=function(_0x36034f){const _0x423c14=_0x469ba0,_0x2f5a4b=_0x36034f[_0x423c14('0x1')](_0x423c14('0x4'),attributes,{'tableName':_0x423c14('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2f5a4b;}; \ No newline at end of file +const a600_0xde42=['./squareProject.attributes','define','SquareProject','square_projects'];(function(_0x318df2,_0xde423a){const _0x3d8a18=function(_0x2be08e){while(--_0x2be08e){_0x318df2['push'](_0x318df2['shift']());}};_0x3d8a18(++_0xde423a);}(a600_0xde42,0x163));const a600_0x3d8a=function(_0x318df2,_0xde423a){_0x318df2=_0x318df2-0x0;let _0x3d8a18=a600_0xde42[_0x318df2];return _0x3d8a18;};const _0x1316d2=a600_0x3d8a;'use strict';const attributes=require(_0x1316d2('0x1'));module['exports']=function(_0x2be08e){const _0x5277bb=_0x1316d2,_0x367d99=_0x2be08e[_0x5277bb('0x2')](_0x5277bb('0x3'),attributes,{'tableName':_0x5277bb('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x367d99;}; \ No newline at end of file diff --git a/server/api/squareProject/squareProject.rpc.js b/server/api/squareProject/squareProject.rpc.js index 7f2ef95..751b97a 100644 --- a/server/api/squareProject/squareProject.rpc.js +++ b/server/api/squareProject/squareProject.rpc.js @@ -1 +1 @@ -const a601_0x4792=['catch','include','../../rediscache','stringify','error','lodash','findOne','message','attributes','where','options','then','map','../../config/logger','register','model','ShowSquareProject'];(function(_0x105210,_0x4792f6){const _0x25e1b4=function(_0x55c2b8){while(--_0x55c2b8){_0x105210['push'](_0x105210['shift']());}};_0x25e1b4(++_0x4792f6);}(a601_0x4792,0x112));const a601_0x25e1=function(_0x105210,_0x4792f6){_0x105210=_0x105210-0x0;let _0x25e1b4=a601_0x4792[_0x105210];return _0x25e1b4;};const _0x3c1f58=a601_0x25e1;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x3c1f58('0xb'))('rpc'),_=require(_0x3c1f58('0x3')),{getSocket}=require(_0x3c1f58('0x0')),socket=getSocket();require('./squareProject.socket')[_0x3c1f58('0xc')](socket),exports[_0x3c1f58('0xe')]=function(_0x55c2b8){const _0x5bad89=this;return new Promise(function(_0x158173,_0x38d0a3){const _0x5432be=a601_0x25e1;return db['SquareProject'][_0x5432be('0x4')]({'raw':_0x55c2b8[_0x5432be('0x8')]?_0x55c2b8['options']['raw']===undefined?!![]:![]:!![],'where':_0x55c2b8['options']?_0x55c2b8[_0x5432be('0x8')][_0x5432be('0x7')]||null:null,'attributes':_0x55c2b8[_0x5432be('0x8')]?_0x55c2b8[_0x5432be('0x8')][_0x5432be('0x6')]||null:null,'include':_0x55c2b8[_0x5432be('0x8')]?_0x55c2b8[_0x5432be('0x8')]['include']?_[_0x5432be('0xa')](_0x55c2b8['options'][_0x5432be('0x10')],function(_0x2c8447){const _0x447c81=_0x5432be;return{'model':db[_0x2c8447[_0x447c81('0xd')]],'as':_0x2c8447['as'],'attributes':_0x2c8447[_0x447c81('0x6')],'include':_0x2c8447['include']?_[_0x447c81('0xa')](_0x2c8447[_0x447c81('0x10')],function(_0x42b63f){const _0x292abe=_0x447c81;return{'model':db[_0x42b63f[_0x292abe('0xd')]],'as':_0x42b63f['as'],'attributes':_0x42b63f['attributes'],'include':_0x42b63f[_0x292abe('0x10')]?_['map'](_0x42b63f[_0x292abe('0x10')],function(_0x2daa8b){const _0x559999=_0x292abe;return{'model':db[_0x2daa8b[_0x559999('0xd')]],'as':_0x2daa8b['as'],'attributes':_0x2daa8b[_0x559999('0x6')]};}):[]};}):[]};}):[]:[]})[_0x5432be('0x9')](function(_0xe8a4c5){const _0xda7550=_0x5432be;logger['info'](_0xda7550('0xe'),_0x55c2b8),logger['debug']('ShowSquareProject',_0x55c2b8,JSON[_0xda7550('0x1')](_0xe8a4c5)),_0x158173(_0xe8a4c5);})[_0x5432be('0xf')](function(_0x34be16){const _0x37cdb3=_0x5432be;logger[_0x37cdb3('0x2')](_0x37cdb3('0xe'),_0x34be16[_0x37cdb3('0x5')],_0x55c2b8),_0x38d0a3(_0x5bad89['error'](0x1f4,_0x34be16['message']));});});}; \ No newline at end of file +const a601_0x2afc=['register','SquareProject','./squareProject.socket','raw','info','map','catch','where','message','ShowSquareProject','then','../../rediscache','options','include','model','findOne','attributes','rpc','error'];(function(_0x444b05,_0x2afc29){const _0x48e235=function(_0x35be3b){while(--_0x35be3b){_0x444b05['push'](_0x444b05['shift']());}};_0x48e235(++_0x2afc29);}(a601_0x2afc,0x176));const a601_0x48e2=function(_0x444b05,_0x2afc29){_0x444b05=_0x444b05-0x0;let _0x48e235=a601_0x2afc[_0x444b05];return _0x48e235;};const _0x3f3e03=a601_0x48e2;'use strict';const db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x3f3e03('0x4')),_=require('lodash'),{getSocket}=require(_0x3f3e03('0x11')),socket=getSocket();require(_0x3f3e03('0x8'))[_0x3f3e03('0x6')](socket),exports[_0x3f3e03('0xf')]=function(_0x35be3b){const _0x941bfb=this;return new Promise(function(_0x4b3813,_0x127c54){const _0x17764d=a601_0x48e2;return db[_0x17764d('0x7')][_0x17764d('0x2')]({'raw':_0x35be3b[_0x17764d('0x12')]?_0x35be3b[_0x17764d('0x12')][_0x17764d('0x9')]===undefined?!![]:![]:!![],'where':_0x35be3b[_0x17764d('0x12')]?_0x35be3b['options'][_0x17764d('0xd')]||null:null,'attributes':_0x35be3b[_0x17764d('0x12')]?_0x35be3b[_0x17764d('0x12')][_0x17764d('0x3')]||null:null,'include':_0x35be3b[_0x17764d('0x12')]?_0x35be3b['options']['include']?_['map'](_0x35be3b[_0x17764d('0x12')][_0x17764d('0x0')],function(_0x65a738){const _0x3dac4f=_0x17764d;return{'model':db[_0x65a738[_0x3dac4f('0x1')]],'as':_0x65a738['as'],'attributes':_0x65a738['attributes'],'include':_0x65a738['include']?_['map'](_0x65a738[_0x3dac4f('0x0')],function(_0x2c6bb0){const _0x4be4e8=_0x3dac4f;return{'model':db[_0x2c6bb0['model']],'as':_0x2c6bb0['as'],'attributes':_0x2c6bb0['attributes'],'include':_0x2c6bb0[_0x4be4e8('0x0')]?_[_0x4be4e8('0xb')](_0x2c6bb0[_0x4be4e8('0x0')],function(_0x52db31){const _0x3d5b25=_0x4be4e8;return{'model':db[_0x52db31[_0x3d5b25('0x1')]],'as':_0x52db31['as'],'attributes':_0x52db31[_0x3d5b25('0x3')]};}):[]};}):[]};}):[]:[]})[_0x17764d('0x10')](function(_0x22888c){const _0x144689=_0x17764d;logger[_0x144689('0xa')](_0x144689('0xf'),_0x35be3b),logger['debug'](_0x144689('0xf'),_0x35be3b,JSON['stringify'](_0x22888c)),_0x4b3813(_0x22888c);})[_0x17764d('0xc')](function(_0x128578){const _0x179fca=_0x17764d;logger[_0x179fca('0x5')]('ShowSquareProject',_0x128578[_0x179fca('0xe')],_0x35be3b),_0x127c54(_0x941bfb[_0x179fca('0x5')](0x1f4,_0x128578[_0x179fca('0xe')]));});});}; \ No newline at end of file diff --git a/server/api/squareProject/squareProject.socket.js b/server/api/squareProject/squareProject.socket.js index 4d5bf68..e7eacaf 100644 --- a/server/api/squareProject/squareProject.socket.js +++ b/server/api/squareProject/squareProject.socket.js @@ -1 +1 @@ -const a602_0x1783=['./squareProject.events','remove','save','register','length','emit'];(function(_0x149224,_0x1783f7){const _0x4411b4=function(_0x167c84){while(--_0x167c84){_0x149224['push'](_0x149224['shift']());}};_0x4411b4(++_0x1783f7);}(a602_0x1783,0xa7));const a602_0x4411=function(_0x149224,_0x1783f7){_0x149224=_0x149224-0x0;let _0x4411b4=a602_0x1783[_0x149224];return _0x4411b4;};const _0x4d3d37=a602_0x4411;'use strict';const SquareProjectEvents=require(_0x4d3d37('0x1')),events=[_0x4d3d37('0x3'),_0x4d3d37('0x2'),'update'];function createListener(_0x167c84,_0x5f577a){return function(_0x3dd49e){const _0x5815af=a602_0x4411;_0x5f577a[_0x5815af('0x0')](_0x167c84,_0x3dd49e);};}exports[_0x4d3d37('0x4')]=function(_0x2d5607){const _0x4d5997=_0x4d3d37;for(let _0x3c13ec=0x0,_0x165545=events[_0x4d5997('0x5')];_0x3c13ec<_0x165545;_0x3c13ec++){const _0x1e4214=events[_0x3c13ec],_0x8a8dc2=createListener('squareProject:'+_0x1e4214,_0x2d5607);SquareProjectEvents['on'](_0x1e4214,_0x8a8dc2);}}; \ No newline at end of file +const a602_0x10c5=['length','save','register','squareProject:','remove'];(function(_0x1b0dca,_0x10c5e){const _0x1cdd58=function(_0x4b35e2){while(--_0x4b35e2){_0x1b0dca['push'](_0x1b0dca['shift']());}};_0x1cdd58(++_0x10c5e);}(a602_0x10c5,0xcf));const a602_0x1cdd=function(_0x1b0dca,_0x10c5e){_0x1b0dca=_0x1b0dca-0x0;let _0x1cdd58=a602_0x10c5[_0x1b0dca];return _0x1cdd58;};const _0x33cd88=a602_0x1cdd;'use strict';const SquareProjectEvents=require('./squareProject.events'),events=[_0x33cd88('0x4'),_0x33cd88('0x2'),'update'];function createListener(_0x4b35e2,_0x3e3441){return function(_0x3f889b){_0x3e3441['emit'](_0x4b35e2,_0x3f889b);};}exports[_0x33cd88('0x0')]=function(_0x183e91){const _0xbd3542=_0x33cd88;for(let _0x351ddf=0x0,_0x27f230=events[_0xbd3542('0x3')];_0x351ddf<_0x27f230;_0x351ddf++){const _0x28c69b=events[_0x351ddf],_0x4b3c91=createListener(_0xbd3542('0x1')+_0x28c69b,_0x183e91);SquareProjectEvents['on'](_0x28c69b,_0x4b3c91);}}; \ No newline at end of file diff --git a/server/api/squareRecording/index.js b/server/api/squareRecording/index.js index e643101..108b597 100644 --- a/server/api/squareRecording/index.js +++ b/server/api/squareRecording/index.js @@ -1 +1 @@ -const a603_0x46e8=['/:id/download','destroy','get','index','exports','create','isAuthenticated','../../components/auth/service','show','/:id/delete','Router','./squareRecording.controller','download','/:id','express','update','put','delete'];(function(_0x36ea23,_0x46e82b){const _0x592bb2=function(_0x447551){while(--_0x447551){_0x36ea23['push'](_0x36ea23['shift']());}};_0x592bb2(++_0x46e82b);}(a603_0x46e8,0x1d5));const a603_0x592b=function(_0x36ea23,_0x46e82b){_0x36ea23=_0x36ea23-0x0;let _0x592bb2=a603_0x46e8[_0x36ea23];return _0x592bb2;};const _0x5775e2=a603_0x592b;'use strict';const express=require(_0x5775e2('0xd')),router=express[_0x5775e2('0x9')](),auth=require(_0x5775e2('0x6')),controller=require(_0x5775e2('0xa'));router['get']('/',auth[_0x5775e2('0x5')](),controller[_0x5775e2('0x2')]),router['get'](_0x5775e2('0xc'),auth[_0x5775e2('0x5')](),controller[_0x5775e2('0x7')]),router[_0x5775e2('0x1')](_0x5775e2('0x11'),auth[_0x5775e2('0x5')](),controller[_0x5775e2('0xb')]),router['post']('/',auth[_0x5775e2('0x5')](),controller[_0x5775e2('0x4')]),router[_0x5775e2('0xf')](_0x5775e2('0xc'),auth['isAuthenticated'](),controller[_0x5775e2('0xe')]),router[_0x5775e2('0x10')](_0x5775e2('0x8'),auth[_0x5775e2('0x5')](),controller[_0x5775e2('0x0')]),module[_0x5775e2('0x3')]=router; \ No newline at end of file +const a603_0x2c22=['post','put','download','isAuthenticated','update','/:id/delete','show','exports','/:id','../../components/auth/service','/:id/download','create','get'];(function(_0x5eec10,_0x2c221c){const _0x570f7f=function(_0x4fcf93){while(--_0x4fcf93){_0x5eec10['push'](_0x5eec10['shift']());}};_0x570f7f(++_0x2c221c);}(a603_0x2c22,0x6e));const a603_0x570f=function(_0x5eec10,_0x2c221c){_0x5eec10=_0x5eec10-0x0;let _0x570f7f=a603_0x2c22[_0x5eec10];return _0x570f7f;};const _0x4f0801=a603_0x570f;'use strict';const express=require('express'),router=express['Router'](),auth=require(_0x4f0801('0x3')),controller=require('./squareRecording.controller');router[_0x4f0801('0x6')]('/',auth['isAuthenticated'](),controller['index']),router[_0x4f0801('0x6')](_0x4f0801('0x2'),auth[_0x4f0801('0xa')](),controller[_0x4f0801('0x0')]),router[_0x4f0801('0x6')](_0x4f0801('0x4'),auth['isAuthenticated'](),controller[_0x4f0801('0x9')]),router[_0x4f0801('0x7')]('/',auth[_0x4f0801('0xa')](),controller[_0x4f0801('0x5')]),router[_0x4f0801('0x8')](_0x4f0801('0x2'),auth[_0x4f0801('0xa')](),controller[_0x4f0801('0xb')]),router['delete'](_0x4f0801('0xc'),auth[_0x4f0801('0xa')](),controller['destroy']),module[_0x4f0801('0x1')]=router; \ No newline at end of file diff --git a/server/api/squareRecording/squareRecording.attributes.js b/server/api/squareRecording/squareRecording.attributes.js index 7ddc64f..7bc0015 100644 --- a/server/api/squareRecording/squareRecording.attributes.js +++ b/server/api/squareRecording/squareRecording.attributes.js @@ -1 +1 @@ -const a604_0x2f53=['STRING','sequelize','lastIndexOf','VIRTUAL','substring','getDataValue','exports'];(function(_0x697fd3,_0x2f53fa){const _0xc84041=function(_0x270da1){while(--_0x270da1){_0x697fd3['push'](_0x697fd3['shift']());}};_0xc84041(++_0x2f53fa);}(a604_0x2f53,0x1a9));const a604_0xc840=function(_0x697fd3,_0x2f53fa){_0x697fd3=_0x697fd3-0x0;let _0xc84041=a604_0x2f53[_0x697fd3];return _0xc84041;};const _0x7bb744=a604_0xc840;'use strict';const Sequelize=require(_0x7bb744('0x3'));module[_0x7bb744('0x1')]={'uniqueid':{'type':Sequelize[_0x7bb744('0x2')]},'callerid':{'type':Sequelize[_0x7bb744('0x2')]},'calleridname':{'type':Sequelize['STRING']},'context':{'type':Sequelize[_0x7bb744('0x2')]},'extension':{'type':Sequelize[_0x7bb744('0x2')]},'priority':{'type':Sequelize[_0x7bb744('0x2')]},'accountcode':{'type':Sequelize[_0x7bb744('0x2')]},'dnid':{'type':Sequelize['STRING']},'projectName':{'type':Sequelize[_0x7bb744('0x2')]},'saveName':{'type':Sequelize[_0x7bb744('0x2')]},'filename':{'type':Sequelize[_0x7bb744('0x2')]},'savePath':{'type':Sequelize['STRING']},'format':{'type':Sequelize[_0x7bb744('0x5')],'get':function(){const _0xfd140=_0x7bb744;let _0x270da1='';const _0x4db0ec=this[_0xfd140('0x0')]('savePath');return _0x4db0ec&&(_0x270da1=_0x4db0ec[_0xfd140('0x6')](_0x4db0ec[_0xfd140('0x4')]('.'))),_0x270da1;}}}; \ No newline at end of file +const a604_0x127b=['STRING','sequelize','VIRTUAL','lastIndexOf','substring','exports'];(function(_0x5d2a9d,_0x127b59){const _0x2dd88b=function(_0x323c6c){while(--_0x323c6c){_0x5d2a9d['push'](_0x5d2a9d['shift']());}};_0x2dd88b(++_0x127b59);}(a604_0x127b,0x101));const a604_0x2dd8=function(_0x5d2a9d,_0x127b59){_0x5d2a9d=_0x5d2a9d-0x0;let _0x2dd88b=a604_0x127b[_0x5d2a9d];return _0x2dd88b;};const _0x7b6b8=a604_0x2dd8;'use strict';const Sequelize=require(_0x7b6b8('0x2'));module[_0x7b6b8('0x0')]={'uniqueid':{'type':Sequelize[_0x7b6b8('0x1')]},'callerid':{'type':Sequelize['STRING']},'calleridname':{'type':Sequelize[_0x7b6b8('0x1')]},'context':{'type':Sequelize['STRING']},'extension':{'type':Sequelize[_0x7b6b8('0x1')]},'priority':{'type':Sequelize[_0x7b6b8('0x1')]},'accountcode':{'type':Sequelize[_0x7b6b8('0x1')]},'dnid':{'type':Sequelize['STRING']},'projectName':{'type':Sequelize[_0x7b6b8('0x1')]},'saveName':{'type':Sequelize[_0x7b6b8('0x1')]},'filename':{'type':Sequelize[_0x7b6b8('0x1')]},'savePath':{'type':Sequelize['STRING']},'format':{'type':Sequelize[_0x7b6b8('0x3')],'get':function(){const _0x30b2e2=_0x7b6b8;let _0x323c6c='';const _0x3c3633=this['getDataValue']('savePath');return _0x3c3633&&(_0x323c6c=_0x3c3633[_0x30b2e2('0x5')](_0x3c3633[_0x30b2e2('0x4')]('.'))),_0x323c6c;}}}; \ No newline at end of file diff --git a/server/api/squareRecording/squareRecording.controller.js b/server/api/squareRecording/squareRecording.controller.js index 81861ac..40e3a5c 100644 --- a/server/api/squareRecording/squareRecording.controller.js +++ b/server/api/squareRecording/squareRecording.controller.js @@ -1 +1 @@ -const a605_0x4605=['attributes','secrets','order','\x22\x20trovato\x20eseguo\x20la\x20cancellazione','where','intersection','send','sendStatus','body','options','type','isNil','cancellazione\x20fisica\x20documento\x20%s','savePath','offset','include','includeAll','existsSync','map','catch','../../config/logger','query','index','fieldName','error','Not\x20found','sequelize','info','SquareRecording','lodash','download','destroy','VIRTUAL','filters','api','then','../../components/encryptor','like','status','rows','merge','path','findOne','create','.cypher','decryptFile','json','update','unlink','uniqueid','SquareRecording\x20not\x20found','filename','filter','name','extname','limit','show','params','length','../../components/parsers/qs','set','unlinkSync','message','rawAttributes','fields','undefined','sort','model','stack','count','format'];(function(_0xa8a78c,_0x46059c){const _0x2d76c5=function(_0x3821cb){while(--_0x3821cb){_0xa8a78c['push'](_0xa8a78c['shift']());}};_0x2d76c5(++_0x46059c);}(a605_0x4605,0x166));const a605_0x2d76=function(_0xa8a78c,_0x46059c){_0xa8a78c=_0xa8a78c-0x0;let _0x2d76c5=a605_0x4605[_0xa8a78c];return _0x2d76c5;};const _0x5d7917=a605_0x2d76;'use strict';const util=require('util'),path=require(_0x5d7917('0x26')),fs=require('fs'),_=require(_0x5d7917('0x1a')),qs=require(_0x5d7917('0x38')),logger=require(_0x5d7917('0x11'))(_0x5d7917('0x1f')),config=require('../../config/environment'),db=require('../../mysqldb')['db'],{Op,ValidationError}=require(_0x5d7917('0x17')),{InternalError}=require('error-middleware/errors');function respondWithResult(_0x3821cb,_0x2416ad){return _0x2416ad=_0x2416ad||0xc8,function(_0x11325e){const _0x9a3931=a605_0x2d76;if(_0x11325e)return _0x3821cb[_0x9a3931('0x23')](_0x2416ad)[_0x9a3931('0x2b')](_0x11325e);};}function respondWithFilteredResult(_0x1681c3,_0x2bde77){return function(_0x3038cb){const _0x26ca98=a605_0x2d76;if(_0x3038cb){const _0x4d36d5=_0x3038cb['count'],_0x288fd4=_0x2bde77[_0x26ca98('0xb')];let _0x5001e9=_0x2bde77['offset']+_0x2bde77['limit'],_0x2a4098;return _0x5001e9>=_0x4d36d5?(_0x5001e9=_0x4d36d5,_0x2a4098=0xc8):_0x2a4098=0xce,_0x1681c3['status'](_0x2a4098),_0x1681c3[_0x26ca98('0x39')]('Content-Range',_0x288fd4+'-'+_0x5001e9+'/'+_0x4d36d5)[_0x26ca98('0x2b')](_0x3038cb);}return null;};}function saveUpdates(_0xfd6ca7){return function(_0x19d014){const _0x5b6f95=a605_0x2d76;if(_0x19d014)return _0x19d014[_0x5b6f95('0x2c')](_0xfd6ca7)[_0x5b6f95('0x20')](function(_0x46e437){return _0x46e437;});return null;};}function handleEntityNotFound(_0x4cc920){return function(_0x27f1a4){const _0x2a677a=a605_0x2d76;return!_0x27f1a4&&_0x4cc920[_0x2a677a('0x4')](0x194),_0x27f1a4;};}function handleError(_0x35b0c3,_0x17d71e){return _0x17d71e=_0x17d71e||0x1f4,function(_0x225d79){const _0x1f7eb2=a605_0x2d76;logger[_0x1f7eb2('0x15')](_0x225d79[_0x1f7eb2('0x41')]),_0x225d79[_0x1f7eb2('0x32')]&&delete _0x225d79[_0x1f7eb2('0x32')],_0x35b0c3[_0x1f7eb2('0x23')](_0x17d71e)[_0x1f7eb2('0x3')](_0x225d79);};}exports[_0x5d7917('0x13')]=function(_0x490a62,_0x1a565e){const _0x2ee9e7=_0x5d7917;let _0xf7653e={};const _0x2f87db={},_0x41e6cc={'count':0x0,'rows':[]},_0x25a88b=_[_0x2ee9e7('0xf')](db[_0x2ee9e7('0x19')]['rawAttributes'],function(_0x4e2034){const _0x35a9d1=_0x2ee9e7;return{'name':_0x4e2034[_0x35a9d1('0x14')],'type':_0x4e2034[_0x35a9d1('0x7')]['key']};});_0x2f87db[_0x2ee9e7('0x40')]=_[_0x2ee9e7('0xf')](_0x25a88b,_0x2ee9e7('0x32')),_0x2f87db[_0x2ee9e7('0x12')]=_['keys'](_0x490a62['query']),_0x2f87db[_0x2ee9e7('0x1e')]=_[_0x2ee9e7('0x2')](_0x2f87db['model'],_0x2f87db[_0x2ee9e7('0x12')]),_0xf7653e['attributes']=_[_0x2ee9e7('0x2')](_0x2f87db[_0x2ee9e7('0x40')],qs['fields'](_0x490a62[_0x2ee9e7('0x12')]['fields'])),_0xf7653e['attributes']=_0xf7653e[_0x2ee9e7('0x44')]['length']?_0xf7653e['attributes']:_0x2f87db[_0x2ee9e7('0x40')];typeof _0x490a62[_0x2ee9e7('0x12')]['nolimit']===_0x2ee9e7('0x3e')&&(_0xf7653e[_0x2ee9e7('0x34')]=qs['limit'](_0x490a62[_0x2ee9e7('0x12')][_0x2ee9e7('0x34')]),_0xf7653e['offset']=qs[_0x2ee9e7('0xb')](_0x490a62[_0x2ee9e7('0x12')][_0x2ee9e7('0xb')]));_0xf7653e[_0x2ee9e7('0x46')]=qs[_0x2ee9e7('0x3f')](_0x490a62[_0x2ee9e7('0x12')][_0x2ee9e7('0x3f')]),_0xf7653e['where']=qs[_0x2ee9e7('0x1e')](_['pick'](_0x490a62[_0x2ee9e7('0x12')],_0x2f87db['filters']),_0x25a88b);_0x490a62[_0x2ee9e7('0x12')][_0x2ee9e7('0x31')]&&(_0xf7653e[_0x2ee9e7('0x1')]=_[_0x2ee9e7('0x25')](_0xf7653e[_0x2ee9e7('0x1')],{[Op['or']]:_['map'](_0x25a88b,function(_0x1666ab){const _0x1a0384=_0x2ee9e7;if(_0x1666ab[_0x1a0384('0x7')]!==_0x1a0384('0x1d')){const _0x9a035b={};return _0x9a035b[_0x1666ab[_0x1a0384('0x32')]]={[Op[_0x1a0384('0x22')]]:'%'+_0x490a62['query'][_0x1a0384('0x31')]+'%'},_0x9a035b;}})}));_0xf7653e=_[_0x2ee9e7('0x25')]({},_0xf7653e,_0x490a62[_0x2ee9e7('0x6')]);const _0x49d09={'where':_0xf7653e[_0x2ee9e7('0x1')]};return db['SquareRecording']['count'](_0x49d09)['then'](function(_0x44ade9){const _0x4858c5=_0x2ee9e7;return _0x41e6cc[_0x4858c5('0x42')]=_0x44ade9,_0x490a62['query'][_0x4858c5('0xd')]&&(_0xf7653e[_0x4858c5('0xc')]=[{'all':!![]}]),db[_0x4858c5('0x19')]['findAll'](_0xf7653e);})['then'](function(_0x3b176e){const _0x23ef93=_0x2ee9e7;return _0x41e6cc[_0x23ef93('0x24')]=_0x3b176e,_0x41e6cc;})[_0x2ee9e7('0x20')](respondWithFilteredResult(_0x1a565e,_0xf7653e))[_0x2ee9e7('0x10')](handleError(_0x1a565e,null));},exports[_0x5d7917('0x35')]=function(_0x390d02,_0x16a25d){const _0x31f938=_0x5d7917;let _0x186c0b={'raw':!![],'where':{'id':_0x390d02[_0x31f938('0x36')]['id']}};const _0x34ed3a={};return _0x34ed3a[_0x31f938('0x40')]=_['keys'](db[_0x31f938('0x19')][_0x31f938('0x3c')]),_0x34ed3a[_0x31f938('0x12')]=_['keys'](_0x390d02[_0x31f938('0x12')]),_0x34ed3a['filters']=_[_0x31f938('0x2')](_0x34ed3a[_0x31f938('0x40')],_0x34ed3a[_0x31f938('0x12')]),_0x186c0b[_0x31f938('0x44')]=_['intersection'](_0x34ed3a[_0x31f938('0x40')],qs[_0x31f938('0x3d')](_0x390d02[_0x31f938('0x12')][_0x31f938('0x3d')])),_0x186c0b[_0x31f938('0x44')]=_0x186c0b[_0x31f938('0x44')][_0x31f938('0x37')]?_0x186c0b['attributes']:_0x34ed3a[_0x31f938('0x40')],_0x390d02[_0x31f938('0x12')][_0x31f938('0xd')]&&(_0x186c0b[_0x31f938('0xc')]=[{'all':!![]}]),_0x186c0b=_[_0x31f938('0x25')]({},_0x186c0b,_0x390d02['options']),db[_0x31f938('0x19')][_0x31f938('0x27')](_0x186c0b)[_0x31f938('0x20')](handleEntityNotFound(_0x16a25d,null))[_0x31f938('0x20')](respondWithResult(_0x16a25d,null))['catch'](handleError(_0x16a25d,null));},exports[_0x5d7917('0x28')]=function(_0x20b127,_0x12fa40){const _0x1985a1=_0x5d7917;return db[_0x1985a1('0x19')][_0x1985a1('0x28')](_0x20b127[_0x1985a1('0x5')],{})[_0x1985a1('0x20')](respondWithResult(_0x12fa40,0xc9))[_0x1985a1('0x10')](handleError(_0x12fa40,null));},exports[_0x5d7917('0x2c')]=function(_0x143a8f,_0x59b8eb){const _0x124363=_0x5d7917;return _0x143a8f[_0x124363('0x5')]['id']&&delete _0x143a8f[_0x124363('0x5')]['id'],db[_0x124363('0x19')]['findOne']({'where':{'id':_0x143a8f[_0x124363('0x36')]['id']}})['then'](handleEntityNotFound(_0x59b8eb,null))[_0x124363('0x20')](saveUpdates(_0x143a8f[_0x124363('0x5')],null))[_0x124363('0x20')](respondWithResult(_0x59b8eb,null))[_0x124363('0x10')](handleError(_0x59b8eb,null));},exports[_0x5d7917('0x1b')]=function(_0x11e33c,_0x4441ef){const _0x377651=_0x5d7917,_0x203348=require(_0x377651('0x21'));let _0x3f90ae=![];const _0x47ce6a={};return _0x11e33c[_0x377651('0x12')][_0x377651('0x7')]&&_0x11e33c[_0x377651('0x12')][_0x377651('0x7')]===_0x377651('0x2e')?_0x47ce6a[_0x377651('0x2e')]=_0x11e33c[_0x377651('0x36')]['id']:_0x47ce6a['id']=_0x11e33c[_0x377651('0x36')]['id'],db['SquareRecording']['findOne']({'where':_0x47ce6a,'attributes':['id','savePath',_0x377651('0x30')],'raw':!![]})['then'](handleEntityNotFound(_0x4441ef,null))[_0x377651('0x20')](function(_0x7751b4){const _0x26128d=_0x377651;if(_0x7751b4){const _0x1f129e=_0x7751b4[_0x26128d('0xa')],_0x2c2551=util[_0x26128d('0x43')]('%s.cypher',_0x1f129e);if(fs[_0x26128d('0xe')](_0x2c2551))return _0x3f90ae=!![],_0x203348[_0x26128d('0x2a')](_0x2c2551,_0x1f129e,config[_0x26128d('0x45')]['recording'])['then'](function(){return _0x7751b4;});return _0x7751b4;}})[_0x377651('0x20')](function(_0x4b347b){const _0x539560=_0x377651;if(_0x4b347b){const _0x4f8749=_0x4b347b[_0x539560('0xa')];if(!fs[_0x539560('0xe')](_0x4f8749))throw new ValidationError('SquareRecording\x20not\x20found');return _0x4b347b['filename']?_0x4441ef[_0x539560('0x1b')](_0x4f8749,_0x4b347b[_0x539560('0x30')]+path[_0x539560('0x33')](_0x4f8749),function(){const _0x27c426=_0x539560;_0x3f90ae&&fs[_0x27c426('0x2d')](_0x4f8749);}):_0x4441ef[_0x539560('0x1b')](_0x4f8749,function(){const _0x33b2a1=_0x539560;_0x3f90ae&&fs[_0x33b2a1('0x2d')](_0x4f8749);});}})['catch'](function(_0x426c22){const _0x2ba7a3=_0x377651;if(_0x426c22[_0x2ba7a3('0x3b')]===_0x2ba7a3('0x2f'))_0x4441ef[_0x2ba7a3('0x23')](0x194)[_0x2ba7a3('0x3')](_0x2ba7a3('0x16'));else return handleError(_0x4441ef,null);});},exports[_0x5d7917('0x1c')]=function(_0x392180,_0x2e4f7f){const _0x6b2613=_0x5d7917;return db[_0x6b2613('0x19')]['findOne']({'where':{'id':_0x392180[_0x6b2613('0x36')]['id']}})[_0x6b2613('0x20')](function(_0x517dea){if(!_0x517dea)throw new ReferenceError('Entity\x20not\x20found');return _0x517dea;})[_0x6b2613('0x20')](function(_0x2ed87b){const _0x1b3fc4=_0x6b2613;let _0x1a42a5=_0x2ed87b[_0x1b3fc4('0xa')];return logger[_0x1b3fc4('0x18')](_0x1b3fc4('0x9'),_0x1a42a5),!_[_0x1b3fc4('0x8')](_0x2ed87b[_0x1b3fc4('0xa')])&&fs[_0x1b3fc4('0xe')](_0x1a42a5)&&(logger[_0x1b3fc4('0x18')]('File:\x20\x22'+_0x1a42a5+_0x1b3fc4('0x0')),fs[_0x1b3fc4('0x3a')](_0x1a42a5)),_0x1a42a5=_0x1a42a5+_0x1b3fc4('0x29'),!_[_0x1b3fc4('0x8')](_0x2ed87b['savePath'])&&fs['existsSync'](_0x1a42a5)&&(logger[_0x1b3fc4('0x18')]('File:\x20\x22'+_0x1a42a5+_0x1b3fc4('0x0')),fs[_0x1b3fc4('0x3a')](_0x1a42a5)),_0x2ed87b;})[_0x6b2613('0x20')](function(_0x5e7af5){const _0x23e788=_0x6b2613;if(!_0x5e7af5)throw new InternalError();return _0x5e7af5[_0x23e788('0x1c')]();})[_0x6b2613('0x20')](function(){_0x2e4f7f['status'](0xcc)['end']();})['catch'](handleError(_0x2e4f7f,null));}; \ No newline at end of file +const a605_0x580d=['savePath','../../components/encryptor','nolimit','unlinkSync','existsSync','filter','format','merge','create','secrets','status','set','api','intersection','includeAll','stack','model','findAll','download','recording','map','\x22\x20trovato\x20eseguo\x20la\x20cancellazione','keys','Content-Range','then','unlink','path','util','filters','sequelize','name','where','../../components/parsers/qs','SquareRecording\x20not\x20found','uniqueid','body','query','catch','order','type','undefined','rows','Not\x20found','findOne','limit','info','.cypher','filename','json','lodash','fields','sort','extname','../../config/logger','destroy','File:\x20\x22','update','Entity\x20not\x20found','send','offset','SquareRecording','options','count','isNil','../../config/environment','pick','include','rawAttributes','params','attributes','index','../../mysqldb','fieldName','message'];(function(_0x24411a,_0x580d9b){const _0x10d7a7=function(_0x22b51e){while(--_0x22b51e){_0x24411a['push'](_0x24411a['shift']());}};_0x10d7a7(++_0x580d9b);}(a605_0x580d,0x97));const a605_0x10d7=function(_0x24411a,_0x580d9b){_0x24411a=_0x24411a-0x0;let _0x10d7a7=a605_0x580d[_0x24411a];return _0x10d7a7;};const _0x12ec25=a605_0x10d7;'use strict';const util=require(_0x12ec25('0x18')),path=require(_0x12ec25('0x17')),fs=require('fs'),_=require(_0x12ec25('0x2e')),qs=require(_0x12ec25('0x1d')),logger=require(_0x12ec25('0x32'))(_0x12ec25('0x9')),config=require(_0x12ec25('0x3d')),db=require(_0x12ec25('0x44'))['db'],{Op,ValidationError}=require(_0x12ec25('0x1a')),{InternalError}=require('error-middleware/errors');function respondWithResult(_0x22b51e,_0x3e88ad){return _0x3e88ad=_0x3e88ad||0xc8,function(_0x31ffd3){const _0x1c5835=a605_0x10d7;if(_0x31ffd3)return _0x22b51e[_0x1c5835('0x7')](_0x3e88ad)['json'](_0x31ffd3);};}function respondWithFilteredResult(_0x381309,_0x290841){return function(_0x8b128a){const _0xf3cece=a605_0x10d7;if(_0x8b128a){const _0x415915=_0x8b128a[_0xf3cece('0x3b')],_0x20dae4=_0x290841['offset'];let _0x511e10=_0x290841['offset']+_0x290841[_0xf3cece('0x29')],_0x44bb71;return _0x511e10>=_0x415915?(_0x511e10=_0x415915,_0x44bb71=0xc8):_0x44bb71=0xce,_0x381309[_0xf3cece('0x7')](_0x44bb71),_0x381309[_0xf3cece('0x8')](_0xf3cece('0x14'),_0x20dae4+'-'+_0x511e10+'/'+_0x415915)[_0xf3cece('0x2d')](_0x8b128a);}return null;};}function saveUpdates(_0x1b4344){return function(_0x24e801){const _0x1cfe90=a605_0x10d7;if(_0x24e801)return _0x24e801[_0x1cfe90('0x35')](_0x1b4344)['then'](function(_0x10c568){return _0x10c568;});return null;};}function handleEntityNotFound(_0x2428fa){return function(_0x2d1dd2){return!_0x2d1dd2&&_0x2428fa['sendStatus'](0x194),_0x2d1dd2;};}function handleError(_0x43b92c,_0x21f375){return _0x21f375=_0x21f375||0x1f4,function(_0x4ca394){const _0x77be40=a605_0x10d7;logger['error'](_0x4ca394[_0x77be40('0xc')]),_0x4ca394[_0x77be40('0x1b')]&&delete _0x4ca394[_0x77be40('0x1b')],_0x43b92c[_0x77be40('0x7')](_0x21f375)[_0x77be40('0x37')](_0x4ca394);};}exports[_0x12ec25('0x43')]=function(_0xfff3d3,_0x1351b0){const _0x3ee0f8=_0x12ec25;let _0x24d65a={};const _0x5cc67e={},_0x57d269={'count':0x0,'rows':[]},_0x27e78c=_['map'](db[_0x3ee0f8('0x39')][_0x3ee0f8('0x40')],function(_0x14d003){const _0x710ea0=_0x3ee0f8;return{'name':_0x14d003[_0x710ea0('0x45')],'type':_0x14d003[_0x710ea0('0x24')]['key']};});_0x5cc67e[_0x3ee0f8('0xd')]=_[_0x3ee0f8('0x11')](_0x27e78c,_0x3ee0f8('0x1b')),_0x5cc67e['query']=_['keys'](_0xfff3d3[_0x3ee0f8('0x21')]),_0x5cc67e[_0x3ee0f8('0x19')]=_[_0x3ee0f8('0xa')](_0x5cc67e['model'],_0x5cc67e['query']),_0x24d65a[_0x3ee0f8('0x42')]=_[_0x3ee0f8('0xa')](_0x5cc67e['model'],qs[_0x3ee0f8('0x2f')](_0xfff3d3[_0x3ee0f8('0x21')]['fields'])),_0x24d65a[_0x3ee0f8('0x42')]=_0x24d65a[_0x3ee0f8('0x42')]['length']?_0x24d65a[_0x3ee0f8('0x42')]:_0x5cc67e[_0x3ee0f8('0xd')];typeof _0xfff3d3[_0x3ee0f8('0x21')][_0x3ee0f8('0x49')]===_0x3ee0f8('0x25')&&(_0x24d65a['limit']=qs[_0x3ee0f8('0x29')](_0xfff3d3[_0x3ee0f8('0x21')][_0x3ee0f8('0x29')]),_0x24d65a[_0x3ee0f8('0x38')]=qs[_0x3ee0f8('0x38')](_0xfff3d3['query'][_0x3ee0f8('0x38')]));_0x24d65a[_0x3ee0f8('0x23')]=qs[_0x3ee0f8('0x30')](_0xfff3d3[_0x3ee0f8('0x21')][_0x3ee0f8('0x30')]),_0x24d65a['where']=qs[_0x3ee0f8('0x19')](_[_0x3ee0f8('0x3e')](_0xfff3d3[_0x3ee0f8('0x21')],_0x5cc67e[_0x3ee0f8('0x19')]),_0x27e78c);_0xfff3d3[_0x3ee0f8('0x21')][_0x3ee0f8('0x2')]&&(_0x24d65a[_0x3ee0f8('0x1c')]=_['merge'](_0x24d65a[_0x3ee0f8('0x1c')],{[Op['or']]:_[_0x3ee0f8('0x11')](_0x27e78c,function(_0x2df2a8){const _0x1ad11b=_0x3ee0f8;if(_0x2df2a8[_0x1ad11b('0x24')]!=='VIRTUAL'){const _0x39efdf={};return _0x39efdf[_0x2df2a8['name']]={[Op['like']]:'%'+_0xfff3d3[_0x1ad11b('0x21')][_0x1ad11b('0x2')]+'%'},_0x39efdf;}})}));_0x24d65a=_[_0x3ee0f8('0x4')]({},_0x24d65a,_0xfff3d3[_0x3ee0f8('0x3a')]);const _0x12df6e={'where':_0x24d65a[_0x3ee0f8('0x1c')]};return db[_0x3ee0f8('0x39')]['count'](_0x12df6e)[_0x3ee0f8('0x15')](function(_0x349390){const _0x5562e5=_0x3ee0f8;return _0x57d269[_0x5562e5('0x3b')]=_0x349390,_0xfff3d3['query'][_0x5562e5('0xb')]&&(_0x24d65a[_0x5562e5('0x3f')]=[{'all':!![]}]),db[_0x5562e5('0x39')][_0x5562e5('0xe')](_0x24d65a);})[_0x3ee0f8('0x15')](function(_0xa5c1cc){const _0x59dd2e=_0x3ee0f8;return _0x57d269[_0x59dd2e('0x26')]=_0xa5c1cc,_0x57d269;})[_0x3ee0f8('0x15')](respondWithFilteredResult(_0x1351b0,_0x24d65a))[_0x3ee0f8('0x22')](handleError(_0x1351b0,null));},exports['show']=function(_0x1c9542,_0x4d2f93){const _0x17d2de=_0x12ec25;let _0x51530d={'raw':!![],'where':{'id':_0x1c9542[_0x17d2de('0x41')]['id']}};const _0x33ca6f={};return _0x33ca6f['model']=_[_0x17d2de('0x13')](db[_0x17d2de('0x39')][_0x17d2de('0x40')]),_0x33ca6f['query']=_[_0x17d2de('0x13')](_0x1c9542[_0x17d2de('0x21')]),_0x33ca6f[_0x17d2de('0x19')]=_[_0x17d2de('0xa')](_0x33ca6f[_0x17d2de('0xd')],_0x33ca6f[_0x17d2de('0x21')]),_0x51530d[_0x17d2de('0x42')]=_[_0x17d2de('0xa')](_0x33ca6f[_0x17d2de('0xd')],qs[_0x17d2de('0x2f')](_0x1c9542[_0x17d2de('0x21')][_0x17d2de('0x2f')])),_0x51530d['attributes']=_0x51530d[_0x17d2de('0x42')]['length']?_0x51530d['attributes']:_0x33ca6f[_0x17d2de('0xd')],_0x1c9542[_0x17d2de('0x21')][_0x17d2de('0xb')]&&(_0x51530d[_0x17d2de('0x3f')]=[{'all':!![]}]),_0x51530d=_[_0x17d2de('0x4')]({},_0x51530d,_0x1c9542[_0x17d2de('0x3a')]),db['SquareRecording'][_0x17d2de('0x28')](_0x51530d)[_0x17d2de('0x15')](handleEntityNotFound(_0x4d2f93,null))[_0x17d2de('0x15')](respondWithResult(_0x4d2f93,null))[_0x17d2de('0x22')](handleError(_0x4d2f93,null));},exports[_0x12ec25('0x5')]=function(_0x3f49d9,_0x236c94){const _0x263273=_0x12ec25;return db[_0x263273('0x39')]['create'](_0x3f49d9[_0x263273('0x20')],{})[_0x263273('0x15')](respondWithResult(_0x236c94,0xc9))[_0x263273('0x22')](handleError(_0x236c94,null));},exports[_0x12ec25('0x35')]=function(_0x2b7bbf,_0x35b8c2){const _0x39bf0f=_0x12ec25;return _0x2b7bbf[_0x39bf0f('0x20')]['id']&&delete _0x2b7bbf[_0x39bf0f('0x20')]['id'],db[_0x39bf0f('0x39')][_0x39bf0f('0x28')]({'where':{'id':_0x2b7bbf[_0x39bf0f('0x41')]['id']}})['then'](handleEntityNotFound(_0x35b8c2,null))[_0x39bf0f('0x15')](saveUpdates(_0x2b7bbf[_0x39bf0f('0x20')],null))[_0x39bf0f('0x15')](respondWithResult(_0x35b8c2,null))[_0x39bf0f('0x22')](handleError(_0x35b8c2,null));},exports[_0x12ec25('0xf')]=function(_0x5d51ca,_0x270080){const _0x38fade=_0x12ec25,_0x2bd7df=require(_0x38fade('0x48'));let _0x463a60=![];const _0x5a69c1={};return _0x5d51ca[_0x38fade('0x21')][_0x38fade('0x24')]&&_0x5d51ca[_0x38fade('0x21')][_0x38fade('0x24')]==='uniqueid'?_0x5a69c1[_0x38fade('0x1f')]=_0x5d51ca['params']['id']:_0x5a69c1['id']=_0x5d51ca['params']['id'],db[_0x38fade('0x39')][_0x38fade('0x28')]({'where':_0x5a69c1,'attributes':['id',_0x38fade('0x47'),_0x38fade('0x2c')],'raw':!![]})['then'](handleEntityNotFound(_0x270080,null))['then'](function(_0x9992a8){const _0x4ae125=_0x38fade;if(_0x9992a8){const _0x2e230f=_0x9992a8['savePath'],_0x1cd529=util[_0x4ae125('0x3')]('%s.cypher',_0x2e230f);if(fs[_0x4ae125('0x1')](_0x1cd529))return _0x463a60=!![],_0x2bd7df['decryptFile'](_0x1cd529,_0x2e230f,config[_0x4ae125('0x6')][_0x4ae125('0x10')])[_0x4ae125('0x15')](function(){return _0x9992a8;});return _0x9992a8;}})[_0x38fade('0x15')](function(_0x415114){const _0x3cc2a0=_0x38fade;if(_0x415114){const _0x422b70=_0x415114[_0x3cc2a0('0x47')];if(!fs[_0x3cc2a0('0x1')](_0x422b70))throw new ValidationError(_0x3cc2a0('0x1e'));return _0x415114[_0x3cc2a0('0x2c')]?_0x270080[_0x3cc2a0('0xf')](_0x422b70,_0x415114[_0x3cc2a0('0x2c')]+path[_0x3cc2a0('0x31')](_0x422b70),function(){_0x463a60&&fs['unlink'](_0x422b70);}):_0x270080[_0x3cc2a0('0xf')](_0x422b70,function(){const _0x823d86=_0x3cc2a0;_0x463a60&&fs[_0x823d86('0x16')](_0x422b70);});}})[_0x38fade('0x22')](function(_0xec7399){const _0x32c9f8=_0x38fade;if(_0xec7399[_0x32c9f8('0x46')]===_0x32c9f8('0x1e'))_0x270080[_0x32c9f8('0x7')](0x194)[_0x32c9f8('0x37')](_0x32c9f8('0x27'));else return handleError(_0x270080,null);});},exports[_0x12ec25('0x33')]=function(_0x23d4f8,_0x3b84bb){const _0x456713=_0x12ec25;return db[_0x456713('0x39')]['findOne']({'where':{'id':_0x23d4f8[_0x456713('0x41')]['id']}})[_0x456713('0x15')](function(_0xbc40f6){const _0x82e47a=_0x456713;if(!_0xbc40f6)throw new ReferenceError(_0x82e47a('0x36'));return _0xbc40f6;})[_0x456713('0x15')](function(_0x1bce73){const _0x2854ee=_0x456713;let _0x3f1432=_0x1bce73[_0x2854ee('0x47')];return logger[_0x2854ee('0x2a')]('cancellazione\x20fisica\x20documento\x20%s',_0x3f1432),!_[_0x2854ee('0x3c')](_0x1bce73[_0x2854ee('0x47')])&&fs[_0x2854ee('0x1')](_0x3f1432)&&(logger['info'](_0x2854ee('0x34')+_0x3f1432+_0x2854ee('0x12')),fs[_0x2854ee('0x0')](_0x3f1432)),_0x3f1432=_0x3f1432+_0x2854ee('0x2b'),!_[_0x2854ee('0x3c')](_0x1bce73['savePath'])&&fs[_0x2854ee('0x1')](_0x3f1432)&&(logger[_0x2854ee('0x2a')](_0x2854ee('0x34')+_0x3f1432+_0x2854ee('0x12')),fs['unlinkSync'](_0x3f1432)),_0x1bce73;})['then'](function(_0x1c9569){if(!_0x1c9569)throw new InternalError();return _0x1c9569['destroy']();})[_0x456713('0x15')](function(){const _0x7a04bd=_0x456713;_0x3b84bb[_0x7a04bd('0x7')](0xcc)['end']();})[_0x456713('0x22')](handleError(_0x3b84bb,null));}; \ No newline at end of file diff --git a/server/api/squareRecording/squareRecording.model.js b/server/api/squareRecording/squareRecording.model.js index 86b7f3d..0c3fd76 100644 --- a/server/api/squareRecording/squareRecording.model.js +++ b/server/api/squareRecording/squareRecording.model.js @@ -1 +1 @@ -const a606_0x2ce7=['SquareRecording','./squareRecording.attributes','square_recordings','exports'];(function(_0x10c22f,_0x2ce75c){const _0x2e7c47=function(_0x2acd61){while(--_0x2acd61){_0x10c22f['push'](_0x10c22f['shift']());}};_0x2e7c47(++_0x2ce75c);}(a606_0x2ce7,0x1d4));const a606_0x2e7c=function(_0x10c22f,_0x2ce75c){_0x10c22f=_0x10c22f-0x0;let _0x2e7c47=a606_0x2ce7[_0x10c22f];return _0x2e7c47;};const _0x2aff87=a606_0x2e7c;'use strict';const attributes=require(_0x2aff87('0x1'));module[_0x2aff87('0x3')]=function(_0x2acd61){const _0x14691d=_0x2aff87,_0x5b8d7b=_0x2acd61['define'](_0x14691d('0x0'),attributes,{'tableName':_0x14691d('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x5b8d7b;}; \ No newline at end of file +const a606_0x20ad=['SquareRecording','define','exports','./squareRecording.attributes','square_recordings'];(function(_0x3caed1,_0x20adff){const _0x4e632b=function(_0x31f4da){while(--_0x31f4da){_0x3caed1['push'](_0x3caed1['shift']());}};_0x4e632b(++_0x20adff);}(a606_0x20ad,0x1e7));const a606_0x4e63=function(_0x3caed1,_0x20adff){_0x3caed1=_0x3caed1-0x0;let _0x4e632b=a606_0x20ad[_0x3caed1];return _0x4e632b;};const _0x402456=a606_0x4e63;'use strict';const attributes=require(_0x402456('0x1'));module[_0x402456('0x0')]=function(_0x31f4da){const _0x149cc5=_0x402456,_0x346435=_0x31f4da[_0x149cc5('0x4')](_0x149cc5('0x3'),attributes,{'tableName':_0x149cc5('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x346435;}; \ No newline at end of file diff --git a/server/api/squareRecording/squareRecording.rpc.js b/server/api/squareRecording/squareRecording.rpc.js index b443d04..ecbd67b 100644 --- a/server/api/squareRecording/squareRecording.rpc.js +++ b/server/api/squareRecording/squareRecording.rpc.js @@ -1 +1 @@ -const a607_0x2c38=['../../config/logger','message','then','SquareRecording','catch','options','create','debug','stringify','body','../../mysqldb','raw','CreateSquareRecording'];(function(_0x599c9c,_0x2c38e1){const _0x108602=function(_0x368feb){while(--_0x368feb){_0x599c9c['push'](_0x599c9c['shift']());}};_0x108602(++_0x2c38e1);}(a607_0x2c38,0x127));const a607_0x1086=function(_0x599c9c,_0x2c38e1){_0x599c9c=_0x599c9c-0x0;let _0x108602=a607_0x2c38[_0x599c9c];return _0x108602;};const _0x342aee=a607_0x1086;'use strict';const db=require(_0x342aee('0x1'))['db'],logger=require(_0x342aee('0x4'))('rpc');exports[_0x342aee('0x3')]=function(_0x368feb){const _0x3dd3cd=this;return new Promise(function(_0x357051,_0x1c011b){const _0xf29d34=a607_0x1086;return db[_0xf29d34('0x7')][_0xf29d34('0xa')](_0x368feb[_0xf29d34('0x0')],{'raw':_0x368feb[_0xf29d34('0x9')]?_0x368feb['options'][_0xf29d34('0x2')]===undefined?!![]:![]:!![]})[_0xf29d34('0x6')](function(_0x265376){const _0x27cf72=_0xf29d34;logger['info'](_0x27cf72('0x3'),_0x368feb),logger[_0x27cf72('0xb')](_0x27cf72('0x3'),_0x368feb,JSON[_0x27cf72('0xc')](_0x265376)),_0x357051(_0x265376);})[_0xf29d34('0x8')](function(_0x80ea96){const _0x4679ad=_0xf29d34;logger['error'](_0x4679ad('0x3'),_0x80ea96[_0x4679ad('0x5')],_0x368feb),_0x1c011b(_0x3dd3cd['error'](0x1f4,_0x80ea96['message']));});});}; \ No newline at end of file +const a607_0x8136=['../../mysqldb','error','rpc','debug','create','CreateSquareRecording','SquareRecording','options','message','../../config/logger','raw','catch'];(function(_0x48df0c,_0x8136ff){const _0x1801c0=function(_0x3e1464){while(--_0x3e1464){_0x48df0c['push'](_0x48df0c['shift']());}};_0x1801c0(++_0x8136ff);}(a607_0x8136,0x1b5));const a607_0x1801=function(_0x48df0c,_0x8136ff){_0x48df0c=_0x48df0c-0x0;let _0x1801c0=a607_0x8136[_0x48df0c];return _0x1801c0;};const _0x170031=a607_0x1801;'use strict';const db=require(_0x170031('0x7'))['db'],logger=require(_0x170031('0x4'))(_0x170031('0x9'));exports['CreateSquareRecording']=function(_0x3e1464){const _0x129a3a=this;return new Promise(function(_0x4aedcc,_0x4aa1a9){const _0x590e16=a607_0x1801;return db[_0x590e16('0x1')][_0x590e16('0xb')](_0x3e1464['body'],{'raw':_0x3e1464['options']?_0x3e1464[_0x590e16('0x2')][_0x590e16('0x5')]===undefined?!![]:![]:!![]})['then'](function(_0x1767aa){const _0x37b04f=_0x590e16;logger['info'](_0x37b04f('0x0'),_0x3e1464),logger[_0x37b04f('0xa')]('CreateSquareRecording',_0x3e1464,JSON['stringify'](_0x1767aa)),_0x4aedcc(_0x1767aa);})[_0x590e16('0x6')](function(_0x34d711){const _0x557d5e=_0x590e16;logger[_0x557d5e('0x8')](_0x557d5e('0x0'),_0x34d711[_0x557d5e('0x3')],_0x3e1464),_0x4aa1a9(_0x129a3a[_0x557d5e('0x8')](0x1f4,_0x34d711[_0x557d5e('0x3')]));});});}; \ No newline at end of file diff --git a/server/api/squareReport/index.js b/server/api/squareReport/index.js index 6968d32..7ab6142 100644 --- a/server/api/squareReport/index.js +++ b/server/api/squareReport/index.js @@ -1 +1 @@ -const a608_0x2b66=['show','post','put','describe','../../components/auth/service','isAuthenticated','/:id','update','index','create','Router','exports','get'];(function(_0x134510,_0x2b666d){const _0xd64f9a=function(_0x590f1f){while(--_0x590f1f){_0x134510['push'](_0x134510['shift']());}};_0xd64f9a(++_0x2b666d);}(a608_0x2b66,0x164));const a608_0xd64f=function(_0x134510,_0x2b666d){_0x134510=_0x134510-0x0;let _0xd64f9a=a608_0x2b66[_0x134510];return _0xd64f9a;};const _0x3076a5=a608_0xd64f;'use strict';const express=require('express'),router=express[_0x3076a5('0x5')](),auth=require(_0x3076a5('0xc')),controller=require('./squareReport.controller');router[_0x3076a5('0x7')]('/',auth[_0x3076a5('0x0')](),controller[_0x3076a5('0x3')]),router[_0x3076a5('0x7')]('/describe',auth[_0x3076a5('0x0')](),controller[_0x3076a5('0xb')]),router['get'](_0x3076a5('0x1'),auth[_0x3076a5('0x0')](),controller[_0x3076a5('0x8')]),router[_0x3076a5('0x9')]('/',auth[_0x3076a5('0x0')](),controller[_0x3076a5('0x4')]),router[_0x3076a5('0xa')]('/:id',auth[_0x3076a5('0x0')](),controller[_0x3076a5('0x2')]),router['delete'](_0x3076a5('0x1'),auth[_0x3076a5('0x0')](),controller['destroy']),module[_0x3076a5('0x6')]=router; \ No newline at end of file +const a608_0x6a6b=['isAuthenticated','/describe','put','create','describe','get','./squareReport.controller','/:id','index','show','update','destroy','Router','delete','../../components/auth/service'];(function(_0x573721,_0x6a6bfe){const _0x5d0c1d=function(_0x5b786e){while(--_0x5b786e){_0x573721['push'](_0x573721['shift']());}};_0x5d0c1d(++_0x6a6bfe);}(a608_0x6a6b,0x182));const a608_0x5d0c=function(_0x573721,_0x6a6bfe){_0x573721=_0x573721-0x0;let _0x5d0c1d=a608_0x6a6b[_0x573721];return _0x5d0c1d;};const _0x59940c=a608_0x5d0c;'use strict';const express=require('express'),router=express[_0x59940c('0x1')](),auth=require(_0x59940c('0x3')),controller=require(_0x59940c('0xa'));router['get']('/',auth[_0x59940c('0x4')](),controller[_0x59940c('0xc')]),router[_0x59940c('0x9')](_0x59940c('0x5'),auth[_0x59940c('0x4')](),controller[_0x59940c('0x8')]),router['get'](_0x59940c('0xb'),auth[_0x59940c('0x4')](),controller[_0x59940c('0xd')]),router['post']('/',auth[_0x59940c('0x4')](),controller[_0x59940c('0x7')]),router[_0x59940c('0x6')](_0x59940c('0xb'),auth[_0x59940c('0x4')](),controller[_0x59940c('0xe')]),router[_0x59940c('0x2')](_0x59940c('0xb'),auth['isAuthenticated'](),controller[_0x59940c('0x0')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/squareReport/squareReport.attributes.js b/server/api/squareReport/squareReport.attributes.js index ecdb653..24ef3e0 100644 --- a/server/api/squareReport/squareReport.attributes.js +++ b/server/api/squareReport/squareReport.attributes.js @@ -1 +1 @@ -const a609_0xff1e=['BOOLEAN','sequelize','DATE','exports','STRING'];(function(_0x4b91f9,_0xff1e0c){const _0x407d7d=function(_0x18744c){while(--_0x18744c){_0x4b91f9['push'](_0x4b91f9['shift']());}};_0x407d7d(++_0xff1e0c);}(a609_0xff1e,0x1b3));const a609_0x407d=function(_0x4b91f9,_0xff1e0c){_0x4b91f9=_0x4b91f9-0x0;let _0x407d7d=a609_0xff1e[_0x4b91f9];return _0x407d7d;};const _0x20c5eb=a609_0x407d;'use strict';const Sequelize=require(_0x20c5eb('0x1'));module[_0x20c5eb('0x3')]={'network':{'type':Sequelize[_0x20c5eb('0x4')]},'network_script':{'type':Sequelize['STRING']},'request':{'type':Sequelize[_0x20c5eb('0x4')]},'channel':{'type':Sequelize[_0x20c5eb('0x4')]},'language':{'type':Sequelize[_0x20c5eb('0x4')]},'type':{'type':Sequelize[_0x20c5eb('0x4')]},'uniqueid':{'type':Sequelize[_0x20c5eb('0x4')]},'version':{'type':Sequelize[_0x20c5eb('0x4')]},'callerid':{'type':Sequelize['STRING']},'calleridname':{'type':Sequelize[_0x20c5eb('0x4')]},'callingpres':{'type':Sequelize[_0x20c5eb('0x4')]},'callingani2':{'type':Sequelize[_0x20c5eb('0x4')]},'callington':{'type':Sequelize[_0x20c5eb('0x4')]},'callingtns':{'type':Sequelize[_0x20c5eb('0x4')]},'dnid':{'type':Sequelize[_0x20c5eb('0x4')]},'rdnis':{'type':Sequelize[_0x20c5eb('0x4')]},'context':{'type':Sequelize[_0x20c5eb('0x4')]},'extension':{'type':Sequelize[_0x20c5eb('0x4')]},'priority':{'type':Sequelize['STRING']},'enhanced':{'type':Sequelize[_0x20c5eb('0x4')]},'accountcode':{'type':Sequelize[_0x20c5eb('0x4')]},'threadid':{'type':Sequelize[_0x20c5eb('0x4')]},'project_name':{'type':Sequelize[_0x20c5eb('0x4')]},'joinAt':{'type':Sequelize[_0x20c5eb('0x2')]},'leaveAt':{'type':Sequelize['DATE']},'bot':{'type':Sequelize[_0x20c5eb('0x0')],'defaultValue':![]}}; \ No newline at end of file +const a609_0x527b=['exports','STRING','sequelize','BOOLEAN','DATE'];(function(_0x4fcc4e,_0x527b3c){const _0x587440=function(_0x597194){while(--_0x597194){_0x4fcc4e['push'](_0x4fcc4e['shift']());}};_0x587440(++_0x527b3c);}(a609_0x527b,0x1cc));const a609_0x5874=function(_0x4fcc4e,_0x527b3c){_0x4fcc4e=_0x4fcc4e-0x0;let _0x587440=a609_0x527b[_0x4fcc4e];return _0x587440;};const _0x31afc3=a609_0x5874;'use strict';const Sequelize=require(_0x31afc3('0x2'));module[_0x31afc3('0x0')]={'network':{'type':Sequelize['STRING']},'network_script':{'type':Sequelize[_0x31afc3('0x1')]},'request':{'type':Sequelize[_0x31afc3('0x1')]},'channel':{'type':Sequelize['STRING']},'language':{'type':Sequelize[_0x31afc3('0x1')]},'type':{'type':Sequelize[_0x31afc3('0x1')]},'uniqueid':{'type':Sequelize['STRING']},'version':{'type':Sequelize[_0x31afc3('0x1')]},'callerid':{'type':Sequelize[_0x31afc3('0x1')]},'calleridname':{'type':Sequelize[_0x31afc3('0x1')]},'callingpres':{'type':Sequelize['STRING']},'callingani2':{'type':Sequelize[_0x31afc3('0x1')]},'callington':{'type':Sequelize[_0x31afc3('0x1')]},'callingtns':{'type':Sequelize['STRING']},'dnid':{'type':Sequelize[_0x31afc3('0x1')]},'rdnis':{'type':Sequelize[_0x31afc3('0x1')]},'context':{'type':Sequelize[_0x31afc3('0x1')]},'extension':{'type':Sequelize[_0x31afc3('0x1')]},'priority':{'type':Sequelize[_0x31afc3('0x1')]},'enhanced':{'type':Sequelize['STRING']},'accountcode':{'type':Sequelize[_0x31afc3('0x1')]},'threadid':{'type':Sequelize[_0x31afc3('0x1')]},'project_name':{'type':Sequelize[_0x31afc3('0x1')]},'joinAt':{'type':Sequelize[_0x31afc3('0x4')]},'leaveAt':{'type':Sequelize[_0x31afc3('0x4')]},'bot':{'type':Sequelize[_0x31afc3('0x3')],'defaultValue':![]}}; \ No newline at end of file diff --git a/server/api/squareReport/squareReport.controller.js b/server/api/squareReport/squareReport.controller.js index f7dd179..9447ce3 100644 --- a/server/api/squareReport/squareReport.controller.js +++ b/server/api/squareReport/squareReport.controller.js @@ -1 +1 @@ -const a610_0x940f=['where','undefined','filter','include','intersection','show','../../config/logger','options','set','nolimit','sendStatus','order','offset','type','api','merge','like','length','describe','catch','count','send','VIRTUAL','name','../../mysqldb','filters','findAll','limit','map','error','rawAttributes','attributes','sort','json','update','body','params','pick','query','SquareReport','findOne','fields','destroy','then','model','includeAll','status','create','keys','sequelize','end'];(function(_0x1d7554,_0x940f5e){const _0x517f61=function(_0x1de540){while(--_0x1de540){_0x1d7554['push'](_0x1d7554['shift']());}};_0x517f61(++_0x940f5e);}(a610_0x940f,0x156));const a610_0x517f=function(_0x1d7554,_0x940f5e){_0x1d7554=_0x1d7554-0x0;let _0x517f61=a610_0x940f[_0x1d7554];return _0x517f61;};const _0x583a6e=a610_0x517f;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require(_0x583a6e('0x15'))(_0x583a6e('0x1d')),db=require(_0x583a6e('0x27'))['db'],{Op}=require(_0x583a6e('0xd'));function respondWithResult(_0x1de540,_0x2f27a5){return _0x2f27a5=_0x2f27a5||0xc8,function(_0x31c08c){const _0x524fc4=a610_0x517f;if(_0x31c08c)return _0x1de540[_0x524fc4('0xa')](_0x2f27a5)[_0x524fc4('0x30')](_0x31c08c);};}function respondWithFilteredResult(_0x9b2b0b,_0x7f4738){return function(_0x45927b){const _0x10430f=a610_0x517f;if(_0x45927b){const _0xedd1c1=_0x45927b[_0x10430f('0x23')],_0x3998fa=_0x7f4738[_0x10430f('0x1b')];let _0x4a4d8a=_0x7f4738[_0x10430f('0x1b')]+_0x7f4738[_0x10430f('0x2a')],_0x144943;return _0x4a4d8a>=_0xedd1c1?(_0x4a4d8a=_0xedd1c1,_0x144943=0xc8):_0x144943=0xce,_0x9b2b0b['status'](_0x144943),_0x9b2b0b[_0x10430f('0x17')]('Content-Range',_0x3998fa+'-'+_0x4a4d8a+'/'+_0xedd1c1)[_0x10430f('0x30')](_0x45927b);}return null;};}function saveUpdates(_0x26ed71){return function(_0x123779){if(_0x123779)return _0x123779['update'](_0x26ed71)['then'](function(_0x4a671d){return _0x4a671d;});return null;};}function removeEntity(_0x41d5b6){return function(_0x13b246){const _0x1d5e30=a610_0x517f;if(_0x13b246)return _0x13b246['destroy']()[_0x1d5e30('0x7')](function(){const _0x29b95a=_0x1d5e30;_0x41d5b6[_0x29b95a('0xa')](0xcc)[_0x29b95a('0xe')]();});};}function handleEntityNotFound(_0x21de96){return function(_0x180bb3){const _0x3ba6c6=a610_0x517f;return!_0x180bb3&&_0x21de96[_0x3ba6c6('0x19')](0x194),_0x180bb3;};}function handleError(_0x3c1575,_0x3e7b59){return _0x3e7b59=_0x3e7b59||0x1f4,function(_0x24590c){const _0x27125c=a610_0x517f;logger[_0x27125c('0x2c')](_0x24590c['stack']),_0x24590c['name']&&delete _0x24590c[_0x27125c('0x26')],_0x3c1575[_0x27125c('0xa')](_0x3e7b59)[_0x27125c('0x24')](_0x24590c);};}exports['index']=function(_0x2b4944,_0x315df8){const _0x460bbe=_0x583a6e;let _0x1705f3={};const _0x40a4e8={},_0x1e6713={'count':0x0,'rows':[]},_0x167b9c=_[_0x460bbe('0x2b')](db[_0x460bbe('0x3')][_0x460bbe('0x2d')],function(_0x2476aa){const _0x325974=_0x460bbe;return{'name':_0x2476aa['fieldName'],'type':_0x2476aa[_0x325974('0x1c')]['key']};});_0x40a4e8['model']=_[_0x460bbe('0x2b')](_0x167b9c,_0x460bbe('0x26')),_0x40a4e8[_0x460bbe('0x2')]=_[_0x460bbe('0xc')](_0x2b4944[_0x460bbe('0x2')]),_0x40a4e8[_0x460bbe('0x28')]=_['intersection'](_0x40a4e8[_0x460bbe('0x8')],_0x40a4e8['query']),_0x1705f3[_0x460bbe('0x2e')]=_[_0x460bbe('0x13')](_0x40a4e8[_0x460bbe('0x8')],qs[_0x460bbe('0x5')](_0x2b4944[_0x460bbe('0x2')][_0x460bbe('0x5')])),_0x1705f3[_0x460bbe('0x2e')]=_0x1705f3[_0x460bbe('0x2e')]['length']?_0x1705f3[_0x460bbe('0x2e')]:_0x40a4e8[_0x460bbe('0x8')];typeof _0x2b4944[_0x460bbe('0x2')][_0x460bbe('0x18')]===_0x460bbe('0x10')&&(_0x1705f3[_0x460bbe('0x2a')]=qs[_0x460bbe('0x2a')](_0x2b4944[_0x460bbe('0x2')][_0x460bbe('0x2a')]),_0x1705f3[_0x460bbe('0x1b')]=qs[_0x460bbe('0x1b')](_0x2b4944[_0x460bbe('0x2')][_0x460bbe('0x1b')]));_0x1705f3[_0x460bbe('0x1a')]=qs[_0x460bbe('0x2f')](_0x2b4944[_0x460bbe('0x2')]['sort']),_0x1705f3[_0x460bbe('0xf')]=qs['filters'](_[_0x460bbe('0x1')](_0x2b4944[_0x460bbe('0x2')],_0x40a4e8[_0x460bbe('0x28')]),_0x167b9c);_0x2b4944[_0x460bbe('0x2')][_0x460bbe('0x11')]&&(_0x1705f3[_0x460bbe('0xf')]=_[_0x460bbe('0x1e')](_0x1705f3[_0x460bbe('0xf')],{[Op['or']]:_[_0x460bbe('0x2b')](_0x167b9c,function(_0x589114){const _0x315463=_0x460bbe;if(_0x589114['type']!==_0x315463('0x25')){const _0x2c5445={};return _0x2c5445[_0x589114[_0x315463('0x26')]]={[Op[_0x315463('0x1f')]]:'%'+_0x2b4944[_0x315463('0x2')][_0x315463('0x11')]+'%'},_0x2c5445;}})}));_0x1705f3=_[_0x460bbe('0x1e')]({},_0x1705f3,_0x2b4944[_0x460bbe('0x16')]);const _0x57ef78={'where':_0x1705f3[_0x460bbe('0xf')]};return db[_0x460bbe('0x3')][_0x460bbe('0x23')](_0x57ef78)[_0x460bbe('0x7')](function(_0x526b23){const _0x378d8d=_0x460bbe;return _0x1e6713['count']=_0x526b23,_0x2b4944[_0x378d8d('0x2')][_0x378d8d('0x9')]&&(_0x1705f3[_0x378d8d('0x12')]=[{'all':!![]}]),db['SquareReport'][_0x378d8d('0x29')](_0x1705f3);})['then'](function(_0x3f2b04){return _0x1e6713['rows']=_0x3f2b04,_0x1e6713;})[_0x460bbe('0x7')](respondWithFilteredResult(_0x315df8,_0x1705f3))[_0x460bbe('0x22')](handleError(_0x315df8,null));},exports[_0x583a6e('0x14')]=function(_0x5b803d,_0x591f40){const _0x5bd8b8=_0x583a6e;let _0x4541d4={'raw':!![],'where':{'id':_0x5b803d[_0x5bd8b8('0x0')]['id']}};const _0x1e11c5={};return _0x1e11c5[_0x5bd8b8('0x8')]=_['keys'](db[_0x5bd8b8('0x3')][_0x5bd8b8('0x2d')]),_0x1e11c5['query']=_[_0x5bd8b8('0xc')](_0x5b803d[_0x5bd8b8('0x2')]),_0x1e11c5['filters']=_['intersection'](_0x1e11c5[_0x5bd8b8('0x8')],_0x1e11c5[_0x5bd8b8('0x2')]),_0x4541d4[_0x5bd8b8('0x2e')]=_[_0x5bd8b8('0x13')](_0x1e11c5[_0x5bd8b8('0x8')],qs[_0x5bd8b8('0x5')](_0x5b803d[_0x5bd8b8('0x2')][_0x5bd8b8('0x5')])),_0x4541d4[_0x5bd8b8('0x2e')]=_0x4541d4[_0x5bd8b8('0x2e')][_0x5bd8b8('0x20')]?_0x4541d4['attributes']:_0x1e11c5[_0x5bd8b8('0x8')],_0x5b803d['query'][_0x5bd8b8('0x9')]&&(_0x4541d4['include']=[{'all':!![]}]),_0x4541d4=_[_0x5bd8b8('0x1e')]({},_0x4541d4,_0x5b803d['options']),db[_0x5bd8b8('0x3')][_0x5bd8b8('0x4')](_0x4541d4)[_0x5bd8b8('0x7')](handleEntityNotFound(_0x591f40,null))[_0x5bd8b8('0x7')](respondWithResult(_0x591f40,null))[_0x5bd8b8('0x22')](handleError(_0x591f40,null));},exports[_0x583a6e('0xb')]=function(_0x599e40,_0x5b69a3){const _0x1280b0=_0x583a6e;return db[_0x1280b0('0x3')]['create'](_0x599e40[_0x1280b0('0x32')],{})[_0x1280b0('0x7')](respondWithResult(_0x5b69a3,0xc9))[_0x1280b0('0x22')](handleError(_0x5b69a3,null));},exports[_0x583a6e('0x31')]=function(_0x1337af,_0x4cb686){const _0x2342a8=_0x583a6e;return _0x1337af['body']['id']&&delete _0x1337af[_0x2342a8('0x32')]['id'],db[_0x2342a8('0x3')][_0x2342a8('0x4')]({'where':{'id':_0x1337af[_0x2342a8('0x0')]['id']}})[_0x2342a8('0x7')](handleEntityNotFound(_0x4cb686,null))[_0x2342a8('0x7')](saveUpdates(_0x1337af[_0x2342a8('0x32')],null))[_0x2342a8('0x7')](respondWithResult(_0x4cb686,null))['catch'](handleError(_0x4cb686,null));},exports[_0x583a6e('0x6')]=function(_0x2c6c3c,_0x4f91f4){const _0x200b93=_0x583a6e;return db[_0x200b93('0x3')][_0x200b93('0x4')]({'where':{'id':_0x2c6c3c['params']['id']}})['then'](handleEntityNotFound(_0x4f91f4,null))[_0x200b93('0x7')](removeEntity(_0x4f91f4,null))[_0x200b93('0x22')](handleError(_0x4f91f4,null));},exports['describe']=function(_0x106e23,_0x13c3b5){const _0x57c1de=_0x583a6e;return db[_0x57c1de('0x3')][_0x57c1de('0x21')]()[_0x57c1de('0x7')](respondWithResult(_0x13c3b5,null))['catch'](handleError(_0x13c3b5,null));}; \ No newline at end of file +const a610_0x8d19=['index','filters','body','length','describe','keys','then','json','VIRTUAL','destroy','key','limit','error','stack','where','status','send','sort','type','create','count','../../mysqldb','map','includeAll','rawAttributes','Content-Range','undefined','findOne','end','sendStatus','options','model','pick','query','name','lodash','offset','fields','attributes','params','set','filter','rows','update','like','catch','include','SquareReport','intersection','show','merge'];(function(_0x4ca3e2,_0x8d19e8){const _0x1ed507=function(_0x221741){while(--_0x221741){_0x4ca3e2['push'](_0x4ca3e2['shift']());}};_0x1ed507(++_0x8d19e8);}(a610_0x8d19,0xbf));const a610_0x1ed5=function(_0x4ca3e2,_0x8d19e8){_0x4ca3e2=_0x4ca3e2-0x0;let _0x1ed507=a610_0x8d19[_0x4ca3e2];return _0x1ed507;};const _0x35956f=a610_0x1ed5;'use strict';const _=require(_0x35956f('0x30')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')('api'),db=require(_0x35956f('0x22'))['db'],{Op}=require('sequelize');function respondWithResult(_0x221741,_0x29b443){return _0x29b443=_0x29b443||0xc8,function(_0x2aa940){const _0x145bc7=a610_0x1ed5;if(_0x2aa940)return _0x221741[_0x145bc7('0x1c')](_0x29b443)[_0x145bc7('0x14')](_0x2aa940);};}function respondWithFilteredResult(_0x143805,_0xcebb2f){return function(_0x4af367){const _0x4d685b=a610_0x1ed5;if(_0x4af367){const _0x56e204=_0x4af367['count'],_0x5b6091=_0xcebb2f[_0x4d685b('0x31')];let _0x1552d3=_0xcebb2f['offset']+_0xcebb2f[_0x4d685b('0x18')],_0x1e01d8;return _0x1552d3>=_0x56e204?(_0x1552d3=_0x56e204,_0x1e01d8=0xc8):_0x1e01d8=0xce,_0x143805[_0x4d685b('0x1c')](_0x1e01d8),_0x143805[_0x4d685b('0x2')](_0x4d685b('0x26'),_0x5b6091+'-'+_0x1552d3+'/'+_0x56e204)[_0x4d685b('0x14')](_0x4af367);}return null;};}function saveUpdates(_0x3a294a){return function(_0x4dcfb7){const _0x1606f5=a610_0x1ed5;if(_0x4dcfb7)return _0x4dcfb7[_0x1606f5('0x5')](_0x3a294a)[_0x1606f5('0x13')](function(_0x3cfe74){return _0x3cfe74;});return null;};}function removeEntity(_0x1e2f07){return function(_0x196ea5){const _0x2cb09f=a610_0x1ed5;if(_0x196ea5)return _0x196ea5[_0x2cb09f('0x16')]()[_0x2cb09f('0x13')](function(){const _0x1b66d4=_0x2cb09f;_0x1e2f07[_0x1b66d4('0x1c')](0xcc)[_0x1b66d4('0x29')]();});};}function handleEntityNotFound(_0x56bde4){return function(_0x219c12){const _0x43c3c6=a610_0x1ed5;return!_0x219c12&&_0x56bde4[_0x43c3c6('0x2a')](0x194),_0x219c12;};}function handleError(_0x1224ed,_0x1dc0b2){return _0x1dc0b2=_0x1dc0b2||0x1f4,function(_0x5b32d0){const _0x545a5b=a610_0x1ed5;logger[_0x545a5b('0x19')](_0x5b32d0[_0x545a5b('0x1a')]),_0x5b32d0[_0x545a5b('0x2f')]&&delete _0x5b32d0[_0x545a5b('0x2f')],_0x1224ed[_0x545a5b('0x1c')](_0x1dc0b2)[_0x545a5b('0x1d')](_0x5b32d0);};}exports[_0x35956f('0xd')]=function(_0x3cd698,_0x3d21fc){const _0x326596=_0x35956f;let _0x387e13={};const _0x46d2c0={},_0x2392b2={'count':0x0,'rows':[]},_0x4d0458=_['map'](db[_0x326596('0x9')][_0x326596('0x25')],function(_0x323e20){const _0x191593=_0x326596;return{'name':_0x323e20['fieldName'],'type':_0x323e20[_0x191593('0x1f')][_0x191593('0x17')]};});_0x46d2c0['model']=_['map'](_0x4d0458,_0x326596('0x2f')),_0x46d2c0[_0x326596('0x2e')]=_['keys'](_0x3cd698[_0x326596('0x2e')]),_0x46d2c0[_0x326596('0xe')]=_[_0x326596('0xa')](_0x46d2c0[_0x326596('0x2c')],_0x46d2c0[_0x326596('0x2e')]),_0x387e13[_0x326596('0x0')]=_[_0x326596('0xa')](_0x46d2c0['model'],qs[_0x326596('0x32')](_0x3cd698['query'][_0x326596('0x32')])),_0x387e13[_0x326596('0x0')]=_0x387e13['attributes'][_0x326596('0x10')]?_0x387e13[_0x326596('0x0')]:_0x46d2c0[_0x326596('0x2c')];typeof _0x3cd698['query']['nolimit']===_0x326596('0x27')&&(_0x387e13['limit']=qs[_0x326596('0x18')](_0x3cd698[_0x326596('0x2e')][_0x326596('0x18')]),_0x387e13['offset']=qs[_0x326596('0x31')](_0x3cd698[_0x326596('0x2e')][_0x326596('0x31')]));_0x387e13['order']=qs[_0x326596('0x1e')](_0x3cd698['query'][_0x326596('0x1e')]),_0x387e13[_0x326596('0x1b')]=qs[_0x326596('0xe')](_[_0x326596('0x2d')](_0x3cd698['query'],_0x46d2c0['filters']),_0x4d0458);_0x3cd698['query'][_0x326596('0x3')]&&(_0x387e13[_0x326596('0x1b')]=_['merge'](_0x387e13[_0x326596('0x1b')],{[Op['or']]:_[_0x326596('0x23')](_0x4d0458,function(_0x2ce59){const _0x43d558=_0x326596;if(_0x2ce59['type']!==_0x43d558('0x15')){const _0x53dc8c={};return _0x53dc8c[_0x2ce59[_0x43d558('0x2f')]]={[Op[_0x43d558('0x6')]]:'%'+_0x3cd698[_0x43d558('0x2e')][_0x43d558('0x3')]+'%'},_0x53dc8c;}})}));_0x387e13=_[_0x326596('0xc')]({},_0x387e13,_0x3cd698['options']);const _0x4cd8a2={'where':_0x387e13['where']};return db[_0x326596('0x9')][_0x326596('0x21')](_0x4cd8a2)['then'](function(_0x5f4fa8){const _0x4d9982=_0x326596;return _0x2392b2['count']=_0x5f4fa8,_0x3cd698[_0x4d9982('0x2e')]['includeAll']&&(_0x387e13['include']=[{'all':!![]}]),db[_0x4d9982('0x9')]['findAll'](_0x387e13);})[_0x326596('0x13')](function(_0x29e89b){const _0xfd26f9=_0x326596;return _0x2392b2[_0xfd26f9('0x4')]=_0x29e89b,_0x2392b2;})[_0x326596('0x13')](respondWithFilteredResult(_0x3d21fc,_0x387e13))[_0x326596('0x7')](handleError(_0x3d21fc,null));},exports[_0x35956f('0xb')]=function(_0x1ef32e,_0x4c9f11){const _0x4af2c3=_0x35956f;let _0x274ff5={'raw':!![],'where':{'id':_0x1ef32e[_0x4af2c3('0x1')]['id']}};const _0x3f98ed={};return _0x3f98ed[_0x4af2c3('0x2c')]=_['keys'](db[_0x4af2c3('0x9')]['rawAttributes']),_0x3f98ed[_0x4af2c3('0x2e')]=_[_0x4af2c3('0x12')](_0x1ef32e['query']),_0x3f98ed[_0x4af2c3('0xe')]=_[_0x4af2c3('0xa')](_0x3f98ed['model'],_0x3f98ed[_0x4af2c3('0x2e')]),_0x274ff5[_0x4af2c3('0x0')]=_[_0x4af2c3('0xa')](_0x3f98ed[_0x4af2c3('0x2c')],qs[_0x4af2c3('0x32')](_0x1ef32e['query'][_0x4af2c3('0x32')])),_0x274ff5['attributes']=_0x274ff5[_0x4af2c3('0x0')][_0x4af2c3('0x10')]?_0x274ff5['attributes']:_0x3f98ed[_0x4af2c3('0x2c')],_0x1ef32e[_0x4af2c3('0x2e')][_0x4af2c3('0x24')]&&(_0x274ff5[_0x4af2c3('0x8')]=[{'all':!![]}]),_0x274ff5=_[_0x4af2c3('0xc')]({},_0x274ff5,_0x1ef32e[_0x4af2c3('0x2b')]),db[_0x4af2c3('0x9')][_0x4af2c3('0x28')](_0x274ff5)['then'](handleEntityNotFound(_0x4c9f11,null))['then'](respondWithResult(_0x4c9f11,null))[_0x4af2c3('0x7')](handleError(_0x4c9f11,null));},exports[_0x35956f('0x20')]=function(_0x479625,_0x55b78d){const _0x3a1deb=_0x35956f;return db[_0x3a1deb('0x9')][_0x3a1deb('0x20')](_0x479625[_0x3a1deb('0xf')],{})[_0x3a1deb('0x13')](respondWithResult(_0x55b78d,0xc9))[_0x3a1deb('0x7')](handleError(_0x55b78d,null));},exports[_0x35956f('0x5')]=function(_0x2c93b5,_0x40b4dc){const _0x2cd676=_0x35956f;return _0x2c93b5[_0x2cd676('0xf')]['id']&&delete _0x2c93b5[_0x2cd676('0xf')]['id'],db['SquareReport'][_0x2cd676('0x28')]({'where':{'id':_0x2c93b5['params']['id']}})[_0x2cd676('0x13')](handleEntityNotFound(_0x40b4dc,null))[_0x2cd676('0x13')](saveUpdates(_0x2c93b5[_0x2cd676('0xf')],null))[_0x2cd676('0x13')](respondWithResult(_0x40b4dc,null))[_0x2cd676('0x7')](handleError(_0x40b4dc,null));},exports['destroy']=function(_0x266749,_0x1fee70){const _0xe3775b=_0x35956f;return db[_0xe3775b('0x9')][_0xe3775b('0x28')]({'where':{'id':_0x266749[_0xe3775b('0x1')]['id']}})[_0xe3775b('0x13')](handleEntityNotFound(_0x1fee70,null))['then'](removeEntity(_0x1fee70,null))[_0xe3775b('0x7')](handleError(_0x1fee70,null));},exports[_0x35956f('0x11')]=function(_0x59486f,_0x160e52){const _0x5a1568=_0x35956f;return db[_0x5a1568('0x9')][_0x5a1568('0x11')]()[_0x5a1568('0x13')](respondWithResult(_0x160e52,null))[_0x5a1568('0x7')](handleError(_0x160e52,null));}; \ No newline at end of file diff --git a/server/api/squareReport/squareReport.model.js b/server/api/squareReport/squareReport.model.js index de0468f..df92bf7 100644 --- a/server/api/squareReport/squareReport.model.js +++ b/server/api/squareReport/squareReport.model.js @@ -1 +1 @@ -const a611_0x300d=['./squareReport.attributes','leaveAt','uniqueid','SquareReport','define','project_name','exports','uid_pname'];(function(_0x4dec87,_0x300d1e){const _0x43923e=function(_0x60ffb5){while(--_0x60ffb5){_0x4dec87['push'](_0x4dec87['shift']());}};_0x43923e(++_0x300d1e);}(a611_0x300d,0x81));const a611_0x4392=function(_0x4dec87,_0x300d1e){_0x4dec87=_0x4dec87-0x0;let _0x43923e=a611_0x300d[_0x4dec87];return _0x43923e;};const _0x4f6b8e=a611_0x4392;'use strict';const attributes=require(_0x4f6b8e('0x7'));module[_0x4f6b8e('0x5')]=function(_0x60ffb5){const _0x35198a=_0x4f6b8e,_0x16491d=_0x60ffb5[_0x35198a('0x3')](_0x35198a('0x2'),attributes,{'tableName':'report_square','paranoid':![],'indexes':[{'name':_0x35198a('0x6'),'fields':[_0x35198a('0x1'),_0x35198a('0x4')]},{'name':'leaveAt','fields':[_0x35198a('0x0')]}],'timestamps':!![]});return _0x16491d;}; \ No newline at end of file +const a611_0x4be4=['exports','uid_pname','SquareReport','./squareReport.attributes','define','uniqueid','report_square'];(function(_0x3a2b50,_0x4be494){const _0x1f8d59=function(_0x1b98fe){while(--_0x1b98fe){_0x3a2b50['push'](_0x3a2b50['shift']());}};_0x1f8d59(++_0x4be494);}(a611_0x4be4,0x1ec));const a611_0x1f8d=function(_0x3a2b50,_0x4be494){_0x3a2b50=_0x3a2b50-0x0;let _0x1f8d59=a611_0x4be4[_0x3a2b50];return _0x1f8d59;};const _0x2fbb2b=a611_0x1f8d;'use strict';const attributes=require(_0x2fbb2b('0x1'));module[_0x2fbb2b('0x5')]=function(_0x1b98fe){const _0x125c0e=_0x2fbb2b,_0x1fb55a=_0x1b98fe[_0x125c0e('0x2')](_0x125c0e('0x0'),attributes,{'tableName':_0x125c0e('0x4'),'paranoid':![],'indexes':[{'name':_0x125c0e('0x6'),'fields':[_0x125c0e('0x3'),'project_name']},{'name':'leaveAt','fields':['leaveAt']}],'timestamps':!![]});return _0x1fb55a;}; \ No newline at end of file diff --git a/server/api/squareReport/squareReport.rpc.js b/server/api/squareReport/squareReport.rpc.js index 8cc2f3c..68aff95 100644 --- a/server/api/squareReport/squareReport.rpc.js +++ b/server/api/squareReport/squareReport.rpc.js @@ -1 +1 @@ -const a612_0x3db2=['limit','then','attributes','CreateSquareReport','SquareReport','update','message','raw','error','create','debug','info','stringify','catch','where','UpdateSquareReport','options','body','../../config/logger','rpc'];(function(_0x128ca3,_0x3db273){const _0x71c142=function(_0x740acc){while(--_0x740acc){_0x128ca3['push'](_0x128ca3['shift']());}};_0x71c142(++_0x3db273);}(a612_0x3db2,0x80));const a612_0x71c1=function(_0x128ca3,_0x3db273){_0x128ca3=_0x128ca3-0x0;let _0x71c142=a612_0x3db2[_0x128ca3];return _0x71c142;};const _0x435e89=a612_0x71c1;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x435e89('0xa'))(_0x435e89('0xb'));exports[_0x435e89('0xf')]=function(_0x740acc){const _0x37285b=this;return new Promise(function(_0x36bc93,_0x3ab824){const _0x2d92d0=a612_0x71c1;return db[_0x2d92d0('0x10')][_0x2d92d0('0x1')](_0x740acc[_0x2d92d0('0x9')],{'raw':_0x740acc[_0x2d92d0('0x8')]?_0x740acc['options'][_0x2d92d0('0x13')]===undefined?!![]:![]:!![]})[_0x2d92d0('0xd')](function(_0x298195){const _0x53595f=_0x2d92d0;logger[_0x53595f('0x3')](_0x53595f('0xf'),_0x740acc),logger[_0x53595f('0x2')](_0x53595f('0xf'),_0x740acc,JSON[_0x53595f('0x4')](_0x298195)),_0x36bc93(_0x298195);})[_0x2d92d0('0x5')](function(_0xdb1819){const _0x61f6c9=_0x2d92d0;logger[_0x61f6c9('0x0')](_0x61f6c9('0xf'),_0xdb1819[_0x61f6c9('0x12')],_0x740acc),_0x3ab824(_0x37285b[_0x61f6c9('0x0')](0x1f4,_0xdb1819[_0x61f6c9('0x12')]));});});},exports[_0x435e89('0x7')]=function(_0x53c331){const _0x457cf5=this;return new Promise(function(_0x1bcf4d,_0x5d8fb7){const _0x57ca54=a612_0x71c1;return db[_0x57ca54('0x10')][_0x57ca54('0x11')](_0x53c331['body'],{'raw':_0x53c331[_0x57ca54('0x8')]?_0x53c331['options']['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x53c331[_0x57ca54('0x8')]?_0x53c331['options'][_0x57ca54('0x6')]||null:null,'attributes':_0x53c331[_0x57ca54('0x8')]?_0x53c331['options'][_0x57ca54('0xe')]||null:null,'limit':_0x53c331[_0x57ca54('0x8')]?_0x53c331[_0x57ca54('0x8')][_0x57ca54('0xc')]||null:null})[_0x57ca54('0xd')](function(_0x495dba){const _0x5032de=_0x57ca54;logger[_0x5032de('0x3')]('UpdateSquareReport',_0x53c331),logger['debug'](_0x5032de('0x7'),_0x53c331,JSON['stringify'](_0x495dba)),_0x1bcf4d(_0x495dba);})[_0x57ca54('0x5')](function(_0x35a199){const _0x4822e2=_0x57ca54;logger[_0x4822e2('0x0')](_0x4822e2('0x7'),_0x35a199['message'],_0x53c331),_0x5d8fb7(_0x457cf5[_0x4822e2('0x0')](0x1f4,_0x35a199[_0x4822e2('0x12')]));});});}; \ No newline at end of file +const a612_0x2e55=['catch','debug','limit','CreateSquareReport','info','../../mysqldb','error','body','where','update','UpdateSquareReport','SquareReport','rpc','create','options','attributes','message','stringify','raw','then'];(function(_0x4f2ceb,_0x2e55df){const _0x4f5450=function(_0x3f9d6a){while(--_0x3f9d6a){_0x4f2ceb['push'](_0x4f2ceb['shift']());}};_0x4f5450(++_0x2e55df);}(a612_0x2e55,0x77));const a612_0x4f54=function(_0x4f2ceb,_0x2e55df){_0x4f2ceb=_0x4f2ceb-0x0;let _0x4f5450=a612_0x2e55[_0x4f2ceb];return _0x4f5450;};const _0xc97a98=a612_0x4f54;'use strict';const db=require(_0xc97a98('0x6'))['db'],logger=require('../../config/logger')(_0xc97a98('0xd'));exports[_0xc97a98('0x4')]=function(_0x3f9d6a){const _0x290cee=this;return new Promise(function(_0x1cdf75,_0x1c7961){const _0x607f0c=a612_0x4f54;return db[_0x607f0c('0xc')][_0x607f0c('0xe')](_0x3f9d6a[_0x607f0c('0x8')],{'raw':_0x3f9d6a[_0x607f0c('0xf')]?_0x3f9d6a[_0x607f0c('0xf')][_0x607f0c('0x13')]===undefined?!![]:![]:!![]})[_0x607f0c('0x0')](function(_0x5b7555){const _0xd2493e=_0x607f0c;logger[_0xd2493e('0x5')](_0xd2493e('0x4'),_0x3f9d6a),logger[_0xd2493e('0x2')](_0xd2493e('0x4'),_0x3f9d6a,JSON[_0xd2493e('0x12')](_0x5b7555)),_0x1cdf75(_0x5b7555);})[_0x607f0c('0x1')](function(_0xa2b39c){const _0x1a65da=_0x607f0c;logger['error'](_0x1a65da('0x4'),_0xa2b39c[_0x1a65da('0x11')],_0x3f9d6a),_0x1c7961(_0x290cee['error'](0x1f4,_0xa2b39c[_0x1a65da('0x11')]));});});},exports[_0xc97a98('0xb')]=function(_0x2141e1){const _0x23a076=this;return new Promise(function(_0x30d46f,_0x459791){const _0x5dab90=a612_0x4f54;return db[_0x5dab90('0xc')][_0x5dab90('0xa')](_0x2141e1['body'],{'raw':_0x2141e1[_0x5dab90('0xf')]?_0x2141e1[_0x5dab90('0xf')][_0x5dab90('0x13')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x2141e1[_0x5dab90('0xf')]?_0x2141e1['options'][_0x5dab90('0x9')]||null:null,'attributes':_0x2141e1[_0x5dab90('0xf')]?_0x2141e1['options'][_0x5dab90('0x10')]||null:null,'limit':_0x2141e1[_0x5dab90('0xf')]?_0x2141e1[_0x5dab90('0xf')][_0x5dab90('0x3')]||null:null})['then'](function(_0x4318b7){const _0x5244d2=_0x5dab90;logger[_0x5244d2('0x5')](_0x5244d2('0xb'),_0x2141e1),logger[_0x5244d2('0x2')]('UpdateSquareReport',_0x2141e1,JSON['stringify'](_0x4318b7)),_0x30d46f(_0x4318b7);})[_0x5dab90('0x1')](function(_0x257e30){const _0x10644f=_0x5dab90;logger[_0x10644f('0x7')](_0x10644f('0xb'),_0x257e30[_0x10644f('0x11')],_0x2141e1),_0x459791(_0x23a076[_0x10644f('0x7')](0x1f4,_0x257e30['message']));});});}; \ No newline at end of file diff --git a/server/api/squareReportDetail/index.js b/server/api/squareReportDetail/index.js index 0aac403..056c53d 100644 --- a/server/api/squareReportDetail/index.js +++ b/server/api/squareReportDetail/index.js @@ -1 +1 @@ -const a613_0x544b=['isAuthenticated','update','/describe','/:id','delete','exports','post','express','destroy','put','../../components/auth/service','create','show','Router','./squareReportDetail.controller','get'];(function(_0x39da95,_0x544b99){const _0x33a46e=function(_0x3986ab){while(--_0x3986ab){_0x39da95['push'](_0x39da95['shift']());}};_0x33a46e(++_0x544b99);}(a613_0x544b,0x81));const a613_0x33a4=function(_0x39da95,_0x544b99){_0x39da95=_0x39da95-0x0;let _0x33a46e=a613_0x544b[_0x39da95];return _0x33a46e;};const _0xa6da4=a613_0x33a4;'use strict';const express=require(_0xa6da4('0x6')),router=express[_0xa6da4('0xc')](),auth=require(_0xa6da4('0x9')),controller=require(_0xa6da4('0xd'));router['get']('/',auth['isAuthenticated'](),controller['index']),router[_0xa6da4('0xe')](_0xa6da4('0x1'),auth[_0xa6da4('0xf')](),controller['describe']),router[_0xa6da4('0xe')](_0xa6da4('0x2'),auth[_0xa6da4('0xf')](),controller[_0xa6da4('0xb')]),router[_0xa6da4('0x5')]('/',auth[_0xa6da4('0xf')](),controller[_0xa6da4('0xa')]),router[_0xa6da4('0x8')](_0xa6da4('0x2'),auth[_0xa6da4('0xf')](),controller[_0xa6da4('0x0')]),router[_0xa6da4('0x3')]('/:id',auth[_0xa6da4('0xf')](),controller[_0xa6da4('0x7')]),module[_0xa6da4('0x4')]=router; \ No newline at end of file +const a613_0x49af=['delete','exports','update','../../components/auth/service','isAuthenticated','/describe','describe','/:id','create','put','get','express','Router','show','./squareReportDetail.controller'];(function(_0x3a2dd6,_0x49afd2){const _0x43b364=function(_0x1c2b17){while(--_0x1c2b17){_0x3a2dd6['push'](_0x3a2dd6['shift']());}};_0x43b364(++_0x49afd2);}(a613_0x49af,0x1c1));const a613_0x43b3=function(_0x3a2dd6,_0x49afd2){_0x3a2dd6=_0x3a2dd6-0x0;let _0x43b364=a613_0x49af[_0x3a2dd6];return _0x43b364;};const _0x6d6284=a613_0x43b3;'use strict';const express=require(_0x6d6284('0xc')),router=express[_0x6d6284('0xd')](),auth=require(_0x6d6284('0x4')),controller=require(_0x6d6284('0x0'));router[_0x6d6284('0xb')]('/',auth[_0x6d6284('0x5')](),controller['index']),router[_0x6d6284('0xb')](_0x6d6284('0x6'),auth[_0x6d6284('0x5')](),controller[_0x6d6284('0x7')]),router['get'](_0x6d6284('0x8'),auth[_0x6d6284('0x5')](),controller[_0x6d6284('0xe')]),router['post']('/',auth['isAuthenticated'](),controller[_0x6d6284('0x9')]),router[_0x6d6284('0xa')](_0x6d6284('0x8'),auth['isAuthenticated'](),controller[_0x6d6284('0x3')]),router[_0x6d6284('0x1')](_0x6d6284('0x8'),auth[_0x6d6284('0x5')](),controller['destroy']),module[_0x6d6284('0x2')]=router; \ No newline at end of file diff --git a/server/api/squareReportDetail/squareReportDetail.attributes.js b/server/api/squareReportDetail/squareReportDetail.attributes.js index fb99a32..7124bbb 100644 --- a/server/api/squareReportDetail/squareReportDetail.attributes.js +++ b/server/api/squareReportDetail/squareReportDetail.attributes.js @@ -1 +1 @@ -const a614_0x28c6=['STRING','exports'];(function(_0x2bef8f,_0x28c6ac){const _0x298c07=function(_0x4d5f49){while(--_0x4d5f49){_0x2bef8f['push'](_0x2bef8f['shift']());}};_0x298c07(++_0x28c6ac);}(a614_0x28c6,0xe8));const a614_0x298c=function(_0x2bef8f,_0x28c6ac){_0x2bef8f=_0x2bef8f-0x0;let _0x298c07=a614_0x28c6[_0x2bef8f];return _0x298c07;};const _0x212e2f=a614_0x298c;'use strict';const Sequelize=require('sequelize');module[_0x212e2f('0x1')]={'uniqueid':{'type':Sequelize[_0x212e2f('0x0')]},'node':{'type':Sequelize['STRING']},'application':{'type':Sequelize[_0x212e2f('0x0')]},'data':{'type':Sequelize['TEXT']},'project_name':{'type':Sequelize[_0x212e2f('0x0')]},'callerid':{'type':Sequelize[_0x212e2f('0x0')]}}; \ No newline at end of file +const a614_0x2792=['TEXT','exports','STRING','sequelize'];(function(_0x28378e,_0x2792cf){const _0x568e83=function(_0x9c3bbe){while(--_0x9c3bbe){_0x28378e['push'](_0x28378e['shift']());}};_0x568e83(++_0x2792cf);}(a614_0x2792,0x152));const a614_0x568e=function(_0x28378e,_0x2792cf){_0x28378e=_0x28378e-0x0;let _0x568e83=a614_0x2792[_0x28378e];return _0x568e83;};const _0x4c6e7b=a614_0x568e;'use strict';const Sequelize=require(_0x4c6e7b('0x1'));module[_0x4c6e7b('0x3')]={'uniqueid':{'type':Sequelize[_0x4c6e7b('0x0')]},'node':{'type':Sequelize[_0x4c6e7b('0x0')]},'application':{'type':Sequelize['STRING']},'data':{'type':Sequelize[_0x4c6e7b('0x2')]},'project_name':{'type':Sequelize[_0x4c6e7b('0x0')]},'callerid':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/squareReportDetail/squareReportDetail.controller.js b/server/api/squareReportDetail/squareReportDetail.controller.js index 42cebb4..e30d68b 100644 --- a/server/api/squareReportDetail/squareReportDetail.controller.js +++ b/server/api/squareReportDetail/squareReportDetail.controller.js @@ -1 +1 @@ -const a615_0x14ef=['key','name','type','Content-Range','include','undefined','attributes','describe','filter','options','error','then','sendStatus','pick','query','filters','../../components/parsers/qs','SquareDetailsReport','limit','lodash','sort','fields','sequelize','params','where','stack','update','includeAll','rows','../../mysqldb','intersection','api','map','status','index','findOne','merge','body','create','offset','nolimit','catch','model','length','set','json','order','keys','rawAttributes','findAll','count','end','VIRTUAL'];(function(_0x2574b2,_0x14efd8){const _0x49dfca=function(_0x1816e4){while(--_0x1816e4){_0x2574b2['push'](_0x2574b2['shift']());}};_0x49dfca(++_0x14efd8);}(a615_0x14ef,0x17d));const a615_0x49df=function(_0x2574b2,_0x14efd8){_0x2574b2=_0x2574b2-0x0;let _0x49dfca=a615_0x14ef[_0x2574b2];return _0x49dfca;};const _0x4eebba=a615_0x49df;'use strict';const _=require(_0x4eebba('0x9')),qs=require(_0x4eebba('0x6')),logger=require('../../config/logger')(_0x4eebba('0x15')),db=require(_0x4eebba('0x13'))['db'],{Op}=require(_0x4eebba('0xc'));function respondWithResult(_0x1816e4,_0x229036){return _0x229036=_0x229036||0xc8,function(_0x44ceec){const _0x4e76d2=a615_0x49df;if(_0x44ceec)return _0x1816e4['status'](_0x229036)[_0x4e76d2('0x23')](_0x44ceec);};}function respondWithFilteredResult(_0x11b729,_0x18a3ee){return function(_0x58f961){const _0xea0dae=a615_0x49df;if(_0x58f961){const _0x2a22a6=_0x58f961[_0xea0dae('0x28')],_0x85a4da=_0x18a3ee[_0xea0dae('0x1d')];let _0xf16832=_0x18a3ee[_0xea0dae('0x1d')]+_0x18a3ee[_0xea0dae('0x8')],_0x12e397;return _0xf16832>=_0x2a22a6?(_0xf16832=_0x2a22a6,_0x12e397=0xc8):_0x12e397=0xce,_0x11b729[_0xea0dae('0x17')](_0x12e397),_0x11b729[_0xea0dae('0x22')](_0xea0dae('0x2e'),_0x85a4da+'-'+_0xf16832+'/'+_0x2a22a6)['json'](_0x58f961);}return null;};}function saveUpdates(_0x475dfc){return function(_0x3638b2){const _0x428196=a615_0x49df;if(_0x3638b2)return _0x3638b2[_0x428196('0x10')](_0x475dfc)['then'](function(_0x3b2fb5){return _0x3b2fb5;});return null;};}function removeEntity(_0x528cbb){return function(_0x345d55){if(_0x345d55)return _0x345d55['destroy']()['then'](function(){const _0x157464=a615_0x49df;_0x528cbb[_0x157464('0x17')](0xcc)[_0x157464('0x29')]();});};}function handleEntityNotFound(_0x1c18c2){return function(_0x85a1cf){const _0x325887=a615_0x49df;return!_0x85a1cf&&_0x1c18c2[_0x325887('0x2')](0x194),_0x85a1cf;};}function handleError(_0x37f681,_0x2d0e9d){return _0x2d0e9d=_0x2d0e9d||0x1f4,function(_0xb77079){const _0x59f68f=a615_0x49df;logger[_0x59f68f('0x0')](_0xb77079[_0x59f68f('0xf')]),_0xb77079['name']&&delete _0xb77079['name'],_0x37f681[_0x59f68f('0x17')](_0x2d0e9d)['send'](_0xb77079);};}exports[_0x4eebba('0x18')]=function(_0x1a0e30,_0x2af2e9){const _0x2b603a=_0x4eebba;let _0x43b81c={};const _0x29cd51={},_0x149974={'count':0x0,'rows':[]},_0x500765=_[_0x2b603a('0x16')](db[_0x2b603a('0x7')][_0x2b603a('0x26')],function(_0x29feff){const _0x454e11=_0x2b603a;return{'name':_0x29feff['fieldName'],'type':_0x29feff[_0x454e11('0x2d')][_0x454e11('0x2b')]};});_0x29cd51[_0x2b603a('0x20')]=_[_0x2b603a('0x16')](_0x500765,_0x2b603a('0x2c')),_0x29cd51[_0x2b603a('0x4')]=_[_0x2b603a('0x25')](_0x1a0e30[_0x2b603a('0x4')]),_0x29cd51[_0x2b603a('0x5')]=_['intersection'](_0x29cd51['model'],_0x29cd51[_0x2b603a('0x4')]),_0x43b81c[_0x2b603a('0x31')]=_[_0x2b603a('0x14')](_0x29cd51[_0x2b603a('0x20')],qs['fields'](_0x1a0e30['query'][_0x2b603a('0xb')])),_0x43b81c[_0x2b603a('0x31')]=_0x43b81c['attributes'][_0x2b603a('0x21')]?_0x43b81c[_0x2b603a('0x31')]:_0x29cd51[_0x2b603a('0x20')];typeof _0x1a0e30[_0x2b603a('0x4')][_0x2b603a('0x1e')]===_0x2b603a('0x30')&&(_0x43b81c[_0x2b603a('0x8')]=qs['limit'](_0x1a0e30[_0x2b603a('0x4')][_0x2b603a('0x8')]),_0x43b81c[_0x2b603a('0x1d')]=qs[_0x2b603a('0x1d')](_0x1a0e30['query'][_0x2b603a('0x1d')]));_0x43b81c[_0x2b603a('0x24')]=qs[_0x2b603a('0xa')](_0x1a0e30[_0x2b603a('0x4')][_0x2b603a('0xa')]),_0x43b81c['where']=qs[_0x2b603a('0x5')](_[_0x2b603a('0x3')](_0x1a0e30[_0x2b603a('0x4')],_0x29cd51['filters']),_0x500765);_0x1a0e30[_0x2b603a('0x4')][_0x2b603a('0x33')]&&(_0x43b81c[_0x2b603a('0xe')]=_[_0x2b603a('0x1a')](_0x43b81c[_0x2b603a('0xe')],{[Op['or']]:_[_0x2b603a('0x16')](_0x500765,function(_0x29808f){const _0x2f43c7=_0x2b603a;if(_0x29808f['type']!==_0x2f43c7('0x2a')){const _0x5312c1={};return _0x5312c1[_0x29808f[_0x2f43c7('0x2c')]]={[Op['like']]:'%'+_0x1a0e30['query'][_0x2f43c7('0x33')]+'%'},_0x5312c1;}})}));_0x43b81c=_[_0x2b603a('0x1a')]({},_0x43b81c,_0x1a0e30[_0x2b603a('0x34')]);const _0xd5c815={'where':_0x43b81c['where']};return db[_0x2b603a('0x7')]['count'](_0xd5c815)[_0x2b603a('0x1')](function(_0x891c90){const _0x47d8f5=_0x2b603a;return _0x149974[_0x47d8f5('0x28')]=_0x891c90,_0x1a0e30['query'][_0x47d8f5('0x11')]&&(_0x43b81c[_0x47d8f5('0x2f')]=[{'all':!![]}]),db['SquareDetailsReport'][_0x47d8f5('0x27')](_0x43b81c);})[_0x2b603a('0x1')](function(_0x142311){const _0x2e53b0=_0x2b603a;return _0x149974[_0x2e53b0('0x12')]=_0x142311,_0x149974;})['then'](respondWithFilteredResult(_0x2af2e9,_0x43b81c))['catch'](handleError(_0x2af2e9,null));},exports['show']=function(_0x5bfbdf,_0x1a3b39){const _0x36114c=_0x4eebba;let _0x4de03d={'raw':!![],'where':{'id':_0x5bfbdf[_0x36114c('0xd')]['id']}};const _0x23779c={};return _0x23779c['model']=_[_0x36114c('0x25')](db[_0x36114c('0x7')][_0x36114c('0x26')]),_0x23779c['query']=_[_0x36114c('0x25')](_0x5bfbdf['query']),_0x23779c[_0x36114c('0x5')]=_[_0x36114c('0x14')](_0x23779c[_0x36114c('0x20')],_0x23779c[_0x36114c('0x4')]),_0x4de03d[_0x36114c('0x31')]=_[_0x36114c('0x14')](_0x23779c[_0x36114c('0x20')],qs[_0x36114c('0xb')](_0x5bfbdf[_0x36114c('0x4')]['fields'])),_0x4de03d['attributes']=_0x4de03d['attributes']['length']?_0x4de03d[_0x36114c('0x31')]:_0x23779c['model'],_0x5bfbdf['query'][_0x36114c('0x11')]&&(_0x4de03d['include']=[{'all':!![]}]),_0x4de03d=_[_0x36114c('0x1a')]({},_0x4de03d,_0x5bfbdf[_0x36114c('0x34')]),db['SquareDetailsReport'][_0x36114c('0x19')](_0x4de03d)[_0x36114c('0x1')](handleEntityNotFound(_0x1a3b39,null))['then'](respondWithResult(_0x1a3b39,null))[_0x36114c('0x1f')](handleError(_0x1a3b39,null));},exports[_0x4eebba('0x1c')]=function(_0x5b032a,_0x4e0014){const _0x32a31c=_0x4eebba;return db[_0x32a31c('0x7')]['create'](_0x5b032a[_0x32a31c('0x1b')],{})[_0x32a31c('0x1')](respondWithResult(_0x4e0014,0xc9))['catch'](handleError(_0x4e0014,null));},exports[_0x4eebba('0x10')]=function(_0x1731ea,_0x22bcb6){const _0x3b2749=_0x4eebba;return _0x1731ea[_0x3b2749('0x1b')]['id']&&delete _0x1731ea[_0x3b2749('0x1b')]['id'],db[_0x3b2749('0x7')][_0x3b2749('0x19')]({'where':{'id':_0x1731ea[_0x3b2749('0xd')]['id']}})[_0x3b2749('0x1')](handleEntityNotFound(_0x22bcb6,null))[_0x3b2749('0x1')](saveUpdates(_0x1731ea[_0x3b2749('0x1b')],null))[_0x3b2749('0x1')](respondWithResult(_0x22bcb6,null))[_0x3b2749('0x1f')](handleError(_0x22bcb6,null));},exports['destroy']=function(_0x1b1e5b,_0x1e7844){const _0x46832b=_0x4eebba;return db[_0x46832b('0x7')][_0x46832b('0x19')]({'where':{'id':_0x1b1e5b[_0x46832b('0xd')]['id']}})[_0x46832b('0x1')](handleEntityNotFound(_0x1e7844,null))[_0x46832b('0x1')](removeEntity(_0x1e7844,null))['catch'](handleError(_0x1e7844,null));},exports['describe']=function(_0x45876e,_0x1bcf98){const _0x3b4a55=_0x4eebba;return db[_0x3b4a55('0x7')][_0x3b4a55('0x32')]()['then'](respondWithResult(_0x1bcf98,null))[_0x3b4a55('0x1f')](handleError(_0x1bcf98,null));}; \ No newline at end of file +const a615_0x44ce=['findOne','params','body','findAll','undefined','error','like','nolimit','end','merge','model','limit','query','stack','show','count','fields','create','status','lodash','include','intersection','destroy','attributes','type','../../mysqldb','SquareDetailsReport','sequelize','includeAll','options','api','length','fieldName','then','where','update','../../config/logger','name','../../components/parsers/qs','rawAttributes','describe','rows','offset','filters','keys','VIRTUAL','json','filter','map','catch','sort'];(function(_0x56d07c,_0x44ceb1){const _0x2cb1df=function(_0x578289){while(--_0x578289){_0x56d07c['push'](_0x56d07c['shift']());}};_0x2cb1df(++_0x44ceb1);}(a615_0x44ce,0x108));const a615_0x2cb1=function(_0x56d07c,_0x44ceb1){_0x56d07c=_0x56d07c-0x0;let _0x2cb1df=a615_0x44ce[_0x56d07c];return _0x2cb1df;};const _0x432a0b=a615_0x2cb1;'use strict';const _=require(_0x432a0b('0xa')),qs=require(_0x432a0b('0x1d')),logger=require(_0x432a0b('0x1b'))(_0x432a0b('0x15')),db=require(_0x432a0b('0x10'))['db'],{Op}=require(_0x432a0b('0x12'));function respondWithResult(_0x578289,_0x241dbf){return _0x241dbf=_0x241dbf||0xc8,function(_0x115df9){const _0x55db8f=a615_0x2cb1;if(_0x115df9)return _0x578289[_0x55db8f('0x9')](_0x241dbf)[_0x55db8f('0x25')](_0x115df9);};}function respondWithFilteredResult(_0x5eb635,_0x3886ea){return function(_0x4bc23a){const _0x13ab2b=a615_0x2cb1;if(_0x4bc23a){const _0x1e74d0=_0x4bc23a['count'],_0x1e683a=_0x3886ea[_0x13ab2b('0x21')];let _0x58d4db=_0x3886ea['offset']+_0x3886ea[_0x13ab2b('0x2')],_0x4b5f23;return _0x58d4db>=_0x1e74d0?(_0x58d4db=_0x1e74d0,_0x4b5f23=0xc8):_0x4b5f23=0xce,_0x5eb635['status'](_0x4b5f23),_0x5eb635['set']('Content-Range',_0x1e683a+'-'+_0x58d4db+'/'+_0x1e74d0)[_0x13ab2b('0x25')](_0x4bc23a);}return null;};}function saveUpdates(_0x168e56){return function(_0xac1814){const _0x5d4710=a615_0x2cb1;if(_0xac1814)return _0xac1814[_0x5d4710('0x1a')](_0x168e56)['then'](function(_0x6876c5){return _0x6876c5;});return null;};}function removeEntity(_0xf07d6d){return function(_0x6ad99a){const _0x5d8165=a615_0x2cb1;if(_0x6ad99a)return _0x6ad99a[_0x5d8165('0xd')]()[_0x5d8165('0x18')](function(){const _0x29b04f=_0x5d8165;_0xf07d6d[_0x29b04f('0x9')](0xcc)[_0x29b04f('0x32')]();});};}function handleEntityNotFound(_0x212ee2){return function(_0x2aba6d){return!_0x2aba6d&&_0x212ee2['sendStatus'](0x194),_0x2aba6d;};}function handleError(_0x586400,_0x441b2e){return _0x441b2e=_0x441b2e||0x1f4,function(_0x4365d7){const _0x1491d2=a615_0x2cb1;logger[_0x1491d2('0x2f')](_0x4365d7[_0x1491d2('0x4')]),_0x4365d7[_0x1491d2('0x1c')]&&delete _0x4365d7[_0x1491d2('0x1c')],_0x586400['status'](_0x441b2e)['send'](_0x4365d7);};}exports['index']=function(_0x426032,_0x42391c){const _0x487c67=_0x432a0b;let _0x2064c0={};const _0x4a4180={},_0x4d9b86={'count':0x0,'rows':[]},_0x198721=_['map'](db[_0x487c67('0x11')][_0x487c67('0x1e')],function(_0x23da92){const _0x32f910=_0x487c67;return{'name':_0x23da92[_0x32f910('0x17')],'type':_0x23da92[_0x32f910('0xf')]['key']};});_0x4a4180[_0x487c67('0x1')]=_['map'](_0x198721,_0x487c67('0x1c')),_0x4a4180[_0x487c67('0x3')]=_[_0x487c67('0x23')](_0x426032[_0x487c67('0x3')]),_0x4a4180[_0x487c67('0x22')]=_[_0x487c67('0xc')](_0x4a4180[_0x487c67('0x1')],_0x4a4180[_0x487c67('0x3')]),_0x2064c0['attributes']=_[_0x487c67('0xc')](_0x4a4180[_0x487c67('0x1')],qs['fields'](_0x426032[_0x487c67('0x3')][_0x487c67('0x7')])),_0x2064c0[_0x487c67('0xe')]=_0x2064c0['attributes'][_0x487c67('0x16')]?_0x2064c0[_0x487c67('0xe')]:_0x4a4180[_0x487c67('0x1')];typeof _0x426032[_0x487c67('0x3')][_0x487c67('0x31')]===_0x487c67('0x2e')&&(_0x2064c0[_0x487c67('0x2')]=qs['limit'](_0x426032[_0x487c67('0x3')][_0x487c67('0x2')]),_0x2064c0['offset']=qs[_0x487c67('0x21')](_0x426032['query']['offset']));_0x2064c0['order']=qs[_0x487c67('0x29')](_0x426032[_0x487c67('0x3')][_0x487c67('0x29')]),_0x2064c0[_0x487c67('0x19')]=qs[_0x487c67('0x22')](_['pick'](_0x426032['query'],_0x4a4180[_0x487c67('0x22')]),_0x198721);_0x426032[_0x487c67('0x3')][_0x487c67('0x26')]&&(_0x2064c0[_0x487c67('0x19')]=_[_0x487c67('0x0')](_0x2064c0[_0x487c67('0x19')],{[Op['or']]:_[_0x487c67('0x27')](_0x198721,function(_0x436aab){const _0xf64d8=_0x487c67;if(_0x436aab['type']!==_0xf64d8('0x24')){const _0x4963b5={};return _0x4963b5[_0x436aab[_0xf64d8('0x1c')]]={[Op[_0xf64d8('0x30')]]:'%'+_0x426032[_0xf64d8('0x3')][_0xf64d8('0x26')]+'%'},_0x4963b5;}})}));_0x2064c0=_[_0x487c67('0x0')]({},_0x2064c0,_0x426032[_0x487c67('0x14')]);const _0x240ba4={'where':_0x2064c0['where']};return db[_0x487c67('0x11')][_0x487c67('0x6')](_0x240ba4)[_0x487c67('0x18')](function(_0x58d990){const _0x5c4544=_0x487c67;return _0x4d9b86[_0x5c4544('0x6')]=_0x58d990,_0x426032['query'][_0x5c4544('0x13')]&&(_0x2064c0[_0x5c4544('0xb')]=[{'all':!![]}]),db[_0x5c4544('0x11')][_0x5c4544('0x2d')](_0x2064c0);})[_0x487c67('0x18')](function(_0x2c4d8a){const _0x3c7bf4=_0x487c67;return _0x4d9b86[_0x3c7bf4('0x20')]=_0x2c4d8a,_0x4d9b86;})['then'](respondWithFilteredResult(_0x42391c,_0x2064c0))[_0x487c67('0x28')](handleError(_0x42391c,null));},exports[_0x432a0b('0x5')]=function(_0x226ac8,_0x15f6a5){const _0x2b71b2=_0x432a0b;let _0x33d721={'raw':!![],'where':{'id':_0x226ac8[_0x2b71b2('0x2b')]['id']}};const _0x61b120={};return _0x61b120[_0x2b71b2('0x1')]=_['keys'](db[_0x2b71b2('0x11')]['rawAttributes']),_0x61b120[_0x2b71b2('0x3')]=_[_0x2b71b2('0x23')](_0x226ac8[_0x2b71b2('0x3')]),_0x61b120['filters']=_[_0x2b71b2('0xc')](_0x61b120[_0x2b71b2('0x1')],_0x61b120[_0x2b71b2('0x3')]),_0x33d721[_0x2b71b2('0xe')]=_[_0x2b71b2('0xc')](_0x61b120[_0x2b71b2('0x1')],qs[_0x2b71b2('0x7')](_0x226ac8['query'][_0x2b71b2('0x7')])),_0x33d721[_0x2b71b2('0xe')]=_0x33d721['attributes']['length']?_0x33d721[_0x2b71b2('0xe')]:_0x61b120['model'],_0x226ac8[_0x2b71b2('0x3')][_0x2b71b2('0x13')]&&(_0x33d721[_0x2b71b2('0xb')]=[{'all':!![]}]),_0x33d721=_['merge']({},_0x33d721,_0x226ac8[_0x2b71b2('0x14')]),db[_0x2b71b2('0x11')]['findOne'](_0x33d721)[_0x2b71b2('0x18')](handleEntityNotFound(_0x15f6a5,null))[_0x2b71b2('0x18')](respondWithResult(_0x15f6a5,null))[_0x2b71b2('0x28')](handleError(_0x15f6a5,null));},exports[_0x432a0b('0x8')]=function(_0x57c2e1,_0x3c25c2){const _0x4a88eb=_0x432a0b;return db[_0x4a88eb('0x11')]['create'](_0x57c2e1[_0x4a88eb('0x2c')],{})[_0x4a88eb('0x18')](respondWithResult(_0x3c25c2,0xc9))[_0x4a88eb('0x28')](handleError(_0x3c25c2,null));},exports[_0x432a0b('0x1a')]=function(_0x925fd3,_0x320659){const _0x4aa670=_0x432a0b;return _0x925fd3['body']['id']&&delete _0x925fd3[_0x4aa670('0x2c')]['id'],db[_0x4aa670('0x11')][_0x4aa670('0x2a')]({'where':{'id':_0x925fd3['params']['id']}})[_0x4aa670('0x18')](handleEntityNotFound(_0x320659,null))[_0x4aa670('0x18')](saveUpdates(_0x925fd3[_0x4aa670('0x2c')],null))[_0x4aa670('0x18')](respondWithResult(_0x320659,null))[_0x4aa670('0x28')](handleError(_0x320659,null));},exports[_0x432a0b('0xd')]=function(_0x2b7436,_0x3035cd){const _0x2a82cc=_0x432a0b;return db['SquareDetailsReport'][_0x2a82cc('0x2a')]({'where':{'id':_0x2b7436[_0x2a82cc('0x2b')]['id']}})[_0x2a82cc('0x18')](handleEntityNotFound(_0x3035cd,null))[_0x2a82cc('0x18')](removeEntity(_0x3035cd,null))[_0x2a82cc('0x28')](handleError(_0x3035cd,null));},exports[_0x432a0b('0x1f')]=function(_0x3cf0ac,_0x5d846c){const _0x547cb2=_0x432a0b;return db[_0x547cb2('0x11')][_0x547cb2('0x1f')]()[_0x547cb2('0x18')](respondWithResult(_0x5d846c,null))[_0x547cb2('0x28')](handleError(_0x5d846c,null));}; \ No newline at end of file diff --git a/server/api/squareReportDetail/squareReportDetail.model.js b/server/api/squareReportDetail/squareReportDetail.model.js index 1bda2eb..edc4675 100644 --- a/server/api/squareReportDetail/squareReportDetail.model.js +++ b/server/api/squareReportDetail/squareReportDetail.model.js @@ -1 +1 @@ -const a616_0x4b99=['./squareReportDetail.attributes','report_square_details','SquareDetailsReport','define'];(function(_0x52a349,_0x4b9943){const _0x27a7b0=function(_0x4a3e46){while(--_0x4a3e46){_0x52a349['push'](_0x52a349['shift']());}};_0x27a7b0(++_0x4b9943);}(a616_0x4b99,0xd9));const a616_0x27a7=function(_0x52a349,_0x4b9943){_0x52a349=_0x52a349-0x0;let _0x27a7b0=a616_0x4b99[_0x52a349];return _0x27a7b0;};const _0x454b06=a616_0x27a7;'use strict';const attributes=require(_0x454b06('0x3'));module['exports']=function(_0x4a3e46){const _0x29b08f=_0x454b06,_0x25fb80=_0x4a3e46[_0x29b08f('0x2')](_0x29b08f('0x1'),attributes,{'tableName':_0x29b08f('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x25fb80;}; \ No newline at end of file +const a616_0x53e0=['report_square_details','./squareReportDetail.attributes','exports','SquareDetailsReport','define'];(function(_0x45225a,_0x53e09b){const _0x1aaf1d=function(_0x140c8b){while(--_0x140c8b){_0x45225a['push'](_0x45225a['shift']());}};_0x1aaf1d(++_0x53e09b);}(a616_0x53e0,0x1bf));const a616_0x1aaf=function(_0x45225a,_0x53e09b){_0x45225a=_0x45225a-0x0;let _0x1aaf1d=a616_0x53e0[_0x45225a];return _0x1aaf1d;};const _0x1cc13f=a616_0x1aaf;'use strict';const attributes=require(_0x1cc13f('0x4'));module[_0x1cc13f('0x0')]=function(_0x140c8b){const _0x4e0771=_0x1cc13f,_0xd07b5b=_0x140c8b[_0x4e0771('0x2')](_0x4e0771('0x1'),attributes,{'tableName':_0x4e0771('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xd07b5b;}; \ No newline at end of file diff --git a/server/api/squareReportDetail/squareReportDetail.rpc.js b/server/api/squareReportDetail/squareReportDetail.rpc.js index fe5c543..680c7c9 100644 --- a/server/api/squareReportDetail/squareReportDetail.rpc.js +++ b/server/api/squareReportDetail/squareReportDetail.rpc.js @@ -1 +1 @@ -const a617_0x1451=['raw','body','then','info','catch','SquareDetailsReport','message','../../mysqldb','rpc','create','CreateSquareDetailsReport','options','error','../../config/logger','debug'];(function(_0xdce815,_0x1451d5){const _0x26f69c=function(_0x4a5582){while(--_0x4a5582){_0xdce815['push'](_0xdce815['shift']());}};_0x26f69c(++_0x1451d5);}(a617_0x1451,0x1c7));const a617_0x26f6=function(_0xdce815,_0x1451d5){_0xdce815=_0xdce815-0x0;let _0x26f69c=a617_0x1451[_0xdce815];return _0x26f69c;};const _0x180834=a617_0x26f6;'use strict';const db=require(_0x180834('0x2'))['db'],logger=require(_0x180834('0x8'))(_0x180834('0x3'));exports['CreateSquareDetailsReport']=function(_0x4a5582){const _0x14c88f=this;return new Promise(function(_0x488e0c,_0x25d126){const _0x27a847=a617_0x26f6;return db[_0x27a847('0x0')][_0x27a847('0x4')](_0x4a5582[_0x27a847('0xb')],{'raw':_0x4a5582['options']?_0x4a5582[_0x27a847('0x6')][_0x27a847('0xa')]===undefined?!![]:![]:!![]})[_0x27a847('0xc')](function(_0x548a29){const _0x405a56=_0x27a847;logger[_0x405a56('0xd')]('CreateSquareDetailsReport',_0x4a5582),logger[_0x405a56('0x9')](_0x405a56('0x5'),_0x4a5582,JSON['stringify'](_0x548a29)),_0x488e0c(_0x548a29);})[_0x27a847('0xe')](function(_0x3b7b2e){const _0x47155a=_0x27a847;logger[_0x47155a('0x7')](_0x47155a('0x5'),_0x3b7b2e[_0x47155a('0x1')],_0x4a5582),_0x25d126(_0x14c88f[_0x47155a('0x7')](0x1f4,_0x3b7b2e[_0x47155a('0x1')]));});});}; \ No newline at end of file +const a617_0x4921=['rpc','../../config/logger','error','body','info','../../mysqldb','options','debug','then','message','create','catch','stringify','raw','CreateSquareDetailsReport','SquareDetailsReport'];(function(_0x1af646,_0x492125){const _0x451854=function(_0x2f8ebb){while(--_0x2f8ebb){_0x1af646['push'](_0x1af646['shift']());}};_0x451854(++_0x492125);}(a617_0x4921,0x10b));const a617_0x4518=function(_0x1af646,_0x492125){_0x1af646=_0x1af646-0x0;let _0x451854=a617_0x4921[_0x1af646];return _0x451854;};const _0x590f90=a617_0x4518;'use strict';const db=require(_0x590f90('0xa'))['db'],logger=require(_0x590f90('0x6'))(_0x590f90('0x5'));exports[_0x590f90('0x3')]=function(_0x2f8ebb){const _0x1e0e09=this;return new Promise(function(_0x397edd,_0x3ab551){const _0x264ec6=a617_0x4518;return db[_0x264ec6('0x4')][_0x264ec6('0xf')](_0x2f8ebb[_0x264ec6('0x8')],{'raw':_0x2f8ebb['options']?_0x2f8ebb[_0x264ec6('0xb')][_0x264ec6('0x2')]===undefined?!![]:![]:!![]})[_0x264ec6('0xd')](function(_0x47a949){const _0x4e28f8=_0x264ec6;logger[_0x4e28f8('0x9')](_0x4e28f8('0x3'),_0x2f8ebb),logger[_0x4e28f8('0xc')](_0x4e28f8('0x3'),_0x2f8ebb,JSON[_0x4e28f8('0x1')](_0x47a949)),_0x397edd(_0x47a949);})[_0x264ec6('0x0')](function(_0x5098ff){const _0x23cf0e=_0x264ec6;logger['error'](_0x23cf0e('0x3'),_0x5098ff['message'],_0x2f8ebb),_0x3ab551(_0x1e0e09[_0x23cf0e('0x7')](0x1f4,_0x5098ff[_0x23cf0e('0xe')]));});});}; \ No newline at end of file diff --git a/server/api/system/index.js b/server/api/system/index.js index e76071c..8db0b0b 100644 --- a/server/api/system/index.js +++ b/server/api/system/index.js @@ -1 +1 @@ -const a618_0x1a84=['get','/process/:pid/kill','Router','express','killProcess','exports','../../components/auth/service','./system.controller'];(function(_0x4bc309,_0x1a8453){const _0x2cbf71=function(_0x31f8d9){while(--_0x31f8d9){_0x4bc309['push'](_0x4bc309['shift']());}};_0x2cbf71(++_0x1a8453);}(a618_0x1a84,0x1f3));const a618_0x2cbf=function(_0x4bc309,_0x1a8453){_0x4bc309=_0x4bc309-0x0;let _0x2cbf71=a618_0x1a84[_0x4bc309];return _0x2cbf71;};const _0x216206=a618_0x2cbf;'use strict';const express=require(_0x216206('0x0')),router=express[_0x216206('0x7')](),auth=require(_0x216206('0x3')),controller=require(_0x216206('0x4'));router[_0x216206('0x5')]('/',auth['isAuthenticated'](),controller['index']),router[_0x216206('0x5')](_0x216206('0x6'),auth['isAuthenticated'](),controller[_0x216206('0x1')]),module[_0x216206('0x2')]=router; \ No newline at end of file +const a618_0x1c0a=['express','/process/:pid/kill','./system.controller','exports','isAuthenticated','index','../../components/auth/service','Router','killProcess','get'];(function(_0x519212,_0x1c0ad6){const _0x598c6a=function(_0x361077){while(--_0x361077){_0x519212['push'](_0x519212['shift']());}};_0x598c6a(++_0x1c0ad6);}(a618_0x1c0a,0x17d));const a618_0x598c=function(_0x519212,_0x1c0ad6){_0x519212=_0x519212-0x0;let _0x598c6a=a618_0x1c0a[_0x519212];return _0x598c6a;};const _0x247f38=a618_0x598c;'use strict';const express=require(_0x247f38('0x9')),router=express[_0x247f38('0x6')](),auth=require(_0x247f38('0x5')),controller=require(_0x247f38('0x1'));router['get']('/',auth[_0x247f38('0x3')](),controller[_0x247f38('0x4')]),router[_0x247f38('0x8')](_0x247f38('0x0'),auth[_0x247f38('0x3')](),controller[_0x247f38('0x7')]),module[_0x247f38('0x2')]=router; \ No newline at end of file diff --git a/server/api/system/system.controller.js b/server/api/system/system.controller.js index f4f920f..a61d673 100644 --- a/server/api/system/system.controller.js +++ b/server/api/system/system.controller.js @@ -1 +1 @@ -const a619_0x2517=['indexOf','Process\x20with\x20pid\x20%s\x20killed\x20correctly','getAllData','Process\x20with\x20pid\x20%s\x20not\x20found!','format','length','api','pid','kill','json','ps\x20-p\x20%s\x20-ww\x20-o\x20args','error','status','child_process','SIGINT','params','name','then','killProcess','catch','../../config/logger'];(function(_0x3affc7,_0x251776){const _0x3cc77e=function(_0x4a84ce){while(--_0x4a84ce){_0x3affc7['push'](_0x3affc7['shift']());}};_0x3cc77e(++_0x251776);}(a619_0x2517,0x79));const a619_0x3cc7=function(_0x3affc7,_0x251776){_0x3affc7=_0x3affc7-0x0;let _0x3cc77e=a619_0x2517[_0x3affc7];return _0x3cc77e;};const _0x5b4f8d=a619_0x3cc7;'use strict';const info=require('systeminformation'),exec=require(_0x5b4f8d('0x12'))['exec'],logger=require(_0x5b4f8d('0x4'))(_0x5b4f8d('0xb')),util=require('util');function handleError(_0x4a84ce,_0x330190,_0x1d2803){return _0x330190=_0x330190||0x1f4,function(_0x351bb5){const _0x762680=a619_0x3cc7;logger[_0x762680('0x10')]('<%-\x20name\x20%>,\x20%s,\x20%s,\x20%s',_0x1d2803,_0x330190,util['inspect'](_0x351bb5,{'showHidden':![],'depth':null})),delete _0x351bb5[_0x762680('0x0')],_0x4a84ce[_0x762680('0x11')](_0x330190)['send'](_0x351bb5);};}exports['index']=function(_0x3c4cea,_0x551858){const _0x38687a=_0x5b4f8d;return info[_0x38687a('0x7')]()['then'](function(_0x7c18f7){const _0x262f13=_0x38687a;return _0x551858['status'](0xc8)[_0x262f13('0xe')](_0x7c18f7);})[_0x38687a('0x3')](function(_0x34a282){const _0x3b6cc7=_0x38687a;return _0x551858[_0x3b6cc7('0x11')](0x1f4)[_0x3b6cc7('0xe')](_0x34a282);});},exports[_0x5b4f8d('0x2')]=function(_0xe4f848,_0x589a76){const _0x2790e8=_0x5b4f8d,_0x3785e3=['components/import/cm'];return new Promise(function(_0x17b6f2,_0x3a1360){const _0x113ee=a619_0x3cc7;return exec(util[_0x113ee('0x9')](_0x113ee('0xf'),_0xe4f848['params']['pid']),function(_0xe8272e,_0x4b7f25){if(_0xe8272e)return _0x3a1360(_0xe8272e);return _0x17b6f2(_0x4b7f25);});})[_0x2790e8('0x1')](function(_0x1a08a9){const _0x1f12aa=_0x2790e8;let _0x9828e=![];for(let _0x55e054=0x0,_0x83bd8c=_0x3785e3[_0x1f12aa('0xa')];_0x55e054<_0x83bd8c,_0x9828e===![];_0x55e054+=0x1){_0x1a08a9[_0x1f12aa('0x5')](_0x3785e3[_0x55e054])>=0x0&&(_0x9828e=!![]);}if(!_0x9828e)throw new Error(util['format'](_0x1f12aa('0x8'),_0xe4f848[_0x1f12aa('0x14')]['pid']));return process[_0x1f12aa('0xd')](_0xe4f848[_0x1f12aa('0x14')][_0x1f12aa('0xc')],_0x1f12aa('0x13')),_0x589a76['status'](0xc8)['json']({'message':util[_0x1f12aa('0x9')](_0x1f12aa('0x6'),_0xe4f848[_0x1f12aa('0x14')]['pid'])});})['catch'](handleError(_0x589a76,null,_0x2790e8('0x2')));}; \ No newline at end of file +const a619_0x1e39=['catch','name','params','getAllData','error','SIGINT','then','pid','api','../../config/logger','ps\x20-p\x20%s\x20-ww\x20-o\x20args','status','index','json','<%-\x20name\x20%>,\x20%s,\x20%s,\x20%s','kill','Process\x20with\x20pid\x20%s\x20not\x20found!','send','components/import/cm','child_process','inspect','exec','format'];(function(_0x378d1d,_0x1e39b2){const _0xd03a6=function(_0x2cd669){while(--_0x2cd669){_0x378d1d['push'](_0x378d1d['shift']());}};_0xd03a6(++_0x1e39b2);}(a619_0x1e39,0x15e));const a619_0xd03a=function(_0x378d1d,_0x1e39b2){_0x378d1d=_0x378d1d-0x0;let _0xd03a6=a619_0x1e39[_0x378d1d];return _0xd03a6;};const _0x57a71f=a619_0xd03a;'use strict';const info=require('systeminformation'),exec=require(_0x57a71f('0xe'))[_0x57a71f('0x10')],logger=require(_0x57a71f('0x4'))(_0x57a71f('0x3')),util=require('util');function handleError(_0x2cd669,_0x2d3496,_0x5ed24e){return _0x2d3496=_0x2d3496||0x1f4,function(_0x24a250){const _0x4ba957=a619_0xd03a;logger[_0x4ba957('0x16')](_0x4ba957('0x9'),_0x5ed24e,_0x2d3496,util[_0x4ba957('0xf')](_0x24a250,{'showHidden':![],'depth':null})),delete _0x24a250[_0x4ba957('0x13')],_0x2cd669[_0x4ba957('0x6')](_0x2d3496)[_0x4ba957('0xc')](_0x24a250);};}exports[_0x57a71f('0x7')]=function(_0x4eb8dd,_0x163b88){const _0x54e5f4=_0x57a71f;return info[_0x54e5f4('0x15')]()['then'](function(_0x3c5165){const _0x32979a=_0x54e5f4;return _0x163b88[_0x32979a('0x6')](0xc8)[_0x32979a('0x8')](_0x3c5165);})[_0x54e5f4('0x12')](function(_0x2884d6){const _0x3e8c04=_0x54e5f4;return _0x163b88[_0x3e8c04('0x6')](0x1f4)[_0x3e8c04('0x8')](_0x2884d6);});},exports['killProcess']=function(_0x5cb18a,_0x9bfe9b){const _0x3f3a0d=_0x57a71f,_0x49d2cf=[_0x3f3a0d('0xd')];return new Promise(function(_0x5a0cc7,_0x1254bb){const _0x1cb4c8=_0x3f3a0d;return exec(util[_0x1cb4c8('0x11')](_0x1cb4c8('0x5'),_0x5cb18a[_0x1cb4c8('0x14')][_0x1cb4c8('0x2')]),function(_0x52765d,_0x54aab5){if(_0x52765d)return _0x1254bb(_0x52765d);return _0x5a0cc7(_0x54aab5);});})[_0x3f3a0d('0x1')](function(_0x26c586){const _0x1f6067=_0x3f3a0d;let _0xa18bd3=![];for(let _0x1d118f=0x0,_0x271351=_0x49d2cf['length'];_0x1d118f<_0x271351,_0xa18bd3===![];_0x1d118f+=0x1){_0x26c586['indexOf'](_0x49d2cf[_0x1d118f])>=0x0&&(_0xa18bd3=!![]);}if(!_0xa18bd3)throw new Error(util[_0x1f6067('0x11')](_0x1f6067('0xb'),_0x5cb18a[_0x1f6067('0x14')][_0x1f6067('0x2')]));return process[_0x1f6067('0xa')](_0x5cb18a[_0x1f6067('0x14')][_0x1f6067('0x2')],_0x1f6067('0x0')),_0x9bfe9b[_0x1f6067('0x6')](0xc8)[_0x1f6067('0x8')]({'message':util[_0x1f6067('0x11')]('Process\x20with\x20pid\x20%s\x20killed\x20correctly',_0x5cb18a['params'][_0x1f6067('0x2')])});})[_0x3f3a0d('0x12')](handleError(_0x9bfe9b,null,'killProcess'));}; \ No newline at end of file diff --git a/server/api/tag/index.js b/server/api/tag/index.js index 79d8009..94553c6 100644 --- a/server/api/tag/index.js +++ b/server/api/tag/index.js @@ -1 +1 @@ -const a620_0x3aa2=['post','./tag.controller','create','get','index','express','/:id','delete','Router','show','exports','isAuthenticated'];(function(_0x5cb1e4,_0x3aa2d3){const _0x251e10=function(_0x73e340){while(--_0x73e340){_0x5cb1e4['push'](_0x5cb1e4['shift']());}};_0x251e10(++_0x3aa2d3);}(a620_0x3aa2,0x101));const a620_0x251e=function(_0x5cb1e4,_0x3aa2d3){_0x5cb1e4=_0x5cb1e4-0x0;let _0x251e10=a620_0x3aa2[_0x5cb1e4];return _0x251e10;};const _0x1516a1=a620_0x251e;'use strict';const express=require(_0x1516a1('0x0')),router=express[_0x1516a1('0x3')](),auth=require('../../components/auth/service'),controller=require(_0x1516a1('0x8'));router[_0x1516a1('0xa')]('/',auth['isAuthenticated'](),controller[_0x1516a1('0xb')]),router[_0x1516a1('0xa')](_0x1516a1('0x1'),auth[_0x1516a1('0x6')](),controller[_0x1516a1('0x4')]),router[_0x1516a1('0x7')]('/',auth[_0x1516a1('0x6')](),controller[_0x1516a1('0x9')]),router['put'](_0x1516a1('0x1'),auth[_0x1516a1('0x6')](),controller['update']),router[_0x1516a1('0x2')](_0x1516a1('0x1'),auth[_0x1516a1('0x6')](),controller['destroy']),module[_0x1516a1('0x5')]=router; \ No newline at end of file +const a620_0x1b78=['create','update','express','put','index','show','get','delete','exports','/:id','isAuthenticated'];(function(_0x3ae357,_0x1b780f){const _0x504cb3=function(_0xaead83){while(--_0xaead83){_0x3ae357['push'](_0x3ae357['shift']());}};_0x504cb3(++_0x1b780f);}(a620_0x1b78,0x1f3));const a620_0x504c=function(_0x3ae357,_0x1b780f){_0x3ae357=_0x3ae357-0x0;let _0x504cb3=a620_0x1b78[_0x3ae357];return _0x504cb3;};const _0x1ae9b0=a620_0x504c;'use strict';const express=require(_0x1ae9b0('0x9')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require('./tag.controller');router[_0x1ae9b0('0x2')]('/',auth[_0x1ae9b0('0x6')](),controller[_0x1ae9b0('0x0')]),router[_0x1ae9b0('0x2')]('/:id',auth[_0x1ae9b0('0x6')](),controller[_0x1ae9b0('0x1')]),router['post']('/',auth[_0x1ae9b0('0x6')](),controller[_0x1ae9b0('0x7')]),router[_0x1ae9b0('0xa')](_0x1ae9b0('0x5'),auth[_0x1ae9b0('0x6')](),controller[_0x1ae9b0('0x8')]),router[_0x1ae9b0('0x3')](_0x1ae9b0('0x5'),auth[_0x1ae9b0('0x6')](),controller['destroy']),module[_0x1ae9b0('0x4')]=router; \ No newline at end of file diff --git a/server/api/tag/tag.attributes.js b/server/api/tag/tag.attributes.js index 7b485a8..4f15a4b 100644 --- a/server/api/tag/tag.attributes.js +++ b/server/api/tag/tag.attributes.js @@ -1 +1 @@ -const a621_0x5184=['sequelize','STRING'];(function(_0x1cacd8,_0x518404){const _0x28c1a8=function(_0x110673){while(--_0x110673){_0x1cacd8['push'](_0x1cacd8['shift']());}};_0x28c1a8(++_0x518404);}(a621_0x5184,0x1d6));const a621_0x28c1=function(_0x1cacd8,_0x518404){_0x1cacd8=_0x1cacd8-0x0;let _0x28c1a8=a621_0x5184[_0x1cacd8];return _0x28c1a8;};const _0xb66226=a621_0x28c1;'use strict';const Sequelize=require(_0xb66226('0x0'));module['exports']={'name':{'type':Sequelize['STRING'],'unique':'name','allowNull':![],'validate':{'is':/[A-Za-z0-9._\\+*!-]+/,'notEmpty':!![]}},'color':{'type':Sequelize['STRING'],'defaultValue':'#0091EA'},'description':{'type':Sequelize[_0xb66226('0x1')]}}; \ No newline at end of file +const a621_0x3e63=['STRING','exports','name','sequelize','#0091EA'];(function(_0x5d62e3,_0x3e633b){const _0x3909a2=function(_0x665cec){while(--_0x665cec){_0x5d62e3['push'](_0x5d62e3['shift']());}};_0x3909a2(++_0x3e633b);}(a621_0x3e63,0x179));const a621_0x3909=function(_0x5d62e3,_0x3e633b){_0x5d62e3=_0x5d62e3-0x0;let _0x3909a2=a621_0x3e63[_0x5d62e3];return _0x3909a2;};const _0x55e0c9=a621_0x3909;'use strict';const Sequelize=require(_0x55e0c9('0x1'));module[_0x55e0c9('0x4')]={'name':{'type':Sequelize['STRING'],'unique':_0x55e0c9('0x0'),'allowNull':![],'validate':{'is':/[A-Za-z0-9._\\+*!-]+/,'notEmpty':!![]}},'color':{'type':Sequelize[_0x55e0c9('0x3')],'defaultValue':_0x55e0c9('0x2')},'description':{'type':Sequelize[_0x55e0c9('0x3')]}}; \ No newline at end of file diff --git a/server/api/tag/tag.controller.js b/server/api/tag/tag.controller.js index 404be7d..2270b6e 100644 --- a/server/api/tag/tag.controller.js +++ b/server/api/tag/tag.controller.js @@ -1 +1 @@ -const a622_0x5a5f=['sequelize','update','user','userProfileId','limit','Unable\x20to\x20retrieve\x20the\x20current\x20user','show','name','findAll','map','sort','merge','VIRTUAL','includeAll','count','UserProfileSection','intersection','end','stack','json','attributes','filter','offset','keys','findOne','fieldName','fields','send','filters','Tag','then','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','sendStatus','get','order','rawAttributes','lodash','create','include','type','length','nolimit','status','body','set','like','model','where','api','catch','destroy','error','autoAssociation','UserProfileResource','Tags','key','query','undefined','role','options','params','../../mysqldb'];(function(_0x5b4d87,_0x5a5f15){const _0xfe5c1e=function(_0x35a245){while(--_0x35a245){_0x5b4d87['push'](_0x5b4d87['shift']());}};_0xfe5c1e(++_0x5a5f15);}(a622_0x5a5f,0x1c0));const a622_0xfe5c=function(_0x5b4d87,_0x5a5f15){_0x5b4d87=_0x5b4d87-0x0;let _0xfe5c1e=a622_0x5a5f[_0x5b4d87];return _0xfe5c1e;};const _0x45b70d=a622_0xfe5c;'use strict';const _=require(_0x45b70d('0x16')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x45b70d('0x22')),db=require(_0x45b70d('0x2f'))['db'],{Op}=require(_0x45b70d('0x30'));function respondWithResult(_0x35a245,_0xaf4f6e){return _0xaf4f6e=_0xaf4f6e||0xc8,function(_0x2bcc8b){const _0x42f0a3=a622_0xfe5c;if(_0x2bcc8b)return _0x35a245['status'](_0xaf4f6e)[_0x42f0a3('0x5')](_0x2bcc8b);};}function respondWithFilteredResult(_0x3a701f,_0x16ccdc){return function(_0x493862){const _0x4fc71f=a622_0xfe5c;if(_0x493862){const _0x59af35=_0x493862[_0x4fc71f('0x0')],_0x572b7c=_0x16ccdc[_0x4fc71f('0x8')];let _0x5c6b1d=_0x16ccdc[_0x4fc71f('0x8')]+_0x16ccdc['limit'],_0x5b3ca8;return _0x5c6b1d>=_0x59af35?(_0x5c6b1d=_0x59af35,_0x5b3ca8=0xc8):_0x5b3ca8=0xce,_0x3a701f[_0x4fc71f('0x1c')](_0x5b3ca8),_0x3a701f[_0x4fc71f('0x1e')]('Content-Range',_0x572b7c+'-'+_0x5c6b1d+'/'+_0x59af35)['json'](_0x493862);}return null;};}function saveUpdates(_0x3c59e3){return function(_0x1c31e8){const _0x7d9e1e=a622_0xfe5c;if(_0x1c31e8)return _0x1c31e8[_0x7d9e1e('0x31')](_0x3c59e3)[_0x7d9e1e('0x10')](function(_0x358b0f){return _0x358b0f;});return null;};}function removeEntity(_0x5d527d){return function(_0x312c36){const _0x3fe894=a622_0xfe5c;if(_0x312c36)return _0x312c36[_0x3fe894('0x24')]()[_0x3fe894('0x10')](function(){const _0x2d3717=_0x3fe894,_0x54dffe=_0x312c36['get']({'plain':!![]}),_0x245903=_0x2d3717('0x28');return db[_0x2d3717('0x27')][_0x2d3717('0x24')]({'where':{'type':_0x245903,'resourceId':_0x54dffe['id']}})[_0x2d3717('0x10')](function(){return _0x312c36;});})[_0x3fe894('0x10')](function(){const _0x36b0e6=_0x3fe894;_0x5d527d[_0x36b0e6('0x1c')](0xcc)[_0x36b0e6('0x3')]();});};}function handleEntityNotFound(_0x4f8c9a){return function(_0x2ab274){const _0x32df6c=a622_0xfe5c;return!_0x2ab274&&_0x4f8c9a[_0x32df6c('0x12')](0x194),_0x2ab274;};}function handleError(_0x3e0c71,_0x1a02dc){return _0x1a02dc=_0x1a02dc||0x1f4,function(_0x4227c4){const _0x1ebba6=a622_0xfe5c;logger[_0x1ebba6('0x25')](_0x4227c4[_0x1ebba6('0x4')]),_0x4227c4['name']&&delete _0x4227c4['name'],_0x3e0c71[_0x1ebba6('0x1c')](_0x1a02dc)[_0x1ebba6('0xd')](_0x4227c4);};}exports['index']=function(_0x43f8bd,_0x1f8478){const _0x382f25=_0x45b70d;let _0xdfe9a8={};const _0x23ef3b={},_0x202794={'count':0x0,'rows':[]},_0x175d99=_[_0x382f25('0x39')](db[_0x382f25('0xf')][_0x382f25('0x15')],function(_0x394e3e){const _0x28baef=_0x382f25;return{'name':_0x394e3e[_0x28baef('0xb')],'type':_0x394e3e[_0x28baef('0x19')][_0x28baef('0x29')]};});_0x23ef3b[_0x382f25('0x20')]=_[_0x382f25('0x39')](_0x175d99,'name'),_0x23ef3b['query']=_[_0x382f25('0x9')](_0x43f8bd[_0x382f25('0x2a')]),_0x23ef3b['filters']=_['intersection'](_0x23ef3b[_0x382f25('0x20')],_0x23ef3b[_0x382f25('0x2a')]),_0xdfe9a8[_0x382f25('0x6')]=_[_0x382f25('0x2')](_0x23ef3b['model'],qs['fields'](_0x43f8bd[_0x382f25('0x2a')][_0x382f25('0xc')])),_0xdfe9a8[_0x382f25('0x6')]=_0xdfe9a8['attributes'][_0x382f25('0x1a')]?_0xdfe9a8[_0x382f25('0x6')]:_0x23ef3b[_0x382f25('0x20')];typeof _0x43f8bd[_0x382f25('0x2a')][_0x382f25('0x1b')]===_0x382f25('0x2b')&&(_0xdfe9a8[_0x382f25('0x34')]=qs[_0x382f25('0x34')](_0x43f8bd[_0x382f25('0x2a')][_0x382f25('0x34')]),_0xdfe9a8[_0x382f25('0x8')]=qs['offset'](_0x43f8bd['query'][_0x382f25('0x8')]));_0xdfe9a8[_0x382f25('0x14')]=qs[_0x382f25('0x3a')](_0x43f8bd[_0x382f25('0x2a')]['sort']),_0xdfe9a8[_0x382f25('0x21')]=qs[_0x382f25('0xe')](_['pick'](_0x43f8bd[_0x382f25('0x2a')],_0x23ef3b[_0x382f25('0xe')]),_0x175d99);_0x43f8bd['query']['filter']&&(_0xdfe9a8['where']=_[_0x382f25('0x3b')](_0xdfe9a8[_0x382f25('0x21')],{[Op['or']]:_['map'](_0x175d99,function(_0x1dea69){const _0x171b09=_0x382f25;if(_0x1dea69['type']!==_0x171b09('0x3c')){const _0x1927ca={};return _0x1927ca[_0x1dea69[_0x171b09('0x37')]]={[Op[_0x171b09('0x1f')]]:'%'+_0x43f8bd['query'][_0x171b09('0x7')]+'%'},_0x1927ca;}})}));_0xdfe9a8=_['merge']({},_0xdfe9a8,_0x43f8bd[_0x382f25('0x2d')]);const _0x93e39c={'where':_0xdfe9a8[_0x382f25('0x21')]};return db[_0x382f25('0xf')][_0x382f25('0x0')](_0x93e39c)[_0x382f25('0x10')](function(_0x2b8f63){const _0x401d6e=_0x382f25;return _0x202794[_0x401d6e('0x0')]=_0x2b8f63,_0x43f8bd['query'][_0x401d6e('0x3d')]&&(_0xdfe9a8[_0x401d6e('0x18')]=[{'all':!![]}]),db[_0x401d6e('0xf')][_0x401d6e('0x38')](_0xdfe9a8);})[_0x382f25('0x10')](function(_0x8ab8d3){return _0x202794['rows']=_0x8ab8d3,_0x202794;})[_0x382f25('0x10')](respondWithFilteredResult(_0x1f8478,_0xdfe9a8))[_0x382f25('0x23')](handleError(_0x1f8478,null));},exports[_0x45b70d('0x36')]=function(_0x301468,_0x4b7564){const _0xb7828d=_0x45b70d;let _0x11b3a3={'raw':!![],'where':{'id':_0x301468[_0xb7828d('0x2e')]['id']}};const _0x304130={};return _0x304130[_0xb7828d('0x20')]=_[_0xb7828d('0x9')](db[_0xb7828d('0xf')][_0xb7828d('0x15')]),_0x304130[_0xb7828d('0x2a')]=_[_0xb7828d('0x9')](_0x301468[_0xb7828d('0x2a')]),_0x304130[_0xb7828d('0xe')]=_['intersection'](_0x304130[_0xb7828d('0x20')],_0x304130[_0xb7828d('0x2a')]),_0x11b3a3[_0xb7828d('0x6')]=_[_0xb7828d('0x2')](_0x304130[_0xb7828d('0x20')],qs['fields'](_0x301468[_0xb7828d('0x2a')][_0xb7828d('0xc')])),_0x11b3a3[_0xb7828d('0x6')]=_0x11b3a3[_0xb7828d('0x6')][_0xb7828d('0x1a')]?_0x11b3a3['attributes']:_0x304130[_0xb7828d('0x20')],_0x301468['query']['includeAll']&&(_0x11b3a3[_0xb7828d('0x18')]=[{'all':!![]}]),_0x11b3a3=_['merge']({},_0x11b3a3,_0x301468['options']),db[_0xb7828d('0xf')]['findOne'](_0x11b3a3)[_0xb7828d('0x10')](handleEntityNotFound(_0x4b7564,null))['then'](respondWithResult(_0x4b7564,null))[_0xb7828d('0x23')](handleError(_0x4b7564,null));},exports[_0x45b70d('0x17')]=function(_0x2f76a0,_0x37a9ff){const _0x3e8716=_0x45b70d;return db['Tag'][_0x3e8716('0x17')](_0x2f76a0[_0x3e8716('0x1d')],{})[_0x3e8716('0x10')](function(_0x231ed1){const _0x2b4f8b=_0x3e8716,_0x3de804=_0x2f76a0[_0x2b4f8b('0x32')][_0x2b4f8b('0x13')]({'plain':!![]});if(!_0x3de804)throw new Error(_0x2b4f8b('0x35'));if(_0x3de804[_0x2b4f8b('0x2c')]===_0x2b4f8b('0x32')){const _0x51d763=_0x231ed1[_0x2b4f8b('0x13')]({'plain':!![]}),_0x4bc498=_0x2b4f8b('0x28');return db[_0x2b4f8b('0x1')][_0x2b4f8b('0xa')]({'where':{'name':_0x4bc498,'userProfileId':_0x3de804[_0x2b4f8b('0x33')]},'raw':!![]})['then'](function(_0x19606b){const _0x2a4de7=_0x2b4f8b;return _0x19606b&&_0x19606b[_0x2a4de7('0x26')]===0x0?db[_0x2a4de7('0x27')]['create']({'name':_0x51d763['name'],'resourceId':_0x51d763['id'],'type':_0x19606b['name'],'sectionId':_0x19606b['id']},{})[_0x2a4de7('0x10')](function(){return _0x231ed1;}):_0x231ed1;})[_0x2b4f8b('0x23')](function(_0x2d0ab5){const _0x168ce8=_0x2b4f8b;logger[_0x168ce8('0x25')](_0x168ce8('0x11'),_0x2d0ab5);throw _0x2d0ab5;});}return _0x231ed1;})['then'](respondWithResult(_0x37a9ff,0xc9))[_0x3e8716('0x23')](handleError(_0x37a9ff,null));},exports[_0x45b70d('0x31')]=function(_0x3d4695,_0x4cfee3){const _0x59e58a=_0x45b70d;return _0x3d4695['body']['id']&&delete _0x3d4695[_0x59e58a('0x1d')]['id'],db[_0x59e58a('0xf')]['findOne']({'where':{'id':_0x3d4695['params']['id']}})[_0x59e58a('0x10')](handleEntityNotFound(_0x4cfee3,null))[_0x59e58a('0x10')](saveUpdates(_0x3d4695[_0x59e58a('0x1d')],null))[_0x59e58a('0x10')](respondWithResult(_0x4cfee3,null))[_0x59e58a('0x23')](handleError(_0x4cfee3,null));},exports[_0x45b70d('0x24')]=function(_0x49f881,_0x981675){const _0x318535=_0x45b70d;return db[_0x318535('0xf')][_0x318535('0xa')]({'where':{'id':_0x49f881[_0x318535('0x2e')]['id']}})[_0x318535('0x10')](handleEntityNotFound(_0x981675,null))[_0x318535('0x10')](removeEntity(_0x981675,null))[_0x318535('0x23')](handleError(_0x981675,null));}; \ No newline at end of file +const a622_0x3343=['findOne','../../components/parsers/qs','autoAssociation','update','type','then','nolimit','options','Unable\x20to\x20retrieve\x20the\x20current\x20user','json','destroy','offset','pick','set','intersection','user','body','keys','attributes','VIRTUAL','key','includeAll','sendStatus','stack','count','role','rawAttributes','get','status','fields','UserProfileResource','create','Tags','UserProfileSection','sort','limit','show','Tag','where','include','model','api','Content-Range','findAll','error','order','userProfileId','lodash','index','name','catch','filter','../../mysqldb','query','merge','send','params','map','filters','../../config/logger'];(function(_0x4844fc,_0x33434a){const _0xbf3e0=function(_0x2c6c22){while(--_0x2c6c22){_0x4844fc['push'](_0x4844fc['shift']());}};_0xbf3e0(++_0x33434a);}(a622_0x3343,0x160));const a622_0xbf3e=function(_0x4844fc,_0x33434a){_0x4844fc=_0x4844fc-0x0;let _0xbf3e0=a622_0x3343[_0x4844fc];return _0xbf3e0;};const _0x515514=a622_0xbf3e;'use strict';const _=require(_0x515514('0x37')),qs=require(_0x515514('0x9')),logger=require(_0x515514('0x7'))(_0x515514('0x31')),db=require(_0x515514('0x0'))['db'],{Op}=require('sequelize');function respondWithResult(_0x2c6c22,_0x2e64e2){return _0x2e64e2=_0x2e64e2||0xc8,function(_0xb531bd){const _0x58990a=a622_0xbf3e;if(_0xb531bd)return _0x2c6c22[_0x58990a('0x24')](_0x2e64e2)[_0x58990a('0x11')](_0xb531bd);};}function respondWithFilteredResult(_0x1f9115,_0x303311){return function(_0xf3232d){const _0xdf653d=a622_0xbf3e;if(_0xf3232d){const _0x2b2466=_0xf3232d[_0xdf653d('0x20')],_0x3e2a1f=_0x303311[_0xdf653d('0x13')];let _0x2284e2=_0x303311[_0xdf653d('0x13')]+_0x303311[_0xdf653d('0x2b')],_0x4c96a7;return _0x2284e2>=_0x2b2466?(_0x2284e2=_0x2b2466,_0x4c96a7=0xc8):_0x4c96a7=0xce,_0x1f9115[_0xdf653d('0x24')](_0x4c96a7),_0x1f9115[_0xdf653d('0x15')](_0xdf653d('0x32'),_0x3e2a1f+'-'+_0x2284e2+'/'+_0x2b2466)['json'](_0xf3232d);}return null;};}function saveUpdates(_0x1f37e3){return function(_0x54f736){const _0x360309=a622_0xbf3e;if(_0x54f736)return _0x54f736[_0x360309('0xb')](_0x1f37e3)['then'](function(_0x5bc906){return _0x5bc906;});return null;};}function removeEntity(_0x384c74){return function(_0x5ec714){if(_0x5ec714)return _0x5ec714['destroy']()['then'](function(){const _0x3fa818=a622_0xbf3e,_0x10409e=_0x5ec714['get']({'plain':!![]}),_0x565867=_0x3fa818('0x28');return db[_0x3fa818('0x26')][_0x3fa818('0x12')]({'where':{'type':_0x565867,'resourceId':_0x10409e['id']}})['then'](function(){return _0x5ec714;});})['then'](function(){const _0x497a34=a622_0xbf3e;_0x384c74[_0x497a34('0x24')](0xcc)['end']();});};}function handleEntityNotFound(_0x182211){return function(_0x3aefe7){const _0x1a5831=a622_0xbf3e;return!_0x3aefe7&&_0x182211[_0x1a5831('0x1e')](0x194),_0x3aefe7;};}function handleError(_0x4c04e8,_0x3f8c5f){return _0x3f8c5f=_0x3f8c5f||0x1f4,function(_0x2814bc){const _0xfb96f1=a622_0xbf3e;logger[_0xfb96f1('0x34')](_0x2814bc[_0xfb96f1('0x1f')]),_0x2814bc[_0xfb96f1('0x39')]&&delete _0x2814bc[_0xfb96f1('0x39')],_0x4c04e8['status'](_0x3f8c5f)[_0xfb96f1('0x3')](_0x2814bc);};}exports[_0x515514('0x38')]=function(_0x548156,_0x354ecd){const _0x4e4cc2=_0x515514;let _0x2beb6a={};const _0x3a4a40={},_0x156511={'count':0x0,'rows':[]},_0x4b41c1=_[_0x4e4cc2('0x5')](db[_0x4e4cc2('0x2d')][_0x4e4cc2('0x22')],function(_0x3de184){const _0x36b888=_0x4e4cc2;return{'name':_0x3de184['fieldName'],'type':_0x3de184[_0x36b888('0xc')][_0x36b888('0x1c')]};});_0x3a4a40[_0x4e4cc2('0x30')]=_['map'](_0x4b41c1,'name'),_0x3a4a40[_0x4e4cc2('0x1')]=_[_0x4e4cc2('0x19')](_0x548156[_0x4e4cc2('0x1')]),_0x3a4a40[_0x4e4cc2('0x6')]=_[_0x4e4cc2('0x16')](_0x3a4a40[_0x4e4cc2('0x30')],_0x3a4a40[_0x4e4cc2('0x1')]),_0x2beb6a[_0x4e4cc2('0x1a')]=_[_0x4e4cc2('0x16')](_0x3a4a40[_0x4e4cc2('0x30')],qs[_0x4e4cc2('0x25')](_0x548156[_0x4e4cc2('0x1')][_0x4e4cc2('0x25')])),_0x2beb6a[_0x4e4cc2('0x1a')]=_0x2beb6a[_0x4e4cc2('0x1a')]['length']?_0x2beb6a[_0x4e4cc2('0x1a')]:_0x3a4a40[_0x4e4cc2('0x30')];typeof _0x548156[_0x4e4cc2('0x1')][_0x4e4cc2('0xe')]==='undefined'&&(_0x2beb6a[_0x4e4cc2('0x2b')]=qs[_0x4e4cc2('0x2b')](_0x548156[_0x4e4cc2('0x1')][_0x4e4cc2('0x2b')]),_0x2beb6a['offset']=qs[_0x4e4cc2('0x13')](_0x548156[_0x4e4cc2('0x1')]['offset']));_0x2beb6a[_0x4e4cc2('0x35')]=qs['sort'](_0x548156['query'][_0x4e4cc2('0x2a')]),_0x2beb6a['where']=qs[_0x4e4cc2('0x6')](_[_0x4e4cc2('0x14')](_0x548156[_0x4e4cc2('0x1')],_0x3a4a40[_0x4e4cc2('0x6')]),_0x4b41c1);_0x548156[_0x4e4cc2('0x1')][_0x4e4cc2('0x3b')]&&(_0x2beb6a[_0x4e4cc2('0x2e')]=_[_0x4e4cc2('0x2')](_0x2beb6a[_0x4e4cc2('0x2e')],{[Op['or']]:_[_0x4e4cc2('0x5')](_0x4b41c1,function(_0x3d707c){const _0x252e46=_0x4e4cc2;if(_0x3d707c[_0x252e46('0xc')]!==_0x252e46('0x1b')){const _0x3dc20e={};return _0x3dc20e[_0x3d707c['name']]={[Op['like']]:'%'+_0x548156[_0x252e46('0x1')]['filter']+'%'},_0x3dc20e;}})}));_0x2beb6a=_[_0x4e4cc2('0x2')]({},_0x2beb6a,_0x548156['options']);const _0x14c026={'where':_0x2beb6a['where']};return db['Tag'][_0x4e4cc2('0x20')](_0x14c026)[_0x4e4cc2('0xd')](function(_0x1fbf5f){const _0x502882=_0x4e4cc2;return _0x156511['count']=_0x1fbf5f,_0x548156[_0x502882('0x1')][_0x502882('0x1d')]&&(_0x2beb6a[_0x502882('0x2f')]=[{'all':!![]}]),db[_0x502882('0x2d')][_0x502882('0x33')](_0x2beb6a);})[_0x4e4cc2('0xd')](function(_0x53e144){return _0x156511['rows']=_0x53e144,_0x156511;})[_0x4e4cc2('0xd')](respondWithFilteredResult(_0x354ecd,_0x2beb6a))['catch'](handleError(_0x354ecd,null));},exports[_0x515514('0x2c')]=function(_0x5a476a,_0x1be7ef){const _0x86c5cf=_0x515514;let _0x604971={'raw':!![],'where':{'id':_0x5a476a[_0x86c5cf('0x4')]['id']}};const _0xda35ff={};return _0xda35ff['model']=_[_0x86c5cf('0x19')](db[_0x86c5cf('0x2d')]['rawAttributes']),_0xda35ff[_0x86c5cf('0x1')]=_['keys'](_0x5a476a[_0x86c5cf('0x1')]),_0xda35ff[_0x86c5cf('0x6')]=_[_0x86c5cf('0x16')](_0xda35ff['model'],_0xda35ff[_0x86c5cf('0x1')]),_0x604971['attributes']=_[_0x86c5cf('0x16')](_0xda35ff['model'],qs[_0x86c5cf('0x25')](_0x5a476a['query']['fields'])),_0x604971[_0x86c5cf('0x1a')]=_0x604971[_0x86c5cf('0x1a')]['length']?_0x604971[_0x86c5cf('0x1a')]:_0xda35ff[_0x86c5cf('0x30')],_0x5a476a[_0x86c5cf('0x1')][_0x86c5cf('0x1d')]&&(_0x604971[_0x86c5cf('0x2f')]=[{'all':!![]}]),_0x604971=_[_0x86c5cf('0x2')]({},_0x604971,_0x5a476a[_0x86c5cf('0xf')]),db[_0x86c5cf('0x2d')]['findOne'](_0x604971)['then'](handleEntityNotFound(_0x1be7ef,null))['then'](respondWithResult(_0x1be7ef,null))[_0x86c5cf('0x3a')](handleError(_0x1be7ef,null));},exports[_0x515514('0x27')]=function(_0x45f854,_0x1b32c8){const _0x603d54=_0x515514;return db['Tag'][_0x603d54('0x27')](_0x45f854[_0x603d54('0x18')],{})['then'](function(_0x5daa4a){const _0x360acf=_0x603d54,_0x41b018=_0x45f854[_0x360acf('0x17')][_0x360acf('0x23')]({'plain':!![]});if(!_0x41b018)throw new Error(_0x360acf('0x10'));if(_0x41b018[_0x360acf('0x21')]==='user'){const _0x539d38=_0x5daa4a[_0x360acf('0x23')]({'plain':!![]}),_0x3085ef='Tags';return db[_0x360acf('0x29')][_0x360acf('0x8')]({'where':{'name':_0x3085ef,'userProfileId':_0x41b018[_0x360acf('0x36')]},'raw':!![]})[_0x360acf('0xd')](function(_0x37ce74){const _0x1f5741=_0x360acf;return _0x37ce74&&_0x37ce74[_0x1f5741('0xa')]===0x0?db['UserProfileResource']['create']({'name':_0x539d38[_0x1f5741('0x39')],'resourceId':_0x539d38['id'],'type':_0x37ce74[_0x1f5741('0x39')],'sectionId':_0x37ce74['id']},{})['then'](function(){return _0x5daa4a;}):_0x5daa4a;})[_0x360acf('0x3a')](function(_0x2ea89){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x2ea89);throw _0x2ea89;});}return _0x5daa4a;})['then'](respondWithResult(_0x1b32c8,0xc9))[_0x603d54('0x3a')](handleError(_0x1b32c8,null));},exports[_0x515514('0xb')]=function(_0x410e39,_0x3cb9d4){const _0x1e2e7f=_0x515514;return _0x410e39[_0x1e2e7f('0x18')]['id']&&delete _0x410e39[_0x1e2e7f('0x18')]['id'],db[_0x1e2e7f('0x2d')][_0x1e2e7f('0x8')]({'where':{'id':_0x410e39['params']['id']}})[_0x1e2e7f('0xd')](handleEntityNotFound(_0x3cb9d4,null))['then'](saveUpdates(_0x410e39[_0x1e2e7f('0x18')],null))[_0x1e2e7f('0xd')](respondWithResult(_0x3cb9d4,null))[_0x1e2e7f('0x3a')](handleError(_0x3cb9d4,null));},exports[_0x515514('0x12')]=function(_0x53fb59,_0x1588cd){const _0x23c002=_0x515514;return db[_0x23c002('0x2d')][_0x23c002('0x8')]({'where':{'id':_0x53fb59[_0x23c002('0x4')]['id']}})[_0x23c002('0xd')](handleEntityNotFound(_0x1588cd,null))['then'](removeEntity(_0x1588cd,null))[_0x23c002('0x3a')](handleError(_0x1588cd,null));}; \ No newline at end of file diff --git a/server/api/tag/tag.model.js b/server/api/tag/tag.model.js index 02cbaad..59e31c2 100644 --- a/server/api/tag/tag.model.js +++ b/server/api/tag/tag.model.js @@ -1 +1 @@ -const a623_0x1cff=['tools_tags','exports','define'];(function(_0x39832c,_0x1cff4e){const _0x4b68b8=function(_0x19e041){while(--_0x19e041){_0x39832c['push'](_0x39832c['shift']());}};_0x4b68b8(++_0x1cff4e);}(a623_0x1cff,0x116));const a623_0x4b68=function(_0x39832c,_0x1cff4e){_0x39832c=_0x39832c-0x0;let _0x4b68b8=a623_0x1cff[_0x39832c];return _0x4b68b8;};const _0x1de115=a623_0x4b68;'use strict';const attributes=require('./tag.attributes');module[_0x1de115('0x2')]=function(_0x19e041){const _0x57f0b8=_0x1de115,_0x2efbf4=_0x19e041[_0x57f0b8('0x0')]('Tag',attributes,{'tableName':_0x57f0b8('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2efbf4;}; \ No newline at end of file +const a623_0x141c=['define','exports','./tag.attributes','Tag'];(function(_0x21886c,_0x141c61){const _0x2e8210=function(_0x244468){while(--_0x244468){_0x21886c['push'](_0x21886c['shift']());}};_0x2e8210(++_0x141c61);}(a623_0x141c,0x1ba));const a623_0x2e82=function(_0x21886c,_0x141c61){_0x21886c=_0x21886c-0x0;let _0x2e8210=a623_0x141c[_0x21886c];return _0x2e8210;};const _0xfdeca5=a623_0x2e82;'use strict';const attributes=require(_0xfdeca5('0x0'));module[_0xfdeca5('0x3')]=function(_0x244468){const _0x21da48=_0xfdeca5,_0x4b7790=_0x244468[_0x21da48('0x2')](_0x21da48('0x1'),attributes,{'tableName':'tools_tags','paranoid':![],'indexes':[],'timestamps':!![]});return _0x4b7790;}; \ No newline at end of file diff --git a/server/api/team/index.js b/server/api/team/index.js index d35ae47..a0dfc3a 100644 --- a/server/api/team/index.js +++ b/server/api/team/index.js @@ -1 +1 @@ -const a624_0x15dd=['delete','Router','get','removeQueues','create','exports','/:id/users','../../components/auth/service','getAgents','post','update','isAuthenticated','removeAgents','/:id/queues','addQueues','show','addAgents','/:id'];(function(_0x2c0755,_0x15dd53){const _0x21261a=function(_0x4aadf6){while(--_0x4aadf6){_0x2c0755['push'](_0x2c0755['shift']());}};_0x21261a(++_0x15dd53);}(a624_0x15dd,0xd3));const a624_0x2126=function(_0x2c0755,_0x15dd53){_0x2c0755=_0x2c0755-0x0;let _0x21261a=a624_0x15dd[_0x2c0755];return _0x21261a;};const _0x4c291a=a624_0x2126;'use strict';const express=require('express'),router=express[_0x4c291a('0x6')](),auth=require(_0x4c291a('0xc')),controller=require('./team.controller');router[_0x4c291a('0x7')]('/',auth[_0x4c291a('0x10')](),controller['index']),router[_0x4c291a('0x7')](_0x4c291a('0x4'),auth[_0x4c291a('0x10')](),controller[_0x4c291a('0x2')]),router[_0x4c291a('0x7')]('/:id/queues',auth[_0x4c291a('0x10')](),controller['getQueues']),router[_0x4c291a('0x7')](_0x4c291a('0xb'),auth[_0x4c291a('0x10')](),controller[_0x4c291a('0xd')]),router[_0x4c291a('0xe')]('/',auth[_0x4c291a('0x10')](),controller[_0x4c291a('0x9')]),router[_0x4c291a('0xe')](_0x4c291a('0x0'),auth[_0x4c291a('0x10')](),controller[_0x4c291a('0x1')]),router['post'](_0x4c291a('0xb'),auth[_0x4c291a('0x10')](),controller[_0x4c291a('0x3')]),router['put'](_0x4c291a('0x4'),auth[_0x4c291a('0x10')](),controller[_0x4c291a('0xf')]),router[_0x4c291a('0x5')](_0x4c291a('0x4'),auth['isAuthenticated'](),controller['destroy']),router[_0x4c291a('0x5')](_0x4c291a('0x0'),auth['isAuthenticated'](),controller[_0x4c291a('0x8')]),router[_0x4c291a('0x5')](_0x4c291a('0xb'),auth[_0x4c291a('0x10')](),controller[_0x4c291a('0x11')]),module[_0x4c291a('0xa')]=router; \ No newline at end of file +const a624_0x4d1e=['put','exports','addAgents','/:id','create','isAuthenticated','/:id/users','post','removeAgents','show','delete','update','Router','get','getAgents','removeQueues','index','./team.controller','addQueues','/:id/queues'];(function(_0x32d85e,_0x4d1e2d){const _0x58480f=function(_0x5ad46f){while(--_0x5ad46f){_0x32d85e['push'](_0x32d85e['shift']());}};_0x58480f(++_0x4d1e2d);}(a624_0x4d1e,0x1c1));const a624_0x5848=function(_0x32d85e,_0x4d1e2d){_0x32d85e=_0x32d85e-0x0;let _0x58480f=a624_0x4d1e[_0x32d85e];return _0x58480f;};const _0x573b62=a624_0x5848;'use strict';const express=require('express'),router=express[_0x573b62('0x3')](),auth=require('../../components/auth/service'),controller=require(_0x573b62('0x8'));router['get']('/',auth[_0x573b62('0x10')](),controller[_0x573b62('0x7')]),router[_0x573b62('0x4')]('/:id',auth[_0x573b62('0x10')](),controller[_0x573b62('0x0')]),router[_0x573b62('0x4')](_0x573b62('0xa'),auth[_0x573b62('0x10')](),controller['getQueues']),router[_0x573b62('0x4')](_0x573b62('0x11'),auth[_0x573b62('0x10')](),controller[_0x573b62('0x5')]),router[_0x573b62('0x12')]('/',auth[_0x573b62('0x10')](),controller[_0x573b62('0xf')]),router['post']('/:id/queues',auth['isAuthenticated'](),controller[_0x573b62('0x9')]),router[_0x573b62('0x12')](_0x573b62('0x11'),auth[_0x573b62('0x10')](),controller[_0x573b62('0xd')]),router[_0x573b62('0xb')](_0x573b62('0xe'),auth[_0x573b62('0x10')](),controller[_0x573b62('0x2')]),router[_0x573b62('0x1')](_0x573b62('0xe'),auth[_0x573b62('0x10')](),controller['destroy']),router[_0x573b62('0x1')]('/:id/queues',auth[_0x573b62('0x10')](),controller[_0x573b62('0x6')]),router[_0x573b62('0x1')](_0x573b62('0x11'),auth[_0x573b62('0x10')](),controller[_0x573b62('0x13')]),module[_0x573b62('0xc')]=router; \ No newline at end of file diff --git a/server/api/team/team.attributes.js b/server/api/team/team.attributes.js index d2561cc..bf8f315 100644 --- a/server/api/team/team.attributes.js +++ b/server/api/team/team.attributes.js @@ -1 +1 @@ -const a625_0x380f=['STRING','sequelize','name','exports'];(function(_0x4d18eb,_0x380f71){const _0x55383f=function(_0x49968e){while(--_0x49968e){_0x4d18eb['push'](_0x4d18eb['shift']());}};_0x55383f(++_0x380f71);}(a625_0x380f,0x12f));const a625_0x5538=function(_0x4d18eb,_0x380f71){_0x4d18eb=_0x4d18eb-0x0;let _0x55383f=a625_0x380f[_0x4d18eb];return _0x55383f;};const _0x31cb89=a625_0x5538;'use strict';const Sequelize=require(_0x31cb89('0x2'));module[_0x31cb89('0x0')]={'name':{'type':Sequelize[_0x31cb89('0x1')],'allowNull':![],'unique':_0x31cb89('0x3')},'description':{'type':Sequelize[_0x31cb89('0x1')]}}; \ No newline at end of file +const a625_0x3c01=['name','sequelize','exports'];(function(_0xdc9279,_0x3c0125){const _0xa117c0=function(_0x47375f){while(--_0x47375f){_0xdc9279['push'](_0xdc9279['shift']());}};_0xa117c0(++_0x3c0125);}(a625_0x3c01,0x85));const a625_0xa117=function(_0xdc9279,_0x3c0125){_0xdc9279=_0xdc9279-0x0;let _0xa117c0=a625_0x3c01[_0xdc9279];return _0xa117c0;};const _0x541050=a625_0xa117;'use strict';const Sequelize=require(_0x541050('0x0'));module[_0x541050('0x1')]={'name':{'type':Sequelize['STRING'],'allowNull':![],'unique':_0x541050('0x2')},'description':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/team/team.controller.js b/server/api/team/team.controller.js index b0e877f..578c26a 100644 --- a/server/api/team/team.controller.js +++ b/server/api/team/team.controller.js @@ -1 +1 @@ -const a626_0xd0d8=['Mail','offset','update','Chat','../../rediscache','each','online','Sms','SIP/%s','util','like','then','show','filter','fax','Fax','register','channel','keys','send','attributes','includeAll','fields','set','end','pick','json','map','toLowerCase','model','error','user','nolimit','removeQueues','Whatsapp','../../config/logger','userProfileId','catch','removeAgents','sms','status','sort','key','intersection','mail','get','isArray','Teams','Unknown\x20channel','UserVoiceQueueRt','emit','capitalize','limit','chat','body','VIRTUAL','create','findOne','getQueues','addQueues','options','rows','include','ids','where','omit','remove','Unable\x20to\x20retrieve\x20the\x20current\x20user','merge','getAgents','index','../../mysqldb','name','addAgents','Openchannel','upsert','whatsapp','userTeam:remove','filters','query','./team.socket','type','Queues','voicePause','User','UserProfileResource','length','sendStatus','format','params','stack','Voice','undefined','count','interface','Team','destroy','openchannel','UserProfileSection','order','isValidChannel','rawAttributes','lodash'];(function(_0x4427ef,_0xd0d8ac){const _0x3b26ce=function(_0x1146ea){while(--_0x1146ea){_0x4427ef['push'](_0x4427ef['shift']());}};_0x3b26ce(++_0xd0d8ac);}(a626_0xd0d8,0x65));const a626_0x3b26=function(_0x4427ef,_0xd0d8ac){_0x4427ef=_0x4427ef-0x0;let _0x3b26ce=a626_0xd0d8[_0x4427ef];return _0x3b26ce;};const _0x50cbe4=a626_0x3b26;'use strict';const util=require(_0x50cbe4('0xb')),_=require(_0x50cbe4('0x1')),qs=require('../../components/parsers/qs'),logger=require(_0x50cbe4('0x25'))('api'),utils=require('../../config/utils'),{getSocket}=require(_0x50cbe4('0x6')),socket=getSocket(),db=require(_0x50cbe4('0x49'))['db'],{Op,ValidationError}=require('sequelize');require(_0x50cbe4('0x52'))[_0x50cbe4('0x12')](socket);function respondWithStatusCode(_0x1146ea,_0x3217ae){return _0x3217ae=_0x3217ae||0xcc,function(_0x4ae208){const _0x498d7f=a626_0x3b26;if(_0x4ae208)return _0x1146ea[_0x498d7f('0x59')](_0x3217ae);return _0x1146ea[_0x498d7f('0x2a')](_0x3217ae)[_0x498d7f('0x1a')]();};}function respondWithResult(_0x42bd21,_0x53cfd6){return _0x53cfd6=_0x53cfd6||0xc8,function(_0x2a0d3e){const _0x392b54=a626_0x3b26;if(_0x2a0d3e)return _0x42bd21[_0x392b54('0x2a')](_0x53cfd6)['json'](_0x2a0d3e);};}function respondWithFilteredResult(_0x39d512,_0x1e7e86){return function(_0x325988){const _0x3cc887=a626_0x3b26;if(_0x325988){const _0x1c5307=_0x325988[_0x3cc887('0x5f')],_0x2cff8d=_0x1e7e86[_0x3cc887('0x3')];let _0x4e492e=_0x1e7e86[_0x3cc887('0x3')]+_0x1e7e86[_0x3cc887('0x36')],_0x5c4fbc;return _0x4e492e>=_0x1c5307?(_0x4e492e=_0x1c5307,_0x5c4fbc=0xc8):_0x5c4fbc=0xce,_0x39d512[_0x3cc887('0x2a')](_0x5c4fbc),_0x39d512[_0x3cc887('0x19')]('Content-Range',_0x2cff8d+'-'+_0x4e492e+'/'+_0x1c5307)[_0x3cc887('0x1c')](_0x325988);}return null;};}function saveUpdates(_0x343221){return function(_0x218ddf){const _0x30234f=a626_0x3b26;if(_0x218ddf)return _0x218ddf[_0x30234f('0x4')](_0x343221)['then'](function(_0x114a4e){return _0x114a4e;});return null;};}function removeEntity(_0x347af8){return function(_0x27ff4e){const _0x3120f2=a626_0x3b26;if(_0x27ff4e)return _0x27ff4e['destroy']()[_0x3120f2('0xd')](function(){const _0x217214=_0x3120f2,_0x20c21d=_0x27ff4e['get']({'plain':!![]}),_0x5b830a=_0x217214('0x31');return db[_0x217214('0x57')][_0x217214('0x62')]({'where':{'type':_0x5b830a,'resourceId':_0x20c21d['id']}})['then'](function(){return _0x27ff4e;});})[_0x3120f2('0xd')](function(){const _0x4d8acc=_0x3120f2;_0x347af8[_0x4d8acc('0x2a')](0xcc)[_0x4d8acc('0x1a')]();});};}function handleEntityNotFound(_0x35c104){return function(_0xaa5031){const _0x461200=a626_0x3b26;return!_0xaa5031&&_0x35c104[_0x461200('0x59')](0x194),_0xaa5031;};}function handleError(_0x11e439,_0x4fdf10){return _0x4fdf10=_0x4fdf10||0x1f4,function(_0x86e1f3){const _0xf02908=a626_0x3b26;logger['error'](_0x86e1f3[_0xf02908('0x5c')]),_0x86e1f3[_0xf02908('0x4a')]&&delete _0x86e1f3['name'],_0x11e439[_0xf02908('0x2a')](_0x4fdf10)[_0xf02908('0x15')](_0x86e1f3);};}exports[_0x50cbe4('0x48')]=function(_0x9a1158,_0x34b058){const _0x106723=_0x50cbe4;let _0x9412a5={};const _0x33a6ef={},_0x500d7e={'count':0x0,'rows':[]},_0x45aa2=_['map'](db[_0x106723('0x61')][_0x106723('0x0')],function(_0x4bbbf0){const _0x571d6c=_0x106723;return{'name':_0x4bbbf0['fieldName'],'type':_0x4bbbf0[_0x571d6c('0x53')][_0x571d6c('0x2c')]};});_0x33a6ef[_0x106723('0x1f')]=_[_0x106723('0x1d')](_0x45aa2,_0x106723('0x4a')),_0x33a6ef[_0x106723('0x51')]=_[_0x106723('0x14')](_0x9a1158['query']),_0x33a6ef[_0x106723('0x50')]=_['intersection'](_0x33a6ef[_0x106723('0x1f')],_0x33a6ef['query']),_0x9412a5[_0x106723('0x16')]=_[_0x106723('0x2d')](_0x33a6ef['model'],qs[_0x106723('0x18')](_0x9a1158[_0x106723('0x51')][_0x106723('0x18')])),_0x9412a5['attributes']=_0x9412a5[_0x106723('0x16')][_0x106723('0x58')]?_0x9412a5[_0x106723('0x16')]:_0x33a6ef[_0x106723('0x1f')];typeof _0x9a1158[_0x106723('0x51')]['nolimit']===_0x106723('0x5e')&&(_0x9412a5['limit']=qs['limit'](_0x9a1158[_0x106723('0x51')][_0x106723('0x36')]),_0x9412a5[_0x106723('0x3')]=qs[_0x106723('0x3')](_0x9a1158[_0x106723('0x51')][_0x106723('0x3')]));_0x9412a5[_0x106723('0x65')]=qs[_0x106723('0x2b')](_0x9a1158[_0x106723('0x51')][_0x106723('0x2b')]),_0x9412a5[_0x106723('0x42')]=qs[_0x106723('0x50')](_[_0x106723('0x1b')](_0x9a1158[_0x106723('0x51')],_0x33a6ef[_0x106723('0x50')]),_0x45aa2);_0x9a1158[_0x106723('0x51')]['filter']&&(_0x9412a5[_0x106723('0x42')]=_[_0x106723('0x46')](_0x9412a5[_0x106723('0x42')],{[Op['or']]:_[_0x106723('0x1d')](_0x45aa2,function(_0x469f25){const _0x5ce995=_0x106723;if(_0x469f25['type']!==_0x5ce995('0x39')){const _0x724ae5={};return _0x724ae5[_0x469f25[_0x5ce995('0x4a')]]={[Op[_0x5ce995('0xc')]]:'%'+_0x9a1158[_0x5ce995('0x51')][_0x5ce995('0xf')]+'%'},_0x724ae5;}})}));_0x9412a5=_[_0x106723('0x46')]({},_0x9412a5,_0x9a1158[_0x106723('0x3e')]);const _0x18691f={'where':_0x9412a5[_0x106723('0x42')]};return db['Team'][_0x106723('0x5f')](_0x18691f)[_0x106723('0xd')](function(_0x273169){const _0x2c1cf6=_0x106723;return _0x500d7e[_0x2c1cf6('0x5f')]=_0x273169,_0x9a1158[_0x2c1cf6('0x51')][_0x2c1cf6('0x17')]&&(_0x9412a5[_0x2c1cf6('0x40')]=[{'all':!![]}]),db['Team']['findAll'](_0x9412a5);})['then'](function(_0x168931){const _0x3ca674=_0x106723;return _0x500d7e[_0x3ca674('0x3f')]=_0x168931,_0x500d7e;})['then'](respondWithFilteredResult(_0x34b058,_0x9412a5))[_0x106723('0x27')](handleError(_0x34b058,null));},exports[_0x50cbe4('0xe')]=function(_0x256292,_0x5205f3){const _0x5789e0=_0x50cbe4;let _0xcf0a6c={'raw':![],'where':{'id':_0x256292['params']['id']}};const _0x191f42={};return _0x191f42[_0x5789e0('0x1f')]=_[_0x5789e0('0x14')](db[_0x5789e0('0x61')][_0x5789e0('0x0')]),_0x191f42['query']=_['keys'](_0x256292[_0x5789e0('0x51')]),_0x191f42[_0x5789e0('0x50')]=_['intersection'](_0x191f42['model'],_0x191f42[_0x5789e0('0x51')]),_0xcf0a6c[_0x5789e0('0x16')]=_[_0x5789e0('0x2d')](_0x191f42[_0x5789e0('0x1f')],qs[_0x5789e0('0x18')](_0x256292[_0x5789e0('0x51')][_0x5789e0('0x18')])),_0xcf0a6c[_0x5789e0('0x16')]=_0xcf0a6c[_0x5789e0('0x16')][_0x5789e0('0x58')]?_0xcf0a6c[_0x5789e0('0x16')]:_0x191f42[_0x5789e0('0x1f')],_0x256292[_0x5789e0('0x51')][_0x5789e0('0x17')]&&(_0xcf0a6c[_0x5789e0('0x40')]=[{'all':!![]}]),_0xcf0a6c=_[_0x5789e0('0x46')]({},_0xcf0a6c,_0x256292['options']),db[_0x5789e0('0x61')][_0x5789e0('0x3b')](_0xcf0a6c)[_0x5789e0('0xd')](handleEntityNotFound(_0x5205f3,null))[_0x5789e0('0xd')](respondWithResult(_0x5205f3,null))[_0x5789e0('0x27')](handleError(_0x5205f3,null));},exports[_0x50cbe4('0x3a')]=function(_0xcb07e,_0x2bbf20){const _0x2a450e=_0x50cbe4;return db[_0x2a450e('0x61')]['create'](_0xcb07e[_0x2a450e('0x38')],{})[_0x2a450e('0xd')](function(_0x34361a){const _0x7e4d7f=_0x2a450e,_0x3b9a9c=_0xcb07e[_0x7e4d7f('0x21')][_0x7e4d7f('0x2f')]({'plain':!![]});if(!_0x3b9a9c)throw new Error(_0x7e4d7f('0x45'));if(_0x3b9a9c['role']===_0x7e4d7f('0x21')){const _0x5df061=_0x34361a[_0x7e4d7f('0x2f')]({'plain':!![]}),_0x3a02db='Teams';return db[_0x7e4d7f('0x64')][_0x7e4d7f('0x3b')]({'where':{'name':_0x3a02db,'userProfileId':_0x3b9a9c[_0x7e4d7f('0x26')]},'raw':!![]})[_0x7e4d7f('0xd')](function(_0x3474bc){const _0x86b2a=_0x7e4d7f;return _0x3474bc&&_0x3474bc['autoAssociation']===0x0?db[_0x86b2a('0x57')][_0x86b2a('0x3a')]({'name':_0x5df061[_0x86b2a('0x4a')],'resourceId':_0x5df061['id'],'type':_0x3474bc['name'],'sectionId':_0x3474bc['id']},{})[_0x86b2a('0xd')](function(){return _0x34361a;}):_0x34361a;})['catch'](function(_0x1553c2){const _0x1acc84=_0x7e4d7f;logger[_0x1acc84('0x20')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x1553c2);throw _0x1553c2;});}return _0x34361a;})[_0x2a450e('0xd')](respondWithResult(_0x2bbf20,0xc9))[_0x2a450e('0x27')](handleError(_0x2bbf20,null));},exports['update']=function(_0x248012,_0x160e62){const _0x26dc62=_0x50cbe4;return _0x248012[_0x26dc62('0x38')]['id']&&delete _0x248012['body']['id'],db[_0x26dc62('0x61')][_0x26dc62('0x3b')]({'where':{'id':_0x248012[_0x26dc62('0x5b')]['id']}})[_0x26dc62('0xd')](handleEntityNotFound(_0x160e62,null))['then'](saveUpdates(_0x248012['body'],null))['then'](respondWithResult(_0x160e62,null))['catch'](handleError(_0x160e62,null));},exports['destroy']=function(_0x269a67,_0x5f4b8b){const _0x5be28d=_0x50cbe4;return db[_0x5be28d('0x61')]['findOne']({'where':{'id':_0x269a67[_0x5be28d('0x5b')]['id']}})[_0x5be28d('0xd')](handleEntityNotFound(_0x5f4b8b,null))['then'](removeEntity(_0x5f4b8b,null))[_0x5be28d('0x27')](handleError(_0x5f4b8b,null));},exports[_0x50cbe4('0x3c')]=function(_0x4fa678,_0x32ad3d){const _0x54a778=_0x50cbe4;return db[_0x54a778('0x61')][_0x54a778('0x3b')]({'where':{'id':_0x4fa678[_0x54a778('0x5b')]['id']}})['then'](handleEntityNotFound(_0x32ad3d,null))['then'](function(_0x4f3648){const _0x2cbcf4=_0x54a778;if(!_0x4fa678['query'][_0x2cbcf4('0x13')]||!utils[_0x2cbcf4('0x66')](_0x4fa678[_0x2cbcf4('0x51')][_0x2cbcf4('0x13')]))throw new ValidationError('Unknown\x20channel');let _0x45e36d={};const _0x674840={};return _0x674840[_0x2cbcf4('0x1f')]=_[_0x2cbcf4('0x14')](db[_['capitalize'](_0x4fa678[_0x2cbcf4('0x51')]['channel'][_0x2cbcf4('0x1e')]())+'Queue'][_0x2cbcf4('0x0')]),_0x674840['query']=_[_0x2cbcf4('0x14')](_0x4fa678[_0x2cbcf4('0x51')]),_0x674840[_0x2cbcf4('0x50')]=_[_0x2cbcf4('0x2d')](_0x674840[_0x2cbcf4('0x1f')],_0x674840[_0x2cbcf4('0x51')]),_0x45e36d[_0x2cbcf4('0x16')]=_['intersection'](_0x674840['model'],qs[_0x2cbcf4('0x18')](_0x4fa678[_0x2cbcf4('0x51')]['fields'])),_0x45e36d[_0x2cbcf4('0x16')]=_0x45e36d[_0x2cbcf4('0x16')][_0x2cbcf4('0x58')]?_0x45e36d[_0x2cbcf4('0x16')]:_0x674840[_0x2cbcf4('0x1f')],_0x45e36d[_0x2cbcf4('0x36')]=qs[_0x2cbcf4('0x36')](_0x4fa678[_0x2cbcf4('0x51')][_0x2cbcf4('0x36')]),_0x45e36d[_0x2cbcf4('0x3')]=qs[_0x2cbcf4('0x3')](_0x4fa678['query'][_0x2cbcf4('0x3')]),_0x45e36d[_0x2cbcf4('0x65')]=qs[_0x2cbcf4('0x2b')](_0x4fa678[_0x2cbcf4('0x51')][_0x2cbcf4('0x2b')]),_0x45e36d['where']=qs['filters'](_['pick'](_0x4fa678[_0x2cbcf4('0x51')],_0x674840['filters'])),_0x45e36d=_[_0x2cbcf4('0x46')]({},_0x45e36d,_0x4fa678[_0x2cbcf4('0x3e')]),_0x4f3648['get'+_[_0x2cbcf4('0x35')](_0x4fa678['query'][_0x2cbcf4('0x13')][_0x2cbcf4('0x1e')]())+'Queues'](_0x45e36d);})[_0x54a778('0xd')](respondWithResult(_0x32ad3d,null))[_0x54a778('0x27')](handleError(_0x32ad3d,null));},exports[_0x50cbe4('0x3d')]=function(_0x1c216a,_0x5ea2e7){const _0x566d5f=_0x50cbe4;return db[_0x566d5f('0x61')][_0x566d5f('0x3b')]({'where':{'id':_0x1c216a[_0x566d5f('0x5b')]['id']}})[_0x566d5f('0xd')](function(_0x33807b){const _0x1171d0=_0x566d5f;if(_0x33807b){if(!_0x1c216a[_0x1171d0('0x38')][_0x1171d0('0x13')]||!utils['isValidChannel'](_0x1c216a[_0x1171d0('0x38')][_0x1171d0('0x13')]))throw new ValidationError('Unknown\x20channel');return _0x33807b['add'+_[_0x1171d0('0x35')](_0x1c216a[_0x1171d0('0x38')][_0x1171d0('0x13')][_0x1171d0('0x1e')]())+'Queues'](_0x1c216a[_0x1171d0('0x38')][_0x1171d0('0x41')]);}return null;})[_0x566d5f('0xd')](handleEntityNotFound(_0x5ea2e7,null))[_0x566d5f('0xd')](respondWithStatusCode(_0x5ea2e7,null))[_0x566d5f('0x27')](handleError(_0x5ea2e7,null));},exports[_0x50cbe4('0x23')]=function(_0x592d03,_0x434170){const _0x510c78=_0x50cbe4;return db[_0x510c78('0x61')]['findOne']({'where':{'id':_0x592d03[_0x510c78('0x5b')]['id']}})[_0x510c78('0xd')](function(_0x7f2b57){const _0x4c82d5=_0x510c78;if(_0x7f2b57){if(!_0x592d03['query']['channel']||!utils['isValidChannel'](_0x592d03[_0x4c82d5('0x51')][_0x4c82d5('0x13')]))throw new ValidationError(_0x4c82d5('0x32'));return _0x7f2b57[_0x4c82d5('0x44')+_['capitalize'](_0x592d03[_0x4c82d5('0x51')][_0x4c82d5('0x13')][_0x4c82d5('0x1e')]())+_0x4c82d5('0x54')](_0x592d03[_0x4c82d5('0x51')]['ids']);}return null;})[_0x510c78('0xd')](handleEntityNotFound(_0x434170,null))[_0x510c78('0xd')](respondWithStatusCode(_0x434170,null))[_0x510c78('0x27')](handleError(_0x434170,null));},exports[_0x50cbe4('0x4b')]=function(_0x198acd,_0x570037){const _0x226747=_0x50cbe4;return db[_0x226747('0x61')][_0x226747('0x3b')]({'where':{'id':_0x198acd['params']['id']}})[_0x226747('0xd')](function(_0x1841b7){const _0xe02942=_0x226747;if(_0x1841b7){const _0x3d09fd=[_0xe02942('0x5d'),_0xe02942('0x5'),_0xe02942('0x2'),_0xe02942('0x9'),_0xe02942('0x11'),_0xe02942('0x4c'),_0xe02942('0x24')];return Promise[_0xe02942('0x7')](_0x3d09fd,function(_0x56b460){const _0x5288ad=_0xe02942;return _0x1841b7['get'+_0x56b460+_0x5288ad('0x54')]({'attributes':['id','name']})[_0x5288ad('0xd')](function(_0x54df62){const _0x292c7c=_0x5288ad;return Promise[_0x292c7c('0x7')](_0x54df62,function(_0x47d653){const _0x217f9b=_0x292c7c;return _0x47d653[_0x217f9b('0x4b')](_0x198acd[_0x217f9b('0x38')][_0x217f9b('0x41')])[_0x217f9b('0xd')](function(){const _0x4b52c4=_0x217f9b;if(_0x56b460==='Voice')return db[_0x4b52c4('0x56')]['findAll']({'where':{'id':_0x198acd[_0x4b52c4('0x38')][_0x4b52c4('0x41')]},'attributes':['id','name',_0x4b52c4('0x8'),_0x4b52c4('0x55'),_0x4b52c4('0x60')],'raw':!![]})['then'](function(_0x499d5a){const _0x472f96=_0x4b52c4;return Promise[_0x472f96('0x7')](_['filter'](_0x499d5a,{'online':0x1}),function(_0x174e84){const _0x15a6ab=_0x472f96;return db[_0x15a6ab('0x33')][_0x15a6ab('0x4d')]({'membername':_0x174e84['name'],'UserId':_0x174e84['id'],'queue_name':_0x47d653[_0x15a6ab('0x4a')],'VoiceQueueId':_0x47d653['id'],'interface':_['isNil'](_0x174e84['interface'])?util[_0x15a6ab('0x5a')](_0x15a6ab('0xa'),_0x174e84[_0x15a6ab('0x4a')]):_0x174e84['interface'],'paused':_0x174e84[_0x15a6ab('0x55')]||![],'penalty':0x0});});});});});})[_0x5288ad('0xd')](function(){return _0x1841b7;});})[_0xe02942('0xd')](function(){return _0x1841b7;});}})[_0x226747('0xd')](function(_0xcfa75a){const _0x599b45=_0x226747;if(_0xcfa75a)return _0xcfa75a[_0x599b45('0x4b')](_0x198acd[_0x599b45('0x38')][_0x599b45('0x41')],{'through':_[_0x599b45('0x43')](_0x198acd['body'],[_0x599b45('0x41'),'id'])})[_0x599b45('0xd')](function(_0x56323d){const _0x417dcc=_0x599b45;for(let _0xdbb734=0x0;_0xdbb734<_0x198acd[_0x417dcc('0x38')][_0x417dcc('0x41')][_0x417dcc('0x58')];_0xdbb734+=0x1){socket[_0x417dcc('0x34')]('userTeam:save',{'UserId':_0x198acd['body'][_0x417dcc('0x41')][_0xdbb734],'TeamId':_0x198acd['params']['id']});}return _0x56323d;});})[_0x226747('0xd')](respondWithResult(_0x570037,null))[_0x226747('0x27')](handleError(_0x570037,null));},exports[_0x50cbe4('0x28')]=function(_0x245dd5,_0x1fdb7f){const _0x5b1c4d=_0x50cbe4;return db[_0x5b1c4d('0x61')]['findOne']({'where':{'id':_0x245dd5[_0x5b1c4d('0x5b')]['id']}})['then'](handleEntityNotFound(_0x1fdb7f,null))[_0x5b1c4d('0xd')](function(_0x237ffe){const _0x204620=_0x5b1c4d;if(_0x237ffe)return Promise['each'](['voice',_0x204620('0x37'),_0x204620('0x2e'),_0x204620('0x29'),_0x204620('0x10'),_0x204620('0x63'),_0x204620('0x4e')],function(_0x239615){const _0xcbafdf=_0x204620;return _0x237ffe['get'+_['capitalize'](_0x239615)+_0xcbafdf('0x54')]({'attributes':['id',_0xcbafdf('0x4a')]})[_0xcbafdf('0xd')](function(_0x4c22fc){const _0x1e9290=_0xcbafdf;return Promise[_0x1e9290('0x7')](_0x4c22fc,function(_0x5c1609){const _0x1cd38a=_0x1e9290;return _0x5c1609[_0x1cd38a('0x28')](_0x245dd5[_0x1cd38a('0x51')][_0x1cd38a('0x41')])['then'](function(){const _0x2c47a6=_0x1cd38a;if(_0x239615==='voice')return db['UserVoiceQueueRt'][_0x2c47a6('0x62')]({'where':{'VoiceQueueId':_0x5c1609['id'],'UserId':_0x245dd5[_0x2c47a6('0x51')][_0x2c47a6('0x41')]}});});});})[_0xcbafdf('0xd')](function(){return _0x237ffe;});})[_0x204620('0xd')](function(){return _0x237ffe;});})[_0x5b1c4d('0xd')](function(_0x25038a){const _0x264349=_0x5b1c4d;if(_0x25038a)return _0x25038a[_0x264349('0x28')](_0x245dd5[_0x264349('0x51')]['ids'])[_0x264349('0xd')](function(){const _0xe94c8c=_0x264349;if(_[_0xe94c8c('0x30')](_0x245dd5[_0xe94c8c('0x51')][_0xe94c8c('0x41')]))for(let _0x5a223d=0x0;_0x5a223d<_0x245dd5[_0xe94c8c('0x51')][_0xe94c8c('0x41')][_0xe94c8c('0x58')];_0x5a223d+=0x1){socket[_0xe94c8c('0x34')](_0xe94c8c('0x4f'),{'UserId':Number(_0x245dd5[_0xe94c8c('0x51')][_0xe94c8c('0x41')][_0x5a223d]),'TeamId':Number(_0x245dd5['params']['id'])});}else socket['emit'](_0xe94c8c('0x4f'),{'UserId':Number(_0x245dd5[_0xe94c8c('0x51')][_0xe94c8c('0x41')]),'TeamId':Number(_0x245dd5[_0xe94c8c('0x5b')]['id'])});});})[_0x5b1c4d('0xd')](respondWithStatusCode(_0x1fdb7f,null))[_0x5b1c4d('0x27')](handleError(_0x1fdb7f,null));},exports[_0x50cbe4('0x47')]=function(_0x17afab,_0x295cb2){const _0xf952e7=_0x50cbe4;let _0x23ebc0={};const _0x5b4816={};let _0x176a46,_0x1bb6f3;return db[_0xf952e7('0x61')][_0xf952e7('0x3b')]({'where':{'id':_0x17afab[_0xf952e7('0x5b')]['id']}})['then'](handleEntityNotFound(_0x295cb2,null))[_0xf952e7('0xd')](function(_0x504882){const _0x2117fd=_0xf952e7;if(_0x504882)return _0x176a46=_0x504882,_0x5b4816[_0x2117fd('0x1f')]=_['keys'](db[_0x2117fd('0x56')][_0x2117fd('0x0')]),_0x5b4816[_0x2117fd('0x51')]=_[_0x2117fd('0x14')](_0x17afab[_0x2117fd('0x51')]),_0x5b4816[_0x2117fd('0x50')]=_[_0x2117fd('0x2d')](_0x5b4816[_0x2117fd('0x1f')],_0x5b4816[_0x2117fd('0x51')]),_0x23ebc0[_0x2117fd('0x16')]=_['intersection'](_0x5b4816[_0x2117fd('0x1f')],qs[_0x2117fd('0x18')](_0x17afab['query']['fields'])),_0x23ebc0[_0x2117fd('0x16')]=_0x23ebc0[_0x2117fd('0x16')][_0x2117fd('0x58')]?_0x23ebc0['attributes']:_0x5b4816['model'],_0x23ebc0[_0x2117fd('0x65')]=qs[_0x2117fd('0x2b')](_0x17afab[_0x2117fd('0x51')]['sort']),_0x23ebc0[_0x2117fd('0x42')]=qs[_0x2117fd('0x50')](_[_0x2117fd('0x1b')](_0x17afab['query'],_0x5b4816[_0x2117fd('0x50')])),_0x17afab[_0x2117fd('0x51')][_0x2117fd('0xf')]&&(_0x23ebc0[_0x2117fd('0x42')]=_[_0x2117fd('0x46')](_0x23ebc0[_0x2117fd('0x42')],{[Op['or']]:_[_0x2117fd('0x1d')](_0x23ebc0[_0x2117fd('0x16')],function(_0x551f27){const _0x488d0b=_0x2117fd,_0x3a345b={};return _0x3a345b[_0x551f27]={[Op[_0x488d0b('0xc')]]:'%'+_0x17afab[_0x488d0b('0x51')][_0x488d0b('0xf')]+'%'},_0x3a345b;})})),_0x23ebc0=_[_0x2117fd('0x46')]({},_0x23ebc0,_0x17afab[_0x2117fd('0x3e')]),_0x176a46['getAgents'](_0x23ebc0);})[_0xf952e7('0xd')](function(_0x5d571d){const _0x1b0ee7=_0xf952e7;if(_0x5d571d)return _0x1bb6f3=_0x5d571d[_0x1b0ee7('0x58')],typeof _0x17afab[_0x1b0ee7('0x51')][_0x1b0ee7('0x22')]==='undefined'&&(_0x23ebc0['limit']=qs[_0x1b0ee7('0x36')](_0x17afab[_0x1b0ee7('0x51')][_0x1b0ee7('0x36')]),_0x23ebc0['offset']=qs[_0x1b0ee7('0x3')](_0x17afab[_0x1b0ee7('0x51')][_0x1b0ee7('0x3')])),_0x176a46[_0x1b0ee7('0x47')](_0x23ebc0);})[_0xf952e7('0xd')](function(_0x381830){if(_0x381830)return _0x381830?{'count':_0x1bb6f3,'rows':_0x381830}:null;})[_0xf952e7('0xd')](respondWithResult(_0x295cb2,null))[_0xf952e7('0x27')](handleError(_0x295cb2,null));}; \ No newline at end of file +const a626_0x174d=['emit','remove','show','fields','send','getQueues','Openchannel','Fax','Mail','offset','order','channel','create','attributes','isValidChannel','upsert','length','model','isNil','then','Unknown\x20channel','count','rawAttributes','limit','options','voice','undefined','catch','register','includeAll','../../components/parsers/qs','sendStatus','mail','like','intersection','Whatsapp','update','removeAgents','pick','../../config/logger','map','autoAssociation','getAgents','online','json','User','ids','addAgents','addQueues','error','where','findAll','query','./team.socket','type','../../rediscache','Teams','sort','../../config/utils','include','end','Queues','params','get','UserProfileSection','rows','set','role','body','fieldName','removeQueues','SIP/%s','chat','Unable\x20to\x20retrieve\x20the\x20current\x20user','filter','user','Voice','findOne','Content-Range','index','add','status','lodash','each','interface','Chat','toLowerCase','userTeam:remove','userTeam:save','capitalize','util','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','Team','omit','voicePause','merge','format','destroy','UserProfileResource','filters','sms','../../mysqldb','userProfileId','fax','keys','name','api','UserVoiceQueueRt'];(function(_0x441d43,_0x174db1){const _0x45357d=function(_0x18e801){while(--_0x18e801){_0x441d43['push'](_0x441d43['shift']());}};_0x45357d(++_0x174db1);}(a626_0x174d,0x159));const a626_0x4535=function(_0x441d43,_0x174db1){_0x441d43=_0x441d43-0x0;let _0x45357d=a626_0x174d[_0x441d43];return _0x45357d;};const _0x5794f5=a626_0x4535;'use strict';const util=require(_0x5794f5('0x45')),_=require(_0x5794f5('0x3d')),qs=require(_0x5794f5('0x9')),logger=require(_0x5794f5('0x12'))(_0x5794f5('0x55')),utils=require(_0x5794f5('0x25')),{getSocket}=require(_0x5794f5('0x22')),socket=getSocket(),db=require(_0x5794f5('0x50'))['db'],{Op,ValidationError}=require('sequelize');require(_0x5794f5('0x20'))[_0x5794f5('0x7')](socket);function respondWithStatusCode(_0x18e801,_0x2aa974){return _0x2aa974=_0x2aa974||0xcc,function(_0x103595){const _0x7f71b6=a626_0x4535;if(_0x103595)return _0x18e801[_0x7f71b6('0xa')](_0x2aa974);return _0x18e801['status'](_0x2aa974)[_0x7f71b6('0x27')]();};}function respondWithResult(_0x48f412,_0x589660){return _0x589660=_0x589660||0xc8,function(_0x19e1d3){const _0x13b524=a626_0x4535;if(_0x19e1d3)return _0x48f412[_0x13b524('0x3c')](_0x589660)[_0x13b524('0x17')](_0x19e1d3);};}function respondWithFilteredResult(_0x196215,_0x1601f3){return function(_0x34a96a){const _0xb398c8=a626_0x4535;if(_0x34a96a){const _0x22b779=_0x34a96a[_0xb398c8('0x0')],_0x5939bc=_0x1601f3['offset'];let _0x3b3af9=_0x1601f3[_0xb398c8('0x60')]+_0x1601f3[_0xb398c8('0x2')],_0x4a0326;return _0x3b3af9>=_0x22b779?(_0x3b3af9=_0x22b779,_0x4a0326=0xc8):_0x4a0326=0xce,_0x196215[_0xb398c8('0x3c')](_0x4a0326),_0x196215[_0xb398c8('0x2d')](_0xb398c8('0x39'),_0x5939bc+'-'+_0x3b3af9+'/'+_0x22b779)[_0xb398c8('0x17')](_0x34a96a);}return null;};}function saveUpdates(_0x4e3a5e){return function(_0x1e0ae9){const _0x1a0241=a626_0x4535;if(_0x1e0ae9)return _0x1e0ae9[_0x1a0241('0xf')](_0x4e3a5e)['then'](function(_0x40e9b8){return _0x40e9b8;});return null;};}function removeEntity(_0x36959c){return function(_0x2061b0){const _0x5e2a90=a626_0x4535;if(_0x2061b0)return _0x2061b0[_0x5e2a90('0x4c')]()[_0x5e2a90('0x6a')](function(){const _0x2e4693=_0x5e2a90,_0x177ca1=_0x2061b0[_0x2e4693('0x2a')]({'plain':!![]}),_0x2a28ab='Teams';return db[_0x2e4693('0x4d')][_0x2e4693('0x4c')]({'where':{'type':_0x2a28ab,'resourceId':_0x177ca1['id']}})[_0x2e4693('0x6a')](function(){return _0x2061b0;});})[_0x5e2a90('0x6a')](function(){const _0x3a1ae0=_0x5e2a90;_0x36959c['status'](0xcc)[_0x3a1ae0('0x27')]();});};}function handleEntityNotFound(_0x1e6407){return function(_0x5cb6be){return!_0x5cb6be&&_0x1e6407['sendStatus'](0x194),_0x5cb6be;};}function handleError(_0x52a00d,_0x252ca8){return _0x252ca8=_0x252ca8||0x1f4,function(_0x141552){const _0x24f5b2=a626_0x4535;logger[_0x24f5b2('0x1c')](_0x141552['stack']),_0x141552[_0x24f5b2('0x54')]&&delete _0x141552['name'],_0x52a00d[_0x24f5b2('0x3c')](_0x252ca8)[_0x24f5b2('0x5b')](_0x141552);};}exports[_0x5794f5('0x3a')]=function(_0x170bcd,_0x300750){const _0x1ef617=_0x5794f5;let _0x1e66c1={};const _0xbb1e68={},_0x568845={'count':0x0,'rows':[]},_0x19f409=_[_0x1ef617('0x13')](db[_0x1ef617('0x47')]['rawAttributes'],function(_0x31b925){const _0x318a0c=_0x1ef617;return{'name':_0x31b925[_0x318a0c('0x30')],'type':_0x31b925[_0x318a0c('0x21')]['key']};});_0xbb1e68[_0x1ef617('0x68')]=_[_0x1ef617('0x13')](_0x19f409,'name'),_0xbb1e68[_0x1ef617('0x1f')]=_[_0x1ef617('0x53')](_0x170bcd[_0x1ef617('0x1f')]),_0xbb1e68['filters']=_[_0x1ef617('0xd')](_0xbb1e68[_0x1ef617('0x68')],_0xbb1e68[_0x1ef617('0x1f')]),_0x1e66c1[_0x1ef617('0x64')]=_['intersection'](_0xbb1e68[_0x1ef617('0x68')],qs['fields'](_0x170bcd['query'][_0x1ef617('0x5a')])),_0x1e66c1[_0x1ef617('0x64')]=_0x1e66c1[_0x1ef617('0x64')][_0x1ef617('0x67')]?_0x1e66c1[_0x1ef617('0x64')]:_0xbb1e68['model'];typeof _0x170bcd[_0x1ef617('0x1f')]['nolimit']===_0x1ef617('0x5')&&(_0x1e66c1[_0x1ef617('0x2')]=qs['limit'](_0x170bcd[_0x1ef617('0x1f')]['limit']),_0x1e66c1['offset']=qs[_0x1ef617('0x60')](_0x170bcd[_0x1ef617('0x1f')]['offset']));_0x1e66c1[_0x1ef617('0x61')]=qs[_0x1ef617('0x24')](_0x170bcd[_0x1ef617('0x1f')][_0x1ef617('0x24')]),_0x1e66c1['where']=qs[_0x1ef617('0x4e')](_['pick'](_0x170bcd['query'],_0xbb1e68[_0x1ef617('0x4e')]),_0x19f409);_0x170bcd[_0x1ef617('0x1f')][_0x1ef617('0x35')]&&(_0x1e66c1[_0x1ef617('0x1d')]=_[_0x1ef617('0x4a')](_0x1e66c1[_0x1ef617('0x1d')],{[Op['or']]:_[_0x1ef617('0x13')](_0x19f409,function(_0x22e71b){const _0x3e6c3e=_0x1ef617;if(_0x22e71b['type']!=='VIRTUAL'){const _0x2fafe6={};return _0x2fafe6[_0x22e71b[_0x3e6c3e('0x54')]]={[Op[_0x3e6c3e('0xc')]]:'%'+_0x170bcd['query'][_0x3e6c3e('0x35')]+'%'},_0x2fafe6;}})}));_0x1e66c1=_['merge']({},_0x1e66c1,_0x170bcd[_0x1ef617('0x3')]);const _0x879baf={'where':_0x1e66c1[_0x1ef617('0x1d')]};return db[_0x1ef617('0x47')][_0x1ef617('0x0')](_0x879baf)[_0x1ef617('0x6a')](function(_0x2f8a46){const _0xb9b372=_0x1ef617;return _0x568845[_0xb9b372('0x0')]=_0x2f8a46,_0x170bcd[_0xb9b372('0x1f')][_0xb9b372('0x8')]&&(_0x1e66c1[_0xb9b372('0x26')]=[{'all':!![]}]),db[_0xb9b372('0x47')]['findAll'](_0x1e66c1);})[_0x1ef617('0x6a')](function(_0x2fe1f0){const _0x3ee640=_0x1ef617;return _0x568845[_0x3ee640('0x2c')]=_0x2fe1f0,_0x568845;})[_0x1ef617('0x6a')](respondWithFilteredResult(_0x300750,_0x1e66c1))[_0x1ef617('0x6')](handleError(_0x300750,null));},exports[_0x5794f5('0x59')]=function(_0x4adf31,_0x14803e){const _0x2fc3a2=_0x5794f5;let _0x4fbfba={'raw':![],'where':{'id':_0x4adf31[_0x2fc3a2('0x29')]['id']}};const _0x4abe0c={};return _0x4abe0c['model']=_['keys'](db['Team'][_0x2fc3a2('0x1')]),_0x4abe0c[_0x2fc3a2('0x1f')]=_[_0x2fc3a2('0x53')](_0x4adf31['query']),_0x4abe0c[_0x2fc3a2('0x4e')]=_[_0x2fc3a2('0xd')](_0x4abe0c[_0x2fc3a2('0x68')],_0x4abe0c[_0x2fc3a2('0x1f')]),_0x4fbfba[_0x2fc3a2('0x64')]=_[_0x2fc3a2('0xd')](_0x4abe0c['model'],qs[_0x2fc3a2('0x5a')](_0x4adf31[_0x2fc3a2('0x1f')][_0x2fc3a2('0x5a')])),_0x4fbfba[_0x2fc3a2('0x64')]=_0x4fbfba[_0x2fc3a2('0x64')]['length']?_0x4fbfba[_0x2fc3a2('0x64')]:_0x4abe0c[_0x2fc3a2('0x68')],_0x4adf31[_0x2fc3a2('0x1f')][_0x2fc3a2('0x8')]&&(_0x4fbfba[_0x2fc3a2('0x26')]=[{'all':!![]}]),_0x4fbfba=_[_0x2fc3a2('0x4a')]({},_0x4fbfba,_0x4adf31[_0x2fc3a2('0x3')]),db[_0x2fc3a2('0x47')][_0x2fc3a2('0x38')](_0x4fbfba)[_0x2fc3a2('0x6a')](handleEntityNotFound(_0x14803e,null))['then'](respondWithResult(_0x14803e,null))[_0x2fc3a2('0x6')](handleError(_0x14803e,null));},exports[_0x5794f5('0x63')]=function(_0x21b1cb,_0x4c0d6a){const _0x151997=_0x5794f5;return db[_0x151997('0x47')]['create'](_0x21b1cb['body'],{})[_0x151997('0x6a')](function(_0x1bcff5){const _0x2639b7=_0x151997,_0x6be624=_0x21b1cb[_0x2639b7('0x36')]['get']({'plain':!![]});if(!_0x6be624)throw new Error(_0x2639b7('0x34'));if(_0x6be624[_0x2639b7('0x2e')]===_0x2639b7('0x36')){const _0x72bfb3=_0x1bcff5[_0x2639b7('0x2a')]({'plain':!![]}),_0x15ff9c=_0x2639b7('0x23');return db[_0x2639b7('0x2b')][_0x2639b7('0x38')]({'where':{'name':_0x15ff9c,'userProfileId':_0x6be624[_0x2639b7('0x51')]},'raw':!![]})[_0x2639b7('0x6a')](function(_0x5550a3){const _0xca8b10=_0x2639b7;return _0x5550a3&&_0x5550a3[_0xca8b10('0x14')]===0x0?db[_0xca8b10('0x4d')][_0xca8b10('0x63')]({'name':_0x72bfb3['name'],'resourceId':_0x72bfb3['id'],'type':_0x5550a3[_0xca8b10('0x54')],'sectionId':_0x5550a3['id']},{})[_0xca8b10('0x6a')](function(){return _0x1bcff5;}):_0x1bcff5;})[_0x2639b7('0x6')](function(_0x2ff30b){const _0x317a01=_0x2639b7;logger['error'](_0x317a01('0x46'),_0x2ff30b);throw _0x2ff30b;});}return _0x1bcff5;})[_0x151997('0x6a')](respondWithResult(_0x4c0d6a,0xc9))[_0x151997('0x6')](handleError(_0x4c0d6a,null));},exports['update']=function(_0x4efaa5,_0x69c332){const _0xc4bc67=_0x5794f5;return _0x4efaa5[_0xc4bc67('0x2f')]['id']&&delete _0x4efaa5[_0xc4bc67('0x2f')]['id'],db[_0xc4bc67('0x47')][_0xc4bc67('0x38')]({'where':{'id':_0x4efaa5[_0xc4bc67('0x29')]['id']}})[_0xc4bc67('0x6a')](handleEntityNotFound(_0x69c332,null))['then'](saveUpdates(_0x4efaa5[_0xc4bc67('0x2f')],null))[_0xc4bc67('0x6a')](respondWithResult(_0x69c332,null))[_0xc4bc67('0x6')](handleError(_0x69c332,null));},exports[_0x5794f5('0x4c')]=function(_0x1c9874,_0x4e6b0b){const _0x374fcd=_0x5794f5;return db[_0x374fcd('0x47')][_0x374fcd('0x38')]({'where':{'id':_0x1c9874[_0x374fcd('0x29')]['id']}})[_0x374fcd('0x6a')](handleEntityNotFound(_0x4e6b0b,null))[_0x374fcd('0x6a')](removeEntity(_0x4e6b0b,null))['catch'](handleError(_0x4e6b0b,null));},exports[_0x5794f5('0x5c')]=function(_0x4a4b83,_0x5a0576){const _0x1ee521=_0x5794f5;return db['Team'][_0x1ee521('0x38')]({'where':{'id':_0x4a4b83[_0x1ee521('0x29')]['id']}})[_0x1ee521('0x6a')](handleEntityNotFound(_0x5a0576,null))[_0x1ee521('0x6a')](function(_0x24151e){const _0x23ded5=_0x1ee521;if(!_0x4a4b83['query'][_0x23ded5('0x62')]||!utils[_0x23ded5('0x65')](_0x4a4b83['query']['channel']))throw new ValidationError(_0x23ded5('0x6b'));let _0x4ec93a={};const _0x10ed2c={};return _0x10ed2c[_0x23ded5('0x68')]=_['keys'](db[_[_0x23ded5('0x44')](_0x4a4b83['query'][_0x23ded5('0x62')][_0x23ded5('0x41')]())+'Queue'][_0x23ded5('0x1')]),_0x10ed2c[_0x23ded5('0x1f')]=_[_0x23ded5('0x53')](_0x4a4b83['query']),_0x10ed2c[_0x23ded5('0x4e')]=_[_0x23ded5('0xd')](_0x10ed2c[_0x23ded5('0x68')],_0x10ed2c['query']),_0x4ec93a[_0x23ded5('0x64')]=_[_0x23ded5('0xd')](_0x10ed2c['model'],qs[_0x23ded5('0x5a')](_0x4a4b83['query'][_0x23ded5('0x5a')])),_0x4ec93a[_0x23ded5('0x64')]=_0x4ec93a[_0x23ded5('0x64')][_0x23ded5('0x67')]?_0x4ec93a[_0x23ded5('0x64')]:_0x10ed2c[_0x23ded5('0x68')],_0x4ec93a[_0x23ded5('0x2')]=qs[_0x23ded5('0x2')](_0x4a4b83['query'][_0x23ded5('0x2')]),_0x4ec93a[_0x23ded5('0x60')]=qs[_0x23ded5('0x60')](_0x4a4b83['query'][_0x23ded5('0x60')]),_0x4ec93a['order']=qs[_0x23ded5('0x24')](_0x4a4b83[_0x23ded5('0x1f')]['sort']),_0x4ec93a[_0x23ded5('0x1d')]=qs[_0x23ded5('0x4e')](_[_0x23ded5('0x11')](_0x4a4b83[_0x23ded5('0x1f')],_0x10ed2c[_0x23ded5('0x4e')])),_0x4ec93a=_[_0x23ded5('0x4a')]({},_0x4ec93a,_0x4a4b83[_0x23ded5('0x3')]),_0x24151e[_0x23ded5('0x2a')+_[_0x23ded5('0x44')](_0x4a4b83[_0x23ded5('0x1f')][_0x23ded5('0x62')]['toLowerCase']())+_0x23ded5('0x28')](_0x4ec93a);})['then'](respondWithResult(_0x5a0576,null))['catch'](handleError(_0x5a0576,null));},exports[_0x5794f5('0x1b')]=function(_0x2ccc29,_0x47eb66){const _0x62ad64=_0x5794f5;return db[_0x62ad64('0x47')][_0x62ad64('0x38')]({'where':{'id':_0x2ccc29[_0x62ad64('0x29')]['id']}})[_0x62ad64('0x6a')](function(_0x312a08){const _0x24ac9d=_0x62ad64;if(_0x312a08){if(!_0x2ccc29['body'][_0x24ac9d('0x62')]||!utils[_0x24ac9d('0x65')](_0x2ccc29[_0x24ac9d('0x2f')][_0x24ac9d('0x62')]))throw new ValidationError(_0x24ac9d('0x6b'));return _0x312a08[_0x24ac9d('0x3b')+_['capitalize'](_0x2ccc29[_0x24ac9d('0x2f')][_0x24ac9d('0x62')][_0x24ac9d('0x41')]())+_0x24ac9d('0x28')](_0x2ccc29[_0x24ac9d('0x2f')]['ids']);}return null;})[_0x62ad64('0x6a')](handleEntityNotFound(_0x47eb66,null))[_0x62ad64('0x6a')](respondWithStatusCode(_0x47eb66,null))[_0x62ad64('0x6')](handleError(_0x47eb66,null));},exports[_0x5794f5('0x31')]=function(_0x563352,_0x3a6be7){const _0x215fd1=_0x5794f5;return db[_0x215fd1('0x47')][_0x215fd1('0x38')]({'where':{'id':_0x563352[_0x215fd1('0x29')]['id']}})['then'](function(_0x263e74){const _0x579a91=_0x215fd1;if(_0x263e74){if(!_0x563352[_0x579a91('0x1f')][_0x579a91('0x62')]||!utils[_0x579a91('0x65')](_0x563352['query'][_0x579a91('0x62')]))throw new ValidationError('Unknown\x20channel');return _0x263e74[_0x579a91('0x58')+_[_0x579a91('0x44')](_0x563352[_0x579a91('0x1f')]['channel'][_0x579a91('0x41')]())+_0x579a91('0x28')](_0x563352[_0x579a91('0x1f')][_0x579a91('0x19')]);}return null;})[_0x215fd1('0x6a')](handleEntityNotFound(_0x3a6be7,null))[_0x215fd1('0x6a')](respondWithStatusCode(_0x3a6be7,null))[_0x215fd1('0x6')](handleError(_0x3a6be7,null));},exports[_0x5794f5('0x1a')]=function(_0x57fe63,_0x298398){const _0x442208=_0x5794f5;return db[_0x442208('0x47')]['findOne']({'where':{'id':_0x57fe63['params']['id']}})['then'](function(_0x5999de){const _0x426b42=_0x442208;if(_0x5999de){const _0x49f3f0=[_0x426b42('0x37'),_0x426b42('0x40'),_0x426b42('0x5f'),'Sms',_0x426b42('0x5e'),_0x426b42('0x5d'),_0x426b42('0xe')];return Promise[_0x426b42('0x3e')](_0x49f3f0,function(_0x5ecaf1){const _0x1fb845=_0x426b42;return _0x5999de[_0x1fb845('0x2a')+_0x5ecaf1+_0x1fb845('0x28')]({'attributes':['id',_0x1fb845('0x54')]})[_0x1fb845('0x6a')](function(_0x552a69){const _0xbf5057=_0x1fb845;return Promise[_0xbf5057('0x3e')](_0x552a69,function(_0x495e73){const _0x315d2d=_0xbf5057;return _0x495e73['addAgents'](_0x57fe63[_0x315d2d('0x2f')][_0x315d2d('0x19')])['then'](function(){const _0x4739e9=_0x315d2d;if(_0x5ecaf1===_0x4739e9('0x37'))return db[_0x4739e9('0x18')][_0x4739e9('0x1e')]({'where':{'id':_0x57fe63['body']['ids']},'attributes':['id',_0x4739e9('0x54'),_0x4739e9('0x16'),_0x4739e9('0x49'),_0x4739e9('0x3f')],'raw':!![]})[_0x4739e9('0x6a')](function(_0x180629){const _0x33abe5=_0x4739e9;return Promise[_0x33abe5('0x3e')](_[_0x33abe5('0x35')](_0x180629,{'online':0x1}),function(_0x46cb0a){const _0x4da0d8=_0x33abe5;return db[_0x4da0d8('0x56')][_0x4da0d8('0x66')]({'membername':_0x46cb0a['name'],'UserId':_0x46cb0a['id'],'queue_name':_0x495e73[_0x4da0d8('0x54')],'VoiceQueueId':_0x495e73['id'],'interface':_[_0x4da0d8('0x69')](_0x46cb0a['interface'])?util[_0x4da0d8('0x4b')](_0x4da0d8('0x32'),_0x46cb0a[_0x4da0d8('0x54')]):_0x46cb0a[_0x4da0d8('0x3f')],'paused':_0x46cb0a[_0x4da0d8('0x49')]||![],'penalty':0x0});});});});});})[_0x1fb845('0x6a')](function(){return _0x5999de;});})[_0x426b42('0x6a')](function(){return _0x5999de;});}})['then'](function(_0x1583fc){const _0x285c98=_0x442208;if(_0x1583fc)return _0x1583fc[_0x285c98('0x1a')](_0x57fe63[_0x285c98('0x2f')]['ids'],{'through':_[_0x285c98('0x48')](_0x57fe63[_0x285c98('0x2f')],[_0x285c98('0x19'),'id'])})[_0x285c98('0x6a')](function(_0xac180c){const _0x353b19=_0x285c98;for(let _0x4749b2=0x0;_0x4749b2<_0x57fe63[_0x353b19('0x2f')][_0x353b19('0x19')][_0x353b19('0x67')];_0x4749b2+=0x1){socket[_0x353b19('0x57')](_0x353b19('0x43'),{'UserId':_0x57fe63[_0x353b19('0x2f')][_0x353b19('0x19')][_0x4749b2],'TeamId':_0x57fe63['params']['id']});}return _0xac180c;});})[_0x442208('0x6a')](respondWithResult(_0x298398,null))[_0x442208('0x6')](handleError(_0x298398,null));},exports[_0x5794f5('0x10')]=function(_0x4be468,_0xc791e6){const _0x4e9731=_0x5794f5;return db[_0x4e9731('0x47')][_0x4e9731('0x38')]({'where':{'id':_0x4be468[_0x4e9731('0x29')]['id']}})[_0x4e9731('0x6a')](handleEntityNotFound(_0xc791e6,null))[_0x4e9731('0x6a')](function(_0x19a720){const _0x4e0dd4=_0x4e9731;if(_0x19a720)return Promise[_0x4e0dd4('0x3e')]([_0x4e0dd4('0x4'),_0x4e0dd4('0x33'),_0x4e0dd4('0xb'),_0x4e0dd4('0x4f'),_0x4e0dd4('0x52'),'openchannel','whatsapp'],function(_0x14f7df){const _0x37ec36=_0x4e0dd4;return _0x19a720[_0x37ec36('0x2a')+_[_0x37ec36('0x44')](_0x14f7df)+_0x37ec36('0x28')]({'attributes':['id',_0x37ec36('0x54')]})['then'](function(_0x134c6b){const _0xb4dde3=_0x37ec36;return Promise[_0xb4dde3('0x3e')](_0x134c6b,function(_0x42774d){const _0x166578=_0xb4dde3;return _0x42774d[_0x166578('0x10')](_0x4be468[_0x166578('0x1f')]['ids'])[_0x166578('0x6a')](function(){const _0x2fecc6=_0x166578;if(_0x14f7df==='voice')return db['UserVoiceQueueRt']['destroy']({'where':{'VoiceQueueId':_0x42774d['id'],'UserId':_0x4be468['query'][_0x2fecc6('0x19')]}});});});})[_0x37ec36('0x6a')](function(){return _0x19a720;});})[_0x4e0dd4('0x6a')](function(){return _0x19a720;});})[_0x4e9731('0x6a')](function(_0x4cb8f6){const _0x3d5aff=_0x4e9731;if(_0x4cb8f6)return _0x4cb8f6[_0x3d5aff('0x10')](_0x4be468[_0x3d5aff('0x1f')]['ids'])['then'](function(){const _0x4a8fe5=_0x3d5aff;if(_['isArray'](_0x4be468[_0x4a8fe5('0x1f')][_0x4a8fe5('0x19')]))for(let _0x1050a8=0x0;_0x1050a8<_0x4be468['query']['ids']['length'];_0x1050a8+=0x1){socket[_0x4a8fe5('0x57')](_0x4a8fe5('0x42'),{'UserId':Number(_0x4be468[_0x4a8fe5('0x1f')][_0x4a8fe5('0x19')][_0x1050a8]),'TeamId':Number(_0x4be468[_0x4a8fe5('0x29')]['id'])});}else socket[_0x4a8fe5('0x57')]('userTeam:remove',{'UserId':Number(_0x4be468[_0x4a8fe5('0x1f')][_0x4a8fe5('0x19')]),'TeamId':Number(_0x4be468[_0x4a8fe5('0x29')]['id'])});});})['then'](respondWithStatusCode(_0xc791e6,null))['catch'](handleError(_0xc791e6,null));},exports[_0x5794f5('0x15')]=function(_0x4b668e,_0x54ffa7){const _0x1568b8=_0x5794f5;let _0x313708={};const _0x3f51a5={};let _0x38ff31,_0x56df3e;return db[_0x1568b8('0x47')][_0x1568b8('0x38')]({'where':{'id':_0x4b668e['params']['id']}})['then'](handleEntityNotFound(_0x54ffa7,null))['then'](function(_0x54a96f){const _0x25fe78=_0x1568b8;if(_0x54a96f)return _0x38ff31=_0x54a96f,_0x3f51a5[_0x25fe78('0x68')]=_[_0x25fe78('0x53')](db[_0x25fe78('0x18')]['rawAttributes']),_0x3f51a5['query']=_['keys'](_0x4b668e[_0x25fe78('0x1f')]),_0x3f51a5[_0x25fe78('0x4e')]=_['intersection'](_0x3f51a5[_0x25fe78('0x68')],_0x3f51a5[_0x25fe78('0x1f')]),_0x313708[_0x25fe78('0x64')]=_[_0x25fe78('0xd')](_0x3f51a5[_0x25fe78('0x68')],qs[_0x25fe78('0x5a')](_0x4b668e['query']['fields'])),_0x313708[_0x25fe78('0x64')]=_0x313708[_0x25fe78('0x64')][_0x25fe78('0x67')]?_0x313708[_0x25fe78('0x64')]:_0x3f51a5['model'],_0x313708['order']=qs[_0x25fe78('0x24')](_0x4b668e[_0x25fe78('0x1f')][_0x25fe78('0x24')]),_0x313708[_0x25fe78('0x1d')]=qs[_0x25fe78('0x4e')](_[_0x25fe78('0x11')](_0x4b668e[_0x25fe78('0x1f')],_0x3f51a5[_0x25fe78('0x4e')])),_0x4b668e[_0x25fe78('0x1f')][_0x25fe78('0x35')]&&(_0x313708[_0x25fe78('0x1d')]=_['merge'](_0x313708[_0x25fe78('0x1d')],{[Op['or']]:_[_0x25fe78('0x13')](_0x313708[_0x25fe78('0x64')],function(_0x348078){const _0x129fbd=_0x25fe78,_0xec1351={};return _0xec1351[_0x348078]={[Op[_0x129fbd('0xc')]]:'%'+_0x4b668e[_0x129fbd('0x1f')][_0x129fbd('0x35')]+'%'},_0xec1351;})})),_0x313708=_[_0x25fe78('0x4a')]({},_0x313708,_0x4b668e[_0x25fe78('0x3')]),_0x38ff31[_0x25fe78('0x15')](_0x313708);})[_0x1568b8('0x6a')](function(_0x508741){const _0x278e2e=_0x1568b8;if(_0x508741)return _0x56df3e=_0x508741['length'],typeof _0x4b668e[_0x278e2e('0x1f')]['nolimit']==='undefined'&&(_0x313708['limit']=qs['limit'](_0x4b668e[_0x278e2e('0x1f')][_0x278e2e('0x2')]),_0x313708[_0x278e2e('0x60')]=qs[_0x278e2e('0x60')](_0x4b668e['query']['offset'])),_0x38ff31[_0x278e2e('0x15')](_0x313708);})[_0x1568b8('0x6a')](function(_0x244b34){if(_0x244b34)return _0x244b34?{'count':_0x56df3e,'rows':_0x244b34}:null;})[_0x1568b8('0x6a')](respondWithResult(_0x54ffa7,null))['catch'](handleError(_0x54ffa7,null));}; \ No newline at end of file diff --git a/server/api/team/team.events.js b/server/api/team/team.events.js index 9284ec0..5e61a4b 100644 --- a/server/api/team/team.events.js +++ b/server/api/team/team.events.js @@ -1 +1 @@ -const a627_0x2a26=['events','undefined','setMaxListeners','emit','remove','Team','../../mysqldb','exports'];(function(_0x5eb9e0,_0x2a269b){const _0x37c72b=function(_0x3c6689){while(--_0x3c6689){_0x5eb9e0['push'](_0x5eb9e0['shift']());}};_0x37c72b(++_0x2a269b);}(a627_0x2a26,0xa5));const a627_0x37c7=function(_0x5eb9e0,_0x2a269b){_0x5eb9e0=_0x5eb9e0-0x0;let _0x37c72b=a627_0x2a26[_0x5eb9e0];return _0x37c72b;};const _0x501f0e=a627_0x37c7;'use strict';const EventEmitter=require(_0x501f0e('0x3')),Team=require(_0x501f0e('0x1'))['db'][_0x501f0e('0x0')],TeamEvents=new EventEmitter();TeamEvents[_0x501f0e('0x5')](0x0);const events={'afterCreate':'save','afterUpdate':'update','afterDestroy':_0x501f0e('0x7')};function emitEvent(_0x3c6689){return function(_0x194d44){const _0x467526=a627_0x37c7;TeamEvents['emit'](_0x3c6689+':'+_0x194d44['id'],_0x194d44),TeamEvents[_0x467526('0x6')](_0x3c6689,_0x194d44);};}for(const e in events){if(typeof events[e]!==_0x501f0e('0x4')){const event=events[e];Team['addHook'](e,emitEvent(event));}}module[_0x501f0e('0x2')]=TeamEvents; \ No newline at end of file +const a627_0x2c50=['remove','undefined','emit','update','exports','../../mysqldb','save','addHook'];(function(_0x22834a,_0x2c50cd){const _0x4e2cde=function(_0x58d01a){while(--_0x58d01a){_0x22834a['push'](_0x22834a['shift']());}};_0x4e2cde(++_0x2c50cd);}(a627_0x2c50,0x1cb));const a627_0x4e2c=function(_0x22834a,_0x2c50cd){_0x22834a=_0x22834a-0x0;let _0x4e2cde=a627_0x2c50[_0x22834a];return _0x4e2cde;};const _0x109d90=a627_0x4e2c;'use strict';const EventEmitter=require('events'),Team=require(_0x109d90('0x2'))['db']['Team'],TeamEvents=new EventEmitter();TeamEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x109d90('0x3'),'afterUpdate':_0x109d90('0x0'),'afterDestroy':_0x109d90('0x5')};function emitEvent(_0x58d01a){return function(_0x596f8e){const _0x3b6929=a627_0x4e2c;TeamEvents[_0x3b6929('0x7')](_0x58d01a+':'+_0x596f8e['id'],_0x596f8e),TeamEvents['emit'](_0x58d01a,_0x596f8e);};}for(const e in events){if(typeof events[e]!==_0x109d90('0x6')){const event=events[e];Team[_0x109d90('0x4')](e,emitEvent(event));}}module[_0x109d90('0x1')]=TeamEvents; \ No newline at end of file diff --git a/server/api/team/team.model.js b/server/api/team/team.model.js index 0abb52b..251b7f7 100644 --- a/server/api/team/team.model.js +++ b/server/api/team/team.model.js @@ -1 +1 @@ -const a628_0x16f4=['teams','exports','define','./team.attributes'];(function(_0xf3ed03,_0x16f4ed){const _0xefdb00=function(_0x28e874){while(--_0x28e874){_0xf3ed03['push'](_0xf3ed03['shift']());}};_0xefdb00(++_0x16f4ed);}(a628_0x16f4,0x19f));const a628_0xefdb=function(_0xf3ed03,_0x16f4ed){_0xf3ed03=_0xf3ed03-0x0;let _0xefdb00=a628_0x16f4[_0xf3ed03];return _0xefdb00;};const _0x83e3a1=a628_0xefdb;'use strict';const attributes=require(_0x83e3a1('0x0'));module[_0x83e3a1('0x2')]=function(_0x28e874){const _0x4a31ac=_0x83e3a1,_0x3906f1=_0x28e874[_0x4a31ac('0x3')]('Team',attributes,{'tableName':_0x4a31ac('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3906f1;}; \ No newline at end of file +const a628_0x30d6=['exports','define','Team','./team.attributes','teams'];(function(_0x2457ed,_0x30d61d){const _0x537dd0=function(_0x5a72c0){while(--_0x5a72c0){_0x2457ed['push'](_0x2457ed['shift']());}};_0x537dd0(++_0x30d61d);}(a628_0x30d6,0x6c));const a628_0x537d=function(_0x2457ed,_0x30d61d){_0x2457ed=_0x2457ed-0x0;let _0x537dd0=a628_0x30d6[_0x2457ed];return _0x537dd0;};const _0x30ddd2=a628_0x537d;'use strict';const attributes=require(_0x30ddd2('0x0'));module[_0x30ddd2('0x2')]=function(_0x5a72c0){const _0xca373=_0x30ddd2,_0x436fc5=_0x5a72c0[_0xca373('0x3')](_0xca373('0x4'),attributes,{'tableName':_0xca373('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x436fc5;}; \ No newline at end of file diff --git a/server/api/team/team.rpc.js b/server/api/team/team.rpc.js index 6153658..c94bc16 100644 --- a/server/api/team/team.rpc.js +++ b/server/api/team/team.rpc.js @@ -1 +1 @@ -const a629_0x2eed=['../../rediscache','./team.socket'];(function(_0x31dc6a,_0x2eede0){const _0x188339=function(_0x188d26){while(--_0x188d26){_0x31dc6a['push'](_0x31dc6a['shift']());}};_0x188339(++_0x2eede0);}(a629_0x2eed,0x70));const a629_0x1883=function(_0x31dc6a,_0x2eede0){_0x31dc6a=_0x31dc6a-0x0;let _0x188339=a629_0x2eed[_0x31dc6a];return _0x188339;};const _0x48e8d6=a629_0x1883;'use strict';const {getSocket}=require(_0x48e8d6('0x0')),socket=getSocket();require(_0x48e8d6('0x1'))['register'](socket); \ No newline at end of file +const a629_0x4890=['../../rediscache','./team.socket','register'];(function(_0xcfbbd5,_0x48907d){const _0x29b311=function(_0x2ea80b){while(--_0x2ea80b){_0xcfbbd5['push'](_0xcfbbd5['shift']());}};_0x29b311(++_0x48907d);}(a629_0x4890,0x150));const a629_0x29b3=function(_0xcfbbd5,_0x48907d){_0xcfbbd5=_0xcfbbd5-0x0;let _0x29b311=a629_0x4890[_0xcfbbd5];return _0x29b311;};const _0x257165=a629_0x29b3;'use strict';const {getSocket}=require(_0x257165('0x0')),socket=getSocket();require(_0x257165('0x1'))[_0x257165('0x2')](socket); \ No newline at end of file diff --git a/server/api/team/team.socket.js b/server/api/team/team.socket.js index aaeb032..67ceb6d 100644 --- a/server/api/team/team.socket.js +++ b/server/api/team/team.socket.js @@ -1 +1 @@ -const a630_0x29b6=['team:','emit','update','register','remove'];(function(_0xb5901b,_0x29b67a){const _0x44de72=function(_0x535d32){while(--_0x535d32){_0xb5901b['push'](_0xb5901b['shift']());}};_0x44de72(++_0x29b67a);}(a630_0x29b6,0xe8));const a630_0x44de=function(_0xb5901b,_0x29b67a){_0xb5901b=_0xb5901b-0x0;let _0x44de72=a630_0x29b6[_0xb5901b];return _0x44de72;};const _0x19a0cc=a630_0x44de;'use strict';const TeamEvents=require('./team.events'),events=['save',_0x19a0cc('0x2'),_0x19a0cc('0x0')];function createListener(_0x535d32,_0x25173d){return function(_0x27ed61){const _0x3e9525=a630_0x44de;_0x25173d[_0x3e9525('0x4')](_0x535d32,_0x27ed61);};}exports[_0x19a0cc('0x1')]=function(_0x4d045f){const _0x5d0e4f=_0x19a0cc;for(let _0x32d823=0x0,_0x5ce52e=events['length'];_0x32d823<_0x5ce52e;_0x32d823++){const _0x2a7a10=events[_0x32d823],_0x1f04e2=createListener(_0x5d0e4f('0x3')+_0x2a7a10,_0x4d045f);TeamEvents['on'](_0x2a7a10,_0x1f04e2);}}; \ No newline at end of file +const a630_0x2e8b=['save','./team.events','register','team:','remove','emit'];(function(_0x46c596,_0x2e8b79){const _0x571ada=function(_0x571f14){while(--_0x571f14){_0x46c596['push'](_0x46c596['shift']());}};_0x571ada(++_0x2e8b79);}(a630_0x2e8b,0x1a1));const a630_0x571a=function(_0x46c596,_0x2e8b79){_0x46c596=_0x46c596-0x0;let _0x571ada=a630_0x2e8b[_0x46c596];return _0x571ada;};const _0x290e82=a630_0x571a;'use strict';const TeamEvents=require(_0x290e82('0x4')),events=[_0x290e82('0x3'),_0x290e82('0x1'),'update'];function createListener(_0x571f14,_0x226d6b){return function(_0x270348){const _0x17727c=a630_0x571a;_0x226d6b[_0x17727c('0x2')](_0x571f14,_0x270348);};}exports[_0x290e82('0x5')]=function(_0x4e1f5a){const _0x22f603=_0x290e82;for(let _0x35cf36=0x0,_0x5938d1=events['length'];_0x35cf36<_0x5938d1;_0x35cf36++){const _0x21a11e=events[_0x35cf36],_0x328974=createListener(_0x22f603('0x0')+_0x21a11e,_0x4e1f5a);TeamEvents['on'](_0x21a11e,_0x328974);}}; \ No newline at end of file diff --git a/server/api/template/index.js b/server/api/template/index.js index eef008f..d997b02 100644 --- a/server/api/template/index.js +++ b/server/api/template/index.js @@ -1 +1 @@ -const a631_0x389a=['/:id','create','show','post','exports','destroy','express','index','./template.controller','Router','../../components/auth/service','isAuthenticated','delete','get'];(function(_0x479da3,_0x389a47){const _0x559a5e=function(_0x34185b){while(--_0x34185b){_0x479da3['push'](_0x479da3['shift']());}};_0x559a5e(++_0x389a47);}(a631_0x389a,0x1b9));const a631_0x559a=function(_0x479da3,_0x389a47){_0x479da3=_0x479da3-0x0;let _0x559a5e=a631_0x389a[_0x479da3];return _0x559a5e;};const _0x1e2c44=a631_0x559a;'use strict';const express=require(_0x1e2c44('0xd')),router=express[_0x1e2c44('0x2')](),auth=require(_0x1e2c44('0x3')),controller=require(_0x1e2c44('0x1'));router[_0x1e2c44('0x6')]('/',auth['isAuthenticated'](),controller[_0x1e2c44('0x0')]),router[_0x1e2c44('0x6')](_0x1e2c44('0x7'),auth['isAuthenticated'](),controller[_0x1e2c44('0x9')]),router[_0x1e2c44('0xa')]('/',auth[_0x1e2c44('0x4')](),controller[_0x1e2c44('0x8')]),router['put']('/:id',auth['isAuthenticated'](),controller['update']),router[_0x1e2c44('0x5')](_0x1e2c44('0x7'),auth[_0x1e2c44('0x4')](),controller[_0x1e2c44('0xc')]),module[_0x1e2c44('0xb')]=router; \ No newline at end of file +const a631_0x3099=['update','/:id','show','../../components/auth/service','delete','isAuthenticated','exports','index','express','get','Router','./template.controller','post','destroy'];(function(_0xdb6d0c,_0x3099a3){const _0x3e6488=function(_0x1f9f04){while(--_0x1f9f04){_0xdb6d0c['push'](_0xdb6d0c['shift']());}};_0x3e6488(++_0x3099a3);}(a631_0x3099,0x143));const a631_0x3e64=function(_0xdb6d0c,_0x3099a3){_0xdb6d0c=_0xdb6d0c-0x0;let _0x3e6488=a631_0x3099[_0xdb6d0c];return _0x3e6488;};const _0x9c174=a631_0x3e64;'use strict';const express=require(_0x9c174('0x7')),router=express[_0x9c174('0x9')](),auth=require(_0x9c174('0x2')),controller=require(_0x9c174('0xa'));router[_0x9c174('0x8')]('/',auth['isAuthenticated'](),controller[_0x9c174('0x6')]),router[_0x9c174('0x8')](_0x9c174('0x0'),auth[_0x9c174('0x4')](),controller[_0x9c174('0x1')]),router[_0x9c174('0xb')]('/',auth['isAuthenticated'](),controller['create']),router['put'](_0x9c174('0x0'),auth[_0x9c174('0x4')](),controller[_0x9c174('0xd')]),router[_0x9c174('0x3')](_0x9c174('0x0'),auth[_0x9c174('0x4')](),controller[_0x9c174('0xc')]),module[_0x9c174('0x5')]=router; \ No newline at end of file diff --git a/server/api/template/template.attributes.js b/server/api/template/template.attributes.js index 391b1fd..17121f8 100644 --- a/server/api/template/template.attributes.js +++ b/server/api/template/template.attributes.js @@ -1 +1 @@ -const a632_0x445e=['STRING','exports','sequelize'];(function(_0x5ac111,_0x445ea9){const _0x18b787=function(_0xf9a6fc){while(--_0xf9a6fc){_0x5ac111['push'](_0x5ac111['shift']());}};_0x18b787(++_0x445ea9);}(a632_0x445e,0x178));const a632_0x18b7=function(_0x5ac111,_0x445ea9){_0x5ac111=_0x5ac111-0x0;let _0x18b787=a632_0x445e[_0x5ac111];return _0x18b787;};const _0x4ed05c=a632_0x18b7;'use strict';const Sequelize=require(_0x4ed05c('0x1'));module[_0x4ed05c('0x0')]={'name':{'type':Sequelize[_0x4ed05c('0x2')]},'description':{'type':Sequelize['STRING']},'html':{'type':Sequelize['TEXT']}}; \ No newline at end of file +const a632_0x1d89=['TEXT','STRING','exports'];(function(_0x4beeaa,_0x1d89c7){const _0x5c1d0c=function(_0x5918a2){while(--_0x5918a2){_0x4beeaa['push'](_0x4beeaa['shift']());}};_0x5c1d0c(++_0x1d89c7);}(a632_0x1d89,0x10b));const a632_0x5c1d=function(_0x4beeaa,_0x1d89c7){_0x4beeaa=_0x4beeaa-0x0;let _0x5c1d0c=a632_0x1d89[_0x4beeaa];return _0x5c1d0c;};const _0x165aa4=a632_0x5c1d;'use strict';const Sequelize=require('sequelize');module[_0x165aa4('0x2')]={'name':{'type':Sequelize[_0x165aa4('0x1')]},'description':{'type':Sequelize['STRING']},'html':{'type':Sequelize[_0x165aa4('0x0')]}}; \ No newline at end of file diff --git a/server/api/template/template.controller.js b/server/api/template/template.controller.js index f231f07..713a716 100644 --- a/server/api/template/template.controller.js +++ b/server/api/template/template.controller.js @@ -1 +1 @@ -const a633_0x897c=['lodash','keys','Templates','includeAll','type','order','index','model','error','UserProfileResource','query','include','json','rawAttributes','rows','where','autoAssociation','role','status','end','Content-Range','sendStatus','body','show','filter','limit','pick','get','length','key','merge','findOne','stack','like','Unable\x20to\x20retrieve\x20the\x20current\x20user','destroy','UserProfileSection','offset','sequelize','params','then','count','fields','fieldName','userProfileId','update','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','catch','VIRTUAL','filters','intersection','sort','nolimit','create','map','../../config/logger','api','name','user','options','attributes','Template'];(function(_0x23d6c8,_0x897ccd){const _0x3ddcd0=function(_0x3cf021){while(--_0x3cf021){_0x23d6c8['push'](_0x23d6c8['shift']());}};_0x3ddcd0(++_0x897ccd);}(a633_0x897c,0x153));const a633_0x3ddc=function(_0x23d6c8,_0x897ccd){_0x23d6c8=_0x23d6c8-0x0;let _0x3ddcd0=a633_0x897c[_0x23d6c8];return _0x3ddcd0;};const _0x32f8e6=a633_0x3ddc;'use strict';const _=require(_0x32f8e6('0x21')),qs=require('../../components/parsers/qs'),logger=require(_0x32f8e6('0x1a'))(_0x32f8e6('0x1b')),db=require('../../mysqldb')['db'],{Op}=require(_0x32f8e6('0x9'));function respondWithResult(_0x3cf021,_0x2ccc93){return _0x2ccc93=_0x2ccc93||0xc8,function(_0xad894f){const _0x14435a=a633_0x3ddc;if(_0xad894f)return _0x3cf021[_0x14435a('0x33')](_0x2ccc93)['json'](_0xad894f);};}function respondWithFilteredResult(_0x4a6e44,_0x3c3c5b){return function(_0x554851){const _0xac1eec=a633_0x3ddc;if(_0x554851){const _0x9964e2=_0x554851[_0xac1eec('0xc')],_0xe3a9f8=_0x3c3c5b[_0xac1eec('0x8')];let _0x5f264f=_0x3c3c5b[_0xac1eec('0x8')]+_0x3c3c5b[_0xac1eec('0x3a')],_0x114a1c;return _0x5f264f>=_0x9964e2?(_0x5f264f=_0x9964e2,_0x114a1c=0xc8):_0x114a1c=0xce,_0x4a6e44[_0xac1eec('0x33')](_0x114a1c),_0x4a6e44['set'](_0xac1eec('0x35'),_0xe3a9f8+'-'+_0x5f264f+'/'+_0x9964e2)[_0xac1eec('0x2d')](_0x554851);}return null;};}function saveUpdates(_0x44658a){return function(_0x543ebe){const _0x529afe=a633_0x3ddc;if(_0x543ebe)return _0x543ebe['update'](_0x44658a)[_0x529afe('0xb')](function(_0x37ffeb){return _0x37ffeb;});return null;};}function removeEntity(_0x26d0e9){return function(_0x51cf95){const _0x2395c3=a633_0x3ddc;if(_0x51cf95)return _0x51cf95['destroy']()['then'](function(){const _0x159770=a633_0x3ddc,_0x5a45a7=_0x51cf95['get']({'plain':!![]}),_0x59218e=_0x159770('0x23');return db[_0x159770('0x2a')][_0x159770('0x6')]({'where':{'type':_0x59218e,'resourceId':_0x5a45a7['id']}})[_0x159770('0xb')](function(){return _0x51cf95;});})[_0x2395c3('0xb')](function(){const _0x44dcd9=_0x2395c3;_0x26d0e9[_0x44dcd9('0x33')](0xcc)[_0x44dcd9('0x34')]();});};}function handleEntityNotFound(_0x1b5e86){return function(_0x27d50f){const _0xf347ab=a633_0x3ddc;return!_0x27d50f&&_0x1b5e86[_0xf347ab('0x36')](0x194),_0x27d50f;};}function handleError(_0x11409d,_0x5b8c28){return _0x5b8c28=_0x5b8c28||0x1f4,function(_0x2df912){const _0x20acdc=a633_0x3ddc;logger[_0x20acdc('0x29')](_0x2df912[_0x20acdc('0x3')]),_0x2df912[_0x20acdc('0x1c')]&&delete _0x2df912[_0x20acdc('0x1c')],_0x11409d[_0x20acdc('0x33')](_0x5b8c28)['send'](_0x2df912);};}exports[_0x32f8e6('0x27')]=function(_0x3447aa,_0x37314f){const _0x37f17c=_0x32f8e6;let _0x52e24c={};const _0x85f409={},_0x46eea0={'count':0x0,'rows':[]},_0x370b7a=_[_0x37f17c('0x19')](db['Template'][_0x37f17c('0x2e')],function(_0x1ad467){const _0x590773=_0x37f17c;return{'name':_0x1ad467[_0x590773('0xe')],'type':_0x1ad467['type'][_0x590773('0x0')]};});_0x85f409[_0x37f17c('0x28')]=_['map'](_0x370b7a,_0x37f17c('0x1c')),_0x85f409[_0x37f17c('0x2b')]=_[_0x37f17c('0x22')](_0x3447aa[_0x37f17c('0x2b')]),_0x85f409[_0x37f17c('0x14')]=_[_0x37f17c('0x15')](_0x85f409[_0x37f17c('0x28')],_0x85f409[_0x37f17c('0x2b')]),_0x52e24c[_0x37f17c('0x1f')]=_[_0x37f17c('0x15')](_0x85f409[_0x37f17c('0x28')],qs[_0x37f17c('0xd')](_0x3447aa[_0x37f17c('0x2b')][_0x37f17c('0xd')])),_0x52e24c[_0x37f17c('0x1f')]=_0x52e24c[_0x37f17c('0x1f')][_0x37f17c('0x3d')]?_0x52e24c[_0x37f17c('0x1f')]:_0x85f409['model'];typeof _0x3447aa[_0x37f17c('0x2b')][_0x37f17c('0x17')]==='undefined'&&(_0x52e24c[_0x37f17c('0x3a')]=qs[_0x37f17c('0x3a')](_0x3447aa['query'][_0x37f17c('0x3a')]),_0x52e24c[_0x37f17c('0x8')]=qs[_0x37f17c('0x8')](_0x3447aa[_0x37f17c('0x2b')][_0x37f17c('0x8')]));_0x52e24c[_0x37f17c('0x26')]=qs[_0x37f17c('0x16')](_0x3447aa['query'][_0x37f17c('0x16')]),_0x52e24c[_0x37f17c('0x30')]=qs[_0x37f17c('0x14')](_[_0x37f17c('0x3b')](_0x3447aa[_0x37f17c('0x2b')],_0x85f409[_0x37f17c('0x14')]),_0x370b7a);_0x3447aa['query'][_0x37f17c('0x39')]&&(_0x52e24c[_0x37f17c('0x30')]=_['merge'](_0x52e24c[_0x37f17c('0x30')],{[Op['or']]:_[_0x37f17c('0x19')](_0x370b7a,function(_0x4619fc){const _0x31a324=_0x37f17c;if(_0x4619fc[_0x31a324('0x25')]!==_0x31a324('0x13')){const _0x5d8abe={};return _0x5d8abe[_0x4619fc[_0x31a324('0x1c')]]={[Op[_0x31a324('0x4')]]:'%'+_0x3447aa[_0x31a324('0x2b')][_0x31a324('0x39')]+'%'},_0x5d8abe;}})}));_0x52e24c=_['merge']({},_0x52e24c,_0x3447aa['options']);const _0x299c06={'where':_0x52e24c[_0x37f17c('0x30')]};return db[_0x37f17c('0x20')][_0x37f17c('0xc')](_0x299c06)[_0x37f17c('0xb')](function(_0x105222){const _0x616b2f=_0x37f17c;return _0x46eea0[_0x616b2f('0xc')]=_0x105222,_0x3447aa[_0x616b2f('0x2b')][_0x616b2f('0x24')]&&(_0x52e24c[_0x616b2f('0x2c')]=[{'all':!![]}]),db[_0x616b2f('0x20')]['findAll'](_0x52e24c);})[_0x37f17c('0xb')](function(_0x27c4e6){const _0x1f08df=_0x37f17c;return _0x46eea0[_0x1f08df('0x2f')]=_0x27c4e6,_0x46eea0;})['then'](respondWithFilteredResult(_0x37314f,_0x52e24c))[_0x37f17c('0x12')](handleError(_0x37314f,null));},exports[_0x32f8e6('0x38')]=function(_0x944dd4,_0xeb88b5){const _0x1df5d1=_0x32f8e6;let _0x4fab6c={'raw':!![],'where':{'id':_0x944dd4[_0x1df5d1('0xa')]['id']}};const _0x2af846={};return _0x2af846[_0x1df5d1('0x28')]=_[_0x1df5d1('0x22')](db[_0x1df5d1('0x20')][_0x1df5d1('0x2e')]),_0x2af846[_0x1df5d1('0x2b')]=_['keys'](_0x944dd4[_0x1df5d1('0x2b')]),_0x2af846[_0x1df5d1('0x14')]=_[_0x1df5d1('0x15')](_0x2af846[_0x1df5d1('0x28')],_0x2af846[_0x1df5d1('0x2b')]),_0x4fab6c[_0x1df5d1('0x1f')]=_[_0x1df5d1('0x15')](_0x2af846[_0x1df5d1('0x28')],qs[_0x1df5d1('0xd')](_0x944dd4[_0x1df5d1('0x2b')][_0x1df5d1('0xd')])),_0x4fab6c[_0x1df5d1('0x1f')]=_0x4fab6c[_0x1df5d1('0x1f')]['length']?_0x4fab6c[_0x1df5d1('0x1f')]:_0x2af846[_0x1df5d1('0x28')],_0x944dd4[_0x1df5d1('0x2b')][_0x1df5d1('0x24')]&&(_0x4fab6c[_0x1df5d1('0x2c')]=[{'all':!![]}]),_0x4fab6c=_[_0x1df5d1('0x1')]({},_0x4fab6c,_0x944dd4[_0x1df5d1('0x1e')]),db[_0x1df5d1('0x20')]['findOne'](_0x4fab6c)[_0x1df5d1('0xb')](handleEntityNotFound(_0xeb88b5,null))[_0x1df5d1('0xb')](respondWithResult(_0xeb88b5,null))[_0x1df5d1('0x12')](handleError(_0xeb88b5,null));},exports[_0x32f8e6('0x18')]=function(_0x4bd151,_0x244ddd){const _0x31947e=_0x32f8e6;return db[_0x31947e('0x20')]['create'](_0x4bd151[_0x31947e('0x37')],{})[_0x31947e('0xb')](function(_0x3c56e6){const _0x2da6e3=_0x31947e,_0x181704=_0x4bd151[_0x2da6e3('0x1d')][_0x2da6e3('0x3c')]({'plain':!![]});if(!_0x181704)throw new Error(_0x2da6e3('0x5'));if(_0x181704[_0x2da6e3('0x32')]==='user'){const _0x2cee9d=_0x3c56e6[_0x2da6e3('0x3c')]({'plain':!![]}),_0x33c714='Templates';return db[_0x2da6e3('0x7')][_0x2da6e3('0x2')]({'where':{'name':_0x33c714,'userProfileId':_0x181704[_0x2da6e3('0xf')]},'raw':!![]})[_0x2da6e3('0xb')](function(_0x17a7e6){const _0x5a8e44=_0x2da6e3;return _0x17a7e6&&_0x17a7e6[_0x5a8e44('0x31')]===0x0?db[_0x5a8e44('0x2a')][_0x5a8e44('0x18')]({'name':_0x2cee9d[_0x5a8e44('0x1c')],'resourceId':_0x2cee9d['id'],'type':_0x17a7e6[_0x5a8e44('0x1c')],'sectionId':_0x17a7e6['id']},{})[_0x5a8e44('0xb')](function(){return _0x3c56e6;}):_0x3c56e6;})[_0x2da6e3('0x12')](function(_0x21246a){const _0xe1f4a1=_0x2da6e3;logger[_0xe1f4a1('0x29')](_0xe1f4a1('0x11'),_0x21246a);throw _0x21246a;});}return _0x3c56e6;})[_0x31947e('0xb')](respondWithResult(_0x244ddd,0xc9))[_0x31947e('0x12')](handleError(_0x244ddd,null));},exports[_0x32f8e6('0x10')]=function(_0x5c3cd9,_0x165cdd){const _0x204dcd=_0x32f8e6;return _0x5c3cd9[_0x204dcd('0x37')]['id']&&delete _0x5c3cd9[_0x204dcd('0x37')]['id'],db[_0x204dcd('0x20')][_0x204dcd('0x2')]({'where':{'id':_0x5c3cd9[_0x204dcd('0xa')]['id']}})['then'](handleEntityNotFound(_0x165cdd,null))[_0x204dcd('0xb')](saveUpdates(_0x5c3cd9[_0x204dcd('0x37')],null))[_0x204dcd('0xb')](respondWithResult(_0x165cdd,null))[_0x204dcd('0x12')](handleError(_0x165cdd,null));},exports['destroy']=function(_0x4a75d8,_0x5582ca){const _0x4a1a41=_0x32f8e6;return db[_0x4a1a41('0x20')][_0x4a1a41('0x2')]({'where':{'id':_0x4a75d8[_0x4a1a41('0xa')]['id']}})[_0x4a1a41('0xb')](handleEntityNotFound(_0x5582ca,null))[_0x4a1a41('0xb')](removeEntity(_0x5582ca,null))[_0x4a1a41('0x12')](handleError(_0x5582ca,null));}; \ No newline at end of file +const a633_0x4f70=['where','../../components/parsers/qs','limit','keys','autoAssociation','get','filters','UserProfileResource','includeAll','../../mysqldb','update','query','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','merge','error','sort','length','body','options','send','undefined','sendStatus','create','role','Templates','then','fieldName','VIRTUAL','filter','Template','map','Unable\x20to\x20retrieve\x20the\x20current\x20user','pick','intersection','offset','user','nolimit','api','fields','show','destroy','params','findAll','model','like','findOne','include','stack','Content-Range','catch','name','index','../../config/logger','count','rows','userProfileId','json','UserProfileSection','end','sequelize','status','rawAttributes','order','set','attributes'];(function(_0x9147e4,_0x4f708a){const _0x4ee2f7=function(_0x3a97bb){while(--_0x3a97bb){_0x9147e4['push'](_0x9147e4['shift']());}};_0x4ee2f7(++_0x4f708a);}(a633_0x4f70,0x109));const a633_0x4ee2=function(_0x9147e4,_0x4f708a){_0x9147e4=_0x9147e4-0x0;let _0x4ee2f7=a633_0x4f70[_0x9147e4];return _0x4ee2f7;};const _0x15c969=a633_0x4ee2;'use strict';const _=require('lodash'),qs=require(_0x15c969('0x3d')),logger=require(_0x15c969('0x2f'))(_0x15c969('0x20')),db=require(_0x15c969('0x4'))['db'],{Op}=require(_0x15c969('0x36'));function respondWithResult(_0x3a97bb,_0x35fc04){return _0x35fc04=_0x35fc04||0xc8,function(_0x40ed0b){const _0x3a3bce=a633_0x4ee2;if(_0x40ed0b)return _0x3a97bb[_0x3a3bce('0x37')](_0x35fc04)[_0x3a3bce('0x33')](_0x40ed0b);};}function respondWithFilteredResult(_0x1f4de8,_0x1e7ab7){return function(_0x5ab63f){const _0x264567=a633_0x4ee2;if(_0x5ab63f){const _0x341568=_0x5ab63f[_0x264567('0x30')],_0x2e3189=_0x1e7ab7['offset'];let _0x1f4670=_0x1e7ab7['offset']+_0x1e7ab7[_0x264567('0x3e')],_0x3147ee;return _0x1f4670>=_0x341568?(_0x1f4670=_0x341568,_0x3147ee=0xc8):_0x3147ee=0xce,_0x1f4de8[_0x264567('0x37')](_0x3147ee),_0x1f4de8[_0x264567('0x3a')](_0x264567('0x2b'),_0x2e3189+'-'+_0x1f4670+'/'+_0x341568)['json'](_0x5ab63f);}return null;};}function saveUpdates(_0x5f3c08){return function(_0x109f3c){const _0x309caa=a633_0x4ee2;if(_0x109f3c)return _0x109f3c[_0x309caa('0x5')](_0x5f3c08)[_0x309caa('0x14')](function(_0x147499){return _0x147499;});return null;};}function removeEntity(_0xe82f2e){return function(_0x7cc1c){const _0x5277e0=a633_0x4ee2;if(_0x7cc1c)return _0x7cc1c[_0x5277e0('0x23')]()['then'](function(){const _0x57e6e8=_0x5277e0,_0x2e3342=_0x7cc1c[_0x57e6e8('0x0')]({'plain':!![]}),_0xd8c791=_0x57e6e8('0x13');return db[_0x57e6e8('0x2')][_0x57e6e8('0x23')]({'where':{'type':_0xd8c791,'resourceId':_0x2e3342['id']}})[_0x57e6e8('0x14')](function(){return _0x7cc1c;});})[_0x5277e0('0x14')](function(){const _0x2f3b1b=_0x5277e0;_0xe82f2e[_0x2f3b1b('0x37')](0xcc)[_0x2f3b1b('0x35')]();});};}function handleEntityNotFound(_0x418480){return function(_0x6d21bf){const _0x4b7134=a633_0x4ee2;return!_0x6d21bf&&_0x418480[_0x4b7134('0x10')](0x194),_0x6d21bf;};}function handleError(_0x2cfe44,_0x46e255){return _0x46e255=_0x46e255||0x1f4,function(_0x2c5e43){const _0x36e858=a633_0x4ee2;logger[_0x36e858('0x9')](_0x2c5e43[_0x36e858('0x2a')]),_0x2c5e43[_0x36e858('0x2d')]&&delete _0x2c5e43[_0x36e858('0x2d')],_0x2cfe44['status'](_0x46e255)[_0x36e858('0xe')](_0x2c5e43);};}exports[_0x15c969('0x2e')]=function(_0x3212e7,_0x346018){const _0x3e6aa8=_0x15c969;let _0x2fa026={};const _0x17745b={},_0x2f99f8={'count':0x0,'rows':[]},_0x38aeb3=_['map'](db[_0x3e6aa8('0x18')][_0x3e6aa8('0x38')],function(_0x583d8a){const _0x47f200=_0x3e6aa8;return{'name':_0x583d8a[_0x47f200('0x15')],'type':_0x583d8a['type']['key']};});_0x17745b[_0x3e6aa8('0x26')]=_[_0x3e6aa8('0x19')](_0x38aeb3,_0x3e6aa8('0x2d')),_0x17745b[_0x3e6aa8('0x6')]=_[_0x3e6aa8('0x3f')](_0x3212e7[_0x3e6aa8('0x6')]),_0x17745b[_0x3e6aa8('0x1')]=_[_0x3e6aa8('0x1c')](_0x17745b[_0x3e6aa8('0x26')],_0x17745b[_0x3e6aa8('0x6')]),_0x2fa026[_0x3e6aa8('0x3b')]=_['intersection'](_0x17745b[_0x3e6aa8('0x26')],qs[_0x3e6aa8('0x21')](_0x3212e7[_0x3e6aa8('0x6')][_0x3e6aa8('0x21')])),_0x2fa026[_0x3e6aa8('0x3b')]=_0x2fa026[_0x3e6aa8('0x3b')]['length']?_0x2fa026[_0x3e6aa8('0x3b')]:_0x17745b[_0x3e6aa8('0x26')];typeof _0x3212e7[_0x3e6aa8('0x6')][_0x3e6aa8('0x1f')]===_0x3e6aa8('0xf')&&(_0x2fa026[_0x3e6aa8('0x3e')]=qs[_0x3e6aa8('0x3e')](_0x3212e7['query'][_0x3e6aa8('0x3e')]),_0x2fa026[_0x3e6aa8('0x1d')]=qs[_0x3e6aa8('0x1d')](_0x3212e7[_0x3e6aa8('0x6')][_0x3e6aa8('0x1d')]));_0x2fa026[_0x3e6aa8('0x39')]=qs[_0x3e6aa8('0xa')](_0x3212e7[_0x3e6aa8('0x6')][_0x3e6aa8('0xa')]),_0x2fa026[_0x3e6aa8('0x3c')]=qs[_0x3e6aa8('0x1')](_[_0x3e6aa8('0x1b')](_0x3212e7[_0x3e6aa8('0x6')],_0x17745b[_0x3e6aa8('0x1')]),_0x38aeb3);_0x3212e7[_0x3e6aa8('0x6')][_0x3e6aa8('0x17')]&&(_0x2fa026['where']=_['merge'](_0x2fa026[_0x3e6aa8('0x3c')],{[Op['or']]:_['map'](_0x38aeb3,function(_0x1bead3){const _0x4afbad=_0x3e6aa8;if(_0x1bead3['type']!==_0x4afbad('0x16')){const _0x353789={};return _0x353789[_0x1bead3[_0x4afbad('0x2d')]]={[Op[_0x4afbad('0x27')]]:'%'+_0x3212e7[_0x4afbad('0x6')][_0x4afbad('0x17')]+'%'},_0x353789;}})}));_0x2fa026=_[_0x3e6aa8('0x8')]({},_0x2fa026,_0x3212e7[_0x3e6aa8('0xd')]);const _0x41906f={'where':_0x2fa026['where']};return db[_0x3e6aa8('0x18')][_0x3e6aa8('0x30')](_0x41906f)['then'](function(_0x4dd8a8){const _0x8288de=_0x3e6aa8;return _0x2f99f8[_0x8288de('0x30')]=_0x4dd8a8,_0x3212e7[_0x8288de('0x6')][_0x8288de('0x3')]&&(_0x2fa026[_0x8288de('0x29')]=[{'all':!![]}]),db[_0x8288de('0x18')][_0x8288de('0x25')](_0x2fa026);})['then'](function(_0x5d62d0){const _0x2425d7=_0x3e6aa8;return _0x2f99f8[_0x2425d7('0x31')]=_0x5d62d0,_0x2f99f8;})[_0x3e6aa8('0x14')](respondWithFilteredResult(_0x346018,_0x2fa026))[_0x3e6aa8('0x2c')](handleError(_0x346018,null));},exports[_0x15c969('0x22')]=function(_0x2d9cba,_0x3e145c){const _0x1e5dc5=_0x15c969;let _0x59c3ff={'raw':!![],'where':{'id':_0x2d9cba[_0x1e5dc5('0x24')]['id']}};const _0x3a73bb={};return _0x3a73bb[_0x1e5dc5('0x26')]=_[_0x1e5dc5('0x3f')](db[_0x1e5dc5('0x18')][_0x1e5dc5('0x38')]),_0x3a73bb[_0x1e5dc5('0x6')]=_[_0x1e5dc5('0x3f')](_0x2d9cba[_0x1e5dc5('0x6')]),_0x3a73bb[_0x1e5dc5('0x1')]=_[_0x1e5dc5('0x1c')](_0x3a73bb[_0x1e5dc5('0x26')],_0x3a73bb[_0x1e5dc5('0x6')]),_0x59c3ff[_0x1e5dc5('0x3b')]=_['intersection'](_0x3a73bb[_0x1e5dc5('0x26')],qs[_0x1e5dc5('0x21')](_0x2d9cba[_0x1e5dc5('0x6')][_0x1e5dc5('0x21')])),_0x59c3ff[_0x1e5dc5('0x3b')]=_0x59c3ff['attributes'][_0x1e5dc5('0xb')]?_0x59c3ff[_0x1e5dc5('0x3b')]:_0x3a73bb[_0x1e5dc5('0x26')],_0x2d9cba[_0x1e5dc5('0x6')][_0x1e5dc5('0x3')]&&(_0x59c3ff['include']=[{'all':!![]}]),_0x59c3ff=_[_0x1e5dc5('0x8')]({},_0x59c3ff,_0x2d9cba[_0x1e5dc5('0xd')]),db['Template'][_0x1e5dc5('0x28')](_0x59c3ff)[_0x1e5dc5('0x14')](handleEntityNotFound(_0x3e145c,null))[_0x1e5dc5('0x14')](respondWithResult(_0x3e145c,null))[_0x1e5dc5('0x2c')](handleError(_0x3e145c,null));},exports[_0x15c969('0x11')]=function(_0x3d5dbe,_0xac5180){const _0x10973f=_0x15c969;return db[_0x10973f('0x18')][_0x10973f('0x11')](_0x3d5dbe[_0x10973f('0xc')],{})[_0x10973f('0x14')](function(_0x215234){const _0x15eadc=_0x10973f,_0x6a9272=_0x3d5dbe[_0x15eadc('0x1e')][_0x15eadc('0x0')]({'plain':!![]});if(!_0x6a9272)throw new Error(_0x15eadc('0x1a'));if(_0x6a9272[_0x15eadc('0x12')]===_0x15eadc('0x1e')){const _0x31bee8=_0x215234[_0x15eadc('0x0')]({'plain':!![]}),_0x481e79='Templates';return db[_0x15eadc('0x34')][_0x15eadc('0x28')]({'where':{'name':_0x481e79,'userProfileId':_0x6a9272[_0x15eadc('0x32')]},'raw':!![]})[_0x15eadc('0x14')](function(_0x48e9be){const _0x33d3dc=_0x15eadc;return _0x48e9be&&_0x48e9be[_0x33d3dc('0x40')]===0x0?db['UserProfileResource'][_0x33d3dc('0x11')]({'name':_0x31bee8['name'],'resourceId':_0x31bee8['id'],'type':_0x48e9be[_0x33d3dc('0x2d')],'sectionId':_0x48e9be['id']},{})[_0x33d3dc('0x14')](function(){return _0x215234;}):_0x215234;})[_0x15eadc('0x2c')](function(_0x541274){const _0x405135=_0x15eadc;logger['error'](_0x405135('0x7'),_0x541274);throw _0x541274;});}return _0x215234;})['then'](respondWithResult(_0xac5180,0xc9))['catch'](handleError(_0xac5180,null));},exports['update']=function(_0x433560,_0x5ad22d){const _0xc1a428=_0x15c969;return _0x433560[_0xc1a428('0xc')]['id']&&delete _0x433560[_0xc1a428('0xc')]['id'],db['Template'][_0xc1a428('0x28')]({'where':{'id':_0x433560['params']['id']}})[_0xc1a428('0x14')](handleEntityNotFound(_0x5ad22d,null))[_0xc1a428('0x14')](saveUpdates(_0x433560[_0xc1a428('0xc')],null))[_0xc1a428('0x14')](respondWithResult(_0x5ad22d,null))[_0xc1a428('0x2c')](handleError(_0x5ad22d,null));},exports[_0x15c969('0x23')]=function(_0x43e857,_0x1c7218){const _0x22484c=_0x15c969;return db['Template'][_0x22484c('0x28')]({'where':{'id':_0x43e857[_0x22484c('0x24')]['id']}})[_0x22484c('0x14')](handleEntityNotFound(_0x1c7218,null))[_0x22484c('0x14')](removeEntity(_0x1c7218,null))[_0x22484c('0x2c')](handleError(_0x1c7218,null));}; \ No newline at end of file diff --git a/server/api/template/template.model.js b/server/api/template/template.model.js index c71dadb..5b2562a 100644 --- a/server/api/template/template.model.js +++ b/server/api/template/template.model.js @@ -1 +1 @@ -const a634_0x8c2d=['define','exports','tools_templates','./template.attributes'];(function(_0x437633,_0x8c2d48){const _0x8a467b=function(_0x599b39){while(--_0x599b39){_0x437633['push'](_0x437633['shift']());}};_0x8a467b(++_0x8c2d48);}(a634_0x8c2d,0xfc));const a634_0x8a46=function(_0x437633,_0x8c2d48){_0x437633=_0x437633-0x0;let _0x8a467b=a634_0x8c2d[_0x437633];return _0x8a467b;};const _0x52f1c9=a634_0x8a46;'use strict';const attributes=require(_0x52f1c9('0x3'));module[_0x52f1c9('0x1')]=function(_0x599b39){const _0x11ac3f=_0x52f1c9,_0x280176=_0x599b39[_0x11ac3f('0x0')]('Template',attributes,{'tableName':_0x11ac3f('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x280176;}; \ No newline at end of file +const a634_0x491b=['Template','./template.attributes','exports','tools_templates','define'];(function(_0x3cc4c5,_0x491bd2){const _0xf6df29=function(_0x55308c){while(--_0x55308c){_0x3cc4c5['push'](_0x3cc4c5['shift']());}};_0xf6df29(++_0x491bd2);}(a634_0x491b,0x1c5));const a634_0xf6df=function(_0x3cc4c5,_0x491bd2){_0x3cc4c5=_0x3cc4c5-0x0;let _0xf6df29=a634_0x491b[_0x3cc4c5];return _0xf6df29;};const _0x5a1a3a=a634_0xf6df;'use strict';const attributes=require(_0x5a1a3a('0x3'));module[_0x5a1a3a('0x4')]=function(_0x55308c){const _0x164194=_0x5a1a3a,_0x115af6=_0x55308c[_0x164194('0x1')](_0x164194('0x2'),attributes,{'tableName':_0x164194('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x115af6;}; \ No newline at end of file diff --git a/server/api/template/template.rpc.js b/server/api/template/template.rpc.js index 9853532..153a30f 100644 --- a/server/api/template/template.rpc.js +++ b/server/api/template/template.rpc.js @@ -1 +1 @@ -const a635_0x4dc2=['attributes','findAll','GetTemplate','info','map','error','catch','message','debug','rpc','then','model','options','raw','Template','include','stringify'];(function(_0x28575b,_0x4dc2e1){const _0x1a29fc=function(_0x432197){while(--_0x432197){_0x28575b['push'](_0x28575b['shift']());}};_0x1a29fc(++_0x4dc2e1);}(a635_0x4dc2,0xc0));const a635_0x1a29=function(_0x28575b,_0x4dc2e1){_0x28575b=_0x28575b-0x0;let _0x1a29fc=a635_0x4dc2[_0x28575b];return _0x1a29fc;};const _0x54e254=a635_0x1a29;'use strict';const _=require('lodash'),db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x54e254('0x4'));exports['GetTemplate']=function(_0x432197){const _0x5e6768=this;return new Promise(function(_0x56c6b6,_0x2f44b3){const _0x5c701e=a635_0x1a29;return db[_0x5c701e('0x9')][_0x5c701e('0xd')]({'raw':_0x432197['options']?_0x432197[_0x5c701e('0x7')][_0x5c701e('0x8')]===undefined?!![]:![]:!![],'where':_0x432197['options']?_0x432197[_0x5c701e('0x7')]['where']||null:null,'attributes':_0x432197['options']?_0x432197[_0x5c701e('0x7')]['attributes']||null:null,'limit':_0x432197[_0x5c701e('0x7')]?_0x432197['options']['limit']||null:null,'include':_0x432197[_0x5c701e('0x7')]?_0x432197[_0x5c701e('0x7')]['include']?_[_0x5c701e('0x10')](_0x432197[_0x5c701e('0x7')][_0x5c701e('0xa')],function(_0x36bb45){const _0x438037=_0x5c701e;return{'model':db[_0x36bb45['model']],'as':_0x36bb45['as'],'attributes':_0x36bb45[_0x438037('0xc')],'include':_0x36bb45['include']?_['map'](_0x36bb45['include'],function(_0x25b99d){const _0x5a2bec=_0x438037;return{'model':db[_0x25b99d[_0x5a2bec('0x6')]],'as':_0x25b99d['as'],'attributes':_0x25b99d[_0x5a2bec('0xc')],'include':_0x25b99d['include']?_[_0x5a2bec('0x10')](_0x25b99d['include'],function(_0x2955fb){const _0xe390d8=_0x5a2bec;return{'model':db[_0x2955fb[_0xe390d8('0x6')]],'as':_0x2955fb['as'],'attributes':_0x2955fb[_0xe390d8('0xc')]};}):[]};}):[]};}):[]:[]})[_0x5c701e('0x5')](function(_0x5b6eac){const _0x46b08d=_0x5c701e;logger[_0x46b08d('0xf')](_0x46b08d('0xe'),_0x432197),logger[_0x46b08d('0x3')]('GetTemplate',_0x432197,JSON[_0x46b08d('0xb')](_0x5b6eac)),_0x56c6b6(_0x5b6eac);})[_0x5c701e('0x1')](function(_0x2969b1){const _0x2a248b=_0x5c701e;logger['error']('GetTemplate',_0x2969b1['message'],_0x432197),_0x2f44b3(_0x5e6768[_0x2a248b('0x0')](0x1f4,_0x2969b1[_0x2a248b('0x2')]));});});}; \ No newline at end of file +const a635_0x268a=['message','stringify','include','error','where','debug','limit','rpc','Template','attributes','then','findAll','GetTemplate','../../mysqldb','map','info','model','options'];(function(_0x264d14,_0x268a86){const _0x521469=function(_0xff718f){while(--_0xff718f){_0x264d14['push'](_0x264d14['shift']());}};_0x521469(++_0x268a86);}(a635_0x268a,0xe3));const a635_0x5214=function(_0x264d14,_0x268a86){_0x264d14=_0x264d14-0x0;let _0x521469=a635_0x268a[_0x264d14];return _0x521469;};const _0x3ac45a=a635_0x5214;'use strict';const _=require('lodash'),db=require(_0x3ac45a('0x2'))['db'],logger=require('../../config/logger')(_0x3ac45a('0xe'));exports[_0x3ac45a('0x1')]=function(_0xff718f){const _0x9c80cc=this;return new Promise(function(_0x37dda2,_0x5d9546){const _0x2e0109=a635_0x5214;return db[_0x2e0109('0xf')][_0x2e0109('0x0')]({'raw':_0xff718f[_0x2e0109('0x6')]?_0xff718f['options']['raw']===undefined?!![]:![]:!![],'where':_0xff718f[_0x2e0109('0x6')]?_0xff718f[_0x2e0109('0x6')][_0x2e0109('0xb')]||null:null,'attributes':_0xff718f[_0x2e0109('0x6')]?_0xff718f[_0x2e0109('0x6')][_0x2e0109('0x10')]||null:null,'limit':_0xff718f[_0x2e0109('0x6')]?_0xff718f[_0x2e0109('0x6')][_0x2e0109('0xd')]||null:null,'include':_0xff718f[_0x2e0109('0x6')]?_0xff718f['options'][_0x2e0109('0x9')]?_[_0x2e0109('0x3')](_0xff718f[_0x2e0109('0x6')][_0x2e0109('0x9')],function(_0x29607f){const _0x2c48ce=_0x2e0109;return{'model':db[_0x29607f[_0x2c48ce('0x5')]],'as':_0x29607f['as'],'attributes':_0x29607f[_0x2c48ce('0x10')],'include':_0x29607f[_0x2c48ce('0x9')]?_['map'](_0x29607f['include'],function(_0x31d235){const _0x45a8b8=_0x2c48ce;return{'model':db[_0x31d235[_0x45a8b8('0x5')]],'as':_0x31d235['as'],'attributes':_0x31d235[_0x45a8b8('0x10')],'include':_0x31d235['include']?_[_0x45a8b8('0x3')](_0x31d235[_0x45a8b8('0x9')],function(_0xa73b8){const _0x5e4c34=_0x45a8b8;return{'model':db[_0xa73b8[_0x5e4c34('0x5')]],'as':_0xa73b8['as'],'attributes':_0xa73b8[_0x5e4c34('0x10')]};}):[]};}):[]};}):[]:[]})[_0x2e0109('0x11')](function(_0x36bd10){const _0x17c494=_0x2e0109;logger[_0x17c494('0x4')]('GetTemplate',_0xff718f),logger[_0x17c494('0xc')]('GetTemplate',_0xff718f,JSON[_0x17c494('0x8')](_0x36bd10)),_0x37dda2(_0x36bd10);})['catch'](function(_0x24810a){const _0x204cc9=_0x2e0109;logger[_0x204cc9('0xa')](_0x204cc9('0x1'),_0x24810a[_0x204cc9('0x7')],_0xff718f),_0x5d9546(_0x9c80cc[_0x204cc9('0xa')](0x1f4,_0x24810a[_0x204cc9('0x7')]));});});}; \ No newline at end of file diff --git a/server/api/trigger/index.js b/server/api/trigger/index.js index 59edacf..23f5b2a 100644 --- a/server/api/trigger/index.js +++ b/server/api/trigger/index.js @@ -1 +1 @@ -const a636_0xb419=['/:id','addAction','Router','addAnyCondition','express','show','addAllCondition','getAllConditions','create','/:id/actions','getActions','post','put','getAnyConditions','get','update','isAuthenticated','/:id/any_conditions','/:id/all_conditions','delete','../../components/auth/service'];(function(_0x4d02c9,_0xb41965){const _0x1d40f9=function(_0x28abdf){while(--_0x28abdf){_0x4d02c9['push'](_0x4d02c9['shift']());}};_0x1d40f9(++_0xb41965);}(a636_0xb419,0xc7));const a636_0x1d40=function(_0x4d02c9,_0xb41965){_0x4d02c9=_0x4d02c9-0x0;let _0x1d40f9=a636_0xb419[_0x4d02c9];return _0x1d40f9;};const _0x16ddd5=a636_0x1d40;'use strict';const express=require(_0x16ddd5('0xf')),router=express[_0x16ddd5('0xd')](),auth=require(_0x16ddd5('0xa')),controller=require('./trigger.controller');router[_0x16ddd5('0x4')]('/',auth[_0x16ddd5('0x6')](),controller['index']),router[_0x16ddd5('0x4')]('/:id',auth[_0x16ddd5('0x6')](),controller[_0x16ddd5('0x10')]),router[_0x16ddd5('0x4')](_0x16ddd5('0x8'),auth['isAuthenticated'](),controller[_0x16ddd5('0x12')]),router[_0x16ddd5('0x4')](_0x16ddd5('0x7'),auth[_0x16ddd5('0x6')](),controller[_0x16ddd5('0x3')]),router['get']('/:id/actions',auth['isAuthenticated'](),controller[_0x16ddd5('0x0')]),router[_0x16ddd5('0x1')]('/',auth[_0x16ddd5('0x6')](),controller[_0x16ddd5('0x13')]),router[_0x16ddd5('0x1')](_0x16ddd5('0x8'),auth['isAuthenticated'](),controller[_0x16ddd5('0x11')]),router[_0x16ddd5('0x1')](_0x16ddd5('0x7'),auth[_0x16ddd5('0x6')](),controller[_0x16ddd5('0xe')]),router[_0x16ddd5('0x1')](_0x16ddd5('0x14'),auth[_0x16ddd5('0x6')](),controller[_0x16ddd5('0xc')]),router[_0x16ddd5('0x2')]('/:id',auth[_0x16ddd5('0x6')](),controller[_0x16ddd5('0x5')]),router[_0x16ddd5('0x9')](_0x16ddd5('0xb'),auth[_0x16ddd5('0x6')](),controller['destroy']),module['exports']=router; \ No newline at end of file +const a636_0x1a03=['put','/:id/any_conditions','getActions','/:id','index','../../components/auth/service','delete','destroy','addAnyCondition','/:id/all_conditions','getAnyConditions','./trigger.controller','create','addAction','get','Router','update','post','addAllCondition','isAuthenticated'];(function(_0x2d8e12,_0x1a034c){const _0x10dc92=function(_0x529ac2){while(--_0x529ac2){_0x2d8e12['push'](_0x2d8e12['shift']());}};_0x10dc92(++_0x1a034c);}(a636_0x1a03,0xea));const a636_0x10dc=function(_0x2d8e12,_0x1a034c){_0x2d8e12=_0x2d8e12-0x0;let _0x10dc92=a636_0x1a03[_0x2d8e12];return _0x10dc92;};const _0x105f12=a636_0x10dc;'use strict';const express=require('express'),router=express[_0x105f12('0x1')](),auth=require(_0x105f12('0xb')),controller=require(_0x105f12('0x11'));router[_0x105f12('0x0')]('/',auth[_0x105f12('0x5')](),controller[_0x105f12('0xa')]),router[_0x105f12('0x0')]('/:id',auth[_0x105f12('0x5')](),controller['show']),router['get']('/:id/all_conditions',auth[_0x105f12('0x5')](),controller['getAllConditions']),router['get'](_0x105f12('0x7'),auth['isAuthenticated'](),controller[_0x105f12('0x10')]),router[_0x105f12('0x0')]('/:id/actions',auth[_0x105f12('0x5')](),controller[_0x105f12('0x8')]),router[_0x105f12('0x3')]('/',auth[_0x105f12('0x5')](),controller[_0x105f12('0x12')]),router['post'](_0x105f12('0xf'),auth[_0x105f12('0x5')](),controller[_0x105f12('0x4')]),router[_0x105f12('0x3')](_0x105f12('0x7'),auth[_0x105f12('0x5')](),controller[_0x105f12('0xe')]),router[_0x105f12('0x3')]('/:id/actions',auth[_0x105f12('0x5')](),controller[_0x105f12('0x13')]),router[_0x105f12('0x6')](_0x105f12('0x9'),auth['isAuthenticated'](),controller[_0x105f12('0x2')]),router[_0x105f12('0xc')](_0x105f12('0x9'),auth[_0x105f12('0x5')](),controller[_0x105f12('0xd')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/trigger/trigger.attributes.js b/server/api/trigger/trigger.attributes.js index a2b6fe9..de92d05 100644 --- a/server/api/trigger/trigger.attributes.js +++ b/server/api/trigger/trigger.attributes.js @@ -1 +1 @@ -const a637_0x11f3=['STRING','BOOLEAN','exports','sequelize'];(function(_0x5f4897,_0x11f3a7){const _0x42275f=function(_0x2a84c1){while(--_0x2a84c1){_0x5f4897['push'](_0x5f4897['shift']());}};_0x42275f(++_0x11f3a7);}(a637_0x11f3,0xdb));const a637_0x4227=function(_0x5f4897,_0x11f3a7){_0x5f4897=_0x5f4897-0x0;let _0x42275f=a637_0x11f3[_0x5f4897];return _0x42275f;};const _0x15361a=a637_0x4227;'use strict';const Sequelize=require(_0x15361a('0x0'));module[_0x15361a('0x3')]={'name':{'type':Sequelize['STRING']},'channel':{'type':Sequelize[_0x15361a('0x1')]},'description':{'type':Sequelize[_0x15361a('0x1')]},'status':{'type':Sequelize[_0x15361a('0x2')],'defaultValue':![]}}; \ No newline at end of file +const a637_0x4d08=['exports','STRING','sequelize','BOOLEAN'];(function(_0x204ef0,_0x4d08a1){const _0x3fd05e=function(_0x1e36d5){while(--_0x1e36d5){_0x204ef0['push'](_0x204ef0['shift']());}};_0x3fd05e(++_0x4d08a1);}(a637_0x4d08,0xef));const a637_0x3fd0=function(_0x204ef0,_0x4d08a1){_0x204ef0=_0x204ef0-0x0;let _0x3fd05e=a637_0x4d08[_0x204ef0];return _0x3fd05e;};const _0x193607=a637_0x3fd0;'use strict';const Sequelize=require(_0x193607('0x3'));module[_0x193607('0x1')]={'name':{'type':Sequelize[_0x193607('0x2')]},'channel':{'type':Sequelize['STRING']},'description':{'type':Sequelize[_0x193607('0x2')]},'status':{'type':Sequelize[_0x193607('0x0')],'defaultValue':![]}}; \ No newline at end of file diff --git a/server/api/trigger/trigger.controller.js b/server/api/trigger/trigger.controller.js index e0b68ad..4b05cf3 100644 --- a/server/api/trigger/trigger.controller.js +++ b/server/api/trigger/trigger.controller.js @@ -1 +1 @@ -const a638_0x1f21=['getActions','where','filter','addAnyCondition','fields','map','send','length','Condition','status','options','json','index','stack','name','error','limit','Triggers','merge','key','role','Action','offset','keys','rawAttributes','Content-Range','create','nolimit','show','findOne','type','getAnyConditions','catch','user','get','attributes','TriggerAllId','TriggerAnyId','Trigger','filters','fieldName','destroy','findAll','UserProfileSection','query','then','undefined','like','../../components/parsers/qs','pick','addAllCondition','api','sort','model','sendStatus','rows','VIRTUAL','../../config/logger','update','includeAll','getAllConditions','lodash','../../mysqldb','addAction','UserProfileResource','body','count','order','TriggerId','params','intersection'];(function(_0x130a4c,_0x1f2158){const _0x522dfa=function(_0x252415){while(--_0x252415){_0x130a4c['push'](_0x130a4c['shift']());}};_0x522dfa(++_0x1f2158);}(a638_0x1f21,0x138));const a638_0x522d=function(_0x130a4c,_0x1f2158){_0x130a4c=_0x130a4c-0x0;let _0x522dfa=a638_0x1f21[_0x130a4c];return _0x522dfa;};const _0x11cc39=a638_0x522d;'use strict';const _=require(_0x11cc39('0x21')),qs=require(_0x11cc39('0x14')),logger=require(_0x11cc39('0x1d'))(_0x11cc39('0x17')),db=require(_0x11cc39('0x22'))['db'],{Op}=require('sequelize');function respondWithResult(_0x252415,_0xfeadb1){return _0xfeadb1=_0xfeadb1||0xc8,function(_0x3b8c30){const _0x1c8162=a638_0x522d;if(_0x3b8c30)return _0x252415[_0x1c8162('0x34')](_0xfeadb1)['json'](_0x3b8c30);};}function respondWithFilteredResult(_0x503d19,_0x37fa87){return function(_0xb6dddc){const _0x4a27f2=a638_0x522d;if(_0xb6dddc){const _0x47f99f=_0xb6dddc['count'],_0x1a5390=_0x37fa87['offset'];let _0x2c9121=_0x37fa87[_0x4a27f2('0x41')]+_0x37fa87[_0x4a27f2('0x3b')],_0x1162be;return _0x2c9121>=_0x47f99f?(_0x2c9121=_0x47f99f,_0x1162be=0xc8):_0x1162be=0xce,_0x503d19[_0x4a27f2('0x34')](_0x1162be),_0x503d19['set'](_0x4a27f2('0x44'),_0x1a5390+'-'+_0x2c9121+'/'+_0x47f99f)[_0x4a27f2('0x36')](_0xb6dddc);}return null;};}function saveUpdates(_0x559f6b){return function(_0x6ad278){const _0x21ebe2=a638_0x522d;if(_0x6ad278)return _0x6ad278[_0x21ebe2('0x1e')](_0x559f6b)['then'](function(_0x10d432){return _0x10d432;});return null;};}function removeEntity(_0x33f694){return function(_0x164547){const _0x56ce7d=a638_0x522d;if(_0x164547)return _0x164547[_0x56ce7d('0xd')]()['then'](function(){const _0x6b9c03=_0x56ce7d,_0x4625de=_0x164547[_0x6b9c03('0x6')]({'plain':!![]}),_0x31c274=_0x6b9c03('0x3c');return db[_0x6b9c03('0x24')][_0x6b9c03('0xd')]({'where':{'type':_0x31c274,'resourceId':_0x4625de['id']}})['then'](function(){return _0x164547;});})['then'](function(){const _0x149526=_0x56ce7d;_0x33f694[_0x149526('0x34')](0xcc)['end']();});};}function handleEntityNotFound(_0x42fe6e){return function(_0x2d5329){const _0x17e8df=a638_0x522d;return!_0x2d5329&&_0x42fe6e[_0x17e8df('0x1a')](0x194),_0x2d5329;};}function handleError(_0x59c5a9,_0x37e39b){return _0x37e39b=_0x37e39b||0x1f4,function(_0x5a9bcc){const _0x1d3632=a638_0x522d;logger['error'](_0x5a9bcc[_0x1d3632('0x38')]),_0x5a9bcc['name']&&delete _0x5a9bcc[_0x1d3632('0x39')],_0x59c5a9[_0x1d3632('0x34')](_0x37e39b)[_0x1d3632('0x31')](_0x5a9bcc);};}exports[_0x11cc39('0x37')]=function(_0x4fb2f4,_0x3642bb){const _0x42afd7=_0x11cc39;let _0x27ca13={};const _0x32bf05={},_0x298056={'count':0x0,'rows':[]},_0x2eef77=_[_0x42afd7('0x30')](db[_0x42afd7('0xa')][_0x42afd7('0x43')],function(_0x1e7c1b){const _0x3a1c44=_0x42afd7;return{'name':_0x1e7c1b[_0x3a1c44('0xc')],'type':_0x1e7c1b[_0x3a1c44('0x2')][_0x3a1c44('0x3e')]};});_0x32bf05[_0x42afd7('0x19')]=_[_0x42afd7('0x30')](_0x2eef77,_0x42afd7('0x39')),_0x32bf05[_0x42afd7('0x10')]=_[_0x42afd7('0x42')](_0x4fb2f4[_0x42afd7('0x10')]),_0x32bf05['filters']=_['intersection'](_0x32bf05[_0x42afd7('0x19')],_0x32bf05[_0x42afd7('0x10')]),_0x27ca13[_0x42afd7('0x7')]=_[_0x42afd7('0x2a')](_0x32bf05[_0x42afd7('0x19')],qs[_0x42afd7('0x2f')](_0x4fb2f4[_0x42afd7('0x10')][_0x42afd7('0x2f')])),_0x27ca13[_0x42afd7('0x7')]=_0x27ca13[_0x42afd7('0x7')]['length']?_0x27ca13['attributes']:_0x32bf05[_0x42afd7('0x19')];typeof _0x4fb2f4['query'][_0x42afd7('0x46')]===_0x42afd7('0x12')&&(_0x27ca13[_0x42afd7('0x3b')]=qs[_0x42afd7('0x3b')](_0x4fb2f4[_0x42afd7('0x10')][_0x42afd7('0x3b')]),_0x27ca13[_0x42afd7('0x41')]=qs[_0x42afd7('0x41')](_0x4fb2f4[_0x42afd7('0x10')][_0x42afd7('0x41')]));_0x27ca13[_0x42afd7('0x27')]=qs[_0x42afd7('0x18')](_0x4fb2f4['query'][_0x42afd7('0x18')]),_0x27ca13[_0x42afd7('0x2c')]=qs[_0x42afd7('0xb')](_[_0x42afd7('0x15')](_0x4fb2f4[_0x42afd7('0x10')],_0x32bf05[_0x42afd7('0xb')]),_0x2eef77);_0x4fb2f4['query'][_0x42afd7('0x2d')]&&(_0x27ca13[_0x42afd7('0x2c')]=_[_0x42afd7('0x3d')](_0x27ca13[_0x42afd7('0x2c')],{[Op['or']]:_[_0x42afd7('0x30')](_0x2eef77,function(_0x56807f){const _0x16c587=_0x42afd7;if(_0x56807f[_0x16c587('0x2')]!==_0x16c587('0x1c')){const _0x538e13={};return _0x538e13[_0x56807f[_0x16c587('0x39')]]={[Op['like']]:'%'+_0x4fb2f4[_0x16c587('0x10')][_0x16c587('0x2d')]+'%'},_0x538e13;}})}));_0x27ca13=_[_0x42afd7('0x3d')]({},_0x27ca13,_0x4fb2f4['options']);const _0x4b8856={'where':_0x27ca13[_0x42afd7('0x2c')]};return db[_0x42afd7('0xa')][_0x42afd7('0x26')](_0x4b8856)['then'](function(_0x23b124){const _0x4da86d=_0x42afd7;return _0x298056['count']=_0x23b124,_0x4fb2f4['query'][_0x4da86d('0x1f')]&&(_0x27ca13['include']=[{'all':!![]}]),db[_0x4da86d('0xa')][_0x4da86d('0xe')](_0x27ca13);})[_0x42afd7('0x11')](function(_0x335629){const _0x375383=_0x42afd7;return _0x298056[_0x375383('0x1b')]=_0x335629,_0x298056;})[_0x42afd7('0x11')](respondWithFilteredResult(_0x3642bb,_0x27ca13))[_0x42afd7('0x4')](handleError(_0x3642bb,null));},exports[_0x11cc39('0x0')]=function(_0x47d250,_0x424d7f){const _0x4507b9=_0x11cc39;let _0x375081={'raw':![],'where':{'id':_0x47d250[_0x4507b9('0x29')]['id']}};const _0x4561a3={};return _0x4561a3['model']=_[_0x4507b9('0x42')](db[_0x4507b9('0xa')][_0x4507b9('0x43')]),_0x4561a3[_0x4507b9('0x10')]=_[_0x4507b9('0x42')](_0x47d250[_0x4507b9('0x10')]),_0x4561a3['filters']=_['intersection'](_0x4561a3[_0x4507b9('0x19')],_0x4561a3[_0x4507b9('0x10')]),_0x375081[_0x4507b9('0x7')]=_['intersection'](_0x4561a3[_0x4507b9('0x19')],qs['fields'](_0x47d250[_0x4507b9('0x10')][_0x4507b9('0x2f')])),_0x375081[_0x4507b9('0x7')]=_0x375081['attributes'][_0x4507b9('0x32')]?_0x375081[_0x4507b9('0x7')]:_0x4561a3[_0x4507b9('0x19')],_0x47d250[_0x4507b9('0x10')]['includeAll']&&(_0x375081['include']=[{'all':!![]}]),_0x375081=_[_0x4507b9('0x3d')]({},_0x375081,_0x47d250['options']),db[_0x4507b9('0xa')][_0x4507b9('0x1')](_0x375081)[_0x4507b9('0x11')](handleEntityNotFound(_0x424d7f,null))[_0x4507b9('0x11')](respondWithResult(_0x424d7f,null))[_0x4507b9('0x4')](handleError(_0x424d7f,null));},exports['create']=function(_0x102483,_0x2371b1){const _0x459669=_0x11cc39;return db[_0x459669('0xa')][_0x459669('0x45')](_0x102483[_0x459669('0x25')],{})[_0x459669('0x11')](function(_0x27ac60){const _0x7716a5=_0x459669,_0x2e7fb7=_0x102483[_0x7716a5('0x5')][_0x7716a5('0x6')]({'plain':!![]});if(!_0x2e7fb7)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x2e7fb7[_0x7716a5('0x3f')]===_0x7716a5('0x5')){const _0x46354d=_0x27ac60['get']({'plain':!![]}),_0x30fc5a=_0x7716a5('0x3c');return db[_0x7716a5('0xf')]['findOne']({'where':{'name':_0x30fc5a,'userProfileId':_0x2e7fb7['userProfileId']},'raw':!![]})[_0x7716a5('0x11')](function(_0x5e4d8f){const _0x2ac9b0=_0x7716a5;return _0x5e4d8f&&_0x5e4d8f['autoAssociation']===0x0?db[_0x2ac9b0('0x24')][_0x2ac9b0('0x45')]({'name':_0x46354d['name'],'resourceId':_0x46354d['id'],'type':_0x5e4d8f[_0x2ac9b0('0x39')],'sectionId':_0x5e4d8f['id']},{})[_0x2ac9b0('0x11')](function(){return _0x27ac60;}):_0x27ac60;})[_0x7716a5('0x4')](function(_0x581ffe){const _0x5f981f=_0x7716a5;logger[_0x5f981f('0x3a')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x581ffe);throw _0x581ffe;});}return _0x27ac60;})[_0x459669('0x11')](respondWithResult(_0x2371b1,0xc9))['catch'](handleError(_0x2371b1,null));},exports[_0x11cc39('0x1e')]=function(_0x18712f,_0x2e077e){const _0x48e3e6=_0x11cc39;return _0x18712f[_0x48e3e6('0x25')]['id']&&delete _0x18712f[_0x48e3e6('0x25')]['id'],db[_0x48e3e6('0xa')]['findOne']({'where':{'id':_0x18712f[_0x48e3e6('0x29')]['id']}})[_0x48e3e6('0x11')](handleEntityNotFound(_0x2e077e,null))[_0x48e3e6('0x11')](saveUpdates(_0x18712f[_0x48e3e6('0x25')],null))[_0x48e3e6('0x11')](respondWithResult(_0x2e077e,null))[_0x48e3e6('0x4')](handleError(_0x2e077e,null));},exports['destroy']=function(_0x1a8973,_0x4c9b8c){const _0x26fa70=_0x11cc39;return db[_0x26fa70('0xa')][_0x26fa70('0x1')]({'where':{'id':_0x1a8973[_0x26fa70('0x29')]['id']}})[_0x26fa70('0x11')](handleEntityNotFound(_0x4c9b8c,null))[_0x26fa70('0x11')](removeEntity(_0x4c9b8c,null))['catch'](handleError(_0x4c9b8c,null));},exports[_0x11cc39('0x16')]=function(_0x29704b,_0x500fa5){const _0x2da131=_0x11cc39;return _0x29704b[_0x2da131('0x25')]['id']&&delete _0x29704b[_0x2da131('0x25')]['id'],db[_0x2da131('0xa')]['findOne']({'where':{'id':_0x29704b[_0x2da131('0x29')]['id']}})[_0x2da131('0x11')](handleEntityNotFound(_0x500fa5,null))[_0x2da131('0x11')](function(_0x409d27){const _0x15cdd2=_0x2da131;if(_0x409d27)return _0x29704b[_0x15cdd2('0x25')][_0x15cdd2('0x8')]=_0x409d27['id'],db[_0x15cdd2('0x33')][_0x15cdd2('0x45')](_0x29704b[_0x15cdd2('0x25')]);})[_0x2da131('0x11')](respondWithResult(_0x500fa5,null))[_0x2da131('0x4')](handleError(_0x500fa5,null));},exports[_0x11cc39('0x2e')]=function(_0x1ba0ba,_0x1dc032){const _0x409d74=_0x11cc39;return _0x1ba0ba[_0x409d74('0x25')]['id']&&delete _0x1ba0ba[_0x409d74('0x25')]['id'],db['Trigger'][_0x409d74('0x1')]({'where':{'id':_0x1ba0ba['params']['id']}})[_0x409d74('0x11')](handleEntityNotFound(_0x1dc032,null))[_0x409d74('0x11')](function(_0x412600){const _0x3b0332=_0x409d74;if(_0x412600)return _0x1ba0ba[_0x3b0332('0x25')][_0x3b0332('0x9')]=_0x412600['id'],db[_0x3b0332('0x33')]['create'](_0x1ba0ba['body']);})[_0x409d74('0x11')](respondWithResult(_0x1dc032,null))[_0x409d74('0x4')](handleError(_0x1dc032,null));},exports[_0x11cc39('0x20')]=function(_0x2649df,_0x37a2dd){const _0x2b53c6=_0x11cc39;let _0x3ae432={};const _0x1ec9d6={};let _0x3ead33,_0x25a2af;return db['Trigger']['findOne']({'where':{'id':_0x2649df[_0x2b53c6('0x29')]['id']}})[_0x2b53c6('0x11')](handleEntityNotFound(_0x37a2dd,null))[_0x2b53c6('0x11')](function(_0x3301a1){const _0x5e4a9b=_0x2b53c6;if(_0x3301a1)return _0x3ead33=_0x3301a1,_0x1ec9d6[_0x5e4a9b('0x19')]=_['keys'](db[_0x5e4a9b('0x33')][_0x5e4a9b('0x43')]),_0x1ec9d6['query']=_[_0x5e4a9b('0x42')](_0x2649df['query']),_0x1ec9d6[_0x5e4a9b('0xb')]=_[_0x5e4a9b('0x2a')](_0x1ec9d6[_0x5e4a9b('0x19')],_0x1ec9d6[_0x5e4a9b('0x10')]),_0x3ae432[_0x5e4a9b('0x7')]=_[_0x5e4a9b('0x2a')](_0x1ec9d6[_0x5e4a9b('0x19')],qs[_0x5e4a9b('0x2f')](_0x2649df[_0x5e4a9b('0x10')]['fields'])),_0x3ae432[_0x5e4a9b('0x7')]=_0x3ae432[_0x5e4a9b('0x7')][_0x5e4a9b('0x32')]?_0x3ae432[_0x5e4a9b('0x7')]:_0x1ec9d6[_0x5e4a9b('0x19')],_0x3ae432[_0x5e4a9b('0x27')]=qs[_0x5e4a9b('0x18')](_0x2649df[_0x5e4a9b('0x10')][_0x5e4a9b('0x18')]),_0x3ae432['where']=qs[_0x5e4a9b('0xb')](_[_0x5e4a9b('0x15')](_0x2649df['query'],_0x1ec9d6['filters'])),_0x2649df[_0x5e4a9b('0x10')][_0x5e4a9b('0x2d')]&&(_0x3ae432[_0x5e4a9b('0x2c')]=_['merge'](_0x3ae432[_0x5e4a9b('0x2c')],{[Op['or']]:_[_0x5e4a9b('0x30')](_0x3ae432[_0x5e4a9b('0x7')],function(_0x57d528){const _0x242858=_0x5e4a9b,_0x15bcd4={};return _0x15bcd4[_0x57d528]={[Op[_0x242858('0x13')]]:'%'+_0x2649df[_0x242858('0x10')][_0x242858('0x2d')]+'%'},_0x15bcd4;})})),_0x3ae432=_[_0x5e4a9b('0x3d')]({},_0x3ae432,_0x2649df[_0x5e4a9b('0x35')]),_0x3ead33['getAllConditions'](_0x3ae432);})[_0x2b53c6('0x11')](function(_0x5bbd65){const _0x428388=_0x2b53c6;if(_0x5bbd65)return _0x25a2af=_0x5bbd65[_0x428388('0x32')],typeof _0x2649df[_0x428388('0x10')]['nolimit']==='undefined'&&(_0x3ae432[_0x428388('0x3b')]=qs[_0x428388('0x3b')](_0x2649df['query'][_0x428388('0x3b')]),_0x3ae432[_0x428388('0x41')]=qs[_0x428388('0x41')](_0x2649df[_0x428388('0x10')][_0x428388('0x41')])),_0x3ead33[_0x428388('0x20')](_0x3ae432);})[_0x2b53c6('0x11')](function(_0x1997b6){if(_0x1997b6)return _0x1997b6?{'count':_0x25a2af,'rows':_0x1997b6}:null;})[_0x2b53c6('0x11')](respondWithResult(_0x37a2dd,null))['catch'](handleError(_0x37a2dd,null));},exports[_0x11cc39('0x3')]=function(_0xafdeab,_0x528428){const _0x303adf=_0x11cc39;let _0x52250a={};const _0x301ed0={};let _0x566c25,_0x20d18f;return db[_0x303adf('0xa')][_0x303adf('0x1')]({'where':{'id':_0xafdeab[_0x303adf('0x29')]['id']}})[_0x303adf('0x11')](handleEntityNotFound(_0x528428,null))[_0x303adf('0x11')](function(_0xcccd44){const _0x5549e8=_0x303adf;if(_0xcccd44)return _0x566c25=_0xcccd44,_0x301ed0[_0x5549e8('0x19')]=_['keys'](db[_0x5549e8('0x33')][_0x5549e8('0x43')]),_0x301ed0['query']=_[_0x5549e8('0x42')](_0xafdeab[_0x5549e8('0x10')]),_0x301ed0[_0x5549e8('0xb')]=_[_0x5549e8('0x2a')](_0x301ed0[_0x5549e8('0x19')],_0x301ed0[_0x5549e8('0x10')]),_0x52250a['attributes']=_['intersection'](_0x301ed0[_0x5549e8('0x19')],qs['fields'](_0xafdeab['query'][_0x5549e8('0x2f')])),_0x52250a[_0x5549e8('0x7')]=_0x52250a[_0x5549e8('0x7')][_0x5549e8('0x32')]?_0x52250a[_0x5549e8('0x7')]:_0x301ed0[_0x5549e8('0x19')],_0x52250a[_0x5549e8('0x27')]=qs['sort'](_0xafdeab[_0x5549e8('0x10')][_0x5549e8('0x18')]),_0x52250a[_0x5549e8('0x2c')]=qs[_0x5549e8('0xb')](_[_0x5549e8('0x15')](_0xafdeab['query'],_0x301ed0[_0x5549e8('0xb')])),_0xafdeab[_0x5549e8('0x10')]['filter']&&(_0x52250a[_0x5549e8('0x2c')]=_['merge'](_0x52250a[_0x5549e8('0x2c')],{[Op['or']]:_['map'](_0x52250a[_0x5549e8('0x7')],function(_0x2865a2){const _0xb0ffb5=_0x5549e8,_0x2a6760={};return _0x2a6760[_0x2865a2]={[Op[_0xb0ffb5('0x13')]]:'%'+_0xafdeab[_0xb0ffb5('0x10')]['filter']+'%'},_0x2a6760;})})),_0x52250a=_['merge']({},_0x52250a,_0xafdeab[_0x5549e8('0x35')]),_0x566c25[_0x5549e8('0x3')](_0x52250a);})[_0x303adf('0x11')](function(_0x10fca0){const _0x2e4378=_0x303adf;if(_0x10fca0)return _0x20d18f=_0x10fca0[_0x2e4378('0x32')],typeof _0xafdeab[_0x2e4378('0x10')][_0x2e4378('0x46')]===_0x2e4378('0x12')&&(_0x52250a[_0x2e4378('0x3b')]=qs[_0x2e4378('0x3b')](_0xafdeab[_0x2e4378('0x10')][_0x2e4378('0x3b')]),_0x52250a[_0x2e4378('0x41')]=qs[_0x2e4378('0x41')](_0xafdeab[_0x2e4378('0x10')][_0x2e4378('0x41')])),_0x566c25[_0x2e4378('0x3')](_0x52250a);})[_0x303adf('0x11')](function(_0x231049){if(_0x231049)return _0x231049?{'count':_0x20d18f,'rows':_0x231049}:null;})[_0x303adf('0x11')](respondWithResult(_0x528428,null))['catch'](handleError(_0x528428,null));},exports[_0x11cc39('0x23')]=function(_0x5991df,_0x3f0803){const _0x5d0f09=_0x11cc39;return _0x5991df[_0x5d0f09('0x25')]['id']&&delete _0x5991df[_0x5d0f09('0x25')]['id'],db[_0x5d0f09('0xa')][_0x5d0f09('0x1')]({'where':{'id':_0x5991df[_0x5d0f09('0x29')]['id']}})[_0x5d0f09('0x11')](handleEntityNotFound(_0x3f0803,null))[_0x5d0f09('0x11')](function(_0x3f5bf0){const _0x198fa7=_0x5d0f09;if(_0x3f5bf0)return _0x5991df[_0x198fa7('0x25')][_0x198fa7('0x28')]=_0x3f5bf0['id'],db[_0x198fa7('0x40')][_0x198fa7('0x45')](_0x5991df[_0x198fa7('0x25')]);})[_0x5d0f09('0x11')](respondWithResult(_0x3f0803,null))['catch'](handleError(_0x3f0803,null));},exports[_0x11cc39('0x2b')]=function(_0x5d60ee,_0x5e8017){const _0x542077=_0x11cc39;let _0x477168={};const _0x10b5c9={};let _0x31a515,_0x57bb1e;return db[_0x542077('0xa')]['findOne']({'where':{'id':_0x5d60ee[_0x542077('0x29')]['id']}})['then'](handleEntityNotFound(_0x5e8017,null))[_0x542077('0x11')](function(_0x1cfef9){const _0x388cd5=_0x542077;if(_0x1cfef9)return _0x31a515=_0x1cfef9,_0x10b5c9['model']=_[_0x388cd5('0x42')](db[_0x388cd5('0x40')][_0x388cd5('0x43')]),_0x10b5c9[_0x388cd5('0x10')]=_[_0x388cd5('0x42')](_0x5d60ee[_0x388cd5('0x10')]),_0x10b5c9[_0x388cd5('0xb')]=_[_0x388cd5('0x2a')](_0x10b5c9[_0x388cd5('0x19')],_0x10b5c9[_0x388cd5('0x10')]),_0x477168[_0x388cd5('0x7')]=_['intersection'](_0x10b5c9['model'],qs['fields'](_0x5d60ee[_0x388cd5('0x10')][_0x388cd5('0x2f')])),_0x477168['attributes']=_0x477168[_0x388cd5('0x7')][_0x388cd5('0x32')]?_0x477168['attributes']:_0x10b5c9[_0x388cd5('0x19')],_0x477168[_0x388cd5('0x27')]=qs[_0x388cd5('0x18')](_0x5d60ee['query']['sort']),_0x477168[_0x388cd5('0x2c')]=qs[_0x388cd5('0xb')](_[_0x388cd5('0x15')](_0x5d60ee[_0x388cd5('0x10')],_0x10b5c9[_0x388cd5('0xb')])),_0x5d60ee[_0x388cd5('0x10')][_0x388cd5('0x2d')]&&(_0x477168[_0x388cd5('0x2c')]=_['merge'](_0x477168[_0x388cd5('0x2c')],{[Op['or']]:_['map'](_0x477168[_0x388cd5('0x7')],function(_0x6374bb){const _0x2bcb4c=_0x388cd5,_0x6b04b8={};return _0x6b04b8[_0x6374bb]={[Op[_0x2bcb4c('0x13')]]:'%'+_0x5d60ee[_0x2bcb4c('0x10')][_0x2bcb4c('0x2d')]+'%'},_0x6b04b8;})})),_0x477168=_[_0x388cd5('0x3d')]({},_0x477168,_0x5d60ee[_0x388cd5('0x35')]),_0x31a515[_0x388cd5('0x2b')](_0x477168);})[_0x542077('0x11')](function(_0x11639e){const _0x471715=_0x542077;if(_0x11639e)return _0x57bb1e=_0x11639e['length'],typeof _0x5d60ee[_0x471715('0x10')][_0x471715('0x46')]===_0x471715('0x12')&&(_0x477168[_0x471715('0x3b')]=qs['limit'](_0x5d60ee[_0x471715('0x10')][_0x471715('0x3b')]),_0x477168['offset']=qs[_0x471715('0x41')](_0x5d60ee[_0x471715('0x10')]['offset'])),_0x31a515[_0x471715('0x2b')](_0x477168);})[_0x542077('0x11')](function(_0x343003){if(_0x343003)return _0x343003?{'count':_0x57bb1e,'rows':_0x343003}:null;})[_0x542077('0x11')](respondWithResult(_0x5e8017,null))['catch'](handleError(_0x5e8017,null));}; \ No newline at end of file +const a638_0x3dd5=['order','status','catch','like','Trigger','update','includeAll','send','../../components/parsers/qs','TriggerId','merge','index','addAnyCondition','params','intersection','body','fieldName','offset','filters','getActions','findOne','then','TriggerAllId','undefined','get','destroy','user','attributes','sequelize','getAnyConditions','Unable\x20to\x20retrieve\x20the\x20current\x20user','rawAttributes','keys','map','sort','where','UserProfileSection','limit','addAllCondition','findAll','count','end','Content-Range','filter','UserProfileResource','show','model','Action','fields','key','userProfileId','Triggers','options','query','name','getAllConditions','pick','Condition','nolimit','type','include','length','role','json','error','create'];(function(_0x24925e,_0x3dd5f3){const _0x323012=function(_0x406c59){while(--_0x406c59){_0x24925e['push'](_0x24925e['shift']());}};_0x323012(++_0x3dd5f3);}(a638_0x3dd5,0x1ba));const a638_0x3230=function(_0x24925e,_0x3dd5f3){_0x24925e=_0x24925e-0x0;let _0x323012=a638_0x3dd5[_0x24925e];return _0x323012;};const _0x271fc7=a638_0x3230;'use strict';const _=require('lodash'),qs=require(_0x271fc7('0x1c')),logger=require('../../config/logger')('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x271fc7('0x30'));function respondWithResult(_0x406c59,_0x30b380){return _0x30b380=_0x30b380||0xc8,function(_0x11b5c6){const _0x3d181a=a638_0x3230;if(_0x11b5c6)return _0x406c59['status'](_0x30b380)[_0x3d181a('0x11')](_0x11b5c6);};}function respondWithFilteredResult(_0x41cf5c,_0xe3de9e){return function(_0x1573ba){const _0x4949de=a638_0x3230;if(_0x1573ba){const _0x2f1b73=_0x1573ba[_0x4949de('0x3c')],_0x248842=_0xe3de9e['offset'];let _0x227610=_0xe3de9e[_0x4949de('0x25')]+_0xe3de9e[_0x4949de('0x39')],_0x506383;return _0x227610>=_0x2f1b73?(_0x227610=_0x2f1b73,_0x506383=0xc8):_0x506383=0xce,_0x41cf5c[_0x4949de('0x15')](_0x506383),_0x41cf5c['set'](_0x4949de('0x3e'),_0x248842+'-'+_0x227610+'/'+_0x2f1b73)[_0x4949de('0x11')](_0x1573ba);}return null;};}function saveUpdates(_0x131957){return function(_0xaf8f56){const _0xe656b0=a638_0x3230;if(_0xaf8f56)return _0xaf8f56[_0xe656b0('0x19')](_0x131957)[_0xe656b0('0x29')](function(_0x2dcc14){return _0x2dcc14;});return null;};}function removeEntity(_0xbb28a2){return function(_0x502b5c){const _0x1c74b5=a638_0x3230;if(_0x502b5c)return _0x502b5c['destroy']()[_0x1c74b5('0x29')](function(){const _0x5b4034=_0x1c74b5,_0x4898c6=_0x502b5c[_0x5b4034('0x2c')]({'plain':!![]}),_0x480d21='Triggers';return db[_0x5b4034('0x40')][_0x5b4034('0x2d')]({'where':{'type':_0x480d21,'resourceId':_0x4898c6['id']}})[_0x5b4034('0x29')](function(){return _0x502b5c;});})['then'](function(){const _0x442af7=_0x1c74b5;_0xbb28a2[_0x442af7('0x15')](0xcc)[_0x442af7('0x3d')]();});};}function handleEntityNotFound(_0x5c3e75){return function(_0x519fb7){return!_0x519fb7&&_0x5c3e75['sendStatus'](0x194),_0x519fb7;};}function handleError(_0x5e74d9,_0x1a2f81){return _0x1a2f81=_0x1a2f81||0x1f4,function(_0x317bde){const _0x34a0ee=a638_0x3230;logger[_0x34a0ee('0x12')](_0x317bde['stack']),_0x317bde['name']&&delete _0x317bde[_0x34a0ee('0x8')],_0x5e74d9['status'](_0x1a2f81)[_0x34a0ee('0x1b')](_0x317bde);};}exports[_0x271fc7('0x1f')]=function(_0x280b53,_0x6584e8){const _0x171860=_0x271fc7;let _0x2605f9={};const _0x58f48a={},_0x5824b2={'count':0x0,'rows':[]},_0x348e8a=_[_0x171860('0x35')](db[_0x171860('0x18')][_0x171860('0x33')],function(_0x1ee0ba){const _0x4efe09=_0x171860;return{'name':_0x1ee0ba[_0x4efe09('0x24')],'type':_0x1ee0ba[_0x4efe09('0xd')][_0x4efe09('0x3')]};});_0x58f48a[_0x171860('0x0')]=_[_0x171860('0x35')](_0x348e8a,_0x171860('0x8')),_0x58f48a['query']=_[_0x171860('0x34')](_0x280b53[_0x171860('0x7')]),_0x58f48a['filters']=_['intersection'](_0x58f48a[_0x171860('0x0')],_0x58f48a['query']),_0x2605f9[_0x171860('0x2f')]=_['intersection'](_0x58f48a['model'],qs[_0x171860('0x2')](_0x280b53[_0x171860('0x7')][_0x171860('0x2')])),_0x2605f9[_0x171860('0x2f')]=_0x2605f9[_0x171860('0x2f')]['length']?_0x2605f9['attributes']:_0x58f48a[_0x171860('0x0')];typeof _0x280b53[_0x171860('0x7')][_0x171860('0xc')]===_0x171860('0x2b')&&(_0x2605f9[_0x171860('0x39')]=qs[_0x171860('0x39')](_0x280b53[_0x171860('0x7')][_0x171860('0x39')]),_0x2605f9[_0x171860('0x25')]=qs['offset'](_0x280b53[_0x171860('0x7')]['offset']));_0x2605f9[_0x171860('0x14')]=qs['sort'](_0x280b53[_0x171860('0x7')][_0x171860('0x36')]),_0x2605f9[_0x171860('0x37')]=qs[_0x171860('0x26')](_[_0x171860('0xa')](_0x280b53[_0x171860('0x7')],_0x58f48a[_0x171860('0x26')]),_0x348e8a);_0x280b53['query'][_0x171860('0x3f')]&&(_0x2605f9['where']=_[_0x171860('0x1e')](_0x2605f9['where'],{[Op['or']]:_[_0x171860('0x35')](_0x348e8a,function(_0x5b0575){const _0x116d9f=_0x171860;if(_0x5b0575[_0x116d9f('0xd')]!=='VIRTUAL'){const _0x414fa9={};return _0x414fa9[_0x5b0575[_0x116d9f('0x8')]]={[Op[_0x116d9f('0x17')]]:'%'+_0x280b53[_0x116d9f('0x7')][_0x116d9f('0x3f')]+'%'},_0x414fa9;}})}));_0x2605f9=_[_0x171860('0x1e')]({},_0x2605f9,_0x280b53[_0x171860('0x6')]);const _0x3d5ff5={'where':_0x2605f9[_0x171860('0x37')]};return db['Trigger']['count'](_0x3d5ff5)[_0x171860('0x29')](function(_0x2e0260){const _0x3d35a7=_0x171860;return _0x5824b2['count']=_0x2e0260,_0x280b53[_0x3d35a7('0x7')][_0x3d35a7('0x1a')]&&(_0x2605f9[_0x3d35a7('0xe')]=[{'all':!![]}]),db['Trigger'][_0x3d35a7('0x3b')](_0x2605f9);})[_0x171860('0x29')](function(_0x5143b7){return _0x5824b2['rows']=_0x5143b7,_0x5824b2;})[_0x171860('0x29')](respondWithFilteredResult(_0x6584e8,_0x2605f9))[_0x171860('0x16')](handleError(_0x6584e8,null));},exports[_0x271fc7('0x41')]=function(_0x22790d,_0x5c3bcd){const _0x21caa0=_0x271fc7;let _0x2f5fd5={'raw':![],'where':{'id':_0x22790d[_0x21caa0('0x21')]['id']}};const _0x2e6b2d={};return _0x2e6b2d[_0x21caa0('0x0')]=_[_0x21caa0('0x34')](db[_0x21caa0('0x18')][_0x21caa0('0x33')]),_0x2e6b2d[_0x21caa0('0x7')]=_['keys'](_0x22790d[_0x21caa0('0x7')]),_0x2e6b2d[_0x21caa0('0x26')]=_[_0x21caa0('0x22')](_0x2e6b2d['model'],_0x2e6b2d[_0x21caa0('0x7')]),_0x2f5fd5[_0x21caa0('0x2f')]=_[_0x21caa0('0x22')](_0x2e6b2d['model'],qs['fields'](_0x22790d['query'][_0x21caa0('0x2')])),_0x2f5fd5[_0x21caa0('0x2f')]=_0x2f5fd5['attributes']['length']?_0x2f5fd5[_0x21caa0('0x2f')]:_0x2e6b2d[_0x21caa0('0x0')],_0x22790d[_0x21caa0('0x7')]['includeAll']&&(_0x2f5fd5[_0x21caa0('0xe')]=[{'all':!![]}]),_0x2f5fd5=_[_0x21caa0('0x1e')]({},_0x2f5fd5,_0x22790d[_0x21caa0('0x6')]),db['Trigger'][_0x21caa0('0x28')](_0x2f5fd5)['then'](handleEntityNotFound(_0x5c3bcd,null))[_0x21caa0('0x29')](respondWithResult(_0x5c3bcd,null))[_0x21caa0('0x16')](handleError(_0x5c3bcd,null));},exports['create']=function(_0x1de65e,_0x44bcaf){const _0x4ac4c0=_0x271fc7;return db['Trigger'][_0x4ac4c0('0x13')](_0x1de65e[_0x4ac4c0('0x23')],{})[_0x4ac4c0('0x29')](function(_0xddb076){const _0x210698=_0x4ac4c0,_0x488f33=_0x1de65e['user'][_0x210698('0x2c')]({'plain':!![]});if(!_0x488f33)throw new Error(_0x210698('0x32'));if(_0x488f33[_0x210698('0x10')]===_0x210698('0x2e')){const _0x5530a1=_0xddb076[_0x210698('0x2c')]({'plain':!![]}),_0x1bca47=_0x210698('0x5');return db[_0x210698('0x38')][_0x210698('0x28')]({'where':{'name':_0x1bca47,'userProfileId':_0x488f33[_0x210698('0x4')]},'raw':!![]})[_0x210698('0x29')](function(_0x2f7fb1){const _0x3488d5=_0x210698;return _0x2f7fb1&&_0x2f7fb1['autoAssociation']===0x0?db['UserProfileResource'][_0x3488d5('0x13')]({'name':_0x5530a1[_0x3488d5('0x8')],'resourceId':_0x5530a1['id'],'type':_0x2f7fb1[_0x3488d5('0x8')],'sectionId':_0x2f7fb1['id']},{})[_0x3488d5('0x29')](function(){return _0xddb076;}):_0xddb076;})[_0x210698('0x16')](function(_0x1a021e){const _0x1f23e6=_0x210698;logger[_0x1f23e6('0x12')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x1a021e);throw _0x1a021e;});}return _0xddb076;})['then'](respondWithResult(_0x44bcaf,0xc9))[_0x4ac4c0('0x16')](handleError(_0x44bcaf,null));},exports[_0x271fc7('0x19')]=function(_0x209789,_0x1be1b1){const _0x41a459=_0x271fc7;return _0x209789['body']['id']&&delete _0x209789[_0x41a459('0x23')]['id'],db[_0x41a459('0x18')][_0x41a459('0x28')]({'where':{'id':_0x209789[_0x41a459('0x21')]['id']}})['then'](handleEntityNotFound(_0x1be1b1,null))[_0x41a459('0x29')](saveUpdates(_0x209789['body'],null))[_0x41a459('0x29')](respondWithResult(_0x1be1b1,null))[_0x41a459('0x16')](handleError(_0x1be1b1,null));},exports[_0x271fc7('0x2d')]=function(_0x32453f,_0xa0f3b6){const _0x221022=_0x271fc7;return db[_0x221022('0x18')]['findOne']({'where':{'id':_0x32453f['params']['id']}})[_0x221022('0x29')](handleEntityNotFound(_0xa0f3b6,null))[_0x221022('0x29')](removeEntity(_0xa0f3b6,null))[_0x221022('0x16')](handleError(_0xa0f3b6,null));},exports[_0x271fc7('0x3a')]=function(_0x48f5c2,_0x27ad59){const _0x57139f=_0x271fc7;return _0x48f5c2['body']['id']&&delete _0x48f5c2[_0x57139f('0x23')]['id'],db[_0x57139f('0x18')]['findOne']({'where':{'id':_0x48f5c2[_0x57139f('0x21')]['id']}})['then'](handleEntityNotFound(_0x27ad59,null))[_0x57139f('0x29')](function(_0xa77317){const _0x376442=_0x57139f;if(_0xa77317)return _0x48f5c2['body'][_0x376442('0x2a')]=_0xa77317['id'],db[_0x376442('0xb')][_0x376442('0x13')](_0x48f5c2[_0x376442('0x23')]);})[_0x57139f('0x29')](respondWithResult(_0x27ad59,null))[_0x57139f('0x16')](handleError(_0x27ad59,null));},exports[_0x271fc7('0x20')]=function(_0x29ebd4,_0x1bf6c3){const _0x2b68ed=_0x271fc7;return _0x29ebd4[_0x2b68ed('0x23')]['id']&&delete _0x29ebd4[_0x2b68ed('0x23')]['id'],db[_0x2b68ed('0x18')][_0x2b68ed('0x28')]({'where':{'id':_0x29ebd4['params']['id']}})['then'](handleEntityNotFound(_0x1bf6c3,null))[_0x2b68ed('0x29')](function(_0x21c20f){const _0x117e14=_0x2b68ed;if(_0x21c20f)return _0x29ebd4['body']['TriggerAnyId']=_0x21c20f['id'],db[_0x117e14('0xb')][_0x117e14('0x13')](_0x29ebd4['body']);})['then'](respondWithResult(_0x1bf6c3,null))['catch'](handleError(_0x1bf6c3,null));},exports['getAllConditions']=function(_0x48b2eb,_0x52bb2b){const _0x244158=_0x271fc7;let _0x224543={};const _0x982ef2={};let _0x2cd681,_0x452f5e;return db[_0x244158('0x18')]['findOne']({'where':{'id':_0x48b2eb[_0x244158('0x21')]['id']}})[_0x244158('0x29')](handleEntityNotFound(_0x52bb2b,null))[_0x244158('0x29')](function(_0xae63f1){const _0x636a4b=_0x244158;if(_0xae63f1)return _0x2cd681=_0xae63f1,_0x982ef2[_0x636a4b('0x0')]=_[_0x636a4b('0x34')](db[_0x636a4b('0xb')][_0x636a4b('0x33')]),_0x982ef2[_0x636a4b('0x7')]=_['keys'](_0x48b2eb[_0x636a4b('0x7')]),_0x982ef2[_0x636a4b('0x26')]=_['intersection'](_0x982ef2['model'],_0x982ef2[_0x636a4b('0x7')]),_0x224543[_0x636a4b('0x2f')]=_[_0x636a4b('0x22')](_0x982ef2[_0x636a4b('0x0')],qs[_0x636a4b('0x2')](_0x48b2eb['query'][_0x636a4b('0x2')])),_0x224543[_0x636a4b('0x2f')]=_0x224543[_0x636a4b('0x2f')][_0x636a4b('0xf')]?_0x224543['attributes']:_0x982ef2[_0x636a4b('0x0')],_0x224543[_0x636a4b('0x14')]=qs[_0x636a4b('0x36')](_0x48b2eb[_0x636a4b('0x7')][_0x636a4b('0x36')]),_0x224543['where']=qs['filters'](_[_0x636a4b('0xa')](_0x48b2eb[_0x636a4b('0x7')],_0x982ef2[_0x636a4b('0x26')])),_0x48b2eb[_0x636a4b('0x7')][_0x636a4b('0x3f')]&&(_0x224543['where']=_[_0x636a4b('0x1e')](_0x224543['where'],{[Op['or']]:_[_0x636a4b('0x35')](_0x224543[_0x636a4b('0x2f')],function(_0xe5d0ee){const _0x492622=_0x636a4b,_0x3e50fd={};return _0x3e50fd[_0xe5d0ee]={[Op['like']]:'%'+_0x48b2eb[_0x492622('0x7')][_0x492622('0x3f')]+'%'},_0x3e50fd;})})),_0x224543=_['merge']({},_0x224543,_0x48b2eb[_0x636a4b('0x6')]),_0x2cd681[_0x636a4b('0x9')](_0x224543);})[_0x244158('0x29')](function(_0x3e1f14){const _0x21768d=_0x244158;if(_0x3e1f14)return _0x452f5e=_0x3e1f14['length'],typeof _0x48b2eb[_0x21768d('0x7')][_0x21768d('0xc')]==='undefined'&&(_0x224543[_0x21768d('0x39')]=qs[_0x21768d('0x39')](_0x48b2eb[_0x21768d('0x7')][_0x21768d('0x39')]),_0x224543['offset']=qs[_0x21768d('0x25')](_0x48b2eb[_0x21768d('0x7')][_0x21768d('0x25')])),_0x2cd681[_0x21768d('0x9')](_0x224543);})[_0x244158('0x29')](function(_0x4b8377){if(_0x4b8377)return _0x4b8377?{'count':_0x452f5e,'rows':_0x4b8377}:null;})[_0x244158('0x29')](respondWithResult(_0x52bb2b,null))[_0x244158('0x16')](handleError(_0x52bb2b,null));},exports[_0x271fc7('0x31')]=function(_0x57af3a,_0x347053){const _0x375075=_0x271fc7;let _0x2571c6={};const _0x30dc37={};let _0x127429,_0x5d5381;return db[_0x375075('0x18')]['findOne']({'where':{'id':_0x57af3a[_0x375075('0x21')]['id']}})['then'](handleEntityNotFound(_0x347053,null))[_0x375075('0x29')](function(_0x4eab56){const _0xbb8a49=_0x375075;if(_0x4eab56)return _0x127429=_0x4eab56,_0x30dc37[_0xbb8a49('0x0')]=_[_0xbb8a49('0x34')](db['Condition'][_0xbb8a49('0x33')]),_0x30dc37['query']=_[_0xbb8a49('0x34')](_0x57af3a['query']),_0x30dc37[_0xbb8a49('0x26')]=_[_0xbb8a49('0x22')](_0x30dc37[_0xbb8a49('0x0')],_0x30dc37[_0xbb8a49('0x7')]),_0x2571c6[_0xbb8a49('0x2f')]=_[_0xbb8a49('0x22')](_0x30dc37[_0xbb8a49('0x0')],qs[_0xbb8a49('0x2')](_0x57af3a['query']['fields'])),_0x2571c6[_0xbb8a49('0x2f')]=_0x2571c6[_0xbb8a49('0x2f')]['length']?_0x2571c6['attributes']:_0x30dc37[_0xbb8a49('0x0')],_0x2571c6['order']=qs[_0xbb8a49('0x36')](_0x57af3a['query'][_0xbb8a49('0x36')]),_0x2571c6['where']=qs[_0xbb8a49('0x26')](_[_0xbb8a49('0xa')](_0x57af3a[_0xbb8a49('0x7')],_0x30dc37[_0xbb8a49('0x26')])),_0x57af3a[_0xbb8a49('0x7')][_0xbb8a49('0x3f')]&&(_0x2571c6[_0xbb8a49('0x37')]=_['merge'](_0x2571c6['where'],{[Op['or']]:_[_0xbb8a49('0x35')](_0x2571c6[_0xbb8a49('0x2f')],function(_0x2a4fa8){const _0x1ed5c0=_0xbb8a49,_0x2ae97c={};return _0x2ae97c[_0x2a4fa8]={[Op['like']]:'%'+_0x57af3a[_0x1ed5c0('0x7')][_0x1ed5c0('0x3f')]+'%'},_0x2ae97c;})})),_0x2571c6=_[_0xbb8a49('0x1e')]({},_0x2571c6,_0x57af3a[_0xbb8a49('0x6')]),_0x127429[_0xbb8a49('0x31')](_0x2571c6);})[_0x375075('0x29')](function(_0x56fc4f){const _0x515bf3=_0x375075;if(_0x56fc4f)return _0x5d5381=_0x56fc4f['length'],typeof _0x57af3a['query'][_0x515bf3('0xc')]==='undefined'&&(_0x2571c6[_0x515bf3('0x39')]=qs[_0x515bf3('0x39')](_0x57af3a[_0x515bf3('0x7')][_0x515bf3('0x39')]),_0x2571c6[_0x515bf3('0x25')]=qs[_0x515bf3('0x25')](_0x57af3a['query'][_0x515bf3('0x25')])),_0x127429[_0x515bf3('0x31')](_0x2571c6);})[_0x375075('0x29')](function(_0x6659fb){if(_0x6659fb)return _0x6659fb?{'count':_0x5d5381,'rows':_0x6659fb}:null;})[_0x375075('0x29')](respondWithResult(_0x347053,null))[_0x375075('0x16')](handleError(_0x347053,null));},exports['addAction']=function(_0x321082,_0x700bb0){const _0x358fd9=_0x271fc7;return _0x321082[_0x358fd9('0x23')]['id']&&delete _0x321082[_0x358fd9('0x23')]['id'],db[_0x358fd9('0x18')][_0x358fd9('0x28')]({'where':{'id':_0x321082[_0x358fd9('0x21')]['id']}})['then'](handleEntityNotFound(_0x700bb0,null))[_0x358fd9('0x29')](function(_0x4f726f){const _0x14b134=_0x358fd9;if(_0x4f726f)return _0x321082['body'][_0x14b134('0x1d')]=_0x4f726f['id'],db['Action']['create'](_0x321082[_0x14b134('0x23')]);})[_0x358fd9('0x29')](respondWithResult(_0x700bb0,null))[_0x358fd9('0x16')](handleError(_0x700bb0,null));},exports[_0x271fc7('0x27')]=function(_0x44816e,_0x461232){const _0x17dd44=_0x271fc7;let _0x1f6198={};const _0x30b828={};let _0x10f3da,_0x38579f;return db['Trigger'][_0x17dd44('0x28')]({'where':{'id':_0x44816e[_0x17dd44('0x21')]['id']}})[_0x17dd44('0x29')](handleEntityNotFound(_0x461232,null))[_0x17dd44('0x29')](function(_0x2e9b44){const _0x4259fc=_0x17dd44;if(_0x2e9b44)return _0x10f3da=_0x2e9b44,_0x30b828['model']=_[_0x4259fc('0x34')](db[_0x4259fc('0x1')][_0x4259fc('0x33')]),_0x30b828['query']=_[_0x4259fc('0x34')](_0x44816e[_0x4259fc('0x7')]),_0x30b828[_0x4259fc('0x26')]=_[_0x4259fc('0x22')](_0x30b828[_0x4259fc('0x0')],_0x30b828[_0x4259fc('0x7')]),_0x1f6198[_0x4259fc('0x2f')]=_[_0x4259fc('0x22')](_0x30b828[_0x4259fc('0x0')],qs[_0x4259fc('0x2')](_0x44816e[_0x4259fc('0x7')]['fields'])),_0x1f6198[_0x4259fc('0x2f')]=_0x1f6198[_0x4259fc('0x2f')][_0x4259fc('0xf')]?_0x1f6198[_0x4259fc('0x2f')]:_0x30b828[_0x4259fc('0x0')],_0x1f6198['order']=qs[_0x4259fc('0x36')](_0x44816e[_0x4259fc('0x7')][_0x4259fc('0x36')]),_0x1f6198[_0x4259fc('0x37')]=qs[_0x4259fc('0x26')](_[_0x4259fc('0xa')](_0x44816e['query'],_0x30b828['filters'])),_0x44816e[_0x4259fc('0x7')][_0x4259fc('0x3f')]&&(_0x1f6198['where']=_[_0x4259fc('0x1e')](_0x1f6198[_0x4259fc('0x37')],{[Op['or']]:_[_0x4259fc('0x35')](_0x1f6198[_0x4259fc('0x2f')],function(_0x54e128){const _0x1b1600=_0x4259fc,_0x5c607a={};return _0x5c607a[_0x54e128]={[Op[_0x1b1600('0x17')]]:'%'+_0x44816e[_0x1b1600('0x7')][_0x1b1600('0x3f')]+'%'},_0x5c607a;})})),_0x1f6198=_[_0x4259fc('0x1e')]({},_0x1f6198,_0x44816e[_0x4259fc('0x6')]),_0x10f3da[_0x4259fc('0x27')](_0x1f6198);})[_0x17dd44('0x29')](function(_0xa3a8c7){const _0x17eae8=_0x17dd44;if(_0xa3a8c7)return _0x38579f=_0xa3a8c7[_0x17eae8('0xf')],typeof _0x44816e[_0x17eae8('0x7')][_0x17eae8('0xc')]==='undefined'&&(_0x1f6198['limit']=qs[_0x17eae8('0x39')](_0x44816e['query'][_0x17eae8('0x39')]),_0x1f6198[_0x17eae8('0x25')]=qs['offset'](_0x44816e['query']['offset'])),_0x10f3da[_0x17eae8('0x27')](_0x1f6198);})['then'](function(_0x9ddb48){if(_0x9ddb48)return _0x9ddb48?{'count':_0x38579f,'rows':_0x9ddb48}:null;})[_0x17dd44('0x29')](respondWithResult(_0x461232,null))['catch'](handleError(_0x461232,null));}; \ No newline at end of file diff --git a/server/api/trigger/trigger.model.js b/server/api/trigger/trigger.model.js index 2b481b4..f7d37b2 100644 --- a/server/api/trigger/trigger.model.js +++ b/server/api/trigger/trigger.model.js @@ -1 +1 @@ -const a639_0x4fdb=['Trigger','define','exports','./trigger.attributes','tools_triggers'];(function(_0x1c8201,_0x4fdbba){const _0x1b72fe=function(_0x19e44b){while(--_0x19e44b){_0x1c8201['push'](_0x1c8201['shift']());}};_0x1b72fe(++_0x4fdbba);}(a639_0x4fdb,0x190));const a639_0x1b72=function(_0x1c8201,_0x4fdbba){_0x1c8201=_0x1c8201-0x0;let _0x1b72fe=a639_0x4fdb[_0x1c8201];return _0x1b72fe;};const _0x4c360e=a639_0x1b72;'use strict';const attributes=require(_0x4c360e('0x3'));module[_0x4c360e('0x2')]=function(_0x19e44b){const _0x2d5922=_0x4c360e,_0xcda43d=_0x19e44b[_0x2d5922('0x1')](_0x2d5922('0x0'),attributes,{'tableName':_0x2d5922('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xcda43d;}; \ No newline at end of file +const a639_0x520b=['Trigger','exports','define','./trigger.attributes'];(function(_0x2b4383,_0x520b7a){const _0x1f935a=function(_0x2fa288){while(--_0x2fa288){_0x2b4383['push'](_0x2b4383['shift']());}};_0x1f935a(++_0x520b7a);}(a639_0x520b,0x14c));const a639_0x1f93=function(_0x2b4383,_0x520b7a){_0x2b4383=_0x2b4383-0x0;let _0x1f935a=a639_0x520b[_0x2b4383];return _0x1f935a;};const _0x714fea=a639_0x1f93;'use strict';const attributes=require(_0x714fea('0x3'));module[_0x714fea('0x1')]=function(_0x2fa288){const _0x51957f=_0x714fea,_0x44f235=_0x2fa288[_0x51957f('0x2')](_0x51957f('0x0'),attributes,{'tableName':'tools_triggers','paranoid':![],'indexes':[],'timestamps':!![]});return _0x44f235;}; \ No newline at end of file diff --git a/server/api/trigger/trigger.rpc.js b/server/api/trigger/trigger.rpc.js index c564488..6e63d3e 100644 --- a/server/api/trigger/trigger.rpc.js +++ b/server/api/trigger/trigger.rpc.js @@ -1 +1 @@ -const a640_0x476e=['model','map','message','rpc','where','options','GetTrigger','stringify','../../mysqldb','catch','then','findAll','lodash','attributes','include','info','error','../../config/logger','Trigger','ShowTrigger','debug','raw'];(function(_0xd9147a,_0x476e81){const _0x405b3c=function(_0x182fda){while(--_0x182fda){_0xd9147a['push'](_0xd9147a['shift']());}};_0x405b3c(++_0x476e81);}(a640_0x476e,0x154));const a640_0x405b=function(_0xd9147a,_0x476e81){_0xd9147a=_0xd9147a-0x0;let _0x405b3c=a640_0x476e[_0xd9147a];return _0x405b3c;};const _0x244e3c=a640_0x405b;'use strict';const _=require(_0x244e3c('0x2')),db=require(_0x244e3c('0x14'))['db'],logger=require(_0x244e3c('0x7'))(_0x244e3c('0xf'));exports[_0x244e3c('0x12')]=function(_0x182fda){const _0x2bd3e1=this;return new Promise(function(_0x17d8d6,_0xd6e21b){const _0x1290a9=a640_0x405b;return db[_0x1290a9('0x8')][_0x1290a9('0x1')]({'raw':_0x182fda[_0x1290a9('0x11')]?_0x182fda[_0x1290a9('0x11')][_0x1290a9('0xb')]===undefined?!![]:![]:!![],'where':_0x182fda[_0x1290a9('0x11')]?_0x182fda[_0x1290a9('0x11')][_0x1290a9('0x10')]||null:null,'attributes':_0x182fda[_0x1290a9('0x11')]?_0x182fda[_0x1290a9('0x11')]['attributes']||null:null,'limit':_0x182fda[_0x1290a9('0x11')]?_0x182fda[_0x1290a9('0x11')]['limit']||null:null,'include':_0x182fda[_0x1290a9('0x11')]?_0x182fda['options'][_0x1290a9('0x4')]?_[_0x1290a9('0xd')](_0x182fda[_0x1290a9('0x11')][_0x1290a9('0x4')],function(_0x639d31){const _0x217a92=_0x1290a9;return{'model':db[_0x639d31['model']],'as':_0x639d31['as'],'attributes':_0x639d31['attributes'],'include':_0x639d31[_0x217a92('0x4')]?_[_0x217a92('0xd')](_0x639d31[_0x217a92('0x4')],function(_0x30155c){const _0x44013b=_0x217a92;return{'model':db[_0x30155c[_0x44013b('0xc')]],'as':_0x30155c['as'],'attributes':_0x30155c[_0x44013b('0x3')],'include':_0x30155c['include']?_[_0x44013b('0xd')](_0x30155c[_0x44013b('0x4')],function(_0x46fb73){const _0x4712c8=_0x44013b;return{'model':db[_0x46fb73[_0x4712c8('0xc')]],'as':_0x46fb73['as'],'attributes':_0x46fb73['attributes']};}):[]};}):[]};}):[]:[]})[_0x1290a9('0x0')](function(_0x10148f){const _0x3f0b7a=_0x1290a9;logger[_0x3f0b7a('0x5')]('GetTrigger',_0x182fda),logger[_0x3f0b7a('0xa')](_0x3f0b7a('0x12'),_0x182fda,JSON['stringify'](_0x10148f)),_0x17d8d6(_0x10148f);})[_0x1290a9('0x15')](function(_0x48bc19){const _0xcc9f4d=_0x1290a9;logger[_0xcc9f4d('0x6')](_0xcc9f4d('0x12'),_0x48bc19['message'],_0x182fda),_0xd6e21b(_0x2bd3e1[_0xcc9f4d('0x6')](0x1f4,_0x48bc19[_0xcc9f4d('0xe')]));});});},exports[_0x244e3c('0x9')]=function(_0x167eb1){const _0x3315be=this;return new Promise(function(_0x37fcde,_0x45af2c){const _0x1258bc=a640_0x405b;return db[_0x1258bc('0x8')]['findOne']({'raw':_0x167eb1['options']?_0x167eb1[_0x1258bc('0x11')][_0x1258bc('0xb')]===undefined?!![]:![]:!![],'where':_0x167eb1['options']?_0x167eb1[_0x1258bc('0x11')][_0x1258bc('0x10')]||null:null,'attributes':_0x167eb1[_0x1258bc('0x11')]?_0x167eb1['options'][_0x1258bc('0x3')]||null:null,'include':_0x167eb1[_0x1258bc('0x11')]?_0x167eb1['options'][_0x1258bc('0x4')]?_['map'](_0x167eb1[_0x1258bc('0x11')][_0x1258bc('0x4')],function(_0x47448b){const _0x2c5831=_0x1258bc;return{'model':db[_0x47448b[_0x2c5831('0xc')]],'as':_0x47448b['as'],'attributes':_0x47448b[_0x2c5831('0x3')],'include':_0x47448b[_0x2c5831('0x4')]?_[_0x2c5831('0xd')](_0x47448b[_0x2c5831('0x4')],function(_0x4bdafa){const _0x4e4843=_0x2c5831;return{'model':db[_0x4bdafa[_0x4e4843('0xc')]],'as':_0x4bdafa['as'],'attributes':_0x4bdafa['attributes'],'include':_0x4bdafa[_0x4e4843('0x4')]?_[_0x4e4843('0xd')](_0x4bdafa[_0x4e4843('0x4')],function(_0x1daa89){const _0x272f54=_0x4e4843;return{'model':db[_0x1daa89['model']],'as':_0x1daa89['as'],'attributes':_0x1daa89[_0x272f54('0x3')]};}):[]};}):[]};}):[]:[]})[_0x1258bc('0x0')](function(_0x578a0b){const _0xe2e0f0=_0x1258bc;logger[_0xe2e0f0('0x5')](_0xe2e0f0('0x9'),_0x167eb1),logger[_0xe2e0f0('0xa')](_0xe2e0f0('0x9'),_0x167eb1,JSON[_0xe2e0f0('0x13')](_0x578a0b)),_0x37fcde(_0x578a0b);})[_0x1258bc('0x15')](function(_0x4f8f49){const _0x5eeac8=_0x1258bc;logger[_0x5eeac8('0x6')](_0x5eeac8('0x9'),_0x4f8f49['message'],_0x167eb1),_0x45af2c(_0x3315be[_0x5eeac8('0x6')](0x1f4,_0x4f8f49[_0x5eeac8('0xe')]));});});}; \ No newline at end of file +const a640_0x16f3=['GetTrigger','then','error','map','Trigger','rpc','findOne','attributes','options','info','lodash','include','catch','model','stringify','debug','raw','ShowTrigger','where','findAll','message'];(function(_0x3b3dd7,_0x16f330){const _0x25da37=function(_0x61b660){while(--_0x61b660){_0x3b3dd7['push'](_0x3b3dd7['shift']());}};_0x25da37(++_0x16f330);}(a640_0x16f3,0x1c3));const a640_0x25da=function(_0x3b3dd7,_0x16f330){_0x3b3dd7=_0x3b3dd7-0x0;let _0x25da37=a640_0x16f3[_0x3b3dd7];return _0x25da37;};const _0x433306=a640_0x25da;'use strict';const _=require(_0x433306('0x0')),db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x433306('0x10'));exports[_0x433306('0xb')]=function(_0x61b660){const _0xda334d=this;return new Promise(function(_0x2ae24a,_0x57c456){const _0x56350a=a640_0x25da;return db[_0x56350a('0xf')][_0x56350a('0x9')]({'raw':_0x61b660['options']?_0x61b660[_0x56350a('0x13')][_0x56350a('0x6')]===undefined?!![]:![]:!![],'where':_0x61b660[_0x56350a('0x13')]?_0x61b660[_0x56350a('0x13')][_0x56350a('0x8')]||null:null,'attributes':_0x61b660[_0x56350a('0x13')]?_0x61b660[_0x56350a('0x13')]['attributes']||null:null,'limit':_0x61b660[_0x56350a('0x13')]?_0x61b660[_0x56350a('0x13')]['limit']||null:null,'include':_0x61b660[_0x56350a('0x13')]?_0x61b660[_0x56350a('0x13')]['include']?_[_0x56350a('0xe')](_0x61b660[_0x56350a('0x13')]['include'],function(_0x31c205){const _0x3ae15e=_0x56350a;return{'model':db[_0x31c205[_0x3ae15e('0x3')]],'as':_0x31c205['as'],'attributes':_0x31c205['attributes'],'include':_0x31c205[_0x3ae15e('0x1')]?_[_0x3ae15e('0xe')](_0x31c205[_0x3ae15e('0x1')],function(_0xe58bea){const _0x5504c7=_0x3ae15e;return{'model':db[_0xe58bea[_0x5504c7('0x3')]],'as':_0xe58bea['as'],'attributes':_0xe58bea[_0x5504c7('0x12')],'include':_0xe58bea['include']?_[_0x5504c7('0xe')](_0xe58bea['include'],function(_0x5e577f){const _0x321b48=_0x5504c7;return{'model':db[_0x5e577f[_0x321b48('0x3')]],'as':_0x5e577f['as'],'attributes':_0x5e577f[_0x321b48('0x12')]};}):[]};}):[]};}):[]:[]})[_0x56350a('0xc')](function(_0x5c674c){const _0x140be9=_0x56350a;logger[_0x140be9('0x14')](_0x140be9('0xb'),_0x61b660),logger[_0x140be9('0x5')]('GetTrigger',_0x61b660,JSON['stringify'](_0x5c674c)),_0x2ae24a(_0x5c674c);})[_0x56350a('0x2')](function(_0x45132e){const _0x4afc92=_0x56350a;logger['error'](_0x4afc92('0xb'),_0x45132e['message'],_0x61b660),_0x57c456(_0xda334d[_0x4afc92('0xd')](0x1f4,_0x45132e[_0x4afc92('0xa')]));});});},exports['ShowTrigger']=function(_0x280296){const _0x21fce5=this;return new Promise(function(_0x4078e6,_0x15a56d){const _0x1637ec=a640_0x25da;return db['Trigger'][_0x1637ec('0x11')]({'raw':_0x280296[_0x1637ec('0x13')]?_0x280296[_0x1637ec('0x13')][_0x1637ec('0x6')]===undefined?!![]:![]:!![],'where':_0x280296[_0x1637ec('0x13')]?_0x280296['options'][_0x1637ec('0x8')]||null:null,'attributes':_0x280296[_0x1637ec('0x13')]?_0x280296['options'][_0x1637ec('0x12')]||null:null,'include':_0x280296[_0x1637ec('0x13')]?_0x280296['options'][_0x1637ec('0x1')]?_[_0x1637ec('0xe')](_0x280296[_0x1637ec('0x13')][_0x1637ec('0x1')],function(_0x8dafdf){const _0x1ace3c=_0x1637ec;return{'model':db[_0x8dafdf[_0x1ace3c('0x3')]],'as':_0x8dafdf['as'],'attributes':_0x8dafdf[_0x1ace3c('0x12')],'include':_0x8dafdf[_0x1ace3c('0x1')]?_[_0x1ace3c('0xe')](_0x8dafdf[_0x1ace3c('0x1')],function(_0x41689b){const _0x3548dd=_0x1ace3c;return{'model':db[_0x41689b[_0x3548dd('0x3')]],'as':_0x41689b['as'],'attributes':_0x41689b[_0x3548dd('0x12')],'include':_0x41689b[_0x3548dd('0x1')]?_[_0x3548dd('0xe')](_0x41689b[_0x3548dd('0x1')],function(_0x5b8407){const _0xbbb5de=_0x3548dd;return{'model':db[_0x5b8407['model']],'as':_0x5b8407['as'],'attributes':_0x5b8407[_0xbbb5de('0x12')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x4da3aa){const _0x55462a=_0x1637ec;logger['info']('ShowTrigger',_0x280296),logger['debug'](_0x55462a('0x7'),_0x280296,JSON[_0x55462a('0x4')](_0x4da3aa)),_0x4078e6(_0x4da3aa);})[_0x1637ec('0x2')](function(_0x321810){const _0x179380=_0x1637ec;logger['error'](_0x179380('0x7'),_0x321810[_0x179380('0xa')],_0x280296),_0x15a56d(_0x21fce5[_0x179380('0xd')](0x1f4,_0x321810[_0x179380('0xa')]));});});}; \ No newline at end of file diff --git a/server/api/trunk/index.js b/server/api/trunk/index.js index b673167..14d5607 100644 --- a/server/api/trunk/index.js +++ b/server/api/trunk/index.js @@ -1 +1 @@ -const a641_0x3953=['get','/:id','../../components/auth/service','Router','update','exports','express','index','isAuthenticated','destroy','/:id/clone','clone','./trunk.controller','create','show','post','put'];(function(_0x2f7281,_0x3953f0){const _0x4186e3=function(_0x42888b){while(--_0x42888b){_0x2f7281['push'](_0x2f7281['shift']());}};_0x4186e3(++_0x3953f0);}(a641_0x3953,0x1d8));const a641_0x4186=function(_0x2f7281,_0x3953f0){_0x2f7281=_0x2f7281-0x0;let _0x4186e3=a641_0x3953[_0x2f7281];return _0x4186e3;};const _0x23f3f3=a641_0x4186;'use strict';const express=require(_0x23f3f3('0xa')),router=express[_0x23f3f3('0x7')](),auth=require(_0x23f3f3('0x6')),controller=require(_0x23f3f3('0x10'));router[_0x23f3f3('0x4')]('/',auth[_0x23f3f3('0xc')](),controller[_0x23f3f3('0xb')]),router['get']('/:id',auth[_0x23f3f3('0xc')](),controller[_0x23f3f3('0x1')]),router[_0x23f3f3('0x2')](_0x23f3f3('0xe'),auth[_0x23f3f3('0xc')](),controller[_0x23f3f3('0xf')]),router[_0x23f3f3('0x2')]('/',auth[_0x23f3f3('0xc')](),controller[_0x23f3f3('0x0')]),router[_0x23f3f3('0x3')](_0x23f3f3('0x5'),auth['isAuthenticated'](),controller[_0x23f3f3('0x8')]),router['delete']('/:id',auth['isAuthenticated'](),controller[_0x23f3f3('0xd')]),module[_0x23f3f3('0x9')]=router; \ No newline at end of file +const a641_0x2c7a=['/:id','/:id/clone','isAuthenticated','express','../../components/auth/service','clone','show','./trunk.controller','put','create','post','get','index'];(function(_0x585bcd,_0x2c7a8b){const _0x3bd7b9=function(_0x7b46a2){while(--_0x7b46a2){_0x585bcd['push'](_0x585bcd['shift']());}};_0x3bd7b9(++_0x2c7a8b);}(a641_0x2c7a,0x156));const a641_0x3bd7=function(_0x585bcd,_0x2c7a8b){_0x585bcd=_0x585bcd-0x0;let _0x3bd7b9=a641_0x2c7a[_0x585bcd];return _0x3bd7b9;};const _0x4d9d4e=a641_0x3bd7;'use strict';const express=require(_0x4d9d4e('0xc')),router=express['Router'](),auth=require(_0x4d9d4e('0x0')),controller=require(_0x4d9d4e('0x3'));router['get']('/',auth['isAuthenticated'](),controller[_0x4d9d4e('0x8')]),router[_0x4d9d4e('0x7')]('/:id',auth[_0x4d9d4e('0xb')](),controller[_0x4d9d4e('0x2')]),router[_0x4d9d4e('0x6')](_0x4d9d4e('0xa'),auth[_0x4d9d4e('0xb')](),controller[_0x4d9d4e('0x1')]),router['post']('/',auth[_0x4d9d4e('0xb')](),controller[_0x4d9d4e('0x5')]),router[_0x4d9d4e('0x4')](_0x4d9d4e('0x9'),auth[_0x4d9d4e('0xb')](),controller['update']),router['delete'](_0x4d9d4e('0x9'),auth[_0x4d9d4e('0xb')](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/trunk/trunk.attributes.js b/server/api/trunk/trunk.attributes.js index 5a1e19f..90bc33c 100644 --- a/server/api/trunk/trunk.attributes.js +++ b/server/api/trunk/trunk.attributes.js @@ -1 +1 @@ -const a642_0xe6be=['update','INTEGER','PROHIB_NOT_SCREENED','ALLOWED','ENUM','all','yes','allow','shortinfo','uac','exports','info','PROHIB','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22ulaw\x22,\x20\x22alaw\x22,\x20\x22alaw\x22]','nonat','getDataValue','\x22\x22\x20<>','STRING','outgoing','BOOLEAN','rfc2833','name','ulaw;alaw;gsm','originate','transport','refuse','passive','friend','always','nat','uas','insecure','setDataValue','split','join','accept','ALLOWED_FAILED_SCREEN','update,nonat','never','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22force_rport\x22,\x20\x22comedia\x22]','ALLOWED_NOT_SCREENED','PROHIB_FAILED_SCREEN','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22port\x22,\x20\x22invite\x22]','from-voip-provider','pai','ALLOWED_PASSED_SCREEN'];(function(_0x5910f9,_0xe6be18){const _0x26e405=function(_0x426375){while(--_0x426375){_0x5910f9['push'](_0x5910f9['shift']());}};_0x26e405(++_0xe6be18);}(a642_0xe6be,0xb6));const a642_0x26e4=function(_0x5910f9,_0xe6be18){_0x5910f9=_0x5910f9-0x0;let _0x26e405=a642_0xe6be[_0x5910f9];return _0x26e405;};const _0x4f39d6=a642_0x26e4;'use strict';const Sequelize=require('sequelize');module[_0x4f39d6('0xc')]={'name':{'type':Sequelize[_0x4f39d6('0x13')],'allowNull':![],'unique':_0x4f39d6('0x17'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'type':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x1d'),'user','peer'),'allowNull':![],'defaultValue':'friend'},'context':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x4f39d6('0x2d')},'callingpres':{'type':Sequelize['ENUM'](_0x4f39d6('0x2a'),_0x4f39d6('0x1'),_0x4f39d6('0x26'),_0x4f39d6('0x5'),_0x4f39d6('0x4'),'PROHIB_PASSED_SCREEN',_0x4f39d6('0x2b'),_0x4f39d6('0xe'))},'deny':{'type':Sequelize[_0x4f39d6('0x13')]},'permit':{'type':Sequelize[_0x4f39d6('0x13')]},'secret':{'type':Sequelize['STRING']},'md5secret':{'type':Sequelize['STRING']},'remotesecret':{'type':Sequelize[_0x4f39d6('0x13')]},'transport':{'type':Sequelize[_0x4f39d6('0x13')],'defaultValue':'udp','set':function(_0x426375){const _0x94a212=_0x4f39d6;this[_0x94a212('0x22')]('transport',_0x426375?_0x426375[_0x94a212('0x24')](','):null);},'get':function(){const _0x46a9fd=_0x4f39d6;return this[_0x46a9fd('0x11')](_0x46a9fd('0x1a'))?this[_0x46a9fd('0x11')](_0x46a9fd('0x1a'))[_0x46a9fd('0x23')](','):null;},'comment':'String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22udp\x22,\x20\x22tcp\x22]'},'dtmfmode':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x16'),_0x4f39d6('0xd'),_0x4f39d6('0xa'),'inband','auto'),'defaultValue':_0x4f39d6('0x16')},'directmedia':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no',_0x4f39d6('0x10'),_0x4f39d6('0x2'),_0x4f39d6('0x14')),'defaultValue':'no'},'directrtpsetup':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no'),'defaultValue':'no'},'directmediapermit':{'type':Sequelize[_0x4f39d6('0x13')]},'directmediadeny':{'type':Sequelize[_0x4f39d6('0x13')]},'nat':{'type':Sequelize['STRING'],'defaultValue':'force_rport,comedia','set':function(_0x5ed105){const _0xa1ac9=_0x4f39d6;this['setDataValue'](_0xa1ac9('0x1f'),_0x5ed105?_0x5ed105[_0xa1ac9('0x24')](','):null);},'get':function(){const _0x116020=_0x4f39d6;return this['getDataValue'](_0x116020('0x1f'))?this[_0x116020('0x11')](_0x116020('0x1f'))[_0x116020('0x23')](','):null;},'comment':_0x4f39d6('0x29')},'callgroup':{'type':Sequelize[_0x4f39d6('0x13')]},'namedcallgroup':{'type':Sequelize[_0x4f39d6('0x13')]},'pickupgroup':{'type':Sequelize[_0x4f39d6('0x13')]},'namedpickupgroup':{'type':Sequelize[_0x4f39d6('0x13')]},'language':{'type':Sequelize[_0x4f39d6('0x13')],'defaultValue':'en'},'tonezone':{'type':Sequelize[_0x4f39d6('0x13')],'allowNull':!![]},'disallow':{'type':Sequelize[_0x4f39d6('0x13')],'defaultValue':_0x4f39d6('0x7')},'allow':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x4f39d6('0x18'),'set':function(_0x387f3b){const _0x4df540=_0x4f39d6;this[_0x4df540('0x22')](_0x4df540('0x9'),_0x387f3b?_0x387f3b[_0x4df540('0x24')](';'):_0x4df540('0x18'));},'get':function(){const _0x5dfb87=_0x4f39d6;return this['getDataValue'](_0x5dfb87('0x9'))?this[_0x5dfb87('0x11')](_0x5dfb87('0x9'))[_0x5dfb87('0x23')](';'):null;},'comment':_0x4f39d6('0xf')},'autoframing':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no')},'insecure':{'type':Sequelize['STRING'],'defaultValue':'port,invite','set':function(_0x41db23){const _0x3d78be=_0x4f39d6;this[_0x3d78be('0x22')]('insecure',_0x41db23?_0x41db23['join'](','):null);},'get':function(){const _0x2a7446=_0x4f39d6;return this[_0x2a7446('0x11')](_0x2a7446('0x21'))?this[_0x2a7446('0x11')](_0x2a7446('0x21'))['split'](','):null;},'comment':_0x4f39d6('0x2c')},'trustrpid':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no'),'defaultValue':'no'},'trust_id_outbound':{'type':Sequelize['ENUM']('yes','no'),'defaultValue':'no'},'progressinband':{'type':Sequelize[_0x4f39d6('0x6')]('yes','no',_0x4f39d6('0x28'))},'promiscredir':{'type':Sequelize[_0x4f39d6('0x6')]('yes','no')},'useclientcode':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no')},'accountcode':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'setvar':{'type':Sequelize['STRING']},'callerid':{'type':Sequelize[_0x4f39d6('0x13')],'defaultValue':_0x4f39d6('0x12')},'amaflags':{'type':Sequelize[_0x4f39d6('0x13')]},'callcounter':{'type':Sequelize['ENUM'](_0x4f39d6('0x8'),'no'),'defaultValue':_0x4f39d6('0x8')},'busylevel':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'allowoverlap':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no')},'allowsubscribe':{'type':Sequelize[_0x4f39d6('0x6')]('yes','no')},'allowtransfer':{'type':Sequelize[_0x4f39d6('0x6')]('yes','no')},'ignoresdpversion':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no')},'subscribecontext':{'type':Sequelize[_0x4f39d6('0x13')]},'template':{'type':Sequelize[_0x4f39d6('0x13')]},'videosupport':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no',_0x4f39d6('0x1e')),'defaultValue':'no'},'maxcallbitrate':{'type':Sequelize['INTEGER'](0xb)},'rfc2833compensate':{'type':Sequelize['ENUM']('yes','no')},'mailbox':{'type':Sequelize['STRING']},'session_timers':{'type':Sequelize['ENUM'](_0x4f39d6('0x25'),_0x4f39d6('0x1b'),_0x4f39d6('0x19'))},'session_expires':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'session_minse':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'session_refresher':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0xb'),_0x4f39d6('0x20')),'defaultValue':_0x4f39d6('0x20')},'t38pt_usertpsource':{'type':Sequelize[_0x4f39d6('0x13')]},'regexten':{'type':Sequelize['STRING']},'fromdomain':{'type':Sequelize[_0x4f39d6('0x13')]},'fromuser':{'type':Sequelize[_0x4f39d6('0x13')]},'port':{'type':Sequelize[_0x4f39d6('0x3')](0x5)},'qualify':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no'),'defaultValue':_0x4f39d6('0x8')},'keepalive':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'defaultip':{'type':Sequelize[_0x4f39d6('0x13')]},'defaultuser':{'type':Sequelize[_0x4f39d6('0x13')]},'rtptimeout':{'type':Sequelize['INTEGER'](0xb)},'rtpholdtimeout':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'rtpkeepalive':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'sendrpid':{'type':Sequelize[_0x4f39d6('0x6')]('yes','no',_0x4f39d6('0x0')),'defaultValue':'no'},'outboundproxy':{'type':Sequelize[_0x4f39d6('0x13')]},'callbackextension':{'type':Sequelize[_0x4f39d6('0x13')]},'timert1':{'type':Sequelize['INTEGER'](0xb)},'timerb':{'type':Sequelize['INTEGER'](0xb)},'qualifyfreq':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'contactpermit':{'type':Sequelize[_0x4f39d6('0x13')]},'contactdeny':{'type':Sequelize[_0x4f39d6('0x13')]},'contactacl':{'type':Sequelize[_0x4f39d6('0x13')]},'unsolicited_mailbox':{'type':Sequelize[_0x4f39d6('0x13')]},'use_q850_reason':{'type':Sequelize[_0x4f39d6('0x13')]},'maxforwards':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'encryption':{'type':Sequelize['ENUM']('yes','no'),'defaultValue':'no'},'avpf':{'type':Sequelize[_0x4f39d6('0x6')]('yes','no')},'force_avp':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no')},'icesupport':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no')},'dtlsenable':{'type':Sequelize['ENUM'](_0x4f39d6('0x8'),'no')},'dtlsverify':{'type':Sequelize['ENUM'](_0x4f39d6('0x8'),'no','fingerprint','certificate')},'dtlsrekey':{'type':Sequelize[_0x4f39d6('0x3')](0xb)},'dtlscertfile':{'type':Sequelize[_0x4f39d6('0x13')]},'dtlsprivatekey':{'type':Sequelize[_0x4f39d6('0x13')]},'dtlscipher':{'type':Sequelize[_0x4f39d6('0x13')]},'dtlscafile':{'type':Sequelize[_0x4f39d6('0x13')]},'dtlscapath':{'type':Sequelize['STRING']},'dtlssetup':{'type':Sequelize[_0x4f39d6('0x6')]('active',_0x4f39d6('0x1c'),'actpass'),'allowNull':!![]},'dtlsfingerprint':{'type':Sequelize['STRING']},'usereqphone':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no'),'defaultValue':'no'},'recordonfeature':{'type':Sequelize[_0x4f39d6('0x13')]},'recordofffeature':{'type':Sequelize[_0x4f39d6('0x13')]},'call_limit':{'type':Sequelize[_0x4f39d6('0x3')](0xb),'defaultValue':0x3e8},'registertrying':{'type':Sequelize[_0x4f39d6('0x6')](_0x4f39d6('0x8'),'no')},'subscribemwi':{'type':Sequelize['ENUM']('yes','no')},'vmexten':{'type':Sequelize[_0x4f39d6('0x13')]},'mohinterpret':{'type':Sequelize[_0x4f39d6('0x13')]},'mohsuggest':{'type':Sequelize[_0x4f39d6('0x13')]},'parkinglot':{'type':Sequelize['STRING']},'description':{'type':Sequelize['STRING']},'host':{'type':Sequelize[_0x4f39d6('0x13')],'defaultValue':'dynamic'},'canreinvite':{'type':Sequelize[_0x4f39d6('0x6')]('yes','no','nonat',_0x4f39d6('0x2'),_0x4f39d6('0x27')),'defaultValue':'no'},'registry':{'type':Sequelize[_0x4f39d6('0x13')]},'otherFields':{'type':Sequelize[_0x4f39d6('0x13')]},'active':{'type':Sequelize[_0x4f39d6('0x15')],'allowNull':![],'defaultValue':!![]},'t38pt_udptl':{'type':Sequelize[_0x4f39d6('0x13')],'defaultValue':'no'}}; \ No newline at end of file +const a642_0x4200=['udp','from-voip-provider','actpass','pai','dynamic','INTEGER','\x22\x22\x20<>','nat','force_rport,comedia','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22ulaw\x22,\x20\x22alaw\x22,\x20\x22alaw\x22]','nonat','uac','never','split','PROHIB_FAILED_SCREEN','inband','certificate','transport','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22udp\x22,\x20\x22tcp\x22]','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22port\x22,\x20\x22invite\x22]','STRING','insecure','ALLOWED_PASSED_SCREEN','join','PROHIB_NOT_SCREENED','passive','yes','shortinfo','accept','PROHIB_PASSED_SCREEN','ulaw;alaw;gsm','PROHIB','ALLOWED_NOT_SCREENED','rfc2833','sequelize','info','peer','update','getDataValue','ENUM','allow','name','outgoing','setDataValue','all','exports','BOOLEAN','fingerprint'];(function(_0x547df8,_0x420021){const _0x177843=function(_0x40c6bd){while(--_0x40c6bd){_0x547df8['push'](_0x547df8['shift']());}};_0x177843(++_0x420021);}(a642_0x4200,0x9b));const a642_0x1778=function(_0x547df8,_0x420021){_0x547df8=_0x547df8-0x0;let _0x177843=a642_0x4200[_0x547df8];return _0x177843;};const _0x28f6d0=a642_0x1778;'use strict';const Sequelize=require(_0x28f6d0('0x17'));module[_0x28f6d0('0x22')]={'name':{'type':Sequelize[_0x28f6d0('0x9')],'allowNull':![],'unique':_0x28f6d0('0x1e'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'type':{'type':Sequelize['ENUM']('friend','user',_0x28f6d0('0x19')),'allowNull':![],'defaultValue':'friend'},'context':{'type':Sequelize[_0x28f6d0('0x9')],'allowNull':![],'defaultValue':_0x28f6d0('0x26')},'callingpres':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0x15'),_0x28f6d0('0xb'),'ALLOWED_FAILED_SCREEN','ALLOWED',_0x28f6d0('0xd'),_0x28f6d0('0x12'),_0x28f6d0('0x3'),_0x28f6d0('0x14'))},'deny':{'type':Sequelize[_0x28f6d0('0x9')]},'permit':{'type':Sequelize[_0x28f6d0('0x9')]},'secret':{'type':Sequelize[_0x28f6d0('0x9')]},'md5secret':{'type':Sequelize[_0x28f6d0('0x9')]},'remotesecret':{'type':Sequelize[_0x28f6d0('0x9')]},'transport':{'type':Sequelize[_0x28f6d0('0x9')],'defaultValue':_0x28f6d0('0x25'),'set':function(_0x40c6bd){const _0x388dcb=_0x28f6d0;this[_0x388dcb('0x20')]('transport',_0x40c6bd?_0x40c6bd[_0x388dcb('0xc')](','):null);},'get':function(){const _0x430f8c=_0x28f6d0;return this[_0x430f8c('0x1b')](_0x430f8c('0x6'))?this[_0x430f8c('0x1b')](_0x430f8c('0x6'))['split'](','):null;},'comment':_0x28f6d0('0x7')},'dtmfmode':{'type':Sequelize[_0x28f6d0('0x1c')]('rfc2833',_0x28f6d0('0x18'),_0x28f6d0('0x10'),_0x28f6d0('0x4'),'auto'),'defaultValue':_0x28f6d0('0x16')},'directmedia':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no',_0x28f6d0('0x2f'),_0x28f6d0('0x1a'),_0x28f6d0('0x1f')),'defaultValue':'no'},'directrtpsetup':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no'),'defaultValue':'no'},'directmediapermit':{'type':Sequelize[_0x28f6d0('0x9')]},'directmediadeny':{'type':Sequelize[_0x28f6d0('0x9')]},'nat':{'type':Sequelize['STRING'],'defaultValue':_0x28f6d0('0x2d'),'set':function(_0x30a312){const _0x148bcf=_0x28f6d0;this[_0x148bcf('0x20')](_0x148bcf('0x2c'),_0x30a312?_0x30a312[_0x148bcf('0xc')](','):null);},'get':function(){const _0x5d59ff=_0x28f6d0;return this[_0x5d59ff('0x1b')](_0x5d59ff('0x2c'))?this[_0x5d59ff('0x1b')]('nat')['split'](','):null;},'comment':'String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22force_rport\x22,\x20\x22comedia\x22]'},'callgroup':{'type':Sequelize['STRING']},'namedcallgroup':{'type':Sequelize['STRING']},'pickupgroup':{'type':Sequelize[_0x28f6d0('0x9')]},'namedpickupgroup':{'type':Sequelize[_0x28f6d0('0x9')]},'language':{'type':Sequelize[_0x28f6d0('0x9')],'defaultValue':'en'},'tonezone':{'type':Sequelize[_0x28f6d0('0x9')],'allowNull':!![]},'disallow':{'type':Sequelize[_0x28f6d0('0x9')],'defaultValue':_0x28f6d0('0x21')},'allow':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x28f6d0('0x13'),'set':function(_0x50bd81){const _0x18a8e2=_0x28f6d0;this[_0x18a8e2('0x20')](_0x18a8e2('0x1d'),_0x50bd81?_0x50bd81[_0x18a8e2('0xc')](';'):_0x18a8e2('0x13'));},'get':function(){const _0x269b2e=_0x28f6d0;return this[_0x269b2e('0x1b')](_0x269b2e('0x1d'))?this[_0x269b2e('0x1b')](_0x269b2e('0x1d'))[_0x269b2e('0x2')](';'):null;},'comment':_0x28f6d0('0x2e')},'autoframing':{'type':Sequelize['ENUM'](_0x28f6d0('0xf'),'no')},'insecure':{'type':Sequelize['STRING'],'defaultValue':'port,invite','set':function(_0x910313){const _0x2b3e14=_0x28f6d0;this['setDataValue'](_0x2b3e14('0xa'),_0x910313?_0x910313['join'](','):null);},'get':function(){const _0x3ce568=_0x28f6d0;return this['getDataValue'](_0x3ce568('0xa'))?this[_0x3ce568('0x1b')](_0x3ce568('0xa'))['split'](','):null;},'comment':_0x28f6d0('0x8')},'trustrpid':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no'),'defaultValue':'no'},'trust_id_outbound':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no'),'defaultValue':'no'},'progressinband':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no',_0x28f6d0('0x1'))},'promiscredir':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no')},'useclientcode':{'type':Sequelize[_0x28f6d0('0x1c')]('yes','no')},'accountcode':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'setvar':{'type':Sequelize['STRING']},'callerid':{'type':Sequelize[_0x28f6d0('0x9')],'defaultValue':_0x28f6d0('0x2b')},'amaflags':{'type':Sequelize['STRING']},'callcounter':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no'),'defaultValue':_0x28f6d0('0xf')},'busylevel':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'allowoverlap':{'type':Sequelize[_0x28f6d0('0x1c')]('yes','no')},'allowsubscribe':{'type':Sequelize['ENUM'](_0x28f6d0('0xf'),'no')},'allowtransfer':{'type':Sequelize['ENUM'](_0x28f6d0('0xf'),'no')},'ignoresdpversion':{'type':Sequelize[_0x28f6d0('0x1c')]('yes','no')},'subscribecontext':{'type':Sequelize[_0x28f6d0('0x9')]},'template':{'type':Sequelize[_0x28f6d0('0x9')]},'videosupport':{'type':Sequelize['ENUM']('yes','no','always'),'defaultValue':'no'},'maxcallbitrate':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'rfc2833compensate':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no')},'mailbox':{'type':Sequelize['STRING']},'session_timers':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0x11'),'refuse','originate')},'session_expires':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'session_minse':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'session_refresher':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0x0'),'uas'),'defaultValue':'uas'},'t38pt_usertpsource':{'type':Sequelize['STRING']},'regexten':{'type':Sequelize[_0x28f6d0('0x9')]},'fromdomain':{'type':Sequelize[_0x28f6d0('0x9')]},'fromuser':{'type':Sequelize[_0x28f6d0('0x9')]},'port':{'type':Sequelize[_0x28f6d0('0x2a')](0x5)},'qualify':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no'),'defaultValue':_0x28f6d0('0xf')},'keepalive':{'type':Sequelize['INTEGER'](0xb)},'defaultip':{'type':Sequelize[_0x28f6d0('0x9')]},'defaultuser':{'type':Sequelize[_0x28f6d0('0x9')]},'rtptimeout':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'rtpholdtimeout':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'rtpkeepalive':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'sendrpid':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no',_0x28f6d0('0x28')),'defaultValue':'no'},'outboundproxy':{'type':Sequelize['STRING']},'callbackextension':{'type':Sequelize['STRING']},'timert1':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'timerb':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'qualifyfreq':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'contactpermit':{'type':Sequelize[_0x28f6d0('0x9')]},'contactdeny':{'type':Sequelize['STRING']},'contactacl':{'type':Sequelize[_0x28f6d0('0x9')]},'unsolicited_mailbox':{'type':Sequelize[_0x28f6d0('0x9')]},'use_q850_reason':{'type':Sequelize['STRING']},'maxforwards':{'type':Sequelize['INTEGER'](0xb)},'encryption':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no'),'defaultValue':'no'},'avpf':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no')},'force_avp':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no')},'icesupport':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no')},'dtlsenable':{'type':Sequelize[_0x28f6d0('0x1c')]('yes','no')},'dtlsverify':{'type':Sequelize['ENUM']('yes','no',_0x28f6d0('0x24'),_0x28f6d0('0x5'))},'dtlsrekey':{'type':Sequelize[_0x28f6d0('0x2a')](0xb)},'dtlscertfile':{'type':Sequelize[_0x28f6d0('0x9')]},'dtlsprivatekey':{'type':Sequelize[_0x28f6d0('0x9')]},'dtlscipher':{'type':Sequelize[_0x28f6d0('0x9')]},'dtlscafile':{'type':Sequelize[_0x28f6d0('0x9')]},'dtlscapath':{'type':Sequelize['STRING']},'dtlssetup':{'type':Sequelize['ENUM']('active',_0x28f6d0('0xe'),_0x28f6d0('0x27')),'allowNull':!![]},'dtlsfingerprint':{'type':Sequelize[_0x28f6d0('0x9')]},'usereqphone':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no'),'defaultValue':'no'},'recordonfeature':{'type':Sequelize[_0x28f6d0('0x9')]},'recordofffeature':{'type':Sequelize[_0x28f6d0('0x9')]},'call_limit':{'type':Sequelize['INTEGER'](0xb),'defaultValue':0x3e8},'registertrying':{'type':Sequelize[_0x28f6d0('0x1c')](_0x28f6d0('0xf'),'no')},'subscribemwi':{'type':Sequelize[_0x28f6d0('0x1c')]('yes','no')},'vmexten':{'type':Sequelize['STRING']},'mohinterpret':{'type':Sequelize['STRING']},'mohsuggest':{'type':Sequelize[_0x28f6d0('0x9')]},'parkinglot':{'type':Sequelize[_0x28f6d0('0x9')]},'description':{'type':Sequelize[_0x28f6d0('0x9')]},'host':{'type':Sequelize['STRING'],'defaultValue':_0x28f6d0('0x29')},'canreinvite':{'type':Sequelize[_0x28f6d0('0x1c')]('yes','no','nonat','update','update,nonat'),'defaultValue':'no'},'registry':{'type':Sequelize[_0x28f6d0('0x9')]},'otherFields':{'type':Sequelize[_0x28f6d0('0x9')]},'active':{'type':Sequelize[_0x28f6d0('0x23')],'allowNull':![],'defaultValue':!![]},'t38pt_udptl':{'type':Sequelize[_0x28f6d0('0x9')],'defaultValue':'no'}}; \ No newline at end of file diff --git a/server/api/trunk/trunk.controller.js b/server/api/trunk/trunk.controller.js index f218bc7..df21e87 100644 --- a/server/api/trunk/trunk.controller.js +++ b/server/api/trunk/trunk.controller.js @@ -1 +1 @@ -const a643_0x19d9=['/etc/asterisk/sip_xcally_registers.conf','json','map','fieldName','end','catch','Trunk','lodash','get','files/templates/trunk.ejs','where','options','nolimit','Trunk,\x20%s,\x20%s,\x20%s','update','Content-Range','like','stringify','path','updatedAt','render','fields','length','set','clone','result','Reload','order','UserProfileSection','type','attributes','destroy','root','ejs','rows','findAll','Unable\x20to\x20retrieve\x20the\x20current\x20user','limit','Trunks','/etc/asterisk/sip_xcally_trunks.conf','undefined','send','api','debug','merge','info','name','offset','create','filter','then','jayson/promise','filters','show','findOne','message','UserProfileResource','key','user','registry','includeAll','model','count','request','status','intersection','utf8','omit','http','params','join','role','request\x20sent','query','sort','createdAt','rawAttributes','error','../../mysqldb','chan_sip.so','include','Trunk,\x20%s,\x20%s','userProfileId','writeFileSync','pick','body','readFileSync','sequelize','keys','files/templates/registry.ejs'];(function(_0x1f8a8d,_0x19d952){const _0x57ca02=function(_0xcc9a10){while(--_0xcc9a10){_0x1f8a8d['push'](_0x1f8a8d['shift']());}};_0x57ca02(++_0x19d952);}(a643_0x19d9,0x8b));const a643_0x57ca=function(_0x1f8a8d,_0x19d952){_0x1f8a8d=_0x1f8a8d-0x0;let _0x57ca02=a643_0x19d9[_0x1f8a8d];return _0x57ca02;};const _0x66f912=a643_0x57ca;'use strict';const path=require(_0x66f912('0x3b')),ejs=require(_0x66f912('0x4a')),fs=require('fs'),_=require(_0x66f912('0x30')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x66f912('0x53')),config=require('../../config/environment'),db=require(_0x66f912('0x1d'))['db'],{Op}=require(_0x66f912('0x26')),jayson=require(_0x66f912('0x2')),client=jayson['client'][_0x66f912('0x13')]({'port':0x232a});function respondWithRpcPromise(_0xcc9a10,_0x24a135,_0x4ed1a2,_0x460487){return new Promise(function(_0x198305,_0x120b84){const _0x2bd5e5=a643_0x57ca,_0x88a462=_0x460487||client;return _0x88a462[_0x2bd5e5('0xe')](_0xcc9a10,_0x4ed1a2)[_0x2bd5e5('0x1')](function(_0x3c20a4){const _0x56d661=_0x2bd5e5;logger[_0x56d661('0x56')]('Trunk,\x20%s,\x20%s',_0x24a135,_0x56d661('0x17')),logger[_0x56d661('0x54')](_0x56d661('0x36'),_0x24a135,_0x56d661('0x17'),JSON[_0x56d661('0x3a')](_0x3c20a4));if(_0x3c20a4[_0x56d661('0x1c')]){if(_0x3c20a4[_0x56d661('0x1c')]['code']===0x1f4)return logger[_0x56d661('0x1c')](_0x56d661('0x20'),_0x24a135,_0x3c20a4[_0x56d661('0x1c')][_0x56d661('0x6')]),_0x120b84(_0x3c20a4['error']['message']);return logger[_0x56d661('0x1c')](_0x56d661('0x20'),_0x24a135,_0x3c20a4[_0x56d661('0x1c')][_0x56d661('0x6')]),_0x198305(_0x3c20a4[_0x56d661('0x1c')]['message']);}else logger['info'](_0x56d661('0x20'),_0x24a135,_0x56d661('0x17')),_0x198305(_0x3c20a4[_0x56d661('0x42')][_0x56d661('0x6')]);})[_0x2bd5e5('0x2e')](function(_0x319df5){const _0x2f70b4=_0x2bd5e5;logger[_0x2f70b4('0x1c')]('Trunk,\x20%s,\x20%s',_0x24a135,_0x319df5),_0x120b84(_0x319df5);});});}function respondWithResult(_0x3cc97d,_0x496188){return _0x496188=_0x496188||0xc8,function(_0x3214e3){const _0x3b2300=a643_0x57ca;if(_0x3214e3)return _0x3cc97d[_0x3b2300('0xf')](_0x496188)[_0x3b2300('0x2a')](_0x3214e3);};}function respondWithFilteredResult(_0x373f87,_0x5c594a){return function(_0xd4b39b){const _0x243834=a643_0x57ca;if(_0xd4b39b){const _0x78e4ae=_0xd4b39b['count'],_0x1f1edd=_0x5c594a[_0x243834('0x58')];let _0x2b3efa=_0x5c594a[_0x243834('0x58')]+_0x5c594a['limit'],_0x3a767d;return _0x2b3efa>=_0x78e4ae?(_0x2b3efa=_0x78e4ae,_0x3a767d=0xc8):_0x3a767d=0xce,_0x373f87[_0x243834('0xf')](_0x3a767d),_0x373f87[_0x243834('0x40')](_0x243834('0x38'),_0x1f1edd+'-'+_0x2b3efa+'/'+_0x78e4ae)[_0x243834('0x2a')](_0xd4b39b);}return null;};}function saveUpdates(_0x5cd59c){return function(_0xe56ea7){const _0x66a3a4=a643_0x57ca;if(_0xe56ea7)return _0xe56ea7[_0x66a3a4('0x37')](_0x5cd59c)[_0x66a3a4('0x1')](function(_0x36542e){return _0x36542e;});return null;};}function removeEntity(_0x293923){return function(_0x3f3b64){const _0x5a080e=a643_0x57ca;if(_0x3f3b64)return _0x3f3b64[_0x5a080e('0x48')]()[_0x5a080e('0x1')](function(){const _0x1a3dcd=_0x5a080e,_0x279b49=_0x3f3b64[_0x1a3dcd('0x31')]({'plain':!![]}),_0x4a11f3=_0x1a3dcd('0x4f');return db['UserProfileResource'][_0x1a3dcd('0x48')]({'where':{'type':_0x4a11f3,'resourceId':_0x279b49['id']}})[_0x1a3dcd('0x1')](function(){return _0x3f3b64;});})[_0x5a080e('0x1')](function(){const _0x4d3f59=_0x5a080e;_0x293923[_0x4d3f59('0xf')](0xcc)[_0x4d3f59('0x2d')]();});};}function handleEntityNotFound(_0x4094b4){return function(_0x32b0ae){return!_0x32b0ae&&_0x4094b4['sendStatus'](0x194),_0x32b0ae;};}function handleError(_0x150c8a,_0x566d29){return _0x566d29=_0x566d29||0x1f4,function(_0xf3b263){const _0x5d542d=a643_0x57ca;logger['error'](_0xf3b263['stack']),_0xf3b263[_0x5d542d('0x57')]&&delete _0xf3b263['name'],_0x150c8a[_0x5d542d('0xf')](_0x566d29)[_0x5d542d('0x52')](_0xf3b263);};}exports['index']=function(_0x4be71d,_0x5c44f0){const _0x2d10cb=_0x66f912;let _0x4d2649={};const _0x1879b8={},_0x34f809={'count':0x0,'rows':[]},_0x3edcd5=_[_0x2d10cb('0x2b')](db[_0x2d10cb('0x2f')][_0x2d10cb('0x1b')],function(_0x3ffb03){const _0x335db5=_0x2d10cb;return{'name':_0x3ffb03[_0x335db5('0x2c')],'type':_0x3ffb03[_0x335db5('0x46')][_0x335db5('0x8')]};});_0x1879b8[_0x2d10cb('0xc')]=_[_0x2d10cb('0x2b')](_0x3edcd5,_0x2d10cb('0x57')),_0x1879b8[_0x2d10cb('0x18')]=_[_0x2d10cb('0x27')](_0x4be71d[_0x2d10cb('0x18')]),_0x1879b8[_0x2d10cb('0x3')]=_[_0x2d10cb('0x10')](_0x1879b8[_0x2d10cb('0xc')],_0x1879b8[_0x2d10cb('0x18')]),_0x4d2649['attributes']=_[_0x2d10cb('0x10')](_0x1879b8['model'],qs[_0x2d10cb('0x3e')](_0x4be71d[_0x2d10cb('0x18')][_0x2d10cb('0x3e')])),_0x4d2649[_0x2d10cb('0x47')]=_0x4d2649[_0x2d10cb('0x47')][_0x2d10cb('0x3f')]?_0x4d2649[_0x2d10cb('0x47')]:_0x1879b8[_0x2d10cb('0xc')];typeof _0x4be71d[_0x2d10cb('0x18')][_0x2d10cb('0x35')]===_0x2d10cb('0x51')&&(_0x4d2649[_0x2d10cb('0x4e')]=qs[_0x2d10cb('0x4e')](_0x4be71d[_0x2d10cb('0x18')]['limit']),_0x4d2649[_0x2d10cb('0x58')]=qs[_0x2d10cb('0x58')](_0x4be71d[_0x2d10cb('0x18')][_0x2d10cb('0x58')]));_0x4d2649[_0x2d10cb('0x44')]=qs[_0x2d10cb('0x19')](_0x4be71d[_0x2d10cb('0x18')]['sort']),_0x4d2649[_0x2d10cb('0x33')]=qs[_0x2d10cb('0x3')](_[_0x2d10cb('0x23')](_0x4be71d[_0x2d10cb('0x18')],_0x1879b8[_0x2d10cb('0x3')]),_0x3edcd5);_0x4be71d[_0x2d10cb('0x18')]['filter']&&(_0x4d2649[_0x2d10cb('0x33')]=_['merge'](_0x4d2649['where'],{[Op['or']]:_[_0x2d10cb('0x2b')](_0x3edcd5,function(_0x31dba2){const _0x52a7ad=_0x2d10cb;if(_0x31dba2['type']!=='VIRTUAL'){const _0x267164={};return _0x267164[_0x31dba2[_0x52a7ad('0x57')]]={[Op[_0x52a7ad('0x39')]]:'%'+_0x4be71d[_0x52a7ad('0x18')][_0x52a7ad('0x0')]+'%'},_0x267164;}})}));_0x4d2649=_['merge']({},_0x4d2649,_0x4be71d[_0x2d10cb('0x34')]);const _0x188d08={'where':_0x4d2649[_0x2d10cb('0x33')]};return db[_0x2d10cb('0x2f')][_0x2d10cb('0xd')](_0x188d08)[_0x2d10cb('0x1')](function(_0x4465bb){const _0x248f53=_0x2d10cb;return _0x34f809[_0x248f53('0xd')]=_0x4465bb,_0x4be71d[_0x248f53('0x18')][_0x248f53('0xb')]&&(_0x4d2649[_0x248f53('0x1f')]=[{'all':!![]}]),db[_0x248f53('0x2f')]['findAll'](_0x4d2649);})[_0x2d10cb('0x1')](function(_0x4a567e){const _0x40e9b4=_0x2d10cb;return _0x34f809[_0x40e9b4('0x4b')]=_0x4a567e,_0x34f809;})['then'](respondWithFilteredResult(_0x5c44f0,_0x4d2649))[_0x2d10cb('0x2e')](handleError(_0x5c44f0,null));},exports[_0x66f912('0x4')]=function(_0x3152fd,_0x2efba3){const _0x38a5a3=_0x66f912;let _0x521fb7={'raw':![],'where':{'id':_0x3152fd[_0x38a5a3('0x14')]['id']}};const _0x1b8be1={};return _0x1b8be1[_0x38a5a3('0xc')]=_[_0x38a5a3('0x27')](db[_0x38a5a3('0x2f')][_0x38a5a3('0x1b')]),_0x1b8be1[_0x38a5a3('0x18')]=_['keys'](_0x3152fd['query']),_0x1b8be1[_0x38a5a3('0x3')]=_['intersection'](_0x1b8be1[_0x38a5a3('0xc')],_0x1b8be1[_0x38a5a3('0x18')]),_0x521fb7[_0x38a5a3('0x47')]=_[_0x38a5a3('0x10')](_0x1b8be1['model'],qs[_0x38a5a3('0x3e')](_0x3152fd[_0x38a5a3('0x18')]['fields'])),_0x521fb7['attributes']=_0x521fb7[_0x38a5a3('0x47')]['length']?_0x521fb7['attributes']:_0x1b8be1['model'],_0x3152fd[_0x38a5a3('0x18')][_0x38a5a3('0xb')]&&(_0x521fb7['include']=[{'all':!![]}]),_0x521fb7=_[_0x38a5a3('0x55')]({},_0x521fb7,_0x3152fd[_0x38a5a3('0x34')]),db[_0x38a5a3('0x2f')][_0x38a5a3('0x5')](_0x521fb7)[_0x38a5a3('0x1')](handleEntityNotFound(_0x2efba3,null))[_0x38a5a3('0x1')](respondWithResult(_0x2efba3,null))[_0x38a5a3('0x2e')](handleError(_0x2efba3,null));},exports[_0x66f912('0x41')]=function(_0x239c1e,_0x89000){const _0xe7ccfc=_0x66f912;let _0x1108c7={'where':{'id':_0x239c1e['params']['id']}};const _0x8fe3c2={};return _0x8fe3c2[_0xe7ccfc('0xc')]=_[_0xe7ccfc('0x27')](db['Trunk'][_0xe7ccfc('0x1b')]),_0x1108c7[_0xe7ccfc('0x47')]=_[_0xe7ccfc('0x10')](_0x8fe3c2[_0xe7ccfc('0xc')],qs[_0xe7ccfc('0x3e')](_0x239c1e['query'][_0xe7ccfc('0x3e')])),_0x1108c7[_0xe7ccfc('0x47')]=_0x1108c7[_0xe7ccfc('0x47')][_0xe7ccfc('0x3f')]?_0x1108c7['attributes']:_0x8fe3c2[_0xe7ccfc('0xc')],_0x239c1e[_0xe7ccfc('0x18')][_0xe7ccfc('0xb')]&&(_0x1108c7[_0xe7ccfc('0x1f')]=[{'all':!![]}]),_0x1108c7=_['merge']({},_0x1108c7,_0x239c1e[_0xe7ccfc('0x34')]),db[_0xe7ccfc('0x2f')]['findOne'](_0x1108c7)['then'](handleEntityNotFound(_0x89000,null))[_0xe7ccfc('0x1')](function(_0x3c7164){const _0x9a753b=_0xe7ccfc;if(_0x3c7164){let _0x18a4ab=_0x3c7164[_0x9a753b('0x31')]({'plain':!![]});return _0x18a4ab=qs['omit'](_0x18a4ab,['id',_0x9a753b('0x1a'),_0x9a753b('0x3c')]),_0x239c1e[_0x9a753b('0x24')]=_[_0x9a753b('0x12')](_0x239c1e[_0x9a753b('0x24')],['id',_0x9a753b('0x1a'),_0x9a753b('0x3c')]),db[_0x9a753b('0x2f')][_0x9a753b('0x59')](_['merge'](_0x18a4ab,_0x239c1e[_0x9a753b('0x24')]),{'include':_0x239c1e[_0x9a753b('0x18')][_0x9a753b('0xb')]?[{'all':!![]}]:undefined})[_0x9a753b('0x1')](function(_0x129de6){const _0x47416a=_0x9a753b,_0x26dddc=_0x239c1e[_0x47416a('0x9')][_0x47416a('0x31')]({'plain':!![]});if(!_0x26dddc)throw new Error(_0x47416a('0x4d'));if(_0x26dddc[_0x47416a('0x16')]==='user'){const _0x382498=_0x129de6[_0x47416a('0x31')]({'plain':!![]}),_0x298026=_0x47416a('0x4f');return db['UserProfileSection'][_0x47416a('0x5')]({'where':{'name':_0x298026,'userProfileId':_0x26dddc[_0x47416a('0x21')]},'raw':!![]})[_0x47416a('0x1')](function(_0x2f42f){const _0x516753=_0x47416a;return _0x2f42f&&_0x2f42f['autoAssociation']===0x0?db[_0x516753('0x7')][_0x516753('0x59')]({'name':_0x382498[_0x516753('0x57')],'resourceId':_0x382498['id'],'type':_0x2f42f['name'],'sectionId':_0x2f42f['id']},{})['then'](function(){return _0x129de6;}):_0x129de6;})[_0x47416a('0x2e')](function(_0xc680a5){const _0x2ff731=_0x47416a;logger[_0x2ff731('0x1c')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0xc680a5);throw _0xc680a5;});}return _0x129de6;});}})[_0xe7ccfc('0x1')](respondWithResult(_0x89000,0xc9))[_0xe7ccfc('0x2e')](handleError(_0x89000,null));},exports[_0x66f912('0x59')]=function(_0x40ed1d,_0x53c467){const _0x4e6293=_0x66f912;let _0x2186c1;return db[_0x4e6293('0x2f')][_0x4e6293('0x59')](_0x40ed1d[_0x4e6293('0x24')],{'raw':!![]})[_0x4e6293('0x1')](function(_0x19d841){const _0x240d4f=_0x4e6293;return _0x2186c1=_0x19d841,db['Trunk'][_0x240d4f('0x4c')]({'raw':!![]});})[_0x4e6293('0x1')](function(_0x593a9e){const _0x1a2be3=_0x4e6293,_0x21df53=fs[_0x1a2be3('0x25')](path['join'](config['root'],_0x1a2be3('0x32')),_0x1a2be3('0x11')),_0x57adbe=fs[_0x1a2be3('0x25')](path[_0x1a2be3('0x15')](config[_0x1a2be3('0x49')],_0x1a2be3('0x28')),_0x1a2be3('0x11')),_0x565ef4=ejs[_0x1a2be3('0x3d')](_0x21df53,{'trunks':_0x593a9e||[]});fs[_0x1a2be3('0x22')](_0x1a2be3('0x50'),_0x565ef4);if(_0x2186c1[_0x1a2be3('0xa')]){const _0x2fe572=ejs[_0x1a2be3('0x3d')](_0x57adbe,{'trunks':_0x593a9e||[]});fs['writeFileSync'](_0x1a2be3('0x29'),_0x2fe572);}})[_0x4e6293('0x1')](function(){const _0x27b9aa=_0x4e6293;return respondWithRpcPromise('Reload',_0x27b9aa('0x59'),{'module':_0x27b9aa('0x1e')});})['then'](function(){const _0x1691ea=_0x4e6293,_0x46042b=_0x40ed1d['user'][_0x1691ea('0x31')]({'plain':!![]});if(!_0x46042b)throw new Error(_0x1691ea('0x4d'));if(_0x46042b[_0x1691ea('0x16')]==='user'){const _0x53ead3=_0x2186c1[_0x1691ea('0x31')]({'plain':!![]});return db[_0x1691ea('0x45')]['findOne']({'where':{'name':_0x1691ea('0x4f'),'userProfileId':_0x46042b[_0x1691ea('0x21')]},'raw':!![]})[_0x1691ea('0x1')](function(_0x33e740){const _0x1fffde=_0x1691ea;return _0x33e740&&_0x33e740['autoAssociation']===0x0?db[_0x1fffde('0x7')]['create']({'name':_0x53ead3['name'],'resourceId':_0x53ead3['id'],'type':_0x33e740[_0x1fffde('0x57')],'sectionId':_0x33e740['id']},{})[_0x1fffde('0x1')](function(){return _0x2186c1;}):_0x2186c1;})['catch'](function(_0xe40cbe){const _0x4111c2=_0x1691ea;logger[_0x4111c2('0x1c')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0xe40cbe);throw _0xe40cbe;});}return _0x2186c1;})[_0x4e6293('0x1')](respondWithResult(_0x53c467,0xc9))['catch'](handleError(_0x53c467,null));},exports['update']=function(_0x1bc10f,_0x3ba3a9){const _0x1fcb6a=_0x66f912;let _0x43da1e;return db[_0x1fcb6a('0x2f')][_0x1fcb6a('0x5')]({'where':{'id':_0x1bc10f['params']['id']}})[_0x1fcb6a('0x1')](handleEntityNotFound(_0x3ba3a9,null))[_0x1fcb6a('0x1')](saveUpdates(_0x1bc10f[_0x1fcb6a('0x24')],null))[_0x1fcb6a('0x1')](function(_0x5595d6){const _0x4bef9a=_0x1fcb6a;if(_0x5595d6)return _0x43da1e=_0x5595d6,db[_0x4bef9a('0x2f')]['findAll']({'raw':!![]});})[_0x1fcb6a('0x1')](function(_0x2ea6b9){const _0x34b518=_0x1fcb6a;if(_0x2ea6b9){const _0x49d4c7=fs[_0x34b518('0x25')](path[_0x34b518('0x15')](config[_0x34b518('0x49')],_0x34b518('0x32')),_0x34b518('0x11')),_0x52343b=fs[_0x34b518('0x25')](path[_0x34b518('0x15')](config[_0x34b518('0x49')],_0x34b518('0x28')),'utf8'),_0x3a34a9=ejs['render'](_0x49d4c7,{'trunks':_0x2ea6b9||[]});fs[_0x34b518('0x22')](_0x34b518('0x50'),_0x3a34a9);const _0x12edf6=ejs[_0x34b518('0x3d')](_0x52343b,{'trunks':_0x2ea6b9||[]});return fs[_0x34b518('0x22')](_0x34b518('0x29'),_0x12edf6),respondWithRpcPromise(_0x34b518('0x43'),_0x34b518('0x37'),{'module':'chan_sip.so'});}return null;})[_0x1fcb6a('0x1')](function(_0x576c8e){if(_0x576c8e)return _0x43da1e;})[_0x1fcb6a('0x1')](respondWithResult(_0x3ba3a9,null))[_0x1fcb6a('0x2e')](handleError(_0x3ba3a9,null));},exports[_0x66f912('0x48')]=function(_0x14d4f2,_0x31e3cd){const _0x3a0ae1=_0x66f912;return db[_0x3a0ae1('0x2f')][_0x3a0ae1('0x5')]({'where':{'id':_0x14d4f2[_0x3a0ae1('0x14')]['id']}})[_0x3a0ae1('0x1')](handleEntityNotFound(_0x31e3cd,null))[_0x3a0ae1('0x1')](removeEntity(_0x31e3cd,null))[_0x3a0ae1('0x1')](function(){const _0x38b298=_0x3a0ae1;return db[_0x38b298('0x2f')][_0x38b298('0x4c')]({'raw':!![]});})[_0x3a0ae1('0x1')](function(_0x449fda){const _0x47fd39=_0x3a0ae1,_0x29d643=fs['readFileSync'](path['join'](config[_0x47fd39('0x49')],'files/templates/trunk.ejs'),'utf8'),_0x103a59=fs[_0x47fd39('0x25')](path[_0x47fd39('0x15')](config['root'],_0x47fd39('0x28')),_0x47fd39('0x11')),_0x131fdf=ejs[_0x47fd39('0x3d')](_0x29d643,{'trunks':_0x449fda}),_0x5aaa67=ejs['render'](_0x103a59,{'trunks':_0x449fda});return fs['writeFileSync'](_0x47fd39('0x50'),_0x131fdf),fs[_0x47fd39('0x22')](_0x47fd39('0x29'),_0x5aaa67),respondWithRpcPromise(_0x47fd39('0x43'),'destroy',{'module':_0x47fd39('0x1e')});})[_0x3a0ae1('0x2e')](handleError(_0x31e3cd,null));}; \ No newline at end of file +const a643_0x467b=['intersection','undefined','Unable\x20to\x20retrieve\x20the\x20current\x20user','client','readFileSync','UserProfileSection','../../config/environment','role','includeAll','create','merge','length','writeFileSync','params','updatedAt','rows','where','VIRTUAL','request\x20sent','user','count','message','Trunk,\x20%s,\x20%s,\x20%s','query','path','limit','findAll','sendStatus','type','registry','then','root','map','catch','Trunk','order','userProfileId','json','nolimit','createdAt','Reload','info','fields','UserProfileResource','offset','sort','destroy','rawAttributes','render','../../components/parsers/qs','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','sequelize','utf8','Trunk,\x20%s,\x20%s','error','code','result','attributes','Trunks','autoAssociation','model','update','files/templates/registry.ejs','get','set','omit','/etc/asterisk/sip_xcally_trunks.conf','files/templates/trunk.ejs','Content-Range','filters','clone','chan_sip.so','join','pick','stringify','keys','status','send','/etc/asterisk/sip_xcally_registers.conf','name','options','include','request','stack','ejs','body','api','index','filter','findOne'];(function(_0x375ac1,_0x467b89){const _0x2cd100=function(_0x490a11){while(--_0x490a11){_0x375ac1['push'](_0x375ac1['shift']());}};_0x2cd100(++_0x467b89);}(a643_0x467b,0x1e1));const a643_0x2cd1=function(_0x375ac1,_0x467b89){_0x375ac1=_0x375ac1-0x0;let _0x2cd100=a643_0x467b[_0x375ac1];return _0x2cd100;};const _0x1689c3=a643_0x2cd1;'use strict';const path=require(_0x1689c3('0x53')),ejs=require(_0x1689c3('0x35')),fs=require('fs'),_=require('lodash'),qs=require(_0x1689c3('0x12')),logger=require('../../config/logger')(_0x1689c3('0x37')),config=require(_0x1689c3('0x41')),db=require('../../mysqldb')['db'],{Op}=require(_0x1689c3('0x14')),jayson=require('jayson/promise'),client=jayson[_0x1689c3('0x3e')]['http']({'port':0x232a});function respondWithRpcPromise(_0x490a11,_0x2d485b,_0x572139,_0x4d2a00){return new Promise(function(_0x37564b,_0x5b882d){const _0x4c3336=a643_0x2cd1,_0x2774cc=_0x4d2a00||client;return _0x2774cc[_0x4c3336('0x33')](_0x490a11,_0x572139)[_0x4c3336('0x59')](function(_0x286011){const _0x48cb9b=_0x4c3336;logger['info'](_0x48cb9b('0x16'),_0x2d485b,'request\x20sent'),logger['debug'](_0x48cb9b('0x51'),_0x2d485b,_0x48cb9b('0x4d'),JSON[_0x48cb9b('0x2b')](_0x286011));if(_0x286011[_0x48cb9b('0x17')]){if(_0x286011['error'][_0x48cb9b('0x18')]===0x1f4)return logger[_0x48cb9b('0x17')](_0x48cb9b('0x16'),_0x2d485b,_0x286011[_0x48cb9b('0x17')][_0x48cb9b('0x50')]),_0x5b882d(_0x286011[_0x48cb9b('0x17')][_0x48cb9b('0x50')]);return logger[_0x48cb9b('0x17')]('Trunk,\x20%s,\x20%s',_0x2d485b,_0x286011[_0x48cb9b('0x17')][_0x48cb9b('0x50')]),_0x37564b(_0x286011[_0x48cb9b('0x17')][_0x48cb9b('0x50')]);}else logger[_0x48cb9b('0xa')](_0x48cb9b('0x16'),_0x2d485b,_0x48cb9b('0x4d')),_0x37564b(_0x286011[_0x48cb9b('0x19')][_0x48cb9b('0x50')]);})['catch'](function(_0x1343cf){const _0x1c010a=_0x4c3336;logger[_0x1c010a('0x17')](_0x1c010a('0x16'),_0x2d485b,_0x1343cf),_0x5b882d(_0x1343cf);});});}function respondWithResult(_0x57f54e,_0x7de2f3){return _0x7de2f3=_0x7de2f3||0xc8,function(_0x11fc7e){const _0x2e36cd=a643_0x2cd1;if(_0x11fc7e)return _0x57f54e['status'](_0x7de2f3)[_0x2e36cd('0x6')](_0x11fc7e);};}function respondWithFilteredResult(_0x4b4786,_0x333045){return function(_0x340aa0){const _0x474776=a643_0x2cd1;if(_0x340aa0){const _0x45b6cb=_0x340aa0['count'],_0x447505=_0x333045[_0x474776('0xd')];let _0x5b3afd=_0x333045[_0x474776('0xd')]+_0x333045[_0x474776('0x54')],_0x6475c;return _0x5b3afd>=_0x45b6cb?(_0x5b3afd=_0x45b6cb,_0x6475c=0xc8):_0x6475c=0xce,_0x4b4786[_0x474776('0x2d')](_0x6475c),_0x4b4786[_0x474776('0x21')](_0x474776('0x25'),_0x447505+'-'+_0x5b3afd+'/'+_0x45b6cb)[_0x474776('0x6')](_0x340aa0);}return null;};}function saveUpdates(_0x1021af){return function(_0x193e93){const _0x1061ea=a643_0x2cd1;if(_0x193e93)return _0x193e93[_0x1061ea('0x1e')](_0x1021af)[_0x1061ea('0x59')](function(_0x3e082b){return _0x3e082b;});return null;};}function removeEntity(_0x47684b){return function(_0x3d52f7){if(_0x3d52f7)return _0x3d52f7['destroy']()['then'](function(){const _0x3b6ebe=a643_0x2cd1,_0x148980=_0x3d52f7[_0x3b6ebe('0x20')]({'plain':!![]}),_0x584875=_0x3b6ebe('0x1b');return db[_0x3b6ebe('0xc')]['destroy']({'where':{'type':_0x584875,'resourceId':_0x148980['id']}})[_0x3b6ebe('0x59')](function(){return _0x3d52f7;});})['then'](function(){const _0x2fb931=a643_0x2cd1;_0x47684b[_0x2fb931('0x2d')](0xcc)['end']();});};}function handleEntityNotFound(_0x267740){return function(_0xc15e02){const _0x4ef684=a643_0x2cd1;return!_0xc15e02&&_0x267740[_0x4ef684('0x56')](0x194),_0xc15e02;};}function handleError(_0x49ec03,_0x408f2a){return _0x408f2a=_0x408f2a||0x1f4,function(_0x120200){const _0x3fdfaa=a643_0x2cd1;logger[_0x3fdfaa('0x17')](_0x120200[_0x3fdfaa('0x34')]),_0x120200[_0x3fdfaa('0x30')]&&delete _0x120200[_0x3fdfaa('0x30')],_0x49ec03[_0x3fdfaa('0x2d')](_0x408f2a)[_0x3fdfaa('0x2e')](_0x120200);};}exports[_0x1689c3('0x38')]=function(_0x4e6159,_0x529cdb){const _0x24f752=_0x1689c3;let _0x558408={};const _0x324e18={},_0x23916e={'count':0x0,'rows':[]},_0x57f4c2=_[_0x24f752('0x1')](db[_0x24f752('0x3')][_0x24f752('0x10')],function(_0x25c34f){const _0x6dfd2=_0x24f752;return{'name':_0x25c34f['fieldName'],'type':_0x25c34f[_0x6dfd2('0x57')]['key']};});_0x324e18[_0x24f752('0x1d')]=_[_0x24f752('0x1')](_0x57f4c2,_0x24f752('0x30')),_0x324e18[_0x24f752('0x52')]=_['keys'](_0x4e6159[_0x24f752('0x52')]),_0x324e18[_0x24f752('0x26')]=_[_0x24f752('0x3b')](_0x324e18[_0x24f752('0x1d')],_0x324e18['query']),_0x558408[_0x24f752('0x1a')]=_['intersection'](_0x324e18[_0x24f752('0x1d')],qs[_0x24f752('0xb')](_0x4e6159[_0x24f752('0x52')][_0x24f752('0xb')])),_0x558408[_0x24f752('0x1a')]=_0x558408[_0x24f752('0x1a')]['length']?_0x558408[_0x24f752('0x1a')]:_0x324e18[_0x24f752('0x1d')];typeof _0x4e6159[_0x24f752('0x52')][_0x24f752('0x7')]===_0x24f752('0x3c')&&(_0x558408['limit']=qs[_0x24f752('0x54')](_0x4e6159[_0x24f752('0x52')]['limit']),_0x558408['offset']=qs[_0x24f752('0xd')](_0x4e6159['query'][_0x24f752('0xd')]));_0x558408[_0x24f752('0x4')]=qs[_0x24f752('0xe')](_0x4e6159[_0x24f752('0x52')][_0x24f752('0xe')]),_0x558408[_0x24f752('0x4b')]=qs['filters'](_[_0x24f752('0x2a')](_0x4e6159[_0x24f752('0x52')],_0x324e18[_0x24f752('0x26')]),_0x57f4c2);_0x4e6159['query'][_0x24f752('0x39')]&&(_0x558408['where']=_[_0x24f752('0x45')](_0x558408[_0x24f752('0x4b')],{[Op['or']]:_[_0x24f752('0x1')](_0x57f4c2,function(_0x1821f2){const _0x33ddd3=_0x24f752;if(_0x1821f2[_0x33ddd3('0x57')]!==_0x33ddd3('0x4c')){const _0x2041f6={};return _0x2041f6[_0x1821f2[_0x33ddd3('0x30')]]={[Op['like']]:'%'+_0x4e6159[_0x33ddd3('0x52')][_0x33ddd3('0x39')]+'%'},_0x2041f6;}})}));_0x558408=_['merge']({},_0x558408,_0x4e6159[_0x24f752('0x31')]);const _0x4b432a={'where':_0x558408[_0x24f752('0x4b')]};return db[_0x24f752('0x3')][_0x24f752('0x4f')](_0x4b432a)['then'](function(_0x5302fe){const _0x1da601=_0x24f752;return _0x23916e[_0x1da601('0x4f')]=_0x5302fe,_0x4e6159[_0x1da601('0x52')][_0x1da601('0x43')]&&(_0x558408[_0x1da601('0x32')]=[{'all':!![]}]),db['Trunk'][_0x1da601('0x55')](_0x558408);})[_0x24f752('0x59')](function(_0x3858dd){const _0x424e21=_0x24f752;return _0x23916e[_0x424e21('0x4a')]=_0x3858dd,_0x23916e;})['then'](respondWithFilteredResult(_0x529cdb,_0x558408))['catch'](handleError(_0x529cdb,null));},exports['show']=function(_0x290c5a,_0x512539){const _0x53add0=_0x1689c3;let _0x16e63a={'raw':![],'where':{'id':_0x290c5a[_0x53add0('0x48')]['id']}};const _0x492667={};return _0x492667[_0x53add0('0x1d')]=_['keys'](db[_0x53add0('0x3')]['rawAttributes']),_0x492667[_0x53add0('0x52')]=_[_0x53add0('0x2c')](_0x290c5a[_0x53add0('0x52')]),_0x492667[_0x53add0('0x26')]=_['intersection'](_0x492667[_0x53add0('0x1d')],_0x492667[_0x53add0('0x52')]),_0x16e63a['attributes']=_[_0x53add0('0x3b')](_0x492667[_0x53add0('0x1d')],qs['fields'](_0x290c5a[_0x53add0('0x52')]['fields'])),_0x16e63a['attributes']=_0x16e63a[_0x53add0('0x1a')][_0x53add0('0x46')]?_0x16e63a[_0x53add0('0x1a')]:_0x492667['model'],_0x290c5a[_0x53add0('0x52')][_0x53add0('0x43')]&&(_0x16e63a[_0x53add0('0x32')]=[{'all':!![]}]),_0x16e63a=_[_0x53add0('0x45')]({},_0x16e63a,_0x290c5a['options']),db[_0x53add0('0x3')][_0x53add0('0x3a')](_0x16e63a)[_0x53add0('0x59')](handleEntityNotFound(_0x512539,null))[_0x53add0('0x59')](respondWithResult(_0x512539,null))[_0x53add0('0x2')](handleError(_0x512539,null));},exports[_0x1689c3('0x27')]=function(_0x2dff76,_0x255b5b){const _0x1df960=_0x1689c3;let _0x362fde={'where':{'id':_0x2dff76['params']['id']}};const _0x4708c3={};return _0x4708c3['model']=_[_0x1df960('0x2c')](db['Trunk']['rawAttributes']),_0x362fde[_0x1df960('0x1a')]=_['intersection'](_0x4708c3[_0x1df960('0x1d')],qs[_0x1df960('0xb')](_0x2dff76['query'][_0x1df960('0xb')])),_0x362fde[_0x1df960('0x1a')]=_0x362fde[_0x1df960('0x1a')][_0x1df960('0x46')]?_0x362fde['attributes']:_0x4708c3[_0x1df960('0x1d')],_0x2dff76[_0x1df960('0x52')][_0x1df960('0x43')]&&(_0x362fde['include']=[{'all':!![]}]),_0x362fde=_[_0x1df960('0x45')]({},_0x362fde,_0x2dff76['options']),db[_0x1df960('0x3')]['findOne'](_0x362fde)[_0x1df960('0x59')](handleEntityNotFound(_0x255b5b,null))[_0x1df960('0x59')](function(_0x139eed){const _0x373163=_0x1df960;if(_0x139eed){let _0x42fafd=_0x139eed[_0x373163('0x20')]({'plain':!![]});return _0x42fafd=qs[_0x373163('0x22')](_0x42fafd,['id',_0x373163('0x8'),_0x373163('0x49')]),_0x2dff76[_0x373163('0x36')]=_['omit'](_0x2dff76[_0x373163('0x36')],['id','createdAt',_0x373163('0x49')]),db[_0x373163('0x3')][_0x373163('0x44')](_[_0x373163('0x45')](_0x42fafd,_0x2dff76[_0x373163('0x36')]),{'include':_0x2dff76[_0x373163('0x52')]['includeAll']?[{'all':!![]}]:undefined})[_0x373163('0x59')](function(_0x21f78c){const _0x1c749c=_0x373163,_0x5ec76d=_0x2dff76[_0x1c749c('0x4e')][_0x1c749c('0x20')]({'plain':!![]});if(!_0x5ec76d)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x5ec76d[_0x1c749c('0x42')]===_0x1c749c('0x4e')){const _0x5e4f24=_0x21f78c['get']({'plain':!![]}),_0x352085=_0x1c749c('0x1b');return db['UserProfileSection']['findOne']({'where':{'name':_0x352085,'userProfileId':_0x5ec76d[_0x1c749c('0x5')]},'raw':!![]})['then'](function(_0x4a1d06){const _0x404587=_0x1c749c;return _0x4a1d06&&_0x4a1d06[_0x404587('0x1c')]===0x0?db[_0x404587('0xc')][_0x404587('0x44')]({'name':_0x5e4f24[_0x404587('0x30')],'resourceId':_0x5e4f24['id'],'type':_0x4a1d06[_0x404587('0x30')],'sectionId':_0x4a1d06['id']},{})['then'](function(){return _0x21f78c;}):_0x21f78c;})['catch'](function(_0xb56c0){const _0x276574=_0x1c749c;logger[_0x276574('0x17')](_0x276574('0x13'),_0xb56c0);throw _0xb56c0;});}return _0x21f78c;});}})[_0x1df960('0x59')](respondWithResult(_0x255b5b,0xc9))[_0x1df960('0x2')](handleError(_0x255b5b,null));},exports[_0x1689c3('0x44')]=function(_0xa7f992,_0x24b579){const _0x5c07e8=_0x1689c3;let _0xc9a35d;return db[_0x5c07e8('0x3')][_0x5c07e8('0x44')](_0xa7f992[_0x5c07e8('0x36')],{'raw':!![]})[_0x5c07e8('0x59')](function(_0x2bf85d){const _0x11eb11=_0x5c07e8;return _0xc9a35d=_0x2bf85d,db[_0x11eb11('0x3')][_0x11eb11('0x55')]({'raw':!![]});})[_0x5c07e8('0x59')](function(_0x4ee9f9){const _0x894d0=_0x5c07e8,_0x3e47ee=fs[_0x894d0('0x3f')](path[_0x894d0('0x29')](config[_0x894d0('0x0')],_0x894d0('0x24')),_0x894d0('0x15')),_0x28850e=fs['readFileSync'](path[_0x894d0('0x29')](config[_0x894d0('0x0')],'files/templates/registry.ejs'),_0x894d0('0x15')),_0x14659a=ejs[_0x894d0('0x11')](_0x3e47ee,{'trunks':_0x4ee9f9||[]});fs[_0x894d0('0x47')](_0x894d0('0x23'),_0x14659a);if(_0xc9a35d[_0x894d0('0x58')]){const _0x54ebad=ejs[_0x894d0('0x11')](_0x28850e,{'trunks':_0x4ee9f9||[]});fs['writeFileSync'](_0x894d0('0x2f'),_0x54ebad);}})['then'](function(){const _0x1cbe17=_0x5c07e8;return respondWithRpcPromise(_0x1cbe17('0x9'),_0x1cbe17('0x44'),{'module':_0x1cbe17('0x28')});})[_0x5c07e8('0x59')](function(){const _0x56e1cb=_0x5c07e8,_0x9a9003=_0xa7f992[_0x56e1cb('0x4e')][_0x56e1cb('0x20')]({'plain':!![]});if(!_0x9a9003)throw new Error(_0x56e1cb('0x3d'));if(_0x9a9003['role']===_0x56e1cb('0x4e')){const _0x4db7be=_0xc9a35d['get']({'plain':!![]});return db[_0x56e1cb('0x40')][_0x56e1cb('0x3a')]({'where':{'name':_0x56e1cb('0x1b'),'userProfileId':_0x9a9003[_0x56e1cb('0x5')]},'raw':!![]})[_0x56e1cb('0x59')](function(_0x3f1033){const _0xc2dc01=_0x56e1cb;return _0x3f1033&&_0x3f1033[_0xc2dc01('0x1c')]===0x0?db[_0xc2dc01('0xc')][_0xc2dc01('0x44')]({'name':_0x4db7be[_0xc2dc01('0x30')],'resourceId':_0x4db7be['id'],'type':_0x3f1033[_0xc2dc01('0x30')],'sectionId':_0x3f1033['id']},{})[_0xc2dc01('0x59')](function(){return _0xc9a35d;}):_0xc9a35d;})[_0x56e1cb('0x2')](function(_0x90d757){const _0x4f0fbe=_0x56e1cb;logger['error'](_0x4f0fbe('0x13'),_0x90d757);throw _0x90d757;});}return _0xc9a35d;})['then'](respondWithResult(_0x24b579,0xc9))['catch'](handleError(_0x24b579,null));},exports['update']=function(_0xa75423,_0x488dd1){const _0x13f481=_0x1689c3;let _0x439ba1;return db[_0x13f481('0x3')][_0x13f481('0x3a')]({'where':{'id':_0xa75423['params']['id']}})[_0x13f481('0x59')](handleEntityNotFound(_0x488dd1,null))[_0x13f481('0x59')](saveUpdates(_0xa75423['body'],null))[_0x13f481('0x59')](function(_0x2e812d){const _0x36ecb9=_0x13f481;if(_0x2e812d)return _0x439ba1=_0x2e812d,db[_0x36ecb9('0x3')]['findAll']({'raw':!![]});})[_0x13f481('0x59')](function(_0x4cf1ae){const _0x384c98=_0x13f481;if(_0x4cf1ae){const _0x323ad3=fs[_0x384c98('0x3f')](path[_0x384c98('0x29')](config[_0x384c98('0x0')],_0x384c98('0x24')),'utf8'),_0x1084b3=fs[_0x384c98('0x3f')](path[_0x384c98('0x29')](config['root'],'files/templates/registry.ejs'),_0x384c98('0x15')),_0xc3356f=ejs[_0x384c98('0x11')](_0x323ad3,{'trunks':_0x4cf1ae||[]});fs[_0x384c98('0x47')](_0x384c98('0x23'),_0xc3356f);const _0x2eec3f=ejs[_0x384c98('0x11')](_0x1084b3,{'trunks':_0x4cf1ae||[]});return fs[_0x384c98('0x47')](_0x384c98('0x2f'),_0x2eec3f),respondWithRpcPromise(_0x384c98('0x9'),_0x384c98('0x1e'),{'module':_0x384c98('0x28')});}return null;})[_0x13f481('0x59')](function(_0x47f02e){if(_0x47f02e)return _0x439ba1;})['then'](respondWithResult(_0x488dd1,null))[_0x13f481('0x2')](handleError(_0x488dd1,null));},exports[_0x1689c3('0xf')]=function(_0x4584c5,_0x12088b){const _0x38e6f7=_0x1689c3;return db[_0x38e6f7('0x3')]['findOne']({'where':{'id':_0x4584c5[_0x38e6f7('0x48')]['id']}})['then'](handleEntityNotFound(_0x12088b,null))['then'](removeEntity(_0x12088b,null))[_0x38e6f7('0x59')](function(){const _0x49b7eb=_0x38e6f7;return db[_0x49b7eb('0x3')][_0x49b7eb('0x55')]({'raw':!![]});})[_0x38e6f7('0x59')](function(_0xef7c4e){const _0x364dfb=_0x38e6f7,_0x39110d=fs[_0x364dfb('0x3f')](path[_0x364dfb('0x29')](config['root'],_0x364dfb('0x24')),'utf8'),_0xf2a314=fs[_0x364dfb('0x3f')](path[_0x364dfb('0x29')](config['root'],_0x364dfb('0x1f')),_0x364dfb('0x15')),_0x43605a=ejs[_0x364dfb('0x11')](_0x39110d,{'trunks':_0xef7c4e}),_0xb709b=ejs[_0x364dfb('0x11')](_0xf2a314,{'trunks':_0xef7c4e});return fs[_0x364dfb('0x47')](_0x364dfb('0x23'),_0x43605a),fs[_0x364dfb('0x47')](_0x364dfb('0x2f'),_0xb709b),respondWithRpcPromise(_0x364dfb('0x9'),_0x364dfb('0xf'),{'module':_0x364dfb('0x28')});})['catch'](handleError(_0x12088b,null));}; \ No newline at end of file diff --git a/server/api/trunk/trunk.model.js b/server/api/trunk/trunk.model.js index 74fed58..3cc4ad3 100644 --- a/server/api/trunk/trunk.model.js +++ b/server/api/trunk/trunk.model.js @@ -1 +1 @@ -const a644_0x704b=['exports','Trunk','./trunk.attributes','define','tools_trunks'];(function(_0x203ae3,_0x704b24){const _0x2ee35=function(_0x6fc0f5){while(--_0x6fc0f5){_0x203ae3['push'](_0x203ae3['shift']());}};_0x2ee35(++_0x704b24);}(a644_0x704b,0x94));const a644_0x2ee3=function(_0x203ae3,_0x704b24){_0x203ae3=_0x203ae3-0x0;let _0x2ee35=a644_0x704b[_0x203ae3];return _0x2ee35;};const _0x28b325=a644_0x2ee3;'use strict';const attributes=require(_0x28b325('0x4'));module[_0x28b325('0x2')]=function(_0x6fc0f5){const _0x2d5a08=_0x28b325,_0x137cbd=_0x6fc0f5[_0x2d5a08('0x0')](_0x2d5a08('0x3'),attributes,{'tableName':_0x2d5a08('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x137cbd;}; \ No newline at end of file +const a644_0x1ec7=['./trunk.attributes','define','tools_trunks','exports','Trunk'];(function(_0x1437f3,_0x1ec76a){const _0x4243d9=function(_0x471988){while(--_0x471988){_0x1437f3['push'](_0x1437f3['shift']());}};_0x4243d9(++_0x1ec76a);}(a644_0x1ec7,0x9b));const a644_0x4243=function(_0x1437f3,_0x1ec76a){_0x1437f3=_0x1437f3-0x0;let _0x4243d9=a644_0x1ec7[_0x1437f3];return _0x4243d9;};const _0x1e16e3=a644_0x4243;'use strict';const attributes=require(_0x1e16e3('0x0'));module[_0x1e16e3('0x3')]=function(_0x471988){const _0x177c8f=_0x1e16e3,_0x70ad4b=_0x471988[_0x177c8f('0x1')](_0x177c8f('0x4'),attributes,{'tableName':_0x177c8f('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x70ad4b;}; \ No newline at end of file diff --git a/server/api/trunk/trunk.rpc.js b/server/api/trunk/trunk.rpc.js index 3039328..151037a 100644 --- a/server/api/trunk/trunk.rpc.js +++ b/server/api/trunk/trunk.rpc.js @@ -1 +1 @@ -const a645_0x5b48=['error','ShowTrunk','limit','debug','then','info','findOne','model','options','findAll','raw','catch','include','message','lodash','attributes','where','rpc','Trunk','map','GetTrunk'];(function(_0x17981f,_0x5b480b){const _0x4e85a1=function(_0x40224f){while(--_0x40224f){_0x17981f['push'](_0x17981f['shift']());}};_0x4e85a1(++_0x5b480b);}(a645_0x5b48,0x1b0));const a645_0x4e85=function(_0x17981f,_0x5b480b){_0x17981f=_0x17981f-0x0;let _0x4e85a1=a645_0x5b48[_0x17981f];return _0x4e85a1;};const _0x300af4=a645_0x4e85;'use strict';const _=require(_0x300af4('0x2')),db=require('../../mysqldb')['db'],logger=require('../../config/logger')(_0x300af4('0x5'));exports['GetTrunk']=function(_0x40224f){const _0x50649b=this;return new Promise(function(_0x5c0ab6,_0x27ea3d){const _0x1ca69d=a645_0x4e85;return db[_0x1ca69d('0x6')][_0x1ca69d('0x12')]({'raw':_0x40224f[_0x1ca69d('0x11')]?_0x40224f[_0x1ca69d('0x11')][_0x1ca69d('0x13')]===undefined?!![]:![]:!![],'where':_0x40224f[_0x1ca69d('0x11')]?_0x40224f[_0x1ca69d('0x11')][_0x1ca69d('0x4')]||null:null,'attributes':_0x40224f[_0x1ca69d('0x11')]?_0x40224f[_0x1ca69d('0x11')][_0x1ca69d('0x3')]||null:null,'limit':_0x40224f[_0x1ca69d('0x11')]?_0x40224f[_0x1ca69d('0x11')][_0x1ca69d('0xb')]||null:null,'include':_0x40224f[_0x1ca69d('0x11')]?_0x40224f[_0x1ca69d('0x11')]['include']?_[_0x1ca69d('0x7')](_0x40224f[_0x1ca69d('0x11')][_0x1ca69d('0x0')],function(_0x562b85){const _0x3ebd33=_0x1ca69d;return{'model':db[_0x562b85[_0x3ebd33('0x10')]],'as':_0x562b85['as'],'attributes':_0x562b85['attributes'],'include':_0x562b85['include']?_[_0x3ebd33('0x7')](_0x562b85[_0x3ebd33('0x0')],function(_0x2de2eb){const _0x455643=_0x3ebd33;return{'model':db[_0x2de2eb[_0x455643('0x10')]],'as':_0x2de2eb['as'],'attributes':_0x2de2eb[_0x455643('0x3')],'include':_0x2de2eb['include']?_['map'](_0x2de2eb[_0x455643('0x0')],function(_0x23e482){const _0x5dae22=_0x455643;return{'model':db[_0x23e482[_0x5dae22('0x10')]],'as':_0x23e482['as'],'attributes':_0x23e482[_0x5dae22('0x3')]};}):[]};}):[]};}):[]:[]})[_0x1ca69d('0xd')](function(_0x402242){const _0xa439a9=_0x1ca69d;logger[_0xa439a9('0xe')]('GetTrunk',_0x40224f),logger[_0xa439a9('0xc')](_0xa439a9('0x8'),_0x40224f,JSON['stringify'](_0x402242)),_0x5c0ab6(_0x402242);})[_0x1ca69d('0x14')](function(_0x5f560f){const _0x303492=_0x1ca69d;logger[_0x303492('0x9')](_0x303492('0x8'),_0x5f560f['message'],_0x40224f),_0x27ea3d(_0x50649b['error'](0x1f4,_0x5f560f[_0x303492('0x1')]));});});},exports[_0x300af4('0xa')]=function(_0x269741){const _0x12cd95=this;return new Promise(function(_0x25d94f,_0x490bcc){const _0x371398=a645_0x4e85;return db[_0x371398('0x6')][_0x371398('0xf')]({'raw':_0x269741[_0x371398('0x11')]?_0x269741[_0x371398('0x11')][_0x371398('0x13')]===undefined?!![]:![]:!![],'where':_0x269741['options']?_0x269741['options'][_0x371398('0x4')]||null:null,'attributes':_0x269741[_0x371398('0x11')]?_0x269741[_0x371398('0x11')][_0x371398('0x3')]||null:null,'include':_0x269741[_0x371398('0x11')]?_0x269741['options'][_0x371398('0x0')]?_[_0x371398('0x7')](_0x269741[_0x371398('0x11')][_0x371398('0x0')],function(_0x540ca0){const _0x55bf85=_0x371398;return{'model':db[_0x540ca0[_0x55bf85('0x10')]],'as':_0x540ca0['as'],'attributes':_0x540ca0[_0x55bf85('0x3')],'include':_0x540ca0['include']?_[_0x55bf85('0x7')](_0x540ca0[_0x55bf85('0x0')],function(_0x5d34a8){const _0xf2595b=_0x55bf85;return{'model':db[_0x5d34a8['model']],'as':_0x5d34a8['as'],'attributes':_0x5d34a8[_0xf2595b('0x3')],'include':_0x5d34a8['include']?_[_0xf2595b('0x7')](_0x5d34a8[_0xf2595b('0x0')],function(_0x22da3b){const _0x2fbede=_0xf2595b;return{'model':db[_0x22da3b[_0x2fbede('0x10')]],'as':_0x22da3b['as'],'attributes':_0x22da3b[_0x2fbede('0x3')]};}):[]};}):[]};}):[]:[]})[_0x371398('0xd')](function(_0x54137e){const _0xac4cb6=_0x371398;logger[_0xac4cb6('0xe')](_0xac4cb6('0xa'),_0x269741),logger['debug'](_0xac4cb6('0xa'),_0x269741,JSON['stringify'](_0x54137e)),_0x25d94f(_0x54137e);})['catch'](function(_0xaa5e3e){const _0x1631eb=_0x371398;logger['error'](_0x1631eb('0xa'),_0xaa5e3e[_0x1631eb('0x1')],_0x269741),_0x490bcc(_0x12cd95[_0x1631eb('0x9')](0x1f4,_0xaa5e3e['message']));});});}; \ No newline at end of file +const a645_0x5c8f=['rpc','then','catch','../../mysqldb','map','GetTrunk','info','attributes','raw','include','findOne','model','error','limit','where','stringify','ShowTrunk','options','message','Trunk','debug','../../config/logger','lodash','findAll'];(function(_0x3a731d,_0x5c8ff8){const _0x745191=function(_0x372c3a){while(--_0x372c3a){_0x3a731d['push'](_0x3a731d['shift']());}};_0x745191(++_0x5c8ff8);}(a645_0x5c8f,0xcc));const a645_0x7451=function(_0x3a731d,_0x5c8ff8){_0x3a731d=_0x3a731d-0x0;let _0x745191=a645_0x5c8f[_0x3a731d];return _0x745191;};const _0x1214d6=a645_0x7451;'use strict';const _=require(_0x1214d6('0xa')),db=require(_0x1214d6('0xf'))['db'],logger=require(_0x1214d6('0x9'))(_0x1214d6('0xc'));exports[_0x1214d6('0x11')]=function(_0x372c3a){const _0x43ccc1=this;return new Promise(function(_0x1714f1,_0x4ec93d){const _0x21cdbb=a645_0x7451;return db[_0x21cdbb('0x7')][_0x21cdbb('0xb')]({'raw':_0x372c3a[_0x21cdbb('0x5')]?_0x372c3a['options']['raw']===undefined?!![]:![]:!![],'where':_0x372c3a[_0x21cdbb('0x5')]?_0x372c3a[_0x21cdbb('0x5')][_0x21cdbb('0x2')]||null:null,'attributes':_0x372c3a['options']?_0x372c3a[_0x21cdbb('0x5')]['attributes']||null:null,'limit':_0x372c3a[_0x21cdbb('0x5')]?_0x372c3a['options'][_0x21cdbb('0x1')]||null:null,'include':_0x372c3a[_0x21cdbb('0x5')]?_0x372c3a[_0x21cdbb('0x5')][_0x21cdbb('0x15')]?_[_0x21cdbb('0x10')](_0x372c3a[_0x21cdbb('0x5')]['include'],function(_0x48515a){const _0x3b275d=_0x21cdbb;return{'model':db[_0x48515a['model']],'as':_0x48515a['as'],'attributes':_0x48515a[_0x3b275d('0x13')],'include':_0x48515a[_0x3b275d('0x15')]?_[_0x3b275d('0x10')](_0x48515a[_0x3b275d('0x15')],function(_0x3dd1e0){const _0x18c2f4=_0x3b275d;return{'model':db[_0x3dd1e0[_0x18c2f4('0x17')]],'as':_0x3dd1e0['as'],'attributes':_0x3dd1e0[_0x18c2f4('0x13')],'include':_0x3dd1e0[_0x18c2f4('0x15')]?_[_0x18c2f4('0x10')](_0x3dd1e0[_0x18c2f4('0x15')],function(_0x5a2628){const _0x100530=_0x18c2f4;return{'model':db[_0x5a2628[_0x100530('0x17')]],'as':_0x5a2628['as'],'attributes':_0x5a2628[_0x100530('0x13')]};}):[]};}):[]};}):[]:[]})[_0x21cdbb('0xd')](function(_0x4c900f){const _0x4ec2dd=_0x21cdbb;logger[_0x4ec2dd('0x12')](_0x4ec2dd('0x11'),_0x372c3a),logger['debug']('GetTrunk',_0x372c3a,JSON[_0x4ec2dd('0x3')](_0x4c900f)),_0x1714f1(_0x4c900f);})[_0x21cdbb('0xe')](function(_0x712071){const _0x334cf0=_0x21cdbb;logger[_0x334cf0('0x0')](_0x334cf0('0x11'),_0x712071[_0x334cf0('0x6')],_0x372c3a),_0x4ec93d(_0x43ccc1[_0x334cf0('0x0')](0x1f4,_0x712071[_0x334cf0('0x6')]));});});},exports['ShowTrunk']=function(_0x1bae32){const _0x2436a2=this;return new Promise(function(_0x34432a,_0x3703eb){const _0x2f9758=a645_0x7451;return db[_0x2f9758('0x7')][_0x2f9758('0x16')]({'raw':_0x1bae32[_0x2f9758('0x5')]?_0x1bae32[_0x2f9758('0x5')][_0x2f9758('0x14')]===undefined?!![]:![]:!![],'where':_0x1bae32['options']?_0x1bae32['options'][_0x2f9758('0x2')]||null:null,'attributes':_0x1bae32[_0x2f9758('0x5')]?_0x1bae32['options']['attributes']||null:null,'include':_0x1bae32[_0x2f9758('0x5')]?_0x1bae32['options'][_0x2f9758('0x15')]?_[_0x2f9758('0x10')](_0x1bae32['options']['include'],function(_0x8533a7){const _0x32e6b7=_0x2f9758;return{'model':db[_0x8533a7[_0x32e6b7('0x17')]],'as':_0x8533a7['as'],'attributes':_0x8533a7[_0x32e6b7('0x13')],'include':_0x8533a7[_0x32e6b7('0x15')]?_['map'](_0x8533a7[_0x32e6b7('0x15')],function(_0x3dea71){const _0x37064c=_0x32e6b7;return{'model':db[_0x3dea71[_0x37064c('0x17')]],'as':_0x3dea71['as'],'attributes':_0x3dea71[_0x37064c('0x13')],'include':_0x3dea71[_0x37064c('0x15')]?_[_0x37064c('0x10')](_0x3dea71[_0x37064c('0x15')],function(_0x333ab7){const _0x3ff677=_0x37064c;return{'model':db[_0x333ab7[_0x3ff677('0x17')]],'as':_0x333ab7['as'],'attributes':_0x333ab7[_0x3ff677('0x13')]};}):[]};}):[]};}):[]:[]})[_0x2f9758('0xd')](function(_0x258046){const _0x1a2062=_0x2f9758;logger[_0x1a2062('0x12')](_0x1a2062('0x4'),_0x1bae32),logger[_0x1a2062('0x8')](_0x1a2062('0x4'),_0x1bae32,JSON[_0x1a2062('0x3')](_0x258046)),_0x34432a(_0x258046);})['catch'](function(_0xb77394){const _0x5ab6a8=_0x2f9758;logger[_0x5ab6a8('0x0')](_0x5ab6a8('0x4'),_0xb77394[_0x5ab6a8('0x6')],_0x1bae32),_0x3703eb(_0x2436a2[_0x5ab6a8('0x0')](0x1f4,_0xb77394[_0x5ab6a8('0x6')]));});});}; \ No newline at end of file diff --git a/server/api/user/index.js b/server/api/user/index.js index d07fcda..d89db99 100644 --- a/server/api/user/index.js +++ b/server/api/user/index.js @@ -1 +1 @@ -const a646_0x507a=['getOpenchannelAccounts','getScreenRecordings','now','/:id/mail_interactions','getChatWebsites','post','addFaxInteractions','create','/:id','addSquareProjects','/:id/square_projects','addOpenchannelAccounts','removeChatInteractions','removeWhatsappInteractions','getFaxAccounts','/:id/recordings','removeFaxAccounts','/:id/fax_accounts','removeOpenchannelAccounts','put','login','delete','/:id/chat_interactions','/:id/mail_accounts','/:id/whatsapp_interactions','/:id/groups','getQueues','addAvatar','getMailInteractions','removeTeams','addWhatsappAccounts','removeChatWebsites','getWhatsappAccounts','getFaxInteractions','../../config/environment','show','/:id/whatsapp/interactions','removeMailInteractions','removeSquareProjects','pause','/:id/chat/interactions','/:id/api_key','/:id/logout','single','getAvatar','get','removeOpenchannelInteractions','createApiKey','%s-%s','destroy','getTeams','removeQueues','/:id/openchannel_interactions','/:id/sms_interactions','getApiKey','/:id/scheduled_calls','join','getVoiceQueuesRt','/:id/lists','/:id/prefixes','index','/describe','getContacts','removeSmsAccounts','getAgents','/:id/fax_interactions','/:id/sms_accounts','whoami','/:id/contacts','express','/:id/queues_rt','removeApiKey','removeFaxInteractions','getRecordings','describe','/:id/fax/interactions','/:id/openchannel_accounts','/:id/teams','diskStorage','../../components/auth/service','getScheduledCalls','getWhatsappInteractions','getMailAccounts','getVoicePrefixes','/:id/pause','getChatInteractions','/:id/unpause','path','/:id/chat_websites','addChatWebsites','isAuthenticated','update','/:id/sms/interactions','unpause','removeMailAccounts','/:id/password','/:id/screen_recordings','util','/whoami','addChatInteractions','bulkCreate','/:id/mail/interactions','/:id/avatar','getGroups','/:id/whatsapp_accounts','addSmsAccounts','/:id/openchannel/interactions','getSmsInteractions','addTeams','/:id/login','getLists','/:id/queues','multer','changePassword'];(function(_0x163db4,_0x507aa1){const _0x462d3a=function(_0x52a6cb){while(--_0x52a6cb){_0x163db4['push'](_0x163db4['shift']());}};_0x462d3a(++_0x507aa1);}(a646_0x507a,0x1a6));const a646_0x462d=function(_0x163db4,_0x507aa1){_0x163db4=_0x163db4-0x0;let _0x462d3a=a646_0x507a[_0x163db4];return _0x462d3a;};const _0x43a7e7=a646_0x462d;'use strict';const multer=require(_0x43a7e7('0x20')),util=require(_0x43a7e7('0x11')),path=require(_0x43a7e7('0x7')),express=require(_0x43a7e7('0x67')),router=express['Router'](),auth=require(_0x43a7e7('0x71')),config=require(_0x43a7e7('0x44')),controller=require('./user.controller');router[_0x43a7e7('0x4f')]('/',auth['isAuthenticated'](),controller[_0x43a7e7('0x5e')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x5f'),auth['isAuthenticated'](),controller[_0x43a7e7('0x6c')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x12'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x65')]),router[_0x43a7e7('0x4f')]('/:id',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x45')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x16'),controller[_0x43a7e7('0x4e')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x66'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x60')]),router['get'](_0x43a7e7('0x1f'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x3c')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x68'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x5b')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x3b'),auth['isAuthenticated'](),controller[_0x43a7e7('0x17')]),router['get'](_0x43a7e7('0x31'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x6b')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x10'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x23')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x4a'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x5')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x1a'),auth[_0x43a7e7('0xa')](),controller['getOpenchannelInteractions']),router[_0x43a7e7('0x4f')](_0x43a7e7('0x15'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x3e')]),router['get'](_0x43a7e7('0xc'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x1b')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x6d'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x43')]),router['get'](_0x43a7e7('0x46'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x1')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x6f'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x54')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x5c'),auth['isAuthenticated'](),controller[_0x43a7e7('0x1e')]),router[_0x43a7e7('0x4f')]('/:id/agents',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x62')]),router['get'](_0x43a7e7('0x5d'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x3')]),router[_0x43a7e7('0x4f')]('/:id/fax_accounts',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x30')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x39'),auth['isAuthenticated'](),controller[_0x43a7e7('0x2')]),router['get'](_0x43a7e7('0x6e'),auth['isAuthenticated'](),controller[_0x43a7e7('0x22')]),router['get'](_0x43a7e7('0x64'),auth[_0x43a7e7('0xa')](),controller['getSmsAccounts']),router[_0x43a7e7('0x4f')](_0x43a7e7('0x8'),auth['isAuthenticated'](),controller[_0x43a7e7('0x26')]),router[_0x43a7e7('0x4f')]('/:id/whatsapp_accounts',auth['isAuthenticated'](),controller[_0x43a7e7('0x42')]),router[_0x43a7e7('0x4f')](_0x43a7e7('0x2c'),auth[_0x43a7e7('0xa')](),controller['getSquareProjects']),router[_0x43a7e7('0x4f')](_0x43a7e7('0x59'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x0')]),router[_0x43a7e7('0x4f')]('/:id/api_key',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x58')]),router['post'](_0x43a7e7('0x66'),auth['isAuthenticated'](),controller['addContacts']),router[_0x43a7e7('0x27')]('/',auth['isAuthenticated'](),controller[_0x43a7e7('0x29')]),router['post']('/create_many',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x14')]),router[_0x43a7e7('0x27')](_0x43a7e7('0x1f'),auth[_0x43a7e7('0xa')](),controller['addQueues']);const upload=multer({'storage':multer[_0x43a7e7('0x70')]({'destination':function(_0x52a6cb,_0x3584bb,_0x41b0f5){const _0x2c08e5=_0x43a7e7;_0x41b0f5(null,path[_0x2c08e5('0x5a')](config['root'],'files/images/'));},'filename':function(_0x339bf8,_0x3ce96a,_0x267cfe){const _0x173444=_0x43a7e7;_0x267cfe(null,util['format'](_0x173444('0x52'),Date[_0x173444('0x24')](),_0x3ce96a['originalname']));}})});router[_0x43a7e7('0x27')](_0x43a7e7('0x16'),upload[_0x43a7e7('0x4d')]('file'),controller[_0x43a7e7('0x3d')]),router[_0x43a7e7('0x27')](_0x43a7e7('0x1d'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x36')]),router[_0x43a7e7('0x27')](_0x43a7e7('0x4c'),auth[_0x43a7e7('0xa')](),controller['logout']),router['post'](_0x43a7e7('0x4'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x49')]),router['post'](_0x43a7e7('0x6'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0xd')]),router[_0x43a7e7('0x27')]('/:id/teams',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x1c')]),router[_0x43a7e7('0x27')]('/:id/chat_interactions',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x13')]),router['post'](_0x43a7e7('0x25'),auth[_0x43a7e7('0xa')](),controller['addMailInteractions']),router[_0x43a7e7('0x27')](_0x43a7e7('0x63'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x28')]),router[_0x43a7e7('0x27')](_0x43a7e7('0x57'),auth[_0x43a7e7('0xa')](),controller['addSmsInteractions']),router[_0x43a7e7('0x27')](_0x43a7e7('0x56'),auth[_0x43a7e7('0xa')](),controller['addOpenchannelInteractions']),router['post'](_0x43a7e7('0x3a'),auth[_0x43a7e7('0xa')](),controller['addWhatsappInteractions']),router[_0x43a7e7('0x27')](_0x43a7e7('0x33'),auth[_0x43a7e7('0xa')](),controller['addFaxAccounts']),router[_0x43a7e7('0x27')](_0x43a7e7('0x39'),auth[_0x43a7e7('0xa')](),controller['addMailAccounts']),router['post']('/:id/openchannel_accounts',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x2d')]),router[_0x43a7e7('0x27')]('/:id/sms_accounts',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x19')]),router[_0x43a7e7('0x27')](_0x43a7e7('0x8'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x9')]),router['post']('/:id/whatsapp_accounts',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x40')]),router[_0x43a7e7('0x27')]('/:id/square_projects',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x2b')]),router[_0x43a7e7('0x27')]('/:id/api_key',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x51')]),router['put'](_0x43a7e7('0x2a'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0xb')]),router[_0x43a7e7('0x35')](_0x43a7e7('0xf'),auth['isAuthenticated'](),controller[_0x43a7e7('0x21')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x1f'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x55')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x6f'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x3f')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x2a'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x53')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x38'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x2e')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x25'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x47')]),router[_0x43a7e7('0x37')]('/:id/fax_interactions',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x6a')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x57'),auth[_0x43a7e7('0xa')](),controller['removeSmsInteractions']),router[_0x43a7e7('0x37')]('/:id/openchannel_interactions',auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x50')]),router['delete']('/:id/whatsapp_interactions',auth['isAuthenticated'](),controller[_0x43a7e7('0x2f')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x33'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x32')]),router['delete']('/:id/mail_accounts',auth['isAuthenticated'](),controller[_0x43a7e7('0xe')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x6e'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x34')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x64'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x61')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x8'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x41')]),router[_0x43a7e7('0x37')](_0x43a7e7('0x18'),auth[_0x43a7e7('0xa')](),controller['removeWhatsappAccounts']),router[_0x43a7e7('0x37')](_0x43a7e7('0x2c'),auth[_0x43a7e7('0xa')](),controller[_0x43a7e7('0x48')]),router['delete'](_0x43a7e7('0x4b'),auth['isAuthenticated'](),controller[_0x43a7e7('0x69')]),module['exports']=router; \ No newline at end of file +const a646_0x2d0f=['removeFaxAccounts','logout','originalname','removeQueues','/:id/mail_accounts','post','/:id/lists','/:id/login','/:id/unpause','/:id/fax/interactions','removeSmsInteractions','bulkCreate','/:id/openchannel/interactions','getOpenchannelAccounts','/:id/teams','removeOpenchannelInteractions','file','getTeams','/:id/api_key','/:id/queues','createApiKey','/:id/groups','../../config/environment','addOpenchannelAccounts','/:id/sms_accounts','get','getMailInteractions','getAgents','addSquareProjects','getApiKey','getRecordings','/:id/queues_rt','/:id/agents','/:id/mail_interactions','/:id/whatsapp_interactions','/:id/whatsapp/interactions','pause','/:id','/:id/scheduled_calls','put','getFaxAccounts','addWhatsappInteractions','/:id/password','express','/:id/contacts','index','login','removeChatWebsites','getFaxInteractions','getChatInteractions','getWhatsappAccounts','/:id/fax_accounts','/:id/square_projects','unpause','root','show','delete','addChatInteractions','getChatWebsites','files/images/','join','removeApiKey','/whoami','addMailInteractions','addSmsInteractions','addContacts','getSmsAccounts','/:id/logout','/:id/openchannel_accounts','addSmsAccounts','single','multer','removeTeams','/:id/chat_websites','/:id/openchannel_interactions','/:id/prefixes','getVoiceQueuesRt','util','getAvatar','isAuthenticated','now','../../components/auth/service','addMailAccounts','addFaxInteractions','removeOpenchannelAccounts','describe','/:id/sms/interactions','/:id/screen_recordings','/:id/avatar','addFaxAccounts','/:id/fax_interactions','diskStorage','removeChatInteractions','getGroups','/:id/sms_interactions','removeSmsAccounts','/:id/whatsapp_accounts','getLists','/:id/chat_interactions','update','addWhatsappAccounts','./user.controller','getScheduledCalls','removeFaxInteractions'];(function(_0x171265,_0x2d0fff){const _0x225a1c=function(_0x46cf48){while(--_0x46cf48){_0x171265['push'](_0x171265['shift']());}};_0x225a1c(++_0x2d0fff);}(a646_0x2d0f,0x132));const a646_0x225a=function(_0x171265,_0x2d0fff){_0x171265=_0x171265-0x0;let _0x225a1c=a646_0x2d0f[_0x171265];return _0x225a1c;};const _0x320f21=a646_0x225a;'use strict';const multer=require(_0x320f21('0x4d')),util=require(_0x320f21('0x53')),path=require('path'),express=require(_0x320f21('0x31')),router=express['Router'](),auth=require(_0x320f21('0x57')),config=require(_0x320f21('0x1c')),controller=require(_0x320f21('0x3'));router[_0x320f21('0x1f')]('/',auth[_0x320f21('0x55')](),controller[_0x320f21('0x33')]),router[_0x320f21('0x1f')]('/describe',auth[_0x320f21('0x55')](),controller[_0x320f21('0x5b')]),router[_0x320f21('0x1f')](_0x320f21('0x44'),auth['isAuthenticated'](),controller['whoami']),router[_0x320f21('0x1f')]('/:id',auth[_0x320f21('0x55')](),controller[_0x320f21('0x3d')]),router[_0x320f21('0x1f')](_0x320f21('0x5e'),controller[_0x320f21('0x54')]),router[_0x320f21('0x1f')]('/:id/contacts',auth[_0x320f21('0x55')](),controller['getContacts']),router[_0x320f21('0x1f')](_0x320f21('0x19'),auth['isAuthenticated'](),controller['getQueues']),router[_0x320f21('0x1f')](_0x320f21('0x25'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x52')]),router['get'](_0x320f21('0x1b'),auth['isAuthenticated'](),controller[_0x320f21('0x63')]),router[_0x320f21('0x1f')]('/:id/recordings',auth[_0x320f21('0x55')](),controller[_0x320f21('0x24')]),router[_0x320f21('0x1f')](_0x320f21('0x5d'),auth[_0x320f21('0x55')](),controller['getScreenRecordings']),router[_0x320f21('0x1f')]('/:id/chat/interactions',auth[_0x320f21('0x55')](),controller[_0x320f21('0x37')]),router[_0x320f21('0x1f')](_0x320f21('0x12'),auth['isAuthenticated'](),controller['getOpenchannelInteractions']),router['get']('/:id/mail/interactions',auth[_0x320f21('0x55')](),controller[_0x320f21('0x20')]),router['get'](_0x320f21('0x5c'),auth['isAuthenticated'](),controller['getSmsInteractions']),router[_0x320f21('0x1f')](_0x320f21('0xf'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x36')]),router[_0x320f21('0x1f')](_0x320f21('0x29'),auth['isAuthenticated'](),controller['getWhatsappInteractions']),router['get'](_0x320f21('0x14'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x17')]),router[_0x320f21('0x1f')](_0x320f21('0xc'),auth['isAuthenticated'](),controller[_0x320f21('0x67')]),router[_0x320f21('0x1f')](_0x320f21('0x26'),auth['isAuthenticated'](),controller[_0x320f21('0x21')]),router['get'](_0x320f21('0x51'),auth[_0x320f21('0x55')](),controller['getVoicePrefixes']),router[_0x320f21('0x1f')](_0x320f21('0x39'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x2e')]),router[_0x320f21('0x1f')](_0x320f21('0xa'),auth[_0x320f21('0x55')](),controller['getMailAccounts']),router[_0x320f21('0x1f')](_0x320f21('0x4a'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x13')]),router['get'](_0x320f21('0x1e'),auth['isAuthenticated'](),controller[_0x320f21('0x48')]),router[_0x320f21('0x1f')]('/:id/chat_websites',auth[_0x320f21('0x55')](),controller[_0x320f21('0x40')]),router['get']('/:id/whatsapp_accounts',auth[_0x320f21('0x55')](),controller[_0x320f21('0x38')]),router[_0x320f21('0x1f')](_0x320f21('0x3a'),auth['isAuthenticated'](),controller['getSquareProjects']),router[_0x320f21('0x1f')](_0x320f21('0x2c'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x4')]),router[_0x320f21('0x1f')]('/:id/api_key',auth[_0x320f21('0x55')](),controller[_0x320f21('0x23')]),router[_0x320f21('0xb')](_0x320f21('0x32'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x47')]),router['post']('/',auth[_0x320f21('0x55')](),controller['create']),router[_0x320f21('0xb')]('/create_many',auth[_0x320f21('0x55')](),controller[_0x320f21('0x11')]),router[_0x320f21('0xb')](_0x320f21('0x19'),auth[_0x320f21('0x55')](),controller['addQueues']);const upload=multer({'storage':multer[_0x320f21('0x61')]({'destination':function(_0x46cf48,_0x1e5ef0,_0x29a8b){const _0x497a00=_0x320f21;_0x29a8b(null,path[_0x497a00('0x42')](config[_0x497a00('0x3c')],_0x497a00('0x41')));},'filename':function(_0x3f10f7,_0x660b9a,_0x7de4f3){const _0x19d664=_0x320f21;_0x7de4f3(null,util['format']('%s-%s',Date[_0x19d664('0x56')](),_0x660b9a[_0x19d664('0x8')]));}})});router['post']('/:id/avatar',upload[_0x320f21('0x4c')](_0x320f21('0x16')),controller['addAvatar']),router['post'](_0x320f21('0xd'),auth['isAuthenticated'](),controller[_0x320f21('0x34')]),router[_0x320f21('0xb')](_0x320f21('0x49'),auth['isAuthenticated'](),controller[_0x320f21('0x7')]),router['post']('/:id/pause',auth['isAuthenticated'](),controller[_0x320f21('0x2a')]),router[_0x320f21('0xb')](_0x320f21('0xe'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x3b')]),router[_0x320f21('0xb')](_0x320f21('0x14'),auth[_0x320f21('0x55')](),controller['addTeams']),router[_0x320f21('0xb')](_0x320f21('0x0'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x3f')]),router[_0x320f21('0xb')](_0x320f21('0x27'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x45')]),router[_0x320f21('0xb')](_0x320f21('0x60'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x59')]),router['post'](_0x320f21('0x64'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x46')]),router[_0x320f21('0xb')](_0x320f21('0x50'),auth[_0x320f21('0x55')](),controller['addOpenchannelInteractions']),router['post'](_0x320f21('0x28'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x2f')]),router[_0x320f21('0xb')](_0x320f21('0x39'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x5f')]),router[_0x320f21('0xb')]('/:id/mail_accounts',auth[_0x320f21('0x55')](),controller[_0x320f21('0x58')]),router[_0x320f21('0xb')]('/:id/openchannel_accounts',auth[_0x320f21('0x55')](),controller[_0x320f21('0x1d')]),router[_0x320f21('0xb')]('/:id/sms_accounts',auth[_0x320f21('0x55')](),controller[_0x320f21('0x4b')]),router[_0x320f21('0xb')](_0x320f21('0x4f'),auth[_0x320f21('0x55')](),controller['addChatWebsites']),router[_0x320f21('0xb')](_0x320f21('0x66'),auth['isAuthenticated'](),controller[_0x320f21('0x2')]),router[_0x320f21('0xb')]('/:id/square_projects',auth[_0x320f21('0x55')](),controller[_0x320f21('0x22')]),router[_0x320f21('0xb')]('/:id/api_key',auth[_0x320f21('0x55')](),controller[_0x320f21('0x1a')]),router[_0x320f21('0x2d')](_0x320f21('0x2b'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x1')]),router[_0x320f21('0x2d')](_0x320f21('0x30'),auth[_0x320f21('0x55')](),controller['changePassword']),router[_0x320f21('0x3e')](_0x320f21('0x19'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x9')]),router[_0x320f21('0x3e')](_0x320f21('0x14'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x4e')]),router['delete'](_0x320f21('0x2b'),auth[_0x320f21('0x55')](),controller['destroy']),router[_0x320f21('0x3e')]('/:id/chat_interactions',auth[_0x320f21('0x55')](),controller[_0x320f21('0x62')]),router[_0x320f21('0x3e')](_0x320f21('0x27'),auth[_0x320f21('0x55')](),controller['removeMailInteractions']),router[_0x320f21('0x3e')](_0x320f21('0x60'),auth['isAuthenticated'](),controller[_0x320f21('0x5')]),router[_0x320f21('0x3e')](_0x320f21('0x64'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x10')]),router[_0x320f21('0x3e')](_0x320f21('0x50'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x15')]),router[_0x320f21('0x3e')](_0x320f21('0x28'),auth[_0x320f21('0x55')](),controller['removeWhatsappInteractions']),router[_0x320f21('0x3e')]('/:id/fax_accounts',auth[_0x320f21('0x55')](),controller[_0x320f21('0x6')]),router[_0x320f21('0x3e')](_0x320f21('0xa'),auth['isAuthenticated'](),controller['removeMailAccounts']),router['delete'](_0x320f21('0x4a'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x5a')]),router[_0x320f21('0x3e')]('/:id/sms_accounts',auth[_0x320f21('0x55')](),controller[_0x320f21('0x65')]),router[_0x320f21('0x3e')](_0x320f21('0x4f'),auth[_0x320f21('0x55')](),controller[_0x320f21('0x35')]),router[_0x320f21('0x3e')](_0x320f21('0x66'),auth['isAuthenticated'](),controller['removeWhatsappAccounts']),router[_0x320f21('0x3e')](_0x320f21('0x3a'),auth[_0x320f21('0x55')](),controller['removeSquareProjects']),router[_0x320f21('0x3e')](_0x320f21('0x18'),auth['isAuthenticated'](),controller[_0x320f21('0x43')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/user/user.attributes.js b/server/api/user/user.attributes.js index a3be04a..47388ca 100644 --- a/server/api/user/user.attributes.js +++ b/server/api/user/user.attributes.js @@ -1 +1 @@ -const a647_0x26d8=['refuse','force_avp','join','user','isArray','PROHIB_NOT_SCREENED','defaultuser','ALLOWED','avpf','BOOLEAN','agent','udp','friend','dtlsverify','internal','setDataValue','telephone','PROHIB_PASSED_SCREEN','accept','fullname','auto','\x22%s\x22\x20<%s>','ALLOWED_FAILED_SCREEN','yes','showWebBar','VIRTUAL','phoneBarEnableScreenRecordingByAgent','name','blockedAt','wss','active','update','INTEGER','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22force_rport\x22,\x20\x22comedia\x22]','The\x20name\x20of\x20the\x20user','screenrecording','callerid','allow','ALLOWED_PASSED_SCREEN','admin','getDataValue','force_rport,comedia','insecure','STRING','encryption','from-sip','blocked','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22udp\x22,\x20\x22tcp\x22]','rfc2833','dtlscertfile','PROHIB_FAILED_SCREEN','passive','map','string','exports','dtlssetup','all','false','info','update,nonat','dtlsenable','ulaw;alaw;gsm','actpass','local','lodash','always','icesupport','split','permissions','nat','ENUM','moment','sequelize','transport','format','fingerprint','nonat','uac','get','\x22\x22\x20<>','dtlsprivatekey','certificate','/etc/pki/tls/private/motion.key','rtcp_mux','/etc/pki/tls/certs/motion.crt','TEXT','email','DATE','PROHIB','uas'];(function(_0x10901d,_0x26d848){const _0x9c118=function(_0x4b372a){while(--_0x4b372a){_0x10901d['push'](_0x10901d['shift']());}};_0x9c118(++_0x26d848);}(a647_0x26d8,0x1b2));const a647_0x9c11=function(_0x10901d,_0x26d848){_0x10901d=_0x10901d-0x0;let _0x9c118=a647_0x26d8[_0x10901d];return _0x9c118;};const _0x2774ec=a647_0x9c11;'use strict';const Sequelize=require(_0x2774ec('0x58')),moment=require(_0x2774ec('0x57')),util=require('util'),_=require(_0x2774ec('0x50'));module[_0x2774ec('0x46')]={'name':{'type':Sequelize['STRING'],'allowNull':![],'unique':'name','validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i},'set':function(_0x4b372a){const _0x3a7cae=_0x2774ec;this['setDataValue'](_0x3a7cae('0x2b'),_0x4b372a),this['setDataValue'](_0x3a7cae('0x16'),_0x4b372a);},'comment':_0x2774ec('0x32')},'fullname':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':![],'set':function(_0x5f1211){const _0x1eba6a=_0x2774ec;this['setDataValue'](_0x1eba6a('0x23'),_0x5f1211),this[_0x1eba6a('0x1f')](_0x1eba6a('0x34'),util[_0x1eba6a('0x0')](_0x1eba6a('0x25'),_0x5f1211,this['getDataValue'](_0x1eba6a('0x1e'))));}},'alias':{'type':Sequelize[_0x2774ec('0x3b')]},'email':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':![],'unique':_0x2774ec('0xc'),'validate':{'isEmail':!![]},'set':function(_0x33a1c8){const _0x3a2d20=_0x2774ec;_0x33a1c8&&this[_0x3a2d20('0x1f')]('email',_0x33a1c8['toLowerCase']());}},'role':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x37'),_0x2774ec('0x13'),_0x2774ec('0x1a'),_0x2774ec('0x20')),'allowNull':![]},'password':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':![],'validate':{'notEmpty':!![]}},'provider':{'type':Sequelize[_0x2774ec('0x3b')],'defaultValue':_0x2774ec('0x4f')},'internal':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':![],'unique':_0x2774ec('0x1e'),'set':function(_0x18c2b7){const _0xe62a2=_0x2774ec;this[_0xe62a2('0x1f')]('internal',_0x18c2b7),this[_0xe62a2('0x1f')]('accountcode',_0x18c2b7),this['setDataValue'](_0xe62a2('0x34'),util['format'](_0xe62a2('0x25'),this[_0xe62a2('0x38')]('fullname'),_0x18c2b7));}},'salt':{'type':Sequelize[_0x2774ec('0x3b')]},'phone':{'type':Sequelize[_0x2774ec('0x3b')]},'mobile':{'type':Sequelize[_0x2774ec('0x3b')]},'address':{'type':Sequelize[_0x2774ec('0x3b')]},'zipcode':{'type':Sequelize['STRING']},'userpic':{'type':Sequelize['STRING']},'city':{'type':Sequelize[_0x2774ec('0x3b')]},'country':{'type':Sequelize['STRING']},'online':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'lastLoginAt':{'type':Sequelize[_0x2774ec('0xd')]},'voicePause':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'chatPause':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'mailPause':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'faxPause':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'smsPause':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'whatsappPause':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'openchannelPause':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'pauseType':{'type':Sequelize['STRING'],'defaultValue':'DEFAULT\x20PAUSE'},'lastPauseAt':{'type':Sequelize[_0x2774ec('0xd')]},'chatCapacity':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'mailCapacity':{'type':Sequelize[_0x2774ec('0x30')],'defaultValue':0x0},'faxCapacity':{'type':Sequelize[_0x2774ec('0x30')],'defaultValue':0x0},'smsCapacity':{'type':Sequelize[_0x2774ec('0x30')],'defaultValue':0x0},'whatsappCapacity':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'openchannelCapacity':{'type':Sequelize[_0x2774ec('0x30')],'defaultValue':0x0},'phoneBarAutoAnswer':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'phoneBarEnableSettings':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'phoneBarListenPort':{'type':Sequelize[_0x2774ec('0x30')](0x5),'defaultValue':0x1428},'phoneBarExpires':{'type':Sequelize['INTEGER'](0x5),'defaultValue':0x78},'phoneBarRemoteControl':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'phoneBarRemoteControlPort':{'type':Sequelize['INTEGER'],'defaultValue':0x26a0},'phoneBarEnableRecording':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'phoneBarRingInUse':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'chanspy':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'description':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'host':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![],'defaultValue':'dynamic'},'ipaddr':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'port':{'type':Sequelize[_0x2774ec('0x30')](0x5),'allowNull':!![]},'regseconds':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'fullcontact':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'regserver':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'useragent':{'type':Sequelize['STRING'],'allowNull':!![]},'lastms':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'type':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x1c'),_0x2774ec('0x13'),'peer'),'allowNull':!![],'defaultValue':'friend'},'context':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![],'defaultValue':_0x2774ec('0x3d')},'callingpres':{'type':Sequelize['ENUM']('ALLOWED_NOT_SCREENED',_0x2774ec('0x36'),_0x2774ec('0x26'),_0x2774ec('0x17'),_0x2774ec('0x15'),_0x2774ec('0x21'),_0x2774ec('0x42'),_0x2774ec('0xe')),'allowNull':!![]},'deny':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'permit':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'secret':{'type':Sequelize['STRING'],'allowNull':!![]},'md5secret':{'type':Sequelize['STRING'],'allowNull':!![]},'remotesecret':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'transport':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![],'defaultValue':'udp','set':function(_0x298ca2){const _0x117365=_0x2774ec;this[_0x117365('0x1f')](_0x117365('0x59'),_0x298ca2?_0x298ca2['join'](','):null);},'get':function(){const _0x3a603e=_0x2774ec;return this[_0x3a603e('0x38')](_0x3a603e('0x59'))?this['getDataValue']('transport')[_0x3a603e('0x53')](','):null;},'comment':_0x2774ec('0x3f')},'dtmfmode':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x40'),_0x2774ec('0x4a'),'shortinfo','inband',_0x2774ec('0x24')),'allowNull':!![],'defaultValue':'rfc2833'},'directmedia':{'type':Sequelize[_0x2774ec('0x56')]('yes','no',_0x2774ec('0x2'),_0x2774ec('0x2f'),'outgoing'),'allowNull':!![],'defaultValue':'no'},'directrtpsetup':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![],'defaultValue':'no'},'directmediapermit':{'type':Sequelize['STRING'],'allowNull':!![]},'directmediadeny':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'nat':{'type':Sequelize['STRING'],'allowNull':!![],'defaultValue':_0x2774ec('0x39'),'set':function(_0xf43fe0){const _0x46de25=_0x2774ec;this[_0x46de25('0x1f')](_0x46de25('0x55'),_0xf43fe0?_0xf43fe0[_0x46de25('0x12')](','):null);},'get':function(){const _0x3611ae=_0x2774ec;return this[_0x3611ae('0x38')](_0x3611ae('0x55'))?this['getDataValue']('nat')[_0x3611ae('0x53')](','):null;},'comment':_0x2774ec('0x31')},'callgroup':{'type':Sequelize['STRING']},'namedcallgroup':{'type':Sequelize[_0x2774ec('0x3b')]},'pickupgroup':{'type':Sequelize[_0x2774ec('0x3b')]},'namedpickupgroup':{'type':Sequelize[_0x2774ec('0x3b')]},'language':{'type':Sequelize[_0x2774ec('0x3b')],'defaultValue':'en'},'tonezone':{'type':Sequelize['STRING']},'disallow':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':![],'defaultValue':_0x2774ec('0x48')},'allow':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x2774ec('0x4d'),'set':function(_0x4343ec){const _0x52ed1b=_0x2774ec;this['setDataValue'](_0x52ed1b('0x35'),_0x4343ec?_0x4343ec[_0x52ed1b('0x12')](';'):'ulaw;alaw;gsm');},'get':function(){const _0x327443=_0x2774ec;return this['getDataValue'](_0x327443('0x35'))?this[_0x327443('0x38')](_0x327443('0x35'))[_0x327443('0x53')](';'):null;},'comment':'String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22ulaw\x22,\x20\x22alaw\x22,\x20\x22gsm\x22]'},'autoframing':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![]},'insecure':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![],'set':function(_0x24833e){const _0x422929=_0x2774ec;this[_0x422929('0x1f')](_0x422929('0x3a'),_0x24833e?_0x24833e[_0x422929('0x12')](','):null);},'get':function(){const _0x390a68=_0x2774ec;return this[_0x390a68('0x38')]('insecure')?this['getDataValue'](_0x390a68('0x3a'))[_0x390a68('0x53')](','):null;},'comment':'String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22port\x22,\x20\x22invite\x22]'},'trustrpid':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![],'defaultValue':'no'},'trust_id_outbound':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![],'defaultValue':'no'},'progressinband':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no','never'),'allowNull':!![]},'promiscredir':{'type':Sequelize['ENUM'](_0x2774ec('0x27'),'no'),'allowNull':!![]},'useclientcode':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![]},'accountcode':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'setvar':{'type':Sequelize['STRING'],'allowNull':!![]},'callerid':{'type':Sequelize['STRING'],'allowNull':!![],'defaultValue':_0x2774ec('0x5')},'amaflags':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'callcounter':{'type':Sequelize[_0x2774ec('0x56')]('yes','no'),'allowNull':!![],'defaultValue':_0x2774ec('0x27')},'busylevel':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'allowoverlap':{'type':Sequelize['ENUM']('yes','no'),'allowNull':!![]},'allowsubscribe':{'type':Sequelize['ENUM'](_0x2774ec('0x27'),'no'),'allowNull':!![]},'allowtransfer':{'type':Sequelize['ENUM'](_0x2774ec('0x27'),'no'),'allowNull':!![]},'ignoresdpversion':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![]},'subscribecontext':{'type':Sequelize['STRING'],'allowNull':!![]},'template':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'videosupport':{'type':Sequelize['ENUM'](_0x2774ec('0x27'),'no',_0x2774ec('0x51')),'allowNull':!![],'defaultValue':'no'},'maxcallbitrate':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'rfc2833compensate':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![]},'mailbox':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'session_timers':{'type':Sequelize['ENUM'](_0x2774ec('0x22'),_0x2774ec('0x10'),'originate'),'allowNull':!![]},'session_expires':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'session_minse':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'session_refresher':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x3'),_0x2774ec('0xf')),'allowNull':!![],'defaultValue':_0x2774ec('0xf')},'t38pt_usertpsource':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'regexten':{'type':Sequelize['STRING'],'allowNull':!![]},'fromdomain':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'fromuser':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'qualify':{'type':Sequelize[_0x2774ec('0x56')]('yes','no'),'allowNull':!![],'defaultValue':_0x2774ec('0x27')},'keepalive':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'defaultip':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'defaultuser':{'type':Sequelize['STRING'],'allowNull':!![]},'rtptimeout':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'rtpholdtimeout':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'rtpkeepalive':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'sendrpid':{'type':Sequelize[_0x2774ec('0x56')]('yes','no'),'allowNull':!![],'defaultValue':'no'},'outboundproxy':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'callbackextension':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'timert1':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'timerb':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'qualifyfreq':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'contactpermit':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'contactdeny':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'contactacl':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'unsolicited_mailbox':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'use_q850_reason':{'type':Sequelize['STRING'],'allowNull':!![]},'maxforwards':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'encryption':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![],'defaultValue':'no'},'avpf':{'type':Sequelize[_0x2774ec('0x56')]('yes','no'),'allowNull':!![]},'force_avp':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![]},'icesupport':{'type':Sequelize['ENUM'](_0x2774ec('0x27'),'no'),'allowNull':!![]},'dtlsenable':{'type':Sequelize['ENUM'](_0x2774ec('0x27'),'no'),'allowNull':!![]},'dtlsverify':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no',_0x2774ec('0x1'),_0x2774ec('0x7')),'allowNull':!![]},'dtlsrekey':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![]},'dtlscertfile':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'dtlsprivatekey':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'dtlscipher':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'dtlscafile':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'dtlscapath':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'dtlssetup':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x2e'),_0x2774ec('0x43'),_0x2774ec('0x4e')),'allowNull':!![]},'dtlsfingerprint':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'usereqphone':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![],'defaultValue':'no'},'recordonfeature':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'recordofffeature':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'call_limit':{'type':Sequelize[_0x2774ec('0x30')](0xb),'allowNull':!![],'defaultValue':0xa},'registertrying':{'type':Sequelize['ENUM'](_0x2774ec('0x27'),'no'),'allowNull':!![]},'subscribemwi':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no'),'allowNull':!![]},'vmexten':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'mohinterpret':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'mohsuggest':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'parkinglot':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'canreinvite':{'type':Sequelize[_0x2774ec('0x56')](_0x2774ec('0x27'),'no',_0x2774ec('0x2'),_0x2774ec('0x2f'),_0x2774ec('0x4b')),'allowNull':!![],'defaultValue':'no'},'loginInPause':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'resetPasswordToken':{'type':Sequelize[_0x2774ec('0x3b')]},'resetPasswordExpires':{'type':Sequelize[_0x2774ec('0xd')]},'passwordResetAt':{'type':Sequelize[_0x2774ec('0xd')],'defaultValue':null},'previousPasswords':{'type':Sequelize[_0x2774ec('0x3b')]},'showWebBar':{'type':Sequelize[_0x2774ec('0x30')],'defaultValue':0x0,'set':function(_0x6a96a6){const _0x13faa8=_0x2774ec;this['setDataValue'](_0x13faa8('0x28'),_0x6a96a6);const _0x114d28=this[_0x13faa8('0x4')]({'plain':!![]});switch(_0x6a96a6){case 0x0:case 0x1:{let _0x25a7a4=_0x114d28[_0x13faa8('0x59')]?_[_0x13faa8('0x14')](_0x114d28[_0x13faa8('0x59')])?_0x114d28['transport'][_0x13faa8('0x12')]():_0x114d28[_0x13faa8('0x59')]:_0x13faa8('0x1b');_0x25a7a4==='wss'&&(_0x25a7a4='udp'),this[_0x13faa8('0x1f')]('transport',_0x25a7a4),this['setDataValue'](_0x13faa8('0x3c'),'no'),this[_0x13faa8('0x1f')](_0x13faa8('0x18'),null),this[_0x13faa8('0x1f')](_0x13faa8('0x11'),null),this[_0x13faa8('0x1f')]('icesupport',null),this[_0x13faa8('0x1f')](_0x13faa8('0x4c'),null),this['setDataValue'](_0x13faa8('0x1d'),null),this[_0x13faa8('0x1f')]('dtlssetup',null),this['setDataValue'](_0x13faa8('0x41'),null),this[_0x13faa8('0x1f')](_0x13faa8('0x6'),null),this[_0x13faa8('0x1f')]('rtcp_mux','no');}break;case 0x2:this[_0x13faa8('0x1f')](_0x13faa8('0x59'),_0x13faa8('0x2d')),this[_0x13faa8('0x1f')](_0x13faa8('0x3c'),'yes'),this['setDataValue'](_0x13faa8('0x18'),_0x13faa8('0x27')),this[_0x13faa8('0x1f')](_0x13faa8('0x11'),_0x13faa8('0x27')),this['setDataValue'](_0x13faa8('0x52'),_0x13faa8('0x27')),this[_0x13faa8('0x1f')]('dtlsenable',_0x13faa8('0x27')),this[_0x13faa8('0x1f')](_0x13faa8('0x1d'),'no'),this[_0x13faa8('0x1f')](_0x13faa8('0x47'),_0x13faa8('0x4e')),this[_0x13faa8('0x1f')]('dtlscertfile',_0x114d28[_0x13faa8('0x41')]||_0x13faa8('0xa')),this['setDataValue']('dtlsprivatekey',_0x114d28[_0x13faa8('0x6')]||_0x13faa8('0x8')),this['setDataValue'](_0x13faa8('0x9'),'yes');break;default:}}},'permissions':{'type':Sequelize[_0x2774ec('0xb')],'set':function(_0x4ab41c){const _0x423b54=_0x2774ec;this[_0x423b54('0x1f')](_0x423b54('0x54'),_0x4ab41c?_0x4ab41c[_0x423b54('0x12')](','):[]);},'get':function(){const _0x2eef93=_0x2774ec;return this[_0x2eef93('0x38')](_0x2eef93('0x54'))?_[_0x2eef93('0x44')](this[_0x2eef93('0x38')](_0x2eef93('0x54'))['split'](','),function(_0x21cde9){return parseInt(_0x21cde9,0xa);}):[];}},'phoneBarUnconditionalNumber':{'type':Sequelize['STRING']},'phoneBarNoReplyNumber':{'type':Sequelize[_0x2774ec('0x3b')]},'phoneBarBusyNumber':{'type':Sequelize[_0x2774ec('0x3b')]},'phoneBarUnconditional':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'phoneBarNoReply':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'phoneBarBusy':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'phoneBarDnd':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':!![]},'phoneBarUnansweredCallBadge':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':!![]},'phoneBarEnableDtmfTone':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'phoneBarAutoAnswerDelay':{'type':Sequelize[_0x2774ec('0x30')],'defaultValue':0x0},'extensionMonitor':{'type':Sequelize['STRING'],'defaultValue':''},'crudPermissions':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'rtcp_mux':{'type':Sequelize['ENUM'](_0x2774ec('0x27'),'no'),'defaultValue':'no'},'allowmessenger':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':!![]},'phoneBarOutboundProxy':{'type':Sequelize[_0x2774ec('0x3b')]},'phoneBarEnableJaws':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'phoneBarEnableScreenRecordingByAgent':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'phoneBarEnableVideoRecording':{'type':Sequelize[_0x2774ec('0x29')],'get':function(){const _0x35a2ca=_0x2774ec;return this[_0x35a2ca('0x38')](_0x35a2ca('0x2a'))?this[_0x35a2ca('0x38')](_0x35a2ca('0x2a')):![];}},'phoneBarEnableAutomaticScreenRecording':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'phoneBarPrefixRequired':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'hotdesk':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'interface':{'type':Sequelize[_0x2774ec('0x3b')],'defaultValue':null},'privacyEnabled':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'apiKeyNonce':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'apiKeyIat':{'type':Sequelize[_0x2774ec('0x3b')],'allowNull':!![]},'screenrecording':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![],'set':function(_0xdc7685){const _0x4dc73b=_0x2774ec;if(typeof _0xdc7685===_0x4dc73b('0x45')){const _0x3d3b54=_0xdc7685==='1'?!![]:_0xdc7685==='0'?![]:_0xdc7685==='true'?!![]:_0xdc7685===_0x4dc73b('0x49')?![]:![];this[_0x4dc73b('0x1f')](_0x4dc73b('0x33'),_0x3d3b54);}else this['setDataValue'](_0x4dc73b('0x33'),_0xdc7685);}},'blocked':{'type':Sequelize['BOOLEAN'],'defaultValue':![],'set':function(_0x1cbf93){const _0x4dce5d=_0x2774ec;this[_0x4dce5d('0x1f')](_0x4dce5d('0x3e'),_0x1cbf93),_0x1cbf93===!![]?(this[_0x4dce5d('0x1f')]('blockedAt',moment()),this[_0x4dce5d('0x1f')]('loginAttempts',0x0)):this['setDataValue'](_0x4dce5d('0x2c'),null);}},'blockedAt':{'type':Sequelize['DATE'],'defaultValue':null},'loginAttempts':{'type':Sequelize[_0x2774ec('0x30')],'defaultValue':0x0},'disabled':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':![]},'settingsEnabled':{'type':Sequelize[_0x2774ec('0x19')],'defaultValue':!![]}}; \ No newline at end of file +const a647_0x5807=['PROHIB_NOT_SCREENED','setDataValue','wss','dtlsverify','accountcode','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22udp\x22,\x20\x22tcp\x22]','uas','udp','ALLOWED_PASSED_SCREEN','util','peer','STRING','The\x20name\x20of\x20the\x20user','passive','join','internal','/etc/pki/tls/certs/motion.crt','ALLOWED','blocked','info','defaultuser','PROHIB_PASSED_SCREEN','transport','/etc/pki/tls/private/motion.key','email','split','showWebBar','encryption','fullname','ulaw;alaw;gsm','rtcp_mux','certificate','all','permissions','active','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22ulaw\x22,\x20\x22alaw\x22,\x20\x22gsm\x22]','auto','never','blockedAt','rfc2833','uac','dtlsprivatekey','sequelize','update','yes','allow','dynamic','user','admin','outgoing','nat','INTEGER','isArray','icesupport','VIRTUAL','from-sip','getDataValue','DATE','screenrecording','update,nonat','String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22force_rport\x22,\x20\x22comedia\x22]','friend','ENUM','actpass','exports','callerid','PROHIB','avpf','force_avp','dtlscertfile','fingerprint','ALLOWED_FAILED_SCREEN','dtlsenable','phoneBarEnableScreenRecordingByAgent','name','dtlssetup','BOOLEAN','accept','format','nonat','\x22%s\x22\x20<%s>','moment','map','inband','string','local','lodash'];(function(_0x4ee64f,_0x58078c){const _0x3c8c68=function(_0x29aef1){while(--_0x29aef1){_0x4ee64f['push'](_0x4ee64f['shift']());}};_0x3c8c68(++_0x58078c);}(a647_0x5807,0x1ab));const a647_0x3c8c=function(_0x4ee64f,_0x58078c){_0x4ee64f=_0x4ee64f-0x0;let _0x3c8c68=a647_0x5807[_0x4ee64f];return _0x3c8c68;};const _0x3079ef=a647_0x3c8c;'use strict';const Sequelize=require(_0x3079ef('0x32')),moment=require(_0x3079ef('0x2')),util=require(_0x3079ef('0x11')),_=require(_0x3079ef('0x7'));module[_0x3079ef('0x48')]={'name':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':![],'unique':_0x3079ef('0x52'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i},'set':function(_0x29aef1){const _0x2076db=_0x3079ef;this[_0x2076db('0x9')](_0x2076db('0x52'),_0x29aef1),this['setDataValue'](_0x2076db('0x1c'),_0x29aef1);},'comment':_0x3079ef('0x14')},'fullname':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':![],'set':function(_0x567b1b){const _0x452159=_0x3079ef;this['setDataValue'](_0x452159('0x24'),_0x567b1b),this[_0x452159('0x9')](_0x452159('0x49'),util[_0x452159('0x56')](_0x452159('0x1'),_0x567b1b,this[_0x452159('0x40')]('internal')));}},'alias':{'type':Sequelize['STRING']},'email':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':![],'unique':_0x3079ef('0x20'),'validate':{'isEmail':!![]},'set':function(_0x53bbf2){const _0x183971=_0x3079ef;_0x53bbf2&&this['setDataValue'](_0x183971('0x20'),_0x53bbf2['toLowerCase']());}},'role':{'type':Sequelize['ENUM'](_0x3079ef('0x38'),_0x3079ef('0x37'),'agent','telephone'),'allowNull':![]},'password':{'type':Sequelize['STRING'],'allowNull':![],'validate':{'notEmpty':!![]}},'provider':{'type':Sequelize[_0x3079ef('0x13')],'defaultValue':_0x3079ef('0x6')},'internal':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':![],'unique':_0x3079ef('0x17'),'set':function(_0x2c3faa){const _0x55b493=_0x3079ef;this[_0x55b493('0x9')]('internal',_0x2c3faa),this[_0x55b493('0x9')](_0x55b493('0xc'),_0x2c3faa),this[_0x55b493('0x9')](_0x55b493('0x49'),util[_0x55b493('0x56')](_0x55b493('0x1'),this[_0x55b493('0x40')]('fullname'),_0x2c3faa));}},'salt':{'type':Sequelize['STRING']},'phone':{'type':Sequelize['STRING']},'mobile':{'type':Sequelize[_0x3079ef('0x13')]},'address':{'type':Sequelize['STRING']},'zipcode':{'type':Sequelize[_0x3079ef('0x13')]},'userpic':{'type':Sequelize[_0x3079ef('0x13')]},'city':{'type':Sequelize[_0x3079ef('0x13')]},'country':{'type':Sequelize['STRING']},'online':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'lastLoginAt':{'type':Sequelize[_0x3079ef('0x41')]},'voicePause':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'chatPause':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'mailPause':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'faxPause':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'smsPause':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'whatsappPause':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'openchannelPause':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'pauseType':{'type':Sequelize[_0x3079ef('0x13')],'defaultValue':'DEFAULT\x20PAUSE'},'lastPauseAt':{'type':Sequelize[_0x3079ef('0x41')]},'chatCapacity':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x0},'mailCapacity':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x0},'faxCapacity':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x0},'smsCapacity':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x0},'whatsappCapacity':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x0},'openchannelCapacity':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x0},'phoneBarAutoAnswer':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'phoneBarEnableSettings':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':!![]},'phoneBarListenPort':{'type':Sequelize[_0x3079ef('0x3b')](0x5),'defaultValue':0x1428},'phoneBarExpires':{'type':Sequelize[_0x3079ef('0x3b')](0x5),'defaultValue':0x78},'phoneBarRemoteControl':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'phoneBarRemoteControlPort':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x26a0},'phoneBarEnableRecording':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'phoneBarRingInUse':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'chanspy':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'description':{'type':Sequelize['STRING'],'allowNull':!![]},'host':{'type':Sequelize['STRING'],'allowNull':!![],'defaultValue':_0x3079ef('0x36')},'ipaddr':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'port':{'type':Sequelize[_0x3079ef('0x3b')](0x5),'allowNull':!![]},'regseconds':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'fullcontact':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'regserver':{'type':Sequelize['STRING'],'allowNull':!![]},'useragent':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'lastms':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'type':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x45'),_0x3079ef('0x37'),_0x3079ef('0x12')),'allowNull':!![],'defaultValue':_0x3079ef('0x45')},'context':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![],'defaultValue':_0x3079ef('0x3f')},'callingpres':{'type':Sequelize[_0x3079ef('0x46')]('ALLOWED_NOT_SCREENED',_0x3079ef('0x10'),_0x3079ef('0x4f'),_0x3079ef('0x19'),_0x3079ef('0x8'),_0x3079ef('0x1d'),'PROHIB_FAILED_SCREEN',_0x3079ef('0x4a')),'allowNull':!![]},'deny':{'type':Sequelize['STRING'],'allowNull':!![]},'permit':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'secret':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'md5secret':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'remotesecret':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'transport':{'type':Sequelize['STRING'],'allowNull':!![],'defaultValue':_0x3079ef('0xf'),'set':function(_0x79bacd){const _0x18d895=_0x3079ef;this['setDataValue']('transport',_0x79bacd?_0x79bacd[_0x18d895('0x16')](','):null);},'get':function(){const _0x24e0d7=_0x3079ef;return this[_0x24e0d7('0x40')]('transport')?this['getDataValue'](_0x24e0d7('0x1e'))[_0x24e0d7('0x21')](','):null;},'comment':_0x3079ef('0xd')},'dtmfmode':{'type':Sequelize['ENUM'](_0x3079ef('0x2f'),_0x3079ef('0x1b'),'shortinfo',_0x3079ef('0x4'),_0x3079ef('0x2c')),'allowNull':!![],'defaultValue':'rfc2833'},'directmedia':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no',_0x3079ef('0x0'),_0x3079ef('0x33'),_0x3079ef('0x39')),'allowNull':!![],'defaultValue':'no'},'directrtpsetup':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![],'defaultValue':'no'},'directmediapermit':{'type':Sequelize['STRING'],'allowNull':!![]},'directmediadeny':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'nat':{'type':Sequelize['STRING'],'allowNull':!![],'defaultValue':'force_rport,comedia','set':function(_0x549334){const _0x139c5a=_0x3079ef;this['setDataValue'](_0x139c5a('0x3a'),_0x549334?_0x549334[_0x139c5a('0x16')](','):null);},'get':function(){const _0x34d913=_0x3079ef;return this[_0x34d913('0x40')](_0x34d913('0x3a'))?this[_0x34d913('0x40')](_0x34d913('0x3a'))[_0x34d913('0x21')](','):null;},'comment':_0x3079ef('0x44')},'callgroup':{'type':Sequelize[_0x3079ef('0x13')]},'namedcallgroup':{'type':Sequelize['STRING']},'pickupgroup':{'type':Sequelize['STRING']},'namedpickupgroup':{'type':Sequelize[_0x3079ef('0x13')]},'language':{'type':Sequelize[_0x3079ef('0x13')],'defaultValue':'en'},'tonezone':{'type':Sequelize[_0x3079ef('0x13')]},'disallow':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':![],'defaultValue':_0x3079ef('0x28')},'allow':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':![],'defaultValue':'ulaw;alaw;gsm','set':function(_0x2bd90a){const _0x54b204=_0x3079ef;this[_0x54b204('0x9')](_0x54b204('0x35'),_0x2bd90a?_0x2bd90a[_0x54b204('0x16')](';'):_0x54b204('0x25'));},'get':function(){const _0x223b78=_0x3079ef;return this[_0x223b78('0x40')](_0x223b78('0x35'))?this['getDataValue'](_0x223b78('0x35'))['split'](';'):null;},'comment':_0x3079ef('0x2b')},'autoframing':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![]},'insecure':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![],'set':function(_0x13e855){const _0x25a966=_0x3079ef;this[_0x25a966('0x9')]('insecure',_0x13e855?_0x13e855['join'](','):null);},'get':function(){const _0x2c51ce=_0x3079ef;return this[_0x2c51ce('0x40')]('insecure')?this[_0x2c51ce('0x40')]('insecure')[_0x2c51ce('0x21')](','):null;},'comment':'String\x20is\x20deprecated.\x20Please\x20use\x20an\x20Array\x20as\x20[\x22port\x22,\x20\x22invite\x22]'},'trustrpid':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![],'defaultValue':'no'},'trust_id_outbound':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![],'defaultValue':'no'},'progressinband':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no',_0x3079ef('0x2d')),'allowNull':!![]},'promiscredir':{'type':Sequelize[_0x3079ef('0x46')]('yes','no'),'allowNull':!![]},'useclientcode':{'type':Sequelize['ENUM'](_0x3079ef('0x34'),'no'),'allowNull':!![]},'accountcode':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'setvar':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'callerid':{'type':Sequelize['STRING'],'allowNull':!![],'defaultValue':'\x22\x22\x20<>'},'amaflags':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'callcounter':{'type':Sequelize['ENUM'](_0x3079ef('0x34'),'no'),'allowNull':!![],'defaultValue':_0x3079ef('0x34')},'busylevel':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'allowoverlap':{'type':Sequelize['ENUM']('yes','no'),'allowNull':!![]},'allowsubscribe':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![]},'allowtransfer':{'type':Sequelize[_0x3079ef('0x46')]('yes','no'),'allowNull':!![]},'ignoresdpversion':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![]},'subscribecontext':{'type':Sequelize['STRING'],'allowNull':!![]},'template':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'videosupport':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no','always'),'allowNull':!![],'defaultValue':'no'},'maxcallbitrate':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'rfc2833compensate':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![]},'mailbox':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'session_timers':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x55'),'refuse','originate'),'allowNull':!![]},'session_expires':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'session_minse':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'session_refresher':{'type':Sequelize['ENUM'](_0x3079ef('0x30'),_0x3079ef('0xe')),'allowNull':!![],'defaultValue':'uas'},'t38pt_usertpsource':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'regexten':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'fromdomain':{'type':Sequelize['STRING'],'allowNull':!![]},'fromuser':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'qualify':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![],'defaultValue':_0x3079ef('0x34')},'keepalive':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'defaultip':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'defaultuser':{'type':Sequelize['STRING'],'allowNull':!![]},'rtptimeout':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'rtpholdtimeout':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'rtpkeepalive':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'sendrpid':{'type':Sequelize['ENUM'](_0x3079ef('0x34'),'no'),'allowNull':!![],'defaultValue':'no'},'outboundproxy':{'type':Sequelize['STRING'],'allowNull':!![]},'callbackextension':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'timert1':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'timerb':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'qualifyfreq':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'contactpermit':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'contactdeny':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'contactacl':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'unsolicited_mailbox':{'type':Sequelize['STRING'],'allowNull':!![]},'use_q850_reason':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'maxforwards':{'type':Sequelize['INTEGER'](0xb),'allowNull':!![]},'encryption':{'type':Sequelize['ENUM'](_0x3079ef('0x34'),'no'),'allowNull':!![],'defaultValue':'no'},'avpf':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![]},'force_avp':{'type':Sequelize['ENUM'](_0x3079ef('0x34'),'no'),'allowNull':!![]},'icesupport':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![]},'dtlsenable':{'type':Sequelize[_0x3079ef('0x46')]('yes','no'),'allowNull':!![]},'dtlsverify':{'type':Sequelize['ENUM'](_0x3079ef('0x34'),'no',_0x3079ef('0x4e'),_0x3079ef('0x27')),'allowNull':!![]},'dtlsrekey':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![]},'dtlscertfile':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'dtlsprivatekey':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'dtlscipher':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'dtlscafile':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'dtlscapath':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'dtlssetup':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x2a'),_0x3079ef('0x15'),_0x3079ef('0x47')),'allowNull':!![]},'dtlsfingerprint':{'type':Sequelize['STRING'],'allowNull':!![]},'usereqphone':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![],'defaultValue':'no'},'recordonfeature':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'recordofffeature':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'call_limit':{'type':Sequelize[_0x3079ef('0x3b')](0xb),'allowNull':!![],'defaultValue':0xa},'registertrying':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![]},'subscribemwi':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'allowNull':!![]},'vmexten':{'type':Sequelize['STRING'],'allowNull':!![]},'mohinterpret':{'type':Sequelize['STRING'],'allowNull':!![]},'mohsuggest':{'type':Sequelize['STRING'],'allowNull':!![]},'parkinglot':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'canreinvite':{'type':Sequelize['ENUM']('yes','no',_0x3079ef('0x0'),_0x3079ef('0x33'),_0x3079ef('0x43')),'allowNull':!![],'defaultValue':'no'},'loginInPause':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'resetPasswordToken':{'type':Sequelize['STRING']},'resetPasswordExpires':{'type':Sequelize['DATE']},'passwordResetAt':{'type':Sequelize['DATE'],'defaultValue':null},'previousPasswords':{'type':Sequelize[_0x3079ef('0x13')]},'showWebBar':{'type':Sequelize['INTEGER'],'defaultValue':0x0,'set':function(_0x2d12cd){const _0x42a07d=_0x3079ef;this[_0x42a07d('0x9')](_0x42a07d('0x22'),_0x2d12cd);const _0x1d60cb=this['get']({'plain':!![]});switch(_0x2d12cd){case 0x0:case 0x1:{let _0x504d8a=_0x1d60cb[_0x42a07d('0x1e')]?_[_0x42a07d('0x3c')](_0x1d60cb[_0x42a07d('0x1e')])?_0x1d60cb[_0x42a07d('0x1e')][_0x42a07d('0x16')]():_0x1d60cb[_0x42a07d('0x1e')]:'udp';_0x504d8a===_0x42a07d('0xa')&&(_0x504d8a=_0x42a07d('0xf')),this[_0x42a07d('0x9')](_0x42a07d('0x1e'),_0x504d8a),this['setDataValue'](_0x42a07d('0x23'),'no'),this['setDataValue']('avpf',null),this[_0x42a07d('0x9')]('force_avp',null),this['setDataValue'](_0x42a07d('0x3d'),null),this['setDataValue'](_0x42a07d('0x50'),null),this[_0x42a07d('0x9')](_0x42a07d('0xb'),null),this[_0x42a07d('0x9')](_0x42a07d('0x53'),null),this[_0x42a07d('0x9')](_0x42a07d('0x4d'),null),this[_0x42a07d('0x9')](_0x42a07d('0x31'),null),this[_0x42a07d('0x9')](_0x42a07d('0x26'),'no');}break;case 0x2:this[_0x42a07d('0x9')]('transport',_0x42a07d('0xa')),this[_0x42a07d('0x9')]('encryption',_0x42a07d('0x34')),this[_0x42a07d('0x9')](_0x42a07d('0x4b'),'yes'),this[_0x42a07d('0x9')](_0x42a07d('0x4c'),_0x42a07d('0x34')),this[_0x42a07d('0x9')]('icesupport',_0x42a07d('0x34')),this[_0x42a07d('0x9')]('dtlsenable',_0x42a07d('0x34')),this[_0x42a07d('0x9')](_0x42a07d('0xb'),'no'),this[_0x42a07d('0x9')]('dtlssetup',_0x42a07d('0x47')),this[_0x42a07d('0x9')](_0x42a07d('0x4d'),_0x1d60cb[_0x42a07d('0x4d')]||_0x42a07d('0x18')),this['setDataValue'](_0x42a07d('0x31'),_0x1d60cb[_0x42a07d('0x31')]||_0x42a07d('0x1f')),this[_0x42a07d('0x9')](_0x42a07d('0x26'),_0x42a07d('0x34'));break;default:}}},'permissions':{'type':Sequelize['TEXT'],'set':function(_0x56318f){const _0x340a59=_0x3079ef;this['setDataValue'](_0x340a59('0x29'),_0x56318f?_0x56318f[_0x340a59('0x16')](','):[]);},'get':function(){const _0x326a07=_0x3079ef;return this['getDataValue'](_0x326a07('0x29'))?_[_0x326a07('0x3')](this['getDataValue'](_0x326a07('0x29'))[_0x326a07('0x21')](','),function(_0x987e44){return parseInt(_0x987e44,0xa);}):[];}},'phoneBarUnconditionalNumber':{'type':Sequelize[_0x3079ef('0x13')]},'phoneBarNoReplyNumber':{'type':Sequelize[_0x3079ef('0x13')]},'phoneBarBusyNumber':{'type':Sequelize[_0x3079ef('0x13')]},'phoneBarUnconditional':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'phoneBarNoReply':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'phoneBarBusy':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'phoneBarDnd':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'phoneBarUnansweredCallBadge':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]},'phoneBarEnableDtmfTone':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'phoneBarAutoAnswerDelay':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x0},'extensionMonitor':{'type':Sequelize['STRING'],'defaultValue':''},'crudPermissions':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x0},'rtcp_mux':{'type':Sequelize[_0x3079ef('0x46')](_0x3079ef('0x34'),'no'),'defaultValue':'no'},'allowmessenger':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':!![]},'phoneBarOutboundProxy':{'type':Sequelize[_0x3079ef('0x13')]},'phoneBarEnableJaws':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'phoneBarEnableScreenRecordingByAgent':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'phoneBarEnableVideoRecording':{'type':Sequelize[_0x3079ef('0x3e')],'get':function(){const _0x3a3c9a=_0x3079ef;return this['getDataValue']('phoneBarEnableScreenRecordingByAgent')?this[_0x3a3c9a('0x40')](_0x3a3c9a('0x51')):![];}},'phoneBarEnableAutomaticScreenRecording':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'phoneBarPrefixRequired':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'hotdesk':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'interface':{'type':Sequelize[_0x3079ef('0x13')],'defaultValue':null},'privacyEnabled':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'apiKeyNonce':{'type':Sequelize['STRING'],'allowNull':!![]},'apiKeyIat':{'type':Sequelize[_0x3079ef('0x13')],'allowNull':!![]},'screenrecording':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![],'set':function(_0x43c9da){const _0x35814e=_0x3079ef;if(typeof _0x43c9da===_0x35814e('0x5')){const _0x180b6b=_0x43c9da==='1'?!![]:_0x43c9da==='0'?![]:_0x43c9da==='true'?!![]:_0x43c9da==='false'?![]:![];this[_0x35814e('0x9')](_0x35814e('0x42'),_0x180b6b);}else this[_0x35814e('0x9')](_0x35814e('0x42'),_0x43c9da);}},'blocked':{'type':Sequelize['BOOLEAN'],'defaultValue':![],'set':function(_0x4db5ac){const _0x597c57=_0x3079ef;this[_0x597c57('0x9')](_0x597c57('0x1a'),_0x4db5ac),_0x4db5ac===!![]?(this[_0x597c57('0x9')](_0x597c57('0x2e'),moment()),this[_0x597c57('0x9')]('loginAttempts',0x0)):this[_0x597c57('0x9')](_0x597c57('0x2e'),null);}},'blockedAt':{'type':Sequelize[_0x3079ef('0x41')],'defaultValue':null},'loginAttempts':{'type':Sequelize[_0x3079ef('0x3b')],'defaultValue':0x0},'disabled':{'type':Sequelize[_0x3079ef('0x54')],'defaultValue':![]},'settingsEnabled':{'type':Sequelize['BOOLEAN'],'defaultValue':!![]}}; \ No newline at end of file diff --git a/server/api/user/user.controller.js b/server/api/user/user.controller.js index 0144904..5f9fc51 100644 --- a/server/api/user/user.controller.js +++ b/server/api/user/user.controller.js @@ -1 +1 @@ -const a648_0x19d8=['download','json','Agents','List','socket','$ne','CmHopper','getWhatsappInteractions','unpause','user_has_whatsapp_interactions:save','user_has_fax_interactions:remove','info','server/files/images/logos/default_profile.png','Whatsapp','lastPauseAt','removeChatInteractions','$any','LOGIN','fax','rawAttributes','result','addFaxAccounts','%s%s','emit','filename','lodash','request\x20sent','User,\x20%s,\x20%s','Queues','voicePause','ids','getVoicePrefixes','getMailQueues','filter','removeMailAccounts','findOne','Team','getGroups','root','passwordHistoryLimit','MemberReport','getFaxInteractions','headers','includeAll','add','user:%s','describe','VIRTUAL','user_has_chat_interactions:remove','getQueues','dialActive','online','apiKeyNonce','getChannels','merge','push','VoiceMail','addOpenchannelAccounts','getTeams','length','$between','user_has_sms_interactions:save','getLists','includes','differenceBy','getDataValue','getChatWebsites','attributes','create','permissions','limit','$notBetween','updatePasswordsHistory','penalty','addSmsInteractions','oldPassword','Unauthorized','removeSmsInteractions','PAUSE','min_internal','ChatGroup','getChatInteractions','addTeams','Contact','flatten','destroy','client','$gt','checkUserLimits','../../mysqldb','VoiceRecording','addSmsAccounts','join','addWhatsappAccounts','WhatsappAccount','$in','voice','getChatQueues','102','where','Telephones','newPassword','whoami','$notILike','intersection','removeSmsAccounts','UserProfileResource','api','changePassword','userpic','path','getContacts','find','values','addSquareProjects','previousPasswords','SIP/%s','nolimit','removeSquareProjects','index','some','removeAgent','user:forcelogout','DEFAULT\x20PAUSE','getRecordings','capitalize','agent','OpenchannelAccount','Invalid\x20body\x20format.\x20Use\x20newPassword','Voice','mailPause','lastName','user_has_openchannel_interactions:remove','type','removeTeams','getVoiceQueues','You\x20don\x27t\x20have\x20sufficient\x20privileges\x20to\x20access\x20this\x20resource.','nonce','getFaxAccounts','count','toLowerCase','Unauthorized.\x20You\x20must\x20be\x20an\x20administrator\x20in\x20order\x20to\x20create\x20an\x20user','max','interface','mailbox','LOCAL/%s@from-sip/n','whatsapp','openchannelPause','value','getMailAccounts','error','../../rediscache','pick','util','109','Sms','getVoiceQueuesRt','fields','addOpenchannelInteractions','file','bulkCreate','removeWhatsappInteractions','VoiceQueue','remove','addContacts','faxPause','each','retrieveApiKey','autoAssociation','SmsAccount','login','user','isArray','$and','addAgent','removeFaxAccounts','VoicePrefix','Chat','transaction','sort','../../components/parsers/qs','getOpenchannelQueues','x-forwarded-for','pause','user_has_mail_interactions:remove','113','params','Mail','ChatWebsite','Setting','update','setDataValue','include','getMailInteractions','omit','addChatWebsites','filters','token','lower','remoteAddress','smsPause','pauseType','getScreenRecordings','./user.socket','Unable\x20to\x20retrieve\x20the\x20current\x20user','model','logout','Unauthorized.\x20You\x20must\x20be\x20an\x20administrator\x20in\x20order\x20to\x20create\x20another\x20administrator','getAgents','all','LOGININPAUSE','and','QueuePause','Content-Range','enforcePasswordHistory','removeFaxInteractions','getSmsAccounts','userProfileId','internal','body','keys','removeOpenchannelInteractions','Unknown\x20role','CmList','createApiKey','getWhatsappAccounts','status','YYYY-MM-DD\x20HH:mm:ss','$overlap','isMiddleware','validatePasswordPattern','$lt','../../config/environment','catch','stack','mobile','SELECT','QueueId','rows','password','addAvatar','code','findAll','MailInteraction','manual','admin','getSquareProjects','114','OpenchannelInteraction','fullname','getSmsInteractions','options','select\x20(select\x20IFNULL(max(internal)+1,1)\x20from\x20users\x20where\x20internal\x20<\x20md.internal)\x20as\x20\x27from\x27,\x20md.internal\x20-\x201\x20as\x20\x27to\x27\x20from\x20users\x20md\x20where\x20md.internal\x20!=\x201\x20and\x20not\x20exists\x20(select\x201\x20from\x20users\x20md2\x20where\x20md2.internal\x20=\x20md.internal\x20-\x201)','$or','send','securePassword','Users','getOpenchannelAccounts','Queue','like','addFaxInteractions','files/images/','concat','color','getOpenchannelInteractions','authenticate','end','undefined','loginInPause','Queue:save','$lte','UserVoiceQueue.penalty','SmsInteraction','Tag','user_has_fax_interactions:save','sms','openchannel','105','FaxAccount','offset','$gte','ChatInteraction','No\x20API\x20access\x20key\x20found!','You\x20can\x27t\x20delete\x20yourself','format','salt','$notIn','UserVoiceQueueRt','then','from','addMailAccounts','Unknown\x20channel','FaxInteraction','removeMailInteractions','addWhatsappInteractions','user_has_openchannel_interactions:save','compact','request','map','removeOpenchannelAccounts','debug','CmContact','../../components/auth/service','resolve','Unauthorized.\x20You\x20must\x20be\x20an\x20administrator\x20in\x20order\x20to\x20create\x20an\x20administrator','order','generateApiKey','$contained','forEach','100','getWhatsappQueues','key','User','Use','jayson/promise','UserProfileSection','$like','moment','mail','telephone','getFaxQueues','Fax','getApiKey','106','UserId','upsert','ScreenRecording','device','phone','chatPause','user_has_chat_interactions:save','firstName','$notLike','isValidChannel','101','addQueues','user_has_sms_interactions:remove','110','channel','isNil','user_has_mail_interactions:save','Invalid\x20body\x20format.\x20Use\x20oldPassword\x20and\x20newPassword','removeChatWebsites','get','name','New\x20password\x20must\x20be\x20different\x20from\x20old\x20password','sequelize','message','addMailInteractions','107','tag','query','removeWhatsappAccounts','whatsapppause','connection','role','intrf'];(function(_0x2d47f1,_0x19d887){const _0x4b4f7b=function(_0x5c6cd0){while(--_0x5c6cd0){_0x2d47f1['push'](_0x2d47f1['shift']());}};_0x4b4f7b(++_0x19d887);}(a648_0x19d8,0x8e));const a648_0x4b4f=function(_0x2d47f1,_0x19d887){_0x2d47f1=_0x2d47f1-0x0;let _0x4b4f7b=a648_0x19d8[_0x2d47f1];return _0x4b4f7b;};const _0x5832ca=a648_0x4b4f;'use strict';const moment=require(_0x5832ca('0xaf')),util=require(_0x5832ca('0xb')),path=require(_0x5832ca('0x145')),fs=require('fs'),_=require(_0x5832ca('0xf0')),{getSocket}=require(_0x5832ca('0x9')),socket=getSocket(),authService=require(_0x5832ca('0xa0')),qs=require(_0x5832ca('0x26')),logger=require('../../config/logger')(_0x5832ca('0x142')),utils=require('../../config/utils'),config=require(_0x5832ca('0x5a')),db=require(_0x5832ca('0x130'))['db'],{Op,QueryTypes,fn,col,where,ValidationError}=require('sequelize'),licenseUtil=require('../../config/license/util');require(_0x5832ca('0x3d'))['register'](socket);const jayson=require(_0x5832ca('0xac')),client=jayson[_0x5832ca('0x12d')]['http']({'port':0x232a});function respondWithRpcPromise(_0x5c6cd0,_0x51384f,_0xeed696,_0x1cff35){return new Promise(function(_0x256fdc,_0x3dc3af){const _0x375e9b=a648_0x4b4f,_0x27f1f9=_0x1cff35||client;return _0x27f1f9[_0x375e9b('0x9b')](_0x5c6cd0,_0xeed696)[_0x375e9b('0x92')](function(_0x2d1a9f){const _0x1e55fd=_0x375e9b;logger[_0x1e55fd('0xe2')](_0x1e55fd('0xf2'),_0x51384f,_0x1e55fd('0xf1')),logger[_0x1e55fd('0x9e')]('User,\x20%s,\x20%s,\x20%s',_0x51384f,_0x1e55fd('0xf1'),JSON['stringify'](_0x2d1a9f));if(_0x2d1a9f[_0x1e55fd('0x8')]){if(_0x2d1a9f['error'][_0x1e55fd('0x63')]===0x1f4)return logger[_0x1e55fd('0x8')](_0x1e55fd('0xf2'),_0x51384f,_0x2d1a9f['error'][_0x1e55fd('0xcd')]),_0x3dc3af(_0x2d1a9f[_0x1e55fd('0x8')]['message']);return logger[_0x1e55fd('0x8')](_0x1e55fd('0xf2'),_0x51384f,_0x2d1a9f['error']['message']),_0x256fdc(_0x2d1a9f['error'][_0x1e55fd('0xcd')]);}else logger[_0x1e55fd('0xe2')]('User,\x20%s,\x20%s',_0x51384f,_0x1e55fd('0xf1')),_0x256fdc(_0x2d1a9f[_0x1e55fd('0xeb')]['message']);})[_0x375e9b('0x5b')](function(_0x3a50db){const _0xa057c5=_0x375e9b;logger[_0xa057c5('0x8')](_0xa057c5('0xf2'),_0x51384f,_0x3a50db),_0x3dc3af(_0x3a50db);});});}function respondWithStatusCode(_0x518833,_0x4e730b){return _0x4e730b=_0x4e730b||0xcc,function(_0x41579e){const _0x15cf41=a648_0x4b4f;if(_0x41579e)return _0x518833['sendStatus'](_0x4e730b);return _0x518833[_0x15cf41('0x54')](_0x4e730b)[_0x15cf41('0x7c')]();};}function respondWithResult(_0x41f1f1,_0x5526ad){return _0x5526ad=_0x5526ad||0xc8,function(_0x245c83){const _0xb831e2=a648_0x4b4f;if(_0x245c83)return _0x41f1f1['status'](_0x5526ad)[_0xb831e2('0xd8')](_0x245c83);};}function respondWithFilteredResult(_0x1b2e1a,_0x226e26){return function(_0x328768){const _0x8c02a5=a648_0x4b4f;if(_0x328768){const _0x4f15d0=_0x328768[_0x8c02a5('0x162')],_0x2ab566=_0x226e26[_0x8c02a5('0x89')];let _0x72459d=_0x226e26[_0x8c02a5('0x89')]+_0x226e26[_0x8c02a5('0x11d')],_0x4510de;return _0x72459d>=_0x4f15d0?(_0x72459d=_0x4f15d0,_0x4510de=0xc8):_0x4510de=0xce,_0x1b2e1a[_0x8c02a5('0x54')](_0x4510de),_0x1b2e1a['set'](_0x8c02a5('0x47'),_0x2ab566+'-'+_0x72459d+'/'+_0x4f15d0)[_0x8c02a5('0xd8')](_0x328768);}return null;};}function saveUpdates(_0x566ae4){return function(_0x127a5e){const _0x39b136=a648_0x4b4f;if(_0x127a5e)return _0x127a5e[_0x39b136('0x30')](_0x566ae4)[_0x39b136('0x92')](function(_0x11f674){return _0x11f674;});return null;};}function removeEntity(_0x875801){return function(_0x2fcb87){const _0x517344=a648_0x4b4f;if(_0x2fcb87)return _0x2fcb87[_0x517344('0x12c')]()[_0x517344('0x92')](function(){const _0x34d362=_0x517344,_0x489f8a=_0x2fcb87['get']({'plain':!![]});if(_0x489f8a[_0x34d362('0xd5')]===_0x34d362('0x67'))return;const _0x44a3c3=[{'name':_0x34d362('0x72'),'value':_0x34d362('0x1d'),'ignore':!![]},{'name':'Agents','value':_0x34d362('0x155'),'ignore':![]},{'name':_0x34d362('0x13b'),'value':_0x34d362('0xb1'),'ignore':![]}],_0x3ed8d6=_(_0x44a3c3)['filter']('ignore')[_0x34d362('0x9c')](_0x34d362('0x6'))[_0x34d362('0x6')]();if(_[_0x34d362('0x116')](_0x3ed8d6,_0x489f8a['role']))return;const _0x1c064e=_[_0x34d362('0x147')](_0x44a3c3,['value',_0x489f8a[_0x34d362('0xd5')]])['name'];return db[_0x34d362('0x141')][_0x34d362('0x12c')]({'where':{'type':_0x1c064e,'resourceId':_0x489f8a['id']}})[_0x34d362('0x92')](function(){return _0x2fcb87;});})[_0x517344('0x92')](function(){const _0x3ee65a=_0x517344;_0x875801['status'](0xcc)[_0x3ee65a('0x7c')]();});};}function handleEntityNotFound(_0x85f0b8){return function(_0x9647d4){return!_0x9647d4&&_0x85f0b8['sendStatus'](0x194),_0x9647d4;};}function handleError(_0xef187d,_0x482f7a){return _0x482f7a=_0x482f7a||0x1f4,function(_0x18ff9d){const _0x369218=a648_0x4b4f;logger[_0x369218('0x8')](_0x18ff9d[_0x369218('0x5c')]),_0x18ff9d[_0x369218('0xca')]&&delete _0x18ff9d[_0x369218('0xca')],_0xef187d[_0x369218('0x54')](_0x482f7a)[_0x369218('0x70')](_0x18ff9d);};}function validateUser(_0x1c74d1){return new Promise(function(_0x212ee1,_0x595c66){const _0x35aa11=a648_0x4b4f;if(_0x1c74d1[_0x35aa11('0x4c')])return _0x212ee1(_0x1c74d1);return db['Setting']['findByPk'](0x1)[_0x35aa11('0x92')](function(_0x1a941f){const _0x57f5b8=_0x35aa11;if(_0x1a941f[_0x57f5b8('0x71')])authService[_0x57f5b8('0x58')](_0x1c74d1[_0x57f5b8('0x61')]);db[_0x57f5b8('0xaa')][_0x57f5b8('0x0')](_0x57f5b8('0x4c'))[_0x57f5b8('0x92')](function(_0x49c8ad){const _0x2723ac=_0x57f5b8;if(_[_0x2723ac('0xc5')](_0x49c8ad)){_0x1c74d1[_0x2723ac('0x4c')]=_0x1a941f[_0x2723ac('0x126')]||0x1;return;}if(_[_0x2723ac('0xc5')](_0x1a941f[_0x2723ac('0x126')])||_0x1a941f['min_internal']===_0x49c8ad){_0x1c74d1['internal']=_0x49c8ad+0x1;return;}if(_0x1a941f[_0x2723ac('0x126')]>_0x49c8ad){_0x1c74d1['internal']=_0x1a941f['min_internal'];return;}return db[_0x2723ac('0xcc')][_0x2723ac('0xd1')](_0x2723ac('0x6e'),{'type':QueryTypes[_0x2723ac('0x5e')]})[_0x2723ac('0x92')](function(_0x4285fc){const _0x1277d8=_0x2723ac;if(_0x4285fc&&_0x4285fc[_0x1277d8('0x112')])for(let _0x8acf92=0x0,_0x16cb01=_0x4285fc['length'];_0x8acf92<_0x16cb01&&_[_0x1277d8('0xc5')](_0x1c74d1[_0x1277d8('0x4c')]);_0x8acf92++){if(_0x1a941f[_0x1277d8('0x126')]<=_0x4285fc[_0x8acf92][_0x1277d8('0x93')])_0x1c74d1[_0x1277d8('0x4c')]=_0x4285fc[_0x8acf92][_0x1277d8('0x93')];else _0x1a941f[_0x1277d8('0x126')]>_0x4285fc[_0x8acf92][_0x1277d8('0x93')]&&_0x1a941f[_0x1277d8('0x126')]<=_0x4285fc[_0x8acf92]['to']&&(_0x1c74d1['internal']=_0x1a941f[_0x1277d8('0x126')]);}return _[_0x1277d8('0xc5')](_0x1c74d1['internal'])&&(_0x1c74d1[_0x1277d8('0x4c')]=_0x49c8ad+0x1),_0x212ee1(_0x1c74d1);});});})[_0x35aa11('0x5b')](function(_0x41ae6c){_0x595c66(_0x41ae6c);});});}function updateUser(_0x16f7c1){return new Promise(function(_0x4505e3,_0x4460f3){const _0x15e475=a648_0x4b4f;try{_0x16f7c1['voicemail']&&(_0x16f7c1[_0x15e475('0x2')]=_0x16f7c1[_0x15e475('0x4c')],_0x16f7c1[_0x15e475('0x10f')]={'mailbox':_0x16f7c1['internal'],'password':_0x16f7c1['password'],'fullname':_0x16f7c1[_0x15e475('0x6b')],'email':_0x16f7c1['email']});if(_0x16f7c1[_0x15e475('0xd5')]===_0x15e475('0x155')){if(!_0x16f7c1[_0x15e475('0x11c')])_0x16f7c1[_0x15e475('0x11c')]=[_0x15e475('0xc0'),_0x15e475('0x139'),'103',_0x15e475('0x2b'),_0x15e475('0xc3'),'104',_0x15e475('0x87'),_0x15e475('0xb5'),_0x15e475('0xcf'),'108',_0x15e475('0xc'),_0x15e475('0xa7'),'111',_0x15e475('0x69')];}_0x4505e3(_0x16f7c1);}catch(_0x450f8b){_0x4460f3(_0x450f8b);}});}exports[_0x5832ca('0x14e')]=function(_0x4fa5a5,_0x51cdaa){const _0x1fbafa=_0x5832ca;let _0xdcc4ab={};const _0x523329={},_0x1779d7={'count':0x0,'rows':[]},_0x51c8ae=_['map'](db[_0x1fbafa('0xaa')][_0x1fbafa('0xea')],function(_0x37cc1f){const _0x1211f7=_0x1fbafa;return{'name':_0x37cc1f['fieldName'],'type':_0x37cc1f[_0x1211f7('0x15c')][_0x1211f7('0xa9')]};});_0x523329['model']=_['differenceBy'](_[_0x1fbafa('0x9c')](_0x51c8ae,'name'),[_0x1fbafa('0x61'),_0x1fbafa('0x8f')]),_0x523329['query']=_[_0x1fbafa('0x4e')](_0x4fa5a5[_0x1fbafa('0xd1')]),_0x523329[_0x1fbafa('0x36')]=_[_0x1fbafa('0x13f')](_0x523329['model'],_0x523329['query']),_0xdcc4ab['attributes']=_[_0x1fbafa('0x13f')](_0x523329[_0x1fbafa('0x3f')],qs[_0x1fbafa('0xf')](_0x4fa5a5[_0x1fbafa('0xd1')]['fields'])),_0xdcc4ab[_0x1fbafa('0x11a')]=_0xdcc4ab['attributes'][_0x1fbafa('0x112')]?_0xdcc4ab['attributes']:_0x523329[_0x1fbafa('0x3f')];typeof _0x4fa5a5[_0x1fbafa('0xd1')][_0x1fbafa('0x14c')]===_0x1fbafa('0x7d')&&(_0xdcc4ab[_0x1fbafa('0x11d')]=qs[_0x1fbafa('0x11d')](_0x4fa5a5[_0x1fbafa('0xd1')][_0x1fbafa('0x11d')]),_0xdcc4ab['offset']=qs['offset'](_0x4fa5a5['query']['offset']));_0xdcc4ab[_0x1fbafa('0xa3')]=qs[_0x1fbafa('0x25')](_0x4fa5a5['query'][_0x1fbafa('0x25')]),_0xdcc4ab[_0x1fbafa('0x13a')]=qs['filters'](_[_0x1fbafa('0xa')](_0x4fa5a5[_0x1fbafa('0xd1')],_0x523329[_0x1fbafa('0x36')]),_0x51c8ae);_0x4fa5a5['query'][_0x1fbafa('0xf8')]&&(_0xdcc4ab[_0x1fbafa('0x13a')]=_[_0x1fbafa('0x10d')](_0xdcc4ab[_0x1fbafa('0x13a')],{[Op['or']]:_[_0x1fbafa('0x9c')](_0x51c8ae,function(_0x59b11e){const _0x571e4c=_0x1fbafa;if(_0x59b11e[_0x571e4c('0x15c')]!==_0x571e4c('0x106'))return where(fn(_0x571e4c('0x38'),col(_0x59b11e[_0x571e4c('0xca')])),{'$like':fn(_0x571e4c('0x38'),'%'+_0x4fa5a5['query'][_0x571e4c('0xf8')]+'%')});})}));_0xdcc4ab=_['merge']({},_0xdcc4ab,_0x4fa5a5[_0x1fbafa('0x6d')]);const _0x201d06={'where':_0xdcc4ab[_0x1fbafa('0x13a')]};return db['User'][_0x1fbafa('0x162')](_0x201d06)['then'](function(_0x13751e){const _0x48ded6=_0x1fbafa;return _0x1779d7['count']=_0x13751e,typeof _0x4fa5a5[_0x48ded6('0xd1')][_0x48ded6('0x102')]!==_0x48ded6('0x7d')&&(_0xdcc4ab[_0x48ded6('0x32')]=[{'all':!![]}]),db[_0x48ded6('0xaa')][_0x48ded6('0x64')](_0xdcc4ab);})['then'](function(_0x361617){return _0x1779d7['rows']=_0x361617,_0x1779d7;})[_0x1fbafa('0x92')](respondWithFilteredResult(_0x51cdaa,_0xdcc4ab))[_0x1fbafa('0x5b')](handleError(_0x51cdaa,null));},exports['show']=function(_0x5c8954,_0xa03cbf){const _0x39c975=_0x5832ca;let _0x152dc4={'raw':![],'where':{'id':_0x5c8954[_0x39c975('0x2c')]['id']}};const _0x759a58={};return _0x759a58[_0x39c975('0x3f')]=_[_0x39c975('0x117')](_['keys'](db[_0x39c975('0xaa')][_0x39c975('0xea')]),[_0x39c975('0x61'),_0x39c975('0x8f')]),_0x759a58[_0x39c975('0xd1')]=_[_0x39c975('0x4e')](_0x5c8954[_0x39c975('0xd1')]),_0x759a58[_0x39c975('0x36')]=_['intersection'](_0x759a58[_0x39c975('0x3f')],_0x759a58['query']),_0x152dc4[_0x39c975('0x11a')]=_['intersection'](_0x759a58['model'],qs[_0x39c975('0xf')](_0x5c8954['query'][_0x39c975('0xf')])),_0x152dc4[_0x39c975('0x11a')]=_0x152dc4[_0x39c975('0x11a')]['length']?_0x152dc4['attributes']:_0x759a58[_0x39c975('0x3f')],_0x5c8954[_0x39c975('0xd1')][_0x39c975('0x102')]&&(_0x152dc4[_0x39c975('0x32')]=[{'all':!![]}]),_0x152dc4=_[_0x39c975('0x10d')]({},_0x152dc4,_0x5c8954[_0x39c975('0x6d')]),db[_0x39c975('0xaa')][_0x39c975('0xfa')](_0x152dc4)['then'](handleEntityNotFound(_0xa03cbf,null))[_0x39c975('0x92')](respondWithResult(_0xa03cbf,null))['catch'](handleError(_0xa03cbf,null));},exports[_0x5832ca('0x12')]=function(_0xcff05,_0x4f48e3){const _0x2fd36c=_0x5832ca,_0x1e805d=_0xcff05[_0x2fd36c('0x4d')];let _0x4a1cec=[];if(_0xcff05[_0x2fd36c('0x1d')][_0x2fd36c('0xd5')]===_0x2fd36c('0x155'))throw new Error(_0x2fd36c('0x123'));if(_[_0x2fd36c('0x14f')](_0x1e805d,[_0x2fd36c('0xd5'),_0x2fd36c('0x1d')])&&_0xcff05[_0x2fd36c('0x1d')][_0x2fd36c('0xd5')]!==_0x2fd36c('0x67'))throw new Error('Unauthorized.\x20You\x20must\x20be\x20an\x20administrator\x20in\x20order\x20to\x20create\x20an\x20user');if(_['some'](_0x1e805d,[_0x2fd36c('0xd5'),_0x2fd36c('0x67')])&&_0xcff05['user'][_0x2fd36c('0xd5')]!==_0x2fd36c('0x67'))throw new Error(_0x2fd36c('0xa2'));return licenseUtil['checkUserLimits'](_0x1e805d)[_0x2fd36c('0x92')](function(){return validateUser(_0x1e805d[0x0]);})[_0x2fd36c('0x92')](function(){const _0x48c267=_0x2fd36c;for(let _0x187545=0x1;_0x187545<_0x1e805d[_0x48c267('0x112')];_0x187545++){const _0x329a15=_0x1e805d[_0x187545-0x1][_0x48c267('0x4c')];if(!_0x1e805d[_0x187545]['internal'])_0x1e805d[_0x187545][_0x48c267('0x4c')]=_0x329a15+0x1;_0x4a1cec[_0x48c267('0x10e')](validateUser(_0x1e805d[_0x187545]));}return Promise[_0x48c267('0x43')](_0x4a1cec);})[_0x2fd36c('0x92')](function(){const _0x13ceb7=_0x2fd36c;_0x4a1cec=[];for(let _0x44dfa8=0x0;_0x44dfa8<_0x1e805d[_0x13ceb7('0x112')];_0x44dfa8++){_0x4a1cec['push'](updateUser(_0x1e805d[_0x44dfa8]));}return Promise['all'](_0x4a1cec);})['then'](function(){return _0x4a1cec=_0x1e805d['map'](_0x35e4bb=>{const _0x426ea4=a648_0x4b4f;return db[_0x426ea4('0xaa')][_0x426ea4('0x11b')](_0x35e4bb,{'include':[{'model':db[_0x426ea4('0x10f')],'as':_0x426ea4('0x10f')}]})[_0x426ea4('0x92')](function(_0x56d696){return _0x35e4bb['id']=_0x56d696['id'],_0x35e4bb;});}),Promise['all'](_0x4a1cec);})['then'](function(_0x424dd7){const _0x186945=_0x2fd36c;if(_0xcff05[_0x186945('0x4d')][_0x186945('0xd5')]===_0x186945('0x1d'))return _0x424dd7;if(_0xcff05['user'][_0x186945('0xd5')]!==_0x186945('0x1d'))return _0x424dd7;const _0x4c0b4d=_[_0x186945('0x14f')](_0x424dd7,function(_0x183f1b){const _0x5dc44d=_0x186945;return _0x183f1b[_0x5dc44d('0xd5')]==='agent'||_0x183f1b[_0x5dc44d('0xd5')]===_0x5dc44d('0xb1');});if(!_0x4c0b4d)return _0x424dd7;return db[_0x186945('0xad')][_0x186945('0x64')]({'where':{'name':{[Op['or']]:[_0x186945('0xd9'),_0x186945('0x13b')]},'userProfileId':_0xcff05[_0x186945('0x1d')][_0x186945('0x4b')]},'raw':!![]})[_0x186945('0x92')](function(_0x37b206){const _0x43a9db=_0x186945;if(_['isEmpty'](_0x37b206)||!_[_0x43a9db('0x14f')](_0x37b206,[_0x43a9db('0x1a'),0x0]))return _0x424dd7;_0x4a1cec=[];const _0x111fa8=_(_0x37b206)[_0x43a9db('0x9c')](function(_0x2b94a6){const _0x1b1c17=_0x43a9db;if(_0x2b94a6[_0x1b1c17('0x1a')]===0x1)return;return _0x2b94a6[_0x1b1c17('0xca')]===_0x1b1c17('0xd9')?_0x1b1c17('0x155'):_0x1b1c17('0xb1');})[_0x43a9db('0x9a')]()[_0x43a9db('0x6')]();for(let _0x391957=0x0;_0x391957<_0x424dd7[_0x43a9db('0x112')];_0x391957++){if(!_[_0x43a9db('0x116')](_0x111fa8,_0x424dd7[_0x391957][_0x43a9db('0xd5')]))return;const _0x57cdca=_0x424dd7[_0x391957]['role']==='agent'?_0x43a9db('0xd9'):_0x43a9db('0x13b');_0x4a1cec[_0x43a9db('0x10e')](db[_0x43a9db('0x141')]['create']({'name':_0x424dd7[_0x391957]['name'],'resourceId':_0x424dd7[_0x391957]['id'],'type':_0x57cdca,'sectionId':_[_0x43a9db('0x147')](_0x37b206,['name',_0x57cdca])['id']},{}));}return Promise[_0x43a9db('0x43')](_0x4a1cec);});})['then'](respondWithResult(_0x4f48e3,0xc9))['catch'](handleError(_0x4f48e3,null));},exports['update']=function(_0x1683c2,_0x397ca8){const _0x72707b=_0x5832ca;return _0x1683c2[_0x72707b('0x4d')]['id']&&delete _0x1683c2['body']['id'],delete _0x1683c2[_0x72707b('0x4d')]['role'],db['User'][_0x72707b('0xfa')]({'where':{'id':_0x1683c2[_0x72707b('0x2c')]['id']}})[_0x72707b('0x92')](handleEntityNotFound(_0x397ca8,null))[_0x72707b('0x92')](saveUpdates(_0x1683c2['body'],null))[_0x72707b('0x92')](respondWithResult(_0x397ca8,null))[_0x72707b('0x5b')](handleError(_0x397ca8,null));},exports[_0x5832ca('0x105')]=function(_0x349e84,_0x39e86c){const _0x41bd25=_0x5832ca;return db[_0x41bd25('0xaa')][_0x41bd25('0x105')]()[_0x41bd25('0x92')](respondWithResult(_0x39e86c,null))['catch'](handleError(_0x39e86c,null));},exports[_0x5832ca('0x16')]=function(_0x1f26d5,_0x7399f0){const _0x19a0e4=_0x5832ca;return db[_0x19a0e4('0xaa')][_0x19a0e4('0xfa')]({'where':{'id':_0x1f26d5[_0x19a0e4('0x2c')]['id']}})[_0x19a0e4('0x92')](handleEntityNotFound(_0x7399f0,null))[_0x19a0e4('0x92')](function(_0x4e9b03){const _0x44590b=_0x19a0e4;if(_0x4e9b03)return _0x4e9b03['addContacts'](_0x1f26d5['body'][_0x44590b('0xf5')],{'through':_[_0x44590b('0x34')](_0x1f26d5[_0x44590b('0x4d')],['ids','id'])});})[_0x19a0e4('0x92')](respondWithResult(_0x7399f0,null))['catch'](handleError(_0x7399f0,null));},exports['create']=function(_0x59624e,_0x10a474){const _0xb1ff7b=_0x5832ca;if(_0x59624e['user'][_0xb1ff7b('0xd5')]===_0xb1ff7b('0x155'))throw new Error(_0xb1ff7b('0x123'));if(_0x59624e['body'][_0xb1ff7b('0xd5')]===_0xb1ff7b('0x1d')&&_0x59624e[_0xb1ff7b('0x1d')]['role']!==_0xb1ff7b('0x67'))throw new Error(_0xb1ff7b('0x164'));if(_0x59624e[_0xb1ff7b('0x4d')][_0xb1ff7b('0xd5')]===_0xb1ff7b('0x67')&&_0x59624e[_0xb1ff7b('0x1d')][_0xb1ff7b('0xd5')]!==_0xb1ff7b('0x67'))throw new Error(_0xb1ff7b('0x41'));return licenseUtil[_0xb1ff7b('0x12f')]([_0x59624e[_0xb1ff7b('0x4d')]])[_0xb1ff7b('0x92')](function(){const _0x325117=_0xb1ff7b;return validateUser(_0x59624e[_0x325117('0x4d')]);})[_0xb1ff7b('0x92')](function(_0x5602fa){const _0x488966=_0xb1ff7b;return updateUser(_0x5602fa)[_0x488966('0x92')](function(_0x54bf6c){const _0x5cd08b=_0x488966;return _0x54bf6c['role']==='admin'&&(_0x54bf6c['settingsEnabled']=_0x59624e[_0x5cd08b('0x1d')]['settingsEnabled'],delete _0x54bf6c['userProfileId']),_0x54bf6c;});})[_0xb1ff7b('0x92')](function(_0x2e8103){const _0x79dfda=_0xb1ff7b;return db['User'][_0x79dfda('0x11b')](_0x2e8103,{'include':[{'model':db[_0x79dfda('0x10f')],'as':'VoiceMail'}]});})[_0xb1ff7b('0x92')](function(_0x51e3a3){const _0x5ee2b7=_0xb1ff7b;if(_0x59624e[_0x5ee2b7('0x4d')]['role']===_0x5ee2b7('0x1d'))return _0x51e3a3;if(_0x59624e[_0x5ee2b7('0x1d')][_0x5ee2b7('0xd5')]!==_0x5ee2b7('0x1d'))return _0x51e3a3;return db[_0x5ee2b7('0xad')][_0x5ee2b7('0xfa')]({'where':{'name':_0x51e3a3[_0x5ee2b7('0xd5')]==='agent'?_0x5ee2b7('0xd9'):_0x5ee2b7('0x13b'),'userProfileId':_0x59624e['user'][_0x5ee2b7('0x4b')]},'raw':!![]})[_0x5ee2b7('0x92')](function(_0xdae7c3){const _0x49b9d6=_0x5ee2b7;if(!_0xdae7c3||_0xdae7c3['autoAssociation']!=0x0)return _0x51e3a3;return db[_0x49b9d6('0x141')]['create']({'name':_0x51e3a3[_0x49b9d6('0xca')],'resourceId':_0x51e3a3['id'],'type':_0xdae7c3[_0x49b9d6('0xca')],'sectionId':_0xdae7c3['id']},{})[_0x49b9d6('0x92')](function(){return _0x51e3a3;});})['catch'](function(_0x1a2ddb){const _0x43eacc=_0x5ee2b7;logger[_0x43eacc('0x8')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x1a2ddb);throw _0x1a2ddb;});})['then'](respondWithResult(_0x10a474,0xc9))['catch'](handleError(_0x10a474,null));},exports[_0x5832ca('0x143')]=function(_0x1fd382,_0x2b4377){const _0x4e84d7=_0x5832ca;if(_0x1fd382[_0x4e84d7('0x4d')]['id'])delete _0x1fd382[_0x4e84d7('0x4d')]['id'];return db[_0x4e84d7('0xaa')][_0x4e84d7('0xfa')]({'where':{'id':_0x1fd382[_0x4e84d7('0x2c')]['id']}})['then'](function(_0x35c02f){const _0xc4a031=_0x4e84d7;if(!_0x35c02f)return null;if(_0x35c02f['id']===_0x1fd382[_0xc4a031('0x1d')]['id']){if(!_0x1fd382['body']['oldPassword']||!_0x1fd382[_0xc4a031('0x4d')]['newPassword'])throw new ValidationError(_0xc4a031('0xc7'));if(!_0x35c02f[_0xc4a031('0x7b')](_0x1fd382[_0xc4a031('0x4d')][_0xc4a031('0x122')]))throw new ValidationError('Wrong\x20credentials');if(_0x1fd382['body']['oldPassword']===_0x1fd382[_0xc4a031('0x4d')][_0xc4a031('0x13c')])throw new ValidationError(_0xc4a031('0xcb'));}else{if(_0x1fd382[_0xc4a031('0x1d')]['role']===_0xc4a031('0x67')){if(!_0x1fd382['body'][_0xc4a031('0x13c')])throw new ValidationError('Invalid\x20body\x20format.\x20Use\x20newPassword');}else{if(_0x1fd382['user'][_0xc4a031('0xd5')]===_0xc4a031('0x1d')){if(!_0x1fd382[_0xc4a031('0x4d')][_0xc4a031('0x13c')])throw new ValidationError(_0xc4a031('0x157'));if(_0x35c02f[_0xc4a031('0xd5')]!==_0xc4a031('0x155'))throw new ValidationError(_0xc4a031('0x123'));}else throw new ValidationError(_0xc4a031('0x123'));}}return _0x35c02f;})['then'](handleEntityNotFound(_0x2b4377,null))['then'](function(_0x3a277b){const _0x35738d=_0x4e84d7;return db[_0x35738d('0x2f')][_0x35738d('0xfa')]({'attributes':['id','securePassword',_0x35738d('0x48'),_0x35738d('0xfe')]})[_0x35738d('0x92')](function(_0x3304c7){const _0x3af862=_0x35738d;if(_0x3304c7[_0x3af862('0x71')])authService[_0x3af862('0x58')](_0x1fd382[_0x3af862('0x4d')][_0x3af862('0x13c')]);if(!_0x3304c7['enforcePasswordHistory']||!_0x3a277b[_0x3af862('0x14a')])return _0x3a277b;return authService['validatePasswordHistory'](_0x1fd382[_0x3af862('0x4d')][_0x3af862('0x13c')],_0x3a277b[_0x3af862('0x14a')],_0x3304c7[_0x3af862('0xfe')]),_0x3a277b;})['then'](saveUpdates({'password':_0x1fd382[_0x35738d('0x4d')][_0x35738d('0x13c')],'passwordResetAt':_0x1fd382[_0x35738d('0x1d')]['id']==_0x1fd382[_0x35738d('0x2c')]['id']?moment():null,'previousPasswords':authService[_0x35738d('0x11f')](_0x1fd382[_0x35738d('0x4d')][_0x35738d('0x13c')],_0x3a277b['previousPasswords'])},null));})[_0x4e84d7('0x92')](respondWithResult(_0x2b4377,null))[_0x4e84d7('0x5b')](handleError(_0x2b4377,null));},exports[_0x5832ca('0xc1')]=function(_0x3d7026,_0xba2c8d){const _0x391cb3=_0x5832ca,_0x423583=_0x3d7026[_0x391cb3('0x4d')][_0x391cb3('0xc4')];return db[_0x391cb3('0xaa')][_0x391cb3('0xfa')]({'where':{'id':_0x3d7026[_0x391cb3('0x2c')]['id']},'attributes':['id',_0x391cb3('0xca'),_0x391cb3('0xd5'),_0x391cb3('0x10a'),'loginInPause',_0x391cb3('0xf4'),_0x391cb3('0x1')]})['then'](handleEntityNotFound(_0xba2c8d,null))[_0x391cb3('0x92')](function(_0x7a3cc7){const _0x4181c0=_0x391cb3;if(_0x7a3cc7){if(!utils[_0x4181c0('0xbf')](_0x423583))throw new ValidationError(_0x4181c0('0x95'));return _0x7a3cc7[_0x4181c0('0x103')+_[_0x4181c0('0x154')](_0x423583[_0x4181c0('0x163')]())+_0x4181c0('0xf3')](_0x3d7026[_0x4181c0('0x4d')][_0x4181c0('0xf5')],{'through':{'penalty':_0x3d7026[_0x4181c0('0x4d')][_0x4181c0('0x120')]||0x0}})[_0x4181c0('0x92')](function(_0x274150){const _0x56a3e2=_0x4181c0;for(let _0x2dd155=0x0;_0x2dd155<_0x3d7026['body'][_0x56a3e2('0xf5')][_0x56a3e2('0x112')];_0x2dd155+=0x1){const _0x2ba3ec={'UserId':_0x3d7026['params']['id']};_0x2ba3ec[_[_0x56a3e2('0x154')](_0x423583['toLowerCase']())+_0x56a3e2('0x5f')]=_0x3d7026[_0x56a3e2('0x4d')][_0x56a3e2('0xf5')][_0x2dd155],socket[_0x56a3e2('0xee')](_0x56a3e2('0x1d')+_[_0x56a3e2('0x154')](_0x423583[_0x56a3e2('0x163')]())+_0x56a3e2('0x7f'),_0x2ba3ec);}return _0x274150;})[_0x4181c0('0x92')](function(){const _0x53a449=_0x4181c0;if(_0x423583==='voice')return db['VoiceQueue'][_0x53a449('0x64')]({'where':{'id':_0x3d7026[_0x53a449('0x4d')]['ids']||[]},'raw':!![],'attributes':['id','name']});})[_0x4181c0('0x92')](function(_0x592067){const _0x5931cf=_0x4181c0,_0x2015c9=_0x7a3cc7[_0x5931cf('0xc9')]({'plain':!![]}),_0x5d7370=[];if(_0x423583===_0x5931cf('0x137')&&_0x2015c9['role']==='agent'&&_0x2015c9[_0x5931cf('0x10a')]){for(let _0x290cea=0x0;_0x290cea<_0x592067[_0x5931cf('0x112')];_0x290cea+=0x1){_0x5d7370[_0x5931cf('0x10e')]({'membername':_0x2015c9[_0x5931cf('0xca')],'UserId':_0x2015c9['id'],'queue_name':_0x592067[_0x290cea][_0x5931cf('0xca')],'VoiceQueueId':_0x592067[_0x290cea]['id'],'interface':_['isNil'](_0x2015c9[_0x5931cf('0x1')])?util[_0x5931cf('0x8e')]('SIP/%s',_0x2015c9[_0x5931cf('0xca')]):_0x2015c9['interface'],'paused':_0x2015c9['voicePause']||![],'penalty':_0x3d7026[_0x5931cf('0x4d')][_0x5931cf('0x120')]||0x0});}return Promise['each'](_0x5d7370,function(_0x42de1a){const _0x38f6cc=_0x5931cf;return db[_0x38f6cc('0x91')][_0x38f6cc('0xb7')](_0x42de1a);});}return _0x7a3cc7;});}})[_0x391cb3('0x92')](respondWithStatusCode(_0xba2c8d,null))['catch'](handleError(_0xba2c8d,null));},exports['removeQueues']=function(_0x1d6080,_0x59b10e){const _0x18fcf0=_0x5832ca;let _0x215aff;return db[_0x18fcf0('0xaa')]['findOne']({'where':{'id':_0x1d6080[_0x18fcf0('0x2c')]['id']},'attributes':['id',_0x18fcf0('0xca'),_0x18fcf0('0xd5')]})[_0x18fcf0('0x92')](handleEntityNotFound(_0x59b10e,null))[_0x18fcf0('0x92')](function(_0x2488ba){const _0x2c7d32=_0x18fcf0;if(_0x2488ba){_0x215aff=_0x2488ba;if(!_0x1d6080[_0x2c7d32('0xd1')]['channel']||!utils['isValidChannel'](_0x1d6080[_0x2c7d32('0xd1')][_0x2c7d32('0xc4')]))throw new ValidationError(_0x2c7d32('0x95'));return _0x2488ba[_0x2c7d32('0x15')+_[_0x2c7d32('0x154')](_0x1d6080['query'][_0x2c7d32('0xc4')][_0x2c7d32('0x163')]())+_0x2c7d32('0xf3')](_0x1d6080[_0x2c7d32('0xd1')][_0x2c7d32('0xf5')]);}})['then'](function(_0x2fb402){const _0x42b6f1=_0x18fcf0;for(let _0x5cfd68=0x0;_0x5cfd68<_0x1d6080['query']['ids']['length'];_0x5cfd68+=0x1){const _0xe78d5e={'UserId':_0x1d6080[_0x42b6f1('0x2c')]['id']};_0xe78d5e[_[_0x42b6f1('0x154')](_0x1d6080[_0x42b6f1('0xd1')][_0x42b6f1('0xc4')]['toLowerCase']())+'QueueId']=_0x1d6080[_0x42b6f1('0xd1')][_0x42b6f1('0xf5')][_0x5cfd68],socket[_0x42b6f1('0xee')](_0x42b6f1('0x1d')+_[_0x42b6f1('0x154')](_0x1d6080['query'][_0x42b6f1('0xc4')][_0x42b6f1('0x163')]())+'Queue:remove',_0xe78d5e);}return _0x2fb402;})[_0x18fcf0('0x92')](function(){const _0x4aff6f=_0x18fcf0;if(_0x1d6080[_0x4aff6f('0xd1')]['channel']===_0x4aff6f('0x137'))return db[_0x4aff6f('0x91')][_0x4aff6f('0x12c')]({'where':{'UserId':_0x1d6080[_0x4aff6f('0x2c')]['id'],'VoiceQueueId':_0x1d6080[_0x4aff6f('0xd1')][_0x4aff6f('0xf5')]},'individualHooks':!![]})[_0x4aff6f('0x92')](function(){return _0x215aff;});return _0x215aff;})[_0x18fcf0('0x92')](respondWithStatusCode(_0x59b10e,null))[_0x18fcf0('0x5b')](handleError(_0x59b10e,null));},exports[_0x5832ca('0x62')]=function(_0x45f5ee,_0x8e417a){const _0x3287d8=_0x5832ca;return _0x45f5ee[_0x3287d8('0x4d')]['userpic']=_0x45f5ee[_0x3287d8('0x11')][_0x3287d8('0xef')],db[_0x3287d8('0xaa')][_0x3287d8('0xfa')]({'where':{'id':_0x45f5ee[_0x3287d8('0x2c')]['id']}})[_0x3287d8('0x92')](handleEntityNotFound(_0x8e417a,null))['then'](saveUpdates(_0x45f5ee['body'],null))[_0x3287d8('0x92')](respondWithResult(_0x8e417a,null))[_0x3287d8('0x5b')](handleError(_0x8e417a,null));},exports['getAvatar']=function(_0x233e34,_0x11e6f7){const _0x376a42=_0x5832ca,_0x2234cf=path['join'](config[_0x376a42('0xfd')],_0x376a42('0xe3'));return db[_0x376a42('0xaa')][_0x376a42('0xfa')]({'where':{'id':_0x233e34[_0x376a42('0x2c')]['id']},'attributes':['id',_0x376a42('0x144')],'raw':!![]})['then'](handleEntityNotFound(_0x11e6f7,null))[_0x376a42('0x92')](function(_0x1c1ccd){const _0x2187d8=_0x376a42;if(_0x1c1ccd){if(_[_0x2187d8('0xc5')](_0x1c1ccd[_0x2187d8('0x144')]))return _0x11e6f7[_0x2187d8('0xd7')](_0x2234cf);else{if(!fs['existsSync'](path[_0x2187d8('0x133')](config[_0x2187d8('0xfd')],_0x2187d8('0x77'),_0x1c1ccd['userpic'])))return _0x11e6f7[_0x2187d8('0xd7')](_0x2234cf);return _0x11e6f7[_0x2187d8('0xd7')](path[_0x2187d8('0x133')](config[_0x2187d8('0xfd')],_0x2187d8('0x77'),_0x1c1ccd['userpic']));}}})['catch'](handleError(_0x11e6f7,null));},exports[_0x5832ca('0x146')]=function(_0x2b4147,_0x428ff6){const _0x528234=_0x5832ca;let _0x3909b8={};const _0x2cc924={};let _0x3e622e,_0x50da06;return db['User'][_0x528234('0xfa')]({'where':{'id':_0x2b4147[_0x528234('0x2c')]['id']}})[_0x528234('0x92')](handleEntityNotFound(_0x428ff6,null))[_0x528234('0x92')](function(_0x5cd1de){const _0x296c0d=_0x528234;if(_0x5cd1de)return _0x3e622e=_0x5cd1de,_0x2cc924[_0x296c0d('0x3f')]=_[_0x296c0d('0x4e')](db[_0x296c0d('0x9f')]['rawAttributes']),_0x2cc924[_0x296c0d('0xd1')]=_[_0x296c0d('0x4e')](_0x2b4147['query']),_0x2cc924[_0x296c0d('0x36')]=_[_0x296c0d('0x13f')](_0x2cc924[_0x296c0d('0x3f')],_0x2cc924['query']),_0x3909b8['attributes']=_[_0x296c0d('0x13f')](_0x2cc924[_0x296c0d('0x3f')],qs[_0x296c0d('0xf')](_0x2b4147[_0x296c0d('0xd1')][_0x296c0d('0xf')])),_0x3909b8[_0x296c0d('0x11a')]=_0x3909b8[_0x296c0d('0x11a')]['length']?_0x3909b8[_0x296c0d('0x11a')]:_0x2cc924[_0x296c0d('0x3f')],_0x3909b8[_0x296c0d('0xa3')]=qs['sort'](_0x2b4147['query'][_0x296c0d('0x25')]),_0x3909b8['where']=qs[_0x296c0d('0x36')](_[_0x296c0d('0xa')](_0x2b4147[_0x296c0d('0xd1')],_0x2cc924['filters'])),_0x2b4147[_0x296c0d('0xd1')][_0x296c0d('0xf8')]&&(_0x3909b8[_0x296c0d('0x13a')]=_['merge'](_0x3909b8[_0x296c0d('0x13a')],{[Op['or']]:_[_0x296c0d('0x9c')](_0x3909b8['attributes'],function(_0x1a90a1){const _0x5736f6=_0x296c0d,_0x28c3a1={};return _0x28c3a1[_0x1a90a1]={[Op[_0x5736f6('0x75')]]:'%'+_0x2b4147['query']['filter']+'%'},_0x28c3a1;})})),_0x3909b8=_['merge']({},_0x3909b8,_0x2b4147['options']),_0x3e622e[_0x296c0d('0x146')](_0x3909b8);})[_0x528234('0x92')](function(_0x523ce1){const _0x53f407=_0x528234;if(_0x523ce1)return _0x50da06=_0x523ce1[_0x53f407('0x112')],typeof _0x2b4147['query']['includeAll']!==_0x53f407('0x7d')&&(_0x3909b8[_0x53f407('0x32')]=[{'model':db[_0x53f407('0x51')],'as':_0x53f407('0xda'),'required':![]},{'model':db[_0x53f407('0x83')],'as':'Tags','attributes':['id',_0x53f407('0xca'),_0x53f407('0x79')],'where':_0x2b4147['query'][_0x53f407('0xd0')]?{'id':_0x2b4147[_0x53f407('0xd1')][_0x53f407('0xd0')]}:undefined,'required':_0x2b4147[_0x53f407('0xd1')][_0x53f407('0xd0')]?!![]:![]}]),typeof _0x2b4147[_0x53f407('0xd1')]['nolimit']===_0x53f407('0x7d')&&(_0x3909b8[_0x53f407('0x11d')]=qs[_0x53f407('0x11d')](_0x2b4147[_0x53f407('0xd1')][_0x53f407('0x11d')]),_0x3909b8[_0x53f407('0x89')]=qs[_0x53f407('0x89')](_0x2b4147[_0x53f407('0xd1')][_0x53f407('0x89')])),_0x3e622e[_0x53f407('0x146')](_0x3909b8);})[_0x528234('0x92')](function(_0x1b0fd3){if(_0x1b0fd3)return _0x1b0fd3?{'count':_0x50da06,'rows':_0x1b0fd3}:null;})[_0x528234('0x92')](respondWithResult(_0x428ff6,null))[_0x528234('0x5b')](handleError(_0x428ff6,null));},exports[_0x5832ca('0x108')]=function(_0xd33202,_0x4c9294){const _0x4fb5f2=_0x5832ca;let _0x4588c4,_0x30d37f={},_0x9a7015;return db[_0x4fb5f2('0xaa')][_0x4fb5f2('0xfa')]({'where':{'id':_0xd33202[_0x4fb5f2('0x2c')]['id']},'attributes':['id',_0x4fb5f2('0xca'),_0x4fb5f2('0xd5')]})[_0x4fb5f2('0x92')](handleEntityNotFound(_0x4c9294,null))[_0x4fb5f2('0x92')](function(_0x41e285){const _0xbe6c8b=_0x4fb5f2;if(!utils['isValidChannel'](_0xd33202[_0xbe6c8b('0xd1')]['channel']))throw new ValidationError(_0xbe6c8b('0x95'));_0x4588c4=_0x41e285;const _0x17fff4={};_0x17fff4[_0xbe6c8b('0x3f')]=_[_0xbe6c8b('0x4e')](db[_[_0xbe6c8b('0x154')](_0xd33202[_0xbe6c8b('0xd1')][_0xbe6c8b('0xc4')])+_0xbe6c8b('0x74')][_0xbe6c8b('0xea')]),_0x17fff4['query']=_[_0xbe6c8b('0x4e')](_0xd33202[_0xbe6c8b('0xd1')]),_0x17fff4[_0xbe6c8b('0x36')]=_[_0xbe6c8b('0x13f')](_0x17fff4[_0xbe6c8b('0x3f')],_0x17fff4[_0xbe6c8b('0xd1')]),_0x30d37f[_0xbe6c8b('0x11a')]=_[_0xbe6c8b('0x13f')](_0x17fff4[_0xbe6c8b('0x3f')],qs[_0xbe6c8b('0xf')](_0xd33202[_0xbe6c8b('0xd1')][_0xbe6c8b('0xf')])),_0x30d37f[_0xbe6c8b('0x11a')]=_0x30d37f[_0xbe6c8b('0x11a')][_0xbe6c8b('0x112')]?_0x30d37f[_0xbe6c8b('0x11a')]:_0x17fff4[_0xbe6c8b('0x3f')],_0x30d37f['order']=qs['sort'](_0xd33202[_0xbe6c8b('0xd1')]['sort']),_0x30d37f[_0xbe6c8b('0x13a')]=qs[_0xbe6c8b('0x36')](_[_0xbe6c8b('0xa')](_0xd33202['query'],_0x17fff4['filters']));_0xd33202[_0xbe6c8b('0xd1')][_0xbe6c8b('0xf8')]&&(_0x30d37f[_0xbe6c8b('0x13a')]=_['merge'](_0x30d37f[_0xbe6c8b('0x13a')],{[Op['or']]:_['map'](_0x30d37f[_0xbe6c8b('0x11a')],function(_0x2f0f6d){const _0x2e363a=_0xbe6c8b,_0x27b389={};return _0x27b389[_0x2f0f6d]={[Op[_0x2e363a('0x75')]]:'%'+_0xd33202['query'][_0x2e363a('0xf8')]+'%'},_0x27b389;})}));_0x30d37f=_[_0xbe6c8b('0x10d')]({},_0x30d37f,_0xd33202[_0xbe6c8b('0x6d')]);switch(_0x4588c4['role']){case _0xbe6c8b('0x67'):return db[_[_0xbe6c8b('0x154')](_0xd33202[_0xbe6c8b('0xd1')][_0xbe6c8b('0xc4')])+_0xbe6c8b('0x74')][_0xbe6c8b('0x64')](_0x30d37f);case _0xbe6c8b('0x1d'):case _0xbe6c8b('0x155'):return _0x4588c4['get'+_[_0xbe6c8b('0x154')](_0xd33202[_0xbe6c8b('0xd1')]['channel'])+_0xbe6c8b('0xf3')](_0x30d37f);default:throw new ValidationError(_0xbe6c8b('0x50'));}})[_0x4fb5f2('0x92')](function(_0x42ccb5){const _0x1b57b5=_0x4fb5f2;_0x9a7015=_0x42ccb5[_0x1b57b5('0x112')];typeof _0xd33202['query'][_0x1b57b5('0x14c')]===_0x1b57b5('0x7d')&&(_0x30d37f[_0x1b57b5('0x11d')]=qs[_0x1b57b5('0x11d')](_0xd33202[_0x1b57b5('0xd1')]['limit']),_0x30d37f[_0x1b57b5('0x89')]=qs[_0x1b57b5('0x89')](_0xd33202[_0x1b57b5('0xd1')][_0x1b57b5('0x89')]));switch(_0x4588c4[_0x1b57b5('0xd5')]){case _0x1b57b5('0x67'):return db[_['capitalize'](_0xd33202[_0x1b57b5('0xd1')][_0x1b57b5('0xc4')])+_0x1b57b5('0x74')][_0x1b57b5('0x64')](_0x30d37f);case _0x1b57b5('0x1d'):case _0x1b57b5('0x155'):return _0x4588c4['get'+_[_0x1b57b5('0x154')](_0xd33202[_0x1b57b5('0xd1')][_0x1b57b5('0xc4')])+'Queues'](_0x30d37f);}})['then'](function(_0xb2c5d4){return{'count':_0x9a7015,'rows':_0xb2c5d4};})[_0x4fb5f2('0x92')](respondWithResult(_0x4c9294,null))[_0x4fb5f2('0x5b')](handleError(_0x4c9294,null));},exports['getVoiceQueuesRt']=function(_0x1ac2b6,_0x4b0f93){const _0xed612b=_0x5832ca;let _0x2fc439={};const _0x2ad6a8={};let _0xe27b14,_0x804354;return db[_0xed612b('0xaa')]['findOne']({'where':{'id':_0x1ac2b6[_0xed612b('0x2c')]['id']}})[_0xed612b('0x92')](handleEntityNotFound(_0x4b0f93,null))[_0xed612b('0x92')](function(_0x2cd1a2){const _0x3e4d74=_0xed612b;if(_0x2cd1a2)return _0xe27b14=_0x2cd1a2,_0x2ad6a8[_0x3e4d74('0x3f')]=_['keys'](db[_0x3e4d74('0x91')]['rawAttributes']),_0x2ad6a8[_0x3e4d74('0xd1')]=_[_0x3e4d74('0x4e')](_0x1ac2b6[_0x3e4d74('0xd1')]),_0x2ad6a8[_0x3e4d74('0x36')]=_[_0x3e4d74('0x13f')](_0x2ad6a8['model'],_0x2ad6a8['query']),_0x2fc439[_0x3e4d74('0x11a')]=_[_0x3e4d74('0x13f')](_0x2ad6a8[_0x3e4d74('0x3f')],qs[_0x3e4d74('0xf')](_0x1ac2b6[_0x3e4d74('0xd1')][_0x3e4d74('0xf')])),_0x2fc439[_0x3e4d74('0x11a')]=_0x2fc439['attributes'][_0x3e4d74('0x112')]?_0x2fc439[_0x3e4d74('0x11a')]:_0x2ad6a8[_0x3e4d74('0x3f')],_0x2fc439[_0x3e4d74('0xa3')]=qs[_0x3e4d74('0x25')](_0x1ac2b6['query'][_0x3e4d74('0x25')]),_0x2fc439[_0x3e4d74('0x13a')]=qs[_0x3e4d74('0x36')](_[_0x3e4d74('0xa')](_0x1ac2b6[_0x3e4d74('0xd1')],_0x2ad6a8['filters'])),_0x1ac2b6[_0x3e4d74('0xd1')][_0x3e4d74('0xf8')]&&(_0x2fc439[_0x3e4d74('0x13a')]=_[_0x3e4d74('0x10d')](_0x2fc439['where'],{[Op['or']]:_['map'](_0x2fc439['attributes'],function(_0x22c1cc){const _0x1d8844=_0x3e4d74,_0x4ad179={};return _0x4ad179[_0x22c1cc]={[Op[_0x1d8844('0x75')]]:'%'+_0x1ac2b6['query'][_0x1d8844('0xf8')]+'%'},_0x4ad179;})})),_0x2fc439=_[_0x3e4d74('0x10d')]({},_0x2fc439,_0x1ac2b6[_0x3e4d74('0x6d')]),_0xe27b14[_0x3e4d74('0xe')](_0x2fc439);})[_0xed612b('0x92')](function(_0x4b35ec){const _0x5cf59a=_0xed612b;if(_0x4b35ec)return _0x804354=_0x4b35ec['length'],typeof _0x1ac2b6[_0x5cf59a('0xd1')][_0x5cf59a('0x14c')]===_0x5cf59a('0x7d')&&(_0x2fc439[_0x5cf59a('0x11d')]=qs[_0x5cf59a('0x11d')](_0x1ac2b6[_0x5cf59a('0xd1')][_0x5cf59a('0x11d')]),_0x2fc439['offset']=qs[_0x5cf59a('0x89')](_0x1ac2b6[_0x5cf59a('0xd1')][_0x5cf59a('0x89')])),_0xe27b14[_0x5cf59a('0xe')](_0x2fc439);})[_0xed612b('0x92')](function(_0x4bca07){if(_0x4bca07)return _0x4bca07?{'count':_0x804354,'rows':_0x4bca07}:null;})[_0xed612b('0x92')](respondWithResult(_0x4b0f93,null))[_0xed612b('0x5b')](handleError(_0x4b0f93,null));},exports['getGroups']=function(_0x108d6c,_0x503ada){const _0x204b7c=_0x5832ca;let _0x47e1a7={};const _0x3541f0={};let _0x345600,_0xfed8f5;return db['User']['findOne']({'where':{'id':_0x108d6c[_0x204b7c('0x2c')]['id']}})[_0x204b7c('0x92')](handleEntityNotFound(_0x503ada,null))[_0x204b7c('0x92')](function(_0x47d23c){const _0x2c53ac=_0x204b7c;if(_0x47d23c)return _0x345600=_0x47d23c,_0x3541f0[_0x2c53ac('0x3f')]=_[_0x2c53ac('0x4e')](db[_0x2c53ac('0x127')][_0x2c53ac('0xea')]),_0x3541f0['query']=_[_0x2c53ac('0x4e')](_0x108d6c['query']),_0x3541f0['filters']=_[_0x2c53ac('0x13f')](_0x3541f0[_0x2c53ac('0x3f')],_0x3541f0[_0x2c53ac('0xd1')]),_0x47e1a7[_0x2c53ac('0x11a')]=_[_0x2c53ac('0x13f')](_0x3541f0['model'],qs[_0x2c53ac('0xf')](_0x108d6c[_0x2c53ac('0xd1')][_0x2c53ac('0xf')])),_0x47e1a7[_0x2c53ac('0x11a')]=_0x47e1a7[_0x2c53ac('0x11a')][_0x2c53ac('0x112')]?_0x47e1a7[_0x2c53ac('0x11a')]:_0x3541f0[_0x2c53ac('0x3f')],_0x47e1a7['order']=qs[_0x2c53ac('0x25')](_0x108d6c[_0x2c53ac('0xd1')]['sort']),_0x47e1a7['where']=qs[_0x2c53ac('0x36')](_[_0x2c53ac('0xa')](_0x108d6c[_0x2c53ac('0xd1')],_0x3541f0[_0x2c53ac('0x36')])),_0x108d6c[_0x2c53ac('0xd1')]['filter']&&(_0x47e1a7[_0x2c53ac('0x13a')]=_[_0x2c53ac('0x10d')](_0x47e1a7['where'],{[Op['or']]:_[_0x2c53ac('0x9c')](_0x47e1a7[_0x2c53ac('0x11a')],function(_0x1055ec){const _0x5b6f4f=_0x2c53ac,_0x446e81={};return _0x446e81[_0x1055ec]={[Op[_0x5b6f4f('0x75')]]:'%'+_0x108d6c[_0x5b6f4f('0xd1')][_0x5b6f4f('0xf8')]+'%'},_0x446e81;})})),_0x47e1a7=_[_0x2c53ac('0x10d')]({},_0x47e1a7,_0x108d6c[_0x2c53ac('0x6d')]),_0x345600[_0x2c53ac('0xfc')](_0x47e1a7);})[_0x204b7c('0x92')](function(_0x49d75a){const _0x53e9bf=_0x204b7c;if(_0x49d75a)return _0xfed8f5=_0x49d75a[_0x53e9bf('0x112')],typeof _0x108d6c[_0x53e9bf('0xd1')][_0x53e9bf('0x14c')]===_0x53e9bf('0x7d')&&(_0x47e1a7[_0x53e9bf('0x11d')]=qs[_0x53e9bf('0x11d')](_0x108d6c[_0x53e9bf('0xd1')][_0x53e9bf('0x11d')]),_0x47e1a7[_0x53e9bf('0x89')]=qs[_0x53e9bf('0x89')](_0x108d6c[_0x53e9bf('0xd1')][_0x53e9bf('0x89')])),_0x345600[_0x53e9bf('0xfc')](_0x47e1a7);})[_0x204b7c('0x92')](function(_0xf5bafd){if(_0xf5bafd)return _0xf5bafd?{'count':_0xfed8f5,'rows':_0xf5bafd}:null;})[_0x204b7c('0x92')](respondWithResult(_0x503ada,null))[_0x204b7c('0x5b')](handleError(_0x503ada,null));},exports[_0x5832ca('0x153')]=function(_0x260e47,_0x50a987){const _0x11ddef=_0x5832ca;let _0x22fd81={'raw':!![],'where':{}};const _0x4ea163={},_0x13369a={'count':0x0,'rows':[]};return db[_0x11ddef('0xaa')][_0x11ddef('0xfa')]({'where':{'id':_0x260e47[_0x11ddef('0x2c')]['id']}})[_0x11ddef('0x92')](handleEntityNotFound(_0x50a987,null))[_0x11ddef('0x92')](function(_0x40af6e){const _0x415325=_0x11ddef;if(_0x40af6e)return _0x4ea163['model']=_[_0x415325('0x4e')](db[_0x415325('0x131')]['rawAttributes']),_0x4ea163[_0x415325('0xd1')]=_[_0x415325('0x4e')](_0x260e47[_0x415325('0xd1')]),_0x4ea163[_0x415325('0x36')]=_[_0x415325('0x13f')](_0x4ea163[_0x415325('0x3f')],_0x4ea163['query']),_0x22fd81[_0x415325('0x11a')]=_[_0x415325('0x13f')](_0x4ea163[_0x415325('0x3f')],qs[_0x415325('0xf')](_0x260e47['query']['fields'])),_0x22fd81['attributes']=_0x22fd81['attributes'][_0x415325('0x112')]?_0x22fd81['attributes']:_0x4ea163[_0x415325('0x3f')],typeof _0x260e47['query'][_0x415325('0x14c')]==='undefined'&&(_0x22fd81[_0x415325('0x11d')]=qs[_0x415325('0x11d')](_0x260e47[_0x415325('0xd1')][_0x415325('0x11d')]),_0x22fd81[_0x415325('0x89')]=qs[_0x415325('0x89')](_0x260e47[_0x415325('0xd1')][_0x415325('0x89')])),_0x22fd81[_0x415325('0xa3')]=qs[_0x415325('0x25')](_0x260e47[_0x415325('0xd1')][_0x415325('0x25')]),_0x22fd81[_0x415325('0x13a')]=qs['filters'](_['pick'](_0x260e47['query'],_0x4ea163[_0x415325('0x36')])),_0x22fd81[_0x415325('0x13a')]['UserId']=_0x40af6e['id'],_0x260e47[_0x415325('0xd1')][_0x415325('0xf8')]&&(_0x22fd81['where']=_[_0x415325('0x10d')](_0x22fd81[_0x415325('0x13a')],{[Op['or']]:_[_0x415325('0x9c')](_0x22fd81['attributes'],function(_0xff5c11){const _0xa5f83d=_0x415325,_0x478b40={};return _0x478b40[_0xff5c11]={[Op['like']]:'%'+_0x260e47[_0xa5f83d('0xd1')][_0xa5f83d('0xf8')]+'%'},_0x478b40;})})),_0x22fd81=_[_0x415325('0x10d')]({},_0x22fd81,_0x260e47[_0x415325('0x6d')]),db[_0x415325('0x131')]['count']({'where':_0x22fd81[_0x415325('0x13a')]})['then'](function(_0x1a2713){const _0x3ea5d8=_0x415325;return _0x13369a[_0x3ea5d8('0x162')]=_0x1a2713,_0x260e47[_0x3ea5d8('0xd1')][_0x3ea5d8('0x102')]&&(_0x22fd81['include']=[{'all':!![]}]),db[_0x3ea5d8('0x131')][_0x3ea5d8('0x64')](_0x22fd81);})[_0x415325('0x92')](function(_0x1a976a){return _0x13369a['rows']=_0x1a976a,_0x13369a;});})[_0x11ddef('0x92')](respondWithFilteredResult(_0x50a987,_0x22fd81))[_0x11ddef('0x5b')](handleError(_0x50a987,null));},exports[_0x5832ca('0x3c')]=function(_0x1c0251,_0x25d411){const _0x45ae5e=_0x5832ca;let _0xd17669={'raw':!![],'where':{}};const _0x3b7928={},_0x30309c={'count':0x0,'rows':[]};return db[_0x45ae5e('0xaa')][_0x45ae5e('0xfa')]({'where':{'id':_0x1c0251[_0x45ae5e('0x2c')]['id']}})[_0x45ae5e('0x92')](handleEntityNotFound(_0x25d411,null))[_0x45ae5e('0x92')](function(_0xf0217d){const _0x379196=_0x45ae5e;if(_0xf0217d)return _0x3b7928[_0x379196('0x3f')]=_[_0x379196('0x4e')](db[_0x379196('0xb8')][_0x379196('0xea')]),_0x3b7928[_0x379196('0xd1')]=_[_0x379196('0x4e')](_0x1c0251[_0x379196('0xd1')]),_0x3b7928[_0x379196('0x36')]=_[_0x379196('0x13f')](_0x3b7928[_0x379196('0x3f')],_0x3b7928[_0x379196('0xd1')]),_0xd17669[_0x379196('0x11a')]=_['intersection'](_0x3b7928['model'],qs[_0x379196('0xf')](_0x1c0251[_0x379196('0xd1')][_0x379196('0xf')])),_0xd17669[_0x379196('0x11a')]=_0xd17669['attributes']['length']?_0xd17669['attributes']:_0x3b7928[_0x379196('0x3f')],typeof _0x1c0251[_0x379196('0xd1')][_0x379196('0x14c')]===_0x379196('0x7d')&&(_0xd17669['limit']=qs['limit'](_0x1c0251[_0x379196('0xd1')]['limit']),_0xd17669[_0x379196('0x89')]=qs[_0x379196('0x89')](_0x1c0251[_0x379196('0xd1')]['offset'])),_0xd17669[_0x379196('0xa3')]=qs['sort'](_0x1c0251[_0x379196('0xd1')][_0x379196('0x25')]),_0xd17669[_0x379196('0x13a')]=qs['filters'](_[_0x379196('0xa')](_0x1c0251[_0x379196('0xd1')],_0x3b7928[_0x379196('0x36')])),_0xd17669[_0x379196('0x13a')][_0x379196('0xb6')]=_0xf0217d['id'],_0x1c0251[_0x379196('0xd1')][_0x379196('0xf8')]&&(_0xd17669[_0x379196('0x13a')]=_[_0x379196('0x10d')](_0xd17669[_0x379196('0x13a')],{[Op['or']]:_[_0x379196('0x9c')](_0xd17669[_0x379196('0x11a')],function(_0x36e0f4){const _0x3cd856=_0x379196,_0xbbc88d={};return _0xbbc88d[_0x36e0f4]={[Op[_0x3cd856('0x75')]]:'%'+_0x1c0251[_0x3cd856('0xd1')][_0x3cd856('0xf8')]+'%'},_0xbbc88d;})})),_0xd17669=_[_0x379196('0x10d')]({},_0xd17669,_0x1c0251['options']),db[_0x379196('0xb8')][_0x379196('0x162')]({'where':_0xd17669['where']})[_0x379196('0x92')](function(_0x3541bc){const _0x32a8a4=_0x379196;return _0x30309c[_0x32a8a4('0x162')]=_0x3541bc,_0x1c0251[_0x32a8a4('0xd1')]['includeAll']&&(_0xd17669[_0x32a8a4('0x32')]=[{'all':!![]}]),db[_0x32a8a4('0xb8')][_0x32a8a4('0x64')](_0xd17669);})[_0x379196('0x92')](function(_0x465dc2){return _0x30309c['rows']=_0x465dc2,_0x30309c;});})[_0x45ae5e('0x92')](respondWithFilteredResult(_0x25d411,_0xd17669))[_0x45ae5e('0x5b')](handleError(_0x25d411,null));},exports['getChatInteractions']=function(_0x1276b0,_0x4a4852){const _0x1b0ac0=_0x5832ca;let _0x1cf3c0={};const _0x8c4e11={};let _0x5abf2f,_0x29526e;return db[_0x1b0ac0('0xaa')][_0x1b0ac0('0xfa')]({'where':{'id':_0x1276b0[_0x1b0ac0('0x2c')]['id']}})[_0x1b0ac0('0x92')](handleEntityNotFound(_0x4a4852,null))[_0x1b0ac0('0x92')](function(_0x4ddfcd){const _0x3c8fe7=_0x1b0ac0;if(_0x4ddfcd)return _0x5abf2f=_0x4ddfcd,_0x8c4e11[_0x3c8fe7('0x3f')]=_['keys'](db[_0x3c8fe7('0x8b')]['rawAttributes']),_0x8c4e11[_0x3c8fe7('0xd1')]=_[_0x3c8fe7('0x4e')](_0x1276b0['query']),_0x8c4e11[_0x3c8fe7('0x36')]=_[_0x3c8fe7('0x13f')](_0x8c4e11[_0x3c8fe7('0x3f')],_0x8c4e11['query']),_0x1cf3c0[_0x3c8fe7('0x11a')]=_[_0x3c8fe7('0x13f')](_0x8c4e11[_0x3c8fe7('0x3f')],qs[_0x3c8fe7('0xf')](_0x1276b0[_0x3c8fe7('0xd1')][_0x3c8fe7('0xf')])),_0x1cf3c0['attributes']=_0x1cf3c0[_0x3c8fe7('0x11a')]['length']?_0x1cf3c0[_0x3c8fe7('0x11a')]:_0x8c4e11[_0x3c8fe7('0x3f')],_0x1cf3c0['order']=qs[_0x3c8fe7('0x25')](_0x1276b0[_0x3c8fe7('0xd1')][_0x3c8fe7('0x25')]),_0x1cf3c0[_0x3c8fe7('0x13a')]=qs['filters'](_[_0x3c8fe7('0xa')](_0x1276b0['query'],_0x8c4e11[_0x3c8fe7('0x36')])),_0x1276b0[_0x3c8fe7('0xd1')][_0x3c8fe7('0xf8')]&&(_0x1cf3c0[_0x3c8fe7('0x13a')]=_[_0x3c8fe7('0x10d')](_0x1cf3c0[_0x3c8fe7('0x13a')],{[Op['or']]:_[_0x3c8fe7('0x9c')](_0x1cf3c0[_0x3c8fe7('0x11a')],function(_0x595aef){const _0x47e643=_0x3c8fe7,_0x4d39a3={};return _0x4d39a3[_0x595aef]={[Op[_0x47e643('0x75')]]:'%'+_0x1276b0[_0x47e643('0xd1')][_0x47e643('0xf8')]+'%'},_0x4d39a3;})})),_0x1cf3c0=_['merge']({},_0x1cf3c0,_0x1276b0[_0x3c8fe7('0x6d')]),_0x5abf2f[_0x3c8fe7('0x128')](_0x1cf3c0);})[_0x1b0ac0('0x92')](function(_0x33a5f9){const _0x512ad3=_0x1b0ac0;if(_0x33a5f9)return _0x29526e=_0x33a5f9[_0x512ad3('0x112')],typeof _0x1276b0[_0x512ad3('0xd1')]['nolimit']==='undefined'&&(_0x1cf3c0[_0x512ad3('0x11d')]=qs['limit'](_0x1276b0['query'][_0x512ad3('0x11d')]),_0x1cf3c0[_0x512ad3('0x89')]=qs['offset'](_0x1276b0[_0x512ad3('0xd1')][_0x512ad3('0x89')])),_0x5abf2f[_0x512ad3('0x128')](_0x1cf3c0);})[_0x1b0ac0('0x92')](function(_0x4911a7){if(_0x4911a7)return _0x4911a7?{'count':_0x29526e,'rows':_0x4911a7}:null;})[_0x1b0ac0('0x92')](respondWithResult(_0x4a4852,null))[_0x1b0ac0('0x5b')](handleError(_0x4a4852,null));},exports['getOpenchannelInteractions']=function(_0x3df6f9,_0x4efd78){const _0x423260=_0x5832ca;let _0x1144a6={};const _0x284264={};let _0x299dea,_0x98ad62;return db[_0x423260('0xaa')][_0x423260('0xfa')]({'where':{'id':_0x3df6f9[_0x423260('0x2c')]['id']}})[_0x423260('0x92')](handleEntityNotFound(_0x4efd78,null))[_0x423260('0x92')](function(_0x685f51){const _0x1a4675=_0x423260;if(_0x685f51)return _0x299dea=_0x685f51,_0x284264[_0x1a4675('0x3f')]=_[_0x1a4675('0x4e')](db[_0x1a4675('0x6a')][_0x1a4675('0xea')]),_0x284264[_0x1a4675('0xd1')]=_['keys'](_0x3df6f9[_0x1a4675('0xd1')]),_0x284264[_0x1a4675('0x36')]=_['intersection'](_0x284264[_0x1a4675('0x3f')],_0x284264[_0x1a4675('0xd1')]),_0x1144a6[_0x1a4675('0x11a')]=_[_0x1a4675('0x13f')](_0x284264[_0x1a4675('0x3f')],qs['fields'](_0x3df6f9[_0x1a4675('0xd1')]['fields'])),_0x1144a6[_0x1a4675('0x11a')]=_0x1144a6[_0x1a4675('0x11a')][_0x1a4675('0x112')]?_0x1144a6[_0x1a4675('0x11a')]:_0x284264[_0x1a4675('0x3f')],_0x1144a6[_0x1a4675('0xa3')]=qs[_0x1a4675('0x25')](_0x3df6f9[_0x1a4675('0xd1')][_0x1a4675('0x25')]),_0x1144a6[_0x1a4675('0x13a')]=qs[_0x1a4675('0x36')](_['pick'](_0x3df6f9[_0x1a4675('0xd1')],_0x284264[_0x1a4675('0x36')])),_0x3df6f9[_0x1a4675('0xd1')]['filter']&&(_0x1144a6[_0x1a4675('0x13a')]=_[_0x1a4675('0x10d')](_0x1144a6[_0x1a4675('0x13a')],{[Op['or']]:_[_0x1a4675('0x9c')](_0x1144a6['attributes'],function(_0x25de0c){const _0x59a849=_0x1a4675,_0x183fed={};return _0x183fed[_0x25de0c]={[Op[_0x59a849('0x75')]]:'%'+_0x3df6f9[_0x59a849('0xd1')]['filter']+'%'},_0x183fed;})})),_0x1144a6=_[_0x1a4675('0x10d')]({},_0x1144a6,_0x3df6f9[_0x1a4675('0x6d')]),_0x299dea['getOpenchannelInteractions'](_0x1144a6);})[_0x423260('0x92')](function(_0x5e4a79){const _0x3b2791=_0x423260;if(_0x5e4a79)return _0x98ad62=_0x5e4a79[_0x3b2791('0x112')],typeof _0x3df6f9['query'][_0x3b2791('0x14c')]==='undefined'&&(_0x1144a6['limit']=qs['limit'](_0x3df6f9[_0x3b2791('0xd1')][_0x3b2791('0x11d')]),_0x1144a6['offset']=qs[_0x3b2791('0x89')](_0x3df6f9[_0x3b2791('0xd1')][_0x3b2791('0x89')])),_0x299dea[_0x3b2791('0x7a')](_0x1144a6);})[_0x423260('0x92')](function(_0xe2b11b){if(_0xe2b11b)return _0xe2b11b?{'count':_0x98ad62,'rows':_0xe2b11b}:null;})[_0x423260('0x92')](respondWithResult(_0x4efd78,null))['catch'](handleError(_0x4efd78,null));},exports[_0x5832ca('0x33')]=function(_0x29f959,_0x560862){const _0xcf5ef0=_0x5832ca;let _0x224e5e={'raw':!![],'where':{}};const _0x45752e={},_0x30069e={'count':0x0,'rows':[]};return db[_0xcf5ef0('0xaa')][_0xcf5ef0('0xfa')]({'where':{'id':_0x29f959[_0xcf5ef0('0x2c')]['id']}})['then'](handleEntityNotFound(_0x560862,null))[_0xcf5ef0('0x92')](function(_0x434187){const _0x3b5591=_0xcf5ef0;if(_0x434187)return _0x45752e[_0x3b5591('0x3f')]=_[_0x3b5591('0x4e')](db[_0x3b5591('0x65')][_0x3b5591('0xea')]),_0x45752e[_0x3b5591('0xd1')]=_[_0x3b5591('0x4e')](_0x29f959[_0x3b5591('0xd1')]),_0x45752e['filters']=_[_0x3b5591('0x13f')](_0x45752e[_0x3b5591('0x3f')],_0x45752e[_0x3b5591('0xd1')]),_0x224e5e['attributes']=_[_0x3b5591('0x13f')](_0x45752e[_0x3b5591('0x3f')],qs[_0x3b5591('0xf')](_0x29f959['query'][_0x3b5591('0xf')])),_0x224e5e['attributes']=_0x224e5e['attributes'][_0x3b5591('0x112')]?_0x224e5e[_0x3b5591('0x11a')]:_0x45752e[_0x3b5591('0x3f')],typeof _0x29f959['query']['nolimit']==='undefined'&&(_0x224e5e['limit']=qs[_0x3b5591('0x11d')](_0x29f959[_0x3b5591('0xd1')][_0x3b5591('0x11d')]),_0x224e5e['offset']=qs['offset'](_0x29f959[_0x3b5591('0xd1')][_0x3b5591('0x89')])),_0x224e5e['order']=qs[_0x3b5591('0x25')](_0x29f959[_0x3b5591('0xd1')][_0x3b5591('0x25')]),_0x224e5e[_0x3b5591('0x13a')]=qs[_0x3b5591('0x36')](_['pick'](_0x29f959[_0x3b5591('0xd1')],_0x45752e[_0x3b5591('0x36')])),_0x224e5e[_0x3b5591('0x13a')][_0x3b5591('0xb6')]=_0x434187['id'],_0x29f959[_0x3b5591('0xd1')][_0x3b5591('0xf8')]&&(_0x224e5e['where']=_[_0x3b5591('0x10d')](_0x224e5e['where'],{[Op['or']]:_[_0x3b5591('0x9c')](_0x224e5e[_0x3b5591('0x11a')],function(_0x4503d7){const _0x432abb=_0x3b5591,_0xe5afd5={};return _0xe5afd5[_0x4503d7]={[Op[_0x432abb('0x75')]]:'%'+_0x29f959[_0x432abb('0xd1')][_0x432abb('0xf8')]+'%'},_0xe5afd5;})})),_0x224e5e=_[_0x3b5591('0x10d')]({},_0x224e5e,_0x29f959[_0x3b5591('0x6d')]),db[_0x3b5591('0x65')][_0x3b5591('0x162')]({'where':_0x224e5e[_0x3b5591('0x13a')]})[_0x3b5591('0x92')](function(_0x519b9c){const _0x46a7d0=_0x3b5591;return _0x30069e['count']=_0x519b9c,_0x29f959[_0x46a7d0('0xd1')][_0x46a7d0('0x102')]&&(_0x224e5e[_0x46a7d0('0x32')]=[{'all':!![]}]),db['MailInteraction']['findAll'](_0x224e5e);})[_0x3b5591('0x92')](function(_0x16cb56){const _0x29ed18=_0x3b5591;return _0x30069e[_0x29ed18('0x60')]=_0x16cb56,_0x30069e;});})[_0xcf5ef0('0x92')](respondWithFilteredResult(_0x560862,_0x224e5e))[_0xcf5ef0('0x5b')](handleError(_0x560862,null));},exports[_0x5832ca('0x6c')]=function(_0x1a87f8,_0xcad287){const _0x169ea2=_0x5832ca;let _0x10b42d={};const _0x591088={};let _0x30eaff,_0x575fdb;return db[_0x169ea2('0xaa')][_0x169ea2('0xfa')]({'where':{'id':_0x1a87f8[_0x169ea2('0x2c')]['id']}})[_0x169ea2('0x92')](handleEntityNotFound(_0xcad287,null))['then'](function(_0x68e26c){const _0x4e0eaa=_0x169ea2;if(_0x68e26c)return _0x30eaff=_0x68e26c,_0x591088[_0x4e0eaa('0x3f')]=_[_0x4e0eaa('0x4e')](db[_0x4e0eaa('0x82')][_0x4e0eaa('0xea')]),_0x591088[_0x4e0eaa('0xd1')]=_[_0x4e0eaa('0x4e')](_0x1a87f8[_0x4e0eaa('0xd1')]),_0x591088[_0x4e0eaa('0x36')]=_['intersection'](_0x591088[_0x4e0eaa('0x3f')],_0x591088['query']),_0x10b42d[_0x4e0eaa('0x11a')]=_[_0x4e0eaa('0x13f')](_0x591088[_0x4e0eaa('0x3f')],qs[_0x4e0eaa('0xf')](_0x1a87f8[_0x4e0eaa('0xd1')][_0x4e0eaa('0xf')])),_0x10b42d[_0x4e0eaa('0x11a')]=_0x10b42d['attributes']['length']?_0x10b42d[_0x4e0eaa('0x11a')]:_0x591088[_0x4e0eaa('0x3f')],_0x10b42d[_0x4e0eaa('0xa3')]=qs[_0x4e0eaa('0x25')](_0x1a87f8[_0x4e0eaa('0xd1')][_0x4e0eaa('0x25')]),_0x10b42d[_0x4e0eaa('0x13a')]=qs[_0x4e0eaa('0x36')](_[_0x4e0eaa('0xa')](_0x1a87f8['query'],_0x591088[_0x4e0eaa('0x36')])),_0x1a87f8[_0x4e0eaa('0xd1')][_0x4e0eaa('0xf8')]&&(_0x10b42d[_0x4e0eaa('0x13a')]=_['merge'](_0x10b42d[_0x4e0eaa('0x13a')],{[Op['or']]:_['map'](_0x10b42d[_0x4e0eaa('0x11a')],function(_0x4eba99){const _0xc60a34=_0x4e0eaa,_0x35a0fb={};return _0x35a0fb[_0x4eba99]={[Op[_0xc60a34('0x75')]]:'%'+_0x1a87f8[_0xc60a34('0xd1')][_0xc60a34('0xf8')]+'%'},_0x35a0fb;})})),_0x10b42d=_[_0x4e0eaa('0x10d')]({},_0x10b42d,_0x1a87f8[_0x4e0eaa('0x6d')]),_0x30eaff[_0x4e0eaa('0x6c')](_0x10b42d);})['then'](function(_0x1cbd26){const _0x3a1d7e=_0x169ea2;if(_0x1cbd26)return _0x575fdb=_0x1cbd26[_0x3a1d7e('0x112')],typeof _0x1a87f8[_0x3a1d7e('0xd1')]['nolimit']==='undefined'&&(_0x10b42d[_0x3a1d7e('0x11d')]=qs[_0x3a1d7e('0x11d')](_0x1a87f8[_0x3a1d7e('0xd1')]['limit']),_0x10b42d[_0x3a1d7e('0x89')]=qs[_0x3a1d7e('0x89')](_0x1a87f8[_0x3a1d7e('0xd1')][_0x3a1d7e('0x89')])),_0x30eaff[_0x3a1d7e('0x6c')](_0x10b42d);})[_0x169ea2('0x92')](function(_0x23f883){if(_0x23f883)return _0x23f883?{'count':_0x575fdb,'rows':_0x23f883}:null;})[_0x169ea2('0x92')](respondWithResult(_0xcad287,null))[_0x169ea2('0x5b')](handleError(_0xcad287,null));},exports[_0x5832ca('0x100')]=function(_0xc8b526,_0x4d5d20){const _0x2dbf47=_0x5832ca;let _0x11ec0b={};const _0x3e2b9d={};let _0x510b36,_0x2f5f71;return db[_0x2dbf47('0xaa')][_0x2dbf47('0xfa')]({'where':{'id':_0xc8b526[_0x2dbf47('0x2c')]['id']}})['then'](handleEntityNotFound(_0x4d5d20,null))[_0x2dbf47('0x92')](function(_0x9c69a9){const _0x4c00fb=_0x2dbf47;if(_0x9c69a9)return _0x510b36=_0x9c69a9,_0x3e2b9d[_0x4c00fb('0x3f')]=_[_0x4c00fb('0x4e')](db[_0x4c00fb('0x96')][_0x4c00fb('0xea')]),_0x3e2b9d[_0x4c00fb('0xd1')]=_['keys'](_0xc8b526[_0x4c00fb('0xd1')]),_0x3e2b9d[_0x4c00fb('0x36')]=_['intersection'](_0x3e2b9d[_0x4c00fb('0x3f')],_0x3e2b9d['query']),_0x11ec0b[_0x4c00fb('0x11a')]=_[_0x4c00fb('0x13f')](_0x3e2b9d[_0x4c00fb('0x3f')],qs['fields'](_0xc8b526[_0x4c00fb('0xd1')][_0x4c00fb('0xf')])),_0x11ec0b[_0x4c00fb('0x11a')]=_0x11ec0b[_0x4c00fb('0x11a')]['length']?_0x11ec0b[_0x4c00fb('0x11a')]:_0x3e2b9d[_0x4c00fb('0x3f')],_0x11ec0b['order']=qs['sort'](_0xc8b526[_0x4c00fb('0xd1')][_0x4c00fb('0x25')]),_0x11ec0b[_0x4c00fb('0x13a')]=qs[_0x4c00fb('0x36')](_[_0x4c00fb('0xa')](_0xc8b526[_0x4c00fb('0xd1')],_0x3e2b9d['filters'])),_0xc8b526[_0x4c00fb('0xd1')][_0x4c00fb('0xf8')]&&(_0x11ec0b[_0x4c00fb('0x13a')]=_[_0x4c00fb('0x10d')](_0x11ec0b[_0x4c00fb('0x13a')],{[Op['or']]:_['map'](_0x11ec0b[_0x4c00fb('0x11a')],function(_0x29bfbf){const _0x219931=_0x4c00fb,_0x4d117c={};return _0x4d117c[_0x29bfbf]={[Op[_0x219931('0x75')]]:'%'+_0xc8b526[_0x219931('0xd1')]['filter']+'%'},_0x4d117c;})})),_0x11ec0b=_[_0x4c00fb('0x10d')]({},_0x11ec0b,_0xc8b526[_0x4c00fb('0x6d')]),_0x510b36[_0x4c00fb('0x100')](_0x11ec0b);})[_0x2dbf47('0x92')](function(_0xb8dc96){const _0xb39289=_0x2dbf47;if(_0xb8dc96)return _0x2f5f71=_0xb8dc96[_0xb39289('0x112')],typeof _0xc8b526[_0xb39289('0xd1')]['nolimit']===_0xb39289('0x7d')&&(_0x11ec0b[_0xb39289('0x11d')]=qs[_0xb39289('0x11d')](_0xc8b526[_0xb39289('0xd1')]['limit']),_0x11ec0b[_0xb39289('0x89')]=qs[_0xb39289('0x89')](_0xc8b526[_0xb39289('0xd1')]['offset'])),_0x510b36['getFaxInteractions'](_0x11ec0b);})[_0x2dbf47('0x92')](function(_0x3fdb0f){if(_0x3fdb0f)return _0x3fdb0f?{'count':_0x2f5f71,'rows':_0x3fdb0f}:null;})[_0x2dbf47('0x92')](respondWithResult(_0x4d5d20,null))[_0x2dbf47('0x5b')](handleError(_0x4d5d20,null));},exports[_0x5832ca('0xde')]=function(_0x474155,_0x4bd420){const _0x54efe2=_0x5832ca;let _0x27e74f={};const _0x3b995f={};let _0x5c4dc3,_0x726aeb;return db['User']['findOne']({'where':{'id':_0x474155[_0x54efe2('0x2c')]['id']}})['then'](handleEntityNotFound(_0x4bd420,null))[_0x54efe2('0x92')](function(_0x3a6df9){const _0x4c1803=_0x54efe2;if(_0x3a6df9)return _0x5c4dc3=_0x3a6df9,_0x3b995f[_0x4c1803('0x3f')]=_['keys'](db['WhatsappInteraction'][_0x4c1803('0xea')]),_0x3b995f[_0x4c1803('0xd1')]=_[_0x4c1803('0x4e')](_0x474155['query']),_0x3b995f[_0x4c1803('0x36')]=_[_0x4c1803('0x13f')](_0x3b995f['model'],_0x3b995f[_0x4c1803('0xd1')]),_0x27e74f[_0x4c1803('0x11a')]=_[_0x4c1803('0x13f')](_0x3b995f['model'],qs[_0x4c1803('0xf')](_0x474155[_0x4c1803('0xd1')]['fields'])),_0x27e74f['attributes']=_0x27e74f[_0x4c1803('0x11a')][_0x4c1803('0x112')]?_0x27e74f[_0x4c1803('0x11a')]:_0x3b995f['model'],_0x27e74f[_0x4c1803('0xa3')]=qs['sort'](_0x474155['query'][_0x4c1803('0x25')]),_0x27e74f[_0x4c1803('0x13a')]=qs[_0x4c1803('0x36')](_['pick'](_0x474155[_0x4c1803('0xd1')],_0x3b995f['filters'])),_0x474155[_0x4c1803('0xd1')]['filter']&&(_0x27e74f[_0x4c1803('0x13a')]=_[_0x4c1803('0x10d')](_0x27e74f[_0x4c1803('0x13a')],{[Op['or']]:_[_0x4c1803('0x9c')](_0x27e74f[_0x4c1803('0x11a')],function(_0x38ec39){const _0x4f4014=_0x4c1803,_0x340c0a={};return _0x340c0a[_0x38ec39]={[Op[_0x4f4014('0x75')]]:'%'+_0x474155['query'][_0x4f4014('0xf8')]+'%'},_0x340c0a;})})),_0x27e74f=_[_0x4c1803('0x10d')]({},_0x27e74f,_0x474155[_0x4c1803('0x6d')]),_0x5c4dc3[_0x4c1803('0xde')](_0x27e74f);})['then'](function(_0x22cfca){const _0x3c2f30=_0x54efe2;if(_0x22cfca)return _0x726aeb=_0x22cfca['length'],typeof _0x474155[_0x3c2f30('0xd1')]['nolimit']===_0x3c2f30('0x7d')&&(_0x27e74f[_0x3c2f30('0x11d')]=qs['limit'](_0x474155[_0x3c2f30('0xd1')][_0x3c2f30('0x11d')]),_0x27e74f['offset']=qs[_0x3c2f30('0x89')](_0x474155['query']['offset'])),_0x5c4dc3[_0x3c2f30('0xde')](_0x27e74f);})[_0x54efe2('0x92')](function(_0x2e94d5){if(_0x2e94d5)return _0x2e94d5?{'count':_0x726aeb,'rows':_0x2e94d5}:null;})[_0x54efe2('0x92')](respondWithResult(_0x4bd420,null))[_0x54efe2('0x5b')](handleError(_0x4bd420,null));},exports[_0x5832ca('0x1c')]=function(_0xbdf94c,_0x1aaa5c,_0x4b27ad){const _0x2e0c2f=_0x5832ca;let _0x502c88,_0x30d6ac,_0x4c34ac;const _0x1807eb=!_[_0x2e0c2f('0xc5')](_0xbdf94c[_0x2e0c2f('0x2c')]['id'])?_0xbdf94c[_0x2e0c2f('0x2c')]['id']:!_['isNil'](_0xbdf94c[_0x2e0c2f('0x1d')]['id'])?_0xbdf94c[_0x2e0c2f('0x1d')]['id']:null;return db[_0x2e0c2f('0xaa')][_0x2e0c2f('0xfa')]({'where':{'id':_0x1807eb,'role':{[Op['or']]:['admin','user',_0x2e0c2f('0x155')]}},'attributes':['id',_0x2e0c2f('0xca'),_0x2e0c2f('0xba'),_0x2e0c2f('0x5d'),'role',_0x2e0c2f('0x4c'),_0x2e0c2f('0x7e')]})[_0x2e0c2f('0x92')](function(_0x50bbb0){const _0x3b747c=_0x2e0c2f;if(_0x50bbb0){if(_0x50bbb0[_0x3b747c('0xd5')]===_0x3b747c('0x155')){_0x502c88=_0x50bbb0;if(_0xbdf94c[_0x3b747c('0x4d')][_0x3b747c('0x1')])_0x4c34ac=util[_0x3b747c('0x8e')](_0x3b747c('0x3'),_0x502c88[_0xbdf94c[_0x3b747c('0x4d')][_0x3b747c('0x1')]]);else _0xbdf94c[_0x3b747c('0x4d')][_0x3b747c('0xd6')]?_0x4c34ac=util[_0x3b747c('0x8e')](_0x3b747c('0x14b'),_0xbdf94c['body'][_0x3b747c('0xd6')]):_0x4c34ac=util[_0x3b747c('0x8e')](_0x3b747c('0x14b'),_0x502c88['name']);return socket['to'](util['format'](_0x3b747c('0x104'),_0x502c88['name']))[_0x3b747c('0xee')](_0x3b747c('0x151'),{'ip':_0xbdf94c[_0x3b747c('0x101')][_0x3b747c('0x28')]||_0xbdf94c[_0x3b747c('0xd4')]['remoteAddress']||_0xbdf94c[_0x3b747c('0xdb')][_0x3b747c('0x39')]||_0xbdf94c[_0x3b747c('0xd4')][_0x3b747c('0xdb')][_0x3b747c('0x39')]}),db[_0x3b747c('0x91')][_0x3b747c('0x12c')]({'where':{'membername':_0x502c88[_0x3b747c('0xca')]},'individualHooks':!![]});}}else throw new ValidationError('User\x20not\x20found\x20or\x20not\x20allowed\x20to\x20perform\x20login\x20method');})[_0x2e0c2f('0x92')](function(){const _0x54b19d=_0x2e0c2f;if(_0x502c88)return _0x502c88[_0x54b19d('0x15e')]({'raw':!![]});})[_0x2e0c2f('0x92')](function(_0x3c7fb0){const _0x10be61=_0x2e0c2f;if(_0x502c88){if(_0x3c7fb0){_0x30d6ac=_0x3c7fb0;if(_0x30d6ac[_0x10be61('0x112')]){const _0x36f263=_0x30d6ac[_0x10be61('0x9c')](_0x171319=>{const _0x2f7ceb=_0x10be61,_0x2d129d={'membername':_0x502c88[_0x2f7ceb('0xca')],'UserId':_0x502c88['id'],'queue_name':_0x171319['name'],'VoiceQueueId':_0x171319['id'],'interface':_0x4c34ac,'paused':_0x502c88[_0x2f7ceb('0x7e')]||![],'penalty':_0x171319[_0x2f7ceb('0x81')]||0x0};return db[_0x2f7ceb('0x91')][_0x2f7ceb('0xb7')](_0x2d129d);});return Promise[_0x10be61('0x43')](_0x36f263);}}}})[_0x2e0c2f('0x92')](function(){const _0x2cd56b=_0x2e0c2f;if(_0x502c88)return db[_0x2cd56b('0xff')]['findAll']({'where':{'membername':_0x502c88[_0x2cd56b('0xca')],'exitAt':null}});})[_0x2e0c2f('0x92')](function(_0x59fc5e){const _0x24ad4c=_0x2e0c2f;if(_0x502c88){const _0x845f49=[];return _0x59fc5e[_0x24ad4c('0xa6')](function(_0x500b57){const _0x4f08b2=_0x24ad4c;_0x845f49[_0x4f08b2('0x10e')](_0x500b57[_0x4f08b2('0x30')]({'exitAt':moment()[_0x4f08b2('0x8e')]('YYYY-MM-DD\x20HH:mm:ss')}));}),Promise[_0x24ad4c('0x43')](_0x845f49);}})['then'](function(){const _0x44f357=_0x2e0c2f;if(_0x502c88){const _0x1deac7=[],_0x5b1422=[],_0x4d14e8=utils[_0x44f357('0x10c')](),_0x2c7aec={'membername':_0x502c88[_0x44f357('0xca')],'interface':_0x4c34ac,'enterAt':moment()[_0x44f357('0x8e')](_0x44f357('0x55')),'role':_0x502c88['role'],'internal':_0x502c88['internal']};return _0x4d14e8[_0x44f357('0xa6')](function(_0x3ff96c){const _0x5d08a8=_0x44f357;_0x1deac7[_0x5d08a8('0x10e')](_[_0x5d08a8('0x10d')]({'channel':_0x3ff96c,'type':_0x5d08a8('0xe8'),'data1':_0xbdf94c[_0x5d08a8('0x4d')][_0x5d08a8('0xb9')],'data2':_0x4c34ac},_0x2c7aec)),_0x502c88[_0x5d08a8('0x7e')]&&_0x5b1422[_0x5d08a8('0x10e')](_[_0x5d08a8('0x10d')]({'channel':_0x3ff96c,'type':_0x5d08a8('0x125'),'data1':_0x5d08a8('0x44')},_0x2c7aec));}),db[_0x44f357('0xff')][_0x44f357('0x12')](_0x1deac7[_0x44f357('0x78')](_0x5b1422),{'individualHooks':!![]});}})[_0x2e0c2f('0x92')](function(){const _0x3ef125=_0x2e0c2f;if(_0x502c88)return _0x502c88[_0x3ef125('0x30')]({'online':!![],'lastLoginAt':moment()[_0x3ef125('0x8e')](_0x3ef125('0x55')),'voicePause':_0x502c88[_0x3ef125('0x7e')]||![],'mailPause':_0x502c88[_0x3ef125('0x7e')]||![],'chatPause':_0x502c88['loginInPause']||![],'faxPause':_0x502c88['loginInPause']||![],'smsPause':_0x502c88[_0x3ef125('0x7e')]||![],'openchannelPause':_0x502c88[_0x3ef125('0x7e')]||![],'whatsappPause':_0x502c88['loginInPause']||![],'pauseType':_0x502c88[_0x3ef125('0x7e')]?_0x3ef125('0x44'):null,'interface':_0x4c34ac,'lastPauseAt':moment()[_0x3ef125('0x8e')]('YYYY-MM-DD\x20HH:mm:ss')});})[_0x2e0c2f('0x92')](function(_0x28d935){const _0x1107fc=_0x2e0c2f;return _0xbdf94c[_0x1107fc('0x57')]?_0x4b27ad():Promise[_0x1107fc('0xa1')](_0x28d935)[_0x1107fc('0x92')](respondWithResult(_0x1aaa5c,null));})[_0x2e0c2f('0x5b')](handleError(_0x1aaa5c,null));},exports[_0x5832ca('0x40')]=function(_0x5ce2b4,_0x39e0c6){const _0x48d71b=_0x5832ca;let _0x48dcbf;return db[_0x48d71b('0xaa')][_0x48d71b('0xfa')]({'where':{'id':_0x5ce2b4['params']['id'],'role':'agent'},'attributes':['id',_0x48d71b('0xca'),_0x48d71b('0xd5')]})[_0x48d71b('0x92')](handleEntityNotFound(_0x39e0c6,null))['then'](function(_0x326c11){const _0x1f197f=_0x48d71b;if(_0x326c11)return _0x48dcbf=_0x326c11,db[_0x1f197f('0x91')][_0x1f197f('0x12c')]({'where':{'membername':_0x48dcbf['name']},'individualHooks':!![]});})[_0x48d71b('0x92')](function(){const _0x590f1c=_0x48d71b;return db[_0x590f1c('0xff')][_0x590f1c('0x64')]({'where':{'membername':_0x48dcbf[_0x590f1c('0xca')],'exitAt':null}});})[_0x48d71b('0x92')](function(_0x2bac0f){const _0x4ddb0b=_0x48d71b,_0xc0ece4=[];return _0x2bac0f['forEach'](function(_0xe87f4f){const _0xae6bb5=a648_0x4b4f;_0xc0ece4['push'](_0xe87f4f[_0xae6bb5('0x30')]({'exitAt':moment()[_0xae6bb5('0x8e')](_0xae6bb5('0x55'))}));}),Promise[_0x4ddb0b('0x43')](_0xc0ece4);})[_0x48d71b('0x92')](function(){const _0x5c0586=_0x48d71b;return _0x48dcbf[_0x5c0586('0x30')]({'online':![],'lastLoginAt':null,'voicePause':![],'mailPause':![],'chatPause':![],'faxPause':![],'smsPause':![],'openchannelPause':![],'whatsappPause':![],'interface':null});})[_0x48d71b('0x92')](respondWithResult(_0x39e0c6,null))[_0x48d71b('0x5b')](handleError(_0x39e0c6,null));},exports[_0x5832ca('0x29')]=function(_0x1dbfe9,_0x1758cd){const _0x4bacd4=_0x5832ca;let _0x1d0f03;return db[_0x4bacd4('0x91')]['update']({'paused':0x1},{'where':{'UserId':_0x1dbfe9[_0x4bacd4('0x2c')]['id']},'individualHooks':!![]})[_0x4bacd4('0x92')](function(){const _0x368736=_0x4bacd4;return db['User'][_0x368736('0xfa')]({'where':{'id':_0x1dbfe9['params']['id'],'role':_0x368736('0x155')},'attributes':['id',_0x368736('0xca'),_0x368736('0xd5'),_0x368736('0x4c'),_0x368736('0x1')]});})['then'](handleEntityNotFound(_0x1758cd,null))[_0x4bacd4('0x92')](function(_0xc8953a){const _0x402afd=_0x4bacd4;if(_0xc8953a)return _0x1d0f03=_0xc8953a,respondWithRpcPromise(_0x402afd('0x46'),_0x402afd('0x29'),{'id':_0x1d0f03['id'],'name':_0x1d0f03['name'],'pause':!![]});})[_0x4bacd4('0x92')](function(){const _0xe03320=_0x4bacd4;if(_0x1d0f03)return db[_0xe03320('0xff')][_0xe03320('0x64')]({'where':{'membername':_0x1d0f03[_0xe03320('0xca')],'type':_0xe03320('0x125'),'exitAt':null}});})[_0x4bacd4('0x92')](function(_0x5a4ca7){const _0x37ef80=_0x4bacd4;if(_0x5a4ca7[_0x37ef80('0x112')]){const _0x124b03=moment()['format'](_0x37ef80('0x55'));for(let _0x139a12=0x0,_0x2bfd1a=_0x5a4ca7[_0x37ef80('0x112')];_0x139a12<_0x2bfd1a;_0x139a12++){_0x5a4ca7[_0x139a12][_0x37ef80('0x30')]({'exitAt':_0x124b03});}}})['then'](function(){const _0x57083b=_0x4bacd4,_0x4cb24c=[],_0x2da139=utils[_0x57083b('0x10c')]();return _0x2da139['forEach'](function(_0x275285){const _0x43fe84=_0x57083b;_0x4cb24c[_0x43fe84('0x10e')]({'channel':_0x275285,'membername':_0x1d0f03[_0x43fe84('0xca')],'interface':_[_0x43fe84('0xc5')](_0x1d0f03['interface'])?util['format'](_0x43fe84('0x14b'),_0x1d0f03[_0x43fe84('0xca')]):_0x1d0f03['interface'],'type':_0x43fe84('0x125'),'enterAt':moment()['format'](_0x43fe84('0x55')),'data1':_0x1dbfe9[_0x43fe84('0x4d')][_0x43fe84('0x15c')]||_0x43fe84('0x152'),'role':_0x1d0f03[_0x43fe84('0xd5')],'internal':_0x1d0f03[_0x43fe84('0x4c')]});}),db[_0x57083b('0xff')]['bulkCreate'](_0x4cb24c,{'individualHooks':!![]});})['then'](function(){const _0xf4dc31=_0x4bacd4;return _0x1d0f03[_0xf4dc31('0x30')]({'voicePause':!![],'mailPause':!![],'chatPause':!![],'faxPause':!![],'smsPause':!![],'whatsappPause':!![],'openchannelPause':!![],'pauseType':_0x1dbfe9[_0xf4dc31('0x4d')]['type']||'DEFAULT\x20PAUSE','lastPauseAt':moment()['format'](_0xf4dc31('0x55'))});})[_0x4bacd4('0x92')](respondWithResult(_0x1758cd,null))[_0x4bacd4('0x5b')](handleError(_0x1758cd,null));},exports[_0x5832ca('0xdf')]=function(_0x57821e,_0x5b9488){const _0x54b0d1=_0x5832ca;let _0x17c7cc;return db['User'][_0x54b0d1('0xfa')]({'where':{'id':_0x57821e[_0x54b0d1('0x2c')]['id']},'attributes':['id',_0x54b0d1('0xca'),'role',_0x54b0d1('0xf4'),_0x54b0d1('0x159'),_0x54b0d1('0xbb'),_0x54b0d1('0x17'),_0x54b0d1('0x5'),_0x54b0d1('0x3a'),_0x54b0d1('0xd3'),_0x54b0d1('0x3b'),_0x54b0d1('0xe5')]})['then'](handleEntityNotFound(_0x5b9488,null))[_0x54b0d1('0x92')](function(_0x239878){const _0x58209e=_0x54b0d1;if(_0x239878){_0x17c7cc=_0x239878;if(_0x57821e[_0x58209e('0x4d')][_0x58209e('0xc4')]&&!utils['isValidChannel'](_0x57821e[_0x58209e('0x4d')][_0x58209e('0xc4')]))throw new ValidationError(_0x58209e('0x95'));switch(_0x57821e[_0x58209e('0x4d')][_0x58209e('0xc4')]){case _0x58209e('0x137'):return respondWithRpcPromise('QueuePause',_0x58209e('0xdf'),{'id':_0x17c7cc['id'],'name':_0x17c7cc[_0x58209e('0xca')],'pause':![]})['then'](function(){const _0x443b67=_0x58209e;return db[_0x443b67('0x91')][_0x443b67('0x30')]({'paused':0x0},{'where':{'UserId':_0x17c7cc['id']},'individualHooks':!![]});})[_0x58209e('0x92')](function(){const _0x4d29e2=_0x58209e;return db['MemberReport'][_0x4d29e2('0xfa')]({'where':{'channel':_0x57821e[_0x4d29e2('0x4d')][_0x4d29e2('0xc4')],'membername':_0x17c7cc[_0x4d29e2('0xca')],'type':_0x4d29e2('0x125'),'exitAt':null}});})['then'](function(_0x35d617){const _0x55c63b=_0x58209e;if(_0x35d617)return _0x35d617[_0x55c63b('0x30')]({'exitAt':moment()[_0x55c63b('0x8e')]('YYYY-MM-DD\x20HH:mm:ss'),'data2':'manual'},{'individualHooks':!![]});return null;})[_0x58209e('0x92')](function(){const _0x559ff7=_0x58209e;return _0x17c7cc[_0x559ff7('0x30')]({'voicePause':![]});});case _0x58209e('0xb0'):case'chat':case _0x58209e('0xe9'):case _0x58209e('0x85'):case _0x58209e('0x4'):case _0x58209e('0x86'):return db[_0x58209e('0xff')]['findOne']({'where':{'channel':_0x57821e['body'][_0x58209e('0xc4')],'membername':_0x17c7cc[_0x58209e('0xca')],'type':_0x58209e('0x125'),'exitAt':null}})[_0x58209e('0x92')](function(_0x15a23e){const _0x304927=_0x58209e;if(_0x15a23e)return _0x15a23e[_0x304927('0x30')]({'exitAt':moment()[_0x304927('0x8e')](_0x304927('0x55')),'data2':_0x304927('0x66')},{'individualHooks':!![]});return null;})[_0x58209e('0x92')](function(){const _0x2e2561=_0x58209e,_0x33410c={};return _['set'](_0x33410c,util[_0x2e2561('0x8e')](_0x2e2561('0xed'),_0x57821e['body'][_0x2e2561('0xc4')],'Pause'),![]),_0x17c7cc[_0x2e2561('0x30')](_0x33410c);});default:return respondWithRpcPromise(_0x58209e('0x46'),'unpause',{'id':_0x17c7cc['id'],'name':_0x17c7cc['name'],'pause':![]})['then'](function(){const _0x5e984f=_0x58209e;return db[_0x5e984f('0x91')]['update']({'paused':0x0},{'where':{'UserId':_0x17c7cc['id']}});})[_0x58209e('0x92')](function(){const _0x35082b=_0x58209e;return db[_0x35082b('0xff')]['findAll']({'where':{'membername':_0x17c7cc['name'],'type':'PAUSE','exitAt':null}});})[_0x58209e('0x92')](function(_0x2c91fd){const _0x11f05e=_0x58209e,_0x29c187=[];return _0x2c91fd['forEach'](function(_0xae7327){const _0x57125a=a648_0x4b4f;_0x29c187[_0x57125a('0x10e')](_0xae7327[_0x57125a('0x30')]({'exitAt':moment()[_0x57125a('0x8e')]('YYYY-MM-DD\x20HH:mm:ss'),'data2':_0x57125a('0x66')}));}),Promise[_0x11f05e('0x43')](_0x29c187);})[_0x58209e('0x92')](function(){const _0x3f3a25=_0x58209e;return _0x17c7cc[_0x3f3a25('0x30')]({'voicePause':![],'mailPause':![],'chatPause':![],'faxPause':![],'smsPause':![],'whatsappPause':![],'openchannelPause':![]});});}}})[_0x54b0d1('0x92')](respondWithResult(_0x5b9488,null))['catch'](handleError(_0x5b9488,null));},exports[_0x5832ca('0x111')]=function(_0x5cd6d8,_0x133b1f){const _0x595a02=_0x5832ca;let _0x491a6f={};const _0x57e24d={};let _0x37d90c,_0x4e2071;return db['User'][_0x595a02('0xfa')]({'where':{'id':_0x5cd6d8[_0x595a02('0x2c')]['id']}})[_0x595a02('0x92')](handleEntityNotFound(_0x133b1f,null))[_0x595a02('0x92')](function(_0xb2c126){const _0x8c7fb9=_0x595a02;if(_0xb2c126)return _0x37d90c=_0xb2c126,_0x57e24d[_0x8c7fb9('0x3f')]=_[_0x8c7fb9('0x4e')](db[_0x8c7fb9('0xfb')][_0x8c7fb9('0xea')]),_0x57e24d[_0x8c7fb9('0xd1')]=_[_0x8c7fb9('0x4e')](_0x5cd6d8['query']),_0x57e24d[_0x8c7fb9('0x36')]=_[_0x8c7fb9('0x13f')](_0x57e24d['model'],_0x57e24d[_0x8c7fb9('0xd1')]),_0x491a6f[_0x8c7fb9('0x11a')]=_[_0x8c7fb9('0x13f')](_0x57e24d[_0x8c7fb9('0x3f')],qs[_0x8c7fb9('0xf')](_0x5cd6d8[_0x8c7fb9('0xd1')]['fields'])),_0x491a6f[_0x8c7fb9('0x11a')]=_0x491a6f['attributes'][_0x8c7fb9('0x112')]?_0x491a6f[_0x8c7fb9('0x11a')]:_0x57e24d[_0x8c7fb9('0x3f')],_0x491a6f['order']=qs[_0x8c7fb9('0x25')](_0x5cd6d8[_0x8c7fb9('0xd1')][_0x8c7fb9('0x25')]),_0x491a6f[_0x8c7fb9('0x13a')]=qs[_0x8c7fb9('0x36')](_[_0x8c7fb9('0xa')](_0x5cd6d8[_0x8c7fb9('0xd1')],_0x57e24d[_0x8c7fb9('0x36')])),_0x5cd6d8[_0x8c7fb9('0xd1')][_0x8c7fb9('0xf8')]&&(_0x491a6f[_0x8c7fb9('0x13a')]=_['merge'](_0x491a6f[_0x8c7fb9('0x13a')],{[Op['or']]:_[_0x8c7fb9('0x9c')](_0x491a6f['attributes'],function(_0x3bcb12){const _0x522823=_0x8c7fb9,_0x4af47c={};return _0x4af47c[_0x3bcb12]={[Op[_0x522823('0x75')]]:'%'+_0x5cd6d8['query'][_0x522823('0xf8')]+'%'},_0x4af47c;})})),_0x491a6f=_[_0x8c7fb9('0x10d')]({},_0x491a6f,_0x5cd6d8['options']),_0x37d90c[_0x8c7fb9('0x111')](_0x491a6f);})[_0x595a02('0x92')](function(_0x49955b){const _0x128eb8=_0x595a02;if(_0x49955b)return _0x4e2071=_0x49955b[_0x128eb8('0x112')],typeof _0x5cd6d8[_0x128eb8('0xd1')]['nolimit']==='undefined'&&(_0x491a6f[_0x128eb8('0x11d')]=qs['limit'](_0x5cd6d8[_0x128eb8('0xd1')][_0x128eb8('0x11d')]),_0x491a6f[_0x128eb8('0x89')]=qs[_0x128eb8('0x89')](_0x5cd6d8[_0x128eb8('0xd1')][_0x128eb8('0x89')])),_0x37d90c[_0x128eb8('0x111')](_0x491a6f);})['then'](function(_0x585bfc){if(_0x585bfc)return _0x585bfc?{'count':_0x4e2071,'rows':_0x585bfc}:null;})[_0x595a02('0x92')](respondWithResult(_0x133b1f,null))['catch'](handleError(_0x133b1f,null));},exports[_0x5832ca('0x129')]=function(_0x3ccb48,_0x25d0fd){const _0xe9fa92=_0x5832ca;return db[_0xe9fa92('0xaa')]['findOne']({'where':{'id':_0x3ccb48[_0xe9fa92('0x2c')]['id']}})['then'](handleEntityNotFound(_0x25d0fd,null))[_0xe9fa92('0x92')](function(_0x4b455d){const _0x47d308=_0xe9fa92;if(_0x4b455d){const _0x1c67b5=_0x4b455d['get']({'plain':!![]});return _0x4b455d[_0x47d308('0x129')](_0x3ccb48[_0x47d308('0x4d')][_0x47d308('0xf5')],_[_0x47d308('0x34')](_0x3ccb48['body'],[_0x47d308('0xf5'),'id'])||{})[_0x47d308('0x92')](function(){const _0x5edc8a=_0x47d308;for(let _0x525a06=0x0;_0x525a06<_0x3ccb48[_0x5edc8a('0x4d')][_0x5edc8a('0xf5')]['length'];_0x525a06++){let _0x35c47c=[];db['Team'][_0x5edc8a('0xfa')]({'where':{'id':_0x3ccb48[_0x5edc8a('0x4d')][_0x5edc8a('0xf5')][_0x525a06]}})[_0x5edc8a('0x92')](function(_0x310721){const _0x23cb5e=_0x5edc8a;return _0x35c47c[_0x23cb5e('0x10e')](_0x310721[_0x23cb5e('0x15e')]()[_0x23cb5e('0x92')](function(_0x4cb7b9){const _0x3ad085=_0x23cb5e;for(let _0x38b981=0x0;_0x38b981<_0x4cb7b9[_0x3ad085('0x112')];_0x38b981++){_0x4cb7b9[_0x38b981][_0x3ad085('0x31')](_0x3ad085('0xc4'),_0x3ad085('0x158'));}return _0x4cb7b9;})),_0x35c47c['push'](_0x310721[_0x23cb5e('0x138')]()[_0x23cb5e('0x92')](function(_0x1ddd9c){const _0x115d3c=_0x23cb5e;for(let _0x19bfa2=0x0;_0x19bfa2<_0x1ddd9c[_0x115d3c('0x112')];_0x19bfa2++){_0x1ddd9c[_0x19bfa2][_0x115d3c('0x31')](_0x115d3c('0xc4'),_0x115d3c('0x23'));}return _0x1ddd9c;})),_0x35c47c[_0x23cb5e('0x10e')](_0x310721[_0x23cb5e('0xf7')]()[_0x23cb5e('0x92')](function(_0x5e7e46){const _0x5741e0=_0x23cb5e;for(let _0x25bac0=0x0;_0x25bac0<_0x5e7e46[_0x5741e0('0x112')];_0x25bac0++){_0x5e7e46[_0x25bac0]['setDataValue'](_0x5741e0('0xc4'),_0x5741e0('0x2d'));}return _0x5e7e46;})),_0x35c47c[_0x23cb5e('0x10e')](_0x310721['getSmsQueues']()[_0x23cb5e('0x92')](function(_0x41fad4){const _0x565d5d=_0x23cb5e;for(let _0x3b3cfa=0x0;_0x3b3cfa<_0x41fad4[_0x565d5d('0x112')];_0x3b3cfa++){_0x41fad4[_0x3b3cfa]['setDataValue'](_0x565d5d('0xc4'),_0x565d5d('0xd'));}return _0x41fad4;})),_0x35c47c[_0x23cb5e('0x10e')](_0x310721[_0x23cb5e('0xa8')]()[_0x23cb5e('0x92')](function(_0x25a912){const _0x123b89=_0x23cb5e;for(let _0xf19b6=0x0;_0xf19b6<_0x25a912[_0x123b89('0x112')];_0xf19b6++){_0x25a912[_0xf19b6][_0x123b89('0x31')](_0x123b89('0xc4'),_0x123b89('0xe4'));}return _0x25a912;})),_0x35c47c[_0x23cb5e('0x10e')](_0x310721[_0x23cb5e('0xb2')]()['then'](function(_0x26e175){const _0xf59375=_0x23cb5e;for(let _0x16fb89=0x0;_0x16fb89<_0x26e175[_0xf59375('0x112')];_0x16fb89++){_0x26e175[_0x16fb89][_0xf59375('0x31')](_0xf59375('0xc4'),_0xf59375('0xb3'));}return _0x26e175;})),_0x35c47c['push'](_0x310721[_0x23cb5e('0x27')]()[_0x23cb5e('0x92')](function(_0x1b0599){const _0x380c5e=_0x23cb5e;for(let _0x2c622a=0x0;_0x2c622a<_0x1b0599[_0x380c5e('0x112')];_0x2c622a++){_0x1b0599[_0x2c622a]['setDataValue'](_0x380c5e('0xc4'),'Openchannel');}return _0x1b0599;})),Promise[_0x23cb5e('0x43')](_0x35c47c);})[_0x5edc8a('0x92')](function(_0x42f1b5){const _0x3aba93=_0x5edc8a,_0x4b6e31=_[_0x3aba93('0x12b')](_0x42f1b5);return _0x35c47c=[],db[_0x3aba93('0xcc')][_0x3aba93('0x24')](function(_0x47e3e4){const _0xe8aab=_0x3aba93;for(let _0x36961e=0x0;_0x36961e<_0x4b6e31['length'];_0x36961e++){_0x35c47c[_0xe8aab('0x10e')](_0x4b6e31[_0x36961e][_0xe8aab('0x20')](_0x1c67b5['id']),{'transaction':_0x47e3e4});}return Promise[_0xe8aab('0x43')](_0x35c47c)[_0xe8aab('0x92')](function(){const _0x3425f9=_0xe8aab;if(_0x1c67b5[_0x3425f9('0x10a')])return Promise[_0x3425f9('0x18')](_[_0x3425f9('0xf8')](_0x4b6e31,function(_0x14d7a4){const _0x26e154=_0x3425f9;return _0x14d7a4[_0x26e154('0x118')](_0x26e154('0xc4'))===_0x26e154('0x158');}),function(_0x3ad6e3){const _0x497408=_0x3425f9;return db['UserVoiceQueueRt'][_0x497408('0xb7')]({'membername':_0x1c67b5[_0x497408('0xca')],'UserId':_0x1c67b5['id'],'queue_name':_0x3ad6e3[_0x497408('0xca')],'VoiceQueueId':_0x3ad6e3['id'],'interface':_[_0x497408('0xc5')](_0x1c67b5[_0x497408('0x1')])?util['format'](_0x497408('0x14b'),_0x1c67b5[_0x497408('0xca')]):_0x1c67b5[_0x497408('0x1')],'paused':_0x1c67b5[_0x497408('0xf4')]||![],'penalty':_0x1c67b5[_0x497408('0x120')]},{'transaction':_0x47e3e4});});else return;})['then'](function(){const _0x4d2892=_0xe8aab;for(let _0x3a84c5=0x0;_0x3a84c5<_0x4b6e31[_0x4d2892('0x112')];_0x3a84c5++){const _0x5532df=_0x4b6e31[_0x3a84c5][_0x4d2892('0x118')](_0x4d2892('0xc4')),_0x469764=_0x5532df+_0x4d2892('0x5f');socket[_0x4d2892('0xee')]('user'+_0x5532df+_0x4d2892('0x7f'),{'UserId':_0x1c67b5['id'],[_0x469764]:_0x4b6e31[_0x3a84c5]['id']});}});});});}});}})[_0xe9fa92('0x92')](respondWithStatusCode(_0x25d0fd,null))[_0xe9fa92('0x5b')](handleError(_0x25d0fd,null));},exports[_0x5832ca('0x15d')]=function(_0x205bb4,_0x81f49e){const _0x191e6b=_0x5832ca;return db['User'][_0x191e6b('0xfa')]({'where':{'id':_0x205bb4[_0x191e6b('0x2c')]['id']}})[_0x191e6b('0x92')](handleEntityNotFound(_0x81f49e,null))[_0x191e6b('0x92')](function(_0x3dc87f){const _0x20d72d=_0x191e6b;if(_0x3dc87f){const _0xd42442=_0x3dc87f[_0x20d72d('0xc9')]({'plain':!![]}),_0x55532a=_0x205bb4['query'][_0x20d72d('0xf5')];return _0x3dc87f[_0x20d72d('0x15d')](_0x55532a)[_0x20d72d('0x92')](function(){const _0x14fa6a=_0x20d72d;for(let _0x2d75fd=0x0;_0x2d75fd<_0x55532a['length'];_0x2d75fd++){let _0xc8cbdb=[];db[_0x14fa6a('0xfb')]['findOne']({'where':{'id':_0x55532a[_0x2d75fd]}})[_0x14fa6a('0x92')](function(_0x377575){const _0x1837a7=_0x14fa6a;return _0xc8cbdb[_0x1837a7('0x10e')](_0x377575[_0x1837a7('0x15e')]()[_0x1837a7('0x92')](function(_0x29952c){const _0x4eaa22=_0x1837a7;for(let _0x2eaee3=0x0;_0x2eaee3<_0x29952c[_0x4eaa22('0x112')];_0x2eaee3++){_0x29952c[_0x2eaee3][_0x4eaa22('0x31')](_0x4eaa22('0xc4'),_0x4eaa22('0x158'));}return _0x29952c;})),_0xc8cbdb[_0x1837a7('0x10e')](_0x377575[_0x1837a7('0x138')]()[_0x1837a7('0x92')](function(_0x368bc3){const _0x4fbf9a=_0x1837a7;for(let _0xe0b8d=0x0;_0xe0b8d<_0x368bc3[_0x4fbf9a('0x112')];_0xe0b8d++){_0x368bc3[_0xe0b8d][_0x4fbf9a('0x31')]('channel',_0x4fbf9a('0x23'));}return _0x368bc3;})),_0xc8cbdb['push'](_0x377575[_0x1837a7('0xf7')]()['then'](function(_0x32fe48){const _0x5411ab=_0x1837a7;for(let _0x5c6631=0x0;_0x5c6631<_0x32fe48['length'];_0x5c6631++){_0x32fe48[_0x5c6631][_0x5411ab('0x31')](_0x5411ab('0xc4'),'Mail');}return _0x32fe48;})),_0xc8cbdb[_0x1837a7('0x10e')](_0x377575['getSmsQueues']()[_0x1837a7('0x92')](function(_0x12da67){const _0x2aa0a7=_0x1837a7;for(let _0x12a43c=0x0;_0x12a43c<_0x12da67['length'];_0x12a43c++){_0x12da67[_0x12a43c]['setDataValue'](_0x2aa0a7('0xc4'),'Sms');}return _0x12da67;})),_0xc8cbdb[_0x1837a7('0x10e')](_0x377575[_0x1837a7('0xa8')]()['then'](function(_0x2b7262){const _0x379201=_0x1837a7;for(let _0x16d932=0x0;_0x16d932<_0x2b7262[_0x379201('0x112')];_0x16d932++){_0x2b7262[_0x16d932][_0x379201('0x31')](_0x379201('0xc4'),_0x379201('0xe4'));}return _0x2b7262;})),_0xc8cbdb[_0x1837a7('0x10e')](_0x377575['getFaxQueues']()[_0x1837a7('0x92')](function(_0x9ad7a1){const _0x1f0adb=_0x1837a7;for(let _0x1f0f3c=0x0;_0x1f0f3c<_0x9ad7a1['length'];_0x1f0f3c++){_0x9ad7a1[_0x1f0f3c]['setDataValue'](_0x1f0adb('0xc4'),_0x1f0adb('0xb3'));}return _0x9ad7a1;})),_0xc8cbdb[_0x1837a7('0x10e')](_0x377575['getOpenchannelQueues']()[_0x1837a7('0x92')](function(_0x433937){const _0x36dea8=_0x1837a7;for(let _0x1a0346=0x0;_0x1a0346<_0x433937[_0x36dea8('0x112')];_0x1a0346++){_0x433937[_0x1a0346]['setDataValue'](_0x36dea8('0xc4'),'Openchannel');}return _0x433937;})),Promise[_0x1837a7('0x43')](_0xc8cbdb);})[_0x14fa6a('0x92')](function(_0xddacc2){const _0x36466c=_0x14fa6a,_0x1d314a=_[_0x36466c('0x12b')](_0xddacc2);return _0xc8cbdb=[],db['sequelize'][_0x36466c('0x24')](function(_0x4a58dd){const _0x4b01b2=_0x36466c;for(let _0x4441cc=0x0;_0x4441cc<_0x1d314a[_0x4b01b2('0x112')];_0x4441cc++){_0xc8cbdb[_0x4b01b2('0x10e')](_0x1d314a[_0x4441cc][_0x4b01b2('0x150')](_0xd42442['id']),{'transaction':_0x4a58dd});}return Promise['all'](_0xc8cbdb)[_0x4b01b2('0x92')](function(){const _0x1654bc=_0x4b01b2;if(_0xd42442[_0x1654bc('0x10a')])return Promise['each'](_[_0x1654bc('0xf8')](_0x1d314a,function(_0x31af93){const _0x288c7b=_0x1654bc;return _0x31af93['getDataValue'](_0x288c7b('0xc4'))===_0x288c7b('0x158');}),function(_0x22aa66){const _0x541294=_0x1654bc;return db[_0x541294('0x91')][_0x541294('0x12c')]({'where':{'VoiceQueueId':_0x22aa66['id'],'UserId':_0xd42442['id']},'transaction':_0x4a58dd});});else return;})[_0x4b01b2('0x92')](function(){const _0x5b3512=_0x4b01b2;for(let _0x299fbb=0x0;_0x299fbb<_0x1d314a[_0x5b3512('0x112')];_0x299fbb++){const _0x53568d=_0x1d314a[_0x299fbb][_0x5b3512('0x118')](_0x5b3512('0xc4')),_0x4083cb=_0x53568d+_0x5b3512('0x5f');socket[_0x5b3512('0xee')](_0x5b3512('0x1d')+_0x53568d+'Queue:remove',{'UserId':_0xd42442['id'],[_0x4083cb]:_0x1d314a[_0x299fbb]['id']});}});});});}});}})[_0x191e6b('0x92')](respondWithStatusCode(_0x81f49e,null))[_0x191e6b('0x5b')](handleError(_0x81f49e,null));},exports['getLists']=function(_0x43101b,_0x17166f){const _0x47d39e=_0x5832ca;let _0x186895={};const _0xe8bacc={};let _0x3c88ee,_0xa5f458;return db[_0x47d39e('0xaa')][_0x47d39e('0xfa')]({'where':{'id':_0x43101b[_0x47d39e('0x2c')]['id']}})['then'](handleEntityNotFound(_0x17166f,null))[_0x47d39e('0x92')](function(_0x386ff0){const _0x264dcc=_0x47d39e;if(_0x386ff0)return _0x3c88ee=_0x386ff0,_0xe8bacc[_0x264dcc('0x3f')]=_[_0x264dcc('0x4e')](db[_0x264dcc('0x51')]['rawAttributes']),_0xe8bacc[_0x264dcc('0xd1')]=_[_0x264dcc('0x4e')](_0x43101b[_0x264dcc('0xd1')]),_0xe8bacc[_0x264dcc('0x36')]=_[_0x264dcc('0x13f')](_0xe8bacc[_0x264dcc('0x3f')],_0xe8bacc['query']),_0x186895[_0x264dcc('0x11a')]=_[_0x264dcc('0x13f')](_0xe8bacc[_0x264dcc('0x3f')],qs['fields'](_0x43101b['query'][_0x264dcc('0xf')])),_0x186895[_0x264dcc('0x11a')]=_0x186895['attributes']['length']?_0x186895[_0x264dcc('0x11a')]:_0xe8bacc['model'],_0x186895['order']=qs[_0x264dcc('0x25')](_0x43101b[_0x264dcc('0xd1')][_0x264dcc('0x25')]),_0x186895[_0x264dcc('0x13a')]=qs[_0x264dcc('0x36')](_[_0x264dcc('0xa')](_0x43101b[_0x264dcc('0xd1')],_0xe8bacc[_0x264dcc('0x36')])),_0x43101b['query'][_0x264dcc('0xf8')]&&(_0x186895['where']=_[_0x264dcc('0x10d')](_0x186895[_0x264dcc('0x13a')],{[Op['or']]:_[_0x264dcc('0x9c')](_0x186895[_0x264dcc('0x11a')],function(_0x1c3f75){const _0x1779e4=_0x264dcc,_0x13045c={};return _0x13045c[_0x1c3f75]={[Op[_0x1779e4('0x75')]]:'%'+_0x43101b['query'][_0x1779e4('0xf8')]+'%'},_0x13045c;})})),_0x186895=_['merge']({},_0x186895,_0x43101b[_0x264dcc('0x6d')]),_0x3c88ee[_0x264dcc('0x115')](_0x186895);})[_0x47d39e('0x92')](function(_0x2046f5){const _0x582db0=_0x47d39e;if(_0x2046f5)return _0xa5f458=_0x2046f5['length'],typeof _0x43101b[_0x582db0('0xd1')][_0x582db0('0x14c')]==='undefined'&&(_0x186895[_0x582db0('0x11d')]=qs['limit'](_0x43101b[_0x582db0('0xd1')]['limit']),_0x186895['offset']=qs[_0x582db0('0x89')](_0x43101b[_0x582db0('0xd1')]['offset'])),_0x3c88ee['getLists'](_0x186895);})[_0x47d39e('0x92')](function(_0x4d49c7){if(_0x4d49c7)return _0x4d49c7?{'count':_0xa5f458,'rows':_0x4d49c7}:null;})['then'](respondWithResult(_0x17166f,null))[_0x47d39e('0x5b')](handleError(_0x17166f,null));},exports[_0x5832ca('0x42')]=function(_0x56d351,_0x35cff5){const _0x54f9c8=_0x5832ca;let _0x39fe27={};const _0x595f41={};let _0x3dbdd2;return db[_0x54f9c8('0xaa')][_0x54f9c8('0xfa')]({'where':{'id':_0x56d351[_0x54f9c8('0x2c')]['id']}})[_0x54f9c8('0x92')](handleEntityNotFound(_0x35cff5,null))[_0x54f9c8('0x92')](function(_0x3acd47){const _0x5502cc=_0x54f9c8;if(_0x3acd47)return _0x3dbdd2=_0x3acd47,_0x595f41[_0x5502cc('0x3f')]=_[_0x5502cc('0x4e')](db[_0x5502cc('0xaa')][_0x5502cc('0xea')]),_0x595f41['query']=_[_0x5502cc('0x4e')](_0x56d351[_0x5502cc('0xd1')]),_0x595f41[_0x5502cc('0x36')]=_[_0x5502cc('0x13f')](_0x595f41[_0x5502cc('0x3f')],_0x595f41[_0x5502cc('0xd1')]),_0x39fe27[_0x5502cc('0x11a')]=_[_0x5502cc('0x13f')](_0x595f41[_0x5502cc('0x3f')],qs[_0x5502cc('0xf')](_0x56d351[_0x5502cc('0xd1')][_0x5502cc('0xf')])),_0x39fe27['attributes']=_0x39fe27[_0x5502cc('0x11a')]['length']?_0x39fe27['attributes']:_0x595f41[_0x5502cc('0x3f')],_0x39fe27['order']=qs['sort'](_0x56d351[_0x5502cc('0xd1')]['sort']),_0x39fe27[_0x5502cc('0x13a')]=qs[_0x5502cc('0x36')](_[_0x5502cc('0xa')](_0x56d351[_0x5502cc('0xd1')],_0x595f41['filters'])),_0x56d351[_0x5502cc('0xd1')][_0x5502cc('0xf8')]&&(_0x39fe27[_0x5502cc('0x13a')]=_[_0x5502cc('0x10d')](_0x39fe27[_0x5502cc('0x13a')],{[Op['or']]:_[_0x5502cc('0x9c')](_0x39fe27[_0x5502cc('0x11a')],function(_0x80a0a9){const _0x24a43d=_0x5502cc,_0x44777e={};return _0x44777e[_0x80a0a9]={[Op[_0x24a43d('0x75')]]:'%'+_0x56d351[_0x24a43d('0xd1')][_0x24a43d('0xf8')]+'%'},_0x44777e;})})),_0x39fe27[_0x5502cc('0x3f')]=db[_0x5502cc('0xaa')],_0x39fe27['as']=_0x5502cc('0xd9'),_0x39fe27=_['merge']({},_0x39fe27,_0x56d351[_0x5502cc('0x6d')]),_0x3dbdd2[_0x5502cc('0x15e')]({'include':[_0x39fe27]});})[_0x54f9c8('0x92')](function(_0x526d24){const _0x3af6a1=_0x54f9c8;if(_0x526d24){let _0x3ac52e={};const _0x308766=[];for(let _0x690e4=0x0;_0x690e4<_0x526d24[_0x3af6a1('0x112')];_0x690e4+=0x1){for(let _0x554405=0x0,_0x282bc7;_0x554405<_0x526d24[_0x690e4]['Agents']['length'];_0x554405+=0x1){_0x282bc7=_0x526d24[_0x690e4][_0x3af6a1('0xd9')][_0x554405][_0x3af6a1('0xc9')]({'plain':!![]}),_0x3ac52e[_0x282bc7['id']]=_0x282bc7;}}_0x3ac52e=_[_0x3af6a1('0x148')](_0x3ac52e);for(let _0x1b457b=qs[_0x3af6a1('0x89')](_0x56d351['query'][_0x3af6a1('0x89')]);_0x1b457b<_0x3ac52e['length']&&_0x308766['length']=_0xaabb49?(_0x2d420b=_0xaabb49,_0xbe0d5=0xc8):_0xbe0d5=0xce,_0x5c7a6d[_0x5ce9ac('0x151')](_0xbe0d5),_0x5c7a6d[_0x5ce9ac('0xf0')]('Content-Range',_0x2c5a90+'-'+_0x2d420b+'/'+_0xaabb49)[_0x5ce9ac('0xc')](_0x51018f);}return null;};}function saveUpdates(_0x2034d0){return function(_0x52e71e){const _0x10ab78=a648_0x8395;if(_0x52e71e)return _0x52e71e[_0x10ab78('0xc2')](_0x2034d0)[_0x10ab78('0x158')](function(_0x1374bc){return _0x1374bc;});return null;};}function removeEntity(_0x4a4035){return function(_0x1aa82e){const _0x2d78e7=a648_0x8395;if(_0x1aa82e)return _0x1aa82e[_0x2d78e7('0x14b')]()[_0x2d78e7('0x158')](function(){const _0x221417=_0x2d78e7,_0x3a0fda=_0x1aa82e['get']({'plain':!![]});if(_0x3a0fda[_0x221417('0x85')]===_0x221417('0x4a'))return;const _0x40e273=[{'name':_0x221417('0xdc'),'value':_0x221417('0xcc'),'ignore':!![]},{'name':_0x221417('0x106'),'value':_0x221417('0x25'),'ignore':![]},{'name':_0x221417('0x1e'),'value':_0x221417('0x4b'),'ignore':![]}],_0x189992=_(_0x40e273)[_0x221417('0x44')](_0x221417('0x10c'))['map'](_0x221417('0x71'))['value']();if(_[_0x221417('0x2a')](_0x189992,_0x3a0fda[_0x221417('0x85')]))return;const _0x45e055=_[_0x221417('0x3c')](_0x40e273,[_0x221417('0x71'),_0x3a0fda[_0x221417('0x85')]])[_0x221417('0xaf')];return db[_0x221417('0x13e')][_0x221417('0x14b')]({'where':{'type':_0x45e055,'resourceId':_0x3a0fda['id']}})[_0x221417('0x158')](function(){return _0x1aa82e;});})['then'](function(){const _0x2599f3=_0x2d78e7;_0x4a4035[_0x2599f3('0x151')](0xcc)[_0x2599f3('0xeb')]();});};}function handleEntityNotFound(_0x404e6e){return function(_0x1cecba){return!_0x1cecba&&_0x404e6e['sendStatus'](0x194),_0x1cecba;};}function handleError(_0x495fbb,_0x575b7b){return _0x575b7b=_0x575b7b||0x1f4,function(_0x6b9151){const _0x5f6c20=a648_0x8395;logger[_0x5f6c20('0x5a')](_0x6b9151['stack']),_0x6b9151[_0x5f6c20('0xaf')]&&delete _0x6b9151[_0x5f6c20('0xaf')],_0x495fbb[_0x5f6c20('0x151')](_0x575b7b)[_0x5f6c20('0x12f')](_0x6b9151);};}function validateUser(_0x286890){return new Promise(function(_0x13523e,_0x14a0ee){const _0xba9a4e=a648_0x8395;if(_0x286890[_0xba9a4e('0x150')])return _0x13523e(_0x286890);return db[_0xba9a4e('0x8f')][_0xba9a4e('0x33')](0x1)[_0xba9a4e('0x158')](function(_0x500bcd){const _0x1cbafe=_0xba9a4e;if(_0x500bcd[_0x1cbafe('0xf4')])authService['validatePasswordPattern'](_0x286890[_0x1cbafe('0x98')]);db[_0x1cbafe('0x159')][_0x1cbafe('0x28')](_0x1cbafe('0x150'))[_0x1cbafe('0x158')](function(_0x2a8c3c){const _0x4323e3=_0x1cbafe;if(_[_0x4323e3('0x161')](_0x2a8c3c)){_0x286890[_0x4323e3('0x150')]=_0x500bcd[_0x4323e3('0x119')]||0x1;return;}if(_[_0x4323e3('0x161')](_0x500bcd[_0x4323e3('0x119')])||_0x500bcd[_0x4323e3('0x119')]===_0x2a8c3c){_0x286890['internal']=_0x2a8c3c+0x1;return;}if(_0x500bcd[_0x4323e3('0x119')]>_0x2a8c3c){_0x286890[_0x4323e3('0x150')]=_0x500bcd['min_internal'];return;}return db[_0x4323e3('0x6e')][_0x4323e3('0x126')]('select\x20(select\x20IFNULL(max(internal)+1,1)\x20from\x20users\x20where\x20internal\x20<\x20md.internal)\x20as\x20\x27from\x27,\x20md.internal\x20-\x201\x20as\x20\x27to\x27\x20from\x20users\x20md\x20where\x20md.internal\x20!=\x201\x20and\x20not\x20exists\x20(select\x201\x20from\x20users\x20md2\x20where\x20md2.internal\x20=\x20md.internal\x20-\x201)',{'type':QueryTypes[_0x4323e3('0x5c')]})['then'](function(_0xf21bbe){const _0x29ef87=_0x4323e3;if(_0xf21bbe&&_0xf21bbe[_0x29ef87('0xab')])for(let _0x301335=0x0,_0x84018f=_0xf21bbe[_0x29ef87('0xab')];_0x301335<_0x84018f&&_[_0x29ef87('0x161')](_0x286890[_0x29ef87('0x150')]);_0x301335++){if(_0x500bcd[_0x29ef87('0x119')]<=_0xf21bbe[_0x301335][_0x29ef87('0xaa')])_0x286890[_0x29ef87('0x150')]=_0xf21bbe[_0x301335][_0x29ef87('0xaa')];else _0x500bcd[_0x29ef87('0x119')]>_0xf21bbe[_0x301335][_0x29ef87('0xaa')]&&_0x500bcd[_0x29ef87('0x119')]<=_0xf21bbe[_0x301335]['to']&&(_0x286890[_0x29ef87('0x150')]=_0x500bcd[_0x29ef87('0x119')]);}return _[_0x29ef87('0x161')](_0x286890[_0x29ef87('0x150')])&&(_0x286890[_0x29ef87('0x150')]=_0x2a8c3c+0x1),_0x13523e(_0x286890);});});})[_0xba9a4e('0x38')](function(_0x5cb06d){_0x14a0ee(_0x5cb06d);});});}function updateUser(_0x42a29d){return new Promise(function(_0x418d4a,_0xb5665e){const _0x155cfd=a648_0x8395;try{_0x42a29d[_0x155cfd('0x77')]&&(_0x42a29d['mailbox']=_0x42a29d[_0x155cfd('0x150')],_0x42a29d['VoiceMail']={'mailbox':_0x42a29d[_0x155cfd('0x150')],'password':_0x42a29d[_0x155cfd('0x98')],'fullname':_0x42a29d[_0x155cfd('0x9e')],'email':_0x42a29d['email']});if(_0x42a29d['role']===_0x155cfd('0x25')){if(!_0x42a29d[_0x155cfd('0x135')])_0x42a29d[_0x155cfd('0x135')]=['101',_0x155cfd('0x95'),_0x155cfd('0x11c'),_0x155cfd('0x14f'),'110','104',_0x155cfd('0x153'),_0x155cfd('0x4d'),'107','108',_0x155cfd('0x4f'),_0x155cfd('0x14d'),_0x155cfd('0x6b'),'114'];}_0x418d4a(_0x42a29d);}catch(_0xe73d5d){_0xb5665e(_0xe73d5d);}});}exports[_0x3b43e1('0x64')]=function(_0xdef46d,_0x4b0bd0){const _0x420a3e=_0x3b43e1;let _0x1de023={};const _0x4906d3={},_0x50fc87={'count':0x0,'rows':[]},_0x488dc7=_[_0x420a3e('0x47')](db[_0x420a3e('0x159')][_0x420a3e('0x89')],function(_0x23f59b){const _0xe2812d=_0x420a3e;return{'name':_0x23f59b[_0xe2812d('0x74')],'type':_0x23f59b['type'][_0xe2812d('0x54')]};});_0x4906d3['model']=_[_0x420a3e('0xae')](_[_0x420a3e('0x47')](_0x488dc7,_0x420a3e('0xaf')),['password','salt']),_0x4906d3['query']=_[_0x420a3e('0x113')](_0xdef46d[_0x420a3e('0x126')]),_0x4906d3[_0x420a3e('0x49')]=_['intersection'](_0x4906d3['model'],_0x4906d3['query']),_0x1de023[_0x420a3e('0x92')]=_[_0x420a3e('0xbc')](_0x4906d3[_0x420a3e('0x1c')],qs[_0x420a3e('0x3')](_0xdef46d['query'][_0x420a3e('0x3')])),_0x1de023[_0x420a3e('0x92')]=_0x1de023[_0x420a3e('0x92')]['length']?_0x1de023[_0x420a3e('0x92')]:_0x4906d3[_0x420a3e('0x1c')];typeof _0xdef46d['query'][_0x420a3e('0x109')]===_0x420a3e('0x9c')&&(_0x1de023[_0x420a3e('0xfa')]=qs[_0x420a3e('0xfa')](_0xdef46d[_0x420a3e('0x126')][_0x420a3e('0xfa')]),_0x1de023[_0x420a3e('0xfc')]=qs[_0x420a3e('0xfc')](_0xdef46d[_0x420a3e('0x126')][_0x420a3e('0xfc')]));_0x1de023[_0x420a3e('0x11d')]=qs['sort'](_0xdef46d['query'][_0x420a3e('0x8')]),_0x1de023[_0x420a3e('0x11e')]=qs['filters'](_[_0x420a3e('0xe1')](_0xdef46d['query'],_0x4906d3[_0x420a3e('0x49')]),_0x488dc7);_0xdef46d[_0x420a3e('0x126')][_0x420a3e('0x44')]&&(_0x1de023[_0x420a3e('0x11e')]=_[_0x420a3e('0x72')](_0x1de023[_0x420a3e('0x11e')],{[Op['or']]:_['map'](_0x488dc7,function(_0xbc1e9c){const _0x1c5fa2=_0x420a3e;if(_0xbc1e9c[_0x1c5fa2('0x69')]!==_0x1c5fa2('0x7'))return where(fn(_0x1c5fa2('0x122'),col(_0xbc1e9c[_0x1c5fa2('0xaf')])),{'$like':fn(_0x1c5fa2('0x122'),'%'+_0xdef46d['query'][_0x1c5fa2('0x44')]+'%')});})}));_0x1de023=_[_0x420a3e('0x72')]({},_0x1de023,_0xdef46d[_0x420a3e('0x117')]);const _0x408e16={'where':_0x1de023[_0x420a3e('0x11e')]};return db['User'][_0x420a3e('0x144')](_0x408e16)[_0x420a3e('0x158')](function(_0x48f849){const _0x52de00=_0x420a3e;return _0x50fc87[_0x52de00('0x144')]=_0x48f849,typeof _0xdef46d[_0x52de00('0x126')]['includeAll']!==_0x52de00('0x9c')&&(_0x1de023[_0x52de00('0x48')]=[{'all':!![]}]),db[_0x52de00('0x159')][_0x52de00('0x128')](_0x1de023);})[_0x420a3e('0x158')](function(_0x23f771){return _0x50fc87['rows']=_0x23f771,_0x50fc87;})[_0x420a3e('0x158')](respondWithFilteredResult(_0x4b0bd0,_0x1de023))['catch'](handleError(_0x4b0bd0,null));},exports[_0x3b43e1('0x125')]=function(_0x239d17,_0x69084b){const _0x2e6a9f=_0x3b43e1;let _0x51a1b9={'raw':![],'where':{'id':_0x239d17[_0x2e6a9f('0x13b')]['id']}};const _0x3f9cb9={};return _0x3f9cb9[_0x2e6a9f('0x1c')]=_[_0x2e6a9f('0xae')](_[_0x2e6a9f('0x113')](db['User'][_0x2e6a9f('0x89')]),[_0x2e6a9f('0x98'),_0x2e6a9f('0xbb')]),_0x3f9cb9[_0x2e6a9f('0x126')]=_[_0x2e6a9f('0x113')](_0x239d17[_0x2e6a9f('0x126')]),_0x3f9cb9[_0x2e6a9f('0x49')]=_['intersection'](_0x3f9cb9['model'],_0x3f9cb9[_0x2e6a9f('0x126')]),_0x51a1b9[_0x2e6a9f('0x92')]=_[_0x2e6a9f('0xbc')](_0x3f9cb9[_0x2e6a9f('0x1c')],qs['fields'](_0x239d17[_0x2e6a9f('0x126')][_0x2e6a9f('0x3')])),_0x51a1b9[_0x2e6a9f('0x92')]=_0x51a1b9[_0x2e6a9f('0x92')]['length']?_0x51a1b9[_0x2e6a9f('0x92')]:_0x3f9cb9['model'],_0x239d17[_0x2e6a9f('0x126')][_0x2e6a9f('0x11b')]&&(_0x51a1b9['include']=[{'all':!![]}]),_0x51a1b9=_[_0x2e6a9f('0x72')]({},_0x51a1b9,_0x239d17[_0x2e6a9f('0x117')]),db[_0x2e6a9f('0x159')][_0x2e6a9f('0xc9')](_0x51a1b9)['then'](handleEntityNotFound(_0x69084b,null))['then'](respondWithResult(_0x69084b,null))[_0x2e6a9f('0x38')](handleError(_0x69084b,null));},exports[_0x3b43e1('0x110')]=function(_0x42d2f3,_0x52fbb8){const _0x11b2ca=_0x3b43e1,_0x1f270f=_0x42d2f3['body'];let _0x2d0cf8=[];if(_0x42d2f3[_0x11b2ca('0xcc')][_0x11b2ca('0x85')]===_0x11b2ca('0x25'))throw new Error(_0x11b2ca('0x15'));if(_[_0x11b2ca('0xc6')](_0x1f270f,[_0x11b2ca('0x85'),'user'])&&_0x42d2f3[_0x11b2ca('0xcc')][_0x11b2ca('0x85')]!==_0x11b2ca('0x4a'))throw new Error(_0x11b2ca('0xdf'));if(_[_0x11b2ca('0xc6')](_0x1f270f,[_0x11b2ca('0x85'),_0x11b2ca('0x4a')])&&_0x42d2f3['user']['role']!==_0x11b2ca('0x4a'))throw new Error(_0x11b2ca('0xa2'));return licenseUtil[_0x11b2ca('0x100')](_0x1f270f)[_0x11b2ca('0x158')](function(){return validateUser(_0x1f270f[0x0]);})['then'](function(){const _0x411483=_0x11b2ca;for(let _0x1f915d=0x1;_0x1f915d<_0x1f270f[_0x411483('0xab')];_0x1f915d++){const _0x1eb22a=_0x1f270f[_0x1f915d-0x1][_0x411483('0x150')];if(!_0x1f270f[_0x1f915d][_0x411483('0x150')])_0x1f270f[_0x1f915d][_0x411483('0x150')]=_0x1eb22a+0x1;_0x2d0cf8[_0x411483('0x137')](validateUser(_0x1f270f[_0x1f915d]));}return Promise[_0x411483('0x10e')](_0x2d0cf8);})[_0x11b2ca('0x158')](function(){const _0xaaa3ec=_0x11b2ca;_0x2d0cf8=[];for(let _0x2f9be0=0x0;_0x2f9be0<_0x1f270f[_0xaaa3ec('0xab')];_0x2f9be0++){_0x2d0cf8[_0xaaa3ec('0x137')](updateUser(_0x1f270f[_0x2f9be0]));}return Promise[_0xaaa3ec('0x10e')](_0x2d0cf8);})[_0x11b2ca('0x158')](function(){const _0x2e309f=_0x11b2ca;return _0x2d0cf8=_0x1f270f['map'](_0x54478a=>{const _0x4130dc=a648_0x8395;return db[_0x4130dc('0x159')][_0x4130dc('0xa5')](_0x54478a,{'include':[{'model':db[_0x4130dc('0xa0')],'as':_0x4130dc('0xa0')}]})[_0x4130dc('0x158')](function(_0x26cf8d){return _0x54478a['id']=_0x26cf8d['id'],_0x54478a;});}),Promise[_0x2e309f('0x10e')](_0x2d0cf8);})[_0x11b2ca('0x158')](function(_0x1ae059){const _0x4dfa25=_0x11b2ca;if(_0x42d2f3[_0x4dfa25('0x36')]['role']===_0x4dfa25('0xcc'))return _0x1ae059;if(_0x42d2f3[_0x4dfa25('0xcc')][_0x4dfa25('0x85')]!=='user')return _0x1ae059;const _0x339d56=_[_0x4dfa25('0xc6')](_0x1ae059,function(_0x38ab23){const _0x3c824c=_0x4dfa25;return _0x38ab23[_0x3c824c('0x85')]==='agent'||_0x38ab23[_0x3c824c('0x85')]===_0x3c824c('0x4b');});if(!_0x339d56)return _0x1ae059;return db['UserProfileSection']['findAll']({'where':{'name':{[Op['or']]:[_0x4dfa25('0x106'),_0x4dfa25('0x1e')]},'userProfileId':_0x42d2f3[_0x4dfa25('0xcc')][_0x4dfa25('0xc7')]},'raw':!![]})[_0x4dfa25('0x158')](function(_0x2962e7){const _0x7fec20=_0x4dfa25;if(_[_0x7fec20('0x39')](_0x2962e7)||!_['some'](_0x2962e7,[_0x7fec20('0x46'),0x0]))return _0x1ae059;_0x2d0cf8=[];const _0x5c9450=_(_0x2962e7)[_0x7fec20('0x47')](function(_0x4011ea){const _0xcd2a2d=_0x7fec20;if(_0x4011ea[_0xcd2a2d('0x46')]===0x1)return;return _0x4011ea[_0xcd2a2d('0xaf')]===_0xcd2a2d('0x106')?_0xcd2a2d('0x25'):_0xcd2a2d('0x4b');})['compact']()[_0x7fec20('0x71')]();for(let _0x505c22=0x0;_0x505c22<_0x1ae059[_0x7fec20('0xab')];_0x505c22++){if(!_[_0x7fec20('0x2a')](_0x5c9450,_0x1ae059[_0x505c22][_0x7fec20('0x85')]))return;const _0x2ff1dd=_0x1ae059[_0x505c22][_0x7fec20('0x85')]===_0x7fec20('0x25')?_0x7fec20('0x106'):_0x7fec20('0x1e');_0x2d0cf8[_0x7fec20('0x137')](db[_0x7fec20('0x13e')]['create']({'name':_0x1ae059[_0x505c22][_0x7fec20('0xaf')],'resourceId':_0x1ae059[_0x505c22]['id'],'type':_0x2ff1dd,'sectionId':_[_0x7fec20('0x3c')](_0x2962e7,[_0x7fec20('0xaf'),_0x2ff1dd])['id']},{}));}return Promise[_0x7fec20('0x10e')](_0x2d0cf8);});})[_0x11b2ca('0x158')](respondWithResult(_0x52fbb8,0xc9))[_0x11b2ca('0x38')](handleError(_0x52fbb8,null));},exports[_0x3b43e1('0xc2')]=function(_0x44374b,_0x4940aa){const _0xefba5a=_0x3b43e1;return _0x44374b['body']['id']&&delete _0x44374b[_0xefba5a('0x36')]['id'],delete _0x44374b['body'][_0xefba5a('0x85')],db[_0xefba5a('0x159')][_0xefba5a('0xc9')]({'where':{'id':_0x44374b['params']['id']}})['then'](handleEntityNotFound(_0x4940aa,null))['then'](saveUpdates(_0x44374b[_0xefba5a('0x36')],null))[_0xefba5a('0x158')](respondWithResult(_0x4940aa,null))['catch'](handleError(_0x4940aa,null));},exports['describe']=function(_0x488b7e,_0x3db19f){const _0x49c87c=_0x3b43e1;return db[_0x49c87c('0x159')][_0x49c87c('0xfd')]()[_0x49c87c('0x158')](respondWithResult(_0x3db19f,null))[_0x49c87c('0x38')](handleError(_0x3db19f,null));},exports[_0x3b43e1('0x13')]=function(_0x15d7fc,_0x30b7d9){const _0x1c5d89=_0x3b43e1;return db[_0x1c5d89('0x159')]['findOne']({'where':{'id':_0x15d7fc[_0x1c5d89('0x13b')]['id']}})[_0x1c5d89('0x158')](handleEntityNotFound(_0x30b7d9,null))[_0x1c5d89('0x158')](function(_0x1e2630){const _0x2926dd=_0x1c5d89;if(_0x1e2630)return _0x1e2630['addContacts'](_0x15d7fc[_0x2926dd('0x36')][_0x2926dd('0x132')],{'through':_[_0x2926dd('0xac')](_0x15d7fc[_0x2926dd('0x36')],[_0x2926dd('0x132'),'id'])});})[_0x1c5d89('0x158')](respondWithResult(_0x30b7d9,null))[_0x1c5d89('0x38')](handleError(_0x30b7d9,null));},exports[_0x3b43e1('0xa5')]=function(_0x56595b,_0x2063a3){const _0x27de9c=_0x3b43e1;if(_0x56595b[_0x27de9c('0xcc')][_0x27de9c('0x85')]===_0x27de9c('0x25'))throw new Error('Unauthorized');if(_0x56595b[_0x27de9c('0x36')][_0x27de9c('0x85')]===_0x27de9c('0xcc')&&_0x56595b[_0x27de9c('0xcc')][_0x27de9c('0x85')]!=='admin')throw new Error(_0x27de9c('0xdf'));if(_0x56595b['body'][_0x27de9c('0x85')]==='admin'&&_0x56595b[_0x27de9c('0xcc')][_0x27de9c('0x85')]!==_0x27de9c('0x4a'))throw new Error(_0x27de9c('0xa3'));return licenseUtil[_0x27de9c('0x100')]([_0x56595b['body']])[_0x27de9c('0x158')](function(){const _0x34c166=_0x27de9c;return validateUser(_0x56595b[_0x34c166('0x36')]);})['then'](function(_0x4c53ce){const _0x2f7ff5=_0x27de9c;return updateUser(_0x4c53ce)[_0x2f7ff5('0x158')](function(_0x1216ef){const _0x261f39=_0x2f7ff5;return _0x1216ef[_0x261f39('0x85')]===_0x261f39('0x4a')&&(_0x1216ef['settingsEnabled']=_0x56595b[_0x261f39('0xcc')]['settingsEnabled'],delete _0x1216ef['userProfileId']),_0x1216ef;});})[_0x27de9c('0x158')](function(_0x24d5c0){const _0x988e92=_0x27de9c;return db['User'][_0x988e92('0xa5')](_0x24d5c0,{'include':[{'model':db[_0x988e92('0xa0')],'as':_0x988e92('0xa0')}]});})['then'](function(_0x55f67e){const _0x47b31f=_0x27de9c;if(_0x56595b['body'][_0x47b31f('0x85')]===_0x47b31f('0xcc'))return _0x55f67e;if(_0x56595b[_0x47b31f('0xcc')][_0x47b31f('0x85')]!==_0x47b31f('0xcc'))return _0x55f67e;return db[_0x47b31f('0xdb')]['findOne']({'where':{'name':_0x55f67e[_0x47b31f('0x85')]===_0x47b31f('0x25')?'Agents':_0x47b31f('0x1e'),'userProfileId':_0x56595b[_0x47b31f('0xcc')]['userProfileId']},'raw':!![]})[_0x47b31f('0x158')](function(_0x31e3be){const _0x2a91c0=_0x47b31f;if(!_0x31e3be||_0x31e3be[_0x2a91c0('0x46')]!=0x0)return _0x55f67e;return db[_0x2a91c0('0x13e')][_0x2a91c0('0xa5')]({'name':_0x55f67e['name'],'resourceId':_0x55f67e['id'],'type':_0x31e3be[_0x2a91c0('0xaf')],'sectionId':_0x31e3be['id']},{})[_0x2a91c0('0x158')](function(){return _0x55f67e;});})[_0x47b31f('0x38')](function(_0x414b13){const _0xca251d=_0x47b31f;logger[_0xca251d('0x5a')](_0xca251d('0x82'),_0x414b13);throw _0x414b13;});})[_0x27de9c('0x158')](respondWithResult(_0x2063a3,0xc9))[_0x27de9c('0x38')](handleError(_0x2063a3,null));},exports[_0x3b43e1('0xd7')]=function(_0x44b233,_0x56eae7){const _0x2c5837=_0x3b43e1;if(_0x44b233[_0x2c5837('0x36')]['id'])delete _0x44b233[_0x2c5837('0x36')]['id'];return db[_0x2c5837('0x159')]['findOne']({'where':{'id':_0x44b233[_0x2c5837('0x13b')]['id']}})[_0x2c5837('0x158')](function(_0x516de6){const _0x2f12e2=_0x2c5837;if(!_0x516de6)return null;if(_0x516de6['id']===_0x44b233['user']['id']){if(!_0x44b233[_0x2f12e2('0x36')]['oldPassword']||!_0x44b233[_0x2f12e2('0x36')]['newPassword'])throw new ValidationError(_0x2f12e2('0x160'));if(!_0x516de6[_0x2f12e2('0xee')](_0x44b233[_0x2f12e2('0x36')][_0x2f12e2('0x7a')]))throw new ValidationError('Wrong\x20credentials');if(_0x44b233[_0x2f12e2('0x36')][_0x2f12e2('0x7a')]===_0x44b233['body'][_0x2f12e2('0xb4')])throw new ValidationError('New\x20password\x20must\x20be\x20different\x20from\x20old\x20password');}else{if(_0x44b233['user']['role']==='admin'){if(!_0x44b233[_0x2f12e2('0x36')][_0x2f12e2('0xb4')])throw new ValidationError('Invalid\x20body\x20format.\x20Use\x20newPassword');}else{if(_0x44b233['user']['role']===_0x2f12e2('0xcc')){if(!_0x44b233[_0x2f12e2('0x36')][_0x2f12e2('0xb4')])throw new ValidationError(_0x2f12e2('0x86'));if(_0x516de6[_0x2f12e2('0x85')]!=='agent')throw new ValidationError('Unauthorized');}else throw new ValidationError('Unauthorized');}}return _0x516de6;})['then'](handleEntityNotFound(_0x56eae7,null))[_0x2c5837('0x158')](function(_0x9433d4){const _0x10d16d=_0x2c5837;return db[_0x10d16d('0x8f')][_0x10d16d('0xc9')]({'attributes':['id','securePassword','enforcePasswordHistory',_0x10d16d('0x13a')]})[_0x10d16d('0x158')](function(_0x1efc64){const _0x770a9c=_0x10d16d;if(_0x1efc64['securePassword'])authService['validatePasswordPattern'](_0x44b233[_0x770a9c('0x36')][_0x770a9c('0xb4')]);if(!_0x1efc64[_0x770a9c('0xc0')]||!_0x9433d4['previousPasswords'])return _0x9433d4;return authService[_0x770a9c('0xf')](_0x44b233['body'][_0x770a9c('0xb4')],_0x9433d4[_0x770a9c('0xd6')],_0x1efc64['passwordHistoryLimit']),_0x9433d4;})['then'](saveUpdates({'password':_0x44b233[_0x10d16d('0x36')][_0x10d16d('0xb4')],'passwordResetAt':_0x44b233[_0x10d16d('0xcc')]['id']==_0x44b233[_0x10d16d('0x13b')]['id']?moment():null,'previousPasswords':authService['updatePasswordsHistory'](_0x44b233['body'][_0x10d16d('0xb4')],_0x9433d4['previousPasswords'])},null));})[_0x2c5837('0x158')](respondWithResult(_0x56eae7,null))[_0x2c5837('0x38')](handleError(_0x56eae7,null));},exports[_0x3b43e1('0xed')]=function(_0x39c2c3,_0x119143){const _0x1391c3=_0x3b43e1,_0x2c7d3f=_0x39c2c3[_0x1391c3('0x36')][_0x1391c3('0x10b')];return db[_0x1391c3('0x159')][_0x1391c3('0xc9')]({'where':{'id':_0x39c2c3[_0x1391c3('0x13b')]['id']},'attributes':['id',_0x1391c3('0xaf'),_0x1391c3('0x85'),'online','loginInPause',_0x1391c3('0x37'),_0x1391c3('0x14e')]})[_0x1391c3('0x158')](handleEntityNotFound(_0x119143,null))['then'](function(_0x1721d6){const _0x5df4f4=_0x1391c3;if(_0x1721d6){if(!utils[_0x5df4f4('0x66')](_0x2c7d3f))throw new ValidationError('Unknown\x20channel');return _0x1721d6['add'+_['capitalize'](_0x2c7d3f[_0x5df4f4('0x5')]())+_0x5df4f4('0x140')](_0x39c2c3['body'][_0x5df4f4('0x132')],{'through':{'penalty':_0x39c2c3[_0x5df4f4('0x36')][_0x5df4f4('0x84')]||0x0}})[_0x5df4f4('0x158')](function(_0x26c353){const _0x143808=_0x5df4f4;for(let _0x1a0156=0x0;_0x1a0156<_0x39c2c3['body']['ids'][_0x143808('0xab')];_0x1a0156+=0x1){const _0x4c9dc8={'UserId':_0x39c2c3[_0x143808('0x13b')]['id']};_0x4c9dc8[_[_0x143808('0x3b')](_0x2c7d3f[_0x143808('0x5')]())+'QueueId']=_0x39c2c3['body']['ids'][_0x1a0156],socket[_0x143808('0xd')]('user'+_['capitalize'](_0x2c7d3f[_0x143808('0x5')]())+_0x143808('0x2f'),_0x4c9dc8);}return _0x26c353;})['then'](function(){const _0x5e7e19=_0x5df4f4;if(_0x2c7d3f===_0x5e7e19('0x157'))return db[_0x5e7e19('0x2')][_0x5e7e19('0x128')]({'where':{'id':_0x39c2c3[_0x5e7e19('0x36')][_0x5e7e19('0x132')]||[]},'raw':!![],'attributes':['id',_0x5e7e19('0xaf')]});})[_0x5df4f4('0x158')](function(_0x5d9f49){const _0x111920=_0x5df4f4,_0xb178cb=_0x1721d6['get']({'plain':!![]}),_0x5ba568=[];if(_0x2c7d3f==='voice'&&_0xb178cb[_0x111920('0x85')]===_0x111920('0x25')&&_0xb178cb['online']){for(let _0x59e700=0x0;_0x59e700<_0x5d9f49[_0x111920('0xab')];_0x59e700+=0x1){_0x5ba568['push']({'membername':_0xb178cb[_0x111920('0xaf')],'UserId':_0xb178cb['id'],'queue_name':_0x5d9f49[_0x59e700][_0x111920('0xaf')],'VoiceQueueId':_0x5d9f49[_0x59e700]['id'],'interface':_[_0x111920('0x161')](_0xb178cb[_0x111920('0x14e')])?util[_0x111920('0x6a')](_0x111920('0xcf'),_0xb178cb[_0x111920('0xaf')]):_0xb178cb[_0x111920('0x14e')],'paused':_0xb178cb['voicePause']||![],'penalty':_0x39c2c3[_0x111920('0x36')][_0x111920('0x84')]||0x0});}return Promise[_0x111920('0x96')](_0x5ba568,function(_0x40375e){const _0x92e7c9=_0x111920;return db['UserVoiceQueueRt'][_0x92e7c9('0x9a')](_0x40375e);});}return _0x1721d6;});}})[_0x1391c3('0x158')](respondWithStatusCode(_0x119143,null))['catch'](handleError(_0x119143,null));},exports[_0x3b43e1('0x60')]=function(_0x1ff9f8,_0x4f17a9){const _0x3e57a9=_0x3b43e1;let _0x1d494b;return db[_0x3e57a9('0x159')][_0x3e57a9('0xc9')]({'where':{'id':_0x1ff9f8[_0x3e57a9('0x13b')]['id']},'attributes':['id',_0x3e57a9('0xaf'),_0x3e57a9('0x85')]})[_0x3e57a9('0x158')](handleEntityNotFound(_0x4f17a9,null))[_0x3e57a9('0x158')](function(_0x4a9bc2){const _0x10780b=_0x3e57a9;if(_0x4a9bc2){_0x1d494b=_0x4a9bc2;if(!_0x1ff9f8['query'][_0x10780b('0x10b')]||!utils[_0x10780b('0x66')](_0x1ff9f8[_0x10780b('0x126')][_0x10780b('0x10b')]))throw new ValidationError(_0x10780b('0x133'));return _0x4a9bc2[_0x10780b('0xa6')+_[_0x10780b('0x3b')](_0x1ff9f8[_0x10780b('0x126')][_0x10780b('0x10b')]['toLowerCase']())+_0x10780b('0x140')](_0x1ff9f8[_0x10780b('0x126')][_0x10780b('0x132')]);}})[_0x3e57a9('0x158')](function(_0x2aae56){const _0x5afd2c=_0x3e57a9;for(let _0x3a155c=0x0;_0x3a155c<_0x1ff9f8['query']['ids'][_0x5afd2c('0xab')];_0x3a155c+=0x1){const _0x1ec52d={'UserId':_0x1ff9f8[_0x5afd2c('0x13b')]['id']};_0x1ec52d[_[_0x5afd2c('0x3b')](_0x1ff9f8[_0x5afd2c('0x126')][_0x5afd2c('0x10b')]['toLowerCase']())+'QueueId']=_0x1ff9f8['query'][_0x5afd2c('0x132')][_0x3a155c],socket[_0x5afd2c('0xd')](_0x5afd2c('0xcc')+_[_0x5afd2c('0x3b')](_0x1ff9f8['query']['channel'][_0x5afd2c('0x5')]())+'Queue:remove',_0x1ec52d);}return _0x2aae56;})[_0x3e57a9('0x158')](function(){const _0x50c0fb=_0x3e57a9;if(_0x1ff9f8[_0x50c0fb('0x126')][_0x50c0fb('0x10b')]==='voice')return db[_0x50c0fb('0x5b')][_0x50c0fb('0x14b')]({'where':{'UserId':_0x1ff9f8['params']['id'],'VoiceQueueId':_0x1ff9f8['query']['ids']},'individualHooks':!![]})['then'](function(){return _0x1d494b;});return _0x1d494b;})[_0x3e57a9('0x158')](respondWithStatusCode(_0x4f17a9,null))['catch'](handleError(_0x4f17a9,null));},exports[_0x3b43e1('0x16')]=function(_0x5b4e92,_0x4cc2d3){const _0x6cf5e2=_0x3b43e1;return _0x5b4e92[_0x6cf5e2('0x36')][_0x6cf5e2('0x45')]=_0x5b4e92[_0x6cf5e2('0x6')][_0x6cf5e2('0x1')],db[_0x6cf5e2('0x159')]['findOne']({'where':{'id':_0x5b4e92[_0x6cf5e2('0x13b')]['id']}})[_0x6cf5e2('0x158')](handleEntityNotFound(_0x4cc2d3,null))[_0x6cf5e2('0x158')](saveUpdates(_0x5b4e92[_0x6cf5e2('0x36')],null))['then'](respondWithResult(_0x4cc2d3,null))[_0x6cf5e2('0x38')](handleError(_0x4cc2d3,null));},exports[_0x3b43e1('0x55')]=function(_0x511ae3,_0x363672){const _0x5a3d3f=_0x3b43e1,_0x3ade89=path[_0x5a3d3f('0x105')](config[_0x5a3d3f('0x13c')],_0x5a3d3f('0xca'));return db[_0x5a3d3f('0x159')][_0x5a3d3f('0xc9')]({'where':{'id':_0x511ae3[_0x5a3d3f('0x13b')]['id']},'attributes':['id','userpic'],'raw':!![]})['then'](handleEntityNotFound(_0x363672,null))['then'](function(_0x33cafe){const _0x25069b=_0x5a3d3f;if(_0x33cafe){if(_[_0x25069b('0x161')](_0x33cafe['userpic']))return _0x363672[_0x25069b('0x2c')](_0x3ade89);else{if(!fs[_0x25069b('0xad')](path['join'](config[_0x25069b('0x13c')],'files/images/',_0x33cafe['userpic'])))return _0x363672[_0x25069b('0x2c')](_0x3ade89);return _0x363672[_0x25069b('0x2c')](path[_0x25069b('0x105')](config[_0x25069b('0x13c')],'files/images/',_0x33cafe[_0x25069b('0x45')]));}}})[_0x5a3d3f('0x38')](handleError(_0x363672,null));},exports['getContacts']=function(_0x45f7e8,_0x3a8e1c){const _0xdfde06=_0x3b43e1;let _0x356597={};const _0x554014={};let _0x51a4a4,_0x14bfc9;return db[_0xdfde06('0x159')][_0xdfde06('0xc9')]({'where':{'id':_0x45f7e8['params']['id']}})[_0xdfde06('0x158')](handleEntityNotFound(_0x3a8e1c,null))[_0xdfde06('0x158')](function(_0xc54008){const _0x56070a=_0xdfde06;if(_0xc54008)return _0x51a4a4=_0xc54008,_0x554014['model']=_[_0x56070a('0x113')](db['CmContact'][_0x56070a('0x89')]),_0x554014[_0x56070a('0x126')]=_[_0x56070a('0x113')](_0x45f7e8['query']),_0x554014[_0x56070a('0x49')]=_[_0x56070a('0xbc')](_0x554014[_0x56070a('0x1c')],_0x554014[_0x56070a('0x126')]),_0x356597[_0x56070a('0x92')]=_[_0x56070a('0xbc')](_0x554014[_0x56070a('0x1c')],qs['fields'](_0x45f7e8['query'][_0x56070a('0x3')])),_0x356597[_0x56070a('0x92')]=_0x356597[_0x56070a('0x92')][_0x56070a('0xab')]?_0x356597['attributes']:_0x554014[_0x56070a('0x1c')],_0x356597[_0x56070a('0x11d')]=qs[_0x56070a('0x8')](_0x45f7e8[_0x56070a('0x126')]['sort']),_0x356597[_0x56070a('0x11e')]=qs[_0x56070a('0x49')](_['pick'](_0x45f7e8[_0x56070a('0x126')],_0x554014[_0x56070a('0x49')])),_0x45f7e8['query']['filter']&&(_0x356597['where']=_[_0x56070a('0x72')](_0x356597['where'],{[Op['or']]:_[_0x56070a('0x47')](_0x356597['attributes'],function(_0x2c534e){const _0x517518=_0x56070a,_0x56a3df={};return _0x56a3df[_0x2c534e]={[Op[_0x517518('0x2b')]]:'%'+_0x45f7e8['query']['filter']+'%'},_0x56a3df;})})),_0x356597=_[_0x56070a('0x72')]({},_0x356597,_0x45f7e8[_0x56070a('0x117')]),_0x51a4a4[_0x56070a('0xe5')](_0x356597);})['then'](function(_0x59bce0){const _0x170392=_0xdfde06;if(_0x59bce0)return _0x14bfc9=_0x59bce0['length'],typeof _0x45f7e8[_0x170392('0x126')][_0x170392('0x11b')]!==_0x170392('0x9c')&&(_0x356597[_0x170392('0x48')]=[{'model':db[_0x170392('0x4c')],'as':_0x170392('0x141'),'required':![]},{'model':db[_0x170392('0x11a')],'as':_0x170392('0x19'),'attributes':['id','name','color'],'where':_0x45f7e8[_0x170392('0x126')][_0x170392('0x9b')]?{'id':_0x45f7e8[_0x170392('0x126')][_0x170392('0x9b')]}:undefined,'required':_0x45f7e8[_0x170392('0x126')][_0x170392('0x9b')]?!![]:![]}]),typeof _0x45f7e8['query'][_0x170392('0x109')]===_0x170392('0x9c')&&(_0x356597[_0x170392('0xfa')]=qs[_0x170392('0xfa')](_0x45f7e8[_0x170392('0x126')][_0x170392('0xfa')]),_0x356597[_0x170392('0xfc')]=qs['offset'](_0x45f7e8[_0x170392('0x126')]['offset'])),_0x51a4a4[_0x170392('0xe5')](_0x356597);})['then'](function(_0x1a3648){if(_0x1a3648)return _0x1a3648?{'count':_0x14bfc9,'rows':_0x1a3648}:null;})[_0xdfde06('0x158')](respondWithResult(_0x3a8e1c,null))[_0xdfde06('0x38')](handleError(_0x3a8e1c,null));},exports[_0x3b43e1('0x18')]=function(_0x56cee3,_0x3143df){const _0x35dcf0=_0x3b43e1;let _0x5231ec,_0x143c3d={},_0x4325f6;return db[_0x35dcf0('0x159')][_0x35dcf0('0xc9')]({'where':{'id':_0x56cee3['params']['id']},'attributes':['id',_0x35dcf0('0xaf'),_0x35dcf0('0x85')]})['then'](handleEntityNotFound(_0x3143df,null))[_0x35dcf0('0x158')](function(_0x3d14dd){const _0x25641d=_0x35dcf0;if(!utils[_0x25641d('0x66')](_0x56cee3[_0x25641d('0x126')][_0x25641d('0x10b')]))throw new ValidationError('Unknown\x20channel');_0x5231ec=_0x3d14dd;const _0x27959a={};_0x27959a[_0x25641d('0x1c')]=_[_0x25641d('0x113')](db[_[_0x25641d('0x3b')](_0x56cee3['query'][_0x25641d('0x10b')])+_0x25641d('0x1d')][_0x25641d('0x89')]),_0x27959a[_0x25641d('0x126')]=_[_0x25641d('0x113')](_0x56cee3[_0x25641d('0x126')]),_0x27959a[_0x25641d('0x49')]=_[_0x25641d('0xbc')](_0x27959a[_0x25641d('0x1c')],_0x27959a[_0x25641d('0x126')]),_0x143c3d[_0x25641d('0x92')]=_[_0x25641d('0xbc')](_0x27959a[_0x25641d('0x1c')],qs[_0x25641d('0x3')](_0x56cee3[_0x25641d('0x126')][_0x25641d('0x3')])),_0x143c3d[_0x25641d('0x92')]=_0x143c3d[_0x25641d('0x92')][_0x25641d('0xab')]?_0x143c3d['attributes']:_0x27959a['model'],_0x143c3d[_0x25641d('0x11d')]=qs['sort'](_0x56cee3[_0x25641d('0x126')]['sort']),_0x143c3d[_0x25641d('0x11e')]=qs[_0x25641d('0x49')](_[_0x25641d('0xe1')](_0x56cee3['query'],_0x27959a['filters']));_0x56cee3[_0x25641d('0x126')][_0x25641d('0x44')]&&(_0x143c3d[_0x25641d('0x11e')]=_[_0x25641d('0x72')](_0x143c3d[_0x25641d('0x11e')],{[Op['or']]:_['map'](_0x143c3d['attributes'],function(_0xb47a42){const _0x5dc422=_0x25641d,_0xe70ebd={};return _0xe70ebd[_0xb47a42]={[Op[_0x5dc422('0x2b')]]:'%'+_0x56cee3[_0x5dc422('0x126')][_0x5dc422('0x44')]+'%'},_0xe70ebd;})}));_0x143c3d=_[_0x25641d('0x72')]({},_0x143c3d,_0x56cee3[_0x25641d('0x117')]);switch(_0x5231ec[_0x25641d('0x85')]){case'admin':return db[_[_0x25641d('0x3b')](_0x56cee3[_0x25641d('0x126')][_0x25641d('0x10b')])+_0x25641d('0x1d')][_0x25641d('0x128')](_0x143c3d);case _0x25641d('0xcc'):case _0x25641d('0x25'):return _0x5231ec['get'+_[_0x25641d('0x3b')](_0x56cee3[_0x25641d('0x126')]['channel'])+_0x25641d('0x140')](_0x143c3d);default:throw new ValidationError(_0x25641d('0x70'));}})[_0x35dcf0('0x158')](function(_0x155661){const _0x4f5a3f=_0x35dcf0;_0x4325f6=_0x155661[_0x4f5a3f('0xab')];typeof _0x56cee3['query'][_0x4f5a3f('0x109')]==='undefined'&&(_0x143c3d[_0x4f5a3f('0xfa')]=qs[_0x4f5a3f('0xfa')](_0x56cee3[_0x4f5a3f('0x126')][_0x4f5a3f('0xfa')]),_0x143c3d[_0x4f5a3f('0xfc')]=qs[_0x4f5a3f('0xfc')](_0x56cee3[_0x4f5a3f('0x126')][_0x4f5a3f('0xfc')]));switch(_0x5231ec['role']){case _0x4f5a3f('0x4a'):return db[_[_0x4f5a3f('0x3b')](_0x56cee3[_0x4f5a3f('0x126')]['channel'])+_0x4f5a3f('0x1d')][_0x4f5a3f('0x128')](_0x143c3d);case'user':case _0x4f5a3f('0x25'):return _0x5231ec[_0x4f5a3f('0x1a')+_[_0x4f5a3f('0x3b')](_0x56cee3[_0x4f5a3f('0x126')]['channel'])+_0x4f5a3f('0x140')](_0x143c3d);}})[_0x35dcf0('0x158')](function(_0xfafb2c){return{'count':_0x4325f6,'rows':_0xfafb2c};})[_0x35dcf0('0x158')](respondWithResult(_0x3143df,null))['catch'](handleError(_0x3143df,null));},exports[_0x3b43e1('0x7f')]=function(_0x3108eb,_0x53ae03){const _0x32880f=_0x3b43e1;let _0x2f0bac={};const _0xd1c48f={};let _0x26aec3,_0x2082aa;return db['User'][_0x32880f('0xc9')]({'where':{'id':_0x3108eb[_0x32880f('0x13b')]['id']}})[_0x32880f('0x158')](handleEntityNotFound(_0x53ae03,null))[_0x32880f('0x158')](function(_0x539c1c){const _0x45ce27=_0x32880f;if(_0x539c1c)return _0x26aec3=_0x539c1c,_0xd1c48f['model']=_[_0x45ce27('0x113')](db[_0x45ce27('0x5b')][_0x45ce27('0x89')]),_0xd1c48f[_0x45ce27('0x126')]=_[_0x45ce27('0x113')](_0x3108eb[_0x45ce27('0x126')]),_0xd1c48f['filters']=_[_0x45ce27('0xbc')](_0xd1c48f[_0x45ce27('0x1c')],_0xd1c48f[_0x45ce27('0x126')]),_0x2f0bac[_0x45ce27('0x92')]=_['intersection'](_0xd1c48f['model'],qs['fields'](_0x3108eb[_0x45ce27('0x126')]['fields'])),_0x2f0bac[_0x45ce27('0x92')]=_0x2f0bac[_0x45ce27('0x92')]['length']?_0x2f0bac['attributes']:_0xd1c48f[_0x45ce27('0x1c')],_0x2f0bac[_0x45ce27('0x11d')]=qs[_0x45ce27('0x8')](_0x3108eb[_0x45ce27('0x126')]['sort']),_0x2f0bac[_0x45ce27('0x11e')]=qs[_0x45ce27('0x49')](_[_0x45ce27('0xe1')](_0x3108eb[_0x45ce27('0x126')],_0xd1c48f['filters'])),_0x3108eb[_0x45ce27('0x126')]['filter']&&(_0x2f0bac[_0x45ce27('0x11e')]=_['merge'](_0x2f0bac['where'],{[Op['or']]:_[_0x45ce27('0x47')](_0x2f0bac['attributes'],function(_0x281f94){const _0x46cc9a=_0x45ce27,_0x57cd9e={};return _0x57cd9e[_0x281f94]={[Op[_0x46cc9a('0x2b')]]:'%'+_0x3108eb[_0x46cc9a('0x126')][_0x46cc9a('0x44')]+'%'},_0x57cd9e;})})),_0x2f0bac=_[_0x45ce27('0x72')]({},_0x2f0bac,_0x3108eb[_0x45ce27('0x117')]),_0x26aec3[_0x45ce27('0x7f')](_0x2f0bac);})[_0x32880f('0x158')](function(_0x59d7f1){const _0x93c6d3=_0x32880f;if(_0x59d7f1)return _0x2082aa=_0x59d7f1[_0x93c6d3('0xab')],typeof _0x3108eb['query'][_0x93c6d3('0x109')]===_0x93c6d3('0x9c')&&(_0x2f0bac['limit']=qs['limit'](_0x3108eb[_0x93c6d3('0x126')][_0x93c6d3('0xfa')]),_0x2f0bac[_0x93c6d3('0xfc')]=qs[_0x93c6d3('0xfc')](_0x3108eb[_0x93c6d3('0x126')]['offset'])),_0x26aec3[_0x93c6d3('0x7f')](_0x2f0bac);})['then'](function(_0x37750f){if(_0x37750f)return _0x37750f?{'count':_0x2082aa,'rows':_0x37750f}:null;})[_0x32880f('0x158')](respondWithResult(_0x53ae03,null))[_0x32880f('0x38')](handleError(_0x53ae03,null));},exports['getGroups']=function(_0x5c3511,_0xbae0be){const _0x3b6e41=_0x3b43e1;let _0x2ca144={};const _0x2f1619={};let _0x38662e,_0x516d9b;return db[_0x3b6e41('0x159')][_0x3b6e41('0xc9')]({'where':{'id':_0x5c3511[_0x3b6e41('0x13b')]['id']}})[_0x3b6e41('0x158')](handleEntityNotFound(_0xbae0be,null))[_0x3b6e41('0x158')](function(_0x2a58af){const _0x130943=_0x3b6e41;if(_0x2a58af)return _0x38662e=_0x2a58af,_0x2f1619['model']=_['keys'](db['ChatGroup']['rawAttributes']),_0x2f1619[_0x130943('0x126')]=_[_0x130943('0x113')](_0x5c3511['query']),_0x2f1619[_0x130943('0x49')]=_[_0x130943('0xbc')](_0x2f1619[_0x130943('0x1c')],_0x2f1619[_0x130943('0x126')]),_0x2ca144['attributes']=_['intersection'](_0x2f1619[_0x130943('0x1c')],qs[_0x130943('0x3')](_0x5c3511['query']['fields'])),_0x2ca144[_0x130943('0x92')]=_0x2ca144[_0x130943('0x92')][_0x130943('0xab')]?_0x2ca144[_0x130943('0x92')]:_0x2f1619['model'],_0x2ca144[_0x130943('0x11d')]=qs['sort'](_0x5c3511[_0x130943('0x126')]['sort']),_0x2ca144['where']=qs[_0x130943('0x49')](_[_0x130943('0xe1')](_0x5c3511['query'],_0x2f1619[_0x130943('0x49')])),_0x5c3511['query'][_0x130943('0x44')]&&(_0x2ca144['where']=_['merge'](_0x2ca144[_0x130943('0x11e')],{[Op['or']]:_[_0x130943('0x47')](_0x2ca144[_0x130943('0x92')],function(_0x51fc73){const _0x3cfdab=_0x130943,_0x56edca={};return _0x56edca[_0x51fc73]={[Op[_0x3cfdab('0x2b')]]:'%'+_0x5c3511[_0x3cfdab('0x126')][_0x3cfdab('0x44')]+'%'},_0x56edca;})})),_0x2ca144=_[_0x130943('0x72')]({},_0x2ca144,_0x5c3511[_0x130943('0x117')]),_0x38662e[_0x130943('0x13d')](_0x2ca144);})[_0x3b6e41('0x158')](function(_0xd55b2e){const _0x46be7a=_0x3b6e41;if(_0xd55b2e)return _0x516d9b=_0xd55b2e['length'],typeof _0x5c3511['query']['nolimit']===_0x46be7a('0x9c')&&(_0x2ca144[_0x46be7a('0xfa')]=qs[_0x46be7a('0xfa')](_0x5c3511[_0x46be7a('0x126')][_0x46be7a('0xfa')]),_0x2ca144[_0x46be7a('0xfc')]=qs[_0x46be7a('0xfc')](_0x5c3511[_0x46be7a('0x126')]['offset'])),_0x38662e[_0x46be7a('0x13d')](_0x2ca144);})[_0x3b6e41('0x158')](function(_0x4b2b16){if(_0x4b2b16)return _0x4b2b16?{'count':_0x516d9b,'rows':_0x4b2b16}:null;})[_0x3b6e41('0x158')](respondWithResult(_0xbae0be,null))[_0x3b6e41('0x38')](handleError(_0xbae0be,null));},exports[_0x3b43e1('0x12a')]=function(_0x3ff94b,_0x509747){const _0x169dfb=_0x3b43e1;let _0x21706b={'raw':!![],'where':{}};const _0xcbdab1={},_0x1fa320={'count':0x0,'rows':[]};return db['User'][_0x169dfb('0xc9')]({'where':{'id':_0x3ff94b[_0x169dfb('0x13b')]['id']}})[_0x169dfb('0x158')](handleEntityNotFound(_0x509747,null))[_0x169dfb('0x158')](function(_0x42c958){const _0x3b94b7=_0x169dfb;if(_0x42c958)return _0xcbdab1[_0x3b94b7('0x1c')]=_['keys'](db[_0x3b94b7('0x6f')][_0x3b94b7('0x89')]),_0xcbdab1[_0x3b94b7('0x126')]=_[_0x3b94b7('0x113')](_0x3ff94b['query']),_0xcbdab1['filters']=_['intersection'](_0xcbdab1['model'],_0xcbdab1[_0x3b94b7('0x126')]),_0x21706b[_0x3b94b7('0x92')]=_['intersection'](_0xcbdab1[_0x3b94b7('0x1c')],qs[_0x3b94b7('0x3')](_0x3ff94b['query'][_0x3b94b7('0x3')])),_0x21706b[_0x3b94b7('0x92')]=_0x21706b[_0x3b94b7('0x92')][_0x3b94b7('0xab')]?_0x21706b[_0x3b94b7('0x92')]:_0xcbdab1[_0x3b94b7('0x1c')],typeof _0x3ff94b['query'][_0x3b94b7('0x109')]===_0x3b94b7('0x9c')&&(_0x21706b[_0x3b94b7('0xfa')]=qs['limit'](_0x3ff94b[_0x3b94b7('0x126')][_0x3b94b7('0xfa')]),_0x21706b[_0x3b94b7('0xfc')]=qs[_0x3b94b7('0xfc')](_0x3ff94b[_0x3b94b7('0x126')][_0x3b94b7('0xfc')])),_0x21706b[_0x3b94b7('0x11d')]=qs[_0x3b94b7('0x8')](_0x3ff94b[_0x3b94b7('0x126')][_0x3b94b7('0x8')]),_0x21706b[_0x3b94b7('0x11e')]=qs[_0x3b94b7('0x49')](_['pick'](_0x3ff94b[_0x3b94b7('0x126')],_0xcbdab1['filters'])),_0x21706b[_0x3b94b7('0x11e')][_0x3b94b7('0xea')]=_0x42c958['id'],_0x3ff94b[_0x3b94b7('0x126')]['filter']&&(_0x21706b['where']=_['merge'](_0x21706b[_0x3b94b7('0x11e')],{[Op['or']]:_[_0x3b94b7('0x47')](_0x21706b[_0x3b94b7('0x92')],function(_0x36f150){const _0x1e471d=_0x3b94b7,_0x33d89e={};return _0x33d89e[_0x36f150]={[Op[_0x1e471d('0x2b')]]:'%'+_0x3ff94b['query']['filter']+'%'},_0x33d89e;})})),_0x21706b=_[_0x3b94b7('0x72')]({},_0x21706b,_0x3ff94b[_0x3b94b7('0x117')]),db[_0x3b94b7('0x6f')][_0x3b94b7('0x144')]({'where':_0x21706b[_0x3b94b7('0x11e')]})[_0x3b94b7('0x158')](function(_0x295797){const _0x1d1f02=_0x3b94b7;return _0x1fa320['count']=_0x295797,_0x3ff94b['query']['includeAll']&&(_0x21706b[_0x1d1f02('0x48')]=[{'all':!![]}]),db[_0x1d1f02('0x6f')]['findAll'](_0x21706b);})[_0x3b94b7('0x158')](function(_0x294fcf){const _0x2beac2=_0x3b94b7;return _0x1fa320[_0x2beac2('0x154')]=_0x294fcf,_0x1fa320;});})[_0x169dfb('0x158')](respondWithFilteredResult(_0x509747,_0x21706b))[_0x169dfb('0x38')](handleError(_0x509747,null));},exports[_0x3b43e1('0xba')]=function(_0x2761fc,_0x25b2c4){const _0x349fb8=_0x3b43e1;let _0x2737f3={'raw':!![],'where':{}};const _0x4480d4={},_0xa2cf6a={'count':0x0,'rows':[]};return db[_0x349fb8('0x159')][_0x349fb8('0xc9')]({'where':{'id':_0x2761fc[_0x349fb8('0x13b')]['id']}})[_0x349fb8('0x158')](handleEntityNotFound(_0x25b2c4,null))[_0x349fb8('0x158')](function(_0x5346a7){const _0x13e306=_0x349fb8;if(_0x5346a7)return _0x4480d4[_0x13e306('0x1c')]=_[_0x13e306('0x113')](db[_0x13e306('0xd2')][_0x13e306('0x89')]),_0x4480d4[_0x13e306('0x126')]=_['keys'](_0x2761fc[_0x13e306('0x126')]),_0x4480d4[_0x13e306('0x49')]=_[_0x13e306('0xbc')](_0x4480d4[_0x13e306('0x1c')],_0x4480d4[_0x13e306('0x126')]),_0x2737f3[_0x13e306('0x92')]=_['intersection'](_0x4480d4[_0x13e306('0x1c')],qs[_0x13e306('0x3')](_0x2761fc['query']['fields'])),_0x2737f3[_0x13e306('0x92')]=_0x2737f3[_0x13e306('0x92')][_0x13e306('0xab')]?_0x2737f3[_0x13e306('0x92')]:_0x4480d4[_0x13e306('0x1c')],typeof _0x2761fc['query'][_0x13e306('0x109')]===_0x13e306('0x9c')&&(_0x2737f3['limit']=qs[_0x13e306('0xfa')](_0x2761fc[_0x13e306('0x126')][_0x13e306('0xfa')]),_0x2737f3[_0x13e306('0xfc')]=qs['offset'](_0x2761fc[_0x13e306('0x126')][_0x13e306('0xfc')])),_0x2737f3[_0x13e306('0x11d')]=qs[_0x13e306('0x8')](_0x2761fc[_0x13e306('0x126')]['sort']),_0x2737f3['where']=qs['filters'](_[_0x13e306('0xe1')](_0x2761fc[_0x13e306('0x126')],_0x4480d4[_0x13e306('0x49')])),_0x2737f3[_0x13e306('0x11e')][_0x13e306('0xea')]=_0x5346a7['id'],_0x2761fc['query']['filter']&&(_0x2737f3[_0x13e306('0x11e')]=_[_0x13e306('0x72')](_0x2737f3[_0x13e306('0x11e')],{[Op['or']]:_[_0x13e306('0x47')](_0x2737f3[_0x13e306('0x92')],function(_0xfadb8){const _0x48e64a=_0x13e306,_0x29ed71={};return _0x29ed71[_0xfadb8]={[Op[_0x48e64a('0x2b')]]:'%'+_0x2761fc[_0x48e64a('0x126')][_0x48e64a('0x44')]+'%'},_0x29ed71;})})),_0x2737f3=_['merge']({},_0x2737f3,_0x2761fc[_0x13e306('0x117')]),db[_0x13e306('0xd2')][_0x13e306('0x144')]({'where':_0x2737f3[_0x13e306('0x11e')]})[_0x13e306('0x158')](function(_0x5a49c7){const _0x2e4bfd=_0x13e306;return _0xa2cf6a['count']=_0x5a49c7,_0x2761fc[_0x2e4bfd('0x126')][_0x2e4bfd('0x11b')]&&(_0x2737f3['include']=[{'all':!![]}]),db[_0x2e4bfd('0xd2')]['findAll'](_0x2737f3);})['then'](function(_0x4ee871){const _0xd92f88=_0x13e306;return _0xa2cf6a[_0xd92f88('0x154')]=_0x4ee871,_0xa2cf6a;});})[_0x349fb8('0x158')](respondWithFilteredResult(_0x25b2c4,_0x2737f3))['catch'](handleError(_0x25b2c4,null));},exports[_0x3b43e1('0x8d')]=function(_0x354400,_0x32a772){const _0x57b8b4=_0x3b43e1;let _0x3200e7={};const _0x20dec4={};let _0x229291,_0x252c87;return db['User'][_0x57b8b4('0xc9')]({'where':{'id':_0x354400[_0x57b8b4('0x13b')]['id']}})[_0x57b8b4('0x158')](handleEntityNotFound(_0x32a772,null))[_0x57b8b4('0x158')](function(_0x2641af){const _0x38479a=_0x57b8b4;if(_0x2641af)return _0x229291=_0x2641af,_0x20dec4[_0x38479a('0x1c')]=_[_0x38479a('0x113')](db[_0x38479a('0x94')][_0x38479a('0x89')]),_0x20dec4[_0x38479a('0x126')]=_['keys'](_0x354400[_0x38479a('0x126')]),_0x20dec4[_0x38479a('0x49')]=_['intersection'](_0x20dec4['model'],_0x20dec4[_0x38479a('0x126')]),_0x3200e7[_0x38479a('0x92')]=_['intersection'](_0x20dec4['model'],qs[_0x38479a('0x3')](_0x354400['query'][_0x38479a('0x3')])),_0x3200e7['attributes']=_0x3200e7['attributes'][_0x38479a('0xab')]?_0x3200e7['attributes']:_0x20dec4['model'],_0x3200e7[_0x38479a('0x11d')]=qs['sort'](_0x354400['query'][_0x38479a('0x8')]),_0x3200e7[_0x38479a('0x11e')]=qs[_0x38479a('0x49')](_[_0x38479a('0xe1')](_0x354400[_0x38479a('0x126')],_0x20dec4[_0x38479a('0x49')])),_0x354400[_0x38479a('0x126')][_0x38479a('0x44')]&&(_0x3200e7['where']=_[_0x38479a('0x72')](_0x3200e7[_0x38479a('0x11e')],{[Op['or']]:_[_0x38479a('0x47')](_0x3200e7['attributes'],function(_0x54aa4a){const _0x2ff079=_0x38479a,_0x314b67={};return _0x314b67[_0x54aa4a]={[Op[_0x2ff079('0x2b')]]:'%'+_0x354400['query'][_0x2ff079('0x44')]+'%'},_0x314b67;})})),_0x3200e7=_['merge']({},_0x3200e7,_0x354400[_0x38479a('0x117')]),_0x229291[_0x38479a('0x8d')](_0x3200e7);})[_0x57b8b4('0x158')](function(_0x5447c){const _0x559a3d=_0x57b8b4;if(_0x5447c)return _0x252c87=_0x5447c[_0x559a3d('0xab')],typeof _0x354400[_0x559a3d('0x126')]['nolimit']===_0x559a3d('0x9c')&&(_0x3200e7[_0x559a3d('0xfa')]=qs[_0x559a3d('0xfa')](_0x354400[_0x559a3d('0x126')]['limit']),_0x3200e7[_0x559a3d('0xfc')]=qs[_0x559a3d('0xfc')](_0x354400[_0x559a3d('0x126')]['offset'])),_0x229291[_0x559a3d('0x8d')](_0x3200e7);})[_0x57b8b4('0x158')](function(_0x4f018e){if(_0x4f018e)return _0x4f018e?{'count':_0x252c87,'rows':_0x4f018e}:null;})[_0x57b8b4('0x158')](respondWithResult(_0x32a772,null))[_0x57b8b4('0x38')](handleError(_0x32a772,null));},exports[_0x3b43e1('0x11')]=function(_0xc52d10,_0x4c0f57){const _0x32b9c8=_0x3b43e1;let _0x22d8fa={};const _0x5c73c3={};let _0x4f5443,_0xae5733;return db[_0x32b9c8('0x159')][_0x32b9c8('0xc9')]({'where':{'id':_0xc52d10[_0x32b9c8('0x13b')]['id']}})['then'](handleEntityNotFound(_0x4c0f57,null))[_0x32b9c8('0x158')](function(_0x4b85bf){const _0x3120d1=_0x32b9c8;if(_0x4b85bf)return _0x4f5443=_0x4b85bf,_0x5c73c3[_0x3120d1('0x1c')]=_['keys'](db[_0x3120d1('0xc3')][_0x3120d1('0x89')]),_0x5c73c3['query']=_[_0x3120d1('0x113')](_0xc52d10[_0x3120d1('0x126')]),_0x5c73c3['filters']=_['intersection'](_0x5c73c3[_0x3120d1('0x1c')],_0x5c73c3[_0x3120d1('0x126')]),_0x22d8fa[_0x3120d1('0x92')]=_[_0x3120d1('0xbc')](_0x5c73c3[_0x3120d1('0x1c')],qs[_0x3120d1('0x3')](_0xc52d10[_0x3120d1('0x126')][_0x3120d1('0x3')])),_0x22d8fa[_0x3120d1('0x92')]=_0x22d8fa[_0x3120d1('0x92')]['length']?_0x22d8fa[_0x3120d1('0x92')]:_0x5c73c3[_0x3120d1('0x1c')],_0x22d8fa[_0x3120d1('0x11d')]=qs[_0x3120d1('0x8')](_0xc52d10[_0x3120d1('0x126')][_0x3120d1('0x8')]),_0x22d8fa['where']=qs['filters'](_[_0x3120d1('0xe1')](_0xc52d10[_0x3120d1('0x126')],_0x5c73c3[_0x3120d1('0x49')])),_0xc52d10[_0x3120d1('0x126')][_0x3120d1('0x44')]&&(_0x22d8fa[_0x3120d1('0x11e')]=_[_0x3120d1('0x72')](_0x22d8fa[_0x3120d1('0x11e')],{[Op['or']]:_[_0x3120d1('0x47')](_0x22d8fa[_0x3120d1('0x92')],function(_0x540249){const _0xf9a870={};return _0xf9a870[_0x540249]={[Op['like']]:'%'+_0xc52d10['query']['filter']+'%'},_0xf9a870;})})),_0x22d8fa=_[_0x3120d1('0x72')]({},_0x22d8fa,_0xc52d10[_0x3120d1('0x117')]),_0x4f5443[_0x3120d1('0x11')](_0x22d8fa);})['then'](function(_0x3d1459){const _0x15a7e6=_0x32b9c8;if(_0x3d1459)return _0xae5733=_0x3d1459['length'],typeof _0xc52d10[_0x15a7e6('0x126')][_0x15a7e6('0x109')]===_0x15a7e6('0x9c')&&(_0x22d8fa[_0x15a7e6('0xfa')]=qs[_0x15a7e6('0xfa')](_0xc52d10[_0x15a7e6('0x126')][_0x15a7e6('0xfa')]),_0x22d8fa[_0x15a7e6('0xfc')]=qs[_0x15a7e6('0xfc')](_0xc52d10[_0x15a7e6('0x126')]['offset'])),_0x4f5443[_0x15a7e6('0x11')](_0x22d8fa);})['then'](function(_0x6d353d){if(_0x6d353d)return _0x6d353d?{'count':_0xae5733,'rows':_0x6d353d}:null;})[_0x32b9c8('0x158')](respondWithResult(_0x4c0f57,null))['catch'](handleError(_0x4c0f57,null));},exports[_0x3b43e1('0x11f')]=function(_0x628a87,_0x3fd4d8){const _0x1a4bf5=_0x3b43e1;let _0xa33647={'raw':!![],'where':{}};const _0x41c61f={},_0x23f5a9={'count':0x0,'rows':[]};return db[_0x1a4bf5('0x159')][_0x1a4bf5('0xc9')]({'where':{'id':_0x628a87[_0x1a4bf5('0x13b')]['id']}})[_0x1a4bf5('0x158')](handleEntityNotFound(_0x3fd4d8,null))[_0x1a4bf5('0x158')](function(_0x42399c){const _0x583159=_0x1a4bf5;if(_0x42399c)return _0x41c61f[_0x583159('0x1c')]=_['keys'](db[_0x583159('0x73')][_0x583159('0x89')]),_0x41c61f['query']=_['keys'](_0x628a87[_0x583159('0x126')]),_0x41c61f[_0x583159('0x49')]=_[_0x583159('0xbc')](_0x41c61f[_0x583159('0x1c')],_0x41c61f['query']),_0xa33647[_0x583159('0x92')]=_[_0x583159('0xbc')](_0x41c61f[_0x583159('0x1c')],qs[_0x583159('0x3')](_0x628a87[_0x583159('0x126')][_0x583159('0x3')])),_0xa33647['attributes']=_0xa33647[_0x583159('0x92')]['length']?_0xa33647[_0x583159('0x92')]:_0x41c61f[_0x583159('0x1c')],typeof _0x628a87['query'][_0x583159('0x109')]==='undefined'&&(_0xa33647[_0x583159('0xfa')]=qs[_0x583159('0xfa')](_0x628a87[_0x583159('0x126')][_0x583159('0xfa')]),_0xa33647['offset']=qs[_0x583159('0xfc')](_0x628a87[_0x583159('0x126')][_0x583159('0xfc')])),_0xa33647[_0x583159('0x11d')]=qs['sort'](_0x628a87[_0x583159('0x126')][_0x583159('0x8')]),_0xa33647[_0x583159('0x11e')]=qs[_0x583159('0x49')](_[_0x583159('0xe1')](_0x628a87['query'],_0x41c61f[_0x583159('0x49')])),_0xa33647[_0x583159('0x11e')][_0x583159('0xea')]=_0x42399c['id'],_0x628a87['query'][_0x583159('0x44')]&&(_0xa33647[_0x583159('0x11e')]=_[_0x583159('0x72')](_0xa33647[_0x583159('0x11e')],{[Op['or']]:_[_0x583159('0x47')](_0xa33647[_0x583159('0x92')],function(_0x4a2d00){const _0x3b86a5=_0x583159,_0xf5b683={};return _0xf5b683[_0x4a2d00]={[Op[_0x3b86a5('0x2b')]]:'%'+_0x628a87[_0x3b86a5('0x126')][_0x3b86a5('0x44')]+'%'},_0xf5b683;})})),_0xa33647=_['merge']({},_0xa33647,_0x628a87[_0x583159('0x117')]),db[_0x583159('0x73')]['count']({'where':_0xa33647[_0x583159('0x11e')]})['then'](function(_0x5bb751){const _0xb7aee0=_0x583159;return _0x23f5a9[_0xb7aee0('0x144')]=_0x5bb751,_0x628a87[_0xb7aee0('0x126')][_0xb7aee0('0x11b')]&&(_0xa33647['include']=[{'all':!![]}]),db[_0xb7aee0('0x73')][_0xb7aee0('0x128')](_0xa33647);})[_0x583159('0x158')](function(_0x30aaa6){const _0x54837f=_0x583159;return _0x23f5a9[_0x54837f('0x154')]=_0x30aaa6,_0x23f5a9;});})[_0x1a4bf5('0x158')](respondWithFilteredResult(_0x3fd4d8,_0xa33647))[_0x1a4bf5('0x38')](handleError(_0x3fd4d8,null));},exports['getSmsInteractions']=function(_0x1334c8,_0x284b3c){const _0x50c388=_0x3b43e1;let _0x450aab={};const _0x32da17={};let _0x524f13,_0x504b13;return db[_0x50c388('0x159')][_0x50c388('0xc9')]({'where':{'id':_0x1334c8[_0x50c388('0x13b')]['id']}})['then'](handleEntityNotFound(_0x284b3c,null))[_0x50c388('0x158')](function(_0x2f671c){const _0xded77f=_0x50c388;if(_0x2f671c)return _0x524f13=_0x2f671c,_0x32da17['model']=_[_0xded77f('0x113')](db[_0xded77f('0x112')][_0xded77f('0x89')]),_0x32da17[_0xded77f('0x126')]=_[_0xded77f('0x113')](_0x1334c8[_0xded77f('0x126')]),_0x32da17[_0xded77f('0x49')]=_[_0xded77f('0xbc')](_0x32da17[_0xded77f('0x1c')],_0x32da17[_0xded77f('0x126')]),_0x450aab[_0xded77f('0x92')]=_[_0xded77f('0xbc')](_0x32da17[_0xded77f('0x1c')],qs[_0xded77f('0x3')](_0x1334c8[_0xded77f('0x126')][_0xded77f('0x3')])),_0x450aab[_0xded77f('0x92')]=_0x450aab['attributes'][_0xded77f('0xab')]?_0x450aab['attributes']:_0x32da17[_0xded77f('0x1c')],_0x450aab[_0xded77f('0x11d')]=qs['sort'](_0x1334c8[_0xded77f('0x126')]['sort']),_0x450aab[_0xded77f('0x11e')]=qs['filters'](_['pick'](_0x1334c8[_0xded77f('0x126')],_0x32da17[_0xded77f('0x49')])),_0x1334c8[_0xded77f('0x126')][_0xded77f('0x44')]&&(_0x450aab[_0xded77f('0x11e')]=_[_0xded77f('0x72')](_0x450aab[_0xded77f('0x11e')],{[Op['or']]:_[_0xded77f('0x47')](_0x450aab[_0xded77f('0x92')],function(_0x14ec94){const _0x5ded17=_0xded77f,_0x1210c6={};return _0x1210c6[_0x14ec94]={[Op[_0x5ded17('0x2b')]]:'%'+_0x1334c8[_0x5ded17('0x126')][_0x5ded17('0x44')]+'%'},_0x1210c6;})})),_0x450aab=_[_0xded77f('0x72')]({},_0x450aab,_0x1334c8[_0xded77f('0x117')]),_0x524f13['getSmsInteractions'](_0x450aab);})[_0x50c388('0x158')](function(_0x1b9cdd){const _0x462e2c=_0x50c388;if(_0x1b9cdd)return _0x504b13=_0x1b9cdd[_0x462e2c('0xab')],typeof _0x1334c8[_0x462e2c('0x126')][_0x462e2c('0x109')]===_0x462e2c('0x9c')&&(_0x450aab[_0x462e2c('0xfa')]=qs['limit'](_0x1334c8[_0x462e2c('0x126')][_0x462e2c('0xfa')]),_0x450aab[_0x462e2c('0xfc')]=qs[_0x462e2c('0xfc')](_0x1334c8[_0x462e2c('0x126')]['offset'])),_0x524f13[_0x462e2c('0x93')](_0x450aab);})['then'](function(_0x214134){if(_0x214134)return _0x214134?{'count':_0x504b13,'rows':_0x214134}:null;})['then'](respondWithResult(_0x284b3c,null))[_0x50c388('0x38')](handleError(_0x284b3c,null));},exports[_0x3b43e1('0x43')]=function(_0x461f16,_0x20a9f6){const _0x1c8f44=_0x3b43e1;let _0x1fcd49={};const _0x5d64a1={};let _0x1338a7,_0x2a62d3;return db[_0x1c8f44('0x159')][_0x1c8f44('0xc9')]({'where':{'id':_0x461f16['params']['id']}})[_0x1c8f44('0x158')](handleEntityNotFound(_0x20a9f6,null))[_0x1c8f44('0x158')](function(_0x187902){const _0x2d517d=_0x1c8f44;if(_0x187902)return _0x1338a7=_0x187902,_0x5d64a1[_0x2d517d('0x1c')]=_['keys'](db[_0x2d517d('0xb3')]['rawAttributes']),_0x5d64a1[_0x2d517d('0x126')]=_[_0x2d517d('0x113')](_0x461f16['query']),_0x5d64a1['filters']=_[_0x2d517d('0xbc')](_0x5d64a1[_0x2d517d('0x1c')],_0x5d64a1['query']),_0x1fcd49[_0x2d517d('0x92')]=_[_0x2d517d('0xbc')](_0x5d64a1[_0x2d517d('0x1c')],qs[_0x2d517d('0x3')](_0x461f16['query'][_0x2d517d('0x3')])),_0x1fcd49[_0x2d517d('0x92')]=_0x1fcd49['attributes'][_0x2d517d('0xab')]?_0x1fcd49[_0x2d517d('0x92')]:_0x5d64a1[_0x2d517d('0x1c')],_0x1fcd49[_0x2d517d('0x11d')]=qs[_0x2d517d('0x8')](_0x461f16[_0x2d517d('0x126')]['sort']),_0x1fcd49['where']=qs['filters'](_[_0x2d517d('0xe1')](_0x461f16[_0x2d517d('0x126')],_0x5d64a1[_0x2d517d('0x49')])),_0x461f16[_0x2d517d('0x126')]['filter']&&(_0x1fcd49[_0x2d517d('0x11e')]=_[_0x2d517d('0x72')](_0x1fcd49[_0x2d517d('0x11e')],{[Op['or']]:_[_0x2d517d('0x47')](_0x1fcd49[_0x2d517d('0x92')],function(_0x752143){const _0x2f7d93=_0x2d517d,_0x453441={};return _0x453441[_0x752143]={[Op['like']]:'%'+_0x461f16[_0x2f7d93('0x126')][_0x2f7d93('0x44')]+'%'},_0x453441;})})),_0x1fcd49=_[_0x2d517d('0x72')]({},_0x1fcd49,_0x461f16['options']),_0x1338a7['getFaxInteractions'](_0x1fcd49);})[_0x1c8f44('0x158')](function(_0x584e79){const _0x5d2694=_0x1c8f44;if(_0x584e79)return _0x2a62d3=_0x584e79[_0x5d2694('0xab')],typeof _0x461f16[_0x5d2694('0x126')][_0x5d2694('0x109')]===_0x5d2694('0x9c')&&(_0x1fcd49[_0x5d2694('0xfa')]=qs[_0x5d2694('0xfa')](_0x461f16[_0x5d2694('0x126')][_0x5d2694('0xfa')]),_0x1fcd49[_0x5d2694('0xfc')]=qs[_0x5d2694('0xfc')](_0x461f16[_0x5d2694('0x126')][_0x5d2694('0xfc')])),_0x1338a7[_0x5d2694('0x43')](_0x1fcd49);})[_0x1c8f44('0x158')](function(_0xcc859e){if(_0xcc859e)return _0xcc859e?{'count':_0x2a62d3,'rows':_0xcc859e}:null;})[_0x1c8f44('0x158')](respondWithResult(_0x20a9f6,null))[_0x1c8f44('0x38')](handleError(_0x20a9f6,null));},exports['getWhatsappInteractions']=function(_0x422e7a,_0x104101){const _0x46a3c5=_0x3b43e1;let _0x459c57={};const _0x55b4e6={};let _0x2f312d,_0x3590b0;return db[_0x46a3c5('0x159')][_0x46a3c5('0xc9')]({'where':{'id':_0x422e7a[_0x46a3c5('0x13b')]['id']}})['then'](handleEntityNotFound(_0x104101,null))['then'](function(_0x26ad4c){const _0x436998=_0x46a3c5;if(_0x26ad4c)return _0x2f312d=_0x26ad4c,_0x55b4e6[_0x436998('0x1c')]=_[_0x436998('0x113')](db[_0x436998('0xfb')]['rawAttributes']),_0x55b4e6['query']=_[_0x436998('0x113')](_0x422e7a[_0x436998('0x126')]),_0x55b4e6['filters']=_[_0x436998('0xbc')](_0x55b4e6['model'],_0x55b4e6[_0x436998('0x126')]),_0x459c57['attributes']=_[_0x436998('0xbc')](_0x55b4e6[_0x436998('0x1c')],qs[_0x436998('0x3')](_0x422e7a[_0x436998('0x126')][_0x436998('0x3')])),_0x459c57[_0x436998('0x92')]=_0x459c57[_0x436998('0x92')][_0x436998('0xab')]?_0x459c57[_0x436998('0x92')]:_0x55b4e6[_0x436998('0x1c')],_0x459c57[_0x436998('0x11d')]=qs[_0x436998('0x8')](_0x422e7a[_0x436998('0x126')][_0x436998('0x8')]),_0x459c57[_0x436998('0x11e')]=qs['filters'](_['pick'](_0x422e7a['query'],_0x55b4e6[_0x436998('0x49')])),_0x422e7a[_0x436998('0x126')][_0x436998('0x44')]&&(_0x459c57[_0x436998('0x11e')]=_[_0x436998('0x72')](_0x459c57[_0x436998('0x11e')],{[Op['or']]:_[_0x436998('0x47')](_0x459c57[_0x436998('0x92')],function(_0x2930d8){const _0xb4097c=_0x436998,_0x1e37be={};return _0x1e37be[_0x2930d8]={[Op[_0xb4097c('0x2b')]]:'%'+_0x422e7a['query'][_0xb4097c('0x44')]+'%'},_0x1e37be;})})),_0x459c57=_[_0x436998('0x72')]({},_0x459c57,_0x422e7a[_0x436998('0x117')]),_0x2f312d[_0x436998('0x99')](_0x459c57);})['then'](function(_0x2b07f8){const _0x4d1caf=_0x46a3c5;if(_0x2b07f8)return _0x3590b0=_0x2b07f8[_0x4d1caf('0xab')],typeof _0x422e7a[_0x4d1caf('0x126')]['nolimit']===_0x4d1caf('0x9c')&&(_0x459c57[_0x4d1caf('0xfa')]=qs[_0x4d1caf('0xfa')](_0x422e7a[_0x4d1caf('0x126')][_0x4d1caf('0xfa')]),_0x459c57[_0x4d1caf('0xfc')]=qs[_0x4d1caf('0xfc')](_0x422e7a['query'][_0x4d1caf('0xfc')])),_0x2f312d['getWhatsappInteractions'](_0x459c57);})[_0x46a3c5('0x158')](function(_0x1d2fef){if(_0x1d2fef)return _0x1d2fef?{'count':_0x3590b0,'rows':_0x1d2fef}:null;})[_0x46a3c5('0x158')](respondWithResult(_0x104101,null))[_0x46a3c5('0x38')](handleError(_0x104101,null));},exports[_0x3b43e1('0xef')]=function(_0xe2607e,_0x3ac10b,_0x22251){const _0x177a12=_0x3b43e1;let _0x52070a,_0x4de75d,_0xb5ebac;const _0x498353=!_['isNil'](_0xe2607e[_0x177a12('0x13b')]['id'])?_0xe2607e['params']['id']:!_[_0x177a12('0x161')](_0xe2607e['user']['id'])?_0xe2607e[_0x177a12('0xcc')]['id']:null;return db[_0x177a12('0x159')]['findOne']({'where':{'id':_0x498353,'role':{[Op['or']]:[_0x177a12('0x4a'),_0x177a12('0xcc'),_0x177a12('0x25')]}},'attributes':['id',_0x177a12('0xaf'),_0x177a12('0x42'),_0x177a12('0x14c'),_0x177a12('0x85'),_0x177a12('0x150'),'loginInPause']})[_0x177a12('0x158')](function(_0x567079){const _0x58de97=_0x177a12;if(_0x567079){if(_0x567079[_0x58de97('0x85')]===_0x58de97('0x25')){_0x52070a=_0x567079;if(_0xe2607e['body'][_0x58de97('0x14e')])_0xb5ebac=util[_0x58de97('0x6a')](_0x58de97('0x8a'),_0x52070a[_0xe2607e[_0x58de97('0x36')][_0x58de97('0x14e')]]);else _0xe2607e[_0x58de97('0x36')][_0x58de97('0x63')]?_0xb5ebac=util[_0x58de97('0x6a')]('SIP/%s',_0xe2607e[_0x58de97('0x36')][_0x58de97('0x63')]):_0xb5ebac=util[_0x58de97('0x6a')](_0x58de97('0xcf'),_0x52070a[_0x58de97('0xaf')]);return socket['to'](util[_0x58de97('0x6a')](_0x58de97('0x30'),_0x52070a[_0x58de97('0xaf')]))['emit'](_0x58de97('0xbf'),{'ip':_0xe2607e['headers'][_0x58de97('0x13f')]||_0xe2607e[_0x58de97('0x91')][_0x58de97('0x8b')]||_0xe2607e[_0x58de97('0xb6')][_0x58de97('0x8b')]||_0xe2607e['connection'][_0x58de97('0xb6')]['remoteAddress']}),db[_0x58de97('0x5b')][_0x58de97('0x14b')]({'where':{'membername':_0x52070a[_0x58de97('0xaf')]},'individualHooks':!![]});}}else throw new ValidationError(_0x58de97('0xf8'));})[_0x177a12('0x158')](function(){const _0x4ef335=_0x177a12;if(_0x52070a)return _0x52070a[_0x4ef335('0x14a')]({'raw':!![]});})['then'](function(_0x50d13b){const _0xf413f7=_0x177a12;if(_0x52070a){if(_0x50d13b){_0x4de75d=_0x50d13b;if(_0x4de75d[_0xf413f7('0xab')]){const _0x229a17=_0x4de75d['map'](_0x3ae006=>{const _0x30d858=_0xf413f7,_0x460c99={'membername':_0x52070a[_0x30d858('0xaf')],'UserId':_0x52070a['id'],'queue_name':_0x3ae006[_0x30d858('0xaf')],'VoiceQueueId':_0x3ae006['id'],'interface':_0xb5ebac,'paused':_0x52070a['loginInPause']||![],'penalty':_0x3ae006[_0x30d858('0xe9')]||0x0};return db[_0x30d858('0x5b')][_0x30d858('0x9a')](_0x460c99);});return Promise[_0xf413f7('0x10e')](_0x229a17);}}}})[_0x177a12('0x158')](function(){const _0x174489=_0x177a12;if(_0x52070a)return db[_0x174489('0x143')][_0x174489('0x128')]({'where':{'membername':_0x52070a[_0x174489('0xaf')],'exitAt':null}});})[_0x177a12('0x158')](function(_0x4526ee){const _0x5bc759=_0x177a12;if(_0x52070a){const _0x28b4ce=[];return _0x4526ee[_0x5bc759('0x31')](function(_0x4b856b){const _0x1c1344=_0x5bc759;_0x28b4ce['push'](_0x4b856b[_0x1c1344('0xc2')]({'exitAt':moment()[_0x1c1344('0x6a')](_0x1c1344('0x26'))}));}),Promise[_0x5bc759('0x10e')](_0x28b4ce);}})['then'](function(){const _0x1c00f5=_0x177a12;if(_0x52070a){const _0x4b267=[],_0x3d26ca=[],_0x5f14ae=utils[_0x1c00f5('0x53')](),_0x54f873={'membername':_0x52070a[_0x1c00f5('0xaf')],'interface':_0xb5ebac,'enterAt':moment()[_0x1c00f5('0x6a')](_0x1c00f5('0x26')),'role':_0x52070a[_0x1c00f5('0x85')],'internal':_0x52070a[_0x1c00f5('0x150')]};return _0x5f14ae['forEach'](function(_0x23e276){const _0x181c8c=_0x1c00f5;_0x4b267[_0x181c8c('0x137')](_[_0x181c8c('0x72')]({'channel':_0x23e276,'type':_0x181c8c('0x9d'),'data1':_0xe2607e[_0x181c8c('0x36')][_0x181c8c('0x146')],'data2':_0xb5ebac},_0x54f873)),_0x52070a[_0x181c8c('0x78')]&&_0x3d26ca[_0x181c8c('0x137')](_['merge']({'channel':_0x23e276,'type':_0x181c8c('0x136'),'data1':'LOGININPAUSE'},_0x54f873));}),db[_0x1c00f5('0x143')][_0x1c00f5('0x110')](_0x4b267[_0x1c00f5('0x12e')](_0x3d26ca),{'individualHooks':!![]});}})[_0x177a12('0x158')](function(){const _0x18d515=_0x177a12;if(_0x52070a)return _0x52070a[_0x18d515('0xc2')]({'online':!![],'lastLoginAt':moment()[_0x18d515('0x6a')](_0x18d515('0x26')),'voicePause':_0x52070a[_0x18d515('0x78')]||![],'mailPause':_0x52070a['loginInPause']||![],'chatPause':_0x52070a[_0x18d515('0x78')]||![],'faxPause':_0x52070a[_0x18d515('0x78')]||![],'smsPause':_0x52070a[_0x18d515('0x78')]||![],'openchannelPause':_0x52070a['loginInPause']||![],'whatsappPause':_0x52070a['loginInPause']||![],'pauseType':_0x52070a[_0x18d515('0x78')]?'LOGININPAUSE':null,'interface':_0xb5ebac,'lastPauseAt':moment()['format']('YYYY-MM-DD\x20HH:mm:ss')});})[_0x177a12('0x158')](function(_0x3bab6f){const _0x19fb76=_0x177a12;return _0xe2607e[_0x19fb76('0x15e')]?_0x22251():Promise[_0x19fb76('0x15d')](_0x3bab6f)[_0x19fb76('0x158')](respondWithResult(_0x3ac10b,null));})[_0x177a12('0x38')](handleError(_0x3ac10b,null));},exports['logout']=function(_0x245e0a,_0x9ed675){const _0x33187a=_0x3b43e1;let _0x2fdc0b;return db[_0x33187a('0x159')]['findOne']({'where':{'id':_0x245e0a[_0x33187a('0x13b')]['id'],'role':_0x33187a('0x25')},'attributes':['id',_0x33187a('0xaf'),_0x33187a('0x85')]})[_0x33187a('0x158')](handleEntityNotFound(_0x9ed675,null))[_0x33187a('0x158')](function(_0x10dbfc){if(_0x10dbfc)return _0x2fdc0b=_0x10dbfc,db['UserVoiceQueueRt']['destroy']({'where':{'membername':_0x2fdc0b['name']},'individualHooks':!![]});})[_0x33187a('0x158')](function(){const _0x1bb529=_0x33187a;return db[_0x1bb529('0x143')]['findAll']({'where':{'membername':_0x2fdc0b[_0x1bb529('0xaf')],'exitAt':null}});})['then'](function(_0xf636f8){const _0x3f956b=_0x33187a,_0x3e32f4=[];return _0xf636f8['forEach'](function(_0x4899e3){const _0x6033d0=a648_0x8395;_0x3e32f4[_0x6033d0('0x137')](_0x4899e3['update']({'exitAt':moment()[_0x6033d0('0x6a')](_0x6033d0('0x26'))}));}),Promise[_0x3f956b('0x10e')](_0x3e32f4);})[_0x33187a('0x158')](function(){return _0x2fdc0b['update']({'online':![],'lastLoginAt':null,'voicePause':![],'mailPause':![],'chatPause':![],'faxPause':![],'smsPause':![],'openchannelPause':![],'whatsappPause':![],'interface':null});})[_0x33187a('0x158')](respondWithResult(_0x9ed675,null))[_0x33187a('0x38')](handleError(_0x9ed675,null));},exports[_0x3b43e1('0xec')]=function(_0x214465,_0x381ac4){const _0x41cd8c=_0x3b43e1;let _0x4da2fc;return db[_0x41cd8c('0x5b')]['update']({'paused':0x1},{'where':{'UserId':_0x214465['params']['id']},'individualHooks':!![]})[_0x41cd8c('0x158')](function(){const _0x1703c8=_0x41cd8c;return db[_0x1703c8('0x159')][_0x1703c8('0xc9')]({'where':{'id':_0x214465[_0x1703c8('0x13b')]['id'],'role':_0x1703c8('0x25')},'attributes':['id',_0x1703c8('0xaf'),_0x1703c8('0x85'),_0x1703c8('0x150'),_0x1703c8('0x14e')]});})['then'](handleEntityNotFound(_0x381ac4,null))[_0x41cd8c('0x158')](function(_0x591055){const _0x34cb4d=_0x41cd8c;if(_0x591055)return _0x4da2fc=_0x591055,respondWithRpcPromise(_0x34cb4d('0xf1'),_0x34cb4d('0xec'),{'id':_0x4da2fc['id'],'name':_0x4da2fc[_0x34cb4d('0xaf')],'pause':!![]});})[_0x41cd8c('0x158')](function(){const _0x575cc3=_0x41cd8c;if(_0x4da2fc)return db[_0x575cc3('0x143')][_0x575cc3('0x128')]({'where':{'membername':_0x4da2fc[_0x575cc3('0xaf')],'type':_0x575cc3('0x136'),'exitAt':null}});})[_0x41cd8c('0x158')](function(_0x37d12c){const _0x574aa4=_0x41cd8c;if(_0x37d12c['length']){const _0x566cb1=moment()[_0x574aa4('0x6a')](_0x574aa4('0x26'));for(let _0x3434aa=0x0,_0x42d367=_0x37d12c[_0x574aa4('0xab')];_0x3434aa<_0x42d367;_0x3434aa++){_0x37d12c[_0x3434aa][_0x574aa4('0xc2')]({'exitAt':_0x566cb1});}}})['then'](function(){const _0x366b89=_0x41cd8c,_0xbfad8d=[],_0x3159c2=utils[_0x366b89('0x53')]();return _0x3159c2[_0x366b89('0x31')](function(_0x284f94){const _0x14364e=_0x366b89;_0xbfad8d[_0x14364e('0x137')]({'channel':_0x284f94,'membername':_0x4da2fc[_0x14364e('0xaf')],'interface':_[_0x14364e('0x161')](_0x4da2fc[_0x14364e('0x14e')])?util[_0x14364e('0x6a')](_0x14364e('0xcf'),_0x4da2fc[_0x14364e('0xaf')]):_0x4da2fc['interface'],'type':_0x14364e('0x136'),'enterAt':moment()['format'](_0x14364e('0x26')),'data1':_0x214465[_0x14364e('0x36')]['type']||_0x14364e('0xce'),'role':_0x4da2fc['role'],'internal':_0x4da2fc[_0x14364e('0x150')]});}),db[_0x366b89('0x143')][_0x366b89('0x110')](_0xbfad8d,{'individualHooks':!![]});})[_0x41cd8c('0x158')](function(){const _0x567bdc=_0x41cd8c;return _0x4da2fc[_0x567bdc('0xc2')]({'voicePause':!![],'mailPause':!![],'chatPause':!![],'faxPause':!![],'smsPause':!![],'whatsappPause':!![],'openchannelPause':!![],'pauseType':_0x214465['body'][_0x567bdc('0x69')]||_0x567bdc('0xce'),'lastPauseAt':moment()[_0x567bdc('0x6a')](_0x567bdc('0x26'))});})[_0x41cd8c('0x158')](respondWithResult(_0x381ac4,null))[_0x41cd8c('0x38')](handleError(_0x381ac4,null));},exports[_0x3b43e1('0x83')]=function(_0x1c948a,_0x32815f){const _0xf44b9d=_0x3b43e1;let _0x32936e;return db[_0xf44b9d('0x159')][_0xf44b9d('0xc9')]({'where':{'id':_0x1c948a[_0xf44b9d('0x13b')]['id']},'attributes':['id',_0xf44b9d('0xaf'),_0xf44b9d('0x85'),'voicePause','mailPause',_0xf44b9d('0xda'),_0xf44b9d('0x20'),_0xf44b9d('0x156'),_0xf44b9d('0x3a'),'whatsapppause',_0xf44b9d('0xfe'),_0xf44b9d('0x3f')]})['then'](handleEntityNotFound(_0x32815f,null))[_0xf44b9d('0x158')](function(_0x576b79){const _0x360a44=_0xf44b9d;if(_0x576b79){_0x32936e=_0x576b79;if(_0x1c948a[_0x360a44('0x36')][_0x360a44('0x10b')]&&!utils[_0x360a44('0x66')](_0x1c948a[_0x360a44('0x36')][_0x360a44('0x10b')]))throw new ValidationError(_0x360a44('0x133'));switch(_0x1c948a['body'][_0x360a44('0x10b')]){case'voice':return respondWithRpcPromise(_0x360a44('0xf1'),_0x360a44('0x83'),{'id':_0x32936e['id'],'name':_0x32936e['name'],'pause':![]})[_0x360a44('0x158')](function(){const _0x52f662=_0x360a44;return db[_0x52f662('0x5b')][_0x52f662('0xc2')]({'paused':0x0},{'where':{'UserId':_0x32936e['id']},'individualHooks':!![]});})['then'](function(){const _0x4a5a5a=_0x360a44;return db[_0x4a5a5a('0x143')][_0x4a5a5a('0xc9')]({'where':{'channel':_0x1c948a['body'][_0x4a5a5a('0x10b')],'membername':_0x32936e[_0x4a5a5a('0xaf')],'type':_0x4a5a5a('0x136'),'exitAt':null}});})[_0x360a44('0x158')](function(_0x4e621f){const _0xa2274e=_0x360a44;if(_0x4e621f)return _0x4e621f[_0xa2274e('0xc2')]({'exitAt':moment()[_0xa2274e('0x6a')]('YYYY-MM-DD\x20HH:mm:ss'),'data2':_0xa2274e('0x102')},{'individualHooks':!![]});return null;})['then'](function(){return _0x32936e['update']({'voicePause':![]});});case _0x360a44('0x148'):case'chat':case _0x360a44('0x7b'):case _0x360a44('0xff'):case _0x360a44('0x134'):case _0x360a44('0xd0'):return db[_0x360a44('0x143')][_0x360a44('0xc9')]({'where':{'channel':_0x1c948a[_0x360a44('0x36')]['channel'],'membername':_0x32936e[_0x360a44('0xaf')],'type':_0x360a44('0x136'),'exitAt':null}})[_0x360a44('0x158')](function(_0x2a0398){const _0x2e74f9=_0x360a44;if(_0x2a0398)return _0x2a0398[_0x2e74f9('0xc2')]({'exitAt':moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),'data2':_0x2e74f9('0x102')},{'individualHooks':!![]});return null;})['then'](function(){const _0xbbcfd6=_0x360a44,_0x31d2fc={};return _[_0xbbcfd6('0xf0')](_0x31d2fc,util[_0xbbcfd6('0x6a')]('%s%s',_0x1c948a[_0xbbcfd6('0x36')][_0xbbcfd6('0x10b')],_0xbbcfd6('0xdd')),![]),_0x32936e[_0xbbcfd6('0xc2')](_0x31d2fc);});default:return respondWithRpcPromise('QueuePause',_0x360a44('0x83'),{'id':_0x32936e['id'],'name':_0x32936e[_0x360a44('0xaf')],'pause':![]})[_0x360a44('0x158')](function(){const _0x55a7ad=_0x360a44;return db[_0x55a7ad('0x5b')][_0x55a7ad('0xc2')]({'paused':0x0},{'where':{'UserId':_0x32936e['id']}});})[_0x360a44('0x158')](function(){const _0x19c52e=_0x360a44;return db[_0x19c52e('0x143')][_0x19c52e('0x128')]({'where':{'membername':_0x32936e[_0x19c52e('0xaf')],'type':'PAUSE','exitAt':null}});})['then'](function(_0x47b82a){const _0x390d5f=_0x360a44,_0x10c6fb=[];return _0x47b82a['forEach'](function(_0x2090a9){const _0x14a6ed=a648_0x8395;_0x10c6fb[_0x14a6ed('0x137')](_0x2090a9[_0x14a6ed('0xc2')]({'exitAt':moment()[_0x14a6ed('0x6a')](_0x14a6ed('0x26')),'data2':_0x14a6ed('0x102')}));}),Promise[_0x390d5f('0x10e')](_0x10c6fb);})[_0x360a44('0x158')](function(){return _0x32936e['update']({'voicePause':![],'mailPause':![],'chatPause':![],'faxPause':![],'smsPause':![],'whatsappPause':![],'openchannelPause':![]});});}}})['then'](respondWithResult(_0x32815f,null))[_0xf44b9d('0x38')](handleError(_0x32815f,null));},exports[_0x3b43e1('0x138')]=function(_0x33bd9e,_0x254179){const _0x3e24cf=_0x3b43e1;let _0x29cdf9={};const _0x2bc0dd={};let _0x30b430,_0x1fec86;return db[_0x3e24cf('0x159')][_0x3e24cf('0xc9')]({'where':{'id':_0x33bd9e[_0x3e24cf('0x13b')]['id']}})[_0x3e24cf('0x158')](handleEntityNotFound(_0x254179,null))[_0x3e24cf('0x158')](function(_0x86274b){const _0x584471=_0x3e24cf;if(_0x86274b)return _0x30b430=_0x86274b,_0x2bc0dd[_0x584471('0x1c')]=_['keys'](db[_0x584471('0x12d')][_0x584471('0x89')]),_0x2bc0dd[_0x584471('0x126')]=_['keys'](_0x33bd9e[_0x584471('0x126')]),_0x2bc0dd[_0x584471('0x49')]=_[_0x584471('0xbc')](_0x2bc0dd['model'],_0x2bc0dd[_0x584471('0x126')]),_0x29cdf9[_0x584471('0x92')]=_[_0x584471('0xbc')](_0x2bc0dd[_0x584471('0x1c')],qs[_0x584471('0x3')](_0x33bd9e['query'][_0x584471('0x3')])),_0x29cdf9['attributes']=_0x29cdf9[_0x584471('0x92')]['length']?_0x29cdf9[_0x584471('0x92')]:_0x2bc0dd[_0x584471('0x1c')],_0x29cdf9[_0x584471('0x11d')]=qs[_0x584471('0x8')](_0x33bd9e[_0x584471('0x126')][_0x584471('0x8')]),_0x29cdf9[_0x584471('0x11e')]=qs['filters'](_['pick'](_0x33bd9e['query'],_0x2bc0dd[_0x584471('0x49')])),_0x33bd9e[_0x584471('0x126')][_0x584471('0x44')]&&(_0x29cdf9[_0x584471('0x11e')]=_[_0x584471('0x72')](_0x29cdf9['where'],{[Op['or']]:_[_0x584471('0x47')](_0x29cdf9[_0x584471('0x92')],function(_0x4d9f4e){const _0x5de02c=_0x584471,_0x229829={};return _0x229829[_0x4d9f4e]={[Op[_0x5de02c('0x2b')]]:'%'+_0x33bd9e[_0x5de02c('0x126')][_0x5de02c('0x44')]+'%'},_0x229829;})})),_0x29cdf9=_[_0x584471('0x72')]({},_0x29cdf9,_0x33bd9e['options']),_0x30b430[_0x584471('0x138')](_0x29cdf9);})[_0x3e24cf('0x158')](function(_0x495af6){const _0x129ea6=_0x3e24cf;if(_0x495af6)return _0x1fec86=_0x495af6['length'],typeof _0x33bd9e['query']['nolimit']===_0x129ea6('0x9c')&&(_0x29cdf9[_0x129ea6('0xfa')]=qs[_0x129ea6('0xfa')](_0x33bd9e[_0x129ea6('0x126')][_0x129ea6('0xfa')]),_0x29cdf9[_0x129ea6('0xfc')]=qs[_0x129ea6('0xfc')](_0x33bd9e[_0x129ea6('0x126')]['offset'])),_0x30b430['getTeams'](_0x29cdf9);})[_0x3e24cf('0x158')](function(_0x212bca){if(_0x212bca)return _0x212bca?{'count':_0x1fec86,'rows':_0x212bca}:null;})[_0x3e24cf('0x158')](respondWithResult(_0x254179,null))['catch'](handleError(_0x254179,null));},exports[_0x3b43e1('0xa7')]=function(_0x994546,_0x11114c){const _0x3a6c0e=_0x3b43e1;return db['User']['findOne']({'where':{'id':_0x994546[_0x3a6c0e('0x13b')]['id']}})['then'](handleEntityNotFound(_0x11114c,null))[_0x3a6c0e('0x158')](function(_0x9eccb1){const _0x23eb83=_0x3a6c0e;if(_0x9eccb1){const _0x4ac648=_0x9eccb1[_0x23eb83('0x1a')]({'plain':!![]});return _0x9eccb1[_0x23eb83('0xa7')](_0x994546[_0x23eb83('0x36')]['ids'],_[_0x23eb83('0xac')](_0x994546['body'],[_0x23eb83('0x132'),'id'])||{})[_0x23eb83('0x158')](function(){const _0x2e07ba=_0x23eb83;for(let _0x1f7176=0x0;_0x1f7176<_0x994546['body'][_0x2e07ba('0x132')]['length'];_0x1f7176++){let _0x53c129=[];db['Team'][_0x2e07ba('0xc9')]({'where':{'id':_0x994546[_0x2e07ba('0x36')][_0x2e07ba('0x132')][_0x1f7176]}})[_0x2e07ba('0x158')](function(_0x24523f){const _0x38f406=_0x2e07ba;return _0x53c129['push'](_0x24523f['getVoiceQueues']()['then'](function(_0x3c63d7){const _0x3badb5=a648_0x8395;for(let _0x48dd2f=0x0;_0x48dd2f<_0x3c63d7[_0x3badb5('0xab')];_0x48dd2f++){_0x3c63d7[_0x48dd2f][_0x3badb5('0x5d')](_0x3badb5('0x10b'),_0x3badb5('0x21'));}return _0x3c63d7;})),_0x53c129['push'](_0x24523f[_0x38f406('0x15c')]()[_0x38f406('0x158')](function(_0x697e3f){const _0x3e5fa5=_0x38f406;for(let _0x4c95a2=0x0;_0x4c95a2<_0x697e3f[_0x3e5fa5('0xab')];_0x4c95a2++){_0x697e3f[_0x4c95a2]['setDataValue'](_0x3e5fa5('0x10b'),_0x3e5fa5('0xe0'));}return _0x697e3f;})),_0x53c129[_0x38f406('0x137')](_0x24523f['getMailQueues']()['then'](function(_0x4ff579){const _0x530dd2=_0x38f406;for(let _0x444884=0x0;_0x444884<_0x4ff579[_0x530dd2('0xab')];_0x444884++){_0x4ff579[_0x444884]['setDataValue'](_0x530dd2('0x10b'),_0x530dd2('0x52'));}return _0x4ff579;})),_0x53c129['push'](_0x24523f[_0x38f406('0x149')]()[_0x38f406('0x158')](function(_0x30bf4a){const _0x39dfc4=_0x38f406;for(let _0x42a39c=0x0;_0x42a39c<_0x30bf4a[_0x39dfc4('0xab')];_0x42a39c++){_0x30bf4a[_0x42a39c][_0x39dfc4('0x5d')](_0x39dfc4('0x10b'),_0x39dfc4('0x130'));}return _0x30bf4a;})),_0x53c129['push'](_0x24523f[_0x38f406('0x57')]()[_0x38f406('0x158')](function(_0x2efa3e){const _0xdd87c1=_0x38f406;for(let _0x338536=0x0;_0x338536<_0x2efa3e[_0xdd87c1('0xab')];_0x338536++){_0x2efa3e[_0x338536]['setDataValue']('channel',_0xdd87c1('0x123'));}return _0x2efa3e;})),_0x53c129[_0x38f406('0x137')](_0x24523f[_0x38f406('0x1f')]()[_0x38f406('0x158')](function(_0x5f2491){const _0x202d8b=_0x38f406;for(let _0x136c03=0x0;_0x136c03<_0x5f2491[_0x202d8b('0xab')];_0x136c03++){_0x5f2491[_0x136c03][_0x202d8b('0x5d')]('channel',_0x202d8b('0x41'));}return _0x5f2491;})),_0x53c129['push'](_0x24523f['getOpenchannelQueues']()[_0x38f406('0x158')](function(_0x2cfadf){const _0x2124de=_0x38f406;for(let _0x976eeb=0x0;_0x976eeb<_0x2cfadf[_0x2124de('0xab')];_0x976eeb++){_0x2cfadf[_0x976eeb][_0x2124de('0x5d')](_0x2124de('0x10b'),_0x2124de('0xd8'));}return _0x2cfadf;})),Promise[_0x38f406('0x10e')](_0x53c129);})[_0x2e07ba('0x158')](function(_0x4375ca){const _0x39c2ee=_0x2e07ba,_0x59abf6=_['flatten'](_0x4375ca);return _0x53c129=[],db[_0x39c2ee('0x6e')][_0x39c2ee('0x76')](function(_0x50cea0){const _0x493ed9=_0x39c2ee;for(let _0x55a1e7=0x0;_0x55a1e7<_0x59abf6[_0x493ed9('0xab')];_0x55a1e7++){_0x53c129['push'](_0x59abf6[_0x55a1e7][_0x493ed9('0x67')](_0x4ac648['id']),{'transaction':_0x50cea0});}return Promise[_0x493ed9('0x10e')](_0x53c129)[_0x493ed9('0x158')](function(){const _0x260488=_0x493ed9;if(_0x4ac648[_0x260488('0xcd')])return Promise[_0x260488('0x96')](_[_0x260488('0x44')](_0x59abf6,function(_0x4a48de){const _0x22b8eb=_0x260488;return _0x4a48de[_0x22b8eb('0x2e')](_0x22b8eb('0x10b'))==='Voice';}),function(_0x2a93a4){const _0x4b2773=_0x260488;return db['UserVoiceQueueRt'][_0x4b2773('0x9a')]({'membername':_0x4ac648[_0x4b2773('0xaf')],'UserId':_0x4ac648['id'],'queue_name':_0x2a93a4['name'],'VoiceQueueId':_0x2a93a4['id'],'interface':_[_0x4b2773('0x161')](_0x4ac648['interface'])?util[_0x4b2773('0x6a')]('SIP/%s',_0x4ac648[_0x4b2773('0xaf')]):_0x4ac648[_0x4b2773('0x14e')],'paused':_0x4ac648['voicePause']||![],'penalty':_0x4ac648[_0x4b2773('0x84')]},{'transaction':_0x50cea0});});else return;})[_0x493ed9('0x158')](function(){const _0x340e99=_0x493ed9;for(let _0x20a41f=0x0;_0x20a41f<_0x59abf6[_0x340e99('0xab')];_0x20a41f++){const _0x23161f=_0x59abf6[_0x20a41f]['getDataValue']('channel'),_0x5f1668=_0x23161f+_0x340e99('0xf9');socket[_0x340e99('0xd')](_0x340e99('0xcc')+_0x23161f+_0x340e99('0x2f'),{'UserId':_0x4ac648['id'],[_0x5f1668]:_0x59abf6[_0x20a41f]['id']});}});});});}});}})[_0x3a6c0e('0x158')](respondWithStatusCode(_0x11114c,null))['catch'](handleError(_0x11114c,null));},exports['removeTeams']=function(_0x4e4a6f,_0x20645e){const _0x5035f3=_0x3b43e1;return db[_0x5035f3('0x159')][_0x5035f3('0xc9')]({'where':{'id':_0x4e4a6f[_0x5035f3('0x13b')]['id']}})[_0x5035f3('0x158')](handleEntityNotFound(_0x20645e,null))[_0x5035f3('0x158')](function(_0x4fc862){const _0x4fe83b=_0x5035f3;if(_0x4fc862){const _0x3fc82f=_0x4fc862[_0x4fe83b('0x1a')]({'plain':!![]}),_0x3b9b2b=_0x4e4a6f['query'][_0x4fe83b('0x132')];return _0x4fc862[_0x4fe83b('0x1b')](_0x3b9b2b)['then'](function(){const _0x3ba53a=_0x4fe83b;for(let _0x4b0bb1=0x0;_0x4b0bb1<_0x3b9b2b[_0x3ba53a('0xab')];_0x4b0bb1++){let _0x3bdd18=[];db[_0x3ba53a('0x12d')][_0x3ba53a('0xc9')]({'where':{'id':_0x3b9b2b[_0x4b0bb1]}})[_0x3ba53a('0x158')](function(_0x54ed6a){const _0xf982eb=_0x3ba53a;return _0x3bdd18[_0xf982eb('0x137')](_0x54ed6a[_0xf982eb('0x14a')]()[_0xf982eb('0x158')](function(_0x1bd1a){const _0x4a9576=_0xf982eb;for(let _0x169cc7=0x0;_0x169cc7<_0x1bd1a[_0x4a9576('0xab')];_0x169cc7++){_0x1bd1a[_0x169cc7][_0x4a9576('0x5d')](_0x4a9576('0x10b'),'Voice');}return _0x1bd1a;})),_0x3bdd18[_0xf982eb('0x137')](_0x54ed6a['getChatQueues']()['then'](function(_0x2f785f){const _0x1f5084=_0xf982eb;for(let _0x1dd8ed=0x0;_0x1dd8ed<_0x2f785f['length'];_0x1dd8ed++){_0x2f785f[_0x1dd8ed][_0x1f5084('0x5d')](_0x1f5084('0x10b'),_0x1f5084('0xe0'));}return _0x2f785f;})),_0x3bdd18['push'](_0x54ed6a[_0xf982eb('0x90')]()[_0xf982eb('0x158')](function(_0x41944f){const _0x43fba8=_0xf982eb;for(let _0xe902d3=0x0;_0xe902d3<_0x41944f[_0x43fba8('0xab')];_0xe902d3++){_0x41944f[_0xe902d3][_0x43fba8('0x5d')](_0x43fba8('0x10b'),_0x43fba8('0x52'));}return _0x41944f;})),_0x3bdd18[_0xf982eb('0x137')](_0x54ed6a[_0xf982eb('0x149')]()[_0xf982eb('0x158')](function(_0x6de115){const _0x1f9f5f=_0xf982eb;for(let _0x2e799a=0x0;_0x2e799a<_0x6de115[_0x1f9f5f('0xab')];_0x2e799a++){_0x6de115[_0x2e799a]['setDataValue'](_0x1f9f5f('0x10b'),_0x1f9f5f('0x130'));}return _0x6de115;})),_0x3bdd18[_0xf982eb('0x137')](_0x54ed6a[_0xf982eb('0x57')]()['then'](function(_0x1045ef){const _0xd1acb3=_0xf982eb;for(let _0x249a20=0x0;_0x249a20<_0x1045ef[_0xd1acb3('0xab')];_0x249a20++){_0x1045ef[_0x249a20][_0xd1acb3('0x5d')](_0xd1acb3('0x10b'),'Whatsapp');}return _0x1045ef;})),_0x3bdd18[_0xf982eb('0x137')](_0x54ed6a['getFaxQueues']()[_0xf982eb('0x158')](function(_0xcd8ec0){const _0x35242b=_0xf982eb;for(let _0x1e3389=0x0;_0x1e3389<_0xcd8ec0[_0x35242b('0xab')];_0x1e3389++){_0xcd8ec0[_0x1e3389][_0x35242b('0x5d')](_0x35242b('0x10b'),'Fax');}return _0xcd8ec0;})),_0x3bdd18[_0xf982eb('0x137')](_0x54ed6a[_0xf982eb('0x15a')]()[_0xf982eb('0x158')](function(_0x23139c){const _0x332101=_0xf982eb;for(let _0x157d44=0x0;_0x157d44<_0x23139c[_0x332101('0xab')];_0x157d44++){_0x23139c[_0x157d44][_0x332101('0x5d')](_0x332101('0x10b'),_0x332101('0xd8'));}return _0x23139c;})),Promise[_0xf982eb('0x10e')](_0x3bdd18);})['then'](function(_0x40c60e){const _0x5f11f8=_0x3ba53a,_0x48f4fe=_['flatten'](_0x40c60e);return _0x3bdd18=[],db['sequelize'][_0x5f11f8('0x76')](function(_0x19a424){const _0x1fef1f=_0x5f11f8;for(let _0x3a23f7=0x0;_0x3a23f7<_0x48f4fe[_0x1fef1f('0xab')];_0x3a23f7++){_0x3bdd18['push'](_0x48f4fe[_0x3a23f7][_0x1fef1f('0x3e')](_0x3fc82f['id']),{'transaction':_0x19a424});}return Promise[_0x1fef1f('0x10e')](_0x3bdd18)[_0x1fef1f('0x158')](function(){const _0x2dde9f=_0x1fef1f;if(_0x3fc82f[_0x2dde9f('0xcd')])return Promise[_0x2dde9f('0x96')](_[_0x2dde9f('0x44')](_0x48f4fe,function(_0x47b824){const _0x178212=_0x2dde9f;return _0x47b824['getDataValue'](_0x178212('0x10b'))===_0x178212('0x21');}),function(_0x459c70){const _0x7245d8=_0x2dde9f;return db['UserVoiceQueueRt'][_0x7245d8('0x14b')]({'where':{'VoiceQueueId':_0x459c70['id'],'UserId':_0x3fc82f['id']},'transaction':_0x19a424});});else return;})[_0x1fef1f('0x158')](function(){const _0x4422f1=_0x1fef1f;for(let _0x5eb1f7=0x0;_0x5eb1f7<_0x48f4fe[_0x4422f1('0xab')];_0x5eb1f7++){const _0x1443e5=_0x48f4fe[_0x5eb1f7][_0x4422f1('0x2e')]('channel'),_0x42eb14=_0x1443e5+'QueueId';socket[_0x4422f1('0xd')](_0x4422f1('0xcc')+_0x1443e5+_0x4422f1('0x88'),{'UserId':_0x3fc82f['id'],[_0x42eb14]:_0x48f4fe[_0x5eb1f7]['id']});}});});});}});}})[_0x5035f3('0x158')](respondWithStatusCode(_0x20645e,null))['catch'](handleError(_0x20645e,null));},exports['getLists']=function(_0x3013b3,_0x5c119d){const _0x5aeac5=_0x3b43e1;let _0x3dd7bb={};const _0x28ee94={};let _0x1e9007,_0x25ac7a;return db[_0x5aeac5('0x159')][_0x5aeac5('0xc9')]({'where':{'id':_0x3013b3[_0x5aeac5('0x13b')]['id']}})[_0x5aeac5('0x158')](handleEntityNotFound(_0x5c119d,null))[_0x5aeac5('0x158')](function(_0x4a1176){const _0x8faf05=_0x5aeac5;if(_0x4a1176)return _0x1e9007=_0x4a1176,_0x28ee94['model']=_[_0x8faf05('0x113')](db['CmList']['rawAttributes']),_0x28ee94[_0x8faf05('0x126')]=_[_0x8faf05('0x113')](_0x3013b3[_0x8faf05('0x126')]),_0x28ee94[_0x8faf05('0x49')]=_[_0x8faf05('0xbc')](_0x28ee94['model'],_0x28ee94[_0x8faf05('0x126')]),_0x3dd7bb[_0x8faf05('0x92')]=_[_0x8faf05('0xbc')](_0x28ee94[_0x8faf05('0x1c')],qs['fields'](_0x3013b3[_0x8faf05('0x126')][_0x8faf05('0x3')])),_0x3dd7bb['attributes']=_0x3dd7bb['attributes'][_0x8faf05('0xab')]?_0x3dd7bb[_0x8faf05('0x92')]:_0x28ee94['model'],_0x3dd7bb[_0x8faf05('0x11d')]=qs[_0x8faf05('0x8')](_0x3013b3[_0x8faf05('0x126')][_0x8faf05('0x8')]),_0x3dd7bb[_0x8faf05('0x11e')]=qs[_0x8faf05('0x49')](_[_0x8faf05('0xe1')](_0x3013b3['query'],_0x28ee94[_0x8faf05('0x49')])),_0x3013b3[_0x8faf05('0x126')][_0x8faf05('0x44')]&&(_0x3dd7bb[_0x8faf05('0x11e')]=_[_0x8faf05('0x72')](_0x3dd7bb['where'],{[Op['or']]:_['map'](_0x3dd7bb[_0x8faf05('0x92')],function(_0x58ef2f){const _0x25ec25=_0x8faf05,_0xc4502a={};return _0xc4502a[_0x58ef2f]={[Op[_0x25ec25('0x2b')]]:'%'+_0x3013b3[_0x25ec25('0x126')]['filter']+'%'},_0xc4502a;})})),_0x3dd7bb=_['merge']({},_0x3dd7bb,_0x3013b3[_0x8faf05('0x117')]),_0x1e9007[_0x8faf05('0xde')](_0x3dd7bb);})[_0x5aeac5('0x158')](function(_0x46a029){const _0x6db454=_0x5aeac5;if(_0x46a029)return _0x25ac7a=_0x46a029['length'],typeof _0x3013b3[_0x6db454('0x126')][_0x6db454('0x109')]===_0x6db454('0x9c')&&(_0x3dd7bb['limit']=qs[_0x6db454('0xfa')](_0x3013b3['query']['limit']),_0x3dd7bb[_0x6db454('0xfc')]=qs[_0x6db454('0xfc')](_0x3013b3[_0x6db454('0x126')]['offset'])),_0x1e9007[_0x6db454('0xde')](_0x3dd7bb);})[_0x5aeac5('0x158')](function(_0x117068){if(_0x117068)return _0x117068?{'count':_0x25ac7a,'rows':_0x117068}:null;})['then'](respondWithResult(_0x5c119d,null))['catch'](handleError(_0x5c119d,null));},exports[_0x3b43e1('0x97')]=function(_0x27f4e2,_0x4c5620){const _0x26c273=_0x3b43e1;let _0x93848d={};const _0xd4465e={};let _0x2f56ad;return db[_0x26c273('0x159')][_0x26c273('0xc9')]({'where':{'id':_0x27f4e2[_0x26c273('0x13b')]['id']}})[_0x26c273('0x158')](handleEntityNotFound(_0x4c5620,null))[_0x26c273('0x158')](function(_0x4bab30){const _0x3a46c6=_0x26c273;if(_0x4bab30)return _0x2f56ad=_0x4bab30,_0xd4465e['model']=_['keys'](db[_0x3a46c6('0x159')][_0x3a46c6('0x89')]),_0xd4465e[_0x3a46c6('0x126')]=_[_0x3a46c6('0x113')](_0x27f4e2[_0x3a46c6('0x126')]),_0xd4465e[_0x3a46c6('0x49')]=_[_0x3a46c6('0xbc')](_0xd4465e['model'],_0xd4465e[_0x3a46c6('0x126')]),_0x93848d[_0x3a46c6('0x92')]=_[_0x3a46c6('0xbc')](_0xd4465e[_0x3a46c6('0x1c')],qs[_0x3a46c6('0x3')](_0x27f4e2[_0x3a46c6('0x126')][_0x3a46c6('0x3')])),_0x93848d[_0x3a46c6('0x92')]=_0x93848d['attributes'][_0x3a46c6('0xab')]?_0x93848d[_0x3a46c6('0x92')]:_0xd4465e[_0x3a46c6('0x1c')],_0x93848d[_0x3a46c6('0x11d')]=qs[_0x3a46c6('0x8')](_0x27f4e2[_0x3a46c6('0x126')][_0x3a46c6('0x8')]),_0x93848d[_0x3a46c6('0x11e')]=qs[_0x3a46c6('0x49')](_[_0x3a46c6('0xe1')](_0x27f4e2[_0x3a46c6('0x126')],_0xd4465e['filters'])),_0x27f4e2[_0x3a46c6('0x126')]['filter']&&(_0x93848d[_0x3a46c6('0x11e')]=_['merge'](_0x93848d[_0x3a46c6('0x11e')],{[Op['or']]:_[_0x3a46c6('0x47')](_0x93848d[_0x3a46c6('0x92')],function(_0x37c2b1){const _0x5a81b5=_0x3a46c6,_0x25ca5c={};return _0x25ca5c[_0x37c2b1]={[Op[_0x5a81b5('0x2b')]]:'%'+_0x27f4e2[_0x5a81b5('0x126')]['filter']+'%'},_0x25ca5c;})})),_0x93848d[_0x3a46c6('0x1c')]=db[_0x3a46c6('0x159')],_0x93848d['as']=_0x3a46c6('0x106'),_0x93848d=_[_0x3a46c6('0x72')]({},_0x93848d,_0x27f4e2[_0x3a46c6('0x117')]),_0x2f56ad[_0x3a46c6('0x14a')]({'include':[_0x93848d]});})['then'](function(_0xab00d1){const _0x103eff=_0x26c273;if(_0xab00d1){let _0x483d70={};const _0x3fdc74=[];for(let _0x30b8af=0x0;_0x30b8af<_0xab00d1['length'];_0x30b8af+=0x1){for(let _0x48d725=0x0,_0x32dde9;_0x48d725<_0xab00d1[_0x30b8af][_0x103eff('0x106')][_0x103eff('0xab')];_0x48d725+=0x1){_0x32dde9=_0xab00d1[_0x30b8af][_0x103eff('0x106')][_0x48d725][_0x103eff('0x1a')]({'plain':!![]}),_0x483d70[_0x32dde9['id']]=_0x32dde9;}}_0x483d70=_['values'](_0x483d70);for(let _0x5f254c=qs['offset'](_0x27f4e2['query'][_0x103eff('0xfc')]);_0x5f254c<_0x483d70[_0x103eff('0xab')]&&_0x3fdc74[_0x103eff('0xab')]{crypto['randomBytes'](_0x12d8ee,function(_0xd7974c,_0x14a710){const _0x35a291=a650_0x180b;return _0xd7974c&&_0x8831a8(_0xd7974c),_0xf85a79(_0x14a710[_0x35a291('0x12')](_0x35a291('0x2e')));});});},_0x27168a[_0x44fb65('0x43')][_0x44fb65('0x47')]=function(_0x264406,_0x5d22ac){const _0x49746c=_0x44fb65;if(!_0x264406||!this[_0x49746c('0x3a')])return _0x5d22ac?_0x5d22ac(null):null;const _0x31401b=0x2710,_0x5c13ab=0x40,_0x524cb9=Buffer[_0x49746c('0x2b')](this[_0x49746c('0x3a')],_0x49746c('0x2e'));if(!_0x5d22ac)return crypto['pbkdf2Sync'](_0x264406,_0x524cb9,_0x31401b,_0x5c13ab,_0x49746c('0x30'))['toString'](_0x49746c('0x2e'));return crypto['pbkdf2'](_0x264406,_0x524cb9,_0x31401b,_0x5c13ab,'sha1',function(_0x510845,_0x20da89){return _0x510845&&_0x5d22ac(_0x510845),_0x5d22ac(null,_0x20da89['toString']('base64'));});},_0x27168a[_0x44fb65('0x43')][_0x44fb65('0x15')]=async function(){const _0x2146a7=_0x44fb65;if(!this[_0x2146a7('0x2a')])return null;if(!_['isEmpty'](this[_0x2146a7('0x2a')])&&authTypes[_0x2146a7('0x41')](this[_0x2146a7('0x2')])===-0x1)throw new Error('Invalid\x20password');return this[_0x2146a7('0x3a')]=await this[_0x2146a7('0x6')](),new Promise((_0x2135d6,_0x576af2)=>{const _0x23ecd1=_0x2146a7;this[_0x23ecd1('0x47')](this['password'],(_0x5a09c4,_0xa6be90)=>{const _0x42a31f=_0x23ecd1;_0x5a09c4?_0x576af2(_0x5a09c4):(this[_0x42a31f('0x2a')]=_0xa6be90,_0x2135d6());});});},_0x27168a[_0x44fb65('0x43')][_0x44fb65('0x22')]=function(){const _0xc35e8a=_0x44fb65;this[_0xc35e8a('0x29')]=md5(this['name']+_0xc35e8a('0x25')+this[_0xc35e8a('0x2a')]);},_0x27168a;}; \ No newline at end of file +const a650_0x47ae=['CDR(type)=%s','internal','User','utf8','exports','%s%s','Authenticate','_XCALLY_MIXMONITOR_FORMAT=%s','sequelize','priority','extensionMonitor','updatePassword','VoiceExtension','gsm','prefix','record','context','sha1','toString','Hangup','options','pbkdf2','recordingFormat','./user.attributes','define','Set','prototype','bulkCreate','function','md5secret','concat','_XCALLY_MIXMONITOR_UNIQUEID=${UNIQUEID}','name','length','lodash','local','password','CDR(type)=internal','utf8_bin','join','base64','randomBytes','wav','defaults','ChanSpy','Dial','makeSaltAsync','${UNIQUEID}.%s,ab','MixMonitor','crypto','includes','md5','catch','destroy','chanspy','provider','then','system','changed','encryptPassword','Invalid\x20password','authenticate','SIP/%s,,tTxX','push','merge','google','salt','Missing\x20Callback','updateMd5Password','resolve','from-sip','format'];(function(_0x3ff2a2,_0x47aea0){const _0x55177a=function(_0x447f0a){while(--_0x447f0a){_0x3ff2a2['push'](_0x3ff2a2['shift']());}};_0x55177a(++_0x47aea0);}(a650_0x47ae,0x120));const a650_0x5517=function(_0x3ff2a2,_0x47aea0){_0x3ff2a2=_0x3ff2a2-0x0;let _0x55177a=a650_0x47ae[_0x3ff2a2];return _0x55177a;};const _0x5e3c4b=a650_0x5517;'use strict';const _=require(_0x5e3c4b('0x22')),util=require('util'),crypto=require(_0x5e3c4b('0x31')),md5=require(_0x5e3c4b('0x33')),sequelize=require(_0x5e3c4b('0x8')),{Op}=sequelize,attributes=require(_0x5e3c4b('0x17')),addUserApplication=function(_0x447f0a,_0x326e2d){const _0x22c546=_0x5e3c4b,_0x42c35b=[_0x22c546('0x2a'),'WAV',_0x22c546('0xd')],_0x914795={'context':_0x447f0a[_0x22c546('0x10')]||_0x22c546('0x46'),'exten':_0x326e2d,'type':_0x22c546('0x39'),'isApp':![],'UserId':_0x447f0a['id']},_0x531fed=[{'app':_0x22c546('0x19'),'appdata':_0x22c546('0x25')}];_0x447f0a[_0x22c546('0xa')]&&_[_0x22c546('0x32')](_0x42c35b,_0x447f0a[_0x22c546('0xa')])?(_0x531fed[_0x22c546('0x3f')]({'app':_0x22c546('0x19'),'appdata':_0x22c546('0x1f')}),_0x531fed[_0x22c546('0x3f')]({'app':_0x22c546('0x19'),'appdata':util[_0x22c546('0x47')](_0x22c546('0x7'),_0x447f0a[_0x22c546('0xa')])}),_0x531fed[_0x22c546('0x3f')]({'app':_0x22c546('0x2d'),'appdata':util['format']('SIP/%s,,tTxXU(xcally-mixmonitor-context)',_0x447f0a[_0x22c546('0x20')])})):_0x531fed['push']({'app':'Dial','appdata':util[_0x22c546('0x47')](_0x22c546('0x3e'),_0x447f0a['name'])});_0x531fed[_0x22c546('0x3f')]({'app':_0x22c546('0x13')});for(let _0x2ee38e=0x0;_0x2ee38e<_0x531fed['length'];_0x2ee38e++){_0x531fed[_0x2ee38e][_0x22c546('0x9')]=_0x2ee38e+0x1,_0x531fed[_0x2ee38e]=_[_0x22c546('0x2b')](_0x531fed[_0x2ee38e],_0x914795);}return _0x531fed;},addChanSpyApplications=function(_0x2d6757,_0x571f6f,_0x2fc4a9){const _0x5f2e21=_0x5e3c4b,_0x9c8d70={'context':_0x2d6757['context']||_0x5f2e21('0x46'),'type':'system','isApp':![],'UserId':_0x2d6757['id']},_0x112835=[];for(let _0x2800b6=0x0,_0xc23749=0x1;_0x2800b6<_0x2fc4a9[_0x5f2e21('0x21')];_0x2800b6++,_0xc23749=0x1){const _0x6d29f3={'exten':util['format'](_0x5f2e21('0x5'),_0x2fc4a9[_0x2800b6][_0x5f2e21('0xe')],_0x571f6f),'ChanSpyId':_0x2fc4a9[_0x2800b6]['id']};_0x112835[_0x5f2e21('0x3f')](_[_0x5f2e21('0x40')]({'app':_0x5f2e21('0x19'),'appdata':util[_0x5f2e21('0x47')](_0x5f2e21('0x0'),'chanspy'),'priority':_0xc23749++},_0x9c8d70,_0x6d29f3)),_0x2fc4a9[_0x2800b6][_0x5f2e21('0xf')]&&_0x112835['push'](_[_0x5f2e21('0x40')]({'app':_0x5f2e21('0x30'),'appdata':util['format'](_0x5f2e21('0x2f'),_0x2fc4a9[_0x2800b6][_0x5f2e21('0x16')]),'priority':_0xc23749++},_0x9c8d70,_0x6d29f3)),_0x2fc4a9[_0x2800b6]['auth']&&_0x112835[_0x5f2e21('0x3f')](_['merge']({'app':_0x5f2e21('0x6'),'appdata':_0x2fc4a9[_0x2800b6][_0x5f2e21('0x24')],'priority':_0xc23749++},_0x9c8d70,_0x6d29f3)),_0x112835['push'](_[_0x5f2e21('0x40')]({'app':_0x5f2e21('0x2c'),'appdata':util['format']('SIP/%s,%s',_0x2d6757[_0x5f2e21('0x20')],_0x2fc4a9[_0x2800b6]['options']?_0x2fc4a9[_0x2800b6][_0x5f2e21('0x14')][_0x5f2e21('0x27')](''):''),'priority':_0xc23749++},_0x9c8d70,_0x6d29f3)),_0x2fc4a9[_0x2800b6][_0x5f2e21('0xf')]&&_0x112835['push'](_[_0x5f2e21('0x40')]({'app':'StopMixMonitor','priority':_0xc23749++},_0x9c8d70,_0x6d29f3));}return _0x112835;},getChanSpy=function(_0x33c36e,_0x3f65e6){return new Promise(function(_0x1d4938,_0x55c5d3){const _0xea4cc8=a650_0x5517;return _0x33c36e['VoiceChanSpy']['findAll']()[_0xea4cc8('0x38')](function(_0x3bbb45){const _0x1120c9=_0xea4cc8;if(_0x3bbb45){let _0x2cc660=addChanSpyApplications(_0x3f65e6,_0x3f65e6[_0x1120c9('0x1')],_0x3bbb45);return _0x3f65e6[_0x1120c9('0x1')]!=_0x3f65e6[_0x1120c9('0x20')]&&(_0x2cc660=_0x2cc660[_0x1120c9('0x1e')](addChanSpyApplications(_0x3f65e6,_0x3f65e6[_0x1120c9('0x20')],_0x3bbb45))),_0x1d4938(_0x2cc660);}return _0x1d4938([]);})[_0xea4cc8('0x34')](function(_0xf98eaa){_0x55c5d3(_0xf98eaa);});});},authTypes=[_0x5e3c4b('0x41'),_0x5e3c4b('0x23')];module[_0x5e3c4b('0x4')]=function(_0x473452){const _0x3aee57=_0x5e3c4b,_0x1a4463=_0x473452['models'],_0x34f44d=_0x473452[_0x3aee57('0x18')](_0x3aee57('0x2'),attributes,{'tableName':'users','paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeCreate':function(_0x51a80d){return _0x51a80d['updateMd5Password'](),_0x51a80d['updatePassword']();},'beforeUpdate':function(_0x533f4f){const _0x4507a0=_0x3aee57;return _0x533f4f[_0x4507a0('0x3a')]('password')?(_0x533f4f[_0x4507a0('0x44')](),_0x533f4f[_0x4507a0('0xb')]()):Promise[_0x4507a0('0x45')]();},'afterCreate':function(_0x55119b){const _0x5cf562=_0x3aee57;let _0x14213e=addUserApplication(_0x55119b,_0x55119b[_0x5cf562('0x1')]);return _0x55119b[_0x5cf562('0x1')]!=_0x55119b[_0x5cf562('0x20')]&&(_0x14213e=_0x14213e[_0x5cf562('0x1e')](addUserApplication(_0x55119b,_0x55119b[_0x5cf562('0x20')]))),_0x1a4463[_0x5cf562('0xc')][_0x5cf562('0x1b')](_0x14213e)[_0x5cf562('0x38')](function(){const _0x398876=_0x5cf562;if(_0x55119b[_0x398876('0x36')])return getChanSpy(_0x1a4463,_0x55119b);})['then'](function(_0x26037f){const _0x1e6772=_0x5cf562;return _0x26037f&&_0x26037f[_0x1e6772('0x21')]?_0x1a4463[_0x1e6772('0xc')][_0x1e6772('0x1b')](_0x26037f):null;})[_0x5cf562('0x34')](function(_0x3fac5b){return _0x3fac5b;});},'afterUpdate':function(_0x4873c0){const _0xbc2625=_0x3aee57;return Promise[_0xbc2625('0x45')]()['then'](function(){const _0x3d8583=_0xbc2625;if(_0x4873c0['changed']('chanspy')||_0x4873c0[_0x3d8583('0x3a')](_0x3d8583('0x10')))return _0x1a4463[_0x3d8583('0xc')][_0x3d8583('0x35')]({'where':{'UserId':_0x4873c0['id'],'type':_0x3d8583('0x39'),'ChanSpyId':{[Op['ne']]:null}}})['then'](function(){const _0x2eb794=_0x3d8583;if(_0x4873c0['chanspy'])return getChanSpy(_0x1a4463,_0x4873c0)[_0x2eb794('0x38')](function(_0x2cccbc){const _0x5261b2=_0x2eb794;if(_0x2cccbc&&_0x2cccbc[_0x5261b2('0x21')])return _0x1a4463['VoiceExtension'][_0x5261b2('0x1b')](_0x2cccbc);});});})[_0xbc2625('0x38')](function(){const _0x4f3d67=_0xbc2625;return _0x4873c0[_0x4f3d67('0x3a')](_0x4f3d67('0xa'))||_0x4873c0[_0x4f3d67('0x3a')](_0x4f3d67('0x10'))?_0x1a4463[_0x4f3d67('0xc')][_0x4f3d67('0x35')]({'where':{'UserId':_0x4873c0['id'],'type':_0x4f3d67('0x39'),'ChanSpyId':null}})[_0x4f3d67('0x38')](function(){const _0x52068a=_0x4f3d67;let _0x2938d0=addUserApplication(_0x4873c0,_0x4873c0[_0x52068a('0x1')]);return _0x4873c0['internal']!=_0x4873c0[_0x52068a('0x20')]&&(_0x2938d0=_0x2938d0['concat'](addUserApplication(_0x4873c0,_0x4873c0[_0x52068a('0x20')]))),_0x1a4463[_0x52068a('0xc')][_0x52068a('0x1b')](_0x2938d0);}):null;})[_0xbc2625('0x34')](function(_0x536b70){return _0x536b70;});},'afterDestroy':function(_0x1286ac){const _0x4dbdf4=_0x3aee57;return _0x1a4463[_0x4dbdf4('0xc')]['destroy']({'where':{'UserId':_0x1286ac['id'],'type':_0x4dbdf4('0x39')}});}},'charset':_0x3aee57('0x3'),'collate':_0x3aee57('0x26')});return _0x34f44d[_0x3aee57('0x1a')][_0x3aee57('0x3d')]=function(_0x1e0ffd,_0x42e4d6){const _0x14d048=_0x3aee57;if(!_0x42e4d6)return this['password']===this[_0x14d048('0x3b')](_0x1e0ffd);const _0x12b71f=this;this['encryptPassword'](_0x1e0ffd,function(_0xb2e28e,_0x48a4d1){const _0x280d5f=_0x14d048;_0xb2e28e&&_0x42e4d6(_0xb2e28e),_0x12b71f[_0x280d5f('0x24')]===_0x48a4d1?_0x42e4d6(null,!![]):_0x42e4d6(null,![]);});},_0x34f44d[_0x3aee57('0x1a')]['makeSalt']=function(_0x12c93c,_0x183b68){const _0x19fa40=_0x3aee57,_0x574271=0x10;if(typeof arguments[0x0]===_0x19fa40('0x1c'))_0x183b68=arguments[0x0],_0x12c93c=_0x574271;else{if(typeof arguments[0x1]==='function')_0x183b68=arguments[0x1];else throw new Error(_0x19fa40('0x43'));}return!_0x12c93c&&(_0x12c93c=_0x574271),crypto[_0x19fa40('0x29')](_0x12c93c,function(_0x12df09,_0x3744a9){const _0x2ed5d2=_0x19fa40;return _0x12df09&&_0x183b68(_0x12df09),_0x183b68(null,_0x3744a9[_0x2ed5d2('0x12')](_0x2ed5d2('0x28')));});},_0x34f44d['prototype'][_0x3aee57('0x2e')]=async function(_0x181dbe=0x10){return new Promise((_0x344c91,_0x567dcd)=>{const _0x24fadc=a650_0x5517;crypto[_0x24fadc('0x29')](_0x181dbe,function(_0x2dfade,_0x569226){const _0x2aa55a=_0x24fadc;return _0x2dfade&&_0x567dcd(_0x2dfade),_0x344c91(_0x569226[_0x2aa55a('0x12')](_0x2aa55a('0x28')));});});},_0x34f44d[_0x3aee57('0x1a')][_0x3aee57('0x3b')]=function(_0x1c14d2,_0x5a98b3){const _0x3126ff=_0x3aee57;if(!_0x1c14d2||!this[_0x3126ff('0x42')])return _0x5a98b3?_0x5a98b3(null):null;const _0xe540ec=0x2710,_0x130c0f=0x40,_0xca264c=Buffer['from'](this[_0x3126ff('0x42')],_0x3126ff('0x28'));if(!_0x5a98b3)return crypto['pbkdf2Sync'](_0x1c14d2,_0xca264c,_0xe540ec,_0x130c0f,_0x3126ff('0x11'))[_0x3126ff('0x12')](_0x3126ff('0x28'));return crypto[_0x3126ff('0x15')](_0x1c14d2,_0xca264c,_0xe540ec,_0x130c0f,_0x3126ff('0x11'),function(_0x50a703,_0x7d6b26){const _0x30f85d=_0x3126ff;return _0x50a703&&_0x5a98b3(_0x50a703),_0x5a98b3(null,_0x7d6b26[_0x30f85d('0x12')](_0x30f85d('0x28')));});},_0x34f44d[_0x3aee57('0x1a')][_0x3aee57('0xb')]=async function(){const _0x50b752=_0x3aee57;if(!this[_0x50b752('0x24')])return null;if(!_['isEmpty'](this[_0x50b752('0x24')])&&authTypes['indexOf'](this[_0x50b752('0x37')])===-0x1)throw new Error(_0x50b752('0x3c'));return this[_0x50b752('0x42')]=await this[_0x50b752('0x2e')](),new Promise((_0x1796dd,_0x166533)=>{const _0x32f537=_0x50b752;this[_0x32f537('0x3b')](this[_0x32f537('0x24')],(_0x12656b,_0x5e3ab8)=>{const _0x272840=_0x32f537;_0x12656b?_0x166533(_0x12656b):(this[_0x272840('0x24')]=_0x5e3ab8,_0x1796dd());});});},_0x34f44d[_0x3aee57('0x1a')]['updateMd5Password']=function(){const _0x162db5=_0x3aee57;this[_0x162db5('0x1d')]=md5(this[_0x162db5('0x20')]+':asterisk:'+this['password']);},_0x34f44d;}; \ No newline at end of file diff --git a/server/api/user/user.rpc.js b/server/api/user/user.rpc.js index 57362c2..8544e7f 100644 --- a/server/api/user/user.rpc.js +++ b/server/api/user/user.rpc.js @@ -1 +1 @@ -const a651_0x1e91=['info','mail','../../config/utils','options','forEach','isValidChannel','findAll','getVoiceQueues','set','UserVoiceQueueRt','push','Maximum\x20login\x20has\x20been\x20reached','SIP/%s','register','loginInPause','map','findOne','merge','YYYY-MM-DD\x20HH:mm:ss','catch','system','raw','voice','moment','error','util','count','Unknown\x20channel','User','body','update','format','fax','attributes','role','openchannel','all','%s%s','LOGININPAUSE','UnpauseUser','LOGIN','LogoutUser','limit','name','rpc','PauseUser','MemberReport','include','agent','sequelize','callysquare','message','PAUSE','isNil','sms','model','../../rediscache','bulkCreate','./user.socket','type','destroy','interface','ShowUser','GetUser','length','where','stringify','LoginUser','getChannels','debug','upsert','DEFAULT\x20PAUSE','channel','agents','then','../../mysqldb','lodash','concat','internal','Pause'];(function(_0x30250d,_0x1e91a2){const _0x2b90e6=function(_0x35bd5e){while(--_0x35bd5e){_0x30250d['push'](_0x30250d['shift']());}};_0x2b90e6(++_0x1e91a2);}(a651_0x1e91,0xd4));const a651_0x2b90=function(_0x30250d,_0x1e91a2){_0x30250d=_0x30250d-0x0;let _0x2b90e6=a651_0x1e91[_0x30250d];return _0x2b90e6;};const _0x595379=a651_0x2b90;'use strict';const _=require(_0x595379('0x18')),util=require(_0x595379('0x35')),db=require(_0x595379('0x17'))['db'],logger=require('../../config/logger')(_0x595379('0x48')),moment=require(_0x595379('0x33')),utils=require(_0x595379('0x1e')),{getSocket}=require(_0x595379('0x4')),socket=getSocket(),sequelize=require(_0x595379('0x4d')),{Op}=sequelize;require(_0x595379('0x6'))[_0x595379('0x29')](socket),exports['GetUser']=function(_0x35bd5e){const _0x1a7ad8=this;return new Promise(function(_0x35ccc6,_0x4a7eca){const _0x1441f6=a651_0x2b90;return db[_0x1441f6('0x38')][_0x1441f6('0x22')]({'raw':_0x35bd5e[_0x1441f6('0x1f')]?_0x35bd5e['options'][_0x1441f6('0x31')]===undefined?!![]:![]:!![],'where':_0x35bd5e[_0x1441f6('0x1f')]?_0x35bd5e[_0x1441f6('0x1f')]['where']||null:null,'attributes':_0x35bd5e[_0x1441f6('0x1f')]?_0x35bd5e[_0x1441f6('0x1f')][_0x1441f6('0x3d')]||null:null,'limit':_0x35bd5e[_0x1441f6('0x1f')]?_0x35bd5e[_0x1441f6('0x1f')][_0x1441f6('0x46')]||null:null,'include':_0x35bd5e[_0x1441f6('0x1f')]?_0x35bd5e[_0x1441f6('0x1f')]['include']?_[_0x1441f6('0x2b')](_0x35bd5e[_0x1441f6('0x1f')][_0x1441f6('0x4b')],function(_0x385ad5){const _0x267537=_0x1441f6;return{'model':db[_0x385ad5[_0x267537('0x3')]],'as':_0x385ad5['as'],'attributes':_0x385ad5['attributes'],'include':_0x385ad5[_0x267537('0x4b')]?_[_0x267537('0x2b')](_0x385ad5[_0x267537('0x4b')],function(_0x1dcc59){const _0x1016b4=_0x267537;return{'model':db[_0x1dcc59[_0x1016b4('0x3')]],'as':_0x1dcc59['as'],'attributes':_0x1dcc59[_0x1016b4('0x3d')],'include':_0x1dcc59[_0x1016b4('0x4b')]?_['map'](_0x1dcc59[_0x1016b4('0x4b')],function(_0x37826d){const _0x4cb15f=_0x1016b4;return{'model':db[_0x37826d[_0x4cb15f('0x3')]],'as':_0x37826d['as'],'attributes':_0x37826d[_0x4cb15f('0x3d')]};}):[]};}):[]};}):[]:[]})[_0x1441f6('0x16')](function(_0x1fb6b4){const _0x381647=_0x1441f6;logger[_0x381647('0x1c')](_0x381647('0xb'),_0x35bd5e),logger[_0x381647('0x11')](_0x381647('0xb'),_0x35bd5e,JSON[_0x381647('0xe')](_0x1fb6b4)),_0x35ccc6(_0x1fb6b4);})[_0x1441f6('0x2f')](function(_0x5eb575){const _0x3a45d5=_0x1441f6;logger[_0x3a45d5('0x34')](_0x3a45d5('0xb'),_0x5eb575[_0x3a45d5('0x4f')],_0x35bd5e),_0x4a7eca(_0x1a7ad8[_0x3a45d5('0x34')](0x1f4,_0x5eb575['message']));});});},exports[_0x595379('0xa')]=function(_0x4761a7){const _0x347a5d=this;return new Promise(function(_0x333af9,_0x4d54e5){const _0x5dbe0c=a651_0x2b90;return db[_0x5dbe0c('0x38')][_0x5dbe0c('0x2c')]({'raw':_0x4761a7[_0x5dbe0c('0x1f')]?_0x4761a7[_0x5dbe0c('0x1f')]['raw']===undefined?!![]:![]:!![],'where':_0x4761a7[_0x5dbe0c('0x1f')]?_0x4761a7[_0x5dbe0c('0x1f')][_0x5dbe0c('0xd')]||null:null,'attributes':_0x4761a7[_0x5dbe0c('0x1f')]?_0x4761a7[_0x5dbe0c('0x1f')][_0x5dbe0c('0x3d')]||null:null,'include':_0x4761a7[_0x5dbe0c('0x1f')]?_0x4761a7[_0x5dbe0c('0x1f')][_0x5dbe0c('0x4b')]?_[_0x5dbe0c('0x2b')](_0x4761a7['options']['include'],function(_0x3d31fb){const _0x3e5a5c=_0x5dbe0c;return{'model':db[_0x3d31fb[_0x3e5a5c('0x3')]],'as':_0x3d31fb['as'],'attributes':_0x3d31fb[_0x3e5a5c('0x3d')],'include':_0x3d31fb[_0x3e5a5c('0x4b')]?_['map'](_0x3d31fb[_0x3e5a5c('0x4b')],function(_0x198d2c){const _0x21e3b9=_0x3e5a5c;return{'model':db[_0x198d2c[_0x21e3b9('0x3')]],'as':_0x198d2c['as'],'attributes':_0x198d2c['attributes'],'include':_0x198d2c[_0x21e3b9('0x4b')]?_['map'](_0x198d2c[_0x21e3b9('0x4b')],function(_0x26ad8d){const _0x7fd149=_0x21e3b9;return{'model':db[_0x26ad8d['model']],'as':_0x26ad8d['as'],'attributes':_0x26ad8d[_0x7fd149('0x3d')]};}):[]};}):[]};}):[]:[]})[_0x5dbe0c('0x16')](function(_0x3cbadb){const _0x59a4b5=_0x5dbe0c;logger[_0x59a4b5('0x1c')](_0x59a4b5('0xa'),_0x4761a7),logger['debug'](_0x59a4b5('0xa'),_0x4761a7,JSON[_0x59a4b5('0xe')](_0x3cbadb)),_0x333af9(_0x3cbadb);})[_0x5dbe0c('0x2f')](function(_0x491e64){const _0x1bbc7a=_0x5dbe0c;logger[_0x1bbc7a('0x34')]('ShowUser',_0x491e64[_0x1bbc7a('0x4f')],_0x4761a7),_0x4d54e5(_0x347a5d[_0x1bbc7a('0x34')](0x1f4,_0x491e64[_0x1bbc7a('0x4f')]));});});},exports[_0x595379('0x49')]=function(_0x697e2f){const _0x2443ef=this;return new Promise(function(_0xdec225,_0x445bdb){const _0x21fe20=a651_0x2b90;let _0x3a7b2b;return db[_0x21fe20('0x38')][_0x21fe20('0x2c')]({'where':_0x697e2f[_0x21fe20('0x1f')][_0x21fe20('0xd')]||{},'attributes':['id','name',_0x21fe20('0x3e'),_0x21fe20('0x1a'),'interface']})[_0x21fe20('0x16')](function(_0x4eab3f){const _0x1e126e=_0x21fe20;if(_0x4eab3f)return _0x3a7b2b=_0x4eab3f,db[_0x1e126e('0x25')][_0x1e126e('0x3a')]({'paused':0x1},{'where':{'UserId':_0x3a7b2b['id']},'individualHooks':!![]});})[_0x21fe20('0x16')](function(){const _0x36ec33=_0x21fe20;if(_0x3a7b2b)return db['MemberReport'][_0x36ec33('0x22')]({'where':{'membername':_0x3a7b2b[_0x36ec33('0x47')],'type':'PAUSE','exitAt':null}});})[_0x21fe20('0x16')](function(_0x313171){const _0x10daea=_0x21fe20;if(_0x3a7b2b){if(_0x313171&&_0x313171[_0x10daea('0xc')]){const _0x3867bd=moment()['format'](_0x10daea('0x2e'));for(let _0x3e658e=0x0,_0x17f92a=_0x313171[_0x10daea('0xc')];_0x3e658e<_0x17f92a;_0x3e658e++){_0x313171[_0x3e658e][_0x10daea('0x3a')]({'exitAt':_0x3867bd});}}}})[_0x21fe20('0x16')](function(){const _0x2f1e1a=_0x21fe20;if(_0x3a7b2b){const _0x4cfcc0=[],_0x8e2592=utils[_0x2f1e1a('0x10')]();return _0x8e2592['forEach'](function(_0x4668b2){const _0x4b9e01=_0x2f1e1a;_0x4cfcc0[_0x4b9e01('0x26')]({'channel':_0x4668b2,'membername':_0x3a7b2b['name'],'interface':_[_0x4b9e01('0x1')](_0x3a7b2b[_0x4b9e01('0x9')])?util[_0x4b9e01('0x3b')](_0x4b9e01('0x28'),_0x3a7b2b['name']):_0x3a7b2b[_0x4b9e01('0x9')],'type':'PAUSE','enterAt':moment()[_0x4b9e01('0x3b')]('YYYY-MM-DD\x20HH:mm:ss'),'data1':_0x697e2f['body']['type']||_0x4b9e01('0x13'),'role':_0x3a7b2b[_0x4b9e01('0x3e')],'internal':_0x3a7b2b[_0x4b9e01('0x1a')],'uniqueid':_0x697e2f[_0x4b9e01('0x39')]['uniqueid']||null});}),db[_0x2f1e1a('0x4a')][_0x2f1e1a('0x5')](_0x4cfcc0,{'individualHooks':!![]});}})[_0x21fe20('0x16')](function(){const _0x32e5dd=_0x21fe20;if(_0x3a7b2b)return _0x3a7b2b[_0x32e5dd('0x3a')]({'voicePause':!![],'mailPause':!![],'chatPause':!![],'faxPause':!![],'smsPause':!![],'openchannelPause':!![],'pauseType':_0x697e2f[_0x32e5dd('0x39')][_0x32e5dd('0x7')]||_0x32e5dd('0x13'),'lastPauseAt':moment()[_0x32e5dd('0x3b')]('YYYY-MM-DD\x20HH:mm:ss')});})['then'](function(_0x3a1e31){_0xdec225(_0x3a1e31);})['catch'](function(_0x5390ec){const _0x22076f=_0x21fe20;_0x445bdb(_0x2443ef[_0x22076f('0x34')](0x1f4,_0x5390ec[_0x22076f('0x4f')]));});});},exports[_0x595379('0x43')]=function(_0x504a21){const _0x39c132=this;return new Promise(function(_0x3c01d6,_0x358a36){const _0x347bfe=a651_0x2b90;let _0x155b32;return db[_0x347bfe('0x38')]['findOne']({'where':_0x504a21[_0x347bfe('0x1f')][_0x347bfe('0xd')]||{},'attributes':['id',_0x347bfe('0x47')]})[_0x347bfe('0x16')](function(_0x30c5a1){const _0x48c99e=_0x347bfe;if(_0x30c5a1){_0x155b32=_0x30c5a1;if(_0x504a21['body']['channel']&&!utils[_0x48c99e('0x21')](_0x504a21[_0x48c99e('0x39')][_0x48c99e('0x14')]))throw new Error(_0x48c99e('0x37'));switch(_0x504a21[_0x48c99e('0x39')][_0x48c99e('0x14')]){case _0x48c99e('0x32'):return db[_0x48c99e('0x25')][_0x48c99e('0x3a')]({'paused':0x0},{'where':{'UserId':_0x155b32['id']}})[_0x48c99e('0x16')](function(){const _0x551b4b=_0x48c99e;return db['MemberReport'][_0x551b4b('0x2c')]({'where':{'channel':_0x504a21[_0x551b4b('0x39')][_0x551b4b('0x14')],'membername':_0x155b32['name'],'type':_0x551b4b('0x0'),'exitAt':null}});})['then'](function(_0x1b5b3a){const _0x3eda9b=_0x48c99e;if(_0x1b5b3a)return _0x1b5b3a[_0x3eda9b('0x3a')]({'exitAt':moment()[_0x3eda9b('0x3b')](_0x3eda9b('0x2e')),'data2':_0x3eda9b('0x30')},{'individualHooks':!![]});return null;})[_0x48c99e('0x16')](function(){return _0x155b32['update']({'voicePause':![]});});case _0x48c99e('0x1d'):case'chat':case _0x48c99e('0x3c'):case _0x48c99e('0x2'):case _0x48c99e('0x3f'):return db[_0x48c99e('0x4a')][_0x48c99e('0x2c')]({'where':{'channel':_0x504a21['body'][_0x48c99e('0x14')],'membername':_0x155b32[_0x48c99e('0x47')],'type':_0x48c99e('0x0'),'exitAt':null}})[_0x48c99e('0x16')](function(_0x4f41bf){const _0x205fb2=_0x48c99e;return _0x4f41bf[_0x205fb2('0x3a')]({'exitAt':moment()[_0x205fb2('0x3b')](_0x205fb2('0x2e')),'data2':_0x205fb2('0x30')},{'individualHooks':!![]});})['then'](function(){const _0x41f65e=_0x48c99e,_0x53b518={};return _[_0x41f65e('0x24')](_0x53b518,util['format'](_0x41f65e('0x41'),_0x504a21[_0x41f65e('0x39')][_0x41f65e('0x14')],_0x41f65e('0x1b')),![]),_0x155b32['update'](_0x53b518);});default:return db[_0x48c99e('0x25')][_0x48c99e('0x3a')]({'paused':0x0},{'where':{'UserId':_0x155b32['id']}})[_0x48c99e('0x16')](function(){const _0x3ba968=_0x48c99e;return db[_0x3ba968('0x4a')]['findAll']({'where':{'membername':_0x155b32['name'],'type':_0x3ba968('0x0'),'exitAt':null}});})['then'](function(_0x2329ba){const _0x4ad648=_0x48c99e,_0x9e7ab3=[];return _0x2329ba[_0x4ad648('0x20')](function(_0x5413b2){const _0x1819da=_0x4ad648;_0x9e7ab3[_0x1819da('0x26')](_0x5413b2[_0x1819da('0x3a')]({'exitAt':moment()[_0x1819da('0x3b')](_0x1819da('0x2e')),'data2':_0x1819da('0x30')}));}),Promise[_0x4ad648('0x40')](_0x9e7ab3);})[_0x48c99e('0x16')](function(){return _0x155b32['update']({'voicePause':![],'mailPause':![],'chatPause':![],'faxPause':![],'smsPause':![],'openchannelPause':![]});});}}})[_0x347bfe('0x16')](function(_0x54ba6a){_0x3c01d6(_0x54ba6a);})['catch'](function(_0xe77699){const _0x551015=_0x347bfe;_0x358a36(_0x39c132[_0x551015('0x34')](0x1f4,_0xe77699[_0x551015('0x4f')]));});});},exports[_0x595379('0x45')]=function(_0x4da8f9){const _0x34be9f=this;return new Promise(function(_0xb18667,_0xe6bf63){const _0x1be3e4=a651_0x2b90;let _0x5377d6;return db['User']['findOne']({'where':_0x4da8f9[_0x1be3e4('0x1f')][_0x1be3e4('0xd')]||{},'attributes':['id',_0x1be3e4('0x47')]})['then'](function(_0x5ba98a){const _0x3d6dcc=_0x1be3e4;if(_0x5ba98a)return _0x5377d6=_0x5ba98a,db['UserVoiceQueueRt'][_0x3d6dcc('0x8')]({'where':{'membername':_0x5377d6[_0x3d6dcc('0x47')]},'individualHooks':!![]});})[_0x1be3e4('0x16')](function(){const _0x27c562=_0x1be3e4;if(_0x5377d6)return db[_0x27c562('0x4a')][_0x27c562('0x22')]({'where':{'membername':_0x5377d6['name'],'exitAt':null}});})[_0x1be3e4('0x16')](function(_0x112024){if(_0x5377d6){if(_0x112024&&_0x112024['length']){const _0x5e819f=[];return _0x112024['forEach'](function(_0xd0132c){const _0x1e80c8=a651_0x2b90;_0x5e819f['push'](_0xd0132c['update']({'exitAt':moment()[_0x1e80c8('0x3b')](_0x1e80c8('0x2e'))}));}),Promise['all'](_0x5e819f);}}})[_0x1be3e4('0x16')](function(){if(_0x5377d6)return _0x5377d6['update']({'online':![],'lastLoginAt':null,'voicePause':![],'mailPause':![],'chatPause':![],'faxPause':![],'smsPause':![],'openchannelPause':![]});})[_0x1be3e4('0x16')](function(_0x33df07){_0xb18667(_0x33df07);})[_0x1be3e4('0x2f')](function(_0x1a3da8){_0xe6bf63(_0x34be9f['error'](0x1f4,_0x1a3da8['message']));});});},exports[_0x595379('0xf')]=function(_0x4667de){const _0x6fc52a=this;return new Promise(function(_0x371626,_0x2efbb0){const _0x218980=a651_0x2b90;let _0x5ca0c7,_0x457a32,_0x1204a6,_0x51b142;return db['User'][_0x218980('0x2c')]({'where':_0x4667de[_0x218980('0x1f')]['where']||{},'attributes':['id',_0x218980('0x47'),'role','mobile','phone',_0x218980('0x1a'),_0x218980('0x2a'),_0x218980('0x9')]})[_0x218980('0x16')](function(_0x5e7cf8){const _0x437d89=_0x218980;if(_0x5e7cf8)return _0x5ca0c7=_0x5e7cf8,_0x51b142=_0x4667de[_0x437d89('0x39')][_0x437d89('0x9')]?_0x4667de[_0x437d89('0x39')]['interface']:util[_0x437d89('0x3b')](_0x437d89('0x28'),_0x5ca0c7[_0x437d89('0x47')]),db['User'][_0x437d89('0x36')]({'where':{'role':_0x437d89('0x4c'),'online':!![],'id':{[Op['ne']]:_0x5ca0c7['id']}}});})[_0x218980('0x16')](function(_0x415fd4){if(_0x415fd4)return _0x1204a6=_0x415fd4,require('../../config/license/util')['getLicense']();})[_0x218980('0x16')](function(_0x2df7e3){const _0x2bc4bf=_0x218980;if(_0x2df7e3&&_0x2df7e3[_0x2bc4bf('0x15')]&&_0x1204a6>=_0x2df7e3[_0x2bc4bf('0x15')])throw new Error(_0x2bc4bf('0x27'));})['then'](function(){const _0x2413a3=_0x218980;if(_0x5ca0c7)return db[_0x2413a3('0x25')][_0x2413a3('0x8')]({'where':{'membername':_0x5ca0c7[_0x2413a3('0x47')]},'individualHooks':!![]});})[_0x218980('0x16')](function(){const _0x76e27b=_0x218980;if(_0x5ca0c7)return _0x5ca0c7[_0x76e27b('0x23')]({'raw':!![]});})[_0x218980('0x16')](function(_0x27064f){const _0x399082=_0x218980;if(_0x5ca0c7){if(_0x27064f){const _0x490923=[];_0x457a32=_0x27064f;if(_0x457a32['length']){for(let _0x43381e=0x0;_0x43381e<_0x457a32[_0x399082('0xc')];_0x43381e++){_0x490923[_0x399082('0x26')](db[_0x399082('0x25')][_0x399082('0x12')]({'membername':_0x5ca0c7['name'],'UserId':_0x5ca0c7['id'],'queue_name':_0x457a32[_0x43381e][_0x399082('0x47')],'VoiceQueueId':_0x457a32[_0x43381e]['id'],'interface':_0x51b142,'paused':_0x5ca0c7[_0x399082('0x2a')]||![],'penalty':_0x457a32[_0x43381e]['UserVoiceQueue.penalty']||0x0}));}return Promise['all'](_0x490923);}}}})[_0x218980('0x16')](function(){const _0x6285b5=_0x218980;if(_0x5ca0c7)return db[_0x6285b5('0x4a')][_0x6285b5('0x22')]({'where':{'membername':_0x5ca0c7[_0x6285b5('0x47')],'exitAt':null}});})[_0x218980('0x16')](function(_0x6a4f16){const _0x333fd4=_0x218980;if(_0x5ca0c7){if(_0x6a4f16&&_0x6a4f16[_0x333fd4('0xc')]){const _0xff83f5=[];return _0x6a4f16[_0x333fd4('0x20')](function(_0x10058b){const _0x17849a=_0x333fd4;_0xff83f5['push'](_0x10058b[_0x17849a('0x3a')]({'exitAt':moment()[_0x17849a('0x3b')]('YYYY-MM-DD\x20HH:mm:ss')}));}),Promise[_0x333fd4('0x40')](_0xff83f5);}}})[_0x218980('0x16')](function(){const _0x4eb687=_0x218980;if(_0x5ca0c7){const _0x36196c=[],_0x39dbe2=[],_0x17905b=utils[_0x4eb687('0x10')](),_0x3c45b6={'membername':_0x5ca0c7[_0x4eb687('0x47')],'interface':_0x51b142,'enterAt':moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),'role':_0x5ca0c7[_0x4eb687('0x3e')],'internal':_0x5ca0c7[_0x4eb687('0x1a')]};return _0x17905b[_0x4eb687('0x20')](function(_0x26a1a6){const _0x12e8d2=_0x4eb687;_0x36196c['push'](_['merge']({'channel':_0x26a1a6,'type':_0x12e8d2('0x44'),'data1':_0x12e8d2('0x4e'),'data2':_0x51b142},_0x3c45b6)),_0x5ca0c7['loginInPause']&&_0x39dbe2[_0x12e8d2('0x26')](_[_0x12e8d2('0x2d')]({'channel':_0x26a1a6,'type':_0x12e8d2('0x0'),'data1':_0x12e8d2('0x42')},_0x3c45b6));}),db['MemberReport']['bulkCreate'](_0x36196c[_0x4eb687('0x19')](_0x39dbe2),{'individualHooks':!![]});}})[_0x218980('0x16')](function(){const _0x39901c=_0x218980;if(_0x5ca0c7)return _0x5ca0c7[_0x39901c('0x3a')]({'online':!![],'lastLoginAt':moment()[_0x39901c('0x3b')](_0x39901c('0x2e')),'voicePause':_0x5ca0c7['loginInPause']||![],'mailPause':_0x5ca0c7[_0x39901c('0x2a')]||![],'chatPause':_0x5ca0c7[_0x39901c('0x2a')]||![],'faxPause':_0x5ca0c7['loginInPause']||![],'smsPause':_0x5ca0c7[_0x39901c('0x2a')]||![],'openchannelPause':_0x5ca0c7[_0x39901c('0x2a')]||![],'pauseType':_0x5ca0c7['loginInPause']?_0x39901c('0x42'):null,'lastPauseAt':moment()[_0x39901c('0x3b')](_0x39901c('0x2e')),'interface':_0x51b142});})[_0x218980('0x16')](function(_0x53493e){_0x371626(_0x53493e);})[_0x218980('0x2f')](function(_0x52128b){const _0x8fa1b9=_0x218980;_0x2efbb0(_0x6fc52a[_0x8fa1b9('0x34')](0x1f4,_0x52128b[_0x8fa1b9('0x4f')]));});});}; \ No newline at end of file +const a651_0x5a9f=['callysquare','UserVoiceQueueRt','../../config/logger','chat','internal','MemberReport','Pause','format','raw','model','all','map','isValidChannel','DEFAULT\x20PAUSE','debug','findOne','then','fax','register','YYYY-MM-DD\x20HH:mm:ss','merge','%s%s','message','channel','length','getLicense','include','findAll','agents','system','LoginUser','concat','LOGIN','getChannels','attributes','name','LogoutUser','UserVoiceQueue.penalty','info','sequelize','GetUser','PauseUser','PAUSE','catch','push','destroy','util','../../mysqldb','User','options','limit','upsert','update','phone','loginInPause','error','type','set','interface','../../rediscache','./user.socket','role','agent','moment','isNil','mail','stringify','where','forEach','bulkCreate','SIP/%s','count','body','openchannel','ShowUser','LOGININPAUSE','uniqueid'];(function(_0x513870,_0x5a9fee){const _0x4644d5=function(_0x1d73fc){while(--_0x1d73fc){_0x513870['push'](_0x513870['shift']());}};_0x4644d5(++_0x5a9fee);}(a651_0x5a9f,0x14d));const a651_0x4644=function(_0x513870,_0x5a9fee){_0x513870=_0x513870-0x0;let _0x4644d5=a651_0x5a9f[_0x513870];return _0x4644d5;};const _0x44b7c4=a651_0x4644;'use strict';const _=require('lodash'),util=require(_0x44b7c4('0x15')),db=require(_0x44b7c4('0x16'))['db'],logger=require(_0x44b7c4('0x36'))('rpc'),moment=require(_0x44b7c4('0x26')),utils=require('../../config/utils'),{getSocket}=require(_0x44b7c4('0x22')),socket=getSocket(),sequelize=require(_0x44b7c4('0xe')),{Op}=sequelize;require(_0x44b7c4('0x23'))[_0x44b7c4('0x46')](socket),exports['GetUser']=function(_0x1d73fc){const _0x10649f=this;return new Promise(function(_0xdc5fa5,_0x5e800a){const _0x5bc903=a651_0x4644;return db['User'][_0x5bc903('0x2')]({'raw':_0x1d73fc['options']?_0x1d73fc[_0x5bc903('0x18')][_0x5bc903('0x3c')]===undefined?!![]:![]:!![],'where':_0x1d73fc[_0x5bc903('0x18')]?_0x1d73fc['options'][_0x5bc903('0x2a')]||null:null,'attributes':_0x1d73fc[_0x5bc903('0x18')]?_0x1d73fc[_0x5bc903('0x18')][_0x5bc903('0x9')]||null:null,'limit':_0x1d73fc[_0x5bc903('0x18')]?_0x1d73fc['options'][_0x5bc903('0x19')]||null:null,'include':_0x1d73fc['options']?_0x1d73fc['options']['include']?_['map'](_0x1d73fc[_0x5bc903('0x18')]['include'],function(_0x107270){const _0x362b97=_0x5bc903;return{'model':db[_0x107270[_0x362b97('0x3d')]],'as':_0x107270['as'],'attributes':_0x107270[_0x362b97('0x9')],'include':_0x107270[_0x362b97('0x1')]?_[_0x362b97('0x3f')](_0x107270[_0x362b97('0x1')],function(_0x5c67de){const _0x4e7ee4=_0x362b97;return{'model':db[_0x5c67de['model']],'as':_0x5c67de['as'],'attributes':_0x5c67de['attributes'],'include':_0x5c67de[_0x4e7ee4('0x1')]?_[_0x4e7ee4('0x3f')](_0x5c67de[_0x4e7ee4('0x1')],function(_0x51e4c8){const _0x187b2b=_0x4e7ee4;return{'model':db[_0x51e4c8['model']],'as':_0x51e4c8['as'],'attributes':_0x51e4c8[_0x187b2b('0x9')]};}):[]};}):[]};}):[]:[]})[_0x5bc903('0x44')](function(_0x500e87){const _0x77950a=_0x5bc903;logger['info'](_0x77950a('0xf'),_0x1d73fc),logger['debug'](_0x77950a('0xf'),_0x1d73fc,JSON[_0x77950a('0x29')](_0x500e87)),_0xdc5fa5(_0x500e87);})[_0x5bc903('0x12')](function(_0x5cc079){const _0x3556e3=_0x5bc903;logger['error'](_0x3556e3('0xf'),_0x5cc079[_0x3556e3('0x4a')],_0x1d73fc),_0x5e800a(_0x10649f[_0x3556e3('0x1e')](0x1f4,_0x5cc079[_0x3556e3('0x4a')]));});});},exports[_0x44b7c4('0x31')]=function(_0xdea68f){const _0x3a0d54=this;return new Promise(function(_0x3495f4,_0x28a703){const _0x389e96=a651_0x4644;return db[_0x389e96('0x17')][_0x389e96('0x43')]({'raw':_0xdea68f['options']?_0xdea68f[_0x389e96('0x18')][_0x389e96('0x3c')]===undefined?!![]:![]:!![],'where':_0xdea68f[_0x389e96('0x18')]?_0xdea68f['options'][_0x389e96('0x2a')]||null:null,'attributes':_0xdea68f[_0x389e96('0x18')]?_0xdea68f[_0x389e96('0x18')]['attributes']||null:null,'include':_0xdea68f[_0x389e96('0x18')]?_0xdea68f['options'][_0x389e96('0x1')]?_['map'](_0xdea68f['options'][_0x389e96('0x1')],function(_0x25ee61){const _0x592236=_0x389e96;return{'model':db[_0x25ee61[_0x592236('0x3d')]],'as':_0x25ee61['as'],'attributes':_0x25ee61[_0x592236('0x9')],'include':_0x25ee61[_0x592236('0x1')]?_[_0x592236('0x3f')](_0x25ee61['include'],function(_0x3ce530){const _0xc6f235=_0x592236;return{'model':db[_0x3ce530[_0xc6f235('0x3d')]],'as':_0x3ce530['as'],'attributes':_0x3ce530[_0xc6f235('0x9')],'include':_0x3ce530['include']?_['map'](_0x3ce530['include'],function(_0xa4ad7b){const _0x505daa=_0xc6f235;return{'model':db[_0xa4ad7b[_0x505daa('0x3d')]],'as':_0xa4ad7b['as'],'attributes':_0xa4ad7b[_0x505daa('0x9')]};}):[]};}):[]};}):[]:[]})[_0x389e96('0x44')](function(_0x371191){const _0x2beed5=_0x389e96;logger[_0x2beed5('0xd')](_0x2beed5('0x31'),_0xdea68f),logger[_0x2beed5('0x42')](_0x2beed5('0x31'),_0xdea68f,JSON[_0x2beed5('0x29')](_0x371191)),_0x3495f4(_0x371191);})[_0x389e96('0x12')](function(_0x1ec31c){const _0x27e504=_0x389e96;logger[_0x27e504('0x1e')](_0x27e504('0x31'),_0x1ec31c[_0x27e504('0x4a')],_0xdea68f),_0x28a703(_0x3a0d54[_0x27e504('0x1e')](0x1f4,_0x1ec31c[_0x27e504('0x4a')]));});});},exports[_0x44b7c4('0x10')]=function(_0xcfb36){const _0x336f6d=this;return new Promise(function(_0x257b2c,_0xe24b5c){const _0x29bbe2=a651_0x4644;let _0x4b2ba1;return db['User'][_0x29bbe2('0x43')]({'where':_0xcfb36['options'][_0x29bbe2('0x2a')]||{},'attributes':['id','name',_0x29bbe2('0x24'),_0x29bbe2('0x38'),_0x29bbe2('0x21')]})['then'](function(_0x54b02e){const _0x3ade1e=_0x29bbe2;if(_0x54b02e)return _0x4b2ba1=_0x54b02e,db[_0x3ade1e('0x35')]['update']({'paused':0x1},{'where':{'UserId':_0x4b2ba1['id']},'individualHooks':!![]});})[_0x29bbe2('0x44')](function(){const _0x395aff=_0x29bbe2;if(_0x4b2ba1)return db[_0x395aff('0x39')][_0x395aff('0x2')]({'where':{'membername':_0x4b2ba1[_0x395aff('0xa')],'type':_0x395aff('0x11'),'exitAt':null}});})[_0x29bbe2('0x44')](function(_0xbd0c95){const _0x28fac2=_0x29bbe2;if(_0x4b2ba1){if(_0xbd0c95&&_0xbd0c95[_0x28fac2('0x4c')]){const _0x230e75=moment()[_0x28fac2('0x3b')]('YYYY-MM-DD\x20HH:mm:ss');for(let _0x4ed8a9=0x0,_0x44852e=_0xbd0c95['length'];_0x4ed8a9<_0x44852e;_0x4ed8a9++){_0xbd0c95[_0x4ed8a9][_0x28fac2('0x1b')]({'exitAt':_0x230e75});}}}})[_0x29bbe2('0x44')](function(){const _0x421446=_0x29bbe2;if(_0x4b2ba1){const _0x2cc5a2=[],_0x2f5751=utils[_0x421446('0x8')]();return _0x2f5751[_0x421446('0x2b')](function(_0x437a13){const _0x3cba62=_0x421446;_0x2cc5a2[_0x3cba62('0x13')]({'channel':_0x437a13,'membername':_0x4b2ba1[_0x3cba62('0xa')],'interface':_[_0x3cba62('0x27')](_0x4b2ba1[_0x3cba62('0x21')])?util[_0x3cba62('0x3b')](_0x3cba62('0x2d'),_0x4b2ba1['name']):_0x4b2ba1[_0x3cba62('0x21')],'type':_0x3cba62('0x11'),'enterAt':moment()[_0x3cba62('0x3b')](_0x3cba62('0x47')),'data1':_0xcfb36[_0x3cba62('0x2f')][_0x3cba62('0x1f')]||_0x3cba62('0x41'),'role':_0x4b2ba1[_0x3cba62('0x24')],'internal':_0x4b2ba1[_0x3cba62('0x38')],'uniqueid':_0xcfb36[_0x3cba62('0x2f')][_0x3cba62('0x33')]||null});}),db[_0x421446('0x39')][_0x421446('0x2c')](_0x2cc5a2,{'individualHooks':!![]});}})['then'](function(){const _0x45ee89=_0x29bbe2;if(_0x4b2ba1)return _0x4b2ba1[_0x45ee89('0x1b')]({'voicePause':!![],'mailPause':!![],'chatPause':!![],'faxPause':!![],'smsPause':!![],'openchannelPause':!![],'pauseType':_0xcfb36[_0x45ee89('0x2f')]['type']||_0x45ee89('0x41'),'lastPauseAt':moment()[_0x45ee89('0x3b')](_0x45ee89('0x47'))});})[_0x29bbe2('0x44')](function(_0x3ca1b1){_0x257b2c(_0x3ca1b1);})[_0x29bbe2('0x12')](function(_0x2e7a32){const _0x33ca18=_0x29bbe2;_0xe24b5c(_0x336f6d[_0x33ca18('0x1e')](0x1f4,_0x2e7a32[_0x33ca18('0x4a')]));});});},exports['UnpauseUser']=function(_0x156ad0){const _0x4cdc20=this;return new Promise(function(_0xfb51c0,_0x1551d8){const _0x31ecbe=a651_0x4644;let _0x461dc4;return db[_0x31ecbe('0x17')][_0x31ecbe('0x43')]({'where':_0x156ad0[_0x31ecbe('0x18')][_0x31ecbe('0x2a')]||{},'attributes':['id','name']})[_0x31ecbe('0x44')](function(_0xfaa0e8){const _0x3a441c=_0x31ecbe;if(_0xfaa0e8){_0x461dc4=_0xfaa0e8;if(_0x156ad0[_0x3a441c('0x2f')][_0x3a441c('0x4b')]&&!utils[_0x3a441c('0x40')](_0x156ad0[_0x3a441c('0x2f')][_0x3a441c('0x4b')]))throw new Error('Unknown\x20channel');switch(_0x156ad0[_0x3a441c('0x2f')][_0x3a441c('0x4b')]){case'voice':return db[_0x3a441c('0x35')]['update']({'paused':0x0},{'where':{'UserId':_0x461dc4['id']}})[_0x3a441c('0x44')](function(){const _0x38a7a5=_0x3a441c;return db[_0x38a7a5('0x39')][_0x38a7a5('0x43')]({'where':{'channel':_0x156ad0[_0x38a7a5('0x2f')][_0x38a7a5('0x4b')],'membername':_0x461dc4[_0x38a7a5('0xa')],'type':'PAUSE','exitAt':null}});})[_0x3a441c('0x44')](function(_0x26e5f6){const _0x1ecc40=_0x3a441c;if(_0x26e5f6)return _0x26e5f6[_0x1ecc40('0x1b')]({'exitAt':moment()[_0x1ecc40('0x3b')](_0x1ecc40('0x47')),'data2':_0x1ecc40('0x4')},{'individualHooks':!![]});return null;})['then'](function(){const _0x3e819e=_0x3a441c;return _0x461dc4[_0x3e819e('0x1b')]({'voicePause':![]});});case _0x3a441c('0x28'):case _0x3a441c('0x37'):case _0x3a441c('0x45'):case'sms':case _0x3a441c('0x30'):return db[_0x3a441c('0x39')][_0x3a441c('0x43')]({'where':{'channel':_0x156ad0[_0x3a441c('0x2f')][_0x3a441c('0x4b')],'membername':_0x461dc4['name'],'type':_0x3a441c('0x11'),'exitAt':null}})[_0x3a441c('0x44')](function(_0x2421e7){const _0x14a9d3=_0x3a441c;return _0x2421e7[_0x14a9d3('0x1b')]({'exitAt':moment()[_0x14a9d3('0x3b')](_0x14a9d3('0x47')),'data2':'system'},{'individualHooks':!![]});})[_0x3a441c('0x44')](function(){const _0x23029f=_0x3a441c,_0x54b1ff={};return _[_0x23029f('0x20')](_0x54b1ff,util[_0x23029f('0x3b')](_0x23029f('0x49'),_0x156ad0[_0x23029f('0x2f')][_0x23029f('0x4b')],_0x23029f('0x3a')),![]),_0x461dc4['update'](_0x54b1ff);});default:return db[_0x3a441c('0x35')]['update']({'paused':0x0},{'where':{'UserId':_0x461dc4['id']}})[_0x3a441c('0x44')](function(){const _0x53e75d=_0x3a441c;return db[_0x53e75d('0x39')][_0x53e75d('0x2')]({'where':{'membername':_0x461dc4[_0x53e75d('0xa')],'type':_0x53e75d('0x11'),'exitAt':null}});})[_0x3a441c('0x44')](function(_0x4155a7){const _0x1f42d0=_0x3a441c,_0x39d300=[];return _0x4155a7[_0x1f42d0('0x2b')](function(_0x379ac7){const _0x108793=_0x1f42d0;_0x39d300['push'](_0x379ac7[_0x108793('0x1b')]({'exitAt':moment()['format'](_0x108793('0x47')),'data2':_0x108793('0x4')}));}),Promise[_0x1f42d0('0x3e')](_0x39d300);})[_0x3a441c('0x44')](function(){const _0x1b5959=_0x3a441c;return _0x461dc4[_0x1b5959('0x1b')]({'voicePause':![],'mailPause':![],'chatPause':![],'faxPause':![],'smsPause':![],'openchannelPause':![]});});}}})[_0x31ecbe('0x44')](function(_0x51c2ed){_0xfb51c0(_0x51c2ed);})[_0x31ecbe('0x12')](function(_0x39b2c2){const _0x1ebf40=_0x31ecbe;_0x1551d8(_0x4cdc20['error'](0x1f4,_0x39b2c2[_0x1ebf40('0x4a')]));});});},exports[_0x44b7c4('0xb')]=function(_0x6a8964){const _0x3e99c4=this;return new Promise(function(_0x276834,_0x194a77){const _0xeaf1a1=a651_0x4644;let _0x440e26;return db['User'][_0xeaf1a1('0x43')]({'where':_0x6a8964[_0xeaf1a1('0x18')][_0xeaf1a1('0x2a')]||{},'attributes':['id','name']})[_0xeaf1a1('0x44')](function(_0xa01d97){const _0x5e5c8e=_0xeaf1a1;if(_0xa01d97)return _0x440e26=_0xa01d97,db['UserVoiceQueueRt'][_0x5e5c8e('0x14')]({'where':{'membername':_0x440e26[_0x5e5c8e('0xa')]},'individualHooks':!![]});})['then'](function(){const _0x4b44d6=_0xeaf1a1;if(_0x440e26)return db['MemberReport'][_0x4b44d6('0x2')]({'where':{'membername':_0x440e26[_0x4b44d6('0xa')],'exitAt':null}});})[_0xeaf1a1('0x44')](function(_0x32296f){const _0x5d5cef=_0xeaf1a1;if(_0x440e26){if(_0x32296f&&_0x32296f[_0x5d5cef('0x4c')]){const _0x998940=[];return _0x32296f[_0x5d5cef('0x2b')](function(_0x4dba3a){const _0x2f44b8=_0x5d5cef;_0x998940[_0x2f44b8('0x13')](_0x4dba3a['update']({'exitAt':moment()[_0x2f44b8('0x3b')](_0x2f44b8('0x47'))}));}),Promise[_0x5d5cef('0x3e')](_0x998940);}}})[_0xeaf1a1('0x44')](function(){if(_0x440e26)return _0x440e26['update']({'online':![],'lastLoginAt':null,'voicePause':![],'mailPause':![],'chatPause':![],'faxPause':![],'smsPause':![],'openchannelPause':![]});})[_0xeaf1a1('0x44')](function(_0x536602){_0x276834(_0x536602);})['catch'](function(_0x107902){const _0x2ef53d=_0xeaf1a1;_0x194a77(_0x3e99c4['error'](0x1f4,_0x107902[_0x2ef53d('0x4a')]));});});},exports[_0x44b7c4('0x5')]=function(_0x1a0e42){const _0x195073=this;return new Promise(function(_0x62ec48,_0x13a49e){const _0x391144=a651_0x4644;let _0x17f612,_0x3fbd7f,_0x563fc2,_0x5149a9;return db[_0x391144('0x17')][_0x391144('0x43')]({'where':_0x1a0e42[_0x391144('0x18')][_0x391144('0x2a')]||{},'attributes':['id',_0x391144('0xa'),_0x391144('0x24'),'mobile',_0x391144('0x1c'),_0x391144('0x38'),_0x391144('0x1d'),_0x391144('0x21')]})[_0x391144('0x44')](function(_0x350352){const _0x2debbc=_0x391144;if(_0x350352)return _0x17f612=_0x350352,_0x5149a9=_0x1a0e42[_0x2debbc('0x2f')][_0x2debbc('0x21')]?_0x1a0e42[_0x2debbc('0x2f')][_0x2debbc('0x21')]:util['format'](_0x2debbc('0x2d'),_0x17f612[_0x2debbc('0xa')]),db[_0x2debbc('0x17')][_0x2debbc('0x2e')]({'where':{'role':_0x2debbc('0x25'),'online':!![],'id':{[Op['ne']]:_0x17f612['id']}}});})[_0x391144('0x44')](function(_0x491869){const _0xbbe463=_0x391144;if(_0x491869)return _0x563fc2=_0x491869,require('../../config/license/util')[_0xbbe463('0x0')]();})[_0x391144('0x44')](function(_0x398f85){const _0x181145=_0x391144;if(_0x398f85&&_0x398f85[_0x181145('0x3')]&&_0x563fc2>=_0x398f85[_0x181145('0x3')])throw new Error('Maximum\x20login\x20has\x20been\x20reached');})[_0x391144('0x44')](function(){const _0x4844b3=_0x391144;if(_0x17f612)return db[_0x4844b3('0x35')][_0x4844b3('0x14')]({'where':{'membername':_0x17f612['name']},'individualHooks':!![]});})['then'](function(){if(_0x17f612)return _0x17f612['getVoiceQueues']({'raw':!![]});})[_0x391144('0x44')](function(_0x53266a){const _0x20d8de=_0x391144;if(_0x17f612){if(_0x53266a){const _0x1c6af7=[];_0x3fbd7f=_0x53266a;if(_0x3fbd7f[_0x20d8de('0x4c')]){for(let _0x208edb=0x0;_0x208edb<_0x3fbd7f[_0x20d8de('0x4c')];_0x208edb++){_0x1c6af7[_0x20d8de('0x13')](db[_0x20d8de('0x35')][_0x20d8de('0x1a')]({'membername':_0x17f612['name'],'UserId':_0x17f612['id'],'queue_name':_0x3fbd7f[_0x208edb][_0x20d8de('0xa')],'VoiceQueueId':_0x3fbd7f[_0x208edb]['id'],'interface':_0x5149a9,'paused':_0x17f612['loginInPause']||![],'penalty':_0x3fbd7f[_0x208edb][_0x20d8de('0xc')]||0x0}));}return Promise[_0x20d8de('0x3e')](_0x1c6af7);}}}})['then'](function(){const _0x3ae551=_0x391144;if(_0x17f612)return db[_0x3ae551('0x39')][_0x3ae551('0x2')]({'where':{'membername':_0x17f612[_0x3ae551('0xa')],'exitAt':null}});})[_0x391144('0x44')](function(_0x4f8e4b){const _0x25bec9=_0x391144;if(_0x17f612){if(_0x4f8e4b&&_0x4f8e4b[_0x25bec9('0x4c')]){const _0x29218e=[];return _0x4f8e4b['forEach'](function(_0xfaa852){const _0x942818=_0x25bec9;_0x29218e[_0x942818('0x13')](_0xfaa852[_0x942818('0x1b')]({'exitAt':moment()[_0x942818('0x3b')](_0x942818('0x47'))}));}),Promise[_0x25bec9('0x3e')](_0x29218e);}}})['then'](function(){const _0x55d6d3=_0x391144;if(_0x17f612){const _0x55f5d2=[],_0x2e0354=[],_0x469557=utils[_0x55d6d3('0x8')](),_0x35e5cd={'membername':_0x17f612[_0x55d6d3('0xa')],'interface':_0x5149a9,'enterAt':moment()[_0x55d6d3('0x3b')]('YYYY-MM-DD\x20HH:mm:ss'),'role':_0x17f612[_0x55d6d3('0x24')],'internal':_0x17f612[_0x55d6d3('0x38')]};return _0x469557[_0x55d6d3('0x2b')](function(_0x4ea8f2){const _0x475e4d=_0x55d6d3;_0x55f5d2[_0x475e4d('0x13')](_[_0x475e4d('0x48')]({'channel':_0x4ea8f2,'type':_0x475e4d('0x7'),'data1':_0x475e4d('0x34'),'data2':_0x5149a9},_0x35e5cd)),_0x17f612[_0x475e4d('0x1d')]&&_0x2e0354[_0x475e4d('0x13')](_[_0x475e4d('0x48')]({'channel':_0x4ea8f2,'type':'PAUSE','data1':_0x475e4d('0x32')},_0x35e5cd));}),db[_0x55d6d3('0x39')][_0x55d6d3('0x2c')](_0x55f5d2[_0x55d6d3('0x6')](_0x2e0354),{'individualHooks':!![]});}})[_0x391144('0x44')](function(){const _0x577ca7=_0x391144;if(_0x17f612)return _0x17f612['update']({'online':!![],'lastLoginAt':moment()['format'](_0x577ca7('0x47')),'voicePause':_0x17f612['loginInPause']||![],'mailPause':_0x17f612[_0x577ca7('0x1d')]||![],'chatPause':_0x17f612[_0x577ca7('0x1d')]||![],'faxPause':_0x17f612[_0x577ca7('0x1d')]||![],'smsPause':_0x17f612[_0x577ca7('0x1d')]||![],'openchannelPause':_0x17f612[_0x577ca7('0x1d')]||![],'pauseType':_0x17f612[_0x577ca7('0x1d')]?_0x577ca7('0x32'):null,'lastPauseAt':moment()[_0x577ca7('0x3b')](_0x577ca7('0x47')),'interface':_0x5149a9});})[_0x391144('0x44')](function(_0x2cf20a){_0x62ec48(_0x2cf20a);})[_0x391144('0x12')](function(_0x238297){const _0x47d134=_0x391144;_0x13a49e(_0x195073['error'](0x1f4,_0x238297[_0x47d134('0x4a')]));});});}; \ No newline at end of file diff --git a/server/api/user/user.socket.js b/server/api/user/user.socket.js index c7708e4..c8f4828 100644 --- a/server/api/user/user.socket.js +++ b/server/api/user/user.socket.js @@ -1 +1 @@ -const a652_0x1444=['remove','./user.events','length','save','register','update'];(function(_0x890454,_0x14447b){const _0x1cdc83=function(_0x2612ec){while(--_0x2612ec){_0x890454['push'](_0x890454['shift']());}};_0x1cdc83(++_0x14447b);}(a652_0x1444,0xdb));const a652_0x1cdc=function(_0x890454,_0x14447b){_0x890454=_0x890454-0x0;let _0x1cdc83=a652_0x1444[_0x890454];return _0x1cdc83;};const _0x39e186=a652_0x1cdc;'use strict';const UserEvents=require(_0x39e186('0x4')),events=[_0x39e186('0x0'),_0x39e186('0x3'),_0x39e186('0x2')];function createListener(_0x2612ec,_0xdb5197){return function(_0x17ccf4){_0xdb5197['emit'](_0x2612ec,_0x17ccf4);};}exports[_0x39e186('0x1')]=function(_0x106404){const _0x54e230=_0x39e186;for(let _0x244982=0x0,_0x547ca9=events[_0x54e230('0x5')];_0x244982<_0x547ca9;_0x244982++){const _0xf896a9=events[_0x244982],_0x36b3c7=createListener('user:'+_0xf896a9,_0x106404);UserEvents['on'](_0xf896a9,_0x36b3c7);}}; \ No newline at end of file +const a652_0xbcc6=['save','remove','length','update','user:','register','emit'];(function(_0x3077c1,_0xbcc68){const _0x2cc098=function(_0x112803){while(--_0x112803){_0x3077c1['push'](_0x3077c1['shift']());}};_0x2cc098(++_0xbcc68);}(a652_0xbcc6,0x128));const a652_0x2cc0=function(_0x3077c1,_0xbcc68){_0x3077c1=_0x3077c1-0x0;let _0x2cc098=a652_0xbcc6[_0x3077c1];return _0x2cc098;};const _0x5779b6=a652_0x2cc0;'use strict';const UserEvents=require('./user.events'),events=[_0x5779b6('0x5'),_0x5779b6('0x6'),_0x5779b6('0x1')];function createListener(_0x112803,_0x16af80){return function(_0x191d62){const _0xa5cb62=a652_0x2cc0;_0x16af80[_0xa5cb62('0x4')](_0x112803,_0x191d62);};}exports[_0x5779b6('0x3')]=function(_0x4f972e){const _0x15c41b=_0x5779b6;for(let _0x105ab6=0x0,_0x44e7c1=events[_0x15c41b('0x0')];_0x105ab6<_0x44e7c1;_0x105ab6++){const _0x39bce0=events[_0x105ab6],_0x10b549=createListener(_0x15c41b('0x2')+_0x39bce0,_0x4f972e);UserEvents['on'](_0x39bce0,_0x10b549);}}; \ No newline at end of file diff --git a/server/api/userChatQueue/index.js b/server/api/userChatQueue/index.js index edab7e4..4080aef 100644 --- a/server/api/userChatQueue/index.js +++ b/server/api/userChatQueue/index.js @@ -1 +1 @@ -const a653_0xd91a=['exports'];(function(_0x512872,_0xd91a41){const _0x4d2f16=function(_0x4bb034){while(--_0x4bb034){_0x512872['push'](_0x512872['shift']());}};_0x4d2f16(++_0xd91a41);}(a653_0xd91a,0xdd));const a653_0x4d2f=function(_0x512872,_0xd91a41){_0x512872=_0x512872-0x0;let _0x4d2f16=a653_0xd91a[_0x512872];return _0x4d2f16;};const _0x16a447=a653_0x4d2f;'use strict';const express=require('express'),router=express['Router']();module[_0x16a447('0x0')]=router; \ No newline at end of file +const a653_0x591f=['exports'];(function(_0x395f51,_0x591f8e){const _0x3c4160=function(_0x4be684){while(--_0x4be684){_0x395f51['push'](_0x395f51['shift']());}};_0x3c4160(++_0x591f8e);}(a653_0x591f,0x173));const a653_0x3c41=function(_0x395f51,_0x591f8e){_0x395f51=_0x395f51-0x0;let _0x3c4160=a653_0x591f[_0x395f51];return _0x3c4160;};const _0x512e2d=a653_0x3c41;'use strict';const express=require('express'),router=express['Router']();module[_0x512e2d('0x0')]=router; \ No newline at end of file diff --git a/server/api/userChatQueue/userChatQueue.attributes.js b/server/api/userChatQueue/userChatQueue.attributes.js index cd14322..256a0fb 100644 --- a/server/api/userChatQueue/userChatQueue.attributes.js +++ b/server/api/userChatQueue/userChatQueue.attributes.js @@ -1 +1 @@ -const a654_0x387b=['sequelize','exports','INTEGER'];(function(_0x163708,_0x387bb4){const _0x12508d=function(_0x2ad9a8){while(--_0x2ad9a8){_0x163708['push'](_0x163708['shift']());}};_0x12508d(++_0x387bb4);}(a654_0x387b,0x8d));const a654_0x1250=function(_0x163708,_0x387bb4){_0x163708=_0x163708-0x0;let _0x12508d=a654_0x387b[_0x163708];return _0x12508d;};const _0x225260=a654_0x1250;'use strict';const Sequelize=require(_0x225260('0x0'));module[_0x225260('0x1')]={'penalty':{'type':Sequelize[_0x225260('0x2')],'defaultValue':0x0}}; \ No newline at end of file +const a654_0x390f=['sequelize','exports','INTEGER'];(function(_0x25b5a2,_0x390fb1){const _0x3f791e=function(_0x234781){while(--_0x234781){_0x25b5a2['push'](_0x25b5a2['shift']());}};_0x3f791e(++_0x390fb1);}(a654_0x390f,0xbe));const a654_0x3f79=function(_0x25b5a2,_0x390fb1){_0x25b5a2=_0x25b5a2-0x0;let _0x3f791e=a654_0x390f[_0x25b5a2];return _0x3f791e;};const _0x4ab98e=a654_0x3f79;'use strict';const Sequelize=require(_0x4ab98e('0x2'));module[_0x4ab98e('0x0')]={'penalty':{'type':Sequelize[_0x4ab98e('0x1')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/userChatQueue/userChatQueue.model.js b/server/api/userChatQueue/userChatQueue.model.js index fdcc250..20fd330 100644 --- a/server/api/userChatQueue/userChatQueue.model.js +++ b/server/api/userChatQueue/userChatQueue.model.js @@ -1 +1 @@ -const a655_0x3b9b=['define','./userChatQueue.attributes','UserChatQueue','exports','user_has_chat_queues'];(function(_0x1ccd07,_0x3b9bc4){const _0xab7feb=function(_0x3e1155){while(--_0x3e1155){_0x1ccd07['push'](_0x1ccd07['shift']());}};_0xab7feb(++_0x3b9bc4);}(a655_0x3b9b,0x1a7));const a655_0xab7f=function(_0x1ccd07,_0x3b9bc4){_0x1ccd07=_0x1ccd07-0x0;let _0xab7feb=a655_0x3b9b[_0x1ccd07];return _0xab7feb;};const _0x2c7fa4=a655_0xab7f;'use strict';const attributes=require(_0x2c7fa4('0x3'));module[_0x2c7fa4('0x0')]=function(_0x3e1155){const _0x51b9fc=_0x2c7fa4,_0x312700=_0x3e1155[_0x51b9fc('0x2')](_0x51b9fc('0x4'),attributes,{'tableName':_0x51b9fc('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x312700;}; \ No newline at end of file +const a655_0x31e6=['exports','user_has_chat_queues','UserChatQueue'];(function(_0x4952d8,_0x31e61a){const _0x26d231=function(_0x447207){while(--_0x447207){_0x4952d8['push'](_0x4952d8['shift']());}};_0x26d231(++_0x31e61a);}(a655_0x31e6,0x168));const a655_0x26d2=function(_0x4952d8,_0x31e61a){_0x4952d8=_0x4952d8-0x0;let _0x26d231=a655_0x31e6[_0x4952d8];return _0x26d231;};const _0xc06f3a=a655_0x26d2;'use strict';const attributes=require('./userChatQueue.attributes');module[_0xc06f3a('0x0')]=function(_0x447207){const _0x53b928=_0xc06f3a,_0x2eaf7a=_0x447207['define'](_0x53b928('0x2'),attributes,{'tableName':_0x53b928('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2eaf7a;}; \ No newline at end of file diff --git a/server/api/userFaxQueue/index.js b/server/api/userFaxQueue/index.js index 8960764..4b1be5e 100644 --- a/server/api/userFaxQueue/index.js +++ b/server/api/userFaxQueue/index.js @@ -1 +1 @@ -const a656_0x530f=['express','Router','exports'];(function(_0x14bb78,_0x530f12){const _0x4b4d2d=function(_0x62d11a){while(--_0x62d11a){_0x14bb78['push'](_0x14bb78['shift']());}};_0x4b4d2d(++_0x530f12);}(a656_0x530f,0x1e7));const a656_0x4b4d=function(_0x14bb78,_0x530f12){_0x14bb78=_0x14bb78-0x0;let _0x4b4d2d=a656_0x530f[_0x14bb78];return _0x4b4d2d;};const _0xd5f3ba=a656_0x4b4d;'use strict';const express=require(_0xd5f3ba('0x2')),router=express[_0xd5f3ba('0x0')]();module[_0xd5f3ba('0x1')]=router; \ No newline at end of file +const a656_0x5dd7=['exports'];(function(_0x294117,_0x5dd78d){const _0x2075e8=function(_0x50ea03){while(--_0x50ea03){_0x294117['push'](_0x294117['shift']());}};_0x2075e8(++_0x5dd78d);}(a656_0x5dd7,0x12e));const a656_0x2075=function(_0x294117,_0x5dd78d){_0x294117=_0x294117-0x0;let _0x2075e8=a656_0x5dd7[_0x294117];return _0x2075e8;};const _0x3b39c5=a656_0x2075;'use strict';const express=require('express'),router=express['Router']();module[_0x3b39c5('0x0')]=router; \ No newline at end of file diff --git a/server/api/userFaxQueue/userFaxQueue.attributes.js b/server/api/userFaxQueue/userFaxQueue.attributes.js index 1a87e49..1bc6b83 100644 --- a/server/api/userFaxQueue/userFaxQueue.attributes.js +++ b/server/api/userFaxQueue/userFaxQueue.attributes.js @@ -1 +1 @@ -const a657_0x13a3=['sequelize','STRING','INTEGER'];(function(_0x1c365c,_0x13a3ba){const _0x2df3d9=function(_0x1e977e){while(--_0x1e977e){_0x1c365c['push'](_0x1c365c['shift']());}};_0x2df3d9(++_0x13a3ba);}(a657_0x13a3,0x1a3));const a657_0x2df3=function(_0x1c365c,_0x13a3ba){_0x1c365c=_0x1c365c-0x0;let _0x2df3d9=a657_0x13a3[_0x1c365c];return _0x2df3d9;};const _0x2edd9e=a657_0x2df3;'use strict';const Sequelize=require(_0x2edd9e('0x1'));module['exports']={'penalty':{'type':Sequelize[_0x2edd9e('0x0')],'defaultValue':0x0},'assigned':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'queue':{'type':Sequelize[_0x2edd9e('0x2')]}}; \ No newline at end of file +const a657_0xbf7c=['exports','INTEGER','STRING'];(function(_0x53e559,_0xbf7c9d){const _0x1c353f=function(_0x4ce190){while(--_0x4ce190){_0x53e559['push'](_0x53e559['shift']());}};_0x1c353f(++_0xbf7c9d);}(a657_0xbf7c,0x106));const a657_0x1c35=function(_0x53e559,_0xbf7c9d){_0x53e559=_0x53e559-0x0;let _0x1c353f=a657_0xbf7c[_0x53e559];return _0x1c353f;};const _0x94f393=a657_0x1c35;'use strict';const Sequelize=require('sequelize');module[_0x94f393('0x2')]={'penalty':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'assigned':{'type':Sequelize[_0x94f393('0x0')],'defaultValue':0x0},'queue':{'type':Sequelize[_0x94f393('0x1')]}}; \ No newline at end of file diff --git a/server/api/userFaxQueue/userFaxQueue.model.js b/server/api/userFaxQueue/userFaxQueue.model.js index bfa7520..0755203 100644 --- a/server/api/userFaxQueue/userFaxQueue.model.js +++ b/server/api/userFaxQueue/userFaxQueue.model.js @@ -1 +1 @@ -const a658_0x5967=['UserFaxQueue','user_has_fax_queues','define','./userFaxQueue.attributes'];(function(_0x217d2e,_0x5967f1){const _0x3daf9f=function(_0x5e5c0b){while(--_0x5e5c0b){_0x217d2e['push'](_0x217d2e['shift']());}};_0x3daf9f(++_0x5967f1);}(a658_0x5967,0x150));const a658_0x3daf=function(_0x217d2e,_0x5967f1){_0x217d2e=_0x217d2e-0x0;let _0x3daf9f=a658_0x5967[_0x217d2e];return _0x3daf9f;};const _0x3348b7=a658_0x3daf;'use strict';const attributes=require(_0x3348b7('0x3'));module['exports']=function(_0x5e5c0b){const _0x2b31c2=_0x3348b7,_0x3979d6=_0x5e5c0b[_0x2b31c2('0x2')](_0x2b31c2('0x0'),attributes,{'tableName':_0x2b31c2('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3979d6;}; \ No newline at end of file +const a658_0x44ad=['exports','user_has_fax_queues','UserFaxQueue','./userFaxQueue.attributes'];(function(_0x2f70d6,_0x44ad4d){const _0x53c844=function(_0x336de9){while(--_0x336de9){_0x2f70d6['push'](_0x2f70d6['shift']());}};_0x53c844(++_0x44ad4d);}(a658_0x44ad,0x18b));const a658_0x53c8=function(_0x2f70d6,_0x44ad4d){_0x2f70d6=_0x2f70d6-0x0;let _0x53c844=a658_0x44ad[_0x2f70d6];return _0x53c844;};const _0x419bfc=a658_0x53c8;'use strict';const attributes=require(_0x419bfc('0x0'));module[_0x419bfc('0x1')]=function(_0x336de9){const _0x25398a=_0x419bfc,_0x383f97=_0x336de9['define'](_0x25398a('0x3'),attributes,{'tableName':_0x25398a('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x383f97;}; \ No newline at end of file diff --git a/server/api/userMailQueue/index.js b/server/api/userMailQueue/index.js index e09e48f..fb96499 100644 --- a/server/api/userMailQueue/index.js +++ b/server/api/userMailQueue/index.js @@ -1 +1 @@ -const a659_0xcd1b=['express','exports'];(function(_0x43d713,_0xcd1b85){const _0x5e20cc=function(_0x222047){while(--_0x222047){_0x43d713['push'](_0x43d713['shift']());}};_0x5e20cc(++_0xcd1b85);}(a659_0xcd1b,0x1f0));const a659_0x5e20=function(_0x43d713,_0xcd1b85){_0x43d713=_0x43d713-0x0;let _0x5e20cc=a659_0xcd1b[_0x43d713];return _0x5e20cc;};const _0x572c4e=a659_0x5e20;'use strict';const express=require(_0x572c4e('0x0')),router=express['Router']();module[_0x572c4e('0x1')]=router; \ No newline at end of file +const a659_0x19da=['exports','Router'];(function(_0x4c0042,_0x19daec){const _0x3be0d9=function(_0x4f31a2){while(--_0x4f31a2){_0x4c0042['push'](_0x4c0042['shift']());}};_0x3be0d9(++_0x19daec);}(a659_0x19da,0xcc));const a659_0x3be0=function(_0x4c0042,_0x19daec){_0x4c0042=_0x4c0042-0x0;let _0x3be0d9=a659_0x19da[_0x4c0042];return _0x3be0d9;};const _0x5b3c0b=a659_0x3be0;'use strict';const express=require('express'),router=express[_0x5b3c0b('0x1')]();module[_0x5b3c0b('0x0')]=router; \ No newline at end of file diff --git a/server/api/userMailQueue/userMailQueue.attributes.js b/server/api/userMailQueue/userMailQueue.attributes.js index a4db63e..a082c12 100644 --- a/server/api/userMailQueue/userMailQueue.attributes.js +++ b/server/api/userMailQueue/userMailQueue.attributes.js @@ -1 +1 @@ -const a660_0x146b=['INTEGER','sequelize'];(function(_0x4c97bf,_0x146b5d){const _0x3dbaa9=function(_0x1f81d7){while(--_0x1f81d7){_0x4c97bf['push'](_0x4c97bf['shift']());}};_0x3dbaa9(++_0x146b5d);}(a660_0x146b,0x1a5));const a660_0x3dba=function(_0x4c97bf,_0x146b5d){_0x4c97bf=_0x4c97bf-0x0;let _0x3dbaa9=a660_0x146b[_0x4c97bf];return _0x3dbaa9;};const _0x52282c=a660_0x3dba;'use strict';const Sequelize=require(_0x52282c('0x0'));module['exports']={'penalty':{'type':Sequelize[_0x52282c('0x1')],'defaultValue':0x0}}; \ No newline at end of file +const a660_0x2e0e=['INTEGER','sequelize'];(function(_0x157f10,_0x2e0e9e){const _0x27f856=function(_0x25e14e){while(--_0x25e14e){_0x157f10['push'](_0x157f10['shift']());}};_0x27f856(++_0x2e0e9e);}(a660_0x2e0e,0x156));const a660_0x27f8=function(_0x157f10,_0x2e0e9e){_0x157f10=_0x157f10-0x0;let _0x27f856=a660_0x2e0e[_0x157f10];return _0x27f856;};const _0x54269d=a660_0x27f8;'use strict';const Sequelize=require(_0x54269d('0x1'));module['exports']={'penalty':{'type':Sequelize[_0x54269d('0x0')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/userMailQueue/userMailQueue.model.js b/server/api/userMailQueue/userMailQueue.model.js index bbbe1aa..f8701f0 100644 --- a/server/api/userMailQueue/userMailQueue.model.js +++ b/server/api/userMailQueue/userMailQueue.model.js @@ -1 +1 @@ -const a661_0x145a=['define','UserMailQueue','exports'];(function(_0x5a1b35,_0x145ab4){const _0x5bced5=function(_0x5bd40c){while(--_0x5bd40c){_0x5a1b35['push'](_0x5a1b35['shift']());}};_0x5bced5(++_0x145ab4);}(a661_0x145a,0x15c));const a661_0x5bce=function(_0x5a1b35,_0x145ab4){_0x5a1b35=_0x5a1b35-0x0;let _0x5bced5=a661_0x145a[_0x5a1b35];return _0x5bced5;};const _0x407b55=a661_0x5bce;'use strict';const attributes=require('./userMailQueue.attributes');module[_0x407b55('0x2')]=function(_0x5bd40c){const _0x598803=_0x407b55,_0x3c190c=_0x5bd40c[_0x598803('0x0')](_0x598803('0x1'),attributes,{'tableName':'user_has_mail_queues','paranoid':![],'indexes':[],'timestamps':!![]});return _0x3c190c;}; \ No newline at end of file +const a661_0x4b8e=['UserMailQueue','define','./userMailQueue.attributes'];(function(_0x2f1baf,_0x4b8e72){const _0x121093=function(_0x42d078){while(--_0x42d078){_0x2f1baf['push'](_0x2f1baf['shift']());}};_0x121093(++_0x4b8e72);}(a661_0x4b8e,0xe0));const a661_0x1210=function(_0x2f1baf,_0x4b8e72){_0x2f1baf=_0x2f1baf-0x0;let _0x121093=a661_0x4b8e[_0x2f1baf];return _0x121093;};const _0x2b9582=a661_0x1210;'use strict';const attributes=require(_0x2b9582('0x0'));module['exports']=function(_0x42d078){const _0x5f213e=_0x2b9582,_0xa12c75=_0x42d078[_0x5f213e('0x2')](_0x5f213e('0x1'),attributes,{'tableName':'user_has_mail_queues','paranoid':![],'indexes':[],'timestamps':!![]});return _0xa12c75;}; \ No newline at end of file diff --git a/server/api/userOpenchannelQueue/index.js b/server/api/userOpenchannelQueue/index.js index 9044d7e..43aa38a 100644 --- a/server/api/userOpenchannelQueue/index.js +++ b/server/api/userOpenchannelQueue/index.js @@ -1 +1 @@ -const a662_0x425c=['exports','Router','express'];(function(_0x10d6b1,_0x425c05){const _0x28afc6=function(_0x45e8bf){while(--_0x45e8bf){_0x10d6b1['push'](_0x10d6b1['shift']());}};_0x28afc6(++_0x425c05);}(a662_0x425c,0x6d));const a662_0x28af=function(_0x10d6b1,_0x425c05){_0x10d6b1=_0x10d6b1-0x0;let _0x28afc6=a662_0x425c[_0x10d6b1];return _0x28afc6;};const _0x75cdab=a662_0x28af;'use strict';const express=require(_0x75cdab('0x1')),router=express[_0x75cdab('0x0')]();module[_0x75cdab('0x2')]=router; \ No newline at end of file +const a662_0x149f=['Router','express'];(function(_0x53dfe0,_0x149fe0){const _0x1ce332=function(_0x37175a){while(--_0x37175a){_0x53dfe0['push'](_0x53dfe0['shift']());}};_0x1ce332(++_0x149fe0);}(a662_0x149f,0xc6));const a662_0x1ce3=function(_0x53dfe0,_0x149fe0){_0x53dfe0=_0x53dfe0-0x0;let _0x1ce332=a662_0x149f[_0x53dfe0];return _0x1ce332;};const _0x48c081=a662_0x1ce3;'use strict';const express=require(_0x48c081('0x1')),router=express[_0x48c081('0x0')]();module['exports']=router; \ No newline at end of file diff --git a/server/api/userOpenchannelQueue/userOpenchannelQueue.attributes.js b/server/api/userOpenchannelQueue/userOpenchannelQueue.attributes.js index ca20650..5e62159 100644 --- a/server/api/userOpenchannelQueue/userOpenchannelQueue.attributes.js +++ b/server/api/userOpenchannelQueue/userOpenchannelQueue.attributes.js @@ -1 +1 @@ -const a663_0x1908=['sequelize'];(function(_0x25793f,_0x1908e0){const _0x4558d2=function(_0x265e87){while(--_0x265e87){_0x25793f['push'](_0x25793f['shift']());}};_0x4558d2(++_0x1908e0);}(a663_0x1908,0x17f));const a663_0x4558=function(_0x25793f,_0x1908e0){_0x25793f=_0x25793f-0x0;let _0x4558d2=a663_0x1908[_0x25793f];return _0x4558d2;};const _0x4d2ed5=a663_0x4558;'use strict';const Sequelize=require(_0x4d2ed5('0x0'));module['exports']={'penalty':{'type':Sequelize['INTEGER'],'defaultValue':0x0}}; \ No newline at end of file +const a663_0x5a45=['sequelize','exports','INTEGER'];(function(_0x1a3454,_0x5a4520){const _0x590dd9=function(_0x1eecf8){while(--_0x1eecf8){_0x1a3454['push'](_0x1a3454['shift']());}};_0x590dd9(++_0x5a4520);}(a663_0x5a45,0x1dd));const a663_0x590d=function(_0x1a3454,_0x5a4520){_0x1a3454=_0x1a3454-0x0;let _0x590dd9=a663_0x5a45[_0x1a3454];return _0x590dd9;};const _0x124383=a663_0x590d;'use strict';const Sequelize=require(_0x124383('0x0'));module[_0x124383('0x1')]={'penalty':{'type':Sequelize[_0x124383('0x2')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/userOpenchannelQueue/userOpenchannelQueue.model.js b/server/api/userOpenchannelQueue/userOpenchannelQueue.model.js index 8a49370..c4ab3db 100644 --- a/server/api/userOpenchannelQueue/userOpenchannelQueue.model.js +++ b/server/api/userOpenchannelQueue/userOpenchannelQueue.model.js @@ -1 +1 @@ -const a664_0x4349=['exports','./userOpenchannelQueue.attributes','UserOpenchannelQueue','user_has_openchannel_queues'];(function(_0x3e4d9c,_0x434973){const _0x459d96=function(_0x340edf){while(--_0x340edf){_0x3e4d9c['push'](_0x3e4d9c['shift']());}};_0x459d96(++_0x434973);}(a664_0x4349,0x1e4));const a664_0x459d=function(_0x3e4d9c,_0x434973){_0x3e4d9c=_0x3e4d9c-0x0;let _0x459d96=a664_0x4349[_0x3e4d9c];return _0x459d96;};const _0xf3bb58=a664_0x459d;'use strict';const attributes=require(_0xf3bb58('0x1'));module[_0xf3bb58('0x0')]=function(_0x340edf){const _0x4275a6=_0xf3bb58,_0x6ccaa3=_0x340edf['define'](_0x4275a6('0x2'),attributes,{'tableName':_0x4275a6('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x6ccaa3;}; \ No newline at end of file +const a664_0x5b70=['UserOpenchannelQueue','./userOpenchannelQueue.attributes','user_has_openchannel_queues'];(function(_0x493050,_0x5b7014){const _0x3af95c=function(_0x245704){while(--_0x245704){_0x493050['push'](_0x493050['shift']());}};_0x3af95c(++_0x5b7014);}(a664_0x5b70,0x6f));const a664_0x3af9=function(_0x493050,_0x5b7014){_0x493050=_0x493050-0x0;let _0x3af95c=a664_0x5b70[_0x493050];return _0x3af95c;};const _0x50bb04=a664_0x3af9;'use strict';const attributes=require(_0x50bb04('0x1'));module['exports']=function(_0x245704){const _0x2a968d=_0x50bb04,_0x3f8c58=_0x245704['define'](_0x2a968d('0x0'),attributes,{'tableName':_0x2a968d('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3f8c58;}; \ No newline at end of file diff --git a/server/api/userProfile/index.js b/server/api/userProfile/index.js index 856166a..9eb250b 100644 --- a/server/api/userProfile/index.js +++ b/server/api/userProfile/index.js @@ -1 +1 @@ -const a665_0x321e=['/:id/sections','getResources','Router','../../components/auth/service','get','destroy','express','create','removeResources','show','isAuthenticated','./userProfile.controller','/:id/clone','update','removeSections','describe','/:id/resources','/describe','getSections','/:id','post','put','index','addSections'];(function(_0x4cd39c,_0x321ef5){const _0x51d647=function(_0x3e380f){while(--_0x3e380f){_0x4cd39c['push'](_0x4cd39c['shift']());}};_0x51d647(++_0x321ef5);}(a665_0x321e,0x120));const a665_0x51d6=function(_0x4cd39c,_0x321ef5){_0x4cd39c=_0x4cd39c-0x0;let _0x51d647=a665_0x321e[_0x4cd39c];return _0x51d647;};const _0x1aa0fc=a665_0x51d6;'use strict';const express=require(_0x1aa0fc('0x6')),router=express[_0x1aa0fc('0x2')](),auth=require(_0x1aa0fc('0x3')),controller=require(_0x1aa0fc('0xb'));router[_0x1aa0fc('0x4')]('/',auth['isAuthenticated'](),controller[_0x1aa0fc('0x16')]),router[_0x1aa0fc('0x4')](_0x1aa0fc('0x11'),auth['isAuthenticated'](),controller[_0x1aa0fc('0xf')]),router[_0x1aa0fc('0x4')](_0x1aa0fc('0x13'),auth[_0x1aa0fc('0xa')](),controller[_0x1aa0fc('0x9')]),router['get'](_0x1aa0fc('0x0'),auth[_0x1aa0fc('0xa')](),controller[_0x1aa0fc('0x12')]),router[_0x1aa0fc('0x4')](_0x1aa0fc('0x10'),auth[_0x1aa0fc('0xa')](),controller[_0x1aa0fc('0x1')]),router['post']('/',auth[_0x1aa0fc('0xa')](),controller[_0x1aa0fc('0x7')]),router[_0x1aa0fc('0x14')](_0x1aa0fc('0xc'),auth[_0x1aa0fc('0xa')](),controller['clone']),router[_0x1aa0fc('0x14')](_0x1aa0fc('0x0'),auth[_0x1aa0fc('0xa')](),controller[_0x1aa0fc('0x17')]),router[_0x1aa0fc('0x14')]('/:id/resources',auth[_0x1aa0fc('0xa')](),controller['addResources']),router[_0x1aa0fc('0x15')]('/:id',auth[_0x1aa0fc('0xa')](),controller[_0x1aa0fc('0xd')]),router['delete'](_0x1aa0fc('0x13'),auth[_0x1aa0fc('0xa')](),controller[_0x1aa0fc('0x5')]),router['delete'](_0x1aa0fc('0x0'),auth['isAuthenticated'](),controller[_0x1aa0fc('0xe')]),router['delete']('/:id/resources',auth['isAuthenticated'](),controller[_0x1aa0fc('0x8')]),module['exports']=router; \ No newline at end of file +const a665_0xadeb=['post','addResources','express','/:id','removeResources','destroy','/:id/clone','describe','put','/describe','/:id/sections','delete','getSections','Router','isAuthenticated','create','../../components/auth/service','show','exports','get','removeSections','index','update','./userProfile.controller','/:id/resources'];(function(_0x5a1d59,_0xadeb82){const _0x49e3d1=function(_0x128c59){while(--_0x128c59){_0x5a1d59['push'](_0x5a1d59['shift']());}};_0x49e3d1(++_0xadeb82);}(a665_0xadeb,0x116));const a665_0x49e3=function(_0x5a1d59,_0xadeb82){_0x5a1d59=_0x5a1d59-0x0;let _0x49e3d1=a665_0xadeb[_0x5a1d59];return _0x49e3d1;};const _0x51cea5=a665_0x49e3;'use strict';const express=require(_0x51cea5('0x18')),router=express[_0x51cea5('0xa')](),auth=require(_0x51cea5('0xd')),controller=require(_0x51cea5('0x14'));router['get']('/',auth[_0x51cea5('0xb')](),controller[_0x51cea5('0x12')]),router[_0x51cea5('0x10')](_0x51cea5('0x6'),auth[_0x51cea5('0xb')](),controller[_0x51cea5('0x4')]),router[_0x51cea5('0x10')]('/:id',auth[_0x51cea5('0xb')](),controller[_0x51cea5('0xe')]),router[_0x51cea5('0x10')](_0x51cea5('0x7'),auth['isAuthenticated'](),controller[_0x51cea5('0x9')]),router[_0x51cea5('0x10')](_0x51cea5('0x15'),auth[_0x51cea5('0xb')](),controller['getResources']),router[_0x51cea5('0x16')]('/',auth['isAuthenticated'](),controller[_0x51cea5('0xc')]),router[_0x51cea5('0x16')](_0x51cea5('0x3'),auth['isAuthenticated'](),controller['clone']),router[_0x51cea5('0x16')](_0x51cea5('0x7'),auth['isAuthenticated'](),controller['addSections']),router[_0x51cea5('0x16')](_0x51cea5('0x15'),auth[_0x51cea5('0xb')](),controller[_0x51cea5('0x17')]),router[_0x51cea5('0x5')](_0x51cea5('0x0'),auth[_0x51cea5('0xb')](),controller[_0x51cea5('0x13')]),router[_0x51cea5('0x8')](_0x51cea5('0x0'),auth[_0x51cea5('0xb')](),controller[_0x51cea5('0x2')]),router[_0x51cea5('0x8')](_0x51cea5('0x7'),auth[_0x51cea5('0xb')](),controller[_0x51cea5('0x11')]),router[_0x51cea5('0x8')]('/:id/resources',auth[_0x51cea5('0xb')](),controller[_0x51cea5('0x1')]),module[_0x51cea5('0xf')]=router; \ No newline at end of file diff --git a/server/api/userProfile/userProfile.attributes.js b/server/api/userProfile/userProfile.attributes.js index 52d6110..67a7add 100644 --- a/server/api/userProfile/userProfile.attributes.js +++ b/server/api/userProfile/userProfile.attributes.js @@ -1 +1 @@ -const a666_0x586e=['name','setDataValue','getDataValue','crudPermissions','STRING','join','split'];(function(_0x27a1d4,_0x586e13){const _0xfd2a7c=function(_0x258e4a){while(--_0x258e4a){_0x27a1d4['push'](_0x27a1d4['shift']());}};_0xfd2a7c(++_0x586e13);}(a666_0x586e,0x168));const a666_0xfd2a=function(_0x27a1d4,_0x586e13){_0x27a1d4=_0x27a1d4-0x0;let _0xfd2a7c=a666_0x586e[_0x27a1d4];return _0xfd2a7c;};const _0x45ee97=a666_0xfd2a;'use strict';const Sequelize=require('sequelize');module['exports']={'name':{'type':Sequelize[_0x45ee97('0x1')],'allowNull':![],'unique':_0x45ee97('0x4')},'crudPermissions':{'type':Sequelize[_0x45ee97('0x1')],'set':function(_0x258e4a){const _0xcafe7f=_0x45ee97;this[_0xcafe7f('0x5')](_0xcafe7f('0x0'),_0x258e4a?_0x258e4a[_0xcafe7f('0x2')](''):[]);},'get':function(){const _0x2840d4=_0x45ee97;return this[_0x2840d4('0x6')](_0x2840d4('0x0'))?this[_0x2840d4('0x6')](_0x2840d4('0x0'))[_0x2840d4('0x3')](''):[];},'allowNull':![],'defaultValue':'r'},'description':{'type':Sequelize[_0x45ee97('0x1')],'allowNull':!![]}}; \ No newline at end of file +const a666_0x8b1c=['split','crudPermissions','exports','STRING','getDataValue','sequelize','name','join'];(function(_0x4ee749,_0x8b1c6a){const _0x54de6e=function(_0x1f9be3){while(--_0x1f9be3){_0x4ee749['push'](_0x4ee749['shift']());}};_0x54de6e(++_0x8b1c6a);}(a666_0x8b1c,0x188));const a666_0x54de=function(_0x4ee749,_0x8b1c6a){_0x4ee749=_0x4ee749-0x0;let _0x54de6e=a666_0x8b1c[_0x4ee749];return _0x54de6e;};const _0x2d5e2d=a666_0x54de;'use strict';const Sequelize=require(_0x2d5e2d('0x5'));module[_0x2d5e2d('0x2')]={'name':{'type':Sequelize[_0x2d5e2d('0x3')],'allowNull':![],'unique':_0x2d5e2d('0x6')},'crudPermissions':{'type':Sequelize['STRING'],'set':function(_0x1f9be3){const _0x3d9712=_0x2d5e2d;this['setDataValue'](_0x3d9712('0x1'),_0x1f9be3?_0x1f9be3[_0x3d9712('0x7')](''):[]);},'get':function(){const _0x279750=_0x2d5e2d;return this['getDataValue']('crudPermissions')?this[_0x279750('0x4')](_0x279750('0x1'))[_0x279750('0x0')](''):[];},'allowNull':![],'defaultValue':'r'},'description':{'type':Sequelize[_0x2d5e2d('0x3')],'allowNull':!![]}}; \ No newline at end of file diff --git a/server/api/userProfile/userProfile.controller.js b/server/api/userProfile/userProfile.controller.js index 670f076..5ac2d22 100644 --- a/server/api/userProfile/userProfile.controller.js +++ b/server/api/userProfile/userProfile.controller.js @@ -1 +1 @@ -const a667_0x321d=['register','get','voiceprefixes','lists','map','contacts','stack','SquareProject','include','musiconholds','order','SquareRecording','tag','internalroutes','chatwebsites','undefined','sequelize','ivrcampaigns','whatsappqueues','removeResources','freshdeskaccounts','transaction','Resources','QueueCampaigns','getSections','keys','nolimit','Telephones','users','Schedule','rawAttributes','subsections','update','inboundroutes','fields','UserProfileSection','VoiceChanSpy','metrics','whatsappaccounts','queuecampaigns','set','projectName','filters','VoiceRecording','Agents','type','sectionId','UserProfileResource','intersection','./userProfile.socket','SugarcrmAccount','vtigeraccounts','CustomReports','like','../../rediscache','OpenchannelAccount','SmsQueue','VoiceMail','includeAll','user','field','ignore','openchannelaccounts','zohoaccounts','tags','smsaccounts','count','associatedResources','key','templates','push','value','custom','extractedreports','destroy','Interval','createdAt','union','Tag','describe','VoicePrefix','params','reportType','VoiceExtension','catch','sugarcrmaccounts','Template','ids','Trunk','parentSections','mailsubstatuses','autoAssociation','omit','agent','userProfileId','name','dispositions','end','filter','merge','JscriptyProject','telephone','ThroughTags','body','VoiceQueues','getResources','all','outboundroutes','Tags','odbc','rows','../../components/parsers/qs','mailqueues','foreignKey','customdashboards','Disposition','queue','attributes','trunks','create','Sound','enabled','ZohoAccount','isEmpty','voicemails','sounds','send','resourceId','sort','scheduler','Reports','CmCompany','AnalyticMetric','api','FaxAccount','Variable','voicerecordings','VoiceQueue','model','reportId','where','User','telephones','Lists','../../config/logger','find','SalesforceAccount','ZendeskAccount','status','role','pick','Unknown\x20section','MailAccount','findAll','length','updatedAt','childModel','Plugin','DeskAccount','squarerecordings','squareprojects','Team','CmList','admin','crudPermissions','includes','Campaign','triggers','VoiceContext','addSections','DefaultReports','each','limit','sendStatus','intervals','query','CmContact','Content-Range','options','bulkCreate','FreshdeskAccount','json','section','CmCustomField','projects','color','OpenchannelQueue','CannedAnswer','globalcustomfields','index','chatqueues','Invalid\x20section\x20\x27','VoiceMusicOnHold','agents','faxqueues','AnalyticExtractedReport','salesforceaccounts','clone','chanspies','then','WhatsappQueue','UserProfile','findOne','SquareOdbc','VIRTUAL','offset','teams','forEach','companies'];(function(_0x5e7bb6,_0x321d38){const _0x498699=function(_0x3b1028){while(--_0x3b1028){_0x5e7bb6['push'](_0x5e7bb6['shift']());}};_0x498699(++_0x321d38);}(a667_0x321d,0x182));const a667_0x4986=function(_0x5e7bb6,_0x321d38){_0x5e7bb6=_0x5e7bb6-0x0;let _0x498699=a667_0x321d[_0x5e7bb6];return _0x498699;};const _0x5837ab=a667_0x4986;'use strict';const _=require('lodash'),qs=require(_0x5837ab('0x8f')),logger=require(_0x5837ab('0xb0'))(_0x5837ab('0xa5')),{getSocket}=require(_0x5837ab('0x56')),socket=getSocket(),db=require('../../mysqldb')['db'],{Op,ValidationError}=require(_0x5837ab('0x30'));require(_0x5837ab('0x51'))[_0x5837ab('0x20')](socket);function respondWithStatusCode(_0x3b1028,_0x532c15){return _0x532c15=_0x532c15||0xcc,function(_0x43a1e4){const _0x33fc87=a667_0x4986;if(_0x43a1e4)return _0x3b1028[_0x33fc87('0xcd')](_0x532c15);return _0x3b1028[_0x33fc87('0xb4')](_0x532c15)[_0x33fc87('0x81')]();};}function respondWithResult(_0x278061,_0x26b3d8){return _0x26b3d8=_0x26b3d8||0xc8,function(_0x3f7c49){const _0x245090=a667_0x4986;if(_0x3f7c49)return _0x278061[_0x245090('0xb4')](_0x26b3d8)[_0x245090('0x4')](_0x3f7c49);};}function respondWithFilteredResult(_0x49f1c7,_0x1a64a7){return function(_0x2bb2b6){const _0x5cbc1d=a667_0x4986;if(_0x2bb2b6){const _0x42094b=_0x2bb2b6[_0x5cbc1d('0x62')],_0x4278ce=_0x1a64a7['offset'];let _0x4224a9=_0x1a64a7[_0x5cbc1d('0x1c')]+_0x1a64a7[_0x5cbc1d('0xcc')],_0x2dc7d5;return _0x4224a9>=_0x42094b?(_0x4224a9=_0x42094b,_0x2dc7d5=0xc8):_0x2dc7d5=0xce,_0x49f1c7[_0x5cbc1d('0xb4')](_0x2dc7d5),_0x49f1c7[_0x5cbc1d('0x48')](_0x5cbc1d('0x0'),_0x4278ce+'-'+_0x4224a9+'/'+_0x42094b)['json'](_0x2bb2b6);}return null;};}function saveUpdates(_0x350eec){return function(_0x1c264f){const _0x443e97=a667_0x4986;if(_0x1c264f)return _0x1c264f[_0x443e97('0x40')](_0x350eec)[_0x443e97('0x16')](function(_0x1540d7){return _0x1540d7;});return null;};}function removeEntity(_0x49dfab){return function(_0x3257f8){const _0xfc2fc6=a667_0x4986;if(_0x3257f8)return _0x3257f8[_0xfc2fc6('0x6a')]()[_0xfc2fc6('0x16')](function(){_0x49dfab['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x11e498){return function(_0x3b253b){const _0x5bb12b=a667_0x4986;return!_0x3b253b&&_0x11e498[_0x5bb12b('0xcd')](0x194),_0x3b253b;};}function handleError(_0x4817fa,_0x332fec){return _0x332fec=_0x332fec||0x1f4,function(_0xa0578a){const _0x21cdaf=a667_0x4986;logger['error'](_0xa0578a[_0x21cdaf('0x26')]),_0xa0578a[_0x21cdaf('0x7f')]&&delete _0xa0578a[_0x21cdaf('0x7f')],_0x4817fa[_0x21cdaf('0xb4')](_0x332fec)[_0x21cdaf('0x9e')](_0xa0578a);};}exports[_0x5837ab('0xc')]=function(_0x21c715,_0xdff68f){const _0x37717a=_0x5837ab;let _0x357aea={};const _0x5cc14a={},_0x18bbda={'count':0x0,'rows':[]},_0xbd8d5=_['map'](db['UserProfile'][_0x37717a('0x3e')],function(_0x1babfd){const _0x2789e3=_0x37717a;return{'name':_0x1babfd['fieldName'],'type':_0x1babfd[_0x2789e3('0x4d')][_0x2789e3('0x64')]};});_0x5cc14a[_0x37717a('0xaa')]=_[_0x37717a('0x24')](_0xbd8d5,_0x37717a('0x7f')),_0x5cc14a[_0x37717a('0xcf')]=_[_0x37717a('0x39')](_0x21c715[_0x37717a('0xcf')]),_0x5cc14a[_0x37717a('0x4a')]=_[_0x37717a('0x50')](_0x5cc14a['model'],_0x5cc14a['query']),_0x357aea[_0x37717a('0x95')]=_[_0x37717a('0x50')](_0x5cc14a[_0x37717a('0xaa')],qs[_0x37717a('0x42')](_0x21c715['query'][_0x37717a('0x42')])),_0x357aea[_0x37717a('0x95')]=_0x357aea['attributes']['length']?_0x357aea[_0x37717a('0x95')]:_0x5cc14a['model'];typeof _0x21c715['query'][_0x37717a('0x3a')]===_0x37717a('0x2f')&&(_0x357aea[_0x37717a('0xcc')]=qs[_0x37717a('0xcc')](_0x21c715['query']['limit']),_0x357aea[_0x37717a('0x1c')]=qs[_0x37717a('0x1c')](_0x21c715[_0x37717a('0xcf')][_0x37717a('0x1c')]));_0x357aea[_0x37717a('0x2a')]=qs[_0x37717a('0xa0')](_0x21c715[_0x37717a('0xcf')]['sort']),_0x357aea['where']=qs[_0x37717a('0x4a')](_[_0x37717a('0xb6')](_0x21c715[_0x37717a('0xcf')],_0x5cc14a[_0x37717a('0x4a')]),_0xbd8d5);_0x21c715[_0x37717a('0xcf')][_0x37717a('0x82')]&&(_0x357aea[_0x37717a('0xac')]=_['merge'](_0x357aea[_0x37717a('0xac')],{[Op['or']]:_[_0x37717a('0x24')](_0xbd8d5,function(_0x156409){const _0x3eb164=_0x37717a;if(_0x156409[_0x3eb164('0x4d')]!==_0x3eb164('0x1b')){const _0x519689={};return _0x519689[_0x156409[_0x3eb164('0x7f')]]={[Op[_0x3eb164('0x55')]]:'%'+_0x21c715[_0x3eb164('0xcf')]['filter']+'%'},_0x519689;}})}));_0x357aea=_[_0x37717a('0x83')]({},_0x357aea,_0x21c715[_0x37717a('0x1')]);const _0x5e8241={'where':_0x357aea[_0x37717a('0xac')]};return db[_0x37717a('0x18')][_0x37717a('0x62')](_0x5e8241)['then'](function(_0x30b028){const _0x3d8db2=_0x37717a;return _0x18bbda[_0x3d8db2('0x62')]=_0x30b028,_0x21c715[_0x3d8db2('0xcf')]['includeAll']&&(_0x357aea[_0x3d8db2('0x28')]=[{'all':!![]}]),db[_0x3d8db2('0x18')][_0x3d8db2('0xb9')](_0x357aea);})['then'](function(_0x554fd8){const _0x5a52be=_0x37717a;return _0x18bbda[_0x5a52be('0x8e')]=_0x554fd8,_0x18bbda;})['then'](respondWithFilteredResult(_0xdff68f,_0x357aea))[_0x37717a('0x74')](handleError(_0xdff68f,null));},exports['show']=function(_0x3296b8,_0x20b329){const _0x4e58ca=_0x5837ab;let _0x400a73={'raw':![],'where':{'id':_0x3296b8[_0x4e58ca('0x71')]['id']}};const _0x2d6906={};return _0x2d6906[_0x4e58ca('0xaa')]=_['keys'](db[_0x4e58ca('0x18')][_0x4e58ca('0x3e')]),_0x2d6906['query']=_[_0x4e58ca('0x39')](_0x3296b8[_0x4e58ca('0xcf')]),_0x2d6906['filters']=_['intersection'](_0x2d6906[_0x4e58ca('0xaa')],_0x2d6906[_0x4e58ca('0xcf')]),_0x400a73[_0x4e58ca('0x95')]=_[_0x4e58ca('0x50')](_0x2d6906['model'],qs[_0x4e58ca('0x42')](_0x3296b8[_0x4e58ca('0xcf')][_0x4e58ca('0x42')])),_0x400a73[_0x4e58ca('0x95')]=_0x400a73[_0x4e58ca('0x95')][_0x4e58ca('0xba')]?_0x400a73[_0x4e58ca('0x95')]:_0x2d6906['model'],_0x3296b8[_0x4e58ca('0xcf')]['includeAll']&&(_0x400a73[_0x4e58ca('0x28')]=[{'all':!![]}]),_0x400a73=_[_0x4e58ca('0x83')]({},_0x400a73,_0x3296b8[_0x4e58ca('0x1')]),db['UserProfile'][_0x4e58ca('0x19')](_0x400a73)[_0x4e58ca('0x16')](handleEntityNotFound(_0x20b329))[_0x4e58ca('0x16')](respondWithResult(_0x20b329,null))[_0x4e58ca('0x74')](handleError(_0x20b329,null));},exports['create']=function(_0x5e648b,_0xae04ac){const _0x4604ec=_0x5837ab;return db[_0x4604ec('0x18')][_0x4604ec('0x97')](_0x5e648b[_0x4604ec('0x87')],{})['then'](respondWithResult(_0xae04ac,0xc9))['catch'](handleError(_0xae04ac,null));},exports[_0x5837ab('0x14')]=function(_0x51c732,_0x324c39){const _0x44d6a3=_0x5837ab;let _0x45fd0f={'where':{'id':_0x51c732[_0x44d6a3('0x71')]['id']}};const _0x361d04={};return _0x361d04[_0x44d6a3('0xaa')]=_[_0x44d6a3('0x39')](db[_0x44d6a3('0x18')][_0x44d6a3('0x3e')]),_0x45fd0f[_0x44d6a3('0x95')]=_[_0x44d6a3('0x50')](_0x361d04[_0x44d6a3('0xaa')],qs['fields'](_0x51c732[_0x44d6a3('0xcf')][_0x44d6a3('0x42')])),_0x45fd0f[_0x44d6a3('0x95')]=_0x45fd0f[_0x44d6a3('0x95')][_0x44d6a3('0xba')]?_0x45fd0f[_0x44d6a3('0x95')]:_0x361d04['model'],_0x51c732[_0x44d6a3('0xcf')]['includeAll']&&(_0x45fd0f['include']=[{'all':!![]}]),_0x45fd0f=_[_0x44d6a3('0x83')]({},_0x45fd0f,_0x51c732[_0x44d6a3('0x1')]),db[_0x44d6a3('0x18')][_0x44d6a3('0x19')](_0x45fd0f)[_0x44d6a3('0x16')](handleEntityNotFound(_0x324c39))[_0x44d6a3('0x16')](function(_0x36df47){const _0x2abd95=_0x44d6a3;if(_0x36df47){let _0x362e89=_0x36df47[_0x2abd95('0x21')]({'plain':!![]});return _0x362e89=qs[_0x2abd95('0x7c')](_0x362e89,['id',_0x2abd95('0x6c'),'updatedAt',_0x2abd95('0xc4')]),_0x51c732[_0x2abd95('0x87')]=_['omit'](_0x51c732['body'],['id',_0x2abd95('0x6c'),_0x2abd95('0xbb')]),db[_0x2abd95('0x30')][_0x2abd95('0x35')](function(_0x69a98f){const _0x24315a=_0x2abd95;return db[_0x24315a('0x18')][_0x24315a('0x97')](_[_0x24315a('0x83')](_0x362e89,_0x51c732[_0x24315a('0x87')]),{'include':_0x51c732[_0x24315a('0xcf')]['includeAll']?[{'all':!![]}]:undefined,'transaction':_0x69a98f})[_0x24315a('0x16')](function(_0x22754a){const _0x15ba95=_0x24315a,_0x53f598=_0x22754a['get']({'plain':!![]});return db['UserProfileSection'][_0x15ba95('0xb9')]({'where':{'userProfileId':_0x51c732['params']['id']},'raw':!![]})[_0x15ba95('0x16')](function(_0xa2dcad){const _0x38023d=_0x15ba95;if(_0xa2dcad)return Promise[_0x38023d('0xcb')](_0xa2dcad,function(_0xd2dec5){const _0x3e9606=_0x38023d;return new Promise(function(_0x3d40ad,_0x23cc66){const _0x17f539=a667_0x4986;if(_0xd2dec5['autoAssociation']===null||_0xd2dec5[_0x17f539('0x7b')]===0x1)_0x3d40ad(null);return db[_0x17f539('0x4f')]['findAll']({'where':{'sectionId':_0xd2dec5['id']},'raw':!![]})[_0x17f539('0x16')](function(_0x5af247){const _0x15e893=_0x17f539,_0x20121c=_[_0x15e893('0x24')](_0x5af247,function(_0xe44c00){const _0x1cef3d=_0x15e893;return qs['omit'](_0xe44c00,['id',_0x1cef3d('0x6c'),_0x1cef3d('0xbb'),_0x1cef3d('0x4e')]);});_0x3d40ad(_0x20121c);})[_0x17f539('0x74')](function(_0x3dd77a){_0x23cc66(_0x3dd77a);});})[_0x3e9606('0x16')](function(_0x28bb5a){const _0x43c5e4=_0x3e9606,_0x3b68c2=qs['omit'](_0xd2dec5,['id',_0x43c5e4('0x6c'),_0x43c5e4('0xbb')]);_0x3b68c2[_0x43c5e4('0x7e')]=_0x53f598['id'];if(_0x28bb5a)_0x3b68c2['Resources']=_0x28bb5a;return _0x3b68c2;})[_0x3e9606('0x16')](function(_0x230cd3){const _0x490eac=_0x3e9606;return db[_0x490eac('0x43')][_0x490eac('0x97')](_0x230cd3,{'include':[{'model':db[_0x490eac('0x4f')],'as':_0x490eac('0x36')}],'raw':!![],'transaction':_0x69a98f});});})['then'](function(){return _0x53f598;});});});});}})[_0x44d6a3('0x16')](respondWithResult(_0x324c39,0xc9))[_0x44d6a3('0x74')](handleError(_0x324c39,null));},exports[_0x5837ab('0x40')]=function(_0x38236c,_0x545eab){const _0x48d53b=_0x5837ab;return _0x38236c[_0x48d53b('0x87')]['id']&&delete _0x38236c['body']['id'],db[_0x48d53b('0x18')]['findOne']({'where':{'id':_0x38236c[_0x48d53b('0x71')]['id']}})[_0x48d53b('0x16')](handleEntityNotFound(_0x545eab))['then'](saveUpdates(_0x38236c[_0x48d53b('0x87')],null))[_0x48d53b('0x16')](respondWithResult(_0x545eab,null))['catch'](handleError(_0x545eab,null));},exports[_0x5837ab('0x6a')]=function(_0x6145fa,_0x5a09e8){const _0x5c1df6=_0x5837ab;return db['UserProfile'][_0x5c1df6('0x19')]({'where':{'id':_0x6145fa[_0x5c1df6('0x71')]['id']}})['then'](handleEntityNotFound(_0x5a09e8))[_0x5c1df6('0x16')](removeEntity(_0x5a09e8,null))[_0x5c1df6('0x74')](handleError(_0x5a09e8,null));},exports[_0x5837ab('0x6f')]=function(_0x113286,_0x2e873b){const _0x105b18=_0x5837ab;return db[_0x105b18('0x18')][_0x105b18('0x6f')]()[_0x105b18('0x16')](respondWithResult(_0x2e873b,null))[_0x105b18('0x74')](handleError(_0x2e873b,null));},exports[_0x5837ab('0xc9')]=function(_0x14f00b,_0x5ec983){const _0x109ef1=_0x5837ab,_0x39e705=_0x14f00b['body'];return db[_0x109ef1('0x18')][_0x109ef1('0x19')]({'where':{'id':_0x14f00b[_0x109ef1('0x71')]['id']}})[_0x109ef1('0x16')](handleEntityNotFound(_0x5ec983))[_0x109ef1('0x16')](function(_0x298137){const _0xbbc352=_0x109ef1;if(_0x298137)return db['sequelize'][_0xbbc352('0x35')](function(_0x2cdf58){const _0x115fcf=_0xbbc352;return db['UserProfileSection'][_0x115fcf('0x6a')]({'where':{'userProfileId':_0x14f00b[_0x115fcf('0x71')]['id'],'sectionId':_['map'](_0x39e705,function(_0x6129cb){const _0x2cf43b=_0x115fcf;return _0x6129cb[_0x2cf43b('0x4e')];})},'transaction':_0x2cdf58})[_0x115fcf('0x16')](function(){const _0x366d03=_0x115fcf,_0x11db11=_[_0x366d03('0x24')](_0x39e705,function(_0x18a82c){const _0x3f8dec=_0x366d03;return _0x18a82c[_0x3f8dec('0x7e')]=_0x14f00b[_0x3f8dec('0x71')]['id'],_0x18a82c;}),_0x4ad8f6=[];return Promise[_0x366d03('0xcb')](_0x11db11,function(_0xf438a7){const _0x43e8b4=_0x366d03;return db[_0x43e8b4('0x43')][_0x43e8b4('0x97')](_0xf438a7,{'include':[{'model':db[_0x43e8b4('0x4f')],'as':'Resources'}],'raw':!![],'transaction':_0x2cdf58})[_0x43e8b4('0x16')](function(_0x2ccc57){const _0x18020f=_0x43e8b4;_0x4ad8f6[_0x18020f('0x66')](_0x2ccc57[_0x18020f('0x21')]({'plain':!![]}));});})[_0x366d03('0x16')](function(){return _0x4ad8f6;});});});})[_0x109ef1('0x16')](function(_0x56bf74){return _0x56bf74;})[_0x109ef1('0x16')](respondWithResult(_0x5ec983,null))[_0x109ef1('0x74')](handleError(_0x5ec983,null));},exports['removeSections']=function(_0x42ace9,_0x52ebc8){const _0x14f3cc=_0x5837ab;let _0x1b1885;return db[_0x14f3cc('0x18')][_0x14f3cc('0x19')]({'where':{'id':_0x42ace9[_0x14f3cc('0x71')]['id']},'attributes':['id',_0x14f3cc('0x7f')]})[_0x14f3cc('0x16')](handleEntityNotFound(_0x52ebc8))[_0x14f3cc('0x16')](function(_0x3c41e2){const _0x18d824=_0x14f3cc;if(_0x3c41e2)return _0x1b1885=_0x3c41e2,db[_0x18d824('0x43')]['destroy']({'where':{'userProfileId':_0x42ace9['params']['id'],'sectionId':_0x42ace9['query'][_0x18d824('0x77')]}});})['then'](function(){return _0x1b1885;})[_0x14f3cc('0x16')](respondWithStatusCode(_0x52ebc8,null))[_0x14f3cc('0x74')](handleError(_0x52ebc8,null));},exports[_0x5837ab('0x38')]=function(_0x176aad,_0x189c2e){const _0x56fa44=_0x5837ab;let _0x7051ce=[],_0x2fd220=[];return db[_0x56fa44('0x43')]['findAll']({'where':{'userProfileId':_0x176aad[_0x56fa44('0x71')]['id']},'raw':!![]})['then'](function(_0xfd30a4){const _0x383a48=_0x56fa44;_0x7051ce=_[_0x383a48('0x82')](_0xfd30a4,function(_0x4d8dfb){const _0x44b5f3=_0x383a48;return _0x4d8dfb[_0x44b5f3('0x99')]===0x1||_[_0x44b5f3('0xc5')]([0x3eb,0x709],_0x4d8dfb['sectionId']);});if(!_['isEmpty'](_0x7051ce))return _[_0x383a48('0x24')](_0x7051ce,function(_0x264ed2){const _0x2c83e7=_0x383a48;return _0x264ed2[_0x2c83e7('0x4e')];});else return;})[_0x56fa44('0x16')](function(_0x9058f6){const _0x10dd89=_0x56fa44;if(_0x9058f6)_0x2fd220=_0x9058f6;if(_[_0x10dd89('0xc5')](_0x2fd220,0x64)){const _0x2dc194=_['find'](_0x7051ce,{'sectionId':0x64});return hasDefaultDashboard(_0x2dc194)['then'](function(_0x1fcd8c){const _0x1c8b3d=_0x10dd89;return _[_0x1c8b3d('0x24')](_0x7051ce,function(_0x4904e3){const _0x30ada0=_0x1c8b3d;return _0x4904e3[_0x30ada0('0x4e')]===0x64&&(_0x4904e3['subsections']=_0x1fcd8c),_0x4904e3;});});}else return;})[_0x56fa44('0x16')](function(_0x381569){const _0x49d16e=_0x56fa44;if(_0x381569)_0x7051ce=_0x381569;if(_[_0x49d16e('0xc5')](_0x2fd220,0x3eb)){const _0x47c205=_['find'](_0x7051ce,{'sectionId':0x3eb});return getCustomDashboards(_0x47c205)['then'](function(_0x223b10){const _0x93257d=_0x49d16e;return _[_0x93257d('0x24')](_0x7051ce,function(_0x1175cb){const _0x27708a=_0x93257d;return _0x47c205['enabled']?_0x1175cb['sectionId']===0x3eb&&(_0x1175cb[_0x27708a('0x3f')]=_0x223b10):_0x1175cb[_0x27708a('0x4e')]===0x64&&(_0x1175cb[_0x27708a('0x3f')]=_0x223b10),_0x1175cb;});});}else return;})[_0x56fa44('0x16')](function(_0x3e353d){const _0x6312d=_0x56fa44;if(_0x3e353d)_0x7051ce=_0x3e353d;if(_[_0x6312d('0xc5')](_0x2fd220,0x709)){const _0x1dc829=_[_0x6312d('0xb1')](_0x7051ce,{'sectionId':0x709});return getPlugins(_0x1dc829)[_0x6312d('0x16')](function(_0x3e658e){const _0x181c8e=_0x6312d;if(_0x1dc829['enabled'])return _['map'](_0x7051ce,function(_0x4c3a0d){const _0x129a6f=a667_0x4986;return _0x4c3a0d['sectionId']===0x709&&(_0x4c3a0d[_0x129a6f('0x3f')]=_0x3e658e),_0x4c3a0d;});else{const _0x254b32={'sectionId':0x76c,'enabled':0x1,'subsections':_0x3e658e},_0x3bf5eb=_['map'](_0x7051ce);return _0x3bf5eb[_0x181c8e('0x66')](_0x254b32),_0x3bf5eb;}});}else return;})['then'](function(_0x497315){const _0x388432=_0x56fa44;if(_0x497315)_0x7051ce=_0x497315;return _[_0x388432('0x82')](_0x7051ce,[_0x388432('0x99'),0x1]);})[_0x56fa44('0x16')](respondWithResult(_0x189c2e,null))[_0x56fa44('0x74')](handleError(_0x189c2e,null));};function hasDefaultDashboard(_0x5526d1){const _0x1107fc=[0x65];return new Promise(function(_0xf0ec7a,_0x4cf96b){const _0xd9efa2=a667_0x4986;try{if(_0x5526d1[_0xd9efa2('0x7b')])_0xf0ec7a(_0x1107fc);else return db['UserProfileResource'][_0xd9efa2('0x19')]({'where':{'sectionId':_0x5526d1['id']},'raw':!![]})['then'](function(_0x284527){_0x284527?_0xf0ec7a(_0x1107fc):_0xf0ec7a();});}catch(_0x37f251){_0x4cf96b(_0x37f251);}});}function getCustomDashboards(_0x5e238b){const _0x1067d6=[];return new Promise(function(_0x7fc363,_0x2d787e){const _0x36bcbc=a667_0x4986;try{return _0x5e238b['autoAssociation']?db['Dashboard'][_0x36bcbc('0xb9')]({'raw':!![]})[_0x36bcbc('0x16')](function(_0x5dd5e2){_0x5dd5e2['forEach'](function(_0x5505ab){const _0x415f61=a667_0x4986;_0x1067d6[_0x415f61('0x66')](_0x5505ab['id']+0x1869f);}),_0x7fc363(_0x1067d6);}):db[_0x36bcbc('0x4f')][_0x36bcbc('0xb9')]({'where':{'sectionId':_0x5e238b['id']},'raw':!![]})['then'](function(_0x3d1876){const _0x457c23=_0x36bcbc;_0x3d1876[_0x457c23('0x1e')](function(_0x3ff87f){const _0x9412aa=_0x457c23;_0x1067d6[_0x9412aa('0x66')](_0x3ff87f[_0x9412aa('0x9f')]+0x1869f);}),_0x7fc363(_0x1067d6);});}catch(_0x5bd84d){_0x2d787e(_0x5bd84d);}});}function getPlugins(_0x5a131f){const _0xf3e0bc=[];return new Promise(function(_0x63e66f,_0x2aa268){const _0x213ab2=a667_0x4986;try{return _0x5a131f[_0x213ab2('0x7b')]?db[_0x213ab2('0xbd')][_0x213ab2('0xb9')]({'raw':!![]})[_0x213ab2('0x16')](function(_0x39fc9f){const _0x3f49a0=_0x213ab2;_0x39fc9f[_0x3f49a0('0x1e')](function(_0x38acf2){_0xf3e0bc['push'](_0x38acf2['id']+0x15b38);}),_0x63e66f(_0xf3e0bc);}):db[_0x213ab2('0x4f')][_0x213ab2('0xb9')]({'where':{'sectionId':_0x5a131f['id']},'raw':!![]})['then'](function(_0x21d220){const _0x1ac4b5=_0x213ab2;_0x21d220[_0x1ac4b5('0x1e')](function(_0x372458){const _0x1164af=_0x1ac4b5;_0xf3e0bc[_0x1164af('0x66')](_0x372458[_0x1164af('0x9f')]+0x15b38);}),_0x63e66f(_0xf3e0bc);});}catch(_0xa192db){_0x2aa268(_0xa192db);}});}exports['addResources']=function(_0x20b390,_0xf910f1){const _0x2ad1f5=_0x5837ab;return db['UserProfile'][_0x2ad1f5('0x19')]({'where':{'id':_0x20b390[_0x2ad1f5('0x71')]['id']}})[_0x2ad1f5('0x16')](handleEntityNotFound(_0xf910f1))[_0x2ad1f5('0x16')](function(_0x19f1d6){const _0xfa5372=_0x2ad1f5;if(_0x19f1d6)return db['sequelize'][_0xfa5372('0x35')](function(_0x373819){const _0x4c2249=_0xfa5372;return db['UserProfileSection'][_0x4c2249('0xb9')]({'where':{'userProfileId':_0x20b390[_0x4c2249('0x71')]['id']},'attributes':['id'],'raw':!![]})[_0x4c2249('0x16')](function(_0x172fdd){const _0x34abc4=_0x4c2249;if(_0x172fdd)return db['UserProfileSection'][_0x34abc4('0x6a')]({'where':{'userProfileId':_0x20b390[_0x34abc4('0x71')]['id'],'id':_[_0x34abc4('0x24')](_0x172fdd,function(_0xd689cb){return _0xd689cb['id'];})},'transaction':_0x373819});})['then'](function(){const _0x426f61=_0x4c2249,_0x3c34e1=_['map'](_0x20b390[_0x426f61('0x87')],function(_0x17f16c){const _0x22af48=_0x426f61;return _0x17f16c[_0x22af48('0x7e')]=_0x20b390[_0x22af48('0x71')]['id'],_0x17f16c;});return db[_0x426f61('0x43')]['bulkCreate'](_0x3c34e1,{'raw':!![],'transaction':_0x373819});})[_0x4c2249('0x16')](function(_0x187dc4){const _0x2aa275=_0x4c2249,_0x114b28=_[_0x2aa275('0x82')](_['map'](_0x187dc4,function(_0x22469b){const _0x38a6a9=_0x2aa275;return _0x22469b[_0x38a6a9('0x21')]({'plain':!![]});}),{'includeAll':![]});if(_0x114b28)return db[_0x2aa275('0x43')]['findAll']({'where':{'userProfileId':_0x20b390[_0x2aa275('0x71')]['id'],'sectionId':_['map'](_0x114b28,function(_0x4c5332){const _0x2c6fa6=_0x2aa275;return _0x4c5332[_0x2c6fa6('0x4e')];})},'attributes':['id',_0x2aa275('0x4e')],'raw':!![]})[_0x2aa275('0x16')](function(){const _0x40a17f=_0x2aa275,_0x4ea5d6=_[_0x40a17f('0x24')](_0x20b390[_0x40a17f('0x87')],function(_0x2f4ad1){const _0x20c488=_0x40a17f;return _0x2f4ad1[_0x20c488('0x7e')]=_0x20b390[_0x20c488('0x71')]['id'],_0x2f4ad1;});return db['UserProfileResource'][_0x40a17f('0x2')](_0x4ea5d6,{'raw':!![],'transaction':_0x373819});});})['catch'](handleError(_0xf910f1,null));});})[_0x2ad1f5('0x16')](function(){})[_0x2ad1f5('0x16')](respondWithResult(_0xf910f1,null))[_0x2ad1f5('0x74')](handleError(_0xf910f1,null));},exports[_0x5837ab('0x33')]=function(_0x27410a,_0x329f0d){const _0x42c45a=_0x5837ab;return db[_0x42c45a('0x18')]['findOne']({'where':{'id':_0x27410a[_0x42c45a('0x71')]['id']}})[_0x42c45a('0x16')](handleEntityNotFound(_0x329f0d))['then'](function(_0x41c823){const _0x255fe5=_0x42c45a;if(_0x41c823)return _0x41c823[_0x255fe5('0x33')](_0x27410a[_0x255fe5('0xcf')][_0x255fe5('0x77')]);})[_0x42c45a('0x16')](respondWithStatusCode(_0x329f0d,null))['catch'](handleError(_0x329f0d,null));},exports[_0x5837ab('0x89')]=function(_0x1747b7,_0x4b908b){const _0x3717b1=_0x5837ab;let _0x15b24c={'raw':![],'where':{}};const _0x51cbf0={},_0x45a51b={'count':0x0,'rows':[]},_0x2f6cf9=_0x1747b7[_0x3717b1('0xcf')][_0x3717b1('0x5')];if(typeof _0x2f6cf9===_0x3717b1('0x2f'))throw new ValidationError(_0x3717b1('0xb7'));const _0x1f8ec5=_0x1747b7[_0x3717b1('0xcf')]['mergeResources']||![],_0x2157e2=getQueryModels(_0x2f6cf9,_0x1f8ec5);if(typeof _0x2157e2[_0x3717b1('0xbc')]===_0x3717b1('0x2f'))throw new ValidationError(_0x3717b1('0xe')+_0x2f6cf9+'\x27');let _0x571c6b=[];return!_['isEmpty'](_0x2157e2[_0x3717b1('0x79')])?_0x571c6b=_0x2157e2[_0x3717b1('0x79')]:_0x571c6b=[{'name':_0x2f6cf9}],db['UserProfile'][_0x3717b1('0x19')]({'where':{'id':_0x1747b7[_0x3717b1('0x71')]['id']}})[_0x3717b1('0x16')](handleEntityNotFound(_0x4b908b))[_0x3717b1('0x16')](function(_0x542949){const _0x19e64c=_0x3717b1;if(_0x542949){const _0x54d6bf=[];for(let _0x4ffcd5=0x0;_0x4ffcd5<_0x571c6b['length'];_0x4ffcd5++){_0x54d6bf[_0x19e64c('0x66')](db[_0x19e64c('0x43')][_0x19e64c('0x19')]({'where':{'userProfileId':_0x542949['id'],'name':_0x571c6b[_0x4ffcd5][_0x19e64c('0x7f')]},'raw':!![]}));}return Promise['all'](_0x54d6bf);}})[_0x3717b1('0x16')](function(_0x23a14e){const _0x459ae4=_0x3717b1,_0x5f0609=_[_0x459ae4('0x82')](_0x23a14e,function(_0x3d6fbb){return _0x3d6fbb?_0x3d6fbb:undefined;}),_0x24f835=_[_0x459ae4('0x82')](_0x571c6b,[_0x459ae4('0x5d'),!![]]),_0x5a29af=_[_0x459ae4('0x9b')](_0x5f0609)&&_[_0x459ae4('0x9b')](_0x24f835)?null:_[_0x459ae4('0x6d')](_0x24f835,_0x5f0609);if(_0x5a29af){const _0x2386d1=[];for(let _0x5011b6=0x0;_0x5011b6<_0x5a29af[_0x459ae4('0xba')];_0x5011b6++){const _0x592f75=_[_0x459ae4('0xb1')](_0x571c6b,function(_0x5d9ead){const _0x2a51de=_0x459ae4;return _0x5a29af[_0x5011b6]?_0x5d9ead['name']===_0x5a29af[_0x5011b6][_0x2a51de('0x7f')]:null;});_0x592f75&&(_0x5a29af[_0x5011b6][_0x459ae4('0x5d')]?_0x2386d1['push'](getAllResources(_0x2157e2[_0x459ae4('0xbc')],_0x5a29af[_0x5011b6])):!_0x5a29af[_0x5011b6][_0x459ae4('0x7b')]?_0x2386d1[_0x459ae4('0x66')](getAllowedResources(_0x592f75,_0x5a29af[_0x5011b6],_0x2157e2['childModel'])):_0x592f75[_0x459ae4('0xaa')]&&_0x2386d1['push'](getAllFilteredResources(_0x592f75,_0x5a29af[_0x5011b6])));}return Promise[_0x459ae4('0x8a')](_0x2386d1);}else return null;})[_0x3717b1('0x16')](function(_0xd0f4a5){const _0x2b8aa7=_0x3717b1,_0xf642b6=_0xd0f4a5;let _0x337fae=null;_0xf642b6&&(_0x337fae=_0xf642b6[_0x2b8aa7('0xba')]===0x1?_0xf642b6[0x0]:null);if(_0x337fae||_0xf642b6){const _0xaa06af=db[_0x2157e2[_0x2b8aa7('0xbc')]][_0x2b8aa7('0x3e')];_0x51cbf0[_0x2b8aa7('0xaa')]=_['keys'](_0xaa06af),_0x51cbf0[_0x2b8aa7('0xcf')]=_[_0x2b8aa7('0x39')](_0x1747b7['query']),_0x51cbf0[_0x2b8aa7('0x4a')]=_[_0x2b8aa7('0x50')](_0x51cbf0[_0x2b8aa7('0xaa')],_0x51cbf0[_0x2b8aa7('0xcf')]),_0x15b24c[_0x2b8aa7('0x95')]=_[_0x2b8aa7('0x50')](_0x51cbf0[_0x2b8aa7('0xaa')],qs[_0x2b8aa7('0x42')](_0x1747b7[_0x2b8aa7('0xcf')][_0x2b8aa7('0x42')])),_0x15b24c[_0x2b8aa7('0x95')]=_0x15b24c[_0x2b8aa7('0x95')][_0x2b8aa7('0xba')]?_0x15b24c[_0x2b8aa7('0x95')]:_0x51cbf0[_0x2b8aa7('0xaa')];typeof _0x1747b7[_0x2b8aa7('0xcf')][_0x2b8aa7('0x3a')]==='undefined'&&(_0x15b24c[_0x2b8aa7('0xcc')]=qs[_0x2b8aa7('0xcc')](_0x1747b7[_0x2b8aa7('0xcf')]['limit']),_0x15b24c[_0x2b8aa7('0x1c')]=qs[_0x2b8aa7('0x1c')](_0x1747b7['query']['offset']));_0x15b24c[_0x2b8aa7('0x2a')]=qs['sort'](_0x1747b7[_0x2b8aa7('0xcf')][_0x2b8aa7('0xa0')]),_0x15b24c[_0x2b8aa7('0xac')]=qs['filters'](_[_0x2b8aa7('0xb6')](_0x1747b7[_0x2b8aa7('0xcf')],_0x51cbf0[_0x2b8aa7('0x4a')]));_0x1747b7['query']['filter']&&(_0x15b24c[_0x2b8aa7('0xac')]=_[_0x2b8aa7('0x83')](_0x15b24c[_0x2b8aa7('0xac')],{[Op['or']]:_[_0x2b8aa7('0x24')](_0xaa06af,function(_0x2a778e){const _0x20acc6=_0x2b8aa7;if(_0x2a778e[_0x20acc6('0x4d')]['key']!==_0x20acc6('0x1b')){const _0x2069ae={};return _0x2069ae[_0x2a778e['field']]={[Op[_0x20acc6('0x55')]]:'%'+_0x1747b7['query']['filter']+'%'},_0x2069ae;}})}));const _0xca4739=[];if(_0x337fae){const _0x4dfa2d=_[_0x2b8aa7('0xb1')](_0x571c6b,[_0x2b8aa7('0x7f'),_0x337fae[_0x2b8aa7('0x7f')]]);if(_0x4dfa2d[_0x2b8aa7('0x5c')]){const _0x108aa3={};_0x2157e2[_0x2b8aa7('0xbc')]===_0x2b8aa7('0x12')?_0x108aa3[_0x4dfa2d[_0x2b8aa7('0x91')]]=_[_0x2b8aa7('0x24')](_0x337fae['associatedResources'],'id'):_0x108aa3[_0x4dfa2d['foreignKey']]=_0x337fae[_0x2b8aa7('0x63')],_0xca4739['push'](_0x108aa3);}else _0x15b24c[_0x2b8aa7('0xac')]['id']=_0x337fae['associatedResources'];}else for(let _0x58a3dc=0x0;_0x58a3dc<_0xf642b6[_0x2b8aa7('0xba')];_0x58a3dc++){const _0x321246=_[_0x2b8aa7('0xb1')](_0x571c6b,[_0x2b8aa7('0x7f'),_0xf642b6[_0x58a3dc]['name']]);if(_0x321246['field']){const _0x28e10f={};_0x28e10f[_0x321246['foreignKey']]=_0xf642b6[_0x58a3dc][_0x2b8aa7('0x63')],_0xca4739[_0x2b8aa7('0x66')](_0x28e10f);}else{if(!_0x15b24c['where']['id'])_0x15b24c['where']['id']=[];_0xf642b6[_0x58a3dc][_0x2b8aa7('0x63')][_0x2b8aa7('0x1e')](function(_0x184185){_0x15b24c['where']['id']['push'](_0x184185);});}}return!_[_0x2b8aa7('0x9b')](_0xca4739)&&(_0x15b24c[_0x2b8aa7('0xac')]=_['merge'](_0x15b24c['where'],{[Op['and']]:{[Op['or']]:_0xca4739}})),_0x15b24c=_[_0x2b8aa7('0x83')]({},_0x15b24c,_0x1747b7[_0x2b8aa7('0x1')]),_0x337fae&&!_0x337fae[_0x2b8aa7('0x7b')]&&_0x2157e2['childModel']===_0x2b8aa7('0x12')?(_0x1747b7[_0x2b8aa7('0xcf')][_0x2b8aa7('0x5a')]&&(_0x15b24c[_0x2b8aa7('0x28')]=[{'all':!![]}]),db[_0x2157e2[_0x2b8aa7('0xbc')]]['findAll'](_0x15b24c)[_0x2b8aa7('0x16')](function(_0xcf94c5){const _0x141f9a=_0x2b8aa7,_0x18a554=[];return _0xcf94c5[_0x141f9a('0x1e')](function(_0x51f9a2){const _0x11d0f6=_0x141f9a;let _0xd4cf77;switch(_0x51f9a2[_0x11d0f6('0x72')]){case'default':_0xd4cf77=_[_0x11d0f6('0xb1')](_0x337fae[_0x11d0f6('0x63')],function(_0x43a694){const _0x43b1f6=_0x11d0f6;return _0x43a694['id']===_0x51f9a2[_0x43b1f6('0xab')]&&_0x43a694[_0x43b1f6('0x4d')]===_0x43b1f6('0xca');});break;case _0x11d0f6('0x68'):_0xd4cf77=_[_0x11d0f6('0xb1')](_0x337fae[_0x11d0f6('0x63')],function(_0x1d69b3){const _0x2eef53=_0x11d0f6;return _0x1d69b3['id']===_0x51f9a2[_0x2eef53('0xab')]&&_0x1d69b3[_0x2eef53('0x4d')]===_0x2eef53('0x54');});break;}if(_0xd4cf77)_0x18a554['push'](_0x51f9a2);}),_0x45a51b[_0x141f9a('0x62')]=_0x18a554[_0x141f9a('0xba')],_0x45a51b[_0x141f9a('0x8e')]=_0x18a554,_0x45a51b;})):db[_0x2157e2[_0x2b8aa7('0xbc')]][_0x2b8aa7('0x62')]({'where':_0x15b24c[_0x2b8aa7('0xac')]})[_0x2b8aa7('0x16')](function(_0x2bf337){const _0x1d618e=_0x2b8aa7;return _0x45a51b[_0x1d618e('0x62')]=_0x2bf337,_0x1747b7[_0x1d618e('0xcf')]['includeAll']&&(_0x2157e2['childModel']==='CmContact'?_0x15b24c[_0x1d618e('0x28')]=[{'model':db['Tag'],'as':_0x1d618e('0x8c'),'attributes':['id','name',_0x1d618e('0x8')],'required':_0x1747b7['query'][_0x1d618e('0x2c')]?!![]:![]},{'model':db[_0x1d618e('0x6e')],'as':_0x1d618e('0x86'),'attributes':['id',_0x1d618e('0x7f'),'color'],'through':_0x1747b7[_0x1d618e('0xcf')]['tag']?{'attributes':[],'where':{'TagId':_0x1747b7[_0x1d618e('0xcf')][_0x1d618e('0x2c')]||undefined}}:{},'required':_0x1747b7[_0x1d618e('0xcf')][_0x1d618e('0x2c')]?!![]:![]}]:_0x15b24c[_0x1d618e('0x28')]=[{'all':!![]}]),db[_0x2157e2[_0x1d618e('0xbc')]][_0x1d618e('0xb9')](_0x15b24c);})[_0x2b8aa7('0x16')](function(_0xb817c6){return _0x45a51b['rows']=_0xb817c6,_0x45a51b;});}else return _0x45a51b;})[_0x3717b1('0x16')](respondWithFilteredResult(_0x4b908b,_0x15b24c))[_0x3717b1('0x74')](handleError(_0x4b908b,null));};function getAllResources(_0x1ec7e1,_0x6335a6){return new Promise(function(_0xf06bde,_0x52b998){const _0x2bf7dc=a667_0x4986;if(_0x6335a6){const _0x48e2cd=_0x6335a6[_0x2bf7dc('0x82')]?{[_0x6335a6[_0x2bf7dc('0x82')]['field']]:_0x6335a6['filter'][_0x2bf7dc('0x67')]}:undefined;return db[_0x1ec7e1]['findAll']({'where':_0x48e2cd,'raw':!![]})[_0x2bf7dc('0x16')](function(_0x4de5ac){const _0x5e6c9b=_0x2bf7dc;_0x6335a6[_0x5e6c9b('0x63')]=_['map'](_0x4de5ac,'id'),_0xf06bde(_0x6335a6);})[_0x2bf7dc('0x74')](function(_0x2bfbca){_0x52b998(_0x2bfbca);});}else _0xf06bde(null);});}function getAllFilteredResources(_0x3c77cd,_0x405918){return new Promise(function(_0x459ecf,_0x3182e8){const _0x9b0196=a667_0x4986,_0x10b629=_0x3c77cd[_0x9b0196('0x82')]?{[_0x3c77cd[_0x9b0196('0x82')][_0x9b0196('0x5c')]]:_0x3c77cd[_0x9b0196('0x82')][_0x9b0196('0x67')]}:undefined;return db[_0x3c77cd[_0x9b0196('0xaa')]][_0x9b0196('0xb9')]({'where':_0x10b629,'raw':!![]})[_0x9b0196('0x16')](function(_0x86eb1b){_0x405918['associatedResources']=_['map'](_0x86eb1b,function(_0x15c88f){const _0x5d0efd=a667_0x4986;return _0x15c88f[_0x5d0efd('0x7f')];}),_0x459ecf(_0x405918);})[_0x9b0196('0x74')](function(_0x1e1577){_0x3182e8(_0x1e1577);});});}function getAllowedResources(_0x23e813,_0x455ff0,_0x5a2738){return new Promise(function(_0x1af823,_0x3c9ed5){const _0x3e3e01=a667_0x4986;if(_0x455ff0)return db[_0x3e3e01('0x4f')][_0x3e3e01('0xb9')]({'where':{'sectionId':_0x455ff0['id']},'raw':!![]})[_0x3e3e01('0x16')](function(_0xd11642){const _0x4f94fc=_0x3e3e01;_0x23e813[_0x4f94fc('0x5c')]&&_0x23e813[_0x4f94fc('0x5c')]!=='id'?_0x455ff0[_0x4f94fc('0x63')]=_[_0x4f94fc('0x24')](_0xd11642,function(_0x405142){return _0x405142[_0x23e813['field']];}):_0x5a2738===_0x4f94fc('0x12')?_0x455ff0[_0x4f94fc('0x63')]=_[_0x4f94fc('0x24')](_0xd11642,function(_0x5c3073){const _0x28277a=_0x4f94fc;return{'id':_0x5c3073[_0x28277a('0x9f')],'type':_0x5c3073[_0x28277a('0x4d')]};}):_0x455ff0[_0x4f94fc('0x63')]=_[_0x4f94fc('0x24')](_0xd11642,function(_0x390f92){const _0x8a6162=_0x4f94fc;return _0x390f92[_0x8a6162('0x9f')];}),_0x1af823(_0x455ff0);})[_0x3e3e01('0x74')](function(_0x50530d){_0x3c9ed5(_0x50530d);});else _0x1af823(null);});}function getQueryModels(_0x22c405,_0x2e8a4e){const _0x4489fd=_0x5837ab,_0x1eee7b=_0x22c405['toLowerCase'](),_0x5495ac={'childModel':undefined,'parentSections':[]};switch(_0x1eee7b){case _0x4489fd('0xc0'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x27');break;case _0x4489fd('0x8d'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x1a');break;case _0x4489fd('0xbf'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x2b'),_0x5495ac[_0x4489fd('0x79')]=[{'name':'SquareProjects','field':_0x4489fd('0x7f'),'foreignKey':_0x4489fd('0x49')}];break;case _0x4489fd('0x7'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x84');break;case _0x4489fd('0x25'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xd0'),_0x5495ac[_0x4489fd('0x79')]=[{'name':_0x4489fd('0xaf'),'field':'id','foreignKey':'ListId'}];break;case _0x4489fd('0x23'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xc2');break;case _0x4489fd('0x1f'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xa3');break;case _0x4489fd('0xb'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x6');break;case _0x4489fd('0xd'):_0x5495ac['childModel']='ChatQueue';break;case _0x4489fd('0x2e'):_0x5495ac[_0x4489fd('0xbc')]='ChatWebsite';break;case _0x4489fd('0x11'):_0x5495ac['childModel']='FaxQueue';break;case'faxaccounts':_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xa6');break;case _0x4489fd('0x41'):case _0x4489fd('0x2d'):case _0x4489fd('0x8b'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x73');break;case'contexts':_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xc8');break;case _0x4489fd('0x9c'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x59');break;case _0x4489fd('0xa8'):_0x5495ac['childModel']=_0x4489fd('0x4b'),_0x5495ac['parentSections']=[{'name':'Agents','field':_0x4489fd('0x7f'),'foreignKey':'membername','model':'User','filter':{'field':_0x4489fd('0xb5'),'value':[_0x4489fd('0x7d')]}},{'name':'Telephones','field':'name','foreignKey':'membername','model':_0x4489fd('0xad'),'filter':{'field':'role','value':[_0x4489fd('0x85')]}},{'name':_0x4489fd('0x88'),'field':'name','foreignKey':_0x4489fd('0x94'),'model':_0x4489fd('0xa9'),'filter':{'field':'type','value':['inbound']}},{'name':_0x4489fd('0x37'),'field':_0x4489fd('0x7f'),'foreignKey':_0x4489fd('0x94'),'model':_0x4489fd('0xa9'),'filter':{'field':_0x4489fd('0x4d'),'value':['outbound']}}];break;case _0x4489fd('0x29'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xf');break;case _0x4489fd('0x15'):_0x5495ac['childModel']=_0x4489fd('0x44');break;case _0x4489fd('0x22'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x70');break;case _0x4489fd('0x31'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xc6');break;case _0x4489fd('0x90'):_0x5495ac['childModel']='MailQueue';break;case'mailaccounts':_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xb8');break;case _0x4489fd('0x7a'):_0x5495ac[_0x4489fd('0xbc')]='MailSubstatus';break;case'openchannelqueues':_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x9');break;case _0x4489fd('0x5e'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x57');break;case'smsqueues':_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x58');break;case _0x4489fd('0x61'):_0x5495ac['childModel']='SmsAccount';break;case _0x4489fd('0x32'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x17');break;case _0x4489fd('0x46'):_0x5495ac[_0x4489fd('0xbc')]='WhatsappAccount';break;case _0x4489fd('0x1d'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xc1');break;case'voicequeues':case _0x4489fd('0x47'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xa9');_0x2e8a4e&&(_0x5495ac['parentSections']=[{'name':_0x4489fd('0x88')},{'name':_0x4489fd('0x37')}]);break;case _0x4489fd('0x3c'):case _0x4489fd('0x10'):case _0x4489fd('0xae'):_0x5495ac[_0x4489fd('0xbc')]='User';_0x2e8a4e&&(_0x5495ac['parentSections']=[{'name':'Users','filter':{'field':_0x4489fd('0xb5'),'value':[_0x4489fd('0xc3'),_0x4489fd('0x5b')]},'ignore':!![]},{'name':_0x4489fd('0x4c')},{'name':_0x4489fd('0x3b')}]);break;case'zendeskaccounts':_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xb3');break;case _0x4489fd('0x13'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xb2');break;case _0x4489fd('0x34'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x3');break;case _0x4489fd('0x75'):_0x5495ac['childModel']=_0x4489fd('0x52');break;case'deskaccounts':_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xbe');break;case _0x4489fd('0x5f'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x9a');break;case _0x4489fd('0x53'):_0x5495ac[_0x4489fd('0xbc')]='User';break;case'cannedanswers':_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xa');break;case _0x4489fd('0x80'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x93');break;case _0x4489fd('0x92'):_0x5495ac[_0x4489fd('0xbc')]='Dashboard';break;case _0x4489fd('0xce'):_0x5495ac['childModel']=_0x4489fd('0x6b');break;case'pauses':_0x5495ac['childModel']='Pause';break;case _0x4489fd('0xa1'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x3d');break;case _0x4489fd('0x9d'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x98');break;case _0x4489fd('0x60'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x6e');break;case _0x4489fd('0x65'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x76');break;case _0x4489fd('0xc7'):_0x5495ac[_0x4489fd('0xbc')]='Trigger';break;case _0x4489fd('0x96'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0x78');break;case'variables':_0x5495ac['childModel']=_0x4489fd('0xa7');break;case'plugins':_0x5495ac['childModel']=_0x4489fd('0xbd');break;case _0x4489fd('0x69'):_0x5495ac['childModel']=_0x4489fd('0x12'),_0x5495ac[_0x4489fd('0x79')]=[{'name':_0x4489fd('0xa2'),'field':'id','foreignKey':_0x4489fd('0xab')}];break;case _0x4489fd('0x45'):_0x5495ac[_0x4489fd('0xbc')]=_0x4489fd('0xa4');break;default:return _0x5495ac;}return _0x5495ac;} \ No newline at end of file +const a667_0x3133=['mailsubstatuses','Dashboard','keys','CmCompany','filter','status','inbound','include','voiceprefixes','CannedAnswer','MailQueue','zendeskaccounts','destroy','VoiceContext','get','show','internalroutes','all','Invalid\x20section\x20\x27','sectionId','intersection','squareprojects','pick','VoiceExtension','attributes','filters','voicemails','union','MailSubstatus','query','params','contexts','push','name','SquareProjects','projectName','findOne','CmContact','faxqueues','error','mergeResources','SquareProject','AnalyticExtractedReport','agents','color','clone','squarerecordings','Pause','like','VoiceMusicOnHold','cannedanswers','end','voicequeues','FaxQueue','outbound','includeAll','getSections','tags','user','DeskAccount','ids','nolimit','User','VoicePrefix','removeResources','sort','Telephones','where','mailqueues','globalcustomfields','templates','variables','triggers','rows','isEmpty','enabled','chatwebsites','api','ZendeskAccount','teams','forEach','VoiceQueues','AnalyticMetric','default','faxaccounts','update','stack','contacts','CustomReports','UserProfile','Disposition','lodash','includes','offset','Trigger','value','Content-Range','membername','index','tag','Agents','removeSections','order','projects','register','voicerecordings','telephone','model','sugarcrmaccounts','catch','MailAccount','VoiceRecording','queue','parentSections','plugins','options','merge','zohoaccounts','Interval','reportType','addSections','Unknown\x20section','reportId','then','../../config/logger','json','smsqueues','customdashboards','omit','trunks','undefined','body','../../mysqldb','userProfileId','Tags','ChatQueue','key','OpenchannelAccount','Template','find','resourceId','SquareRecording','map','freshdeskaccounts','type','length','FaxAccount','SmsQueue','Variable','admin','extractedreports','users','crudPermissions','ivrcampaigns','VoiceQueue','rawAttributes','subsections','Team','agent','bulkCreate','getResources','Resources','VoiceMail','Schedule','VIRTUAL','UserProfileSection','smsaccounts','create','and','WhatsappQueue','associatedResources','toLowerCase','sendStatus','each','FreshdeskAccount','transaction','SquareOdbc','findAll','lists','UserProfileResource','OpenchannelQueue','ignore','foreignKey','metrics','SmsAccount','childModel','field','SugarcrmAccount','Trunk','musiconholds','QueueCampaigns','count','CmList','inboundroutes','Plugin','ListId','autoAssociation','telephones','Lists','set','ChatWebsite','Campaign','sequelize','chanspies','describe','section','openchannelaccounts','role','updatedAt','whatsappaccounts','DefaultReports','Users','Tag','vtigeraccounts','companies','fields','JscriptyProject','WhatsappAccount','chatqueues','createdAt','limit','../../components/parsers/qs','custom'];(function(_0x311c21,_0x3133e0){const _0x15d43c=function(_0x1a01bd){while(--_0x1a01bd){_0x311c21['push'](_0x311c21['shift']());}};_0x15d43c(++_0x3133e0);}(a667_0x3133,0xb0));const a667_0x15d4=function(_0x311c21,_0x3133e0){_0x311c21=_0x311c21-0x0;let _0x15d43c=a667_0x3133[_0x311c21];return _0x15d43c;};const _0x18d5a8=a667_0x15d4;'use strict';const _=require(_0x18d5a8('0x8a')),qs=require(_0x18d5a8('0x2d')),logger=require(_0x18d5a8('0xab'))(_0x18d5a8('0x7c')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x18d5a8('0xb3'))['db'],{Op,ValidationError}=require(_0x18d5a8('0x1a'));require('./userProfile.socket')[_0x18d5a8('0x97')](socket);function respondWithStatusCode(_0x1a01bd,_0x2975cf){return _0x2975cf=_0x2975cf||0xcc,function(_0x4a4168){const _0x1cbb5a=a667_0x15d4;if(_0x4a4168)return _0x1a01bd[_0x1cbb5a('0xdb')](_0x2975cf);return _0x1a01bd[_0x1cbb5a('0x34')](_0x2975cf)[_0x1cbb5a('0x62')]();};}function respondWithResult(_0x22dca4,_0x24b343){return _0x24b343=_0x24b343||0xc8,function(_0x594bc1){if(_0x594bc1)return _0x22dca4['status'](_0x24b343)['json'](_0x594bc1);};}function respondWithFilteredResult(_0x3553f8,_0x29c29a){return function(_0x14f4e6){const _0x26942b=a667_0x15d4;if(_0x14f4e6){const _0x39716c=_0x14f4e6['count'],_0x343ac0=_0x29c29a[_0x26942b('0x8c')];let _0xf75146=_0x29c29a['offset']+_0x29c29a['limit'],_0x2b4d37;return _0xf75146>=_0x39716c?(_0xf75146=_0x39716c,_0x2b4d37=0xc8):_0x2b4d37=0xce,_0x3553f8[_0x26942b('0x34')](_0x2b4d37),_0x3553f8[_0x26942b('0x17')](_0x26942b('0x8f'),_0x343ac0+'-'+_0xf75146+'/'+_0x39716c)[_0x26942b('0xac')](_0x14f4e6);}return null;};}function saveUpdates(_0x341399){return function(_0x5327cd){const _0x2aea41=a667_0x15d4;if(_0x5327cd)return _0x5327cd['update'](_0x341399)[_0x2aea41('0xaa')](function(_0x17da8b){return _0x17da8b;});return null;};}function removeEntity(_0x7bc099){return function(_0x584381){const _0x41d277=a667_0x15d4;if(_0x584381)return _0x584381[_0x41d277('0x3b')]()['then'](function(){const _0x46738b=_0x41d277;_0x7bc099['status'](0xcc)[_0x46738b('0x62')]();});};}function handleEntityNotFound(_0x212ea1){return function(_0x80e654){const _0x36bc3d=a667_0x15d4;return!_0x80e654&&_0x212ea1[_0x36bc3d('0xdb')](0x194),_0x80e654;};}function handleError(_0x354265,_0x11f81e){return _0x11f81e=_0x11f81e||0x1f4,function(_0x9559b1){const _0x3d2d8b=a667_0x15d4;logger[_0x3d2d8b('0x56')](_0x9559b1[_0x3d2d8b('0x85')]),_0x9559b1[_0x3d2d8b('0x50')]&&delete _0x9559b1[_0x3d2d8b('0x50')],_0x354265[_0x3d2d8b('0x34')](_0x11f81e)['send'](_0x9559b1);};}exports[_0x18d5a8('0x91')]=function(_0x478335,_0x4d9470){const _0x416c9b=_0x18d5a8;let _0x2a59aa={};const _0x4fd915={},_0x2f3024={'count':0x0,'rows':[]},_0x4c9b68=_['map'](db[_0x416c9b('0x88')][_0x416c9b('0xca')],function(_0xa20238){const _0x533de5=_0x416c9b;return{'name':_0xa20238['fieldName'],'type':_0xa20238[_0x533de5('0xbf')][_0x533de5('0xb7')]};});_0x4fd915[_0x416c9b('0x9a')]=_['map'](_0x4c9b68,_0x416c9b('0x50')),_0x4fd915['query']=_[_0x416c9b('0x31')](_0x478335['query']),_0x4fd915[_0x416c9b('0x48')]=_[_0x416c9b('0x43')](_0x4fd915[_0x416c9b('0x9a')],_0x4fd915[_0x416c9b('0x4c')]),_0x2a59aa[_0x416c9b('0x47')]=_[_0x416c9b('0x43')](_0x4fd915[_0x416c9b('0x9a')],qs[_0x416c9b('0x27')](_0x478335[_0x416c9b('0x4c')][_0x416c9b('0x27')])),_0x2a59aa[_0x416c9b('0x47')]=_0x2a59aa[_0x416c9b('0x47')][_0x416c9b('0xc0')]?_0x2a59aa[_0x416c9b('0x47')]:_0x4fd915[_0x416c9b('0x9a')];typeof _0x478335['query']['nolimit']==='undefined'&&(_0x2a59aa[_0x416c9b('0x2c')]=qs['limit'](_0x478335[_0x416c9b('0x4c')][_0x416c9b('0x2c')]),_0x2a59aa[_0x416c9b('0x8c')]=qs[_0x416c9b('0x8c')](_0x478335[_0x416c9b('0x4c')][_0x416c9b('0x8c')]));_0x2a59aa[_0x416c9b('0x95')]=qs[_0x416c9b('0x70')](_0x478335[_0x416c9b('0x4c')]['sort']),_0x2a59aa['where']=qs[_0x416c9b('0x48')](_[_0x416c9b('0x45')](_0x478335[_0x416c9b('0x4c')],_0x4fd915[_0x416c9b('0x48')]),_0x4c9b68);_0x478335[_0x416c9b('0x4c')][_0x416c9b('0x33')]&&(_0x2a59aa[_0x416c9b('0x72')]=_[_0x416c9b('0xa3')](_0x2a59aa['where'],{[Op['or']]:_['map'](_0x4c9b68,function(_0x354291){const _0x534bf8=_0x416c9b;if(_0x354291['type']!==_0x534bf8('0xd3')){const _0x137449={};return _0x137449[_0x354291[_0x534bf8('0x50')]]={[Op[_0x534bf8('0x5f')]]:'%'+_0x478335['query'][_0x534bf8('0x33')]+'%'},_0x137449;}})}));_0x2a59aa=_[_0x416c9b('0xa3')]({},_0x2a59aa,_0x478335['options']);const _0x4ca84c={'where':_0x2a59aa[_0x416c9b('0x72')]};return db[_0x416c9b('0x88')][_0x416c9b('0xf')](_0x4ca84c)['then'](function(_0x3dd883){const _0x45ee5b=_0x416c9b;return _0x2f3024['count']=_0x3dd883,_0x478335[_0x45ee5b('0x4c')][_0x45ee5b('0x66')]&&(_0x2a59aa[_0x45ee5b('0x36')]=[{'all':!![]}]),db[_0x45ee5b('0x88')]['findAll'](_0x2a59aa);})[_0x416c9b('0xaa')](function(_0x2b53f4){return _0x2f3024['rows']=_0x2b53f4,_0x2f3024;})['then'](respondWithFilteredResult(_0x4d9470,_0x2a59aa))[_0x416c9b('0x9c')](handleError(_0x4d9470,null));},exports[_0x18d5a8('0x3e')]=function(_0x4ea14d,_0x32cc72){const _0x43939a=_0x18d5a8;let _0x15e6a9={'raw':![],'where':{'id':_0x4ea14d[_0x43939a('0x4d')]['id']}};const _0x293f73={};return _0x293f73['model']=_[_0x43939a('0x31')](db['UserProfile'][_0x43939a('0xca')]),_0x293f73[_0x43939a('0x4c')]=_[_0x43939a('0x31')](_0x4ea14d[_0x43939a('0x4c')]),_0x293f73[_0x43939a('0x48')]=_[_0x43939a('0x43')](_0x293f73[_0x43939a('0x9a')],_0x293f73[_0x43939a('0x4c')]),_0x15e6a9['attributes']=_[_0x43939a('0x43')](_0x293f73[_0x43939a('0x9a')],qs['fields'](_0x4ea14d[_0x43939a('0x4c')][_0x43939a('0x27')])),_0x15e6a9[_0x43939a('0x47')]=_0x15e6a9[_0x43939a('0x47')]['length']?_0x15e6a9['attributes']:_0x293f73['model'],_0x4ea14d['query'][_0x43939a('0x66')]&&(_0x15e6a9[_0x43939a('0x36')]=[{'all':!![]}]),_0x15e6a9=_[_0x43939a('0xa3')]({},_0x15e6a9,_0x4ea14d['options']),db[_0x43939a('0x88')]['findOne'](_0x15e6a9)[_0x43939a('0xaa')](handleEntityNotFound(_0x32cc72))[_0x43939a('0xaa')](respondWithResult(_0x32cc72,null))[_0x43939a('0x9c')](handleError(_0x32cc72,null));},exports[_0x18d5a8('0xd6')]=function(_0x31bc4e,_0x5797fd){const _0x31ee5b=_0x18d5a8;return db[_0x31ee5b('0x88')]['create'](_0x31bc4e['body'],{})[_0x31ee5b('0xaa')](respondWithResult(_0x5797fd,0xc9))[_0x31ee5b('0x9c')](handleError(_0x5797fd,null));},exports[_0x18d5a8('0x5c')]=function(_0x467bfe,_0x1088ee){const _0x4827e5=_0x18d5a8;let _0x29eb40={'where':{'id':_0x467bfe[_0x4827e5('0x4d')]['id']}};const _0x215ae7={};return _0x215ae7[_0x4827e5('0x9a')]=_[_0x4827e5('0x31')](db[_0x4827e5('0x88')]['rawAttributes']),_0x29eb40['attributes']=_[_0x4827e5('0x43')](_0x215ae7[_0x4827e5('0x9a')],qs[_0x4827e5('0x27')](_0x467bfe['query'][_0x4827e5('0x27')])),_0x29eb40[_0x4827e5('0x47')]=_0x29eb40['attributes']['length']?_0x29eb40['attributes']:_0x215ae7[_0x4827e5('0x9a')],_0x467bfe['query']['includeAll']&&(_0x29eb40['include']=[{'all':!![]}]),_0x29eb40=_['merge']({},_0x29eb40,_0x467bfe[_0x4827e5('0xa2')]),db[_0x4827e5('0x88')]['findOne'](_0x29eb40)[_0x4827e5('0xaa')](handleEntityNotFound(_0x1088ee))[_0x4827e5('0xaa')](function(_0x15eb11){const _0x194b8f=_0x4827e5;if(_0x15eb11){let _0x3d2e69=_0x15eb11['get']({'plain':!![]});return _0x3d2e69=qs[_0x194b8f('0xaf')](_0x3d2e69,['id','createdAt','updatedAt',_0x194b8f('0xc7')]),_0x467bfe['body']=_['omit'](_0x467bfe[_0x194b8f('0xb2')],['id','createdAt',_0x194b8f('0x20')]),db['sequelize'][_0x194b8f('0xde')](function(_0x2b18c3){const _0x3e7811=_0x194b8f;return db[_0x3e7811('0x88')][_0x3e7811('0xd6')](_['merge'](_0x3d2e69,_0x467bfe[_0x3e7811('0xb2')]),{'include':_0x467bfe[_0x3e7811('0x4c')][_0x3e7811('0x66')]?[{'all':!![]}]:undefined,'transaction':_0x2b18c3})[_0x3e7811('0xaa')](function(_0x3a0ba0){const _0x184d74=_0x3e7811,_0x5851be=_0x3a0ba0[_0x184d74('0x3d')]({'plain':!![]});return db[_0x184d74('0xd4')][_0x184d74('0x1')]({'where':{'userProfileId':_0x467bfe['params']['id']},'raw':!![]})[_0x184d74('0xaa')](function(_0xf2309b){const _0x535d96=_0x184d74;if(_0xf2309b)return Promise[_0x535d96('0xdc')](_0xf2309b,function(_0x2d1181){const _0x5aff4c=_0x535d96;return new Promise(function(_0x43afad,_0x164ed4){const _0x372076=a667_0x15d4;if(_0x2d1181[_0x372076('0x14')]===null||_0x2d1181[_0x372076('0x14')]===0x1)_0x43afad(null);return db[_0x372076('0x3')]['findAll']({'where':{'sectionId':_0x2d1181['id']},'raw':!![]})['then'](function(_0x5d2d7f){const _0x188a12=_['map'](_0x5d2d7f,function(_0x3ecc0e){const _0x521ffb=a667_0x15d4;return qs[_0x521ffb('0xaf')](_0x3ecc0e,['id','createdAt',_0x521ffb('0x20'),'sectionId']);});_0x43afad(_0x188a12);})['catch'](function(_0x347056){_0x164ed4(_0x347056);});})[_0x5aff4c('0xaa')](function(_0x187008){const _0x5f3591=_0x5aff4c,_0xbd40a7=qs[_0x5f3591('0xaf')](_0x2d1181,['id',_0x5f3591('0x2b'),_0x5f3591('0x20')]);_0xbd40a7['userProfileId']=_0x5851be['id'];if(_0x187008)_0xbd40a7['Resources']=_0x187008;return _0xbd40a7;})[_0x5aff4c('0xaa')](function(_0x337c10){const _0x577b29=_0x5aff4c;return db[_0x577b29('0xd4')]['create'](_0x337c10,{'include':[{'model':db['UserProfileResource'],'as':'Resources'}],'raw':!![],'transaction':_0x2b18c3});});})[_0x535d96('0xaa')](function(){return _0x5851be;});});});});}})[_0x4827e5('0xaa')](respondWithResult(_0x1088ee,0xc9))[_0x4827e5('0x9c')](handleError(_0x1088ee,null));},exports[_0x18d5a8('0x84')]=function(_0x197742,_0x585a75){const _0x1d0753=_0x18d5a8;return _0x197742['body']['id']&&delete _0x197742[_0x1d0753('0xb2')]['id'],db[_0x1d0753('0x88')][_0x1d0753('0x53')]({'where':{'id':_0x197742['params']['id']}})[_0x1d0753('0xaa')](handleEntityNotFound(_0x585a75))['then'](saveUpdates(_0x197742['body'],null))[_0x1d0753('0xaa')](respondWithResult(_0x585a75,null))[_0x1d0753('0x9c')](handleError(_0x585a75,null));},exports[_0x18d5a8('0x3b')]=function(_0x3bf933,_0x4133ae){const _0x515631=_0x18d5a8;return db['UserProfile'][_0x515631('0x53')]({'where':{'id':_0x3bf933['params']['id']}})[_0x515631('0xaa')](handleEntityNotFound(_0x4133ae))['then'](removeEntity(_0x4133ae,null))[_0x515631('0x9c')](handleError(_0x4133ae,null));},exports[_0x18d5a8('0x1c')]=function(_0x3793ce,_0x293a66){const _0x227006=_0x18d5a8;return db[_0x227006('0x88')][_0x227006('0x1c')]()[_0x227006('0xaa')](respondWithResult(_0x293a66,null))[_0x227006('0x9c')](handleError(_0x293a66,null));},exports[_0x18d5a8('0xa7')]=function(_0x1b1be4,_0xe0c50b){const _0x5a1f15=_0x18d5a8,_0x5ce4d3=_0x1b1be4[_0x5a1f15('0xb2')];return db[_0x5a1f15('0x88')]['findOne']({'where':{'id':_0x1b1be4['params']['id']}})[_0x5a1f15('0xaa')](handleEntityNotFound(_0xe0c50b))['then'](function(_0x373617){const _0x5c7156=_0x5a1f15;if(_0x373617)return db[_0x5c7156('0x1a')]['transaction'](function(_0x5acfba){const _0x37ad69=_0x5c7156;return db[_0x37ad69('0xd4')][_0x37ad69('0x3b')]({'where':{'userProfileId':_0x1b1be4[_0x37ad69('0x4d')]['id'],'sectionId':_[_0x37ad69('0xbd')](_0x5ce4d3,function(_0xa63406){const _0xca54d1=_0x37ad69;return _0xa63406[_0xca54d1('0x42')];})},'transaction':_0x5acfba})[_0x37ad69('0xaa')](function(){const _0x5009e8=_0x37ad69,_0xa02ea4=_['map'](_0x5ce4d3,function(_0x40c912){const _0x5cbb68=a667_0x15d4;return _0x40c912[_0x5cbb68('0xb4')]=_0x1b1be4[_0x5cbb68('0x4d')]['id'],_0x40c912;}),_0x1aa8b2=[];return Promise[_0x5009e8('0xdc')](_0xa02ea4,function(_0x397e0e){const _0x216f7e=_0x5009e8;return db[_0x216f7e('0xd4')][_0x216f7e('0xd6')](_0x397e0e,{'include':[{'model':db[_0x216f7e('0x3')],'as':_0x216f7e('0xd0')}],'raw':!![],'transaction':_0x5acfba})[_0x216f7e('0xaa')](function(_0x517dfd){const _0x56a66e=_0x216f7e;_0x1aa8b2['push'](_0x517dfd[_0x56a66e('0x3d')]({'plain':!![]}));});})[_0x5009e8('0xaa')](function(){return _0x1aa8b2;});});});})[_0x5a1f15('0xaa')](function(_0xa1f07e){return _0xa1f07e;})['then'](respondWithResult(_0xe0c50b,null))['catch'](handleError(_0xe0c50b,null));},exports[_0x18d5a8('0x94')]=function(_0xd9ed46,_0x266142){const _0x2c12b1=_0x18d5a8;let _0x47547c;return db[_0x2c12b1('0x88')][_0x2c12b1('0x53')]({'where':{'id':_0xd9ed46[_0x2c12b1('0x4d')]['id']},'attributes':['id',_0x2c12b1('0x50')]})[_0x2c12b1('0xaa')](handleEntityNotFound(_0x266142))['then'](function(_0x2a5f69){const _0x1c5c45=_0x2c12b1;if(_0x2a5f69)return _0x47547c=_0x2a5f69,db[_0x1c5c45('0xd4')][_0x1c5c45('0x3b')]({'where':{'userProfileId':_0xd9ed46[_0x1c5c45('0x4d')]['id'],'sectionId':_0xd9ed46[_0x1c5c45('0x4c')][_0x1c5c45('0x6b')]}});})[_0x2c12b1('0xaa')](function(){return _0x47547c;})[_0x2c12b1('0xaa')](respondWithStatusCode(_0x266142,null))[_0x2c12b1('0x9c')](handleError(_0x266142,null));},exports[_0x18d5a8('0x67')]=function(_0x24b1e2,_0x555f3d){const _0x3f1348=_0x18d5a8;let _0x4d1ad2=[],_0x1e8325=[];return db[_0x3f1348('0xd4')][_0x3f1348('0x1')]({'where':{'userProfileId':_0x24b1e2[_0x3f1348('0x4d')]['id']},'raw':!![]})[_0x3f1348('0xaa')](function(_0x57fa46){const _0x203507=_0x3f1348;_0x4d1ad2=_[_0x203507('0x33')](_0x57fa46,function(_0x59665a){const _0xb39aba=_0x203507;return _0x59665a['enabled']===0x1||_['includes']([0x3eb,0x709],_0x59665a[_0xb39aba('0x42')]);});if(!_[_0x203507('0x79')](_0x4d1ad2))return _[_0x203507('0xbd')](_0x4d1ad2,function(_0x5ae944){const _0x1e6e43=_0x203507;return _0x5ae944[_0x1e6e43('0x42')];});else return;})[_0x3f1348('0xaa')](function(_0x3b6f4b){const _0x48cff6=_0x3f1348;if(_0x3b6f4b)_0x1e8325=_0x3b6f4b;if(_[_0x48cff6('0x8b')](_0x1e8325,0x64)){const _0x4a95ad=_[_0x48cff6('0xba')](_0x4d1ad2,{'sectionId':0x64});return hasDefaultDashboard(_0x4a95ad)['then'](function(_0x2ee4da){const _0x3bd1dd=_0x48cff6;return _[_0x3bd1dd('0xbd')](_0x4d1ad2,function(_0x36e132){const _0xaf6bc1=_0x3bd1dd;return _0x36e132[_0xaf6bc1('0x42')]===0x64&&(_0x36e132['subsections']=_0x2ee4da),_0x36e132;});});}else return;})['then'](function(_0x3b85ed){const _0x3771d5=_0x3f1348;if(_0x3b85ed)_0x4d1ad2=_0x3b85ed;if(_['includes'](_0x1e8325,0x3eb)){const _0xabb501=_['find'](_0x4d1ad2,{'sectionId':0x3eb});return getCustomDashboards(_0xabb501)[_0x3771d5('0xaa')](function(_0x282468){return _['map'](_0x4d1ad2,function(_0x2ac4e2){const _0x56e388=a667_0x15d4;return _0xabb501[_0x56e388('0x7a')]?_0x2ac4e2[_0x56e388('0x42')]===0x3eb&&(_0x2ac4e2[_0x56e388('0xcb')]=_0x282468):_0x2ac4e2['sectionId']===0x64&&(_0x2ac4e2['subsections']=_0x282468),_0x2ac4e2;});});}else return;})[_0x3f1348('0xaa')](function(_0x45cd7a){const _0x3780c8=_0x3f1348;if(_0x45cd7a)_0x4d1ad2=_0x45cd7a;if(_[_0x3780c8('0x8b')](_0x1e8325,0x709)){const _0x5bce39=_[_0x3780c8('0xba')](_0x4d1ad2,{'sectionId':0x709});return getPlugins(_0x5bce39)['then'](function(_0x38f176){const _0x198c19=_0x3780c8;if(_0x5bce39[_0x198c19('0x7a')])return _[_0x198c19('0xbd')](_0x4d1ad2,function(_0x3a90fd){const _0x590a07=_0x198c19;return _0x3a90fd[_0x590a07('0x42')]===0x709&&(_0x3a90fd[_0x590a07('0xcb')]=_0x38f176),_0x3a90fd;});else{const _0x532661={'sectionId':0x76c,'enabled':0x1,'subsections':_0x38f176},_0x3240b9=_[_0x198c19('0xbd')](_0x4d1ad2);return _0x3240b9[_0x198c19('0x4f')](_0x532661),_0x3240b9;}});}else return;})[_0x3f1348('0xaa')](function(_0x5d61c0){const _0x49fd66=_0x3f1348;if(_0x5d61c0)_0x4d1ad2=_0x5d61c0;return _[_0x49fd66('0x33')](_0x4d1ad2,[_0x49fd66('0x7a'),0x1]);})[_0x3f1348('0xaa')](respondWithResult(_0x555f3d,null))[_0x3f1348('0x9c')](handleError(_0x555f3d,null));};function hasDefaultDashboard(_0x2c7d3d){const _0x43d8ac=[0x65];return new Promise(function(_0x1444b9,_0x26a0c3){const _0x1f8ef7=a667_0x15d4;try{if(_0x2c7d3d[_0x1f8ef7('0x14')])_0x1444b9(_0x43d8ac);else return db[_0x1f8ef7('0x3')][_0x1f8ef7('0x53')]({'where':{'sectionId':_0x2c7d3d['id']},'raw':!![]})[_0x1f8ef7('0xaa')](function(_0xd2806e){_0xd2806e?_0x1444b9(_0x43d8ac):_0x1444b9();});}catch(_0x5eb1f2){_0x26a0c3(_0x5eb1f2);}});}function getCustomDashboards(_0x4aa54f){const _0x294600=[];return new Promise(function(_0x142869,_0x4ecad3){const _0xe90e32=a667_0x15d4;try{return _0x4aa54f['autoAssociation']?db['Dashboard'][_0xe90e32('0x1')]({'raw':!![]})[_0xe90e32('0xaa')](function(_0x1f7b04){const _0x48193c=_0xe90e32;_0x1f7b04[_0x48193c('0x7f')](function(_0x25deb2){const _0x3a8906=_0x48193c;_0x294600[_0x3a8906('0x4f')](_0x25deb2['id']+0x1869f);}),_0x142869(_0x294600);}):db[_0xe90e32('0x3')][_0xe90e32('0x1')]({'where':{'sectionId':_0x4aa54f['id']},'raw':!![]})['then'](function(_0x14ec9d){const _0x6e8dd=_0xe90e32;_0x14ec9d[_0x6e8dd('0x7f')](function(_0x50549c){const _0x2d47a8=_0x6e8dd;_0x294600[_0x2d47a8('0x4f')](_0x50549c['resourceId']+0x1869f);}),_0x142869(_0x294600);});}catch(_0x48d23e){_0x4ecad3(_0x48d23e);}});}function getPlugins(_0xa8bb46){const _0x3ebb43=[];return new Promise(function(_0x2063aa,_0x5a6df6){const _0x154a3e=a667_0x15d4;try{return _0xa8bb46[_0x154a3e('0x14')]?db[_0x154a3e('0x12')][_0x154a3e('0x1')]({'raw':!![]})['then'](function(_0xb60c25){const _0x2faff5=_0x154a3e;_0xb60c25[_0x2faff5('0x7f')](function(_0x32cfe9){const _0x1f0b80=_0x2faff5;_0x3ebb43[_0x1f0b80('0x4f')](_0x32cfe9['id']+0x15b38);}),_0x2063aa(_0x3ebb43);}):db[_0x154a3e('0x3')]['findAll']({'where':{'sectionId':_0xa8bb46['id']},'raw':!![]})[_0x154a3e('0xaa')](function(_0x13865a){const _0x44960c=_0x154a3e;_0x13865a[_0x44960c('0x7f')](function(_0x34d234){const _0x9ead24=_0x44960c;_0x3ebb43[_0x9ead24('0x4f')](_0x34d234['resourceId']+0x15b38);}),_0x2063aa(_0x3ebb43);});}catch(_0x10dc97){_0x5a6df6(_0x10dc97);}});}exports['addResources']=function(_0x81f5cb,_0x389406){const _0x1bb093=_0x18d5a8;return db[_0x1bb093('0x88')][_0x1bb093('0x53')]({'where':{'id':_0x81f5cb[_0x1bb093('0x4d')]['id']}})['then'](handleEntityNotFound(_0x389406))[_0x1bb093('0xaa')](function(_0x7b8cfc){const _0x482539=_0x1bb093;if(_0x7b8cfc)return db[_0x482539('0x1a')][_0x482539('0xde')](function(_0x24dfbe){const _0x432707=_0x482539;return db['UserProfileSection'][_0x432707('0x1')]({'where':{'userProfileId':_0x81f5cb[_0x432707('0x4d')]['id']},'attributes':['id'],'raw':!![]})['then'](function(_0x1a2553){const _0x1cc32b=_0x432707;if(_0x1a2553)return db[_0x1cc32b('0xd4')][_0x1cc32b('0x3b')]({'where':{'userProfileId':_0x81f5cb[_0x1cc32b('0x4d')]['id'],'id':_['map'](_0x1a2553,function(_0x58b6c9){return _0x58b6c9['id'];})},'transaction':_0x24dfbe});})[_0x432707('0xaa')](function(){const _0x5a32dd=_0x432707,_0xa49d3f=_[_0x5a32dd('0xbd')](_0x81f5cb[_0x5a32dd('0xb2')],function(_0x4229a0){const _0x44d403=_0x5a32dd;return _0x4229a0[_0x44d403('0xb4')]=_0x81f5cb[_0x44d403('0x4d')]['id'],_0x4229a0;});return db[_0x5a32dd('0xd4')][_0x5a32dd('0xce')](_0xa49d3f,{'raw':!![],'transaction':_0x24dfbe});})[_0x432707('0xaa')](function(_0x2849a8){const _0xe87368=_0x432707,_0x5c936c=_['filter'](_[_0xe87368('0xbd')](_0x2849a8,function(_0x252410){return _0x252410['get']({'plain':!![]});}),{'includeAll':![]});if(_0x5c936c)return db['UserProfileSection'][_0xe87368('0x1')]({'where':{'userProfileId':_0x81f5cb[_0xe87368('0x4d')]['id'],'sectionId':_['map'](_0x5c936c,function(_0x1ed1b6){const _0x3f3291=_0xe87368;return _0x1ed1b6[_0x3f3291('0x42')];})},'attributes':['id',_0xe87368('0x42')],'raw':!![]})[_0xe87368('0xaa')](function(){const _0x3bf7a2=_0xe87368,_0x25abaf=_[_0x3bf7a2('0xbd')](_0x81f5cb[_0x3bf7a2('0xb2')],function(_0x57c25a){const _0x26bee1=_0x3bf7a2;return _0x57c25a[_0x26bee1('0xb4')]=_0x81f5cb[_0x26bee1('0x4d')]['id'],_0x57c25a;});return db[_0x3bf7a2('0x3')][_0x3bf7a2('0xce')](_0x25abaf,{'raw':!![],'transaction':_0x24dfbe});});})[_0x432707('0x9c')](handleError(_0x389406,null));});})[_0x1bb093('0xaa')](function(){})['then'](respondWithResult(_0x389406,null))['catch'](handleError(_0x389406,null));},exports[_0x18d5a8('0x6f')]=function(_0xcef6c1,_0x4b183c){const _0x11eb75=_0x18d5a8;return db[_0x11eb75('0x88')][_0x11eb75('0x53')]({'where':{'id':_0xcef6c1[_0x11eb75('0x4d')]['id']}})[_0x11eb75('0xaa')](handleEntityNotFound(_0x4b183c))[_0x11eb75('0xaa')](function(_0x1bd090){const _0x3b4786=_0x11eb75;if(_0x1bd090)return _0x1bd090[_0x3b4786('0x6f')](_0xcef6c1[_0x3b4786('0x4c')][_0x3b4786('0x6b')]);})[_0x11eb75('0xaa')](respondWithStatusCode(_0x4b183c,null))[_0x11eb75('0x9c')](handleError(_0x4b183c,null));},exports[_0x18d5a8('0xcf')]=function(_0xc90dd2,_0x596e56){const _0x3e08e9=_0x18d5a8;let _0x3e6746={'raw':![],'where':{}};const _0x1bb4cf={},_0x4f899c={'count':0x0,'rows':[]},_0x59fbb9=_0xc90dd2['query'][_0x3e08e9('0x1d')];if(typeof _0x59fbb9===_0x3e08e9('0xb1'))throw new ValidationError(_0x3e08e9('0xa8'));const _0x3417b7=_0xc90dd2[_0x3e08e9('0x4c')][_0x3e08e9('0x57')]||![],_0x1705d8=getQueryModels(_0x59fbb9,_0x3417b7);if(typeof _0x1705d8[_0x3e08e9('0x9')]===_0x3e08e9('0xb1'))throw new ValidationError(_0x3e08e9('0x41')+_0x59fbb9+'\x27');let _0x4a1348=[];return!_[_0x3e08e9('0x79')](_0x1705d8[_0x3e08e9('0xa0')])?_0x4a1348=_0x1705d8[_0x3e08e9('0xa0')]:_0x4a1348=[{'name':_0x59fbb9}],db['UserProfile'][_0x3e08e9('0x53')]({'where':{'id':_0xc90dd2[_0x3e08e9('0x4d')]['id']}})[_0x3e08e9('0xaa')](handleEntityNotFound(_0x596e56))['then'](function(_0x39060b){const _0x2bbc04=_0x3e08e9;if(_0x39060b){const _0x4a8ef4=[];for(let _0x35615a=0x0;_0x35615a<_0x4a1348[_0x2bbc04('0xc0')];_0x35615a++){_0x4a8ef4[_0x2bbc04('0x4f')](db[_0x2bbc04('0xd4')][_0x2bbc04('0x53')]({'where':{'userProfileId':_0x39060b['id'],'name':_0x4a1348[_0x35615a][_0x2bbc04('0x50')]},'raw':!![]}));}return Promise[_0x2bbc04('0x40')](_0x4a8ef4);}})['then'](function(_0x14706b){const _0x2393f3=_0x3e08e9,_0x381807=_[_0x2393f3('0x33')](_0x14706b,function(_0x16e935){return _0x16e935?_0x16e935:undefined;}),_0xe27974=_[_0x2393f3('0x33')](_0x4a1348,[_0x2393f3('0x5'),!![]]),_0x241384=_[_0x2393f3('0x79')](_0x381807)&&_[_0x2393f3('0x79')](_0xe27974)?null:_[_0x2393f3('0x4a')](_0xe27974,_0x381807);if(_0x241384){const _0x48f964=[];for(let _0x287fe9=0x0;_0x287fe9<_0x241384[_0x2393f3('0xc0')];_0x287fe9++){const _0x4e8689=_['find'](_0x4a1348,function(_0x6fcf1d){const _0x5831ca=_0x2393f3;return _0x241384[_0x287fe9]?_0x6fcf1d[_0x5831ca('0x50')]===_0x241384[_0x287fe9]['name']:null;});_0x4e8689&&(_0x241384[_0x287fe9]['ignore']?_0x48f964[_0x2393f3('0x4f')](getAllResources(_0x1705d8[_0x2393f3('0x9')],_0x241384[_0x287fe9])):!_0x241384[_0x287fe9][_0x2393f3('0x14')]?_0x48f964[_0x2393f3('0x4f')](getAllowedResources(_0x4e8689,_0x241384[_0x287fe9],_0x1705d8[_0x2393f3('0x9')])):_0x4e8689[_0x2393f3('0x9a')]&&_0x48f964[_0x2393f3('0x4f')](getAllFilteredResources(_0x4e8689,_0x241384[_0x287fe9])));}return Promise[_0x2393f3('0x40')](_0x48f964);}else return null;})['then'](function(_0x1d6421){const _0x41071e=_0x3e08e9,_0x23640c=_0x1d6421;let _0x497572=null;_0x23640c&&(_0x497572=_0x23640c[_0x41071e('0xc0')]===0x1?_0x23640c[0x0]:null);if(_0x497572||_0x23640c){const _0x3fb032=db[_0x1705d8[_0x41071e('0x9')]][_0x41071e('0xca')];_0x1bb4cf[_0x41071e('0x9a')]=_[_0x41071e('0x31')](_0x3fb032),_0x1bb4cf[_0x41071e('0x4c')]=_['keys'](_0xc90dd2['query']),_0x1bb4cf[_0x41071e('0x48')]=_[_0x41071e('0x43')](_0x1bb4cf['model'],_0x1bb4cf[_0x41071e('0x4c')]),_0x3e6746[_0x41071e('0x47')]=_[_0x41071e('0x43')](_0x1bb4cf[_0x41071e('0x9a')],qs['fields'](_0xc90dd2[_0x41071e('0x4c')][_0x41071e('0x27')])),_0x3e6746[_0x41071e('0x47')]=_0x3e6746['attributes'][_0x41071e('0xc0')]?_0x3e6746['attributes']:_0x1bb4cf[_0x41071e('0x9a')];typeof _0xc90dd2['query'][_0x41071e('0x6c')]==='undefined'&&(_0x3e6746[_0x41071e('0x2c')]=qs['limit'](_0xc90dd2[_0x41071e('0x4c')][_0x41071e('0x2c')]),_0x3e6746[_0x41071e('0x8c')]=qs[_0x41071e('0x8c')](_0xc90dd2[_0x41071e('0x4c')]['offset']));_0x3e6746[_0x41071e('0x95')]=qs['sort'](_0xc90dd2[_0x41071e('0x4c')][_0x41071e('0x70')]),_0x3e6746[_0x41071e('0x72')]=qs['filters'](_['pick'](_0xc90dd2[_0x41071e('0x4c')],_0x1bb4cf['filters']));_0xc90dd2[_0x41071e('0x4c')][_0x41071e('0x33')]&&(_0x3e6746['where']=_[_0x41071e('0xa3')](_0x3e6746[_0x41071e('0x72')],{[Op['or']]:_[_0x41071e('0xbd')](_0x3fb032,function(_0x53af23){const _0x56b8dd=_0x41071e;if(_0x53af23[_0x56b8dd('0xbf')][_0x56b8dd('0xb7')]!==_0x56b8dd('0xd3')){const _0x21b56e={};return _0x21b56e[_0x53af23[_0x56b8dd('0xa')]]={[Op[_0x56b8dd('0x5f')]]:'%'+_0xc90dd2[_0x56b8dd('0x4c')][_0x56b8dd('0x33')]+'%'},_0x21b56e;}})}));const _0x50c369=[];if(_0x497572){const _0x2e56e3=_[_0x41071e('0xba')](_0x4a1348,[_0x41071e('0x50'),_0x497572[_0x41071e('0x50')]]);if(_0x2e56e3[_0x41071e('0xa')]){const _0xc9a3a8={};_0x1705d8['childModel']===_0x41071e('0x59')?_0xc9a3a8[_0x2e56e3[_0x41071e('0x6')]]=_[_0x41071e('0xbd')](_0x497572['associatedResources'],'id'):_0xc9a3a8[_0x2e56e3['foreignKey']]=_0x497572[_0x41071e('0xd9')],_0x50c369[_0x41071e('0x4f')](_0xc9a3a8);}else _0x3e6746[_0x41071e('0x72')]['id']=_0x497572['associatedResources'];}else for(let _0x464eb3=0x0;_0x464eb3<_0x23640c['length'];_0x464eb3++){const _0x4b21f7=_[_0x41071e('0xba')](_0x4a1348,[_0x41071e('0x50'),_0x23640c[_0x464eb3][_0x41071e('0x50')]]);if(_0x4b21f7['field']){const _0x284b3c={};_0x284b3c[_0x4b21f7['foreignKey']]=_0x23640c[_0x464eb3][_0x41071e('0xd9')],_0x50c369[_0x41071e('0x4f')](_0x284b3c);}else{if(!_0x3e6746['where']['id'])_0x3e6746[_0x41071e('0x72')]['id']=[];_0x23640c[_0x464eb3][_0x41071e('0xd9')][_0x41071e('0x7f')](function(_0x3af86b){const _0x159277=_0x41071e;_0x3e6746[_0x159277('0x72')]['id']['push'](_0x3af86b);});}}return!_['isEmpty'](_0x50c369)&&(_0x3e6746[_0x41071e('0x72')]=_['merge'](_0x3e6746['where'],{[Op[_0x41071e('0xd7')]]:{[Op['or']]:_0x50c369}})),_0x3e6746=_[_0x41071e('0xa3')]({},_0x3e6746,_0xc90dd2['options']),_0x497572&&!_0x497572[_0x41071e('0x14')]&&_0x1705d8['childModel']==='AnalyticExtractedReport'?(_0xc90dd2['query'][_0x41071e('0x66')]&&(_0x3e6746[_0x41071e('0x36')]=[{'all':!![]}]),db[_0x1705d8[_0x41071e('0x9')]][_0x41071e('0x1')](_0x3e6746)[_0x41071e('0xaa')](function(_0x1d97af){const _0xdd223c=_0x41071e,_0x3bc06b=[];return _0x1d97af['forEach'](function(_0x298a4b){const _0x3e5d06=a667_0x15d4;let _0x44f287;switch(_0x298a4b[_0x3e5d06('0xa6')]){case _0x3e5d06('0x82'):_0x44f287=_[_0x3e5d06('0xba')](_0x497572[_0x3e5d06('0xd9')],function(_0xb2c17c){const _0x2fea47=_0x3e5d06;return _0xb2c17c['id']===_0x298a4b[_0x2fea47('0xa9')]&&_0xb2c17c['type']===_0x2fea47('0x22');});break;case _0x3e5d06('0x2e'):_0x44f287=_[_0x3e5d06('0xba')](_0x497572['associatedResources'],function(_0x1b901b){const _0x42c492=_0x3e5d06;return _0x1b901b['id']===_0x298a4b[_0x42c492('0xa9')]&&_0x1b901b[_0x42c492('0xbf')]===_0x42c492('0x87');});break;}if(_0x44f287)_0x3bc06b[_0x3e5d06('0x4f')](_0x298a4b);}),_0x4f899c[_0xdd223c('0xf')]=_0x3bc06b[_0xdd223c('0xc0')],_0x4f899c[_0xdd223c('0x78')]=_0x3bc06b,_0x4f899c;})):db[_0x1705d8[_0x41071e('0x9')]][_0x41071e('0xf')]({'where':_0x3e6746[_0x41071e('0x72')]})['then'](function(_0x4c61be){const _0xd8fd0d=_0x41071e;return _0x4f899c[_0xd8fd0d('0xf')]=_0x4c61be,_0xc90dd2[_0xd8fd0d('0x4c')][_0xd8fd0d('0x66')]&&(_0x1705d8[_0xd8fd0d('0x9')]===_0xd8fd0d('0x54')?_0x3e6746[_0xd8fd0d('0x36')]=[{'model':db['Tag'],'as':_0xd8fd0d('0xb5'),'attributes':['id','name',_0xd8fd0d('0x5b')],'required':_0xc90dd2[_0xd8fd0d('0x4c')]['tag']?!![]:![]},{'model':db['Tag'],'as':'ThroughTags','attributes':['id',_0xd8fd0d('0x50'),_0xd8fd0d('0x5b')],'through':_0xc90dd2[_0xd8fd0d('0x4c')][_0xd8fd0d('0x92')]?{'attributes':[],'where':{'TagId':_0xc90dd2[_0xd8fd0d('0x4c')]['tag']||undefined}}:{},'required':_0xc90dd2['query'][_0xd8fd0d('0x92')]?!![]:![]}]:_0x3e6746[_0xd8fd0d('0x36')]=[{'all':!![]}]),db[_0x1705d8[_0xd8fd0d('0x9')]][_0xd8fd0d('0x1')](_0x3e6746);})[_0x41071e('0xaa')](function(_0x27f6cc){const _0x2f53aa=_0x41071e;return _0x4f899c[_0x2f53aa('0x78')]=_0x27f6cc,_0x4f899c;});}else return _0x4f899c;})[_0x3e08e9('0xaa')](respondWithFilteredResult(_0x596e56,_0x3e6746))['catch'](handleError(_0x596e56,null));};function getAllResources(_0x4ea3ef,_0x1916f4){return new Promise(function(_0x2babe5,_0x398127){const _0x46bdbe=a667_0x15d4;if(_0x1916f4){const _0x250895=_0x1916f4[_0x46bdbe('0x33')]?{[_0x1916f4['filter'][_0x46bdbe('0xa')]]:_0x1916f4[_0x46bdbe('0x33')][_0x46bdbe('0x8e')]}:undefined;return db[_0x4ea3ef][_0x46bdbe('0x1')]({'where':_0x250895,'raw':!![]})[_0x46bdbe('0xaa')](function(_0x21291f){const _0x40e155=_0x46bdbe;_0x1916f4[_0x40e155('0xd9')]=_[_0x40e155('0xbd')](_0x21291f,'id'),_0x2babe5(_0x1916f4);})['catch'](function(_0x523ddd){_0x398127(_0x523ddd);});}else _0x2babe5(null);});}function getAllFilteredResources(_0x1d098c,_0x10dea0){return new Promise(function(_0x348001,_0x5a31fb){const _0x484ef9=a667_0x15d4,_0x2c68b3=_0x1d098c[_0x484ef9('0x33')]?{[_0x1d098c[_0x484ef9('0x33')][_0x484ef9('0xa')]]:_0x1d098c[_0x484ef9('0x33')][_0x484ef9('0x8e')]}:undefined;return db[_0x1d098c[_0x484ef9('0x9a')]][_0x484ef9('0x1')]({'where':_0x2c68b3,'raw':!![]})[_0x484ef9('0xaa')](function(_0x4fd47e){const _0x5011e1=_0x484ef9;_0x10dea0[_0x5011e1('0xd9')]=_[_0x5011e1('0xbd')](_0x4fd47e,function(_0x4c74e4){const _0x55fdb0=_0x5011e1;return _0x4c74e4[_0x55fdb0('0x50')];}),_0x348001(_0x10dea0);})[_0x484ef9('0x9c')](function(_0x389c2b){_0x5a31fb(_0x389c2b);});});}function getAllowedResources(_0x200bcd,_0x56483e,_0xe5e119){return new Promise(function(_0x2412e5,_0xffade3){const _0x12f0e0=a667_0x15d4;if(_0x56483e)return db['UserProfileResource']['findAll']({'where':{'sectionId':_0x56483e['id']},'raw':!![]})['then'](function(_0x4e43fe){const _0x12c3d8=a667_0x15d4;_0x200bcd[_0x12c3d8('0xa')]&&_0x200bcd[_0x12c3d8('0xa')]!=='id'?_0x56483e[_0x12c3d8('0xd9')]=_[_0x12c3d8('0xbd')](_0x4e43fe,function(_0x133090){const _0x1d61ac=_0x12c3d8;return _0x133090[_0x200bcd[_0x1d61ac('0xa')]];}):_0xe5e119===_0x12c3d8('0x59')?_0x56483e[_0x12c3d8('0xd9')]=_[_0x12c3d8('0xbd')](_0x4e43fe,function(_0x14ecce){const _0x3239a9=_0x12c3d8;return{'id':_0x14ecce['resourceId'],'type':_0x14ecce[_0x3239a9('0xbf')]};}):_0x56483e[_0x12c3d8('0xd9')]=_[_0x12c3d8('0xbd')](_0x4e43fe,function(_0x1a4c77){const _0x3efc22=_0x12c3d8;return _0x1a4c77[_0x3efc22('0xbb')];}),_0x2412e5(_0x56483e);})[_0x12f0e0('0x9c')](function(_0x22e9be){_0xffade3(_0x22e9be);});else _0x2412e5(null);});}function getQueryModels(_0x30df0,_0x25c0d9){const _0x139756=_0x18d5a8,_0x41732d=_0x30df0[_0x139756('0xda')](),_0x1b7198={'childModel':undefined,'parentSections':[]};switch(_0x41732d){case _0x139756('0x44'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x58');break;case'odbc':_0x1b7198[_0x139756('0x9')]=_0x139756('0x0');break;case _0x139756('0x5d'):_0x1b7198['childModel']=_0x139756('0xbc'),_0x1b7198[_0x139756('0xa0')]=[{'name':_0x139756('0x51'),'field':'name','foreignKey':_0x139756('0x52')}];break;case _0x139756('0x96'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x28');break;case _0x139756('0x86'):_0x1b7198['childModel']='CmContact',_0x1b7198['parentSections']=[{'name':_0x139756('0x16'),'field':'id','foreignKey':_0x139756('0x13')}];break;case _0x139756('0x2'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x10');break;case _0x139756('0x26'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x32');break;case _0x139756('0x74'):_0x1b7198[_0x139756('0x9')]='CmCustomField';break;case _0x139756('0x2a'):_0x1b7198[_0x139756('0x9')]=_0x139756('0xb6');break;case _0x139756('0x7b'):_0x1b7198['childModel']=_0x139756('0x18');break;case _0x139756('0x55'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x64');break;case _0x139756('0x83'):_0x1b7198[_0x139756('0x9')]=_0x139756('0xc1');break;case _0x139756('0x11'):case _0x139756('0x3f'):case'outboundroutes':_0x1b7198['childModel']=_0x139756('0x46');break;case _0x139756('0x4e'):_0x1b7198['childModel']=_0x139756('0x3c');break;case _0x139756('0x49'):_0x1b7198['childModel']=_0x139756('0xd1');break;case _0x139756('0x98'):_0x1b7198['childModel']=_0x139756('0x9e'),_0x1b7198[_0x139756('0xa0')]=[{'name':'Agents','field':_0x139756('0x50'),'foreignKey':_0x139756('0x90'),'model':_0x139756('0x6d'),'filter':{'field':_0x139756('0x1f'),'value':[_0x139756('0xcd')]}},{'name':_0x139756('0x71'),'field':_0x139756('0x50'),'foreignKey':'membername','model':'User','filter':{'field':_0x139756('0x1f'),'value':[_0x139756('0x99')]}},{'name':_0x139756('0x80'),'field':_0x139756('0x50'),'foreignKey':'queue','model':_0x139756('0xc9'),'filter':{'field':_0x139756('0xbf'),'value':[_0x139756('0x35')]}},{'name':_0x139756('0xe'),'field':_0x139756('0x50'),'foreignKey':_0x139756('0x9f'),'model':'VoiceQueue','filter':{'field':_0x139756('0xbf'),'value':[_0x139756('0x65')]}}];break;case _0x139756('0xd'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x60');break;case _0x139756('0x1b'):_0x1b7198['childModel']='VoiceChanSpy';break;case _0x139756('0x37'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x6e');break;case _0x139756('0xc8'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x19');break;case _0x139756('0x73'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x39');break;case'mailaccounts':_0x1b7198['childModel']=_0x139756('0x9d');break;case _0x139756('0x2f'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x4b');break;case'openchannelqueues':_0x1b7198['childModel']=_0x139756('0x4');break;case _0x139756('0x1e'):_0x1b7198[_0x139756('0x9')]=_0x139756('0xb8');break;case _0x139756('0xad'):_0x1b7198['childModel']=_0x139756('0xc2');break;case _0x139756('0xd5'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x8');break;case'whatsappqueues':_0x1b7198[_0x139756('0x9')]=_0x139756('0xd8');break;case _0x139756('0x21'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x29');break;case _0x139756('0x7e'):_0x1b7198['childModel']=_0x139756('0xcc');break;case _0x139756('0x63'):case'queuecampaigns':_0x1b7198[_0x139756('0x9')]=_0x139756('0xc9');_0x25c0d9&&(_0x1b7198[_0x139756('0xa0')]=[{'name':_0x139756('0x80')},{'name':_0x139756('0xe')}]);break;case _0x139756('0xc6'):case _0x139756('0x5a'):case _0x139756('0x15'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x6d');_0x25c0d9&&(_0x1b7198[_0x139756('0xa0')]=[{'name':_0x139756('0x23'),'filter':{'field':_0x139756('0x1f'),'value':[_0x139756('0xc4'),_0x139756('0x69')]},'ignore':!![]},{'name':_0x139756('0x93')},{'name':_0x139756('0x71')}]);break;case _0x139756('0x3a'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x7d');break;case'salesforceaccounts':_0x1b7198[_0x139756('0x9')]='SalesforceAccount';break;case _0x139756('0xbe'):_0x1b7198['childModel']=_0x139756('0xdd');break;case _0x139756('0x9b'):_0x1b7198[_0x139756('0x9')]=_0x139756('0xb');break;case'deskaccounts':_0x1b7198['childModel']=_0x139756('0x6a');break;case _0x139756('0xa4'):_0x1b7198[_0x139756('0x9')]='ZohoAccount';break;case _0x139756('0x25'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x6d');break;case _0x139756('0x61'):_0x1b7198['childModel']=_0x139756('0x38');break;case'dispositions':_0x1b7198[_0x139756('0x9')]=_0x139756('0x89');break;case _0x139756('0xae'):_0x1b7198['childModel']=_0x139756('0x30');break;case'intervals':_0x1b7198[_0x139756('0x9')]=_0x139756('0xa5');break;case'pauses':_0x1b7198[_0x139756('0x9')]=_0x139756('0x5e');break;case'scheduler':_0x1b7198['childModel']=_0x139756('0xd2');break;case'sounds':_0x1b7198[_0x139756('0x9')]='Sound';break;case _0x139756('0x68'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x24');break;case _0x139756('0x75'):_0x1b7198[_0x139756('0x9')]=_0x139756('0xb9');break;case _0x139756('0x77'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x8d');break;case _0x139756('0xb0'):_0x1b7198[_0x139756('0x9')]=_0x139756('0xc');break;case _0x139756('0x76'):_0x1b7198[_0x139756('0x9')]=_0x139756('0xc3');break;case _0x139756('0xa1'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x12');break;case _0x139756('0xc5'):_0x1b7198[_0x139756('0x9')]=_0x139756('0x59'),_0x1b7198[_0x139756('0xa0')]=[{'name':'Reports','field':'id','foreignKey':_0x139756('0xa9')}];break;case _0x139756('0x7'):_0x1b7198['childModel']=_0x139756('0x81');break;default:return _0x1b7198;}return _0x1b7198;} \ No newline at end of file diff --git a/server/api/userProfile/userProfile.events.js b/server/api/userProfile/userProfile.events.js index 92ce1ce..7ce4036 100644 --- a/server/api/userProfile/userProfile.events.js +++ b/server/api/userProfile/userProfile.events.js @@ -1 +1 @@ -const a668_0xf486=['../../mysqldb','emit','update','UserProfile','save','undefined','setMaxListeners','addHook'];(function(_0x49c267,_0xf486a4){const _0x53ff80=function(_0x1e4bf0){while(--_0x1e4bf0){_0x49c267['push'](_0x49c267['shift']());}};_0x53ff80(++_0xf486a4);}(a668_0xf486,0x19a));const a668_0x53ff=function(_0x49c267,_0xf486a4){_0x49c267=_0x49c267-0x0;let _0x53ff80=a668_0xf486[_0x49c267];return _0x53ff80;};const _0xe09e80=a668_0x53ff;'use strict';const EventEmitter=require('events'),UserProfile=require(_0xe09e80('0x6'))['db'][_0xe09e80('0x1')],UserProfileEvents=new EventEmitter();UserProfileEvents[_0xe09e80('0x4')](0x0);const events={'afterCreate':_0xe09e80('0x2'),'afterUpdate':_0xe09e80('0x0'),'afterDestroy':'remove'};function emitEvent(_0x1e4bf0){return function(_0x19cb7e){const _0x4fb2c1=a668_0x53ff;UserProfileEvents[_0x4fb2c1('0x7')](_0x1e4bf0+':'+_0x19cb7e['id'],_0x19cb7e),UserProfileEvents['emit'](_0x1e4bf0,_0x19cb7e);};}for(const e in events){if(typeof events[e]!==_0xe09e80('0x3')){const event=events[e];UserProfile[_0xe09e80('0x5')](e,emitEvent(event));}}module['exports']=UserProfileEvents; \ No newline at end of file +const a668_0x260d=['../../mysqldb','events','emit','addHook','update','UserProfile','save','setMaxListeners','remove'];(function(_0x3a99e5,_0x260d01){const _0x2211b3=function(_0x2a3264){while(--_0x2a3264){_0x3a99e5['push'](_0x3a99e5['shift']());}};_0x2211b3(++_0x260d01);}(a668_0x260d,0x69));const a668_0x2211=function(_0x3a99e5,_0x260d01){_0x3a99e5=_0x3a99e5-0x0;let _0x2211b3=a668_0x260d[_0x3a99e5];return _0x2211b3;};const _0x50686f=a668_0x2211;'use strict';const EventEmitter=require(_0x50686f('0x4')),UserProfile=require(_0x50686f('0x3'))['db'][_0x50686f('0x8')],UserProfileEvents=new EventEmitter();UserProfileEvents[_0x50686f('0x1')](0x0);const events={'afterCreate':_0x50686f('0x0'),'afterUpdate':_0x50686f('0x7'),'afterDestroy':_0x50686f('0x2')};function emitEvent(_0x2a3264){return function(_0x71561a){const _0x1854da=a668_0x2211;UserProfileEvents[_0x1854da('0x5')](_0x2a3264+':'+_0x71561a['id'],_0x71561a),UserProfileEvents[_0x1854da('0x5')](_0x2a3264,_0x71561a);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];UserProfile[_0x50686f('0x6')](e,emitEvent(event));}}module['exports']=UserProfileEvents; \ No newline at end of file diff --git a/server/api/userProfile/userProfile.model.js b/server/api/userProfile/userProfile.model.js index 2ec468a..4d55677 100644 --- a/server/api/userProfile/userProfile.model.js +++ b/server/api/userProfile/userProfile.model.js @@ -1 +1 @@ -const a669_0x487c=['user_profiles','define','./userProfile.attributes','exports'];(function(_0x5d88ca,_0x487c37){const _0x204d69=function(_0x6f9d4){while(--_0x6f9d4){_0x5d88ca['push'](_0x5d88ca['shift']());}};_0x204d69(++_0x487c37);}(a669_0x487c,0x144));const a669_0x204d=function(_0x5d88ca,_0x487c37){_0x5d88ca=_0x5d88ca-0x0;let _0x204d69=a669_0x487c[_0x5d88ca];return _0x204d69;};const _0xa9980e=a669_0x204d;'use strict';const attributes=require(_0xa9980e('0x2'));module[_0xa9980e('0x3')]=function(_0x6f9d4){const _0x5317dc=_0xa9980e,_0x55fc72=_0x6f9d4[_0x5317dc('0x1')]('UserProfile',attributes,{'tableName':_0x5317dc('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x55fc72;}; \ No newline at end of file +const a669_0x8373=['define','exports','user_profiles','UserProfile','./userProfile.attributes'];(function(_0x462e6c,_0x83738c){const _0x2931a9=function(_0x10fbcd){while(--_0x10fbcd){_0x462e6c['push'](_0x462e6c['shift']());}};_0x2931a9(++_0x83738c);}(a669_0x8373,0x16a));const a669_0x2931=function(_0x462e6c,_0x83738c){_0x462e6c=_0x462e6c-0x0;let _0x2931a9=a669_0x8373[_0x462e6c];return _0x2931a9;};const _0x4050ae=a669_0x2931;'use strict';const attributes=require(_0x4050ae('0x2'));module[_0x4050ae('0x4')]=function(_0x10fbcd){const _0x440e37=_0x4050ae,_0x10f317=_0x10fbcd[_0x440e37('0x3')](_0x440e37('0x1'),attributes,{'tableName':_0x440e37('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x10f317;}; \ No newline at end of file diff --git a/server/api/userProfile/userProfile.rpc.js b/server/api/userProfile/userProfile.rpc.js index c042744..b31393f 100644 --- a/server/api/userProfile/userProfile.rpc.js +++ b/server/api/userProfile/userProfile.rpc.js @@ -1 +1 @@ -const a670_0x5090=['./userProfile.socket','register','../../rediscache'];(function(_0x212c7d,_0x5090d0){const _0x44e86c=function(_0x3ee828){while(--_0x3ee828){_0x212c7d['push'](_0x212c7d['shift']());}};_0x44e86c(++_0x5090d0);}(a670_0x5090,0x8e));const a670_0x44e8=function(_0x212c7d,_0x5090d0){_0x212c7d=_0x212c7d-0x0;let _0x44e86c=a670_0x5090[_0x212c7d];return _0x44e86c;};const _0x156c1d=a670_0x44e8;'use strict';const {getSocket}=require(_0x156c1d('0x1')),socket=getSocket();require(_0x156c1d('0x2'))[_0x156c1d('0x0')](socket); \ No newline at end of file +const a670_0x54b9=['../../rediscache','register'];(function(_0x2c15c9,_0x54b9eb){const _0x140f3f=function(_0x8bbd0){while(--_0x8bbd0){_0x2c15c9['push'](_0x2c15c9['shift']());}};_0x140f3f(++_0x54b9eb);}(a670_0x54b9,0xf5));const a670_0x140f=function(_0x2c15c9,_0x54b9eb){_0x2c15c9=_0x2c15c9-0x0;let _0x140f3f=a670_0x54b9[_0x2c15c9];return _0x140f3f;};const _0x360707=a670_0x140f;'use strict';const {getSocket}=require(_0x360707('0x1')),socket=getSocket();require('./userProfile.socket')[_0x360707('0x0')](socket); \ No newline at end of file diff --git a/server/api/userProfile/userProfile.socket.js b/server/api/userProfile/userProfile.socket.js index adc76d1..cbe37ef 100644 --- a/server/api/userProfile/userProfile.socket.js +++ b/server/api/userProfile/userProfile.socket.js @@ -1 +1 @@ -const a671_0x1afc=['update','save','length','./userProfile.events','remove'];(function(_0x2319a0,_0x1afc85){const _0x23fe9c=function(_0x59458a){while(--_0x59458a){_0x2319a0['push'](_0x2319a0['shift']());}};_0x23fe9c(++_0x1afc85);}(a671_0x1afc,0x163));const a671_0x23fe=function(_0x2319a0,_0x1afc85){_0x2319a0=_0x2319a0-0x0;let _0x23fe9c=a671_0x1afc[_0x2319a0];return _0x23fe9c;};const _0x438e78=a671_0x23fe;'use strict';const UserProfileEvents=require(_0x438e78('0x3')),events=[_0x438e78('0x1'),_0x438e78('0x4'),_0x438e78('0x0')];function createListener(_0x59458a,_0x25438a){return function(_0x3585fc){_0x25438a['emit'](_0x59458a,_0x3585fc);};}exports['register']=function(_0x5aed1a){const _0x450bd3=_0x438e78;for(let _0x47cac7=0x0,_0x207ed2=events[_0x450bd3('0x2')];_0x47cac7<_0x207ed2;_0x47cac7++){const _0xeb373a=events[_0x47cac7],_0x14e8bc=createListener('userProfile:'+_0xeb373a,_0x5aed1a);UserProfileEvents['on'](_0xeb373a,_0x14e8bc);}}; \ No newline at end of file +const a671_0x308c=['save','remove','./userProfile.events','userProfile:','length','emit','update'];(function(_0x37d8e8,_0x308c01){const _0x5dea93=function(_0x4aee5f){while(--_0x4aee5f){_0x37d8e8['push'](_0x37d8e8['shift']());}};_0x5dea93(++_0x308c01);}(a671_0x308c,0xb4));const a671_0x5dea=function(_0x37d8e8,_0x308c01){_0x37d8e8=_0x37d8e8-0x0;let _0x5dea93=a671_0x308c[_0x37d8e8];return _0x5dea93;};const _0x44bf54=a671_0x5dea;'use strict';const UserProfileEvents=require(_0x44bf54('0x4')),events=[_0x44bf54('0x2'),_0x44bf54('0x3'),_0x44bf54('0x1')];function createListener(_0x4aee5f,_0x4e40c9){return function(_0x1126ca){const _0x3ac65a=a671_0x5dea;_0x4e40c9[_0x3ac65a('0x0')](_0x4aee5f,_0x1126ca);};}exports['register']=function(_0x5e50d5){const _0x625bc9=_0x44bf54;for(let _0x229a81=0x0,_0x82c505=events[_0x625bc9('0x6')];_0x229a81<_0x82c505;_0x229a81++){const _0x21cf22=events[_0x229a81],_0x4a8fc5=createListener(_0x625bc9('0x5')+_0x21cf22,_0x5e50d5);UserProfileEvents['on'](_0x21cf22,_0x4a8fc5);}}; \ No newline at end of file diff --git a/server/api/userProfileResource/index.js b/server/api/userProfileResource/index.js index f866ec4..949592f 100644 --- a/server/api/userProfileResource/index.js +++ b/server/api/userProfileResource/index.js @@ -1 +1 @@ -const a672_0xa0a7=['get','delete','create','update','put','Router','show','express','./userProfileResource.controller','/describe','/:id','../../components/auth/service','exports','isAuthenticated'];(function(_0x19e8fb,_0xa0a730){const _0x4f1ac2=function(_0x19f519){while(--_0x19f519){_0x19e8fb['push'](_0x19e8fb['shift']());}};_0x4f1ac2(++_0xa0a730);}(a672_0xa0a7,0xd4));const a672_0x4f1a=function(_0x19e8fb,_0xa0a730){_0x19e8fb=_0x19e8fb-0x0;let _0x4f1ac2=a672_0xa0a7[_0x19e8fb];return _0x4f1ac2;};const _0x3f33b3=a672_0x4f1a;'use strict';const express=require(_0x3f33b3('0x5')),router=express[_0x3f33b3('0x3')](),auth=require(_0x3f33b3('0x9')),controller=require(_0x3f33b3('0x6'));router[_0x3f33b3('0xc')]('/',auth[_0x3f33b3('0xb')](),controller['index']),router[_0x3f33b3('0xc')](_0x3f33b3('0x7'),auth[_0x3f33b3('0xb')](),controller['describe']),router[_0x3f33b3('0xc')](_0x3f33b3('0x8'),auth[_0x3f33b3('0xb')](),controller[_0x3f33b3('0x4')]),router['post']('/',auth[_0x3f33b3('0xb')](),controller[_0x3f33b3('0x0')]),router[_0x3f33b3('0x2')]('/:id',auth[_0x3f33b3('0xb')](),controller[_0x3f33b3('0x1')]),router[_0x3f33b3('0xd')](_0x3f33b3('0x8'),auth[_0x3f33b3('0xb')](),controller['destroy']),module[_0x3f33b3('0xa')]=router; \ No newline at end of file +const a672_0x4490=['show','delete','create','express','put','get','../../components/auth/service','/describe','describe','./userProfileResource.controller','isAuthenticated','destroy','/:id','index','post'];(function(_0xf090d0,_0x44903b){const _0x597ac5=function(_0x3d43ec){while(--_0x3d43ec){_0xf090d0['push'](_0xf090d0['shift']());}};_0x597ac5(++_0x44903b);}(a672_0x4490,0x1d9));const a672_0x597a=function(_0xf090d0,_0x44903b){_0xf090d0=_0xf090d0-0x0;let _0x597ac5=a672_0x4490[_0xf090d0];return _0x597ac5;};const _0x3fec7c=a672_0x597a;'use strict';const express=require(_0x3fec7c('0xa')),router=express['Router'](),auth=require(_0x3fec7c('0xd')),controller=require(_0x3fec7c('0x1'));router['get']('/',auth[_0x3fec7c('0x2')](),controller[_0x3fec7c('0x5')]),router[_0x3fec7c('0xc')](_0x3fec7c('0xe'),auth['isAuthenticated'](),controller[_0x3fec7c('0x0')]),router[_0x3fec7c('0xc')](_0x3fec7c('0x4'),auth[_0x3fec7c('0x2')](),controller[_0x3fec7c('0x7')]),router[_0x3fec7c('0x6')]('/',auth[_0x3fec7c('0x2')](),controller[_0x3fec7c('0x9')]),router[_0x3fec7c('0xb')](_0x3fec7c('0x4'),auth[_0x3fec7c('0x2')](),controller['update']),router[_0x3fec7c('0x8')](_0x3fec7c('0x4'),auth['isAuthenticated'](),controller[_0x3fec7c('0x3')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/userProfileResource/userProfileResource.attributes.js b/server/api/userProfileResource/userProfileResource.attributes.js index 66462be..a14338d 100644 --- a/server/api/userProfileResource/userProfileResource.attributes.js +++ b/server/api/userProfileResource/userProfileResource.attributes.js @@ -1 +1 @@ -const a673_0xfa2c=['sequelize','exports','INTEGER','STRING'];(function(_0xd1abbf,_0xfa2c19){const _0x18e460=function(_0x2124c6){while(--_0x2124c6){_0xd1abbf['push'](_0xd1abbf['shift']());}};_0x18e460(++_0xfa2c19);}(a673_0xfa2c,0x116));const a673_0x18e4=function(_0xd1abbf,_0xfa2c19){_0xd1abbf=_0xd1abbf-0x0;let _0x18e460=a673_0xfa2c[_0xd1abbf];return _0x18e460;};const _0x519e26=a673_0x18e4;'use strict';const Sequelize=require(_0x519e26('0x2'));module[_0x519e26('0x3')]={'name':{'type':Sequelize[_0x519e26('0x1')],'allowNull':![]},'resourceId':{'type':Sequelize[_0x519e26('0x0')],'allowNull':![]},'type':{'type':Sequelize[_0x519e26('0x1')],'allowNull':![]}}; \ No newline at end of file +const a673_0x4c5d=['STRING','INTEGER','exports','sequelize'];(function(_0x38faac,_0x4c5d6b){const _0x51ac4e=function(_0x216317){while(--_0x216317){_0x38faac['push'](_0x38faac['shift']());}};_0x51ac4e(++_0x4c5d6b);}(a673_0x4c5d,0xe0));const a673_0x51ac=function(_0x38faac,_0x4c5d6b){_0x38faac=_0x38faac-0x0;let _0x51ac4e=a673_0x4c5d[_0x38faac];return _0x51ac4e;};const _0x264ced=a673_0x51ac;'use strict';const Sequelize=require(_0x264ced('0x3'));module[_0x264ced('0x2')]={'name':{'type':Sequelize['STRING'],'allowNull':![]},'resourceId':{'type':Sequelize[_0x264ced('0x1')],'allowNull':![]},'type':{'type':Sequelize[_0x264ced('0x0')],'allowNull':![]}}; \ No newline at end of file diff --git a/server/api/userProfileResource/userProfileResource.controller.js b/server/api/userProfileResource/userProfileResource.controller.js index 2777352..3de9daa 100644 --- a/server/api/userProfileResource/userProfileResource.controller.js +++ b/server/api/userProfileResource/userProfileResource.controller.js @@ -1 +1 @@ -const a674_0x314d=['destroy','where','limit','intersection','fields','filter','error','key','params','pick','query','sort','order','describe','map','offset','Content-Range','sequelize','keys','api','body','../../components/parsers/qs','sendStatus','index','../../mysqldb','count','show','length','model','attributes','includeAll','findOne','options','create','merge','update','rawAttributes','rows','type','lodash','then','catch','like','include','UserProfileResource','filters','VIRTUAL','status','name'];(function(_0x51abb7,_0x314d3c){const _0x10d642=function(_0x46bf97){while(--_0x46bf97){_0x51abb7['push'](_0x51abb7['shift']());}};_0x10d642(++_0x314d3c);}(a674_0x314d,0x1b2));const a674_0x10d6=function(_0x51abb7,_0x314d3c){_0x51abb7=_0x51abb7-0x0;let _0x10d642=a674_0x314d[_0x51abb7];return _0x10d642;};const _0x14509b=a674_0x10d6;'use strict';const _=require(_0x14509b('0x2e')),qs=require(_0x14509b('0x1c')),logger=require('../../config/logger')(_0x14509b('0x1a')),db=require(_0x14509b('0x1f'))['db'],{Op}=require(_0x14509b('0x18'));function respondWithResult(_0x46bf97,_0x275c77){return _0x275c77=_0x275c77||0xc8,function(_0x8cfe11){if(_0x8cfe11)return _0x46bf97['status'](_0x275c77)['json'](_0x8cfe11);};}function respondWithFilteredResult(_0x54b4a0,_0x460e51){return function(_0x211b52){const _0x2c435a=a674_0x10d6;if(_0x211b52){const _0x2cbb60=_0x211b52['count'],_0x320771=_0x460e51['offset'];let _0x2e7e20=_0x460e51[_0x2c435a('0x16')]+_0x460e51[_0x2c435a('0x9')],_0x5847db;return _0x2e7e20>=_0x2cbb60?(_0x2e7e20=_0x2cbb60,_0x5847db=0xc8):_0x5847db=0xce,_0x54b4a0[_0x2c435a('0x5')](_0x5847db),_0x54b4a0['set'](_0x2c435a('0x17'),_0x320771+'-'+_0x2e7e20+'/'+_0x2cbb60)['json'](_0x211b52);}return null;};}function saveUpdates(_0x1290f){return function(_0x69fbc4){const _0x111dfe=a674_0x10d6;if(_0x69fbc4)return _0x69fbc4['update'](_0x1290f)[_0x111dfe('0x2f')](function(_0x5b7c51){return _0x5b7c51;});return null;};}function removeEntity(_0x397856){return function(_0x63402){const _0x358627=a674_0x10d6;if(_0x63402)return _0x63402[_0x358627('0x7')]()[_0x358627('0x2f')](function(){const _0x3cd2b0=_0x358627;_0x397856[_0x3cd2b0('0x5')](0xcc)['end']();});};}function handleEntityNotFound(_0x501627){return function(_0xb35178){const _0xd10cde=a674_0x10d6;return!_0xb35178&&_0x501627[_0xd10cde('0x1d')](0x194),_0xb35178;};}function handleError(_0x2556e2,_0x36e23e){return _0x36e23e=_0x36e23e||0x1f4,function(_0x36d28a){const _0xccac64=a674_0x10d6;logger[_0xccac64('0xd')](_0x36d28a['stack']),_0x36d28a[_0xccac64('0x6')]&&delete _0x36d28a[_0xccac64('0x6')],_0x2556e2[_0xccac64('0x5')](_0x36e23e)['send'](_0x36d28a);};}exports[_0x14509b('0x1e')]=function(_0x604966,_0x1606f6){const _0x11cad3=_0x14509b;let _0x338d26={};const _0x33bfd7={},_0x40a5f1={'count':0x0,'rows':[]},_0x3c1d5a=_[_0x11cad3('0x15')](db[_0x11cad3('0x2')][_0x11cad3('0x2b')],function(_0x183f22){const _0x77e71d=_0x11cad3;return{'name':_0x183f22['fieldName'],'type':_0x183f22[_0x77e71d('0x2d')][_0x77e71d('0xe')]};});_0x33bfd7[_0x11cad3('0x23')]=_[_0x11cad3('0x15')](_0x3c1d5a,'name'),_0x33bfd7['query']=_[_0x11cad3('0x19')](_0x604966[_0x11cad3('0x11')]),_0x33bfd7['filters']=_[_0x11cad3('0xa')](_0x33bfd7[_0x11cad3('0x23')],_0x33bfd7[_0x11cad3('0x11')]),_0x338d26[_0x11cad3('0x24')]=_[_0x11cad3('0xa')](_0x33bfd7[_0x11cad3('0x23')],qs[_0x11cad3('0xb')](_0x604966[_0x11cad3('0x11')]['fields'])),_0x338d26[_0x11cad3('0x24')]=_0x338d26[_0x11cad3('0x24')][_0x11cad3('0x22')]?_0x338d26[_0x11cad3('0x24')]:_0x33bfd7[_0x11cad3('0x23')];typeof _0x604966[_0x11cad3('0x11')]['nolimit']==='undefined'&&(_0x338d26['limit']=qs['limit'](_0x604966['query'][_0x11cad3('0x9')]),_0x338d26['offset']=qs[_0x11cad3('0x16')](_0x604966[_0x11cad3('0x11')][_0x11cad3('0x16')]));_0x338d26[_0x11cad3('0x13')]=qs[_0x11cad3('0x12')](_0x604966[_0x11cad3('0x11')]['sort']),_0x338d26[_0x11cad3('0x8')]=qs[_0x11cad3('0x3')](_[_0x11cad3('0x10')](_0x604966['query'],_0x33bfd7[_0x11cad3('0x3')]),_0x3c1d5a);_0x604966[_0x11cad3('0x11')][_0x11cad3('0xc')]&&(_0x338d26['where']=_['merge'](_0x338d26[_0x11cad3('0x8')],{[Op['or']]:_[_0x11cad3('0x15')](_0x3c1d5a,function(_0x55cd0e){const _0x1bed86=_0x11cad3;if(_0x55cd0e[_0x1bed86('0x2d')]!==_0x1bed86('0x4')){const _0x52a946={};return _0x52a946[_0x55cd0e[_0x1bed86('0x6')]]={[Op[_0x1bed86('0x0')]]:'%'+_0x604966[_0x1bed86('0x11')][_0x1bed86('0xc')]+'%'},_0x52a946;}})}));_0x338d26=_['merge']({},_0x338d26,_0x604966['options']);const _0x38e3dd={'where':_0x338d26[_0x11cad3('0x8')]};return db['UserProfileResource'][_0x11cad3('0x20')](_0x38e3dd)[_0x11cad3('0x2f')](function(_0x4a40c1){const _0xe7ed25=_0x11cad3;return _0x40a5f1[_0xe7ed25('0x20')]=_0x4a40c1,_0x604966['query'][_0xe7ed25('0x25')]&&(_0x338d26[_0xe7ed25('0x1')]=[{'all':!![]}]),db[_0xe7ed25('0x2')]['findAll'](_0x338d26);})[_0x11cad3('0x2f')](function(_0x10f8b9){const _0x34f586=_0x11cad3;return _0x40a5f1[_0x34f586('0x2c')]=_0x10f8b9,_0x40a5f1;})[_0x11cad3('0x2f')](respondWithFilteredResult(_0x1606f6,_0x338d26))[_0x11cad3('0x30')](handleError(_0x1606f6,null));},exports[_0x14509b('0x21')]=function(_0x3608e6,_0x42a391){const _0x1fcee1=_0x14509b;let _0x3539d4={'raw':![],'where':{'id':_0x3608e6['params']['id']}};const _0x591a38={};return _0x591a38['model']=_['keys'](db['UserProfileResource']['rawAttributes']),_0x591a38[_0x1fcee1('0x11')]=_[_0x1fcee1('0x19')](_0x3608e6['query']),_0x591a38[_0x1fcee1('0x3')]=_[_0x1fcee1('0xa')](_0x591a38[_0x1fcee1('0x23')],_0x591a38[_0x1fcee1('0x11')]),_0x3539d4['attributes']=_[_0x1fcee1('0xa')](_0x591a38[_0x1fcee1('0x23')],qs[_0x1fcee1('0xb')](_0x3608e6[_0x1fcee1('0x11')][_0x1fcee1('0xb')])),_0x3539d4['attributes']=_0x3539d4['attributes'][_0x1fcee1('0x22')]?_0x3539d4[_0x1fcee1('0x24')]:_0x591a38[_0x1fcee1('0x23')],_0x3608e6['query'][_0x1fcee1('0x25')]&&(_0x3539d4['include']=[{'all':!![]}]),_0x3539d4=_[_0x1fcee1('0x29')]({},_0x3539d4,_0x3608e6[_0x1fcee1('0x27')]),db[_0x1fcee1('0x2')][_0x1fcee1('0x26')](_0x3539d4)['then'](handleEntityNotFound(_0x42a391,null))[_0x1fcee1('0x2f')](respondWithResult(_0x42a391,null))[_0x1fcee1('0x30')](handleError(_0x42a391,null));},exports[_0x14509b('0x28')]=function(_0xcb708c,_0x2c1430){const _0x5cb51d=_0x14509b;return db[_0x5cb51d('0x2')][_0x5cb51d('0x28')](_0xcb708c[_0x5cb51d('0x1b')],{})[_0x5cb51d('0x2f')](respondWithResult(_0x2c1430,0xc9))[_0x5cb51d('0x30')](handleError(_0x2c1430,null));},exports[_0x14509b('0x2a')]=function(_0x2edc1a,_0x3608b3){const _0x144023=_0x14509b;return _0x2edc1a[_0x144023('0x1b')]['id']&&delete _0x2edc1a['body']['id'],db[_0x144023('0x2')]['findOne']({'where':{'id':_0x2edc1a['params']['id']}})[_0x144023('0x2f')](handleEntityNotFound(_0x3608b3,null))[_0x144023('0x2f')](saveUpdates(_0x2edc1a[_0x144023('0x1b')],null))['then'](respondWithResult(_0x3608b3,null))['catch'](handleError(_0x3608b3,null));},exports[_0x14509b('0x7')]=function(_0x275c93,_0xff50e2){const _0x590a4f=_0x14509b;return db[_0x590a4f('0x2')]['findOne']({'where':{'id':_0x275c93[_0x590a4f('0xf')]['id']}})[_0x590a4f('0x2f')](handleEntityNotFound(_0xff50e2,null))['then'](removeEntity(_0xff50e2,null))[_0x590a4f('0x30')](handleError(_0xff50e2,null));},exports['describe']=function(_0x23b550,_0xe224ea){const _0x20b1c5=_0x14509b;return db[_0x20b1c5('0x2')][_0x20b1c5('0x14')]()[_0x20b1c5('0x2f')](respondWithResult(_0xe224ea,null))[_0x20b1c5('0x30')](handleError(_0xe224ea,null));}; \ No newline at end of file +const a674_0x56ae=['status','order','describe','UserProfileResource','type','nolimit','where','body','length','json','../../components/parsers/qs','limit','findAll','includeAll','rows','key','name','send','index','fields','keys','filters','options','create','VIRTUAL','destroy','update','offset','include','sendStatus','count','map','attributes','sort','error','filter','findOne','merge','sequelize','intersection','then','Content-Range','params','model','query','rawAttributes','lodash','catch'];(function(_0x1948b3,_0x56ae70){const _0x5df5cc=function(_0x9a51a){while(--_0x9a51a){_0x1948b3['push'](_0x1948b3['shift']());}};_0x5df5cc(++_0x56ae70);}(a674_0x56ae,0x7b));const a674_0x5df5=function(_0x1948b3,_0x56ae70){_0x1948b3=_0x1948b3-0x0;let _0x5df5cc=a674_0x56ae[_0x1948b3];return _0x5df5cc;};const _0x5c0eb5=a674_0x5df5;'use strict';const _=require(_0x5c0eb5('0x13')),qs=require(_0x5c0eb5('0x1f')),logger=require('../../config/logger')('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x5c0eb5('0xb'));function respondWithResult(_0x9a51a,_0x30b3b4){return _0x30b3b4=_0x30b3b4||0xc8,function(_0x45c938){const _0x429c08=a674_0x5df5;if(_0x45c938)return _0x9a51a['status'](_0x30b3b4)[_0x429c08('0x1e')](_0x45c938);};}function respondWithFilteredResult(_0x186ae2,_0x44b50e){return function(_0x2ea24e){const _0x461f1c=a674_0x5df5;if(_0x2ea24e){const _0x20108d=_0x2ea24e['count'],_0x39319c=_0x44b50e['offset'];let _0x5269d9=_0x44b50e[_0x461f1c('0x0')]+_0x44b50e[_0x461f1c('0x20')],_0xb65710;return _0x5269d9>=_0x20108d?(_0x5269d9=_0x20108d,_0xb65710=0xc8):_0xb65710=0xce,_0x186ae2[_0x461f1c('0x15')](_0xb65710),_0x186ae2['set'](_0x461f1c('0xe'),_0x39319c+'-'+_0x5269d9+'/'+_0x20108d)[_0x461f1c('0x1e')](_0x2ea24e);}return null;};}function saveUpdates(_0x295edf){return function(_0x3776fa){const _0x1b954b=a674_0x5df5;if(_0x3776fa)return _0x3776fa[_0x1b954b('0x2f')](_0x295edf)['then'](function(_0x5486e8){return _0x5486e8;});return null;};}function removeEntity(_0x44847a){return function(_0x58d486){const _0x24a414=a674_0x5df5;if(_0x58d486)return _0x58d486[_0x24a414('0x2e')]()[_0x24a414('0xd')](function(){_0x44847a['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x5f35b9){return function(_0x47e747){const _0x254ffd=a674_0x5df5;return!_0x47e747&&_0x5f35b9[_0x254ffd('0x2')](0x194),_0x47e747;};}function handleError(_0x4c4232,_0x1c74c1){return _0x1c74c1=_0x1c74c1||0x1f4,function(_0x1f31df){const _0x49dc6a=a674_0x5df5;logger[_0x49dc6a('0x7')](_0x1f31df['stack']),_0x1f31df['name']&&delete _0x1f31df['name'],_0x4c4232[_0x49dc6a('0x15')](_0x1c74c1)[_0x49dc6a('0x26')](_0x1f31df);};}exports[_0x5c0eb5('0x27')]=function(_0x2b53d0,_0x1cf63a){const _0x55e399=_0x5c0eb5;let _0xdf5c53={};const _0x185da8={},_0x532dac={'count':0x0,'rows':[]},_0x1935af=_[_0x55e399('0x4')](db['UserProfileResource'][_0x55e399('0x12')],function(_0x31ae13){const _0x14343e=_0x55e399;return{'name':_0x31ae13['fieldName'],'type':_0x31ae13[_0x14343e('0x19')][_0x14343e('0x24')]};});_0x185da8[_0x55e399('0x10')]=_[_0x55e399('0x4')](_0x1935af,'name'),_0x185da8[_0x55e399('0x11')]=_[_0x55e399('0x29')](_0x2b53d0[_0x55e399('0x11')]),_0x185da8[_0x55e399('0x2a')]=_[_0x55e399('0xc')](_0x185da8['model'],_0x185da8[_0x55e399('0x11')]),_0xdf5c53[_0x55e399('0x5')]=_['intersection'](_0x185da8[_0x55e399('0x10')],qs[_0x55e399('0x28')](_0x2b53d0[_0x55e399('0x11')][_0x55e399('0x28')])),_0xdf5c53[_0x55e399('0x5')]=_0xdf5c53[_0x55e399('0x5')][_0x55e399('0x1d')]?_0xdf5c53[_0x55e399('0x5')]:_0x185da8['model'];typeof _0x2b53d0[_0x55e399('0x11')][_0x55e399('0x1a')]==='undefined'&&(_0xdf5c53[_0x55e399('0x20')]=qs[_0x55e399('0x20')](_0x2b53d0[_0x55e399('0x11')][_0x55e399('0x20')]),_0xdf5c53[_0x55e399('0x0')]=qs[_0x55e399('0x0')](_0x2b53d0[_0x55e399('0x11')][_0x55e399('0x0')]));_0xdf5c53[_0x55e399('0x16')]=qs[_0x55e399('0x6')](_0x2b53d0[_0x55e399('0x11')][_0x55e399('0x6')]),_0xdf5c53[_0x55e399('0x1b')]=qs[_0x55e399('0x2a')](_['pick'](_0x2b53d0[_0x55e399('0x11')],_0x185da8[_0x55e399('0x2a')]),_0x1935af);_0x2b53d0[_0x55e399('0x11')][_0x55e399('0x8')]&&(_0xdf5c53['where']=_['merge'](_0xdf5c53[_0x55e399('0x1b')],{[Op['or']]:_[_0x55e399('0x4')](_0x1935af,function(_0x43309a){const _0x4966cf=_0x55e399;if(_0x43309a[_0x4966cf('0x19')]!==_0x4966cf('0x2d')){const _0xc5fc7f={};return _0xc5fc7f[_0x43309a[_0x4966cf('0x25')]]={[Op['like']]:'%'+_0x2b53d0[_0x4966cf('0x11')]['filter']+'%'},_0xc5fc7f;}})}));_0xdf5c53=_[_0x55e399('0xa')]({},_0xdf5c53,_0x2b53d0['options']);const _0x365d77={'where':_0xdf5c53[_0x55e399('0x1b')]};return db[_0x55e399('0x18')][_0x55e399('0x3')](_0x365d77)[_0x55e399('0xd')](function(_0xac864a){const _0x250f07=_0x55e399;return _0x532dac[_0x250f07('0x3')]=_0xac864a,_0x2b53d0[_0x250f07('0x11')][_0x250f07('0x22')]&&(_0xdf5c53[_0x250f07('0x1')]=[{'all':!![]}]),db['UserProfileResource'][_0x250f07('0x21')](_0xdf5c53);})[_0x55e399('0xd')](function(_0x136900){const _0x49a95f=_0x55e399;return _0x532dac[_0x49a95f('0x23')]=_0x136900,_0x532dac;})[_0x55e399('0xd')](respondWithFilteredResult(_0x1cf63a,_0xdf5c53))[_0x55e399('0x14')](handleError(_0x1cf63a,null));},exports['show']=function(_0x49d219,_0x15287d){const _0x34b0b7=_0x5c0eb5;let _0x2b6f3d={'raw':![],'where':{'id':_0x49d219[_0x34b0b7('0xf')]['id']}};const _0x282646={};return _0x282646['model']=_[_0x34b0b7('0x29')](db[_0x34b0b7('0x18')][_0x34b0b7('0x12')]),_0x282646[_0x34b0b7('0x11')]=_[_0x34b0b7('0x29')](_0x49d219['query']),_0x282646[_0x34b0b7('0x2a')]=_['intersection'](_0x282646['model'],_0x282646[_0x34b0b7('0x11')]),_0x2b6f3d['attributes']=_[_0x34b0b7('0xc')](_0x282646[_0x34b0b7('0x10')],qs['fields'](_0x49d219[_0x34b0b7('0x11')][_0x34b0b7('0x28')])),_0x2b6f3d['attributes']=_0x2b6f3d[_0x34b0b7('0x5')][_0x34b0b7('0x1d')]?_0x2b6f3d[_0x34b0b7('0x5')]:_0x282646[_0x34b0b7('0x10')],_0x49d219[_0x34b0b7('0x11')][_0x34b0b7('0x22')]&&(_0x2b6f3d['include']=[{'all':!![]}]),_0x2b6f3d=_[_0x34b0b7('0xa')]({},_0x2b6f3d,_0x49d219[_0x34b0b7('0x2b')]),db[_0x34b0b7('0x18')]['findOne'](_0x2b6f3d)[_0x34b0b7('0xd')](handleEntityNotFound(_0x15287d,null))[_0x34b0b7('0xd')](respondWithResult(_0x15287d,null))[_0x34b0b7('0x14')](handleError(_0x15287d,null));},exports[_0x5c0eb5('0x2c')]=function(_0x149a54,_0x51a42c){const _0x3c22d5=_0x5c0eb5;return db[_0x3c22d5('0x18')][_0x3c22d5('0x2c')](_0x149a54[_0x3c22d5('0x1c')],{})[_0x3c22d5('0xd')](respondWithResult(_0x51a42c,0xc9))[_0x3c22d5('0x14')](handleError(_0x51a42c,null));},exports[_0x5c0eb5('0x2f')]=function(_0x5b8ebc,_0x4ba8cf){const _0x398b42=_0x5c0eb5;return _0x5b8ebc['body']['id']&&delete _0x5b8ebc[_0x398b42('0x1c')]['id'],db[_0x398b42('0x18')][_0x398b42('0x9')]({'where':{'id':_0x5b8ebc['params']['id']}})[_0x398b42('0xd')](handleEntityNotFound(_0x4ba8cf,null))['then'](saveUpdates(_0x5b8ebc['body'],null))[_0x398b42('0xd')](respondWithResult(_0x4ba8cf,null))[_0x398b42('0x14')](handleError(_0x4ba8cf,null));},exports['destroy']=function(_0x28e37a,_0x18821d){const _0xa8af1c=_0x5c0eb5;return db[_0xa8af1c('0x18')][_0xa8af1c('0x9')]({'where':{'id':_0x28e37a[_0xa8af1c('0xf')]['id']}})[_0xa8af1c('0xd')](handleEntityNotFound(_0x18821d,null))['then'](removeEntity(_0x18821d,null))[_0xa8af1c('0x14')](handleError(_0x18821d,null));},exports[_0x5c0eb5('0x17')]=function(_0x3cc45b,_0x52bde0){const _0x1f2a84=_0x5c0eb5;return db['UserProfileResource']['describe']()[_0x1f2a84('0xd')](respondWithResult(_0x52bde0,null))['catch'](handleError(_0x52bde0,null));}; \ No newline at end of file diff --git a/server/api/userProfileResource/userProfileResource.model.js b/server/api/userProfileResource/userProfileResource.model.js index 39cfac1..28f1bc4 100644 --- a/server/api/userProfileResource/userProfileResource.model.js +++ b/server/api/userProfileResource/userProfileResource.model.js @@ -1 +1 @@ -const a675_0x3887=['sectionId','exports','compositeIndex','UserProfileResource'];(function(_0x523040,_0x3887a2){const _0x29ca1f=function(_0x26386f){while(--_0x26386f){_0x523040['push'](_0x523040['shift']());}};_0x29ca1f(++_0x3887a2);}(a675_0x3887,0x194));const a675_0x29ca=function(_0x523040,_0x3887a2){_0x523040=_0x523040-0x0;let _0x29ca1f=a675_0x3887[_0x523040];return _0x29ca1f;};const _0x46479b=a675_0x29ca;'use strict';const attributes=require('./userProfileResource.attributes');module[_0x46479b('0x1')]=function(_0x26386f){const _0x26a1b7=_0x46479b,_0x5672d9=_0x26386f['define'](_0x26a1b7('0x3'),attributes,{'tableName':'user_profile_has_resources','paranoid':![],'indexes':[{'name':_0x26a1b7('0x2'),'fields':['resourceId',_0x26a1b7('0x0')]}],'timestamps':!![]});return _0x5672d9;}; \ No newline at end of file +const a675_0x395b=['define','exports','./userProfileResource.attributes','compositeIndex','resourceId'];(function(_0x3e7e12,_0x395bb2){const _0x3cab3b=function(_0x1ac57b){while(--_0x1ac57b){_0x3e7e12['push'](_0x3e7e12['shift']());}};_0x3cab3b(++_0x395bb2);}(a675_0x395b,0x158));const a675_0x3cab=function(_0x3e7e12,_0x395bb2){_0x3e7e12=_0x3e7e12-0x0;let _0x3cab3b=a675_0x395b[_0x3e7e12];return _0x3cab3b;};const _0x1ed656=a675_0x3cab;'use strict';const attributes=require(_0x1ed656('0x3'));module[_0x1ed656('0x2')]=function(_0x1ac57b){const _0x27bfdf=_0x1ed656,_0x537e6f=_0x1ac57b[_0x27bfdf('0x1')]('UserProfileResource',attributes,{'tableName':'user_profile_has_resources','paranoid':![],'indexes':[{'name':_0x27bfdf('0x4'),'fields':[_0x27bfdf('0x0'),'sectionId']}],'timestamps':!![]});return _0x537e6f;}; \ No newline at end of file diff --git a/server/api/userProfileSection/index.js b/server/api/userProfileSection/index.js index a0c9e4c..1bb4d49 100644 --- a/server/api/userProfileSection/index.js +++ b/server/api/userProfileSection/index.js @@ -1 +1 @@ -const a676_0x2bc1=['get','index','./userProfileSection.controller','/describe','show','post','destroy','update','/:id','../../components/auth/service','describe','Router','isAuthenticated','exports','express'];(function(_0x2e7859,_0x2bc1bd){const _0x5527f2=function(_0x447bb6){while(--_0x447bb6){_0x2e7859['push'](_0x2e7859['shift']());}};_0x5527f2(++_0x2bc1bd);}(a676_0x2bc1,0xfb));const a676_0x5527=function(_0x2e7859,_0x2bc1bd){_0x2e7859=_0x2e7859-0x0;let _0x5527f2=a676_0x2bc1[_0x2e7859];return _0x5527f2;};const _0x34ffc9=a676_0x5527;'use strict';const express=require(_0x34ffc9('0x3')),router=express[_0x34ffc9('0x0')](),auth=require(_0x34ffc9('0xd')),controller=require(_0x34ffc9('0x6'));router[_0x34ffc9('0x4')]('/',auth['isAuthenticated'](),controller[_0x34ffc9('0x5')]),router[_0x34ffc9('0x4')](_0x34ffc9('0x7'),auth[_0x34ffc9('0x1')](),controller[_0x34ffc9('0xe')]),router[_0x34ffc9('0x4')]('/:id',auth[_0x34ffc9('0x1')](),controller[_0x34ffc9('0x8')]),router[_0x34ffc9('0x9')]('/',auth[_0x34ffc9('0x1')](),controller['create']),router['put'](_0x34ffc9('0xc'),auth[_0x34ffc9('0x1')](),controller[_0x34ffc9('0xb')]),router['delete'](_0x34ffc9('0xc'),auth[_0x34ffc9('0x1')](),controller[_0x34ffc9('0xa')]),module[_0x34ffc9('0x2')]=router; \ No newline at end of file +const a676_0x45fe=['./userProfileSection.controller','get','show','../../components/auth/service','/:id','create','delete','put','/describe','exports','isAuthenticated','express','post'];(function(_0x2c9671,_0x45feac){const _0x275985=function(_0x4f8ac4){while(--_0x4f8ac4){_0x2c9671['push'](_0x2c9671['shift']());}};_0x275985(++_0x45feac);}(a676_0x45fe,0xf1));const a676_0x2759=function(_0x2c9671,_0x45feac){_0x2c9671=_0x2c9671-0x0;let _0x275985=a676_0x45fe[_0x2c9671];return _0x275985;};const _0x5f4192=a676_0x2759;'use strict';const express=require(_0x5f4192('0x4')),router=express['Router'](),auth=require(_0x5f4192('0x9')),controller=require(_0x5f4192('0x6'));router['get']('/',auth[_0x5f4192('0x3')](),controller['index']),router['get'](_0x5f4192('0x1'),auth['isAuthenticated'](),controller['describe']),router[_0x5f4192('0x7')](_0x5f4192('0xa'),auth[_0x5f4192('0x3')](),controller[_0x5f4192('0x8')]),router[_0x5f4192('0x5')]('/',auth['isAuthenticated'](),controller[_0x5f4192('0xb')]),router[_0x5f4192('0x0')](_0x5f4192('0xa'),auth[_0x5f4192('0x3')](),controller['update']),router[_0x5f4192('0xc')](_0x5f4192('0xa'),auth[_0x5f4192('0x3')](),controller['destroy']),module[_0x5f4192('0x2')]=router; \ No newline at end of file diff --git a/server/api/userProfileSection/userProfileSection.attributes.js b/server/api/userProfileSection/userProfileSection.attributes.js index 89cfb3a..c02f3c9 100644 --- a/server/api/userProfileSection/userProfileSection.attributes.js +++ b/server/api/userProfileSection/userProfileSection.attributes.js @@ -1 +1 @@ -const a677_0x4a35=['exports','getDataValue','crudPermissions','INTEGER','BOOLEAN','join','STRING'];(function(_0x757738,_0x4a3556){const _0x1af2ea=function(_0x4e025d){while(--_0x4e025d){_0x757738['push'](_0x757738['shift']());}};_0x1af2ea(++_0x4a3556);}(a677_0x4a35,0x199));const a677_0x1af2=function(_0x757738,_0x4a3556){_0x757738=_0x757738-0x0;let _0x1af2ea=a677_0x4a35[_0x757738];return _0x1af2ea;};const _0x1c4259=a677_0x1af2;'use strict';const Sequelize=require('sequelize');module[_0x1c4259('0x4')]={'name':{'type':Sequelize['STRING'],'allowNull':![]},'category':{'type':Sequelize[_0x1c4259('0x3')],'allowNull':![]},'sectionId':{'type':Sequelize[_0x1c4259('0x0')],'allowNull':![]},'enabled':{'type':Sequelize[_0x1c4259('0x1')],'defaultValue':null},'autoAssociation':{'type':Sequelize[_0x1c4259('0x1')],'defaultValue':null},'crudPermissions':{'type':Sequelize['STRING'],'set':function(_0x4e025d){const _0x53ad7f=_0x1c4259;this['setDataValue']('crudPermissions',_0x4e025d?_0x4e025d[_0x53ad7f('0x2')](''):[]);},'get':function(){const _0x57b19d=_0x1c4259;return this[_0x57b19d('0x5')]('crudPermissions')?this['getDataValue'](_0x57b19d('0x6'))['split'](''):[];}}}; \ No newline at end of file +const a677_0x7eff=['exports','INTEGER','getDataValue','sequelize','setDataValue','BOOLEAN','crudPermissions','join','STRING','split'];(function(_0x45b02f,_0x7effdc){const _0x1ff903=function(_0x3acf1f){while(--_0x3acf1f){_0x45b02f['push'](_0x45b02f['shift']());}};_0x1ff903(++_0x7effdc);}(a677_0x7eff,0x1b8));const a677_0x1ff9=function(_0x45b02f,_0x7effdc){_0x45b02f=_0x45b02f-0x0;let _0x1ff903=a677_0x7eff[_0x45b02f];return _0x1ff903;};const _0xdff58=a677_0x1ff9;'use strict';const Sequelize=require(_0xdff58('0x3'));module[_0xdff58('0x0')]={'name':{'type':Sequelize[_0xdff58('0x8')],'allowNull':![]},'category':{'type':Sequelize[_0xdff58('0x8')],'allowNull':![]},'sectionId':{'type':Sequelize[_0xdff58('0x1')],'allowNull':![]},'enabled':{'type':Sequelize[_0xdff58('0x5')],'defaultValue':null},'autoAssociation':{'type':Sequelize[_0xdff58('0x5')],'defaultValue':null},'crudPermissions':{'type':Sequelize[_0xdff58('0x8')],'set':function(_0x3acf1f){const _0x447417=_0xdff58;this[_0x447417('0x4')](_0x447417('0x6'),_0x3acf1f?_0x3acf1f[_0x447417('0x7')](''):[]);},'get':function(){const _0x5aa56d=_0xdff58;return this['getDataValue'](_0x5aa56d('0x6'))?this[_0x5aa56d('0x2')]('crudPermissions')[_0x5aa56d('0x9')](''):[];}}}; \ No newline at end of file diff --git a/server/api/userProfileSection/userProfileSection.controller.js b/server/api/userProfileSection/userProfileSection.controller.js index 0d1ebc8..8aa3053 100644 --- a/server/api/userProfileSection/userProfileSection.controller.js +++ b/server/api/userProfileSection/userProfileSection.controller.js @@ -1 +1 @@ -const a678_0x2198=['rows','where','../../mysqldb','filter','sort','attributes','limit','catch','destroy','describe','fieldName','api','UserProfileSection','update','send','stack','index','body','intersection','set','findOne','model','map','length','fields','key','merge','error','params','Content-Range','offset','name','json','nolimit','query','findAll','then','VIRTUAL','lodash','filters','count','status','create','like','keys','rawAttributes','options','includeAll','include','sendStatus'];(function(_0x12f47b,_0x219827){const _0x35aead=function(_0x5de601){while(--_0x5de601){_0x12f47b['push'](_0x12f47b['shift']());}};_0x35aead(++_0x219827);}(a678_0x2198,0x97));const a678_0x35ae=function(_0x12f47b,_0x219827){_0x12f47b=_0x12f47b-0x0;let _0x35aead=a678_0x2198[_0x12f47b];return _0x35aead;};const _0x20e94f=a678_0x35ae;'use strict';const _=require(_0x20e94f('0x25')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x20e94f('0xa')),db=require(_0x20e94f('0x1'))['db'],{Op}=require('sequelize');function respondWithResult(_0x5de601,_0x12118e){return _0x12118e=_0x12118e||0xc8,function(_0x43c7fe){const _0x3e1d74=a678_0x35ae;if(_0x43c7fe)return _0x5de601[_0x3e1d74('0x28')](_0x12118e)[_0x3e1d74('0x1f')](_0x43c7fe);};}function respondWithFilteredResult(_0xeeb964,_0x60ea44){return function(_0x19664d){const _0x47fc02=a678_0x35ae;if(_0x19664d){const _0x323842=_0x19664d[_0x47fc02('0x27')],_0x34aadd=_0x60ea44['offset'];let _0x37ba67=_0x60ea44['offset']+_0x60ea44[_0x47fc02('0x5')],_0x4807d9;return _0x37ba67>=_0x323842?(_0x37ba67=_0x323842,_0x4807d9=0xc8):_0x4807d9=0xce,_0xeeb964[_0x47fc02('0x28')](_0x4807d9),_0xeeb964[_0x47fc02('0x12')](_0x47fc02('0x1c'),_0x34aadd+'-'+_0x37ba67+'/'+_0x323842)['json'](_0x19664d);}return null;};}function saveUpdates(_0x42d0c4){return function(_0x11fdf3){const _0x2437cb=a678_0x35ae;if(_0x11fdf3)return _0x11fdf3[_0x2437cb('0xc')](_0x42d0c4)[_0x2437cb('0x23')](function(_0x590861){return _0x590861;});return null;};}function removeEntity(_0x42722e){return function(_0x5423a8){const _0x2b7f5d=a678_0x35ae;if(_0x5423a8)return _0x5423a8[_0x2b7f5d('0x7')]()[_0x2b7f5d('0x23')](function(){const _0x3b7e91=_0x2b7f5d;_0x42722e[_0x3b7e91('0x28')](0xcc)['end']();});};}function handleEntityNotFound(_0xcb15f9){return function(_0x18c644){const _0x20e1a1=a678_0x35ae;return!_0x18c644&&_0xcb15f9[_0x20e1a1('0x30')](0x194),_0x18c644;};}function handleError(_0x54c4f7,_0x3b4f41){return _0x3b4f41=_0x3b4f41||0x1f4,function(_0x4f13fd){const _0x23672b=a678_0x35ae;logger[_0x23672b('0x1a')](_0x4f13fd[_0x23672b('0xe')]),_0x4f13fd['name']&&delete _0x4f13fd[_0x23672b('0x1e')],_0x54c4f7[_0x23672b('0x28')](_0x3b4f41)[_0x23672b('0xd')](_0x4f13fd);};}exports[_0x20e94f('0xf')]=function(_0x431cf4,_0x35e90e){const _0x2343e0=_0x20e94f;let _0x436e60={};const _0x24de0e={},_0x595352={'count':0x0,'rows':[]},_0x148909=_['map'](db[_0x2343e0('0xb')][_0x2343e0('0x2c')],function(_0x5d8e2d){const _0x30fcad=_0x2343e0;return{'name':_0x5d8e2d[_0x30fcad('0x9')],'type':_0x5d8e2d['type'][_0x30fcad('0x18')]};});_0x24de0e[_0x2343e0('0x14')]=_['map'](_0x148909,_0x2343e0('0x1e')),_0x24de0e['query']=_['keys'](_0x431cf4[_0x2343e0('0x21')]),_0x24de0e[_0x2343e0('0x26')]=_[_0x2343e0('0x11')](_0x24de0e['model'],_0x24de0e[_0x2343e0('0x21')]),_0x436e60[_0x2343e0('0x4')]=_['intersection'](_0x24de0e[_0x2343e0('0x14')],qs[_0x2343e0('0x17')](_0x431cf4[_0x2343e0('0x21')][_0x2343e0('0x17')])),_0x436e60[_0x2343e0('0x4')]=_0x436e60[_0x2343e0('0x4')][_0x2343e0('0x16')]?_0x436e60['attributes']:_0x24de0e[_0x2343e0('0x14')];typeof _0x431cf4[_0x2343e0('0x21')][_0x2343e0('0x20')]==='undefined'&&(_0x436e60[_0x2343e0('0x5')]=qs[_0x2343e0('0x5')](_0x431cf4['query'][_0x2343e0('0x5')]),_0x436e60[_0x2343e0('0x1d')]=qs['offset'](_0x431cf4[_0x2343e0('0x21')][_0x2343e0('0x1d')]));_0x436e60['order']=qs['sort'](_0x431cf4['query'][_0x2343e0('0x3')]),_0x436e60[_0x2343e0('0x0')]=qs[_0x2343e0('0x26')](_['pick'](_0x431cf4[_0x2343e0('0x21')],_0x24de0e[_0x2343e0('0x26')]),_0x148909);_0x431cf4[_0x2343e0('0x21')][_0x2343e0('0x2')]&&(_0x436e60[_0x2343e0('0x0')]=_['merge'](_0x436e60['where'],{[Op['or']]:_[_0x2343e0('0x15')](_0x148909,function(_0x16582a){const _0x4c7854=_0x2343e0;if(_0x16582a['type']!==_0x4c7854('0x24')){const _0x3e97bf={};return _0x3e97bf[_0x16582a[_0x4c7854('0x1e')]]={[Op[_0x4c7854('0x2a')]]:'%'+_0x431cf4[_0x4c7854('0x21')][_0x4c7854('0x2')]+'%'},_0x3e97bf;}})}));_0x436e60=_[_0x2343e0('0x19')]({},_0x436e60,_0x431cf4[_0x2343e0('0x2d')]);const _0xd74a5e={'where':_0x436e60['where']};return db[_0x2343e0('0xb')]['count'](_0xd74a5e)[_0x2343e0('0x23')](function(_0x2c9704){const _0x407627=_0x2343e0;return _0x595352[_0x407627('0x27')]=_0x2c9704,_0x431cf4[_0x407627('0x21')][_0x407627('0x2e')]&&(_0x436e60[_0x407627('0x2f')]=[{'all':!![]}]),db[_0x407627('0xb')][_0x407627('0x22')](_0x436e60);})['then'](function(_0x2f1b18){const _0x252b1e=_0x2343e0;return _0x595352[_0x252b1e('0x31')]=_0x2f1b18,_0x595352;})[_0x2343e0('0x23')](respondWithFilteredResult(_0x35e90e,_0x436e60))[_0x2343e0('0x6')](handleError(_0x35e90e,null));},exports['show']=function(_0x4500d0,_0xe84783){const _0x5af346=_0x20e94f;let _0x314d8b={'raw':![],'where':{'id':_0x4500d0[_0x5af346('0x1b')]['id']}};const _0x228745={};return _0x228745[_0x5af346('0x14')]=_[_0x5af346('0x2b')](db[_0x5af346('0xb')][_0x5af346('0x2c')]),_0x228745['query']=_[_0x5af346('0x2b')](_0x4500d0[_0x5af346('0x21')]),_0x228745[_0x5af346('0x26')]=_[_0x5af346('0x11')](_0x228745[_0x5af346('0x14')],_0x228745[_0x5af346('0x21')]),_0x314d8b[_0x5af346('0x4')]=_[_0x5af346('0x11')](_0x228745[_0x5af346('0x14')],qs[_0x5af346('0x17')](_0x4500d0[_0x5af346('0x21')][_0x5af346('0x17')])),_0x314d8b[_0x5af346('0x4')]=_0x314d8b[_0x5af346('0x4')][_0x5af346('0x16')]?_0x314d8b[_0x5af346('0x4')]:_0x228745[_0x5af346('0x14')],_0x4500d0[_0x5af346('0x21')][_0x5af346('0x2e')]&&(_0x314d8b[_0x5af346('0x2f')]=[{'all':!![]}]),_0x314d8b=_[_0x5af346('0x19')]({},_0x314d8b,_0x4500d0[_0x5af346('0x2d')]),db[_0x5af346('0xb')][_0x5af346('0x13')](_0x314d8b)[_0x5af346('0x23')](handleEntityNotFound(_0xe84783,null))[_0x5af346('0x23')](respondWithResult(_0xe84783,null))[_0x5af346('0x6')](handleError(_0xe84783,null));},exports[_0x20e94f('0x29')]=function(_0x134af1,_0x5c33c1){const _0x238c92=_0x20e94f;return db[_0x238c92('0xb')][_0x238c92('0x29')](_0x134af1[_0x238c92('0x10')],{})[_0x238c92('0x23')](respondWithResult(_0x5c33c1,0xc9))['catch'](handleError(_0x5c33c1,null));},exports[_0x20e94f('0xc')]=function(_0x254ce9,_0x5d271a){const _0xdcf539=_0x20e94f;return _0x254ce9['body']['id']&&delete _0x254ce9[_0xdcf539('0x10')]['id'],db[_0xdcf539('0xb')][_0xdcf539('0x13')]({'where':{'id':_0x254ce9[_0xdcf539('0x1b')]['id']}})[_0xdcf539('0x23')](handleEntityNotFound(_0x5d271a,null))['then'](saveUpdates(_0x254ce9[_0xdcf539('0x10')],null))['then'](respondWithResult(_0x5d271a,null))[_0xdcf539('0x6')](handleError(_0x5d271a,null));},exports[_0x20e94f('0x7')]=function(_0x27fb40,_0x46026a){const _0x58af19=_0x20e94f;return db[_0x58af19('0xb')][_0x58af19('0x13')]({'where':{'id':_0x27fb40['params']['id']}})[_0x58af19('0x23')](handleEntityNotFound(_0x46026a,null))[_0x58af19('0x23')](removeEntity(_0x46026a,null))[_0x58af19('0x6')](handleError(_0x46026a,null));},exports[_0x20e94f('0x8')]=function(_0x2b32b7,_0x2a134b){const _0x2e3586=_0x20e94f;return db[_0x2e3586('0xb')][_0x2e3586('0x8')]()[_0x2e3586('0x23')](respondWithResult(_0x2a134b,null))[_0x2e3586('0x6')](handleError(_0x2a134b,null));}; \ No newline at end of file +const a678_0x3cfe=['query','sort','status','findAll','catch','fields','offset','limit','order','length','type','model','describe','includeAll','Content-Range','intersection','findOne','merge','error','update','map','include','nolimit','sendStatus','sequelize','keys','count','show','attributes','pick','stack','set','../../config/logger','send','UserProfileSection','fieldName','VIRTUAL','api','index','then','rows','params','create','options','filters','where','lodash','name','body','destroy','undefined'];(function(_0x920ae9,_0x3cfe4e){const _0x1c2eda=function(_0x4a3de6){while(--_0x4a3de6){_0x920ae9['push'](_0x920ae9['shift']());}};_0x1c2eda(++_0x3cfe4e);}(a678_0x3cfe,0x1cb));const a678_0x1c2e=function(_0x920ae9,_0x3cfe4e){_0x920ae9=_0x920ae9-0x0;let _0x1c2eda=a678_0x3cfe[_0x920ae9];return _0x1c2eda;};const _0x4e620d=a678_0x1c2e;'use strict';const _=require(_0x4e620d('0x2e')),qs=require('../../components/parsers/qs'),logger=require(_0x4e620d('0x20'))(_0x4e620d('0x25')),db=require('../../mysqldb')['db'],{Op}=require(_0x4e620d('0x18'));function respondWithResult(_0x4a3de6,_0x3efeea){return _0x3efeea=_0x3efeea||0xc8,function(_0x3bcc40){const _0xc5abb8=a678_0x1c2e;if(_0x3bcc40)return _0x4a3de6[_0xc5abb8('0x2')](_0x3efeea)['json'](_0x3bcc40);};}function respondWithFilteredResult(_0x10a626,_0x341758){return function(_0x6a3cc3){const _0x540193=a678_0x1c2e;if(_0x6a3cc3){const _0x273eb8=_0x6a3cc3[_0x540193('0x1a')],_0x5b9f73=_0x341758[_0x540193('0x6')];let _0x19ee3a=_0x341758['offset']+_0x341758[_0x540193('0x7')],_0x293e98;return _0x19ee3a>=_0x273eb8?(_0x19ee3a=_0x273eb8,_0x293e98=0xc8):_0x293e98=0xce,_0x10a626[_0x540193('0x2')](_0x293e98),_0x10a626[_0x540193('0x1f')](_0x540193('0xe'),_0x5b9f73+'-'+_0x19ee3a+'/'+_0x273eb8)['json'](_0x6a3cc3);}return null;};}function saveUpdates(_0x576bd7){return function(_0x4b244a){const _0x45e7f3=a678_0x1c2e;if(_0x4b244a)return _0x4b244a[_0x45e7f3('0x13')](_0x576bd7)[_0x45e7f3('0x27')](function(_0x3b5697){return _0x3b5697;});return null;};}function removeEntity(_0x42c1ed){return function(_0x28d61a){const _0x15010f=a678_0x1c2e;if(_0x28d61a)return _0x28d61a[_0x15010f('0x31')]()['then'](function(){const _0x58e199=_0x15010f;_0x42c1ed[_0x58e199('0x2')](0xcc)['end']();});};}function handleEntityNotFound(_0x115eea){return function(_0x478b1b){const _0x5af7f5=a678_0x1c2e;return!_0x478b1b&&_0x115eea[_0x5af7f5('0x17')](0x194),_0x478b1b;};}function handleError(_0x39643d,_0x302b5e){return _0x302b5e=_0x302b5e||0x1f4,function(_0x3b1e9a){const _0x8a6dc6=a678_0x1c2e;logger[_0x8a6dc6('0x12')](_0x3b1e9a[_0x8a6dc6('0x1e')]),_0x3b1e9a[_0x8a6dc6('0x2f')]&&delete _0x3b1e9a[_0x8a6dc6('0x2f')],_0x39643d['status'](_0x302b5e)[_0x8a6dc6('0x21')](_0x3b1e9a);};}exports[_0x4e620d('0x26')]=function(_0x3f7138,_0x48e5ec){const _0x1a5a94=_0x4e620d;let _0x1e4b93={};const _0x404483={},_0x5d0fa0={'count':0x0,'rows':[]},_0x498cf2=_[_0x1a5a94('0x14')](db['UserProfileSection']['rawAttributes'],function(_0x5284a8){const _0x61ca2=_0x1a5a94;return{'name':_0x5284a8[_0x61ca2('0x23')],'type':_0x5284a8[_0x61ca2('0xa')]['key']};});_0x404483[_0x1a5a94('0xb')]=_['map'](_0x498cf2,_0x1a5a94('0x2f')),_0x404483[_0x1a5a94('0x0')]=_[_0x1a5a94('0x19')](_0x3f7138[_0x1a5a94('0x0')]),_0x404483['filters']=_[_0x1a5a94('0xf')](_0x404483[_0x1a5a94('0xb')],_0x404483[_0x1a5a94('0x0')]),_0x1e4b93[_0x1a5a94('0x1c')]=_[_0x1a5a94('0xf')](_0x404483['model'],qs[_0x1a5a94('0x5')](_0x3f7138[_0x1a5a94('0x0')]['fields'])),_0x1e4b93[_0x1a5a94('0x1c')]=_0x1e4b93[_0x1a5a94('0x1c')][_0x1a5a94('0x9')]?_0x1e4b93['attributes']:_0x404483[_0x1a5a94('0xb')];typeof _0x3f7138[_0x1a5a94('0x0')][_0x1a5a94('0x16')]===_0x1a5a94('0x32')&&(_0x1e4b93[_0x1a5a94('0x7')]=qs['limit'](_0x3f7138[_0x1a5a94('0x0')][_0x1a5a94('0x7')]),_0x1e4b93[_0x1a5a94('0x6')]=qs[_0x1a5a94('0x6')](_0x3f7138[_0x1a5a94('0x0')]['offset']));_0x1e4b93[_0x1a5a94('0x8')]=qs[_0x1a5a94('0x1')](_0x3f7138[_0x1a5a94('0x0')][_0x1a5a94('0x1')]),_0x1e4b93[_0x1a5a94('0x2d')]=qs[_0x1a5a94('0x2c')](_[_0x1a5a94('0x1d')](_0x3f7138[_0x1a5a94('0x0')],_0x404483['filters']),_0x498cf2);_0x3f7138[_0x1a5a94('0x0')]['filter']&&(_0x1e4b93['where']=_[_0x1a5a94('0x11')](_0x1e4b93[_0x1a5a94('0x2d')],{[Op['or']]:_[_0x1a5a94('0x14')](_0x498cf2,function(_0x10f920){const _0xe3cfc2=_0x1a5a94;if(_0x10f920[_0xe3cfc2('0xa')]!==_0xe3cfc2('0x24')){const _0x2dedf1={};return _0x2dedf1[_0x10f920[_0xe3cfc2('0x2f')]]={[Op['like']]:'%'+_0x3f7138[_0xe3cfc2('0x0')]['filter']+'%'},_0x2dedf1;}})}));_0x1e4b93=_['merge']({},_0x1e4b93,_0x3f7138[_0x1a5a94('0x2b')]);const _0x4f115b={'where':_0x1e4b93[_0x1a5a94('0x2d')]};return db[_0x1a5a94('0x22')][_0x1a5a94('0x1a')](_0x4f115b)[_0x1a5a94('0x27')](function(_0x2787ec){const _0x2958c4=_0x1a5a94;return _0x5d0fa0['count']=_0x2787ec,_0x3f7138[_0x2958c4('0x0')][_0x2958c4('0xd')]&&(_0x1e4b93[_0x2958c4('0x15')]=[{'all':!![]}]),db['UserProfileSection'][_0x2958c4('0x3')](_0x1e4b93);})[_0x1a5a94('0x27')](function(_0x314dc3){const _0xeaa8fe=_0x1a5a94;return _0x5d0fa0[_0xeaa8fe('0x28')]=_0x314dc3,_0x5d0fa0;})['then'](respondWithFilteredResult(_0x48e5ec,_0x1e4b93))[_0x1a5a94('0x4')](handleError(_0x48e5ec,null));},exports[_0x4e620d('0x1b')]=function(_0x2b0ded,_0xed255e){const _0x58a6ea=_0x4e620d;let _0x47fdd3={'raw':![],'where':{'id':_0x2b0ded[_0x58a6ea('0x29')]['id']}};const _0x39ae74={};return _0x39ae74[_0x58a6ea('0xb')]=_['keys'](db[_0x58a6ea('0x22')]['rawAttributes']),_0x39ae74[_0x58a6ea('0x0')]=_[_0x58a6ea('0x19')](_0x2b0ded[_0x58a6ea('0x0')]),_0x39ae74['filters']=_[_0x58a6ea('0xf')](_0x39ae74[_0x58a6ea('0xb')],_0x39ae74[_0x58a6ea('0x0')]),_0x47fdd3[_0x58a6ea('0x1c')]=_[_0x58a6ea('0xf')](_0x39ae74['model'],qs[_0x58a6ea('0x5')](_0x2b0ded[_0x58a6ea('0x0')][_0x58a6ea('0x5')])),_0x47fdd3[_0x58a6ea('0x1c')]=_0x47fdd3['attributes'][_0x58a6ea('0x9')]?_0x47fdd3[_0x58a6ea('0x1c')]:_0x39ae74[_0x58a6ea('0xb')],_0x2b0ded[_0x58a6ea('0x0')][_0x58a6ea('0xd')]&&(_0x47fdd3[_0x58a6ea('0x15')]=[{'all':!![]}]),_0x47fdd3=_['merge']({},_0x47fdd3,_0x2b0ded[_0x58a6ea('0x2b')]),db[_0x58a6ea('0x22')][_0x58a6ea('0x10')](_0x47fdd3)['then'](handleEntityNotFound(_0xed255e,null))[_0x58a6ea('0x27')](respondWithResult(_0xed255e,null))[_0x58a6ea('0x4')](handleError(_0xed255e,null));},exports[_0x4e620d('0x2a')]=function(_0x1c1897,_0xf9b8ea){const _0x2c5761=_0x4e620d;return db['UserProfileSection']['create'](_0x1c1897[_0x2c5761('0x30')],{})[_0x2c5761('0x27')](respondWithResult(_0xf9b8ea,0xc9))[_0x2c5761('0x4')](handleError(_0xf9b8ea,null));},exports[_0x4e620d('0x13')]=function(_0x119e3e,_0x3dffaf){const _0x49972c=_0x4e620d;return _0x119e3e[_0x49972c('0x30')]['id']&&delete _0x119e3e[_0x49972c('0x30')]['id'],db['UserProfileSection'][_0x49972c('0x10')]({'where':{'id':_0x119e3e[_0x49972c('0x29')]['id']}})['then'](handleEntityNotFound(_0x3dffaf,null))['then'](saveUpdates(_0x119e3e[_0x49972c('0x30')],null))['then'](respondWithResult(_0x3dffaf,null))['catch'](handleError(_0x3dffaf,null));},exports['destroy']=function(_0x5e91e6,_0xc543b0){const _0x385286=_0x4e620d;return db[_0x385286('0x22')]['findOne']({'where':{'id':_0x5e91e6[_0x385286('0x29')]['id']}})[_0x385286('0x27')](handleEntityNotFound(_0xc543b0,null))[_0x385286('0x27')](removeEntity(_0xc543b0,null))['catch'](handleError(_0xc543b0,null));},exports[_0x4e620d('0xc')]=function(_0x100dd3,_0x47e79b){const _0x3e7b31=_0x4e620d;return db[_0x3e7b31('0x22')][_0x3e7b31('0xc')]()[_0x3e7b31('0x27')](respondWithResult(_0x47e79b,null))['catch'](handleError(_0x47e79b,null));}; \ No newline at end of file diff --git a/server/api/userProfileSection/userProfileSection.model.js b/server/api/userProfileSection/userProfileSection.model.js index 4803443..605730b 100644 --- a/server/api/userProfileSection/userProfileSection.model.js +++ b/server/api/userProfileSection/userProfileSection.model.js @@ -1 +1 @@ -const a679_0x2917=['sectionId','user_profile_has_sections','compositeIndex','define','userProfileId','exports'];(function(_0x59ede9,_0x2917fa){const _0x2e3ee8=function(_0x338cce){while(--_0x338cce){_0x59ede9['push'](_0x59ede9['shift']());}};_0x2e3ee8(++_0x2917fa);}(a679_0x2917,0x14d));const a679_0x2e3e=function(_0x59ede9,_0x2917fa){_0x59ede9=_0x59ede9-0x0;let _0x2e3ee8=a679_0x2917[_0x59ede9];return _0x2e3ee8;};const _0x344cc2=a679_0x2e3e;'use strict';const attributes=require('./userProfileSection.attributes');module[_0x344cc2('0x2')]=function(_0x338cce){const _0x7b1031=_0x344cc2,_0x18e7b6=_0x338cce[_0x7b1031('0x0')]('UserProfileSection',attributes,{'tableName':_0x7b1031('0x4'),'paranoid':![],'indexes':[{'name':_0x7b1031('0x5'),'fields':[_0x7b1031('0x3'),_0x7b1031('0x1')]}],'timestamps':!![]});return _0x18e7b6;}; \ No newline at end of file +const a679_0x2adb=['user_profile_has_sections','exports','sectionId','./userProfileSection.attributes','userProfileId'];(function(_0x4c576d,_0x2adb18){const _0x24ad36=function(_0x8362ab){while(--_0x8362ab){_0x4c576d['push'](_0x4c576d['shift']());}};_0x24ad36(++_0x2adb18);}(a679_0x2adb,0x1b1));const a679_0x24ad=function(_0x4c576d,_0x2adb18){_0x4c576d=_0x4c576d-0x0;let _0x24ad36=a679_0x2adb[_0x4c576d];return _0x24ad36;};const _0x1d53f7=a679_0x24ad;'use strict';const attributes=require(_0x1d53f7('0x0'));module[_0x1d53f7('0x3')]=function(_0x8362ab){const _0x5e0b4f=_0x1d53f7,_0x57b36c=_0x8362ab['define']('UserProfileSection',attributes,{'tableName':_0x5e0b4f('0x2'),'paranoid':![],'indexes':[{'name':'compositeIndex','fields':[_0x5e0b4f('0x4'),_0x5e0b4f('0x1')]}],'timestamps':!![]});return _0x57b36c;}; \ No newline at end of file diff --git a/server/api/userSmsQueue/index.js b/server/api/userSmsQueue/index.js index d375132..87ab1b5 100644 --- a/server/api/userSmsQueue/index.js +++ b/server/api/userSmsQueue/index.js @@ -1 +1 @@ -const a680_0xf12b=['exports','Router','express'];(function(_0x18de28,_0xf12be7){const _0xc43983=function(_0x3ce751){while(--_0x3ce751){_0x18de28['push'](_0x18de28['shift']());}};_0xc43983(++_0xf12be7);}(a680_0xf12b,0x1d9));const a680_0xc439=function(_0x18de28,_0xf12be7){_0x18de28=_0x18de28-0x0;let _0xc43983=a680_0xf12b[_0x18de28];return _0xc43983;};const _0x5878dc=a680_0xc439;'use strict';const express=require(_0x5878dc('0x0')),router=express[_0x5878dc('0x2')]();module[_0x5878dc('0x1')]=router; \ No newline at end of file +const a680_0x5bb6=['Router'];(function(_0x51d145,_0x5bb6e1){const _0x3b14d5=function(_0x488004){while(--_0x488004){_0x51d145['push'](_0x51d145['shift']());}};_0x3b14d5(++_0x5bb6e1);}(a680_0x5bb6,0x160));const a680_0x3b14=function(_0x51d145,_0x5bb6e1){_0x51d145=_0x51d145-0x0;let _0x3b14d5=a680_0x5bb6[_0x51d145];return _0x3b14d5;};const _0x203e76=a680_0x3b14;'use strict';const express=require('express'),router=express[_0x203e76('0x0')]();module['exports']=router; \ No newline at end of file diff --git a/server/api/userSmsQueue/userSmsQueue.attributes.js b/server/api/userSmsQueue/userSmsQueue.attributes.js index b090927..dda1659 100644 --- a/server/api/userSmsQueue/userSmsQueue.attributes.js +++ b/server/api/userSmsQueue/userSmsQueue.attributes.js @@ -1 +1 @@ -const a681_0x2a78=['INTEGER','exports','sequelize'];(function(_0x5b2ad3,_0x2a78d5){const _0x7d1c3d=function(_0x283621){while(--_0x283621){_0x5b2ad3['push'](_0x5b2ad3['shift']());}};_0x7d1c3d(++_0x2a78d5);}(a681_0x2a78,0x69));const a681_0x7d1c=function(_0x5b2ad3,_0x2a78d5){_0x5b2ad3=_0x5b2ad3-0x0;let _0x7d1c3d=a681_0x2a78[_0x5b2ad3];return _0x7d1c3d;};const _0xd323d6=a681_0x7d1c;'use strict';const Sequelize=require(_0xd323d6('0x2'));module[_0xd323d6('0x1')]={'penalty':{'type':Sequelize[_0xd323d6('0x0')],'defaultValue':0x0}}; \ No newline at end of file +const a681_0x4cb2=['sequelize','INTEGER','exports'];(function(_0x1aab66,_0x4cb216){const _0x199fca=function(_0x1e587d){while(--_0x1e587d){_0x1aab66['push'](_0x1aab66['shift']());}};_0x199fca(++_0x4cb216);}(a681_0x4cb2,0x198));const a681_0x199f=function(_0x1aab66,_0x4cb216){_0x1aab66=_0x1aab66-0x0;let _0x199fca=a681_0x4cb2[_0x1aab66];return _0x199fca;};const _0x26a722=a681_0x199f;'use strict';const Sequelize=require(_0x26a722('0x0'));module[_0x26a722('0x2')]={'penalty':{'type':Sequelize[_0x26a722('0x1')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/userSmsQueue/userSmsQueue.model.js b/server/api/userSmsQueue/userSmsQueue.model.js index 7668458..d6ddb80 100644 --- a/server/api/userSmsQueue/userSmsQueue.model.js +++ b/server/api/userSmsQueue/userSmsQueue.model.js @@ -1 +1 @@ -const a682_0xf670=['define','UserSmsQueue','user_has_sms_queues','exports','./userSmsQueue.attributes'];(function(_0x4e1672,_0xf67028){const _0x3963a4=function(_0x3060ac){while(--_0x3060ac){_0x4e1672['push'](_0x4e1672['shift']());}};_0x3963a4(++_0xf67028);}(a682_0xf670,0x77));const a682_0x3963=function(_0x4e1672,_0xf67028){_0x4e1672=_0x4e1672-0x0;let _0x3963a4=a682_0xf670[_0x4e1672];return _0x3963a4;};const _0x30c444=a682_0x3963;'use strict';const attributes=require(_0x30c444('0x0'));module[_0x30c444('0x4')]=function(_0x3060ac){const _0x1c6793=_0x30c444,_0x12fee4=_0x3060ac[_0x1c6793('0x1')](_0x1c6793('0x2'),attributes,{'tableName':_0x1c6793('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x12fee4;}; \ No newline at end of file +const a682_0x3842=['user_has_sms_queues','define','./userSmsQueue.attributes','exports','UserSmsQueue'];(function(_0x2fb0fe,_0x3842af){const _0x42108f=function(_0x4dce58){while(--_0x4dce58){_0x2fb0fe['push'](_0x2fb0fe['shift']());}};_0x42108f(++_0x3842af);}(a682_0x3842,0x6a));const a682_0x4210=function(_0x2fb0fe,_0x3842af){_0x2fb0fe=_0x2fb0fe-0x0;let _0x42108f=a682_0x3842[_0x2fb0fe];return _0x42108f;};const _0x32dd97=a682_0x4210;'use strict';const attributes=require(_0x32dd97('0x1'));module[_0x32dd97('0x2')]=function(_0x4dce58){const _0x3281a3=_0x32dd97,_0x18e978=_0x4dce58[_0x3281a3('0x0')](_0x3281a3('0x3'),attributes,{'tableName':_0x3281a3('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x18e978;}; \ No newline at end of file diff --git a/server/api/userVoiceQueue/index.js b/server/api/userVoiceQueue/index.js index 6db3570..3197126 100644 --- a/server/api/userVoiceQueue/index.js +++ b/server/api/userVoiceQueue/index.js @@ -1 +1 @@ -const a683_0x2f9c=['Router','exports'];(function(_0x589962,_0x2f9cc9){const _0x5eae6a=function(_0x58552a){while(--_0x58552a){_0x589962['push'](_0x589962['shift']());}};_0x5eae6a(++_0x2f9cc9);}(a683_0x2f9c,0x161));const a683_0x5eae=function(_0x589962,_0x2f9cc9){_0x589962=_0x589962-0x0;let _0x5eae6a=a683_0x2f9c[_0x589962];return _0x5eae6a;};const _0x3c0ceb=a683_0x5eae;'use strict';const express=require('express'),router=express[_0x3c0ceb('0x1')]();module[_0x3c0ceb('0x0')]=router; \ No newline at end of file +const a683_0x4773=['exports','express'];(function(_0x5d7f02,_0x47739c){const _0x8acb65=function(_0x4172c5){while(--_0x4172c5){_0x5d7f02['push'](_0x5d7f02['shift']());}};_0x8acb65(++_0x47739c);}(a683_0x4773,0xe6));const a683_0x8acb=function(_0x5d7f02,_0x47739c){_0x5d7f02=_0x5d7f02-0x0;let _0x8acb65=a683_0x4773[_0x5d7f02];return _0x8acb65;};const _0x14378e=a683_0x8acb;'use strict';const express=require(_0x14378e('0x1')),router=express['Router']();module[_0x14378e('0x0')]=router; \ No newline at end of file diff --git a/server/api/userVoiceQueue/userVoiceQueue.attributes.js b/server/api/userVoiceQueue/userVoiceQueue.attributes.js index 8fe550e..060167b 100644 --- a/server/api/userVoiceQueue/userVoiceQueue.attributes.js +++ b/server/api/userVoiceQueue/userVoiceQueue.attributes.js @@ -1 +1 @@ -const a684_0x4904=['exports','sequelize'];(function(_0x4551ad,_0x490473){const _0x3600ed=function(_0x3b02fa){while(--_0x3b02fa){_0x4551ad['push'](_0x4551ad['shift']());}};_0x3600ed(++_0x490473);}(a684_0x4904,0x152));const a684_0x3600=function(_0x4551ad,_0x490473){_0x4551ad=_0x4551ad-0x0;let _0x3600ed=a684_0x4904[_0x4551ad];return _0x3600ed;};const _0x22f9cc=a684_0x3600;'use strict';const Sequelize=require(_0x22f9cc('0x1'));module[_0x22f9cc('0x0')]={'penalty':{'type':Sequelize['INTEGER'],'defaultValue':0x0}}; \ No newline at end of file +const a684_0x5ca7=['INTEGER','sequelize','exports'];(function(_0x1eaab,_0x5ca773){const _0x2f1bdc=function(_0x43d133){while(--_0x43d133){_0x1eaab['push'](_0x1eaab['shift']());}};_0x2f1bdc(++_0x5ca773);}(a684_0x5ca7,0xcd));const a684_0x2f1b=function(_0x1eaab,_0x5ca773){_0x1eaab=_0x1eaab-0x0;let _0x2f1bdc=a684_0x5ca7[_0x1eaab];return _0x2f1bdc;};const _0x5224af=a684_0x2f1b;'use strict';const Sequelize=require(_0x5224af('0x0'));module[_0x5224af('0x1')]={'penalty':{'type':Sequelize[_0x5224af('0x2')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/userVoiceQueue/userVoiceQueue.model.js b/server/api/userVoiceQueue/userVoiceQueue.model.js index fd6a6d2..6791ddb 100644 --- a/server/api/userVoiceQueue/userVoiceQueue.model.js +++ b/server/api/userVoiceQueue/userVoiceQueue.model.js @@ -1 +1 @@ -const a685_0x287b=['./userVoiceQueue.attributes','exports','UserVoiceQueue','define','user_has_voice_queues'];(function(_0x31db4e,_0x287bf3){const _0x273595=function(_0x1571cb){while(--_0x1571cb){_0x31db4e['push'](_0x31db4e['shift']());}};_0x273595(++_0x287bf3);}(a685_0x287b,0x149));const a685_0x2735=function(_0x31db4e,_0x287bf3){_0x31db4e=_0x31db4e-0x0;let _0x273595=a685_0x287b[_0x31db4e];return _0x273595;};const _0x345b4c=a685_0x2735;'use strict';const attributes=require(_0x345b4c('0x1'));module[_0x345b4c('0x2')]=function(_0x1571cb){const _0x2ee056=_0x345b4c,_0x36b269=_0x1571cb[_0x2ee056('0x4')](_0x2ee056('0x3'),attributes,{'tableName':_0x2ee056('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x36b269;}; \ No newline at end of file +const a685_0x6d7e=['define','UserVoiceQueue','user_has_voice_queues','exports'];(function(_0x180782,_0x6d7e18){const _0x2c578f=function(_0x43c151){while(--_0x43c151){_0x180782['push'](_0x180782['shift']());}};_0x2c578f(++_0x6d7e18);}(a685_0x6d7e,0x80));const a685_0x2c57=function(_0x180782,_0x6d7e18){_0x180782=_0x180782-0x0;let _0x2c578f=a685_0x6d7e[_0x180782];return _0x2c578f;};const _0x2e3479=a685_0x2c57;'use strict';const attributes=require('./userVoiceQueue.attributes');module[_0x2e3479('0x3')]=function(_0x43c151){const _0x26e712=_0x2e3479,_0x57ae50=_0x43c151[_0x26e712('0x0')](_0x26e712('0x1'),attributes,{'tableName':_0x26e712('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x57ae50;}; \ No newline at end of file diff --git a/server/api/userVoiceQueueRt/index.js b/server/api/userVoiceQueueRt/index.js index 77817ca..c543e30 100644 --- a/server/api/userVoiceQueueRt/index.js +++ b/server/api/userVoiceQueueRt/index.js @@ -1 +1 @@ -const a686_0x198a=['Router','exports'];(function(_0x5a9319,_0x198ac3){const _0x71011b=function(_0x4884a6){while(--_0x4884a6){_0x5a9319['push'](_0x5a9319['shift']());}};_0x71011b(++_0x198ac3);}(a686_0x198a,0x11b));const a686_0x7101=function(_0x5a9319,_0x198ac3){_0x5a9319=_0x5a9319-0x0;let _0x71011b=a686_0x198a[_0x5a9319];return _0x71011b;};const _0x2a7d00=a686_0x7101;'use strict';const express=require('express'),router=express[_0x2a7d00('0x1')]();module[_0x2a7d00('0x0')]=router; \ No newline at end of file +const a686_0x1f16=['exports','express','Router'];(function(_0x11305e,_0x1f1638){const _0x216f60=function(_0x3636a4){while(--_0x3636a4){_0x11305e['push'](_0x11305e['shift']());}};_0x216f60(++_0x1f1638);}(a686_0x1f16,0x1ef));const a686_0x216f=function(_0x11305e,_0x1f1638){_0x11305e=_0x11305e-0x0;let _0x216f60=a686_0x1f16[_0x11305e];return _0x216f60;};const _0x2fc034=a686_0x216f;'use strict';const express=require(_0x2fc034('0x1')),router=express[_0x2fc034('0x2')]();module[_0x2fc034('0x0')]=router; \ No newline at end of file diff --git a/server/api/userVoiceQueueRt/userVoiceQueueRt.attributes.js b/server/api/userVoiceQueueRt/userVoiceQueueRt.attributes.js index bb84dc5..617b1ea 100644 --- a/server/api/userVoiceQueueRt/userVoiceQueueRt.attributes.js +++ b/server/api/userVoiceQueueRt/userVoiceQueueRt.attributes.js @@ -1 +1 @@ -const a687_0x14dd=['INTEGER','queue_interface','exports','STRING','Required\x20by\x20Asterisk'];(function(_0x1063a8,_0x14ddf8){const _0x3d7fb1=function(_0x56dba3){while(--_0x56dba3){_0x1063a8['push'](_0x1063a8['shift']());}};_0x3d7fb1(++_0x14ddf8);}(a687_0x14dd,0x13b));const a687_0x3d7f=function(_0x1063a8,_0x14ddf8){_0x1063a8=_0x1063a8-0x0;let _0x3d7fb1=a687_0x14dd[_0x1063a8];return _0x3d7fb1;};const _0xf4161c=a687_0x3d7f;'use strict';const Sequelize=require('sequelize');module[_0xf4161c('0x2')]={'uniqueid':{'type':Sequelize[_0xf4161c('0x0')],'primaryKey':!![],'autoIncrement':!![],'comment':_0xf4161c('0x4')},'membername':{'type':Sequelize[_0xf4161c('0x3')],'allowNull':![],'comment':_0xf4161c('0x4')},'UserId':{'type':Sequelize[_0xf4161c('0x0')],'allowNull':![]},'queue_name':{'type':Sequelize[_0xf4161c('0x3')],'allowNull':![],'unique':_0xf4161c('0x1'),'comment':_0xf4161c('0x4')},'VoiceQueueId':{'type':Sequelize[_0xf4161c('0x0')],'allowNull':![]},'interface':{'type':Sequelize[_0xf4161c('0x3')],'allowNull':![],'unique':_0xf4161c('0x1'),'comment':_0xf4161c('0x4')},'penalty':{'type':Sequelize[_0xf4161c('0x0')](0xb),'defaultValue':0x0,'comment':_0xf4161c('0x4')},'paused':{'type':Sequelize[_0xf4161c('0x0')](0xb),'defaultValue':0x0,'comment':_0xf4161c('0x4')}}; \ No newline at end of file +const a687_0x56a5=['INTEGER','queue_interface','exports','STRING','sequelize','Required\x20by\x20Asterisk'];(function(_0x519777,_0x56a5d2){const _0x4cc841=function(_0x1528f9){while(--_0x1528f9){_0x519777['push'](_0x519777['shift']());}};_0x4cc841(++_0x56a5d2);}(a687_0x56a5,0x88));const a687_0x4cc8=function(_0x519777,_0x56a5d2){_0x519777=_0x519777-0x0;let _0x4cc841=a687_0x56a5[_0x519777];return _0x4cc841;};const _0x1931d5=a687_0x4cc8;'use strict';const Sequelize=require(_0x1931d5('0x0'));module[_0x1931d5('0x4')]={'uniqueid':{'type':Sequelize[_0x1931d5('0x2')],'primaryKey':!![],'autoIncrement':!![],'comment':'Required\x20by\x20Asterisk'},'membername':{'type':Sequelize['STRING'],'allowNull':![],'comment':_0x1931d5('0x1')},'UserId':{'type':Sequelize[_0x1931d5('0x2')],'allowNull':![]},'queue_name':{'type':Sequelize[_0x1931d5('0x5')],'allowNull':![],'unique':'queue_interface','comment':_0x1931d5('0x1')},'VoiceQueueId':{'type':Sequelize[_0x1931d5('0x2')],'allowNull':![]},'interface':{'type':Sequelize['STRING'],'allowNull':![],'unique':_0x1931d5('0x3'),'comment':_0x1931d5('0x1')},'penalty':{'type':Sequelize['INTEGER'](0xb),'defaultValue':0x0,'comment':_0x1931d5('0x1')},'paused':{'type':Sequelize['INTEGER'](0xb),'defaultValue':0x0,'comment':_0x1931d5('0x1')}}; \ No newline at end of file diff --git a/server/api/userVoiceQueueRt/userVoiceQueueRt.events.js b/server/api/userVoiceQueueRt/userVoiceQueueRt.events.js index 951ffeb..ba72cca 100644 --- a/server/api/userVoiceQueueRt/userVoiceQueueRt.events.js +++ b/server/api/userVoiceQueueRt/userVoiceQueueRt.events.js @@ -1 +1 @@ -const a688_0x86a7=['undefined','UserVoiceQueueRt','events','emit','addHook','remove','save','update','../../mysqldb','exports','setMaxListeners'];(function(_0x4c6fbd,_0x86a77f){const _0x33937d=function(_0x30bfef){while(--_0x30bfef){_0x4c6fbd['push'](_0x4c6fbd['shift']());}};_0x33937d(++_0x86a77f);}(a688_0x86a7,0xeb));const a688_0x3393=function(_0x4c6fbd,_0x86a77f){_0x4c6fbd=_0x4c6fbd-0x0;let _0x33937d=a688_0x86a7[_0x4c6fbd];return _0x33937d;};const _0x4feb38=a688_0x3393;'use strict';const EventEmitter=require(_0x4feb38('0x9')),UserVoiceQueueRt=require(_0x4feb38('0x4'))['db'][_0x4feb38('0x8')],UserVoiceQueueRtEvents=new EventEmitter();UserVoiceQueueRtEvents[_0x4feb38('0x6')](0x0);const events={'afterCreate':_0x4feb38('0x2'),'afterUpdate':_0x4feb38('0x3'),'afterDestroy':_0x4feb38('0x1')};function emitEvent(_0x30bfef){return function(_0xd1c596){const _0x380bec=a688_0x3393;UserVoiceQueueRtEvents[_0x380bec('0xa')](_0x30bfef+':'+_0xd1c596['id'],_0xd1c596),UserVoiceQueueRtEvents[_0x380bec('0xa')](_0x30bfef,_0xd1c596);};}for(const e in events){if(typeof events[e]!==_0x4feb38('0x7')){const event=events[e];UserVoiceQueueRt[_0x4feb38('0x0')](e,emitEvent(event));}}module[_0x4feb38('0x5')]=UserVoiceQueueRtEvents; \ No newline at end of file +const a688_0x3bde=['remove','../../mysqldb','events','addHook','undefined','exports','emit'];(function(_0x26cbc7,_0x3bdecb){const _0x53ee2c=function(_0xedf655){while(--_0xedf655){_0x26cbc7['push'](_0x26cbc7['shift']());}};_0x53ee2c(++_0x3bdecb);}(a688_0x3bde,0x177));const a688_0x53ee=function(_0x26cbc7,_0x3bdecb){_0x26cbc7=_0x26cbc7-0x0;let _0x53ee2c=a688_0x3bde[_0x26cbc7];return _0x53ee2c;};const _0x41631a=a688_0x53ee;'use strict';const EventEmitter=require(_0x41631a('0x5')),UserVoiceQueueRt=require(_0x41631a('0x4'))['db']['UserVoiceQueueRt'],UserVoiceQueueRtEvents=new EventEmitter();UserVoiceQueueRtEvents['setMaxListeners'](0x0);const events={'afterCreate':'save','afterUpdate':'update','afterDestroy':_0x41631a('0x3')};function emitEvent(_0xedf655){return function(_0x4ea7d2){const _0x599b76=a688_0x53ee;UserVoiceQueueRtEvents[_0x599b76('0x2')](_0xedf655+':'+_0x4ea7d2['id'],_0x4ea7d2),UserVoiceQueueRtEvents[_0x599b76('0x2')](_0xedf655,_0x4ea7d2);};}for(const e in events){if(typeof events[e]!==_0x41631a('0x0')){const event=events[e];UserVoiceQueueRt[_0x41631a('0x6')](e,emitEvent(event));}}module[_0x41631a('0x1')]=UserVoiceQueueRtEvents; \ No newline at end of file diff --git a/server/api/userVoiceQueueRt/userVoiceQueueRt.model.js b/server/api/userVoiceQueueRt/userVoiceQueueRt.model.js index cb66aee..378f43e 100644 --- a/server/api/userVoiceQueueRt/userVoiceQueueRt.model.js +++ b/server/api/userVoiceQueueRt/userVoiceQueueRt.model.js @@ -1 +1 @@ -const a689_0x4306=['define','user_has_voice_queues_rt','./userVoiceQueueRt.attributes'];(function(_0x2d5ef7,_0x430661){const _0x3cab17=function(_0x2fcb31){while(--_0x2fcb31){_0x2d5ef7['push'](_0x2d5ef7['shift']());}};_0x3cab17(++_0x430661);}(a689_0x4306,0x1f2));const a689_0x3cab=function(_0x2d5ef7,_0x430661){_0x2d5ef7=_0x2d5ef7-0x0;let _0x3cab17=a689_0x4306[_0x2d5ef7];return _0x3cab17;};const _0x121b9c=a689_0x3cab;'use strict';const attributes=require(_0x121b9c('0x2'));module['exports']=function(_0x2fcb31){const _0x5243d1=_0x121b9c,_0x2fb3e9=_0x2fcb31[_0x5243d1('0x0')]('UserVoiceQueueRt',attributes,{'tableName':_0x5243d1('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x2fb3e9;}; \ No newline at end of file +const a689_0x1de4=['UserVoiceQueueRt','exports','./userVoiceQueueRt.attributes','user_has_voice_queues_rt','define'];(function(_0x5dc0ad,_0x1de431){const _0x3645a3=function(_0x5f4315){while(--_0x5f4315){_0x5dc0ad['push'](_0x5dc0ad['shift']());}};_0x3645a3(++_0x1de431);}(a689_0x1de4,0x1ed));const a689_0x3645=function(_0x5dc0ad,_0x1de431){_0x5dc0ad=_0x5dc0ad-0x0;let _0x3645a3=a689_0x1de4[_0x5dc0ad];return _0x3645a3;};const _0x17ace8=a689_0x3645;'use strict';const attributes=require(_0x17ace8('0x4'));module[_0x17ace8('0x3')]=function(_0x5f4315){const _0x36082a=_0x17ace8,_0x3d4f2e=_0x5f4315[_0x36082a('0x1')](_0x36082a('0x2'),attributes,{'tableName':_0x36082a('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3d4f2e;}; \ No newline at end of file diff --git a/server/api/userVoiceQueueRt/userVoiceQueueRt.rpc.js b/server/api/userVoiceQueueRt/userVoiceQueueRt.rpc.js index 33632da..1132d72 100644 --- a/server/api/userVoiceQueueRt/userVoiceQueueRt.rpc.js +++ b/server/api/userVoiceQueueRt/userVoiceQueueRt.rpc.js @@ -1 +1 @@ -const a690_0x46b2=['rpc','../../config/logger','info','error','sequelize','COUNT','message','findAll','then','where','register','UserVoiceQueueRt','stringify','../../mysqldb','options','./userVoiceQueueRt.socket','outboundQueuePauses','raw','debug','GetVoiceQueueRtPauses','`paused`\x20=\x201,\x201,\x20null','../../rediscache'];(function(_0x45bb0d,_0x46b273){const _0x3f0f36=function(_0x2ebc7f){while(--_0x2ebc7f){_0x45bb0d['push'](_0x45bb0d['shift']());}};_0x3f0f36(++_0x46b273);}(a690_0x46b2,0xf7));const a690_0x3f0f=function(_0x45bb0d,_0x46b273){_0x45bb0d=_0x45bb0d-0x0;let _0x3f0f36=a690_0x46b2[_0x45bb0d];return _0x3f0f36;};const _0xd87224=a690_0x3f0f;'use strict';const db=require(_0xd87224('0x8'))['db'],{fn,literal}=require(_0xd87224('0x15')),logger=require(_0xd87224('0x12'))(_0xd87224('0x11')),{getSocket}=require(_0xd87224('0x10')),socket=getSocket();require(_0xd87224('0xa'))[_0xd87224('0x5')](socket),exports[_0xd87224('0xe')]=function(_0x2ebc7f){const _0x471511=this;return new Promise(function(_0x218a2b,_0x54532f){const _0x3a2656=a690_0x3f0f;return db[_0x3a2656('0x6')][_0x3a2656('0x2')]({'raw':_0x2ebc7f[_0x3a2656('0x9')]?_0x2ebc7f[_0x3a2656('0x9')][_0x3a2656('0xc')]===undefined?!![]:![]:!![],'where':_0x2ebc7f[_0x3a2656('0x9')]?_0x2ebc7f[_0x3a2656('0x9')][_0x3a2656('0x4')]||null:null,'attributes':[[fn(_0x3a2656('0x0'),fn('IF',literal(_0x3a2656('0xf')))),_0x3a2656('0xb')]]})[_0x3a2656('0x3')](function(_0x1b78fe){const _0x4c535f=_0x3a2656;logger[_0x4c535f('0x13')]('GetVoiceQueueRtPauses',_0x2ebc7f),logger[_0x4c535f('0xd')]('GetVoiceQueueRtPauses',_0x2ebc7f,JSON[_0x4c535f('0x7')](_0x1b78fe)),_0x218a2b(_0x1b78fe);})['catch'](function(_0x212589){const _0x2b5b5e=_0x3a2656;logger[_0x2b5b5e('0x14')](_0x2b5b5e('0xe'),_0x212589[_0x2b5b5e('0x1')],_0x2ebc7f),_0x54532f(_0x471511[_0x2b5b5e('0x14')](0x1f4,_0x212589[_0x2b5b5e('0x1')]));});});}; \ No newline at end of file +const a690_0xffaf=['findAll','options','where','debug','message','COUNT','`paused`\x20=\x201,\x201,\x20null','sequelize','stringify','./userVoiceQueueRt.socket','info','then','../../mysqldb','raw','outboundQueuePauses','../../config/logger','error','GetVoiceQueueRtPauses'];(function(_0x408d63,_0xffaf6e){const _0x3beab5=function(_0x377c13){while(--_0x377c13){_0x408d63['push'](_0x408d63['shift']());}};_0x3beab5(++_0xffaf6e);}(a690_0xffaf,0x19f));const a690_0x3bea=function(_0x408d63,_0xffaf6e){_0x408d63=_0x408d63-0x0;let _0x3beab5=a690_0xffaf[_0x408d63];return _0x3beab5;};const _0x240738=a690_0x3bea;'use strict';const db=require(_0x240738('0xb'))['db'],{fn,literal}=require(_0x240738('0x6')),logger=require(_0x240738('0xe'))('rpc'),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x240738('0x8'))['register'](socket),exports[_0x240738('0x10')]=function(_0x377c13){const _0x671350=this;return new Promise(function(_0x402593,_0x35b38e){const _0x178f49=a690_0x3bea;return db['UserVoiceQueueRt'][_0x178f49('0x11')]({'raw':_0x377c13[_0x178f49('0x0')]?_0x377c13['options'][_0x178f49('0xc')]===undefined?!![]:![]:!![],'where':_0x377c13[_0x178f49('0x0')]?_0x377c13[_0x178f49('0x0')][_0x178f49('0x1')]||null:null,'attributes':[[fn(_0x178f49('0x4'),fn('IF',literal(_0x178f49('0x5')))),_0x178f49('0xd')]]})[_0x178f49('0xa')](function(_0x130bef){const _0x3486e5=_0x178f49;logger[_0x3486e5('0x9')](_0x3486e5('0x10'),_0x377c13),logger[_0x3486e5('0x2')](_0x3486e5('0x10'),_0x377c13,JSON[_0x3486e5('0x7')](_0x130bef)),_0x402593(_0x130bef);})['catch'](function(_0x286627){const _0x5b4596=_0x178f49;logger['error'](_0x5b4596('0x10'),_0x286627[_0x5b4596('0x3')],_0x377c13),_0x35b38e(_0x671350[_0x5b4596('0xf')](0x1f4,_0x286627[_0x5b4596('0x3')]));});});}; \ No newline at end of file diff --git a/server/api/userVoiceQueueRt/userVoiceQueueRt.socket.js b/server/api/userVoiceQueueRt/userVoiceQueueRt.socket.js index d71779f..4f02e6c 100644 --- a/server/api/userVoiceQueueRt/userVoiceQueueRt.socket.js +++ b/server/api/userVoiceQueueRt/userVoiceQueueRt.socket.js @@ -1 +1 @@ -const a691_0x2867=['./userVoiceQueueRt.events','update','save','register','userVoiceQueueRt:','emit'];(function(_0x7d3440,_0x286709){const _0x24fc77=function(_0x47f62e){while(--_0x47f62e){_0x7d3440['push'](_0x7d3440['shift']());}};_0x24fc77(++_0x286709);}(a691_0x2867,0x136));const a691_0x24fc=function(_0x7d3440,_0x286709){_0x7d3440=_0x7d3440-0x0;let _0x24fc77=a691_0x2867[_0x7d3440];return _0x24fc77;};const _0x22ba2a=a691_0x24fc;'use strict';const UserVoiceQueueRtEvents=require(_0x22ba2a('0x2')),events=[_0x22ba2a('0x4'),'remove',_0x22ba2a('0x3')];function createListener(_0x47f62e,_0x2cc8d3){return function(_0x1db739){const _0x4d0353=a691_0x24fc;_0x2cc8d3[_0x4d0353('0x1')](_0x47f62e,_0x1db739);};}exports[_0x22ba2a('0x5')]=function(_0x277553){const _0x1bddfa=_0x22ba2a;for(let _0x1a1e12=0x0,_0x37879d=events['length'];_0x1a1e12<_0x37879d;_0x1a1e12++){const _0x418e46=events[_0x1a1e12],_0x36b259=createListener(_0x1bddfa('0x0')+_0x418e46,_0x277553);UserVoiceQueueRtEvents['on'](_0x418e46,_0x36b259);}}; \ No newline at end of file +const a691_0x3c42=['update','remove','length','register','userVoiceQueueRt:'];(function(_0x5657f4,_0x3c42a1){const _0x4dd49d=function(_0x4b656e){while(--_0x4b656e){_0x5657f4['push'](_0x5657f4['shift']());}};_0x4dd49d(++_0x3c42a1);}(a691_0x3c42,0x106));const a691_0x4dd4=function(_0x5657f4,_0x3c42a1){_0x5657f4=_0x5657f4-0x0;let _0x4dd49d=a691_0x3c42[_0x5657f4];return _0x4dd49d;};const _0x5dc069=a691_0x4dd4;'use strict';const UserVoiceQueueRtEvents=require('./userVoiceQueueRt.events'),events=['save',_0x5dc069('0x4'),_0x5dc069('0x3')];function createListener(_0x4b656e,_0x5ac5dc){return function(_0x18857b){_0x5ac5dc['emit'](_0x4b656e,_0x18857b);};}exports[_0x5dc069('0x1')]=function(_0x23cd6f){const _0xe744b4=_0x5dc069;for(let _0xf7180d=0x0,_0x2f979f=events[_0xe744b4('0x0')];_0xf7180d<_0x2f979f;_0xf7180d++){const _0x2f1ebb=events[_0xf7180d],_0x47f039=createListener(_0xe744b4('0x2')+_0x2f1ebb,_0x23cd6f);UserVoiceQueueRtEvents['on'](_0x2f1ebb,_0x47f039);}}; \ No newline at end of file diff --git a/server/api/userWhatsappQueue/index.js b/server/api/userWhatsappQueue/index.js index 7f45c6b..4d83b6f 100644 --- a/server/api/userWhatsappQueue/index.js +++ b/server/api/userWhatsappQueue/index.js @@ -1 +1 @@ -const a692_0x5651=['Router'];(function(_0x1e0100,_0x565190){const _0x4f3e54=function(_0x5dbc28){while(--_0x5dbc28){_0x1e0100['push'](_0x1e0100['shift']());}};_0x4f3e54(++_0x565190);}(a692_0x5651,0x13e));const a692_0x4f3e=function(_0x1e0100,_0x565190){_0x1e0100=_0x1e0100-0x0;let _0x4f3e54=a692_0x5651[_0x1e0100];return _0x4f3e54;};const _0xa599e4=a692_0x4f3e;'use strict';const express=require('express'),router=express[_0xa599e4('0x0')]();module['exports']=router; \ No newline at end of file +const a692_0x3cab=['exports','Router','express'];(function(_0x4bd3ba,_0x3cab69){const _0x30bb35=function(_0xdd8e97){while(--_0xdd8e97){_0x4bd3ba['push'](_0x4bd3ba['shift']());}};_0x30bb35(++_0x3cab69);}(a692_0x3cab,0x164));const a692_0x30bb=function(_0x4bd3ba,_0x3cab69){_0x4bd3ba=_0x4bd3ba-0x0;let _0x30bb35=a692_0x3cab[_0x4bd3ba];return _0x30bb35;};const _0x2cad1b=a692_0x30bb;'use strict';const express=require(_0x2cad1b('0x0')),router=express[_0x2cad1b('0x2')]();module[_0x2cad1b('0x1')]=router; \ No newline at end of file diff --git a/server/api/userWhatsappQueue/userWhatsappQueue.attributes.js b/server/api/userWhatsappQueue/userWhatsappQueue.attributes.js index 837b7c3..07ef671 100644 --- a/server/api/userWhatsappQueue/userWhatsappQueue.attributes.js +++ b/server/api/userWhatsappQueue/userWhatsappQueue.attributes.js @@ -1 +1 @@ -const a693_0x1c46=['exports','INTEGER','sequelize'];(function(_0x42c84f,_0x1c4613){const _0x4efd6a=function(_0x1745d1){while(--_0x1745d1){_0x42c84f['push'](_0x42c84f['shift']());}};_0x4efd6a(++_0x1c4613);}(a693_0x1c46,0x97));const a693_0x4efd=function(_0x42c84f,_0x1c4613){_0x42c84f=_0x42c84f-0x0;let _0x4efd6a=a693_0x1c46[_0x42c84f];return _0x4efd6a;};const _0x12f00a=a693_0x4efd;'use strict';const Sequelize=require(_0x12f00a('0x1'));module[_0x12f00a('0x2')]={'penalty':{'type':Sequelize[_0x12f00a('0x0')],'defaultValue':0x0}}; \ No newline at end of file +const a693_0x1965=['exports','sequelize','INTEGER'];(function(_0x3de373,_0x196568){const _0x466736=function(_0x4655e6){while(--_0x4655e6){_0x3de373['push'](_0x3de373['shift']());}};_0x466736(++_0x196568);}(a693_0x1965,0xd0));const a693_0x4667=function(_0x3de373,_0x196568){_0x3de373=_0x3de373-0x0;let _0x466736=a693_0x1965[_0x3de373];return _0x466736;};const _0x2c6092=a693_0x4667;'use strict';const Sequelize=require(_0x2c6092('0x0'));module[_0x2c6092('0x2')]={'penalty':{'type':Sequelize[_0x2c6092('0x1')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/userWhatsappQueue/userWhatsappQueue.model.js b/server/api/userWhatsappQueue/userWhatsappQueue.model.js index 5de3118..101e7f6 100644 --- a/server/api/userWhatsappQueue/userWhatsappQueue.model.js +++ b/server/api/userWhatsappQueue/userWhatsappQueue.model.js @@ -1 +1 @@ -const a694_0x203e=['UserWhatsappQueue','user_has_whatsapp_queues','exports','./userWhatsappQueue.attributes','define'];(function(_0x5400fc,_0x203eb1){const _0x496168=function(_0x54dd7e){while(--_0x54dd7e){_0x5400fc['push'](_0x5400fc['shift']());}};_0x496168(++_0x203eb1);}(a694_0x203e,0x197));const a694_0x4961=function(_0x5400fc,_0x203eb1){_0x5400fc=_0x5400fc-0x0;let _0x496168=a694_0x203e[_0x5400fc];return _0x496168;};const _0x3253b1=a694_0x4961;'use strict';const attributes=require(_0x3253b1('0x1'));module[_0x3253b1('0x0')]=function(_0x54dd7e){const _0x317d64=_0x3253b1,_0xc96777=_0x54dd7e[_0x317d64('0x2')](_0x317d64('0x3'),attributes,{'tableName':_0x317d64('0x4'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xc96777;}; \ No newline at end of file +const a694_0x4034=['user_has_whatsapp_queues','exports','./userWhatsappQueue.attributes','UserWhatsappQueue'];(function(_0x34b803,_0x4034b0){const _0x49913b=function(_0x403fed){while(--_0x403fed){_0x34b803['push'](_0x34b803['shift']());}};_0x49913b(++_0x4034b0);}(a694_0x4034,0x7b));const a694_0x4991=function(_0x34b803,_0x4034b0){_0x34b803=_0x34b803-0x0;let _0x49913b=a694_0x4034[_0x34b803];return _0x49913b;};const _0x4be597=a694_0x4991;'use strict';const attributes=require(_0x4be597('0x3'));module[_0x4be597('0x2')]=function(_0x403fed){const _0x196ffc=_0x4be597,_0x147e32=_0x403fed['define'](_0x196ffc('0x0'),attributes,{'tableName':_0x196ffc('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x147e32;}; \ No newline at end of file diff --git a/server/api/variable/index.js b/server/api/variable/index.js index aedd4ca..54fd0a5 100644 --- a/server/api/variable/index.js +++ b/server/api/variable/index.js @@ -1 +1 @@ -const a695_0x2490=['destroy','update','put','delete','get','exports','express','Router','../../components/auth/service','show','create','isAuthenticated','/:id','./variable.controller'];(function(_0x27c113,_0x24905e){const _0x51f600=function(_0x1b58ec){while(--_0x1b58ec){_0x27c113['push'](_0x27c113['shift']());}};_0x51f600(++_0x24905e);}(a695_0x2490,0x8a));const a695_0x51f6=function(_0x27c113,_0x24905e){_0x27c113=_0x27c113-0x0;let _0x51f600=a695_0x2490[_0x27c113];return _0x51f600;};const _0xa777d2=a695_0x51f6;'use strict';const express=require(_0xa777d2('0x8')),router=express[_0xa777d2('0x9')](),auth=require(_0xa777d2('0xa')),controller=require(_0xa777d2('0x1'));router[_0xa777d2('0x6')]('/',auth[_0xa777d2('0xd')](),controller['index']),router[_0xa777d2('0x6')](_0xa777d2('0x0'),auth[_0xa777d2('0xd')](),controller[_0xa777d2('0xb')]),router['post']('/',auth['isAuthenticated'](),controller[_0xa777d2('0xc')]),router[_0xa777d2('0x4')](_0xa777d2('0x0'),auth[_0xa777d2('0xd')](),controller[_0xa777d2('0x3')]),router[_0xa777d2('0x5')]('/:id',auth['isAuthenticated'](),controller[_0xa777d2('0x2')]),module[_0xa777d2('0x7')]=router; \ No newline at end of file +const a695_0x56ed=['exports','update','isAuthenticated','show','create','index','express','post','./variable.controller','get','put','Router','/:id','delete'];(function(_0x5861d4,_0x56ed1c){const _0x4035cc=function(_0xb7ae35){while(--_0xb7ae35){_0x5861d4['push'](_0x5861d4['shift']());}};_0x4035cc(++_0x56ed1c);}(a695_0x56ed,0x185));const a695_0x4035=function(_0x5861d4,_0x56ed1c){_0x5861d4=_0x5861d4-0x0;let _0x4035cc=a695_0x56ed[_0x5861d4];return _0x4035cc;};const _0x1e9f66=a695_0x4035;'use strict';const express=require(_0x1e9f66('0x9')),router=express[_0x1e9f66('0x0')](),auth=require('../../components/auth/service'),controller=require(_0x1e9f66('0xb'));router[_0x1e9f66('0xc')]('/',auth['isAuthenticated'](),controller[_0x1e9f66('0x8')]),router[_0x1e9f66('0xc')](_0x1e9f66('0x1'),auth[_0x1e9f66('0x5')](),controller[_0x1e9f66('0x6')]),router[_0x1e9f66('0xa')]('/',auth['isAuthenticated'](),controller[_0x1e9f66('0x7')]),router[_0x1e9f66('0xd')](_0x1e9f66('0x1'),auth[_0x1e9f66('0x5')](),controller[_0x1e9f66('0x4')]),router[_0x1e9f66('0x2')](_0x1e9f66('0x1'),auth[_0x1e9f66('0x5')](),controller['destroy']),module[_0x1e9f66('0x3')]=router; \ No newline at end of file diff --git a/server/api/variable/variable.attributes.js b/server/api/variable/variable.attributes.js index 0b66776..e02748b 100644 --- a/server/api/variable/variable.attributes.js +++ b/server/api/variable/variable.attributes.js @@ -1 +1 @@ -const a696_0x5936=['name','STRING','sequelize','exports'];(function(_0xe0080f,_0x593630){const _0x530869=function(_0x1fe6af){while(--_0x1fe6af){_0xe0080f['push'](_0xe0080f['shift']());}};_0x530869(++_0x593630);}(a696_0x5936,0x14b));const a696_0x5308=function(_0xe0080f,_0x593630){_0xe0080f=_0xe0080f-0x0;let _0x530869=a696_0x5936[_0xe0080f];return _0x530869;};const _0xd99085=a696_0x5308;'use strict';const Sequelize=require(_0xd99085('0x3'));module[_0xd99085('0x0')]={'name':{'type':Sequelize[_0xd99085('0x2')],'unique':_0xd99085('0x1'),'allowNull':![],'validate':{'notEmpty':!![]}},'description':{'type':Sequelize[_0xd99085('0x2')]}}; \ No newline at end of file +const a696_0x5e62=['exports','name','sequelize','STRING'];(function(_0x4b001b,_0x5e628c){const _0x1477cd=function(_0x25b38f){while(--_0x25b38f){_0x4b001b['push'](_0x4b001b['shift']());}};_0x1477cd(++_0x5e628c);}(a696_0x5e62,0xa9));const a696_0x1477=function(_0x4b001b,_0x5e628c){_0x4b001b=_0x4b001b-0x0;let _0x1477cd=a696_0x5e62[_0x4b001b];return _0x1477cd;};const _0x5a37a7=a696_0x1477;'use strict';const Sequelize=require(_0x5a37a7('0x1'));module[_0x5a37a7('0x3')]={'name':{'type':Sequelize[_0x5a37a7('0x2')],'unique':_0x5a37a7('0x0'),'allowNull':![],'validate':{'notEmpty':!![]}},'description':{'type':Sequelize[_0x5a37a7('0x2')]}}; \ No newline at end of file diff --git a/server/api/variable/variable.controller.js b/server/api/variable/variable.controller.js index dd51108..2c587b4 100644 --- a/server/api/variable/variable.controller.js +++ b/server/api/variable/variable.controller.js @@ -1 +1 @@ -const a697_0xb9ca=['name','offset','Variable','rows','fields','model','keys','filter','error','index','UserProfileSection','rawAttributes','json','catch','order','includeAll','role','key','undefined','create','params','include','show','options','findOne','type','get','map','sendStatus','userProfileId','filters','set','Variables','query','body','like','where','UserProfileResource','../../config/logger','intersection','count','api','Content-Range','../../mysqldb','status','Unable\x20to\x20retrieve\x20the\x20current\x20user','length','end','sequelize','stack','destroy','attributes','autoAssociation','limit','update','../../components/parsers/qs','merge','sort','pick','fieldName','then'];(function(_0x3e849b,_0xb9cadf){const _0xdce445=function(_0x641476){while(--_0x641476){_0x3e849b['push'](_0x3e849b['shift']());}};_0xdce445(++_0xb9cadf);}(a697_0xb9ca,0x110));const a697_0xdce4=function(_0x3e849b,_0xb9cadf){_0x3e849b=_0x3e849b-0x0;let _0xdce445=a697_0xb9ca[_0x3e849b];return _0xdce445;};const _0x29f233=a697_0xdce4;'use strict';const _=require('lodash'),qs=require(_0x29f233('0x1b')),logger=require(_0x29f233('0xa'))(_0x29f233('0xd')),db=require(_0x29f233('0xf'))['db'],{Op}=require(_0x29f233('0x14'));function respondWithResult(_0x641476,_0x53ad18){return _0x53ad18=_0x53ad18||0xc8,function(_0x198d7d){if(_0x198d7d)return _0x641476['status'](_0x53ad18)['json'](_0x198d7d);};}function respondWithFilteredResult(_0x465002,_0x115d90){return function(_0x52c27d){const _0x2f24ae=a697_0xdce4;if(_0x52c27d){const _0x31990d=_0x52c27d[_0x2f24ae('0xc')],_0x671325=_0x115d90[_0x2f24ae('0x22')];let _0x3cf325=_0x115d90['offset']+_0x115d90['limit'],_0x57f443;return _0x3cf325>=_0x31990d?(_0x3cf325=_0x31990d,_0x57f443=0xc8):_0x57f443=0xce,_0x465002[_0x2f24ae('0x10')](_0x57f443),_0x465002[_0x2f24ae('0x3')](_0x2f24ae('0xe'),_0x671325+'-'+_0x3cf325+'/'+_0x31990d)[_0x2f24ae('0x2d')](_0x52c27d);}return null;};}function saveUpdates(_0x3ccfa2){return function(_0xdc51e8){if(_0xdc51e8)return _0xdc51e8['update'](_0x3ccfa2)['then'](function(_0x24d5f2){return _0x24d5f2;});return null;};}function removeEntity(_0x2ec95e){return function(_0x484e88){const _0x242dc3=a697_0xdce4;if(_0x484e88)return _0x484e88['destroy']()[_0x242dc3('0x20')](function(){const _0x56e5a8=_0x242dc3,_0x3eba88=_0x484e88[_0x56e5a8('0x3b')]({'plain':!![]}),_0x482b35=_0x56e5a8('0x4');return db['UserProfileResource'][_0x56e5a8('0x16')]({'where':{'type':_0x482b35,'resourceId':_0x3eba88['id']}})[_0x56e5a8('0x20')](function(){return _0x484e88;});})[_0x242dc3('0x20')](function(){const _0x3f85e0=_0x242dc3;_0x2ec95e[_0x3f85e0('0x10')](0xcc)[_0x3f85e0('0x13')]();});};}function handleEntityNotFound(_0x5e191e){return function(_0x243722){const _0x412aec=a697_0xdce4;return!_0x243722&&_0x5e191e[_0x412aec('0x0')](0x194),_0x243722;};}function handleError(_0x5b85c1,_0x3378fd){return _0x3378fd=_0x3378fd||0x1f4,function(_0x19370e){const _0x36f67b=a697_0xdce4;logger[_0x36f67b('0x29')](_0x19370e[_0x36f67b('0x15')]),_0x19370e[_0x36f67b('0x21')]&&delete _0x19370e[_0x36f67b('0x21')],_0x5b85c1[_0x36f67b('0x10')](_0x3378fd)['send'](_0x19370e);};}exports[_0x29f233('0x2a')]=function(_0x523c2c,_0x38fe35){const _0x76eb02=_0x29f233;let _0x3426a3={};const _0xfc93b0={},_0x4451d2={'count':0x0,'rows':[]},_0x56da86=_[_0x76eb02('0x3c')](db[_0x76eb02('0x23')][_0x76eb02('0x2c')],function(_0xf5ae7c){const _0x5eaab8=_0x76eb02;return{'name':_0xf5ae7c[_0x5eaab8('0x1f')],'type':_0xf5ae7c[_0x5eaab8('0x3a')][_0x5eaab8('0x32')]};});_0xfc93b0['model']=_['map'](_0x56da86,_0x76eb02('0x21')),_0xfc93b0[_0x76eb02('0x5')]=_[_0x76eb02('0x27')](_0x523c2c[_0x76eb02('0x5')]),_0xfc93b0[_0x76eb02('0x2')]=_[_0x76eb02('0xb')](_0xfc93b0[_0x76eb02('0x26')],_0xfc93b0[_0x76eb02('0x5')]),_0x3426a3['attributes']=_['intersection'](_0xfc93b0[_0x76eb02('0x26')],qs[_0x76eb02('0x25')](_0x523c2c['query'][_0x76eb02('0x25')])),_0x3426a3[_0x76eb02('0x17')]=_0x3426a3[_0x76eb02('0x17')][_0x76eb02('0x12')]?_0x3426a3['attributes']:_0xfc93b0[_0x76eb02('0x26')];typeof _0x523c2c[_0x76eb02('0x5')]['nolimit']===_0x76eb02('0x33')&&(_0x3426a3[_0x76eb02('0x19')]=qs[_0x76eb02('0x19')](_0x523c2c[_0x76eb02('0x5')][_0x76eb02('0x19')]),_0x3426a3[_0x76eb02('0x22')]=qs[_0x76eb02('0x22')](_0x523c2c['query']['offset']));_0x3426a3[_0x76eb02('0x2f')]=qs[_0x76eb02('0x1d')](_0x523c2c[_0x76eb02('0x5')]['sort']),_0x3426a3['where']=qs[_0x76eb02('0x2')](_[_0x76eb02('0x1e')](_0x523c2c[_0x76eb02('0x5')],_0xfc93b0['filters']),_0x56da86);_0x523c2c[_0x76eb02('0x5')][_0x76eb02('0x28')]&&(_0x3426a3['where']=_[_0x76eb02('0x1c')](_0x3426a3['where'],{[Op['or']]:_[_0x76eb02('0x3c')](_0x56da86,function(_0x2be66d){const _0x2c8115=_0x76eb02;if(_0x2be66d[_0x2c8115('0x3a')]!=='VIRTUAL'){const _0x4642b9={};return _0x4642b9[_0x2be66d[_0x2c8115('0x21')]]={[Op[_0x2c8115('0x7')]]:'%'+_0x523c2c['query'][_0x2c8115('0x28')]+'%'},_0x4642b9;}})}));_0x3426a3=_[_0x76eb02('0x1c')]({},_0x3426a3,_0x523c2c[_0x76eb02('0x38')]);const _0x1524ec={'where':_0x3426a3[_0x76eb02('0x8')]};return db[_0x76eb02('0x23')][_0x76eb02('0xc')](_0x1524ec)['then'](function(_0x3b2266){const _0x1ed985=_0x76eb02;return _0x4451d2[_0x1ed985('0xc')]=_0x3b2266,_0x523c2c[_0x1ed985('0x5')][_0x1ed985('0x30')]&&(_0x3426a3[_0x1ed985('0x36')]=[{'all':!![]}]),db[_0x1ed985('0x23')]['findAll'](_0x3426a3);})[_0x76eb02('0x20')](function(_0xd9f065){const _0x572689=_0x76eb02;return _0x4451d2[_0x572689('0x24')]=_0xd9f065,_0x4451d2;})[_0x76eb02('0x20')](respondWithFilteredResult(_0x38fe35,_0x3426a3))[_0x76eb02('0x2e')](handleError(_0x38fe35,null));},exports[_0x29f233('0x37')]=function(_0x161183,_0x37423d){const _0x1c862d=_0x29f233;let _0x49dd3c={'raw':!![],'where':{'id':_0x161183['params']['id']}};const _0x2e7d5c={};return _0x2e7d5c[_0x1c862d('0x26')]=_['keys'](db['Variable'][_0x1c862d('0x2c')]),_0x2e7d5c[_0x1c862d('0x5')]=_[_0x1c862d('0x27')](_0x161183[_0x1c862d('0x5')]),_0x2e7d5c[_0x1c862d('0x2')]=_[_0x1c862d('0xb')](_0x2e7d5c[_0x1c862d('0x26')],_0x2e7d5c[_0x1c862d('0x5')]),_0x49dd3c['attributes']=_[_0x1c862d('0xb')](_0x2e7d5c[_0x1c862d('0x26')],qs[_0x1c862d('0x25')](_0x161183[_0x1c862d('0x5')][_0x1c862d('0x25')])),_0x49dd3c[_0x1c862d('0x17')]=_0x49dd3c[_0x1c862d('0x17')][_0x1c862d('0x12')]?_0x49dd3c['attributes']:_0x2e7d5c[_0x1c862d('0x26')],_0x161183[_0x1c862d('0x5')]['includeAll']&&(_0x49dd3c[_0x1c862d('0x36')]=[{'all':!![]}]),_0x49dd3c=_[_0x1c862d('0x1c')]({},_0x49dd3c,_0x161183['options']),db[_0x1c862d('0x23')][_0x1c862d('0x39')](_0x49dd3c)[_0x1c862d('0x20')](handleEntityNotFound(_0x37423d,null))['then'](respondWithResult(_0x37423d,null))[_0x1c862d('0x2e')](handleError(_0x37423d,null));},exports[_0x29f233('0x34')]=function(_0x4d9e7a,_0x20618b){const _0x35bee7=_0x29f233;return db[_0x35bee7('0x23')][_0x35bee7('0x34')](_0x4d9e7a[_0x35bee7('0x6')],{})[_0x35bee7('0x20')](function(_0x1d575a){const _0x42c90e=_0x35bee7,_0x28353a=_0x4d9e7a['user'][_0x42c90e('0x3b')]({'plain':!![]});if(!_0x28353a)throw new Error(_0x42c90e('0x11'));if(_0x28353a[_0x42c90e('0x31')]==='user'){const _0x2525ed=_0x1d575a[_0x42c90e('0x3b')]({'plain':!![]}),_0x38b76c=_0x42c90e('0x4');return db[_0x42c90e('0x2b')][_0x42c90e('0x39')]({'where':{'name':_0x38b76c,'userProfileId':_0x28353a[_0x42c90e('0x1')]},'raw':!![]})[_0x42c90e('0x20')](function(_0x5f4111){const _0x311d64=_0x42c90e;return _0x5f4111&&_0x5f4111[_0x311d64('0x18')]===0x0?db[_0x311d64('0x9')]['create']({'name':_0x2525ed['name'],'resourceId':_0x2525ed['id'],'type':_0x5f4111[_0x311d64('0x21')],'sectionId':_0x5f4111['id']},{})[_0x311d64('0x20')](function(){return _0x1d575a;}):_0x1d575a;})[_0x42c90e('0x2e')](function(_0x5c94a4){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x5c94a4);throw _0x5c94a4;});}return _0x1d575a;})[_0x35bee7('0x20')](respondWithResult(_0x20618b,0xc9))['catch'](handleError(_0x20618b,null));},exports[_0x29f233('0x1a')]=function(_0x8bd5cf,_0x280355){const _0x23737d=_0x29f233;return _0x8bd5cf[_0x23737d('0x6')]['id']&&delete _0x8bd5cf['body']['id'],db['Variable']['findOne']({'where':{'id':_0x8bd5cf[_0x23737d('0x35')]['id']}})[_0x23737d('0x20')](handleEntityNotFound(_0x280355,null))[_0x23737d('0x20')](saveUpdates(_0x8bd5cf[_0x23737d('0x6')],null))[_0x23737d('0x20')](respondWithResult(_0x280355,null))[_0x23737d('0x2e')](handleError(_0x280355,null));},exports['destroy']=function(_0x2da156,_0x2cc101){const _0xdba3e8=_0x29f233;return db['Variable']['findOne']({'where':{'id':_0x2da156['params']['id']}})[_0xdba3e8('0x20')](handleEntityNotFound(_0x2cc101,null))[_0xdba3e8('0x20')](removeEntity(_0x2cc101,null))['catch'](handleError(_0x2cc101,null));}; \ No newline at end of file +const a697_0x56d7=['user','filter','VIRTUAL','params','catch','Variable','intersection','body','sort','end','key','model','count','get','type','../../components/parsers/qs','set','role','sendStatus','sequelize','../../mysqldb','then','offset','attributes','name','filters','query','fieldName','stack','findAll','limit','show','fields','update','length','UserProfileResource','../../config/logger','rows','UserProfileSection','rawAttributes','create','include','lodash','status','send','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','findOne','includeAll','keys','merge','json','nolimit','order','Content-Range','map','where','destroy','error','index'];(function(_0x2e67db,_0x56d791){const _0x31ac86=function(_0xc083b2){while(--_0xc083b2){_0x2e67db['push'](_0x2e67db['shift']());}};_0x31ac86(++_0x56d791);}(a697_0x56d7,0x1ae));const a697_0x31ac=function(_0x2e67db,_0x56d791){_0x2e67db=_0x2e67db-0x0;let _0x31ac86=a697_0x56d7[_0x2e67db];return _0x31ac86;};const _0x522e1c=a697_0x31ac;'use strict';const _=require(_0x522e1c('0x19')),qs=require(_0x522e1c('0x39')),logger=require(_0x522e1c('0x13'))('api'),db=require(_0x522e1c('0x3'))['db'],{Op}=require(_0x522e1c('0x2'));function respondWithResult(_0xc083b2,_0x4366f8){return _0x4366f8=_0x4366f8||0xc8,function(_0x5c368a){const _0x21bbd1=a697_0x31ac;if(_0x5c368a)return _0xc083b2[_0x21bbd1('0x1a')](_0x4366f8)['json'](_0x5c368a);};}function respondWithFilteredResult(_0x4c0653,_0x255f9a){return function(_0x1dd0e){const _0x53b03b=a697_0x31ac;if(_0x1dd0e){const _0x38f8f5=_0x1dd0e[_0x53b03b('0x36')],_0x5b3383=_0x255f9a[_0x53b03b('0x5')];let _0x159b53=_0x255f9a['offset']+_0x255f9a[_0x53b03b('0xd')],_0x2985ee;return _0x159b53>=_0x38f8f5?(_0x159b53=_0x38f8f5,_0x2985ee=0xc8):_0x2985ee=0xce,_0x4c0653[_0x53b03b('0x1a')](_0x2985ee),_0x4c0653[_0x53b03b('0x3a')](_0x53b03b('0x24'),_0x5b3383+'-'+_0x159b53+'/'+_0x38f8f5)[_0x53b03b('0x21')](_0x1dd0e);}return null;};}function saveUpdates(_0x40c3ed){return function(_0x90877a){const _0x1fbcce=a697_0x31ac;if(_0x90877a)return _0x90877a['update'](_0x40c3ed)[_0x1fbcce('0x4')](function(_0x19c03c){return _0x19c03c;});return null;};}function removeEntity(_0x5a4345){return function(_0x2c5f40){const _0x52c321=a697_0x31ac;if(_0x2c5f40)return _0x2c5f40[_0x52c321('0x27')]()[_0x52c321('0x4')](function(){const _0x21124d=_0x52c321,_0x1c25f1=_0x2c5f40[_0x21124d('0x37')]({'plain':!![]}),_0x3308b5='Variables';return db[_0x21124d('0x12')][_0x21124d('0x27')]({'where':{'type':_0x3308b5,'resourceId':_0x1c25f1['id']}})[_0x21124d('0x4')](function(){return _0x2c5f40;});})[_0x52c321('0x4')](function(){const _0x80c5de=_0x52c321;_0x5a4345[_0x80c5de('0x1a')](0xcc)[_0x80c5de('0x33')]();});};}function handleEntityNotFound(_0x4f51fa){return function(_0x48e631){const _0x3e6914=a697_0x31ac;return!_0x48e631&&_0x4f51fa[_0x3e6914('0x1')](0x194),_0x48e631;};}function handleError(_0x4dfca0,_0x45ec4d){return _0x45ec4d=_0x45ec4d||0x1f4,function(_0x12d206){const _0x1322ed=a697_0x31ac;logger[_0x1322ed('0x28')](_0x12d206[_0x1322ed('0xb')]),_0x12d206['name']&&delete _0x12d206['name'],_0x4dfca0['status'](_0x45ec4d)[_0x1322ed('0x1b')](_0x12d206);};}exports[_0x522e1c('0x29')]=function(_0x55d1b8,_0x173326){const _0x2963f0=_0x522e1c;let _0x1a6971={};const _0x5d334d={},_0x35e490={'count':0x0,'rows':[]},_0x421eb9=_['map'](db[_0x2963f0('0x2f')]['rawAttributes'],function(_0x5d08e0){const _0x3e67b3=_0x2963f0;return{'name':_0x5d08e0[_0x3e67b3('0xa')],'type':_0x5d08e0[_0x3e67b3('0x38')][_0x3e67b3('0x34')]};});_0x5d334d[_0x2963f0('0x35')]=_[_0x2963f0('0x25')](_0x421eb9,_0x2963f0('0x7')),_0x5d334d['query']=_[_0x2963f0('0x1f')](_0x55d1b8[_0x2963f0('0x9')]),_0x5d334d[_0x2963f0('0x8')]=_['intersection'](_0x5d334d[_0x2963f0('0x35')],_0x5d334d['query']),_0x1a6971[_0x2963f0('0x6')]=_['intersection'](_0x5d334d[_0x2963f0('0x35')],qs[_0x2963f0('0xf')](_0x55d1b8['query'][_0x2963f0('0xf')])),_0x1a6971[_0x2963f0('0x6')]=_0x1a6971['attributes'][_0x2963f0('0x11')]?_0x1a6971[_0x2963f0('0x6')]:_0x5d334d[_0x2963f0('0x35')];typeof _0x55d1b8[_0x2963f0('0x9')][_0x2963f0('0x22')]==='undefined'&&(_0x1a6971[_0x2963f0('0xd')]=qs['limit'](_0x55d1b8['query'][_0x2963f0('0xd')]),_0x1a6971[_0x2963f0('0x5')]=qs[_0x2963f0('0x5')](_0x55d1b8[_0x2963f0('0x9')][_0x2963f0('0x5')]));_0x1a6971[_0x2963f0('0x23')]=qs[_0x2963f0('0x32')](_0x55d1b8[_0x2963f0('0x9')][_0x2963f0('0x32')]),_0x1a6971[_0x2963f0('0x26')]=qs['filters'](_['pick'](_0x55d1b8['query'],_0x5d334d[_0x2963f0('0x8')]),_0x421eb9);_0x55d1b8[_0x2963f0('0x9')][_0x2963f0('0x2b')]&&(_0x1a6971[_0x2963f0('0x26')]=_[_0x2963f0('0x20')](_0x1a6971[_0x2963f0('0x26')],{[Op['or']]:_['map'](_0x421eb9,function(_0x4a6e7e){const _0x1bf426=_0x2963f0;if(_0x4a6e7e[_0x1bf426('0x38')]!==_0x1bf426('0x2c')){const _0x17e71a={};return _0x17e71a[_0x4a6e7e[_0x1bf426('0x7')]]={[Op['like']]:'%'+_0x55d1b8[_0x1bf426('0x9')][_0x1bf426('0x2b')]+'%'},_0x17e71a;}})}));_0x1a6971=_[_0x2963f0('0x20')]({},_0x1a6971,_0x55d1b8['options']);const _0x28e55a={'where':_0x1a6971[_0x2963f0('0x26')]};return db[_0x2963f0('0x2f')][_0x2963f0('0x36')](_0x28e55a)[_0x2963f0('0x4')](function(_0x5f3ab2){const _0x31e1bb=_0x2963f0;return _0x35e490[_0x31e1bb('0x36')]=_0x5f3ab2,_0x55d1b8['query'][_0x31e1bb('0x1e')]&&(_0x1a6971['include']=[{'all':!![]}]),db[_0x31e1bb('0x2f')][_0x31e1bb('0xc')](_0x1a6971);})[_0x2963f0('0x4')](function(_0x1fe52d){const _0x4fdc75=_0x2963f0;return _0x35e490[_0x4fdc75('0x14')]=_0x1fe52d,_0x35e490;})['then'](respondWithFilteredResult(_0x173326,_0x1a6971))['catch'](handleError(_0x173326,null));},exports[_0x522e1c('0xe')]=function(_0x191308,_0x33118d){const _0x31b997=_0x522e1c;let _0x8a0784={'raw':!![],'where':{'id':_0x191308[_0x31b997('0x2d')]['id']}};const _0x1f1e99={};return _0x1f1e99[_0x31b997('0x35')]=_[_0x31b997('0x1f')](db[_0x31b997('0x2f')][_0x31b997('0x16')]),_0x1f1e99[_0x31b997('0x9')]=_[_0x31b997('0x1f')](_0x191308['query']),_0x1f1e99[_0x31b997('0x8')]=_[_0x31b997('0x30')](_0x1f1e99['model'],_0x1f1e99[_0x31b997('0x9')]),_0x8a0784['attributes']=_['intersection'](_0x1f1e99[_0x31b997('0x35')],qs[_0x31b997('0xf')](_0x191308[_0x31b997('0x9')][_0x31b997('0xf')])),_0x8a0784[_0x31b997('0x6')]=_0x8a0784[_0x31b997('0x6')][_0x31b997('0x11')]?_0x8a0784[_0x31b997('0x6')]:_0x1f1e99[_0x31b997('0x35')],_0x191308[_0x31b997('0x9')][_0x31b997('0x1e')]&&(_0x8a0784[_0x31b997('0x18')]=[{'all':!![]}]),_0x8a0784=_['merge']({},_0x8a0784,_0x191308['options']),db[_0x31b997('0x2f')][_0x31b997('0x1d')](_0x8a0784)[_0x31b997('0x4')](handleEntityNotFound(_0x33118d,null))[_0x31b997('0x4')](respondWithResult(_0x33118d,null))[_0x31b997('0x2e')](handleError(_0x33118d,null));},exports[_0x522e1c('0x17')]=function(_0x16a8e5,_0x52c4fe){const _0x595382=_0x522e1c;return db['Variable']['create'](_0x16a8e5['body'],{})['then'](function(_0x22b9f7){const _0x2b9736=a697_0x31ac,_0x5842dc=_0x16a8e5['user'][_0x2b9736('0x37')]({'plain':!![]});if(!_0x5842dc)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x5842dc[_0x2b9736('0x0')]===_0x2b9736('0x2a')){const _0xcebf19=_0x22b9f7[_0x2b9736('0x37')]({'plain':!![]}),_0xe69fae='Variables';return db[_0x2b9736('0x15')][_0x2b9736('0x1d')]({'where':{'name':_0xe69fae,'userProfileId':_0x5842dc['userProfileId']},'raw':!![]})[_0x2b9736('0x4')](function(_0x1bfc9d){const _0x52fc73=_0x2b9736;return _0x1bfc9d&&_0x1bfc9d['autoAssociation']===0x0?db['UserProfileResource'][_0x52fc73('0x17')]({'name':_0xcebf19[_0x52fc73('0x7')],'resourceId':_0xcebf19['id'],'type':_0x1bfc9d[_0x52fc73('0x7')],'sectionId':_0x1bfc9d['id']},{})[_0x52fc73('0x4')](function(){return _0x22b9f7;}):_0x22b9f7;})[_0x2b9736('0x2e')](function(_0xe0b66a){const _0x1a9dfe=_0x2b9736;logger[_0x1a9dfe('0x28')](_0x1a9dfe('0x1c'),_0xe0b66a);throw _0xe0b66a;});}return _0x22b9f7;})[_0x595382('0x4')](respondWithResult(_0x52c4fe,0xc9))[_0x595382('0x2e')](handleError(_0x52c4fe,null));},exports[_0x522e1c('0x10')]=function(_0x49732f,_0xe7ca4a){const _0xc65da9=_0x522e1c;return _0x49732f[_0xc65da9('0x31')]['id']&&delete _0x49732f['body']['id'],db[_0xc65da9('0x2f')][_0xc65da9('0x1d')]({'where':{'id':_0x49732f['params']['id']}})['then'](handleEntityNotFound(_0xe7ca4a,null))[_0xc65da9('0x4')](saveUpdates(_0x49732f[_0xc65da9('0x31')],null))[_0xc65da9('0x4')](respondWithResult(_0xe7ca4a,null))[_0xc65da9('0x2e')](handleError(_0xe7ca4a,null));},exports[_0x522e1c('0x27')]=function(_0x659536,_0x163cfe){const _0x1197f5=_0x522e1c;return db[_0x1197f5('0x2f')][_0x1197f5('0x1d')]({'where':{'id':_0x659536[_0x1197f5('0x2d')]['id']}})[_0x1197f5('0x4')](handleEntityNotFound(_0x163cfe,null))['then'](removeEntity(_0x163cfe,null))[_0x1197f5('0x2e')](handleError(_0x163cfe,null));}; \ No newline at end of file diff --git a/server/api/variable/variable.model.js b/server/api/variable/variable.model.js index a3a57dc..a4fec92 100644 --- a/server/api/variable/variable.model.js +++ b/server/api/variable/variable.model.js @@ -1 +1 @@ -const a698_0x11a4=['./variable.attributes','tools_variables','define','Variable'];(function(_0x179c8f,_0x11a495){const _0x18f254=function(_0x3e9d88){while(--_0x3e9d88){_0x179c8f['push'](_0x179c8f['shift']());}};_0x18f254(++_0x11a495);}(a698_0x11a4,0xea));const a698_0x18f2=function(_0x179c8f,_0x11a495){_0x179c8f=_0x179c8f-0x0;let _0x18f254=a698_0x11a4[_0x179c8f];return _0x18f254;};const _0x1a5381=a698_0x18f2;'use strict';const attributes=require(_0x1a5381('0x2'));module['exports']=function(_0x3e9d88){const _0x1c590f=_0x1a5381,_0x56a2f8=_0x3e9d88[_0x1c590f('0x0')](_0x1c590f('0x1'),attributes,{'tableName':_0x1c590f('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x56a2f8;}; \ No newline at end of file +const a698_0x1154=['Variable','./variable.attributes'];(function(_0x1f805b,_0x11548e){const _0x5d9008=function(_0x2c9713){while(--_0x2c9713){_0x1f805b['push'](_0x1f805b['shift']());}};_0x5d9008(++_0x11548e);}(a698_0x1154,0x1b7));const a698_0x5d90=function(_0x1f805b,_0x11548e){_0x1f805b=_0x1f805b-0x0;let _0x5d9008=a698_0x1154[_0x1f805b];return _0x5d9008;};const _0x5d721d=a698_0x5d90;'use strict';const attributes=require(_0x5d721d('0x0'));module['exports']=function(_0x2c9713){const _0x2b004a=_0x5d721d,_0x36e849=_0x2c9713['define'](_0x2b004a('0x1'),attributes,{'tableName':'tools_variables','paranoid':![],'indexes':[],'timestamps':!![]});return _0x36e849;}; \ No newline at end of file diff --git a/server/api/variable/variable.rpc.js b/server/api/variable/variable.rpc.js index 8f798f9..53ff01e 100644 --- a/server/api/variable/variable.rpc.js +++ b/server/api/variable/variable.rpc.js @@ -1 +1 @@ -const a699_0x5d80=['debug','model','catch','raw','include','where','then','map','info','error','stringify','attributes','../../config/logger','ShowVariable','rpc','../../mysqldb','message','options'];(function(_0x252937,_0x5d802c){const _0x277ed3=function(_0x31255e){while(--_0x31255e){_0x252937['push'](_0x252937['shift']());}};_0x277ed3(++_0x5d802c);}(a699_0x5d80,0xc7));const a699_0x277e=function(_0x252937,_0x5d802c){_0x252937=_0x252937-0x0;let _0x277ed3=a699_0x5d80[_0x252937];return _0x277ed3;};const _0x44dba2=a699_0x277e;'use strict';const db=require(_0x44dba2('0xe'))['db'],logger=require(_0x44dba2('0xb'))(_0x44dba2('0xd')),_=require('lodash');exports[_0x44dba2('0xc')]=function(_0x31255e){const _0x2664c=this;return new Promise(function(_0xb80837,_0x22726b){const _0x844324=a699_0x277e;return db['Variable']['findOne']({'raw':_0x31255e['options']?_0x31255e['options'][_0x844324('0x2')]===undefined?!![]:![]:!![],'where':_0x31255e[_0x844324('0x10')]?_0x31255e[_0x844324('0x10')][_0x844324('0x4')]||null:null,'attributes':_0x31255e[_0x844324('0x10')]?_0x31255e['options'][_0x844324('0xa')]||null:null,'include':_0x31255e['options']?_0x31255e[_0x844324('0x10')]['include']?_['map'](_0x31255e[_0x844324('0x10')][_0x844324('0x3')],function(_0x4b3ff1){const _0xe8c7b=_0x844324;return{'model':db[_0x4b3ff1['model']],'as':_0x4b3ff1['as'],'attributes':_0x4b3ff1[_0xe8c7b('0xa')],'include':_0x4b3ff1[_0xe8c7b('0x3')]?_[_0xe8c7b('0x6')](_0x4b3ff1[_0xe8c7b('0x3')],function(_0x12de63){const _0x52c3a8=_0xe8c7b;return{'model':db[_0x12de63[_0x52c3a8('0x0')]],'as':_0x12de63['as'],'attributes':_0x12de63[_0x52c3a8('0xa')],'include':_0x12de63['include']?_['map'](_0x12de63['include'],function(_0x2feec4){const _0x34a510=_0x52c3a8;return{'model':db[_0x2feec4['model']],'as':_0x2feec4['as'],'attributes':_0x2feec4[_0x34a510('0xa')]};}):[]};}):[]};}):[]:[]})[_0x844324('0x5')](function(_0x41871c){const _0x10f291=_0x844324;logger[_0x10f291('0x7')](_0x10f291('0xc'),_0x31255e),logger[_0x10f291('0x11')](_0x10f291('0xc'),_0x31255e,JSON[_0x10f291('0x9')](_0x41871c)),_0xb80837(_0x41871c);})[_0x844324('0x1')](function(_0x255e3b){const _0x1d08c5=_0x844324;logger['error'](_0x1d08c5('0xc'),_0x255e3b['message'],_0x31255e),_0x22726b(_0x2664c[_0x1d08c5('0x8')](0x1f4,_0x255e3b[_0x1d08c5('0xf')]));});});}; \ No newline at end of file +const a699_0x392c=['message','ShowVariable','info','map','debug','Variable','include','stringify','attributes','lodash','findOne','rpc','model','where','options','../../config/logger','catch'];(function(_0xf72259,_0x392c9b){const _0x35ec75=function(_0x1497e8){while(--_0x1497e8){_0xf72259['push'](_0xf72259['shift']());}};_0x35ec75(++_0x392c9b);}(a699_0x392c,0x181));const a699_0x35ec=function(_0xf72259,_0x392c9b){_0xf72259=_0xf72259-0x0;let _0x35ec75=a699_0x392c[_0xf72259];return _0x35ec75;};const _0x1fbe08=a699_0x35ec;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x1fbe08('0x4'))(_0x1fbe08('0x0')),_=require(_0x1fbe08('0xf'));exports['ShowVariable']=function(_0x1497e8){const _0x2102fc=this;return new Promise(function(_0x141416,_0x19e99b){const _0x14cefb=a699_0x35ec;return db[_0x14cefb('0xb')][_0x14cefb('0x10')]({'raw':_0x1497e8['options']?_0x1497e8[_0x14cefb('0x3')]['raw']===undefined?!![]:![]:!![],'where':_0x1497e8[_0x14cefb('0x3')]?_0x1497e8[_0x14cefb('0x3')][_0x14cefb('0x2')]||null:null,'attributes':_0x1497e8[_0x14cefb('0x3')]?_0x1497e8[_0x14cefb('0x3')][_0x14cefb('0xe')]||null:null,'include':_0x1497e8[_0x14cefb('0x3')]?_0x1497e8[_0x14cefb('0x3')][_0x14cefb('0xc')]?_['map'](_0x1497e8[_0x14cefb('0x3')][_0x14cefb('0xc')],function(_0xb375ae){const _0x377c5f=_0x14cefb;return{'model':db[_0xb375ae['model']],'as':_0xb375ae['as'],'attributes':_0xb375ae[_0x377c5f('0xe')],'include':_0xb375ae[_0x377c5f('0xc')]?_[_0x377c5f('0x9')](_0xb375ae[_0x377c5f('0xc')],function(_0x14e5cc){const _0x460c95=_0x377c5f;return{'model':db[_0x14e5cc[_0x460c95('0x1')]],'as':_0x14e5cc['as'],'attributes':_0x14e5cc[_0x460c95('0xe')],'include':_0x14e5cc[_0x460c95('0xc')]?_[_0x460c95('0x9')](_0x14e5cc['include'],function(_0x299aa3){const _0x4f9940=_0x460c95;return{'model':db[_0x299aa3[_0x4f9940('0x1')]],'as':_0x299aa3['as'],'attributes':_0x299aa3[_0x4f9940('0xe')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x2e985e){const _0x3f69ec=_0x14cefb;logger[_0x3f69ec('0x8')](_0x3f69ec('0x7'),_0x1497e8),logger[_0x3f69ec('0xa')]('ShowVariable',_0x1497e8,JSON[_0x3f69ec('0xd')](_0x2e985e)),_0x141416(_0x2e985e);})[_0x14cefb('0x5')](function(_0x4721ac){const _0x41fd99=_0x14cefb;logger['error'](_0x41fd99('0x7'),_0x4721ac[_0x41fd99('0x6')],_0x1497e8),_0x19e99b(_0x2102fc['error'](0x1f4,_0x4721ac[_0x41fd99('0x6')]));});});}; \ No newline at end of file diff --git a/server/api/version/index.js b/server/api/version/index.js index 3508414..a14d4d3 100644 --- a/server/api/version/index.js +++ b/server/api/version/index.js @@ -1 +1 @@ -const a700_0x19a0=['/reset','reset','pull','fetch','/migrations','restart','/fetch','index','exports','/restart','migrations','isAuthenticated','canUpdate','../../components/auth/service','./version.controller','get','express'];(function(_0x2b75f4,_0x19a0d6){const _0x1e3ab6=function(_0x46076a){while(--_0x46076a){_0x2b75f4['push'](_0x2b75f4['shift']());}};_0x1e3ab6(++_0x19a0d6);}(a700_0x19a0,0x180));const a700_0x1e3a=function(_0x2b75f4,_0x19a0d6){_0x2b75f4=_0x2b75f4-0x0;let _0x1e3ab6=a700_0x19a0[_0x2b75f4];return _0x1e3ab6;};const _0x110dfd=a700_0x1e3a;'use strict';const express=require(_0x110dfd('0x6')),router=express['Router'](),auth=require(_0x110dfd('0x3')),controller=require(_0x110dfd('0x4'));router[_0x110dfd('0x5')]('/',controller[_0x110dfd('0xe')]),router[_0x110dfd('0x5')](_0x110dfd('0xd'),auth[_0x110dfd('0x1')](),auth[_0x110dfd('0x2')](),controller[_0x110dfd('0xa')]),router['get'](_0x110dfd('0x7'),auth[_0x110dfd('0x1')](),auth[_0x110dfd('0x2')](),controller[_0x110dfd('0x8')]),router[_0x110dfd('0x5')]('/pull',auth['isAuthenticated'](),auth['canUpdate'](),controller[_0x110dfd('0x9')]),router[_0x110dfd('0x5')](_0x110dfd('0x10'),auth[_0x110dfd('0x1')](),controller[_0x110dfd('0xc')]),router[_0x110dfd('0x5')](_0x110dfd('0xb'),controller[_0x110dfd('0x0')]),module[_0x110dfd('0xf')]=router; \ No newline at end of file +const a700_0x3e25=['canUpdate','isAuthenticated','/fetch','express','get','/restart','Router','/pull','pull','exports','fetch','../../components/auth/service','reset'];(function(_0x11bf0d,_0x3e25d7){const _0x235248=function(_0x22fa3d){while(--_0x22fa3d){_0x11bf0d['push'](_0x11bf0d['shift']());}};_0x235248(++_0x3e25d7);}(a700_0x3e25,0x1f2));const a700_0x2352=function(_0x11bf0d,_0x3e25d7){_0x11bf0d=_0x11bf0d-0x0;let _0x235248=a700_0x3e25[_0x11bf0d];return _0x235248;};const _0x473964=a700_0x2352;'use strict';const express=require(_0x473964('0xc')),router=express[_0x473964('0x2')](),auth=require(_0x473964('0x7')),controller=require('./version.controller');router['get']('/',controller['index']),router[_0x473964('0x0')](_0x473964('0xb'),auth[_0x473964('0xa')](),auth[_0x473964('0x9')](),controller[_0x473964('0x6')]),router[_0x473964('0x0')]('/reset',auth[_0x473964('0xa')](),auth[_0x473964('0x9')](),controller[_0x473964('0x8')]),router['get'](_0x473964('0x3'),auth[_0x473964('0xa')](),auth[_0x473964('0x9')](),controller[_0x473964('0x4')]),router[_0x473964('0x0')](_0x473964('0x1'),auth[_0x473964('0xa')](),controller['restart']),router['get']('/migrations',controller['migrations']),module[_0x473964('0x5')]=router; \ No newline at end of file diff --git a/server/api/version/version.controller.js b/server/api/version/version.controller.js index c880b38..9c32284 100644 --- a/server/api/version/version.controller.js +++ b/server/api/version/version.controller.js @@ -1 +1 @@ -const a701_0xdd60=['git\x20reset\x20--hard','Database\x20migrated\x20successfully\x20from\x20version\x20','compare-versions','Your\x20system\x20has\x20been\x20restart\x20successfully','version','join','umzug','length','error','../../config/pm2','update','push','npm\x20install\x20--production','migrations','--hard','query','last','map','../../mysqldb','sequelize','status','then','Migration','catch','git\x20fetch','tags','fetch','motion2','2.0.0','json','info','constructor','latest','Migration\x20tried\x20to\x20use\x20old\x20style\x20\x22done\x22\x20callback.\x20Please\x20upgrade\x20to\x20\x22umzug\x22\x20and\x20return\x20a\x20promise\x20instead.','replace','git\x20reset\x20--hard\x20FETCH_HEAD','pm2\x20restart\x20motion\x20%s','root','Database\x20already\x20up-to-date','../../utils/build-info','FETCH_HEAD','path','git\x20fetch\x20origin\x20master','exec','exports'];(function(_0x37ab2c,_0xdd60de){const _0x392a62=function(_0x21613d){while(--_0x21613d){_0x37ab2c['push'](_0x37ab2c['shift']());}};_0x392a62(++_0xdd60de);}(a701_0xdd60,0x1b9));const a701_0x392a=function(_0x37ab2c,_0xdd60de){_0x37ab2c=_0x37ab2c-0x0;let _0x392a62=a701_0xdd60[_0x37ab2c];return _0x392a62;};const _0x5754c6=a701_0x392a;'use strict';const Umzug=require(_0x5754c6('0xf')),path=require(_0x5754c6('0x5')),fs=require('fs'),_=require('lodash'),compareVersions=require(_0x5754c6('0xb')),exec=require('child_process')[_0x5754c6('0x7')],db=require(_0x5754c6('0x1b'))['db'],config=require('../../config/environment'),pm2=require(_0x5754c6('0x12')),logger=require('../../config/logger')(_0x5754c6('0x13')),{version:packageVersion}=require('../../../package.json'),git=require('simple-git')(config[_0x5754c6('0x1')]),{UniqueConstraintError}=require(_0x5754c6('0x1c')),{readBuildInfo}=require(_0x5754c6('0x3'));async function index(_0x21613d,_0x9c095a){const _0x35c874=_0x5754c6,_0x5e1b1c=await readBuildInfo(),_0x1b361d={'current':packageVersion,'phonebar':0x2,..._0x5e1b1c};return _0x21613d[_0x35c874('0x18')]&&_0x21613d[_0x35c874('0x18')][_0x35c874('0x29')]?git[_0x35c874('0x23')]()[_0x35c874('0x22')](function(_0x5b24d8,_0x36e64f){const _0x3a3ea2=_0x35c874;return _0x1b361d[_0x3a3ea2('0x29')]=(_0x5b24d8?packageVersion:_0x36e64f[_0x3a3ea2('0x29')])||_0x3a3ea2('0x25'),_0x9c095a[_0x3a3ea2('0x1d')](0xc8)['json'](_0x1b361d);}):_0x9c095a[_0x35c874('0x1d')](0xc8)[_0x35c874('0x26')](_0x1b361d);}function fetch(_0x544fce,_0x3f5e2e){const _0x1858f4=_0x5754c6;return git[_0x1858f4('0x23')](['origin','master'],function(_0x408f50){const _0x1a6714=_0x1858f4;if(_0x408f50)return logger[_0x1a6714('0x11')](_0x408f50),_0x3f5e2e[_0x1a6714('0x1d')](0x1f4)['json'](_0x408f50);return logger[_0x1a6714('0x27')](_0x1a6714('0x21')),_0x3f5e2e[_0x1a6714('0x1d')](0xc8)[_0x1a6714('0x26')]({'output':_0x1a6714('0x6')});});}function reset(_0x1bcd68,_0x2114c8){const _0x8c048e=_0x5754c6;return git['reset']([_0x8c048e('0x17'),_0x8c048e('0x4')],function(_0x537b41){const _0x5a589b=_0x8c048e;if(_0x537b41)return logger['error'](_0x537b41),_0x2114c8[_0x5a589b('0x1d')](0x1f4)[_0x5a589b('0x26')](_0x537b41);return logger[_0x5a589b('0x27')](_0x5a589b('0x2c')),_0x2114c8[_0x5a589b('0x1d')](0xc8)['json']({'output':_0x5a589b('0x9')});});}function pull(_0x415c6f,_0x3ddd1f){const _0x4aa7c4=_0x5754c6;exec(_0x4aa7c4('0x15'),function(_0x46be88,_0x16151d,_0x1ebc58){const _0x30509a=_0x4aa7c4;logger[_0x30509a('0x27')](_0x16151d),logger['info'](_0x1ebc58);if(_0x46be88)return logger['error'](_0x46be88),_0x3ddd1f['status'](0x1f4)[_0x30509a('0x26')](_0x46be88);return _0x3ddd1f[_0x30509a('0x1d')](0xc8)['json']({'output':_0x16151d});});}function restart(_0x132d6a,_0x590173){const _0x1619e8=_0x5754c6;return pm2['restart'](_0x1619e8('0x24'))[_0x1619e8('0x1e')](function(_0xf49376){const _0x1d3598=_0x1619e8;return logger[_0x1d3598('0x27')](_0x1d3598('0x0'),_0xf49376),_0x590173['status'](0xc8)[_0x1d3598('0x26')]({'output':_0x1d3598('0xc')});})[_0x1619e8('0x20')](function(_0x252f52){const _0x58efe2=_0x1619e8;return logger['error'](_0x252f52),_0x590173[_0x58efe2('0x1d')](0x1f4)[_0x58efe2('0x26')](_0x252f52);});}function migrations(_0x2b378a,_0x183aa8){const _0x3d91c7=_0x5754c6,_0x3ec4b0=fs['readdirSync'](path['join'](config[_0x3d91c7('0x1')],_0x3d91c7('0x16'))),_0x2362dd=[];for(let _0x54fbec=0x0;_0x54fbec<_0x3ec4b0[_0x3d91c7('0x10')];_0x54fbec++){const _0x257873=_0x3ec4b0[_0x54fbec][_0x3d91c7('0x2b')]('.js','');compareVersions(packageVersion,_0x257873)===-0x1&&_0x2362dd[_0x3d91c7('0x14')](_0x257873);}if(_0x2362dd['length']){const _0x2b97a3=_0x2362dd['sort'](compareVersions),_0x2a3f45=new Umzug({'storage':_0x3d91c7('0x1c'),'storageOptions':{'model':db[_0x3d91c7('0x1f')],'modelName':_0x3d91c7('0x1f'),'columnName':_0x3d91c7('0xd')},'migrations':{'params':[db[_0x3d91c7('0x1c')]['getQueryInterface'](),db['sequelize'][_0x3d91c7('0x28')],function(){const _0x73e44c=_0x3d91c7;throw new Error(_0x73e44c('0x2a'));}],'path':path[_0x3d91c7('0xe')](config[_0x3d91c7('0x1')],_0x3d91c7('0x16')),'pattern':/\.js$/}});_0x2a3f45['up']({'migrations':_[_0x3d91c7('0x1a')](_0x2b97a3,function(_0x3d38c5){return _0x3d38c5+'.js';})})[_0x3d91c7('0x1e')](function(){const _0x3c7079=_0x3d91c7;return _0x183aa8[_0x3c7079('0x1d')](0xc8)[_0x3c7079('0x26')]({'output':_0x3c7079('0xa')+packageVersion+'\x20to\x20'+_[_0x3c7079('0x19')](_0x2b97a3),'migrations':_['join'](_0x2b97a3)});})[_0x3d91c7('0x20')](function(_0x122b1d){const _0x5e4a5b=_0x3d91c7;return _0x122b1d instanceof UniqueConstraintError?_0x183aa8[_0x5e4a5b('0x1d')](0xc8)[_0x5e4a5b('0x26')]({'output':_0x5e4a5b('0x2')}):_0x183aa8[_0x5e4a5b('0x1d')](0x1f4)[_0x5e4a5b('0x26')](_0x122b1d);});}else return _0x183aa8[_0x3d91c7('0x1d')](0xc8)[_0x3d91c7('0x26')]({'output':_0x3d91c7('0x2')});}module[_0x5754c6('0x8')]={'index':index,'fetch':fetch,'migrations':migrations,'pull':pull,'reset':reset,'restart':restart}; \ No newline at end of file +const a701_0x1114=['push','join','git\x20reset\x20--hard','json','simple-git','../../mysqldb','catch','motion2','then','2.0.0','restart','git\x20fetch\x20origin\x20master','Your\x20system\x20has\x20been\x20restart\x20successfully','origin','child_process','path','info','umzug','length','sort','replace','root','tags','latest','readdirSync','compare-versions','map','git\x20reset\x20--hard\x20FETCH_HEAD','Database\x20already\x20up-to-date','FETCH_HEAD','reset','.js','constructor','pm2\x20restart\x20motion\x20%s','query','fetch','Migration\x20tried\x20to\x20use\x20old\x20style\x20\x22done\x22\x20callback.\x20Please\x20upgrade\x20to\x20\x22umzug\x22\x20and\x20return\x20a\x20promise\x20instead.','error','migrations','version','lodash','Migration','getQueryInterface','../../config/logger','../../config/environment','sequelize','master','status','../../utils/build-info'];(function(_0x3189cc,_0x1114d9){const _0x1a3793=function(_0xa77f33){while(--_0xa77f33){_0x3189cc['push'](_0x3189cc['shift']());}};_0x1a3793(++_0x1114d9);}(a701_0x1114,0x12c));const a701_0x1a37=function(_0x3189cc,_0x1114d9){_0x3189cc=_0x3189cc-0x0;let _0x1a3793=a701_0x1114[_0x3189cc];return _0x1a3793;};const _0x5f3394=a701_0x1a37;'use strict';const Umzug=require(_0x5f3394('0xb')),path=require(_0x5f3394('0x9')),fs=require('fs'),_=require(_0x5f3394('0x22')),compareVersions=require(_0x5f3394('0x13')),exec=require(_0x5f3394('0x8'))['exec'],db=require(_0x5f3394('0x30'))['db'],config=require(_0x5f3394('0x26')),pm2=require('../../config/pm2'),logger=require(_0x5f3394('0x25'))('update'),{version:packageVersion}=require('../../../package.json'),git=require(_0x5f3394('0x2f'))(config[_0x5f3394('0xf')]),{UniqueConstraintError}=require(_0x5f3394('0x27')),{readBuildInfo}=require(_0x5f3394('0x2a'));async function index(_0xa77f33,_0x46fb3b){const _0x13c6bb=_0x5f3394,_0x45515f=await readBuildInfo(),_0x141fd8={'current':packageVersion,'phonebar':0x2,..._0x45515f};return _0xa77f33[_0x13c6bb('0x1c')]&&_0xa77f33[_0x13c6bb('0x1c')][_0x13c6bb('0x11')]?git[_0x13c6bb('0x1d')]()[_0x13c6bb('0x10')](function(_0x15dd77,_0x1c8650){const _0x5680f4=_0x13c6bb;return _0x141fd8[_0x5680f4('0x11')]=(_0x15dd77?packageVersion:_0x1c8650[_0x5680f4('0x11')])||_0x5680f4('0x3'),_0x46fb3b[_0x5680f4('0x29')](0xc8)[_0x5680f4('0x2e')](_0x141fd8);}):_0x46fb3b['status'](0xc8)[_0x13c6bb('0x2e')](_0x141fd8);}function fetch(_0x43bd61,_0x4c95a1){const _0x301d88=_0x5f3394;return git[_0x301d88('0x1d')]([_0x301d88('0x7'),_0x301d88('0x28')],function(_0x1872f9){const _0x4c9ba6=_0x301d88;if(_0x1872f9)return logger[_0x4c9ba6('0x1f')](_0x1872f9),_0x4c95a1[_0x4c9ba6('0x29')](0x1f4)['json'](_0x1872f9);return logger[_0x4c9ba6('0xa')]('git\x20fetch'),_0x4c95a1[_0x4c9ba6('0x29')](0xc8)[_0x4c9ba6('0x2e')]({'output':_0x4c9ba6('0x5')});});}function reset(_0x5ed1d7,_0x52235c){const _0x1db874=_0x5f3394;return git[_0x1db874('0x18')](['--hard',_0x1db874('0x17')],function(_0x90597d){const _0x322400=_0x1db874;if(_0x90597d)return logger['error'](_0x90597d),_0x52235c['status'](0x1f4)[_0x322400('0x2e')](_0x90597d);return logger[_0x322400('0xa')](_0x322400('0x15')),_0x52235c[_0x322400('0x29')](0xc8)[_0x322400('0x2e')]({'output':_0x322400('0x2d')});});}function pull(_0x381e80,_0x2fe4f2){exec('npm\x20install\x20--production',function(_0xf3c440,_0x40afb1,_0x82873e){const _0x5540af=a701_0x1a37;logger['info'](_0x40afb1),logger[_0x5540af('0xa')](_0x82873e);if(_0xf3c440)return logger[_0x5540af('0x1f')](_0xf3c440),_0x2fe4f2[_0x5540af('0x29')](0x1f4)['json'](_0xf3c440);return _0x2fe4f2[_0x5540af('0x29')](0xc8)[_0x5540af('0x2e')]({'output':_0x40afb1});});}function restart(_0x2bc9e2,_0x2cdeeb){const _0x4e8f97=_0x5f3394;return pm2[_0x4e8f97('0x4')](_0x4e8f97('0x1'))[_0x4e8f97('0x2')](function(_0x2fee33){const _0x36e341=_0x4e8f97;return logger[_0x36e341('0xa')](_0x36e341('0x1b'),_0x2fee33),_0x2cdeeb[_0x36e341('0x29')](0xc8)[_0x36e341('0x2e')]({'output':_0x36e341('0x6')});})[_0x4e8f97('0x0')](function(_0x2450dc){const _0x27be52=_0x4e8f97;return logger['error'](_0x2450dc),_0x2cdeeb[_0x27be52('0x29')](0x1f4)[_0x27be52('0x2e')](_0x2450dc);});}function migrations(_0x4ec9c1,_0x3ecff8){const _0xed6344=_0x5f3394,_0x5c940d=fs[_0xed6344('0x12')](path[_0xed6344('0x2c')](config['root'],_0xed6344('0x20'))),_0x16029f=[];for(let _0x5f5da0=0x0;_0x5f5da0<_0x5c940d['length'];_0x5f5da0++){const _0x27dd49=_0x5c940d[_0x5f5da0][_0xed6344('0xe')](_0xed6344('0x19'),'');compareVersions(packageVersion,_0x27dd49)===-0x1&&_0x16029f[_0xed6344('0x2b')](_0x27dd49);}if(_0x16029f[_0xed6344('0xc')]){const _0x321a43=_0x16029f[_0xed6344('0xd')](compareVersions),_0x61de56=new Umzug({'storage':_0xed6344('0x27'),'storageOptions':{'model':db[_0xed6344('0x23')],'modelName':_0xed6344('0x23'),'columnName':_0xed6344('0x21')},'migrations':{'params':[db['sequelize'][_0xed6344('0x24')](),db['sequelize'][_0xed6344('0x1a')],function(){const _0x7100a1=_0xed6344;throw new Error(_0x7100a1('0x1e'));}],'path':path[_0xed6344('0x2c')](config[_0xed6344('0xf')],_0xed6344('0x20')),'pattern':/\.js$/}});_0x61de56['up']({'migrations':_[_0xed6344('0x14')](_0x321a43,function(_0xafd938){const _0x58e7c6=_0xed6344;return _0xafd938+_0x58e7c6('0x19');})})[_0xed6344('0x2')](function(){const _0x49853a=_0xed6344;return _0x3ecff8[_0x49853a('0x29')](0xc8)[_0x49853a('0x2e')]({'output':'Database\x20migrated\x20successfully\x20from\x20version\x20'+packageVersion+'\x20to\x20'+_['last'](_0x321a43),'migrations':_[_0x49853a('0x2c')](_0x321a43)});})[_0xed6344('0x0')](function(_0x1eba19){const _0x15d34f=_0xed6344;return _0x1eba19 instanceof UniqueConstraintError?_0x3ecff8['status'](0xc8)[_0x15d34f('0x2e')]({'output':_0x15d34f('0x16')}):_0x3ecff8[_0x15d34f('0x29')](0x1f4)[_0x15d34f('0x2e')](_0x1eba19);});}else return _0x3ecff8['status'](0xc8)[_0xed6344('0x2e')]({'output':_0xed6344('0x16')});}module['exports']={'index':index,'fetch':fetch,'migrations':migrations,'pull':pull,'reset':reset,'restart':restart}; \ No newline at end of file diff --git a/server/api/voiceAgentReport/index.js b/server/api/voiceAgentReport/index.js index 012fc3e..b3d10a1 100644 --- a/server/api/voiceAgentReport/index.js +++ b/server/api/voiceAgentReport/index.js @@ -1 +1 @@ -const a702_0xd1be=['Router','show','get','/:id','put','express','/describe','destroy','post','delete','isAuthenticated','exports','update','create'];(function(_0x32e437,_0xd1be62){const _0x4eec79=function(_0x2992bc){while(--_0x2992bc){_0x32e437['push'](_0x32e437['shift']());}};_0x4eec79(++_0xd1be62);}(a702_0xd1be,0x171));const a702_0x4eec=function(_0x32e437,_0xd1be62){_0x32e437=_0x32e437-0x0;let _0x4eec79=a702_0xd1be[_0x32e437];return _0x4eec79;};const _0x4e0057=a702_0x4eec;'use strict';const express=require(_0x4e0057('0x0')),router=express[_0x4e0057('0x9')](),auth=require('../../components/auth/service'),controller=require('./voiceAgentReport.controller');router[_0x4e0057('0xb')]('/',auth['isAuthenticated'](),controller['index']),router['get'](_0x4e0057('0x1'),auth[_0x4e0057('0x5')](),controller['describe']),router[_0x4e0057('0xb')](_0x4e0057('0xc'),auth[_0x4e0057('0x5')](),controller[_0x4e0057('0xa')]),router[_0x4e0057('0x3')]('/',auth[_0x4e0057('0x5')](),controller[_0x4e0057('0x8')]),router[_0x4e0057('0xd')](_0x4e0057('0xc'),auth[_0x4e0057('0x5')](),controller[_0x4e0057('0x7')]),router[_0x4e0057('0x4')](_0x4e0057('0xc'),auth['isAuthenticated'](),controller[_0x4e0057('0x2')]),module[_0x4e0057('0x6')]=router; \ No newline at end of file +const a702_0x53d5=['Router','exports','post','../../components/auth/service','destroy','express','/:id','update','get','delete','create','isAuthenticated','./voiceAgentReport.controller','/describe','describe','index'];(function(_0x497111,_0x53d55f){const _0x2fbcd3=function(_0x34357b){while(--_0x34357b){_0x497111['push'](_0x497111['shift']());}};_0x2fbcd3(++_0x53d55f);}(a702_0x53d5,0x7b));const a702_0x2fbc=function(_0x497111,_0x53d55f){_0x497111=_0x497111-0x0;let _0x2fbcd3=a702_0x53d5[_0x497111];return _0x2fbcd3;};const _0x1c7080=a702_0x2fbc;'use strict';const express=require(_0x1c7080('0xa')),router=express[_0x1c7080('0x5')](),auth=require(_0x1c7080('0x8')),controller=require(_0x1c7080('0x1'));router['get']('/',auth['isAuthenticated'](),controller[_0x1c7080('0x4')]),router[_0x1c7080('0xd')](_0x1c7080('0x2'),auth[_0x1c7080('0x0')](),controller[_0x1c7080('0x3')]),router[_0x1c7080('0xd')]('/:id',auth[_0x1c7080('0x0')](),controller['show']),router[_0x1c7080('0x7')]('/',auth[_0x1c7080('0x0')](),controller[_0x1c7080('0xf')]),router['put'](_0x1c7080('0xb'),auth[_0x1c7080('0x0')](),controller[_0x1c7080('0xc')]),router[_0x1c7080('0xe')]('/:id',auth[_0x1c7080('0x0')](),controller[_0x1c7080('0x9')]),module[_0x1c7080('0x6')]=router; \ No newline at end of file diff --git a/server/api/voiceAgentReport/voiceAgentReport.attributes.js b/server/api/voiceAgentReport/voiceAgentReport.attributes.js index 3de2b8b..a810f85 100644 --- a/server/api/voiceAgentReport/voiceAgentReport.attributes.js +++ b/server/api/voiceAgentReport/voiceAgentReport.attributes.js @@ -1 +1 @@ -const a703_0x30f6=['sequelize','BOOLEAN','INTEGER','DATE','exports','FORWARD,\x20BLIND,\x20ATTENDED','STRING'];(function(_0x53fe69,_0x30f65d){const _0x52b21f=function(_0x22b4a9){while(--_0x22b4a9){_0x53fe69['push'](_0x53fe69['shift']());}};_0x52b21f(++_0x30f65d);}(a703_0x30f6,0x1a8));const a703_0x52b2=function(_0x53fe69,_0x30f65d){_0x53fe69=_0x53fe69-0x0;let _0x52b21f=a703_0x30f6[_0x53fe69];return _0x52b21f;};const _0x3c9270=a703_0x52b2;'use strict';const Sequelize=require(_0x3c9270('0x3'));module[_0x3c9270('0x0')]={'type':{'type':Sequelize[_0x3c9270('0x2')]},'uniqueid':{'type':Sequelize[_0x3c9270('0x2')]},'calleridnum':{'type':Sequelize[_0x3c9270('0x2')]},'calleridname':{'type':Sequelize['STRING']},'queue':{'type':Sequelize[_0x3c9270('0x2')]},'interface':{'type':Sequelize[_0x3c9270('0x2')]},'membername':{'type':Sequelize[_0x3c9270('0x2')]},'agentcalledAt':{'type':Sequelize[_0x3c9270('0x6')]},'agentconnectAt':{'type':Sequelize[_0x3c9270('0x6')]},'agentcompleteAt':{'type':Sequelize[_0x3c9270('0x6')]},'agentringnoanswerAt':{'type':Sequelize[_0x3c9270('0x6')]},'agentdumpAt':{'type':Sequelize[_0x3c9270('0x6')]},'holdtime':{'type':Sequelize[_0x3c9270('0x5')]},'agentcomplete':{'type':Sequelize[_0x3c9270('0x4')],'defaultValue':![]},'agentringnoanswer':{'type':Sequelize[_0x3c9270('0x4')],'defaultValue':![]},'agentdump':{'type':Sequelize[_0x3c9270('0x4')],'defaultValue':![]},'talktime':{'type':Sequelize[_0x3c9270('0x5')]},'agentacw':{'type':Sequelize[_0x3c9270('0x4')],'defaultValue':![]},'acwtime':{'type':Sequelize[_0x3c9270('0x5')]},'reason':{'type':Sequelize[_0x3c9270('0x2')]},'lastevent':{'type':Sequelize[_0x3c9270('0x2')]},'channel':{'type':Sequelize['STRING']},'channelstate':{'type':Sequelize['INTEGER']},'channelstatedesc':{'type':Sequelize['STRING']},'connectedlinenum':{'type':Sequelize[_0x3c9270('0x2')]},'connectedlinename':{'type':Sequelize[_0x3c9270('0x2')]},'language':{'type':Sequelize['STRING']},'accountcode':{'type':Sequelize[_0x3c9270('0x2')]},'context':{'type':Sequelize['STRING']},'exten':{'type':Sequelize[_0x3c9270('0x2')]},'priority':{'type':Sequelize[_0x3c9270('0x2')]},'destchannel':{'type':Sequelize['STRING']},'destchannelstate':{'type':Sequelize['INTEGER']},'destchannelstatedesc':{'type':Sequelize[_0x3c9270('0x2')]},'destcalleridnum':{'type':Sequelize[_0x3c9270('0x2')]},'destcalleridname':{'type':Sequelize[_0x3c9270('0x2')]},'destconnectedlinenum':{'type':Sequelize[_0x3c9270('0x2')]},'destconnectedlinename':{'type':Sequelize[_0x3c9270('0x2')]},'destlanguage':{'type':Sequelize[_0x3c9270('0x2')]},'destaccountcode':{'type':Sequelize[_0x3c9270('0x2')]},'destcontext':{'type':Sequelize[_0x3c9270('0x2')]},'destexten':{'type':Sequelize[_0x3c9270('0x2')]},'destpriority':{'type':Sequelize[_0x3c9270('0x2')]},'destuniqueid':{'type':Sequelize[_0x3c9270('0x2')]},'answeredelsewheredestinationuniqueid':{'type':Sequelize[_0x3c9270('0x2')]},'answeredelsewheremembername':{'type':Sequelize['STRING']},'transfer':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'transfertype':{'type':Sequelize[_0x3c9270('0x2')],'comment':_0x3c9270('0x1')},'transferexten':{'type':Sequelize[_0x3c9270('0x2')]},'transferuniqueid':{'type':Sequelize['STRING']},'agententerreason':{'type':Sequelize[_0x3c9270('0x5')],'defaultValue':0x0}}; \ No newline at end of file +const a703_0xa1ca=['STRING','DATE','INTEGER','sequelize','BOOLEAN'];(function(_0x3bc06b,_0xa1caab){const _0x431609=function(_0x43900b){while(--_0x43900b){_0x3bc06b['push'](_0x3bc06b['shift']());}};_0x431609(++_0xa1caab);}(a703_0xa1ca,0x95));const a703_0x4316=function(_0x3bc06b,_0xa1caab){_0x3bc06b=_0x3bc06b-0x0;let _0x431609=a703_0xa1ca[_0x3bc06b];return _0x431609;};const _0x26db01=a703_0x4316;'use strict';const Sequelize=require(_0x26db01('0x4'));module['exports']={'type':{'type':Sequelize[_0x26db01('0x1')]},'uniqueid':{'type':Sequelize['STRING']},'calleridnum':{'type':Sequelize[_0x26db01('0x1')]},'calleridname':{'type':Sequelize[_0x26db01('0x1')]},'queue':{'type':Sequelize[_0x26db01('0x1')]},'interface':{'type':Sequelize[_0x26db01('0x1')]},'membername':{'type':Sequelize[_0x26db01('0x1')]},'agentcalledAt':{'type':Sequelize[_0x26db01('0x2')]},'agentconnectAt':{'type':Sequelize[_0x26db01('0x2')]},'agentcompleteAt':{'type':Sequelize[_0x26db01('0x2')]},'agentringnoanswerAt':{'type':Sequelize[_0x26db01('0x2')]},'agentdumpAt':{'type':Sequelize[_0x26db01('0x2')]},'holdtime':{'type':Sequelize['INTEGER']},'agentcomplete':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'agentringnoanswer':{'type':Sequelize[_0x26db01('0x0')],'defaultValue':![]},'agentdump':{'type':Sequelize[_0x26db01('0x0')],'defaultValue':![]},'talktime':{'type':Sequelize['INTEGER']},'agentacw':{'type':Sequelize[_0x26db01('0x0')],'defaultValue':![]},'acwtime':{'type':Sequelize['INTEGER']},'reason':{'type':Sequelize['STRING']},'lastevent':{'type':Sequelize[_0x26db01('0x1')]},'channel':{'type':Sequelize['STRING']},'channelstate':{'type':Sequelize[_0x26db01('0x3')]},'channelstatedesc':{'type':Sequelize[_0x26db01('0x1')]},'connectedlinenum':{'type':Sequelize[_0x26db01('0x1')]},'connectedlinename':{'type':Sequelize[_0x26db01('0x1')]},'language':{'type':Sequelize[_0x26db01('0x1')]},'accountcode':{'type':Sequelize[_0x26db01('0x1')]},'context':{'type':Sequelize[_0x26db01('0x1')]},'exten':{'type':Sequelize[_0x26db01('0x1')]},'priority':{'type':Sequelize[_0x26db01('0x1')]},'destchannel':{'type':Sequelize['STRING']},'destchannelstate':{'type':Sequelize[_0x26db01('0x3')]},'destchannelstatedesc':{'type':Sequelize[_0x26db01('0x1')]},'destcalleridnum':{'type':Sequelize['STRING']},'destcalleridname':{'type':Sequelize[_0x26db01('0x1')]},'destconnectedlinenum':{'type':Sequelize['STRING']},'destconnectedlinename':{'type':Sequelize['STRING']},'destlanguage':{'type':Sequelize[_0x26db01('0x1')]},'destaccountcode':{'type':Sequelize['STRING']},'destcontext':{'type':Sequelize[_0x26db01('0x1')]},'destexten':{'type':Sequelize[_0x26db01('0x1')]},'destpriority':{'type':Sequelize[_0x26db01('0x1')]},'destuniqueid':{'type':Sequelize['STRING']},'answeredelsewheredestinationuniqueid':{'type':Sequelize[_0x26db01('0x1')]},'answeredelsewheremembername':{'type':Sequelize[_0x26db01('0x1')]},'transfer':{'type':Sequelize[_0x26db01('0x0')],'defaultValue':![]},'transfertype':{'type':Sequelize[_0x26db01('0x1')],'comment':'FORWARD,\x20BLIND,\x20ATTENDED'},'transferexten':{'type':Sequelize[_0x26db01('0x1')]},'transferuniqueid':{'type':Sequelize[_0x26db01('0x1')]},'agententerreason':{'type':Sequelize[_0x26db01('0x3')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/voiceAgentReport/voiceAgentReport.controller.js b/server/api/voiceAgentReport/voiceAgentReport.controller.js index 749cd9e..d8dc175 100644 --- a/server/api/voiceAgentReport/voiceAgentReport.controller.js +++ b/server/api/voiceAgentReport/voiceAgentReport.controller.js @@ -1 +1 @@ -const a704_0x43a1=['Content-Range','filters','findOne','keys','create','VIRTUAL','count','limit','body','send','set','describe','status','length','json','nolimit','fieldName','where','query','rawAttributes','attributes','order','stack','rows','findAll','end','offset','merge','sequelize','api','pick','then','destroy','fields','like','intersection','type','includeAll','map','catch','show','index','params','include','key','undefined','VoiceAgentReport','error','options','../../mysqldb','../../components/parsers/qs','name','update','lodash','sort','model'];(function(_0x462fd4,_0x43a172){const _0x3ec140=function(_0x9bc0dd){while(--_0x9bc0dd){_0x462fd4['push'](_0x462fd4['shift']());}};_0x3ec140(++_0x43a172);}(a704_0x43a1,0x1c0));const a704_0x3ec1=function(_0x462fd4,_0x43a172){_0x462fd4=_0x462fd4-0x0;let _0x3ec140=a704_0x43a1[_0x462fd4];return _0x3ec140;};const _0x5dde5a=a704_0x3ec1;'use strict';const _=require(_0x5dde5a('0x35')),qs=require(_0x5dde5a('0x32')),logger=require('../../config/logger')(_0x5dde5a('0x1d')),db=require(_0x5dde5a('0x31'))['db'],{Op}=require(_0x5dde5a('0x1c'));function respondWithResult(_0x9bc0dd,_0x44f00d){return _0x44f00d=_0x44f00d||0xc8,function(_0xf3790a){const _0x226859=a704_0x3ec1;if(_0xf3790a)return _0x9bc0dd[_0x226859('0xc')](_0x44f00d)[_0x226859('0xe')](_0xf3790a);};}function respondWithFilteredResult(_0x520863,_0x1f0835){return function(_0x51bdde){const _0x25e6c5=a704_0x3ec1;if(_0x51bdde){const _0x2e82c4=_0x51bdde[_0x25e6c5('0x6')],_0x76a716=_0x1f0835[_0x25e6c5('0x1a')];let _0x15c3c1=_0x1f0835[_0x25e6c5('0x1a')]+_0x1f0835['limit'],_0x3fde54;return _0x15c3c1>=_0x2e82c4?(_0x15c3c1=_0x2e82c4,_0x3fde54=0xc8):_0x3fde54=0xce,_0x520863[_0x25e6c5('0xc')](_0x3fde54),_0x520863[_0x25e6c5('0xa')](_0x25e6c5('0x0'),_0x76a716+'-'+_0x15c3c1+'/'+_0x2e82c4)[_0x25e6c5('0xe')](_0x51bdde);}return null;};}function saveUpdates(_0x391961){return function(_0x191368){const _0x50fa75=a704_0x3ec1;if(_0x191368)return _0x191368['update'](_0x391961)[_0x50fa75('0x1f')](function(_0x5b2a18){return _0x5b2a18;});return null;};}function removeEntity(_0x31f33b){return function(_0x5a1a99){const _0x6fee6=a704_0x3ec1;if(_0x5a1a99)return _0x5a1a99[_0x6fee6('0x20')]()[_0x6fee6('0x1f')](function(){const _0x5a682e=_0x6fee6;_0x31f33b['status'](0xcc)[_0x5a682e('0x19')]();});};}function handleEntityNotFound(_0x3a1d49){return function(_0x250f2d){return!_0x250f2d&&_0x3a1d49['sendStatus'](0x194),_0x250f2d;};}function handleError(_0x56c2f0,_0x346cf0){return _0x346cf0=_0x346cf0||0x1f4,function(_0x4f9dd1){const _0x5bed69=a704_0x3ec1;logger[_0x5bed69('0x2f')](_0x4f9dd1[_0x5bed69('0x16')]),_0x4f9dd1[_0x5bed69('0x33')]&&delete _0x4f9dd1['name'],_0x56c2f0[_0x5bed69('0xc')](_0x346cf0)[_0x5bed69('0x9')](_0x4f9dd1);};}exports[_0x5dde5a('0x29')]=function(_0x18b383,_0x3654fa){const _0x35d032=_0x5dde5a;let _0x14383c={};const _0x4b76e9={},_0x520214={'count':0x0,'rows':[]},_0x4575db=_[_0x35d032('0x26')](db['VoiceAgentReport'][_0x35d032('0x13')],function(_0x133f28){const _0x180ebf=_0x35d032;return{'name':_0x133f28[_0x180ebf('0x10')],'type':_0x133f28[_0x180ebf('0x24')][_0x180ebf('0x2c')]};});_0x4b76e9[_0x35d032('0x37')]=_['map'](_0x4575db,_0x35d032('0x33')),_0x4b76e9['query']=_[_0x35d032('0x3')](_0x18b383[_0x35d032('0x12')]),_0x4b76e9[_0x35d032('0x1')]=_[_0x35d032('0x23')](_0x4b76e9['model'],_0x4b76e9[_0x35d032('0x12')]),_0x14383c[_0x35d032('0x14')]=_[_0x35d032('0x23')](_0x4b76e9[_0x35d032('0x37')],qs[_0x35d032('0x21')](_0x18b383[_0x35d032('0x12')][_0x35d032('0x21')])),_0x14383c['attributes']=_0x14383c[_0x35d032('0x14')][_0x35d032('0xd')]?_0x14383c[_0x35d032('0x14')]:_0x4b76e9['model'];typeof _0x18b383[_0x35d032('0x12')][_0x35d032('0xf')]===_0x35d032('0x2d')&&(_0x14383c[_0x35d032('0x7')]=qs[_0x35d032('0x7')](_0x18b383[_0x35d032('0x12')][_0x35d032('0x7')]),_0x14383c[_0x35d032('0x1a')]=qs[_0x35d032('0x1a')](_0x18b383[_0x35d032('0x12')][_0x35d032('0x1a')]));_0x14383c[_0x35d032('0x15')]=qs[_0x35d032('0x36')](_0x18b383[_0x35d032('0x12')]['sort']),_0x14383c[_0x35d032('0x11')]=qs['filters'](_[_0x35d032('0x1e')](_0x18b383[_0x35d032('0x12')],_0x4b76e9[_0x35d032('0x1')]),_0x4575db);_0x18b383[_0x35d032('0x12')]['filter']&&(_0x14383c[_0x35d032('0x11')]=_['merge'](_0x14383c['where'],{[Op['or']]:_['map'](_0x4575db,function(_0x56d6b0){const _0x4f93a7=_0x35d032;if(_0x56d6b0[_0x4f93a7('0x24')]!==_0x4f93a7('0x5')){const _0x2c7757={};return _0x2c7757[_0x56d6b0[_0x4f93a7('0x33')]]={[Op[_0x4f93a7('0x22')]]:'%'+_0x18b383[_0x4f93a7('0x12')]['filter']+'%'},_0x2c7757;}})}));_0x14383c=_['merge']({},_0x14383c,_0x18b383[_0x35d032('0x30')]);const _0xd36988={'where':_0x14383c['where']};return db[_0x35d032('0x2e')]['count'](_0xd36988)[_0x35d032('0x1f')](function(_0x5c9ae6){const _0x20ad30=_0x35d032;return _0x520214[_0x20ad30('0x6')]=_0x5c9ae6,_0x18b383[_0x20ad30('0x12')][_0x20ad30('0x25')]&&(_0x14383c['include']=[{'all':!![]}]),db['VoiceAgentReport'][_0x20ad30('0x18')](_0x14383c);})[_0x35d032('0x1f')](function(_0x25b99d){const _0x32a2bb=_0x35d032;return _0x520214[_0x32a2bb('0x17')]=_0x25b99d,_0x520214;})[_0x35d032('0x1f')](respondWithFilteredResult(_0x3654fa,_0x14383c))['catch'](handleError(_0x3654fa,null));},exports[_0x5dde5a('0x28')]=function(_0xb008aa,_0x579c96){const _0x5cb31c=_0x5dde5a;let _0x1e41b8={'raw':![],'where':{'id':_0xb008aa[_0x5cb31c('0x2a')]['id']}};const _0x139f79={};return _0x139f79[_0x5cb31c('0x37')]=_[_0x5cb31c('0x3')](db[_0x5cb31c('0x2e')]['rawAttributes']),_0x139f79[_0x5cb31c('0x12')]=_[_0x5cb31c('0x3')](_0xb008aa['query']),_0x139f79[_0x5cb31c('0x1')]=_['intersection'](_0x139f79['model'],_0x139f79[_0x5cb31c('0x12')]),_0x1e41b8[_0x5cb31c('0x14')]=_[_0x5cb31c('0x23')](_0x139f79[_0x5cb31c('0x37')],qs[_0x5cb31c('0x21')](_0xb008aa['query'][_0x5cb31c('0x21')])),_0x1e41b8[_0x5cb31c('0x14')]=_0x1e41b8[_0x5cb31c('0x14')][_0x5cb31c('0xd')]?_0x1e41b8[_0x5cb31c('0x14')]:_0x139f79[_0x5cb31c('0x37')],_0xb008aa[_0x5cb31c('0x12')][_0x5cb31c('0x25')]&&(_0x1e41b8[_0x5cb31c('0x2b')]=[{'all':!![]}]),_0x1e41b8=_[_0x5cb31c('0x1b')]({},_0x1e41b8,_0xb008aa[_0x5cb31c('0x30')]),db[_0x5cb31c('0x2e')][_0x5cb31c('0x2')](_0x1e41b8)[_0x5cb31c('0x1f')](handleEntityNotFound(_0x579c96,null))[_0x5cb31c('0x1f')](respondWithResult(_0x579c96,null))[_0x5cb31c('0x27')](handleError(_0x579c96,null));},exports[_0x5dde5a('0x4')]=function(_0x137b51,_0xfb036f){const _0x598c1d=_0x5dde5a;return db[_0x598c1d('0x2e')][_0x598c1d('0x4')](_0x137b51['body'],{})['then'](respondWithResult(_0xfb036f,0xc9))[_0x598c1d('0x27')](handleError(_0xfb036f,null));},exports[_0x5dde5a('0x34')]=function(_0x413eac,_0x1bd0ee){const _0x8994fb=_0x5dde5a;return _0x413eac[_0x8994fb('0x8')]['id']&&delete _0x413eac[_0x8994fb('0x8')]['id'],db[_0x8994fb('0x2e')]['findOne']({'where':{'id':_0x413eac[_0x8994fb('0x2a')]['id']}})[_0x8994fb('0x1f')](handleEntityNotFound(_0x1bd0ee,null))[_0x8994fb('0x1f')](saveUpdates(_0x413eac[_0x8994fb('0x8')],null))[_0x8994fb('0x1f')](respondWithResult(_0x1bd0ee,null))[_0x8994fb('0x27')](handleError(_0x1bd0ee,null));},exports['destroy']=function(_0x3737cf,_0x5dcc70){const _0x21edec=_0x5dde5a;return db[_0x21edec('0x2e')][_0x21edec('0x2')]({'where':{'id':_0x3737cf[_0x21edec('0x2a')]['id']}})['then'](handleEntityNotFound(_0x5dcc70,null))[_0x21edec('0x1f')](removeEntity(_0x5dcc70,null))['catch'](handleError(_0x5dcc70,null));},exports[_0x5dde5a('0xb')]=function(_0x857a5,_0x86c034){const _0x2f31e8=_0x5dde5a;return db['VoiceAgentReport']['describe']()[_0x2f31e8('0x1f')](respondWithResult(_0x86c034,null))[_0x2f31e8('0x27')](handleError(_0x86c034,null));}; \ No newline at end of file +const a704_0x5743=['destroy','../../components/parsers/qs','name','attributes','body','offset','status','includeAll','fields','show','merge','key','like','order','../../mysqldb','options','limit','rows','update','index','catch','intersection','VoiceAgentReport','sequelize','set','map','end','params','filters','json','findOne','keys','nolimit','type','filter','error','sort','length','create','where','fieldName','then','rawAttributes','query','count','../../config/logger','include','findAll','model','describe','send','sendStatus','api'];(function(_0xa611e6,_0x5743e3){const _0x35daa2=function(_0x210571){while(--_0x210571){_0xa611e6['push'](_0xa611e6['shift']());}};_0x35daa2(++_0x5743e3);}(a704_0x5743,0xec));const a704_0x35da=function(_0xa611e6,_0x5743e3){_0xa611e6=_0xa611e6-0x0;let _0x35daa2=a704_0x5743[_0xa611e6];return _0x35daa2;};const _0x123b05=a704_0x35da;'use strict';const _=require('lodash'),qs=require(_0x123b05('0x1e')),logger=require(_0x123b05('0x15'))(_0x123b05('0x1c')),db=require(_0x123b05('0x2b'))['db'],{Op}=require(_0x123b05('0x34'));function respondWithResult(_0x210571,_0x264692){return _0x264692=_0x264692||0xc8,function(_0x2a8f55){const _0xa7b7a2=a704_0x35da;if(_0x2a8f55)return _0x210571[_0xa7b7a2('0x23')](_0x264692)[_0xa7b7a2('0x5')](_0x2a8f55);};}function respondWithFilteredResult(_0x325898,_0x119450){return function(_0xbe9b2e){const _0x5969d7=a704_0x35da;if(_0xbe9b2e){const _0x4aa8de=_0xbe9b2e[_0x5969d7('0x14')],_0xbe478b=_0x119450[_0x5969d7('0x22')];let _0x61f59e=_0x119450[_0x5969d7('0x22')]+_0x119450[_0x5969d7('0x2d')],_0x66f15b;return _0x61f59e>=_0x4aa8de?(_0x61f59e=_0x4aa8de,_0x66f15b=0xc8):_0x66f15b=0xce,_0x325898[_0x5969d7('0x23')](_0x66f15b),_0x325898[_0x5969d7('0x0')]('Content-Range',_0xbe478b+'-'+_0x61f59e+'/'+_0x4aa8de)[_0x5969d7('0x5')](_0xbe9b2e);}return null;};}function saveUpdates(_0x2a5820){return function(_0x9805c){const _0x52ef7=a704_0x35da;if(_0x9805c)return _0x9805c[_0x52ef7('0x2f')](_0x2a5820)[_0x52ef7('0x11')](function(_0x1c064f){return _0x1c064f;});return null;};}function removeEntity(_0x4eea4c){return function(_0x184090){const _0x3eba81=a704_0x35da;if(_0x184090)return _0x184090[_0x3eba81('0x1d')]()[_0x3eba81('0x11')](function(){const _0x15d427=_0x3eba81;_0x4eea4c[_0x15d427('0x23')](0xcc)[_0x15d427('0x2')]();});};}function handleEntityNotFound(_0x4be3a8){return function(_0x12a2d9){const _0x57c669=a704_0x35da;return!_0x12a2d9&&_0x4be3a8[_0x57c669('0x1b')](0x194),_0x12a2d9;};}function handleError(_0x37963c,_0x51d281){return _0x51d281=_0x51d281||0x1f4,function(_0x199537){const _0x1cf663=a704_0x35da;logger[_0x1cf663('0xb')](_0x199537['stack']),_0x199537[_0x1cf663('0x1f')]&&delete _0x199537[_0x1cf663('0x1f')],_0x37963c[_0x1cf663('0x23')](_0x51d281)[_0x1cf663('0x1a')](_0x199537);};}exports[_0x123b05('0x30')]=function(_0x47c2b2,_0x3c7b87){const _0x137525=_0x123b05;let _0xf966f1={};const _0x2da7cb={},_0x520d60={'count':0x0,'rows':[]},_0x559333=_[_0x137525('0x1')](db['VoiceAgentReport'][_0x137525('0x12')],function(_0x367638){const _0x5bc924=_0x137525;return{'name':_0x367638[_0x5bc924('0x10')],'type':_0x367638['type'][_0x5bc924('0x28')]};});_0x2da7cb[_0x137525('0x18')]=_[_0x137525('0x1')](_0x559333,_0x137525('0x1f')),_0x2da7cb[_0x137525('0x13')]=_[_0x137525('0x7')](_0x47c2b2[_0x137525('0x13')]),_0x2da7cb[_0x137525('0x4')]=_[_0x137525('0x32')](_0x2da7cb[_0x137525('0x18')],_0x2da7cb['query']),_0xf966f1['attributes']=_[_0x137525('0x32')](_0x2da7cb[_0x137525('0x18')],qs[_0x137525('0x25')](_0x47c2b2[_0x137525('0x13')][_0x137525('0x25')])),_0xf966f1[_0x137525('0x20')]=_0xf966f1['attributes'][_0x137525('0xd')]?_0xf966f1[_0x137525('0x20')]:_0x2da7cb[_0x137525('0x18')];typeof _0x47c2b2[_0x137525('0x13')][_0x137525('0x8')]==='undefined'&&(_0xf966f1[_0x137525('0x2d')]=qs['limit'](_0x47c2b2[_0x137525('0x13')]['limit']),_0xf966f1[_0x137525('0x22')]=qs[_0x137525('0x22')](_0x47c2b2[_0x137525('0x13')][_0x137525('0x22')]));_0xf966f1[_0x137525('0x2a')]=qs[_0x137525('0xc')](_0x47c2b2[_0x137525('0x13')][_0x137525('0xc')]),_0xf966f1['where']=qs[_0x137525('0x4')](_['pick'](_0x47c2b2['query'],_0x2da7cb['filters']),_0x559333);_0x47c2b2[_0x137525('0x13')]['filter']&&(_0xf966f1['where']=_[_0x137525('0x27')](_0xf966f1[_0x137525('0xf')],{[Op['or']]:_[_0x137525('0x1')](_0x559333,function(_0x2e9bff){const _0x455426=_0x137525;if(_0x2e9bff[_0x455426('0x9')]!=='VIRTUAL'){const _0x541669={};return _0x541669[_0x2e9bff[_0x455426('0x1f')]]={[Op[_0x455426('0x29')]]:'%'+_0x47c2b2['query'][_0x455426('0xa')]+'%'},_0x541669;}})}));_0xf966f1=_[_0x137525('0x27')]({},_0xf966f1,_0x47c2b2[_0x137525('0x2c')]);const _0x1daf82={'where':_0xf966f1['where']};return db['VoiceAgentReport'][_0x137525('0x14')](_0x1daf82)[_0x137525('0x11')](function(_0xbe8eb){const _0x505104=_0x137525;return _0x520d60[_0x505104('0x14')]=_0xbe8eb,_0x47c2b2[_0x505104('0x13')][_0x505104('0x24')]&&(_0xf966f1[_0x505104('0x16')]=[{'all':!![]}]),db['VoiceAgentReport'][_0x505104('0x17')](_0xf966f1);})[_0x137525('0x11')](function(_0x1f2cc4){const _0x1ae75f=_0x137525;return _0x520d60[_0x1ae75f('0x2e')]=_0x1f2cc4,_0x520d60;})[_0x137525('0x11')](respondWithFilteredResult(_0x3c7b87,_0xf966f1))['catch'](handleError(_0x3c7b87,null));},exports[_0x123b05('0x26')]=function(_0x50b70e,_0x322b75){const _0x40f62a=_0x123b05;let _0x124e31={'raw':![],'where':{'id':_0x50b70e[_0x40f62a('0x3')]['id']}};const _0x4408a7={};return _0x4408a7[_0x40f62a('0x18')]=_[_0x40f62a('0x7')](db[_0x40f62a('0x33')]['rawAttributes']),_0x4408a7[_0x40f62a('0x13')]=_[_0x40f62a('0x7')](_0x50b70e[_0x40f62a('0x13')]),_0x4408a7[_0x40f62a('0x4')]=_[_0x40f62a('0x32')](_0x4408a7[_0x40f62a('0x18')],_0x4408a7[_0x40f62a('0x13')]),_0x124e31[_0x40f62a('0x20')]=_[_0x40f62a('0x32')](_0x4408a7[_0x40f62a('0x18')],qs[_0x40f62a('0x25')](_0x50b70e[_0x40f62a('0x13')][_0x40f62a('0x25')])),_0x124e31[_0x40f62a('0x20')]=_0x124e31[_0x40f62a('0x20')]['length']?_0x124e31[_0x40f62a('0x20')]:_0x4408a7[_0x40f62a('0x18')],_0x50b70e[_0x40f62a('0x13')][_0x40f62a('0x24')]&&(_0x124e31[_0x40f62a('0x16')]=[{'all':!![]}]),_0x124e31=_[_0x40f62a('0x27')]({},_0x124e31,_0x50b70e[_0x40f62a('0x2c')]),db['VoiceAgentReport'][_0x40f62a('0x6')](_0x124e31)[_0x40f62a('0x11')](handleEntityNotFound(_0x322b75,null))[_0x40f62a('0x11')](respondWithResult(_0x322b75,null))['catch'](handleError(_0x322b75,null));},exports[_0x123b05('0xe')]=function(_0x468497,_0x46963f){const _0x1b5129=_0x123b05;return db[_0x1b5129('0x33')][_0x1b5129('0xe')](_0x468497['body'],{})[_0x1b5129('0x11')](respondWithResult(_0x46963f,0xc9))[_0x1b5129('0x31')](handleError(_0x46963f,null));},exports[_0x123b05('0x2f')]=function(_0x1b0664,_0x1eb0e4){const _0x1ff00f=_0x123b05;return _0x1b0664[_0x1ff00f('0x21')]['id']&&delete _0x1b0664[_0x1ff00f('0x21')]['id'],db['VoiceAgentReport'][_0x1ff00f('0x6')]({'where':{'id':_0x1b0664[_0x1ff00f('0x3')]['id']}})[_0x1ff00f('0x11')](handleEntityNotFound(_0x1eb0e4,null))[_0x1ff00f('0x11')](saveUpdates(_0x1b0664[_0x1ff00f('0x21')],null))[_0x1ff00f('0x11')](respondWithResult(_0x1eb0e4,null))[_0x1ff00f('0x31')](handleError(_0x1eb0e4,null));},exports[_0x123b05('0x1d')]=function(_0x32ddbf,_0x310669){const _0x58e225=_0x123b05;return db[_0x58e225('0x33')][_0x58e225('0x6')]({'where':{'id':_0x32ddbf[_0x58e225('0x3')]['id']}})[_0x58e225('0x11')](handleEntityNotFound(_0x310669,null))[_0x58e225('0x11')](removeEntity(_0x310669,null))['catch'](handleError(_0x310669,null));},exports['describe']=function(_0xd733bb,_0x184531){const _0x1a2c6a=_0x123b05;return db['VoiceAgentReport'][_0x1a2c6a('0x19')]()[_0x1a2c6a('0x11')](respondWithResult(_0x184531,null))[_0x1a2c6a('0x31')](handleError(_0x184531,null));}; \ No newline at end of file diff --git a/server/api/voiceAgentReport/voiceAgentReport.model.js b/server/api/voiceAgentReport/voiceAgentReport.model.js index 65e1ba6..39ee45f 100644 --- a/server/api/voiceAgentReport/voiceAgentReport.model.js +++ b/server/api/voiceAgentReport/voiceAgentReport.model.js @@ -1 +1 @@ -const a705_0xe50f=['uniqueid','./voiceAgentReport.attributes','destuniqueid','exports'];(function(_0xc15727,_0xe50faf){const _0x119f2c=function(_0x8534cb){while(--_0x8534cb){_0xc15727['push'](_0xc15727['shift']());}};_0x119f2c(++_0xe50faf);}(a705_0xe50f,0x6e));const a705_0x119f=function(_0xc15727,_0xe50faf){_0xc15727=_0xc15727-0x0;let _0x119f2c=a705_0xe50f[_0xc15727];return _0x119f2c;};const _0x31208c=a705_0x119f;'use strict';const attributes=require(_0x31208c('0x3'));module[_0x31208c('0x1')]=function(_0x8534cb){const _0x577928=_0x31208c,_0x4fa23c=_0x8534cb['define']('VoiceAgentReport',attributes,{'tableName':'report_agent','paranoid':![],'indexes':[{'fields':[_0x577928('0x2'),_0x577928('0x0')]}],'timestamps':!![]});return _0x4fa23c;}; \ No newline at end of file +const a705_0x51ec=['define','exports','VoiceAgentReport','uniqueid','report_agent','destuniqueid'];(function(_0x4f179b,_0x51ecc5){const _0x46f986=function(_0x138b70){while(--_0x138b70){_0x4f179b['push'](_0x4f179b['shift']());}};_0x46f986(++_0x51ecc5);}(a705_0x51ec,0xf7));const a705_0x46f9=function(_0x4f179b,_0x51ecc5){_0x4f179b=_0x4f179b-0x0;let _0x46f986=a705_0x51ec[_0x4f179b];return _0x46f986;};const _0xa1bb5e=a705_0x46f9;'use strict';const attributes=require('./voiceAgentReport.attributes');module[_0xa1bb5e('0x0')]=function(_0x138b70){const _0x4a5b2b=_0xa1bb5e,_0x30139a=_0x138b70[_0x4a5b2b('0x5')](_0x4a5b2b('0x1'),attributes,{'tableName':_0x4a5b2b('0x3'),'paranoid':![],'indexes':[{'fields':[_0x4a5b2b('0x2'),_0x4a5b2b('0x4')]}],'timestamps':!![]});return _0x30139a;}; \ No newline at end of file diff --git a/server/api/voiceAgentReport/voiceAgentReport.rpc.js b/server/api/voiceAgentReport/voiceAgentReport.rpc.js index cbd461d..d625d51 100644 --- a/server/api/voiceAgentReport/voiceAgentReport.rpc.js +++ b/server/api/voiceAgentReport/voiceAgentReport.rpc.js @@ -1 +1 @@ -const a706_0x4da9=['then','update','stringify','options','../../config/logger','raw','CreateVoiceAgentReport','UpdateVoiceAgentReport','attributes','body','catch','message','error','debug','limit','../../mysqldb'];(function(_0x44dfce,_0x4da935){const _0x562dfc=function(_0x4777cf){while(--_0x4777cf){_0x44dfce['push'](_0x44dfce['shift']());}};_0x562dfc(++_0x4da935);}(a706_0x4da9,0xcb));const a706_0x562d=function(_0x44dfce,_0x4da935){_0x44dfce=_0x44dfce-0x0;let _0x562dfc=a706_0x4da9[_0x44dfce];return _0x562dfc;};const _0x126a82=a706_0x562d;'use strict';const db=require(_0x126a82('0x4'))['db'],logger=require(_0x126a82('0x9'))('rpc');exports[_0x126a82('0xb')]=function(_0x4777cf){const _0x195e85=this;return new Promise(function(_0x4d27e1,_0x540a7b){const _0x36edb5=a706_0x562d;return db['VoiceAgentReport']['create'](_0x4777cf[_0x36edb5('0xe')],{'raw':_0x4777cf[_0x36edb5('0x8')]?_0x4777cf['options'][_0x36edb5('0xa')]===undefined?!![]:![]:!![]})[_0x36edb5('0x5')](function(_0x40e626){const _0x3eb380=_0x36edb5;logger['info'](_0x3eb380('0xb'),_0x4777cf),logger[_0x3eb380('0x2')](_0x3eb380('0xb'),_0x4777cf,JSON[_0x3eb380('0x7')](_0x40e626)),_0x4d27e1(_0x40e626);})[_0x36edb5('0xf')](function(_0x4b7a51){const _0x291472=_0x36edb5;logger[_0x291472('0x1')](_0x291472('0xb'),_0x4b7a51[_0x291472('0x0')],_0x4777cf),_0x540a7b(_0x195e85['error'](0x1f4,_0x4b7a51[_0x291472('0x0')]));});});},exports[_0x126a82('0xc')]=function(_0x2945dc){const _0x51e4e1=this;return new Promise(function(_0x4a9501,_0xf8b7e9){const _0xb589bc=a706_0x562d;return db['VoiceAgentReport'][_0xb589bc('0x6')](_0x2945dc['body'],{'raw':_0x2945dc[_0xb589bc('0x8')]?_0x2945dc[_0xb589bc('0x8')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x2945dc[_0xb589bc('0x8')]?_0x2945dc[_0xb589bc('0x8')]['where']||null:null,'attributes':_0x2945dc[_0xb589bc('0x8')]?_0x2945dc[_0xb589bc('0x8')][_0xb589bc('0xd')]||null:null,'limit':_0x2945dc[_0xb589bc('0x8')]?_0x2945dc['options'][_0xb589bc('0x3')]||null:null})[_0xb589bc('0x5')](function(_0x715483){const _0x4d4c13=_0xb589bc;logger['info']('UpdateVoiceAgentReport',_0x2945dc),logger[_0x4d4c13('0x2')](_0x4d4c13('0xc'),_0x2945dc,JSON['stringify'](_0x715483)),_0x4a9501(_0x715483);})[_0xb589bc('0xf')](function(_0x95fd29){const _0x4ac359=_0xb589bc;logger['error'](_0x4ac359('0xc'),_0x95fd29['message'],_0x2945dc),_0xf8b7e9(_0x51e4e1['error'](0x1f4,_0x95fd29[_0x4ac359('0x0')]));});});}; \ No newline at end of file +const a706_0x2b42=['where','info','body','attributes','error','VoiceAgentReport','CreateVoiceAgentReport','../../config/logger','raw','debug','../../mysqldb','message','UpdateVoiceAgentReport','options','then','catch','stringify','update'];(function(_0x5effd4,_0x2b4265){const _0x8e04e=function(_0x36bed1){while(--_0x36bed1){_0x5effd4['push'](_0x5effd4['shift']());}};_0x8e04e(++_0x2b4265);}(a706_0x2b42,0x6f));const a706_0x8e04=function(_0x5effd4,_0x2b4265){_0x5effd4=_0x5effd4-0x0;let _0x8e04e=a706_0x2b42[_0x5effd4];return _0x8e04e;};const _0x23a784=a706_0x8e04;'use strict';const db=require(_0x23a784('0x7'))['db'],logger=require(_0x23a784('0x4'))('rpc');exports['CreateVoiceAgentReport']=function(_0x36bed1){const _0x1dd200=this;return new Promise(function(_0x5b299b,_0x432a15){const _0x258c3f=a706_0x8e04;return db[_0x258c3f('0x2')]['create'](_0x36bed1[_0x258c3f('0x11')],{'raw':_0x36bed1[_0x258c3f('0xa')]?_0x36bed1[_0x258c3f('0xa')][_0x258c3f('0x5')]===undefined?!![]:![]:!![]})[_0x258c3f('0xb')](function(_0x1daf4a){const _0x4eb45b=_0x258c3f;logger[_0x4eb45b('0x10')](_0x4eb45b('0x3'),_0x36bed1),logger[_0x4eb45b('0x6')](_0x4eb45b('0x3'),_0x36bed1,JSON['stringify'](_0x1daf4a)),_0x5b299b(_0x1daf4a);})[_0x258c3f('0xc')](function(_0x390e8a){const _0xa4ae5f=_0x258c3f;logger['error'](_0xa4ae5f('0x3'),_0x390e8a[_0xa4ae5f('0x8')],_0x36bed1),_0x432a15(_0x1dd200['error'](0x1f4,_0x390e8a[_0xa4ae5f('0x8')]));});});},exports[_0x23a784('0x9')]=function(_0x23c88d){const _0x7ae0b4=this;return new Promise(function(_0x13f383,_0x1c0214){const _0x24a6f7=a706_0x8e04;return db[_0x24a6f7('0x2')][_0x24a6f7('0xe')](_0x23c88d[_0x24a6f7('0x11')],{'raw':_0x23c88d[_0x24a6f7('0xa')]?_0x23c88d[_0x24a6f7('0xa')][_0x24a6f7('0x5')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x23c88d[_0x24a6f7('0xa')]?_0x23c88d[_0x24a6f7('0xa')][_0x24a6f7('0xf')]||null:null,'attributes':_0x23c88d[_0x24a6f7('0xa')]?_0x23c88d[_0x24a6f7('0xa')][_0x24a6f7('0x0')]||null:null,'limit':_0x23c88d[_0x24a6f7('0xa')]?_0x23c88d[_0x24a6f7('0xa')]['limit']||null:null})[_0x24a6f7('0xb')](function(_0x57a167){const _0x3f2717=_0x24a6f7;logger[_0x3f2717('0x10')](_0x3f2717('0x9'),_0x23c88d),logger[_0x3f2717('0x6')](_0x3f2717('0x9'),_0x23c88d,JSON[_0x3f2717('0xd')](_0x57a167)),_0x13f383(_0x57a167);})['catch'](function(_0x3d7021){const _0x186faa=_0x24a6f7;logger[_0x186faa('0x1')](_0x186faa('0x9'),_0x3d7021[_0x186faa('0x8')],_0x23c88d),_0x1c0214(_0x7ae0b4[_0x186faa('0x1')](0x1f4,_0x3d7021[_0x186faa('0x8')]));});});}; \ No newline at end of file diff --git a/server/api/voiceCallReport/index.js b/server/api/voiceCallReport/index.js index 7a04003..36bf18d 100644 --- a/server/api/voiceCallReport/index.js +++ b/server/api/voiceCallReport/index.js @@ -1 +1 @@ -const a707_0x2f18=['./voiceCallReport.controller','../../components/auth/service','/:id','get','isAuthenticated','index','update','delete','/describe','create','put','post','Router','express','describe'];(function(_0x4fca43,_0x2f187b){const _0x4994d3=function(_0x11bde9){while(--_0x11bde9){_0x4fca43['push'](_0x4fca43['shift']());}};_0x4994d3(++_0x2f187b);}(a707_0x2f18,0x10b));const a707_0x4994=function(_0x4fca43,_0x2f187b){_0x4fca43=_0x4fca43-0x0;let _0x4994d3=a707_0x2f18[_0x4fca43];return _0x4994d3;};const _0x454a79=a707_0x4994;'use strict';const express=require(_0x454a79('0x1')),router=express[_0x454a79('0x0')](),auth=require(_0x454a79('0x4')),controller=require(_0x454a79('0x3'));router[_0x454a79('0x6')]('/',auth[_0x454a79('0x7')](),controller[_0x454a79('0x8')]),router[_0x454a79('0x6')](_0x454a79('0xb'),auth['isAuthenticated'](),controller[_0x454a79('0x2')]),router[_0x454a79('0x6')](_0x454a79('0x5'),auth[_0x454a79('0x7')](),controller['show']),router[_0x454a79('0xe')]('/',auth[_0x454a79('0x7')](),controller[_0x454a79('0xc')]),router[_0x454a79('0xd')](_0x454a79('0x5'),auth[_0x454a79('0x7')](),controller[_0x454a79('0x9')]),router[_0x454a79('0xa')](_0x454a79('0x5'),auth[_0x454a79('0x7')](),controller['destroy']),module['exports']=router; \ No newline at end of file +const a707_0x4100=['isAuthenticated','post','/:id','update','destroy','../../components/auth/service','index','/describe','create','express','exports','show','put','delete','get','Router'];(function(_0x3eec0c,_0x4100f3){const _0x2f26b5=function(_0x2d31d9){while(--_0x2d31d9){_0x3eec0c['push'](_0x3eec0c['shift']());}};_0x2f26b5(++_0x4100f3);}(a707_0x4100,0x1b0));const a707_0x2f26=function(_0x3eec0c,_0x4100f3){_0x3eec0c=_0x3eec0c-0x0;let _0x2f26b5=a707_0x4100[_0x3eec0c];return _0x2f26b5;};const _0x411892=a707_0x2f26;'use strict';const express=require(_0x411892('0x9')),router=express[_0x411892('0xf')](),auth=require(_0x411892('0x5')),controller=require('./voiceCallReport.controller');router[_0x411892('0xe')]('/',auth[_0x411892('0x0')](),controller[_0x411892('0x6')]),router[_0x411892('0xe')](_0x411892('0x7'),auth['isAuthenticated'](),controller['describe']),router[_0x411892('0xe')](_0x411892('0x2'),auth[_0x411892('0x0')](),controller[_0x411892('0xb')]),router[_0x411892('0x1')]('/',auth[_0x411892('0x0')](),controller[_0x411892('0x8')]),router[_0x411892('0xc')](_0x411892('0x2'),auth[_0x411892('0x0')](),controller[_0x411892('0x3')]),router[_0x411892('0xd')](_0x411892('0x2'),auth[_0x411892('0x0')](),controller[_0x411892('0x4')]),module[_0x411892('0xa')]=router; \ No newline at end of file diff --git a/server/api/voiceCallReport/voiceCallReport.attributes.js b/server/api/voiceCallReport/voiceCallReport.attributes.js index 2597f4f..b51d369 100644 --- a/server/api/voiceCallReport/voiceCallReport.attributes.js +++ b/server/api/voiceCallReport/voiceCallReport.attributes.js @@ -1 +1 @@ -const a708_0x2a39=['outbound','sequelize','STRING','TEXT','exports','INTEGER','outbound-fax','dialer','inbound','ENUM','DATE'];(function(_0x51ffc9,_0x2a39b0){const _0x168bf9=function(_0x38b21a){while(--_0x38b21a){_0x51ffc9['push'](_0x51ffc9['shift']());}};_0x168bf9(++_0x2a39b0);}(a708_0x2a39,0x9c));const a708_0x168b=function(_0x51ffc9,_0x2a39b0){_0x51ffc9=_0x51ffc9-0x0;let _0x168bf9=a708_0x2a39[_0x51ffc9];return _0x168bf9;};const _0x33f2ce=a708_0x168b;'use strict';const Sequelize=require(_0x33f2ce('0xa'));module[_0x33f2ce('0x2')]={'uniqueid':{'type':Sequelize['STRING']},'type':{'type':Sequelize[_0x33f2ce('0x7')](_0x33f2ce('0x6'),'internal',_0x33f2ce('0x9'),'inbound-fax',_0x33f2ce('0x4'),_0x33f2ce('0x5'))},'tag':{'type':Sequelize[_0x33f2ce('0x0')]},'accountcode':{'type':Sequelize[_0x33f2ce('0x0')]},'source':{'type':Sequelize[_0x33f2ce('0x0')]},'destination':{'type':Sequelize[_0x33f2ce('0x0')]},'destinationcontext':{'type':Sequelize[_0x33f2ce('0x0')]},'callerid':{'type':Sequelize[_0x33f2ce('0x0')]},'channel':{'type':Sequelize[_0x33f2ce('0x0')]},'destinationchannel':{'type':Sequelize[_0x33f2ce('0x0')]},'lastapplication':{'type':Sequelize[_0x33f2ce('0x0')]},'lastdata':{'type':Sequelize[_0x33f2ce('0x1')]},'starttime':{'type':Sequelize[_0x33f2ce('0x8')]},'systemanswertime':{'type':Sequelize[_0x33f2ce('0x8')]},'answertime':{'type':Sequelize[_0x33f2ce('0x8')]},'endtime':{'type':Sequelize[_0x33f2ce('0x8')]},'duration':{'type':Sequelize[_0x33f2ce('0x3')]},'billableseconds':{'type':Sequelize['INTEGER']},'mohtime':{'type':Sequelize[_0x33f2ce('0x3')],'defaultValue':0x0},'disposition':{'type':Sequelize[_0x33f2ce('0x0')]},'amaflags':{'type':Sequelize['STRING']},'userfield':{'type':Sequelize[_0x33f2ce('0x0')]},'userDisposition':{'type':Sequelize[_0x33f2ce('0x0')]},'userSecondDisposition':{'type':Sequelize[_0x33f2ce('0x0')]},'userThirdDisposition':{'type':Sequelize[_0x33f2ce('0x0')]},'note':{'type':Sequelize[_0x33f2ce('0x0')]},'prefix':{'type':Sequelize[_0x33f2ce('0x0')]},'routeid':{'type':Sequelize['INTEGER']},'sipcallid':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a708_0x4043=['dialer','sequelize','inbound','outbound-fax','STRING','TEXT','DATE','ENUM','outbound','exports','internal','INTEGER'];(function(_0x4ff49b,_0x4043aa){const _0x300187=function(_0x1a80e2){while(--_0x1a80e2){_0x4ff49b['push'](_0x4ff49b['shift']());}};_0x300187(++_0x4043aa);}(a708_0x4043,0xfe));const a708_0x3001=function(_0x4ff49b,_0x4043aa){_0x4ff49b=_0x4ff49b-0x0;let _0x300187=a708_0x4043[_0x4ff49b];return _0x300187;};const _0x2157f7=a708_0x3001;'use strict';const Sequelize=require(_0x2157f7('0xb'));module[_0x2157f7('0x7')]={'uniqueid':{'type':Sequelize[_0x2157f7('0x2')]},'type':{'type':Sequelize[_0x2157f7('0x5')](_0x2157f7('0x0'),_0x2157f7('0x8'),_0x2157f7('0x6'),'inbound-fax',_0x2157f7('0x1'),_0x2157f7('0xa'))},'tag':{'type':Sequelize[_0x2157f7('0x2')]},'accountcode':{'type':Sequelize[_0x2157f7('0x2')]},'source':{'type':Sequelize[_0x2157f7('0x2')]},'destination':{'type':Sequelize[_0x2157f7('0x2')]},'destinationcontext':{'type':Sequelize[_0x2157f7('0x2')]},'callerid':{'type':Sequelize[_0x2157f7('0x2')]},'channel':{'type':Sequelize['STRING']},'destinationchannel':{'type':Sequelize['STRING']},'lastapplication':{'type':Sequelize[_0x2157f7('0x2')]},'lastdata':{'type':Sequelize[_0x2157f7('0x3')]},'starttime':{'type':Sequelize[_0x2157f7('0x4')]},'systemanswertime':{'type':Sequelize[_0x2157f7('0x4')]},'answertime':{'type':Sequelize['DATE']},'endtime':{'type':Sequelize[_0x2157f7('0x4')]},'duration':{'type':Sequelize[_0x2157f7('0x9')]},'billableseconds':{'type':Sequelize[_0x2157f7('0x9')]},'mohtime':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'disposition':{'type':Sequelize[_0x2157f7('0x2')]},'amaflags':{'type':Sequelize[_0x2157f7('0x2')]},'userfield':{'type':Sequelize[_0x2157f7('0x2')]},'userDisposition':{'type':Sequelize[_0x2157f7('0x2')]},'userSecondDisposition':{'type':Sequelize[_0x2157f7('0x2')]},'userThirdDisposition':{'type':Sequelize[_0x2157f7('0x2')]},'note':{'type':Sequelize[_0x2157f7('0x2')]},'prefix':{'type':Sequelize[_0x2157f7('0x2')]},'routeid':{'type':Sequelize[_0x2157f7('0x9')]},'sipcallid':{'type':Sequelize['STRING']}}; \ No newline at end of file diff --git a/server/api/voiceCallReport/voiceCallReport.controller.js b/server/api/voiceCallReport/voiceCallReport.controller.js index 10ba0a2..410877b 100644 --- a/server/api/voiceCallReport/voiceCallReport.controller.js +++ b/server/api/voiceCallReport/voiceCallReport.controller.js @@ -1 +1 @@ -const a709_0x3d69=['filters','like','end','include','lodash','uniqueid','includeAll','options','count','keys','model','rawAttributes','order','../../components/parsers/qs','stack','show','params','fieldName','destroy','../../config/logger','findOne','filter','body','offset','query','limit','user','update','merge','name','error','intersection','create','attributes','Content-Range','index','sendStatus','sort','User','api','pick','map','status','where','json','describe','type','findAll','rows','then','catch','nolimit','fields','../../mysqldb','send','fullname','VoiceCallReport','length','key','sequelize'];(function(_0x1c5bf4,_0x3d6926){const _0x5646db=function(_0x58f6b3){while(--_0x58f6b3){_0x1c5bf4['push'](_0x1c5bf4['shift']());}};_0x5646db(++_0x3d6926);}(a709_0x3d69,0x124));const a709_0x5646=function(_0x1c5bf4,_0x3d6926){_0x1c5bf4=_0x1c5bf4-0x0;let _0x5646db=a709_0x3d69[_0x1c5bf4];return _0x5646db;};const _0x86a7c7=a709_0x5646;'use strict';const _=require(_0x86a7c7('0xc')),qs=require(_0x86a7c7('0x15')),logger=require(_0x86a7c7('0x1b'))(_0x86a7c7('0x2f')),db=require(_0x86a7c7('0x1'))['db'],{Op}=require(_0x86a7c7('0x7'));function respondWithResult(_0x58f6b3,_0xfa36ef){return _0xfa36ef=_0xfa36ef||0xc8,function(_0xd48ac){const _0x5100dd=a709_0x5646;if(_0xd48ac)return _0x58f6b3[_0x5100dd('0x32')](_0xfa36ef)['json'](_0xd48ac);};}function respondWithFilteredResult(_0x200172,_0x140103){return function(_0x36d884){const _0x473a8d=a709_0x5646;if(_0x36d884){const _0x161bbc=_0x36d884[_0x473a8d('0x10')],_0x5bce97=_0x140103['offset'];let _0xc252b9=_0x140103[_0x473a8d('0x1f')]+_0x140103[_0x473a8d('0x21')],_0x48592c;return _0xc252b9>=_0x161bbc?(_0xc252b9=_0x161bbc,_0x48592c=0xc8):_0x48592c=0xce,_0x200172['status'](_0x48592c),_0x200172['set'](_0x473a8d('0x2a'),_0x5bce97+'-'+_0xc252b9+'/'+_0x161bbc)[_0x473a8d('0x34')](_0x36d884);}return null;};}function saveUpdates(_0x4e42fd){return function(_0x530c84){const _0x1ee586=a709_0x5646;if(_0x530c84)return _0x530c84[_0x1ee586('0x23')](_0x4e42fd)[_0x1ee586('0x39')](function(_0x9d6dec){return _0x9d6dec;});return null;};}function removeEntity(_0x43b876){return function(_0x101cc8){const _0x47ba7b=a709_0x5646;if(_0x101cc8)return _0x101cc8[_0x47ba7b('0x1a')]()['then'](function(){const _0x263401=_0x47ba7b;_0x43b876[_0x263401('0x32')](0xcc)[_0x263401('0xa')]();});};}function handleEntityNotFound(_0x496c23){return function(_0x4244ba){const _0x447f15=a709_0x5646;return!_0x4244ba&&_0x496c23[_0x447f15('0x2c')](0x194),_0x4244ba;};}function handleError(_0x537017,_0x3b12b6){return _0x3b12b6=_0x3b12b6||0x1f4,function(_0x5e36f0){const _0x471e2c=a709_0x5646;logger[_0x471e2c('0x26')](_0x5e36f0[_0x471e2c('0x16')]),_0x5e36f0[_0x471e2c('0x25')]&&delete _0x5e36f0[_0x471e2c('0x25')],_0x537017['status'](_0x3b12b6)[_0x471e2c('0x2')](_0x5e36f0);};}exports[_0x86a7c7('0x2b')]=function(_0x13861e,_0x33b9bd){const _0x5a9e9e=_0x86a7c7;let _0x3f94ef={};const _0x16ae82={},_0x3f5e7c={'count':0x0,'rows':[]},_0x1451be=_['map'](db[_0x5a9e9e('0x4')][_0x5a9e9e('0x13')],function(_0x51e66f){const _0x46c960=_0x5a9e9e;return{'name':_0x51e66f[_0x46c960('0x19')],'type':_0x51e66f['type'][_0x46c960('0x6')]};});_0x16ae82[_0x5a9e9e('0x12')]=_[_0x5a9e9e('0x31')](_0x1451be,'name'),_0x16ae82[_0x5a9e9e('0x20')]=_['keys'](_0x13861e[_0x5a9e9e('0x20')]),_0x16ae82[_0x5a9e9e('0x8')]=_['intersection'](_0x16ae82[_0x5a9e9e('0x12')],_0x16ae82['query']),_0x3f94ef['attributes']=_[_0x5a9e9e('0x27')](_0x16ae82[_0x5a9e9e('0x12')],qs[_0x5a9e9e('0x0')](_0x13861e[_0x5a9e9e('0x20')]['fields'])),_0x3f94ef[_0x5a9e9e('0x29')]=_0x3f94ef[_0x5a9e9e('0x29')]['length']?_0x3f94ef[_0x5a9e9e('0x29')]:_0x16ae82[_0x5a9e9e('0x12')];typeof _0x13861e[_0x5a9e9e('0x20')][_0x5a9e9e('0x3b')]==='undefined'&&(_0x3f94ef[_0x5a9e9e('0x21')]=qs[_0x5a9e9e('0x21')](_0x13861e['query']['limit']),_0x3f94ef['offset']=qs['offset'](_0x13861e[_0x5a9e9e('0x20')]['offset']));_0x3f94ef[_0x5a9e9e('0x14')]=qs[_0x5a9e9e('0x2d')](_0x13861e[_0x5a9e9e('0x20')][_0x5a9e9e('0x2d')]),_0x3f94ef[_0x5a9e9e('0x33')]=qs['filters'](_[_0x5a9e9e('0x30')](_0x13861e[_0x5a9e9e('0x20')],_0x16ae82[_0x5a9e9e('0x8')]),_0x1451be);_0x13861e['query']['filter']&&(_0x3f94ef[_0x5a9e9e('0x33')]=_[_0x5a9e9e('0x24')](_0x3f94ef[_0x5a9e9e('0x33')],{[Op['or']]:_[_0x5a9e9e('0x31')](_0x1451be,function(_0x1419cc){const _0x12841b=_0x5a9e9e;if(_0x1419cc[_0x12841b('0x36')]!=='VIRTUAL'){const _0x1660e0={};return _0x1660e0[_0x1419cc['name']]={[Op[_0x12841b('0x9')]]:'%'+_0x13861e[_0x12841b('0x20')][_0x12841b('0x1d')]+'%'},_0x1660e0;}})}));_0x3f94ef=_[_0x5a9e9e('0x24')]({},_0x3f94ef,_0x13861e[_0x5a9e9e('0xf')]);const _0x3c87c4={'where':_0x3f94ef[_0x5a9e9e('0x33')]};return db[_0x5a9e9e('0x4')]['count'](_0x3c87c4)[_0x5a9e9e('0x39')](function(_0x405170){const _0x3b9f54=_0x5a9e9e;return _0x3f5e7c[_0x3b9f54('0x10')]=_0x405170,_0x13861e['query'][_0x3b9f54('0xe')]&&(_0x3f94ef[_0x3b9f54('0xb')]=[{'attributes':['id',_0x3b9f54('0x25'),_0x3b9f54('0x3'),'alias'],'model':db[_0x3b9f54('0x2e')],'as':'User'}]),db[_0x3b9f54('0x4')][_0x3b9f54('0x37')](_0x3f94ef);})[_0x5a9e9e('0x39')](function(_0x2e84e2){const _0x4c7e7a=_0x5a9e9e;return _0x3f5e7c[_0x4c7e7a('0x38')]=_0x2e84e2,_0x3f5e7c;})[_0x5a9e9e('0x39')](respondWithFilteredResult(_0x33b9bd,_0x3f94ef))['catch'](handleError(_0x33b9bd,null));},exports[_0x86a7c7('0x17')]=function(_0x26dba2,_0xe2a03b){const _0x11b18e=_0x86a7c7;let _0x5b45a3={'raw':!![],'where':{'id':_0x26dba2['params']['id']}};const _0x435c36={};return _0x435c36[_0x11b18e('0x12')]=_['keys'](db[_0x11b18e('0x4')][_0x11b18e('0x13')]),_0x435c36['query']=_[_0x11b18e('0x11')](_0x26dba2[_0x11b18e('0x20')]),_0x435c36[_0x11b18e('0x8')]=_['intersection'](_0x435c36['model'],_0x435c36['query']),_0x5b45a3['attributes']=_['intersection'](_0x435c36[_0x11b18e('0x12')],qs[_0x11b18e('0x0')](_0x26dba2[_0x11b18e('0x20')][_0x11b18e('0x0')])),_0x5b45a3[_0x11b18e('0x29')]=_0x5b45a3[_0x11b18e('0x29')][_0x11b18e('0x5')]?_0x5b45a3[_0x11b18e('0x29')]:_0x435c36['model'],_0x26dba2['query'][_0x11b18e('0xe')]&&(_0x5b45a3[_0x11b18e('0xb')]=[{'all':!![]}]),_0x5b45a3=_[_0x11b18e('0x24')]({},_0x5b45a3,_0x26dba2[_0x11b18e('0xf')]),db[_0x11b18e('0x4')][_0x11b18e('0x1c')](_0x5b45a3)['then'](handleEntityNotFound(_0xe2a03b,null))[_0x11b18e('0x39')](respondWithResult(_0xe2a03b,null))['catch'](handleError(_0xe2a03b,null));},exports[_0x86a7c7('0x28')]=function(_0x575bc9,_0x17993b){const _0x11fca3=_0x86a7c7;return db[_0x11fca3('0x4')][_0x11fca3('0x28')](_0x575bc9[_0x11fca3('0x1e')],{})['then'](respondWithResult(_0x17993b,0xc9))['catch'](handleError(_0x17993b,null));},exports[_0x86a7c7('0x1a')]=function(_0x3f92bb,_0x116fb9){const _0x24b100=_0x86a7c7;return db[_0x24b100('0x4')]['findOne']({'where':{'id':_0x3f92bb['params']['id']}})[_0x24b100('0x39')](handleEntityNotFound(_0x116fb9,null))[_0x24b100('0x39')](removeEntity(_0x116fb9,null))['catch'](handleError(_0x116fb9,null));},exports['describe']=function(_0x383d3d,_0x577441){const _0x57b763=_0x86a7c7;return db[_0x57b763('0x4')][_0x57b763('0x35')]()[_0x57b763('0x39')](respondWithResult(_0x577441,null))[_0x57b763('0x3a')](handleError(_0x577441,null));},exports[_0x86a7c7('0x23')]=function(_0x233871,_0x29f7ef){const _0xd627b6=_0x86a7c7;return _0x233871[_0xd627b6('0x1e')][_0xd627b6('0xd')]&&delete _0x233871[_0xd627b6('0x1e')][_0xd627b6('0xd')],db['VoiceCallReport'][_0xd627b6('0x1c')]({'where':{'uniqueid':_0x233871[_0xd627b6('0x18')]['id'],'UserId':{[Op['or']]:[null,_0x233871[_0xd627b6('0x22')]['id']]}}})['then'](handleEntityNotFound(_0x29f7ef,null))['then'](saveUpdates(_0x233871[_0xd627b6('0x1e')],null))[_0xd627b6('0x39')](respondWithResult(_0x29f7ef,null))[_0xd627b6('0x3a')](handleError(_0x29f7ef,null));}; \ No newline at end of file +const a709_0x164e=['offset','query','Content-Range','../../mysqldb','destroy','model','send','length','rows','merge','then','../../components/parsers/qs','stack','attributes','include','user','../../config/logger','User','keys','sort','filter','type','options','includeAll','rawAttributes','set','findAll','VIRTUAL','filters','body','create','show','error','name','findOne','VoiceCallReport','map','update','end','json','nolimit','uniqueid','status','like','where','limit','undefined','fields','key','pick','sendStatus','catch','fullname','params','intersection','count'];(function(_0x19f874,_0x164e72){const _0x223037=function(_0x202166){while(--_0x202166){_0x19f874['push'](_0x19f874['shift']());}};_0x223037(++_0x164e72);}(a709_0x164e,0xed));const a709_0x2230=function(_0x19f874,_0x164e72){_0x19f874=_0x19f874-0x0;let _0x223037=a709_0x164e[_0x19f874];return _0x223037;};const _0x5e05c0=a709_0x2230;'use strict';const _=require('lodash'),qs=require(_0x5e05c0('0x36')),logger=require(_0x5e05c0('0x3'))('api'),db=require(_0x5e05c0('0x2e'))['db'],{Op}=require('sequelize');function respondWithResult(_0x202166,_0x9ecdcd){return _0x9ecdcd=_0x9ecdcd||0xc8,function(_0x39b907){const _0x12e0dd=a709_0x2230;if(_0x39b907)return _0x202166[_0x12e0dd('0x1d')](_0x9ecdcd)[_0x12e0dd('0x1a')](_0x39b907);};}function respondWithFilteredResult(_0x533eb5,_0x5dc355){return function(_0x55660a){const _0x1aed38=a709_0x2230;if(_0x55660a){const _0x506fff=_0x55660a['count'],_0x470c70=_0x5dc355[_0x1aed38('0x2b')];let _0x2b110d=_0x5dc355[_0x1aed38('0x2b')]+_0x5dc355[_0x1aed38('0x20')],_0x20dcf7;return _0x2b110d>=_0x506fff?(_0x2b110d=_0x506fff,_0x20dcf7=0xc8):_0x20dcf7=0xce,_0x533eb5[_0x1aed38('0x1d')](_0x20dcf7),_0x533eb5[_0x1aed38('0xc')](_0x1aed38('0x2d'),_0x470c70+'-'+_0x2b110d+'/'+_0x506fff)[_0x1aed38('0x1a')](_0x55660a);}return null;};}function saveUpdates(_0x522218){return function(_0x4d402d){const _0x419da7=a709_0x2230;if(_0x4d402d)return _0x4d402d[_0x419da7('0x18')](_0x522218)[_0x419da7('0x35')](function(_0x255d5b){return _0x255d5b;});return null;};}function removeEntity(_0x17149f){return function(_0x31c3bd){if(_0x31c3bd)return _0x31c3bd['destroy']()['then'](function(){const _0x35df56=a709_0x2230;_0x17149f[_0x35df56('0x1d')](0xcc)[_0x35df56('0x19')]();});};}function handleEntityNotFound(_0x35924f){return function(_0x1f5d76){const _0x424486=a709_0x2230;return!_0x1f5d76&&_0x35924f[_0x424486('0x25')](0x194),_0x1f5d76;};}function handleError(_0x8193fa,_0x36d55a){return _0x36d55a=_0x36d55a||0x1f4,function(_0x5ed080){const _0x3a1314=a709_0x2230;logger[_0x3a1314('0x13')](_0x5ed080[_0x3a1314('0x37')]),_0x5ed080['name']&&delete _0x5ed080[_0x3a1314('0x14')],_0x8193fa['status'](_0x36d55a)[_0x3a1314('0x31')](_0x5ed080);};}exports['index']=function(_0x5d68e4,_0xd59613){const _0x4d9f36=_0x5e05c0;let _0x3f12f7={};const _0x311db1={},_0x3e0693={'count':0x0,'rows':[]},_0x5a93e5=_[_0x4d9f36('0x17')](db[_0x4d9f36('0x16')][_0x4d9f36('0xb')],function(_0xcfda5){const _0xe94106=_0x4d9f36;return{'name':_0xcfda5['fieldName'],'type':_0xcfda5[_0xe94106('0x8')][_0xe94106('0x23')]};});_0x311db1[_0x4d9f36('0x30')]=_[_0x4d9f36('0x17')](_0x5a93e5,'name'),_0x311db1['query']=_[_0x4d9f36('0x5')](_0x5d68e4[_0x4d9f36('0x2c')]),_0x311db1[_0x4d9f36('0xf')]=_[_0x4d9f36('0x29')](_0x311db1[_0x4d9f36('0x30')],_0x311db1[_0x4d9f36('0x2c')]),_0x3f12f7[_0x4d9f36('0x0')]=_[_0x4d9f36('0x29')](_0x311db1[_0x4d9f36('0x30')],qs[_0x4d9f36('0x22')](_0x5d68e4['query'][_0x4d9f36('0x22')])),_0x3f12f7['attributes']=_0x3f12f7['attributes'][_0x4d9f36('0x32')]?_0x3f12f7[_0x4d9f36('0x0')]:_0x311db1[_0x4d9f36('0x30')];typeof _0x5d68e4[_0x4d9f36('0x2c')][_0x4d9f36('0x1b')]===_0x4d9f36('0x21')&&(_0x3f12f7[_0x4d9f36('0x20')]=qs[_0x4d9f36('0x20')](_0x5d68e4[_0x4d9f36('0x2c')][_0x4d9f36('0x20')]),_0x3f12f7[_0x4d9f36('0x2b')]=qs[_0x4d9f36('0x2b')](_0x5d68e4[_0x4d9f36('0x2c')][_0x4d9f36('0x2b')]));_0x3f12f7['order']=qs[_0x4d9f36('0x6')](_0x5d68e4[_0x4d9f36('0x2c')][_0x4d9f36('0x6')]),_0x3f12f7[_0x4d9f36('0x1f')]=qs[_0x4d9f36('0xf')](_[_0x4d9f36('0x24')](_0x5d68e4[_0x4d9f36('0x2c')],_0x311db1['filters']),_0x5a93e5);_0x5d68e4[_0x4d9f36('0x2c')][_0x4d9f36('0x7')]&&(_0x3f12f7[_0x4d9f36('0x1f')]=_[_0x4d9f36('0x34')](_0x3f12f7[_0x4d9f36('0x1f')],{[Op['or']]:_[_0x4d9f36('0x17')](_0x5a93e5,function(_0x380b05){const _0x12d2fb=_0x4d9f36;if(_0x380b05['type']!==_0x12d2fb('0xe')){const _0x42db88={};return _0x42db88[_0x380b05[_0x12d2fb('0x14')]]={[Op[_0x12d2fb('0x1e')]]:'%'+_0x5d68e4[_0x12d2fb('0x2c')][_0x12d2fb('0x7')]+'%'},_0x42db88;}})}));_0x3f12f7=_[_0x4d9f36('0x34')]({},_0x3f12f7,_0x5d68e4[_0x4d9f36('0x9')]);const _0x245db6={'where':_0x3f12f7[_0x4d9f36('0x1f')]};return db[_0x4d9f36('0x16')][_0x4d9f36('0x2a')](_0x245db6)[_0x4d9f36('0x35')](function(_0x1a2771){const _0x5107a2=_0x4d9f36;return _0x3e0693[_0x5107a2('0x2a')]=_0x1a2771,_0x5d68e4[_0x5107a2('0x2c')][_0x5107a2('0xa')]&&(_0x3f12f7[_0x5107a2('0x1')]=[{'attributes':['id',_0x5107a2('0x14'),_0x5107a2('0x27'),'alias'],'model':db[_0x5107a2('0x4')],'as':'User'}]),db[_0x5107a2('0x16')][_0x5107a2('0xd')](_0x3f12f7);})['then'](function(_0x456e18){const _0x4caeca=_0x4d9f36;return _0x3e0693[_0x4caeca('0x33')]=_0x456e18,_0x3e0693;})[_0x4d9f36('0x35')](respondWithFilteredResult(_0xd59613,_0x3f12f7))[_0x4d9f36('0x26')](handleError(_0xd59613,null));},exports[_0x5e05c0('0x12')]=function(_0xb4760d,_0x89d567){const _0x3669ea=_0x5e05c0;let _0x22dfa6={'raw':!![],'where':{'id':_0xb4760d['params']['id']}};const _0x475ac1={};return _0x475ac1[_0x3669ea('0x30')]=_['keys'](db[_0x3669ea('0x16')][_0x3669ea('0xb')]),_0x475ac1[_0x3669ea('0x2c')]=_[_0x3669ea('0x5')](_0xb4760d[_0x3669ea('0x2c')]),_0x475ac1['filters']=_['intersection'](_0x475ac1[_0x3669ea('0x30')],_0x475ac1['query']),_0x22dfa6['attributes']=_['intersection'](_0x475ac1['model'],qs[_0x3669ea('0x22')](_0xb4760d[_0x3669ea('0x2c')][_0x3669ea('0x22')])),_0x22dfa6[_0x3669ea('0x0')]=_0x22dfa6[_0x3669ea('0x0')]['length']?_0x22dfa6[_0x3669ea('0x0')]:_0x475ac1[_0x3669ea('0x30')],_0xb4760d[_0x3669ea('0x2c')]['includeAll']&&(_0x22dfa6['include']=[{'all':!![]}]),_0x22dfa6=_[_0x3669ea('0x34')]({},_0x22dfa6,_0xb4760d[_0x3669ea('0x9')]),db[_0x3669ea('0x16')][_0x3669ea('0x15')](_0x22dfa6)[_0x3669ea('0x35')](handleEntityNotFound(_0x89d567,null))[_0x3669ea('0x35')](respondWithResult(_0x89d567,null))[_0x3669ea('0x26')](handleError(_0x89d567,null));},exports[_0x5e05c0('0x11')]=function(_0x3bee89,_0x58a288){const _0x157097=_0x5e05c0;return db[_0x157097('0x16')][_0x157097('0x11')](_0x3bee89[_0x157097('0x10')],{})[_0x157097('0x35')](respondWithResult(_0x58a288,0xc9))[_0x157097('0x26')](handleError(_0x58a288,null));},exports[_0x5e05c0('0x2f')]=function(_0x341930,_0x1e4297){const _0x443b0f=_0x5e05c0;return db['VoiceCallReport'][_0x443b0f('0x15')]({'where':{'id':_0x341930[_0x443b0f('0x28')]['id']}})[_0x443b0f('0x35')](handleEntityNotFound(_0x1e4297,null))[_0x443b0f('0x35')](removeEntity(_0x1e4297,null))[_0x443b0f('0x26')](handleError(_0x1e4297,null));},exports['describe']=function(_0x567610,_0x51d01c){const _0x4671f5=_0x5e05c0;return db[_0x4671f5('0x16')]['describe']()[_0x4671f5('0x35')](respondWithResult(_0x51d01c,null))[_0x4671f5('0x26')](handleError(_0x51d01c,null));},exports['update']=function(_0x37e8cb,_0x586201){const _0x336505=_0x5e05c0;return _0x37e8cb['body'][_0x336505('0x1c')]&&delete _0x37e8cb[_0x336505('0x10')]['uniqueid'],db[_0x336505('0x16')][_0x336505('0x15')]({'where':{'uniqueid':_0x37e8cb[_0x336505('0x28')]['id'],'UserId':{[Op['or']]:[null,_0x37e8cb[_0x336505('0x2')]['id']]}}})[_0x336505('0x35')](handleEntityNotFound(_0x586201,null))[_0x336505('0x35')](saveUpdates(_0x37e8cb[_0x336505('0x10')],null))[_0x336505('0x35')](respondWithResult(_0x586201,null))[_0x336505('0x26')](handleError(_0x586201,null));}; \ No newline at end of file diff --git a/server/api/voiceCallReport/voiceCallReport.model.js b/server/api/voiceCallReport/voiceCallReport.model.js index ad68e30..2b3684f 100644 --- a/server/api/voiceCallReport/voiceCallReport.model.js +++ b/server/api/voiceCallReport/voiceCallReport.model.js @@ -1 +1 @@ -const a710_0x193f=['uniqueid','VoiceCallReport','report_call','exports','./voiceCallReport.attributes','define'];(function(_0x44d16f,_0x193fc4){const _0xac98c0=function(_0x35903d){while(--_0x35903d){_0x44d16f['push'](_0x44d16f['shift']());}};_0xac98c0(++_0x193fc4);}(a710_0x193f,0x15b));const a710_0xac98=function(_0x44d16f,_0x193fc4){_0x44d16f=_0x44d16f-0x0;let _0xac98c0=a710_0x193f[_0x44d16f];return _0xac98c0;};const _0x381497=a710_0xac98;'use strict';const attributes=require(_0x381497('0x5'));module[_0x381497('0x4')]=function(_0x35903d){const _0xbc2a04=_0x381497,_0x57e863=_0x35903d[_0xbc2a04('0x0')](_0xbc2a04('0x2'),attributes,{'tableName':_0xbc2a04('0x3'),'paranoid':![],'indexes':[{'fields':[_0xbc2a04('0x1')]}],'timestamps':!![]});return _0x57e863;}; \ No newline at end of file +const a710_0x4543=['report_call','define','VoiceCallReport','./voiceCallReport.attributes','exports'];(function(_0x57ee3d,_0x45431c){const _0x51d3fd=function(_0x461877){while(--_0x461877){_0x57ee3d['push'](_0x57ee3d['shift']());}};_0x51d3fd(++_0x45431c);}(a710_0x4543,0xb6));const a710_0x51d3=function(_0x57ee3d,_0x45431c){_0x57ee3d=_0x57ee3d-0x0;let _0x51d3fd=a710_0x4543[_0x57ee3d];return _0x51d3fd;};const _0x8bd665=a710_0x51d3;'use strict';const attributes=require(_0x8bd665('0x1'));module[_0x8bd665('0x2')]=function(_0x461877){const _0x4a35e1=_0x8bd665,_0x5a7fbd=_0x461877[_0x4a35e1('0x4')](_0x4a35e1('0x0'),attributes,{'tableName':_0x4a35e1('0x3'),'paranoid':![],'indexes':[{'fields':['uniqueid']}],'timestamps':!![]});return _0x5a7fbd;}; \ No newline at end of file diff --git a/server/api/voiceCallReport/voiceCallReport.rpc.js b/server/api/voiceCallReport/voiceCallReport.rpc.js index d7b3a44..dbeb2eb 100644 --- a/server/api/voiceCallReport/voiceCallReport.rpc.js +++ b/server/api/voiceCallReport/voiceCallReport.rpc.js @@ -1 +1 @@ -const a711_0x33f7=['stringify','UpdateVoiceCallReport','attributes','where','limit','model','findAll','CreateVoiceCallReport','include','options','raw','../../mysqldb','debug','body','lodash','VoiceCallReport','error','rpc','info','map','then','message','catch','update','GetVoiceCallReport'];(function(_0x4890bd,_0x33f754){const _0x3b5655=function(_0x4ca99e){while(--_0x4ca99e){_0x4890bd['push'](_0x4890bd['shift']());}};_0x3b5655(++_0x33f754);}(a711_0x33f7,0xf4));const a711_0x3b56=function(_0x4890bd,_0x33f754){_0x4890bd=_0x4890bd-0x0;let _0x3b5655=a711_0x33f7[_0x4890bd];return _0x3b5655;};const _0x159a22=a711_0x3b56;'use strict';const _=require(_0x159a22('0x14')),db=require(_0x159a22('0x11'))['db'],logger=require('../../config/logger')(_0x159a22('0x17'));exports[_0x159a22('0x5')]=function(_0x4ca99e){const _0x4e9296=this;return new Promise(function(_0x3c645c,_0x511b76){const _0x5da977=a711_0x3b56;return db['VoiceCallReport'][_0x5da977('0xc')]({'raw':_0x4ca99e['options']?_0x4ca99e['options']['raw']===undefined?!![]:![]:!![],'where':_0x4ca99e[_0x5da977('0xf')]?_0x4ca99e[_0x5da977('0xf')][_0x5da977('0x9')]||null:null,'attributes':_0x4ca99e[_0x5da977('0xf')]?_0x4ca99e['options'][_0x5da977('0x8')]||null:null,'limit':_0x4ca99e[_0x5da977('0xf')]?_0x4ca99e['options']['limit']||null:null,'include':_0x4ca99e[_0x5da977('0xf')]?_0x4ca99e[_0x5da977('0xf')][_0x5da977('0xe')]?_[_0x5da977('0x0')](_0x4ca99e['options']['include'],function(_0xdfd97e){const _0x5d24b6=_0x5da977;return{'model':db[_0xdfd97e[_0x5d24b6('0xb')]],'as':_0xdfd97e['as'],'attributes':_0xdfd97e[_0x5d24b6('0x8')],'include':_0xdfd97e[_0x5d24b6('0xe')]?_[_0x5d24b6('0x0')](_0xdfd97e[_0x5d24b6('0xe')],function(_0x2aa175){const _0x51d647=_0x5d24b6;return{'model':db[_0x2aa175[_0x51d647('0xb')]],'as':_0x2aa175['as'],'attributes':_0x2aa175['attributes'],'include':_0x2aa175[_0x51d647('0xe')]?_[_0x51d647('0x0')](_0x2aa175[_0x51d647('0xe')],function(_0x1ade62){return{'model':db[_0x1ade62['model']],'as':_0x1ade62['as'],'attributes':_0x1ade62['attributes']};}):[]};}):[]};}):[]:[]})[_0x5da977('0x1')](function(_0x15a32f){const _0x3e9294=_0x5da977;logger[_0x3e9294('0x18')]('GetVoiceCallReport',_0x4ca99e),logger[_0x3e9294('0x12')]('GetVoiceCallReport',_0x4ca99e,JSON[_0x3e9294('0x6')](_0x15a32f)),_0x3c645c(_0x15a32f);})[_0x5da977('0x3')](function(_0x11df3c){const _0x361c0f=_0x5da977;logger[_0x361c0f('0x16')](_0x361c0f('0x5'),_0x11df3c[_0x361c0f('0x2')],_0x4ca99e),_0x511b76(_0x4e9296['error'](0x1f4,_0x11df3c[_0x361c0f('0x2')]));});});},exports['CreateVoiceCallReport']=function(_0x452a5d){const _0x45b43a=this;return new Promise(function(_0x57cfe3,_0x57d830){const _0x434992=a711_0x3b56;return db[_0x434992('0x15')]['create'](_0x452a5d[_0x434992('0x13')],{'raw':_0x452a5d[_0x434992('0xf')]?_0x452a5d[_0x434992('0xf')][_0x434992('0x10')]===undefined?!![]:![]:!![]})['then'](function(_0x543427){const _0x31041e=_0x434992;logger[_0x31041e('0x18')](_0x31041e('0xd'),_0x452a5d),logger['debug'](_0x31041e('0xd'),_0x452a5d,JSON[_0x31041e('0x6')](_0x543427)),_0x57cfe3(_0x543427);})[_0x434992('0x3')](function(_0x4cc3d2){const _0x484677=_0x434992;logger[_0x484677('0x16')](_0x484677('0xd'),_0x4cc3d2[_0x484677('0x2')],_0x452a5d),_0x57d830(_0x45b43a[_0x484677('0x16')](0x1f4,_0x4cc3d2[_0x484677('0x2')]));});});},exports[_0x159a22('0x7')]=function(_0xffd5b4){const _0x2cdfb7=this;return new Promise(function(_0x512138,_0x57d70a){const _0x52f623=a711_0x3b56;return db['VoiceCallReport'][_0x52f623('0x4')](_0xffd5b4[_0x52f623('0x13')],{'raw':_0xffd5b4[_0x52f623('0xf')]?_0xffd5b4['options'][_0x52f623('0x10')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0xffd5b4[_0x52f623('0xf')]?_0xffd5b4[_0x52f623('0xf')][_0x52f623('0x9')]||null:null,'attributes':_0xffd5b4[_0x52f623('0xf')]?_0xffd5b4[_0x52f623('0xf')][_0x52f623('0x8')]||null:null,'limit':_0xffd5b4['options']?_0xffd5b4[_0x52f623('0xf')][_0x52f623('0xa')]||null:null})[_0x52f623('0x1')](function(_0x484ac0){const _0x3f97aa=_0x52f623;logger['info'](_0x3f97aa('0x7'),_0xffd5b4),logger[_0x3f97aa('0x12')](_0x3f97aa('0x7'),_0xffd5b4,JSON[_0x3f97aa('0x6')](_0x484ac0)),_0x512138(_0x484ac0);})['catch'](function(_0x312d99){const _0x252f43=_0x52f623;logger[_0x252f43('0x16')](_0x252f43('0x7'),_0x312d99[_0x252f43('0x2')],_0xffd5b4),_0x57d70a(_0x2cdfb7['error'](0x1f4,_0x312d99[_0x252f43('0x2')]));});});}; \ No newline at end of file +const a711_0x379c=['limit','GetVoiceCallReport','UpdateVoiceCallReport','debug','then','include','catch','CreateVoiceCallReport','../../config/logger','findAll','update','stringify','raw','../../mysqldb','map','create','info','options','lodash','message','where','rpc','body','model','attributes','error','VoiceCallReport'];(function(_0x2e6218,_0x379c42){const _0x3226fe=function(_0x10767e){while(--_0x10767e){_0x2e6218['push'](_0x2e6218['shift']());}};_0x3226fe(++_0x379c42);}(a711_0x379c,0xc7));const a711_0x3226=function(_0x2e6218,_0x379c42){_0x2e6218=_0x2e6218-0x0;let _0x3226fe=a711_0x379c[_0x2e6218];return _0x3226fe;};const _0x29d281=a711_0x3226;'use strict';const _=require(_0x29d281('0x8')),db=require(_0x29d281('0x3'))['db'],logger=require(_0x29d281('0x19'))(_0x29d281('0xb'));exports[_0x29d281('0x12')]=function(_0x10767e){const _0x5f1204=this;return new Promise(function(_0x4394ea,_0x59dfbb){const _0x1db628=a711_0x3226;return db['VoiceCallReport'][_0x1db628('0x1a')]({'raw':_0x10767e[_0x1db628('0x7')]?_0x10767e[_0x1db628('0x7')]['raw']===undefined?!![]:![]:!![],'where':_0x10767e[_0x1db628('0x7')]?_0x10767e[_0x1db628('0x7')][_0x1db628('0xa')]||null:null,'attributes':_0x10767e[_0x1db628('0x7')]?_0x10767e[_0x1db628('0x7')]['attributes']||null:null,'limit':_0x10767e[_0x1db628('0x7')]?_0x10767e[_0x1db628('0x7')][_0x1db628('0x11')]||null:null,'include':_0x10767e[_0x1db628('0x7')]?_0x10767e[_0x1db628('0x7')]['include']?_[_0x1db628('0x4')](_0x10767e[_0x1db628('0x7')]['include'],function(_0x5b1995){const _0x5ee89b=_0x1db628;return{'model':db[_0x5b1995['model']],'as':_0x5b1995['as'],'attributes':_0x5b1995[_0x5ee89b('0xe')],'include':_0x5b1995[_0x5ee89b('0x16')]?_['map'](_0x5b1995[_0x5ee89b('0x16')],function(_0x499356){const _0x2789e0=_0x5ee89b;return{'model':db[_0x499356[_0x2789e0('0xd')]],'as':_0x499356['as'],'attributes':_0x499356[_0x2789e0('0xe')],'include':_0x499356[_0x2789e0('0x16')]?_['map'](_0x499356[_0x2789e0('0x16')],function(_0xe1797c){const _0xa38bf1=_0x2789e0;return{'model':db[_0xe1797c[_0xa38bf1('0xd')]],'as':_0xe1797c['as'],'attributes':_0xe1797c[_0xa38bf1('0xe')]};}):[]};}):[]};}):[]:[]})[_0x1db628('0x15')](function(_0x3cb196){const _0x5a76c3=_0x1db628;logger['info'](_0x5a76c3('0x12'),_0x10767e),logger[_0x5a76c3('0x14')](_0x5a76c3('0x12'),_0x10767e,JSON[_0x5a76c3('0x1')](_0x3cb196)),_0x4394ea(_0x3cb196);})[_0x1db628('0x17')](function(_0x15b16c){const _0x3b3483=_0x1db628;logger[_0x3b3483('0xf')]('GetVoiceCallReport',_0x15b16c[_0x3b3483('0x9')],_0x10767e),_0x59dfbb(_0x5f1204[_0x3b3483('0xf')](0x1f4,_0x15b16c[_0x3b3483('0x9')]));});});},exports[_0x29d281('0x18')]=function(_0x1d7106){const _0x267df4=this;return new Promise(function(_0x1a3cdf,_0x115f39){const _0x4ab198=a711_0x3226;return db[_0x4ab198('0x10')][_0x4ab198('0x5')](_0x1d7106['body'],{'raw':_0x1d7106[_0x4ab198('0x7')]?_0x1d7106['options'][_0x4ab198('0x2')]===undefined?!![]:![]:!![]})[_0x4ab198('0x15')](function(_0xb9567c){const _0x41422d=_0x4ab198;logger[_0x41422d('0x6')](_0x41422d('0x18'),_0x1d7106),logger[_0x41422d('0x14')]('CreateVoiceCallReport',_0x1d7106,JSON[_0x41422d('0x1')](_0xb9567c)),_0x1a3cdf(_0xb9567c);})[_0x4ab198('0x17')](function(_0x457985){const _0x57d89f=_0x4ab198;logger[_0x57d89f('0xf')](_0x57d89f('0x18'),_0x457985[_0x57d89f('0x9')],_0x1d7106),_0x115f39(_0x267df4['error'](0x1f4,_0x457985[_0x57d89f('0x9')]));});});},exports['UpdateVoiceCallReport']=function(_0x4b4ac2){const _0x58ebe6=this;return new Promise(function(_0x5af56f,_0x38ea6a){const _0x34b06e=a711_0x3226;return db[_0x34b06e('0x10')][_0x34b06e('0x0')](_0x4b4ac2[_0x34b06e('0xc')],{'raw':_0x4b4ac2[_0x34b06e('0x7')]?_0x4b4ac2[_0x34b06e('0x7')][_0x34b06e('0x2')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x4b4ac2[_0x34b06e('0x7')]?_0x4b4ac2[_0x34b06e('0x7')][_0x34b06e('0xa')]||null:null,'attributes':_0x4b4ac2[_0x34b06e('0x7')]?_0x4b4ac2[_0x34b06e('0x7')][_0x34b06e('0xe')]||null:null,'limit':_0x4b4ac2[_0x34b06e('0x7')]?_0x4b4ac2[_0x34b06e('0x7')][_0x34b06e('0x11')]||null:null})[_0x34b06e('0x15')](function(_0x4581c2){const _0x4f3272=_0x34b06e;logger[_0x4f3272('0x6')](_0x4f3272('0x13'),_0x4b4ac2),logger['debug'](_0x4f3272('0x13'),_0x4b4ac2,JSON[_0x4f3272('0x1')](_0x4581c2)),_0x5af56f(_0x4581c2);})[_0x34b06e('0x17')](function(_0x5cc0ba){const _0x146cb2=_0x34b06e;logger[_0x146cb2('0xf')](_0x146cb2('0x13'),_0x5cc0ba['message'],_0x4b4ac2),_0x38ea6a(_0x58ebe6['error'](0x1f4,_0x5cc0ba['message']));});});}; \ No newline at end of file diff --git a/server/api/voiceChanSpy/index.js b/server/api/voiceChanSpy/index.js index 990e400..0f63e66 100644 --- a/server/api/voiceChanSpy/index.js +++ b/server/api/voiceChanSpy/index.js @@ -1 +1 @@ -const a712_0x559a=['./voiceChanSpy.controller','get','/:id','destroy','isAuthenticated','express','index','exports','create','put'];(function(_0x33abd6,_0x559a54){const _0x1eebe6=function(_0x3545a6){while(--_0x3545a6){_0x33abd6['push'](_0x33abd6['shift']());}};_0x1eebe6(++_0x559a54);}(a712_0x559a,0x9c));const a712_0x1eeb=function(_0x33abd6,_0x559a54){_0x33abd6=_0x33abd6-0x0;let _0x1eebe6=a712_0x559a[_0x33abd6];return _0x1eebe6;};const _0x40ace2=a712_0x1eeb;'use strict';const express=require(_0x40ace2('0x9')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x40ace2('0x4'));router[_0x40ace2('0x5')]('/',auth[_0x40ace2('0x8')](),controller[_0x40ace2('0x0')]),router[_0x40ace2('0x5')]('/:id',auth[_0x40ace2('0x8')](),controller['show']),router['post']('/',auth[_0x40ace2('0x8')](),controller[_0x40ace2('0x2')]),router[_0x40ace2('0x3')](_0x40ace2('0x6'),auth[_0x40ace2('0x8')](),controller['update']),router['delete'](_0x40ace2('0x6'),auth['isAuthenticated'](),controller[_0x40ace2('0x7')]),module[_0x40ace2('0x1')]=router; \ No newline at end of file +const a712_0x137c=['show','create','destroy','get','update','delete','Router','./voiceChanSpy.controller','express','isAuthenticated','/:id','exports','post'];(function(_0x5b4d93,_0x137cfa){const _0x15b6b4=function(_0x3ea9a2){while(--_0x3ea9a2){_0x5b4d93['push'](_0x5b4d93['shift']());}};_0x15b6b4(++_0x137cfa);}(a712_0x137c,0xc3));const a712_0x15b6=function(_0x5b4d93,_0x137cfa){_0x5b4d93=_0x5b4d93-0x0;let _0x15b6b4=a712_0x137c[_0x5b4d93];return _0x15b6b4;};const _0x2e6311=a712_0x15b6;'use strict';const express=require(_0x2e6311('0x8')),router=express[_0x2e6311('0x6')](),auth=require('../../components/auth/service'),controller=require(_0x2e6311('0x7'));router[_0x2e6311('0x3')]('/',auth[_0x2e6311('0x9')](),controller['index']),router['get']('/:id',auth[_0x2e6311('0x9')](),controller[_0x2e6311('0x0')]),router[_0x2e6311('0xc')]('/',auth[_0x2e6311('0x9')](),controller[_0x2e6311('0x1')]),router['put'](_0x2e6311('0xa'),auth[_0x2e6311('0x9')](),controller[_0x2e6311('0x4')]),router[_0x2e6311('0x5')](_0x2e6311('0xa'),auth['isAuthenticated'](),controller[_0x2e6311('0x2')]),module[_0x2e6311('0xb')]=router; \ No newline at end of file diff --git a/server/api/voiceChanSpy/voiceChanSpy.attributes.js b/server/api/voiceChanSpy/voiceChanSpy.attributes.js index 56dc96e..a9f0dcb 100644 --- a/server/api/voiceChanSpy/voiceChanSpy.attributes.js +++ b/server/api/voiceChanSpy/voiceChanSpy.attributes.js @@ -1 +1 @@ -const a713_0x19ee=['name','options','BOOLEAN','getDataValue','join','sequelize','STRING'];(function(_0x1de483,_0x19ee95){const _0x4f674f=function(_0x5636f5){while(--_0x5636f5){_0x1de483['push'](_0x1de483['shift']());}};_0x4f674f(++_0x19ee95);}(a713_0x19ee,0x198));const a713_0x4f67=function(_0x1de483,_0x19ee95){_0x1de483=_0x1de483-0x0;let _0x4f674f=a713_0x19ee[_0x1de483];return _0x4f674f;};const _0xb5b659=a713_0x4f67;'use strict';const Sequelize=require(_0xb5b659('0x3'));module['exports']={'name':{'type':Sequelize[_0xb5b659('0x4')]},'prefix':{'type':Sequelize[_0xb5b659('0x4')],'unique':_0xb5b659('0x5'),'allowNull':![]},'options':{'type':Sequelize[_0xb5b659('0x4')],'set':function(_0x5636f5){const _0x5cf6d2=_0xb5b659;this['setDataValue'](_0x5cf6d2('0x6'),_0x5636f5?_0x5636f5[_0x5cf6d2('0x2')](''):[]);},'get':function(){const _0x3f1234=_0xb5b659;return this['getDataValue']('options')?this[_0x3f1234('0x1')](_0x3f1234('0x6'))['split'](''):[];}},'auth':{'type':Sequelize[_0xb5b659('0x0')],'defaultValue':![]},'password':{'type':Sequelize[_0xb5b659('0x4')]},'record':{'type':Sequelize[_0xb5b659('0x0')],'defaultValue':![]},'recordingFormat':{'type':Sequelize[_0xb5b659('0x4')]},'description':{'type':Sequelize[_0xb5b659('0x4')]}}; \ No newline at end of file +const a713_0x1281=['STRING','split','options','setDataValue','name','BOOLEAN','exports'];(function(_0x1a4519,_0x12813f){const _0x53de87=function(_0x52941a){while(--_0x52941a){_0x1a4519['push'](_0x1a4519['shift']());}};_0x53de87(++_0x12813f);}(a713_0x1281,0x7c));const a713_0x53de=function(_0x1a4519,_0x12813f){_0x1a4519=_0x1a4519-0x0;let _0x53de87=a713_0x1281[_0x1a4519];return _0x53de87;};const _0x140c7e=a713_0x53de;'use strict';const Sequelize=require('sequelize');module[_0x140c7e('0x1')]={'name':{'type':Sequelize[_0x140c7e('0x2')]},'prefix':{'type':Sequelize[_0x140c7e('0x2')],'unique':_0x140c7e('0x6'),'allowNull':![]},'options':{'type':Sequelize['STRING'],'set':function(_0x52941a){const _0x48e869=_0x140c7e;this[_0x48e869('0x5')](_0x48e869('0x4'),_0x52941a?_0x52941a['join'](''):[]);},'get':function(){const _0x50cf55=_0x140c7e;return this['getDataValue'](_0x50cf55('0x4'))?this['getDataValue'](_0x50cf55('0x4'))[_0x50cf55('0x3')](''):[];}},'auth':{'type':Sequelize[_0x140c7e('0x0')],'defaultValue':![]},'password':{'type':Sequelize['STRING']},'record':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'recordingFormat':{'type':Sequelize[_0x140c7e('0x2')]},'description':{'type':Sequelize[_0x140c7e('0x2')]}}; \ No newline at end of file diff --git a/server/api/voiceChanSpy/voiceChanSpy.controller.js b/server/api/voiceChanSpy/voiceChanSpy.controller.js index d50b9b2..1042222 100644 --- a/server/api/voiceChanSpy/voiceChanSpy.controller.js +++ b/server/api/voiceChanSpy/voiceChanSpy.controller.js @@ -1 +1 @@ -const a714_0x21ea=['send','lodash','name','update','fieldName','get','destroy','end','Unable\x20to\x20retrieve\x20the\x20current\x20user','status','UserProfileResource','body','../../components/parsers/qs','set','catch','userProfileId','like','attributes','count','json','filters','params','where','includeAll','index','nolimit','undefined','key','api','length','findAll','include','filter','options','model','then','order','offset','ChanSpies','type','autoAssociation','limit','findOne','merge','fields','error','VIRTUAL','query','sort','../../config/logger','VoiceChanSpy','keys','../../mysqldb','create','sequelize','role','intersection','user'];(function(_0x302cbe,_0x21eab6){const _0x30e5ab=function(_0x5e17df){while(--_0x5e17df){_0x302cbe['push'](_0x302cbe['shift']());}};_0x30e5ab(++_0x21eab6);}(a714_0x21ea,0x10c));const a714_0x30e5=function(_0x302cbe,_0x21eab6){_0x302cbe=_0x302cbe-0x0;let _0x30e5ab=a714_0x21ea[_0x302cbe];return _0x30e5ab;};const _0x1d2bbd=a714_0x30e5;'use strict';const _=require(_0x1d2bbd('0x17')),qs=require(_0x1d2bbd('0x22')),logger=require(_0x1d2bbd('0xd'))(_0x1d2bbd('0x32')),db=require(_0x1d2bbd('0x10'))['db'],{Op}=require(_0x1d2bbd('0x12'));function respondWithResult(_0x5e17df,_0x14f15f){return _0x14f15f=_0x14f15f||0xc8,function(_0x8256f){const _0x29a1aa=a714_0x30e5;if(_0x8256f)return _0x5e17df[_0x29a1aa('0x1f')](_0x14f15f)[_0x29a1aa('0x29')](_0x8256f);};}function respondWithFilteredResult(_0xbf8836,_0x3a023e){return function(_0x147312){const _0x493408=a714_0x30e5;if(_0x147312){const _0x446f44=_0x147312['count'],_0x1a4d7b=_0x3a023e[_0x493408('0x1')];let _0x339bdd=_0x3a023e[_0x493408('0x1')]+_0x3a023e[_0x493408('0x5')],_0x2e9406;return _0x339bdd>=_0x446f44?(_0x339bdd=_0x446f44,_0x2e9406=0xc8):_0x2e9406=0xce,_0xbf8836['status'](_0x2e9406),_0xbf8836[_0x493408('0x23')]('Content-Range',_0x1a4d7b+'-'+_0x339bdd+'/'+_0x446f44)[_0x493408('0x29')](_0x147312);}return null;};}function saveUpdates(_0x53faf0){return function(_0x285c39){const _0x3eeab4=a714_0x30e5;if(_0x285c39)return _0x285c39[_0x3eeab4('0x19')](_0x53faf0)[_0x3eeab4('0x39')](function(_0x2db971){return _0x2db971;});return null;};}function removeEntity(_0x5c3725){return function(_0x3f040f){const _0x369f13=a714_0x30e5;if(_0x3f040f)return _0x3f040f['destroy']()[_0x369f13('0x39')](function(){const _0xe71b9f=_0x369f13,_0x1eea82=_0x3f040f['get']({'plain':!![]}),_0x13b2b5=_0xe71b9f('0x2');return db[_0xe71b9f('0x20')]['destroy']({'where':{'type':_0x13b2b5,'resourceId':_0x1eea82['id']}})[_0xe71b9f('0x39')](function(){return _0x3f040f;});})[_0x369f13('0x39')](function(){const _0x47e714=_0x369f13;_0x5c3725['status'](0xcc)[_0x47e714('0x1d')]();});};}function handleEntityNotFound(_0xe94ca6){return function(_0x31950e){return!_0x31950e&&_0xe94ca6['sendStatus'](0x194),_0x31950e;};}function handleError(_0x10bd90,_0x392b2c){return _0x392b2c=_0x392b2c||0x1f4,function(_0x3580c6){const _0x50e0fe=a714_0x30e5;logger[_0x50e0fe('0x9')](_0x3580c6['stack']),_0x3580c6['name']&&delete _0x3580c6[_0x50e0fe('0x18')],_0x10bd90[_0x50e0fe('0x1f')](_0x392b2c)[_0x50e0fe('0x16')](_0x3580c6);};}exports[_0x1d2bbd('0x2e')]=function(_0x7e978e,_0x5ade4f){const _0x48550e=_0x1d2bbd;let _0x5360cf={};const _0x4f9501={},_0x24f914={'count':0x0,'rows':[]},_0xb89072=_['map'](db['VoiceChanSpy']['rawAttributes'],function(_0x3ebf7f){const _0x418877=a714_0x30e5;return{'name':_0x3ebf7f[_0x418877('0x1a')],'type':_0x3ebf7f[_0x418877('0x3')][_0x418877('0x31')]};});_0x4f9501[_0x48550e('0x38')]=_['map'](_0xb89072,'name'),_0x4f9501[_0x48550e('0xb')]=_[_0x48550e('0xf')](_0x7e978e[_0x48550e('0xb')]),_0x4f9501[_0x48550e('0x2a')]=_['intersection'](_0x4f9501['model'],_0x4f9501['query']),_0x5360cf['attributes']=_[_0x48550e('0x14')](_0x4f9501[_0x48550e('0x38')],qs[_0x48550e('0x8')](_0x7e978e[_0x48550e('0xb')][_0x48550e('0x8')])),_0x5360cf[_0x48550e('0x27')]=_0x5360cf[_0x48550e('0x27')][_0x48550e('0x33')]?_0x5360cf['attributes']:_0x4f9501[_0x48550e('0x38')];typeof _0x7e978e['query'][_0x48550e('0x2f')]===_0x48550e('0x30')&&(_0x5360cf['limit']=qs[_0x48550e('0x5')](_0x7e978e[_0x48550e('0xb')][_0x48550e('0x5')]),_0x5360cf[_0x48550e('0x1')]=qs['offset'](_0x7e978e[_0x48550e('0xb')]['offset']));_0x5360cf[_0x48550e('0x0')]=qs[_0x48550e('0xc')](_0x7e978e[_0x48550e('0xb')][_0x48550e('0xc')]),_0x5360cf['where']=qs[_0x48550e('0x2a')](_['pick'](_0x7e978e['query'],_0x4f9501[_0x48550e('0x2a')]),_0xb89072);_0x7e978e[_0x48550e('0xb')]['filter']&&(_0x5360cf[_0x48550e('0x2c')]=_['merge'](_0x5360cf[_0x48550e('0x2c')],{[Op['or']]:_['map'](_0xb89072,function(_0x3d40f5){const _0x406720=_0x48550e;if(_0x3d40f5[_0x406720('0x3')]!==_0x406720('0xa')){const _0x4250ce={};return _0x4250ce[_0x3d40f5[_0x406720('0x18')]]={[Op[_0x406720('0x26')]]:'%'+_0x7e978e[_0x406720('0xb')][_0x406720('0x36')]+'%'},_0x4250ce;}})}));_0x5360cf=_[_0x48550e('0x7')]({},_0x5360cf,_0x7e978e[_0x48550e('0x37')]);const _0x3896a3={'where':_0x5360cf[_0x48550e('0x2c')]};return db['VoiceChanSpy'][_0x48550e('0x28')](_0x3896a3)[_0x48550e('0x39')](function(_0x2e795e){const _0x7028c6=_0x48550e;return _0x24f914['count']=_0x2e795e,_0x7e978e['query'][_0x7028c6('0x2d')]&&(_0x5360cf['include']=[{'all':!![]}]),db[_0x7028c6('0xe')][_0x7028c6('0x34')](_0x5360cf);})[_0x48550e('0x39')](function(_0x231fed){return _0x24f914['rows']=_0x231fed,_0x24f914;})[_0x48550e('0x39')](respondWithFilteredResult(_0x5ade4f,_0x5360cf))[_0x48550e('0x24')](handleError(_0x5ade4f,null));},exports['show']=function(_0x52c0bc,_0x2c782d){const _0x2baaee=_0x1d2bbd;let _0x1dee68={'raw':![],'where':{'id':_0x52c0bc[_0x2baaee('0x2b')]['id']}};const _0x438737={};return _0x438737[_0x2baaee('0x38')]=_[_0x2baaee('0xf')](db[_0x2baaee('0xe')]['rawAttributes']),_0x438737['query']=_[_0x2baaee('0xf')](_0x52c0bc['query']),_0x438737['filters']=_[_0x2baaee('0x14')](_0x438737[_0x2baaee('0x38')],_0x438737[_0x2baaee('0xb')]),_0x1dee68[_0x2baaee('0x27')]=_[_0x2baaee('0x14')](_0x438737[_0x2baaee('0x38')],qs['fields'](_0x52c0bc['query'][_0x2baaee('0x8')])),_0x1dee68['attributes']=_0x1dee68['attributes']['length']?_0x1dee68['attributes']:_0x438737['model'],_0x52c0bc[_0x2baaee('0xb')][_0x2baaee('0x2d')]&&(_0x1dee68[_0x2baaee('0x35')]=[{'all':!![]}]),_0x1dee68=_['merge']({},_0x1dee68,_0x52c0bc[_0x2baaee('0x37')]),db[_0x2baaee('0xe')][_0x2baaee('0x6')](_0x1dee68)[_0x2baaee('0x39')](handleEntityNotFound(_0x2c782d,null))[_0x2baaee('0x39')](respondWithResult(_0x2c782d,null))[_0x2baaee('0x24')](handleError(_0x2c782d,null));},exports[_0x1d2bbd('0x11')]=function(_0x446ffa,_0x41c2e9){const _0x263b1a=_0x1d2bbd;return db['VoiceChanSpy'][_0x263b1a('0x11')](_0x446ffa['body'],{})['then'](function(_0x4fada5){const _0x13f637=_0x263b1a,_0x41ac5c=_0x446ffa['user'][_0x13f637('0x1b')]({'plain':!![]});if(!_0x41ac5c)throw new Error(_0x13f637('0x1e'));if(_0x41ac5c[_0x13f637('0x13')]===_0x13f637('0x15')){const _0x3994ce=_0x4fada5[_0x13f637('0x1b')]({'plain':!![]}),_0x4eeca9=_0x13f637('0x2');return db['UserProfileSection'][_0x13f637('0x6')]({'where':{'name':_0x4eeca9,'userProfileId':_0x41ac5c[_0x13f637('0x25')]},'raw':!![]})['then'](function(_0x5967c9){const _0x1a45aa=_0x13f637;return _0x5967c9&&_0x5967c9[_0x1a45aa('0x4')]===0x0?db[_0x1a45aa('0x20')][_0x1a45aa('0x11')]({'name':_0x3994ce[_0x1a45aa('0x18')],'resourceId':_0x3994ce['id'],'type':_0x5967c9[_0x1a45aa('0x18')],'sectionId':_0x5967c9['id']},{})['then'](function(){return _0x4fada5;}):_0x4fada5;})['catch'](function(_0x3f7c65){const _0x560547=_0x13f637;logger[_0x560547('0x9')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x3f7c65);throw _0x3f7c65;});}return _0x4fada5;})[_0x263b1a('0x39')](respondWithResult(_0x41c2e9,0xc9))[_0x263b1a('0x24')](handleError(_0x41c2e9,null));},exports[_0x1d2bbd('0x19')]=function(_0xb9193f,_0x235d43){const _0x1a696b=_0x1d2bbd;return _0xb9193f[_0x1a696b('0x21')]['id']&&delete _0xb9193f[_0x1a696b('0x21')]['id'],db['VoiceChanSpy'][_0x1a696b('0x6')]({'where':{'id':_0xb9193f[_0x1a696b('0x2b')]['id']}})[_0x1a696b('0x39')](handleEntityNotFound(_0x235d43,null))[_0x1a696b('0x39')](saveUpdates(_0xb9193f['body'],null))[_0x1a696b('0x39')](respondWithResult(_0x235d43,null))['catch'](handleError(_0x235d43,null));},exports[_0x1d2bbd('0x1c')]=function(_0x421eff,_0x7d0f7d){const _0x263235=_0x1d2bbd;return db[_0x263235('0xe')]['findOne']({'where':{'id':_0x421eff['params']['id']}})[_0x263235('0x39')](handleEntityNotFound(_0x7d0f7d,null))[_0x263235('0x39')](removeEntity(_0x7d0f7d,null))[_0x263235('0x24')](handleError(_0x7d0f7d,null));}; \ No newline at end of file +const a714_0x3853=['sequelize','findOne','VoiceChanSpy','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','count','fields','pick','then','attributes','UserProfileResource','undefined','nolimit','keys','includeAll','error','type','../../components/parsers/qs','catch','fieldName','user','status','body','intersection','show','merge','include','../../mysqldb','where','filter','autoAssociation','end','destroy','stack','json','like','ChanSpies','UserProfileSection','rows','update','api','get','rawAttributes','userProfileId','offset','sort','VIRTUAL','send','length','name','options','create','map','sendStatus','index','model','limit','query','role','params','filters','order'];(function(_0x5bbdc2,_0x3853a6){const _0x3273c4=function(_0x27ad46){while(--_0x27ad46){_0x5bbdc2['push'](_0x5bbdc2['shift']());}};_0x3273c4(++_0x3853a6);}(a714_0x3853,0x15f));const a714_0x3273=function(_0x5bbdc2,_0x3853a6){_0x5bbdc2=_0x5bbdc2-0x0;let _0x3273c4=a714_0x3853[_0x5bbdc2];return _0x3273c4;};const _0x345274=a714_0x3273;'use strict';const _=require('lodash'),qs=require(_0x345274('0x1f')),logger=require('../../config/logger')(_0x345274('0x36')),db=require(_0x345274('0x29'))['db'],{Op}=require(_0x345274('0xf'));function respondWithResult(_0x27ad46,_0x30d4d5){return _0x30d4d5=_0x30d4d5||0xc8,function(_0x52274b){const _0x33c238=a714_0x3273;if(_0x52274b)return _0x27ad46[_0x33c238('0x23')](_0x30d4d5)[_0x33c238('0x30')](_0x52274b);};}function respondWithFilteredResult(_0x33bc9d,_0x5ecee9){return function(_0x369e13){const _0x2f69f2=a714_0x3273;if(_0x369e13){const _0x56bd1a=_0x369e13[_0x2f69f2('0x13')],_0x1e1b82=_0x5ecee9['offset'];let _0xa1e9e3=_0x5ecee9[_0x2f69f2('0x3a')]+_0x5ecee9[_0x2f69f2('0x9')],_0x2dbcdd;return _0xa1e9e3>=_0x56bd1a?(_0xa1e9e3=_0x56bd1a,_0x2dbcdd=0xc8):_0x2dbcdd=0xce,_0x33bc9d[_0x2f69f2('0x23')](_0x2dbcdd),_0x33bc9d['set']('Content-Range',_0x1e1b82+'-'+_0xa1e9e3+'/'+_0x56bd1a)[_0x2f69f2('0x30')](_0x369e13);}return null;};}function saveUpdates(_0x3577f6){return function(_0x10375a){const _0x3322c5=a714_0x3273;if(_0x10375a)return _0x10375a[_0x3322c5('0x35')](_0x3577f6)['then'](function(_0x507081){return _0x507081;});return null;};}function removeEntity(_0x314b7e){return function(_0x3c2b4d){if(_0x3c2b4d)return _0x3c2b4d['destroy']()['then'](function(){const _0x490eb6=a714_0x3273,_0x426ab6=_0x3c2b4d[_0x490eb6('0x37')]({'plain':!![]}),_0x18b057=_0x490eb6('0x32');return db['UserProfileResource']['destroy']({'where':{'type':_0x18b057,'resourceId':_0x426ab6['id']}})[_0x490eb6('0x16')](function(){return _0x3c2b4d;});})['then'](function(){const _0x57d5d1=a714_0x3273;_0x314b7e[_0x57d5d1('0x23')](0xcc)[_0x57d5d1('0x2d')]();});};}function handleEntityNotFound(_0x19775e){return function(_0xf8a12f){const _0x5b41ad=a714_0x3273;return!_0xf8a12f&&_0x19775e[_0x5b41ad('0x6')](0x194),_0xf8a12f;};}function handleError(_0x1a8662,_0x506558){return _0x506558=_0x506558||0x1f4,function(_0x198762){const _0x24fd1b=a714_0x3273;logger[_0x24fd1b('0x1d')](_0x198762[_0x24fd1b('0x2f')]),_0x198762[_0x24fd1b('0x2')]&&delete _0x198762[_0x24fd1b('0x2')],_0x1a8662[_0x24fd1b('0x23')](_0x506558)[_0x24fd1b('0x0')](_0x198762);};}exports[_0x345274('0x7')]=function(_0x445a91,_0x2d6cf0){const _0x14b619=_0x345274;let _0x399de8={};const _0x348f0d={},_0x28bc42={'count':0x0,'rows':[]},_0x9c240e=_[_0x14b619('0x5')](db['VoiceChanSpy']['rawAttributes'],function(_0x5e63be){const _0x22f868=_0x14b619;return{'name':_0x5e63be[_0x22f868('0x21')],'type':_0x5e63be[_0x22f868('0x1e')]['key']};});_0x348f0d['model']=_[_0x14b619('0x5')](_0x9c240e,'name'),_0x348f0d[_0x14b619('0xa')]=_[_0x14b619('0x1b')](_0x445a91[_0x14b619('0xa')]),_0x348f0d[_0x14b619('0xd')]=_[_0x14b619('0x25')](_0x348f0d['model'],_0x348f0d[_0x14b619('0xa')]),_0x399de8[_0x14b619('0x17')]=_[_0x14b619('0x25')](_0x348f0d[_0x14b619('0x8')],qs[_0x14b619('0x14')](_0x445a91['query']['fields'])),_0x399de8[_0x14b619('0x17')]=_0x399de8[_0x14b619('0x17')][_0x14b619('0x1')]?_0x399de8[_0x14b619('0x17')]:_0x348f0d['model'];typeof _0x445a91[_0x14b619('0xa')][_0x14b619('0x1a')]===_0x14b619('0x19')&&(_0x399de8[_0x14b619('0x9')]=qs[_0x14b619('0x9')](_0x445a91[_0x14b619('0xa')][_0x14b619('0x9')]),_0x399de8[_0x14b619('0x3a')]=qs[_0x14b619('0x3a')](_0x445a91[_0x14b619('0xa')]['offset']));_0x399de8[_0x14b619('0xe')]=qs[_0x14b619('0x3b')](_0x445a91['query'][_0x14b619('0x3b')]),_0x399de8[_0x14b619('0x2a')]=qs[_0x14b619('0xd')](_[_0x14b619('0x15')](_0x445a91['query'],_0x348f0d[_0x14b619('0xd')]),_0x9c240e);_0x445a91[_0x14b619('0xa')]['filter']&&(_0x399de8[_0x14b619('0x2a')]=_['merge'](_0x399de8['where'],{[Op['or']]:_[_0x14b619('0x5')](_0x9c240e,function(_0x2ae146){const _0x430cfa=_0x14b619;if(_0x2ae146['type']!==_0x430cfa('0x3c')){const _0x227037={};return _0x227037[_0x2ae146[_0x430cfa('0x2')]]={[Op[_0x430cfa('0x31')]]:'%'+_0x445a91['query'][_0x430cfa('0x2b')]+'%'},_0x227037;}})}));_0x399de8=_['merge']({},_0x399de8,_0x445a91[_0x14b619('0x3')]);const _0x6950e3={'where':_0x399de8['where']};return db['VoiceChanSpy']['count'](_0x6950e3)[_0x14b619('0x16')](function(_0x30ffa1){const _0x408753=_0x14b619;return _0x28bc42[_0x408753('0x13')]=_0x30ffa1,_0x445a91[_0x408753('0xa')]['includeAll']&&(_0x399de8[_0x408753('0x28')]=[{'all':!![]}]),db[_0x408753('0x11')]['findAll'](_0x399de8);})[_0x14b619('0x16')](function(_0x13e707){const _0x1a7549=_0x14b619;return _0x28bc42[_0x1a7549('0x34')]=_0x13e707,_0x28bc42;})['then'](respondWithFilteredResult(_0x2d6cf0,_0x399de8))[_0x14b619('0x20')](handleError(_0x2d6cf0,null));},exports[_0x345274('0x26')]=function(_0x29db3f,_0x18d4ce){const _0x48ba49=_0x345274;let _0x5e3c2e={'raw':![],'where':{'id':_0x29db3f[_0x48ba49('0xc')]['id']}};const _0x4decc1={};return _0x4decc1[_0x48ba49('0x8')]=_[_0x48ba49('0x1b')](db[_0x48ba49('0x11')][_0x48ba49('0x38')]),_0x4decc1[_0x48ba49('0xa')]=_[_0x48ba49('0x1b')](_0x29db3f[_0x48ba49('0xa')]),_0x4decc1['filters']=_['intersection'](_0x4decc1['model'],_0x4decc1['query']),_0x5e3c2e[_0x48ba49('0x17')]=_[_0x48ba49('0x25')](_0x4decc1[_0x48ba49('0x8')],qs[_0x48ba49('0x14')](_0x29db3f[_0x48ba49('0xa')][_0x48ba49('0x14')])),_0x5e3c2e[_0x48ba49('0x17')]=_0x5e3c2e[_0x48ba49('0x17')][_0x48ba49('0x1')]?_0x5e3c2e[_0x48ba49('0x17')]:_0x4decc1['model'],_0x29db3f[_0x48ba49('0xa')][_0x48ba49('0x1c')]&&(_0x5e3c2e[_0x48ba49('0x28')]=[{'all':!![]}]),_0x5e3c2e=_[_0x48ba49('0x27')]({},_0x5e3c2e,_0x29db3f[_0x48ba49('0x3')]),db[_0x48ba49('0x11')][_0x48ba49('0x10')](_0x5e3c2e)[_0x48ba49('0x16')](handleEntityNotFound(_0x18d4ce,null))[_0x48ba49('0x16')](respondWithResult(_0x18d4ce,null))['catch'](handleError(_0x18d4ce,null));},exports[_0x345274('0x4')]=function(_0x538255,_0x464427){const _0x3abce4=_0x345274;return db[_0x3abce4('0x11')]['create'](_0x538255[_0x3abce4('0x24')],{})[_0x3abce4('0x16')](function(_0x5adea9){const _0x2b8501=_0x3abce4,_0x1093c2=_0x538255[_0x2b8501('0x22')][_0x2b8501('0x37')]({'plain':!![]});if(!_0x1093c2)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x1093c2[_0x2b8501('0xb')]===_0x2b8501('0x22')){const _0x5ab638=_0x5adea9[_0x2b8501('0x37')]({'plain':!![]}),_0x289359=_0x2b8501('0x32');return db[_0x2b8501('0x33')][_0x2b8501('0x10')]({'where':{'name':_0x289359,'userProfileId':_0x1093c2[_0x2b8501('0x39')]},'raw':!![]})[_0x2b8501('0x16')](function(_0x4c568c){const _0x18df58=_0x2b8501;return _0x4c568c&&_0x4c568c[_0x18df58('0x2c')]===0x0?db[_0x18df58('0x18')][_0x18df58('0x4')]({'name':_0x5ab638['name'],'resourceId':_0x5ab638['id'],'type':_0x4c568c[_0x18df58('0x2')],'sectionId':_0x4c568c['id']},{})[_0x18df58('0x16')](function(){return _0x5adea9;}):_0x5adea9;})['catch'](function(_0x542c78){const _0x1c1815=_0x2b8501;logger[_0x1c1815('0x1d')](_0x1c1815('0x12'),_0x542c78);throw _0x542c78;});}return _0x5adea9;})[_0x3abce4('0x16')](respondWithResult(_0x464427,0xc9))['catch'](handleError(_0x464427,null));},exports[_0x345274('0x35')]=function(_0xbaa426,_0x3405d5){const _0x5cf9ee=_0x345274;return _0xbaa426[_0x5cf9ee('0x24')]['id']&&delete _0xbaa426[_0x5cf9ee('0x24')]['id'],db[_0x5cf9ee('0x11')][_0x5cf9ee('0x10')]({'where':{'id':_0xbaa426[_0x5cf9ee('0xc')]['id']}})[_0x5cf9ee('0x16')](handleEntityNotFound(_0x3405d5,null))[_0x5cf9ee('0x16')](saveUpdates(_0xbaa426[_0x5cf9ee('0x24')],null))[_0x5cf9ee('0x16')](respondWithResult(_0x3405d5,null))[_0x5cf9ee('0x20')](handleError(_0x3405d5,null));},exports[_0x345274('0x2e')]=function(_0x59166f,_0x4bc3f7){const _0x33733b=_0x345274;return db[_0x33733b('0x11')][_0x33733b('0x10')]({'where':{'id':_0x59166f['params']['id']}})[_0x33733b('0x16')](handleEntityNotFound(_0x4bc3f7,null))[_0x33733b('0x16')](removeEntity(_0x4bc3f7,null))['catch'](handleError(_0x4bc3f7,null));}; \ No newline at end of file diff --git a/server/api/voiceChanSpy/voiceChanSpy.model.js b/server/api/voiceChanSpy/voiceChanSpy.model.js index 4a3c24f..c460326 100644 --- a/server/api/voiceChanSpy/voiceChanSpy.model.js +++ b/server/api/voiceChanSpy/voiceChanSpy.model.js @@ -1 +1 @@ -const a715_0x57c5=['record','${UNIQUEID}.%s,ab','join','MixMonitor','destroy','catch','bulkCreate','auth','CDR(type)=%s','ChanSpy','agent','length','system','%s%s','name','format','context','SIP/%s,%s','voice_chanspy','./voiceChanSpy.attributes','VoiceExtension','prefix','Set','concat','chanspy','recordingFormat','exports','internal','merge','lodash','options','findAll','VoiceChanSpy','StopMixMonitor','push','Authenticate','define','util','then'];(function(_0x239791,_0x57c523){const _0x176d43=function(_0x153da2){while(--_0x153da2){_0x239791['push'](_0x239791['shift']());}};_0x176d43(++_0x57c523);}(a715_0x57c5,0x86));const a715_0x176d=function(_0x239791,_0x57c523){_0x239791=_0x239791-0x0;let _0x176d43=a715_0x57c5[_0x239791];return _0x176d43;};const _0x5006e0=a715_0x176d;'use strict';const _=require(_0x5006e0('0xc')),util=require(_0x5006e0('0x14')),attributes=require(_0x5006e0('0x2')),createChanSpyApplications=function(_0x153da2,_0x4a476e,_0x4ff362){const _0x46602a=_0x5006e0;let _0xf4292c=0x1;const _0x135388=[],_0x1eeef6={'context':_0x4a476e[_0x46602a('0x26')]||'from-sip','exten':util[_0x46602a('0x25')](_0x46602a('0x23'),_0x153da2[_0x46602a('0x4')],_0x4ff362),'type':_0x46602a('0x22'),'isApp':![],'ChanSpyId':_0x153da2['id'],'UserId':_0x4a476e['id']};return _0x135388[_0x46602a('0x11')](_[_0x46602a('0xb')]({'app':_0x46602a('0x5'),'appdata':util['format'](_0x46602a('0x1e'),_0x46602a('0x7')),'priority':_0xf4292c++},_0x1eeef6)),_0x153da2['record']&&_0x135388['push'](_[_0x46602a('0xb')]({'app':_0x46602a('0x19'),'appdata':util[_0x46602a('0x25')](_0x46602a('0x17'),_0x153da2[_0x46602a('0x8')]),'priority':_0xf4292c++},_0x1eeef6)),_0x153da2[_0x46602a('0x1d')]&&_0x135388[_0x46602a('0x11')](_[_0x46602a('0xb')]({'app':_0x46602a('0x12'),'appdata':_0x153da2['password'],'priority':_0xf4292c++},_0x1eeef6)),_0x135388['push'](_[_0x46602a('0xb')]({'app':_0x46602a('0x1f'),'appdata':util['format'](_0x46602a('0x0'),_0x4a476e['name'],_0x153da2[_0x46602a('0xd')]?_0x153da2[_0x46602a('0xd')][_0x46602a('0x18')](''):''),'priority':_0xf4292c++},_0x1eeef6)),_0x153da2[_0x46602a('0x16')]&&_0x135388[_0x46602a('0x11')](_[_0x46602a('0xb')]({'app':_0x46602a('0x10'),'priority':_0xf4292c++},_0x1eeef6)),_0x135388;},addChanSpyApplications=function(_0x2612f8,_0x131a6e){const _0x4980c5=_0x5006e0;let _0x7fb28d=[];for(let _0x1af2bc=0x0;_0x1af2bc<_0x131a6e[_0x4980c5('0x21')];_0x1af2bc++){_0x7fb28d=_0x7fb28d['concat'](createChanSpyApplications(_0x2612f8,_0x131a6e[_0x1af2bc],_0x131a6e[_0x1af2bc][_0x4980c5('0xa')])),_0x131a6e[_0x1af2bc]['internal']!=_0x131a6e[_0x1af2bc]['name']&&(_0x7fb28d=_0x7fb28d[_0x4980c5('0x6')](createChanSpyApplications(_0x2612f8,_0x131a6e[_0x1af2bc],_0x131a6e[_0x1af2bc][_0x4980c5('0x24')])));}return _0x7fb28d;},getChanSpy=function(_0x2dc24f,_0x10632a){return new Promise(function(_0x31359c,_0xd647a8){const _0x5c819e=a715_0x176d;return _0x2dc24f['User'][_0x5c819e('0xe')]({'attributes':['id',_0x5c819e('0x24'),_0x5c819e('0xa')],'where':{'role':_0x5c819e('0x20'),'chanspy':!![]},'raw':!![]})[_0x5c819e('0x15')](function(_0x5a7210){if(_0x5a7210)return _0x31359c(addChanSpyApplications(_0x10632a,_0x5a7210));return _0x31359c([]);})[_0x5c819e('0x1b')](function(_0x5391cf){_0xd647a8(_0x5391cf);});});};module[_0x5006e0('0x9')]=function(_0x4d712b){const _0x3c5cbd=_0x5006e0,_0x51257f=_0x4d712b['models'],_0x308f5e=_0x4d712b[_0x3c5cbd('0x13')](_0x3c5cbd('0xf'),attributes,{'tableName':_0x3c5cbd('0x1'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'afterCreate':function(_0x14f202){const _0x321feb=_0x3c5cbd;return getChanSpy(_0x51257f,_0x14f202)['then'](function(_0x27aecb){const _0x1a9cd0=a715_0x176d;return _0x27aecb&&_0x27aecb[_0x1a9cd0('0x21')]?_0x51257f[_0x1a9cd0('0x3')][_0x1a9cd0('0x1c')](_0x27aecb):null;})[_0x321feb('0x1b')](function(_0x5b09ed){return _0x5b09ed;});},'afterUpdate':function(_0x5999cc){const _0x259c86=_0x3c5cbd;return _0x51257f[_0x259c86('0x3')][_0x259c86('0x1a')]({'where':{'ChanSpyId':_0x5999cc['id']}})[_0x259c86('0x15')](function(){return getChanSpy(_0x51257f,_0x5999cc);})['then'](function(_0x300e06){const _0x2dbcc1=_0x259c86;return _0x300e06&&_0x300e06[_0x2dbcc1('0x21')]?_0x51257f['VoiceExtension'][_0x2dbcc1('0x1c')](_0x300e06):null;})[_0x259c86('0x1b')](function(_0x2d9d21){return _0x2d9d21;});},'afterDestroy':function(_0x2962d2){const _0x2c50db=_0x3c5cbd;return _0x51257f[_0x2c50db('0x3')][_0x2c50db('0x1a')]({'where':{'ChanSpyId':_0x2962d2['id']}})[_0x2c50db('0x15')](function(){return null;})[_0x2c50db('0x1b')](function(_0x552430){return _0x552430;});}}});return _0x308f5e;}; \ No newline at end of file +const a715_0x25e1=['password','prefix','agent','%s%s','${UNIQUEID}.%s,ab','catch','length','format','ChanSpy','options','chanspy','concat','StopMixMonitor','SIP/%s,%s','User','record','merge','./voiceChanSpy.attributes','models','MixMonitor','push','Set','system','CDR(type)=%s','recordingFormat','internal','context','then','join','voice_chanspy','define','findAll','Authenticate','name','VoiceChanSpy','VoiceExtension','bulkCreate'];(function(_0x35844e,_0x25e1bd){const _0x5086d1=function(_0x5b9ee4){while(--_0x5b9ee4){_0x35844e['push'](_0x35844e['shift']());}};_0x5086d1(++_0x25e1bd);}(a715_0x25e1,0x10a));const a715_0x5086=function(_0x35844e,_0x25e1bd){_0x35844e=_0x35844e-0x0;let _0x5086d1=a715_0x25e1[_0x35844e];return _0x5086d1;};const _0x7f1171=a715_0x5086;'use strict';const _=require('lodash'),util=require('util'),attributes=require(_0x7f1171('0xa')),createChanSpyApplications=function(_0x5b9ee4,_0x4a13b4,_0x3a1400){const _0x2fb0d5=_0x7f1171;let _0x3e0d3f=0x1;const _0x12c796=[],_0x40b4b0={'context':_0x4a13b4[_0x2fb0d5('0x13')]||'from-sip','exten':util['format'](_0x2fb0d5('0x21'),_0x5b9ee4[_0x2fb0d5('0x1f')],_0x3a1400),'type':_0x2fb0d5('0xf'),'isApp':![],'ChanSpyId':_0x5b9ee4['id'],'UserId':_0x4a13b4['id']};return _0x12c796[_0x2fb0d5('0xd')](_[_0x2fb0d5('0x9')]({'app':_0x2fb0d5('0xe'),'appdata':util[_0x2fb0d5('0x0')](_0x2fb0d5('0x10'),_0x2fb0d5('0x3')),'priority':_0x3e0d3f++},_0x40b4b0)),_0x5b9ee4[_0x2fb0d5('0x8')]&&_0x12c796[_0x2fb0d5('0xd')](_[_0x2fb0d5('0x9')]({'app':_0x2fb0d5('0xc'),'appdata':util['format'](_0x2fb0d5('0x22'),_0x5b9ee4[_0x2fb0d5('0x11')]),'priority':_0x3e0d3f++},_0x40b4b0)),_0x5b9ee4['auth']&&_0x12c796[_0x2fb0d5('0xd')](_[_0x2fb0d5('0x9')]({'app':_0x2fb0d5('0x19'),'appdata':_0x5b9ee4[_0x2fb0d5('0x1e')],'priority':_0x3e0d3f++},_0x40b4b0)),_0x12c796[_0x2fb0d5('0xd')](_[_0x2fb0d5('0x9')]({'app':_0x2fb0d5('0x1'),'appdata':util['format'](_0x2fb0d5('0x6'),_0x4a13b4[_0x2fb0d5('0x1a')],_0x5b9ee4['options']?_0x5b9ee4[_0x2fb0d5('0x2')][_0x2fb0d5('0x15')](''):''),'priority':_0x3e0d3f++},_0x40b4b0)),_0x5b9ee4[_0x2fb0d5('0x8')]&&_0x12c796[_0x2fb0d5('0xd')](_[_0x2fb0d5('0x9')]({'app':_0x2fb0d5('0x5'),'priority':_0x3e0d3f++},_0x40b4b0)),_0x12c796;},addChanSpyApplications=function(_0x5adeb5,_0x31df9f){const _0x4f8977=_0x7f1171;let _0x1042a0=[];for(let _0x26ad2f=0x0;_0x26ad2f<_0x31df9f['length'];_0x26ad2f++){_0x1042a0=_0x1042a0[_0x4f8977('0x4')](createChanSpyApplications(_0x5adeb5,_0x31df9f[_0x26ad2f],_0x31df9f[_0x26ad2f]['internal'])),_0x31df9f[_0x26ad2f]['internal']!=_0x31df9f[_0x26ad2f][_0x4f8977('0x1a')]&&(_0x1042a0=_0x1042a0[_0x4f8977('0x4')](createChanSpyApplications(_0x5adeb5,_0x31df9f[_0x26ad2f],_0x31df9f[_0x26ad2f][_0x4f8977('0x1a')])));}return _0x1042a0;},getChanSpy=function(_0x2785ee,_0x24fc75){return new Promise(function(_0x4001de,_0x22820b){const _0x1b75ad=a715_0x5086;return _0x2785ee[_0x1b75ad('0x7')][_0x1b75ad('0x18')]({'attributes':['id','name',_0x1b75ad('0x12')],'where':{'role':_0x1b75ad('0x20'),'chanspy':!![]},'raw':!![]})[_0x1b75ad('0x14')](function(_0xdb889b){if(_0xdb889b)return _0x4001de(addChanSpyApplications(_0x24fc75,_0xdb889b));return _0x4001de([]);})[_0x1b75ad('0x23')](function(_0x479566){_0x22820b(_0x479566);});});};module['exports']=function(_0x1a7c1b){const _0x4020c4=_0x7f1171,_0x39a069=_0x1a7c1b[_0x4020c4('0xb')],_0x37247d=_0x1a7c1b[_0x4020c4('0x17')](_0x4020c4('0x1b'),attributes,{'tableName':_0x4020c4('0x16'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'afterCreate':function(_0xfdf369){const _0x458517=_0x4020c4;return getChanSpy(_0x39a069,_0xfdf369)['then'](function(_0x233e84){const _0x46140a=a715_0x5086;return _0x233e84&&_0x233e84[_0x46140a('0x24')]?_0x39a069[_0x46140a('0x1c')][_0x46140a('0x1d')](_0x233e84):null;})[_0x458517('0x23')](function(_0x3b38c5){return _0x3b38c5;});},'afterUpdate':function(_0x5d23c0){const _0x1e060a=_0x4020c4;return _0x39a069[_0x1e060a('0x1c')]['destroy']({'where':{'ChanSpyId':_0x5d23c0['id']}})['then'](function(){return getChanSpy(_0x39a069,_0x5d23c0);})[_0x1e060a('0x14')](function(_0x3f3aed){const _0x190bea=_0x1e060a;return _0x3f3aed&&_0x3f3aed['length']?_0x39a069[_0x190bea('0x1c')]['bulkCreate'](_0x3f3aed):null;})[_0x1e060a('0x23')](function(_0x23162f){return _0x23162f;});},'afterDestroy':function(_0x1989ca){const _0x111636=_0x4020c4;return _0x39a069[_0x111636('0x1c')]['destroy']({'where':{'ChanSpyId':_0x1989ca['id']}})[_0x111636('0x14')](function(){return null;})['catch'](function(_0x4faef1){return _0x4faef1;});}}});return _0x37247d;}; \ No newline at end of file diff --git a/server/api/voiceContext/index.js b/server/api/voiceContext/index.js index bd4f87d..d7890b7 100644 --- a/server/api/voiceContext/index.js +++ b/server/api/voiceContext/index.js @@ -1 +1 @@ -const a716_0x3bfe=['../../components/auth/service','./voiceContext.controller','Router','get','isAuthenticated','update','delete','show','/:id','destroy','put','post','express'];(function(_0x4bcc4c,_0x3bfe3a){const _0x11e6d4=function(_0x717f25){while(--_0x717f25){_0x4bcc4c['push'](_0x4bcc4c['shift']());}};_0x11e6d4(++_0x3bfe3a);}(a716_0x3bfe,0x65));const a716_0x11e6=function(_0x4bcc4c,_0x3bfe3a){_0x4bcc4c=_0x4bcc4c-0x0;let _0x11e6d4=a716_0x3bfe[_0x4bcc4c];return _0x11e6d4;};const _0x1b9112=a716_0x11e6;'use strict';const express=require(_0x1b9112('0x2')),router=express[_0x1b9112('0x5')](),auth=require(_0x1b9112('0x3')),controller=require(_0x1b9112('0x4'));router['get']('/',auth[_0x1b9112('0x7')](),controller['index']),router[_0x1b9112('0x6')](_0x1b9112('0xb'),auth[_0x1b9112('0x7')](),controller[_0x1b9112('0xa')]),router[_0x1b9112('0x1')]('/',auth[_0x1b9112('0x7')](),controller['create']),router[_0x1b9112('0x0')](_0x1b9112('0xb'),auth[_0x1b9112('0x7')](),controller[_0x1b9112('0x8')]),router[_0x1b9112('0x9')](_0x1b9112('0xb'),auth[_0x1b9112('0x7')](),controller[_0x1b9112('0xc')]),module['exports']=router; \ No newline at end of file +const a716_0x15d5=['show','isAuthenticated','post','/:id','exports','express','delete','index','get','../../components/auth/service','create','Router','./voiceContext.controller','put','destroy'];(function(_0x51cc2f,_0x15d5e5){const _0x642b2d=function(_0xb3d7c){while(--_0xb3d7c){_0x51cc2f['push'](_0x51cc2f['shift']());}};_0x642b2d(++_0x15d5e5);}(a716_0x15d5,0x143));const a716_0x642b=function(_0x51cc2f,_0x15d5e5){_0x51cc2f=_0x51cc2f-0x0;let _0x642b2d=a716_0x15d5[_0x51cc2f];return _0x642b2d;};const _0xa3cb9c=a716_0x642b;'use strict';const express=require(_0xa3cb9c('0xc')),router=express[_0xa3cb9c('0x3')](),auth=require(_0xa3cb9c('0x1')),controller=require(_0xa3cb9c('0x4'));router['get']('/',auth[_0xa3cb9c('0x8')](),controller[_0xa3cb9c('0xe')]),router[_0xa3cb9c('0x0')](_0xa3cb9c('0xa'),auth[_0xa3cb9c('0x8')](),controller[_0xa3cb9c('0x7')]),router[_0xa3cb9c('0x9')]('/',auth[_0xa3cb9c('0x8')](),controller[_0xa3cb9c('0x2')]),router[_0xa3cb9c('0x5')](_0xa3cb9c('0xa'),auth['isAuthenticated'](),controller['update']),router[_0xa3cb9c('0xd')](_0xa3cb9c('0xa'),auth[_0xa3cb9c('0x8')](),controller[_0xa3cb9c('0x6')]),module[_0xa3cb9c('0xb')]=router; \ No newline at end of file diff --git a/server/api/voiceContext/voiceContext.attributes.js b/server/api/voiceContext/voiceContext.attributes.js index 565ca7c..e0cfb45 100644 --- a/server/api/voiceContext/voiceContext.attributes.js +++ b/server/api/voiceContext/voiceContext.attributes.js @@ -1 +1 @@ -const a717_0x3109=['STRING','BOOLEAN','exports','sequelize','name'];(function(_0x210360,_0x31097d){const _0x133709=function(_0x273892){while(--_0x273892){_0x210360['push'](_0x210360['shift']());}};_0x133709(++_0x31097d);}(a717_0x3109,0x1e7));const a717_0x1337=function(_0x210360,_0x31097d){_0x210360=_0x210360-0x0;let _0x133709=a717_0x3109[_0x210360];return _0x133709;};const _0x1e4b5b=a717_0x1337;'use strict';const Sequelize=require(_0x1e4b5b('0x1'));module[_0x1e4b5b('0x0')]={'name':{'type':Sequelize[_0x1e4b5b('0x3')],'unique':_0x1e4b5b('0x2')},'description':{'type':Sequelize[_0x1e4b5b('0x3')],'allowNull':!![]},'defaultEntry':{'type':Sequelize[_0x1e4b5b('0x4')],'defaultValue':0x0}}; \ No newline at end of file +const a717_0x3590=['BOOLEAN','name','STRING','exports','sequelize'];(function(_0x75c4,_0x35903c){const _0x3e739d=function(_0x28f5fa){while(--_0x28f5fa){_0x75c4['push'](_0x75c4['shift']());}};_0x3e739d(++_0x35903c);}(a717_0x3590,0xc3));const a717_0x3e73=function(_0x75c4,_0x35903c){_0x75c4=_0x75c4-0x0;let _0x3e739d=a717_0x3590[_0x75c4];return _0x3e739d;};const _0x58b1f1=a717_0x3e73;'use strict';const Sequelize=require(_0x58b1f1('0x4'));module[_0x58b1f1('0x3')]={'name':{'type':Sequelize['STRING'],'unique':_0x58b1f1('0x1')},'description':{'type':Sequelize[_0x58b1f1('0x2')],'allowNull':!![]},'defaultEntry':{'type':Sequelize[_0x58b1f1('0x0')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/voiceContext/voiceContext.controller.js b/server/api/voiceContext/voiceContext.controller.js index 8db598d..28e3078 100644 --- a/server/api/voiceContext/voiceContext.controller.js +++ b/server/api/voiceContext/voiceContext.controller.js @@ -1 +1 @@ -const a718_0x1900=['intersection','UserProfileSection','params','order','path','sort','limit','chan_sip.so','options','update','userProfileId','map','create','findAll','pick','findOne','Content-Range','jayson/promise','VoiceContext,\x20%s,\x20%s','like','request\x20sent','json','join','nolimit','info','Contexts','destroy','includeAll','body','VIRTUAL','filters','UserProfileResource','undefined','length','attributes','VoiceContext,\x20%s,\x20%s,\x20%s','Unable\x20to\x20retrieve\x20the\x20current\x20user','merge','offset','stack','model','key','index','sequelize','show','include','catch','files/templates/context.ejs','stringify','render','query','Reload','then','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','../../components/parsers/qs','VoiceContext','result','get','http','status','error','rawAttributes','autoAssociation','writeFileSync','user','keys','debug','../../config/environment','name','message','rows','readFileSync','filter','code','../../mysqldb','count','where','role','api','/etc/asterisk/extensions_xcally_contexts.conf','fields','root','ejs','client','utf8','../../config/logger','type'];(function(_0x45afa0,_0x19002f){const _0xee856a=function(_0x1416b4){while(--_0x1416b4){_0x45afa0['push'](_0x45afa0['shift']());}};_0xee856a(++_0x19002f);}(a718_0x1900,0xb9));const a718_0xee85=function(_0x45afa0,_0x19002f){_0x45afa0=_0x45afa0-0x0;let _0xee856a=a718_0x1900[_0x45afa0];return _0xee856a;};const _0x5bad73=a718_0xee85;'use strict';const path=require(_0x5bad73('0x50')),ejs=require(_0x5bad73('0x47')),fs=require('fs'),_=require('lodash'),qs=require(_0x5bad73('0x2b')),logger=require(_0x5bad73('0x4a'))(_0x5bad73('0x43')),config=require(_0x5bad73('0x38')),db=require(_0x5bad73('0x3f'))['db'],{Op}=require(_0x5bad73('0x20')),jayson=require(_0x5bad73('0x6')),client=jayson[_0x5bad73('0x48')][_0x5bad73('0x2f')]({'port':0x232a});function respondWithRpcPromise(_0x1416b4,_0x49c5e6,_0x498fe3,_0x469a5b){return new Promise(function(_0x47cbb4,_0x43a814){const _0x2007ce=a718_0xee85,_0x37c708=_0x469a5b||client;return _0x37c708['request'](_0x1416b4,_0x498fe3)[_0x2007ce('0x29')](function(_0x599e9f){const _0x418ac0=_0x2007ce;logger[_0x418ac0('0xd')]('VoiceContext,\x20%s,\x20%s',_0x49c5e6,_0x418ac0('0x9')),logger[_0x418ac0('0x37')](_0x418ac0('0x18'),_0x49c5e6,'request\x20sent',JSON[_0x418ac0('0x25')](_0x599e9f));if(_0x599e9f[_0x418ac0('0x31')]){if(_0x599e9f['error'][_0x418ac0('0x3e')]===0x1f4)return logger['error'](_0x418ac0('0x7'),_0x49c5e6,_0x599e9f[_0x418ac0('0x31')]['message']),_0x43a814(_0x599e9f[_0x418ac0('0x31')]['message']);return logger[_0x418ac0('0x31')](_0x418ac0('0x7'),_0x49c5e6,_0x599e9f[_0x418ac0('0x31')]['message']),_0x47cbb4(_0x599e9f[_0x418ac0('0x31')][_0x418ac0('0x3a')]);}else logger[_0x418ac0('0xd')](_0x418ac0('0x7'),_0x49c5e6,_0x418ac0('0x9')),_0x47cbb4(_0x599e9f[_0x418ac0('0x2d')][_0x418ac0('0x3a')]);})[_0x2007ce('0x23')](function(_0x34e29e){const _0x401e24=_0x2007ce;logger['error'](_0x401e24('0x7'),_0x49c5e6,_0x34e29e),_0x43a814(_0x34e29e);});});}function respondWithResult(_0x333ac1,_0x35cac0){return _0x35cac0=_0x35cac0||0xc8,function(_0x363f8f){const _0x3bf4af=a718_0xee85;if(_0x363f8f)return _0x333ac1[_0x3bf4af('0x30')](_0x35cac0)[_0x3bf4af('0xa')](_0x363f8f);};}function respondWithFilteredResult(_0x35dead,_0x46eccc){return function(_0x856122){const _0x30a73e=a718_0xee85;if(_0x856122){const _0x5eba7d=_0x856122[_0x30a73e('0x40')],_0x278f1d=_0x46eccc['offset'];let _0x20d982=_0x46eccc[_0x30a73e('0x1b')]+_0x46eccc['limit'],_0x49ef8d;return _0x20d982>=_0x5eba7d?(_0x20d982=_0x5eba7d,_0x49ef8d=0xc8):_0x49ef8d=0xce,_0x35dead[_0x30a73e('0x30')](_0x49ef8d),_0x35dead['set'](_0x30a73e('0x5'),_0x278f1d+'-'+_0x20d982+'/'+_0x5eba7d)[_0x30a73e('0xa')](_0x856122);}return null;};}function saveUpdates(_0x379ba6){return function(_0x59d927){const _0x3055a3=a718_0xee85;if(_0x59d927)return _0x59d927[_0x3055a3('0x55')](_0x379ba6)[_0x3055a3('0x29')](function(_0x580eef){return _0x580eef;});return null;};}function removeEntity(_0x1806c9){return function(_0x22201a){const _0x336cdf=a718_0xee85;if(_0x22201a)return _0x22201a[_0x336cdf('0xf')]()[_0x336cdf('0x29')](function(){const _0x55fa5f=_0x336cdf,_0x5a22fe=_0x22201a[_0x55fa5f('0x2e')]({'plain':!![]}),_0x53c10d='Contexts';return db[_0x55fa5f('0x14')]['destroy']({'where':{'type':_0x53c10d,'resourceId':_0x5a22fe['id']}})[_0x55fa5f('0x29')](function(){return _0x22201a;});})[_0x336cdf('0x29')](function(){_0x1806c9['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x2d5381){return function(_0x53dfc2){return!_0x53dfc2&&_0x2d5381['sendStatus'](0x194),_0x53dfc2;};}function handleError(_0x2b6f24,_0x82a3ab){return _0x82a3ab=_0x82a3ab||0x1f4,function(_0x39eb7a){const _0x14f3e4=a718_0xee85;logger['error'](_0x39eb7a[_0x14f3e4('0x1c')]),_0x39eb7a[_0x14f3e4('0x39')]&&delete _0x39eb7a[_0x14f3e4('0x39')],_0x2b6f24[_0x14f3e4('0x30')](_0x82a3ab)['send'](_0x39eb7a);};}exports[_0x5bad73('0x1f')]=function(_0x4145f8,_0x3b1a5f){const _0x200b76=_0x5bad73;let _0xa8e1ce={};const _0x34222f={},_0x270a0b={'count':0x0,'rows':[]},_0x1cc837=_[_0x200b76('0x0')](db[_0x200b76('0x2c')]['rawAttributes'],function(_0x17674d){const _0x145f41=_0x200b76;return{'name':_0x17674d['fieldName'],'type':_0x17674d[_0x145f41('0x4b')][_0x145f41('0x1e')]};});_0x34222f[_0x200b76('0x1d')]=_[_0x200b76('0x0')](_0x1cc837,'name'),_0x34222f[_0x200b76('0x27')]=_['keys'](_0x4145f8[_0x200b76('0x27')]),_0x34222f['filters']=_['intersection'](_0x34222f['model'],_0x34222f[_0x200b76('0x27')]),_0xa8e1ce[_0x200b76('0x17')]=_[_0x200b76('0x4c')](_0x34222f[_0x200b76('0x1d')],qs[_0x200b76('0x45')](_0x4145f8[_0x200b76('0x27')][_0x200b76('0x45')])),_0xa8e1ce[_0x200b76('0x17')]=_0xa8e1ce[_0x200b76('0x17')]['length']?_0xa8e1ce[_0x200b76('0x17')]:_0x34222f[_0x200b76('0x1d')];typeof _0x4145f8['query'][_0x200b76('0xc')]===_0x200b76('0x15')&&(_0xa8e1ce[_0x200b76('0x52')]=qs['limit'](_0x4145f8['query'][_0x200b76('0x52')]),_0xa8e1ce['offset']=qs[_0x200b76('0x1b')](_0x4145f8[_0x200b76('0x27')][_0x200b76('0x1b')]));_0xa8e1ce[_0x200b76('0x4f')]=qs[_0x200b76('0x51')](_0x4145f8[_0x200b76('0x27')]['sort']),_0xa8e1ce[_0x200b76('0x41')]=qs['filters'](_[_0x200b76('0x3')](_0x4145f8[_0x200b76('0x27')],_0x34222f[_0x200b76('0x13')]),_0x1cc837);_0x4145f8[_0x200b76('0x27')][_0x200b76('0x3d')]&&(_0xa8e1ce[_0x200b76('0x41')]=_[_0x200b76('0x1a')](_0xa8e1ce[_0x200b76('0x41')],{[Op['or']]:_[_0x200b76('0x0')](_0x1cc837,function(_0x4d9aec){const _0x3cca66=_0x200b76;if(_0x4d9aec[_0x3cca66('0x4b')]!==_0x3cca66('0x12')){const _0x919116={};return _0x919116[_0x4d9aec[_0x3cca66('0x39')]]={[Op[_0x3cca66('0x8')]]:'%'+_0x4145f8[_0x3cca66('0x27')]['filter']+'%'},_0x919116;}})}));_0xa8e1ce=_[_0x200b76('0x1a')]({},_0xa8e1ce,_0x4145f8[_0x200b76('0x54')]);const _0xec0df4={'where':_0xa8e1ce[_0x200b76('0x41')]};return db[_0x200b76('0x2c')][_0x200b76('0x40')](_0xec0df4)[_0x200b76('0x29')](function(_0x22a683){const _0x105069=_0x200b76;return _0x270a0b[_0x105069('0x40')]=_0x22a683,_0x4145f8[_0x105069('0x27')][_0x105069('0x10')]&&(_0xa8e1ce[_0x105069('0x22')]=[{'all':!![]}]),db[_0x105069('0x2c')][_0x105069('0x2')](_0xa8e1ce);})[_0x200b76('0x29')](function(_0x2ad032){const _0x499f49=_0x200b76;return _0x270a0b[_0x499f49('0x3b')]=_0x2ad032,_0x270a0b;})[_0x200b76('0x29')](respondWithFilteredResult(_0x3b1a5f,_0xa8e1ce))[_0x200b76('0x23')](handleError(_0x3b1a5f,null));},exports[_0x5bad73('0x21')]=function(_0x1cabb0,_0x31cc8a){const _0x1ee073=_0x5bad73;let _0x1ced2a={'raw':![],'where':{'id':_0x1cabb0[_0x1ee073('0x4e')]['id']}};const _0x11c58c={};return _0x11c58c['model']=_[_0x1ee073('0x36')](db['VoiceContext'][_0x1ee073('0x32')]),_0x11c58c[_0x1ee073('0x27')]=_[_0x1ee073('0x36')](_0x1cabb0[_0x1ee073('0x27')]),_0x11c58c[_0x1ee073('0x13')]=_[_0x1ee073('0x4c')](_0x11c58c[_0x1ee073('0x1d')],_0x11c58c[_0x1ee073('0x27')]),_0x1ced2a['attributes']=_[_0x1ee073('0x4c')](_0x11c58c['model'],qs[_0x1ee073('0x45')](_0x1cabb0['query'][_0x1ee073('0x45')])),_0x1ced2a[_0x1ee073('0x17')]=_0x1ced2a[_0x1ee073('0x17')][_0x1ee073('0x16')]?_0x1ced2a[_0x1ee073('0x17')]:_0x11c58c[_0x1ee073('0x1d')],_0x1cabb0[_0x1ee073('0x27')]['includeAll']&&(_0x1ced2a['include']=[{'all':!![]}]),_0x1ced2a=_[_0x1ee073('0x1a')]({},_0x1ced2a,_0x1cabb0[_0x1ee073('0x54')]),db[_0x1ee073('0x2c')][_0x1ee073('0x4')](_0x1ced2a)[_0x1ee073('0x29')](handleEntityNotFound(_0x31cc8a,null))[_0x1ee073('0x29')](respondWithResult(_0x31cc8a,null))[_0x1ee073('0x23')](handleError(_0x31cc8a,null));},exports[_0x5bad73('0x1')]=function(_0x25cbd3,_0x1f65cd){const _0x202003=_0x5bad73;let _0x224e8f;return db[_0x202003('0x2c')][_0x202003('0x1')](_0x25cbd3[_0x202003('0x11')],{'raw':!![]})[_0x202003('0x29')](function(_0x2c677c){const _0x28d8cb=_0x202003;return _0x224e8f=_0x2c677c,db[_0x28d8cb('0x2c')]['findAll']({'raw':!![]});})[_0x202003('0x29')](function(_0x8665b4){const _0x1bda87=_0x202003,_0x28a48c=fs[_0x1bda87('0x3c')](path[_0x1bda87('0xb')](config[_0x1bda87('0x46')],'files/templates/context.ejs'),'utf8'),_0x5145be=ejs[_0x1bda87('0x26')](_0x28a48c,{'contexts':_0x8665b4||[]});fs[_0x1bda87('0x34')](_0x1bda87('0x44'),_0x5145be);})[_0x202003('0x29')](function(){const _0x2d83cd=_0x202003;return respondWithRpcPromise(_0x2d83cd('0x28'),_0x2d83cd('0x1'),{'module':_0x2d83cd('0x53')});})['then'](function(){const _0x226779=_0x202003,_0x5d434a=_0x25cbd3[_0x226779('0x35')]['get']({'plain':!![]});if(!_0x5d434a)throw new Error(_0x226779('0x19'));if(_0x5d434a[_0x226779('0x42')]===_0x226779('0x35')){const _0x5e489a=_0x224e8f[_0x226779('0x2e')]({'plain':!![]});return db[_0x226779('0x4d')]['findOne']({'where':{'name':_0x226779('0xe'),'userProfileId':_0x5d434a[_0x226779('0x56')]},'raw':!![]})['then'](function(_0x1483af){const _0xb6f8f1=_0x226779;return _0x1483af&&_0x1483af[_0xb6f8f1('0x33')]===0x0?db[_0xb6f8f1('0x14')][_0xb6f8f1('0x1')]({'name':_0x5e489a['name'],'resourceId':_0x5e489a['id'],'type':_0x1483af[_0xb6f8f1('0x39')],'sectionId':_0x1483af['id']},{})[_0xb6f8f1('0x29')](function(){return _0x224e8f;}):_0x224e8f;})[_0x226779('0x23')](function(_0xe32c0){const _0x2cba6e=_0x226779;logger[_0x2cba6e('0x31')](_0x2cba6e('0x2a'),_0xe32c0);throw _0xe32c0;});}return _0x224e8f;})[_0x202003('0x29')](respondWithResult(_0x1f65cd,0xc9))['catch'](handleError(_0x1f65cd,null));},exports[_0x5bad73('0x55')]=function(_0x2cab1a,_0x5035ac){const _0x347600=_0x5bad73;let _0x262e7e;return db['VoiceContext'][_0x347600('0x4')]({'where':{'id':_0x2cab1a[_0x347600('0x4e')]['id']}})[_0x347600('0x29')](handleEntityNotFound(_0x5035ac,null))[_0x347600('0x29')](saveUpdates(_0x2cab1a[_0x347600('0x11')],null))[_0x347600('0x29')](function(_0x271aa2){const _0x167e64=_0x347600;if(_0x271aa2)return _0x262e7e=_0x271aa2,db[_0x167e64('0x2c')]['findAll']({'raw':!![]});})[_0x347600('0x29')](function(_0x40756a){const _0x3b10fe=_0x347600,_0x377c6f=fs[_0x3b10fe('0x3c')](path[_0x3b10fe('0xb')](config['root'],_0x3b10fe('0x24')),'utf8'),_0x444967=ejs[_0x3b10fe('0x26')](_0x377c6f,{'contexts':_0x40756a||[]});fs['writeFileSync'](_0x3b10fe('0x44'),_0x444967);})[_0x347600('0x29')](function(){const _0x2b6c53=_0x347600;return respondWithRpcPromise('Reload',_0x2b6c53('0x55'),{'module':_0x2b6c53('0x53')});})[_0x347600('0x29')](function(){return _0x262e7e;})[_0x347600('0x29')](respondWithResult(_0x5035ac,null))['catch'](handleError(_0x5035ac,null));},exports[_0x5bad73('0xf')]=function(_0x141506,_0x452901){const _0x5c7ba2=_0x5bad73;return db[_0x5c7ba2('0x2c')][_0x5c7ba2('0x4')]({'where':{'id':_0x141506[_0x5c7ba2('0x4e')]['id']}})[_0x5c7ba2('0x29')](handleEntityNotFound(_0x452901,null))['then'](removeEntity(_0x452901,null))[_0x5c7ba2('0x29')](function(){const _0x5ad5c9=_0x5c7ba2;return db[_0x5ad5c9('0x2c')][_0x5ad5c9('0x2')]({'raw':!![]});})['then'](function(_0x4e2aa5){const _0xf85097=_0x5c7ba2,_0x10a8d8=fs[_0xf85097('0x3c')](path[_0xf85097('0xb')](config[_0xf85097('0x46')],_0xf85097('0x24')),_0xf85097('0x49')),_0x40723d=ejs[_0xf85097('0x26')](_0x10a8d8,{'contexts':_0x4e2aa5});return fs[_0xf85097('0x34')](_0xf85097('0x44'),_0x40723d),respondWithRpcPromise(_0xf85097('0x28'),'destroy',{'module':'chan_sip.so'});})['catch'](handleError(_0x452901,null));}; \ No newline at end of file +const a718_0x2355=['Content-Range','http','chan_sip.so','user','update','sequelize','length','../../config/logger','fields','writeFileSync','offset','rawAttributes','filter','findOne','Reload','name','readFileSync','json','include','../../components/parsers/qs','VoiceContext,\x20%s,\x20%s','stringify','code','userProfileId','api','set','error','show','includeAll','body','sendStatus','role','send','options','join','Unable\x20to\x20retrieve\x20the\x20current\x20user','render','Contexts','destroy','ejs','limit','get','end','create','merge','files/templates/context.ejs','intersection','request\x20sent','autoAssociation','findAll','then','info','type','../../mysqldb','catch','model','map','params','query','jayson/promise','index','stack','VoiceContext','sort','count','/etc/asterisk/extensions_xcally_contexts.conf','root','utf8','like','../../config/environment','result','order','rows','status','undefined','key','where','filters','attributes','keys','message'];(function(_0x32fad3,_0x235551){const _0x520654=function(_0x20bf89){while(--_0x20bf89){_0x32fad3['push'](_0x32fad3['shift']());}};_0x520654(++_0x235551);}(a718_0x2355,0xc0));const a718_0x5206=function(_0x32fad3,_0x235551){_0x32fad3=_0x32fad3-0x0;let _0x520654=a718_0x2355[_0x32fad3];return _0x520654;};const _0xf3982a=a718_0x5206;'use strict';const path=require('path'),ejs=require(_0xf3982a('0x9')),fs=require('fs'),_=require('lodash'),qs=require(_0xf3982a('0x46')),logger=require(_0xf3982a('0x3a'))(_0xf3982a('0x4b')),config=require(_0xf3982a('0x27')),db=require(_0xf3982a('0x17'))['db'],{Op}=require(_0xf3982a('0x38')),jayson=require(_0xf3982a('0x1d')),client=jayson['client'][_0xf3982a('0x34')]({'port':0x232a});function respondWithRpcPromise(_0x20bf89,_0x28365a,_0x95c456,_0x115433){return new Promise(function(_0x52a3c2,_0x79ff3a){const _0x17b230=a718_0x5206,_0x2eaf9c=_0x115433||client;return _0x2eaf9c['request'](_0x20bf89,_0x95c456)[_0x17b230('0x14')](function(_0x597e88){const _0x342750=_0x17b230;logger[_0x342750('0x15')](_0x342750('0x47'),_0x28365a,_0x342750('0x11')),logger['debug']('VoiceContext,\x20%s,\x20%s,\x20%s',_0x28365a,'request\x20sent',JSON[_0x342750('0x48')](_0x597e88));if(_0x597e88[_0x342750('0x4d')]){if(_0x597e88[_0x342750('0x4d')][_0x342750('0x49')]===0x1f4)return logger[_0x342750('0x4d')](_0x342750('0x47'),_0x28365a,_0x597e88[_0x342750('0x4d')][_0x342750('0x32')]),_0x79ff3a(_0x597e88[_0x342750('0x4d')]['message']);return logger[_0x342750('0x4d')](_0x342750('0x47'),_0x28365a,_0x597e88[_0x342750('0x4d')][_0x342750('0x32')]),_0x52a3c2(_0x597e88[_0x342750('0x4d')][_0x342750('0x32')]);}else logger[_0x342750('0x15')]('VoiceContext,\x20%s,\x20%s',_0x28365a,_0x342750('0x11')),_0x52a3c2(_0x597e88[_0x342750('0x28')][_0x342750('0x32')]);})[_0x17b230('0x18')](function(_0x4d221f){const _0x5f45c7=_0x17b230;logger[_0x5f45c7('0x4d')](_0x5f45c7('0x47'),_0x28365a,_0x4d221f),_0x79ff3a(_0x4d221f);});});}function respondWithResult(_0x12a3fb,_0x10d7f0){return _0x10d7f0=_0x10d7f0||0xc8,function(_0x104536){const _0x198409=a718_0x5206;if(_0x104536)return _0x12a3fb[_0x198409('0x2b')](_0x10d7f0)[_0x198409('0x44')](_0x104536);};}function respondWithFilteredResult(_0x2c118f,_0xdd09a7){return function(_0x42aa16){const _0x2d3a7f=a718_0x5206;if(_0x42aa16){const _0x59e4fd=_0x42aa16[_0x2d3a7f('0x22')],_0x712fee=_0xdd09a7['offset'];let _0x37c8c7=_0xdd09a7[_0x2d3a7f('0x3d')]+_0xdd09a7['limit'],_0x4c0099;return _0x37c8c7>=_0x59e4fd?(_0x37c8c7=_0x59e4fd,_0x4c0099=0xc8):_0x4c0099=0xce,_0x2c118f[_0x2d3a7f('0x2b')](_0x4c0099),_0x2c118f[_0x2d3a7f('0x4c')](_0x2d3a7f('0x33'),_0x712fee+'-'+_0x37c8c7+'/'+_0x59e4fd)[_0x2d3a7f('0x44')](_0x42aa16);}return null;};}function saveUpdates(_0x3355c2){return function(_0x46cf78){const _0x2b46a9=a718_0x5206;if(_0x46cf78)return _0x46cf78['update'](_0x3355c2)[_0x2b46a9('0x14')](function(_0x30fbc7){return _0x30fbc7;});return null;};}function removeEntity(_0x2bf9f0){return function(_0x53c64f){const _0xd2e9b=a718_0x5206;if(_0x53c64f)return _0x53c64f[_0xd2e9b('0x8')]()['then'](function(){const _0x2eea43=_0xd2e9b,_0x3d8fa3=_0x53c64f[_0x2eea43('0xb')]({'plain':!![]}),_0x2cb691=_0x2eea43('0x7');return db['UserProfileResource'][_0x2eea43('0x8')]({'where':{'type':_0x2cb691,'resourceId':_0x3d8fa3['id']}})[_0x2eea43('0x14')](function(){return _0x53c64f;});})[_0xd2e9b('0x14')](function(){const _0x58c93c=_0xd2e9b;_0x2bf9f0[_0x58c93c('0x2b')](0xcc)[_0x58c93c('0xc')]();});};}function handleEntityNotFound(_0x43fc77){return function(_0x110798){const _0x35511d=a718_0x5206;return!_0x110798&&_0x43fc77[_0x35511d('0x0')](0x194),_0x110798;};}function handleError(_0x55a4a6,_0x26928b){return _0x26928b=_0x26928b||0x1f4,function(_0x540044){const _0x212a9a=a718_0x5206;logger['error'](_0x540044[_0x212a9a('0x1f')]),_0x540044['name']&&delete _0x540044[_0x212a9a('0x42')],_0x55a4a6['status'](_0x26928b)[_0x212a9a('0x2')](_0x540044);};}exports[_0xf3982a('0x1e')]=function(_0x4d350f,_0x35517f){const _0x1faac1=_0xf3982a;let _0x458674={};const _0x596738={},_0x30e560={'count':0x0,'rows':[]},_0x53d2ee=_[_0x1faac1('0x1a')](db[_0x1faac1('0x20')][_0x1faac1('0x3e')],function(_0x2493fe){const _0x2728a7=_0x1faac1;return{'name':_0x2493fe['fieldName'],'type':_0x2493fe['type'][_0x2728a7('0x2d')]};});_0x596738[_0x1faac1('0x19')]=_[_0x1faac1('0x1a')](_0x53d2ee,_0x1faac1('0x42')),_0x596738[_0x1faac1('0x1c')]=_[_0x1faac1('0x31')](_0x4d350f[_0x1faac1('0x1c')]),_0x596738[_0x1faac1('0x2f')]=_[_0x1faac1('0x10')](_0x596738['model'],_0x596738[_0x1faac1('0x1c')]),_0x458674[_0x1faac1('0x30')]=_[_0x1faac1('0x10')](_0x596738[_0x1faac1('0x19')],qs[_0x1faac1('0x3b')](_0x4d350f[_0x1faac1('0x1c')][_0x1faac1('0x3b')])),_0x458674[_0x1faac1('0x30')]=_0x458674[_0x1faac1('0x30')][_0x1faac1('0x39')]?_0x458674[_0x1faac1('0x30')]:_0x596738[_0x1faac1('0x19')];typeof _0x4d350f[_0x1faac1('0x1c')]['nolimit']===_0x1faac1('0x2c')&&(_0x458674[_0x1faac1('0xa')]=qs[_0x1faac1('0xa')](_0x4d350f[_0x1faac1('0x1c')][_0x1faac1('0xa')]),_0x458674[_0x1faac1('0x3d')]=qs[_0x1faac1('0x3d')](_0x4d350f[_0x1faac1('0x1c')][_0x1faac1('0x3d')]));_0x458674[_0x1faac1('0x29')]=qs[_0x1faac1('0x21')](_0x4d350f[_0x1faac1('0x1c')][_0x1faac1('0x21')]),_0x458674['where']=qs['filters'](_['pick'](_0x4d350f[_0x1faac1('0x1c')],_0x596738[_0x1faac1('0x2f')]),_0x53d2ee);_0x4d350f[_0x1faac1('0x1c')][_0x1faac1('0x3f')]&&(_0x458674[_0x1faac1('0x2e')]=_[_0x1faac1('0xe')](_0x458674[_0x1faac1('0x2e')],{[Op['or']]:_[_0x1faac1('0x1a')](_0x53d2ee,function(_0x5e9953){const _0x39a1de=_0x1faac1;if(_0x5e9953[_0x39a1de('0x16')]!=='VIRTUAL'){const _0x3a55db={};return _0x3a55db[_0x5e9953[_0x39a1de('0x42')]]={[Op[_0x39a1de('0x26')]]:'%'+_0x4d350f[_0x39a1de('0x1c')][_0x39a1de('0x3f')]+'%'},_0x3a55db;}})}));_0x458674=_['merge']({},_0x458674,_0x4d350f[_0x1faac1('0x3')]);const _0x263799={'where':_0x458674['where']};return db[_0x1faac1('0x20')][_0x1faac1('0x22')](_0x263799)[_0x1faac1('0x14')](function(_0x2f7e7f){const _0x46330b=_0x1faac1;return _0x30e560['count']=_0x2f7e7f,_0x4d350f[_0x46330b('0x1c')][_0x46330b('0x4f')]&&(_0x458674[_0x46330b('0x45')]=[{'all':!![]}]),db[_0x46330b('0x20')][_0x46330b('0x13')](_0x458674);})[_0x1faac1('0x14')](function(_0x43ddcf){const _0x5d1f73=_0x1faac1;return _0x30e560[_0x5d1f73('0x2a')]=_0x43ddcf,_0x30e560;})['then'](respondWithFilteredResult(_0x35517f,_0x458674))[_0x1faac1('0x18')](handleError(_0x35517f,null));},exports[_0xf3982a('0x4e')]=function(_0x383646,_0x56f0bc){const _0x308414=_0xf3982a;let _0x4d0d68={'raw':![],'where':{'id':_0x383646[_0x308414('0x1b')]['id']}};const _0xffc953={};return _0xffc953[_0x308414('0x19')]=_['keys'](db[_0x308414('0x20')][_0x308414('0x3e')]),_0xffc953[_0x308414('0x1c')]=_[_0x308414('0x31')](_0x383646['query']),_0xffc953[_0x308414('0x2f')]=_['intersection'](_0xffc953[_0x308414('0x19')],_0xffc953[_0x308414('0x1c')]),_0x4d0d68[_0x308414('0x30')]=_[_0x308414('0x10')](_0xffc953['model'],qs[_0x308414('0x3b')](_0x383646['query'][_0x308414('0x3b')])),_0x4d0d68['attributes']=_0x4d0d68[_0x308414('0x30')]['length']?_0x4d0d68[_0x308414('0x30')]:_0xffc953[_0x308414('0x19')],_0x383646[_0x308414('0x1c')]['includeAll']&&(_0x4d0d68['include']=[{'all':!![]}]),_0x4d0d68=_[_0x308414('0xe')]({},_0x4d0d68,_0x383646[_0x308414('0x3')]),db[_0x308414('0x20')][_0x308414('0x40')](_0x4d0d68)[_0x308414('0x14')](handleEntityNotFound(_0x56f0bc,null))['then'](respondWithResult(_0x56f0bc,null))[_0x308414('0x18')](handleError(_0x56f0bc,null));},exports[_0xf3982a('0xd')]=function(_0x2919f8,_0x3b6ec7){const _0x426eab=_0xf3982a;let _0x52d7ea;return db[_0x426eab('0x20')]['create'](_0x2919f8[_0x426eab('0x50')],{'raw':!![]})['then'](function(_0x41e6a2){const _0x57e9dd=_0x426eab;return _0x52d7ea=_0x41e6a2,db[_0x57e9dd('0x20')][_0x57e9dd('0x13')]({'raw':!![]});})[_0x426eab('0x14')](function(_0x1defeb){const _0x59d14a=_0x426eab,_0x6f3630=fs[_0x59d14a('0x43')](path[_0x59d14a('0x4')](config[_0x59d14a('0x24')],'files/templates/context.ejs'),_0x59d14a('0x25')),_0x3e61a8=ejs['render'](_0x6f3630,{'contexts':_0x1defeb||[]});fs[_0x59d14a('0x3c')](_0x59d14a('0x23'),_0x3e61a8);})[_0x426eab('0x14')](function(){const _0x3fc958=_0x426eab;return respondWithRpcPromise(_0x3fc958('0x41'),_0x3fc958('0xd'),{'module':_0x3fc958('0x35')});})[_0x426eab('0x14')](function(){const _0xf48b16=_0x426eab,_0x40111b=_0x2919f8[_0xf48b16('0x36')][_0xf48b16('0xb')]({'plain':!![]});if(!_0x40111b)throw new Error(_0xf48b16('0x5'));if(_0x40111b[_0xf48b16('0x1')]===_0xf48b16('0x36')){const _0x25ab90=_0x52d7ea['get']({'plain':!![]});return db['UserProfileSection'][_0xf48b16('0x40')]({'where':{'name':'Contexts','userProfileId':_0x40111b[_0xf48b16('0x4a')]},'raw':!![]})['then'](function(_0x29972a){const _0x29f119=_0xf48b16;return _0x29972a&&_0x29972a[_0x29f119('0x12')]===0x0?db['UserProfileResource'][_0x29f119('0xd')]({'name':_0x25ab90[_0x29f119('0x42')],'resourceId':_0x25ab90['id'],'type':_0x29972a[_0x29f119('0x42')],'sectionId':_0x29972a['id']},{})[_0x29f119('0x14')](function(){return _0x52d7ea;}):_0x52d7ea;})[_0xf48b16('0x18')](function(_0x34c8af){const _0x519c98=_0xf48b16;logger[_0x519c98('0x4d')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x34c8af);throw _0x34c8af;});}return _0x52d7ea;})[_0x426eab('0x14')](respondWithResult(_0x3b6ec7,0xc9))[_0x426eab('0x18')](handleError(_0x3b6ec7,null));},exports['update']=function(_0x53d53b,_0x467bec){const _0x30ba34=_0xf3982a;let _0x978f35;return db['VoiceContext']['findOne']({'where':{'id':_0x53d53b['params']['id']}})['then'](handleEntityNotFound(_0x467bec,null))[_0x30ba34('0x14')](saveUpdates(_0x53d53b[_0x30ba34('0x50')],null))[_0x30ba34('0x14')](function(_0x2a0fa8){const _0x317fc8=_0x30ba34;if(_0x2a0fa8)return _0x978f35=_0x2a0fa8,db[_0x317fc8('0x20')][_0x317fc8('0x13')]({'raw':!![]});})[_0x30ba34('0x14')](function(_0x4cfd79){const _0x1206de=_0x30ba34,_0x2424fc=fs[_0x1206de('0x43')](path[_0x1206de('0x4')](config[_0x1206de('0x24')],_0x1206de('0xf')),_0x1206de('0x25')),_0x54dd40=ejs['render'](_0x2424fc,{'contexts':_0x4cfd79||[]});fs[_0x1206de('0x3c')](_0x1206de('0x23'),_0x54dd40);})[_0x30ba34('0x14')](function(){const _0x147010=_0x30ba34;return respondWithRpcPromise(_0x147010('0x41'),_0x147010('0x37'),{'module':'chan_sip.so'});})[_0x30ba34('0x14')](function(){return _0x978f35;})[_0x30ba34('0x14')](respondWithResult(_0x467bec,null))[_0x30ba34('0x18')](handleError(_0x467bec,null));},exports[_0xf3982a('0x8')]=function(_0x533939,_0x306493){const _0x5362e3=_0xf3982a;return db['VoiceContext'][_0x5362e3('0x40')]({'where':{'id':_0x533939[_0x5362e3('0x1b')]['id']}})['then'](handleEntityNotFound(_0x306493,null))['then'](removeEntity(_0x306493,null))[_0x5362e3('0x14')](function(){const _0x3bf734=_0x5362e3;return db[_0x3bf734('0x20')][_0x3bf734('0x13')]({'raw':!![]});})['then'](function(_0x7e0bf0){const _0x4cbd66=_0x5362e3,_0x3ce55e=fs[_0x4cbd66('0x43')](path['join'](config[_0x4cbd66('0x24')],'files/templates/context.ejs'),_0x4cbd66('0x25')),_0x734011=ejs[_0x4cbd66('0x6')](_0x3ce55e,{'contexts':_0x7e0bf0});return fs['writeFileSync'](_0x4cbd66('0x23'),_0x734011),respondWithRpcPromise(_0x4cbd66('0x41'),_0x4cbd66('0x8'),{'module':_0x4cbd66('0x35')});})[_0x5362e3('0x18')](handleError(_0x306493,null));}; \ No newline at end of file diff --git a/server/api/voiceContext/voiceContext.model.js b/server/api/voiceContext/voiceContext.model.js index dc37fc2..2a5332c 100644 --- a/server/api/voiceContext/voiceContext.model.js +++ b/server/api/voiceContext/voiceContext.model.js @@ -1 +1 @@ -const a719_0x2119=['VoiceContext','define','./voiceContext.attributes','exports'];(function(_0x2065d5,_0x211991){const _0x8f44ab=function(_0x1582f2){while(--_0x1582f2){_0x2065d5['push'](_0x2065d5['shift']());}};_0x8f44ab(++_0x211991);}(a719_0x2119,0x13b));const a719_0x8f44=function(_0x2065d5,_0x211991){_0x2065d5=_0x2065d5-0x0;let _0x8f44ab=a719_0x2119[_0x2065d5];return _0x8f44ab;};const _0x36a95e=a719_0x8f44;'use strict';const attributes=require(_0x36a95e('0x3'));module[_0x36a95e('0x0')]=function(_0x1582f2){const _0x11fc89=_0x36a95e,_0x31be0d=_0x1582f2[_0x11fc89('0x2')](_0x11fc89('0x1'),attributes,{'tableName':'voice_contexts','paranoid':![],'indexes':[],'timestamps':!![]});return _0x31be0d;}; \ No newline at end of file +const a719_0x5982=['voice_contexts','./voiceContext.attributes','VoiceContext','define','exports'];(function(_0x10b5ec,_0x598236){const _0x1fc8e5=function(_0x5b88ef){while(--_0x5b88ef){_0x10b5ec['push'](_0x10b5ec['shift']());}};_0x1fc8e5(++_0x598236);}(a719_0x5982,0x16c));const a719_0x1fc8=function(_0x10b5ec,_0x598236){_0x10b5ec=_0x10b5ec-0x0;let _0x1fc8e5=a719_0x5982[_0x10b5ec];return _0x1fc8e5;};const _0x3e45ec=a719_0x1fc8;'use strict';const attributes=require(_0x3e45ec('0x2'));module[_0x3e45ec('0x0')]=function(_0x5b88ef){const _0x46cfbc=_0x3e45ec,_0x3a6d99=_0x5b88ef[_0x46cfbc('0x4')](_0x46cfbc('0x3'),attributes,{'tableName':_0x46cfbc('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x3a6d99;}; \ No newline at end of file diff --git a/server/api/voiceDialReport/index.js b/server/api/voiceDialReport/index.js index a36ea3b..254a142 100644 --- a/server/api/voiceDialReport/index.js +++ b/server/api/voiceDialReport/index.js @@ -1 +1 @@ -const a720_0x5744=['put','exports','/:id','get','delete','express','destroy','index','create','Router','update','show','./voiceDialReport.controller','isAuthenticated','/describe','../../components/auth/service'];(function(_0xb37ec3,_0x5744da){const _0x2ab350=function(_0x20e861){while(--_0x20e861){_0xb37ec3['push'](_0xb37ec3['shift']());}};_0x2ab350(++_0x5744da);}(a720_0x5744,0x12d));const a720_0x2ab3=function(_0xb37ec3,_0x5744da){_0xb37ec3=_0xb37ec3-0x0;let _0x2ab350=a720_0x5744[_0xb37ec3];return _0x2ab350;};const _0x45d959=a720_0x2ab3;'use strict';const express=require(_0x45d959('0x8')),router=express[_0x45d959('0xc')](),auth=require(_0x45d959('0x2')),controller=require(_0x45d959('0xf'));router[_0x45d959('0x6')]('/',auth[_0x45d959('0x0')](),controller[_0x45d959('0xa')]),router[_0x45d959('0x6')](_0x45d959('0x1'),auth[_0x45d959('0x0')](),controller['describe']),router['get'](_0x45d959('0x5'),auth['isAuthenticated'](),controller[_0x45d959('0xe')]),router['post']('/',auth[_0x45d959('0x0')](),controller[_0x45d959('0xb')]),router[_0x45d959('0x3')](_0x45d959('0x5'),auth['isAuthenticated'](),controller[_0x45d959('0xd')]),router[_0x45d959('0x7')](_0x45d959('0x5'),auth[_0x45d959('0x0')](),controller[_0x45d959('0x9')]),module[_0x45d959('0x4')]=router; \ No newline at end of file +const a720_0x4013=['create','/:id','put','Router','delete','get','express','isAuthenticated','../../components/auth/service','show','./voiceDialReport.controller','/describe','post'];(function(_0x4687f6,_0x401360){const _0x4bf2b4=function(_0x6c6a24){while(--_0x6c6a24){_0x4687f6['push'](_0x4687f6['shift']());}};_0x4bf2b4(++_0x401360);}(a720_0x4013,0x17b));const a720_0x4bf2=function(_0x4687f6,_0x401360){_0x4687f6=_0x4687f6-0x0;let _0x4bf2b4=a720_0x4013[_0x4687f6];return _0x4bf2b4;};const _0x494198=a720_0x4bf2;'use strict';const express=require(_0x494198('0x4')),router=express[_0x494198('0x1')](),auth=require(_0x494198('0x6')),controller=require(_0x494198('0x8'));router[_0x494198('0x3')]('/',auth[_0x494198('0x5')](),controller['index']),router[_0x494198('0x3')](_0x494198('0x9'),auth[_0x494198('0x5')](),controller['describe']),router[_0x494198('0x3')](_0x494198('0xc'),auth[_0x494198('0x5')](),controller[_0x494198('0x7')]),router[_0x494198('0xa')]('/',auth[_0x494198('0x5')](),controller[_0x494198('0xb')]),router[_0x494198('0x0')]('/:id',auth[_0x494198('0x5')](),controller['update']),router[_0x494198('0x2')](_0x494198('0xc'),auth[_0x494198('0x5')](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/voiceDialReport/voiceDialReport.attributes.js b/server/api/voiceDialReport/voiceDialReport.attributes.js index 3f57a97..76db79c 100644 --- a/server/api/voiceDialReport/voiceDialReport.attributes.js +++ b/server/api/voiceDialReport/voiceDialReport.attributes.js @@ -1 +1 @@ -const a721_0x488e=['DATE','called,connect,complete','STRING','INTEGER'];(function(_0x2822fd,_0x488e22){const _0x2b7534=function(_0x518c87){while(--_0x518c87){_0x2822fd['push'](_0x2822fd['shift']());}};_0x2b7534(++_0x488e22);}(a721_0x488e,0x1b2));const a721_0x2b75=function(_0x2822fd,_0x488e22){_0x2822fd=_0x2822fd-0x0;let _0x2b7534=a721_0x488e[_0x2822fd];return _0x2b7534;};const _0x5c1686=a721_0x2b75;'use strict';const Sequelize=require('sequelize');module['exports']={'privilege':{'type':Sequelize[_0x5c1686('0x0')]},'channel':{'type':Sequelize[_0x5c1686('0x0')]},'channelstate':{'type':Sequelize[_0x5c1686('0x1')]},'channelstatedesc':{'type':Sequelize[_0x5c1686('0x0')]},'calleridnum':{'type':Sequelize[_0x5c1686('0x0')]},'calleridname':{'type':Sequelize[_0x5c1686('0x0')]},'connectedlinenum':{'type':Sequelize[_0x5c1686('0x0')]},'connectedlinename':{'type':Sequelize[_0x5c1686('0x0')]},'language':{'type':Sequelize[_0x5c1686('0x0')]},'accountcode':{'type':Sequelize[_0x5c1686('0x0')]},'context':{'type':Sequelize['STRING']},'exten':{'type':Sequelize[_0x5c1686('0x0')]},'priority':{'type':Sequelize['INTEGER']},'uniqueid':{'type':Sequelize[_0x5c1686('0x0')]},'linkedid':{'type':Sequelize['STRING']},'destchannel':{'type':Sequelize['STRING']},'destchannelstate':{'type':Sequelize[_0x5c1686('0x1')]},'destchannelstatedesc':{'type':Sequelize[_0x5c1686('0x0')]},'destcalleridnum':{'type':Sequelize[_0x5c1686('0x0')]},'destcalleridname':{'type':Sequelize[_0x5c1686('0x0')]},'destconnectedlinenum':{'type':Sequelize[_0x5c1686('0x0')]},'destconnectedlinename':{'type':Sequelize[_0x5c1686('0x0')]},'destlanguage':{'type':Sequelize[_0x5c1686('0x0')]},'destaccountcode':{'type':Sequelize[_0x5c1686('0x0')]},'destcontext':{'type':Sequelize[_0x5c1686('0x0')]},'destexten':{'type':Sequelize[_0x5c1686('0x0')]},'destpriority':{'type':Sequelize[_0x5c1686('0x1')]},'destuniqueid':{'type':Sequelize['STRING']},'destlinkedid':{'type':Sequelize['STRING']},'dialstring':{'type':Sequelize[_0x5c1686('0x0')]},'dialstatus':{'type':Sequelize[_0x5c1686('0x0')]},'starttime':{'type':Sequelize[_0x5c1686('0x2')]},'answertime':{'type':Sequelize[_0x5c1686('0x2')]},'endtime':{'type':Sequelize[_0x5c1686('0x2')]},'lastevent':{'type':Sequelize[_0x5c1686('0x0')],'comment':_0x5c1686('0x3')},'routeId':{'type':Sequelize[_0x5c1686('0x1')]},'duration':{'type':Sequelize[_0x5c1686('0x1')]},'holdtime':{'type':Sequelize['INTEGER']},'billableseconds':{'type':Sequelize[_0x5c1686('0x1')]}}; \ No newline at end of file +const a721_0x50e8=['exports','called,connect,complete','STRING','sequelize','DATE','INTEGER'];(function(_0x2df72c,_0x50e8fc){const _0x5893f5=function(_0xfe41f5){while(--_0xfe41f5){_0x2df72c['push'](_0x2df72c['shift']());}};_0x5893f5(++_0x50e8fc);}(a721_0x50e8,0x178));const a721_0x5893=function(_0x2df72c,_0x50e8fc){_0x2df72c=_0x2df72c-0x0;let _0x5893f5=a721_0x50e8[_0x2df72c];return _0x5893f5;};const _0x3dff5a=a721_0x5893;'use strict';const Sequelize=require(_0x3dff5a('0x5'));module[_0x3dff5a('0x2')]={'privilege':{'type':Sequelize[_0x3dff5a('0x4')]},'channel':{'type':Sequelize['STRING']},'channelstate':{'type':Sequelize[_0x3dff5a('0x1')]},'channelstatedesc':{'type':Sequelize['STRING']},'calleridnum':{'type':Sequelize[_0x3dff5a('0x4')]},'calleridname':{'type':Sequelize[_0x3dff5a('0x4')]},'connectedlinenum':{'type':Sequelize['STRING']},'connectedlinename':{'type':Sequelize[_0x3dff5a('0x4')]},'language':{'type':Sequelize['STRING']},'accountcode':{'type':Sequelize[_0x3dff5a('0x4')]},'context':{'type':Sequelize[_0x3dff5a('0x4')]},'exten':{'type':Sequelize[_0x3dff5a('0x4')]},'priority':{'type':Sequelize[_0x3dff5a('0x1')]},'uniqueid':{'type':Sequelize[_0x3dff5a('0x4')]},'linkedid':{'type':Sequelize[_0x3dff5a('0x4')]},'destchannel':{'type':Sequelize[_0x3dff5a('0x4')]},'destchannelstate':{'type':Sequelize[_0x3dff5a('0x1')]},'destchannelstatedesc':{'type':Sequelize['STRING']},'destcalleridnum':{'type':Sequelize[_0x3dff5a('0x4')]},'destcalleridname':{'type':Sequelize[_0x3dff5a('0x4')]},'destconnectedlinenum':{'type':Sequelize['STRING']},'destconnectedlinename':{'type':Sequelize['STRING']},'destlanguage':{'type':Sequelize[_0x3dff5a('0x4')]},'destaccountcode':{'type':Sequelize['STRING']},'destcontext':{'type':Sequelize[_0x3dff5a('0x4')]},'destexten':{'type':Sequelize['STRING']},'destpriority':{'type':Sequelize[_0x3dff5a('0x1')]},'destuniqueid':{'type':Sequelize[_0x3dff5a('0x4')]},'destlinkedid':{'type':Sequelize[_0x3dff5a('0x4')]},'dialstring':{'type':Sequelize[_0x3dff5a('0x4')]},'dialstatus':{'type':Sequelize[_0x3dff5a('0x4')]},'starttime':{'type':Sequelize[_0x3dff5a('0x0')]},'answertime':{'type':Sequelize[_0x3dff5a('0x0')]},'endtime':{'type':Sequelize[_0x3dff5a('0x0')]},'lastevent':{'type':Sequelize[_0x3dff5a('0x4')],'comment':_0x3dff5a('0x3')},'routeId':{'type':Sequelize['INTEGER']},'duration':{'type':Sequelize[_0x3dff5a('0x1')]},'holdtime':{'type':Sequelize['INTEGER']},'billableseconds':{'type':Sequelize[_0x3dff5a('0x1')]}}; \ No newline at end of file diff --git a/server/api/voiceDialReport/voiceDialReport.controller.js b/server/api/voiceDialReport/voiceDialReport.controller.js index bbec90b..25cdb06 100644 --- a/server/api/voiceDialReport/voiceDialReport.controller.js +++ b/server/api/voiceDialReport/voiceDialReport.controller.js @@ -1 +1 @@ -const a722_0x5b49=['includeAll','stack','intersection','rawAttributes','json','fieldName','count','show','describe','VIRTUAL','rows','end','key','sequelize','query','order','merge','send','attributes','lodash','map','keys','create','length','findOne','../../config/logger','destroy','catch','params','then','name','error','status','sort','undefined','type','sendStatus','include','offset','body','VoiceDialReport','limit','pick','model','options','filter','filters','fields','where','set','Content-Range'];(function(_0x79e4fa,_0x5b49ca){const _0x3ec2ed=function(_0x44bcfe){while(--_0x44bcfe){_0x79e4fa['push'](_0x79e4fa['shift']());}};_0x3ec2ed(++_0x5b49ca);}(a722_0x5b49,0x179));const a722_0x3ec2=function(_0x79e4fa,_0x5b49ca){_0x79e4fa=_0x79e4fa-0x0;let _0x3ec2ed=a722_0x5b49[_0x79e4fa];return _0x3ec2ed;};const _0x2b8652=a722_0x3ec2;'use strict';const _=require(_0x2b8652('0x32')),qs=require('../../components/parsers/qs'),logger=require(_0x2b8652('0x5'))('api'),db=require('../../mysqldb')['db'],{Op}=require(_0x2b8652('0x2c'));function respondWithResult(_0x44bcfe,_0x40f4a9){return _0x40f4a9=_0x40f4a9||0xc8,function(_0x13ffe8){const _0x5770ba=a722_0x3ec2;if(_0x13ffe8)return _0x44bcfe[_0x5770ba('0xc')](_0x40f4a9)[_0x5770ba('0x23')](_0x13ffe8);};}function respondWithFilteredResult(_0x498739,_0x1ceceb){return function(_0x148253){const _0xb4f1c3=a722_0x3ec2;if(_0x148253){const _0x428695=_0x148253['count'],_0x7e18bc=_0x1ceceb[_0xb4f1c3('0x12')];let _0xb8d444=_0x1ceceb[_0xb4f1c3('0x12')]+_0x1ceceb[_0xb4f1c3('0x15')],_0x11871d;return _0xb8d444>=_0x428695?(_0xb8d444=_0x428695,_0x11871d=0xc8):_0x11871d=0xce,_0x498739[_0xb4f1c3('0xc')](_0x11871d),_0x498739[_0xb4f1c3('0x1d')](_0xb4f1c3('0x1e'),_0x7e18bc+'-'+_0xb8d444+'/'+_0x428695)[_0xb4f1c3('0x23')](_0x148253);}return null;};}function saveUpdates(_0x25ff59){return function(_0x2065d4){const _0x574bec=a722_0x3ec2;if(_0x2065d4)return _0x2065d4['update'](_0x25ff59)[_0x574bec('0x9')](function(_0x4fe7e5){return _0x4fe7e5;});return null;};}function removeEntity(_0x2531dd){return function(_0x526170){const _0x35e548=a722_0x3ec2;if(_0x526170)return _0x526170['destroy']()[_0x35e548('0x9')](function(){const _0xb593c6=_0x35e548;_0x2531dd['status'](0xcc)[_0xb593c6('0x2a')]();});};}function handleEntityNotFound(_0x223987){return function(_0x4e68a0){const _0x104328=a722_0x3ec2;return!_0x4e68a0&&_0x223987[_0x104328('0x10')](0x194),_0x4e68a0;};}function handleError(_0x3b89c4,_0x3ee0d0){return _0x3ee0d0=_0x3ee0d0||0x1f4,function(_0x59b491){const _0xd265ca=a722_0x3ec2;logger[_0xd265ca('0xb')](_0x59b491[_0xd265ca('0x20')]),_0x59b491[_0xd265ca('0xa')]&&delete _0x59b491[_0xd265ca('0xa')],_0x3b89c4[_0xd265ca('0xc')](_0x3ee0d0)[_0xd265ca('0x30')](_0x59b491);};}exports['index']=function(_0x1decc7,_0x21ee88){const _0x2db050=_0x2b8652;let _0x549a58={};const _0x34d897={},_0x29f6f8={'count':0x0,'rows':[]},_0x3e6e47=_[_0x2db050('0x0')](db[_0x2db050('0x14')][_0x2db050('0x22')],function(_0x21761e){const _0x5b6ebd=_0x2db050;return{'name':_0x21761e[_0x5b6ebd('0x24')],'type':_0x21761e[_0x5b6ebd('0xf')][_0x5b6ebd('0x2b')]};});_0x34d897[_0x2db050('0x17')]=_[_0x2db050('0x0')](_0x3e6e47,_0x2db050('0xa')),_0x34d897[_0x2db050('0x2d')]=_[_0x2db050('0x1')](_0x1decc7['query']),_0x34d897['filters']=_[_0x2db050('0x21')](_0x34d897[_0x2db050('0x17')],_0x34d897[_0x2db050('0x2d')]),_0x549a58[_0x2db050('0x31')]=_[_0x2db050('0x21')](_0x34d897[_0x2db050('0x17')],qs[_0x2db050('0x1b')](_0x1decc7[_0x2db050('0x2d')][_0x2db050('0x1b')])),_0x549a58[_0x2db050('0x31')]=_0x549a58[_0x2db050('0x31')][_0x2db050('0x3')]?_0x549a58[_0x2db050('0x31')]:_0x34d897['model'];typeof _0x1decc7[_0x2db050('0x2d')]['nolimit']===_0x2db050('0xe')&&(_0x549a58[_0x2db050('0x15')]=qs['limit'](_0x1decc7[_0x2db050('0x2d')][_0x2db050('0x15')]),_0x549a58[_0x2db050('0x12')]=qs[_0x2db050('0x12')](_0x1decc7[_0x2db050('0x2d')][_0x2db050('0x12')]));_0x549a58[_0x2db050('0x2e')]=qs[_0x2db050('0xd')](_0x1decc7['query'][_0x2db050('0xd')]),_0x549a58[_0x2db050('0x1c')]=qs[_0x2db050('0x1a')](_[_0x2db050('0x16')](_0x1decc7[_0x2db050('0x2d')],_0x34d897['filters']),_0x3e6e47);_0x1decc7[_0x2db050('0x2d')]['filter']&&(_0x549a58[_0x2db050('0x1c')]=_[_0x2db050('0x2f')](_0x549a58['where'],{[Op['or']]:_[_0x2db050('0x0')](_0x3e6e47,function(_0x35f34b){const _0x447e93=_0x2db050;if(_0x35f34b[_0x447e93('0xf')]!==_0x447e93('0x28')){const _0x3458be={};return _0x3458be[_0x35f34b[_0x447e93('0xa')]]={[Op['like']]:'%'+_0x1decc7[_0x447e93('0x2d')][_0x447e93('0x19')]+'%'},_0x3458be;}})}));_0x549a58=_['merge']({},_0x549a58,_0x1decc7['options']);const _0x18c69b={'where':_0x549a58[_0x2db050('0x1c')]};return db[_0x2db050('0x14')][_0x2db050('0x25')](_0x18c69b)[_0x2db050('0x9')](function(_0x3658df){const _0x21fe5a=_0x2db050;return _0x29f6f8['count']=_0x3658df,_0x1decc7[_0x21fe5a('0x2d')][_0x21fe5a('0x1f')]&&(_0x549a58[_0x21fe5a('0x11')]=[{'all':!![]}]),db[_0x21fe5a('0x14')]['findAll'](_0x549a58);})[_0x2db050('0x9')](function(_0x1a6e71){const _0xfdc222=_0x2db050;return _0x29f6f8[_0xfdc222('0x29')]=_0x1a6e71,_0x29f6f8;})['then'](respondWithFilteredResult(_0x21ee88,_0x549a58))[_0x2db050('0x7')](handleError(_0x21ee88,null));},exports[_0x2b8652('0x26')]=function(_0xa74fcd,_0x53eac0){const _0x178692=_0x2b8652;let _0x41dc4e={'raw':!![],'where':{'id':_0xa74fcd[_0x178692('0x8')]['id']}};const _0x1bc81b={};return _0x1bc81b['model']=_['keys'](db[_0x178692('0x14')][_0x178692('0x22')]),_0x1bc81b[_0x178692('0x2d')]=_[_0x178692('0x1')](_0xa74fcd['query']),_0x1bc81b[_0x178692('0x1a')]=_[_0x178692('0x21')](_0x1bc81b[_0x178692('0x17')],_0x1bc81b[_0x178692('0x2d')]),_0x41dc4e[_0x178692('0x31')]=_[_0x178692('0x21')](_0x1bc81b[_0x178692('0x17')],qs[_0x178692('0x1b')](_0xa74fcd['query']['fields'])),_0x41dc4e['attributes']=_0x41dc4e[_0x178692('0x31')][_0x178692('0x3')]?_0x41dc4e[_0x178692('0x31')]:_0x1bc81b[_0x178692('0x17')],_0xa74fcd['query'][_0x178692('0x1f')]&&(_0x41dc4e[_0x178692('0x11')]=[{'all':!![]}]),_0x41dc4e=_[_0x178692('0x2f')]({},_0x41dc4e,_0xa74fcd[_0x178692('0x18')]),db['VoiceDialReport'][_0x178692('0x4')](_0x41dc4e)[_0x178692('0x9')](handleEntityNotFound(_0x53eac0,null))[_0x178692('0x9')](respondWithResult(_0x53eac0,null))[_0x178692('0x7')](handleError(_0x53eac0,null));},exports[_0x2b8652('0x2')]=function(_0x244e6c,_0x14e95f){const _0x1172ab=_0x2b8652;return db[_0x1172ab('0x14')][_0x1172ab('0x2')](_0x244e6c[_0x1172ab('0x13')],{})[_0x1172ab('0x9')](respondWithResult(_0x14e95f,0xc9))['catch'](handleError(_0x14e95f,null));},exports['update']=function(_0x5e129a,_0x1ba7c7){const _0x2230bb=_0x2b8652;return _0x5e129a[_0x2230bb('0x13')]['id']&&delete _0x5e129a[_0x2230bb('0x13')]['id'],db[_0x2230bb('0x14')][_0x2230bb('0x4')]({'where':{'id':_0x5e129a[_0x2230bb('0x8')]['id']}})[_0x2230bb('0x9')](handleEntityNotFound(_0x1ba7c7,null))[_0x2230bb('0x9')](saveUpdates(_0x5e129a[_0x2230bb('0x13')],null))[_0x2230bb('0x9')](respondWithResult(_0x1ba7c7,null))[_0x2230bb('0x7')](handleError(_0x1ba7c7,null));},exports[_0x2b8652('0x6')]=function(_0x1a0b46,_0x4386b8){const _0x217416=_0x2b8652;return db['VoiceDialReport'][_0x217416('0x4')]({'where':{'id':_0x1a0b46[_0x217416('0x8')]['id']}})[_0x217416('0x9')](handleEntityNotFound(_0x4386b8,null))['then'](removeEntity(_0x4386b8,null))[_0x217416('0x7')](handleError(_0x4386b8,null));},exports[_0x2b8652('0x27')]=function(_0x192905,_0x24ea9a){const _0x4f4081=_0x2b8652;return db[_0x4f4081('0x14')][_0x4f4081('0x27')]()['then'](respondWithResult(_0x24ea9a,null))[_0x4f4081('0x7')](handleError(_0x24ea9a,null));}; \ No newline at end of file +const a722_0x1965=['key','destroy','length','rows','fieldName','count','end','set','catch','lodash','fields','status','model','../../mysqldb','include','then','body','type','params','limit','index','map','name','VIRTUAL','where','offset','../../components/parsers/qs','order','filter','describe','pick','sequelize','filters','options','merge','create','api','../../config/logger','undefined','VoiceDialReport','sort','attributes','update','findAll','intersection','error','nolimit','query','includeAll','rawAttributes','keys','stack','findOne'];(function(_0x5aeaa8,_0x196556){const _0x5a9fc9=function(_0x5aecba){while(--_0x5aecba){_0x5aeaa8['push'](_0x5aeaa8['shift']());}};_0x5a9fc9(++_0x196556);}(a722_0x1965,0x7b));const a722_0x5a9f=function(_0x5aeaa8,_0x196556){_0x5aeaa8=_0x5aeaa8-0x0;let _0x5a9fc9=a722_0x1965[_0x5aeaa8];return _0x5a9fc9;};const _0x2090b7=a722_0x5a9f;'use strict';const _=require(_0x2090b7('0x2d')),qs=require(_0x2090b7('0x9')),logger=require(_0x2090b7('0x14'))(_0x2090b7('0x13')),db=require(_0x2090b7('0x31'))['db'],{Op}=require(_0x2090b7('0xe'));function respondWithResult(_0x5aecba,_0x1e0874){return _0x1e0874=_0x1e0874||0xc8,function(_0x4c340e){const _0x33cad9=a722_0x5a9f;if(_0x4c340e)return _0x5aecba[_0x33cad9('0x2f')](_0x1e0874)['json'](_0x4c340e);};}function respondWithFilteredResult(_0x486a3d,_0xb3218a){return function(_0x4f0069){const _0x11dc29=a722_0x5a9f;if(_0x4f0069){const _0x374183=_0x4f0069[_0x11dc29('0x29')],_0x12f099=_0xb3218a[_0x11dc29('0x8')];let _0x530990=_0xb3218a[_0x11dc29('0x8')]+_0xb3218a[_0x11dc29('0x2')],_0x2518e7;return _0x530990>=_0x374183?(_0x530990=_0x374183,_0x2518e7=0xc8):_0x2518e7=0xce,_0x486a3d[_0x11dc29('0x2f')](_0x2518e7),_0x486a3d[_0x11dc29('0x2b')]('Content-Range',_0x12f099+'-'+_0x530990+'/'+_0x374183)['json'](_0x4f0069);}return null;};}function saveUpdates(_0x8dcb84){return function(_0x56e775){const _0x44b9a5=a722_0x5a9f;if(_0x56e775)return _0x56e775[_0x44b9a5('0x19')](_0x8dcb84)[_0x44b9a5('0x33')](function(_0x154d81){return _0x154d81;});return null;};}function removeEntity(_0x552b8d){return function(_0x291b9f){const _0x2a8f2f=a722_0x5a9f;if(_0x291b9f)return _0x291b9f[_0x2a8f2f('0x25')]()[_0x2a8f2f('0x33')](function(){const _0x1006fb=_0x2a8f2f;_0x552b8d['status'](0xcc)[_0x1006fb('0x2a')]();});};}function handleEntityNotFound(_0x594415){return function(_0x3b820d){return!_0x3b820d&&_0x594415['sendStatus'](0x194),_0x3b820d;};}function handleError(_0x31afe7,_0x2d728c){return _0x2d728c=_0x2d728c||0x1f4,function(_0x4ed991){const _0x241482=a722_0x5a9f;logger[_0x241482('0x1c')](_0x4ed991[_0x241482('0x22')]),_0x4ed991[_0x241482('0x5')]&&delete _0x4ed991[_0x241482('0x5')],_0x31afe7[_0x241482('0x2f')](_0x2d728c)['send'](_0x4ed991);};}exports[_0x2090b7('0x3')]=function(_0xcd6e4,_0x15cc52){const _0x31e476=_0x2090b7;let _0x460a90={};const _0x14a81a={},_0x572e6b={'count':0x0,'rows':[]},_0xbe45bc=_['map'](db[_0x31e476('0x16')]['rawAttributes'],function(_0x15fe5b){const _0x1c0e3e=_0x31e476;return{'name':_0x15fe5b[_0x1c0e3e('0x28')],'type':_0x15fe5b[_0x1c0e3e('0x0')][_0x1c0e3e('0x24')]};});_0x14a81a[_0x31e476('0x30')]=_['map'](_0xbe45bc,_0x31e476('0x5')),_0x14a81a[_0x31e476('0x1e')]=_[_0x31e476('0x21')](_0xcd6e4[_0x31e476('0x1e')]),_0x14a81a[_0x31e476('0xf')]=_[_0x31e476('0x1b')](_0x14a81a['model'],_0x14a81a[_0x31e476('0x1e')]),_0x460a90['attributes']=_[_0x31e476('0x1b')](_0x14a81a[_0x31e476('0x30')],qs[_0x31e476('0x2e')](_0xcd6e4['query'][_0x31e476('0x2e')])),_0x460a90['attributes']=_0x460a90[_0x31e476('0x18')][_0x31e476('0x26')]?_0x460a90[_0x31e476('0x18')]:_0x14a81a[_0x31e476('0x30')];typeof _0xcd6e4[_0x31e476('0x1e')][_0x31e476('0x1d')]===_0x31e476('0x15')&&(_0x460a90[_0x31e476('0x2')]=qs[_0x31e476('0x2')](_0xcd6e4[_0x31e476('0x1e')][_0x31e476('0x2')]),_0x460a90['offset']=qs[_0x31e476('0x8')](_0xcd6e4[_0x31e476('0x1e')][_0x31e476('0x8')]));_0x460a90[_0x31e476('0xa')]=qs[_0x31e476('0x17')](_0xcd6e4[_0x31e476('0x1e')][_0x31e476('0x17')]),_0x460a90[_0x31e476('0x7')]=qs[_0x31e476('0xf')](_[_0x31e476('0xd')](_0xcd6e4[_0x31e476('0x1e')],_0x14a81a[_0x31e476('0xf')]),_0xbe45bc);_0xcd6e4['query'][_0x31e476('0xb')]&&(_0x460a90[_0x31e476('0x7')]=_['merge'](_0x460a90[_0x31e476('0x7')],{[Op['or']]:_[_0x31e476('0x4')](_0xbe45bc,function(_0x5af7a6){const _0x12e0fc=_0x31e476;if(_0x5af7a6[_0x12e0fc('0x0')]!==_0x12e0fc('0x6')){const _0x5e2af9={};return _0x5e2af9[_0x5af7a6[_0x12e0fc('0x5')]]={[Op['like']]:'%'+_0xcd6e4[_0x12e0fc('0x1e')]['filter']+'%'},_0x5e2af9;}})}));_0x460a90=_[_0x31e476('0x11')]({},_0x460a90,_0xcd6e4[_0x31e476('0x10')]);const _0x6f116b={'where':_0x460a90[_0x31e476('0x7')]};return db[_0x31e476('0x16')][_0x31e476('0x29')](_0x6f116b)[_0x31e476('0x33')](function(_0x476894){const _0x849dcf=_0x31e476;return _0x572e6b['count']=_0x476894,_0xcd6e4['query'][_0x849dcf('0x1f')]&&(_0x460a90[_0x849dcf('0x32')]=[{'all':!![]}]),db[_0x849dcf('0x16')][_0x849dcf('0x1a')](_0x460a90);})['then'](function(_0x3433e4){const _0x4c23a2=_0x31e476;return _0x572e6b[_0x4c23a2('0x27')]=_0x3433e4,_0x572e6b;})[_0x31e476('0x33')](respondWithFilteredResult(_0x15cc52,_0x460a90))['catch'](handleError(_0x15cc52,null));},exports['show']=function(_0x11c0cf,_0x1eb164){const _0x3418bc=_0x2090b7;let _0x8f7862={'raw':!![],'where':{'id':_0x11c0cf[_0x3418bc('0x1')]['id']}};const _0x33a00a={};return _0x33a00a[_0x3418bc('0x30')]=_[_0x3418bc('0x21')](db[_0x3418bc('0x16')][_0x3418bc('0x20')]),_0x33a00a[_0x3418bc('0x1e')]=_[_0x3418bc('0x21')](_0x11c0cf[_0x3418bc('0x1e')]),_0x33a00a[_0x3418bc('0xf')]=_[_0x3418bc('0x1b')](_0x33a00a[_0x3418bc('0x30')],_0x33a00a[_0x3418bc('0x1e')]),_0x8f7862[_0x3418bc('0x18')]=_[_0x3418bc('0x1b')](_0x33a00a[_0x3418bc('0x30')],qs[_0x3418bc('0x2e')](_0x11c0cf['query'][_0x3418bc('0x2e')])),_0x8f7862['attributes']=_0x8f7862[_0x3418bc('0x18')]['length']?_0x8f7862[_0x3418bc('0x18')]:_0x33a00a[_0x3418bc('0x30')],_0x11c0cf[_0x3418bc('0x1e')][_0x3418bc('0x1f')]&&(_0x8f7862[_0x3418bc('0x32')]=[{'all':!![]}]),_0x8f7862=_[_0x3418bc('0x11')]({},_0x8f7862,_0x11c0cf['options']),db[_0x3418bc('0x16')][_0x3418bc('0x23')](_0x8f7862)[_0x3418bc('0x33')](handleEntityNotFound(_0x1eb164,null))[_0x3418bc('0x33')](respondWithResult(_0x1eb164,null))[_0x3418bc('0x2c')](handleError(_0x1eb164,null));},exports[_0x2090b7('0x12')]=function(_0x4b68b6,_0x55847d){const _0x2b9035=_0x2090b7;return db['VoiceDialReport'][_0x2b9035('0x12')](_0x4b68b6[_0x2b9035('0x34')],{})[_0x2b9035('0x33')](respondWithResult(_0x55847d,0xc9))['catch'](handleError(_0x55847d,null));},exports['update']=function(_0xcd995,_0x3718b8){const _0x516d50=_0x2090b7;return _0xcd995['body']['id']&&delete _0xcd995[_0x516d50('0x34')]['id'],db['VoiceDialReport'][_0x516d50('0x23')]({'where':{'id':_0xcd995[_0x516d50('0x1')]['id']}})[_0x516d50('0x33')](handleEntityNotFound(_0x3718b8,null))['then'](saveUpdates(_0xcd995['body'],null))[_0x516d50('0x33')](respondWithResult(_0x3718b8,null))[_0x516d50('0x2c')](handleError(_0x3718b8,null));},exports[_0x2090b7('0x25')]=function(_0x4a8902,_0x237369){const _0x223714=_0x2090b7;return db[_0x223714('0x16')][_0x223714('0x23')]({'where':{'id':_0x4a8902[_0x223714('0x1')]['id']}})[_0x223714('0x33')](handleEntityNotFound(_0x237369,null))['then'](removeEntity(_0x237369,null))[_0x223714('0x2c')](handleError(_0x237369,null));},exports[_0x2090b7('0xc')]=function(_0xdcf5a3,_0x4055a2){const _0x4522a9=_0x2090b7;return db[_0x4522a9('0x16')][_0x4522a9('0xc')]()['then'](respondWithResult(_0x4055a2,null))[_0x4522a9('0x2c')](handleError(_0x4055a2,null));}; \ No newline at end of file diff --git a/server/api/voiceDialReport/voiceDialReport.model.js b/server/api/voiceDialReport/voiceDialReport.model.js index a657917..7b0cbef 100644 --- a/server/api/voiceDialReport/voiceDialReport.model.js +++ b/server/api/voiceDialReport/voiceDialReport.model.js @@ -1 +1 @@ -const a723_0x49e1=['./voiceDialReport.attributes','exports','report_dial','define'];(function(_0x52cc2e,_0x49e1ba){const _0x79fe87=function(_0x1ff274){while(--_0x1ff274){_0x52cc2e['push'](_0x52cc2e['shift']());}};_0x79fe87(++_0x49e1ba);}(a723_0x49e1,0x1cd));const a723_0x79fe=function(_0x52cc2e,_0x49e1ba){_0x52cc2e=_0x52cc2e-0x0;let _0x79fe87=a723_0x49e1[_0x52cc2e];return _0x79fe87;};const _0x1eccd4=a723_0x79fe;'use strict';const attributes=require(_0x1eccd4('0x3'));module[_0x1eccd4('0x0')]=function(_0x1ff274){const _0x4f0bd7=_0x1eccd4,_0x2a78bb=_0x1ff274[_0x4f0bd7('0x2')]('VoiceDialReport',attributes,{'tableName':_0x4f0bd7('0x1'),'paranoid':![],'indexes':[{'fields':['uniqueid']}],'timestamps':!![]});return _0x2a78bb;}; \ No newline at end of file +const a723_0x5a9c=['exports','uniqueid','./voiceDialReport.attributes','report_dial','define'];(function(_0x37ebb9,_0x5a9c07){const _0x69f17e=function(_0x2db9b4){while(--_0x2db9b4){_0x37ebb9['push'](_0x37ebb9['shift']());}};_0x69f17e(++_0x5a9c07);}(a723_0x5a9c,0x73));const a723_0x69f1=function(_0x37ebb9,_0x5a9c07){_0x37ebb9=_0x37ebb9-0x0;let _0x69f17e=a723_0x5a9c[_0x37ebb9];return _0x69f17e;};const _0xb68e8a=a723_0x69f1;'use strict';const attributes=require(_0xb68e8a('0x2'));module[_0xb68e8a('0x0')]=function(_0x2db9b4){const _0x38ad4a=_0xb68e8a,_0xcd0f8a=_0x2db9b4[_0x38ad4a('0x4')]('VoiceDialReport',attributes,{'tableName':_0x38ad4a('0x3'),'paranoid':![],'indexes':[{'fields':[_0x38ad4a('0x1')]}],'timestamps':!![]});return _0xcd0f8a;}; \ No newline at end of file diff --git a/server/api/voiceDialReport/voiceDialReport.rpc.js b/server/api/voiceDialReport/voiceDialReport.rpc.js index 4129c88..061f3bb 100644 --- a/server/api/voiceDialReport/voiceDialReport.rpc.js +++ b/server/api/voiceDialReport/voiceDialReport.rpc.js @@ -1 +1 @@ -const a724_0x141d=['VoiceDialReport','../../mysqldb','info','debug','CreateVoiceDialReport','where','body','create','options','message','then','raw','update','error','catch','../../config/logger','UpdateVoiceDialReport','attributes','stringify'];(function(_0x3ce515,_0x141d9f){const _0x505fed=function(_0xeb8feb){while(--_0xeb8feb){_0x3ce515['push'](_0x3ce515['shift']());}};_0x505fed(++_0x141d9f);}(a724_0x141d,0x141));const a724_0x505f=function(_0x3ce515,_0x141d9f){_0x3ce515=_0x3ce515-0x0;let _0x505fed=a724_0x141d[_0x3ce515];return _0x505fed;};const _0x12dba7=a724_0x505f;'use strict';const db=require(_0x12dba7('0x3'))['db'],logger=require(_0x12dba7('0x11'))('rpc');exports[_0x12dba7('0x6')]=function(_0xeb8feb){const _0x3330b3=this;return new Promise(function(_0x36bd86,_0xbc4ecd){const _0xfdae12=a724_0x505f;return db[_0xfdae12('0x2')][_0xfdae12('0x9')](_0xeb8feb[_0xfdae12('0x8')],{'raw':_0xeb8feb[_0xfdae12('0xa')]?_0xeb8feb[_0xfdae12('0xa')]['raw']===undefined?!![]:![]:!![]})[_0xfdae12('0xc')](function(_0x6db2e4){const _0x433c84=_0xfdae12;logger[_0x433c84('0x4')]('CreateVoiceDialReport',_0xeb8feb),logger[_0x433c84('0x5')](_0x433c84('0x6'),_0xeb8feb,JSON[_0x433c84('0x1')](_0x6db2e4)),_0x36bd86(_0x6db2e4);})[_0xfdae12('0x10')](function(_0x2a178d){const _0x18dd08=_0xfdae12;logger['error'](_0x18dd08('0x6'),_0x2a178d[_0x18dd08('0xb')],_0xeb8feb),_0xbc4ecd(_0x3330b3[_0x18dd08('0xf')](0x1f4,_0x2a178d[_0x18dd08('0xb')]));});});},exports[_0x12dba7('0x12')]=function(_0x163e81){const _0x9f3126=this;return new Promise(function(_0x1047a7,_0x215cb8){const _0x20f6c0=a724_0x505f;return db[_0x20f6c0('0x2')][_0x20f6c0('0xe')](_0x163e81['body'],{'raw':_0x163e81[_0x20f6c0('0xa')]?_0x163e81[_0x20f6c0('0xa')][_0x20f6c0('0xd')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x163e81[_0x20f6c0('0xa')]?_0x163e81[_0x20f6c0('0xa')][_0x20f6c0('0x7')]||null:null,'attributes':_0x163e81[_0x20f6c0('0xa')]?_0x163e81[_0x20f6c0('0xa')][_0x20f6c0('0x0')]||null:null,'limit':_0x163e81['options']?_0x163e81[_0x20f6c0('0xa')]['limit']||null:null})[_0x20f6c0('0xc')](function(_0x3b8fb3){const _0x1ce34b=_0x20f6c0;logger['info']('UpdateVoiceDialReport',_0x163e81),logger[_0x1ce34b('0x5')](_0x1ce34b('0x12'),_0x163e81,JSON['stringify'](_0x3b8fb3)),_0x1047a7(_0x3b8fb3);})['catch'](function(_0x15b44a){const _0x85826=_0x20f6c0;logger[_0x85826('0xf')]('UpdateVoiceDialReport',_0x15b44a['message'],_0x163e81),_0x215cb8(_0x9f3126[_0x85826('0xf')](0x1f4,_0x15b44a[_0x85826('0xb')]));});});}; \ No newline at end of file +const a724_0x4ff9=['../../config/logger','CreateVoiceDialReport','rpc','catch','then','stringify','options','body','create','debug','update','raw','attributes','UpdateVoiceDialReport','VoiceDialReport','error','limit','message','info'];(function(_0x41c81c,_0x4ff91d){const _0x3d38fb=function(_0x2c24fc){while(--_0x2c24fc){_0x41c81c['push'](_0x41c81c['shift']());}};_0x3d38fb(++_0x4ff91d);}(a724_0x4ff9,0x1a1));const a724_0x3d38=function(_0x41c81c,_0x4ff91d){_0x41c81c=_0x41c81c-0x0;let _0x3d38fb=a724_0x4ff9[_0x41c81c];return _0x3d38fb;};const _0x5dc071=a724_0x3d38;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x5dc071('0x1'))(_0x5dc071('0x3'));exports[_0x5dc071('0x2')]=function(_0x2c24fc){const _0x59a888=this;return new Promise(function(_0x1fbfed,_0x4963f3){const _0xd6f58b=a724_0x3d38;return db[_0xd6f58b('0xf')][_0xd6f58b('0x9')](_0x2c24fc[_0xd6f58b('0x8')],{'raw':_0x2c24fc[_0xd6f58b('0x7')]?_0x2c24fc[_0xd6f58b('0x7')]['raw']===undefined?!![]:![]:!![]})[_0xd6f58b('0x5')](function(_0x30ce52){const _0x21ce0a=_0xd6f58b;logger[_0x21ce0a('0x0')]('CreateVoiceDialReport',_0x2c24fc),logger[_0x21ce0a('0xa')]('CreateVoiceDialReport',_0x2c24fc,JSON[_0x21ce0a('0x6')](_0x30ce52)),_0x1fbfed(_0x30ce52);})[_0xd6f58b('0x4')](function(_0x21cfe1){const _0x575bbe=_0xd6f58b;logger[_0x575bbe('0x10')](_0x575bbe('0x2'),_0x21cfe1[_0x575bbe('0x12')],_0x2c24fc),_0x4963f3(_0x59a888[_0x575bbe('0x10')](0x1f4,_0x21cfe1[_0x575bbe('0x12')]));});});},exports[_0x5dc071('0xe')]=function(_0x557f2b){const _0x3366f3=this;return new Promise(function(_0x10433,_0x202b2c){const _0x575c2e=a724_0x3d38;return db[_0x575c2e('0xf')][_0x575c2e('0xb')](_0x557f2b[_0x575c2e('0x8')],{'raw':_0x557f2b[_0x575c2e('0x7')]?_0x557f2b[_0x575c2e('0x7')][_0x575c2e('0xc')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x557f2b['options']?_0x557f2b[_0x575c2e('0x7')]['where']||null:null,'attributes':_0x557f2b['options']?_0x557f2b[_0x575c2e('0x7')][_0x575c2e('0xd')]||null:null,'limit':_0x557f2b[_0x575c2e('0x7')]?_0x557f2b[_0x575c2e('0x7')][_0x575c2e('0x11')]||null:null})[_0x575c2e('0x5')](function(_0x14180b){const _0x489afe=_0x575c2e;logger['info'](_0x489afe('0xe'),_0x557f2b),logger[_0x489afe('0xa')](_0x489afe('0xe'),_0x557f2b,JSON[_0x489afe('0x6')](_0x14180b)),_0x10433(_0x14180b);})[_0x575c2e('0x4')](function(_0x1816eb){const _0x4d6569=_0x575c2e;logger[_0x4d6569('0x10')](_0x4d6569('0xe'),_0x1816eb[_0x4d6569('0x12')],_0x557f2b),_0x202b2c(_0x3366f3[_0x4d6569('0x10')](0x1f4,_0x1816eb[_0x4d6569('0x12')]));});});}; \ No newline at end of file diff --git a/server/api/voiceExtension/index.js b/server/api/voiceExtension/index.js index fa60821..786165b 100644 --- a/server/api/voiceExtension/index.js +++ b/server/api/voiceExtension/index.js @@ -1 +1 @@ -const a725_0xa514=['express','get','put','Router','show','/:id/applications','addApplications','exports','create','update','isAuthenticated','/:id','post','../../components/auth/service','delete','index'];(function(_0x37ae1e,_0xa5143e){const _0x597c84=function(_0x3ceb6b){while(--_0x3ceb6b){_0x37ae1e['push'](_0x37ae1e['shift']());}};_0x597c84(++_0xa5143e);}(a725_0xa514,0x15a));const a725_0x597c=function(_0x37ae1e,_0xa5143e){_0x37ae1e=_0x37ae1e-0x0;let _0x597c84=a725_0xa514[_0x37ae1e];return _0x597c84;};const _0x50b212=a725_0x597c;'use strict';const express=require(_0x50b212('0x6')),router=express[_0x50b212('0x9')](),auth=require(_0x50b212('0x3')),controller=require('./voiceExtension.controller');router[_0x50b212('0x7')]('/',auth[_0x50b212('0x0')](),controller[_0x50b212('0x5')]),router['get'](_0x50b212('0x1'),auth[_0x50b212('0x0')](),controller[_0x50b212('0xa')]),router[_0x50b212('0x2')]('/',auth[_0x50b212('0x0')](),controller[_0x50b212('0xe')]),router['post'](_0x50b212('0xb'),auth[_0x50b212('0x0')](),controller[_0x50b212('0xc')]),router[_0x50b212('0x8')](_0x50b212('0x1'),auth['isAuthenticated'](),controller[_0x50b212('0xf')]),router[_0x50b212('0x4')](_0x50b212('0x1'),auth['isAuthenticated'](),controller['destroy']),module[_0x50b212('0xd')]=router; \ No newline at end of file +const a725_0x33e6=['isAuthenticated','/:id/applications','delete','/:id','exports','addApplications','Router','destroy','put','post','express','update','show','get','../../components/auth/service','create'];(function(_0x143b18,_0x33e640){const _0x4faba5=function(_0x18fcf3){while(--_0x18fcf3){_0x143b18['push'](_0x143b18['shift']());}};_0x4faba5(++_0x33e640);}(a725_0x33e6,0x8d));const a725_0x4fab=function(_0x143b18,_0x33e640){_0x143b18=_0x143b18-0x0;let _0x4faba5=a725_0x33e6[_0x143b18];return _0x4faba5;};const _0x5db309=a725_0x4fab;'use strict';const express=require(_0x5db309('0xd')),router=express[_0x5db309('0x9')](),auth=require(_0x5db309('0x1')),controller=require('./voiceExtension.controller');router[_0x5db309('0x0')]('/',auth[_0x5db309('0x3')](),controller['index']),router[_0x5db309('0x0')](_0x5db309('0x6'),auth[_0x5db309('0x3')](),controller[_0x5db309('0xf')]),router[_0x5db309('0xc')]('/',auth[_0x5db309('0x3')](),controller[_0x5db309('0x2')]),router[_0x5db309('0xc')](_0x5db309('0x4'),auth[_0x5db309('0x3')](),controller[_0x5db309('0x8')]),router[_0x5db309('0xb')](_0x5db309('0x6'),auth[_0x5db309('0x3')](),controller[_0x5db309('0xe')]),router[_0x5db309('0x5')](_0x5db309('0x6'),auth[_0x5db309('0x3')](),controller[_0x5db309('0xa')]),module[_0x5db309('0x7')]=router; \ No newline at end of file diff --git a/server/api/voiceExtension/voiceExtension.attributes.js b/server/api/voiceExtension/voiceExtension.attributes.js index 91280b0..b871f5e 100644 --- a/server/api/voiceExtension/voiceExtension.attributes.js +++ b/server/api/voiceExtension/voiceExtension.attributes.js @@ -1 +1 @@ -const a726_0x43fe=['compositeIndex','INTEGER','sequelize','system','wav','BOOLEAN','exten','getDataValue','NoOp','ENUM','exports','internal','STRING','VIRTUAL','outbound-fax','inbound'];(function(_0xbc0b88,_0x43fe4b){const _0x328a77=function(_0xafb018){while(--_0xafb018){_0xbc0b88['push'](_0xbc0b88['shift']());}};_0x328a77(++_0x43fe4b);}(a726_0x43fe,0x150));const a726_0x328a=function(_0xbc0b88,_0x43fe4b){_0xbc0b88=_0xbc0b88-0x0;let _0x328a77=a726_0x43fe[_0xbc0b88];return _0x328a77;};const _0x4ba330=a726_0x328a;'use strict';const Sequelize=require(_0x4ba330('0x2'));module[_0x4ba330('0xa')]={'context':{'type':Sequelize[_0x4ba330('0xc')],'allowNull':![],'unique':_0x4ba330('0x0'),'validate':{'notEmpty':!![],'is':/[A-Za-z0-9._+*!\-[\]]+$/i}},'exten':{'type':Sequelize[_0x4ba330('0xc')],'allowNull':![],'unique':_0x4ba330('0x0')},'priority':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':'1','unique':_0x4ba330('0x0')},'tag':{'type':Sequelize[_0x4ba330('0xc')],'allowNull':![],'defaultValue':'--'},'app':{'type':Sequelize[_0x4ba330('0xc')],'allowNull':![],'defaultValue':_0x4ba330('0x8')},'appdata':{'type':Sequelize[_0x4ba330('0xc')](0x1000),'allowNull':!![],'defaultValue':''},'type':{'type':Sequelize[_0x4ba330('0x9')](_0x4ba330('0xf'),'outbound',_0x4ba330('0xb'),'inbound-fax',_0x4ba330('0xe'),_0x4ba330('0x3'),'any'),'allowNull':![]},'description':{'type':Sequelize['STRING']},'interval':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':'*,*,*,*'},'IntervalId':{'type':Sequelize['INTEGER']},'isApp':{'type':Sequelize[_0x4ba330('0x5')],'allowNull':![],'defaultValue':![]},'appType':{'type':Sequelize[_0x4ba330('0xc')],'defaultValue':null},'callerID':{'type':Sequelize[_0x4ba330('0xc')],'allowNull':!![]},'record':{'type':Sequelize[_0x4ba330('0x5')],'defaultValue':![]},'cutdigits':{'type':Sequelize[_0x4ba330('0x1')]},'recordingFormat':{'type':Sequelize[_0x4ba330('0xc')],'defaultValue':_0x4ba330('0x4')},'answer':{'type':Sequelize[_0x4ba330('0x5')],'defaultValue':!![]},'name':{'type':Sequelize[_0x4ba330('0xd')],'get':function(){const _0x3807a8=_0x4ba330;return this[_0x3807a8('0x7')](_0x3807a8('0x6'));}}}; \ No newline at end of file +const a726_0x5503=['exten','inbound','system','any','exports','BOOLEAN','*,*,*,*','sequelize','outbound-fax','wav','VIRTUAL','compositeIndex','INTEGER','getDataValue','STRING','outbound','internal','inbound-fax'];(function(_0x1e0ab2,_0x5503b1){const _0x111bc6=function(_0xfad74){while(--_0xfad74){_0x1e0ab2['push'](_0x1e0ab2['shift']());}};_0x111bc6(++_0x5503b1);}(a726_0x5503,0x1c0));const a726_0x111b=function(_0x1e0ab2,_0x5503b1){_0x1e0ab2=_0x1e0ab2-0x0;let _0x111bc6=a726_0x5503[_0x1e0ab2];return _0x111bc6;};const _0x599a7e=a726_0x111b;'use strict';const Sequelize=require(_0x599a7e('0x9'));module[_0x599a7e('0x6')]={'context':{'type':Sequelize['STRING'],'allowNull':![],'unique':_0x599a7e('0xd'),'validate':{'notEmpty':!![],'is':/[A-Za-z0-9._+*!\-[\]]+$/i}},'exten':{'type':Sequelize[_0x599a7e('0x10')],'allowNull':![],'unique':_0x599a7e('0xd')},'priority':{'type':Sequelize[_0x599a7e('0x10')],'allowNull':![],'defaultValue':'1','unique':_0x599a7e('0xd')},'tag':{'type':Sequelize[_0x599a7e('0x10')],'allowNull':![],'defaultValue':'--'},'app':{'type':Sequelize[_0x599a7e('0x10')],'allowNull':![],'defaultValue':'NoOp'},'appdata':{'type':Sequelize[_0x599a7e('0x10')](0x1000),'allowNull':!![],'defaultValue':''},'type':{'type':Sequelize['ENUM'](_0x599a7e('0x3'),_0x599a7e('0x11'),_0x599a7e('0x0'),_0x599a7e('0x1'),_0x599a7e('0xa'),_0x599a7e('0x4'),_0x599a7e('0x5')),'allowNull':![]},'description':{'type':Sequelize[_0x599a7e('0x10')]},'interval':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':_0x599a7e('0x8')},'IntervalId':{'type':Sequelize['INTEGER']},'isApp':{'type':Sequelize[_0x599a7e('0x7')],'allowNull':![],'defaultValue':![]},'appType':{'type':Sequelize[_0x599a7e('0x10')],'defaultValue':null},'callerID':{'type':Sequelize[_0x599a7e('0x10')],'allowNull':!![]},'record':{'type':Sequelize[_0x599a7e('0x7')],'defaultValue':![]},'cutdigits':{'type':Sequelize[_0x599a7e('0xe')]},'recordingFormat':{'type':Sequelize['STRING'],'defaultValue':_0x599a7e('0xb')},'answer':{'type':Sequelize[_0x599a7e('0x7')],'defaultValue':!![]},'name':{'type':Sequelize[_0x599a7e('0xc')],'get':function(){const _0x3a2e31=_0x599a7e;return this[_0x3a2e31('0xf')](_0x3a2e31('0x2'));}}}; \ No newline at end of file diff --git a/server/api/voiceExtension/voiceExtension.controller.js b/server/api/voiceExtension/voiceExtension.controller.js index b3f500f..cb164ca 100644 --- a/server/api/voiceExtension/voiceExtension.controller.js +++ b/server/api/voiceExtension/voiceExtension.controller.js @@ -1 +1 @@ -const a727_0x1387=['limit','include','UserProfileSection','role','length','includeAll','count','update','catch','pick','json','map','set','keys','like','transaction','inbound','query','intersection','end','then','fields','exten','params','OutboundRoutes','filter','index','rows','includes','outbound','VoiceExtension','findOne','UserProfileResource','sequelize','where','get','InboundRoutes','options','findAll','error','value','recordingFormat','offset','rawAttributes','register','lodash','fieldName','description','destroy','Content-Range','VoiceExtensionId','InternalRoutes','create','addApplications','ignore','body','userProfileId','../../mysqldb','nolimit','type','../../config/logger','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','attributes','undefined','merge','find','startsWith','context','send','model','status','api','filters','show','autoAssociation','name','findAndCountAll','cutdigits','key','concat','sort','user'];(function(_0x22af08,_0x138779){const _0x40eafc=function(_0x28f597){while(--_0x28f597){_0x22af08['push'](_0x22af08['shift']());}};_0x40eafc(++_0x138779);}(a727_0x1387,0xda));const a727_0x40ea=function(_0x22af08,_0x138779){_0x22af08=_0x22af08-0x0;let _0x40eafc=a727_0x1387[_0x22af08];return _0x40eafc;};const _0x396516=a727_0x40ea;'use strict';const _=require(_0x396516('0x49')),qs=require('../../components/parsers/qs'),logger=require(_0x396516('0x6'))(_0x396516('0x11')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x396516('0x3'))['db'],{Op}=require(_0x396516('0x3d'));require('./voiceExtension.socket')[_0x396516('0x48')](socket);function respondWithStatusCode(_0x28f597,_0x3bc264){return _0x3bc264=_0x3bc264||0xcc,function(_0x3012d4){const _0x167781=a727_0x40ea;if(_0x3012d4)return _0x28f597['sendStatus'](_0x3bc264);return _0x28f597[_0x167781('0x10')](_0x3bc264)['end']();};}function respondWithResult(_0xdc15cd,_0x21bad6){return _0x21bad6=_0x21bad6||0xc8,function(_0x13ef82){const _0x2e3d33=a727_0x40ea;if(_0x13ef82)return _0xdc15cd['status'](_0x21bad6)[_0x2e3d33('0x26')](_0x13ef82);};}function respondWithFilteredResult(_0x248fdc,_0x48c7ff){return function(_0x2a42a3){const _0x51e023=a727_0x40ea;if(_0x2a42a3){const _0x427673=_0x2a42a3[_0x51e023('0x22')],_0x30cafe=_0x48c7ff['offset'];let _0x47d1df=_0x48c7ff[_0x51e023('0x46')]+_0x48c7ff[_0x51e023('0x1c')],_0x5a0439;return _0x47d1df>=_0x427673?(_0x47d1df=_0x427673,_0x5a0439=0xc8):_0x5a0439=0xce,_0x248fdc[_0x51e023('0x10')](_0x5a0439),_0x248fdc[_0x51e023('0x28')](_0x51e023('0x4d'),_0x30cafe+'-'+_0x47d1df+'/'+_0x427673)[_0x51e023('0x26')](_0x2a42a3);}return null;};}function removeEntity(_0x1ee1e1){return function(_0x3e985d){const _0x38effc=a727_0x40ea;if(_0x3e985d)return _0x3e985d[_0x38effc('0x4c')]()[_0x38effc('0x30')](function(){const _0x24dd2a=_0x38effc,_0x34c86a=_0x3e985d[_0x24dd2a('0x3f')]({'plain':!![]}),_0x59dcde=[{'name':_0x24dd2a('0x40'),'value':_0x24dd2a('0x2c'),'ignore':![]},{'name':_0x24dd2a('0x34'),'value':_0x24dd2a('0x39'),'ignore':![]},{'name':_0x24dd2a('0x4f'),'value':'internal','ignore':![]}],_0x5a4298=_(_0x59dcde)['filter'](_0x24dd2a('0x0'))['map']('value')['value']();if(_[_0x24dd2a('0x38')](_0x5a4298,_0x34c86a[_0x24dd2a('0x5')]))return;const _0x5be4bc=_[_0x24dd2a('0xb')](_0x59dcde,['value',_0x34c86a[_0x24dd2a('0x5')]])['name'];return db[_0x24dd2a('0x3c')][_0x24dd2a('0x4c')]({'where':{'type':_0x5be4bc,'resourceId':_0x34c86a['id']}})[_0x24dd2a('0x30')](function(){return _0x3e985d;});})[_0x38effc('0x30')](function(){const _0xde7e74=_0x38effc;_0x1ee1e1['status'](0xcc)[_0xde7e74('0x2f')]();});};}function handleEntityNotFound(_0x5b3d9b){return function(_0x244e27){return!_0x244e27&&_0x5b3d9b['sendStatus'](0x194),_0x244e27;};}function handleError(_0x216976,_0x59d5b0){return _0x59d5b0=_0x59d5b0||0x1f4,function(_0x33770a){const _0x369653=a727_0x40ea;logger[_0x369653('0x43')](_0x33770a['stack']),_0x33770a[_0x369653('0x15')]&&delete _0x33770a[_0x369653('0x15')],_0x216976[_0x369653('0x10')](_0x59d5b0)[_0x369653('0xe')](_0x33770a);};}exports[_0x396516('0x36')]=function(_0x3a29fe,_0x4954c0){const _0x5721db=_0x396516;let _0x154097={};const _0x109eae={},_0x514902={'count':0x0,'rows':[]},_0x1beadd=_[_0x5721db('0x27')](db[_0x5721db('0x3a')][_0x5721db('0x47')],function(_0x3c8edd){const _0x505e67=_0x5721db;return{'name':_0x3c8edd[_0x505e67('0x4a')],'type':_0x3c8edd['type'][_0x505e67('0x18')]};});_0x109eae[_0x5721db('0xf')]=_[_0x5721db('0x27')](_0x1beadd,'name'),_0x109eae[_0x5721db('0x2d')]=_[_0x5721db('0x29')](_0x3a29fe[_0x5721db('0x2d')]),_0x109eae[_0x5721db('0x12')]=_[_0x5721db('0x2e')](_0x109eae['model'],_0x109eae[_0x5721db('0x2d')]),_0x154097[_0x5721db('0x8')]=_['intersection'](_0x109eae['model'],qs[_0x5721db('0x31')](_0x3a29fe[_0x5721db('0x2d')][_0x5721db('0x31')])),_0x154097[_0x5721db('0x8')]=_0x154097[_0x5721db('0x8')][_0x5721db('0x20')]?_0x154097['attributes']:_0x109eae[_0x5721db('0xf')];typeof _0x3a29fe[_0x5721db('0x2d')][_0x5721db('0x4')]===_0x5721db('0x9')&&(_0x154097[_0x5721db('0x1c')]=qs['limit'](_0x3a29fe['query'][_0x5721db('0x1c')]),_0x154097[_0x5721db('0x46')]=qs[_0x5721db('0x46')](_0x3a29fe[_0x5721db('0x2d')][_0x5721db('0x46')]));_0x154097['order']=qs[_0x5721db('0x1a')](_0x3a29fe[_0x5721db('0x2d')][_0x5721db('0x1a')]),_0x154097[_0x5721db('0x3e')]=qs[_0x5721db('0x12')](_['pick'](_0x3a29fe[_0x5721db('0x2d')],_0x109eae[_0x5721db('0x12')]),_0x1beadd);_0x3a29fe[_0x5721db('0x2d')][_0x5721db('0x35')]&&(_0x154097[_0x5721db('0x3e')]=_[_0x5721db('0xa')](_0x154097[_0x5721db('0x3e')],{[Op['or']]:_['map'](_0x1beadd,function(_0x35dec1){const _0x45b8b0=_0x5721db;if(_0x35dec1[_0x45b8b0('0x5')]!=='VIRTUAL'){const _0x4bdddb={};return _0x4bdddb[_0x35dec1[_0x45b8b0('0x15')]]={[Op[_0x45b8b0('0x2a')]]:'%'+_0x3a29fe[_0x45b8b0('0x2d')][_0x45b8b0('0x35')]+'%'},_0x4bdddb;}})}));_0x154097=_[_0x5721db('0xa')]({},_0x154097,_0x3a29fe[_0x5721db('0x41')]);const _0x43ea9b={'where':_0x154097[_0x5721db('0x3e')]};return db[_0x5721db('0x3a')][_0x5721db('0x22')](_0x43ea9b)['then'](function(_0x2d9e86){const _0x164cd0=_0x5721db;return _0x514902['count']=_0x2d9e86,_0x3a29fe[_0x164cd0('0x2d')]['includeAll']&&(_0x154097[_0x164cd0('0x1d')]=[{'all':!![]}]),db[_0x164cd0('0x3a')][_0x164cd0('0x42')](_0x154097);})[_0x5721db('0x30')](function(_0x530894){const _0x1292cd=_0x5721db;return _0x514902[_0x1292cd('0x37')]=_0x530894,_0x514902;})[_0x5721db('0x30')](respondWithFilteredResult(_0x4954c0,_0x154097))[_0x5721db('0x24')](handleError(_0x4954c0,null));},exports[_0x396516('0x13')]=function(_0xeb49ab,_0x1842f4){const _0x2dc61e=_0x396516;let _0x58242a={'raw':![],'where':{'id':_0xeb49ab['params']['id']}};const _0x3c57c8={};return _0x3c57c8['model']=_[_0x2dc61e('0x29')](db[_0x2dc61e('0x3a')][_0x2dc61e('0x47')]),_0x3c57c8[_0x2dc61e('0x2d')]=_[_0x2dc61e('0x29')](_0xeb49ab['query']),_0x3c57c8['filters']=_['intersection'](_0x3c57c8[_0x2dc61e('0xf')],_0x3c57c8['query']),_0x58242a[_0x2dc61e('0x8')]=_[_0x2dc61e('0x2e')](_0x3c57c8['model'],qs['fields'](_0xeb49ab[_0x2dc61e('0x2d')][_0x2dc61e('0x31')])),_0x58242a[_0x2dc61e('0x8')]=_0x58242a[_0x2dc61e('0x8')]['length']?_0x58242a[_0x2dc61e('0x8')]:_0x3c57c8[_0x2dc61e('0xf')],_0xeb49ab[_0x2dc61e('0x2d')][_0x2dc61e('0x21')]&&(_0x58242a['include']=[{'all':!![]}]),_0x58242a=_[_0x2dc61e('0xa')]({},_0x58242a,_0xeb49ab[_0x2dc61e('0x41')]),db[_0x2dc61e('0x3a')][_0x2dc61e('0x3b')](_0x58242a)[_0x2dc61e('0x30')](handleEntityNotFound(_0x1842f4,null))[_0x2dc61e('0x30')](respondWithResult(_0x1842f4,null))[_0x2dc61e('0x24')](handleError(_0x1842f4,null));},exports[_0x396516('0x4c')]=function(_0x549d8d,_0x14ef32){const _0x222215=_0x396516;return db['VoiceExtension']['findOne']({'where':{'id':_0x549d8d[_0x222215('0x33')]['id']}})[_0x222215('0x30')](handleEntityNotFound(_0x14ef32,null))[_0x222215('0x30')](removeEntity(_0x14ef32,null))['catch'](handleError(_0x14ef32,null));},exports['create']=function(_0x2c5535,_0x28983f){const _0xe83916=_0x396516;return _0x2c5535['body'][_0xe83916('0x5')]==='outbound'&&!_[_0xe83916('0xc')](_0x2c5535[_0xe83916('0x1')]['exten'],'_')&&(_0x2c5535[_0xe83916('0x1')][_0xe83916('0x32')]='_'[_0xe83916('0x19')](_0x2c5535[_0xe83916('0x1')][_0xe83916('0x32')])),db[_0xe83916('0x3a')][_0xe83916('0x50')](_0x2c5535[_0xe83916('0x1')],{'raw':![]})[_0xe83916('0x30')](function(_0x12ffee){const _0x7af023=_0xe83916,_0x50e13b=_0x2c5535[_0x7af023('0x1b')][_0x7af023('0x3f')]({'plain':!![]});if(!_0x50e13b)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x50e13b[_0x7af023('0x1f')]===_0x7af023('0x1b')){const _0x4e9a02=_0x12ffee[_0x7af023('0x3f')]({'plain':!![]}),_0x213e3d=[{'name':_0x7af023('0x40'),'value':'inbound'},{'name':'OutboundRoutes','value':'outbound'},{'name':'InternalRoutes','value':'internal'}],_0x5e3460=_[_0x7af023('0xb')](_0x213e3d,[_0x7af023('0x44'),_0x4e9a02[_0x7af023('0x5')]])[_0x7af023('0x15')];return db[_0x7af023('0x1e')]['findOne']({'where':{'name':_0x5e3460,'userProfileId':_0x50e13b[_0x7af023('0x2')]},'raw':!![]})[_0x7af023('0x30')](function(_0x301c89){const _0x5abe36=_0x7af023;return _0x301c89&&_0x301c89[_0x5abe36('0x14')]===0x0?db[_0x5abe36('0x3c')]['create']({'name':_0x4e9a02['name'],'resourceId':_0x4e9a02['id'],'type':_0x301c89[_0x5abe36('0x15')],'sectionId':_0x301c89['id']},{})[_0x5abe36('0x30')](function(){return _0x12ffee;}):_0x12ffee;})[_0x7af023('0x24')](function(_0x2dc473){const _0x48dfc0=_0x7af023;logger[_0x48dfc0('0x43')](_0x48dfc0('0x7'),_0x2dc473);throw _0x2dc473;});}return _0x12ffee;})['then'](respondWithResult(_0x28983f,0xc9))[_0xe83916('0x24')](handleError(_0x28983f,null));},exports[_0x396516('0x23')]=function(_0x5cb956,_0x388d98){const _0x597294=_0x396516;return _0x5cb956[_0x597294('0x1')]['id']&&delete _0x5cb956[_0x597294('0x1')]['id'],db[_0x597294('0x3a')][_0x597294('0x3b')]({'where':{'id':_0x5cb956[_0x597294('0x33')]['id']}})['then'](handleEntityNotFound(_0x388d98,null))['then'](function(_0x11f0bf){const _0x299847=_0x597294;if(_0x11f0bf)return db[_0x299847('0x3a')]['update'](_[_0x299847('0x25')](_0x5cb956['body'],[_0x299847('0x32'),_0x299847('0xd'),_0x299847('0x4b'),_0x299847('0x45'),_0x299847('0x17'),'mandatoryDisposition']),{'where':{'context':_0x11f0bf['context'],'exten':_0x11f0bf[_0x299847('0x32')]},'individualHooks':!![]})[_0x299847('0x30')](function(_0x2d6c5c){return _0x2d6c5c;});return null;})[_0x597294('0x30')](respondWithStatusCode(_0x388d98,null))[_0x597294('0x24')](handleError(_0x388d98,null));},exports[_0x396516('0x51')]=function(_0x226f46,_0x16546a){const _0x15d24a=_0x396516;return db[_0x15d24a('0x3a')][_0x15d24a('0x3b')]({'where':{'id':_0x226f46[_0x15d24a('0x33')]['id']}})['then'](handleEntityNotFound(_0x16546a,null))[_0x15d24a('0x30')](function(_0x4e013c){const _0x4f95f7=_0x15d24a;if(_0x4e013c)return db['sequelize'][_0x4f95f7('0x2b')](function(_0x28e0f0){const _0x5221aa=_0x4f95f7;return db['VoiceExtension'][_0x5221aa('0x4c')]({'where':{'VoiceExtensionId':_0x226f46[_0x5221aa('0x33')]['id']},'transaction':_0x28e0f0})['then'](function(){const _0x5ed9c5=_0x5221aa,_0x3428f0=_[_0x5ed9c5('0x27')](_0x226f46[_0x5ed9c5('0x1')],function(_0x1070a4){const _0x5e94ae=_0x5ed9c5;return _0x1070a4[_0x5e94ae('0x4e')]=_0x226f46['params']['id'],_0x1070a4;});return db['VoiceExtension']['bulkCreate'](_0x3428f0,{'transaction':_0x28e0f0});});})[_0x4f95f7('0x30')](function(){const _0x3d85aa=_0x4f95f7;return db[_0x3d85aa('0x3a')][_0x3d85aa('0x16')]({'where':{'isApp':!![],'VoiceExtensionId':_0x226f46[_0x3d85aa('0x33')]['id']},'order':'cast(priority\x20as\x20unsigned)'});});})[_0x15d24a('0x30')](respondWithResult(_0x16546a,null))[_0x15d24a('0x24')](handleError(_0x16546a,null));}; \ No newline at end of file +const a727_0x5c99=['InternalRoutes','find','body','like','mandatoryDisposition','send','then','addApplications','create','lodash','internal','undefined','limit','outbound','register','sequelize','Content-Range','attributes','./voiceExtension.socket','update','VoiceExtensionId','sort','error','fieldName','../../components/parsers/qs','ignore','inbound','type','cast(priority\x20as\x20unsigned)','role','key','params','userProfileId','get','includeAll','intersection','pick','where','startsWith','merge','findAll','autoAssociation','rows','filters','../../rediscache','include','name','description','length','context','bulkCreate','json','keys','transaction','concat','count','end','recordingFormat','filter','destroy','set','VIRTUAL','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','findOne','catch','UserProfileResource','offset','options','InboundRoutes','model','map','sendStatus','cutdigits','stack','fields','query','exten','OutboundRoutes','VoiceExtension','../../config/logger','status','value','findAndCountAll'];(function(_0x277de1,_0x5c9946){const _0x57f878=function(_0x1dfee8){while(--_0x1dfee8){_0x277de1['push'](_0x277de1['shift']());}};_0x57f878(++_0x5c9946);}(a727_0x5c99,0x17d));const a727_0x57f8=function(_0x277de1,_0x5c9946){_0x277de1=_0x277de1-0x0;let _0x57f878=a727_0x5c99[_0x277de1];return _0x57f878;};const _0x54d63f=a727_0x57f8;'use strict';const _=require(_0x54d63f('0x2b')),qs=require(_0x54d63f('0x3a')),logger=require(_0x54d63f('0x1e'))('api'),{getSocket}=require(_0x54d63f('0x4e')),socket=getSocket(),db=require('../../mysqldb')['db'],{Op}=require(_0x54d63f('0x31'));require(_0x54d63f('0x34'))[_0x54d63f('0x30')](socket);function respondWithStatusCode(_0x1dfee8,_0x314652){return _0x314652=_0x314652||0xcc,function(_0x50bcba){const _0xf62ac9=a727_0x57f8;if(_0x50bcba)return _0x1dfee8[_0xf62ac9('0x16')](_0x314652);return _0x1dfee8[_0xf62ac9('0x1f')](_0x314652)[_0xf62ac9('0x7')]();};}function respondWithResult(_0x21029d,_0x18c6d5){return _0x18c6d5=_0x18c6d5||0xc8,function(_0x116988){const _0x448b08=a727_0x57f8;if(_0x116988)return _0x21029d[_0x448b08('0x1f')](_0x18c6d5)[_0x448b08('0x2')](_0x116988);};}function respondWithFilteredResult(_0xe97e5,_0x583372){return function(_0x5b3798){const _0x2390d6=a727_0x57f8;if(_0x5b3798){const _0x1dad3c=_0x5b3798[_0x2390d6('0x6')],_0x2ae225=_0x583372[_0x2390d6('0x11')];let _0x31348c=_0x583372[_0x2390d6('0x11')]+_0x583372[_0x2390d6('0x2e')],_0x13ed28;return _0x31348c>=_0x1dad3c?(_0x31348c=_0x1dad3c,_0x13ed28=0xc8):_0x13ed28=0xce,_0xe97e5['status'](_0x13ed28),_0xe97e5[_0x2390d6('0xb')](_0x2390d6('0x32'),_0x2ae225+'-'+_0x31348c+'/'+_0x1dad3c)[_0x2390d6('0x2')](_0x5b3798);}return null;};}function removeEntity(_0x44256a){return function(_0x31f0f4){const _0x5ed6e2=a727_0x57f8;if(_0x31f0f4)return _0x31f0f4[_0x5ed6e2('0xa')]()['then'](function(){const _0x5121aa=_0x5ed6e2,_0x39f2d0=_0x31f0f4['get']({'plain':!![]}),_0x325cd8=[{'name':'InboundRoutes','value':_0x5121aa('0x3c'),'ignore':![]},{'name':_0x5121aa('0x1c'),'value':_0x5121aa('0x2f'),'ignore':![]},{'name':'InternalRoutes','value':_0x5121aa('0x2c'),'ignore':![]}],_0x3a2911=_(_0x325cd8)[_0x5121aa('0x9')](_0x5121aa('0x3b'))[_0x5121aa('0x15')](_0x5121aa('0x20'))[_0x5121aa('0x20')]();if(_['includes'](_0x3a2911,_0x39f2d0[_0x5121aa('0x3d')]))return;const _0x18d933=_[_0x5121aa('0x23')](_0x325cd8,['value',_0x39f2d0[_0x5121aa('0x3d')]])[_0x5121aa('0x50')];return db['UserProfileResource'][_0x5121aa('0xa')]({'where':{'type':_0x18d933,'resourceId':_0x39f2d0['id']}})[_0x5121aa('0x28')](function(){return _0x31f0f4;});})[_0x5ed6e2('0x28')](function(){const _0x4ff800=_0x5ed6e2;_0x44256a[_0x4ff800('0x1f')](0xcc)[_0x4ff800('0x7')]();});};}function handleEntityNotFound(_0x2bba86){return function(_0x175e40){const _0x29f446=a727_0x57f8;return!_0x175e40&&_0x2bba86[_0x29f446('0x16')](0x194),_0x175e40;};}function handleError(_0x2c7a55,_0x55b523){return _0x55b523=_0x55b523||0x1f4,function(_0x232cc0){const _0x14fded=a727_0x57f8;logger[_0x14fded('0x38')](_0x232cc0[_0x14fded('0x18')]),_0x232cc0['name']&&delete _0x232cc0[_0x14fded('0x50')],_0x2c7a55['status'](_0x55b523)[_0x14fded('0x27')](_0x232cc0);};}exports['index']=function(_0x12aabf,_0xc3b2ff){const _0x178476=_0x54d63f;let _0x1d7bad={};const _0x2c4f7d={},_0x37b72a={'count':0x0,'rows':[]},_0x13d937=_[_0x178476('0x15')](db[_0x178476('0x1d')]['rawAttributes'],function(_0x1e962b){const _0x52a4c0=_0x178476;return{'name':_0x1e962b[_0x52a4c0('0x39')],'type':_0x1e962b[_0x52a4c0('0x3d')][_0x52a4c0('0x40')]};});_0x2c4f7d[_0x178476('0x14')]=_['map'](_0x13d937,_0x178476('0x50')),_0x2c4f7d['query']=_[_0x178476('0x3')](_0x12aabf['query']),_0x2c4f7d[_0x178476('0x4d')]=_[_0x178476('0x45')](_0x2c4f7d[_0x178476('0x14')],_0x2c4f7d[_0x178476('0x1a')]),_0x1d7bad[_0x178476('0x33')]=_[_0x178476('0x45')](_0x2c4f7d[_0x178476('0x14')],qs[_0x178476('0x19')](_0x12aabf['query'][_0x178476('0x19')])),_0x1d7bad[_0x178476('0x33')]=_0x1d7bad[_0x178476('0x33')]['length']?_0x1d7bad[_0x178476('0x33')]:_0x2c4f7d['model'];typeof _0x12aabf[_0x178476('0x1a')]['nolimit']===_0x178476('0x2d')&&(_0x1d7bad[_0x178476('0x2e')]=qs[_0x178476('0x2e')](_0x12aabf[_0x178476('0x1a')][_0x178476('0x2e')]),_0x1d7bad['offset']=qs[_0x178476('0x11')](_0x12aabf['query'][_0x178476('0x11')]));_0x1d7bad['order']=qs[_0x178476('0x37')](_0x12aabf[_0x178476('0x1a')][_0x178476('0x37')]),_0x1d7bad[_0x178476('0x47')]=qs['filters'](_[_0x178476('0x46')](_0x12aabf['query'],_0x2c4f7d['filters']),_0x13d937);_0x12aabf['query'][_0x178476('0x9')]&&(_0x1d7bad['where']=_['merge'](_0x1d7bad[_0x178476('0x47')],{[Op['or']]:_[_0x178476('0x15')](_0x13d937,function(_0xf4d898){const _0x316601=_0x178476;if(_0xf4d898[_0x316601('0x3d')]!==_0x316601('0xc')){const _0x42a37a={};return _0x42a37a[_0xf4d898[_0x316601('0x50')]]={[Op[_0x316601('0x25')]]:'%'+_0x12aabf[_0x316601('0x1a')][_0x316601('0x9')]+'%'},_0x42a37a;}})}));_0x1d7bad=_[_0x178476('0x49')]({},_0x1d7bad,_0x12aabf[_0x178476('0x12')]);const _0x1eeeb8={'where':_0x1d7bad[_0x178476('0x47')]};return db['VoiceExtension'][_0x178476('0x6')](_0x1eeeb8)[_0x178476('0x28')](function(_0x1c5a56){const _0x22044a=_0x178476;return _0x37b72a[_0x22044a('0x6')]=_0x1c5a56,_0x12aabf[_0x22044a('0x1a')][_0x22044a('0x44')]&&(_0x1d7bad['include']=[{'all':!![]}]),db[_0x22044a('0x1d')][_0x22044a('0x4a')](_0x1d7bad);})[_0x178476('0x28')](function(_0x2f8603){const _0x31d7d1=_0x178476;return _0x37b72a[_0x31d7d1('0x4c')]=_0x2f8603,_0x37b72a;})[_0x178476('0x28')](respondWithFilteredResult(_0xc3b2ff,_0x1d7bad))[_0x178476('0xf')](handleError(_0xc3b2ff,null));},exports['show']=function(_0xc07277,_0x26aa9b){const _0x3c3aac=_0x54d63f;let _0x5b8113={'raw':![],'where':{'id':_0xc07277[_0x3c3aac('0x41')]['id']}};const _0x114497={};return _0x114497[_0x3c3aac('0x14')]=_[_0x3c3aac('0x3')](db['VoiceExtension']['rawAttributes']),_0x114497[_0x3c3aac('0x1a')]=_[_0x3c3aac('0x3')](_0xc07277['query']),_0x114497[_0x3c3aac('0x4d')]=_[_0x3c3aac('0x45')](_0x114497[_0x3c3aac('0x14')],_0x114497['query']),_0x5b8113[_0x3c3aac('0x33')]=_['intersection'](_0x114497[_0x3c3aac('0x14')],qs[_0x3c3aac('0x19')](_0xc07277[_0x3c3aac('0x1a')][_0x3c3aac('0x19')])),_0x5b8113[_0x3c3aac('0x33')]=_0x5b8113[_0x3c3aac('0x33')][_0x3c3aac('0x52')]?_0x5b8113[_0x3c3aac('0x33')]:_0x114497['model'],_0xc07277[_0x3c3aac('0x1a')]['includeAll']&&(_0x5b8113[_0x3c3aac('0x4f')]=[{'all':!![]}]),_0x5b8113=_[_0x3c3aac('0x49')]({},_0x5b8113,_0xc07277[_0x3c3aac('0x12')]),db['VoiceExtension'][_0x3c3aac('0xe')](_0x5b8113)[_0x3c3aac('0x28')](handleEntityNotFound(_0x26aa9b,null))[_0x3c3aac('0x28')](respondWithResult(_0x26aa9b,null))['catch'](handleError(_0x26aa9b,null));},exports[_0x54d63f('0xa')]=function(_0x588cfa,_0xc01ee1){const _0x3236df=_0x54d63f;return db[_0x3236df('0x1d')][_0x3236df('0xe')]({'where':{'id':_0x588cfa[_0x3236df('0x41')]['id']}})['then'](handleEntityNotFound(_0xc01ee1,null))['then'](removeEntity(_0xc01ee1,null))[_0x3236df('0xf')](handleError(_0xc01ee1,null));},exports['create']=function(_0x72b3fe,_0x16b945){const _0xa6672a=_0x54d63f;return _0x72b3fe[_0xa6672a('0x24')][_0xa6672a('0x3d')]==='outbound'&&!_[_0xa6672a('0x48')](_0x72b3fe[_0xa6672a('0x24')][_0xa6672a('0x1b')],'_')&&(_0x72b3fe[_0xa6672a('0x24')][_0xa6672a('0x1b')]='_'[_0xa6672a('0x5')](_0x72b3fe['body'][_0xa6672a('0x1b')])),db[_0xa6672a('0x1d')][_0xa6672a('0x2a')](_0x72b3fe['body'],{'raw':![]})[_0xa6672a('0x28')](function(_0x2249fd){const _0x35395e=_0xa6672a,_0x404730=_0x72b3fe['user'][_0x35395e('0x43')]({'plain':!![]});if(!_0x404730)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x404730[_0x35395e('0x3f')]==='user'){const _0x374c04=_0x2249fd[_0x35395e('0x43')]({'plain':!![]}),_0x407bf5=[{'name':_0x35395e('0x13'),'value':'inbound'},{'name':_0x35395e('0x1c'),'value':'outbound'},{'name':_0x35395e('0x22'),'value':_0x35395e('0x2c')}],_0x4663e5=_[_0x35395e('0x23')](_0x407bf5,[_0x35395e('0x20'),_0x374c04['type']])['name'];return db['UserProfileSection'][_0x35395e('0xe')]({'where':{'name':_0x4663e5,'userProfileId':_0x404730[_0x35395e('0x42')]},'raw':!![]})[_0x35395e('0x28')](function(_0x3b3afd){const _0x4d0b6c=_0x35395e;return _0x3b3afd&&_0x3b3afd[_0x4d0b6c('0x4b')]===0x0?db[_0x4d0b6c('0x10')][_0x4d0b6c('0x2a')]({'name':_0x374c04[_0x4d0b6c('0x50')],'resourceId':_0x374c04['id'],'type':_0x3b3afd[_0x4d0b6c('0x50')],'sectionId':_0x3b3afd['id']},{})['then'](function(){return _0x2249fd;}):_0x2249fd;})[_0x35395e('0xf')](function(_0x3d74a5){const _0x20d60d=_0x35395e;logger[_0x20d60d('0x38')](_0x20d60d('0xd'),_0x3d74a5);throw _0x3d74a5;});}return _0x2249fd;})[_0xa6672a('0x28')](respondWithResult(_0x16b945,0xc9))[_0xa6672a('0xf')](handleError(_0x16b945,null));},exports['update']=function(_0xf91b77,_0xca5b2b){const _0x3c6aca=_0x54d63f;return _0xf91b77[_0x3c6aca('0x24')]['id']&&delete _0xf91b77[_0x3c6aca('0x24')]['id'],db[_0x3c6aca('0x1d')]['findOne']({'where':{'id':_0xf91b77['params']['id']}})['then'](handleEntityNotFound(_0xca5b2b,null))[_0x3c6aca('0x28')](function(_0xc7af4c){const _0x3a8f6e=_0x3c6aca;if(_0xc7af4c)return db[_0x3a8f6e('0x1d')][_0x3a8f6e('0x35')](_[_0x3a8f6e('0x46')](_0xf91b77[_0x3a8f6e('0x24')],[_0x3a8f6e('0x1b'),_0x3a8f6e('0x0'),_0x3a8f6e('0x51'),_0x3a8f6e('0x8'),_0x3a8f6e('0x17'),_0x3a8f6e('0x26')]),{'where':{'context':_0xc7af4c[_0x3a8f6e('0x0')],'exten':_0xc7af4c['exten']},'individualHooks':!![]})[_0x3a8f6e('0x28')](function(_0x46637d){return _0x46637d;});return null;})['then'](respondWithStatusCode(_0xca5b2b,null))['catch'](handleError(_0xca5b2b,null));},exports[_0x54d63f('0x29')]=function(_0x148a9c,_0xf11a7b){const _0x18e98b=_0x54d63f;return db[_0x18e98b('0x1d')]['findOne']({'where':{'id':_0x148a9c['params']['id']}})[_0x18e98b('0x28')](handleEntityNotFound(_0xf11a7b,null))[_0x18e98b('0x28')](function(_0x35ee1e){const _0x1cc19f=_0x18e98b;if(_0x35ee1e)return db[_0x1cc19f('0x31')][_0x1cc19f('0x4')](function(_0x3a13ac){const _0x1bb228=_0x1cc19f;return db[_0x1bb228('0x1d')][_0x1bb228('0xa')]({'where':{'VoiceExtensionId':_0x148a9c[_0x1bb228('0x41')]['id']},'transaction':_0x3a13ac})['then'](function(){const _0x5bab54=_0x1bb228,_0x22355a=_[_0x5bab54('0x15')](_0x148a9c[_0x5bab54('0x24')],function(_0x422fe1){const _0x340959=_0x5bab54;return _0x422fe1[_0x340959('0x36')]=_0x148a9c['params']['id'],_0x422fe1;});return db[_0x5bab54('0x1d')][_0x5bab54('0x1')](_0x22355a,{'transaction':_0x3a13ac});});})['then'](function(){const _0x2cedd4=_0x1cc19f;return db[_0x2cedd4('0x1d')][_0x2cedd4('0x21')]({'where':{'isApp':!![],'VoiceExtensionId':_0x148a9c['params']['id']},'order':_0x2cedd4('0x3e')});});})['then'](respondWithResult(_0xf11a7b,null))[_0x18e98b('0xf')](handleError(_0xf11a7b,null));}; \ No newline at end of file diff --git a/server/api/voiceExtension/voiceExtension.events.js b/server/api/voiceExtension/voiceExtension.events.js index 46a2b1f..b7232e0 100644 --- a/server/api/voiceExtension/voiceExtension.events.js +++ b/server/api/voiceExtension/voiceExtension.events.js @@ -1 +1 @@ -const a728_0x3c70=['VoiceExtension','undefined','emit','../../mysqldb','update','events','setMaxListeners','exports','addHook'];(function(_0x147094,_0x3c7088){const _0x372a55=function(_0x39aa12){while(--_0x39aa12){_0x147094['push'](_0x147094['shift']());}};_0x372a55(++_0x3c7088);}(a728_0x3c70,0x166));const a728_0x372a=function(_0x147094,_0x3c7088){_0x147094=_0x147094-0x0;let _0x372a55=a728_0x3c70[_0x147094];return _0x372a55;};const _0x1ffa1a=a728_0x372a;'use strict';const EventEmitter=require(_0x1ffa1a('0x7')),VoiceExtension=require(_0x1ffa1a('0x5'))['db'][_0x1ffa1a('0x2')],VoiceExtensionEvents=new EventEmitter();VoiceExtensionEvents[_0x1ffa1a('0x8')](0x0);const events={'afterCreate':'save','afterUpdate':_0x1ffa1a('0x6'),'afterDestroy':'remove'};function emitEvent(_0x39aa12){return function(_0x376988){const _0x31ab72=a728_0x372a;VoiceExtensionEvents[_0x31ab72('0x4')](_0x39aa12+':'+_0x376988['id'],_0x376988),VoiceExtensionEvents[_0x31ab72('0x4')](_0x39aa12,_0x376988);};}for(const e in events){if(typeof events[e]!==_0x1ffa1a('0x3')){const event=events[e];VoiceExtension[_0x1ffa1a('0x1')](e,emitEvent(event));}}module[_0x1ffa1a('0x0')]=VoiceExtensionEvents; \ No newline at end of file +const a728_0x3535=['undefined','remove','addHook','save','../../mysqldb','VoiceExtension','emit'];(function(_0x4d6df0,_0x3535bb){const _0xd20ac6=function(_0x4571b2){while(--_0x4571b2){_0x4d6df0['push'](_0x4d6df0['shift']());}};_0xd20ac6(++_0x3535bb);}(a728_0x3535,0x1f3));const a728_0xd20a=function(_0x4d6df0,_0x3535bb){_0x4d6df0=_0x4d6df0-0x0;let _0xd20ac6=a728_0x3535[_0x4d6df0];return _0xd20ac6;};const _0x3a96fe=a728_0xd20a;'use strict';const EventEmitter=require('events'),VoiceExtension=require(_0x3a96fe('0x2'))['db'][_0x3a96fe('0x3')],VoiceExtensionEvents=new EventEmitter();VoiceExtensionEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x3a96fe('0x1'),'afterUpdate':'update','afterDestroy':_0x3a96fe('0x6')};function emitEvent(_0x4571b2){return function(_0xf0c8bb){const _0x59bdf2=a728_0xd20a;VoiceExtensionEvents[_0x59bdf2('0x4')](_0x4571b2+':'+_0xf0c8bb['id'],_0xf0c8bb),VoiceExtensionEvents[_0x59bdf2('0x4')](_0x4571b2,_0xf0c8bb);};}for(const e in events){if(typeof events[e]!==_0x3a96fe('0x5')){const event=events[e];VoiceExtension[_0x3a96fe('0x0')](e,emitEvent(event));}}module['exports']=VoiceExtensionEvents; \ No newline at end of file diff --git a/server/api/voiceExtension/voiceExtension.model.js b/server/api/voiceExtension/voiceExtension.model.js index f3be186..705a659 100644 --- a/server/api/voiceExtension/voiceExtension.model.js +++ b/server/api/voiceExtension/voiceExtension.model.js @@ -1 +1 @@ -const a729_0x4856=['voice_extensions','define'];(function(_0x57ad33,_0x485667){const _0x9b86d3=function(_0x2fc8be){while(--_0x2fc8be){_0x57ad33['push'](_0x57ad33['shift']());}};_0x9b86d3(++_0x485667);}(a729_0x4856,0x152));const a729_0x9b86=function(_0x57ad33,_0x485667){_0x57ad33=_0x57ad33-0x0;let _0x9b86d3=a729_0x4856[_0x57ad33];return _0x9b86d3;};'use strict';const attributes=require('./voiceExtension.attributes');module['exports']=function(_0x2fc8be){const _0x43d0ee=a729_0x9b86,_0x45eee2=_0x2fc8be[_0x43d0ee('0x1')]('VoiceExtension',attributes,{'tableName':_0x43d0ee('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x45eee2;}; \ No newline at end of file +const a729_0x194a=['VoiceExtension','define'];(function(_0x52c6f6,_0x194aa0){const _0x41a20c=function(_0x503003){while(--_0x503003){_0x52c6f6['push'](_0x52c6f6['shift']());}};_0x41a20c(++_0x194aa0);}(a729_0x194a,0x1e0));const a729_0x41a2=function(_0x52c6f6,_0x194aa0){_0x52c6f6=_0x52c6f6-0x0;let _0x41a20c=a729_0x194a[_0x52c6f6];return _0x41a20c;};'use strict';const attributes=require('./voiceExtension.attributes');module['exports']=function(_0x503003){const _0xc14178=a729_0x41a2,_0x133a41=_0x503003[_0xc14178('0x1')](_0xc14178('0x0'),attributes,{'tableName':'voice_extensions','paranoid':![],'indexes':[],'timestamps':!![]});return _0x133a41;}; \ No newline at end of file diff --git a/server/api/voiceExtension/voiceExtension.rpc.js b/server/api/voiceExtension/voiceExtension.rpc.js index bbac78b..73a6eba 100644 --- a/server/api/voiceExtension/voiceExtension.rpc.js +++ b/server/api/voiceExtension/voiceExtension.rpc.js @@ -1 +1 @@ -const a730_0x5bb5=['model','limit','GetVoiceExtension','./voiceExtension.socket','register','findAll','include','options','rpc','info','stringify','then','debug','error','map','attributes','message','raw','lodash','../../config/logger','../../mysqldb','where','VoiceExtension'];(function(_0x218eed,_0x5bb5b4){const _0x460ca8=function(_0x218518){while(--_0x218518){_0x218eed['push'](_0x218eed['shift']());}};_0x460ca8(++_0x5bb5b4);}(a730_0x5bb5,0xe0));const a730_0x460c=function(_0x218eed,_0x5bb5b4){_0x218eed=_0x218eed-0x0;let _0x460ca8=a730_0x5bb5[_0x218eed];return _0x460ca8;};const _0x4dd9b9=a730_0x460c;'use strict';const _=require(_0x4dd9b9('0x1')),db=require(_0x4dd9b9('0x3'))['db'],logger=require(_0x4dd9b9('0x2'))(_0x4dd9b9('0xe')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x4dd9b9('0x9'))[_0x4dd9b9('0xa')](socket),exports[_0x4dd9b9('0x8')]=function(_0x218518){const _0x486397=this;return new Promise(function(_0x2a8228,_0x4c6bfb){const _0x39ce99=a730_0x460c;return db[_0x39ce99('0x5')][_0x39ce99('0xb')]({'raw':_0x218518['options']?_0x218518[_0x39ce99('0xd')][_0x39ce99('0x0')]===undefined?!![]:![]:!![],'where':_0x218518['options']?_0x218518['options'][_0x39ce99('0x4')]||null:null,'attributes':_0x218518['options']?_0x218518[_0x39ce99('0xd')]['attributes']||null:null,'limit':_0x218518[_0x39ce99('0xd')]?_0x218518['options'][_0x39ce99('0x7')]||null:null,'include':_0x218518['options']?_0x218518[_0x39ce99('0xd')][_0x39ce99('0xc')]?_['map'](_0x218518[_0x39ce99('0xd')][_0x39ce99('0xc')],function(_0x5c251d){const _0x21fe28=_0x39ce99;return{'model':db[_0x5c251d[_0x21fe28('0x6')]],'as':_0x5c251d['as'],'attributes':_0x5c251d[_0x21fe28('0x15')],'include':_0x5c251d[_0x21fe28('0xc')]?_[_0x21fe28('0x14')](_0x5c251d[_0x21fe28('0xc')],function(_0x1946fa){const _0x47bd64=_0x21fe28;return{'model':db[_0x1946fa[_0x47bd64('0x6')]],'as':_0x1946fa['as'],'attributes':_0x1946fa[_0x47bd64('0x15')],'include':_0x1946fa[_0x47bd64('0xc')]?_[_0x47bd64('0x14')](_0x1946fa[_0x47bd64('0xc')],function(_0x193f4b){const _0x37169a=_0x47bd64;return{'model':db[_0x193f4b[_0x37169a('0x6')]],'as':_0x193f4b['as'],'attributes':_0x193f4b[_0x37169a('0x15')]};}):[]};}):[]};}):[]:[]})[_0x39ce99('0x11')](function(_0xa846f){const _0xe9cd19=_0x39ce99;logger[_0xe9cd19('0xf')]('GetVoiceExtension',_0x218518),logger[_0xe9cd19('0x12')](_0xe9cd19('0x8'),_0x218518,JSON[_0xe9cd19('0x10')](_0xa846f)),_0x2a8228(_0xa846f);})['catch'](function(_0x54ee18){const _0x4e121a=_0x39ce99;logger['error'](_0x4e121a('0x8'),_0x54ee18[_0x4e121a('0x16')],_0x218518),_0x4c6bfb(_0x486397[_0x4e121a('0x13')](0x1f4,_0x54ee18[_0x4e121a('0x16')]));});});}; \ No newline at end of file +const a730_0x2244=['stringify','debug','message','../../mysqldb','info','model','VoiceExtension','register','./voiceExtension.socket','where','error','include','attributes','then','raw','map','options','lodash','GetVoiceExtension','limit','catch'];(function(_0x5370a5,_0x224404){const _0x3e1cbc=function(_0x546e4c){while(--_0x546e4c){_0x5370a5['push'](_0x5370a5['shift']());}};_0x3e1cbc(++_0x224404);}(a730_0x2244,0x14f));const a730_0x3e1c=function(_0x5370a5,_0x224404){_0x5370a5=_0x5370a5-0x0;let _0x3e1cbc=a730_0x2244[_0x5370a5];return _0x3e1cbc;};const _0x4952be=a730_0x3e1c;'use strict';const _=require(_0x4952be('0x12')),db=require(_0x4952be('0x4'))['db'],logger=require('../../config/logger')('rpc'),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x4952be('0x9'))[_0x4952be('0x8')](socket),exports['GetVoiceExtension']=function(_0x546e4c){const _0x1199bf=this;return new Promise(function(_0x26e20f,_0x15f2a5){const _0xd69109=a730_0x3e1c;return db[_0xd69109('0x7')]['findAll']({'raw':_0x546e4c[_0xd69109('0x11')]?_0x546e4c[_0xd69109('0x11')][_0xd69109('0xf')]===undefined?!![]:![]:!![],'where':_0x546e4c[_0xd69109('0x11')]?_0x546e4c[_0xd69109('0x11')][_0xd69109('0xa')]||null:null,'attributes':_0x546e4c[_0xd69109('0x11')]?_0x546e4c[_0xd69109('0x11')][_0xd69109('0xd')]||null:null,'limit':_0x546e4c[_0xd69109('0x11')]?_0x546e4c[_0xd69109('0x11')][_0xd69109('0x14')]||null:null,'include':_0x546e4c['options']?_0x546e4c['options']['include']?_['map'](_0x546e4c[_0xd69109('0x11')][_0xd69109('0xc')],function(_0xa8283){const _0xd136c1=_0xd69109;return{'model':db[_0xa8283[_0xd136c1('0x6')]],'as':_0xa8283['as'],'attributes':_0xa8283[_0xd136c1('0xd')],'include':_0xa8283[_0xd136c1('0xc')]?_[_0xd136c1('0x10')](_0xa8283[_0xd136c1('0xc')],function(_0x35038e){const _0x21edf2=_0xd136c1;return{'model':db[_0x35038e[_0x21edf2('0x6')]],'as':_0x35038e['as'],'attributes':_0x35038e[_0x21edf2('0xd')],'include':_0x35038e[_0x21edf2('0xc')]?_[_0x21edf2('0x10')](_0x35038e[_0x21edf2('0xc')],function(_0x1af993){const _0x5afa36=_0x21edf2;return{'model':db[_0x1af993['model']],'as':_0x1af993['as'],'attributes':_0x1af993[_0x5afa36('0xd')]};}):[]};}):[]};}):[]:[]})[_0xd69109('0xe')](function(_0x59858d){const _0x4b409c=_0xd69109;logger[_0x4b409c('0x5')](_0x4b409c('0x13'),_0x546e4c),logger[_0x4b409c('0x2')](_0x4b409c('0x13'),_0x546e4c,JSON[_0x4b409c('0x1')](_0x59858d)),_0x26e20f(_0x59858d);})[_0xd69109('0x0')](function(_0x33685d){const _0x32cb44=_0xd69109;logger[_0x32cb44('0xb')]('GetVoiceExtension',_0x33685d[_0x32cb44('0x3')],_0x546e4c),_0x15f2a5(_0x1199bf[_0x32cb44('0xb')](0x1f4,_0x33685d[_0x32cb44('0x3')]));});});}; \ No newline at end of file diff --git a/server/api/voiceExtension/voiceExtension.socket.js b/server/api/voiceExtension/voiceExtension.socket.js index bce0d83..ef179db 100644 --- a/server/api/voiceExtension/voiceExtension.socket.js +++ b/server/api/voiceExtension/voiceExtension.socket.js @@ -1 +1 @@ -const a731_0x7d1f=['save','update','voiceExtension:','register','remove','./voiceExtension.events'];(function(_0x9449e6,_0x7d1f4){const _0x10c67a=function(_0x53ddca){while(--_0x53ddca){_0x9449e6['push'](_0x9449e6['shift']());}};_0x10c67a(++_0x7d1f4);}(a731_0x7d1f,0x103));const a731_0x10c6=function(_0x9449e6,_0x7d1f4){_0x9449e6=_0x9449e6-0x0;let _0x10c67a=a731_0x7d1f[_0x9449e6];return _0x10c67a;};const _0x4d05ad=a731_0x10c6;'use strict';const VoiceExtensionEvents=require(_0x4d05ad('0x4')),events=[_0x4d05ad('0x5'),_0x4d05ad('0x3'),_0x4d05ad('0x0')];function createListener(_0x53ddca,_0x9a7a3c){return function(_0xcce226){_0x9a7a3c['emit'](_0x53ddca,_0xcce226);};}exports[_0x4d05ad('0x2')]=function(_0x5d9701){const _0x240754=_0x4d05ad;for(let _0x5aac4f=0x0,_0x1bc2a1=events['length'];_0x5aac4f<_0x1bc2a1;_0x5aac4f++){const _0x502d17=events[_0x5aac4f],_0xa9eee0=createListener(_0x240754('0x1')+_0x502d17,_0x5d9701);VoiceExtensionEvents['on'](_0x502d17,_0xa9eee0);}}; \ No newline at end of file +const a731_0x3814=['register','update','emit','voiceExtension:','remove','length','./voiceExtension.events'];(function(_0x484795,_0x3814e5){const _0x402cba=function(_0x287bdc){while(--_0x287bdc){_0x484795['push'](_0x484795['shift']());}};_0x402cba(++_0x3814e5);}(a731_0x3814,0x1e6));const a731_0x402c=function(_0x484795,_0x3814e5){_0x484795=_0x484795-0x0;let _0x402cba=a731_0x3814[_0x484795];return _0x402cba;};const _0x4beed6=a731_0x402c;'use strict';const VoiceExtensionEvents=require(_0x4beed6('0x3')),events=['save',_0x4beed6('0x1'),_0x4beed6('0x5')];function createListener(_0x287bdc,_0x3cdc0b){return function(_0x3c754e){const _0x33f67c=a731_0x402c;_0x3cdc0b[_0x33f67c('0x6')](_0x287bdc,_0x3c754e);};}exports[_0x4beed6('0x4')]=function(_0x4bdbe1){const _0x175ef2=_0x4beed6;for(let _0x5f389c=0x0,_0xd1819d=events[_0x175ef2('0x2')];_0x5f389c<_0xd1819d;_0x5f389c++){const _0x62a83d=events[_0x5f389c],_0x4abc27=createListener(_0x175ef2('0x0')+_0x62a83d,_0x4bdbe1);VoiceExtensionEvents['on'](_0x62a83d,_0x4abc27);}}; \ No newline at end of file diff --git a/server/api/voiceMail/index.js b/server/api/voiceMail/index.js index fb9735a..2351585 100644 --- a/server/api/voiceMail/index.js +++ b/server/api/voiceMail/index.js @@ -1 +1 @@ -const a732_0x3206=['../../components/auth/service','get','isAuthenticated','/:id','post','./voiceMail.controller','index','getMessages','put','show','destroy','create','express'];(function(_0x28651a,_0x320620){const _0x460378=function(_0x16066e){while(--_0x16066e){_0x28651a['push'](_0x28651a['shift']());}};_0x460378(++_0x320620);}(a732_0x3206,0x97));const a732_0x4603=function(_0x28651a,_0x320620){_0x28651a=_0x28651a-0x0;let _0x460378=a732_0x3206[_0x28651a];return _0x460378;};const _0x227eca=a732_0x4603;'use strict';const express=require(_0x227eca('0x4')),router=express['Router'](),auth=require(_0x227eca('0x5')),controller=require(_0x227eca('0xa'));router[_0x227eca('0x6')]('/',auth[_0x227eca('0x7')](),controller[_0x227eca('0xb')]),router[_0x227eca('0x6')](_0x227eca('0x8'),auth[_0x227eca('0x7')](),controller[_0x227eca('0x1')]),router[_0x227eca('0x6')]('/:id/messages',auth[_0x227eca('0x7')](),controller[_0x227eca('0xc')]),router[_0x227eca('0x9')]('/',auth[_0x227eca('0x7')](),controller[_0x227eca('0x3')]),router[_0x227eca('0x0')](_0x227eca('0x8'),auth['isAuthenticated'](),controller['update']),router['delete'](_0x227eca('0x8'),auth[_0x227eca('0x7')](),controller[_0x227eca('0x2')]),module['exports']=router; \ No newline at end of file +const a732_0x3c0c=['exports','show','/:id','isAuthenticated','express','get','create','delete','update','/:id/messages','Router','put','../../components/auth/service','getMessages','./voiceMail.controller'];(function(_0x19c4b5,_0x3c0c03){const _0x1111f8=function(_0x3c8e2c){while(--_0x3c8e2c){_0x19c4b5['push'](_0x19c4b5['shift']());}};_0x1111f8(++_0x3c0c03);}(a732_0x3c0c,0x105));const a732_0x1111=function(_0x19c4b5,_0x3c0c03){_0x19c4b5=_0x19c4b5-0x0;let _0x1111f8=a732_0x3c0c[_0x19c4b5];return _0x1111f8;};const _0x262c5b=a732_0x1111;'use strict';const express=require(_0x262c5b('0xd')),router=express[_0x262c5b('0x4')](),auth=require(_0x262c5b('0x6')),controller=require(_0x262c5b('0x8'));router[_0x262c5b('0xe')]('/',auth['isAuthenticated'](),controller['index']),router[_0x262c5b('0xe')]('/:id',auth[_0x262c5b('0xc')](),controller[_0x262c5b('0xa')]),router[_0x262c5b('0xe')](_0x262c5b('0x3'),auth[_0x262c5b('0xc')](),controller[_0x262c5b('0x7')]),router['post']('/',auth['isAuthenticated'](),controller[_0x262c5b('0x0')]),router[_0x262c5b('0x5')]('/:id',auth['isAuthenticated'](),controller[_0x262c5b('0x2')]),router[_0x262c5b('0x1')](_0x262c5b('0xb'),auth[_0x262c5b('0xc')](),controller['destroy']),module[_0x262c5b('0x9')]=router; \ No newline at end of file diff --git a/server/api/voiceMail/voiceMail.attributes.js b/server/api/voiceMail/voiceMail.attributes.js index c068224..e0884fc 100644 --- a/server/api/voiceMail/voiceMail.attributes.js +++ b/server/api/voiceMail/voiceMail.attributes.js @@ -1 +1 @@ -const a733_0x28a3=['from-voicemail','STRING','TIMESTAMP','string','getDataValue','fullname','ENUM','email','trim','TINYINT(4)','VIRTUAL','yes','INTEGER'];(function(_0x1baa06,_0x28a349){const _0x40d153=function(_0x2f0ff6){while(--_0x2f0ff6){_0x1baa06['push'](_0x1baa06['shift']());}};_0x40d153(++_0x28a349);}(a733_0x28a3,0x1c6));const a733_0x40d1=function(_0x1baa06,_0x28a349){_0x1baa06=_0x1baa06-0x0;let _0x40d153=a733_0x28a3[_0x1baa06];return _0x40d153;};const _0x4b4001=a733_0x40d1;'use strict';const Sequelize=require('sequelize');module['exports']={'customer_id':{'type':Sequelize[_0x4b4001('0x2')]},'context':{'type':Sequelize[_0x4b4001('0x2')],'defaultValue':_0x4b4001('0x1'),'unique':'contest_mailbox'},'mailbox':{'type':Sequelize['STRING'],'defaultValue':'','allowNull':![],'unique':'contest_mailbox'},'password':{'type':Sequelize[_0x4b4001('0x2')]},'fullname':{'type':Sequelize[_0x4b4001('0x2')]},'email':{'type':Sequelize[_0x4b4001('0x2')],'validate':{'isEmail':!![]},'set':function(_0x2f0ff6){const _0x528452=_0x4b4001;this['setDataValue'](_0x528452('0x8'),typeof _0x2f0ff6===_0x528452('0x4')&&_0x2f0ff6[_0x528452('0x9')]()?_0x2f0ff6[_0x528452('0x9')]():null);}},'pager':{'type':Sequelize['STRING']},'tz':{'type':Sequelize['STRING'],'defaultValue':'central'},'attach':{'type':Sequelize['ENUM'](_0x4b4001('0xc'),'no'),'defaultValue':_0x4b4001('0xc'),'allowNull':![]},'saycid':{'type':Sequelize[_0x4b4001('0x7')](_0x4b4001('0xc'),'no'),'defaultValue':'yes','allowNull':![]},'dialout':{'type':Sequelize[_0x4b4001('0x2')]},'callback':{'type':Sequelize[_0x4b4001('0x2')]},'review':{'type':Sequelize[_0x4b4001('0x7')](_0x4b4001('0xc'),'no'),'defaultValue':'no','allowNull':![]},'operator':{'type':Sequelize['ENUM'](_0x4b4001('0xc'),'no'),'defaultValue':'no','allowNull':![]},'envelope':{'type':Sequelize[_0x4b4001('0x7')]('yes','no'),'defaultValue':'no','allowNull':![]},'sayduration':{'type':Sequelize[_0x4b4001('0x7')](_0x4b4001('0xc'),'no'),'defaultValue':'no','allowNull':![]},'saydurationm':{'type':_0x4b4001('0xa'),'defaultValue':0x1,'allowNull':![]},'sendvoicemail':{'type':Sequelize[_0x4b4001('0x7')](_0x4b4001('0xc'),'no'),'defaultValue':'no','allowNull':![]},'delete':{'type':Sequelize[_0x4b4001('0x7')]('yes','no'),'defaultValue':'no','allowNull':![]},'nextaftercmd':{'type':Sequelize[_0x4b4001('0x7')](_0x4b4001('0xc'),'no'),'defaultValue':_0x4b4001('0xc'),'allowNull':![]},'forcename':{'type':Sequelize[_0x4b4001('0x7')](_0x4b4001('0xc'),'no'),'defaultValue':'no','allowNull':![]},'forcegreetings':{'type':Sequelize[_0x4b4001('0x7')](_0x4b4001('0xc'),'no'),'defaultValue':'no','allowNull':![]},'hidefromdir':{'type':Sequelize[_0x4b4001('0x7')](_0x4b4001('0xc'),'no'),'defaultValue':_0x4b4001('0xc'),'allowNull':![]},'stamp':{'type':_0x4b4001('0x3')},'emailsubject':{'type':Sequelize['STRING']},'emailbody':{'type':Sequelize[_0x4b4001('0x2')]},'maxsecs':{'type':Sequelize[_0x4b4001('0x0')](0xff),'defaultValue':0xb4,'allowNull':![]},'maxmsg':{'type':Sequelize[_0x4b4001('0x0')](0xff),'defaultValue':0x64,'allowNull':![]},'name':{'type':Sequelize[_0x4b4001('0xb')],'get':function(){const _0xcc4205=_0x4b4001;return this[_0xcc4205('0x5')](_0xcc4205('0x6'))+'\x20-\x20'+this[_0xcc4205('0x5')]('mailbox');}}}; \ No newline at end of file +const a733_0xdcea=['mailbox','INTEGER','string','STRING','trim','yes','ENUM','email','VIRTUAL','exports','TIMESTAMP','contest_mailbox','\x20-\x20','setDataValue','sequelize'];(function(_0x2dc20e,_0xdceab2){const _0x24d052=function(_0x2a4ae8){while(--_0x2a4ae8){_0x2dc20e['push'](_0x2dc20e['shift']());}};_0x24d052(++_0xdceab2);}(a733_0xdcea,0x8b));const a733_0x24d0=function(_0x2dc20e,_0xdceab2){_0x2dc20e=_0x2dc20e-0x0;let _0x24d052=a733_0xdcea[_0x2dc20e];return _0x24d052;};const _0x59c509=a733_0x24d0;'use strict';const Sequelize=require(_0x59c509('0xa'));module[_0x59c509('0x5')]={'customer_id':{'type':Sequelize[_0x59c509('0xe')]},'context':{'type':Sequelize[_0x59c509('0xe')],'defaultValue':'from-voicemail','unique':_0x59c509('0x7')},'mailbox':{'type':Sequelize['STRING'],'defaultValue':'','allowNull':![],'unique':_0x59c509('0x7')},'password':{'type':Sequelize['STRING']},'fullname':{'type':Sequelize[_0x59c509('0xe')]},'email':{'type':Sequelize[_0x59c509('0xe')],'validate':{'isEmail':!![]},'set':function(_0x2a4ae8){const _0x283ac3=_0x59c509;this[_0x283ac3('0x9')](_0x283ac3('0x3'),typeof _0x2a4ae8===_0x283ac3('0xd')&&_0x2a4ae8[_0x283ac3('0x0')]()?_0x2a4ae8[_0x283ac3('0x0')]():null);}},'pager':{'type':Sequelize[_0x59c509('0xe')]},'tz':{'type':Sequelize[_0x59c509('0xe')],'defaultValue':'central'},'attach':{'type':Sequelize[_0x59c509('0x2')](_0x59c509('0x1'),'no'),'defaultValue':'yes','allowNull':![]},'saycid':{'type':Sequelize['ENUM'](_0x59c509('0x1'),'no'),'defaultValue':_0x59c509('0x1'),'allowNull':![]},'dialout':{'type':Sequelize[_0x59c509('0xe')]},'callback':{'type':Sequelize['STRING']},'review':{'type':Sequelize['ENUM']('yes','no'),'defaultValue':'no','allowNull':![]},'operator':{'type':Sequelize[_0x59c509('0x2')]('yes','no'),'defaultValue':'no','allowNull':![]},'envelope':{'type':Sequelize[_0x59c509('0x2')](_0x59c509('0x1'),'no'),'defaultValue':'no','allowNull':![]},'sayduration':{'type':Sequelize[_0x59c509('0x2')](_0x59c509('0x1'),'no'),'defaultValue':'no','allowNull':![]},'saydurationm':{'type':'TINYINT(4)','defaultValue':0x1,'allowNull':![]},'sendvoicemail':{'type':Sequelize[_0x59c509('0x2')](_0x59c509('0x1'),'no'),'defaultValue':'no','allowNull':![]},'delete':{'type':Sequelize[_0x59c509('0x2')](_0x59c509('0x1'),'no'),'defaultValue':'no','allowNull':![]},'nextaftercmd':{'type':Sequelize[_0x59c509('0x2')](_0x59c509('0x1'),'no'),'defaultValue':_0x59c509('0x1'),'allowNull':![]},'forcename':{'type':Sequelize[_0x59c509('0x2')](_0x59c509('0x1'),'no'),'defaultValue':'no','allowNull':![]},'forcegreetings':{'type':Sequelize[_0x59c509('0x2')]('yes','no'),'defaultValue':'no','allowNull':![]},'hidefromdir':{'type':Sequelize[_0x59c509('0x2')](_0x59c509('0x1'),'no'),'defaultValue':'yes','allowNull':![]},'stamp':{'type':_0x59c509('0x6')},'emailsubject':{'type':Sequelize[_0x59c509('0xe')]},'emailbody':{'type':Sequelize[_0x59c509('0xe')]},'maxsecs':{'type':Sequelize[_0x59c509('0xc')](0xff),'defaultValue':0xb4,'allowNull':![]},'maxmsg':{'type':Sequelize[_0x59c509('0xc')](0xff),'defaultValue':0x64,'allowNull':![]},'name':{'type':Sequelize[_0x59c509('0x4')],'get':function(){const _0x561359=_0x59c509;return this['getDataValue']('fullname')+_0x561359('0x8')+this['getDataValue'](_0x561359('0xb'));}}}; \ No newline at end of file diff --git a/server/api/voiceMail/voiceMail.controller.js b/server/api/voiceMail/voiceMail.controller.js index f554463..0f893cd 100644 --- a/server/api/voiceMail/voiceMail.controller.js +++ b/server/api/voiceMail/voiceMail.controller.js @@ -1 +1 @@ -const a734_0x84dc=['userProfileId','mailbox','offset','catch','VoiceMailMessage','status','params','count','user','rawAttributes','../../config/logger','include','json','UserProfileResource','filter','length','order','VoiceMail','stack','end','map','autoAssociation','name','update','UserProfileSection','lodash','create','pick','key','filters','destroy','index','includeAll','sendStatus','getMessages','VIRTUAL','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','options','show','set','api','Unable\x20to\x20retrieve\x20the\x20current\x20user','fields','model','sort','Voicemails','then','intersection','findOne','where','query','like','../../components/parsers/qs','merge','keys','send','body','findAndCountAll','sequelize','limit','findAll','nolimit','Content-Range','error','attributes','get'];(function(_0x22fe14,_0x84dc46){const _0x1f6ca2=function(_0x3aa173){while(--_0x3aa173){_0x22fe14['push'](_0x22fe14['shift']());}};_0x1f6ca2(++_0x84dc46);}(a734_0x84dc,0x1af));const a734_0x1f6c=function(_0x22fe14,_0x84dc46){_0x22fe14=_0x22fe14-0x0;let _0x1f6ca2=a734_0x84dc[_0x22fe14];return _0x1f6ca2;};const _0x1cb058=a734_0x1f6c;'use strict';const _=require(_0x1cb058('0x38')),qs=require(_0x1cb058('0x11')),logger=require(_0x1cb058('0x29'))(_0x1cb058('0x5')),db=require('../../mysqldb')['db'],{Op}=require(_0x1cb058('0x17'));function respondWithResult(_0x3aa173,_0x59b173){return _0x59b173=_0x59b173||0xc8,function(_0x3f0d95){const _0x5c5271=a734_0x1f6c;if(_0x3f0d95)return _0x3aa173[_0x5c5271('0x24')](_0x59b173)['json'](_0x3f0d95);};}function respondWithFilteredResult(_0x1aeb26,_0x511626){return function(_0x360dd1){const _0xfcdd9=a734_0x1f6c;if(_0x360dd1){const _0x4f24e8=_0x360dd1[_0xfcdd9('0x26')],_0x57a721=_0x511626['offset'];let _0x3f18fd=_0x511626[_0xfcdd9('0x21')]+_0x511626['limit'],_0x38d467;return _0x3f18fd>=_0x4f24e8?(_0x3f18fd=_0x4f24e8,_0x38d467=0xc8):_0x38d467=0xce,_0x1aeb26[_0xfcdd9('0x24')](_0x38d467),_0x1aeb26[_0xfcdd9('0x4')](_0xfcdd9('0x1b'),_0x57a721+'-'+_0x3f18fd+'/'+_0x4f24e8)[_0xfcdd9('0x2b')](_0x360dd1);}return null;};}function saveUpdates(_0x181b5d){return function(_0x3688d0){const _0x5cbe8e=a734_0x1f6c;if(_0x3688d0)return _0x3688d0[_0x5cbe8e('0x36')](_0x181b5d)[_0x5cbe8e('0xb')](function(_0x8b0a2f){return _0x8b0a2f;});return null;};}function removeEntity(_0x32c723){return function(_0x5b5c43){const _0x1d97b0=a734_0x1f6c;if(_0x5b5c43)return _0x5b5c43[_0x1d97b0('0x3d')]()['then'](function(){const _0x4d5dd7=_0x1d97b0,_0x4adf2e=_0x5b5c43['get']({'plain':!![]}),_0x1d5b3b='Voicemails';return db[_0x4d5dd7('0x2c')][_0x4d5dd7('0x3d')]({'where':{'type':_0x1d5b3b,'resourceId':_0x4adf2e['id']}})[_0x4d5dd7('0xb')](function(){return _0x5b5c43;});})['then'](function(){const _0x39d664=_0x1d97b0;_0x32c723[_0x39d664('0x24')](0xcc)[_0x39d664('0x32')]();});};}function handleEntityNotFound(_0x72652e){return function(_0x5a0174){const _0x351480=a734_0x1f6c;return!_0x5a0174&&_0x72652e[_0x351480('0x40')](0x194),_0x5a0174;};}function handleError(_0x4d0db4,_0xc5fa4e){return _0xc5fa4e=_0xc5fa4e||0x1f4,function(_0x523463){const _0x4a1530=a734_0x1f6c;logger[_0x4a1530('0x1c')](_0x523463[_0x4a1530('0x31')]),_0x523463[_0x4a1530('0x35')]&&delete _0x523463['name'],_0x4d0db4['status'](_0xc5fa4e)[_0x4a1530('0x14')](_0x523463);};}exports[_0x1cb058('0x3e')]=function(_0x2ecb1e,_0x5f4b7e){const _0x1373c3=_0x1cb058;let _0x32d72f={};const _0x4b27c9={},_0x400500={'count':0x0,'rows':[]},_0x5e77af=_['map'](db[_0x1373c3('0x30')][_0x1373c3('0x28')],function(_0x18fe1d){const _0x2b097a=_0x1373c3;return{'name':_0x18fe1d['fieldName'],'type':_0x18fe1d['type'][_0x2b097a('0x3b')]};});_0x4b27c9['model']=_[_0x1373c3('0x33')](_0x5e77af,_0x1373c3('0x35')),_0x4b27c9[_0x1373c3('0xf')]=_[_0x1373c3('0x13')](_0x2ecb1e[_0x1373c3('0xf')]),_0x4b27c9[_0x1373c3('0x3c')]=_['intersection'](_0x4b27c9[_0x1373c3('0x8')],_0x4b27c9[_0x1373c3('0xf')]),_0x32d72f[_0x1373c3('0x1d')]=_[_0x1373c3('0xc')](_0x4b27c9[_0x1373c3('0x8')],qs[_0x1373c3('0x7')](_0x2ecb1e['query'][_0x1373c3('0x7')])),_0x32d72f[_0x1373c3('0x1d')]=_0x32d72f[_0x1373c3('0x1d')]['length']?_0x32d72f[_0x1373c3('0x1d')]:_0x4b27c9['model'];typeof _0x2ecb1e[_0x1373c3('0xf')][_0x1373c3('0x1a')]==='undefined'&&(_0x32d72f[_0x1373c3('0x18')]=qs['limit'](_0x2ecb1e['query']['limit']),_0x32d72f[_0x1373c3('0x21')]=qs[_0x1373c3('0x21')](_0x2ecb1e[_0x1373c3('0xf')][_0x1373c3('0x21')]));_0x32d72f[_0x1373c3('0x2f')]=qs[_0x1373c3('0x9')](_0x2ecb1e['query'][_0x1373c3('0x9')]),_0x32d72f[_0x1373c3('0xe')]=qs[_0x1373c3('0x3c')](_[_0x1373c3('0x3a')](_0x2ecb1e[_0x1373c3('0xf')],_0x4b27c9[_0x1373c3('0x3c')]),_0x5e77af);_0x2ecb1e[_0x1373c3('0xf')][_0x1373c3('0x2d')]&&(_0x32d72f['where']=_[_0x1373c3('0x12')](_0x32d72f[_0x1373c3('0xe')],{[Op['or']]:_[_0x1373c3('0x33')](_0x5e77af,function(_0x3458c4){const _0x40197b=_0x1373c3;if(_0x3458c4['type']!==_0x40197b('0x0')){const _0xc566a4={};return _0xc566a4[_0x3458c4[_0x40197b('0x35')]]={[Op[_0x40197b('0x10')]]:'%'+_0x2ecb1e[_0x40197b('0xf')][_0x40197b('0x2d')]+'%'},_0xc566a4;}})}));_0x32d72f=_[_0x1373c3('0x12')]({},_0x32d72f,_0x2ecb1e[_0x1373c3('0x2')]);const _0x597411={'where':_0x32d72f[_0x1373c3('0xe')]};return db[_0x1373c3('0x30')][_0x1373c3('0x26')](_0x597411)[_0x1373c3('0xb')](function(_0x1d3ea0){const _0x4dcd18=_0x1373c3;return _0x400500['count']=_0x1d3ea0,_0x2ecb1e['query'][_0x4dcd18('0x3f')]&&(_0x32d72f[_0x4dcd18('0x2a')]=[{'all':!![]}]),db[_0x4dcd18('0x30')][_0x4dcd18('0x19')](_0x32d72f);})[_0x1373c3('0xb')](function(_0x803a6e){return _0x400500['rows']=_0x803a6e,_0x400500;})[_0x1373c3('0xb')](respondWithFilteredResult(_0x5f4b7e,_0x32d72f))['catch'](handleError(_0x5f4b7e,null));},exports[_0x1cb058('0x3')]=function(_0x42e9c6,_0x2f83c3){const _0x588acf=_0x1cb058;let _0x3a561a={'raw':!![],'where':{'id':_0x42e9c6[_0x588acf('0x25')]['id']}};const _0x458f17={};return _0x458f17[_0x588acf('0x8')]=_[_0x588acf('0x13')](db['VoiceMail']['rawAttributes']),_0x458f17['query']=_[_0x588acf('0x13')](_0x42e9c6[_0x588acf('0xf')]),_0x458f17[_0x588acf('0x3c')]=_['intersection'](_0x458f17[_0x588acf('0x8')],_0x458f17[_0x588acf('0xf')]),_0x3a561a[_0x588acf('0x1d')]=_[_0x588acf('0xc')](_0x458f17[_0x588acf('0x8')],qs['fields'](_0x42e9c6[_0x588acf('0xf')][_0x588acf('0x7')])),_0x3a561a['attributes']=_0x3a561a['attributes'][_0x588acf('0x2e')]?_0x3a561a['attributes']:_0x458f17[_0x588acf('0x8')],_0x42e9c6[_0x588acf('0xf')][_0x588acf('0x3f')]&&(_0x3a561a[_0x588acf('0x2a')]=[{'all':!![]}]),_0x3a561a=_['merge']({},_0x3a561a,_0x42e9c6[_0x588acf('0x2')]),db[_0x588acf('0x30')]['findOne'](_0x3a561a)['then'](handleEntityNotFound(_0x2f83c3,null))[_0x588acf('0xb')](respondWithResult(_0x2f83c3,null))[_0x588acf('0x22')](handleError(_0x2f83c3,null));},exports[_0x1cb058('0x39')]=function(_0x39d269,_0x47bf62){const _0x3897d4=_0x1cb058;return db[_0x3897d4('0x30')][_0x3897d4('0x39')](_0x39d269[_0x3897d4('0x15')],{})[_0x3897d4('0xb')](function(_0x57b9e7){const _0x2e7807=_0x3897d4,_0xf2ccad=_0x39d269[_0x2e7807('0x27')][_0x2e7807('0x1e')]({'plain':!![]});if(!_0xf2ccad)throw new Error(_0x2e7807('0x6'));if(_0xf2ccad['role']===_0x2e7807('0x27')){const _0xd1eb7c=_0x57b9e7[_0x2e7807('0x1e')]({'plain':!![]}),_0x4e9b9f=_0x2e7807('0xa');return db[_0x2e7807('0x37')][_0x2e7807('0xd')]({'where':{'name':_0x4e9b9f,'userProfileId':_0xf2ccad[_0x2e7807('0x1f')]},'raw':!![]})[_0x2e7807('0xb')](function(_0x569f4b){const _0x166507=_0x2e7807;return _0x569f4b&&_0x569f4b[_0x166507('0x34')]===0x0?db[_0x166507('0x2c')][_0x166507('0x39')]({'name':_0xd1eb7c[_0x166507('0x35')],'resourceId':_0xd1eb7c['id'],'type':_0x569f4b[_0x166507('0x35')],'sectionId':_0x569f4b['id']},{})[_0x166507('0xb')](function(){return _0x57b9e7;}):_0x57b9e7;})[_0x2e7807('0x22')](function(_0x44ddb4){const _0x198a5c=_0x2e7807;logger['error'](_0x198a5c('0x1'),_0x44ddb4);throw _0x44ddb4;});}return _0x57b9e7;})[_0x3897d4('0xb')](respondWithResult(_0x47bf62,0xc9))[_0x3897d4('0x22')](handleError(_0x47bf62,null));},exports[_0x1cb058('0x36')]=function(_0xae4471,_0x4eb93c){const _0x3d76a7=_0x1cb058;return _0xae4471['body']['id']&&delete _0xae4471[_0x3d76a7('0x15')]['id'],db['VoiceMail']['findOne']({'where':{'id':_0xae4471[_0x3d76a7('0x25')]['id']}})['then'](handleEntityNotFound(_0x4eb93c,null))['then'](saveUpdates(_0xae4471[_0x3d76a7('0x15')],null))[_0x3d76a7('0xb')](respondWithResult(_0x4eb93c,null))[_0x3d76a7('0x22')](handleError(_0x4eb93c,null));},exports['destroy']=function(_0x27b08c,_0x2a348a){const _0x41e295=_0x1cb058;return db[_0x41e295('0x30')][_0x41e295('0xd')]({'where':{'id':_0x27b08c[_0x41e295('0x25')]['id']}})[_0x41e295('0xb')](handleEntityNotFound(_0x2a348a,null))['then'](removeEntity(_0x2a348a,null))['catch'](handleError(_0x2a348a,null));},exports[_0x1cb058('0x41')]=function(_0x3475a6,_0x16e0c5){const _0xdfb342=_0x1cb058;return db[_0xdfb342('0x30')][_0xdfb342('0xd')]({'where':{'id':_0x3475a6[_0xdfb342('0x25')]['id']}})[_0xdfb342('0xb')](handleEntityNotFound(_0x16e0c5,null))[_0xdfb342('0xb')](function(_0x23580f){const _0x408390=_0xdfb342;let _0x43c845={};const _0x5816c2={};return _0x5816c2['model']=_[_0x408390('0x13')](db[_0x408390('0x23')][_0x408390('0x28')]),_0x5816c2['query']=_[_0x408390('0x13')](_0x3475a6[_0x408390('0xf')]),_0x5816c2[_0x408390('0x3c')]=_[_0x408390('0xc')](_0x5816c2[_0x408390('0x8')],_0x5816c2[_0x408390('0xf')]),_0x43c845['attributes']=_[_0x408390('0xc')](_0x5816c2[_0x408390('0x8')],qs[_0x408390('0x7')](_0x3475a6[_0x408390('0xf')][_0x408390('0x7')])),_0x43c845[_0x408390('0x1d')]=_0x43c845[_0x408390('0x1d')][_0x408390('0x2e')]?_0x43c845[_0x408390('0x1d')]:_0x5816c2[_0x408390('0x8')],typeof _0x3475a6[_0x408390('0xf')][_0x408390('0x1a')]==='undefined'&&(_0x43c845[_0x408390('0x18')]=qs[_0x408390('0x18')](_0x3475a6[_0x408390('0xf')][_0x408390('0x18')]),_0x43c845[_0x408390('0x21')]=qs[_0x408390('0x21')](_0x3475a6['query']['offset'])),_0x43c845['order']=qs[_0x408390('0x9')](_0x3475a6[_0x408390('0xf')][_0x408390('0x9')]),_0x43c845[_0x408390('0xe')]=qs[_0x408390('0x3c')](_[_0x408390('0x3a')](_0x3475a6['query'],_0x5816c2['filters'])),_0x3475a6['query'][_0x408390('0x2d')]&&(_0x43c845['where']=_[_0x408390('0x12')](_0x43c845[_0x408390('0xe')],{[Op['or']]:_['map'](_0x43c845[_0x408390('0x1d')],function(_0x5343b4){const _0x5340fc=_0x408390,_0x562b0f={};return _0x562b0f[_0x5343b4]={[Op[_0x5340fc('0x10')]]:'%'+_0x3475a6['query']['filter']+'%'},_0x562b0f;})})),_0x43c845[_0x408390('0xe')]=_['merge'](_0x43c845[_0x408390('0xe')],{'mailboxuser':_0x23580f[_0x408390('0x20')]}),_0x43c845=_[_0x408390('0x12')]({},_0x43c845,_0x3475a6[_0x408390('0x2')]),db[_0x408390('0x23')][_0x408390('0x16')](_0x43c845)['then'](respondWithFilteredResult(_0x16e0c5,_0x43c845));})[_0xdfb342('0x22')](handleError(_0x16e0c5,null));}; \ No newline at end of file +const a734_0xe9a2=['mailbox','UserProfileSection','update','options','name','error','intersection','query','map','fields','offset','body','count','filter','nolimit','include','create','rawAttributes','key','type','VIRTUAL','findOne','Content-Range','includeAll','sendStatus','status','UserProfileResource','model','send','filters','merge','destroy','../../config/logger','VoiceMail','then','findAll','autoAssociation','Voicemails','params','order','json','stack','limit','api','../../mysqldb','sort','keys','catch','undefined','show','VoiceMailMessage','user','lodash','get','Unable\x20to\x20retrieve\x20the\x20current\x20user','end','like','attributes','where','fieldName','pick','length','set'];(function(_0x3f61dc,_0xe9a26d){const _0x11120c=function(_0x4ba325){while(--_0x4ba325){_0x3f61dc['push'](_0x3f61dc['shift']());}};_0x11120c(++_0xe9a26d);}(a734_0xe9a2,0x93));const a734_0x1112=function(_0x3f61dc,_0xe9a26d){_0x3f61dc=_0x3f61dc-0x0;let _0x11120c=a734_0xe9a2[_0x3f61dc];return _0x11120c;};const _0x1fc8ec=a734_0x1112;'use strict';const _=require(_0x1fc8ec('0x1f')),qs=require('../../components/parsers/qs'),logger=require(_0x1fc8ec('0xb'))(_0x1fc8ec('0x16')),db=require(_0x1fc8ec('0x17'))['db'],{Op}=require('sequelize');function respondWithResult(_0x4ba325,_0x459736){return _0x459736=_0x459736||0xc8,function(_0x215de6){const _0x428f98=a734_0x1112;if(_0x215de6)return _0x4ba325['status'](_0x459736)[_0x428f98('0x13')](_0x215de6);};}function respondWithFilteredResult(_0x99b26f,_0x990f0f){return function(_0x3bca87){const _0x3d2b7e=a734_0x1112;if(_0x3bca87){const _0x4208cd=_0x3bca87[_0x3d2b7e('0x36')],_0x403fae=_0x990f0f['offset'];let _0x1c8fe3=_0x990f0f[_0x3d2b7e('0x34')]+_0x990f0f[_0x3d2b7e('0x15')],_0x3d409c;return _0x1c8fe3>=_0x4208cd?(_0x1c8fe3=_0x4208cd,_0x3d409c=0xc8):_0x3d409c=0xce,_0x99b26f['status'](_0x3d409c),_0x99b26f[_0x3d2b7e('0x29')](_0x3d2b7e('0x1'),_0x403fae+'-'+_0x1c8fe3+'/'+_0x4208cd)[_0x3d2b7e('0x13')](_0x3bca87);}return null;};}function saveUpdates(_0x319e0b){return function(_0x2231f2){if(_0x2231f2)return _0x2231f2['update'](_0x319e0b)['then'](function(_0x3ffc5b){return _0x3ffc5b;});return null;};}function removeEntity(_0x45fa50){return function(_0xbe9f8f){const _0x394c35=a734_0x1112;if(_0xbe9f8f)return _0xbe9f8f[_0x394c35('0xa')]()['then'](function(){const _0x4d4a96=_0x394c35,_0x35fe75=_0xbe9f8f[_0x4d4a96('0x20')]({'plain':!![]}),_0x568d63=_0x4d4a96('0x10');return db['UserProfileResource'][_0x4d4a96('0xa')]({'where':{'type':_0x568d63,'resourceId':_0x35fe75['id']}})[_0x4d4a96('0xd')](function(){return _0xbe9f8f;});})['then'](function(){const _0x236a06=_0x394c35;_0x45fa50[_0x236a06('0x4')](0xcc)[_0x236a06('0x22')]();});};}function handleEntityNotFound(_0x144aa8){return function(_0x354cb1){const _0x8e4144=a734_0x1112;return!_0x354cb1&&_0x144aa8[_0x8e4144('0x3')](0x194),_0x354cb1;};}function handleError(_0x50c821,_0x1ce850){return _0x1ce850=_0x1ce850||0x1f4,function(_0x30c9b4){const _0x2d3c37=a734_0x1112;logger['error'](_0x30c9b4[_0x2d3c37('0x14')]),_0x30c9b4[_0x2d3c37('0x2e')]&&delete _0x30c9b4[_0x2d3c37('0x2e')],_0x50c821['status'](_0x1ce850)[_0x2d3c37('0x7')](_0x30c9b4);};}exports['index']=function(_0x35e438,_0x1eaa41){const _0x206b6a=_0x1fc8ec;let _0x5e0c71={};const _0x517ef3={},_0x195f42={'count':0x0,'rows':[]},_0x209b5e=_[_0x206b6a('0x32')](db[_0x206b6a('0xc')][_0x206b6a('0x3b')],function(_0x31d20b){const _0x91674b=_0x206b6a;return{'name':_0x31d20b[_0x91674b('0x26')],'type':_0x31d20b[_0x91674b('0x3d')][_0x91674b('0x3c')]};});_0x517ef3['model']=_[_0x206b6a('0x32')](_0x209b5e,'name'),_0x517ef3[_0x206b6a('0x31')]=_[_0x206b6a('0x19')](_0x35e438['query']),_0x517ef3[_0x206b6a('0x8')]=_[_0x206b6a('0x30')](_0x517ef3[_0x206b6a('0x6')],_0x517ef3['query']),_0x5e0c71['attributes']=_[_0x206b6a('0x30')](_0x517ef3[_0x206b6a('0x6')],qs['fields'](_0x35e438['query'][_0x206b6a('0x33')])),_0x5e0c71['attributes']=_0x5e0c71[_0x206b6a('0x24')][_0x206b6a('0x28')]?_0x5e0c71['attributes']:_0x517ef3[_0x206b6a('0x6')];typeof _0x35e438[_0x206b6a('0x31')][_0x206b6a('0x38')]===_0x206b6a('0x1b')&&(_0x5e0c71['limit']=qs[_0x206b6a('0x15')](_0x35e438['query'][_0x206b6a('0x15')]),_0x5e0c71[_0x206b6a('0x34')]=qs[_0x206b6a('0x34')](_0x35e438['query'][_0x206b6a('0x34')]));_0x5e0c71[_0x206b6a('0x12')]=qs[_0x206b6a('0x18')](_0x35e438[_0x206b6a('0x31')][_0x206b6a('0x18')]),_0x5e0c71[_0x206b6a('0x25')]=qs[_0x206b6a('0x8')](_[_0x206b6a('0x27')](_0x35e438[_0x206b6a('0x31')],_0x517ef3['filters']),_0x209b5e);_0x35e438[_0x206b6a('0x31')][_0x206b6a('0x37')]&&(_0x5e0c71[_0x206b6a('0x25')]=_[_0x206b6a('0x9')](_0x5e0c71['where'],{[Op['or']]:_[_0x206b6a('0x32')](_0x209b5e,function(_0xc9fa08){const _0x2b89a0=_0x206b6a;if(_0xc9fa08[_0x2b89a0('0x3d')]!==_0x2b89a0('0x3e')){const _0x2bc9db={};return _0x2bc9db[_0xc9fa08[_0x2b89a0('0x2e')]]={[Op[_0x2b89a0('0x23')]]:'%'+_0x35e438[_0x2b89a0('0x31')][_0x2b89a0('0x37')]+'%'},_0x2bc9db;}})}));_0x5e0c71=_['merge']({},_0x5e0c71,_0x35e438['options']);const _0x44740c={'where':_0x5e0c71[_0x206b6a('0x25')]};return db[_0x206b6a('0xc')]['count'](_0x44740c)['then'](function(_0x6f764c){const _0x5994f=_0x206b6a;return _0x195f42[_0x5994f('0x36')]=_0x6f764c,_0x35e438[_0x5994f('0x31')]['includeAll']&&(_0x5e0c71[_0x5994f('0x39')]=[{'all':!![]}]),db[_0x5994f('0xc')][_0x5994f('0xe')](_0x5e0c71);})[_0x206b6a('0xd')](function(_0xbb1202){return _0x195f42['rows']=_0xbb1202,_0x195f42;})[_0x206b6a('0xd')](respondWithFilteredResult(_0x1eaa41,_0x5e0c71))[_0x206b6a('0x1a')](handleError(_0x1eaa41,null));},exports[_0x1fc8ec('0x1c')]=function(_0x80cb,_0x3c7cef){const _0x18732c=_0x1fc8ec;let _0xa7915b={'raw':!![],'where':{'id':_0x80cb[_0x18732c('0x11')]['id']}};const _0x27b406={};return _0x27b406[_0x18732c('0x6')]=_[_0x18732c('0x19')](db[_0x18732c('0xc')][_0x18732c('0x3b')]),_0x27b406['query']=_[_0x18732c('0x19')](_0x80cb[_0x18732c('0x31')]),_0x27b406[_0x18732c('0x8')]=_[_0x18732c('0x30')](_0x27b406['model'],_0x27b406[_0x18732c('0x31')]),_0xa7915b['attributes']=_[_0x18732c('0x30')](_0x27b406[_0x18732c('0x6')],qs[_0x18732c('0x33')](_0x80cb[_0x18732c('0x31')][_0x18732c('0x33')])),_0xa7915b[_0x18732c('0x24')]=_0xa7915b['attributes'][_0x18732c('0x28')]?_0xa7915b[_0x18732c('0x24')]:_0x27b406['model'],_0x80cb[_0x18732c('0x31')][_0x18732c('0x2')]&&(_0xa7915b[_0x18732c('0x39')]=[{'all':!![]}]),_0xa7915b=_[_0x18732c('0x9')]({},_0xa7915b,_0x80cb[_0x18732c('0x2d')]),db[_0x18732c('0xc')][_0x18732c('0x0')](_0xa7915b)[_0x18732c('0xd')](handleEntityNotFound(_0x3c7cef,null))['then'](respondWithResult(_0x3c7cef,null))[_0x18732c('0x1a')](handleError(_0x3c7cef,null));},exports[_0x1fc8ec('0x3a')]=function(_0x59ad2d,_0x3be2da){const _0x5f0682=_0x1fc8ec;return db[_0x5f0682('0xc')][_0x5f0682('0x3a')](_0x59ad2d[_0x5f0682('0x35')],{})[_0x5f0682('0xd')](function(_0x495763){const _0x46a351=_0x5f0682,_0x1f1b84=_0x59ad2d[_0x46a351('0x1e')][_0x46a351('0x20')]({'plain':!![]});if(!_0x1f1b84)throw new Error(_0x46a351('0x21'));if(_0x1f1b84['role']===_0x46a351('0x1e')){const _0x1474cb=_0x495763[_0x46a351('0x20')]({'plain':!![]}),_0x44c750=_0x46a351('0x10');return db[_0x46a351('0x2b')][_0x46a351('0x0')]({'where':{'name':_0x44c750,'userProfileId':_0x1f1b84['userProfileId']},'raw':!![]})[_0x46a351('0xd')](function(_0xe033c9){const _0x5b156f=_0x46a351;return _0xe033c9&&_0xe033c9[_0x5b156f('0xf')]===0x0?db[_0x5b156f('0x5')][_0x5b156f('0x3a')]({'name':_0x1474cb[_0x5b156f('0x2e')],'resourceId':_0x1474cb['id'],'type':_0xe033c9['name'],'sectionId':_0xe033c9['id']},{})[_0x5b156f('0xd')](function(){return _0x495763;}):_0x495763;})[_0x46a351('0x1a')](function(_0x2fa9a2){const _0x9f8778=_0x46a351;logger[_0x9f8778('0x2f')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x2fa9a2);throw _0x2fa9a2;});}return _0x495763;})[_0x5f0682('0xd')](respondWithResult(_0x3be2da,0xc9))[_0x5f0682('0x1a')](handleError(_0x3be2da,null));},exports[_0x1fc8ec('0x2c')]=function(_0x3f82fe,_0x14c543){const _0x3a7456=_0x1fc8ec;return _0x3f82fe[_0x3a7456('0x35')]['id']&&delete _0x3f82fe[_0x3a7456('0x35')]['id'],db[_0x3a7456('0xc')][_0x3a7456('0x0')]({'where':{'id':_0x3f82fe['params']['id']}})[_0x3a7456('0xd')](handleEntityNotFound(_0x14c543,null))[_0x3a7456('0xd')](saveUpdates(_0x3f82fe[_0x3a7456('0x35')],null))[_0x3a7456('0xd')](respondWithResult(_0x14c543,null))[_0x3a7456('0x1a')](handleError(_0x14c543,null));},exports['destroy']=function(_0x5202cd,_0xbce768){const _0x52d1a7=_0x1fc8ec;return db['VoiceMail'][_0x52d1a7('0x0')]({'where':{'id':_0x5202cd[_0x52d1a7('0x11')]['id']}})[_0x52d1a7('0xd')](handleEntityNotFound(_0xbce768,null))[_0x52d1a7('0xd')](removeEntity(_0xbce768,null))[_0x52d1a7('0x1a')](handleError(_0xbce768,null));},exports['getMessages']=function(_0x1386f6,_0x25822f){const _0x5353ee=_0x1fc8ec;return db[_0x5353ee('0xc')]['findOne']({'where':{'id':_0x1386f6[_0x5353ee('0x11')]['id']}})[_0x5353ee('0xd')](handleEntityNotFound(_0x25822f,null))['then'](function(_0x22c1c4){const _0x587212=_0x5353ee;let _0x17b7c5={};const _0x332289={};return _0x332289[_0x587212('0x6')]=_[_0x587212('0x19')](db[_0x587212('0x1d')][_0x587212('0x3b')]),_0x332289[_0x587212('0x31')]=_[_0x587212('0x19')](_0x1386f6[_0x587212('0x31')]),_0x332289['filters']=_[_0x587212('0x30')](_0x332289[_0x587212('0x6')],_0x332289['query']),_0x17b7c5[_0x587212('0x24')]=_[_0x587212('0x30')](_0x332289[_0x587212('0x6')],qs['fields'](_0x1386f6['query'][_0x587212('0x33')])),_0x17b7c5[_0x587212('0x24')]=_0x17b7c5[_0x587212('0x24')]['length']?_0x17b7c5['attributes']:_0x332289[_0x587212('0x6')],typeof _0x1386f6[_0x587212('0x31')][_0x587212('0x38')]===_0x587212('0x1b')&&(_0x17b7c5[_0x587212('0x15')]=qs[_0x587212('0x15')](_0x1386f6['query']['limit']),_0x17b7c5['offset']=qs[_0x587212('0x34')](_0x1386f6['query'][_0x587212('0x34')])),_0x17b7c5[_0x587212('0x12')]=qs[_0x587212('0x18')](_0x1386f6[_0x587212('0x31')]['sort']),_0x17b7c5[_0x587212('0x25')]=qs[_0x587212('0x8')](_[_0x587212('0x27')](_0x1386f6['query'],_0x332289['filters'])),_0x1386f6[_0x587212('0x31')][_0x587212('0x37')]&&(_0x17b7c5['where']=_['merge'](_0x17b7c5['where'],{[Op['or']]:_[_0x587212('0x32')](_0x17b7c5[_0x587212('0x24')],function(_0x25c10a){const _0x598083=_0x587212,_0x3d1840={};return _0x3d1840[_0x25c10a]={[Op[_0x598083('0x23')]]:'%'+_0x1386f6[_0x598083('0x31')][_0x598083('0x37')]+'%'},_0x3d1840;})})),_0x17b7c5['where']=_['merge'](_0x17b7c5[_0x587212('0x25')],{'mailboxuser':_0x22c1c4[_0x587212('0x2a')]}),_0x17b7c5=_[_0x587212('0x9')]({},_0x17b7c5,_0x1386f6[_0x587212('0x2d')]),db['VoiceMailMessage']['findAndCountAll'](_0x17b7c5)[_0x587212('0xd')](respondWithFilteredResult(_0x25822f,_0x17b7c5));})[_0x5353ee('0x1a')](handleError(_0x25822f,null));}; \ No newline at end of file diff --git a/server/api/voiceMail/voiceMail.model.js b/server/api/voiceMail/voiceMail.model.js index c16ca74..fa096d9 100644 --- a/server/api/voiceMail/voiceMail.model.js +++ b/server/api/voiceMail/voiceMail.model.js @@ -1 +1 @@ -const a735_0x478d=['define','mailbox_context','mailbox','voice_voicemail','VoiceMail','context'];(function(_0x536e82,_0x478df0){const _0x5b8152=function(_0x5545a9){while(--_0x5545a9){_0x536e82['push'](_0x536e82['shift']());}};_0x5b8152(++_0x478df0);}(a735_0x478d,0x1db));const a735_0x5b81=function(_0x536e82,_0x478df0){_0x536e82=_0x536e82-0x0;let _0x5b8152=a735_0x478d[_0x536e82];return _0x5b8152;};'use strict';const attributes=require('./voiceMail.attributes');module['exports']=function(_0x5545a9){const _0x391443=a735_0x5b81,_0x4d3685=_0x5545a9[_0x391443('0x5')](_0x391443('0x3'),attributes,{'tableName':_0x391443('0x2'),'paranoid':![],'indexes':[{'name':_0x391443('0x0'),'fields':[_0x391443('0x1'),_0x391443('0x4')]}],'timestamps':!![]});return _0x4d3685;}; \ No newline at end of file +const a735_0x4f46=['exports','context','voice_voicemail','./voiceMail.attributes','mailbox_context','define','VoiceMail'];(function(_0x9c8092,_0x4f4681){const _0x2704c9=function(_0x548a1d){while(--_0x548a1d){_0x9c8092['push'](_0x9c8092['shift']());}};_0x2704c9(++_0x4f4681);}(a735_0x4f46,0x6e));const a735_0x2704=function(_0x9c8092,_0x4f4681){_0x9c8092=_0x9c8092-0x0;let _0x2704c9=a735_0x4f46[_0x9c8092];return _0x2704c9;};const _0x137310=a735_0x2704;'use strict';const attributes=require(_0x137310('0x5'));module[_0x137310('0x2')]=function(_0x548a1d){const _0x4a924d=_0x137310,_0xfefc81=_0x548a1d[_0x4a924d('0x0')](_0x4a924d('0x1'),attributes,{'tableName':_0x4a924d('0x4'),'paranoid':![],'indexes':[{'name':_0x4a924d('0x6'),'fields':['mailbox',_0x4a924d('0x3')]}],'timestamps':!![]});return _0xfefc81;}; \ No newline at end of file diff --git a/server/api/voiceMailMessage/index.js b/server/api/voiceMailMessage/index.js index 69359ce..1812a90 100644 --- a/server/api/voiceMailMessage/index.js +++ b/server/api/voiceMailMessage/index.js @@ -1 +1 @@ -const a736_0x12b1=['express','post','create','index','/:id','show','exports','./voiceMailMessage.controller','Router','isAuthenticated','delete','get','../../components/auth/service','download','put'];(function(_0x471bad,_0x12b1b8){const _0x4148b0=function(_0x13324e){while(--_0x13324e){_0x471bad['push'](_0x471bad['shift']());}};_0x4148b0(++_0x12b1b8);}(a736_0x12b1,0x87));const a736_0x4148=function(_0x471bad,_0x12b1b8){_0x471bad=_0x471bad-0x0;let _0x4148b0=a736_0x12b1[_0x471bad];return _0x4148b0;};const _0x7dde30=a736_0x4148;'use strict';const express=require(_0x7dde30('0x0')),router=express[_0x7dde30('0x8')](),auth=require(_0x7dde30('0xc')),controller=require(_0x7dde30('0x7'));router[_0x7dde30('0xb')]('/',auth[_0x7dde30('0x9')](),controller[_0x7dde30('0x3')]),router['get']('/:id',auth[_0x7dde30('0x9')](),controller[_0x7dde30('0x5')]),router['get']('/:id/download',auth[_0x7dde30('0x9')](),controller[_0x7dde30('0xd')]),router[_0x7dde30('0x1')]('/',auth[_0x7dde30('0x9')](),controller[_0x7dde30('0x2')]),router[_0x7dde30('0xe')](_0x7dde30('0x4'),auth[_0x7dde30('0x9')](),controller['update']),router[_0x7dde30('0xa')](_0x7dde30('0x4'),auth[_0x7dde30('0x9')](),controller['destroy']),module[_0x7dde30('0x6')]=router; \ No newline at end of file +const a736_0x9994=['destroy','download','isAuthenticated','delete','index','Router','create','get','exports','/:id/download','./voiceMailMessage.controller','/:id','../../components/auth/service','update'];(function(_0x647cba,_0x999484){const _0x4b32b7=function(_0x49878d){while(--_0x49878d){_0x647cba['push'](_0x647cba['shift']());}};_0x4b32b7(++_0x999484);}(a736_0x9994,0x1b5));const a736_0x4b32=function(_0x647cba,_0x999484){_0x647cba=_0x647cba-0x0;let _0x4b32b7=a736_0x9994[_0x647cba];return _0x4b32b7;};const _0x1cf868=a736_0x4b32;'use strict';const express=require('express'),router=express[_0x1cf868('0x2')](),auth=require(_0x1cf868('0x9')),controller=require(_0x1cf868('0x7'));router[_0x1cf868('0x4')]('/',auth[_0x1cf868('0xd')](),controller[_0x1cf868('0x1')]),router[_0x1cf868('0x4')](_0x1cf868('0x8'),auth[_0x1cf868('0xd')](),controller['show']),router[_0x1cf868('0x4')](_0x1cf868('0x6'),auth[_0x1cf868('0xd')](),controller[_0x1cf868('0xc')]),router['post']('/',auth[_0x1cf868('0xd')](),controller[_0x1cf868('0x3')]),router['put'](_0x1cf868('0x8'),auth[_0x1cf868('0xd')](),controller[_0x1cf868('0xa')]),router[_0x1cf868('0x0')](_0x1cf868('0x8'),auth[_0x1cf868('0xd')](),controller[_0x1cf868('0xb')]),module[_0x1cf868('0x5')]=router; \ No newline at end of file diff --git a/server/api/voiceMailMessage/voiceMailMessage.attributes.js b/server/api/voiceMailMessage/voiceMailMessage.attributes.js index f27f136..86c3102 100644 --- a/server/api/voiceMailMessage/voiceMailMessage.attributes.js +++ b/server/api/voiceMailMessage/voiceMailMessage.attributes.js @@ -1 +1 @@ -const a737_0x2512=['long','exports','INTEGER','sequelize','VIRTUAL','getDataValue','BLOB','STRING'];(function(_0x40f537,_0x2512fd){const _0x49f56e=function(_0x43e9db){while(--_0x43e9db){_0x40f537['push'](_0x40f537['shift']());}};_0x49f56e(++_0x2512fd);}(a737_0x2512,0x1ae));const a737_0x49f5=function(_0x40f537,_0x2512fd){_0x40f537=_0x40f537-0x0;let _0x49f56e=a737_0x2512[_0x40f537];return _0x49f56e;};const _0x570746=a737_0x49f5;'use strict';const Sequelize=require(_0x570746('0x5'));module[_0x570746('0x3')]={'name':{'type':Sequelize[_0x570746('0x6')],'get':function(){const _0x2f19ad=_0x570746;return this[_0x2f19ad('0x7')]('id');}},'msgnum':{'type':Sequelize[_0x570746('0x4')](0xb),'defaultValue':0x0,'allowNull':![]},'dir':{'type':Sequelize['STRING'],'defaultValue':''},'context':{'type':Sequelize[_0x570746('0x1')],'defaultValue':''},'macrocontext':{'type':Sequelize[_0x570746('0x1')],'defaultValue':''},'callerid':{'type':Sequelize[_0x570746('0x1')],'defaultValue':''},'origtime':{'type':Sequelize[_0x570746('0x1')],'defaultValue':''},'duration':{'type':Sequelize['STRING'],'defaultValue':''},'mailboxuser':{'type':Sequelize[_0x570746('0x1')],'defaultValue':''},'mailboxcontext':{'type':Sequelize[_0x570746('0x1')],'defaultValue':''},'recording':{'type':Sequelize[_0x570746('0x0')](_0x570746('0x2')),'defaultValue':null},'flag':{'type':Sequelize['STRING'],'defaultValue':''},'msg_id':{'type':Sequelize['STRING'],'defaultValue':''},'stamp':{'type':'TIMESTAMP','allowNull':![]}}; \ No newline at end of file +const a737_0x5bd3=['INTEGER','STRING','exports','sequelize','VIRTUAL','getDataValue','long'];(function(_0x2a5a72,_0x5bd367){const _0x222dd7=function(_0x39526b){while(--_0x39526b){_0x2a5a72['push'](_0x2a5a72['shift']());}};_0x222dd7(++_0x5bd367);}(a737_0x5bd3,0x1e9));const a737_0x222d=function(_0x2a5a72,_0x5bd367){_0x2a5a72=_0x2a5a72-0x0;let _0x222dd7=a737_0x5bd3[_0x2a5a72];return _0x222dd7;};const _0x47e1db=a737_0x222d;'use strict';const Sequelize=require(_0x47e1db('0x4'));module[_0x47e1db('0x3')]={'name':{'type':Sequelize[_0x47e1db('0x5')],'get':function(){const _0x13a165=_0x47e1db;return this[_0x13a165('0x6')]('id');}},'msgnum':{'type':Sequelize[_0x47e1db('0x1')](0xb),'defaultValue':0x0,'allowNull':![]},'dir':{'type':Sequelize[_0x47e1db('0x2')],'defaultValue':''},'context':{'type':Sequelize['STRING'],'defaultValue':''},'macrocontext':{'type':Sequelize[_0x47e1db('0x2')],'defaultValue':''},'callerid':{'type':Sequelize['STRING'],'defaultValue':''},'origtime':{'type':Sequelize[_0x47e1db('0x2')],'defaultValue':''},'duration':{'type':Sequelize[_0x47e1db('0x2')],'defaultValue':''},'mailboxuser':{'type':Sequelize[_0x47e1db('0x2')],'defaultValue':''},'mailboxcontext':{'type':Sequelize[_0x47e1db('0x2')],'defaultValue':''},'recording':{'type':Sequelize['BLOB'](_0x47e1db('0x0')),'defaultValue':null},'flag':{'type':Sequelize[_0x47e1db('0x2')],'defaultValue':''},'msg_id':{'type':Sequelize[_0x47e1db('0x2')],'defaultValue':''},'stamp':{'type':'TIMESTAMP','allowNull':![]}}; \ No newline at end of file diff --git a/server/api/voiceMailMessage/voiceMailMessage.controller.js b/server/api/voiceMailMessage/voiceMailMessage.controller.js index 8bbff80..d38ab1b 100644 --- a/server/api/voiceMailMessage/voiceMailMessage.controller.js +++ b/server/api/voiceMailMessage/voiceMailMessage.controller.js @@ -1 +1 @@ -const a738_0x5f00=['differenceBy','attachment;\x20filename=\x22','findAll','download','error','model','catch','key','show','msg_id','end','destroy','like','sendStatus','includeAll','fields','set','json','query','keys','api','count','recording','name','VoiceMailMessage\x20not\x20found','../../components/parsers/qs','rawAttributes','order','rows','merge','update','then','sequelize','stack','map','params','create','sort','body','filter','length','where','VoiceMailMessage','filters','status','Content-Range','offset','include','send','attributes','intersection','findOne','../../config/logger','attachment','type','Content-Disposition','limit'];(function(_0x31a47c,_0x5f008a){const _0x1b4d5a=function(_0x2afdbf){while(--_0x2afdbf){_0x31a47c['push'](_0x31a47c['shift']());}};_0x1b4d5a(++_0x5f008a);}(a738_0x5f00,0xc7));const a738_0x1b4d=function(_0x31a47c,_0x5f008a){_0x31a47c=_0x31a47c-0x0;let _0x1b4d5a=a738_0x5f00[_0x31a47c];return _0x1b4d5a;};const _0x5aa864=a738_0x1b4d;'use strict';const _=require('lodash'),qs=require(_0x5aa864('0x36')),logger=require(_0x5aa864('0x18'))(_0x5aa864('0x31')),db=require('../../mysqldb')['db'],{Op,ValidationError}=require(_0x5aa864('0x4'));function respondWithResult(_0x2afdbf,_0x27ec81){return _0x27ec81=_0x27ec81||0xc8,function(_0x50b75e){const _0x418d79=a738_0x1b4d;if(_0x50b75e)return _0x2afdbf[_0x418d79('0x10')](_0x27ec81)[_0x418d79('0x2e')](_0x50b75e);};}function respondWithFilteredResult(_0x4648f7,_0x3adbfc){return function(_0x4e793d){const _0x163474=a738_0x1b4d;if(_0x4e793d){const _0x440226=_0x4e793d[_0x163474('0x32')],_0x5431e7=_0x3adbfc[_0x163474('0x12')];let _0x11ecd9=_0x3adbfc[_0x163474('0x12')]+_0x3adbfc[_0x163474('0x1c')],_0x11097a;return _0x11ecd9>=_0x440226?(_0x11ecd9=_0x440226,_0x11097a=0xc8):_0x11097a=0xce,_0x4648f7[_0x163474('0x10')](_0x11097a),_0x4648f7[_0x163474('0x2d')](_0x163474('0x11'),_0x5431e7+'-'+_0x11ecd9+'/'+_0x440226)['json'](_0x4e793d);}return null;};}function saveUpdates(_0x416855){return function(_0x4fcb52){const _0x20dd3b=a738_0x1b4d;if(_0x4fcb52)return _0x4fcb52[_0x20dd3b('0x2')](_0x416855)[_0x20dd3b('0x3')](function(_0x25a996){return _0x25a996;});return null;};}function removeEntity(_0x3a1781){return function(_0x3cb8a7){if(_0x3cb8a7)return _0x3cb8a7['destroy']()['then'](function(){const _0x37ed35=a738_0x1b4d;_0x3a1781['status'](0xcc)[_0x37ed35('0x27')]();});};}function handleEntityNotFound(_0x54b9c0){return function(_0x335222){const _0xa20bae=a738_0x1b4d;return!_0x335222&&_0x54b9c0[_0xa20bae('0x2a')](0x194),_0x335222;};}function handleError(_0x1e7698,_0x34f36a){return _0x34f36a=_0x34f36a||0x1f4,function(_0x48d179){const _0x505077=a738_0x1b4d;logger[_0x505077('0x21')](_0x48d179[_0x505077('0x5')]),_0x48d179['name']&&delete _0x48d179[_0x505077('0x34')],_0x1e7698['status'](_0x34f36a)[_0x505077('0x14')](_0x48d179);};}exports['index']=function(_0xc2c3eb,_0x36236a){const _0x53ca5b=_0x5aa864;let _0x8d5321={};const _0x24f996={},_0x3a18ea={'count':0x0,'rows':[]},_0x7c322c=_[_0x53ca5b('0x6')](db[_0x53ca5b('0xe')][_0x53ca5b('0x37')],function(_0x5774a2){const _0x2c893d=_0x53ca5b;return{'name':_0x5774a2['fieldName'],'type':_0x5774a2[_0x2c893d('0x1a')][_0x2c893d('0x24')]};});_0x24f996[_0x53ca5b('0x22')]=_[_0x53ca5b('0x1d')](_[_0x53ca5b('0x6')](_0x7c322c,_0x53ca5b('0x34')),[_0x53ca5b('0x34')]),_0x24f996[_0x53ca5b('0x2f')]=_[_0x53ca5b('0x30')](_0xc2c3eb[_0x53ca5b('0x2f')]),_0x24f996[_0x53ca5b('0xf')]=_[_0x53ca5b('0x16')](_0x24f996['model'],_0x24f996[_0x53ca5b('0x2f')]),_0x8d5321[_0x53ca5b('0x15')]=_[_0x53ca5b('0x16')](_0x24f996['model'],qs[_0x53ca5b('0x2c')](_0xc2c3eb[_0x53ca5b('0x2f')][_0x53ca5b('0x2c')])),_0x8d5321[_0x53ca5b('0x15')]=_0x8d5321[_0x53ca5b('0x15')][_0x53ca5b('0xc')]?_0x8d5321[_0x53ca5b('0x15')]:_0x24f996[_0x53ca5b('0x22')];typeof _0xc2c3eb[_0x53ca5b('0x2f')]['nolimit']==='undefined'&&(_0x8d5321[_0x53ca5b('0x1c')]=qs[_0x53ca5b('0x1c')](_0xc2c3eb[_0x53ca5b('0x2f')]['limit']),_0x8d5321[_0x53ca5b('0x12')]=qs[_0x53ca5b('0x12')](_0xc2c3eb[_0x53ca5b('0x2f')]['offset']));_0x8d5321[_0x53ca5b('0x38')]=qs[_0x53ca5b('0x9')](_0xc2c3eb['query'][_0x53ca5b('0x9')]),_0x8d5321[_0x53ca5b('0xd')]=qs['filters'](_['pick'](_0xc2c3eb[_0x53ca5b('0x2f')],_0x24f996[_0x53ca5b('0xf')]),_0x7c322c);_0xc2c3eb['query'][_0x53ca5b('0xb')]&&(_0x8d5321['where']=_[_0x53ca5b('0x1')](_0x8d5321[_0x53ca5b('0xd')],{[Op['or']]:_['map'](_0x7c322c,function(_0x1197d2){const _0x384233=_0x53ca5b;if(_0x1197d2[_0x384233('0x1a')]!=='VIRTUAL'){const _0x4ea111={};return _0x4ea111[_0x1197d2[_0x384233('0x34')]]={[Op[_0x384233('0x29')]]:'%'+_0xc2c3eb['query'][_0x384233('0xb')]+'%'},_0x4ea111;}})}));_0x8d5321=_[_0x53ca5b('0x1')]({},_0x8d5321,_0xc2c3eb['options']);const _0x25a461={'where':_0x8d5321[_0x53ca5b('0xd')]};return db[_0x53ca5b('0xe')][_0x53ca5b('0x32')](_0x25a461)[_0x53ca5b('0x3')](function(_0x2e6f4b){const _0x20546d=_0x53ca5b;return _0x3a18ea['count']=_0x2e6f4b,_0xc2c3eb[_0x20546d('0x2f')][_0x20546d('0x2b')]&&(_0x8d5321[_0x20546d('0x13')]=[{'all':!![]}]),db[_0x20546d('0xe')][_0x20546d('0x1f')](_0x8d5321);})[_0x53ca5b('0x3')](function(_0x3b3926){const _0xbd6fa0=_0x53ca5b;return _0x3a18ea[_0xbd6fa0('0x0')]=_0x3b3926,_0x3a18ea;})['then'](respondWithFilteredResult(_0x36236a,_0x8d5321))[_0x53ca5b('0x23')](handleError(_0x36236a,null));},exports[_0x5aa864('0x25')]=function(_0x325dcb,_0x1f10fd){const _0x48025a=_0x5aa864;let _0x27e4cb={'raw':!![],'where':{'id':_0x325dcb['params']['id']}};const _0x43048c={};return _0x43048c[_0x48025a('0x22')]=_['keys'](db[_0x48025a('0xe')]['rawAttributes']),_0x43048c[_0x48025a('0x2f')]=_[_0x48025a('0x30')](_0x325dcb[_0x48025a('0x2f')]),_0x43048c['filters']=_[_0x48025a('0x16')](_0x43048c[_0x48025a('0x22')],_0x43048c[_0x48025a('0x2f')]),_0x27e4cb['attributes']=_[_0x48025a('0x16')](_0x43048c[_0x48025a('0x22')],qs['fields'](_0x325dcb['query'][_0x48025a('0x2c')])),_0x27e4cb[_0x48025a('0x15')]=_0x27e4cb[_0x48025a('0x15')][_0x48025a('0xc')]?_0x27e4cb[_0x48025a('0x15')]:_0x43048c[_0x48025a('0x22')],_0x325dcb[_0x48025a('0x2f')][_0x48025a('0x2b')]&&(_0x27e4cb[_0x48025a('0x13')]=[{'all':!![]}]),_0x27e4cb=_[_0x48025a('0x1')]({},_0x27e4cb,_0x325dcb['options']),db['VoiceMailMessage']['findOne'](_0x27e4cb)['then'](handleEntityNotFound(_0x1f10fd,null))[_0x48025a('0x3')](respondWithResult(_0x1f10fd,null))[_0x48025a('0x23')](handleError(_0x1f10fd,null));},exports['create']=function(_0x5c9fb7,_0xf91e9b){const _0x3c5d47=_0x5aa864;return db[_0x3c5d47('0xe')][_0x3c5d47('0x8')](_0x5c9fb7[_0x3c5d47('0xa')],{})['then'](respondWithResult(_0xf91e9b,0xc9))[_0x3c5d47('0x23')](handleError(_0xf91e9b,null));},exports[_0x5aa864('0x2')]=function(_0x427052,_0x259ae7){const _0x963716=_0x5aa864;return _0x427052[_0x963716('0xa')]['id']&&delete _0x427052[_0x963716('0xa')]['id'],db[_0x963716('0xe')][_0x963716('0x17')]({'where':{'id':_0x427052[_0x963716('0x7')]['id']}})[_0x963716('0x3')](handleEntityNotFound(_0x259ae7,null))[_0x963716('0x3')](saveUpdates(_0x427052[_0x963716('0xa')],null))[_0x963716('0x3')](respondWithResult(_0x259ae7,null))[_0x963716('0x23')](handleError(_0x259ae7,null));},exports[_0x5aa864('0x28')]=function(_0x26bd8a,_0x2e7715){const _0x5933d1=_0x5aa864;return db[_0x5933d1('0xe')][_0x5933d1('0x17')]({'where':{'id':_0x26bd8a[_0x5933d1('0x7')]['id']}})[_0x5933d1('0x3')](handleEntityNotFound(_0x2e7715,null))[_0x5933d1('0x3')](removeEntity(_0x2e7715,null))[_0x5933d1('0x23')](handleError(_0x2e7715,null));},exports[_0x5aa864('0x20')]=function(_0x48db7,_0x479e47){const _0x22a3bf=_0x5aa864;return db[_0x22a3bf('0xe')]['findOne']({'where':{'id':_0x48db7[_0x22a3bf('0x7')]['id']},'attributes':['id',_0x22a3bf('0x33'),'msg_id']})[_0x22a3bf('0x3')](handleEntityNotFound(_0x479e47,null))[_0x22a3bf('0x3')](function(_0x1f0d05){const _0x1815e2=_0x22a3bf;if(_0x1f0d05){if(!_0x1f0d05[_0x1815e2('0x33')])throw new ValidationError(_0x1815e2('0x35'));const _0x4be3d4={'Content-Type':'audio/wav','Content-Disposition':_0x1815e2('0x19')};return _0x1f0d05[_0x1815e2('0x26')]&&(_0x4be3d4[_0x1815e2('0x1b')]=_0x1815e2('0x1e')+_0x1f0d05[_0x1815e2('0x26')]+'.wav\x22'),_0x479e47[_0x1815e2('0x2d')](_0x4be3d4),_0x479e47[_0x1815e2('0x14')](Buffer['from'](_0x1f0d05[_0x1815e2('0x33')]));}})['catch'](handleError(_0x479e47,null));}; \ No newline at end of file +const a738_0x97df=['set','type','model','recording','includeAll','map','key','keys','index','attachment;\x20filename=\x22','VoiceMailMessage','undefined','fieldName','error','.wav\x22','rows','send','from','sequelize','json','../../config/logger','update','create','../../components/parsers/qs','status','VIRTUAL','query','like','offset','audio/wav','findOne','merge','sort','filters','msg_id','attachment','sendStatus','differenceBy','pick','intersection','attributes','count','include','rawAttributes','lodash','nolimit','filter','Content-Range','length','fields','stack','where','body','Content-Disposition','end','limit','order','params','options','destroy','then','name','catch','VoiceMailMessage\x20not\x20found','../../mysqldb'];(function(_0x228840,_0x97df8b){const _0x37c3ef=function(_0x1e334e){while(--_0x1e334e){_0x228840['push'](_0x228840['shift']());}};_0x37c3ef(++_0x97df8b);}(a738_0x97df,0x1b0));const a738_0x37c3=function(_0x228840,_0x97df8b){_0x228840=_0x228840-0x0;let _0x37c3ef=a738_0x97df[_0x228840];return _0x37c3ef;};const _0x27f201=a738_0x37c3;'use strict';const _=require(_0x27f201('0x2')),qs=require(_0x27f201('0x2e')),logger=require(_0x27f201('0x2b'))('api'),db=require(_0x27f201('0x16'))['db'],{Op,ValidationError}=require(_0x27f201('0x29'));function respondWithResult(_0x1e334e,_0x2930ec){return _0x2930ec=_0x2930ec||0xc8,function(_0x36270a){const _0x2ba40c=a738_0x37c3;if(_0x36270a)return _0x1e334e[_0x2ba40c('0x2f')](_0x2930ec)[_0x2ba40c('0x2a')](_0x36270a);};}function respondWithFilteredResult(_0x313d4c,_0x5b3ab1){return function(_0x36185e){const _0x5bbb82=a738_0x37c3;if(_0x36185e){const _0x19165d=_0x36185e['count'],_0x4051d3=_0x5b3ab1[_0x5bbb82('0x33')];let _0x226e30=_0x5b3ab1[_0x5bbb82('0x33')]+_0x5b3ab1['limit'],_0x46138d;return _0x226e30>=_0x19165d?(_0x226e30=_0x19165d,_0x46138d=0xc8):_0x46138d=0xce,_0x313d4c[_0x5bbb82('0x2f')](_0x46138d),_0x313d4c['set'](_0x5bbb82('0x5'),_0x4051d3+'-'+_0x226e30+'/'+_0x19165d)['json'](_0x36185e);}return null;};}function saveUpdates(_0x13979b){return function(_0xf4f137){const _0x3cf3ff=a738_0x37c3;if(_0xf4f137)return _0xf4f137[_0x3cf3ff('0x2c')](_0x13979b)[_0x3cf3ff('0x12')](function(_0x4aef93){return _0x4aef93;});return null;};}function removeEntity(_0x120608){return function(_0x573dd5){const _0x3b6b7d=a738_0x37c3;if(_0x573dd5)return _0x573dd5[_0x3b6b7d('0x11')]()[_0x3b6b7d('0x12')](function(){const _0x120957=_0x3b6b7d;_0x120608[_0x120957('0x2f')](0xcc)[_0x120957('0xc')]();});};}function handleEntityNotFound(_0x4c6a82){return function(_0x53b231){const _0x1e3c4e=a738_0x37c3;return!_0x53b231&&_0x4c6a82[_0x1e3c4e('0x3b')](0x194),_0x53b231;};}function handleError(_0x480baf,_0x5dfcb4){return _0x5dfcb4=_0x5dfcb4||0x1f4,function(_0x1cad81){const _0x45c11=a738_0x37c3;logger[_0x45c11('0x24')](_0x1cad81[_0x45c11('0x8')]),_0x1cad81[_0x45c11('0x13')]&&delete _0x1cad81[_0x45c11('0x13')],_0x480baf[_0x45c11('0x2f')](_0x5dfcb4)[_0x45c11('0x27')](_0x1cad81);};}exports[_0x27f201('0x1f')]=function(_0x575440,_0x1b5250){const _0x33a119=_0x27f201;let _0x4ea5a8={};const _0x3166c5={},_0x5032ef={'count':0x0,'rows':[]},_0x1eca77=_[_0x33a119('0x1c')](db[_0x33a119('0x21')][_0x33a119('0x1')],function(_0x19f650){const _0x4ceb4c=_0x33a119;return{'name':_0x19f650[_0x4ceb4c('0x23')],'type':_0x19f650[_0x4ceb4c('0x18')][_0x4ceb4c('0x1d')]};});_0x3166c5['model']=_[_0x33a119('0x3c')](_[_0x33a119('0x1c')](_0x1eca77,_0x33a119('0x13')),[_0x33a119('0x13')]),_0x3166c5[_0x33a119('0x31')]=_[_0x33a119('0x1e')](_0x575440['query']),_0x3166c5[_0x33a119('0x38')]=_['intersection'](_0x3166c5['model'],_0x3166c5[_0x33a119('0x31')]),_0x4ea5a8[_0x33a119('0x3f')]=_[_0x33a119('0x3e')](_0x3166c5[_0x33a119('0x19')],qs[_0x33a119('0x7')](_0x575440[_0x33a119('0x31')][_0x33a119('0x7')])),_0x4ea5a8[_0x33a119('0x3f')]=_0x4ea5a8[_0x33a119('0x3f')][_0x33a119('0x6')]?_0x4ea5a8[_0x33a119('0x3f')]:_0x3166c5[_0x33a119('0x19')];typeof _0x575440[_0x33a119('0x31')][_0x33a119('0x3')]===_0x33a119('0x22')&&(_0x4ea5a8[_0x33a119('0xd')]=qs['limit'](_0x575440['query'][_0x33a119('0xd')]),_0x4ea5a8[_0x33a119('0x33')]=qs[_0x33a119('0x33')](_0x575440[_0x33a119('0x31')][_0x33a119('0x33')]));_0x4ea5a8[_0x33a119('0xe')]=qs[_0x33a119('0x37')](_0x575440['query'][_0x33a119('0x37')]),_0x4ea5a8['where']=qs[_0x33a119('0x38')](_[_0x33a119('0x3d')](_0x575440[_0x33a119('0x31')],_0x3166c5['filters']),_0x1eca77);_0x575440[_0x33a119('0x31')][_0x33a119('0x4')]&&(_0x4ea5a8[_0x33a119('0x9')]=_[_0x33a119('0x36')](_0x4ea5a8[_0x33a119('0x9')],{[Op['or']]:_[_0x33a119('0x1c')](_0x1eca77,function(_0x3e47b0){const _0x341190=_0x33a119;if(_0x3e47b0[_0x341190('0x18')]!==_0x341190('0x30')){const _0xda8b11={};return _0xda8b11[_0x3e47b0[_0x341190('0x13')]]={[Op[_0x341190('0x32')]]:'%'+_0x575440[_0x341190('0x31')][_0x341190('0x4')]+'%'},_0xda8b11;}})}));_0x4ea5a8=_[_0x33a119('0x36')]({},_0x4ea5a8,_0x575440[_0x33a119('0x10')]);const _0x68bdba={'where':_0x4ea5a8['where']};return db[_0x33a119('0x21')][_0x33a119('0x40')](_0x68bdba)[_0x33a119('0x12')](function(_0x10d0ec){const _0x22992f=_0x33a119;return _0x5032ef[_0x22992f('0x40')]=_0x10d0ec,_0x575440[_0x22992f('0x31')][_0x22992f('0x1b')]&&(_0x4ea5a8[_0x22992f('0x0')]=[{'all':!![]}]),db[_0x22992f('0x21')]['findAll'](_0x4ea5a8);})['then'](function(_0x4599d1){const _0xe96d8c=_0x33a119;return _0x5032ef[_0xe96d8c('0x26')]=_0x4599d1,_0x5032ef;})[_0x33a119('0x12')](respondWithFilteredResult(_0x1b5250,_0x4ea5a8))[_0x33a119('0x14')](handleError(_0x1b5250,null));},exports['show']=function(_0x397157,_0x2fac97){const _0x1b0e7d=_0x27f201;let _0x2dff94={'raw':!![],'where':{'id':_0x397157[_0x1b0e7d('0xf')]['id']}};const _0x46a81e={};return _0x46a81e['model']=_[_0x1b0e7d('0x1e')](db[_0x1b0e7d('0x21')][_0x1b0e7d('0x1')]),_0x46a81e['query']=_[_0x1b0e7d('0x1e')](_0x397157['query']),_0x46a81e[_0x1b0e7d('0x38')]=_[_0x1b0e7d('0x3e')](_0x46a81e[_0x1b0e7d('0x19')],_0x46a81e[_0x1b0e7d('0x31')]),_0x2dff94[_0x1b0e7d('0x3f')]=_[_0x1b0e7d('0x3e')](_0x46a81e[_0x1b0e7d('0x19')],qs[_0x1b0e7d('0x7')](_0x397157[_0x1b0e7d('0x31')]['fields'])),_0x2dff94[_0x1b0e7d('0x3f')]=_0x2dff94[_0x1b0e7d('0x3f')][_0x1b0e7d('0x6')]?_0x2dff94[_0x1b0e7d('0x3f')]:_0x46a81e[_0x1b0e7d('0x19')],_0x397157[_0x1b0e7d('0x31')][_0x1b0e7d('0x1b')]&&(_0x2dff94[_0x1b0e7d('0x0')]=[{'all':!![]}]),_0x2dff94=_[_0x1b0e7d('0x36')]({},_0x2dff94,_0x397157[_0x1b0e7d('0x10')]),db[_0x1b0e7d('0x21')][_0x1b0e7d('0x35')](_0x2dff94)[_0x1b0e7d('0x12')](handleEntityNotFound(_0x2fac97,null))['then'](respondWithResult(_0x2fac97,null))[_0x1b0e7d('0x14')](handleError(_0x2fac97,null));},exports[_0x27f201('0x2d')]=function(_0x1658cc,_0x43d297){const _0x1e2c6f=_0x27f201;return db[_0x1e2c6f('0x21')][_0x1e2c6f('0x2d')](_0x1658cc['body'],{})[_0x1e2c6f('0x12')](respondWithResult(_0x43d297,0xc9))[_0x1e2c6f('0x14')](handleError(_0x43d297,null));},exports['update']=function(_0x48527f,_0x50b4e6){const _0x3f0e0f=_0x27f201;return _0x48527f['body']['id']&&delete _0x48527f[_0x3f0e0f('0xa')]['id'],db[_0x3f0e0f('0x21')]['findOne']({'where':{'id':_0x48527f[_0x3f0e0f('0xf')]['id']}})[_0x3f0e0f('0x12')](handleEntityNotFound(_0x50b4e6,null))['then'](saveUpdates(_0x48527f[_0x3f0e0f('0xa')],null))[_0x3f0e0f('0x12')](respondWithResult(_0x50b4e6,null))[_0x3f0e0f('0x14')](handleError(_0x50b4e6,null));},exports['destroy']=function(_0x23f236,_0xe4ebf7){const _0x1329dc=_0x27f201;return db[_0x1329dc('0x21')][_0x1329dc('0x35')]({'where':{'id':_0x23f236[_0x1329dc('0xf')]['id']}})['then'](handleEntityNotFound(_0xe4ebf7,null))[_0x1329dc('0x12')](removeEntity(_0xe4ebf7,null))[_0x1329dc('0x14')](handleError(_0xe4ebf7,null));},exports['download']=function(_0x48ac1b,_0x5ceaf4){const _0x1d783f=_0x27f201;return db['VoiceMailMessage'][_0x1d783f('0x35')]({'where':{'id':_0x48ac1b['params']['id']},'attributes':['id',_0x1d783f('0x1a'),_0x1d783f('0x39')]})['then'](handleEntityNotFound(_0x5ceaf4,null))['then'](function(_0x10a6a7){const _0x12e9b5=_0x1d783f;if(_0x10a6a7){if(!_0x10a6a7['recording'])throw new ValidationError(_0x12e9b5('0x15'));const _0x270239={'Content-Type':_0x12e9b5('0x34'),'Content-Disposition':_0x12e9b5('0x3a')};return _0x10a6a7['msg_id']&&(_0x270239[_0x12e9b5('0xb')]=_0x12e9b5('0x20')+_0x10a6a7[_0x12e9b5('0x39')]+_0x12e9b5('0x25')),_0x5ceaf4[_0x12e9b5('0x17')](_0x270239),_0x5ceaf4[_0x12e9b5('0x27')](Buffer[_0x12e9b5('0x28')](_0x10a6a7['recording']));}})[_0x1d783f('0x14')](handleError(_0x5ceaf4,null));}; \ No newline at end of file diff --git a/server/api/voiceMailMessage/voiceMailMessage.model.js b/server/api/voiceMailMessage/voiceMailMessage.model.js index 59dc5af..98d0284 100644 --- a/server/api/voiceMailMessage/voiceMailMessage.model.js +++ b/server/api/voiceMailMessage/voiceMailMessage.model.js @@ -1 +1 @@ -const a739_0x538b=['define','voice_voicemail_messages','dir','VoiceMailMessage'];(function(_0x3efae7,_0x538b1a){const _0x1fc843=function(_0xda956a){while(--_0xda956a){_0x3efae7['push'](_0x3efae7['shift']());}};_0x1fc843(++_0x538b1a);}(a739_0x538b,0x1cc));const a739_0x1fc8=function(_0x3efae7,_0x538b1a){_0x3efae7=_0x3efae7-0x0;let _0x1fc843=a739_0x538b[_0x3efae7];return _0x1fc843;};'use strict';const attributes=require('./voiceMailMessage.attributes');module['exports']=function(_0xda956a){const _0x16328f=a739_0x1fc8,_0x67a855=_0xda956a[_0x16328f('0x0')](_0x16328f('0x3'),attributes,{'tableName':_0x16328f('0x1'),'paranoid':![],'indexes':[{'name':_0x16328f('0x2'),'fields':[_0x16328f('0x2')]}],'timestamps':![]});return _0x67a855;}; \ No newline at end of file +const a739_0x7fae=['define','./voiceMailMessage.attributes','exports','voice_voicemail_messages'];(function(_0x587cad,_0x7fae43){const _0x58518c=function(_0x3fb88f){while(--_0x3fb88f){_0x587cad['push'](_0x587cad['shift']());}};_0x58518c(++_0x7fae43);}(a739_0x7fae,0xc6));const a739_0x5851=function(_0x587cad,_0x7fae43){_0x587cad=_0x587cad-0x0;let _0x58518c=a739_0x7fae[_0x587cad];return _0x58518c;};const _0x11e3be=a739_0x5851;'use strict';const attributes=require(_0x11e3be('0x3'));module[_0x11e3be('0x0')]=function(_0x3fb88f){const _0x4b956d=_0x11e3be,_0x447625=_0x3fb88f[_0x4b956d('0x2')]('VoiceMailMessage',attributes,{'tableName':_0x4b956d('0x1'),'paranoid':![],'indexes':[{'name':'dir','fields':['dir']}],'timestamps':![]});return _0x447625;}; \ No newline at end of file diff --git a/server/api/voiceMusicOnHold/index.js b/server/api/voiceMusicOnHold/index.js index cda5cb1..67f67c4 100644 --- a/server/api/voiceMusicOnHold/index.js +++ b/server/api/voiceMusicOnHold/index.js @@ -1 +1 @@ -const a740_0x2136=['post','/:id','./voiceMusicOnHold.controller','../../components/auth/service','/:id/sounds','isAuthenticated','index','destroy','delete','get','put','Router','/:id/sounds/:id2','removeSound','express','show'];(function(_0x5ee550,_0x213668){const _0x21f055=function(_0x1572f1){while(--_0x1572f1){_0x5ee550['push'](_0x5ee550['shift']());}};_0x21f055(++_0x213668);}(a740_0x2136,0xa8));const a740_0x21f0=function(_0x5ee550,_0x213668){_0x5ee550=_0x5ee550-0x0;let _0x21f055=a740_0x2136[_0x5ee550];return _0x21f055;};const _0x5ed22b=a740_0x21f0;'use strict';const express=require(_0x5ed22b('0x6')),router=express[_0x5ed22b('0x3')](),auth=require(_0x5ed22b('0xb')),controller=require(_0x5ed22b('0xa'));router['get']('/',auth[_0x5ed22b('0xd')](),controller[_0x5ed22b('0xe')]),router[_0x5ed22b('0x1')]('/:id',auth['isAuthenticated'](),controller[_0x5ed22b('0x7')]),router[_0x5ed22b('0x1')](_0x5ed22b('0xc'),auth[_0x5ed22b('0xd')](),controller['getSounds']),router[_0x5ed22b('0x8')]('/',auth[_0x5ed22b('0xd')](),controller['create']),router[_0x5ed22b('0x8')]('/:id/sounds',auth['isAuthenticated'](),controller['addSound']),router[_0x5ed22b('0x2')](_0x5ed22b('0x9'),auth[_0x5ed22b('0xd')](),controller['update']),router[_0x5ed22b('0x0')](_0x5ed22b('0x9'),auth[_0x5ed22b('0xd')](),controller[_0x5ed22b('0xf')]),router[_0x5ed22b('0x0')](_0x5ed22b('0x4'),auth[_0x5ed22b('0xd')](),controller[_0x5ed22b('0x5')]),module['exports']=router; \ No newline at end of file +const a740_0x2cdd=['/:id/sounds/:id2','Router','show','delete','removeSound','addSound','express','exports','getSounds','/:id/sounds','create','./voiceMusicOnHold.controller','destroy','isAuthenticated','put','/:id','get','update','post'];(function(_0x1aaf7b,_0x2cdd60){const _0x14f3f4=function(_0x32c3be){while(--_0x32c3be){_0x1aaf7b['push'](_0x1aaf7b['shift']());}};_0x14f3f4(++_0x2cdd60);}(a740_0x2cdd,0x87));const a740_0x14f3=function(_0x1aaf7b,_0x2cdd60){_0x1aaf7b=_0x1aaf7b-0x0;let _0x14f3f4=a740_0x2cdd[_0x1aaf7b];return _0x14f3f4;};const _0x43fb6d=a740_0x14f3;'use strict';const express=require(_0x43fb6d('0x4')),router=express[_0x43fb6d('0x12')](),auth=require('../../components/auth/service'),controller=require(_0x43fb6d('0x9'));router[_0x43fb6d('0xe')]('/',auth[_0x43fb6d('0xb')](),controller['index']),router[_0x43fb6d('0xe')](_0x43fb6d('0xd'),auth[_0x43fb6d('0xb')](),controller[_0x43fb6d('0x0')]),router[_0x43fb6d('0xe')](_0x43fb6d('0x7'),auth[_0x43fb6d('0xb')](),controller[_0x43fb6d('0x6')]),router[_0x43fb6d('0x10')]('/',auth[_0x43fb6d('0xb')](),controller[_0x43fb6d('0x8')]),router[_0x43fb6d('0x10')](_0x43fb6d('0x7'),auth[_0x43fb6d('0xb')](),controller[_0x43fb6d('0x3')]),router[_0x43fb6d('0xc')](_0x43fb6d('0xd'),auth[_0x43fb6d('0xb')](),controller[_0x43fb6d('0xf')]),router[_0x43fb6d('0x1')](_0x43fb6d('0xd'),auth[_0x43fb6d('0xb')](),controller[_0x43fb6d('0xa')]),router[_0x43fb6d('0x1')](_0x43fb6d('0x11'),auth[_0x43fb6d('0xb')](),controller[_0x43fb6d('0x2')]),module[_0x43fb6d('0x5')]=router; \ No newline at end of file diff --git a/server/api/voiceMusicOnHold/voiceMusicOnHold.attributes.js b/server/api/voiceMusicOnHold/voiceMusicOnHold.attributes.js index 3807f87..89f5805 100644 --- a/server/api/voiceMusicOnHold/voiceMusicOnHold.attributes.js +++ b/server/api/voiceMusicOnHold/voiceMusicOnHold.attributes.js @@ -1 +1 @@ -const a741_0x37d3=['ENUM','STRING','sequelize','TIMESTAMP','exports','mp3','quietmp3','mp3nb','quietmp3nb'];(function(_0x573cbf,_0x37d3e8){const _0x2ac360=function(_0x121213){while(--_0x121213){_0x573cbf['push'](_0x573cbf['shift']());}};_0x2ac360(++_0x37d3e8);}(a741_0x37d3,0xfe));const a741_0x2ac3=function(_0x573cbf,_0x37d3e8){_0x573cbf=_0x573cbf-0x0;let _0x2ac360=a741_0x37d3[_0x573cbf];return _0x2ac360;};const _0x3a94f7=a741_0x2ac3;'use strict';const Sequelize=require(_0x3a94f7('0x0'));module[_0x3a94f7('0x2')]={'name':{'type':Sequelize[_0x3a94f7('0x8')],'allowNull':![],'unique':'name'},'mode':{'type':Sequelize[_0x3a94f7('0x7')]('custom','files',_0x3a94f7('0x5'),_0x3a94f7('0x6'),_0x3a94f7('0x4'),_0x3a94f7('0x3')),'allowNull':!![],'defaultValue':'files'},'directory':{'type':Sequelize[_0x3a94f7('0x8')],'allowNull':!![]},'application':{'type':Sequelize[_0x3a94f7('0x8')],'allowNull':!![]},'digit':{'type':Sequelize[_0x3a94f7('0x8')],'allowNull':!![]},'sort':{'type':Sequelize[_0x3a94f7('0x8')],'allowNull':!![],'defaultValue':'alpha'},'format':{'type':Sequelize[_0x3a94f7('0x8')],'allowNull':!![]},'stamp':{'type':_0x3a94f7('0x1')},'defaultEntry':{'type':Sequelize['BOOLEAN'],'defaultValue':0x0}}; \ No newline at end of file +const a741_0x1c86=['TIMESTAMP','quietmp3nb','STRING','mp3','files','mp3nb','custom','sequelize','BOOLEAN','exports'];(function(_0x42d152,_0x1c8667){const _0x14cfaa=function(_0x33f3c3){while(--_0x33f3c3){_0x42d152['push'](_0x42d152['shift']());}};_0x14cfaa(++_0x1c8667);}(a741_0x1c86,0xd6));const a741_0x14cf=function(_0x42d152,_0x1c8667){_0x42d152=_0x42d152-0x0;let _0x14cfaa=a741_0x1c86[_0x42d152];return _0x14cfaa;};const _0x1ed5f3=a741_0x14cf;'use strict';const Sequelize=require(_0x1ed5f3('0x3'));module[_0x1ed5f3('0x5')]={'name':{'type':Sequelize[_0x1ed5f3('0x8')],'allowNull':![],'unique':'name'},'mode':{'type':Sequelize['ENUM'](_0x1ed5f3('0x2'),_0x1ed5f3('0x0'),_0x1ed5f3('0x1'),_0x1ed5f3('0x7'),'quietmp3',_0x1ed5f3('0x9')),'allowNull':!![],'defaultValue':_0x1ed5f3('0x0')},'directory':{'type':Sequelize[_0x1ed5f3('0x8')],'allowNull':!![]},'application':{'type':Sequelize['STRING'],'allowNull':!![]},'digit':{'type':Sequelize[_0x1ed5f3('0x8')],'allowNull':!![]},'sort':{'type':Sequelize['STRING'],'allowNull':!![],'defaultValue':'alpha'},'format':{'type':Sequelize[_0x1ed5f3('0x8')],'allowNull':!![]},'stamp':{'type':_0x1ed5f3('0x6')},'defaultEntry':{'type':Sequelize[_0x1ed5f3('0x4')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/voiceMusicOnHold/voiceMusicOnHold.controller.js b/server/api/voiceMusicOnHold/voiceMusicOnHold.controller.js index b48c99a..f47c489 100644 --- a/server/api/voiceMusicOnHold/voiceMusicOnHold.controller.js +++ b/server/api/voiceMusicOnHold/voiceMusicOnHold.controller.js @@ -1 +1 @@ -const a742_0x3653=['id2','symlinkSync','show','keys','VIRTUAL','MusicOnHolds','root','findOne','mode','order','json','query','include','../../components/parsers/qs','name','index','rmdirSync','count','getSounds','filter','user','nolimit','createdAt','key','unlinkSync','sort','Unable\x20to\x20retrieve\x20the\x20current\x20user','filters','../../config/logger','attributes','role','body','%s.%s','rawAttributes','forEach','extname','params','limit','undefined','util','sequelize','status','autoAssociation','fields','message','destroy','converted_format','join','length','lodash','map','files','catch','directory','findAll','where','get','VoiceMusicOnHold','../../config/environment','transaction','like','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','offset','Sound','mkdirSync','options','sendStatus','end','then','removeSound','save_name','../../mysqldb','format','server/files/moh','create','model','send','merge','pick','error','includeAll','update','addSound','stack','intersection','Content-Range'];(function(_0x16176e,_0x365385){const _0x5ea616=function(_0x56d25d){while(--_0x56d25d){_0x16176e['push'](_0x16176e['shift']());}};_0x5ea616(++_0x365385);}(a742_0x3653,0x1e8));const a742_0x5ea6=function(_0x16176e,_0x365385){_0x16176e=_0x16176e-0x0;let _0x5ea616=a742_0x3653[_0x16176e];return _0x5ea616;};const _0x42b149=a742_0x5ea6;'use strict';const util=require(_0x42b149('0x43')),path=require('path'),fs=require('fs'),_=require(_0x42b149('0x4d')),qs=require(_0x42b149('0x29')),logger=require(_0x42b149('0x38'))('api'),config=require(_0x42b149('0x0')),db=require(_0x42b149('0xd'))['db'],{Op,ValidationError}=require(_0x42b149('0x44'));function respondWithStatusCode(_0x56d25d,_0x2fd4d8){return _0x2fd4d8=_0x2fd4d8||0xcc,function(_0xb6c18a){const _0x5246fb=a742_0x5ea6;if(_0xb6c18a)return _0x56d25d[_0x5246fb('0x8')](_0x2fd4d8);return _0x56d25d[_0x5246fb('0x45')](_0x2fd4d8)['end']();};}function respondWithResult(_0x1a1f46,_0x4066cd){return _0x4066cd=_0x4066cd||0xc8,function(_0x3473a2){const _0x208b3f=a742_0x5ea6;if(_0x3473a2)return _0x1a1f46[_0x208b3f('0x45')](_0x4066cd)[_0x208b3f('0x26')](_0x3473a2);};}function respondWithFilteredResult(_0x4e1dc1,_0x17ec6f){return function(_0x591be7){const _0x303b66=a742_0x5ea6;if(_0x591be7){const _0x30a981=_0x591be7[_0x303b66('0x2d')],_0x1cf28c=_0x17ec6f[_0x303b66('0x4')];let _0x3fbcea=_0x17ec6f['offset']+_0x17ec6f[_0x303b66('0x41')],_0x3e5659;return _0x3fbcea>=_0x30a981?(_0x3fbcea=_0x30a981,_0x3e5659=0xc8):_0x3e5659=0xce,_0x4e1dc1['status'](_0x3e5659),_0x4e1dc1['set'](_0x303b66('0x1b'),_0x1cf28c+'-'+_0x3fbcea+'/'+_0x30a981)[_0x303b66('0x26')](_0x591be7);}return null;};}function saveUpdates(_0x3b480e){return function(_0x39ec3f){const _0x4e595b=a742_0x5ea6;if(_0x39ec3f)return _0x39ec3f[_0x4e595b('0x17')](_0x3b480e)[_0x4e595b('0xa')](function(_0x3ca185){return _0x3ca185;});return null;};}function removeEntity(_0x223c63){return function(_0x5bfe5a){const _0x5dec3e=a742_0x5ea6;if(_0x5bfe5a)return _0x5bfe5a[_0x5dec3e('0x49')]()['then'](function(){const _0x284e15=_0x5dec3e,_0x3b0e38=_0x5bfe5a[_0x284e15('0x54')]({'plain':!![]}),_0x23da3b=_0x284e15('0x21');return db['UserProfileResource'][_0x284e15('0x49')]({'where':{'type':_0x23da3b,'resourceId':_0x3b0e38['id']}})['then'](function(){return _0x5bfe5a;});})['then'](function(){const _0x4994e4=_0x5dec3e;_0x223c63[_0x4994e4('0x45')](0xcc)[_0x4994e4('0x9')]();});};}function handleEntityNotFound(_0x3dd16e){return function(_0xcd88b6){return!_0xcd88b6&&_0x3dd16e['sendStatus'](0x194),_0xcd88b6;};}function handleError(_0x3ef08d,_0x4f9e02){return _0x4f9e02=_0x4f9e02||0x1f4,function(_0x312568){const _0x50c579=a742_0x5ea6;logger['error'](_0x312568[_0x50c579('0x19')]),_0x312568[_0x50c579('0x2a')]&&delete _0x312568[_0x50c579('0x2a')],_0x3ef08d['status'](_0x4f9e02)[_0x50c579('0x12')](_0x312568);};}exports[_0x42b149('0x2b')]=function(_0x3a87ba,_0x53528b){const _0x49c367=_0x42b149;let _0x31d87f={};const _0x431e79={},_0x3ad87e={'count':0x0,'rows':[]},_0x499428=_[_0x49c367('0x4e')](db[_0x49c367('0x55')]['rawAttributes'],function(_0x527821){const _0x41f284=_0x49c367;return{'name':_0x527821['fieldName'],'type':_0x527821['type'][_0x41f284('0x33')]};});_0x431e79[_0x49c367('0x11')]=_['map'](_0x499428,'name'),_0x431e79[_0x49c367('0x27')]=_[_0x49c367('0x1f')](_0x3a87ba[_0x49c367('0x27')]),_0x431e79['filters']=_[_0x49c367('0x1a')](_0x431e79['model'],_0x431e79[_0x49c367('0x27')]),_0x31d87f['attributes']=_[_0x49c367('0x1a')](_0x431e79[_0x49c367('0x11')],qs[_0x49c367('0x47')](_0x3a87ba[_0x49c367('0x27')][_0x49c367('0x47')])),_0x31d87f[_0x49c367('0x39')]=_0x31d87f[_0x49c367('0x39')]['length']?_0x31d87f[_0x49c367('0x39')]:_0x431e79[_0x49c367('0x11')];typeof _0x3a87ba['query'][_0x49c367('0x31')]===_0x49c367('0x42')&&(_0x31d87f[_0x49c367('0x41')]=qs['limit'](_0x3a87ba[_0x49c367('0x27')][_0x49c367('0x41')]),_0x31d87f['offset']=qs['offset'](_0x3a87ba[_0x49c367('0x27')][_0x49c367('0x4')]));_0x31d87f[_0x49c367('0x25')]=qs[_0x49c367('0x35')](_0x3a87ba[_0x49c367('0x27')][_0x49c367('0x35')]),_0x31d87f[_0x49c367('0x53')]=qs[_0x49c367('0x37')](_[_0x49c367('0x14')](_0x3a87ba[_0x49c367('0x27')],_0x431e79[_0x49c367('0x37')]),_0x499428);_0x3a87ba[_0x49c367('0x27')][_0x49c367('0x2f')]&&(_0x31d87f[_0x49c367('0x53')]=_[_0x49c367('0x13')](_0x31d87f[_0x49c367('0x53')],{[Op['or']]:_[_0x49c367('0x4e')](_0x499428,function(_0x36285a){const _0x5dbc9c=_0x49c367;if(_0x36285a['type']!==_0x5dbc9c('0x20')){const _0x1e9ca5={};return _0x1e9ca5[_0x36285a[_0x5dbc9c('0x2a')]]={[Op['like']]:'%'+_0x3a87ba[_0x5dbc9c('0x27')][_0x5dbc9c('0x2f')]+'%'},_0x1e9ca5;}})}));_0x31d87f=_['merge']({},_0x31d87f,_0x3a87ba[_0x49c367('0x7')]);const _0x2c9811={'where':_0x31d87f['where']};return db['VoiceMusicOnHold'][_0x49c367('0x2d')](_0x2c9811)[_0x49c367('0xa')](function(_0x346733){const _0x5dfa08=_0x49c367;return _0x3ad87e[_0x5dfa08('0x2d')]=_0x346733,_0x3a87ba['query']['includeAll']&&(_0x31d87f['include']=[{'all':!![]}]),db[_0x5dfa08('0x55')][_0x5dfa08('0x52')](_0x31d87f);})[_0x49c367('0xa')](function(_0x111d2e){return _0x3ad87e['rows']=_0x111d2e,_0x3ad87e;})[_0x49c367('0xa')](respondWithFilteredResult(_0x53528b,_0x31d87f))[_0x49c367('0x50')](handleError(_0x53528b,null));},exports[_0x42b149('0x1e')]=function(_0x449683,_0x3db5a6){const _0x24d72c=_0x42b149;let _0xbc1200={'raw':![],'where':{'id':_0x449683['params']['id']}};const _0x102452={};return _0x102452['model']=_[_0x24d72c('0x1f')](db[_0x24d72c('0x55')][_0x24d72c('0x3d')]),_0x102452[_0x24d72c('0x27')]=_[_0x24d72c('0x1f')](_0x449683[_0x24d72c('0x27')]),_0x102452[_0x24d72c('0x37')]=_['intersection'](_0x102452[_0x24d72c('0x11')],_0x102452['query']),_0xbc1200[_0x24d72c('0x39')]=_[_0x24d72c('0x1a')](_0x102452[_0x24d72c('0x11')],qs['fields'](_0x449683[_0x24d72c('0x27')]['fields'])),_0xbc1200[_0x24d72c('0x39')]=_0xbc1200[_0x24d72c('0x39')][_0x24d72c('0x4c')]?_0xbc1200[_0x24d72c('0x39')]:_0x102452[_0x24d72c('0x11')],_0x449683[_0x24d72c('0x27')][_0x24d72c('0x16')]&&(_0xbc1200[_0x24d72c('0x28')]=[{'all':!![]}]),_0xbc1200=_['merge']({},_0xbc1200,_0x449683[_0x24d72c('0x7')]),db[_0x24d72c('0x55')][_0x24d72c('0x23')](_0xbc1200)[_0x24d72c('0xa')](handleEntityNotFound(_0x3db5a6,null))[_0x24d72c('0xa')](respondWithResult(_0x3db5a6,null))[_0x24d72c('0x50')](handleError(_0x3db5a6,null));},exports[_0x42b149('0x17')]=function(_0x240566,_0x3f0041){const _0x3834e0=_0x42b149;return _0x240566[_0x3834e0('0x3b')]['id']&&delete _0x240566[_0x3834e0('0x3b')]['id'],db['VoiceMusicOnHold'][_0x3834e0('0x23')]({'where':{'id':_0x240566[_0x3834e0('0x40')]['id']}})[_0x3834e0('0xa')](handleEntityNotFound(_0x3f0041,null))[_0x3834e0('0xa')](saveUpdates(_0x240566[_0x3834e0('0x3b')],null))[_0x3834e0('0xa')](respondWithResult(_0x3f0041,null))[_0x3834e0('0x50')](handleError(_0x3f0041,null));},exports[_0x42b149('0x10')]=function(_0xe87087,_0x4d9460){const _0x19ac57=_0x42b149;return db[_0x19ac57('0x44')][_0x19ac57('0x1')](function(_0x546a27){const _0x166945=_0x19ac57;return _0xe87087[_0x166945('0x3b')][_0x166945('0x24')]===_0x166945('0x4f')&&(_0xe87087[_0x166945('0x3b')][_0x166945('0x51')]=path[_0x166945('0x4b')](config[_0x166945('0x22')],_0x166945('0xf'),_0xe87087['body'][_0x166945('0x2a')])),db[_0x166945('0x55')][_0x166945('0x10')](_0xe87087[_0x166945('0x3b')],{'transaction':_0x546a27})['then'](function(_0x484928){const _0x12ad74=_0x166945;_0xe87087[_0x12ad74('0x3b')][_0x12ad74('0x24')]===_0x12ad74('0x4f')&&fs[_0x12ad74('0x6')](_0x484928[_0x12ad74('0x51')],parseInt('0777',0x8));const _0x15ccb3=_0xe87087['user'][_0x12ad74('0x54')]({'plain':!![]});if(!_0x15ccb3)throw new Error(_0x12ad74('0x36'));if(_0x15ccb3[_0x12ad74('0x3a')]===_0x12ad74('0x30')){const _0x1d10d9=_0x484928[_0x12ad74('0x54')]({'plain':!![]});return db['UserProfileSection'][_0x12ad74('0x23')]({'where':{'name':_0x12ad74('0x21'),'userProfileId':_0x15ccb3['userProfileId']},'raw':!![]})['then'](function(_0x5076f3){const _0x2a5e99=_0x12ad74;return _0x5076f3&&_0x5076f3[_0x2a5e99('0x46')]===0x0?db['UserProfileResource'][_0x2a5e99('0x10')]({'name':_0x1d10d9[_0x2a5e99('0x2a')],'resourceId':_0x1d10d9['id'],'type':_0x5076f3[_0x2a5e99('0x2a')],'sectionId':_0x5076f3['id']},{})['then'](function(){return _0x484928;}):_0x484928;})[_0x12ad74('0x50')](function(_0x25a2dd){const _0x2b6d63=_0x12ad74;logger[_0x2b6d63('0x15')](_0x2b6d63('0x3'),_0x25a2dd);});}return _0x484928;});})['then'](respondWithResult(_0x4d9460,0xc9))['catch'](handleError(_0x4d9460,null));},exports[_0x42b149('0x49')]=function(_0xb2175b,_0x336ec6){const _0x4e2b72=_0x42b149;return db[_0x4e2b72('0x55')]['findOne']({'where':{'id':_0xb2175b[_0x4e2b72('0x40')]['id']}})['then'](function(_0x13806d){const _0x106f03=_0x4e2b72;if(_0x13806d)return db[_0x106f03('0x44')][_0x106f03('0x1')](function(_0x490e40){const _0x4b34bd=_0x106f03;return _0x13806d['destroy']({'transaction':_0x490e40,'raw':!![]})[_0x4b34bd('0xa')](function(_0x47c50c){const _0x59770f=_0x4b34bd;return _0x47c50c['directory']&&(fs['readdirSync'](_0x47c50c[_0x59770f('0x51')])[_0x59770f('0x3e')](function(_0x48a633){const _0x1e0fae=_0x59770f;fs[_0x1e0fae('0x34')](path[_0x1e0fae('0x4b')](_0x47c50c[_0x1e0fae('0x51')],_0x48a633));}),fs[_0x59770f('0x2c')](_0x47c50c[_0x59770f('0x51')])),_0x47c50c;});})[_0x106f03('0x50')](function(_0x39e4b8){const _0x1b9772=_0x106f03;throw new ValidationError(_0x39e4b8[_0x1b9772('0x48')]);});})[_0x4e2b72('0xa')](handleEntityNotFound(_0x336ec6,null))['then'](removeEntity(_0x336ec6,null))[_0x4e2b72('0x50')](handleError(_0x336ec6,null));},exports['addSound']=function(_0x3ebf25,_0x5c293f){const _0x22fb11=_0x42b149;return db[_0x22fb11('0x44')]['transaction'](function(_0x1e781d){const _0x24e20e=_0x22fb11;let _0x5d3f68;return db[_0x24e20e('0x55')][_0x24e20e('0x23')]({'where':{'id':_0x3ebf25[_0x24e20e('0x40')]['id']}})[_0x24e20e('0xa')](function(_0x3e7975){const _0x1067fd=_0x24e20e;if(_0x3e7975)return _0x5d3f68=_0x3e7975,_0x3e7975[_0x1067fd('0x18')](_0x3ebf25[_0x1067fd('0x3b')]['id'],{'transaction':_0x1e781d});})[_0x24e20e('0xa')](function(_0xdf6da){const _0x532719=_0x24e20e;if(_0xdf6da)return db[_0x532719('0x5')][_0x532719('0x23')]({'where':{'id':_0x3ebf25[_0x532719('0x3b')]['id']},'attributes':['id',_0x532719('0x2a'),_0x532719('0xc'),_0x532719('0x4a'),_0x532719('0x32')],'raw':!![]});})['then'](function(_0x353fbe){const _0x9d2004=_0x24e20e;if(_0x353fbe){const _0xd163e2=path[_0x9d2004('0x4b')](config[_0x9d2004('0x22')],'server/files/sounds/converted',util[_0x9d2004('0xe')]('%s.%s',path['basename'](_0x353fbe[_0x9d2004('0xc')],path[_0x9d2004('0x3f')](_0x353fbe[_0x9d2004('0xc')])),_0x353fbe[_0x9d2004('0x4a')])),_0x237d48=path['join'](config[_0x9d2004('0x22')],'server/files/moh',_0x5d3f68[_0x9d2004('0x2a')],util['format'](_0x9d2004('0x3c'),_0x353fbe[_0x9d2004('0x2a')],_0x353fbe[_0x9d2004('0x4a')]));return fs[_0x9d2004('0x1d')](_0xd163e2,_0x237d48),_0x353fbe;}})[_0x24e20e('0x50')](function(_0x361974){throw new ValidationError(_0x361974['message']);});})[_0x22fb11('0xa')](handleEntityNotFound(_0x5c293f,null))[_0x22fb11('0xa')](respondWithResult(_0x5c293f,0xc9))['catch'](handleError(_0x5c293f,null));},exports[_0x42b149('0xb')]=function(_0x233855,_0x54f967){const _0x5484d2=_0x42b149;return db['sequelize']['transaction'](function(){const _0x3387be=a742_0x5ea6;let _0x316c77;return db[_0x3387be('0x55')][_0x3387be('0x23')]({'where':{'id':_0x233855[_0x3387be('0x40')]['id']}})[_0x3387be('0xa')](handleEntityNotFound(_0x54f967,null))['then'](function(_0x188bdd){const _0x4c63bf=_0x3387be;if(_0x188bdd)return _0x316c77=_0x188bdd,_0x188bdd['removeSound'](_0x233855['params'][_0x4c63bf('0x1c')]);})['then'](function(_0x2e8028){const _0x5a8c03=_0x3387be;if(_0x2e8028)return db['Sound']['findOne']({'where':{'id':_0x233855['params'][_0x5a8c03('0x1c')]},'attributes':['id',_0x5a8c03('0x2a'),'save_name',_0x5a8c03('0x4a'),_0x5a8c03('0x32')],'raw':!![]});})[_0x3387be('0xa')](function(_0x7ac6c7){const _0x38cf44=_0x3387be;if(_0x7ac6c7)return fs['unlinkSync'](path[_0x38cf44('0x4b')](_0x316c77[_0x38cf44('0x51')],util[_0x38cf44('0xe')]('%s.%s',_0x7ac6c7[_0x38cf44('0x2a')],_0x7ac6c7[_0x38cf44('0x4a')]))),_0x7ac6c7;})[_0x3387be('0x50')](function(_0x381c0a){throw new ValidationError(_0x381c0a['message']);});})[_0x5484d2('0xa')](handleEntityNotFound(_0x54f967,null))['then'](respondWithStatusCode(_0x54f967,0xcc))[_0x5484d2('0x50')](handleError(_0x54f967,null));},exports[_0x42b149('0x2e')]=function(_0x3ca569,_0x4cfc0b){const _0x263a87=_0x42b149;let _0x32061a={};const _0x540f7a={};let _0x2905d3,_0x503b6f;return db['VoiceMusicOnHold']['findOne']({'where':{'id':_0x3ca569[_0x263a87('0x40')]['id']}})[_0x263a87('0xa')](handleEntityNotFound(_0x4cfc0b,null))['then'](function(_0x712bb7){const _0x542ff7=_0x263a87;if(_0x712bb7)return _0x2905d3=_0x712bb7,_0x540f7a[_0x542ff7('0x11')]=_[_0x542ff7('0x1f')](db[_0x542ff7('0x5')][_0x542ff7('0x3d')]),_0x540f7a[_0x542ff7('0x27')]=_[_0x542ff7('0x1f')](_0x3ca569['query']),_0x540f7a[_0x542ff7('0x37')]=_[_0x542ff7('0x1a')](_0x540f7a[_0x542ff7('0x11')],_0x540f7a[_0x542ff7('0x27')]),_0x32061a[_0x542ff7('0x39')]=_[_0x542ff7('0x1a')](_0x540f7a['model'],qs[_0x542ff7('0x47')](_0x3ca569[_0x542ff7('0x27')]['fields'])),_0x32061a[_0x542ff7('0x39')]=_0x32061a[_0x542ff7('0x39')]['length']?_0x32061a[_0x542ff7('0x39')]:_0x540f7a[_0x542ff7('0x11')],_0x32061a[_0x542ff7('0x25')]=qs[_0x542ff7('0x35')](_0x3ca569[_0x542ff7('0x27')][_0x542ff7('0x35')]),_0x32061a['where']=qs[_0x542ff7('0x37')](_[_0x542ff7('0x14')](_0x3ca569[_0x542ff7('0x27')],_0x540f7a[_0x542ff7('0x37')])),_0x3ca569[_0x542ff7('0x27')][_0x542ff7('0x2f')]&&(_0x32061a[_0x542ff7('0x53')]=_[_0x542ff7('0x13')](_0x32061a['where'],{[Op['or']]:_[_0x542ff7('0x4e')](_0x32061a[_0x542ff7('0x39')],function(_0x461e9e){const _0x1af1b3=_0x542ff7,_0x9d48d9={};return _0x9d48d9[_0x461e9e]={[Op[_0x1af1b3('0x2')]]:'%'+_0x3ca569[_0x1af1b3('0x27')][_0x1af1b3('0x2f')]+'%'},_0x9d48d9;})})),_0x32061a=_['merge']({},_0x32061a,_0x3ca569[_0x542ff7('0x7')]),_0x2905d3[_0x542ff7('0x2e')](_0x32061a);})['then'](function(_0x4d457c){const _0x16d5e4=_0x263a87;if(_0x4d457c)return _0x503b6f=_0x4d457c[_0x16d5e4('0x4c')],typeof _0x3ca569['query'][_0x16d5e4('0x31')]==='undefined'&&(_0x32061a[_0x16d5e4('0x41')]=qs[_0x16d5e4('0x41')](_0x3ca569[_0x16d5e4('0x27')][_0x16d5e4('0x41')]),_0x32061a[_0x16d5e4('0x4')]=qs[_0x16d5e4('0x4')](_0x3ca569[_0x16d5e4('0x27')][_0x16d5e4('0x4')])),_0x2905d3['getSounds'](_0x32061a);})[_0x263a87('0xa')](function(_0x346d5d){if(_0x346d5d)return _0x346d5d?{'count':_0x503b6f,'rows':_0x346d5d}:null;})[_0x263a87('0xa')](respondWithResult(_0x4cfc0b,null))[_0x263a87('0x50')](handleError(_0x4cfc0b,null));}; \ No newline at end of file +const a742_0x4dd9=['root','findOne','attributes','save_name','../../mysqldb','rows','sort','user','merge','filter','Content-Range','lodash','pick','converted_format','../../config/environment','then','autoAssociation','%s.%s','VIRTUAL','model','length','basename','create','unlinkSync','limit','nolimit','VoiceMusicOnHold','options','intersection','server/files/moh','include','status','set','mode','UserProfileSection','show','addSound','map','filters','keys','count','query','UserProfileResource','name','undefined','forEach','format','getSounds','index','sendStatus','message','catch','files','mkdirSync','createdAt','end','fields','offset','server/files/sounds/converted','../../components/parsers/qs','error','findAll','where','sequelize','util','params','Sound','removeSound','directory','fieldName','Unable\x20to\x20retrieve\x20the\x20current\x20user','update','destroy','userProfileId','MusicOnHolds','order','extname','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','../../config/logger','api','body','transaction','includeAll','like','join','get','symlinkSync','rawAttributes','path'];(function(_0x7989ef,_0x4dd9f5){const _0x3cf7fa=function(_0x44d350){while(--_0x44d350){_0x7989ef['push'](_0x7989ef['shift']());}};_0x3cf7fa(++_0x4dd9f5);}(a742_0x4dd9,0x1ce));const a742_0x3cf7=function(_0x7989ef,_0x4dd9f5){_0x7989ef=_0x7989ef-0x0;let _0x3cf7fa=a742_0x4dd9[_0x7989ef];return _0x3cf7fa;};const _0x7643f6=a742_0x3cf7;'use strict';const util=require(_0x7643f6('0x2f')),path=require(_0x7643f6('0x47')),fs=require('fs'),_=require(_0x7643f6('0x53')),qs=require(_0x7643f6('0x2a')),logger=require(_0x7643f6('0x3d'))(_0x7643f6('0x3e')),config=require(_0x7643f6('0x56')),db=require(_0x7643f6('0x4c'))['db'],{Op,ValidationError}=require(_0x7643f6('0x2e'));function respondWithStatusCode(_0x44d350,_0x194022){return _0x194022=_0x194022||0xcc,function(_0x10819c){const _0x10611d=a742_0x3cf7;if(_0x10819c)return _0x44d350[_0x10611d('0x20')](_0x194022);return _0x44d350['status'](_0x194022)[_0x10611d('0x26')]();};}function respondWithResult(_0x4d0d91,_0x56a9c2){return _0x56a9c2=_0x56a9c2||0xc8,function(_0x52a106){const _0x3a5ceb=a742_0x3cf7;if(_0x52a106)return _0x4d0d91[_0x3a5ceb('0xe')](_0x56a9c2)['json'](_0x52a106);};}function respondWithFilteredResult(_0x414a03,_0x402942){return function(_0x711021){const _0x4e9f19=a742_0x3cf7;if(_0x711021){const _0x44af4d=_0x711021[_0x4e9f19('0x17')],_0x5a34ed=_0x402942[_0x4e9f19('0x28')];let _0x5bdfb5=_0x402942[_0x4e9f19('0x28')]+_0x402942[_0x4e9f19('0x7')],_0x3102f3;return _0x5bdfb5>=_0x44af4d?(_0x5bdfb5=_0x44af4d,_0x3102f3=0xc8):_0x3102f3=0xce,_0x414a03[_0x4e9f19('0xe')](_0x3102f3),_0x414a03[_0x4e9f19('0xf')](_0x4e9f19('0x52'),_0x5a34ed+'-'+_0x5bdfb5+'/'+_0x44af4d)['json'](_0x711021);}return null;};}function saveUpdates(_0x4010e2){return function(_0x41ce87){const _0x26f3d2=a742_0x3cf7;if(_0x41ce87)return _0x41ce87[_0x26f3d2('0x36')](_0x4010e2)[_0x26f3d2('0x57')](function(_0x640f2a){return _0x640f2a;});return null;};}function removeEntity(_0x4ac01c){return function(_0xcb6cef){const _0x4c18a0=a742_0x3cf7;if(_0xcb6cef)return _0xcb6cef[_0x4c18a0('0x37')]()['then'](function(){const _0x5ea396=_0x4c18a0,_0x257b45=_0xcb6cef[_0x5ea396('0x44')]({'plain':!![]}),_0x20c83c=_0x5ea396('0x39');return db[_0x5ea396('0x19')][_0x5ea396('0x37')]({'where':{'type':_0x20c83c,'resourceId':_0x257b45['id']}})['then'](function(){return _0xcb6cef;});})[_0x4c18a0('0x57')](function(){const _0x2da0ab=_0x4c18a0;_0x4ac01c['status'](0xcc)[_0x2da0ab('0x26')]();});};}function handleEntityNotFound(_0x46dd91){return function(_0x473e46){const _0x3ba903=a742_0x3cf7;return!_0x473e46&&_0x46dd91[_0x3ba903('0x20')](0x194),_0x473e46;};}function handleError(_0x2a96ba,_0x35ffd4){return _0x35ffd4=_0x35ffd4||0x1f4,function(_0x3632c0){const _0x2b7a96=a742_0x3cf7;logger[_0x2b7a96('0x2b')](_0x3632c0['stack']),_0x3632c0[_0x2b7a96('0x1a')]&&delete _0x3632c0[_0x2b7a96('0x1a')],_0x2a96ba[_0x2b7a96('0xe')](_0x35ffd4)['send'](_0x3632c0);};}exports[_0x7643f6('0x1f')]=function(_0x285271,_0x32d36f){const _0x179afd=_0x7643f6;let _0x13aede={};const _0x3c3058={},_0x148817={'count':0x0,'rows':[]},_0x493f40=_['map'](db['VoiceMusicOnHold']['rawAttributes'],function(_0x3c1c47){const _0x57dd35=a742_0x3cf7;return{'name':_0x3c1c47[_0x57dd35('0x34')],'type':_0x3c1c47['type']['key']};});_0x3c3058[_0x179afd('0x2')]=_['map'](_0x493f40,'name'),_0x3c3058[_0x179afd('0x18')]=_[_0x179afd('0x16')](_0x285271[_0x179afd('0x18')]),_0x3c3058['filters']=_[_0x179afd('0xb')](_0x3c3058['model'],_0x3c3058[_0x179afd('0x18')]),_0x13aede[_0x179afd('0x4a')]=_['intersection'](_0x3c3058['model'],qs[_0x179afd('0x27')](_0x285271['query'][_0x179afd('0x27')])),_0x13aede[_0x179afd('0x4a')]=_0x13aede['attributes'][_0x179afd('0x3')]?_0x13aede[_0x179afd('0x4a')]:_0x3c3058[_0x179afd('0x2')];typeof _0x285271[_0x179afd('0x18')][_0x179afd('0x8')]===_0x179afd('0x1b')&&(_0x13aede['limit']=qs[_0x179afd('0x7')](_0x285271[_0x179afd('0x18')]['limit']),_0x13aede[_0x179afd('0x28')]=qs['offset'](_0x285271['query'][_0x179afd('0x28')]));_0x13aede[_0x179afd('0x3a')]=qs[_0x179afd('0x4e')](_0x285271[_0x179afd('0x18')][_0x179afd('0x4e')]),_0x13aede['where']=qs[_0x179afd('0x15')](_[_0x179afd('0x54')](_0x285271[_0x179afd('0x18')],_0x3c3058[_0x179afd('0x15')]),_0x493f40);_0x285271[_0x179afd('0x18')][_0x179afd('0x51')]&&(_0x13aede[_0x179afd('0x2d')]=_[_0x179afd('0x50')](_0x13aede['where'],{[Op['or']]:_[_0x179afd('0x14')](_0x493f40,function(_0x598582){const _0x5a0026=_0x179afd;if(_0x598582['type']!==_0x5a0026('0x1')){const _0x137269={};return _0x137269[_0x598582['name']]={[Op[_0x5a0026('0x42')]]:'%'+_0x285271[_0x5a0026('0x18')][_0x5a0026('0x51')]+'%'},_0x137269;}})}));_0x13aede=_[_0x179afd('0x50')]({},_0x13aede,_0x285271['options']);const _0x55a7e9={'where':_0x13aede['where']};return db['VoiceMusicOnHold'][_0x179afd('0x17')](_0x55a7e9)['then'](function(_0x1943ee){const _0x23854f=_0x179afd;return _0x148817[_0x23854f('0x17')]=_0x1943ee,_0x285271[_0x23854f('0x18')][_0x23854f('0x41')]&&(_0x13aede[_0x23854f('0xd')]=[{'all':!![]}]),db['VoiceMusicOnHold'][_0x23854f('0x2c')](_0x13aede);})[_0x179afd('0x57')](function(_0x26b47a){const _0x29d54b=_0x179afd;return _0x148817[_0x29d54b('0x4d')]=_0x26b47a,_0x148817;})[_0x179afd('0x57')](respondWithFilteredResult(_0x32d36f,_0x13aede))[_0x179afd('0x22')](handleError(_0x32d36f,null));},exports[_0x7643f6('0x12')]=function(_0x43510b,_0x112063){const _0x439190=_0x7643f6;let _0x48a745={'raw':![],'where':{'id':_0x43510b[_0x439190('0x30')]['id']}};const _0xf817fc={};return _0xf817fc[_0x439190('0x2')]=_[_0x439190('0x16')](db[_0x439190('0x9')][_0x439190('0x46')]),_0xf817fc['query']=_[_0x439190('0x16')](_0x43510b[_0x439190('0x18')]),_0xf817fc[_0x439190('0x15')]=_[_0x439190('0xb')](_0xf817fc[_0x439190('0x2')],_0xf817fc[_0x439190('0x18')]),_0x48a745[_0x439190('0x4a')]=_['intersection'](_0xf817fc[_0x439190('0x2')],qs[_0x439190('0x27')](_0x43510b['query']['fields'])),_0x48a745[_0x439190('0x4a')]=_0x48a745[_0x439190('0x4a')]['length']?_0x48a745[_0x439190('0x4a')]:_0xf817fc[_0x439190('0x2')],_0x43510b['query']['includeAll']&&(_0x48a745['include']=[{'all':!![]}]),_0x48a745=_[_0x439190('0x50')]({},_0x48a745,_0x43510b[_0x439190('0xa')]),db[_0x439190('0x9')]['findOne'](_0x48a745)[_0x439190('0x57')](handleEntityNotFound(_0x112063,null))['then'](respondWithResult(_0x112063,null))[_0x439190('0x22')](handleError(_0x112063,null));},exports[_0x7643f6('0x36')]=function(_0x3ad945,_0x75ed59){const _0x2f6a3b=_0x7643f6;return _0x3ad945[_0x2f6a3b('0x3f')]['id']&&delete _0x3ad945[_0x2f6a3b('0x3f')]['id'],db[_0x2f6a3b('0x9')]['findOne']({'where':{'id':_0x3ad945[_0x2f6a3b('0x30')]['id']}})['then'](handleEntityNotFound(_0x75ed59,null))[_0x2f6a3b('0x57')](saveUpdates(_0x3ad945[_0x2f6a3b('0x3f')],null))[_0x2f6a3b('0x57')](respondWithResult(_0x75ed59,null))['catch'](handleError(_0x75ed59,null));},exports[_0x7643f6('0x5')]=function(_0x3ec7d0,_0x57f75f){const _0x57a367=_0x7643f6;return db['sequelize']['transaction'](function(_0x1b4277){const _0xcc27d9=a742_0x3cf7;return _0x3ec7d0[_0xcc27d9('0x3f')][_0xcc27d9('0x10')]===_0xcc27d9('0x23')&&(_0x3ec7d0[_0xcc27d9('0x3f')][_0xcc27d9('0x33')]=path[_0xcc27d9('0x43')](config['root'],'server/files/moh',_0x3ec7d0[_0xcc27d9('0x3f')]['name'])),db['VoiceMusicOnHold'][_0xcc27d9('0x5')](_0x3ec7d0['body'],{'transaction':_0x1b4277})[_0xcc27d9('0x57')](function(_0x478e42){const _0x3bbc14=_0xcc27d9;_0x3ec7d0['body'][_0x3bbc14('0x10')]===_0x3bbc14('0x23')&&fs[_0x3bbc14('0x24')](_0x478e42[_0x3bbc14('0x33')],parseInt('0777',0x8));const _0x4039b3=_0x3ec7d0[_0x3bbc14('0x4f')][_0x3bbc14('0x44')]({'plain':!![]});if(!_0x4039b3)throw new Error(_0x3bbc14('0x35'));if(_0x4039b3['role']===_0x3bbc14('0x4f')){const _0x5dc189=_0x478e42[_0x3bbc14('0x44')]({'plain':!![]});return db[_0x3bbc14('0x11')][_0x3bbc14('0x49')]({'where':{'name':_0x3bbc14('0x39'),'userProfileId':_0x4039b3[_0x3bbc14('0x38')]},'raw':!![]})[_0x3bbc14('0x57')](function(_0x4b06f5){const _0x30e4d1=_0x3bbc14;return _0x4b06f5&&_0x4b06f5[_0x30e4d1('0x58')]===0x0?db[_0x30e4d1('0x19')][_0x30e4d1('0x5')]({'name':_0x5dc189[_0x30e4d1('0x1a')],'resourceId':_0x5dc189['id'],'type':_0x4b06f5['name'],'sectionId':_0x4b06f5['id']},{})['then'](function(){return _0x478e42;}):_0x478e42;})[_0x3bbc14('0x22')](function(_0xf807c2){const _0x59fce1=_0x3bbc14;logger['error'](_0x59fce1('0x3c'),_0xf807c2);});}return _0x478e42;});})['then'](respondWithResult(_0x57f75f,0xc9))[_0x57a367('0x22')](handleError(_0x57f75f,null));},exports[_0x7643f6('0x37')]=function(_0x555d55,_0x11a495){const _0x48f738=_0x7643f6;return db[_0x48f738('0x9')][_0x48f738('0x49')]({'where':{'id':_0x555d55[_0x48f738('0x30')]['id']}})[_0x48f738('0x57')](function(_0x490739){const _0x2e9588=_0x48f738;if(_0x490739)return db[_0x2e9588('0x2e')][_0x2e9588('0x40')](function(_0x4dd7c6){const _0x341426=_0x2e9588;return _0x490739[_0x341426('0x37')]({'transaction':_0x4dd7c6,'raw':!![]})['then'](function(_0x3a3c08){const _0x37a556=_0x341426;return _0x3a3c08[_0x37a556('0x33')]&&(fs['readdirSync'](_0x3a3c08['directory'])[_0x37a556('0x1c')](function(_0x1e3632){const _0x2a52db=_0x37a556;fs[_0x2a52db('0x6')](path['join'](_0x3a3c08[_0x2a52db('0x33')],_0x1e3632));}),fs['rmdirSync'](_0x3a3c08[_0x37a556('0x33')])),_0x3a3c08;});})[_0x2e9588('0x22')](function(_0x4ed95a){const _0x5143a0=_0x2e9588;throw new ValidationError(_0x4ed95a[_0x5143a0('0x21')]);});})[_0x48f738('0x57')](handleEntityNotFound(_0x11a495,null))[_0x48f738('0x57')](removeEntity(_0x11a495,null))[_0x48f738('0x22')](handleError(_0x11a495,null));},exports[_0x7643f6('0x13')]=function(_0x260bd8,_0x43069f){const _0x232c8f=_0x7643f6;return db[_0x232c8f('0x2e')][_0x232c8f('0x40')](function(_0x41aa93){const _0x14589b=_0x232c8f;let _0x1ea376;return db[_0x14589b('0x9')][_0x14589b('0x49')]({'where':{'id':_0x260bd8[_0x14589b('0x30')]['id']}})['then'](function(_0x5ee997){const _0x515353=_0x14589b;if(_0x5ee997)return _0x1ea376=_0x5ee997,_0x5ee997[_0x515353('0x13')](_0x260bd8['body']['id'],{'transaction':_0x41aa93});})[_0x14589b('0x57')](function(_0x3b2eba){const _0x28e02d=_0x14589b;if(_0x3b2eba)return db[_0x28e02d('0x31')][_0x28e02d('0x49')]({'where':{'id':_0x260bd8['body']['id']},'attributes':['id',_0x28e02d('0x1a'),_0x28e02d('0x4b'),'converted_format','createdAt'],'raw':!![]});})[_0x14589b('0x57')](function(_0x2427d4){const _0x46973b=_0x14589b;if(_0x2427d4){const _0x554a0c=path['join'](config[_0x46973b('0x48')],_0x46973b('0x29'),util[_0x46973b('0x1d')](_0x46973b('0x0'),path[_0x46973b('0x4')](_0x2427d4['save_name'],path[_0x46973b('0x3b')](_0x2427d4['save_name'])),_0x2427d4[_0x46973b('0x55')])),_0x24649c=path[_0x46973b('0x43')](config[_0x46973b('0x48')],_0x46973b('0xc'),_0x1ea376[_0x46973b('0x1a')],util[_0x46973b('0x1d')](_0x46973b('0x0'),_0x2427d4[_0x46973b('0x1a')],_0x2427d4[_0x46973b('0x55')]));return fs[_0x46973b('0x45')](_0x554a0c,_0x24649c),_0x2427d4;}})[_0x14589b('0x22')](function(_0x3d8b7c){throw new ValidationError(_0x3d8b7c['message']);});})['then'](handleEntityNotFound(_0x43069f,null))[_0x232c8f('0x57')](respondWithResult(_0x43069f,0xc9))[_0x232c8f('0x22')](handleError(_0x43069f,null));},exports[_0x7643f6('0x32')]=function(_0x364b20,_0x5ebacd){const _0x450995=_0x7643f6;return db[_0x450995('0x2e')][_0x450995('0x40')](function(){const _0x3e6ac9=_0x450995;let _0x24fb71;return db[_0x3e6ac9('0x9')][_0x3e6ac9('0x49')]({'where':{'id':_0x364b20['params']['id']}})['then'](handleEntityNotFound(_0x5ebacd,null))[_0x3e6ac9('0x57')](function(_0x38fe23){const _0x188db0=_0x3e6ac9;if(_0x38fe23)return _0x24fb71=_0x38fe23,_0x38fe23[_0x188db0('0x32')](_0x364b20[_0x188db0('0x30')]['id2']);})[_0x3e6ac9('0x57')](function(_0x3a02b7){const _0x2bba39=_0x3e6ac9;if(_0x3a02b7)return db[_0x2bba39('0x31')][_0x2bba39('0x49')]({'where':{'id':_0x364b20[_0x2bba39('0x30')]['id2']},'attributes':['id','name',_0x2bba39('0x4b'),_0x2bba39('0x55'),_0x2bba39('0x25')],'raw':!![]});})['then'](function(_0x2040be){const _0x5dbb8f=_0x3e6ac9;if(_0x2040be)return fs['unlinkSync'](path[_0x5dbb8f('0x43')](_0x24fb71[_0x5dbb8f('0x33')],util[_0x5dbb8f('0x1d')](_0x5dbb8f('0x0'),_0x2040be['name'],_0x2040be[_0x5dbb8f('0x55')]))),_0x2040be;})[_0x3e6ac9('0x22')](function(_0x2bb74e){const _0x304acf=_0x3e6ac9;throw new ValidationError(_0x2bb74e[_0x304acf('0x21')]);});})[_0x450995('0x57')](handleEntityNotFound(_0x5ebacd,null))[_0x450995('0x57')](respondWithStatusCode(_0x5ebacd,0xcc))[_0x450995('0x22')](handleError(_0x5ebacd,null));},exports['getSounds']=function(_0x1bac18,_0x1ecc3d){const _0x84ce2c=_0x7643f6;let _0x184d4b={};const _0x95936d={};let _0x58a611,_0x11b2f0;return db[_0x84ce2c('0x9')][_0x84ce2c('0x49')]({'where':{'id':_0x1bac18[_0x84ce2c('0x30')]['id']}})[_0x84ce2c('0x57')](handleEntityNotFound(_0x1ecc3d,null))[_0x84ce2c('0x57')](function(_0x463c0d){const _0x1d0567=_0x84ce2c;if(_0x463c0d)return _0x58a611=_0x463c0d,_0x95936d['model']=_['keys'](db['Sound'][_0x1d0567('0x46')]),_0x95936d['query']=_[_0x1d0567('0x16')](_0x1bac18[_0x1d0567('0x18')]),_0x95936d['filters']=_[_0x1d0567('0xb')](_0x95936d[_0x1d0567('0x2')],_0x95936d['query']),_0x184d4b[_0x1d0567('0x4a')]=_[_0x1d0567('0xb')](_0x95936d[_0x1d0567('0x2')],qs[_0x1d0567('0x27')](_0x1bac18[_0x1d0567('0x18')][_0x1d0567('0x27')])),_0x184d4b[_0x1d0567('0x4a')]=_0x184d4b[_0x1d0567('0x4a')][_0x1d0567('0x3')]?_0x184d4b[_0x1d0567('0x4a')]:_0x95936d[_0x1d0567('0x2')],_0x184d4b[_0x1d0567('0x3a')]=qs[_0x1d0567('0x4e')](_0x1bac18[_0x1d0567('0x18')][_0x1d0567('0x4e')]),_0x184d4b[_0x1d0567('0x2d')]=qs[_0x1d0567('0x15')](_[_0x1d0567('0x54')](_0x1bac18[_0x1d0567('0x18')],_0x95936d['filters'])),_0x1bac18[_0x1d0567('0x18')][_0x1d0567('0x51')]&&(_0x184d4b[_0x1d0567('0x2d')]=_[_0x1d0567('0x50')](_0x184d4b['where'],{[Op['or']]:_[_0x1d0567('0x14')](_0x184d4b[_0x1d0567('0x4a')],function(_0x354cbb){const _0x4bb430=_0x1d0567,_0x102ed5={};return _0x102ed5[_0x354cbb]={[Op[_0x4bb430('0x42')]]:'%'+_0x1bac18[_0x4bb430('0x18')][_0x4bb430('0x51')]+'%'},_0x102ed5;})})),_0x184d4b=_[_0x1d0567('0x50')]({},_0x184d4b,_0x1bac18[_0x1d0567('0xa')]),_0x58a611['getSounds'](_0x184d4b);})[_0x84ce2c('0x57')](function(_0x1eb989){const _0x5a633f=_0x84ce2c;if(_0x1eb989)return _0x11b2f0=_0x1eb989['length'],typeof _0x1bac18[_0x5a633f('0x18')][_0x5a633f('0x8')]===_0x5a633f('0x1b')&&(_0x184d4b[_0x5a633f('0x7')]=qs[_0x5a633f('0x7')](_0x1bac18[_0x5a633f('0x18')][_0x5a633f('0x7')]),_0x184d4b[_0x5a633f('0x28')]=qs['offset'](_0x1bac18[_0x5a633f('0x18')][_0x5a633f('0x28')])),_0x58a611[_0x5a633f('0x1e')](_0x184d4b);})['then'](function(_0xe1cd65){if(_0xe1cd65)return _0xe1cd65?{'count':_0x11b2f0,'rows':_0xe1cd65}:null;})['then'](respondWithResult(_0x1ecc3d,null))[_0x84ce2c('0x22')](handleError(_0x1ecc3d,null));}; \ No newline at end of file diff --git a/server/api/voiceMusicOnHold/voiceMusicOnHold.model.js b/server/api/voiceMusicOnHold/voiceMusicOnHold.model.js index c943399..5ebd34c 100644 --- a/server/api/voiceMusicOnHold/voiceMusicOnHold.model.js +++ b/server/api/voiceMusicOnHold/voiceMusicOnHold.model.js @@ -1 +1 @@ -const a743_0x1a68=['exports','voice_musiconhold','define','VoiceMusicOnHold','./voiceMusicOnHold.attributes'];(function(_0x467ab5,_0x1a68ab){const _0x4912cb=function(_0xcf33b1){while(--_0xcf33b1){_0x467ab5['push'](_0x467ab5['shift']());}};_0x4912cb(++_0x1a68ab);}(a743_0x1a68,0x95));const a743_0x4912=function(_0x467ab5,_0x1a68ab){_0x467ab5=_0x467ab5-0x0;let _0x4912cb=a743_0x1a68[_0x467ab5];return _0x4912cb;};const _0x3a8b64=a743_0x4912;'use strict';const attributes=require(_0x3a8b64('0x0'));module[_0x3a8b64('0x1')]=function(_0xcf33b1){const _0x2e35b0=_0x3a8b64,_0xaad5a1=_0xcf33b1[_0x2e35b0('0x3')](_0x2e35b0('0x4'),attributes,{'tableName':_0x2e35b0('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xaad5a1;}; \ No newline at end of file +const a743_0x491f=['exports','./voiceMusicOnHold.attributes','define'];(function(_0x244850,_0x491f52){const _0x182e62=function(_0x2b99a8){while(--_0x2b99a8){_0x244850['push'](_0x244850['shift']());}};_0x182e62(++_0x491f52);}(a743_0x491f,0x196));const a743_0x182e=function(_0x244850,_0x491f52){_0x244850=_0x244850-0x0;let _0x182e62=a743_0x491f[_0x244850];return _0x182e62;};const _0x4a23fe=a743_0x182e;'use strict';const attributes=require(_0x4a23fe('0x0'));module[_0x4a23fe('0x2')]=function(_0x2b99a8){const _0x465b38=_0x4a23fe,_0x335353=_0x2b99a8[_0x465b38('0x1')]('VoiceMusicOnHold',attributes,{'tableName':'voice_musiconhold','paranoid':![],'indexes':[],'timestamps':!![]});return _0x335353;}; \ No newline at end of file diff --git a/server/api/voicePrefix/index.js b/server/api/voicePrefix/index.js index 2e5158a..5e89094 100644 --- a/server/api/voicePrefix/index.js +++ b/server/api/voicePrefix/index.js @@ -1 +1 @@ -const a744_0x23ac=['getAgents','get','/:id/users','put','Router','delete','../../components/auth/service','exports','/:id','express','index','update','removeAgents','destroy','/describe','post','addAgents','create','describe','isAuthenticated'];(function(_0x2493c6,_0x23ac46){const _0x5b5c4c=function(_0x409991){while(--_0x409991){_0x2493c6['push'](_0x2493c6['shift']());}};_0x5b5c4c(++_0x23ac46);}(a744_0x23ac,0xe8));const a744_0x5b5c=function(_0x2493c6,_0x23ac46){_0x2493c6=_0x2493c6-0x0;let _0x5b5c4c=a744_0x23ac[_0x2493c6];return _0x5b5c4c;};const _0x387f65=a744_0x5b5c;'use strict';const express=require(_0x387f65('0x11')),router=express[_0x387f65('0xc')](),auth=require(_0x387f65('0xe')),controller=require('./voicePrefix.controller');router[_0x387f65('0x9')]('/',auth[_0x387f65('0x7')](),controller[_0x387f65('0x12')]),router[_0x387f65('0x9')](_0x387f65('0x2'),auth['isAuthenticated'](),controller[_0x387f65('0x6')]),router['get']('/:id',auth['isAuthenticated'](),controller['show']),router[_0x387f65('0x9')](_0x387f65('0xa'),auth[_0x387f65('0x7')](),controller[_0x387f65('0x8')]),router['post']('/',auth[_0x387f65('0x7')](),controller[_0x387f65('0x5')]),router[_0x387f65('0x3')]('/:id/users',auth[_0x387f65('0x7')](),controller[_0x387f65('0x4')]),router[_0x387f65('0xb')](_0x387f65('0x10'),auth['isAuthenticated'](),controller[_0x387f65('0x13')]),router[_0x387f65('0xd')](_0x387f65('0x10'),auth['isAuthenticated'](),controller[_0x387f65('0x1')]),router[_0x387f65('0xd')]('/:id/users',auth[_0x387f65('0x7')](),controller[_0x387f65('0x0')]),module[_0x387f65('0xf')]=router; \ No newline at end of file +const a744_0x5e95=['delete','isAuthenticated','../../components/auth/service','getAgents','get','create','index','destroy','/:id','post','exports','addAgents','./voicePrefix.controller','/describe','show','/:id/users','Router'];(function(_0x1070f6,_0x5e9578){const _0x1e7792=function(_0x503066){while(--_0x503066){_0x1070f6['push'](_0x1070f6['shift']());}};_0x1e7792(++_0x5e9578);}(a744_0x5e95,0x1e7));const a744_0x1e77=function(_0x1070f6,_0x5e9578){_0x1070f6=_0x1070f6-0x0;let _0x1e7792=a744_0x5e95[_0x1070f6];return _0x1e7792;};const _0x59fba3=a744_0x1e77;'use strict';const express=require('express'),router=express[_0x59fba3('0x5')](),auth=require(_0x59fba3('0x8')),controller=require(_0x59fba3('0x1'));router[_0x59fba3('0xa')]('/',auth[_0x59fba3('0x7')](),controller[_0x59fba3('0xc')]),router[_0x59fba3('0xa')](_0x59fba3('0x2'),auth[_0x59fba3('0x7')](),controller['describe']),router['get'](_0x59fba3('0xe'),auth[_0x59fba3('0x7')](),controller[_0x59fba3('0x3')]),router[_0x59fba3('0xa')](_0x59fba3('0x4'),auth['isAuthenticated'](),controller[_0x59fba3('0x9')]),router[_0x59fba3('0xf')]('/',auth[_0x59fba3('0x7')](),controller[_0x59fba3('0xb')]),router[_0x59fba3('0xf')](_0x59fba3('0x4'),auth['isAuthenticated'](),controller[_0x59fba3('0x0')]),router['put'](_0x59fba3('0xe'),auth[_0x59fba3('0x7')](),controller['update']),router[_0x59fba3('0x6')](_0x59fba3('0xe'),auth[_0x59fba3('0x7')](),controller[_0x59fba3('0xd')]),router[_0x59fba3('0x6')](_0x59fba3('0x4'),auth['isAuthenticated'](),controller['removeAgents']),module[_0x59fba3('0x10')]=router; \ No newline at end of file diff --git a/server/api/voicePrefix/voicePrefix.attributes.js b/server/api/voicePrefix/voicePrefix.attributes.js index 442a2c8..d8159fc 100644 --- a/server/api/voicePrefix/voicePrefix.attributes.js +++ b/server/api/voicePrefix/voicePrefix.attributes.js @@ -1 +1 @@ -const a745_0x5308=['VIRTUAL','exports','name','STRING','sequelize','getDataValue'];(function(_0x24a756,_0x530891){const _0x44c0b5=function(_0x126d5a){while(--_0x126d5a){_0x24a756['push'](_0x24a756['shift']());}};_0x44c0b5(++_0x530891);}(a745_0x5308,0xf3));const a745_0x44c0=function(_0x24a756,_0x530891){_0x24a756=_0x24a756-0x0;let _0x44c0b5=a745_0x5308[_0x24a756];return _0x44c0b5;};const _0x25dbb2=a745_0x44c0;'use strict';const Sequelize=require(_0x25dbb2('0x1'));module[_0x25dbb2('0x4')]={'name':{'type':Sequelize[_0x25dbb2('0x0')],'allowNull':![],'unique':'name'},'prefix':{'type':Sequelize[_0x25dbb2('0x3')],'get':function(){const _0x322131=_0x25dbb2;return'system-'+this[_0x322131('0x2')](_0x322131('0x5'))+'-';}},'description':{'type':Sequelize['STRING']},'callerIdAll':{'type':Sequelize[_0x25dbb2('0x0')]},'VoiceExtensionId':{'type':Sequelize['INTEGER']}}; \ No newline at end of file +const a745_0x563c=['exports','getDataValue','name','INTEGER','VIRTUAL','system-','STRING','sequelize'];(function(_0xee3412,_0x563c2e){const _0x4d2860=function(_0x21c4ca){while(--_0x21c4ca){_0xee3412['push'](_0xee3412['shift']());}};_0x4d2860(++_0x563c2e);}(a745_0x563c,0x11c));const a745_0x4d28=function(_0xee3412,_0x563c2e){_0xee3412=_0xee3412-0x0;let _0x4d2860=a745_0x563c[_0xee3412];return _0x4d2860;};const _0x39cd54=a745_0x4d28;'use strict';const Sequelize=require(_0x39cd54('0x3'));module[_0x39cd54('0x4')]={'name':{'type':Sequelize[_0x39cd54('0x2')],'allowNull':![],'unique':_0x39cd54('0x6')},'prefix':{'type':Sequelize[_0x39cd54('0x0')],'get':function(){const _0xc50460=_0x39cd54;return _0xc50460('0x1')+this[_0xc50460('0x5')](_0xc50460('0x6'))+'-';}},'description':{'type':Sequelize[_0x39cd54('0x2')]},'callerIdAll':{'type':Sequelize[_0x39cd54('0x2')]},'VoiceExtensionId':{'type':Sequelize[_0x39cd54('0x7')]}}; \ No newline at end of file diff --git a/server/api/voicePrefix/voicePrefix.controller.js b/server/api/voicePrefix/voicePrefix.controller.js index 620ad3d..c841127 100644 --- a/server/api/voicePrefix/voicePrefix.controller.js +++ b/server/api/voicePrefix/voicePrefix.controller.js @@ -1 +1 @@ -const a746_0xb939=['intersection','app','then','undefined','status','user','filter','error','callerIdAll','lodash','../../config/logger','Extensions\x20creation\x20failed','appdata','end','json','Voice\x20Prefix\x20Extension','includeAll','order','Set','isArray','describe','VoiceExtension','exten','role','CDR(prefix)=','prefix','removeAgents','UserProfileResource','goto','fields','sort','api','update','priority','query','attributes','userVoicePrefix:remove','key','transaction','system-','ids','userProfileId','merge','set','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','catch','No\x20callerid\x20available','show','map','name','${EXTEN:','User','addAgents','findOne','userVoicePrefix:save','VoicePrefix','rawAttributes','NoOp','VoiceExtensionId','Content-Range','params','charAt','../../components/parsers/qs','sendStatus','register','./voicePrefix.socket','count','send','omit','push','offset','VoicePrefixId','sequelize','UserProfileSection','emit','from-sip','include','like','get','context','keys','create','getAgents','filters','limit','index','../../rediscache','model','body','Unable\x20to\x20retrieve\x20the\x20current\x20user','../../mysqldb','length','pick','findByPk','type','where','VoicePrefixes','destroy','rows','VIRTUAL','options','nolimit'];(function(_0xb0fde1,_0xb93957){const _0x4a5d5e=function(_0x1b1009){while(--_0x1b1009){_0xb0fde1['push'](_0xb0fde1['shift']());}};_0x4a5d5e(++_0xb93957);}(a746_0xb939,0xb5));const a746_0x4a5d=function(_0xb0fde1,_0xb93957){_0xb0fde1=_0xb0fde1-0x0;let _0x4a5d5e=a746_0xb939[_0xb0fde1];return _0x4a5d5e;};const _0x4f3ff4=a746_0x4a5d;'use strict';const _=require(_0x4f3ff4('0x20')),qs=require(_0x4f3ff4('0x55')),logger=require(_0x4f3ff4('0x21'))(_0x4f3ff4('0x36')),{getSocket}=require(_0x4f3ff4('0x7')),socket=getSocket(),db=require(_0x4f3ff4('0xb'))['db'],{Op}=require(_0x4f3ff4('0x5f'));require(_0x4f3ff4('0x58'))[_0x4f3ff4('0x57')](socket);function respondWithStatusCode(_0x1b1009,_0x23ec85){return _0x23ec85=_0x23ec85||0xcc,function(_0x5721ed){const _0x114a88=a746_0x4a5d;if(_0x5721ed)return _0x1b1009[_0x114a88('0x56')](_0x23ec85);return _0x1b1009['status'](_0x23ec85)[_0x114a88('0x24')]();};}function respondWithResult(_0x249e37,_0x34a7ba){return _0x34a7ba=_0x34a7ba||0xc8,function(_0x2f3022){const _0x275fa3=a746_0x4a5d;if(_0x2f3022)return _0x249e37[_0x275fa3('0x1b')](_0x34a7ba)[_0x275fa3('0x25')](_0x2f3022);};}function respondWithFilteredResult(_0x5dd05a,_0x5f5644){return function(_0x59a3e7){const _0x46067a=a746_0x4a5d;if(_0x59a3e7){const _0x3cbaee=_0x59a3e7[_0x46067a('0x59')],_0x3649cb=_0x5f5644[_0x46067a('0x5d')];let _0x514dc4=_0x5f5644[_0x46067a('0x5d')]+_0x5f5644['limit'],_0x13516d;return _0x514dc4>=_0x3cbaee?(_0x514dc4=_0x3cbaee,_0x13516d=0xc8):_0x13516d=0xce,_0x5dd05a['status'](_0x13516d),_0x5dd05a[_0x46067a('0x42')](_0x46067a('0x52'),_0x3649cb+'-'+_0x514dc4+'/'+_0x3cbaee)[_0x46067a('0x25')](_0x59a3e7);}return null;};}function removeEntity(_0x2eb7fc){return function(_0x46ae58){const _0x15752f=a746_0x4a5d;if(_0x46ae58)return _0x46ae58['destroy']()[_0x15752f('0x19')](function(){const _0x4e38d7=_0x15752f,_0x430106=_0x46ae58[_0x4e38d7('0x65')]({'plain':!![]}),_0x460d98='VoicePrefixes';return db['UserProfileResource'][_0x4e38d7('0x12')]({'where':{'type':_0x460d98,'resourceId':_0x430106['id']}})['then'](function(){return _0x46ae58;});})[_0x15752f('0x19')](function(){const _0x3090c4=_0x15752f;_0x2eb7fc['status'](0xcc)[_0x3090c4('0x24')]();});};}function handleEntityNotFound(_0xf4911b){return function(_0x132798){const _0x5db4ea=a746_0x4a5d;return!_0x132798&&_0xf4911b[_0x5db4ea('0x56')](0x194),_0x132798;};}function handleError(_0x9a3cdd,_0x56efba){return _0x56efba=_0x56efba||0x1f4,function(_0x3d8ba5){const _0x5d906e=a746_0x4a5d;logger[_0x5d906e('0x1e')](_0x3d8ba5['stack']),_0x3d8ba5['name']&&delete _0x3d8ba5[_0x5d906e('0x48')],_0x9a3cdd['status'](_0x56efba)[_0x5d906e('0x5a')](_0x3d8ba5);};}exports[_0x4f3ff4('0x6')]=function(_0x9a10bb,_0x508bea){const _0x1cdc32=_0x4f3ff4;let _0x541f55={};const _0x1b06f6={},_0x4b1ad0={'count':0x0,'rows':[]},_0x51b928=_[_0x1cdc32('0x47')](db[_0x1cdc32('0x4e')][_0x1cdc32('0x4f')],function(_0x5d2c3f){const _0x28d06b=_0x1cdc32;return{'name':_0x5d2c3f['fieldName'],'type':_0x5d2c3f[_0x28d06b('0xf')][_0x28d06b('0x3c')]};});_0x1b06f6[_0x1cdc32('0x8')]=_[_0x1cdc32('0x47')](_0x51b928,'name'),_0x1b06f6[_0x1cdc32('0x39')]=_[_0x1cdc32('0x1')](_0x9a10bb[_0x1cdc32('0x39')]),_0x1b06f6[_0x1cdc32('0x4')]=_[_0x1cdc32('0x17')](_0x1b06f6[_0x1cdc32('0x8')],_0x1b06f6[_0x1cdc32('0x39')]),_0x541f55[_0x1cdc32('0x3a')]=_['intersection'](_0x1b06f6[_0x1cdc32('0x8')],qs[_0x1cdc32('0x34')](_0x9a10bb['query'][_0x1cdc32('0x34')])),_0x541f55[_0x1cdc32('0x3a')]=_0x541f55['attributes'][_0x1cdc32('0xc')]?_0x541f55[_0x1cdc32('0x3a')]:_0x1b06f6['model'];typeof _0x9a10bb['query'][_0x1cdc32('0x16')]===_0x1cdc32('0x1a')&&(_0x541f55[_0x1cdc32('0x5')]=qs[_0x1cdc32('0x5')](_0x9a10bb['query'][_0x1cdc32('0x5')]),_0x541f55[_0x1cdc32('0x5d')]=qs[_0x1cdc32('0x5d')](_0x9a10bb[_0x1cdc32('0x39')]['offset']));_0x541f55[_0x1cdc32('0x28')]=qs[_0x1cdc32('0x35')](_0x9a10bb[_0x1cdc32('0x39')][_0x1cdc32('0x35')]),_0x541f55[_0x1cdc32('0x10')]=qs[_0x1cdc32('0x4')](_[_0x1cdc32('0xd')](_0x9a10bb[_0x1cdc32('0x39')],_0x1b06f6['filters']),_0x51b928);_0x9a10bb[_0x1cdc32('0x39')][_0x1cdc32('0x1d')]&&(_0x541f55[_0x1cdc32('0x10')]=_[_0x1cdc32('0x41')](_0x541f55[_0x1cdc32('0x10')],{[Op['or']]:_[_0x1cdc32('0x47')](_0x51b928,function(_0x4583de){const _0x392c21=_0x1cdc32;if(_0x4583de[_0x392c21('0xf')]!==_0x392c21('0x14')){const _0xe5cf1c={};return _0xe5cf1c[_0x4583de['name']]={[Op[_0x392c21('0x64')]]:'%'+_0x9a10bb[_0x392c21('0x39')]['filter']+'%'},_0xe5cf1c;}})}));_0x541f55=_[_0x1cdc32('0x41')]({},_0x541f55,_0x9a10bb['options']);const _0x549ba3={'where':_0x541f55[_0x1cdc32('0x10')]};return db[_0x1cdc32('0x4e')][_0x1cdc32('0x59')](_0x549ba3)[_0x1cdc32('0x19')](function(_0x4c003f){const _0x31f65b=_0x1cdc32;return _0x4b1ad0[_0x31f65b('0x59')]=_0x4c003f,_0x9a10bb['query'][_0x31f65b('0x27')]&&(_0x541f55[_0x31f65b('0x63')]=[{'all':!![]}]),db[_0x31f65b('0x4e')]['findAll'](_0x541f55);})[_0x1cdc32('0x19')](function(_0x3b4136){const _0x9970a5=_0x1cdc32;return _0x4b1ad0[_0x9970a5('0x13')]=_0x3b4136,_0x4b1ad0;})[_0x1cdc32('0x19')](respondWithFilteredResult(_0x508bea,_0x541f55))[_0x1cdc32('0x44')](handleError(_0x508bea,null));},exports[_0x4f3ff4('0x46')]=function(_0x2a155c,_0x4e7c91){const _0x11eb40=_0x4f3ff4;let _0x59f674={'raw':![],'where':{'id':_0x2a155c[_0x11eb40('0x53')]['id']}};const _0x489217={};return _0x489217[_0x11eb40('0x8')]=_[_0x11eb40('0x1')](db[_0x11eb40('0x4e')][_0x11eb40('0x4f')]),_0x489217[_0x11eb40('0x39')]=_[_0x11eb40('0x1')](_0x2a155c[_0x11eb40('0x39')]),_0x489217[_0x11eb40('0x4')]=_['intersection'](_0x489217[_0x11eb40('0x8')],_0x489217[_0x11eb40('0x39')]),_0x59f674['attributes']=_[_0x11eb40('0x17')](_0x489217[_0x11eb40('0x8')],qs[_0x11eb40('0x34')](_0x2a155c['query']['fields'])),_0x59f674[_0x11eb40('0x3a')]=_0x59f674[_0x11eb40('0x3a')][_0x11eb40('0xc')]?_0x59f674['attributes']:_0x489217[_0x11eb40('0x8')],_0x2a155c[_0x11eb40('0x39')]['includeAll']&&(_0x59f674['include']=[{'all':!![]}]),_0x59f674=_['merge']({},_0x59f674,_0x2a155c[_0x11eb40('0x15')]),db['VoicePrefix'][_0x11eb40('0x4c')](_0x59f674)[_0x11eb40('0x19')](handleEntityNotFound(_0x4e7c91,null))[_0x11eb40('0x19')](respondWithResult(_0x4e7c91,null))['catch'](handleError(_0x4e7c91,null));},exports[_0x4f3ff4('0x12')]=function(_0xc8e791,_0x12f9db){const _0x3436ca=_0x4f3ff4;return db[_0x3436ca('0x4e')][_0x3436ca('0x4c')]({'where':{'id':_0xc8e791['params']['id']}})['then'](handleEntityNotFound(_0x12f9db,null))['then'](removeEntity(_0x12f9db,null))[_0x3436ca('0x44')](handleError(_0x12f9db,null));},exports['describe']=function(_0x3539d5,_0xcf9b40){const _0x443676=_0x4f3ff4;return db[_0x443676('0x4e')][_0x443676('0x2b')]()[_0x443676('0x19')](respondWithResult(_0xcf9b40,null))[_0x443676('0x44')](handleError(_0xcf9b40,null));},exports['create']=function(_0x7386d9,_0x1cd068){const _0x36eef7=_0x4f3ff4;let _0x533563;return db[_0x36eef7('0x5f')]['transaction'](function(_0x1a8755){const _0x230fd5=_0x36eef7;return db[_0x230fd5('0x4e')][_0x230fd5('0x2')](_0x7386d9['body'],{'transaction':_0x1a8755})[_0x230fd5('0x19')](function(_0x15f0ce){const _0x312da6=_0x230fd5;return _0x533563=_0x15f0ce[_0x312da6('0x65')]({'plain':!![]}),db[_0x312da6('0x2c')][_0x312da6('0x4c')]({'where':{'id':_0x533563[_0x312da6('0x51')]},'raw':!![]})[_0x312da6('0x19')](function(_0x27ce67){return createVoicePrefixExtensions(_0x533563,_0x27ce67,_0x1a8755);});});})[_0x36eef7('0x19')](function(){const _0x259d9a=_0x36eef7,_0x325fc5=_0x7386d9[_0x259d9a('0x1c')]['get']({'plain':!![]});if(!_0x325fc5)throw new Error(_0x259d9a('0xa'));if(_0x325fc5[_0x259d9a('0x2e')]===_0x259d9a('0x1c')){const _0x2dd75f=_0x533563;return db[_0x259d9a('0x60')][_0x259d9a('0x4c')]({'where':{'name':_0x259d9a('0x11'),'userProfileId':_0x325fc5[_0x259d9a('0x40')]},'raw':!![]})['then'](function(_0x5cd0fb){const _0x871fcb=_0x259d9a;return _0x5cd0fb&&_0x5cd0fb['autoAssociation']===0x0?db[_0x871fcb('0x32')]['create']({'name':_0x2dd75f[_0x871fcb('0x48')],'resourceId':_0x2dd75f['id'],'type':_0x5cd0fb[_0x871fcb('0x48')],'sectionId':_0x5cd0fb['id']},{})[_0x871fcb('0x19')](function(){return _0x533563;}):_0x533563;})[_0x259d9a('0x44')](function(_0x5d7d67){const _0x34037f=_0x259d9a;logger[_0x34037f('0x1e')](_0x34037f('0x43'),_0x5d7d67);throw _0x5d7d67;});}return _0x533563;})[_0x36eef7('0x19')](respondWithResult(_0x1cd068,null))[_0x36eef7('0x44')](handleError(_0x1cd068,null));};function Extension(_0x4a55d1,_0x95aff5,_0x53fff9,_0xcad56b){const _0x4be111=_0x4f3ff4;this[_0x4be111('0x0')]=_0x4be111('0x62'),this[_0x4be111('0x2d')]=_0x4a55d1,this[_0x4be111('0x18')]=_0x53fff9,this[_0x4be111('0xf')]='system',this['description']=_0x4be111('0x26'),this[_0x4be111('0x38')]=_0x95aff5,this[_0x4be111('0x23')]=_0xcad56b;}function createVoicePrefixExtensions(_0x1cda5c,_0x559463,_0x4f98b4){return new Promise(function(_0x1bbbc7,_0x41c875){const _0x4a6281=a746_0x4a5d,_0x4c0d2a=new Extension(formatPrefixName(_0x1cda5c[_0x4a6281('0x30')]),0x1,_0x4a6281('0x50'),'Voice\x20Prefix');return _0x4c0d2a[_0x4a6281('0x5e')]=_0x1cda5c['id'],db[_0x4a6281('0x2c')][_0x4a6281('0x2')](_0x4c0d2a,{'transaction':_0x4f98b4})[_0x4a6281('0x19')](function(_0x2b5d34){const _0x2239bf=_0x4a6281,_0x593713=_0x2b5d34[_0x2239bf('0x65')]({'plain':!![]}),_0x3fe0d2=_[_0x2239bf('0x47')](addVoicePrefixExtensions(_0x1cda5c,_0x559463),function(_0x5d32c1){const _0x4b9d13=_0x2239bf;return _0x5d32c1[_0x4b9d13('0x51')]=_0x593713['id'],_0x5d32c1[_0x4b9d13('0x5e')]=_0x1cda5c['id'],_0x5d32c1;});return db[_0x2239bf('0x2c')]['bulkCreate'](_0x3fe0d2,{'transaction':_0x4f98b4})[_0x2239bf('0x19')](function(_0x16e949){const _0xb3f387=_0x2239bf;return!_0x16e949?_0x41c875(_0xb3f387('0x22')):_0x1bbbc7(_0x16e949);})[_0x2239bf('0x44')](function(_0x4592e7){return _0x41c875(_0x4592e7);});});});}function addVoicePrefixExtensions(_0x55e99e,_0x283e57){const _0x5df407=_0x4f3ff4,_0x3b1d64=[],_0x2201d9=formatPrefixName(_0x55e99e['prefix']);return _0x3b1d64[_0x5df407('0x5c')](new Extension(_0x2201d9,0x2,_0x5df407('0x29'),_0x5df407('0x2f')+_0x55e99e[_0x5df407('0x48')])),_0x55e99e[_0x5df407('0x1f')]?_0x3b1d64['push'](new Extension(_0x2201d9,0x3,_0x5df407('0x29'),'PREFIX-CALLERIDALL='+_0x55e99e[_0x5df407('0x1f')])):_0x3b1d64['push'](new Extension(_0x2201d9,0x3,_0x5df407('0x50'),_0x5df407('0x45'))),_0x3b1d64['push'](new Extension(_0x2201d9,0x4,_0x5df407('0x33'),_0x283e57['context']+','+_0x5df407('0x49')+(0x8+_0x55e99e[_0x5df407('0x48')][_0x5df407('0xc')])+'}'+','+0x1)),_0x3b1d64;}function formatPrefixName(_0x5849a2){const _0x3aeb70=_0x4f3ff4;let _0x56cf00='_';for(let _0x149fe0=0x0;_0x149fe0<_0x5849a2[_0x3aeb70('0xc')];_0x149fe0++){_0x5849a2[_0x3aeb70('0x54')](_0x149fe0)=='-'?_0x56cf00+=_0x5849a2[_0x3aeb70('0x54')](_0x149fe0):_0x56cf00+='['+_0x5849a2[_0x3aeb70('0x54')](_0x149fe0)+']';}return _0x56cf00+='.',_0x56cf00;}exports[_0x4f3ff4('0x37')]=function(_0x3c7159,_0xc6fd37){const _0xf724cf=_0x4f3ff4,_0x5777b4=_0x3c7159[_0xf724cf('0x9')];return _0x5777b4['prefix']=_0xf724cf('0x3e')+_0x5777b4['name']+'-',db[_0xf724cf('0x5f')][_0xf724cf('0x3d')](function(_0x54850b){const _0x1aa252=_0xf724cf;return db['VoicePrefix'][_0x1aa252('0x37')](_0x5777b4,{'where':{'id':_0x5777b4['id']},'transaction':_0x54850b})['then'](function(){const _0x409c73=_0x1aa252;return db['VoiceExtension'][_0x409c73('0x12')]({'where':{'VoicePrefixId':_0x5777b4['id']},'transaction':_0x54850b})['then'](function(){const _0x3690ee=_0x409c73;return db[_0x3690ee('0x2c')][_0x3690ee('0x4c')]({'where':{'id':_0x5777b4[_0x3690ee('0x51')]},'raw':!![]})[_0x3690ee('0x19')](function(_0x18e9d5){return createVoicePrefixExtensions(_0x5777b4,_0x18e9d5,_0x54850b);});});});})[_0xf724cf('0x19')](function(){const _0x3a5640=_0xf724cf;return db[_0x3a5640('0x4e')][_0x3a5640('0xe')](_0x5777b4['id']);})['then'](respondWithResult(_0xc6fd37,null))[_0xf724cf('0x44')](handleError(_0xc6fd37,null));},exports[_0x4f3ff4('0x4b')]=function(_0xe4289c,_0x43a173){const _0x2585c9=_0x4f3ff4;return db[_0x2585c9('0x4e')][_0x2585c9('0x4c')]({'where':{'id':_0xe4289c[_0x2585c9('0x53')]['id']}})[_0x2585c9('0x19')](function(_0x2b4600){const _0x16e50b=_0x2585c9;if(_0x2b4600)return _0x2b4600[_0x16e50b('0x4b')](_0xe4289c[_0x16e50b('0x9')][_0x16e50b('0x3f')],{'through':_[_0x16e50b('0x5b')](_0xe4289c['body'],[_0x16e50b('0x3f'),'id'])})[_0x16e50b('0x19')](function(_0x58f7ed){const _0x1ff9ec=_0x16e50b;for(let _0x3b5d7a=0x0;_0x3b5d7a<_0xe4289c[_0x1ff9ec('0x9')]['ids'][_0x1ff9ec('0xc')];_0x3b5d7a+=0x1){socket[_0x1ff9ec('0x61')](_0x1ff9ec('0x4d'),{'UserId':_0xe4289c[_0x1ff9ec('0x9')][_0x1ff9ec('0x3f')][_0x3b5d7a],'VoicePrefixId':_0xe4289c[_0x1ff9ec('0x53')]['id']});}return _0x58f7ed;});})[_0x2585c9('0x19')](respondWithResult(_0x43a173,null))[_0x2585c9('0x44')](handleError(_0x43a173,null));},exports['removeAgents']=function(_0x2cf095,_0x4975b0){const _0x4391bc=_0x4f3ff4;return db[_0x4391bc('0x4e')]['findOne']({'where':{'id':_0x2cf095[_0x4391bc('0x53')]['id']}})[_0x4391bc('0x19')](handleEntityNotFound(_0x4975b0,null))[_0x4391bc('0x19')](function(_0x3a90ff){const _0x3aab8a=_0x4391bc;if(_0x3a90ff)return _0x3a90ff[_0x3aab8a('0x31')](_0x2cf095[_0x3aab8a('0x39')][_0x3aab8a('0x3f')])['then'](function(){const _0x393ff5=_0x3aab8a;if(_[_0x393ff5('0x2a')](_0x2cf095[_0x393ff5('0x39')][_0x393ff5('0x3f')]))for(let _0x39ba5e=0x0;_0x39ba5e<_0x2cf095[_0x393ff5('0x39')]['ids'][_0x393ff5('0xc')];_0x39ba5e+=0x1){socket[_0x393ff5('0x61')](_0x393ff5('0x3b'),{'UserId':Number(_0x2cf095[_0x393ff5('0x39')]['ids'][_0x39ba5e]),'VoicePrefixId':Number(_0x2cf095['params']['id'])});}else socket[_0x393ff5('0x61')](_0x393ff5('0x3b'),{'UserId':Number(_0x2cf095['query'][_0x393ff5('0x3f')]),'VoicePrefixId':Number(_0x2cf095[_0x393ff5('0x53')]['id'])});});})[_0x4391bc('0x19')](respondWithStatusCode(_0x4975b0,null))[_0x4391bc('0x44')](handleError(_0x4975b0,null));},exports['getAgents']=function(_0x4c30bc,_0x1f2ad2){const _0x9d31e2=_0x4f3ff4;let _0x3786f1={};const _0x52b0fd={};let _0x4acce3,_0x358e7a;return db['VoicePrefix'][_0x9d31e2('0x4c')]({'where':{'id':_0x4c30bc[_0x9d31e2('0x53')]['id']}})[_0x9d31e2('0x19')](handleEntityNotFound(_0x1f2ad2,null))['then'](function(_0x404158){const _0x35224b=_0x9d31e2;if(_0x404158)return _0x4acce3=_0x404158,_0x52b0fd[_0x35224b('0x8')]=_[_0x35224b('0x1')](db[_0x35224b('0x4a')][_0x35224b('0x4f')]),_0x52b0fd[_0x35224b('0x39')]=_[_0x35224b('0x1')](_0x4c30bc[_0x35224b('0x39')]),_0x52b0fd[_0x35224b('0x4')]=_[_0x35224b('0x17')](_0x52b0fd[_0x35224b('0x8')],_0x52b0fd['query']),_0x3786f1[_0x35224b('0x3a')]=_[_0x35224b('0x17')](_0x52b0fd['model'],qs[_0x35224b('0x34')](_0x4c30bc['query'][_0x35224b('0x34')])),_0x3786f1['attributes']=_0x3786f1[_0x35224b('0x3a')][_0x35224b('0xc')]?_0x3786f1['attributes']:_0x52b0fd[_0x35224b('0x8')],_0x3786f1[_0x35224b('0x28')]=qs[_0x35224b('0x35')](_0x4c30bc[_0x35224b('0x39')][_0x35224b('0x35')]),_0x3786f1[_0x35224b('0x10')]=qs[_0x35224b('0x4')](_['pick'](_0x4c30bc['query'],_0x52b0fd[_0x35224b('0x4')])),_0x4c30bc[_0x35224b('0x39')][_0x35224b('0x1d')]&&(_0x3786f1['where']=_[_0x35224b('0x41')](_0x3786f1['where'],{[Op['or']]:_[_0x35224b('0x47')](_0x3786f1[_0x35224b('0x3a')],function(_0x48a53a){const _0x2770db=_0x35224b,_0x31b3c4={};return _0x31b3c4[_0x48a53a]={[Op[_0x2770db('0x64')]]:'%'+_0x4c30bc['query'][_0x2770db('0x1d')]+'%'},_0x31b3c4;})})),_0x3786f1=_[_0x35224b('0x41')]({},_0x3786f1,_0x4c30bc[_0x35224b('0x15')]),_0x4acce3[_0x35224b('0x3')](_0x3786f1);})[_0x9d31e2('0x19')](function(_0x37ce0f){const _0x4a6d99=_0x9d31e2;if(_0x37ce0f)return _0x358e7a=_0x37ce0f[_0x4a6d99('0xc')],typeof _0x4c30bc['query'][_0x4a6d99('0x16')]===_0x4a6d99('0x1a')&&(_0x3786f1[_0x4a6d99('0x5')]=qs[_0x4a6d99('0x5')](_0x4c30bc[_0x4a6d99('0x39')][_0x4a6d99('0x5')]),_0x3786f1[_0x4a6d99('0x5d')]=qs['offset'](_0x4c30bc[_0x4a6d99('0x39')][_0x4a6d99('0x5d')])),_0x4acce3[_0x4a6d99('0x3')](_0x3786f1);})['then'](function(_0x482332){if(_0x482332)return _0x482332?{'count':_0x358e7a,'rows':_0x482332}:null;})[_0x9d31e2('0x19')](respondWithResult(_0x1f2ad2,null))[_0x9d31e2('0x44')](handleError(_0x1f2ad2,null));}; \ No newline at end of file +const a746_0x3369=['context','type','includeAll','Voice\x20Prefix','charAt','VoiceExtension','addAgents','fieldName','Voice\x20Prefix\x20Extension','rawAttributes','set','appdata','No\x20callerid\x20available','fields','autoAssociation','callerIdAll','like','lodash','from-sip','userVoicePrefix:remove','ids','stack','get','include','priority','pick','nolimit','options','count','sort','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','then','api','query','key','NoOp','merge','end','removeAgents','isArray','catch','where','User','UserProfileSection','sendStatus','create','../../components/parsers/qs','getAgents','../../mysqldb','../../rediscache','VoicePrefixId','role','system','push','attributes','body','transaction','keys','describe','app','offset','status','intersection','VIRTUAL','order','model','limit','userVoicePrefix:save','../../config/logger','Set','./voicePrefix.socket','json','Extensions\x20creation\x20failed','user','send','${EXTEN:','prefix','index','description','params','VoicePrefixes','Unable\x20to\x20retrieve\x20the\x20current\x20user','update','goto','map','name','length','findOne','UserProfileResource','show','PREFIX-CALLERIDALL=','VoiceExtensionId','bulkCreate','VoicePrefix','sequelize','destroy','register','emit','filter','filters'];(function(_0x111b88,_0x3369eb){const _0x323898=function(_0x156c5d){while(--_0x156c5d){_0x111b88['push'](_0x111b88['shift']());}};_0x323898(++_0x3369eb);}(a746_0x3369,0x171));const a746_0x3238=function(_0x111b88,_0x3369eb){_0x111b88=_0x111b88-0x0;let _0x323898=a746_0x3369[_0x111b88];return _0x323898;};const _0x3b3ced=a746_0x3238;'use strict';const _=require(_0x3b3ced('0x30')),qs=require(_0x3b3ced('0x4d')),logger=require(_0x3b3ced('0x63'))(_0x3b3ced('0x3f')),{getSocket}=require(_0x3b3ced('0x50')),socket=getSocket(),db=require(_0x3b3ced('0x4f'))['db'],{Op}=require(_0x3b3ced('0x19'));require(_0x3b3ced('0x1'))[_0x3b3ced('0x1b')](socket);function respondWithStatusCode(_0x156c5d,_0x40c758){return _0x40c758=_0x40c758||0xcc,function(_0x4e51a3){const _0x39f88e=a746_0x3238;if(_0x4e51a3)return _0x156c5d[_0x39f88e('0x4b')](_0x40c758);return _0x156c5d[_0x39f88e('0x5c')](_0x40c758)[_0x39f88e('0x44')]();};}function respondWithResult(_0x5609e9,_0x1e3dfb){return _0x1e3dfb=_0x1e3dfb||0xc8,function(_0x1f117b){const _0x474646=a746_0x3238;if(_0x1f117b)return _0x5609e9['status'](_0x1e3dfb)[_0x474646('0x2')](_0x1f117b);};}function respondWithFilteredResult(_0x49a639,_0x3f8827){return function(_0x512d6f){const _0x248d81=a746_0x3238;if(_0x512d6f){const _0x460762=_0x512d6f['count'],_0x1bc5e9=_0x3f8827[_0x248d81('0x5b')];let _0x58e4a5=_0x3f8827['offset']+_0x3f8827[_0x248d81('0x61')],_0x4a1628;return _0x58e4a5>=_0x460762?(_0x58e4a5=_0x460762,_0x4a1628=0xc8):_0x4a1628=0xce,_0x49a639['status'](_0x4a1628),_0x49a639[_0x248d81('0x29')]('Content-Range',_0x1bc5e9+'-'+_0x58e4a5+'/'+_0x460762)[_0x248d81('0x2')](_0x512d6f);}return null;};}function removeEntity(_0x389e42){return function(_0x529610){const _0x2dbc61=a746_0x3238;if(_0x529610)return _0x529610[_0x2dbc61('0x1a')]()[_0x2dbc61('0x3e')](function(){const _0x56d19f=_0x2dbc61,_0x1ad022=_0x529610[_0x56d19f('0x35')]({'plain':!![]}),_0x451cd0=_0x56d19f('0xb');return db[_0x56d19f('0x13')][_0x56d19f('0x1a')]({'where':{'type':_0x451cd0,'resourceId':_0x1ad022['id']}})[_0x56d19f('0x3e')](function(){return _0x529610;});})[_0x2dbc61('0x3e')](function(){const _0x55ca8d=_0x2dbc61;_0x389e42[_0x55ca8d('0x5c')](0xcc)[_0x55ca8d('0x44')]();});};}function handleEntityNotFound(_0x1e28db){return function(_0x5c77f8){const _0x716334=a746_0x3238;return!_0x5c77f8&&_0x1e28db[_0x716334('0x4b')](0x194),_0x5c77f8;};}function handleError(_0x27d537,_0x3fb05b){return _0x3fb05b=_0x3fb05b||0x1f4,function(_0xe8adb2){const _0xa3ed34=a746_0x3238;logger['error'](_0xe8adb2[_0xa3ed34('0x34')]),_0xe8adb2['name']&&delete _0xe8adb2['name'],_0x27d537[_0xa3ed34('0x5c')](_0x3fb05b)[_0xa3ed34('0x5')](_0xe8adb2);};}exports[_0x3b3ced('0x8')]=function(_0x32bacf,_0x505fa5){const _0xe5185f=_0x3b3ced;let _0x37308b={};const _0x4f28f8={},_0x3dc456={'count':0x0,'rows':[]},_0x27546e=_['map'](db['VoicePrefix'][_0xe5185f('0x28')],function(_0x5614a3){const _0x160e61=_0xe5185f;return{'name':_0x5614a3[_0x160e61('0x26')],'type':_0x5614a3[_0x160e61('0x20')][_0x160e61('0x41')]};});_0x4f28f8[_0xe5185f('0x60')]=_[_0xe5185f('0xf')](_0x27546e,_0xe5185f('0x10')),_0x4f28f8[_0xe5185f('0x40')]=_[_0xe5185f('0x58')](_0x32bacf[_0xe5185f('0x40')]),_0x4f28f8[_0xe5185f('0x1e')]=_['intersection'](_0x4f28f8[_0xe5185f('0x60')],_0x4f28f8[_0xe5185f('0x40')]),_0x37308b[_0xe5185f('0x55')]=_[_0xe5185f('0x5d')](_0x4f28f8[_0xe5185f('0x60')],qs[_0xe5185f('0x2c')](_0x32bacf[_0xe5185f('0x40')][_0xe5185f('0x2c')])),_0x37308b['attributes']=_0x37308b['attributes'][_0xe5185f('0x11')]?_0x37308b['attributes']:_0x4f28f8[_0xe5185f('0x60')];typeof _0x32bacf['query'][_0xe5185f('0x39')]==='undefined'&&(_0x37308b[_0xe5185f('0x61')]=qs['limit'](_0x32bacf[_0xe5185f('0x40')][_0xe5185f('0x61')]),_0x37308b[_0xe5185f('0x5b')]=qs[_0xe5185f('0x5b')](_0x32bacf[_0xe5185f('0x40')][_0xe5185f('0x5b')]));_0x37308b[_0xe5185f('0x5f')]=qs['sort'](_0x32bacf[_0xe5185f('0x40')]['sort']),_0x37308b['where']=qs[_0xe5185f('0x1e')](_['pick'](_0x32bacf['query'],_0x4f28f8['filters']),_0x27546e);_0x32bacf[_0xe5185f('0x40')][_0xe5185f('0x1d')]&&(_0x37308b[_0xe5185f('0x48')]=_[_0xe5185f('0x43')](_0x37308b[_0xe5185f('0x48')],{[Op['or']]:_[_0xe5185f('0xf')](_0x27546e,function(_0x1532ec){const _0x45fa4c=_0xe5185f;if(_0x1532ec['type']!==_0x45fa4c('0x5e')){const _0x2c7f2e={};return _0x2c7f2e[_0x1532ec[_0x45fa4c('0x10')]]={[Op[_0x45fa4c('0x2f')]]:'%'+_0x32bacf[_0x45fa4c('0x40')][_0x45fa4c('0x1d')]+'%'},_0x2c7f2e;}})}));_0x37308b=_['merge']({},_0x37308b,_0x32bacf[_0xe5185f('0x3a')]);const _0xfacf0b={'where':_0x37308b['where']};return db[_0xe5185f('0x18')]['count'](_0xfacf0b)['then'](function(_0x4bc96f){const _0x51fef3=_0xe5185f;return _0x3dc456[_0x51fef3('0x3b')]=_0x4bc96f,_0x32bacf['query'][_0x51fef3('0x21')]&&(_0x37308b[_0x51fef3('0x36')]=[{'all':!![]}]),db[_0x51fef3('0x18')]['findAll'](_0x37308b);})['then'](function(_0x4ed1ae){return _0x3dc456['rows']=_0x4ed1ae,_0x3dc456;})[_0xe5185f('0x3e')](respondWithFilteredResult(_0x505fa5,_0x37308b))['catch'](handleError(_0x505fa5,null));},exports[_0x3b3ced('0x14')]=function(_0x4d3597,_0x317f39){const _0x3e7ff6=_0x3b3ced;let _0x52dd12={'raw':![],'where':{'id':_0x4d3597['params']['id']}};const _0x14a51f={};return _0x14a51f[_0x3e7ff6('0x60')]=_[_0x3e7ff6('0x58')](db[_0x3e7ff6('0x18')]['rawAttributes']),_0x14a51f[_0x3e7ff6('0x40')]=_['keys'](_0x4d3597[_0x3e7ff6('0x40')]),_0x14a51f[_0x3e7ff6('0x1e')]=_['intersection'](_0x14a51f[_0x3e7ff6('0x60')],_0x14a51f[_0x3e7ff6('0x40')]),_0x52dd12['attributes']=_[_0x3e7ff6('0x5d')](_0x14a51f[_0x3e7ff6('0x60')],qs[_0x3e7ff6('0x2c')](_0x4d3597['query']['fields'])),_0x52dd12[_0x3e7ff6('0x55')]=_0x52dd12[_0x3e7ff6('0x55')][_0x3e7ff6('0x11')]?_0x52dd12[_0x3e7ff6('0x55')]:_0x14a51f[_0x3e7ff6('0x60')],_0x4d3597['query'][_0x3e7ff6('0x21')]&&(_0x52dd12[_0x3e7ff6('0x36')]=[{'all':!![]}]),_0x52dd12=_['merge']({},_0x52dd12,_0x4d3597[_0x3e7ff6('0x3a')]),db[_0x3e7ff6('0x18')]['findOne'](_0x52dd12)[_0x3e7ff6('0x3e')](handleEntityNotFound(_0x317f39,null))[_0x3e7ff6('0x3e')](respondWithResult(_0x317f39,null))[_0x3e7ff6('0x47')](handleError(_0x317f39,null));},exports[_0x3b3ced('0x1a')]=function(_0x185892,_0x3a004a){const _0x2defca=_0x3b3ced;return db[_0x2defca('0x18')][_0x2defca('0x12')]({'where':{'id':_0x185892[_0x2defca('0xa')]['id']}})['then'](handleEntityNotFound(_0x3a004a,null))['then'](removeEntity(_0x3a004a,null))[_0x2defca('0x47')](handleError(_0x3a004a,null));},exports[_0x3b3ced('0x59')]=function(_0x22f4a8,_0x51cc37){const _0x9cb792=_0x3b3ced;return db[_0x9cb792('0x18')]['describe']()['then'](respondWithResult(_0x51cc37,null))[_0x9cb792('0x47')](handleError(_0x51cc37,null));},exports[_0x3b3ced('0x4c')]=function(_0x1ecf7a,_0x2f0ac4){const _0xa5bc50=_0x3b3ced;let _0x57b8ee;return db[_0xa5bc50('0x19')][_0xa5bc50('0x57')](function(_0x257d92){const _0x11c5fc=_0xa5bc50;return db[_0x11c5fc('0x18')]['create'](_0x1ecf7a['body'],{'transaction':_0x257d92})[_0x11c5fc('0x3e')](function(_0x13b039){const _0x39bd81=_0x11c5fc;return _0x57b8ee=_0x13b039[_0x39bd81('0x35')]({'plain':!![]}),db[_0x39bd81('0x24')][_0x39bd81('0x12')]({'where':{'id':_0x57b8ee[_0x39bd81('0x16')]},'raw':!![]})[_0x39bd81('0x3e')](function(_0x4c425e){return createVoicePrefixExtensions(_0x57b8ee,_0x4c425e,_0x257d92);});});})[_0xa5bc50('0x3e')](function(){const _0x3fc171=_0xa5bc50,_0x450ef1=_0x1ecf7a['user'][_0x3fc171('0x35')]({'plain':!![]});if(!_0x450ef1)throw new Error(_0x3fc171('0xc'));if(_0x450ef1[_0x3fc171('0x52')]===_0x3fc171('0x4')){const _0x5427b0=_0x57b8ee;return db[_0x3fc171('0x4a')][_0x3fc171('0x12')]({'where':{'name':_0x3fc171('0xb'),'userProfileId':_0x450ef1['userProfileId']},'raw':!![]})[_0x3fc171('0x3e')](function(_0x5d6efe){const _0x171148=_0x3fc171;return _0x5d6efe&&_0x5d6efe[_0x171148('0x2d')]===0x0?db[_0x171148('0x13')][_0x171148('0x4c')]({'name':_0x5427b0[_0x171148('0x10')],'resourceId':_0x5427b0['id'],'type':_0x5d6efe[_0x171148('0x10')],'sectionId':_0x5d6efe['id']},{})[_0x171148('0x3e')](function(){return _0x57b8ee;}):_0x57b8ee;})[_0x3fc171('0x47')](function(_0x346367){const _0x96e9be=_0x3fc171;logger['error'](_0x96e9be('0x3d'),_0x346367);throw _0x346367;});}return _0x57b8ee;})[_0xa5bc50('0x3e')](respondWithResult(_0x2f0ac4,null))[_0xa5bc50('0x47')](handleError(_0x2f0ac4,null));};function Extension(_0xed7370,_0x4b5e32,_0x19cf82,_0x422a2f){const _0x16a12a=_0x3b3ced;this['context']=_0x16a12a('0x31'),this['exten']=_0xed7370,this[_0x16a12a('0x5a')]=_0x19cf82,this[_0x16a12a('0x20')]=_0x16a12a('0x53'),this[_0x16a12a('0x9')]=_0x16a12a('0x27'),this[_0x16a12a('0x37')]=_0x4b5e32,this[_0x16a12a('0x2a')]=_0x422a2f;}function createVoicePrefixExtensions(_0x8ce85f,_0x588ff5,_0x4e2492){return new Promise(function(_0x2d7335,_0x1e6cec){const _0x4e6eeb=a746_0x3238,_0x23f600=new Extension(formatPrefixName(_0x8ce85f[_0x4e6eeb('0x7')]),0x1,_0x4e6eeb('0x42'),_0x4e6eeb('0x22'));return _0x23f600[_0x4e6eeb('0x51')]=_0x8ce85f['id'],db[_0x4e6eeb('0x24')][_0x4e6eeb('0x4c')](_0x23f600,{'transaction':_0x4e2492})[_0x4e6eeb('0x3e')](function(_0x3a6625){const _0x46a20a=_0x4e6eeb,_0x41386d=_0x3a6625[_0x46a20a('0x35')]({'plain':!![]}),_0x2e699f=_[_0x46a20a('0xf')](addVoicePrefixExtensions(_0x8ce85f,_0x588ff5),function(_0x308751){const _0x25d8ef=_0x46a20a;return _0x308751[_0x25d8ef('0x16')]=_0x41386d['id'],_0x308751['VoicePrefixId']=_0x8ce85f['id'],_0x308751;});return db[_0x46a20a('0x24')][_0x46a20a('0x17')](_0x2e699f,{'transaction':_0x4e2492})[_0x46a20a('0x3e')](function(_0x33a326){const _0x4fcfc0=_0x46a20a;return!_0x33a326?_0x1e6cec(_0x4fcfc0('0x3')):_0x2d7335(_0x33a326);})[_0x46a20a('0x47')](function(_0x901570){return _0x1e6cec(_0x901570);});});});}function addVoicePrefixExtensions(_0x11e156,_0x5156d6){const _0x5f291c=_0x3b3ced,_0x426a53=[],_0x56971e=formatPrefixName(_0x11e156[_0x5f291c('0x7')]);return _0x426a53['push'](new Extension(_0x56971e,0x2,'Set','CDR(prefix)='+_0x11e156[_0x5f291c('0x10')])),_0x11e156['callerIdAll']?_0x426a53[_0x5f291c('0x54')](new Extension(_0x56971e,0x3,_0x5f291c('0x0'),_0x5f291c('0x15')+_0x11e156[_0x5f291c('0x2e')])):_0x426a53[_0x5f291c('0x54')](new Extension(_0x56971e,0x3,_0x5f291c('0x42'),_0x5f291c('0x2b'))),_0x426a53[_0x5f291c('0x54')](new Extension(_0x56971e,0x4,_0x5f291c('0xe'),_0x5156d6[_0x5f291c('0x1f')]+','+_0x5f291c('0x6')+(0x8+_0x11e156[_0x5f291c('0x10')][_0x5f291c('0x11')])+'}'+','+0x1)),_0x426a53;}function formatPrefixName(_0x28c0b2){const _0x4d9234=_0x3b3ced;let _0x47dab0='_';for(let _0x5bd8c0=0x0;_0x5bd8c0<_0x28c0b2[_0x4d9234('0x11')];_0x5bd8c0++){_0x28c0b2[_0x4d9234('0x23')](_0x5bd8c0)=='-'?_0x47dab0+=_0x28c0b2[_0x4d9234('0x23')](_0x5bd8c0):_0x47dab0+='['+_0x28c0b2[_0x4d9234('0x23')](_0x5bd8c0)+']';}return _0x47dab0+='.',_0x47dab0;}exports['update']=function(_0x5ee967,_0x223a88){const _0x87bd91=_0x3b3ced,_0x4aa99b=_0x5ee967[_0x87bd91('0x56')];return _0x4aa99b[_0x87bd91('0x7')]='system-'+_0x4aa99b[_0x87bd91('0x10')]+'-',db['sequelize'][_0x87bd91('0x57')](function(_0x428f56){const _0x451c27=_0x87bd91;return db[_0x451c27('0x18')][_0x451c27('0xd')](_0x4aa99b,{'where':{'id':_0x4aa99b['id']},'transaction':_0x428f56})['then'](function(){const _0x3b251f=_0x451c27;return db[_0x3b251f('0x24')]['destroy']({'where':{'VoicePrefixId':_0x4aa99b['id']},'transaction':_0x428f56})[_0x3b251f('0x3e')](function(){const _0x15d1a8=_0x3b251f;return db['VoiceExtension'][_0x15d1a8('0x12')]({'where':{'id':_0x4aa99b[_0x15d1a8('0x16')]},'raw':!![]})[_0x15d1a8('0x3e')](function(_0x152620){return createVoicePrefixExtensions(_0x4aa99b,_0x152620,_0x428f56);});});});})[_0x87bd91('0x3e')](function(){const _0x5e005f=_0x87bd91;return db[_0x5e005f('0x18')]['findByPk'](_0x4aa99b['id']);})[_0x87bd91('0x3e')](respondWithResult(_0x223a88,null))[_0x87bd91('0x47')](handleError(_0x223a88,null));},exports[_0x3b3ced('0x25')]=function(_0x31cf3d,_0x4e6349){const _0x3a9349=_0x3b3ced;return db[_0x3a9349('0x18')][_0x3a9349('0x12')]({'where':{'id':_0x31cf3d[_0x3a9349('0xa')]['id']}})['then'](function(_0x15359f){const _0x47b2cf=_0x3a9349;if(_0x15359f)return _0x15359f[_0x47b2cf('0x25')](_0x31cf3d[_0x47b2cf('0x56')][_0x47b2cf('0x33')],{'through':_['omit'](_0x31cf3d[_0x47b2cf('0x56')],[_0x47b2cf('0x33'),'id'])})[_0x47b2cf('0x3e')](function(_0x16abe6){const _0x2a023f=_0x47b2cf;for(let _0x9c9476=0x0;_0x9c9476<_0x31cf3d['body'][_0x2a023f('0x33')][_0x2a023f('0x11')];_0x9c9476+=0x1){socket[_0x2a023f('0x1c')](_0x2a023f('0x62'),{'UserId':_0x31cf3d[_0x2a023f('0x56')][_0x2a023f('0x33')][_0x9c9476],'VoicePrefixId':_0x31cf3d[_0x2a023f('0xa')]['id']});}return _0x16abe6;});})[_0x3a9349('0x3e')](respondWithResult(_0x4e6349,null))['catch'](handleError(_0x4e6349,null));},exports[_0x3b3ced('0x45')]=function(_0x4e33ed,_0x1ae121){const _0x12b967=_0x3b3ced;return db['VoicePrefix'][_0x12b967('0x12')]({'where':{'id':_0x4e33ed[_0x12b967('0xa')]['id']}})[_0x12b967('0x3e')](handleEntityNotFound(_0x1ae121,null))[_0x12b967('0x3e')](function(_0x4eed08){const _0x31c37e=_0x12b967;if(_0x4eed08)return _0x4eed08[_0x31c37e('0x45')](_0x4e33ed[_0x31c37e('0x40')][_0x31c37e('0x33')])[_0x31c37e('0x3e')](function(){const _0x41f062=_0x31c37e;if(_[_0x41f062('0x46')](_0x4e33ed[_0x41f062('0x40')][_0x41f062('0x33')]))for(let _0x4b01c9=0x0;_0x4b01c9<_0x4e33ed[_0x41f062('0x40')]['ids'][_0x41f062('0x11')];_0x4b01c9+=0x1){socket[_0x41f062('0x1c')]('userVoicePrefix:remove',{'UserId':Number(_0x4e33ed[_0x41f062('0x40')][_0x41f062('0x33')][_0x4b01c9]),'VoicePrefixId':Number(_0x4e33ed[_0x41f062('0xa')]['id'])});}else socket[_0x41f062('0x1c')](_0x41f062('0x32'),{'UserId':Number(_0x4e33ed[_0x41f062('0x40')][_0x41f062('0x33')]),'VoicePrefixId':Number(_0x4e33ed[_0x41f062('0xa')]['id'])});});})[_0x12b967('0x3e')](respondWithStatusCode(_0x1ae121,null))[_0x12b967('0x47')](handleError(_0x1ae121,null));},exports[_0x3b3ced('0x4e')]=function(_0x46c431,_0x35b48f){const _0x1e27fa=_0x3b3ced;let _0x363942={};const _0x35c23b={};let _0x4535c4,_0x4fa427;return db[_0x1e27fa('0x18')]['findOne']({'where':{'id':_0x46c431[_0x1e27fa('0xa')]['id']}})[_0x1e27fa('0x3e')](handleEntityNotFound(_0x35b48f,null))[_0x1e27fa('0x3e')](function(_0x31a70b){const _0x5d3597=_0x1e27fa;if(_0x31a70b)return _0x4535c4=_0x31a70b,_0x35c23b[_0x5d3597('0x60')]=_[_0x5d3597('0x58')](db[_0x5d3597('0x49')][_0x5d3597('0x28')]),_0x35c23b[_0x5d3597('0x40')]=_[_0x5d3597('0x58')](_0x46c431[_0x5d3597('0x40')]),_0x35c23b[_0x5d3597('0x1e')]=_[_0x5d3597('0x5d')](_0x35c23b[_0x5d3597('0x60')],_0x35c23b['query']),_0x363942['attributes']=_[_0x5d3597('0x5d')](_0x35c23b[_0x5d3597('0x60')],qs[_0x5d3597('0x2c')](_0x46c431[_0x5d3597('0x40')]['fields'])),_0x363942[_0x5d3597('0x55')]=_0x363942[_0x5d3597('0x55')][_0x5d3597('0x11')]?_0x363942[_0x5d3597('0x55')]:_0x35c23b[_0x5d3597('0x60')],_0x363942['order']=qs[_0x5d3597('0x3c')](_0x46c431[_0x5d3597('0x40')][_0x5d3597('0x3c')]),_0x363942[_0x5d3597('0x48')]=qs['filters'](_[_0x5d3597('0x38')](_0x46c431[_0x5d3597('0x40')],_0x35c23b[_0x5d3597('0x1e')])),_0x46c431[_0x5d3597('0x40')][_0x5d3597('0x1d')]&&(_0x363942[_0x5d3597('0x48')]=_[_0x5d3597('0x43')](_0x363942['where'],{[Op['or']]:_[_0x5d3597('0xf')](_0x363942[_0x5d3597('0x55')],function(_0x4862ca){const _0x4cee77=_0x5d3597,_0x42755d={};return _0x42755d[_0x4862ca]={[Op[_0x4cee77('0x2f')]]:'%'+_0x46c431[_0x4cee77('0x40')][_0x4cee77('0x1d')]+'%'},_0x42755d;})})),_0x363942=_[_0x5d3597('0x43')]({},_0x363942,_0x46c431[_0x5d3597('0x3a')]),_0x4535c4[_0x5d3597('0x4e')](_0x363942);})[_0x1e27fa('0x3e')](function(_0x1c5ee5){const _0x1c7e2d=_0x1e27fa;if(_0x1c5ee5)return _0x4fa427=_0x1c5ee5[_0x1c7e2d('0x11')],typeof _0x46c431['query']['nolimit']==='undefined'&&(_0x363942[_0x1c7e2d('0x61')]=qs[_0x1c7e2d('0x61')](_0x46c431['query'][_0x1c7e2d('0x61')]),_0x363942[_0x1c7e2d('0x5b')]=qs['offset'](_0x46c431[_0x1c7e2d('0x40')][_0x1c7e2d('0x5b')])),_0x4535c4[_0x1c7e2d('0x4e')](_0x363942);})[_0x1e27fa('0x3e')](function(_0x1e2985){if(_0x1e2985)return _0x1e2985?{'count':_0x4fa427,'rows':_0x1e2985}:null;})[_0x1e27fa('0x3e')](respondWithResult(_0x35b48f,null))[_0x1e27fa('0x47')](handleError(_0x35b48f,null));}; \ No newline at end of file diff --git a/server/api/voicePrefix/voicePrefix.events.js b/server/api/voicePrefix/voicePrefix.events.js index 1d09bd1..2370c62 100644 --- a/server/api/voicePrefix/voicePrefix.events.js +++ b/server/api/voicePrefix/voicePrefix.events.js @@ -1 +1 @@ -const a747_0x4dc4=['setMaxListeners','exports','undefined','events','VoicePrefix','emit','update','remove'];(function(_0x42e9cd,_0x4dc49b){const _0x49c289=function(_0x220dc9){while(--_0x220dc9){_0x42e9cd['push'](_0x42e9cd['shift']());}};_0x49c289(++_0x4dc49b);}(a747_0x4dc4,0x19a));const a747_0x49c2=function(_0x42e9cd,_0x4dc49b){_0x42e9cd=_0x42e9cd-0x0;let _0x49c289=a747_0x4dc4[_0x42e9cd];return _0x49c289;};const _0x3f23b1=a747_0x49c2;'use strict';const EventEmitter=require(_0x3f23b1('0x1')),VoicePrefix=require('../../mysqldb')['db'][_0x3f23b1('0x2')],VoicePrefixEvents=new EventEmitter();VoicePrefixEvents[_0x3f23b1('0x6')](0x0);const events={'afterCreate':'save','afterUpdate':_0x3f23b1('0x4'),'afterDestroy':_0x3f23b1('0x5')};function emitEvent(_0x220dc9){return function(_0x34d13f){const _0x3b5d43=a747_0x49c2;VoicePrefixEvents['emit'](_0x220dc9+':'+_0x34d13f['id'],_0x34d13f),VoicePrefixEvents[_0x3b5d43('0x3')](_0x220dc9,_0x34d13f);};}for(const e in events){if(typeof events[e]!==_0x3f23b1('0x0')){const event=events[e];VoicePrefix['addHook'](e,emitEvent(event));}}module[_0x3f23b1('0x7')]=VoicePrefixEvents; \ No newline at end of file +const a747_0x4c67=['undefined','exports','emit','addHook','VoicePrefix','save'];(function(_0x3bbaf3,_0x4c6762){const _0x11ef37=function(_0x231e5f){while(--_0x231e5f){_0x3bbaf3['push'](_0x3bbaf3['shift']());}};_0x11ef37(++_0x4c6762);}(a747_0x4c67,0x1bf));const a747_0x11ef=function(_0x3bbaf3,_0x4c6762){_0x3bbaf3=_0x3bbaf3-0x0;let _0x11ef37=a747_0x4c67[_0x3bbaf3];return _0x11ef37;};const _0x3a8629=a747_0x11ef;'use strict';const EventEmitter=require('events'),VoicePrefix=require('../../mysqldb')['db'][_0x3a8629('0x1')],VoicePrefixEvents=new EventEmitter();VoicePrefixEvents['setMaxListeners'](0x0);const events={'afterCreate':_0x3a8629('0x2'),'afterUpdate':'update','afterDestroy':'remove'};function emitEvent(_0x231e5f){return function(_0x1cb6ea){const _0x1c2e59=a747_0x11ef;VoicePrefixEvents[_0x1c2e59('0x5')](_0x231e5f+':'+_0x1cb6ea['id'],_0x1cb6ea),VoicePrefixEvents[_0x1c2e59('0x5')](_0x231e5f,_0x1cb6ea);};}for(const e in events){if(typeof events[e]!==_0x3a8629('0x3')){const event=events[e];VoicePrefix[_0x3a8629('0x0')](e,emitEvent(event));}}module[_0x3a8629('0x4')]=VoicePrefixEvents; \ No newline at end of file diff --git a/server/api/voicePrefix/voicePrefix.model.js b/server/api/voicePrefix/voicePrefix.model.js index 4f90eb7..d25f601 100644 --- a/server/api/voicePrefix/voicePrefix.model.js +++ b/server/api/voicePrefix/voicePrefix.model.js @@ -1 +1 @@ -const a748_0x1716=['define','./voicePrefix.attributes','VoicePrefix','voice_prefixes','exports'];(function(_0x5033c4,_0x17164f){const _0x585524=function(_0x1a9b0a){while(--_0x1a9b0a){_0x5033c4['push'](_0x5033c4['shift']());}};_0x585524(++_0x17164f);}(a748_0x1716,0xb0));const a748_0x5855=function(_0x5033c4,_0x17164f){_0x5033c4=_0x5033c4-0x0;let _0x585524=a748_0x1716[_0x5033c4];return _0x585524;};const _0x5cfbf5=a748_0x5855;'use strict';const attributes=require(_0x5cfbf5('0x0'));module[_0x5cfbf5('0x3')]=function(_0x1a9b0a){const _0x1be098=_0x5cfbf5,_0x15643f=_0x1a9b0a[_0x1be098('0x4')](_0x1be098('0x1'),attributes,{'tableName':_0x1be098('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x15643f;}; \ No newline at end of file +const a748_0x4650=['VoicePrefix','define','./voicePrefix.attributes','exports','voice_prefixes'];(function(_0x5007b9,_0x465037){const _0x5d8e85=function(_0x1a0069){while(--_0x1a0069){_0x5007b9['push'](_0x5007b9['shift']());}};_0x5d8e85(++_0x465037);}(a748_0x4650,0x1c3));const a748_0x5d8e=function(_0x5007b9,_0x465037){_0x5007b9=_0x5007b9-0x0;let _0x5d8e85=a748_0x4650[_0x5007b9];return _0x5d8e85;};const _0x15807e=a748_0x5d8e;'use strict';const attributes=require(_0x15807e('0x1'));module[_0x15807e('0x2')]=function(_0x1a0069){const _0x530918=_0x15807e,_0x48fab2=_0x1a0069[_0x530918('0x0')](_0x530918('0x4'),attributes,{'tableName':_0x530918('0x3'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x48fab2;}; \ No newline at end of file diff --git a/server/api/voicePrefix/voicePrefix.rpc.js b/server/api/voicePrefix/voicePrefix.rpc.js index 4d93c6b..237876a 100644 --- a/server/api/voicePrefix/voicePrefix.rpc.js +++ b/server/api/voicePrefix/voicePrefix.rpc.js @@ -1 +1 @@ -const a749_0x2476=['register','../../rediscache'];(function(_0x110677,_0x24769f){const _0x200b0d=function(_0x1d17d7){while(--_0x1d17d7){_0x110677['push'](_0x110677['shift']());}};_0x200b0d(++_0x24769f);}(a749_0x2476,0x136));const a749_0x200b=function(_0x110677,_0x24769f){_0x110677=_0x110677-0x0;let _0x200b0d=a749_0x2476[_0x110677];return _0x200b0d;};const _0x585f15=a749_0x200b;'use strict';const {getSocket}=require(_0x585f15('0x1')),socket=getSocket();require('./voicePrefix.socket')[_0x585f15('0x0')](socket); \ No newline at end of file +const a749_0x25cd=['register','../../rediscache'];(function(_0x161040,_0x25cdf3){const _0x15245a=function(_0x1818b4){while(--_0x1818b4){_0x161040['push'](_0x161040['shift']());}};_0x15245a(++_0x25cdf3);}(a749_0x25cd,0x10c));const a749_0x1524=function(_0x161040,_0x25cdf3){_0x161040=_0x161040-0x0;let _0x15245a=a749_0x25cd[_0x161040];return _0x15245a;};const _0x49e833=a749_0x1524;'use strict';const {getSocket}=require(_0x49e833('0x1')),socket=getSocket();require('./voicePrefix.socket')[_0x49e833('0x0')](socket); \ No newline at end of file diff --git a/server/api/voicePrefix/voicePrefix.socket.js b/server/api/voicePrefix/voicePrefix.socket.js index 8435e98..fffa8fa 100644 --- a/server/api/voicePrefix/voicePrefix.socket.js +++ b/server/api/voicePrefix/voicePrefix.socket.js @@ -1 +1 @@ -const a750_0x38e6=['length','save','update','./voicePrefix.events','register'];(function(_0x3dc161,_0x38e6b2){const _0x1f5891=function(_0x4c0c44){while(--_0x4c0c44){_0x3dc161['push'](_0x3dc161['shift']());}};_0x1f5891(++_0x38e6b2);}(a750_0x38e6,0x99));const a750_0x1f58=function(_0x3dc161,_0x38e6b2){_0x3dc161=_0x3dc161-0x0;let _0x1f5891=a750_0x38e6[_0x3dc161];return _0x1f5891;};const _0x4276aa=a750_0x1f58;'use strict';const VoicePrefixEvents=require(_0x4276aa('0x0')),events=[_0x4276aa('0x3'),'remove',_0x4276aa('0x4')];function createListener(_0x4c0c44,_0x14fd9a){return function(_0x1ca3b7){_0x14fd9a['emit'](_0x4c0c44,_0x1ca3b7);};}exports[_0x4276aa('0x1')]=function(_0x38fdae){const _0x5b58cb=_0x4276aa;for(let _0x4811fd=0x0,_0xabb118=events[_0x5b58cb('0x2')];_0x4811fd<_0xabb118;_0x4811fd++){const _0x33fc7b=events[_0x4811fd],_0x14eec0=createListener('voicePrefix:'+_0x33fc7b,_0x38fdae);VoicePrefixEvents['on'](_0x33fc7b,_0x14eec0);}}; \ No newline at end of file +const a750_0x2cc4=['save','remove','emit','./voicePrefix.events','length'];(function(_0x143403,_0x2cc417){const _0x289642=function(_0x544f39){while(--_0x544f39){_0x143403['push'](_0x143403['shift']());}};_0x289642(++_0x2cc417);}(a750_0x2cc4,0xc0));const a750_0x2896=function(_0x143403,_0x2cc417){_0x143403=_0x143403-0x0;let _0x289642=a750_0x2cc4[_0x143403];return _0x289642;};const _0x508aa6=a750_0x2896;'use strict';const VoicePrefixEvents=require(_0x508aa6('0x1')),events=[_0x508aa6('0x3'),_0x508aa6('0x4'),'update'];function createListener(_0x544f39,_0x47f3c8){return function(_0x36fef5){const _0x44ddcc=a750_0x2896;_0x47f3c8[_0x44ddcc('0x0')](_0x544f39,_0x36fef5);};}exports['register']=function(_0x103512){const _0x476a91=_0x508aa6;for(let _0x25d9c5=0x0,_0x4f6cac=events[_0x476a91('0x2')];_0x25d9c5<_0x4f6cac;_0x25d9c5++){const _0x3fe36a=events[_0x25d9c5],_0x1d7539=createListener('voicePrefix:'+_0x3fe36a,_0x103512);VoicePrefixEvents['on'](_0x3fe36a,_0x1d7539);}}; \ No newline at end of file diff --git a/server/api/voiceQueue/index.js b/server/api/voiceQueue/index.js index 41a83da..a595527 100644 --- a/server/api/voiceQueue/index.js +++ b/server/api/voiceQueue/index.js @@ -1 +1 @@ -const a751_0x35c6=['removeBlackLists','/:id/hoppers','../../components/auth/service','getTeams','get','addBlackLists','exports','post','/:id/clone','delete','/:id/hopper_black','/:id/hopper_histories','addAgents','/:id/teams','getHoppers','addLists','/:id/hopper_finals','/:id/lists','/:id/blacklists','/:id/users','isAuthenticated','update','destroy','create','getMembers','getLists','getHopperBlacks','getHopperFinals','clone','express','/:id','removeLists','./voiceQueue.controller','Router'];(function(_0x3fab1e,_0x35c681){const _0x12e5e3=function(_0x3d2504){while(--_0x3d2504){_0x3fab1e['push'](_0x3fab1e['shift']());}};_0x12e5e3(++_0x35c681);}(a751_0x35c6,0x127));const a751_0x12e5=function(_0x3fab1e,_0x35c681){_0x3fab1e=_0x3fab1e-0x0;let _0x12e5e3=a751_0x35c6[_0x3fab1e];return _0x12e5e3;};const _0x1489ee=a751_0x12e5;'use strict';const express=require(_0x1489ee('0x6')),router=express[_0x1489ee('0xa')](),auth=require(_0x1489ee('0xd')),controller=require(_0x1489ee('0x9'));router['get']('/',auth[_0x1489ee('0x1f')](),controller['index']),router[_0x1489ee('0xf')](_0x1489ee('0x7'),auth['isAuthenticated'](),controller['show']),router[_0x1489ee('0xf')](_0x1489ee('0xc'),auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0x19')]),router[_0x1489ee('0xf')](_0x1489ee('0x16'),auth[_0x1489ee('0x1f')](),controller['getHopperHistories']),router[_0x1489ee('0xf')](_0x1489ee('0x1b'),auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0x4')]),router[_0x1489ee('0xf')](_0x1489ee('0x15'),auth['isAuthenticated'](),controller[_0x1489ee('0x3')]),router[_0x1489ee('0xf')](_0x1489ee('0x18'),auth['isAuthenticated'](),controller[_0x1489ee('0xe')]),router[_0x1489ee('0xf')]('/:id/users',auth[_0x1489ee('0x1f')](),controller['getAgents']),router[_0x1489ee('0xf')]('/:id/members',auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0x1')]),router[_0x1489ee('0xf')](_0x1489ee('0x1c'),auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0x2')]),router[_0x1489ee('0xf')]('/:id/blacklists',auth[_0x1489ee('0x1f')](),controller['getBlackLists']),router[_0x1489ee('0x12')]('/',auth['isAuthenticated'](),controller[_0x1489ee('0x0')]),router[_0x1489ee('0x12')](_0x1489ee('0x13'),auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0x5')]),router['post'](_0x1489ee('0x18'),auth[_0x1489ee('0x1f')](),controller['addTeams']),router['post'](_0x1489ee('0x1e'),auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0x17')]),router[_0x1489ee('0x12')](_0x1489ee('0x1c'),auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0x1a')]),router[_0x1489ee('0x12')]('/:id/blacklists',auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0x10')]),router['put'](_0x1489ee('0x7'),auth['isAuthenticated'](),controller[_0x1489ee('0x20')]),router[_0x1489ee('0x14')](_0x1489ee('0x7'),auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0x21')]),router[_0x1489ee('0x14')](_0x1489ee('0x18'),auth[_0x1489ee('0x1f')](),controller['removeTeams']),router['delete']('/:id/users',auth[_0x1489ee('0x1f')](),controller['removeAgents']),router[_0x1489ee('0x14')]('/:id/lists',auth['isAuthenticated'](),controller[_0x1489ee('0x8')]),router[_0x1489ee('0x14')](_0x1489ee('0x1d'),auth[_0x1489ee('0x1f')](),controller[_0x1489ee('0xb')]),module[_0x1489ee('0x11')]=router; \ No newline at end of file +const a751_0x4390=['/:id/blacklists','index','isAuthenticated','Router','/:id/members','getLists','/:id/hopper_histories','getHoppers','/:id/lists','getHopperFinals','getTeams','put','get','../../components/auth/service','removeBlackLists','destroy','addTeams','getBlackLists','delete','update','getHopperBlacks','/:id/teams','removeTeams','create','getMembers','post','clone','/:id','addBlackLists','getHopperHistories','show','removeLists','exports','./voiceQueue.controller','/:id/users','addAgents'];(function(_0x45e386,_0x43908c){const _0x398b33=function(_0x4df308){while(--_0x4df308){_0x45e386['push'](_0x45e386['shift']());}};_0x398b33(++_0x43908c);}(a751_0x4390,0x1e1));const a751_0x398b=function(_0x45e386,_0x43908c){_0x45e386=_0x45e386-0x0;let _0x398b33=a751_0x4390[_0x45e386];return _0x398b33;};const _0x6b9b9=a751_0x398b;'use strict';const express=require('express'),router=express[_0x6b9b9('0x1a')](),auth=require(_0x6b9b9('0x0')),controller=require(_0x6b9b9('0x14'));router[_0x6b9b9('0x23')]('/',auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x18')]),router['get'](_0x6b9b9('0xe'),auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x11')]),router[_0x6b9b9('0x23')]('/:id/hoppers',auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x1e')]),router[_0x6b9b9('0x23')](_0x6b9b9('0x1d'),auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x10')]),router['get']('/:id/hopper_finals',auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x20')]),router[_0x6b9b9('0x23')]('/:id/hopper_black',auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x7')]),router['get'](_0x6b9b9('0x8'),auth['isAuthenticated'](),controller[_0x6b9b9('0x21')]),router['get'](_0x6b9b9('0x15'),auth[_0x6b9b9('0x19')](),controller['getAgents']),router[_0x6b9b9('0x23')](_0x6b9b9('0x1b'),auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0xb')]),router[_0x6b9b9('0x23')](_0x6b9b9('0x1f'),auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x1c')]),router[_0x6b9b9('0x23')](_0x6b9b9('0x17'),auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x4')]),router[_0x6b9b9('0xc')]('/',auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0xa')]),router[_0x6b9b9('0xc')]('/:id/clone',auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0xd')]),router[_0x6b9b9('0xc')](_0x6b9b9('0x8'),auth['isAuthenticated'](),controller[_0x6b9b9('0x3')]),router[_0x6b9b9('0xc')]('/:id/users',auth['isAuthenticated'](),controller[_0x6b9b9('0x16')]),router[_0x6b9b9('0xc')](_0x6b9b9('0x1f'),auth['isAuthenticated'](),controller['addLists']),router[_0x6b9b9('0xc')](_0x6b9b9('0x17'),auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0xf')]),router[_0x6b9b9('0x22')](_0x6b9b9('0xe'),auth['isAuthenticated'](),controller[_0x6b9b9('0x6')]),router['delete'](_0x6b9b9('0xe'),auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x2')]),router[_0x6b9b9('0x5')](_0x6b9b9('0x8'),auth['isAuthenticated'](),controller[_0x6b9b9('0x9')]),router[_0x6b9b9('0x5')](_0x6b9b9('0x15'),auth[_0x6b9b9('0x19')](),controller['removeAgents']),router[_0x6b9b9('0x5')](_0x6b9b9('0x1f'),auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x12')]),router[_0x6b9b9('0x5')](_0x6b9b9('0x17'),auth[_0x6b9b9('0x19')](),controller[_0x6b9b9('0x1')]),module[_0x6b9b9('0x13')]=router; \ No newline at end of file diff --git a/server/api/voiceQueue/voiceQueue.attributes.js b/server/api/voiceQueue/voiceQueue.attributes.js index 5445fad..f527ed5 100644 --- a/server/api/voiceQueue/voiceQueue.attributes.js +++ b/server/api/voiceQueue/voiceQueue.attributes.js @@ -1 +1 @@ -const a752_0x4599=['#NoAnswer\x20Retry\x20(min:1,\x20max:999)','Queue\x20Timeout\x20Seconds\x20(min:1,\x20max:999)','#AgentReject\x20Retry\x20(min:1,\x20max:999)','#Busy\x20Retry\x20(min:1,\x20max:999)','exports','#Machine\x20Retry\x20(min:1,\x20max:999)','setDataValue','https://wiki.asterisk.org/wiki/display/AST/Asterisk+13+Application_Queue','#AMD\x20Greeting','always','never','TEXT','#AMD\x20Silence\x20Threshold\x20(min:0,\x20max:32767)','Abandoned\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','Random\x20Last\x20Digit\x20(min:1,\x20max:15)','#AMD\x20Total\x20Analysis\x20Time','leastrecent','FLOAT','wrandom','#AMD\x20Min\x20Word\x20Length','sequelize','joinempty','split','ENUM','rrordered','DESC','#NoSuchNumber\x20Retry\x20(min:1,\x20max:999)','BOOLEAN','Dial\x20Method.','07:00-22:00,*,*,*','STRING','#Drop\x20Retry\x20(min:1,\x20max:999)','#Global\x20Max\x20Retry\x20(min:1,\x20max:999)','roundrobin','INTEGER','NoSuchNumber\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','preview','mandatoryDispositionPauseId','Active/Disactive\x20AMD','Congestion\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','Max\x209999\x20member\x20in\x20queue(min:1,\x20max:9999),\x200\x20means\x20unlimited.','name','ringall','ASC','getDataValue','Drop\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','join','#RecallMe\x20Timeout\x20(min:1)','Power\x20Level:\x20Calls\x20for\x20agents\x20(min:1,\x20max:10).','leavewhenempty','UNSIGNED','fewestcalls','AGI\x20queue\x20option\x20(use:\x20agi://127.0.0.1/square,)','Only\x20for\x20predictive\x20method.','progressive','wrapuptime','yes','tTxX','booked','Cut\x20Digit\x20(min:1,\x20max:15)','default','periodic_announce','once','rrmemory','predictive','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','Active/Disactive\x20Recall\x20In\x20Queue','Originate\x20Timeout\x20Seconds\x20(min:1,\x20max:999)','power','Busy\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','AgentReject\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','linear','#AMD\x20Maximum\x20Word\x20Length','#AMD\x20Between\x20Words\x20Silence','inbound','dialMethod','Predictive\x20Optimization\x20Percentage\x20(min:\x201,\x20max:\x2095)','Interval\x20Predictive\x20Minutes\x20(min:5\x20max:30)','type'];(function(_0x5b2c3d,_0x459967){const _0x58394b=function(_0x12f963){while(--_0x12f963){_0x5b2c3d['push'](_0x5b2c3d['shift']());}};_0x58394b(++_0x459967);}(a752_0x4599,0xde));const a752_0x5839=function(_0x5b2c3d,_0x459967){_0x5b2c3d=_0x5b2c3d-0x0;let _0x58394b=a752_0x4599[_0x5b2c3d];return _0x58394b;};const _0xb39a8=a752_0x5839;'use strict';const Sequelize=require(_0xb39a8('0x26'));module[_0xb39a8('0x16')]={'name':{'type':Sequelize['STRING'],'allowNull':![],'unique':_0xb39a8('0x3b'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'type':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0xd'),'outbound'),'allowNull':![],'defaultValue':_0xb39a8('0xd')},'musiconhold':{'type':Sequelize['STRING'],'defaultValue':_0xb39a8('0x4e')},'announce':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':''},'strategy':{'type':Sequelize[_0xb39a8('0x29')]('rr',_0xb39a8('0x3c'),_0xb39a8('0x22'),_0xb39a8('0x45'),'random','rrmemory',_0xb39a8('0xa'),_0xb39a8('0x24'),_0xb39a8('0x2a')),'allowNull':![],'defaultValue':'ringall','set':function(_0x12f963){const _0x5be1fc=_0xb39a8;this['setDataValue']('strategy',_0x12f963?_0x12f963:_0x5be1fc('0x1'));},'get':function(){const _0x239a7d=_0xb39a8,_0x488024=this[_0x239a7d('0x3e')](_0x239a7d('0x11')),_0x1b1360=this[_0x239a7d('0x3e')](_0x239a7d('0xe')),_0x40070c=this['getDataValue']('strategy');if(_0x488024==='inbound')return _0x40070c;if(_0x1b1360===_0x239a7d('0x4c')&&_0x40070c===_0x239a7d('0x1')||_0x1b1360===_0x239a7d('0x4c')&&_0x40070c===_0x239a7d('0x33'))return _0x40070c;if(_0x1b1360===_0x239a7d('0x48')||_0x1b1360==='predictive'||_0x1b1360===_0x239a7d('0x7'))return _0x40070c;return null;}},'servicelevel':{'type':Sequelize[_0xb39a8('0x34')](0xb),'defaultValue':0x0},'context':{'type':Sequelize['STRING'],'defaultValue':null},'penaltymemberslimit':{'type':Sequelize['INTEGER'](0xb)},'timeout':{'type':Sequelize[_0xb39a8('0x34')](0xb),'defaultValue':0xf},'retry':{'type':Sequelize[_0xb39a8('0x34')](0xb),'defaultValue':0x2},'timeoutpriority':{'type':Sequelize[_0xb39a8('0x30')]},'weight':{'type':Sequelize[_0xb39a8('0x34')](0xb),'allowNull':!![],'defaultValue':0x0},'wrapuptime':{'type':Sequelize['INTEGER'](0xb),'defaultValue':0x0},'autofill':{'type':Sequelize[_0xb39a8('0x29')]('yes','no'),'defaultValue':'yes'},'autopause':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no','all'),'defaultValue':'no'},'autopausedelay':{'type':Sequelize[_0xb39a8('0x34')](0xb)},'autopausebusy':{'type':Sequelize[_0xb39a8('0x29')]('yes','no'),'defaultValue':'no'},'autopauseunavail':{'type':Sequelize['ENUM'](_0xb39a8('0x4a'),'no'),'defaultValue':'no'},'maxlen':{'type':Sequelize[_0xb39a8('0x34')](0xb),'defaultValue':0x0},'setinterfacevar':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no'),'defaultValue':'no'},'setqueueentryvar':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no'),'defautValue':'no'},'setqueuevar':{'type':Sequelize[_0xb39a8('0x29')]('yes','no'),'defaultValue':'no'},'eventmemberstatus':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no'),'defaultValue':'no'},'membermacro':{'type':Sequelize['STRING'],'allowNull':!![]},'membergosub':{'type':Sequelize[_0xb39a8('0x30')],'allowNull':!![]},'announce_frequency':{'type':Sequelize[_0xb39a8('0x34')](0xb),'defaultValue':0x0},'min_announce_frequency':{'type':Sequelize['INTEGER'](0xb),'defaultValue':0x0},'periodic_announce_frequency':{'type':Sequelize['INTEGER'](0xb),'defaultValue':0x0},'random_periodic_announce':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no'),'defaultValue':'no'},'relative_periodic_announce':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no'),'defaultValue':_0xb39a8('0x4a')},'announce_holdtime':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no',_0xb39a8('0x0')),'defaultValue':'no'},'announce_position':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':'no'},'announce_to_first_user':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no')},'announce_position_limit':{'type':Sequelize[_0xb39a8('0x34')](0xb)},'announce_round_seconds':{'type':Sequelize[_0xb39a8('0x29')]('0','5','10','15','20','30'),'defaultValue':'0'},'monitor_format':{'type':Sequelize['STRING'],'defaultValue':''},'monitor_type':{'type':Sequelize[_0xb39a8('0x30')]},'queue_youarenext':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':null},'queue_thereare':{'type':Sequelize['STRING'],'defaultValue':null},'queue_callswaiting':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':null},'queue_holdtime':{'type':Sequelize['STRING'],'defaultValue':null},'queue_minute':{'type':Sequelize['STRING'],'allowNull':!![],'defaultValue':null},'queue_minutes':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':null},'queue_seconds':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':null},'queue_thankyou':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':null},'queue_reporthold':{'type':Sequelize[_0xb39a8('0x30')]},'queue_quantity1':{'type':Sequelize[_0xb39a8('0x30')]},'queue_quantity2':{'type':Sequelize[_0xb39a8('0x30')]},'queue_periodic_announce':{'type':Sequelize[_0xb39a8('0x30')]},'queue_less_than':{'type':Sequelize[_0xb39a8('0x30')]},'periodic_announce':{'type':Sequelize[_0xb39a8('0x1d')],'set':function(_0x3ab673){const _0x230ec1=_0xb39a8;this[_0x230ec1('0x18')]('periodic_announce',_0x3ab673?_0x3ab673[_0x230ec1('0x40')](','):[]);},'get':function(){const _0x3f3cd3=_0xb39a8;return this['getDataValue']('periodic_announce')?this[_0x3f3cd3('0x3e')](_0x3f3cd3('0x4f'))[_0x3f3cd3('0x28')](','):[];}},'joinempty':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':'yes','set':function(_0x2f8cdb){const _0x59995e=_0xb39a8;this[_0x59995e('0x18')](_0x59995e('0x27'),_0x2f8cdb?_0x2f8cdb['join'](','):undefined);},'get':function(){const _0x20b881=_0xb39a8;return this[_0x20b881('0x3e')](_0x20b881('0x27'))?this[_0x20b881('0x3e')](_0x20b881('0x27'))['split'](','):undefined;}},'leavewhenempty':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':'no','set':function(_0xa81235){const _0x27cbb2=_0xb39a8;this[_0x27cbb2('0x18')](_0x27cbb2('0x43'),_0xa81235?_0xa81235['join'](','):undefined);},'get':function(){const _0x290887=_0xb39a8;return this[_0x290887('0x3e')](_0x290887('0x43'))?this[_0x290887('0x3e')]('leavewhenempty')[_0x290887('0x28')](','):undefined;}},'reportholdtime':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no'),'defaultValue':'no'},'ringinuse':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x4a'),'no'),'defaultValue':'no'},'memberdelay':{'type':Sequelize['INTEGER'](0xb),'defaultValue':0x0},'timeoutrestart':{'type':Sequelize[_0xb39a8('0x29')]('yes','no'),'defaultValue':'no'},'defaultrule':{'type':Sequelize[_0xb39a8('0x30')]},'description':{'type':Sequelize[_0xb39a8('0x30')]},'acw':{'type':Sequelize['BOOLEAN'],'defaultValue':0x0,'set':function(_0x279dde){const _0x29cf81=_0xb39a8;this[_0x29cf81('0x18')]('acw',_0x279dde),_0x279dde&&(this['getDataValue'](_0x29cf81('0x49'))<0x2&&this[_0x29cf81('0x18')](_0x29cf81('0x49'),0x2));}},'acwTimeout':{'type':Sequelize[_0xb39a8('0x34')](0xb),'defaultValue':0xa},'dialActive':{'type':Sequelize[_0xb39a8('0x2d')],'defaultValue':0x0,'comment':'Active/Disactive\x20Campaign'},'dialMethod':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x36'),'progressive','power',_0xb39a8('0x2'),_0xb39a8('0x4c')),'defaultValue':'progressive','comment':_0xb39a8('0x2e')},'dialLimitChannel':{'type':Sequelize[_0xb39a8('0x34')](0x4)[_0xb39a8('0x44')],'defaultValue':0x0,'validate':{'min':0x0,'max':0x270f},'comment':'Max\x209999\x20channels,\x200\x20means\x20unlimited.'},'dialLimitQueue':{'type':Sequelize[_0xb39a8('0x34')](0x4)[_0xb39a8('0x44')],'defaultValue':0x0,'validate':{'min':0x0,'max':0x270f},'comment':_0xb39a8('0x3a')},'dialPowerLevel':{'type':Sequelize[_0xb39a8('0x23')](0x2)[_0xb39a8('0x44')],'defaultValue':0x1,'validate':{'min':0x1,'max':0xa},'comment':_0xb39a8('0x42')},'dialPredictiveOptimization':{'type':Sequelize[_0xb39a8('0x29')]('agentBusyFactor','dropRate'),'defaultValue':'dropRate','comment':_0xb39a8('0x47')},'dialPredictiveOptimizationPercentage':{'type':Sequelize[_0xb39a8('0x23')](0x2)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x1,'max':0x5f},'comment':_0xb39a8('0xf')},'dialPredictiveInterval':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'defaultValue':0xa,'validate':{'min':0x5,'max':0x1e},'comment':_0xb39a8('0x10')},'dialOriginateCallerIdName':{'type':Sequelize[_0xb39a8('0x30')]},'dialOriginateCallerIdNumber':{'type':Sequelize[_0xb39a8('0x30')]},'dialOriginateTimeout':{'type':Sequelize[_0xb39a8('0x34')](0x3)['UNSIGNED'],'defaultValue':0x1e,'validate':{'min':0x1,'max':0x3e7},'comment':_0xb39a8('0x6')},'dialQueueOptions':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':_0xb39a8('0x4b'),'comment':_0xb39a8('0x19')},'dialQueueTimeout':{'type':Sequelize['INTEGER'](0x3)[_0xb39a8('0x44')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0xb39a8('0x13')},'dialQueueProject':{'type':Sequelize[_0xb39a8('0x30')],'comment':_0xb39a8('0x46')},'dialCongestionMaxRetry':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':'#Congestion\x20Retry\x20(min:1,\x20max:999)'},'dialCongestionRetryFrequency':{'type':Sequelize[_0xb39a8('0x34')](0x5)[_0xb39a8('0x44')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0xb39a8('0x39')},'dialBusyMaxRetry':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0xb39a8('0x15')},'dialBusyRetryFrequency':{'type':Sequelize[_0xb39a8('0x34')](0x5)[_0xb39a8('0x44')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0xb39a8('0x8')},'dialNoAnswerMaxRetry':{'type':Sequelize[_0xb39a8('0x34')](0x3)['UNSIGNED'],'defaultValue':0x3,'comment':_0xb39a8('0x12')},'dialNoAnswerRetryFrequency':{'type':Sequelize[_0xb39a8('0x34')](0x5)[_0xb39a8('0x44')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':'NoAnswer\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)'},'dialGlobalMaxRetry':{'type':Sequelize['INTEGER'](0x3)[_0xb39a8('0x44')],'validate':{'min':0x1,'max':0x3e7},'defaultValue':0x4,'comment':_0xb39a8('0x32')},'dialTimezone':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':null},'dialGlobalInterval':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':_0xb39a8('0x2f')},'dialPrefix':{'type':Sequelize[_0xb39a8('0x30')],'defaultValue':null},'dialCheckDuplicateType':{'type':Sequelize['ENUM'](_0xb39a8('0x1b'),_0xb39a8('0x1c'),'onlyIfOpen'),'defaultValue':_0xb39a8('0x1b')},'dialAMDActive':{'type':Sequelize['BOOLEAN'],'defaultValue':0x0,'comment':_0xb39a8('0x38')},'dialAMDInitialSilence':{'type':Sequelize[_0xb39a8('0x34')](0x9)[_0xb39a8('0x44')],'defaultValue':0x9c4,'validate':{'min':0x0},'comment':'#AMD\x20Initial\x20Silence'},'dialAMDGreeting':{'type':Sequelize[_0xb39a8('0x34')](0x9)['UNSIGNED'],'defaultValue':0x5dc,'validate':{'min':0x0},'comment':_0xb39a8('0x1a')},'dialAMDAfterGreetingSilence':{'type':Sequelize[_0xb39a8('0x34')](0x9)[_0xb39a8('0x44')],'defaultValue':0x320,'validate':{'min':0x0},'comment':'#AMD\x20After\x20Greeting\x20Silence'},'dialAMDTotalAnalysisTime':{'type':Sequelize['INTEGER'](0x9)[_0xb39a8('0x44')],'defaultValue':0x1388,'validate':{'min':0x0},'comment':_0xb39a8('0x21')},'dialAMDMinWordLength':{'type':Sequelize[_0xb39a8('0x34')](0x9)['UNSIGNED'],'defaultValue':0x64,'validate':{'min':0x0},'comment':_0xb39a8('0x25')},'dialAMDBetweenWordsSilence':{'type':Sequelize[_0xb39a8('0x34')](0x9)['UNSIGNED'],'defaultValue':0x32,'validate':{'min':0x0},'comment':_0xb39a8('0xc')},'dialAMDMaximumNumberOfWords':{'type':Sequelize[_0xb39a8('0x34')](0x9)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x0},'comment':'#AMD\x20Maximum\x20Number\x20Of\x20Words'},'dialAMDSilenceThreshold':{'type':Sequelize[_0xb39a8('0x34')](0x5)[_0xb39a8('0x44')],'validate':{'min':0x0,'max':0x7fff},'defaultValue':0x100,'comment':_0xb39a8('0x1e')},'dialAMDMaximumWordLength':{'type':Sequelize['INTEGER'](0x9)['UNSIGNED'],'defaultValue':0x1388,'validate':{'min':0x0},'comment':_0xb39a8('0xb')},'dialRecallMeTimeout':{'type':Sequelize['INTEGER'](0x5)[_0xb39a8('0x44')],'validate':{'min':0x1},'defaultValue':0x1e,'comment':_0xb39a8('0x41')},'dialRecallInQueue':{'type':Sequelize[_0xb39a8('0x2d')],'defaultValue':0x0,'comment':_0xb39a8('0x5')},'dialOrderByScheduledAt':{'type':Sequelize[_0xb39a8('0x29')](_0xb39a8('0x2b'),_0xb39a8('0x3d')),'defaultValue':_0xb39a8('0x2b')},'dialQueueProject2':{'type':Sequelize[_0xb39a8('0x30')],'comment':_0xb39a8('0x46')},'dialAgiAfterHangupClient':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'dialAgiAfterHangupAgent':{'type':Sequelize[_0xb39a8('0x2d')],'defaultValue':![]},'dialRandomLastDigitCallerIdNumber':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'validate':{'min':0x0,'max':0xf},'defaultValue':0x0,'comment':_0xb39a8('0x20')},'dialCutDigit':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'validate':{'min':0x0,'max':0xf},'defaultValue':0x0,'comment':_0xb39a8('0x4d')},'dialNoSuchNumberMaxRetry':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0xb39a8('0x2c')},'dialNoSuchNumberRetryFrequency':{'type':Sequelize['INTEGER'](0x5)[_0xb39a8('0x44')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0xb39a8('0x35')},'dialDropMaxRetry':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0xb39a8('0x31')},'dialDropRetryFrequency':{'type':Sequelize[_0xb39a8('0x34')](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0xb39a8('0x3f')},'dialAbandonedMaxRetry':{'type':Sequelize['INTEGER'](0x3)[_0xb39a8('0x44')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':'#Abandoned\x20Retry\x20(min:1,\x20max:999)'},'dialAbandonedRetryFrequency':{'type':Sequelize[_0xb39a8('0x34')](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0xb39a8('0x1f')},'dialMachineMaxRetry':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0xb39a8('0x17')},'dialMachineRetryFrequency':{'type':Sequelize['INTEGER'](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':'Machine\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)'},'dialAgentRejectMaxRetry':{'type':Sequelize[_0xb39a8('0x34')](0x3)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0xb39a8('0x14')},'dialAgentRejectRetryFrequency':{'type':Sequelize['INTEGER'](0x5)[_0xb39a8('0x44')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0xb39a8('0x9')},'mandatoryDispositionPauseId':{'type':Sequelize[_0xb39a8('0x34')],'allowNull':!![],'comment':_0xb39a8('0x3')},'mandatoryDisposition':{'type':Sequelize[_0xb39a8('0x2d')],'defaultValue':![],'comment':_0xb39a8('0x4'),'set':function(_0x51c31b){const _0x45b6cf=_0xb39a8;if(!_0x51c31b)this['setDataValue'](_0x45b6cf('0x37'),null);this[_0x45b6cf('0x18')]('mandatoryDisposition',_0x51c31b);}},'dialPredictiveIntervalMaxThreshold':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'defaultValue':0x14,'validate':{'min':0x1,'max':0x64}},'dialPredictiveIntervalMinThreshold':{'type':Sequelize[_0xb39a8('0x34')](0x3)[_0xb39a8('0x44')],'defaultValue':0xa,'validate':{'min':0x1,'max':0x64}}}; \ No newline at end of file +const a752_0x155c=['#AMD\x20Maximum\x20Number\x20Of\x20Words','Interval\x20Predictive\x20Minutes\x20(min:5\x20max:30)','leavewhenempty','DESC','#Congestion\x20Retry\x20(min:1,\x20max:999)','INTEGER','exports','always','Random\x20Last\x20Digit\x20(min:1,\x20max:15)','getDataValue','BOOLEAN','Dial\x20Method.','FLOAT','outbound','#NoAnswer\x20Retry\x20(min:1,\x20max:999)','07:00-22:00,*,*,*','NoSuchNumber\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','Active/Disactive\x20AMD','Max\x209999\x20channels,\x200\x20means\x20unlimited.','default','#AMD\x20After\x20Greeting\x20Silence','yes','rrmemory','#AMD\x20Between\x20Words\x20Silence','#AgentReject\x20Retry\x20(min:1,\x20max:999)','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','ringall','name','#Busy\x20Retry\x20(min:1,\x20max:999)','#AMD\x20Silence\x20Threshold\x20(min:0,\x20max:32767)','#AMD\x20Total\x20Analysis\x20Time','https://wiki.asterisk.org/wiki/display/AST/Asterisk+13+Application_Queue','predictive','#AMD\x20Maximum\x20Word\x20Length','join','ENUM','inbound','AgentReject\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','setDataValue','NoAnswer\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','booked','joinempty','#Global\x20Max\x20Retry\x20(min:1,\x20max:999)','ASC','acw','split','Cut\x20Digit\x20(min:1,\x20max:15)','progressive','Power\x20Level:\x20Calls\x20for\x20agents\x20(min:1,\x20max:10).','Active/Disactive\x20Recall\x20In\x20Queue','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','Abandoned\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','agentBusyFactor','power','tTxX','rrordered','strategy','TEXT','leastrecent','Active/Disactive\x20Campaign','dialMethod','UNSIGNED','wrapuptime','once','STRING','periodic_announce','#AMD\x20Initial\x20Silence','Queue\x20Timeout\x20Seconds\x20(min:1,\x20max:999)','Machine\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','#Machine\x20Retry\x20(min:1,\x20max:999)','#AMD\x20Min\x20Word\x20Length','never','dropRate','Congestion\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)','mandatoryDisposition','linear','fewestcalls','random','AGI\x20queue\x20option\x20(use:\x20agi://127.0.0.1/square,)','type'];(function(_0xc599d,_0x155c0d){const _0x2ef7c9=function(_0x2f6c12){while(--_0x2f6c12){_0xc599d['push'](_0xc599d['shift']());}};_0x2ef7c9(++_0x155c0d);}(a752_0x155c,0xa1));const a752_0x2ef7=function(_0xc599d,_0x155c0d){_0xc599d=_0xc599d-0x0;let _0x2ef7c9=a752_0x155c[_0xc599d];return _0x2ef7c9;};const _0x5eebcc=a752_0x2ef7;'use strict';const Sequelize=require('sequelize');module[_0x5eebcc('0x5')]={'name':{'type':Sequelize['STRING'],'allowNull':![],'unique':_0x5eebcc('0x1a'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'type':{'type':Sequelize[_0x5eebcc('0x22')](_0x5eebcc('0x23'),_0x5eebcc('0xc')),'allowNull':![],'defaultValue':'inbound'},'musiconhold':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':_0x5eebcc('0x12')},'announce':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':''},'strategy':{'type':Sequelize[_0x5eebcc('0x22')]('rr',_0x5eebcc('0x19'),_0x5eebcc('0x39'),_0x5eebcc('0x4b'),_0x5eebcc('0x4c'),_0x5eebcc('0x15'),_0x5eebcc('0x4a'),'wrandom',_0x5eebcc('0x36')),'allowNull':![],'defaultValue':_0x5eebcc('0x19'),'set':function(_0x2f6c12){const _0x202836=_0x5eebcc;this['setDataValue'](_0x202836('0x37'),_0x2f6c12?_0x2f6c12:'rrmemory');},'get':function(){const _0x97a3ed=_0x5eebcc,_0x31b658=this[_0x97a3ed('0x8')](_0x97a3ed('0x4e')),_0x5e3224=this[_0x97a3ed('0x8')](_0x97a3ed('0x3b')),_0xc81546=this['getDataValue'](_0x97a3ed('0x37'));if(_0x31b658===_0x97a3ed('0x23'))return _0xc81546;if(_0x5e3224===_0x97a3ed('0x27')&&_0xc81546===_0x97a3ed('0x15')||_0x5e3224===_0x97a3ed('0x27')&&_0xc81546==='roundrobin')return _0xc81546;if(_0x5e3224===_0x97a3ed('0x2e')||_0x5e3224===_0x97a3ed('0x1f')||_0x5e3224===_0x97a3ed('0x34'))return _0xc81546;return null;}},'servicelevel':{'type':Sequelize[_0x5eebcc('0x4')](0xb),'defaultValue':0x0},'context':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':null},'penaltymemberslimit':{'type':Sequelize['INTEGER'](0xb)},'timeout':{'type':Sequelize[_0x5eebcc('0x4')](0xb),'defaultValue':0xf},'retry':{'type':Sequelize[_0x5eebcc('0x4')](0xb),'defaultValue':0x2},'timeoutpriority':{'type':Sequelize[_0x5eebcc('0x3f')]},'weight':{'type':Sequelize[_0x5eebcc('0x4')](0xb),'allowNull':!![],'defaultValue':0x0},'wrapuptime':{'type':Sequelize['INTEGER'](0xb),'defaultValue':0x0},'autofill':{'type':Sequelize[_0x5eebcc('0x22')](_0x5eebcc('0x14'),'no'),'defaultValue':_0x5eebcc('0x14')},'autopause':{'type':Sequelize[_0x5eebcc('0x22')](_0x5eebcc('0x14'),'no','all'),'defaultValue':'no'},'autopausedelay':{'type':Sequelize['INTEGER'](0xb)},'autopausebusy':{'type':Sequelize[_0x5eebcc('0x22')](_0x5eebcc('0x14'),'no'),'defaultValue':'no'},'autopauseunavail':{'type':Sequelize['ENUM'](_0x5eebcc('0x14'),'no'),'defaultValue':'no'},'maxlen':{'type':Sequelize['INTEGER'](0xb),'defaultValue':0x0},'setinterfacevar':{'type':Sequelize[_0x5eebcc('0x22')](_0x5eebcc('0x14'),'no'),'defaultValue':'no'},'setqueueentryvar':{'type':Sequelize['ENUM'](_0x5eebcc('0x14'),'no'),'defautValue':'no'},'setqueuevar':{'type':Sequelize['ENUM'](_0x5eebcc('0x14'),'no'),'defaultValue':'no'},'eventmemberstatus':{'type':Sequelize[_0x5eebcc('0x22')](_0x5eebcc('0x14'),'no'),'defaultValue':'no'},'membermacro':{'type':Sequelize[_0x5eebcc('0x3f')],'allowNull':!![]},'membergosub':{'type':Sequelize[_0x5eebcc('0x3f')],'allowNull':!![]},'announce_frequency':{'type':Sequelize[_0x5eebcc('0x4')](0xb),'defaultValue':0x0},'min_announce_frequency':{'type':Sequelize[_0x5eebcc('0x4')](0xb),'defaultValue':0x0},'periodic_announce_frequency':{'type':Sequelize[_0x5eebcc('0x4')](0xb),'defaultValue':0x0},'random_periodic_announce':{'type':Sequelize['ENUM'](_0x5eebcc('0x14'),'no'),'defaultValue':'no'},'relative_periodic_announce':{'type':Sequelize[_0x5eebcc('0x22')](_0x5eebcc('0x14'),'no'),'defaultValue':_0x5eebcc('0x14')},'announce_holdtime':{'type':Sequelize[_0x5eebcc('0x22')](_0x5eebcc('0x14'),'no',_0x5eebcc('0x3e')),'defaultValue':'no'},'announce_position':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':'no'},'announce_to_first_user':{'type':Sequelize[_0x5eebcc('0x22')](_0x5eebcc('0x14'),'no')},'announce_position_limit':{'type':Sequelize[_0x5eebcc('0x4')](0xb)},'announce_round_seconds':{'type':Sequelize[_0x5eebcc('0x22')]('0','5','10','15','20','30'),'defaultValue':'0'},'monitor_format':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':''},'monitor_type':{'type':Sequelize['STRING']},'queue_youarenext':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':null},'queue_thereare':{'type':Sequelize['STRING'],'defaultValue':null},'queue_callswaiting':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':null},'queue_holdtime':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':null},'queue_minute':{'type':Sequelize[_0x5eebcc('0x3f')],'allowNull':!![],'defaultValue':null},'queue_minutes':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':null},'queue_seconds':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':null},'queue_thankyou':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':null},'queue_reporthold':{'type':Sequelize[_0x5eebcc('0x3f')]},'queue_quantity1':{'type':Sequelize['STRING']},'queue_quantity2':{'type':Sequelize['STRING']},'queue_periodic_announce':{'type':Sequelize['STRING']},'queue_less_than':{'type':Sequelize[_0x5eebcc('0x3f')]},'periodic_announce':{'type':Sequelize[_0x5eebcc('0x38')],'set':function(_0x2a7be9){const _0x17d50b=_0x5eebcc;this['setDataValue'](_0x17d50b('0x40'),_0x2a7be9?_0x2a7be9[_0x17d50b('0x21')](','):[]);},'get':function(){const _0x2d7a10=_0x5eebcc;return this[_0x2d7a10('0x8')]('periodic_announce')?this['getDataValue'](_0x2d7a10('0x40'))['split'](','):[];}},'joinempty':{'type':Sequelize['STRING'],'defaultValue':'yes','set':function(_0x3759c2){const _0x30af76=_0x5eebcc;this[_0x30af76('0x25')](_0x30af76('0x28'),_0x3759c2?_0x3759c2['join'](','):undefined);},'get':function(){const _0x1a80d8=_0x5eebcc;return this[_0x1a80d8('0x8')](_0x1a80d8('0x28'))?this['getDataValue'](_0x1a80d8('0x28'))[_0x1a80d8('0x2c')](','):undefined;}},'leavewhenempty':{'type':Sequelize['STRING'],'defaultValue':'no','set':function(_0x33e17d){const _0x38edf0=_0x5eebcc;this[_0x38edf0('0x25')](_0x38edf0('0x1'),_0x33e17d?_0x33e17d[_0x38edf0('0x21')](','):undefined);},'get':function(){const _0x45681a=_0x5eebcc;return this[_0x45681a('0x8')](_0x45681a('0x1'))?this[_0x45681a('0x8')](_0x45681a('0x1'))['split'](','):undefined;}},'reportholdtime':{'type':Sequelize[_0x5eebcc('0x22')]('yes','no'),'defaultValue':'no'},'ringinuse':{'type':Sequelize['ENUM'](_0x5eebcc('0x14'),'no'),'defaultValue':'no'},'memberdelay':{'type':Sequelize[_0x5eebcc('0x4')](0xb),'defaultValue':0x0},'timeoutrestart':{'type':Sequelize['ENUM'](_0x5eebcc('0x14'),'no'),'defaultValue':'no'},'defaultrule':{'type':Sequelize[_0x5eebcc('0x3f')]},'description':{'type':Sequelize[_0x5eebcc('0x3f')]},'acw':{'type':Sequelize[_0x5eebcc('0x9')],'defaultValue':0x0,'set':function(_0xb8ee85){const _0x33f53d=_0x5eebcc;this['setDataValue'](_0x33f53d('0x2b'),_0xb8ee85),_0xb8ee85&&(this['getDataValue'](_0x33f53d('0x3d'))<0x2&&this[_0x33f53d('0x25')](_0x33f53d('0x3d'),0x2));}},'acwTimeout':{'type':Sequelize[_0x5eebcc('0x4')](0xb),'defaultValue':0xa},'dialActive':{'type':Sequelize['BOOLEAN'],'defaultValue':0x0,'comment':_0x5eebcc('0x3a')},'dialMethod':{'type':Sequelize[_0x5eebcc('0x22')]('preview',_0x5eebcc('0x2e'),_0x5eebcc('0x34'),_0x5eebcc('0x1f'),'booked'),'defaultValue':_0x5eebcc('0x2e'),'comment':_0x5eebcc('0xa')},'dialLimitChannel':{'type':Sequelize[_0x5eebcc('0x4')](0x4)['UNSIGNED'],'defaultValue':0x0,'validate':{'min':0x0,'max':0x270f},'comment':_0x5eebcc('0x11')},'dialLimitQueue':{'type':Sequelize['INTEGER'](0x4)[_0x5eebcc('0x3c')],'defaultValue':0x0,'validate':{'min':0x0,'max':0x270f},'comment':'Max\x209999\x20member\x20in\x20queue(min:1,\x20max:9999),\x200\x20means\x20unlimited.'},'dialPowerLevel':{'type':Sequelize[_0x5eebcc('0xb')](0x2)[_0x5eebcc('0x3c')],'defaultValue':0x1,'validate':{'min':0x1,'max':0xa},'comment':_0x5eebcc('0x2f')},'dialPredictiveOptimization':{'type':Sequelize['ENUM'](_0x5eebcc('0x33'),_0x5eebcc('0x47')),'defaultValue':_0x5eebcc('0x47'),'comment':'Only\x20for\x20predictive\x20method.'},'dialPredictiveOptimizationPercentage':{'type':Sequelize[_0x5eebcc('0xb')](0x2)[_0x5eebcc('0x3c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x5f},'comment':'Predictive\x20Optimization\x20Percentage\x20(min:\x201,\x20max:\x2095)'},'dialPredictiveInterval':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0xa,'validate':{'min':0x5,'max':0x1e},'comment':_0x5eebcc('0x0')},'dialOriginateCallerIdName':{'type':Sequelize['STRING']},'dialOriginateCallerIdNumber':{'type':Sequelize[_0x5eebcc('0x3f')]},'dialOriginateTimeout':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0x1e,'validate':{'min':0x1,'max':0x3e7},'comment':'Originate\x20Timeout\x20Seconds\x20(min:1,\x20max:999)'},'dialQueueOptions':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':_0x5eebcc('0x35'),'comment':_0x5eebcc('0x1e')},'dialQueueTimeout':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x5eebcc('0x42')},'dialQueueProject':{'type':Sequelize[_0x5eebcc('0x3f')],'comment':_0x5eebcc('0x4d')},'dialCongestionMaxRetry':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x5eebcc('0x3')},'dialCongestionRetryFrequency':{'type':Sequelize[_0x5eebcc('0x4')](0x5)[_0x5eebcc('0x3c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x5eebcc('0x48')},'dialBusyMaxRetry':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x5eebcc('0x1b')},'dialBusyRetryFrequency':{'type':Sequelize[_0x5eebcc('0x4')](0x5)[_0x5eebcc('0x3c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':'Busy\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)'},'dialNoAnswerMaxRetry':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0x3,'comment':_0x5eebcc('0xd')},'dialNoAnswerRetryFrequency':{'type':Sequelize[_0x5eebcc('0x4')](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x5eebcc('0x26')},'dialGlobalMaxRetry':{'type':Sequelize['INTEGER'](0x3)['UNSIGNED'],'validate':{'min':0x1,'max':0x3e7},'defaultValue':0x4,'comment':_0x5eebcc('0x29')},'dialTimezone':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':null},'dialGlobalInterval':{'type':Sequelize[_0x5eebcc('0x3f')],'defaultValue':_0x5eebcc('0xe')},'dialPrefix':{'type':Sequelize['STRING'],'defaultValue':null},'dialCheckDuplicateType':{'type':Sequelize['ENUM'](_0x5eebcc('0x6'),_0x5eebcc('0x46'),'onlyIfOpen'),'defaultValue':_0x5eebcc('0x6')},'dialAMDActive':{'type':Sequelize['BOOLEAN'],'defaultValue':0x0,'comment':_0x5eebcc('0x10')},'dialAMDInitialSilence':{'type':Sequelize[_0x5eebcc('0x4')](0x9)[_0x5eebcc('0x3c')],'defaultValue':0x9c4,'validate':{'min':0x0},'comment':_0x5eebcc('0x41')},'dialAMDGreeting':{'type':Sequelize[_0x5eebcc('0x4')](0x9)[_0x5eebcc('0x3c')],'defaultValue':0x5dc,'validate':{'min':0x0},'comment':'#AMD\x20Greeting'},'dialAMDAfterGreetingSilence':{'type':Sequelize[_0x5eebcc('0x4')](0x9)[_0x5eebcc('0x3c')],'defaultValue':0x320,'validate':{'min':0x0},'comment':_0x5eebcc('0x13')},'dialAMDTotalAnalysisTime':{'type':Sequelize[_0x5eebcc('0x4')](0x9)[_0x5eebcc('0x3c')],'defaultValue':0x1388,'validate':{'min':0x0},'comment':_0x5eebcc('0x1d')},'dialAMDMinWordLength':{'type':Sequelize[_0x5eebcc('0x4')](0x9)['UNSIGNED'],'defaultValue':0x64,'validate':{'min':0x0},'comment':_0x5eebcc('0x45')},'dialAMDBetweenWordsSilence':{'type':Sequelize[_0x5eebcc('0x4')](0x9)['UNSIGNED'],'defaultValue':0x32,'validate':{'min':0x0},'comment':_0x5eebcc('0x16')},'dialAMDMaximumNumberOfWords':{'type':Sequelize[_0x5eebcc('0x4')](0x9)[_0x5eebcc('0x3c')],'defaultValue':0x3,'validate':{'min':0x0},'comment':_0x5eebcc('0x4f')},'dialAMDSilenceThreshold':{'type':Sequelize[_0x5eebcc('0x4')](0x5)[_0x5eebcc('0x3c')],'validate':{'min':0x0,'max':0x7fff},'defaultValue':0x100,'comment':_0x5eebcc('0x1c')},'dialAMDMaximumWordLength':{'type':Sequelize['INTEGER'](0x9)['UNSIGNED'],'defaultValue':0x1388,'validate':{'min':0x0},'comment':_0x5eebcc('0x20')},'dialRecallMeTimeout':{'type':Sequelize[_0x5eebcc('0x4')](0x5)[_0x5eebcc('0x3c')],'validate':{'min':0x1},'defaultValue':0x1e,'comment':'#RecallMe\x20Timeout\x20(min:1)'},'dialRecallInQueue':{'type':Sequelize[_0x5eebcc('0x9')],'defaultValue':0x0,'comment':_0x5eebcc('0x30')},'dialOrderByScheduledAt':{'type':Sequelize['ENUM'](_0x5eebcc('0x2'),_0x5eebcc('0x2a')),'defaultValue':'DESC'},'dialQueueProject2':{'type':Sequelize[_0x5eebcc('0x3f')],'comment':'AGI\x20queue\x20option\x20(use:\x20agi://127.0.0.1/square,)'},'dialAgiAfterHangupClient':{'type':Sequelize[_0x5eebcc('0x9')],'defaultValue':![]},'dialAgiAfterHangupAgent':{'type':Sequelize[_0x5eebcc('0x9')],'defaultValue':![]},'dialRandomLastDigitCallerIdNumber':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'validate':{'min':0x0,'max':0xf},'defaultValue':0x0,'comment':_0x5eebcc('0x7')},'dialCutDigit':{'type':Sequelize[_0x5eebcc('0x4')](0x3)['UNSIGNED'],'validate':{'min':0x0,'max':0xf},'defaultValue':0x0,'comment':_0x5eebcc('0x2d')},'dialNoSuchNumberMaxRetry':{'type':Sequelize['INTEGER'](0x3)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':'#NoSuchNumber\x20Retry\x20(min:1,\x20max:999)'},'dialNoSuchNumberRetryFrequency':{'type':Sequelize[_0x5eebcc('0x4')](0x5)[_0x5eebcc('0x3c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x5eebcc('0xf')},'dialDropMaxRetry':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':'#Drop\x20Retry\x20(min:1,\x20max:999)'},'dialDropRetryFrequency':{'type':Sequelize[_0x5eebcc('0x4')](0x5)[_0x5eebcc('0x3c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':'Drop\x20Retry\x20Frequency\x20Minutes\x20(min:1,\x20max:99999)'},'dialAbandonedMaxRetry':{'type':Sequelize['INTEGER'](0x3)[_0x5eebcc('0x3c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':'#Abandoned\x20Retry\x20(min:1,\x20max:999)'},'dialAbandonedRetryFrequency':{'type':Sequelize[_0x5eebcc('0x4')](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x5eebcc('0x32')},'dialMachineMaxRetry':{'type':Sequelize[_0x5eebcc('0x4')](0x3)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x5eebcc('0x44')},'dialMachineRetryFrequency':{'type':Sequelize[_0x5eebcc('0x4')](0x5)[_0x5eebcc('0x3c')],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x5eebcc('0x43')},'dialAgentRejectMaxRetry':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x5eebcc('0x17')},'dialAgentRejectRetryFrequency':{'type':Sequelize[_0x5eebcc('0x4')](0x5)['UNSIGNED'],'validate':{'min':0x1,'max':0x1869f},'defaultValue':0x96,'comment':_0x5eebcc('0x24')},'mandatoryDispositionPauseId':{'type':Sequelize[_0x5eebcc('0x4')],'allowNull':!![],'comment':_0x5eebcc('0x31')},'mandatoryDisposition':{'type':Sequelize[_0x5eebcc('0x9')],'defaultValue':![],'comment':_0x5eebcc('0x18'),'set':function(_0x54a136){const _0x41d46d=_0x5eebcc;if(!_0x54a136)this[_0x41d46d('0x25')]('mandatoryDispositionPauseId',null);this[_0x41d46d('0x25')](_0x41d46d('0x49'),_0x54a136);}},'dialPredictiveIntervalMaxThreshold':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0x14,'validate':{'min':0x1,'max':0x64}},'dialPredictiveIntervalMinThreshold':{'type':Sequelize[_0x5eebcc('0x4')](0x3)[_0x5eebcc('0x3c')],'defaultValue':0xa,'validate':{'min':0x1,'max':0x64}}}; \ No newline at end of file diff --git a/server/api/voiceQueue/voiceQueue.controller.js b/server/api/voiceQueue/voiceQueue.controller.js index 94e6bcc..69a9d8a 100644 --- a/server/api/voiceQueue/voiceQueue.controller.js +++ b/server/api/voiceQueue/voiceQueue.controller.js @@ -1 +1 @@ -const a753_0xabb7=['removeAgents','../../components/parsers/qs','from','getHopperFinals','updatedAt','VIRTUAL','body','QueueCampaigns','ut.UserId\x20=\x20?','addAgents','intersection','userVoiceQueue:save','forEach','CmListId','getHoppers','user_has_teams','autoAssociation','../../rediscache','update','getTeams','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','findOrCreate','CmHopperBlack','phone\x20NOT\x20IN\x20(?)','count','getHopperBlacks','error','into','register','format','sequelize','rows','like','value','name','VoiceQueueId\x20=\x20?','catch','addBlackLists','phone\x20IS\x20NOT\x20NULL','deletedAt\x20IS\x20NULL','CmHopperHistory','limit','role','removeBlackLists','./voiceQueue.socket','lodash','ContactId','scheduledAt','includes','sendStatus','isArray','undefined','create','emit','send','UserVoiceQueue','findAll','includeAll','NOW()','then','removeLists','Team','SIP/%s','online','cm_hopper','field','cm_contacts','filter','Agents','CmHopper','key','merge','status','getBlackLists','clone','query','getLists','User','Content-Range','../../mysqldb','transaction','penalty','select','inbound','CmList','options','teams','omit','userVoiceQueue:remove','UserProfileSection','length','every','fieldName','attributes','ListId\x20=\x20?','toString','params','where','map','each','isNil','../../config/logger','model','end','api','COALESCE(phone,\x27\x27)','UserVoiceQueueRt','json','user','VoiceQueues','all','findOne','addTeams','type','tq.TeamId','fromQuery','TeamId','util','pick','rawAttributes','index','userProfileId','interface','filters','union','insert','dialCheckDuplicateType','offset','ids','phone','find','CmHopperFinal','nolimit','order','VoiceQueueId','destroy','join','voicePause','ListId','createdAt','addLists','flatMap','team_has_voice_queues','VoiceQueue','push','keys','get','getMembers','outbound','UserProfileResource','isEmpty','always','include','fields','getAgents','sort'];(function(_0x49e68a,_0xabb725){const _0x1193b7=function(_0x3fc1ae){while(--_0x3fc1ae){_0x49e68a['push'](_0x49e68a['shift']());}};_0x1193b7(++_0xabb725);}(a753_0xabb7,0x8f));const a753_0x1193=function(_0x49e68a,_0xabb725){_0x49e68a=_0x49e68a-0x0;let _0x1193b7=a753_0xabb7[_0x49e68a];return _0x1193b7;};const _0xbd745f=a753_0x1193;'use strict';const util=require(_0xbd745f('0x82')),_=require(_0xbd745f('0x3a')),squel=require('squel'),qs=require(_0xbd745f('0xe')),logger=require(_0xbd745f('0x72'))(_0xbd745f('0x75')),{getSocket}=require(_0xbd745f('0x1e')),socket=getSocket(),db=require(_0xbd745f('0x5c'))['db'],{Op,QueryTypes}=require(_0xbd745f('0x2b'));require(_0xbd745f('0x39'))[_0xbd745f('0x29')](socket);function respondWithStatusCode(_0x3fc1ae,_0x20ea4a){return _0x20ea4a=_0x20ea4a||0xcc,function(_0x4fff2b){const _0x16a775=a753_0x1193;if(_0x4fff2b)return _0x3fc1ae[_0x16a775('0x3e')](_0x20ea4a);return _0x3fc1ae[_0x16a775('0x55')](_0x20ea4a)[_0x16a775('0x74')]();};}function respondWithResult(_0x1a120c,_0x419765){return _0x419765=_0x419765||0xc8,function(_0x556d67){const _0x47a6b4=a753_0x1193;if(_0x556d67)return _0x1a120c[_0x47a6b4('0x55')](_0x419765)[_0x47a6b4('0x78')](_0x556d67);};}function respondWithFilteredResult(_0xccec17,_0x2abb13){return function(_0x52cd08){const _0x5a1179=a753_0x1193;if(_0x52cd08){const _0x3ed5ba=_0x52cd08['count'],_0x3bd4ec=_0x2abb13[_0x5a1179('0x8c')];let _0x4196b9=_0x2abb13[_0x5a1179('0x8c')]+_0x2abb13['limit'],_0x32e022;return _0x4196b9>=_0x3ed5ba?(_0x4196b9=_0x3ed5ba,_0x32e022=0xc8):_0x32e022=0xce,_0xccec17[_0x5a1179('0x55')](_0x32e022),_0xccec17['set'](_0x5a1179('0x5b'),_0x3bd4ec+'-'+_0x4196b9+'/'+_0x3ed5ba)[_0x5a1179('0x78')](_0x52cd08);}return null;};}function saveUpdates(_0x8d9331){return function(_0x228419){const _0x4bb30c=a753_0x1193;if(_0x228419)return _0x228419[_0x4bb30c('0x1f')](_0x8d9331)['then'](function(_0x4f2ae5){return _0x4f2ae5;});return null;};}function removeEntity(_0x17ca51){return function(_0x8e12bf){const _0x5b15bf=a753_0x1193;if(_0x8e12bf)return _0x8e12bf[_0x5b15bf('0x94')]()['then'](function(){const _0x502814=_0x5b15bf,_0x458ccb=_0x8e12bf[_0x502814('0x3')]({'plain':!![]}),_0x55c3db=[{'name':_0x502814('0x7a'),'value':'inbound','ignore':![]},{'name':_0x502814('0x14'),'value':_0x502814('0x5'),'ignore':![]}],_0x262587=_(_0x55c3db)[_0x502814('0x50')]('ignore')[_0x502814('0x6f')](_0x502814('0x2e'))[_0x502814('0x2e')]();if(_[_0x502814('0x3d')](_0x262587,_0x458ccb[_0x502814('0x7e')]))return;const _0x2aeddc=_['find'](_0x55c3db,[_0x502814('0x2e'),_0x458ccb[_0x502814('0x7e')]])[_0x502814('0x2f')];return db[_0x502814('0x6')]['destroy']({'where':{'type':_0x2aeddc,'resourceId':_0x458ccb['id']}})[_0x502814('0x48')](function(){return _0x8e12bf;});})['then'](function(){const _0x2e4a84=_0x5b15bf;_0x17ca51[_0x2e4a84('0x55')](0xcc)[_0x2e4a84('0x74')]();});};}function handleEntityNotFound(_0x5875f4){return function(_0x1b99d6){return!_0x1b99d6&&_0x5875f4['sendStatus'](0x194),_0x1b99d6;};}function handleError(_0x3a4156,_0x2e122c){return _0x2e122c=_0x2e122c||0x1f4,function(_0x3c0237){const _0x1b4470=a753_0x1193;logger[_0x1b4470('0x27')](_0x3c0237['stack']),_0x3c0237[_0x1b4470('0x2f')]&&delete _0x3c0237[_0x1b4470('0x2f')],_0x3a4156[_0x1b4470('0x55')](_0x2e122c)[_0x1b4470('0x43')](_0x3c0237);};}exports[_0xbd745f('0x85')]=function(_0x3fe789,_0xb7a29){const _0x514f95=_0xbd745f;let _0x7bece5={};const _0x328631={},_0x1f2970={'count':0x0,'rows':[]},_0x732e54=_['map'](db[_0x514f95('0x0')]['rawAttributes'],function(_0x517291){const _0x3cf148=_0x514f95;return{'name':_0x517291[_0x3cf148('0x69')],'type':_0x517291[_0x3cf148('0x7e')][_0x3cf148('0x53')]};});_0x328631[_0x514f95('0x73')]=_[_0x514f95('0x6f')](_0x732e54,_0x514f95('0x2f')),_0x328631[_0x514f95('0x58')]=_[_0x514f95('0x2')](_0x3fe789['query']),_0x328631[_0x514f95('0x88')]=_['intersection'](_0x328631[_0x514f95('0x73')],_0x328631[_0x514f95('0x58')]),_0x7bece5[_0x514f95('0x6a')]=_['intersection'](_0x328631[_0x514f95('0x73')],qs[_0x514f95('0xa')](_0x3fe789[_0x514f95('0x58')][_0x514f95('0xa')])),_0x7bece5[_0x514f95('0x6a')]=_0x7bece5[_0x514f95('0x6a')]['length']?_0x7bece5[_0x514f95('0x6a')]:_0x328631[_0x514f95('0x73')];typeof _0x3fe789['query']['nolimit']===_0x514f95('0x40')&&(_0x7bece5[_0x514f95('0x36')]=qs[_0x514f95('0x36')](_0x3fe789['query'][_0x514f95('0x36')]),_0x7bece5[_0x514f95('0x8c')]=qs[_0x514f95('0x8c')](_0x3fe789[_0x514f95('0x58')][_0x514f95('0x8c')]));_0x7bece5[_0x514f95('0x92')]=qs[_0x514f95('0xc')](_0x3fe789[_0x514f95('0x58')][_0x514f95('0xc')]),_0x7bece5[_0x514f95('0x6e')]=qs['filters'](_['pick'](_0x3fe789[_0x514f95('0x58')],_0x328631['filters']),_0x732e54);_0x3fe789[_0x514f95('0x58')][_0x514f95('0x50')]&&(_0x7bece5[_0x514f95('0x6e')]=_[_0x514f95('0x54')](_0x7bece5[_0x514f95('0x6e')],{[Op['or']]:_[_0x514f95('0x6f')](_0x732e54,function(_0x4032df){const _0x46eea9=_0x514f95;if(_0x4032df[_0x46eea9('0x7e')]!==_0x46eea9('0x12')){const _0x3452d3={};return _0x3452d3[_0x4032df[_0x46eea9('0x2f')]]={[Op[_0x46eea9('0x2d')]]:'%'+_0x3fe789['query'][_0x46eea9('0x50')]+'%'},_0x3452d3;}})}));_0x7bece5=_['merge']({},_0x7bece5,_0x3fe789['options']);const _0x428f6d={'where':_0x7bece5['where']};return db[_0x514f95('0x0')][_0x514f95('0x25')](_0x428f6d)[_0x514f95('0x48')](function(_0x66f163){const _0x1093b6=_0x514f95;return _0x1f2970['count']=_0x66f163,_0x3fe789[_0x1093b6('0x58')][_0x1093b6('0x46')]&&(_0x7bece5['include']=[{'all':!![]}]),db[_0x1093b6('0x0')][_0x1093b6('0x45')](_0x7bece5);})[_0x514f95('0x48')](function(_0x25bb51){const _0x1aa143=_0x514f95;return _0x1f2970[_0x1aa143('0x2c')]=_0x25bb51,_0x1f2970;})[_0x514f95('0x48')](respondWithFilteredResult(_0xb7a29,_0x7bece5))[_0x514f95('0x31')](handleError(_0xb7a29,null));},exports['show']=function(_0x17aaa8,_0x1814a4){const _0x1abcb1=_0xbd745f;let _0x447e08={'raw':![],'where':{'id':_0x17aaa8[_0x1abcb1('0x6d')]['id']}};const _0x4ed525={};return _0x4ed525[_0x1abcb1('0x73')]=_['keys'](db[_0x1abcb1('0x0')][_0x1abcb1('0x84')]),_0x4ed525[_0x1abcb1('0x58')]=_[_0x1abcb1('0x2')](_0x17aaa8[_0x1abcb1('0x58')]),_0x4ed525[_0x1abcb1('0x88')]=_[_0x1abcb1('0x17')](_0x4ed525[_0x1abcb1('0x73')],_0x4ed525['query']),_0x447e08['attributes']=_[_0x1abcb1('0x17')](_0x4ed525[_0x1abcb1('0x73')],qs['fields'](_0x17aaa8[_0x1abcb1('0x58')]['fields'])),_0x447e08[_0x1abcb1('0x6a')]=_0x447e08[_0x1abcb1('0x6a')]['length']?_0x447e08[_0x1abcb1('0x6a')]:_0x4ed525['model'],_0x17aaa8['query'][_0x1abcb1('0x46')]&&(_0x447e08[_0x1abcb1('0x9')]=[{'all':!![]}]),_0x447e08=_[_0x1abcb1('0x54')]({},_0x447e08,_0x17aaa8[_0x1abcb1('0x62')]),db[_0x1abcb1('0x0')][_0x1abcb1('0x7c')](_0x447e08)[_0x1abcb1('0x48')](handleEntityNotFound(_0x1814a4,null))['then'](respondWithResult(_0x1814a4,null))['catch'](handleError(_0x1814a4,null));},exports[_0xbd745f('0x41')]=function(_0x19f006,_0x594a26){const _0x8f71ef=_0xbd745f;return db[_0x8f71ef('0x0')][_0x8f71ef('0x41')](_0x19f006[_0x8f71ef('0x13')],{})[_0x8f71ef('0x48')](function(_0x3e2ec8){const _0x44c92d=_0x8f71ef,_0x4a0dcb=_0x19f006[_0x44c92d('0x79')][_0x44c92d('0x3')]({'plain':!![]});if(!_0x4a0dcb)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x4a0dcb['role']==='user'){const _0x3f9062=_0x3e2ec8[_0x44c92d('0x3')]({'plain':!![]}),_0x4733d1=[{'name':_0x44c92d('0x7a'),'value':_0x44c92d('0x60')},{'name':'QueueCampaigns','value':'outbound'}],_0x26ea80=_['find'](_0x4733d1,[_0x44c92d('0x2e'),_0x3f9062[_0x44c92d('0x7e')]])[_0x44c92d('0x2f')];return db[_0x44c92d('0x66')][_0x44c92d('0x7c')]({'where':{'name':_0x26ea80,'userProfileId':_0x4a0dcb['userProfileId']},'raw':!![]})[_0x44c92d('0x48')](function(_0x47eaaf){const _0x59a138=_0x44c92d;return _0x47eaaf&&_0x47eaaf[_0x59a138('0x1d')]===0x0?db[_0x59a138('0x6')]['create']({'name':_0x3f9062[_0x59a138('0x2f')],'resourceId':_0x3f9062['id'],'type':_0x47eaaf['name'],'sectionId':_0x47eaaf['id']},{})[_0x59a138('0x48')](function(){return _0x3e2ec8;}):_0x3e2ec8;})[_0x44c92d('0x31')](function(_0x3fc734){const _0x3f1eda=_0x44c92d;logger['error'](_0x3f1eda('0x21'),_0x3fc734);throw _0x3fc734;});}return _0x3e2ec8;})[_0x8f71ef('0x48')](respondWithResult(_0x594a26,0xc9))[_0x8f71ef('0x31')](handleError(_0x594a26,null));},exports[_0xbd745f('0x57')]=function(_0x223d7b,_0x26c651){const _0x48d183=_0xbd745f;let _0x41580e={'where':{'id':_0x223d7b['params']['id']}};const _0x63af6={};return _0x63af6[_0x48d183('0x73')]=_[_0x48d183('0x2')](db[_0x48d183('0x0')][_0x48d183('0x84')]),_0x41580e[_0x48d183('0x6a')]=_[_0x48d183('0x17')](_0x63af6[_0x48d183('0x73')],qs[_0x48d183('0xa')](_0x223d7b['query'][_0x48d183('0xa')])),_0x41580e[_0x48d183('0x6a')]=_0x41580e[_0x48d183('0x6a')][_0x48d183('0x67')]?_0x41580e[_0x48d183('0x6a')]:_0x63af6[_0x48d183('0x73')],_0x223d7b[_0x48d183('0x58')][_0x48d183('0x46')]&&(_0x41580e[_0x48d183('0x9')]=[{'all':!![]}]),_0x41580e=_[_0x48d183('0x54')]({},_0x41580e,_0x223d7b[_0x48d183('0x62')]),db[_0x48d183('0x0')][_0x48d183('0x7c')](_0x41580e)[_0x48d183('0x48')](handleEntityNotFound(_0x26c651,null))[_0x48d183('0x48')](function(_0xaf9c0e){const _0x1e0087=_0x48d183;if(_0xaf9c0e){let _0x3a852f=_0xaf9c0e[_0x1e0087('0x3')]({'plain':!![]});return _0x3a852f=qs[_0x1e0087('0x64')](_0x3a852f,['id','createdAt',_0x1e0087('0x11')]),_0x223d7b[_0x1e0087('0x13')]=_[_0x1e0087('0x64')](_0x223d7b[_0x1e0087('0x13')],['id',_0x1e0087('0x98'),'updatedAt']),db[_0x1e0087('0x0')][_0x1e0087('0x41')](_['merge'](_0x3a852f,_0x223d7b['body']),{'include':_0x223d7b[_0x1e0087('0x58')]['includeAll']?[{'all':!![]}]:undefined})[_0x1e0087('0x48')](function(_0x5e2c7a){const _0x263556=_0x1e0087,_0x1979c2=_0x223d7b[_0x263556('0x79')][_0x263556('0x3')]({'plain':!![]});if(!_0x1979c2)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x1979c2[_0x263556('0x37')]==='user'){const _0x5a6d37=_0x5e2c7a[_0x263556('0x3')]({'plain':!![]}),_0x26250b=[{'name':'VoiceQueues','value':_0x263556('0x60')},{'name':_0x263556('0x14'),'value':_0x263556('0x5')}],_0x3a4db4=_[_0x263556('0x8f')](_0x26250b,[_0x263556('0x2e'),_0x5a6d37[_0x263556('0x7e')]])[_0x263556('0x2f')];return db[_0x263556('0x66')][_0x263556('0x7c')]({'where':{'name':_0x3a4db4,'userProfileId':_0x1979c2[_0x263556('0x86')]},'raw':!![]})[_0x263556('0x48')](function(_0x7febd3){const _0x389406=_0x263556;return _0x7febd3&&_0x7febd3[_0x389406('0x1d')]===0x0?db['UserProfileResource'][_0x389406('0x41')]({'name':_0x5a6d37[_0x389406('0x2f')],'resourceId':_0x5a6d37['id'],'type':_0x7febd3[_0x389406('0x2f')],'sectionId':_0x7febd3['id']},{})['then'](function(){return _0x5e2c7a;}):_0x5e2c7a;})[_0x263556('0x31')](function(_0x4f651e){const _0x5b76dc=_0x263556;logger['error'](_0x5b76dc('0x21'),_0x4f651e);throw _0x4f651e;});}return _0x5e2c7a;});}})[_0x48d183('0x48')](respondWithResult(_0x26c651,0xc9))['catch'](handleError(_0x26c651,null));},exports[_0xbd745f('0x1f')]=function(_0x5e9ce5,_0x35cdaa){const _0x578bb4=_0xbd745f;return _0x5e9ce5['body']['id']&&delete _0x5e9ce5[_0x578bb4('0x13')]['id'],db['VoiceQueue']['findOne']({'where':{'id':_0x5e9ce5['params']['id']}})[_0x578bb4('0x48')](handleEntityNotFound(_0x35cdaa,null))[_0x578bb4('0x48')](saveUpdates(_0x5e9ce5[_0x578bb4('0x13')],null))[_0x578bb4('0x48')](respondWithResult(_0x35cdaa,null))[_0x578bb4('0x31')](handleError(_0x35cdaa,null));},exports[_0xbd745f('0x94')]=function(_0x2e868d,_0x437479){const _0x4a7962=_0xbd745f;return db['VoiceQueue'][_0x4a7962('0x7c')]({'where':{'id':_0x2e868d[_0x4a7962('0x6d')]['id']}})[_0x4a7962('0x48')](handleEntityNotFound(_0x437479,null))[_0x4a7962('0x48')](removeEntity(_0x437479,null))[_0x4a7962('0x31')](handleError(_0x437479,null));},exports[_0xbd745f('0x1b')]=function(_0x554c55,_0xa795c1){const _0x29dbff=_0xbd745f;let _0x4bfb7b={'raw':![],'where':{}};const _0x1702c3={},_0x16cb86={'count':0x0,'rows':[]};return db[_0x29dbff('0x0')]['findOne']({'where':{'id':_0x554c55['params']['id']}})['then'](handleEntityNotFound(_0xa795c1,null))[_0x29dbff('0x48')](function(_0xa777d0){const _0x47ce42=_0x29dbff;if(_0xa777d0)return _0x1702c3[_0x47ce42('0x73')]=_[_0x47ce42('0x2')](db['CmHopper']['rawAttributes']),_0x1702c3[_0x47ce42('0x58')]=_[_0x47ce42('0x2')](_0x554c55[_0x47ce42('0x58')]),_0x1702c3['filters']=_[_0x47ce42('0x17')](_0x1702c3['model'],_0x1702c3[_0x47ce42('0x58')]),_0x4bfb7b['attributes']=_[_0x47ce42('0x17')](_0x1702c3['model'],qs[_0x47ce42('0xa')](_0x554c55['query']['fields'])),_0x4bfb7b['attributes']=_0x4bfb7b['attributes']['length']?_0x4bfb7b['attributes']:_0x1702c3[_0x47ce42('0x73')],typeof _0x554c55[_0x47ce42('0x58')]['nolimit']===_0x47ce42('0x40')&&(_0x4bfb7b['limit']=qs[_0x47ce42('0x36')](_0x554c55[_0x47ce42('0x58')]['limit']),_0x4bfb7b['offset']=qs[_0x47ce42('0x8c')](_0x554c55[_0x47ce42('0x58')][_0x47ce42('0x8c')])),_0x4bfb7b['order']=qs[_0x47ce42('0xc')](_0x554c55[_0x47ce42('0x58')][_0x47ce42('0xc')]),_0x4bfb7b[_0x47ce42('0x6e')]=qs[_0x47ce42('0x88')](_['pick'](_0x554c55[_0x47ce42('0x58')],_0x1702c3[_0x47ce42('0x88')])),_0x4bfb7b[_0x47ce42('0x6e')][_0x47ce42('0x93')]=_0xa777d0['id'],_0x554c55['query'][_0x47ce42('0x50')]&&(_0x4bfb7b['where']=_[_0x47ce42('0x54')](_0x4bfb7b[_0x47ce42('0x6e')],{[Op['or']]:_[_0x47ce42('0x6f')](_0x4bfb7b[_0x47ce42('0x6a')],function(_0x27131a){const _0xd8d431=_0x47ce42,_0x122a88={};return _0x122a88[_0x27131a]={[Op['like']]:'%'+_0x554c55['query'][_0xd8d431('0x50')]+'%'},_0x122a88;})})),_0x4bfb7b=_[_0x47ce42('0x54')]({},_0x4bfb7b,_0x554c55[_0x47ce42('0x62')]),db[_0x47ce42('0x52')]['count']({'where':_0x4bfb7b[_0x47ce42('0x6e')]})[_0x47ce42('0x48')](function(_0x190539){const _0xa35dda=_0x47ce42;return _0x16cb86[_0xa35dda('0x25')]=_0x190539,_0x554c55[_0xa35dda('0x58')][_0xa35dda('0x46')]&&(_0x4bfb7b['include']=[{'all':!![]}]),db[_0xa35dda('0x52')][_0xa35dda('0x45')](_0x4bfb7b);})['then'](function(_0x550191){const _0x2d557a=_0x47ce42;return _0x16cb86[_0x2d557a('0x2c')]=_0x550191,_0x16cb86;});})[_0x29dbff('0x48')](respondWithFilteredResult(_0xa795c1,_0x4bfb7b))['catch'](handleError(_0xa795c1,null));},exports['getHopperHistories']=function(_0x52ac5f,_0x4b1728){const _0x4b6db1=_0xbd745f;let _0x477474={'raw':!![],'where':{}};const _0x1abd8c={},_0x2a96ea={'count':0x0,'rows':[]};return db[_0x4b6db1('0x0')][_0x4b6db1('0x7c')]({'where':{'id':_0x52ac5f[_0x4b6db1('0x6d')]['id']}})[_0x4b6db1('0x48')](handleEntityNotFound(_0x4b1728,null))[_0x4b6db1('0x48')](function(_0x27ebf){const _0x4f82b0=_0x4b6db1;if(_0x27ebf)return _0x1abd8c[_0x4f82b0('0x73')]=_['keys'](db[_0x4f82b0('0x35')][_0x4f82b0('0x84')]),_0x1abd8c[_0x4f82b0('0x58')]=_[_0x4f82b0('0x2')](_0x52ac5f[_0x4f82b0('0x58')]),_0x1abd8c[_0x4f82b0('0x88')]=_[_0x4f82b0('0x17')](_0x1abd8c[_0x4f82b0('0x73')],_0x1abd8c[_0x4f82b0('0x58')]),_0x477474[_0x4f82b0('0x6a')]=_['intersection'](_0x1abd8c[_0x4f82b0('0x73')],qs[_0x4f82b0('0xa')](_0x52ac5f['query'][_0x4f82b0('0xa')])),_0x477474[_0x4f82b0('0x6a')]=_0x477474[_0x4f82b0('0x6a')][_0x4f82b0('0x67')]?_0x477474[_0x4f82b0('0x6a')]:_0x1abd8c['model'],typeof _0x52ac5f[_0x4f82b0('0x58')]['nolimit']===_0x4f82b0('0x40')&&(_0x477474[_0x4f82b0('0x36')]=qs[_0x4f82b0('0x36')](_0x52ac5f[_0x4f82b0('0x58')][_0x4f82b0('0x36')]),_0x477474[_0x4f82b0('0x8c')]=qs['offset'](_0x52ac5f[_0x4f82b0('0x58')][_0x4f82b0('0x8c')])),_0x477474[_0x4f82b0('0x92')]=qs[_0x4f82b0('0xc')](_0x52ac5f[_0x4f82b0('0x58')][_0x4f82b0('0xc')]),_0x477474[_0x4f82b0('0x6e')]=qs[_0x4f82b0('0x88')](_[_0x4f82b0('0x83')](_0x52ac5f[_0x4f82b0('0x58')],_0x1abd8c['filters'])),_0x477474[_0x4f82b0('0x6e')][_0x4f82b0('0x93')]=_0x27ebf['id'],_0x52ac5f[_0x4f82b0('0x58')][_0x4f82b0('0x50')]&&(_0x477474['where']=_[_0x4f82b0('0x54')](_0x477474['where'],{[Op['or']]:_[_0x4f82b0('0x6f')](_0x477474['attributes'],function(_0x3bd448){const _0x5282ca=_0x4f82b0,_0x47e6f1={};return _0x47e6f1[_0x3bd448]={[Op[_0x5282ca('0x2d')]]:'%'+_0x52ac5f[_0x5282ca('0x58')]['filter']+'%'},_0x47e6f1;})})),_0x477474=_['merge']({},_0x477474,_0x52ac5f['options']),db[_0x4f82b0('0x35')][_0x4f82b0('0x25')]({'where':_0x477474[_0x4f82b0('0x6e')]})[_0x4f82b0('0x48')](function(_0x11ac82){const _0x12cd90=_0x4f82b0;return _0x2a96ea[_0x12cd90('0x25')]=_0x11ac82,_0x52ac5f[_0x12cd90('0x58')][_0x12cd90('0x46')]&&(_0x477474['include']=[{'all':!![]}]),db[_0x12cd90('0x35')][_0x12cd90('0x45')](_0x477474);})['then'](function(_0x2f3d81){return _0x2a96ea['rows']=_0x2f3d81,_0x2a96ea;});})[_0x4b6db1('0x48')](respondWithFilteredResult(_0x4b1728,_0x477474))['catch'](handleError(_0x4b1728,null));},exports[_0xbd745f('0x10')]=function(_0x18c142,_0x5774ad){const _0x4df612=_0xbd745f;let _0x24e653={'raw':!![],'where':{}};const _0x426d82={},_0x2926d1={'count':0x0,'rows':[]};return db[_0x4df612('0x0')]['findOne']({'where':{'id':_0x18c142[_0x4df612('0x6d')]['id']}})[_0x4df612('0x48')](handleEntityNotFound(_0x5774ad,null))[_0x4df612('0x48')](function(_0x46119a){const _0x3c8e1f=_0x4df612;if(_0x46119a)return _0x426d82[_0x3c8e1f('0x73')]=_[_0x3c8e1f('0x2')](db[_0x3c8e1f('0x90')]['rawAttributes']),_0x426d82[_0x3c8e1f('0x58')]=_[_0x3c8e1f('0x2')](_0x18c142[_0x3c8e1f('0x58')]),_0x426d82[_0x3c8e1f('0x88')]=_['intersection'](_0x426d82[_0x3c8e1f('0x73')],_0x426d82[_0x3c8e1f('0x58')]),_0x24e653['attributes']=_[_0x3c8e1f('0x17')](_0x426d82['model'],qs[_0x3c8e1f('0xa')](_0x18c142[_0x3c8e1f('0x58')][_0x3c8e1f('0xa')])),_0x24e653['attributes']=_0x24e653[_0x3c8e1f('0x6a')]['length']?_0x24e653[_0x3c8e1f('0x6a')]:_0x426d82[_0x3c8e1f('0x73')],typeof _0x18c142['query'][_0x3c8e1f('0x91')]==='undefined'&&(_0x24e653[_0x3c8e1f('0x36')]=qs[_0x3c8e1f('0x36')](_0x18c142[_0x3c8e1f('0x58')][_0x3c8e1f('0x36')]),_0x24e653[_0x3c8e1f('0x8c')]=qs[_0x3c8e1f('0x8c')](_0x18c142[_0x3c8e1f('0x58')][_0x3c8e1f('0x8c')])),_0x24e653[_0x3c8e1f('0x92')]=qs[_0x3c8e1f('0xc')](_0x18c142['query'][_0x3c8e1f('0xc')]),_0x24e653[_0x3c8e1f('0x6e')]=qs['filters'](_[_0x3c8e1f('0x83')](_0x18c142['query'],_0x426d82[_0x3c8e1f('0x88')])),_0x24e653[_0x3c8e1f('0x6e')][_0x3c8e1f('0x93')]=_0x46119a['id'],_0x18c142['query'][_0x3c8e1f('0x50')]&&(_0x24e653[_0x3c8e1f('0x6e')]=_['merge'](_0x24e653[_0x3c8e1f('0x6e')],{[Op['or']]:_[_0x3c8e1f('0x6f')](_0x24e653[_0x3c8e1f('0x6a')],function(_0x45197f){const _0x15bbf1=_0x3c8e1f,_0x19d057={};return _0x19d057[_0x45197f]={[Op[_0x15bbf1('0x2d')]]:'%'+_0x18c142[_0x15bbf1('0x58')]['filter']+'%'},_0x19d057;})})),_0x24e653=_[_0x3c8e1f('0x54')]({},_0x24e653,_0x18c142[_0x3c8e1f('0x62')]),db[_0x3c8e1f('0x90')][_0x3c8e1f('0x25')]({'where':_0x24e653[_0x3c8e1f('0x6e')]})[_0x3c8e1f('0x48')](function(_0x231935){const _0x32f699=_0x3c8e1f;return _0x2926d1[_0x32f699('0x25')]=_0x231935,_0x18c142[_0x32f699('0x58')][_0x32f699('0x46')]&&(_0x24e653['include']=[{'all':!![]}]),db[_0x32f699('0x90')][_0x32f699('0x45')](_0x24e653);})[_0x3c8e1f('0x48')](function(_0x259397){const _0x10fc20=_0x3c8e1f;return _0x2926d1[_0x10fc20('0x2c')]=_0x259397,_0x2926d1;});})[_0x4df612('0x48')](respondWithFilteredResult(_0x5774ad,_0x24e653))[_0x4df612('0x31')](handleError(_0x5774ad,null));},exports[_0xbd745f('0x26')]=function(_0x3fcf96,_0x257a3a){const _0xb6042d=_0xbd745f;let _0x577bff={'raw':!![],'where':{}};const _0x2195e3={},_0x41bcc4={'count':0x0,'rows':[]};return db['VoiceQueue'][_0xb6042d('0x7c')]({'where':{'id':_0x3fcf96[_0xb6042d('0x6d')]['id']}})[_0xb6042d('0x48')](handleEntityNotFound(_0x257a3a,null))[_0xb6042d('0x48')](function(_0xca4b4b){const _0x39a999=_0xb6042d;if(_0xca4b4b)return _0x2195e3['model']=_[_0x39a999('0x2')](db[_0x39a999('0x23')][_0x39a999('0x84')]),_0x2195e3[_0x39a999('0x58')]=_[_0x39a999('0x2')](_0x3fcf96[_0x39a999('0x58')]),_0x2195e3[_0x39a999('0x88')]=_[_0x39a999('0x17')](_0x2195e3['model'],_0x2195e3['query']),_0x577bff[_0x39a999('0x6a')]=_['intersection'](_0x2195e3[_0x39a999('0x73')],qs['fields'](_0x3fcf96[_0x39a999('0x58')]['fields'])),_0x577bff[_0x39a999('0x6a')]=_0x577bff[_0x39a999('0x6a')][_0x39a999('0x67')]?_0x577bff[_0x39a999('0x6a')]:_0x2195e3[_0x39a999('0x73')],typeof _0x3fcf96[_0x39a999('0x58')][_0x39a999('0x91')]==='undefined'&&(_0x577bff[_0x39a999('0x36')]=qs[_0x39a999('0x36')](_0x3fcf96[_0x39a999('0x58')][_0x39a999('0x36')]),_0x577bff[_0x39a999('0x8c')]=qs[_0x39a999('0x8c')](_0x3fcf96[_0x39a999('0x58')]['offset'])),_0x577bff['order']=qs[_0x39a999('0xc')](_0x3fcf96[_0x39a999('0x58')][_0x39a999('0xc')]),_0x577bff[_0x39a999('0x6e')]=qs[_0x39a999('0x88')](_[_0x39a999('0x83')](_0x3fcf96[_0x39a999('0x58')],_0x2195e3[_0x39a999('0x88')])),_0x577bff['where'][_0x39a999('0x93')]=_0xca4b4b['id'],_0x3fcf96[_0x39a999('0x58')]['filter']&&(_0x577bff[_0x39a999('0x6e')]=_['merge'](_0x577bff['where'],{[Op['or']]:_[_0x39a999('0x6f')](_0x577bff[_0x39a999('0x6a')],function(_0xdcaccc){const _0x59c08b=_0x39a999,_0x4103ed={};return _0x4103ed[_0xdcaccc]={[Op[_0x59c08b('0x2d')]]:'%'+_0x3fcf96['query'][_0x59c08b('0x50')]+'%'},_0x4103ed;})})),_0x577bff=_[_0x39a999('0x54')]({},_0x577bff,_0x3fcf96[_0x39a999('0x62')]),db[_0x39a999('0x23')][_0x39a999('0x25')]({'where':_0x577bff[_0x39a999('0x6e')]})[_0x39a999('0x48')](function(_0xc7970e){const _0x38478b=_0x39a999;return _0x41bcc4[_0x38478b('0x25')]=_0xc7970e,_0x3fcf96[_0x38478b('0x58')][_0x38478b('0x46')]&&(_0x577bff[_0x38478b('0x9')]=[{'all':!![]}]),db[_0x38478b('0x23')][_0x38478b('0x45')](_0x577bff);})[_0x39a999('0x48')](function(_0x4f3bf1){const _0x38d5a8=_0x39a999;return _0x41bcc4[_0x38d5a8('0x2c')]=_0x4f3bf1,_0x41bcc4;});})[_0xb6042d('0x48')](respondWithFilteredResult(_0x257a3a,_0x577bff))[_0xb6042d('0x31')](handleError(_0x257a3a,null));},exports['getTeams']=function(_0x8b849d,_0xc0621f){const _0x50a3b4=_0xbd745f;let _0x32a7ba={};const _0x1fe926={};let _0x207c45,_0x511a6b;return db[_0x50a3b4('0x0')]['findOne']({'where':{'id':_0x8b849d[_0x50a3b4('0x6d')]['id']}})[_0x50a3b4('0x48')](handleEntityNotFound(_0xc0621f,null))[_0x50a3b4('0x48')](function(_0x286445){const _0x251e70=_0x50a3b4;if(_0x286445)return _0x207c45=_0x286445,_0x1fe926['model']=_[_0x251e70('0x2')](db[_0x251e70('0x4a')][_0x251e70('0x84')]),_0x1fe926[_0x251e70('0x58')]=_[_0x251e70('0x2')](_0x8b849d['query']),_0x1fe926[_0x251e70('0x88')]=_[_0x251e70('0x17')](_0x1fe926[_0x251e70('0x73')],_0x1fe926['query']),_0x32a7ba[_0x251e70('0x6a')]=_[_0x251e70('0x17')](_0x1fe926[_0x251e70('0x73')],qs['fields'](_0x8b849d[_0x251e70('0x58')]['fields'])),_0x32a7ba[_0x251e70('0x6a')]=_0x32a7ba[_0x251e70('0x6a')][_0x251e70('0x67')]?_0x32a7ba['attributes']:_0x1fe926[_0x251e70('0x73')],_0x32a7ba['order']=qs['sort'](_0x8b849d['query'][_0x251e70('0xc')]),_0x32a7ba[_0x251e70('0x6e')]=qs[_0x251e70('0x88')](_[_0x251e70('0x83')](_0x8b849d['query'],_0x1fe926[_0x251e70('0x88')])),_0x8b849d[_0x251e70('0x58')]['filter']&&(_0x32a7ba[_0x251e70('0x6e')]=_['merge'](_0x32a7ba[_0x251e70('0x6e')],{[Op['or']]:_[_0x251e70('0x6f')](_0x32a7ba[_0x251e70('0x6a')],function(_0x2ae896){const _0x497bff=_0x251e70,_0x49f752={};return _0x49f752[_0x2ae896]={[Op[_0x497bff('0x2d')]]:'%'+_0x8b849d[_0x497bff('0x58')][_0x497bff('0x50')]+'%'},_0x49f752;})})),_0x32a7ba=_[_0x251e70('0x54')]({},_0x32a7ba,_0x8b849d['options']),_0x207c45['getTeams'](_0x32a7ba);})[_0x50a3b4('0x48')](function(_0xb282e5){const _0x2f8ced=_0x50a3b4;if(_0xb282e5)return _0x511a6b=_0xb282e5[_0x2f8ced('0x67')],typeof _0x8b849d[_0x2f8ced('0x58')][_0x2f8ced('0x91')]===_0x2f8ced('0x40')&&(_0x32a7ba[_0x2f8ced('0x36')]=qs[_0x2f8ced('0x36')](_0x8b849d[_0x2f8ced('0x58')][_0x2f8ced('0x36')]),_0x32a7ba[_0x2f8ced('0x8c')]=qs[_0x2f8ced('0x8c')](_0x8b849d[_0x2f8ced('0x58')]['offset'])),_0x207c45[_0x2f8ced('0x20')](_0x32a7ba);})['then'](function(_0x25b1e9){if(_0x25b1e9)return _0x25b1e9?{'count':_0x511a6b,'rows':_0x25b1e9}:null;})[_0x50a3b4('0x48')](respondWithResult(_0xc0621f,null))['catch'](handleError(_0xc0621f,null));},exports[_0xbd745f('0x7d')]=function(_0x408864,_0x1fc519){const _0x3cda2e=_0xbd745f,_0x108e2a=_0x408864['body'][_0x3cda2e('0x63')],_0xdabba7=_[_0x3cda2e('0x6f')](_0x108e2a,'id');return db[_0x3cda2e('0x4a')][_0x3cda2e('0x45')]({'where':{'id':_0xdabba7},'attributes':['id'],'include':[{'model':db['User'],'as':'Agents','attributes':['id',_0x3cda2e('0x2f'),_0x3cda2e('0x4c'),'voicePause','interface'],'raw':!![]}]})[_0x3cda2e('0x48')](function(_0x5bdffc){const _0x5c8ad2=_0x3cda2e;if(_0x5bdffc){const _0x10373f=_[_0x5c8ad2('0x9a')](_0x5bdffc,function(_0x4a51c1){const _0x235980=_0x5c8ad2,_0x459cbe=_0x4a51c1[_0x235980('0x3')]({'plain':!![]});return _0x459cbe[_0x235980('0x51')][_0x235980('0x19')](function(_0x486eb5){const _0x525ce4=_0x235980;_0x486eb5['penalty']=_['find'](_0x108e2a,{'id':_0x459cbe['id']})[_0x525ce4('0x5e')];}),_0x459cbe['Agents'];});return db[_0x5c8ad2('0x0')][_0x5c8ad2('0x7c')]({'where':{'id':_0x408864[_0x5c8ad2('0x6d')]['id']}})[_0x5c8ad2('0x48')](function(_0x184ae9){const _0x48ca7f=_0x5c8ad2;return db[_0x48ca7f('0x2b')][_0x48ca7f('0x5d')](function(_0x3e027d){const _0x511801=_0x48ca7f;return _0x184ae9[_0x511801('0x7d')](_0xdabba7,{'transaction':_0x3e027d})[_0x511801('0x48')](function(){const _0x31f1ef=_0x511801;return Promise[_0x31f1ef('0x70')](_0x10373f,function(_0x5ce3c4){const _0x2e8b77=_0x31f1ef;return db[_0x2e8b77('0x44')][_0x2e8b77('0x22')]({'where':{'UserId':_0x5ce3c4['id'],'VoiceQueueId':_0x408864[_0x2e8b77('0x6d')]['id']},'defaults':{'penalty':_0x5ce3c4['penalty']},'transaction':_0x3e027d});});})[_0x511801('0x48')](function(){const _0x193b86=_0x511801;return Promise[_0x193b86('0x70')](_[_0x193b86('0x50')](_0x10373f,{'online':!![]}),function(_0x354ab7){const _0x12c05f=_0x193b86;return db[_0x12c05f('0x77')]['upsert']({'membername':_0x354ab7[_0x12c05f('0x2f')],'UserId':_0x354ab7['id'],'queue_name':_0x184ae9['name'],'VoiceQueueId':_0x184ae9['id'],'interface':_[_0x12c05f('0x71')](_0x354ab7['interface'])?util['format'](_0x12c05f('0x4b'),_0x354ab7[_0x12c05f('0x2f')]):_0x354ab7[_0x12c05f('0x87')],'paused':_0x354ab7[_0x12c05f('0x96')]||![],'penalty':_0x354ab7['penalty']},{'transaction':_0x3e027d});});})['then'](function(){const _0x7039df=_0x511801;_0x10373f[_0x7039df('0x19')](function(_0x480c98){const _0x5bd9d3=_0x7039df;socket[_0x5bd9d3('0x42')]('userVoiceQueue:save',{'UserId':_0x480c98['id'],'VoiceQueueId':_0x184ae9['id']});});});});});}})[_0x3cda2e('0x48')](respondWithStatusCode(_0x1fc519,null))[_0x3cda2e('0x31')](handleError(_0x1fc519,null));},exports['removeTeams']=function(_0x34fcd1,_0x6313a4){const _0x2f1b8d=_0xbd745f;return db[_0x2f1b8d('0x4a')][_0x2f1b8d('0x45')]({'where':{'id':_0x34fcd1[_0x2f1b8d('0x58')][_0x2f1b8d('0x8d')]},'attributes':['id'],'include':[{'model':db[_0x2f1b8d('0x5a')],'as':_0x2f1b8d('0x51'),'attributes':['id'],'raw':!![]}]})[_0x2f1b8d('0x48')](handleEntityNotFound(_0x6313a4,null))[_0x2f1b8d('0x48')](function(_0x108856){const _0x3d127e=_0x2f1b8d,_0x20a270=_[_0x3d127e('0x6f')](_0x108856,'id');let _0x3ed417=[];const _0xe9ee3e=[],_0xe90f48=squel[_0x3d127e('0x5f')]();_0xe90f48[_0x3d127e('0x4e')](_0x3d127e('0x7f'))[_0x3d127e('0xf')](_0x3d127e('0x9b'),'tq')[_0x3d127e('0x95')](_0x3d127e('0x1c'),'ut','ut.TeamId\x20=\x20tq.TeamId')[_0x3d127e('0x6e')]('VoiceQueueId\x20=\x20?',_0x34fcd1['params']['id']);for(let _0x185f84=0x0;_0x185f84<_0x108856[_0x3d127e('0x67')];_0x185f84+=0x1){const _0xf709f=_0x108856[_0x185f84];for(let _0x1c5d77=0x0;_0x1c5d77<_0xf709f['Agents']['length'];_0x1c5d77+=0x1){const _0xe25dd7=_0xf709f['Agents'][_0x1c5d77],_0x17e5a4=_0xe90f48[_0x3d127e('0x57')]();_0x17e5a4[_0x3d127e('0x6e')](_0x3d127e('0x15'),_0xe25dd7['id']),_0xe9ee3e['push'](db[_0x3d127e('0x2b')][_0x3d127e('0x58')](_0x17e5a4['toString'](),{'type':QueryTypes['SELECT']})[_0x3d127e('0x48')](function(_0x1399fb){const _0x44ed1f=_0x3d127e;if(_0x1399fb[_0x44ed1f('0x67')]===0x1)return _0xe25dd7['id'];else{const _0x30e6c5=_[_0x44ed1f('0x68')](_[_0x44ed1f('0x6f')](_0x1399fb,_0x44ed1f('0x81')),function(_0x22cbbc){const _0x40e8e8=_0x44ed1f;return _[_0x40e8e8('0x3d')](_0x20a270,_0x22cbbc);});if(_0x30e6c5)return _0xe25dd7['id'];}}));}}return Promise['all'](_0xe9ee3e)['then'](function(_0x248a49){const _0x45ccf8=_0x3d127e;return _0x3ed417=_(_0x3ed417)[_0x45ccf8('0x89')](_0x248a49)['compact']()[_0x45ccf8('0x2e')](),db[_0x45ccf8('0x0')][_0x45ccf8('0x7c')]({'where':{'id':_0x34fcd1[_0x45ccf8('0x6d')]['id']}})[_0x45ccf8('0x48')](function(_0x12bc32){const _0x2ec2a9=_0x45ccf8;return db[_0x2ec2a9('0x2b')][_0x2ec2a9('0x5d')](function(_0x50356b){const _0x455e19=_0x2ec2a9;return _0x12bc32['removeTeams'](_0x34fcd1[_0x455e19('0x58')][_0x455e19('0x8d')],{'transaction':_0x50356b})['then'](function(){const _0x5525e5=_0x455e19;if(!_[_0x5525e5('0x7')](_0x3ed417))return _0x12bc32[_0x5525e5('0xd')](_0x3ed417,{'transaction':_0x50356b})['then'](function(){const _0x4b0636=_0x5525e5;return db[_0x4b0636('0x77')][_0x4b0636('0x94')]({'where':{'VoiceQueueId':_0x34fcd1[_0x4b0636('0x6d')]['id'],'UserId':_0x3ed417},'transaction':_0x50356b});});})['then'](function(){const _0x16a64d=_0x455e19;_0x3ed417[_0x16a64d('0x19')](function(_0x1a44f2){const _0x7aa21a=_0x16a64d;socket['emit'](_0x7aa21a('0x65'),{'UserId':_0x1a44f2,'VoiceQueueId':_0x12bc32['id']});});});});});});})[_0x2f1b8d('0x48')](respondWithStatusCode(_0x6313a4,null))['catch'](handleError(_0x6313a4,null));},exports[_0xbd745f('0x16')]=function(_0x93579b,_0x3cf913){const _0x12ffcd=_0xbd745f;let _0x4872e0,_0x3e20a8;return db['VoiceQueue'][_0x12ffcd('0x7c')]({'where':{'id':_0x93579b[_0x12ffcd('0x6d')]['id']}})['then'](function(_0x16a5eb){const _0x17172f=_0x12ffcd;if(_0x16a5eb)return _0x3e20a8=_0x16a5eb,_0x16a5eb[_0x17172f('0x16')](_0x93579b[_0x17172f('0x13')][_0x17172f('0x8d')],{'through':_[_0x17172f('0x64')](_0x93579b[_0x17172f('0x13')],[_0x17172f('0x8d'),'id'])})[_0x17172f('0x48')](function(_0x3271cd){const _0x195bf8=_0x17172f;for(let _0x22b223=0x0;_0x22b223<_0x93579b[_0x195bf8('0x13')][_0x195bf8('0x8d')][_0x195bf8('0x67')];_0x22b223+=0x1){socket['emit'](_0x195bf8('0x18'),{'UserId':_0x93579b[_0x195bf8('0x13')]['ids'][_0x22b223],'VoiceQueueId':_0x93579b[_0x195bf8('0x6d')]['id']});}return _0x3271cd;});})[_0x12ffcd('0x48')](function(_0x12adb4){const _0x383e7d=_0x12ffcd;_0x4872e0=_0x12adb4||[];if(_0x3e20a8)return db[_0x383e7d('0x5a')]['findAll']({'where':{'id':_0x93579b['body'][_0x383e7d('0x8d')]},'attributes':['id',_0x383e7d('0x2f'),_0x383e7d('0x4c'),_0x383e7d('0x96'),_0x383e7d('0x87')],'raw':!![]});})[_0x12ffcd('0x48')](function(_0x189df5){const _0x4821b8=_0x12ffcd;if(!_[_0x4821b8('0x7')](_0x189df5)){const _0x5ce9e9=[];for(let _0x513b4d=0x0;_0x513b4d<_0x189df5[_0x4821b8('0x67')];_0x513b4d++){_0x189df5[_0x513b4d][_0x4821b8('0x4c')]&&_0x5ce9e9[_0x4821b8('0x1')](db[_0x4821b8('0x77')]['upsert']({'membername':_0x189df5[_0x513b4d][_0x4821b8('0x2f')],'UserId':_0x189df5[_0x513b4d]['id'],'queue_name':_0x3e20a8[_0x4821b8('0x2f')],'VoiceQueueId':_0x3e20a8['id'],'interface':_[_0x4821b8('0x71')](_0x189df5[_0x513b4d][_0x4821b8('0x87')])?util[_0x4821b8('0x2a')]('SIP/%s',_0x189df5[_0x513b4d][_0x4821b8('0x2f')]):_0x189df5[_0x513b4d]['interface'],'paused':_0x189df5[_0x513b4d]['voicePause']||![],'penalty':_0x93579b['body']['penalty']||0x0}));}return Promise['all'](_0x5ce9e9);}})[_0x12ffcd('0x48')](function(){return _0x4872e0;})[_0x12ffcd('0x48')](respondWithResult(_0x3cf913,null))['catch'](handleError(_0x3cf913,null));},exports[_0xbd745f('0xd')]=function(_0x55c218,_0x47f7c2){const _0x57d622=_0xbd745f;return db[_0x57d622('0x0')][_0x57d622('0x7c')]({'where':{'id':_0x55c218['params']['id']}})[_0x57d622('0x48')](handleEntityNotFound(_0x47f7c2,null))['then'](function(_0x36c270){const _0x24fd62=_0x57d622;if(_0x36c270)return _0x36c270[_0x24fd62('0xd')](_0x55c218[_0x24fd62('0x58')][_0x24fd62('0x8d')])[_0x24fd62('0x48')](function(){const _0xafffcf=_0x24fd62;if(_[_0xafffcf('0x3f')](_0x55c218['query'][_0xafffcf('0x8d')]))for(let _0xd5e32=0x0;_0xd5e32<_0x55c218[_0xafffcf('0x58')][_0xafffcf('0x8d')][_0xafffcf('0x67')];_0xd5e32+=0x1){socket['emit'](_0xafffcf('0x65'),{'UserId':Number(_0x55c218['query'][_0xafffcf('0x8d')][_0xd5e32]),'VoiceQueueId':Number(_0x55c218[_0xafffcf('0x6d')]['id'])});}else socket[_0xafffcf('0x42')]('userVoiceQueue:remove',{'UserId':Number(_0x55c218['query']['ids']),'VoiceQueueId':Number(_0x55c218[_0xafffcf('0x6d')]['id'])});});})[_0x57d622('0x48')](function(_0x5e624b){const _0x291e6d=_0x57d622;return db[_0x291e6d('0x77')][_0x291e6d('0x94')]({'where':{'VoiceQueueId':_0x55c218['params']['id'],'UserId':_0x55c218[_0x291e6d('0x58')][_0x291e6d('0x8d')]}})[_0x291e6d('0x48')](function(){return _0x5e624b;});})['then'](respondWithStatusCode(_0x47f7c2,null))[_0x57d622('0x31')](handleError(_0x47f7c2,null));},exports[_0xbd745f('0xb')]=function(_0x1a1979,_0x4adb0c){const _0x250622=_0xbd745f;let _0x5e10a9={};const _0x2d1f9c={};let _0x2a99f8,_0x1cb266;return db[_0x250622('0x0')][_0x250622('0x7c')]({'where':{'id':_0x1a1979[_0x250622('0x6d')]['id']}})[_0x250622('0x48')](handleEntityNotFound(_0x4adb0c,null))['then'](function(_0x5ad3f8){const _0x170f13=_0x250622;if(_0x5ad3f8)return _0x2a99f8=_0x5ad3f8,_0x2d1f9c[_0x170f13('0x73')]=_[_0x170f13('0x2')](db['User'][_0x170f13('0x84')]),_0x2d1f9c['query']=_[_0x170f13('0x2')](_0x1a1979[_0x170f13('0x58')]),_0x2d1f9c['filters']=_[_0x170f13('0x17')](_0x2d1f9c[_0x170f13('0x73')],_0x2d1f9c[_0x170f13('0x58')]),_0x5e10a9[_0x170f13('0x6a')]=_[_0x170f13('0x17')](_0x2d1f9c[_0x170f13('0x73')],qs[_0x170f13('0xa')](_0x1a1979[_0x170f13('0x58')][_0x170f13('0xa')])),_0x5e10a9[_0x170f13('0x6a')]=_0x5e10a9['attributes'][_0x170f13('0x67')]?_0x5e10a9['attributes']:_0x2d1f9c[_0x170f13('0x73')],_0x5e10a9[_0x170f13('0x92')]=qs[_0x170f13('0xc')](_0x1a1979['query'][_0x170f13('0xc')]),_0x5e10a9['where']=qs['filters'](_['pick'](_0x1a1979['query'],_0x2d1f9c[_0x170f13('0x88')])),_0x1a1979[_0x170f13('0x58')]['filter']&&(_0x5e10a9[_0x170f13('0x6e')]=_['merge'](_0x5e10a9[_0x170f13('0x6e')],{[Op['or']]:_[_0x170f13('0x6f')](_0x5e10a9[_0x170f13('0x6a')],function(_0x45e7df){const _0x20ec7d=_0x170f13,_0x1cc4a3={};return _0x1cc4a3[_0x45e7df]={[Op[_0x20ec7d('0x2d')]]:'%'+_0x1a1979[_0x20ec7d('0x58')]['filter']+'%'},_0x1cc4a3;})})),_0x5e10a9=_[_0x170f13('0x54')]({},_0x5e10a9,_0x1a1979[_0x170f13('0x62')]),_0x2a99f8['getAgents'](_0x5e10a9);})[_0x250622('0x48')](function(_0x47c62b){const _0x4a8408=_0x250622;if(_0x47c62b)return _0x1cb266=_0x47c62b['length'],typeof _0x1a1979[_0x4a8408('0x58')]['nolimit']===_0x4a8408('0x40')&&(_0x5e10a9['limit']=qs[_0x4a8408('0x36')](_0x1a1979[_0x4a8408('0x58')][_0x4a8408('0x36')]),_0x5e10a9[_0x4a8408('0x8c')]=qs[_0x4a8408('0x8c')](_0x1a1979['query'][_0x4a8408('0x8c')])),_0x2a99f8[_0x4a8408('0xb')](_0x5e10a9);})[_0x250622('0x48')](function(_0xd02604){if(_0xd02604)return _0xd02604?{'count':_0x1cb266,'rows':_0xd02604}:null;})[_0x250622('0x48')](respondWithResult(_0x4adb0c,null))[_0x250622('0x31')](handleError(_0x4adb0c,null));},exports[_0xbd745f('0x4')]=function(_0x2ac33b,_0x248378){const _0x501a8d=_0xbd745f;let _0x34b025={};const _0x3037b9={};let _0x4ef7d7,_0xac7c66;return db[_0x501a8d('0x0')][_0x501a8d('0x7c')]({'where':{'id':_0x2ac33b[_0x501a8d('0x6d')]['id']}})['then'](handleEntityNotFound(_0x248378,null))['then'](function(_0x9e1d47){const _0x4fc078=_0x501a8d;if(_0x9e1d47)return _0x4ef7d7=_0x9e1d47,_0x3037b9['model']=_['keys'](db[_0x4fc078('0x77')][_0x4fc078('0x84')]),_0x3037b9[_0x4fc078('0x58')]=_['keys'](_0x2ac33b[_0x4fc078('0x58')]),_0x3037b9[_0x4fc078('0x88')]=_[_0x4fc078('0x17')](_0x3037b9[_0x4fc078('0x73')],_0x3037b9[_0x4fc078('0x58')]),_0x34b025[_0x4fc078('0x6a')]=_[_0x4fc078('0x17')](_0x3037b9['model'],qs[_0x4fc078('0xa')](_0x2ac33b[_0x4fc078('0x58')]['fields'])),_0x34b025['attributes']=_0x34b025[_0x4fc078('0x6a')][_0x4fc078('0x67')]?_0x34b025[_0x4fc078('0x6a')]:_0x3037b9[_0x4fc078('0x73')],_0x34b025[_0x4fc078('0x92')]=qs[_0x4fc078('0xc')](_0x2ac33b[_0x4fc078('0x58')][_0x4fc078('0xc')]),_0x34b025[_0x4fc078('0x6e')]=qs['filters'](_['pick'](_0x2ac33b[_0x4fc078('0x58')],_0x3037b9[_0x4fc078('0x88')])),_0x2ac33b['query'][_0x4fc078('0x50')]&&(_0x34b025[_0x4fc078('0x6e')]=_[_0x4fc078('0x54')](_0x34b025['where'],{[Op['or']]:_['map'](_0x34b025['attributes'],function(_0x48071d){const _0xb1bb0e=_0x4fc078,_0x128f9c={};return _0x128f9c[_0x48071d]={[Op['like']]:'%'+_0x2ac33b[_0xb1bb0e('0x58')][_0xb1bb0e('0x50')]+'%'},_0x128f9c;})})),_0x34b025=_[_0x4fc078('0x54')]({},_0x34b025,_0x2ac33b[_0x4fc078('0x62')]),_0x4ef7d7[_0x4fc078('0x4')](_0x34b025);})[_0x501a8d('0x48')](function(_0x4d46db){const _0x8e8b24=_0x501a8d;if(_0x4d46db)return _0xac7c66=_0x4d46db[_0x8e8b24('0x67')],typeof _0x2ac33b[_0x8e8b24('0x58')]['nolimit']===_0x8e8b24('0x40')&&(_0x34b025[_0x8e8b24('0x36')]=qs[_0x8e8b24('0x36')](_0x2ac33b['query'][_0x8e8b24('0x36')]),_0x34b025[_0x8e8b24('0x8c')]=qs[_0x8e8b24('0x8c')](_0x2ac33b[_0x8e8b24('0x58')][_0x8e8b24('0x8c')])),_0x4ef7d7[_0x8e8b24('0x4')](_0x34b025);})['then'](function(_0x5e1467){return _0x5e1467?{'count':_0xac7c66,'rows':_0x5e1467}:null;})[_0x501a8d('0x48')](respondWithResult(_0x248378,null))[_0x501a8d('0x31')](handleError(_0x248378,null));},exports['getLists']=function(_0x1b2d5d,_0x250cc2){const _0xf10709=_0xbd745f;let _0x58f815={};const _0x143ff7={};let _0x7ec4dd,_0x5c4741;return db[_0xf10709('0x0')][_0xf10709('0x7c')]({'where':{'id':_0x1b2d5d[_0xf10709('0x6d')]['id']}})[_0xf10709('0x48')](handleEntityNotFound(_0x250cc2,null))['then'](function(_0x2694bf){const _0x3bc952=_0xf10709;if(_0x2694bf)return _0x7ec4dd=_0x2694bf,_0x143ff7['model']=_[_0x3bc952('0x2')](db[_0x3bc952('0x61')][_0x3bc952('0x84')]),_0x143ff7[_0x3bc952('0x58')]=_['keys'](_0x1b2d5d[_0x3bc952('0x58')]),_0x143ff7['filters']=_[_0x3bc952('0x17')](_0x143ff7[_0x3bc952('0x73')],_0x143ff7['query']),_0x58f815[_0x3bc952('0x6a')]=_[_0x3bc952('0x17')](_0x143ff7[_0x3bc952('0x73')],qs[_0x3bc952('0xa')](_0x1b2d5d[_0x3bc952('0x58')][_0x3bc952('0xa')])),_0x58f815[_0x3bc952('0x6a')]=_0x58f815[_0x3bc952('0x6a')][_0x3bc952('0x67')]?_0x58f815[_0x3bc952('0x6a')]:_0x143ff7[_0x3bc952('0x73')],_0x58f815[_0x3bc952('0x92')]=qs[_0x3bc952('0xc')](_0x1b2d5d[_0x3bc952('0x58')]['sort']),_0x58f815['where']=qs[_0x3bc952('0x88')](_[_0x3bc952('0x83')](_0x1b2d5d[_0x3bc952('0x58')],_0x143ff7[_0x3bc952('0x88')])),_0x1b2d5d[_0x3bc952('0x58')][_0x3bc952('0x50')]&&(_0x58f815[_0x3bc952('0x6e')]=_[_0x3bc952('0x54')](_0x58f815[_0x3bc952('0x6e')],{[Op['or']]:_[_0x3bc952('0x6f')](_0x58f815[_0x3bc952('0x6a')],function(_0x348dee){const _0x5b1082=_0x3bc952,_0x2dbda0={};return _0x2dbda0[_0x348dee]={[Op[_0x5b1082('0x2d')]]:'%'+_0x1b2d5d[_0x5b1082('0x58')][_0x5b1082('0x50')]+'%'},_0x2dbda0;})})),_0x58f815=_[_0x3bc952('0x54')]({},_0x58f815,_0x1b2d5d[_0x3bc952('0x62')]),_0x7ec4dd[_0x3bc952('0x59')](_0x58f815);})['then'](function(_0x50c0ce){const _0x1b9058=_0xf10709;if(_0x50c0ce)return _0x5c4741=_0x50c0ce[_0x1b9058('0x67')],typeof _0x1b2d5d['query'][_0x1b9058('0x91')]===_0x1b9058('0x40')&&(_0x58f815['limit']=qs[_0x1b9058('0x36')](_0x1b2d5d[_0x1b9058('0x58')][_0x1b9058('0x36')]),_0x58f815['offset']=qs[_0x1b9058('0x8c')](_0x1b2d5d['query'][_0x1b9058('0x8c')])),_0x7ec4dd[_0x1b9058('0x59')](_0x58f815);})[_0xf10709('0x48')](function(_0x1bd72c){if(_0x1bd72c)return _0x1bd72c?{'count':_0x5c4741,'rows':_0x1bd72c}:null;})[_0xf10709('0x48')](respondWithResult(_0x250cc2,null))[_0xf10709('0x31')](handleError(_0x250cc2,null));},exports[_0xbd745f('0x99')]=function(_0x1ba074,_0x3a9e00){const _0x4e5b7e=_0xbd745f;let _0x4de456,_0x1c0a24;return db[_0x4e5b7e('0x0')]['findOne']({'where':{'id':_0x1ba074['params']['id']}})[_0x4e5b7e('0x48')](handleEntityNotFound(_0x3a9e00,null))[_0x4e5b7e('0x48')](function(_0x472e95){const _0x292ebf=_0x4e5b7e;if(_0x472e95)return _0x1c0a24=_0x472e95,_0x472e95[_0x292ebf('0x99')](_0x1ba074[_0x292ebf('0x13')][_0x292ebf('0x8d')],{'through':_[_0x292ebf('0x64')](_0x1ba074['body'],[_0x292ebf('0x8d'),'id'])});return null;})[_0x4e5b7e('0x48')](function(_0x3460e3){const _0x4b9a45=_0x4e5b7e;let _0x3975d2;_0x4de456=_0x3460e3||[];const _0x1a27bb=[];if(_0x3460e3){for(let _0x597a4c=0x0;_0x597a4c<_0x3460e3[_0x4b9a45('0x67')];_0x597a4c+=0x1){const _0x2dcf1b=_0x3460e3[_0x597a4c][_0x4b9a45('0x3')]({'plain':!![]});_0x1c0a24[_0x4b9a45('0x8b')]=_0x1ba074[_0x4b9a45('0x13')][_0x4b9a45('0x8b')]?_0x1ba074['body'][_0x4b9a45('0x8b')]:_0x1c0a24[_0x4b9a45('0x8b')];switch(_0x1c0a24['dialCheckDuplicateType']){case _0x4b9a45('0x8'):_0x3975d2=squel[_0x4b9a45('0x8a')]()[_0x4b9a45('0x28')](_0x4b9a45('0x4d'))[_0x4b9a45('0x80')]([_0x4b9a45('0x8e'),_0x4b9a45('0x3c'),_0x4b9a45('0x3b'),'ListId',_0x4b9a45('0x93'),'createdAt',_0x4b9a45('0x11')],squel[_0x4b9a45('0x5f')]()['field'](_0x4b9a45('0x8e'),_0x4b9a45('0x8e'))[_0x4b9a45('0x4e')]('NOW()','scheduledAt')[_0x4b9a45('0x4e')]('id',_0x4b9a45('0x3b'))[_0x4b9a45('0x4e')](_0x2dcf1b[_0x4b9a45('0x1a')][_0x4b9a45('0x6c')](),'ListId')['field'](_0x1ba074[_0x4b9a45('0x6d')]['id']['toString'](),'VoiceQueueId')['field'](_0x4b9a45('0x47'),_0x4b9a45('0x98'))[_0x4b9a45('0x4e')]('NOW()',_0x4b9a45('0x11'))[_0x4b9a45('0xf')]('cm_contacts')[_0x4b9a45('0x6e')]('deletedAt\x20IS\x20NULL')[_0x4b9a45('0x6e')](_0x4b9a45('0x6b'),_0x2dcf1b[_0x4b9a45('0x1a')][_0x4b9a45('0x6c')]())[_0x4b9a45('0x6e')](_0x4b9a45('0x33'))['where'](_0x4b9a45('0x24'),squel[_0x4b9a45('0x5f')]()[_0x4b9a45('0x4e')]('COALESCE(calleridnum,\x27\x27)')['from']('cm_hopper_final')[_0x4b9a45('0x6e')](_0x4b9a45('0x30'),_0x1ba074[_0x4b9a45('0x6d')]['id'][_0x4b9a45('0x6c')]()))['where'](_0x4b9a45('0x24'),squel['select']()[_0x4b9a45('0x4e')](_0x4b9a45('0x76'))[_0x4b9a45('0xf')]('cm_hopper')[_0x4b9a45('0x6e')](_0x4b9a45('0x30'),_0x1ba074[_0x4b9a45('0x6d')]['id'][_0x4b9a45('0x6c')]())))['toString']();break;case'onlyIfOpen':_0x3975d2=squel[_0x4b9a45('0x8a')]()[_0x4b9a45('0x28')]('cm_hopper')[_0x4b9a45('0x80')]([_0x4b9a45('0x8e'),_0x4b9a45('0x3c'),_0x4b9a45('0x3b'),_0x4b9a45('0x97'),_0x4b9a45('0x93'),_0x4b9a45('0x98'),'updatedAt'],squel[_0x4b9a45('0x5f')]()[_0x4b9a45('0x4e')](_0x4b9a45('0x8e'),_0x4b9a45('0x8e'))[_0x4b9a45('0x4e')](_0x4b9a45('0x47'),_0x4b9a45('0x3c'))[_0x4b9a45('0x4e')]('id',_0x4b9a45('0x3b'))['field'](_0x2dcf1b[_0x4b9a45('0x1a')]['toString'](),_0x4b9a45('0x97'))[_0x4b9a45('0x4e')](_0x1ba074['params']['id'][_0x4b9a45('0x6c')](),_0x4b9a45('0x93'))[_0x4b9a45('0x4e')](_0x4b9a45('0x47'),_0x4b9a45('0x98'))[_0x4b9a45('0x4e')](_0x4b9a45('0x47'),_0x4b9a45('0x11'))[_0x4b9a45('0xf')]('cm_contacts')[_0x4b9a45('0x6e')]('deletedAt\x20IS\x20NULL')[_0x4b9a45('0x6e')](_0x4b9a45('0x6b'),_0x2dcf1b[_0x4b9a45('0x1a')]['toString']())['where'](_0x4b9a45('0x33'))['where']('phone\x20NOT\x20IN\x20(?)',squel[_0x4b9a45('0x5f')]()['field'](_0x4b9a45('0x76'))[_0x4b9a45('0xf')]('cm_hopper')[_0x4b9a45('0x6e')](_0x4b9a45('0x30'),_0x1ba074[_0x4b9a45('0x6d')]['id'][_0x4b9a45('0x6c')]())))[_0x4b9a45('0x6c')]();break;default:_0x3975d2=squel[_0x4b9a45('0x8a')]()[_0x4b9a45('0x28')](_0x4b9a45('0x4d'))[_0x4b9a45('0x80')](['phone',_0x4b9a45('0x3c'),'ContactId',_0x4b9a45('0x97'),_0x4b9a45('0x93'),_0x4b9a45('0x98'),_0x4b9a45('0x11')],squel[_0x4b9a45('0x5f')]()['field'](_0x4b9a45('0x8e'),'phone')[_0x4b9a45('0x4e')](_0x4b9a45('0x47'),_0x4b9a45('0x3c'))['field']('id',_0x4b9a45('0x3b'))[_0x4b9a45('0x4e')](_0x2dcf1b[_0x4b9a45('0x1a')][_0x4b9a45('0x6c')](),'ListId')[_0x4b9a45('0x4e')](_0x1ba074[_0x4b9a45('0x6d')]['id'][_0x4b9a45('0x6c')](),_0x4b9a45('0x93'))['field']('NOW()',_0x4b9a45('0x98'))[_0x4b9a45('0x4e')](_0x4b9a45('0x47'),_0x4b9a45('0x11'))[_0x4b9a45('0xf')](_0x4b9a45('0x4f'))[_0x4b9a45('0x6e')](_0x4b9a45('0x34'))[_0x4b9a45('0x6e')](_0x4b9a45('0x6b'),_0x2dcf1b[_0x4b9a45('0x1a')][_0x4b9a45('0x6c')]())[_0x4b9a45('0x6e')](_0x4b9a45('0x33')))[_0x4b9a45('0x6c')]();}_0x1a27bb[_0x4b9a45('0x1')](db[_0x4b9a45('0x2b')]['query'](_0x3975d2));}return Promise['all'](_0x1a27bb);}})[_0x4e5b7e('0x48')](function(){return _0x4de456;})[_0x4e5b7e('0x48')](respondWithResult(_0x3a9e00,null))[_0x4e5b7e('0x31')](handleError(_0x3a9e00,null));},exports['removeLists']=function(_0x167926,_0x285ef9){const _0x1d36eb=_0xbd745f;return db[_0x1d36eb('0x0')][_0x1d36eb('0x7c')]({'where':{'id':_0x167926[_0x1d36eb('0x6d')]['id']}})[_0x1d36eb('0x48')](handleEntityNotFound(_0x285ef9,null))[_0x1d36eb('0x48')](function(_0x3a3b56){const _0x27c7bd=_0x1d36eb;if(_0x3a3b56)return _0x3a3b56[_0x27c7bd('0x49')](_0x167926[_0x27c7bd('0x58')][_0x27c7bd('0x8d')]);})[_0x1d36eb('0x48')](function(_0xe8b517){const _0x43720a=_0x1d36eb;if(_0xe8b517)return db['CmHopper']['destroy']({'where':{'ListId':_0x167926[_0x43720a('0x58')]['ids'],'VoiceQueueId':_0x167926['params']['id']}})[_0x43720a('0x48')](function(){return _0xe8b517;});})[_0x1d36eb('0x48')](respondWithStatusCode(_0x285ef9,null))[_0x1d36eb('0x31')](handleError(_0x285ef9,null));},exports[_0xbd745f('0x56')]=function(_0x5ada40,_0x25d372){const _0x8f1e2a=_0xbd745f;let _0xf01622={};const _0x19ae45={};let _0xf8bef6,_0x3ad269;return db[_0x8f1e2a('0x0')][_0x8f1e2a('0x7c')]({'where':{'id':_0x5ada40[_0x8f1e2a('0x6d')]['id']}})[_0x8f1e2a('0x48')](handleEntityNotFound(_0x25d372,null))[_0x8f1e2a('0x48')](function(_0x13952a){const _0x2c7760=_0x8f1e2a;if(_0x13952a)return _0xf8bef6=_0x13952a,_0x19ae45[_0x2c7760('0x73')]=_[_0x2c7760('0x2')](db['CmList'][_0x2c7760('0x84')]),_0x19ae45[_0x2c7760('0x58')]=_[_0x2c7760('0x2')](_0x5ada40['query']),_0x19ae45[_0x2c7760('0x88')]=_[_0x2c7760('0x17')](_0x19ae45['model'],_0x19ae45[_0x2c7760('0x58')]),_0xf01622['attributes']=_[_0x2c7760('0x17')](_0x19ae45[_0x2c7760('0x73')],qs[_0x2c7760('0xa')](_0x5ada40[_0x2c7760('0x58')][_0x2c7760('0xa')])),_0xf01622[_0x2c7760('0x6a')]=_0xf01622['attributes'][_0x2c7760('0x67')]?_0xf01622[_0x2c7760('0x6a')]:_0x19ae45[_0x2c7760('0x73')],_0xf01622['order']=qs[_0x2c7760('0xc')](_0x5ada40['query']['sort']),_0xf01622[_0x2c7760('0x6e')]=qs[_0x2c7760('0x88')](_['pick'](_0x5ada40[_0x2c7760('0x58')],_0x19ae45[_0x2c7760('0x88')])),_0x5ada40[_0x2c7760('0x58')]['filter']&&(_0xf01622['where']=_[_0x2c7760('0x54')](_0xf01622[_0x2c7760('0x6e')],{[Op['or']]:_['map'](_0xf01622['attributes'],function(_0x2d6858){const _0x52c75e=_0x2c7760,_0x232946={};return _0x232946[_0x2d6858]={[Op[_0x52c75e('0x2d')]]:'%'+_0x5ada40[_0x52c75e('0x58')]['filter']+'%'},_0x232946;})})),_0xf01622=_[_0x2c7760('0x54')]({},_0xf01622,_0x5ada40[_0x2c7760('0x62')]),_0xf8bef6[_0x2c7760('0x56')](_0xf01622);})[_0x8f1e2a('0x48')](function(_0x492a56){const _0x4d4c52=_0x8f1e2a;if(_0x492a56)return _0x3ad269=_0x492a56[_0x4d4c52('0x67')],typeof _0x5ada40[_0x4d4c52('0x58')][_0x4d4c52('0x91')]===_0x4d4c52('0x40')&&(_0xf01622[_0x4d4c52('0x36')]=qs[_0x4d4c52('0x36')](_0x5ada40[_0x4d4c52('0x58')][_0x4d4c52('0x36')]),_0xf01622[_0x4d4c52('0x8c')]=qs[_0x4d4c52('0x8c')](_0x5ada40[_0x4d4c52('0x58')]['offset'])),_0xf8bef6[_0x4d4c52('0x56')](_0xf01622);})[_0x8f1e2a('0x48')](function(_0xc9a09b){if(_0xc9a09b)return _0xc9a09b?{'count':_0x3ad269,'rows':_0xc9a09b}:null;})['then'](respondWithResult(_0x25d372,null))['catch'](handleError(_0x25d372,null));},exports[_0xbd745f('0x32')]=function(_0x1fb6b8,_0x187fb6){const _0x20144c=_0xbd745f;let _0x59031e;return db[_0x20144c('0x0')][_0x20144c('0x7c')]({'where':{'id':_0x1fb6b8[_0x20144c('0x6d')]['id']}})['then'](handleEntityNotFound(_0x187fb6,null))['then'](function(_0x58bf0e){const _0x1a5aa6=_0x20144c;if(_0x58bf0e)return _0x58bf0e[_0x1a5aa6('0x32')](_0x1fb6b8[_0x1a5aa6('0x13')][_0x1a5aa6('0x8d')],{'through':_[_0x1a5aa6('0x64')](_0x1fb6b8[_0x1a5aa6('0x13')],['ids','id'])});return null;})[_0x20144c('0x48')](function(_0x3f9563){const _0x34f35b=_0x20144c;let _0x1a5a82;_0x59031e=_0x3f9563||[];const _0x4d55de=[];if(_0x3f9563){for(let _0x112841=0x0;_0x112841<_0x3f9563[_0x34f35b('0x67')];_0x112841+=0x1){const _0x5b2f2f=_0x3f9563[_0x112841]['get']({'plain':!![]});_0x1a5a82=squel[_0x34f35b('0x8a')]()['into']('cm_hopper_black')['fromQuery']([_0x34f35b('0x8e'),_0x34f35b('0x3b'),_0x34f35b('0x97'),'VoiceQueueId',_0x34f35b('0x98'),_0x34f35b('0x11')],squel[_0x34f35b('0x5f')]()['field'](_0x34f35b('0x8e'),'phone')[_0x34f35b('0x4e')]('id',_0x34f35b('0x3b'))[_0x34f35b('0x4e')](_0x5b2f2f[_0x34f35b('0x1a')]['toString'](),_0x34f35b('0x97'))[_0x34f35b('0x4e')](_0x1fb6b8[_0x34f35b('0x6d')]['id'][_0x34f35b('0x6c')](),_0x34f35b('0x93'))[_0x34f35b('0x4e')](_0x34f35b('0x47'),_0x34f35b('0x98'))['field'](_0x34f35b('0x47'),_0x34f35b('0x11'))[_0x34f35b('0xf')]('cm_contacts')['where']('deletedAt\x20IS\x20NULL')[_0x34f35b('0x6e')]('ListId\x20=\x20?',_0x5b2f2f[_0x34f35b('0x1a')]['toString']())[_0x34f35b('0x6e')](_0x34f35b('0x33')))[_0x34f35b('0x6c')](),_0x4d55de[_0x34f35b('0x1')](db[_0x34f35b('0x2b')][_0x34f35b('0x58')](_0x1a5a82));}return Promise[_0x34f35b('0x7b')](_0x4d55de);}})['then'](function(){return _0x59031e;})[_0x20144c('0x48')](respondWithResult(_0x187fb6,null))['catch'](handleError(_0x187fb6,null));},exports[_0xbd745f('0x38')]=function(_0x121c46,_0x2217ef){const _0x9c69a5=_0xbd745f;return db['VoiceQueue'][_0x9c69a5('0x7c')]({'where':{'id':_0x121c46[_0x9c69a5('0x6d')]['id']}})['then'](handleEntityNotFound(_0x2217ef,null))[_0x9c69a5('0x48')](function(_0x2b7ea2){const _0x33264a=_0x9c69a5;if(_0x2b7ea2)return _0x2b7ea2[_0x33264a('0x38')](_0x121c46[_0x33264a('0x58')][_0x33264a('0x8d')]);})[_0x9c69a5('0x48')](function(_0x12f67e){const _0x34e98c=_0x9c69a5;if(_0x12f67e)return db['CmHopperBlack'][_0x34e98c('0x94')]({'where':{'ListId':_0x121c46[_0x34e98c('0x58')]['ids'],'VoiceQueueId':_0x121c46['params']['id']}})[_0x34e98c('0x48')](function(){return _0x12f67e;});})[_0x9c69a5('0x48')](respondWithStatusCode(_0x2217ef,null))['catch'](handleError(_0x2217ef,null));}; \ No newline at end of file +const a753_0x50e0=['includeAll','find','userVoiceQueue:remove','insert','phone','findOne','scheduledAt','userVoiceQueue:save','nolimit','ContactId','addTeams','filters','removeTeams','getBlackLists','voicePause','inbound','emit','pick','order','intersection','keys','rows','value','get','deletedAt\x20IS\x20NULL','cm_hopper_black','send','../../components/parsers/qs','interface','User','format','removeAgents','Agents','update','addLists','COALESCE(phone,\x27\x27)','push','where','length','key','addAgents','destroy','index','query','Unable\x20to\x20retrieve\x20the\x20current\x20user','penalty','ut.UserId\x20=\x20?','VoiceQueues','all','./voiceQueue.socket','VoiceQueueId\x20=\x20?','Content-Range','UserProfileSection','getLists','create','end','UserVoiceQueue','register','CmHopperBlack','api','fromQuery','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','into','body','findOrCreate','TeamId','options','set','transaction','ignore','ListId','name','autoAssociation','cm_hopper','rawAttributes','tq.TeamId','updatedAt','ListId\x20=\x20?','user','user_has_teams','VoiceQueueId','compact','offset','params','outbound','getTeams','removeLists','getMembers','QueueCampaigns','online','createdAt','show','removeBlackLists','fields','forEach','field','status','count','isEmpty','SELECT','getHopperHistories','flatMap','isNil','getHopperBlacks','include','limit','onlyIfOpen','VoiceQueue','phone\x20IS\x20NOT\x20NULL','cm_contacts','upsert','undefined','phone\x20NOT\x20IN\x20(?)','CmListId','ids','CmHopperHistory','clone','CmHopperFinal','model','findAll','includes','CmHopper','VIRTUAL','from','teams','like','SIP/%s','UserVoiceQueueRt','sequelize','union','type','UserProfileResource','merge','getAgents','../../mysqldb','omit','then','CmList','catch','cm_hopper_final','toString','error','select','NOW()','each','sendStatus','filter','dialCheckDuplicateType','role','map','sort','attributes','Team'];(function(_0x2fc510,_0x50e080){const _0x39ba36=function(_0x266db8){while(--_0x266db8){_0x2fc510['push'](_0x2fc510['shift']());}};_0x39ba36(++_0x50e080);}(a753_0x50e0,0x65));const a753_0x39ba=function(_0x2fc510,_0x50e080){_0x2fc510=_0x2fc510-0x0;let _0x39ba36=a753_0x50e0[_0x2fc510];return _0x39ba36;};const _0x37fe33=a753_0x39ba;'use strict';const util=require('util'),_=require('lodash'),squel=require('squel'),qs=require(_0x37fe33('0x4f')),logger=require('../../config/logger')(_0x37fe33('0x6f')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x37fe33('0x21'))['db'],{Op,QueryTypes}=require('sequelize');require(_0x37fe33('0x65'))[_0x37fe33('0x6d')](socket);function respondWithStatusCode(_0x266db8,_0x37881b){return _0x37881b=_0x37881b||0xcc,function(_0x407fac){const _0x4c93c5=a753_0x39ba;if(_0x407fac)return _0x266db8[_0x4c93c5('0x2c')](_0x37881b);return _0x266db8[_0x4c93c5('0x94')](_0x37881b)[_0x4c93c5('0x6b')]();};}function respondWithResult(_0x393500,_0x2fc0e9){return _0x2fc0e9=_0x2fc0e9||0xc8,function(_0x234f9c){const _0x7584e2=a753_0x39ba;if(_0x234f9c)return _0x393500[_0x7584e2('0x94')](_0x2fc0e9)['json'](_0x234f9c);};}function respondWithFilteredResult(_0x59031a,_0x520a4f){return function(_0x120842){const _0x2fa4e1=a753_0x39ba;if(_0x120842){const _0x3eea8c=_0x120842[_0x2fa4e1('0x95')],_0x3e5215=_0x520a4f[_0x2fa4e1('0x86')];let _0x2a79c1=_0x520a4f[_0x2fa4e1('0x86')]+_0x520a4f[_0x2fa4e1('0x4')],_0x4ff7d0;return _0x2a79c1>=_0x3eea8c?(_0x2a79c1=_0x3eea8c,_0x4ff7d0=0xc8):_0x4ff7d0=0xce,_0x59031a[_0x2fa4e1('0x94')](_0x4ff7d0),_0x59031a[_0x2fa4e1('0x77')](_0x2fa4e1('0x67'),_0x3e5215+'-'+_0x2a79c1+'/'+_0x3eea8c)['json'](_0x120842);}return null;};}function saveUpdates(_0x167a94){return function(_0x5c88ea){const _0x2d3669=a753_0x39ba;if(_0x5c88ea)return _0x5c88ea['update'](_0x167a94)[_0x2d3669('0x23')](function(_0x13c67e){return _0x13c67e;});return null;};}function removeEntity(_0x4e4cef){return function(_0x3dd9cf){const _0x39785a=a753_0x39ba;if(_0x3dd9cf)return _0x3dd9cf[_0x39785a('0x5d')]()['then'](function(){const _0x48cc5b=_0x39785a,_0x2d620f=_0x3dd9cf['get']({'plain':!![]}),_0x7e5871=[{'name':_0x48cc5b('0x63'),'value':_0x48cc5b('0x43'),'ignore':![]},{'name':'QueueCampaigns','value':_0x48cc5b('0x88'),'ignore':![]}],_0x1221cb=_(_0x7e5871)[_0x48cc5b('0x2d')](_0x48cc5b('0x79'))[_0x48cc5b('0x30')]('value')[_0x48cc5b('0x4a')]();if(_['includes'](_0x1221cb,_0x2d620f[_0x48cc5b('0x1d')]))return;const _0x3bf46d=_[_0x48cc5b('0x35')](_0x7e5871,[_0x48cc5b('0x4a'),_0x2d620f[_0x48cc5b('0x1d')]])[_0x48cc5b('0x7b')];return db[_0x48cc5b('0x1e')][_0x48cc5b('0x5d')]({'where':{'type':_0x3bf46d,'resourceId':_0x2d620f['id']}})[_0x48cc5b('0x23')](function(){return _0x3dd9cf;});})['then'](function(){const _0x33696d=_0x39785a;_0x4e4cef[_0x33696d('0x94')](0xcc)[_0x33696d('0x6b')]();});};}function handleEntityNotFound(_0x4a0776){return function(_0x38c0d5){return!_0x38c0d5&&_0x4a0776['sendStatus'](0x194),_0x38c0d5;};}function handleError(_0x3da286,_0x5a5856){return _0x5a5856=_0x5a5856||0x1f4,function(_0x239a67){const _0x4e104a=a753_0x39ba;logger[_0x4e104a('0x28')](_0x239a67['stack']),_0x239a67['name']&&delete _0x239a67[_0x4e104a('0x7b')],_0x3da286['status'](_0x5a5856)[_0x4e104a('0x4e')](_0x239a67);};}exports[_0x37fe33('0x5e')]=function(_0x1b875f,_0x1fe08e){const _0x32c4b6=_0x37fe33;let _0x6a4655={};const _0x47cec2={},_0x529881={'count':0x0,'rows':[]},_0x45f004=_[_0x32c4b6('0x30')](db[_0x32c4b6('0x6')]['rawAttributes'],function(_0x239747){const _0x7f2b14=_0x32c4b6;return{'name':_0x239747['fieldName'],'type':_0x239747['type'][_0x7f2b14('0x5b')]};});_0x47cec2[_0x32c4b6('0x11')]=_[_0x32c4b6('0x30')](_0x45f004,_0x32c4b6('0x7b')),_0x47cec2[_0x32c4b6('0x5f')]=_[_0x32c4b6('0x48')](_0x1b875f[_0x32c4b6('0x5f')]),_0x47cec2['filters']=_[_0x32c4b6('0x47')](_0x47cec2[_0x32c4b6('0x11')],_0x47cec2[_0x32c4b6('0x5f')]),_0x6a4655[_0x32c4b6('0x32')]=_[_0x32c4b6('0x47')](_0x47cec2['model'],qs[_0x32c4b6('0x91')](_0x1b875f[_0x32c4b6('0x5f')]['fields'])),_0x6a4655['attributes']=_0x6a4655[_0x32c4b6('0x32')][_0x32c4b6('0x5a')]?_0x6a4655[_0x32c4b6('0x32')]:_0x47cec2['model'];typeof _0x1b875f[_0x32c4b6('0x5f')][_0x32c4b6('0x3c')]===_0x32c4b6('0xa')&&(_0x6a4655[_0x32c4b6('0x4')]=qs[_0x32c4b6('0x4')](_0x1b875f[_0x32c4b6('0x5f')][_0x32c4b6('0x4')]),_0x6a4655[_0x32c4b6('0x86')]=qs[_0x32c4b6('0x86')](_0x1b875f['query'][_0x32c4b6('0x86')]));_0x6a4655[_0x32c4b6('0x46')]=qs[_0x32c4b6('0x31')](_0x1b875f[_0x32c4b6('0x5f')][_0x32c4b6('0x31')]),_0x6a4655[_0x32c4b6('0x59')]=qs[_0x32c4b6('0x3f')](_[_0x32c4b6('0x45')](_0x1b875f[_0x32c4b6('0x5f')],_0x47cec2['filters']),_0x45f004);_0x1b875f['query']['filter']&&(_0x6a4655[_0x32c4b6('0x59')]=_[_0x32c4b6('0x1f')](_0x6a4655[_0x32c4b6('0x59')],{[Op['or']]:_[_0x32c4b6('0x30')](_0x45f004,function(_0x17cec2){const _0x5ae548=_0x32c4b6;if(_0x17cec2[_0x5ae548('0x1d')]!==_0x5ae548('0x15')){const _0x1ee042={};return _0x1ee042[_0x17cec2[_0x5ae548('0x7b')]]={[Op['like']]:'%'+_0x1b875f[_0x5ae548('0x5f')][_0x5ae548('0x2d')]+'%'},_0x1ee042;}})}));_0x6a4655=_[_0x32c4b6('0x1f')]({},_0x6a4655,_0x1b875f[_0x32c4b6('0x76')]);const _0x2e7c89={'where':_0x6a4655[_0x32c4b6('0x59')]};return db[_0x32c4b6('0x6')]['count'](_0x2e7c89)[_0x32c4b6('0x23')](function(_0x58b25b){const _0x59e52f=_0x32c4b6;return _0x529881[_0x59e52f('0x95')]=_0x58b25b,_0x1b875f[_0x59e52f('0x5f')]['includeAll']&&(_0x6a4655[_0x59e52f('0x3')]=[{'all':!![]}]),db[_0x59e52f('0x6')][_0x59e52f('0x12')](_0x6a4655);})['then'](function(_0x2dab78){return _0x529881['rows']=_0x2dab78,_0x529881;})['then'](respondWithFilteredResult(_0x1fe08e,_0x6a4655))[_0x32c4b6('0x25')](handleError(_0x1fe08e,null));},exports[_0x37fe33('0x8f')]=function(_0x1a1b47,_0x191a57){const _0x5371c2=_0x37fe33;let _0x27a0b6={'raw':![],'where':{'id':_0x1a1b47['params']['id']}};const _0x4ec254={};return _0x4ec254[_0x5371c2('0x11')]=_['keys'](db[_0x5371c2('0x6')][_0x5371c2('0x7e')]),_0x4ec254[_0x5371c2('0x5f')]=_[_0x5371c2('0x48')](_0x1a1b47['query']),_0x4ec254['filters']=_['intersection'](_0x4ec254[_0x5371c2('0x11')],_0x4ec254[_0x5371c2('0x5f')]),_0x27a0b6[_0x5371c2('0x32')]=_[_0x5371c2('0x47')](_0x4ec254[_0x5371c2('0x11')],qs['fields'](_0x1a1b47[_0x5371c2('0x5f')][_0x5371c2('0x91')])),_0x27a0b6['attributes']=_0x27a0b6['attributes'][_0x5371c2('0x5a')]?_0x27a0b6[_0x5371c2('0x32')]:_0x4ec254['model'],_0x1a1b47['query'][_0x5371c2('0x34')]&&(_0x27a0b6[_0x5371c2('0x3')]=[{'all':!![]}]),_0x27a0b6=_[_0x5371c2('0x1f')]({},_0x27a0b6,_0x1a1b47[_0x5371c2('0x76')]),db[_0x5371c2('0x6')][_0x5371c2('0x39')](_0x27a0b6)[_0x5371c2('0x23')](handleEntityNotFound(_0x191a57,null))[_0x5371c2('0x23')](respondWithResult(_0x191a57,null))[_0x5371c2('0x25')](handleError(_0x191a57,null));},exports[_0x37fe33('0x6a')]=function(_0x22c0c9,_0x5744ca){const _0x1a6f46=_0x37fe33;return db[_0x1a6f46('0x6')]['create'](_0x22c0c9[_0x1a6f46('0x73')],{})['then'](function(_0x4074fa){const _0x39589d=_0x1a6f46,_0x446a4c=_0x22c0c9['user'][_0x39589d('0x4b')]({'plain':!![]});if(!_0x446a4c)throw new Error(_0x39589d('0x60'));if(_0x446a4c[_0x39589d('0x2f')]==='user'){const _0x54c5ea=_0x4074fa[_0x39589d('0x4b')]({'plain':!![]}),_0x2de58d=[{'name':_0x39589d('0x63'),'value':_0x39589d('0x43')},{'name':_0x39589d('0x8c'),'value':_0x39589d('0x88')}],_0x1377b3=_[_0x39589d('0x35')](_0x2de58d,[_0x39589d('0x4a'),_0x54c5ea['type']])[_0x39589d('0x7b')];return db[_0x39589d('0x68')]['findOne']({'where':{'name':_0x1377b3,'userProfileId':_0x446a4c['userProfileId']},'raw':!![]})[_0x39589d('0x23')](function(_0x23d9f5){const _0x5d5459=_0x39589d;return _0x23d9f5&&_0x23d9f5[_0x5d5459('0x7c')]===0x0?db[_0x5d5459('0x1e')][_0x5d5459('0x6a')]({'name':_0x54c5ea[_0x5d5459('0x7b')],'resourceId':_0x54c5ea['id'],'type':_0x23d9f5[_0x5d5459('0x7b')],'sectionId':_0x23d9f5['id']},{})['then'](function(){return _0x4074fa;}):_0x4074fa;})[_0x39589d('0x25')](function(_0x42f730){const _0x26b57a=_0x39589d;logger[_0x26b57a('0x28')](_0x26b57a('0x71'),_0x42f730);throw _0x42f730;});}return _0x4074fa;})[_0x1a6f46('0x23')](respondWithResult(_0x5744ca,0xc9))['catch'](handleError(_0x5744ca,null));},exports[_0x37fe33('0xf')]=function(_0xfadb0c,_0x1f1e15){const _0x26ca33=_0x37fe33;let _0xec9b3a={'where':{'id':_0xfadb0c['params']['id']}};const _0x3f8f05={};return _0x3f8f05['model']=_[_0x26ca33('0x48')](db[_0x26ca33('0x6')]['rawAttributes']),_0xec9b3a['attributes']=_['intersection'](_0x3f8f05[_0x26ca33('0x11')],qs[_0x26ca33('0x91')](_0xfadb0c[_0x26ca33('0x5f')]['fields'])),_0xec9b3a[_0x26ca33('0x32')]=_0xec9b3a[_0x26ca33('0x32')][_0x26ca33('0x5a')]?_0xec9b3a[_0x26ca33('0x32')]:_0x3f8f05['model'],_0xfadb0c[_0x26ca33('0x5f')][_0x26ca33('0x34')]&&(_0xec9b3a['include']=[{'all':!![]}]),_0xec9b3a=_[_0x26ca33('0x1f')]({},_0xec9b3a,_0xfadb0c[_0x26ca33('0x76')]),db[_0x26ca33('0x6')][_0x26ca33('0x39')](_0xec9b3a)[_0x26ca33('0x23')](handleEntityNotFound(_0x1f1e15,null))[_0x26ca33('0x23')](function(_0x19a070){const _0x359932=_0x26ca33;if(_0x19a070){let _0x47d7da=_0x19a070[_0x359932('0x4b')]({'plain':!![]});return _0x47d7da=qs[_0x359932('0x22')](_0x47d7da,['id','createdAt','updatedAt']),_0xfadb0c[_0x359932('0x73')]=_[_0x359932('0x22')](_0xfadb0c[_0x359932('0x73')],['id',_0x359932('0x8e'),'updatedAt']),db[_0x359932('0x6')]['create'](_[_0x359932('0x1f')](_0x47d7da,_0xfadb0c['body']),{'include':_0xfadb0c['query']['includeAll']?[{'all':!![]}]:undefined})[_0x359932('0x23')](function(_0x42d05f){const _0x5c7a41=_0x359932,_0x2e2424=_0xfadb0c[_0x5c7a41('0x82')][_0x5c7a41('0x4b')]({'plain':!![]});if(!_0x2e2424)throw new Error('Unable\x20to\x20retrieve\x20the\x20current\x20user');if(_0x2e2424[_0x5c7a41('0x2f')]===_0x5c7a41('0x82')){const _0x391d97=_0x42d05f[_0x5c7a41('0x4b')]({'plain':!![]}),_0x49d2b6=[{'name':_0x5c7a41('0x63'),'value':_0x5c7a41('0x43')},{'name':_0x5c7a41('0x8c'),'value':_0x5c7a41('0x88')}],_0x55944b=_['find'](_0x49d2b6,[_0x5c7a41('0x4a'),_0x391d97[_0x5c7a41('0x1d')]])[_0x5c7a41('0x7b')];return db[_0x5c7a41('0x68')][_0x5c7a41('0x39')]({'where':{'name':_0x55944b,'userProfileId':_0x2e2424['userProfileId']},'raw':!![]})[_0x5c7a41('0x23')](function(_0x4a1334){const _0x1c443c=_0x5c7a41;return _0x4a1334&&_0x4a1334[_0x1c443c('0x7c')]===0x0?db[_0x1c443c('0x1e')][_0x1c443c('0x6a')]({'name':_0x391d97[_0x1c443c('0x7b')],'resourceId':_0x391d97['id'],'type':_0x4a1334[_0x1c443c('0x7b')],'sectionId':_0x4a1334['id']},{})[_0x1c443c('0x23')](function(){return _0x42d05f;}):_0x42d05f;})['catch'](function(_0x3ab844){const _0x15a93e=_0x5c7a41;logger[_0x15a93e('0x28')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x3ab844);throw _0x3ab844;});}return _0x42d05f;});}})['then'](respondWithResult(_0x1f1e15,0xc9))[_0x26ca33('0x25')](handleError(_0x1f1e15,null));},exports[_0x37fe33('0x55')]=function(_0x5bd230,_0x4eec40){const _0x416b1c=_0x37fe33;return _0x5bd230['body']['id']&&delete _0x5bd230['body']['id'],db[_0x416b1c('0x6')][_0x416b1c('0x39')]({'where':{'id':_0x5bd230['params']['id']}})[_0x416b1c('0x23')](handleEntityNotFound(_0x4eec40,null))['then'](saveUpdates(_0x5bd230[_0x416b1c('0x73')],null))[_0x416b1c('0x23')](respondWithResult(_0x4eec40,null))[_0x416b1c('0x25')](handleError(_0x4eec40,null));},exports[_0x37fe33('0x5d')]=function(_0x7fef20,_0x58696d){const _0x3ad27f=_0x37fe33;return db[_0x3ad27f('0x6')]['findOne']({'where':{'id':_0x7fef20[_0x3ad27f('0x87')]['id']}})[_0x3ad27f('0x23')](handleEntityNotFound(_0x58696d,null))['then'](removeEntity(_0x58696d,null))[_0x3ad27f('0x25')](handleError(_0x58696d,null));},exports['getHoppers']=function(_0x380251,_0x4f3150){const _0x510899=_0x37fe33;let _0x2f2dd5={'raw':![],'where':{}};const _0xfb409={},_0x55b71d={'count':0x0,'rows':[]};return db[_0x510899('0x6')][_0x510899('0x39')]({'where':{'id':_0x380251['params']['id']}})[_0x510899('0x23')](handleEntityNotFound(_0x4f3150,null))['then'](function(_0x2dabd2){const _0x54e046=_0x510899;if(_0x2dabd2)return _0xfb409[_0x54e046('0x11')]=_[_0x54e046('0x48')](db[_0x54e046('0x14')][_0x54e046('0x7e')]),_0xfb409['query']=_['keys'](_0x380251['query']),_0xfb409['filters']=_[_0x54e046('0x47')](_0xfb409[_0x54e046('0x11')],_0xfb409[_0x54e046('0x5f')]),_0x2f2dd5[_0x54e046('0x32')]=_['intersection'](_0xfb409['model'],qs[_0x54e046('0x91')](_0x380251['query'][_0x54e046('0x91')])),_0x2f2dd5[_0x54e046('0x32')]=_0x2f2dd5[_0x54e046('0x32')][_0x54e046('0x5a')]?_0x2f2dd5['attributes']:_0xfb409[_0x54e046('0x11')],typeof _0x380251[_0x54e046('0x5f')][_0x54e046('0x3c')]===_0x54e046('0xa')&&(_0x2f2dd5[_0x54e046('0x4')]=qs['limit'](_0x380251['query'][_0x54e046('0x4')]),_0x2f2dd5[_0x54e046('0x86')]=qs['offset'](_0x380251['query']['offset'])),_0x2f2dd5['order']=qs[_0x54e046('0x31')](_0x380251[_0x54e046('0x5f')]['sort']),_0x2f2dd5[_0x54e046('0x59')]=qs['filters'](_[_0x54e046('0x45')](_0x380251[_0x54e046('0x5f')],_0xfb409[_0x54e046('0x3f')])),_0x2f2dd5[_0x54e046('0x59')][_0x54e046('0x84')]=_0x2dabd2['id'],_0x380251['query'][_0x54e046('0x2d')]&&(_0x2f2dd5[_0x54e046('0x59')]=_[_0x54e046('0x1f')](_0x2f2dd5[_0x54e046('0x59')],{[Op['or']]:_[_0x54e046('0x30')](_0x2f2dd5[_0x54e046('0x32')],function(_0x1d8779){const _0xb80c68=_0x54e046,_0x53722d={};return _0x53722d[_0x1d8779]={[Op[_0xb80c68('0x18')]]:'%'+_0x380251[_0xb80c68('0x5f')][_0xb80c68('0x2d')]+'%'},_0x53722d;})})),_0x2f2dd5=_[_0x54e046('0x1f')]({},_0x2f2dd5,_0x380251[_0x54e046('0x76')]),db[_0x54e046('0x14')]['count']({'where':_0x2f2dd5[_0x54e046('0x59')]})[_0x54e046('0x23')](function(_0x3b75f4){const _0x541590=_0x54e046;return _0x55b71d[_0x541590('0x95')]=_0x3b75f4,_0x380251[_0x541590('0x5f')][_0x541590('0x34')]&&(_0x2f2dd5[_0x541590('0x3')]=[{'all':!![]}]),db[_0x541590('0x14')][_0x541590('0x12')](_0x2f2dd5);})[_0x54e046('0x23')](function(_0x291e56){return _0x55b71d['rows']=_0x291e56,_0x55b71d;});})[_0x510899('0x23')](respondWithFilteredResult(_0x4f3150,_0x2f2dd5))[_0x510899('0x25')](handleError(_0x4f3150,null));},exports[_0x37fe33('0x98')]=function(_0x45ad06,_0x207554){const _0x1031f6=_0x37fe33;let _0x5b45ad={'raw':!![],'where':{}};const _0x520103={},_0x529eff={'count':0x0,'rows':[]};return db['VoiceQueue']['findOne']({'where':{'id':_0x45ad06['params']['id']}})[_0x1031f6('0x23')](handleEntityNotFound(_0x207554,null))['then'](function(_0x34c35d){const _0x29ce2f=_0x1031f6;if(_0x34c35d)return _0x520103[_0x29ce2f('0x11')]=_[_0x29ce2f('0x48')](db['CmHopperHistory'][_0x29ce2f('0x7e')]),_0x520103['query']=_['keys'](_0x45ad06[_0x29ce2f('0x5f')]),_0x520103['filters']=_['intersection'](_0x520103[_0x29ce2f('0x11')],_0x520103[_0x29ce2f('0x5f')]),_0x5b45ad[_0x29ce2f('0x32')]=_[_0x29ce2f('0x47')](_0x520103[_0x29ce2f('0x11')],qs[_0x29ce2f('0x91')](_0x45ad06[_0x29ce2f('0x5f')][_0x29ce2f('0x91')])),_0x5b45ad[_0x29ce2f('0x32')]=_0x5b45ad[_0x29ce2f('0x32')]['length']?_0x5b45ad[_0x29ce2f('0x32')]:_0x520103[_0x29ce2f('0x11')],typeof _0x45ad06['query']['nolimit']==='undefined'&&(_0x5b45ad[_0x29ce2f('0x4')]=qs[_0x29ce2f('0x4')](_0x45ad06[_0x29ce2f('0x5f')][_0x29ce2f('0x4')]),_0x5b45ad['offset']=qs[_0x29ce2f('0x86')](_0x45ad06[_0x29ce2f('0x5f')][_0x29ce2f('0x86')])),_0x5b45ad['order']=qs['sort'](_0x45ad06[_0x29ce2f('0x5f')][_0x29ce2f('0x31')]),_0x5b45ad[_0x29ce2f('0x59')]=qs['filters'](_[_0x29ce2f('0x45')](_0x45ad06['query'],_0x520103[_0x29ce2f('0x3f')])),_0x5b45ad[_0x29ce2f('0x59')][_0x29ce2f('0x84')]=_0x34c35d['id'],_0x45ad06[_0x29ce2f('0x5f')][_0x29ce2f('0x2d')]&&(_0x5b45ad[_0x29ce2f('0x59')]=_[_0x29ce2f('0x1f')](_0x5b45ad[_0x29ce2f('0x59')],{[Op['or']]:_['map'](_0x5b45ad[_0x29ce2f('0x32')],function(_0x121a5d){const _0x3fa72b={};return _0x3fa72b[_0x121a5d]={[Op['like']]:'%'+_0x45ad06['query']['filter']+'%'},_0x3fa72b;})})),_0x5b45ad=_['merge']({},_0x5b45ad,_0x45ad06[_0x29ce2f('0x76')]),db[_0x29ce2f('0xe')][_0x29ce2f('0x95')]({'where':_0x5b45ad[_0x29ce2f('0x59')]})[_0x29ce2f('0x23')](function(_0x3d01b2){const _0x30cfad=_0x29ce2f;return _0x529eff[_0x30cfad('0x95')]=_0x3d01b2,_0x45ad06[_0x30cfad('0x5f')][_0x30cfad('0x34')]&&(_0x5b45ad['include']=[{'all':!![]}]),db[_0x30cfad('0xe')][_0x30cfad('0x12')](_0x5b45ad);})[_0x29ce2f('0x23')](function(_0x16d019){return _0x529eff['rows']=_0x16d019,_0x529eff;});})[_0x1031f6('0x23')](respondWithFilteredResult(_0x207554,_0x5b45ad))[_0x1031f6('0x25')](handleError(_0x207554,null));},exports['getHopperFinals']=function(_0x429f3d,_0x4faf42){const _0x47c0f0=_0x37fe33;let _0x2b1a2f={'raw':!![],'where':{}};const _0x23d8d3={},_0xbb9979={'count':0x0,'rows':[]};return db[_0x47c0f0('0x6')][_0x47c0f0('0x39')]({'where':{'id':_0x429f3d['params']['id']}})[_0x47c0f0('0x23')](handleEntityNotFound(_0x4faf42,null))['then'](function(_0x2f33e2){const _0x22e756=_0x47c0f0;if(_0x2f33e2)return _0x23d8d3[_0x22e756('0x11')]=_[_0x22e756('0x48')](db[_0x22e756('0x10')]['rawAttributes']),_0x23d8d3[_0x22e756('0x5f')]=_[_0x22e756('0x48')](_0x429f3d[_0x22e756('0x5f')]),_0x23d8d3[_0x22e756('0x3f')]=_['intersection'](_0x23d8d3[_0x22e756('0x11')],_0x23d8d3['query']),_0x2b1a2f[_0x22e756('0x32')]=_['intersection'](_0x23d8d3[_0x22e756('0x11')],qs[_0x22e756('0x91')](_0x429f3d['query'][_0x22e756('0x91')])),_0x2b1a2f[_0x22e756('0x32')]=_0x2b1a2f[_0x22e756('0x32')][_0x22e756('0x5a')]?_0x2b1a2f[_0x22e756('0x32')]:_0x23d8d3['model'],typeof _0x429f3d[_0x22e756('0x5f')]['nolimit']===_0x22e756('0xa')&&(_0x2b1a2f[_0x22e756('0x4')]=qs[_0x22e756('0x4')](_0x429f3d[_0x22e756('0x5f')]['limit']),_0x2b1a2f[_0x22e756('0x86')]=qs[_0x22e756('0x86')](_0x429f3d['query'][_0x22e756('0x86')])),_0x2b1a2f[_0x22e756('0x46')]=qs[_0x22e756('0x31')](_0x429f3d[_0x22e756('0x5f')][_0x22e756('0x31')]),_0x2b1a2f[_0x22e756('0x59')]=qs[_0x22e756('0x3f')](_[_0x22e756('0x45')](_0x429f3d['query'],_0x23d8d3[_0x22e756('0x3f')])),_0x2b1a2f['where']['VoiceQueueId']=_0x2f33e2['id'],_0x429f3d[_0x22e756('0x5f')][_0x22e756('0x2d')]&&(_0x2b1a2f[_0x22e756('0x59')]=_['merge'](_0x2b1a2f[_0x22e756('0x59')],{[Op['or']]:_[_0x22e756('0x30')](_0x2b1a2f[_0x22e756('0x32')],function(_0x1840a9){const _0x41ac06=_0x22e756,_0x439b9a={};return _0x439b9a[_0x1840a9]={[Op[_0x41ac06('0x18')]]:'%'+_0x429f3d['query'][_0x41ac06('0x2d')]+'%'},_0x439b9a;})})),_0x2b1a2f=_[_0x22e756('0x1f')]({},_0x2b1a2f,_0x429f3d['options']),db[_0x22e756('0x10')]['count']({'where':_0x2b1a2f['where']})[_0x22e756('0x23')](function(_0x4fbb69){const _0xc076d=_0x22e756;return _0xbb9979[_0xc076d('0x95')]=_0x4fbb69,_0x429f3d['query'][_0xc076d('0x34')]&&(_0x2b1a2f['include']=[{'all':!![]}]),db['CmHopperFinal'][_0xc076d('0x12')](_0x2b1a2f);})[_0x22e756('0x23')](function(_0x5cb717){const _0x2a4883=_0x22e756;return _0xbb9979[_0x2a4883('0x49')]=_0x5cb717,_0xbb9979;});})[_0x47c0f0('0x23')](respondWithFilteredResult(_0x4faf42,_0x2b1a2f))[_0x47c0f0('0x25')](handleError(_0x4faf42,null));},exports[_0x37fe33('0x2')]=function(_0x13a0d6,_0x1e2a6e){const _0x4a0737=_0x37fe33;let _0x5d43d7={'raw':!![],'where':{}};const _0x1b8c60={},_0x5488e8={'count':0x0,'rows':[]};return db[_0x4a0737('0x6')][_0x4a0737('0x39')]({'where':{'id':_0x13a0d6[_0x4a0737('0x87')]['id']}})[_0x4a0737('0x23')](handleEntityNotFound(_0x1e2a6e,null))[_0x4a0737('0x23')](function(_0x2b3af2){const _0x157280=_0x4a0737;if(_0x2b3af2)return _0x1b8c60['model']=_[_0x157280('0x48')](db[_0x157280('0x6e')]['rawAttributes']),_0x1b8c60[_0x157280('0x5f')]=_[_0x157280('0x48')](_0x13a0d6[_0x157280('0x5f')]),_0x1b8c60[_0x157280('0x3f')]=_[_0x157280('0x47')](_0x1b8c60[_0x157280('0x11')],_0x1b8c60[_0x157280('0x5f')]),_0x5d43d7[_0x157280('0x32')]=_['intersection'](_0x1b8c60[_0x157280('0x11')],qs[_0x157280('0x91')](_0x13a0d6[_0x157280('0x5f')]['fields'])),_0x5d43d7[_0x157280('0x32')]=_0x5d43d7['attributes'][_0x157280('0x5a')]?_0x5d43d7['attributes']:_0x1b8c60['model'],typeof _0x13a0d6[_0x157280('0x5f')][_0x157280('0x3c')]==='undefined'&&(_0x5d43d7[_0x157280('0x4')]=qs['limit'](_0x13a0d6[_0x157280('0x5f')][_0x157280('0x4')]),_0x5d43d7[_0x157280('0x86')]=qs[_0x157280('0x86')](_0x13a0d6[_0x157280('0x5f')][_0x157280('0x86')])),_0x5d43d7[_0x157280('0x46')]=qs[_0x157280('0x31')](_0x13a0d6[_0x157280('0x5f')][_0x157280('0x31')]),_0x5d43d7['where']=qs[_0x157280('0x3f')](_[_0x157280('0x45')](_0x13a0d6[_0x157280('0x5f')],_0x1b8c60[_0x157280('0x3f')])),_0x5d43d7[_0x157280('0x59')][_0x157280('0x84')]=_0x2b3af2['id'],_0x13a0d6[_0x157280('0x5f')][_0x157280('0x2d')]&&(_0x5d43d7[_0x157280('0x59')]=_[_0x157280('0x1f')](_0x5d43d7['where'],{[Op['or']]:_['map'](_0x5d43d7['attributes'],function(_0xd1b95b){const _0x599976=_0x157280,_0x1ee7bc={};return _0x1ee7bc[_0xd1b95b]={[Op['like']]:'%'+_0x13a0d6[_0x599976('0x5f')]['filter']+'%'},_0x1ee7bc;})})),_0x5d43d7=_[_0x157280('0x1f')]({},_0x5d43d7,_0x13a0d6[_0x157280('0x76')]),db[_0x157280('0x6e')]['count']({'where':_0x5d43d7[_0x157280('0x59')]})[_0x157280('0x23')](function(_0x5827c6){const _0x170fd9=_0x157280;return _0x5488e8[_0x170fd9('0x95')]=_0x5827c6,_0x13a0d6[_0x170fd9('0x5f')][_0x170fd9('0x34')]&&(_0x5d43d7[_0x170fd9('0x3')]=[{'all':!![]}]),db['CmHopperBlack'][_0x170fd9('0x12')](_0x5d43d7);})['then'](function(_0x113d40){const _0x3b1114=_0x157280;return _0x5488e8[_0x3b1114('0x49')]=_0x113d40,_0x5488e8;});})['then'](respondWithFilteredResult(_0x1e2a6e,_0x5d43d7))[_0x4a0737('0x25')](handleError(_0x1e2a6e,null));},exports[_0x37fe33('0x89')]=function(_0x38c1c8,_0x10a304){const _0x13504b=_0x37fe33;let _0x35feeb={};const _0x4ce944={};let _0x1bba36,_0x13366b;return db['VoiceQueue']['findOne']({'where':{'id':_0x38c1c8[_0x13504b('0x87')]['id']}})['then'](handleEntityNotFound(_0x10a304,null))[_0x13504b('0x23')](function(_0x1cff38){const _0x486e51=_0x13504b;if(_0x1cff38)return _0x1bba36=_0x1cff38,_0x4ce944['model']=_[_0x486e51('0x48')](db[_0x486e51('0x33')]['rawAttributes']),_0x4ce944['query']=_[_0x486e51('0x48')](_0x38c1c8[_0x486e51('0x5f')]),_0x4ce944['filters']=_[_0x486e51('0x47')](_0x4ce944['model'],_0x4ce944['query']),_0x35feeb['attributes']=_[_0x486e51('0x47')](_0x4ce944['model'],qs['fields'](_0x38c1c8['query'][_0x486e51('0x91')])),_0x35feeb[_0x486e51('0x32')]=_0x35feeb[_0x486e51('0x32')][_0x486e51('0x5a')]?_0x35feeb['attributes']:_0x4ce944[_0x486e51('0x11')],_0x35feeb['order']=qs['sort'](_0x38c1c8[_0x486e51('0x5f')]['sort']),_0x35feeb[_0x486e51('0x59')]=qs[_0x486e51('0x3f')](_[_0x486e51('0x45')](_0x38c1c8[_0x486e51('0x5f')],_0x4ce944[_0x486e51('0x3f')])),_0x38c1c8['query']['filter']&&(_0x35feeb['where']=_[_0x486e51('0x1f')](_0x35feeb[_0x486e51('0x59')],{[Op['or']]:_[_0x486e51('0x30')](_0x35feeb[_0x486e51('0x32')],function(_0xdd8ec){const _0x804321=_0x486e51,_0x564f4b={};return _0x564f4b[_0xdd8ec]={[Op['like']]:'%'+_0x38c1c8[_0x804321('0x5f')]['filter']+'%'},_0x564f4b;})})),_0x35feeb=_[_0x486e51('0x1f')]({},_0x35feeb,_0x38c1c8[_0x486e51('0x76')]),_0x1bba36[_0x486e51('0x89')](_0x35feeb);})[_0x13504b('0x23')](function(_0x54adf8){const _0x1def7a=_0x13504b;if(_0x54adf8)return _0x13366b=_0x54adf8[_0x1def7a('0x5a')],typeof _0x38c1c8[_0x1def7a('0x5f')][_0x1def7a('0x3c')]==='undefined'&&(_0x35feeb[_0x1def7a('0x4')]=qs['limit'](_0x38c1c8[_0x1def7a('0x5f')][_0x1def7a('0x4')]),_0x35feeb['offset']=qs['offset'](_0x38c1c8[_0x1def7a('0x5f')]['offset'])),_0x1bba36[_0x1def7a('0x89')](_0x35feeb);})[_0x13504b('0x23')](function(_0x379883){if(_0x379883)return _0x379883?{'count':_0x13366b,'rows':_0x379883}:null;})[_0x13504b('0x23')](respondWithResult(_0x10a304,null))['catch'](handleError(_0x10a304,null));},exports['addTeams']=function(_0x2a5f6f,_0x4f463b){const _0x46cfce=_0x37fe33,_0x4bb8ed=_0x2a5f6f[_0x46cfce('0x73')][_0x46cfce('0x17')],_0x4a9228=_[_0x46cfce('0x30')](_0x4bb8ed,'id');return db[_0x46cfce('0x33')][_0x46cfce('0x12')]({'where':{'id':_0x4a9228},'attributes':['id'],'include':[{'model':db[_0x46cfce('0x51')],'as':_0x46cfce('0x54'),'attributes':['id','name','online','voicePause','interface'],'raw':!![]}]})[_0x46cfce('0x23')](function(_0x4fc440){const _0x58ecae=_0x46cfce;if(_0x4fc440){const _0x260ca4=_[_0x58ecae('0x0')](_0x4fc440,function(_0x4d8eeb){const _0x286943=_0x58ecae,_0x206f3f=_0x4d8eeb[_0x286943('0x4b')]({'plain':!![]});return _0x206f3f[_0x286943('0x54')][_0x286943('0x92')](function(_0x3e6850){const _0x10df01=_0x286943;_0x3e6850[_0x10df01('0x61')]=_[_0x10df01('0x35')](_0x4bb8ed,{'id':_0x206f3f['id']})[_0x10df01('0x61')];}),_0x206f3f['Agents'];});return db[_0x58ecae('0x6')][_0x58ecae('0x39')]({'where':{'id':_0x2a5f6f[_0x58ecae('0x87')]['id']}})[_0x58ecae('0x23')](function(_0x4787b4){const _0x1949b2=_0x58ecae;return db['sequelize'][_0x1949b2('0x78')](function(_0x20df87){const _0x1e066=_0x1949b2;return _0x4787b4[_0x1e066('0x3e')](_0x4a9228,{'transaction':_0x20df87})[_0x1e066('0x23')](function(){const _0x4ce995=_0x1e066;return Promise[_0x4ce995('0x2b')](_0x260ca4,function(_0x5ed22a){const _0x517d50=_0x4ce995;return db[_0x517d50('0x6c')][_0x517d50('0x74')]({'where':{'UserId':_0x5ed22a['id'],'VoiceQueueId':_0x2a5f6f[_0x517d50('0x87')]['id']},'defaults':{'penalty':_0x5ed22a[_0x517d50('0x61')]},'transaction':_0x20df87});});})['then'](function(){return Promise['each'](_['filter'](_0x260ca4,{'online':!![]}),function(_0xd707c5){const _0x6a9462=a753_0x39ba;return db[_0x6a9462('0x1a')][_0x6a9462('0x9')]({'membername':_0xd707c5[_0x6a9462('0x7b')],'UserId':_0xd707c5['id'],'queue_name':_0x4787b4[_0x6a9462('0x7b')],'VoiceQueueId':_0x4787b4['id'],'interface':_[_0x6a9462('0x1')](_0xd707c5[_0x6a9462('0x50')])?util[_0x6a9462('0x52')](_0x6a9462('0x19'),_0xd707c5['name']):_0xd707c5['interface'],'paused':_0xd707c5[_0x6a9462('0x42')]||![],'penalty':_0xd707c5[_0x6a9462('0x61')]},{'transaction':_0x20df87});});})[_0x1e066('0x23')](function(){const _0x33a52b=_0x1e066;_0x260ca4[_0x33a52b('0x92')](function(_0x20c71c){const _0x446db1=_0x33a52b;socket[_0x446db1('0x44')](_0x446db1('0x3b'),{'UserId':_0x20c71c['id'],'VoiceQueueId':_0x4787b4['id']});});});});});}})[_0x46cfce('0x23')](respondWithStatusCode(_0x4f463b,null))['catch'](handleError(_0x4f463b,null));},exports[_0x37fe33('0x40')]=function(_0x2ff008,_0x4c4e20){const _0x2138d9=_0x37fe33;return db[_0x2138d9('0x33')][_0x2138d9('0x12')]({'where':{'id':_0x2ff008['query'][_0x2138d9('0xd')]},'attributes':['id'],'include':[{'model':db[_0x2138d9('0x51')],'as':_0x2138d9('0x54'),'attributes':['id'],'raw':!![]}]})[_0x2138d9('0x23')](handleEntityNotFound(_0x4c4e20,null))['then'](function(_0xc41330){const _0xa31694=_0x2138d9,_0x26137a=_[_0xa31694('0x30')](_0xc41330,'id');let _0xc7a2dc=[];const _0x5a9594=[],_0x3e9ceb=squel[_0xa31694('0x29')]();_0x3e9ceb['field'](_0xa31694('0x7f'))[_0xa31694('0x16')]('team_has_voice_queues','tq')['join'](_0xa31694('0x83'),'ut','ut.TeamId\x20=\x20tq.TeamId')[_0xa31694('0x59')]('VoiceQueueId\x20=\x20?',_0x2ff008[_0xa31694('0x87')]['id']);for(let _0x54ddef=0x0;_0x54ddef<_0xc41330[_0xa31694('0x5a')];_0x54ddef+=0x1){const _0x5c833e=_0xc41330[_0x54ddef];for(let _0x4f5f1d=0x0;_0x4f5f1d<_0x5c833e[_0xa31694('0x54')][_0xa31694('0x5a')];_0x4f5f1d+=0x1){const _0x195fbe=_0x5c833e[_0xa31694('0x54')][_0x4f5f1d],_0x50bc35=_0x3e9ceb[_0xa31694('0xf')]();_0x50bc35['where'](_0xa31694('0x62'),_0x195fbe['id']),_0x5a9594['push'](db[_0xa31694('0x1b')][_0xa31694('0x5f')](_0x50bc35[_0xa31694('0x27')](),{'type':QueryTypes[_0xa31694('0x97')]})[_0xa31694('0x23')](function(_0x5e2f80){const _0x18660d=_0xa31694;if(_0x5e2f80[_0x18660d('0x5a')]===0x1)return _0x195fbe['id'];else{const _0x228892=_['every'](_[_0x18660d('0x30')](_0x5e2f80,_0x18660d('0x75')),function(_0x3523df){const _0x401407=_0x18660d;return _[_0x401407('0x13')](_0x26137a,_0x3523df);});if(_0x228892)return _0x195fbe['id'];}}));}}return Promise[_0xa31694('0x64')](_0x5a9594)[_0xa31694('0x23')](function(_0x2b4a49){const _0x2fb1b1=_0xa31694;return _0xc7a2dc=_(_0xc7a2dc)[_0x2fb1b1('0x1c')](_0x2b4a49)[_0x2fb1b1('0x85')]()[_0x2fb1b1('0x4a')](),db['VoiceQueue'][_0x2fb1b1('0x39')]({'where':{'id':_0x2ff008[_0x2fb1b1('0x87')]['id']}})[_0x2fb1b1('0x23')](function(_0x40944b){const _0xcc60d2=_0x2fb1b1;return db[_0xcc60d2('0x1b')][_0xcc60d2('0x78')](function(_0x1e8572){const _0xe2e75c=_0xcc60d2;return _0x40944b['removeTeams'](_0x2ff008[_0xe2e75c('0x5f')][_0xe2e75c('0xd')],{'transaction':_0x1e8572})[_0xe2e75c('0x23')](function(){const _0x3ccc55=_0xe2e75c;if(!_[_0x3ccc55('0x96')](_0xc7a2dc))return _0x40944b[_0x3ccc55('0x53')](_0xc7a2dc,{'transaction':_0x1e8572})[_0x3ccc55('0x23')](function(){const _0xd241f4=_0x3ccc55;return db[_0xd241f4('0x1a')][_0xd241f4('0x5d')]({'where':{'VoiceQueueId':_0x2ff008['params']['id'],'UserId':_0xc7a2dc},'transaction':_0x1e8572});});})[_0xe2e75c('0x23')](function(){const _0x5942de=_0xe2e75c;_0xc7a2dc[_0x5942de('0x92')](function(_0x59cfaf){const _0x532ecb=_0x5942de;socket[_0x532ecb('0x44')](_0x532ecb('0x36'),{'UserId':_0x59cfaf,'VoiceQueueId':_0x40944b['id']});});});});});});})[_0x2138d9('0x23')](respondWithStatusCode(_0x4c4e20,null))['catch'](handleError(_0x4c4e20,null));},exports[_0x37fe33('0x5c')]=function(_0x4f0ea0,_0x228c8f){const _0x35ce1b=_0x37fe33;let _0xc921c0,_0x54fd8f;return db[_0x35ce1b('0x6')][_0x35ce1b('0x39')]({'where':{'id':_0x4f0ea0[_0x35ce1b('0x87')]['id']}})[_0x35ce1b('0x23')](function(_0x16cded){const _0x2c0b2e=_0x35ce1b;if(_0x16cded)return _0x54fd8f=_0x16cded,_0x16cded[_0x2c0b2e('0x5c')](_0x4f0ea0[_0x2c0b2e('0x73')]['ids'],{'through':_['omit'](_0x4f0ea0[_0x2c0b2e('0x73')],[_0x2c0b2e('0xd'),'id'])})[_0x2c0b2e('0x23')](function(_0x562c75){const _0x4440d1=_0x2c0b2e;for(let _0xc7b1fb=0x0;_0xc7b1fb<_0x4f0ea0[_0x4440d1('0x73')][_0x4440d1('0xd')][_0x4440d1('0x5a')];_0xc7b1fb+=0x1){socket['emit'](_0x4440d1('0x3b'),{'UserId':_0x4f0ea0['body'][_0x4440d1('0xd')][_0xc7b1fb],'VoiceQueueId':_0x4f0ea0[_0x4440d1('0x87')]['id']});}return _0x562c75;});})[_0x35ce1b('0x23')](function(_0x422eed){const _0x455e85=_0x35ce1b;_0xc921c0=_0x422eed||[];if(_0x54fd8f)return db[_0x455e85('0x51')][_0x455e85('0x12')]({'where':{'id':_0x4f0ea0[_0x455e85('0x73')][_0x455e85('0xd')]},'attributes':['id',_0x455e85('0x7b'),_0x455e85('0x8d'),_0x455e85('0x42'),_0x455e85('0x50')],'raw':!![]});})[_0x35ce1b('0x23')](function(_0x2d3ec4){const _0x360746=_0x35ce1b;if(!_[_0x360746('0x96')](_0x2d3ec4)){const _0x5c0d96=[];for(let _0x2e8ca0=0x0;_0x2e8ca0<_0x2d3ec4[_0x360746('0x5a')];_0x2e8ca0++){_0x2d3ec4[_0x2e8ca0]['online']&&_0x5c0d96[_0x360746('0x58')](db[_0x360746('0x1a')]['upsert']({'membername':_0x2d3ec4[_0x2e8ca0][_0x360746('0x7b')],'UserId':_0x2d3ec4[_0x2e8ca0]['id'],'queue_name':_0x54fd8f['name'],'VoiceQueueId':_0x54fd8f['id'],'interface':_['isNil'](_0x2d3ec4[_0x2e8ca0][_0x360746('0x50')])?util[_0x360746('0x52')](_0x360746('0x19'),_0x2d3ec4[_0x2e8ca0][_0x360746('0x7b')]):_0x2d3ec4[_0x2e8ca0]['interface'],'paused':_0x2d3ec4[_0x2e8ca0][_0x360746('0x42')]||![],'penalty':_0x4f0ea0['body'][_0x360746('0x61')]||0x0}));}return Promise[_0x360746('0x64')](_0x5c0d96);}})[_0x35ce1b('0x23')](function(){return _0xc921c0;})[_0x35ce1b('0x23')](respondWithResult(_0x228c8f,null))[_0x35ce1b('0x25')](handleError(_0x228c8f,null));},exports[_0x37fe33('0x53')]=function(_0x1423eb,_0x2a0cb4){const _0x4a5ac8=_0x37fe33;return db[_0x4a5ac8('0x6')][_0x4a5ac8('0x39')]({'where':{'id':_0x1423eb[_0x4a5ac8('0x87')]['id']}})['then'](handleEntityNotFound(_0x2a0cb4,null))[_0x4a5ac8('0x23')](function(_0x2929f0){const _0x38b776=_0x4a5ac8;if(_0x2929f0)return _0x2929f0[_0x38b776('0x53')](_0x1423eb[_0x38b776('0x5f')]['ids'])['then'](function(){const _0x1adc49=_0x38b776;if(_['isArray'](_0x1423eb['query'][_0x1adc49('0xd')]))for(let _0x114f79=0x0;_0x114f79<_0x1423eb[_0x1adc49('0x5f')][_0x1adc49('0xd')][_0x1adc49('0x5a')];_0x114f79+=0x1){socket['emit'](_0x1adc49('0x36'),{'UserId':Number(_0x1423eb['query'][_0x1adc49('0xd')][_0x114f79]),'VoiceQueueId':Number(_0x1423eb[_0x1adc49('0x87')]['id'])});}else socket['emit'](_0x1adc49('0x36'),{'UserId':Number(_0x1423eb['query'][_0x1adc49('0xd')]),'VoiceQueueId':Number(_0x1423eb[_0x1adc49('0x87')]['id'])});});})[_0x4a5ac8('0x23')](function(_0x28b8dd){const _0x15ad6f=_0x4a5ac8;return db[_0x15ad6f('0x1a')][_0x15ad6f('0x5d')]({'where':{'VoiceQueueId':_0x1423eb[_0x15ad6f('0x87')]['id'],'UserId':_0x1423eb['query']['ids']}})[_0x15ad6f('0x23')](function(){return _0x28b8dd;});})[_0x4a5ac8('0x23')](respondWithStatusCode(_0x2a0cb4,null))[_0x4a5ac8('0x25')](handleError(_0x2a0cb4,null));},exports[_0x37fe33('0x20')]=function(_0xa89ec1,_0x2e0418){const _0x497c05=_0x37fe33;let _0x107fd8={};const _0x59f6f1={};let _0x47c34,_0x434363;return db[_0x497c05('0x6')][_0x497c05('0x39')]({'where':{'id':_0xa89ec1[_0x497c05('0x87')]['id']}})['then'](handleEntityNotFound(_0x2e0418,null))[_0x497c05('0x23')](function(_0x46f989){const _0x4b9315=_0x497c05;if(_0x46f989)return _0x47c34=_0x46f989,_0x59f6f1[_0x4b9315('0x11')]=_[_0x4b9315('0x48')](db['User']['rawAttributes']),_0x59f6f1[_0x4b9315('0x5f')]=_[_0x4b9315('0x48')](_0xa89ec1[_0x4b9315('0x5f')]),_0x59f6f1[_0x4b9315('0x3f')]=_[_0x4b9315('0x47')](_0x59f6f1[_0x4b9315('0x11')],_0x59f6f1['query']),_0x107fd8[_0x4b9315('0x32')]=_[_0x4b9315('0x47')](_0x59f6f1[_0x4b9315('0x11')],qs[_0x4b9315('0x91')](_0xa89ec1['query']['fields'])),_0x107fd8[_0x4b9315('0x32')]=_0x107fd8['attributes']['length']?_0x107fd8[_0x4b9315('0x32')]:_0x59f6f1[_0x4b9315('0x11')],_0x107fd8[_0x4b9315('0x46')]=qs[_0x4b9315('0x31')](_0xa89ec1[_0x4b9315('0x5f')][_0x4b9315('0x31')]),_0x107fd8['where']=qs[_0x4b9315('0x3f')](_[_0x4b9315('0x45')](_0xa89ec1['query'],_0x59f6f1['filters'])),_0xa89ec1['query'][_0x4b9315('0x2d')]&&(_0x107fd8[_0x4b9315('0x59')]=_[_0x4b9315('0x1f')](_0x107fd8[_0x4b9315('0x59')],{[Op['or']]:_[_0x4b9315('0x30')](_0x107fd8[_0x4b9315('0x32')],function(_0x8710db){const _0x5165e2=_0x4b9315,_0x5dd2fb={};return _0x5dd2fb[_0x8710db]={[Op[_0x5165e2('0x18')]]:'%'+_0xa89ec1['query'][_0x5165e2('0x2d')]+'%'},_0x5dd2fb;})})),_0x107fd8=_[_0x4b9315('0x1f')]({},_0x107fd8,_0xa89ec1[_0x4b9315('0x76')]),_0x47c34[_0x4b9315('0x20')](_0x107fd8);})['then'](function(_0x5ab7e3){const _0x597f90=_0x497c05;if(_0x5ab7e3)return _0x434363=_0x5ab7e3[_0x597f90('0x5a')],typeof _0xa89ec1['query']['nolimit']===_0x597f90('0xa')&&(_0x107fd8['limit']=qs[_0x597f90('0x4')](_0xa89ec1[_0x597f90('0x5f')][_0x597f90('0x4')]),_0x107fd8['offset']=qs['offset'](_0xa89ec1[_0x597f90('0x5f')][_0x597f90('0x86')])),_0x47c34[_0x597f90('0x20')](_0x107fd8);})[_0x497c05('0x23')](function(_0x3e4ae8){if(_0x3e4ae8)return _0x3e4ae8?{'count':_0x434363,'rows':_0x3e4ae8}:null;})[_0x497c05('0x23')](respondWithResult(_0x2e0418,null))[_0x497c05('0x25')](handleError(_0x2e0418,null));},exports[_0x37fe33('0x8b')]=function(_0x48f54c,_0x2e8b76){const _0x404dcf=_0x37fe33;let _0x2621d6={};const _0x898978={};let _0x5b42b4,_0x522ce7;return db['VoiceQueue'][_0x404dcf('0x39')]({'where':{'id':_0x48f54c['params']['id']}})[_0x404dcf('0x23')](handleEntityNotFound(_0x2e8b76,null))[_0x404dcf('0x23')](function(_0x2d3bc2){const _0x28b572=_0x404dcf;if(_0x2d3bc2)return _0x5b42b4=_0x2d3bc2,_0x898978['model']=_[_0x28b572('0x48')](db[_0x28b572('0x1a')]['rawAttributes']),_0x898978[_0x28b572('0x5f')]=_['keys'](_0x48f54c[_0x28b572('0x5f')]),_0x898978[_0x28b572('0x3f')]=_[_0x28b572('0x47')](_0x898978[_0x28b572('0x11')],_0x898978[_0x28b572('0x5f')]),_0x2621d6[_0x28b572('0x32')]=_['intersection'](_0x898978['model'],qs[_0x28b572('0x91')](_0x48f54c['query'][_0x28b572('0x91')])),_0x2621d6[_0x28b572('0x32')]=_0x2621d6[_0x28b572('0x32')]['length']?_0x2621d6['attributes']:_0x898978[_0x28b572('0x11')],_0x2621d6['order']=qs[_0x28b572('0x31')](_0x48f54c[_0x28b572('0x5f')][_0x28b572('0x31')]),_0x2621d6[_0x28b572('0x59')]=qs['filters'](_[_0x28b572('0x45')](_0x48f54c['query'],_0x898978[_0x28b572('0x3f')])),_0x48f54c['query'][_0x28b572('0x2d')]&&(_0x2621d6[_0x28b572('0x59')]=_['merge'](_0x2621d6['where'],{[Op['or']]:_[_0x28b572('0x30')](_0x2621d6['attributes'],function(_0xbd6901){const _0x28cb56=_0x28b572,_0x3a5e1a={};return _0x3a5e1a[_0xbd6901]={[Op[_0x28cb56('0x18')]]:'%'+_0x48f54c[_0x28cb56('0x5f')][_0x28cb56('0x2d')]+'%'},_0x3a5e1a;})})),_0x2621d6=_[_0x28b572('0x1f')]({},_0x2621d6,_0x48f54c['options']),_0x5b42b4[_0x28b572('0x8b')](_0x2621d6);})['then'](function(_0x49db17){const _0x498778=_0x404dcf;if(_0x49db17)return _0x522ce7=_0x49db17[_0x498778('0x5a')],typeof _0x48f54c[_0x498778('0x5f')][_0x498778('0x3c')]===_0x498778('0xa')&&(_0x2621d6[_0x498778('0x4')]=qs[_0x498778('0x4')](_0x48f54c[_0x498778('0x5f')][_0x498778('0x4')]),_0x2621d6['offset']=qs[_0x498778('0x86')](_0x48f54c[_0x498778('0x5f')][_0x498778('0x86')])),_0x5b42b4[_0x498778('0x8b')](_0x2621d6);})[_0x404dcf('0x23')](function(_0x1e91af){return _0x1e91af?{'count':_0x522ce7,'rows':_0x1e91af}:null;})[_0x404dcf('0x23')](respondWithResult(_0x2e8b76,null))[_0x404dcf('0x25')](handleError(_0x2e8b76,null));},exports['getLists']=function(_0x41fbc9,_0x38997e){const _0x28e85d=_0x37fe33;let _0x37befc={};const _0xaacfb6={};let _0xd1ee97,_0x290950;return db[_0x28e85d('0x6')][_0x28e85d('0x39')]({'where':{'id':_0x41fbc9[_0x28e85d('0x87')]['id']}})['then'](handleEntityNotFound(_0x38997e,null))['then'](function(_0x300f1d){const _0x3bffa2=_0x28e85d;if(_0x300f1d)return _0xd1ee97=_0x300f1d,_0xaacfb6[_0x3bffa2('0x11')]=_[_0x3bffa2('0x48')](db[_0x3bffa2('0x24')][_0x3bffa2('0x7e')]),_0xaacfb6[_0x3bffa2('0x5f')]=_['keys'](_0x41fbc9[_0x3bffa2('0x5f')]),_0xaacfb6[_0x3bffa2('0x3f')]=_[_0x3bffa2('0x47')](_0xaacfb6[_0x3bffa2('0x11')],_0xaacfb6[_0x3bffa2('0x5f')]),_0x37befc[_0x3bffa2('0x32')]=_[_0x3bffa2('0x47')](_0xaacfb6[_0x3bffa2('0x11')],qs[_0x3bffa2('0x91')](_0x41fbc9[_0x3bffa2('0x5f')]['fields'])),_0x37befc[_0x3bffa2('0x32')]=_0x37befc[_0x3bffa2('0x32')][_0x3bffa2('0x5a')]?_0x37befc['attributes']:_0xaacfb6[_0x3bffa2('0x11')],_0x37befc[_0x3bffa2('0x46')]=qs[_0x3bffa2('0x31')](_0x41fbc9['query']['sort']),_0x37befc[_0x3bffa2('0x59')]=qs[_0x3bffa2('0x3f')](_['pick'](_0x41fbc9[_0x3bffa2('0x5f')],_0xaacfb6[_0x3bffa2('0x3f')])),_0x41fbc9[_0x3bffa2('0x5f')][_0x3bffa2('0x2d')]&&(_0x37befc[_0x3bffa2('0x59')]=_[_0x3bffa2('0x1f')](_0x37befc[_0x3bffa2('0x59')],{[Op['or']]:_[_0x3bffa2('0x30')](_0x37befc[_0x3bffa2('0x32')],function(_0x23cbf7){const _0x336a92=_0x3bffa2,_0x493362={};return _0x493362[_0x23cbf7]={[Op['like']]:'%'+_0x41fbc9[_0x336a92('0x5f')][_0x336a92('0x2d')]+'%'},_0x493362;})})),_0x37befc=_[_0x3bffa2('0x1f')]({},_0x37befc,_0x41fbc9[_0x3bffa2('0x76')]),_0xd1ee97[_0x3bffa2('0x69')](_0x37befc);})[_0x28e85d('0x23')](function(_0x508c91){const _0x5ae2b=_0x28e85d;if(_0x508c91)return _0x290950=_0x508c91[_0x5ae2b('0x5a')],typeof _0x41fbc9[_0x5ae2b('0x5f')][_0x5ae2b('0x3c')]===_0x5ae2b('0xa')&&(_0x37befc[_0x5ae2b('0x4')]=qs[_0x5ae2b('0x4')](_0x41fbc9[_0x5ae2b('0x5f')]['limit']),_0x37befc[_0x5ae2b('0x86')]=qs[_0x5ae2b('0x86')](_0x41fbc9[_0x5ae2b('0x5f')][_0x5ae2b('0x86')])),_0xd1ee97[_0x5ae2b('0x69')](_0x37befc);})['then'](function(_0x19e7cc){if(_0x19e7cc)return _0x19e7cc?{'count':_0x290950,'rows':_0x19e7cc}:null;})[_0x28e85d('0x23')](respondWithResult(_0x38997e,null))[_0x28e85d('0x25')](handleError(_0x38997e,null));},exports[_0x37fe33('0x56')]=function(_0x49d136,_0x49a9d3){const _0x45159a=_0x37fe33;let _0x21f0a1,_0xea0ae6;return db[_0x45159a('0x6')][_0x45159a('0x39')]({'where':{'id':_0x49d136[_0x45159a('0x87')]['id']}})[_0x45159a('0x23')](handleEntityNotFound(_0x49a9d3,null))[_0x45159a('0x23')](function(_0x36ffae){const _0x443263=_0x45159a;if(_0x36ffae)return _0xea0ae6=_0x36ffae,_0x36ffae[_0x443263('0x56')](_0x49d136[_0x443263('0x73')][_0x443263('0xd')],{'through':_[_0x443263('0x22')](_0x49d136[_0x443263('0x73')],['ids','id'])});return null;})[_0x45159a('0x23')](function(_0x56af16){const _0x19f493=_0x45159a;let _0x58d7c5;_0x21f0a1=_0x56af16||[];const _0x461963=[];if(_0x56af16){for(let _0x5a4602=0x0;_0x5a4602<_0x56af16[_0x19f493('0x5a')];_0x5a4602+=0x1){const _0x2e93dd=_0x56af16[_0x5a4602][_0x19f493('0x4b')]({'plain':!![]});_0xea0ae6[_0x19f493('0x2e')]=_0x49d136[_0x19f493('0x73')][_0x19f493('0x2e')]?_0x49d136[_0x19f493('0x73')][_0x19f493('0x2e')]:_0xea0ae6[_0x19f493('0x2e')];switch(_0xea0ae6['dialCheckDuplicateType']){case'always':_0x58d7c5=squel[_0x19f493('0x37')]()[_0x19f493('0x72')](_0x19f493('0x7d'))[_0x19f493('0x70')]([_0x19f493('0x38'),_0x19f493('0x3a'),_0x19f493('0x3d'),_0x19f493('0x7a'),_0x19f493('0x84'),_0x19f493('0x8e'),_0x19f493('0x80')],squel['select']()[_0x19f493('0x93')](_0x19f493('0x38'),_0x19f493('0x38'))[_0x19f493('0x93')](_0x19f493('0x2a'),'scheduledAt')['field']('id',_0x19f493('0x3d'))[_0x19f493('0x93')](_0x2e93dd['CmListId'][_0x19f493('0x27')](),_0x19f493('0x7a'))[_0x19f493('0x93')](_0x49d136[_0x19f493('0x87')]['id']['toString'](),_0x19f493('0x84'))['field'](_0x19f493('0x2a'),_0x19f493('0x8e'))[_0x19f493('0x93')]('NOW()',_0x19f493('0x80'))[_0x19f493('0x16')](_0x19f493('0x8'))['where']('deletedAt\x20IS\x20NULL')[_0x19f493('0x59')](_0x19f493('0x81'),_0x2e93dd[_0x19f493('0xc')]['toString']())['where'](_0x19f493('0x7'))[_0x19f493('0x59')](_0x19f493('0xb'),squel[_0x19f493('0x29')]()['field']('COALESCE(calleridnum,\x27\x27)')['from'](_0x19f493('0x26'))[_0x19f493('0x59')](_0x19f493('0x66'),_0x49d136[_0x19f493('0x87')]['id']['toString']()))[_0x19f493('0x59')](_0x19f493('0xb'),squel[_0x19f493('0x29')]()[_0x19f493('0x93')](_0x19f493('0x57'))[_0x19f493('0x16')](_0x19f493('0x7d'))[_0x19f493('0x59')]('VoiceQueueId\x20=\x20?',_0x49d136[_0x19f493('0x87')]['id'][_0x19f493('0x27')]())))[_0x19f493('0x27')]();break;case _0x19f493('0x5'):_0x58d7c5=squel[_0x19f493('0x37')]()['into'](_0x19f493('0x7d'))[_0x19f493('0x70')]([_0x19f493('0x38'),_0x19f493('0x3a'),_0x19f493('0x3d'),_0x19f493('0x7a'),'VoiceQueueId',_0x19f493('0x8e'),_0x19f493('0x80')],squel[_0x19f493('0x29')]()[_0x19f493('0x93')]('phone','phone')[_0x19f493('0x93')]('NOW()',_0x19f493('0x3a'))[_0x19f493('0x93')]('id',_0x19f493('0x3d'))[_0x19f493('0x93')](_0x2e93dd[_0x19f493('0xc')][_0x19f493('0x27')](),'ListId')['field'](_0x49d136[_0x19f493('0x87')]['id'][_0x19f493('0x27')](),_0x19f493('0x84'))['field'](_0x19f493('0x2a'),_0x19f493('0x8e'))['field'](_0x19f493('0x2a'),_0x19f493('0x80'))[_0x19f493('0x16')]('cm_contacts')[_0x19f493('0x59')](_0x19f493('0x4c'))['where']('ListId\x20=\x20?',_0x2e93dd[_0x19f493('0xc')][_0x19f493('0x27')]())[_0x19f493('0x59')](_0x19f493('0x7'))[_0x19f493('0x59')](_0x19f493('0xb'),squel[_0x19f493('0x29')]()[_0x19f493('0x93')](_0x19f493('0x57'))[_0x19f493('0x16')]('cm_hopper')[_0x19f493('0x59')](_0x19f493('0x66'),_0x49d136[_0x19f493('0x87')]['id'][_0x19f493('0x27')]())))['toString']();break;default:_0x58d7c5=squel[_0x19f493('0x37')]()[_0x19f493('0x72')]('cm_hopper')[_0x19f493('0x70')]([_0x19f493('0x38'),_0x19f493('0x3a'),_0x19f493('0x3d'),'ListId',_0x19f493('0x84'),_0x19f493('0x8e'),_0x19f493('0x80')],squel[_0x19f493('0x29')]()[_0x19f493('0x93')](_0x19f493('0x38'),_0x19f493('0x38'))[_0x19f493('0x93')](_0x19f493('0x2a'),_0x19f493('0x3a'))[_0x19f493('0x93')]('id',_0x19f493('0x3d'))['field'](_0x2e93dd['CmListId'][_0x19f493('0x27')](),_0x19f493('0x7a'))[_0x19f493('0x93')](_0x49d136[_0x19f493('0x87')]['id'][_0x19f493('0x27')](),_0x19f493('0x84'))[_0x19f493('0x93')]('NOW()','createdAt')[_0x19f493('0x93')](_0x19f493('0x2a'),_0x19f493('0x80'))[_0x19f493('0x16')](_0x19f493('0x8'))['where']('deletedAt\x20IS\x20NULL')[_0x19f493('0x59')](_0x19f493('0x81'),_0x2e93dd[_0x19f493('0xc')][_0x19f493('0x27')]())[_0x19f493('0x59')](_0x19f493('0x7')))['toString']();}_0x461963[_0x19f493('0x58')](db[_0x19f493('0x1b')][_0x19f493('0x5f')](_0x58d7c5));}return Promise[_0x19f493('0x64')](_0x461963);}})[_0x45159a('0x23')](function(){return _0x21f0a1;})['then'](respondWithResult(_0x49a9d3,null))[_0x45159a('0x25')](handleError(_0x49a9d3,null));},exports[_0x37fe33('0x8a')]=function(_0x37480b,_0x221fec){const _0x1b5a85=_0x37fe33;return db[_0x1b5a85('0x6')][_0x1b5a85('0x39')]({'where':{'id':_0x37480b['params']['id']}})[_0x1b5a85('0x23')](handleEntityNotFound(_0x221fec,null))[_0x1b5a85('0x23')](function(_0x1488b4){const _0x345169=_0x1b5a85;if(_0x1488b4)return _0x1488b4['removeLists'](_0x37480b[_0x345169('0x5f')]['ids']);})['then'](function(_0x48a3de){const _0x3c0885=_0x1b5a85;if(_0x48a3de)return db['CmHopper']['destroy']({'where':{'ListId':_0x37480b[_0x3c0885('0x5f')][_0x3c0885('0xd')],'VoiceQueueId':_0x37480b['params']['id']}})[_0x3c0885('0x23')](function(){return _0x48a3de;});})['then'](respondWithStatusCode(_0x221fec,null))[_0x1b5a85('0x25')](handleError(_0x221fec,null));},exports['getBlackLists']=function(_0x11e5dd,_0x15d828){const _0x2335af=_0x37fe33;let _0x1e2773={};const _0x446d21={};let _0x378421,_0xd95357;return db[_0x2335af('0x6')][_0x2335af('0x39')]({'where':{'id':_0x11e5dd[_0x2335af('0x87')]['id']}})['then'](handleEntityNotFound(_0x15d828,null))['then'](function(_0x1c6c8d){const _0xb9adcb=_0x2335af;if(_0x1c6c8d)return _0x378421=_0x1c6c8d,_0x446d21['model']=_[_0xb9adcb('0x48')](db[_0xb9adcb('0x24')]['rawAttributes']),_0x446d21[_0xb9adcb('0x5f')]=_[_0xb9adcb('0x48')](_0x11e5dd[_0xb9adcb('0x5f')]),_0x446d21['filters']=_[_0xb9adcb('0x47')](_0x446d21[_0xb9adcb('0x11')],_0x446d21['query']),_0x1e2773[_0xb9adcb('0x32')]=_['intersection'](_0x446d21['model'],qs[_0xb9adcb('0x91')](_0x11e5dd[_0xb9adcb('0x5f')][_0xb9adcb('0x91')])),_0x1e2773[_0xb9adcb('0x32')]=_0x1e2773[_0xb9adcb('0x32')][_0xb9adcb('0x5a')]?_0x1e2773[_0xb9adcb('0x32')]:_0x446d21[_0xb9adcb('0x11')],_0x1e2773[_0xb9adcb('0x46')]=qs[_0xb9adcb('0x31')](_0x11e5dd['query']['sort']),_0x1e2773[_0xb9adcb('0x59')]=qs[_0xb9adcb('0x3f')](_[_0xb9adcb('0x45')](_0x11e5dd[_0xb9adcb('0x5f')],_0x446d21[_0xb9adcb('0x3f')])),_0x11e5dd['query'][_0xb9adcb('0x2d')]&&(_0x1e2773[_0xb9adcb('0x59')]=_[_0xb9adcb('0x1f')](_0x1e2773[_0xb9adcb('0x59')],{[Op['or']]:_['map'](_0x1e2773[_0xb9adcb('0x32')],function(_0x57487c){const _0x106849=_0xb9adcb,_0x3474e1={};return _0x3474e1[_0x57487c]={[Op['like']]:'%'+_0x11e5dd[_0x106849('0x5f')]['filter']+'%'},_0x3474e1;})})),_0x1e2773=_[_0xb9adcb('0x1f')]({},_0x1e2773,_0x11e5dd[_0xb9adcb('0x76')]),_0x378421[_0xb9adcb('0x41')](_0x1e2773);})['then'](function(_0x38d6a6){const _0x2817b1=_0x2335af;if(_0x38d6a6)return _0xd95357=_0x38d6a6['length'],typeof _0x11e5dd[_0x2817b1('0x5f')][_0x2817b1('0x3c')]===_0x2817b1('0xa')&&(_0x1e2773[_0x2817b1('0x4')]=qs[_0x2817b1('0x4')](_0x11e5dd[_0x2817b1('0x5f')][_0x2817b1('0x4')]),_0x1e2773[_0x2817b1('0x86')]=qs[_0x2817b1('0x86')](_0x11e5dd[_0x2817b1('0x5f')]['offset'])),_0x378421[_0x2817b1('0x41')](_0x1e2773);})[_0x2335af('0x23')](function(_0x2adbc4){if(_0x2adbc4)return _0x2adbc4?{'count':_0xd95357,'rows':_0x2adbc4}:null;})['then'](respondWithResult(_0x15d828,null))[_0x2335af('0x25')](handleError(_0x15d828,null));},exports['addBlackLists']=function(_0x2dde8f,_0x55ed4b){const _0x5c920b=_0x37fe33;let _0x3b6e1f;return db['VoiceQueue'][_0x5c920b('0x39')]({'where':{'id':_0x2dde8f[_0x5c920b('0x87')]['id']}})[_0x5c920b('0x23')](handleEntityNotFound(_0x55ed4b,null))[_0x5c920b('0x23')](function(_0x37f815){const _0x5654ce=_0x5c920b;if(_0x37f815)return _0x37f815['addBlackLists'](_0x2dde8f[_0x5654ce('0x73')][_0x5654ce('0xd')],{'through':_[_0x5654ce('0x22')](_0x2dde8f[_0x5654ce('0x73')],['ids','id'])});return null;})[_0x5c920b('0x23')](function(_0x11b38a){const _0x33f55e=_0x5c920b;let _0x5e6447;_0x3b6e1f=_0x11b38a||[];const _0x6d44f8=[];if(_0x11b38a){for(let _0x2e4658=0x0;_0x2e4658<_0x11b38a[_0x33f55e('0x5a')];_0x2e4658+=0x1){const _0x1df5c4=_0x11b38a[_0x2e4658]['get']({'plain':!![]});_0x5e6447=squel['insert']()[_0x33f55e('0x72')](_0x33f55e('0x4d'))['fromQuery']([_0x33f55e('0x38'),'ContactId',_0x33f55e('0x7a'),_0x33f55e('0x84'),'createdAt',_0x33f55e('0x80')],squel[_0x33f55e('0x29')]()[_0x33f55e('0x93')](_0x33f55e('0x38'),'phone')['field']('id',_0x33f55e('0x3d'))[_0x33f55e('0x93')](_0x1df5c4['CmListId'][_0x33f55e('0x27')](),_0x33f55e('0x7a'))['field'](_0x2dde8f[_0x33f55e('0x87')]['id'][_0x33f55e('0x27')](),_0x33f55e('0x84'))['field'](_0x33f55e('0x2a'),_0x33f55e('0x8e'))[_0x33f55e('0x93')](_0x33f55e('0x2a'),_0x33f55e('0x80'))['from'](_0x33f55e('0x8'))[_0x33f55e('0x59')](_0x33f55e('0x4c'))[_0x33f55e('0x59')](_0x33f55e('0x81'),_0x1df5c4[_0x33f55e('0xc')][_0x33f55e('0x27')]())[_0x33f55e('0x59')](_0x33f55e('0x7')))['toString'](),_0x6d44f8[_0x33f55e('0x58')](db['sequelize'][_0x33f55e('0x5f')](_0x5e6447));}return Promise[_0x33f55e('0x64')](_0x6d44f8);}})[_0x5c920b('0x23')](function(){return _0x3b6e1f;})['then'](respondWithResult(_0x55ed4b,null))[_0x5c920b('0x25')](handleError(_0x55ed4b,null));},exports[_0x37fe33('0x90')]=function(_0x3e11ef,_0x1328a0){const _0x95e7b9=_0x37fe33;return db[_0x95e7b9('0x6')][_0x95e7b9('0x39')]({'where':{'id':_0x3e11ef[_0x95e7b9('0x87')]['id']}})[_0x95e7b9('0x23')](handleEntityNotFound(_0x1328a0,null))[_0x95e7b9('0x23')](function(_0x3a3b37){const _0x46f883=_0x95e7b9;if(_0x3a3b37)return _0x3a3b37[_0x46f883('0x90')](_0x3e11ef[_0x46f883('0x5f')][_0x46f883('0xd')]);})[_0x95e7b9('0x23')](function(_0x2c6a5a){const _0x2cfa43=_0x95e7b9;if(_0x2c6a5a)return db[_0x2cfa43('0x6e')][_0x2cfa43('0x5d')]({'where':{'ListId':_0x3e11ef[_0x2cfa43('0x5f')][_0x2cfa43('0xd')],'VoiceQueueId':_0x3e11ef[_0x2cfa43('0x87')]['id']}})[_0x2cfa43('0x23')](function(){return _0x2c6a5a;});})[_0x95e7b9('0x23')](respondWithStatusCode(_0x1328a0,null))[_0x95e7b9('0x25')](handleError(_0x1328a0,null));}; \ No newline at end of file diff --git a/server/api/voiceQueue/voiceQueue.events.js b/server/api/voiceQueue/voiceQueue.events.js index 7bb32ea..78f1368 100644 --- a/server/api/voiceQueue/voiceQueue.events.js +++ b/server/api/voiceQueue/voiceQueue.events.js @@ -1 +1 @@ -const a754_0x22e0=['remove','setMaxListeners','VoiceQueue','update','undefined','save','emit','../../mysqldb','exports','events'];(function(_0x153fe9,_0x22e0f3){const _0x41a115=function(_0x10c08b){while(--_0x10c08b){_0x153fe9['push'](_0x153fe9['shift']());}};_0x41a115(++_0x22e0f3);}(a754_0x22e0,0x1de));const a754_0x41a1=function(_0x153fe9,_0x22e0f3){_0x153fe9=_0x153fe9-0x0;let _0x41a115=a754_0x22e0[_0x153fe9];return _0x41a115;};const _0x465f5d=a754_0x41a1;'use strict';const EventEmitter=require(_0x465f5d('0x1')),VoiceQueue=require(_0x465f5d('0x9'))['db'][_0x465f5d('0x4')],VoiceQueueEvents=new EventEmitter();VoiceQueueEvents[_0x465f5d('0x3')](0x0);const events={'afterCreate':_0x465f5d('0x7'),'afterUpdate':_0x465f5d('0x5'),'afterDestroy':_0x465f5d('0x2')};function emitEvent(_0x10c08b){return function(_0x2d787d){const _0x606289=a754_0x41a1;VoiceQueueEvents[_0x606289('0x8')](_0x10c08b+':'+_0x2d787d['id'],_0x2d787d),VoiceQueueEvents[_0x606289('0x8')](_0x10c08b,_0x2d787d);};}for(const e in events){if(typeof events[e]!==_0x465f5d('0x6')){const event=events[e];VoiceQueue['addHook'](e,emitEvent(event));}}module[_0x465f5d('0x0')]=VoiceQueueEvents; \ No newline at end of file +const a754_0x2c1c=['exports','../../mysqldb','update','emit','save','addHook','remove','events','undefined','setMaxListeners'];(function(_0x5c7257,_0x2c1c67){const _0x26d22c=function(_0x7545ea){while(--_0x7545ea){_0x5c7257['push'](_0x5c7257['shift']());}};_0x26d22c(++_0x2c1c67);}(a754_0x2c1c,0x198));const a754_0x26d2=function(_0x5c7257,_0x2c1c67){_0x5c7257=_0x5c7257-0x0;let _0x26d22c=a754_0x2c1c[_0x5c7257];return _0x26d22c;};const _0x175a1e=a754_0x26d2;'use strict';const EventEmitter=require(_0x175a1e('0x9')),VoiceQueue=require(_0x175a1e('0x3'))['db']['VoiceQueue'],VoiceQueueEvents=new EventEmitter();VoiceQueueEvents[_0x175a1e('0x1')](0x0);const events={'afterCreate':_0x175a1e('0x6'),'afterUpdate':_0x175a1e('0x4'),'afterDestroy':_0x175a1e('0x8')};function emitEvent(_0x7545ea){return function(_0xf58221){const _0xd53239=a754_0x26d2;VoiceQueueEvents[_0xd53239('0x5')](_0x7545ea+':'+_0xf58221['id'],_0xf58221),VoiceQueueEvents[_0xd53239('0x5')](_0x7545ea,_0xf58221);};}for(const e in events){if(typeof events[e]!==_0x175a1e('0x0')){const event=events[e];VoiceQueue[_0x175a1e('0x7')](e,emitEvent(event));}}module[_0x175a1e('0x2')]=VoiceQueueEvents; \ No newline at end of file diff --git a/server/api/voiceQueue/voiceQueue.model.js b/server/api/voiceQueue/voiceQueue.model.js index 02c78b1..5a7bfdf 100644 --- a/server/api/voiceQueue/voiceQueue.model.js +++ b/server/api/voiceQueue/voiceQueue.model.js @@ -1 +1 @@ -const a755_0x3865=['exports','define'];(function(_0x572e62,_0x38657b){const _0x371eda=function(_0x588740){while(--_0x588740){_0x572e62['push'](_0x572e62['shift']());}};_0x371eda(++_0x38657b);}(a755_0x3865,0x1d2));const a755_0x371e=function(_0x572e62,_0x38657b){_0x572e62=_0x572e62-0x0;let _0x371eda=a755_0x3865[_0x572e62];return _0x371eda;};const _0x22cc38=a755_0x371e;'use strict';const attributes=require('./voiceQueue.attributes');module[_0x22cc38('0x0')]=function(_0x588740){const _0x337d99=_0x22cc38,_0x4555f4=_0x588740[_0x337d99('0x1')]('VoiceQueue',attributes,{'tableName':'voice_queues','paranoid':![],'indexes':[],'timestamps':!![]});return _0x4555f4;}; \ No newline at end of file +const a755_0x3693=['VoiceQueue','exports','voice_queues','./voiceQueue.attributes'];(function(_0x3abe4b,_0x36938f){const _0x2ba08f=function(_0x40b981){while(--_0x40b981){_0x3abe4b['push'](_0x3abe4b['shift']());}};_0x2ba08f(++_0x36938f);}(a755_0x3693,0x1a2));const a755_0x2ba0=function(_0x3abe4b,_0x36938f){_0x3abe4b=_0x3abe4b-0x0;let _0x2ba08f=a755_0x3693[_0x3abe4b];return _0x2ba08f;};const _0x54405d=a755_0x2ba0;'use strict';const attributes=require(_0x54405d('0x1'));module[_0x54405d('0x3')]=function(_0x40b981){const _0x259b56=_0x54405d,_0x523b3f=_0x40b981['define'](_0x259b56('0x2'),attributes,{'tableName':_0x259b56('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x523b3f;}; \ No newline at end of file diff --git a/server/api/voiceQueue/voiceQueue.rpc.js b/server/api/voiceQueue/voiceQueue.rpc.js index 0e200d5..0373b5c 100644 --- a/server/api/voiceQueue/voiceQueue.rpc.js +++ b/server/api/voiceQueue/voiceQueue.rpc.js @@ -1 +1 @@ -const a756_0x9a1f=['attributes','raw','../../mysqldb','map','register','VoiceQueue','../../rediscache','options','where','limit','rpc','stringify','model','findAll','GetVoiceQueue','then','error','info','debug','./voiceQueue.socket','ShowVoiceQueue','catch','findOne','include','message'];(function(_0x49d85a,_0x9a1f83){const _0x12cb7f=function(_0x54a5d5){while(--_0x54a5d5){_0x49d85a['push'](_0x49d85a['shift']());}};_0x12cb7f(++_0x9a1f83);}(a756_0x9a1f,0x192));const a756_0x12cb=function(_0x49d85a,_0x9a1f83){_0x49d85a=_0x49d85a-0x0;let _0x12cb7f=a756_0x9a1f[_0x49d85a];return _0x12cb7f;};const _0x29d554=a756_0x12cb;'use strict';const _=require('lodash'),db=require(_0x29d554('0x0'))['db'],logger=require('../../config/logger')(_0x29d554('0x8')),{getSocket}=require(_0x29d554('0x4')),socket=getSocket();require(_0x29d554('0x11'))[_0x29d554('0x2')](socket),exports['GetVoiceQueue']=function(_0x54a5d5){const _0x1ca28d=this;return new Promise(function(_0x13db5f,_0x598568){const _0x20ef57=a756_0x12cb;return db[_0x20ef57('0x3')][_0x20ef57('0xb')]({'raw':_0x54a5d5['options']?_0x54a5d5[_0x20ef57('0x5')]['raw']===undefined?!![]:![]:!![],'where':_0x54a5d5[_0x20ef57('0x5')]?_0x54a5d5[_0x20ef57('0x5')][_0x20ef57('0x6')]||null:null,'attributes':_0x54a5d5[_0x20ef57('0x5')]?_0x54a5d5[_0x20ef57('0x5')][_0x20ef57('0x17')]||null:null,'limit':_0x54a5d5['options']?_0x54a5d5[_0x20ef57('0x5')][_0x20ef57('0x7')]||null:null,'include':_0x54a5d5['options']?_0x54a5d5[_0x20ef57('0x5')][_0x20ef57('0x15')]?_[_0x20ef57('0x1')](_0x54a5d5['options'][_0x20ef57('0x15')],function(_0x52fc56){const _0x2177a0=_0x20ef57;return{'model':db[_0x52fc56[_0x2177a0('0xa')]],'as':_0x52fc56['as'],'attributes':_0x52fc56[_0x2177a0('0x17')],'include':_0x52fc56[_0x2177a0('0x15')]?_[_0x2177a0('0x1')](_0x52fc56[_0x2177a0('0x15')],function(_0x4d3705){const _0x3e54a7=_0x2177a0;return{'model':db[_0x4d3705[_0x3e54a7('0xa')]],'as':_0x4d3705['as'],'attributes':_0x4d3705[_0x3e54a7('0x17')],'include':_0x4d3705[_0x3e54a7('0x15')]?_[_0x3e54a7('0x1')](_0x4d3705[_0x3e54a7('0x15')],function(_0x487c9e){const _0x1833c9=_0x3e54a7;return{'model':db[_0x487c9e[_0x1833c9('0xa')]],'as':_0x487c9e['as'],'attributes':_0x487c9e['attributes']};}):[]};}):[]};}):[]:[]})[_0x20ef57('0xd')](function(_0x402ac4){const _0x2f49ae=_0x20ef57;logger[_0x2f49ae('0xf')](_0x2f49ae('0xc'),_0x54a5d5),logger[_0x2f49ae('0x10')](_0x2f49ae('0xc'),_0x54a5d5,JSON[_0x2f49ae('0x9')](_0x402ac4)),_0x13db5f(_0x402ac4);})['catch'](function(_0x308efd){const _0x46e85e=_0x20ef57;logger['error']('GetVoiceQueue',_0x308efd['message'],_0x54a5d5),_0x598568(_0x1ca28d['error'](0x1f4,_0x308efd[_0x46e85e('0x16')]));});});},exports[_0x29d554('0x12')]=function(_0x1bff32){const _0x1daf55=this;return new Promise(function(_0x2c2478,_0x3e4385){const _0x3ba06f=a756_0x12cb;return db[_0x3ba06f('0x3')][_0x3ba06f('0x14')]({'raw':_0x1bff32[_0x3ba06f('0x5')]?_0x1bff32[_0x3ba06f('0x5')][_0x3ba06f('0x18')]===undefined?!![]:![]:!![],'where':_0x1bff32[_0x3ba06f('0x5')]?_0x1bff32['options'][_0x3ba06f('0x6')]||null:null,'attributes':_0x1bff32[_0x3ba06f('0x5')]?_0x1bff32['options'][_0x3ba06f('0x17')]||null:null,'include':_0x1bff32['options']?_0x1bff32[_0x3ba06f('0x5')][_0x3ba06f('0x15')]?_[_0x3ba06f('0x1')](_0x1bff32[_0x3ba06f('0x5')][_0x3ba06f('0x15')],function(_0x2dbdc4){const _0xfae152=_0x3ba06f;return{'model':db[_0x2dbdc4[_0xfae152('0xa')]],'as':_0x2dbdc4['as'],'attributes':_0x2dbdc4[_0xfae152('0x17')],'include':_0x2dbdc4[_0xfae152('0x15')]?_['map'](_0x2dbdc4[_0xfae152('0x15')],function(_0x1af17c){const _0x30eb16=_0xfae152;return{'model':db[_0x1af17c[_0x30eb16('0xa')]],'as':_0x1af17c['as'],'attributes':_0x1af17c[_0x30eb16('0x17')],'include':_0x1af17c[_0x30eb16('0x15')]?_[_0x30eb16('0x1')](_0x1af17c[_0x30eb16('0x15')],function(_0x37f57d){const _0x167b62=_0x30eb16;return{'model':db[_0x37f57d[_0x167b62('0xa')]],'as':_0x37f57d['as'],'attributes':_0x37f57d['attributes']};}):[]};}):[]};}):[]:[]})[_0x3ba06f('0xd')](function(_0x3cb8e7){const _0x40d71a=_0x3ba06f;logger[_0x40d71a('0xf')](_0x40d71a('0x12'),_0x1bff32),logger[_0x40d71a('0x10')](_0x40d71a('0x12'),_0x1bff32,JSON[_0x40d71a('0x9')](_0x3cb8e7)),_0x2c2478(_0x3cb8e7);})[_0x3ba06f('0x13')](function(_0x13fc6e){const _0x4da199=_0x3ba06f;logger[_0x4da199('0xe')]('ShowVoiceQueue',_0x13fc6e['message'],_0x1bff32),_0x3e4385(_0x1daf55[_0x4da199('0xe')](0x1f4,_0x13fc6e[_0x4da199('0x16')]));});});}; \ No newline at end of file +const a756_0x272a=['findOne','rpc','VoiceQueue','debug','lodash','include','findAll','attributes','../../config/logger','message','raw','map','stringify','info','GetVoiceQueue','ShowVoiceQueue','limit','error','catch','../../mysqldb','then','options','where','model'];(function(_0xb2a2d,_0x272a58){const _0x5a8145=function(_0x15a304){while(--_0x15a304){_0xb2a2d['push'](_0xb2a2d['shift']());}};_0x5a8145(++_0x272a58);}(a756_0x272a,0x1d1));const a756_0x5a81=function(_0xb2a2d,_0x272a58){_0xb2a2d=_0xb2a2d-0x0;let _0x5a8145=a756_0x272a[_0xb2a2d];return _0x5a8145;};const _0x19c077=a756_0x5a81;'use strict';const _=require(_0x19c077('0x13')),db=require(_0x19c077('0xa'))['db'],logger=require(_0x19c077('0x17'))(_0x19c077('0x10')),{getSocket}=require('../../rediscache'),socket=getSocket();require('./voiceQueue.socket')['register'](socket),exports[_0x19c077('0x5')]=function(_0x15a304){const _0x102a40=this;return new Promise(function(_0x139515,_0x2dad25){const _0x26c18e=a756_0x5a81;return db[_0x26c18e('0x11')][_0x26c18e('0x15')]({'raw':_0x15a304['options']?_0x15a304['options'][_0x26c18e('0x1')]===undefined?!![]:![]:!![],'where':_0x15a304[_0x26c18e('0xc')]?_0x15a304[_0x26c18e('0xc')][_0x26c18e('0xd')]||null:null,'attributes':_0x15a304['options']?_0x15a304[_0x26c18e('0xc')]['attributes']||null:null,'limit':_0x15a304[_0x26c18e('0xc')]?_0x15a304['options'][_0x26c18e('0x7')]||null:null,'include':_0x15a304[_0x26c18e('0xc')]?_0x15a304[_0x26c18e('0xc')][_0x26c18e('0x14')]?_[_0x26c18e('0x2')](_0x15a304[_0x26c18e('0xc')][_0x26c18e('0x14')],function(_0x3bd44b){const _0x5a224d=_0x26c18e;return{'model':db[_0x3bd44b[_0x5a224d('0xe')]],'as':_0x3bd44b['as'],'attributes':_0x3bd44b[_0x5a224d('0x16')],'include':_0x3bd44b[_0x5a224d('0x14')]?_['map'](_0x3bd44b[_0x5a224d('0x14')],function(_0x5ef959){const _0x55cb62=_0x5a224d;return{'model':db[_0x5ef959[_0x55cb62('0xe')]],'as':_0x5ef959['as'],'attributes':_0x5ef959['attributes'],'include':_0x5ef959[_0x55cb62('0x14')]?_[_0x55cb62('0x2')](_0x5ef959['include'],function(_0x315d72){const _0x37980d=_0x55cb62;return{'model':db[_0x315d72[_0x37980d('0xe')]],'as':_0x315d72['as'],'attributes':_0x315d72['attributes']};}):[]};}):[]};}):[]:[]})[_0x26c18e('0xb')](function(_0x30dd46){const _0x415a41=_0x26c18e;logger[_0x415a41('0x4')](_0x415a41('0x5'),_0x15a304),logger['debug']('GetVoiceQueue',_0x15a304,JSON['stringify'](_0x30dd46)),_0x139515(_0x30dd46);})[_0x26c18e('0x9')](function(_0x55053f){const _0x32cd77=_0x26c18e;logger['error'](_0x32cd77('0x5'),_0x55053f['message'],_0x15a304),_0x2dad25(_0x102a40[_0x32cd77('0x8')](0x1f4,_0x55053f[_0x32cd77('0x0')]));});});},exports['ShowVoiceQueue']=function(_0x5a007b){const _0x119a9e=this;return new Promise(function(_0x1cb15e,_0x2e0bd5){const _0x384925=a756_0x5a81;return db['VoiceQueue'][_0x384925('0xf')]({'raw':_0x5a007b[_0x384925('0xc')]?_0x5a007b[_0x384925('0xc')]['raw']===undefined?!![]:![]:!![],'where':_0x5a007b[_0x384925('0xc')]?_0x5a007b[_0x384925('0xc')][_0x384925('0xd')]||null:null,'attributes':_0x5a007b[_0x384925('0xc')]?_0x5a007b[_0x384925('0xc')]['attributes']||null:null,'include':_0x5a007b['options']?_0x5a007b[_0x384925('0xc')]['include']?_[_0x384925('0x2')](_0x5a007b[_0x384925('0xc')][_0x384925('0x14')],function(_0x3f8320){const _0x10c0ca=_0x384925;return{'model':db[_0x3f8320['model']],'as':_0x3f8320['as'],'attributes':_0x3f8320[_0x10c0ca('0x16')],'include':_0x3f8320['include']?_[_0x10c0ca('0x2')](_0x3f8320[_0x10c0ca('0x14')],function(_0x4e6921){const _0x5ec541=_0x10c0ca;return{'model':db[_0x4e6921[_0x5ec541('0xe')]],'as':_0x4e6921['as'],'attributes':_0x4e6921[_0x5ec541('0x16')],'include':_0x4e6921['include']?_['map'](_0x4e6921[_0x5ec541('0x14')],function(_0x573120){const _0x14e005=_0x5ec541;return{'model':db[_0x573120[_0x14e005('0xe')]],'as':_0x573120['as'],'attributes':_0x573120[_0x14e005('0x16')]};}):[]};}):[]};}):[]:[]})[_0x384925('0xb')](function(_0x57d390){const _0x1827e4=_0x384925;logger['info'](_0x1827e4('0x6'),_0x5a007b),logger[_0x1827e4('0x12')](_0x1827e4('0x6'),_0x5a007b,JSON[_0x1827e4('0x3')](_0x57d390)),_0x1cb15e(_0x57d390);})[_0x384925('0x9')](function(_0x1219b0){const _0x2b0afa=_0x384925;logger[_0x2b0afa('0x8')](_0x2b0afa('0x6'),_0x1219b0[_0x2b0afa('0x0')],_0x5a007b),_0x2e0bd5(_0x119a9e[_0x2b0afa('0x8')](0x1f4,_0x1219b0[_0x2b0afa('0x0')]));});});}; \ No newline at end of file diff --git a/server/api/voiceQueue/voiceQueue.socket.js b/server/api/voiceQueue/voiceQueue.socket.js index 82cf7d5..8c1d59c 100644 --- a/server/api/voiceQueue/voiceQueue.socket.js +++ b/server/api/voiceQueue/voiceQueue.socket.js @@ -1 +1 @@ -const a757_0x6784=['emit','remove','update','save','voiceQueue:','length','./voiceQueue.events'];(function(_0x3dff87,_0x67846c){const _0x4ebf4b=function(_0x1276f6){while(--_0x1276f6){_0x3dff87['push'](_0x3dff87['shift']());}};_0x4ebf4b(++_0x67846c);}(a757_0x6784,0x17e));const a757_0x4ebf=function(_0x3dff87,_0x67846c){_0x3dff87=_0x3dff87-0x0;let _0x4ebf4b=a757_0x6784[_0x3dff87];return _0x4ebf4b;};const _0x1d3069=a757_0x4ebf;'use strict';const VoiceQueueEvents=require(_0x1d3069('0x2')),events=[_0x1d3069('0x6'),_0x1d3069('0x4'),_0x1d3069('0x5')];function createListener(_0x1276f6,_0x58a089){return function(_0x5580bf){const _0x46d9b8=a757_0x4ebf;_0x58a089[_0x46d9b8('0x3')](_0x1276f6,_0x5580bf);};}exports['register']=function(_0x1a4474){const _0x6cc7f9=_0x1d3069;for(let _0x30dca1=0x0,_0x4c023f=events[_0x6cc7f9('0x1')];_0x30dca1<_0x4c023f;_0x30dca1++){const _0x146f1e=events[_0x30dca1],_0x3128c1=createListener(_0x6cc7f9('0x0')+_0x146f1e,_0x1a4474);VoiceQueueEvents['on'](_0x146f1e,_0x3128c1);}}; \ No newline at end of file +const a757_0x4687=['length','./voiceQueue.events','remove','register','save','emit','voiceQueue:'];(function(_0xbeb54,_0x4687d5){const _0x664dda=function(_0x1ee54e){while(--_0x1ee54e){_0xbeb54['push'](_0xbeb54['shift']());}};_0x664dda(++_0x4687d5);}(a757_0x4687,0x13c));const a757_0x664d=function(_0xbeb54,_0x4687d5){_0xbeb54=_0xbeb54-0x0;let _0x664dda=a757_0x4687[_0xbeb54];return _0x664dda;};const _0x19c9ef=a757_0x664d;'use strict';const VoiceQueueEvents=require(_0x19c9ef('0x0')),events=[_0x19c9ef('0x3'),_0x19c9ef('0x1'),'update'];function createListener(_0x1ee54e,_0x5b06e2){return function(_0x5e5a58){const _0x53d797=a757_0x664d;_0x5b06e2[_0x53d797('0x4')](_0x1ee54e,_0x5e5a58);};}exports[_0x19c9ef('0x2')]=function(_0x4280df){const _0x357e25=_0x19c9ef;for(let _0xf2a47a=0x0,_0x395a19=events[_0x357e25('0x6')];_0xf2a47a<_0x395a19;_0xf2a47a++){const _0x127acf=events[_0xf2a47a],_0xaf079=createListener(_0x357e25('0x5')+_0x127acf,_0x4280df);VoiceQueueEvents['on'](_0x127acf,_0xaf079);}}; \ No newline at end of file diff --git a/server/api/voiceQueueReport/index.js b/server/api/voiceQueueReport/index.js index ccca8a3..80df01e 100644 --- a/server/api/voiceQueueReport/index.js +++ b/server/api/voiceQueueReport/index.js @@ -1 +1 @@ -const a758_0x35ca=['express','delete','exports','/:id','get','../../components/auth/service','index','isAuthenticated','/describe','describe','destroy','./voiceQueueReport.controller','update','post','getVoiceQueuesReport','create'];(function(_0x4a7e29,_0x35caa0){const _0x1ac790=function(_0x4289c7){while(--_0x4289c7){_0x4a7e29['push'](_0x4a7e29['shift']());}};_0x1ac790(++_0x35caa0);}(a758_0x35ca,0x115));const a758_0x1ac7=function(_0x4a7e29,_0x35caa0){_0x4a7e29=_0x4a7e29-0x0;let _0x1ac790=a758_0x35ca[_0x4a7e29];return _0x1ac790;};const _0x558a1e=a758_0x1ac7;'use strict';const express=require(_0x558a1e('0xb')),router=express['Router'](),auth=require(_0x558a1e('0x0')),controller=require(_0x558a1e('0x6'));router[_0x558a1e('0xf')]('/',auth[_0x558a1e('0x2')](),controller[_0x558a1e('0x1')]),router[_0x558a1e('0xf')](_0x558a1e('0x3'),auth[_0x558a1e('0x2')](),controller[_0x558a1e('0x4')]),router['get']('/index',auth[_0x558a1e('0x2')](),controller[_0x558a1e('0x9')]),router[_0x558a1e('0xf')](_0x558a1e('0xe'),auth[_0x558a1e('0x2')](),controller['show']),router[_0x558a1e('0x8')]('/',auth[_0x558a1e('0x2')](),controller[_0x558a1e('0xa')]),router['put'](_0x558a1e('0xe'),auth[_0x558a1e('0x2')](),controller[_0x558a1e('0x7')]),router[_0x558a1e('0xc')](_0x558a1e('0xe'),auth[_0x558a1e('0x2')](),controller[_0x558a1e('0x5')]),module[_0x558a1e('0xd')]=router; \ No newline at end of file +const a758_0x3af3=['getVoiceQueuesReport','put','update','/:id','create','../../components/auth/service','Router','express','isAuthenticated','post','delete','/describe','show','get','index'];(function(_0x2e5b22,_0x3af3d4){const _0x38f75f=function(_0xade56c){while(--_0xade56c){_0x2e5b22['push'](_0x2e5b22['shift']());}};_0x38f75f(++_0x3af3d4);}(a758_0x3af3,0x104));const a758_0x38f7=function(_0x2e5b22,_0x3af3d4){_0x2e5b22=_0x2e5b22-0x0;let _0x38f75f=a758_0x3af3[_0x2e5b22];return _0x38f75f;};const _0x23879b=a758_0x38f7;'use strict';const express=require(_0x23879b('0x2')),router=express[_0x23879b('0x1')](),auth=require(_0x23879b('0x0')),controller=require('./voiceQueueReport.controller');router[_0x23879b('0x8')]('/',auth['isAuthenticated'](),controller[_0x23879b('0x9')]),router[_0x23879b('0x8')](_0x23879b('0x6'),auth[_0x23879b('0x3')](),controller['describe']),router['get']('/index',auth['isAuthenticated'](),controller[_0x23879b('0xa')]),router[_0x23879b('0x8')](_0x23879b('0xd'),auth['isAuthenticated'](),controller[_0x23879b('0x7')]),router[_0x23879b('0x4')]('/',auth[_0x23879b('0x3')](),controller[_0x23879b('0xe')]),router[_0x23879b('0xb')](_0x23879b('0xd'),auth[_0x23879b('0x3')](),controller[_0x23879b('0xc')]),router[_0x23879b('0x5')](_0x23879b('0xd'),auth[_0x23879b('0x3')](),controller['destroy']),module['exports']=router; \ No newline at end of file diff --git a/server/api/voiceQueueReport/voiceQueueReport.attributes.js b/server/api/voiceQueueReport/voiceQueueReport.attributes.js index a7bcaa3..1144b3c 100644 --- a/server/api/voiceQueueReport/voiceQueueReport.attributes.js +++ b/server/api/voiceQueueReport/voiceQueueReport.attributes.js @@ -1 +1 @@ -const a759_0x5e2c=['COMPLETEDBYCALLER,\x20COMPLETEDBYAGENT,\x20FORWARDTRANFER,\x20BLINDTRANSFER,\x20ATTENDEDTRANSFER,\x20EXITWITHKEY,\x20TIMEOUT','FORWARD,\x20BLIND,\x20ATTENDED','getDataValue','INTEGER','setDataValue','holdtime','queuecallerleaveAt','DATE','format','queuecallerjoinAt','BOOLEAN','exports','STRING'];(function(_0xedde42,_0x5e2cd7){const _0x32bcf0=function(_0x42e1d0){while(--_0x42e1d0){_0xedde42['push'](_0xedde42['shift']());}};_0x32bcf0(++_0x5e2cd7);}(a759_0x5e2c,0x175));const a759_0x32bc=function(_0xedde42,_0x5e2cd7){_0xedde42=_0xedde42-0x0;let _0x32bcf0=a759_0x5e2c[_0xedde42];return _0x32bcf0;};const _0x486f51=a759_0x32bc;'use strict';const Sequelize=require('sequelize'),moment=require('moment');module[_0x486f51('0x2')]={'type':{'type':Sequelize[_0x486f51('0x3')]},'uniqueid':{'type':Sequelize[_0x486f51('0x3')]},'calleridnum':{'type':Sequelize['STRING']},'calleridname':{'type':Sequelize[_0x486f51('0x3')]},'queue':{'type':Sequelize['STRING']},'queuecallerjoinAt':{'type':Sequelize['DATE']},'queuecallerleaveAt':{'type':Sequelize['DATE'],'set':function(_0x42e1d0){const _0x20d3ce=_0x486f51,_0x432d6a=moment(_0x42e1d0),_0x12917e=moment(this[_0x20d3ce('0x6')](_0x20d3ce('0x0')))[_0x20d3ce('0xc')]('YYYY-MM-DD\x20HH:mm:ss'),_0x5ad0e3=_0x432d6a['diff'](_0x12917e,'seconds');this[_0x20d3ce('0x8')](_0x20d3ce('0xa'),_0x42e1d0),this['setDataValue'](_0x20d3ce('0x9'),_0x5ad0e3||null);}},'position':{'type':Sequelize[_0x486f51('0x7')]},'count':{'type':Sequelize['INTEGER']},'queuecallerabandon':{'type':Sequelize[_0x486f51('0x1')],'defaultValue':![]},'queuecallerabandonAt':{'type':Sequelize['DATE']},'queuecallercomplete':{'type':Sequelize[_0x486f51('0x1')],'defaultValue':![]},'queuecallercompleteAt':{'type':Sequelize[_0x486f51('0xb')]},'queuecallerexit':{'type':Sequelize[_0x486f51('0x1')],'defaultValue':![]},'queuecallerexitAt':{'type':Sequelize['DATE']},'queuecallerexitreason':{'type':Sequelize[_0x486f51('0x3')],'comment':_0x486f51('0x4')},'originalposition':{'type':Sequelize[_0x486f51('0x7')]},'channel':{'type':Sequelize[_0x486f51('0x3')]},'connectedlinenum':{'type':Sequelize['STRING']},'connectedlinename':{'type':Sequelize[_0x486f51('0x3')]},'accountcode':{'type':Sequelize[_0x486f51('0x3')]},'context':{'type':Sequelize[_0x486f51('0x3')]},'exten':{'type':Sequelize['STRING']},'priority':{'type':Sequelize[_0x486f51('0x3')]},'holdtime':{'type':Sequelize[_0x486f51('0x7')]},'mohtime':{'type':Sequelize['INTEGER'],'defaultValue':0x0},'assigned':{'type':Sequelize[_0x486f51('0x1')],'defaultValue':![]},'lastAssignedTo':{'type':Sequelize[_0x486f51('0x3')]},'transfer':{'type':Sequelize[_0x486f51('0x1')],'defaultValue':![]},'transfertype':{'type':Sequelize[_0x486f51('0x3')],'comment':_0x486f51('0x5')},'transferexten':{'type':Sequelize[_0x486f51('0x3')]},'transferuniqueid':{'type':Sequelize['STRING']},'disposition':{'type':Sequelize[_0x486f51('0x3')]},'secondDisposition':{'type':Sequelize['STRING']},'thirdDisposition':{'type':Sequelize[_0x486f51('0x3')]},'queuecallerenterreason':{'type':Sequelize[_0x486f51('0x7')],'defaultValue':0x0}}; \ No newline at end of file +const a759_0x331b=['diff','BOOLEAN','YYYY-MM-DD\x20HH:mm:ss','COMPLETEDBYCALLER,\x20COMPLETEDBYAGENT,\x20FORWARDTRANFER,\x20BLINDTRANSFER,\x20ATTENDEDTRANSFER,\x20EXITWITHKEY,\x20TIMEOUT','queuecallerjoinAt','moment','DATE','STRING','queuecallerleaveAt','FORWARD,\x20BLIND,\x20ATTENDED','setDataValue','seconds','getDataValue','INTEGER','format','holdtime'];(function(_0x3a9707,_0x331b14){const _0x5d7333=function(_0x19d985){while(--_0x19d985){_0x3a9707['push'](_0x3a9707['shift']());}};_0x5d7333(++_0x331b14);}(a759_0x331b,0x150));const a759_0x5d73=function(_0x3a9707,_0x331b14){_0x3a9707=_0x3a9707-0x0;let _0x5d7333=a759_0x331b[_0x3a9707];return _0x5d7333;};const _0x3ba617=a759_0x5d73;'use strict';const Sequelize=require('sequelize'),moment=require(_0x3ba617('0x5'));module['exports']={'type':{'type':Sequelize[_0x3ba617('0x7')]},'uniqueid':{'type':Sequelize[_0x3ba617('0x7')]},'calleridnum':{'type':Sequelize[_0x3ba617('0x7')]},'calleridname':{'type':Sequelize[_0x3ba617('0x7')]},'queue':{'type':Sequelize[_0x3ba617('0x7')]},'queuecallerjoinAt':{'type':Sequelize[_0x3ba617('0x6')]},'queuecallerleaveAt':{'type':Sequelize[_0x3ba617('0x6')],'set':function(_0x19d985){const _0x5969ea=_0x3ba617,_0x5335f1=moment(_0x19d985),_0x5b5fa1=moment(this[_0x5969ea('0xc')](_0x5969ea('0x4')))[_0x5969ea('0xe')](_0x5969ea('0x2')),_0x47e939=_0x5335f1[_0x5969ea('0x0')](_0x5b5fa1,_0x5969ea('0xb'));this[_0x5969ea('0xa')](_0x5969ea('0x8'),_0x19d985),this[_0x5969ea('0xa')](_0x5969ea('0xf'),_0x47e939||null);}},'position':{'type':Sequelize[_0x3ba617('0xd')]},'count':{'type':Sequelize[_0x3ba617('0xd')]},'queuecallerabandon':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'queuecallerabandonAt':{'type':Sequelize[_0x3ba617('0x6')]},'queuecallercomplete':{'type':Sequelize[_0x3ba617('0x1')],'defaultValue':![]},'queuecallercompleteAt':{'type':Sequelize['DATE']},'queuecallerexit':{'type':Sequelize[_0x3ba617('0x1')],'defaultValue':![]},'queuecallerexitAt':{'type':Sequelize[_0x3ba617('0x6')]},'queuecallerexitreason':{'type':Sequelize[_0x3ba617('0x7')],'comment':_0x3ba617('0x3')},'originalposition':{'type':Sequelize[_0x3ba617('0xd')]},'channel':{'type':Sequelize[_0x3ba617('0x7')]},'connectedlinenum':{'type':Sequelize['STRING']},'connectedlinename':{'type':Sequelize[_0x3ba617('0x7')]},'accountcode':{'type':Sequelize[_0x3ba617('0x7')]},'context':{'type':Sequelize['STRING']},'exten':{'type':Sequelize['STRING']},'priority':{'type':Sequelize[_0x3ba617('0x7')]},'holdtime':{'type':Sequelize['INTEGER']},'mohtime':{'type':Sequelize[_0x3ba617('0xd')],'defaultValue':0x0},'assigned':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'lastAssignedTo':{'type':Sequelize[_0x3ba617('0x7')]},'transfer':{'type':Sequelize[_0x3ba617('0x1')],'defaultValue':![]},'transfertype':{'type':Sequelize[_0x3ba617('0x7')],'comment':_0x3ba617('0x9')},'transferexten':{'type':Sequelize[_0x3ba617('0x7')]},'transferuniqueid':{'type':Sequelize[_0x3ba617('0x7')]},'disposition':{'type':Sequelize[_0x3ba617('0x7')]},'secondDisposition':{'type':Sequelize[_0x3ba617('0x7')]},'thirdDisposition':{'type':Sequelize[_0x3ba617('0x7')]},'queuecallerenterreason':{'type':Sequelize[_0x3ba617('0xd')],'defaultValue':0x0}}; \ No newline at end of file diff --git a/server/api/voiceQueueReport/voiceQueueReport.controller.js b/server/api/voiceQueueReport/voiceQueueReport.controller.js index c9e07d9..c257f9c 100644 --- a/server/api/voiceQueueReport/voiceQueueReport.controller.js +++ b/server/api/voiceQueueReport/voiceQueueReport.controller.js @@ -1 +1 @@ -const a760_0x4e6b=['like','register','VoiceQueueReport','count','error','include','destroy','keys','name','show','findOne','undefined','length','limit','findAll','lodash','../../config/logger','catch','send','VIRTUAL','update','intersection','../../components/parsers/qs','sequelize','type','status','set','rawAttributes','fields','key','rows','query','end','map','api','where','sort','stack','attributes','sendStatus','options','body','merge','params','then','order','filters','json','model','../../mysqldb','getVoiceQueuesReport','includeAll','Content-Range','filter','describe','offset','nolimit'];(function(_0x377a3d,_0x4e6b72){const _0x4b012a=function(_0x223d8b){while(--_0x223d8b){_0x377a3d['push'](_0x377a3d['shift']());}};_0x4b012a(++_0x4e6b72);}(a760_0x4e6b,0x1f2));const a760_0x4b01=function(_0x377a3d,_0x4e6b72){_0x377a3d=_0x377a3d-0x0;let _0x4b012a=a760_0x4e6b[_0x377a3d];return _0x4b012a;};const _0x5352f5=a760_0x4b01;'use strict';const _=require(_0x5352f5('0x1e')),qs=require(_0x5352f5('0x25')),logger=require(_0x5352f5('0x1f'))(_0x5352f5('0x31')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x5352f5('0x7'))['db'],{Op}=require(_0x5352f5('0x26'));require('./voiceQueueReport.socket')[_0x5352f5('0x10')](socket);function respondWithResult(_0x223d8b,_0x301910){return _0x301910=_0x301910||0xc8,function(_0x384626){const _0x44eb1d=a760_0x4b01;if(_0x384626)return _0x223d8b[_0x44eb1d('0x28')](_0x301910)[_0x44eb1d('0x5')](_0x384626);};}function respondWithFilteredResult(_0x17100f,_0x27688b){return function(_0x11658b){const _0x3b292f=a760_0x4b01;if(_0x11658b){const _0x35e4c5=_0x11658b[_0x3b292f('0x12')],_0x111a34=_0x27688b[_0x3b292f('0xd')];let _0x491028=_0x27688b[_0x3b292f('0xd')]+_0x27688b[_0x3b292f('0x1c')],_0x49bdfa;return _0x491028>=_0x35e4c5?(_0x491028=_0x35e4c5,_0x49bdfa=0xc8):_0x49bdfa=0xce,_0x17100f[_0x3b292f('0x28')](_0x49bdfa),_0x17100f[_0x3b292f('0x29')](_0x3b292f('0xa'),_0x111a34+'-'+_0x491028+'/'+_0x35e4c5)[_0x3b292f('0x5')](_0x11658b);}return null;};}function saveUpdates(_0x5f0f9f){return function(_0x5e4385){const _0x277698=a760_0x4b01;if(_0x5e4385)return _0x5e4385[_0x277698('0x23')](_0x5f0f9f)[_0x277698('0x2')](function(_0x5e0f15){return _0x5e0f15;});return null;};}function removeEntity(_0x409811){return function(_0x57e9b8){const _0x2620dd=a760_0x4b01;if(_0x57e9b8)return _0x57e9b8['destroy']()[_0x2620dd('0x2')](function(){const _0x199f5b=_0x2620dd;_0x409811[_0x199f5b('0x28')](0xcc)[_0x199f5b('0x2f')]();});};}function handleEntityNotFound(_0x20e877){return function(_0x318c54){const _0x3951e8=a760_0x4b01;return!_0x318c54&&_0x20e877[_0x3951e8('0x36')](0x194),_0x318c54;};}function handleError(_0x2a0569,_0x4bc02d){return _0x4bc02d=_0x4bc02d||0x1f4,function(_0x1cfca4){const _0x523475=a760_0x4b01;logger[_0x523475('0x13')](_0x1cfca4[_0x523475('0x34')]),_0x1cfca4['name']&&delete _0x1cfca4[_0x523475('0x17')],_0x2a0569[_0x523475('0x28')](_0x4bc02d)[_0x523475('0x21')](_0x1cfca4);};}exports['index']=function(_0x3e4d6f,_0x345842){const _0xc2e833=_0x5352f5;let _0x21b4ae={};const _0x3e82cd={},_0x926895={'count':0x0,'rows':[]},_0x552c5c=_[_0xc2e833('0x30')](db[_0xc2e833('0x11')][_0xc2e833('0x2a')],function(_0x1ffacc){const _0x37e738=_0xc2e833;return{'name':_0x1ffacc['fieldName'],'type':_0x1ffacc[_0x37e738('0x27')][_0x37e738('0x2c')]};});_0x3e82cd[_0xc2e833('0x6')]=_['map'](_0x552c5c,_0xc2e833('0x17')),_0x3e82cd[_0xc2e833('0x2e')]=_[_0xc2e833('0x16')](_0x3e4d6f[_0xc2e833('0x2e')]),_0x3e82cd['filters']=_[_0xc2e833('0x24')](_0x3e82cd['model'],_0x3e82cd[_0xc2e833('0x2e')]),_0x21b4ae[_0xc2e833('0x35')]=_[_0xc2e833('0x24')](_0x3e82cd['model'],qs[_0xc2e833('0x2b')](_0x3e4d6f[_0xc2e833('0x2e')]['fields'])),_0x21b4ae[_0xc2e833('0x35')]=_0x21b4ae[_0xc2e833('0x35')][_0xc2e833('0x1b')]?_0x21b4ae[_0xc2e833('0x35')]:_0x3e82cd['model'];typeof _0x3e4d6f[_0xc2e833('0x2e')][_0xc2e833('0xe')]==='undefined'&&(_0x21b4ae[_0xc2e833('0x1c')]=qs['limit'](_0x3e4d6f['query']['limit']),_0x21b4ae[_0xc2e833('0xd')]=qs[_0xc2e833('0xd')](_0x3e4d6f[_0xc2e833('0x2e')][_0xc2e833('0xd')]));_0x21b4ae['order']=qs['sort'](_0x3e4d6f['query'][_0xc2e833('0x33')]),_0x21b4ae[_0xc2e833('0x32')]=qs['filters'](_['pick'](_0x3e4d6f[_0xc2e833('0x2e')],_0x3e82cd[_0xc2e833('0x4')]),_0x552c5c);_0x3e4d6f[_0xc2e833('0x2e')]['filter']&&(_0x21b4ae[_0xc2e833('0x32')]=_['merge'](_0x21b4ae[_0xc2e833('0x32')],{[Op['or']]:_[_0xc2e833('0x30')](_0x552c5c,function(_0x5dd699){const _0x22e5d2=_0xc2e833;if(_0x5dd699[_0x22e5d2('0x27')]!==_0x22e5d2('0x22')){const _0x48ff93={};return _0x48ff93[_0x5dd699[_0x22e5d2('0x17')]]={[Op[_0x22e5d2('0xf')]]:'%'+_0x3e4d6f['query'][_0x22e5d2('0xb')]+'%'},_0x48ff93;}})}));_0x21b4ae=_['merge']({},_0x21b4ae,_0x3e4d6f[_0xc2e833('0x37')]);const _0x5c338b={'where':_0x21b4ae[_0xc2e833('0x32')]};return db[_0xc2e833('0x11')]['count'](_0x5c338b)[_0xc2e833('0x2')](function(_0x143aa0){const _0x41a817=_0xc2e833;return _0x926895[_0x41a817('0x12')]=_0x143aa0,_0x3e4d6f[_0x41a817('0x2e')][_0x41a817('0x9')]&&(_0x21b4ae[_0x41a817('0x14')]=[{'all':!![]}]),db[_0x41a817('0x11')][_0x41a817('0x1d')](_0x21b4ae);})[_0xc2e833('0x2')](function(_0x2858a7){return _0x926895['rows']=_0x2858a7,_0x926895;})[_0xc2e833('0x2')](respondWithFilteredResult(_0x345842,_0x21b4ae))[_0xc2e833('0x20')](handleError(_0x345842,null));},exports[_0x5352f5('0x18')]=function(_0x1dd714,_0x1cb876){const _0x464c8c=_0x5352f5;let _0x2075a9={'raw':![],'where':{'id':_0x1dd714[_0x464c8c('0x1')]['id']}};const _0x4fbed5={};return _0x4fbed5[_0x464c8c('0x6')]=_[_0x464c8c('0x16')](db['VoiceQueueReport'][_0x464c8c('0x2a')]),_0x4fbed5[_0x464c8c('0x2e')]=_['keys'](_0x1dd714[_0x464c8c('0x2e')]),_0x4fbed5[_0x464c8c('0x4')]=_['intersection'](_0x4fbed5['model'],_0x4fbed5[_0x464c8c('0x2e')]),_0x2075a9[_0x464c8c('0x35')]=_[_0x464c8c('0x24')](_0x4fbed5[_0x464c8c('0x6')],qs[_0x464c8c('0x2b')](_0x1dd714[_0x464c8c('0x2e')][_0x464c8c('0x2b')])),_0x2075a9[_0x464c8c('0x35')]=_0x2075a9['attributes']['length']?_0x2075a9[_0x464c8c('0x35')]:_0x4fbed5[_0x464c8c('0x6')],_0x1dd714[_0x464c8c('0x2e')][_0x464c8c('0x9')]&&(_0x2075a9[_0x464c8c('0x14')]=[{'all':!![]}]),_0x2075a9=_[_0x464c8c('0x0')]({},_0x2075a9,_0x1dd714['options']),db[_0x464c8c('0x11')]['findOne'](_0x2075a9)[_0x464c8c('0x2')](handleEntityNotFound(_0x1cb876,null))[_0x464c8c('0x2')](respondWithResult(_0x1cb876,null))[_0x464c8c('0x20')](handleError(_0x1cb876,null));},exports['create']=function(_0x27da24,_0x57ab0b){const _0x439242=_0x5352f5;return db[_0x439242('0x11')]['create'](_0x27da24[_0x439242('0x38')],{})['then'](respondWithResult(_0x57ab0b,0xc9))[_0x439242('0x20')](handleError(_0x57ab0b,null));},exports[_0x5352f5('0x23')]=function(_0x26e215,_0x521615){const _0x3fc066=_0x5352f5;return _0x26e215[_0x3fc066('0x38')]['id']&&delete _0x26e215[_0x3fc066('0x38')]['id'],db['VoiceQueueReport'][_0x3fc066('0x19')]({'where':{'id':_0x26e215[_0x3fc066('0x1')]['id']}})['then'](handleEntityNotFound(_0x521615,null))[_0x3fc066('0x2')](saveUpdates(_0x26e215[_0x3fc066('0x38')],null))['then'](respondWithResult(_0x521615,null))[_0x3fc066('0x20')](handleError(_0x521615,null));},exports[_0x5352f5('0x15')]=function(_0x275b0a,_0x5e57f7){const _0x5b2667=_0x5352f5;return db[_0x5b2667('0x11')][_0x5b2667('0x19')]({'where':{'id':_0x275b0a[_0x5b2667('0x1')]['id']}})[_0x5b2667('0x2')](handleEntityNotFound(_0x5e57f7,null))[_0x5b2667('0x2')](removeEntity(_0x5e57f7,null))['catch'](handleError(_0x5e57f7,null));},exports['describe']=function(_0x3533f2,_0x2ed6d5){const _0x6bfced=_0x5352f5;return db['VoiceQueueReport'][_0x6bfced('0xc')]()['then'](respondWithResult(_0x2ed6d5,null))[_0x6bfced('0x20')](handleError(_0x2ed6d5,null));},exports[_0x5352f5('0x8')]=function(_0x1ff718,_0xff39ea){const _0x4c664d=_0x5352f5;let _0x272c3d={};const _0x1a839b={},_0x47cdd8={'count':0x0,'rows':[]};_0x1a839b[_0x4c664d('0x6')]=_[_0x4c664d('0x16')](db[_0x4c664d('0x11')]['rawAttributes']),_0x1a839b[_0x4c664d('0x2e')]=_[_0x4c664d('0x16')](_0x1ff718[_0x4c664d('0x2e')]),_0x1a839b[_0x4c664d('0x4')]=_[_0x4c664d('0x24')](_0x1a839b['model'],_0x1a839b['query']),_0x272c3d[_0x4c664d('0x35')]=_[_0x4c664d('0x24')](_0x1a839b[_0x4c664d('0x6')],qs['fields'](_0x1ff718[_0x4c664d('0x2e')][_0x4c664d('0x2b')])),_0x272c3d[_0x4c664d('0x35')]=_0x272c3d[_0x4c664d('0x35')]['length']?_0x272c3d[_0x4c664d('0x35')]:_0x1a839b[_0x4c664d('0x6')];typeof _0x1ff718[_0x4c664d('0x2e')][_0x4c664d('0xe')]===_0x4c664d('0x1a')&&(_0x272c3d[_0x4c664d('0x1c')]=qs['limit'](_0x1ff718[_0x4c664d('0x2e')][_0x4c664d('0x1c')]),_0x272c3d[_0x4c664d('0xd')]=qs[_0x4c664d('0xd')](_0x1ff718['query'][_0x4c664d('0xd')]));_0x272c3d[_0x4c664d('0x3')]=qs['sort'](_0x1ff718[_0x4c664d('0x2e')][_0x4c664d('0x33')]),_0x272c3d['where']=qs['filters'](_['pick'](_0x1ff718[_0x4c664d('0x2e')],_0x1a839b[_0x4c664d('0x4')]));_0x1ff718[_0x4c664d('0x2e')][_0x4c664d('0xb')]&&(_0x272c3d[_0x4c664d('0x32')]=_[_0x4c664d('0x0')](_0x272c3d[_0x4c664d('0x32')],{[Op['or']]:_[_0x4c664d('0x30')](_0x272c3d['attributes'],function(_0x303653){const _0x5955be=_0x4c664d,_0x3fcbb4={};return _0x3fcbb4[_0x303653]={[Op['like']]:'%'+_0x1ff718['query'][_0x5955be('0xb')]+'%'},_0x3fcbb4;})}));_0x272c3d=_[_0x4c664d('0x0')]({},_0x272c3d,_0x1ff718[_0x4c664d('0x37')]);const _0x5d1044={'where':_0x272c3d['where']};return db[_0x4c664d('0x11')][_0x4c664d('0x12')](_0x5d1044)[_0x4c664d('0x2')](function(_0x5e8e48){const _0x53ad2a=_0x4c664d;return _0x47cdd8[_0x53ad2a('0x12')]=_0x5e8e48,_0x1ff718[_0x53ad2a('0x2e')]['includeAll']&&(_0x272c3d['include']=[{'all':!![]}]),db[_0x53ad2a('0x11')][_0x53ad2a('0x1d')](_0x272c3d);})[_0x4c664d('0x2')](function(_0x1d14b3){const _0x110994=_0x4c664d;return _0x47cdd8[_0x110994('0x2d')]=_0x1d14b3,_0x47cdd8;})[_0x4c664d('0x2')](respondWithFilteredResult(_0xff39ea,_0x272c3d,_0x4c664d('0x8')))[_0x4c664d('0x20')](handleError(_0xff39ea,null,_0x4c664d('0x8')));}; \ No newline at end of file +const a760_0xd12c=['model','describe','json','rawAttributes','VoiceQueueReport','key','undefined','stack','query','status','name','intersection','offset','map','filter','like','type','../../rediscache','count','filters','includeAll','params','fieldName','limit','lodash','catch','sort','merge','order','Content-Range','update','api','create','length','../../mysqldb','register','sequelize','error','fields','options','destroy','pick','then','where','nolimit','sendStatus','keys','./voiceQueueReport.socket','attributes','body','findAll','rows','set','VIRTUAL','end','findOne','include','getVoiceQueuesReport'];(function(_0x4ae3d0,_0xd12c29){const _0x27e937=function(_0x254a6e){while(--_0x254a6e){_0x4ae3d0['push'](_0x4ae3d0['shift']());}};_0x27e937(++_0xd12c29);}(a760_0xd12c,0x9e));const a760_0x27e9=function(_0x4ae3d0,_0xd12c29){_0x4ae3d0=_0x4ae3d0-0x0;let _0x27e937=a760_0xd12c[_0x4ae3d0];return _0x27e937;};const _0x427f07=a760_0x27e9;'use strict';const _=require(_0x427f07('0x28')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')(_0x427f07('0x2f')),{getSocket}=require(_0x427f07('0x21')),socket=getSocket(),db=require(_0x427f07('0x32'))['db'],{Op}=require(_0x427f07('0x34'));require(_0x427f07('0x5'))[_0x427f07('0x33')](socket);function respondWithResult(_0x254a6e,_0x1c6344){return _0x1c6344=_0x1c6344||0xc8,function(_0x18f548){const _0x2bd82d=a760_0x27e9;if(_0x18f548)return _0x254a6e[_0x2bd82d('0x19')](_0x1c6344)[_0x2bd82d('0x12')](_0x18f548);};}function respondWithFilteredResult(_0x3006f1,_0x37c4fd){return function(_0x21353e){const _0x1f687e=a760_0x27e9;if(_0x21353e){const _0x2c49db=_0x21353e[_0x1f687e('0x22')],_0x2fdff5=_0x37c4fd[_0x1f687e('0x1c')];let _0x3ade7d=_0x37c4fd['offset']+_0x37c4fd[_0x1f687e('0x27')],_0x2b10de;return _0x3ade7d>=_0x2c49db?(_0x3ade7d=_0x2c49db,_0x2b10de=0xc8):_0x2b10de=0xce,_0x3006f1[_0x1f687e('0x19')](_0x2b10de),_0x3006f1[_0x1f687e('0xa')](_0x1f687e('0x2d'),_0x2fdff5+'-'+_0x3ade7d+'/'+_0x2c49db)[_0x1f687e('0x12')](_0x21353e);}return null;};}function saveUpdates(_0x2848b1){return function(_0x3c1b2e){const _0x34a135=a760_0x27e9;if(_0x3c1b2e)return _0x3c1b2e[_0x34a135('0x2e')](_0x2848b1)['then'](function(_0x33bf75){return _0x33bf75;});return null;};}function removeEntity(_0x12eb48){return function(_0x172728){const _0x1c4689=a760_0x27e9;if(_0x172728)return _0x172728[_0x1c4689('0x38')]()[_0x1c4689('0x0')](function(){const _0x40a16d=_0x1c4689;_0x12eb48['status'](0xcc)[_0x40a16d('0xc')]();});};}function handleEntityNotFound(_0x27b241){return function(_0x5b3e4d){const _0x207767=a760_0x27e9;return!_0x5b3e4d&&_0x27b241[_0x207767('0x3')](0x194),_0x5b3e4d;};}function handleError(_0x413a8a,_0x3c4e04){return _0x3c4e04=_0x3c4e04||0x1f4,function(_0x5ddda4){const _0x1a09d3=a760_0x27e9;logger[_0x1a09d3('0x35')](_0x5ddda4[_0x1a09d3('0x17')]),_0x5ddda4[_0x1a09d3('0x1a')]&&delete _0x5ddda4['name'],_0x413a8a[_0x1a09d3('0x19')](_0x3c4e04)['send'](_0x5ddda4);};}exports['index']=function(_0x4cee3b,_0x39387c){const _0x162e04=_0x427f07;let _0x31677b={};const _0x373931={},_0x5e201d={'count':0x0,'rows':[]},_0x2ff2c7=_[_0x162e04('0x1d')](db[_0x162e04('0x14')][_0x162e04('0x13')],function(_0x1d9d87){const _0x528106=_0x162e04;return{'name':_0x1d9d87[_0x528106('0x26')],'type':_0x1d9d87[_0x528106('0x20')][_0x528106('0x15')]};});_0x373931['model']=_[_0x162e04('0x1d')](_0x2ff2c7,_0x162e04('0x1a')),_0x373931[_0x162e04('0x18')]=_[_0x162e04('0x4')](_0x4cee3b['query']),_0x373931[_0x162e04('0x23')]=_[_0x162e04('0x1b')](_0x373931['model'],_0x373931[_0x162e04('0x18')]),_0x31677b[_0x162e04('0x6')]=_[_0x162e04('0x1b')](_0x373931[_0x162e04('0x10')],qs[_0x162e04('0x36')](_0x4cee3b[_0x162e04('0x18')]['fields'])),_0x31677b[_0x162e04('0x6')]=_0x31677b[_0x162e04('0x6')][_0x162e04('0x31')]?_0x31677b['attributes']:_0x373931[_0x162e04('0x10')];typeof _0x4cee3b[_0x162e04('0x18')][_0x162e04('0x2')]===_0x162e04('0x16')&&(_0x31677b['limit']=qs[_0x162e04('0x27')](_0x4cee3b[_0x162e04('0x18')]['limit']),_0x31677b[_0x162e04('0x1c')]=qs['offset'](_0x4cee3b['query'][_0x162e04('0x1c')]));_0x31677b[_0x162e04('0x2c')]=qs[_0x162e04('0x2a')](_0x4cee3b[_0x162e04('0x18')]['sort']),_0x31677b[_0x162e04('0x1')]=qs[_0x162e04('0x23')](_[_0x162e04('0x39')](_0x4cee3b['query'],_0x373931[_0x162e04('0x23')]),_0x2ff2c7);_0x4cee3b[_0x162e04('0x18')]['filter']&&(_0x31677b[_0x162e04('0x1')]=_[_0x162e04('0x2b')](_0x31677b['where'],{[Op['or']]:_[_0x162e04('0x1d')](_0x2ff2c7,function(_0x124a79){const _0x2b052e=_0x162e04;if(_0x124a79['type']!==_0x2b052e('0xb')){const _0x19edbb={};return _0x19edbb[_0x124a79[_0x2b052e('0x1a')]]={[Op[_0x2b052e('0x1f')]]:'%'+_0x4cee3b[_0x2b052e('0x18')][_0x2b052e('0x1e')]+'%'},_0x19edbb;}})}));_0x31677b=_[_0x162e04('0x2b')]({},_0x31677b,_0x4cee3b[_0x162e04('0x37')]);const _0x1f5233={'where':_0x31677b[_0x162e04('0x1')]};return db['VoiceQueueReport'][_0x162e04('0x22')](_0x1f5233)[_0x162e04('0x0')](function(_0x1357c2){const _0x4caa59=_0x162e04;return _0x5e201d[_0x4caa59('0x22')]=_0x1357c2,_0x4cee3b[_0x4caa59('0x18')][_0x4caa59('0x24')]&&(_0x31677b['include']=[{'all':!![]}]),db['VoiceQueueReport'][_0x4caa59('0x8')](_0x31677b);})[_0x162e04('0x0')](function(_0x3b6a07){const _0x15ab69=_0x162e04;return _0x5e201d[_0x15ab69('0x9')]=_0x3b6a07,_0x5e201d;})[_0x162e04('0x0')](respondWithFilteredResult(_0x39387c,_0x31677b))[_0x162e04('0x29')](handleError(_0x39387c,null));},exports['show']=function(_0x15fc8b,_0x354191){const _0x1eb39b=_0x427f07;let _0x59620c={'raw':![],'where':{'id':_0x15fc8b['params']['id']}};const _0x4bcb8f={};return _0x4bcb8f[_0x1eb39b('0x10')]=_[_0x1eb39b('0x4')](db[_0x1eb39b('0x14')]['rawAttributes']),_0x4bcb8f[_0x1eb39b('0x18')]=_[_0x1eb39b('0x4')](_0x15fc8b[_0x1eb39b('0x18')]),_0x4bcb8f['filters']=_[_0x1eb39b('0x1b')](_0x4bcb8f['model'],_0x4bcb8f[_0x1eb39b('0x18')]),_0x59620c['attributes']=_[_0x1eb39b('0x1b')](_0x4bcb8f[_0x1eb39b('0x10')],qs[_0x1eb39b('0x36')](_0x15fc8b['query'][_0x1eb39b('0x36')])),_0x59620c[_0x1eb39b('0x6')]=_0x59620c[_0x1eb39b('0x6')]['length']?_0x59620c[_0x1eb39b('0x6')]:_0x4bcb8f[_0x1eb39b('0x10')],_0x15fc8b['query'][_0x1eb39b('0x24')]&&(_0x59620c[_0x1eb39b('0xe')]=[{'all':!![]}]),_0x59620c=_[_0x1eb39b('0x2b')]({},_0x59620c,_0x15fc8b[_0x1eb39b('0x37')]),db['VoiceQueueReport'][_0x1eb39b('0xd')](_0x59620c)['then'](handleEntityNotFound(_0x354191,null))[_0x1eb39b('0x0')](respondWithResult(_0x354191,null))[_0x1eb39b('0x29')](handleError(_0x354191,null));},exports[_0x427f07('0x30')]=function(_0x3e7a1c,_0x4cd42e){const _0x5b9410=_0x427f07;return db[_0x5b9410('0x14')][_0x5b9410('0x30')](_0x3e7a1c[_0x5b9410('0x7')],{})[_0x5b9410('0x0')](respondWithResult(_0x4cd42e,0xc9))[_0x5b9410('0x29')](handleError(_0x4cd42e,null));},exports[_0x427f07('0x2e')]=function(_0x2b3aac,_0x15f185){const _0x4044e6=_0x427f07;return _0x2b3aac[_0x4044e6('0x7')]['id']&&delete _0x2b3aac['body']['id'],db[_0x4044e6('0x14')]['findOne']({'where':{'id':_0x2b3aac[_0x4044e6('0x25')]['id']}})['then'](handleEntityNotFound(_0x15f185,null))[_0x4044e6('0x0')](saveUpdates(_0x2b3aac[_0x4044e6('0x7')],null))[_0x4044e6('0x0')](respondWithResult(_0x15f185,null))[_0x4044e6('0x29')](handleError(_0x15f185,null));},exports[_0x427f07('0x38')]=function(_0x3abf9d,_0x456bf3){const _0x84c46=_0x427f07;return db['VoiceQueueReport']['findOne']({'where':{'id':_0x3abf9d[_0x84c46('0x25')]['id']}})[_0x84c46('0x0')](handleEntityNotFound(_0x456bf3,null))[_0x84c46('0x0')](removeEntity(_0x456bf3,null))[_0x84c46('0x29')](handleError(_0x456bf3,null));},exports[_0x427f07('0x11')]=function(_0x717f8a,_0x46755f){const _0x23c16d=_0x427f07;return db[_0x23c16d('0x14')]['describe']()[_0x23c16d('0x0')](respondWithResult(_0x46755f,null))[_0x23c16d('0x29')](handleError(_0x46755f,null));},exports['getVoiceQueuesReport']=function(_0x53461e,_0x538bd0){const _0x2afb6b=_0x427f07;let _0x1e8549={};const _0x21862b={},_0x4dfc3a={'count':0x0,'rows':[]};_0x21862b[_0x2afb6b('0x10')]=_['keys'](db[_0x2afb6b('0x14')][_0x2afb6b('0x13')]),_0x21862b[_0x2afb6b('0x18')]=_[_0x2afb6b('0x4')](_0x53461e[_0x2afb6b('0x18')]),_0x21862b['filters']=_[_0x2afb6b('0x1b')](_0x21862b['model'],_0x21862b[_0x2afb6b('0x18')]),_0x1e8549['attributes']=_['intersection'](_0x21862b['model'],qs[_0x2afb6b('0x36')](_0x53461e[_0x2afb6b('0x18')][_0x2afb6b('0x36')])),_0x1e8549[_0x2afb6b('0x6')]=_0x1e8549[_0x2afb6b('0x6')]['length']?_0x1e8549[_0x2afb6b('0x6')]:_0x21862b[_0x2afb6b('0x10')];typeof _0x53461e[_0x2afb6b('0x18')]['nolimit']===_0x2afb6b('0x16')&&(_0x1e8549[_0x2afb6b('0x27')]=qs['limit'](_0x53461e[_0x2afb6b('0x18')][_0x2afb6b('0x27')]),_0x1e8549[_0x2afb6b('0x1c')]=qs['offset'](_0x53461e[_0x2afb6b('0x18')][_0x2afb6b('0x1c')]));_0x1e8549[_0x2afb6b('0x2c')]=qs['sort'](_0x53461e[_0x2afb6b('0x18')][_0x2afb6b('0x2a')]),_0x1e8549['where']=qs['filters'](_[_0x2afb6b('0x39')](_0x53461e[_0x2afb6b('0x18')],_0x21862b['filters']));_0x53461e[_0x2afb6b('0x18')][_0x2afb6b('0x1e')]&&(_0x1e8549[_0x2afb6b('0x1')]=_[_0x2afb6b('0x2b')](_0x1e8549[_0x2afb6b('0x1')],{[Op['or']]:_['map'](_0x1e8549['attributes'],function(_0x44ec93){const _0x5228a9=_0x2afb6b,_0x32a137={};return _0x32a137[_0x44ec93]={[Op['like']]:'%'+_0x53461e['query'][_0x5228a9('0x1e')]+'%'},_0x32a137;})}));_0x1e8549=_['merge']({},_0x1e8549,_0x53461e['options']);const _0x7cff82={'where':_0x1e8549[_0x2afb6b('0x1')]};return db[_0x2afb6b('0x14')]['count'](_0x7cff82)['then'](function(_0x76b6fb){const _0x37249d=_0x2afb6b;return _0x4dfc3a[_0x37249d('0x22')]=_0x76b6fb,_0x53461e[_0x37249d('0x18')]['includeAll']&&(_0x1e8549[_0x37249d('0xe')]=[{'all':!![]}]),db[_0x37249d('0x14')][_0x37249d('0x8')](_0x1e8549);})['then'](function(_0x4f487f){const _0xba571a=_0x2afb6b;return _0x4dfc3a[_0xba571a('0x9')]=_0x4f487f,_0x4dfc3a;})['then'](respondWithFilteredResult(_0x538bd0,_0x1e8549,_0x2afb6b('0xf')))[_0x2afb6b('0x29')](handleError(_0x538bd0,null,_0x2afb6b('0xf')));}; \ No newline at end of file diff --git a/server/api/voiceQueueReport/voiceQueueReport.events.js b/server/api/voiceQueueReport/voiceQueueReport.events.js index d3a7587..eeb9c8a 100644 --- a/server/api/voiceQueueReport/voiceQueueReport.events.js +++ b/server/api/voiceQueueReport/voiceQueueReport.events.js @@ -1 +1 @@ -const a761_0x370f=['save','emit','setMaxListeners','exports','undefined','update','events'];(function(_0x36f05a,_0x370f4e){const _0x350212=function(_0x35ca2c){while(--_0x35ca2c){_0x36f05a['push'](_0x36f05a['shift']());}};_0x350212(++_0x370f4e);}(a761_0x370f,0x84));const a761_0x3502=function(_0x36f05a,_0x370f4e){_0x36f05a=_0x36f05a-0x0;let _0x350212=a761_0x370f[_0x36f05a];return _0x350212;};const _0x38cb33=a761_0x3502;'use strict';const EventEmitter=require(_0x38cb33('0x0')),VoiceQueueReport=require('../../mysqldb')['db']['VoiceQueueReport'],VoiceQueueReportEvents=new EventEmitter();VoiceQueueReportEvents[_0x38cb33('0x3')](0x0);const events={'afterCreate':_0x38cb33('0x1'),'afterUpdate':_0x38cb33('0x6'),'afterDestroy':'remove'};function emitEvent(_0x35ca2c){return function(_0x3975ef){const _0x9b75ae=a761_0x3502;VoiceQueueReportEvents[_0x9b75ae('0x2')](_0x35ca2c+':'+_0x3975ef['id'],_0x3975ef),VoiceQueueReportEvents['emit'](_0x35ca2c,_0x3975ef);};}for(const e in events){if(typeof events[e]!==_0x38cb33('0x5')){const event=events[e];VoiceQueueReport['addHook'](e,emitEvent(event));}}module[_0x38cb33('0x4')]=VoiceQueueReportEvents; \ No newline at end of file +const a761_0x9ca4=['update','save','setMaxListeners','undefined','VoiceQueueReport','remove','events','emit','addHook'];(function(_0x159f74,_0x9ca485){const _0x4a3d3a=function(_0x3c8b47){while(--_0x3c8b47){_0x159f74['push'](_0x159f74['shift']());}};_0x4a3d3a(++_0x9ca485);}(a761_0x9ca4,0x1ea));const a761_0x4a3d=function(_0x159f74,_0x9ca485){_0x159f74=_0x159f74-0x0;let _0x4a3d3a=a761_0x9ca4[_0x159f74];return _0x4a3d3a;};const _0x410137=a761_0x4a3d;'use strict';const EventEmitter=require(_0x410137('0x2')),VoiceQueueReport=require('../../mysqldb')['db'][_0x410137('0x0')],VoiceQueueReportEvents=new EventEmitter();VoiceQueueReportEvents[_0x410137('0x7')](0x0);const events={'afterCreate':_0x410137('0x6'),'afterUpdate':_0x410137('0x5'),'afterDestroy':_0x410137('0x1')};function emitEvent(_0x3c8b47){return function(_0x58e533){const _0x313316=a761_0x4a3d;VoiceQueueReportEvents[_0x313316('0x3')](_0x3c8b47+':'+_0x58e533['id'],_0x58e533),VoiceQueueReportEvents[_0x313316('0x3')](_0x3c8b47,_0x58e533);};}for(const e in events){if(typeof events[e]!==_0x410137('0x8')){const event=events[e];VoiceQueueReport[_0x410137('0x4')](e,emitEvent(event));}}module['exports']=VoiceQueueReportEvents; \ No newline at end of file diff --git a/server/api/voiceQueueReport/voiceQueueReport.model.js b/server/api/voiceQueueReport/voiceQueueReport.model.js index d02bae0..00cb808 100644 --- a/server/api/voiceQueueReport/voiceQueueReport.model.js +++ b/server/api/voiceQueueReport/voiceQueueReport.model.js @@ -1 +1 @@ -const a762_0x2fd5=['calleridnum','uniqueid','report_queue','define','./voiceQueueReport.attributes'];(function(_0x577fba,_0x2fd5cd){const _0x16cd07=function(_0xa14859){while(--_0xa14859){_0x577fba['push'](_0x577fba['shift']());}};_0x16cd07(++_0x2fd5cd);}(a762_0x2fd5,0x147));const a762_0x16cd=function(_0x577fba,_0x2fd5cd){_0x577fba=_0x577fba-0x0;let _0x16cd07=a762_0x2fd5[_0x577fba];return _0x16cd07;};const _0x49c1f2=a762_0x16cd;'use strict';const attributes=require(_0x49c1f2('0x2'));module['exports']=function(_0xa14859){const _0x481621=_0x49c1f2,_0x3f7247=_0xa14859[_0x481621('0x1')]('VoiceQueueReport',attributes,{'tableName':_0x481621('0x0'),'paranoid':![],'indexes':[{'fields':[_0x481621('0x4')]},{'fields':[_0x481621('0x3')]}],'timestamps':!![]});return _0x3f7247;}; \ No newline at end of file +const a762_0x4927=['report_queue','exports','calleridnum','VoiceQueueReport','./voiceQueueReport.attributes','define'];(function(_0x2bdc5c,_0x492722){const _0x302be7=function(_0x32404d){while(--_0x32404d){_0x2bdc5c['push'](_0x2bdc5c['shift']());}};_0x302be7(++_0x492722);}(a762_0x4927,0x167));const a762_0x302b=function(_0x2bdc5c,_0x492722){_0x2bdc5c=_0x2bdc5c-0x0;let _0x302be7=a762_0x4927[_0x2bdc5c];return _0x302be7;};const _0x2f2a2f=a762_0x302b;'use strict';const attributes=require(_0x2f2a2f('0x5'));module[_0x2f2a2f('0x2')]=function(_0x32404d){const _0x5eb849=_0x2f2a2f,_0x285ca6=_0x32404d[_0x5eb849('0x0')](_0x5eb849('0x4'),attributes,{'tableName':_0x5eb849('0x1'),'paranoid':![],'indexes':[{'fields':['uniqueid']},{'fields':[_0x5eb849('0x3')]}],'timestamps':!![]});return _0x285ca6;}; \ No newline at end of file diff --git a/server/api/voiceQueueReport/voiceQueueReport.rpc.js b/server/api/voiceQueueReport/voiceQueueReport.rpc.js index 5e077b5..2405c2b 100644 --- a/server/api/voiceQueueReport/voiceQueueReport.rpc.js +++ b/server/api/voiceQueueReport/voiceQueueReport.rpc.js @@ -1 +1 @@ -const a763_0x433c=['then','model','../../rediscache','body','info','UpdateVoiceQueueReport','stringify','include','options','CreateVoiceQueueReport','create','error','../../mysqldb','../../config/logger','./voiceQueueReport.socket','where','limit','raw','register','debug','message','GetVoiceQueueReport','catch','attributes','VoiceQueueReport','lodash','findAll','map'];(function(_0x107c04,_0x433cf9){const _0x329bc8=function(_0x1669af){while(--_0x1669af){_0x107c04['push'](_0x107c04['shift']());}};_0x329bc8(++_0x433cf9);}(a763_0x433c,0x110));const a763_0x329b=function(_0x107c04,_0x433cf9){_0x107c04=_0x107c04-0x0;let _0x329bc8=a763_0x433c[_0x107c04];return _0x329bc8;};const _0x59e2c4=a763_0x329b;'use strict';const _=require(_0x59e2c4('0x5')),db=require(_0x59e2c4('0x14'))['db'],logger=require(_0x59e2c4('0x15'))('rpc'),{getSocket}=require(_0x59e2c4('0xa')),socket=getSocket();require(_0x59e2c4('0x16'))[_0x59e2c4('0x1a')](socket),exports[_0x59e2c4('0x1')]=function(_0x1669af){const _0x1fd96f=this;return new Promise(function(_0x30e6d4,_0x42fe24){const _0x4d4db3=a763_0x329b;return db[_0x4d4db3('0x4')][_0x4d4db3('0x6')]({'raw':_0x1669af[_0x4d4db3('0x10')]?_0x1669af['options']['raw']===undefined?!![]:![]:!![],'where':_0x1669af[_0x4d4db3('0x10')]?_0x1669af[_0x4d4db3('0x10')][_0x4d4db3('0x17')]||null:null,'attributes':_0x1669af[_0x4d4db3('0x10')]?_0x1669af[_0x4d4db3('0x10')]['attributes']||null:null,'limit':_0x1669af[_0x4d4db3('0x10')]?_0x1669af[_0x4d4db3('0x10')][_0x4d4db3('0x18')]||null:null,'include':_0x1669af[_0x4d4db3('0x10')]?_0x1669af[_0x4d4db3('0x10')][_0x4d4db3('0xf')]?_['map'](_0x1669af[_0x4d4db3('0x10')][_0x4d4db3('0xf')],function(_0x477223){const _0x1c64d2=_0x4d4db3;return{'model':db[_0x477223[_0x1c64d2('0x9')]],'as':_0x477223['as'],'attributes':_0x477223[_0x1c64d2('0x3')],'include':_0x477223[_0x1c64d2('0xf')]?_[_0x1c64d2('0x7')](_0x477223[_0x1c64d2('0xf')],function(_0x4a6353){const _0x429ce5=_0x1c64d2;return{'model':db[_0x4a6353[_0x429ce5('0x9')]],'as':_0x4a6353['as'],'attributes':_0x4a6353[_0x429ce5('0x3')],'include':_0x4a6353[_0x429ce5('0xf')]?_[_0x429ce5('0x7')](_0x4a6353[_0x429ce5('0xf')],function(_0x42ef02){const _0x52777c=_0x429ce5;return{'model':db[_0x42ef02[_0x52777c('0x9')]],'as':_0x42ef02['as'],'attributes':_0x42ef02['attributes']};}):[]};}):[]};}):[]:[]})['then'](function(_0x5ec2b0){const _0x4d0d19=_0x4d4db3;logger[_0x4d0d19('0xc')](_0x4d0d19('0x1'),_0x1669af),logger[_0x4d0d19('0x1b')](_0x4d0d19('0x1'),_0x1669af,JSON[_0x4d0d19('0xe')](_0x5ec2b0)),_0x30e6d4(_0x5ec2b0);})[_0x4d4db3('0x2')](function(_0x39e5a3){const _0x35281f=_0x4d4db3;logger['error'](_0x35281f('0x1'),_0x39e5a3[_0x35281f('0x0')],_0x1669af),_0x42fe24(_0x1fd96f[_0x35281f('0x13')](0x1f4,_0x39e5a3['message']));});});},exports[_0x59e2c4('0x11')]=function(_0x26cd04){const _0x4f3c2c=this;return new Promise(function(_0x2978c8,_0x2fc884){const _0x122a15=a763_0x329b;return db[_0x122a15('0x4')][_0x122a15('0x12')](_0x26cd04[_0x122a15('0xb')],{'raw':_0x26cd04[_0x122a15('0x10')]?_0x26cd04[_0x122a15('0x10')][_0x122a15('0x19')]===undefined?!![]:![]:!![]})['then'](function(_0x2c2865){const _0x35909b=_0x122a15;logger['info'](_0x35909b('0x11'),_0x26cd04),logger[_0x35909b('0x1b')](_0x35909b('0x11'),_0x26cd04,JSON[_0x35909b('0xe')](_0x2c2865)),_0x2978c8(_0x2c2865);})[_0x122a15('0x2')](function(_0x367718){const _0x4a0f71=_0x122a15;logger[_0x4a0f71('0x13')]('CreateVoiceQueueReport',_0x367718[_0x4a0f71('0x0')],_0x26cd04),_0x2fc884(_0x4f3c2c[_0x4a0f71('0x13')](0x1f4,_0x367718[_0x4a0f71('0x0')]));});});},exports['UpdateVoiceQueueReport']=function(_0x18830a){const _0x1d3b90=this;return new Promise(function(_0x5ecfd0,_0xce28c1){const _0x254c0b=a763_0x329b;return db['VoiceQueueReport']['update'](_0x18830a['body'],{'raw':_0x18830a['options']?_0x18830a[_0x254c0b('0x10')][_0x254c0b('0x19')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x18830a['options']?_0x18830a[_0x254c0b('0x10')][_0x254c0b('0x17')]||null:null,'attributes':_0x18830a[_0x254c0b('0x10')]?_0x18830a[_0x254c0b('0x10')][_0x254c0b('0x3')]||null:null,'limit':_0x18830a['options']?_0x18830a[_0x254c0b('0x10')]['limit']||null:null})[_0x254c0b('0x8')](function(_0x1a0ffc){const _0x4a225f=_0x254c0b;logger['info'](_0x4a225f('0xd'),_0x18830a),logger[_0x4a225f('0x1b')](_0x4a225f('0xd'),_0x18830a,JSON[_0x4a225f('0xe')](_0x1a0ffc)),_0x5ecfd0(_0x1a0ffc);})[_0x254c0b('0x2')](function(_0x58ab12){const _0x457110=_0x254c0b;logger['error']('UpdateVoiceQueueReport',_0x58ab12[_0x457110('0x0')],_0x18830a),_0xce28c1(_0x1d3b90[_0x457110('0x13')](0x1f4,_0x58ab12[_0x457110('0x0')]));});});}; \ No newline at end of file +const a763_0x48c6=['model','debug','info','./voiceQueueReport.socket','VoiceQueueReport','limit','error','../../config/logger','where','../../rediscache','UpdateVoiceQueueReport','CreateVoiceQueueReport','message','then','create','../../mysqldb','attributes','body','lodash','map','options','include','rpc','GetVoiceQueueReport','raw','catch'];(function(_0x31dbbe,_0x48c60f){const _0x307c71=function(_0x1610b7){while(--_0x1610b7){_0x31dbbe['push'](_0x31dbbe['shift']());}};_0x307c71(++_0x48c60f);}(a763_0x48c6,0x14d));const a763_0x307c=function(_0x31dbbe,_0x48c60f){_0x31dbbe=_0x31dbbe-0x0;let _0x307c71=a763_0x48c6[_0x31dbbe];return _0x307c71;};const _0x404a4a=a763_0x307c;'use strict';const _=require(_0x404a4a('0x17')),db=require(_0x404a4a('0x14'))['db'],logger=require(_0x404a4a('0xc'))(_0x404a4a('0x1')),{getSocket}=require(_0x404a4a('0xe')),socket=getSocket();require(_0x404a4a('0x8'))['register'](socket),exports[_0x404a4a('0x2')]=function(_0x1610b7){const _0x3350c6=this;return new Promise(function(_0xa32a50,_0x536d45){const _0x5c4eb8=a763_0x307c;return db['VoiceQueueReport']['findAll']({'raw':_0x1610b7[_0x5c4eb8('0x19')]?_0x1610b7['options'][_0x5c4eb8('0x3')]===undefined?!![]:![]:!![],'where':_0x1610b7[_0x5c4eb8('0x19')]?_0x1610b7[_0x5c4eb8('0x19')][_0x5c4eb8('0xd')]||null:null,'attributes':_0x1610b7[_0x5c4eb8('0x19')]?_0x1610b7[_0x5c4eb8('0x19')][_0x5c4eb8('0x15')]||null:null,'limit':_0x1610b7[_0x5c4eb8('0x19')]?_0x1610b7['options'][_0x5c4eb8('0xa')]||null:null,'include':_0x1610b7[_0x5c4eb8('0x19')]?_0x1610b7[_0x5c4eb8('0x19')]['include']?_[_0x5c4eb8('0x18')](_0x1610b7[_0x5c4eb8('0x19')][_0x5c4eb8('0x0')],function(_0x3199dd){const _0x2a59fb=_0x5c4eb8;return{'model':db[_0x3199dd['model']],'as':_0x3199dd['as'],'attributes':_0x3199dd[_0x2a59fb('0x15')],'include':_0x3199dd['include']?_[_0x2a59fb('0x18')](_0x3199dd['include'],function(_0x18de1f){const _0x179aa0=_0x2a59fb;return{'model':db[_0x18de1f['model']],'as':_0x18de1f['as'],'attributes':_0x18de1f[_0x179aa0('0x15')],'include':_0x18de1f[_0x179aa0('0x0')]?_[_0x179aa0('0x18')](_0x18de1f[_0x179aa0('0x0')],function(_0x1fa07f){const _0x94bb4d=_0x179aa0;return{'model':db[_0x1fa07f[_0x94bb4d('0x5')]],'as':_0x1fa07f['as'],'attributes':_0x1fa07f[_0x94bb4d('0x15')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x2e8f49){const _0x254a8c=_0x5c4eb8;logger['info'](_0x254a8c('0x2'),_0x1610b7),logger[_0x254a8c('0x6')]('GetVoiceQueueReport',_0x1610b7,JSON['stringify'](_0x2e8f49)),_0xa32a50(_0x2e8f49);})[_0x5c4eb8('0x4')](function(_0x1aac81){const _0x5960a5=_0x5c4eb8;logger[_0x5960a5('0xb')](_0x5960a5('0x2'),_0x1aac81['message'],_0x1610b7),_0x536d45(_0x3350c6[_0x5960a5('0xb')](0x1f4,_0x1aac81[_0x5960a5('0x11')]));});});},exports[_0x404a4a('0x10')]=function(_0x259035){const _0x8e733e=this;return new Promise(function(_0x29bfbf,_0x1e661c){const _0x320a12=a763_0x307c;return db[_0x320a12('0x9')][_0x320a12('0x13')](_0x259035[_0x320a12('0x16')],{'raw':_0x259035[_0x320a12('0x19')]?_0x259035[_0x320a12('0x19')][_0x320a12('0x3')]===undefined?!![]:![]:!![]})[_0x320a12('0x12')](function(_0xa16e60){const _0x3eba2b=_0x320a12;logger[_0x3eba2b('0x7')](_0x3eba2b('0x10'),_0x259035),logger[_0x3eba2b('0x6')](_0x3eba2b('0x10'),_0x259035,JSON['stringify'](_0xa16e60)),_0x29bfbf(_0xa16e60);})[_0x320a12('0x4')](function(_0x1f2613){const _0x56cd1b=_0x320a12;logger[_0x56cd1b('0xb')]('CreateVoiceQueueReport',_0x1f2613[_0x56cd1b('0x11')],_0x259035),_0x1e661c(_0x8e733e[_0x56cd1b('0xb')](0x1f4,_0x1f2613[_0x56cd1b('0x11')]));});});},exports[_0x404a4a('0xf')]=function(_0x410d00){const _0x17fb25=this;return new Promise(function(_0x1680eb,_0x5343c5){const _0x4bb872=a763_0x307c;return db[_0x4bb872('0x9')]['update'](_0x410d00[_0x4bb872('0x16')],{'raw':_0x410d00[_0x4bb872('0x19')]?_0x410d00['options'][_0x4bb872('0x3')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x410d00['options']?_0x410d00[_0x4bb872('0x19')]['where']||null:null,'attributes':_0x410d00['options']?_0x410d00[_0x4bb872('0x19')][_0x4bb872('0x15')]||null:null,'limit':_0x410d00[_0x4bb872('0x19')]?_0x410d00[_0x4bb872('0x19')][_0x4bb872('0xa')]||null:null})[_0x4bb872('0x12')](function(_0x402166){const _0x1b0253=_0x4bb872;logger[_0x1b0253('0x7')](_0x1b0253('0xf'),_0x410d00),logger[_0x1b0253('0x6')]('UpdateVoiceQueueReport',_0x410d00,JSON['stringify'](_0x402166)),_0x1680eb(_0x402166);})[_0x4bb872('0x4')](function(_0x304ac5){const _0x4775c3=_0x4bb872;logger['error'](_0x4775c3('0xf'),_0x304ac5['message'],_0x410d00),_0x5343c5(_0x17fb25[_0x4775c3('0xb')](0x1f4,_0x304ac5[_0x4775c3('0x11')]));});});}; \ No newline at end of file diff --git a/server/api/voiceQueueReport/voiceQueueReport.socket.js b/server/api/voiceQueueReport/voiceQueueReport.socket.js index e10cee0..39792a1 100644 --- a/server/api/voiceQueueReport/voiceQueueReport.socket.js +++ b/server/api/voiceQueueReport/voiceQueueReport.socket.js @@ -1 +1 @@ -const a764_0x2d3a=['voiceQueueReport:','remove','save','update','emit','register'];(function(_0xa1efc7,_0x2d3a65){const _0x3fb81e=function(_0x2a2e56){while(--_0x2a2e56){_0xa1efc7['push'](_0xa1efc7['shift']());}};_0x3fb81e(++_0x2d3a65);}(a764_0x2d3a,0x1bc));const a764_0x3fb8=function(_0xa1efc7,_0x2d3a65){_0xa1efc7=_0xa1efc7-0x0;let _0x3fb81e=a764_0x2d3a[_0xa1efc7];return _0x3fb81e;};const _0xfd33fd=a764_0x3fb8;'use strict';const VoiceQueueReportEvents=require('./voiceQueueReport.events'),events=[_0xfd33fd('0x2'),_0xfd33fd('0x1'),_0xfd33fd('0x3')];function createListener(_0x2a2e56,_0x50b02b){return function(_0x611175){const _0x4d5cd8=a764_0x3fb8;_0x50b02b[_0x4d5cd8('0x4')](_0x2a2e56,_0x611175);};}exports[_0xfd33fd('0x5')]=function(_0x38edac){const _0x2e44b1=_0xfd33fd;for(let _0x2666fa=0x0,_0x473cf7=events['length'];_0x2666fa<_0x473cf7;_0x2666fa++){const _0x360ff3=events[_0x2666fa],_0x3df1a3=createListener(_0x2e44b1('0x0')+_0x360ff3,_0x38edac);VoiceQueueReportEvents['on'](_0x360ff3,_0x3df1a3);}}; \ No newline at end of file +const a764_0x5f5c=['emit','save','remove','update','voiceQueueReport:','length'];(function(_0x9ff562,_0x5f5cca){const _0x18fd59=function(_0x3b7419){while(--_0x3b7419){_0x9ff562['push'](_0x9ff562['shift']());}};_0x18fd59(++_0x5f5cca);}(a764_0x5f5c,0x1f1));const a764_0x18fd=function(_0x9ff562,_0x5f5cca){_0x9ff562=_0x9ff562-0x0;let _0x18fd59=a764_0x5f5c[_0x9ff562];return _0x18fd59;};const _0x56f04e=a764_0x18fd;'use strict';const VoiceQueueReportEvents=require('./voiceQueueReport.events'),events=[_0x56f04e('0x2'),_0x56f04e('0x3'),_0x56f04e('0x4')];function createListener(_0x3b7419,_0x97b42c){return function(_0x477169){const _0x4dae46=a764_0x18fd;_0x97b42c[_0x4dae46('0x1')](_0x3b7419,_0x477169);};}exports['register']=function(_0x4fc2ac){const _0x107df6=_0x56f04e;for(let _0x3e7f29=0x0,_0x427489=events[_0x107df6('0x0')];_0x3e7f29<_0x427489;_0x3e7f29++){const _0x2ed5a4=events[_0x3e7f29],_0x123af8=createListener(_0x107df6('0x5')+_0x2ed5a4,_0x4fc2ac);VoiceQueueReportEvents['on'](_0x2ed5a4,_0x123af8);}}; \ No newline at end of file diff --git a/server/api/voiceQueuesLog/index.js b/server/api/voiceQueuesLog/index.js index 522aaa8..570c31a 100644 --- a/server/api/voiceQueuesLog/index.js +++ b/server/api/voiceQueuesLog/index.js @@ -1 +1 @@ -const a765_0xbba0=['../../components/auth/service','isAuthenticated','index','./voiceQueuesLog.controller','Router','destroy','create','delete','/:id','put','get'];(function(_0x17e3a8,_0xbba0f1){const _0x119f94=function(_0x520f40){while(--_0x520f40){_0x17e3a8['push'](_0x17e3a8['shift']());}};_0x119f94(++_0xbba0f1);}(a765_0xbba0,0x1e4));const a765_0x119f=function(_0x17e3a8,_0xbba0f1){_0x17e3a8=_0x17e3a8-0x0;let _0x119f94=a765_0xbba0[_0x17e3a8];return _0x119f94;};const _0x3e92c3=a765_0x119f;'use strict';const express=require('express'),router=express[_0x3e92c3('0x4')](),auth=require(_0x3e92c3('0x0')),controller=require(_0x3e92c3('0x3'));router[_0x3e92c3('0xa')]('/',auth[_0x3e92c3('0x1')](),controller[_0x3e92c3('0x2')]),router[_0x3e92c3('0xa')](_0x3e92c3('0x8'),auth[_0x3e92c3('0x1')](),controller['show']),router['post']('/',auth[_0x3e92c3('0x1')](),controller[_0x3e92c3('0x6')]),router[_0x3e92c3('0x9')](_0x3e92c3('0x8'),auth[_0x3e92c3('0x1')](),controller['update']),router[_0x3e92c3('0x7')](_0x3e92c3('0x8'),auth[_0x3e92c3('0x1')](),controller[_0x3e92c3('0x5')]),module['exports']=router; \ No newline at end of file +const a765_0x45eb=['destroy','exports','delete','put','Router','create','/:id','update','isAuthenticated','./voiceQueuesLog.controller','get','show','express'];(function(_0x4f2c1f,_0x45ebab){const _0x4fc771=function(_0x185c03){while(--_0x185c03){_0x4f2c1f['push'](_0x4f2c1f['shift']());}};_0x4fc771(++_0x45ebab);}(a765_0x45eb,0x136));const a765_0x4fc7=function(_0x4f2c1f,_0x45ebab){_0x4f2c1f=_0x4f2c1f-0x0;let _0x4fc771=a765_0x45eb[_0x4f2c1f];return _0x4fc771;};const _0xc54979=a765_0x4fc7;'use strict';const express=require(_0xc54979('0x1')),router=express[_0xc54979('0x6')](),auth=require('../../components/auth/service'),controller=require(_0xc54979('0xb'));router['get']('/',auth['isAuthenticated'](),controller['index']),router[_0xc54979('0xc')](_0xc54979('0x8'),auth[_0xc54979('0xa')](),controller[_0xc54979('0x0')]),router['post']('/',auth[_0xc54979('0xa')](),controller[_0xc54979('0x7')]),router[_0xc54979('0x5')](_0xc54979('0x8'),auth[_0xc54979('0xa')](),controller[_0xc54979('0x9')]),router[_0xc54979('0x4')](_0xc54979('0x8'),auth[_0xc54979('0xa')](),controller[_0xc54979('0x2')]),module[_0xc54979('0x3')]=router; \ No newline at end of file diff --git a/server/api/voiceQueuesLog/voiceQueuesLog.attributes.js b/server/api/voiceQueuesLog/voiceQueuesLog.attributes.js index a3d44bd..e9c107a 100644 --- a/server/api/voiceQueuesLog/voiceQueuesLog.attributes.js +++ b/server/api/voiceQueuesLog/voiceQueuesLog.attributes.js @@ -1 +1 @@ -const a766_0x2cfd=['moment','DATE','format','sequelize','YYYY-MM-DD\x20HH:mm:ss','STRING'];(function(_0x32ff3a,_0x2cfd26){const _0x4356ba=function(_0x24d54c){while(--_0x24d54c){_0x32ff3a['push'](_0x32ff3a['shift']());}};_0x4356ba(++_0x2cfd26);}(a766_0x2cfd,0x72));const a766_0x4356=function(_0x32ff3a,_0x2cfd26){_0x32ff3a=_0x32ff3a-0x0;let _0x4356ba=a766_0x2cfd[_0x32ff3a];return _0x4356ba;};const _0x188f00=a766_0x4356;'use strict';const Sequelize=require(_0x188f00('0x3')),moment=require(_0x188f00('0x0'));module['exports']={'time':{'type':Sequelize[_0x188f00('0x5')]},'callid':{'type':Sequelize[_0x188f00('0x5')],'allowNull':![],'defaultValue':''},'queuename':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':''},'agent':{'type':Sequelize[_0x188f00('0x5')],'allowNull':![],'defaultValue':''},'event':{'type':Sequelize[_0x188f00('0x5')],'allowNull':![],'defaultValue':''},'data':{'type':Sequelize[_0x188f00('0x5')],'allowNull':![],'defaultValue':''},'data1':{'type':Sequelize[_0x188f00('0x5')],'allowNull':![],'defaultValue':''},'data2':{'type':Sequelize[_0x188f00('0x5')],'allowNull':![],'defaultValue':''},'data3':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':''},'data4':{'type':Sequelize[_0x188f00('0x5')],'allowNull':![],'defaultValue':''},'data5':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':''},'dtm':{'type':Sequelize[_0x188f00('0x1')],'allowNull':![],'defaultValue':moment()[_0x188f00('0x2')](_0x188f00('0x4'))}}; \ No newline at end of file +const a766_0x43f6=['sequelize','format','DATE','STRING','YYYY-MM-DD\x20HH:mm:ss','exports'];(function(_0xbb969,_0x43f6b2){const _0x315fa4=function(_0x1ad85e){while(--_0x1ad85e){_0xbb969['push'](_0xbb969['shift']());}};_0x315fa4(++_0x43f6b2);}(a766_0x43f6,0xc8));const a766_0x315f=function(_0xbb969,_0x43f6b2){_0xbb969=_0xbb969-0x0;let _0x315fa4=a766_0x43f6[_0xbb969];return _0x315fa4;};const _0x419bc8=a766_0x315f;'use strict';const Sequelize=require(_0x419bc8('0x4')),moment=require('moment');module[_0x419bc8('0x3')]={'time':{'type':Sequelize['STRING']},'callid':{'type':Sequelize[_0x419bc8('0x1')],'allowNull':![],'defaultValue':''},'queuename':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':''},'agent':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':''},'event':{'type':Sequelize[_0x419bc8('0x1')],'allowNull':![],'defaultValue':''},'data':{'type':Sequelize[_0x419bc8('0x1')],'allowNull':![],'defaultValue':''},'data1':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':''},'data2':{'type':Sequelize['STRING'],'allowNull':![],'defaultValue':''},'data3':{'type':Sequelize[_0x419bc8('0x1')],'allowNull':![],'defaultValue':''},'data4':{'type':Sequelize[_0x419bc8('0x1')],'allowNull':![],'defaultValue':''},'data5':{'type':Sequelize[_0x419bc8('0x1')],'allowNull':![],'defaultValue':''},'dtm':{'type':Sequelize[_0x419bc8('0x0')],'allowNull':![],'defaultValue':moment()[_0x419bc8('0x5')](_0x419bc8('0x2'))}}; \ No newline at end of file diff --git a/server/api/voiceQueuesLog/voiceQueuesLog.controller.js b/server/api/voiceQueuesLog/voiceQueuesLog.controller.js index 3aabb21..8541659 100644 --- a/server/api/voiceQueuesLog/voiceQueuesLog.controller.js +++ b/server/api/voiceQueuesLog/voiceQueuesLog.controller.js @@ -1 +1 @@ -const a767_0x1102=['catch','where','rows','filters','sort','end','update','VoiceQueuesLog','attributes','filter','../../components/parsers/qs','findOne','params','../../mysqldb','count','length','index','json','VIRTUAL','status','options','sequelize','set','include','sendStatus','intersection','rawAttributes','map','keys','query','api','offset','error','model','nolimit','../../config/logger','pick','stack','merge','fields','type','name','destroy','show','lodash','body','create','then','limit','findAll'];(function(_0x3f840c,_0x110292){const _0x8dc6fa=function(_0x47889c){while(--_0x47889c){_0x3f840c['push'](_0x3f840c['shift']());}};_0x8dc6fa(++_0x110292);}(a767_0x1102,0x112));const a767_0x8dc6=function(_0x3f840c,_0x110292){_0x3f840c=_0x3f840c-0x0;let _0x8dc6fa=a767_0x1102[_0x3f840c];return _0x8dc6fa;};const _0x2e828b=a767_0x8dc6;'use strict';const _=require(_0x2e828b('0x14')),qs=require(_0x2e828b('0x24')),logger=require(_0x2e828b('0xb'))(_0x2e828b('0x6')),db=require(_0x2e828b('0x27'))['db'],{Op}=require(_0x2e828b('0x2f'));function respondWithResult(_0x47889c,_0x2a79b0){return _0x2a79b0=_0x2a79b0||0xc8,function(_0x50876d){const _0x4f5345=a767_0x8dc6;if(_0x50876d)return _0x47889c[_0x4f5345('0x2d')](_0x2a79b0)[_0x4f5345('0x2b')](_0x50876d);};}function respondWithFilteredResult(_0x52c047,_0x173a3a){return function(_0x50c8e5){const _0x4dbaf6=a767_0x8dc6;if(_0x50c8e5){const _0x5cd746=_0x50c8e5[_0x4dbaf6('0x28')],_0x56540b=_0x173a3a[_0x4dbaf6('0x7')];let _0x436ba7=_0x173a3a[_0x4dbaf6('0x7')]+_0x173a3a[_0x4dbaf6('0x18')],_0x2cadaa;return _0x436ba7>=_0x5cd746?(_0x436ba7=_0x5cd746,_0x2cadaa=0xc8):_0x2cadaa=0xce,_0x52c047[_0x4dbaf6('0x2d')](_0x2cadaa),_0x52c047[_0x4dbaf6('0x30')]('Content-Range',_0x56540b+'-'+_0x436ba7+'/'+_0x5cd746)[_0x4dbaf6('0x2b')](_0x50c8e5);}return null;};}function saveUpdates(_0x3cdf4c){return function(_0x2c91ec){const _0x875e51=a767_0x8dc6;if(_0x2c91ec)return _0x2c91ec['update'](_0x3cdf4c)[_0x875e51('0x17')](function(_0x5a3afb){return _0x5a3afb;});return null;};}function removeEntity(_0x16d959){return function(_0x457152){const _0x668e4b=a767_0x8dc6;if(_0x457152)return _0x457152['destroy']()[_0x668e4b('0x17')](function(){const _0x1b2858=_0x668e4b;_0x16d959['status'](0xcc)[_0x1b2858('0x1f')]();});};}function handleEntityNotFound(_0x112334){return function(_0x4c5e19){const _0x328ab2=a767_0x8dc6;return!_0x4c5e19&&_0x112334[_0x328ab2('0x0')](0x194),_0x4c5e19;};}function handleError(_0x3feee6,_0x3feb38){return _0x3feb38=_0x3feb38||0x1f4,function(_0x130252){const _0x2bc020=a767_0x8dc6;logger[_0x2bc020('0x8')](_0x130252[_0x2bc020('0xd')]),_0x130252['name']&&delete _0x130252[_0x2bc020('0x11')],_0x3feee6['status'](_0x3feb38)['send'](_0x130252);};}exports[_0x2e828b('0x2a')]=function(_0x4fcb4a,_0x2532a0){const _0x1670c9=_0x2e828b;let _0x57d948={};const _0x3e0c58={},_0x4a918a={'count':0x0,'rows':[]},_0x263abe=_['map'](db['VoiceQueuesLog'][_0x1670c9('0x2')],function(_0x27f3a8){return{'name':_0x27f3a8['fieldName'],'type':_0x27f3a8['type']['key']};});_0x3e0c58[_0x1670c9('0x9')]=_[_0x1670c9('0x3')](_0x263abe,_0x1670c9('0x11')),_0x3e0c58[_0x1670c9('0x5')]=_[_0x1670c9('0x4')](_0x4fcb4a['query']),_0x3e0c58[_0x1670c9('0x1d')]=_[_0x1670c9('0x1')](_0x3e0c58[_0x1670c9('0x9')],_0x3e0c58[_0x1670c9('0x5')]),_0x57d948[_0x1670c9('0x22')]=_['intersection'](_0x3e0c58[_0x1670c9('0x9')],qs[_0x1670c9('0xf')](_0x4fcb4a[_0x1670c9('0x5')]['fields'])),_0x57d948[_0x1670c9('0x22')]=_0x57d948[_0x1670c9('0x22')]['length']?_0x57d948['attributes']:_0x3e0c58[_0x1670c9('0x9')];typeof _0x4fcb4a[_0x1670c9('0x5')][_0x1670c9('0xa')]==='undefined'&&(_0x57d948[_0x1670c9('0x18')]=qs[_0x1670c9('0x18')](_0x4fcb4a[_0x1670c9('0x5')][_0x1670c9('0x18')]),_0x57d948['offset']=qs[_0x1670c9('0x7')](_0x4fcb4a['query'][_0x1670c9('0x7')]));_0x57d948['order']=qs[_0x1670c9('0x1e')](_0x4fcb4a[_0x1670c9('0x5')][_0x1670c9('0x1e')]),_0x57d948[_0x1670c9('0x1b')]=qs[_0x1670c9('0x1d')](_[_0x1670c9('0xc')](_0x4fcb4a[_0x1670c9('0x5')],_0x3e0c58[_0x1670c9('0x1d')]),_0x263abe);_0x4fcb4a[_0x1670c9('0x5')][_0x1670c9('0x23')]&&(_0x57d948[_0x1670c9('0x1b')]=_[_0x1670c9('0xe')](_0x57d948[_0x1670c9('0x1b')],{[Op['or']]:_[_0x1670c9('0x3')](_0x263abe,function(_0x1bfa71){const _0xeedeb2=_0x1670c9;if(_0x1bfa71[_0xeedeb2('0x10')]!==_0xeedeb2('0x2c')){const _0x5d5006={};return _0x5d5006[_0x1bfa71[_0xeedeb2('0x11')]]={[Op['like']]:'%'+_0x4fcb4a[_0xeedeb2('0x5')][_0xeedeb2('0x23')]+'%'},_0x5d5006;}})}));_0x57d948=_[_0x1670c9('0xe')]({},_0x57d948,_0x4fcb4a[_0x1670c9('0x2e')]);const _0x544acf={'where':_0x57d948['where']};return db[_0x1670c9('0x21')][_0x1670c9('0x28')](_0x544acf)[_0x1670c9('0x17')](function(_0x2c7628){const _0x2d584d=_0x1670c9;return _0x4a918a[_0x2d584d('0x28')]=_0x2c7628,_0x4fcb4a[_0x2d584d('0x5')]['includeAll']&&(_0x57d948[_0x2d584d('0x31')]=[{'all':!![]}]),db['VoiceQueuesLog'][_0x2d584d('0x19')](_0x57d948);})[_0x1670c9('0x17')](function(_0xedab6b){const _0x52edc5=_0x1670c9;return _0x4a918a[_0x52edc5('0x1c')]=_0xedab6b,_0x4a918a;})[_0x1670c9('0x17')](respondWithFilteredResult(_0x2532a0,_0x57d948))[_0x1670c9('0x1a')](handleError(_0x2532a0,null));},exports[_0x2e828b('0x13')]=function(_0x35c715,_0x224c08){const _0x330298=_0x2e828b;let _0x496ceb={'raw':!![],'where':{'id':_0x35c715[_0x330298('0x26')]['id']}};const _0x1d433b={};return _0x1d433b['model']=_[_0x330298('0x4')](db[_0x330298('0x21')][_0x330298('0x2')]),_0x1d433b[_0x330298('0x5')]=_['keys'](_0x35c715['query']),_0x1d433b['filters']=_[_0x330298('0x1')](_0x1d433b[_0x330298('0x9')],_0x1d433b['query']),_0x496ceb[_0x330298('0x22')]=_[_0x330298('0x1')](_0x1d433b[_0x330298('0x9')],qs[_0x330298('0xf')](_0x35c715[_0x330298('0x5')][_0x330298('0xf')])),_0x496ceb[_0x330298('0x22')]=_0x496ceb[_0x330298('0x22')][_0x330298('0x29')]?_0x496ceb[_0x330298('0x22')]:_0x1d433b[_0x330298('0x9')],_0x35c715['query']['includeAll']&&(_0x496ceb[_0x330298('0x31')]=[{'all':!![]}]),_0x496ceb=_['merge']({},_0x496ceb,_0x35c715['options']),db['VoiceQueuesLog'][_0x330298('0x25')](_0x496ceb)[_0x330298('0x17')](handleEntityNotFound(_0x224c08,null))[_0x330298('0x17')](respondWithResult(_0x224c08,null))[_0x330298('0x1a')](handleError(_0x224c08,null));},exports[_0x2e828b('0x16')]=function(_0x30c914,_0x5f12e8){const _0x53e6e4=_0x2e828b;return db[_0x53e6e4('0x21')][_0x53e6e4('0x16')](_0x30c914[_0x53e6e4('0x15')],{})[_0x53e6e4('0x17')](respondWithResult(_0x5f12e8,0xc9))[_0x53e6e4('0x1a')](handleError(_0x5f12e8,null));},exports[_0x2e828b('0x20')]=function(_0x107ed7,_0x3f3eb6){const _0x197558=_0x2e828b;return _0x107ed7[_0x197558('0x15')]['id']&&delete _0x107ed7[_0x197558('0x15')]['id'],db['VoiceQueuesLog'][_0x197558('0x25')]({'where':{'id':_0x107ed7[_0x197558('0x26')]['id']}})[_0x197558('0x17')](handleEntityNotFound(_0x3f3eb6,null))['then'](saveUpdates(_0x107ed7['body'],null))[_0x197558('0x17')](respondWithResult(_0x3f3eb6,null))[_0x197558('0x1a')](handleError(_0x3f3eb6,null));},exports[_0x2e828b('0x12')]=function(_0x2cdbca,_0x131c2b){const _0xd117b4=_0x2e828b;return db[_0xd117b4('0x21')]['findOne']({'where':{'id':_0x2cdbca['params']['id']}})[_0xd117b4('0x17')](handleEntityNotFound(_0x131c2b,null))['then'](removeEntity(_0x131c2b,null))[_0xd117b4('0x1a')](handleError(_0x131c2b,null));}; \ No newline at end of file +const a767_0x5498=['json','send','filters','merge','set','name','show','where','map','undefined','Content-Range','pick','model','catch','api','destroy','query','options','lodash','end','fields','../../mysqldb','findAll','type','sendStatus','attributes','sequelize','status','include','stack','length','../../components/parsers/qs','intersection','findOne','body','count','sort','like','nolimit','update','order','create','offset','then','VoiceQueuesLog','index','params','rows','limit','filter','rawAttributes','keys'];(function(_0x304bb3,_0x549840){const _0x463f15=function(_0x489bd1){while(--_0x489bd1){_0x304bb3['push'](_0x304bb3['shift']());}};_0x463f15(++_0x549840);}(a767_0x5498,0xe3));const a767_0x463f=function(_0x304bb3,_0x549840){_0x304bb3=_0x304bb3-0x0;let _0x463f15=a767_0x5498[_0x304bb3];return _0x463f15;};const _0x2c40d8=a767_0x463f;'use strict';const _=require(_0x2c40d8('0x33')),qs=require(_0x2c40d8('0xc')),logger=require('../../config/logger')(_0x2c40d8('0x2f')),db=require(_0x2c40d8('0x2'))['db'],{Op}=require(_0x2c40d8('0x7'));function respondWithResult(_0x489bd1,_0x243f79){return _0x243f79=_0x243f79||0xc8,function(_0x2bd7b4){const _0x250ca8=a767_0x463f;if(_0x2bd7b4)return _0x489bd1['status'](_0x243f79)[_0x250ca8('0x21')](_0x2bd7b4);};}function respondWithFilteredResult(_0x2ec12b,_0x129e3a){return function(_0x57e38d){const _0x4d3d11=a767_0x463f;if(_0x57e38d){const _0x4c0125=_0x57e38d[_0x4d3d11('0x10')],_0x352f68=_0x129e3a['offset'];let _0x23866e=_0x129e3a[_0x4d3d11('0x17')]+_0x129e3a[_0x4d3d11('0x1d')],_0x5307ef;return _0x23866e>=_0x4c0125?(_0x23866e=_0x4c0125,_0x5307ef=0xc8):_0x5307ef=0xce,_0x2ec12b[_0x4d3d11('0x8')](_0x5307ef),_0x2ec12b[_0x4d3d11('0x25')](_0x4d3d11('0x2b'),_0x352f68+'-'+_0x23866e+'/'+_0x4c0125)['json'](_0x57e38d);}return null;};}function saveUpdates(_0x30fad3){return function(_0x2241ee){const _0x44393d=a767_0x463f;if(_0x2241ee)return _0x2241ee['update'](_0x30fad3)[_0x44393d('0x18')](function(_0x581748){return _0x581748;});return null;};}function removeEntity(_0x28ce57){return function(_0x2a6348){const _0x3dd253=a767_0x463f;if(_0x2a6348)return _0x2a6348[_0x3dd253('0x30')]()['then'](function(){const _0xf25fda=_0x3dd253;_0x28ce57[_0xf25fda('0x8')](0xcc)[_0xf25fda('0x0')]();});};}function handleEntityNotFound(_0x2d6441){return function(_0xaab5eb){const _0x19bdb6=a767_0x463f;return!_0xaab5eb&&_0x2d6441[_0x19bdb6('0x5')](0x194),_0xaab5eb;};}function handleError(_0x57137c,_0xaf7636){return _0xaf7636=_0xaf7636||0x1f4,function(_0x1e1229){const _0xebae8e=a767_0x463f;logger['error'](_0x1e1229[_0xebae8e('0xa')]),_0x1e1229['name']&&delete _0x1e1229['name'],_0x57137c[_0xebae8e('0x8')](_0xaf7636)[_0xebae8e('0x22')](_0x1e1229);};}exports[_0x2c40d8('0x1a')]=function(_0x470167,_0x4fc0e2){const _0x21e7e6=_0x2c40d8;let _0x45718c={};const _0x1027ba={},_0x2ba4e7={'count':0x0,'rows':[]},_0x1339f8=_[_0x21e7e6('0x29')](db[_0x21e7e6('0x19')]['rawAttributes'],function(_0x45a38f){const _0x46a0da=_0x21e7e6;return{'name':_0x45a38f['fieldName'],'type':_0x45a38f[_0x46a0da('0x4')]['key']};});_0x1027ba[_0x21e7e6('0x2d')]=_['map'](_0x1339f8,_0x21e7e6('0x26')),_0x1027ba[_0x21e7e6('0x31')]=_[_0x21e7e6('0x20')](_0x470167[_0x21e7e6('0x31')]),_0x1027ba[_0x21e7e6('0x23')]=_['intersection'](_0x1027ba[_0x21e7e6('0x2d')],_0x1027ba[_0x21e7e6('0x31')]),_0x45718c[_0x21e7e6('0x6')]=_[_0x21e7e6('0xd')](_0x1027ba[_0x21e7e6('0x2d')],qs[_0x21e7e6('0x1')](_0x470167['query'][_0x21e7e6('0x1')])),_0x45718c[_0x21e7e6('0x6')]=_0x45718c[_0x21e7e6('0x6')][_0x21e7e6('0xb')]?_0x45718c[_0x21e7e6('0x6')]:_0x1027ba[_0x21e7e6('0x2d')];typeof _0x470167['query'][_0x21e7e6('0x13')]===_0x21e7e6('0x2a')&&(_0x45718c[_0x21e7e6('0x1d')]=qs[_0x21e7e6('0x1d')](_0x470167[_0x21e7e6('0x31')][_0x21e7e6('0x1d')]),_0x45718c['offset']=qs[_0x21e7e6('0x17')](_0x470167[_0x21e7e6('0x31')][_0x21e7e6('0x17')]));_0x45718c[_0x21e7e6('0x15')]=qs[_0x21e7e6('0x11')](_0x470167[_0x21e7e6('0x31')]['sort']),_0x45718c[_0x21e7e6('0x28')]=qs[_0x21e7e6('0x23')](_[_0x21e7e6('0x2c')](_0x470167[_0x21e7e6('0x31')],_0x1027ba[_0x21e7e6('0x23')]),_0x1339f8);_0x470167[_0x21e7e6('0x31')]['filter']&&(_0x45718c[_0x21e7e6('0x28')]=_['merge'](_0x45718c[_0x21e7e6('0x28')],{[Op['or']]:_[_0x21e7e6('0x29')](_0x1339f8,function(_0x28a5bf){const _0x34554c=_0x21e7e6;if(_0x28a5bf['type']!=='VIRTUAL'){const _0x152f4c={};return _0x152f4c[_0x28a5bf[_0x34554c('0x26')]]={[Op[_0x34554c('0x12')]]:'%'+_0x470167[_0x34554c('0x31')][_0x34554c('0x1e')]+'%'},_0x152f4c;}})}));_0x45718c=_[_0x21e7e6('0x24')]({},_0x45718c,_0x470167['options']);const _0x10deae={'where':_0x45718c[_0x21e7e6('0x28')]};return db['VoiceQueuesLog']['count'](_0x10deae)['then'](function(_0x5ee0f6){const _0x52c0ae=_0x21e7e6;return _0x2ba4e7['count']=_0x5ee0f6,_0x470167[_0x52c0ae('0x31')]['includeAll']&&(_0x45718c[_0x52c0ae('0x9')]=[{'all':!![]}]),db[_0x52c0ae('0x19')][_0x52c0ae('0x3')](_0x45718c);})['then'](function(_0x53e7ff){const _0x57545b=_0x21e7e6;return _0x2ba4e7[_0x57545b('0x1c')]=_0x53e7ff,_0x2ba4e7;})['then'](respondWithFilteredResult(_0x4fc0e2,_0x45718c))[_0x21e7e6('0x2e')](handleError(_0x4fc0e2,null));},exports[_0x2c40d8('0x27')]=function(_0x4144d0,_0xe2cbf6){const _0x299cff=_0x2c40d8;let _0x1066e5={'raw':!![],'where':{'id':_0x4144d0[_0x299cff('0x1b')]['id']}};const _0x530731={};return _0x530731['model']=_[_0x299cff('0x20')](db[_0x299cff('0x19')][_0x299cff('0x1f')]),_0x530731[_0x299cff('0x31')]=_[_0x299cff('0x20')](_0x4144d0[_0x299cff('0x31')]),_0x530731['filters']=_['intersection'](_0x530731[_0x299cff('0x2d')],_0x530731[_0x299cff('0x31')]),_0x1066e5[_0x299cff('0x6')]=_[_0x299cff('0xd')](_0x530731[_0x299cff('0x2d')],qs[_0x299cff('0x1')](_0x4144d0['query'][_0x299cff('0x1')])),_0x1066e5[_0x299cff('0x6')]=_0x1066e5[_0x299cff('0x6')]['length']?_0x1066e5['attributes']:_0x530731[_0x299cff('0x2d')],_0x4144d0[_0x299cff('0x31')]['includeAll']&&(_0x1066e5[_0x299cff('0x9')]=[{'all':!![]}]),_0x1066e5=_[_0x299cff('0x24')]({},_0x1066e5,_0x4144d0[_0x299cff('0x32')]),db[_0x299cff('0x19')]['findOne'](_0x1066e5)[_0x299cff('0x18')](handleEntityNotFound(_0xe2cbf6,null))[_0x299cff('0x18')](respondWithResult(_0xe2cbf6,null))[_0x299cff('0x2e')](handleError(_0xe2cbf6,null));},exports[_0x2c40d8('0x16')]=function(_0x7234db,_0x98310b){const _0x50e911=_0x2c40d8;return db[_0x50e911('0x19')][_0x50e911('0x16')](_0x7234db['body'],{})[_0x50e911('0x18')](respondWithResult(_0x98310b,0xc9))['catch'](handleError(_0x98310b,null));},exports[_0x2c40d8('0x14')]=function(_0x25cc9e,_0x3516d7){const _0x4ecd5f=_0x2c40d8;return _0x25cc9e[_0x4ecd5f('0xf')]['id']&&delete _0x25cc9e[_0x4ecd5f('0xf')]['id'],db[_0x4ecd5f('0x19')]['findOne']({'where':{'id':_0x25cc9e[_0x4ecd5f('0x1b')]['id']}})['then'](handleEntityNotFound(_0x3516d7,null))['then'](saveUpdates(_0x25cc9e[_0x4ecd5f('0xf')],null))[_0x4ecd5f('0x18')](respondWithResult(_0x3516d7,null))['catch'](handleError(_0x3516d7,null));},exports['destroy']=function(_0x182469,_0x5906d3){const _0x592397=_0x2c40d8;return db['VoiceQueuesLog'][_0x592397('0xe')]({'where':{'id':_0x182469[_0x592397('0x1b')]['id']}})[_0x592397('0x18')](handleEntityNotFound(_0x5906d3,null))[_0x592397('0x18')](removeEntity(_0x5906d3,null))['catch'](handleError(_0x5906d3,null));}; \ No newline at end of file diff --git a/server/api/voiceQueuesLog/voiceQueuesLog.model.js b/server/api/voiceQueuesLog/voiceQueuesLog.model.js index 747c0f2..4325eb4 100644 --- a/server/api/voiceQueuesLog/voiceQueuesLog.model.js +++ b/server/api/voiceQueuesLog/voiceQueuesLog.model.js @@ -1 +1 @@ -const a768_0x5647=['event','exports','./voiceQueuesLog.attributes','event_dtm'];(function(_0x47c424,_0x5647cd){const _0x15cb7=function(_0x1f7ab5){while(--_0x1f7ab5){_0x47c424['push'](_0x47c424['shift']());}};_0x15cb7(++_0x5647cd);}(a768_0x5647,0x191));const a768_0x15cb=function(_0x47c424,_0x5647cd){_0x47c424=_0x47c424-0x0;let _0x15cb7=a768_0x5647[_0x47c424];return _0x15cb7;};const _0x28ccbc=a768_0x15cb;'use strict';const attributes=require(_0x28ccbc('0x1'));module[_0x28ccbc('0x0')]=function(_0x1f7ab5){const _0x572c8e=_0x28ccbc,_0x1d8cbe=_0x1f7ab5['define']('VoiceQueuesLog',attributes,{'tableName':'voice_queues_log','paranoid':![],'indexes':[{'name':_0x572c8e('0x2'),'fields':[_0x572c8e('0x3'),'dtm']}],'timestamps':![]});return _0x1d8cbe;}; \ No newline at end of file +const a768_0x3878=['voice_queues_log','event_dtm','define','dtm','event','./voiceQueuesLog.attributes','VoiceQueuesLog'];(function(_0x5a5e95,_0x387897){const _0x1857bd=function(_0x50f521){while(--_0x50f521){_0x5a5e95['push'](_0x5a5e95['shift']());}};_0x1857bd(++_0x387897);}(a768_0x3878,0x178));const a768_0x1857=function(_0x5a5e95,_0x387897){_0x5a5e95=_0x5a5e95-0x0;let _0x1857bd=a768_0x3878[_0x5a5e95];return _0x1857bd;};const _0x25bfcf=a768_0x1857;'use strict';const attributes=require(_0x25bfcf('0x0'));module['exports']=function(_0x50f521){const _0x28f937=_0x25bfcf,_0x5c6006=_0x50f521[_0x28f937('0x4')](_0x28f937('0x1'),attributes,{'tableName':_0x28f937('0x2'),'paranoid':![],'indexes':[{'name':_0x28f937('0x3'),'fields':[_0x28f937('0x6'),_0x28f937('0x5')]}],'timestamps':![]});return _0x5c6006;}; \ No newline at end of file diff --git a/server/api/voiceRecording/index.js b/server/api/voiceRecording/index.js index 7bc910a..9b4e01a 100644 --- a/server/api/voiceRecording/index.js +++ b/server/api/voiceRecording/index.js @@ -1 +1 @@ -const a769_0x3c67=['/:id/transcribe','/describe','downloads','runTranscribe','show','get','/:id','index','exports','express','/:id/downloads','describe','put','./voiceRecording.controller','/:id/download','destroy','isAuthenticated','post'];(function(_0x4e9e91,_0x3c67e7){const _0x23a188=function(_0xa9c48b){while(--_0xa9c48b){_0x4e9e91['push'](_0x4e9e91['shift']());}};_0x23a188(++_0x3c67e7);}(a769_0x3c67,0x185));const a769_0x23a1=function(_0x4e9e91,_0x3c67e7){_0x4e9e91=_0x4e9e91-0x0;let _0x23a188=a769_0x3c67[_0x4e9e91];return _0x23a188;};const _0x2c9cf0=a769_0x23a1;'use strict';const express=require(_0x2c9cf0('0x10')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x2c9cf0('0x2'));router[_0x2c9cf0('0xc')]('/',auth[_0x2c9cf0('0x5')](),controller[_0x2c9cf0('0xe')]),router['get'](_0x2c9cf0('0x8'),auth[_0x2c9cf0('0x5')](),controller[_0x2c9cf0('0x0')]),router['get'](_0x2c9cf0('0xd'),auth[_0x2c9cf0('0x5')](),controller[_0x2c9cf0('0xb')]),router[_0x2c9cf0('0xc')](_0x2c9cf0('0x3'),auth[_0x2c9cf0('0x5')](),controller['download']),router[_0x2c9cf0('0xc')](_0x2c9cf0('0x11'),controller[_0x2c9cf0('0x9')]),router[_0x2c9cf0('0xc')](_0x2c9cf0('0x7'),auth['isAuthenticated'](),controller['downloadTranscribe']),router[_0x2c9cf0('0x6')]('/',auth[_0x2c9cf0('0x5')](),controller['create']),router[_0x2c9cf0('0x6')](_0x2c9cf0('0x7'),auth[_0x2c9cf0('0x5')](),controller[_0x2c9cf0('0xa')]),router[_0x2c9cf0('0x1')]('/:id',auth[_0x2c9cf0('0x5')](),controller['update']),router['delete'](_0x2c9cf0('0xd'),auth[_0x2c9cf0('0x5')](),controller[_0x2c9cf0('0x4')]),module[_0x2c9cf0('0xf')]=router; \ No newline at end of file +const a769_0x1dc6=['/:id/download','describe','index','put','isAuthenticated','get','exports','runTranscribe','create','/describe','download','Router','/:id/downloads','/:id/transcribe','show','express','delete','/:id','downloadTranscribe'];(function(_0x4b9f3d,_0x1dc674){const _0x1ba692=function(_0x23631d){while(--_0x23631d){_0x4b9f3d['push'](_0x4b9f3d['shift']());}};_0x1ba692(++_0x1dc674);}(a769_0x1dc6,0x1de));const a769_0x1ba6=function(_0x4b9f3d,_0x1dc674){_0x4b9f3d=_0x4b9f3d-0x0;let _0x1ba692=a769_0x1dc6[_0x4b9f3d];return _0x1ba692;};const _0x25c01e=a769_0x1ba6;'use strict';const express=require(_0x25c01e('0xc')),router=express[_0x25c01e('0x8')](),auth=require('../../components/auth/service'),controller=require('./voiceRecording.controller');router[_0x25c01e('0x2')]('/',auth[_0x25c01e('0x1')](),controller[_0x25c01e('0x12')]),router[_0x25c01e('0x2')](_0x25c01e('0x6'),auth[_0x25c01e('0x1')](),controller[_0x25c01e('0x11')]),router['get'](_0x25c01e('0xe'),auth[_0x25c01e('0x1')](),controller[_0x25c01e('0xb')]),router['get'](_0x25c01e('0x10'),auth[_0x25c01e('0x1')](),controller[_0x25c01e('0x7')]),router['get'](_0x25c01e('0x9'),controller['downloads']),router[_0x25c01e('0x2')](_0x25c01e('0xa'),auth[_0x25c01e('0x1')](),controller[_0x25c01e('0xf')]),router['post']('/',auth['isAuthenticated'](),controller[_0x25c01e('0x5')]),router['post'](_0x25c01e('0xa'),auth[_0x25c01e('0x1')](),controller[_0x25c01e('0x4')]),router[_0x25c01e('0x0')](_0x25c01e('0xe'),auth[_0x25c01e('0x1')](),controller['update']),router[_0x25c01e('0xd')](_0x25c01e('0xe'),auth[_0x25c01e('0x1')](),controller['destroy']),module[_0x25c01e('0x3')]=router; \ No newline at end of file diff --git a/server/api/voiceRecording/voiceRecording.attributes.js b/server/api/voiceRecording/voiceRecording.attributes.js index 7ce9706..7228a40 100644 --- a/server/api/voiceRecording/voiceRecording.attributes.js +++ b/server/api/voiceRecording/voiceRecording.attributes.js @@ -1 +1 @@ -const a770_0x4c03=['FLOAT','extname','membername','createdAt','INTEGER','VIRTUAL','DATE','format','moment','BOOLEAN','TEXT','updatedAt','value','setDataValue','path','getDataValue','exports','split','MM-DD-YYYY\x20HH:mm','toString','sequelize','STRING'];(function(_0x412ce1,_0x4c033c){const _0x2a30e8=function(_0x45bcd0){while(--_0x45bcd0){_0x412ce1['push'](_0x412ce1['shift']());}};_0x2a30e8(++_0x4c033c);}(a770_0x4c03,0x107));const a770_0x2a30=function(_0x412ce1,_0x4c033c){_0x412ce1=_0x412ce1-0x0;let _0x2a30e8=a770_0x4c03[_0x412ce1];return _0x2a30e8;};const _0x4cc800=a770_0x2a30;'use strict';const Sequelize=require(_0x4cc800('0x15')),moment=require(_0x4cc800('0x9')),path=require(_0x4cc800('0xf'));module[_0x4cc800('0x11')]={'format':{'type':Sequelize[_0x4cc800('0x6')],'get':function(){const _0x2c0eda=_0x4cc800;return this['getDataValue'](_0x2c0eda('0xd'))?path[_0x2c0eda('0x2')](this[_0x2c0eda('0x10')](_0x2c0eda('0xd'))):undefined;}},'uniqueid':{'type':Sequelize[_0x4cc800('0x0')]},'channel':{'type':Sequelize['STRING'],'set':function(_0x45bcd0){const _0x57232e=_0x4cc800;_0x45bcd0&&(this[_0x57232e('0xe')]('channel',_0x45bcd0),this['setDataValue'](_0x57232e('0x3'),_0x45bcd0[_0x57232e('0x12')](/\/|-/)[0x1]));}},'membername':{'type':Sequelize['STRING']},'calleridnum':{'type':Sequelize['STRING']},'calleridname':{'type':Sequelize['STRING']},'connectedlinenum':{'type':Sequelize[_0x4cc800('0x0')]},'connectedlinename':{'type':Sequelize[_0x4cc800('0x0')]},'accountcode':{'type':Sequelize['STRING']},'context':{'type':Sequelize[_0x4cc800('0x0')]},'exten':{'type':Sequelize[_0x4cc800('0x0')]},'value':{'type':Sequelize[_0x4cc800('0x0')]},'type':{'type':Sequelize[_0x4cc800('0x0')]},'rating':{'type':Sequelize[_0x4cc800('0x5')],'validate':{'max':0x5,'min':0x0}},'queue':{'type':Sequelize['STRING']},'userDisposition':{'type':Sequelize['STRING']},'userSecondDisposition':{'type':Sequelize['STRING']},'userThirdDisposition':{'type':Sequelize[_0x4cc800('0x0')]},'location':{'type':Sequelize[_0x4cc800('0xb')]},'transcribeName':{'type':Sequelize[_0x4cc800('0x0')]},'transcribeStatus':{'type':Sequelize['STRING'],'defaultValue':'NEW'},'fileUri':{'type':Sequelize[_0x4cc800('0xb')]},'fileText':{'type':Sequelize[_0x4cc800('0xb')]},'failureReason':{'type':Sequelize['TEXT']},'sentiment':{'type':Sequelize['STRING']},'sPositive':{'type':Sequelize[_0x4cc800('0x1')]},'sNegative':{'type':Sequelize[_0x4cc800('0x1')]},'sNeutral':{'type':Sequelize[_0x4cc800('0x1')]},'sMixed':{'type':Sequelize['FLOAT']},'tempSentiment':{'type':Sequelize[_0x4cc800('0xa')],'defaultValue':![]},'createdAt':{'type':Sequelize[_0x4cc800('0x7')],'get':function(){const _0x6938b5=_0x4cc800;return moment(this['getDataValue'](_0x6938b5('0x4')))['format'](_0x6938b5('0x13'))[_0x6938b5('0x14')]();}},'updatedAt':{'type':Sequelize['DATE'],'get':function(){const _0xd74868=_0x4cc800;return moment(this[_0xd74868('0x10')](_0xd74868('0xc')))[_0xd74868('0x8')](_0xd74868('0x13'))[_0xd74868('0x14')]();}}}; \ No newline at end of file +const a770_0x4fc7=['split','MM-DD-YYYY\x20HH:mm','NEW','exports','BOOLEAN','TEXT','FLOAT','DATE','STRING','value','setDataValue','moment','sequelize','membername','createdAt','path','getDataValue','toString','INTEGER','VIRTUAL','format'];(function(_0x4b2e15,_0x4fc72f){const _0x1d833=function(_0x4cb85a){while(--_0x4cb85a){_0x4b2e15['push'](_0x4b2e15['shift']());}};_0x1d833(++_0x4fc72f);}(a770_0x4fc7,0xb2));const a770_0x1d83=function(_0x4b2e15,_0x4fc72f){_0x4b2e15=_0x4b2e15-0x0;let _0x1d833=a770_0x4fc7[_0x4b2e15];return _0x1d833;};const _0x8d20fb=a770_0x1d83;'use strict';const Sequelize=require(_0x8d20fb('0x2')),moment=require(_0x8d20fb('0x1')),path=require(_0x8d20fb('0x5'));module[_0x8d20fb('0xe')]={'format':{'type':Sequelize[_0x8d20fb('0x9')],'get':function(){const _0x595230=_0x8d20fb;return this[_0x595230('0x6')](_0x595230('0x14'))?path['extname'](this[_0x595230('0x6')]('value')):undefined;}},'uniqueid':{'type':Sequelize[_0x8d20fb('0x13')]},'channel':{'type':Sequelize[_0x8d20fb('0x13')],'set':function(_0x4cb85a){const _0x248820=_0x8d20fb;_0x4cb85a&&(this[_0x248820('0x0')]('channel',_0x4cb85a),this[_0x248820('0x0')](_0x248820('0x3'),_0x4cb85a[_0x248820('0xb')](/\/|-/)[0x1]));}},'membername':{'type':Sequelize[_0x8d20fb('0x13')]},'calleridnum':{'type':Sequelize[_0x8d20fb('0x13')]},'calleridname':{'type':Sequelize[_0x8d20fb('0x13')]},'connectedlinenum':{'type':Sequelize[_0x8d20fb('0x13')]},'connectedlinename':{'type':Sequelize[_0x8d20fb('0x13')]},'accountcode':{'type':Sequelize[_0x8d20fb('0x13')]},'context':{'type':Sequelize[_0x8d20fb('0x13')]},'exten':{'type':Sequelize[_0x8d20fb('0x13')]},'value':{'type':Sequelize['STRING']},'type':{'type':Sequelize['STRING']},'rating':{'type':Sequelize[_0x8d20fb('0x8')],'validate':{'max':0x5,'min':0x0}},'queue':{'type':Sequelize[_0x8d20fb('0x13')]},'userDisposition':{'type':Sequelize['STRING']},'userSecondDisposition':{'type':Sequelize[_0x8d20fb('0x13')]},'userThirdDisposition':{'type':Sequelize[_0x8d20fb('0x13')]},'location':{'type':Sequelize[_0x8d20fb('0x10')]},'transcribeName':{'type':Sequelize[_0x8d20fb('0x13')]},'transcribeStatus':{'type':Sequelize[_0x8d20fb('0x13')],'defaultValue':_0x8d20fb('0xd')},'fileUri':{'type':Sequelize[_0x8d20fb('0x10')]},'fileText':{'type':Sequelize[_0x8d20fb('0x10')]},'failureReason':{'type':Sequelize[_0x8d20fb('0x10')]},'sentiment':{'type':Sequelize[_0x8d20fb('0x13')]},'sPositive':{'type':Sequelize[_0x8d20fb('0x11')]},'sNegative':{'type':Sequelize[_0x8d20fb('0x11')]},'sNeutral':{'type':Sequelize[_0x8d20fb('0x11')]},'sMixed':{'type':Sequelize[_0x8d20fb('0x11')]},'tempSentiment':{'type':Sequelize[_0x8d20fb('0xf')],'defaultValue':![]},'createdAt':{'type':Sequelize[_0x8d20fb('0x12')],'get':function(){const _0x18c768=_0x8d20fb;return moment(this[_0x18c768('0x6')](_0x18c768('0x4')))[_0x18c768('0xa')](_0x18c768('0xc'))['toString']();}},'updatedAt':{'type':Sequelize[_0x8d20fb('0x12')],'get':function(){const _0x28998d=_0x8d20fb;return moment(this[_0x28998d('0x6')]('updatedAt'))[_0x28998d('0xa')]('MM-DD-YYYY\x20HH:mm')[_0x28998d('0x7')]();}}}; \ No newline at end of file diff --git a/server/api/voiceRecording/voiceRecording.controller.js b/server/api/voiceRecording/voiceRecording.controller.js index 619b70e..d68892b 100644 --- a/server/api/voiceRecording/voiceRecording.controller.js +++ b/server/api/voiceRecording/voiceRecording.controller.js @@ -1 +1 @@ -const a771_0x5a79=['rows','Cloud\x20Provider\x20not\x20available','runTranscribe','Sentiment\x20Analysis\x20not\x20configured','Transcribe\x20not\x20configured','sentimentAccountId','uniqueid','findOne','count','fields','TranscriptionJobName','IN_PROGRESS','key','TranscriptionJobStatus','listBuckets','../../config/environment','value','update','[RUNTRANSCRIPT][%d]\x20Transcript\x20action\x20already\x20requested','unlinkSync','json','transcribeStatus','sentimentRegion','[RUNTRANSCRIPT][%d]\x20Bucket\x20%s\x20available','and','then','Name','name','Setting','\x22\x20trovato\x20eseguo\x20la\x20cancellazione','File:\x20\x22','intersection','isNil','limit','TranscribeService','secrets','pick','like','sequelize','cancellazione\x20fisica\x20documento\x20%s','$and','.cypher','[RUNTRANSCRIPT][%d]\x20Starting\x20voice\x20recording\x20upload\x20in\x20bucket\x20%s','unlink','NEW','[RUNTRANSCRIPT][%d]\x20Bucket\x20%s\x20not\x20available','api','query','data1','writeFile','existsSync','transcribe','language','attributes','merge','where','aws-sdk','end','/server/files/transcribes/transcribe_','createBucket','basename','map','filter','push','fieldName','../../components/parsers/qs','.txt','path','type','filename','downloads','decryptFile','transcribeAccountId','offset','status','Transcript\x20not\x20available','keys','downloadTranscribe','error','startTranscriptionJob','fileText','Content-Range','undefined','VoiceRecording','../../config/logger','send','Not\x20found','include','includeAll','upload','../../mysqldb','Voice\x20Recording\x20not\x20found','root','[RUNTRANSCRIPT][%d]\x20Voice\x20recording\x20uploaded\x20in\x20bucket\x20%s\x20(%s)','%s.cypher','TranscriptionJob','destroy','params','length','filters','recording','differenceBy','show','Buckets','Location','extname','sendStatus','findAll','runSentiment','body','error-middleware/errors','sort','data2','info','tempSentiment','model','message','find','MD5','format','download','rawAttributes','describe','uuid','VoiceRecording\x20not\x20found','transcribeRegion','[RUNTRANSCRIPT][%d]\x20Sending\x20transcribe\x20request','../../components/encryptor','bucket','CloudProvider','sentiment','token','set','options','catch'];(function(_0x50a5ef,_0x5a79cc){const _0x18a806=function(_0xb6233b){while(--_0xb6233b){_0x50a5ef['push'](_0x50a5ef['shift']());}};_0x18a806(++_0x5a79cc);}(a771_0x5a79,0x106));const a771_0x18a8=function(_0x50a5ef,_0x5a79cc){_0x50a5ef=_0x50a5ef-0x0;let _0x18a806=a771_0x5a79[_0x50a5ef];return _0x18a806;};const _0x2adc94=a771_0x18a8;'use strict';const util=require('util'),path=require(_0x2adc94('0x4b')),fs=require('fs'),_=require('lodash'),AWS=require(_0x2adc94('0x40')),{v4:uuidv4}=require(_0x2adc94('0x83')),qs=require(_0x2adc94('0x49')),logger=require(_0x2adc94('0x5c'))(_0x2adc94('0x36')),config=require(_0x2adc94('0x17')),db=require(_0x2adc94('0x62'))['db'],{Op,fn,col,ValidationError}=require(_0x2adc94('0x2e')),{InternalError}=require(_0x2adc94('0x76'));function respondWithResult(_0xb6233b,_0x598282){return _0x598282=_0x598282||0xc8,function(_0x247883){const _0x141174=a771_0x18a8;if(_0x247883)return _0xb6233b[_0x141174('0x52')](_0x598282)[_0x141174('0x1c')](_0x247883);};}function respondWithFilteredResult(_0x199f08,_0x5b2434){return function(_0x1a22f7){const _0x3fafc8=a771_0x18a8;if(_0x1a22f7){const _0x5add2d=_0x1a22f7[_0x3fafc8('0x10')],_0x1a7ac4=_0x5b2434[_0x3fafc8('0x51')];let _0x4726b4=_0x5b2434[_0x3fafc8('0x51')]+_0x5b2434[_0x3fafc8('0x29')],_0x4fb701;return _0x4726b4>=_0x5add2d?(_0x4726b4=_0x5add2d,_0x4fb701=0xc8):_0x4fb701=0xce,_0x199f08[_0x3fafc8('0x52')](_0x4fb701),_0x199f08[_0x3fafc8('0x5')](_0x3fafc8('0x59'),_0x1a7ac4+'-'+_0x4726b4+'/'+_0x5add2d)['json'](_0x1a22f7);}return null;};}function saveUpdates(_0x1e9bb2){return function(_0x2fe6d2){const _0x1e4b26=a771_0x18a8;if(_0x2fe6d2)return _0x2fe6d2[_0x1e4b26('0x19')](_0x1e9bb2)[_0x1e4b26('0x21')](function(_0x32cabc){return _0x32cabc;});return null;};}function handleEntityNotFound(_0x240c26){return function(_0x16e48a){const _0x4d7657=a771_0x18a8;return!_0x16e48a&&_0x240c26[_0x4d7657('0x72')](0x194),_0x16e48a;};}function handleError(_0x54c7d6,_0x44e968){return _0x44e968=_0x44e968||0x1f4,function(_0x17be38){const _0xcd9ed=a771_0x18a8;logger[_0xcd9ed('0x56')](_0x17be38['stack']),_0x17be38[_0xcd9ed('0x23')]&&delete _0x17be38[_0xcd9ed('0x23')],_0x54c7d6[_0xcd9ed('0x52')](_0x44e968)[_0xcd9ed('0x5d')](_0x17be38);};}exports['index']=function(_0x5fb0ec,_0x4a7b26){const _0x3b8c6f=_0x2adc94;let _0xca96b7={};const _0x269027={},_0x1937e9={'count':0x0,'rows':[]},_0x160e5e=_[_0x3b8c6f('0x45')](db[_0x3b8c6f('0x5b')][_0x3b8c6f('0x81')],function(_0x495bd7){const _0x13dd0d=_0x3b8c6f;return{'name':_0x495bd7[_0x13dd0d('0x48')],'type':_0x495bd7[_0x13dd0d('0x4c')][_0x13dd0d('0x14')]};});_0x269027[_0x3b8c6f('0x7b')]=_[_0x3b8c6f('0x6d')](_[_0x3b8c6f('0x45')](_0x160e5e,_0x3b8c6f('0x23')),[_0x3b8c6f('0x7f')]),_0x269027[_0x3b8c6f('0x37')]=_[_0x3b8c6f('0x54')](_0x5fb0ec[_0x3b8c6f('0x37')]),_0x269027[_0x3b8c6f('0x6b')]=_[_0x3b8c6f('0x27')](_0x269027[_0x3b8c6f('0x7b')],_0x269027['query']),_0xca96b7[_0x3b8c6f('0x3d')]=_[_0x3b8c6f('0x27')](_0x269027[_0x3b8c6f('0x7b')],qs[_0x3b8c6f('0x11')](_0x5fb0ec[_0x3b8c6f('0x37')][_0x3b8c6f('0x11')])),_0xca96b7[_0x3b8c6f('0x3d')]=_0xca96b7[_0x3b8c6f('0x3d')]['length']?_0xca96b7[_0x3b8c6f('0x3d')]:_0x269027['model'];typeof _0x5fb0ec[_0x3b8c6f('0x37')]['nolimit']===_0x3b8c6f('0x5a')&&(_0xca96b7[_0x3b8c6f('0x29')]=qs[_0x3b8c6f('0x29')](_0x5fb0ec[_0x3b8c6f('0x37')]['limit']),_0xca96b7[_0x3b8c6f('0x51')]=qs[_0x3b8c6f('0x51')](_0x5fb0ec[_0x3b8c6f('0x37')][_0x3b8c6f('0x51')]));_0xca96b7['order']=qs[_0x3b8c6f('0x77')](_0x5fb0ec['query'][_0x3b8c6f('0x77')]),_0xca96b7[_0x3b8c6f('0x3f')]=qs[_0x3b8c6f('0x6b')](_[_0x3b8c6f('0x2c')](_0x5fb0ec[_0x3b8c6f('0x37')],_0x269027[_0x3b8c6f('0x6b')]),_0x160e5e);_0x5fb0ec[_0x3b8c6f('0x37')][_0x3b8c6f('0x46')]&&(_0xca96b7[_0x3b8c6f('0x3f')]=_['merge'](_0xca96b7['where'],{[Op['or']]:_[_0x3b8c6f('0x45')](_0x160e5e,function(_0x2a4bbf){const _0x3909cc=_0x3b8c6f;if(_0x2a4bbf[_0x3909cc('0x4c')]!=='VIRTUAL'){const _0x453748={};return _0x453748[_0x2a4bbf[_0x3909cc('0x23')]]={[Op[_0x3909cc('0x2d')]]:'%'+_0x5fb0ec[_0x3909cc('0x37')][_0x3909cc('0x46')]+'%'},_0x453748;}})}));_0xca96b7=_[_0x3b8c6f('0x3e')]({},_0xca96b7,_0x5fb0ec[_0x3b8c6f('0x6')]);const _0x6677fd={'where':_0xca96b7[_0x3b8c6f('0x3f')]};return db[_0x3b8c6f('0x5b')][_0x3b8c6f('0x10')](_0x6677fd)[_0x3b8c6f('0x21')](function(_0x1cd8b4){const _0x3d550f=_0x3b8c6f;return _0x1937e9[_0x3d550f('0x10')]=_0x1cd8b4,_0x5fb0ec[_0x3d550f('0x37')]['includeAll']&&(_0xca96b7[_0x3d550f('0x5f')]=[{'all':!![]}]),db[_0x3d550f('0x5b')][_0x3d550f('0x73')](_0xca96b7);})['then'](function(_0x451bd7){const _0x1d4691=_0x3b8c6f;return _0x1937e9[_0x1d4691('0x8')]=_0x451bd7,_0x1937e9;})['then'](respondWithFilteredResult(_0x4a7b26,_0xca96b7))[_0x3b8c6f('0x7')](handleError(_0x4a7b26,null));},exports[_0x2adc94('0x6e')]=function(_0x4a6129,_0x300b36){const _0x453d17=_0x2adc94;let _0x56cafb={'raw':![],'where':{'id':_0x4a6129[_0x453d17('0x69')]['id']}};const _0x389826={};return _0x389826[_0x453d17('0x7b')]=_[_0x453d17('0x54')](db['VoiceRecording'][_0x453d17('0x81')]),_0x389826[_0x453d17('0x37')]=_[_0x453d17('0x54')](_0x4a6129[_0x453d17('0x37')]),_0x389826['filters']=_['intersection'](_0x389826[_0x453d17('0x7b')],_0x389826[_0x453d17('0x37')]),_0x56cafb[_0x453d17('0x3d')]=_['intersection'](_0x389826[_0x453d17('0x7b')],qs['fields'](_0x4a6129['query'][_0x453d17('0x11')])),_0x56cafb[_0x453d17('0x3d')]=_0x56cafb[_0x453d17('0x3d')][_0x453d17('0x6a')]?_0x56cafb[_0x453d17('0x3d')]:_0x389826[_0x453d17('0x7b')],_0x4a6129['query'][_0x453d17('0x60')]&&(_0x56cafb['include']=[{'all':!![]}]),_0x56cafb=_[_0x453d17('0x3e')]({},_0x56cafb,_0x4a6129['options']),db[_0x453d17('0x5b')][_0x453d17('0xf')](_0x56cafb)[_0x453d17('0x21')](handleEntityNotFound(_0x300b36,null))[_0x453d17('0x21')](respondWithResult(_0x300b36,null))[_0x453d17('0x7')](handleError(_0x300b36,null));},exports['create']=function(_0x540e9a,_0x5c2500){const _0x28143c=_0x2adc94;return db['VoiceRecording']['create'](_0x540e9a[_0x28143c('0x75')],{})[_0x28143c('0x21')](respondWithResult(_0x5c2500,0xc9))[_0x28143c('0x7')](handleError(_0x5c2500,null));},exports[_0x2adc94('0x19')]=function(_0x25c144,_0x251ae0){const _0x21fbca=_0x2adc94;return _0x25c144[_0x21fbca('0x75')]['id']&&delete _0x25c144['body']['id'],db[_0x21fbca('0x5b')][_0x21fbca('0xf')]({'where':{'id':_0x25c144['params']['id']}})[_0x21fbca('0x21')](handleEntityNotFound(_0x251ae0,null))['then'](saveUpdates(_0x25c144[_0x21fbca('0x75')],null))[_0x21fbca('0x21')](respondWithResult(_0x251ae0,null))['catch'](handleError(_0x251ae0,null));},exports[_0x2adc94('0x82')]=function(_0x549439,_0x4f141e){const _0x3b61a0=_0x2adc94;return db['VoiceRecording'][_0x3b61a0('0x82')]()[_0x3b61a0('0x21')](respondWithResult(_0x4f141e,null))[_0x3b61a0('0x7')](handleError(_0x4f141e,null));},exports[_0x2adc94('0x80')]=function(_0xf21ed8,_0x229a91){const _0x977398=_0x2adc94,_0x36721b=require('../../components/encryptor');let _0x3b190b=![];const _0x272351={};return _0xf21ed8[_0x977398('0x37')][_0x977398('0x4c')]&&_0xf21ed8[_0x977398('0x37')][_0x977398('0x4c')]==='uniqueid'?_0x272351[_0x977398('0xe')]=_0xf21ed8[_0x977398('0x69')]['id']:_0x272351['id']=_0xf21ed8[_0x977398('0x69')]['id'],db[_0x977398('0x5b')]['findOne']({'where':_0x272351,'attributes':['id',_0x977398('0x18')],'raw':!![]})['then'](handleEntityNotFound(_0x229a91,null))[_0x977398('0x21')](function(_0x85a31f){const _0x59fd73=_0x977398;if(_0x85a31f){const _0x3fcdf9=_0x85a31f[_0x59fd73('0x18')],_0x3ee639=util[_0x59fd73('0x7f')]('%s.cypher',_0x3fcdf9);if(fs[_0x59fd73('0x3a')](_0x3ee639))return _0x3b190b=!![],_0x36721b[_0x59fd73('0x4f')](_0x3ee639,_0x3fcdf9,config['secrets'][_0x59fd73('0x6c')])[_0x59fd73('0x21')](function(){return _0x85a31f;});return _0x85a31f;}})[_0x977398('0x21')](function(_0x511430){const _0x402c9b=_0x977398;if(_0x511430){const _0x41a8fa=_0x511430['value'];if(!fs[_0x402c9b('0x3a')](_0x41a8fa))throw new ValidationError(_0x402c9b('0x84'));return _0x511430[_0x402c9b('0x4d')]?_0x229a91[_0x402c9b('0x80')](_0x41a8fa,_0x511430['filename']+path[_0x402c9b('0x71')](_0x41a8fa),function(){const _0x54babc=_0x402c9b;_0x3b190b&&fs[_0x54babc('0x33')](_0x41a8fa);}):_0x229a91[_0x402c9b('0x80')](_0x41a8fa,function(){_0x3b190b&&fs['unlink'](_0x41a8fa);});}})['catch'](function(_0x2f8602){const _0x1d324c=_0x977398;if(_0x2f8602[_0x1d324c('0x7c')]==='VoiceRecording\x20not\x20found')_0x229a91['status'](0x194)[_0x1d324c('0x5d')](_0x1d324c('0x5e'));else return handleError(_0x229a91,null);});},exports[_0x2adc94('0x4e')]=function(_0x3eb6b6,_0x44023e){const _0x3f5741=_0x2adc94,_0x408e86=require(_0x3f5741('0x0'));let _0x12c98d=![];const _0x536806={[Op[_0x3f5741('0x20')]]:[_0x536806(fn(_0x3f5741('0x7e'),col(_0x3f5741('0xe'))),_0x3eb6b6[_0x3f5741('0x37')][_0x3f5741('0x4')])]};return _0x3eb6b6[_0x3f5741('0x37')][_0x3f5741('0x4c')]&&_0x3eb6b6[_0x3f5741('0x37')]['type']===_0x3f5741('0xe')?_0x536806[_0x3f5741('0x30')]['push']({'uniqueid':_0x3eb6b6['params']['id']}):_0x536806[_0x3f5741('0x30')][_0x3f5741('0x47')]({'id':_0x3eb6b6['params']['id']}),db[_0x3f5741('0x5b')]['findOne']({'where':_0x536806,'attributes':['id','value'],'raw':!![]})[_0x3f5741('0x21')](handleEntityNotFound(_0x44023e,null))[_0x3f5741('0x21')](function(_0x3d188a){const _0x1be381=_0x3f5741;if(_0x3d188a){const _0x407e6d=util['format'](_0x1be381('0x66'),_0x3d188a[_0x1be381('0x18')]);if(fs['existsSync'](_0x407e6d))return _0x12c98d=!![],_0x408e86[_0x1be381('0x4f')](_0x407e6d,_0x3d188a['value'],config[_0x1be381('0x2b')][_0x1be381('0x6c')])[_0x1be381('0x21')](function(){return _0x3d188a;});return _0x3d188a;}})[_0x3f5741('0x21')](function(_0x2c666b){const _0x1fb813=_0x3f5741;if(_0x2c666b){if(!fs[_0x1fb813('0x3a')](_0x2c666b['value']))throw new ValidationError('VoiceRecording\x20not\x20found');return _0x2c666b[_0x1fb813('0x4d')]?_0x44023e['download'](_0x2c666b[_0x1fb813('0x18')],_0x2c666b[_0x1fb813('0x4d')]+path['extname'](_0x2c666b[_0x1fb813('0x18')]),function(){const _0x583637=_0x1fb813;_0x12c98d&&fs[_0x583637('0x33')](_0x2c666b[_0x583637('0x18')]);}):_0x44023e[_0x1fb813('0x80')](_0x2c666b['value'],function(){const _0x3c9d0d=_0x1fb813;_0x12c98d&&fs[_0x3c9d0d('0x33')](_0x2c666b[_0x3c9d0d('0x18')]);});}})['catch'](handleError(_0x44023e,null));},exports[_0x2adc94('0x68')]=function(_0x3281e1,_0x2edc91){const _0x1fd1aa=_0x2adc94;return db['VoiceRecording']['findOne']({'where':{'id':_0x3281e1[_0x1fd1aa('0x69')]['id']}})['then'](function(_0x2f87a3){if(!_0x2f87a3)throw new ReferenceError('Entity\x20not\x20found');return _0x2f87a3;})[_0x1fd1aa('0x21')](function(_0x1e44d4){const _0x5a19eb=_0x1fd1aa;let _0x32e74e=_0x1e44d4[_0x5a19eb('0x18')];return logger[_0x5a19eb('0x79')](_0x5a19eb('0x2f'),_0x32e74e),!_[_0x5a19eb('0x28')](_0x1e44d4[_0x5a19eb('0x18')])&&fs[_0x5a19eb('0x3a')](_0x32e74e)&&(logger[_0x5a19eb('0x79')](_0x5a19eb('0x26')+_0x32e74e+_0x5a19eb('0x25')),fs[_0x5a19eb('0x1b')](_0x32e74e)),_0x32e74e=_0x32e74e+_0x5a19eb('0x31'),!_[_0x5a19eb('0x28')](_0x1e44d4['value'])&&fs[_0x5a19eb('0x3a')](_0x32e74e)&&(logger[_0x5a19eb('0x79')](_0x5a19eb('0x26')+_0x32e74e+'\x22\x20trovato\x20eseguo\x20la\x20cancellazione'),fs[_0x5a19eb('0x1b')](_0x32e74e)),_0x1e44d4;})[_0x1fd1aa('0x21')](function(_0x3d1229){if(!_0x3d1229)throw new InternalError();return _0x3d1229['destroy']();})[_0x1fd1aa('0x21')](function(){const _0x2e7afe=_0x1fd1aa;_0x2edc91[_0x2e7afe('0x52')](0xcc)[_0x2e7afe('0x41')]();})['catch'](handleError(_0x2edc91,null));};function getBucketslist(_0x15f6d4,_0x36acad,_0x368470){return new Promise(function(_0xc7bf4e,_0x48e12a){const _0x2ddf4a=a771_0x18a8,_0x221d7e=new AWS['S3']({'accessKeyId':_0x36acad,'secretAccessKey':_0x15f6d4,'region':_0x368470});_0x221d7e[_0x2ddf4a('0x16')]({},function(_0x5f0fd4,_0x47c3c3){return _0x5f0fd4?_0x48e12a(_0x5f0fd4):_0xc7bf4e(_0x47c3c3);});});}function createBucket(_0x6861c5,_0x42db95,_0x29cf20,_0x52c746){return new Promise(function(_0x3eb656,_0x4d5a36){const _0x5df473=a771_0x18a8,_0x3459e5=new AWS['S3']({'accessKeyId':_0x42db95,'secretAccessKey':_0x6861c5,'region':_0x29cf20});_0x3459e5[_0x5df473('0x43')]({'Bucket':_0x52c746},function(_0x434607,_0x5a8a46){return _0x434607?_0x4d5a36(_0x434607):_0x3eb656(_0x5a8a46);});});}function uploadFile(_0x58b767,_0x2f4c59,_0x1fd17d,_0xbb3b80,_0x1f44f6,_0x3cf293){return new Promise(function(_0x3efb55,_0xef6d60){const _0x55b1fa=a771_0x18a8,_0x4b7284=new AWS['S3']({'accessKeyId':_0x2f4c59,'secretAccessKey':_0x58b767,'region':_0x1fd17d});_0x4b7284[_0x55b1fa('0x61')]({'Bucket':_0xbb3b80,'Key':_0x1f44f6,'Body':_0x3cf293},function(_0xb320c6,_0x2f5c1a){return _0xb320c6?_0xef6d60(_0xb320c6):_0x3efb55(_0x2f5c1a);});});}function startTranscribe(_0x4dfb2c,_0x408bce,_0x3de5b9,_0x599f7c,_0x451e3b,_0x4f0e7b){return new Promise(function(_0x244300,_0xd74072){const _0x1390d3=a771_0x18a8,_0x8c31fa=new AWS[(_0x1390d3('0x2a'))]({'accessKeyId':_0x408bce,'secretAccessKey':_0x4dfb2c,'region':_0x3de5b9});_0x8c31fa[_0x1390d3('0x57')]({'TranscriptionJobName':_0x599f7c,'LanguageCode':_0x451e3b,'Media':{'MediaFileUri':_0x4f0e7b}},function(_0x26b3d9,_0x59dbce){return _0x26b3d9?_0xd74072(_0x26b3d9):_0x244300(_0x59dbce);});});}function transcribe(_0x541fc8,_0x392586,_0x27b0b1,_0x3369b7,_0x8eca44,_0x24a037,_0x2a76ec){return new Promise(function(_0x501e7b,_0x28dfd6){const _0x5a6b53=a771_0x18a8,_0x58c75e={};return logger[_0x5a6b53('0x79')](util[_0x5a6b53('0x7f')](_0x5a6b53('0x32'),_0x541fc8,_0x8eca44)),uploadFile(_0x392586,_0x27b0b1,_0x3369b7,_0x8eca44,path[_0x5a6b53('0x44')](_0x24a037),fs['readFileSync'](_0x24a037))['then'](function(_0x17fb0b){const _0x46d7d8=_0x5a6b53;return logger['info'](util[_0x46d7d8('0x7f')](_0x46d7d8('0x65'),_0x541fc8,_0x8eca44,_0x17fb0b[_0x46d7d8('0x70')])),_0x58c75e[_0x46d7d8('0x1')]=_0x17fb0b['Bucket'],_0x58c75e['location']=_0x17fb0b[_0x46d7d8('0x70')],logger[_0x46d7d8('0x79')](util[_0x46d7d8('0x7f')](_0x46d7d8('0x86'),_0x541fc8)),startTranscribe(_0x392586,_0x27b0b1,_0x3369b7,uuidv4(),_0x2a76ec,_0x17fb0b[_0x46d7d8('0x70')]);})[_0x5a6b53('0x21')](function(_0x2c8d0e){const _0x5464b2=_0x5a6b53;return logger[_0x5464b2('0x79')](util[_0x5464b2('0x7f')]('[RUNTRANSCRIPT][%d]\x20Transcription\x20job\x20%s\x20created',_0x541fc8,_0x2c8d0e[_0x5464b2('0x67')]['TranscriptionJobName'])),_0x58c75e['transcribeName']=_0x2c8d0e['TranscriptionJob'][_0x5464b2('0x12')],_0x58c75e[_0x5464b2('0x1d')]=_0x2c8d0e[_0x5464b2('0x67')][_0x5464b2('0x15')],_0x501e7b(_0x58c75e);})[_0x5a6b53('0x7')](function(_0x3fa415){return _0x28dfd6(_0x3fa415);});});}exports[_0x2adc94('0xa')]=function(_0x1320b5,_0x24790a){const _0x735568=_0x2adc94;let _0x212249,_0x21cf30,_0x233510;const _0x26033d=require(_0x735568('0x0'));return db[_0x735568('0x5b')][_0x735568('0xf')]({'where':{'id':_0x1320b5['params']['id']}})['then'](function(_0x14c425){const _0x5851cb=_0x735568;if(_0x14c425){const _0x20c8a8=util[_0x5851cb('0x7f')](_0x5851cb('0x66'),_0x14c425[_0x5851cb('0x18')]);if(fs[_0x5851cb('0x3a')](_0x20c8a8))return _0x26033d['decryptFile'](_0x20c8a8,_0x14c425[_0x5851cb('0x18')],config[_0x5851cb('0x2b')][_0x5851cb('0x6c')])['then'](function(){return _0x14c425;});return _0x14c425;}})[_0x735568('0x21')](function(_0x2c8653){const _0xb4aca7=_0x735568;if(!_0x2c8653)throw new ValidationError(_0xb4aca7('0x63'));return _0x21cf30=_0x2c8653,db[_0xb4aca7('0x24')][_0xb4aca7('0xf')]({'where':{'id':0x1}});})[_0x735568('0x21')](handleEntityNotFound(_0x24790a,null))[_0x735568('0x21')](function(_0x41c78c){const _0x3aec8b=_0x735568;if(_0x41c78c){_0x212249=_0x41c78c;if(!_0x212249[_0x3aec8b('0x3b')]||!_0x212249[_0x3aec8b('0x50')]||!_0x212249[_0x3aec8b('0x85')]||!_0x212249[_0x3aec8b('0x3c')]||!_0x212249[_0x3aec8b('0x1')])throw new ValidationError(_0x3aec8b('0xc'));if(_0x1320b5[_0x3aec8b('0x75')][_0x3aec8b('0x74')]&&(!_0x212249[_0x3aec8b('0x3')]||!_0x212249[_0x3aec8b('0xd')]||!_0x212249[_0x3aec8b('0x1e')]||!_0x212249[_0x3aec8b('0x3c')]||!_0x212249[_0x3aec8b('0x1')]))throw new ValidationError(_0x3aec8b('0xb'));return db[_0x3aec8b('0x2')]['findOne']({'where':{'id':_0x212249[_0x3aec8b('0x50')]}});}})[_0x735568('0x21')](function(_0x35bad2){const _0x56402c=_0x735568;if(!_0x35bad2)throw new ValidationError(_0x56402c('0x9'));if(!_0x35bad2[_0x56402c('0x38')]||!_0x35bad2[_0x56402c('0x78')])throw new ValidationError('Cloud\x20Provider\x20not\x20configured');return _0x233510=_0x35bad2,getBucketslist(_0x233510['data1'],_0x233510[_0x56402c('0x78')],_0x212249['transcribeRegion']);})['then'](function(_0x341749){const _0x357413=_0x735568;if(_0x341749&&_0x341749[_0x357413('0x6f')]){const _0x45d9df=_[_0x357413('0x7d')](_0x341749[_0x357413('0x6f')],function(_0x1ae529){const _0xb4c3d5=_0x357413;return _0x1ae529[_0xb4c3d5('0x22')]===_0x212249[_0xb4c3d5('0x1')];});if(!_0x45d9df)return logger[_0x357413('0x79')](util[_0x357413('0x7f')](_0x357413('0x35'),_0x1320b5[_0x357413('0x69')]['id'],_0x212249[_0x357413('0x1')])),createBucket(_0x233510['data1'],_0x233510['data2'],_0x212249[_0x357413('0x85')],_0x212249[_0x357413('0x1')]);logger[_0x357413('0x79')](util[_0x357413('0x7f')](_0x357413('0x1f'),_0x1320b5[_0x357413('0x69')]['id'],_0x212249[_0x357413('0x1')]));return;}})[_0x735568('0x21')](function(){const _0x1d6b7f=_0x735568;return _0x21cf30['transcribeStatus']===_0x1d6b7f('0x34')?transcribe(_0x1320b5[_0x1d6b7f('0x69')]['id'],_0x233510[_0x1d6b7f('0x38')],_0x233510['data2'],_0x212249[_0x1d6b7f('0x85')],_0x212249['bucket'],_0x21cf30[_0x1d6b7f('0x18')],_0x212249[_0x1d6b7f('0x3c')]):(logger[_0x1d6b7f('0x79')](util[_0x1d6b7f('0x7f')](_0x1d6b7f('0x1a'),_0x1320b5[_0x1d6b7f('0x69')]['id'])),{'transcribeStatus':_0x1d6b7f('0x13')});})[_0x735568('0x21')](function(_0xffe56e){const _0x2a263e=_0x735568;if(_0xffe56e)return _0xffe56e[_0x2a263e('0x7a')]=_0x1320b5['body'][_0x2a263e('0x74')],_0x21cf30['update'](_0xffe56e);})[_0x735568('0x21')](respondWithResult(_0x24790a,null))[_0x735568('0x7')](handleError(_0x24790a,null));};function writeFile(_0x5051e1,_0x31102f){return new Promise(function(_0x36abfc,_0x20bfd9){const _0x5a45e9=a771_0x18a8;fs[_0x5a45e9('0x39')](_0x31102f,_0x5051e1,function(_0x52628f,_0x1ca7ff){return _0x52628f?_0x20bfd9(_0x52628f):_0x36abfc(_0x1ca7ff);});});}exports[_0x2adc94('0x55')]=function(_0x419053,_0x42135e){const _0x42dbc2=_0x2adc94;return db[_0x42dbc2('0x5b')]['findOne']({'where':{'id':_0x419053[_0x42dbc2('0x69')]['id']}})[_0x42dbc2('0x21')](handleEntityNotFound(_0x42135e))[_0x42dbc2('0x21')](function(_0x4f8df9){const _0x3e1c26=_0x42dbc2;if(_0x4f8df9&&_0x4f8df9[_0x3e1c26('0x58')]){const _0x18d2d6=_0x4f8df9['fileText'],_0x1639ce=config[_0x3e1c26('0x64')]+_0x3e1c26('0x42')+_0x4f8df9['id']+_0x3e1c26('0x4a');if(fs[_0x3e1c26('0x3a')](_0x1639ce))return _0x1639ce;return writeFile(_0x18d2d6,_0x1639ce)[_0x3e1c26('0x21')](function(){return _0x1639ce;});}else throw new ValidationError(_0x3e1c26('0x53'));})['then'](function(_0x500b18){const _0x2d892c=_0x42dbc2;return _0x42135e[_0x2d892c('0x80')](_0x500b18);})[_0x42dbc2('0x7')](handleError(_0x42135e));}; \ No newline at end of file +const a771_0x2bdd=['%s.cypher','[RUNTRANSCRIPT][%d]\x20Bucket\x20%s\x20not\x20available','decryptFile','../../config/logger','VoiceRecording','sendStatus','set','length','transcribeRegion','create','describe','sequelize','fileText','end','language','rows','filter','TranscriptionJobStatus','Transcript\x20not\x20available','transcribeAccountId','value','where','key','transcribeStatus','VoiceRecording\x20not\x20found','runSentiment','nolimit','TranscriptionJob','filename','readFileSync','[RUNTRANSCRIPT][%d]\x20Bucket\x20%s\x20available','[RUNTRANSCRIPT][%d]\x20Starting\x20voice\x20recording\x20upload\x20in\x20bucket\x20%s','runTranscribe','$and','.cypher','../../mysqldb','status','destroy','model','VIRTUAL','includeAll','api','existsSync','filters','keys','fields','message','basename','info','extname','body','[RUNTRANSCRIPT][%d]\x20Transcription\x20job\x20%s\x20created','Not\x20found','lodash','unlinkSync','cancellazione\x20fisica\x20documento\x20%s','[RUNTRANSCRIPT][%d]\x20Sending\x20transcribe\x20request','util','bucket','push','writeFile','count','NEW','query','sort','Buckets','path','then','sentimentRegion','findOne','rawAttributes','Content-Range','Transcribe\x20not\x20configured','limit','format','send','data1','downloads','fieldName','IN_PROGRESS','uuid','Name','transcribe','Location','Entity\x20not\x20found','downloadTranscribe','json','find','../../components/parsers/qs','update','merge','transcribeName','../../config/environment','findAll','token','stack','Cloud\x20Provider\x20not\x20available','../../components/encryptor','include','map','error','root','.txt','secrets','and','Setting','options','order','name','Bucket','uniqueid','catch','[RUNTRANSCRIPT][%d]\x20Voice\x20recording\x20uploaded\x20in\x20bucket\x20%s\x20(%s)','\x22\x20trovato\x20eseguo\x20la\x20cancellazione','offset','listBuckets','TranscribeService','upload','createBucket','isNil','params','type','download','differenceBy','intersection','unlink','recording','TranscriptionJobName','error-middleware/errors','data2','attributes'];(function(_0x1f0a95,_0x2bdd02){const _0x3ba963=function(_0x35af69){while(--_0x35af69){_0x1f0a95['push'](_0x1f0a95['shift']());}};_0x3ba963(++_0x2bdd02);}(a771_0x2bdd,0x175));const a771_0x3ba9=function(_0x1f0a95,_0x2bdd02){_0x1f0a95=_0x1f0a95-0x0;let _0x3ba963=a771_0x2bdd[_0x1f0a95];return _0x3ba963;};const _0x4bb842=a771_0x3ba9;'use strict';const util=require(_0x4bb842('0x4d')),path=require(_0x4bb842('0x56')),fs=require('fs'),_=require(_0x4bb842('0x49')),AWS=require('aws-sdk'),{v4:uuidv4}=require(_0x4bb842('0x64')),qs=require(_0x4bb842('0x6c')),logger=require(_0x4bb842('0x17'))(_0x4bb842('0x3d')),config=require(_0x4bb842('0x70')),db=require(_0x4bb842('0x37'))['db'],{Op,fn,col,ValidationError}=require(_0x4bb842('0x1f')),{InternalError}=require(_0x4bb842('0x11'));function respondWithResult(_0x35af69,_0x176e29){return _0x176e29=_0x176e29||0xc8,function(_0xef7441){const _0xe45f17=a771_0x3ba9;if(_0xef7441)return _0x35af69[_0xe45f17('0x38')](_0x176e29)[_0xe45f17('0x6a')](_0xef7441);};}function respondWithFilteredResult(_0x16096c,_0x57f29d){return function(_0x5a676e){const _0x17f295=a771_0x3ba9;if(_0x5a676e){const _0x37e938=_0x5a676e[_0x17f295('0x51')],_0x485501=_0x57f29d[_0x17f295('0x3')];let _0x1a8dbf=_0x57f29d['offset']+_0x57f29d[_0x17f295('0x5d')],_0x4752ee;return _0x1a8dbf>=_0x37e938?(_0x1a8dbf=_0x37e938,_0x4752ee=0xc8):_0x4752ee=0xce,_0x16096c['status'](_0x4752ee),_0x16096c[_0x17f295('0x1a')](_0x17f295('0x5b'),_0x485501+'-'+_0x1a8dbf+'/'+_0x37e938)[_0x17f295('0x6a')](_0x5a676e);}return null;};}function saveUpdates(_0x4512ec){return function(_0x53914c){const _0x2f56a9=a771_0x3ba9;if(_0x53914c)return _0x53914c['update'](_0x4512ec)[_0x2f56a9('0x57')](function(_0xf5ad6f){return _0xf5ad6f;});return null;};}function handleEntityNotFound(_0xcae067){return function(_0x4c0a65){const _0x22786a=a771_0x3ba9;return!_0x4c0a65&&_0xcae067[_0x22786a('0x19')](0x194),_0x4c0a65;};}function handleError(_0x423a88,_0x40cd7b){return _0x40cd7b=_0x40cd7b||0x1f4,function(_0x4da98c){const _0x4111d0=a771_0x3ba9;logger[_0x4111d0('0x78')](_0x4da98c[_0x4111d0('0x73')]),_0x4da98c[_0x4111d0('0x80')]&&delete _0x4da98c[_0x4111d0('0x80')],_0x423a88[_0x4111d0('0x38')](_0x40cd7b)[_0x4111d0('0x5f')](_0x4da98c);};}exports['index']=function(_0xa44d4c,_0x4928b3){const _0x11d533=_0x4bb842;let _0x4daf67={};const _0x4f2901={},_0x3e2359={'count':0x0,'rows':[]},_0x5b7a8a=_['map'](db[_0x11d533('0x18')][_0x11d533('0x5a')],function(_0x5a4c76){const _0x5abda7=_0x11d533;return{'name':_0x5a4c76[_0x5abda7('0x62')],'type':_0x5a4c76[_0x5abda7('0xa')][_0x5abda7('0x2a')]};});_0x4f2901['model']=_[_0x11d533('0xc')](_[_0x11d533('0x77')](_0x5b7a8a,_0x11d533('0x80')),[_0x11d533('0x5e')]),_0x4f2901['query']=_['keys'](_0xa44d4c[_0x11d533('0x53')]),_0x4f2901[_0x11d533('0x3f')]=_['intersection'](_0x4f2901['model'],_0x4f2901[_0x11d533('0x53')]),_0x4daf67['attributes']=_[_0x11d533('0xd')](_0x4f2901[_0x11d533('0x3a')],qs[_0x11d533('0x41')](_0xa44d4c[_0x11d533('0x53')]['fields'])),_0x4daf67[_0x11d533('0x13')]=_0x4daf67[_0x11d533('0x13')][_0x11d533('0x1b')]?_0x4daf67[_0x11d533('0x13')]:_0x4f2901[_0x11d533('0x3a')];typeof _0xa44d4c[_0x11d533('0x53')][_0x11d533('0x2e')]==='undefined'&&(_0x4daf67[_0x11d533('0x5d')]=qs[_0x11d533('0x5d')](_0xa44d4c[_0x11d533('0x53')]['limit']),_0x4daf67['offset']=qs[_0x11d533('0x3')](_0xa44d4c[_0x11d533('0x53')][_0x11d533('0x3')]));_0x4daf67[_0x11d533('0x7f')]=qs[_0x11d533('0x54')](_0xa44d4c[_0x11d533('0x53')][_0x11d533('0x54')]),_0x4daf67[_0x11d533('0x29')]=qs[_0x11d533('0x3f')](_['pick'](_0xa44d4c[_0x11d533('0x53')],_0x4f2901['filters']),_0x5b7a8a);_0xa44d4c[_0x11d533('0x53')][_0x11d533('0x24')]&&(_0x4daf67[_0x11d533('0x29')]=_[_0x11d533('0x6e')](_0x4daf67[_0x11d533('0x29')],{[Op['or']]:_[_0x11d533('0x77')](_0x5b7a8a,function(_0xe6a9ab){const _0x5c6090=_0x11d533;if(_0xe6a9ab[_0x5c6090('0xa')]!==_0x5c6090('0x3b')){const _0x2d36e8={};return _0x2d36e8[_0xe6a9ab[_0x5c6090('0x80')]]={[Op['like']]:'%'+_0xa44d4c[_0x5c6090('0x53')][_0x5c6090('0x24')]+'%'},_0x2d36e8;}})}));_0x4daf67=_[_0x11d533('0x6e')]({},_0x4daf67,_0xa44d4c[_0x11d533('0x7e')]);const _0x50a469={'where':_0x4daf67[_0x11d533('0x29')]};return db[_0x11d533('0x18')][_0x11d533('0x51')](_0x50a469)[_0x11d533('0x57')](function(_0x47100){const _0x2f7a43=_0x11d533;return _0x3e2359[_0x2f7a43('0x51')]=_0x47100,_0xa44d4c[_0x2f7a43('0x53')][_0x2f7a43('0x3c')]&&(_0x4daf67[_0x2f7a43('0x76')]=[{'all':!![]}]),db['VoiceRecording'][_0x2f7a43('0x71')](_0x4daf67);})[_0x11d533('0x57')](function(_0x41c076){const _0x50d5c4=_0x11d533;return _0x3e2359[_0x50d5c4('0x23')]=_0x41c076,_0x3e2359;})[_0x11d533('0x57')](respondWithFilteredResult(_0x4928b3,_0x4daf67))[_0x11d533('0x0')](handleError(_0x4928b3,null));},exports['show']=function(_0x1ebeb5,_0x557c3f){const _0x3dc2dd=_0x4bb842;let _0x2c300c={'raw':![],'where':{'id':_0x1ebeb5[_0x3dc2dd('0x9')]['id']}};const _0xa5c400={};return _0xa5c400['model']=_[_0x3dc2dd('0x40')](db[_0x3dc2dd('0x18')][_0x3dc2dd('0x5a')]),_0xa5c400['query']=_[_0x3dc2dd('0x40')](_0x1ebeb5[_0x3dc2dd('0x53')]),_0xa5c400[_0x3dc2dd('0x3f')]=_[_0x3dc2dd('0xd')](_0xa5c400[_0x3dc2dd('0x3a')],_0xa5c400[_0x3dc2dd('0x53')]),_0x2c300c[_0x3dc2dd('0x13')]=_[_0x3dc2dd('0xd')](_0xa5c400[_0x3dc2dd('0x3a')],qs[_0x3dc2dd('0x41')](_0x1ebeb5[_0x3dc2dd('0x53')][_0x3dc2dd('0x41')])),_0x2c300c['attributes']=_0x2c300c[_0x3dc2dd('0x13')][_0x3dc2dd('0x1b')]?_0x2c300c[_0x3dc2dd('0x13')]:_0xa5c400[_0x3dc2dd('0x3a')],_0x1ebeb5[_0x3dc2dd('0x53')][_0x3dc2dd('0x3c')]&&(_0x2c300c[_0x3dc2dd('0x76')]=[{'all':!![]}]),_0x2c300c=_[_0x3dc2dd('0x6e')]({},_0x2c300c,_0x1ebeb5[_0x3dc2dd('0x7e')]),db[_0x3dc2dd('0x18')]['findOne'](_0x2c300c)[_0x3dc2dd('0x57')](handleEntityNotFound(_0x557c3f,null))[_0x3dc2dd('0x57')](respondWithResult(_0x557c3f,null))[_0x3dc2dd('0x0')](handleError(_0x557c3f,null));},exports[_0x4bb842('0x1d')]=function(_0x1f2094,_0x3ad9ba){const _0x5eb30f=_0x4bb842;return db[_0x5eb30f('0x18')]['create'](_0x1f2094[_0x5eb30f('0x46')],{})['then'](respondWithResult(_0x3ad9ba,0xc9))[_0x5eb30f('0x0')](handleError(_0x3ad9ba,null));},exports['update']=function(_0x4703f4,_0x1d7626){const _0x503d67=_0x4bb842;return _0x4703f4[_0x503d67('0x46')]['id']&&delete _0x4703f4[_0x503d67('0x46')]['id'],db[_0x503d67('0x18')][_0x503d67('0x59')]({'where':{'id':_0x4703f4[_0x503d67('0x9')]['id']}})[_0x503d67('0x57')](handleEntityNotFound(_0x1d7626,null))[_0x503d67('0x57')](saveUpdates(_0x4703f4[_0x503d67('0x46')],null))[_0x503d67('0x57')](respondWithResult(_0x1d7626,null))[_0x503d67('0x0')](handleError(_0x1d7626,null));},exports[_0x4bb842('0x1e')]=function(_0xdfc921,_0x58c394){const _0x3e508e=_0x4bb842;return db[_0x3e508e('0x18')][_0x3e508e('0x1e')]()['then'](respondWithResult(_0x58c394,null))[_0x3e508e('0x0')](handleError(_0x58c394,null));},exports[_0x4bb842('0xb')]=function(_0xe9e3f3,_0x177e71){const _0x59d2b8=_0x4bb842,_0x1a5e3a=require(_0x59d2b8('0x75'));let _0x2bd773=![];const _0x26c58a={};return _0xe9e3f3[_0x59d2b8('0x53')][_0x59d2b8('0xa')]&&_0xe9e3f3[_0x59d2b8('0x53')]['type']===_0x59d2b8('0x82')?_0x26c58a[_0x59d2b8('0x82')]=_0xe9e3f3[_0x59d2b8('0x9')]['id']:_0x26c58a['id']=_0xe9e3f3['params']['id'],db[_0x59d2b8('0x18')][_0x59d2b8('0x59')]({'where':_0x26c58a,'attributes':['id',_0x59d2b8('0x28')],'raw':!![]})[_0x59d2b8('0x57')](handleEntityNotFound(_0x177e71,null))[_0x59d2b8('0x57')](function(_0x2a4c6c){const _0xc8cdc5=_0x59d2b8;if(_0x2a4c6c){const _0x2f6e71=_0x2a4c6c[_0xc8cdc5('0x28')],_0x17c539=util[_0xc8cdc5('0x5e')]('%s.cypher',_0x2f6e71);if(fs[_0xc8cdc5('0x3e')](_0x17c539))return _0x2bd773=!![],_0x1a5e3a[_0xc8cdc5('0x16')](_0x17c539,_0x2f6e71,config[_0xc8cdc5('0x7b')][_0xc8cdc5('0xf')])[_0xc8cdc5('0x57')](function(){return _0x2a4c6c;});return _0x2a4c6c;}})[_0x59d2b8('0x57')](function(_0x1feef9){const _0x3e808e=_0x59d2b8;if(_0x1feef9){const _0x361635=_0x1feef9['value'];if(!fs[_0x3e808e('0x3e')](_0x361635))throw new ValidationError(_0x3e808e('0x2c'));return _0x1feef9['filename']?_0x177e71[_0x3e808e('0xb')](_0x361635,_0x1feef9[_0x3e808e('0x30')]+path[_0x3e808e('0x45')](_0x361635),function(){_0x2bd773&&fs['unlink'](_0x361635);}):_0x177e71[_0x3e808e('0xb')](_0x361635,function(){const _0x26c5cf=_0x3e808e;_0x2bd773&&fs[_0x26c5cf('0xe')](_0x361635);});}})['catch'](function(_0x3187b7){const _0x55359f=_0x59d2b8;if(_0x3187b7[_0x55359f('0x42')]===_0x55359f('0x2c'))_0x177e71[_0x55359f('0x38')](0x194)['send'](_0x55359f('0x48'));else return handleError(_0x177e71,null);});},exports[_0x4bb842('0x61')]=function(_0x264ae0,_0xab6c8e){const _0x1b1b7b=_0x4bb842,_0x375c2b=require(_0x1b1b7b('0x75'));let _0x3398ee=![];const _0x3bec55={[Op[_0x1b1b7b('0x7c')]]:[_0x3bec55(fn('MD5',col(_0x1b1b7b('0x82'))),_0x264ae0[_0x1b1b7b('0x53')][_0x1b1b7b('0x72')])]};return _0x264ae0[_0x1b1b7b('0x53')][_0x1b1b7b('0xa')]&&_0x264ae0[_0x1b1b7b('0x53')]['type']===_0x1b1b7b('0x82')?_0x3bec55[_0x1b1b7b('0x35')][_0x1b1b7b('0x4f')]({'uniqueid':_0x264ae0[_0x1b1b7b('0x9')]['id']}):_0x3bec55[_0x1b1b7b('0x35')]['push']({'id':_0x264ae0[_0x1b1b7b('0x9')]['id']}),db[_0x1b1b7b('0x18')][_0x1b1b7b('0x59')]({'where':_0x3bec55,'attributes':['id',_0x1b1b7b('0x28')],'raw':!![]})[_0x1b1b7b('0x57')](handleEntityNotFound(_0xab6c8e,null))[_0x1b1b7b('0x57')](function(_0x9b0834){const _0x5e8653=_0x1b1b7b;if(_0x9b0834){const _0x2823eb=util[_0x5e8653('0x5e')]('%s.cypher',_0x9b0834[_0x5e8653('0x28')]);if(fs['existsSync'](_0x2823eb))return _0x3398ee=!![],_0x375c2b[_0x5e8653('0x16')](_0x2823eb,_0x9b0834['value'],config['secrets'][_0x5e8653('0xf')])[_0x5e8653('0x57')](function(){return _0x9b0834;});return _0x9b0834;}})[_0x1b1b7b('0x57')](function(_0x30c513){const _0x4cc9f2=_0x1b1b7b;if(_0x30c513){if(!fs[_0x4cc9f2('0x3e')](_0x30c513[_0x4cc9f2('0x28')]))throw new ValidationError(_0x4cc9f2('0x2c'));return _0x30c513[_0x4cc9f2('0x30')]?_0xab6c8e['download'](_0x30c513[_0x4cc9f2('0x28')],_0x30c513[_0x4cc9f2('0x30')]+path[_0x4cc9f2('0x45')](_0x30c513[_0x4cc9f2('0x28')]),function(){const _0x40a48d=_0x4cc9f2;_0x3398ee&&fs['unlink'](_0x30c513[_0x40a48d('0x28')]);}):_0xab6c8e[_0x4cc9f2('0xb')](_0x30c513['value'],function(){const _0x4aefc6=_0x4cc9f2;_0x3398ee&&fs[_0x4aefc6('0xe')](_0x30c513[_0x4aefc6('0x28')]);});}})['catch'](handleError(_0xab6c8e,null));},exports['destroy']=function(_0x206e80,_0x1261d6){const _0x59001b=_0x4bb842;return db[_0x59001b('0x18')][_0x59001b('0x59')]({'where':{'id':_0x206e80[_0x59001b('0x9')]['id']}})[_0x59001b('0x57')](function(_0x120011){const _0x2d0deb=_0x59001b;if(!_0x120011)throw new ReferenceError(_0x2d0deb('0x68'));return _0x120011;})[_0x59001b('0x57')](function(_0x21d240){const _0x92cee3=_0x59001b;let _0x115c1b=_0x21d240[_0x92cee3('0x28')];return logger[_0x92cee3('0x44')](_0x92cee3('0x4b'),_0x115c1b),!_[_0x92cee3('0x8')](_0x21d240['value'])&&fs[_0x92cee3('0x3e')](_0x115c1b)&&(logger['info']('File:\x20\x22'+_0x115c1b+_0x92cee3('0x2')),fs[_0x92cee3('0x4a')](_0x115c1b)),_0x115c1b=_0x115c1b+_0x92cee3('0x36'),!_[_0x92cee3('0x8')](_0x21d240['value'])&&fs['existsSync'](_0x115c1b)&&(logger[_0x92cee3('0x44')]('File:\x20\x22'+_0x115c1b+_0x92cee3('0x2')),fs[_0x92cee3('0x4a')](_0x115c1b)),_0x21d240;})[_0x59001b('0x57')](function(_0x3b77d7){const _0x21f5ee=_0x59001b;if(!_0x3b77d7)throw new InternalError();return _0x3b77d7[_0x21f5ee('0x39')]();})[_0x59001b('0x57')](function(){const _0x39199d=_0x59001b;_0x1261d6[_0x39199d('0x38')](0xcc)[_0x39199d('0x21')]();})[_0x59001b('0x0')](handleError(_0x1261d6,null));};function getBucketslist(_0x2942fe,_0x287b27,_0x576b14){return new Promise(function(_0x43a249,_0x234415){const _0x106300=a771_0x3ba9,_0x4c74f6=new AWS['S3']({'accessKeyId':_0x287b27,'secretAccessKey':_0x2942fe,'region':_0x576b14});_0x4c74f6[_0x106300('0x4')]({},function(_0x4859de,_0xab3115){return _0x4859de?_0x234415(_0x4859de):_0x43a249(_0xab3115);});});}function createBucket(_0x5aec8a,_0x4bbd75,_0x1dc8e0,_0x14470a){return new Promise(function(_0x241fa4,_0x5c319d){const _0x4834e4=a771_0x3ba9,_0x448cf4=new AWS['S3']({'accessKeyId':_0x4bbd75,'secretAccessKey':_0x5aec8a,'region':_0x1dc8e0});_0x448cf4[_0x4834e4('0x7')]({'Bucket':_0x14470a},function(_0x4f555c,_0x10e988){return _0x4f555c?_0x5c319d(_0x4f555c):_0x241fa4(_0x10e988);});});}function uploadFile(_0x6ff598,_0x3e04b1,_0x4e7675,_0x36f54b,_0x462ad7,_0x2ef1a9){return new Promise(function(_0x135052,_0x68cec0){const _0x52a001=a771_0x3ba9,_0x553bd2=new AWS['S3']({'accessKeyId':_0x3e04b1,'secretAccessKey':_0x6ff598,'region':_0x4e7675});_0x553bd2[_0x52a001('0x6')]({'Bucket':_0x36f54b,'Key':_0x462ad7,'Body':_0x2ef1a9},function(_0x2ac774,_0x260c64){return _0x2ac774?_0x68cec0(_0x2ac774):_0x135052(_0x260c64);});});}function startTranscribe(_0x4bcdfd,_0xa33cc,_0x1c8192,_0x31a926,_0x32893f,_0x18949f){return new Promise(function(_0x4dd645,_0x16dd77){const _0x50984e=a771_0x3ba9,_0x18c990=new AWS[(_0x50984e('0x5'))]({'accessKeyId':_0xa33cc,'secretAccessKey':_0x4bcdfd,'region':_0x1c8192});_0x18c990['startTranscriptionJob']({'TranscriptionJobName':_0x31a926,'LanguageCode':_0x32893f,'Media':{'MediaFileUri':_0x18949f}},function(_0x5f59f5,_0x5e1035){return _0x5f59f5?_0x16dd77(_0x5f59f5):_0x4dd645(_0x5e1035);});});}function transcribe(_0x3a0dbf,_0x57e1d8,_0x537a13,_0x15ae5d,_0x173e11,_0x52f321,_0xcef2e9){return new Promise(function(_0x279503,_0x2d6f1b){const _0x58975d=a771_0x3ba9,_0x16e5ec={};return logger[_0x58975d('0x44')](util['format'](_0x58975d('0x33'),_0x3a0dbf,_0x173e11)),uploadFile(_0x57e1d8,_0x537a13,_0x15ae5d,_0x173e11,path[_0x58975d('0x43')](_0x52f321),fs[_0x58975d('0x31')](_0x52f321))[_0x58975d('0x57')](function(_0x47537d){const _0x48a7ba=_0x58975d;return logger[_0x48a7ba('0x44')](util[_0x48a7ba('0x5e')](_0x48a7ba('0x1'),_0x3a0dbf,_0x173e11,_0x47537d[_0x48a7ba('0x67')])),_0x16e5ec[_0x48a7ba('0x4e')]=_0x47537d[_0x48a7ba('0x81')],_0x16e5ec['location']=_0x47537d[_0x48a7ba('0x67')],logger[_0x48a7ba('0x44')](util['format'](_0x48a7ba('0x4c'),_0x3a0dbf)),startTranscribe(_0x57e1d8,_0x537a13,_0x15ae5d,uuidv4(),_0xcef2e9,_0x47537d[_0x48a7ba('0x67')]);})[_0x58975d('0x57')](function(_0x14f871){const _0x5c1f74=_0x58975d;return logger[_0x5c1f74('0x44')](util[_0x5c1f74('0x5e')](_0x5c1f74('0x47'),_0x3a0dbf,_0x14f871[_0x5c1f74('0x2f')][_0x5c1f74('0x10')])),_0x16e5ec[_0x5c1f74('0x6f')]=_0x14f871[_0x5c1f74('0x2f')][_0x5c1f74('0x10')],_0x16e5ec[_0x5c1f74('0x2b')]=_0x14f871[_0x5c1f74('0x2f')][_0x5c1f74('0x25')],_0x279503(_0x16e5ec);})[_0x58975d('0x0')](function(_0x5f3cfc){return _0x2d6f1b(_0x5f3cfc);});});}exports[_0x4bb842('0x34')]=function(_0x55263b,_0x17943d){const _0x16c5b4=_0x4bb842;let _0x7bb96e,_0x3bd5de,_0x19cc50;const _0x4a4be2=require(_0x16c5b4('0x75'));return db[_0x16c5b4('0x18')][_0x16c5b4('0x59')]({'where':{'id':_0x55263b['params']['id']}})['then'](function(_0x4789e8){const _0x369a4b=_0x16c5b4;if(_0x4789e8){const _0x51bfd9=util[_0x369a4b('0x5e')](_0x369a4b('0x14'),_0x4789e8[_0x369a4b('0x28')]);if(fs[_0x369a4b('0x3e')](_0x51bfd9))return _0x4a4be2[_0x369a4b('0x16')](_0x51bfd9,_0x4789e8[_0x369a4b('0x28')],config['secrets'][_0x369a4b('0xf')])[_0x369a4b('0x57')](function(){return _0x4789e8;});return _0x4789e8;}})[_0x16c5b4('0x57')](function(_0x4afb1a){const _0x232c8d=_0x16c5b4;if(!_0x4afb1a)throw new ValidationError('Voice\x20Recording\x20not\x20found');return _0x3bd5de=_0x4afb1a,db[_0x232c8d('0x7d')][_0x232c8d('0x59')]({'where':{'id':0x1}});})[_0x16c5b4('0x57')](handleEntityNotFound(_0x17943d,null))[_0x16c5b4('0x57')](function(_0x1096cc){const _0x59d786=_0x16c5b4;if(_0x1096cc){_0x7bb96e=_0x1096cc;if(!_0x7bb96e[_0x59d786('0x66')]||!_0x7bb96e[_0x59d786('0x27')]||!_0x7bb96e[_0x59d786('0x1c')]||!_0x7bb96e['language']||!_0x7bb96e['bucket'])throw new ValidationError(_0x59d786('0x5c'));if(_0x55263b['body'][_0x59d786('0x2d')]&&(!_0x7bb96e['sentiment']||!_0x7bb96e['sentimentAccountId']||!_0x7bb96e[_0x59d786('0x58')]||!_0x7bb96e[_0x59d786('0x22')]||!_0x7bb96e['bucket']))throw new ValidationError('Sentiment\x20Analysis\x20not\x20configured');return db['CloudProvider'][_0x59d786('0x59')]({'where':{'id':_0x7bb96e[_0x59d786('0x27')]}});}})[_0x16c5b4('0x57')](function(_0x15f7df){const _0x4839fa=_0x16c5b4;if(!_0x15f7df)throw new ValidationError(_0x4839fa('0x74'));if(!_0x15f7df['data1']||!_0x15f7df['data2'])throw new ValidationError('Cloud\x20Provider\x20not\x20configured');return _0x19cc50=_0x15f7df,getBucketslist(_0x19cc50['data1'],_0x19cc50[_0x4839fa('0x12')],_0x7bb96e[_0x4839fa('0x1c')]);})['then'](function(_0x2f1517){const _0x469b83=_0x16c5b4;if(_0x2f1517&&_0x2f1517[_0x469b83('0x55')]){const _0x100f8b=_[_0x469b83('0x6b')](_0x2f1517[_0x469b83('0x55')],function(_0x2e1e6f){const _0x2c65c1=_0x469b83;return _0x2e1e6f[_0x2c65c1('0x65')]===_0x7bb96e[_0x2c65c1('0x4e')];});if(!_0x100f8b)return logger['info'](util['format'](_0x469b83('0x15'),_0x55263b[_0x469b83('0x9')]['id'],_0x7bb96e[_0x469b83('0x4e')])),createBucket(_0x19cc50[_0x469b83('0x60')],_0x19cc50[_0x469b83('0x12')],_0x7bb96e[_0x469b83('0x1c')],_0x7bb96e[_0x469b83('0x4e')]);logger[_0x469b83('0x44')](util['format'](_0x469b83('0x32'),_0x55263b[_0x469b83('0x9')]['id'],_0x7bb96e[_0x469b83('0x4e')]));return;}})[_0x16c5b4('0x57')](function(){const _0x181b7b=_0x16c5b4;return _0x3bd5de[_0x181b7b('0x2b')]===_0x181b7b('0x52')?transcribe(_0x55263b[_0x181b7b('0x9')]['id'],_0x19cc50['data1'],_0x19cc50['data2'],_0x7bb96e['transcribeRegion'],_0x7bb96e['bucket'],_0x3bd5de[_0x181b7b('0x28')],_0x7bb96e[_0x181b7b('0x22')]):(logger[_0x181b7b('0x44')](util[_0x181b7b('0x5e')]('[RUNTRANSCRIPT][%d]\x20Transcript\x20action\x20already\x20requested',_0x55263b[_0x181b7b('0x9')]['id'])),{'transcribeStatus':_0x181b7b('0x63')});})[_0x16c5b4('0x57')](function(_0x205e62){const _0x16a313=_0x16c5b4;if(_0x205e62)return _0x205e62['tempSentiment']=_0x55263b[_0x16a313('0x46')][_0x16a313('0x2d')],_0x3bd5de[_0x16a313('0x6d')](_0x205e62);})['then'](respondWithResult(_0x17943d,null))[_0x16c5b4('0x0')](handleError(_0x17943d,null));};function writeFile(_0x2fd28e,_0x5f14af){return new Promise(function(_0x27409a,_0x47acd3){const _0x332999=a771_0x3ba9;fs[_0x332999('0x50')](_0x5f14af,_0x2fd28e,function(_0x52b697,_0x3f6731){return _0x52b697?_0x47acd3(_0x52b697):_0x27409a(_0x3f6731);});});}exports[_0x4bb842('0x69')]=function(_0x47bc33,_0x4ab9d3){const _0x166f1f=_0x4bb842;return db[_0x166f1f('0x18')][_0x166f1f('0x59')]({'where':{'id':_0x47bc33['params']['id']}})[_0x166f1f('0x57')](handleEntityNotFound(_0x4ab9d3))[_0x166f1f('0x57')](function(_0x5d6c4f){const _0x52077b=_0x166f1f;if(_0x5d6c4f&&_0x5d6c4f['fileText']){const _0x4861e3=_0x5d6c4f[_0x52077b('0x20')],_0x2b19c6=config[_0x52077b('0x79')]+'/server/files/transcribes/transcribe_'+_0x5d6c4f['id']+_0x52077b('0x7a');if(fs[_0x52077b('0x3e')](_0x2b19c6))return _0x2b19c6;return writeFile(_0x4861e3,_0x2b19c6)[_0x52077b('0x57')](function(){return _0x2b19c6;});}else throw new ValidationError(_0x52077b('0x26'));})[_0x166f1f('0x57')](function(_0x1f6a7d){return _0x4ab9d3['download'](_0x1f6a7d);})['catch'](handleError(_0x4ab9d3));}; \ No newline at end of file diff --git a/server/api/voiceRecording/voiceRecording.model.js b/server/api/voiceRecording/voiceRecording.model.js index 76ab6a5..b1ad2cd 100644 --- a/server/api/voiceRecording/voiceRecording.model.js +++ b/server/api/voiceRecording/voiceRecording.model.js @@ -1 +1 @@ -const a772_0x49bf=['define','uniqueid','exports'];(function(_0x4d1394,_0x49bf63){const _0x19936f=function(_0x206f6a){while(--_0x206f6a){_0x4d1394['push'](_0x4d1394['shift']());}};_0x19936f(++_0x49bf63);}(a772_0x49bf,0x177));const a772_0x1993=function(_0x4d1394,_0x49bf63){_0x4d1394=_0x4d1394-0x0;let _0x19936f=a772_0x49bf[_0x4d1394];return _0x19936f;};const _0x16870f=a772_0x1993;'use strict';const attributes=require('./voiceRecording.attributes');module[_0x16870f('0x2')]=function(_0x206f6a){const _0x5dcd2e=_0x16870f,_0x1cb634=_0x206f6a[_0x5dcd2e('0x0')]('VoiceRecording',attributes,{'tableName':'voice_recordings','paranoid':![],'indexes':[{'name':_0x5dcd2e('0x1'),'fields':[_0x5dcd2e('0x1')]}],'timestamps':!![]});return _0x1cb634;}; \ No newline at end of file +const a772_0x4f5c=['./voiceRecording.attributes','voice_recordings','exports','uniqueid'];(function(_0x41721a,_0x4f5c4f){const _0x93751=function(_0x443f07){while(--_0x443f07){_0x41721a['push'](_0x41721a['shift']());}};_0x93751(++_0x4f5c4f);}(a772_0x4f5c,0xca));const a772_0x9375=function(_0x41721a,_0x4f5c4f){_0x41721a=_0x41721a-0x0;let _0x93751=a772_0x4f5c[_0x41721a];return _0x93751;};const _0x219030=a772_0x9375;'use strict';const attributes=require(_0x219030('0x2'));module[_0x219030('0x0')]=function(_0x443f07){const _0x4a39ed=_0x219030,_0x4f05fe=_0x443f07['define']('VoiceRecording',attributes,{'tableName':_0x4a39ed('0x3'),'paranoid':![],'indexes':[{'name':_0x4a39ed('0x1'),'fields':[_0x4a39ed('0x1')]}],'timestamps':!![]});return _0x4f05fe;}; \ No newline at end of file diff --git a/server/api/voiceRecording/voiceRecording.rpc.js b/server/api/voiceRecording/voiceRecording.rpc.js index ad01f9c..5e989b1 100644 --- a/server/api/voiceRecording/voiceRecording.rpc.js +++ b/server/api/voiceRecording/voiceRecording.rpc.js @@ -1 +1 @@ -const a773_0x40a5=['create','options','callRecordingEncryption','then','util','catch','UpdateVoiceRecording','message','CreateVoiceRecording','../../config/environment','CreateVoiceRecording\x20file\x20encrypted','recording','../../mysqldb','../../components/encryptor','stringify','format','attributes','Setting','info','value','update','encryptFile','body','error','../../config/logger','findOne','where','VoiceRecording','limit','rpc'];(function(_0x4bd68b,_0x40a515){const _0x391491=function(_0x386109){while(--_0x386109){_0x4bd68b['push'](_0x4bd68b['shift']());}};_0x391491(++_0x40a515);}(a773_0x40a5,0x1a8));const a773_0x3914=function(_0x4bd68b,_0x40a515){_0x4bd68b=_0x4bd68b-0x0;let _0x391491=a773_0x40a5[_0x4bd68b];return _0x391491;};const _0x15da8a=a773_0x3914;'use strict';const util=require(_0x15da8a('0x0')),fs=require('fs'),db=require(_0x15da8a('0x8'))['db'],logger=require(_0x15da8a('0x14'))(_0x15da8a('0x19')),config=require(_0x15da8a('0x5'));exports[_0x15da8a('0x2')]=function(_0x386109){const _0x4c5408=this;return new Promise(function(_0xe6d015,_0x2453eb){const _0x58bf39=a773_0x3914;return db['VoiceRecording'][_0x58bf39('0x10')](_0x386109[_0x58bf39('0x12')],{'raw':_0x386109[_0x58bf39('0x1b')]?_0x386109[_0x58bf39('0x1b')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x386109[_0x58bf39('0x1b')]?_0x386109[_0x58bf39('0x1b')][_0x58bf39('0x16')]||null:null,'attributes':_0x386109[_0x58bf39('0x1b')]?_0x386109['options'][_0x58bf39('0xc')]||null:null,'limit':_0x386109[_0x58bf39('0x1b')]?_0x386109[_0x58bf39('0x1b')][_0x58bf39('0x18')]||null:null})[_0x58bf39('0x1d')](function(_0x486dd7){const _0x27568a=_0x58bf39;logger[_0x27568a('0xe')]('UpdateVoiceRecording',_0x386109),logger['debug'](_0x27568a('0x2'),_0x386109,JSON[_0x27568a('0xa')](_0x486dd7)),_0xe6d015(_0x486dd7);})[_0x58bf39('0x1')](function(_0x538371){const _0x25d9ac=_0x58bf39;logger[_0x25d9ac('0x13')](_0x25d9ac('0x2'),_0x538371[_0x25d9ac('0x3')],_0x386109),_0x2453eb(_0x4c5408[_0x25d9ac('0x13')](0x1f4,_0x538371[_0x25d9ac('0x3')]));});});},exports['CreateVoiceRecording']=function(_0x309044){const _0x2fc384=this;return new Promise(function(_0x26d670,_0x38877a){const _0xf46172=a773_0x3914,_0x415217=require(_0xf46172('0x9'));let _0x596cbf;return db[_0xf46172('0xd')][_0xf46172('0x15')]({'attributes':['id',_0xf46172('0x1c')],'where':{'id':0x1},'raw':!![]})['then'](function(_0x125dd7){const _0x248be0=_0xf46172;return _0x596cbf=_0x125dd7,db[_0x248be0('0x17')][_0x248be0('0x1a')](_0x309044['body']);})[_0xf46172('0x1d')](function(_0x22523f){const _0x29fb49=_0xf46172;if(_0x596cbf['callRecordingEncryption']&&fs['existsSync'](_0x22523f[_0x29fb49('0xf')])){const _0xb9f10d=util[_0x29fb49('0xb')]('%s.cypher',_0x22523f[_0x29fb49('0xf')]);return _0x415217[_0x29fb49('0x11')](_0x22523f[_0x29fb49('0xf')],_0xb9f10d,config['secrets'][_0x29fb49('0x7')])[_0x29fb49('0x1d')](function(){const _0x35232d=_0x29fb49;return fs['unlink'](_0x22523f[_0x35232d('0xf')]),logger[_0x35232d('0xe')](_0x35232d('0x6')),_0x22523f;});}return _0x22523f;})[_0xf46172('0x1d')](function(_0x53af06){const _0x347b42=_0xf46172;logger[_0x347b42('0xe')](_0x347b42('0x4'),_0x309044),logger['debug'](_0x347b42('0x4'),_0x309044,JSON['stringify'](_0x53af06)),_0x26d670(_0x53af06);})['catch'](function(_0x1750f7){const _0x3b3618=_0xf46172;logger[_0x3b3618('0x13')](_0x3b3618('0x4'),_0x1750f7[_0x3b3618('0x3')],_0x309044),_0x38877a(_0x2fc384[_0x3b3618('0x13')](0x1f4,_0x1750f7[_0x3b3618('0x3')]));});});}; \ No newline at end of file +const a773_0xc4e2=['unlink','format','value','../../config/logger','rpc','recording','util','update','message','secrets','../../mysqldb','%s.cypher','debug','attributes','catch','stringify','../../config/environment','existsSync','then','UpdateVoiceRecording','callRecordingEncryption','encryptFile','info','Setting','body','VoiceRecording','CreateVoiceRecording\x20file\x20encrypted','error','create','options','CreateVoiceRecording','raw'];(function(_0x599b33,_0xc4e23f){const _0x4e395f=function(_0xfa1184){while(--_0xfa1184){_0x599b33['push'](_0x599b33['shift']());}};_0x4e395f(++_0xc4e23f);}(a773_0xc4e2,0x7a));const a773_0x4e39=function(_0x599b33,_0xc4e23f){_0x599b33=_0x599b33-0x0;let _0x4e395f=a773_0xc4e2[_0x599b33];return _0x4e395f;};const _0x63c72e=a773_0x4e39;'use strict';const util=require(_0x63c72e('0xc')),fs=require('fs'),db=require(_0x63c72e('0x10'))['db'],logger=require(_0x63c72e('0x9'))(_0x63c72e('0xa')),config=require(_0x63c72e('0x16'));exports[_0x63c72e('0x19')]=function(_0xfa1184){const _0x99711a=this;return new Promise(function(_0x37c718,_0x36bb6d){const _0x2552e0=a773_0x4e39;return db[_0x2552e0('0x1f')][_0x2552e0('0xd')](_0xfa1184[_0x2552e0('0x1e')],{'raw':_0xfa1184[_0x2552e0('0x3')]?_0xfa1184[_0x2552e0('0x3')][_0x2552e0('0x5')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0xfa1184[_0x2552e0('0x3')]?_0xfa1184['options']['where']||null:null,'attributes':_0xfa1184['options']?_0xfa1184['options'][_0x2552e0('0x13')]||null:null,'limit':_0xfa1184[_0x2552e0('0x3')]?_0xfa1184['options']['limit']||null:null})['then'](function(_0x48f046){const _0x4b28f7=_0x2552e0;logger['info'](_0x4b28f7('0x19'),_0xfa1184),logger[_0x4b28f7('0x12')](_0x4b28f7('0x19'),_0xfa1184,JSON[_0x4b28f7('0x15')](_0x48f046)),_0x37c718(_0x48f046);})[_0x2552e0('0x14')](function(_0x9e9d71){const _0x42afc7=_0x2552e0;logger[_0x42afc7('0x1')]('UpdateVoiceRecording',_0x9e9d71[_0x42afc7('0xe')],_0xfa1184),_0x36bb6d(_0x99711a['error'](0x1f4,_0x9e9d71[_0x42afc7('0xe')]));});});},exports['CreateVoiceRecording']=function(_0xef8dc){const _0xdcf9b1=this;return new Promise(function(_0x47b3cc,_0x1916a8){const _0x4759e6=a773_0x4e39,_0x43bbb1=require('../../components/encryptor');let _0x161dbd;return db[_0x4759e6('0x1d')]['findOne']({'attributes':['id',_0x4759e6('0x1a')],'where':{'id':0x1},'raw':!![]})[_0x4759e6('0x18')](function(_0x1faac6){const _0x437ca2=_0x4759e6;return _0x161dbd=_0x1faac6,db[_0x437ca2('0x1f')][_0x437ca2('0x2')](_0xef8dc['body']);})['then'](function(_0x1fdb59){const _0x2478f0=_0x4759e6;if(_0x161dbd['callRecordingEncryption']&&fs[_0x2478f0('0x17')](_0x1fdb59[_0x2478f0('0x8')])){const _0x1a9b1d=util[_0x2478f0('0x7')](_0x2478f0('0x11'),_0x1fdb59[_0x2478f0('0x8')]);return _0x43bbb1[_0x2478f0('0x1b')](_0x1fdb59[_0x2478f0('0x8')],_0x1a9b1d,config[_0x2478f0('0xf')][_0x2478f0('0xb')])[_0x2478f0('0x18')](function(){const _0x5ce8e8=_0x2478f0;return fs[_0x5ce8e8('0x6')](_0x1fdb59[_0x5ce8e8('0x8')]),logger['info'](_0x5ce8e8('0x0')),_0x1fdb59;});}return _0x1fdb59;})[_0x4759e6('0x18')](function(_0xbab6cb){const _0x4a211e=_0x4759e6;logger[_0x4a211e('0x1c')](_0x4a211e('0x4'),_0xef8dc),logger[_0x4a211e('0x12')](_0x4a211e('0x4'),_0xef8dc,JSON[_0x4a211e('0x15')](_0xbab6cb)),_0x47b3cc(_0xbab6cb);})['catch'](function(_0x59910b){const _0x16b47d=_0x4759e6;logger[_0x16b47d('0x1')]('CreateVoiceRecording',_0x59910b['message'],_0xef8dc),_0x1916a8(_0xdcf9b1[_0x16b47d('0x1')](0x1f4,_0x59910b[_0x16b47d('0xe')]));});});}; \ No newline at end of file diff --git a/server/api/voiceTransferReport/index.js b/server/api/voiceTransferReport/index.js index c2c3561..836173d 100644 --- a/server/api/voiceTransferReport/index.js +++ b/server/api/voiceTransferReport/index.js @@ -1 +1 @@ -const a774_0x37fe=['./voiceTransferReport.controller','show','Router','/:id','update','put','exports','create','post','../../components/auth/service','get','index','destroy','isAuthenticated'];(function(_0x418ab7,_0x37fe3e){const _0xde074f=function(_0x50bd53){while(--_0x50bd53){_0x418ab7['push'](_0x418ab7['shift']());}};_0xde074f(++_0x37fe3e);}(a774_0x37fe,0x76));const a774_0xde07=function(_0x418ab7,_0x37fe3e){_0x418ab7=_0x418ab7-0x0;let _0xde074f=a774_0x37fe[_0x418ab7];return _0xde074f;};const _0x8cc9d=a774_0xde07;'use strict';const express=require('express'),router=express[_0x8cc9d('0xa')](),auth=require(_0x8cc9d('0x3')),controller=require(_0x8cc9d('0x8'));router[_0x8cc9d('0x4')]('/',auth[_0x8cc9d('0x7')](),controller[_0x8cc9d('0x5')]),router[_0x8cc9d('0x4')](_0x8cc9d('0xb'),auth[_0x8cc9d('0x7')](),controller[_0x8cc9d('0x9')]),router[_0x8cc9d('0x2')]('/',auth[_0x8cc9d('0x7')](),controller[_0x8cc9d('0x1')]),router[_0x8cc9d('0xd')]('/:id',auth[_0x8cc9d('0x7')](),controller[_0x8cc9d('0xc')]),router['delete'](_0x8cc9d('0xb'),auth[_0x8cc9d('0x7')](),controller[_0x8cc9d('0x6')]),module[_0x8cc9d('0x0')]=router; \ No newline at end of file +const a774_0x2364=['get','/:id','exports','isAuthenticated','update','Router','index','create','show','post','../../components/auth/service','put'];(function(_0x29135b,_0x23643e){const _0x100c7e=function(_0x49e4da){while(--_0x49e4da){_0x29135b['push'](_0x29135b['shift']());}};_0x100c7e(++_0x23643e);}(a774_0x2364,0x88));const a774_0x100c=function(_0x29135b,_0x23643e){_0x29135b=_0x29135b-0x0;let _0x100c7e=a774_0x2364[_0x29135b];return _0x100c7e;};const _0x3b030e=a774_0x100c;'use strict';const express=require('express'),router=express[_0x3b030e('0x1')](),auth=require(_0x3b030e('0x6')),controller=require('./voiceTransferReport.controller');router[_0x3b030e('0x8')]('/',auth[_0x3b030e('0xb')](),controller[_0x3b030e('0x2')]),router[_0x3b030e('0x8')](_0x3b030e('0x9'),auth[_0x3b030e('0xb')](),controller[_0x3b030e('0x4')]),router[_0x3b030e('0x5')]('/',auth[_0x3b030e('0xb')](),controller[_0x3b030e('0x3')]),router[_0x3b030e('0x7')](_0x3b030e('0x9'),auth[_0x3b030e('0xb')](),controller[_0x3b030e('0x0')]),router['delete']('/:id',auth['isAuthenticated'](),controller['destroy']),module[_0x3b030e('0xa')]=router; \ No newline at end of file diff --git a/server/api/voiceTransferReport/voiceTransferReport.attributes.js b/server/api/voiceTransferReport/voiceTransferReport.attributes.js index 9d70daf..07da84c 100644 --- a/server/api/voiceTransferReport/voiceTransferReport.attributes.js +++ b/server/api/voiceTransferReport/voiceTransferReport.attributes.js @@ -1 +1 @@ -const a775_0x5a8b=['STRING','blind','Yes','exports','ENUM','attended'];(function(_0x54cbdf,_0x5a8b58){const _0x161085=function(_0x559104){while(--_0x559104){_0x54cbdf['push'](_0x54cbdf['shift']());}};_0x161085(++_0x5a8b58);}(a775_0x5a8b,0xde));const a775_0x1610=function(_0x54cbdf,_0x5a8b58){_0x54cbdf=_0x54cbdf-0x0;let _0x161085=a775_0x5a8b[_0x54cbdf];return _0x161085;};const _0x3d260f=a775_0x1610;'use strict';const Sequelize=require('sequelize');module[_0x3d260f('0x3')]={'type':{'type':Sequelize[_0x3d260f('0x4')](_0x3d260f('0x1'),_0x3d260f('0x5'))},'result':{'type':Sequelize[_0x3d260f('0x0')]},'transfererchannel':{'type':Sequelize[_0x3d260f('0x0')]},'transferercalleridnum':{'type':Sequelize[_0x3d260f('0x0')]},'transferercalleridname':{'type':Sequelize[_0x3d260f('0x0')]},'transfererconnectedlinenum':{'type':Sequelize[_0x3d260f('0x0')]},'transfererconnectedlinename':{'type':Sequelize[_0x3d260f('0x0')]},'transfereraccountcode':{'type':Sequelize[_0x3d260f('0x0')]},'transferercontext':{'type':Sequelize[_0x3d260f('0x0')]},'transfererexten':{'type':Sequelize['STRING']},'transfererlinkedid':{'type':Sequelize[_0x3d260f('0x0')]},'transfereechannel':{'type':Sequelize['STRING']},'transfereecalleridnum':{'type':Sequelize[_0x3d260f('0x0')]},'transfereecalleridname':{'type':Sequelize[_0x3d260f('0x0')]},'transfereeconnectedlinenum':{'type':Sequelize['STRING']},'transfereeconnectedlinename':{'type':Sequelize[_0x3d260f('0x0')]},'transfereeaccountcode':{'type':Sequelize[_0x3d260f('0x0')]},'transfereecontext':{'type':Sequelize[_0x3d260f('0x0')]},'transfereeexten':{'type':Sequelize[_0x3d260f('0x0')]},'transfereelinkedid':{'type':Sequelize['STRING']},'isexternal':{'type':Sequelize['ENUM'](_0x3d260f('0x2'),'No')},'context':{'type':Sequelize[_0x3d260f('0x0')]},'extension':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a775_0x1c3c=['blind','sequelize','ENUM','STRING','Yes','exports'];(function(_0x42252d,_0x1c3cf5){const _0x649e90=function(_0x2feeb5){while(--_0x2feeb5){_0x42252d['push'](_0x42252d['shift']());}};_0x649e90(++_0x1c3cf5);}(a775_0x1c3c,0x12f));const a775_0x649e=function(_0x42252d,_0x1c3cf5){_0x42252d=_0x42252d-0x0;let _0x649e90=a775_0x1c3c[_0x42252d];return _0x649e90;};const _0x22a979=a775_0x649e;'use strict';const Sequelize=require(_0x22a979('0x4'));module[_0x22a979('0x2')]={'type':{'type':Sequelize[_0x22a979('0x5')](_0x22a979('0x3'),'attended')},'result':{'type':Sequelize['STRING']},'transfererchannel':{'type':Sequelize[_0x22a979('0x0')]},'transferercalleridnum':{'type':Sequelize[_0x22a979('0x0')]},'transferercalleridname':{'type':Sequelize[_0x22a979('0x0')]},'transfererconnectedlinenum':{'type':Sequelize[_0x22a979('0x0')]},'transfererconnectedlinename':{'type':Sequelize[_0x22a979('0x0')]},'transfereraccountcode':{'type':Sequelize[_0x22a979('0x0')]},'transferercontext':{'type':Sequelize[_0x22a979('0x0')]},'transfererexten':{'type':Sequelize[_0x22a979('0x0')]},'transfererlinkedid':{'type':Sequelize[_0x22a979('0x0')]},'transfereechannel':{'type':Sequelize[_0x22a979('0x0')]},'transfereecalleridnum':{'type':Sequelize['STRING']},'transfereecalleridname':{'type':Sequelize[_0x22a979('0x0')]},'transfereeconnectedlinenum':{'type':Sequelize[_0x22a979('0x0')]},'transfereeconnectedlinename':{'type':Sequelize[_0x22a979('0x0')]},'transfereeaccountcode':{'type':Sequelize[_0x22a979('0x0')]},'transfereecontext':{'type':Sequelize[_0x22a979('0x0')]},'transfereeexten':{'type':Sequelize[_0x22a979('0x0')]},'transfereelinkedid':{'type':Sequelize[_0x22a979('0x0')]},'isexternal':{'type':Sequelize[_0x22a979('0x5')](_0x22a979('0x1'),'No')},'context':{'type':Sequelize[_0x22a979('0x0')]},'extension':{'type':Sequelize[_0x22a979('0x0')]}}; \ No newline at end of file diff --git a/server/api/voiceTransferReport/voiceTransferReport.controller.js b/server/api/voiceTransferReport/voiceTransferReport.controller.js index 5250cb5..6a1e3d7 100644 --- a/server/api/voiceTransferReport/voiceTransferReport.controller.js +++ b/server/api/voiceTransferReport/voiceTransferReport.controller.js @@ -1 +1 @@ -const a776_0x3a05=['rows','filters','../../mysqldb','VoiceTransferReport','VIRTUAL','sendStatus','fieldName','index','Content-Range','pick','fields','params','key','body','filter','query','destroy','include','show','sequelize','nolimit','api','limit','undefined','end','lodash','../../config/logger','../../components/parsers/qs','update','rawAttributes','options','catch','set','includeAll','merge','where','map','name','attributes','model','type','sort','count','error','length','send','create','keys','status','intersection','findOne','then','offset','json'];(function(_0x7191a8,_0x3a056d){const _0x1ae788=function(_0x4a9038){while(--_0x4a9038){_0x7191a8['push'](_0x7191a8['shift']());}};_0x1ae788(++_0x3a056d);}(a776_0x3a05,0xac));const a776_0x1ae7=function(_0x7191a8,_0x3a056d){_0x7191a8=_0x7191a8-0x0;let _0x1ae788=a776_0x3a05[_0x7191a8];return _0x1ae788;};const _0x2817e7=a776_0x1ae7;'use strict';const _=require(_0x2817e7('0xf')),qs=require(_0x2817e7('0x11')),logger=require(_0x2817e7('0x10'))(_0x2817e7('0xb')),db=require(_0x2817e7('0x2e'))['db'],{Op}=require(_0x2817e7('0x9'));function respondWithResult(_0x4a9038,_0x599b73){return _0x599b73=_0x599b73||0xc8,function(_0x39053e){const _0x2bf87c=a776_0x1ae7;if(_0x39053e)return _0x4a9038['status'](_0x599b73)[_0x2bf87c('0x2b')](_0x39053e);};}function respondWithFilteredResult(_0x52801d,_0x3060bd){return function(_0x42a7fe){const _0x57c0fa=a776_0x1ae7;if(_0x42a7fe){const _0x19c879=_0x42a7fe[_0x57c0fa('0x20')],_0x4a0a17=_0x3060bd['offset'];let _0x1338a6=_0x3060bd['offset']+_0x3060bd[_0x57c0fa('0xc')],_0x4f0838;return _0x1338a6>=_0x19c879?(_0x1338a6=_0x19c879,_0x4f0838=0xc8):_0x4f0838=0xce,_0x52801d['status'](_0x4f0838),_0x52801d[_0x57c0fa('0x16')](_0x57c0fa('0x34'),_0x4a0a17+'-'+_0x1338a6+'/'+_0x19c879)[_0x57c0fa('0x2b')](_0x42a7fe);}return null;};}function saveUpdates(_0x21f55e){return function(_0x4c66f6){const _0x4477df=a776_0x1ae7;if(_0x4c66f6)return _0x4c66f6[_0x4477df('0x12')](_0x21f55e)[_0x4477df('0x29')](function(_0x337349){return _0x337349;});return null;};}function removeEntity(_0x3e5fce){return function(_0xd26dc2){const _0x57e5f3=a776_0x1ae7;if(_0xd26dc2)return _0xd26dc2[_0x57e5f3('0x6')]()['then'](function(){const _0xfe3843=_0x57e5f3;_0x3e5fce[_0xfe3843('0x26')](0xcc)[_0xfe3843('0xe')]();});};}function handleEntityNotFound(_0x2ce613){return function(_0x3bc3ee){const _0x1aea58=a776_0x1ae7;return!_0x3bc3ee&&_0x2ce613[_0x1aea58('0x31')](0x194),_0x3bc3ee;};}function handleError(_0x35b179,_0x174c47){return _0x174c47=_0x174c47||0x1f4,function(_0xf2a29b){const _0x18e85b=a776_0x1ae7;logger[_0x18e85b('0x21')](_0xf2a29b['stack']),_0xf2a29b[_0x18e85b('0x1b')]&&delete _0xf2a29b[_0x18e85b('0x1b')],_0x35b179[_0x18e85b('0x26')](_0x174c47)[_0x18e85b('0x23')](_0xf2a29b);};}exports[_0x2817e7('0x33')]=function(_0x5f4ceb,_0x29749b){const _0x49c987=_0x2817e7;let _0x3d4a6a={};const _0x3da172={},_0x534f23={'count':0x0,'rows':[]},_0x575e0e=_[_0x49c987('0x1a')](db[_0x49c987('0x2f')][_0x49c987('0x13')],function(_0x59e385){const _0x2f2d3f=_0x49c987;return{'name':_0x59e385[_0x2f2d3f('0x32')],'type':_0x59e385[_0x2f2d3f('0x1e')][_0x2f2d3f('0x2')]};});_0x3da172[_0x49c987('0x1d')]=_[_0x49c987('0x1a')](_0x575e0e,'name'),_0x3da172[_0x49c987('0x5')]=_[_0x49c987('0x25')](_0x5f4ceb['query']),_0x3da172['filters']=_[_0x49c987('0x27')](_0x3da172[_0x49c987('0x1d')],_0x3da172[_0x49c987('0x5')]),_0x3d4a6a[_0x49c987('0x1c')]=_[_0x49c987('0x27')](_0x3da172[_0x49c987('0x1d')],qs[_0x49c987('0x0')](_0x5f4ceb[_0x49c987('0x5')][_0x49c987('0x0')])),_0x3d4a6a[_0x49c987('0x1c')]=_0x3d4a6a[_0x49c987('0x1c')][_0x49c987('0x22')]?_0x3d4a6a['attributes']:_0x3da172[_0x49c987('0x1d')];typeof _0x5f4ceb[_0x49c987('0x5')][_0x49c987('0xa')]===_0x49c987('0xd')&&(_0x3d4a6a[_0x49c987('0xc')]=qs[_0x49c987('0xc')](_0x5f4ceb[_0x49c987('0x5')][_0x49c987('0xc')]),_0x3d4a6a[_0x49c987('0x2a')]=qs[_0x49c987('0x2a')](_0x5f4ceb[_0x49c987('0x5')][_0x49c987('0x2a')]));_0x3d4a6a['order']=qs[_0x49c987('0x1f')](_0x5f4ceb[_0x49c987('0x5')]['sort']),_0x3d4a6a[_0x49c987('0x19')]=qs[_0x49c987('0x2d')](_[_0x49c987('0x35')](_0x5f4ceb['query'],_0x3da172[_0x49c987('0x2d')]),_0x575e0e);_0x5f4ceb[_0x49c987('0x5')][_0x49c987('0x4')]&&(_0x3d4a6a['where']=_[_0x49c987('0x18')](_0x3d4a6a[_0x49c987('0x19')],{[Op['or']]:_[_0x49c987('0x1a')](_0x575e0e,function(_0x4d1614){const _0x3e774e=_0x49c987;if(_0x4d1614['type']!==_0x3e774e('0x30')){const _0x5002d1={};return _0x5002d1[_0x4d1614[_0x3e774e('0x1b')]]={[Op['like']]:'%'+_0x5f4ceb[_0x3e774e('0x5')][_0x3e774e('0x4')]+'%'},_0x5002d1;}})}));_0x3d4a6a=_[_0x49c987('0x18')]({},_0x3d4a6a,_0x5f4ceb[_0x49c987('0x14')]);const _0x359889={'where':_0x3d4a6a['where']};return db[_0x49c987('0x2f')][_0x49c987('0x20')](_0x359889)[_0x49c987('0x29')](function(_0x49f5cd){const _0x43c804=_0x49c987;return _0x534f23[_0x43c804('0x20')]=_0x49f5cd,_0x5f4ceb[_0x43c804('0x5')][_0x43c804('0x17')]&&(_0x3d4a6a[_0x43c804('0x7')]=[{'all':!![]}]),db[_0x43c804('0x2f')]['findAll'](_0x3d4a6a);})[_0x49c987('0x29')](function(_0x19b67d){const _0x72c574=_0x49c987;return _0x534f23[_0x72c574('0x2c')]=_0x19b67d,_0x534f23;})['then'](respondWithFilteredResult(_0x29749b,_0x3d4a6a))[_0x49c987('0x15')](handleError(_0x29749b,null));},exports[_0x2817e7('0x8')]=function(_0x12f187,_0x1c7f7f){const _0x24e2f7=_0x2817e7;let _0x209042={'raw':!![],'where':{'id':_0x12f187[_0x24e2f7('0x1')]['id']}};const _0x276a85={};return _0x276a85['model']=_[_0x24e2f7('0x25')](db[_0x24e2f7('0x2f')]['rawAttributes']),_0x276a85[_0x24e2f7('0x5')]=_[_0x24e2f7('0x25')](_0x12f187[_0x24e2f7('0x5')]),_0x276a85['filters']=_['intersection'](_0x276a85['model'],_0x276a85['query']),_0x209042[_0x24e2f7('0x1c')]=_[_0x24e2f7('0x27')](_0x276a85[_0x24e2f7('0x1d')],qs[_0x24e2f7('0x0')](_0x12f187[_0x24e2f7('0x5')][_0x24e2f7('0x0')])),_0x209042[_0x24e2f7('0x1c')]=_0x209042[_0x24e2f7('0x1c')][_0x24e2f7('0x22')]?_0x209042[_0x24e2f7('0x1c')]:_0x276a85[_0x24e2f7('0x1d')],_0x12f187[_0x24e2f7('0x5')]['includeAll']&&(_0x209042[_0x24e2f7('0x7')]=[{'all':!![]}]),_0x209042=_[_0x24e2f7('0x18')]({},_0x209042,_0x12f187[_0x24e2f7('0x14')]),db[_0x24e2f7('0x2f')][_0x24e2f7('0x28')](_0x209042)[_0x24e2f7('0x29')](handleEntityNotFound(_0x1c7f7f,null))[_0x24e2f7('0x29')](respondWithResult(_0x1c7f7f,null))[_0x24e2f7('0x15')](handleError(_0x1c7f7f,null));},exports[_0x2817e7('0x24')]=function(_0x3d13cf,_0x5f3e23){const _0x2a7f51=_0x2817e7;return db[_0x2a7f51('0x2f')][_0x2a7f51('0x24')](_0x3d13cf[_0x2a7f51('0x3')],{})[_0x2a7f51('0x29')](respondWithResult(_0x5f3e23,0xc9))[_0x2a7f51('0x15')](handleError(_0x5f3e23,null));},exports['update']=function(_0x1e6906,_0x4c6ce7){const _0x254bf4=_0x2817e7;return _0x1e6906['body']['id']&&delete _0x1e6906[_0x254bf4('0x3')]['id'],db[_0x254bf4('0x2f')][_0x254bf4('0x28')]({'where':{'id':_0x1e6906[_0x254bf4('0x1')]['id']}})[_0x254bf4('0x29')](handleEntityNotFound(_0x4c6ce7,null))[_0x254bf4('0x29')](saveUpdates(_0x1e6906['body'],null))['then'](respondWithResult(_0x4c6ce7,null))[_0x254bf4('0x15')](handleError(_0x4c6ce7,null));},exports[_0x2817e7('0x6')]=function(_0x54ffd2,_0x136fc4){const _0x4ae367=_0x2817e7;return db[_0x4ae367('0x2f')][_0x4ae367('0x28')]({'where':{'id':_0x54ffd2[_0x4ae367('0x1')]['id']}})[_0x4ae367('0x29')](handleEntityNotFound(_0x136fc4,null))[_0x4ae367('0x29')](removeEntity(_0x136fc4,null))[_0x4ae367('0x15')](handleError(_0x136fc4,null));}; \ No newline at end of file +const a776_0x4630=['length','filter','keys','findOne','findAll','includeAll','index','../../mysqldb','fieldName','stack','rows','destroy','model','count','pick','update','body','type','show','name','query','status','intersection','merge','where','send','api','lodash','../../config/logger','VoiceTransferReport','attributes','catch','include','offset','Content-Range','fields','map','../../components/parsers/qs','rawAttributes','limit','options','create','filters','sendStatus','params','set','nolimit','json','key','then'];(function(_0xbb94aa,_0x4630d5){const _0x24aa2b=function(_0x143848){while(--_0x143848){_0xbb94aa['push'](_0xbb94aa['shift']());}};_0x24aa2b(++_0x4630d5);}(a776_0x4630,0x1b6));const a776_0x24aa=function(_0xbb94aa,_0x4630d5){_0xbb94aa=_0xbb94aa-0x0;let _0x24aa2b=a776_0x4630[_0xbb94aa];return _0x24aa2b;};const _0x37c568=a776_0x24aa;'use strict';const _=require(_0x37c568('0x27')),qs=require(_0x37c568('0x31')),logger=require(_0x37c568('0x28'))(_0x37c568('0x26')),db=require(_0x37c568('0x13'))['db'],{Op}=require('sequelize');function respondWithResult(_0x143848,_0x31f8d0){return _0x31f8d0=_0x31f8d0||0xc8,function(_0x84ec68){const _0x162f47=a776_0x24aa;if(_0x84ec68)return _0x143848[_0x162f47('0x21')](_0x31f8d0)[_0x162f47('0x9')](_0x84ec68);};}function respondWithFilteredResult(_0x5ede7a,_0x32769a){return function(_0x30ae85){const _0x3c8865=a776_0x24aa;if(_0x30ae85){const _0x3a09ff=_0x30ae85[_0x3c8865('0x19')],_0x53ea06=_0x32769a[_0x3c8865('0x2d')];let _0x13051c=_0x32769a[_0x3c8865('0x2d')]+_0x32769a[_0x3c8865('0x1')],_0x393da1;return _0x13051c>=_0x3a09ff?(_0x13051c=_0x3a09ff,_0x393da1=0xc8):_0x393da1=0xce,_0x5ede7a['status'](_0x393da1),_0x5ede7a[_0x3c8865('0x7')](_0x3c8865('0x2e'),_0x53ea06+'-'+_0x13051c+'/'+_0x3a09ff)[_0x3c8865('0x9')](_0x30ae85);}return null;};}function saveUpdates(_0x2c3607){return function(_0x1a322b){const _0x11b223=a776_0x24aa;if(_0x1a322b)return _0x1a322b[_0x11b223('0x1b')](_0x2c3607)[_0x11b223('0xb')](function(_0x19d69a){return _0x19d69a;});return null;};}function removeEntity(_0x58d688){return function(_0x11ae74){const _0x41fbc1=a776_0x24aa;if(_0x11ae74)return _0x11ae74['destroy']()[_0x41fbc1('0xb')](function(){const _0x123a0d=_0x41fbc1;_0x58d688[_0x123a0d('0x21')](0xcc)['end']();});};}function handleEntityNotFound(_0x27d08a){return function(_0xedfbc1){const _0x28cf8c=a776_0x24aa;return!_0xedfbc1&&_0x27d08a[_0x28cf8c('0x5')](0x194),_0xedfbc1;};}function handleError(_0x511021,_0x48de31){return _0x48de31=_0x48de31||0x1f4,function(_0x453f98){const _0x5bf175=a776_0x24aa;logger['error'](_0x453f98[_0x5bf175('0x15')]),_0x453f98[_0x5bf175('0x1f')]&&delete _0x453f98[_0x5bf175('0x1f')],_0x511021[_0x5bf175('0x21')](_0x48de31)[_0x5bf175('0x25')](_0x453f98);};}exports[_0x37c568('0x12')]=function(_0x235dc8,_0x2c7841){const _0x3b7f10=_0x37c568;let _0x38db38={};const _0x4f0f89={},_0x299f4b={'count':0x0,'rows':[]},_0x475a35=_[_0x3b7f10('0x30')](db[_0x3b7f10('0x29')][_0x3b7f10('0x0')],function(_0x2dfa4b){const _0x218e9b=_0x3b7f10;return{'name':_0x2dfa4b[_0x218e9b('0x14')],'type':_0x2dfa4b[_0x218e9b('0x1d')][_0x218e9b('0xa')]};});_0x4f0f89[_0x3b7f10('0x18')]=_[_0x3b7f10('0x30')](_0x475a35,_0x3b7f10('0x1f')),_0x4f0f89['query']=_['keys'](_0x235dc8[_0x3b7f10('0x20')]),_0x4f0f89['filters']=_['intersection'](_0x4f0f89[_0x3b7f10('0x18')],_0x4f0f89[_0x3b7f10('0x20')]),_0x38db38[_0x3b7f10('0x2a')]=_[_0x3b7f10('0x22')](_0x4f0f89[_0x3b7f10('0x18')],qs[_0x3b7f10('0x2f')](_0x235dc8[_0x3b7f10('0x20')][_0x3b7f10('0x2f')])),_0x38db38[_0x3b7f10('0x2a')]=_0x38db38[_0x3b7f10('0x2a')][_0x3b7f10('0xc')]?_0x38db38[_0x3b7f10('0x2a')]:_0x4f0f89[_0x3b7f10('0x18')];typeof _0x235dc8[_0x3b7f10('0x20')][_0x3b7f10('0x8')]==='undefined'&&(_0x38db38[_0x3b7f10('0x1')]=qs[_0x3b7f10('0x1')](_0x235dc8[_0x3b7f10('0x20')][_0x3b7f10('0x1')]),_0x38db38[_0x3b7f10('0x2d')]=qs[_0x3b7f10('0x2d')](_0x235dc8['query']['offset']));_0x38db38['order']=qs['sort'](_0x235dc8[_0x3b7f10('0x20')]['sort']),_0x38db38[_0x3b7f10('0x24')]=qs[_0x3b7f10('0x4')](_[_0x3b7f10('0x1a')](_0x235dc8[_0x3b7f10('0x20')],_0x4f0f89[_0x3b7f10('0x4')]),_0x475a35);_0x235dc8['query']['filter']&&(_0x38db38[_0x3b7f10('0x24')]=_[_0x3b7f10('0x23')](_0x38db38[_0x3b7f10('0x24')],{[Op['or']]:_['map'](_0x475a35,function(_0x17b0c1){const _0x45a7fa=_0x3b7f10;if(_0x17b0c1[_0x45a7fa('0x1d')]!=='VIRTUAL'){const _0x5ce5d2={};return _0x5ce5d2[_0x17b0c1[_0x45a7fa('0x1f')]]={[Op['like']]:'%'+_0x235dc8[_0x45a7fa('0x20')][_0x45a7fa('0xd')]+'%'},_0x5ce5d2;}})}));_0x38db38=_[_0x3b7f10('0x23')]({},_0x38db38,_0x235dc8[_0x3b7f10('0x2')]);const _0x5520a0={'where':_0x38db38[_0x3b7f10('0x24')]};return db[_0x3b7f10('0x29')][_0x3b7f10('0x19')](_0x5520a0)[_0x3b7f10('0xb')](function(_0x15e17a){const _0x4f73c5=_0x3b7f10;return _0x299f4b[_0x4f73c5('0x19')]=_0x15e17a,_0x235dc8[_0x4f73c5('0x20')]['includeAll']&&(_0x38db38[_0x4f73c5('0x2c')]=[{'all':!![]}]),db[_0x4f73c5('0x29')][_0x4f73c5('0x10')](_0x38db38);})[_0x3b7f10('0xb')](function(_0x3772f9){const _0x10a297=_0x3b7f10;return _0x299f4b[_0x10a297('0x16')]=_0x3772f9,_0x299f4b;})[_0x3b7f10('0xb')](respondWithFilteredResult(_0x2c7841,_0x38db38))[_0x3b7f10('0x2b')](handleError(_0x2c7841,null));},exports[_0x37c568('0x1e')]=function(_0x1d34a5,_0x4c410e){const _0x56ba03=_0x37c568;let _0x489730={'raw':!![],'where':{'id':_0x1d34a5[_0x56ba03('0x6')]['id']}};const _0x4a1c56={};return _0x4a1c56[_0x56ba03('0x18')]=_[_0x56ba03('0xe')](db[_0x56ba03('0x29')][_0x56ba03('0x0')]),_0x4a1c56[_0x56ba03('0x20')]=_[_0x56ba03('0xe')](_0x1d34a5[_0x56ba03('0x20')]),_0x4a1c56[_0x56ba03('0x4')]=_[_0x56ba03('0x22')](_0x4a1c56['model'],_0x4a1c56[_0x56ba03('0x20')]),_0x489730[_0x56ba03('0x2a')]=_[_0x56ba03('0x22')](_0x4a1c56[_0x56ba03('0x18')],qs[_0x56ba03('0x2f')](_0x1d34a5[_0x56ba03('0x20')][_0x56ba03('0x2f')])),_0x489730['attributes']=_0x489730[_0x56ba03('0x2a')]['length']?_0x489730['attributes']:_0x4a1c56['model'],_0x1d34a5[_0x56ba03('0x20')][_0x56ba03('0x11')]&&(_0x489730[_0x56ba03('0x2c')]=[{'all':!![]}]),_0x489730=_[_0x56ba03('0x23')]({},_0x489730,_0x1d34a5['options']),db['VoiceTransferReport']['findOne'](_0x489730)[_0x56ba03('0xb')](handleEntityNotFound(_0x4c410e,null))[_0x56ba03('0xb')](respondWithResult(_0x4c410e,null))[_0x56ba03('0x2b')](handleError(_0x4c410e,null));},exports[_0x37c568('0x3')]=function(_0x32e054,_0xa5c537){const _0x3f5718=_0x37c568;return db[_0x3f5718('0x29')][_0x3f5718('0x3')](_0x32e054[_0x3f5718('0x1c')],{})[_0x3f5718('0xb')](respondWithResult(_0xa5c537,0xc9))['catch'](handleError(_0xa5c537,null));},exports[_0x37c568('0x1b')]=function(_0x1edc04,_0x226cb7){const _0x50e943=_0x37c568;return _0x1edc04[_0x50e943('0x1c')]['id']&&delete _0x1edc04[_0x50e943('0x1c')]['id'],db['VoiceTransferReport'][_0x50e943('0xf')]({'where':{'id':_0x1edc04[_0x50e943('0x6')]['id']}})[_0x50e943('0xb')](handleEntityNotFound(_0x226cb7,null))['then'](saveUpdates(_0x1edc04[_0x50e943('0x1c')],null))[_0x50e943('0xb')](respondWithResult(_0x226cb7,null))[_0x50e943('0x2b')](handleError(_0x226cb7,null));},exports[_0x37c568('0x17')]=function(_0x56662c,_0x352ad5){const _0x5390ed=_0x37c568;return db[_0x5390ed('0x29')][_0x5390ed('0xf')]({'where':{'id':_0x56662c[_0x5390ed('0x6')]['id']}})[_0x5390ed('0xb')](handleEntityNotFound(_0x352ad5,null))['then'](removeEntity(_0x352ad5,null))[_0x5390ed('0x2b')](handleError(_0x352ad5,null));}; \ No newline at end of file diff --git a/server/api/voiceTransferReport/voiceTransferReport.model.js b/server/api/voiceTransferReport/voiceTransferReport.model.js index 883efcd..3b60114 100644 --- a/server/api/voiceTransferReport/voiceTransferReport.model.js +++ b/server/api/voiceTransferReport/voiceTransferReport.model.js @@ -1 +1 @@ -const a777_0x44b8=['exports','VoiceTransferReport','report_call_transfer','./voiceTransferReport.attributes'];(function(_0x17a5e3,_0x44b87a){const _0x5aa059=function(_0x170988){while(--_0x170988){_0x17a5e3['push'](_0x17a5e3['shift']());}};_0x5aa059(++_0x44b87a);}(a777_0x44b8,0xc6));const a777_0x5aa0=function(_0x17a5e3,_0x44b87a){_0x17a5e3=_0x17a5e3-0x0;let _0x5aa059=a777_0x44b8[_0x17a5e3];return _0x5aa059;};const _0x1c5973=a777_0x5aa0;'use strict';const attributes=require(_0x1c5973('0x1'));module[_0x1c5973('0x2')]=function(_0x170988){const _0x259c40=_0x1c5973,_0x4ac167=_0x170988['define'](_0x259c40('0x3'),attributes,{'tableName':_0x259c40('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x4ac167;}; \ No newline at end of file +const a777_0x57ab=['report_call_transfer','VoiceTransferReport','define'];(function(_0x5b085a,_0x57abb4){const _0x53b0a7=function(_0x5a9c40){while(--_0x5a9c40){_0x5b085a['push'](_0x5b085a['shift']());}};_0x53b0a7(++_0x57abb4);}(a777_0x57ab,0xdd));const a777_0x53b0=function(_0x5b085a,_0x57abb4){_0x5b085a=_0x5b085a-0x0;let _0x53b0a7=a777_0x57ab[_0x5b085a];return _0x53b0a7;};'use strict';const attributes=require('./voiceTransferReport.attributes');module['exports']=function(_0x5a9c40){const _0x5c52f6=a777_0x53b0,_0x550c91=_0x5a9c40[_0x5c52f6('0x0')](_0x5c52f6('0x2'),attributes,{'tableName':_0x5c52f6('0x1'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x550c91;}; \ No newline at end of file diff --git a/server/api/voiceTransferReport/voiceTransferReport.rpc.js b/server/api/voiceTransferReport/voiceTransferReport.rpc.js index 50440a0..03259bb 100644 --- a/server/api/voiceTransferReport/voiceTransferReport.rpc.js +++ b/server/api/voiceTransferReport/voiceTransferReport.rpc.js @@ -1 +1 @@ -const a778_0x47f1=['VoiceTransferReport','options','debug','stringify','rpc','CreateVoiceTransferReport','message','raw','catch','info','then','body','../../config/logger','error','create'];(function(_0xf40204,_0x47f1b3){const _0x18228a=function(_0x2961e9){while(--_0x2961e9){_0xf40204['push'](_0xf40204['shift']());}};_0x18228a(++_0x47f1b3);}(a778_0x47f1,0x1f1));const a778_0x1822=function(_0xf40204,_0x47f1b3){_0xf40204=_0xf40204-0x0;let _0x18228a=a778_0x47f1[_0xf40204];return _0x18228a;};const _0x36e490=a778_0x1822;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x36e490('0xa'))(_0x36e490('0x2'));exports[_0x36e490('0x3')]=function(_0x2961e9){const _0x1327cb=this;return new Promise(function(_0x1d1bba,_0x140cc4){const _0x23e75d=a778_0x1822;return db[_0x23e75d('0xd')][_0x23e75d('0xc')](_0x2961e9[_0x23e75d('0x9')],{'raw':_0x2961e9['options']?_0x2961e9[_0x23e75d('0xe')][_0x23e75d('0x5')]===undefined?!![]:![]:!![]})[_0x23e75d('0x8')](function(_0x57e8f8){const _0x139d02=_0x23e75d;logger[_0x139d02('0x7')](_0x139d02('0x3'),_0x2961e9),logger[_0x139d02('0x0')](_0x139d02('0x3'),_0x2961e9,JSON[_0x139d02('0x1')](_0x57e8f8)),_0x1d1bba(_0x57e8f8);})[_0x23e75d('0x6')](function(_0x412500){const _0x19c8d4=_0x23e75d;logger[_0x19c8d4('0xb')]('CreateVoiceTransferReport',_0x412500[_0x19c8d4('0x4')],_0x2961e9),_0x140cc4(_0x1327cb['error'](0x1f4,_0x412500[_0x19c8d4('0x4')]));});});}; \ No newline at end of file +const a778_0x11ba=['../../mysqldb','message','catch','then','CreateVoiceTransferReport','stringify','options','debug','../../config/logger','info','body','error'];(function(_0xdc181d,_0x11ba72){const _0x2c1e82=function(_0x20b4eb){while(--_0x20b4eb){_0xdc181d['push'](_0xdc181d['shift']());}};_0x2c1e82(++_0x11ba72);}(a778_0x11ba,0xf2));const a778_0x2c1e=function(_0xdc181d,_0x11ba72){_0xdc181d=_0xdc181d-0x0;let _0x2c1e82=a778_0x11ba[_0xdc181d];return _0x2c1e82;};const _0x4c5ad2=a778_0x2c1e;'use strict';const db=require(_0x4c5ad2('0xa'))['db'],logger=require(_0x4c5ad2('0x6'))('rpc');exports[_0x4c5ad2('0x2')]=function(_0x20b4eb){const _0x4c787a=this;return new Promise(function(_0xeb8b58,_0x1d3c53){const _0x2ba646=a778_0x2c1e;return db['VoiceTransferReport']['create'](_0x20b4eb[_0x2ba646('0x8')],{'raw':_0x20b4eb[_0x2ba646('0x4')]?_0x20b4eb[_0x2ba646('0x4')]['raw']===undefined?!![]:![]:!![]})[_0x2ba646('0x1')](function(_0x8679a0){const _0x2e0774=_0x2ba646;logger[_0x2e0774('0x7')]('CreateVoiceTransferReport',_0x20b4eb),logger[_0x2e0774('0x5')](_0x2e0774('0x2'),_0x20b4eb,JSON[_0x2e0774('0x3')](_0x8679a0)),_0xeb8b58(_0x8679a0);})[_0x2ba646('0x0')](function(_0x479d74){const _0x35c983=_0x2ba646;logger[_0x35c983('0x9')](_0x35c983('0x2'),_0x479d74[_0x35c983('0xb')],_0x20b4eb),_0x1d3c53(_0x4c787a[_0x35c983('0x9')](0x1f4,_0x479d74[_0x35c983('0xb')]));});});}; \ No newline at end of file diff --git a/server/api/webbar/index.js b/server/api/webbar/index.js index 7d1c241..de78a0a 100644 --- a/server/api/webbar/index.js +++ b/server/api/webbar/index.js @@ -1 +1 @@ -const a779_0x32b8=['/unhold','isAuthenticated','unhold','hold','/hold','post','originate','transfer','/originate','hangup','Router','/transfer','/answer','./webbar.controller','answer','calls','../../components/auth/service','canUpdate','exports'];(function(_0x52c346,_0x32b85f){const _0xde530e=function(_0x494599){while(--_0x494599){_0x52c346['push'](_0x52c346['shift']());}};_0xde530e(++_0x32b85f);}(a779_0x32b8,0x138));const a779_0xde53=function(_0x52c346,_0x32b85f){_0x52c346=_0x52c346-0x0;let _0xde530e=a779_0x32b8[_0x52c346];return _0xde530e;};const _0xdf1449=a779_0xde53;'use strict';const express=require('express'),router=express[_0xdf1449('0x2')](),auth=require(_0xdf1449('0x8')),controller=require(_0xdf1449('0x5'));router['post'](_0xdf1449('0x0'),auth['isAuthenticated'](),auth[_0xdf1449('0x9')](),controller[_0xdf1449('0x11')]),router[_0xdf1449('0x10')]('/hangup',auth[_0xdf1449('0xc')](),auth[_0xdf1449('0x9')](),controller[_0xdf1449('0x1')]),router['post'](_0xdf1449('0x4'),auth[_0xdf1449('0xc')](),auth[_0xdf1449('0x9')](),controller[_0xdf1449('0x6')]),router[_0xdf1449('0x10')](_0xdf1449('0xf'),auth['isAuthenticated'](),auth[_0xdf1449('0x9')](),controller[_0xdf1449('0xe')]),router[_0xdf1449('0x10')](_0xdf1449('0xb'),auth[_0xdf1449('0xc')](),auth['canUpdate'](),controller[_0xdf1449('0xd')]),router[_0xdf1449('0x10')]('/calls',auth['isAuthenticated'](),auth[_0xdf1449('0x9')](),controller[_0xdf1449('0x7')]),router[_0xdf1449('0x10')](_0xdf1449('0x3'),auth[_0xdf1449('0xc')](),auth[_0xdf1449('0x9')](),controller[_0xdf1449('0x12')]),module[_0xdf1449('0xa')]=router; \ No newline at end of file +const a779_0x3dd9=['originate','/unhold','hold','./webbar.controller','/originate','transfer','canUpdate','unhold','/answer','/hold','hangup','../../components/auth/service','calls','express','isAuthenticated','/transfer','post','exports','answer'];(function(_0x560873,_0x3dd992){const _0x11740a=function(_0xaec9fe){while(--_0xaec9fe){_0x560873['push'](_0x560873['shift']());}};_0x11740a(++_0x3dd992);}(a779_0x3dd9,0x137));const a779_0x1174=function(_0x560873,_0x3dd992){_0x560873=_0x560873-0x0;let _0x11740a=a779_0x3dd9[_0x560873];return _0x11740a;};const _0x5bba33=a779_0x1174;'use strict';const express=require(_0x5bba33('0x6')),router=express['Router'](),auth=require(_0x5bba33('0x4')),controller=require(_0x5bba33('0xf'));router[_0x5bba33('0x9')](_0x5bba33('0x10'),auth['isAuthenticated'](),auth[_0x5bba33('0x12')](),controller[_0x5bba33('0xc')]),router['post']('/hangup',auth[_0x5bba33('0x7')](),auth[_0x5bba33('0x12')](),controller[_0x5bba33('0x3')]),router[_0x5bba33('0x9')](_0x5bba33('0x1'),auth['isAuthenticated'](),auth[_0x5bba33('0x12')](),controller[_0x5bba33('0xb')]),router[_0x5bba33('0x9')](_0x5bba33('0x2'),auth[_0x5bba33('0x7')](),auth[_0x5bba33('0x12')](),controller[_0x5bba33('0xe')]),router[_0x5bba33('0x9')](_0x5bba33('0xd'),auth[_0x5bba33('0x7')](),auth[_0x5bba33('0x12')](),controller[_0x5bba33('0x0')]),router['post']('/calls',auth[_0x5bba33('0x7')](),auth[_0x5bba33('0x12')](),controller[_0x5bba33('0x5')]),router['post'](_0x5bba33('0x8'),auth[_0x5bba33('0x7')](),auth[_0x5bba33('0x12')](),controller[_0x5bba33('0x11')]),module[_0x5bba33('0xa')]=router; \ No newline at end of file diff --git a/server/api/webbar/webbar.controller.js b/server/api/webbar/webbar.controller.js index 37006a9..ba52c2a 100644 --- a/server/api/webbar/webbar.controller.js +++ b/server/api/webbar/webbar.controller.js @@ -1 +1 @@ -const a780_0x3047=['handleError:','transfer','webbar:answer','userId\x20is\x20required','message','UserId','../../mysqldb','catch','webbar:conference','user:%s','findOne','calls','hold\x20fired:','NotFound','status','originate\x20executed!','send','userId','unhold','transferNumber\x20is\x20required','entityFound:','User','calls\x20fired:','transfer\x20fired:','length','error','../../rediscache','hangup\x20fired:','result','transferNumber','number','http','emit','hold','json','unhold\x20fired:','hold\x20executed!','util','code','jayson/promise','stringify','answer\x20executed!','log','filter','webbarapi','hangup\x20executed!','conference','format','sessionId','originate','hangup','sessionId\x20is\x20required','webbar:transfer','validate','then','agent','info','rows','answer','callbackUrl','callNumber\x20is\x20required','lodash','name','stack','body','VoiceChannels','string','originate\x20fired:'];(function(_0x496e24,_0x304724){const _0xfa93a5=function(_0x52d35c){while(--_0x52d35c){_0x496e24['push'](_0x496e24['shift']());}};_0xfa93a5(++_0x304724);}(a780_0x3047,0x191));const a780_0xfa93=function(_0x496e24,_0x304724){_0x496e24=_0x496e24-0x0;let _0xfa93a5=a780_0x3047[_0x496e24];return _0xfa93a5;};const _0x494474=a780_0xfa93;'use strict';const _=require(_0x494474('0x0')),db=require(_0x494474('0xd'))['db'],util=require(_0x494474('0x2c')),jayson=require(_0x494474('0x2e')),amiClient=jayson['client'][_0x494474('0x26')]({'port':0x232a}),logger=require('../../config/logger')(_0x494474('0x33')),{getSocket}=require(_0x494474('0x21')),io=getSocket(),Schema=require(_0x494474('0x3c')),originateValidation=new Schema({'userId':{'type':_0x494474('0x25'),'required':[!![],_0x494474('0xa')]},'callNumber':{'type':'string','required':[!![],_0x494474('0x43')]},'callerId':{'type':_0x494474('0x5')},'callbackUrl':{'type':_0x494474('0x5')}}),hangupValidation=new Schema({'userId':{'type':'number','required':[!![],_0x494474('0xa')]},'sessionId':{'type':_0x494474('0x5'),'required':![]}}),answerValidation=new Schema({'userId':{'type':_0x494474('0x25'),'required':[!![],_0x494474('0xa')]},'sessionId':{'type':_0x494474('0x5'),'required':![]}}),transferValidation=new Schema({'userId':{'type':_0x494474('0x25'),'required':[!![],_0x494474('0xa')]},'sessionId':{'type':_0x494474('0x5'),'required':[!![],_0x494474('0x3a')]},'transferNumber':{'type':_0x494474('0x5'),'required':[!![],_0x494474('0x1a')]}}),holdValidation=new Schema({'userId':{'type':_0x494474('0x25'),'required':[!![],_0x494474('0xa')]},'sessionId':{'type':_0x494474('0x5'),'required':![]}}),unholdValidation=new Schema({'userId':{'type':_0x494474('0x25'),'required':[!![],_0x494474('0xa')]},'sessionId':{'type':_0x494474('0x5'),'required':![]}}),callsValidation=new Schema({'userId':{'type':_0x494474('0x25'),'required':[!![],_0x494474('0xa')]}}),conferenceValidation=new Schema({'userId':{'type':'number','required':[!![],_0x494474('0xa')]}});function emit(_0x52d35c,_0x5e78bc,_0x426f9b){const _0x3348c7=_0x494474;logger[_0x3348c7('0x3f')](_0x52d35c,_0x5e78bc,JSON[_0x3348c7('0x2f')](_0x426f9b)),io['to'](_0x52d35c)[_0x3348c7('0x27')](_0x5e78bc,_0x426f9b);}function handleError(_0x2c9b70){return function(_0x4b36c3){const _0x582dfb=a780_0xfa93;console[_0x582dfb('0x31')](_0x582dfb('0x7'),_0x4b36c3,_0x4b36c3 instanceof RangeError),logger[_0x582dfb('0x20')](_0x4b36c3[_0x582dfb('0x2')]),_0x4b36c3 instanceof RangeError?(_0x4b36c3[_0x582dfb('0x1')]&&delete _0x4b36c3[_0x582dfb('0x1')],_0x2c9b70['status'](0x194)[_0x582dfb('0x17')](_0x4b36c3)):(_0x4b36c3[_0x582dfb('0x1')]&&delete _0x4b36c3[_0x582dfb('0x1')],_0x2c9b70['status'](0x1f4)[_0x582dfb('0x17')](_0x4b36c3));};}function checkError(){return function(_0x3618c8){const _0x1cd2f7=a780_0xfa93;if(!_0x3618c8)throw new RangeError(_0x1cd2f7('0x14'));return _0x3618c8;};}function respondWithRpcPromise(_0xb93571,_0x354fd1){return new Promise(function(_0x119c76,_0x1c822b){const _0x42a1dd=a780_0xfa93,_0x479bdd=amiClient;return _0x479bdd['request'](_0xb93571,_0x354fd1)['then'](function(_0x3b486b){const _0x3e591f=a780_0xfa93;if(_0x3b486b['error']){if(_0x3b486b[_0x3e591f('0x20')][_0x3e591f('0x2d')]===0x1f4)return _0x1c822b(_0x3b486b['error'][_0x3e591f('0xb')]);return _0x119c76(_0x3b486b[_0x3e591f('0x20')]['message']);}else _0x119c76(_0x3b486b[_0x3e591f('0x23')]);})[_0x42a1dd('0xe')](function(_0x8b9f61){_0x1c822b(_0x8b9f61);});});}function getAgent(_0x35880a){const _0x35dced=_0x494474;return db[_0x35dced('0x1c')][_0x35dced('0x11')]({'where':{'id':_0x35880a,'role':_0x35dced('0x3e')}})[_0x35dced('0x3d')](checkError());}exports[_0x494474('0x38')]=function(_0x5749c7,_0x12f49f){const _0xd28b10=_0x494474;logger[_0xd28b10('0x3f')](_0xd28b10('0x6'),_0x5749c7[_0xd28b10('0x3')]);const _0x656ddb=originateValidation[_0xd28b10('0x3c')](_0x5749c7[_0xd28b10('0x3')]);if(_0x656ddb[_0xd28b10('0x1f')]>0x0)return _0x12f49f[_0xd28b10('0x15')](0x190)['json'](_0x656ddb);const _0x4230c0=_0x5749c7[_0xd28b10('0x3')][_0xd28b10('0x18')],_0x13ea30=_0x5749c7[_0xd28b10('0x3')]['callNumber'],_0x533a06=_0x5749c7[_0xd28b10('0x3')]['callerId'],_0x555109=_0x5749c7[_0xd28b10('0x3')][_0xd28b10('0x42')];return getAgent(_0x4230c0)[_0xd28b10('0x3d')](function(_0x586169){const _0x349408=_0xd28b10;return logger[_0x349408('0x3f')](_0x349408('0x1b'),_0x586169[_0x349408('0x1')]),emit(util[_0x349408('0x36')](_0x349408('0x10'),_0x586169[_0x349408('0x1')]),'webbar:originate',{'callNumber':_0x13ea30,'callerId':_0x533a06,'callbackUrl':_0x555109}),_0x12f49f[_0x349408('0x15')](0xc8)[_0x349408('0x29')]({'error':![],'message':_0x349408('0x16')});})['catch'](handleError(_0x12f49f));},exports[_0x494474('0x39')]=function(_0x113bba,_0xf8f62){const _0x91b43f=_0x494474;logger[_0x91b43f('0x3f')](_0x91b43f('0x22'),_0x113bba[_0x91b43f('0x3')]);const _0x523019=hangupValidation['validate'](_0x113bba['body']);if(_0x523019[_0x91b43f('0x1f')]>0x0)return _0xf8f62['status'](0x190)[_0x91b43f('0x29')](_0x523019);const _0x24563b=_0x113bba[_0x91b43f('0x3')]['userId'],_0x101eaa=_0x113bba['body'][_0x91b43f('0x37')];return getAgent(_0x24563b)['then'](function(_0x3f058c){const _0x556a36=_0x91b43f;return logger[_0x556a36('0x3f')]('entityFound:',_0x3f058c[_0x556a36('0x1')]),emit(util['format']('user:%s',_0x3f058c[_0x556a36('0x1')]),'webbar:hangup',{'sessionId':_0x101eaa}),_0xf8f62['status'](0xc8)[_0x556a36('0x29')]({'error':![],'message':_0x556a36('0x34')});})['catch'](handleError(_0xf8f62));},exports[_0x494474('0x41')]=function(_0x417b4e,_0x29a021){const _0x1f4d70=_0x494474;logger[_0x1f4d70('0x3f')]('answer\x20fired:',_0x417b4e[_0x1f4d70('0x3')]);const _0x3eeda1=answerValidation[_0x1f4d70('0x3c')](_0x417b4e[_0x1f4d70('0x3')]);if(_0x3eeda1['length']>0x0)return _0x29a021[_0x1f4d70('0x15')](0x190)['json'](_0x3eeda1);const _0x562b12=_0x417b4e['body'][_0x1f4d70('0x18')],_0x309488=_0x417b4e[_0x1f4d70('0x3')]['sessionId'];return getAgent(_0x562b12)[_0x1f4d70('0x3d')](function(_0x171e28){const _0x3f7dda=_0x1f4d70;return logger[_0x3f7dda('0x3f')]('entityFound:',_0x171e28[_0x3f7dda('0x1')]),emit(util[_0x3f7dda('0x36')](_0x3f7dda('0x10'),_0x171e28[_0x3f7dda('0x1')]),_0x3f7dda('0x9'),{'sessionId':_0x309488}),_0x29a021[_0x3f7dda('0x15')](0xc8)[_0x3f7dda('0x29')]({'error':![],'message':_0x3f7dda('0x30')});})[_0x1f4d70('0xe')](handleError(_0x29a021));},exports[_0x494474('0x28')]=function(_0x188e2f,_0x36d8eb){const _0x3791bc=_0x494474;logger['info'](_0x3791bc('0x13'),_0x188e2f[_0x3791bc('0x3')]);const _0x264a60=holdValidation[_0x3791bc('0x3c')](_0x188e2f[_0x3791bc('0x3')]);if(_0x264a60['length']>0x0)return _0x36d8eb['status'](0x190)[_0x3791bc('0x29')](_0x264a60);const _0x3df5f2=_0x188e2f[_0x3791bc('0x3')][_0x3791bc('0x18')],_0x12ae18=_0x188e2f[_0x3791bc('0x3')][_0x3791bc('0x37')];return getAgent(_0x3df5f2)[_0x3791bc('0x3d')](function(_0x1fd36d){const _0x314dab=_0x3791bc;return logger['info'](_0x314dab('0x1b'),_0x1fd36d[_0x314dab('0x1')]),emit(util[_0x314dab('0x36')]('user:%s',_0x1fd36d['name']),'webbar:hold',{'sessionId':_0x12ae18}),_0x36d8eb[_0x314dab('0x15')](0xc8)[_0x314dab('0x29')]({'error':![],'message':_0x314dab('0x2b')});})[_0x3791bc('0xe')](handleError(_0x36d8eb));},exports[_0x494474('0x19')]=function(_0x31da70,_0x290168){const _0x2c99dd=_0x494474;logger['info'](_0x2c99dd('0x2a'),_0x31da70['body']);const _0x449f0a=unholdValidation['validate'](_0x31da70[_0x2c99dd('0x3')]);if(_0x449f0a[_0x2c99dd('0x1f')]>0x0)return _0x290168[_0x2c99dd('0x15')](0x190)[_0x2c99dd('0x29')](_0x449f0a);const _0x25d561=_0x31da70[_0x2c99dd('0x3')][_0x2c99dd('0x18')],_0xe66d37=_0x31da70[_0x2c99dd('0x3')][_0x2c99dd('0x37')];return getAgent(_0x25d561)['then'](function(_0x1cd0b6){const _0x1de0b9=_0x2c99dd;return logger['info'](_0x1de0b9('0x1b'),_0x1cd0b6[_0x1de0b9('0x1')]),emit(util[_0x1de0b9('0x36')]('user:%s',_0x1cd0b6[_0x1de0b9('0x1')]),'webbar:unhold',{'sessionId':_0xe66d37}),_0x290168[_0x1de0b9('0x15')](0xc8)[_0x1de0b9('0x29')]({'error':![],'message':'unhold\x20executed!'});})[_0x2c99dd('0xe')](handleError(_0x290168));},exports[_0x494474('0x12')]=function(_0x582a95,_0x82f158){const _0x5d5c5d=_0x494474;logger[_0x5d5c5d('0x3f')](_0x5d5c5d('0x1d'),_0x82f158[_0x5d5c5d('0x3')]);const _0x23e4a6=callsValidation[_0x5d5c5d('0x3c')](_0x582a95[_0x5d5c5d('0x3')]);if(_0x23e4a6['length']>0x0)return _0x82f158[_0x5d5c5d('0x15')](0x190)[_0x5d5c5d('0x29')](_0x23e4a6);const _0x2419a2=_0x582a95['body'][_0x5d5c5d('0x18')],_0x1c486e=respondWithRpcPromise(_0x5d5c5d('0x4')),_0x4f392c=getAgent(_0x2419a2);return Promise['all']([_0x1c486e,_0x4f392c])[_0x5d5c5d('0x3d')](function(_0x955503){const _0x277f29=_0x5d5c5d,_0xa146d0=_0x955503[0x0],_0x1a5d01=_0x955503[0x1],_0x555d6f=_[_0x277f29('0x32')](_0xa146d0[_0x277f29('0x40')],function(_0x39cc90){const _0x460780=_0x277f29;return _0x39cc90[_0x460780('0xc')]==_0x1a5d01['id'];});return _0x82f158[_0x277f29('0x15')](0xc8)[_0x277f29('0x29')]({'count':_0x555d6f[_0x277f29('0x1f')],'rows':_0x555d6f});})[_0x5d5c5d('0xe')](handleError(_0x82f158));},exports[_0x494474('0x35')]=function(_0x4f43be,_0x594769){const _0x1d7ba9=_0x494474;logger[_0x1d7ba9('0x3f')]('conference\x20fired:',_0x4f43be['body']);const _0x5226b3=conferenceValidation[_0x1d7ba9('0x3c')](_0x4f43be[_0x1d7ba9('0x3')]);if(_0x5226b3[_0x1d7ba9('0x1f')]>0x0)return _0x594769[_0x1d7ba9('0x15')](0x190)[_0x1d7ba9('0x29')](_0x5226b3);const _0xb21704=_0x4f43be['body'][_0x1d7ba9('0x18')];return getAgent(_0xb21704)['then'](function(_0x4574f6){const _0x1200ad=_0x1d7ba9;return logger[_0x1200ad('0x3f')]('entityFound:',_0x4574f6['name']),emit(util['format'](_0x1200ad('0x10'),_0x4574f6[_0x1200ad('0x1')]),_0x1200ad('0xf')),_0x594769[_0x1200ad('0x15')](0xc8)['json']({'error':![],'message':'conference\x20executed!'});})[_0x1d7ba9('0xe')](handleError(_0x594769));},exports[_0x494474('0x8')]=function(_0x22854e,_0xe583be){const _0x5b5897=_0x494474;logger[_0x5b5897('0x3f')](_0x5b5897('0x1e'),_0x22854e['body']);const _0xde0684=transferValidation['validate'](_0x22854e[_0x5b5897('0x3')]);if(_0xde0684[_0x5b5897('0x1f')]>0x0)return _0xe583be[_0x5b5897('0x15')](0x190)[_0x5b5897('0x29')](_0xde0684);const _0x5dca1d=_0x22854e[_0x5b5897('0x3')][_0x5b5897('0x18')],_0x268852=_0x22854e[_0x5b5897('0x3')][_0x5b5897('0x37')],_0x107469=_0x22854e[_0x5b5897('0x3')][_0x5b5897('0x24')];return getAgent(_0x5dca1d)[_0x5b5897('0x3d')](function(_0x2fa0b7){const _0x21801c=_0x5b5897;return logger['info'](_0x21801c('0x1b'),_0x2fa0b7['name']),emit(util['format'](_0x21801c('0x10'),_0x2fa0b7[_0x21801c('0x1')]),_0x21801c('0x3b'),{'sessionId':_0x268852,'transferNumber':_0x107469}),_0xe583be[_0x21801c('0x15')](0xc8)[_0x21801c('0x29')]({'error':![],'message':'transfer\x20executed!'});})[_0x5b5897('0xe')](handleError(_0xe583be));}; \ No newline at end of file +const a780_0xbde1=['originate\x20fired:','emit','calls\x20fired:','webbar:hold','length','webbarapi','NotFound','../../rediscache','util','name','answer\x20fired:','sessionId\x20is\x20required','findOne','http','entityFound:','agent','callerId','UserId','string','transfer\x20fired:','webbar:unhold','transfer','hangup','body','filter','transfer\x20executed!','hold\x20executed!','jayson/promise','answer','sessionId','conference\x20executed!','userId\x20is\x20required','handleError:','request','unhold','answer\x20executed!','info','userId','transferNumber','json','User','../../mysqldb','../../config/logger','error','catch','hangup\x20fired:','callbackUrl','lodash','validate','client','user:%s','webbar:answer','then','all','format','webbar:transfer','webbar:originate','send','status','message','transferNumber\x20is\x20required','number','calls','result','hold\x20fired:','stack','callNumber\x20is\x20required','unhold\x20fired:'];(function(_0x2305db,_0xbde1f6){const _0x4ccae1=function(_0x4e47b2){while(--_0x4e47b2){_0x2305db['push'](_0x2305db['shift']());}};_0x4ccae1(++_0xbde1f6);}(a780_0xbde1,0x1f2));const a780_0x4cca=function(_0x2305db,_0xbde1f6){_0x2305db=_0x2305db-0x0;let _0x4ccae1=a780_0xbde1[_0x2305db];return _0x4ccae1;};const _0x48f048=a780_0x4cca;'use strict';const _=require(_0x48f048('0x19')),db=require(_0x48f048('0x13'))['db'],util=require(_0x48f048('0x36')),jayson=require(_0x48f048('0x5')),amiClient=jayson[_0x48f048('0x1b')][_0x48f048('0x3b')]({'port':0x232a}),logger=require(_0x48f048('0x14'))(_0x48f048('0x33')),{getSocket}=require(_0x48f048('0x35')),io=getSocket(),Schema=require(_0x48f048('0x1a')),originateValidation=new Schema({'userId':{'type':_0x48f048('0x27'),'required':[!![],_0x48f048('0x9')]},'callNumber':{'type':'string','required':[!![],_0x48f048('0x2c')]},'callerId':{'type':_0x48f048('0x40')},'callbackUrl':{'type':_0x48f048('0x40')}}),hangupValidation=new Schema({'userId':{'type':'number','required':[!![],_0x48f048('0x9')]},'sessionId':{'type':_0x48f048('0x40'),'required':![]}}),answerValidation=new Schema({'userId':{'type':'number','required':[!![],'userId\x20is\x20required']},'sessionId':{'type':_0x48f048('0x40'),'required':![]}}),transferValidation=new Schema({'userId':{'type':'number','required':[!![],_0x48f048('0x9')]},'sessionId':{'type':'string','required':[!![],_0x48f048('0x39')]},'transferNumber':{'type':'string','required':[!![],_0x48f048('0x26')]}}),holdValidation=new Schema({'userId':{'type':_0x48f048('0x27'),'required':[!![],'userId\x20is\x20required']},'sessionId':{'type':'string','required':![]}}),unholdValidation=new Schema({'userId':{'type':'number','required':[!![],'userId\x20is\x20required']},'sessionId':{'type':_0x48f048('0x40'),'required':![]}}),callsValidation=new Schema({'userId':{'type':_0x48f048('0x27'),'required':[!![],_0x48f048('0x9')]}}),conferenceValidation=new Schema({'userId':{'type':_0x48f048('0x27'),'required':[!![],_0x48f048('0x9')]}});function emit(_0x4e47b2,_0xea4e5e,_0x5571ee){const _0x408bd3=_0x48f048;logger[_0x408bd3('0xe')](_0x4e47b2,_0xea4e5e,JSON['stringify'](_0x5571ee)),io['to'](_0x4e47b2)[_0x408bd3('0x2f')](_0xea4e5e,_0x5571ee);}function handleError(_0xd92ed5){return function(_0x10b9e5){const _0x31a2df=a780_0x4cca;console['log'](_0x31a2df('0xa'),_0x10b9e5,_0x10b9e5 instanceof RangeError),logger['error'](_0x10b9e5[_0x31a2df('0x2b')]),_0x10b9e5 instanceof RangeError?(_0x10b9e5[_0x31a2df('0x37')]&&delete _0x10b9e5['name'],_0xd92ed5['status'](0x194)[_0x31a2df('0x23')](_0x10b9e5)):(_0x10b9e5[_0x31a2df('0x37')]&&delete _0x10b9e5[_0x31a2df('0x37')],_0xd92ed5['status'](0x1f4)['send'](_0x10b9e5));};}function checkError(){return function(_0x40d053){const _0x1bc96c=a780_0x4cca;if(!_0x40d053)throw new RangeError(_0x1bc96c('0x34'));return _0x40d053;};}function respondWithRpcPromise(_0x20754a,_0x297893){return new Promise(function(_0x56a09c,_0x54ed11){const _0x2c7519=a780_0x4cca,_0x24e445=amiClient;return _0x24e445[_0x2c7519('0xb')](_0x20754a,_0x297893)['then'](function(_0x1accde){const _0x300bb8=_0x2c7519;if(_0x1accde[_0x300bb8('0x15')]){if(_0x1accde[_0x300bb8('0x15')]['code']===0x1f4)return _0x54ed11(_0x1accde['error']['message']);return _0x56a09c(_0x1accde[_0x300bb8('0x15')][_0x300bb8('0x25')]);}else _0x56a09c(_0x1accde[_0x300bb8('0x29')]);})[_0x2c7519('0x16')](function(_0x12a42e){_0x54ed11(_0x12a42e);});});}function getAgent(_0x186962){const _0x4456d5=_0x48f048;return db[_0x4456d5('0x12')][_0x4456d5('0x3a')]({'where':{'id':_0x186962,'role':_0x4456d5('0x3d')}})[_0x4456d5('0x1e')](checkError());}exports['originate']=function(_0x2ffdf5,_0x10b834){const _0x417493=_0x48f048;logger['info'](_0x417493('0x2e'),_0x2ffdf5[_0x417493('0x1')]);const _0x2e8d44=originateValidation['validate'](_0x2ffdf5['body']);if(_0x2e8d44[_0x417493('0x32')]>0x0)return _0x10b834[_0x417493('0x24')](0x190)[_0x417493('0x11')](_0x2e8d44);const _0x54c544=_0x2ffdf5['body'][_0x417493('0xf')],_0x418276=_0x2ffdf5[_0x417493('0x1')]['callNumber'],_0x67fa0b=_0x2ffdf5[_0x417493('0x1')][_0x417493('0x3e')],_0x70c6f3=_0x2ffdf5[_0x417493('0x1')][_0x417493('0x18')];return getAgent(_0x54c544)[_0x417493('0x1e')](function(_0x20059b){const _0x52ee79=_0x417493;return logger['info']('entityFound:',_0x20059b[_0x52ee79('0x37')]),emit(util[_0x52ee79('0x20')](_0x52ee79('0x1c'),_0x20059b[_0x52ee79('0x37')]),_0x52ee79('0x22'),{'callNumber':_0x418276,'callerId':_0x67fa0b,'callbackUrl':_0x70c6f3}),_0x10b834[_0x52ee79('0x24')](0xc8)[_0x52ee79('0x11')]({'error':![],'message':'originate\x20executed!'});})[_0x417493('0x16')](handleError(_0x10b834));},exports[_0x48f048('0x0')]=function(_0x29bcad,_0x546862){const _0x591aa4=_0x48f048;logger['info'](_0x591aa4('0x17'),_0x29bcad['body']);const _0x20361a=hangupValidation[_0x591aa4('0x1a')](_0x29bcad['body']);if(_0x20361a[_0x591aa4('0x32')]>0x0)return _0x546862['status'](0x190)[_0x591aa4('0x11')](_0x20361a);const _0x5576d1=_0x29bcad[_0x591aa4('0x1')][_0x591aa4('0xf')],_0x4c2588=_0x29bcad[_0x591aa4('0x1')][_0x591aa4('0x7')];return getAgent(_0x5576d1)[_0x591aa4('0x1e')](function(_0x4bc234){const _0x269cf2=_0x591aa4;return logger[_0x269cf2('0xe')](_0x269cf2('0x3c'),_0x4bc234[_0x269cf2('0x37')]),emit(util[_0x269cf2('0x20')](_0x269cf2('0x1c'),_0x4bc234['name']),'webbar:hangup',{'sessionId':_0x4c2588}),_0x546862[_0x269cf2('0x24')](0xc8)[_0x269cf2('0x11')]({'error':![],'message':'hangup\x20executed!'});})[_0x591aa4('0x16')](handleError(_0x546862));},exports[_0x48f048('0x6')]=function(_0x1cafed,_0x302c5d){const _0x84a25a=_0x48f048;logger['info'](_0x84a25a('0x38'),_0x1cafed[_0x84a25a('0x1')]);const _0x50e164=answerValidation[_0x84a25a('0x1a')](_0x1cafed[_0x84a25a('0x1')]);if(_0x50e164['length']>0x0)return _0x302c5d[_0x84a25a('0x24')](0x190)[_0x84a25a('0x11')](_0x50e164);const _0x581343=_0x1cafed[_0x84a25a('0x1')][_0x84a25a('0xf')],_0x2c57e5=_0x1cafed[_0x84a25a('0x1')][_0x84a25a('0x7')];return getAgent(_0x581343)[_0x84a25a('0x1e')](function(_0x4a48c9){const _0x1e98e8=_0x84a25a;return logger[_0x1e98e8('0xe')]('entityFound:',_0x4a48c9[_0x1e98e8('0x37')]),emit(util['format'](_0x1e98e8('0x1c'),_0x4a48c9[_0x1e98e8('0x37')]),_0x1e98e8('0x1d'),{'sessionId':_0x2c57e5}),_0x302c5d[_0x1e98e8('0x24')](0xc8)[_0x1e98e8('0x11')]({'error':![],'message':_0x1e98e8('0xd')});})[_0x84a25a('0x16')](handleError(_0x302c5d));},exports['hold']=function(_0x3e07eb,_0xabb444){const _0x24e1eb=_0x48f048;logger[_0x24e1eb('0xe')](_0x24e1eb('0x2a'),_0x3e07eb['body']);const _0x425d3e=holdValidation[_0x24e1eb('0x1a')](_0x3e07eb['body']);if(_0x425d3e[_0x24e1eb('0x32')]>0x0)return _0xabb444['status'](0x190)[_0x24e1eb('0x11')](_0x425d3e);const _0x80ff4a=_0x3e07eb[_0x24e1eb('0x1')]['userId'],_0x5f1e7f=_0x3e07eb[_0x24e1eb('0x1')][_0x24e1eb('0x7')];return getAgent(_0x80ff4a)[_0x24e1eb('0x1e')](function(_0x54a2d3){const _0x80a2ef=_0x24e1eb;return logger['info'](_0x80a2ef('0x3c'),_0x54a2d3[_0x80a2ef('0x37')]),emit(util['format'](_0x80a2ef('0x1c'),_0x54a2d3[_0x80a2ef('0x37')]),_0x80a2ef('0x31'),{'sessionId':_0x5f1e7f}),_0xabb444[_0x80a2ef('0x24')](0xc8)['json']({'error':![],'message':_0x80a2ef('0x4')});})[_0x24e1eb('0x16')](handleError(_0xabb444));},exports[_0x48f048('0xc')]=function(_0x1f76fd,_0x1fd408){const _0x127a5c=_0x48f048;logger[_0x127a5c('0xe')](_0x127a5c('0x2d'),_0x1f76fd[_0x127a5c('0x1')]);const _0x335969=unholdValidation['validate'](_0x1f76fd[_0x127a5c('0x1')]);if(_0x335969['length']>0x0)return _0x1fd408[_0x127a5c('0x24')](0x190)[_0x127a5c('0x11')](_0x335969);const _0x564037=_0x1f76fd[_0x127a5c('0x1')][_0x127a5c('0xf')],_0x47f36e=_0x1f76fd[_0x127a5c('0x1')][_0x127a5c('0x7')];return getAgent(_0x564037)[_0x127a5c('0x1e')](function(_0x19c46e){const _0x423077=_0x127a5c;return logger[_0x423077('0xe')](_0x423077('0x3c'),_0x19c46e[_0x423077('0x37')]),emit(util[_0x423077('0x20')](_0x423077('0x1c'),_0x19c46e[_0x423077('0x37')]),_0x423077('0x42'),{'sessionId':_0x47f36e}),_0x1fd408[_0x423077('0x24')](0xc8)[_0x423077('0x11')]({'error':![],'message':'unhold\x20executed!'});})['catch'](handleError(_0x1fd408));},exports[_0x48f048('0x28')]=function(_0x43a80a,_0x29c106){const _0x3f953f=_0x48f048;logger['info'](_0x3f953f('0x30'),_0x29c106[_0x3f953f('0x1')]);const _0x7f6af0=callsValidation['validate'](_0x43a80a[_0x3f953f('0x1')]);if(_0x7f6af0['length']>0x0)return _0x29c106[_0x3f953f('0x24')](0x190)[_0x3f953f('0x11')](_0x7f6af0);const _0x45409e=_0x43a80a[_0x3f953f('0x1')]['userId'],_0x2fee1f=respondWithRpcPromise('VoiceChannels'),_0x4092ea=getAgent(_0x45409e);return Promise[_0x3f953f('0x1f')]([_0x2fee1f,_0x4092ea])[_0x3f953f('0x1e')](function(_0x40e6de){const _0x5a3d38=_0x3f953f,_0x46d070=_0x40e6de[0x0],_0x23e76a=_0x40e6de[0x1],_0x53f6c8=_[_0x5a3d38('0x2')](_0x46d070['rows'],function(_0x56fed5){const _0x57330e=_0x5a3d38;return _0x56fed5[_0x57330e('0x3f')]==_0x23e76a['id'];});return _0x29c106[_0x5a3d38('0x24')](0xc8)[_0x5a3d38('0x11')]({'count':_0x53f6c8['length'],'rows':_0x53f6c8});})[_0x3f953f('0x16')](handleError(_0x29c106));},exports['conference']=function(_0x2c261f,_0x51b3a3){const _0x278602=_0x48f048;logger[_0x278602('0xe')]('conference\x20fired:',_0x2c261f[_0x278602('0x1')]);const _0x56b48b=conferenceValidation[_0x278602('0x1a')](_0x2c261f['body']);if(_0x56b48b['length']>0x0)return _0x51b3a3['status'](0x190)[_0x278602('0x11')](_0x56b48b);const _0x4f9533=_0x2c261f[_0x278602('0x1')][_0x278602('0xf')];return getAgent(_0x4f9533)[_0x278602('0x1e')](function(_0x378760){const _0x3bdf99=_0x278602;return logger[_0x3bdf99('0xe')](_0x3bdf99('0x3c'),_0x378760[_0x3bdf99('0x37')]),emit(util['format']('user:%s',_0x378760['name']),'webbar:conference'),_0x51b3a3[_0x3bdf99('0x24')](0xc8)['json']({'error':![],'message':_0x3bdf99('0x8')});})[_0x278602('0x16')](handleError(_0x51b3a3));},exports[_0x48f048('0x43')]=function(_0x563120,_0x11b349){const _0x51b0e5=_0x48f048;logger[_0x51b0e5('0xe')](_0x51b0e5('0x41'),_0x563120[_0x51b0e5('0x1')]);const _0x410a6b=transferValidation[_0x51b0e5('0x1a')](_0x563120[_0x51b0e5('0x1')]);if(_0x410a6b['length']>0x0)return _0x11b349[_0x51b0e5('0x24')](0x190)[_0x51b0e5('0x11')](_0x410a6b);const _0x4b4f9b=_0x563120[_0x51b0e5('0x1')][_0x51b0e5('0xf')],_0x4deac9=_0x563120[_0x51b0e5('0x1')][_0x51b0e5('0x7')],_0x170066=_0x563120['body'][_0x51b0e5('0x10')];return getAgent(_0x4b4f9b)[_0x51b0e5('0x1e')](function(_0x14f740){const _0x5595b6=_0x51b0e5;return logger[_0x5595b6('0xe')](_0x5595b6('0x3c'),_0x14f740[_0x5595b6('0x37')]),emit(util['format'](_0x5595b6('0x1c'),_0x14f740[_0x5595b6('0x37')]),_0x5595b6('0x21'),{'sessionId':_0x4deac9,'transferNumber':_0x170066}),_0x11b349['status'](0xc8)[_0x5595b6('0x11')]({'error':![],'message':_0x5595b6('0x3')});})['catch'](handleError(_0x11b349));}; \ No newline at end of file diff --git a/server/api/whatsappAccount/index.js b/server/api/whatsappAccount/index.js index 341838b..60b426a 100644 --- a/server/api/whatsappAccount/index.js +++ b/server/api/whatsappAccount/index.js @@ -1 +1 @@ -const a781_0x21ee=['/:id/notify','put','getAnswers','getDispositions','/:id/dispositions','get','getAgents','notify','post','express','send','update','addDisposition','/:id/canned_answers','removeAnswers','destroy','delete','/:id/send','/:id/users','../../components/auth/service','create','Router','isAuthenticated','getApplications','addAnswer','/:id/applications','./whatsappAccount.controller','/:id','exports'];(function(_0x2d1354,_0x21ee5c){const _0x27250d=function(_0x23578c){while(--_0x23578c){_0x2d1354['push'](_0x2d1354['shift']());}};_0x27250d(++_0x21ee5c);}(a781_0x21ee,0x140));const a781_0x2725=function(_0x2d1354,_0x21ee5c){_0x2d1354=_0x2d1354-0x0;let _0x27250d=a781_0x21ee[_0x2d1354];return _0x27250d;};const _0x173d78=a781_0x2725;'use strict';const express=require(_0x173d78('0x8')),router=express[_0x173d78('0x14')](),auth=require(_0x173d78('0x12')),controller=require(_0x173d78('0x19'));router[_0x173d78('0x4')]('/',auth[_0x173d78('0x15')](),controller['index']),router[_0x173d78('0x4')]('/describe',auth[_0x173d78('0x15')](),controller['describe']),router['get'](_0x173d78('0x1a'),auth[_0x173d78('0x15')](),controller['show']),router[_0x173d78('0x4')](_0x173d78('0x3'),auth[_0x173d78('0x15')](),controller[_0x173d78('0x2')]),router[_0x173d78('0x4')](_0x173d78('0xc'),auth[_0x173d78('0x15')](),controller[_0x173d78('0x1')]),router[_0x173d78('0x4')](_0x173d78('0x11'),auth[_0x173d78('0x15')](),controller[_0x173d78('0x5')]),router[_0x173d78('0x4')](_0x173d78('0x18'),auth[_0x173d78('0x15')](),controller[_0x173d78('0x16')]),router[_0x173d78('0x7')]('/',auth[_0x173d78('0x15')](),controller[_0x173d78('0x13')]),router[_0x173d78('0x7')]('/:id/dispositions',auth[_0x173d78('0x15')](),controller[_0x173d78('0xb')]),router[_0x173d78('0x7')](_0x173d78('0xc'),auth[_0x173d78('0x15')](),controller[_0x173d78('0x17')]),router[_0x173d78('0x7')](_0x173d78('0x11'),auth[_0x173d78('0x15')](),controller['addAgents']),router[_0x173d78('0x7')](_0x173d78('0x18'),auth[_0x173d78('0x15')](),controller['addApplications']),router[_0x173d78('0x7')](_0x173d78('0x1c'),controller[_0x173d78('0x6')]),router[_0x173d78('0x7')](_0x173d78('0x10'),auth['isAuthenticated'](),controller[_0x173d78('0x9')]),router[_0x173d78('0x0')](_0x173d78('0x1a'),auth[_0x173d78('0x15')](),controller[_0x173d78('0xa')]),router[_0x173d78('0xf')]('/:id',auth[_0x173d78('0x15')](),controller[_0x173d78('0xe')]),router['delete'](_0x173d78('0x3'),auth[_0x173d78('0x15')](),controller['removeDispositions']),router[_0x173d78('0xf')](_0x173d78('0xc'),auth['isAuthenticated'](),controller[_0x173d78('0xd')]),router[_0x173d78('0xf')]('/:id/users',auth[_0x173d78('0x15')](),controller['removeAgents']),module[_0x173d78('0x1b')]=router; \ No newline at end of file +const a781_0x1bd0=['send','show','addDisposition','index','delete','create','/:id/dispositions','describe','removeAgents','express','notify','isAuthenticated','./whatsappAccount.controller','/:id/users','getAnswers','post','destroy','getDispositions','addAgents','/:id/applications','/:id/canned_answers','removeDispositions','getAgents','/:id','addApplications','get'];(function(_0x186536,_0x1bd008){const _0x45eaf0=function(_0x237600){while(--_0x237600){_0x186536['push'](_0x186536['shift']());}};_0x45eaf0(++_0x1bd008);}(a781_0x1bd0,0x84));const a781_0x45ea=function(_0x186536,_0x1bd008){_0x186536=_0x186536-0x0;let _0x45eaf0=a781_0x1bd0[_0x186536];return _0x45eaf0;};const _0x65ae9a=a781_0x45ea;'use strict';const express=require(_0x65ae9a('0x7')),router=express['Router'](),auth=require('../../components/auth/service'),controller=require(_0x65ae9a('0xa'));router['get']('/',auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0x1')]),router['get']('/describe',auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0x5')]),router[_0x65ae9a('0x17')](_0x65ae9a('0x15'),auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0x19')]),router[_0x65ae9a('0x17')](_0x65ae9a('0x4'),auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0xf')]),router[_0x65ae9a('0x17')](_0x65ae9a('0x12'),auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0xc')]),router[_0x65ae9a('0x17')](_0x65ae9a('0xb'),auth['isAuthenticated'](),controller[_0x65ae9a('0x14')]),router[_0x65ae9a('0x17')]('/:id/applications',auth['isAuthenticated'](),controller['getApplications']),router['post']('/',auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0x3')]),router['post'](_0x65ae9a('0x4'),auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0x0')]),router[_0x65ae9a('0xd')](_0x65ae9a('0x12'),auth[_0x65ae9a('0x9')](),controller['addAnswer']),router[_0x65ae9a('0xd')]('/:id/users',auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0x10')]),router[_0x65ae9a('0xd')](_0x65ae9a('0x11'),auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0x16')]),router[_0x65ae9a('0xd')]('/:id/notify',controller[_0x65ae9a('0x8')]),router[_0x65ae9a('0xd')]('/:id/send',auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0x18')]),router['put'](_0x65ae9a('0x15'),auth[_0x65ae9a('0x9')](),controller['update']),router[_0x65ae9a('0x2')](_0x65ae9a('0x15'),auth['isAuthenticated'](),controller[_0x65ae9a('0xe')]),router[_0x65ae9a('0x2')](_0x65ae9a('0x4'),auth[_0x65ae9a('0x9')](),controller[_0x65ae9a('0x13')]),router[_0x65ae9a('0x2')]('/:id/canned_answers',auth['isAuthenticated'](),controller['removeAnswers']),router[_0x65ae9a('0x2')]('/:id/users',auth['isAuthenticated'](),controller[_0x65ae9a('0x6')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/whatsappAccount/whatsappAccount.attributes.js b/server/api/whatsappAccount/whatsappAccount.attributes.js index cf2d5f5..9624af7 100644 --- a/server/api/whatsappAccount/whatsappAccount.attributes.js +++ b/server/api/whatsappAccount/whatsappAccount.attributes.js @@ -1 +1 @@ -const a782_0x4768=['INTEGER','Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','randomstring','TEXT','exports','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','name','BOOLEAN','sequelize','Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}','mandatoryDispositionPauseId','ENUM','generate','setDataValue','mandatoryDisposition','STRING'];(function(_0x18e09c,_0x4768e0){const _0x43e9aa=function(_0x31acb4){while(--_0x31acb4){_0x18e09c['push'](_0x18e09c['shift']());}};_0x43e9aa(++_0x4768e0);}(a782_0x4768,0x132));const a782_0x43e9=function(_0x18e09c,_0x4768e0){_0x18e09c=_0x18e09c-0x0;let _0x43e9aa=a782_0x4768[_0x18e09c];return _0x43e9aa;};const _0x20af49=a782_0x43e9;'use strict';const Sequelize=require(_0x20af49('0x6')),rs=require(_0x20af49('0x0'));module[_0x20af49('0x2')]={'name':{'type':Sequelize[_0x20af49('0xd')],'unique':_0x20af49('0x4'),'allowNull':![]},'key':{'type':Sequelize['STRING'],'allowNull':![]},'remote':{'type':Sequelize[_0x20af49('0xd')],'allowNull':![]},'token':{'type':Sequelize['STRING'],'defaultValue':function(){const _0x37ac4e=_0x20af49;return rs[_0x37ac4e('0xa')]();}},'phone':{'type':Sequelize[_0x20af49('0xd')]},'type':{'type':Sequelize[_0x20af49('0x9')]('twilio')},'accountSid':{'type':Sequelize[_0x20af49('0xd')]},'authToken':{'type':Sequelize[_0x20af49('0xd')]},'notificationTemplate':{'type':Sequelize[_0x20af49('0x1')],'defaultValue':function(){const _0x48978b=_0x20af49;return _0x48978b('0x7');}},'notificationSound':{'type':Sequelize[_0x20af49('0x5')],'defaultValue':![]},'notificationShake':{'type':Sequelize[_0x20af49('0x5')],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x20af49('0xe')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'queueTransfer':{'type':Sequelize[_0x20af49('0x5')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize[_0x20af49('0xe')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize[_0x20af49('0x5')],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0x20af49('0xe')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'mandatoryDispositionPauseId':{'type':Sequelize[_0x20af49('0xe')],'comment':_0x20af49('0xf')},'mandatoryDisposition':{'type':Sequelize[_0x20af49('0x5')],'defaultValue':![],'comment':_0x20af49('0x3'),'set':function(_0x31acb4){const _0x11aaa3=_0x20af49;!_0x31acb4&&this[_0x11aaa3('0xb')](_0x11aaa3('0x8'),null),this[_0x11aaa3('0xb')](_0x11aaa3('0xc'),_0x31acb4);}},'description':{'type':Sequelize[_0x20af49('0xd')]}}; \ No newline at end of file +const a782_0x8ecc=['Status\x20to\x20put\x20when\x20mandatory\x20disposition\x20is\x20enabled','randomstring','mandatoryDispositionPauseId','STRING','setDataValue','TEXT','mandatoryDisposition','exports','INTEGER','sequelize','generate','Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}','Enabled/disables\x20mandatory\x20dispo\x20on\x20a\x20queue','BOOLEAN'];(function(_0x4c753a,_0x8eccc2){const _0x837a18=function(_0x3e1ade){while(--_0x3e1ade){_0x4c753a['push'](_0x4c753a['shift']());}};_0x837a18(++_0x8eccc2);}(a782_0x8ecc,0x1a3));const a782_0x837a=function(_0x4c753a,_0x8eccc2){_0x4c753a=_0x4c753a-0x0;let _0x837a18=a782_0x8ecc[_0x4c753a];return _0x837a18;};const _0x3a19aa=a782_0x837a;'use strict';const Sequelize=require(_0x3a19aa('0xa')),rs=require(_0x3a19aa('0x2'));module[_0x3a19aa('0x8')]={'name':{'type':Sequelize[_0x3a19aa('0x4')],'unique':'name','allowNull':![]},'key':{'type':Sequelize['STRING'],'allowNull':![]},'remote':{'type':Sequelize['STRING'],'allowNull':![]},'token':{'type':Sequelize[_0x3a19aa('0x4')],'defaultValue':function(){const _0x1c427a=_0x3a19aa;return rs[_0x1c427a('0xb')]();}},'phone':{'type':Sequelize[_0x3a19aa('0x4')]},'type':{'type':Sequelize['ENUM']('twilio')},'accountSid':{'type':Sequelize[_0x3a19aa('0x4')]},'authToken':{'type':Sequelize[_0x3a19aa('0x4')]},'notificationTemplate':{'type':Sequelize[_0x3a19aa('0x6')],'defaultValue':function(){const _0x39ac15=_0x3a19aa;return _0x39ac15('0xc');}},'notificationSound':{'type':Sequelize[_0x3a19aa('0x0')],'defaultValue':![]},'notificationShake':{'type':Sequelize[_0x3a19aa('0x0')],'defaultValue':![]},'waitForTheAssignedAgent':{'type':Sequelize[_0x3a19aa('0x9')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa},'queueTransfer':{'type':Sequelize[_0x3a19aa('0x0')],'defaultValue':![]},'queueTransferTimeout':{'type':Sequelize['INTEGER'],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'agentTransfer':{'type':Sequelize[_0x3a19aa('0x0')],'defaultValue':![]},'agentTransferTimeout':{'type':Sequelize[_0x3a19aa('0x9')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c},'mandatoryDispositionPauseId':{'type':Sequelize[_0x3a19aa('0x9')],'comment':_0x3a19aa('0x1')},'mandatoryDisposition':{'type':Sequelize[_0x3a19aa('0x0')],'defaultValue':![],'comment':_0x3a19aa('0xd'),'set':function(_0x3e1ade){const _0x2f415f=_0x3a19aa;!_0x3e1ade&&this[_0x2f415f('0x5')](_0x2f415f('0x3'),null),this['setDataValue'](_0x2f415f('0x7'),_0x3e1ade);}},'description':{'type':Sequelize[_0x3a19aa('0x4')]}}; \ No newline at end of file diff --git a/server/api/whatsappAccount/whatsappAccount.controller.js b/server/api/whatsappAccount/whatsappAccount.controller.js index 67a9e3b..c5be46f 100644 --- a/server/api/whatsappAccount/whatsappAccount.controller.js +++ b/server/api/whatsappAccount/whatsappAccount.controller.js @@ -1 +1 @@ -const a783_0x2546=['user','offset','addAnswer','then','like','no\x20available\x20attributes','text/xml','Content-Range','includeAll','query','removeAgents','getAnswers','Unable\x20to\x20retrieve\x20the\x20current\x20user','UserProfileResource','create','Start','send','isArray','messageId','get','api','Content-Type','../../rediscache','keys','../../mysqldb','order','updatedAt','List','includes','stack','fieldName','MessageSid','isNil','notify','length','status','to\x20is\x20mandatory','CmContact','WhatsappAccount,\x20%s,\x20%s,\x20%s','error','./whatsappAccount.socket','Messages','WhatsappAccountId','../../components/parsers/qs','removeDispositions','map','account','getDispositions','key','AttachmentId','from\x20is\x20mandatory','addAgents','WhatsappAccount','sort','getApplications','push','WhatsappAccounts','pick','describe','rawAttributes','userWhatsappAccount:remove','getAgents','ListId','created','WhatsappMessage','WhatsappAccount,\x20%s,\x20%s','UserProfileSection','VIRTUAL','userProfileId','User','findAll','json','contact','message','result','twilio','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','difference','whatsapp:','intersection','where','addDisposition','applications','mandatoryDispositionPause','mapKey','client','UserId','from','info','request\x20sent','findAndCountAll','emit','ContactId','list','attributes','defaults','findOne','WhatsappInteraction','unshift','merge','model','update','request','Applications','autoAssociation','stringify','debug','From','filter','\x0a','transaction','../../config/logger','http','body\x20is\x20mandatory\x20and\x20not\x20empty','nolimit','entity\x20found','lodash','out','createdAt','limit','options','undefined','WhatsappApplication','priority','addApplications','*,*,*,*','body','set','end','catch','include','name','CannedAnswer','sendStatus','CompanyId','removeAnswers','CmList','Pause','sequelize','replace','Body','rows','ids','code','filters','type','destroy','Contacts','fields','receiveMessage','dataValues','count','params','interaction','Disposition'];(function(_0x204646,_0x254637){const _0xa36337=function(_0x376b7e){while(--_0x376b7e){_0x204646['push'](_0x204646['shift']());}};_0xa36337(++_0x254637);}(a783_0x2546,0x10c));const a783_0xa363=function(_0x204646,_0x254637){_0x204646=_0x204646-0x0;let _0xa36337=a783_0x2546[_0x204646];return _0xa36337;};const _0x7be6ea=a783_0xa363;'use strict';const _=require(_0x7be6ea('0x3')),qs=require(_0x7be6ea('0x55')),logger=require(_0x7be6ea('0x99'))(_0x7be6ea('0x3e')),{getSocket}=require(_0x7be6ea('0x40')),socket=getSocket(),db=require(_0x7be6ea('0x42'))['db'],{Op,ValidationError}=require(_0x7be6ea('0x19'));require(_0x7be6ea('0x52'))['register'](socket);const jayson=require('jayson/promise'),client=jayson[_0x7be6ea('0x7f')][_0x7be6ea('0x9a')]({'port':0x232c});function respondWithRpcPromise(_0x376b7e,_0x2fba86,_0x271126,_0x454b16){return new Promise(function(_0x3379c4,_0x493d24){const _0x4faddc=a783_0xa363,_0x4cb422=_0x454b16||client;return _0x4cb422[_0x4faddc('0x90')](_0x376b7e,_0x271126)[_0x4faddc('0x2d')](function(_0x1309ab){const _0x380384=_0x4faddc;logger['info'](_0x380384('0x6b'),_0x2fba86,'request\x20sent'),logger[_0x380384('0x94')]('WhatsappAccount,\x20%s,\x20%s,\x20%s',_0x2fba86,_0x380384('0x83'),JSON[_0x380384('0x93')](_0x1309ab));if(_0x1309ab[_0x380384('0x51')]){if(_0x1309ab['error'][_0x380384('0x1e')]===0x1f4)return logger[_0x380384('0x51')]('WhatsappAccount,\x20%s,\x20%s',_0x2fba86,_0x1309ab[_0x380384('0x51')]['message']),_0x493d24(_0x1309ab['error'][_0x380384('0x73')]);return logger['error'](_0x380384('0x6b'),_0x2fba86,_0x1309ab['error']['message']),_0x3379c4(_0x1309ab[_0x380384('0x51')][_0x380384('0x73')]);}else logger[_0x380384('0x82')]('WhatsappAccount,\x20%s,\x20%s',_0x2fba86,_0x380384('0x83')),_0x3379c4(_0x1309ab[_0x380384('0x74')][_0x380384('0x73')]);})[_0x4faddc('0x10')](function(_0x422b49){const _0x4dd2f8=_0x4faddc;logger['error'](_0x4dd2f8('0x6b'),_0x2fba86,_0x422b49),_0x493d24(_0x422b49);});});}function respondWithStatusCode(_0x307418,_0x1bbcde){return _0x1bbcde=_0x1bbcde||0xcc,function(_0x3e1869){const _0x55bca7=a783_0xa363;if(_0x3e1869)return _0x307418[_0x55bca7('0x14')](_0x1bbcde);return _0x307418[_0x55bca7('0x4d')](_0x1bbcde)[_0x55bca7('0xf')]();};}function respondWithResult(_0x22b5e7,_0x4ad349){return _0x4ad349=_0x4ad349||0xc8,function(_0x31c622){const _0x294c2a=a783_0xa363;if(_0x31c622)return _0x22b5e7[_0x294c2a('0x4d')](_0x4ad349)[_0x294c2a('0x71')](_0x31c622);};}function respondWithFilteredResult(_0x3f46b0,_0x222a5f){return function(_0x170122){const _0xc85910=a783_0xa363;if(_0x170122){const _0x402aaf=_0x170122[_0xc85910('0x26')],_0xca68ac=_0x222a5f[_0xc85910('0x2b')];let _0x297cce=_0x222a5f[_0xc85910('0x2b')]+_0x222a5f[_0xc85910('0x6')],_0xdeae25;return _0x297cce>=_0x402aaf?(_0x297cce=_0x402aaf,_0xdeae25=0xc8):_0xdeae25=0xce,_0x3f46b0[_0xc85910('0x4d')](_0xdeae25),_0x3f46b0['set'](_0xc85910('0x31'),_0xca68ac+'-'+_0x297cce+'/'+_0x402aaf)[_0xc85910('0x71')](_0x170122);}return null;};}function saveUpdates(_0x530a90){return function(_0x2c5c5b){const _0x24cf7a=a783_0xa363;if(_0x2c5c5b)return _0x2c5c5b[_0x24cf7a('0x8f')](_0x530a90)[_0x24cf7a('0x2d')](function(_0x2d2d04){return _0x2d2d04;});return null;};}function removeEntity(_0x4f173c){return function(_0x9c32e3){const _0x55bdb0=a783_0xa363;if(_0x9c32e3)return _0x9c32e3[_0x55bdb0('0x21')]()['then'](function(){const _0x3451be=_0x55bdb0,_0x20eb5f=_0x9c32e3[_0x3451be('0x3d')]({'plain':!![]}),_0x55fb74=_0x3451be('0x62');return db[_0x3451be('0x37')]['destroy']({'where':{'type':_0x55fb74,'resourceId':_0x20eb5f['id']}})[_0x3451be('0x2d')](function(){return _0x9c32e3;});})[_0x55bdb0('0x2d')](function(){const _0x46c4d9=_0x55bdb0;_0x4f173c[_0x46c4d9('0x4d')](0xcc)[_0x46c4d9('0xf')]();});};}function handleEntityNotFound(_0x2f47cb){return function(_0x93a6c9){const _0x3c1ec6=a783_0xa363;return!_0x93a6c9&&_0x2f47cb[_0x3c1ec6('0x14')](0x194),_0x93a6c9;};}function handleError(_0x51d605,_0x3cc780){return _0x3cc780=_0x3cc780||0x1f4,function(_0x259bf6){const _0x50bd3d=a783_0xa363;logger['error'](_0x259bf6[_0x50bd3d('0x47')]),_0x259bf6['name']&&delete _0x259bf6[_0x50bd3d('0x12')],_0x51d605[_0x50bd3d('0x4d')](_0x3cc780)[_0x50bd3d('0x3a')](_0x259bf6);};}exports['index']=function(_0x339a80,_0x14faaa){const _0x2b2926=_0x7be6ea;let _0xf60005={'include':[{'model':db['Pause'],'as':_0x2b2926('0x7d')}]};const _0x4f9564={},_0x403c5f={'count':0x0,'rows':[]},_0x5d4124=_[_0x2b2926('0x57')](db[_0x2b2926('0x5e')][_0x2b2926('0x65')],function(_0x246fa7){const _0x566401=_0x2b2926;return{'name':_0x246fa7[_0x566401('0x48')],'type':_0x246fa7['type'][_0x566401('0x5a')]};});_0x4f9564[_0x2b2926('0x8e')]=_[_0x2b2926('0x57')](_0x5d4124,_0x2b2926('0x12')),_0x4f9564[_0x2b2926('0x33')]=_[_0x2b2926('0x41')](_0x339a80[_0x2b2926('0x33')]),_0x4f9564[_0x2b2926('0x1f')]=_['intersection'](_0x4f9564['model'],_0x4f9564[_0x2b2926('0x33')]),_0xf60005['attributes']=_[_0x2b2926('0x79')](_0x4f9564[_0x2b2926('0x8e')],qs['fields'](_0x339a80[_0x2b2926('0x33')][_0x2b2926('0x23')])),_0xf60005[_0x2b2926('0x88')]=_0xf60005[_0x2b2926('0x88')][_0x2b2926('0x4c')]?_0xf60005[_0x2b2926('0x88')]:_0x4f9564[_0x2b2926('0x8e')];typeof _0x339a80[_0x2b2926('0x33')]['nolimit']===_0x2b2926('0x8')&&(_0xf60005[_0x2b2926('0x6')]=qs[_0x2b2926('0x6')](_0x339a80[_0x2b2926('0x33')][_0x2b2926('0x6')]),_0xf60005[_0x2b2926('0x2b')]=qs['offset'](_0x339a80[_0x2b2926('0x33')][_0x2b2926('0x2b')]));_0xf60005['order']=qs[_0x2b2926('0x5f')](_0x339a80[_0x2b2926('0x33')]['sort']),_0xf60005['where']=qs[_0x2b2926('0x1f')](_[_0x2b2926('0x63')](_0x339a80['query'],_0x4f9564[_0x2b2926('0x1f')]),_0x5d4124);_0x339a80[_0x2b2926('0x33')][_0x2b2926('0x96')]&&(_0xf60005['where']=_['merge'](_0xf60005['where'],{[Op['or']]:_[_0x2b2926('0x57')](_0x5d4124,function(_0x56c0fb){const _0x57f049=_0x2b2926;if(_0x56c0fb['type']!==_0x57f049('0x6d')){const _0x35944d={};return _0x35944d[_0x56c0fb[_0x57f049('0x12')]]={[Op[_0x57f049('0x2e')]]:'%'+_0x339a80[_0x57f049('0x33')][_0x57f049('0x96')]+'%'},_0x35944d;}})}));_0xf60005=_[_0x2b2926('0x8d')]({},_0xf60005,_0x339a80[_0x2b2926('0x7')]);const _0x3486e2={'where':_0xf60005['where']};return db[_0x2b2926('0x5e')][_0x2b2926('0x26')](_0x3486e2)[_0x2b2926('0x2d')](function(_0x39e84c){const _0xb69f0c=_0x2b2926;return _0x403c5f['count']=_0x39e84c,_0x339a80[_0xb69f0c('0x33')][_0xb69f0c('0x32')]&&(_0xf60005[_0xb69f0c('0x11')]=[{'all':!![]}]),db['WhatsappAccount'][_0xb69f0c('0x70')](_0xf60005);})[_0x2b2926('0x2d')](function(_0x27b4fd){const _0x104308=_0x2b2926;return _0x403c5f[_0x104308('0x1c')]=_0x27b4fd,_0x403c5f;})[_0x2b2926('0x2d')](respondWithFilteredResult(_0x14faaa,_0xf60005))['catch'](handleError(_0x14faaa,null));},exports['show']=function(_0x139b0c,_0x59338e){const _0x4e0133=_0x7be6ea;let _0x393b0a={'raw':![],'where':{'id':_0x139b0c[_0x4e0133('0x27')]['id']},'include':[{'model':db['Pause'],'as':'mandatoryDispositionPause'}]};const _0x5593f4={};return _0x5593f4[_0x4e0133('0x8e')]=_[_0x4e0133('0x41')](db[_0x4e0133('0x5e')][_0x4e0133('0x65')]),_0x5593f4[_0x4e0133('0x33')]=_[_0x4e0133('0x41')](_0x139b0c[_0x4e0133('0x33')]),_0x5593f4[_0x4e0133('0x1f')]=_['intersection'](_0x5593f4[_0x4e0133('0x8e')],_0x5593f4[_0x4e0133('0x33')]),_0x393b0a[_0x4e0133('0x88')]=_['intersection'](_0x5593f4['model'],qs[_0x4e0133('0x23')](_0x139b0c[_0x4e0133('0x33')][_0x4e0133('0x23')])),_0x393b0a[_0x4e0133('0x88')]=_0x393b0a['attributes'][_0x4e0133('0x4c')]?_0x393b0a[_0x4e0133('0x88')]:_0x5593f4['model'],_0x139b0c[_0x4e0133('0x33')][_0x4e0133('0x32')]&&(_0x393b0a[_0x4e0133('0x11')]=[{'all':!![]}]),_0x393b0a=_[_0x4e0133('0x8d')]({},_0x393b0a,_0x139b0c['options']),db[_0x4e0133('0x5e')][_0x4e0133('0x8a')](_0x393b0a)[_0x4e0133('0x2d')](handleEntityNotFound(_0x59338e,null))[_0x4e0133('0x2d')](respondWithResult(_0x59338e,null))[_0x4e0133('0x10')](handleError(_0x59338e,null));},exports[_0x7be6ea('0x38')]=function(_0x27ab40,_0x436274){const _0x3308d0=_0x7be6ea;return db['WhatsappAccount'][_0x3308d0('0x38')](_0x27ab40[_0x3308d0('0xd')],{})[_0x3308d0('0x2d')](function(_0x5a39c3){const _0x5a6033=_0x3308d0,_0x76558a=_0x27ab40['user'][_0x5a6033('0x3d')]({'plain':!![]});if(!_0x76558a)throw new Error(_0x5a6033('0x36'));if(_0x76558a['role']===_0x5a6033('0x2a')){const _0x513d85=_0x5a39c3[_0x5a6033('0x3d')]({'plain':!![]}),_0x357932=_0x5a6033('0x62');return db[_0x5a6033('0x6c')][_0x5a6033('0x8a')]({'where':{'name':_0x357932,'userProfileId':_0x76558a[_0x5a6033('0x6e')]},'raw':!![]})['then'](function(_0x2b658f){const _0x34ffe7=_0x5a6033;return _0x2b658f&&_0x2b658f[_0x34ffe7('0x92')]===0x0?db[_0x34ffe7('0x37')][_0x34ffe7('0x38')]({'name':_0x513d85[_0x34ffe7('0x12')],'resourceId':_0x513d85['id'],'type':_0x2b658f['name'],'sectionId':_0x2b658f['id']},{})[_0x34ffe7('0x2d')](function(){return _0x5a39c3;}):_0x5a39c3;})[_0x5a6033('0x10')](function(_0x16c649){const _0x145cbe=_0x5a6033;logger[_0x145cbe('0x51')](_0x145cbe('0x76'),_0x16c649);throw _0x16c649;});}return _0x5a39c3;})[_0x3308d0('0x2d')](respondWithResult(_0x436274,0xc9))[_0x3308d0('0x10')](handleError(_0x436274,null));},exports[_0x7be6ea('0x8f')]=function(_0x39b36b,_0x36e01a){const _0xf2c888=_0x7be6ea;return _0x39b36b[_0xf2c888('0xd')]['id']&&delete _0x39b36b[_0xf2c888('0xd')]['id'],db[_0xf2c888('0x5e')][_0xf2c888('0x8a')]({'where':{'id':_0x39b36b['params']['id']},'include':[{'model':db[_0xf2c888('0x18')],'as':_0xf2c888('0x7d')}]})[_0xf2c888('0x2d')](handleEntityNotFound(_0x36e01a,null))[_0xf2c888('0x2d')](saveUpdates(_0x39b36b[_0xf2c888('0xd')],null))[_0xf2c888('0x2d')](respondWithResult(_0x36e01a,null))[_0xf2c888('0x10')](handleError(_0x36e01a,null));},exports['destroy']=function(_0x408b48,_0x1c54db){const _0x12bb7f=_0x7be6ea;return db[_0x12bb7f('0x5e')]['findOne']({'where':{'id':_0x408b48[_0x12bb7f('0x27')]['id']}})[_0x12bb7f('0x2d')](handleEntityNotFound(_0x1c54db,null))['then'](removeEntity(_0x1c54db,null))['catch'](handleError(_0x1c54db,null));},exports[_0x7be6ea('0x64')]=function(_0x2bc047,_0x329445){const _0x6d9d7f=_0x7be6ea;return db[_0x6d9d7f('0x5e')][_0x6d9d7f('0x64')]()[_0x6d9d7f('0x2d')](respondWithResult(_0x329445,null))[_0x6d9d7f('0x10')](handleError(_0x329445,null));},exports[_0x7be6ea('0x7b')]=function(_0x2fedc7,_0x1588e5){const _0x3c61d2=_0x7be6ea;return _0x2fedc7[_0x3c61d2('0xd')]['id']&&delete _0x2fedc7[_0x3c61d2('0xd')]['id'],db[_0x3c61d2('0x5e')][_0x3c61d2('0x8a')]({'where':{'id':_0x2fedc7[_0x3c61d2('0x27')]['id']}})[_0x3c61d2('0x2d')](handleEntityNotFound(_0x1588e5,null))[_0x3c61d2('0x2d')](function(_0x37ce9f){const _0x2b8160=_0x3c61d2;if(_0x37ce9f)return _0x2fedc7[_0x2b8160('0xd')][_0x2b8160('0x54')]=_0x37ce9f['id'],db[_0x2b8160('0x29')][_0x2b8160('0x38')](_0x2fedc7[_0x2b8160('0xd')]);})['then'](respondWithResult(_0x1588e5,null))[_0x3c61d2('0x10')](handleError(_0x1588e5,null));},exports[_0x7be6ea('0x59')]=function(_0x3cdab3,_0x3a8813){const _0x241537=_0x7be6ea;let _0x2e7265={'raw':![],'where':{}};const _0x51e0cb={},_0x1bdb65={'count':0x0,'rows':[]};return db[_0x241537('0x5e')][_0x241537('0x8a')]({'where':{'id':_0x3cdab3[_0x241537('0x27')]['id']}})[_0x241537('0x2d')](handleEntityNotFound(_0x3a8813,null))[_0x241537('0x2d')](function(_0x27f5cb){const _0x4b93cb=_0x241537;if(_0x27f5cb)return _0x51e0cb[_0x4b93cb('0x8e')]=_['keys'](db[_0x4b93cb('0x29')][_0x4b93cb('0x65')]),_0x51e0cb['query']=_[_0x4b93cb('0x41')](_0x3cdab3['query']),_0x51e0cb[_0x4b93cb('0x1f')]=_['intersection'](_0x51e0cb['model'],_0x51e0cb['query']),_0x2e7265[_0x4b93cb('0x88')]=_[_0x4b93cb('0x79')](_0x51e0cb[_0x4b93cb('0x8e')],qs[_0x4b93cb('0x23')](_0x3cdab3['query'][_0x4b93cb('0x23')])),_0x2e7265[_0x4b93cb('0x88')]=_0x2e7265[_0x4b93cb('0x88')]['length']?_0x2e7265[_0x4b93cb('0x88')]:_0x51e0cb[_0x4b93cb('0x8e')],typeof _0x3cdab3[_0x4b93cb('0x33')][_0x4b93cb('0x1')]==='undefined'&&(_0x2e7265[_0x4b93cb('0x6')]=qs['limit'](_0x3cdab3[_0x4b93cb('0x33')][_0x4b93cb('0x6')]),_0x2e7265[_0x4b93cb('0x2b')]=qs[_0x4b93cb('0x2b')](_0x3cdab3[_0x4b93cb('0x33')][_0x4b93cb('0x2b')])),_0x2e7265['order']=qs['sort'](_0x3cdab3[_0x4b93cb('0x33')][_0x4b93cb('0x5f')]),_0x2e7265[_0x4b93cb('0x7a')]=qs[_0x4b93cb('0x1f')](_[_0x4b93cb('0x63')](_0x3cdab3[_0x4b93cb('0x33')],_0x51e0cb[_0x4b93cb('0x1f')])),_0x2e7265[_0x4b93cb('0x7a')][_0x4b93cb('0x54')]=_0x27f5cb['id'],_0x3cdab3[_0x4b93cb('0x33')][_0x4b93cb('0x96')]&&(_0x2e7265[_0x4b93cb('0x7a')]=_['merge'](_0x2e7265['where'],{[Op['or']]:_[_0x4b93cb('0x57')](_0x2e7265['attributes'],function(_0x1586e4){const _0xe7d576=_0x4b93cb,_0x3fdfcd={};return _0x3fdfcd[_0x1586e4]={[Op[_0xe7d576('0x2e')]]:'%'+_0x3cdab3[_0xe7d576('0x33')][_0xe7d576('0x96')]+'%'},_0x3fdfcd;})})),_0x2e7265=_[_0x4b93cb('0x8d')]({},_0x2e7265,_0x3cdab3['options']),db[_0x4b93cb('0x29')][_0x4b93cb('0x26')]({'where':_0x2e7265[_0x4b93cb('0x7a')]})[_0x4b93cb('0x2d')](function(_0x5e7445){const _0x297f27=_0x4b93cb;return _0x1bdb65['count']=_0x5e7445,_0x3cdab3[_0x297f27('0x33')][_0x297f27('0x32')]&&(_0x2e7265['include']=[{'all':!![]}]),db[_0x297f27('0x29')][_0x297f27('0x70')](_0x2e7265);})['then'](function(_0x46931d){const _0x5e4679=_0x4b93cb;return _0x1bdb65[_0x5e4679('0x1c')]=_0x46931d,_0x1bdb65;});})[_0x241537('0x2d')](respondWithFilteredResult(_0x3a8813,_0x2e7265))[_0x241537('0x10')](handleError(_0x3a8813,null));},exports[_0x7be6ea('0x56')]=function(_0x53677e,_0xfcac5a){const _0x5daf39=_0x7be6ea;return db[_0x5daf39('0x5e')][_0x5daf39('0x8a')]({'where':{'id':_0x53677e[_0x5daf39('0x27')]['id']}})[_0x5daf39('0x2d')](handleEntityNotFound(_0xfcac5a,null))[_0x5daf39('0x2d')](function(_0x3fd164){const _0x305f94=_0x5daf39;if(_0x3fd164)return _0x3fd164[_0x305f94('0x56')](_0x53677e[_0x305f94('0x33')][_0x305f94('0x1d')]);})[_0x5daf39('0x2d')](respondWithStatusCode(_0xfcac5a,null))['catch'](handleError(_0xfcac5a,null));},exports[_0x7be6ea('0x2c')]=function(_0x4b7707,_0xbe06a2){const _0xff6439=_0x7be6ea;return _0x4b7707['body']['id']&&delete _0x4b7707['body']['id'],db[_0xff6439('0x5e')]['findOne']({'where':{'id':_0x4b7707[_0xff6439('0x27')]['id']}})[_0xff6439('0x2d')](handleEntityNotFound(_0xbe06a2,null))[_0xff6439('0x2d')](function(_0x2ae2de){const _0x11b874=_0xff6439;if(_0x2ae2de)return _0x4b7707[_0x11b874('0xd')]['WhatsappAccountId']=_0x2ae2de['id'],db[_0x11b874('0x13')][_0x11b874('0x38')](_0x4b7707[_0x11b874('0xd')]);})['then'](respondWithResult(_0xbe06a2,null))['catch'](handleError(_0xbe06a2,null));},exports[_0x7be6ea('0x35')]=function(_0x2e082c,_0x58b3ef){const _0x3f8665=_0x7be6ea;let _0x481f46={'raw':![],'where':{}};const _0x1beaa0={},_0x15920d={'count':0x0,'rows':[]};return db['WhatsappAccount']['findOne']({'where':{'id':_0x2e082c[_0x3f8665('0x27')]['id']}})[_0x3f8665('0x2d')](handleEntityNotFound(_0x58b3ef,null))[_0x3f8665('0x2d')](function(_0x50da23){const _0x26e385=_0x3f8665;if(_0x50da23)return _0x1beaa0['model']=_[_0x26e385('0x41')](db[_0x26e385('0x13')]['rawAttributes']),_0x1beaa0['query']=_['keys'](_0x2e082c['query']),_0x1beaa0[_0x26e385('0x1f')]=_[_0x26e385('0x79')](_0x1beaa0[_0x26e385('0x8e')],_0x1beaa0[_0x26e385('0x33')]),_0x481f46[_0x26e385('0x88')]=_[_0x26e385('0x79')](_0x1beaa0[_0x26e385('0x8e')],qs[_0x26e385('0x23')](_0x2e082c[_0x26e385('0x33')][_0x26e385('0x23')])),_0x481f46['attributes']=_0x481f46[_0x26e385('0x88')][_0x26e385('0x4c')]?_0x481f46[_0x26e385('0x88')]:_0x1beaa0[_0x26e385('0x8e')],typeof _0x2e082c[_0x26e385('0x33')][_0x26e385('0x1')]===_0x26e385('0x8')&&(_0x481f46[_0x26e385('0x6')]=qs[_0x26e385('0x6')](_0x2e082c[_0x26e385('0x33')][_0x26e385('0x6')]),_0x481f46[_0x26e385('0x2b')]=qs[_0x26e385('0x2b')](_0x2e082c[_0x26e385('0x33')][_0x26e385('0x2b')])),_0x481f46[_0x26e385('0x43')]=qs[_0x26e385('0x5f')](_0x2e082c[_0x26e385('0x33')]['sort']),_0x481f46[_0x26e385('0x7a')]=qs[_0x26e385('0x1f')](_[_0x26e385('0x63')](_0x2e082c['query'],_0x1beaa0[_0x26e385('0x1f')])),_0x481f46[_0x26e385('0x7a')]['WhatsappAccountId']=_0x50da23['id'],_0x2e082c[_0x26e385('0x33')][_0x26e385('0x96')]&&(_0x481f46['where']=_['merge'](_0x481f46[_0x26e385('0x7a')],{[Op['or']]:_[_0x26e385('0x57')](_0x481f46[_0x26e385('0x88')],function(_0x341459){const _0x26a00e=_0x26e385,_0x1875d8={};return _0x1875d8[_0x341459]={[Op[_0x26a00e('0x2e')]]:'%'+_0x2e082c[_0x26a00e('0x33')]['filter']+'%'},_0x1875d8;})})),_0x481f46=_[_0x26e385('0x8d')]({},_0x481f46,_0x2e082c['options']),db[_0x26e385('0x13')]['count']({'where':_0x481f46[_0x26e385('0x7a')]})[_0x26e385('0x2d')](function(_0xe555d9){const _0x214fd8=_0x26e385;return _0x15920d['count']=_0xe555d9,_0x2e082c[_0x214fd8('0x33')][_0x214fd8('0x32')]&&(_0x481f46[_0x214fd8('0x11')]=[{'all':!![]}]),db[_0x214fd8('0x13')]['findAll'](_0x481f46);})['then'](function(_0x32284a){const _0x4b0367=_0x26e385;return _0x15920d[_0x4b0367('0x1c')]=_0x32284a,_0x15920d;});})[_0x3f8665('0x2d')](respondWithFilteredResult(_0x58b3ef,_0x481f46))[_0x3f8665('0x10')](handleError(_0x58b3ef,null));},exports[_0x7be6ea('0x16')]=function(_0x18c74a,_0x48d86e){const _0x13848c=_0x7be6ea;return db[_0x13848c('0x5e')]['findOne']({'where':{'id':_0x18c74a[_0x13848c('0x27')]['id']}})[_0x13848c('0x2d')](handleEntityNotFound(_0x48d86e,null))[_0x13848c('0x2d')](function(_0x120937){const _0x383dc6=_0x13848c;if(_0x120937)return _0x120937[_0x383dc6('0x16')](_0x18c74a['query'][_0x383dc6('0x1d')]);})[_0x13848c('0x2d')](respondWithStatusCode(_0x48d86e,null))[_0x13848c('0x10')](handleError(_0x48d86e,null));},exports[_0x7be6ea('0x5d')]=function(_0x558d5f,_0x5a4b64){const _0x32892b=_0x7be6ea;return db[_0x32892b('0x5e')][_0x32892b('0x8a')]({'where':{'id':_0x558d5f['params']['id']}})[_0x32892b('0x2d')](function(_0x481787){const _0x5945a8=_0x32892b;if(_0x481787)return _0x481787[_0x5945a8('0x5d')](_0x558d5f['body']['ids'],{'through':_['omit'](_0x558d5f[_0x5945a8('0xd')],['ids','id'])})[_0x5945a8('0x2d')](function(_0x38ae1f){const _0x2791ed=_0x5945a8;for(let _0xfa6f99=0x0;_0xfa6f99<_0x558d5f[_0x2791ed('0xd')][_0x2791ed('0x1d')][_0x2791ed('0x4c')];_0xfa6f99+=0x1){socket[_0x2791ed('0x85')]('userWhatsappAccount:save',{'UserId':_0x558d5f['body'][_0x2791ed('0x1d')][_0xfa6f99],'WhatsappAccountId':_0x558d5f['params']['id']});}return _0x38ae1f;});})['then'](respondWithResult(_0x5a4b64,null))[_0x32892b('0x10')](handleError(_0x5a4b64,null));},exports[_0x7be6ea('0x34')]=function(_0x2d467f,_0x4df40e){const _0x42aaf8=_0x7be6ea;return db['WhatsappAccount'][_0x42aaf8('0x8a')]({'where':{'id':_0x2d467f[_0x42aaf8('0x27')]['id']}})[_0x42aaf8('0x2d')](handleEntityNotFound(_0x4df40e,null))['then'](function(_0x37dea0){const _0xd8e991=_0x42aaf8;if(_0x37dea0)return _0x37dea0['removeAgents'](_0x2d467f[_0xd8e991('0x33')]['ids'])[_0xd8e991('0x2d')](function(){const _0xa7cb80=_0xd8e991;if(_[_0xa7cb80('0x3b')](_0x2d467f[_0xa7cb80('0x33')][_0xa7cb80('0x1d')]))for(let _0xbd8e7=0x0;_0xbd8e7<_0x2d467f[_0xa7cb80('0x33')][_0xa7cb80('0x1d')][_0xa7cb80('0x4c')];_0xbd8e7+=0x1){socket[_0xa7cb80('0x85')](_0xa7cb80('0x66'),{'UserId':Number(_0x2d467f[_0xa7cb80('0x33')][_0xa7cb80('0x1d')][_0xbd8e7]),'WhatsappAccountId':Number(_0x2d467f[_0xa7cb80('0x27')]['id'])});}else socket[_0xa7cb80('0x85')](_0xa7cb80('0x66'),{'UserId':Number(_0x2d467f[_0xa7cb80('0x33')][_0xa7cb80('0x1d')]),'WhatsappAccountId':Number(_0x2d467f['params']['id'])});});})[_0x42aaf8('0x2d')](respondWithStatusCode(_0x4df40e,null))[_0x42aaf8('0x10')](handleError(_0x4df40e,null));},exports[_0x7be6ea('0x67')]=function(_0xaa5063,_0x1b9cc9){const _0x4d4067=_0x7be6ea;let _0x55db81={};const _0x3a85fe={};let _0x4c53e2,_0x2740f9;return db[_0x4d4067('0x5e')]['findOne']({'where':{'id':_0xaa5063[_0x4d4067('0x27')]['id']}})[_0x4d4067('0x2d')](handleEntityNotFound(_0x1b9cc9,null))[_0x4d4067('0x2d')](function(_0x433c16){const _0x2e161b=_0x4d4067;if(_0x433c16)return _0x4c53e2=_0x433c16,_0x3a85fe[_0x2e161b('0x8e')]=_[_0x2e161b('0x41')](db[_0x2e161b('0x6f')][_0x2e161b('0x65')]),_0x3a85fe[_0x2e161b('0x33')]=_[_0x2e161b('0x41')](_0xaa5063[_0x2e161b('0x33')]),_0x3a85fe[_0x2e161b('0x1f')]=_[_0x2e161b('0x79')](_0x3a85fe[_0x2e161b('0x8e')],_0x3a85fe[_0x2e161b('0x33')]),_0x55db81[_0x2e161b('0x88')]=_[_0x2e161b('0x79')](_0x3a85fe[_0x2e161b('0x8e')],qs['fields'](_0xaa5063[_0x2e161b('0x33')]['fields'])),_0x55db81[_0x2e161b('0x88')]=_0x55db81['attributes']['length']?_0x55db81[_0x2e161b('0x88')]:_0x3a85fe['model'],_0x55db81[_0x2e161b('0x43')]=qs[_0x2e161b('0x5f')](_0xaa5063[_0x2e161b('0x33')]['sort']),_0x55db81[_0x2e161b('0x7a')]=qs[_0x2e161b('0x1f')](_[_0x2e161b('0x63')](_0xaa5063[_0x2e161b('0x33')],_0x3a85fe[_0x2e161b('0x1f')])),_0xaa5063['query'][_0x2e161b('0x96')]&&(_0x55db81[_0x2e161b('0x7a')]=_[_0x2e161b('0x8d')](_0x55db81[_0x2e161b('0x7a')],{[Op['or']]:_['map'](_0x55db81[_0x2e161b('0x88')],function(_0x559d78){const _0x596d74=_0x2e161b,_0x22c1ee={};return _0x22c1ee[_0x559d78]={[Op[_0x596d74('0x2e')]]:'%'+_0xaa5063[_0x596d74('0x33')]['filter']+'%'},_0x22c1ee;})})),_0x55db81=_[_0x2e161b('0x8d')]({},_0x55db81,_0xaa5063[_0x2e161b('0x7')]),_0x4c53e2['getAgents'](_0x55db81);})[_0x4d4067('0x2d')](function(_0xbcac6a){const _0x4400a4=_0x4d4067;if(_0xbcac6a)return _0x2740f9=_0xbcac6a[_0x4400a4('0x4c')],typeof _0xaa5063[_0x4400a4('0x33')][_0x4400a4('0x1')]===_0x4400a4('0x8')&&(_0x55db81[_0x4400a4('0x6')]=qs[_0x4400a4('0x6')](_0xaa5063[_0x4400a4('0x33')]['limit']),_0x55db81[_0x4400a4('0x2b')]=qs[_0x4400a4('0x2b')](_0xaa5063['query'][_0x4400a4('0x2b')])),_0x4c53e2['getAgents'](_0x55db81);})[_0x4d4067('0x2d')](function(_0x1a3fb9){if(_0x1a3fb9)return _0x1a3fb9?{'count':_0x2740f9,'rows':_0x1a3fb9}:null;})[_0x4d4067('0x2d')](respondWithResult(_0x1b9cc9,null))[_0x4d4067('0x10')](handleError(_0x1b9cc9,null));},exports[_0x7be6ea('0xb')]=function(_0x5688f3,_0x33afc9){const _0x17e0e9=_0x7be6ea;return db[_0x17e0e9('0x5e')][_0x17e0e9('0x8a')]({'where':{'id':_0x5688f3[_0x17e0e9('0x27')]['id']}})[_0x17e0e9('0x2d')](handleEntityNotFound(_0x33afc9,null))['then'](function(_0x37f53a){const _0x330bb5=_0x17e0e9;if(_0x37f53a)return db['sequelize'][_0x330bb5('0x98')](function(_0x156a1e){const _0x8aa76e=_0x330bb5;return db['WhatsappApplication'][_0x8aa76e('0x21')]({'where':{'WhatsappAccountId':_0x5688f3[_0x8aa76e('0x27')]['id']},'transaction':_0x156a1e})[_0x8aa76e('0x2d')](function(){const _0x3db3ae=_0x8aa76e,_0x1abe84=_[_0x3db3ae('0x57')](_0x5688f3[_0x3db3ae('0xd')],function(_0x35fd9a){const _0x4f5e8d=_0x3db3ae;return _0x35fd9a[_0x4f5e8d('0x54')]=_0x5688f3[_0x4f5e8d('0x27')]['id'],_0x35fd9a;});return db[_0x3db3ae('0x9')]['bulkCreate'](_0x1abe84,{'transaction':_0x156a1e});});})['then'](function(){const _0x844ae=_0x330bb5;return db[_0x844ae('0x9')][_0x844ae('0x84')]({'where':{'WhatsappAccountId':_0x5688f3[_0x844ae('0x27')]['id']},'order':_0x844ae('0xa')});});})['then'](respondWithResult(_0x33afc9,null))['catch'](handleError(_0x33afc9,null));},exports[_0x7be6ea('0x60')]=function(_0x4a9de4,_0x201afa){const _0x35efa2=_0x7be6ea;let _0x4f5c79={};const _0x1ebb2f={};let _0x3d13bf,_0x501d06;return db['WhatsappAccount'][_0x35efa2('0x8a')]({'where':{'id':_0x4a9de4[_0x35efa2('0x27')]['id']}})['then'](handleEntityNotFound(_0x201afa,null))[_0x35efa2('0x2d')](function(_0x3118ba){const _0x2ebdce=_0x35efa2;if(_0x3118ba)return _0x3d13bf=_0x3118ba,_0x1ebb2f[_0x2ebdce('0x8e')]=_[_0x2ebdce('0x41')](db['WhatsappApplication']['rawAttributes']),_0x1ebb2f[_0x2ebdce('0x33')]=_[_0x2ebdce('0x41')](_0x4a9de4[_0x2ebdce('0x33')]),_0x1ebb2f['filters']=_[_0x2ebdce('0x79')](_0x1ebb2f[_0x2ebdce('0x8e')],_0x1ebb2f['query']),_0x4f5c79[_0x2ebdce('0x88')]=_[_0x2ebdce('0x79')](_0x1ebb2f[_0x2ebdce('0x8e')],qs[_0x2ebdce('0x23')](_0x4a9de4[_0x2ebdce('0x33')][_0x2ebdce('0x23')])),_0x4f5c79[_0x2ebdce('0x88')]=_0x4f5c79['attributes'][_0x2ebdce('0x4c')]?_0x4f5c79[_0x2ebdce('0x88')]:_0x1ebb2f[_0x2ebdce('0x8e')],_0x4f5c79[_0x2ebdce('0x43')]=qs['sort'](_0x4a9de4['query']['sort']),_0x4f5c79[_0x2ebdce('0x7a')]=qs[_0x2ebdce('0x1f')](_['pick'](_0x4a9de4[_0x2ebdce('0x33')],_0x1ebb2f['filters'])),_0x4a9de4[_0x2ebdce('0x33')][_0x2ebdce('0x96')]&&(_0x4f5c79[_0x2ebdce('0x7a')]=_[_0x2ebdce('0x8d')](_0x4f5c79['where'],{[Op['or']]:_[_0x2ebdce('0x57')](_0x4f5c79[_0x2ebdce('0x88')],function(_0x16c2ca){const _0x5a548b=_0x2ebdce,_0x39aa8f={};return _0x39aa8f[_0x16c2ca]={[Op[_0x5a548b('0x2e')]]:'%'+_0x4a9de4['query'][_0x5a548b('0x96')]+'%'},_0x39aa8f;})})),_0x4f5c79=_[_0x2ebdce('0x8d')]({},_0x4f5c79,_0x4a9de4[_0x2ebdce('0x7')]),_0x3d13bf[_0x2ebdce('0x60')](_0x4f5c79);})[_0x35efa2('0x2d')](function(_0x493c3a){const _0x2093eb=_0x35efa2;if(_0x493c3a)return _0x501d06=_0x493c3a[_0x2093eb('0x4c')],typeof _0x4a9de4[_0x2093eb('0x33')][_0x2093eb('0x1')]==='undefined'&&(_0x4f5c79[_0x2093eb('0x6')]=qs[_0x2093eb('0x6')](_0x4a9de4['query']['limit']),_0x4f5c79[_0x2093eb('0x2b')]=qs[_0x2093eb('0x2b')](_0x4a9de4['query'][_0x2093eb('0x2b')])),_0x3d13bf[_0x2093eb('0x60')](_0x4f5c79);})['then'](function(_0x2ef7bd){if(_0x2ef7bd)return _0x2ef7bd?{'count':_0x501d06,'rows':_0x2ef7bd}:null;})['then'](respondWithResult(_0x201afa,null))['catch'](handleError(_0x201afa,null));},exports[_0x7be6ea('0x4b')]=function(_0x289882,_0x161676){const _0x5780ac=_0x7be6ea,_0x5c33d9={'channel':'whatsapp'};let _0x23d236=[],_0x3ee81a=[];const _0x261100={};return db[_0x5780ac('0x5e')][_0x5780ac('0x8a')]({'where':{'id':_0x289882[_0x5780ac('0x27')]['id']},'include':[{'model':db[_0x5780ac('0x9')],'as':_0x5780ac('0x91')}]})['then'](handleEntityNotFound(_0x161676,null))[_0x5780ac('0x2d')](function(_0x4ee8c7){const _0x35d53f=_0x5780ac;return _0x5c33d9['account']=_0x4ee8c7,_0x5c33d9[_0x35d53f('0x7c')]=_['orderBy'](_0x4ee8c7[_0x35d53f('0x91')],[_0x35d53f('0xa')],['asc']),_0x5c33d9[_0x35d53f('0x58')][_0x35d53f('0x91')]&&delete _0x5c33d9[_0x35d53f('0x58')][_0x35d53f('0x91')],db['CmContact'][_0x35d53f('0x64')]();})[_0x5780ac('0x2d')](function(_0x438573){const _0x311d0d=_0x5780ac;if(!_0x438573)throw new ValidationError(_0x311d0d('0x2f'));_0x23d236=_['difference'](_[_0x311d0d('0x41')](_0x438573),[_0x311d0d('0x5'),_0x311d0d('0x44')]),_0x3ee81a=_[_0x311d0d('0x77')](_[_0x311d0d('0x41')](_0x438573),[_0x311d0d('0x5'),_0x311d0d('0x44'),_0x311d0d('0x15'),'ListId']),_0x5c33d9[_0x311d0d('0xd')]={'mapKey':'mobile'};_0x5c33d9[_0x311d0d('0x58')][_0x311d0d('0x20')]&&_0x5c33d9[_0x311d0d('0x58')]['type']===_0x311d0d('0x75')&&(_0x5c33d9[_0x311d0d('0xd')][_0x311d0d('0x81')]=_0x289882[_0x311d0d('0xd')][_0x311d0d('0x95')][_0x311d0d('0x1a')](_0x311d0d('0x78'),''),_0x5c33d9[_0x311d0d('0xd')][_0x311d0d('0xd')]=_0x289882['body'][_0x311d0d('0x1b')],_0x5c33d9['body'][_0x311d0d('0x3c')]=_0x289882['body'][_0x311d0d('0x49')]);_0x5c33d9[_0x311d0d('0xd')]['id']&&delete _0x5c33d9[_0x311d0d('0xd')]['id'];if(_[_0x311d0d('0x4a')](_0x5c33d9[_0x311d0d('0xd')][_0x311d0d('0x81')]))throw new ValidationError(_0x311d0d('0x5c'));if(_['isNil'](_0x5c33d9[_0x311d0d('0xd')]['body'])||_0x5c33d9[_0x311d0d('0xd')][_0x311d0d('0xd')]==='')throw new ValidationError(_0x311d0d('0x0'));if(_[_0x311d0d('0x4a')](_0x5c33d9['body'][_0x311d0d('0x7e')]))throw new ValidationError('mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20'+_0x3ee81a);if(!_[_0x311d0d('0x46')](_0x3ee81a,_0x5c33d9[_0x311d0d('0xd')][_0x311d0d('0x7e')]))throw new ValidationError('mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20'+_0x3ee81a);return _0x261100[_0x5c33d9[_0x311d0d('0xd')]['mapKey']]=_0x5c33d9[_0x311d0d('0xd')][_0x311d0d('0x81')],db[_0x311d0d('0x17')][_0x311d0d('0x8a')]({'where':{'id':_0x5c33d9[_0x311d0d('0x58')][_0x311d0d('0x68')]},'include':[{'model':db['CmContact'],'as':'Contacts','where':_0x261100,'limit':0x1,'order':[[_0x311d0d('0x44'),'DESC']]}]});})['then'](handleEntityNotFound(_0x161676,null))[_0x5780ac('0x2d')](function(_0x46386b){const _0x2921de=_0x5780ac;if(_0x46386b){_0x5c33d9[_0x2921de('0x87')]=_['omit'](_0x46386b,['Contacts']);if(_0x46386b[_0x2921de('0x22')]['length'])return _0x46386b[_0x2921de('0x22')][0x0];const _0xa3e867=_[_0x2921de('0x89')](_0x5c33d9[_0x2921de('0xd')],{'firstName':_0x5c33d9[_0x2921de('0xd')][_0x2921de('0x81')],'ListId':_0x46386b['id']});return _0xa3e867[_0x5c33d9[_0x2921de('0xd')]['mapKey']]=_0x5c33d9[_0x2921de('0xd')][_0x2921de('0x81')],db[_0x2921de('0x4f')][_0x2921de('0x38')](_0xa3e867,{'fields':_0x23d236,'raw':!![]});}})[_0x5780ac('0x2d')](handleEntityNotFound(_0x161676,null))['then'](function(_0xfcf6d2){const _0x4fc24d=_0x5780ac;if(_0xfcf6d2){_0x5c33d9[_0x4fc24d('0x72')]=_0xfcf6d2;const _0x5c7a50={'ContactId':_0xfcf6d2['id'],'phone':_0x5c33d9[_0x4fc24d('0xd')][_0x4fc24d('0x81')],'WhatsappAccountId':_0x289882[_0x4fc24d('0x27')]['id']},_0x5d6c33={'ContactId':_0xfcf6d2['id'],'WhatsappAccountId':_0x289882[_0x4fc24d('0x27')]['id'],'closed':![]};return db[_0x4fc24d('0x8b')]['findOne']({'where':_0x5d6c33})['then'](function(_0x19ed62){const _0x13b2d0=_0x4fc24d;if(_0x19ed62)return[_0x19ed62,![]];return db[_0x13b2d0('0x8b')][_0x13b2d0('0x38')](_0x5c7a50)[_0x13b2d0('0x2d')](function(_0x1fdf51){return[_0x1fdf51,!![]];});});}})[_0x5780ac('0x2d')](function([_0xe044ce,_0x53e0d0]){const _0xbe7a00=_0x5780ac;return _0x5c33d9[_0xbe7a00('0x28')]=_0xe044ce[_0xbe7a00('0x3d')]({'plain':!![]}),_0x5c33d9[_0xbe7a00('0x28')][_0xbe7a00('0x69')]=![],_0x53e0d0&&(_0x5c33d9['account']['autoclose']&&_0x5c33d9['applications']['push']({'id':0x0,'priority':_0x5c33d9['applications'][_0xbe7a00('0x4c')]+0x1,'app':'close','appdata':'unmanaged','interval':_0xbe7a00('0xc')}),_0x5c33d9['interaction']['created']=!![]),db[_0xbe7a00('0x6a')][_0xbe7a00('0x38')]({'phone':_0x5c33d9[_0xbe7a00('0xd')][_0xbe7a00('0x81')],'messageId':_0x5c33d9[_0xbe7a00('0xd')][_0xbe7a00('0x3c')],'body':_0x5c33d9['body'][_0xbe7a00('0xd')],'WhatsappAccountId':_0x289882[_0xbe7a00('0x27')]['id'],'WhatsappInteractionId':_0xe044ce['id'],'direction':'in','ContactId':_0xe044ce[_0xbe7a00('0x86')],'AttachmentId':_0x5c33d9[_0xbe7a00('0xd')][_0xbe7a00('0x5b')]});})[_0x5780ac('0x2d')](function(_0xa69805){const _0x45321e=_0x5780ac;_0x5c33d9[_0x45321e('0x73')]=_0xa69805;if(_0x5c33d9[_0x45321e('0x28')][_0x45321e('0x80')])return db[_0x45321e('0x6f')][_0x45321e('0x8a')]({'attributes':['id',_0x45321e('0x12')],'where':{'id':_0x5c33d9[_0x45321e('0x28')][_0x45321e('0x80')]}})[_0x45321e('0x2d')](function(_0x53b60e){const _0x179009=_0x45321e;return _0x53b60e&&_0x5c33d9['applications'][_0x179009('0x8c')]({'id':0x0,'priority':0x0,'app':'agent','appdata':_0x53b60e[_0x179009('0x12')]+','+(_0x5c33d9['account']['waitForTheAssignedAgent']||0xa),'interval':_0x179009('0xc')}),respondWithRpcPromise('Start','startRouting',_0x5c33d9);});return respondWithRpcPromise(_0x45321e('0x39'),'startRouting',_0x5c33d9);})['then'](function(_0x19ed36){const _0x4b8120=_0x5780ac;if(_0x19ed36){const _0xc227e5=0xc8,_0x23432f=_0x4b8120('0x24');return logger[_0x4b8120('0x82')](_0x4b8120('0x50'),_0x23432f,_0xc227e5,_0x4b8120('0x2')),logger[_0x4b8120('0x94')]('WhatsappAccount,\x20%s,\x20%s,\x20%s,\x20%s',_0x23432f,_0xc227e5,_0x4b8120('0x2'),JSON[_0x4b8120('0x93')](_0x19ed36)),_0x5c33d9['account'][_0x4b8120('0x20')]===_0x4b8120('0x75')?_0x161676[_0x4b8120('0x4d')](_0xc227e5)[_0x4b8120('0xe')](_0x4b8120('0x3f'),_0x4b8120('0x30'))[_0x4b8120('0x3a')](_0x4b8120('0x97')):_0x161676[_0x4b8120('0x4d')](_0xc227e5)[_0x4b8120('0x71')](_0x19ed36);}})[_0x5780ac('0x10')](handleError(_0x161676,null));},exports[_0x7be6ea('0x3a')]=function(_0x2dcc1b,_0x54e50f){const _0x1a5c53=_0x7be6ea;let _0xf733ca,_0x4c075d;if(_['isNil'](_0x2dcc1b[_0x1a5c53('0xd')][_0x1a5c53('0xd')])||_0x2dcc1b[_0x1a5c53('0xd')][_0x1a5c53('0xd')]==='')throw new ValidationError('body\x20is\x20mandatory\x20and\x20not\x20empty');if(_[_0x1a5c53('0x4a')](_0x2dcc1b['body']['to']))throw new ValidationError(_0x1a5c53('0x4e'));const _0x2beef5=_0x2dcc1b[_0x1a5c53('0xd')]['to'];return db[_0x1a5c53('0x5e')]['findOne']({'where':{'id':_0x2dcc1b[_0x1a5c53('0x27')]['id']},'include':[{'model':db[_0x1a5c53('0x17')],'as':_0x1a5c53('0x45'),'include':[{'model':db[_0x1a5c53('0x4f')],'as':'Contacts','where':{'mobile':_0x2beef5},'limit':0x1,'order':[['updatedAt','DESC']]}]}]})['then'](handleEntityNotFound(_0x54e50f,null))[_0x1a5c53('0x2d')](function(_0x1c6f24){const _0x5adcb7=_0x1a5c53;if(_0x1c6f24&&_0x1c6f24[_0x5adcb7('0x45')]){_0xf733ca=_0x1c6f24['get']({'plain':!![]});if(_0xf733ca[_0x5adcb7('0x45')]&&_0xf733ca['List'][_0x5adcb7('0x22')][_0x5adcb7('0x4c')])return _0xf733ca[_0x5adcb7('0x45')][_0x5adcb7('0x22')][0x0];return db[_0x5adcb7('0x4f')]['create'](_[_0x5adcb7('0x89')](_0x2dcc1b[_0x5adcb7('0xd')],{'firstName':_0x2beef5,'mobile':_0x2beef5,'phone':_0x2beef5,'ListId':_0xf733ca[_0x5adcb7('0x68')]}));}})['then'](handleEntityNotFound(_0x54e50f,null))[_0x1a5c53('0x2d')](function(_0xd32afe){const _0x4a456e=_0x1a5c53;if(_0xd32afe)return _0x4c075d=_0xd32afe,db[_0x4a456e('0x8b')]['findOne']({'where':{'ContactId':_0x4c075d['id'],'closed':![],'WhatsappAccountId':_0xf733ca['id']}})[_0x4a456e('0x2d')](function(_0x160be8){const _0x52e2c3=_0x4a456e;if(_0x160be8)return[_0x160be8,![]];return db[_0x52e2c3('0x8b')][_0x52e2c3('0x38')]({'UserId':_0x2dcc1b[_0x52e2c3('0x2a')]['id'],'ContactId':_0x4c075d['id'],'WhatsappAccountId':_0xf733ca['id'],'phone':_0x2beef5,'firstMsgDirection':_0x52e2c3('0x4'),'Messages':[_[_0x52e2c3('0x8d')](_0x2dcc1b[_0x52e2c3('0xd')],{'read':![],'body':_0x2dcc1b[_0x52e2c3('0xd')][_0x52e2c3('0xd')],'phone':_0x2beef5,'WhatsappAccountId':_0xf733ca['id'],'UserId':_0x2dcc1b[_0x52e2c3('0x2a')]['id'],'ContactId':_0x4c075d['id']})]},{'include':[{'model':db[_0x52e2c3('0x6a')],'as':_0x52e2c3('0x53')}]})['then'](function(_0x43a7f0){return[_0x43a7f0,!![]];});});})['then'](function([_0x476c59,_0x19e248]){const _0x1e235f=_0x1a5c53;if(_0x19e248)return _0x476c59;return db[_0x1e235f('0x6a')][_0x1e235f('0x38')](_[_0x1e235f('0x8d')](_0x2dcc1b[_0x1e235f('0xd')],{'read':![],'body':_0x2dcc1b[_0x1e235f('0xd')]['body'],'phone':_0x2beef5,'WhatsappAccountId':_0xf733ca['id'],'WhatsappInteractionId':_0x476c59['id'],'UserId':_0x2dcc1b[_0x1e235f('0x2a')]['id'],'ContactId':_0x4c075d['id']}))[_0x1e235f('0x2d')](function(_0x5af2d6){const _0x59f522=_0x1e235f;return _0x476c59[_0x59f522('0x25')][_0x59f522('0x53')]=[],_0x476c59[_0x59f522('0x25')]['Messages'][_0x59f522('0x61')](_0x5af2d6[_0x59f522('0x25')]),_0x476c59;});})[_0x1a5c53('0x2d')](respondWithResult(_0x54e50f,null))[_0x1a5c53('0x10')](handleError(_0x54e50f,null));}; \ No newline at end of file +const a783_0x1ab1=['destroy','stack','DESC','WhatsappAccount,\x20%s,\x20%s','includes','send','startRouting','findOne','no\x20available\x20attributes','name','../../components/parsers/qs','contact','From','then','orderBy','body','out','describe','user','limit','sendStatus','WhatsappAccount','text/xml','request','keys','Contacts','request\x20sent','WhatsappAccounts','jayson/promise','set','getApplications','userWhatsappAccount:save','get','merge','unshift','filter','difference','removeDispositions','removeAnswers','sort','includeAll','userWhatsappAccount:remove','bulkCreate','stringify','fields','WhatsappAccount,\x20%s,\x20%s,\x20%s','List','rawAttributes','User','CannedAnswer','getAnswers','create','index','Start','map','emit','UserProfileSection','pick','status','Disposition','code','where','../../config/logger','list','UserProfileResource','rows','whatsapp:','error','WhatsappInteraction','offset','getDispositions','count','model','message','to\x20is\x20mandatory','mobile','interaction','intersection','MessageSid','WhatsappMessage','from','WhatsappAccountId','addAnswer','mapKey\x20invalid,\x20please\x20use\x20one\x20of\x20these:\x20','autoclose','*,*,*,*','Pause','nolimit','replace','waitForTheAssignedAgent','attributes','priority','length','autoAssociation','updatedAt','createdAt','../../mysqldb','mapKey\x20is\x20mandatory,\x20please\x20use\x20one\x20of\x20these:\x20','role','undefined','push','sequelize','params','WhatsappApplication','findAll','userProfileId','created','twilio','CmContact','result','unmanaged','close','isNil','omit','json','catch','end','options','body\x20is\x20mandatory\x20and\x20not\x20empty','\x0a','addApplications','ListId','removeAgents','defaults','query','info','type','from\x20is\x20mandatory','ids','Unable\x20to\x20retrieve\x20the\x20current\x20user','CmList','include','whatsapp','api','dataValues','findAndCountAll','asc','agent','applications','mapKey','AttachmentId','update','Content-Range','UserId','mandatoryDispositionPause','getAgents','client','fieldName','like','debug','filters','register','Messages','Applications','order','addDisposition','account','entity\x20found','messageId'];(function(_0x11731f,_0x1ab135){const _0x25ff5f=function(_0x4e9283){while(--_0x4e9283){_0x11731f['push'](_0x11731f['shift']());}};_0x25ff5f(++_0x1ab135);}(a783_0x1ab1,0xa8));const a783_0x25ff=function(_0x11731f,_0x1ab135){_0x11731f=_0x11731f-0x0;let _0x25ff5f=a783_0x1ab1[_0x11731f];return _0x25ff5f;};const _0x14f4dc=a783_0x25ff;'use strict';const _=require('lodash'),qs=require(_0x14f4dc('0x1')),logger=require(_0x14f4dc('0x35'))(_0x14f4dc('0x7c')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x14f4dc('0x57'))['db'],{Op,ValidationError}=require(_0x14f4dc('0x5c'));require('./whatsappAccount.socket')[_0x14f4dc('0x8e')](socket);const jayson=require(_0x14f4dc('0x13')),client=jayson[_0x14f4dc('0x89')]['http']({'port':0x232c});function respondWithRpcPromise(_0x4e9283,_0x23ad10,_0x1bbeb4,_0x576491){return new Promise(function(_0x399d9a,_0x17e38d){const _0x4536d6=a783_0x25ff,_0x3f9b5d=_0x576491||client;return _0x3f9b5d[_0x4536d6('0xe')](_0x4e9283,_0x1bbeb4)['then'](function(_0x5a09ae){const _0x431d60=_0x4536d6;logger[_0x431d60('0x74')](_0x431d60('0x99'),_0x23ad10,_0x431d60('0x11')),logger[_0x431d60('0x8c')](_0x431d60('0x24'),_0x23ad10,_0x431d60('0x11'),JSON[_0x431d60('0x22')](_0x5a09ae));if(_0x5a09ae[_0x431d60('0x3a')]){if(_0x5a09ae[_0x431d60('0x3a')][_0x431d60('0x33')]===0x1f4)return logger[_0x431d60('0x3a')](_0x431d60('0x99'),_0x23ad10,_0x5a09ae[_0x431d60('0x3a')][_0x431d60('0x40')]),_0x17e38d(_0x5a09ae[_0x431d60('0x3a')][_0x431d60('0x40')]);return logger['error']('WhatsappAccount,\x20%s,\x20%s',_0x23ad10,_0x5a09ae[_0x431d60('0x3a')]['message']),_0x399d9a(_0x5a09ae[_0x431d60('0x3a')]['message']);}else logger[_0x431d60('0x74')](_0x431d60('0x99'),_0x23ad10,_0x431d60('0x11')),_0x399d9a(_0x5a09ae[_0x431d60('0x64')]['message']);})[_0x4536d6('0x6a')](function(_0x729cd9){const _0xcfeb35=_0x4536d6;logger['error'](_0xcfeb35('0x99'),_0x23ad10,_0x729cd9),_0x17e38d(_0x729cd9);});});}function respondWithStatusCode(_0x46f822,_0x4c9aa7){return _0x4c9aa7=_0x4c9aa7||0xcc,function(_0x3c53c9){const _0x4a7753=a783_0x25ff;if(_0x3c53c9)return _0x46f822['sendStatus'](_0x4c9aa7);return _0x46f822[_0x4a7753('0x31')](_0x4c9aa7)[_0x4a7753('0x6b')]();};}function respondWithResult(_0x1841d6,_0x4d1153){return _0x4d1153=_0x4d1153||0xc8,function(_0xe25a2a){if(_0xe25a2a)return _0x1841d6['status'](_0x4d1153)['json'](_0xe25a2a);};}function respondWithFilteredResult(_0x572b83,_0x46917e){return function(_0x38dbe1){const _0x5e3979=a783_0x25ff;if(_0x38dbe1){const _0x3873f2=_0x38dbe1['count'],_0x21d65c=_0x46917e[_0x5e3979('0x3c')];let _0x1e7072=_0x46917e['offset']+_0x46917e[_0x5e3979('0xa')],_0x1d6407;return _0x1e7072>=_0x3873f2?(_0x1e7072=_0x3873f2,_0x1d6407=0xc8):_0x1d6407=0xce,_0x572b83[_0x5e3979('0x31')](_0x1d6407),_0x572b83[_0x5e3979('0x14')](_0x5e3979('0x85'),_0x21d65c+'-'+_0x1e7072+'/'+_0x3873f2)[_0x5e3979('0x69')](_0x38dbe1);}return null;};}function saveUpdates(_0x5a53aa){return function(_0x44c61e){const _0x53f6c5=a783_0x25ff;if(_0x44c61e)return _0x44c61e['update'](_0x5a53aa)[_0x53f6c5('0x4')](function(_0x5d5983){return _0x5d5983;});return null;};}function removeEntity(_0x335fdb){return function(_0x4f0586){const _0x24943d=a783_0x25ff;if(_0x4f0586)return _0x4f0586[_0x24943d('0x96')]()['then'](function(){const _0x7e6d91=_0x24943d,_0x2ed143=_0x4f0586[_0x7e6d91('0x17')]({'plain':!![]}),_0x2bdc12=_0x7e6d91('0x12');return db[_0x7e6d91('0x37')][_0x7e6d91('0x96')]({'where':{'type':_0x2bdc12,'resourceId':_0x2ed143['id']}})[_0x7e6d91('0x4')](function(){return _0x4f0586;});})[_0x24943d('0x4')](function(){const _0x5ab9a5=_0x24943d;_0x335fdb[_0x5ab9a5('0x31')](0xcc)[_0x5ab9a5('0x6b')]();});};}function handleEntityNotFound(_0x292115){return function(_0x19fa5e){const _0x53956e=a783_0x25ff;return!_0x19fa5e&&_0x292115[_0x53956e('0xb')](0x194),_0x19fa5e;};}function handleError(_0xe790b7,_0x492323){return _0x492323=_0x492323||0x1f4,function(_0x483693){const _0x322baf=a783_0x25ff;logger[_0x322baf('0x3a')](_0x483693[_0x322baf('0x97')]),_0x483693[_0x322baf('0x0')]&&delete _0x483693['name'],_0xe790b7[_0x322baf('0x31')](_0x492323)['send'](_0x483693);};}exports[_0x14f4dc('0x2b')]=function(_0x50a01a,_0x447db7){const _0x4d5afd=_0x14f4dc;let _0x26289e={'include':[{'model':db['Pause'],'as':'mandatoryDispositionPause'}]};const _0xfaaadf={},_0x41319e={'count':0x0,'rows':[]},_0x34a4ea=_[_0x4d5afd('0x2d')](db[_0x4d5afd('0xc')][_0x4d5afd('0x26')],function(_0x1e7063){const _0x2b8c67=_0x4d5afd;return{'name':_0x1e7063[_0x2b8c67('0x8a')],'type':_0x1e7063[_0x2b8c67('0x75')]['key']};});_0xfaaadf[_0x4d5afd('0x3f')]=_[_0x4d5afd('0x2d')](_0x34a4ea,_0x4d5afd('0x0')),_0xfaaadf[_0x4d5afd('0x73')]=_['keys'](_0x50a01a[_0x4d5afd('0x73')]),_0xfaaadf[_0x4d5afd('0x8d')]=_[_0x4d5afd('0x44')](_0xfaaadf['model'],_0xfaaadf[_0x4d5afd('0x73')]),_0x26289e[_0x4d5afd('0x51')]=_['intersection'](_0xfaaadf[_0x4d5afd('0x3f')],qs[_0x4d5afd('0x23')](_0x50a01a[_0x4d5afd('0x73')]['fields'])),_0x26289e[_0x4d5afd('0x51')]=_0x26289e[_0x4d5afd('0x51')][_0x4d5afd('0x53')]?_0x26289e[_0x4d5afd('0x51')]:_0xfaaadf['model'];typeof _0x50a01a[_0x4d5afd('0x73')][_0x4d5afd('0x4e')]===_0x4d5afd('0x5a')&&(_0x26289e['limit']=qs['limit'](_0x50a01a[_0x4d5afd('0x73')][_0x4d5afd('0xa')]),_0x26289e[_0x4d5afd('0x3c')]=qs[_0x4d5afd('0x3c')](_0x50a01a[_0x4d5afd('0x73')][_0x4d5afd('0x3c')]));_0x26289e[_0x4d5afd('0x91')]=qs[_0x4d5afd('0x1e')](_0x50a01a[_0x4d5afd('0x73')][_0x4d5afd('0x1e')]),_0x26289e['where']=qs[_0x4d5afd('0x8d')](_['pick'](_0x50a01a[_0x4d5afd('0x73')],_0xfaaadf[_0x4d5afd('0x8d')]),_0x34a4ea);_0x50a01a[_0x4d5afd('0x73')][_0x4d5afd('0x1a')]&&(_0x26289e['where']=_[_0x4d5afd('0x18')](_0x26289e[_0x4d5afd('0x34')],{[Op['or']]:_['map'](_0x34a4ea,function(_0x27946b){const _0x39ca03=_0x4d5afd;if(_0x27946b[_0x39ca03('0x75')]!=='VIRTUAL'){const _0xed2702={};return _0xed2702[_0x27946b['name']]={[Op['like']]:'%'+_0x50a01a[_0x39ca03('0x73')][_0x39ca03('0x1a')]+'%'},_0xed2702;}})}));_0x26289e=_['merge']({},_0x26289e,_0x50a01a['options']);const _0x31dd38={'where':_0x26289e['where']};return db[_0x4d5afd('0xc')][_0x4d5afd('0x3e')](_0x31dd38)['then'](function(_0x5bd857){const _0x1730a6=_0x4d5afd;return _0x41319e[_0x1730a6('0x3e')]=_0x5bd857,_0x50a01a[_0x1730a6('0x73')][_0x1730a6('0x1f')]&&(_0x26289e[_0x1730a6('0x7a')]=[{'all':!![]}]),db[_0x1730a6('0xc')][_0x1730a6('0x5f')](_0x26289e);})['then'](function(_0x14b96e){const _0x5f52e4=_0x4d5afd;return _0x41319e[_0x5f52e4('0x38')]=_0x14b96e,_0x41319e;})[_0x4d5afd('0x4')](respondWithFilteredResult(_0x447db7,_0x26289e))['catch'](handleError(_0x447db7,null));},exports['show']=function(_0x42e707,_0x162aa5){const _0x2e57d4=_0x14f4dc;let _0x1eb7f1={'raw':![],'where':{'id':_0x42e707[_0x2e57d4('0x5d')]['id']},'include':[{'model':db[_0x2e57d4('0x4d')],'as':_0x2e57d4('0x87')}]};const _0x2863f3={};return _0x2863f3[_0x2e57d4('0x3f')]=_['keys'](db[_0x2e57d4('0xc')]['rawAttributes']),_0x2863f3[_0x2e57d4('0x73')]=_[_0x2e57d4('0xf')](_0x42e707[_0x2e57d4('0x73')]),_0x2863f3[_0x2e57d4('0x8d')]=_[_0x2e57d4('0x44')](_0x2863f3[_0x2e57d4('0x3f')],_0x2863f3[_0x2e57d4('0x73')]),_0x1eb7f1[_0x2e57d4('0x51')]=_['intersection'](_0x2863f3[_0x2e57d4('0x3f')],qs[_0x2e57d4('0x23')](_0x42e707[_0x2e57d4('0x73')]['fields'])),_0x1eb7f1[_0x2e57d4('0x51')]=_0x1eb7f1[_0x2e57d4('0x51')][_0x2e57d4('0x53')]?_0x1eb7f1[_0x2e57d4('0x51')]:_0x2863f3[_0x2e57d4('0x3f')],_0x42e707['query']['includeAll']&&(_0x1eb7f1[_0x2e57d4('0x7a')]=[{'all':!![]}]),_0x1eb7f1=_['merge']({},_0x1eb7f1,_0x42e707[_0x2e57d4('0x6c')]),db[_0x2e57d4('0xc')][_0x2e57d4('0x9d')](_0x1eb7f1)[_0x2e57d4('0x4')](handleEntityNotFound(_0x162aa5,null))[_0x2e57d4('0x4')](respondWithResult(_0x162aa5,null))[_0x2e57d4('0x6a')](handleError(_0x162aa5,null));},exports[_0x14f4dc('0x2a')]=function(_0x2168b1,_0xacbabe){const _0x34285e=_0x14f4dc;return db[_0x34285e('0xc')][_0x34285e('0x2a')](_0x2168b1[_0x34285e('0x6')],{})[_0x34285e('0x4')](function(_0x7db50e){const _0x4e973c=_0x34285e,_0xb463de=_0x2168b1[_0x4e973c('0x9')][_0x4e973c('0x17')]({'plain':!![]});if(!_0xb463de)throw new Error(_0x4e973c('0x78'));if(_0xb463de[_0x4e973c('0x59')]===_0x4e973c('0x9')){const _0x6aac96=_0x7db50e[_0x4e973c('0x17')]({'plain':!![]}),_0x4d7595='WhatsappAccounts';return db[_0x4e973c('0x2f')][_0x4e973c('0x9d')]({'where':{'name':_0x4d7595,'userProfileId':_0xb463de[_0x4e973c('0x60')]},'raw':!![]})[_0x4e973c('0x4')](function(_0x93f77a){const _0x140260=_0x4e973c;return _0x93f77a&&_0x93f77a[_0x140260('0x54')]===0x0?db[_0x140260('0x37')][_0x140260('0x2a')]({'name':_0x6aac96['name'],'resourceId':_0x6aac96['id'],'type':_0x93f77a[_0x140260('0x0')],'sectionId':_0x93f77a['id']},{})[_0x140260('0x4')](function(){return _0x7db50e;}):_0x7db50e;})[_0x4e973c('0x6a')](function(_0x318dd4){const _0x4deb4f=_0x4e973c;logger[_0x4deb4f('0x3a')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x318dd4);throw _0x318dd4;});}return _0x7db50e;})['then'](respondWithResult(_0xacbabe,0xc9))[_0x34285e('0x6a')](handleError(_0xacbabe,null));},exports[_0x14f4dc('0x84')]=function(_0x325071,_0x5261d2){const _0x59a706=_0x14f4dc;return _0x325071[_0x59a706('0x6')]['id']&&delete _0x325071['body']['id'],db[_0x59a706('0xc')][_0x59a706('0x9d')]({'where':{'id':_0x325071[_0x59a706('0x5d')]['id']},'include':[{'model':db[_0x59a706('0x4d')],'as':_0x59a706('0x87')}]})[_0x59a706('0x4')](handleEntityNotFound(_0x5261d2,null))[_0x59a706('0x4')](saveUpdates(_0x325071['body'],null))[_0x59a706('0x4')](respondWithResult(_0x5261d2,null))[_0x59a706('0x6a')](handleError(_0x5261d2,null));},exports[_0x14f4dc('0x96')]=function(_0x511cfe,_0x2c7eaa){const _0x2a0c3b=_0x14f4dc;return db[_0x2a0c3b('0xc')][_0x2a0c3b('0x9d')]({'where':{'id':_0x511cfe[_0x2a0c3b('0x5d')]['id']}})[_0x2a0c3b('0x4')](handleEntityNotFound(_0x2c7eaa,null))[_0x2a0c3b('0x4')](removeEntity(_0x2c7eaa,null))[_0x2a0c3b('0x6a')](handleError(_0x2c7eaa,null));},exports[_0x14f4dc('0x8')]=function(_0x251197,_0x3fa723){const _0x361ea8=_0x14f4dc;return db['WhatsappAccount'][_0x361ea8('0x8')]()[_0x361ea8('0x4')](respondWithResult(_0x3fa723,null))['catch'](handleError(_0x3fa723,null));},exports[_0x14f4dc('0x92')]=function(_0x9e336b,_0x7933bb){const _0x145ddd=_0x14f4dc;return _0x9e336b[_0x145ddd('0x6')]['id']&&delete _0x9e336b[_0x145ddd('0x6')]['id'],db['WhatsappAccount'][_0x145ddd('0x9d')]({'where':{'id':_0x9e336b[_0x145ddd('0x5d')]['id']}})[_0x145ddd('0x4')](handleEntityNotFound(_0x7933bb,null))['then'](function(_0x3b581b){const _0xa2c5a1=_0x145ddd;if(_0x3b581b)return _0x9e336b[_0xa2c5a1('0x6')][_0xa2c5a1('0x48')]=_0x3b581b['id'],db['Disposition']['create'](_0x9e336b[_0xa2c5a1('0x6')]);})['then'](respondWithResult(_0x7933bb,null))['catch'](handleError(_0x7933bb,null));},exports[_0x14f4dc('0x3d')]=function(_0x220ee6,_0x4f138a){const _0x5b269c=_0x14f4dc;let _0x4b34b7={'raw':![],'where':{}};const _0x50a604={},_0x2a24ac={'count':0x0,'rows':[]};return db[_0x5b269c('0xc')]['findOne']({'where':{'id':_0x220ee6[_0x5b269c('0x5d')]['id']}})[_0x5b269c('0x4')](handleEntityNotFound(_0x4f138a,null))[_0x5b269c('0x4')](function(_0x4f832a){const _0x4f78e6=_0x5b269c;if(_0x4f832a)return _0x50a604['model']=_[_0x4f78e6('0xf')](db[_0x4f78e6('0x32')][_0x4f78e6('0x26')]),_0x50a604[_0x4f78e6('0x73')]=_[_0x4f78e6('0xf')](_0x220ee6[_0x4f78e6('0x73')]),_0x50a604[_0x4f78e6('0x8d')]=_[_0x4f78e6('0x44')](_0x50a604[_0x4f78e6('0x3f')],_0x50a604[_0x4f78e6('0x73')]),_0x4b34b7[_0x4f78e6('0x51')]=_[_0x4f78e6('0x44')](_0x50a604[_0x4f78e6('0x3f')],qs[_0x4f78e6('0x23')](_0x220ee6[_0x4f78e6('0x73')][_0x4f78e6('0x23')])),_0x4b34b7[_0x4f78e6('0x51')]=_0x4b34b7[_0x4f78e6('0x51')][_0x4f78e6('0x53')]?_0x4b34b7[_0x4f78e6('0x51')]:_0x50a604['model'],typeof _0x220ee6[_0x4f78e6('0x73')][_0x4f78e6('0x4e')]==='undefined'&&(_0x4b34b7[_0x4f78e6('0xa')]=qs['limit'](_0x220ee6[_0x4f78e6('0x73')][_0x4f78e6('0xa')]),_0x4b34b7[_0x4f78e6('0x3c')]=qs['offset'](_0x220ee6['query'][_0x4f78e6('0x3c')])),_0x4b34b7[_0x4f78e6('0x91')]=qs[_0x4f78e6('0x1e')](_0x220ee6[_0x4f78e6('0x73')][_0x4f78e6('0x1e')]),_0x4b34b7[_0x4f78e6('0x34')]=qs[_0x4f78e6('0x8d')](_[_0x4f78e6('0x30')](_0x220ee6[_0x4f78e6('0x73')],_0x50a604['filters'])),_0x4b34b7[_0x4f78e6('0x34')][_0x4f78e6('0x48')]=_0x4f832a['id'],_0x220ee6[_0x4f78e6('0x73')][_0x4f78e6('0x1a')]&&(_0x4b34b7[_0x4f78e6('0x34')]=_[_0x4f78e6('0x18')](_0x4b34b7[_0x4f78e6('0x34')],{[Op['or']]:_[_0x4f78e6('0x2d')](_0x4b34b7[_0x4f78e6('0x51')],function(_0x4c2728){const _0x1562d=_0x4f78e6,_0x240ad4={};return _0x240ad4[_0x4c2728]={[Op[_0x1562d('0x8b')]]:'%'+_0x220ee6[_0x1562d('0x73')]['filter']+'%'},_0x240ad4;})})),_0x4b34b7=_[_0x4f78e6('0x18')]({},_0x4b34b7,_0x220ee6[_0x4f78e6('0x6c')]),db[_0x4f78e6('0x32')]['count']({'where':_0x4b34b7['where']})[_0x4f78e6('0x4')](function(_0x265536){const _0x57a8eb=_0x4f78e6;return _0x2a24ac['count']=_0x265536,_0x220ee6[_0x57a8eb('0x73')][_0x57a8eb('0x1f')]&&(_0x4b34b7['include']=[{'all':!![]}]),db['Disposition'][_0x57a8eb('0x5f')](_0x4b34b7);})['then'](function(_0x470624){const _0xa10494=_0x4f78e6;return _0x2a24ac[_0xa10494('0x38')]=_0x470624,_0x2a24ac;});})[_0x5b269c('0x4')](respondWithFilteredResult(_0x4f138a,_0x4b34b7))['catch'](handleError(_0x4f138a,null));},exports[_0x14f4dc('0x1c')]=function(_0x3fdd98,_0x398191){const _0x21240b=_0x14f4dc;return db['WhatsappAccount']['findOne']({'where':{'id':_0x3fdd98[_0x21240b('0x5d')]['id']}})[_0x21240b('0x4')](handleEntityNotFound(_0x398191,null))[_0x21240b('0x4')](function(_0x50b795){const _0x33b57e=_0x21240b;if(_0x50b795)return _0x50b795['removeDispositions'](_0x3fdd98[_0x33b57e('0x73')][_0x33b57e('0x77')]);})[_0x21240b('0x4')](respondWithStatusCode(_0x398191,null))[_0x21240b('0x6a')](handleError(_0x398191,null));},exports[_0x14f4dc('0x49')]=function(_0x49d523,_0x2af685){const _0x5cbb1c=_0x14f4dc;return _0x49d523[_0x5cbb1c('0x6')]['id']&&delete _0x49d523[_0x5cbb1c('0x6')]['id'],db[_0x5cbb1c('0xc')][_0x5cbb1c('0x9d')]({'where':{'id':_0x49d523[_0x5cbb1c('0x5d')]['id']}})[_0x5cbb1c('0x4')](handleEntityNotFound(_0x2af685,null))['then'](function(_0x3cffc6){const _0x4545fd=_0x5cbb1c;if(_0x3cffc6)return _0x49d523['body']['WhatsappAccountId']=_0x3cffc6['id'],db['CannedAnswer']['create'](_0x49d523[_0x4545fd('0x6')]);})[_0x5cbb1c('0x4')](respondWithResult(_0x2af685,null))[_0x5cbb1c('0x6a')](handleError(_0x2af685,null));},exports[_0x14f4dc('0x29')]=function(_0x3b158e,_0x53c29e){const _0x198996=_0x14f4dc;let _0x1904cd={'raw':![],'where':{}};const _0x45d8bf={},_0x3df5da={'count':0x0,'rows':[]};return db[_0x198996('0xc')]['findOne']({'where':{'id':_0x3b158e[_0x198996('0x5d')]['id']}})[_0x198996('0x4')](handleEntityNotFound(_0x53c29e,null))[_0x198996('0x4')](function(_0x5d52fc){const _0x469405=_0x198996;if(_0x5d52fc)return _0x45d8bf['model']=_['keys'](db['CannedAnswer']['rawAttributes']),_0x45d8bf['query']=_[_0x469405('0xf')](_0x3b158e[_0x469405('0x73')]),_0x45d8bf[_0x469405('0x8d')]=_[_0x469405('0x44')](_0x45d8bf['model'],_0x45d8bf[_0x469405('0x73')]),_0x1904cd['attributes']=_['intersection'](_0x45d8bf['model'],qs[_0x469405('0x23')](_0x3b158e[_0x469405('0x73')][_0x469405('0x23')])),_0x1904cd[_0x469405('0x51')]=_0x1904cd[_0x469405('0x51')][_0x469405('0x53')]?_0x1904cd[_0x469405('0x51')]:_0x45d8bf[_0x469405('0x3f')],typeof _0x3b158e[_0x469405('0x73')][_0x469405('0x4e')]==='undefined'&&(_0x1904cd[_0x469405('0xa')]=qs[_0x469405('0xa')](_0x3b158e['query']['limit']),_0x1904cd[_0x469405('0x3c')]=qs['offset'](_0x3b158e[_0x469405('0x73')]['offset'])),_0x1904cd[_0x469405('0x91')]=qs[_0x469405('0x1e')](_0x3b158e['query']['sort']),_0x1904cd[_0x469405('0x34')]=qs[_0x469405('0x8d')](_[_0x469405('0x30')](_0x3b158e[_0x469405('0x73')],_0x45d8bf[_0x469405('0x8d')])),_0x1904cd[_0x469405('0x34')]['WhatsappAccountId']=_0x5d52fc['id'],_0x3b158e[_0x469405('0x73')][_0x469405('0x1a')]&&(_0x1904cd[_0x469405('0x34')]=_[_0x469405('0x18')](_0x1904cd[_0x469405('0x34')],{[Op['or']]:_[_0x469405('0x2d')](_0x1904cd[_0x469405('0x51')],function(_0x55cd0d){const _0x19d2a4=_0x469405,_0x583d2f={};return _0x583d2f[_0x55cd0d]={[Op[_0x19d2a4('0x8b')]]:'%'+_0x3b158e['query'][_0x19d2a4('0x1a')]+'%'},_0x583d2f;})})),_0x1904cd=_[_0x469405('0x18')]({},_0x1904cd,_0x3b158e['options']),db[_0x469405('0x28')][_0x469405('0x3e')]({'where':_0x1904cd[_0x469405('0x34')]})['then'](function(_0x423c03){const _0x387df7=_0x469405;return _0x3df5da[_0x387df7('0x3e')]=_0x423c03,_0x3b158e[_0x387df7('0x73')][_0x387df7('0x1f')]&&(_0x1904cd[_0x387df7('0x7a')]=[{'all':!![]}]),db['CannedAnswer'][_0x387df7('0x5f')](_0x1904cd);})[_0x469405('0x4')](function(_0x41585f){const _0x3c1f23=_0x469405;return _0x3df5da[_0x3c1f23('0x38')]=_0x41585f,_0x3df5da;});})['then'](respondWithFilteredResult(_0x53c29e,_0x1904cd))['catch'](handleError(_0x53c29e,null));},exports[_0x14f4dc('0x1d')]=function(_0x1604b1,_0x1dd1a3){const _0x800e6c=_0x14f4dc;return db['WhatsappAccount'][_0x800e6c('0x9d')]({'where':{'id':_0x1604b1[_0x800e6c('0x5d')]['id']}})[_0x800e6c('0x4')](handleEntityNotFound(_0x1dd1a3,null))[_0x800e6c('0x4')](function(_0xeb49f7){const _0xbace06=_0x800e6c;if(_0xeb49f7)return _0xeb49f7[_0xbace06('0x1d')](_0x1604b1[_0xbace06('0x73')][_0xbace06('0x77')]);})[_0x800e6c('0x4')](respondWithStatusCode(_0x1dd1a3,null))[_0x800e6c('0x6a')](handleError(_0x1dd1a3,null));},exports['addAgents']=function(_0x3ee6ba,_0x2dec45){const _0x235b4c=_0x14f4dc;return db[_0x235b4c('0xc')]['findOne']({'where':{'id':_0x3ee6ba['params']['id']}})['then'](function(_0x160c4c){const _0xea4ae=_0x235b4c;if(_0x160c4c)return _0x160c4c['addAgents'](_0x3ee6ba[_0xea4ae('0x6')][_0xea4ae('0x77')],{'through':_[_0xea4ae('0x68')](_0x3ee6ba[_0xea4ae('0x6')],[_0xea4ae('0x77'),'id'])})[_0xea4ae('0x4')](function(_0x2a23bb){const _0x5d9937=_0xea4ae;for(let _0x5a34e6=0x0;_0x5a34e6<_0x3ee6ba['body'][_0x5d9937('0x77')]['length'];_0x5a34e6+=0x1){socket[_0x5d9937('0x2e')](_0x5d9937('0x16'),{'UserId':_0x3ee6ba[_0x5d9937('0x6')][_0x5d9937('0x77')][_0x5a34e6],'WhatsappAccountId':_0x3ee6ba[_0x5d9937('0x5d')]['id']});}return _0x2a23bb;});})[_0x235b4c('0x4')](respondWithResult(_0x2dec45,null))[_0x235b4c('0x6a')](handleError(_0x2dec45,null));},exports[_0x14f4dc('0x71')]=function(_0x5e1c60,_0x404151){const _0x527f85=_0x14f4dc;return db[_0x527f85('0xc')][_0x527f85('0x9d')]({'where':{'id':_0x5e1c60[_0x527f85('0x5d')]['id']}})['then'](handleEntityNotFound(_0x404151,null))[_0x527f85('0x4')](function(_0x5ba671){const _0x46638d=_0x527f85;if(_0x5ba671)return _0x5ba671[_0x46638d('0x71')](_0x5e1c60[_0x46638d('0x73')][_0x46638d('0x77')])[_0x46638d('0x4')](function(){const _0x33a056=_0x46638d;if(_['isArray'](_0x5e1c60['query'][_0x33a056('0x77')]))for(let _0x3abb71=0x0;_0x3abb71<_0x5e1c60['query'][_0x33a056('0x77')]['length'];_0x3abb71+=0x1){socket[_0x33a056('0x2e')](_0x33a056('0x20'),{'UserId':Number(_0x5e1c60['query']['ids'][_0x3abb71]),'WhatsappAccountId':Number(_0x5e1c60[_0x33a056('0x5d')]['id'])});}else socket['emit'](_0x33a056('0x20'),{'UserId':Number(_0x5e1c60[_0x33a056('0x73')][_0x33a056('0x77')]),'WhatsappAccountId':Number(_0x5e1c60[_0x33a056('0x5d')]['id'])});});})[_0x527f85('0x4')](respondWithStatusCode(_0x404151,null))[_0x527f85('0x6a')](handleError(_0x404151,null));},exports[_0x14f4dc('0x88')]=function(_0x24cfbe,_0x30d015){const _0xbc0cec=_0x14f4dc;let _0x2d1d3e={};const _0x595287={};let _0x21cd06,_0x355bf6;return db[_0xbc0cec('0xc')]['findOne']({'where':{'id':_0x24cfbe['params']['id']}})[_0xbc0cec('0x4')](handleEntityNotFound(_0x30d015,null))['then'](function(_0x485cbc){const _0x18e0d8=_0xbc0cec;if(_0x485cbc)return _0x21cd06=_0x485cbc,_0x595287[_0x18e0d8('0x3f')]=_['keys'](db[_0x18e0d8('0x27')]['rawAttributes']),_0x595287['query']=_[_0x18e0d8('0xf')](_0x24cfbe[_0x18e0d8('0x73')]),_0x595287[_0x18e0d8('0x8d')]=_['intersection'](_0x595287[_0x18e0d8('0x3f')],_0x595287['query']),_0x2d1d3e[_0x18e0d8('0x51')]=_['intersection'](_0x595287[_0x18e0d8('0x3f')],qs[_0x18e0d8('0x23')](_0x24cfbe[_0x18e0d8('0x73')]['fields'])),_0x2d1d3e[_0x18e0d8('0x51')]=_0x2d1d3e['attributes'][_0x18e0d8('0x53')]?_0x2d1d3e[_0x18e0d8('0x51')]:_0x595287['model'],_0x2d1d3e['order']=qs[_0x18e0d8('0x1e')](_0x24cfbe[_0x18e0d8('0x73')][_0x18e0d8('0x1e')]),_0x2d1d3e[_0x18e0d8('0x34')]=qs['filters'](_[_0x18e0d8('0x30')](_0x24cfbe[_0x18e0d8('0x73')],_0x595287[_0x18e0d8('0x8d')])),_0x24cfbe['query'][_0x18e0d8('0x1a')]&&(_0x2d1d3e[_0x18e0d8('0x34')]=_[_0x18e0d8('0x18')](_0x2d1d3e['where'],{[Op['or']]:_[_0x18e0d8('0x2d')](_0x2d1d3e['attributes'],function(_0xd81bf5){const _0x580013=_0x18e0d8,_0x2dc02b={};return _0x2dc02b[_0xd81bf5]={[Op[_0x580013('0x8b')]]:'%'+_0x24cfbe[_0x580013('0x73')][_0x580013('0x1a')]+'%'},_0x2dc02b;})})),_0x2d1d3e=_[_0x18e0d8('0x18')]({},_0x2d1d3e,_0x24cfbe[_0x18e0d8('0x6c')]),_0x21cd06[_0x18e0d8('0x88')](_0x2d1d3e);})[_0xbc0cec('0x4')](function(_0x59e8dc){const _0x37807b=_0xbc0cec;if(_0x59e8dc)return _0x355bf6=_0x59e8dc[_0x37807b('0x53')],typeof _0x24cfbe[_0x37807b('0x73')][_0x37807b('0x4e')]===_0x37807b('0x5a')&&(_0x2d1d3e[_0x37807b('0xa')]=qs[_0x37807b('0xa')](_0x24cfbe[_0x37807b('0x73')][_0x37807b('0xa')]),_0x2d1d3e['offset']=qs[_0x37807b('0x3c')](_0x24cfbe[_0x37807b('0x73')][_0x37807b('0x3c')])),_0x21cd06[_0x37807b('0x88')](_0x2d1d3e);})[_0xbc0cec('0x4')](function(_0x278ac1){if(_0x278ac1)return _0x278ac1?{'count':_0x355bf6,'rows':_0x278ac1}:null;})[_0xbc0cec('0x4')](respondWithResult(_0x30d015,null))[_0xbc0cec('0x6a')](handleError(_0x30d015,null));},exports[_0x14f4dc('0x6f')]=function(_0x36b4e3,_0x28b4db){const _0xe410e0=_0x14f4dc;return db['WhatsappAccount'][_0xe410e0('0x9d')]({'where':{'id':_0x36b4e3[_0xe410e0('0x5d')]['id']}})[_0xe410e0('0x4')](handleEntityNotFound(_0x28b4db,null))[_0xe410e0('0x4')](function(_0x277595){const _0xd647eb=_0xe410e0;if(_0x277595)return db[_0xd647eb('0x5c')]['transaction'](function(_0x6da2c3){const _0x52fd53=_0xd647eb;return db[_0x52fd53('0x5e')][_0x52fd53('0x96')]({'where':{'WhatsappAccountId':_0x36b4e3['params']['id']},'transaction':_0x6da2c3})[_0x52fd53('0x4')](function(){const _0x251af1=_0x52fd53,_0x243e90=_['map'](_0x36b4e3['body'],function(_0x2133d8){const _0xb68597=a783_0x25ff;return _0x2133d8[_0xb68597('0x48')]=_0x36b4e3[_0xb68597('0x5d')]['id'],_0x2133d8;});return db['WhatsappApplication'][_0x251af1('0x21')](_0x243e90,{'transaction':_0x6da2c3});});})[_0xd647eb('0x4')](function(){const _0xd03ba8=_0xd647eb;return db['WhatsappApplication'][_0xd03ba8('0x7e')]({'where':{'WhatsappAccountId':_0x36b4e3[_0xd03ba8('0x5d')]['id']},'order':_0xd03ba8('0x52')});});})[_0xe410e0('0x4')](respondWithResult(_0x28b4db,null))[_0xe410e0('0x6a')](handleError(_0x28b4db,null));},exports[_0x14f4dc('0x15')]=function(_0x813610,_0x196c1a){const _0xf2b460=_0x14f4dc;let _0x455aac={};const _0x31ed26={};let _0x19f6e9,_0x3bc29e;return db[_0xf2b460('0xc')][_0xf2b460('0x9d')]({'where':{'id':_0x813610[_0xf2b460('0x5d')]['id']}})[_0xf2b460('0x4')](handleEntityNotFound(_0x196c1a,null))[_0xf2b460('0x4')](function(_0x495bc5){const _0x4d2c8f=_0xf2b460;if(_0x495bc5)return _0x19f6e9=_0x495bc5,_0x31ed26[_0x4d2c8f('0x3f')]=_[_0x4d2c8f('0xf')](db[_0x4d2c8f('0x5e')][_0x4d2c8f('0x26')]),_0x31ed26[_0x4d2c8f('0x73')]=_[_0x4d2c8f('0xf')](_0x813610[_0x4d2c8f('0x73')]),_0x31ed26[_0x4d2c8f('0x8d')]=_[_0x4d2c8f('0x44')](_0x31ed26[_0x4d2c8f('0x3f')],_0x31ed26['query']),_0x455aac[_0x4d2c8f('0x51')]=_[_0x4d2c8f('0x44')](_0x31ed26[_0x4d2c8f('0x3f')],qs[_0x4d2c8f('0x23')](_0x813610[_0x4d2c8f('0x73')][_0x4d2c8f('0x23')])),_0x455aac[_0x4d2c8f('0x51')]=_0x455aac['attributes']['length']?_0x455aac[_0x4d2c8f('0x51')]:_0x31ed26[_0x4d2c8f('0x3f')],_0x455aac[_0x4d2c8f('0x91')]=qs['sort'](_0x813610['query']['sort']),_0x455aac[_0x4d2c8f('0x34')]=qs['filters'](_['pick'](_0x813610[_0x4d2c8f('0x73')],_0x31ed26[_0x4d2c8f('0x8d')])),_0x813610[_0x4d2c8f('0x73')][_0x4d2c8f('0x1a')]&&(_0x455aac[_0x4d2c8f('0x34')]=_[_0x4d2c8f('0x18')](_0x455aac[_0x4d2c8f('0x34')],{[Op['or']]:_[_0x4d2c8f('0x2d')](_0x455aac[_0x4d2c8f('0x51')],function(_0x58f24e){const _0x586ecf=_0x4d2c8f,_0x2193fe={};return _0x2193fe[_0x58f24e]={[Op[_0x586ecf('0x8b')]]:'%'+_0x813610[_0x586ecf('0x73')][_0x586ecf('0x1a')]+'%'},_0x2193fe;})})),_0x455aac=_[_0x4d2c8f('0x18')]({},_0x455aac,_0x813610[_0x4d2c8f('0x6c')]),_0x19f6e9[_0x4d2c8f('0x15')](_0x455aac);})['then'](function(_0x1a0f1c){const _0x4a03b7=_0xf2b460;if(_0x1a0f1c)return _0x3bc29e=_0x1a0f1c[_0x4a03b7('0x53')],typeof _0x813610[_0x4a03b7('0x73')][_0x4a03b7('0x4e')]===_0x4a03b7('0x5a')&&(_0x455aac[_0x4a03b7('0xa')]=qs[_0x4a03b7('0xa')](_0x813610[_0x4a03b7('0x73')][_0x4a03b7('0xa')]),_0x455aac[_0x4a03b7('0x3c')]=qs[_0x4a03b7('0x3c')](_0x813610[_0x4a03b7('0x73')][_0x4a03b7('0x3c')])),_0x19f6e9[_0x4a03b7('0x15')](_0x455aac);})['then'](function(_0x310101){if(_0x310101)return _0x310101?{'count':_0x3bc29e,'rows':_0x310101}:null;})[_0xf2b460('0x4')](respondWithResult(_0x196c1a,null))['catch'](handleError(_0x196c1a,null));},exports['notify']=function(_0x2eeb6a,_0x42b110){const _0x22ecb3=_0x14f4dc,_0x1e735d={'channel':_0x22ecb3('0x7b')};let _0x16fe27=[],_0x366b90=[];const _0x21eec9={};return db['WhatsappAccount'][_0x22ecb3('0x9d')]({'where':{'id':_0x2eeb6a[_0x22ecb3('0x5d')]['id']},'include':[{'model':db['WhatsappApplication'],'as':_0x22ecb3('0x90')}]})['then'](handleEntityNotFound(_0x42b110,null))[_0x22ecb3('0x4')](function(_0x5a26f2){const _0x55b709=_0x22ecb3;return _0x1e735d[_0x55b709('0x93')]=_0x5a26f2,_0x1e735d[_0x55b709('0x81')]=_[_0x55b709('0x5')](_0x5a26f2[_0x55b709('0x90')],['priority'],[_0x55b709('0x7f')]),_0x1e735d['account'][_0x55b709('0x90')]&&delete _0x1e735d['account']['Applications'],db[_0x55b709('0x63')]['describe']();})[_0x22ecb3('0x4')](function(_0x318f8b){const _0x558d9d=_0x22ecb3;if(!_0x318f8b)throw new ValidationError(_0x558d9d('0x9e'));_0x16fe27=_[_0x558d9d('0x1b')](_[_0x558d9d('0xf')](_0x318f8b),[_0x558d9d('0x56'),_0x558d9d('0x55')]),_0x366b90=_['difference'](_[_0x558d9d('0xf')](_0x318f8b),['createdAt','updatedAt','CompanyId',_0x558d9d('0x70')]),_0x1e735d[_0x558d9d('0x6')]={'mapKey':_0x558d9d('0x42')};_0x1e735d[_0x558d9d('0x93')][_0x558d9d('0x75')]&&_0x1e735d[_0x558d9d('0x93')][_0x558d9d('0x75')]===_0x558d9d('0x62')&&(_0x1e735d[_0x558d9d('0x6')][_0x558d9d('0x47')]=_0x2eeb6a[_0x558d9d('0x6')][_0x558d9d('0x3')][_0x558d9d('0x4f')](_0x558d9d('0x39'),''),_0x1e735d[_0x558d9d('0x6')][_0x558d9d('0x6')]=_0x2eeb6a[_0x558d9d('0x6')]['Body'],_0x1e735d[_0x558d9d('0x6')][_0x558d9d('0x95')]=_0x2eeb6a[_0x558d9d('0x6')][_0x558d9d('0x45')]);_0x1e735d['body']['id']&&delete _0x1e735d['body']['id'];if(_[_0x558d9d('0x67')](_0x1e735d['body'][_0x558d9d('0x47')]))throw new ValidationError(_0x558d9d('0x76'));if(_[_0x558d9d('0x67')](_0x1e735d[_0x558d9d('0x6')]['body'])||_0x1e735d[_0x558d9d('0x6')][_0x558d9d('0x6')]==='')throw new ValidationError(_0x558d9d('0x6d'));if(_[_0x558d9d('0x67')](_0x1e735d[_0x558d9d('0x6')][_0x558d9d('0x82')]))throw new ValidationError(_0x558d9d('0x58')+_0x366b90);if(!_[_0x558d9d('0x9a')](_0x366b90,_0x1e735d[_0x558d9d('0x6')][_0x558d9d('0x82')]))throw new ValidationError(_0x558d9d('0x4a')+_0x366b90);return _0x21eec9[_0x1e735d[_0x558d9d('0x6')]['mapKey']]=_0x1e735d[_0x558d9d('0x6')][_0x558d9d('0x47')],db['CmList'][_0x558d9d('0x9d')]({'where':{'id':_0x1e735d[_0x558d9d('0x93')]['ListId']},'include':[{'model':db['CmContact'],'as':'Contacts','where':_0x21eec9,'limit':0x1,'order':[['updatedAt',_0x558d9d('0x98')]]}]});})[_0x22ecb3('0x4')](handleEntityNotFound(_0x42b110,null))[_0x22ecb3('0x4')](function(_0x35b886){const _0x233a59=_0x22ecb3;if(_0x35b886){_0x1e735d[_0x233a59('0x36')]=_[_0x233a59('0x68')](_0x35b886,['Contacts']);if(_0x35b886['Contacts'][_0x233a59('0x53')])return _0x35b886['Contacts'][0x0];const _0x462de7=_[_0x233a59('0x72')](_0x1e735d['body'],{'firstName':_0x1e735d[_0x233a59('0x6')][_0x233a59('0x47')],'ListId':_0x35b886['id']});return _0x462de7[_0x1e735d[_0x233a59('0x6')][_0x233a59('0x82')]]=_0x1e735d[_0x233a59('0x6')][_0x233a59('0x47')],db[_0x233a59('0x63')][_0x233a59('0x2a')](_0x462de7,{'fields':_0x16fe27,'raw':!![]});}})[_0x22ecb3('0x4')](handleEntityNotFound(_0x42b110,null))['then'](function(_0x13051c){const _0x246dfb=_0x22ecb3;if(_0x13051c){_0x1e735d[_0x246dfb('0x2')]=_0x13051c;const _0x15901d={'ContactId':_0x13051c['id'],'phone':_0x1e735d[_0x246dfb('0x6')][_0x246dfb('0x47')],'WhatsappAccountId':_0x2eeb6a[_0x246dfb('0x5d')]['id']},_0xf19422={'ContactId':_0x13051c['id'],'WhatsappAccountId':_0x2eeb6a[_0x246dfb('0x5d')]['id'],'closed':![]};return db['WhatsappInteraction']['findOne']({'where':_0xf19422})[_0x246dfb('0x4')](function(_0x835730){const _0x1332ad=_0x246dfb;if(_0x835730)return[_0x835730,![]];return db[_0x1332ad('0x3b')]['create'](_0x15901d)[_0x1332ad('0x4')](function(_0xa53ef8){return[_0xa53ef8,!![]];});});}})['then'](function([_0x526e3e,_0x5ce40b]){const _0x361c77=_0x22ecb3;return _0x1e735d[_0x361c77('0x43')]=_0x526e3e[_0x361c77('0x17')]({'plain':!![]}),_0x1e735d[_0x361c77('0x43')][_0x361c77('0x61')]=![],_0x5ce40b&&(_0x1e735d[_0x361c77('0x93')][_0x361c77('0x4b')]&&_0x1e735d['applications'][_0x361c77('0x5b')]({'id':0x0,'priority':_0x1e735d[_0x361c77('0x81')][_0x361c77('0x53')]+0x1,'app':_0x361c77('0x66'),'appdata':_0x361c77('0x65'),'interval':_0x361c77('0x4c')}),_0x1e735d[_0x361c77('0x43')][_0x361c77('0x61')]=!![]),db['WhatsappMessage'][_0x361c77('0x2a')]({'phone':_0x1e735d[_0x361c77('0x6')]['from'],'messageId':_0x1e735d[_0x361c77('0x6')]['messageId'],'body':_0x1e735d[_0x361c77('0x6')][_0x361c77('0x6')],'WhatsappAccountId':_0x2eeb6a[_0x361c77('0x5d')]['id'],'WhatsappInteractionId':_0x526e3e['id'],'direction':'in','ContactId':_0x526e3e['ContactId'],'AttachmentId':_0x1e735d[_0x361c77('0x6')][_0x361c77('0x83')]});})[_0x22ecb3('0x4')](function(_0x2d69b4){const _0x3ec232=_0x22ecb3;_0x1e735d[_0x3ec232('0x40')]=_0x2d69b4;if(_0x1e735d[_0x3ec232('0x43')][_0x3ec232('0x86')])return db[_0x3ec232('0x27')][_0x3ec232('0x9d')]({'attributes':['id',_0x3ec232('0x0')],'where':{'id':_0x1e735d['interaction']['UserId']}})['then'](function(_0x96b279){const _0x53d53f=_0x3ec232;return _0x96b279&&_0x1e735d['applications'][_0x53d53f('0x19')]({'id':0x0,'priority':0x0,'app':_0x53d53f('0x80'),'appdata':_0x96b279['name']+','+(_0x1e735d[_0x53d53f('0x93')][_0x53d53f('0x50')]||0xa),'interval':_0x53d53f('0x4c')}),respondWithRpcPromise(_0x53d53f('0x2c'),_0x53d53f('0x9c'),_0x1e735d);});return respondWithRpcPromise(_0x3ec232('0x2c'),_0x3ec232('0x9c'),_0x1e735d);})[_0x22ecb3('0x4')](function(_0x192f70){const _0x5992a7=_0x22ecb3;if(_0x192f70){const _0xb16d3a=0xc8,_0x59b616='receiveMessage';return logger[_0x5992a7('0x74')](_0x5992a7('0x24'),_0x59b616,_0xb16d3a,_0x5992a7('0x94')),logger[_0x5992a7('0x8c')]('WhatsappAccount,\x20%s,\x20%s,\x20%s,\x20%s',_0x59b616,_0xb16d3a,_0x5992a7('0x94'),JSON['stringify'](_0x192f70)),_0x1e735d[_0x5992a7('0x93')][_0x5992a7('0x75')]==='twilio'?_0x42b110[_0x5992a7('0x31')](_0xb16d3a)[_0x5992a7('0x14')]('Content-Type',_0x5992a7('0xd'))[_0x5992a7('0x9b')](_0x5992a7('0x6e')):_0x42b110['status'](_0xb16d3a)[_0x5992a7('0x69')](_0x192f70);}})[_0x22ecb3('0x6a')](handleError(_0x42b110,null));},exports[_0x14f4dc('0x9b')]=function(_0x38ec80,_0x188c03){const _0x36f2bc=_0x14f4dc;let _0x215de8,_0x3be13f;if(_[_0x36f2bc('0x67')](_0x38ec80[_0x36f2bc('0x6')][_0x36f2bc('0x6')])||_0x38ec80[_0x36f2bc('0x6')]['body']==='')throw new ValidationError('body\x20is\x20mandatory\x20and\x20not\x20empty');if(_[_0x36f2bc('0x67')](_0x38ec80[_0x36f2bc('0x6')]['to']))throw new ValidationError(_0x36f2bc('0x41'));const _0x31f777=_0x38ec80['body']['to'];return db[_0x36f2bc('0xc')][_0x36f2bc('0x9d')]({'where':{'id':_0x38ec80[_0x36f2bc('0x5d')]['id']},'include':[{'model':db[_0x36f2bc('0x79')],'as':_0x36f2bc('0x25'),'include':[{'model':db['CmContact'],'as':_0x36f2bc('0x10'),'where':{'mobile':_0x31f777},'limit':0x1,'order':[[_0x36f2bc('0x55'),'DESC']]}]}]})[_0x36f2bc('0x4')](handleEntityNotFound(_0x188c03,null))[_0x36f2bc('0x4')](function(_0x2c2d8f){const _0x2bbd1b=_0x36f2bc;if(_0x2c2d8f&&_0x2c2d8f[_0x2bbd1b('0x25')]){_0x215de8=_0x2c2d8f[_0x2bbd1b('0x17')]({'plain':!![]});if(_0x215de8[_0x2bbd1b('0x25')]&&_0x215de8[_0x2bbd1b('0x25')][_0x2bbd1b('0x10')][_0x2bbd1b('0x53')])return _0x215de8[_0x2bbd1b('0x25')]['Contacts'][0x0];return db['CmContact']['create'](_['defaults'](_0x38ec80[_0x2bbd1b('0x6')],{'firstName':_0x31f777,'mobile':_0x31f777,'phone':_0x31f777,'ListId':_0x215de8['ListId']}));}})[_0x36f2bc('0x4')](handleEntityNotFound(_0x188c03,null))[_0x36f2bc('0x4')](function(_0xc94d33){const _0x12f17e=_0x36f2bc;if(_0xc94d33)return _0x3be13f=_0xc94d33,db[_0x12f17e('0x3b')]['findOne']({'where':{'ContactId':_0x3be13f['id'],'closed':![],'WhatsappAccountId':_0x215de8['id']}})[_0x12f17e('0x4')](function(_0x3a5e88){const _0x4d1e68=_0x12f17e;if(_0x3a5e88)return[_0x3a5e88,![]];return db['WhatsappInteraction']['create']({'UserId':_0x38ec80[_0x4d1e68('0x9')]['id'],'ContactId':_0x3be13f['id'],'WhatsappAccountId':_0x215de8['id'],'phone':_0x31f777,'firstMsgDirection':_0x4d1e68('0x7'),'Messages':[_[_0x4d1e68('0x18')](_0x38ec80[_0x4d1e68('0x6')],{'read':![],'body':_0x38ec80[_0x4d1e68('0x6')][_0x4d1e68('0x6')],'phone':_0x31f777,'WhatsappAccountId':_0x215de8['id'],'UserId':_0x38ec80['user']['id'],'ContactId':_0x3be13f['id']})]},{'include':[{'model':db[_0x4d1e68('0x46')],'as':_0x4d1e68('0x8f')}]})[_0x4d1e68('0x4')](function(_0x5a0c57){return[_0x5a0c57,!![]];});});})[_0x36f2bc('0x4')](function([_0x27a84c,_0x5153d0]){const _0x2e5047=_0x36f2bc;if(_0x5153d0)return _0x27a84c;return db['WhatsappMessage'][_0x2e5047('0x2a')](_[_0x2e5047('0x18')](_0x38ec80[_0x2e5047('0x6')],{'read':![],'body':_0x38ec80[_0x2e5047('0x6')][_0x2e5047('0x6')],'phone':_0x31f777,'WhatsappAccountId':_0x215de8['id'],'WhatsappInteractionId':_0x27a84c['id'],'UserId':_0x38ec80[_0x2e5047('0x9')]['id'],'ContactId':_0x3be13f['id']}))[_0x2e5047('0x4')](function(_0x14a2d0){const _0x57b634=_0x2e5047;return _0x27a84c[_0x57b634('0x7d')][_0x57b634('0x8f')]=[],_0x27a84c[_0x57b634('0x7d')][_0x57b634('0x8f')][_0x57b634('0x5b')](_0x14a2d0[_0x57b634('0x7d')]),_0x27a84c;});})[_0x36f2bc('0x4')](respondWithResult(_0x188c03,null))['catch'](handleError(_0x188c03,null));}; \ No newline at end of file diff --git a/server/api/whatsappAccount/whatsappAccount.events.js b/server/api/whatsappAccount/whatsappAccount.events.js index 5d0939f..b69a616 100644 --- a/server/api/whatsappAccount/whatsappAccount.events.js +++ b/server/api/whatsappAccount/whatsappAccount.events.js @@ -1 +1 @@ -const a784_0x4dc2=['save','exports','addHook','update','setMaxListeners','undefined','emit','../../mysqldb','events','remove'];(function(_0x1d2217,_0x4dc264){const _0x135ae4=function(_0x3ab5b5){while(--_0x3ab5b5){_0x1d2217['push'](_0x1d2217['shift']());}};_0x135ae4(++_0x4dc264);}(a784_0x4dc2,0xe3));const a784_0x135a=function(_0x1d2217,_0x4dc264){_0x1d2217=_0x1d2217-0x0;let _0x135ae4=a784_0x4dc2[_0x1d2217];return _0x135ae4;};const _0x6d752f=a784_0x135a;'use strict';const EventEmitter=require(_0x6d752f('0x1')),WhatsappAccount=require(_0x6d752f('0x0'))['db']['WhatsappAccount'],WhatsappAccountEvents=new EventEmitter();WhatsappAccountEvents[_0x6d752f('0x7')](0x0);const events={'afterCreate':_0x6d752f('0x3'),'afterUpdate':_0x6d752f('0x6'),'afterDestroy':_0x6d752f('0x2')};function emitEvent(_0x3ab5b5){return function(_0x221c7f){const _0x4ba4df=a784_0x135a;WhatsappAccountEvents[_0x4ba4df('0x9')](_0x3ab5b5+':'+_0x221c7f['id'],_0x221c7f),WhatsappAccountEvents[_0x4ba4df('0x9')](_0x3ab5b5,_0x221c7f);};}for(const e in events){if(typeof events[e]!==_0x6d752f('0x8')){const event=events[e];WhatsappAccount[_0x6d752f('0x5')](e,emitEvent(event));}}module[_0x6d752f('0x4')]=WhatsappAccountEvents; \ No newline at end of file +const a784_0x12c0=['remove','undefined','addHook','../../mysqldb','update','setMaxListeners','events','exports'];(function(_0x11343f,_0x12c049){const _0x4ad438=function(_0x1763c0){while(--_0x1763c0){_0x11343f['push'](_0x11343f['shift']());}};_0x4ad438(++_0x12c049);}(a784_0x12c0,0x1a3));const a784_0x4ad4=function(_0x11343f,_0x12c049){_0x11343f=_0x11343f-0x0;let _0x4ad438=a784_0x12c0[_0x11343f];return _0x4ad438;};const _0x1ac9d7=a784_0x4ad4;'use strict';const EventEmitter=require(_0x1ac9d7('0x3')),WhatsappAccount=require(_0x1ac9d7('0x0'))['db']['WhatsappAccount'],WhatsappAccountEvents=new EventEmitter();WhatsappAccountEvents[_0x1ac9d7('0x2')](0x0);const events={'afterCreate':'save','afterUpdate':_0x1ac9d7('0x1'),'afterDestroy':_0x1ac9d7('0x5')};function emitEvent(_0x1763c0){return function(_0x39ac33){WhatsappAccountEvents['emit'](_0x1763c0+':'+_0x39ac33['id'],_0x39ac33),WhatsappAccountEvents['emit'](_0x1763c0,_0x39ac33);};}for(const e in events){if(typeof events[e]!==_0x1ac9d7('0x6')){const event=events[e];WhatsappAccount[_0x1ac9d7('0x7')](e,emitEvent(event));}}module[_0x1ac9d7('0x4')]=WhatsappAccountEvents; \ No newline at end of file diff --git a/server/api/whatsappAccount/whatsappAccount.model.js b/server/api/whatsappAccount/whatsappAccount.model.js index 25e3904..f07d517 100644 --- a/server/api/whatsappAccount/whatsappAccount.model.js +++ b/server/api/whatsappAccount/whatsappAccount.model.js @@ -1 +1 @@ -const a785_0x51d9=['WhatsappAccount','exports','./whatsappAccount.attributes','define'];(function(_0x11d99a,_0x51d942){const _0x3c5607=function(_0x16f1ec){while(--_0x16f1ec){_0x11d99a['push'](_0x11d99a['shift']());}};_0x3c5607(++_0x51d942);}(a785_0x51d9,0x130));const a785_0x3c56=function(_0x11d99a,_0x51d942){_0x11d99a=_0x11d99a-0x0;let _0x3c5607=a785_0x51d9[_0x11d99a];return _0x3c5607;};const _0x339ba4=a785_0x3c56;'use strict';const attributes=require(_0x339ba4('0x2'));module[_0x339ba4('0x1')]=function(_0x16f1ec){const _0x4537c0=_0x339ba4,_0x3d4c3e=_0x16f1ec[_0x4537c0('0x3')](_0x4537c0('0x0'),attributes,{'tableName':'whatsapp_accounts','paranoid':![],'indexes':[],'timestamps':!![]});return _0x3d4c3e;}; \ No newline at end of file +const a785_0x1440=['exports','whatsapp_accounts','./whatsappAccount.attributes','define'];(function(_0xc3f7b,_0x1440f9){const _0x4e98f4=function(_0x47745b){while(--_0x47745b){_0xc3f7b['push'](_0xc3f7b['shift']());}};_0x4e98f4(++_0x1440f9);}(a785_0x1440,0x115));const a785_0x4e98=function(_0xc3f7b,_0x1440f9){_0xc3f7b=_0xc3f7b-0x0;let _0x4e98f4=a785_0x1440[_0xc3f7b];return _0x4e98f4;};const _0x154883=a785_0x4e98;'use strict';const attributes=require(_0x154883('0x1'));module[_0x154883('0x3')]=function(_0x47745b){const _0x2785c0=_0x154883,_0x4ae87d=_0x47745b[_0x2785c0('0x2')]('WhatsappAccount',attributes,{'tableName':_0x2785c0('0x0'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x4ae87d;}; \ No newline at end of file diff --git a/server/api/whatsappAccount/whatsappAccount.rpc.js b/server/api/whatsappAccount/whatsappAccount.rpc.js index 75eb4c7..9b66494 100644 --- a/server/api/whatsappAccount/whatsappAccount.rpc.js +++ b/server/api/whatsappAccount/whatsappAccount.rpc.js @@ -1 +1 @@ -const a786_0x137e=['include','attributes','findOne','error','../../config/logger','lodash','model','./whatsappAccount.socket','debug','register','ShowWhatsappAccount','WhatsappAccount','raw','stringify','where','options','catch','map','message','../../mysqldb','then'];(function(_0x4c7b89,_0x137edc){const _0x248e54=function(_0x33cbda){while(--_0x33cbda){_0x4c7b89['push'](_0x4c7b89['shift']());}};_0x248e54(++_0x137edc);}(a786_0x137e,0xad));const a786_0x248e=function(_0x4c7b89,_0x137edc){_0x4c7b89=_0x4c7b89-0x0;let _0x248e54=a786_0x137e[_0x4c7b89];return _0x248e54;};const _0x58e47c=a786_0x248e;'use strict';const db=require(_0x58e47c('0xe'))['db'],logger=require(_0x58e47c('0x14'))('rpc'),_=require(_0x58e47c('0x0')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x58e47c('0x2'))[_0x58e47c('0x4')](socket),exports[_0x58e47c('0x5')]=function(_0x33cbda){const _0xaf56fa=this;return new Promise(function(_0xaef63f,_0x316748){const _0x2b5a85=a786_0x248e;return db[_0x2b5a85('0x6')][_0x2b5a85('0x12')]({'raw':_0x33cbda[_0x2b5a85('0xa')]?_0x33cbda[_0x2b5a85('0xa')][_0x2b5a85('0x7')]===undefined?!![]:![]:!![],'where':_0x33cbda[_0x2b5a85('0xa')]?_0x33cbda[_0x2b5a85('0xa')][_0x2b5a85('0x9')]||null:null,'attributes':_0x33cbda[_0x2b5a85('0xa')]?_0x33cbda[_0x2b5a85('0xa')][_0x2b5a85('0x11')]||null:null,'include':_0x33cbda[_0x2b5a85('0xa')]?_0x33cbda['options'][_0x2b5a85('0x10')]?_['map'](_0x33cbda[_0x2b5a85('0xa')][_0x2b5a85('0x10')],function(_0x589727){const _0x3c27f7=_0x2b5a85;return{'model':db[_0x589727[_0x3c27f7('0x1')]],'as':_0x589727['as'],'attributes':_0x589727[_0x3c27f7('0x11')],'include':_0x589727[_0x3c27f7('0x10')]?_[_0x3c27f7('0xc')](_0x589727[_0x3c27f7('0x10')],function(_0x385c7c){const _0x281470=_0x3c27f7;return{'model':db[_0x385c7c[_0x281470('0x1')]],'as':_0x385c7c['as'],'attributes':_0x385c7c[_0x281470('0x11')],'include':_0x385c7c[_0x281470('0x10')]?_['map'](_0x385c7c[_0x281470('0x10')],function(_0x41eb83){const _0x383c66=_0x281470;return{'model':db[_0x41eb83[_0x383c66('0x1')]],'as':_0x41eb83['as'],'attributes':_0x41eb83[_0x383c66('0x11')]};}):[]};}):[]};}):[]:[]})[_0x2b5a85('0xf')](function(_0x2f25f3){const _0x21abb8=_0x2b5a85;logger['info'](_0x21abb8('0x5'),_0x33cbda),logger[_0x21abb8('0x3')](_0x21abb8('0x5'),_0x33cbda,JSON[_0x21abb8('0x8')](_0x2f25f3)),_0xaef63f(_0x2f25f3);})[_0x2b5a85('0xb')](function(_0x1d939a){const _0x3022ed=_0x2b5a85;logger[_0x3022ed('0x13')](_0x3022ed('0x5'),_0x1d939a[_0x3022ed('0xd')],_0x33cbda),_0x316748(_0xaf56fa[_0x3022ed('0x13')](0x1f4,_0x1d939a['message']));});});}; \ No newline at end of file +const a786_0x4fb7=['../../mysqldb','include','ShowWhatsappAccount','map','where','message','raw','rpc','../../config/logger','catch','attributes','stringify','WhatsappAccount','info','options','error','debug','model'];(function(_0x25b355,_0x4fb7c7){const _0x4aedc1=function(_0x432de8){while(--_0x432de8){_0x25b355['push'](_0x25b355['shift']());}};_0x4aedc1(++_0x4fb7c7);}(a786_0x4fb7,0x1b6));const a786_0x4aed=function(_0x25b355,_0x4fb7c7){_0x25b355=_0x25b355-0x0;let _0x4aedc1=a786_0x4fb7[_0x25b355];return _0x4aedc1;};const _0x2b80d7=a786_0x4aed;'use strict';const db=require(_0x2b80d7('0xc'))['db'],logger=require(_0x2b80d7('0x2'))(_0x2b80d7('0x1')),_=require('lodash'),{getSocket}=require('../../rediscache'),socket=getSocket();require('./whatsappAccount.socket')['register'](socket),exports[_0x2b80d7('0xe')]=function(_0x432de8){const _0x1cead2=this;return new Promise(function(_0x54fcbe,_0x5ec8ed){const _0x14bd12=a786_0x4aed;return db[_0x14bd12('0x6')]['findOne']({'raw':_0x432de8[_0x14bd12('0x8')]?_0x432de8[_0x14bd12('0x8')][_0x14bd12('0x0')]===undefined?!![]:![]:!![],'where':_0x432de8[_0x14bd12('0x8')]?_0x432de8['options'][_0x14bd12('0x10')]||null:null,'attributes':_0x432de8[_0x14bd12('0x8')]?_0x432de8[_0x14bd12('0x8')][_0x14bd12('0x4')]||null:null,'include':_0x432de8['options']?_0x432de8[_0x14bd12('0x8')][_0x14bd12('0xd')]?_[_0x14bd12('0xf')](_0x432de8[_0x14bd12('0x8')]['include'],function(_0x341604){const _0x1388cd=_0x14bd12;return{'model':db[_0x341604[_0x1388cd('0xb')]],'as':_0x341604['as'],'attributes':_0x341604['attributes'],'include':_0x341604[_0x1388cd('0xd')]?_[_0x1388cd('0xf')](_0x341604[_0x1388cd('0xd')],function(_0x4e0801){const _0x4f57c9=_0x1388cd;return{'model':db[_0x4e0801[_0x4f57c9('0xb')]],'as':_0x4e0801['as'],'attributes':_0x4e0801[_0x4f57c9('0x4')],'include':_0x4e0801[_0x4f57c9('0xd')]?_[_0x4f57c9('0xf')](_0x4e0801[_0x4f57c9('0xd')],function(_0x5e2e27){const _0x19a37a=_0x4f57c9;return{'model':db[_0x5e2e27[_0x19a37a('0xb')]],'as':_0x5e2e27['as'],'attributes':_0x5e2e27[_0x19a37a('0x4')]};}):[]};}):[]};}):[]:[]})['then'](function(_0x192589){const _0x1be178=_0x14bd12;logger[_0x1be178('0x7')](_0x1be178('0xe'),_0x432de8),logger[_0x1be178('0xa')]('ShowWhatsappAccount',_0x432de8,JSON[_0x1be178('0x5')](_0x192589)),_0x54fcbe(_0x192589);})[_0x14bd12('0x3')](function(_0x4b4f37){const _0x32abdb=_0x14bd12;logger['error'](_0x32abdb('0xe'),_0x4b4f37['message'],_0x432de8),_0x5ec8ed(_0x1cead2[_0x32abdb('0x9')](0x1f4,_0x4b4f37[_0x32abdb('0x11')]));});});}; \ No newline at end of file diff --git a/server/api/whatsappAccount/whatsappAccount.socket.js b/server/api/whatsappAccount/whatsappAccount.socket.js index 44b5fb5..1d718b6 100644 --- a/server/api/whatsappAccount/whatsappAccount.socket.js +++ b/server/api/whatsappAccount/whatsappAccount.socket.js @@ -1 +1 @@ -const a787_0x3b72=['update','register','length','save','emit','./whatsappAccount.events','remove'];(function(_0x4b7e56,_0x3b729){const _0x4bbf18=function(_0x317805){while(--_0x317805){_0x4b7e56['push'](_0x4b7e56['shift']());}};_0x4bbf18(++_0x3b729);}(a787_0x3b72,0x199));const a787_0x4bbf=function(_0x4b7e56,_0x3b729){_0x4b7e56=_0x4b7e56-0x0;let _0x4bbf18=a787_0x3b72[_0x4b7e56];return _0x4bbf18;};const _0x3d47ba=a787_0x4bbf;'use strict';const WhatsappAccountEvents=require(_0x3d47ba('0x2')),events=[_0x3d47ba('0x0'),_0x3d47ba('0x3'),_0x3d47ba('0x4')];function createListener(_0x317805,_0x3a642c){return function(_0x26744a){const _0x2293a7=a787_0x4bbf;_0x3a642c[_0x2293a7('0x1')](_0x317805,_0x26744a);};}exports[_0x3d47ba('0x5')]=function(_0x54d463){const _0x272c4c=_0x3d47ba;for(let _0x47990d=0x0,_0x3f3c4a=events[_0x272c4c('0x6')];_0x47990d<_0x3f3c4a;_0x47990d++){const _0x5dc5e0=events[_0x47990d],_0x2b2c10=createListener('whatsappAccount:'+_0x5dc5e0,_0x54d463);WhatsappAccountEvents['on'](_0x5dc5e0,_0x2b2c10);}}; \ No newline at end of file +const a787_0x32ae=['update','register','./whatsappAccount.events','save','whatsappAccount:','remove','length'];(function(_0x5c1ccc,_0x32aedc){const _0x1c105f=function(_0x3d1c76){while(--_0x3d1c76){_0x5c1ccc['push'](_0x5c1ccc['shift']());}};_0x1c105f(++_0x32aedc);}(a787_0x32ae,0x13b));const a787_0x1c10=function(_0x5c1ccc,_0x32aedc){_0x5c1ccc=_0x5c1ccc-0x0;let _0x1c105f=a787_0x32ae[_0x5c1ccc];return _0x1c105f;};const _0x182d82=a787_0x1c10;'use strict';const WhatsappAccountEvents=require(_0x182d82('0x2')),events=[_0x182d82('0x3'),_0x182d82('0x5'),_0x182d82('0x0')];function createListener(_0x3d1c76,_0x1c02fc){return function(_0x154bb8){_0x1c02fc['emit'](_0x3d1c76,_0x154bb8);};}exports[_0x182d82('0x1')]=function(_0x3ca067){const _0x53a1ed=_0x182d82;for(let _0x4b0ffa=0x0,_0x152e9f=events[_0x53a1ed('0x6')];_0x4b0ffa<_0x152e9f;_0x4b0ffa++){const _0x204033=events[_0x4b0ffa],_0x4d5675=createListener(_0x53a1ed('0x4')+_0x204033,_0x3ca067);WhatsappAccountEvents['on'](_0x204033,_0x4d5675);}}; \ No newline at end of file diff --git a/server/api/whatsappApplication/index.js b/server/api/whatsappApplication/index.js index c8c511c..b0a8c3c 100644 --- a/server/api/whatsappApplication/index.js +++ b/server/api/whatsappApplication/index.js @@ -1 +1 @@ -const a788_0x46f7=['Router','get','put','isAuthenticated','create','delete','post','../../components/auth/service','show','exports','express','/:id','./whatsappApplication.controller'];(function(_0x1c6f83,_0x46f727){const _0x3299c1=function(_0x44089c){while(--_0x44089c){_0x1c6f83['push'](_0x1c6f83['shift']());}};_0x3299c1(++_0x46f727);}(a788_0x46f7,0x16a));const a788_0x3299=function(_0x1c6f83,_0x46f727){_0x1c6f83=_0x1c6f83-0x0;let _0x3299c1=a788_0x46f7[_0x1c6f83];return _0x3299c1;};const _0x11dac3=a788_0x3299;'use strict';const express=require(_0x11dac3('0xc')),router=express[_0x11dac3('0x2')](),auth=require(_0x11dac3('0x9')),controller=require(_0x11dac3('0x1'));router['get']('/',auth[_0x11dac3('0x5')](),controller['index']),router[_0x11dac3('0x3')]('/:id',auth[_0x11dac3('0x5')](),controller[_0x11dac3('0xa')]),router[_0x11dac3('0x8')]('/',auth[_0x11dac3('0x5')](),controller[_0x11dac3('0x6')]),router[_0x11dac3('0x4')](_0x11dac3('0x0'),auth[_0x11dac3('0x5')](),controller['update']),router[_0x11dac3('0x7')](_0x11dac3('0x0'),auth[_0x11dac3('0x5')](),controller['destroy']),module[_0x11dac3('0xb')]=router; \ No newline at end of file +const a788_0x267d=['./whatsappApplication.controller','/:id','isAuthenticated','index','destroy','get','Router','delete','put','update','post','show','exports'];(function(_0x261a71,_0x267d83){const _0x360cb1=function(_0x59663b){while(--_0x59663b){_0x261a71['push'](_0x261a71['shift']());}};_0x360cb1(++_0x267d83);}(a788_0x267d,0x1ae));const a788_0x360c=function(_0x261a71,_0x267d83){_0x261a71=_0x261a71-0x0;let _0x360cb1=a788_0x267d[_0x261a71];return _0x360cb1;};const _0x5eca48=a788_0x360c;'use strict';const express=require('express'),router=express[_0x5eca48('0x5')](),auth=require('../../components/auth/service'),controller=require(_0x5eca48('0xc'));router[_0x5eca48('0x4')]('/',auth[_0x5eca48('0x1')](),controller[_0x5eca48('0x2')]),router[_0x5eca48('0x4')]('/:id',auth[_0x5eca48('0x1')](),controller[_0x5eca48('0xa')]),router[_0x5eca48('0x9')]('/',auth[_0x5eca48('0x1')](),controller['create']),router[_0x5eca48('0x7')](_0x5eca48('0x0'),auth['isAuthenticated'](),controller[_0x5eca48('0x8')]),router[_0x5eca48('0x6')](_0x5eca48('0x0'),auth[_0x5eca48('0x1')](),controller[_0x5eca48('0x3')]),module[_0x5eca48('0xb')]=router; \ No newline at end of file diff --git a/server/api/whatsappApplication/whatsappApplication.attributes.js b/server/api/whatsappApplication/whatsappApplication.attributes.js index 6713444..9e4dfa8 100644 --- a/server/api/whatsappApplication/whatsappApplication.attributes.js +++ b/server/api/whatsappApplication/whatsappApplication.attributes.js @@ -1 +1 @@ -const a789_0x4f94=['sequelize','TEXT','noop','INTEGER','*,*,*,*','STRING'];(function(_0x151124,_0x4f946a){const _0x46c21e=function(_0x3f1a39){while(--_0x3f1a39){_0x151124['push'](_0x151124['shift']());}};_0x46c21e(++_0x4f946a);}(a789_0x4f94,0x163));const a789_0x46c2=function(_0x151124,_0x4f946a){_0x151124=_0x151124-0x0;let _0x46c21e=a789_0x4f94[_0x151124];return _0x46c21e;};const _0x51be27=a789_0x46c2;'use strict';const Sequelize=require(_0x51be27('0x5'));module['exports']={'priority':{'type':Sequelize[_0x51be27('0x2')],'allowNull':![]},'app':{'type':Sequelize[_0x51be27('0x4')],'allowNull':![],'defaultValue':_0x51be27('0x1')},'appdata':{'type':Sequelize[_0x51be27('0x0')]()},'description':{'type':Sequelize['STRING']},'interval':{'type':Sequelize[_0x51be27('0x4')],'defaultValue':_0x51be27('0x3')}}; \ No newline at end of file +const a789_0x4495=['noop','TEXT','STRING','*,*,*,*','exports','sequelize'];(function(_0x4bc69c,_0x449502){const _0x1e2101=function(_0x21fd4a){while(--_0x21fd4a){_0x4bc69c['push'](_0x4bc69c['shift']());}};_0x1e2101(++_0x449502);}(a789_0x4495,0x146));const a789_0x1e21=function(_0x4bc69c,_0x449502){_0x4bc69c=_0x4bc69c-0x0;let _0x1e2101=a789_0x4495[_0x4bc69c];return _0x1e2101;};const _0x230684=a789_0x1e21;'use strict';const Sequelize=require(_0x230684('0x3'));module[_0x230684('0x2')]={'priority':{'type':Sequelize['INTEGER'],'allowNull':![]},'app':{'type':Sequelize[_0x230684('0x0')],'allowNull':![],'defaultValue':_0x230684('0x4')},'appdata':{'type':Sequelize[_0x230684('0x5')]()},'description':{'type':Sequelize[_0x230684('0x0')]},'interval':{'type':Sequelize[_0x230684('0x0')],'defaultValue':_0x230684('0x1')}}; \ No newline at end of file diff --git a/server/api/whatsappApplication/whatsappApplication.controller.js b/server/api/whatsappApplication/whatsappApplication.controller.js index 36e49ae..bc8208b 100644 --- a/server/api/whatsappApplication/whatsappApplication.controller.js +++ b/server/api/whatsappApplication/whatsappApplication.controller.js @@ -1 +1 @@ -const a790_0x10f2=['create','filters','length','order','sort','api','fields','limit','destroy','pick','name','include','then','includeAll','undefined','query','stack','../../components/parsers/qs','error','where','findAll','options','fieldName','../../config/logger','nolimit','attributes','json','rows','send','end','sendStatus','model','count','offset','map','params','keys','lodash','rawAttributes','VIRTUAL','update','findOne','filter','status','like','merge','intersection','catch','show','WhatsappApplication','type','body'];(function(_0x1004a8,_0x10f2f9){const _0x53c6c8=function(_0x19a0f7){while(--_0x19a0f7){_0x1004a8['push'](_0x1004a8['shift']());}};_0x53c6c8(++_0x10f2f9);}(a790_0x10f2,0x1c6));const a790_0x53c6=function(_0x1004a8,_0x10f2f9){_0x1004a8=_0x1004a8-0x0;let _0x53c6c8=a790_0x10f2[_0x1004a8];return _0x53c6c8;};const _0x1142c5=a790_0x53c6;'use strict';const _=require(_0x1142c5('0x33')),qs=require(_0x1142c5('0x1f')),logger=require(_0x1142c5('0x25'))(_0x1142c5('0x13')),db=require('../../mysqldb')['db'],{Op}=require('sequelize');function respondWithResult(_0x19a0f7,_0x3cb5c3){return _0x3cb5c3=_0x3cb5c3||0xc8,function(_0x197620){const _0x154e2c=a790_0x53c6;if(_0x197620)return _0x19a0f7[_0x154e2c('0x5')](_0x3cb5c3)[_0x154e2c('0x28')](_0x197620);};}function respondWithFilteredResult(_0x358cc7,_0x21a78f){return function(_0x888657){const _0x3faf9b=a790_0x53c6;if(_0x888657){const _0xf67bb0=_0x888657['count'],_0x5be4b1=_0x21a78f['offset'];let _0x5f5ca6=_0x21a78f[_0x3faf9b('0x2f')]+_0x21a78f[_0x3faf9b('0x15')],_0x1840e8;return _0x5f5ca6>=_0xf67bb0?(_0x5f5ca6=_0xf67bb0,_0x1840e8=0xc8):_0x1840e8=0xce,_0x358cc7[_0x3faf9b('0x5')](_0x1840e8),_0x358cc7['set']('Content-Range',_0x5be4b1+'-'+_0x5f5ca6+'/'+_0xf67bb0)[_0x3faf9b('0x28')](_0x888657);}return null;};}function saveUpdates(_0x24247f){return function(_0x4d2c5f){const _0xd80df7=a790_0x53c6;if(_0x4d2c5f)return _0x4d2c5f[_0xd80df7('0x2')](_0x24247f)['then'](function(_0x312c40){return _0x312c40;});return null;};}function removeEntity(_0x4eda4a){return function(_0x2953e5){const _0x5b0827=a790_0x53c6;if(_0x2953e5)return _0x2953e5[_0x5b0827('0x16')]()[_0x5b0827('0x1a')](function(){const _0x2af7cf=_0x5b0827;_0x4eda4a[_0x2af7cf('0x5')](0xcc)[_0x2af7cf('0x2b')]();});};}function handleEntityNotFound(_0x3dfc14){return function(_0x25c679){const _0x337f84=a790_0x53c6;return!_0x25c679&&_0x3dfc14[_0x337f84('0x2c')](0x194),_0x25c679;};}function handleError(_0x100017,_0x206a59){return _0x206a59=_0x206a59||0x1f4,function(_0x5e5fd1){const _0x4dcd33=a790_0x53c6;logger[_0x4dcd33('0x20')](_0x5e5fd1[_0x4dcd33('0x1e')]),_0x5e5fd1['name']&&delete _0x5e5fd1[_0x4dcd33('0x18')],_0x100017[_0x4dcd33('0x5')](_0x206a59)[_0x4dcd33('0x2a')](_0x5e5fd1);};}exports['index']=function(_0x3ec957,_0x2f4f1d){const _0x3f51c4=_0x1142c5;let _0x207ef5={};const _0x523ff5={},_0x205c38={'count':0x0,'rows':[]},_0x20c6e9=_[_0x3f51c4('0x30')](db[_0x3f51c4('0xb')][_0x3f51c4('0x0')],function(_0xe929b8){const _0x17f8bf=_0x3f51c4;return{'name':_0xe929b8[_0x17f8bf('0x24')],'type':_0xe929b8[_0x17f8bf('0xc')]['key']};});_0x523ff5[_0x3f51c4('0x2d')]=_[_0x3f51c4('0x30')](_0x20c6e9,_0x3f51c4('0x18')),_0x523ff5['query']=_['keys'](_0x3ec957['query']),_0x523ff5[_0x3f51c4('0xf')]=_['intersection'](_0x523ff5[_0x3f51c4('0x2d')],_0x523ff5['query']),_0x207ef5['attributes']=_[_0x3f51c4('0x8')](_0x523ff5[_0x3f51c4('0x2d')],qs[_0x3f51c4('0x14')](_0x3ec957['query'][_0x3f51c4('0x14')])),_0x207ef5[_0x3f51c4('0x27')]=_0x207ef5['attributes'][_0x3f51c4('0x10')]?_0x207ef5[_0x3f51c4('0x27')]:_0x523ff5[_0x3f51c4('0x2d')];typeof _0x3ec957[_0x3f51c4('0x1d')][_0x3f51c4('0x26')]===_0x3f51c4('0x1c')&&(_0x207ef5[_0x3f51c4('0x15')]=qs['limit'](_0x3ec957[_0x3f51c4('0x1d')][_0x3f51c4('0x15')]),_0x207ef5['offset']=qs[_0x3f51c4('0x2f')](_0x3ec957['query'][_0x3f51c4('0x2f')]));_0x207ef5[_0x3f51c4('0x11')]=qs['sort'](_0x3ec957[_0x3f51c4('0x1d')][_0x3f51c4('0x12')]),_0x207ef5['where']=qs['filters'](_[_0x3f51c4('0x17')](_0x3ec957[_0x3f51c4('0x1d')],_0x523ff5[_0x3f51c4('0xf')]),_0x20c6e9);_0x3ec957[_0x3f51c4('0x1d')]['filter']&&(_0x207ef5[_0x3f51c4('0x21')]=_['merge'](_0x207ef5[_0x3f51c4('0x21')],{[Op['or']]:_['map'](_0x20c6e9,function(_0xe9faf3){const _0x59e380=_0x3f51c4;if(_0xe9faf3[_0x59e380('0xc')]!==_0x59e380('0x1')){const _0x1efb68={};return _0x1efb68[_0xe9faf3[_0x59e380('0x18')]]={[Op[_0x59e380('0x6')]]:'%'+_0x3ec957[_0x59e380('0x1d')][_0x59e380('0x4')]+'%'},_0x1efb68;}})}));_0x207ef5=_[_0x3f51c4('0x7')]({},_0x207ef5,_0x3ec957[_0x3f51c4('0x23')]);const _0x4dd03b={'where':_0x207ef5[_0x3f51c4('0x21')]};return db['WhatsappApplication']['count'](_0x4dd03b)[_0x3f51c4('0x1a')](function(_0x235d68){const _0x327ab0=_0x3f51c4;return _0x205c38[_0x327ab0('0x2e')]=_0x235d68,_0x3ec957['query'][_0x327ab0('0x1b')]&&(_0x207ef5[_0x327ab0('0x19')]=[{'all':!![]}]),db[_0x327ab0('0xb')][_0x327ab0('0x22')](_0x207ef5);})[_0x3f51c4('0x1a')](function(_0x125ec2){const _0x5f574a=_0x3f51c4;return _0x205c38[_0x5f574a('0x29')]=_0x125ec2,_0x205c38;})['then'](respondWithFilteredResult(_0x2f4f1d,_0x207ef5))[_0x3f51c4('0x9')](handleError(_0x2f4f1d,null));},exports[_0x1142c5('0xa')]=function(_0x5a93e3,_0x256564){const _0xab3b6=_0x1142c5;let _0x4c474e={'raw':!![],'where':{'id':_0x5a93e3[_0xab3b6('0x31')]['id']}};const _0x589037={};return _0x589037[_0xab3b6('0x2d')]=_['keys'](db[_0xab3b6('0xb')][_0xab3b6('0x0')]),_0x589037[_0xab3b6('0x1d')]=_[_0xab3b6('0x32')](_0x5a93e3[_0xab3b6('0x1d')]),_0x589037[_0xab3b6('0xf')]=_[_0xab3b6('0x8')](_0x589037[_0xab3b6('0x2d')],_0x589037[_0xab3b6('0x1d')]),_0x4c474e[_0xab3b6('0x27')]=_[_0xab3b6('0x8')](_0x589037[_0xab3b6('0x2d')],qs[_0xab3b6('0x14')](_0x5a93e3[_0xab3b6('0x1d')]['fields'])),_0x4c474e[_0xab3b6('0x27')]=_0x4c474e[_0xab3b6('0x27')][_0xab3b6('0x10')]?_0x4c474e[_0xab3b6('0x27')]:_0x589037[_0xab3b6('0x2d')],_0x5a93e3['query']['includeAll']&&(_0x4c474e['include']=[{'all':!![]}]),_0x4c474e=_[_0xab3b6('0x7')]({},_0x4c474e,_0x5a93e3[_0xab3b6('0x23')]),db[_0xab3b6('0xb')]['findOne'](_0x4c474e)[_0xab3b6('0x1a')](handleEntityNotFound(_0x256564,null))[_0xab3b6('0x1a')](respondWithResult(_0x256564,null))['catch'](handleError(_0x256564,null));},exports[_0x1142c5('0xe')]=function(_0x4190c0,_0x3f428d){const _0x432274=_0x1142c5;return db[_0x432274('0xb')]['create'](_0x4190c0['body'],{})[_0x432274('0x1a')](respondWithResult(_0x3f428d,0xc9))[_0x432274('0x9')](handleError(_0x3f428d,null));},exports['update']=function(_0x1728ff,_0x6c31fb){const _0x2f0477=_0x1142c5;return _0x1728ff[_0x2f0477('0xd')]['id']&&delete _0x1728ff['body']['id'],db[_0x2f0477('0xb')][_0x2f0477('0x3')]({'where':{'id':_0x1728ff[_0x2f0477('0x31')]['id']}})[_0x2f0477('0x1a')](handleEntityNotFound(_0x6c31fb,null))[_0x2f0477('0x1a')](saveUpdates(_0x1728ff[_0x2f0477('0xd')],null))[_0x2f0477('0x1a')](respondWithResult(_0x6c31fb,null))[_0x2f0477('0x9')](handleError(_0x6c31fb,null));},exports['destroy']=function(_0x427261,_0x2a9298){const _0x4422ee=_0x1142c5;return db[_0x4422ee('0xb')][_0x4422ee('0x3')]({'where':{'id':_0x427261[_0x4422ee('0x31')]['id']}})[_0x4422ee('0x1a')](handleEntityNotFound(_0x2a9298,null))[_0x4422ee('0x1a')](removeEntity(_0x2a9298,null))[_0x4422ee('0x9')](handleError(_0x2a9298,null));}; \ No newline at end of file +const a790_0x3165=['Content-Range','count','query','sendStatus','WhatsappApplication','intersection','merge','fieldName','body','catch','include','order','params','update','filters','findAll','VIRTUAL','offset','json','show','keys','then','create','findOne','undefined','stack','send','model','name','rows','includeAll','rawAttributes','filter','where','sort','fields','options','type','nolimit','map','status','attributes','index','limit','destroy'];(function(_0x5727ba,_0x3165f4){const _0x509e7f=function(_0x44f5ac){while(--_0x44f5ac){_0x5727ba['push'](_0x5727ba['shift']());}};_0x509e7f(++_0x3165f4);}(a790_0x3165,0x1c8));const a790_0x509e=function(_0x5727ba,_0x3165f4){_0x5727ba=_0x5727ba-0x0;let _0x509e7f=a790_0x3165[_0x5727ba];return _0x509e7f;};const _0xdcea9e=a790_0x509e;'use strict';const _=require('lodash'),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')('api'),db=require('../../mysqldb')['db'],{Op}=require('sequelize');function respondWithResult(_0x44f5ac,_0xe13e22){return _0xe13e22=_0xe13e22||0xc8,function(_0x14b385){const _0x4b6bf0=a790_0x509e;if(_0x14b385)return _0x44f5ac[_0x4b6bf0('0x22')](_0xe13e22)[_0x4b6bf0('0xc')](_0x14b385);};}function respondWithFilteredResult(_0x536fa3,_0x4953d7){return function(_0x3b6550){const _0x31396e=a790_0x509e;if(_0x3b6550){const _0x13c1a3=_0x3b6550[_0x31396e('0x28')],_0x93590=_0x4953d7[_0x31396e('0xb')];let _0x2c8ecd=_0x4953d7[_0x31396e('0xb')]+_0x4953d7['limit'],_0x2bdeba;return _0x2c8ecd>=_0x13c1a3?(_0x2c8ecd=_0x13c1a3,_0x2bdeba=0xc8):_0x2bdeba=0xce,_0x536fa3[_0x31396e('0x22')](_0x2bdeba),_0x536fa3['set'](_0x31396e('0x27'),_0x93590+'-'+_0x2c8ecd+'/'+_0x13c1a3)['json'](_0x3b6550);}return null;};}function saveUpdates(_0x4e7728){return function(_0x3d319e){const _0x130bc0=a790_0x509e;if(_0x3d319e)return _0x3d319e[_0x130bc0('0x7')](_0x4e7728)[_0x130bc0('0xf')](function(_0xa7da21){return _0xa7da21;});return null;};}function removeEntity(_0x241df4){return function(_0x5166f8){const _0x53d25d=a790_0x509e;if(_0x5166f8)return _0x5166f8[_0x53d25d('0x26')]()[_0x53d25d('0xf')](function(){const _0x494578=_0x53d25d;_0x241df4[_0x494578('0x22')](0xcc)['end']();});};}function handleEntityNotFound(_0x571243){return function(_0x2f3ebd){const _0x26a4af=a790_0x509e;return!_0x2f3ebd&&_0x571243[_0x26a4af('0x2a')](0x194),_0x2f3ebd;};}function handleError(_0x90cb40,_0xb5b32d){return _0xb5b32d=_0xb5b32d||0x1f4,function(_0x3774ee){const _0x362569=a790_0x509e;logger['error'](_0x3774ee[_0x362569('0x13')]),_0x3774ee[_0x362569('0x16')]&&delete _0x3774ee['name'],_0x90cb40['status'](_0xb5b32d)[_0x362569('0x14')](_0x3774ee);};}exports[_0xdcea9e('0x24')]=function(_0x5bc927,_0x5990a8){const _0x13ca8f=_0xdcea9e;let _0x5d2ac0={};const _0x5e429c={},_0x242ab9={'count':0x0,'rows':[]},_0x4c4016=_['map'](db['WhatsappApplication'][_0x13ca8f('0x19')],function(_0x31eb7c){const _0xd3f29c=_0x13ca8f;return{'name':_0x31eb7c[_0xd3f29c('0x1')],'type':_0x31eb7c['type']['key']};});_0x5e429c[_0x13ca8f('0x15')]=_[_0x13ca8f('0x21')](_0x4c4016,'name'),_0x5e429c[_0x13ca8f('0x29')]=_[_0x13ca8f('0xe')](_0x5bc927[_0x13ca8f('0x29')]),_0x5e429c[_0x13ca8f('0x8')]=_[_0x13ca8f('0x2c')](_0x5e429c[_0x13ca8f('0x15')],_0x5e429c[_0x13ca8f('0x29')]),_0x5d2ac0[_0x13ca8f('0x23')]=_['intersection'](_0x5e429c[_0x13ca8f('0x15')],qs['fields'](_0x5bc927[_0x13ca8f('0x29')]['fields'])),_0x5d2ac0['attributes']=_0x5d2ac0[_0x13ca8f('0x23')]['length']?_0x5d2ac0['attributes']:_0x5e429c['model'];typeof _0x5bc927[_0x13ca8f('0x29')][_0x13ca8f('0x20')]===_0x13ca8f('0x12')&&(_0x5d2ac0[_0x13ca8f('0x25')]=qs[_0x13ca8f('0x25')](_0x5bc927[_0x13ca8f('0x29')]['limit']),_0x5d2ac0[_0x13ca8f('0xb')]=qs[_0x13ca8f('0xb')](_0x5bc927['query'][_0x13ca8f('0xb')]));_0x5d2ac0[_0x13ca8f('0x5')]=qs[_0x13ca8f('0x1c')](_0x5bc927[_0x13ca8f('0x29')][_0x13ca8f('0x1c')]),_0x5d2ac0[_0x13ca8f('0x1b')]=qs[_0x13ca8f('0x8')](_['pick'](_0x5bc927[_0x13ca8f('0x29')],_0x5e429c[_0x13ca8f('0x8')]),_0x4c4016);_0x5bc927['query'][_0x13ca8f('0x1a')]&&(_0x5d2ac0[_0x13ca8f('0x1b')]=_[_0x13ca8f('0x0')](_0x5d2ac0[_0x13ca8f('0x1b')],{[Op['or']]:_[_0x13ca8f('0x21')](_0x4c4016,function(_0x3cc220){const _0x4834e5=_0x13ca8f;if(_0x3cc220[_0x4834e5('0x1f')]!==_0x4834e5('0xa')){const _0xacddc6={};return _0xacddc6[_0x3cc220[_0x4834e5('0x16')]]={[Op['like']]:'%'+_0x5bc927['query'][_0x4834e5('0x1a')]+'%'},_0xacddc6;}})}));_0x5d2ac0=_[_0x13ca8f('0x0')]({},_0x5d2ac0,_0x5bc927[_0x13ca8f('0x1e')]);const _0x4a840f={'where':_0x5d2ac0['where']};return db[_0x13ca8f('0x2b')][_0x13ca8f('0x28')](_0x4a840f)[_0x13ca8f('0xf')](function(_0x769135){const _0x592e48=_0x13ca8f;return _0x242ab9[_0x592e48('0x28')]=_0x769135,_0x5bc927['query'][_0x592e48('0x18')]&&(_0x5d2ac0['include']=[{'all':!![]}]),db[_0x592e48('0x2b')][_0x592e48('0x9')](_0x5d2ac0);})[_0x13ca8f('0xf')](function(_0x5aaef9){const _0x4b20ae=_0x13ca8f;return _0x242ab9[_0x4b20ae('0x17')]=_0x5aaef9,_0x242ab9;})[_0x13ca8f('0xf')](respondWithFilteredResult(_0x5990a8,_0x5d2ac0))[_0x13ca8f('0x3')](handleError(_0x5990a8,null));},exports[_0xdcea9e('0xd')]=function(_0x5ad74a,_0x3d312c){const _0x27debc=_0xdcea9e;let _0x1b1c1c={'raw':!![],'where':{'id':_0x5ad74a[_0x27debc('0x6')]['id']}};const _0x3c9e5e={};return _0x3c9e5e[_0x27debc('0x15')]=_[_0x27debc('0xe')](db[_0x27debc('0x2b')][_0x27debc('0x19')]),_0x3c9e5e[_0x27debc('0x29')]=_[_0x27debc('0xe')](_0x5ad74a[_0x27debc('0x29')]),_0x3c9e5e[_0x27debc('0x8')]=_[_0x27debc('0x2c')](_0x3c9e5e[_0x27debc('0x15')],_0x3c9e5e[_0x27debc('0x29')]),_0x1b1c1c[_0x27debc('0x23')]=_[_0x27debc('0x2c')](_0x3c9e5e[_0x27debc('0x15')],qs[_0x27debc('0x1d')](_0x5ad74a[_0x27debc('0x29')][_0x27debc('0x1d')])),_0x1b1c1c[_0x27debc('0x23')]=_0x1b1c1c[_0x27debc('0x23')]['length']?_0x1b1c1c[_0x27debc('0x23')]:_0x3c9e5e[_0x27debc('0x15')],_0x5ad74a[_0x27debc('0x29')][_0x27debc('0x18')]&&(_0x1b1c1c[_0x27debc('0x4')]=[{'all':!![]}]),_0x1b1c1c=_['merge']({},_0x1b1c1c,_0x5ad74a[_0x27debc('0x1e')]),db['WhatsappApplication'][_0x27debc('0x11')](_0x1b1c1c)['then'](handleEntityNotFound(_0x3d312c,null))[_0x27debc('0xf')](respondWithResult(_0x3d312c,null))[_0x27debc('0x3')](handleError(_0x3d312c,null));},exports[_0xdcea9e('0x10')]=function(_0x4c7f88,_0x28aa7f){const _0x41a4e1=_0xdcea9e;return db[_0x41a4e1('0x2b')]['create'](_0x4c7f88[_0x41a4e1('0x2')],{})[_0x41a4e1('0xf')](respondWithResult(_0x28aa7f,0xc9))['catch'](handleError(_0x28aa7f,null));},exports[_0xdcea9e('0x7')]=function(_0x36e2a0,_0x46fc95){const _0x8d719d=_0xdcea9e;return _0x36e2a0[_0x8d719d('0x2')]['id']&&delete _0x36e2a0[_0x8d719d('0x2')]['id'],db[_0x8d719d('0x2b')][_0x8d719d('0x11')]({'where':{'id':_0x36e2a0[_0x8d719d('0x6')]['id']}})[_0x8d719d('0xf')](handleEntityNotFound(_0x46fc95,null))[_0x8d719d('0xf')](saveUpdates(_0x36e2a0[_0x8d719d('0x2')],null))[_0x8d719d('0xf')](respondWithResult(_0x46fc95,null))['catch'](handleError(_0x46fc95,null));},exports[_0xdcea9e('0x26')]=function(_0x1e63a1,_0x508bee){const _0x496be1=_0xdcea9e;return db['WhatsappApplication']['findOne']({'where':{'id':_0x1e63a1[_0x496be1('0x6')]['id']}})[_0x496be1('0xf')](handleEntityNotFound(_0x508bee,null))[_0x496be1('0xf')](removeEntity(_0x508bee,null))[_0x496be1('0x3')](handleError(_0x508bee,null));}; \ No newline at end of file diff --git a/server/api/whatsappApplication/whatsappApplication.model.js b/server/api/whatsappApplication/whatsappApplication.model.js index 15e878f..9b11fdd 100644 --- a/server/api/whatsappApplication/whatsappApplication.model.js +++ b/server/api/whatsappApplication/whatsappApplication.model.js @@ -1 +1 @@ -const a791_0xc7c0=['exports','whatsapp_applications','./whatsappApplication.attributes','WhatsappApplication','define','utf8mb4_unicode_ci','utf8mb4'];(function(_0x1da535,_0xc7c053){const _0x5a2933=function(_0x29d43f){while(--_0x29d43f){_0x1da535['push'](_0x1da535['shift']());}};_0x5a2933(++_0xc7c053);}(a791_0xc7c0,0x94));const a791_0x5a29=function(_0x1da535,_0xc7c053){_0x1da535=_0x1da535-0x0;let _0x5a2933=a791_0xc7c0[_0x1da535];return _0x5a2933;};const _0xcbc5c=a791_0x5a29;'use strict';const attributes=require(_0xcbc5c('0x1'));module[_0xcbc5c('0x6')]=function(_0x29d43f){const _0x3f7f1c=_0xcbc5c,_0x44be0b=_0x29d43f[_0x3f7f1c('0x3')](_0x3f7f1c('0x2'),attributes,{'tableName':_0x3f7f1c('0x0'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x3f7f1c('0x5'),'collate':_0x3f7f1c('0x4')});return _0x44be0b;}; \ No newline at end of file +const a791_0x5241=['exports','define','whatsapp_applications','utf8mb4_unicode_ci','utf8mb4','./whatsappApplication.attributes','WhatsappApplication'];(function(_0x29f06d,_0x524104){const _0x5da8c9=function(_0x2bab93){while(--_0x2bab93){_0x29f06d['push'](_0x29f06d['shift']());}};_0x5da8c9(++_0x524104);}(a791_0x5241,0x6f));const a791_0x5da8=function(_0x29f06d,_0x524104){_0x29f06d=_0x29f06d-0x0;let _0x5da8c9=a791_0x5241[_0x29f06d];return _0x5da8c9;};const _0x2d408c=a791_0x5da8;'use strict';const attributes=require(_0x2d408c('0x6'));module[_0x2d408c('0x1')]=function(_0x2bab93){const _0x33bd08=_0x2d408c,_0x17d465=_0x2bab93[_0x33bd08('0x2')](_0x33bd08('0x0'),attributes,{'tableName':_0x33bd08('0x3'),'paranoid':![],'indexes':[],'timestamps':!![],'charset':_0x33bd08('0x5'),'collate':_0x33bd08('0x4')});return _0x17d465;}; \ No newline at end of file diff --git a/server/api/whatsappInteraction/index.js b/server/api/whatsappInteraction/index.js index 6c7e487..cfade61 100644 --- a/server/api/whatsappInteraction/index.js +++ b/server/api/whatsappInteraction/index.js @@ -1 +1 @@ -const a792_0x4129=['show','put','update','isAuthenticated','download','post','index','tracked','/describe','whatsapp','../../components/auth/service','removeTags','get','express','addMessage','exports','destroy','/:id/download','describe','whatsappinteraction:destroy','/:id/messages','/:id','Router','./whatsappInteraction.controller','whatsappinteraction:update','delete','addTags','/:id/tags'];(function(_0x454dca,_0x4129ad){const _0x3a92a8=function(_0x251f32){while(--_0x251f32){_0x454dca['push'](_0x454dca['shift']());}};_0x3a92a8(++_0x4129ad);}(a792_0x4129,0x1b0));const a792_0x3a92=function(_0x454dca,_0x4129ad){_0x454dca=_0x454dca-0x0;let _0x3a92a8=a792_0x4129[_0x454dca];return _0x3a92a8;};const _0x19691e=a792_0x3a92;'use strict';const express=require(_0x19691e('0x1')),router=express[_0x19691e('0xa')](),auth=require(_0x19691e('0x1a')),interaction=require('../../components/interaction/service'),controller=require(_0x19691e('0xb'));router['get']('/',auth[_0x19691e('0x13')](),controller[_0x19691e('0x16')]),router[_0x19691e('0x0')](_0x19691e('0x18'),auth['isAuthenticated'](),controller[_0x19691e('0x6')]),router[_0x19691e('0x0')](_0x19691e('0x9'),auth[_0x19691e('0x13')](),controller[_0x19691e('0x10')]),router['get'](_0x19691e('0x8'),auth[_0x19691e('0x13')](),controller['getMessages']),router[_0x19691e('0x0')](_0x19691e('0x5'),auth[_0x19691e('0x13')](),controller[_0x19691e('0x14')]),router['post']('/',auth['isAuthenticated'](),controller['create']),router[_0x19691e('0x15')](_0x19691e('0x8'),auth[_0x19691e('0x13')](),controller[_0x19691e('0x2')]),router['post'](_0x19691e('0xf'),auth[_0x19691e('0x13')](),interaction[_0x19691e('0x17')](_0x19691e('0x19'),'whatsappinteraction:addtags'),controller[_0x19691e('0xe')]),router[_0x19691e('0x11')](_0x19691e('0x9'),auth[_0x19691e('0x13')](),interaction['tracked']('whatsapp',_0x19691e('0xc')),controller[_0x19691e('0x12')]),router[_0x19691e('0xd')](_0x19691e('0x9'),auth['isAuthenticated'](),interaction[_0x19691e('0x17')]('whatsapp',_0x19691e('0x7')),controller[_0x19691e('0x4')]),router['delete'](_0x19691e('0xf'),auth[_0x19691e('0x13')](),controller[_0x19691e('0x1b')]),module[_0x19691e('0x3')]=router; \ No newline at end of file +const a792_0x3f6c=['update','express','/:id/tags','whatsappinteraction:addtags','../../components/auth/service','delete','exports','/:id','Router','download','show','whatsappinteraction:destroy','addMessage','post','put','isAuthenticated','whatsapp','getMessages','addTags','/describe','./whatsappInteraction.controller','../../components/interaction/service','destroy','index','/:id/messages','tracked','get'];(function(_0x4eddae,_0x3f6cd9){const _0x4b16c8=function(_0x94b565){while(--_0x94b565){_0x4eddae['push'](_0x4eddae['shift']());}};_0x4b16c8(++_0x3f6cd9);}(a792_0x3f6c,0x83));const a792_0x4b16=function(_0x4eddae,_0x3f6cd9){_0x4eddae=_0x4eddae-0x0;let _0x4b16c8=a792_0x3f6c[_0x4eddae];return _0x4b16c8;};const _0x2d1c76=a792_0x4b16;'use strict';const express=require(_0x2d1c76('0x5')),router=express[_0x2d1c76('0xc')](),auth=require(_0x2d1c76('0x8')),interaction=require(_0x2d1c76('0x19')),controller=require(_0x2d1c76('0x18'));router[_0x2d1c76('0x3')]('/',auth['isAuthenticated'](),controller[_0x2d1c76('0x0')]),router[_0x2d1c76('0x3')](_0x2d1c76('0x17'),auth[_0x2d1c76('0x13')](),controller['describe']),router[_0x2d1c76('0x3')]('/:id',auth[_0x2d1c76('0x13')](),controller[_0x2d1c76('0xe')]),router[_0x2d1c76('0x3')](_0x2d1c76('0x1'),auth['isAuthenticated'](),controller[_0x2d1c76('0x15')]),router[_0x2d1c76('0x3')]('/:id/download',auth[_0x2d1c76('0x13')](),controller[_0x2d1c76('0xd')]),router['post']('/',auth[_0x2d1c76('0x13')](),controller['create']),router[_0x2d1c76('0x11')]('/:id/messages',auth[_0x2d1c76('0x13')](),controller[_0x2d1c76('0x10')]),router['post'](_0x2d1c76('0x6'),auth[_0x2d1c76('0x13')](),interaction['tracked'](_0x2d1c76('0x14'),_0x2d1c76('0x7')),controller[_0x2d1c76('0x16')]),router[_0x2d1c76('0x12')](_0x2d1c76('0xb'),auth['isAuthenticated'](),interaction['tracked'](_0x2d1c76('0x14'),'whatsappinteraction:update'),controller[_0x2d1c76('0x4')]),router[_0x2d1c76('0x9')](_0x2d1c76('0xb'),auth[_0x2d1c76('0x13')](),interaction[_0x2d1c76('0x2')]('whatsapp',_0x2d1c76('0xf')),controller[_0x2d1c76('0x1a')]),router[_0x2d1c76('0x9')](_0x2d1c76('0x6'),auth[_0x2d1c76('0x13')](),controller['removeTags']),module[_0x2d1c76('0xa')]=router; \ No newline at end of file diff --git a/server/api/whatsappInteraction/whatsappInteraction.attributes.js b/server/api/whatsappInteraction/whatsappInteraction.attributes.js index 42d1969..ecbcf70 100644 --- a/server/api/whatsappInteraction/whatsappInteraction.attributes.js +++ b/server/api/whatsappInteraction/whatsappInteraction.attributes.js @@ -1 +1 @@ -const a793_0x23a7=['STRING','DATE','BOOLEAN','out','exports','ENUM','sequelize'];(function(_0x55142a,_0x23a780){const _0xab1853=function(_0x1bd772){while(--_0x1bd772){_0x55142a['push'](_0x55142a['shift']());}};_0xab1853(++_0x23a780);}(a793_0x23a7,0xd1));const a793_0xab18=function(_0x55142a,_0x23a780){_0x55142a=_0x55142a-0x0;let _0xab1853=a793_0x23a7[_0x55142a];return _0xab1853;};const _0x157ebb=a793_0xab18;'use strict';const Sequelize=require(_0x157ebb('0x0'));module[_0x157ebb('0x5')]={'closed':{'type':Sequelize[_0x157ebb('0x3')],'defaultValue':![]},'closedAt':{'type':Sequelize[_0x157ebb('0x2')]},'disposition':{'type':Sequelize[_0x157ebb('0x1')]},'secondDisposition':{'type':Sequelize[_0x157ebb('0x1')]},'thirdDisposition':{'type':Sequelize[_0x157ebb('0x1')]},'note':{'type':Sequelize[_0x157ebb('0x1')]},'phone':{'type':Sequelize[_0x157ebb('0x1')]},'read1stAt':{'type':Sequelize[_0x157ebb('0x2')]},'firstMsgDirection':{'type':Sequelize[_0x157ebb('0x6')]('in',_0x157ebb('0x4')),'defaultValue':'in','allowNull':![]},'lastMsgAt':{'type':Sequelize[_0x157ebb('0x2')]},'lastMsgDirection':{'type':Sequelize[_0x157ebb('0x6')]('in',_0x157ebb('0x4')),'defaultValue':'in','allowNull':![]}}; \ No newline at end of file +const a793_0x1402=['STRING','DATE','sequelize','ENUM'];(function(_0x39dd40,_0x140290){const _0x4ad4da=function(_0x1d6f31){while(--_0x1d6f31){_0x39dd40['push'](_0x39dd40['shift']());}};_0x4ad4da(++_0x140290);}(a793_0x1402,0x191));const a793_0x4ad4=function(_0x39dd40,_0x140290){_0x39dd40=_0x39dd40-0x0;let _0x4ad4da=a793_0x1402[_0x39dd40];return _0x4ad4da;};const _0xfd0f0=a793_0x4ad4;'use strict';const Sequelize=require(_0xfd0f0('0x1'));module['exports']={'closed':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'closedAt':{'type':Sequelize[_0xfd0f0('0x0')]},'disposition':{'type':Sequelize[_0xfd0f0('0x3')]},'secondDisposition':{'type':Sequelize['STRING']},'thirdDisposition':{'type':Sequelize[_0xfd0f0('0x3')]},'note':{'type':Sequelize[_0xfd0f0('0x3')]},'phone':{'type':Sequelize[_0xfd0f0('0x3')]},'read1stAt':{'type':Sequelize[_0xfd0f0('0x0')]},'firstMsgDirection':{'type':Sequelize[_0xfd0f0('0x2')]('in','out'),'defaultValue':'in','allowNull':![]},'lastMsgAt':{'type':Sequelize['DATE']},'lastMsgDirection':{'type':Sequelize['ENUM']('in','out'),'defaultValue':'in','allowNull':![]}}; \ No newline at end of file diff --git a/server/api/whatsappInteraction/whatsappInteraction.controller.js b/server/api/whatsappInteraction/whatsappInteraction.controller.js index c714b2b..89a55cb 100644 --- a/server/api/whatsappInteraction/whatsappInteraction.controller.js +++ b/server/api/whatsappInteraction/whatsappInteraction.controller.js @@ -1 +1 @@ -const a794_0x5291=['transcript-','catch','model','addTags','ui.WhatsappInteractionId','fieldName','api','includeAll','o.fullname','i.WhatsappAccountId\x20IS\x20NULL','%s\x20#%d','value','user_has_whatsapp_interactions','u.id','gte','Contact.email','i.WhatsappAccountId\x20IN\x20?','a.mandatoryDisposition','isEmpty','log','downloadInteraction.html','filter','whatsappInteractionTags:save','groupBy','rimraf','squel','getWhatsappAccounts','whatsapp_messages','buildExpression','removeTags','parseSearch','Tags','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','some','intersection','a.id\x20=\x20i.WhatsappAccountId','err','end','basename','undefined','attributes','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{page}}/{{pages}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','QueryTypes','c.fax','json','length','Tag','40px','from','findAll','ids','i.id\x20LIKE\x20?','Sequelize','compact','isArray','count','`\x20>\x200','keyBy','Whatsapp','filters','users','root','System','server','attachments','concat','../../config/environment','whatsapp_interaction_has_tags','keys','split','Users','10px','text','YYYY-MM-DD\x20HH:mm:ss','type','status','cm_contacts','like','toFile','merge','join','get','Account','`unreadMessages`\x20=\x200','getFullTextValue','files','user','group','../../rediscache','i.createdAt\x20BETWEEN\x20?\x20AND\x20?','Contact.fax','GROUP_CONCAT(DISTINCT\x20t.id)','c.mobile','download','tag','setTags','Owner.fullname','N.A.','union','parse','null','sequelize','me.WhatsappInteractionId\x20=\x20i.id','moment','rawAttributes','UserId','ui.WhatsappInteractionId\x20IN\x20?','error','resolve','findOne','conditions','query','u.fullname','$gte','out','start','c.lastName','then','index','i.*','name','params','limit','WhatsappMessage','options','omit','body','lastName','WhatsappAccountId','createReadStream','rows','nolimit','direction','color','secret','toString','clone','existsSync','fields','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','../../config/logger','Content-Range','CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?','Owner','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
Interaction\x20Transcript
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','renderFile','c.phone','Account.key','sendStatus','order','Contact.lastName','Contact.mobile','views','t.id\x20=\x20it.TagId','Account.mandatoryDisposition','Messages','field','path','firstName','find','Contact','push','ContactId','describe','map','\x20IS\x20NULL','disposition','TagIds','fullname','destroy','../../mysqldb','Contact.phone','closedAt','replace','update','i.id','left_join','zip-dir','register','30px','createdAt','having','Attachment','unreadMessages','User','addMessage','it.WhatsappInteractionId\x20=\x20i.id','$lte','c.firstName','WhatsappInteraction','CmContact','pick','select','WhatsappAccount','YYYY-MM-DD','u.id\x20=\x20ui.UserId','sort','read','t.id\x20IN\x20?','DESC','emit','forEach','getMessages','\x27\x27\x27\x27','whatsapp_accounts','create','transcript-%d-%s.zip','`unreadMessages`\x20>\x200','search','o.internal','expr','offset','sqlOperator','include','where','format','mkdirSync','i.WhatsappAccountId\x20IS\x20NOT\x20NULL'];(function(_0x1ffcf7,_0x5291ca){const _0x31c101=function(_0x362da6){while(--_0x362da6){_0x1ffcf7['push'](_0x1ffcf7['shift']());}};_0x31c101(++_0x5291ca);}(a794_0x5291,0xff));const a794_0x31c1=function(_0x1ffcf7,_0x5291ca){_0x1ffcf7=_0x1ffcf7-0x0;let _0x31c101=a794_0x5291[_0x1ffcf7];return _0x31c101;};const _0x56baa0=a794_0x31c1;'use strict';const pdf=require('html-pdf'),rimraf=require(_0x56baa0('0xcf')),zipdir=require(_0x56baa0('0x8e')),moment=require(_0x56baa0('0x44')),util=require('util'),path=require(_0x56baa0('0x7a')),ejs=require('ejs'),fs=require('fs'),_=require('lodash'),squel=require(_0x56baa0('0xd0')),{getSocket}=require(_0x56baa0('0x35')),socket=getSocket(),qs=require('../../components/parsers/qs'),as=require('../../components/parsers/advancedSearch'),logger=require(_0x56baa0('0x69'))(_0x56baa0('0xbd')),config=require(_0x56baa0('0x1f')),db=require(_0x56baa0('0x87'))['db'],{Op}=require('sequelize');require('./whatsappInteraction.socket')[_0x56baa0('0x8f')](socket);function respondWithStatusCode(_0x362da6,_0x304583){return _0x304583=_0x304583||0xcc,function(_0xa08ec1){const _0x49ab04=a794_0x31c1;if(_0xa08ec1)return _0x362da6[_0x49ab04('0x71')](_0x304583);return _0x362da6[_0x49ab04('0x28')](_0x304583)['end']();};}function respondWithResult(_0x490ccc,_0x472778){return _0x472778=_0x472778||0xc8,function(_0x4b2d56){const _0x848d3f=a794_0x31c1;if(_0x4b2d56)return _0x490ccc[_0x848d3f('0x28')](_0x472778)[_0x848d3f('0x9')](_0x4b2d56);};}function respondWithFilteredResult(_0x33b136,_0x4bac80){return function(_0x4e480f){const _0x3972cf=a794_0x31c1;if(_0x4e480f){const _0x2348c1=_0x4e480f['count'],_0x3cb563=_0x4bac80[_0x3972cf('0xb0')];let _0x1744a3=_0x4bac80[_0x3972cf('0xb0')]+_0x4bac80[_0x3972cf('0x57')],_0x24d09a;return _0x1744a3>=_0x2348c1?(_0x1744a3=_0x2348c1,_0x24d09a=0xc8):_0x24d09a=0xce,_0x33b136[_0x3972cf('0x28')](_0x24d09a),_0x33b136['set'](_0x3972cf('0x6a'),_0x3cb563+'-'+_0x1744a3+'/'+_0x2348c1)['json'](_0x4e480f);}return null;};}function saveUpdates(_0x3b0c37){return function(_0x5ad282){const _0x5a1026=a794_0x31c1;if(_0x5ad282)return _0x5ad282[_0x5a1026('0x8b')](_0x3b0c37)[_0x5a1026('0x52')](function(_0x3e4535){return _0x3e4535;});return null;};}function removeEntity(_0x505a3f){return function(_0x416c72){const _0x4c07ba=a794_0x31c1;if(_0x416c72)return _0x416c72['destroy']()[_0x4c07ba('0x52')](function(){_0x505a3f['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x48579a){return function(_0x32606c){const _0x3d6527=a794_0x31c1;return!_0x32606c&&_0x48579a[_0x3d6527('0x71')](0x194),_0x32606c;};}function handleError(_0x4e9d61,_0x35ca2f){return _0x35ca2f=_0x35ca2f||0x1f4,function(_0x162493){const _0x5c8541=a794_0x31c1;logger[_0x5c8541('0x48')](_0x162493['stack']),_0x162493['name']&&delete _0x162493[_0x5c8541('0x55')],_0x4e9d61[_0x5c8541('0x28')](_0x35ca2f)['send'](_0x162493);};}function getInteractionUsers(_0x4b5beb,_0x380703){return new Promise(function(_0x55ce2e,_0x219d23){const _0xbd4c79=a794_0x31c1;try{_0x380703[_0x4b5beb['id']]&&(_0x4b5beb[_0xbd4c79('0x23')]=_[_0xbd4c79('0x81')](_0x380703[_0x4b5beb['id']],function(_0x190c0f){const _0x1b1638=_0xbd4c79;return{'id':_0x190c0f['id'],'fullname':_0x190c0f[_0x1b1638('0x85')]};}));}catch(_0x32ee48){_0x219d23(_0x32ee48);}_0x55ce2e(_0x4b5beb);});}function getInteractionTags(_0x4a9054,_0x5bedb2){return new Promise(function(_0x358de1,_0x122dd6){const _0x71a142=a794_0x31c1;try{_0x4a9054[_0x71a142('0x84')]&&(_0x4a9054[_0x71a142('0xd6')]=[],_0x4a9054[_0x71a142('0x84')]['split'](',')['forEach'](function(_0x31e965){_0x4a9054['Tags']['push'](_0x5bedb2[_0x31e965]);})),delete _0x4a9054['TagIds'];}catch(_0x5efdbf){_0x122dd6(_0x5efdbf);}_0x358de1(_0x4a9054);});}function updateWhatsappInteraction(_0x18c461,_0x4840c5,_0x3e5585){return new Promise(function(_0x5c737a,_0x2890ed){const _0x2f1de3=a794_0x31c1;return getInteractionUsers(_0x18c461,_0x3e5585)['then'](function(_0xca775f){return getInteractionTags(_0xca775f,_0x4840c5);})[_0x2f1de3('0x52')](function(_0x1d0f16){_0x5c737a(_0x1d0f16);})[_0x2f1de3('0xb8')](function(_0x2a71ee){_0x2890ed(_0x2a71ee);});});}exports[_0x56baa0('0x53')]=function(_0x68a043,_0x17f6bb){const _0x23c76b=_0x56baa0,_0x595c7={},_0x3f7918={},_0x385a81={'count':0x0,'rows':[]},_0x1747d4=_[_0x23c76b('0x81')](db[_0x23c76b('0x9a')]['rawAttributes'],function(_0x3b19ff){const _0xfc0b86=_0x23c76b;return{'name':_0x3b19ff[_0xfc0b86('0xbc')],'type':_0x3b19ff[_0xfc0b86('0x27')]['key']};});_0x3f7918[_0x23c76b('0xb9')]=_[_0x23c76b('0x81')](_0x1747d4,_0x23c76b('0x55')),_0x3f7918['query']=_['keys'](_0x68a043[_0x23c76b('0x4c')]),_0x3f7918[_0x23c76b('0x18')]=_['intersection'](_0x3f7918[_0x23c76b('0xb9')],_0x3f7918[_0x23c76b('0x4c')]),_0x595c7['attributes']=_[_0x23c76b('0xda')](_0x3f7918[_0x23c76b('0xb9')],qs['fields'](_0x68a043[_0x23c76b('0x4c')][_0x23c76b('0x67')])),_0x595c7[_0x23c76b('0x5')]=_0x595c7[_0x23c76b('0x5')][_0x23c76b('0xa')]?_0x595c7[_0x23c76b('0x5')]:_0x3f7918[_0x23c76b('0xb9')];typeof _0x68a043[_0x23c76b('0x4c')][_0x23c76b('0x60')]===_0x23c76b('0x4')&&(_0x595c7['limit']=qs['limit'](_0x68a043['query'][_0x23c76b('0x57')]),_0x595c7[_0x23c76b('0xb0')]=qs[_0x23c76b('0xb0')](_0x68a043[_0x23c76b('0x4c')][_0x23c76b('0xb0')]));_0x595c7[_0x23c76b('0x72')]=qs['sort'](_0x68a043[_0x23c76b('0x4c')]['sort']),_0x595c7[_0x23c76b('0xb3')]=qs[_0x23c76b('0x18')](_['pick'](_0x68a043[_0x23c76b('0x4c')],_0x3f7918['filters']),_0x1747d4);let _0xafccb6=[];const _0x243024=squel[_0x23c76b('0x9d')]()[_0x23c76b('0x79')]('id')[_0x23c76b('0x79')](_0x23c76b('0x55'))['field'](_0x23c76b('0x62'))['from']('tools_tags'),_0x353275=squel[_0x23c76b('0x9d')]()['field'](_0x23c76b('0xc4'))[_0x23c76b('0x79')](_0x23c76b('0x4d'))['field'](_0x23c76b('0xbb'))[_0x23c76b('0xd')](_0x23c76b('0xc3'),'ui')[_0x23c76b('0x8d')](_0x23c76b('0x19'),'u',_0x23c76b('0xa0')),_0x1eedf7=squel[_0x23c76b('0x9d')]()['from']('whatsapp_interactions','i')[_0x23c76b('0x8d')](_0x23c76b('0x29'),'c','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL')[_0x23c76b('0x8d')](_0x23c76b('0x19'),'o','o.id\x20=\x20i.UserId')[_0x23c76b('0x8d')](_0x23c76b('0xa9'),'a',_0x23c76b('0x0'))[_0x23c76b('0x8d')](_0x23c76b('0xd2'),'me',_0x23c76b('0x43'))[_0x23c76b('0x8d')](_0x23c76b('0x20'),'it',_0x23c76b('0x97'))[_0x23c76b('0x8d')]('tools_tags','t',_0x23c76b('0x76')),_0x11e814=squel[_0x23c76b('0xaf')]();let _0x58565b=[];const _0x486f53=squel[_0x23c76b('0xaf')]();let _0x263825;if(_0x68a043[_0x23c76b('0x4c')][_0x23c76b('0xad')]){_0x263825=as[_0x23c76b('0xd5')](_0x68a043['query']['search']);const _0x3b60ca=_0x263825[_0x23c76b('0xb1')];for(let _0x2ada2c=0x0;_0x2ada2c<_0x263825[_0x23c76b('0x4b')][_0x23c76b('0xa')];_0x2ada2c++){const _0x31623d=_0x263825[_0x23c76b('0x4b')][_0x2ada2c],_0x69bae9='i';let _0x4d4217,_0x128d3e=_[_0x23c76b('0x7c')](_0x1747d4,[_0x23c76b('0x55'),_0x31623d['field']]);if(!_0x128d3e)switch(_0x31623d[_0x23c76b('0x79')]){case _0x23c76b('0x94'):_0x31623d[_0x23c76b('0xc2')]==0x1?_0x1eedf7['having']('`'+_0x31623d[_0x23c76b('0x79')]+'`\x20=\x200'):_0x1eedf7['having']('`'+_0x31623d[_0x23c76b('0x79')]+_0x23c76b('0x15'));break;case _0x23c76b('0x7d'):if(_0x31623d['operator']==='$substring'){if(_0x31623d['value'][_0x23c76b('0x22')]('\x20')[_0x23c76b('0xa')]>0x1)_0x11e814[_0x3b60ca](_0x23c76b('0xd8'),qs[_0x23c76b('0x31')](_0x31623d[_0x23c76b('0xc2')]),null);else{const _0x2a2ced='%'+_0x31623d[_0x23c76b('0xc2')]+'%';_0x11e814[_0x3b60ca]('c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?',_0x2a2ced,_0x2a2ced,_0x2a2ced);}}else _0x128d3e=_['find'](_0x1747d4,[_0x23c76b('0x55'),_0x23c76b('0x7f')]),_0x31623d['field']='ContactId',_0x4d4217=as['buildExpression'](_0x69bae9,_0x128d3e[_0x23c76b('0x27')],_0x31623d),_0x11e814[_0x3b60ca](_0x4d4217[_0x23c76b('0x25')],_0x4d4217[_0x23c76b('0xc2')][_0x23c76b('0x50')],_0x4d4217[_0x23c76b('0xc2')][_0x23c76b('0x2')]);break;case _0x23c76b('0xb'):{const _0x12f8c2=_0x31623d[_0x23c76b('0xc2')][_0x23c76b('0x22')](',')[_0x23c76b('0x81')](function(_0x252279){return Number(_0x252279);});_0x12f8c2[_0x23c76b('0xa6')](function(_0x50a8cf){const _0x4e80ee=_0x23c76b;_0x486f53['or'](_0x4e80ee('0x68'),'%,'+_0x50a8cf+',%');}),_0x58565b=_[_0x23c76b('0x3f')](_0x58565b,_0x12f8c2);}break;case _0x23c76b('0x95'):_0x31623d['operator']==='$substring'?_0x11e814[_0x3b60ca]('CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','%'+_0x31623d['value']+'%',null):(_0x128d3e=_[_0x23c76b('0x7c')](_0x1747d4,['name',_0x23c76b('0x46')]),_0x31623d[_0x23c76b('0x79')]=_0x23c76b('0x46'),_0x4d4217=as[_0x23c76b('0xd3')](_0x69bae9,_0x128d3e['type'],_0x31623d),_0x11e814[_0x3b60ca](_0x4d4217[_0x23c76b('0x25')],_0x4d4217['value'][_0x23c76b('0x50')],_0x4d4217[_0x23c76b('0xc2')]['end']));break;case'body':_0x4d4217=as[_0x23c76b('0xd3')]('me',null,_0x31623d),_0x11e814[_0x3b60ca](_0x4d4217[_0x23c76b('0x25')],_0x4d4217[_0x23c76b('0xc2')][_0x23c76b('0x50')],_0x4d4217[_0x23c76b('0xc2')][_0x23c76b('0x2')]);break;}else _0x4d4217=as[_0x23c76b('0xd3')](_0x69bae9,_0x128d3e[_0x23c76b('0x27')],_0x31623d),_0x11e814[_0x3b60ca](_0x4d4217[_0x23c76b('0x25')],_0x4d4217[_0x23c76b('0xc2')]['start'],_0x4d4217[_0x23c76b('0xc2')][_0x23c76b('0x2')]);}}else{const _0x48563d=_(_0x68a043[_0x23c76b('0x4c')])['keys']()[_0x23c76b('0x81')](function(_0x598a23){const _0x3eeb29=_0x23c76b;return _[_0x3eeb29('0xd9')](_0x1747d4,[_0x3eeb29('0x55'),_0x598a23])?_0x598a23:undefined;})[_0x23c76b('0x12')]()['value']();!_[_0x23c76b('0xc9')](_0x48563d)&&_0x48563d[_0x23c76b('0xa6')](function(_0x76b66a){const _0x202b7c=_0x23c76b;if(_0x76b66a===_0x202b7c('0x5d'))_0x1eedf7[_0x202b7c('0xb3')](_0x202b7c('0xc7'),[][_0x202b7c('0x1e')](_0x68a043['query'][_0x76b66a]));else{if(_0x76b66a==='createdAt'){const _0x4d5e89=JSON[_0x202b7c('0x40')](_0x68a043[_0x202b7c('0x4c')][_0x76b66a])[_0x202b7c('0x4e')],_0x127b43=JSON[_0x202b7c('0x40')](_0x68a043['query'][_0x76b66a])[_0x202b7c('0x98')];_0x1eedf7['where'](_0x202b7c('0x36'),_0x4d5e89,_0x127b43);}else _0x68a043[_0x202b7c('0x4c')][_0x76b66a]===_0x202b7c('0x41')?_0x1eedf7['where']('i.'+_0x76b66a+_0x202b7c('0x82')):_0x1eedf7[_0x202b7c('0xb3')]('i.'+_0x76b66a+'\x20=\x20?',_0x68a043['query'][_0x76b66a]);}});_0x68a043[_0x23c76b('0x4c')][_0x23c76b('0xa2')]&&(_0x68a043[_0x23c76b('0x4c')]['read']==0x1?_0x1eedf7[_0x23c76b('0x92')](_0x23c76b('0x30')):_0x1eedf7[_0x23c76b('0x92')](_0x23c76b('0xac')));_0x68a043['query']['tag']&&(_0x58565b=_[_0x23c76b('0x13')](_0x68a043[_0x23c76b('0x4c')]['tag'])?_0x68a043['query'][_0x23c76b('0x3b')]:new Array(_0x68a043['query'][_0x23c76b('0x3b')]),_0x58565b[_0x23c76b('0xa6')](function(_0x13ffda){const _0x4285c0=_0x23c76b;_0x486f53['or'](_0x4285c0('0x68'),'%,'+_0x13ffda+',%');}));if(_0x68a043[_0x23c76b('0x4c')][_0x23c76b('0xcc')]){const _0xcb23cd=_0x68a043[_0x23c76b('0x4c')][_0x23c76b('0xcc')][_0x23c76b('0x8a')]('\x5c','\x5c\x5c')[_0x23c76b('0x8a')]('\x27\x27',_0x23c76b('0xa8'));qs['isNumeric'](_0xcb23cd)?_0x11e814['or'](_0x23c76b('0x10'),_0xcb23cd+'%')['or']('i.phone\x20LIKE\x20?',_0xcb23cd+'%'):_0x11e814['or']('MATCH\x20(me.body)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)',qs['getFullTextValue'](_0xcb23cd))['or'](_0x23c76b('0x6b'),_0xcb23cd+'%');}}_0x1eedf7[_0x23c76b('0xb3')](_0x11e814),_0x1eedf7[_0x23c76b('0x34')](_0x23c76b('0x8c'));let _0x158a94={'type':db[_0x23c76b('0x11')][_0x23c76b('0x7')]['SELECT'],'raw':!![]};const _0xd2c686=_0x1eedf7[_0x23c76b('0x65')]();_0xd2c686[_0x23c76b('0x79')](_0x23c76b('0x8c')),_0xd2c686['field'](_0x23c76b('0xd7'),_0x23c76b('0x94')),_0x595c7[_0x23c76b('0x72')]&&_0x595c7[_0x23c76b('0x72')][_0x23c76b('0xa6')](function(_0x46a279){const _0x5db74d=_0x23c76b;_0x1eedf7[_0x5db74d('0x72')]('i.'+_0x46a279[0x0],_0x46a279[0x1]===_0x5db74d('0xa4')?![]:!![]);}),!_[_0x23c76b('0xc9')](_0x58565b)&&(_0x1eedf7['having'](_0x486f53),_0xd2c686[_0x23c76b('0xb3')](_0x23c76b('0xa3'),_0x58565b)),Promise[_0x23c76b('0x49')]()[_0x23c76b('0x52')](function(){const _0xf38d7c=_0x23c76b;if(!_0x263825){if(_0x68a043[_0xf38d7c('0x4c')][_0xf38d7c('0x5d')]||_0x68a043[_0xf38d7c('0x4c')]['journey'])return;_0xd2c686[_0xf38d7c('0xb3')](_0xf38d7c('0xb6')),_0x1eedf7[_0xf38d7c('0xb3')](_0xf38d7c('0xb6'));return;}return _0x68a043[_0xf38d7c('0x33')][_0xf38d7c('0xd1')]({'attributes':['id'],'raw':!![]})[_0xf38d7c('0x52')](function(_0x500284){const _0x2c785a=_0xf38d7c;_['isEmpty'](_0x500284)?(_0xd2c686[_0x2c785a('0xb3')](_0x2c785a('0xc0')),_0x1eedf7[_0x2c785a('0xb3')]('i.WhatsappAccountId\x20IS\x20NULL')):(_0xd2c686[_0x2c785a('0xb3')]('i.WhatsappAccountId\x20IN\x20?',_[_0x2c785a('0x81')](_0x500284,'id')),_0x1eedf7[_0x2c785a('0xb3')](_0x2c785a('0xc7'),_[_0x2c785a('0x81')](_0x500284,'id')));});})[_0x23c76b('0x52')](function(){const _0x29b3b5=_0x23c76b;db['sequelize'][_0x29b3b5('0x4c')](_0xd2c686[_0x29b3b5('0x64')](),_0x158a94)['then'](function(_0x5ad6b2){const _0x631700=_0x29b3b5;_0x385a81['count']=_0x5ad6b2['length'];if(_0x385a81['count']===0x0)return[];return db[_0x631700('0x42')][_0x631700('0x4c')](_0x243024[_0x631700('0x64')](),_0x158a94)['then'](function(_0x2836a5){const _0xbf871b=_0x631700;_0xafccb6=_[_0xbf871b('0x16')](_0x2836a5,'id'),_0x158a94=_[_0xbf871b('0x2c')](_0x158a94,{'model':db[_0xbf871b('0x9a')],'mapToModel':!![],'raw':!![],'nest':!![]});_0x68a043[_0xbf871b('0x4c')][_0xbf871b('0x67')]?_0x595c7[_0xbf871b('0x5')][_0xbf871b('0xa6')](function(_0x450428){const _0x267053=_0xbf871b;_0x1eedf7[_0x267053('0x79')]('i.'+_0x450428);}):(_0x1eedf7[_0xbf871b('0x79')]('SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)',_0xbf871b('0x94')),_0x1eedf7['field']('a.key',_0xbf871b('0x70')),_0x1eedf7[_0xbf871b('0x79')](_0xbf871b('0xc8'),_0xbf871b('0x77')),_0x1eedf7[_0xbf871b('0x79')](_0xbf871b('0x54')),_0x1eedf7['field'](_0xbf871b('0x99'),'Contact.firstName'),_0x1eedf7[_0xbf871b('0x79')](_0xbf871b('0x51'),_0xbf871b('0x73')),_0x1eedf7[_0xbf871b('0x79')]('c.email',_0xbf871b('0xc6')),_0x1eedf7['field'](_0xbf871b('0x6f'),_0xbf871b('0x88')),_0x1eedf7[_0xbf871b('0x79')](_0xbf871b('0x39'),_0xbf871b('0x74')),_0x1eedf7[_0xbf871b('0x79')](_0xbf871b('0x8'),_0xbf871b('0x37')),_0x1eedf7[_0xbf871b('0x79')](_0xbf871b('0xbf'),_0xbf871b('0x3d')),_0x1eedf7[_0xbf871b('0x79')](_0xbf871b('0xae'),'Owner.internal'),_0x1eedf7[_0xbf871b('0x79')](_0xbf871b('0x38'),_0xbf871b('0x84')));if(_0x595c7['limit'])_0x1eedf7[_0xbf871b('0x57')](_0x595c7[_0xbf871b('0x57')]);if(_0x595c7[_0xbf871b('0xb0')])_0x1eedf7[_0xbf871b('0xb0')](_0x595c7[_0xbf871b('0xb0')]);return db[_0xbf871b('0x42')][_0xbf871b('0x4c')](_0x1eedf7[_0xbf871b('0x64')](),_0x158a94);})['then'](function(_0x7eff91){const _0x5e698e=_0x631700;return _0x353275['where'](_0x5e698e('0x47'),_['map'](_0x7eff91,'id')),db[_0x5e698e('0x42')][_0x5e698e('0x4c')](_0x353275['toString'](),_0x158a94)[_0x5e698e('0x52')](function(_0x17706c){const _0xd1ba1=_0x5e698e,_0x34bb93=_[_0xd1ba1('0xce')](_0x17706c,'WhatsappInteractionId'),_0x16d054=[];return _0x7eff91[_0xd1ba1('0xa6')](function(_0x247017){_0x16d054['push'](updateWhatsappInteraction(_0x247017,_0xafccb6,_0x34bb93));}),Promise['all'](_0x16d054);});});})['then'](function(_0x54ec9b){return _0x385a81['rows']=_0x54ec9b,_0x385a81;})['then'](respondWithFilteredResult(_0x17f6bb,_0x595c7));})[_0x23c76b('0xb8')](handleError(_0x17f6bb,null));},exports['show']=function(_0x536f4c,_0x20e68c){const _0x3564a7=_0x56baa0;let _0x1daa1e={'raw':![],'where':{'id':_0x536f4c[_0x3564a7('0x56')]['id']}};const _0x3a4f4c={};return _0x3a4f4c['model']=_['keys'](db[_0x3564a7('0x9a')][_0x3564a7('0x45')]),_0x3a4f4c[_0x3564a7('0x4c')]=_[_0x3564a7('0x21')](_0x536f4c[_0x3564a7('0x4c')]),_0x3a4f4c[_0x3564a7('0x18')]=_[_0x3564a7('0xda')](_0x3a4f4c[_0x3564a7('0xb9')],_0x3a4f4c[_0x3564a7('0x4c')]),_0x1daa1e[_0x3564a7('0x5')]=_[_0x3564a7('0xda')](_0x3a4f4c[_0x3564a7('0xb9')],qs[_0x3564a7('0x67')](_0x536f4c[_0x3564a7('0x4c')]['fields'])),_0x1daa1e[_0x3564a7('0x5')]=_0x1daa1e[_0x3564a7('0x5')][_0x3564a7('0xa')]?_0x1daa1e[_0x3564a7('0x5')]:_0x3a4f4c[_0x3564a7('0xb9')],_0x536f4c[_0x3564a7('0x4c')][_0x3564a7('0xbe')]&&(_0x1daa1e[_0x3564a7('0xb2')]=[{'all':!![]}]),_0x1daa1e=_[_0x3564a7('0x2c')]({},_0x1daa1e,_0x536f4c[_0x3564a7('0x59')]),db['WhatsappInteraction'][_0x3564a7('0x4a')](_0x1daa1e)['then'](handleEntityNotFound(_0x20e68c,null))[_0x3564a7('0x52')](respondWithResult(_0x20e68c,null))[_0x3564a7('0xb8')](handleError(_0x20e68c,null));},exports[_0x56baa0('0xaa')]=function(_0x3794f4,_0x4a3383){const _0x1a6c52=_0x56baa0;return db[_0x1a6c52('0x9a')]['create'](_0x3794f4[_0x1a6c52('0x5b')],{})[_0x1a6c52('0x52')](respondWithResult(_0x4a3383,0xc9))[_0x1a6c52('0xb8')](handleError(_0x4a3383,null));},exports[_0x56baa0('0x8b')]=function(_0x2cc1fc,_0x45b65a){const _0x232e11=_0x56baa0;return _0x2cc1fc[_0x232e11('0x5b')]['id']&&delete _0x2cc1fc[_0x232e11('0x5b')]['id'],db[_0x232e11('0x9a')][_0x232e11('0x4a')]({'where':{'id':_0x2cc1fc[_0x232e11('0x56')]['id']}})[_0x232e11('0x52')](handleEntityNotFound(_0x45b65a,null))[_0x232e11('0x52')](saveUpdates(_0x2cc1fc['body'],null))['then'](respondWithResult(_0x45b65a,null))[_0x232e11('0xb8')](handleError(_0x45b65a,null));},exports[_0x56baa0('0x86')]=function(_0x27178a,_0x505e66){const _0x104b06=_0x56baa0;return db[_0x104b06('0x9a')][_0x104b06('0x4a')]({'where':{'id':_0x27178a[_0x104b06('0x56')]['id']}})[_0x104b06('0x52')](handleEntityNotFound(_0x505e66,null))['then'](removeEntity(_0x505e66,null))[_0x104b06('0xb8')](handleError(_0x505e66,null));},exports[_0x56baa0('0x80')]=function(_0x233544,_0x13cb57){const _0x56bcd2=_0x56baa0;return db[_0x56bcd2('0x9a')][_0x56bcd2('0x80')]()['then'](respondWithResult(_0x13cb57,null))[_0x56bcd2('0xb8')](handleError(_0x13cb57,null));},exports[_0x56baa0('0x96')]=function(_0x33a034,_0x221d33){const _0x1fc4f2=_0x56baa0;return db[_0x1fc4f2('0x58')][_0x1fc4f2('0x4a')]({'where':{'id':_0x33a034[_0x1fc4f2('0x56')]['id']}})[_0x1fc4f2('0x52')](function(_0x2e6791){const _0x55edbf=_0x1fc4f2;if(_0x2e6791)return _0x2e6791[_0x55edbf('0x96')](_0x33a034[_0x55edbf('0x5b')][_0x55edbf('0xf')],{'through':_[_0x55edbf('0x5a')](_0x33a034[_0x55edbf('0x5b')],['ids','id'])});})[_0x1fc4f2('0x52')](respondWithResult(_0x221d33,null))[_0x1fc4f2('0xb8')](handleError(_0x221d33,null));},exports[_0x56baa0('0xa7')]=function(_0xa7ee0,_0x4a5f5a){const _0x5a9f83=_0x56baa0;let _0x2c3100={'raw':![],'where':{}};const _0x5e6163={},_0x358c77={'count':0x0,'rows':[]};return db[_0x5a9f83('0x9a')][_0x5a9f83('0x4a')]({'where':{'id':_0xa7ee0['params']['id']}})['then'](handleEntityNotFound(_0x4a5f5a,null))[_0x5a9f83('0x52')](function(_0x22f7af){const _0x42ab16=_0x5a9f83;if(_0x22f7af){_0x5e6163[_0x42ab16('0xb9')]=_[_0x42ab16('0x21')](db[_0x42ab16('0x58')][_0x42ab16('0x45')]),_0x5e6163[_0x42ab16('0x4c')]=_[_0x42ab16('0x21')](_0xa7ee0[_0x42ab16('0x4c')]),_0x5e6163[_0x42ab16('0x18')]=_[_0x42ab16('0xda')](_0x5e6163[_0x42ab16('0xb9')],_0x5e6163['query']),_0x2c3100[_0x42ab16('0x5')]=_[_0x42ab16('0xda')](_0x5e6163[_0x42ab16('0xb9')],qs['fields'](_0xa7ee0[_0x42ab16('0x4c')][_0x42ab16('0x67')])),_0x2c3100[_0x42ab16('0x5')]=_0x2c3100[_0x42ab16('0x5')][_0x42ab16('0xa')]?_0x2c3100['attributes']:_0x5e6163[_0x42ab16('0xb9')];typeof _0xa7ee0['query'][_0x42ab16('0x60')]===_0x42ab16('0x4')&&(_0x2c3100[_0x42ab16('0x57')]=qs['limit'](_0xa7ee0[_0x42ab16('0x4c')]['limit']),_0x2c3100[_0x42ab16('0xb0')]=qs[_0x42ab16('0xb0')](_0xa7ee0[_0x42ab16('0x4c')]['offset']));_0x2c3100[_0x42ab16('0x72')]=qs['sort'](_0xa7ee0['query'][_0x42ab16('0xa1')]),_0x2c3100[_0x42ab16('0xb3')]=qs['filters'](_[_0x42ab16('0x9c')](_0xa7ee0[_0x42ab16('0x4c')],_0x5e6163['filters'])),_0x2c3100['where']['WhatsappInteractionId']=_0x22f7af['id'];_0xa7ee0[_0x42ab16('0x4c')][_0x42ab16('0xcc')]&&(_0x2c3100['where']=_[_0x42ab16('0x2c')](_0x2c3100['where'],{[Op['or']]:_['map'](_0x2c3100[_0x42ab16('0x5')],function(_0x2c6681){const _0x25bc24=_0x42ab16,_0x3d80f2={};return _0x3d80f2[_0x2c6681]={[Op[_0x25bc24('0x2a')]]:'%'+_0xa7ee0[_0x25bc24('0x4c')][_0x25bc24('0xcc')]+'%'},_0x3d80f2;})}));if(_0xa7ee0[_0x42ab16('0x4c')][_0x42ab16('0x4e')]){const _0x2816d4=_0xa7ee0[_0x42ab16('0x4c')][_0x42ab16('0x4e')][_0x42ab16('0x22')](','),_0x938782={};_0x938782[_0x2816d4[0x0]]={[Op[_0x42ab16('0xc5')]]:moment(_0x2816d4[0x1])[_0x42ab16('0xb4')](_0x42ab16('0x26'))},_0x2c3100[_0x42ab16('0xb3')]=_[_0x42ab16('0x2c')](_0x2c3100[_0x42ab16('0xb3')],_0x938782);}return _0x2c3100=_[_0x42ab16('0x2c')]({},_0x2c3100,_0xa7ee0[_0x42ab16('0x59')]),db[_0x42ab16('0x58')][_0x42ab16('0x14')]({'where':_0x2c3100[_0x42ab16('0xb3')]})[_0x42ab16('0x52')](function(_0x16c19c){const _0x1552b8=_0x42ab16;return _0x358c77['count']=_0x16c19c,_0xa7ee0[_0x1552b8('0x4c')][_0x1552b8('0xbe')]&&(_0x2c3100[_0x1552b8('0xb2')]=[{'all':!![]}]),db['WhatsappMessage'][_0x1552b8('0xe')](_0x2c3100);})['then'](function(_0x199997){const _0x5dde4e=_0x42ab16;return _0x358c77[_0x5dde4e('0x5f')]=_0x199997,_0x358c77;});}})['then'](respondWithFilteredResult(_0x4a5f5a,_0x2c3100))[_0x5a9f83('0xb8')](handleError(_0x4a5f5a,null));},exports[_0x56baa0('0xba')]=function(_0xccfe5c,_0x22d1ea){const _0x2d7434=_0x56baa0;return db[_0x2d7434('0x9a')]['findOne']({'where':{'id':_0xccfe5c['params']['id']}})[_0x2d7434('0x52')](function(_0x167722){const _0x6310cb=_0x2d7434;if(_0x167722)return _0x167722[_0x6310cb('0x3c')](_0xccfe5c[_0x6310cb('0x5b')][_0x6310cb('0xf')],{'through':_['omit'](_0xccfe5c[_0x6310cb('0x5b')],[_0x6310cb('0xf'),'id'])})['then'](function(){const _0x2709df=_0x6310cb;return db[_0x2709df('0xb')]['findAll']({'attributes':['id',_0x2709df('0x55'),_0x2709df('0x62')],'where':{'id':_0xccfe5c[_0x2709df('0x5b')]['ids']}});})[_0x6310cb('0x52')](function(_0x559dd8){const _0x3abc8c=_0x6310cb;return socket[_0x3abc8c('0xa5')](_0x3abc8c('0xcd'),{'id':Number(_0xccfe5c['params']['id']),'tags':_0x559dd8||[]}),{'id':Number(_0xccfe5c[_0x3abc8c('0x56')]['id']),'tags':_0x559dd8||[]};});})[_0x2d7434('0x52')](respondWithResult(_0x22d1ea,null))['catch'](handleError(_0x22d1ea,null));},exports['removeTags']=function(_0x1b34e2,_0x293999){const _0x24a3c7=_0x56baa0;return db[_0x24a3c7('0x9a')][_0x24a3c7('0x4a')]({'where':{'id':_0x1b34e2[_0x24a3c7('0x56')]['id']}})[_0x24a3c7('0x52')](handleEntityNotFound(_0x293999,null))[_0x24a3c7('0x52')](function(_0x3d6e23){const _0x485b86=_0x24a3c7;if(_0x3d6e23)return _0x3d6e23[_0x485b86('0xd4')](_0x1b34e2[_0x485b86('0x4c')]['ids']);})[_0x24a3c7('0x52')](respondWithStatusCode(_0x293999,null))[_0x24a3c7('0xb8')](handleError(_0x293999,null));},exports[_0x56baa0('0x3a')]=function(_0x2f5ad5,_0x21c336){const _0x2afa44=_0x56baa0,_0x18b84b=moment()['unix']()[_0x2afa44('0x64')](),_0x40c360=path[_0x2afa44('0x2d')](config[_0x2afa44('0x1a')],_0x2afa44('0x32'),'tmp'),_0x295098=path['join'](config['root'],_0x2afa44('0x1c'),_0x2afa44('0x32'),_0x2afa44('0x1d')),_0xd6fc3b=path[_0x2afa44('0x2d')](_0x40c360,_0x18b84b),_0x475b54=util['format'](_0x2afa44('0xab'),_0x2f5ad5[_0x2afa44('0x56')]['id'],_0x18b84b),_0xde4a2e=path[_0x2afa44('0x2d')](_0x40c360,_0x475b54),_0x13e34c=[];_0x13e34c[_0x2afa44('0x7e')]({'model':db[_0x2afa44('0x95')],'as':_0x2afa44('0x95'),'attributes':['id','fullname'],'raw':!![]}),_0x13e34c[_0x2afa44('0x7e')]({'model':db[_0x2afa44('0x9b')],'as':_0x2afa44('0x7d'),'attributes':['id',_0x2afa44('0x7b'),_0x2afa44('0x5c')],'raw':!![]});_0x2f5ad5[_0x2afa44('0x4c')][_0x2afa44('0x1d')]&&_0x13e34c[_0x2afa44('0x7e')]({'model':db['Attachment'],'as':'Attachment','raw':!![]});const _0x45e5ef=[{'model':db[_0x2afa44('0x58')],'as':_0x2afa44('0x78'),'attributes':['id',_0x2afa44('0x5b'),_0x2afa44('0x91'),'direction',_0x2afa44('0x63'),'read'],'include':_0x13e34c}];return _0x45e5ef['push']({'model':db[_0x2afa44('0x9e')],'as':'Account','attributes':['id',_0x2afa44('0x55')]}),_0x45e5ef['push']({'model':db['User'],'as':_0x2afa44('0x6c'),'attributes':['id',_0x2afa44('0x85')]}),db[_0x2afa44('0x9a')][_0x2afa44('0x4a')]({'where':{'id':_0x2f5ad5[_0x2afa44('0x56')]['id']},'include':_0x45e5ef})['then'](handleEntityNotFound(_0x21c336,null))['then'](function(_0xe54d5d){const _0x1095a3=_0x2afa44;if(_0xe54d5d){const _0x2f2a63=_0xe54d5d[_0x1095a3('0x2e')]({'plain':!![]});fs[_0x1095a3('0xb5')](_0xd6fc3b);const _0xf6e270={'format':'A4','border':_0x1095a3('0x24'),'header':{'height':_0x1095a3('0xc'),'contents':{'first':_0x1095a3('0x6d')}},'footer':{'height':_0x1095a3('0x90'),'contents':{'default':util[_0x1095a3('0xb4')](_0x1095a3('0x6'),util[_0x1095a3('0xb4')](_0x1095a3('0xc1'),_0x1095a3('0x17'),_0x2f2a63['id']),moment()[_0x1095a3('0xb4')](_0x1095a3('0x9f'))['toString']())}}},_0x1f0a34={'channel':'Whatsapp','account':_0x2f2a63[_0x1095a3('0x2f')][_0x1095a3('0x55')],'agent':_0x2f2a63[_0x1095a3('0x6c')]?_0x2f2a63['Owner'][_0x1095a3('0x85')]:_0x1095a3('0x3e'),'createdAt':moment(_0x2f2a63[_0x1095a3('0x91')])[_0x1095a3('0xb4')]('YYYY-MM-DD\x20HH:mm:ss')['toString'](),'closedAt':_0x2f2a63['closed']?moment(_0x2f2a63[_0x1095a3('0x89')])[_0x1095a3('0xb4')]('YYYY-MM-DD\x20HH:mm:ss')[_0x1095a3('0x64')]():'','disposition':_0x2f2a63[_0x1095a3('0x83')],'messages':_(_0x2f2a63[_0x1095a3('0x78')])[_0x1095a3('0xcc')]({'secret':![]})[_0x1095a3('0x81')](function(_0x4720b6){const _0x2e9ab6=_0x1095a3;if(_0x4720b6[_0x2e9ab6('0x93')]){const _0x154e0b=path['join'](_0x295098,_0x4720b6[_0x2e9ab6('0x93')]['basename']);fs[_0x2e9ab6('0x66')](_0x154e0b)&&fs[_0x2e9ab6('0x5e')](_0x154e0b)['pipe'](fs['createWriteStream'](path['join'](_0xd6fc3b,_0x4720b6[_0x2e9ab6('0x93')][_0x2e9ab6('0x3')])));}return{'date':moment(_0x4720b6[_0x2e9ab6('0x91')])[_0x2e9ab6('0xb4')](_0x2e9ab6('0x26'))[_0x2e9ab6('0x64')](),'sender':_0x4720b6[_0x2e9ab6('0x61')]===_0x2e9ab6('0x4f')?_0x4720b6[_0x2e9ab6('0x95')]?_0x4720b6[_0x2e9ab6('0x95')][_0x2e9ab6('0x85')]:_0x2e9ab6('0x1b'):_0x4720b6[_0x2e9ab6('0x7d')][_0x2e9ab6('0x7b')]+(_0x4720b6['Contact'][_0x2e9ab6('0x5c')]?'\x20'+_0x4720b6[_0x2e9ab6('0x7d')][_0x2e9ab6('0x5c')]:''),'body':_0x4720b6[_0x2e9ab6('0x93')]?_0x4720b6[_0x2e9ab6('0x93')][_0x2e9ab6('0x3')]:_0x4720b6[_0x2e9ab6('0x5b')],'direction':_0x4720b6[_0x2e9ab6('0x61')]===_0x2e9ab6('0x4f')?'A':'C','secret':_0x4720b6['secret'],'read':_0x4720b6[_0x2e9ab6('0xa2')],'attachment':_0x4720b6[_0x2e9ab6('0x93')]};})['value']()};return ejs[_0x1095a3('0x6e')](path['join'](config['root'],_0x1095a3('0x1c'),_0x1095a3('0x75'),_0x1095a3('0xcb')),{'interaction':_0x1f0a34})[_0x1095a3('0x52')](function(_0x35ec0a){return new Promise(function(_0x37d8d7,_0x297d1a){const _0xc92e4e=a794_0x31c1;pdf['create'](_0x35ec0a,_0xf6e270)[_0xc92e4e('0x2b')](path[_0xc92e4e('0x2d')](_0xd6fc3b,_0xc92e4e('0xb7')+_0x2f2a63['id']+'-'+_0x18b84b+'.pdf'),function(_0x28634b,_0x56eed9){if(_0x28634b)return _0x297d1a(_0x28634b);_0x37d8d7(_0x56eed9);});});})['then'](function(){const _0x35eb0e=_0x1095a3;return new Promise(function(_0x137668,_0xbc3d0a){zipdir(_0xd6fc3b,{'saveTo':_0xde4a2e},function(_0x190cb5,_0x5618fd){if(_0x190cb5)return _0xbc3d0a(_0x190cb5);return _0x137668(_0x5618fd);});})[_0x35eb0e('0x52')](function(){return new Promise(function(_0x56cd6a,_0x2f5038){rimraf(_0xd6fc3b,function(_0x1aaf28){if(_0x1aaf28)_0x2f5038(_0x1aaf28);return _0x56cd6a();});});})['then'](function(){return _0x21c336['download'](_0xde4a2e,_0x475b54,function(_0x1c6807){const _0x5f563f=a794_0x31c1;_0x1c6807?console[_0x5f563f('0xca')](_0x5f563f('0x1'),_0x1c6807):fs['unlinkSync'](_0xde4a2e);});});});}else return _0x21c336['sendStatus'](0xc8);})[_0x2afa44('0xb8')](handleError(_0x21c336,null));}; \ No newline at end of file +const a794_0x3f1c=['length','TagIds','nolimit','left_join','null','Whatsapp','sequelize','tools_tags','createdAt','Sequelize','model','path','QueryTypes','keys','ui.WhatsappInteractionId\x20IN\x20?','WhatsappMessage','from','isEmpty','a.key','Attachment','cm_contacts','status','firstName','rawAttributes','../../config/environment','WhatsappInteractionId','log','fieldName','update','color','direction','i.WhatsappAccountId\x20IN\x20?','transcript-','`\x20>\x200','../../rediscache','union','ids','c.mobile','Contact.mobile','MATCH\x20(c.firstName,\x20c.lastName,\x20c.phone,\x20c.mobile,\x20c.fax,\x20c.email)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','tmp','Contact.lastName','gte','i.WhatsappAccountId\x20IS\x20NULL','Contact.phone','c.id\x20=\x20i.ContactId\x20AND\x20c.deletedAt\x20IS\x20NULL','c.fax','join','Users','SUM(me.read\x20=\x200\x20AND\x20me.direction\x20=\x20\x27in\x27)','WhatsappAccountId','$gte','attachments','user','forEach','search','`unreadMessages`\x20=\x200','filters','GROUP_CONCAT(DISTINCT\x20t.id)','User','params','some','CONCAT(c.firstName,\x20\x27\x20\x27,\x20c.lastName)\x20LIKE\x20?','rows','SELECT','split','CmContact','map','pick','Account.mandatoryDisposition','replace','push','buildExpression','fields','sqlOperator','Contact.firstName','renderFile','intersection','whatsapp_accounts','sendStatus','send','body','lastName','basename','toString','out','addMessage','type','findAll','CONCAT_WS(\x27\x20\x27,\x20o.name,\x20o.fullname)\x20LIKE\x20?','text','expr','util','stack','it.WhatsappInteractionId\x20=\x20i.id','catch','i.phone\x20LIKE\x20?','find','having','10px','c.phone','tag','Content-Range','emit','YYYY-MM-DD','conditions','end','createReadStream','%s\x20#%d','rimraf','$substring','CONCAT(\x27,\x27,\x20`TagIds`,\x20\x27,\x27)\x20LIKE\x20?','getFullTextValue','root','users','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{{page}}/{{pages}}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20%s\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','Messages','filter','count','unreadMessages','i.id','./whatsappInteraction.socket','30px','MATCH\x20(me.body)\x20AGAINST\x20(?\x20IN\x20BOOLEAN\x20MODE)','`\x20=\x200','includeAll','undefined','Owner','like','ejs','index','user_has_whatsapp_interactions','name','YYYY-MM-DD\x20HH:mm:ss','setTags','register','i.createdAt\x20BETWEEN\x20?\x20AND\x20?','whatsapp_messages','Contact','secret','isArray','removeTags','\x27\x27\x27\x27','select','closed','$lte','err','field','fullname','files','omit','compact','c.firstName\x20LIKE\x20?\x20OR\x20c.lastName\x20LIKE\x20?\x20OR\x20c.email\x20LIKE\x20?','Contact.email','findOne','include','Account.key','unix','then','Account','options','u.fullname','server','createWriteStream','read','u.id','format','isNumeric','addTags','Owner.internal','start','closedAt','unlinkSync','concat','lodash','Tags','query','show','download','c.lastName','destroy','describe','a.mandatoryDisposition','../../components/parsers/qs','order','a.id\x20=\x20i.WhatsappAccountId','o.id\x20=\x20i.UserId','all','sort','../../components/parsers/advancedSearch','mkdirSync','../../config/logger','o.fullname','value','t.id\x20IN\x20?','where','set','key','ContactId','40px','operator','../../mysqldb','Contact.fax','parse','getMessages','attributes','group','merge','create','transcript-%d-%s.zip','me.WhatsappInteractionId\x20=\x20i.id','existsSync','UserId','N.A.','pipe','Tag','whatsappInteractionTags:save','offset','limit','WhatsappInteraction'];(function(_0x20c89f,_0x3f1c11){const _0x2deffc=function(_0x1bfb93){while(--_0x1bfb93){_0x20c89f['push'](_0x20c89f['shift']());}};_0x2deffc(++_0x3f1c11);}(a794_0x3f1c,0x142));const a794_0x2def=function(_0x20c89f,_0x3f1c11){_0x20c89f=_0x20c89f-0x0;let _0x2deffc=a794_0x3f1c[_0x20c89f];return _0x2deffc;};const _0x48d991=a794_0x2def;'use strict';const pdf=require('html-pdf'),rimraf=require(_0x48d991('0x7')),zipdir=require('zip-dir'),moment=require('moment'),util=require(_0x48d991('0xd2')),path=require(_0x48d991('0x81')),ejs=require(_0x48d991('0x1b')),fs=require('fs'),_=require(_0x48d991('0x48')),squel=require('squel'),{getSocket}=require(_0x48d991('0x98')),socket=getSocket(),qs=require(_0x48d991('0x51')),as=require(_0x48d991('0x57')),logger=require(_0x48d991('0x59'))('api'),config=require(_0x48d991('0x8e')),db=require(_0x48d991('0x63'))['db'],{Op}=require(_0x48d991('0x7c'));require(_0x48d991('0x13'))[_0x48d991('0x21')](socket);function respondWithStatusCode(_0x1bfb93,_0x242979){return _0x242979=_0x242979||0xcc,function(_0x5417f8){const _0x1a0a96=a794_0x2def;if(_0x5417f8)return _0x1bfb93[_0x1a0a96('0xc5')](_0x242979);return _0x1bfb93['status'](_0x242979)[_0x1a0a96('0x4')]();};}function respondWithResult(_0x4d8964,_0x5cdd36){return _0x5cdd36=_0x5cdd36||0xc8,function(_0x182bb1){const _0x74fa89=a794_0x2def;if(_0x182bb1)return _0x4d8964[_0x74fa89('0x8b')](_0x5cdd36)['json'](_0x182bb1);};}function respondWithFilteredResult(_0x588957,_0x4ca66c){return function(_0x44d492){const _0x7b03f1=a794_0x2def;if(_0x44d492){const _0x13a969=_0x44d492[_0x7b03f1('0x10')],_0x55eb62=_0x4ca66c[_0x7b03f1('0x73')];let _0xbf869c=_0x4ca66c[_0x7b03f1('0x73')]+_0x4ca66c[_0x7b03f1('0x74')],_0x256089;return _0xbf869c>=_0x13a969?(_0xbf869c=_0x13a969,_0x256089=0xc8):_0x256089=0xce,_0x588957[_0x7b03f1('0x8b')](_0x256089),_0x588957[_0x7b03f1('0x5e')](_0x7b03f1('0x0'),_0x55eb62+'-'+_0xbf869c+'/'+_0x13a969)['json'](_0x44d492);}return null;};}function saveUpdates(_0x4273c2){return function(_0x5d6fa5){const _0x5e454a=a794_0x2def;if(_0x5d6fa5)return _0x5d6fa5[_0x5e454a('0x92')](_0x4273c2)[_0x5e454a('0x38')](function(_0x475aa2){return _0x475aa2;});return null;};}function removeEntity(_0x17a299){return function(_0x483406){if(_0x483406)return _0x483406['destroy']()['then'](function(){const _0x26c01d=a794_0x2def;_0x17a299['status'](0xcc)[_0x26c01d('0x4')]();});};}function handleEntityNotFound(_0x35b182){return function(_0x4da94d){const _0x3222d1=a794_0x2def;return!_0x4da94d&&_0x35b182[_0x3222d1('0xc5')](0x194),_0x4da94d;};}function handleError(_0x598a26,_0x5d1ceb){return _0x5d1ceb=_0x5d1ceb||0x1f4,function(_0xf471e5){const _0x30a5f4=a794_0x2def;logger['error'](_0xf471e5[_0x30a5f4('0xd3')]),_0xf471e5['name']&&delete _0xf471e5[_0x30a5f4('0x1e')],_0x598a26[_0x30a5f4('0x8b')](_0x5d1ceb)[_0x30a5f4('0xc6')](_0xf471e5);};}function getInteractionUsers(_0x3f2ef1,_0x219a14){return new Promise(function(_0x1ed8d2,_0x1b2f6c){const _0x57cea3=a794_0x2def;try{_0x219a14[_0x3f2ef1['id']]&&(_0x3f2ef1[_0x57cea3('0xa6')]=_[_0x57cea3('0xb9')](_0x219a14[_0x3f2ef1['id']],function(_0x52d42c){const _0x6c1a5a=_0x57cea3;return{'id':_0x52d42c['id'],'fullname':_0x52d42c[_0x6c1a5a('0x2e')]};}));}catch(_0x3ad79a){_0x1b2f6c(_0x3ad79a);}_0x1ed8d2(_0x3f2ef1);});}function getInteractionTags(_0x143b8b,_0x2b95e7){return new Promise(function(_0x4ec33d,_0x41e650){const _0x5cf575=a794_0x2def;try{_0x143b8b[_0x5cf575('0x77')]&&(_0x143b8b[_0x5cf575('0x49')]=[],_0x143b8b[_0x5cf575('0x77')][_0x5cf575('0xb7')](',')[_0x5cf575('0xac')](function(_0x2a3463){const _0x24c922=_0x5cf575;_0x143b8b[_0x24c922('0x49')][_0x24c922('0xbd')](_0x2b95e7[_0x2a3463]);})),delete _0x143b8b[_0x5cf575('0x77')];}catch(_0xd98220){_0x41e650(_0xd98220);}_0x4ec33d(_0x143b8b);});}function updateWhatsappInteraction(_0x3fddf4,_0x406478,_0x1c85b8){return new Promise(function(_0x97e72a,_0x3bc205){const _0xd15a71=a794_0x2def;return getInteractionUsers(_0x3fddf4,_0x1c85b8)[_0xd15a71('0x38')](function(_0x43c114){return getInteractionTags(_0x43c114,_0x406478);})[_0xd15a71('0x38')](function(_0x397870){_0x97e72a(_0x397870);})['catch'](function(_0x1c2b02){_0x3bc205(_0x1c2b02);});});}exports[_0x48d991('0x1c')]=function(_0x6e2a5a,_0x57e835){const _0x581136=_0x48d991,_0x7c2275={},_0x3c2853={},_0x53e504={'count':0x0,'rows':[]},_0x3dbdef=_['map'](db[_0x581136('0x75')]['rawAttributes'],function(_0x4907c3){const _0x1e0d0f=_0x581136;return{'name':_0x4907c3[_0x1e0d0f('0x91')],'type':_0x4907c3[_0x1e0d0f('0xcd')][_0x1e0d0f('0x5f')]};});_0x3c2853[_0x581136('0x80')]=_[_0x581136('0xb9')](_0x3dbdef,_0x581136('0x1e')),_0x3c2853[_0x581136('0x4a')]=_[_0x581136('0x83')](_0x6e2a5a[_0x581136('0x4a')]),_0x3c2853['filters']=_[_0x581136('0xc3')](_0x3c2853['model'],_0x3c2853[_0x581136('0x4a')]),_0x7c2275[_0x581136('0x67')]=_[_0x581136('0xc3')](_0x3c2853[_0x581136('0x80')],qs[_0x581136('0xbf')](_0x6e2a5a[_0x581136('0x4a')][_0x581136('0xbf')])),_0x7c2275['attributes']=_0x7c2275[_0x581136('0x67')][_0x581136('0x76')]?_0x7c2275[_0x581136('0x67')]:_0x3c2853[_0x581136('0x80')];typeof _0x6e2a5a[_0x581136('0x4a')][_0x581136('0x78')]===_0x581136('0x18')&&(_0x7c2275[_0x581136('0x74')]=qs[_0x581136('0x74')](_0x6e2a5a[_0x581136('0x4a')][_0x581136('0x74')]),_0x7c2275[_0x581136('0x73')]=qs[_0x581136('0x73')](_0x6e2a5a[_0x581136('0x4a')][_0x581136('0x73')]));_0x7c2275[_0x581136('0x52')]=qs['sort'](_0x6e2a5a[_0x581136('0x4a')][_0x581136('0x56')]),_0x7c2275[_0x581136('0x5d')]=qs['filters'](_[_0x581136('0xba')](_0x6e2a5a[_0x581136('0x4a')],_0x3c2853[_0x581136('0xaf')]),_0x3dbdef);let _0x17b785=[];const _0x19809d=squel[_0x581136('0x29')]()[_0x581136('0x2d')]('id')[_0x581136('0x2d')](_0x581136('0x1e'))['field'](_0x581136('0x93'))['from'](_0x581136('0x7d')),_0x130890=squel[_0x581136('0x29')]()[_0x581136('0x2d')](_0x581136('0x3f'))[_0x581136('0x2d')](_0x581136('0x3b'))['field']('ui.WhatsappInteractionId')[_0x581136('0x86')](_0x581136('0x1d'),'ui')[_0x581136('0x79')](_0x581136('0xc'),'u','u.id\x20=\x20ui.UserId'),_0x50e1e1=squel[_0x581136('0x29')]()[_0x581136('0x86')]('whatsapp_interactions','i')[_0x581136('0x79')](_0x581136('0x8a'),'c',_0x581136('0xa3'))[_0x581136('0x79')]('users','o',_0x581136('0x54'))[_0x581136('0x79')](_0x581136('0xc4'),'a',_0x581136('0x53'))['left_join'](_0x581136('0x23'),'me',_0x581136('0x6c'))[_0x581136('0x79')]('whatsapp_interaction_has_tags','it',_0x581136('0xd4'))[_0x581136('0x79')]('tools_tags','t','t.id\x20=\x20it.TagId'),_0x445236=squel[_0x581136('0xd1')]();let _0x3eb4d9=[];const _0x3f3393=squel[_0x581136('0xd1')]();let _0x4a3f61;if(_0x6e2a5a[_0x581136('0x4a')][_0x581136('0xad')]){_0x4a3f61=as['parseSearch'](_0x6e2a5a[_0x581136('0x4a')]['search']);const _0x1ea1bb=_0x4a3f61[_0x581136('0xc0')];for(let _0x515182=0x0;_0x515182<_0x4a3f61['conditions'][_0x581136('0x76')];_0x515182++){const _0x314712=_0x4a3f61[_0x581136('0x3')][_0x515182],_0x1f64ad='i';let _0x1881fe,_0x3c7f1d=_[_0x581136('0xd7')](_0x3dbdef,[_0x581136('0x1e'),_0x314712['field']]);if(!_0x3c7f1d)switch(_0x314712[_0x581136('0x2d')]){case _0x581136('0x11'):_0x314712[_0x581136('0x5b')]==0x1?_0x50e1e1[_0x581136('0xd8')]('`'+_0x314712[_0x581136('0x2d')]+_0x581136('0x16')):_0x50e1e1[_0x581136('0xd8')]('`'+_0x314712[_0x581136('0x2d')]+_0x581136('0x97'));break;case _0x581136('0x24'):if(_0x314712['operator']==='$substring'){if(_0x314712[_0x581136('0x5b')][_0x581136('0xb7')]('\x20')['length']>0x1)_0x445236[_0x1ea1bb](_0x581136('0x9d'),qs['getFullTextValue'](_0x314712['value']),null);else{const _0x1e2064='%'+_0x314712['value']+'%';_0x445236[_0x1ea1bb](_0x581136('0x32'),_0x1e2064,_0x1e2064,_0x1e2064);}}else _0x3c7f1d=_[_0x581136('0xd7')](_0x3dbdef,[_0x581136('0x1e'),_0x581136('0x60')]),_0x314712[_0x581136('0x2d')]=_0x581136('0x60'),_0x1881fe=as['buildExpression'](_0x1f64ad,_0x3c7f1d[_0x581136('0xcd')],_0x314712),_0x445236[_0x1ea1bb](_0x1881fe['text'],_0x1881fe[_0x581136('0x5b')][_0x581136('0x44')],_0x1881fe['value'][_0x581136('0x4')]);break;case _0x581136('0x71'):{const _0x2bdc95=_0x314712[_0x581136('0x5b')][_0x581136('0xb7')](',')[_0x581136('0xb9')](function(_0x37e59a){return Number(_0x37e59a);});_0x2bdc95[_0x581136('0xac')](function(_0xfacbdc){const _0x22f372=_0x581136;_0x3f3393['or'](_0x22f372('0x9'),'%,'+_0xfacbdc+',%');}),_0x3eb4d9=_[_0x581136('0x99')](_0x3eb4d9,_0x2bdc95);}break;case'User':_0x314712[_0x581136('0x62')]===_0x581136('0x8')?_0x445236[_0x1ea1bb](_0x581136('0xcf'),'%'+_0x314712[_0x581136('0x5b')]+'%',null):(_0x3c7f1d=_[_0x581136('0xd7')](_0x3dbdef,[_0x581136('0x1e'),_0x581136('0x6e')]),_0x314712[_0x581136('0x2d')]='UserId',_0x1881fe=as['buildExpression'](_0x1f64ad,_0x3c7f1d[_0x581136('0xcd')],_0x314712),_0x445236[_0x1ea1bb](_0x1881fe['text'],_0x1881fe[_0x581136('0x5b')][_0x581136('0x44')],_0x1881fe[_0x581136('0x5b')][_0x581136('0x4')]));break;case'body':_0x1881fe=as[_0x581136('0xbe')]('me',null,_0x314712),_0x445236[_0x1ea1bb](_0x1881fe[_0x581136('0xd0')],_0x1881fe['value'][_0x581136('0x44')],_0x1881fe[_0x581136('0x5b')][_0x581136('0x4')]);break;}else _0x1881fe=as[_0x581136('0xbe')](_0x1f64ad,_0x3c7f1d[_0x581136('0xcd')],_0x314712),_0x445236[_0x1ea1bb](_0x1881fe[_0x581136('0xd0')],_0x1881fe[_0x581136('0x5b')][_0x581136('0x44')],_0x1881fe[_0x581136('0x5b')][_0x581136('0x4')]);}}else{const _0x38588b=_(_0x6e2a5a[_0x581136('0x4a')])[_0x581136('0x83')]()[_0x581136('0xb9')](function(_0x1b43ad){const _0x329231=_0x581136;return _[_0x329231('0xb3')](_0x3dbdef,[_0x329231('0x1e'),_0x1b43ad])?_0x1b43ad:undefined;})[_0x581136('0x31')]()['value']();!_['isEmpty'](_0x38588b)&&_0x38588b[_0x581136('0xac')](function(_0x1643d1){const _0x479f4e=_0x581136;if(_0x1643d1===_0x479f4e('0xa8'))_0x50e1e1[_0x479f4e('0x5d')](_0x479f4e('0x95'),[][_0x479f4e('0x47')](_0x6e2a5a[_0x479f4e('0x4a')][_0x1643d1]));else{if(_0x1643d1===_0x479f4e('0x7e')){const _0x7c868f=JSON[_0x479f4e('0x65')](_0x6e2a5a[_0x479f4e('0x4a')][_0x1643d1])[_0x479f4e('0xa9')],_0xa0f65d=JSON['parse'](_0x6e2a5a['query'][_0x1643d1])[_0x479f4e('0x2b')];_0x50e1e1[_0x479f4e('0x5d')](_0x479f4e('0x22'),_0x7c868f,_0xa0f65d);}else _0x6e2a5a['query'][_0x1643d1]===_0x479f4e('0x7a')?_0x50e1e1[_0x479f4e('0x5d')]('i.'+_0x1643d1+'\x20IS\x20NULL'):_0x50e1e1[_0x479f4e('0x5d')]('i.'+_0x1643d1+'\x20=\x20?',_0x6e2a5a[_0x479f4e('0x4a')][_0x1643d1]);}});_0x6e2a5a[_0x581136('0x4a')]['read']&&(_0x6e2a5a[_0x581136('0x4a')][_0x581136('0x3e')]==0x1?_0x50e1e1[_0x581136('0xd8')](_0x581136('0xae')):_0x50e1e1[_0x581136('0xd8')]('`unreadMessages`\x20>\x200'));_0x6e2a5a[_0x581136('0x4a')][_0x581136('0xdb')]&&(_0x3eb4d9=_[_0x581136('0x26')](_0x6e2a5a[_0x581136('0x4a')][_0x581136('0xdb')])?_0x6e2a5a[_0x581136('0x4a')]['tag']:new Array(_0x6e2a5a['query'][_0x581136('0xdb')]),_0x3eb4d9['forEach'](function(_0x551433){const _0x17c612=_0x581136;_0x3f3393['or'](_0x17c612('0x9'),'%,'+_0x551433+',%');}));if(_0x6e2a5a[_0x581136('0x4a')]['filter']){const _0x3fa3e3=_0x6e2a5a[_0x581136('0x4a')][_0x581136('0xf')][_0x581136('0xbc')]('\x5c','\x5c\x5c')[_0x581136('0xbc')]('\x27\x27',_0x581136('0x28'));qs[_0x581136('0x41')](_0x3fa3e3)?_0x445236['or']('i.id\x20LIKE\x20?',_0x3fa3e3+'%')['or'](_0x581136('0xd6'),_0x3fa3e3+'%'):_0x445236['or'](_0x581136('0x15'),qs[_0x581136('0xa')](_0x3fa3e3))['or'](_0x581136('0xb4'),_0x3fa3e3+'%');}}_0x50e1e1[_0x581136('0x5d')](_0x445236),_0x50e1e1[_0x581136('0x68')]('i.id');let _0xd36915={'type':db[_0x581136('0x7f')][_0x581136('0x82')][_0x581136('0xb6')],'raw':!![]};const _0x508fd3=_0x50e1e1['clone']();_0x508fd3['field'](_0x581136('0x12')),_0x508fd3[_0x581136('0x2d')](_0x581136('0xa7'),_0x581136('0x11')),_0x7c2275['order']&&_0x7c2275[_0x581136('0x52')][_0x581136('0xac')](function(_0x548f89){const _0x498ff0=_0x581136;_0x50e1e1[_0x498ff0('0x52')]('i.'+_0x548f89[0x0],_0x548f89[0x1]==='DESC'?![]:!![]);}),!_['isEmpty'](_0x3eb4d9)&&(_0x50e1e1[_0x581136('0xd8')](_0x3f3393),_0x508fd3[_0x581136('0x5d')](_0x581136('0x5c'),_0x3eb4d9)),Promise['resolve']()[_0x581136('0x38')](function(){const _0x3ba15b=_0x581136;if(!_0x4a3f61){if(_0x6e2a5a[_0x3ba15b('0x4a')]['WhatsappAccountId']||_0x6e2a5a['query']['journey'])return;_0x508fd3[_0x3ba15b('0x5d')]('i.WhatsappAccountId\x20IS\x20NOT\x20NULL'),_0x50e1e1[_0x3ba15b('0x5d')]('i.WhatsappAccountId\x20IS\x20NOT\x20NULL');return;}return _0x6e2a5a[_0x3ba15b('0xab')]['getWhatsappAccounts']({'attributes':['id'],'raw':!![]})[_0x3ba15b('0x38')](function(_0x29bddd){const _0x325b2c=_0x3ba15b;_[_0x325b2c('0x87')](_0x29bddd)?(_0x508fd3['where'](_0x325b2c('0xa1')),_0x50e1e1[_0x325b2c('0x5d')](_0x325b2c('0xa1'))):(_0x508fd3[_0x325b2c('0x5d')](_0x325b2c('0x95'),_[_0x325b2c('0xb9')](_0x29bddd,'id')),_0x50e1e1[_0x325b2c('0x5d')](_0x325b2c('0x95'),_[_0x325b2c('0xb9')](_0x29bddd,'id')));});})[_0x581136('0x38')](function(){const _0x2b41f1=_0x581136;db[_0x2b41f1('0x7c')][_0x2b41f1('0x4a')](_0x508fd3[_0x2b41f1('0xca')](),_0xd36915)[_0x2b41f1('0x38')](function(_0x40abda){const _0x22247b=_0x2b41f1;_0x53e504[_0x22247b('0x10')]=_0x40abda['length'];if(_0x53e504[_0x22247b('0x10')]===0x0)return[];return db[_0x22247b('0x7c')][_0x22247b('0x4a')](_0x19809d['toString'](),_0xd36915)['then'](function(_0x505f70){const _0x5b4260=_0x22247b;_0x17b785=_['keyBy'](_0x505f70,'id'),_0xd36915=_['merge'](_0xd36915,{'model':db[_0x5b4260('0x75')],'mapToModel':!![],'raw':!![],'nest':!![]});_0x6e2a5a['query'][_0x5b4260('0xbf')]?_0x7c2275[_0x5b4260('0x67')][_0x5b4260('0xac')](function(_0x1d8699){const _0x405161=_0x5b4260;_0x50e1e1[_0x405161('0x2d')]('i.'+_0x1d8699);}):(_0x50e1e1[_0x5b4260('0x2d')](_0x5b4260('0xa7'),_0x5b4260('0x11')),_0x50e1e1['field'](_0x5b4260('0x88'),_0x5b4260('0x36')),_0x50e1e1['field'](_0x5b4260('0x50'),_0x5b4260('0xbb')),_0x50e1e1[_0x5b4260('0x2d')]('i.*'),_0x50e1e1[_0x5b4260('0x2d')]('c.firstName',_0x5b4260('0xc1')),_0x50e1e1[_0x5b4260('0x2d')](_0x5b4260('0x4d'),_0x5b4260('0x9f')),_0x50e1e1[_0x5b4260('0x2d')]('c.email',_0x5b4260('0x33')),_0x50e1e1['field'](_0x5b4260('0xda'),_0x5b4260('0xa2')),_0x50e1e1[_0x5b4260('0x2d')](_0x5b4260('0x9b'),_0x5b4260('0x9c')),_0x50e1e1['field'](_0x5b4260('0xa4'),_0x5b4260('0x64')),_0x50e1e1[_0x5b4260('0x2d')](_0x5b4260('0x5a'),'Owner.fullname'),_0x50e1e1[_0x5b4260('0x2d')]('o.internal',_0x5b4260('0x43')),_0x50e1e1[_0x5b4260('0x2d')](_0x5b4260('0xb0'),'TagIds'));if(_0x7c2275['limit'])_0x50e1e1[_0x5b4260('0x74')](_0x7c2275[_0x5b4260('0x74')]);if(_0x7c2275[_0x5b4260('0x73')])_0x50e1e1[_0x5b4260('0x73')](_0x7c2275[_0x5b4260('0x73')]);return db[_0x5b4260('0x7c')][_0x5b4260('0x4a')](_0x50e1e1['toString'](),_0xd36915);})[_0x22247b('0x38')](function(_0x1f40dc){const _0x26a3bd=_0x22247b;return _0x130890['where'](_0x26a3bd('0x84'),_[_0x26a3bd('0xb9')](_0x1f40dc,'id')),db[_0x26a3bd('0x7c')]['query'](_0x130890['toString'](),_0xd36915)['then'](function(_0x577f2c){const _0x52e5cd=_0x26a3bd,_0x396f9e=_['groupBy'](_0x577f2c,_0x52e5cd('0x8f')),_0x53c065=[];return _0x1f40dc[_0x52e5cd('0xac')](function(_0x47fe41){const _0x5c602d=_0x52e5cd;_0x53c065[_0x5c602d('0xbd')](updateWhatsappInteraction(_0x47fe41,_0x17b785,_0x396f9e));}),Promise[_0x52e5cd('0x55')](_0x53c065);});});})[_0x2b41f1('0x38')](function(_0xb90dd5){const _0x4e1079=_0x2b41f1;return _0x53e504[_0x4e1079('0xb5')]=_0xb90dd5,_0x53e504;})[_0x2b41f1('0x38')](respondWithFilteredResult(_0x57e835,_0x7c2275));})[_0x581136('0xd5')](handleError(_0x57e835,null));},exports[_0x48d991('0x4b')]=function(_0x382f99,_0x4cb259){const _0x2631df=_0x48d991;let _0x4efbbf={'raw':![],'where':{'id':_0x382f99[_0x2631df('0xb2')]['id']}};const _0xc5896e={};return _0xc5896e[_0x2631df('0x80')]=_[_0x2631df('0x83')](db[_0x2631df('0x75')][_0x2631df('0x8d')]),_0xc5896e[_0x2631df('0x4a')]=_[_0x2631df('0x83')](_0x382f99[_0x2631df('0x4a')]),_0xc5896e[_0x2631df('0xaf')]=_['intersection'](_0xc5896e[_0x2631df('0x80')],_0xc5896e[_0x2631df('0x4a')]),_0x4efbbf['attributes']=_[_0x2631df('0xc3')](_0xc5896e[_0x2631df('0x80')],qs['fields'](_0x382f99[_0x2631df('0x4a')][_0x2631df('0xbf')])),_0x4efbbf['attributes']=_0x4efbbf[_0x2631df('0x67')][_0x2631df('0x76')]?_0x4efbbf[_0x2631df('0x67')]:_0xc5896e[_0x2631df('0x80')],_0x382f99[_0x2631df('0x4a')][_0x2631df('0x17')]&&(_0x4efbbf[_0x2631df('0x35')]=[{'all':!![]}]),_0x4efbbf=_[_0x2631df('0x69')]({},_0x4efbbf,_0x382f99['options']),db[_0x2631df('0x75')][_0x2631df('0x34')](_0x4efbbf)[_0x2631df('0x38')](handleEntityNotFound(_0x4cb259,null))[_0x2631df('0x38')](respondWithResult(_0x4cb259,null))[_0x2631df('0xd5')](handleError(_0x4cb259,null));},exports['create']=function(_0x24602e,_0x58b9a5){const _0x593dac=_0x48d991;return db[_0x593dac('0x75')][_0x593dac('0x6a')](_0x24602e[_0x593dac('0xc7')],{})['then'](respondWithResult(_0x58b9a5,0xc9))[_0x593dac('0xd5')](handleError(_0x58b9a5,null));},exports['update']=function(_0x16fc17,_0x5e3d20){const _0x56d873=_0x48d991;return _0x16fc17[_0x56d873('0xc7')]['id']&&delete _0x16fc17[_0x56d873('0xc7')]['id'],db[_0x56d873('0x75')]['findOne']({'where':{'id':_0x16fc17[_0x56d873('0xb2')]['id']}})[_0x56d873('0x38')](handleEntityNotFound(_0x5e3d20,null))[_0x56d873('0x38')](saveUpdates(_0x16fc17[_0x56d873('0xc7')],null))[_0x56d873('0x38')](respondWithResult(_0x5e3d20,null))[_0x56d873('0xd5')](handleError(_0x5e3d20,null));},exports[_0x48d991('0x4e')]=function(_0x11bee8,_0x385e81){const _0x2037fa=_0x48d991;return db['WhatsappInteraction'][_0x2037fa('0x34')]({'where':{'id':_0x11bee8[_0x2037fa('0xb2')]['id']}})[_0x2037fa('0x38')](handleEntityNotFound(_0x385e81,null))[_0x2037fa('0x38')](removeEntity(_0x385e81,null))[_0x2037fa('0xd5')](handleError(_0x385e81,null));},exports['describe']=function(_0x43bcd2,_0x23f18b){const _0x2bfe32=_0x48d991;return db[_0x2bfe32('0x75')][_0x2bfe32('0x4f')]()[_0x2bfe32('0x38')](respondWithResult(_0x23f18b,null))[_0x2bfe32('0xd5')](handleError(_0x23f18b,null));},exports[_0x48d991('0xcc')]=function(_0x125943,_0xce3603){const _0x4e8310=_0x48d991;return db[_0x4e8310('0x85')][_0x4e8310('0x34')]({'where':{'id':_0x125943[_0x4e8310('0xb2')]['id']}})[_0x4e8310('0x38')](function(_0x280408){const _0x84f206=_0x4e8310;if(_0x280408)return _0x280408[_0x84f206('0xcc')](_0x125943[_0x84f206('0xc7')][_0x84f206('0x9a')],{'through':_[_0x84f206('0x30')](_0x125943[_0x84f206('0xc7')],['ids','id'])});})[_0x4e8310('0x38')](respondWithResult(_0xce3603,null))[_0x4e8310('0xd5')](handleError(_0xce3603,null));},exports[_0x48d991('0x66')]=function(_0x214a32,_0x31d721){const _0x314ca1=_0x48d991;let _0x5cd638={'raw':![],'where':{}};const _0x16dcf3={},_0x37bf4c={'count':0x0,'rows':[]};return db[_0x314ca1('0x75')][_0x314ca1('0x34')]({'where':{'id':_0x214a32['params']['id']}})['then'](handleEntityNotFound(_0x31d721,null))['then'](function(_0xfb03b9){const _0x5eac05=_0x314ca1;if(_0xfb03b9){_0x16dcf3['model']=_[_0x5eac05('0x83')](db[_0x5eac05('0x85')]['rawAttributes']),_0x16dcf3[_0x5eac05('0x4a')]=_[_0x5eac05('0x83')](_0x214a32[_0x5eac05('0x4a')]),_0x16dcf3[_0x5eac05('0xaf')]=_['intersection'](_0x16dcf3[_0x5eac05('0x80')],_0x16dcf3[_0x5eac05('0x4a')]),_0x5cd638[_0x5eac05('0x67')]=_[_0x5eac05('0xc3')](_0x16dcf3['model'],qs[_0x5eac05('0xbf')](_0x214a32['query']['fields'])),_0x5cd638[_0x5eac05('0x67')]=_0x5cd638[_0x5eac05('0x67')]['length']?_0x5cd638[_0x5eac05('0x67')]:_0x16dcf3[_0x5eac05('0x80')];typeof _0x214a32[_0x5eac05('0x4a')][_0x5eac05('0x78')]===_0x5eac05('0x18')&&(_0x5cd638[_0x5eac05('0x74')]=qs[_0x5eac05('0x74')](_0x214a32['query'][_0x5eac05('0x74')]),_0x5cd638[_0x5eac05('0x73')]=qs[_0x5eac05('0x73')](_0x214a32[_0x5eac05('0x4a')][_0x5eac05('0x73')]));_0x5cd638['order']=qs[_0x5eac05('0x56')](_0x214a32['query']['sort']),_0x5cd638[_0x5eac05('0x5d')]=qs[_0x5eac05('0xaf')](_['pick'](_0x214a32[_0x5eac05('0x4a')],_0x16dcf3[_0x5eac05('0xaf')])),_0x5cd638[_0x5eac05('0x5d')][_0x5eac05('0x8f')]=_0xfb03b9['id'];_0x214a32['query'][_0x5eac05('0xf')]&&(_0x5cd638[_0x5eac05('0x5d')]=_[_0x5eac05('0x69')](_0x5cd638[_0x5eac05('0x5d')],{[Op['or']]:_[_0x5eac05('0xb9')](_0x5cd638[_0x5eac05('0x67')],function(_0x12763e){const _0x32e3d0=_0x5eac05,_0xaa805f={};return _0xaa805f[_0x12763e]={[Op[_0x32e3d0('0x1a')]]:'%'+_0x214a32[_0x32e3d0('0x4a')][_0x32e3d0('0xf')]+'%'},_0xaa805f;})}));if(_0x214a32['query'][_0x5eac05('0xa9')]){const _0x345a7a=_0x214a32['query'][_0x5eac05('0xa9')][_0x5eac05('0xb7')](','),_0x49bdb2={};_0x49bdb2[_0x345a7a[0x0]]={[Op[_0x5eac05('0xa0')]]:moment(_0x345a7a[0x1])[_0x5eac05('0x40')](_0x5eac05('0x1f'))},_0x5cd638[_0x5eac05('0x5d')]=_['merge'](_0x5cd638[_0x5eac05('0x5d')],_0x49bdb2);}return _0x5cd638=_[_0x5eac05('0x69')]({},_0x5cd638,_0x214a32[_0x5eac05('0x3a')]),db['WhatsappMessage']['count']({'where':_0x5cd638[_0x5eac05('0x5d')]})[_0x5eac05('0x38')](function(_0x2a4023){const _0x1c6d4f=_0x5eac05;return _0x37bf4c[_0x1c6d4f('0x10')]=_0x2a4023,_0x214a32[_0x1c6d4f('0x4a')][_0x1c6d4f('0x17')]&&(_0x5cd638[_0x1c6d4f('0x35')]=[{'all':!![]}]),db[_0x1c6d4f('0x85')][_0x1c6d4f('0xce')](_0x5cd638);})['then'](function(_0x26b567){const _0x55284d=_0x5eac05;return _0x37bf4c[_0x55284d('0xb5')]=_0x26b567,_0x37bf4c;});}})[_0x314ca1('0x38')](respondWithFilteredResult(_0x31d721,_0x5cd638))['catch'](handleError(_0x31d721,null));},exports[_0x48d991('0x42')]=function(_0x4c742c,_0x1999c3){const _0x246d00=_0x48d991;return db[_0x246d00('0x75')][_0x246d00('0x34')]({'where':{'id':_0x4c742c[_0x246d00('0xb2')]['id']}})[_0x246d00('0x38')](function(_0x546033){const _0x4b7505=_0x246d00;if(_0x546033)return _0x546033[_0x4b7505('0x20')](_0x4c742c[_0x4b7505('0xc7')]['ids'],{'through':_[_0x4b7505('0x30')](_0x4c742c[_0x4b7505('0xc7')],['ids','id'])})[_0x4b7505('0x38')](function(){const _0x2cbb67=_0x4b7505;return db['Tag'][_0x2cbb67('0xce')]({'attributes':['id','name',_0x2cbb67('0x93')],'where':{'id':_0x4c742c[_0x2cbb67('0xc7')]['ids']}});})[_0x4b7505('0x38')](function(_0x3b20dd){const _0x154d9e=_0x4b7505;return socket[_0x154d9e('0x1')](_0x154d9e('0x72'),{'id':Number(_0x4c742c['params']['id']),'tags':_0x3b20dd||[]}),{'id':Number(_0x4c742c[_0x154d9e('0xb2')]['id']),'tags':_0x3b20dd||[]};});})[_0x246d00('0x38')](respondWithResult(_0x1999c3,null))[_0x246d00('0xd5')](handleError(_0x1999c3,null));},exports[_0x48d991('0x27')]=function(_0x24ae32,_0xdae32b){const _0x41803c=_0x48d991;return db['WhatsappInteraction']['findOne']({'where':{'id':_0x24ae32[_0x41803c('0xb2')]['id']}})['then'](handleEntityNotFound(_0xdae32b,null))[_0x41803c('0x38')](function(_0x1c09b3){const _0x386185=_0x41803c;if(_0x1c09b3)return _0x1c09b3[_0x386185('0x27')](_0x24ae32[_0x386185('0x4a')][_0x386185('0x9a')]);})[_0x41803c('0x38')](respondWithStatusCode(_0xdae32b,null))[_0x41803c('0xd5')](handleError(_0xdae32b,null));},exports[_0x48d991('0x4c')]=function(_0x2d5317,_0xa1e130){const _0x387d33=_0x48d991,_0x19ead1=moment()[_0x387d33('0x37')]()[_0x387d33('0xca')](),_0x250bca=path['join'](config[_0x387d33('0xb')],_0x387d33('0x2f'),_0x387d33('0x9e')),_0x5a9715=path['join'](config[_0x387d33('0xb')],_0x387d33('0x3c'),_0x387d33('0x2f'),_0x387d33('0xaa')),_0x4a3ca4=path[_0x387d33('0xa5')](_0x250bca,_0x19ead1),_0x5259ab=util[_0x387d33('0x40')](_0x387d33('0x6b'),_0x2d5317['params']['id'],_0x19ead1),_0x44ddc2=path['join'](_0x250bca,_0x5259ab),_0x550c8e=[];_0x550c8e[_0x387d33('0xbd')]({'model':db[_0x387d33('0xb1')],'as':_0x387d33('0xb1'),'attributes':['id',_0x387d33('0x2e')],'raw':!![]}),_0x550c8e[_0x387d33('0xbd')]({'model':db[_0x387d33('0xb8')],'as':_0x387d33('0x24'),'attributes':['id',_0x387d33('0x8c'),_0x387d33('0xc8')],'raw':!![]});_0x2d5317[_0x387d33('0x4a')]['attachments']&&_0x550c8e[_0x387d33('0xbd')]({'model':db[_0x387d33('0x89')],'as':_0x387d33('0x89'),'raw':!![]});const _0x3d15f4=[{'model':db[_0x387d33('0x85')],'as':_0x387d33('0xe'),'attributes':['id',_0x387d33('0xc7'),_0x387d33('0x7e'),_0x387d33('0x94'),_0x387d33('0x25'),_0x387d33('0x3e')],'include':_0x550c8e}];return _0x3d15f4[_0x387d33('0xbd')]({'model':db['WhatsappAccount'],'as':_0x387d33('0x39'),'attributes':['id',_0x387d33('0x1e')]}),_0x3d15f4[_0x387d33('0xbd')]({'model':db[_0x387d33('0xb1')],'as':_0x387d33('0x19'),'attributes':['id',_0x387d33('0x2e')]}),db[_0x387d33('0x75')][_0x387d33('0x34')]({'where':{'id':_0x2d5317['params']['id']},'include':_0x3d15f4})[_0x387d33('0x38')](handleEntityNotFound(_0xa1e130,null))['then'](function(_0x3172a3){const _0x5170b4=_0x387d33;if(_0x3172a3){const _0x43872f=_0x3172a3['get']({'plain':!![]});fs[_0x5170b4('0x58')](_0x4a3ca4);const _0xb8342c={'format':'A4','border':_0x5170b4('0xd9'),'header':{'height':_0x5170b4('0x61'),'contents':{'first':'\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20
Interaction\x20Transcript
\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'}},'footer':{'height':_0x5170b4('0x14'),'contents':{'default':util[_0x5170b4('0x40')](_0x5170b4('0xd'),util[_0x5170b4('0x40')](_0x5170b4('0x6'),_0x5170b4('0x7b'),_0x43872f['id']),moment()[_0x5170b4('0x40')](_0x5170b4('0x2'))['toString']())}}},_0x1333a8={'channel':_0x5170b4('0x7b'),'account':_0x43872f['Account']['name'],'agent':_0x43872f[_0x5170b4('0x19')]?_0x43872f[_0x5170b4('0x19')][_0x5170b4('0x2e')]:_0x5170b4('0x6f'),'createdAt':moment(_0x43872f[_0x5170b4('0x7e')])['format'](_0x5170b4('0x1f'))[_0x5170b4('0xca')](),'closedAt':_0x43872f[_0x5170b4('0x2a')]?moment(_0x43872f[_0x5170b4('0x45')])[_0x5170b4('0x40')]('YYYY-MM-DD\x20HH:mm:ss')[_0x5170b4('0xca')]():'','disposition':_0x43872f['disposition'],'messages':_(_0x43872f[_0x5170b4('0xe')])[_0x5170b4('0xf')]({'secret':![]})[_0x5170b4('0xb9')](function(_0x55e801){const _0x59c74b=_0x5170b4;if(_0x55e801['Attachment']){const _0x40fc9e=path['join'](_0x5a9715,_0x55e801[_0x59c74b('0x89')][_0x59c74b('0xc9')]);fs[_0x59c74b('0x6d')](_0x40fc9e)&&fs[_0x59c74b('0x5')](_0x40fc9e)[_0x59c74b('0x70')](fs[_0x59c74b('0x3d')](path[_0x59c74b('0xa5')](_0x4a3ca4,_0x55e801['Attachment'][_0x59c74b('0xc9')])));}return{'date':moment(_0x55e801[_0x59c74b('0x7e')])[_0x59c74b('0x40')]('YYYY-MM-DD\x20HH:mm:ss')[_0x59c74b('0xca')](),'sender':_0x55e801[_0x59c74b('0x94')]===_0x59c74b('0xcb')?_0x55e801[_0x59c74b('0xb1')]?_0x55e801[_0x59c74b('0xb1')]['fullname']:'System':_0x55e801[_0x59c74b('0x24')]['firstName']+(_0x55e801[_0x59c74b('0x24')][_0x59c74b('0xc8')]?'\x20'+_0x55e801[_0x59c74b('0x24')][_0x59c74b('0xc8')]:''),'body':_0x55e801[_0x59c74b('0x89')]?_0x55e801[_0x59c74b('0x89')][_0x59c74b('0xc9')]:_0x55e801[_0x59c74b('0xc7')],'direction':_0x55e801[_0x59c74b('0x94')]===_0x59c74b('0xcb')?'A':'C','secret':_0x55e801[_0x59c74b('0x25')],'read':_0x55e801[_0x59c74b('0x3e')],'attachment':_0x55e801[_0x59c74b('0x89')]};})[_0x5170b4('0x5b')]()};return ejs[_0x5170b4('0xc2')](path[_0x5170b4('0xa5')](config[_0x5170b4('0xb')],_0x5170b4('0x3c'),'views','downloadInteraction.html'),{'interaction':_0x1333a8})[_0x5170b4('0x38')](function(_0x3aca9f){return new Promise(function(_0xa71873,_0xe1798c){const _0x39962b=a794_0x2def;pdf['create'](_0x3aca9f,_0xb8342c)['toFile'](path[_0x39962b('0xa5')](_0x4a3ca4,_0x39962b('0x96')+_0x43872f['id']+'-'+_0x19ead1+'.pdf'),function(_0x574eb8,_0x52b40e){if(_0x574eb8)return _0xe1798c(_0x574eb8);_0xa71873(_0x52b40e);});});})[_0x5170b4('0x38')](function(){const _0x3aa920=_0x5170b4;return new Promise(function(_0x4b67be,_0x2a68f1){zipdir(_0x4a3ca4,{'saveTo':_0x44ddc2},function(_0x24c379,_0x385b4c){if(_0x24c379)return _0x2a68f1(_0x24c379);return _0x4b67be(_0x385b4c);});})[_0x3aa920('0x38')](function(){return new Promise(function(_0x43d6a3,_0x4d3c68){rimraf(_0x4a3ca4,function(_0x3fc1f0){if(_0x3fc1f0)_0x4d3c68(_0x3fc1f0);return _0x43d6a3();});});})[_0x3aa920('0x38')](function(){const _0xfc99cf=_0x3aa920;return _0xa1e130[_0xfc99cf('0x4c')](_0x44ddc2,_0x5259ab,function(_0x595327){const _0x17dd9d=_0xfc99cf;_0x595327?console[_0x17dd9d('0x90')](_0x17dd9d('0x2c'),_0x595327):fs[_0x17dd9d('0x46')](_0x44ddc2);});});});}else return _0xa1e130[_0x5170b4('0xc5')](0xc8);})[_0x387d33('0xd5')](handleError(_0xa1e130,null));}; \ No newline at end of file diff --git a/server/api/whatsappInteraction/whatsappInteraction.events.js b/server/api/whatsappInteraction/whatsappInteraction.events.js index d19a95e..2bdacae 100644 --- a/server/api/whatsappInteraction/whatsappInteraction.events.js +++ b/server/api/whatsappInteraction/whatsappInteraction.events.js @@ -1 +1 @@ -const a795_0x2db1=['exports','length','setDataValue','Users','emit','remove','addHook','catch','setMaxListeners','findAll','getUsers','../../mysqldb','then','WhatsappInteraction'];(function(_0x54190d,_0x2db1f7){const _0x2e72f5=function(_0x328472){while(--_0x328472){_0x54190d['push'](_0x54190d['shift']());}};_0x2e72f5(++_0x2db1f7);}(a795_0x2db1,0xac));const a795_0x2e72=function(_0x54190d,_0x2db1f7){_0x54190d=_0x54190d-0x0;let _0x2e72f5=a795_0x2db1[_0x54190d];return _0x2e72f5;};const _0x4739f8=a795_0x2e72;'use strict';const EventEmitter=require('events'),WhatsappInteraction=require(_0x4739f8('0x7'))['db'][_0x4739f8('0x9')],WhatsappMessage=require('../../mysqldb')['db']['WhatsappMessage'],WhatsappInteractionEvents=new EventEmitter();WhatsappInteractionEvents[_0x4739f8('0x4')](0x0);const events={'afterCreate':'save','afterUpdate':'update','afterDestroy':_0x4739f8('0x1')};function emitEvent(_0x328472){return function(_0x3012e4){const _0x4e259f=a795_0x2e72;_0x3012e4[_0x4e259f('0x6')]({'attributes':['id'],'raw':!![]})[_0x4e259f('0x8')](function(_0x518f74){const _0x1bcf13=_0x4e259f;return _0x3012e4[_0x1bcf13('0xc')](_0x1bcf13('0xd'),_0x518f74['map'](function(_0x35444c){return{'id':_0x35444c['id']};})),WhatsappMessage[_0x1bcf13('0x5')]({'where':{'WhatsappInteractionId':_0x3012e4['id'],'direction':'in','read':![]},'raw':!![]});})[_0x4e259f('0x8')](function(_0x149db2){const _0x4213b5=_0x4e259f;_0x3012e4[_0x4213b5('0xc')]('unreadMessages',_0x149db2[_0x4213b5('0xb')]),WhatsappInteractionEvents[_0x4213b5('0x0')](_0x328472+':'+_0x3012e4['id'],_0x3012e4),WhatsappInteractionEvents[_0x4213b5('0x0')](_0x328472,_0x3012e4);})[_0x4e259f('0x3')](()=>{});};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];WhatsappInteraction[_0x4739f8('0x2')](e,emitEvent(event));}}module[_0x4739f8('0xa')]=WhatsappInteractionEvents; \ No newline at end of file +const a795_0x2a84=['WhatsappInteraction','emit','setMaxListeners','unreadMessages','save','getUsers','Users','then','remove','undefined','exports','findAll','setDataValue','WhatsappMessage','length','map','catch','addHook'];(function(_0x1c48da,_0x2a84d4){const _0xefca90=function(_0x4a149a){while(--_0x4a149a){_0x1c48da['push'](_0x1c48da['shift']());}};_0xefca90(++_0x2a84d4);}(a795_0x2a84,0xec));const a795_0xefca=function(_0x1c48da,_0x2a84d4){_0x1c48da=_0x1c48da-0x0;let _0xefca90=a795_0x2a84[_0x1c48da];return _0xefca90;};const _0x15ea5d=a795_0xefca;'use strict';const EventEmitter=require('events'),WhatsappInteraction=require('../../mysqldb')['db'][_0x15ea5d('0x10')],WhatsappMessage=require('../../mysqldb')['db'][_0x15ea5d('0xb')],WhatsappInteractionEvents=new EventEmitter();WhatsappInteractionEvents[_0x15ea5d('0x0')](0x0);const events={'afterCreate':_0x15ea5d('0x2'),'afterUpdate':'update','afterDestroy':_0x15ea5d('0x6')};function emitEvent(_0x4a149a){return function(_0x416e30){const _0x3e7f43=a795_0xefca;_0x416e30[_0x3e7f43('0x3')]({'attributes':['id'],'raw':!![]})[_0x3e7f43('0x5')](function(_0x1d43fb){const _0x572ef8=_0x3e7f43;return _0x416e30[_0x572ef8('0xa')](_0x572ef8('0x4'),_0x1d43fb[_0x572ef8('0xd')](function(_0x3c152d){return{'id':_0x3c152d['id']};})),WhatsappMessage[_0x572ef8('0x9')]({'where':{'WhatsappInteractionId':_0x416e30['id'],'direction':'in','read':![]},'raw':!![]});})[_0x3e7f43('0x5')](function(_0x144951){const _0x47c52d=_0x3e7f43;_0x416e30[_0x47c52d('0xa')](_0x47c52d('0x1'),_0x144951[_0x47c52d('0xc')]),WhatsappInteractionEvents[_0x47c52d('0x11')](_0x4a149a+':'+_0x416e30['id'],_0x416e30),WhatsappInteractionEvents['emit'](_0x4a149a,_0x416e30);})[_0x3e7f43('0xe')](()=>{});};}for(const e in events){if(typeof events[e]!==_0x15ea5d('0x7')){const event=events[e];WhatsappInteraction[_0x15ea5d('0xf')](e,emitEvent(event));}}module[_0x15ea5d('0x8')]=WhatsappInteractionEvents; \ No newline at end of file diff --git a/server/api/whatsappInteraction/whatsappInteraction.model.js b/server/api/whatsappInteraction/whatsappInteraction.model.js index 94e6151..a440897 100644 --- a/server/api/whatsappInteraction/whatsappInteraction.model.js +++ b/server/api/whatsappInteraction/whatsappInteraction.model.js @@ -1 +1 @@ -const a796_0x3fc4=['YYYY-MM-DD\x20HH:mm:ss','changed','./whatsappInteraction.attributes','closed','moment','exports','format'];(function(_0x393249,_0x3fc4e6){const _0x2dff7d=function(_0x3ef61f){while(--_0x3ef61f){_0x393249['push'](_0x393249['shift']());}};_0x2dff7d(++_0x3fc4e6);}(a796_0x3fc4,0x155));const a796_0x2dff=function(_0x393249,_0x3fc4e6){_0x393249=_0x393249-0x0;let _0x2dff7d=a796_0x3fc4[_0x393249];return _0x2dff7d;};const _0x2946a8=a796_0x2dff;'use strict';const moment=require(_0x2946a8('0x6')),attributes=require(_0x2946a8('0x4'));module[_0x2946a8('0x0')]=function(_0x3ef61f){const _0x2b6e7d=_0x3ef61f['define']('WhatsappInteraction',attributes,{'tableName':'whatsapp_interactions','paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x4ac74b){const _0x343835=a796_0x2dff;_0x4ac74b[_0x343835('0x3')](_0x343835('0x5'))&&(_0x4ac74b['closedAt']=moment()[_0x343835('0x1')](_0x343835('0x2')));}}});return _0x2b6e7d;}; \ No newline at end of file +const a796_0x3d87=['changed','closedAt','format','whatsapp_interactions','define','closed','moment','./whatsappInteraction.attributes','WhatsappInteraction','exports'];(function(_0x488a98,_0x3d872a){const _0x5aa677=function(_0x30299b){while(--_0x30299b){_0x488a98['push'](_0x488a98['shift']());}};_0x5aa677(++_0x3d872a);}(a796_0x3d87,0x190));const a796_0x5aa6=function(_0x488a98,_0x3d872a){_0x488a98=_0x488a98-0x0;let _0x5aa677=a796_0x3d87[_0x488a98];return _0x5aa677;};const _0x22745d=a796_0x5aa6;'use strict';const moment=require(_0x22745d('0x6')),attributes=require(_0x22745d('0x7'));module[_0x22745d('0x9')]=function(_0x30299b){const _0x40a0d3=_0x22745d,_0x1494b0=_0x30299b[_0x40a0d3('0x4')](_0x40a0d3('0x8'),attributes,{'tableName':_0x40a0d3('0x3'),'paranoid':![],'indexes':[],'timestamps':!![],'hooks':{'beforeUpdate':function(_0x472367){const _0x522f8a=_0x40a0d3;_0x472367[_0x522f8a('0x0')](_0x522f8a('0x5'))&&(_0x472367[_0x522f8a('0x1')]=moment()[_0x522f8a('0x2')]('YYYY-MM-DD\x20HH:mm:ss'));}}});return _0x1494b0;}; \ No newline at end of file diff --git a/server/api/whatsappInteraction/whatsappInteraction.rpc.js b/server/api/whatsappInteraction/whatsappInteraction.rpc.js index 05b3be8..45976bf 100644 --- a/server/api/whatsappInteraction/whatsappInteraction.rpc.js +++ b/server/api/whatsappInteraction/whatsappInteraction.rpc.js @@ -1 +1 @@ -const a797_0x2e16=['../../mysqldb','stringify','ids','UpdateWhatsappInteraction','../../config/logger','message','rpc','addTags','WhatsappInteraction','../../rediscache','options','error','debug','then','info','where','body','omit','limit','catch','findOne','AddTags','register','update','raw'];(function(_0x4d4f0b,_0x2e1688){const _0x17f03f=function(_0x5288fe){while(--_0x5288fe){_0x4d4f0b['push'](_0x4d4f0b['shift']());}};_0x17f03f(++_0x2e1688);}(a797_0x2e16,0x172));const a797_0x17f0=function(_0x4d4f0b,_0x2e1688){_0x4d4f0b=_0x4d4f0b-0x0;let _0x17f03f=a797_0x2e16[_0x4d4f0b];return _0x17f03f;};const _0x35aef6=a797_0x17f0;'use strict';const _=require('lodash'),db=require(_0x35aef6('0x5'))['db'],logger=require(_0x35aef6('0x9'))(_0x35aef6('0xb')),{getSocket}=require(_0x35aef6('0xe')),socket=getSocket();require('./whatsappInteraction.socket')[_0x35aef6('0x2')](socket),exports[_0x35aef6('0x8')]=function(_0x5288fe){const _0x15fdcb=this;return new Promise(function(_0x818d2c,_0x533ac8){const _0x31cd8c=a797_0x17f0;return db[_0x31cd8c('0xd')][_0x31cd8c('0x3')](_0x5288fe[_0x31cd8c('0x15')],{'raw':_0x5288fe['options']?_0x5288fe['options'][_0x31cd8c('0x4')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x5288fe[_0x31cd8c('0xf')]?_0x5288fe[_0x31cd8c('0xf')]['where']||null:null,'attributes':_0x5288fe[_0x31cd8c('0xf')]?_0x5288fe[_0x31cd8c('0xf')]['attributes']||null:null,'limit':_0x5288fe[_0x31cd8c('0xf')]?_0x5288fe[_0x31cd8c('0xf')][_0x31cd8c('0x17')]||null:null})[_0x31cd8c('0x12')](function(_0x2b572e){const _0x501883=_0x31cd8c;logger[_0x501883('0x13')]('UpdateWhatsappInteraction',_0x5288fe),logger[_0x501883('0x11')]('UpdateWhatsappInteraction',_0x5288fe,JSON['stringify'](_0x2b572e)),_0x818d2c(_0x2b572e);})['catch'](function(_0x26cd7f){const _0x1b9c66=_0x31cd8c;logger[_0x1b9c66('0x10')](_0x1b9c66('0x8'),_0x26cd7f[_0x1b9c66('0xa')],_0x5288fe),_0x533ac8(_0x15fdcb[_0x1b9c66('0x10')](0x1f4,_0x26cd7f[_0x1b9c66('0xa')]));});});},exports['AddTagsToWhatsappInteraction']=function(_0x11ba15){const _0x104630=this;return new Promise(function(_0x203b62,_0x53626d){const _0x46ecb9=a797_0x17f0;return db[_0x46ecb9('0xd')][_0x46ecb9('0x0')]({'where':_0x11ba15[_0x46ecb9('0xf')]?_0x11ba15[_0x46ecb9('0xf')][_0x46ecb9('0x14')]||null:null})['then'](function(_0x2f599b){const _0x3bc4e9=_0x46ecb9;if(_0x2f599b)return _0x2f599b[_0x3bc4e9('0xc')](_0x11ba15[_0x3bc4e9('0x15')][_0x3bc4e9('0x7')],{'through':_[_0x3bc4e9('0x16')](_0x11ba15[_0x3bc4e9('0x15')],['ids','id'])});})[_0x46ecb9('0x12')](function([_0x2c418c]){const _0x51ee8a=_0x46ecb9;logger[_0x51ee8a('0x13')](_0x51ee8a('0x1'),_0x11ba15),logger['debug'](_0x51ee8a('0x1'),_0x11ba15,JSON[_0x51ee8a('0x6')](_0x2c418c)),_0x203b62(_0x2c418c);})[_0x46ecb9('0x18')](function(_0x23af4d){const _0x1ea85b=_0x46ecb9;logger[_0x1ea85b('0x10')](_0x1ea85b('0x1'),_0x23af4d[_0x1ea85b('0xa')],_0x11ba15),_0x53626d(_0x104630['error'](0x1f4,_0x23af4d[_0x1ea85b('0xa')]));});});}; \ No newline at end of file +const a797_0x2763=['UpdateWhatsappInteraction','then','message','WhatsappInteraction','ids','lodash','error','info','../../rediscache','catch','stringify','omit','AddTagsToWhatsappInteraction','addTags','where','../../config/logger','options','../../mysqldb','raw','body','debug','AddTags','./whatsappInteraction.socket','rpc','limit','findOne','update'];(function(_0x234209,_0x276361){const _0x284538=function(_0x116037){while(--_0x116037){_0x234209['push'](_0x234209['shift']());}};_0x284538(++_0x276361);}(a797_0x2763,0x1b6));const a797_0x2845=function(_0x234209,_0x276361){_0x234209=_0x234209-0x0;let _0x284538=a797_0x2763[_0x234209];return _0x284538;};const _0x45aee1=a797_0x2845;'use strict';const _=require(_0x45aee1('0x1a')),db=require(_0x45aee1('0xb'))['db'],logger=require(_0x45aee1('0x9'))(_0x45aee1('0x11')),{getSocket}=require(_0x45aee1('0x2')),socket=getSocket();require(_0x45aee1('0x10'))['register'](socket),exports['UpdateWhatsappInteraction']=function(_0x116037){const _0x413ea0=this;return new Promise(function(_0xb07ee1,_0x1833e5){const _0x9b5db7=a797_0x2845;return db[_0x9b5db7('0x18')][_0x9b5db7('0x14')](_0x116037['body'],{'raw':_0x116037[_0x9b5db7('0xa')]?_0x116037[_0x9b5db7('0xa')][_0x9b5db7('0xc')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x116037['options']?_0x116037[_0x9b5db7('0xa')][_0x9b5db7('0x8')]||null:null,'attributes':_0x116037[_0x9b5db7('0xa')]?_0x116037[_0x9b5db7('0xa')]['attributes']||null:null,'limit':_0x116037[_0x9b5db7('0xa')]?_0x116037[_0x9b5db7('0xa')][_0x9b5db7('0x12')]||null:null})[_0x9b5db7('0x16')](function(_0x59e06b){const _0x41176e=_0x9b5db7;logger[_0x41176e('0x1')](_0x41176e('0x15'),_0x116037),logger[_0x41176e('0xe')]('UpdateWhatsappInteraction',_0x116037,JSON[_0x41176e('0x4')](_0x59e06b)),_0xb07ee1(_0x59e06b);})[_0x9b5db7('0x3')](function(_0x1024a9){const _0xbee17b=_0x9b5db7;logger['error'](_0xbee17b('0x15'),_0x1024a9[_0xbee17b('0x17')],_0x116037),_0x1833e5(_0x413ea0['error'](0x1f4,_0x1024a9[_0xbee17b('0x17')]));});});},exports[_0x45aee1('0x6')]=function(_0x48dd37){const _0x3daf8f=this;return new Promise(function(_0x8f5f08,_0x53593d){const _0x175a21=a797_0x2845;return db[_0x175a21('0x18')][_0x175a21('0x13')]({'where':_0x48dd37[_0x175a21('0xa')]?_0x48dd37[_0x175a21('0xa')]['where']||null:null})[_0x175a21('0x16')](function(_0x145611){const _0x277846=_0x175a21;if(_0x145611)return _0x145611[_0x277846('0x7')](_0x48dd37[_0x277846('0xd')][_0x277846('0x19')],{'through':_[_0x277846('0x5')](_0x48dd37['body'],[_0x277846('0x19'),'id'])});})['then'](function([_0x41caad]){const _0x4c9e2b=_0x175a21;logger[_0x4c9e2b('0x1')](_0x4c9e2b('0xf'),_0x48dd37),logger['debug'](_0x4c9e2b('0xf'),_0x48dd37,JSON[_0x4c9e2b('0x4')](_0x41caad)),_0x8f5f08(_0x41caad);})['catch'](function(_0x29ab5e){const _0x4aebdb=_0x175a21;logger['error']('AddTags',_0x29ab5e[_0x4aebdb('0x17')],_0x48dd37),_0x53593d(_0x3daf8f[_0x4aebdb('0x0')](0x1f4,_0x29ab5e[_0x4aebdb('0x17')]));});});}; \ No newline at end of file diff --git a/server/api/whatsappInteraction/whatsappInteraction.socket.js b/server/api/whatsappInteraction/whatsappInteraction.socket.js index e76069b..bf9850e 100644 --- a/server/api/whatsappInteraction/whatsappInteraction.socket.js +++ b/server/api/whatsappInteraction/whatsappInteraction.socket.js @@ -1 +1 @@ -const a798_0x4f67=['length','register','emit'];(function(_0x40a723,_0x4f6764){const _0x4232ca=function(_0x515689){while(--_0x515689){_0x40a723['push'](_0x40a723['shift']());}};_0x4232ca(++_0x4f6764);}(a798_0x4f67,0x19f));const a798_0x4232=function(_0x40a723,_0x4f6764){_0x40a723=_0x40a723-0x0;let _0x4232ca=a798_0x4f67[_0x40a723];return _0x4232ca;};const _0x5a283b=a798_0x4232;'use strict';const WhatsappInteractionEvents=require('./whatsappInteraction.events'),events=['save','remove','update'];function createListener(_0x515689,_0x53b6cc){return function(_0x4881aa){const _0x510b5a=a798_0x4232;_0x53b6cc[_0x510b5a('0x1')](_0x515689,_0x4881aa);};}exports[_0x5a283b('0x0')]=function(_0x579fbd){const _0x51d467=_0x5a283b;for(let _0x34c7a5=0x0,_0x58e8ae=events[_0x51d467('0x2')];_0x34c7a5<_0x58e8ae;_0x34c7a5++){const _0x59ae41=events[_0x34c7a5],_0x4dc9a6=createListener('whatsappInteraction:'+_0x59ae41,_0x579fbd);WhatsappInteractionEvents['on'](_0x59ae41,_0x4dc9a6);}}; \ No newline at end of file +const a798_0x3022=['whatsappInteraction:','update','save','./whatsappInteraction.events','length','register'];(function(_0x5db3bf,_0x302237){const _0x385b4b=function(_0x468246){while(--_0x468246){_0x5db3bf['push'](_0x5db3bf['shift']());}};_0x385b4b(++_0x302237);}(a798_0x3022,0x90));const a798_0x385b=function(_0x5db3bf,_0x302237){_0x5db3bf=_0x5db3bf-0x0;let _0x385b4b=a798_0x3022[_0x5db3bf];return _0x385b4b;};const _0x131fb8=a798_0x385b;'use strict';const WhatsappInteractionEvents=require(_0x131fb8('0x3')),events=[_0x131fb8('0x2'),'remove',_0x131fb8('0x1')];function createListener(_0x468246,_0x24d49a){return function(_0x3dcacc){_0x24d49a['emit'](_0x468246,_0x3dcacc);};}exports[_0x131fb8('0x5')]=function(_0x13c7cd){const _0x1f52a9=_0x131fb8;for(let _0x5b8996=0x0,_0x3873b7=events[_0x1f52a9('0x4')];_0x5b8996<_0x3873b7;_0x5b8996++){const _0x3c1174=events[_0x5b8996],_0x247386=createListener(_0x1f52a9('0x0')+_0x3c1174,_0x13c7cd);WhatsappInteractionEvents['on'](_0x3c1174,_0x247386);}}; \ No newline at end of file diff --git a/server/api/whatsappMessage/index.js b/server/api/whatsappMessage/index.js index e0f2aa6..cc774fd 100644 --- a/server/api/whatsappMessage/index.js +++ b/server/api/whatsappMessage/index.js @@ -1 +1 @@ -const a799_0x576a=['show','tracked','isAuthenticated','../../components/auth/service','/:id/accept','post','./whatsappMessage.controller','reject','status','/:id/reject','/:id','express','destroy','put','/describe','update','get','whatsapp','describe','whatsappmessage:create','exports','Router'];(function(_0x293186,_0x576a06){const _0x13d21a=function(_0xa60a58){while(--_0xa60a58){_0x293186['push'](_0x293186['shift']());}};_0x13d21a(++_0x576a06);}(a799_0x576a,0x16d));const a799_0x13d2=function(_0x293186,_0x576a06){_0x293186=_0x293186-0x0;let _0x13d21a=a799_0x576a[_0x293186];return _0x13d21a;};const _0x4d9ea2=a799_0x13d2;'use strict';const express=require(_0x4d9ea2('0x14')),router=express[_0x4d9ea2('0x8')](),auth=require(_0x4d9ea2('0xc')),interaction=require('../../components/interaction/service'),controller=require(_0x4d9ea2('0xf'));router[_0x4d9ea2('0x3')]('/',auth[_0x4d9ea2('0xb')](),controller['index']),router[_0x4d9ea2('0x3')](_0x4d9ea2('0x1'),auth['isAuthenticated'](),controller[_0x4d9ea2('0x5')]),router['get'](_0x4d9ea2('0x13'),auth[_0x4d9ea2('0xb')](),controller[_0x4d9ea2('0x9')]),router[_0x4d9ea2('0xe')]('/',auth[_0x4d9ea2('0xb')](),interaction[_0x4d9ea2('0xa')](_0x4d9ea2('0x4'),_0x4d9ea2('0x6')),controller['create']),router['post']('/:id/status',controller[_0x4d9ea2('0x11')]),router[_0x4d9ea2('0x0')](_0x4d9ea2('0x13'),auth[_0x4d9ea2('0xb')](),controller[_0x4d9ea2('0x2')]),router[_0x4d9ea2('0x0')](_0x4d9ea2('0xd'),auth['isAuthenticated'](),controller['accept']),router[_0x4d9ea2('0x0')](_0x4d9ea2('0x12'),auth['isAuthenticated'](),controller[_0x4d9ea2('0x10')]),router['delete']('/:id',auth[_0x4d9ea2('0xb')](),controller[_0x4d9ea2('0x15')]),module[_0x4d9ea2('0x7')]=router; \ No newline at end of file +const a799_0x5840=['/:id/accept','delete','/:id/reject','tracked','index','get','/:id','update','Router','/:id/status','status','post','describe','isAuthenticated','create','../../components/auth/service','destroy','./whatsappMessage.controller','accept','/describe'];(function(_0x23f0bb,_0x5840d6){const _0x4ce668=function(_0x52a944){while(--_0x52a944){_0x23f0bb['push'](_0x23f0bb['shift']());}};_0x4ce668(++_0x5840d6);}(a799_0x5840,0x145));const a799_0x4ce6=function(_0x23f0bb,_0x5840d6){_0x23f0bb=_0x23f0bb-0x0;let _0x4ce668=a799_0x5840[_0x23f0bb];return _0x4ce668;};const _0x736a0e=a799_0x4ce6;'use strict';const express=require('express'),router=express[_0x736a0e('0x3')](),auth=require(_0x736a0e('0xa')),interaction=require('../../components/interaction/service'),controller=require(_0x736a0e('0xc'));router['get']('/',auth[_0x736a0e('0x8')](),controller[_0x736a0e('0x13')]),router[_0x736a0e('0x0')](_0x736a0e('0xe'),auth['isAuthenticated'](),controller[_0x736a0e('0x7')]),router['get'](_0x736a0e('0x1'),auth[_0x736a0e('0x8')](),controller['show']),router[_0x736a0e('0x6')]('/',auth[_0x736a0e('0x8')](),interaction[_0x736a0e('0x12')]('whatsapp','whatsappmessage:create'),controller[_0x736a0e('0x9')]),router['post'](_0x736a0e('0x4'),controller[_0x736a0e('0x5')]),router['put'](_0x736a0e('0x1'),auth[_0x736a0e('0x8')](),controller[_0x736a0e('0x2')]),router['put'](_0x736a0e('0xf'),auth[_0x736a0e('0x8')](),controller[_0x736a0e('0xd')]),router['put'](_0x736a0e('0x11'),auth[_0x736a0e('0x8')](),controller['reject']),router[_0x736a0e('0x10')]('/:id',auth[_0x736a0e('0x8')](),controller[_0x736a0e('0xb')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/whatsappMessage/whatsappMessage.attributes.js b/server/api/whatsappMessage/whatsappMessage.attributes.js index cea265a..7eaa41a 100644 --- a/server/api/whatsappMessage/whatsappMessage.attributes.js +++ b/server/api/whatsappMessage/whatsappMessage.attributes.js @@ -1 +1 @@ -const a800_0x1166=['exports','TEXT','BOOLEAN','sequelize','DATE','ENUM','medium','STRING','out'];(function(_0x5fb307,_0x1166a9){const _0x2fdfa3=function(_0x27f51b){while(--_0x27f51b){_0x5fb307['push'](_0x5fb307['shift']());}};_0x2fdfa3(++_0x1166a9);}(a800_0x1166,0xcc));const a800_0x2fdf=function(_0x5fb307,_0x1166a9){_0x5fb307=_0x5fb307-0x0;let _0x2fdfa3=a800_0x1166[_0x5fb307];return _0x2fdfa3;};const _0x46e7b9=a800_0x2fdf;'use strict';const Sequelize=require(_0x46e7b9('0x6'));module[_0x46e7b9('0x3')]={'body':{'type':Sequelize[_0x46e7b9('0x4')](_0x46e7b9('0x0')),'allowNull':![]},'read':{'type':Sequelize[_0x46e7b9('0x5')],'defaultValue':![]},'direction':{'type':Sequelize[_0x46e7b9('0x8')]('in','out'),'defaultValue':_0x46e7b9('0x2'),'allowNull':![]},'messageId':{'type':Sequelize[_0x46e7b9('0x1')](0xbe)},'phone':{'type':Sequelize['STRING']},'readAt':{'type':Sequelize[_0x46e7b9('0x7')]},'secret':{'type':Sequelize[_0x46e7b9('0x5')],'defaultValue':![]},'providerName':{'type':Sequelize[_0x46e7b9('0x1')]},'providerResponse':{'type':Sequelize['TEXT']}}; \ No newline at end of file +const a800_0xe157=['ENUM','out','TEXT','exports','sequelize','DATE','BOOLEAN','STRING','medium'];(function(_0xa8a036,_0xe15711){const _0x305816=function(_0x1b5a55){while(--_0x1b5a55){_0xa8a036['push'](_0xa8a036['shift']());}};_0x305816(++_0xe15711);}(a800_0xe157,0x1d4));const a800_0x3058=function(_0xa8a036,_0xe15711){_0xa8a036=_0xa8a036-0x0;let _0x305816=a800_0xe157[_0xa8a036];return _0x305816;};const _0x19ddbd=a800_0x3058;'use strict';const Sequelize=require(_0x19ddbd('0x4'));module[_0x19ddbd('0x3')]={'body':{'type':Sequelize[_0x19ddbd('0x2')](_0x19ddbd('0x8')),'allowNull':![]},'read':{'type':Sequelize[_0x19ddbd('0x6')],'defaultValue':![]},'direction':{'type':Sequelize[_0x19ddbd('0x0')]('in',_0x19ddbd('0x1')),'defaultValue':'out','allowNull':![]},'messageId':{'type':Sequelize['STRING'](0xbe)},'phone':{'type':Sequelize[_0x19ddbd('0x7')]},'readAt':{'type':Sequelize[_0x19ddbd('0x5')]},'secret':{'type':Sequelize['BOOLEAN'],'defaultValue':![]},'providerName':{'type':Sequelize[_0x19ddbd('0x7')]},'providerResponse':{'type':Sequelize[_0x19ddbd('0x2')]}}; \ No newline at end of file diff --git a/server/api/whatsappMessage/whatsappMessage.controller.js b/server/api/whatsappMessage/whatsappMessage.controller.js index 178f0df..c3992db 100644 --- a/server/api/whatsappMessage/whatsappMessage.controller.js +++ b/server/api/whatsappMessage/whatsappMessage.controller.js @@ -1 +1 @@ -const a801_0x1b34=['order','WhatsappMessage','stack','WhatsappMessage,\x20%s,\x20%s,\x20%s','request','http','sendStatus','read','status','../../rediscache','limit','show','destroy','name','role','null','lodash','YYYY-MM-DD\x20HH:mm:ss','UserId','filters','then','accept','reject','AcceptMessage','offset','intersection','type','map','keys','message','channel','interaction','length','util','WhatsappMessage,\x20%s,\x20%s','CmContact','body','json','acceptMessage','count','filter','create','includeAll','catch','Content-Range','agent','inspect','rows','../../config/logger','fields','twilio','send','info','like','EventManager','result','read1stAt','rawAttributes','Contact','manual','WhatsappInteraction','client','model','acceptmessage','update','WhatsappAccountId','sort','jayson/promise','MessageStatus','messageId','SIP/%s','format','stringify','findOne','readAt','user','rejectmessage','describe','params','attributes','MessageSid','debug','../../mysqldb','whatsapp-interactions','merge','get','include','set','received\x20delivery\x20report\x20from','moment','WhatsappAccount,\x20%s,\x20%s,\x20%s','WhatsappAccount','[WHATSAPPMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','undefined','options','error','fieldName','query','WhatsappInteractionId','key'];(function(_0xd6e2ce,_0x1b348a){const _0x525e07=function(_0x586a92){while(--_0x586a92){_0xd6e2ce['push'](_0xd6e2ce['shift']());}};_0x525e07(++_0x1b348a);}(a801_0x1b34,0x191));const a801_0x525e=function(_0xd6e2ce,_0x1b348a){_0xd6e2ce=_0xd6e2ce-0x0;let _0x525e07=a801_0x1b34[_0xd6e2ce];return _0x525e07;};const _0x48753d=a801_0x525e;'use strict';const moment=require(_0x48753d('0x58')),util=require(_0x48753d('0x20')),_=require(_0x48753d('0xf')),qs=require('../../components/parsers/qs'),logger=require('../../config/logger')('api'),{getSocket}=require(_0x48753d('0x8')),socket=getSocket(),interaction_log=require(_0x48753d('0x2f'))(_0x48753d('0x52')),db=require(_0x48753d('0x51'))['db'],{Op}=require('sequelize');require('./whatsappMessage.socket')['register'](socket);const jayson=require(_0x48753d('0x42')),client=jayson[_0x48753d('0x3c')][_0x48753d('0x4')]({'port':0x232c}),client9002=jayson[_0x48753d('0x3c')][_0x48753d('0x4')]({'port':0x232a});function respondWithRpcPromise(_0x586a92,_0x2bd0bf,_0x1192a3,_0x1f6a7e){return new Promise(function(_0x1ec3d8,_0x4dfcf3){const _0x5ee5e0=a801_0x525e,_0x3af7d3=_0x1f6a7e||client;return _0x3af7d3[_0x5ee5e0('0x3')](_0x586a92,_0x1192a3)['then'](function(_0x2c6cd8){const _0x33df19=_0x5ee5e0;logger['info'](_0x33df19('0x21'),_0x2bd0bf,'request\x20sent'),logger[_0x33df19('0x50')](_0x33df19('0x2'),_0x2bd0bf,'request\x20sent',JSON[_0x33df19('0x47')](_0x2c6cd8));if(_0x2c6cd8[_0x33df19('0x5e')]){if(_0x2c6cd8[_0x33df19('0x5e')]['code']===0x1f4)return logger[_0x33df19('0x5e')](_0x33df19('0x21'),_0x2bd0bf,_0x2c6cd8['error'][_0x33df19('0x1c')]),_0x4dfcf3(_0x2c6cd8['error'][_0x33df19('0x1c')]);return logger[_0x33df19('0x5e')](_0x33df19('0x21'),_0x2bd0bf,_0x2c6cd8['error'][_0x33df19('0x1c')]),_0x1ec3d8(_0x2c6cd8[_0x33df19('0x5e')][_0x33df19('0x1c')]);}else logger[_0x33df19('0x33')]('WhatsappMessage,\x20%s,\x20%s',_0x2bd0bf,'request\x20sent'),_0x1ec3d8(_0x2c6cd8[_0x33df19('0x36')][_0x33df19('0x1c')]);})[_0x5ee5e0('0x2a')](function(_0xdcf92e){const _0x16647c=_0x5ee5e0;logger[_0x16647c('0x5e')](_0x16647c('0x21'),_0x2bd0bf,_0xdcf92e),_0x4dfcf3(_0xdcf92e);});});}function respondWithResult(_0x5e6c55,_0x5858e7){return _0x5858e7=_0x5858e7||0xc8,function(_0x12d725){const _0xa7abec=a801_0x525e;if(_0x12d725)return _0x5e6c55[_0xa7abec('0x7')](_0x5858e7)[_0xa7abec('0x24')](_0x12d725);};}function respondWithFilteredResult(_0x5b7209,_0x4fafcb){return function(_0x2309ca){const _0x260adc=a801_0x525e;if(_0x2309ca){const _0x558782=_0x2309ca['count'],_0x333a56=_0x4fafcb[_0x260adc('0x17')];let _0x2826a1=_0x4fafcb[_0x260adc('0x17')]+_0x4fafcb['limit'],_0x557820;return _0x2826a1>=_0x558782?(_0x2826a1=_0x558782,_0x557820=0xc8):_0x557820=0xce,_0x5b7209[_0x260adc('0x7')](_0x557820),_0x5b7209[_0x260adc('0x56')](_0x260adc('0x2b'),_0x333a56+'-'+_0x2826a1+'/'+_0x558782)['json'](_0x2309ca);}return null;};}function saveUpdates(_0x58137b){return function(_0x5d92c5){const _0x1273b2=a801_0x525e;if(_0x5d92c5)return _0x5d92c5[_0x1273b2('0x3f')](_0x58137b)[_0x1273b2('0x13')](function(_0x2e88ed){return _0x2e88ed;});return null;};}function removeEntity(_0x1eb5ad){return function(_0x276bd9){const _0x2152b4=a801_0x525e;if(_0x276bd9)return _0x276bd9['destroy']()[_0x2152b4('0x13')](function(){_0x1eb5ad['status'](0xcc)['end']();});};}function handleEntityNotFound(_0x3bfc6d){return function(_0x537f31){const _0x7b3b48=a801_0x525e;return!_0x537f31&&_0x3bfc6d[_0x7b3b48('0x5')](0x194),_0x537f31;};}function handleError(_0x428e6e,_0x345552){return _0x345552=_0x345552||0x1f4,function(_0x78524a){const _0x5d2e6f=a801_0x525e;logger['error'](_0x78524a[_0x5d2e6f('0x1')]),_0x78524a['name']&&delete _0x78524a[_0x5d2e6f('0xc')],_0x428e6e['status'](_0x345552)[_0x5d2e6f('0x32')](_0x78524a);};}exports['index']=function(_0x1eaf20,_0x54cac4){const _0x2ff465=_0x48753d;let _0x36b4ea={};const _0x3f6302={},_0x30d3ea={'count':0x0,'rows':[]},_0x59cfdc=_[_0x2ff465('0x1a')](db['WhatsappMessage'][_0x2ff465('0x38')],function(_0x33098d){const _0x3866f0=_0x2ff465;return{'name':_0x33098d[_0x3866f0('0x5f')],'type':_0x33098d['type'][_0x3866f0('0x62')]};});_0x3f6302['model']=_['map'](_0x59cfdc,_0x2ff465('0xc')),_0x3f6302[_0x2ff465('0x60')]=_[_0x2ff465('0x1b')](_0x1eaf20[_0x2ff465('0x60')]),_0x3f6302[_0x2ff465('0x12')]=_[_0x2ff465('0x18')](_0x3f6302['model'],_0x3f6302[_0x2ff465('0x60')]),_0x36b4ea[_0x2ff465('0x4e')]=_[_0x2ff465('0x18')](_0x3f6302[_0x2ff465('0x3d')],qs[_0x2ff465('0x30')](_0x1eaf20[_0x2ff465('0x60')][_0x2ff465('0x30')])),_0x36b4ea['attributes']=_0x36b4ea[_0x2ff465('0x4e')][_0x2ff465('0x1f')]?_0x36b4ea[_0x2ff465('0x4e')]:_0x3f6302[_0x2ff465('0x3d')];typeof _0x1eaf20[_0x2ff465('0x60')]['nolimit']===_0x2ff465('0x5c')&&(_0x36b4ea[_0x2ff465('0x9')]=qs[_0x2ff465('0x9')](_0x1eaf20['query'][_0x2ff465('0x9')]),_0x36b4ea[_0x2ff465('0x17')]=qs['offset'](_0x1eaf20['query'][_0x2ff465('0x17')]));_0x36b4ea[_0x2ff465('0x63')]=qs[_0x2ff465('0x41')](_0x1eaf20[_0x2ff465('0x60')][_0x2ff465('0x41')]),_0x36b4ea['where']=qs[_0x2ff465('0x12')](_['pick'](_0x1eaf20[_0x2ff465('0x60')],_0x3f6302[_0x2ff465('0x12')]),_0x59cfdc);_0x1eaf20['query']['filter']&&(_0x36b4ea['where']=_[_0x2ff465('0x53')](_0x36b4ea['where'],{[Op['or']]:_[_0x2ff465('0x1a')](_0x59cfdc,function(_0x57c7f3){const _0x1cf46f=_0x2ff465;if(_0x57c7f3[_0x1cf46f('0x19')]!=='VIRTUAL'){const _0x25d3eb={};return _0x25d3eb[_0x57c7f3[_0x1cf46f('0xc')]]={[Op[_0x1cf46f('0x34')]]:'%'+_0x1eaf20[_0x1cf46f('0x60')][_0x1cf46f('0x27')]+'%'},_0x25d3eb;}})}));_0x36b4ea=_[_0x2ff465('0x53')]({},_0x36b4ea,_0x1eaf20[_0x2ff465('0x5d')]);const _0x3cabce={'where':_0x36b4ea['where']};return db[_0x2ff465('0x0')]['count'](_0x3cabce)['then'](function(_0x3b9d39){const _0x546eab=_0x2ff465;return _0x30d3ea[_0x546eab('0x26')]=_0x3b9d39,_0x1eaf20[_0x546eab('0x60')][_0x546eab('0x29')]&&(_0x36b4ea['include']=[{'all':!![]}]),db[_0x546eab('0x0')]['findAll'](_0x36b4ea);})[_0x2ff465('0x13')](function(_0x345c8e){const _0x4aeec1=_0x2ff465;return _0x30d3ea[_0x4aeec1('0x2e')]=_0x345c8e,_0x30d3ea;})[_0x2ff465('0x13')](respondWithFilteredResult(_0x54cac4,_0x36b4ea))[_0x2ff465('0x2a')](handleError(_0x54cac4,null));},exports[_0x48753d('0xa')]=function(_0x2df1a0,_0x232991){const _0x574e67=_0x48753d;let _0x77aae1={'raw':!![],'where':{'id':_0x2df1a0[_0x574e67('0x4d')]['id']}};const _0x9a3211={};return _0x9a3211[_0x574e67('0x3d')]=_[_0x574e67('0x1b')](db[_0x574e67('0x0')][_0x574e67('0x38')]),_0x9a3211['query']=_[_0x574e67('0x1b')](_0x2df1a0[_0x574e67('0x60')]),_0x9a3211['filters']=_['intersection'](_0x9a3211[_0x574e67('0x3d')],_0x9a3211[_0x574e67('0x60')]),_0x77aae1[_0x574e67('0x4e')]=_[_0x574e67('0x18')](_0x9a3211[_0x574e67('0x3d')],qs['fields'](_0x2df1a0['query']['fields'])),_0x77aae1[_0x574e67('0x4e')]=_0x77aae1[_0x574e67('0x4e')][_0x574e67('0x1f')]?_0x77aae1[_0x574e67('0x4e')]:_0x9a3211['model'],_0x2df1a0[_0x574e67('0x60')]['includeAll']&&(_0x77aae1[_0x574e67('0x55')]=[{'all':!![]}]),_0x77aae1=_[_0x574e67('0x53')]({},_0x77aae1,_0x2df1a0[_0x574e67('0x5d')]),db['WhatsappMessage'][_0x574e67('0x48')](_0x77aae1)[_0x574e67('0x13')](handleEntityNotFound(_0x232991,null))[_0x574e67('0x13')](respondWithResult(_0x232991,null))[_0x574e67('0x2a')](handleError(_0x232991,null));},exports[_0x48753d('0x28')]=function(_0x362530,_0x2afd01){const _0x1c43c6=_0x48753d;return db[_0x1c43c6('0x0')][_0x1c43c6('0x28')](_0x362530[_0x1c43c6('0x23')],{})[_0x1c43c6('0x13')](respondWithResult(_0x2afd01,0xc9))[_0x1c43c6('0x2a')](handleError(_0x2afd01,null));},exports[_0x48753d('0x3f')]=function(_0x16d7ae,_0x4382c0){const _0x3b4efe=_0x48753d;return _0x16d7ae[_0x3b4efe('0x23')]['id']&&delete _0x16d7ae[_0x3b4efe('0x23')]['id'],db[_0x3b4efe('0x0')][_0x3b4efe('0x48')]({'where':{'id':_0x16d7ae['params']['id']}})[_0x3b4efe('0x13')](handleEntityNotFound(_0x4382c0,null))[_0x3b4efe('0x13')](saveUpdates(_0x16d7ae['body'],null))[_0x3b4efe('0x13')](respondWithResult(_0x4382c0,null))[_0x3b4efe('0x2a')](handleError(_0x4382c0,null));},exports[_0x48753d('0xb')]=function(_0x4bf81e,_0x4f793e){const _0x147c9f=_0x48753d;return db[_0x147c9f('0x0')][_0x147c9f('0x48')]({'where':{'id':_0x4bf81e[_0x147c9f('0x4d')]['id']}})[_0x147c9f('0x13')](handleEntityNotFound(_0x4f793e,null))[_0x147c9f('0x13')](removeEntity(_0x4f793e,null))[_0x147c9f('0x2a')](handleError(_0x4f793e,null));},exports[_0x48753d('0x4c')]=function(_0x5d0c58,_0x59b0f1){const _0xf062c6=_0x48753d;return db[_0xf062c6('0x0')][_0xf062c6('0x4c')]()[_0xf062c6('0x13')](respondWithResult(_0x59b0f1,null))['catch'](handleError(_0x59b0f1,null));},exports[_0x48753d('0x14')]=function(_0x51bff6,_0x2f9d13){const _0x1cd516=_0x48753d,_0x34f95b={'channel':'whatsapp'};return _0x51bff6['body']['id']&&delete _0x51bff6[_0x1cd516('0x23')]['id'],_0x51bff6[_0x1cd516('0x23')][_0x1cd516('0x6')]=!![],_0x51bff6['body'][_0x1cd516('0x49')]=moment()[_0x1cd516('0x46')](_0x1cd516('0x10')),_0x51bff6[_0x1cd516('0x23')][_0x1cd516('0x11')]=_0x51bff6['body']['UserId']||_0x51bff6['user']['id'],db[_0x1cd516('0x0')][_0x1cd516('0x48')]({'where':{'id':_0x51bff6[_0x1cd516('0x4d')]['id'],'UserId':null},'include':[{'model':db[_0x1cd516('0x22')],'as':_0x1cd516('0x39')}]})['then'](handleEntityNotFound(_0x2f9d13,null))[_0x1cd516('0x13')](saveUpdates(_0x51bff6[_0x1cd516('0x23')],null))[_0x1cd516('0x13')](function(_0x92639f){const _0x556e81=_0x1cd516;if(_0x92639f)return _0x34f95b[_0x556e81('0x1c')]=_0x92639f[_0x556e81('0x54')]({'plain':!![]}),db['WhatsappInteraction'][_0x556e81('0x48')]({'where':{'id':_0x92639f[_0x556e81('0x61')]}});return null;})[_0x1cd516('0x13')](handleEntityNotFound(_0x2f9d13,null))[_0x1cd516('0x13')](function(_0x50b963){const _0x161224=_0x1cd516;if(_0x50b963)return _0x50b963[_0x161224('0x3f')]({'UserId':_0x51bff6['body'][_0x161224('0x11')],'read1stAt':_['isNil'](_0x50b963[_0x161224('0x37')])?moment()['format'](_0x161224('0x10')):undefined});return null;})['then'](function(_0x5c69da){const _0x297fd9=_0x1cd516;if(_0x5c69da)return _0x34f95b[_0x297fd9('0x1e')]=_0x5c69da[_0x297fd9('0x54')]({'plain':!![]}),interaction_log[_0x297fd9('0x33')]('[WHATSAPPMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s',_0x51bff6[_0x297fd9('0x4a')]['id'],_0x51bff6['user']['name'],_0x51bff6[_0x297fd9('0x4a')][_0x297fd9('0xd')],_0x34f95b[_0x297fd9('0x1e')]['id'],_0x51bff6[_0x297fd9('0x23')]?JSON[_0x297fd9('0x47')](_0x51bff6[_0x297fd9('0x23')]):_0x297fd9('0xe')),respondWithRpcPromise(_0x297fd9('0x16'),_0x297fd9('0x25'),_0x34f95b);return null;})[_0x1cd516('0x13')](function(_0x3d1bea){const _0x5b7ca8=_0x1cd516;if(_0x3d1bea){if(_0x51bff6['body'][_0x5b7ca8('0x3a')])return _0x34f95b[_0x5b7ca8('0x1c')]['interface']=util[_0x5b7ca8('0x46')](_0x5b7ca8('0x45'),_0x51bff6['user'][_0x5b7ca8('0xc')]),_0x34f95b['message']['channel']=_0x34f95b[_0x5b7ca8('0x1d')],_0x34f95b[_0x5b7ca8('0x1c')]['event']=_0x5b7ca8('0x14'),respondWithRpcPromise('EventManager',_0x5b7ca8('0x35'),{'event':_0x5b7ca8('0x3e'),'message':_0x34f95b[_0x5b7ca8('0x1c')]},client9002)[_0x5b7ca8('0x13')](function(){return _0x34f95b;});return _0x34f95b;}return null;})[_0x1cd516('0x13')](respondWithResult(_0x2f9d13,null))[_0x1cd516('0x2a')](handleError(_0x2f9d13,null));},exports[_0x48753d('0x15')]=function(_0x50218f,_0x944139){const _0x5e098f=_0x48753d,_0x50703c={'agent':{},'channel':'whatsapp'};return _0x50218f[_0x5e098f('0x23')]['id']&&delete _0x50218f['body']['id'],_0x50218f[_0x5e098f('0x23')]['UserId']=_0x50218f['body'][_0x5e098f('0x11')]||_0x50218f[_0x5e098f('0x4a')]['id'],_0x50703c[_0x5e098f('0x2c')]['id']=_0x50218f[_0x5e098f('0x23')][_0x5e098f('0x11')],db['WhatsappMessage'][_0x5e098f('0x48')]({'where':{'id':_0x50218f['params']['id'],'UserId':null}})[_0x5e098f('0x13')](handleEntityNotFound(_0x944139,null))[_0x5e098f('0x13')](function(_0x30b83e){const _0x1c097c=_0x5e098f;if(_0x30b83e)return _0x50703c['message']=_0x30b83e[_0x1c097c('0x54')]({'plain':!![]}),db[_0x1c097c('0x3b')]['findOne']({'where':{'id':_0x30b83e['WhatsappInteractionId']}});return null;})['then'](handleEntityNotFound(_0x944139,null))[_0x5e098f('0x13')](function(_0x4bf1ac){const _0xc0e4f5=_0x5e098f;if(_0x4bf1ac)return _0x50703c[_0xc0e4f5('0x1e')]=_0x4bf1ac['get']({'plain':!![]}),interaction_log[_0xc0e4f5('0x33')](_0xc0e4f5('0x5b'),_0x50218f[_0xc0e4f5('0x4a')]['id'],_0x50218f[_0xc0e4f5('0x4a')]['name'],_0x50218f[_0xc0e4f5('0x4a')]['role'],_0x50703c[_0xc0e4f5('0x1e')]['id'],_0x50218f[_0xc0e4f5('0x23')]?JSON['stringify'](_0x50218f['body']):'null'),respondWithRpcPromise('RejectMessage','rejectMessage',_0x50703c);return null;})[_0x5e098f('0x13')](function(_0x402531){const _0x3140fb=_0x5e098f;if(_0x402531)return _0x402531[_0x3140fb('0x1c')]['interface']=util[_0x3140fb('0x46')](_0x3140fb('0x45'),_0x50218f[_0x3140fb('0x4a')][_0x3140fb('0xc')]),_0x402531[_0x3140fb('0x1c')][_0x3140fb('0x1d')]=_0x50703c[_0x3140fb('0x1d')],_0x402531[_0x3140fb('0x1c')]['event']=_0x3140fb('0x15'),respondWithRpcPromise(_0x3140fb('0x35'),_0x3140fb('0x35'),{'event':_0x3140fb('0x4b'),'message':_0x402531[_0x3140fb('0x1c')]},client9002),_0x50703c;return null;})[_0x5e098f('0x13')](respondWithResult(_0x944139,null))[_0x5e098f('0x2a')](handleError(_0x944139,null));},exports[_0x48753d('0x7')]=function(_0x10f4a0,_0x253b31){const _0x10fc62=_0x48753d;_0x10f4a0[_0x10fc62('0x23')]['id']&&delete _0x10f4a0[_0x10fc62('0x23')]['id'];let _0x464a58;return db[_0x10fc62('0x0')][_0x10fc62('0x48')]({'where':{'id':_0x10f4a0[_0x10fc62('0x4d')]['id']}})[_0x10fc62('0x13')](handleEntityNotFound(_0x253b31,null))[_0x10fc62('0x13')](function(_0x537f47){const _0x1c10bc=_0x10fc62;if(_0x537f47)return _0x464a58=_0x537f47,db[_0x1c10bc('0x5a')][_0x1c10bc('0x48')]({'where':{'id':_0x537f47[_0x1c10bc('0x40')]}});})[_0x10fc62('0x13')](handleEntityNotFound(_0x253b31,null))[_0x10fc62('0x13')](function(_0xf0736b){const _0x1f9f9d=_0x10fc62;if(_0xf0736b){logger['debug']('WhatsppMessage,\x20%s,\x20%s,\x20%s',_0x1f9f9d('0x7'),_0x1f9f9d('0x57'),_0xf0736b[_0x1f9f9d('0x19')],util[_0x1f9f9d('0x2d')](_0x10f4a0['body'],{'showHidden':![],'depth':null}));switch(_0xf0736b['type']){case _0x1f9f9d('0x31'):if(_0x10f4a0[_0x1f9f9d('0x23')][_0x1f9f9d('0x4f')]&&_0x10f4a0[_0x1f9f9d('0x23')][_0x1f9f9d('0x4f')]===_0x464a58[_0x1f9f9d('0x44')]&&_0x10f4a0['body'][_0x1f9f9d('0x43')]&&_0x10f4a0[_0x1f9f9d('0x23')][_0x1f9f9d('0x43')]===_0x1f9f9d('0x6'))return _0x464a58[_0x1f9f9d('0x3f')]({'read':!![]});else logger['error'](_0x1f9f9d('0x59'),_0x1f9f9d('0x7'),_0x1f9f9d('0x31'),util[_0x1f9f9d('0x2d')](_0x10f4a0[_0x1f9f9d('0x23')],{'showHidden':![],'depth':null}));break;}return _0x464a58;}})[_0x10fc62('0x13')](respondWithResult(_0x253b31,null))[_0x10fc62('0x2a')](handleError(_0x253b31,null));}; \ No newline at end of file +const a801_0x56ca=['sendStatus','WhatsappInteraction','undefined','CmContact','params','jayson/promise','user','twilio','VIRTUAL','attributes','end','intersection','read1stAt','WhatsappAccount','length','acceptmessage','send','event','fields','set','json','WhatsappMessage,\x20%s,\x20%s','read','manual','like','SIP/%s','order','agent','destroy','message','RejectMessage','Contact','get','sort','../../rediscache','../../config/logger','inspect','Content-Range','query','WhatsappAccount,\x20%s,\x20%s,\x20%s','nolimit','filters','show','received\x20delivery\x20report\x20from','channel','WhatsppMessage,\x20%s,\x20%s,\x20%s','index','whatsapp-interactions','error','merge','debug','EventManager','reject','MessageStatus','offset','filter','catch','options','rows','then','util','findOne','create','update','rejectmessage','model','rawAttributes','info','format','../../components/parsers/qs','[WHATSAPPMESSAGE:ACCEPT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','body','interface','MessageSid','includeAll','WhatsappMessage,\x20%s,\x20%s,\x20%s','name','WhatsappMessage','WhatsappAccountId','null','limit','role','sequelize','result','stringify','interaction','keys','accept','register','request\x20sent','whatsapp','status','readAt','key','map','describe','lodash','UserId','moment','WhatsappInteractionId','stack','http','client','rejectMessage','where','fieldName','count','[WHATSAPPMESSAGE:REJECT]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s','include','type','acceptMessage'];(function(_0x55d4fa,_0x56ca1f){const _0x28457b=function(_0x47e1ff){while(--_0x47e1ff){_0x55d4fa['push'](_0x55d4fa['shift']());}};_0x28457b(++_0x56ca1f);}(a801_0x56ca,0x103));const a801_0x2845=function(_0x55d4fa,_0x56ca1f){_0x55d4fa=_0x55d4fa-0x0;let _0x28457b=a801_0x56ca[_0x55d4fa];return _0x28457b;};const _0xd049e=a801_0x2845;'use strict';const moment=require(_0xd049e('0x3d')),util=require(_0xd049e('0x17')),_=require(_0xd049e('0x3b')),qs=require(_0xd049e('0x20')),logger=require(_0xd049e('0x6d'))('api'),{getSocket}=require(_0xd049e('0x6c')),socket=getSocket(),interaction_log=require(_0xd049e('0x6d'))(_0xd049e('0xa')),db=require('../../mysqldb')['db'],{Op}=require(_0xd049e('0x2d'));require('./whatsappMessage.socket')[_0xd049e('0x33')](socket);const jayson=require(_0xd049e('0x4f')),client=jayson[_0xd049e('0x41')][_0xd049e('0x40')]({'port':0x232c}),client9002=jayson[_0xd049e('0x41')][_0xd049e('0x40')]({'port':0x232a});function respondWithRpcPromise(_0x47e1ff,_0x35e9b5,_0x801374,_0x85eee3){return new Promise(function(_0x28d834,_0x28a70f){const _0x728906=a801_0x2845,_0x361232=_0x85eee3||client;return _0x361232['request'](_0x47e1ff,_0x801374)[_0x728906('0x16')](function(_0x16a80e){const _0x3c37e4=_0x728906;logger[_0x3c37e4('0x1e')](_0x3c37e4('0x5f'),_0x35e9b5,_0x3c37e4('0x34')),logger[_0x3c37e4('0xd')](_0x3c37e4('0x26'),_0x35e9b5,_0x3c37e4('0x34'),JSON[_0x3c37e4('0x2f')](_0x16a80e));if(_0x16a80e['error']){if(_0x16a80e[_0x3c37e4('0xb')]['code']===0x1f4)return logger[_0x3c37e4('0xb')]('WhatsappMessage,\x20%s,\x20%s',_0x35e9b5,_0x16a80e[_0x3c37e4('0xb')][_0x3c37e4('0x67')]),_0x28a70f(_0x16a80e['error']['message']);return logger[_0x3c37e4('0xb')](_0x3c37e4('0x5f'),_0x35e9b5,_0x16a80e[_0x3c37e4('0xb')][_0x3c37e4('0x67')]),_0x28d834(_0x16a80e[_0x3c37e4('0xb')][_0x3c37e4('0x67')]);}else logger['info'](_0x3c37e4('0x5f'),_0x35e9b5,_0x3c37e4('0x34')),_0x28d834(_0x16a80e[_0x3c37e4('0x2e')]['message']);})[_0x728906('0x13')](function(_0x35dd48){const _0x26ac82=_0x728906;logger['error'](_0x26ac82('0x5f'),_0x35e9b5,_0x35dd48),_0x28a70f(_0x35dd48);});});}function respondWithResult(_0x201c9a,_0x57fb30){return _0x57fb30=_0x57fb30||0xc8,function(_0x97f673){const _0x15dc1b=a801_0x2845;if(_0x97f673)return _0x201c9a[_0x15dc1b('0x36')](_0x57fb30)[_0x15dc1b('0x5e')](_0x97f673);};}function respondWithFilteredResult(_0xcafb17,_0x676748){return function(_0x54e64c){const _0x3604f0=a801_0x2845;if(_0x54e64c){const _0x3da970=_0x54e64c['count'],_0x50a41c=_0x676748[_0x3604f0('0x11')];let _0x471f3d=_0x676748[_0x3604f0('0x11')]+_0x676748[_0x3604f0('0x2b')],_0x33ec37;return _0x471f3d>=_0x3da970?(_0x471f3d=_0x3da970,_0x33ec37=0xc8):_0x33ec37=0xce,_0xcafb17[_0x3604f0('0x36')](_0x33ec37),_0xcafb17[_0x3604f0('0x5d')](_0x3604f0('0x0'),_0x50a41c+'-'+_0x471f3d+'/'+_0x3da970)[_0x3604f0('0x5e')](_0x54e64c);}return null;};}function saveUpdates(_0x229b07){return function(_0x15aead){const _0x30031e=a801_0x2845;if(_0x15aead)return _0x15aead[_0x30031e('0x1a')](_0x229b07)[_0x30031e('0x16')](function(_0x2d1924){return _0x2d1924;});return null;};}function removeEntity(_0x33037c){return function(_0x3d22d2){const _0x58a243=a801_0x2845;if(_0x3d22d2)return _0x3d22d2[_0x58a243('0x66')]()[_0x58a243('0x16')](function(){const _0x406ac6=_0x58a243;_0x33037c['status'](0xcc)[_0x406ac6('0x54')]();});};}function handleEntityNotFound(_0x4b1090){return function(_0x13f9b3){const _0x45613d=a801_0x2845;return!_0x13f9b3&&_0x4b1090[_0x45613d('0x4a')](0x194),_0x13f9b3;};}function handleError(_0x576555,_0x43e060){return _0x43e060=_0x43e060||0x1f4,function(_0x177cec){const _0x2f8b8b=a801_0x2845;logger['error'](_0x177cec[_0x2f8b8b('0x3f')]),_0x177cec[_0x2f8b8b('0x27')]&&delete _0x177cec['name'],_0x576555[_0x2f8b8b('0x36')](_0x43e060)[_0x2f8b8b('0x5a')](_0x177cec);};}exports[_0xd049e('0x9')]=function(_0x2f0f89,_0x287bc5){const _0x27b99b=_0xd049e;let _0x3e0cda={};const _0x3a69c7={},_0x3d0696={'count':0x0,'rows':[]},_0x463af1=_[_0x27b99b('0x39')](db[_0x27b99b('0x28')]['rawAttributes'],function(_0x23db08){const _0xbbb550=_0x27b99b;return{'name':_0x23db08[_0xbbb550('0x44')],'type':_0x23db08['type'][_0xbbb550('0x38')]};});_0x3a69c7[_0x27b99b('0x1c')]=_[_0x27b99b('0x39')](_0x463af1,'name'),_0x3a69c7['query']=_[_0x27b99b('0x31')](_0x2f0f89[_0x27b99b('0x1')]),_0x3a69c7['filters']=_[_0x27b99b('0x55')](_0x3a69c7[_0x27b99b('0x1c')],_0x3a69c7[_0x27b99b('0x1')]),_0x3e0cda[_0x27b99b('0x53')]=_['intersection'](_0x3a69c7[_0x27b99b('0x1c')],qs[_0x27b99b('0x5c')](_0x2f0f89[_0x27b99b('0x1')][_0x27b99b('0x5c')])),_0x3e0cda['attributes']=_0x3e0cda[_0x27b99b('0x53')][_0x27b99b('0x58')]?_0x3e0cda['attributes']:_0x3a69c7[_0x27b99b('0x1c')];typeof _0x2f0f89[_0x27b99b('0x1')][_0x27b99b('0x3')]===_0x27b99b('0x4c')&&(_0x3e0cda['limit']=qs[_0x27b99b('0x2b')](_0x2f0f89[_0x27b99b('0x1')]['limit']),_0x3e0cda[_0x27b99b('0x11')]=qs[_0x27b99b('0x11')](_0x2f0f89[_0x27b99b('0x1')][_0x27b99b('0x11')]));_0x3e0cda[_0x27b99b('0x64')]=qs[_0x27b99b('0x6b')](_0x2f0f89[_0x27b99b('0x1')][_0x27b99b('0x6b')]),_0x3e0cda[_0x27b99b('0x43')]=qs[_0x27b99b('0x4')](_['pick'](_0x2f0f89['query'],_0x3a69c7[_0x27b99b('0x4')]),_0x463af1);_0x2f0f89[_0x27b99b('0x1')][_0x27b99b('0x12')]&&(_0x3e0cda[_0x27b99b('0x43')]=_[_0x27b99b('0xc')](_0x3e0cda['where'],{[Op['or']]:_[_0x27b99b('0x39')](_0x463af1,function(_0x55823a){const _0x24cb23=_0x27b99b;if(_0x55823a[_0x24cb23('0x48')]!==_0x24cb23('0x52')){const _0xd54be8={};return _0xd54be8[_0x55823a['name']]={[Op[_0x24cb23('0x62')]]:'%'+_0x2f0f89[_0x24cb23('0x1')][_0x24cb23('0x12')]+'%'},_0xd54be8;}})}));_0x3e0cda=_[_0x27b99b('0xc')]({},_0x3e0cda,_0x2f0f89[_0x27b99b('0x14')]);const _0x30f4fd={'where':_0x3e0cda[_0x27b99b('0x43')]};return db[_0x27b99b('0x28')][_0x27b99b('0x45')](_0x30f4fd)['then'](function(_0x35a055){const _0x209c8a=_0x27b99b;return _0x3d0696[_0x209c8a('0x45')]=_0x35a055,_0x2f0f89[_0x209c8a('0x1')]['includeAll']&&(_0x3e0cda[_0x209c8a('0x47')]=[{'all':!![]}]),db[_0x209c8a('0x28')]['findAll'](_0x3e0cda);})[_0x27b99b('0x16')](function(_0x50ed6a){const _0x33578d=_0x27b99b;return _0x3d0696[_0x33578d('0x15')]=_0x50ed6a,_0x3d0696;})[_0x27b99b('0x16')](respondWithFilteredResult(_0x287bc5,_0x3e0cda))[_0x27b99b('0x13')](handleError(_0x287bc5,null));},exports[_0xd049e('0x5')]=function(_0x371b39,_0x5bce0f){const _0x3c7dbe=_0xd049e;let _0x107e5d={'raw':!![],'where':{'id':_0x371b39[_0x3c7dbe('0x4e')]['id']}};const _0xb5f53d={};return _0xb5f53d[_0x3c7dbe('0x1c')]=_[_0x3c7dbe('0x31')](db[_0x3c7dbe('0x28')][_0x3c7dbe('0x1d')]),_0xb5f53d[_0x3c7dbe('0x1')]=_[_0x3c7dbe('0x31')](_0x371b39[_0x3c7dbe('0x1')]),_0xb5f53d[_0x3c7dbe('0x4')]=_[_0x3c7dbe('0x55')](_0xb5f53d[_0x3c7dbe('0x1c')],_0xb5f53d[_0x3c7dbe('0x1')]),_0x107e5d[_0x3c7dbe('0x53')]=_[_0x3c7dbe('0x55')](_0xb5f53d[_0x3c7dbe('0x1c')],qs[_0x3c7dbe('0x5c')](_0x371b39[_0x3c7dbe('0x1')][_0x3c7dbe('0x5c')])),_0x107e5d[_0x3c7dbe('0x53')]=_0x107e5d['attributes'][_0x3c7dbe('0x58')]?_0x107e5d[_0x3c7dbe('0x53')]:_0xb5f53d[_0x3c7dbe('0x1c')],_0x371b39[_0x3c7dbe('0x1')][_0x3c7dbe('0x25')]&&(_0x107e5d[_0x3c7dbe('0x47')]=[{'all':!![]}]),_0x107e5d=_[_0x3c7dbe('0xc')]({},_0x107e5d,_0x371b39[_0x3c7dbe('0x14')]),db[_0x3c7dbe('0x28')]['findOne'](_0x107e5d)[_0x3c7dbe('0x16')](handleEntityNotFound(_0x5bce0f,null))[_0x3c7dbe('0x16')](respondWithResult(_0x5bce0f,null))[_0x3c7dbe('0x13')](handleError(_0x5bce0f,null));},exports[_0xd049e('0x19')]=function(_0x3aa7ae,_0x3c168b){const _0x57e24d=_0xd049e;return db[_0x57e24d('0x28')][_0x57e24d('0x19')](_0x3aa7ae[_0x57e24d('0x22')],{})[_0x57e24d('0x16')](respondWithResult(_0x3c168b,0xc9))[_0x57e24d('0x13')](handleError(_0x3c168b,null));},exports[_0xd049e('0x1a')]=function(_0x1dd5ea,_0x375ad3){const _0x29c31b=_0xd049e;return _0x1dd5ea['body']['id']&&delete _0x1dd5ea['body']['id'],db[_0x29c31b('0x28')]['findOne']({'where':{'id':_0x1dd5ea[_0x29c31b('0x4e')]['id']}})[_0x29c31b('0x16')](handleEntityNotFound(_0x375ad3,null))[_0x29c31b('0x16')](saveUpdates(_0x1dd5ea[_0x29c31b('0x22')],null))['then'](respondWithResult(_0x375ad3,null))[_0x29c31b('0x13')](handleError(_0x375ad3,null));},exports[_0xd049e('0x66')]=function(_0xb57d8e,_0x101638){const _0x5a43f4=_0xd049e;return db[_0x5a43f4('0x28')][_0x5a43f4('0x18')]({'where':{'id':_0xb57d8e['params']['id']}})['then'](handleEntityNotFound(_0x101638,null))['then'](removeEntity(_0x101638,null))[_0x5a43f4('0x13')](handleError(_0x101638,null));},exports['describe']=function(_0xc6969b,_0x2df572){const _0x57bd48=_0xd049e;return db[_0x57bd48('0x28')][_0x57bd48('0x3a')]()[_0x57bd48('0x16')](respondWithResult(_0x2df572,null))[_0x57bd48('0x13')](handleError(_0x2df572,null));},exports[_0xd049e('0x32')]=function(_0x3c8003,_0x3997de){const _0x38072f=_0xd049e,_0x41edec={'channel':_0x38072f('0x35')};return _0x3c8003[_0x38072f('0x22')]['id']&&delete _0x3c8003[_0x38072f('0x22')]['id'],_0x3c8003[_0x38072f('0x22')]['read']=!![],_0x3c8003[_0x38072f('0x22')][_0x38072f('0x37')]=moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),_0x3c8003[_0x38072f('0x22')]['UserId']=_0x3c8003[_0x38072f('0x22')][_0x38072f('0x3c')]||_0x3c8003['user']['id'],db[_0x38072f('0x28')]['findOne']({'where':{'id':_0x3c8003[_0x38072f('0x4e')]['id'],'UserId':null},'include':[{'model':db[_0x38072f('0x4d')],'as':_0x38072f('0x69')}]})[_0x38072f('0x16')](handleEntityNotFound(_0x3997de,null))[_0x38072f('0x16')](saveUpdates(_0x3c8003[_0x38072f('0x22')],null))[_0x38072f('0x16')](function(_0x5e7732){const _0x34e656=_0x38072f;if(_0x5e7732)return _0x41edec['message']=_0x5e7732[_0x34e656('0x6a')]({'plain':!![]}),db[_0x34e656('0x4b')][_0x34e656('0x18')]({'where':{'id':_0x5e7732[_0x34e656('0x3e')]}});return null;})[_0x38072f('0x16')](handleEntityNotFound(_0x3997de,null))[_0x38072f('0x16')](function(_0x1d58f2){const _0x43a6ac=_0x38072f;if(_0x1d58f2)return _0x1d58f2[_0x43a6ac('0x1a')]({'UserId':_0x3c8003['body'][_0x43a6ac('0x3c')],'read1stAt':_['isNil'](_0x1d58f2[_0x43a6ac('0x56')])?moment()['format']('YYYY-MM-DD\x20HH:mm:ss'):undefined});return null;})[_0x38072f('0x16')](function(_0x47f59f){const _0x4e6160=_0x38072f;if(_0x47f59f)return _0x41edec['interaction']=_0x47f59f[_0x4e6160('0x6a')]({'plain':!![]}),interaction_log[_0x4e6160('0x1e')](_0x4e6160('0x21'),_0x3c8003[_0x4e6160('0x50')]['id'],_0x3c8003['user'][_0x4e6160('0x27')],_0x3c8003['user'][_0x4e6160('0x2c')],_0x41edec['interaction']['id'],_0x3c8003[_0x4e6160('0x22')]?JSON[_0x4e6160('0x2f')](_0x3c8003[_0x4e6160('0x22')]):_0x4e6160('0x2a')),respondWithRpcPromise('AcceptMessage',_0x4e6160('0x49'),_0x41edec);return null;})['then'](function(_0x3b5afb){const _0x237690=_0x38072f;if(_0x3b5afb){if(_0x3c8003[_0x237690('0x22')][_0x237690('0x61')])return _0x41edec[_0x237690('0x67')][_0x237690('0x23')]=util[_0x237690('0x1f')](_0x237690('0x63'),_0x3c8003[_0x237690('0x50')][_0x237690('0x27')]),_0x41edec[_0x237690('0x67')][_0x237690('0x7')]=_0x41edec['channel'],_0x41edec[_0x237690('0x67')]['event']=_0x237690('0x32'),respondWithRpcPromise('EventManager',_0x237690('0xe'),{'event':_0x237690('0x59'),'message':_0x41edec[_0x237690('0x67')]},client9002)[_0x237690('0x16')](function(){return _0x41edec;});return _0x41edec;}return null;})[_0x38072f('0x16')](respondWithResult(_0x3997de,null))['catch'](handleError(_0x3997de,null));},exports['reject']=function(_0x3616b1,_0x101ac8){const _0x213198=_0xd049e,_0x482b7d={'agent':{},'channel':_0x213198('0x35')};return _0x3616b1[_0x213198('0x22')]['id']&&delete _0x3616b1['body']['id'],_0x3616b1[_0x213198('0x22')][_0x213198('0x3c')]=_0x3616b1[_0x213198('0x22')][_0x213198('0x3c')]||_0x3616b1[_0x213198('0x50')]['id'],_0x482b7d[_0x213198('0x65')]['id']=_0x3616b1['body'][_0x213198('0x3c')],db['WhatsappMessage'][_0x213198('0x18')]({'where':{'id':_0x3616b1[_0x213198('0x4e')]['id'],'UserId':null}})['then'](handleEntityNotFound(_0x101ac8,null))[_0x213198('0x16')](function(_0x333b9e){const _0x3012a2=_0x213198;if(_0x333b9e)return _0x482b7d['message']=_0x333b9e['get']({'plain':!![]}),db[_0x3012a2('0x4b')][_0x3012a2('0x18')]({'where':{'id':_0x333b9e[_0x3012a2('0x3e')]}});return null;})[_0x213198('0x16')](handleEntityNotFound(_0x101ac8,null))[_0x213198('0x16')](function(_0x471f1a){const _0x3cb5cb=_0x213198;if(_0x471f1a)return _0x482b7d[_0x3cb5cb('0x30')]=_0x471f1a[_0x3cb5cb('0x6a')]({'plain':!![]}),interaction_log[_0x3cb5cb('0x1e')](_0x3cb5cb('0x46'),_0x3616b1['user']['id'],_0x3616b1[_0x3cb5cb('0x50')]['name'],_0x3616b1[_0x3cb5cb('0x50')][_0x3cb5cb('0x2c')],_0x482b7d[_0x3cb5cb('0x30')]['id'],_0x3616b1[_0x3cb5cb('0x22')]?JSON[_0x3cb5cb('0x2f')](_0x3616b1[_0x3cb5cb('0x22')]):'null'),respondWithRpcPromise(_0x3cb5cb('0x68'),_0x3cb5cb('0x42'),_0x482b7d);return null;})[_0x213198('0x16')](function(_0x4a48e1){const _0x5d4918=_0x213198;if(_0x4a48e1)return _0x4a48e1['message']['interface']=util[_0x5d4918('0x1f')]('SIP/%s',_0x3616b1[_0x5d4918('0x50')][_0x5d4918('0x27')]),_0x4a48e1[_0x5d4918('0x67')][_0x5d4918('0x7')]=_0x482b7d[_0x5d4918('0x7')],_0x4a48e1['message'][_0x5d4918('0x5b')]=_0x5d4918('0xf'),respondWithRpcPromise('EventManager',_0x5d4918('0xe'),{'event':_0x5d4918('0x1b'),'message':_0x4a48e1[_0x5d4918('0x67')]},client9002),_0x482b7d;return null;})[_0x213198('0x16')](respondWithResult(_0x101ac8,null))['catch'](handleError(_0x101ac8,null));},exports[_0xd049e('0x36')]=function(_0x58b7f5,_0x104e53){const _0x25ed7b=_0xd049e;_0x58b7f5[_0x25ed7b('0x22')]['id']&&delete _0x58b7f5[_0x25ed7b('0x22')]['id'];let _0x1901fe;return db[_0x25ed7b('0x28')]['findOne']({'where':{'id':_0x58b7f5[_0x25ed7b('0x4e')]['id']}})[_0x25ed7b('0x16')](handleEntityNotFound(_0x104e53,null))['then'](function(_0x1e727a){const _0x1b27d6=_0x25ed7b;if(_0x1e727a)return _0x1901fe=_0x1e727a,db[_0x1b27d6('0x57')][_0x1b27d6('0x18')]({'where':{'id':_0x1e727a[_0x1b27d6('0x29')]}});})[_0x25ed7b('0x16')](handleEntityNotFound(_0x104e53,null))[_0x25ed7b('0x16')](function(_0x11c7bf){const _0x2652be=_0x25ed7b;if(_0x11c7bf){logger[_0x2652be('0xd')](_0x2652be('0x8'),_0x2652be('0x36'),_0x2652be('0x6'),_0x11c7bf['type'],util[_0x2652be('0x6e')](_0x58b7f5[_0x2652be('0x22')],{'showHidden':![],'depth':null}));switch(_0x11c7bf[_0x2652be('0x48')]){case _0x2652be('0x51'):if(_0x58b7f5['body'][_0x2652be('0x24')]&&_0x58b7f5[_0x2652be('0x22')][_0x2652be('0x24')]===_0x1901fe['messageId']&&_0x58b7f5[_0x2652be('0x22')]['MessageStatus']&&_0x58b7f5[_0x2652be('0x22')][_0x2652be('0x10')]===_0x2652be('0x60'))return _0x1901fe[_0x2652be('0x1a')]({'read':!![]});else logger[_0x2652be('0xb')](_0x2652be('0x2'),'status',_0x2652be('0x51'),util['inspect'](_0x58b7f5[_0x2652be('0x22')],{'showHidden':![],'depth':null}));break;}return _0x1901fe;}})[_0x25ed7b('0x16')](respondWithResult(_0x104e53,null))[_0x25ed7b('0x13')](handleError(_0x104e53,null));}; \ No newline at end of file diff --git a/server/api/whatsappMessage/whatsappMessage.events.js b/server/api/whatsappMessage/whatsappMessage.events.js index c696574..594a81b 100644 --- a/server/api/whatsappMessage/whatsappMessage.events.js +++ b/server/api/whatsappMessage/whatsappMessage.events.js @@ -1 +1 @@ -const a802_0x1f4b=['addHook','exports','../../mysqldb','setMaxListeners','remove','undefined','emit','update','save','events'];(function(_0x142634,_0x1f4b5b){const _0x297975=function(_0x3820cb){while(--_0x3820cb){_0x142634['push'](_0x142634['shift']());}};_0x297975(++_0x1f4b5b);}(a802_0x1f4b,0x173));const a802_0x2979=function(_0x142634,_0x1f4b5b){_0x142634=_0x142634-0x0;let _0x297975=a802_0x1f4b[_0x142634];return _0x297975;};const _0x12dbc9=a802_0x2979;'use strict';const EventEmitter=require(_0x12dbc9('0x8')),WhatsappMessage=require(_0x12dbc9('0x1'))['db']['WhatsappMessage'],WhatsappMessageEvents=new EventEmitter();WhatsappMessageEvents[_0x12dbc9('0x2')](0x0);const events={'afterCreate':_0x12dbc9('0x7'),'afterUpdate':_0x12dbc9('0x6'),'afterDestroy':_0x12dbc9('0x3')};function emitEvent(_0x3820cb){return function(_0x106c4c){const _0x555a3=a802_0x2979;WhatsappMessageEvents[_0x555a3('0x5')](_0x3820cb+':'+_0x106c4c['id'],_0x106c4c),WhatsappMessageEvents[_0x555a3('0x5')](_0x3820cb,_0x106c4c);};}for(const e in events){if(typeof events[e]!==_0x12dbc9('0x4')){const event=events[e];WhatsappMessage[_0x12dbc9('0x9')](e,emitEvent(event));}}module[_0x12dbc9('0x0')]=WhatsappMessageEvents; \ No newline at end of file +const a802_0x2bed=['emit','events','WhatsappMessage','setMaxListeners','addHook','../../mysqldb','update','save','remove','exports'];(function(_0x4465da,_0x2bede8){const _0x1fa77b=function(_0x4cd94a){while(--_0x4cd94a){_0x4465da['push'](_0x4465da['shift']());}};_0x1fa77b(++_0x2bede8);}(a802_0x2bed,0x109));const a802_0x1fa7=function(_0x4465da,_0x2bede8){_0x4465da=_0x4465da-0x0;let _0x1fa77b=a802_0x2bed[_0x4465da];return _0x1fa77b;};const _0x258bcb=a802_0x1fa7;'use strict';const EventEmitter=require(_0x258bcb('0x6')),WhatsappMessage=require(_0x258bcb('0x0'))['db'][_0x258bcb('0x7')],WhatsappMessageEvents=new EventEmitter();WhatsappMessageEvents[_0x258bcb('0x8')](0x0);const events={'afterCreate':_0x258bcb('0x2'),'afterUpdate':_0x258bcb('0x1'),'afterDestroy':_0x258bcb('0x3')};function emitEvent(_0x4cd94a){return function(_0x2f7522){const _0x5cb4f4=a802_0x1fa7;WhatsappMessageEvents[_0x5cb4f4('0x5')](_0x4cd94a+':'+_0x2f7522['id'],_0x2f7522),WhatsappMessageEvents[_0x5cb4f4('0x5')](_0x4cd94a,_0x2f7522);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];WhatsappMessage[_0x258bcb('0x9')](e,emitEvent(event));}}module[_0x258bcb('0x4')]=WhatsappMessageEvents; \ No newline at end of file diff --git a/server/api/whatsappMessage/whatsappMessage.model.js b/server/api/whatsappMessage/whatsappMessage.model.js index 07d28b2..5d22b9b 100644 --- a/server/api/whatsappMessage/whatsappMessage.model.js +++ b/server/api/whatsappMessage/whatsappMessage.model.js @@ -1 +1 @@ -const a803_0x1314=['error','findOne','update','fti_whatsapp_messages','afterCreate','utf8mb4_unicode_ci','createdAt','out','./whatsappMessage.attributes','catch','util','twilio','direction','finally','messages','/api/whatsapp/messages/','Missing\x20parameters:\x20phone,\x20accountSid\x20or\x20authToken','accountSid','type','authToken','/status?token=','then','body','sid','utf8mb4','lodash','WhatsappInteractionId','token','toLowerCase','whatsapp:','create','messageId','UserId','WhatsappAccountId','secret','WhatsappMessage','api','../../config/logger','whatsapp_messages','WhatsappMessage,\x20%s,\x20%s,\x20%s','FULLTEXT','phone','define'];(function(_0x521480,_0x13145e){const _0xb8d980=function(_0x32a260){while(--_0x32a260){_0x521480['push'](_0x521480['shift']());}};_0xb8d980(++_0x13145e);}(a803_0x1314,0x13f));const a803_0xb8d9=function(_0x521480,_0x13145e){_0x521480=_0x521480-0x0;let _0xb8d980=a803_0x1314[_0x521480];return _0xb8d980;};const _0x47c16a=a803_0xb8d9;'use strict';const _=require(_0x47c16a('0x7')),util=require(_0x47c16a('0x23')),logger=require(_0x47c16a('0x13'))(_0x47c16a('0x12')),attributes=require(_0x47c16a('0x21'));module['exports']=function(_0x32a260){const _0x371d9d=_0x47c16a,_0xf73b2f=_0x32a260['models'],_0x8a59e5=_0x32a260[_0x371d9d('0x18')](_0x371d9d('0x11'),attributes,{'tableName':_0x371d9d('0x14'),'paranoid':![],'indexes':[{'name':'messageId','fields':[_0x371d9d('0xd')]},{'name':_0x371d9d('0x1c'),'fields':['body'],'type':_0x371d9d('0x16')}],'timestamps':!![],'hooks':{'afterCreate':function(_0x4bc71f){const _0x51e4dc=_0x371d9d,_0x1bc32e=_0x4bc71f['get']({'plain':!![]});(_0x1bc32e[_0x51e4dc('0x25')][_0x51e4dc('0xa')]()==='in'||_0x1bc32e['direction'][_0x51e4dc('0xa')]()===_0x51e4dc('0x20')&&!_0x1bc32e[_0x51e4dc('0x10')]&&!_['isNil'](_0x1bc32e[_0x51e4dc('0xe')]))&&_0xf73b2f['WhatsappInteraction'][_0x51e4dc('0x1a')]({'where':{'id':_0x1bc32e[_0x51e4dc('0x8')]}})['then'](function(_0x4232ca){const _0x380316=_0x51e4dc;_0x4232ca&&_0x4232ca[_0x380316('0x1b')]({'lastMsgAt':_0x1bc32e[_0x380316('0x1f')],'lastMsgDirection':_0x1bc32e[_0x380316('0x25')][_0x380316('0xa')]()});})[_0x51e4dc('0x22')](function(_0x5d1992){console['error'](_0x5d1992);});if(_0x1bc32e['direction']===_0x51e4dc('0x20')&&!_0x1bc32e['secret']){let _0x2c6038;_0xf73b2f['WhatsappAccount'][_0x51e4dc('0x1a')]({'where':{'id':_0x1bc32e[_0x51e4dc('0xf')]},'raw':!![]})[_0x51e4dc('0x3')](function(_0x4d2db1){const _0x2aed93=_0x51e4dc;_0x2c6038=_0x4d2db1;if(_0x2c6038&&_0x2c6038[_0x2aed93('0x0')])switch(_0x2c6038['type']){case _0x2aed93('0x24'):{const _0x3cc6f5=require(_0x2aed93('0x24'));if(_0x2c6038[_0x2aed93('0x2a')]&&_0x2c6038['authToken']&&_0x2c6038[_0x2aed93('0x17')]){const _0x4b015c=new _0x3cc6f5(_0x2c6038[_0x2aed93('0x2a')],_0x2c6038[_0x2aed93('0x1')]);_0x4b015c[_0x2aed93('0x27')][_0x2aed93('0xc')]({'body':_0x1bc32e[_0x2aed93('0x4')],'to':_0x2aed93('0xb')+_0x1bc32e[_0x2aed93('0x17')],'from':'whatsapp:'+_0x2c6038[_0x2aed93('0x17')],'statusCallback':_0x2c6038['remote']+_0x2aed93('0x28')+_0x1bc32e['id']+_0x2aed93('0x2')+_0x2c6038[_0x2aed93('0x9')]})[_0x2aed93('0x3')](function(_0x5d4977){const _0x433156=_0x2aed93;if(_0x5d4977[_0x433156('0x5')])return _0x4bc71f['update']({'messageId':_0x5d4977['sid']});})['catch'](function(_0x2ca732){const _0x3b178c=_0x2aed93;logger['error']('WhatsappMessage,\x20%s,\x20%s,\x20%s',_0x3b178c('0x1d'),_0x3b178c('0x24'),util['inspect'](_0x2ca732,{'showHidden':![],'depth':null}));});}else logger[_0x2aed93('0x19')](_0x2aed93('0x15'),'afterCreate',_0x2aed93('0x24'),_0x2aed93('0x29'));}break;}})[_0x51e4dc('0x26')](function(){return null;});}else return null;}},'charset':_0x371d9d('0x6'),'collate':_0x371d9d('0x1e')});return _0x8a59e5;}; \ No newline at end of file +const a803_0x3266=['toLowerCase','WhatsappMessage','models','WhatsappMessage,\x20%s,\x20%s,\x20%s','get','twilio','utf8mb4_unicode_ci','update','phone','whatsapp_messages','fti_whatsapp_messages','error','catch','WhatsappAccount','createdAt','WhatsappInteractionId','afterCreate','exports','finally','lodash','remote','messageId','secret','WhatsappInteraction','Missing\x20parameters:\x20phone,\x20accountSid\x20or\x20authToken','direction','messages','/status?token=','token','authToken','create','type','then','body','isNil','./whatsappMessage.attributes','findOne','UserId','out','accountSid','sid','FULLTEXT'];(function(_0x18bd27,_0x3266aa){const _0x504862=function(_0x1953b6){while(--_0x1953b6){_0x18bd27['push'](_0x18bd27['shift']());}};_0x504862(++_0x3266aa);}(a803_0x3266,0x168));const a803_0x5048=function(_0x18bd27,_0x3266aa){_0x18bd27=_0x18bd27-0x0;let _0x504862=a803_0x3266[_0x18bd27];return _0x504862;};const _0x386316=a803_0x5048;'use strict';const _=require(_0x386316('0x25')),util=require('util'),logger=require('../../config/logger')('api'),attributes=require(_0x386316('0xb'));module[_0x386316('0x23')]=function(_0x1953b6){const _0x5996e0=_0x386316,_0x1a62fa=_0x1953b6[_0x5996e0('0x14')],_0x1d97da=_0x1953b6['define'](_0x5996e0('0x13'),attributes,{'tableName':_0x5996e0('0x1b'),'paranoid':![],'indexes':[{'name':_0x5996e0('0x27'),'fields':[_0x5996e0('0x27')]},{'name':_0x5996e0('0x1c'),'fields':[_0x5996e0('0x9')],'type':_0x5996e0('0x11')}],'timestamps':!![],'hooks':{'afterCreate':function(_0x35bcb3){const _0x9f4ad0=_0x5996e0,_0xc0f1ab=_0x35bcb3[_0x9f4ad0('0x16')]({'plain':!![]});(_0xc0f1ab[_0x9f4ad0('0x1')][_0x9f4ad0('0x12')]()==='in'||_0xc0f1ab[_0x9f4ad0('0x1')]['toLowerCase']()===_0x9f4ad0('0xe')&&!_0xc0f1ab['secret']&&!_[_0x9f4ad0('0xa')](_0xc0f1ab[_0x9f4ad0('0xd')]))&&_0x1a62fa[_0x9f4ad0('0x29')]['findOne']({'where':{'id':_0xc0f1ab[_0x9f4ad0('0x21')]}})[_0x9f4ad0('0x8')](function(_0x1af667){const _0x214ab9=_0x9f4ad0;_0x1af667&&_0x1af667['update']({'lastMsgAt':_0xc0f1ab[_0x214ab9('0x20')],'lastMsgDirection':_0xc0f1ab['direction'][_0x214ab9('0x12')]()});})[_0x9f4ad0('0x1e')](function(_0x4ca3fc){const _0x56716e=_0x9f4ad0;console[_0x56716e('0x1d')](_0x4ca3fc);});if(_0xc0f1ab['direction']==='out'&&!_0xc0f1ab[_0x9f4ad0('0x28')]){let _0x44dd14;_0x1a62fa[_0x9f4ad0('0x1f')][_0x9f4ad0('0xc')]({'where':{'id':_0xc0f1ab['WhatsappAccountId']},'raw':!![]})['then'](function(_0x2a6852){const _0x346655=_0x9f4ad0;_0x44dd14=_0x2a6852;if(_0x44dd14&&_0x44dd14['type'])switch(_0x44dd14[_0x346655('0x7')]){case'twilio':{const _0xef35e0=require(_0x346655('0x17'));if(_0x44dd14[_0x346655('0xf')]&&_0x44dd14[_0x346655('0x5')]&&_0x44dd14[_0x346655('0x1a')]){const _0x4f1120=new _0xef35e0(_0x44dd14[_0x346655('0xf')],_0x44dd14[_0x346655('0x5')]);_0x4f1120[_0x346655('0x2')][_0x346655('0x6')]({'body':_0xc0f1ab[_0x346655('0x9')],'to':'whatsapp:'+_0xc0f1ab['phone'],'from':'whatsapp:'+_0x44dd14['phone'],'statusCallback':_0x44dd14[_0x346655('0x26')]+'/api/whatsapp/messages/'+_0xc0f1ab['id']+_0x346655('0x3')+_0x44dd14[_0x346655('0x4')]})['then'](function(_0x26fb5c){const _0x51d1db=_0x346655;if(_0x26fb5c[_0x51d1db('0x10')])return _0x35bcb3[_0x51d1db('0x19')]({'messageId':_0x26fb5c[_0x51d1db('0x10')]});})[_0x346655('0x1e')](function(_0x28e0a2){const _0x237a42=_0x346655;logger[_0x237a42('0x1d')](_0x237a42('0x15'),_0x237a42('0x22'),_0x237a42('0x17'),util['inspect'](_0x28e0a2,{'showHidden':![],'depth':null}));});}else logger['error'](_0x346655('0x15'),_0x346655('0x22'),'twilio',_0x346655('0x0'));}break;}})[_0x9f4ad0('0x24')](function(){return null;});}else return null;}},'charset':'utf8mb4','collate':_0x5996e0('0x18')});return _0x1d97da;}; \ No newline at end of file diff --git a/server/api/whatsappMessage/whatsappMessage.rpc.js b/server/api/whatsappMessage/whatsappMessage.rpc.js index 0184356..90aa572 100644 --- a/server/api/whatsappMessage/whatsappMessage.rpc.js +++ b/server/api/whatsappMessage/whatsappMessage.rpc.js @@ -1 +1 @@ -const a804_0x2f01=['rpc','catch','message','../../rediscache','create','../../mysqldb','options','WhatsappMessage','body','CreateWhatsappMessage','info','register','./whatsappMessage.socket','raw','error','then'];(function(_0x159156,_0x2f0100){const _0x264bcd=function(_0x256eba){while(--_0x256eba){_0x159156['push'](_0x159156['shift']());}};_0x264bcd(++_0x2f0100);}(a804_0x2f01,0x9a));const a804_0x264b=function(_0x159156,_0x2f0100){_0x159156=_0x159156-0x0;let _0x264bcd=a804_0x2f01[_0x159156];return _0x264bcd;};const _0x5721b9=a804_0x264b;'use strict';const db=require(_0x5721b9('0xb'))['db'],logger=require('../../config/logger')(_0x5721b9('0x6')),{getSocket}=require(_0x5721b9('0x9')),socket=getSocket();require(_0x5721b9('0x2'))[_0x5721b9('0x1')](socket),exports[_0x5721b9('0xf')]=function(_0x256eba){const _0x548515=this;return new Promise(function(_0x27eb00,_0x401ac3){const _0xe0106d=a804_0x264b;return db[_0xe0106d('0xd')][_0xe0106d('0xa')](_0x256eba[_0xe0106d('0xe')],{'raw':_0x256eba['options']?_0x256eba[_0xe0106d('0xc')][_0xe0106d('0x3')]===undefined?!![]:![]:!![]})[_0xe0106d('0x5')](function(_0x384378){const _0x5b4e04=_0xe0106d;logger[_0x5b4e04('0x0')](_0x5b4e04('0xf'),_0x256eba),logger['debug'](_0x5b4e04('0xf'),_0x256eba,JSON['stringify'](_0x384378)),_0x27eb00(_0x384378);})[_0xe0106d('0x7')](function(_0x38711b){const _0x5cbc9a=_0xe0106d;logger[_0x5cbc9a('0x4')](_0x5cbc9a('0xf'),_0x38711b['message'],_0x256eba),_0x401ac3(_0x548515['error'](0x1f4,_0x38711b[_0x5cbc9a('0x8')]));});});}; \ No newline at end of file +const a804_0x4d19=['error','message','stringify','raw','options','catch','../../mysqldb','CreateWhatsappMessage','debug','info'];(function(_0x3e2aa6,_0x4d19ca){const _0x4c62a4=function(_0x2789a6){while(--_0x2789a6){_0x3e2aa6['push'](_0x3e2aa6['shift']());}};_0x4c62a4(++_0x4d19ca);}(a804_0x4d19,0x1de));const a804_0x4c62=function(_0x3e2aa6,_0x4d19ca){_0x3e2aa6=_0x3e2aa6-0x0;let _0x4c62a4=a804_0x4d19[_0x3e2aa6];return _0x4c62a4;};const _0x1e3b41=a804_0x4c62;'use strict';const db=require(_0x1e3b41('0x8'))['db'],logger=require('../../config/logger')('rpc'),{getSocket}=require('../../rediscache'),socket=getSocket();require('./whatsappMessage.socket')['register'](socket),exports[_0x1e3b41('0x9')]=function(_0x2789a6){const _0x575f94=this;return new Promise(function(_0x1dffc0,_0x1978f6){const _0x58945c=a804_0x4c62;return db['WhatsappMessage']['create'](_0x2789a6['body'],{'raw':_0x2789a6[_0x58945c('0x6')]?_0x2789a6[_0x58945c('0x6')][_0x58945c('0x5')]===undefined?!![]:![]:!![]})['then'](function(_0x1ff6f7){const _0x313cd3=_0x58945c;logger[_0x313cd3('0x1')]('CreateWhatsappMessage',_0x2789a6),logger[_0x313cd3('0x0')](_0x313cd3('0x9'),_0x2789a6,JSON[_0x313cd3('0x4')](_0x1ff6f7)),_0x1dffc0(_0x1ff6f7);})[_0x58945c('0x7')](function(_0x44006e){const _0x27814b=_0x58945c;logger[_0x27814b('0x2')](_0x27814b('0x9'),_0x44006e['message'],_0x2789a6),_0x1978f6(_0x575f94[_0x27814b('0x2')](0x1f4,_0x44006e[_0x27814b('0x3')]));});});}; \ No newline at end of file diff --git a/server/api/whatsappMessage/whatsappMessage.socket.js b/server/api/whatsappMessage/whatsappMessage.socket.js index 6671e98..5120b46 100644 --- a/server/api/whatsappMessage/whatsappMessage.socket.js +++ b/server/api/whatsappMessage/whatsappMessage.socket.js @@ -1 +1 @@ -const a805_0x1ccb=['remove','./whatsappMessage.events','register','save','whatsappMessage:','emit','update'];(function(_0x5811eb,_0x1ccba6){const _0x3fd6e2=function(_0x48c21d){while(--_0x48c21d){_0x5811eb['push'](_0x5811eb['shift']());}};_0x3fd6e2(++_0x1ccba6);}(a805_0x1ccb,0xf1));const a805_0x3fd6=function(_0x5811eb,_0x1ccba6){_0x5811eb=_0x5811eb-0x0;let _0x3fd6e2=a805_0x1ccb[_0x5811eb];return _0x3fd6e2;};const _0x1c20ac=a805_0x3fd6;'use strict';const WhatsappMessageEvents=require(_0x1c20ac('0x5')),events=[_0x1c20ac('0x0'),_0x1c20ac('0x4'),_0x1c20ac('0x3')];function createListener(_0x48c21d,_0x3e3d89){return function(_0x3bed85){const _0x1cef56=a805_0x3fd6;_0x3e3d89[_0x1cef56('0x2')](_0x48c21d,_0x3bed85);};}exports[_0x1c20ac('0x6')]=function(_0x21a4e3){const _0xd6790d=_0x1c20ac;for(let _0x5cd42c=0x0,_0x4f65a3=events['length'];_0x5cd42c<_0x4f65a3;_0x5cd42c++){const _0x337754=events[_0x5cd42c],_0x5263aa=createListener(_0xd6790d('0x1')+_0x337754,_0x21a4e3);WhatsappMessageEvents['on'](_0x337754,_0x5263aa);}}; \ No newline at end of file +const a805_0x4fc3=['./whatsappMessage.events','save','register','length','update'];(function(_0x16e450,_0x4fc3a2){const _0x2651ae=function(_0x160a58){while(--_0x160a58){_0x16e450['push'](_0x16e450['shift']());}};_0x2651ae(++_0x4fc3a2);}(a805_0x4fc3,0x119));const a805_0x2651=function(_0x16e450,_0x4fc3a2){_0x16e450=_0x16e450-0x0;let _0x2651ae=a805_0x4fc3[_0x16e450];return _0x2651ae;};const _0x5f3432=a805_0x2651;'use strict';const WhatsappMessageEvents=require(_0x5f3432('0x4')),events=[_0x5f3432('0x0'),'remove',_0x5f3432('0x3')];function createListener(_0x160a58,_0x2f20cd){return function(_0x5636b7){_0x2f20cd['emit'](_0x160a58,_0x5636b7);};}exports[_0x5f3432('0x1')]=function(_0x32afd2){const _0xeb7480=_0x5f3432;for(let _0x5b764b=0x0,_0x1cf21c=events[_0xeb7480('0x2')];_0x5b764b<_0x1cf21c;_0x5b764b++){const _0x4e4a8c=events[_0x5b764b],_0x583b3c=createListener('whatsappMessage:'+_0x4e4a8c,_0x32afd2);WhatsappMessageEvents['on'](_0x4e4a8c,_0x583b3c);}}; \ No newline at end of file diff --git a/server/api/whatsappQueue/index.js b/server/api/whatsappQueue/index.js index de3ffbc..5deeaaa 100644 --- a/server/api/whatsappQueue/index.js +++ b/server/api/whatsappQueue/index.js @@ -1 +1 @@ -const a806_0x4b13=['put','get','post','destroy','show','./whatsappQueue.controller','addTeams','getTeams','describe','/:id/teams','exports','Router','/:id','update','index','delete','/describe','isAuthenticated','../../components/auth/service','/:id/users','getMembers','addAgents'];(function(_0x8ae2c4,_0x4b1339){const _0x34a335=function(_0x557fc2){while(--_0x557fc2){_0x8ae2c4['push'](_0x8ae2c4['shift']());}};_0x34a335(++_0x4b1339);}(a806_0x4b13,0x113));const a806_0x34a3=function(_0x8ae2c4,_0x4b1339){_0x8ae2c4=_0x8ae2c4-0x0;let _0x34a335=a806_0x4b13[_0x8ae2c4];return _0x34a335;};const _0x112088=a806_0x34a3;'use strict';const express=require('express'),router=express[_0x112088('0x0')](),auth=require(_0x112088('0x7')),controller=require(_0x112088('0x10'));router[_0x112088('0xc')]('/',auth[_0x112088('0x6')](),controller[_0x112088('0x3')]),router[_0x112088('0xc')](_0x112088('0x5'),auth[_0x112088('0x6')](),controller[_0x112088('0x13')]),router['get'](_0x112088('0x1'),auth['isAuthenticated'](),controller[_0x112088('0xf')]),router[_0x112088('0xc')]('/:id/members',auth[_0x112088('0x6')](),controller[_0x112088('0x9')]),router[_0x112088('0xc')](_0x112088('0x14'),auth[_0x112088('0x6')](),controller[_0x112088('0x12')]),router[_0x112088('0xc')](_0x112088('0x8'),auth[_0x112088('0x6')](),controller['getAgents']),router[_0x112088('0xd')]('/',auth[_0x112088('0x6')](),controller['create']),router[_0x112088('0xd')](_0x112088('0x14'),auth[_0x112088('0x6')](),controller[_0x112088('0x11')]),router[_0x112088('0xd')](_0x112088('0x8'),auth['isAuthenticated'](),controller[_0x112088('0xa')]),router[_0x112088('0xb')]('/:id',auth[_0x112088('0x6')](),controller[_0x112088('0x2')]),router[_0x112088('0x4')](_0x112088('0x1'),auth['isAuthenticated'](),controller[_0x112088('0xe')]),router[_0x112088('0x4')](_0x112088('0x14'),auth[_0x112088('0x6')](),controller['removeTeams']),router[_0x112088('0x4')](_0x112088('0x8'),auth[_0x112088('0x6')](),controller['removeAgents']),module[_0x112088('0x15')]=router; \ No newline at end of file +const a806_0xf465=['/:id','delete','./whatsappQueue.controller','/:id/members','/describe','get','removeAgents','destroy','getAgents','express','addAgents','show','index','isAuthenticated','create','/:id/teams','put','/:id/users','../../components/auth/service','post','update','removeTeams','getMembers','getTeams'];(function(_0x47a420,_0xf46512){const _0x2d5092=function(_0x63376e){while(--_0x63376e){_0x47a420['push'](_0x47a420['shift']());}};_0x2d5092(++_0xf46512);}(a806_0xf465,0x9c));const a806_0x2d50=function(_0x47a420,_0xf46512){_0x47a420=_0x47a420-0x0;let _0x2d5092=a806_0xf465[_0x47a420];return _0x2d5092;};const _0x38dcb0=a806_0x2d50;'use strict';const express=require(_0x38dcb0('0x15')),router=express['Router'](),auth=require(_0x38dcb0('0x6')),controller=require(_0x38dcb0('0xe'));router[_0x38dcb0('0x11')]('/',auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0x0')]),router[_0x38dcb0('0x11')](_0x38dcb0('0x10'),auth[_0x38dcb0('0x1')](),controller['describe']),router[_0x38dcb0('0x11')](_0x38dcb0('0xc'),auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0x17')]),router['get'](_0x38dcb0('0xf'),auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0xa')]),router[_0x38dcb0('0x11')](_0x38dcb0('0x3'),auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0xb')]),router[_0x38dcb0('0x11')]('/:id/users',auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0x14')]),router[_0x38dcb0('0x7')]('/',auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0x2')]),router[_0x38dcb0('0x7')]('/:id/teams',auth[_0x38dcb0('0x1')](),controller['addTeams']),router[_0x38dcb0('0x7')](_0x38dcb0('0x5'),auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0x16')]),router[_0x38dcb0('0x4')](_0x38dcb0('0xc'),auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0x8')]),router[_0x38dcb0('0xd')](_0x38dcb0('0xc'),auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0x13')]),router[_0x38dcb0('0xd')](_0x38dcb0('0x3'),auth['isAuthenticated'](),controller[_0x38dcb0('0x9')]),router[_0x38dcb0('0xd')](_0x38dcb0('0x5'),auth[_0x38dcb0('0x1')](),controller[_0x38dcb0('0x12')]),module['exports']=router; \ No newline at end of file diff --git a/server/api/whatsappQueue/whatsappQueue.attributes.js b/server/api/whatsappQueue/whatsappQueue.attributes.js index 3a1b278..4d4a45a 100644 --- a/server/api/whatsappQueue/whatsappQueue.attributes.js +++ b/server/api/whatsappQueue/whatsappQueue.attributes.js @@ -1 +1 @@ -const a807_0x1d4a=['exports','STRING','INTEGER','rrmemory','name','roundrobin','beepall','ENUM'];(function(_0x28f6ea,_0x1d4a1a){const _0xf85e5b=function(_0x47cedd){while(--_0x47cedd){_0x28f6ea['push'](_0x28f6ea['shift']());}};_0xf85e5b(++_0x1d4a1a);}(a807_0x1d4a,0xf6));const a807_0xf85e=function(_0x28f6ea,_0x1d4a1a){_0x28f6ea=_0x28f6ea-0x0;let _0xf85e5b=a807_0x1d4a[_0x28f6ea];return _0xf85e5b;};const _0x2f9474=a807_0xf85e;'use strict';const Sequelize=require('sequelize');module[_0x2f9474('0x2')]={'name':{'type':Sequelize[_0x2f9474('0x3')],'unique':_0x2f9474('0x6'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'timeout':{'type':Sequelize[_0x2f9474('0x4')],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x2f9474('0x1')](_0x2f9474('0x5'),_0x2f9474('0x0'),_0x2f9474('0x7'))},'description':{'type':Sequelize['STRING']}}; \ No newline at end of file +const a807_0xea8f=['INTEGER','STRING','beepall','rrmemory','exports','ENUM','name','roundrobin'];(function(_0x22909f,_0xea8fee){const _0x197fa8=function(_0x5589b8){while(--_0x5589b8){_0x22909f['push'](_0x22909f['shift']());}};_0x197fa8(++_0xea8fee);}(a807_0xea8f,0x147));const a807_0x197f=function(_0x22909f,_0xea8fee){_0x22909f=_0x22909f-0x0;let _0x197fa8=a807_0xea8f[_0x22909f];return _0x197fa8;};const _0x3bfc38=a807_0x197f;'use strict';const Sequelize=require('sequelize');module[_0x3bfc38('0x5')]={'name':{'type':Sequelize[_0x3bfc38('0x2')],'unique':_0x3bfc38('0x7'),'validate':{'notEmpty':!![],'is':/^[A-Za-z0-9._]+$/i}},'timeout':{'type':Sequelize[_0x3bfc38('0x1')],'validate':{'min':0x1,'max':0x20c49b}},'strategy':{'type':Sequelize[_0x3bfc38('0x6')](_0x3bfc38('0x4'),_0x3bfc38('0x3'),_0x3bfc38('0x0'))},'description':{'type':Sequelize[_0x3bfc38('0x2')]}}; \ No newline at end of file diff --git a/server/api/whatsappQueue/whatsappQueue.controller.js b/server/api/whatsappQueue/whatsappQueue.controller.js index 35e3f9e..5058acb 100644 --- a/server/api/whatsappQueue/whatsappQueue.controller.js +++ b/server/api/whatsappQueue/whatsappQueue.controller.js @@ -1 +1 @@ -const a808_0x3af3=['fields','filters','query','model','create','WhatsappQueue','push','includes','destroy','emit','UserId','removeTeams','type','../../rediscache','compact','map','tq.TeamId','merge','filter','SIP','UserProfileSection','params','createdAt','count','whatsappPause','join','updatedAt','flatMap','order','rows','update','userWhatsappQueue:remove','userProfileId','keys','where','toString','userWhatsappQueue:save','findAll','addAgents','get','value','key','sendStatus','online','like','UserProfileResource','every','TeamId','Unable\x20to\x20retrieve\x20the\x20current\x20user','sequelize','findAndCountAll','getTeams','interface','fieldName','show','name','ut.UserId\x20=\x20?','forEach','error','length','VIRTUAL','findOne','Agents','WhatsappQueueId','util','UserWhatsappQueue','removeAgents','../../config/logger','attributes','ids','clone','then','rawAttributes','describe','Team','sort','ut.TeamId\x20=\x20tq.TeamId','role','end','../../mysqldb','user_has_teams','transaction','nolimit','select','addTeams','pick','index','getAgents','autoAssociation','catch','body','stack','limit','each','WhatsappQueueId\x20=\x20?','json','user','includeAll','all','status','offset','undefined','WhatsappQueues','options','User','intersection','isEmpty','union','set'];(function(_0x30a34c,_0x3af380){const _0x51e706=function(_0x1ae9a0){while(--_0x1ae9a0){_0x30a34c['push'](_0x30a34c['shift']());}};_0x51e706(++_0x3af380);}(a808_0x3af3,0x1e9));const a808_0x51e7=function(_0x30a34c,_0x3af380){_0x30a34c=_0x30a34c-0x0;let _0x51e706=a808_0x3af3[_0x30a34c];return _0x51e706;};const _0x36ee15=a808_0x51e7;'use strict';const util=require(_0x36ee15('0xb')),_=require('lodash'),squel=require('squel'),qs=require('../../components/parsers/qs'),logger=require(_0x36ee15('0xe'))('api'),{getSocket}=require(_0x36ee15('0x45')),socket=getSocket(),db=require(_0x36ee15('0x1a'))['db'],{Op,QueryTypes}=require('sequelize');require('./whatsappQueue.socket')['register'](socket);function respondWithStatusCode(_0x1ae9a0,_0x5e8e5d){return _0x5e8e5d=_0x5e8e5d||0xcc,function(_0x107267){const _0x1be7a2=a808_0x51e7;if(_0x107267)return _0x1ae9a0[_0x1be7a2('0x62')](_0x5e8e5d);return _0x1ae9a0[_0x1be7a2('0x2e')](_0x5e8e5d)[_0x1be7a2('0x19')]();};}function respondWithResult(_0x3027b9,_0x3f8c26){return _0x3f8c26=_0x3f8c26||0xc8,function(_0x941584){const _0x1898ee=a808_0x51e7;if(_0x941584)return _0x3027b9[_0x1898ee('0x2e')](_0x3f8c26)[_0x1898ee('0x2a')](_0x941584);};}function respondWithFilteredResult(_0x52a95e,_0x31fbe8){return function(_0x2ac629){const _0x6be954=a808_0x51e7;if(_0x2ac629){const _0x5db05d=_0x2ac629[_0x6be954('0x4f')],_0xa9c697=_0x31fbe8[_0x6be954('0x2f')];let _0x19c203=_0x31fbe8[_0x6be954('0x2f')]+_0x31fbe8['limit'],_0x145fe1;return _0x19c203>=_0x5db05d?(_0x19c203=_0x5db05d,_0x145fe1=0xc8):_0x145fe1=0xce,_0x52a95e[_0x6be954('0x2e')](_0x145fe1),_0x52a95e[_0x6be954('0x37')]('Content-Range',_0xa9c697+'-'+_0x19c203+'/'+_0x5db05d)[_0x6be954('0x2a')](_0x2ac629);}return null;};}function saveUpdates(_0x371c18){return function(_0x4a9aaf){const _0x36b314=a808_0x51e7;if(_0x4a9aaf)return _0x4a9aaf[_0x36b314('0x56')](_0x371c18)['then'](function(_0x4f0c98){return _0x4f0c98;});return null;};}function removeEntity(_0x4e3a68){return function(_0x1e5378){const _0x1fe798=a808_0x51e7;if(_0x1e5378)return _0x1e5378[_0x1fe798('0x40')]()['then'](function(){const _0x266c22=_0x1fe798,_0x1b691c=_0x1e5378[_0x266c22('0x5f')]({'plain':!![]}),_0x34cbf7=_0x266c22('0x31');return db[_0x266c22('0x65')]['destroy']({'where':{'type':_0x34cbf7,'resourceId':_0x1b691c['id']}})[_0x266c22('0x12')](function(){return _0x1e5378;});})['then'](function(){const _0x1f817f=_0x1fe798;_0x4e3a68[_0x1f817f('0x2e')](0xcc)[_0x1f817f('0x19')]();});};}function handleEntityNotFound(_0x1b55fc){return function(_0x3f837d){const _0x4a3db3=a808_0x51e7;return!_0x3f837d&&_0x1b55fc[_0x4a3db3('0x62')](0x194),_0x3f837d;};}function handleError(_0x19a680,_0x38c859){return _0x38c859=_0x38c859||0x1f4,function(_0x405af6){const _0x50df80=a808_0x51e7;logger[_0x50df80('0x5')](_0x405af6[_0x50df80('0x26')]),_0x405af6['name']&&delete _0x405af6[_0x50df80('0x2')],_0x19a680[_0x50df80('0x2e')](_0x38c859)['send'](_0x405af6);};}exports[_0x36ee15('0x21')]=function(_0x1e57df,_0x4836f7){const _0x34fa6e=_0x36ee15;let _0x10a619={};const _0x153e50={},_0x306b29={'count':0x0,'rows':[]},_0x305053=_[_0x34fa6e('0x47')](db['WhatsappQueue'][_0x34fa6e('0x13')],function(_0x24fd2b){const _0x4c7cd0=_0x34fa6e;return{'name':_0x24fd2b[_0x4c7cd0('0x0')],'type':_0x24fd2b[_0x4c7cd0('0x44')][_0x4c7cd0('0x61')]};});_0x153e50[_0x34fa6e('0x3b')]=_[_0x34fa6e('0x47')](_0x305053,_0x34fa6e('0x2')),_0x153e50[_0x34fa6e('0x3a')]=_[_0x34fa6e('0x59')](_0x1e57df[_0x34fa6e('0x3a')]),_0x153e50[_0x34fa6e('0x39')]=_[_0x34fa6e('0x34')](_0x153e50[_0x34fa6e('0x3b')],_0x153e50[_0x34fa6e('0x3a')]),_0x10a619[_0x34fa6e('0xf')]=_[_0x34fa6e('0x34')](_0x153e50[_0x34fa6e('0x3b')],qs['fields'](_0x1e57df[_0x34fa6e('0x3a')][_0x34fa6e('0x38')])),_0x10a619[_0x34fa6e('0xf')]=_0x10a619[_0x34fa6e('0xf')][_0x34fa6e('0x6')]?_0x10a619[_0x34fa6e('0xf')]:_0x153e50[_0x34fa6e('0x3b')];typeof _0x1e57df['query']['nolimit']===_0x34fa6e('0x30')&&(_0x10a619[_0x34fa6e('0x27')]=qs[_0x34fa6e('0x27')](_0x1e57df[_0x34fa6e('0x3a')][_0x34fa6e('0x27')]),_0x10a619['offset']=qs[_0x34fa6e('0x2f')](_0x1e57df[_0x34fa6e('0x3a')][_0x34fa6e('0x2f')]));_0x10a619[_0x34fa6e('0x54')]=qs['sort'](_0x1e57df[_0x34fa6e('0x3a')]['sort']),_0x10a619[_0x34fa6e('0x5a')]=qs[_0x34fa6e('0x39')](_[_0x34fa6e('0x20')](_0x1e57df[_0x34fa6e('0x3a')],_0x153e50['filters']),_0x305053);_0x1e57df[_0x34fa6e('0x3a')][_0x34fa6e('0x4a')]&&(_0x10a619[_0x34fa6e('0x5a')]=_['merge'](_0x10a619[_0x34fa6e('0x5a')],{[Op['or']]:_[_0x34fa6e('0x47')](_0x305053,function(_0x445c7d){const _0x1df53c=_0x34fa6e;if(_0x445c7d[_0x1df53c('0x44')]!==_0x1df53c('0x7')){const _0x44afc5={};return _0x44afc5[_0x445c7d[_0x1df53c('0x2')]]={[Op[_0x1df53c('0x64')]]:'%'+_0x1e57df[_0x1df53c('0x3a')][_0x1df53c('0x4a')]+'%'},_0x44afc5;}})}));_0x10a619=_['merge']({},_0x10a619,_0x1e57df[_0x34fa6e('0x32')]);const _0x3581c0={'where':_0x10a619[_0x34fa6e('0x5a')]};return db['WhatsappQueue'][_0x34fa6e('0x4f')](_0x3581c0)[_0x34fa6e('0x12')](function(_0x4c3dae){const _0x2cd25d=_0x34fa6e;return _0x306b29[_0x2cd25d('0x4f')]=_0x4c3dae,_0x1e57df['query'][_0x2cd25d('0x2c')]&&(_0x10a619['include']=[{'all':!![]}]),db[_0x2cd25d('0x3d')][_0x2cd25d('0x5d')](_0x10a619);})[_0x34fa6e('0x12')](function(_0x43ef6d){const _0x28e280=_0x34fa6e;return _0x306b29[_0x28e280('0x55')]=_0x43ef6d,_0x306b29;})[_0x34fa6e('0x12')](respondWithFilteredResult(_0x4836f7,_0x10a619))['catch'](handleError(_0x4836f7,null));},exports[_0x36ee15('0x1')]=function(_0xec46c5,_0x89ffd){const _0x307a1a=_0x36ee15;let _0x21f6a5={'raw':!![],'where':{'id':_0xec46c5['params']['id']}};const _0x446f9a={};return _0x446f9a['model']=_['keys'](db[_0x307a1a('0x3d')][_0x307a1a('0x13')]),_0x446f9a['query']=_['keys'](_0xec46c5['query']),_0x446f9a[_0x307a1a('0x39')]=_[_0x307a1a('0x34')](_0x446f9a[_0x307a1a('0x3b')],_0x446f9a[_0x307a1a('0x3a')]),_0x21f6a5[_0x307a1a('0xf')]=_['intersection'](_0x446f9a[_0x307a1a('0x3b')],qs[_0x307a1a('0x38')](_0xec46c5[_0x307a1a('0x3a')][_0x307a1a('0x38')])),_0x21f6a5['attributes']=_0x21f6a5['attributes']['length']?_0x21f6a5[_0x307a1a('0xf')]:_0x446f9a[_0x307a1a('0x3b')],_0xec46c5[_0x307a1a('0x3a')][_0x307a1a('0x2c')]&&(_0x21f6a5['include']=[{'all':!![]}]),_0x21f6a5=_['merge']({},_0x21f6a5,_0xec46c5['options']),db[_0x307a1a('0x3d')][_0x307a1a('0x8')](_0x21f6a5)[_0x307a1a('0x12')](handleEntityNotFound(_0x89ffd,null))['then'](respondWithResult(_0x89ffd,null))[_0x307a1a('0x24')](handleError(_0x89ffd,null));},exports['create']=function(_0x598036,_0x1a0c3d){const _0x2ce6b6=_0x36ee15;return db[_0x2ce6b6('0x3d')][_0x2ce6b6('0x3c')](_0x598036[_0x2ce6b6('0x25')],{})[_0x2ce6b6('0x12')](function(_0x4087a9){const _0x2bcf33=_0x2ce6b6,_0x321285=_0x598036[_0x2bcf33('0x2b')][_0x2bcf33('0x5f')]({'plain':!![]});if(!_0x321285)throw new Error(_0x2bcf33('0x68'));if(_0x321285[_0x2bcf33('0x18')]==='user'){const _0x1c0a62=_0x4087a9[_0x2bcf33('0x5f')]({'plain':!![]}),_0x5215ff=_0x2bcf33('0x31');return db[_0x2bcf33('0x4c')][_0x2bcf33('0x8')]({'where':{'name':_0x5215ff,'userProfileId':_0x321285[_0x2bcf33('0x58')]},'raw':!![]})[_0x2bcf33('0x12')](function(_0x32b9fa){const _0x38bc92=_0x2bcf33;return _0x32b9fa&&_0x32b9fa[_0x38bc92('0x23')]===0x0?db[_0x38bc92('0x65')]['create']({'name':_0x1c0a62[_0x38bc92('0x2')],'resourceId':_0x1c0a62['id'],'type':_0x32b9fa[_0x38bc92('0x2')],'sectionId':_0x32b9fa['id']},{})[_0x38bc92('0x12')](function(){return _0x4087a9;}):_0x4087a9;})[_0x2bcf33('0x24')](function(_0x545728){const _0x3d7c4e=_0x2bcf33;logger[_0x3d7c4e('0x5')]('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x545728);throw _0x545728;});}return _0x4087a9;})[_0x2ce6b6('0x12')](respondWithResult(_0x1a0c3d,0xc9))[_0x2ce6b6('0x24')](handleError(_0x1a0c3d,null));},exports['update']=function(_0x5c6c56,_0x2eba4e){const _0x3fb593=_0x36ee15;return _0x5c6c56['body']['id']&&delete _0x5c6c56[_0x3fb593('0x25')]['id'],db[_0x3fb593('0x3d')][_0x3fb593('0x8')]({'where':{'id':_0x5c6c56[_0x3fb593('0x4d')]['id']}})[_0x3fb593('0x12')](handleEntityNotFound(_0x2eba4e,null))[_0x3fb593('0x12')](saveUpdates(_0x5c6c56[_0x3fb593('0x25')],null))['then'](respondWithResult(_0x2eba4e,null))[_0x3fb593('0x24')](handleError(_0x2eba4e,null));},exports[_0x36ee15('0x40')]=function(_0x3fbd82,_0x1afd08){const _0x310cb6=_0x36ee15;return db['WhatsappQueue']['findOne']({'where':{'id':_0x3fbd82['params']['id']}})[_0x310cb6('0x12')](handleEntityNotFound(_0x1afd08,null))[_0x310cb6('0x12')](removeEntity(_0x1afd08,null))[_0x310cb6('0x24')](handleError(_0x1afd08,null));},exports[_0x36ee15('0x14')]=function(_0x48574d,_0x210a53){const _0x3736e0=_0x36ee15;return db[_0x3736e0('0x3d')]['describe']()[_0x3736e0('0x12')](respondWithResult(_0x210a53,null))[_0x3736e0('0x24')](handleError(_0x210a53,null));},exports['getMembers']=function(_0x4d6a53,_0x2a8dc8){const _0x41a38d=_0x36ee15;let _0x41d49f={'raw':!![],'where':{}};const _0x211dc3={};let _0x2af13d;return db[_0x41a38d('0x3d')][_0x41a38d('0x8')]({'where':{'id':_0x4d6a53[_0x41a38d('0x4d')]['id']}})['then'](handleEntityNotFound(_0x2a8dc8,null))['then'](function(_0x304c68){const _0x42e556=_0x41a38d;if(_0x304c68)return _0x2af13d=_0x304c68[_0x42e556('0x5f')]({'plain':!![]}),_0x211dc3['model']=_['keys'](db[_0x42e556('0xc')][_0x42e556('0x13')]),_0x211dc3[_0x42e556('0x3a')]=_[_0x42e556('0x59')](_0x4d6a53[_0x42e556('0x3a')]),_0x211dc3['filters']=_[_0x42e556('0x34')](_0x211dc3[_0x42e556('0x3b')],_0x211dc3[_0x42e556('0x3a')]),_0x41d49f['attributes']=_[_0x42e556('0x34')](_0x211dc3[_0x42e556('0x3b')],qs[_0x42e556('0x38')](_0x4d6a53[_0x42e556('0x3a')]['fields'])),_0x41d49f['attributes']=_0x41d49f['attributes'][_0x42e556('0x6')]?_0x41d49f['attributes']:_0x211dc3[_0x42e556('0x3b')],typeof _0x4d6a53[_0x42e556('0x3a')][_0x42e556('0x1d')]==='undefined'&&(_0x41d49f[_0x42e556('0x27')]=qs['limit'](_0x4d6a53['query'][_0x42e556('0x27')]),_0x41d49f['offset']=qs[_0x42e556('0x2f')](_0x4d6a53[_0x42e556('0x3a')][_0x42e556('0x2f')])),_0x41d49f[_0x42e556('0x54')]=qs[_0x42e556('0x16')](_0x4d6a53[_0x42e556('0x3a')][_0x42e556('0x16')]),_0x41d49f[_0x42e556('0x5a')]=qs[_0x42e556('0x39')](_[_0x42e556('0x20')](_0x4d6a53['query'],_0x211dc3[_0x42e556('0x39')])),_0x41d49f[_0x42e556('0x5a')][_0x42e556('0xa')]=_0x304c68['id'],_0x4d6a53['query'][_0x42e556('0x4a')]&&(_0x41d49f[_0x42e556('0x5a')]=_[_0x42e556('0x49')](_0x41d49f[_0x42e556('0x5a')],{[Op['or']]:_[_0x42e556('0x47')](_0x41d49f[_0x42e556('0xf')],function(_0x56e507){const _0x2408d7=_0x42e556,_0x101749={};return _0x101749[_0x56e507]={[Op['like']]:'%'+_0x4d6a53['query'][_0x2408d7('0x4a')]+'%'},_0x101749;})})),_0x41d49f=_[_0x42e556('0x49')]({},_0x41d49f,_0x4d6a53['options']),db['UserWhatsappQueue']['findAll'](_0x41d49f);})[_0x41a38d('0x12')](function(_0x5b449e){const _0x18fae2=_0x41a38d;if(_0x5b449e)return db[_0x18fae2('0x33')][_0x18fae2('0x6a')]({'where':{'id':_[_0x18fae2('0x47')](_0x5b449e,_0x18fae2('0x42')),'role':'agent'},'attributes':['id',_0x18fae2('0x2'),_0x18fae2('0x50'),'updatedAt',_0x18fae2('0x4e')]});})['then'](function(_0xa898b5){const _0x129dc4=_0x41a38d;return _0xa898b5?{'count':_0xa898b5[_0x129dc4('0x4f')],'rows':_[_0x129dc4('0x47')](_0xa898b5[_0x129dc4('0x55')],function(_0x58b299){const _0x585df3=_0x129dc4;return{'membername':_0x58b299[_0x585df3('0x2')],'UserId':_0x58b299['id'],'queue_name':_0x2af13d[_0x585df3('0x2')],'WhatsappQueueId':_0x2af13d['id'],'interface':util['format']('%s/%s',_0x585df3('0x4b'),_0x58b299['name']),'penalty':0x0,'paused':_0x58b299[_0x585df3('0x50')],'createdAt':_0x58b299[_0x585df3('0x4e')],'updatedAt':_0x58b299[_0x585df3('0x52')]};})}:{'count':0x0,'rows':[]};})[_0x41a38d('0x12')](respondWithFilteredResult(_0x2a8dc8,_0x41d49f))[_0x41a38d('0x24')](handleError(_0x2a8dc8,null));},exports[_0x36ee15('0x6b')]=function(_0x9f63b6,_0x23fadf){const _0x219e35=_0x36ee15;let _0x45fc13={};const _0x304b68={};let _0xc00a79,_0x17d855;return db[_0x219e35('0x3d')]['findOne']({'where':{'id':_0x9f63b6[_0x219e35('0x4d')]['id']}})['then'](handleEntityNotFound(_0x23fadf,null))[_0x219e35('0x12')](function(_0x4a2623){const _0x512b20=_0x219e35;if(_0x4a2623)return _0xc00a79=_0x4a2623,_0x304b68['model']=_[_0x512b20('0x59')](db[_0x512b20('0x15')][_0x512b20('0x13')]),_0x304b68[_0x512b20('0x3a')]=_[_0x512b20('0x59')](_0x9f63b6[_0x512b20('0x3a')]),_0x304b68[_0x512b20('0x39')]=_[_0x512b20('0x34')](_0x304b68[_0x512b20('0x3b')],_0x304b68[_0x512b20('0x3a')]),_0x45fc13[_0x512b20('0xf')]=_[_0x512b20('0x34')](_0x304b68['model'],qs['fields'](_0x9f63b6['query'][_0x512b20('0x38')])),_0x45fc13[_0x512b20('0xf')]=_0x45fc13[_0x512b20('0xf')][_0x512b20('0x6')]?_0x45fc13[_0x512b20('0xf')]:_0x304b68['model'],_0x45fc13[_0x512b20('0x54')]=qs[_0x512b20('0x16')](_0x9f63b6[_0x512b20('0x3a')][_0x512b20('0x16')]),_0x45fc13['where']=qs['filters'](_[_0x512b20('0x20')](_0x9f63b6['query'],_0x304b68[_0x512b20('0x39')])),_0x9f63b6[_0x512b20('0x3a')]['filter']&&(_0x45fc13[_0x512b20('0x5a')]=_[_0x512b20('0x49')](_0x45fc13['where'],{[Op['or']]:_[_0x512b20('0x47')](_0x45fc13['attributes'],function(_0x22be4e){const _0x2d7d23=_0x512b20,_0x7f8ea1={};return _0x7f8ea1[_0x22be4e]={[Op[_0x2d7d23('0x64')]]:'%'+_0x9f63b6['query'][_0x2d7d23('0x4a')]+'%'},_0x7f8ea1;})})),_0x45fc13=_[_0x512b20('0x49')]({},_0x45fc13,_0x9f63b6[_0x512b20('0x32')]),_0xc00a79['getTeams'](_0x45fc13);})['then'](function(_0x130c6e){const _0x54163d=_0x219e35;if(_0x130c6e)return _0x17d855=_0x130c6e[_0x54163d('0x6')],typeof _0x9f63b6[_0x54163d('0x3a')]['nolimit']==='undefined'&&(_0x45fc13[_0x54163d('0x27')]=qs[_0x54163d('0x27')](_0x9f63b6[_0x54163d('0x3a')][_0x54163d('0x27')]),_0x45fc13[_0x54163d('0x2f')]=qs[_0x54163d('0x2f')](_0x9f63b6[_0x54163d('0x3a')][_0x54163d('0x2f')])),_0xc00a79['getTeams'](_0x45fc13);})[_0x219e35('0x12')](function(_0x497911){if(_0x497911)return _0x497911?{'count':_0x17d855,'rows':_0x497911}:null;})['then'](respondWithResult(_0x23fadf,null))['catch'](handleError(_0x23fadf,null));},exports[_0x36ee15('0x1f')]=function(_0x5edd01,_0x5ba52c){const _0x47f985=_0x36ee15,_0x3cfde8=_0x5edd01[_0x47f985('0x25')][_0x47f985('0x10')];return db[_0x47f985('0x15')][_0x47f985('0x5d')]({'where':{'id':_0x3cfde8},'attributes':['id'],'include':[{'model':db['User'],'as':_0x47f985('0x9'),'attributes':['id',_0x47f985('0x2'),_0x47f985('0x63'),'voicePause',_0x47f985('0x6c')],'raw':!![]}]})['then'](function(_0x3a8e48){const _0x2c2cd5=_0x47f985;if(_0x3a8e48){const _0x5f0bd3=_[_0x2c2cd5('0x53')](_0x3a8e48,function(_0x3bbfb9){const _0x2309c8=_0x2c2cd5,_0x48b756=_0x3bbfb9[_0x2309c8('0x5f')]({'plain':!![]});return _0x48b756[_0x2309c8('0x9')];});return db['WhatsappQueue']['findOne']({'where':{'id':_0x5edd01[_0x2c2cd5('0x4d')]['id']}})[_0x2c2cd5('0x12')](function(_0x2cef40){const _0x23a142=_0x2c2cd5;return db[_0x23a142('0x69')]['transaction'](function(_0xb7c7cb){const _0x490977=_0x23a142;return _0x2cef40[_0x490977('0x1f')](_0x3cfde8,{'transaction':_0xb7c7cb})['then'](function(){const _0x3b5e70=_0x490977;return Promise[_0x3b5e70('0x28')](_0x5f0bd3,function(_0x17bc35){const _0x57815d=_0x3b5e70;return db[_0x57815d('0xc')]['findOrCreate']({'where':{'UserId':_0x17bc35['id'],'WhatsappQueueId':_0x5edd01[_0x57815d('0x4d')]['id']},'transaction':_0xb7c7cb});});})[_0x490977('0x12')](function(){_0x5f0bd3['forEach'](function(_0x3e24d7){const _0x59e681=a808_0x51e7;socket[_0x59e681('0x41')](_0x59e681('0x5c'),{'UserId':_0x3e24d7['id'],'WhatsappQueueId':_0x2cef40['id']});});});});});}})[_0x47f985('0x12')](respondWithStatusCode(_0x5ba52c,null))[_0x47f985('0x24')](handleError(_0x5ba52c,null));},exports['removeTeams']=function(_0x4466fd,_0x194650){const _0x21fbd0=_0x36ee15;return db['Team'][_0x21fbd0('0x5d')]({'where':{'id':_0x4466fd[_0x21fbd0('0x3a')]['ids']},'attributes':['id'],'include':[{'model':db[_0x21fbd0('0x33')],'as':_0x21fbd0('0x9'),'attributes':['id'],'raw':!![]}]})['then'](handleEntityNotFound(_0x194650,null))[_0x21fbd0('0x12')](function(_0x4ae4a8){const _0x211746=_0x21fbd0,_0x1a9753=_[_0x211746('0x47')](_0x4ae4a8,'id');let _0x2ca35d=[];const _0x26074c=[],_0x1b5592=squel[_0x211746('0x1e')]();_0x1b5592['field'](_0x211746('0x48'))['from']('team_has_whatsapp_queues','tq')[_0x211746('0x51')](_0x211746('0x1b'),'ut',_0x211746('0x17'))[_0x211746('0x5a')](_0x211746('0x29'),_0x4466fd['params']['id']);for(let _0x2e13cc=0x0;_0x2e13cc<_0x4ae4a8['length'];_0x2e13cc+=0x1){const _0x392076=_0x4ae4a8[_0x2e13cc];for(let _0x20152b=0x0;_0x20152b<_0x392076[_0x211746('0x9')]['length'];_0x20152b+=0x1){const _0x1ab174=_0x392076['Agents'][_0x20152b],_0x2e218d=_0x1b5592[_0x211746('0x11')]();_0x2e218d[_0x211746('0x5a')](_0x211746('0x3'),_0x1ab174['id']),_0x26074c[_0x211746('0x3e')](db['sequelize'][_0x211746('0x3a')](_0x2e218d[_0x211746('0x5b')](),{'type':QueryTypes['SELECT']})[_0x211746('0x12')](function(_0x3047b3){const _0x54a720=_0x211746;if(_0x3047b3[_0x54a720('0x6')]===0x1)return _0x1ab174['id'];else{const _0x3f40ec=_[_0x54a720('0x66')](_['map'](_0x3047b3,_0x54a720('0x67')),function(_0x4898b7){const _0x65e8e8=_0x54a720;return _[_0x65e8e8('0x3f')](_0x1a9753,_0x4898b7);});if(_0x3f40ec)return _0x1ab174['id'];}}));}}return Promise[_0x211746('0x2d')](_0x26074c)[_0x211746('0x12')](function(_0x334847){const _0x48b5d5=_0x211746;return _0x2ca35d=_(_0x2ca35d)[_0x48b5d5('0x36')](_0x334847)[_0x48b5d5('0x46')]()[_0x48b5d5('0x60')](),db[_0x48b5d5('0x3d')]['findOne']({'where':{'id':_0x4466fd[_0x48b5d5('0x4d')]['id']}})[_0x48b5d5('0x12')](function(_0x2288f0){const _0x40b93c=_0x48b5d5;return db['sequelize'][_0x40b93c('0x1c')](function(_0x4fada8){const _0x969dcd=_0x40b93c;return _0x2288f0[_0x969dcd('0x43')](_0x4466fd[_0x969dcd('0x3a')][_0x969dcd('0x10')],{'transaction':_0x4fada8})[_0x969dcd('0x12')](function(){const _0x546bda=_0x969dcd;if(!_[_0x546bda('0x35')](_0x2ca35d))return _0x2288f0[_0x546bda('0xd')](_0x2ca35d,{'transaction':_0x4fada8});})[_0x969dcd('0x12')](function(){const _0x437db2=_0x969dcd;_0x2ca35d[_0x437db2('0x4')](function(_0xfbada6){const _0x2d658d=_0x437db2;socket['emit'](_0x2d658d('0x57'),{'UserId':_0xfbada6,'WhatsappQueueId':_0x2288f0['id']});});});});});});})[_0x21fbd0('0x12')](respondWithStatusCode(_0x194650,null))[_0x21fbd0('0x24')](handleError(_0x194650,null));},exports['addAgents']=function(_0x211449,_0x331986){const _0x249ca4=_0x36ee15;return db[_0x249ca4('0x3d')][_0x249ca4('0x8')]({'where':{'id':_0x211449['params']['id']}})[_0x249ca4('0x12')](function(_0x97a255){const _0x20af6b=_0x249ca4;if(_0x97a255)return _0x97a255[_0x20af6b('0x5e')](_0x211449[_0x20af6b('0x25')]['ids'],{'through':_['omit'](_0x211449[_0x20af6b('0x25')],[_0x20af6b('0x10'),'id'])})[_0x20af6b('0x12')](function(_0x1d9e49){const _0x30d317=_0x20af6b;for(let _0x37b2bb=0x0;_0x37b2bb<_0x211449[_0x30d317('0x25')][_0x30d317('0x10')]['length'];_0x37b2bb+=0x1){socket[_0x30d317('0x41')](_0x30d317('0x5c'),{'UserId':_0x211449[_0x30d317('0x25')][_0x30d317('0x10')][_0x37b2bb],'WhatsappQueueId':_0x211449[_0x30d317('0x4d')]['id']});}return _0x1d9e49;});})[_0x249ca4('0x12')](respondWithResult(_0x331986,null))[_0x249ca4('0x24')](handleError(_0x331986,null));},exports[_0x36ee15('0xd')]=function(_0x2c5ab4,_0x324a47){const _0x30f665=_0x36ee15;return db['WhatsappQueue'][_0x30f665('0x8')]({'where':{'id':_0x2c5ab4[_0x30f665('0x4d')]['id']}})[_0x30f665('0x12')](handleEntityNotFound(_0x324a47,null))[_0x30f665('0x12')](function(_0x2fb955){const _0x4520fb=_0x30f665;if(_0x2fb955)return _0x2fb955[_0x4520fb('0xd')](_0x2c5ab4['query'][_0x4520fb('0x10')])[_0x4520fb('0x12')](function(){const _0x138755=_0x4520fb;if(_['isArray'](_0x2c5ab4['query'][_0x138755('0x10')]))for(let _0x2291d0=0x0;_0x2291d0<_0x2c5ab4[_0x138755('0x3a')][_0x138755('0x10')][_0x138755('0x6')];_0x2291d0+=0x1){socket[_0x138755('0x41')](_0x138755('0x57'),{'UserId':Number(_0x2c5ab4[_0x138755('0x3a')]['ids'][_0x2291d0]),'WhatsappQueueId':Number(_0x2c5ab4[_0x138755('0x4d')]['id'])});}else socket[_0x138755('0x41')]('userWhatsappQueue:remove',{'UserId':Number(_0x2c5ab4['query']['ids']),'WhatsappQueueId':Number(_0x2c5ab4['params']['id'])});});})[_0x30f665('0x12')](respondWithStatusCode(_0x324a47,null))[_0x30f665('0x24')](handleError(_0x324a47,null));},exports['getAgents']=function(_0x445d48,_0x3c876a){const _0x422ec6=_0x36ee15;let _0x221913={};const _0x40b752={};let _0x19a7bf,_0x10f58e;return db['WhatsappQueue'][_0x422ec6('0x8')]({'where':{'id':_0x445d48['params']['id']}})[_0x422ec6('0x12')](handleEntityNotFound(_0x3c876a,null))[_0x422ec6('0x12')](function(_0xc76194){const _0x5a8768=_0x422ec6;if(_0xc76194)return _0x19a7bf=_0xc76194,_0x40b752[_0x5a8768('0x3b')]=_['keys'](db[_0x5a8768('0x33')][_0x5a8768('0x13')]),_0x40b752['query']=_[_0x5a8768('0x59')](_0x445d48[_0x5a8768('0x3a')]),_0x40b752['filters']=_['intersection'](_0x40b752[_0x5a8768('0x3b')],_0x40b752['query']),_0x221913[_0x5a8768('0xf')]=_[_0x5a8768('0x34')](_0x40b752[_0x5a8768('0x3b')],qs[_0x5a8768('0x38')](_0x445d48[_0x5a8768('0x3a')][_0x5a8768('0x38')])),_0x221913['attributes']=_0x221913['attributes']['length']?_0x221913[_0x5a8768('0xf')]:_0x40b752[_0x5a8768('0x3b')],_0x221913[_0x5a8768('0x54')]=qs[_0x5a8768('0x16')](_0x445d48[_0x5a8768('0x3a')][_0x5a8768('0x16')]),_0x221913['where']=qs[_0x5a8768('0x39')](_[_0x5a8768('0x20')](_0x445d48[_0x5a8768('0x3a')],_0x40b752[_0x5a8768('0x39')])),_0x445d48['query'][_0x5a8768('0x4a')]&&(_0x221913[_0x5a8768('0x5a')]=_[_0x5a8768('0x49')](_0x221913[_0x5a8768('0x5a')],{[Op['or']]:_[_0x5a8768('0x47')](_0x221913[_0x5a8768('0xf')],function(_0x1c630e){const _0x5a4d0f=_0x5a8768,_0x4b3ef0={};return _0x4b3ef0[_0x1c630e]={[Op[_0x5a4d0f('0x64')]]:'%'+_0x445d48[_0x5a4d0f('0x3a')]['filter']+'%'},_0x4b3ef0;})})),_0x221913=_['merge']({},_0x221913,_0x445d48[_0x5a8768('0x32')]),_0x19a7bf['getAgents'](_0x221913);})['then'](function(_0x5baaca){const _0x545a3e=_0x422ec6;if(_0x5baaca)return _0x10f58e=_0x5baaca[_0x545a3e('0x6')],typeof _0x445d48['query']['nolimit']===_0x545a3e('0x30')&&(_0x221913['limit']=qs['limit'](_0x445d48[_0x545a3e('0x3a')][_0x545a3e('0x27')]),_0x221913[_0x545a3e('0x2f')]=qs['offset'](_0x445d48[_0x545a3e('0x3a')][_0x545a3e('0x2f')])),_0x19a7bf[_0x545a3e('0x22')](_0x221913);})['then'](function(_0x941063){if(_0x941063)return _0x941063?{'count':_0x10f58e,'rows':_0x941063}:null;})[_0x422ec6('0x12')](respondWithResult(_0x3c876a,null))[_0x422ec6('0x24')](handleError(_0x3c876a,null));}; \ No newline at end of file +const a808_0xf1da=['UserWhatsappQueue','compact','findOne','userWhatsappQueue:save','WhatsappQueueId','addAgents','Team','describe','team_has_whatsapp_queues','TeamId','error','body','../../mysqldb','UserProfileSection','send','intersection','lodash','autoAssociation','Content-Range','../../components/parsers/qs','Agents','count','updatedAt','findAll','tq.TeamId','Unable\x20to\x20retrieve\x20the\x20current\x20user','push','set','end','transaction','where','userProfileId','map','stack','undefined','SIP','value','util','key','offset','api','order','online','removeAgents','index','omit','userWhatsappQueue:remove','removeTeams','includeAll','WhatsappQueues','rows','%s/%s','destroy','format','options','sort','params','join','model','register','sendStatus','User','getTeams','then','filter','status','catch','create','include','createdAt','ut.UserId\x20=\x20?','fieldName','update','role','nolimit','like','includes','get','query','UserId','fields','./whatsappQueue.socket','WhatsappQueue','isArray','whatsappPause','name','agent','ids','each','getAgents','type','clone','pick','findAndCountAll','findOrCreate','sequelize','emit','attributes','limit','user','squel','filters','merge','keys','all','length','ut.TeamId\x20=\x20tq.TeamId','WhatsappQueueId\x20=\x20?','rawAttributes'];(function(_0x1b602f,_0xf1dadf){const _0x3d3cff=function(_0x157fe5){while(--_0x157fe5){_0x1b602f['push'](_0x1b602f['shift']());}};_0x3d3cff(++_0xf1dadf);}(a808_0xf1da,0x1a8));const a808_0x3d3c=function(_0x1b602f,_0xf1dadf){_0x1b602f=_0x1b602f-0x0;let _0x3d3cff=a808_0xf1da[_0x1b602f];return _0x3d3cff;};const _0x295ae9=a808_0x3d3c;'use strict';const util=require(_0x295ae9('0x31')),_=require(_0x295ae9('0x1c')),squel=require(_0x295ae9('0x3')),qs=require(_0x295ae9('0x1f')),logger=require('../../config/logger')(_0x295ae9('0x34')),{getSocket}=require('../../rediscache'),socket=getSocket(),db=require(_0x295ae9('0x18'))['db'],{Op,QueryTypes}=require(_0x295ae9('0x6b'));require(_0x295ae9('0x5d'))[_0x295ae9('0x47')](socket);function respondWithStatusCode(_0x157fe5,_0x33a33f){return _0x33a33f=_0x33a33f||0xcc,function(_0xf0b592){const _0x41449a=a808_0x3d3c;if(_0xf0b592)return _0x157fe5[_0x41449a('0x48')](_0x33a33f);return _0x157fe5['status'](_0x33a33f)[_0x41449a('0x28')]();};}function respondWithResult(_0x1427f7,_0x39ae93){return _0x39ae93=_0x39ae93||0xc8,function(_0x26372e){const _0x552768=a808_0x3d3c;if(_0x26372e)return _0x1427f7[_0x552768('0x4d')](_0x39ae93)['json'](_0x26372e);};}function respondWithFilteredResult(_0x36dd1d,_0x49b777){return function(_0x29164a){const _0x27cbae=a808_0x3d3c;if(_0x29164a){const _0x358efe=_0x29164a[_0x27cbae('0x21')],_0x31aba2=_0x49b777[_0x27cbae('0x33')];let _0x26ea7c=_0x49b777[_0x27cbae('0x33')]+_0x49b777[_0x27cbae('0x1')],_0x478a10;return _0x26ea7c>=_0x358efe?(_0x26ea7c=_0x358efe,_0x478a10=0xc8):_0x478a10=0xce,_0x36dd1d[_0x27cbae('0x4d')](_0x478a10),_0x36dd1d[_0x27cbae('0x27')](_0x27cbae('0x1e'),_0x31aba2+'-'+_0x26ea7c+'/'+_0x358efe)['json'](_0x29164a);}return null;};}function saveUpdates(_0x457111){return function(_0x5c598f){const _0x4049fc=a808_0x3d3c;if(_0x5c598f)return _0x5c598f[_0x4049fc('0x54')](_0x457111)[_0x4049fc('0x4b')](function(_0x367f6f){return _0x367f6f;});return null;};}function removeEntity(_0x3efb23){return function(_0x5f0b17){if(_0x5f0b17)return _0x5f0b17['destroy']()['then'](function(){const _0x570a95=a808_0x3d3c,_0x5894b7=_0x5f0b17[_0x570a95('0x59')]({'plain':!![]}),_0x760e75=_0x570a95('0x3d');return db['UserProfileResource'][_0x570a95('0x40')]({'where':{'type':_0x760e75,'resourceId':_0x5894b7['id']}})[_0x570a95('0x4b')](function(){return _0x5f0b17;});})['then'](function(){const _0x1c6af2=a808_0x3d3c;_0x3efb23[_0x1c6af2('0x4d')](0xcc)[_0x1c6af2('0x28')]();});};}function handleEntityNotFound(_0x1b3e80){return function(_0x438880){const _0x477533=a808_0x3d3c;return!_0x438880&&_0x1b3e80[_0x477533('0x48')](0x194),_0x438880;};}function handleError(_0x14c142,_0x3a1ee4){return _0x3a1ee4=_0x3a1ee4||0x1f4,function(_0x136d90){const _0x147234=a808_0x3d3c;logger[_0x147234('0x16')](_0x136d90[_0x147234('0x2d')]),_0x136d90['name']&&delete _0x136d90['name'],_0x14c142[_0x147234('0x4d')](_0x3a1ee4)[_0x147234('0x1a')](_0x136d90);};}exports[_0x295ae9('0x38')]=function(_0x4ea368,_0x351f9a){const _0xff9ece=_0x295ae9;let _0x421856={};const _0x3ed641={},_0x547dd7={'count':0x0,'rows':[]},_0x49558f=_['map'](db[_0xff9ece('0x5e')]['rawAttributes'],function(_0x5a1a56){const _0x33f542=_0xff9ece;return{'name':_0x5a1a56[_0x33f542('0x53')],'type':_0x5a1a56[_0x33f542('0x66')][_0x33f542('0x32')]};});_0x3ed641[_0xff9ece('0x46')]=_[_0xff9ece('0x2c')](_0x49558f,'name'),_0x3ed641['query']=_['keys'](_0x4ea368[_0xff9ece('0x5a')]),_0x3ed641['filters']=_['intersection'](_0x3ed641[_0xff9ece('0x46')],_0x3ed641[_0xff9ece('0x5a')]),_0x421856[_0xff9ece('0x0')]=_[_0xff9ece('0x1b')](_0x3ed641[_0xff9ece('0x46')],qs['fields'](_0x4ea368[_0xff9ece('0x5a')][_0xff9ece('0x5c')])),_0x421856[_0xff9ece('0x0')]=_0x421856[_0xff9ece('0x0')][_0xff9ece('0x8')]?_0x421856['attributes']:_0x3ed641['model'];typeof _0x4ea368[_0xff9ece('0x5a')][_0xff9ece('0x56')]==='undefined'&&(_0x421856[_0xff9ece('0x1')]=qs[_0xff9ece('0x1')](_0x4ea368['query'][_0xff9ece('0x1')]),_0x421856['offset']=qs[_0xff9ece('0x33')](_0x4ea368[_0xff9ece('0x5a')][_0xff9ece('0x33')]));_0x421856[_0xff9ece('0x35')]=qs[_0xff9ece('0x43')](_0x4ea368[_0xff9ece('0x5a')][_0xff9ece('0x43')]),_0x421856['where']=qs[_0xff9ece('0x4')](_['pick'](_0x4ea368[_0xff9ece('0x5a')],_0x3ed641[_0xff9ece('0x4')]),_0x49558f);_0x4ea368[_0xff9ece('0x5a')][_0xff9ece('0x4c')]&&(_0x421856[_0xff9ece('0x2a')]=_[_0xff9ece('0x5')](_0x421856[_0xff9ece('0x2a')],{[Op['or']]:_[_0xff9ece('0x2c')](_0x49558f,function(_0x5afaae){const _0x2f48d6=_0xff9ece;if(_0x5afaae['type']!=='VIRTUAL'){const _0x429076={};return _0x429076[_0x5afaae[_0x2f48d6('0x61')]]={[Op[_0x2f48d6('0x57')]]:'%'+_0x4ea368[_0x2f48d6('0x5a')]['filter']+'%'},_0x429076;}})}));_0x421856=_['merge']({},_0x421856,_0x4ea368[_0xff9ece('0x42')]);const _0x5501bb={'where':_0x421856[_0xff9ece('0x2a')]};return db[_0xff9ece('0x5e')][_0xff9ece('0x21')](_0x5501bb)[_0xff9ece('0x4b')](function(_0x1f8282){const _0x25482a=_0xff9ece;return _0x547dd7['count']=_0x1f8282,_0x4ea368[_0x25482a('0x5a')][_0x25482a('0x3c')]&&(_0x421856[_0x25482a('0x50')]=[{'all':!![]}]),db[_0x25482a('0x5e')][_0x25482a('0x23')](_0x421856);})[_0xff9ece('0x4b')](function(_0x5f5406){const _0x126174=_0xff9ece;return _0x547dd7[_0x126174('0x3e')]=_0x5f5406,_0x547dd7;})['then'](respondWithFilteredResult(_0x351f9a,_0x421856))[_0xff9ece('0x4e')](handleError(_0x351f9a,null));},exports['show']=function(_0x2a2de8,_0x5e861d){const _0x1b7edc=_0x295ae9;let _0x1fcccc={'raw':!![],'where':{'id':_0x2a2de8[_0x1b7edc('0x44')]['id']}};const _0x160c65={};return _0x160c65[_0x1b7edc('0x46')]=_[_0x1b7edc('0x6')](db[_0x1b7edc('0x5e')]['rawAttributes']),_0x160c65[_0x1b7edc('0x5a')]=_[_0x1b7edc('0x6')](_0x2a2de8[_0x1b7edc('0x5a')]),_0x160c65['filters']=_['intersection'](_0x160c65[_0x1b7edc('0x46')],_0x160c65[_0x1b7edc('0x5a')]),_0x1fcccc[_0x1b7edc('0x0')]=_[_0x1b7edc('0x1b')](_0x160c65[_0x1b7edc('0x46')],qs[_0x1b7edc('0x5c')](_0x2a2de8[_0x1b7edc('0x5a')][_0x1b7edc('0x5c')])),_0x1fcccc[_0x1b7edc('0x0')]=_0x1fcccc[_0x1b7edc('0x0')]['length']?_0x1fcccc[_0x1b7edc('0x0')]:_0x160c65[_0x1b7edc('0x46')],_0x2a2de8[_0x1b7edc('0x5a')][_0x1b7edc('0x3c')]&&(_0x1fcccc['include']=[{'all':!![]}]),_0x1fcccc=_[_0x1b7edc('0x5')]({},_0x1fcccc,_0x2a2de8[_0x1b7edc('0x42')]),db[_0x1b7edc('0x5e')]['findOne'](_0x1fcccc)[_0x1b7edc('0x4b')](handleEntityNotFound(_0x5e861d,null))['then'](respondWithResult(_0x5e861d,null))[_0x1b7edc('0x4e')](handleError(_0x5e861d,null));},exports[_0x295ae9('0x4f')]=function(_0x388452,_0x258a9f){const _0x38f31d=_0x295ae9;return db['WhatsappQueue'][_0x38f31d('0x4f')](_0x388452[_0x38f31d('0x17')],{})['then'](function(_0x495db0){const _0x540344=_0x38f31d,_0x2e0f35=_0x388452[_0x540344('0x2')]['get']({'plain':!![]});if(!_0x2e0f35)throw new Error(_0x540344('0x25'));if(_0x2e0f35[_0x540344('0x55')]===_0x540344('0x2')){const _0x33f68a=_0x495db0['get']({'plain':!![]}),_0x52a852='WhatsappQueues';return db[_0x540344('0x19')][_0x540344('0xe')]({'where':{'name':_0x52a852,'userProfileId':_0x2e0f35[_0x540344('0x2b')]},'raw':!![]})['then'](function(_0x379760){const _0x1f5957=_0x540344;return _0x379760&&_0x379760[_0x1f5957('0x1d')]===0x0?db['UserProfileResource'][_0x1f5957('0x4f')]({'name':_0x33f68a[_0x1f5957('0x61')],'resourceId':_0x33f68a['id'],'type':_0x379760[_0x1f5957('0x61')],'sectionId':_0x379760['id']},{})[_0x1f5957('0x4b')](function(){return _0x495db0;}):_0x495db0;})[_0x540344('0x4e')](function(_0x4d1fd2){logger['error']('Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s',_0x4d1fd2);throw _0x4d1fd2;});}return _0x495db0;})[_0x38f31d('0x4b')](respondWithResult(_0x258a9f,0xc9))[_0x38f31d('0x4e')](handleError(_0x258a9f,null));},exports[_0x295ae9('0x54')]=function(_0x4ae29b,_0x3db89f){const _0x2b5287=_0x295ae9;return _0x4ae29b['body']['id']&&delete _0x4ae29b[_0x2b5287('0x17')]['id'],db[_0x2b5287('0x5e')][_0x2b5287('0xe')]({'where':{'id':_0x4ae29b[_0x2b5287('0x44')]['id']}})[_0x2b5287('0x4b')](handleEntityNotFound(_0x3db89f,null))[_0x2b5287('0x4b')](saveUpdates(_0x4ae29b[_0x2b5287('0x17')],null))[_0x2b5287('0x4b')](respondWithResult(_0x3db89f,null))[_0x2b5287('0x4e')](handleError(_0x3db89f,null));},exports[_0x295ae9('0x40')]=function(_0x4ed01a,_0x537ce3){const _0x3dba9d=_0x295ae9;return db[_0x3dba9d('0x5e')][_0x3dba9d('0xe')]({'where':{'id':_0x4ed01a[_0x3dba9d('0x44')]['id']}})['then'](handleEntityNotFound(_0x537ce3,null))[_0x3dba9d('0x4b')](removeEntity(_0x537ce3,null))[_0x3dba9d('0x4e')](handleError(_0x537ce3,null));},exports[_0x295ae9('0x13')]=function(_0x594a46,_0x5f18f4){const _0x43b800=_0x295ae9;return db[_0x43b800('0x5e')]['describe']()[_0x43b800('0x4b')](respondWithResult(_0x5f18f4,null))[_0x43b800('0x4e')](handleError(_0x5f18f4,null));},exports['getMembers']=function(_0x21e5bf,_0x2dd573){const _0x58b814=_0x295ae9;let _0x4ca95c={'raw':!![],'where':{}};const _0x529602={};let _0xd54120;return db[_0x58b814('0x5e')]['findOne']({'where':{'id':_0x21e5bf[_0x58b814('0x44')]['id']}})[_0x58b814('0x4b')](handleEntityNotFound(_0x2dd573,null))[_0x58b814('0x4b')](function(_0x639bea){const _0x2dc2e7=_0x58b814;if(_0x639bea)return _0xd54120=_0x639bea['get']({'plain':!![]}),_0x529602['model']=_[_0x2dc2e7('0x6')](db[_0x2dc2e7('0xc')][_0x2dc2e7('0xb')]),_0x529602[_0x2dc2e7('0x5a')]=_['keys'](_0x21e5bf[_0x2dc2e7('0x5a')]),_0x529602['filters']=_[_0x2dc2e7('0x1b')](_0x529602[_0x2dc2e7('0x46')],_0x529602[_0x2dc2e7('0x5a')]),_0x4ca95c['attributes']=_[_0x2dc2e7('0x1b')](_0x529602['model'],qs[_0x2dc2e7('0x5c')](_0x21e5bf[_0x2dc2e7('0x5a')]['fields'])),_0x4ca95c[_0x2dc2e7('0x0')]=_0x4ca95c[_0x2dc2e7('0x0')][_0x2dc2e7('0x8')]?_0x4ca95c[_0x2dc2e7('0x0')]:_0x529602[_0x2dc2e7('0x46')],typeof _0x21e5bf[_0x2dc2e7('0x5a')][_0x2dc2e7('0x56')]===_0x2dc2e7('0x2e')&&(_0x4ca95c[_0x2dc2e7('0x1')]=qs[_0x2dc2e7('0x1')](_0x21e5bf[_0x2dc2e7('0x5a')]['limit']),_0x4ca95c[_0x2dc2e7('0x33')]=qs[_0x2dc2e7('0x33')](_0x21e5bf[_0x2dc2e7('0x5a')][_0x2dc2e7('0x33')])),_0x4ca95c[_0x2dc2e7('0x35')]=qs[_0x2dc2e7('0x43')](_0x21e5bf[_0x2dc2e7('0x5a')][_0x2dc2e7('0x43')]),_0x4ca95c[_0x2dc2e7('0x2a')]=qs['filters'](_[_0x2dc2e7('0x68')](_0x21e5bf[_0x2dc2e7('0x5a')],_0x529602[_0x2dc2e7('0x4')])),_0x4ca95c[_0x2dc2e7('0x2a')][_0x2dc2e7('0x10')]=_0x639bea['id'],_0x21e5bf[_0x2dc2e7('0x5a')][_0x2dc2e7('0x4c')]&&(_0x4ca95c[_0x2dc2e7('0x2a')]=_[_0x2dc2e7('0x5')](_0x4ca95c[_0x2dc2e7('0x2a')],{[Op['or']]:_[_0x2dc2e7('0x2c')](_0x4ca95c[_0x2dc2e7('0x0')],function(_0x349fae){const _0xf1d972=_0x2dc2e7,_0x4c2eba={};return _0x4c2eba[_0x349fae]={[Op[_0xf1d972('0x57')]]:'%'+_0x21e5bf[_0xf1d972('0x5a')]['filter']+'%'},_0x4c2eba;})})),_0x4ca95c=_[_0x2dc2e7('0x5')]({},_0x4ca95c,_0x21e5bf[_0x2dc2e7('0x42')]),db['UserWhatsappQueue']['findAll'](_0x4ca95c);})[_0x58b814('0x4b')](function(_0x4aa0f6){const _0x5b5289=_0x58b814;if(_0x4aa0f6)return db['User'][_0x5b5289('0x69')]({'where':{'id':_[_0x5b5289('0x2c')](_0x4aa0f6,_0x5b5289('0x5b')),'role':_0x5b5289('0x62')},'attributes':['id',_0x5b5289('0x61'),_0x5b5289('0x60'),_0x5b5289('0x22'),_0x5b5289('0x51')]});})[_0x58b814('0x4b')](function(_0x299afe){const _0x5f20a4=_0x58b814;return _0x299afe?{'count':_0x299afe['count'],'rows':_[_0x5f20a4('0x2c')](_0x299afe[_0x5f20a4('0x3e')],function(_0x2ee4e4){const _0x3327d3=_0x5f20a4;return{'membername':_0x2ee4e4[_0x3327d3('0x61')],'UserId':_0x2ee4e4['id'],'queue_name':_0xd54120[_0x3327d3('0x61')],'WhatsappQueueId':_0xd54120['id'],'interface':util[_0x3327d3('0x41')](_0x3327d3('0x3f'),_0x3327d3('0x2f'),_0x2ee4e4['name']),'penalty':0x0,'paused':_0x2ee4e4[_0x3327d3('0x60')],'createdAt':_0x2ee4e4[_0x3327d3('0x51')],'updatedAt':_0x2ee4e4[_0x3327d3('0x22')]};})}:{'count':0x0,'rows':[]};})['then'](respondWithFilteredResult(_0x2dd573,_0x4ca95c))[_0x58b814('0x4e')](handleError(_0x2dd573,null));},exports[_0x295ae9('0x4a')]=function(_0x36a4af,_0x34d7dc){const _0x1c8892=_0x295ae9;let _0x48bbe3={};const _0x5add42={};let _0xc0f337,_0x59a8f9;return db['WhatsappQueue']['findOne']({'where':{'id':_0x36a4af['params']['id']}})[_0x1c8892('0x4b')](handleEntityNotFound(_0x34d7dc,null))[_0x1c8892('0x4b')](function(_0xa80ea){const _0x51c508=_0x1c8892;if(_0xa80ea)return _0xc0f337=_0xa80ea,_0x5add42[_0x51c508('0x46')]=_[_0x51c508('0x6')](db['Team'][_0x51c508('0xb')]),_0x5add42['query']=_[_0x51c508('0x6')](_0x36a4af[_0x51c508('0x5a')]),_0x5add42[_0x51c508('0x4')]=_[_0x51c508('0x1b')](_0x5add42[_0x51c508('0x46')],_0x5add42['query']),_0x48bbe3[_0x51c508('0x0')]=_[_0x51c508('0x1b')](_0x5add42[_0x51c508('0x46')],qs[_0x51c508('0x5c')](_0x36a4af['query']['fields'])),_0x48bbe3[_0x51c508('0x0')]=_0x48bbe3[_0x51c508('0x0')][_0x51c508('0x8')]?_0x48bbe3[_0x51c508('0x0')]:_0x5add42[_0x51c508('0x46')],_0x48bbe3[_0x51c508('0x35')]=qs['sort'](_0x36a4af[_0x51c508('0x5a')][_0x51c508('0x43')]),_0x48bbe3['where']=qs[_0x51c508('0x4')](_[_0x51c508('0x68')](_0x36a4af[_0x51c508('0x5a')],_0x5add42[_0x51c508('0x4')])),_0x36a4af['query'][_0x51c508('0x4c')]&&(_0x48bbe3['where']=_[_0x51c508('0x5')](_0x48bbe3[_0x51c508('0x2a')],{[Op['or']]:_[_0x51c508('0x2c')](_0x48bbe3['attributes'],function(_0xc6252){const _0x113e67=_0x51c508,_0x216b0b={};return _0x216b0b[_0xc6252]={[Op[_0x113e67('0x57')]]:'%'+_0x36a4af[_0x113e67('0x5a')][_0x113e67('0x4c')]+'%'},_0x216b0b;})})),_0x48bbe3=_['merge']({},_0x48bbe3,_0x36a4af['options']),_0xc0f337[_0x51c508('0x4a')](_0x48bbe3);})[_0x1c8892('0x4b')](function(_0x2355b8){const _0x35f927=_0x1c8892;if(_0x2355b8)return _0x59a8f9=_0x2355b8[_0x35f927('0x8')],typeof _0x36a4af['query'][_0x35f927('0x56')]===_0x35f927('0x2e')&&(_0x48bbe3[_0x35f927('0x1')]=qs[_0x35f927('0x1')](_0x36a4af[_0x35f927('0x5a')]['limit']),_0x48bbe3[_0x35f927('0x33')]=qs[_0x35f927('0x33')](_0x36a4af[_0x35f927('0x5a')][_0x35f927('0x33')])),_0xc0f337[_0x35f927('0x4a')](_0x48bbe3);})[_0x1c8892('0x4b')](function(_0x2b16f6){if(_0x2b16f6)return _0x2b16f6?{'count':_0x59a8f9,'rows':_0x2b16f6}:null;})['then'](respondWithResult(_0x34d7dc,null))[_0x1c8892('0x4e')](handleError(_0x34d7dc,null));},exports['addTeams']=function(_0x3f105c,_0x2ec4f0){const _0x45568f=_0x295ae9,_0x40c5a6=_0x3f105c[_0x45568f('0x17')][_0x45568f('0x63')];return db[_0x45568f('0x12')][_0x45568f('0x23')]({'where':{'id':_0x40c5a6},'attributes':['id'],'include':[{'model':db[_0x45568f('0x49')],'as':_0x45568f('0x20'),'attributes':['id',_0x45568f('0x61'),_0x45568f('0x36'),'voicePause','interface'],'raw':!![]}]})[_0x45568f('0x4b')](function(_0x2065b5){const _0x5949c3=_0x45568f;if(_0x2065b5){const _0x2d68ab=_['flatMap'](_0x2065b5,function(_0x49eee7){const _0x391376=a808_0x3d3c,_0x5e4fb8=_0x49eee7['get']({'plain':!![]});return _0x5e4fb8[_0x391376('0x20')];});return db[_0x5949c3('0x5e')][_0x5949c3('0xe')]({'where':{'id':_0x3f105c[_0x5949c3('0x44')]['id']}})[_0x5949c3('0x4b')](function(_0x3e40de){const _0xd4ff91=_0x5949c3;return db[_0xd4ff91('0x6b')][_0xd4ff91('0x29')](function(_0x14dbbd){const _0x504979=_0xd4ff91;return _0x3e40de['addTeams'](_0x40c5a6,{'transaction':_0x14dbbd})[_0x504979('0x4b')](function(){const _0x199b5f=_0x504979;return Promise[_0x199b5f('0x64')](_0x2d68ab,function(_0x1ac07b){const _0x5ed44d=_0x199b5f;return db[_0x5ed44d('0xc')][_0x5ed44d('0x6a')]({'where':{'UserId':_0x1ac07b['id'],'WhatsappQueueId':_0x3f105c[_0x5ed44d('0x44')]['id']},'transaction':_0x14dbbd});});})['then'](function(){_0x2d68ab['forEach'](function(_0x5235c0){const _0xc52b89=a808_0x3d3c;socket[_0xc52b89('0x6c')](_0xc52b89('0xf'),{'UserId':_0x5235c0['id'],'WhatsappQueueId':_0x3e40de['id']});});});});});}})[_0x45568f('0x4b')](respondWithStatusCode(_0x2ec4f0,null))[_0x45568f('0x4e')](handleError(_0x2ec4f0,null));},exports[_0x295ae9('0x3b')]=function(_0x3039d3,_0x5c4be5){const _0x3ffd59=_0x295ae9;return db[_0x3ffd59('0x12')][_0x3ffd59('0x23')]({'where':{'id':_0x3039d3[_0x3ffd59('0x5a')]['ids']},'attributes':['id'],'include':[{'model':db[_0x3ffd59('0x49')],'as':_0x3ffd59('0x20'),'attributes':['id'],'raw':!![]}]})[_0x3ffd59('0x4b')](handleEntityNotFound(_0x5c4be5,null))['then'](function(_0x5e5cef){const _0x146154=_0x3ffd59,_0x561610=_[_0x146154('0x2c')](_0x5e5cef,'id');let _0x1ee421=[];const _0x153a3e=[],_0x4bf986=squel['select']();_0x4bf986['field'](_0x146154('0x24'))['from'](_0x146154('0x14'),'tq')[_0x146154('0x45')]('user_has_teams','ut',_0x146154('0x9'))[_0x146154('0x2a')](_0x146154('0xa'),_0x3039d3[_0x146154('0x44')]['id']);for(let _0x3262d4=0x0;_0x3262d4<_0x5e5cef[_0x146154('0x8')];_0x3262d4+=0x1){const _0x398abe=_0x5e5cef[_0x3262d4];for(let _0x5939d6=0x0;_0x5939d6<_0x398abe[_0x146154('0x20')][_0x146154('0x8')];_0x5939d6+=0x1){const _0x25e302=_0x398abe['Agents'][_0x5939d6],_0x51c41a=_0x4bf986[_0x146154('0x67')]();_0x51c41a[_0x146154('0x2a')](_0x146154('0x52'),_0x25e302['id']),_0x153a3e[_0x146154('0x26')](db['sequelize'][_0x146154('0x5a')](_0x51c41a['toString'](),{'type':QueryTypes['SELECT']})[_0x146154('0x4b')](function(_0x5dea43){const _0x38a64d=_0x146154;if(_0x5dea43['length']===0x1)return _0x25e302['id'];else{const _0xfd4532=_['every'](_[_0x38a64d('0x2c')](_0x5dea43,_0x38a64d('0x15')),function(_0x3edb12){const _0x1664da=_0x38a64d;return _[_0x1664da('0x58')](_0x561610,_0x3edb12);});if(_0xfd4532)return _0x25e302['id'];}}));}}return Promise[_0x146154('0x7')](_0x153a3e)[_0x146154('0x4b')](function(_0x1fefb8){const _0x1e92de=_0x146154;return _0x1ee421=_(_0x1ee421)['union'](_0x1fefb8)[_0x1e92de('0xd')]()[_0x1e92de('0x30')](),db[_0x1e92de('0x5e')][_0x1e92de('0xe')]({'where':{'id':_0x3039d3['params']['id']}})[_0x1e92de('0x4b')](function(_0x4aebc2){return db['sequelize']['transaction'](function(_0x2e5c7b){const _0x2267e7=a808_0x3d3c;return _0x4aebc2[_0x2267e7('0x3b')](_0x3039d3[_0x2267e7('0x5a')]['ids'],{'transaction':_0x2e5c7b})[_0x2267e7('0x4b')](function(){if(!_['isEmpty'](_0x1ee421))return _0x4aebc2['removeAgents'](_0x1ee421,{'transaction':_0x2e5c7b});})[_0x2267e7('0x4b')](function(){_0x1ee421['forEach'](function(_0x18f2fa){const _0x504448=a808_0x3d3c;socket[_0x504448('0x6c')]('userWhatsappQueue:remove',{'UserId':_0x18f2fa,'WhatsappQueueId':_0x4aebc2['id']});});});});});});})[_0x3ffd59('0x4b')](respondWithStatusCode(_0x5c4be5,null))[_0x3ffd59('0x4e')](handleError(_0x5c4be5,null));},exports['addAgents']=function(_0x462859,_0x385449){const _0x5096f3=_0x295ae9;return db[_0x5096f3('0x5e')][_0x5096f3('0xe')]({'where':{'id':_0x462859[_0x5096f3('0x44')]['id']}})[_0x5096f3('0x4b')](function(_0x35c928){const _0x12937b=_0x5096f3;if(_0x35c928)return _0x35c928[_0x12937b('0x11')](_0x462859[_0x12937b('0x17')][_0x12937b('0x63')],{'through':_[_0x12937b('0x39')](_0x462859[_0x12937b('0x17')],['ids','id'])})[_0x12937b('0x4b')](function(_0x3e4cff){const _0x5929a4=_0x12937b;for(let _0xb68099=0x0;_0xb68099<_0x462859[_0x5929a4('0x17')]['ids']['length'];_0xb68099+=0x1){socket[_0x5929a4('0x6c')](_0x5929a4('0xf'),{'UserId':_0x462859[_0x5929a4('0x17')][_0x5929a4('0x63')][_0xb68099],'WhatsappQueueId':_0x462859[_0x5929a4('0x44')]['id']});}return _0x3e4cff;});})[_0x5096f3('0x4b')](respondWithResult(_0x385449,null))[_0x5096f3('0x4e')](handleError(_0x385449,null));},exports[_0x295ae9('0x37')]=function(_0x14270a,_0x43886c){const _0x474c22=_0x295ae9;return db[_0x474c22('0x5e')]['findOne']({'where':{'id':_0x14270a[_0x474c22('0x44')]['id']}})[_0x474c22('0x4b')](handleEntityNotFound(_0x43886c,null))['then'](function(_0x3559ad){const _0x15e4e1=_0x474c22;if(_0x3559ad)return _0x3559ad['removeAgents'](_0x14270a[_0x15e4e1('0x5a')][_0x15e4e1('0x63')])[_0x15e4e1('0x4b')](function(){const _0x24f1f5=_0x15e4e1;if(_[_0x24f1f5('0x5f')](_0x14270a[_0x24f1f5('0x5a')][_0x24f1f5('0x63')]))for(let _0x491553=0x0;_0x491553<_0x14270a[_0x24f1f5('0x5a')]['ids'][_0x24f1f5('0x8')];_0x491553+=0x1){socket[_0x24f1f5('0x6c')](_0x24f1f5('0x3a'),{'UserId':Number(_0x14270a[_0x24f1f5('0x5a')][_0x24f1f5('0x63')][_0x491553]),'WhatsappQueueId':Number(_0x14270a[_0x24f1f5('0x44')]['id'])});}else socket[_0x24f1f5('0x6c')](_0x24f1f5('0x3a'),{'UserId':Number(_0x14270a['query'][_0x24f1f5('0x63')]),'WhatsappQueueId':Number(_0x14270a[_0x24f1f5('0x44')]['id'])});});})[_0x474c22('0x4b')](respondWithStatusCode(_0x43886c,null))[_0x474c22('0x4e')](handleError(_0x43886c,null));},exports[_0x295ae9('0x65')]=function(_0x4c30f3,_0x3c8545){const _0x47bf39=_0x295ae9;let _0x1f374f={};const _0x4567bc={};let _0x137d05,_0x3bb2fa;return db[_0x47bf39('0x5e')][_0x47bf39('0xe')]({'where':{'id':_0x4c30f3[_0x47bf39('0x44')]['id']}})[_0x47bf39('0x4b')](handleEntityNotFound(_0x3c8545,null))[_0x47bf39('0x4b')](function(_0x28af2f){const _0x3b7177=_0x47bf39;if(_0x28af2f)return _0x137d05=_0x28af2f,_0x4567bc[_0x3b7177('0x46')]=_[_0x3b7177('0x6')](db[_0x3b7177('0x49')][_0x3b7177('0xb')]),_0x4567bc[_0x3b7177('0x5a')]=_['keys'](_0x4c30f3['query']),_0x4567bc[_0x3b7177('0x4')]=_[_0x3b7177('0x1b')](_0x4567bc[_0x3b7177('0x46')],_0x4567bc[_0x3b7177('0x5a')]),_0x1f374f[_0x3b7177('0x0')]=_[_0x3b7177('0x1b')](_0x4567bc[_0x3b7177('0x46')],qs[_0x3b7177('0x5c')](_0x4c30f3[_0x3b7177('0x5a')][_0x3b7177('0x5c')])),_0x1f374f['attributes']=_0x1f374f[_0x3b7177('0x0')][_0x3b7177('0x8')]?_0x1f374f[_0x3b7177('0x0')]:_0x4567bc['model'],_0x1f374f[_0x3b7177('0x35')]=qs[_0x3b7177('0x43')](_0x4c30f3['query'][_0x3b7177('0x43')]),_0x1f374f[_0x3b7177('0x2a')]=qs[_0x3b7177('0x4')](_[_0x3b7177('0x68')](_0x4c30f3[_0x3b7177('0x5a')],_0x4567bc[_0x3b7177('0x4')])),_0x4c30f3[_0x3b7177('0x5a')][_0x3b7177('0x4c')]&&(_0x1f374f[_0x3b7177('0x2a')]=_[_0x3b7177('0x5')](_0x1f374f[_0x3b7177('0x2a')],{[Op['or']]:_[_0x3b7177('0x2c')](_0x1f374f['attributes'],function(_0x521ced){const _0x56ba20=_0x3b7177,_0x272571={};return _0x272571[_0x521ced]={[Op['like']]:'%'+_0x4c30f3[_0x56ba20('0x5a')][_0x56ba20('0x4c')]+'%'},_0x272571;})})),_0x1f374f=_[_0x3b7177('0x5')]({},_0x1f374f,_0x4c30f3['options']),_0x137d05[_0x3b7177('0x65')](_0x1f374f);})[_0x47bf39('0x4b')](function(_0x21b627){const _0x5b4f5b=_0x47bf39;if(_0x21b627)return _0x3bb2fa=_0x21b627[_0x5b4f5b('0x8')],typeof _0x4c30f3[_0x5b4f5b('0x5a')]['nolimit']==='undefined'&&(_0x1f374f['limit']=qs['limit'](_0x4c30f3[_0x5b4f5b('0x5a')]['limit']),_0x1f374f[_0x5b4f5b('0x33')]=qs[_0x5b4f5b('0x33')](_0x4c30f3[_0x5b4f5b('0x5a')][_0x5b4f5b('0x33')])),_0x137d05[_0x5b4f5b('0x65')](_0x1f374f);})[_0x47bf39('0x4b')](function(_0xa1a5d6){if(_0xa1a5d6)return _0xa1a5d6?{'count':_0x3bb2fa,'rows':_0xa1a5d6}:null;})[_0x47bf39('0x4b')](respondWithResult(_0x3c8545,null))[_0x47bf39('0x4e')](handleError(_0x3c8545,null));}; \ No newline at end of file diff --git a/server/api/whatsappQueue/whatsappQueue.events.js b/server/api/whatsappQueue/whatsappQueue.events.js index 45f75d9..2a919db 100644 --- a/server/api/whatsappQueue/whatsappQueue.events.js +++ b/server/api/whatsappQueue/whatsappQueue.events.js @@ -1 +1 @@ -const a809_0x148b=['../../mysqldb','WhatsappQueue','save','setMaxListeners','emit','exports','remove','events'];(function(_0x3d82d,_0x148bde){const _0x445c18=function(_0x5bc24c){while(--_0x5bc24c){_0x3d82d['push'](_0x3d82d['shift']());}};_0x445c18(++_0x148bde);}(a809_0x148b,0x145));const a809_0x445c=function(_0x3d82d,_0x148bde){_0x3d82d=_0x3d82d-0x0;let _0x445c18=a809_0x148b[_0x3d82d];return _0x445c18;};const _0x3e7392=a809_0x445c;'use strict';const EventEmitter=require(_0x3e7392('0x2')),WhatsappQueue=require(_0x3e7392('0x3'))['db'][_0x3e7392('0x4')],WhatsappQueueEvents=new EventEmitter();WhatsappQueueEvents[_0x3e7392('0x6')](0x0);const events={'afterCreate':_0x3e7392('0x5'),'afterUpdate':'update','afterDestroy':_0x3e7392('0x1')};function emitEvent(_0x5bc24c){return function(_0x373617){const _0x5c0132=a809_0x445c;WhatsappQueueEvents[_0x5c0132('0x7')](_0x5bc24c+':'+_0x373617['id'],_0x373617),WhatsappQueueEvents[_0x5c0132('0x7')](_0x5bc24c,_0x373617);};}for(const e in events){if(typeof events[e]!=='undefined'){const event=events[e];WhatsappQueue['addHook'](e,emitEvent(event));}}module[_0x3e7392('0x0')]=WhatsappQueueEvents; \ No newline at end of file +const a809_0x2352=['emit','../../mysqldb','update','events','remove','exports','save','undefined','setMaxListeners'];(function(_0x462678,_0x235251){const _0x2575d3=function(_0x36a108){while(--_0x36a108){_0x462678['push'](_0x462678['shift']());}};_0x2575d3(++_0x235251);}(a809_0x2352,0x107));const a809_0x2575=function(_0x462678,_0x235251){_0x462678=_0x462678-0x0;let _0x2575d3=a809_0x2352[_0x462678];return _0x2575d3;};const _0x4a6466=a809_0x2575;'use strict';const EventEmitter=require(_0x4a6466('0x1')),WhatsappQueue=require(_0x4a6466('0x8'))['db']['WhatsappQueue'],WhatsappQueueEvents=new EventEmitter();WhatsappQueueEvents[_0x4a6466('0x6')](0x0);const events={'afterCreate':_0x4a6466('0x4'),'afterUpdate':_0x4a6466('0x0'),'afterDestroy':_0x4a6466('0x2')};function emitEvent(_0x36a108){return function(_0x55877f){const _0x5d2f4d=a809_0x2575;WhatsappQueueEvents['emit'](_0x36a108+':'+_0x55877f['id'],_0x55877f),WhatsappQueueEvents[_0x5d2f4d('0x7')](_0x36a108,_0x55877f);};}for(const e in events){if(typeof events[e]!==_0x4a6466('0x5')){const event=events[e];WhatsappQueue['addHook'](e,emitEvent(event));}}module[_0x4a6466('0x3')]=WhatsappQueueEvents; \ No newline at end of file diff --git a/server/api/whatsappQueue/whatsappQueue.model.js b/server/api/whatsappQueue/whatsappQueue.model.js index fe5411a..ea4a9ad 100644 --- a/server/api/whatsappQueue/whatsappQueue.model.js +++ b/server/api/whatsappQueue/whatsappQueue.model.js @@ -1 +1 @@ -const a810_0x30e4=['exports','define','whatsapp_queues'];(function(_0xa5cf69,_0x30e448){const _0xd342a7=function(_0x398c55){while(--_0x398c55){_0xa5cf69['push'](_0xa5cf69['shift']());}};_0xd342a7(++_0x30e448);}(a810_0x30e4,0xe7));const a810_0xd342=function(_0xa5cf69,_0x30e448){_0xa5cf69=_0xa5cf69-0x0;let _0xd342a7=a810_0x30e4[_0xa5cf69];return _0xd342a7;};const _0x2a0081=a810_0xd342;'use strict';const attributes=require('./whatsappQueue.attributes');module[_0x2a0081('0x0')]=function(_0x398c55){const _0xb3f706=_0x2a0081,_0xe80b96=_0x398c55[_0xb3f706('0x1')]('WhatsappQueue',attributes,{'tableName':_0xb3f706('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0xe80b96;}; \ No newline at end of file +const a810_0xf3e9=['WhatsappQueue','exports','whatsapp_queues','./whatsappQueue.attributes'];(function(_0x149b65,_0xf3e9cc){const _0x1c6a28=function(_0x79183f){while(--_0x79183f){_0x149b65['push'](_0x149b65['shift']());}};_0x1c6a28(++_0xf3e9cc);}(a810_0xf3e9,0x17c));const a810_0x1c6a=function(_0x149b65,_0xf3e9cc){_0x149b65=_0x149b65-0x0;let _0x1c6a28=a810_0xf3e9[_0x149b65];return _0x1c6a28;};const _0x432525=a810_0x1c6a;'use strict';const attributes=require(_0x432525('0x3'));module[_0x432525('0x1')]=function(_0x79183f){const _0x2ecc67=_0x432525,_0x27b77f=_0x79183f['define'](_0x2ecc67('0x0'),attributes,{'tableName':_0x2ecc67('0x2'),'paranoid':![],'indexes':[],'timestamps':!![]});return _0x27b77f;}; \ No newline at end of file diff --git a/server/api/whatsappQueue/whatsappQueue.rpc.js b/server/api/whatsappQueue/whatsappQueue.rpc.js index 4e6867f..a72da38 100644 --- a/server/api/whatsappQueue/whatsappQueue.rpc.js +++ b/server/api/whatsappQueue/whatsappQueue.rpc.js @@ -1 +1 @@ -const a811_0x2d72=['WhatsappQueue','GetWhatsappQueue','message','debug','../../mysqldb','error','ShowWhatsappQueue','map','../../rediscache','findAll','options','info','register','then','catch','attributes','lodash','include','where','stringify','rpc','model','../../config/logger','raw'];(function(_0x2422f1,_0x2d721f){const _0x403469=function(_0x18e5f0){while(--_0x18e5f0){_0x2422f1['push'](_0x2422f1['shift']());}};_0x403469(++_0x2d721f);}(a811_0x2d72,0xe6));const a811_0x4034=function(_0x2422f1,_0x2d721f){_0x2422f1=_0x2422f1-0x0;let _0x403469=a811_0x2d72[_0x2422f1];return _0x403469;};const _0x53be4c=a811_0x4034;'use strict';const _=require(_0x53be4c('0x2')),db=require(_0x53be4c('0xe'))['db'],logger=require(_0x53be4c('0x8'))(_0x53be4c('0x6')),{getSocket}=require(_0x53be4c('0x12')),socket=getSocket();require('./whatsappQueue.socket')[_0x53be4c('0x16')](socket),exports[_0x53be4c('0xb')]=function(_0x18e5f0){const _0x713ea0=this;return new Promise(function(_0x3c1813,_0x224c38){const _0x431ca8=a811_0x4034;return db[_0x431ca8('0xa')][_0x431ca8('0x13')]({'raw':_0x18e5f0['options']?_0x18e5f0[_0x431ca8('0x14')][_0x431ca8('0x9')]===undefined?!![]:![]:!![],'where':_0x18e5f0['options']?_0x18e5f0[_0x431ca8('0x14')][_0x431ca8('0x4')]||null:null,'attributes':_0x18e5f0[_0x431ca8('0x14')]?_0x18e5f0[_0x431ca8('0x14')][_0x431ca8('0x1')]||null:null,'limit':_0x18e5f0['options']?_0x18e5f0[_0x431ca8('0x14')]['limit']||null:null,'include':_0x18e5f0[_0x431ca8('0x14')]?_0x18e5f0[_0x431ca8('0x14')][_0x431ca8('0x3')]?_['map'](_0x18e5f0[_0x431ca8('0x14')][_0x431ca8('0x3')],function(_0x1385d5){const _0x2bd072=_0x431ca8;return{'model':db[_0x1385d5[_0x2bd072('0x7')]],'as':_0x1385d5['as'],'attributes':_0x1385d5[_0x2bd072('0x1')],'include':_0x1385d5[_0x2bd072('0x3')]?_[_0x2bd072('0x11')](_0x1385d5[_0x2bd072('0x3')],function(_0x4a8ed1){const _0x65c5c4=_0x2bd072;return{'model':db[_0x4a8ed1['model']],'as':_0x4a8ed1['as'],'attributes':_0x4a8ed1[_0x65c5c4('0x1')],'include':_0x4a8ed1[_0x65c5c4('0x3')]?_[_0x65c5c4('0x11')](_0x4a8ed1[_0x65c5c4('0x3')],function(_0x1b5057){const _0x4aba45=_0x65c5c4;return{'model':db[_0x1b5057['model']],'as':_0x1b5057['as'],'attributes':_0x1b5057[_0x4aba45('0x1')]};}):[]};}):[]};}):[]:[]})[_0x431ca8('0x17')](function(_0x5f067c){const _0x5689dd=_0x431ca8;logger[_0x5689dd('0x15')](_0x5689dd('0xb'),_0x18e5f0),logger[_0x5689dd('0xd')](_0x5689dd('0xb'),_0x18e5f0,JSON[_0x5689dd('0x5')](_0x5f067c)),_0x3c1813(_0x5f067c);})[_0x431ca8('0x0')](function(_0x25df76){const _0x4ea626=_0x431ca8;logger[_0x4ea626('0xf')]('GetWhatsappQueue',_0x25df76[_0x4ea626('0xc')],_0x18e5f0),_0x224c38(_0x713ea0[_0x4ea626('0xf')](0x1f4,_0x25df76[_0x4ea626('0xc')]));});});},exports['ShowWhatsappQueue']=function(_0x3aa2c9){const _0x6ba286=this;return new Promise(function(_0x3552d4,_0x394cf0){const _0x44d790=a811_0x4034;return db[_0x44d790('0xa')]['findOne']({'raw':_0x3aa2c9[_0x44d790('0x14')]?_0x3aa2c9[_0x44d790('0x14')]['raw']===undefined?!![]:![]:!![],'where':_0x3aa2c9[_0x44d790('0x14')]?_0x3aa2c9[_0x44d790('0x14')][_0x44d790('0x4')]||null:null,'attributes':_0x3aa2c9['options']?_0x3aa2c9[_0x44d790('0x14')][_0x44d790('0x1')]||null:null,'include':_0x3aa2c9[_0x44d790('0x14')]?_0x3aa2c9[_0x44d790('0x14')][_0x44d790('0x3')]?_[_0x44d790('0x11')](_0x3aa2c9['options'][_0x44d790('0x3')],function(_0x2cfe52){const _0x16299b=_0x44d790;return{'model':db[_0x2cfe52[_0x16299b('0x7')]],'as':_0x2cfe52['as'],'attributes':_0x2cfe52['attributes'],'include':_0x2cfe52[_0x16299b('0x3')]?_[_0x16299b('0x11')](_0x2cfe52['include'],function(_0x3d0d15){const _0x4e9de1=_0x16299b;return{'model':db[_0x3d0d15[_0x4e9de1('0x7')]],'as':_0x3d0d15['as'],'attributes':_0x3d0d15[_0x4e9de1('0x1')],'include':_0x3d0d15[_0x4e9de1('0x3')]?_['map'](_0x3d0d15[_0x4e9de1('0x3')],function(_0xc91cd2){const _0x49502f=_0x4e9de1;return{'model':db[_0xc91cd2[_0x49502f('0x7')]],'as':_0xc91cd2['as'],'attributes':_0xc91cd2[_0x49502f('0x1')]};}):[]};}):[]};}):[]:[]})[_0x44d790('0x17')](function(_0xd93253){const _0x57e1ba=_0x44d790;logger[_0x57e1ba('0x15')](_0x57e1ba('0x10'),_0x3aa2c9),logger[_0x57e1ba('0xd')](_0x57e1ba('0x10'),_0x3aa2c9,JSON[_0x57e1ba('0x5')](_0xd93253)),_0x3552d4(_0xd93253);})[_0x44d790('0x0')](function(_0x44d7f4){const _0x263256=_0x44d790;logger[_0x263256('0xf')](_0x263256('0x10'),_0x44d7f4[_0x263256('0xc')],_0x3aa2c9),_0x394cf0(_0x6ba286[_0x263256('0xf')](0x1f4,_0x44d7f4['message']));});});}; \ No newline at end of file +const a811_0x10af=['attributes','message','WhatsappQueue','lodash','rpc','catch','map','stringify','error','raw','model','options','GetWhatsappQueue','findAll','ShowWhatsappQueue','include','debug','then','findOne','../../mysqldb','info','./whatsappQueue.socket','where'];(function(_0x2813b5,_0x10afcd){const _0x302fc9=function(_0x50f4d9){while(--_0x50f4d9){_0x2813b5['push'](_0x2813b5['shift']());}};_0x302fc9(++_0x10afcd);}(a811_0x10af,0x1ef));const a811_0x302f=function(_0x2813b5,_0x10afcd){_0x2813b5=_0x2813b5-0x0;let _0x302fc9=a811_0x10af[_0x2813b5];return _0x302fc9;};const _0x1e6047=a811_0x302f;'use strict';const _=require(_0x1e6047('0xe')),db=require(_0x1e6047('0x7'))['db'],logger=require('../../config/logger')(_0x1e6047('0xf')),{getSocket}=require('../../rediscache'),socket=getSocket();require(_0x1e6047('0x9'))['register'](socket),exports[_0x1e6047('0x0')]=function(_0x50f4d9){const _0x167741=this;return new Promise(function(_0x52c3da,_0x272c13){const _0x513bb1=a811_0x302f;return db['WhatsappQueue'][_0x513bb1('0x1')]({'raw':_0x50f4d9['options']?_0x50f4d9['options'][_0x513bb1('0x14')]===undefined?!![]:![]:!![],'where':_0x50f4d9[_0x513bb1('0x16')]?_0x50f4d9[_0x513bb1('0x16')][_0x513bb1('0xa')]||null:null,'attributes':_0x50f4d9[_0x513bb1('0x16')]?_0x50f4d9[_0x513bb1('0x16')][_0x513bb1('0xb')]||null:null,'limit':_0x50f4d9['options']?_0x50f4d9['options']['limit']||null:null,'include':_0x50f4d9[_0x513bb1('0x16')]?_0x50f4d9['options']['include']?_[_0x513bb1('0x11')](_0x50f4d9[_0x513bb1('0x16')]['include'],function(_0x2ddb8e){const _0x254c0a=_0x513bb1;return{'model':db[_0x2ddb8e[_0x254c0a('0x15')]],'as':_0x2ddb8e['as'],'attributes':_0x2ddb8e[_0x254c0a('0xb')],'include':_0x2ddb8e['include']?_[_0x254c0a('0x11')](_0x2ddb8e[_0x254c0a('0x3')],function(_0xf680d){const _0x4e2646=_0x254c0a;return{'model':db[_0xf680d['model']],'as':_0xf680d['as'],'attributes':_0xf680d['attributes'],'include':_0xf680d['include']?_[_0x4e2646('0x11')](_0xf680d[_0x4e2646('0x3')],function(_0x1fcd7f){const _0x243f1b=_0x4e2646;return{'model':db[_0x1fcd7f[_0x243f1b('0x15')]],'as':_0x1fcd7f['as'],'attributes':_0x1fcd7f[_0x243f1b('0xb')]};}):[]};}):[]};}):[]:[]})[_0x513bb1('0x5')](function(_0x3d4fde){const _0x84878e=_0x513bb1;logger[_0x84878e('0x8')]('GetWhatsappQueue',_0x50f4d9),logger[_0x84878e('0x4')]('GetWhatsappQueue',_0x50f4d9,JSON['stringify'](_0x3d4fde)),_0x52c3da(_0x3d4fde);})[_0x513bb1('0x10')](function(_0x3b500b){const _0x2bbf1c=_0x513bb1;logger[_0x2bbf1c('0x13')]('GetWhatsappQueue',_0x3b500b[_0x2bbf1c('0xc')],_0x50f4d9),_0x272c13(_0x167741[_0x2bbf1c('0x13')](0x1f4,_0x3b500b[_0x2bbf1c('0xc')]));});});},exports['ShowWhatsappQueue']=function(_0x1b5d8f){const _0x5c1365=this;return new Promise(function(_0x32c380,_0x50d52e){const _0x8ad588=a811_0x302f;return db[_0x8ad588('0xd')][_0x8ad588('0x6')]({'raw':_0x1b5d8f['options']?_0x1b5d8f[_0x8ad588('0x16')][_0x8ad588('0x14')]===undefined?!![]:![]:!![],'where':_0x1b5d8f['options']?_0x1b5d8f[_0x8ad588('0x16')]['where']||null:null,'attributes':_0x1b5d8f[_0x8ad588('0x16')]?_0x1b5d8f[_0x8ad588('0x16')]['attributes']||null:null,'include':_0x1b5d8f[_0x8ad588('0x16')]?_0x1b5d8f[_0x8ad588('0x16')][_0x8ad588('0x3')]?_[_0x8ad588('0x11')](_0x1b5d8f[_0x8ad588('0x16')][_0x8ad588('0x3')],function(_0xb14693){const _0x4bd891=_0x8ad588;return{'model':db[_0xb14693['model']],'as':_0xb14693['as'],'attributes':_0xb14693[_0x4bd891('0xb')],'include':_0xb14693[_0x4bd891('0x3')]?_['map'](_0xb14693['include'],function(_0x3b5b13){const _0x31df97=_0x4bd891;return{'model':db[_0x3b5b13[_0x31df97('0x15')]],'as':_0x3b5b13['as'],'attributes':_0x3b5b13[_0x31df97('0xb')],'include':_0x3b5b13['include']?_[_0x31df97('0x11')](_0x3b5b13[_0x31df97('0x3')],function(_0x1022a6){const _0x50cbbe=_0x31df97;return{'model':db[_0x1022a6[_0x50cbbe('0x15')]],'as':_0x1022a6['as'],'attributes':_0x1022a6[_0x50cbbe('0xb')]};}):[]};}):[]};}):[]:[]})[_0x8ad588('0x5')](function(_0x4129ff){const _0x85439c=_0x8ad588;logger[_0x85439c('0x8')](_0x85439c('0x2'),_0x1b5d8f),logger[_0x85439c('0x4')](_0x85439c('0x2'),_0x1b5d8f,JSON[_0x85439c('0x12')](_0x4129ff)),_0x32c380(_0x4129ff);})[_0x8ad588('0x10')](function(_0x2f4f26){const _0x3ab9e5=_0x8ad588;logger[_0x3ab9e5('0x13')](_0x3ab9e5('0x2'),_0x2f4f26[_0x3ab9e5('0xc')],_0x1b5d8f),_0x50d52e(_0x5c1365[_0x3ab9e5('0x13')](0x1f4,_0x2f4f26[_0x3ab9e5('0xc')]));});});}; \ No newline at end of file diff --git a/server/api/whatsappQueue/whatsappQueue.socket.js b/server/api/whatsappQueue/whatsappQueue.socket.js index ac1916f..29e0cee 100644 --- a/server/api/whatsappQueue/whatsappQueue.socket.js +++ b/server/api/whatsappQueue/whatsappQueue.socket.js @@ -1 +1 @@ -const a812_0x5e5d=['save','emit','./whatsappQueue.events','length','whatsappQueue:','remove','register'];(function(_0xedb43f,_0x5e5d57){const _0x426754=function(_0x442955){while(--_0x442955){_0xedb43f['push'](_0xedb43f['shift']());}};_0x426754(++_0x5e5d57);}(a812_0x5e5d,0x18e));const a812_0x4267=function(_0xedb43f,_0x5e5d57){_0xedb43f=_0xedb43f-0x0;let _0x426754=a812_0x5e5d[_0xedb43f];return _0x426754;};const _0x3d63d7=a812_0x4267;'use strict';const WhatsappQueueEvents=require(_0x3d63d7('0x3')),events=[_0x3d63d7('0x1'),_0x3d63d7('0x6'),'update'];function createListener(_0x442955,_0x1e6746){return function(_0x1309c5){const _0x4556af=a812_0x4267;_0x1e6746[_0x4556af('0x2')](_0x442955,_0x1309c5);};}exports[_0x3d63d7('0x0')]=function(_0x36d7cd){const _0x1795d1=_0x3d63d7;for(let _0xd39f18=0x0,_0x3418ec=events[_0x1795d1('0x4')];_0xd39f18<_0x3418ec;_0xd39f18++){const _0x1edb42=events[_0xd39f18],_0x24216b=createListener(_0x1795d1('0x5')+_0x1edb42,_0x36d7cd);WhatsappQueueEvents['on'](_0x1edb42,_0x24216b);}}; \ No newline at end of file +const a812_0x10d6=['length','emit','whatsappQueue:','update','remove','register'];(function(_0x4d91b4,_0x10d6b4){const _0x472853=function(_0x1ccb18){while(--_0x1ccb18){_0x4d91b4['push'](_0x4d91b4['shift']());}};_0x472853(++_0x10d6b4);}(a812_0x10d6,0xbc));const a812_0x4728=function(_0x4d91b4,_0x10d6b4){_0x4d91b4=_0x4d91b4-0x0;let _0x472853=a812_0x10d6[_0x4d91b4];return _0x472853;};const _0x2d7e0e=a812_0x4728;'use strict';const WhatsappQueueEvents=require('./whatsappQueue.events'),events=['save',_0x2d7e0e('0x2'),_0x2d7e0e('0x1')];function createListener(_0x1ccb18,_0x50f5e6){return function(_0x1d687f){const _0x2f3caa=a812_0x4728;_0x50f5e6[_0x2f3caa('0x5')](_0x1ccb18,_0x1d687f);};}exports[_0x2d7e0e('0x3')]=function(_0x1c0f0b){const _0x1ab115=_0x2d7e0e;for(let _0x32ef41=0x0,_0x4d265e=events[_0x1ab115('0x4')];_0x32ef41<_0x4d265e;_0x32ef41++){const _0x581f52=events[_0x32ef41],_0xc6fd0b=createListener(_0x1ab115('0x0')+_0x581f52,_0x1c0f0b);WhatsappQueueEvents['on'](_0x581f52,_0xc6fd0b);}}; \ No newline at end of file diff --git a/server/api/whatsappQueueReport/index.js b/server/api/whatsappQueueReport/index.js index 1c27ac3..d8bc42b 100644 --- a/server/api/whatsappQueueReport/index.js +++ b/server/api/whatsappQueueReport/index.js @@ -1 +1 @@ -const a813_0x310c=['express','Router','show','/:id','../../components/auth/service','./whatsappQueueReport.controller','get','delete','exports','index','destroy','put','create','post','isAuthenticated','describe'];(function(_0x133c7f,_0x310cf4){const _0x5ec39b=function(_0x13dd7f){while(--_0x13dd7f){_0x133c7f['push'](_0x133c7f['shift']());}};_0x5ec39b(++_0x310cf4);}(a813_0x310c,0xcb));const a813_0x5ec3=function(_0x133c7f,_0x310cf4){_0x133c7f=_0x133c7f-0x0;let _0x5ec39b=a813_0x310c[_0x133c7f];return _0x5ec39b;};const _0x4b22ee=a813_0x5ec3;'use strict';const express=require(_0x4b22ee('0x5')),router=express[_0x4b22ee('0x6')](),auth=require(_0x4b22ee('0x9')),controller=require(_0x4b22ee('0xa'));router[_0x4b22ee('0xb')]('/',auth[_0x4b22ee('0x3')](),controller[_0x4b22ee('0xe')]),router['get']('/describe',auth[_0x4b22ee('0x3')](),controller[_0x4b22ee('0x4')]),router[_0x4b22ee('0xb')](_0x4b22ee('0x8'),auth[_0x4b22ee('0x3')](),controller[_0x4b22ee('0x7')]),router[_0x4b22ee('0x2')]('/',auth['isAuthenticated'](),controller[_0x4b22ee('0x1')]),router[_0x4b22ee('0x0')](_0x4b22ee('0x8'),auth['isAuthenticated'](),controller['update']),router[_0x4b22ee('0xc')](_0x4b22ee('0x8'),auth['isAuthenticated'](),controller[_0x4b22ee('0xf')]),module[_0x4b22ee('0xd')]=router; \ No newline at end of file +const a813_0x56a4=['/:id','get','index','create','destroy','/describe','isAuthenticated','describe','update','express','exports','post','put','show','Router','./whatsappQueueReport.controller'];(function(_0xea0a75,_0x56a445){const _0x49d8f0=function(_0x1cf6df){while(--_0x1cf6df){_0xea0a75['push'](_0xea0a75['shift']());}};_0x49d8f0(++_0x56a445);}(a813_0x56a4,0x90));const a813_0x49d8=function(_0xea0a75,_0x56a445){_0xea0a75=_0xea0a75-0x0;let _0x49d8f0=a813_0x56a4[_0xea0a75];return _0x49d8f0;};const _0x48912=a813_0x49d8;'use strict';const express=require(_0x48912('0x9')),router=express[_0x48912('0xe')](),auth=require('../../components/auth/service'),controller=require(_0x48912('0xf'));router[_0x48912('0x1')]('/',auth[_0x48912('0x6')](),controller[_0x48912('0x2')]),router[_0x48912('0x1')](_0x48912('0x5'),auth[_0x48912('0x6')](),controller[_0x48912('0x7')]),router[_0x48912('0x1')](_0x48912('0x0'),auth[_0x48912('0x6')](),controller[_0x48912('0xd')]),router[_0x48912('0xb')]('/',auth['isAuthenticated'](),controller[_0x48912('0x3')]),router[_0x48912('0xc')](_0x48912('0x0'),auth[_0x48912('0x6')](),controller[_0x48912('0x8')]),router['delete'](_0x48912('0x0'),auth[_0x48912('0x6')](),controller[_0x48912('0x4')]),module[_0x48912('0xa')]=router; \ No newline at end of file diff --git a/server/api/whatsappQueueReport/whatsappQueueReport.attributes.js b/server/api/whatsappQueueReport/whatsappQueueReport.attributes.js index 5a23a15..0452856 100644 --- a/server/api/whatsappQueueReport/whatsappQueueReport.attributes.js +++ b/server/api/whatsappQueueReport/whatsappQueueReport.attributes.js @@ -1 +1 @@ -const a814_0x5de1=['sequelize','STRING','DATE','exports'];(function(_0x28b5e4,_0x5de1b6){const _0x3bd093=function(_0x46dc69){while(--_0x46dc69){_0x28b5e4['push'](_0x28b5e4['shift']());}};_0x3bd093(++_0x5de1b6);}(a814_0x5de1,0x163));const a814_0x3bd0=function(_0x28b5e4,_0x5de1b6){_0x28b5e4=_0x28b5e4-0x0;let _0x3bd093=a814_0x5de1[_0x28b5e4];return _0x3bd093;};const _0x13a23e=a814_0x3bd0;'use strict';const Sequelize=require(_0x13a23e('0x1'));module[_0x13a23e('0x0')]={'uniqueid':{'type':Sequelize['STRING'],'allowNull':![]},'from':{'type':Sequelize[_0x13a23e('0x2')]},'joinAt':{'type':Sequelize['DATE']},'leaveAt':{'type':Sequelize[_0x13a23e('0x3')]},'acceptAt':{'type':Sequelize['DATE']},'exitAt':{'type':Sequelize[_0x13a23e('0x3')]},'reason':{'type':Sequelize[_0x13a23e('0x2')]}}; \ No newline at end of file +const a814_0x503f=['exports','DATE','STRING'];(function(_0x232093,_0x503f8f){const _0x333e11=function(_0x4c544f){while(--_0x4c544f){_0x232093['push'](_0x232093['shift']());}};_0x333e11(++_0x503f8f);}(a814_0x503f,0x11a));const a814_0x333e=function(_0x232093,_0x503f8f){_0x232093=_0x232093-0x0;let _0x333e11=a814_0x503f[_0x232093];return _0x333e11;};const _0x4b7426=a814_0x333e;'use strict';const Sequelize=require('sequelize');module[_0x4b7426('0x0')]={'uniqueid':{'type':Sequelize[_0x4b7426('0x2')],'allowNull':![]},'from':{'type':Sequelize[_0x4b7426('0x2')]},'joinAt':{'type':Sequelize[_0x4b7426('0x1')]},'leaveAt':{'type':Sequelize[_0x4b7426('0x1')]},'acceptAt':{'type':Sequelize['DATE']},'exitAt':{'type':Sequelize[_0x4b7426('0x1')]},'reason':{'type':Sequelize[_0x4b7426('0x2')]}}; \ No newline at end of file diff --git a/server/api/whatsappQueueReport/whatsappQueueReport.controller.js b/server/api/whatsappQueueReport/whatsappQueueReport.controller.js index cfabaf1..cae1f8c 100644 --- a/server/api/whatsappQueueReport/whatsappQueueReport.controller.js +++ b/server/api/whatsappQueueReport/whatsappQueueReport.controller.js @@ -1 +1 @@ -const a815_0x3c31=['rawAttributes','filter','then','WhatsappQueueReport','includeAll','count','fieldName','body','findAll','fields','../../config/logger','set','limit','type','merge','length','offset','map','params','where','VIRTUAL','model','attributes','update','../../mysqldb','status','create','include','index','name','Content-Range','intersection','query','sort','key','filters','api','json','nolimit','like','end','options','describe','destroy','catch','keys','../../components/parsers/qs','findOne','order','sendStatus'];(function(_0x2fc613,_0x3c3199){const _0x2b84c9=function(_0x41e7fd){while(--_0x41e7fd){_0x2fc613['push'](_0x2fc613['shift']());}};_0x2b84c9(++_0x3c3199);}(a815_0x3c31,0xf7));const a815_0x2b84=function(_0x2fc613,_0x3c3199){_0x2fc613=_0x2fc613-0x0;let _0x2b84c9=a815_0x3c31[_0x2fc613];return _0x2b84c9;};const _0x112782=a815_0x2b84;'use strict';const _=require('lodash'),qs=require(_0x112782('0x31')),logger=require(_0x112782('0xd'))(_0x112782('0x27')),db=require(_0x112782('0x1b'))['db'],{Op}=require('sequelize');function respondWithResult(_0x41e7fd,_0x2fb3a9){return _0x2fb3a9=_0x2fb3a9||0xc8,function(_0x2684d4){const _0x402bec=a815_0x2b84;if(_0x2684d4)return _0x41e7fd[_0x402bec('0x1c')](_0x2fb3a9)[_0x402bec('0x28')](_0x2684d4);};}function respondWithFilteredResult(_0x40fdba,_0x240be1){return function(_0xebc193){const _0x2d8e4b=a815_0x2b84;if(_0xebc193){const _0x43e36a=_0xebc193[_0x2d8e4b('0x8')],_0xa70034=_0x240be1[_0x2d8e4b('0x13')];let _0x53f020=_0x240be1['offset']+_0x240be1[_0x2d8e4b('0xf')],_0x587810;return _0x53f020>=_0x43e36a?(_0x53f020=_0x43e36a,_0x587810=0xc8):_0x587810=0xce,_0x40fdba['status'](_0x587810),_0x40fdba[_0x2d8e4b('0xe')](_0x2d8e4b('0x21'),_0xa70034+'-'+_0x53f020+'/'+_0x43e36a)['json'](_0xebc193);}return null;};}function saveUpdates(_0x2ee4ba){return function(_0x38028e){const _0x7fda49=a815_0x2b84;if(_0x38028e)return _0x38028e[_0x7fda49('0x1a')](_0x2ee4ba)[_0x7fda49('0x5')](function(_0x348be0){return _0x348be0;});return null;};}function removeEntity(_0x2b7f6f){return function(_0x17fd66){const _0x21a298=a815_0x2b84;if(_0x17fd66)return _0x17fd66['destroy']()[_0x21a298('0x5')](function(){const _0x3ea580=_0x21a298;_0x2b7f6f[_0x3ea580('0x1c')](0xcc)[_0x3ea580('0x2b')]();});};}function handleEntityNotFound(_0x4bc122){return function(_0x268142){const _0x2a7ec2=a815_0x2b84;return!_0x268142&&_0x4bc122[_0x2a7ec2('0x2')](0x194),_0x268142;};}function handleError(_0x455fec,_0x21580c){return _0x21580c=_0x21580c||0x1f4,function(_0x50399c){const _0x15889e=a815_0x2b84;logger['error'](_0x50399c['stack']),_0x50399c[_0x15889e('0x20')]&&delete _0x50399c[_0x15889e('0x20')],_0x455fec[_0x15889e('0x1c')](_0x21580c)['send'](_0x50399c);};}exports[_0x112782('0x1f')]=function(_0x270c54,_0x3fdc70){const _0x4cd522=_0x112782;let _0x4eee98={};const _0x21f9c6={},_0x4c5555={'count':0x0,'rows':[]},_0x1df90c=_['map'](db[_0x4cd522('0x6')][_0x4cd522('0x3')],function(_0x2af3fc){const _0xad1a72=_0x4cd522;return{'name':_0x2af3fc[_0xad1a72('0x9')],'type':_0x2af3fc[_0xad1a72('0x10')][_0xad1a72('0x25')]};});_0x21f9c6[_0x4cd522('0x18')]=_[_0x4cd522('0x14')](_0x1df90c,_0x4cd522('0x20')),_0x21f9c6[_0x4cd522('0x23')]=_['keys'](_0x270c54[_0x4cd522('0x23')]),_0x21f9c6['filters']=_[_0x4cd522('0x22')](_0x21f9c6[_0x4cd522('0x18')],_0x21f9c6[_0x4cd522('0x23')]),_0x4eee98['attributes']=_[_0x4cd522('0x22')](_0x21f9c6[_0x4cd522('0x18')],qs[_0x4cd522('0xc')](_0x270c54[_0x4cd522('0x23')][_0x4cd522('0xc')])),_0x4eee98[_0x4cd522('0x19')]=_0x4eee98[_0x4cd522('0x19')]['length']?_0x4eee98[_0x4cd522('0x19')]:_0x21f9c6[_0x4cd522('0x18')];typeof _0x270c54['query'][_0x4cd522('0x29')]==='undefined'&&(_0x4eee98[_0x4cd522('0xf')]=qs[_0x4cd522('0xf')](_0x270c54[_0x4cd522('0x23')][_0x4cd522('0xf')]),_0x4eee98[_0x4cd522('0x13')]=qs[_0x4cd522('0x13')](_0x270c54['query'][_0x4cd522('0x13')]));_0x4eee98[_0x4cd522('0x1')]=qs[_0x4cd522('0x24')](_0x270c54[_0x4cd522('0x23')][_0x4cd522('0x24')]),_0x4eee98[_0x4cd522('0x16')]=qs[_0x4cd522('0x26')](_['pick'](_0x270c54[_0x4cd522('0x23')],_0x21f9c6[_0x4cd522('0x26')]),_0x1df90c);_0x270c54[_0x4cd522('0x23')][_0x4cd522('0x4')]&&(_0x4eee98[_0x4cd522('0x16')]=_[_0x4cd522('0x11')](_0x4eee98['where'],{[Op['or']]:_[_0x4cd522('0x14')](_0x1df90c,function(_0x10f12d){const _0x4a42d0=_0x4cd522;if(_0x10f12d['type']!==_0x4a42d0('0x17')){const _0x465569={};return _0x465569[_0x10f12d[_0x4a42d0('0x20')]]={[Op[_0x4a42d0('0x2a')]]:'%'+_0x270c54[_0x4a42d0('0x23')][_0x4a42d0('0x4')]+'%'},_0x465569;}})}));_0x4eee98=_[_0x4cd522('0x11')]({},_0x4eee98,_0x270c54[_0x4cd522('0x2c')]);const _0x52ea83={'where':_0x4eee98['where']};return db[_0x4cd522('0x6')][_0x4cd522('0x8')](_0x52ea83)[_0x4cd522('0x5')](function(_0x226426){const _0x451752=_0x4cd522;return _0x4c5555[_0x451752('0x8')]=_0x226426,_0x270c54['query'][_0x451752('0x7')]&&(_0x4eee98[_0x451752('0x1e')]=[{'all':!![]}]),db[_0x451752('0x6')][_0x451752('0xb')](_0x4eee98);})[_0x4cd522('0x5')](function(_0xb0c356){return _0x4c5555['rows']=_0xb0c356,_0x4c5555;})['then'](respondWithFilteredResult(_0x3fdc70,_0x4eee98))[_0x4cd522('0x2f')](handleError(_0x3fdc70,null));},exports['show']=function(_0x4d0dff,_0x189715){const _0x5a870a=_0x112782;let _0x2be558={'raw':!![],'where':{'id':_0x4d0dff[_0x5a870a('0x15')]['id']}};const _0x22823f={};return _0x22823f[_0x5a870a('0x18')]=_[_0x5a870a('0x30')](db[_0x5a870a('0x6')]['rawAttributes']),_0x22823f[_0x5a870a('0x23')]=_['keys'](_0x4d0dff[_0x5a870a('0x23')]),_0x22823f[_0x5a870a('0x26')]=_['intersection'](_0x22823f['model'],_0x22823f[_0x5a870a('0x23')]),_0x2be558[_0x5a870a('0x19')]=_[_0x5a870a('0x22')](_0x22823f[_0x5a870a('0x18')],qs[_0x5a870a('0xc')](_0x4d0dff['query'][_0x5a870a('0xc')])),_0x2be558[_0x5a870a('0x19')]=_0x2be558[_0x5a870a('0x19')][_0x5a870a('0x12')]?_0x2be558[_0x5a870a('0x19')]:_0x22823f[_0x5a870a('0x18')],_0x4d0dff[_0x5a870a('0x23')][_0x5a870a('0x7')]&&(_0x2be558[_0x5a870a('0x1e')]=[{'all':!![]}]),_0x2be558=_[_0x5a870a('0x11')]({},_0x2be558,_0x4d0dff['options']),db[_0x5a870a('0x6')]['findOne'](_0x2be558)['then'](handleEntityNotFound(_0x189715,null))[_0x5a870a('0x5')](respondWithResult(_0x189715,null))[_0x5a870a('0x2f')](handleError(_0x189715,null));},exports['create']=function(_0x4e31f3,_0x2984c8){const _0x5ef03a=_0x112782;return db[_0x5ef03a('0x6')][_0x5ef03a('0x1d')](_0x4e31f3['body'],{})[_0x5ef03a('0x5')](respondWithResult(_0x2984c8,0xc9))[_0x5ef03a('0x2f')](handleError(_0x2984c8,null));},exports[_0x112782('0x1a')]=function(_0x4d9834,_0x13eab3){const _0x6f8380=_0x112782;return _0x4d9834[_0x6f8380('0xa')]['id']&&delete _0x4d9834[_0x6f8380('0xa')]['id'],db['WhatsappQueueReport'][_0x6f8380('0x0')]({'where':{'id':_0x4d9834[_0x6f8380('0x15')]['id']}})['then'](handleEntityNotFound(_0x13eab3,null))[_0x6f8380('0x5')](saveUpdates(_0x4d9834[_0x6f8380('0xa')],null))[_0x6f8380('0x5')](respondWithResult(_0x13eab3,null))[_0x6f8380('0x2f')](handleError(_0x13eab3,null));},exports[_0x112782('0x2e')]=function(_0x70343a,_0x1f6453){const _0x56ad38=_0x112782;return db[_0x56ad38('0x6')]['findOne']({'where':{'id':_0x70343a[_0x56ad38('0x15')]['id']}})[_0x56ad38('0x5')](handleEntityNotFound(_0x1f6453,null))[_0x56ad38('0x5')](removeEntity(_0x1f6453,null))[_0x56ad38('0x2f')](handleError(_0x1f6453,null));},exports[_0x112782('0x2d')]=function(_0x41fc14,_0x22ff7d){const _0x5137cf=_0x112782;return db[_0x5137cf('0x6')][_0x5137cf('0x2d')]()['then'](respondWithResult(_0x22ff7d,null))[_0x5137cf('0x2f')](handleError(_0x22ff7d,null));}; \ No newline at end of file +const a815_0x1a49=['includeAll','WhatsappQueueReport','../../mysqldb','key','fields','findOne','keys','fieldName','create','destroy','Content-Range','nolimit','model','../../config/logger','length','type','then','order','sequelize','name','index','filters','status','sort','set','update','like','body','offset','catch','send','intersection','findAll','options','error','show','VIRTUAL','sendStatus','params','json','limit','api','rows','end','describe','where','stack','lodash','map','undefined','count','merge','rawAttributes','include','query','attributes'];(function(_0x2bfb8e,_0x1a4983){const _0x31281f=function(_0x132d1f){while(--_0x132d1f){_0x2bfb8e['push'](_0x2bfb8e['shift']());}};_0x31281f(++_0x1a4983);}(a815_0x1a49,0x17e));const a815_0x3128=function(_0x2bfb8e,_0x1a4983){_0x2bfb8e=_0x2bfb8e-0x0;let _0x31281f=a815_0x1a49[_0x2bfb8e];return _0x31281f;};const _0x3e634c=a815_0x3128;'use strict';const _=require(_0x3e634c('0x1')),qs=require('../../components/parsers/qs'),logger=require(_0x3e634c('0x17'))(_0x3e634c('0x33')),db=require(_0x3e634c('0xc'))['db'],{Op}=require(_0x3e634c('0x1c'));function respondWithResult(_0x132d1f,_0x238ab5){return _0x238ab5=_0x238ab5||0xc8,function(_0x1ccd27){const _0x53de93=a815_0x3128;if(_0x1ccd27)return _0x132d1f['status'](_0x238ab5)[_0x53de93('0x31')](_0x1ccd27);};}function respondWithFilteredResult(_0x1569d7,_0x2055c2){return function(_0x2dc91e){const _0x18c469=a815_0x3128;if(_0x2dc91e){const _0x2bfb69=_0x2dc91e[_0x18c469('0x4')],_0x21cb3e=_0x2055c2[_0x18c469('0x26')];let _0x533e04=_0x2055c2[_0x18c469('0x26')]+_0x2055c2['limit'],_0x5cfd1c;return _0x533e04>=_0x2bfb69?(_0x533e04=_0x2bfb69,_0x5cfd1c=0xc8):_0x5cfd1c=0xce,_0x1569d7['status'](_0x5cfd1c),_0x1569d7[_0x18c469('0x22')](_0x18c469('0x14'),_0x21cb3e+'-'+_0x533e04+'/'+_0x2bfb69)[_0x18c469('0x31')](_0x2dc91e);}return null;};}function saveUpdates(_0x1abe4f){return function(_0x3c197a){const _0x2684ff=a815_0x3128;if(_0x3c197a)return _0x3c197a[_0x2684ff('0x23')](_0x1abe4f)[_0x2684ff('0x1a')](function(_0x4839d3){return _0x4839d3;});return null;};}function removeEntity(_0x581382){return function(_0x352585){const _0x43592e=a815_0x3128;if(_0x352585)return _0x352585[_0x43592e('0x13')]()['then'](function(){const _0x44191c=_0x43592e;_0x581382[_0x44191c('0x20')](0xcc)[_0x44191c('0x35')]();});};}function handleEntityNotFound(_0x9b52e7){return function(_0x4ab9c5){const _0x5871d2=a815_0x3128;return!_0x4ab9c5&&_0x9b52e7[_0x5871d2('0x2f')](0x194),_0x4ab9c5;};}function handleError(_0x1e32e2,_0xe11ee4){return _0xe11ee4=_0xe11ee4||0x1f4,function(_0x461efc){const _0x212552=a815_0x3128;logger[_0x212552('0x2c')](_0x461efc[_0x212552('0x0')]),_0x461efc['name']&&delete _0x461efc[_0x212552('0x1d')],_0x1e32e2[_0x212552('0x20')](_0xe11ee4)[_0x212552('0x28')](_0x461efc);};}exports[_0x3e634c('0x1e')]=function(_0x170c49,_0x207d08){const _0x4613c6=_0x3e634c;let _0x106043={};const _0x33e470={},_0xc859a={'count':0x0,'rows':[]},_0x321dbe=_[_0x4613c6('0x2')](db[_0x4613c6('0xb')][_0x4613c6('0x6')],function(_0x3d525c){const _0x357471=_0x4613c6;return{'name':_0x3d525c[_0x357471('0x11')],'type':_0x3d525c[_0x357471('0x19')][_0x357471('0xd')]};});_0x33e470[_0x4613c6('0x16')]=_['map'](_0x321dbe,_0x4613c6('0x1d')),_0x33e470[_0x4613c6('0x8')]=_[_0x4613c6('0x10')](_0x170c49[_0x4613c6('0x8')]),_0x33e470[_0x4613c6('0x1f')]=_['intersection'](_0x33e470['model'],_0x33e470[_0x4613c6('0x8')]),_0x106043[_0x4613c6('0x9')]=_['intersection'](_0x33e470['model'],qs[_0x4613c6('0xe')](_0x170c49[_0x4613c6('0x8')][_0x4613c6('0xe')])),_0x106043[_0x4613c6('0x9')]=_0x106043[_0x4613c6('0x9')]['length']?_0x106043['attributes']:_0x33e470[_0x4613c6('0x16')];typeof _0x170c49['query'][_0x4613c6('0x15')]===_0x4613c6('0x3')&&(_0x106043[_0x4613c6('0x32')]=qs['limit'](_0x170c49['query']['limit']),_0x106043['offset']=qs[_0x4613c6('0x26')](_0x170c49[_0x4613c6('0x8')][_0x4613c6('0x26')]));_0x106043[_0x4613c6('0x1b')]=qs['sort'](_0x170c49[_0x4613c6('0x8')][_0x4613c6('0x21')]),_0x106043[_0x4613c6('0x37')]=qs['filters'](_['pick'](_0x170c49[_0x4613c6('0x8')],_0x33e470[_0x4613c6('0x1f')]),_0x321dbe);_0x170c49[_0x4613c6('0x8')]['filter']&&(_0x106043['where']=_[_0x4613c6('0x5')](_0x106043['where'],{[Op['or']]:_[_0x4613c6('0x2')](_0x321dbe,function(_0x50eaf3){const _0x189f00=_0x4613c6;if(_0x50eaf3[_0x189f00('0x19')]!==_0x189f00('0x2e')){const _0x3e3ece={};return _0x3e3ece[_0x50eaf3[_0x189f00('0x1d')]]={[Op[_0x189f00('0x24')]]:'%'+_0x170c49[_0x189f00('0x8')]['filter']+'%'},_0x3e3ece;}})}));_0x106043=_[_0x4613c6('0x5')]({},_0x106043,_0x170c49[_0x4613c6('0x2b')]);const _0x453f2d={'where':_0x106043[_0x4613c6('0x37')]};return db[_0x4613c6('0xb')][_0x4613c6('0x4')](_0x453f2d)[_0x4613c6('0x1a')](function(_0x1f6378){const _0x959f4f=_0x4613c6;return _0xc859a[_0x959f4f('0x4')]=_0x1f6378,_0x170c49[_0x959f4f('0x8')][_0x959f4f('0xa')]&&(_0x106043[_0x959f4f('0x7')]=[{'all':!![]}]),db[_0x959f4f('0xb')][_0x959f4f('0x2a')](_0x106043);})[_0x4613c6('0x1a')](function(_0x52d332){const _0x2222cc=_0x4613c6;return _0xc859a[_0x2222cc('0x34')]=_0x52d332,_0xc859a;})[_0x4613c6('0x1a')](respondWithFilteredResult(_0x207d08,_0x106043))[_0x4613c6('0x27')](handleError(_0x207d08,null));},exports[_0x3e634c('0x2d')]=function(_0x40945f,_0x2af5ef){const _0x54fd79=_0x3e634c;let _0x5b54b8={'raw':!![],'where':{'id':_0x40945f[_0x54fd79('0x30')]['id']}};const _0x981edb={};return _0x981edb['model']=_['keys'](db['WhatsappQueueReport'][_0x54fd79('0x6')]),_0x981edb['query']=_[_0x54fd79('0x10')](_0x40945f['query']),_0x981edb[_0x54fd79('0x1f')]=_['intersection'](_0x981edb[_0x54fd79('0x16')],_0x981edb[_0x54fd79('0x8')]),_0x5b54b8['attributes']=_[_0x54fd79('0x29')](_0x981edb[_0x54fd79('0x16')],qs['fields'](_0x40945f[_0x54fd79('0x8')][_0x54fd79('0xe')])),_0x5b54b8['attributes']=_0x5b54b8[_0x54fd79('0x9')][_0x54fd79('0x18')]?_0x5b54b8[_0x54fd79('0x9')]:_0x981edb[_0x54fd79('0x16')],_0x40945f[_0x54fd79('0x8')][_0x54fd79('0xa')]&&(_0x5b54b8['include']=[{'all':!![]}]),_0x5b54b8=_['merge']({},_0x5b54b8,_0x40945f[_0x54fd79('0x2b')]),db[_0x54fd79('0xb')][_0x54fd79('0xf')](_0x5b54b8)['then'](handleEntityNotFound(_0x2af5ef,null))['then'](respondWithResult(_0x2af5ef,null))['catch'](handleError(_0x2af5ef,null));},exports[_0x3e634c('0x12')]=function(_0x40e78b,_0x6845ea){const _0x386877=_0x3e634c;return db['WhatsappQueueReport'][_0x386877('0x12')](_0x40e78b[_0x386877('0x25')],{})[_0x386877('0x1a')](respondWithResult(_0x6845ea,0xc9))[_0x386877('0x27')](handleError(_0x6845ea,null));},exports[_0x3e634c('0x23')]=function(_0x48618d,_0x164fc5){const _0x2cd139=_0x3e634c;return _0x48618d[_0x2cd139('0x25')]['id']&&delete _0x48618d['body']['id'],db[_0x2cd139('0xb')]['findOne']({'where':{'id':_0x48618d[_0x2cd139('0x30')]['id']}})[_0x2cd139('0x1a')](handleEntityNotFound(_0x164fc5,null))[_0x2cd139('0x1a')](saveUpdates(_0x48618d['body'],null))['then'](respondWithResult(_0x164fc5,null))[_0x2cd139('0x27')](handleError(_0x164fc5,null));},exports[_0x3e634c('0x13')]=function(_0x38bb6b,_0xf6d9ea){const _0x4ed20c=_0x3e634c;return db[_0x4ed20c('0xb')][_0x4ed20c('0xf')]({'where':{'id':_0x38bb6b[_0x4ed20c('0x30')]['id']}})[_0x4ed20c('0x1a')](handleEntityNotFound(_0xf6d9ea,null))[_0x4ed20c('0x1a')](removeEntity(_0xf6d9ea,null))[_0x4ed20c('0x27')](handleError(_0xf6d9ea,null));},exports[_0x3e634c('0x36')]=function(_0x18f212,_0x39867d){const _0x2302f9=_0x3e634c;return db[_0x2302f9('0xb')][_0x2302f9('0x36')]()[_0x2302f9('0x1a')](respondWithResult(_0x39867d,null))[_0x2302f9('0x27')](handleError(_0x39867d,null));}; \ No newline at end of file diff --git a/server/api/whatsappQueueReport/whatsappQueueReport.model.js b/server/api/whatsappQueueReport/whatsappQueueReport.model.js index d3cda92..6618063 100644 --- a/server/api/whatsappQueueReport/whatsappQueueReport.model.js +++ b/server/api/whatsappQueueReport/whatsappQueueReport.model.js @@ -1 +1 @@ -const a816_0x4110=['define','exports','uniqueid','./whatsappQueueReport.attributes','report_whatsapp_queue'];(function(_0x1faf4a,_0x41106e){const _0x298b56=function(_0x4f8e42){while(--_0x4f8e42){_0x1faf4a['push'](_0x1faf4a['shift']());}};_0x298b56(++_0x41106e);}(a816_0x4110,0xa5));const a816_0x298b=function(_0x1faf4a,_0x41106e){_0x1faf4a=_0x1faf4a-0x0;let _0x298b56=a816_0x4110[_0x1faf4a];return _0x298b56;};const _0x3044ed=a816_0x298b;'use strict';const attributes=require(_0x3044ed('0x3'));module[_0x3044ed('0x1')]=function(_0x4f8e42){const _0x368f08=_0x3044ed,_0x16fe53=_0x4f8e42[_0x368f08('0x0')]('WhatsappQueueReport',attributes,{'tableName':_0x368f08('0x4'),'paranoid':![],'indexes':[{'name':'uniqueid','fields':[_0x368f08('0x2')]}],'timestamps':!![]});return _0x16fe53;}; \ No newline at end of file +const a816_0x31c8=['report_whatsapp_queue','uniqueid','./whatsappQueueReport.attributes','WhatsappQueueReport'];(function(_0x34fbb9,_0x31c8e8){const _0x413826=function(_0xa590e){while(--_0xa590e){_0x34fbb9['push'](_0x34fbb9['shift']());}};_0x413826(++_0x31c8e8);}(a816_0x31c8,0xe8));const a816_0x4138=function(_0x34fbb9,_0x31c8e8){_0x34fbb9=_0x34fbb9-0x0;let _0x413826=a816_0x31c8[_0x34fbb9];return _0x413826;};const _0x3c9df9=a816_0x4138;'use strict';const attributes=require(_0x3c9df9('0x2'));module['exports']=function(_0xa590e){const _0x36e81d=_0x3c9df9,_0x53ebe1=_0xa590e['define'](_0x36e81d('0x3'),attributes,{'tableName':_0x36e81d('0x0'),'paranoid':![],'indexes':[{'name':'uniqueid','fields':[_0x36e81d('0x1')]}],'timestamps':!![]});return _0x53ebe1;}; \ No newline at end of file diff --git a/server/api/whatsappQueueReport/whatsappQueueReport.rpc.js b/server/api/whatsappQueueReport/whatsappQueueReport.rpc.js index e239ab4..5453305 100644 --- a/server/api/whatsappQueueReport/whatsappQueueReport.rpc.js +++ b/server/api/whatsappQueueReport/whatsappQueueReport.rpc.js @@ -1 +1 @@ -const a817_0x31af=['WhatsappQueueReport','options','error','rpc','CreateWhatsappQueueReport','body','../../config/logger','raw','where','stringify','limit','../../mysqldb','then','attributes','debug','create','message','UpdateWhatsappQueueReport'];(function(_0x4d9a55,_0x31af7f){const _0x4e62d1=function(_0xc674f2){while(--_0xc674f2){_0x4d9a55['push'](_0x4d9a55['shift']());}};_0x4e62d1(++_0x31af7f);}(a817_0x31af,0x142));const a817_0x4e62=function(_0x4d9a55,_0x31af7f){_0x4d9a55=_0x4d9a55-0x0;let _0x4e62d1=a817_0x31af[_0x4d9a55];return _0x4e62d1;};const _0x42a9a3=a817_0x4e62;'use strict';const db=require(_0x42a9a3('0xd'))['db'],logger=require(_0x42a9a3('0x8'))(_0x42a9a3('0x5'));exports['CreateWhatsappQueueReport']=function(_0xc674f2){const _0x1fc7f1=this;return new Promise(function(_0xbd125f,_0x100fe8){const _0x1e69de=a817_0x4e62;return db[_0x1e69de('0x2')][_0x1e69de('0x11')](_0xc674f2[_0x1e69de('0x7')],{'raw':_0xc674f2['options']?_0xc674f2[_0x1e69de('0x3')][_0x1e69de('0x9')]===undefined?!![]:![]:!![]})[_0x1e69de('0xe')](function(_0x18ecd5){const _0x41435e=_0x1e69de;logger['info'](_0x41435e('0x6'),_0xc674f2),logger[_0x41435e('0x10')](_0x41435e('0x6'),_0xc674f2,JSON[_0x41435e('0xb')](_0x18ecd5)),_0xbd125f(_0x18ecd5);})['catch'](function(_0x10b606){const _0x5442cc=_0x1e69de;logger[_0x5442cc('0x4')]('CreateWhatsappQueueReport',_0x10b606[_0x5442cc('0x0')],_0xc674f2),_0x100fe8(_0x1fc7f1[_0x5442cc('0x4')](0x1f4,_0x10b606[_0x5442cc('0x0')]));});});},exports['UpdateWhatsappQueueReport']=function(_0x3b723c){const _0x2ddbf3=this;return new Promise(function(_0x2d22db,_0x37b0b0){const _0x42eb3e=a817_0x4e62;return db[_0x42eb3e('0x2')]['update'](_0x3b723c[_0x42eb3e('0x7')],{'raw':_0x3b723c[_0x42eb3e('0x3')]?_0x3b723c[_0x42eb3e('0x3')][_0x42eb3e('0x9')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x3b723c[_0x42eb3e('0x3')]?_0x3b723c[_0x42eb3e('0x3')][_0x42eb3e('0xa')]||null:null,'attributes':_0x3b723c[_0x42eb3e('0x3')]?_0x3b723c[_0x42eb3e('0x3')][_0x42eb3e('0xf')]||null:null,'limit':_0x3b723c['options']?_0x3b723c[_0x42eb3e('0x3')][_0x42eb3e('0xc')]||null:null})[_0x42eb3e('0xe')](function(_0x335c83){const _0x19cbca=_0x42eb3e;logger['info'](_0x19cbca('0x1'),_0x3b723c),logger[_0x19cbca('0x10')](_0x19cbca('0x1'),_0x3b723c,JSON[_0x19cbca('0xb')](_0x335c83)),_0x2d22db(_0x335c83);})['catch'](function(_0x57f704){const _0x1a8f63=_0x42eb3e;logger[_0x1a8f63('0x4')]('UpdateWhatsappQueueReport',_0x57f704[_0x1a8f63('0x0')],_0x3b723c),_0x37b0b0(_0x2ddbf3['error'](0x1f4,_0x57f704['message']));});});}; \ No newline at end of file +const a817_0x2ab6=['attributes','message','WhatsappQueueReport','body','../../config/logger','../../mysqldb','limit','then','raw','options','stringify','UpdateWhatsappQueueReport','where','rpc','CreateWhatsappQueueReport','debug','info','error'];(function(_0x4d3485,_0x2ab690){const _0x4b5787=function(_0x2f44c6){while(--_0x2f44c6){_0x4d3485['push'](_0x4d3485['shift']());}};_0x4b5787(++_0x2ab690);}(a817_0x2ab6,0x1d8));const a817_0x4b57=function(_0x4d3485,_0x2ab690){_0x4d3485=_0x4d3485-0x0;let _0x4b5787=a817_0x2ab6[_0x4d3485];return _0x4b5787;};const _0xe4a39e=a817_0x4b57;'use strict';const db=require(_0xe4a39e('0x1'))['db'],logger=require(_0xe4a39e('0x0'))(_0xe4a39e('0x9'));exports[_0xe4a39e('0xa')]=function(_0x2f44c6){const _0x5d8d08=this;return new Promise(function(_0x372285,_0x26857d){const _0x44bee6=a817_0x4b57;return db[_0x44bee6('0x10')]['create'](_0x2f44c6[_0x44bee6('0x11')],{'raw':_0x2f44c6[_0x44bee6('0x5')]?_0x2f44c6[_0x44bee6('0x5')]['raw']===undefined?!![]:![]:!![]})[_0x44bee6('0x3')](function(_0x22bc8f){const _0x1261d9=_0x44bee6;logger[_0x1261d9('0xc')](_0x1261d9('0xa'),_0x2f44c6),logger['debug'](_0x1261d9('0xa'),_0x2f44c6,JSON[_0x1261d9('0x6')](_0x22bc8f)),_0x372285(_0x22bc8f);})['catch'](function(_0x5e5be7){const _0x310b6d=_0x44bee6;logger[_0x310b6d('0xd')](_0x310b6d('0xa'),_0x5e5be7['message'],_0x2f44c6),_0x26857d(_0x5d8d08[_0x310b6d('0xd')](0x1f4,_0x5e5be7[_0x310b6d('0xf')]));});});},exports[_0xe4a39e('0x7')]=function(_0x355ec7){const _0xe9464a=this;return new Promise(function(_0x4a6c62,_0x1aeec9){const _0x171f96=a817_0x4b57;return db[_0x171f96('0x10')]['update'](_0x355ec7[_0x171f96('0x11')],{'raw':_0x355ec7['options']?_0x355ec7[_0x171f96('0x5')][_0x171f96('0x4')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x355ec7['options']?_0x355ec7['options'][_0x171f96('0x8')]||null:null,'attributes':_0x355ec7[_0x171f96('0x5')]?_0x355ec7['options'][_0x171f96('0xe')]||null:null,'limit':_0x355ec7['options']?_0x355ec7[_0x171f96('0x5')][_0x171f96('0x2')]||null:null})[_0x171f96('0x3')](function(_0x28d338){const _0x2f5c5c=_0x171f96;logger[_0x2f5c5c('0xc')]('UpdateWhatsappQueueReport',_0x355ec7),logger[_0x2f5c5c('0xb')](_0x2f5c5c('0x7'),_0x355ec7,JSON[_0x2f5c5c('0x6')](_0x28d338)),_0x4a6c62(_0x28d338);})['catch'](function(_0x1f933c){const _0x431d43=_0x171f96;logger[_0x431d43('0xd')](_0x431d43('0x7'),_0x1f933c[_0x431d43('0xf')],_0x355ec7),_0x1aeec9(_0xe9464a[_0x431d43('0xd')](0x1f4,_0x1f933c[_0x431d43('0xf')]));});});}; \ No newline at end of file diff --git a/server/api/whatsappTransferReport/index.js b/server/api/whatsappTransferReport/index.js index a204ba4..2e0ddea 100644 --- a/server/api/whatsappTransferReport/index.js +++ b/server/api/whatsappTransferReport/index.js @@ -1 +1 @@ -const a818_0x58c2=['create','destroy','../../components/auth/service','get','./whatsappTransferReport.controller','delete','Router','/describe','exports','put','isAuthenticated','describe','/:id','index'];(function(_0x480091,_0x58c25a){const _0x22d4f7=function(_0x4b2680){while(--_0x4b2680){_0x480091['push'](_0x480091['shift']());}};_0x22d4f7(++_0x58c25a);}(a818_0x58c2,0x7b));const a818_0x22d4=function(_0x480091,_0x58c25a){_0x480091=_0x480091-0x0;let _0x22d4f7=a818_0x58c2[_0x480091];return _0x22d4f7;};const _0x296d16=a818_0x22d4;'use strict';const express=require('express'),router=express[_0x296d16('0x9')](),auth=require(_0x296d16('0x5')),controller=require(_0x296d16('0x7'));router[_0x296d16('0x6')]('/',auth['isAuthenticated'](),controller[_0x296d16('0x2')]),router[_0x296d16('0x6')](_0x296d16('0xa'),auth['isAuthenticated'](),controller[_0x296d16('0x0')]),router[_0x296d16('0x6')]('/:id',auth[_0x296d16('0xd')](),controller['show']),router['post']('/',auth[_0x296d16('0xd')](),controller[_0x296d16('0x3')]),router[_0x296d16('0xc')](_0x296d16('0x1'),auth[_0x296d16('0xd')](),controller['update']),router[_0x296d16('0x8')]('/:id',auth[_0x296d16('0xd')](),controller[_0x296d16('0x4')]),module[_0x296d16('0xb')]=router; \ No newline at end of file +const a818_0x2fee=['isAuthenticated','update','destroy','delete','./whatsappTransferReport.controller','put','index','express','Router','get','exports','/:id','/describe','../../components/auth/service','show','describe'];(function(_0x1e7adc,_0x2fee78){const _0x128b16=function(_0x25cbdc){while(--_0x25cbdc){_0x1e7adc['push'](_0x1e7adc['shift']());}};_0x128b16(++_0x2fee78);}(a818_0x2fee,0x65));const a818_0x128b=function(_0x1e7adc,_0x2fee78){_0x1e7adc=_0x1e7adc-0x0;let _0x128b16=a818_0x2fee[_0x1e7adc];return _0x128b16;};const _0x4dc62b=a818_0x128b;'use strict';const express=require(_0x4dc62b('0x2')),router=express[_0x4dc62b('0x3')](),auth=require(_0x4dc62b('0x8')),controller=require(_0x4dc62b('0xf'));router[_0x4dc62b('0x4')]('/',auth[_0x4dc62b('0xb')](),controller[_0x4dc62b('0x1')]),router[_0x4dc62b('0x4')](_0x4dc62b('0x7'),auth[_0x4dc62b('0xb')](),controller[_0x4dc62b('0xa')]),router[_0x4dc62b('0x4')](_0x4dc62b('0x6'),auth[_0x4dc62b('0xb')](),controller[_0x4dc62b('0x9')]),router['post']('/',auth['isAuthenticated'](),controller['create']),router[_0x4dc62b('0x0')]('/:id',auth[_0x4dc62b('0xb')](),controller[_0x4dc62b('0xc')]),router[_0x4dc62b('0xe')](_0x4dc62b('0x6'),auth[_0x4dc62b('0xb')](),controller[_0x4dc62b('0xd')]),module[_0x4dc62b('0x5')]=router; \ No newline at end of file diff --git a/server/api/whatsappTransferReport/whatsappTransferReport.attributes.js b/server/api/whatsappTransferReport/whatsappTransferReport.attributes.js index a7fbde9..b81e6e6 100644 --- a/server/api/whatsappTransferReport/whatsappTransferReport.attributes.js +++ b/server/api/whatsappTransferReport/whatsappTransferReport.attributes.js @@ -1 +1 @@ -const a819_0x11f0=['STRING','sequelize','ENUM','agent','queue','account'];(function(_0x38dc33,_0x11f068){const _0x3247f6=function(_0x195dbc){while(--_0x195dbc){_0x38dc33['push'](_0x38dc33['shift']());}};_0x3247f6(++_0x11f068);}(a819_0x11f0,0x184));const a819_0x3247=function(_0x38dc33,_0x11f068){_0x38dc33=_0x38dc33-0x0;let _0x3247f6=a819_0x11f0[_0x38dc33];return _0x3247f6;};const _0x3bd8f4=a819_0x3247;'use strict';const Sequelize=require(_0x3bd8f4('0x3'));module['exports']={'uniqueid':{'type':Sequelize[_0x3bd8f4('0x2')],'allowNull':![]},'type':{'type':Sequelize[_0x3bd8f4('0x4')](_0x3bd8f4('0x1'),_0x3bd8f4('0x5'),_0x3bd8f4('0x0')),'allowNull':![]},'transferredAt':{'type':Sequelize['DATE']}}; \ No newline at end of file +const a819_0x1002=['exports','DATE','ENUM','STRING','account'];(function(_0x352074,_0x100244){const _0x11ea27=function(_0x5a32b1){while(--_0x5a32b1){_0x352074['push'](_0x352074['shift']());}};_0x11ea27(++_0x100244);}(a819_0x1002,0x15a));const a819_0x11ea=function(_0x352074,_0x100244){_0x352074=_0x352074-0x0;let _0x11ea27=a819_0x1002[_0x352074];return _0x11ea27;};const _0x646832=a819_0x11ea;'use strict';const Sequelize=require('sequelize');module[_0x646832('0x4')]={'uniqueid':{'type':Sequelize[_0x646832('0x2')],'allowNull':![]},'type':{'type':Sequelize[_0x646832('0x1')](_0x646832('0x3'),'agent','queue'),'allowNull':![]},'transferredAt':{'type':Sequelize[_0x646832('0x0')]}}; \ No newline at end of file diff --git a/server/api/whatsappTransferReport/whatsappTransferReport.controller.js b/server/api/whatsappTransferReport/whatsappTransferReport.controller.js index aa6770c..f8f03db 100644 --- a/server/api/whatsappTransferReport/whatsappTransferReport.controller.js +++ b/server/api/whatsappTransferReport/whatsappTransferReport.controller.js @@ -1 +1 @@ -const a820_0x5fd7=['../../components/parsers/qs','end','options','type','findOne','merge','json','fieldName','order','intersection','map','sequelize','limit','filter','update','WhatsappTransferReport','findAll','catch','params','then','rows','stack','where','send','create','set','../../config/logger','query','destroy','offset','rawAttributes','count','filters','sendStatus','undefined','body','index','error','includeAll','keys','nolimit','length','VIRTUAL','status','like','key','api','../../mysqldb','name','fields','describe','attributes','sort','model','include','lodash'];(function(_0x283357,_0x5fd785){const _0x5cce15=function(_0x1a2392){while(--_0x1a2392){_0x283357['push'](_0x283357['shift']());}};_0x5cce15(++_0x5fd785);}(a820_0x5fd7,0x178));const a820_0x5cce=function(_0x283357,_0x5fd785){_0x283357=_0x283357-0x0;let _0x5cce15=a820_0x5fd7[_0x283357];return _0x5cce15;};const _0x36313b=a820_0x5cce;'use strict';const _=require(_0x36313b('0xf')),qs=require(_0x36313b('0x10')),logger=require(_0x36313b('0x2a'))(_0x36313b('0x6')),db=require(_0x36313b('0x7'))['db'],{Op}=require(_0x36313b('0x1b'));function respondWithResult(_0x1a2392,_0x4ca750){return _0x4ca750=_0x4ca750||0xc8,function(_0x3c26f3){const _0x222dd1=a820_0x5cce;if(_0x3c26f3)return _0x1a2392[_0x222dd1('0x3')](_0x4ca750)['json'](_0x3c26f3);};}function respondWithFilteredResult(_0x21b58b,_0x5191e1){return function(_0xbfde04){const _0x21b1e7=a820_0x5cce;if(_0xbfde04){const _0x5aa87e=_0xbfde04[_0x21b1e7('0x2f')],_0x488024=_0x5191e1[_0x21b1e7('0x2d')];let _0x389110=_0x5191e1[_0x21b1e7('0x2d')]+_0x5191e1[_0x21b1e7('0x1c')],_0xa8c799;return _0x389110>=_0x5aa87e?(_0x389110=_0x5aa87e,_0xa8c799=0xc8):_0xa8c799=0xce,_0x21b58b[_0x21b1e7('0x3')](_0xa8c799),_0x21b58b[_0x21b1e7('0x29')]('Content-Range',_0x488024+'-'+_0x389110+'/'+_0x5aa87e)[_0x21b1e7('0x16')](_0xbfde04);}return null;};}function saveUpdates(_0x1c0506){return function(_0x100d1a){const _0xb1bf57=a820_0x5cce;if(_0x100d1a)return _0x100d1a[_0xb1bf57('0x1e')](_0x1c0506)['then'](function(_0x2377c8){return _0x2377c8;});return null;};}function removeEntity(_0x5c17f5){return function(_0x43e947){const _0x1087ef=a820_0x5cce;if(_0x43e947)return _0x43e947[_0x1087ef('0x2c')]()['then'](function(){const _0x2cee3e=_0x1087ef;_0x5c17f5[_0x2cee3e('0x3')](0xcc)[_0x2cee3e('0x11')]();});};}function handleEntityNotFound(_0x5da5c4){return function(_0x5c89e7){const _0x123252=a820_0x5cce;return!_0x5c89e7&&_0x5da5c4[_0x123252('0x31')](0x194),_0x5c89e7;};}function handleError(_0x33de49,_0xbe8aa7){return _0xbe8aa7=_0xbe8aa7||0x1f4,function(_0x2793f7){const _0x28a33b=a820_0x5cce;logger[_0x28a33b('0x35')](_0x2793f7[_0x28a33b('0x25')]),_0x2793f7[_0x28a33b('0x8')]&&delete _0x2793f7[_0x28a33b('0x8')],_0x33de49['status'](_0xbe8aa7)[_0x28a33b('0x27')](_0x2793f7);};}exports[_0x36313b('0x34')]=function(_0x101fd4,_0xbce1a6){const _0x4cbd73=_0x36313b;let _0x641ab3={};const _0x2c51b9={},_0x1b693c={'count':0x0,'rows':[]},_0x44ef53=_[_0x4cbd73('0x1a')](db[_0x4cbd73('0x1f')]['rawAttributes'],function(_0x1248d8){const _0x34844d=_0x4cbd73;return{'name':_0x1248d8[_0x34844d('0x17')],'type':_0x1248d8['type'][_0x34844d('0x5')]};});_0x2c51b9[_0x4cbd73('0xd')]=_['map'](_0x44ef53,_0x4cbd73('0x8')),_0x2c51b9['query']=_[_0x4cbd73('0x37')](_0x101fd4[_0x4cbd73('0x2b')]),_0x2c51b9[_0x4cbd73('0x30')]=_[_0x4cbd73('0x19')](_0x2c51b9[_0x4cbd73('0xd')],_0x2c51b9[_0x4cbd73('0x2b')]),_0x641ab3[_0x4cbd73('0xb')]=_['intersection'](_0x2c51b9[_0x4cbd73('0xd')],qs[_0x4cbd73('0x9')](_0x101fd4[_0x4cbd73('0x2b')][_0x4cbd73('0x9')])),_0x641ab3[_0x4cbd73('0xb')]=_0x641ab3[_0x4cbd73('0xb')][_0x4cbd73('0x1')]?_0x641ab3['attributes']:_0x2c51b9[_0x4cbd73('0xd')];typeof _0x101fd4['query'][_0x4cbd73('0x0')]===_0x4cbd73('0x32')&&(_0x641ab3['limit']=qs[_0x4cbd73('0x1c')](_0x101fd4[_0x4cbd73('0x2b')]['limit']),_0x641ab3['offset']=qs[_0x4cbd73('0x2d')](_0x101fd4['query'][_0x4cbd73('0x2d')]));_0x641ab3[_0x4cbd73('0x18')]=qs[_0x4cbd73('0xc')](_0x101fd4[_0x4cbd73('0x2b')][_0x4cbd73('0xc')]),_0x641ab3[_0x4cbd73('0x26')]=qs[_0x4cbd73('0x30')](_['pick'](_0x101fd4[_0x4cbd73('0x2b')],_0x2c51b9['filters']),_0x44ef53);_0x101fd4[_0x4cbd73('0x2b')][_0x4cbd73('0x1d')]&&(_0x641ab3[_0x4cbd73('0x26')]=_[_0x4cbd73('0x15')](_0x641ab3['where'],{[Op['or']]:_[_0x4cbd73('0x1a')](_0x44ef53,function(_0xe832f8){const _0x36460d=_0x4cbd73;if(_0xe832f8[_0x36460d('0x13')]!==_0x36460d('0x2')){const _0x4903d9={};return _0x4903d9[_0xe832f8['name']]={[Op[_0x36460d('0x4')]]:'%'+_0x101fd4[_0x36460d('0x2b')][_0x36460d('0x1d')]+'%'},_0x4903d9;}})}));_0x641ab3=_[_0x4cbd73('0x15')]({},_0x641ab3,_0x101fd4[_0x4cbd73('0x12')]);const _0x40640f={'where':_0x641ab3['where']};return db[_0x4cbd73('0x1f')][_0x4cbd73('0x2f')](_0x40640f)[_0x4cbd73('0x23')](function(_0x458e9f){const _0x9d222=_0x4cbd73;return _0x1b693c[_0x9d222('0x2f')]=_0x458e9f,_0x101fd4[_0x9d222('0x2b')][_0x9d222('0x36')]&&(_0x641ab3[_0x9d222('0xe')]=[{'all':!![]}]),db['WhatsappTransferReport'][_0x9d222('0x20')](_0x641ab3);})[_0x4cbd73('0x23')](function(_0x498d7c){const _0x34612e=_0x4cbd73;return _0x1b693c[_0x34612e('0x24')]=_0x498d7c,_0x1b693c;})[_0x4cbd73('0x23')](respondWithFilteredResult(_0xbce1a6,_0x641ab3))[_0x4cbd73('0x21')](handleError(_0xbce1a6,null));},exports['show']=function(_0xa5452,_0x3540fd){const _0x41b1e9=_0x36313b;let _0x40b863={'raw':!![],'where':{'id':_0xa5452[_0x41b1e9('0x22')]['id']}};const _0x20da17={};return _0x20da17[_0x41b1e9('0xd')]=_[_0x41b1e9('0x37')](db[_0x41b1e9('0x1f')][_0x41b1e9('0x2e')]),_0x20da17[_0x41b1e9('0x2b')]=_[_0x41b1e9('0x37')](_0xa5452[_0x41b1e9('0x2b')]),_0x20da17[_0x41b1e9('0x30')]=_[_0x41b1e9('0x19')](_0x20da17[_0x41b1e9('0xd')],_0x20da17['query']),_0x40b863[_0x41b1e9('0xb')]=_[_0x41b1e9('0x19')](_0x20da17[_0x41b1e9('0xd')],qs['fields'](_0xa5452['query']['fields'])),_0x40b863[_0x41b1e9('0xb')]=_0x40b863[_0x41b1e9('0xb')][_0x41b1e9('0x1')]?_0x40b863[_0x41b1e9('0xb')]:_0x20da17[_0x41b1e9('0xd')],_0xa5452[_0x41b1e9('0x2b')][_0x41b1e9('0x36')]&&(_0x40b863[_0x41b1e9('0xe')]=[{'all':!![]}]),_0x40b863=_[_0x41b1e9('0x15')]({},_0x40b863,_0xa5452[_0x41b1e9('0x12')]),db[_0x41b1e9('0x1f')]['findOne'](_0x40b863)[_0x41b1e9('0x23')](handleEntityNotFound(_0x3540fd,null))[_0x41b1e9('0x23')](respondWithResult(_0x3540fd,null))[_0x41b1e9('0x21')](handleError(_0x3540fd,null));},exports[_0x36313b('0x28')]=function(_0x43e721,_0x69bc41){const _0x4d4764=_0x36313b;return db[_0x4d4764('0x1f')][_0x4d4764('0x28')](_0x43e721['body'],{})[_0x4d4764('0x23')](respondWithResult(_0x69bc41,0xc9))[_0x4d4764('0x21')](handleError(_0x69bc41,null));},exports[_0x36313b('0x1e')]=function(_0x3d1c69,_0x35c40e){const _0x44c529=_0x36313b;return _0x3d1c69['body']['id']&&delete _0x3d1c69[_0x44c529('0x33')]['id'],db['WhatsappTransferReport'][_0x44c529('0x14')]({'where':{'id':_0x3d1c69[_0x44c529('0x22')]['id']}})[_0x44c529('0x23')](handleEntityNotFound(_0x35c40e,null))['then'](saveUpdates(_0x3d1c69[_0x44c529('0x33')],null))['then'](respondWithResult(_0x35c40e,null))[_0x44c529('0x21')](handleError(_0x35c40e,null));},exports['destroy']=function(_0xe2ff31,_0xd893de){const _0x4a20cb=_0x36313b;return db[_0x4a20cb('0x1f')][_0x4a20cb('0x14')]({'where':{'id':_0xe2ff31['params']['id']}})[_0x4a20cb('0x23')](handleEntityNotFound(_0xd893de,null))[_0x4a20cb('0x23')](removeEntity(_0xd893de,null))[_0x4a20cb('0x21')](handleError(_0xd893de,null));},exports[_0x36313b('0xa')]=function(_0x8fe655,_0x4a9d58){const _0x3c4005=_0x36313b;return db['WhatsappTransferReport']['describe']()[_0x3c4005('0x23')](respondWithResult(_0x4a9d58,null))[_0x3c4005('0x21')](handleError(_0x4a9d58,null));}; \ No newline at end of file +const a820_0x121c=['type','../../components/parsers/qs','include','where','model','catch','map','end','like','status','fields','key','VIRTUAL','intersection','rawAttributes','limit','filters','merge','then','filter','name','findAll','update','error','offset','includeAll','WhatsappTransferReport','pick','keys','body','findOne','undefined','length','sort','rows','show','lodash','create','sequelize','attributes','query','../../config/logger','options','send','json','order','count','params','stack','nolimit','../../mysqldb','sendStatus','destroy','describe','fieldName'];(function(_0x18c1b2,_0x121cdb){const _0x58255f=function(_0x2192d7){while(--_0x2192d7){_0x18c1b2['push'](_0x18c1b2['shift']());}};_0x58255f(++_0x121cdb);}(a820_0x121c,0x153));const a820_0x5825=function(_0x18c1b2,_0x121cdb){_0x18c1b2=_0x18c1b2-0x0;let _0x58255f=a820_0x121c[_0x18c1b2];return _0x58255f;};const _0x4c314f=a820_0x5825;'use strict';const _=require(_0x4c314f('0x1b')),qs=require(_0x4c314f('0x2f')),logger=require(_0x4c314f('0x20'))('api'),db=require(_0x4c314f('0x29'))['db'],{Op}=require(_0x4c314f('0x1d'));function respondWithResult(_0x2192d7,_0x57490f){return _0x57490f=_0x57490f||0xc8,function(_0xf1db04){const _0x460a87=a820_0x5825;if(_0xf1db04)return _0x2192d7[_0x460a87('0x0')](_0x57490f)[_0x460a87('0x23')](_0xf1db04);};}function respondWithFilteredResult(_0x30cf20,_0x16a0f9){return function(_0x526fe6){const _0x528a4a=a820_0x5825;if(_0x526fe6){const _0x2da0f6=_0x526fe6['count'],_0x34c9a7=_0x16a0f9[_0x528a4a('0xf')];let _0x5e671c=_0x16a0f9[_0x528a4a('0xf')]+_0x16a0f9[_0x528a4a('0x6')],_0x48105e;return _0x5e671c>=_0x2da0f6?(_0x5e671c=_0x2da0f6,_0x48105e=0xc8):_0x48105e=0xce,_0x30cf20[_0x528a4a('0x0')](_0x48105e),_0x30cf20['set']('Content-Range',_0x34c9a7+'-'+_0x5e671c+'/'+_0x2da0f6)[_0x528a4a('0x23')](_0x526fe6);}return null;};}function saveUpdates(_0x364ab9){return function(_0x2d5b8d){const _0xf28a20=a820_0x5825;if(_0x2d5b8d)return _0x2d5b8d[_0xf28a20('0xd')](_0x364ab9)[_0xf28a20('0x9')](function(_0x5d2b77){return _0x5d2b77;});return null;};}function removeEntity(_0x370f59){return function(_0x4460d4){const _0x4cda31=a820_0x5825;if(_0x4460d4)return _0x4460d4[_0x4cda31('0x2b')]()['then'](function(){const _0x2783f5=_0x4cda31;_0x370f59[_0x2783f5('0x0')](0xcc)[_0x2783f5('0x35')]();});};}function handleEntityNotFound(_0x1bd47a){return function(_0x295b05){const _0x202946=a820_0x5825;return!_0x295b05&&_0x1bd47a[_0x202946('0x2a')](0x194),_0x295b05;};}function handleError(_0x528007,_0x12e491){return _0x12e491=_0x12e491||0x1f4,function(_0x3c0d9f){const _0x59b7dc=a820_0x5825;logger[_0x59b7dc('0xe')](_0x3c0d9f[_0x59b7dc('0x27')]),_0x3c0d9f['name']&&delete _0x3c0d9f['name'],_0x528007[_0x59b7dc('0x0')](_0x12e491)[_0x59b7dc('0x22')](_0x3c0d9f);};}exports['index']=function(_0x2caa57,_0x2a159a){const _0x41ed71=_0x4c314f;let _0x18ff35={};const _0x4e660d={},_0x4be508={'count':0x0,'rows':[]},_0x59a5b0=_['map'](db['WhatsappTransferReport'][_0x41ed71('0x5')],function(_0x26872f){const _0x223469=_0x41ed71;return{'name':_0x26872f[_0x223469('0x2d')],'type':_0x26872f['type'][_0x223469('0x2')]};});_0x4e660d[_0x41ed71('0x32')]=_[_0x41ed71('0x34')](_0x59a5b0,'name'),_0x4e660d[_0x41ed71('0x1f')]=_[_0x41ed71('0x13')](_0x2caa57['query']),_0x4e660d[_0x41ed71('0x7')]=_['intersection'](_0x4e660d[_0x41ed71('0x32')],_0x4e660d[_0x41ed71('0x1f')]),_0x18ff35[_0x41ed71('0x1e')]=_['intersection'](_0x4e660d[_0x41ed71('0x32')],qs[_0x41ed71('0x1')](_0x2caa57['query'][_0x41ed71('0x1')])),_0x18ff35['attributes']=_0x18ff35[_0x41ed71('0x1e')][_0x41ed71('0x17')]?_0x18ff35[_0x41ed71('0x1e')]:_0x4e660d[_0x41ed71('0x32')];typeof _0x2caa57[_0x41ed71('0x1f')][_0x41ed71('0x28')]===_0x41ed71('0x16')&&(_0x18ff35[_0x41ed71('0x6')]=qs['limit'](_0x2caa57['query'][_0x41ed71('0x6')]),_0x18ff35[_0x41ed71('0xf')]=qs[_0x41ed71('0xf')](_0x2caa57[_0x41ed71('0x1f')][_0x41ed71('0xf')]));_0x18ff35[_0x41ed71('0x24')]=qs['sort'](_0x2caa57[_0x41ed71('0x1f')][_0x41ed71('0x18')]),_0x18ff35[_0x41ed71('0x31')]=qs[_0x41ed71('0x7')](_[_0x41ed71('0x12')](_0x2caa57[_0x41ed71('0x1f')],_0x4e660d['filters']),_0x59a5b0);_0x2caa57['query'][_0x41ed71('0xa')]&&(_0x18ff35[_0x41ed71('0x31')]=_[_0x41ed71('0x8')](_0x18ff35[_0x41ed71('0x31')],{[Op['or']]:_[_0x41ed71('0x34')](_0x59a5b0,function(_0x4588a2){const _0x37c98e=_0x41ed71;if(_0x4588a2[_0x37c98e('0x2e')]!==_0x37c98e('0x3')){const _0x32f4eb={};return _0x32f4eb[_0x4588a2[_0x37c98e('0xb')]]={[Op[_0x37c98e('0x36')]]:'%'+_0x2caa57['query'][_0x37c98e('0xa')]+'%'},_0x32f4eb;}})}));_0x18ff35=_[_0x41ed71('0x8')]({},_0x18ff35,_0x2caa57[_0x41ed71('0x21')]);const _0x3d52b9={'where':_0x18ff35['where']};return db[_0x41ed71('0x11')][_0x41ed71('0x25')](_0x3d52b9)[_0x41ed71('0x9')](function(_0x2e03e9){const _0x3d1189=_0x41ed71;return _0x4be508[_0x3d1189('0x25')]=_0x2e03e9,_0x2caa57[_0x3d1189('0x1f')][_0x3d1189('0x10')]&&(_0x18ff35[_0x3d1189('0x30')]=[{'all':!![]}]),db[_0x3d1189('0x11')][_0x3d1189('0xc')](_0x18ff35);})[_0x41ed71('0x9')](function(_0x531da1){const _0x14e9f0=_0x41ed71;return _0x4be508[_0x14e9f0('0x19')]=_0x531da1,_0x4be508;})[_0x41ed71('0x9')](respondWithFilteredResult(_0x2a159a,_0x18ff35))[_0x41ed71('0x33')](handleError(_0x2a159a,null));},exports[_0x4c314f('0x1a')]=function(_0x31b492,_0x54f092){const _0x1b3386=_0x4c314f;let _0x19b600={'raw':!![],'where':{'id':_0x31b492[_0x1b3386('0x26')]['id']}};const _0x4d7767={};return _0x4d7767[_0x1b3386('0x32')]=_['keys'](db[_0x1b3386('0x11')][_0x1b3386('0x5')]),_0x4d7767[_0x1b3386('0x1f')]=_[_0x1b3386('0x13')](_0x31b492[_0x1b3386('0x1f')]),_0x4d7767[_0x1b3386('0x7')]=_['intersection'](_0x4d7767[_0x1b3386('0x32')],_0x4d7767['query']),_0x19b600['attributes']=_[_0x1b3386('0x4')](_0x4d7767[_0x1b3386('0x32')],qs['fields'](_0x31b492[_0x1b3386('0x1f')]['fields'])),_0x19b600[_0x1b3386('0x1e')]=_0x19b600[_0x1b3386('0x1e')]['length']?_0x19b600[_0x1b3386('0x1e')]:_0x4d7767[_0x1b3386('0x32')],_0x31b492[_0x1b3386('0x1f')][_0x1b3386('0x10')]&&(_0x19b600['include']=[{'all':!![]}]),_0x19b600=_['merge']({},_0x19b600,_0x31b492['options']),db[_0x1b3386('0x11')][_0x1b3386('0x15')](_0x19b600)['then'](handleEntityNotFound(_0x54f092,null))[_0x1b3386('0x9')](respondWithResult(_0x54f092,null))['catch'](handleError(_0x54f092,null));},exports[_0x4c314f('0x1c')]=function(_0xaf7aa7,_0x37ce81){const _0x1073ce=_0x4c314f;return db[_0x1073ce('0x11')][_0x1073ce('0x1c')](_0xaf7aa7[_0x1073ce('0x14')],{})[_0x1073ce('0x9')](respondWithResult(_0x37ce81,0xc9))['catch'](handleError(_0x37ce81,null));},exports[_0x4c314f('0xd')]=function(_0x273d2d,_0x4d4bb0){const _0x50a573=_0x4c314f;return _0x273d2d[_0x50a573('0x14')]['id']&&delete _0x273d2d[_0x50a573('0x14')]['id'],db['WhatsappTransferReport'][_0x50a573('0x15')]({'where':{'id':_0x273d2d[_0x50a573('0x26')]['id']}})['then'](handleEntityNotFound(_0x4d4bb0,null))[_0x50a573('0x9')](saveUpdates(_0x273d2d['body'],null))[_0x50a573('0x9')](respondWithResult(_0x4d4bb0,null))[_0x50a573('0x33')](handleError(_0x4d4bb0,null));},exports[_0x4c314f('0x2b')]=function(_0x40f752,_0x36b801){const _0x1cac43=_0x4c314f;return db[_0x1cac43('0x11')][_0x1cac43('0x15')]({'where':{'id':_0x40f752[_0x1cac43('0x26')]['id']}})[_0x1cac43('0x9')](handleEntityNotFound(_0x36b801,null))[_0x1cac43('0x9')](removeEntity(_0x36b801,null))['catch'](handleError(_0x36b801,null));},exports[_0x4c314f('0x2c')]=function(_0xfb219b,_0xdb7293){const _0x29aa60=_0x4c314f;return db['WhatsappTransferReport'][_0x29aa60('0x2c')]()[_0x29aa60('0x9')](respondWithResult(_0xdb7293,null))[_0x29aa60('0x33')](handleError(_0xdb7293,null));}; \ No newline at end of file diff --git a/server/api/whatsappTransferReport/whatsappTransferReport.model.js b/server/api/whatsappTransferReport/whatsappTransferReport.model.js index f63d7c9..f558ed1 100644 --- a/server/api/whatsappTransferReport/whatsappTransferReport.model.js +++ b/server/api/whatsappTransferReport/whatsappTransferReport.model.js @@ -1 +1 @@ -const a821_0x50bd=['report_whatsapp_transfer','WhatsappTransferReport','./whatsappTransferReport.attributes','exports','uniqueid'];(function(_0x195964,_0x50bd39){const _0x1711ec=function(_0x259aba){while(--_0x259aba){_0x195964['push'](_0x195964['shift']());}};_0x1711ec(++_0x50bd39);}(a821_0x50bd,0xb8));const a821_0x1711=function(_0x195964,_0x50bd39){_0x195964=_0x195964-0x0;let _0x1711ec=a821_0x50bd[_0x195964];return _0x1711ec;};const _0x468d05=a821_0x1711;'use strict';const attributes=require(_0x468d05('0x3'));module[_0x468d05('0x4')]=function(_0x259aba){const _0x423945=_0x468d05,_0x38aa9a=_0x259aba['define'](_0x423945('0x2'),attributes,{'tableName':_0x423945('0x1'),'paranoid':![],'indexes':[{'name':_0x423945('0x0'),'fields':[_0x423945('0x0')]}],'timestamps':!![]});return _0x38aa9a;}; \ No newline at end of file +const a821_0x3418=['define','./whatsappTransferReport.attributes','uniqueid','exports'];(function(_0x3c066a,_0x3418e3){const _0x5163d7=function(_0x24b2f9){while(--_0x24b2f9){_0x3c066a['push'](_0x3c066a['shift']());}};_0x5163d7(++_0x3418e3);}(a821_0x3418,0x150));const a821_0x5163=function(_0x3c066a,_0x3418e3){_0x3c066a=_0x3c066a-0x0;let _0x5163d7=a821_0x3418[_0x3c066a];return _0x5163d7;};const _0x696f71=a821_0x5163;'use strict';const attributes=require(_0x696f71('0x1'));module[_0x696f71('0x3')]=function(_0x24b2f9){const _0x32646e=_0x696f71,_0x473a7c=_0x24b2f9[_0x32646e('0x0')]('WhatsappTransferReport',attributes,{'tableName':'report_whatsapp_transfer','paranoid':![],'indexes':[{'name':_0x32646e('0x2'),'fields':['uniqueid']}],'timestamps':!![]});return _0x473a7c;}; \ No newline at end of file diff --git a/server/app.js b/server/app.js index feedef9..c4bdbb3 100644 --- a/server/app.js +++ b/server/app.js @@ -15,4 +15,4 @@ // * treaties. The SOFTWARE PRODUCT is licensed, not sold. * // * * // ************************************************************************* -const a822_0x5295=['online','\x0a*****\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Caught\x20','\x0a*****\x20\x20\x20\x20\x20\x20\x20Stopped\x20and\x20removed\x20all\x20subprocesses\x20\x20\x20\x20\x20\x20*****\x0a\x0a\x0a','apps','xCally\x20ready!','./config/license','environment','pid','Seed\x20DB\x20ok','error','stack','isTest','App\x20shut\x20down','Rpc\x20closed','seedDB','start','lodash','db-query','info','\x20deleted','debounce','name','delete','DB\x20Sync\x20Error:\x0a','log','RPC\x20Error','disconnect','isProduction','once','Online\x20apps:','status','./config/pm2','Database','debug','Redis\x20disconnected','xCally\x20Starting...\x20','SIGUSR2','listen','exit','./rpc','ON\x20SIGINT','warn','filter','kill','./config/schedule/transcribe','\x20signal!\x20\x20\x20\x20\x20\x20\x20\x20*****\x0a','join','./config/logger','message','DB\x20Sync\x20Error:\x20','app','ONCE\x20SIGINT','./config/schedule/chat','test','SIGINT','Error\x20on\x20server\x20exit:\x20','./config/environment','./config/seedDB','map','./mysqldb','process\x20or\x20namespace\x20not\x20found','sequelize','Cannot\x20kill\x20'];(function(_0x2584ab,_0x5295af){const _0x36f648=function(_0x1df9f4){while(--_0x1df9f4){_0x2584ab['push'](_0x2584ab['shift']());}};_0x36f648(++_0x5295af);}(a822_0x5295,0x18a));const a822_0x36f6=function(_0x2584ab,_0x5295af){_0x2584ab=_0x2584ab-0x0;let _0x36f648=a822_0x5295[_0x2584ab];return _0x36f648;};const _0x46f775=a822_0x36f6;'use strict';require('./globals');const mysqldb=require(_0x46f775('0x2b')),{RPC}=require(_0x46f775('0x17')),{getConfigService}=require('./config/config.service'),config=require(_0x46f775('0x28')),logger=require(_0x46f775('0x1f')),pm2=require(_0x46f775('0xf')),pm2Config=require('./config/pm2/config'),schedule=require('./config/schedule'),chat=require(_0x46f775('0x24')),transcribe=require(_0x46f775('0x1c')),{default:seedDB}=require(_0x46f775('0x29')),{default:checkLicense}=require(_0x46f775('0x34')),{getRedis}=require('./rediscache'),cs=getConfigService(),_=require(_0x46f775('0x0')),appLogger=logger(_0x46f775('0x22')),queryLogger=logger(_0x46f775('0x1'));function logDatabase(_0x1df9f4){const _0x3b510a=_0x46f775;try{queryLogger['info'](_0x3b510a('0x10'),_0x1df9f4);}catch(_0x106b19){console[_0x3b510a('0x38')](_0x106b19);}}function onRPCError(_0x390e31){const _0xc8903a=_0x46f775;appLogger[_0xc8903a('0x38')](_0xc8903a('0x9'),_0x390e31);}const rpc=new RPC(onRPCError),onServerExitHandler=_[_0x46f775('0x4')](async function onServerExit(_0x4fd69b){const _0x319250=_0x46f775;console[_0x319250('0x8')](_0x319250('0x30')+_0x4fd69b+_0x319250('0x1d'));try{await rpc['close'](),appLogger[_0x319250('0x11')](_0x319250('0x3c'));for(const _0x48e871 of pm2Config[_0x319250('0x32')]){try{await pm2[_0x319250('0x6')](_0x48e871[_0x319250('0x5')]),appLogger[_0x319250('0x11')](_0x48e871['name']+_0x319250('0x3'));}catch(_0x4c6443){_0x4c6443['message']!==_0x319250('0x2c')&&(console[_0x319250('0x38')](_0x319250('0x2e')+_0x48e871[_0x319250('0x5')],_0x4c6443),appLogger['error']('Cannot\x20kill\x20'+_0x48e871[_0x319250('0x5')]+':\x20'+_0x4c6443[_0x319250('0x20')]+'\x0a'+_0x4c6443['stack']));}}console[_0x319250('0x8')](_0x319250('0x31')),getRedis()[_0x319250('0xa')](),appLogger[_0x319250('0x11')](_0x319250('0x12')),appLogger[_0x319250('0x11')](_0x319250('0x3b'));}catch(_0x1985c9){console[_0x319250('0x38')]('Error\x20on\x20server\x20exit',_0x1985c9),appLogger[_0x319250('0x38')](_0x319250('0x27')+_0x1985c9['message']+'\x0a'+_0x1985c9[_0x319250('0x39')]);}},0x7d0,{'leading':!![]});!(cs['isProduction']||cs[_0x46f775('0x3a')])?(process[_0x46f775('0xc')](_0x46f775('0x14'),async function(){const _0x21afe1=_0x46f775;await onServerExitHandler(_0x21afe1('0x14')),process[_0x21afe1('0x1b')](process[_0x21afe1('0x36')],'SIGUSR2');}),process['on'](_0x46f775('0x26'),async function(){const _0x4cf3c3=_0x46f775;console['log'](_0x4cf3c3('0x18')),await onServerExitHandler(_0x4cf3c3('0x26')),process[_0x4cf3c3('0x16')](0x0);})):process[_0x46f775('0xc')](_0x46f775('0x26'),async function(){const _0x105c90=_0x46f775;console[_0x105c90('0x8')](_0x105c90('0x23')),await onServerExitHandler(_0x105c90('0x26')),process[_0x105c90('0x16')](0x0);});async function main(){const _0x3a05ca=_0x46f775;try{console['log'](_0x3a05ca('0x13')+(cs[_0x3a05ca('0xb')]?'':'Development\x20Mode'));try{await mysqldb['db'][_0x3a05ca('0x2d')]['sync']({'logging':cs[_0x3a05ca('0xb')]||cs[_0x3a05ca('0x35')]===_0x3a05ca('0x25')?![]:logDatabase});}catch(_0x5b90ee){console[_0x3a05ca('0x19')](_0x3a05ca('0x7'),_0x5b90ee),queryLogger['error'](_0x3a05ca('0x21')+_0x5b90ee[_0x3a05ca('0x20')]+',\x20'+_0x5b90ee[_0x3a05ca('0x39')]);}config[_0x3a05ca('0x3d')]===!![]&&(console[_0x3a05ca('0x8')]('Starting\x20DB\x20seed...'),await seedDB(),console['log'](_0x3a05ca('0x37')));await checkLicense();const _0x5168e6=await rpc[_0x3a05ca('0x15')]();appLogger[_0x3a05ca('0x2')](_0x5168e6),await chat[_0x3a05ca('0x3e')](),await schedule[_0x3a05ca('0x3e')]();const _0x431878=await transcribe[_0x3a05ca('0x3e')]();appLogger[_0x3a05ca('0x2')](_0x431878);const _0x3fe06d=await pm2[_0x3a05ca('0x3e')](pm2Config);appLogger['info'](_0x3a05ca('0xd'),_[_0x3a05ca('0x2a')](_[_0x3a05ca('0x1a')](_0x3fe06d,{'status':_0x3a05ca('0x2f')}),_0x3a05ca('0x5'))['join']()),appLogger[_0x3a05ca('0x2')]('Offline\x20apps:',_['map'](_[_0x3a05ca('0x1a')](_0x3fe06d,function(_0x3996e0){const _0x541ffb=_0x3a05ca;return _0x3996e0[_0x541ffb('0xe')]!=='online';}),_0x3a05ca('0x5'))[_0x3a05ca('0x1e')]()||'None'),console[_0x3a05ca('0x8')](_0x3a05ca('0x33'));}catch(_0x4e7e34){console[_0x3a05ca('0x38')](_0x4e7e34),appLogger[_0x3a05ca('0x38')]('Server\x20failed\x20to\x20start\x20due\x20to\x20error:',_0x4e7e34);throw _0x4e7e34;}}main(); \ No newline at end of file +const a822_0x3009=['Cannot\x20kill\x20','close','./config/logger','kill','warn','environment','db-query','join','map','./rpc','process\x20or\x20namespace\x20not\x20found','./config/config.service','Starting\x20DB\x20seed...','error','online','exit','\x20deleted','message','start','SIGUSR2','\x0a*****\x20\x20\x20\x20\x20\x20\x20Stopped\x20and\x20removed\x20all\x20subprocesses\x20\x20\x20\x20\x20\x20*****\x0a\x0a\x0a','listen','Online\x20apps:','stack','App\x20shut\x20down','debounce','debug','test','ON\x20SIGINT','\x20signal!\x20\x20\x20\x20\x20\x20\x20\x20*****\x0a','filter','lodash','once','Server\x20failed\x20to\x20start\x20due\x20to\x20error:','\x0a*****\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Caught\x20','./globals','Error\x20on\x20server\x20exit','name','Offline\x20apps:','apps','status','./config/pm2/config','./config/schedule/transcribe','info','ONCE\x20SIGINT','./config/license','delete','Error\x20on\x20server\x20exit:\x20','pid','xCally\x20ready!','./config/pm2','./config/schedule','xCally\x20Starting...\x20','./config/schedule/chat','./config/seedDB','seedDB','log','isProduction','SIGINT','Seed\x20DB\x20ok','sequelize','sync'];(function(_0x1edb10,_0x300908){const _0x56ac76=function(_0x47e211){while(--_0x47e211){_0x1edb10['push'](_0x1edb10['shift']());}};_0x56ac76(++_0x300908);}(a822_0x3009,0x17b));const a822_0x56ac=function(_0x1edb10,_0x300908){_0x1edb10=_0x1edb10-0x0;let _0x56ac76=a822_0x3009[_0x1edb10];return _0x56ac76;};const _0x2b176e=a822_0x56ac;'use strict';require(_0x2b176e('0x1c'));const mysqldb=require('./mysqldb'),{RPC}=require(_0x2b176e('0x2')),{getConfigService}=require(_0x2b176e('0x4')),config=require('./config/environment'),logger=require(_0x2b176e('0x39')),pm2=require(_0x2b176e('0x2b')),pm2Config=require(_0x2b176e('0x22')),schedule=require(_0x2b176e('0x2c')),chat=require(_0x2b176e('0x2e')),transcribe=require(_0x2b176e('0x23')),{default:seedDB}=require(_0x2b176e('0x2f')),{default:checkLicense}=require(_0x2b176e('0x26')),{getRedis}=require('./rediscache'),cs=getConfigService(),_=require(_0x2b176e('0x18')),appLogger=logger('app'),queryLogger=logger(_0x2b176e('0x3d'));function logDatabase(_0x47e211){const _0x5c606a=_0x2b176e;try{queryLogger[_0x5c606a('0x24')]('Database',_0x47e211);}catch(_0x119eaa){console[_0x5c606a('0x6')](_0x119eaa);}}function onRPCError(_0x5efa7f){appLogger['error']('RPC\x20Error',_0x5efa7f);}const rpc=new RPC(onRPCError),onServerExitHandler=_[_0x2b176e('0x12')](async function onServerExit(_0x18610e){const _0x2213a9=_0x2b176e;console[_0x2213a9('0x31')](_0x2213a9('0x1b')+_0x18610e+_0x2213a9('0x16'));try{await rpc[_0x2213a9('0x38')](),appLogger[_0x2213a9('0x13')]('Rpc\x20closed');for(const _0x1dff4a of pm2Config[_0x2213a9('0x20')]){try{await pm2[_0x2213a9('0x27')](_0x1dff4a[_0x2213a9('0x1e')]),appLogger[_0x2213a9('0x13')](_0x1dff4a[_0x2213a9('0x1e')]+_0x2213a9('0x9'));}catch(_0x3286f9){_0x3286f9[_0x2213a9('0xa')]!==_0x2213a9('0x3')&&(console[_0x2213a9('0x6')](_0x2213a9('0x37')+_0x1dff4a[_0x2213a9('0x1e')],_0x3286f9),appLogger[_0x2213a9('0x6')](_0x2213a9('0x37')+_0x1dff4a[_0x2213a9('0x1e')]+':\x20'+_0x3286f9[_0x2213a9('0xa')]+'\x0a'+_0x3286f9[_0x2213a9('0x10')]));}}console[_0x2213a9('0x31')](_0x2213a9('0xd')),getRedis()['disconnect'](),appLogger['debug']('Redis\x20disconnected'),appLogger[_0x2213a9('0x13')](_0x2213a9('0x11'));}catch(_0x52d925){console[_0x2213a9('0x6')](_0x2213a9('0x1d'),_0x52d925),appLogger[_0x2213a9('0x6')](_0x2213a9('0x28')+_0x52d925['message']+'\x0a'+_0x52d925[_0x2213a9('0x10')]);}},0x7d0,{'leading':!![]});!(cs[_0x2b176e('0x32')]||cs['isTest'])?(process['once'](_0x2b176e('0xc'),async function(){const _0xec83c0=_0x2b176e;await onServerExitHandler(_0xec83c0('0xc')),process[_0xec83c0('0x3a')](process[_0xec83c0('0x29')],_0xec83c0('0xc'));}),process['on'](_0x2b176e('0x33'),async function(){const _0xa235f2=_0x2b176e;console[_0xa235f2('0x31')](_0xa235f2('0x15')),await onServerExitHandler(_0xa235f2('0x33')),process[_0xa235f2('0x8')](0x0);})):process[_0x2b176e('0x19')](_0x2b176e('0x33'),async function(){const _0x952350=_0x2b176e;console[_0x952350('0x31')](_0x952350('0x25')),await onServerExitHandler(_0x952350('0x33')),process[_0x952350('0x8')](0x0);});async function main(){const _0x173e25=_0x2b176e;try{console[_0x173e25('0x31')](_0x173e25('0x2d')+(cs[_0x173e25('0x32')]?'':'Development\x20Mode'));try{await mysqldb['db'][_0x173e25('0x35')][_0x173e25('0x36')]({'logging':cs['isProduction']||cs[_0x173e25('0x3c')]===_0x173e25('0x14')?![]:logDatabase});}catch(_0x144845){console[_0x173e25('0x3b')]('DB\x20Sync\x20Error:\x0a',_0x144845),queryLogger[_0x173e25('0x6')]('DB\x20Sync\x20Error:\x20'+_0x144845[_0x173e25('0xa')]+',\x20'+_0x144845[_0x173e25('0x10')]);}config[_0x173e25('0x30')]===!![]&&(console['log'](_0x173e25('0x5')),await seedDB(),console[_0x173e25('0x31')](_0x173e25('0x34')));await checkLicense();const _0xbddd23=await rpc[_0x173e25('0xe')]();appLogger[_0x173e25('0x24')](_0xbddd23),await chat[_0x173e25('0xb')](),await schedule[_0x173e25('0xb')]();const _0x2deab5=await transcribe[_0x173e25('0xb')]();appLogger[_0x173e25('0x24')](_0x2deab5);const _0x17d8ef=await pm2[_0x173e25('0xb')](pm2Config);appLogger[_0x173e25('0x24')](_0x173e25('0xf'),_[_0x173e25('0x1')](_[_0x173e25('0x17')](_0x17d8ef,{'status':_0x173e25('0x7')}),_0x173e25('0x1e'))[_0x173e25('0x0')]()),appLogger[_0x173e25('0x24')](_0x173e25('0x1f'),_['map'](_[_0x173e25('0x17')](_0x17d8ef,function(_0x4bcb1a){const _0x22b907=_0x173e25;return _0x4bcb1a[_0x22b907('0x21')]!==_0x22b907('0x7');}),_0x173e25('0x1e'))[_0x173e25('0x0')]()||'None'),console['log'](_0x173e25('0x2a'));}catch(_0x26bf99){console[_0x173e25('0x6')](_0x26bf99),appLogger[_0x173e25('0x6')](_0x173e25('0x1a'),_0x26bf99);throw _0x26bf99;}}main(); \ No newline at end of file diff --git a/server/components/auth/service.js b/server/components/auth/service.js index 0f45696..4146ba3 100644 --- a/server/components/auth/service.js +++ b/server/components/auth/service.js @@ -1 +1 @@ -const a823_0x3388=['allowmessenger','smsPause','use','query','/dashboards/general','The\x20password\x20must\x20be\x20different\x20from\x20the\x20previous\x20%d\x20passwords.\x20Please\x20choose\x20another\x20one.','length','encryptString','update','isAuthenticated','authenticate','lodash','phoneBarPrefixRequired','settingsEnabled','showWebBar','User\x20object\x20not\x20found.','toString','redirect','hotdesk','session','voicePause','User','isNil','Unknown\x20authorization\x20format','unshift','getLicense','../encryptor','userProfileId','phoneBarRemoteControlPort','role','params','fullname','jsonwebtoken','closed','catch','interface','startsWith','Please\x20use\x20the\x20previous\x20API\x20access\x20key\x20to\x20generate\x20a\x20new\x20one','authorization','exports','headers','promisify','Unmanaged.','toLowerCase','randomBytes','findOne','verify','decryptString','unmanaged','md5secret','Bearer','pauseType','express-jwt','floor','crudPermissions','pass','HS256','phoneBarEnableRecording','util','apiKeyNonce','sign','The\x20password\x20must\x20be\x20different\x20from\x20the\x20last\x20one.\x20Please\x20choose\x20another\x20one.','faxPause','user','phoneBarEnableDtmfTone','json','phoneBarDnd','lastPauseAt','apiKeyIat','Invalid\x20API\x20access\x20key','internal','../../config/environment','lastLoginAt','Forbidden.','splice','status','now','getUuid','email','disposition','test','secrets','apikey','isEqual','../../config/license/hardware','cookie','hex','The\x20password\x20must\x20be\x20at\x20least\x208\x20characters\x20long\x20and\x20have\x201\x20lowercase\x20character,\x201\x20uppercase\x20character,\x201\x20number\x20and\x201\x20special\x20character\x20~!@#$%^&-_=+[{]}.','then','secret','split','Wrong\x20credentials.','payload','phoneBarExpires','format','name','permissions','Forbidden','phoneBarAutoAnswer','passwordResetAt','phoneBarEnableSettings','join','HS512','motion.token'];(function(_0x2a183a,_0x33888f){const _0x198e21=function(_0x40a75d){while(--_0x40a75d){_0x2a183a['push'](_0x2a183a['shift']());}};_0x198e21(++_0x33888f);}(a823_0x3388,0xc6));const a823_0x198e=function(_0x2a183a,_0x33888f){_0x2a183a=_0x2a183a-0x0;let _0x198e21=a823_0x3388[_0x2a183a];return _0x198e21;};const _0x1a3419=a823_0x198e;'use strict';const db=require('../../mysqldb')['db'],{ValidationError}=require('sequelize'),config=require(_0x1a3419('0x51')),hardwareConf=require(_0x1a3419('0x5e')),licenseUtil=require('../../config/license/util'),encryptor=require(_0x1a3419('0x24')),util=require(_0x1a3419('0x44')),_=require(_0x1a3419('0x15')),jwt=require(_0x1a3419('0x2a')),expressJwt=require(_0x1a3419('0x3e')),compose=require('composable-middleware'),basicAuth=require('basic-auth'),crypto=require('crypto'),validateJwt=expressJwt({'secret':config[_0x1a3419('0x5b')][_0x1a3419('0x1d')],'algorithms':[_0x1a3419('0x42')]}),userAttributes=['id',_0x1a3419('0x27'),_0x1a3419('0x29'),_0x1a3419('0x1'),_0x1a3419('0x50'),_0x1a3419('0x58'),'userpic',_0x1a3419('0x2'),_0x1a3419('0x3b'),_0x1a3419('0x1e'),'chatPause','mailPause',_0x1a3419('0x48'),_0x1a3419('0xb'),'openchannelPause',_0x1a3419('0x3d'),_0x1a3419('0x18'),_0x1a3419('0x52'),_0x1a3419('0x4d'),_0x1a3419('0x40'),_0x1a3419('0xa'),_0x1a3419('0x5'),'alias',_0x1a3419('0x4'),'phoneBarAutoAnswerDelay',_0x1a3419('0x4c'),_0x1a3419('0x43'),_0x1a3419('0x4a'),_0x1a3419('0x6'),_0x1a3419('0x67'),_0x1a3419('0x16'),'phoneBarRemoteControl',_0x1a3419('0x26'),_0x1a3419('0x1c'),_0x1a3419('0x2d'),_0x1a3419('0x25'),_0x1a3419('0x17')];function isChatInteractionAuthorized(){const _0x2e16a1=_0x1a3419;return this[_0x2e16a1('0x13')](!![])[_0x2e16a1('0xc')](function(_0x40a75d,_0x105918,_0x563d94){const _0x4f5746=_0x2e16a1;if(_0x40a75d[_0x4f5746('0x49')])_0x563d94();else return db['ChatInteraction'][_0x4f5746('0x37')]({'where':{'id':_0x40a75d[_0x4f5746('0x28')]['id']},'attributes':['id',_0x4f5746('0x2b'),_0x4f5746('0x59')],'raw':!![]})[_0x4f5746('0x62')](function(_0x7ffec7){const _0x35bbb3=_0x4f5746;if(_0x7ffec7&&_0x7ffec7[_0x35bbb3('0x2b')])return _0x105918[_0x35bbb3('0x55')](_0x7ffec7[_0x35bbb3('0x59')]==='unmanaged'?0x195:0x193)[_0x35bbb3('0x4b')]({'message':_0x7ffec7['disposition']===_0x35bbb3('0x3a')?_0x35bbb3('0x34'):_0x35bbb3('0x53')});else _0x563d94();})[_0x4f5746('0x2c')](function(_0x1ceedd){_0x563d94(_0x1ceedd);});});}function isAuthenticated(_0x18fe35){const _0x5d1643=_0x1a3419;return compose()['use'](function(_0x1f76e5,_0x579ab5,_0x463f1b){const _0xbb00c9=a823_0x198e;if(_0x1f76e5[_0xbb00c9('0x32')][_0xbb00c9('0x30')]){if(_[_0xbb00c9('0x2e')](_0x1f76e5[_0xbb00c9('0x32')][_0xbb00c9('0x30')],'Basic')){const _0x3bdbe5=basicAuth(_0x1f76e5);db['User'][_0xbb00c9('0x37')]({'where':{'name':_0x3bdbe5[_0xbb00c9('0x1')]}})[_0xbb00c9('0x62')](function(_0x2359c0){const _0x2756db=_0xbb00c9;if(!_0x2359c0||!_0x2359c0[_0x2756db('0x14')](_0x3bdbe5[_0x2756db('0x41')]))return _0x579ab5['status'](0x191)[_0x2756db('0x4b')]({'message':_0x2756db('0x65')});_0x1f76e5['user']={'id':_0x2359c0['id']},_0x463f1b();})[_0xbb00c9('0x2c')](function(_0x42a67a){_0x463f1b(_0x42a67a);});}else{if(_[_0xbb00c9('0x2e')](_0x1f76e5['headers'][_0xbb00c9('0x30')],_0xbb00c9('0x3c')))validateJwt(_0x1f76e5,_0x579ab5,_0x463f1b);else{if(_0x18fe35)_0x463f1b();else return _0x579ab5[_0xbb00c9('0x55')](0x193)[_0xbb00c9('0x4b')]({'message':_0xbb00c9('0x21')});}}}else{if(_0x1f76e5[_0xbb00c9('0xd')][_0xbb00c9('0x5c')])try{const _0x44a86e={'audience':hardwareConf[_0xbb00c9('0x57')](),'issuer':hardwareConf[_0xbb00c9('0x57')]()};verifyJwt(_0x1f76e5[_0xbb00c9('0xd')][_0xbb00c9('0x5c')],_0x44a86e)['then'](function(_0x2e35ce){const _0x250944=_0xbb00c9;return db[_0x250944('0x1f')]['findOne']({'where':{'id':_0x2e35ce['sub']}})['then'](function(_0x1a7a67){const _0x2a2b93=_0x250944;if(!_0x1a7a67||!_[_0x2a2b93('0x5d')](_0x1a7a67['apiKeyNonce'],_0x2e35ce['nonce']))return _0x579ab5['status'](0x191)[_0x2a2b93('0x4b')]({'message':'API\x20access\x20key\x20is\x20not\x20valid\x20anymore'});_0x1f76e5[_0x2a2b93('0x49')]={'id':_0x1a7a67['id']},_0x463f1b();});})[_0xbb00c9('0x2c')](function(){const _0x5d8a25=_0xbb00c9;return _0x579ab5['status'](0x191)[_0x5d8a25('0x4b')]({'message':_0x5d8a25('0x4f')});});}catch(_0x387010){_0x463f1b(_0x387010);}else{if(_0x18fe35)_0x463f1b();else return _0x579ab5[_0xbb00c9('0x55')](0x193)['json']({'message':_0xbb00c9('0x21')});}}})[_0x5d1643('0xc')](function(_0x3f4e53,_0x25681f,_0x30eeda){const _0x341caa=_0x5d1643;if(_0x3f4e53['user'])db[_0x341caa('0x1f')][_0x341caa('0x37')]({'where':{'id':_0x3f4e53['user']['id']},'attributes':userAttributes})['then'](function(_0xe1eea){const _0x37d742=_0x341caa;if(!_0xe1eea)return _0x25681f['status'](0x194)[_0x37d742('0x4b')]({'message':'User\x20not\x20found.'});_0x3f4e53[_0x37d742('0x49')]=_0xe1eea,_0x30eeda();})[_0x341caa('0x2c')](function(_0x185358){_0x30eeda(_0x185358);});else{if(_0x18fe35)_0x30eeda();else return _0x25681f[_0x341caa('0x55')](0x194)[_0x341caa('0x4b')]({'message':_0x341caa('0x19')});}});}function canUpdate(){const _0x43adf1=_0x1a3419;return compose()[_0x43adf1('0xc')](function(_0x599b3f,_0x40bc10,_0x10d0ac){const _0x2555c4=_0x43adf1;return licenseUtil[_0x2555c4('0x23')]()['then'](function(_0x23ef60){const _0x5947fa=_0x2555c4;if(_0x23ef60[_0x5947fa('0x12')])_0x10d0ac();else return _0x40bc10[_0x5947fa('0x55')](0x193)[_0x5947fa('0x4b')]({'message':_0x5947fa('0x3')});})[_0x2555c4('0x2c')](function(_0x488a30){_0x10d0ac(_0x488a30);});});}function isMiddleware(_0x4f816f,_0x1457aa,_0x4dfec0){return _0x4f816f['isMiddleware']=!![],_0x4dfec0();}function signToken(_0x566868){return signJwt(_0x566868);}function setTokenCookie(_0x422dce,_0x2bd5c9){const _0x3c8f51=_0x1a3419;if(!_0x422dce[_0x3c8f51('0x49')])return _0x2bd5c9[_0x3c8f51('0x55')](0x194)[_0x3c8f51('0x4b')]({'message':'It\x20looks\x20like\x20you\x20aren\x27t\x20logged\x20in,\x20please\x20try\x20again.'});const _0xc9b771={'payload':{'id':_0x422dce[_0x3c8f51('0x49')]['id'],'role':_0x422dce[_0x3c8f51('0x49')]['role']},'options':{'expiresIn':0x15180}};return signJwt(_0xc9b771)[_0x3c8f51('0x62')](function(_0xb5f50f){const _0x333946=_0x3c8f51;_0x2bd5c9[_0x333946('0x5f')](_0x333946('0x9'),_0xb5f50f),_0x2bd5c9[_0x333946('0x1b')](_0x333946('0xe'));})[_0x3c8f51('0x2c')](function(_0x575ea8){const _0x367b0b=_0x3c8f51;return _0x2bd5c9[_0x367b0b('0x55')](0x1f4)['send'](_0x575ea8);});}function retrieveApiKey(_0x41162f){const _0x1b46d6=_0x1a3419;return _[_0x1b46d6('0x20')](_0x41162f['apiKeyNonce'])||_[_0x1b46d6('0x20')](_0x41162f[_0x1b46d6('0x4e')])?null:createJwt(_0x41162f);}function generateApiKey(_0x53a7a9){const _0x3fa564=_0x1a3419;return _0x53a7a9[_0x3fa564('0x45')]=generateNonce(),_0x53a7a9[_0x3fa564('0x4e')]=generateIssuedAt(),createJwt(_0x53a7a9);}function regenerateApiKey(_0x17d5bc,_0x1a22e9){const _0x5d6ab9=_0x1a3419,_0x4abe0c=_0x17d5bc[_0x5d6ab9('0xd')][_0x5d6ab9('0x5c')];if(_0x4abe0c){const _0x2093a1={'nonce':_0x1a22e9[_0x5d6ab9('0x45')],'iat':_0x1a22e9[_0x5d6ab9('0x4e')],'audience':hardwareConf['getUuid'](),'issuer':hardwareConf[_0x5d6ab9('0x57')]()};return verifyJwt(_0x4abe0c,_0x2093a1)['then'](function(){return generateApiKey(_0x1a22e9);});}else throw{'message':_0x5d6ab9('0x2f')};}function validatePasswordPattern(_0x2fd363){const _0x55ec21=_0x1a3419,_0x45b24b=new RegExp(/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/);if(!_0x45b24b[_0x55ec21('0x5a')](_0x2fd363))throw new ValidationError(_0x55ec21('0x61'));return;}function validatePasswordHistory(_0x51c06d,_0x41b380,_0x4a1dff){const _0x3cbbe8=_0x1a3419,_0xab44a8=encryptor['decryptString'](_0x41b380)['split'](',');for(let _0x323d01=0x0;_0x323d01<_0x4a1dff;_0x323d01++){if(!_0xab44a8[_0x323d01])break;if(_0x51c06d[_0x3cbbe8('0x35')]()===_0xab44a8[_0x323d01][_0x3cbbe8('0x35')]()){let _0x429e67=util[_0x3cbbe8('0x0')](_0x3cbbe8('0xf'),_0x4a1dff);_0x4a1dff===0x1&&(_0x429e67=_0x3cbbe8('0x47'));throw new ValidationError(_0x429e67);}}return;}function updatePasswordsHistory(_0x2665ed,_0xf434b9){const _0x1d25dc=_0x1a3419,_0x5ade11=_0xf434b9?encryptor[_0x1d25dc('0x39')](_0xf434b9)[_0x1d25dc('0x64')](','):[];return _0x5ade11[_0x1d25dc('0x10')]===0x5&&_0x5ade11[_0x1d25dc('0x54')](-0x1,0x1),_0x5ade11[_0x1d25dc('0x22')](_0x2665ed),encryptor[_0x1d25dc('0x11')](_0x5ade11[_0x1d25dc('0x7')](','));}function signJwt(_0x1c94dd){const _0x4407c5=_0x1a3419,_0x1d6d57=util['promisify'](jwt[_0x4407c5('0x46')],{'context':jwt}),_0x24d84b=_0x1c94dd[_0x4407c5('0x63')]||config[_0x4407c5('0x5b')][_0x4407c5('0x1d')];return new Promise(function(_0x1c8a89,_0x14da10){const _0x54a8e0=_0x4407c5;_0x1d6d57(_0x1c94dd[_0x54a8e0('0x66')],_0x24d84b,_0x1c94dd['options'])[_0x54a8e0('0x62')](function(_0x58057b){_0x1c8a89(_0x58057b);})['catch'](function(_0x2e115f){_0x14da10(_0x2e115f);});});}function verifyJwt(_0x154ad1,_0x52bde3,_0x1edc53){const _0x1fad62=_0x1a3419,_0x4d8b35=util[_0x1fad62('0x33')](jwt[_0x1fad62('0x38')],{'context':jwt}),_0x487e39=_0x1edc53||config[_0x1fad62('0x5b')]['session'];return new Promise(function(_0x16e397,_0x2c5002){const _0x458b06=_0x1fad62;_0x4d8b35(_0x154ad1,_0x487e39,_0x52bde3)[_0x458b06('0x62')](function(_0xd1d55a){_0x16e397(_0xd1d55a);})['catch'](function(_0x1ba75c){_0x2c5002(_0x1ba75c);});});}function generateNonce(){const _0x182244=_0x1a3419;return crypto[_0x182244('0x36')](0x10)[_0x182244('0x1a')](_0x182244('0x60'));}function generateIssuedAt(){const _0x37ec89=_0x1a3419;return Math[_0x37ec89('0x3f')](Date[_0x37ec89('0x56')]()/0x3e8)['toString']();}function createJwt(_0x18d420){const _0x1c32eb=_0x1a3419,_0x227184={'payload':{'iat':_0x18d420[_0x1c32eb('0x4e')],'nonce':_0x18d420[_0x1c32eb('0x45')]},'options':{'algorithm':_0x1c32eb('0x8'),'subject':_0x18d420['id'][_0x1c32eb('0x1a')](),'issuer':hardwareConf[_0x1c32eb('0x57')](),'audience':hardwareConf[_0x1c32eb('0x57')]()}};return signJwt(_0x227184)['then'](function(_0x3af558){const _0x443588=_0x1c32eb;return{'iat':_0x18d420[_0x443588('0x4e')],'nonce':_0x18d420[_0x443588('0x45')],'token':_0x3af558};});}module[_0x1a3419('0x31')]={'isChatInteractionAuthorized':isChatInteractionAuthorized,'isAuthenticated':isAuthenticated,'canUpdate':canUpdate,'isMiddleware':isMiddleware,'signToken':signToken,'setTokenCookie':setTokenCookie,'retrieveApiKey':retrieveApiKey,'generateApiKey':generateApiKey,'regenerateApiKey':regenerateApiKey,'validatePasswordPattern':validatePasswordPattern,'validatePasswordHistory':validatePasswordHistory,'updatePasswordsHistory':updatePasswordsHistory}; \ No newline at end of file +const a823_0x5a34=['use','User\x20not\x20found.','md5secret','toLowerCase','Basic','unmanaged','encryptString','authorization','It\x20looks\x20like\x20you\x20aren\x27t\x20logged\x20in,\x20please\x20try\x20again.','findOne','role','userpic','internal','isEqual','crudPermissions','nonce','closed','user','phoneBarEnableRecording','disposition','basic-auth','query','json','express-jwt','phoneBarDnd','faxPause','phoneBarEnableSettings','User','../encryptor','hex','The\x20password\x20must\x20be\x20at\x20least\x208\x20characters\x20long\x20and\x20have\x201\x20lowercase\x20character,\x201\x20uppercase\x20character,\x201\x20number\x20and\x201\x20special\x20character\x20~!@#$%^&-_=+[{]}.','phoneBarEnableDtmfTone','promisify','apiKeyIat','startsWith','getLicense','update','HS256','format','interface','splice','The\x20password\x20must\x20be\x20different\x20from\x20the\x20previous\x20%d\x20passwords.\x20Please\x20choose\x20another\x20one.','openchannelPause','apikey','catch','options','voicePause','allowmessenger','now','decryptString','passwordResetAt','verify','Unmanaged.','lodash','secret','../../config/license/hardware','sign','Invalid\x20API\x20access\x20key','payload','apiKeyNonce','status','length','test','exports','floor','lastLoginAt','alias','phoneBarRemoteControl','../../mysqldb','session','name','API\x20access\x20key\x20is\x20not\x20valid\x20anymore','pass','getUuid','isMiddleware','join','settingsEnabled','Forbidden.','jsonwebtoken','split','pauseType','headers','email','isNil','toString','User\x20object\x20not\x20found.','secrets','Unknown\x20authorization\x20format','isAuthenticated','then','util','permissions','phoneBarAutoAnswer','chatPause','userProfileId','smsPause','../../config/license/util','sub','unshift','fullname'];(function(_0x1a8860,_0x5a341a){const _0x52ab62=function(_0x51ed03){while(--_0x51ed03){_0x1a8860['push'](_0x1a8860['shift']());}};_0x52ab62(++_0x5a341a);}(a823_0x5a34,0x64));const a823_0x52ab=function(_0x1a8860,_0x5a341a){_0x1a8860=_0x1a8860-0x0;let _0x52ab62=a823_0x5a34[_0x1a8860];return _0x52ab62;};const _0x1b1463=a823_0x52ab;'use strict';const db=require(_0x1b1463('0x44'))['db'],{ValidationError}=require('sequelize'),config=require('../../config/environment'),hardwareConf=require(_0x1b1463('0x37')),licenseUtil=require(_0x1b1463('0x60')),encryptor=require(_0x1b1463('0x1c')),util=require(_0x1b1463('0x5a')),_=require(_0x1b1463('0x35')),jwt=require(_0x1b1463('0x4e')),expressJwt=require(_0x1b1463('0x17')),compose=require('composable-middleware'),basicAuth=require(_0x1b1463('0x14')),crypto=require('crypto'),validateJwt=expressJwt({'secret':config['secrets'][_0x1b1463('0x45')],'algorithms':[_0x1b1463('0x25')]}),userAttributes=['id','role',_0x1b1463('0x63'),_0x1b1463('0x46'),_0x1b1463('0xc'),_0x1b1463('0x52'),_0x1b1463('0xb'),_0x1b1463('0x5b'),_0x1b1463('0x2'),_0x1b1463('0x2e'),_0x1b1463('0x5d'),'mailPause',_0x1b1463('0x19'),_0x1b1463('0x5f'),_0x1b1463('0x2a'),_0x1b1463('0x50'),'showWebBar',_0x1b1463('0x41'),'lastPauseAt',_0x1b1463('0xe'),_0x1b1463('0x2f'),_0x1b1463('0x32'),_0x1b1463('0x42'),_0x1b1463('0x5c'),'phoneBarAutoAnswerDelay',_0x1b1463('0x18'),_0x1b1463('0x12'),_0x1b1463('0x1f'),_0x1b1463('0x1a'),'phoneBarExpires','phoneBarPrefixRequired',_0x1b1463('0x43'),'phoneBarRemoteControlPort','hotdesk',_0x1b1463('0x27'),_0x1b1463('0x5e'),_0x1b1463('0x4c')];function isChatInteractionAuthorized(){const _0x4feabe=_0x1b1463;return this[_0x4feabe('0x58')](!![])['use'](function(_0x51ed03,_0x258087,_0x3e1f2a){const _0x5e6b69=_0x4feabe;if(_0x51ed03[_0x5e6b69('0x11')])_0x3e1f2a();else return db['ChatInteraction'][_0x5e6b69('0x9')]({'where':{'id':_0x51ed03['params']['id']},'attributes':['id','closed',_0x5e6b69('0x13')],'raw':!![]})['then'](function(_0x84cf82){const _0x53a29f=_0x5e6b69;if(_0x84cf82&&_0x84cf82[_0x53a29f('0x10')])return _0x258087[_0x53a29f('0x3c')](_0x84cf82['disposition']===_0x53a29f('0x5')?0x195:0x193)['json']({'message':_0x84cf82[_0x53a29f('0x13')]===_0x53a29f('0x5')?_0x53a29f('0x34'):_0x53a29f('0x4d')});else _0x3e1f2a();})['catch'](function(_0x4a314f){_0x3e1f2a(_0x4a314f);});});}function isAuthenticated(_0x34c2bd){const _0x478f51=_0x1b1463;return compose()[_0x478f51('0x0')](function(_0x482bb0,_0x48c58e,_0x3a26a1){const _0x26c596=_0x478f51;if(_0x482bb0[_0x26c596('0x51')][_0x26c596('0x7')]){if(_[_0x26c596('0x22')](_0x482bb0[_0x26c596('0x51')]['authorization'],_0x26c596('0x4'))){const _0x313730=basicAuth(_0x482bb0);db[_0x26c596('0x1b')][_0x26c596('0x9')]({'where':{'name':_0x313730[_0x26c596('0x46')]}})['then'](function(_0x5eeb46){const _0x533d24=_0x26c596;if(!_0x5eeb46||!_0x5eeb46['authenticate'](_0x313730[_0x533d24('0x48')]))return _0x48c58e[_0x533d24('0x3c')](0x191)['json']({'message':'Wrong\x20credentials.'});_0x482bb0[_0x533d24('0x11')]={'id':_0x5eeb46['id']},_0x3a26a1();})[_0x26c596('0x2c')](function(_0x15ae8e){_0x3a26a1(_0x15ae8e);});}else{if(_['startsWith'](_0x482bb0[_0x26c596('0x51')][_0x26c596('0x7')],'Bearer'))validateJwt(_0x482bb0,_0x48c58e,_0x3a26a1);else{if(_0x34c2bd)_0x3a26a1();else return _0x48c58e[_0x26c596('0x3c')](0x193)['json']({'message':'Unknown\x20authorization\x20format'});}}}else{if(_0x482bb0[_0x26c596('0x15')][_0x26c596('0x2b')])try{const _0xd5c423={'audience':hardwareConf[_0x26c596('0x49')](),'issuer':hardwareConf['getUuid']()};verifyJwt(_0x482bb0['query'][_0x26c596('0x2b')],_0xd5c423)[_0x26c596('0x59')](function(_0x31468b){const _0x510f19=_0x26c596;return db[_0x510f19('0x1b')][_0x510f19('0x9')]({'where':{'id':_0x31468b[_0x510f19('0x61')]}})['then'](function(_0x2a9824){const _0x59c2b5=_0x510f19;if(!_0x2a9824||!_[_0x59c2b5('0xd')](_0x2a9824[_0x59c2b5('0x3b')],_0x31468b[_0x59c2b5('0xf')]))return _0x48c58e[_0x59c2b5('0x3c')](0x191)['json']({'message':_0x59c2b5('0x47')});_0x482bb0['user']={'id':_0x2a9824['id']},_0x3a26a1();});})[_0x26c596('0x2c')](function(){const _0x12a9de=_0x26c596;return _0x48c58e[_0x12a9de('0x3c')](0x191)['json']({'message':_0x12a9de('0x39')});});}catch(_0x27d163){_0x3a26a1(_0x27d163);}else{if(_0x34c2bd)_0x3a26a1();else return _0x48c58e[_0x26c596('0x3c')](0x193)['json']({'message':_0x26c596('0x57')});}}})[_0x478f51('0x0')](function(_0x1ae703,_0x433cee,_0x2474ac){const _0x50b259=_0x478f51;if(_0x1ae703[_0x50b259('0x11')])db[_0x50b259('0x1b')]['findOne']({'where':{'id':_0x1ae703[_0x50b259('0x11')]['id']},'attributes':userAttributes})[_0x50b259('0x59')](function(_0x20f9af){const _0x58e668=_0x50b259;if(!_0x20f9af)return _0x433cee['status'](0x194)['json']({'message':_0x58e668('0x1')});_0x1ae703[_0x58e668('0x11')]=_0x20f9af,_0x2474ac();})[_0x50b259('0x2c')](function(_0x3c38df){_0x2474ac(_0x3c38df);});else{if(_0x34c2bd)_0x2474ac();else return _0x433cee['status'](0x194)['json']({'message':_0x50b259('0x55')});}});}function canUpdate(){const _0x5a7a2c=_0x1b1463;return compose()[_0x5a7a2c('0x0')](function(_0x52833e,_0x3b33bf,_0x45496d){const _0x42e59b=_0x5a7a2c;return licenseUtil[_0x42e59b('0x23')]()[_0x42e59b('0x59')](function(_0x40788b){const _0x3f55af=_0x42e59b;if(_0x40788b[_0x3f55af('0x24')])_0x45496d();else return _0x3b33bf[_0x3f55af('0x3c')](0x193)['json']({'message':'Forbidden'});})['catch'](function(_0x406141){_0x45496d(_0x406141);});});}function isMiddleware(_0x1c6988,_0x59bd4e,_0x15d3a1){const _0x430fcb=_0x1b1463;return _0x1c6988[_0x430fcb('0x4a')]=!![],_0x15d3a1();}function signToken(_0x30222a){return signJwt(_0x30222a);}function setTokenCookie(_0x4509e8,_0x17eafa){const _0x18a688=_0x1b1463;if(!_0x4509e8[_0x18a688('0x11')])return _0x17eafa[_0x18a688('0x3c')](0x194)[_0x18a688('0x16')]({'message':_0x18a688('0x8')});const _0x1a1435={'payload':{'id':_0x4509e8[_0x18a688('0x11')]['id'],'role':_0x4509e8['user'][_0x18a688('0xa')]},'options':{'expiresIn':0x15180}};return signJwt(_0x1a1435)['then'](function(_0x3c89e8){_0x17eafa['cookie']('motion.token',_0x3c89e8),_0x17eafa['redirect']('/dashboards/general');})[_0x18a688('0x2c')](function(_0x23ca05){const _0x4bb681=_0x18a688;return _0x17eafa[_0x4bb681('0x3c')](0x1f4)['send'](_0x23ca05);});}function retrieveApiKey(_0x32da49){const _0x4b9e09=_0x1b1463;return _[_0x4b9e09('0x53')](_0x32da49[_0x4b9e09('0x3b')])||_[_0x4b9e09('0x53')](_0x32da49[_0x4b9e09('0x21')])?null:createJwt(_0x32da49);}function generateApiKey(_0x5f3ecd){const _0x49746f=_0x1b1463;return _0x5f3ecd[_0x49746f('0x3b')]=generateNonce(),_0x5f3ecd[_0x49746f('0x21')]=generateIssuedAt(),createJwt(_0x5f3ecd);}function regenerateApiKey(_0x9dd5cd,_0x190214){const _0x42455d=_0x1b1463,_0x8faa32=_0x9dd5cd[_0x42455d('0x15')][_0x42455d('0x2b')];if(_0x8faa32){const _0x5bd865={'nonce':_0x190214[_0x42455d('0x3b')],'iat':_0x190214[_0x42455d('0x21')],'audience':hardwareConf['getUuid'](),'issuer':hardwareConf[_0x42455d('0x49')]()};return verifyJwt(_0x8faa32,_0x5bd865)[_0x42455d('0x59')](function(){return generateApiKey(_0x190214);});}else throw{'message':'Please\x20use\x20the\x20previous\x20API\x20access\x20key\x20to\x20generate\x20a\x20new\x20one'};}function validatePasswordPattern(_0x51dfb8){const _0x2d7c13=_0x1b1463,_0xadea3d=new RegExp(/(?=.*[a-z])(?=.*[A-Z])(?=.*[0-9])(?=.*[?!@#$%^&*~\-_=+[{\]}])(?=.{8,})/);if(!_0xadea3d[_0x2d7c13('0x3e')](_0x51dfb8))throw new ValidationError(_0x2d7c13('0x1e'));return;}function validatePasswordHistory(_0x591406,_0x36c44e,_0x52935e){const _0x47e950=_0x1b1463,_0x904969=encryptor['decryptString'](_0x36c44e)[_0x47e950('0x4f')](',');for(let _0x394ed9=0x0;_0x394ed9<_0x52935e;_0x394ed9++){if(!_0x904969[_0x394ed9])break;if(_0x591406[_0x47e950('0x3')]()===_0x904969[_0x394ed9][_0x47e950('0x3')]()){let _0x4dca85=util[_0x47e950('0x26')](_0x47e950('0x29'),_0x52935e);_0x52935e===0x1&&(_0x4dca85='The\x20password\x20must\x20be\x20different\x20from\x20the\x20last\x20one.\x20Please\x20choose\x20another\x20one.');throw new ValidationError(_0x4dca85);}}return;}function updatePasswordsHistory(_0x544a29,_0x2c54cf){const _0x4985ac=_0x1b1463,_0x559004=_0x2c54cf?encryptor[_0x4985ac('0x31')](_0x2c54cf)[_0x4985ac('0x4f')](','):[];return _0x559004[_0x4985ac('0x3d')]===0x5&&_0x559004[_0x4985ac('0x28')](-0x1,0x1),_0x559004[_0x4985ac('0x62')](_0x544a29),encryptor[_0x4985ac('0x6')](_0x559004[_0x4985ac('0x4b')](','));}function signJwt(_0x1ed810){const _0x358ba5=_0x1b1463,_0x1a1783=util[_0x358ba5('0x20')](jwt[_0x358ba5('0x38')],{'context':jwt}),_0x238127=_0x1ed810[_0x358ba5('0x36')]||config[_0x358ba5('0x56')][_0x358ba5('0x45')];return new Promise(function(_0x1fc2e3,_0x57ba44){const _0x3a5d8a=_0x358ba5;_0x1a1783(_0x1ed810[_0x3a5d8a('0x3a')],_0x238127,_0x1ed810[_0x3a5d8a('0x2d')])[_0x3a5d8a('0x59')](function(_0x400c45){_0x1fc2e3(_0x400c45);})['catch'](function(_0x57578b){_0x57ba44(_0x57578b);});});}function verifyJwt(_0x1cda1a,_0x1e2b96,_0x50f7a5){const _0xd20b89=_0x1b1463,_0x417c2f=util[_0xd20b89('0x20')](jwt[_0xd20b89('0x33')],{'context':jwt}),_0x5171e6=_0x50f7a5||config['secrets'][_0xd20b89('0x45')];return new Promise(function(_0x5d66ae,_0x5d9522){const _0x3c184a=_0xd20b89;_0x417c2f(_0x1cda1a,_0x5171e6,_0x1e2b96)[_0x3c184a('0x59')](function(_0x55e249){_0x5d66ae(_0x55e249);})[_0x3c184a('0x2c')](function(_0x477bb7){_0x5d9522(_0x477bb7);});});}function generateNonce(){const _0x26f083=_0x1b1463;return crypto['randomBytes'](0x10)['toString'](_0x26f083('0x1d'));}function generateIssuedAt(){const _0x1e6d11=_0x1b1463;return Math[_0x1e6d11('0x40')](Date[_0x1e6d11('0x30')]()/0x3e8)[_0x1e6d11('0x54')]();}function createJwt(_0x35231d){const _0xdc56a8=_0x1b1463,_0x14fd85={'payload':{'iat':_0x35231d[_0xdc56a8('0x21')],'nonce':_0x35231d[_0xdc56a8('0x3b')]},'options':{'algorithm':'HS512','subject':_0x35231d['id']['toString'](),'issuer':hardwareConf[_0xdc56a8('0x49')](),'audience':hardwareConf[_0xdc56a8('0x49')]()}};return signJwt(_0x14fd85)[_0xdc56a8('0x59')](function(_0x5d57f2){const _0x4adbdb=_0xdc56a8;return{'iat':_0x35231d[_0x4adbdb('0x21')],'nonce':_0x35231d[_0x4adbdb('0x3b')],'token':_0x5d57f2};});}module[_0x1b1463('0x3f')]={'isChatInteractionAuthorized':isChatInteractionAuthorized,'isAuthenticated':isAuthenticated,'canUpdate':canUpdate,'isMiddleware':isMiddleware,'signToken':signToken,'setTokenCookie':setTokenCookie,'retrieveApiKey':retrieveApiKey,'generateApiKey':generateApiKey,'regenerateApiKey':regenerateApiKey,'validatePasswordPattern':validatePasswordPattern,'validatePasswordHistory':validatePasswordHistory,'updatePasswordsHistory':updatePasswordsHistory}; \ No newline at end of file diff --git a/server/components/encryptor/create-cypher-fallback.js b/server/components/encryptor/create-cypher-fallback.js index 3f49f06..ae186a0 100644 --- a/server/components/encryptor/create-cypher-fallback.js +++ b/server/components/encryptor/create-cypher-fallback.js @@ -1 +1 @@ -const a824_0x11ea=['message','min','exports','md5','digest','from','length','hex','repeat','test','Missing\x20passphrase','slice','update','Missing\x20cipher'];(function(_0x52df42,_0x11eacc){const _0x4a1833=function(_0x25c56a){while(--_0x25c56a){_0x52df42['push'](_0x52df42['shift']());}};_0x4a1833(++_0x11eacc);}(a824_0x11ea,0x9f));const a824_0x4a18=function(_0x52df42,_0x11eacc){_0x52df42=_0x52df42-0x0;let _0x4a1833=a824_0x11ea[_0x52df42];return _0x4a1833;};const _0x4cedaa=a824_0x4a18;'use strict';const {createCipheriv,createHash}=require('crypto');function sizes(_0x25c56a){const _0x3aa879=a824_0x4a18;for(let _0x19aefb=0x1,_0x10e924=0x0;;){try{return createCipheriv(_0x25c56a,'.'[_0x3aa879('0x3')](_0x19aefb),'.'['repeat'](_0x10e924)),[_0x19aefb,_0x10e924];}catch(_0x655546){if(/invalid iv length/i[_0x3aa879('0x4')](_0x655546[_0x3aa879('0x9')]))_0x10e924+=0x1;else{if(/invalid key length/i[_0x3aa879('0x4')](_0x655546['message']))_0x19aefb+=0x1;else throw _0x655546;}}}}function compute(_0x5aa36b,_0x944ae){const _0x33ad4d=a824_0x4a18;let [_0x26e541,_0x439793]=sizes(_0x5aa36b);for(let _0x3dd9f9='',_0x27ffb8='',_0x5ae870='';;){const _0x421813=createHash(_0x33ad4d('0xc'));_0x421813[_0x33ad4d('0x7')](_0x5ae870,_0x33ad4d('0x2')),_0x421813[_0x33ad4d('0x7')](_0x944ae),_0x5ae870=_0x421813[_0x33ad4d('0xd')]('hex');let _0x2c7158=0x0,_0x25fdfd=0x0;_0x2c7158=Math[_0x33ad4d('0xa')](_0x5ae870[_0x33ad4d('0x1')]-_0x25fdfd,0x2*_0x26e541),(_0x26e541-=_0x2c7158/0x2,_0x3dd9f9+=_0x5ae870[_0x33ad4d('0x6')](_0x25fdfd,_0x25fdfd+_0x2c7158),_0x25fdfd+=_0x2c7158),_0x2c7158=Math['min'](_0x5ae870[_0x33ad4d('0x1')]-_0x25fdfd,0x2*_0x439793),(_0x439793-=_0x2c7158/0x2,_0x27ffb8+=_0x5ae870[_0x33ad4d('0x6')](_0x25fdfd,_0x25fdfd+_0x2c7158),_0x25fdfd+=_0x2c7158);if(_0x26e541+_0x439793===0x0)return[_0x3dd9f9,_0x27ffb8];}}function createCypherFallback(_0x47e19a,_0x2ce0ac){const _0x4b4a4a=a824_0x4a18;if(!_0x47e19a)throw new Error(_0x4b4a4a('0x8'));if(!_0x2ce0ac)throw new Error(_0x4b4a4a('0x5'));const [_0x5bd5e7,_0x73c23c]=compute(_0x47e19a,_0x2ce0ac);return{'key':Buffer[_0x4b4a4a('0x0')](_0x5bd5e7,_0x4b4a4a('0x2')),'iv':Buffer[_0x4b4a4a('0x0')](_0x73c23c,_0x4b4a4a('0x2'))};}module[_0x4cedaa('0xb')]={'createCypherFallback':createCypherFallback}; \ No newline at end of file +const a824_0x1532=['message','digest','crypto','hex','min','from','length','Missing\x20cipher','Missing\x20passphrase','md5','repeat','update','test'];(function(_0x53d063,_0x1532a2){const _0x4e2075=function(_0x36c92b){while(--_0x36c92b){_0x53d063['push'](_0x53d063['shift']());}};_0x4e2075(++_0x1532a2);}(a824_0x1532,0x9e));const a824_0x4e20=function(_0x53d063,_0x1532a2){_0x53d063=_0x53d063-0x0;let _0x4e2075=a824_0x1532[_0x53d063];return _0x4e2075;};const _0x372fc5=a824_0x4e20;'use strict';const {createCipheriv,createHash}=require(_0x372fc5('0x0'));function sizes(_0x36c92b){const _0x4d1c10=_0x372fc5;for(let _0xabb0fc=0x1,_0x28e4ca=0x0;;){try{return createCipheriv(_0x36c92b,'.'[_0x4d1c10('0x8')](_0xabb0fc),'.'['repeat'](_0x28e4ca)),[_0xabb0fc,_0x28e4ca];}catch(_0x1dee57){if(/invalid iv length/i[_0x4d1c10('0xa')](_0x1dee57[_0x4d1c10('0xb')]))_0x28e4ca+=0x1;else{if(/invalid key length/i[_0x4d1c10('0xa')](_0x1dee57[_0x4d1c10('0xb')]))_0xabb0fc+=0x1;else throw _0x1dee57;}}}}function compute(_0x5cd65c,_0x1fb951){const _0x1f4a13=_0x372fc5;let [_0x506779,_0x29e07e]=sizes(_0x5cd65c);for(let _0x2af141='',_0x3a5c22='',_0xf794dd='';;){const _0x1ff8a3=createHash(_0x1f4a13('0x7'));_0x1ff8a3[_0x1f4a13('0x9')](_0xf794dd,'hex'),_0x1ff8a3['update'](_0x1fb951),_0xf794dd=_0x1ff8a3[_0x1f4a13('0xc')](_0x1f4a13('0x1'));let _0x57ba00=0x0,_0x565f0f=0x0;_0x57ba00=Math[_0x1f4a13('0x2')](_0xf794dd[_0x1f4a13('0x4')]-_0x565f0f,0x2*_0x506779),(_0x506779-=_0x57ba00/0x2,_0x2af141+=_0xf794dd['slice'](_0x565f0f,_0x565f0f+_0x57ba00),_0x565f0f+=_0x57ba00),_0x57ba00=Math[_0x1f4a13('0x2')](_0xf794dd[_0x1f4a13('0x4')]-_0x565f0f,0x2*_0x29e07e),(_0x29e07e-=_0x57ba00/0x2,_0x3a5c22+=_0xf794dd['slice'](_0x565f0f,_0x565f0f+_0x57ba00),_0x565f0f+=_0x57ba00);if(_0x506779+_0x29e07e===0x0)return[_0x2af141,_0x3a5c22];}}function createCypherFallback(_0x3cb7e0,_0x225d5e){const _0x1dbc7a=_0x372fc5;if(!_0x3cb7e0)throw new Error(_0x1dbc7a('0x5'));if(!_0x225d5e)throw new Error(_0x1dbc7a('0x6'));const [_0x24d996,_0x5812ae]=compute(_0x3cb7e0,_0x225d5e);return{'key':Buffer[_0x1dbc7a('0x3')](_0x24d996,_0x1dbc7a('0x1')),'iv':Buffer[_0x1dbc7a('0x3')](_0x5812ae,_0x1dbc7a('0x1'))};}module['exports']={'createCypherFallback':createCypherFallback}; \ No newline at end of file diff --git a/server/components/encryptor/index.js b/server/components/encryptor/index.js index e09084d..fc0152d 100644 --- a/server/components/encryptor/index.js +++ b/server/components/encryptor/index.js @@ -1 +1 @@ -const a825_0x24e9=['key','close','utf-8','digest','end','createWriteStream','final','substr','from','unlink','./create-cypher-fallback','update','parse','split','sha256','data','some-naughty-secret','../../config/logger','utf8','base64','toString','string','open','license','join','info','write','promises','read','Missing\x20Initialization\x20Vector\x20in\x20the\x20encrypted\x20string.\x20Using\x20fallbacks.','aes-256-ctr','you\x20must\x20pass\x20a\x20secret','length','algorithm','secret','randomBytes','binary','separator'];(function(_0x516b2b,_0x24e975){const _0x3d5a93=function(_0x3403d2){while(--_0x3403d2){_0x516b2b['push'](_0x516b2b['shift']());}};_0x3d5a93(++_0x24e975);}(a825_0x24e9,0xdb));const a825_0x3d5a=function(_0x516b2b,_0x24e975){_0x516b2b=_0x516b2b-0x0;let _0x3d5a93=a825_0x24e9[_0x516b2b];return _0x3d5a93;};const _0x1645bd=a825_0x3d5a;'use strict';const fs=require('fs'),crypto=require('crypto'),{createCypherFallback}=require(_0x1645bd('0x13')),logger=require(_0x1645bd('0x1a'))('app'),DEFAULT_STRING_OPTIONS={'secret':_0x1645bd('0x19'),'algorithm':_0x1645bd('0x1'),'separator':'!'},DEFAULT_FILE_OPTIONS={'algorithm':'aes192','separator':'!'},KEYLEN_MAP={'aes-256-ctr':0x20,'aes192':0x18},IVLEN_MAP={'aes-256-ctr':0x18,'aes192':0x10};function getCipherAndIvText(_0x3403d2,_0x25fc3a,_0x202873){const _0x2f0b2e=_0x1645bd,_0x1630e3=KEYLEN_MAP[_0x25fc3a],_0x4a15fe=crypto['createHash'](_0x2f0b2e('0x17'))[_0x2f0b2e('0x14')](String(_0x3403d2))[_0x2f0b2e('0xc')](_0x2f0b2e('0x1c'))[_0x2f0b2e('0x10')](0x0,_0x1630e3),_0x10965e=Buffer[_0x2f0b2e('0x11')](_0x4a15fe,_0x2f0b2e('0xb')),_0x11e3ff=crypto[_0x2f0b2e('0x6')](0x10),_0x453937=_0x11e3ff[_0x2f0b2e('0x1d')]('base64'),_0x1fa519=crypto['createCipheriv'](_0x25fc3a,_0x10965e,_0x11e3ff,_0x202873);return[_0x1fa519,_0x453937];}function getDecipher(_0x313e77,_0x7622b9,_0x208532,_0x2ed204){const _0x5b83cf=_0x1645bd,_0x420b12=KEYLEN_MAP[_0x7622b9],_0x573d08=typeof _0x208532===_0x5b83cf('0x1e')&&_0x208532[_0x5b83cf('0x3')]>0x0;let _0x24f500=null,_0x1f0fb7=null;if(!_0x573d08){logger[_0x5b83cf('0x22')](_0x5b83cf('0x0'));const _0x1893cf=createCypherFallback(_0x7622b9,_0x313e77);_0x1f0fb7=_0x1893cf['iv'],_0x24f500=_0x1893cf[_0x5b83cf('0x9')];}const _0x56ee60=_0x573d08?Buffer[_0x5b83cf('0x11')](_0x208532,_0x5b83cf('0x1c')):_0x1f0fb7,_0x4d62d6=_0x573d08?crypto['createHash'](_0x5b83cf('0x17'))['update'](String(_0x313e77))[_0x5b83cf('0xc')](_0x5b83cf('0x1c'))[_0x5b83cf('0x10')](0x0,_0x420b12):null,_0x437341=_0x573d08?Buffer[_0x5b83cf('0x11')](_0x4d62d6,'utf-8'):_0x24f500,_0x150ff4=crypto['createDecipheriv'](_0x7622b9,_0x437341,_0x56ee60,_0x2ed204);return _0x150ff4;}function encryptFile(_0x746e35,_0x23fbcc,_0x54e50b,_0x4b3da5={}){return new Promise(function(_0x37303a,_0x39e0ac){const _0x1a1149=a825_0x3d5a;_0x4b3da5={...DEFAULT_FILE_OPTIONS,..._0x4b3da5};const _0x1dcea2=fs['createReadStream'](_0x746e35),_0x402305=fs['createWriteStream'](_0x23fbcc),[_0x1c6963,_0x50b979]=getCipherAndIvText(_0x54e50b,_0x4b3da5[_0x1a1149('0x4')]);_0x1dcea2['on'](_0x1a1149('0x1f'),function(){const _0x38b033=_0x1a1149,_0x4055f4=Buffer[_0x38b033('0x11')](_0x50b979,_0x38b033('0x1c')),_0x5927c0=Buffer[_0x38b033('0x11')](_0x4b3da5[_0x38b033('0x8')],_0x38b033('0xb'));_0x402305[_0x38b033('0x23')](Buffer['concat']([_0x4055f4,_0x5927c0],_0x4055f4[_0x38b033('0x3')]+_0x5927c0[_0x38b033('0x3')]));}),_0x1dcea2['on'](_0x1a1149('0x18'),function(_0xe2180c){const _0x35ce6a=_0x1a1149,_0x4edd86=Buffer[_0x35ce6a('0x11')](_0x1c6963['update'](_0xe2180c),_0x35ce6a('0x7'));_0x402305['write'](_0x4edd86);}),_0x1dcea2['on'](_0x1a1149('0xd'),function(){const _0x2ce269=_0x1a1149;try{const _0x28bed5=Buffer[_0x2ce269('0x11')](_0x1c6963[_0x2ce269('0xf')](_0x2ce269('0x7')),_0x2ce269('0x7'));_0x402305[_0x2ce269('0x23')](_0x28bed5),_0x402305[_0x2ce269('0xd')](),_0x402305['on'](_0x2ce269('0xa'),function(){_0x37303a(_0x23fbcc);});}catch(_0x3148ce){fs[_0x2ce269('0x12')](_0x23fbcc,_0x40fca=>{_0x39e0ac(_0x40fca===null?_0x3148ce:_0x40fca);});}});});}async function decryptFile(_0xf2a0db,_0x3307d2,_0x590167,_0x2e7f1a={}){const _0x539638=_0x1645bd;_0x2e7f1a={...DEFAULT_FILE_OPTIONS,..._0x2e7f1a};const _0x4e1343=Buffer['from'](_0x2e7f1a['separator'],_0x539638('0xb'))['length'],_0x51e29d=IVLEN_MAP[_0x2e7f1a[_0x539638('0x4')]],_0x5b0385=_0x51e29d+_0x4e1343,_0x525a5e=await fs[_0x539638('0x24')]['open'](_0xf2a0db,'r'),_0x5a02a8=Buffer['alloc'](_0x5b0385),{buffer:_0x1bd210}=await _0x525a5e[_0x539638('0x25')](_0x5a02a8,0x0,_0x5b0385),_0x5a2b76=_0x1bd210['slice'](0x0,_0x51e29d),_0x3ffb87=_0x1bd210['slice'](_0x51e29d),_0x2ee51b=_0x3ffb87['toString'](_0x539638('0xb')),_0x20c738=_0x5a2b76[_0x539638('0x1d')](_0x539638('0x1c')),_0x4fe6a3=_0x2ee51b===_0x2e7f1a[_0x539638('0x8')];return new Promise(function(_0x2e99f1,_0x26dda8){const _0x246914=_0x539638,_0x551400=fs['createReadStream'](_0xf2a0db,{'start':_0x4fe6a3?_0x5b0385:0x0,'fd':_0x525a5e,'autoClose':!![]}),_0x167752=fs[_0x246914('0xe')](_0x3307d2),_0x3a72d1=getDecipher(_0x590167,_0x2e7f1a[_0x246914('0x4')],_0x4fe6a3?_0x20c738:null);_0x551400['on'](_0x246914('0x18'),function(_0x444da9){const _0x50b620=_0x246914,_0x2f6719=Buffer['from'](_0x3a72d1[_0x50b620('0x14')](_0x444da9),_0x50b620('0x7'));_0x167752[_0x50b620('0x23')](_0x2f6719);}),_0x551400['on']('error',_0x2a0a29=>_0x26dda8(_0x2a0a29)),_0x551400['on']('end',function(){const _0x260f6c=_0x246914;try{const _0x4400b2=Buffer['from'](_0x3a72d1['final'](_0x260f6c('0x7')),_0x260f6c('0x7'));_0x167752[_0x260f6c('0x23')](_0x4400b2),_0x167752[_0x260f6c('0xd')](),_0x167752['on'](_0x260f6c('0xa'),function(){_0x2e99f1(_0x3307d2);});}catch(_0x3831b2){fs[_0x260f6c('0x12')](_0x3307d2,_0x511c8c=>{_0x26dda8(_0x511c8c===null?_0x3831b2:_0x511c8c);});}});});}function encryptString(_0x348621,_0x2c6bc7=DEFAULT_STRING_OPTIONS[_0x1645bd('0x5')],_0x560bb8=DEFAULT_STRING_OPTIONS[_0x1645bd('0x4')],_0x200743=DEFAULT_STRING_OPTIONS[_0x1645bd('0x8')]){const _0x39bf7c=_0x1645bd;if(!_0x348621||_0x348621[_0x39bf7c('0x3')]===0x0)return _0x348621;if(!_0x2c6bc7||_0x2c6bc7[_0x39bf7c('0x3')]===0x0)throw new Error(_0x39bf7c('0x2'));const [_0x5f41e4,_0x1736ef]=getCipherAndIvText(_0x2c6bc7,_0x560bb8);let _0x54f46f=_0x5f41e4[_0x39bf7c('0x14')](_0x348621,_0x39bf7c('0x1b'),'base64');return _0x54f46f+=_0x5f41e4[_0x39bf7c('0xf')](_0x39bf7c('0x1c')),[_0x1736ef,_0x54f46f][_0x39bf7c('0x21')](_0x200743);}function decryptString(_0x3deb3a,_0xc41056=DEFAULT_STRING_OPTIONS[_0x1645bd('0x5')],_0x37dd8d=DEFAULT_STRING_OPTIONS['algorithm'],_0x16893d=DEFAULT_STRING_OPTIONS[_0x1645bd('0x8')]){const _0x55bf77=_0x1645bd;if(!_0x3deb3a||_0x3deb3a['length']===0x0)return _0x3deb3a;if(!_0xc41056||_0xc41056[_0x55bf77('0x3')]===0x0)throw new Error(_0x55bf77('0x2'));const _0x256fe8=_0x3deb3a['split'](_0x16893d),_0x200b9c=_0x256fe8[_0x55bf77('0x3')]===0x2,_0x227044=_0x200b9c?_0x256fe8[0x1]:_0x3deb3a,_0x35b056=getDecipher(_0xc41056,_0x37dd8d,_0x200b9c?_0x256fe8[0x0]:undefined);let _0x5e2f65=_0x35b056['update'](_0x227044,_0x55bf77('0x1c'),_0x55bf77('0x1b'));return _0x5e2f65+=_0x35b056[_0x55bf77('0xf')]('utf8'),_0x5e2f65;}function getValueFromLicense(_0x56c5bf,_0x1fd524){const _0x4fac13=_0x1645bd;if(_0x56c5bf&&_0x1fd524){if(_0x1fd524['data1']&&_0x1fd524[_0x4fac13('0x20')]){const _0x3a51a2=_0x1fd524['data1'],_0x302b2c=_0x1fd524[_0x4fac13('0x20')],_0x506b36=_0x3a51a2['split']('-')[0x4],_0x40bcb2=_0x3a51a2[_0x4fac13('0x16')]('-')[0x0],_0xd83601=[_0x506b36,_0x3a51a2,_0x40bcb2][_0x4fac13('0x21')](':'),_0x16ba54=getDecipher(_0xd83601,_0x4fac13('0x1'));let _0xe64927=_0x16ba54[_0x4fac13('0x14')](_0x302b2c,_0x4fac13('0x1c'),'utf8');_0xe64927+=_0x16ba54[_0x4fac13('0xf')](_0x4fac13('0x1b'));const _0x3f5143=JSON[_0x4fac13('0x15')](_0xe64927);return typeof _0x3f5143[_0x56c5bf]==='undefined'?null:_0x3f5143[_0x56c5bf];}}return null;}module['exports']={'encryptFile':encryptFile,'decryptFile':decryptFile,'encryptString':encryptString,'decryptString':decryptString,'getValueFromLicense':getValueFromLicense}; \ No newline at end of file +const a825_0x44e7=['toString','close','aes-256-ctr','unlink','undefined','data','utf8','separator','createHash','app','alloc','slice','data1','read','secret','base64','end','exports','../../config/logger','parse','error','promises','key','aes192','sha256','split','join','some-naughty-secret','binary','open','from','length','Missing\x20Initialization\x20Vector\x20in\x20the\x20encrypted\x20string.\x20Using\x20fallbacks.','createReadStream','digest','createWriteStream','update','final','crypto','randomBytes','utf-8','substr','createCipheriv','you\x20must\x20pass\x20a\x20secret','license','algorithm','write'];(function(_0x3d2066,_0x44e77e){const _0x381eb7=function(_0x36589f){while(--_0x36589f){_0x3d2066['push'](_0x3d2066['shift']());}};_0x381eb7(++_0x44e77e);}(a825_0x44e7,0xc7));const a825_0x381e=function(_0x3d2066,_0x44e77e){_0x3d2066=_0x3d2066-0x0;let _0x381eb7=a825_0x44e7[_0x3d2066];return _0x381eb7;};const _0x2ad457=a825_0x381e;'use strict';const fs=require('fs'),crypto=require(_0x2ad457('0x1b')),{createCypherFallback}=require('./create-cypher-fallback'),logger=require(_0x2ad457('0x7'))(_0x2ad457('0x2d')),DEFAULT_STRING_OPTIONS={'secret':_0x2ad457('0x10'),'algorithm':_0x2ad457('0x26'),'separator':'!'},DEFAULT_FILE_OPTIONS={'algorithm':_0x2ad457('0xc'),'separator':'!'},KEYLEN_MAP={'aes-256-ctr':0x20,'aes192':0x18},IVLEN_MAP={'aes-256-ctr':0x18,'aes192':0x10};function getCipherAndIvText(_0x36589f,_0x3e4f25,_0x219e14){const _0x196c2f=_0x2ad457,_0x3f38c0=KEYLEN_MAP[_0x3e4f25],_0x498c13=crypto['createHash'](_0x196c2f('0xd'))['update'](String(_0x36589f))[_0x196c2f('0x17')](_0x196c2f('0x4'))[_0x196c2f('0x1e')](0x0,_0x3f38c0),_0x1910d6=Buffer[_0x196c2f('0x13')](_0x498c13,_0x196c2f('0x1d')),_0x26a88f=crypto[_0x196c2f('0x1c')](0x10),_0x2be530=_0x26a88f[_0x196c2f('0x24')]('base64'),_0x3875a3=crypto[_0x196c2f('0x1f')](_0x3e4f25,_0x1910d6,_0x26a88f,_0x219e14);return[_0x3875a3,_0x2be530];}function getDecipher(_0x451499,_0x21fb8b,_0x213e5a,_0x241777){const _0x1a46f0=_0x2ad457,_0x48ff5a=KEYLEN_MAP[_0x21fb8b],_0x5d618a=typeof _0x213e5a==='string'&&_0x213e5a[_0x1a46f0('0x14')]>0x0;let _0x512ef3=null,_0x58729d=null;if(!_0x5d618a){logger['info'](_0x1a46f0('0x15'));const _0x20a710=createCypherFallback(_0x21fb8b,_0x451499);_0x58729d=_0x20a710['iv'],_0x512ef3=_0x20a710[_0x1a46f0('0xb')];}const _0x328e03=_0x5d618a?Buffer[_0x1a46f0('0x13')](_0x213e5a,'base64'):_0x58729d,_0x12e074=_0x5d618a?crypto[_0x1a46f0('0x2c')](_0x1a46f0('0xd'))[_0x1a46f0('0x19')](String(_0x451499))['digest'](_0x1a46f0('0x4'))[_0x1a46f0('0x1e')](0x0,_0x48ff5a):null,_0x4ad9b1=_0x5d618a?Buffer[_0x1a46f0('0x13')](_0x12e074,_0x1a46f0('0x1d')):_0x512ef3,_0x5a795b=crypto['createDecipheriv'](_0x21fb8b,_0x4ad9b1,_0x328e03,_0x241777);return _0x5a795b;}function encryptFile(_0x2b7405,_0x2125ec,_0x4b0c08,_0x3a2322={}){return new Promise(function(_0x1da41b,_0x1575e8){const _0xea4d7a=a825_0x381e;_0x3a2322={...DEFAULT_FILE_OPTIONS,..._0x3a2322};const _0xaeb82d=fs[_0xea4d7a('0x16')](_0x2b7405),_0x54d8d8=fs[_0xea4d7a('0x18')](_0x2125ec),[_0x1a7fe2,_0x4210be]=getCipherAndIvText(_0x4b0c08,_0x3a2322[_0xea4d7a('0x22')]);_0xaeb82d['on'](_0xea4d7a('0x12'),function(){const _0x3fd4de=_0xea4d7a,_0x34d899=Buffer[_0x3fd4de('0x13')](_0x4210be,_0x3fd4de('0x4')),_0x2bbef8=Buffer[_0x3fd4de('0x13')](_0x3a2322[_0x3fd4de('0x2b')],_0x3fd4de('0x1d'));_0x54d8d8[_0x3fd4de('0x23')](Buffer['concat']([_0x34d899,_0x2bbef8],_0x34d899['length']+_0x2bbef8[_0x3fd4de('0x14')]));}),_0xaeb82d['on'](_0xea4d7a('0x29'),function(_0x56ee96){const _0x15c6cf=_0xea4d7a,_0x3f7c9d=Buffer[_0x15c6cf('0x13')](_0x1a7fe2[_0x15c6cf('0x19')](_0x56ee96),_0x15c6cf('0x11'));_0x54d8d8['write'](_0x3f7c9d);}),_0xaeb82d['on'](_0xea4d7a('0x5'),function(){const _0x38a2d1=_0xea4d7a;try{const _0x1bb01d=Buffer[_0x38a2d1('0x13')](_0x1a7fe2[_0x38a2d1('0x1a')](_0x38a2d1('0x11')),_0x38a2d1('0x11'));_0x54d8d8['write'](_0x1bb01d),_0x54d8d8[_0x38a2d1('0x5')](),_0x54d8d8['on']('close',function(){_0x1da41b(_0x2125ec);});}catch(_0x55557a){fs[_0x38a2d1('0x27')](_0x2125ec,_0x2775c3=>{_0x1575e8(_0x2775c3===null?_0x55557a:_0x2775c3);});}});});}async function decryptFile(_0x48bd44,_0x9f20d,_0x197b76,_0x1f7bca={}){const _0x2ad187=_0x2ad457;_0x1f7bca={...DEFAULT_FILE_OPTIONS,..._0x1f7bca};const _0x55b2b1=Buffer['from'](_0x1f7bca[_0x2ad187('0x2b')],_0x2ad187('0x1d'))[_0x2ad187('0x14')],_0x599305=IVLEN_MAP[_0x1f7bca['algorithm']],_0x4a6e2b=_0x599305+_0x55b2b1,_0xa4ec24=await fs[_0x2ad187('0xa')]['open'](_0x48bd44,'r'),_0x1b6049=Buffer[_0x2ad187('0x2e')](_0x4a6e2b),{buffer:_0x2e7b6d}=await _0xa4ec24[_0x2ad187('0x2')](_0x1b6049,0x0,_0x4a6e2b),_0x5305a4=_0x2e7b6d[_0x2ad187('0x0')](0x0,_0x599305),_0x1abf07=_0x2e7b6d[_0x2ad187('0x0')](_0x599305),_0x4fa7cd=_0x1abf07['toString'](_0x2ad187('0x1d')),_0x5eee30=_0x5305a4[_0x2ad187('0x24')]('base64'),_0x1a7cb6=_0x4fa7cd===_0x1f7bca['separator'];return new Promise(function(_0xd664f8,_0x25e865){const _0x6280bb=_0x2ad187,_0x95463e=fs['createReadStream'](_0x48bd44,{'start':_0x1a7cb6?_0x4a6e2b:0x0,'fd':_0xa4ec24,'autoClose':!![]}),_0x4ba2bf=fs[_0x6280bb('0x18')](_0x9f20d),_0x4fe89e=getDecipher(_0x197b76,_0x1f7bca['algorithm'],_0x1a7cb6?_0x5eee30:null);_0x95463e['on'](_0x6280bb('0x29'),function(_0x1c648c){const _0x452869=_0x6280bb,_0xa9f3a=Buffer['from'](_0x4fe89e['update'](_0x1c648c),'binary');_0x4ba2bf[_0x452869('0x23')](_0xa9f3a);}),_0x95463e['on'](_0x6280bb('0x9'),_0x3d3a48=>_0x25e865(_0x3d3a48)),_0x95463e['on'](_0x6280bb('0x5'),function(){const _0xb2eebd=_0x6280bb;try{const _0x5684ec=Buffer[_0xb2eebd('0x13')](_0x4fe89e[_0xb2eebd('0x1a')](_0xb2eebd('0x11')),'binary');_0x4ba2bf[_0xb2eebd('0x23')](_0x5684ec),_0x4ba2bf['end'](),_0x4ba2bf['on'](_0xb2eebd('0x25'),function(){_0xd664f8(_0x9f20d);});}catch(_0x58bd8d){fs[_0xb2eebd('0x27')](_0x9f20d,_0x5a05d7=>{_0x25e865(_0x5a05d7===null?_0x58bd8d:_0x5a05d7);});}});});}function encryptString(_0x300601,_0x13cc7f=DEFAULT_STRING_OPTIONS[_0x2ad457('0x3')],_0x497169=DEFAULT_STRING_OPTIONS[_0x2ad457('0x22')],_0x45d81b=DEFAULT_STRING_OPTIONS[_0x2ad457('0x2b')]){const _0x55ca03=_0x2ad457;if(!_0x300601||_0x300601[_0x55ca03('0x14')]===0x0)return _0x300601;if(!_0x13cc7f||_0x13cc7f[_0x55ca03('0x14')]===0x0)throw new Error(_0x55ca03('0x20'));const [_0x21b1d2,_0x55003b]=getCipherAndIvText(_0x13cc7f,_0x497169);let _0x394606=_0x21b1d2[_0x55ca03('0x19')](_0x300601,'utf8','base64');return _0x394606+=_0x21b1d2[_0x55ca03('0x1a')]('base64'),[_0x55003b,_0x394606][_0x55ca03('0xf')](_0x45d81b);}function decryptString(_0x5483d9,_0x272ce2=DEFAULT_STRING_OPTIONS['secret'],_0x42fcb7=DEFAULT_STRING_OPTIONS[_0x2ad457('0x22')],_0x1f7005=DEFAULT_STRING_OPTIONS[_0x2ad457('0x2b')]){const _0x1657b4=_0x2ad457;if(!_0x5483d9||_0x5483d9['length']===0x0)return _0x5483d9;if(!_0x272ce2||_0x272ce2['length']===0x0)throw new Error(_0x1657b4('0x20'));const _0x144b36=_0x5483d9[_0x1657b4('0xe')](_0x1f7005),_0x399262=_0x144b36[_0x1657b4('0x14')]===0x2,_0x3838ba=_0x399262?_0x144b36[0x1]:_0x5483d9,_0x5afdca=getDecipher(_0x272ce2,_0x42fcb7,_0x399262?_0x144b36[0x0]:undefined);let _0x11de45=_0x5afdca[_0x1657b4('0x19')](_0x3838ba,_0x1657b4('0x4'),_0x1657b4('0x2a'));return _0x11de45+=_0x5afdca[_0x1657b4('0x1a')](_0x1657b4('0x2a')),_0x11de45;}function getValueFromLicense(_0x4b292f,_0x21fca8){const _0x22a284=_0x2ad457;if(_0x4b292f&&_0x21fca8){if(_0x21fca8[_0x22a284('0x1')]&&_0x21fca8[_0x22a284('0x21')]){const _0x4912b0=_0x21fca8['data1'],_0x1916f2=_0x21fca8[_0x22a284('0x21')],_0x28f435=_0x4912b0[_0x22a284('0xe')]('-')[0x4],_0xcf6ca8=_0x4912b0[_0x22a284('0xe')]('-')[0x0],_0x18889b=[_0x28f435,_0x4912b0,_0xcf6ca8][_0x22a284('0xf')](':'),_0x49f6b9=getDecipher(_0x18889b,_0x22a284('0x26'));let _0x3aa747=_0x49f6b9[_0x22a284('0x19')](_0x1916f2,_0x22a284('0x4'),_0x22a284('0x2a'));_0x3aa747+=_0x49f6b9[_0x22a284('0x1a')](_0x22a284('0x2a'));const _0x293988=JSON[_0x22a284('0x8')](_0x3aa747);return typeof _0x293988[_0x4b292f]===_0x22a284('0x28')?null:_0x293988[_0x4b292f];}}return null;}module[_0x2ad457('0x6')]={'encryptFile':encryptFile,'decryptFile':decryptFile,'encryptString':encryptString,'decryptString':decryptString,'getValueFromLicense':getValueFromLicense}; \ No newline at end of file diff --git a/server/components/export/csv.js b/server/components/export/csv.js index 6462d75..6e94e40 100644 --- a/server/components/export/csv.js +++ b/server/components/export/csv.js @@ -1 +1 @@ -const a826_0x4a50=['argv','AnalyticExtractedReport','zip-dir','SELECT','info','csv','Completed','QueryTypes','analytics','util','mkdirSync','sequelize','num','to-csv','.csv','dirname','basename','Failed','../../config/logger','CSV','savename','zip','join','then','splitSizeCsv','length','Extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format\x20completed','split','push','path','findOne','Error\x20during\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format','Setting','Empty','format','query','../../mysqldb','each','Start\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format','inspect'];(function(_0x2e21ea,_0x4a50f8){const _0x2ce41a=function(_0x1beded){while(--_0x1beded){_0x2e21ea['push'](_0x2e21ea['shift']());}};_0x2ce41a(++_0x4a50f8);}(a826_0x4a50,0x119));const a826_0x2ce4=function(_0x2e21ea,_0x4a50f8){_0x2e21ea=_0x2e21ea-0x0;let _0x2ce41a=a826_0x4a50[_0x2e21ea];return _0x2ce41a;};const _0x312f9e=a826_0x2ce4;'use strict';const util=require(_0x312f9e('0x8')),path=require(_0x312f9e('0x1c')),csv=require(_0x312f9e('0xc')),fs=require('fs'),zipdir=require(_0x312f9e('0x1')),rimraf=require('rimraf'),db=require(_0x312f9e('0x23'))['db'],dbH=require(_0x312f9e('0x23'))['dbH'],logger=require(_0x312f9e('0x11'))(_0x312f9e('0x7')),EXTRACTED_REPORT_ID=Number(process[_0x312f9e('0x27')][0x2]),QUERY=process[_0x312f9e('0x27')][0x3],PATH=process[_0x312f9e('0x27')][0x4];function analyticExtractedReport(_0x1beded,_0x537c92){const _0x1892ca=_0x312f9e,_0x2aeb5d={'status':_0x1beded},_0x2ece8a={'where':{'id':EXTRACTED_REPORT_ID}};return _0x537c92&&(_0x2aeb5d[_0x1892ca('0x13')]=_0x537c92),db[_0x1892ca('0x0')]['update'](_0x2aeb5d,_0x2ece8a);}function main(){const _0x41f631=_0x312f9e;let _0x14a3ec=0x1388,_0x15756a;return logger[_0x41f631('0x3')](util[_0x41f631('0x21')](_0x41f631('0x25'),EXTRACTED_REPORT_ID,_0x41f631('0x12'))),db[_0x41f631('0x1f')][_0x41f631('0x1d')]({'where':{'id':0x1},'raw':!![],'attributes':['id',_0x41f631('0x1a'),_0x41f631('0x17')]})[_0x41f631('0x16')](function(_0x335941){const _0x4fbf95=_0x41f631;_0x335941&&(_0x15756a=_0x335941,_0x14a3ec=_0x15756a[_0x4fbf95('0x17')]||0x1388);})[_0x41f631('0x16')](function(){const _0x1ad494=_0x41f631;return dbH[_0x1ad494('0xa')][_0x1ad494('0x22')](util[_0x1ad494('0x21')]('SELECT\x20count(*)\x20as\x20num\x20FROM\x20(%s)\x20t',QUERY),{'type':dbH[_0x1ad494('0xa')]['QueryTypes'][_0x1ad494('0x2')]});})[_0x41f631('0x16')](function(_0x1b2f14){const _0x4820ba=_0x41f631;if(!_0x1b2f14[0x0][_0x4820ba('0xb')])return analyticExtractedReport(_0x4820ba('0x20'));const _0x33b53c=[];let _0x38a1cd=0x0,_0x3bea4e=!![];if(_0x1b2f14&&_0x1b2f14[_0x4820ba('0x18')]){let _0x353938=_0x1b2f14[0x0][_0x4820ba('0xb')]%(_0x38a1cd+_0x14a3ec);if(_0x15756a[_0x4820ba('0x1a')])for(;_0x3bea4e;_0x38a1cd+=_0x14a3ec,_0x353938=_0x1b2f14[0x0][_0x4820ba('0xb')]%(_0x38a1cd+_0x14a3ec)){(_0x353938==0x0||_0x353938==_0x1b2f14[0x0][_0x4820ba('0xb')])&&(_0x3bea4e=![]),_0x33b53c['push'](dbH[_0x4820ba('0xa')][_0x4820ba('0x22')](util[_0x4820ba('0x21')]('%s\x20limit\x20%d\x20OFFSET\x20%d',QUERY,_0x14a3ec,_0x38a1cd),{'type':dbH[_0x4820ba('0xa')][_0x4820ba('0x6')]['SELECT']}));}else _0x33b53c[_0x4820ba('0x1b')](dbH[_0x4820ba('0xa')][_0x4820ba('0x22')](QUERY,{'type':dbH['sequelize'][_0x4820ba('0x6')][_0x4820ba('0x2')]}));}const _0x2afb24=path[_0x4820ba('0xe')](PATH),_0x451dde=path[_0x4820ba('0xf')](PATH,_0x4820ba('0xd')),_0x44bfaa=_0x15756a[_0x4820ba('0x1a')]&&_0x33b53c['length']>0x1,_0x3dd59e=[];return!fs['existsSync'](path['join'](_0x2afb24,_0x451dde))&&_0x44bfaa&&fs[_0x4820ba('0x9')](path['join'](_0x2afb24,_0x451dde)),Promise[_0x4820ba('0x24')](_0x33b53c,function(_0x10c84d){_0x3dd59e['push'](_0x10c84d);})[_0x4820ba('0x16')](function(){const _0x48ca1e=_0x4820ba;for(let _0xcfc8e1=0x0;_0xcfc8e1<_0x3dd59e[_0x48ca1e('0x18')];_0xcfc8e1+=0x1){let _0x20c74c;const _0x26621f=_0x3dd59e[_0xcfc8e1];_0x44bfaa?_0x20c74c=path['join'](_0x2afb24,_0x451dde,util[_0x48ca1e('0x21')]('%s%d.%s',_0x451dde,_0xcfc8e1,'csv')):_0x20c74c=path[_0x48ca1e('0x15')](_0x2afb24,util[_0x48ca1e('0x21')]('%s.%s',_0x451dde,_0x48ca1e('0x4'))),fs['writeFileSync'](_0x20c74c,csv(_0x26621f));}})[_0x4820ba('0x16')](function(){const _0x3cb938=_0x4820ba;_0x44bfaa&&(zipdir(path['join'](_0x2afb24,_0x451dde),{'saveTo':path[_0x3cb938('0x15')](_0x2afb24,util['format']('%s.%s',_0x451dde,_0x3cb938('0x14')))},function(){}),rimraf(path[_0x3cb938('0x15')](_0x2afb24,_0x451dde),function(){}));})[_0x4820ba('0x16')](function(){const _0x55e435=_0x4820ba;return logger[_0x55e435('0x3')](util['format'](_0x55e435('0x19'),EXTRACTED_REPORT_ID,_0x55e435('0x12'))),analyticExtractedReport(_0x55e435('0x5'),_0x44bfaa?util[_0x55e435('0x21')]('%s.%s',_0x451dde,_0x44bfaa?_0x55e435('0x14'):_0x55e435('0x4')):null);});})['catch'](function(_0x13f794){const _0x23286a=_0x41f631;return logger[_0x23286a('0x3')](util[_0x23286a('0x21')](_0x23286a('0x1e'),EXTRACTED_REPORT_ID,_0x23286a('0x12')),util[_0x23286a('0x26')](_0x13f794,{'showHidden':![],'depth':null})),analyticExtractedReport(_0x23286a('0x10'));});}main(); \ No newline at end of file +const a826_0x3b12=['inspect','Failed','split','%s\x20limit\x20%d\x20OFFSET\x20%d','splitSizeCsv','csv','CSV','join','rimraf','query','update','num','info','then','%s.%s','existsSync','Start\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format','each','argv','catch','Empty','Completed','dbH','%s%d.%s','format','push','savename','zip-dir','length','QueryTypes','../../mysqldb','analytics','findOne','zip','sequelize','mkdirSync','dirname','AnalyticExtractedReport','SELECT'];(function(_0xec36af,_0x3b12b3){const _0x29d846=function(_0x377cb6){while(--_0x377cb6){_0xec36af['push'](_0xec36af['shift']());}};_0x29d846(++_0x3b12b3);}(a826_0x3b12,0x168));const a826_0x29d8=function(_0xec36af,_0x3b12b3){_0xec36af=_0xec36af-0x0;let _0x29d846=a826_0x3b12[_0xec36af];return _0x29d846;};const _0x184708=a826_0x29d8;'use strict';const util=require('util'),path=require('path'),csv=require('to-csv'),fs=require('fs'),zipdir=require(_0x184708('0x12')),rimraf=require(_0x184708('0x26')),db=require(_0x184708('0x15'))['db'],dbH=require(_0x184708('0x15'))[_0x184708('0xd')],logger=require('../../config/logger')(_0x184708('0x16')),EXTRACTED_REPORT_ID=Number(process[_0x184708('0x9')][0x2]),QUERY=process[_0x184708('0x9')][0x3],PATH=process[_0x184708('0x9')][0x4];function analyticExtractedReport(_0x377cb6,_0x52dce9){const _0x36c0b7=_0x184708,_0x311b94={'status':_0x377cb6},_0x24d41d={'where':{'id':EXTRACTED_REPORT_ID}};return _0x52dce9&&(_0x311b94[_0x36c0b7('0x11')]=_0x52dce9),db[_0x36c0b7('0x1c')][_0x36c0b7('0x1')](_0x311b94,_0x24d41d);}function main(){const _0x4ebd0d=_0x184708;let _0x30bd0c=0x1388,_0x4db804;return logger[_0x4ebd0d('0x3')](util[_0x4ebd0d('0xf')](_0x4ebd0d('0x7'),EXTRACTED_REPORT_ID,_0x4ebd0d('0x24'))),db['Setting'][_0x4ebd0d('0x17')]({'where':{'id':0x1},'raw':!![],'attributes':['id','split',_0x4ebd0d('0x22')]})[_0x4ebd0d('0x4')](function(_0x14e27f){_0x14e27f&&(_0x4db804=_0x14e27f,_0x30bd0c=_0x4db804['splitSizeCsv']||0x1388);})[_0x4ebd0d('0x4')](function(){const _0x576033=_0x4ebd0d;return dbH['sequelize'][_0x576033('0x0')](util[_0x576033('0xf')]('SELECT\x20count(*)\x20as\x20num\x20FROM\x20(%s)\x20t',QUERY),{'type':dbH[_0x576033('0x19')][_0x576033('0x14')][_0x576033('0x1d')]});})[_0x4ebd0d('0x4')](function(_0x6147f1){const _0x21e844=_0x4ebd0d;if(!_0x6147f1[0x0]['num'])return analyticExtractedReport(_0x21e844('0xb'));const _0x5300b8=[];let _0x2c750e=0x0,_0x548822=!![];if(_0x6147f1&&_0x6147f1[_0x21e844('0x13')]){let _0x386c28=_0x6147f1[0x0][_0x21e844('0x2')]%(_0x2c750e+_0x30bd0c);if(_0x4db804[_0x21e844('0x20')])for(;_0x548822;_0x2c750e+=_0x30bd0c,_0x386c28=_0x6147f1[0x0][_0x21e844('0x2')]%(_0x2c750e+_0x30bd0c)){(_0x386c28==0x0||_0x386c28==_0x6147f1[0x0][_0x21e844('0x2')])&&(_0x548822=![]),_0x5300b8[_0x21e844('0x10')](dbH['sequelize']['query'](util[_0x21e844('0xf')](_0x21e844('0x21'),QUERY,_0x30bd0c,_0x2c750e),{'type':dbH['sequelize'][_0x21e844('0x14')]['SELECT']}));}else _0x5300b8['push'](dbH['sequelize']['query'](QUERY,{'type':dbH[_0x21e844('0x19')][_0x21e844('0x14')]['SELECT']}));}const _0x315e7b=path[_0x21e844('0x1b')](PATH),_0x36099c=path['basename'](PATH,'.csv'),_0x383064=_0x4db804[_0x21e844('0x20')]&&_0x5300b8[_0x21e844('0x13')]>0x1,_0x2cd3d=[];return!fs[_0x21e844('0x6')](path[_0x21e844('0x25')](_0x315e7b,_0x36099c))&&_0x383064&&fs[_0x21e844('0x1a')](path[_0x21e844('0x25')](_0x315e7b,_0x36099c)),Promise[_0x21e844('0x8')](_0x5300b8,function(_0x2f4fac){_0x2cd3d['push'](_0x2f4fac);})['then'](function(){const _0x2e5ebf=_0x21e844;for(let _0x1435b0=0x0;_0x1435b0<_0x2cd3d[_0x2e5ebf('0x13')];_0x1435b0+=0x1){let _0x292046;const _0x5b1564=_0x2cd3d[_0x1435b0];_0x383064?_0x292046=path['join'](_0x315e7b,_0x36099c,util[_0x2e5ebf('0xf')](_0x2e5ebf('0xe'),_0x36099c,_0x1435b0,_0x2e5ebf('0x23'))):_0x292046=path['join'](_0x315e7b,util['format'](_0x2e5ebf('0x5'),_0x36099c,_0x2e5ebf('0x23'))),fs['writeFileSync'](_0x292046,csv(_0x5b1564));}})[_0x21e844('0x4')](function(){const _0x370b63=_0x21e844;_0x383064&&(zipdir(path[_0x370b63('0x25')](_0x315e7b,_0x36099c),{'saveTo':path[_0x370b63('0x25')](_0x315e7b,util[_0x370b63('0xf')](_0x370b63('0x5'),_0x36099c,_0x370b63('0x18')))},function(){}),rimraf(path[_0x370b63('0x25')](_0x315e7b,_0x36099c),function(){}));})[_0x21e844('0x4')](function(){const _0x473a4d=_0x21e844;return logger[_0x473a4d('0x3')](util[_0x473a4d('0xf')]('Extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format\x20completed',EXTRACTED_REPORT_ID,_0x473a4d('0x24'))),analyticExtractedReport(_0x473a4d('0xc'),_0x383064?util[_0x473a4d('0xf')](_0x473a4d('0x5'),_0x36099c,_0x383064?_0x473a4d('0x18'):'csv'):null);});})[_0x4ebd0d('0xa')](function(_0xecfb72){const _0xae29f6=_0x4ebd0d;return logger[_0xae29f6('0x3')](util[_0xae29f6('0xf')]('Error\x20during\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format',EXTRACTED_REPORT_ID,'CSV'),util[_0xae29f6('0x1e')](_0xecfb72,{'showHidden':![],'depth':null})),analyticExtractedReport(_0xae29f6('0x1f'));});}main(); \ No newline at end of file diff --git a/server/components/export/pdf.js b/server/components/export/pdf.js index a2a322e..138347e 100644 --- a/server/components/export/pdf.js +++ b/server/components/export/pdf.js @@ -1 +1 @@ -const a827_0x21b4=['../../config/logger','push','SELECT','%s%d.%s','undefined','log','query','Extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format\x20completed','zip-dir','then','SELECT\x20count(*)\x20as\x20num\x20FROM\x20(%s)\x20t','Empty','/fonts/Roboto-Medium.ttf','dbH','argv','/fonts/Roboto-Italic.ttf','AnalyticExtractedReport','body','length','each','split','findOne','endDate','CSV','dirname','rimraf','/fonts/Roboto-Regular.ttf','basename','Error\x20during\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format','pdfmake/src/printer','inspect','toString','join','format','num','pipe','MMMM\x20Do\x20YYYY,\x20h:mm:ss\x20a','util','/fonts/Roboto-MediumItalic.ttf','sequelize','mkdirSync','path','createPdfKitDocument','savename','err','%s.%s','black','moment','PDF','QueryTypes','../../mysqldb','landscape','splitSizePdf','.pdf','%s\x20limit\x20%d\x20OFFSET\x20%d','Name:\x20%s\x0aReport:\x20%s\x0aFrom:\x20%s\x20To:\x20%s','finish','info','createWriteStream','Failed','Completed','pdf','update','error'];(function(_0x14282c,_0x21b4f5){const _0xd6b1f6=function(_0x45f0a2){while(--_0x45f0a2){_0x14282c['push'](_0x14282c['shift']());}};_0xd6b1f6(++_0x21b4f5);}(a827_0x21b4,0x172));const a827_0xd6b1=function(_0x14282c,_0x21b4f5){_0x14282c=_0x14282c-0x0;let _0xd6b1f6=a827_0x21b4[_0x14282c];return _0xd6b1f6;};const _0x2f9af7=a827_0xd6b1;'use strict';const _=require('lodash'),fs=require('fs'),util=require(_0x2f9af7('0x33')),path=require(_0x2f9af7('0x37')),moment=require(_0x2f9af7('0x3d')),PdfPrinter=require(_0x2f9af7('0x2b')),zipdir=require(_0x2f9af7('0x16')),rimraf=require(_0x2f9af7('0x27')),db=require(_0x2f9af7('0x0'))['db'],dbH=require(_0x2f9af7('0x0'))[_0x2f9af7('0x1b')],logger=require(_0x2f9af7('0xe'))('analytics'),EXTRACTED_REPORT_ID=Number(process[_0x2f9af7('0x1c')][0x2]),QUERY=process['argv'][0x3],PATH=process[_0x2f9af7('0x1c')][0x4],NAME=process[_0x2f9af7('0x1c')][0x5],FORMAT=_0x2f9af7('0x32');let _extractedReport;function analyticExtractedReport(_0x45f0a2,_0x1b4411){const _0x248533=_0x2f9af7,_0x136e89={'status':_0x45f0a2},_0x54b4ee={'where':{'id':EXTRACTED_REPORT_ID}};return _0x1b4411&&(_0x136e89[_0x248533('0x39')]=_0x1b4411),db['AnalyticExtractedReport'][_0x248533('0xc')](_0x136e89,_0x54b4ee);}function getHeader(_0x32e5c9){const _0xbe2bd0=_0x2f9af7,_0x491731=[];for(const _0x533f6c in _0x32e5c9){typeof _0x32e5c9[_0x533f6c]!==_0xbe2bd0('0x12')&&_0x491731[_0xbe2bd0('0xf')]({'text':_0x533f6c,'style':'tableHeader'});}return _0x491731;}function extractReport(_0x1dc741){const _0x349e6e=_0x2f9af7;let _0xbe31e5=0x1388,_0x1d36ad;if(!_0x1dc741[0x0][_0x349e6e('0x30')])return analyticExtractedReport(_0x349e6e('0x19'));const _0x1b543d=[];let _0x4fff90=0x0,_0x4f5864=!![];const _0x5eef75=path[_0x349e6e('0x26')](PATH),_0x30383d=path[_0x349e6e('0x29')](PATH,_0x349e6e('0x3'));let _0x132e60=![];const _0x2c8fe2=[];return db['Setting'][_0x349e6e('0x23')]({'where':{'id':0x1},'raw':!![],'attributes':['id',_0x349e6e('0x22'),_0x349e6e('0x2')]})['then'](function(_0x252e7f){const _0x43f026=_0x349e6e;_0x252e7f&&(_0x1d36ad=_0x252e7f,_0xbe31e5=_0x1d36ad[_0x43f026('0x2')]||0x3e8);})[_0x349e6e('0x17')](function(){const _0x358654=_0x349e6e;if(_0x1dc741&&_0x1dc741[_0x358654('0x20')]){let _0xcd3281=_0x1dc741[0x0][_0x358654('0x30')]%(_0x4fff90+_0xbe31e5);if(_0x1d36ad['split'])for(;_0x4f5864;_0x4fff90+=_0xbe31e5,_0xcd3281=_0x1dc741[0x0][_0x358654('0x30')]%(_0x4fff90+_0xbe31e5)){(_0xcd3281==0x0||_0xcd3281==_0x1dc741[0x0][_0x358654('0x30')])&&(_0x4f5864=![]),_0x1b543d[_0x358654('0xf')](dbH[_0x358654('0x35')][_0x358654('0x14')](util[_0x358654('0x2f')](_0x358654('0x4'),QUERY,_0xbe31e5,_0x4fff90),{'type':dbH[_0x358654('0x35')]['QueryTypes'][_0x358654('0x10')]}));}else _0x1b543d[_0x358654('0xf')](dbH['sequelize'][_0x358654('0x14')](QUERY,{'type':dbH[_0x358654('0x35')][_0x358654('0x3f')][_0x358654('0x10')]}));}return _0x132e60=_0x1d36ad[_0x358654('0x22')]&&_0x1b543d[_0x358654('0x20')]>0x1,!fs['existsSync'](path[_0x358654('0x2e')](_0x5eef75,_0x30383d))&&_0x132e60&&fs[_0x358654('0x36')](path['join'](_0x5eef75,_0x30383d)),Promise[_0x358654('0x21')](_0x1b543d,function(_0x37b06c){_0x2c8fe2['push'](_0x37b06c);});})[_0x349e6e('0x17')](function(){const _0x465270=_0x349e6e;return Promise[_0x465270('0x21')](_0x1b543d,function(_0x58bb91,_0x2b9f66){const _0x515c36=_0x465270;let _0x55f273;const _0x428d37=util['format'](_0x515c36('0x5'),NAME,_extractedReport['name'],moment(_extractedReport['startDate'])[_0x515c36('0x2f')](FORMAT),moment(_extractedReport[_0x515c36('0x24')])[_0x515c36('0x2f')](FORMAT)),_0x2e02f5={'pageSize':'A4','pageOrientation':_0x515c36('0x1'),'content':[{'text':_0x428d37,'style':'header'}],'styles':{'header':{'fontSize':0x12,'bold':!![],'margin':[0x0,0x0,0x0,0xa]},'tableHeader':{'bold':!![],'fontSize':0xd,'color':_0x515c36('0x3c')}}},_0x32a53b={'headerRows':0x1,'body':[]};_0x32a53b[_0x515c36('0x1f')][_0x515c36('0xf')](getHeader(_0x58bb91[0x0]));let _0x2f9cff;for(let _0x4d7295=0x0;_0x4d7295<_0x58bb91[_0x515c36('0x20')];_0x4d7295+=0x1){_0x2f9cff=[];for(const _0x57598f in _0x58bb91[_0x4d7295]){typeof _0x58bb91[_0x4d7295][_0x57598f]!==_0x515c36('0x12')&&_0x2f9cff[_0x515c36('0xf')](_0x58bb91[_0x4d7295][_0x57598f]?_[_0x515c36('0x2d')](_0x58bb91[_0x4d7295][_0x57598f]):'');}_0x32a53b['body'][_0x515c36('0xf')](_0x2f9cff);}return _0x2e02f5['content'][_0x515c36('0xf')]({'table':_0x32a53b}),new Promise(function(_0x150d9e,_0x7e5aee){const _0x15d4ec=_0x515c36,_0x430c1b=new PdfPrinter({'Roboto':{'normal':__dirname+_0x15d4ec('0x28'),'bold':__dirname+_0x15d4ec('0x1a'),'italics':__dirname+_0x15d4ec('0x1d'),'bolditalics':__dirname+_0x15d4ec('0x34')}}),_0x3fdbe9=_0x430c1b[_0x15d4ec('0x38')](_0x2e02f5);_0x132e60?_0x55f273=path[_0x15d4ec('0x2e')](_0x5eef75,_0x30383d,util[_0x15d4ec('0x2f')](_0x15d4ec('0x11'),_0x30383d,_0x2b9f66,_0x15d4ec('0xb'))):_0x55f273=path[_0x15d4ec('0x2e')](_0x5eef75,util[_0x15d4ec('0x2f')]('%s.%s',_0x30383d,_0x15d4ec('0xb')));const _0x59c6af=_0x3fdbe9[_0x15d4ec('0x31')](fs[_0x15d4ec('0x8')](_0x55f273));_0x59c6af['on'](_0x15d4ec('0x6'),function(){_0x150d9e();}),_0x59c6af['on'](_0x15d4ec('0xd'),function(_0x4b434e){const _0x5306d0=_0x15d4ec;console[_0x5306d0('0x13')](_0x5306d0('0x3a'),_0x4b434e),_0x7e5aee(_0x4b434e);}),_0x3fdbe9['end']();});});})['then'](function(){if(_0x132e60)return new Promise(function(_0x5110a9,_0x35e438){const _0x1c083c=a827_0xd6b1;zipdir(path[_0x1c083c('0x2e')](_0x5eef75,_0x30383d),{'saveTo':path['join'](_0x5eef75,util[_0x1c083c('0x2f')](_0x1c083c('0x3b'),_0x30383d,'zip'))},function(_0x4267b8){_0x4267b8?_0x35e438(_0x4267b8):_0x5110a9();});});})[_0x349e6e('0x17')](function(){_0x132e60&&rimraf(path['join'](_0x5eef75,_0x30383d),function(){});})['then'](function(){const _0x4257b7=_0x349e6e;return logger[_0x4257b7('0x7')](util['format'](_0x4257b7('0x15'),EXTRACTED_REPORT_ID,_0x4257b7('0x25'))),analyticExtractedReport(_0x4257b7('0xa'),_0x132e60?util[_0x4257b7('0x2f')](_0x4257b7('0x3b'),_0x30383d,_0x132e60?'zip':_0x4257b7('0xb')):null);});}function main(){const _0x1d9c89=_0x2f9af7;return logger[_0x1d9c89('0x7')](util[_0x1d9c89('0x2f')]('Start\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format',EXTRACTED_REPORT_ID,_0x1d9c89('0x3e'))),db[_0x1d9c89('0x1e')]['findOne']({'where':{'id':EXTRACTED_REPORT_ID}})[_0x1d9c89('0x17')](function(_0x30a5af){const _0x1b50aa=_0x1d9c89;return _extractedReport=_0x30a5af,dbH['sequelize'][_0x1b50aa('0x14')](util['format'](_0x1b50aa('0x18'),QUERY),{'type':dbH[_0x1b50aa('0x35')][_0x1b50aa('0x3f')]['SELECT']});})[_0x1d9c89('0x17')](extractReport)['catch'](function(_0x9c44db){const _0x4e52bb=_0x1d9c89;return logger['info'](util[_0x4e52bb('0x2f')](_0x4e52bb('0x2a'),EXTRACTED_REPORT_ID,'PDF'),util[_0x4e52bb('0x2c')](_0x9c44db,{'showHidden':![],'depth':null})),analyticExtractedReport(_0x4e52bb('0x9'));});}main(); \ No newline at end of file +const a827_0x372e=['dbH','SELECT\x20count(*)\x20as\x20num\x20FROM\x20(%s)\x20t','err','zip-dir','body','createWriteStream','black','then','splitSizePdf','tableHeader','info','existsSync','content','analytics','Error\x20during\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format','PDF','QueryTypes','zip','Extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format\x20completed','length','name','mkdirSync','Start\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format','pipe','pdf','push','savename','startDate','SELECT','AnalyticExtractedReport','catch','dirname','join','num','inspect','Completed','../../mysqldb','query','path','rimraf','.pdf','finish','createPdfKitDocument','argv','log','%s\x20limit\x20%d\x20OFFSET\x20%d','%s.%s','/fonts/Roboto-Italic.ttf','sequelize','split','Empty','findOne','util','each','format','error'];(function(_0x50f3a7,_0x372edb){const _0x26cd11=function(_0x57fe8b){while(--_0x57fe8b){_0x50f3a7['push'](_0x50f3a7['shift']());}};_0x26cd11(++_0x372edb);}(a827_0x372e,0xed));const a827_0x26cd=function(_0x50f3a7,_0x372edb){_0x50f3a7=_0x50f3a7-0x0;let _0x26cd11=a827_0x372e[_0x50f3a7];return _0x26cd11;};const _0x584e33=a827_0x26cd;'use strict';const _=require('lodash'),fs=require('fs'),util=require(_0x584e33('0x27')),path=require(_0x584e33('0x19')),moment=require('moment'),PdfPrinter=require('pdfmake/src/printer'),zipdir=require(_0x584e33('0x2e')),rimraf=require(_0x584e33('0x1a')),db=require('../../mysqldb')['db'],dbH=require(_0x584e33('0x17'))[_0x584e33('0x2b')],logger=require('../../config/logger')(_0x584e33('0x0')),EXTRACTED_REPORT_ID=Number(process[_0x584e33('0x1e')][0x2]),QUERY=process[_0x584e33('0x1e')][0x3],PATH=process['argv'][0x4],NAME=process[_0x584e33('0x1e')][0x5],FORMAT='MMMM\x20Do\x20YYYY,\x20h:mm:ss\x20a';let _extractedReport;function analyticExtractedReport(_0x57fe8b,_0x1d0bc4){const _0x348308=_0x584e33,_0x1c49a6={'status':_0x57fe8b},_0x3c3e8d={'where':{'id':EXTRACTED_REPORT_ID}};return _0x1d0bc4&&(_0x1c49a6[_0x348308('0xd')]=_0x1d0bc4),db[_0x348308('0x10')]['update'](_0x1c49a6,_0x3c3e8d);}function getHeader(_0x4e8d42){const _0x539b3b=_0x584e33,_0x55fd7e=[];for(const _0x40ec4a in _0x4e8d42){typeof _0x4e8d42[_0x40ec4a]!=='undefined'&&_0x55fd7e[_0x539b3b('0xc')]({'text':_0x40ec4a,'style':_0x539b3b('0x34')});}return _0x55fd7e;}function extractReport(_0x104062){const _0x5b2400=_0x584e33;let _0x270bc3=0x1388,_0xf600bd;if(!_0x104062[0x0]['num'])return analyticExtractedReport(_0x5b2400('0x25'));const _0x39af2f=[];let _0x122da4=0x0,_0x21872c=!![];const _0x48f60c=path[_0x5b2400('0x12')](PATH),_0x162c29=path['basename'](PATH,_0x5b2400('0x1b'));let _0x1d4a15=![];const _0x46cd2a=[];return db['Setting'][_0x5b2400('0x26')]({'where':{'id':0x1},'raw':!![],'attributes':['id','split',_0x5b2400('0x33')]})[_0x5b2400('0x32')](function(_0x5be256){const _0x19a2a3=_0x5b2400;_0x5be256&&(_0xf600bd=_0x5be256,_0x270bc3=_0xf600bd[_0x19a2a3('0x33')]||0x3e8);})[_0x5b2400('0x32')](function(){const _0x218035=_0x5b2400;if(_0x104062&&_0x104062['length']){let _0x311ed9=_0x104062[0x0]['num']%(_0x122da4+_0x270bc3);if(_0xf600bd[_0x218035('0x24')])for(;_0x21872c;_0x122da4+=_0x270bc3,_0x311ed9=_0x104062[0x0]['num']%(_0x122da4+_0x270bc3)){(_0x311ed9==0x0||_0x311ed9==_0x104062[0x0][_0x218035('0x14')])&&(_0x21872c=![]),_0x39af2f[_0x218035('0xc')](dbH['sequelize'][_0x218035('0x18')](util['format'](_0x218035('0x20'),QUERY,_0x270bc3,_0x122da4),{'type':dbH[_0x218035('0x23')][_0x218035('0x3')][_0x218035('0xf')]}));}else _0x39af2f['push'](dbH[_0x218035('0x23')]['query'](QUERY,{'type':dbH[_0x218035('0x23')]['QueryTypes'][_0x218035('0xf')]}));}return _0x1d4a15=_0xf600bd['split']&&_0x39af2f[_0x218035('0x6')]>0x1,!fs[_0x218035('0x36')](path['join'](_0x48f60c,_0x162c29))&&_0x1d4a15&&fs[_0x218035('0x8')](path['join'](_0x48f60c,_0x162c29)),Promise[_0x218035('0x28')](_0x39af2f,function(_0x443a2b){const _0x40a815=_0x218035;_0x46cd2a[_0x40a815('0xc')](_0x443a2b);});})[_0x5b2400('0x32')](function(){const _0x410bc2=_0x5b2400;return Promise[_0x410bc2('0x28')](_0x39af2f,function(_0x3ba176,_0x5663ae){const _0x22c9e5=_0x410bc2;let _0x4926d4;const _0x48c29c=util[_0x22c9e5('0x29')]('Name:\x20%s\x0aReport:\x20%s\x0aFrom:\x20%s\x20To:\x20%s',NAME,_extractedReport[_0x22c9e5('0x7')],moment(_extractedReport[_0x22c9e5('0xe')])[_0x22c9e5('0x29')](FORMAT),moment(_extractedReport['endDate'])[_0x22c9e5('0x29')](FORMAT)),_0x3b1e58={'pageSize':'A4','pageOrientation':'landscape','content':[{'text':_0x48c29c,'style':'header'}],'styles':{'header':{'fontSize':0x12,'bold':!![],'margin':[0x0,0x0,0x0,0xa]},'tableHeader':{'bold':!![],'fontSize':0xd,'color':_0x22c9e5('0x31')}}},_0x1523dd={'headerRows':0x1,'body':[]};_0x1523dd[_0x22c9e5('0x2f')][_0x22c9e5('0xc')](getHeader(_0x3ba176[0x0]));let _0x1bb96a;for(let _0x5d7ad0=0x0;_0x5d7ad0<_0x3ba176[_0x22c9e5('0x6')];_0x5d7ad0+=0x1){_0x1bb96a=[];for(const _0x3e31ca in _0x3ba176[_0x5d7ad0]){typeof _0x3ba176[_0x5d7ad0][_0x3e31ca]!=='undefined'&&_0x1bb96a[_0x22c9e5('0xc')](_0x3ba176[_0x5d7ad0][_0x3e31ca]?_['toString'](_0x3ba176[_0x5d7ad0][_0x3e31ca]):'');}_0x1523dd[_0x22c9e5('0x2f')]['push'](_0x1bb96a);}return _0x3b1e58[_0x22c9e5('0x37')]['push']({'table':_0x1523dd}),new Promise(function(_0x47eeee,_0x58dccb){const _0x283f05=_0x22c9e5,_0x38e472=new PdfPrinter({'Roboto':{'normal':__dirname+'/fonts/Roboto-Regular.ttf','bold':__dirname+'/fonts/Roboto-Medium.ttf','italics':__dirname+_0x283f05('0x22'),'bolditalics':__dirname+'/fonts/Roboto-MediumItalic.ttf'}}),_0x6145df=_0x38e472[_0x283f05('0x1d')](_0x3b1e58);_0x1d4a15?_0x4926d4=path['join'](_0x48f60c,_0x162c29,util[_0x283f05('0x29')]('%s%d.%s',_0x162c29,_0x5663ae,_0x283f05('0xb'))):_0x4926d4=path[_0x283f05('0x13')](_0x48f60c,util[_0x283f05('0x29')](_0x283f05('0x21'),_0x162c29,'pdf'));const _0x231ab8=_0x6145df[_0x283f05('0xa')](fs[_0x283f05('0x30')](_0x4926d4));_0x231ab8['on'](_0x283f05('0x1c'),function(){_0x47eeee();}),_0x231ab8['on'](_0x283f05('0x2a'),function(_0x4545a3){const _0x1cc13e=_0x283f05;console[_0x1cc13e('0x1f')](_0x1cc13e('0x2d'),_0x4545a3),_0x58dccb(_0x4545a3);}),_0x6145df['end']();});});})[_0x5b2400('0x32')](function(){if(_0x1d4a15)return new Promise(function(_0x563d06,_0x40009f){const _0xfde287=a827_0x26cd;zipdir(path[_0xfde287('0x13')](_0x48f60c,_0x162c29),{'saveTo':path[_0xfde287('0x13')](_0x48f60c,util[_0xfde287('0x29')]('%s.%s',_0x162c29,'zip'))},function(_0x1dc5b2){_0x1dc5b2?_0x40009f(_0x1dc5b2):_0x563d06();});});})[_0x5b2400('0x32')](function(){_0x1d4a15&&rimraf(path['join'](_0x48f60c,_0x162c29),function(){});})[_0x5b2400('0x32')](function(){const _0x24c039=_0x5b2400;return logger[_0x24c039('0x35')](util['format'](_0x24c039('0x5'),EXTRACTED_REPORT_ID,'CSV')),analyticExtractedReport(_0x24c039('0x16'),_0x1d4a15?util[_0x24c039('0x29')](_0x24c039('0x21'),_0x162c29,_0x1d4a15?_0x24c039('0x4'):_0x24c039('0xb')):null);});}function main(){const _0x45319b=_0x584e33;return logger['info'](util[_0x45319b('0x29')](_0x45319b('0x9'),EXTRACTED_REPORT_ID,_0x45319b('0x2'))),db[_0x45319b('0x10')][_0x45319b('0x26')]({'where':{'id':EXTRACTED_REPORT_ID}})[_0x45319b('0x32')](function(_0x348527){const _0x34de3e=_0x45319b;return _extractedReport=_0x348527,dbH[_0x34de3e('0x23')][_0x34de3e('0x18')](util[_0x34de3e('0x29')](_0x34de3e('0x2c'),QUERY),{'type':dbH[_0x34de3e('0x23')][_0x34de3e('0x3')][_0x34de3e('0xf')]});})[_0x45319b('0x32')](extractReport)[_0x45319b('0x11')](function(_0x1a61b2){const _0x56f654=_0x45319b;return logger[_0x56f654('0x35')](util[_0x56f654('0x29')](_0x56f654('0x1'),EXTRACTED_REPORT_ID,_0x56f654('0x2')),util[_0x56f654('0x15')](_0x1a61b2,{'showHidden':![],'depth':null})),analyticExtractedReport('Failed');});}main(); \ No newline at end of file diff --git a/server/components/export/xlsx.js b/server/components/export/xlsx.js index 1a7a987..59c8f9a 100644 --- a/server/components/export/xlsx.js +++ b/server/components/export/xlsx.js @@ -1 +1 @@ -const a828_0x1030=['XLSX','inspect','util','QueryTypes','Empty','split','basename','analytics','catch','update','../../config/logger','SELECT','../../mysqldb','Extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format\x20completed','savename','zip','%s%d.%s','info','length','%s.%s','num','dirname','findOne','join','xlsx','format','push','.xlsx','argv','query','writeFileSync','json2xls','Error\x20during\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format','sequelize','then','mkdirSync','splitSizeXlsx','%s\x20limit\x20%d\x20OFFSET\x20%d','rimraf'];(function(_0x293e6a,_0x10301a){const _0x81cbca=function(_0x2e4973){while(--_0x2e4973){_0x293e6a['push'](_0x293e6a['shift']());}};_0x81cbca(++_0x10301a);}(a828_0x1030,0x164));const a828_0x81cb=function(_0x293e6a,_0x10301a){_0x293e6a=_0x293e6a-0x0;let _0x81cbca=a828_0x1030[_0x293e6a];return _0x81cbca;};const _0x3e1892=a828_0x81cb;'use strict';const util=require(_0x3e1892('0x24')),path=require('path'),fs=require('fs'),json2xls=require(_0x3e1892('0x1a')),zipdir=require('zip-dir'),rimraf=require(_0x3e1892('0x21')),db=require(_0x3e1892('0x7'))['db'],dbH=require(_0x3e1892('0x7'))['dbH'],logger=require(_0x3e1892('0x5'))(_0x3e1892('0x2')),EXTRACTED_REPORT_ID=Number(process[_0x3e1892('0x17')][0x2]),QUERY=process[_0x3e1892('0x17')][0x3],PATH=process[_0x3e1892('0x17')][0x4];function analyticExtractedReport(_0x2e4973,_0x3352cb){const _0x7d5225=_0x3e1892,_0x53474b={'status':_0x2e4973},_0x3f6723={'where':{'id':EXTRACTED_REPORT_ID}};return _0x3352cb&&(_0x53474b[_0x7d5225('0x9')]=_0x3352cb),db['AnalyticExtractedReport'][_0x7d5225('0x4')](_0x53474b,_0x3f6723);}function main(){const _0xe1c907=_0x3e1892;let _0x308307=0x1388,_0x55c20c;return logger[_0xe1c907('0xc')](util[_0xe1c907('0x14')]('Start\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format',EXTRACTED_REPORT_ID,_0xe1c907('0x22'))),db['Setting'][_0xe1c907('0x11')]({'where':{'id':0x1},'raw':!![],'attributes':['id','split',_0xe1c907('0x1f')]})[_0xe1c907('0x1d')](function(_0x4e3554){const _0x58103f=_0xe1c907;_0x4e3554&&(_0x55c20c=_0x4e3554,_0x308307=_0x55c20c[_0x58103f('0x1f')]||0x1388);})['then'](function(){const _0xdf3f0d=_0xe1c907;return dbH['sequelize']['query'](util['format']('SELECT\x20count(*)\x20as\x20num\x20FROM\x20(%s)\x20t',QUERY),{'type':dbH['sequelize'][_0xdf3f0d('0x25')]['SELECT']});})[_0xe1c907('0x1d')](function(_0x39d600){const _0x248637=_0xe1c907;if(!_0x39d600[0x0][_0x248637('0xf')])return analyticExtractedReport(_0x248637('0x26'));const _0x40314f=[];let _0x2a0815=0x0,_0x5de15f=!![];if(_0x55c20c['split']){if(_0x39d600&&_0x39d600[_0x248637('0xd')]){let _0x154b79=_0x39d600[0x0]['num']%(_0x2a0815+_0x308307);for(;_0x5de15f;_0x2a0815+=_0x308307,_0x154b79=_0x39d600[0x0][_0x248637('0xf')]%(_0x2a0815+_0x308307)){(_0x154b79==0x0||_0x154b79==_0x39d600[0x0]['num'])&&(_0x5de15f=![]),_0x40314f['push'](dbH['sequelize']['query'](util[_0x248637('0x14')](_0x248637('0x20'),QUERY,_0x308307,_0x2a0815),{'type':dbH['sequelize'][_0x248637('0x25')]['SELECT']}));}}}else _0x40314f[_0x248637('0x15')](dbH[_0x248637('0x1c')][_0x248637('0x18')](QUERY,{'type':dbH[_0x248637('0x1c')][_0x248637('0x25')][_0x248637('0x6')]}));const _0x1b4b4f=path[_0x248637('0x10')](PATH),_0x57ae2e=path[_0x248637('0x1')](PATH,_0x248637('0x16')),_0x59442f=_0x55c20c[_0x248637('0x0')]&&_0x40314f['length']>0x1,_0xbfb71e=[];return!fs['existsSync'](path[_0x248637('0x12')](_0x1b4b4f,_0x57ae2e))&&_0x59442f&&fs[_0x248637('0x1e')](path['join'](_0x1b4b4f,_0x57ae2e)),Promise['each'](_0x40314f,function(_0x2059aa){const _0x35ba55=_0x248637;_0xbfb71e[_0x35ba55('0x15')](_0x2059aa);})['then'](function(){const _0x273fc9=_0x248637;for(let _0x337cde=0x0;_0x337cde<_0xbfb71e[_0x273fc9('0xd')];_0x337cde+=0x1){let _0x1b476b;const _0x1dd80f=_0xbfb71e[_0x337cde];_0x59442f?_0x1b476b=path['join'](_0x1b4b4f,_0x57ae2e,util[_0x273fc9('0x14')](_0x273fc9('0xb'),_0x57ae2e,_0x337cde,_0x273fc9('0x13'))):_0x1b476b=path['join'](_0x1b4b4f,util['format'](_0x273fc9('0xe'),_0x57ae2e,'xlsx')),fs[_0x273fc9('0x19')](_0x1b476b,json2xls(_0x1dd80f),'binary');}})[_0x248637('0x1d')](function(){const _0x278a84=_0x248637;_0x59442f&&(zipdir(path[_0x278a84('0x12')](_0x1b4b4f,_0x57ae2e),{'saveTo':path[_0x278a84('0x12')](_0x1b4b4f,util[_0x278a84('0x14')](_0x278a84('0xe'),_0x57ae2e,_0x278a84('0xa')))},function(){}),rimraf(path[_0x278a84('0x12')](_0x1b4b4f,_0x57ae2e),function(){}));})[_0x248637('0x1d')](function(){const _0x5cae45=_0x248637;return logger['info'](util[_0x5cae45('0x14')](_0x5cae45('0x8'),EXTRACTED_REPORT_ID,_0x5cae45('0x22'))),analyticExtractedReport('Completed',_0x59442f?util['format'](_0x5cae45('0xe'),_0x57ae2e,_0x59442f?_0x5cae45('0xa'):'xlsx'):null);});})[_0xe1c907('0x3')](function(_0x53d48d){const _0x3f8b91=_0xe1c907;return logger[_0x3f8b91('0xc')](util['format'](_0x3f8b91('0x1b'),EXTRACTED_REPORT_ID,_0x3f8b91('0x22')),util[_0x3f8b91('0x23')](_0x53d48d,{'showHidden':![],'depth':null})),analyticExtractedReport('Failed');});}main(); \ No newline at end of file +const a828_0x1de4=['format','join','Extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format\x20completed','argv','each','.xlsx','sequelize','XLSX','existsSync','%s%d.%s','push','../../mysqldb','splitSizeXlsx','%s\x20limit\x20%d\x20OFFSET\x20%d','mkdirSync','num','writeFileSync','zip-dir','zip','inspect','catch','Completed','binary','json2xls','split','info','QueryTypes','AnalyticExtractedReport','basename','query','dirname','rimraf','../../config/logger','update','xlsx','SELECT','%s.%s','path','util','then','Start\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format','length'];(function(_0x4f86ce,_0x1de4c4){const _0x5362f0=function(_0x394458){while(--_0x394458){_0x4f86ce['push'](_0x4f86ce['shift']());}};_0x5362f0(++_0x1de4c4);}(a828_0x1de4,0x193));const a828_0x5362=function(_0x4f86ce,_0x1de4c4){_0x4f86ce=_0x4f86ce-0x0;let _0x5362f0=a828_0x1de4[_0x4f86ce];return _0x5362f0;};const _0x2953c9=a828_0x5362;'use strict';const util=require(_0x2953c9('0xd')),path=require(_0x2953c9('0xc')),fs=require('fs'),json2xls=require(_0x2953c9('0x28')),zipdir=require(_0x2953c9('0x22')),rimraf=require(_0x2953c9('0x6')),db=require('../../mysqldb')['db'],dbH=require(_0x2953c9('0x1c'))['dbH'],logger=require(_0x2953c9('0x7'))('analytics'),EXTRACTED_REPORT_ID=Number(process[_0x2953c9('0x14')][0x2]),QUERY=process[_0x2953c9('0x14')][0x3],PATH=process[_0x2953c9('0x14')][0x4];function analyticExtractedReport(_0x394458,_0x4530de){const _0x207849=_0x2953c9,_0x24fb87={'status':_0x394458},_0x4aaf79={'where':{'id':EXTRACTED_REPORT_ID}};return _0x4530de&&(_0x24fb87['savename']=_0x4530de),db[_0x207849('0x2')][_0x207849('0x8')](_0x24fb87,_0x4aaf79);}function main(){const _0x203dfb=_0x2953c9;let _0xd636ad=0x1388,_0x23c491;return logger['info'](util[_0x203dfb('0x11')](_0x203dfb('0xf'),EXTRACTED_REPORT_ID,_0x203dfb('0x18'))),db['Setting']['findOne']({'where':{'id':0x1},'raw':!![],'attributes':['id',_0x203dfb('0x29'),'splitSizeXlsx']})['then'](function(_0x1d6ac6){const _0x211499=_0x203dfb;_0x1d6ac6&&(_0x23c491=_0x1d6ac6,_0xd636ad=_0x23c491[_0x211499('0x1d')]||0x1388);})[_0x203dfb('0xe')](function(){const _0x5e866d=_0x203dfb;return dbH[_0x5e866d('0x17')][_0x5e866d('0x4')](util[_0x5e866d('0x11')]('SELECT\x20count(*)\x20as\x20num\x20FROM\x20(%s)\x20t',QUERY),{'type':dbH[_0x5e866d('0x17')]['QueryTypes'][_0x5e866d('0xa')]});})[_0x203dfb('0xe')](function(_0x44fc06){const _0xb93dcb=_0x203dfb;if(!_0x44fc06[0x0][_0xb93dcb('0x20')])return analyticExtractedReport('Empty');const _0x4a453e=[];let _0x472e88=0x0,_0x1b2e92=!![];if(_0x23c491[_0xb93dcb('0x29')]){if(_0x44fc06&&_0x44fc06[_0xb93dcb('0x10')]){let _0x15a2d7=_0x44fc06[0x0]['num']%(_0x472e88+_0xd636ad);for(;_0x1b2e92;_0x472e88+=_0xd636ad,_0x15a2d7=_0x44fc06[0x0]['num']%(_0x472e88+_0xd636ad)){(_0x15a2d7==0x0||_0x15a2d7==_0x44fc06[0x0][_0xb93dcb('0x20')])&&(_0x1b2e92=![]),_0x4a453e['push'](dbH[_0xb93dcb('0x17')][_0xb93dcb('0x4')](util['format'](_0xb93dcb('0x1e'),QUERY,_0xd636ad,_0x472e88),{'type':dbH['sequelize'][_0xb93dcb('0x1')]['SELECT']}));}}}else _0x4a453e['push'](dbH[_0xb93dcb('0x17')][_0xb93dcb('0x4')](QUERY,{'type':dbH[_0xb93dcb('0x17')][_0xb93dcb('0x1')][_0xb93dcb('0xa')]}));const _0x1d3af2=path[_0xb93dcb('0x5')](PATH),_0x19d133=path[_0xb93dcb('0x3')](PATH,_0xb93dcb('0x16')),_0x29e95e=_0x23c491[_0xb93dcb('0x29')]&&_0x4a453e[_0xb93dcb('0x10')]>0x1,_0x5bf72b=[];return!fs[_0xb93dcb('0x19')](path[_0xb93dcb('0x12')](_0x1d3af2,_0x19d133))&&_0x29e95e&&fs[_0xb93dcb('0x1f')](path[_0xb93dcb('0x12')](_0x1d3af2,_0x19d133)),Promise[_0xb93dcb('0x15')](_0x4a453e,function(_0x78b040){const _0x128cbc=_0xb93dcb;_0x5bf72b[_0x128cbc('0x1b')](_0x78b040);})[_0xb93dcb('0xe')](function(){const _0x1b0826=_0xb93dcb;for(let _0x542465=0x0;_0x542465<_0x5bf72b['length'];_0x542465+=0x1){let _0x499d78;const _0x361e3b=_0x5bf72b[_0x542465];_0x29e95e?_0x499d78=path[_0x1b0826('0x12')](_0x1d3af2,_0x19d133,util[_0x1b0826('0x11')](_0x1b0826('0x1a'),_0x19d133,_0x542465,_0x1b0826('0x9'))):_0x499d78=path['join'](_0x1d3af2,util[_0x1b0826('0x11')](_0x1b0826('0xb'),_0x19d133,_0x1b0826('0x9'))),fs[_0x1b0826('0x21')](_0x499d78,json2xls(_0x361e3b),_0x1b0826('0x27'));}})[_0xb93dcb('0xe')](function(){const _0x10d049=_0xb93dcb;_0x29e95e&&(zipdir(path[_0x10d049('0x12')](_0x1d3af2,_0x19d133),{'saveTo':path['join'](_0x1d3af2,util[_0x10d049('0x11')](_0x10d049('0xb'),_0x19d133,_0x10d049('0x23')))},function(){}),rimraf(path[_0x10d049('0x12')](_0x1d3af2,_0x19d133),function(){}));})[_0xb93dcb('0xe')](function(){const _0x578629=_0xb93dcb;return logger[_0x578629('0x0')](util[_0x578629('0x11')](_0x578629('0x13'),EXTRACTED_REPORT_ID,_0x578629('0x18'))),analyticExtractedReport(_0x578629('0x26'),_0x29e95e?util[_0x578629('0x11')]('%s.%s',_0x19d133,_0x29e95e?_0x578629('0x23'):_0x578629('0x9')):null);});})[_0x203dfb('0x25')](function(_0x2a4fe8){const _0x211632=_0x203dfb;return logger[_0x211632('0x0')](util[_0x211632('0x11')]('Error\x20during\x20extraction\x20report\x20with\x20id\x20%d\x20in\x20%s\x20format',EXTRACTED_REPORT_ID,'XLSX'),util[_0x211632('0x24')](_0x2a4fe8,{'showHidden':![],'depth':null})),analyticExtractedReport('Failed');});}main(); \ No newline at end of file diff --git a/server/components/extensions/rewrite.js b/server/components/extensions/rewrite.js index fc7ca91..c906c6f 100644 --- a/server/components/extensions/rewrite.js +++ b/server/components/extensions/rewrite.js @@ -1 +1 @@ -const a829_0x308d=['find','VoiceExtension','_XCALLY_MIXMONITOR_UNIQUEID=${UNIQUEID}','${EXTEN}','CDR(prefix)=${EXTEN:0:','intervals','last','CDR(prefix)=noprefix','undefined','GotoIfTime','transaction','literal','sequelize','*,*,*,*','extension','Interval',',${EXTEN},','uniq','):Goto(','wav','recordingFormat','map','lodash','CDR(destination)=','XCALLY-MOTION-PROGRESS=0','$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):Set(CALLERID(all)=','updatedAt','$[${LEN(${CDR(prefix)})}\x20>\x200]?Goto(','concat','XCALLY-MOTION-PROGRESS=1','bulkCreate','outbound','XCALLY-MOTION-ANSWER=1','Hangup','$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):NoOp(No\x20number\x20available)','groupBy','MONITOR_OPTIONS=ab','exten','ExecIf','type','rewrite','CAST(priority\x20AS\x20UNSIGNED)','priority','context','tag','none','$[${XCALLY-MOTION-ANSWER}=0]?Answer','VoiceExtensionId','length','toLowerCase','models','$[${XCALLY-MOTION-PROGRESS}=0]?Progress','push','CDR(type)=%s','filter','outboundrouteid=','appType','findAll','createdAt','interval','cutdigits','Set','app','sortBy','format','destroy','answer','custom','IntervalId','callerID','extensions','then'];(function(_0x214e4b,_0x308d3a){const _0x5f2807=function(_0x4cf51a){while(--_0x4cf51a){_0x214e4b['push'](_0x214e4b['shift']());}};_0x5f2807(++_0x308d3a);}(a829_0x308d,0x17d));const a829_0x5f28=function(_0x214e4b,_0x308d3a){_0x214e4b=_0x214e4b-0x0;let _0x5f2807=a829_0x308d[_0x214e4b];return _0x5f2807;};const _0x2483a6=a829_0x5f28;'use strict';const _=require(_0x2483a6('0x1')),util=require('util'),{Op}=require(_0x2483a6('0x3f'));function rewrite(_0x4cf51a,_0x129035){const _0x5e220a=_0x2483a6,_0x5e362c=this;return _0x4cf51a[_0x5e220a('0x1d')][_0x5e220a('0x42')]['findAll']({'raw':!![]})[_0x5e220a('0x32')](function(_0x369fb0){const _0x59541b=_0x5e220a;return _0x5e362c['intervals']=_0x369fb0,_0x4cf51a[_0x59541b('0x1d')][_0x59541b('0x34')][_0x59541b('0x24')]({'where':{'IntervalId':_0x129035[_0x59541b('0x2f')]},'raw':!![]});})[_0x5e220a('0x32')](function(_0xdbe075){const _0x4c7814=_0x5e220a;return _0x4cf51a['models'][_0x4c7814('0x34')][_0x4c7814('0x24')]({'where':{'exten':{[Op['in']]:_[_0x4c7814('0x44')](_[_0x4c7814('0x0')](_0xdbe075,_0x4c7814('0x10')))}},'order':_0x4cf51a[_0x4c7814('0x3e')](_0x4c7814('0x14')),'raw':!![]});})[_0x5e220a('0x32')](function(_0x14eb10){const _0x2dbc71=_0x5e220a,_0x219a61=_[_0x2dbc71('0x21')](_0x14eb10,{'priority':'1'}),_0x1e2c4b=_[_0x2dbc71('0x21')](_0x14eb10,{'isApp':0x1}),_0x5e2cd1=_[_0x2dbc71('0xe')](_0x1e2c4b,_0x2dbc71('0x10')),_0xee194d=['queue','playback'],_0x119ff6=[];let _0x39adfe=[];for(const _0x394b05 in _0x5e2cd1){if(typeof _0x5e2cd1[_0x394b05]!==_0x2dbc71('0x3b')){_0x5e362c[_0x2dbc71('0x15')]=0x2,_0x5e362c['extensions']=[],_0x5e362c[_0x2dbc71('0x41')]=_[_0x2dbc71('0x33')](_0x219a61,{'exten':_0x5e2cd1[_0x394b05][0x0]['exten']}),_0x5e362c[_0x2dbc71('0x31')][_0x2dbc71('0x1f')]({'type':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x12')],'app':'Set','appdata':util[_0x2dbc71('0x2b')](_0x2dbc71('0x20'),_0x5e2cd1[_0x394b05][0x0]['type']),'context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'exten':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x10')],'priority':_0x5e362c[_0x2dbc71('0x15')]++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0]['VoiceExtensionId']});if(_0x5e2cd1[_0x394b05][0x0]['type']===_0x2dbc71('0xa')){_0x5e362c[_0x2dbc71('0x41')]&&_0x5e362c[_0x2dbc71('0x31')][_0x2dbc71('0x1f')]({'type':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x12')],'app':_0x2dbc71('0x28'),'appdata':_0x2dbc71('0x2')+(_0x5e362c[_0x2dbc71('0x41')]['cutdigits']?'${EXTEN:'+_0x5e362c[_0x2dbc71('0x41')][_0x2dbc71('0x27')]+'}':_0x2dbc71('0x36')),'context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'exten':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x10')],'priority':_0x5e362c[_0x2dbc71('0x15')]++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')]});_0x5e362c[_0x2dbc71('0x31')]['push']({'type':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x12')],'app':'Set','appdata':'CDR(routeid)='+_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')],'context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'exten':_0x5e2cd1[_0x394b05][0x0]['exten'],'priority':_0x5e362c['priority']++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')]});const _0x24f94e=_0x5e362c[_0x2dbc71('0x15')]++;_0x5e362c['extensions'][_0x2dbc71('0x1f')]({'type':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x12')],'app':'ExecIf','appdata':_0x2dbc71('0x6')+(_0x24f94e+0x2)+_0x2dbc71('0x45')+(_0x24f94e+0x1)+')','context':_0x5e2cd1[_0x394b05][0x0]['context'],'exten':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x10')],'priority':_0x24f94e,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0]['VoiceExtensionId']}),_0x5e362c[_0x2dbc71('0x41')]&&_0x5e362c[_0x2dbc71('0x31')][_0x2dbc71('0x1f')]({'type':_0x5e2cd1[_0x394b05][0x0]['type'],'app':'Set','appdata':_0x5e362c[_0x2dbc71('0x41')][_0x2dbc71('0x27')]?_0x2dbc71('0x37')+_0x5e362c[_0x2dbc71('0x41')][_0x2dbc71('0x27')]+'}':_0x2dbc71('0x3a'),'context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'exten':_0x5e2cd1[_0x394b05][0x0]['exten'],'priority':_0x5e362c[_0x2dbc71('0x15')]++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0]['VoiceExtensionId']}),_0x5e362c[_0x2dbc71('0x31')][_0x2dbc71('0x1f')]({'type':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x12')],'app':_0x2dbc71('0x28'),'appdata':_0x2dbc71('0x22')+_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')],'context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'exten':_0x5e2cd1[_0x394b05][0x0]['exten'],'priority':_0x5e362c['priority']++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')]}),_0x5e362c[_0x2dbc71('0x41')]&&typeof _0x5e362c[_0x2dbc71('0x41')]['recordingFormat']!==_0x2dbc71('0x3b')&&_0x5e362c['extension'][_0x2dbc71('0x47')]!==_0x2dbc71('0x18')&&(_0x5e362c[_0x2dbc71('0x31')][_0x2dbc71('0x1f')]({'type':_0x5e2cd1[_0x394b05][0x0]['type'],'app':_0x2dbc71('0x28'),'appdata':_0x2dbc71('0x35'),'context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'exten':_0x5e2cd1[_0x394b05][0x0]['exten'],'priority':_0x5e362c[_0x2dbc71('0x15')]++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0]['VoiceExtensionId']}),_0x5e362c[_0x2dbc71('0x31')]['push']({'type':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x12')],'app':_0x2dbc71('0x28'),'appdata':'_XCALLY_MIXMONITOR_FORMAT='+_0x5e362c[_0x2dbc71('0x41')]['recordingFormat']||_0x2dbc71('0x46'),'context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'exten':_0x5e2cd1[_0x394b05][0x0]['exten'],'priority':_0x5e362c[_0x2dbc71('0x15')]++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')]}));}_0x5e362c[_0x2dbc71('0x31')][_0x2dbc71('0x1f')]({'type':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x12')],'app':_0x2dbc71('0x28'),'appdata':'XCALLY-MOTION-ANSWER=0','context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'exten':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x10')],'priority':_0x5e362c['priority']++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')]}),_0x5e362c[_0x2dbc71('0x31')]['push']({'type':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x12')],'app':_0x2dbc71('0x28'),'appdata':_0x2dbc71('0x3'),'context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'exten':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x10')],'priority':_0x5e362c['priority']++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0]['VoiceExtensionId']}),_0x5e362c['extensions'][_0x2dbc71('0x1f')]({'type':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x12')],'app':'Set','appdata':_0x2dbc71('0xf'),'context':_0x5e2cd1[_0x394b05][0x0]['context'],'exten':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x10')],'priority':_0x5e362c['priority']++,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')]});for(let _0x3ce099=0x0,_0x48abcb=0x0;_0x3ce099<_0x5e2cd1[_0x394b05][_0x2dbc71('0x1b')];_0x3ce099+=0x1,_0x48abcb=0x0){const _0x531440=_0x5e2cd1[_0x394b05][_0x3ce099];_0x531440[_0x2dbc71('0x12')]&&(_0x531440[_0x2dbc71('0x12')]=_0x531440['type'][_0x2dbc71('0x1c')]());const _0x4a0ce7=[],_0x4b825b=[];delete _0x531440['id'],delete _0x531440[_0x2dbc71('0x25')],delete _0x531440[_0x2dbc71('0x5')];const _0x3a446e=_0x531440[_0x2dbc71('0x26')]!==_0x2dbc71('0x40')?[_0x531440[_0x2dbc71('0x26')]]:_0x531440['IntervalId']?_[_0x2dbc71('0x0')](_['filter'](_0x5e362c[_0x2dbc71('0x38')],{'IntervalId':_0x531440['IntervalId']}),'interval'):[];typeof _0x531440[_0x2dbc71('0x17')]!=='undefined'&&(_0x531440[_0x2dbc71('0x17')]&&_0x531440[_0x2dbc71('0x17')]!=='--'&&_0x4a0ce7['push']({'type':_0x531440[_0x2dbc71('0x12')],'app':_0x2dbc71('0x28'),'appdata':'CDR(tag)='+_0x531440[_0x2dbc71('0x17')],'context':_0x531440[_0x2dbc71('0x16')],'exten':_0x531440['exten'],'priority':_0x3a446e[_0x2dbc71('0x1b')]+_0x5e362c[_0x2dbc71('0x15')]+_0x48abcb++,'VoiceExtensionId':_0x531440[_0x2dbc71('0x1a')]}));_0x531440[_0x2dbc71('0x12')]==='outbound'&&typeof _0x531440[_0x2dbc71('0x30')]!==_0x2dbc71('0x3b')&&(_0x531440[_0x2dbc71('0x30')]?_0x4a0ce7[_0x2dbc71('0x1f')]({'type':_0x531440[_0x2dbc71('0x12')],'app':'ExecIf','appdata':_0x2dbc71('0x4')+_0x531440['callerID']+')','context':_0x531440[_0x2dbc71('0x16')],'exten':_0x531440[_0x2dbc71('0x10')],'priority':_0x3a446e[_0x2dbc71('0x1b')]+_0x5e362c[_0x2dbc71('0x15')]+_0x48abcb++,'VoiceExtensionId':_0x531440['VoiceExtensionId']}):_0x4a0ce7['push']({'type':_0x531440[_0x2dbc71('0x12')],'app':'ExecIf','appdata':_0x2dbc71('0xd'),'context':_0x531440[_0x2dbc71('0x16')],'exten':_0x531440['exten'],'priority':_0x3a446e[_0x2dbc71('0x1b')]+_0x5e362c[_0x2dbc71('0x15')]+_0x48abcb++,'VoiceExtensionId':_0x531440['VoiceExtensionId']}));typeof _0x531440[_0x2dbc71('0x2d')]!==_0x2dbc71('0x3b')&&(_0xee194d['indexOf'](_0x531440[_0x2dbc71('0x29')]['toLowerCase']())>=0x0&&_0x531440[_0x2dbc71('0x23')]!==_0x2dbc71('0x2e')&&(_0x531440[_0x2dbc71('0x2d')]?(_0x4a0ce7[_0x2dbc71('0x1f')]({'type':_0x531440[_0x2dbc71('0x12')],'app':_0x2dbc71('0x11'),'appdata':_0x2dbc71('0x19'),'context':_0x531440[_0x2dbc71('0x16')],'exten':_0x531440[_0x2dbc71('0x10')],'priority':_0x3a446e[_0x2dbc71('0x1b')]+_0x5e362c[_0x2dbc71('0x15')]+_0x48abcb++,'VoiceExtensionId':_0x531440[_0x2dbc71('0x1a')]}),_0x4a0ce7[_0x2dbc71('0x1f')]({'type':_0x531440[_0x2dbc71('0x12')],'app':_0x2dbc71('0x28'),'appdata':_0x2dbc71('0xb'),'context':_0x531440['context'],'exten':_0x531440[_0x2dbc71('0x10')],'priority':_0x3a446e[_0x2dbc71('0x1b')]+_0x5e362c[_0x2dbc71('0x15')]+_0x48abcb++,'VoiceExtensionId':_0x531440['VoiceExtensionId']})):(_0x4a0ce7[_0x2dbc71('0x1f')]({'type':_0x531440['type'],'app':_0x2dbc71('0x11'),'appdata':_0x2dbc71('0x1e'),'context':_0x531440['context'],'exten':_0x531440[_0x2dbc71('0x10')],'priority':_0x3a446e[_0x2dbc71('0x1b')]+_0x5e362c[_0x2dbc71('0x15')]+_0x48abcb++,'VoiceExtensionId':_0x531440[_0x2dbc71('0x1a')]}),_0x4a0ce7[_0x2dbc71('0x1f')]({'type':_0x531440['type'],'app':_0x2dbc71('0x28'),'appdata':_0x2dbc71('0x8'),'context':_0x531440[_0x2dbc71('0x16')],'exten':_0x531440['exten'],'priority':_0x3a446e['length']+_0x5e362c[_0x2dbc71('0x15')]+_0x48abcb++,'VoiceExtensionId':_0x531440[_0x2dbc71('0x1a')]}))));for(let _0x481913=0x0;_0x481913<_0x3a446e[_0x2dbc71('0x1b')];_0x481913+=0x1){const _0x429497=_0x5e362c[_0x2dbc71('0x15')]+_0x3a446e[_0x2dbc71('0x1b')],_0x4e3bb2=_0x481913===_0x3a446e[_0x2dbc71('0x1b')]-0x1?_0x5e362c['priority']+_0x4a0ce7[_0x2dbc71('0x1b')]+_0x4b825b['length']+0x2:_0x5e362c[_0x2dbc71('0x15')]+_0x481913+0x1;_0x4a0ce7['splice'](_0x481913,0x0,{'type':_0x531440[_0x2dbc71('0x12')],'app':_0x2dbc71('0x3c'),'appdata':_0x3a446e[_0x481913]+'?'+_0x531440[_0x2dbc71('0x16')]+_0x2dbc71('0x43')+_0x429497+':'+_0x531440[_0x2dbc71('0x16')]+_0x2dbc71('0x43')+_0x4e3bb2,'exten':_0x531440[_0x2dbc71('0x10')],'context':_0x531440['context'],'priority':_0x5e362c['priority']+_0x481913,'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')]});}_0x531440[_0x2dbc71('0x15')]=_0x4a0ce7[_0x2dbc71('0x1b')]?_['last'](_0x4a0ce7)['priority']+0x1:_0x5e362c['priority'],_0x5e362c[_0x2dbc71('0x15')]=(_0x4b825b[_0x2dbc71('0x1b')]?_[_0x2dbc71('0x39')](_0x4b825b)[_0x2dbc71('0x15')]:_0x531440['priority'])+0x1,_0x5e362c['extensions']=_['concat'](_0x5e362c['extensions'],_0x4a0ce7,[_0x531440],_0x4b825b);}_0x5e362c[_0x2dbc71('0x31')][_0x2dbc71('0x1f')]({'type':_0x5e2cd1[_0x394b05][0x0]['type'],'app':_0x2dbc71('0xc'),'exten':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x10')],'context':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x16')],'priority':_0x5e362c[_0x2dbc71('0x15')],'VoiceExtensionId':_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')]}),_0x119ff6[_0x2dbc71('0x1f')](_0x5e2cd1[_0x394b05][0x0][_0x2dbc71('0x1a')]),_0x39adfe=_[_0x2dbc71('0x7')](_0x39adfe,_0x5e362c[_0x2dbc71('0x31')]);}}return _0x4cf51a[_0x2dbc71('0x3d')](function(_0xacc1e7){const _0x559113=_0x2dbc71;return _0x4cf51a[_0x559113('0x1d')][_0x559113('0x34')][_0x559113('0x2c')]({'where':{'VoiceExtensionId':{[Op['in']]:_0x119ff6}},'transaction':_0xacc1e7})[_0x559113('0x32')](function(){const _0x2e9c66=_0x559113;return _0x4cf51a[_0x2e9c66('0x1d')][_0x2e9c66('0x34')][_0x2e9c66('0x9')](_[_0x2e9c66('0x2a')](_0x39adfe,_0x2e9c66('0x15')),{'transaction':_0xacc1e7});});});})['catch'](function(_0x29eea1){console['error'](_0x29eea1);});}exports[_0x2483a6('0x13')]=rewrite; \ No newline at end of file +const a829_0x1bca=['push','lodash','destroy','custom','exten','models','VoiceExtensionId','CDR(type)=%s','toLowerCase','indexOf','interval','format','$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):NoOp(No\x20number\x20available)','literal','IntervalId','app','map','util','undefined','none','_XCALLY_MIXMONITOR_FORMAT=','appType','CDR(routeid)=','priority','outbound','concat','bulkCreate','intervals','last','$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):Set(CALLERID(all)=','createdAt','CDR(prefix)=${EXTEN:0:','playback','CDR(prefix)=noprefix','splice','MONITOR_OPTIONS=ab','answer','findAll','tag','VoiceExtension','extensions','ExecIf','sortBy','then','callerID','context','filter','rewrite','recordingFormat','$[${XCALLY-MOTION-PROGRESS}=0]?Progress','catch','cutdigits','XCALLY-MOTION-PROGRESS=0','type','CDR(destination)=','XCALLY-MOTION-ANSWER=1','Set','error','Hangup','sequelize','length','*,*,*,*','transaction','):Goto(','wav','uniq',',${EXTEN},','CAST(priority\x20AS\x20UNSIGNED)','extension','${EXTEN}','_XCALLY_MIXMONITOR_UNIQUEID=${UNIQUEID}','CDR(tag)='];(function(_0x4ee74c,_0x1bca6b){const _0x3c2f1c=function(_0x50867b){while(--_0x50867b){_0x4ee74c['push'](_0x4ee74c['shift']());}};_0x3c2f1c(++_0x1bca6b);}(a829_0x1bca,0xfc));const a829_0x3c2f=function(_0x4ee74c,_0x1bca6b){_0x4ee74c=_0x4ee74c-0x0;let _0x3c2f1c=a829_0x1bca[_0x4ee74c];return _0x3c2f1c;};const _0x4417a7=a829_0x3c2f;'use strict';const _=require(_0x4417a7('0x25')),util=require(_0x4417a7('0x35')),{Op}=require(_0x4417a7('0x17'));function rewrite(_0x50867b,_0x152be0){const _0x1f04c2=_0x4417a7,_0x52e1a6=this;return _0x50867b[_0x1f04c2('0x29')]['Interval']['findAll']({'raw':!![]})[_0x1f04c2('0x7')](function(_0x23530c){const _0x60d3c3=_0x1f04c2;return _0x52e1a6[_0x60d3c3('0x3f')]=_0x23530c,_0x50867b[_0x60d3c3('0x29')][_0x60d3c3('0x3')][_0x60d3c3('0x1')]({'where':{'IntervalId':_0x152be0['IntervalId']},'raw':!![]});})[_0x1f04c2('0x7')](function(_0x1a23f7){const _0x1ddaf9=_0x1f04c2;return _0x50867b['models'][_0x1ddaf9('0x3')][_0x1ddaf9('0x1')]({'where':{'exten':{[Op['in']]:_[_0x1ddaf9('0x1d')](_[_0x1ddaf9('0x34')](_0x1a23f7,_0x1ddaf9('0x28')))}},'order':_0x50867b[_0x1ddaf9('0x31')](_0x1ddaf9('0x1f')),'raw':!![]});})['then'](function(_0x389606){const _0x4f05d5=_0x1f04c2,_0x31b016=_[_0x4f05d5('0xa')](_0x389606,{'priority':'1'}),_0x3d1b91=_[_0x4f05d5('0xa')](_0x389606,{'isApp':0x1}),_0x5a7b8a=_['groupBy'](_0x3d1b91,_0x4f05d5('0x28')),_0x2d9e02=['queue',_0x4f05d5('0x44')],_0x3010a7=[];let _0x2342ae=[];for(const _0x404095 in _0x5a7b8a){if(typeof _0x5a7b8a[_0x404095]!==_0x4f05d5('0x36')){_0x52e1a6[_0x4f05d5('0x3b')]=0x2,_0x52e1a6[_0x4f05d5('0x4')]=[],_0x52e1a6[_0x4f05d5('0x20')]=_['find'](_0x31b016,{'exten':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x28')]}),_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')],'app':'Set','appdata':util[_0x4f05d5('0x2f')](_0x4f05d5('0x2b'),_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')]),'context':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x9')],'exten':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x28')],'priority':_0x52e1a6['priority']++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]});if(_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')]==='outbound'){_0x52e1a6[_0x4f05d5('0x20')]&&_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')],'app':'Set','appdata':_0x4f05d5('0x12')+(_0x52e1a6[_0x4f05d5('0x20')]['cutdigits']?'${EXTEN:'+_0x52e1a6[_0x4f05d5('0x20')]['cutdigits']+'}':_0x4f05d5('0x21')),'context':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x9')],'exten':_0x5a7b8a[_0x404095][0x0]['exten'],'priority':_0x52e1a6[_0x4f05d5('0x3b')]++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]});_0x52e1a6['extensions'][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0]['type'],'app':_0x4f05d5('0x14'),'appdata':_0x4f05d5('0x3a')+_0x5a7b8a[_0x404095][0x0]['VoiceExtensionId'],'context':_0x5a7b8a[_0x404095][0x0]['context'],'exten':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x28')],'priority':_0x52e1a6[_0x4f05d5('0x3b')]++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]});const _0x2d53d1=_0x52e1a6['priority']++;_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')],'app':_0x4f05d5('0x5'),'appdata':'$[${LEN(${CDR(prefix)})}\x20>\x200]?Goto('+(_0x2d53d1+0x2)+_0x4f05d5('0x1b')+(_0x2d53d1+0x1)+')','context':_0x5a7b8a[_0x404095][0x0]['context'],'exten':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x28')],'priority':_0x2d53d1,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]}),_0x52e1a6[_0x4f05d5('0x20')]&&_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')],'app':_0x4f05d5('0x14'),'appdata':_0x52e1a6[_0x4f05d5('0x20')][_0x4f05d5('0xf')]?_0x4f05d5('0x43')+_0x52e1a6[_0x4f05d5('0x20')][_0x4f05d5('0xf')]+'}':_0x4f05d5('0x45'),'context':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x9')],'exten':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x28')],'priority':_0x52e1a6['priority']++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]}),_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')],'app':'Set','appdata':'outboundrouteid='+_0x5a7b8a[_0x404095][0x0]['VoiceExtensionId'],'context':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x9')],'exten':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x28')],'priority':_0x52e1a6['priority']++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0]['VoiceExtensionId']}),_0x52e1a6[_0x4f05d5('0x20')]&&typeof _0x52e1a6[_0x4f05d5('0x20')][_0x4f05d5('0xc')]!=='undefined'&&_0x52e1a6[_0x4f05d5('0x20')][_0x4f05d5('0xc')]!==_0x4f05d5('0x37')&&(_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0]['type'],'app':_0x4f05d5('0x14'),'appdata':_0x4f05d5('0x22'),'context':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x9')],'exten':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x28')],'priority':_0x52e1a6['priority']++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]}),_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')],'app':_0x4f05d5('0x14'),'appdata':_0x4f05d5('0x38')+_0x52e1a6[_0x4f05d5('0x20')][_0x4f05d5('0xc')]||_0x4f05d5('0x1c'),'context':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x9')],'exten':_0x5a7b8a[_0x404095][0x0]['exten'],'priority':_0x52e1a6['priority']++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]}));}_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')],'app':'Set','appdata':'XCALLY-MOTION-ANSWER=0','context':_0x5a7b8a[_0x404095][0x0]['context'],'exten':_0x5a7b8a[_0x404095][0x0]['exten'],'priority':_0x52e1a6['priority']++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]}),_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0]['type'],'app':_0x4f05d5('0x14'),'appdata':_0x4f05d5('0x10'),'context':_0x5a7b8a[_0x404095][0x0]['context'],'exten':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x28')],'priority':_0x52e1a6[_0x4f05d5('0x3b')]++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0]['VoiceExtensionId']}),_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')],'app':_0x4f05d5('0x14'),'appdata':_0x4f05d5('0x47'),'context':_0x5a7b8a[_0x404095][0x0]['context'],'exten':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x28')],'priority':_0x52e1a6[_0x4f05d5('0x3b')]++,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]});for(let _0x149e25=0x0,_0x3837a0=0x0;_0x149e25<_0x5a7b8a[_0x404095][_0x4f05d5('0x18')];_0x149e25+=0x1,_0x3837a0=0x0){const _0xe6cce5=_0x5a7b8a[_0x404095][_0x149e25];_0xe6cce5['type']&&(_0xe6cce5[_0x4f05d5('0x11')]=_0xe6cce5[_0x4f05d5('0x11')][_0x4f05d5('0x2c')]());const _0x459a73=[],_0x4ebf7a=[];delete _0xe6cce5['id'],delete _0xe6cce5[_0x4f05d5('0x42')],delete _0xe6cce5['updatedAt'];const _0x127a1d=_0xe6cce5[_0x4f05d5('0x2e')]!==_0x4f05d5('0x19')?[_0xe6cce5['interval']]:_0xe6cce5[_0x4f05d5('0x32')]?_[_0x4f05d5('0x34')](_[_0x4f05d5('0xa')](_0x52e1a6[_0x4f05d5('0x3f')],{'IntervalId':_0xe6cce5['IntervalId']}),'interval'):[];typeof _0xe6cce5['tag']!==_0x4f05d5('0x36')&&(_0xe6cce5[_0x4f05d5('0x2')]&&_0xe6cce5['tag']!=='--'&&_0x459a73[_0x4f05d5('0x24')]({'type':_0xe6cce5[_0x4f05d5('0x11')],'app':_0x4f05d5('0x14'),'appdata':_0x4f05d5('0x23')+_0xe6cce5[_0x4f05d5('0x2')],'context':_0xe6cce5[_0x4f05d5('0x9')],'exten':_0xe6cce5[_0x4f05d5('0x28')],'priority':_0x127a1d[_0x4f05d5('0x18')]+_0x52e1a6['priority']+_0x3837a0++,'VoiceExtensionId':_0xe6cce5[_0x4f05d5('0x2a')]}));_0xe6cce5['type']===_0x4f05d5('0x3c')&&typeof _0xe6cce5['callerID']!==_0x4f05d5('0x36')&&(_0xe6cce5[_0x4f05d5('0x8')]?_0x459a73['push']({'type':_0xe6cce5['type'],'app':'ExecIf','appdata':_0x4f05d5('0x41')+_0xe6cce5['callerID']+')','context':_0xe6cce5[_0x4f05d5('0x9')],'exten':_0xe6cce5['exten'],'priority':_0x127a1d[_0x4f05d5('0x18')]+_0x52e1a6[_0x4f05d5('0x3b')]+_0x3837a0++,'VoiceExtensionId':_0xe6cce5['VoiceExtensionId']}):_0x459a73[_0x4f05d5('0x24')]({'type':_0xe6cce5[_0x4f05d5('0x11')],'app':_0x4f05d5('0x5'),'appdata':_0x4f05d5('0x30'),'context':_0xe6cce5[_0x4f05d5('0x9')],'exten':_0xe6cce5['exten'],'priority':_0x127a1d['length']+_0x52e1a6[_0x4f05d5('0x3b')]+_0x3837a0++,'VoiceExtensionId':_0xe6cce5[_0x4f05d5('0x2a')]}));typeof _0xe6cce5[_0x4f05d5('0x0')]!==_0x4f05d5('0x36')&&(_0x2d9e02[_0x4f05d5('0x2d')](_0xe6cce5[_0x4f05d5('0x33')]['toLowerCase']())>=0x0&&_0xe6cce5[_0x4f05d5('0x39')]!==_0x4f05d5('0x27')&&(_0xe6cce5[_0x4f05d5('0x0')]?(_0x459a73[_0x4f05d5('0x24')]({'type':_0xe6cce5[_0x4f05d5('0x11')],'app':'ExecIf','appdata':'$[${XCALLY-MOTION-ANSWER}=0]?Answer','context':_0xe6cce5[_0x4f05d5('0x9')],'exten':_0xe6cce5[_0x4f05d5('0x28')],'priority':_0x127a1d[_0x4f05d5('0x18')]+_0x52e1a6[_0x4f05d5('0x3b')]+_0x3837a0++,'VoiceExtensionId':_0xe6cce5['VoiceExtensionId']}),_0x459a73['push']({'type':_0xe6cce5[_0x4f05d5('0x11')],'app':_0x4f05d5('0x14'),'appdata':_0x4f05d5('0x13'),'context':_0xe6cce5[_0x4f05d5('0x9')],'exten':_0xe6cce5[_0x4f05d5('0x28')],'priority':_0x127a1d['length']+_0x52e1a6[_0x4f05d5('0x3b')]+_0x3837a0++,'VoiceExtensionId':_0xe6cce5[_0x4f05d5('0x2a')]})):(_0x459a73[_0x4f05d5('0x24')]({'type':_0xe6cce5[_0x4f05d5('0x11')],'app':'ExecIf','appdata':_0x4f05d5('0xd'),'context':_0xe6cce5['context'],'exten':_0xe6cce5[_0x4f05d5('0x28')],'priority':_0x127a1d['length']+_0x52e1a6[_0x4f05d5('0x3b')]+_0x3837a0++,'VoiceExtensionId':_0xe6cce5['VoiceExtensionId']}),_0x459a73[_0x4f05d5('0x24')]({'type':_0xe6cce5[_0x4f05d5('0x11')],'app':'Set','appdata':'XCALLY-MOTION-PROGRESS=1','context':_0xe6cce5[_0x4f05d5('0x9')],'exten':_0xe6cce5[_0x4f05d5('0x28')],'priority':_0x127a1d[_0x4f05d5('0x18')]+_0x52e1a6['priority']+_0x3837a0++,'VoiceExtensionId':_0xe6cce5[_0x4f05d5('0x2a')]}))));for(let _0x1ad5a4=0x0;_0x1ad5a4<_0x127a1d[_0x4f05d5('0x18')];_0x1ad5a4+=0x1){const _0x3a4257=_0x52e1a6[_0x4f05d5('0x3b')]+_0x127a1d[_0x4f05d5('0x18')],_0x57c3e0=_0x1ad5a4===_0x127a1d['length']-0x1?_0x52e1a6[_0x4f05d5('0x3b')]+_0x459a73[_0x4f05d5('0x18')]+_0x4ebf7a[_0x4f05d5('0x18')]+0x2:_0x52e1a6[_0x4f05d5('0x3b')]+_0x1ad5a4+0x1;_0x459a73[_0x4f05d5('0x46')](_0x1ad5a4,0x0,{'type':_0xe6cce5[_0x4f05d5('0x11')],'app':'GotoIfTime','appdata':_0x127a1d[_0x1ad5a4]+'?'+_0xe6cce5[_0x4f05d5('0x9')]+_0x4f05d5('0x1e')+_0x3a4257+':'+_0xe6cce5['context']+',${EXTEN},'+_0x57c3e0,'exten':_0xe6cce5[_0x4f05d5('0x28')],'context':_0xe6cce5[_0x4f05d5('0x9')],'priority':_0x52e1a6['priority']+_0x1ad5a4,'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]});}_0xe6cce5['priority']=_0x459a73[_0x4f05d5('0x18')]?_[_0x4f05d5('0x40')](_0x459a73)[_0x4f05d5('0x3b')]+0x1:_0x52e1a6[_0x4f05d5('0x3b')],_0x52e1a6[_0x4f05d5('0x3b')]=(_0x4ebf7a[_0x4f05d5('0x18')]?_[_0x4f05d5('0x40')](_0x4ebf7a)['priority']:_0xe6cce5['priority'])+0x1,_0x52e1a6['extensions']=_[_0x4f05d5('0x3d')](_0x52e1a6[_0x4f05d5('0x4')],_0x459a73,[_0xe6cce5],_0x4ebf7a);}_0x52e1a6[_0x4f05d5('0x4')][_0x4f05d5('0x24')]({'type':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x11')],'app':_0x4f05d5('0x16'),'exten':_0x5a7b8a[_0x404095][0x0]['exten'],'context':_0x5a7b8a[_0x404095][0x0]['context'],'priority':_0x52e1a6[_0x4f05d5('0x3b')],'VoiceExtensionId':_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]}),_0x3010a7[_0x4f05d5('0x24')](_0x5a7b8a[_0x404095][0x0][_0x4f05d5('0x2a')]),_0x2342ae=_[_0x4f05d5('0x3d')](_0x2342ae,_0x52e1a6[_0x4f05d5('0x4')]);}}return _0x50867b[_0x4f05d5('0x1a')](function(_0x4244a8){const _0x619e3f=_0x4f05d5;return _0x50867b[_0x619e3f('0x29')][_0x619e3f('0x3')][_0x619e3f('0x26')]({'where':{'VoiceExtensionId':{[Op['in']]:_0x3010a7}},'transaction':_0x4244a8})['then'](function(){const _0x2dc2b4=_0x619e3f;return _0x50867b[_0x2dc2b4('0x29')][_0x2dc2b4('0x3')][_0x2dc2b4('0x3e')](_[_0x2dc2b4('0x6')](_0x2342ae,'priority'),{'transaction':_0x4244a8});});});})[_0x1f04c2('0xe')](function(_0x134a71){const _0x21d6e0=_0x1f04c2;console[_0x21d6e0('0x15')](_0x134a71);});}exports[_0x4417a7('0xb')]=rewrite; \ No newline at end of file diff --git a/server/components/import/cm/csv.js b/server/components/import/cm/csv.js index 8660f12..b90b3f7 100644 --- a/server/components/import/cm/csv.js +++ b/server/components/import/cm/csv.js @@ -1 +1 @@ -const a830_0x507f=['stringify','select','inspect','findAll','VoiceQueue','outbound','error','then','CmContact','Error\x20while\x20creating\x20contact:\x20','contact','CSV\x20parsed\x20correctly!','papaparse','phone\x20not\x20specified!','errors','util','onlyIfOpen','message','length','phone','all','argv','insert','dialCheckDuplicateType','../../../rediscache','birthDate\x20format\x20is\x20invalid,\x20YYYY-MM-DD\x20format\x20is\x20supported!','fromQuery','cm_hopper_black','undefined','id\x20IN\x20?','duplicate','updatedAt','CSV\x20parse\x20error','firstName','ListId\x20=\x20?','resume','cm_hopper','sequelize','pick','BlackLists','create','Error\x20executing\x20contact\x20csv\x20import:','email\x20format\x20is\x20not\x20valid!','exit','info','scheduledAt','resolve','CmList','finally','Unable\x20to\x20delete\x20temp\x20file:','push','get','keys','data','createReadStream','Lists','email','SIGINT','always','createdAt','moment','query','Missing\x20socket_timestamp\x20parameter!','from','CampaignId','ListId','parse','toString','NOW()','Error\x20processing\x20rows\x20block:','ContactId','split','Missing\x20ListId\x20parameter!','catch','../../../api/cmContact/cmContact.socket','\x20=\x20?','emit','phone\x20IS\x20NOT\x20NULL','deletedAt\x20IS\x20NULL','CSV\x20import\x20process\x20stopped!','field','pause','Missing\x20filepath\x20parameter!','contact:csv_','cmContact','../../../config/logger','firstName\x20not\x20specified!','cm_contacts','VoiceQueueId','zipObject','calleridnum','phone\x20NOT\x20IN\x20(?)','test','The\x20row\x20is\x20empty\x20or\x20the\x20number\x20of\x20parameters\x20does\x20not\x20match\x20the\x20columns!','unlinkSync','null','str','where','into'];(function(_0x279495,_0x507f4f){const _0x3c50fd=function(_0x23123d){while(--_0x23123d){_0x279495['push'](_0x279495['shift']());}};_0x3c50fd(++_0x507f4f);}(a830_0x507f,0x18e));const a830_0x3c50=function(_0x279495,_0x507f4f){_0x279495=_0x279495-0x0;let _0x3c50fd=a830_0x507f[_0x279495];return _0x3c50fd;};const _0x2c28db=a830_0x3c50;'use strict';const util=require(_0x2c28db('0xd')),_=require('lodash'),fs=require('fs'),squel=require('squel'),Papa=require(_0x2c28db('0xa')),moment=require(_0x2c28db('0x3a')),db=require('../../../mysqldb')['db'],logger=require(_0x2c28db('0x53'))('api'),{getSocket}=require(_0x2c28db('0x16')),socket=getSocket();require(_0x2c28db('0x48'))['register'](socket);let FILEPATH,FIELDS,LISTID,COMPANYID,DUPLICATES,SOCKET_TIMESTAMP;try{if(!process['argv'][0x2]||process['argv'][0x2]===_0x2c28db('0x1a')||process[_0x2c28db('0x13')][0x2]===_0x2c28db('0x5d'))throw new Error(_0x2c28db('0x50'));FILEPATH=process[_0x2c28db('0x13')][0x2];if(!process['argv'][0x3]||process[_0x2c28db('0x13')][0x3]===_0x2c28db('0x1a')||process[_0x2c28db('0x13')][0x3]===_0x2c28db('0x5d')||!process[_0x2c28db('0x13')][0x4]||process[_0x2c28db('0x13')][0x4]==='undefined'||process[_0x2c28db('0x13')][0x4]===_0x2c28db('0x5d'))throw new Error('Missing\x20binding\x20parameters!');FIELDS=_[_0x2c28db('0x57')](process['argv'][0x3]['split'](','),process[_0x2c28db('0x13')][0x4]['split'](','));if(!process[_0x2c28db('0x13')][0x5]||process[_0x2c28db('0x13')][0x5]===_0x2c28db('0x1a')||process[_0x2c28db('0x13')][0x5]==='null')throw new Error(_0x2c28db('0x46'));LISTID=process[_0x2c28db('0x13')][0x5],COMPANYID=process[_0x2c28db('0x13')][0x6]&&process[_0x2c28db('0x13')][0x6]!==_0x2c28db('0x1a')&&process[_0x2c28db('0x13')][0x6]!==_0x2c28db('0x5d')?process[_0x2c28db('0x13')][0x6]:null,DUPLICATES=process['argv'][0x7]&&process['argv'][0x7]!=='undefined'&&process[_0x2c28db('0x13')][0x7]!==_0x2c28db('0x5d')?process[_0x2c28db('0x13')][0x7]:null;if(!process[_0x2c28db('0x13')][0x8]||process['argv'][0x8]==='undefined'||process['argv'][0x8]===_0x2c28db('0x5d'))throw new Error(_0x2c28db('0x3c'));SOCKET_TIMESTAMP=process[_0x2c28db('0x13')][0x8];}catch(a830_0x23123d){logger['error'](a830_0x23123d),endCsv();}let total=0x0,success=0x0,errors=0x0,duplicates=0x0,rows=[],hopperContacts='',promises=[];function handleCheckRowError(_0x57b338,_0x4b3764,_0x107f5d,_0x4f7f27){const _0x6dd58c=_0x2c28db,_0xf4280a={'message':_0x4b3764};return _0xf4280a[_0x57b338]=!![],_0x107f5d&&(_0xf4280a[_0x6dd58c('0x8')]=_0x107f5d),_0x4f7f27&&(_0xf4280a['index']=_0x4f7f27),_0xf4280a;}function isEmail(_0x317eb4){const _0x1c544b=_0x2c28db;return/^([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x22([^\x0d\x22\x5c\x80-\xff]|\x5c[\x00-\x7f])*\x22)(\x2e([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x22([^\x0d\x22\x5c\x80-\xff]|\x5c[\x00-\x7f])*\x22))*\x40([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x5b([^\x0d\x5b-\x5d\x80-\xff]|\x5c[\x00-\x7f])*\x5d)(\x2e([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x5b([^\x0d\x5b-\x5d\x80-\xff]|\x5c[\x00-\x7f])*\x5d))*$/[_0x1c544b('0x5a')](_0x317eb4);}function checkRow(_0x56e1a6,_0x118259,_0x31acc6){return new Promise(function(_0x33a8b5,_0x2e7950){const _0x7b3eac=a830_0x3c50;if(_['isNil'](_0x56e1a6))return _0x2e7950(handleCheckRowError(_0x7b3eac('0x4'),_0x7b3eac('0x5b'),null,_0x31acc6));if(_0x56e1a6['errors']&&_0x56e1a6[_0x7b3eac('0xc')][_0x7b3eac('0x10')]){const _0x24add4=_['map'](_0x56e1a6['errors'],_0x7b3eac('0xf'))['join'](';');return _0x2e7950(handleCheckRowError(_0x7b3eac('0x4'),_0x24add4,null,_0x31acc6));}const _0xa180c6={};for(const _0x4a0c93 in FIELDS){typeof FIELDS[_0x4a0c93]!==_0x7b3eac('0x1a')&&FIELDS[_0x4a0c93]&&(_0xa180c6[_0x4a0c93]=_0x56e1a6['data'][0x0][FIELDS[_0x4a0c93]]||_0x56e1a6[_0x7b3eac('0x33')][0x0]['\ufeff'+FIELDS[_0x4a0c93]]);}if(!_0xa180c6[_0x7b3eac('0x1f')])return _0x2e7950(handleCheckRowError(_0x7b3eac('0x4'),_0x7b3eac('0x54'),null,_0x31acc6));if(!_0xa180c6['phone'])return _0x2e7950(handleCheckRowError(_0x7b3eac('0x4'),_0x7b3eac('0xb'),null,_0x31acc6));if(_0xa180c6['birthDate']){const _0x22a891=moment(_0xa180c6['birthDate'],'YYYY-MM-DD');if(!_0x22a891['isValid']())return _0x2e7950(handleCheckRowError('error',_0x7b3eac('0x17'),null,_0x31acc6));}if(_0xa180c6[_0x7b3eac('0x36')]){if(!isEmail(_0xa180c6[_0x7b3eac('0x36')]))return _0x2e7950(handleCheckRowError('error',_0x7b3eac('0x28'),null,_0x31acc6));}_0xa180c6[_0x7b3eac('0x3f')]=LISTID,_0xa180c6['CompanyId']=COMPANYID||undefined;if(DUPLICATES&&DUPLICATES[_0x7b3eac('0x10')]&&_0x118259){const _0x599963={};for(let _0x51b196=0x0,_0x4919b0=DUPLICATES[_0x7b3eac('0x10')];_0x51b196<_0x4919b0;_0x51b196+=0x1){_0x599963[DUPLICATES[_0x51b196]]=_0xa180c6[DUPLICATES[_0x51b196]];}const _0x182437=_['find'](_0x118259,_0x599963);if(_0x182437)return _0x2e7950(handleCheckRowError(_0x7b3eac('0x1c'),'Duplicate\x20Contact',_0x182437,_0x31acc6));}return db[_0x7b3eac('0x6')][_0x7b3eac('0x26')](_0xa180c6,{'raw':!![],'hooks':![],'fields':_[_0x7b3eac('0x32')](_0xa180c6)})['then'](function(_0x425604){const _0x5e3600=_0x7b3eac;return DUPLICATES&&DUPLICATES[_0x5e3600('0x10')]&&_0x118259&&_0x118259[_0x5e3600('0x30')](_[_0x5e3600('0x24')](_0xa180c6,DUPLICATES)),hopperContacts+=(hopperContacts?',':'')+_0x425604['id'],_0x33a8b5();})[_0x7b3eac('0x47')](function(_0x45bf42){const _0x5ce62c=_0x7b3eac;return _0x2e7950(handleCheckRowError(_0x5ce62c('0x4'),_0x5ce62c('0x7')+(_0x45bf42[_0x5ce62c('0xf')]||JSON[_0x5ce62c('0x61')](_0x45bf42)),null,_0x31acc6));});});}function checkHopper(){const _0x2581d8=_0x2c28db;function _0x3b81e3(){return function(_0x30f0b4){const _0x561244=a830_0x3c50;logger['error'](_0x561244('0x52'),'checkHopper',util[_0x561244('0x0')](_0x30f0b4,{'showHidden':![],'depth':null}));};}const _0x1c7dd7=function(_0x1c199e,_0x5022b6){const _0x46bf4d=a830_0x3c50,_0x13c940=squel[_0x46bf4d('0x14')]()[_0x46bf4d('0x60')](_0x46bf4d('0x22'))[_0x46bf4d('0x18')]([_0x46bf4d('0x11'),_0x46bf4d('0x2b'),_0x46bf4d('0x44'),_0x46bf4d('0x3f'),_0x5022b6,_0x46bf4d('0x39'),'updatedAt'],squel[_0x46bf4d('0x62')]()[_0x46bf4d('0x4e')]('phone',_0x46bf4d('0x11'))[_0x46bf4d('0x4e')](_0x46bf4d('0x42'),_0x46bf4d('0x2b'))[_0x46bf4d('0x4e')]('id','ContactId')[_0x46bf4d('0x4e')](LISTID[_0x46bf4d('0x41')](),'ListId')[_0x46bf4d('0x4e')](_0x1c199e['id']['toString'](),_0x5022b6)['field'](_0x46bf4d('0x42'),_0x46bf4d('0x39'))[_0x46bf4d('0x4e')]('NOW()','updatedAt')[_0x46bf4d('0x3d')](_0x46bf4d('0x55'))['where'](_0x46bf4d('0x4c'))['where']('ListId\x20=\x20?',LISTID['toString']())['where'](_0x46bf4d('0x4b'))[_0x46bf4d('0x5f')](_0x46bf4d('0x59'),squel[_0x46bf4d('0x62')]()['field'](_0x46bf4d('0x11'))['from'](_0x46bf4d('0x22'))[_0x46bf4d('0x5f')](_0x5022b6+_0x46bf4d('0x49'),_0x1c199e['id'][_0x46bf4d('0x41')]())))[_0x46bf4d('0x41')]();return _0x13c940;},_0x33f5c9=function(_0x5b054c,_0x917923){const _0x28ff5f=a830_0x3c50,_0xabbcce=squel[_0x28ff5f('0x14')]()['into'](_0x28ff5f('0x22'))[_0x28ff5f('0x18')]([_0x28ff5f('0x11'),'scheduledAt',_0x28ff5f('0x44'),_0x28ff5f('0x3f'),_0x917923,_0x28ff5f('0x39'),_0x28ff5f('0x1d')],squel[_0x28ff5f('0x62')]()[_0x28ff5f('0x4e')](_0x28ff5f('0x11'),_0x28ff5f('0x11'))[_0x28ff5f('0x4e')]('NOW()',_0x28ff5f('0x2b'))[_0x28ff5f('0x4e')]('id',_0x28ff5f('0x44'))[_0x28ff5f('0x4e')](LISTID[_0x28ff5f('0x41')](),'ListId')[_0x28ff5f('0x4e')](_0x5b054c['id'][_0x28ff5f('0x41')](),_0x917923)[_0x28ff5f('0x4e')](_0x28ff5f('0x42'),'createdAt')[_0x28ff5f('0x4e')](_0x28ff5f('0x42'),_0x28ff5f('0x1d'))['from']('cm_contacts')[_0x28ff5f('0x5f')]('deletedAt\x20IS\x20NULL')[_0x28ff5f('0x5f')](_0x28ff5f('0x20'),LISTID['toString']())[_0x28ff5f('0x5f')]('id\x20IN\x20?',squel[_0x28ff5f('0x5e')](hopperContacts))[_0x28ff5f('0x5f')](_0x28ff5f('0x4b'))[_0x28ff5f('0x5f')](_0x28ff5f('0x59'),squel[_0x28ff5f('0x62')]()[_0x28ff5f('0x4e')](_0x28ff5f('0x58'))['from']('cm_hopper_final')[_0x28ff5f('0x5f')](_0x917923+'\x20=\x20?',_0x5b054c['id'][_0x28ff5f('0x41')]()))['where']('phone\x20NOT\x20IN\x20(?)',squel[_0x28ff5f('0x62')]()[_0x28ff5f('0x4e')](_0x28ff5f('0x11'))['from'](_0x28ff5f('0x22'))[_0x28ff5f('0x5f')](_0x917923+_0x28ff5f('0x49'),_0x5b054c['id'][_0x28ff5f('0x41')]())))['toString']();return _0xabbcce;};function _0x19901c(_0x4535c6,_0x202831){const _0x45d2ab=a830_0x3c50,_0x6595b5=squel[_0x45d2ab('0x14')]()['into'](_0x45d2ab('0x22'))[_0x45d2ab('0x18')]([_0x45d2ab('0x11'),_0x45d2ab('0x2b'),'ContactId',_0x45d2ab('0x3f'),_0x202831,'createdAt','updatedAt'],squel[_0x45d2ab('0x62')]()[_0x45d2ab('0x4e')](_0x45d2ab('0x11'),_0x45d2ab('0x11'))['field'](_0x45d2ab('0x42'),_0x45d2ab('0x2b'))['field']('id','ContactId')['field'](LISTID[_0x45d2ab('0x41')](),_0x45d2ab('0x3f'))[_0x45d2ab('0x4e')](_0x4535c6['id'][_0x45d2ab('0x41')](),_0x202831)[_0x45d2ab('0x4e')]('NOW()',_0x45d2ab('0x39'))[_0x45d2ab('0x4e')](_0x45d2ab('0x42'),_0x45d2ab('0x1d'))['from'](_0x45d2ab('0x55'))[_0x45d2ab('0x5f')](_0x45d2ab('0x4c'))[_0x45d2ab('0x5f')](_0x45d2ab('0x20'),LISTID[_0x45d2ab('0x41')]())[_0x45d2ab('0x5f')](_0x45d2ab('0x1b'),squel[_0x45d2ab('0x5e')](hopperContacts))['where'](_0x45d2ab('0x4b')))['toString']();return _0x6595b5;}function _0x4d72cf(_0x1904fe,_0x1b38d9){const _0x2210c6=a830_0x3c50,_0x42fb2d=squel[_0x2210c6('0x14')]()['into'](_0x2210c6('0x19'))[_0x2210c6('0x18')](['phone','ContactId',_0x2210c6('0x3f'),_0x1b38d9,_0x2210c6('0x39'),_0x2210c6('0x1d')],squel[_0x2210c6('0x62')]()[_0x2210c6('0x4e')](_0x2210c6('0x11'),_0x2210c6('0x11'))[_0x2210c6('0x4e')]('id',_0x2210c6('0x44'))[_0x2210c6('0x4e')](LISTID[_0x2210c6('0x41')](),_0x2210c6('0x3f'))[_0x2210c6('0x4e')](_0x1904fe['id'][_0x2210c6('0x41')](),_0x1b38d9)[_0x2210c6('0x4e')](_0x2210c6('0x42'),_0x2210c6('0x39'))[_0x2210c6('0x4e')]('NOW()','updatedAt')[_0x2210c6('0x3d')](_0x2210c6('0x55'))[_0x2210c6('0x5f')](_0x2210c6('0x4c'))[_0x2210c6('0x5f')](_0x2210c6('0x20'),LISTID[_0x2210c6('0x41')]())[_0x2210c6('0x5f')](_0x2210c6('0x1b'),squel[_0x2210c6('0x5e')](hopperContacts))[_0x2210c6('0x5f')](_0x2210c6('0x4b')))[_0x2210c6('0x41')]();return _0x42fb2d;}return db[_0x2581d8('0x2')][_0x2581d8('0x1')]({'where':{'type':_0x2581d8('0x3')},'attributes':['id',_0x2581d8('0x15')],'include':[{'model':db[_0x2581d8('0x2d')],'as':_0x2581d8('0x35'),'where':{'id':LISTID}}]})[_0x2581d8('0x5')](function(_0x300e43){const _0x581f15=_0x2581d8,_0x4e9619=[];if(_0x300e43)for(let _0x25b48b=0x0,_0x8e5f8a;_0x25b48b<_0x300e43[_0x581f15('0x10')];_0x25b48b+=0x1){_0x8e5f8a=_0x300e43[_0x25b48b][_0x581f15('0x31')]({'plain':!![]});switch(_0x8e5f8a[_0x581f15('0x15')]){case _0x581f15('0x38'):_0x4e9619[_0x581f15('0x30')](db['sequelize']['query'](_0x33f5c9(_0x8e5f8a,_0x581f15('0x56')))['then'](function(){})[_0x581f15('0x47')](_0x3b81e3()));break;case _0x581f15('0xe'):_0x4e9619[_0x581f15('0x30')](db['sequelize'][_0x581f15('0x3b')](_0x1c7dd7(_0x8e5f8a,'VoiceQueueId'))['then'](function(){})[_0x581f15('0x47')](_0x3b81e3()));break;default:_0x4e9619[_0x581f15('0x30')](db[_0x581f15('0x23')][_0x581f15('0x3b')](_0x19901c(_0x8e5f8a,_0x581f15('0x56')))[_0x581f15('0x5')](function(){})[_0x581f15('0x47')](_0x3b81e3()));}}return _0x4e9619;})['all']()['then'](function(){const _0x5ceb58=_0x2581d8;return db[_0x5ceb58('0x2')][_0x5ceb58('0x1')]({'where':{'type':_0x5ceb58('0x3')},'attributes':['id'],'include':[{'model':db[_0x5ceb58('0x2d')],'as':_0x5ceb58('0x25'),'where':{'id':LISTID}}]})[_0x5ceb58('0x5')](function(_0x39f961){const _0x4b81f1=_0x5ceb58,_0x4b0ae6=[];if(_0x39f961)for(let _0x4642a3=0x0,_0x194a6e;_0x4642a3<_0x39f961[_0x4b81f1('0x10')];_0x4642a3+=0x1){_0x194a6e=_0x39f961[_0x4642a3][_0x4b81f1('0x31')]({'plain':!![]}),_0x4b0ae6[_0x4b81f1('0x30')](db['sequelize']['query'](_0x4d72cf(_0x194a6e,_0x4b81f1('0x56')))['then'](function(){})[_0x4b81f1('0x47')](_0x3b81e3()));}return _0x4b0ae6;})[_0x5ceb58('0x12')]();})[_0x2581d8('0x5')](function(){const _0x38c593=_0x2581d8;return db['Campaign'][_0x38c593('0x1')]({'attributes':['id',_0x38c593('0x15')],'include':[{'model':db[_0x38c593('0x2d')],'as':_0x38c593('0x35'),'where':{'id':LISTID}}]})[_0x38c593('0x5')](function(_0x20dceb){const _0x2ba9e2=_0x38c593,_0x35a71c=[];if(_0x20dceb)for(let _0x3a69cb=0x0,_0x364e69;_0x3a69cb<_0x20dceb[_0x2ba9e2('0x10')];_0x3a69cb+=0x1){_0x364e69=_0x20dceb[_0x3a69cb]['get']({'plain':!![]});switch(_0x364e69[_0x2ba9e2('0x15')]){case _0x2ba9e2('0x38'):_0x35a71c[_0x2ba9e2('0x30')](db[_0x2ba9e2('0x23')][_0x2ba9e2('0x3b')](_0x33f5c9(_0x364e69,_0x2ba9e2('0x3e')))[_0x2ba9e2('0x5')](function(){})[_0x2ba9e2('0x47')](_0x3b81e3()));break;case _0x2ba9e2('0xe'):_0x35a71c[_0x2ba9e2('0x30')](db['sequelize'][_0x2ba9e2('0x3b')](_0x1c7dd7(_0x364e69,_0x2ba9e2('0x3e')))[_0x2ba9e2('0x5')](function(){})[_0x2ba9e2('0x47')](_0x3b81e3()));break;default:_0x35a71c[_0x2ba9e2('0x30')](db['sequelize'][_0x2ba9e2('0x3b')](_0x19901c(_0x364e69,_0x2ba9e2('0x3e')))[_0x2ba9e2('0x5')](function(){})['catch'](_0x3b81e3()));}}return _0x35a71c;})[_0x38c593('0x12')]();})[_0x2581d8('0x5')](function(){const _0x150dec=_0x2581d8;return db['Campaign']['findAll']({'attributes':['id'],'include':[{'model':db[_0x150dec('0x2d')],'as':_0x150dec('0x25'),'where':{'id':LISTID}}]})[_0x150dec('0x5')](function(_0x51c90c){const _0x4d6a1c=_0x150dec,_0x30331e=[];if(_0x51c90c)for(let _0x1a62ba=0x0,_0x4a7c60;_0x1a62ba<_0x51c90c['length'];_0x1a62ba+=0x1){_0x4a7c60=_0x51c90c[_0x1a62ba][_0x4d6a1c('0x31')]({'plain':!![]}),_0x30331e[_0x4d6a1c('0x30')](db[_0x4d6a1c('0x23')]['query'](_0x4d72cf(_0x4a7c60,_0x4d6a1c('0x3e')))[_0x4d6a1c('0x5')](function(){})[_0x4d6a1c('0x47')](_0x3b81e3()));}return _0x30331e;})[_0x150dec('0x12')]();})[_0x2581d8('0x47')](function(_0x37a5b0){const _0x191387=_0x2581d8;logger[_0x191387('0x4')]('cmContact,\x20%s,\x20%s','generalCheckHopper',_0x37a5b0[_0x191387('0xf')]);});}const processPromises=function(_0x611e9c){const _0x151093=_0x2c28db;return Promise[_0x151093('0x12')](promises)[_0x151093('0x47')](function(_0x2600f6){const _0x1e2f9c=_0x151093;logger['error'](_0x1e2f9c('0x43'),JSON[_0x1e2f9c('0x61')](_0x2600f6));})[_0x151093('0x2e')](function(){const _0x25d126=_0x151093;socket[_0x25d126('0x4a')]('contact:csv_'+SOCKET_TIMESTAMP,{'success':success,'errors':errors,'duplicates':duplicates,'rows':rows}),promises=[],success=0x0,errors=0x0,duplicates=0x0,rows=[];if(_0x611e9c)return _0x611e9c[_0x25d126('0x21')]();});},endCsv=function(){const _0x33c199=_0x2c28db;return Promise['resolve']()[_0x33c199('0x5')](function(){if(hopperContacts)return checkHopper();})[_0x33c199('0x5')](function(){const _0x58deb6=_0x33c199;socket[_0x58deb6('0x4a')](_0x58deb6('0x51')+SOCKET_TIMESTAMP,{'finished':!![],'success':success,'errors':errors,'duplicates':duplicates,'rows':rows});try{fs[_0x58deb6('0x5c')](FILEPATH);}catch(_0x5252a9){logger['error'](_0x58deb6('0x2f'),JSON[_0x58deb6('0x61')](_0x5252a9));}finally{process[_0x58deb6('0x29')](0x0);}});};process['on'](_0x2c28db('0x37'),function(){const _0x3b2807=_0x2c28db;logger[_0x3b2807('0x2a')](_0x3b2807('0x4d')),endCsv();});function main(){const _0x3e3ca2=_0x2c28db;return Promise[_0x3e3ca2('0x2c')]()['then'](function(){const _0x515d09=_0x3e3ca2;if(DUPLICATES)return DUPLICATES=DUPLICATES[_0x515d09('0x45')](','),db[_0x515d09('0x6')][_0x515d09('0x1')]({'where':{'ListId':LISTID},'attributes':DUPLICATES,'raw':!![]});})[_0x3e3ca2('0x5')](function(_0x64f1f4){const _0x1ad289=_0x3e3ca2,_0x549686=fs[_0x1ad289('0x34')](FILEPATH,{'highWaterMark':0xf*0x400*0x400});Papa[_0x1ad289('0x40')](_0x549686,{'header':!![],'skipEmptyLines':!![],'step':function(_0x28f3b3,_0x4335ec){const _0xe43695=_0x1ad289;total+=0x1;const _0x19fc77=total;promises[_0xe43695('0x30')](checkRow(_0x28f3b3,_0x64f1f4,_0x19fc77)[_0xe43695('0x5')](function(){success+=0x1;})[_0xe43695('0x47')](function(_0x2ed3d4){const _0x54a592=_0xe43695;if(_0x2ed3d4[_0x54a592('0x4')])errors+=0x1,delete _0x2ed3d4[_0x54a592('0x4')];else _0x2ed3d4[_0x54a592('0x1c')]&&(duplicates+=0x1,delete _0x2ed3d4[_0x54a592('0x1c')]);rows[_0x54a592('0x30')](_0x2ed3d4);}));if(total%0xc8===0x0)return _0x4335ec[_0xe43695('0x4f')](),processPromises(_0x4335ec);},'complete':function(){const _0x52e411=_0x1ad289;return processPromises()[_0x52e411('0x5')](function(){const _0x3d2a2b=_0x52e411;logger[_0x3d2a2b('0x2a')](_0x3d2a2b('0x9')),endCsv();});},'error':function(_0x2cd5e7){const _0x1e5ee1=_0x1ad289;logger['info'](_0x1e5ee1('0x1e'),JSON[_0x1e5ee1('0x61')](_0x2cd5e7)),endCsv();}});})[_0x3e3ca2('0x47')](function(_0x119d5c){const _0x967f52=_0x3e3ca2;logger[_0x967f52('0x4')](_0x967f52('0x27'),JSON[_0x967f52('0x61')](_0x119d5c));});}main(); \ No newline at end of file +const a830_0x4a2d=['onlyIfOpen','resolve','exit','inspect','catch','where','split','CmList','Missing\x20ListId\x20parameter!','SIGINT','util','papaparse','cm_hopper','phone','then','NOW()','phone\x20NOT\x20IN\x20(?)','toString','zipObject','duplicate','always','from','info','../../../config/logger','cmContact,\x20%s,\x20%s','lodash','str','test','pause','length','undefined','find','createReadStream','emit','index','errors','cm_contacts','argv','null','updatedAt','deletedAt\x20IS\x20NULL','error','insert','push','../../../mysqldb','phone\x20not\x20specified!','Missing\x20filepath\x20parameter!','email','unlinkSync','contact:csv_','findAll','dialCheckDuplicateType','join','../../../rediscache','ListId\x20=\x20?','get','checkHopper','phone\x20IS\x20NOT\x20NULL','VoiceQueue','Missing\x20socket_timestamp\x20parameter!','scheduledAt','CmContact','query','CSV\x20import\x20process\x20stopped!','The\x20row\x20is\x20empty\x20or\x20the\x20number\x20of\x20parameters\x20does\x20not\x20match\x20the\x20columns!','\x20=\x20?','isNil','Missing\x20binding\x20parameters!','into','field','calleridnum','YYYY-MM-DD','resume','VoiceQueueId','finally','CampaignId','birthDate','create','all','Campaign','map','select','message','Error\x20while\x20creating\x20contact:\x20','ContactId','BlackLists','api','sequelize','email\x20format\x20is\x20not\x20valid!','id\x20IN\x20?','Lists','parse','generalCheckHopper','firstName','stringify','data','createdAt','fromQuery','CSV\x20parsed\x20correctly!','squel','ListId','firstName\x20not\x20specified!','Error\x20processing\x20rows\x20block:','register'];(function(_0x1d42c7,_0x4a2dd3){const _0x318714=function(_0x40a29c){while(--_0x40a29c){_0x1d42c7['push'](_0x1d42c7['shift']());}};_0x318714(++_0x4a2dd3);}(a830_0x4a2d,0x133));const a830_0x3187=function(_0x1d42c7,_0x4a2dd3){_0x1d42c7=_0x1d42c7-0x0;let _0x318714=a830_0x4a2d[_0x1d42c7];return _0x318714;};const _0x2b549f=a830_0x3187;'use strict';const util=require(_0x2b549f('0xf')),_=require(_0x2b549f('0x1e')),fs=require('fs'),squel=require(_0x2b549f('0x0')),Papa=require(_0x2b549f('0x10')),moment=require('moment'),db=require(_0x2b549f('0x31'))['db'],logger=require(_0x2b549f('0x1c'))(_0x2b549f('0x5b')),{getSocket}=require(_0x2b549f('0x3a')),socket=getSocket();require('../../../api/cmContact/cmContact.socket')[_0x2b549f('0x4')](socket);let FILEPATH,FIELDS,LISTID,COMPANYID,DUPLICATES,SOCKET_TIMESTAMP;try{if(!process[_0x2b549f('0x2a')][0x2]||process[_0x2b549f('0x2a')][0x2]===_0x2b549f('0x23')||process[_0x2b549f('0x2a')][0x2]===_0x2b549f('0x2b'))throw new Error(_0x2b549f('0x33'));FILEPATH=process[_0x2b549f('0x2a')][0x2];if(!process[_0x2b549f('0x2a')][0x3]||process[_0x2b549f('0x2a')][0x3]==='undefined'||process[_0x2b549f('0x2a')][0x3]==='null'||!process['argv'][0x4]||process[_0x2b549f('0x2a')][0x4]===_0x2b549f('0x23')||process['argv'][0x4]===_0x2b549f('0x2b'))throw new Error(_0x2b549f('0x48'));FIELDS=_[_0x2b549f('0x17')](process[_0x2b549f('0x2a')][0x3]['split'](','),process[_0x2b549f('0x2a')][0x4][_0x2b549f('0xb')](','));if(!process[_0x2b549f('0x2a')][0x5]||process[_0x2b549f('0x2a')][0x5]===_0x2b549f('0x23')||process[_0x2b549f('0x2a')][0x5]===_0x2b549f('0x2b'))throw new Error(_0x2b549f('0xd'));LISTID=process['argv'][0x5],COMPANYID=process[_0x2b549f('0x2a')][0x6]&&process[_0x2b549f('0x2a')][0x6]!=='undefined'&&process[_0x2b549f('0x2a')][0x6]!=='null'?process[_0x2b549f('0x2a')][0x6]:null,DUPLICATES=process[_0x2b549f('0x2a')][0x7]&&process[_0x2b549f('0x2a')][0x7]!=='undefined'&&process[_0x2b549f('0x2a')][0x7]!=='null'?process[_0x2b549f('0x2a')][0x7]:null;if(!process[_0x2b549f('0x2a')][0x8]||process['argv'][0x8]===_0x2b549f('0x23')||process['argv'][0x8]==='null')throw new Error(_0x2b549f('0x40'));SOCKET_TIMESTAMP=process[_0x2b549f('0x2a')][0x8];}catch(a830_0x40a29c){logger[_0x2b549f('0x2e')](a830_0x40a29c),endCsv();}let total=0x0,success=0x0,errors=0x0,duplicates=0x0,rows=[],hopperContacts='',promises=[];function handleCheckRowError(_0x4b1296,_0x5e6ba3,_0x50a395,_0x31ca78){const _0x34c19b=_0x2b549f,_0x4d1262={'message':_0x5e6ba3};return _0x4d1262[_0x4b1296]=!![],_0x50a395&&(_0x4d1262['contact']=_0x50a395),_0x31ca78&&(_0x4d1262[_0x34c19b('0x27')]=_0x31ca78),_0x4d1262;}function isEmail(_0x581c53){const _0x1f37e8=_0x2b549f;return/^([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x22([^\x0d\x22\x5c\x80-\xff]|\x5c[\x00-\x7f])*\x22)(\x2e([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x22([^\x0d\x22\x5c\x80-\xff]|\x5c[\x00-\x7f])*\x22))*\x40([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x5b([^\x0d\x5b-\x5d\x80-\xff]|\x5c[\x00-\x7f])*\x5d)(\x2e([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x5b([^\x0d\x5b-\x5d\x80-\xff]|\x5c[\x00-\x7f])*\x5d))*$/[_0x1f37e8('0x20')](_0x581c53);}function checkRow(_0x386f00,_0x45362c,_0xff7a2d){return new Promise(function(_0x48b3ba,_0x1ab5cf){const _0x57bc87=a830_0x3187;if(_[_0x57bc87('0x47')](_0x386f00))return _0x1ab5cf(handleCheckRowError('error',_0x57bc87('0x45'),null,_0xff7a2d));if(_0x386f00[_0x57bc87('0x28')]&&_0x386f00['errors'][_0x57bc87('0x22')]){const _0x1a1eea=_[_0x57bc87('0x55')](_0x386f00[_0x57bc87('0x28')],_0x57bc87('0x57'))[_0x57bc87('0x39')](';');return _0x1ab5cf(handleCheckRowError(_0x57bc87('0x2e'),_0x1a1eea,null,_0xff7a2d));}const _0xa79e1f={};for(const _0x2e7ec5 in FIELDS){typeof FIELDS[_0x2e7ec5]!=='undefined'&&FIELDS[_0x2e7ec5]&&(_0xa79e1f[_0x2e7ec5]=_0x386f00[_0x57bc87('0x64')][0x0][FIELDS[_0x2e7ec5]]||_0x386f00[_0x57bc87('0x64')][0x0]['\ufeff'+FIELDS[_0x2e7ec5]]);}if(!_0xa79e1f[_0x57bc87('0x62')])return _0x1ab5cf(handleCheckRowError('error',_0x57bc87('0x2'),null,_0xff7a2d));if(!_0xa79e1f[_0x57bc87('0x12')])return _0x1ab5cf(handleCheckRowError(_0x57bc87('0x2e'),_0x57bc87('0x32'),null,_0xff7a2d));if(_0xa79e1f[_0x57bc87('0x51')]){const _0x5ebd51=moment(_0xa79e1f['birthDate'],_0x57bc87('0x4c'));if(!_0x5ebd51['isValid']())return _0x1ab5cf(handleCheckRowError('error','birthDate\x20format\x20is\x20invalid,\x20YYYY-MM-DD\x20format\x20is\x20supported!',null,_0xff7a2d));}if(_0xa79e1f[_0x57bc87('0x34')]){if(!isEmail(_0xa79e1f['email']))return _0x1ab5cf(handleCheckRowError(_0x57bc87('0x2e'),_0x57bc87('0x5d'),null,_0xff7a2d));}_0xa79e1f[_0x57bc87('0x1')]=LISTID,_0xa79e1f['CompanyId']=COMPANYID||undefined;if(DUPLICATES&&DUPLICATES['length']&&_0x45362c){const _0x2a9558={};for(let _0x5c1cbe=0x0,_0x27dad4=DUPLICATES[_0x57bc87('0x22')];_0x5c1cbe<_0x27dad4;_0x5c1cbe+=0x1){_0x2a9558[DUPLICATES[_0x5c1cbe]]=_0xa79e1f[DUPLICATES[_0x5c1cbe]];}const _0x29415f=_[_0x57bc87('0x24')](_0x45362c,_0x2a9558);if(_0x29415f)return _0x1ab5cf(handleCheckRowError('duplicate','Duplicate\x20Contact',_0x29415f,_0xff7a2d));}return db[_0x57bc87('0x42')][_0x57bc87('0x52')](_0xa79e1f,{'raw':!![],'hooks':![],'fields':_['keys'](_0xa79e1f)})[_0x57bc87('0x13')](function(_0x37b24c){const _0x34d462=_0x57bc87;return DUPLICATES&&DUPLICATES[_0x34d462('0x22')]&&_0x45362c&&_0x45362c[_0x34d462('0x30')](_['pick'](_0xa79e1f,DUPLICATES)),hopperContacts+=(hopperContacts?',':'')+_0x37b24c['id'],_0x48b3ba();})[_0x57bc87('0x9')](function(_0x1d516c){const _0x56e03a=_0x57bc87;return _0x1ab5cf(handleCheckRowError('error',_0x56e03a('0x58')+(_0x1d516c['message']||JSON[_0x56e03a('0x63')](_0x1d516c)),null,_0xff7a2d));});});}function checkHopper(){const _0xaf402d=_0x2b549f;function _0x51eddd(){return function(_0x2e1e6c){const _0x130e6e=a830_0x3187;logger[_0x130e6e('0x2e')]('cmContact',_0x130e6e('0x3d'),util[_0x130e6e('0x8')](_0x2e1e6c,{'showHidden':![],'depth':null}));};}const _0x16b030=function(_0x58eb21,_0x2bc1a7){const _0xe5d6dd=a830_0x3187,_0x1fe9c2=squel['insert']()[_0xe5d6dd('0x49')]('cm_hopper')[_0xe5d6dd('0x66')]([_0xe5d6dd('0x12'),_0xe5d6dd('0x41'),'ContactId',_0xe5d6dd('0x1'),_0x2bc1a7,_0xe5d6dd('0x65'),_0xe5d6dd('0x2c')],squel['select']()['field']('phone',_0xe5d6dd('0x12'))['field'](_0xe5d6dd('0x14'),_0xe5d6dd('0x41'))[_0xe5d6dd('0x4a')]('id','ContactId')[_0xe5d6dd('0x4a')](LISTID[_0xe5d6dd('0x16')](),_0xe5d6dd('0x1'))['field'](_0x58eb21['id'][_0xe5d6dd('0x16')](),_0x2bc1a7)[_0xe5d6dd('0x4a')](_0xe5d6dd('0x14'),_0xe5d6dd('0x65'))[_0xe5d6dd('0x4a')](_0xe5d6dd('0x14'),'updatedAt')[_0xe5d6dd('0x1a')](_0xe5d6dd('0x29'))[_0xe5d6dd('0xa')]('deletedAt\x20IS\x20NULL')[_0xe5d6dd('0xa')](_0xe5d6dd('0x3b'),LISTID[_0xe5d6dd('0x16')]())['where'](_0xe5d6dd('0x3e'))[_0xe5d6dd('0xa')](_0xe5d6dd('0x15'),squel['select']()[_0xe5d6dd('0x4a')]('phone')[_0xe5d6dd('0x1a')](_0xe5d6dd('0x11'))['where'](_0x2bc1a7+_0xe5d6dd('0x46'),_0x58eb21['id'][_0xe5d6dd('0x16')]())))[_0xe5d6dd('0x16')]();return _0x1fe9c2;},_0x27b4fd=function(_0x3deeb2,_0x3c55e9){const _0x50aebe=a830_0x3187,_0x565f2a=squel[_0x50aebe('0x2f')]()['into'](_0x50aebe('0x11'))[_0x50aebe('0x66')](['phone','scheduledAt',_0x50aebe('0x59'),'ListId',_0x3c55e9,_0x50aebe('0x65'),_0x50aebe('0x2c')],squel['select']()[_0x50aebe('0x4a')](_0x50aebe('0x12'),_0x50aebe('0x12'))[_0x50aebe('0x4a')]('NOW()',_0x50aebe('0x41'))[_0x50aebe('0x4a')]('id',_0x50aebe('0x59'))[_0x50aebe('0x4a')](LISTID[_0x50aebe('0x16')](),_0x50aebe('0x1'))[_0x50aebe('0x4a')](_0x3deeb2['id'][_0x50aebe('0x16')](),_0x3c55e9)[_0x50aebe('0x4a')](_0x50aebe('0x14'),'createdAt')[_0x50aebe('0x4a')]('NOW()','updatedAt')[_0x50aebe('0x1a')](_0x50aebe('0x29'))[_0x50aebe('0xa')]('deletedAt\x20IS\x20NULL')[_0x50aebe('0xa')](_0x50aebe('0x3b'),LISTID[_0x50aebe('0x16')]())[_0x50aebe('0xa')]('id\x20IN\x20?',squel['str'](hopperContacts))[_0x50aebe('0xa')](_0x50aebe('0x3e'))[_0x50aebe('0xa')](_0x50aebe('0x15'),squel[_0x50aebe('0x56')]()['field'](_0x50aebe('0x4b'))['from']('cm_hopper_final')[_0x50aebe('0xa')](_0x3c55e9+_0x50aebe('0x46'),_0x3deeb2['id'][_0x50aebe('0x16')]()))['where'](_0x50aebe('0x15'),squel[_0x50aebe('0x56')]()[_0x50aebe('0x4a')](_0x50aebe('0x12'))[_0x50aebe('0x1a')]('cm_hopper')[_0x50aebe('0xa')](_0x3c55e9+_0x50aebe('0x46'),_0x3deeb2['id'][_0x50aebe('0x16')]())))[_0x50aebe('0x16')]();return _0x565f2a;};function _0x30555b(_0x556d61,_0x1259d0){const _0x14c032=a830_0x3187,_0x78a3f6=squel['insert']()[_0x14c032('0x49')](_0x14c032('0x11'))['fromQuery'](['phone',_0x14c032('0x41'),_0x14c032('0x59'),_0x14c032('0x1'),_0x1259d0,_0x14c032('0x65'),'updatedAt'],squel[_0x14c032('0x56')]()[_0x14c032('0x4a')](_0x14c032('0x12'),_0x14c032('0x12'))[_0x14c032('0x4a')]('NOW()',_0x14c032('0x41'))[_0x14c032('0x4a')]('id',_0x14c032('0x59'))['field'](LISTID[_0x14c032('0x16')](),_0x14c032('0x1'))[_0x14c032('0x4a')](_0x556d61['id']['toString'](),_0x1259d0)[_0x14c032('0x4a')](_0x14c032('0x14'),_0x14c032('0x65'))[_0x14c032('0x4a')](_0x14c032('0x14'),_0x14c032('0x2c'))[_0x14c032('0x1a')](_0x14c032('0x29'))[_0x14c032('0xa')](_0x14c032('0x2d'))[_0x14c032('0xa')](_0x14c032('0x3b'),LISTID['toString']())[_0x14c032('0xa')](_0x14c032('0x5e'),squel[_0x14c032('0x1f')](hopperContacts))[_0x14c032('0xa')](_0x14c032('0x3e')))[_0x14c032('0x16')]();return _0x78a3f6;}function _0x1bc05f(_0x412f91,_0x12b1f2){const _0x43c73c=a830_0x3187,_0xa16424=squel[_0x43c73c('0x2f')]()[_0x43c73c('0x49')]('cm_hopper_black')[_0x43c73c('0x66')]([_0x43c73c('0x12'),_0x43c73c('0x59'),_0x43c73c('0x1'),_0x12b1f2,_0x43c73c('0x65'),'updatedAt'],squel[_0x43c73c('0x56')]()[_0x43c73c('0x4a')](_0x43c73c('0x12'),_0x43c73c('0x12'))['field']('id',_0x43c73c('0x59'))['field'](LISTID[_0x43c73c('0x16')](),_0x43c73c('0x1'))[_0x43c73c('0x4a')](_0x412f91['id'][_0x43c73c('0x16')](),_0x12b1f2)[_0x43c73c('0x4a')](_0x43c73c('0x14'),_0x43c73c('0x65'))['field'](_0x43c73c('0x14'),_0x43c73c('0x2c'))[_0x43c73c('0x1a')]('cm_contacts')['where'](_0x43c73c('0x2d'))[_0x43c73c('0xa')](_0x43c73c('0x3b'),LISTID[_0x43c73c('0x16')]())['where'](_0x43c73c('0x5e'),squel[_0x43c73c('0x1f')](hopperContacts))[_0x43c73c('0xa')](_0x43c73c('0x3e')))[_0x43c73c('0x16')]();return _0xa16424;}return db[_0xaf402d('0x3f')]['findAll']({'where':{'type':'outbound'},'attributes':['id',_0xaf402d('0x38')],'include':[{'model':db[_0xaf402d('0xc')],'as':_0xaf402d('0x5f'),'where':{'id':LISTID}}]})['then'](function(_0x9b749c){const _0x26f669=_0xaf402d,_0x4d1edf=[];if(_0x9b749c)for(let _0x182e76=0x0,_0x3aeedc;_0x182e76<_0x9b749c[_0x26f669('0x22')];_0x182e76+=0x1){_0x3aeedc=_0x9b749c[_0x182e76][_0x26f669('0x3c')]({'plain':!![]});switch(_0x3aeedc['dialCheckDuplicateType']){case _0x26f669('0x19'):_0x4d1edf['push'](db[_0x26f669('0x5c')][_0x26f669('0x43')](_0x27b4fd(_0x3aeedc,'VoiceQueueId'))[_0x26f669('0x13')](function(){})[_0x26f669('0x9')](_0x51eddd()));break;case _0x26f669('0x5'):_0x4d1edf['push'](db[_0x26f669('0x5c')][_0x26f669('0x43')](_0x16b030(_0x3aeedc,_0x26f669('0x4e')))[_0x26f669('0x13')](function(){})[_0x26f669('0x9')](_0x51eddd()));break;default:_0x4d1edf[_0x26f669('0x30')](db[_0x26f669('0x5c')][_0x26f669('0x43')](_0x30555b(_0x3aeedc,_0x26f669('0x4e')))['then'](function(){})[_0x26f669('0x9')](_0x51eddd()));}}return _0x4d1edf;})[_0xaf402d('0x53')]()['then'](function(){const _0x4620f7=_0xaf402d;return db[_0x4620f7('0x3f')][_0x4620f7('0x37')]({'where':{'type':'outbound'},'attributes':['id'],'include':[{'model':db['CmList'],'as':_0x4620f7('0x5a'),'where':{'id':LISTID}}]})[_0x4620f7('0x13')](function(_0x296fa9){const _0x1a0212=_0x4620f7,_0x4cfd05=[];if(_0x296fa9)for(let _0x303870=0x0,_0x12b0a2;_0x303870<_0x296fa9[_0x1a0212('0x22')];_0x303870+=0x1){_0x12b0a2=_0x296fa9[_0x303870][_0x1a0212('0x3c')]({'plain':!![]}),_0x4cfd05[_0x1a0212('0x30')](db[_0x1a0212('0x5c')][_0x1a0212('0x43')](_0x1bc05f(_0x12b0a2,_0x1a0212('0x4e')))[_0x1a0212('0x13')](function(){})['catch'](_0x51eddd()));}return _0x4cfd05;})[_0x4620f7('0x53')]();})[_0xaf402d('0x13')](function(){const _0x4c3925=_0xaf402d;return db[_0x4c3925('0x54')][_0x4c3925('0x37')]({'attributes':['id',_0x4c3925('0x38')],'include':[{'model':db[_0x4c3925('0xc')],'as':_0x4c3925('0x5f'),'where':{'id':LISTID}}]})[_0x4c3925('0x13')](function(_0x17fdc0){const _0x1cd737=_0x4c3925,_0x4ae0ed=[];if(_0x17fdc0)for(let _0xf2043=0x0,_0x254e55;_0xf2043<_0x17fdc0['length'];_0xf2043+=0x1){_0x254e55=_0x17fdc0[_0xf2043][_0x1cd737('0x3c')]({'plain':!![]});switch(_0x254e55[_0x1cd737('0x38')]){case _0x1cd737('0x19'):_0x4ae0ed['push'](db[_0x1cd737('0x5c')][_0x1cd737('0x43')](_0x27b4fd(_0x254e55,_0x1cd737('0x50')))[_0x1cd737('0x13')](function(){})['catch'](_0x51eddd()));break;case _0x1cd737('0x5'):_0x4ae0ed['push'](db[_0x1cd737('0x5c')]['query'](_0x16b030(_0x254e55,_0x1cd737('0x50')))[_0x1cd737('0x13')](function(){})[_0x1cd737('0x9')](_0x51eddd()));break;default:_0x4ae0ed['push'](db['sequelize'][_0x1cd737('0x43')](_0x30555b(_0x254e55,_0x1cd737('0x50')))['then'](function(){})[_0x1cd737('0x9')](_0x51eddd()));}}return _0x4ae0ed;})['all']();})['then'](function(){const _0x395091=_0xaf402d;return db[_0x395091('0x54')][_0x395091('0x37')]({'attributes':['id'],'include':[{'model':db[_0x395091('0xc')],'as':_0x395091('0x5a'),'where':{'id':LISTID}}]})[_0x395091('0x13')](function(_0x5af89c){const _0x307ff1=_0x395091,_0x4a5a62=[];if(_0x5af89c)for(let _0xdc0997=0x0,_0x91e42f;_0xdc0997<_0x5af89c['length'];_0xdc0997+=0x1){_0x91e42f=_0x5af89c[_0xdc0997]['get']({'plain':!![]}),_0x4a5a62[_0x307ff1('0x30')](db[_0x307ff1('0x5c')][_0x307ff1('0x43')](_0x1bc05f(_0x91e42f,_0x307ff1('0x50')))[_0x307ff1('0x13')](function(){})[_0x307ff1('0x9')](_0x51eddd()));}return _0x4a5a62;})[_0x395091('0x53')]();})[_0xaf402d('0x9')](function(_0x5ac3c2){const _0x39f633=_0xaf402d;logger[_0x39f633('0x2e')](_0x39f633('0x1d'),_0x39f633('0x61'),_0x5ac3c2[_0x39f633('0x57')]);});}const processPromises=function(_0x2db46d){const _0xea64fd=_0x2b549f;return Promise['all'](promises)[_0xea64fd('0x9')](function(_0x515928){const _0x10ffa9=_0xea64fd;logger['error'](_0x10ffa9('0x3'),JSON[_0x10ffa9('0x63')](_0x515928));})[_0xea64fd('0x4f')](function(){const _0x7f3467=_0xea64fd;socket['emit']('contact:csv_'+SOCKET_TIMESTAMP,{'success':success,'errors':errors,'duplicates':duplicates,'rows':rows}),promises=[],success=0x0,errors=0x0,duplicates=0x0,rows=[];if(_0x2db46d)return _0x2db46d[_0x7f3467('0x4d')]();});},endCsv=function(){const _0x3950d8=_0x2b549f;return Promise[_0x3950d8('0x6')]()[_0x3950d8('0x13')](function(){if(hopperContacts)return checkHopper();})[_0x3950d8('0x13')](function(){const _0x527de1=_0x3950d8;socket[_0x527de1('0x26')](_0x527de1('0x36')+SOCKET_TIMESTAMP,{'finished':!![],'success':success,'errors':errors,'duplicates':duplicates,'rows':rows});try{fs[_0x527de1('0x35')](FILEPATH);}catch(_0x1d9f7d){logger['error']('Unable\x20to\x20delete\x20temp\x20file:',JSON[_0x527de1('0x63')](_0x1d9f7d));}finally{process[_0x527de1('0x7')](0x0);}});};process['on'](_0x2b549f('0xe'),function(){const _0x2c1a5a=_0x2b549f;logger[_0x2c1a5a('0x1b')](_0x2c1a5a('0x44')),endCsv();});function main(){const _0x4b5973=_0x2b549f;return Promise[_0x4b5973('0x6')]()[_0x4b5973('0x13')](function(){const _0x59b929=_0x4b5973;if(DUPLICATES)return DUPLICATES=DUPLICATES['split'](','),db['CmContact'][_0x59b929('0x37')]({'where':{'ListId':LISTID},'attributes':DUPLICATES,'raw':!![]});})[_0x4b5973('0x13')](function(_0x2f3dae){const _0x5b0801=_0x4b5973,_0x49a677=fs[_0x5b0801('0x25')](FILEPATH,{'highWaterMark':0xf*0x400*0x400});Papa[_0x5b0801('0x60')](_0x49a677,{'header':!![],'skipEmptyLines':!![],'step':function(_0x2134bc,_0x4b05e0){const _0x4e48b0=_0x5b0801;total+=0x1;const _0xdfd3ad=total;promises[_0x4e48b0('0x30')](checkRow(_0x2134bc,_0x2f3dae,_0xdfd3ad)[_0x4e48b0('0x13')](function(){success+=0x1;})[_0x4e48b0('0x9')](function(_0xd61b6b){const _0x15d78d=_0x4e48b0;if(_0xd61b6b[_0x15d78d('0x2e')])errors+=0x1,delete _0xd61b6b['error'];else _0xd61b6b[_0x15d78d('0x18')]&&(duplicates+=0x1,delete _0xd61b6b[_0x15d78d('0x18')]);rows['push'](_0xd61b6b);}));if(total%0xc8===0x0)return _0x4b05e0[_0x4e48b0('0x21')](),processPromises(_0x4b05e0);},'complete':function(){const _0x3d30d2=_0x5b0801;return processPromises()[_0x3d30d2('0x13')](function(){const _0x876f8b=_0x3d30d2;logger[_0x876f8b('0x1b')](_0x876f8b('0x67')),endCsv();});},'error':function(_0xb02674){logger['info']('CSV\x20parse\x20error',JSON['stringify'](_0xb02674)),endCsv();}});})[_0x4b5973('0x9')](function(_0x331331){const _0x2c9559=_0x4b5973;logger[_0x2c9559('0x2e')]('Error\x20executing\x20contact\x20csv\x20import:',JSON['stringify'](_0x331331));});}main(); \ No newline at end of file diff --git a/server/components/import/cm/csv2.js b/server/components/import/cm/csv2.js index b174262..77baa5b 100644 --- a/server/components/import/cm/csv2.js +++ b/server/components/import/cm/csv2.js @@ -1 +1 @@ -const a831_0x590e=['concat','argv','cm_contacts.scheduledat','SystemError','push','CampaignId','ListId\x20is\x20mandatory','Received\x20SIGINT','error','YYYY-MM-DD\x20HH:mm:ss','exit','cm_hopper_black','root','deletedAt\x20IS\x20NULL','agent\x20not\x20exists','abort','appendFileSync','catch','CompanyId','format','\x20=\x20?','updatedAt','cm_hopper','.id\x20=\x20','socket_timestamp','cm_contacts.createdAt\x20=\x20?','UserId','step','undefined','import','fromQuery','cm_contacts','ContactId','duplicates','voice_queues_has_cm_blacklists','../../../config/logger','then','info','isValid','cm_contacts.phone\x20NOT\x20IN\x20(?)','unlink','errors','map','\x22always\x22','where','send','VoiceQueueId','cm_contacts.phone','ListId',',\x20scheduledAt\x20=\x20NOW()','binding\x20doesn\x27t\x20exists','SystemRow','\x20not\x20specified','files/tmp','parse','join','server/files/tmp','createReadStream','priority','.CmListId\x20=\x20?','cm_contacts.ListId','scheduledat','writeFileSync','cm_contacts_','message','MIN(id)','../../../mysqldb','lodash','dateOfBirth','emit','toString','Abort\x20parser','finish','length','scheduledat\x20wrong\x20format\x20(YYYY-MM-DD\x20HH:mm:ss)','path','campaigns_has_cm_lists','rows','affectedRows','code','cm_contacts.createdAt','stringify','\x20=\x20','select','keys','cm_contacts.priority','phone\x20is\x20mandatory','field','createdAt','ListId\x20=\x20?','recallme','firstName','email','uncaughtException','id\x20IN\x20?','trim','replace','campaigns','insert','voice_queues','\x20LIKE\x20cm_contacts;','squel','campaigns_has_cm_blacklists','firstName\x20is\x20mandatory','cm_contacts.UserId','cm_contacts.updatedAt','group','.csv','LOAD\x20DATA\x20LOCAL\x20INFILE\x20\x27%s\x27\x20INTO\x20TABLE\x20%s\x20CHARACTER\x20SET\x20UTF8\x20FIELDS\x20TERMINATED\x20BY\x20\x27,\x27\x20ENCLOSED\x20BY\x20\x27\x22\x27\x20LINES\x20TERMINATED\x20BY\x20\x27\x0a\x27\x20IGNORE\x201\x20ROWS\x20(%s)\x20SET\x20id\x20=\x20NULL,\x20ListId\x20=\x20%s,\x20CompanyId\x20=\x20%s,\x20createdAt\x20=\x20\x27%s\x27,\x20updatedAt\x20=\x20\x27%s\x27','data','cm_contacts.id','email\x20wrong\x20format','main','fields','isNumber','header','into','binding','phone','../../../rediscache',')\x20NOT\x20IN\x20?','cm_contacts.ListId\x20=\x20','.CmListId','.dialCheckDuplicateType\x20IN\x20(','CREATE\x20TABLE\x20','from'];(function(_0x3192e3,_0x590e30){const _0x908c85=function(_0xaadb8a){while(--_0xaadb8a){_0x3192e3['push'](_0x3192e3['shift']());}};_0x908c85(++_0x590e30);}(a831_0x590e,0x1a6));const a831_0x908c=function(_0x3192e3,_0x590e30){_0x3192e3=_0x3192e3-0x0;let _0x908c85=a831_0x590e[_0x3192e3];return _0x908c85;};const _0x28adb7=a831_0x908c;'use strict';const fs=require('fs'),path=require(_0x28adb7('0x1f')),_=require(_0x28adb7('0x17')),Papa=require('papaparse'),util=require('util'),moment=require('moment'),squel=require(_0x28adb7('0x39')),db=require(_0x28adb7('0x16'))['db'],config=require('../../../config/environment'),logger=require(_0x28adb7('0x75'))(_0x28adb7('0x6f')),{getSocket}=require(_0x28adb7('0x4b')),socket=getSocket(),stats={'finish':![],'errors':[],'rows':0x0,'affectedRows':0x0},results=[];let stopped=![];const NOW=moment()[_0x28adb7('0x65')](_0x28adb7('0x5b'));function isEmail(_0xaadb8a){return/^([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x22([^\x0d\x22\x5c\x80-\xff]|\x5c[\x00-\x7f])*\x22)(\x2e([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x22([^\x0d\x22\x5c\x80-\xff]|\x5c[\x00-\x7f])*\x22))*\x40([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x5b([^\x0d\x5b-\x5d\x80-\xff]|\x5c[\x00-\x7f])*\x5d)(\x2e([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x5b([^\x0d\x5b-\x5d\x80-\xff]|\x5c[\x00-\x7f])*\x5d))*$/['test'](_0xaadb8a);}function selectNotIn(_0x125d29,_0x2f9196,_0x27a6b7,_0x3eaba5,_0x7ba163){const _0x4e5011=_0x28adb7;return squel[_0x4e5011('0x27')]()[_0x4e5011('0x2b')](_0x4e5011('0x4a'))['from'](_0x3eaba5)['join'](_0x2f9196,null,_0x2f9196+_0x4e5011('0x69')+_0x3eaba5+'.'+_0x27a6b7)['where'](_0x3eaba5+'.'+_0x27a6b7+_0x4e5011('0x26')+_0x125d29+'.'+_0x27a6b7)[_0x4e5011('0x0')](_0x2f9196+_0x4e5011('0x4f')+_0x7ba163[_0x4e5011('0xb')]()+')');}function insertCmHopper(_0x54371b,_0xded3e1,_0x1612f6,_0x411467,_0x2d761b){const _0x3cf45e=_0x28adb7,_0x269887=[_0x3cf45e('0x3'),_0x3cf45e('0x54'),'cm_contacts.id',_0x3cf45e('0x10'),_0xded3e1+'.'+_0x411467,_0x3cf45e('0x24'),'cm_contacts.updatedAt',_0x3cf45e('0x29'),_0x3cf45e('0x3c'),'\x22'+_0x2d761b+'\x22'];return squel[_0x3cf45e('0x36')]()[_0x3cf45e('0x48')](_0x3cf45e('0x68'))[_0x3cf45e('0x70')]([_0x3cf45e('0x4a'),'scheduledat','ContactId','ListId',_0x411467,_0x3cf45e('0x2c'),'updatedAt',_0x3cf45e('0xe'),_0x3cf45e('0x6c'),_0x3cf45e('0x2e')],squel[_0x3cf45e('0x27')]()[_0x3cf45e('0x45')](_0x269887)[_0x3cf45e('0x51')](_0xded3e1)[_0x3cf45e('0xb')](_0x3cf45e('0x71'),null,_0x3cf45e('0x4d')+_0xded3e1+_0x3cf45e('0x4e'))[_0x3cf45e('0xb')](_0x1612f6,null,_0x1612f6+_0x3cf45e('0x69')+_0xded3e1+'.'+_0x411467)['where'](_0xded3e1+_0x3cf45e('0xf'),_0x54371b)['where'](_0x3cf45e('0x6b'),NOW)[_0x3cf45e('0x0')](_0x3cf45e('0x79'),selectNotIn(_0xded3e1,_0x1612f6,_0x411467,_0x3cf45e('0x68'),[_0x3cf45e('0x7d'),'\x22onlyIfOpen\x22']))[_0x3cf45e('0x0')](_0x3cf45e('0x79'),selectNotIn(_0xded3e1,_0x1612f6,_0x411467,_0x3cf45e('0x68'),[_0x3cf45e('0x7d')])))['toString']();}function insertCmHopperBlack(_0xf64ab4,_0x5aa0db,_0x20b732,_0x5a5d1d){const _0x31eae1=_0x28adb7,_0xfcf008=[_0x31eae1('0x3'),_0x31eae1('0x42'),_0x31eae1('0x10'),_0x5aa0db+'.'+_0x5a5d1d,'cm_contacts.createdAt',_0x31eae1('0x3d')];return squel[_0x31eae1('0x36')]()[_0x31eae1('0x48')](_0x31eae1('0x5d'))[_0x31eae1('0x70')]([_0x31eae1('0x4a'),_0x31eae1('0x72'),_0x31eae1('0x4'),_0x5a5d1d,_0x31eae1('0x2c'),'updatedAt'],squel[_0x31eae1('0x27')]()[_0x31eae1('0x45')](_0xfcf008)['from'](_0x5aa0db)[_0x31eae1('0xb')](_0x31eae1('0x71'),null,_0x31eae1('0x4d')+_0x5aa0db+_0x31eae1('0x4e'))[_0x31eae1('0xb')](_0x20b732,null,_0x20b732+_0x31eae1('0x69')+_0x5aa0db+'.'+_0x5a5d1d)[_0x31eae1('0x0')](_0x5aa0db+_0x31eae1('0xf'),_0xf64ab4)[_0x31eae1('0x0')](_0x31eae1('0x6b'),NOW)[_0x31eae1('0x0')](_0x31eae1('0x79'),squel[_0x31eae1('0x27')]()[_0x31eae1('0x2b')]('phone')[_0x31eae1('0x51')](_0x31eae1('0x5d'))[_0x31eae1('0x0')](_0x31eae1('0x2d'),_0xf64ab4)[_0x31eae1('0x0')](_0x5a5d1d+_0x31eae1('0x66'),_0x5aa0db+'.'+_0x5a5d1d)))[_0x31eae1('0x1a')]();}function insertCmContact(_0x33c313,_0x2ef7cd,_0x5e7451,_0x410704){const _0x263409=_0x28adb7,_0x16fe6c=_[_0x263409('0x52')](_[_0x263409('0x28')](_0x410704),['ListId',_0x263409('0x64'),_0x263409('0x2c'),_0x263409('0x67')]);return squel[_0x263409('0x36')]()[_0x263409('0x48')](_0x263409('0x71'))['fromQuery'](_0x16fe6c,squel['select']()[_0x263409('0x45')](_0x16fe6c)[_0x263409('0x51')](_0x2ef7cd)[_0x263409('0x0')]('('+_0x5e7451[_0x263409('0xb')](',')+_0x263409('0x4c'),squel[_0x263409('0x27')]()[_0x263409('0x45')](_0x5e7451)[_0x263409('0x51')]('cm_contacts')[_0x263409('0x0')]('ListId\x20=\x20?',_0x33c313)['where'](_0x263409('0x5f')))[_0x263409('0x0')](_0x263409('0x32'),squel[_0x263409('0x27')]()['field'](_0x263409('0x15'),'min_id')[_0x263409('0x51')](_0x2ef7cd)[_0x263409('0x3e')](_0x5e7451[_0x263409('0xb')](','))))['toString']();}function handleStop(){const _0x6798b=_0x28adb7;logger['info'](_0x6798b('0x59')),stopped=!![];}function handleUncaughtException(_0x22a228){const _0x141552=_0x28adb7;logger[_0x141552('0x5a')](_0x22a228[_0x141552('0x14')]);throw _0x22a228;}function handleError(_0x5d45bf,_0x254d0d){const _0x190dae=_0x28adb7;stats[_0x190dae('0x7b')]['push']({'name':_0x254d0d[_0x190dae('0x23')],'message':_0x254d0d[_0x190dae('0x14')],'row':_0x5d45bf});}function handleQuery(_0xb937b4){const _0x5c214f=_0x28adb7;return logger[_0x5c214f('0x77')](_0xb937b4),db['sequelize']['query'](_0xb937b4)['then'](function([_0xa1aeaa]){const _0x3349af=_0x5c214f;results[_0x3349af('0x56')](_0xa1aeaa);})[_0x5c214f('0x63')](function(_0x746b7b){const _0x904f77=_0x5c214f;logger[_0x904f77('0x5a')](_0x746b7b['message']);});}function main(_0x5c3577,_0x173752,_0x353e3f,_0x9ea751){const _0x36a255=_0x28adb7;logger[_0x36a255('0x77')](_0x36a255('0x44'),_0x5c3577,JSON[_0x36a255('0x25')](_0x173752)),process[_0x36a255('0x1')]('start');const _0x7be490=_0x173752[_0x36a255('0x49')],_0x4ded57=_0x173752[_0x36a255('0x6a')],_0x323e83=path[_0x36a255('0xb')](config['root'],_0x36a255('0xc'),_0x4ded57+_0x36a255('0x3f')),_0x30c6cd=_[_0x36a255('0x28')](_0x7be490)[_0x36a255('0xb')]();logger[_0x36a255('0x77')](_0x36a255('0x47'),_0x30c6cd),fs[_0x36a255('0x12')](_0x323e83,_0x30c6cd+'\x0a'),Papa['parse'](fs[_0x36a255('0xd')](_0x5c3577),{'header':!![],'skipEmptyLines':!![],'step':function(_0x103d9b,_0x2b967d){const _0x49091a=_0x36a255;let _0x2a946b=0x0,_0x547400=[];try{for(_0x2a946b=0x0,_0x547400=[];_0x2a946b<_0x103d9b[_0x49091a('0x41')][_0x49091a('0x1d')];_0x2a946b++){stats[_0x49091a('0x21')]+=0x1;if(_0x103d9b[_0x49091a('0x7b')][_0x2a946b])handleError(_0x103d9b[_0x49091a('0x41')][_0x2a946b],_0x103d9b[_0x49091a('0x7b')][_0x2a946b]);else{const _0x87162f=[];for(const _0x47fbbc in _0x7be490){if(typeof _0x7be490[_0x47fbbc]!==_0x49091a('0x6e')){if(_0x103d9b['data'][_0x2a946b][_0x7be490[_0x47fbbc]]){let _0x4fda8e=_[_0x49091a('0x33')](_0x103d9b[_0x49091a('0x41')][_0x2a946b][_0x7be490[_0x47fbbc]][_0x49091a('0x34')](/"/g,'\x27'));switch(_0x47fbbc){case _0x49091a('0x11'):{const _0x43a78a=moment(_0x4fda8e,_0x49091a('0x5b'),!![]);_0x43a78a['isValid']()?_0x547400[_0x49091a('0x56')]('\x22'+_0x4fda8e+'\x22'):_0x87162f[_0x49091a('0x56')](_0x49091a('0x1e'));}break;case _0x49091a('0xe'):{const _0x12d87c=parseInt(_0x4fda8e);_0x4fda8e=_['isNaN'](_0x12d87c)||_0x12d87c<0x0||_0x12d87c>0x4?_0x9ea751?0x3:0x2:_0x12d87c,_0x547400[_0x49091a('0x56')]('\x22'+_0x4fda8e+'\x22');}break;case _0x49091a('0x6c'):{const _0xcf810f=parseInt(_0x4fda8e);_[_0x49091a('0x46')](_0xcf810f)&&_['includes'](_0x353e3f,_0xcf810f)?_0x547400[_0x49091a('0x56')]('\x22'+_0xcf810f+'\x22'):_0x87162f[_0x49091a('0x56')](_0x49091a('0x60'));}break;case _0x49091a('0x30'):isEmail(_0x4fda8e)?_0x547400[_0x49091a('0x56')]('\x22'+_0x4fda8e+'\x22'):_0x87162f[_0x49091a('0x56')](_0x49091a('0x43'));break;case _0x49091a('0x18'):{const _0x218d8f=moment(_0x4fda8e,'YYYY-MM-DD',!![]);_0x218d8f[_0x49091a('0x78')]()?_0x547400[_0x49091a('0x56')]('\x22'+_0x4fda8e+'\x22'):_0x87162f[_0x49091a('0x56')]('dateOfBirth\x20wrong\x20format\x20(YYYY-MM-DD)');}break;default:_0x547400[_0x49091a('0x56')]('\x22'+_0x4fda8e+'\x22');}}else switch(_0x47fbbc){case _0x49091a('0x2f'):case'phone':_0x87162f['push'](_0x47fbbc+_0x49091a('0x8'));break;default:_0x547400[_0x49091a('0x56')]('\x22\x22');}}}_0x87162f[_0x49091a('0x1d')]?handleError(_0x103d9b[_0x49091a('0x41')][_0x2a946b],{'code':_0x49091a('0x7'),'message':_0x87162f[_0x49091a('0xb')]()}):fs[_0x49091a('0x62')](_0x323e83,_0x547400[_0x49091a('0xb')]()+'\x0a'),_0x547400=[];}!(stats[_0x49091a('0x21')]%0xc8)&&(socket[_0x49091a('0x19')]('contact:import:'+_0x4ded57,stats),stats[_0x49091a('0x7b')]=[]);}stopped&&(logger[_0x49091a('0x77')](_0x49091a('0x1b')),_0x2b967d[_0x49091a('0x61')]());}catch(_0x16aa2f){handleError(_0x103d9b['data'][_0x2a946b],{'code':_0x49091a('0x55'),'message':_0x16aa2f['message']}),logger[_0x49091a('0x5a')](_0x49091a('0x6d'),_0x16aa2f[_0x49091a('0x14')]);}},'complete':function(){const _0x46e574=_0x36a255;try{const _0x3d9926=[];let _0x220362=_0x46e574('0x71');_0x173752['duplicates']&&_0x173752['duplicates'][_0x46e574('0x1d')]&&(_0x220362=_0x46e574('0x13')+_0x4ded57,_0x3d9926[_0x46e574('0x56')](_0x46e574('0x50')+_0x220362+_0x46e574('0x38')));let _0x13fabd=util['format'](_0x46e574('0x40'),_0x323e83,_0x220362,_0x30c6cd,_0x173752[_0x46e574('0x4')],_0x173752[_0x46e574('0x64')]||null,NOW,NOW);_['isNil'](_0x7be490[_0x46e574('0x11')])&&(_0x13fabd+=_0x46e574('0x5')),_0x3d9926[_0x46e574('0x56')](_0x13fabd),_0x173752[_0x46e574('0x73')]&&_0x173752[_0x46e574('0x73')][_0x46e574('0x1d')]&&(_0x3d9926[_0x46e574('0x56')](insertCmContact(_0x173752[_0x46e574('0x4')],_0x220362,_0x173752[_0x46e574('0x73')],_0x7be490)),_0x3d9926[_0x46e574('0x56')]('DROP\x20TABLE\x20'+_0x220362+';')),_0x3d9926[_0x46e574('0x56')](insertCmHopper(_0x173752[_0x46e574('0x4')],'voice_queues_has_cm_lists',_0x46e574('0x37'),_0x46e574('0x2'),_0x9ea751)),_0x3d9926[_0x46e574('0x56')](insertCmHopperBlack(_0x173752['ListId'],_0x46e574('0x74'),_0x46e574('0x37'),_0x46e574('0x2'))),_0x3d9926[_0x46e574('0x56')](insertCmHopper(_0x173752[_0x46e574('0x4')],_0x46e574('0x20'),_0x46e574('0x35'),'CampaignId',_0x9ea751)),_0x3d9926['push'](insertCmHopperBlack(_0x173752['ListId'],_0x46e574('0x3a'),_0x46e574('0x35'),_0x46e574('0x57'))),Promise['each'](_0x3d9926,handleQuery)[_0x46e574('0x76')](function(){const _0x7b7389=_0x46e574;stats[_0x7b7389('0x1c')]=!![],stats[_0x7b7389('0x22')]=_0x173752[_0x7b7389('0x73')]&&_0x173752['duplicates'][_0x7b7389('0x1d')]?results[0x2][_0x7b7389('0x22')]:results[0x0]['affectedRows'],socket['emit']('contact:import:'+_0x4ded57,stats),fs[_0x7b7389('0x7a')](_0x5c3577),fs['unlink'](_0x323e83),process[_0x7b7389('0x5c')](0x0);})[_0x46e574('0x63')](function(_0x24d5bd){const _0x58adbd=_0x46e574;logger[_0x58adbd('0x5a')](_0x24d5bd[_0x58adbd('0x14')]);throw _0x24d5bd;});}catch(_0x4fd479){logger[_0x46e574('0x5a')]('complete',_0x4fd479[_0x46e574('0x14')]);throw _0x4fd479;}},'error':function(_0x5d37f3,_0x52b12a,_0x2c1eec,_0x233dd8){throw new Error(_0x233dd8);}});}function validate(){const _0x3636a3=_0x28adb7;if(process[_0x3636a3('0x53')]&&process[_0x3636a3('0x53')][_0x3636a3('0x1d')]<0x4)throw new Error('arguments\x20\x20\x20');const _0x35cc23=path['join'](config[_0x3636a3('0x5e')],_0x3636a3('0x9'),process[_0x3636a3('0x53')][0x2]);if(!fs['existsSync'](_0x35cc23))throw new Error('file\x20doesn\x27t\x20exists');let _0x4547fb={},_0x1ec984=0x0;try{_0x4547fb=JSON[_0x3636a3('0xa')](process['argv'][0x3]);if(!_0x4547fb[_0x3636a3('0x49')])throw new Error(_0x3636a3('0x6'));if(!_0x4547fb[_0x3636a3('0x49')]['phone'])throw new Error(_0x3636a3('0x2a'));if(!_0x4547fb[_0x3636a3('0x49')][_0x3636a3('0x2f')])throw new Error(_0x3636a3('0x3b'));_0x4547fb[_0x3636a3('0x49')][_0x3636a3('0x6c')]&&(_0x1ec984=0x1);if(!_0x4547fb[_0x3636a3('0x4')])throw new Error(_0x3636a3('0x58'));}catch(_0x200391){throw new Error('body\x20id\x20mandatory');}let _0xb45cb0=[];try{_0xb45cb0=_[_0x3636a3('0x7c')](JSON['parse'](process['argv'][0x4]),'id');}catch(_0x5f5363){logger[_0x3636a3('0x77')]('No\x20agent\x20available');}main(_0x35cc23,_0x4547fb,_0xb45cb0,_0x1ec984);}validate(),process['on']('SIGINT',handleStop),process['on'](_0x28adb7('0x31'),handleUncaughtException); \ No newline at end of file +const a831_0xdb1f=['includes','toString','util','dateOfBirth','files/tmp','SystemError','updatedAt','\x22always\x22','finish','data','join','duplicates','deletedAt\x20IS\x20NULL','YYYY-MM-DD\x20HH:mm:ss','isNaN','.CmListId','complete','campaigns_has_cm_blacklists','papaparse','format','voice_queues_has_cm_blacklists','cm_contacts.id','step','createdAt','fromQuery','firstName','body\x20id\x20mandatory','concat','email','isValid','lodash','\x20LIKE\x20cm_contacts;','agent\x20not\x20exists','cm_hopper','main','into','push','socket_timestamp','.dialCheckDuplicateType\x20IN\x20(','../../../config/environment','ContactId','send','.CmListId\x20=\x20?','affectedRows','keys','stringify','cm_contacts.updatedAt','file\x20doesn\x27t\x20exists','uncaughtException','firstName\x20is\x20mandatory','voice_queues_has_cm_lists','cm_contacts.ListId\x20=\x20','rows','phone','abort','dateOfBirth\x20wrong\x20format\x20(YYYY-MM-DD)','cm_contacts.createdAt','cm_contacts.phone\x20NOT\x20IN\x20(?)',',\x20scheduledAt\x20=\x20NOW()','message','campaigns_has_cm_lists','exit','ListId','Received\x20SIGINT','binding\x20doesn\x27t\x20exists','length','CompanyId','cm_contacts.scheduledat','VoiceQueueId','cm_contacts_','cm_contacts.createdAt\x20=\x20?','import','group','info','../../../rediscache','fields','../../../config/logger','select','No\x20agent\x20available','cm_contacts.UserId','where','header','CampaignId','field','scheduledat','each','cm_contacts','ListId\x20=\x20?','parse','ListId\x20is\x20mandatory','contact:import:','start','cm_contacts.phone','\x20not\x20specified','\x20=\x20','errors','LOAD\x20DATA\x20LOCAL\x20INFILE\x20\x27%s\x27\x20INTO\x20TABLE\x20%s\x20CHARACTER\x20SET\x20UTF8\x20FIELDS\x20TERMINATED\x20BY\x20\x27,\x27\x20ENCLOSED\x20BY\x20\x27\x22\x27\x20LINES\x20TERMINATED\x20BY\x20\x27\x0a\x27\x20IGNORE\x201\x20ROWS\x20(%s)\x20SET\x20id\x20=\x20NULL,\x20ListId\x20=\x20%s,\x20CompanyId\x20=\x20%s,\x20createdAt\x20=\x20\x27%s\x27,\x20updatedAt\x20=\x20\x27%s\x27','catch','query','code','binding','unlink','priority','.id\x20=\x20','MIN(id)','emit','squel','existsSync','voice_queues','DROP\x20TABLE\x20','test','campaigns','error','YYYY-MM-DD','.csv','cm_hopper_black','argv','then','insert',')\x20NOT\x20IN\x20?','from','email\x20wrong\x20format','phone\x20is\x20mandatory','UserId','scheduledat\x20wrong\x20format\x20(YYYY-MM-DD\x20HH:mm:ss)','createReadStream'];(function(_0xe01711,_0xdb1fb4){const _0x337873=function(_0x58aada){while(--_0x58aada){_0xe01711['push'](_0xe01711['shift']());}};_0x337873(++_0xdb1fb4);}(a831_0xdb1f,0x182));const a831_0x3378=function(_0xe01711,_0xdb1fb4){_0xe01711=_0xe01711-0x0;let _0x337873=a831_0xdb1f[_0xe01711];return _0x337873;};const _0x18ee37=a831_0x3378;'use strict';const fs=require('fs'),path=require('path'),_=require(_0x18ee37('0x16')),Papa=require(_0x18ee37('0xa')),util=require(_0x18ee37('0x78')),moment=require('moment'),squel=require(_0x18ee37('0x62')),db=require('../../../mysqldb')['db'],config=require(_0x18ee37('0x1f')),logger=require(_0x18ee37('0x44'))(_0x18ee37('0x3f')),{getSocket}=require(_0x18ee37('0x42')),socket=getSocket(),stats={'finish':![],'errors':[],'rows':0x0,'affectedRows':0x0},results=[];let stopped=![];const NOW=moment()['format'](_0x18ee37('0x5'));function isEmail(_0x58aada){const _0x3a58d0=_0x18ee37;return/^([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x22([^\x0d\x22\x5c\x80-\xff]|\x5c[\x00-\x7f])*\x22)(\x2e([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x22([^\x0d\x22\x5c\x80-\xff]|\x5c[\x00-\x7f])*\x22))*\x40([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x5b([^\x0d\x5b-\x5d\x80-\xff]|\x5c[\x00-\x7f])*\x5d)(\x2e([^\x00-\x20\x22\x28\x29\x2c\x2e\x3a-\x3c\x3e\x40\x5b-\x5d\x7f-\xff]+|\x5b([^\x0d\x5b-\x5d\x80-\xff]|\x5c[\x00-\x7f])*\x5d))*$/[_0x3a58d0('0x66')](_0x58aada);}function selectNotIn(_0x17391c,_0xa57704,_0x7e00e4,_0x3d71ab,_0xb357e2){const _0x33e7dd=_0x18ee37;return squel[_0x33e7dd('0x45')]()[_0x33e7dd('0x4b')]('phone')[_0x33e7dd('0x70')](_0x3d71ab)[_0x33e7dd('0x2')](_0xa57704,null,_0xa57704+'.id\x20=\x20'+_0x3d71ab+'.'+_0x7e00e4)[_0x33e7dd('0x48')](_0x3d71ab+'.'+_0x7e00e4+_0x33e7dd('0x56')+_0x17391c+'.'+_0x7e00e4)[_0x33e7dd('0x48')](_0xa57704+_0x33e7dd('0x1e')+_0xb357e2[_0x33e7dd('0x2')]()+')');}function insertCmHopper(_0x2c7e51,_0x150ef2,_0x44aaef,_0x184257,_0x47ef27){const _0xc19abe=_0x18ee37,_0x4be976=['cm_contacts.phone',_0xc19abe('0x3b'),_0xc19abe('0xd'),'cm_contacts.ListId',_0x150ef2+'.'+_0x184257,_0xc19abe('0x30'),_0xc19abe('0x26'),'cm_contacts.priority',_0xc19abe('0x47'),'\x22'+_0x47ef27+'\x22'];return squel['insert']()[_0xc19abe('0x1b')](_0xc19abe('0x19'))[_0xc19abe('0x10')]([_0xc19abe('0x2d'),_0xc19abe('0x4c'),_0xc19abe('0x20'),_0xc19abe('0x36'),_0x184257,_0xc19abe('0xf'),_0xc19abe('0x7c'),_0xc19abe('0x5e'),_0xc19abe('0x73'),'recallme'],squel[_0xc19abe('0x45')]()[_0xc19abe('0x43')](_0x4be976)[_0xc19abe('0x70')](_0x150ef2)[_0xc19abe('0x2')](_0xc19abe('0x4e'),null,'cm_contacts.ListId\x20=\x20'+_0x150ef2+_0xc19abe('0x7'))[_0xc19abe('0x2')](_0x44aaef,null,_0x44aaef+_0xc19abe('0x5f')+_0x150ef2+'.'+_0x184257)[_0xc19abe('0x48')](_0x150ef2+_0xc19abe('0x22'),_0x2c7e51)[_0xc19abe('0x48')](_0xc19abe('0x3e'),NOW)['where'](_0xc19abe('0x31'),selectNotIn(_0x150ef2,_0x44aaef,_0x184257,_0xc19abe('0x19'),[_0xc19abe('0x7d'),'\x22onlyIfOpen\x22']))[_0xc19abe('0x48')](_0xc19abe('0x31'),selectNotIn(_0x150ef2,_0x44aaef,_0x184257,'cm_hopper',[_0xc19abe('0x7d')])))[_0xc19abe('0x77')]();}function insertCmHopperBlack(_0x5b36ce,_0x5bb115,_0x3b8846,_0x89a06b){const _0x161b78=_0x18ee37,_0x4dd68a=[_0x161b78('0x54'),_0x161b78('0xd'),'cm_contacts.ListId',_0x5bb115+'.'+_0x89a06b,_0x161b78('0x30'),_0x161b78('0x26')];return squel[_0x161b78('0x6e')]()[_0x161b78('0x1b')](_0x161b78('0x6b'))[_0x161b78('0x10')](['phone',_0x161b78('0x20'),'ListId',_0x89a06b,'createdAt',_0x161b78('0x7c')],squel[_0x161b78('0x45')]()['fields'](_0x4dd68a)[_0x161b78('0x70')](_0x5bb115)[_0x161b78('0x2')]('cm_contacts',null,_0x161b78('0x2b')+_0x5bb115+_0x161b78('0x7'))['join'](_0x3b8846,null,_0x3b8846+_0x161b78('0x5f')+_0x5bb115+'.'+_0x89a06b)['where'](_0x5bb115+'.CmListId\x20=\x20?',_0x5b36ce)[_0x161b78('0x48')](_0x161b78('0x3e'),NOW)['where'](_0x161b78('0x31'),squel['select']()[_0x161b78('0x4b')]('phone')[_0x161b78('0x70')](_0x161b78('0x6b'))[_0x161b78('0x48')](_0x161b78('0x4f'),_0x5b36ce)['where'](_0x89a06b+'\x20=\x20?',_0x5bb115+'.'+_0x89a06b)))['toString']();}function insertCmContact(_0x1c7a8f,_0x3f930a,_0x4a257d,_0x5ab05f){const _0x4035de=_0x18ee37,_0x37b73f=_[_0x4035de('0x13')](_[_0x4035de('0x24')](_0x5ab05f),[_0x4035de('0x36'),'CompanyId',_0x4035de('0xf'),_0x4035de('0x7c')]);return squel[_0x4035de('0x6e')]()['into'](_0x4035de('0x4e'))[_0x4035de('0x10')](_0x37b73f,squel['select']()[_0x4035de('0x43')](_0x37b73f)['from'](_0x3f930a)[_0x4035de('0x48')]('('+_0x4a257d['join'](',')+_0x4035de('0x6f'),squel[_0x4035de('0x45')]()['fields'](_0x4a257d)['from'](_0x4035de('0x4e'))[_0x4035de('0x48')](_0x4035de('0x4f'),_0x1c7a8f)['where'](_0x4035de('0x4')))[_0x4035de('0x48')]('id\x20IN\x20?',squel[_0x4035de('0x45')]()['field'](_0x4035de('0x60'),'min_id')[_0x4035de('0x70')](_0x3f930a)[_0x4035de('0x40')](_0x4a257d[_0x4035de('0x2')](','))))[_0x4035de('0x77')]();}function handleStop(){const _0xd6a97a=_0x18ee37;logger[_0xd6a97a('0x41')](_0xd6a97a('0x37')),stopped=!![];}function handleUncaughtException(_0x68dfbd){const _0x150ad3=_0x18ee37;logger[_0x150ad3('0x68')](_0x68dfbd['message']);throw _0x68dfbd;}function handleError(_0x1ba0ba,_0xae7e0c){const _0x3eb573=_0x18ee37;stats[_0x3eb573('0x57')]['push']({'name':_0xae7e0c[_0x3eb573('0x5b')],'message':_0xae7e0c[_0x3eb573('0x33')],'row':_0x1ba0ba});}function handleQuery(_0x33d839){const _0x16d95f=_0x18ee37;return logger[_0x16d95f('0x41')](_0x33d839),db['sequelize'][_0x16d95f('0x5a')](_0x33d839)['then'](function([_0x514ebc]){const _0x47103a=_0x16d95f;results[_0x47103a('0x1c')](_0x514ebc);})[_0x16d95f('0x59')](function(_0xdab0ea){const _0x366e54=_0x16d95f;logger[_0x366e54('0x68')](_0xdab0ea[_0x366e54('0x33')]);});}function main(_0x3dcde7,_0x134f7a,_0x10f8cd,_0xff5dad){const _0x3e7e55=_0x18ee37;logger[_0x3e7e55('0x41')](_0x3e7e55('0x1a'),_0x3dcde7,JSON[_0x3e7e55('0x25')](_0x134f7a)),process[_0x3e7e55('0x21')](_0x3e7e55('0x53'));const _0x2967f0=_0x134f7a[_0x3e7e55('0x5c')],_0x5536d4=_0x134f7a[_0x3e7e55('0x1d')],_0x4a169f=path[_0x3e7e55('0x2')](config['root'],'server/files/tmp',_0x5536d4+_0x3e7e55('0x6a')),_0x1c0236=_[_0x3e7e55('0x24')](_0x2967f0)['join']();logger[_0x3e7e55('0x41')](_0x3e7e55('0x49'),_0x1c0236),fs['writeFileSync'](_0x4a169f,_0x1c0236+'\x0a'),Papa['parse'](fs[_0x3e7e55('0x75')](_0x3dcde7),{'header':!![],'skipEmptyLines':!![],'step':function(_0x5a769b,_0x4ba4d0){const _0x5c5acf=_0x3e7e55;let _0x4454b5=0x0,_0x4c3b2d=[];try{for(_0x4454b5=0x0,_0x4c3b2d=[];_0x4454b5<_0x5a769b[_0x5c5acf('0x1')][_0x5c5acf('0x39')];_0x4454b5++){stats[_0x5c5acf('0x2c')]+=0x1;if(_0x5a769b['errors'][_0x4454b5])handleError(_0x5a769b[_0x5c5acf('0x1')][_0x4454b5],_0x5a769b[_0x5c5acf('0x57')][_0x4454b5]);else{const _0x2c0655=[];for(const _0x2e01d6 in _0x2967f0){if(typeof _0x2967f0[_0x2e01d6]!=='undefined'){if(_0x5a769b[_0x5c5acf('0x1')][_0x4454b5][_0x2967f0[_0x2e01d6]]){let _0x3ff2df=_['trim'](_0x5a769b[_0x5c5acf('0x1')][_0x4454b5][_0x2967f0[_0x2e01d6]]['replace'](/"/g,'\x27'));switch(_0x2e01d6){case _0x5c5acf('0x4c'):{const _0x11c40f=moment(_0x3ff2df,_0x5c5acf('0x5'),!![]);_0x11c40f[_0x5c5acf('0x15')]()?_0x4c3b2d[_0x5c5acf('0x1c')]('\x22'+_0x3ff2df+'\x22'):_0x2c0655['push'](_0x5c5acf('0x74'));}break;case _0x5c5acf('0x5e'):{const _0x3c050e=parseInt(_0x3ff2df);_0x3ff2df=_[_0x5c5acf('0x6')](_0x3c050e)||_0x3c050e<0x0||_0x3c050e>0x4?_0xff5dad?0x3:0x2:_0x3c050e,_0x4c3b2d[_0x5c5acf('0x1c')]('\x22'+_0x3ff2df+'\x22');}break;case _0x5c5acf('0x73'):{const _0x97a4a8=parseInt(_0x3ff2df);_['isNumber'](_0x97a4a8)&&_[_0x5c5acf('0x76')](_0x10f8cd,_0x97a4a8)?_0x4c3b2d[_0x5c5acf('0x1c')]('\x22'+_0x97a4a8+'\x22'):_0x2c0655['push'](_0x5c5acf('0x18'));}break;case _0x5c5acf('0x14'):isEmail(_0x3ff2df)?_0x4c3b2d['push']('\x22'+_0x3ff2df+'\x22'):_0x2c0655[_0x5c5acf('0x1c')](_0x5c5acf('0x71'));break;case _0x5c5acf('0x79'):{const _0x35a1d1=moment(_0x3ff2df,_0x5c5acf('0x69'),!![]);_0x35a1d1[_0x5c5acf('0x15')]()?_0x4c3b2d[_0x5c5acf('0x1c')]('\x22'+_0x3ff2df+'\x22'):_0x2c0655['push'](_0x5c5acf('0x2f'));}break;default:_0x4c3b2d[_0x5c5acf('0x1c')]('\x22'+_0x3ff2df+'\x22');}}else switch(_0x2e01d6){case'firstName':case _0x5c5acf('0x2d'):_0x2c0655[_0x5c5acf('0x1c')](_0x2e01d6+_0x5c5acf('0x55'));break;default:_0x4c3b2d[_0x5c5acf('0x1c')]('\x22\x22');}}}_0x2c0655['length']?handleError(_0x5a769b[_0x5c5acf('0x1')][_0x4454b5],{'code':'SystemRow','message':_0x2c0655['join']()}):fs['appendFileSync'](_0x4a169f,_0x4c3b2d[_0x5c5acf('0x2')]()+'\x0a'),_0x4c3b2d=[];}!(stats[_0x5c5acf('0x2c')]%0xc8)&&(socket[_0x5c5acf('0x61')](_0x5c5acf('0x52')+_0x5536d4,stats),stats[_0x5c5acf('0x57')]=[]);}stopped&&(logger[_0x5c5acf('0x41')]('Abort\x20parser'),_0x4ba4d0[_0x5c5acf('0x2e')]());}catch(_0x41a189){handleError(_0x5a769b[_0x5c5acf('0x1')][_0x4454b5],{'code':_0x5c5acf('0x7b'),'message':_0x41a189[_0x5c5acf('0x33')]}),logger[_0x5c5acf('0x68')](_0x5c5acf('0xe'),_0x41a189[_0x5c5acf('0x33')]);}},'complete':function(){const _0x52effb=_0x3e7e55;try{const _0x1c28ad=[];let _0x5d24e3=_0x52effb('0x4e');_0x134f7a[_0x52effb('0x3')]&&_0x134f7a[_0x52effb('0x3')]['length']&&(_0x5d24e3=_0x52effb('0x3d')+_0x5536d4,_0x1c28ad[_0x52effb('0x1c')]('CREATE\x20TABLE\x20'+_0x5d24e3+_0x52effb('0x17')));let _0x12d5a4=util[_0x52effb('0xb')](_0x52effb('0x58'),_0x4a169f,_0x5d24e3,_0x1c0236,_0x134f7a['ListId'],_0x134f7a[_0x52effb('0x3a')]||null,NOW,NOW);_['isNil'](_0x2967f0[_0x52effb('0x4c')])&&(_0x12d5a4+=_0x52effb('0x32')),_0x1c28ad[_0x52effb('0x1c')](_0x12d5a4),_0x134f7a[_0x52effb('0x3')]&&_0x134f7a['duplicates'][_0x52effb('0x39')]&&(_0x1c28ad[_0x52effb('0x1c')](insertCmContact(_0x134f7a[_0x52effb('0x36')],_0x5d24e3,_0x134f7a[_0x52effb('0x3')],_0x2967f0)),_0x1c28ad[_0x52effb('0x1c')](_0x52effb('0x65')+_0x5d24e3+';')),_0x1c28ad[_0x52effb('0x1c')](insertCmHopper(_0x134f7a['ListId'],_0x52effb('0x2a'),_0x52effb('0x64'),_0x52effb('0x3c'),_0xff5dad)),_0x1c28ad['push'](insertCmHopperBlack(_0x134f7a[_0x52effb('0x36')],_0x52effb('0xc'),_0x52effb('0x64'),_0x52effb('0x3c'))),_0x1c28ad[_0x52effb('0x1c')](insertCmHopper(_0x134f7a[_0x52effb('0x36')],_0x52effb('0x34'),_0x52effb('0x67'),_0x52effb('0x4a'),_0xff5dad)),_0x1c28ad['push'](insertCmHopperBlack(_0x134f7a['ListId'],_0x52effb('0x9'),_0x52effb('0x67'),_0x52effb('0x4a'))),Promise[_0x52effb('0x4d')](_0x1c28ad,handleQuery)[_0x52effb('0x6d')](function(){const _0x24be58=_0x52effb;stats[_0x24be58('0x0')]=!![],stats[_0x24be58('0x23')]=_0x134f7a[_0x24be58('0x3')]&&_0x134f7a[_0x24be58('0x3')][_0x24be58('0x39')]?results[0x2][_0x24be58('0x23')]:results[0x0]['affectedRows'],socket[_0x24be58('0x61')](_0x24be58('0x52')+_0x5536d4,stats),fs[_0x24be58('0x5d')](_0x3dcde7),fs['unlink'](_0x4a169f),process[_0x24be58('0x35')](0x0);})['catch'](function(_0x3b2e29){const _0x54103f=_0x52effb;logger[_0x54103f('0x68')](_0x3b2e29[_0x54103f('0x33')]);throw _0x3b2e29;});}catch(_0x22080f){logger[_0x52effb('0x68')](_0x52effb('0x8'),_0x22080f['message']);throw _0x22080f;}},'error':function(_0x1561e7,_0x26f6d7,_0x36e2a0,_0x27cf47){throw new Error(_0x27cf47);}});}function validate(){const _0x5cdf0e=_0x18ee37;if(process[_0x5cdf0e('0x6c')]&&process[_0x5cdf0e('0x6c')][_0x5cdf0e('0x39')]<0x4)throw new Error('arguments\x20\x20\x20');const _0x57dddb=path[_0x5cdf0e('0x2')](config['root'],_0x5cdf0e('0x7a'),process[_0x5cdf0e('0x6c')][0x2]);if(!fs[_0x5cdf0e('0x63')](_0x57dddb))throw new Error(_0x5cdf0e('0x27'));let _0x2d2072={},_0x1fa804=0x0;try{_0x2d2072=JSON[_0x5cdf0e('0x50')](process[_0x5cdf0e('0x6c')][0x3]);if(!_0x2d2072[_0x5cdf0e('0x5c')])throw new Error(_0x5cdf0e('0x38'));if(!_0x2d2072['binding'][_0x5cdf0e('0x2d')])throw new Error(_0x5cdf0e('0x72'));if(!_0x2d2072[_0x5cdf0e('0x5c')][_0x5cdf0e('0x11')])throw new Error(_0x5cdf0e('0x29'));_0x2d2072[_0x5cdf0e('0x5c')][_0x5cdf0e('0x73')]&&(_0x1fa804=0x1);if(!_0x2d2072['ListId'])throw new Error(_0x5cdf0e('0x51'));}catch(_0x166e0d){throw new Error(_0x5cdf0e('0x12'));}let _0x218f70=[];try{_0x218f70=_['map'](JSON[_0x5cdf0e('0x50')](process['argv'][0x4]),'id');}catch(_0x20d89e){logger['info'](_0x5cdf0e('0x46'));}main(_0x57dddb,_0x2d2072,_0x218f70,_0x1fa804);}validate(),process['on']('SIGINT',handleStop),process['on'](_0x18ee37('0x28'),handleUncaughtException); \ No newline at end of file diff --git a/server/components/integrations/configuration.js b/server/components/integrations/configuration.js index 36efe98..6b35c57 100644 --- a/server/components/integrations/configuration.js +++ b/server/components/integrations/configuration.js @@ -1 +1 @@ -const a832_0x55f2=['destcalleridnum','inbound','holdtime','calleridnum','Answer\x20Time','toLowerCase','membername','billableseconds','answertime','string','variable','agentcompleteAt','[xCALLY\x20Ticket]','Agent\x20Name','getSubjects','Agent\x20Number','***\x20Agent\x20Info\x20***','Caller\x20Name','Call\x20To','***\x20Call\x20Info\x20***','destcalleridname','voice','destexten','Date','agentcalledAt','getDescriptions','push','endtime','queue','Outbound\x20Call','Agent\x20Connect','Caller\x20Number','agentconnectAt','duration','calleridname','keyValue','Agent\x20Ring','uniqueid','Talk\x20Time','talktime','***\x20Time\x20Info\x20***','starttime','Agent\x20Complete'];(function(_0x36675c,_0x55f21c){const _0x4a0f9c=function(_0x352474){while(--_0x352474){_0x36675c['push'](_0x36675c['shift']());}};_0x4a0f9c(++_0x55f21c);}(a832_0x55f2,0x138));const a832_0x4a0f=function(_0x36675c,_0x55f21c){_0x36675c=_0x36675c-0x0;let _0x4a0f9c=a832_0x55f2[_0x36675c];return _0x4a0f9c;};const _0x12e9e4=a832_0x4a0f;'use strict';exports[_0x12e9e4('0x3')]=function(_0x352474,_0x18defd){const _0x2688ec=_0x12e9e4,_0x4fbc5b=[{'type':'string','content':_0x2688ec('0x1'),'variableName':null}];switch(_0x352474[_0x2688ec('0x25')]()){case'voice':switch(_0x18defd[_0x2688ec('0x25')]()){case _0x2688ec('0x21'):_0x4fbc5b[_0x2688ec('0xf')]({'type':_0x2688ec('0x2a'),'content':'','variableName':_0x2688ec('0x11')}),_0x4fbc5b[_0x2688ec('0xf')]({'type':_0x2688ec('0x2a'),'content':'','variableName':_0x2688ec('0x23')});break;case'outbound':_0x4fbc5b[_0x2688ec('0xf')]({'type':'string','content':_0x2688ec('0x12'),'variableName':null}),_0x4fbc5b['push']({'type':_0x2688ec('0x2a'),'content':'','variableName':_0x2688ec('0x20')});break;}}return _0x4fbc5b;},exports[_0x12e9e4('0xe')]=function(_0x833595,_0x4ae823){const _0x119ad6=_0x12e9e4;let _0x5f24b4=[];switch(_0x833595['toLowerCase']()){case _0x119ad6('0xa'):switch(_0x4ae823[_0x119ad6('0x25')]()){case _0x119ad6('0x21'):_0x5f24b4=[{'type':_0x119ad6('0x29'),'content':_0x119ad6('0x8'),'key':null,'keyType':null,'variableName':null},{'type':'keyValue','content':'','key':_0x119ad6('0x14'),'keyType':_0x119ad6('0x2a'),'variableName':_0x119ad6('0x23')},{'type':_0x119ad6('0x18'),'content':'','key':_0x119ad6('0x6'),'keyType':_0x119ad6('0x2a'),'variableName':_0x119ad6('0x17')},{'type':_0x119ad6('0x18'),'content':'','key':_0x119ad6('0x7'),'keyType':'variable','variableName':_0x119ad6('0xb')},{'type':_0x119ad6('0x18'),'content':'','key':'Queue','keyType':_0x119ad6('0x2a'),'variableName':_0x119ad6('0x11')},{'type':_0x119ad6('0x18'),'content':'','key':'UniqueId','keyType':_0x119ad6('0x2a'),'variableName':'uniqueid'},{'type':'keyValue','content':'','key':_0x119ad6('0xc'),'keyType':_0x119ad6('0x2a'),'variableName':'agentcalledAt'},{'type':_0x119ad6('0x29'),'content':_0x119ad6('0x5'),'key':null,'keyType':null,'variableName':null},{'type':_0x119ad6('0x18'),'content':'','key':_0x119ad6('0x2'),'keyType':'variable','variableName':_0x119ad6('0x9')},{'type':_0x119ad6('0x18'),'content':'','key':_0x119ad6('0x4'),'keyType':'variable','variableName':_0x119ad6('0x20')},{'type':_0x119ad6('0x29'),'content':_0x119ad6('0x1d'),'key':null,'keyType':null,'variableName':null},{'type':'keyValue','content':'','key':_0x119ad6('0x19'),'keyType':_0x119ad6('0x2a'),'variableName':_0x119ad6('0xd')},{'type':_0x119ad6('0x18'),'content':'','key':_0x119ad6('0x13'),'keyType':_0x119ad6('0x2a'),'variableName':_0x119ad6('0x15')},{'type':'keyValue','content':'','key':_0x119ad6('0x1f'),'keyType':_0x119ad6('0x2a'),'variableName':_0x119ad6('0x0')},{'type':_0x119ad6('0x18'),'content':'','key':'Hold\x20Time','keyType':_0x119ad6('0x2a'),'variableName':_0x119ad6('0x22')},{'type':_0x119ad6('0x18'),'content':'','key':_0x119ad6('0x1b'),'keyType':'variable','variableName':_0x119ad6('0x1c')}];break;case'outbound':_0x5f24b4=[{'type':_0x119ad6('0x29'),'content':_0x119ad6('0x8'),'variableName':null},{'type':'keyValue','content':'','key':'Called\x20Number','keyType':_0x119ad6('0x2a'),'keyContent':'','variableName':_0x119ad6('0x20')},{'type':_0x119ad6('0x18'),'content':'','key':'Member\x20Name','keyType':_0x119ad6('0x2a'),'keyContent':'','variableName':_0x119ad6('0x26')},{'type':_0x119ad6('0x18'),'content':'','key':'UniqueId','keyType':_0x119ad6('0x2a'),'keyContent':'','variableName':_0x119ad6('0x1a')},{'type':'keyValue','content':'','key':_0x119ad6('0xc'),'keyType':_0x119ad6('0x2a'),'keyContent':'','variableName':_0x119ad6('0x1e')},{'type':_0x119ad6('0x29'),'content':'***\x20Time\x20Info\x20***'},{'type':'keyValue','content':'','key':_0x119ad6('0x24'),'keyType':_0x119ad6('0x2a'),'keyContent':'','variableName':_0x119ad6('0x28')},{'type':'keyValue','content':'','key':'Complete\x20Time','keyType':_0x119ad6('0x2a'),'keyContent':'','variableName':_0x119ad6('0x10')},{'type':_0x119ad6('0x18'),'content':'','key':'Duration','keyType':'variable','keyContent':'','variableName':_0x119ad6('0x16')},{'type':_0x119ad6('0x18'),'content':'','key':'Billable\x20Time','keyType':_0x119ad6('0x2a'),'keyContent':'','variableName':_0x119ad6('0x27')}];break;}}return _0x5f24b4;}; \ No newline at end of file +const a832_0x4499=['calleridnum','agentcompleteAt','Answer\x20Time','Agent\x20Complete','answertime','Member\x20Name','Agent\x20Connect','agentconnectAt','uniqueid','destcalleridname','agentcalledAt','queue','getDescriptions','variable','***\x20Time\x20Info\x20***','Duration','inbound','Complete\x20Time','calleridname','outbound','talktime','Caller\x20Number','***\x20Agent\x20Info\x20***','string','Caller\x20Name','push','[xCALLY\x20Ticket]','Outbound\x20Call','membername','Agent\x20Ring','billableseconds','Date','***\x20Call\x20Info\x20***','voice','starttime','destcalleridnum','Agent\x20Number','toLowerCase','holdtime','Billable\x20Time','Agent\x20Name','UniqueId','keyValue'];(function(_0x3c58a4,_0x449953){const _0x1b8bb6=function(_0x50af6a){while(--_0x50af6a){_0x3c58a4['push'](_0x3c58a4['shift']());}};_0x1b8bb6(++_0x449953);}(a832_0x4499,0x9d));const a832_0x1b8b=function(_0x3c58a4,_0x449953){_0x3c58a4=_0x3c58a4-0x0;let _0x1b8bb6=a832_0x4499[_0x3c58a4];return _0x1b8bb6;};const _0x15b0e2=a832_0x1b8b;'use strict';exports['getSubjects']=function(_0x50af6a,_0xa324d){const _0x541603=a832_0x1b8b,_0x5bfb76=[{'type':'string','content':_0x541603('0x29'),'variableName':null}];switch(_0x50af6a['toLowerCase']()){case _0x541603('0x5'):switch(_0xa324d[_0x541603('0x9')]()){case _0x541603('0x1f'):_0x5bfb76[_0x541603('0x28')]({'type':'variable','content':'','variableName':_0x541603('0x1a')}),_0x5bfb76[_0x541603('0x28')]({'type':_0x541603('0x1c'),'content':'','variableName':_0x541603('0xf')});break;case _0x541603('0x22'):_0x5bfb76[_0x541603('0x28')]({'type':_0x541603('0x26'),'content':_0x541603('0x2a'),'variableName':null}),_0x5bfb76['push']({'type':'variable','content':'','variableName':'destcalleridnum'});break;}}return _0x5bfb76;},exports[_0x15b0e2('0x1b')]=function(_0x79cf47,_0x1d3dad){const _0xba2bab=_0x15b0e2;let _0x240101=[];switch(_0x79cf47['toLowerCase']()){case'voice':switch(_0x1d3dad[_0xba2bab('0x9')]()){case'inbound':_0x240101=[{'type':_0xba2bab('0x26'),'content':_0xba2bab('0x4'),'key':null,'keyType':null,'variableName':null},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0x24'),'keyType':_0xba2bab('0x1c'),'variableName':'calleridnum'},{'type':'keyValue','content':'','key':_0xba2bab('0x27'),'keyType':_0xba2bab('0x1c'),'variableName':_0xba2bab('0x21')},{'type':_0xba2bab('0xe'),'content':'','key':'Call\x20To','keyType':_0xba2bab('0x1c'),'variableName':'destexten'},{'type':_0xba2bab('0xe'),'content':'','key':'Queue','keyType':_0xba2bab('0x1c'),'variableName':_0xba2bab('0x1a')},{'type':'keyValue','content':'','key':_0xba2bab('0xd'),'keyType':_0xba2bab('0x1c'),'variableName':_0xba2bab('0x17')},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0x3'),'keyType':'variable','variableName':_0xba2bab('0x19')},{'type':'string','content':_0xba2bab('0x25'),'key':null,'keyType':null,'variableName':null},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0xc'),'keyType':_0xba2bab('0x1c'),'variableName':_0xba2bab('0x18')},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0x8'),'keyType':_0xba2bab('0x1c'),'variableName':_0xba2bab('0x7')},{'type':_0xba2bab('0x26'),'content':_0xba2bab('0x1d'),'key':null,'keyType':null,'variableName':null},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0x1'),'keyType':_0xba2bab('0x1c'),'variableName':_0xba2bab('0x19')},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0x15'),'keyType':'variable','variableName':_0xba2bab('0x16')},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0x12'),'keyType':_0xba2bab('0x1c'),'variableName':_0xba2bab('0x10')},{'type':_0xba2bab('0xe'),'content':'','key':'Hold\x20Time','keyType':_0xba2bab('0x1c'),'variableName':_0xba2bab('0xa')},{'type':'keyValue','content':'','key':'Talk\x20Time','keyType':'variable','variableName':_0xba2bab('0x23')}];break;case _0xba2bab('0x22'):_0x240101=[{'type':_0xba2bab('0x26'),'content':_0xba2bab('0x4'),'variableName':null},{'type':_0xba2bab('0xe'),'content':'','key':'Called\x20Number','keyType':_0xba2bab('0x1c'),'keyContent':'','variableName':_0xba2bab('0x7')},{'type':'keyValue','content':'','key':_0xba2bab('0x14'),'keyType':'variable','keyContent':'','variableName':_0xba2bab('0x0')},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0xd'),'keyType':_0xba2bab('0x1c'),'keyContent':'','variableName':'uniqueid'},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0x3'),'keyType':'variable','keyContent':'','variableName':_0xba2bab('0x6')},{'type':_0xba2bab('0x26'),'content':_0xba2bab('0x1d')},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0x11'),'keyType':'variable','keyContent':'','variableName':_0xba2bab('0x13')},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0x20'),'keyType':_0xba2bab('0x1c'),'keyContent':'','variableName':'endtime'},{'type':'keyValue','content':'','key':_0xba2bab('0x1e'),'keyType':'variable','keyContent':'','variableName':'duration'},{'type':_0xba2bab('0xe'),'content':'','key':_0xba2bab('0xb'),'keyType':_0xba2bab('0x1c'),'keyContent':'','variableName':_0xba2bab('0x2')}];break;}}return _0x240101;}; \ No newline at end of file diff --git a/server/components/interaction/service.js b/server/components/interaction/service.js index 91fe40c..0c63a9e 100644 --- a/server/components/interaction/service.js +++ b/server/components/interaction/service.js @@ -1 +1 @@ -const a833_0x5383=['update','mail-interactions','null','openchannel-interactions','unknown','fax-interactions','name','tracked','role','Interaction','InteractionId','../../config/logger','user','upperFirst','catch','error','query','html','stringify','../../mysqldb','toUpperCase','omit','lodash','fax','phone','whatsapp-interactions','then','findOne','body'];(function(_0x19b33b,_0x538321){const _0x4fac4c=function(_0x4cff28){while(--_0x4cff28){_0x19b33b['push'](_0x19b33b['shift']());}};_0x4fac4c(++_0x538321);}(a833_0x5383,0x8a));const a833_0x4fac=function(_0x19b33b,_0x538321){_0x19b33b=_0x19b33b-0x0;let _0x4fac4c=a833_0x5383[_0x19b33b];return _0x4fac4c;};const _0x2f981e=a833_0x4fac;'use strict';const _=require(_0x2f981e('0x0')),db=require(_0x2f981e('0x1a'))['db'],loggers={'openchannel':require(_0x2f981e('0x12'))(_0x2f981e('0xa')),'mail':require('../../config/logger')(_0x2f981e('0x8')),'fax':require(_0x2f981e('0x12'))(_0x2f981e('0xc')),'sms':require(_0x2f981e('0x12'))('sms-interactions'),'chat':require(_0x2f981e('0x12'))('chat-interactions'),'whatsapp':require(_0x2f981e('0x12'))(_0x2f981e('0x3'))};function getInteractionId(_0x4cff28,_0x172f7a,_0x1d2e42){const _0x33f7f1=_0x2f981e;if(_0x4cff28&&_0x4cff28[_[_0x33f7f1('0x14')](_0x1d2e42)+_0x33f7f1('0x11')])return _0x4cff28[_[_0x33f7f1('0x14')](_0x1d2e42)+_0x33f7f1('0x11')];else{if(_0x4cff28&&_0x4cff28['id'])return _0x4cff28['id'];else return _0x172f7a&&_0x172f7a['id']?_0x172f7a['id']:_0x33f7f1('0xb');}}function log(_0x58ec2d,_0x5ce0ee,_0x3bf1ec,_0x3e4390,_0x3781ce,_0x107115){const _0x1500f0=_0x2f981e;loggers[_0x3781ce['toLowerCase']()][_0x58ec2d]('[%s]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s',_0x107115[_0x1500f0('0x1b')](),_0x5ce0ee?_0x5ce0ee['id']:null,_0x5ce0ee?_0x5ce0ee[_0x1500f0('0xd')]:null,_0x5ce0ee?_0x5ce0ee[_0x1500f0('0xf')]:null,getInteractionId(_0x3bf1ec,_0x3e4390,_0x3781ce),_0x3bf1ec?JSON[_0x1500f0('0x19')](_0x3bf1ec):_0x1500f0('0x9'));}function updateUser(_0x48d08d,_0x3c8898,_0x5a8fd7,_0x118135,_0x1a150f){const _0x5356ca=_0x2f981e;db[_[_0x5356ca('0x14')](_0x118135)+_0x5356ca('0x10')][_0x5356ca('0x5')]({'where':{'id':getInteractionId(_0x3c8898,_0x5a8fd7,_0x118135)}})[_0x5356ca('0x4')](function(_0x122939){const _0x3814f5=_0x5356ca;if(_0x122939)return _0x122939[_0x3814f5('0x7')]({'UserId':_0x48d08d?_0x48d08d['id']:null});})['then'](function(_0x51ecb4){_0x51ecb4&&log('info',_0x48d08d,_0x3c8898,_0x5a8fd7,_0x118135,_0x1a150f);})[_0x5356ca('0x15')](function(){const _0x4b220a=_0x5356ca;log(_0x4b220a('0x16'),_0x48d08d,_0x3c8898,_0x5a8fd7,_0x118135,_0x1a150f);});}exports[_0x2f981e('0xe')]=function(_0x3f6806,_0x28dce1){return function(_0x43a398,_0x4f2ece,_0x4f6017){const _0x34ddb7=a833_0x4fac,_0x255f68=_0x43a398[_0x34ddb7('0x13')];let _0x1274a9={};const _0x2b448a=_0x43a398[_0x34ddb7('0x17')];_0x1274a9&&(_0x1274a9=_['clone'](_0x43a398[_0x34ddb7('0x6')]),_0x1274a9=_[_0x34ddb7('0x1c')](_0x1274a9,[_0x34ddb7('0x6'),_0x34ddb7('0x18'),_0x34ddb7('0x2'),_0x34ddb7('0x1'),'mobile'])),updateUser(_0x255f68,_0x1274a9,_0x2b448a,_0x3f6806,_0x28dce1),_0x4f6017(null);};}; \ No newline at end of file +const a833_0x1e1a=['lodash','stringify','body','user','fax','mobile','upperFirst','mail-interactions','InteractionId','toLowerCase','query','omit','tracked','unknown','chat-interactions','then','html','whatsapp-interactions','findOne','toUpperCase','Interaction','error','catch','../../config/logger','phone','fax-interactions','sms-interactions','update'];(function(_0x4b86c4,_0x1e1a3c){const _0x467772=function(_0x15265a){while(--_0x15265a){_0x4b86c4['push'](_0x4b86c4['shift']());}};_0x467772(++_0x1e1a3c);}(a833_0x1e1a,0x199));const a833_0x4677=function(_0x4b86c4,_0x1e1a3c){_0x4b86c4=_0x4b86c4-0x0;let _0x467772=a833_0x1e1a[_0x4b86c4];return _0x467772;};const _0x1c645a=a833_0x4677;'use strict';const _=require(_0x1c645a('0xb')),db=require('../../mysqldb')['db'],loggers={'openchannel':require('../../config/logger')('openchannel-interactions'),'mail':require(_0x1c645a('0x6'))(_0x1c645a('0x12')),'fax':require(_0x1c645a('0x6'))(_0x1c645a('0x8')),'sms':require('../../config/logger')(_0x1c645a('0x9')),'chat':require(_0x1c645a('0x6'))(_0x1c645a('0x19')),'whatsapp':require('../../config/logger')(_0x1c645a('0x0'))};function getInteractionId(_0x15265a,_0x19a1ac,_0x1d3e2d){const _0x594a8d=_0x1c645a;if(_0x15265a&&_0x15265a[_[_0x594a8d('0x11')](_0x1d3e2d)+_0x594a8d('0x13')])return _0x15265a[_[_0x594a8d('0x11')](_0x1d3e2d)+_0x594a8d('0x13')];else{if(_0x15265a&&_0x15265a['id'])return _0x15265a['id'];else return _0x19a1ac&&_0x19a1ac['id']?_0x19a1ac['id']:_0x594a8d('0x18');}}function log(_0x5dda02,_0x18f2c3,_0x1b9ca1,_0x582a2e,_0x281400,_0x15911c){const _0x301ded=_0x1c645a;loggers[_0x281400[_0x301ded('0x14')]()][_0x5dda02]('[%s]\x20id=%s\x20name=%s\x20role=%s\x20interaction=%s\x20body=%s',_0x15911c[_0x301ded('0x2')](),_0x18f2c3?_0x18f2c3['id']:null,_0x18f2c3?_0x18f2c3['name']:null,_0x18f2c3?_0x18f2c3['role']:null,getInteractionId(_0x1b9ca1,_0x582a2e,_0x281400),_0x1b9ca1?JSON[_0x301ded('0xc')](_0x1b9ca1):'null');}function updateUser(_0x3ce4bf,_0x5d8fa5,_0x585b0b,_0x572a30,_0x4300f8){const _0x6c00be=_0x1c645a;db[_[_0x6c00be('0x11')](_0x572a30)+_0x6c00be('0x3')][_0x6c00be('0x1')]({'where':{'id':getInteractionId(_0x5d8fa5,_0x585b0b,_0x572a30)}})[_0x6c00be('0x1a')](function(_0x423268){const _0x110f9e=_0x6c00be;if(_0x423268)return _0x423268[_0x110f9e('0xa')]({'UserId':_0x3ce4bf?_0x3ce4bf['id']:null});})[_0x6c00be('0x1a')](function(_0x50797b){_0x50797b&&log('info',_0x3ce4bf,_0x5d8fa5,_0x585b0b,_0x572a30,_0x4300f8);})[_0x6c00be('0x5')](function(){const _0x5bf6f0=_0x6c00be;log(_0x5bf6f0('0x4'),_0x3ce4bf,_0x5d8fa5,_0x585b0b,_0x572a30,_0x4300f8);});}exports[_0x1c645a('0x17')]=function(_0x29333e,_0x493b0c){return function(_0x5ca5b0,_0x3d9828,_0x791c28){const _0x5e7109=a833_0x4677,_0x5ef477=_0x5ca5b0[_0x5e7109('0xe')];let _0x4c272d={};const _0x238359=_0x5ca5b0[_0x5e7109('0x15')];_0x4c272d&&(_0x4c272d=_['clone'](_0x5ca5b0[_0x5e7109('0xd')]),_0x4c272d=_[_0x5e7109('0x16')](_0x4c272d,[_0x5e7109('0xd'),_0x5e7109('0x1b'),_0x5e7109('0x7'),_0x5e7109('0xf'),_0x5e7109('0x10')])),updateUser(_0x5ef477,_0x4c272d,_0x238359,_0x29333e,_0x493b0c),_0x791c28(null);};}; \ No newline at end of file diff --git a/server/components/license/service.js b/server/components/license/service.js index d532667..b115c96 100644 --- a/server/components/license/service.js +++ b/server/components/license/service.js @@ -1 +1 @@ -const a834_0x2b09=['../encryptor','composable-middleware','sequelize','findOne','admin','License','user','status','format','use','util','json','Maximum\x20%s\x20limit\x20have\x20been\x20reached','then','../../mysqldb','User','users'];(function(_0x359905,_0x2b092d){const _0x465f61=function(_0x5f2d6c){while(--_0x5f2d6c){_0x359905['push'](_0x359905['shift']());}};_0x465f61(++_0x2b092d);}(a834_0x2b09,0x1bf));const a834_0x465f=function(_0x359905,_0x2b092d){_0x359905=_0x359905-0x0;let _0x465f61=a834_0x2b09[_0x359905];return _0x465f61;};const _0x405d4d=a834_0x465f;'use strict';const util=require(_0x405d4d('0x5')),compose=require(_0x405d4d('0xd')),{Op}=require(_0x405d4d('0xe')),db=require(_0x405d4d('0x9'))['db'],{getValueFromLicense}=require(_0x405d4d('0xc'));function isLimit(_0x5f2d6c,_0x53e217,_0x35e31c,_0x3a926b){const _0x2941a6=_0x405d4d;let _0x534691=_0x53e217;return compose()[_0x2941a6('0x4')](function(_0x49f2ed,_0x12e74d,_0x214915){const _0x3199c9=_0x2941a6;return db[_0x3199c9('0x0')][_0x3199c9('0xf')]({'where':{'id':0x1},'raw':!![]})[_0x3199c9('0x8')](function(_0x16a7ee){const _0x76a34a=getValueFromLicense(_0x5f2d6c,_0x16a7ee);return _0x76a34a?_0x76a34a:_0x534691;})[_0x3199c9('0x8')](function(_0x4f6c0d){return _0x534691=_0x4f6c0d,_0x35e31c['count'](_0x3a926b);})[_0x3199c9('0x8')](function(_0x386143){const _0x3278be=_0x3199c9;if(_0x386143>=_0x534691)return _0x12e74d[_0x3278be('0x2')](0x193)[_0x3278be('0x6')]({'message':util[_0x3278be('0x3')](_0x3278be('0x7'),_0x5f2d6c)});_0x214915();})['catch'](function(_0x5065e6){_0x214915(_0x5065e6);});});}function isUserLimit(){const _0x553eb9=_0x405d4d;return isLimit(_0x553eb9('0xb'),0x1,db[_0x553eb9('0xa')],{'where':{[Op['or']]:[{'role':_0x553eb9('0x10')},{'role':_0x553eb9('0x1')}]}});}exports['isUserLimit']=isUserLimit; \ No newline at end of file +const a834_0x46d6=['users','isUserLimit','License','User','json','count','user','format','util','composable-middleware','admin','Maximum\x20%s\x20limit\x20have\x20been\x20reached','use','then','../../mysqldb'];(function(_0x1589d7,_0x46d665){const _0x3f2950=function(_0x5afd2c){while(--_0x5afd2c){_0x1589d7['push'](_0x1589d7['shift']());}};_0x3f2950(++_0x46d665);}(a834_0x46d6,0x186));const a834_0x3f29=function(_0x1589d7,_0x46d665){_0x1589d7=_0x1589d7-0x0;let _0x3f2950=a834_0x46d6[_0x1589d7];return _0x3f2950;};const _0x4cdaea=a834_0x3f29;'use strict';const util=require(_0x4cdaea('0x8')),compose=require(_0x4cdaea('0x9')),{Op}=require('sequelize'),db=require(_0x4cdaea('0xe'))['db'],{getValueFromLicense}=require('../encryptor');function isLimit(_0x5afd2c,_0x205180,_0x13b42f,_0x2ad843){const _0x139e62=_0x4cdaea;let _0x5463d9=_0x205180;return compose()[_0x139e62('0xc')](function(_0x181fb1,_0x352cad,_0x357836){const _0x5c3974=_0x139e62;return db[_0x5c3974('0x2')]['findOne']({'where':{'id':0x1},'raw':!![]})[_0x5c3974('0xd')](function(_0x2981fd){const _0x42e8ea=getValueFromLicense(_0x5afd2c,_0x2981fd);return _0x42e8ea?_0x42e8ea:_0x5463d9;})['then'](function(_0x3d9a57){const _0x2288a3=_0x5c3974;return _0x5463d9=_0x3d9a57,_0x13b42f[_0x2288a3('0x5')](_0x2ad843);})[_0x5c3974('0xd')](function(_0x3b09ca){const _0x2fe4d6=_0x5c3974;if(_0x3b09ca>=_0x5463d9)return _0x352cad['status'](0x193)[_0x2fe4d6('0x4')]({'message':util[_0x2fe4d6('0x7')](_0x2fe4d6('0xb'),_0x5afd2c)});_0x357836();})['catch'](function(_0x58e4c2){_0x357836(_0x58e4c2);});});}function isUserLimit(){const _0x47984a=_0x4cdaea;return isLimit(_0x47984a('0x0'),0x1,db[_0x47984a('0x3')],{'where':{[Op['or']]:[{'role':_0x47984a('0xa')},{'role':_0x47984a('0x6')}]}});}exports[_0x4cdaea('0x1')]=isUserLimit; \ No newline at end of file diff --git a/server/components/parsers/advancedSearch.js b/server/components/parsers/advancedSearch.js index 1010fce..898b88c 100644 --- a/server/components/parsers/advancedSearch.js +++ b/server/components/parsers/advancedSearch.js @@ -1 +1 @@ -const a835_0x4d1d=['$in','shift','includes','hours','$between','\x20OR\x20','<=\x20?','field','LIKE\x20?','$substring','replace','seconds','$notIn','text','match','$startsWith','$lte','$gt','YYYY-MM-DD','>\x20?','days','[$and]','operator','conditions','$eq','$ne','buildExpression','split','>=\x20?','value','filter','forEach','lodash','castTo','add','$lt','push','format','minutes','and','NOT\x20IN\x20?','slice','parseSearch','[$or]','startsWith','\x20IS\x20NULL)','indexOf','DATE','=\x20?','map','sqlOperator','BETWEEN\x20?\x20AND\x20?','start','<>\x20?','moment'];(function(_0x5b10ed,_0x4d1d46){const _0x4e7992=function(_0x6ccc2){while(--_0x6ccc2){_0x5b10ed['push'](_0x5b10ed['shift']());}};_0x4e7992(++_0x4d1d46);}(a835_0x4d1d,0x151));const a835_0x4e79=function(_0x5b10ed,_0x4d1d46){_0x5b10ed=_0x5b10ed-0x0;let _0x4e7992=a835_0x4d1d[_0x5b10ed];return _0x4e7992;};const _0x221b11=a835_0x4e79;'use strict';const _=require(_0x221b11('0x19')),moment=require(_0x221b11('0x2f'));exports[_0x221b11('0x23')]=function(_0x6ccc2){const _0xcae97e=_0x221b11,_0x45576b={'conditions':[]};_0x45576b[_0xcae97e('0x2b')]=_[_0xcae97e('0x25')](_0x6ccc2,_0xcae97e('0x24'))?'or':_0xcae97e('0x20');const _0x34b759=_0x6ccc2[_0xcae97e('0x3')](_0xcae97e('0xe'),'')[_0xcae97e('0x3')](_0xcae97e('0x24'),'')[_0xcae97e('0x14')]('||');for(let _0x1885fb=0x0;_0x1885fb<_0x34b759['length'];_0x1885fb++){const _0x5e1767=_0x34b759[_0x1885fb]['split'](':='),_0x35a195=_0x5e1767[0x0],_0x2fe63=_0x5e1767[_0xcae97e('0x22')](0x1);_0x2fe63[_0xcae97e('0x18')](function(_0x30ace2){const _0x20ee6d=_0xcae97e,_0x1b681e=_0x30ace2[_0x20ee6d('0x14')]('[')['shift'](),_0x9201b1=_0x30ace2[_0x20ee6d('0x7')](/\[(.*?)\]/g);_0x9201b1['forEach'](function(_0x4ebffa){const _0x3b4c95=_0x20ee6d,_0x4913cd=_0x4ebffa[_0x3b4c95('0x14')]('[')[_0x3b4c95('0x17')](function(_0x4df0e4){const _0x1d446b=_0x3b4c95;return _0x4df0e4[_0x1d446b('0x27')](']')>-0x1;})[_0x3b4c95('0x2a')](function(_0x5ba7aa){const _0xd748f9=_0x3b4c95;return _0x5ba7aa[_0xd748f9('0x14')](']')[0x0];})[0x0];_0x45576b[_0x3b4c95('0x10')][_0x3b4c95('0x1d')]({'field':_0x35a195,'operator':_0x1b681e,'value':_0x4913cd});});});}return _0x45576b;},exports[_0x221b11('0x13')]=function(_0x2b54df,_0x410c86,_0x559ec8){const _0x3d9445=_0x221b11,_0x220a57={};if(_0x410c86===_0x3d9445('0x28')){if(_0x559ec8['operator']===_0x3d9445('0x11'))_0x559ec8[_0x3d9445('0xf')]=_0x3d9445('0x34'),_0x559ec8[_0x3d9445('0x16')]+=','+_0x559ec8[_0x3d9445('0x16')];else _[_0x3d9445('0x32')]([_0x3d9445('0xa'),'$lte'],_0x559ec8[_0x3d9445('0xf')])&&(_0x559ec8[_0x3d9445('0x16')]=moment(_0x559ec8[_0x3d9445('0x16')])[_0x3d9445('0x1b')](0x1,_0x3d9445('0xd'))[_0x3d9445('0x1e')](_0x3d9445('0xb')));}_0x559ec8[_0x3d9445('0x1a')]?(_0x410c86=_0x559ec8[_0x3d9445('0x1a')],_0x220a57[_0x3d9445('0x6')]='CAST('+_0x2b54df+'.'+_0x559ec8[_0x3d9445('0x0')]+'\x20AS\x20'+_0x559ec8[_0x3d9445('0x1a')]+')\x20'+parseOperator(_0x559ec8[_0x3d9445('0xf')])):_0x220a57[_0x3d9445('0x6')]=_0x2b54df+'.'+_0x559ec8[_0x3d9445('0x0')]+'\x20'+parseOperator(_0x559ec8[_0x3d9445('0xf')]);if(_['includes']([_0x3d9445('0x12'),_0x3d9445('0x5')],_0x559ec8[_0x3d9445('0xf')]))_0x220a57['text']='('+_0x220a57[_0x3d9445('0x6')]+_0x3d9445('0x35')+_0x2b54df+'.'+_0x559ec8['field']+_0x3d9445('0x26');return _0x220a57[_0x3d9445('0x16')]=parseValue(_0x410c86,_0x559ec8['operator'],_0x559ec8[_0x3d9445('0x16')]),_0x220a57;};function parseOperator(_0x577237){const _0x1d825a=_0x221b11;let _0x3050c5;switch(_0x577237){case _0x1d825a('0x30'):_0x3050c5='IN\x20?';break;case _0x1d825a('0x5'):_0x3050c5=_0x1d825a('0x21');break;case'$eq':_0x3050c5=_0x1d825a('0x29');break;case _0x1d825a('0x12'):_0x3050c5=_0x1d825a('0x2e');break;case _0x1d825a('0x2'):case _0x1d825a('0x8'):case'$endsWith':_0x3050c5=_0x1d825a('0x1');break;case _0x1d825a('0x1c'):_0x3050c5='<\x20?';break;case _0x1d825a('0xa'):_0x3050c5=_0x1d825a('0xc');break;case _0x1d825a('0x9'):_0x3050c5=_0x1d825a('0x36');break;case'$gte':_0x3050c5=_0x1d825a('0x15');break;case _0x1d825a('0x34'):_0x3050c5=_0x1d825a('0x2c');break;}return _0x3050c5;}function parseValue(_0xbecf63,_0x513c00,_0x56f97e){const _0x12f20b=_0x221b11;let _0xdb2055={'start':undefined,'end':undefined};switch(_0x513c00){case _0x12f20b('0x30'):case _0x12f20b('0x5'):_0xdb2055[_0x12f20b('0x2d')]=_0x56f97e[_0x12f20b('0x14')](',');break;case'$substring':_0xdb2055[_0x12f20b('0x2d')]='%'+_0x56f97e+'%';break;case _0x12f20b('0x8'):_0xdb2055[_0x12f20b('0x2d')]=_0x56f97e+'%';break;case'$endsWith':_0xdb2055[_0x12f20b('0x2d')]='%'+_0x56f97e;break;case _0x12f20b('0x34'):{const _0x3bc150=_0x529ffb[_0x12f20b('0x14')](',');let _0x529ffb=_0x3bc150[_0x12f20b('0x31')](),_0x121d2=_0x3bc150['pop']();_0xbecf63===_0x12f20b('0x28')&&(_0x529ffb=moment(_0x529ffb)['utcOffset'](0x0,!![])[_0x12f20b('0x1e')](),_0x121d2=moment(_0x121d2)['utcOffset'](0x0,!![])[_0x12f20b('0x1b')](0x17,_0x12f20b('0x33'))[_0x12f20b('0x1b')](0x3b,_0x12f20b('0x1f'))[_0x12f20b('0x1b')](0x3b,_0x12f20b('0x4'))[_0x12f20b('0x1e')]()),_0xdb2055={'start':_0x529ffb,'end':_0x121d2};}break;default:_0xdb2055[_0x12f20b('0x2d')]=_0x56f97e;break;}return _0xdb2055;} \ No newline at end of file +const a835_0x3ddb=['$between','lodash','$substring','\x20OR\x20','$eq','<\x20?','$startsWith','value','push','\x20AS\x20','$gt','forEach','$lt','text','>=\x20?','sqlOperator','CAST(','startsWith','DATE','and','$in','field','$ne','utcOffset','moment','add','$gte','slice','$endsWith','castTo','start','$notIn','replace','operator','NOT\x20IN\x20?','minutes','filter','pop','days','format','includes','shift','[$and]','LIKE\x20?','hours','split','length','[$or]','<=\x20?','$lte'];(function(_0x59c2c0,_0x3ddbd8){const _0x5d6bcf=function(_0x2c5b09){while(--_0x2c5b09){_0x59c2c0['push'](_0x59c2c0['shift']());}};_0x5d6bcf(++_0x3ddbd8);}(a835_0x3ddb,0xee));const a835_0x5d6b=function(_0x59c2c0,_0x3ddbd8){_0x59c2c0=_0x59c2c0-0x0;let _0x5d6bcf=a835_0x3ddb[_0x59c2c0];return _0x5d6bcf;};const _0x6bfb41=a835_0x5d6b;'use strict';const _=require(_0x6bfb41('0xd')),moment=require(_0x6bfb41('0x24'));exports['parseSearch']=function(_0x2c5b09){const _0x33400b=_0x6bfb41,_0x2eab={'conditions':[]};_0x2eab[_0x33400b('0x1b')]=_[_0x33400b('0x1d')](_0x2c5b09,_0x33400b('0x9'))?'or':_0x33400b('0x1f');const _0xbec82c=_0x2c5b09[_0x33400b('0x2c')](_0x33400b('0x4'),'')[_0x33400b('0x2c')](_0x33400b('0x9'),'')[_0x33400b('0x7')]('||');for(let _0x19e3bd=0x0;_0x19e3bd<_0xbec82c[_0x33400b('0x8')];_0x19e3bd++){const _0x1b7f30=_0xbec82c[_0x19e3bd][_0x33400b('0x7')](':='),_0x487a35=_0x1b7f30[0x0],_0x10b99b=_0x1b7f30[_0x33400b('0x27')](0x1);_0x10b99b['forEach'](function(_0x8b6a88){const _0x188675=_0x33400b,_0x434538=_0x8b6a88['split']('[')[_0x188675('0x3')](),_0x5ce2bb=_0x8b6a88['match'](/\[(.*?)\]/g);_0x5ce2bb[_0x188675('0x17')](function(_0x5675ef){const _0x20969a=_0x188675,_0x297f51=_0x5675ef[_0x20969a('0x7')]('[')[_0x20969a('0x30')](function(_0x43d006){return _0x43d006['indexOf'](']')>-0x1;})['map'](function(_0x4c3319){const _0x1439d0=_0x20969a;return _0x4c3319[_0x1439d0('0x7')](']')[0x0];})[0x0];_0x2eab['conditions'][_0x20969a('0x14')]({'field':_0x487a35,'operator':_0x434538,'value':_0x297f51});});});}return _0x2eab;},exports['buildExpression']=function(_0x5011b7,_0x185ab7,_0x5d87ea){const _0x53735a=_0x6bfb41,_0x25f3e5={};if(_0x185ab7===_0x53735a('0x1e')){if(_0x5d87ea[_0x53735a('0x2d')]===_0x53735a('0x10'))_0x5d87ea['operator']=_0x53735a('0xc'),_0x5d87ea['value']+=','+_0x5d87ea[_0x53735a('0x13')];else _[_0x53735a('0x2')]([_0x53735a('0x16'),_0x53735a('0xb')],_0x5d87ea['operator'])&&(_0x5d87ea[_0x53735a('0x13')]=moment(_0x5d87ea[_0x53735a('0x13')])[_0x53735a('0x25')](0x1,_0x53735a('0x0'))[_0x53735a('0x1')]('YYYY-MM-DD'));}_0x5d87ea[_0x53735a('0x29')]?(_0x185ab7=_0x5d87ea[_0x53735a('0x29')],_0x25f3e5[_0x53735a('0x19')]=_0x53735a('0x1c')+_0x5011b7+'.'+_0x5d87ea[_0x53735a('0x21')]+_0x53735a('0x15')+_0x5d87ea[_0x53735a('0x29')]+')\x20'+parseOperator(_0x5d87ea[_0x53735a('0x2d')])):_0x25f3e5[_0x53735a('0x19')]=_0x5011b7+'.'+_0x5d87ea[_0x53735a('0x21')]+'\x20'+parseOperator(_0x5d87ea[_0x53735a('0x2d')]);if(_[_0x53735a('0x2')]([_0x53735a('0x22'),'$notIn'],_0x5d87ea[_0x53735a('0x2d')]))_0x25f3e5['text']='('+_0x25f3e5['text']+_0x53735a('0xf')+_0x5011b7+'.'+_0x5d87ea['field']+'\x20IS\x20NULL)';return _0x25f3e5[_0x53735a('0x13')]=parseValue(_0x185ab7,_0x5d87ea[_0x53735a('0x2d')],_0x5d87ea[_0x53735a('0x13')]),_0x25f3e5;};function parseOperator(_0x486d0a){const _0x4496da=_0x6bfb41;let _0x131367;switch(_0x486d0a){case _0x4496da('0x20'):_0x131367='IN\x20?';break;case'$notIn':_0x131367=_0x4496da('0x2e');break;case'$eq':_0x131367='=\x20?';break;case _0x4496da('0x22'):_0x131367='<>\x20?';break;case _0x4496da('0xe'):case _0x4496da('0x12'):case _0x4496da('0x28'):_0x131367=_0x4496da('0x5');break;case _0x4496da('0x18'):_0x131367=_0x4496da('0x11');break;case _0x4496da('0x16'):_0x131367='>\x20?';break;case _0x4496da('0xb'):_0x131367=_0x4496da('0xa');break;case _0x4496da('0x26'):_0x131367=_0x4496da('0x1a');break;case _0x4496da('0xc'):_0x131367='BETWEEN\x20?\x20AND\x20?';break;}return _0x131367;}function parseValue(_0x37225b,_0xaffc5d,_0x521e92){const _0x21e85f=_0x6bfb41;let _0x62dcc8={'start':undefined,'end':undefined};switch(_0xaffc5d){case _0x21e85f('0x20'):case _0x21e85f('0x2b'):_0x62dcc8[_0x21e85f('0x2a')]=_0x521e92['split'](',');break;case _0x21e85f('0xe'):_0x62dcc8[_0x21e85f('0x2a')]='%'+_0x521e92+'%';break;case _0x21e85f('0x12'):_0x62dcc8[_0x21e85f('0x2a')]=_0x521e92+'%';break;case _0x21e85f('0x28'):_0x62dcc8[_0x21e85f('0x2a')]='%'+_0x521e92;break;case'$between':{const _0x5927b9=_0x1d270['split'](',');let _0x1d270=_0x5927b9[_0x21e85f('0x3')](),_0x4ed2f0=_0x5927b9[_0x21e85f('0x31')]();_0x37225b===_0x21e85f('0x1e')&&(_0x1d270=moment(_0x1d270)['utcOffset'](0x0,!![])[_0x21e85f('0x1')](),_0x4ed2f0=moment(_0x4ed2f0)[_0x21e85f('0x23')](0x0,!![])[_0x21e85f('0x25')](0x17,_0x21e85f('0x6'))[_0x21e85f('0x25')](0x3b,_0x21e85f('0x2f'))[_0x21e85f('0x25')](0x3b,'seconds')[_0x21e85f('0x1')]()),_0x62dcc8={'start':_0x1d270,'end':_0x4ed2f0};}break;default:_0x62dcc8[_0x21e85f('0x2a')]=_0x521e92;break;}return _0x62dcc8;} \ No newline at end of file diff --git a/server/components/parsers/qs.js b/server/components/parsers/qs.js index 3b5cfda..1fa588b 100644 --- a/server/components/parsers/qs.js +++ b/server/components/parsers/qs.js @@ -1 +1 @@ -const a836_0x4f96=['DESC','limit','isString','col','sort','DATE','format','priority','join','substr','getFullTextValue','fields','utc','subtract','forEach','lodash','lte','type','isNumeric','isEmpty','isArray','split','map','isEmail','push','undefined','toString','cast','ASC','^[+]?[0-9]*$','parse','$gte','filters','unsigned','sequelize','omit','unset','match','length','isObject','moment','forOwn'];(function(_0x361620,_0x4f9682){const _0x1204e4=function(_0x2fddc9){while(--_0x2fddc9){_0x361620['push'](_0x361620['shift']());}};_0x1204e4(++_0x4f9682);}(a836_0x4f96,0x142));const a836_0x1204=function(_0x361620,_0x4f9682){_0x361620=_0x361620-0x0;let _0x1204e4=a836_0x4f96[_0x361620];return _0x1204e4;};const _0x230813=a836_0x1204;'use strict';const _=require(_0x230813('0x1d')),sequelize=require(_0x230813('0x6')),moment=require(_0x230813('0xc')),Op=sequelize['Op'],LIMIT_VALUE=0xfa;exports[_0x230813('0x19')]=function(_0x2fddc9){const _0x281526=_0x230813;let _0x4d648a=null;return _0x2fddc9&&(_0x4d648a=_0x2fddc9[_0x281526('0x23')](',')),_0x4d648a;},exports[_0x230813('0x4')]=function(_0x4401f8,_0x515414){const _0x290973=_0x230813,_0x425c62={};return!_[_0x290973('0x21')](_0x4401f8)&&_[_0x290973('0xd')](_0x4401f8,function(_0xad0bdb,_0x435084){const _0x131db6=_0x290973;try{if(_0x515414){const _0x24ff6e=_['find'](_0x515414,{'name':_0x435084})||{};if(_0x24ff6e[_0x131db6('0x1f')]===_0x131db6('0x13')&&_['isPlainObject'](_0xad0bdb)){const _0x575032=JSON[_0x131db6('0x2')](_0xad0bdb),_0x12de39={[Op['gte']]:moment(moment(_0x575032[_0x131db6('0x3')])[_0x131db6('0x14')]('YYYY-MM-DD'))[_0x131db6('0x1a')]()['format'](),[Op[_0x131db6('0x1e')]]:moment(moment(_0x575032['$lte'])[_0x131db6('0x14')]('YYYY-MM-DD'))['utc']()[_0x131db6('0x1b')](0x1,'s')['format']()};_0x425c62[_0x435084]=_0x12de39;}else _0x425c62[_0x435084]=_[_0x131db6('0x22')](_0xad0bdb)?_0xad0bdb:JSON[_0x131db6('0x2')](_0xad0bdb);}else _0x425c62[_0x435084]=_[_0x131db6('0x22')](_0xad0bdb)?_0xad0bdb:JSON[_0x131db6('0x2')](_0xad0bdb);}catch(_0x371eef){_0x425c62[_0x435084]=_0xad0bdb[_0x131db6('0x23')](',');}}),_0x425c62;},exports[_0x230813('0xf')]=function(_0x2c9ba6){return _0x2c9ba6=parseInt(_0x2c9ba6,0xa),(!_0x2c9ba6||_0x2c9ba6<0x0)&&(_0x2c9ba6=LIMIT_VALUE),_0x2c9ba6;},exports['offset']=function(_0x231a4e){return _0x231a4e=parseInt(_0x231a4e,0xa),(!_0x231a4e||_0x231a4e<0x0)&&(_0x231a4e=0x0),_0x231a4e;},exports[_0x230813('0x12')]=function(_0x2251e7){const _0x7d4f98=_0x230813;let _0x1f3142,_0x393220=null;return _0x2251e7&&(_0x1f3142=_0x2251e7['split'](','),_0x393220=_[_0x7d4f98('0x24')](_0x1f3142,function(_0x1ec2ef){const _0x13b54b=_0x7d4f98;return _0x1ec2ef['indexOf']('-')===0x0?[_0x1ec2ef==='priority'?sequelize['cast'](sequelize['col'](_0x13b54b('0x15')),_0x13b54b('0x5')):_0x1ec2ef[_0x13b54b('0x17')](0x1),_0x13b54b('0xe')]:[_0x1ec2ef===_0x13b54b('0x15')?sequelize[_0x13b54b('0x29')](sequelize[_0x13b54b('0x11')](_0x13b54b('0x15')),_0x13b54b('0x5')):_0x1ec2ef,_0x13b54b('0x0')];})),_0x393220;},exports['omit']=function(_0x45e397,_0x3aeb5e){const _0x2e119c=_0x230813;if(_[_0x2e119c('0x21')](_0x45e397))return _0x45e397;if(_['isArray'](_0x45e397)){for(let _0xad1b9=0x0;_0xad1b9<_0x45e397[_0x2e119c('0xa')];_0xad1b9+=0x1){_0x45e397[_0xad1b9]=this[_0x2e119c('0x7')](_0x45e397[_0xad1b9],_0x3aeb5e);}return _0x45e397;}if(!_[_0x2e119c('0xb')](_0x45e397))return _0x45e397;_[_0x2e119c('0x10')](_0x3aeb5e)&&(_0x3aeb5e=[_0x3aeb5e]);if(!_['isArray'](_0x3aeb5e))return _0x45e397;for(let _0x461cae=0x0;_0x461cae<_0x3aeb5e[_0x2e119c('0xa')];_0x461cae+=0x1){_[_0x2e119c('0x8')](_0x45e397,_0x3aeb5e[_0x461cae]);}for(const _0x39c181 in _0x45e397){typeof _0x45e397[_0x39c181]!==_0x2e119c('0x27')&&(_0x45e397[_0x39c181]=this['omit'](_0x45e397[_0x39c181],_0x3aeb5e));}return _0x45e397;},exports[_0x230813('0x20')]=function(_0xce51b9){const _0x4330a9=_0x230813;return _0xce51b9[_0x4330a9('0x9')](RegExp(_0x4330a9('0x1')))?!![]:![];},exports[_0x230813('0x25')]=function(_0x53c494){const _0x31d33e=_0x230813;return _0x53c494[_0x31d33e('0x9')](/^\S+@\S+$/)?!![]:![];},exports[_0x230813('0x18')]=function(_0x5a32e0){const _0x39138=_0x230813,_0x34526f=[];return _0x5a32e0[_0x39138('0x23')]('\x20')[_0x39138('0x1c')](function(_0x367ece){const _0x31c639=_0x39138;_0x34526f[_0x31c639('0x26')]('+'+_0x367ece[_0x31c639('0x28')]()+'*');}),_0x34526f[_0x39138('0x16')]('\x20');}; \ No newline at end of file +const a836_0xc4aa=['indexOf','isObject','moment','unset','YYYY-MM-DD','match','isEmpty','unsigned','parse','offset','type','$lte','push','isNumeric','limit','format','gte','cast','getFullTextValue','^[+]?[0-9]*$','isString','substr','length','isPlainObject','isEmail','ASC','isArray','sequelize','filters','lodash','fields','DATE','sort','toString','col','priority','map','subtract','find','lte','omit','utc','forEach','split'];(function(_0x40affe,_0xc4aa8){const _0x3e7f15=function(_0x43cb49){while(--_0x43cb49){_0x40affe['push'](_0x40affe['shift']());}};_0x3e7f15(++_0xc4aa8);}(a836_0xc4aa,0x1b8));const a836_0x3e7f=function(_0x40affe,_0xc4aa8){_0x40affe=_0x40affe-0x0;let _0x3e7f15=a836_0xc4aa[_0x40affe];return _0x3e7f15;};const _0x545f5b=a836_0x3e7f;'use strict';const _=require(_0x545f5b('0x1d')),sequelize=require(_0x545f5b('0x1b')),moment=require(_0x545f5b('0x2')),Op=sequelize['Op'],LIMIT_VALUE=0xfa;exports[_0x545f5b('0x1e')]=function(_0x43cb49){const _0x5a0e10=_0x545f5b;let _0x291e6f=null;return _0x43cb49&&(_0x291e6f=_0x43cb49[_0x5a0e10('0x2b')](',')),_0x291e6f;},exports[_0x545f5b('0x1c')]=function(_0x284990,_0x6c5e3b){const _0x292c79=_0x545f5b,_0x3e7b6c={};return!_[_0x292c79('0x6')](_0x284990)&&_['forOwn'](_0x284990,function(_0x32f4d3,_0x45bfba){const _0x7e6756=_0x292c79;try{if(_0x6c5e3b){const _0xbbda53=_[_0x7e6756('0x26')](_0x6c5e3b,{'name':_0x45bfba})||{};if(_0xbbda53[_0x7e6756('0xa')]===_0x7e6756('0x1f')&&_[_0x7e6756('0x17')](_0x32f4d3)){const _0x3e861b=JSON['parse'](_0x32f4d3),_0x53ed20={[Op[_0x7e6756('0x10')]]:moment(moment(_0x3e861b['$gte'])['format'](_0x7e6756('0x4')))[_0x7e6756('0x29')]()['format'](),[Op[_0x7e6756('0x27')]]:moment(moment(_0x3e861b[_0x7e6756('0xb')])['format']('YYYY-MM-DD'))[_0x7e6756('0x29')]()[_0x7e6756('0x25')](0x1,'s')[_0x7e6756('0xf')]()};_0x3e7b6c[_0x45bfba]=_0x53ed20;}else _0x3e7b6c[_0x45bfba]=_[_0x7e6756('0x1a')](_0x32f4d3)?_0x32f4d3:JSON[_0x7e6756('0x8')](_0x32f4d3);}else _0x3e7b6c[_0x45bfba]=_['isArray'](_0x32f4d3)?_0x32f4d3:JSON[_0x7e6756('0x8')](_0x32f4d3);}catch(_0x40228e){_0x3e7b6c[_0x45bfba]=_0x32f4d3[_0x7e6756('0x2b')](',');}}),_0x3e7b6c;},exports[_0x545f5b('0xe')]=function(_0x461f91){return _0x461f91=parseInt(_0x461f91,0xa),(!_0x461f91||_0x461f91<0x0)&&(_0x461f91=LIMIT_VALUE),_0x461f91;},exports[_0x545f5b('0x9')]=function(_0x48559b){return _0x48559b=parseInt(_0x48559b,0xa),(!_0x48559b||_0x48559b<0x0)&&(_0x48559b=0x0),_0x48559b;},exports[_0x545f5b('0x20')]=function(_0x4a5b6c){const _0x4ee937=_0x545f5b;let _0x4fb570,_0x2726d2=null;return _0x4a5b6c&&(_0x4fb570=_0x4a5b6c[_0x4ee937('0x2b')](','),_0x2726d2=_[_0x4ee937('0x24')](_0x4fb570,function(_0x438f61){const _0x5a1c23=_0x4ee937;return _0x438f61[_0x5a1c23('0x0')]('-')===0x0?[_0x438f61===_0x5a1c23('0x23')?sequelize[_0x5a1c23('0x11')](sequelize[_0x5a1c23('0x22')](_0x5a1c23('0x23')),_0x5a1c23('0x7')):_0x438f61[_0x5a1c23('0x15')](0x1),'DESC']:[_0x438f61===_0x5a1c23('0x23')?sequelize[_0x5a1c23('0x11')](sequelize[_0x5a1c23('0x22')](_0x5a1c23('0x23')),_0x5a1c23('0x7')):_0x438f61,_0x5a1c23('0x19')];})),_0x2726d2;},exports[_0x545f5b('0x28')]=function(_0x2ee93a,_0xec4626){const _0x4037cb=_0x545f5b;if(_[_0x4037cb('0x6')](_0x2ee93a))return _0x2ee93a;if(_[_0x4037cb('0x1a')](_0x2ee93a)){for(let _0x4bcdc1=0x0;_0x4bcdc1<_0x2ee93a[_0x4037cb('0x16')];_0x4bcdc1+=0x1){_0x2ee93a[_0x4bcdc1]=this[_0x4037cb('0x28')](_0x2ee93a[_0x4bcdc1],_0xec4626);}return _0x2ee93a;}if(!_[_0x4037cb('0x1')](_0x2ee93a))return _0x2ee93a;_[_0x4037cb('0x14')](_0xec4626)&&(_0xec4626=[_0xec4626]);if(!_['isArray'](_0xec4626))return _0x2ee93a;for(let _0x1438bc=0x0;_0x1438bc<_0xec4626[_0x4037cb('0x16')];_0x1438bc+=0x1){_[_0x4037cb('0x3')](_0x2ee93a,_0xec4626[_0x1438bc]);}for(const _0x23de19 in _0x2ee93a){typeof _0x2ee93a[_0x23de19]!=='undefined'&&(_0x2ee93a[_0x23de19]=this[_0x4037cb('0x28')](_0x2ee93a[_0x23de19],_0xec4626));}return _0x2ee93a;},exports[_0x545f5b('0xd')]=function(_0x30d590){const _0x336deb=_0x545f5b;return _0x30d590[_0x336deb('0x5')](RegExp(_0x336deb('0x13')))?!![]:![];},exports[_0x545f5b('0x18')]=function(_0x4c12ef){const _0x15a889=_0x545f5b;return _0x4c12ef[_0x15a889('0x5')](/^\S+@\S+$/)?!![]:![];},exports[_0x545f5b('0x12')]=function(_0x150ade){const _0x5ea2df=_0x545f5b,_0x16e428=[];return _0x150ade[_0x5ea2df('0x2b')]('\x20')[_0x5ea2df('0x2a')](function(_0x90a132){const _0x20272b=_0x5ea2df;_0x16e428[_0x20272b('0xc')]('+'+_0x90a132[_0x20272b('0x21')]()+'*');}),_0x16e428['join']('\x20');}; \ No newline at end of file diff --git a/server/config/config.service.js b/server/config/config.service.js index 7e49cb7..5ab4d15 100644 --- a/server/config/config.service.js +++ b/server/config/config.service.js @@ -1 +1 @@ -const a837_0x33c9=['test','defineProperties','undefined','replace','string','toLowerCase','production','boolean','lodash','true','exports'];(function(_0x3e0886,_0x33c924){const _0x37f42c=function(_0x4bd278){while(--_0x4bd278){_0x3e0886['push'](_0x3e0886['shift']());}};_0x37f42c(++_0x33c924);}(a837_0x33c9,0x138));const a837_0x37f4=function(_0x3e0886,_0x33c924){_0x3e0886=_0x3e0886-0x0;let _0x37f42c=a837_0x33c9[_0x3e0886];return _0x37f42c;};const _0xf38852=a837_0x37f4,{camelCase}=require(_0xf38852('0x4')),{validKeys}=require('./env_definitions'),VALID_KEYS=validKeys;function toBoolean(_0x4bd278,_0xb53bb5=![]){const _0x3dd667=_0xf38852;return typeof _0x4bd278==='undefined'?_0xb53bb5:Boolean(typeof _0x4bd278==='string'?_0x4bd278[_0x3dd667('0x1')]()===_0x3dd667('0x5'):_0x4bd278);}function toNumber(_0x53d95c,_0x43b9d0=null){const _0x5f524c=_0xf38852,_0x595e8c=typeof _0x53d95c===_0x5f524c('0x9')||_0x53d95c===null?NaN:Number(_0x53d95c);return isNaN(_0x595e8c)?_0x43b9d0:_0x595e8c;}function toString(_0x456102,_0x5337d5=''){const _0xb4ca5d=_0xf38852;return typeof _0x456102===_0xb4ca5d('0x9')||_0x456102===null?_0x5337d5:String(_0x456102);}function getPropertiesConfiguration(){const _0x1c677e={'enumerable':!![],'configurable':![],'writable':![]};return VALID_KEYS['reduce']((_0xdbf1c3,{env:_0x59e45d,type:_0x44cbbf,defaultValue:_0x5828a1})=>{const _0x56e1c8=a837_0x37f4;let _0x26026e=null;const _0x331c76=process['env'][_0x59e45d];switch(_0x44cbbf){case _0x56e1c8('0x3'):_0x26026e=toBoolean(_0x331c76,_0x5828a1);break;case'number':_0x26026e=toNumber(_0x331c76,_0x5828a1);break;case _0x56e1c8('0x0'):_0x26026e=toString(_0x331c76,_0x5828a1);break;default:break;}if(_0x59e45d==='NODE_ENV')_0xdbf1c3={..._0xdbf1c3,'isProduction':{'value':_0x26026e===_0x56e1c8('0x2'),..._0x1c677e},'isTest':{'value':_0x26026e===_0x56e1c8('0x7'),..._0x1c677e},'environment':{'value':_0x26026e,..._0x1c677e}};else{const _0x31fd78=camelCase(_0x59e45d[_0x56e1c8('0xa')](/^XC_/,''));_0xdbf1c3={..._0xdbf1c3,[_0x31fd78]:{'value':_0x26026e,..._0x1c677e}};}return _0xdbf1c3;},{});}let configService=null;function getConfigService(){const _0x2c2b0f=_0xf38852;if(configService===null){configService={};const _0x317ac0=getPropertiesConfiguration();Object[_0x2c2b0f('0x8')](configService,_0x317ac0);}return configService;}module[_0xf38852('0x6')]={'getConfigService':getConfigService}; \ No newline at end of file +const a837_0x376f=['env','boolean','test','true','replace','exports','production','undefined','./env_definitions','number','toLowerCase','string','reduce','defineProperties'];(function(_0x3db86c,_0x376f1a){const _0x5dc4be=function(_0x188396){while(--_0x188396){_0x3db86c['push'](_0x3db86c['shift']());}};_0x5dc4be(++_0x376f1a);}(a837_0x376f,0x18b));const a837_0x5dc4=function(_0x3db86c,_0x376f1a){_0x3db86c=_0x3db86c-0x0;let _0x5dc4be=a837_0x376f[_0x3db86c];return _0x5dc4be;};const _0x3e04f1=a837_0x5dc4,{camelCase}=require('lodash'),{validKeys}=require(_0x3e04f1('0x5')),VALID_KEYS=validKeys;function toBoolean(_0x188396,_0x4dbc64=![]){const _0x26745f=_0x3e04f1;return typeof _0x188396===_0x26745f('0x4')?_0x4dbc64:Boolean(typeof _0x188396===_0x26745f('0x8')?_0x188396[_0x26745f('0x7')]()===_0x26745f('0x0'):_0x188396);}function toNumber(_0x12ddbe,_0x576135=null){const _0x41ab4e=_0x3e04f1,_0x3d38e1=typeof _0x12ddbe===_0x41ab4e('0x4')||_0x12ddbe===null?NaN:Number(_0x12ddbe);return isNaN(_0x3d38e1)?_0x576135:_0x3d38e1;}function toString(_0x220388,_0x7acb06=''){const _0x569f68=_0x3e04f1;return typeof _0x220388===_0x569f68('0x4')||_0x220388===null?_0x7acb06:String(_0x220388);}function getPropertiesConfiguration(){const _0x23a838=_0x3e04f1,_0x5ebefa={'enumerable':!![],'configurable':![],'writable':![]};return VALID_KEYS[_0x23a838('0x9')]((_0x593cd9,{env:_0x6e8231,type:_0x518c97,defaultValue:_0xaa57d6})=>{const _0x3e8794=_0x23a838;let _0x182564=null;const _0xe3fa66=process[_0x3e8794('0xb')][_0x6e8231];switch(_0x518c97){case _0x3e8794('0xc'):_0x182564=toBoolean(_0xe3fa66,_0xaa57d6);break;case _0x3e8794('0x6'):_0x182564=toNumber(_0xe3fa66,_0xaa57d6);break;case _0x3e8794('0x8'):_0x182564=toString(_0xe3fa66,_0xaa57d6);break;default:break;}if(_0x6e8231==='NODE_ENV')_0x593cd9={..._0x593cd9,'isProduction':{'value':_0x182564===_0x3e8794('0x3'),..._0x5ebefa},'isTest':{'value':_0x182564===_0x3e8794('0xd'),..._0x5ebefa},'environment':{'value':_0x182564,..._0x5ebefa}};else{const _0x345c09=camelCase(_0x6e8231[_0x3e8794('0x1')](/^XC_/,''));_0x593cd9={..._0x593cd9,[_0x345c09]:{'value':_0x182564,..._0x5ebefa}};}return _0x593cd9;},{});}let configService=null;function getConfigService(){const _0xfecc55=_0x3e04f1;if(configService===null){configService={};const _0x191749=getPropertiesConfiguration();Object[_0xfecc55('0xa')](configService,_0x191749);}return configService;}module[_0x3e04f1('0x2')]={'getConfigService':getConfigService}; \ No newline at end of file diff --git a/server/config/environment/development.js b/server/config/environment/development.js index 98ae66b..43a54ec 100644 --- a/server/config/environment/development.js +++ b/server/config/environment/development.js @@ -1 +1 @@ -const a838_0x1ce2=['seedDb','asteriskHost','utf8mb4','jstz','rpcPort','agiPort','utf8_general_ci','recordingSecret','dbHost','mysqlDatabase','mysql','rpcIp','googleSecret','./shared','mysqlPassword','redisPort','redisHost','agiIp','domain','/api/auth/google/callback','../config.service','dbPort','asteriskPassword','sessionSecret','utf8'];(function(_0x26a4bf,_0x1ce2b0){const _0x51fb2e=function(_0x85f648){while(--_0x85f648){_0x26a4bf['push'](_0x26a4bf['shift']());}};_0x51fb2e(++_0x1ce2b0);}(a838_0x1ce2,0x81));const a838_0x51fb=function(_0x26a4bf,_0x1ce2b0){_0x26a4bf=_0x26a4bf-0x0;let _0x51fb2e=a838_0x1ce2[_0x26a4bf];return _0x51fb2e;};const _0x38baa4=a838_0x51fb;'use strict';const shared=require(_0x38baa4('0x9')),jstz=require(_0x38baa4('0x18')),timezone=jstz['determine'](),timezoneOffset=shared['timezones'][timezone['name']()]['offsetStr'],cs=require(_0x38baa4('0x10'))['getConfigService']();module['exports']={'sequelize':{'database':cs['mysqlDatabase'],'username':cs['mysqlUser'],'password':cs[_0x38baa4('0xa')],'options':{'host':cs[_0x38baa4('0x4')],'port':cs[_0x38baa4('0x11')],'dialect':_0x38baa4('0x6'),'dialectOptions':{'charset':_0x38baa4('0x17')},'timezone':timezoneOffset,'define':{'charset':'utf8','collate':_0x38baa4('0x2')}}},'sequelizeHistory':{'database':cs[_0x38baa4('0x5')],'username':cs['mysqlUser'],'password':cs['mysqlPassword'],'options':{'host':cs['dbHost'],'port':cs[_0x38baa4('0x11')],'dialect':_0x38baa4('0x6'),'dialectOptions':{'charset':_0x38baa4('0x17')},'logging':![],'timezone':timezoneOffset,'define':{'charset':_0x38baa4('0x14'),'collate':_0x38baa4('0x2')}}},'asterisk':{'ip':cs[_0x38baa4('0x16')],'port':cs['asteriskPort'],'username':cs['asteriskUsername'],'password':cs[_0x38baa4('0x12')]},'redis':{'host':cs[_0x38baa4('0xc')],'port':cs[_0x38baa4('0xb')]},'rpc':{'port':cs[_0x38baa4('0x0')],'ip':cs[_0x38baa4('0x7')]},'agi':{'port':cs[_0x38baa4('0x1')],'ip':cs[_0x38baa4('0xd')]},'seedDB':cs[_0x38baa4('0x15')],'google':{'clientID':cs['googleId'],'clientSecret':cs[_0x38baa4('0x8')],'callbackURL':cs[_0x38baa4('0xe')]+_0x38baa4('0xf')},'secrets':{'session':cs[_0x38baa4('0x13')],'recording':cs[_0x38baa4('0x3')]},'xdr':{'disabled':![]}}; \ No newline at end of file +const a838_0x2953=['utf8','googleSecret','asteriskPort','jstz','mysqlUser','domain','sessionSecret','name','mysqlDatabase','dbHost','mysql','getConfigService','redisHost','exports','googleId','asteriskHost','utf8mb4','dbPort','offsetStr','asteriskUsername','./shared','timezones','mysqlPassword','rpcIp','asteriskPassword','utf8_general_ci','agiPort'];(function(_0x58cd5c,_0x2953c3){const _0x2842e6=function(_0x22878c){while(--_0x22878c){_0x58cd5c['push'](_0x58cd5c['shift']());}};_0x2842e6(++_0x2953c3);}(a838_0x2953,0x1d8));const a838_0x2842=function(_0x58cd5c,_0x2953c3){_0x58cd5c=_0x58cd5c-0x0;let _0x2842e6=a838_0x2953[_0x58cd5c];return _0x2842e6;};const _0x5e0ff8=a838_0x2842;'use strict';const shared=require(_0x5e0ff8('0x7')),jstz=require(_0x5e0ff8('0x11')),timezone=jstz['determine'](),timezoneOffset=shared[_0x5e0ff8('0x8')][timezone[_0x5e0ff8('0x15')]()][_0x5e0ff8('0x5')],cs=require('../config.service')[_0x5e0ff8('0x19')]();module[_0x5e0ff8('0x0')]={'sequelize':{'database':cs[_0x5e0ff8('0x16')],'username':cs[_0x5e0ff8('0x12')],'password':cs[_0x5e0ff8('0x9')],'options':{'host':cs[_0x5e0ff8('0x17')],'port':cs[_0x5e0ff8('0x4')],'dialect':_0x5e0ff8('0x18'),'dialectOptions':{'charset':_0x5e0ff8('0x3')},'timezone':timezoneOffset,'define':{'charset':'utf8','collate':_0x5e0ff8('0xc')}}},'sequelizeHistory':{'database':cs[_0x5e0ff8('0x16')],'username':cs[_0x5e0ff8('0x12')],'password':cs[_0x5e0ff8('0x9')],'options':{'host':cs[_0x5e0ff8('0x17')],'port':cs[_0x5e0ff8('0x4')],'dialect':_0x5e0ff8('0x18'),'dialectOptions':{'charset':_0x5e0ff8('0x3')},'logging':![],'timezone':timezoneOffset,'define':{'charset':_0x5e0ff8('0xe'),'collate':_0x5e0ff8('0xc')}}},'asterisk':{'ip':cs[_0x5e0ff8('0x2')],'port':cs[_0x5e0ff8('0x10')],'username':cs[_0x5e0ff8('0x6')],'password':cs[_0x5e0ff8('0xb')]},'redis':{'host':cs[_0x5e0ff8('0x1a')],'port':cs['redisPort']},'rpc':{'port':cs['rpcPort'],'ip':cs[_0x5e0ff8('0xa')]},'agi':{'port':cs[_0x5e0ff8('0xd')],'ip':cs['agiIp']},'seedDB':cs['seedDb'],'google':{'clientID':cs[_0x5e0ff8('0x1')],'clientSecret':cs[_0x5e0ff8('0xf')],'callbackURL':cs[_0x5e0ff8('0x13')]+'/api/auth/google/callback'},'secrets':{'session':cs[_0x5e0ff8('0x14')],'recording':cs['recordingSecret']},'xdr':{'disabled':![]}}; \ No newline at end of file diff --git a/server/config/environment/index.js b/server/config/environment/index.js index 4962b8a..c23ffb2 100644 --- a/server/config/environment/index.js +++ b/server/config/environment/index.js @@ -1 +1 @@ -const a839_0x1ab6=['../environment/','isProduction','sessionSecret','port','exports','seedDB','../config.service','development','environment'];(function(_0x5aa78d,_0x1ab6ae){const _0x385d4=function(_0x3a5cac){while(--_0x3a5cac){_0x5aa78d['push'](_0x5aa78d['shift']());}};_0x385d4(++_0x1ab6ae);}(a839_0x1ab6,0xf8));const a839_0x385d=function(_0x5aa78d,_0x1ab6ae){_0x5aa78d=_0x5aa78d-0x0;let _0x385d4=a839_0x1ab6[_0x5aa78d];return _0x385d4;};const _0x956ba=a839_0x385d;'use strict';const cs=require(_0x956ba('0x1'))['getConfigService'](),all={'env':cs[_0x956ba('0x3')],'root':global['appRoot'],'browserSyncPort':cs['browserSyncPort'],'port':cs[_0x956ba('0x7')],'ip':cs['ip'],'seedDB':cs[_0x956ba('0x0')],'secrets':{'session':cs[_0x956ba('0x6')],'recording':cs['recordingSecret']}},shared=require('./shared'),env=cs[_0x956ba('0x5')]||cs['isTest']?cs[_0x956ba('0x3')]:_0x956ba('0x2'),variables=require(_0x956ba('0x4')+env);module[_0x956ba('0x8')]={...all,...shared,...variables}; \ No newline at end of file +const a839_0x12a7=['recordingSecret','./shared','getConfigService','development','browserSyncPort','environment','../environment/','sessionSecret','exports','seedDB','../config.service'];(function(_0x30b534,_0x12a7b2){const _0x404588=function(_0x3e59e6){while(--_0x3e59e6){_0x30b534['push'](_0x30b534['shift']());}};_0x404588(++_0x12a7b2);}(a839_0x12a7,0x1b8));const a839_0x4045=function(_0x30b534,_0x12a7b2){_0x30b534=_0x30b534-0x0;let _0x404588=a839_0x12a7[_0x30b534];return _0x404588;};const _0x1e4abe=a839_0x4045;'use strict';const cs=require(_0x1e4abe('0xa'))[_0x1e4abe('0x2')](),all={'env':cs['environment'],'root':global['appRoot'],'browserSyncPort':cs[_0x1e4abe('0x4')],'port':cs['port'],'ip':cs['ip'],'seedDB':cs[_0x1e4abe('0x9')],'secrets':{'session':cs[_0x1e4abe('0x7')],'recording':cs[_0x1e4abe('0x0')]}},shared=require(_0x1e4abe('0x1')),env=cs['isProduction']||cs['isTest']?cs[_0x1e4abe('0x5')]:_0x1e4abe('0x3'),variables=require(_0x1e4abe('0x6')+env);module[_0x1e4abe('0x8')]={...all,...shared,...variables}; \ No newline at end of file diff --git a/server/config/environment/shared.js b/server/config/environment/shared.js index 4f20d6f..b3a7a30 100644 --- a/server/config/environment/shared.js +++ b/server/config/environment/shared.js @@ -1 +1 @@ -var a840_0x303a=['Asia/Kathmandu','Asia/Aqtobe','America/Sao_Paulo','-05:00','-03:00','+00:00','+06:00','Europe/Paris','Australia/Lord_Howe','America/Boise','Pacific/Auckland','Africa/Ceuta','Europe/Stockholm','Pacific/Rarotonga','America/Belem','Africa/Monrovia','Asia/Gaza','Europe/Lisbon','Europe/Helsinki','Asia/Qatar','Pacific/Port_Moresby','Europe/Amsterdam','Europe/Athens','Europe/Andorra','America/Argentina/Tucuman','Indian/Mauritius','Europe/Madrid','Australia/Hobart','America/North_Dakota/New_Salem','America/Iqaluit','America/Moncton','America/Paramaribo','America/Porto_Velho','Pacific/Honolulu','America/Rainy_River','Asia/Dhaka','+05:30','Pacific/Kiritimati','Pacific/Kwajalein','+08:00','America/Indiana/Winamac','Pacific/Marquesas','Asia/Pyongyang','Atlantic/Madeira','+09:00','Asia/Rangoon','Asia/Damascus','America/Thunder_Bay','Africa/Tripoli','Indian/Mahe','Pacific/Pohnpei','America/Bahia','Australia/Perth','+02:00','Indian/Chagos','America/Goose_Bay','America/Boa_Vista','Pacific/Gambier','Europe/Belgrade','Europe/Minsk','Asia/Kuching','Africa/Cairo','Atlantic/Bermuda','Asia/Oral','America/Cuiaba','+06:30','America/Juneau','America/Cambridge_Bay','Europe/London','Asia/Magadan','America/Halifax','Antarctica/Palmer','Africa/Lagos','America/Resolute','America/Hermosillo','Indian/Cocos','America/Anchorage','Atlantic/Cape_Verde','+10:00','Pacific/Tahiti','America/Kentucky/Louisville','America/Phoenix','America/La_Paz','Pacific/Enderbury','America/Danmarkshavn','Australia/Broken_Hill','Africa/Ndjamena','America/Dawson_Creek','+03:30','Asia/Baghdad','Europe/Malta','America/Ojinaga','Australia/Eucla','Africa/Accra','Europe/Sofia','-09:00','Europe/Bucharest','America/Inuvik','America/St_Johns','Australia/Currie','Pacific/Pitcairn','Asia/Novosibirsk','Europe/Zurich','America/Port_of_Spain','+14:00','America/Guyana','Africa/Maputo','Pacific/Tongatapu','America/Chicago','America/Argentina/Cordoba','Africa/Johannesburg','America/Manaus','Asia/Khandyga','America/Caracas','Pacific/Guadalcanal','Europe/Samara','America/Los_Angeles','Asia/Aqtau','America/Regina','America/Nipigon','+04:00','Asia/Qyzylorda','Asia/Karachi','Europe/Rome','Australia/Brisbane','Antarctica/Macquarie','-04:30','Asia/Ho_Chi_Minh','America/Vancouver','America/Puerto_Rico','America/Chihuahua','Europe/Vilnius','Asia/Yakutsk','America/Indiana/Vevay','America/Costa_Rica','Asia/Kabul','America/Fortaleza','-07:00','America/Cayman','America/Blanc-Sablon','Africa/Abidjan','America/Campo_Grande','Africa/Casablanca','Pacific/Kosrae','Asia/Yerevan','Asia/Ulaanbaatar','Antarctica/Syowa','Atlantic/South_Georgia','America/Curacao','Asia/Beirut','Asia/Bishkek','Asia/Tbilisi','Europe/Chisinau','-04:00','Pacific/Pago_Pago','Pacific/Nauru','+10:30','America/Mazatlan','Antarctica/Mawson','+05:45','America/Menominee','America/Argentina/Catamarca','-02:00','Pacific/Galapagos','Pacific/Easter','Pacific/Guam','Asia/Seoul','Indian/Reunion','Pacific/Wallis','America/Kentucky/Monticello','America/Montevideo','Australia/Sydney','America/Toronto','user','Antarctica/DumontDUrville','Asia/Taipei','America/North_Dakota/Center','Asia/Makassar','America/Argentina/Ushuaia','America/Eirunepe','America/Adak','Europe/Simferopol','America/Tijuana','Australia/Lindeman','+03:00','+12:00','Indian/Maldives','America/Indiana/Knox','Europe/Oslo','Pacific/Wake','Asia/Shanghai','Pacific/Fakaofo','UTC','Asia/Amman','Europe/Brussels','Asia/Colombo','Asia/Novokuznetsk','Africa/El_Aaiun','America/Godthab','+01:00','Asia/Ust-Nera','America/Lima','+09:30','America/Managua','America/Martinique','America/Noronha','America/Detroit','Europe/Vienna','+05:00','America/Yellowknife','Asia/Ashgabat','Pacific/Chatham','Europe/Warsaw','America/Araguaina','-08:00','Europe/Luxembourg','America/Argentina/La_Rioja','America/Creston','Antarctica/Troll','America/Rio_Branco','+11:00','America/Argentina/Jujuy','+13:00','America/Yakutat','America/Cancun','Asia/Kolkata','America/Santo_Domingo','Asia/Choibalsan','America/New_York','-11:00','Asia/Manila','Asia/Dushanbe','Pacific/Chuuk','America/Nassau','Pacific/Noumea','Atlantic/Stanley','America/Belize','Asia/Samarkand','America/Miquelon','Asia/Hong_Kong','America/Argentina/Rio_Gallegos','Europe/Budapest','America/Merida','America/Guayaquil','-01:00','Asia/Kuala_Lumpur','Asia/Nicosia','America/Bogota','America/Recife','Asia/Dubai','Asia/Jayapura','Asia/Chita','America/Havana','Asia/Jerusalem','America/Swift_Current','Europe/Gibraltar','America/Argentina/Buenos_Aires','America/Thule','Asia/Brunei','Asia/Tehran','Atlantic/Canary','Australia/Adelaide','-10:00','Africa/Tunis','Asia/Riyadh','America/Indiana/Vincennes','Atlantic/Reykjavik','America/Barbados','America/Santiago','+13:45','Indian/Christmas','Europe/Tirane','America/Denver','Australia/Melbourne','Asia/Singapore','Europe/Tallinn','Asia/Hovd','Asia/Kamchatka','-06:00','+07:00','-03:30','America/Nome','exports'];(function(_0x386972,_0x303a8c){var _0x142f65=function(_0x24e86d){while(--_0x24e86d){_0x386972['push'](_0x386972['shift']());}};_0x142f65(++_0x303a8c);}(a840_0x303a,0x1f2));var a840_0x142f=function(_0x386972,_0x303a8c){_0x386972=_0x386972-0x0;var _0x142f65=a840_0x303a[_0x386972];return _0x142f65;};var _0x3edf0e=a840_0x142f;'use strict';module[_0x3edf0e('0x43')]={'userRoles':['guest',_0x3edf0e('0xf1'),'admin'],'timezones':{'Europe/Andorra':{'name':_0x3edf0e('0x5b'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['AD']},'Asia/Dubai':{'name':_0x3edf0e('0x22'),'utcOffset':0xf0,'offsetStr':_0x3edf0e('0xbc'),'countries':['AE','OM']},'Asia/Kabul':{'name':_0x3edf0e('0xcb'),'utcOffset':0x10e,'offsetStr':'+04:30','countries':['AF']},'Europe/Tirane':{'name':_0x3edf0e('0x38'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['AL']},'Asia/Yerevan':{'name':_0x3edf0e('0xd4'),'utcOffset':0xf0,'offsetStr':_0x3edf0e('0xbc'),'countries':['AM']},'Antarctica/Rothera':{'name':'Antarctica/Rothera','utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AQ']},'Antarctica/Palmer':{'name':_0x3edf0e('0x8b'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AQ']},'Antarctica/Mawson':{'name':_0x3edf0e('0xe2'),'utcOffset':0x12c,'offsetStr':_0x3edf0e('0x114'),'countries':['AQ']},'Antarctica/Davis':{'name':'Antarctica/Davis','utcOffset':0x1a4,'offsetStr':_0x3edf0e('0x40'),'countries':['AQ']},'Antarctica/Casey':{'name':'Antarctica/Casey','utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['AQ']},'Antarctica/Vostok':{'name':'Antarctica/Vostok','utcOffset':0x168,'offsetStr':_0x3edf0e('0x4a'),'countries':['AQ']},'Antarctica/DumontDUrville':{'name':_0x3edf0e('0xf2'),'utcOffset':0x258,'offsetStr':_0x3edf0e('0x92'),'countries':['AQ']},'Antarctica/Syowa':{'name':_0x3edf0e('0xd6'),'utcOffset':0xb4,'offsetStr':_0x3edf0e('0xfc'),'countries':['AQ']},'Antarctica/Troll':{'name':_0x3edf0e('0x3'),'utcOffset':0x0,'offsetStr':_0x3edf0e('0x49'),'countries':['AQ']},'America/Argentina/Buenos_Aires':{'name':_0x3edf0e('0x29'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['AR']},'America/Argentina/Cordoba':{'name':_0x3edf0e('0xb1'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/Salta':{'name':'America/Argentina/Salta','utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/Jujuy':{'name':_0x3edf0e('0x6'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/Tucuman':{'name':_0x3edf0e('0x5c'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/Catamarca':{'name':_0x3edf0e('0xe5'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/La_Rioja':{'name':_0x3edf0e('0x1'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/San_Juan':{'name':'America/Argentina/San_Juan','utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/Mendoza':{'name':'America/Argentina/Mendoza','utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/San_Luis':{'name':'America/Argentina/San_Luis','utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/Rio_Gallegos':{'name':_0x3edf0e('0x19'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'America/Argentina/Ushuaia':{'name':_0x3edf0e('0xf6'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['AR']},'Pacific/Pago_Pago':{'name':_0x3edf0e('0xde'),'utcOffset':-0x294,'offsetStr':_0x3edf0e('0xe'),'countries':['AS','UM']},'Europe/Vienna':{'name':_0x3edf0e('0x113'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['AT']},'Australia/Lord_Howe':{'name':_0x3edf0e('0x4c'),'utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['AU']},'Antarctica/Macquarie':{'name':_0x3edf0e('0xc1'),'utcOffset':0x294,'offsetStr':'+11:00','countries':['AU']},'Australia/Hobart':{'name':_0x3edf0e('0x5f'),'utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['AU']},'Australia/Currie':{'name':_0x3edf0e('0xa7'),'utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['AU']},'Australia/Melbourne':{'name':_0x3edf0e('0x3a'),'utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['AU']},'Australia/Sydney':{'name':_0x3edf0e('0xef'),'utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['AU']},'Australia/Broken_Hill':{'name':_0x3edf0e('0x99'),'utcOffset':0x276,'offsetStr':_0x3edf0e('0xe0'),'countries':['AU']},'Australia/Brisbane':{'name':_0x3edf0e('0xc0'),'utcOffset':0x258,'offsetStr':_0x3edf0e('0x92'),'countries':['AU']},'Australia/Lindeman':{'name':_0x3edf0e('0xfb'),'utcOffset':0x258,'offsetStr':_0x3edf0e('0x92'),'countries':['AU']},'Australia/Adelaide':{'name':_0x3edf0e('0x2e'),'utcOffset':0x276,'offsetStr':'+10:30','countries':['AU']},'Australia/Darwin':{'name':'Australia/Darwin','utcOffset':0x23a,'offsetStr':_0x3edf0e('0x10e'),'countries':['AU']},'Australia/Perth':{'name':_0x3edf0e('0x78'),'utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['AU']},'Australia/Eucla':{'name':_0x3edf0e('0xa0'),'utcOffset':0x20d,'offsetStr':'+08:45','countries':['AU']},'Asia/Baku':{'name':'Asia/Baku','utcOffset':0xf0,'offsetStr':'+04:00','countries':['AZ']},'America/Barbados':{'name':_0x3edf0e('0x34'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['BB']},'Asia/Dhaka':{'name':_0x3edf0e('0x67'),'utcOffset':0x168,'offsetStr':_0x3edf0e('0x4a'),'countries':['BD']},'Europe/Brussels':{'name':_0x3edf0e('0x106'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['BE']},'Europe/Sofia':{'name':_0x3edf0e('0xa2'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['BG']},'Atlantic/Bermuda':{'name':_0x3edf0e('0x82'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['BM']},'Asia/Brunei':{'name':_0x3edf0e('0x2b'),'utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['BN']},'America/La_Paz':{'name':_0x3edf0e('0x96'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['BO']},'America/Noronha':{'name':_0x3edf0e('0x111'),'utcOffset':-0x78,'offsetStr':'-02:00','countries':['BR']},'America/Belem':{'name':_0x3edf0e('0x52'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['BR']},'America/Fortaleza':{'name':_0x3edf0e('0xcc'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['BR']},'America/Recife':{'name':_0x3edf0e('0x21'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['BR']},'America/Araguaina':{'name':_0x3edf0e('0x119'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['BR']},'America/Maceio':{'name':'America/Maceio','utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['BR']},'America/Bahia':{'name':_0x3edf0e('0x77'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['BR']},'America/Sao_Paulo':{'name':_0x3edf0e('0x46'),'utcOffset':-0x78,'offsetStr':_0x3edf0e('0xe6'),'countries':['BR']},'America/Campo_Grande':{'name':_0x3edf0e('0xd1'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['BR']},'America/Cuiaba':{'name':_0x3edf0e('0x84'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['BR']},'America/Santarem':{'name':'America/Santarem','utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['BR']},'America/Porto_Velho':{'name':_0x3edf0e('0x64'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['BR']},'America/Boa_Vista':{'name':_0x3edf0e('0x7c'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['BR']},'America/Manaus':{'name':_0x3edf0e('0xb3'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['BR']},'America/Eirunepe':{'name':_0x3edf0e('0xf7'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['BR']},'America/Rio_Branco':{'name':_0x3edf0e('0x4'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['BR']},'America/Nassau':{'name':_0x3edf0e('0x12'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['BS']},'Asia/Thimphu':{'name':'Asia/Thimphu','utcOffset':0x168,'offsetStr':'+06:00','countries':['BT']},'Europe/Minsk':{'name':_0x3edf0e('0x7f'),'utcOffset':0xb4,'offsetStr':_0x3edf0e('0xfc'),'countries':['BY']},'America/Belize':{'name':_0x3edf0e('0x15'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['BZ']},'America/St_Johns':{'name':_0x3edf0e('0xa6'),'utcOffset':-0xd2,'offsetStr':_0x3edf0e('0x41'),'countries':['CA']},'America/Halifax':{'name':_0x3edf0e('0x8a'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['CA']},'America/Glace_Bay':{'name':'America/Glace_Bay','utcOffset':-0xf0,'offsetStr':'-04:00','countries':['CA']},'America/Moncton':{'name':_0x3edf0e('0x62'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['CA']},'America/Goose_Bay':{'name':_0x3edf0e('0x7b'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['CA']},'America/Blanc-Sablon':{'name':_0x3edf0e('0xcf'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['CA']},'America/Toronto':{'name':_0x3edf0e('0xf0'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['CA']},'America/Nipigon':{'name':_0x3edf0e('0xbb'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['CA']},'America/Thunder_Bay':{'name':_0x3edf0e('0x73'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['CA']},'America/Iqaluit':{'name':_0x3edf0e('0x61'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['CA']},'America/Pangnirtung':{'name':'America/Pangnirtung','utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['CA']},'America/Resolute':{'name':_0x3edf0e('0x8d'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['CA']},'America/Atikokan':{'name':'America/Atikokan','utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['CA']},'America/Rankin_Inlet':{'name':'America/Rankin_Inlet','utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['CA']},'America/Winnipeg':{'name':'America/Winnipeg','utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['CA']},'America/Rainy_River':{'name':_0x3edf0e('0x66'),'utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['CA']},'America/Regina':{'name':_0x3edf0e('0xba'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['CA']},'America/Swift_Current':{'name':_0x3edf0e('0x27'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['CA']},'America/Edmonton':{'name':'America/Edmonton','utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['CA']},'America/Cambridge_Bay':{'name':_0x3edf0e('0x87'),'utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['CA']},'America/Yellowknife':{'name':_0x3edf0e('0x115'),'utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['CA']},'America/Inuvik':{'name':_0x3edf0e('0xa5'),'utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['CA']},'America/Creston':{'name':_0x3edf0e('0x2'),'utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['CA']},'America/Dawson_Creek':{'name':_0x3edf0e('0x9b'),'utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['CA']},'America/Fort_Nelson':{'name':'America/Fort_Nelson','utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['CA']},'America/Vancouver':{'name':_0x3edf0e('0xc4'),'utcOffset':-0x1e0,'offsetStr':_0x3edf0e('0x11a'),'countries':['CA']},'America/Whitehorse':{'name':'America/Whitehorse','utcOffset':-0x1e0,'offsetStr':_0x3edf0e('0x11a'),'countries':['CA']},'America/Dawson':{'name':'America/Dawson','utcOffset':-0x1e0,'offsetStr':_0x3edf0e('0x11a'),'countries':['CA']},'Indian/Cocos':{'name':_0x3edf0e('0x8f'),'utcOffset':0x186,'offsetStr':_0x3edf0e('0x85'),'countries':['CC']},'Europe/Zurich':{'name':_0x3edf0e('0xaa'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['CH','DE','LI']},'Africa/Abidjan':{'name':_0x3edf0e('0xd0'),'utcOffset':0x0,'offsetStr':_0x3edf0e('0x49'),'countries':['CI','BF','GM','GN','ML','MR','SH','SL','SN','ST','TG']},'Pacific/Rarotonga':{'name':_0x3edf0e('0x51'),'utcOffset':-0x258,'offsetStr':_0x3edf0e('0x2f'),'countries':['CK']},'America/Santiago':{'name':_0x3edf0e('0x35'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['CL']},'Pacific/Easter':{'name':_0x3edf0e('0xe8'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['CL']},'Asia/Shanghai':{'name':_0x3edf0e('0x102'),'utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['CN']},'Asia/Urumqi':{'name':'Asia/Urumqi','utcOffset':0x168,'offsetStr':_0x3edf0e('0x4a'),'countries':['CN']},'America/Bogota':{'name':_0x3edf0e('0x20'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['CO']},'America/Costa_Rica':{'name':_0x3edf0e('0xca'),'utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['CR']},'America/Havana':{'name':_0x3edf0e('0x25'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['CU']},'Atlantic/Cape_Verde':{'name':_0x3edf0e('0x91'),'utcOffset':-0x3c,'offsetStr':_0x3edf0e('0x1d'),'countries':['CV']},'America/Curacao':{'name':_0x3edf0e('0xd8'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['CW','AW','BQ','SX']},'Indian/Christmas':{'name':_0x3edf0e('0x37'),'utcOffset':0x1a4,'offsetStr':_0x3edf0e('0x40'),'countries':['CX']},'Asia/Nicosia':{'name':_0x3edf0e('0x1f'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['CY']},'Europe/Prague':{'name':'Europe/Prague','utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['CZ','SK']},'Europe/Berlin':{'name':'Europe/Berlin','utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['DE']},'Europe/Copenhagen':{'name':'Europe/Copenhagen','utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['DK']},'America/Santo_Domingo':{'name':_0x3edf0e('0xb'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['DO']},'Africa/Algiers':{'name':'Africa/Algiers','utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['DZ']},'America/Guayaquil':{'name':_0x3edf0e('0x1c'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['EC']},'Pacific/Galapagos':{'name':_0x3edf0e('0xe7'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['EC']},'Europe/Tallinn':{'name':_0x3edf0e('0x3c'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['EE']},'Africa/Cairo':{'name':_0x3edf0e('0x81'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['EG']},'Africa/El_Aaiun':{'name':_0x3edf0e('0x109'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['EH']},'Europe/Madrid':{'name':_0x3edf0e('0x5e'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['ES']},'Africa/Ceuta':{'name':_0x3edf0e('0x4f'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['ES']},'Atlantic/Canary':{'name':_0x3edf0e('0x2d'),'utcOffset':0x0,'offsetStr':_0x3edf0e('0x49'),'countries':['ES']},'Europe/Helsinki':{'name':_0x3edf0e('0x56'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['FI','AX']},'Pacific/Fiji':{'name':'Pacific/Fiji','utcOffset':0x2d0,'offsetStr':_0x3edf0e('0xfd'),'countries':['FJ']},'Atlantic/Stanley':{'name':_0x3edf0e('0x14'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['FK']},'Pacific/Chuuk':{'name':_0x3edf0e('0x11'),'utcOffset':0x258,'offsetStr':'+10:00','countries':['FM']},'Pacific/Pohnpei':{'name':_0x3edf0e('0x76'),'utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['FM']},'Pacific/Kosrae':{'name':_0x3edf0e('0xd3'),'utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['FM']},'Atlantic/Faroe':{'name':'Atlantic/Faroe','utcOffset':0x0,'offsetStr':'+00:00','countries':['FO']},'Europe/Paris':{'name':_0x3edf0e('0x4b'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['FR']},'UTC':{'name':_0x3edf0e('0x104'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['GB','GG','IM','JE']},'Europe/London':{'name':_0x3edf0e('0x88'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['GB','GG','IM','JE']},'Asia/Tbilisi':{'name':_0x3edf0e('0xdb'),'utcOffset':0xf0,'offsetStr':_0x3edf0e('0xbc'),'countries':['GE']},'America/Cayenne':{'name':'America/Cayenne','utcOffset':-0xb4,'offsetStr':'-03:00','countries':['GF']},'Africa/Accra':{'name':_0x3edf0e('0xa1'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['GH']},'Europe/Gibraltar':{'name':_0x3edf0e('0x28'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['GI']},'America/Godthab':{'name':_0x3edf0e('0x10a'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['GL']},'America/Danmarkshavn':{'name':_0x3edf0e('0x98'),'utcOffset':0x0,'offsetStr':_0x3edf0e('0x49'),'countries':['GL']},'America/Scoresbysund':{'name':'America/Scoresbysund','utcOffset':-0x3c,'offsetStr':_0x3edf0e('0x1d'),'countries':['GL']},'America/Thule':{'name':_0x3edf0e('0x2a'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['GL']},'Europe/Athens':{'name':_0x3edf0e('0x5a'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['GR']},'Atlantic/South_Georgia':{'name':_0x3edf0e('0xd7'),'utcOffset':-0x78,'offsetStr':_0x3edf0e('0xe6'),'countries':['GS']},'America/Guatemala':{'name':'America/Guatemala','utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['GT']},'Pacific/Guam':{'name':_0x3edf0e('0xe9'),'utcOffset':0x258,'offsetStr':_0x3edf0e('0x92'),'countries':['GU','MP']},'Africa/Bissau':{'name':'Africa/Bissau','utcOffset':0x0,'offsetStr':_0x3edf0e('0x49'),'countries':['GW']},'America/Guyana':{'name':_0x3edf0e('0xad'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['GY']},'Asia/Hong_Kong':{'name':_0x3edf0e('0x18'),'utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['HK']},'America/Tegucigalpa':{'name':'America/Tegucigalpa','utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['HN']},'America/Port-au-Prince':{'name':'America/Port-au-Prince','utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['HT']},'Europe/Budapest':{'name':_0x3edf0e('0x1a'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['HU']},'Asia/Jakarta':{'name':'Asia/Jakarta','utcOffset':0x1a4,'offsetStr':_0x3edf0e('0x40'),'countries':['ID']},'Asia/Pontianak':{'name':'Asia/Pontianak','utcOffset':0x1a4,'offsetStr':'+07:00','countries':['ID']},'Asia/Makassar':{'name':_0x3edf0e('0xf5'),'utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['ID']},'Asia/Jayapura':{'name':_0x3edf0e('0x23'),'utcOffset':0x21c,'offsetStr':_0x3edf0e('0x70'),'countries':['ID']},'Europe/Dublin':{'name':'Europe/Dublin','utcOffset':0x0,'offsetStr':_0x3edf0e('0x49'),'countries':['IE']},'Asia/Jerusalem':{'name':_0x3edf0e('0x26'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['IL']},'Asia/Kolkata':{'name':_0x3edf0e('0xa'),'utcOffset':0x14a,'offsetStr':_0x3edf0e('0x68'),'countries':['IN']},'Indian/Chagos':{'name':_0x3edf0e('0x7a'),'utcOffset':0x168,'offsetStr':_0x3edf0e('0x4a'),'countries':['IO']},'Asia/Baghdad':{'name':_0x3edf0e('0x9d'),'utcOffset':0xb4,'offsetStr':'+03:00','countries':['IQ']},'Asia/Tehran':{'name':_0x3edf0e('0x2c'),'utcOffset':0xd2,'offsetStr':_0x3edf0e('0x9c'),'countries':['IR']},'Atlantic/Reykjavik':{'name':_0x3edf0e('0x33'),'utcOffset':0x0,'offsetStr':_0x3edf0e('0x49'),'countries':['IS']},'Europe/Rome':{'name':_0x3edf0e('0xbf'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['IT','SM','VA']},'America/Jamaica':{'name':'America/Jamaica','utcOffset':-0x12c,'offsetStr':'-05:00','countries':['JM']},'Asia/Amman':{'name':_0x3edf0e('0x105'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['JO']},'Asia/Tokyo':{'name':'Asia/Tokyo','utcOffset':0x21c,'offsetStr':'+09:00','countries':['JP']},'Africa/Nairobi':{'name':'Africa/Nairobi','utcOffset':0xb4,'offsetStr':'+03:00','countries':['KE','DJ','ER','ET','KM','MG','SO','TZ','UG','YT']},'Asia/Bishkek':{'name':_0x3edf0e('0xda'),'utcOffset':0x168,'offsetStr':_0x3edf0e('0x4a'),'countries':['KG']},'Pacific/Tarawa':{'name':'Pacific/Tarawa','utcOffset':0x2d0,'offsetStr':_0x3edf0e('0xfd'),'countries':['KI']},'Pacific/Enderbury':{'name':_0x3edf0e('0x97'),'utcOffset':0x30c,'offsetStr':_0x3edf0e('0x7'),'countries':['KI']},'Pacific/Kiritimati':{'name':_0x3edf0e('0x69'),'utcOffset':0x348,'offsetStr':_0x3edf0e('0xac'),'countries':['KI']},'Asia/Pyongyang':{'name':_0x3edf0e('0x6e'),'utcOffset':0x1fe,'offsetStr':'+08:30','countries':['KP']},'Asia/Seoul':{'name':_0x3edf0e('0xea'),'utcOffset':0x21c,'offsetStr':_0x3edf0e('0x70'),'countries':['KR']},'America/Cayman':{'name':_0x3edf0e('0xce'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['KY']},'Asia/Almaty':{'name':'Asia/Almaty','utcOffset':0x168,'offsetStr':_0x3edf0e('0x4a'),'countries':['KZ']},'Asia/Qyzylorda':{'name':_0x3edf0e('0xbd'),'utcOffset':0x168,'offsetStr':_0x3edf0e('0x4a'),'countries':['KZ']},'Asia/Aqtobe':{'name':_0x3edf0e('0x45'),'utcOffset':0x12c,'offsetStr':'+05:00','countries':['KZ']},'Asia/Aqtau':{'name':_0x3edf0e('0xb9'),'utcOffset':0x12c,'offsetStr':'+05:00','countries':['KZ']},'Asia/Oral':{'name':_0x3edf0e('0x83'),'utcOffset':0x12c,'offsetStr':_0x3edf0e('0x114'),'countries':['KZ']},'Asia/Beirut':{'name':_0x3edf0e('0xd9'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['LB']},'Asia/Colombo':{'name':_0x3edf0e('0x107'),'utcOffset':0x14a,'offsetStr':'+05:30','countries':['LK']},'Africa/Monrovia':{'name':_0x3edf0e('0x53'),'utcOffset':0x0,'offsetStr':_0x3edf0e('0x49'),'countries':['LR']},'Europe/Vilnius':{'name':_0x3edf0e('0xc7'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['LT']},'Europe/Luxembourg':{'name':_0x3edf0e('0x0'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['LU']},'Europe/Riga':{'name':'Europe/Riga','utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['LV']},'Africa/Tripoli':{'name':_0x3edf0e('0x74'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['LY']},'Africa/Casablanca':{'name':_0x3edf0e('0xd2'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['MA']},'Europe/Monaco':{'name':'Europe/Monaco','utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['MC']},'Europe/Chisinau':{'name':_0x3edf0e('0xdc'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['MD']},'Pacific/Majuro':{'name':'Pacific/Majuro','utcOffset':0x2d0,'offsetStr':'+12:00','countries':['MH']},'Pacific/Kwajalein':{'name':_0x3edf0e('0x6a'),'utcOffset':0x2d0,'offsetStr':_0x3edf0e('0xfd'),'countries':['MH']},'Asia/Rangoon':{'name':_0x3edf0e('0x71'),'utcOffset':0x186,'offsetStr':'+06:30','countries':['MM']},'Asia/Ulaanbaatar':{'name':_0x3edf0e('0xd5'),'utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['MN']},'Asia/Hovd':{'name':_0x3edf0e('0x3d'),'utcOffset':0x1a4,'offsetStr':_0x3edf0e('0x40'),'countries':['MN']},'Asia/Choibalsan':{'name':_0x3edf0e('0xc'),'utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['MN']},'Asia/Macau':{'name':'Asia/Macau','utcOffset':0x1e0,'offsetStr':'+08:00','countries':['MO']},'America/Martinique':{'name':_0x3edf0e('0x110'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['MQ']},'Europe/Malta':{'name':_0x3edf0e('0x9e'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['MT']},'Indian/Mauritius':{'name':_0x3edf0e('0x5d'),'utcOffset':0xf0,'offsetStr':_0x3edf0e('0xbc'),'countries':['MU']},'Indian/Maldives':{'name':_0x3edf0e('0xfe'),'utcOffset':0x12c,'offsetStr':'+05:00','countries':['MV']},'America/Mexico_City':{'name':'America/Mexico_City','utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['MX']},'America/Cancun':{'name':_0x3edf0e('0x9'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['MX']},'America/Merida':{'name':_0x3edf0e('0x1b'),'utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['MX']},'America/Monterrey':{'name':'America/Monterrey','utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['MX']},'America/Matamoros':{'name':'America/Matamoros','utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['MX']},'America/Mazatlan':{'name':_0x3edf0e('0xe1'),'utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['MX']},'America/Chihuahua':{'name':_0x3edf0e('0xc6'),'utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['MX']},'America/Ojinaga':{'name':_0x3edf0e('0x9f'),'utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['MX']},'America/Hermosillo':{'name':_0x3edf0e('0x8e'),'utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['MX']},'America/Tijuana':{'name':_0x3edf0e('0xfa'),'utcOffset':-0x1e0,'offsetStr':'-08:00','countries':['MX']},'America/Santa_Isabel':{'name':'America/Santa_Isabel','utcOffset':-0x1e0,'offsetStr':_0x3edf0e('0x11a'),'countries':['MX']},'America/Bahia_Banderas':{'name':'America/Bahia_Banderas','utcOffset':-0x168,'offsetStr':'-06:00','countries':['MX']},'Asia/Kuala_Lumpur':{'name':_0x3edf0e('0x1e'),'utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['MY']},'Asia/Kuching':{'name':_0x3edf0e('0x80'),'utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['MY']},'Africa/Maputo':{'name':_0x3edf0e('0xae'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['MZ','BI','BW','CD','MW','RW','ZM','ZW']},'Africa/Windhoek':{'name':'Africa/Windhoek','utcOffset':0x78,'offsetStr':'+02:00','countries':['NA']},'Pacific/Noumea':{'name':_0x3edf0e('0x13'),'utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['NC']},'Pacific/Norfolk':{'name':'Pacific/Norfolk','utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['NF']},'Africa/Lagos':{'name':_0x3edf0e('0x8c'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['NG','AO','BJ','CD','CF','CG','CM','GA','GQ','NE']},'America/Managua':{'name':_0x3edf0e('0x10f'),'utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['NI']},'Europe/Amsterdam':{'name':_0x3edf0e('0x59'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['NL']},'Europe/Oslo':{'name':_0x3edf0e('0x100'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['NO','SJ']},'Asia/Kathmandu':{'name':_0x3edf0e('0x44'),'utcOffset':0x159,'offsetStr':_0x3edf0e('0xe3'),'countries':['NP']},'Pacific/Nauru':{'name':_0x3edf0e('0xdf'),'utcOffset':0x2d0,'offsetStr':_0x3edf0e('0xfd'),'countries':['NR']},'Pacific/Niue':{'name':'Pacific/Niue','utcOffset':-0x294,'offsetStr':'-11:00','countries':['NU']},'Pacific/Auckland':{'name':_0x3edf0e('0x4e'),'utcOffset':0x30c,'offsetStr':'+13:00','countries':['NZ','AQ']},'Pacific/Chatham':{'name':_0x3edf0e('0x117'),'utcOffset':0x339,'offsetStr':_0x3edf0e('0x36'),'countries':['NZ']},'America/Panama':{'name':'America/Panama','utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['PA']},'America/Lima':{'name':_0x3edf0e('0x10d'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['PE']},'Pacific/Tahiti':{'name':_0x3edf0e('0x93'),'utcOffset':-0x258,'offsetStr':'-10:00','countries':['PF']},'Pacific/Marquesas':{'name':_0x3edf0e('0x6d'),'utcOffset':-0x23a,'offsetStr':'-09:30','countries':['PF']},'Pacific/Gambier':{'name':_0x3edf0e('0x7d'),'utcOffset':-0x21c,'offsetStr':_0x3edf0e('0xa3'),'countries':['PF']},'Pacific/Port_Moresby':{'name':_0x3edf0e('0x58'),'utcOffset':0x258,'offsetStr':'+10:00','countries':['PG']},'Pacific/Bougainville':{'name':'Pacific/Bougainville','utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['PG']},'Asia/Manila':{'name':_0x3edf0e('0xf'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['PH']},'Asia/Karachi':{'name':_0x3edf0e('0xbe'),'utcOffset':0x12c,'offsetStr':_0x3edf0e('0x114'),'countries':['PK']},'Europe/Warsaw':{'name':_0x3edf0e('0x118'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['PL']},'America/Miquelon':{'name':_0x3edf0e('0x17'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['PM']},'Pacific/Pitcairn':{'name':_0x3edf0e('0xa8'),'utcOffset':-0x1e0,'offsetStr':_0x3edf0e('0x11a'),'countries':['PN']},'America/Puerto_Rico':{'name':_0x3edf0e('0xc5'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['PR']},'Asia/Gaza':{'name':_0x3edf0e('0x54'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['PS']},'Asia/Hebron':{'name':'Asia/Hebron','utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['PS']},'Europe/Lisbon':{'name':_0x3edf0e('0x55'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['PT']},'Atlantic/Madeira':{'name':_0x3edf0e('0x6f'),'utcOffset':0x0,'offsetStr':_0x3edf0e('0x49'),'countries':['PT']},'Atlantic/Azores':{'name':'Atlantic/Azores','utcOffset':-0x3c,'offsetStr':_0x3edf0e('0x1d'),'countries':['PT']},'Pacific/Palau':{'name':'Pacific/Palau','utcOffset':0x21c,'offsetStr':_0x3edf0e('0x70'),'countries':['PW']},'America/Asuncion':{'name':'America/Asuncion','utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['PY']},'Asia/Qatar':{'name':_0x3edf0e('0x57'),'utcOffset':0xb4,'offsetStr':_0x3edf0e('0xfc'),'countries':['QA','BH']},'Indian/Reunion':{'name':_0x3edf0e('0xeb'),'utcOffset':0xf0,'offsetStr':'+04:00','countries':['RE','TF']},'Europe/Bucharest':{'name':_0x3edf0e('0xa4'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['RO']},'Europe/Belgrade':{'name':_0x3edf0e('0x7e'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['RS','BA','HR','ME','MK','SI']},'Europe/Kaliningrad':{'name':'Europe/Kaliningrad','utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['RU']},'Europe/Moscow':{'name':'Europe/Moscow','utcOffset':0xb4,'offsetStr':_0x3edf0e('0xfc'),'countries':['RU']},'Europe/Simferopol':{'name':_0x3edf0e('0xf9'),'utcOffset':0xb4,'offsetStr':_0x3edf0e('0xfc'),'countries':['RU']},'Europe/Volgograd':{'name':'Europe/Volgograd','utcOffset':0xb4,'offsetStr':_0x3edf0e('0xfc'),'countries':['RU']},'Europe/Samara':{'name':_0x3edf0e('0xb7'),'utcOffset':0xf0,'offsetStr':_0x3edf0e('0xbc'),'countries':['RU']},'Asia/Yekaterinburg':{'name':'Asia/Yekaterinburg','utcOffset':0x12c,'offsetStr':'+05:00','countries':['RU']},'Asia/Omsk':{'name':'Asia/Omsk','utcOffset':0x168,'offsetStr':'+06:00','countries':['RU']},'Asia/Novosibirsk':{'name':_0x3edf0e('0xa9'),'utcOffset':0x168,'offsetStr':_0x3edf0e('0x4a'),'countries':['RU']},'Asia/Novokuznetsk':{'name':_0x3edf0e('0x108'),'utcOffset':0x1a4,'offsetStr':_0x3edf0e('0x40'),'countries':['RU']},'Asia/Krasnoyarsk':{'name':'Asia/Krasnoyarsk','utcOffset':0x1a4,'offsetStr':'+07:00','countries':['RU']},'Asia/Irkutsk':{'name':'Asia/Irkutsk','utcOffset':0x1e0,'offsetStr':_0x3edf0e('0x6b'),'countries':['RU']},'Asia/Chita':{'name':_0x3edf0e('0x24'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['RU']},'Asia/Yakutsk':{'name':_0x3edf0e('0xc8'),'utcOffset':0x21c,'offsetStr':_0x3edf0e('0x70'),'countries':['RU']},'Asia/Khandyga':{'name':_0x3edf0e('0xb4'),'utcOffset':0x21c,'offsetStr':_0x3edf0e('0x70'),'countries':['RU']},'Asia/Vladivostok':{'name':'Asia/Vladivostok','utcOffset':0x258,'offsetStr':_0x3edf0e('0x92'),'countries':['RU']},'Asia/Sakhalin':{'name':'Asia/Sakhalin','utcOffset':0x258,'offsetStr':_0x3edf0e('0x92'),'countries':['RU']},'Asia/Ust-Nera':{'name':_0x3edf0e('0x10c'),'utcOffset':0x258,'offsetStr':_0x3edf0e('0x92'),'countries':['RU']},'Asia/Magadan':{'name':_0x3edf0e('0x89'),'utcOffset':0x258,'offsetStr':_0x3edf0e('0x92'),'countries':['RU']},'Asia/Srednekolymsk':{'name':'Asia/Srednekolymsk','utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['RU']},'Asia/Kamchatka':{'name':_0x3edf0e('0x3e'),'utcOffset':0x2d0,'offsetStr':_0x3edf0e('0xfd'),'countries':['RU']},'Asia/Anadyr':{'name':'Asia/Anadyr','utcOffset':0x2d0,'offsetStr':_0x3edf0e('0xfd'),'countries':['RU']},'Asia/Riyadh':{'name':_0x3edf0e('0x31'),'utcOffset':0xb4,'offsetStr':_0x3edf0e('0xfc'),'countries':['SA','KW','YE']},'Pacific/Guadalcanal':{'name':_0x3edf0e('0xb6'),'utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['SB']},'Indian/Mahe':{'name':_0x3edf0e('0x75'),'utcOffset':0xf0,'offsetStr':_0x3edf0e('0xbc'),'countries':['SC']},'Africa/Khartoum':{'name':'Africa/Khartoum','utcOffset':0xb4,'offsetStr':_0x3edf0e('0xfc'),'countries':['SD','SS']},'Europe/Stockholm':{'name':_0x3edf0e('0x50'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['SE']},'Asia/Singapore':{'name':_0x3edf0e('0x3b'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['SG']},'America/Paramaribo':{'name':_0x3edf0e('0x63'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['SR']},'America/El_Salvador':{'name':'America/El_Salvador','utcOffset':-0x168,'offsetStr':'-06:00','countries':['SV']},'Asia/Damascus':{'name':_0x3edf0e('0x72'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['SY']},'America/Grand_Turk':{'name':'America/Grand_Turk','utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['TC']},'Africa/Ndjamena':{'name':_0x3edf0e('0x9a'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['TD']},'Indian/Kerguelen':{'name':'Indian/Kerguelen','utcOffset':0x12c,'offsetStr':_0x3edf0e('0x114'),'countries':['TF']},'Asia/Bangkok':{'name':'Asia/Bangkok','utcOffset':0x1a4,'offsetStr':'+07:00','countries':['TH','KH','LA','VN']},'Asia/Dushanbe':{'name':_0x3edf0e('0x10'),'utcOffset':0x12c,'offsetStr':'+05:00','countries':['TJ']},'Pacific/Fakaofo':{'name':_0x3edf0e('0x103'),'utcOffset':0x30c,'offsetStr':'+13:00','countries':['TK']},'Asia/Dili':{'name':'Asia/Dili','utcOffset':0x21c,'offsetStr':_0x3edf0e('0x70'),'countries':['TL']},'Asia/Ashgabat':{'name':_0x3edf0e('0x116'),'utcOffset':0x12c,'offsetStr':_0x3edf0e('0x114'),'countries':['TM']},'Africa/Tunis':{'name':_0x3edf0e('0x30'),'utcOffset':0x3c,'offsetStr':_0x3edf0e('0x10b'),'countries':['TN']},'Pacific/Tongatapu':{'name':_0x3edf0e('0xaf'),'utcOffset':0x30c,'offsetStr':'+13:00','countries':['TO']},'Europe/Istanbul':{'name':'Europe/Istanbul','utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['TR']},'America/Port_of_Spain':{'name':_0x3edf0e('0xab'),'utcOffset':-0xf0,'offsetStr':_0x3edf0e('0xdd'),'countries':['TT','AG','AI','BL','DM','GD','GP','KN','LC','MF','MS','VC','VG','VI']},'Pacific/Funafuti':{'name':'Pacific/Funafuti','utcOffset':0x2d0,'offsetStr':_0x3edf0e('0xfd'),'countries':['TV']},'Asia/Taipei':{'name':_0x3edf0e('0xf3'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['TW']},'Europe/Kiev':{'name':'Europe/Kiev','utcOffset':0x78,'offsetStr':'+02:00','countries':['UA']},'Europe/Uzhgorod':{'name':'Europe/Uzhgorod','utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['UA']},'Europe/Zaporozhye':{'name':'Europe/Zaporozhye','utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['UA']},'Pacific/Wake':{'name':_0x3edf0e('0x101'),'utcOffset':0x2d0,'offsetStr':_0x3edf0e('0xfd'),'countries':['UM']},'America/New_York':{'name':_0x3edf0e('0xd'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['US']},'America/Detroit':{'name':_0x3edf0e('0x112'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},'America/Kentucky/Louisville':{'name':_0x3edf0e('0x94'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['US']},'America/Kentucky/Monticello':{'name':_0x3edf0e('0xed'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},'America/Indiana/Indianapolis':{'name':'America/Indiana/Indianapolis','utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['US']},'America/Indiana/Vincennes':{'name':_0x3edf0e('0x32'),'utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['US']},'America/Indiana/Winamac':{'name':_0x3edf0e('0x6c'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},'America/Indiana/Marengo':{'name':'America/Indiana/Marengo','utcOffset':-0x12c,'offsetStr':_0x3edf0e('0x47'),'countries':['US']},'America/Indiana/Petersburg':{'name':'America/Indiana/Petersburg','utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},'America/Indiana/Vevay':{'name':_0x3edf0e('0xc9'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},'America/Chicago':{'name':_0x3edf0e('0xb0'),'utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['US']},'America/Indiana/Tell_City':{'name':'America/Indiana/Tell_City','utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['US']},'America/Indiana/Knox':{'name':_0x3edf0e('0xff'),'utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['US']},'America/Menominee':{'name':_0x3edf0e('0xe4'),'utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['US']},'America/North_Dakota/Center':{'name':_0x3edf0e('0xf4'),'utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['US']},'America/North_Dakota/New_Salem':{'name':_0x3edf0e('0x60'),'utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['US']},'America/North_Dakota/Beulah':{'name':'America/North_Dakota/Beulah','utcOffset':-0x168,'offsetStr':_0x3edf0e('0x3f'),'countries':['US']},'America/Denver':{'name':_0x3edf0e('0x39'),'utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['US']},'America/Boise':{'name':_0x3edf0e('0x4d'),'utcOffset':-0x1a4,'offsetStr':_0x3edf0e('0xcd'),'countries':['US']},'America/Phoenix':{'name':_0x3edf0e('0x95'),'utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['US']},'America/Los_Angeles':{'name':_0x3edf0e('0xb8'),'utcOffset':-0x1e0,'offsetStr':'-08:00','countries':['US']},'America/Metlakatla':{'name':'America/Metlakatla','utcOffset':-0x1e0,'offsetStr':_0x3edf0e('0x11a'),'countries':['US']},'America/Anchorage':{'name':_0x3edf0e('0x90'),'utcOffset':-0x21c,'offsetStr':_0x3edf0e('0xa3'),'countries':['US']},'America/Juneau':{'name':_0x3edf0e('0x86'),'utcOffset':-0x21c,'offsetStr':_0x3edf0e('0xa3'),'countries':['US']},'America/Sitka':{'name':'America/Sitka','utcOffset':-0x21c,'offsetStr':_0x3edf0e('0xa3'),'countries':['US']},'America/Yakutat':{'name':_0x3edf0e('0x8'),'utcOffset':-0x21c,'offsetStr':'-09:00','countries':['US']},'America/Nome':{'name':_0x3edf0e('0x42'),'utcOffset':-0x21c,'offsetStr':_0x3edf0e('0xa3'),'countries':['US']},'America/Adak':{'name':_0x3edf0e('0xf8'),'utcOffset':-0x258,'offsetStr':_0x3edf0e('0x2f'),'countries':['US']},'Pacific/Honolulu':{'name':_0x3edf0e('0x65'),'utcOffset':-0x258,'offsetStr':_0x3edf0e('0x2f'),'countries':['US','UM']},'America/Montevideo':{'name':_0x3edf0e('0xee'),'utcOffset':-0xb4,'offsetStr':_0x3edf0e('0x48'),'countries':['UY']},'Asia/Samarkand':{'name':_0x3edf0e('0x16'),'utcOffset':0x12c,'offsetStr':_0x3edf0e('0x114'),'countries':['UZ']},'Asia/Tashkent':{'name':'Asia/Tashkent','utcOffset':0x12c,'offsetStr':_0x3edf0e('0x114'),'countries':['UZ']},'America/Caracas':{'name':_0x3edf0e('0xb5'),'utcOffset':-0x10e,'offsetStr':_0x3edf0e('0xc2'),'countries':['VE']},'Asia/Ho_Chi_Minh':{'name':_0x3edf0e('0xc3'),'utcOffset':0x1a4,'offsetStr':_0x3edf0e('0x40'),'countries':['VN']},'Pacific/Efate':{'name':'Pacific/Efate','utcOffset':0x294,'offsetStr':_0x3edf0e('0x5'),'countries':['VU']},'Pacific/Wallis':{'name':_0x3edf0e('0xec'),'utcOffset':0x2d0,'offsetStr':_0x3edf0e('0xfd'),'countries':['WF']},'Pacific/Apia':{'name':'Pacific/Apia','utcOffset':0x348,'offsetStr':_0x3edf0e('0xac'),'countries':['WS']},'Africa/Johannesburg':{'name':_0x3edf0e('0xb2'),'utcOffset':0x78,'offsetStr':_0x3edf0e('0x79'),'countries':['ZA','LS','SZ']}}}; \ No newline at end of file +var a840_0x37a6=['Europe/Amsterdam','Africa/Casablanca','America/El_Salvador','America/Recife','America/Edmonton','Africa/Tripoli','America/Belem','Africa/Tunis','Europe/Kiev','America/Bahia_Banderas','Pacific/Apia','UTC','America/Adak','Europe/Zaporozhye','America/Godthab','Pacific/Fiji','Pacific/Marquesas','America/Santa_Isabel','Asia/Baku','Pacific/Guam','+14:00','Asia/Yakutsk','America/Atikokan','-01:00','America/Guyana','America/Kentucky/Louisville','Asia/Beirut','Pacific/Bougainville','Indian/Mahe','+09:30','Europe/Warsaw','Asia/Sakhalin','Pacific/Chatham','Australia/Perth','Asia/Ho_Chi_Minh','America/Manaus','America/Belize','Asia/Magadan','-09:00','Pacific/Tahiti','America/Thule','Europe/Riga','Europe/Paris','Atlantic/Reykjavik','Asia/Jakarta','America/Indiana/Knox','Asia/Tokyo','Europe/Helsinki','America/Puerto_Rico','Europe/Tirane','-10:00','Europe/Budapest','+09:00','Asia/Kabul','Asia/Baghdad','Asia/Dili','America/Bahia','Asia/Kamchatka','Asia/Hebron','America/Argentina/Cordoba','exports','Asia/Damascus','Asia/Pontianak','Atlantic/Azores','-08:00','America/Danmarkshavn','America/Sitka','America/Argentina/Rio_Gallegos','Pacific/Honolulu','Europe/Luxembourg','+10:30','America/Goose_Bay','Asia/Amman','Asia/Omsk','Asia/Rangoon','-03:00','America/Paramaribo','Australia/Broken_Hill','Asia/Gaza','America/North_Dakota/Center','+13:00','Asia/Macau','America/New_York','Asia/Yerevan','Pacific/Kiritimati','Europe/Simferopol','America/Argentina/Mendoza','Australia/Hobart','Atlantic/South_Georgia','Asia/Qatar','America/Guayaquil','Asia/Ulaanbaatar','America/Jamaica','Europe/Berlin','America/Dawson','Asia/Kuala_Lumpur','America/Kentucky/Monticello','Europe/Volgograd','America/Costa_Rica','Europe/Bucharest','Atlantic/Madeira','-03:30','America/Rio_Branco','guest','-07:00','Australia/Adelaide','+07:00','+06:00','Asia/Choibalsan','Europe/Rome','America/Indiana/Vincennes','Asia/Bangkok','Indian/Christmas','Asia/Novosibirsk','America/Barbados','+04:30','Atlantic/Canary','Asia/Qyzylorda','America/Boa_Vista','Asia/Tehran','+05:45','Europe/Brussels','Europe/Gibraltar','America/Boise','Indian/Mauritius','America/Hermosillo','Europe/Tallinn','America/Argentina/San_Luis','Asia/Makassar','Asia/Brunei','Pacific/Rarotonga','-05:00','Europe/Vienna','-04:00','Antarctica/Vostok','Europe/Belgrade','Pacific/Tongatapu','America/Metlakatla','America/Regina','Pacific/Fakaofo','America/Rainy_River','America/Inuvik','America/Argentina/Ushuaia','America/Iqaluit','Antarctica/Davis','America/Indiana/Petersburg','Australia/Sydney','America/Sao_Paulo','Pacific/Chuuk','Indian/Reunion','Asia/Krasnoyarsk','Australia/Lindeman','user','Australia/Brisbane','Europe/Zurich','Asia/Hong_Kong','Asia/Yekaterinburg','America/Grand_Turk','+01:00','Europe/Malta','Africa/Bissau','Asia/Manila','-04:30','America/Denver','Asia/Nicosia','America/Fort_Nelson','America/Chicago','America/Cayman','Europe/Prague','Asia/Samarkand','America/Noronha','Africa/Khartoum','+03:30','+03:00','Australia/Eucla','+11:00','+02:00','Asia/Irkutsk','Pacific/Port_Moresby','Africa/Ndjamena','Asia/Kathmandu','Asia/Jerusalem','Europe/Athens','America/Curacao','America/Blanc-Sablon','Asia/Tbilisi','+04:00','Antarctica/Mawson','America/Anchorage','America/Argentina/Catamarca','Pacific/Pago_Pago','Europe/Andorra','America/Cancun','Antarctica/Palmer','Asia/Colombo','Atlantic/Bermuda','Africa/Maputo','Australia/Darwin','Asia/Aqtau','Pacific/Wallis','Africa/Cairo','Europe/Samara','America/Nipigon','America/Tegucigalpa','+10:00','Australia/Lord_Howe','America/Fortaleza','America/Rankin_Inlet','Asia/Pyongyang','Asia/Ashgabat','America/Port_of_Spain','America/Porto_Velho','America/Merida','America/St_Johns','Europe/Copenhagen','America/Asuncion','America/Argentina/Salta','+05:00','Pacific/Niue','Pacific/Guadalcanal','Asia/Dushanbe','Pacific/Kosrae','America/Yakutat','America/Argentina/Buenos_Aires','America/La_Paz','America/North_Dakota/New_Salem','Asia/Ust-Nera','America/Indiana/Indianapolis','Europe/Minsk','+05:30','Antarctica/Troll','-11:00','America/Ojinaga','Asia/Riyadh','Europe/Vilnius','America/Argentina/Tucuman','Antarctica/DumontDUrville','America/Lima','Australia/Melbourne','+08:00','America/Nome','America/Detroit','-09:30','America/Panama','+12:00','Pacific/Norfolk','America/Vancouver','America/Indiana/Tell_City','Antarctica/Rothera','Asia/Taipei','America/Managua','+00:00','Africa/Monrovia','America/Cuiaba','-06:00','America/Havana','America/Matamoros','Europe/Oslo','Asia/Oral','America/Pangnirtung','Africa/Algiers','Europe/Madrid','America/Resolute','Asia/Dhaka','Africa/Lagos','America/Argentina/Jujuy','Asia/Novokuznetsk','Europe/Dublin','America/Santo_Domingo','America/Halifax','Asia/Bishkek','+08:45','Europe/Lisbon','Europe/Moscow','America/Menominee','Pacific/Funafuti','Asia/Chita','America/Indiana/Marengo','America/Dawson_Creek','Pacific/Gambier','America/Maceio','Antarctica/Syowa','Pacific/Pitcairn','Atlantic/Cape_Verde','America/North_Dakota/Beulah','America/Glace_Bay','Pacific/Palau','America/Indiana/Winamac','Pacific/Auckland','America/Creston','America/Scoresbysund','America/Whitehorse','Africa/Johannesburg','Asia/Seoul','-02:00','+08:30','Indian/Chagos','Atlantic/Faroe','+06:30','Africa/El_Aaiun','Europe/Sofia','America/Mexico_City','Asia/Thimphu'];(function(_0x490178,_0x37a609){var _0x15681c=function(_0x20c7eb){while(--_0x20c7eb){_0x490178['push'](_0x490178['shift']());}};_0x15681c(++_0x37a609);}(a840_0x37a6,0xdf));var a840_0x1568=function(_0x490178,_0x37a609){_0x490178=_0x490178-0x0;var _0x15681c=a840_0x37a6[_0x490178];return _0x15681c;};var _0x35a443=a840_0x1568;'use strict';module[_0x35a443('0x8c')]={'userRoles':[_0x35a443('0xb7'),_0x35a443('0xe8'),'admin'],'timezones':{'Europe/Andorra':{'name':_0x35a443('0x10f'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['AD']},'Asia/Dubai':{'name':'Asia/Dubai','utcOffset':0xf0,'offsetStr':_0x35a443('0x10a'),'countries':['AE','OM']},'Asia/Kabul':{'name':_0x35a443('0x85'),'utcOffset':0x10e,'offsetStr':_0x35a443('0xc3'),'countries':['AF']},'Europe/Tirane':{'name':_0x35a443('0x81'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['AL']},'Asia/Yerevan':{'name':_0x35a443('0xa3'),'utcOffset':0xf0,'offsetStr':_0x35a443('0x10a'),'countries':['AM']},'Antarctica/Rothera':{'name':_0x35a443('0x19'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AQ']},'Antarctica/Palmer':{'name':_0x35a443('0x111'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AQ']},'Antarctica/Mawson':{'name':_0x35a443('0x10b'),'utcOffset':0x12c,'offsetStr':_0x35a443('0x129'),'countries':['AQ']},'Antarctica/Davis':{'name':_0x35a443('0xe0'),'utcOffset':0x1a4,'offsetStr':'+07:00','countries':['AQ']},'Antarctica/Casey':{'name':'Antarctica/Casey','utcOffset':0x1e0,'offsetStr':_0x35a443('0x10'),'countries':['AQ']},'Antarctica/Vostok':{'name':_0x35a443('0xd6'),'utcOffset':0x168,'offsetStr':'+06:00','countries':['AQ']},'Antarctica/DumontDUrville':{'name':_0x35a443('0xd'),'utcOffset':0x258,'offsetStr':_0x35a443('0x11c'),'countries':['AQ']},'Antarctica/Syowa':{'name':_0x35a443('0x3a'),'utcOffset':0xb4,'offsetStr':_0x35a443('0xfd'),'countries':['AQ']},'Antarctica/Troll':{'name':_0x35a443('0x7'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['AQ']},'America/Argentina/Buenos_Aires':{'name':_0x35a443('0x0'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AR']},'America/Argentina/Cordoba':{'name':_0x35a443('0x8b'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AR']},'America/Argentina/Salta':{'name':_0x35a443('0x128'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AR']},'America/Argentina/Jujuy':{'name':_0x35a443('0x2a'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AR']},'America/Argentina/Tucuman':{'name':_0x35a443('0xc'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AR']},'America/Argentina/Catamarca':{'name':_0x35a443('0x10d'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AR']},'America/Argentina/La_Rioja':{'name':'America/Argentina/La_Rioja','utcOffset':-0xb4,'offsetStr':'-03:00','countries':['AR']},'America/Argentina/San_Juan':{'name':'America/Argentina/San_Juan','utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AR']},'America/Argentina/Mendoza':{'name':_0x35a443('0xa6'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['AR']},'America/Argentina/San_Luis':{'name':_0x35a443('0xcf'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AR']},'America/Argentina/Rio_Gallegos':{'name':_0x35a443('0x93'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['AR']},'America/Argentina/Ushuaia':{'name':_0x35a443('0xde'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['AR']},'Pacific/Pago_Pago':{'name':_0x35a443('0x10e'),'utcOffset':-0x294,'offsetStr':_0x35a443('0x8'),'countries':['AS','UM']},'Europe/Vienna':{'name':_0x35a443('0xd4'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['AT']},'Australia/Lord_Howe':{'name':_0x35a443('0x11d'),'utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['AU']},'Antarctica/Macquarie':{'name':'Antarctica/Macquarie','utcOffset':0x294,'offsetStr':'+11:00','countries':['AU']},'Australia/Hobart':{'name':_0x35a443('0xa7'),'utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['AU']},'Australia/Currie':{'name':'Australia/Currie','utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['AU']},'Australia/Melbourne':{'name':_0x35a443('0xf'),'utcOffset':0x294,'offsetStr':'+11:00','countries':['AU']},'Australia/Sydney':{'name':_0x35a443('0xe2'),'utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['AU']},'Australia/Broken_Hill':{'name':_0x35a443('0x9d'),'utcOffset':0x276,'offsetStr':_0x35a443('0x96'),'countries':['AU']},'Australia/Brisbane':{'name':_0x35a443('0xe9'),'utcOffset':0x258,'offsetStr':_0x35a443('0x11c'),'countries':['AU']},'Australia/Lindeman':{'name':_0x35a443('0xe7'),'utcOffset':0x258,'offsetStr':_0x35a443('0x11c'),'countries':['AU']},'Australia/Adelaide':{'name':_0x35a443('0xb9'),'utcOffset':0x276,'offsetStr':_0x35a443('0x96'),'countries':['AU']},'Australia/Darwin':{'name':_0x35a443('0x115'),'utcOffset':0x23a,'offsetStr':_0x35a443('0x6d'),'countries':['AU']},'Australia/Perth':{'name':_0x35a443('0x71'),'utcOffset':0x1e0,'offsetStr':_0x35a443('0x10'),'countries':['AU']},'Australia/Eucla':{'name':_0x35a443('0xfe'),'utcOffset':0x20d,'offsetStr':_0x35a443('0x30'),'countries':['AU']},'Asia/Baku':{'name':_0x35a443('0x62'),'utcOffset':0xf0,'offsetStr':_0x35a443('0x10a'),'countries':['AZ']},'America/Barbados':{'name':_0x35a443('0xc2'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['BB']},'Asia/Dhaka':{'name':_0x35a443('0x28'),'utcOffset':0x168,'offsetStr':_0x35a443('0xbb'),'countries':['BD']},'Europe/Brussels':{'name':_0x35a443('0xc9'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['BE']},'Europe/Sofia':{'name':_0x35a443('0x4d'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['BG']},'Atlantic/Bermuda':{'name':_0x35a443('0x113'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['BM']},'Asia/Brunei':{'name':_0x35a443('0xd1'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['BN']},'America/La_Paz':{'name':_0x35a443('0x1'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['BO']},'America/Noronha':{'name':_0x35a443('0xfa'),'utcOffset':-0x78,'offsetStr':_0x35a443('0x47'),'countries':['BR']},'America/Belem':{'name':_0x35a443('0x56'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['BR']},'America/Fortaleza':{'name':_0x35a443('0x11e'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['BR']},'America/Recife':{'name':_0x35a443('0x53'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['BR']},'America/Araguaina':{'name':'America/Araguaina','utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['BR']},'America/Maceio':{'name':_0x35a443('0x39'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['BR']},'America/Bahia':{'name':_0x35a443('0x88'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['BR']},'America/Sao_Paulo':{'name':_0x35a443('0xe3'),'utcOffset':-0x78,'offsetStr':_0x35a443('0x47'),'countries':['BR']},'America/Campo_Grande':{'name':'America/Campo_Grande','utcOffset':-0xb4,'offsetStr':'-03:00','countries':['BR']},'America/Cuiaba':{'name':_0x35a443('0x1e'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['BR']},'America/Santarem':{'name':'America/Santarem','utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['BR']},'America/Porto_Velho':{'name':_0x35a443('0x123'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['BR']},'America/Boa_Vista':{'name':_0x35a443('0xc6'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['BR']},'America/Manaus':{'name':_0x35a443('0x73'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['BR']},'America/Eirunepe':{'name':'America/Eirunepe','utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['BR']},'America/Rio_Branco':{'name':_0x35a443('0xb6'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['BR']},'America/Nassau':{'name':'America/Nassau','utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['BS']},'Asia/Thimphu':{'name':_0x35a443('0x4f'),'utcOffset':0x168,'offsetStr':_0x35a443('0xbb'),'countries':['BT']},'Europe/Minsk':{'name':_0x35a443('0x5'),'utcOffset':0xb4,'offsetStr':'+03:00','countries':['BY']},'America/Belize':{'name':_0x35a443('0x74'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['BZ']},'America/St_Johns':{'name':_0x35a443('0x125'),'utcOffset':-0xd2,'offsetStr':_0x35a443('0xb5'),'countries':['CA']},'America/Halifax':{'name':_0x35a443('0x2e'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['CA']},'America/Glace_Bay':{'name':_0x35a443('0x3e'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['CA']},'America/Moncton':{'name':'America/Moncton','utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['CA']},'America/Goose_Bay':{'name':_0x35a443('0x97'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['CA']},'America/Blanc-Sablon':{'name':_0x35a443('0x108'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['CA']},'America/Toronto':{'name':'America/Toronto','utcOffset':-0x12c,'offsetStr':'-05:00','countries':['CA']},'America/Nipigon':{'name':_0x35a443('0x11a'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['CA']},'America/Thunder_Bay':{'name':'America/Thunder_Bay','utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['CA']},'America/Iqaluit':{'name':_0x35a443('0xdf'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['CA']},'America/Pangnirtung':{'name':_0x35a443('0x24'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['CA']},'America/Resolute':{'name':_0x35a443('0x27'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['CA']},'America/Atikokan':{'name':_0x35a443('0x66'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['CA']},'America/Rankin_Inlet':{'name':_0x35a443('0x11f'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['CA']},'America/Winnipeg':{'name':'America/Winnipeg','utcOffset':-0x168,'offsetStr':'-06:00','countries':['CA']},'America/Rainy_River':{'name':_0x35a443('0xdc'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['CA']},'America/Regina':{'name':_0x35a443('0xda'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['CA']},'America/Swift_Current':{'name':'America/Swift_Current','utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['CA']},'America/Edmonton':{'name':_0x35a443('0x54'),'utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['CA']},'America/Cambridge_Bay':{'name':'America/Cambridge_Bay','utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['CA']},'America/Yellowknife':{'name':'America/Yellowknife','utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['CA']},'America/Inuvik':{'name':_0x35a443('0xdd'),'utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['CA']},'America/Creston':{'name':_0x35a443('0x42'),'utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['CA']},'America/Dawson_Creek':{'name':_0x35a443('0x37'),'utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['CA']},'America/Fort_Nelson':{'name':_0x35a443('0xf5'),'utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['CA']},'America/Vancouver':{'name':_0x35a443('0x17'),'utcOffset':-0x1e0,'offsetStr':_0x35a443('0x90'),'countries':['CA']},'America/Whitehorse':{'name':_0x35a443('0x44'),'utcOffset':-0x1e0,'offsetStr':_0x35a443('0x90'),'countries':['CA']},'America/Dawson':{'name':_0x35a443('0xae'),'utcOffset':-0x1e0,'offsetStr':_0x35a443('0x90'),'countries':['CA']},'Indian/Cocos':{'name':'Indian/Cocos','utcOffset':0x186,'offsetStr':_0x35a443('0x4b'),'countries':['CC']},'Europe/Zurich':{'name':_0x35a443('0xea'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['CH','DE','LI']},'Africa/Abidjan':{'name':'Africa/Abidjan','utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['CI','BF','GM','GN','ML','MR','SH','SL','SN','ST','TG']},'Pacific/Rarotonga':{'name':_0x35a443('0xd2'),'utcOffset':-0x258,'offsetStr':_0x35a443('0x82'),'countries':['CK']},'America/Santiago':{'name':'America/Santiago','utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['CL']},'Pacific/Easter':{'name':'Pacific/Easter','utcOffset':-0x12c,'offsetStr':'-05:00','countries':['CL']},'Asia/Shanghai':{'name':'Asia/Shanghai','utcOffset':0x1e0,'offsetStr':'+08:00','countries':['CN']},'Asia/Urumqi':{'name':'Asia/Urumqi','utcOffset':0x168,'offsetStr':_0x35a443('0xbb'),'countries':['CN']},'America/Bogota':{'name':'America/Bogota','utcOffset':-0x12c,'offsetStr':'-05:00','countries':['CO']},'America/Costa_Rica':{'name':_0x35a443('0xb2'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['CR']},'America/Havana':{'name':_0x35a443('0x20'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['CU']},'Atlantic/Cape_Verde':{'name':_0x35a443('0x3c'),'utcOffset':-0x3c,'offsetStr':'-01:00','countries':['CV']},'America/Curacao':{'name':_0x35a443('0x107'),'utcOffset':-0xf0,'offsetStr':'-04:00','countries':['CW','AW','BQ','SX']},'Indian/Christmas':{'name':_0x35a443('0xc0'),'utcOffset':0x1a4,'offsetStr':_0x35a443('0xba'),'countries':['CX']},'Asia/Nicosia':{'name':_0x35a443('0xf4'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['CY']},'Europe/Prague':{'name':_0x35a443('0xf8'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['CZ','SK']},'Europe/Berlin':{'name':_0x35a443('0xad'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['DE']},'Europe/Copenhagen':{'name':_0x35a443('0x126'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['DK']},'America/Santo_Domingo':{'name':_0x35a443('0x2d'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['DO']},'Africa/Algiers':{'name':_0x35a443('0x25'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['DZ']},'America/Guayaquil':{'name':_0x35a443('0xaa'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['EC']},'Pacific/Galapagos':{'name':'Pacific/Galapagos','utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['EC']},'Europe/Tallinn':{'name':_0x35a443('0xce'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['EE']},'Africa/Cairo':{'name':_0x35a443('0x118'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['EG']},'Africa/El_Aaiun':{'name':_0x35a443('0x4c'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['EH']},'Europe/Madrid':{'name':_0x35a443('0x26'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['ES']},'Africa/Ceuta':{'name':'Africa/Ceuta','utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['ES']},'Atlantic/Canary':{'name':_0x35a443('0xc4'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['ES']},'Europe/Helsinki':{'name':_0x35a443('0x7f'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['FI','AX']},'Pacific/Fiji':{'name':_0x35a443('0x5f'),'utcOffset':0x2d0,'offsetStr':'+12:00','countries':['FJ']},'Atlantic/Stanley':{'name':'Atlantic/Stanley','utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['FK']},'Pacific/Chuuk':{'name':_0x35a443('0xe4'),'utcOffset':0x258,'offsetStr':_0x35a443('0x11c'),'countries':['FM']},'Pacific/Pohnpei':{'name':'Pacific/Pohnpei','utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['FM']},'Pacific/Kosrae':{'name':_0x35a443('0x12d'),'utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['FM']},'Atlantic/Faroe':{'name':_0x35a443('0x4a'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['FO']},'Europe/Paris':{'name':_0x35a443('0x7a'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['FR']},'UTC':{'name':_0x35a443('0x5b'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['GB','GG','IM','JE']},'Europe/London':{'name':'Europe/London','utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['GB','GG','IM','JE']},'Asia/Tbilisi':{'name':_0x35a443('0x109'),'utcOffset':0xf0,'offsetStr':'+04:00','countries':['GE']},'America/Cayenne':{'name':'America/Cayenne','utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['GF']},'Africa/Accra':{'name':'Africa/Accra','utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['GH']},'Europe/Gibraltar':{'name':_0x35a443('0xca'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['GI']},'America/Godthab':{'name':_0x35a443('0x5e'),'utcOffset':-0xb4,'offsetStr':'-03:00','countries':['GL']},'America/Danmarkshavn':{'name':_0x35a443('0x91'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['GL']},'America/Scoresbysund':{'name':_0x35a443('0x43'),'utcOffset':-0x3c,'offsetStr':_0x35a443('0x67'),'countries':['GL']},'America/Thule':{'name':_0x35a443('0x78'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['GL']},'Europe/Athens':{'name':_0x35a443('0x106'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['GR']},'Atlantic/South_Georgia':{'name':_0x35a443('0xa8'),'utcOffset':-0x78,'offsetStr':_0x35a443('0x47'),'countries':['GS']},'America/Guatemala':{'name':'America/Guatemala','utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['GT']},'Pacific/Guam':{'name':_0x35a443('0x63'),'utcOffset':0x258,'offsetStr':_0x35a443('0x11c'),'countries':['GU','MP']},'Africa/Bissau':{'name':_0x35a443('0xf0'),'utcOffset':0x0,'offsetStr':'+00:00','countries':['GW']},'America/Guyana':{'name':_0x35a443('0x68'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['GY']},'Asia/Hong_Kong':{'name':_0x35a443('0xeb'),'utcOffset':0x1e0,'offsetStr':_0x35a443('0x10'),'countries':['HK']},'America/Tegucigalpa':{'name':_0x35a443('0x11b'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['HN']},'America/Port-au-Prince':{'name':'America/Port-au-Prince','utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['HT']},'Europe/Budapest':{'name':_0x35a443('0x83'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['HU']},'Asia/Jakarta':{'name':_0x35a443('0x7c'),'utcOffset':0x1a4,'offsetStr':'+07:00','countries':['ID']},'Asia/Pontianak':{'name':_0x35a443('0x8e'),'utcOffset':0x1a4,'offsetStr':_0x35a443('0xba'),'countries':['ID']},'Asia/Makassar':{'name':_0x35a443('0xd0'),'utcOffset':0x1e0,'offsetStr':_0x35a443('0x10'),'countries':['ID']},'Asia/Jayapura':{'name':'Asia/Jayapura','utcOffset':0x21c,'offsetStr':'+09:00','countries':['ID']},'Europe/Dublin':{'name':_0x35a443('0x2c'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['IE']},'Asia/Jerusalem':{'name':_0x35a443('0x105'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['IL']},'Asia/Kolkata':{'name':'Asia/Kolkata','utcOffset':0x14a,'offsetStr':_0x35a443('0x6'),'countries':['IN']},'Indian/Chagos':{'name':_0x35a443('0x49'),'utcOffset':0x168,'offsetStr':_0x35a443('0xbb'),'countries':['IO']},'Asia/Baghdad':{'name':_0x35a443('0x86'),'utcOffset':0xb4,'offsetStr':'+03:00','countries':['IQ']},'Asia/Tehran':{'name':_0x35a443('0xc7'),'utcOffset':0xd2,'offsetStr':_0x35a443('0xfc'),'countries':['IR']},'Atlantic/Reykjavik':{'name':_0x35a443('0x7b'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['IS']},'Europe/Rome':{'name':_0x35a443('0xbd'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['IT','SM','VA']},'America/Jamaica':{'name':_0x35a443('0xac'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['JM']},'Asia/Amman':{'name':_0x35a443('0x98'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['JO']},'Asia/Tokyo':{'name':_0x35a443('0x7e'),'utcOffset':0x21c,'offsetStr':_0x35a443('0x84'),'countries':['JP']},'Africa/Nairobi':{'name':'Africa/Nairobi','utcOffset':0xb4,'offsetStr':_0x35a443('0xfd'),'countries':['KE','DJ','ER','ET','KM','MG','SO','TZ','UG','YT']},'Asia/Bishkek':{'name':_0x35a443('0x2f'),'utcOffset':0x168,'offsetStr':'+06:00','countries':['KG']},'Pacific/Tarawa':{'name':'Pacific/Tarawa','utcOffset':0x2d0,'offsetStr':'+12:00','countries':['KI']},'Pacific/Enderbury':{'name':'Pacific/Enderbury','utcOffset':0x30c,'offsetStr':_0x35a443('0xa0'),'countries':['KI']},'Pacific/Kiritimati':{'name':_0x35a443('0xa4'),'utcOffset':0x348,'offsetStr':'+14:00','countries':['KI']},'Asia/Pyongyang':{'name':_0x35a443('0x120'),'utcOffset':0x1fe,'offsetStr':_0x35a443('0x48'),'countries':['KP']},'Asia/Seoul':{'name':_0x35a443('0x46'),'utcOffset':0x21c,'offsetStr':_0x35a443('0x84'),'countries':['KR']},'America/Cayman':{'name':_0x35a443('0xf7'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['KY']},'Asia/Almaty':{'name':'Asia/Almaty','utcOffset':0x168,'offsetStr':_0x35a443('0xbb'),'countries':['KZ']},'Asia/Qyzylorda':{'name':_0x35a443('0xc5'),'utcOffset':0x168,'offsetStr':_0x35a443('0xbb'),'countries':['KZ']},'Asia/Aqtobe':{'name':'Asia/Aqtobe','utcOffset':0x12c,'offsetStr':_0x35a443('0x129'),'countries':['KZ']},'Asia/Aqtau':{'name':_0x35a443('0x116'),'utcOffset':0x12c,'offsetStr':_0x35a443('0x129'),'countries':['KZ']},'Asia/Oral':{'name':_0x35a443('0x23'),'utcOffset':0x12c,'offsetStr':'+05:00','countries':['KZ']},'Asia/Beirut':{'name':_0x35a443('0x6a'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['LB']},'Asia/Colombo':{'name':_0x35a443('0x112'),'utcOffset':0x14a,'offsetStr':_0x35a443('0x6'),'countries':['LK']},'Africa/Monrovia':{'name':_0x35a443('0x1d'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['LR']},'Europe/Vilnius':{'name':_0x35a443('0xb'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['LT']},'Europe/Luxembourg':{'name':_0x35a443('0x95'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['LU']},'Europe/Riga':{'name':_0x35a443('0x79'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['LV']},'Africa/Tripoli':{'name':_0x35a443('0x55'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['LY']},'Africa/Casablanca':{'name':_0x35a443('0x51'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['MA']},'Europe/Monaco':{'name':'Europe/Monaco','utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['MC']},'Europe/Chisinau':{'name':'Europe/Chisinau','utcOffset':0x78,'offsetStr':'+02:00','countries':['MD']},'Pacific/Majuro':{'name':'Pacific/Majuro','utcOffset':0x2d0,'offsetStr':_0x35a443('0x15'),'countries':['MH']},'Pacific/Kwajalein':{'name':'Pacific/Kwajalein','utcOffset':0x2d0,'offsetStr':_0x35a443('0x15'),'countries':['MH']},'Asia/Rangoon':{'name':_0x35a443('0x9a'),'utcOffset':0x186,'offsetStr':_0x35a443('0x4b'),'countries':['MM']},'Asia/Ulaanbaatar':{'name':_0x35a443('0xab'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['MN']},'Asia/Hovd':{'name':'Asia/Hovd','utcOffset':0x1a4,'offsetStr':_0x35a443('0xba'),'countries':['MN']},'Asia/Choibalsan':{'name':_0x35a443('0xbc'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['MN']},'Asia/Macau':{'name':_0x35a443('0xa1'),'utcOffset':0x1e0,'offsetStr':_0x35a443('0x10'),'countries':['MO']},'America/Martinique':{'name':'America/Martinique','utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['MQ']},'Europe/Malta':{'name':_0x35a443('0xef'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['MT']},'Indian/Mauritius':{'name':_0x35a443('0xcc'),'utcOffset':0xf0,'offsetStr':_0x35a443('0x10a'),'countries':['MU']},'Indian/Maldives':{'name':'Indian/Maldives','utcOffset':0x12c,'offsetStr':_0x35a443('0x129'),'countries':['MV']},'America/Mexico_City':{'name':_0x35a443('0x4e'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['MX']},'America/Cancun':{'name':_0x35a443('0x110'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['MX']},'America/Merida':{'name':_0x35a443('0x124'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['MX']},'America/Monterrey':{'name':'America/Monterrey','utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['MX']},'America/Matamoros':{'name':_0x35a443('0x21'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['MX']},'America/Mazatlan':{'name':'America/Mazatlan','utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['MX']},'America/Chihuahua':{'name':'America/Chihuahua','utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['MX']},'America/Ojinaga':{'name':_0x35a443('0x9'),'utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['MX']},'America/Hermosillo':{'name':_0x35a443('0xcd'),'utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['MX']},'America/Tijuana':{'name':'America/Tijuana','utcOffset':-0x1e0,'offsetStr':_0x35a443('0x90'),'countries':['MX']},'America/Santa_Isabel':{'name':_0x35a443('0x61'),'utcOffset':-0x1e0,'offsetStr':_0x35a443('0x90'),'countries':['MX']},'America/Bahia_Banderas':{'name':_0x35a443('0x59'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['MX']},'Asia/Kuala_Lumpur':{'name':_0x35a443('0xaf'),'utcOffset':0x1e0,'offsetStr':_0x35a443('0x10'),'countries':['MY']},'Asia/Kuching':{'name':'Asia/Kuching','utcOffset':0x1e0,'offsetStr':_0x35a443('0x10'),'countries':['MY']},'Africa/Maputo':{'name':_0x35a443('0x114'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['MZ','BI','BW','CD','MW','RW','ZM','ZW']},'Africa/Windhoek':{'name':'Africa/Windhoek','utcOffset':0x78,'offsetStr':'+02:00','countries':['NA']},'Pacific/Noumea':{'name':'Pacific/Noumea','utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['NC']},'Pacific/Norfolk':{'name':_0x35a443('0x16'),'utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['NF']},'Africa/Lagos':{'name':_0x35a443('0x29'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['NG','AO','BJ','CD','CF','CG','CM','GA','GQ','NE']},'America/Managua':{'name':_0x35a443('0x1b'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['NI']},'Europe/Amsterdam':{'name':_0x35a443('0x50'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['NL']},'Europe/Oslo':{'name':_0x35a443('0x22'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['NO','SJ']},'Asia/Kathmandu':{'name':_0x35a443('0x104'),'utcOffset':0x159,'offsetStr':_0x35a443('0xc8'),'countries':['NP']},'Pacific/Nauru':{'name':'Pacific/Nauru','utcOffset':0x2d0,'offsetStr':_0x35a443('0x15'),'countries':['NR']},'Pacific/Niue':{'name':_0x35a443('0x12a'),'utcOffset':-0x294,'offsetStr':_0x35a443('0x8'),'countries':['NU']},'Pacific/Auckland':{'name':_0x35a443('0x41'),'utcOffset':0x30c,'offsetStr':'+13:00','countries':['NZ','AQ']},'Pacific/Chatham':{'name':_0x35a443('0x70'),'utcOffset':0x339,'offsetStr':'+13:45','countries':['NZ']},'America/Panama':{'name':_0x35a443('0x14'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['PA']},'America/Lima':{'name':_0x35a443('0xe'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['PE']},'Pacific/Tahiti':{'name':_0x35a443('0x77'),'utcOffset':-0x258,'offsetStr':'-10:00','countries':['PF']},'Pacific/Marquesas':{'name':_0x35a443('0x60'),'utcOffset':-0x23a,'offsetStr':_0x35a443('0x13'),'countries':['PF']},'Pacific/Gambier':{'name':_0x35a443('0x38'),'utcOffset':-0x21c,'offsetStr':_0x35a443('0x76'),'countries':['PF']},'Pacific/Port_Moresby':{'name':_0x35a443('0x102'),'utcOffset':0x258,'offsetStr':'+10:00','countries':['PG']},'Pacific/Bougainville':{'name':_0x35a443('0x6b'),'utcOffset':0x294,'offsetStr':'+11:00','countries':['PG']},'Asia/Manila':{'name':_0x35a443('0xf1'),'utcOffset':0x1e0,'offsetStr':_0x35a443('0x10'),'countries':['PH']},'Asia/Karachi':{'name':'Asia/Karachi','utcOffset':0x12c,'offsetStr':'+05:00','countries':['PK']},'Europe/Warsaw':{'name':_0x35a443('0x6e'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['PL']},'America/Miquelon':{'name':'America/Miquelon','utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['PM']},'Pacific/Pitcairn':{'name':_0x35a443('0x3b'),'utcOffset':-0x1e0,'offsetStr':_0x35a443('0x90'),'countries':['PN']},'America/Puerto_Rico':{'name':_0x35a443('0x80'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['PR']},'Asia/Gaza':{'name':_0x35a443('0x9e'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['PS']},'Asia/Hebron':{'name':_0x35a443('0x8a'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['PS']},'Europe/Lisbon':{'name':_0x35a443('0x31'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['PT']},'Atlantic/Madeira':{'name':_0x35a443('0xb4'),'utcOffset':0x0,'offsetStr':_0x35a443('0x1c'),'countries':['PT']},'Atlantic/Azores':{'name':_0x35a443('0x8f'),'utcOffset':-0x3c,'offsetStr':'-01:00','countries':['PT']},'Pacific/Palau':{'name':_0x35a443('0x3f'),'utcOffset':0x21c,'offsetStr':_0x35a443('0x84'),'countries':['PW']},'America/Asuncion':{'name':_0x35a443('0x127'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['PY']},'Asia/Qatar':{'name':_0x35a443('0xa9'),'utcOffset':0xb4,'offsetStr':_0x35a443('0xfd'),'countries':['QA','BH']},'Indian/Reunion':{'name':_0x35a443('0xe5'),'utcOffset':0xf0,'offsetStr':_0x35a443('0x10a'),'countries':['RE','TF']},'Europe/Bucharest':{'name':_0x35a443('0xb3'),'utcOffset':0x78,'offsetStr':'+02:00','countries':['RO']},'Europe/Belgrade':{'name':_0x35a443('0xd7'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['RS','BA','HR','ME','MK','SI']},'Europe/Kaliningrad':{'name':'Europe/Kaliningrad','utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['RU']},'Europe/Moscow':{'name':_0x35a443('0x32'),'utcOffset':0xb4,'offsetStr':_0x35a443('0xfd'),'countries':['RU']},'Europe/Simferopol':{'name':_0x35a443('0xa5'),'utcOffset':0xb4,'offsetStr':_0x35a443('0xfd'),'countries':['RU']},'Europe/Volgograd':{'name':_0x35a443('0xb1'),'utcOffset':0xb4,'offsetStr':_0x35a443('0xfd'),'countries':['RU']},'Europe/Samara':{'name':_0x35a443('0x119'),'utcOffset':0xf0,'offsetStr':_0x35a443('0x10a'),'countries':['RU']},'Asia/Yekaterinburg':{'name':_0x35a443('0xec'),'utcOffset':0x12c,'offsetStr':_0x35a443('0x129'),'countries':['RU']},'Asia/Omsk':{'name':_0x35a443('0x99'),'utcOffset':0x168,'offsetStr':_0x35a443('0xbb'),'countries':['RU']},'Asia/Novosibirsk':{'name':_0x35a443('0xc1'),'utcOffset':0x168,'offsetStr':_0x35a443('0xbb'),'countries':['RU']},'Asia/Novokuznetsk':{'name':_0x35a443('0x2b'),'utcOffset':0x1a4,'offsetStr':_0x35a443('0xba'),'countries':['RU']},'Asia/Krasnoyarsk':{'name':_0x35a443('0xe6'),'utcOffset':0x1a4,'offsetStr':_0x35a443('0xba'),'countries':['RU']},'Asia/Irkutsk':{'name':_0x35a443('0x101'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['RU']},'Asia/Chita':{'name':_0x35a443('0x35'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['RU']},'Asia/Yakutsk':{'name':_0x35a443('0x65'),'utcOffset':0x21c,'offsetStr':'+09:00','countries':['RU']},'Asia/Khandyga':{'name':'Asia/Khandyga','utcOffset':0x21c,'offsetStr':_0x35a443('0x84'),'countries':['RU']},'Asia/Vladivostok':{'name':'Asia/Vladivostok','utcOffset':0x258,'offsetStr':_0x35a443('0x11c'),'countries':['RU']},'Asia/Sakhalin':{'name':_0x35a443('0x6f'),'utcOffset':0x258,'offsetStr':'+10:00','countries':['RU']},'Asia/Ust-Nera':{'name':_0x35a443('0x3'),'utcOffset':0x258,'offsetStr':_0x35a443('0x11c'),'countries':['RU']},'Asia/Magadan':{'name':_0x35a443('0x75'),'utcOffset':0x258,'offsetStr':_0x35a443('0x11c'),'countries':['RU']},'Asia/Srednekolymsk':{'name':'Asia/Srednekolymsk','utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['RU']},'Asia/Kamchatka':{'name':_0x35a443('0x89'),'utcOffset':0x2d0,'offsetStr':_0x35a443('0x15'),'countries':['RU']},'Asia/Anadyr':{'name':'Asia/Anadyr','utcOffset':0x2d0,'offsetStr':'+12:00','countries':['RU']},'Asia/Riyadh':{'name':_0x35a443('0xa'),'utcOffset':0xb4,'offsetStr':_0x35a443('0xfd'),'countries':['SA','KW','YE']},'Pacific/Guadalcanal':{'name':_0x35a443('0x12b'),'utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['SB']},'Indian/Mahe':{'name':_0x35a443('0x6c'),'utcOffset':0xf0,'offsetStr':_0x35a443('0x10a'),'countries':['SC']},'Africa/Khartoum':{'name':_0x35a443('0xfb'),'utcOffset':0xb4,'offsetStr':_0x35a443('0xfd'),'countries':['SD','SS']},'Europe/Stockholm':{'name':'Europe/Stockholm','utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['SE']},'Asia/Singapore':{'name':'Asia/Singapore','utcOffset':0x1e0,'offsetStr':'+08:00','countries':['SG']},'America/Paramaribo':{'name':_0x35a443('0x9c'),'utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['SR']},'America/El_Salvador':{'name':_0x35a443('0x52'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['SV']},'Asia/Damascus':{'name':_0x35a443('0x8d'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['SY']},'America/Grand_Turk':{'name':_0x35a443('0xed'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['TC']},'Africa/Ndjamena':{'name':_0x35a443('0x103'),'utcOffset':0x3c,'offsetStr':'+01:00','countries':['TD']},'Indian/Kerguelen':{'name':'Indian/Kerguelen','utcOffset':0x12c,'offsetStr':_0x35a443('0x129'),'countries':['TF']},'Asia/Bangkok':{'name':_0x35a443('0xbf'),'utcOffset':0x1a4,'offsetStr':_0x35a443('0xba'),'countries':['TH','KH','LA','VN']},'Asia/Dushanbe':{'name':_0x35a443('0x12c'),'utcOffset':0x12c,'offsetStr':_0x35a443('0x129'),'countries':['TJ']},'Pacific/Fakaofo':{'name':_0x35a443('0xdb'),'utcOffset':0x30c,'offsetStr':_0x35a443('0xa0'),'countries':['TK']},'Asia/Dili':{'name':_0x35a443('0x87'),'utcOffset':0x21c,'offsetStr':_0x35a443('0x84'),'countries':['TL']},'Asia/Ashgabat':{'name':_0x35a443('0x121'),'utcOffset':0x12c,'offsetStr':'+05:00','countries':['TM']},'Africa/Tunis':{'name':_0x35a443('0x57'),'utcOffset':0x3c,'offsetStr':_0x35a443('0xee'),'countries':['TN']},'Pacific/Tongatapu':{'name':_0x35a443('0xd8'),'utcOffset':0x30c,'offsetStr':_0x35a443('0xa0'),'countries':['TO']},'Europe/Istanbul':{'name':'Europe/Istanbul','utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['TR']},'America/Port_of_Spain':{'name':_0x35a443('0x122'),'utcOffset':-0xf0,'offsetStr':_0x35a443('0xd5'),'countries':['TT','AG','AI','BL','DM','GD','GP','KN','LC','MF','MS','VC','VG','VI']},'Pacific/Funafuti':{'name':_0x35a443('0x34'),'utcOffset':0x2d0,'offsetStr':_0x35a443('0x15'),'countries':['TV']},'Asia/Taipei':{'name':_0x35a443('0x1a'),'utcOffset':0x1e0,'offsetStr':'+08:00','countries':['TW']},'Europe/Kiev':{'name':_0x35a443('0x58'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['UA']},'Europe/Uzhgorod':{'name':'Europe/Uzhgorod','utcOffset':0x78,'offsetStr':'+02:00','countries':['UA']},'Europe/Zaporozhye':{'name':_0x35a443('0x5d'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['UA']},'Pacific/Wake':{'name':'Pacific/Wake','utcOffset':0x2d0,'offsetStr':_0x35a443('0x15'),'countries':['UM']},'America/New_York':{'name':_0x35a443('0xa2'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},'America/Detroit':{'name':_0x35a443('0x12'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['US']},'America/Kentucky/Louisville':{'name':_0x35a443('0x69'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},'America/Kentucky/Monticello':{'name':_0x35a443('0xb0'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['US']},'America/Indiana/Indianapolis':{'name':_0x35a443('0x4'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['US']},'America/Indiana/Vincennes':{'name':_0x35a443('0xbe'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['US']},'America/Indiana/Winamac':{'name':_0x35a443('0x40'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['US']},'America/Indiana/Marengo':{'name':_0x35a443('0x36'),'utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},'America/Indiana/Petersburg':{'name':_0x35a443('0xe1'),'utcOffset':-0x12c,'offsetStr':_0x35a443('0xd3'),'countries':['US']},'America/Indiana/Vevay':{'name':'America/Indiana/Vevay','utcOffset':-0x12c,'offsetStr':'-05:00','countries':['US']},'America/Chicago':{'name':_0x35a443('0xf6'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['US']},'America/Indiana/Tell_City':{'name':_0x35a443('0x18'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['US']},'America/Indiana/Knox':{'name':_0x35a443('0x7d'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['US']},'America/Menominee':{'name':_0x35a443('0x33'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['US']},'America/North_Dakota/Center':{'name':_0x35a443('0x9f'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['US']},'America/North_Dakota/New_Salem':{'name':_0x35a443('0x2'),'utcOffset':-0x168,'offsetStr':_0x35a443('0x1f'),'countries':['US']},'America/North_Dakota/Beulah':{'name':_0x35a443('0x3d'),'utcOffset':-0x168,'offsetStr':'-06:00','countries':['US']},'America/Denver':{'name':_0x35a443('0xf3'),'utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['US']},'America/Boise':{'name':_0x35a443('0xcb'),'utcOffset':-0x1a4,'offsetStr':'-07:00','countries':['US']},'America/Phoenix':{'name':'America/Phoenix','utcOffset':-0x1a4,'offsetStr':_0x35a443('0xb8'),'countries':['US']},'America/Los_Angeles':{'name':'America/Los_Angeles','utcOffset':-0x1e0,'offsetStr':_0x35a443('0x90'),'countries':['US']},'America/Metlakatla':{'name':_0x35a443('0xd9'),'utcOffset':-0x1e0,'offsetStr':_0x35a443('0x90'),'countries':['US']},'America/Anchorage':{'name':_0x35a443('0x10c'),'utcOffset':-0x21c,'offsetStr':_0x35a443('0x76'),'countries':['US']},'America/Juneau':{'name':'America/Juneau','utcOffset':-0x21c,'offsetStr':'-09:00','countries':['US']},'America/Sitka':{'name':_0x35a443('0x92'),'utcOffset':-0x21c,'offsetStr':_0x35a443('0x76'),'countries':['US']},'America/Yakutat':{'name':_0x35a443('0x12e'),'utcOffset':-0x21c,'offsetStr':_0x35a443('0x76'),'countries':['US']},'America/Nome':{'name':_0x35a443('0x11'),'utcOffset':-0x21c,'offsetStr':_0x35a443('0x76'),'countries':['US']},'America/Adak':{'name':_0x35a443('0x5c'),'utcOffset':-0x258,'offsetStr':_0x35a443('0x82'),'countries':['US']},'Pacific/Honolulu':{'name':_0x35a443('0x94'),'utcOffset':-0x258,'offsetStr':_0x35a443('0x82'),'countries':['US','UM']},'America/Montevideo':{'name':'America/Montevideo','utcOffset':-0xb4,'offsetStr':_0x35a443('0x9b'),'countries':['UY']},'Asia/Samarkand':{'name':_0x35a443('0xf9'),'utcOffset':0x12c,'offsetStr':_0x35a443('0x129'),'countries':['UZ']},'Asia/Tashkent':{'name':'Asia/Tashkent','utcOffset':0x12c,'offsetStr':_0x35a443('0x129'),'countries':['UZ']},'America/Caracas':{'name':'America/Caracas','utcOffset':-0x10e,'offsetStr':_0x35a443('0xf2'),'countries':['VE']},'Asia/Ho_Chi_Minh':{'name':_0x35a443('0x72'),'utcOffset':0x1a4,'offsetStr':'+07:00','countries':['VN']},'Pacific/Efate':{'name':'Pacific/Efate','utcOffset':0x294,'offsetStr':_0x35a443('0xff'),'countries':['VU']},'Pacific/Wallis':{'name':_0x35a443('0x117'),'utcOffset':0x2d0,'offsetStr':_0x35a443('0x15'),'countries':['WF']},'Pacific/Apia':{'name':_0x35a443('0x5a'),'utcOffset':0x348,'offsetStr':_0x35a443('0x64'),'countries':['WS']},'Africa/Johannesburg':{'name':_0x35a443('0x45'),'utcOffset':0x78,'offsetStr':_0x35a443('0x100'),'countries':['ZA','LS','SZ']}}}; \ No newline at end of file diff --git a/server/config/environment/test.js b/server/config/environment/test.js index a5a5bef..ee8181b 100644 --- a/server/config/environment/test.js +++ b/server/config/environment/test.js @@ -1 +1 @@ -const a841_0x2db0=['determine','asteriskHost','dbPort','utf8','utf8mb4','asteriskPassword','mysqlPassword','../config.service','sessionSecret','dbHost','mysql','offsetStr','redisHost','asteriskUsername','mysqlDatabase','seedDb','exports','domain','mysqlUser','googleSecret','redisPort','getConfigService','rpcIp','utf8_general_ci','googleId','./shared'];(function(_0xa9ff3,_0x2db086){const _0x1417cf=function(_0x367405){while(--_0x367405){_0xa9ff3['push'](_0xa9ff3['shift']());}};_0x1417cf(++_0x2db086);}(a841_0x2db0,0xc5));const a841_0x1417=function(_0xa9ff3,_0x2db086){_0xa9ff3=_0xa9ff3-0x0;let _0x1417cf=a841_0x2db0[_0xa9ff3];return _0x1417cf;};const _0xec5bdd=a841_0x1417;'use strict';const shared=require(_0xec5bdd('0xa')),jstz=require('jstz'),timezone=jstz[_0xec5bdd('0xb')](),timezoneOffset=shared['timezones'][timezone['name']()][_0xec5bdd('0x16')],cs=require(_0xec5bdd('0x12'))[_0xec5bdd('0x6')]();module[_0xec5bdd('0x1')]={'sequelize':{'database':cs['mysqlDatabase'],'username':cs['mysqlUser'],'password':cs[_0xec5bdd('0x11')],'options':{'host':cs[_0xec5bdd('0x14')],'port':cs[_0xec5bdd('0xd')],'dialect':_0xec5bdd('0x15'),'dialectOptions':{'charset':_0xec5bdd('0xf')},'timezone':timezoneOffset,'define':{'charset':_0xec5bdd('0xe'),'collate':'utf8_general_ci'}}},'sequelizeHistory':{'database':cs[_0xec5bdd('0x19')],'username':cs[_0xec5bdd('0x3')],'password':cs[_0xec5bdd('0x11')],'options':{'host':cs[_0xec5bdd('0x14')],'port':cs[_0xec5bdd('0xd')],'dialect':_0xec5bdd('0x15'),'dialectOptions':{'charset':_0xec5bdd('0xf')},'logging':![],'timezone':timezoneOffset,'define':{'charset':'utf8','collate':_0xec5bdd('0x8')}}},'asterisk':{'ip':cs[_0xec5bdd('0xc')],'port':cs['asteriskPort'],'username':cs[_0xec5bdd('0x18')],'password':cs[_0xec5bdd('0x10')]},'redis':{'host':cs[_0xec5bdd('0x17')],'port':cs[_0xec5bdd('0x5')]},'rpc':{'port':cs['rpcPort'],'ip':cs[_0xec5bdd('0x7')]},'agi':{'port':cs['agiPort'],'ip':cs['agiIp']},'seedDB':cs[_0xec5bdd('0x0')],'google':{'clientID':cs[_0xec5bdd('0x9')],'clientSecret':cs[_0xec5bdd('0x4')],'callbackURL':cs[_0xec5bdd('0x2')]+'/api/auth/google/callback'},'secrets':{'session':cs[_0xec5bdd('0x13')],'recording':cs['recordingSecret']},'xdr':{'disabled':![]}}; \ No newline at end of file +const a841_0x4722=['offsetStr','mysqlUser','/api/auth/google/callback','seedDb','mysqlDatabase','utf8','dbPort','asteriskPassword','agiIp','mysqlPassword','getConfigService','recordingSecret','timezones','../config.service','sessionSecret','./shared','utf8mb4','googleSecret','jstz','redisPort','determine','name','dbHost','mysql','utf8_general_ci','asteriskHost','redisHost','domain','agiPort'];(function(_0x2db668,_0x472204){const _0x472584=function(_0x1af1ce){while(--_0x1af1ce){_0x2db668['push'](_0x2db668['shift']());}};_0x472584(++_0x472204);}(a841_0x4722,0x144));const a841_0x4725=function(_0x2db668,_0x472204){_0x2db668=_0x2db668-0x0;let _0x472584=a841_0x4722[_0x2db668];return _0x472584;};const _0x415401=a841_0x4725;'use strict';const shared=require(_0x415401('0xa')),jstz=require(_0x415401('0xd')),timezone=jstz[_0x415401('0xf')](),timezoneOffset=shared[_0x415401('0x7')][timezone[_0x415401('0x10')]()][_0x415401('0x18')],cs=require(_0x415401('0x8'))[_0x415401('0x5')]();module['exports']={'sequelize':{'database':cs[_0x415401('0x1c')],'username':cs[_0x415401('0x19')],'password':cs[_0x415401('0x4')],'options':{'host':cs[_0x415401('0x11')],'port':cs[_0x415401('0x1')],'dialect':_0x415401('0x12'),'dialectOptions':{'charset':'utf8mb4'},'timezone':timezoneOffset,'define':{'charset':_0x415401('0x0'),'collate':_0x415401('0x13')}}},'sequelizeHistory':{'database':cs['mysqlDatabase'],'username':cs['mysqlUser'],'password':cs[_0x415401('0x4')],'options':{'host':cs[_0x415401('0x11')],'port':cs[_0x415401('0x1')],'dialect':_0x415401('0x12'),'dialectOptions':{'charset':_0x415401('0xb')},'logging':![],'timezone':timezoneOffset,'define':{'charset':_0x415401('0x0'),'collate':'utf8_general_ci'}}},'asterisk':{'ip':cs[_0x415401('0x14')],'port':cs['asteriskPort'],'username':cs['asteriskUsername'],'password':cs[_0x415401('0x2')]},'redis':{'host':cs[_0x415401('0x15')],'port':cs[_0x415401('0xe')]},'rpc':{'port':cs['rpcPort'],'ip':cs['rpcIp']},'agi':{'port':cs[_0x415401('0x17')],'ip':cs[_0x415401('0x3')]},'seedDB':cs[_0x415401('0x1b')],'google':{'clientID':cs['googleId'],'clientSecret':cs[_0x415401('0xc')],'callbackURL':cs[_0x415401('0x16')]+_0x415401('0x1a')},'secrets':{'session':cs[_0x415401('0x9')],'recording':cs[_0x415401('0x6')]},'xdr':{'disabled':![]}}; \ No newline at end of file diff --git a/server/config/express.js b/server/config/express.js index 8efed03..8667a93 100644 --- a/server/config/express.js +++ b/server/config/express.js @@ -1 +1 @@ -const a842_0x1fef=['./config.service','default','isProduction','views','appPath','view\x20engine','./environment','split','cookie-parser','Public\x20path\x20set\x20to\x20','/server/views','OPTIONS,GET,HEAD,PUT,PATCH,POST,DELETE','set','static','json','ejs','info','use','body-parser','50mb','./logger','toISOString','urlencoded','engine','root','method-override','renderFile','initialize','json\x20replacer','public','errorhandler','cors','get'];(function(_0x523690,_0x1fefec){const _0x2de56b=function(_0x54c625){while(--_0x54c625){_0x523690['push'](_0x523690['shift']());}};_0x2de56b(++_0x1fefec);}(a842_0x1fef,0x1f4));const a842_0x2de5=function(_0x523690,_0x1fefec){_0x523690=_0x523690-0x0;let _0x2de56b=a842_0x1fef[_0x523690];return _0x2de56b;};const _0x399e2c=a842_0x2de5;'use strict';const express=require('express'),bodyParser=require(_0x399e2c('0xd')),methodOverride=require(_0x399e2c('0x14')),cookieParser=require(_0x399e2c('0x3')),errorHandler=require(_0x399e2c('0x19')),path=require('path'),passport=require('passport'),cors=require(_0x399e2c('0x1a')),config=require(_0x399e2c('0x1')),{getConfigService}=require(_0x399e2c('0x1c')),logger=require(_0x399e2c('0xf'))('app');exports[_0x399e2c('0x1d')]=function(_0x54c625){const _0x300900=_0x399e2c,_0xd0ccef=getConfigService();_0x54c625[_0x300900('0x7')](_0x300900('0x20'),path['join'](config[_0x300900('0x13')],'..',_0x300900('0x18'))),logger[_0x300900('0xb')](_0x300900('0x4')+_0x54c625['get'](_0x300900('0x20'))),!_0xd0ccef[_0x300900('0x1e')]&&_0x54c625[_0x300900('0xc')](errorHandler()),_0x54c625[_0x300900('0x7')](_0x300900('0x17'),function(_0x18849a,_0x34d504){const _0x3750e1=_0x300900;return this[_0x18849a]instanceof Date&&(_0x34d504=this[_0x18849a][_0x3750e1('0x10')]()[_0x3750e1('0x2')]('.')[0x0]+'Z'),_0x34d504;}),_0x54c625[_0x300900('0xc')](express[_0x300900('0x8')](_0x54c625[_0x300900('0x1b')](_0x300900('0x20')))),_0x54c625[_0x300900('0x7')](_0x300900('0x1f'),config[_0x300900('0x13')]+_0x300900('0x5')),_0x54c625[_0x300900('0x12')]('html',require(_0x300900('0xa'))[_0x300900('0x15')]),_0x54c625['set'](_0x300900('0x0'),'html'),_0x54c625[_0x300900('0xc')](bodyParser[_0x300900('0x11')]({'limit':_0x300900('0xe'),'extended':!![]})),_0x54c625['use'](bodyParser[_0x300900('0x9')]({'limit':'50mb'})),_0x54c625[_0x300900('0xc')](cors({'origin':!_0xd0ccef[_0x300900('0x1e')],'methods':_0xd0ccef[_0x300900('0x1e')]?'GET,HEAD,PUT,PATCH,POST,DELETE':_0x300900('0x6'),'preflightContinue':!![]})),_0x54c625['use'](methodOverride()),_0x54c625[_0x300900('0xc')](cookieParser()),_0x54c625[_0x300900('0xc')](passport[_0x300900('0x16')]());}; \ No newline at end of file +const a842_0x2109=['passport','cors','cookie-parser','appPath','json\x20replacer','split','./config.service','initialize','static','method-override','toISOString','/server/views','get','body-parser','isProduction','GET,HEAD,PUT,PATCH,POST,DELETE','info','join','html','json','./environment','use','renderFile','app','set','default','path','express','view\x20engine','views','urlencoded','Public\x20path\x20set\x20to\x20','50mb','root','errorhandler'];(function(_0x5aa7d6,_0x210978){const _0x394d34=function(_0x54d5bc){while(--_0x54d5bc){_0x5aa7d6['push'](_0x5aa7d6['shift']());}};_0x394d34(++_0x210978);}(a842_0x2109,0x1cc));const a842_0x394d=function(_0x5aa7d6,_0x210978){_0x5aa7d6=_0x5aa7d6-0x0;let _0x394d34=a842_0x2109[_0x5aa7d6];return _0x394d34;};const _0x396e3d=a842_0x394d;'use strict';const express=require(_0x396e3d('0x16')),bodyParser=require(_0x396e3d('0x8')),methodOverride=require(_0x396e3d('0x4')),cookieParser=require(_0x396e3d('0x20')),errorHandler=require(_0x396e3d('0x1d')),path=require(_0x396e3d('0x15')),passport=require(_0x396e3d('0x1e')),cors=require(_0x396e3d('0x1f')),config=require(_0x396e3d('0xf')),{getConfigService}=require(_0x396e3d('0x1')),logger=require('./logger')(_0x396e3d('0x12'));exports[_0x396e3d('0x14')]=function(_0x54d5bc){const _0x23e3f7=_0x396e3d,_0x40131e=getConfigService();_0x54d5bc['set'](_0x23e3f7('0x21'),path[_0x23e3f7('0xc')](config[_0x23e3f7('0x1c')],'..','public')),logger[_0x23e3f7('0xb')](_0x23e3f7('0x1a')+_0x54d5bc[_0x23e3f7('0x7')](_0x23e3f7('0x21'))),!_0x40131e[_0x23e3f7('0x9')]&&_0x54d5bc[_0x23e3f7('0x10')](errorHandler()),_0x54d5bc[_0x23e3f7('0x13')](_0x23e3f7('0x22'),function(_0x21b21e,_0xf24257){const _0x462413=_0x23e3f7;return this[_0x21b21e]instanceof Date&&(_0xf24257=this[_0x21b21e][_0x462413('0x5')]()[_0x462413('0x0')]('.')[0x0]+'Z'),_0xf24257;}),_0x54d5bc['use'](express[_0x23e3f7('0x3')](_0x54d5bc[_0x23e3f7('0x7')](_0x23e3f7('0x21')))),_0x54d5bc[_0x23e3f7('0x13')](_0x23e3f7('0x18'),config[_0x23e3f7('0x1c')]+_0x23e3f7('0x6')),_0x54d5bc['engine'](_0x23e3f7('0xd'),require('ejs')[_0x23e3f7('0x11')]),_0x54d5bc[_0x23e3f7('0x13')](_0x23e3f7('0x17'),'html'),_0x54d5bc[_0x23e3f7('0x10')](bodyParser[_0x23e3f7('0x19')]({'limit':_0x23e3f7('0x1b'),'extended':!![]})),_0x54d5bc[_0x23e3f7('0x10')](bodyParser[_0x23e3f7('0xe')]({'limit':_0x23e3f7('0x1b')})),_0x54d5bc[_0x23e3f7('0x10')](cors({'origin':!_0x40131e[_0x23e3f7('0x9')],'methods':_0x40131e['isProduction']?_0x23e3f7('0xa'):'OPTIONS,GET,HEAD,PUT,PATCH,POST,DELETE','preflightContinue':!![]})),_0x54d5bc['use'](methodOverride()),_0x54d5bc['use'](cookieParser()),_0x54d5bc[_0x23e3f7('0x10')](passport[_0x23e3f7('0x2')]());}; \ No newline at end of file diff --git a/server/config/license/hardware.js b/server/config/license/hardware.js index 25ee83b..4ad84b2 100644 --- a/server/config/license/hardware.js +++ b/server/config/license/hardware.js @@ -1 +1 @@ -const a843_0x4253=['orderBy','crypto','networkInterfaces','hostname','model','127.0.0.1','replace','execSync','hex','00:00:00:00:00:00','concat','exports','test','filter','md5','child_process','createHash','macAddress','substring','head','family','cpus','utf8','length','dmidecode\x20--string\x20system-uuid','mac','map','join','lodash','win32','../config.service','IPv4','devLicense','update','digest'];(function(_0x191f7f,_0x42535d){const _0x5cf45a=function(_0x2288ff){while(--_0x2288ff){_0x191f7f['push'](_0x191f7f['shift']());}};_0x5cf45a(++_0x42535d);}(a843_0x4253,0x115));const a843_0x5cf4=function(_0x191f7f,_0x42535d){_0x191f7f=_0x191f7f-0x0;let _0x5cf45a=a843_0x4253[_0x191f7f];return _0x5cf45a;};const _0x2021e3=a843_0x5cf4;'use strict';const _=require(_0x2021e3('0x1f')),os=require('os'),crypto=require(_0x2021e3('0x4')),{getConfigService}=require(_0x2021e3('0x21')),exec=require(_0x2021e3('0x12'))[_0x2021e3('0xa')];function getInterfaces(){const _0x5397e6=_0x2021e3;let _0x2288ff=[];const _0x42f8f2=os[_0x5397e6('0x5')](),_0x846b04=_[_0x5397e6('0x3')](_['keys'](_0x42f8f2));for(let _0x4fef9f=0x0;_0x4fef9f<_0x846b04[_0x5397e6('0x1a')];_0x4fef9f++){const _0x2bacdb=_0x42f8f2[_0x846b04[_0x4fef9f]][_0x5397e6('0x10')](function(_0x1ec302){const _0x2e8a2c=_0x5397e6;return _0x1ec302[_0x2e8a2c('0x17')]===_0x2e8a2c('0x22')&&_0x1ec302['internal']===![];});_0x2288ff=_0x2288ff[_0x5397e6('0xd')](_0x2bacdb);}return _0x2288ff;}function getFirstInterface(){const _0x1051e0=_0x2021e3,_0x36abbf=_[_0x1051e0('0x16')](getInterfaces());return{'macAddress':_0x36abbf&&_0x36abbf[_0x1051e0('0x1c')]?_0x36abbf['mac']:_0x1051e0('0xc'),'ipAddress':_0x36abbf&&_0x36abbf['address']?_0x36abbf['address']:_0x1051e0('0x8')};}function getCPUhash(){const _0x462018=_0x2021e3,_0x226b0a=_[_0x462018('0x3')](os[_0x462018('0x18')]()[_0x462018('0x1d')](function(_0x576f4a){const _0x4b2033=_0x462018;return _0x576f4a[_0x4b2033('0x7')];}))[_0x462018('0x1e')](':');return crypto[_0x462018('0x13')](_0x462018('0x11'))[_0x462018('0x1')](_0x226b0a)['digest'](_0x462018('0xb'));}function getUuid(){const _0x4b3b19=_0x2021e3,_0x3f3834=getConfigService(),_0x2a2c5f=os['platform'](),_0x4b7cb4=/[0-9a-f-]{36}/;if(!_0x3f3834['isProduction']&&_0x4b7cb4[_0x4b3b19('0xf')](_0x3f3834[_0x4b3b19('0x0')]))return _0x3f3834['devLicense'];else{if(_0x2a2c5f===_0x4b3b19('0x20'))return exec(_0x4b3b19('0x1b'),{'encoding':_0x4b3b19('0x19')})[_0x4b3b19('0x9')]('\x0d\x0a','');else{const _0x490cb9=getFirstInterface(),_0x11c228=getCPUhash(),_0x20bb26=_0x11c228+'|'+os[_0x4b3b19('0x6')]()+'|'+_0x490cb9[_0x4b3b19('0x14')]+'|'+_0x490cb9['ipAddress'],_0x53450c=crypto[_0x4b3b19('0x13')](_0x4b3b19('0x11'))[_0x4b3b19('0x1')](_0x20bb26)[_0x4b3b19('0x2')]('hex');return _0x53450c['substring'](0x0,0x8)+'-'+_0x53450c[_0x4b3b19('0x15')](0x8,0xc)+'-'+_0x53450c['substring'](0xc,0x10)+'-'+_0x53450c['substring'](0x10,0x14)+'-'+_0x53450c['substring'](0x14);}}}module[_0x2021e3('0xe')]={'getUuid':getUuid,'getFirstInterface':getFirstInterface,'getCPUhash':getCPUhash}; \ No newline at end of file +const a843_0x529d=['update','macAddress','filter','test','../config.service','address','internal','exports','devLicense','map','model','replace','utf8','keys','join','substring','crypto','networkInterfaces','child_process','platform','mac','IPv4','dmidecode\x20--string\x20system-uuid','hex','md5','127.0.0.1','cpus','00:00:00:00:00:00','orderBy','concat','digest','createHash'];(function(_0x2fdcbc,_0x529db7){const _0x387d3c=function(_0x1c68b0){while(--_0x1c68b0){_0x2fdcbc['push'](_0x2fdcbc['shift']());}};_0x387d3c(++_0x529db7);}(a843_0x529d,0x1f0));const a843_0x387d=function(_0x2fdcbc,_0x529db7){_0x2fdcbc=_0x2fdcbc-0x0;let _0x387d3c=a843_0x529d[_0x2fdcbc];return _0x387d3c;};const _0x98d5be=a843_0x387d;'use strict';const _=require('lodash'),os=require('os'),crypto=require(_0x98d5be('0x0')),{getConfigService}=require(_0x98d5be('0x14')),exec=require(_0x98d5be('0x2'))['execSync'];function getInterfaces(){const _0x486c55=_0x98d5be;let _0x1c68b0=[];const _0x52b844=os[_0x486c55('0x1')](),_0x47992e=_[_0x486c55('0xc')](_[_0x486c55('0x1d')](_0x52b844));for(let _0xfe4da8=0x0;_0xfe4da8<_0x47992e['length'];_0xfe4da8++){const _0x5be764=_0x52b844[_0x47992e[_0xfe4da8]][_0x486c55('0x12')](function(_0xf4c26e){const _0x3de635=_0x486c55;return _0xf4c26e['family']===_0x3de635('0x5')&&_0xf4c26e[_0x3de635('0x16')]===![];});_0x1c68b0=_0x1c68b0[_0x486c55('0xd')](_0x5be764);}return _0x1c68b0;}function getFirstInterface(){const _0x33f502=_0x98d5be,_0xed9107=_['head'](getInterfaces());return{'macAddress':_0xed9107&&_0xed9107[_0x33f502('0x4')]?_0xed9107[_0x33f502('0x4')]:_0x33f502('0xb'),'ipAddress':_0xed9107&&_0xed9107[_0x33f502('0x15')]?_0xed9107['address']:_0x33f502('0x9')};}function getCPUhash(){const _0x56f0b2=_0x98d5be,_0x4e268f=_[_0x56f0b2('0xc')](os[_0x56f0b2('0xa')]()[_0x56f0b2('0x19')](function(_0x5ce19a){const _0x2cccf7=_0x56f0b2;return _0x5ce19a[_0x2cccf7('0x1a')];}))[_0x56f0b2('0x1e')](':');return crypto[_0x56f0b2('0xf')](_0x56f0b2('0x8'))['update'](_0x4e268f)[_0x56f0b2('0xe')](_0x56f0b2('0x7'));}function getUuid(){const _0x7a6b1f=_0x98d5be,_0x2e158b=getConfigService(),_0x264c43=os[_0x7a6b1f('0x3')](),_0x12a96f=/[0-9a-f-]{36}/;if(!_0x2e158b['isProduction']&&_0x12a96f[_0x7a6b1f('0x13')](_0x2e158b[_0x7a6b1f('0x18')]))return _0x2e158b[_0x7a6b1f('0x18')];else{if(_0x264c43==='win32')return exec(_0x7a6b1f('0x6'),{'encoding':_0x7a6b1f('0x1c')})[_0x7a6b1f('0x1b')]('\x0d\x0a','');else{const _0x435415=getFirstInterface(),_0x553e31=getCPUhash(),_0x3fbfb7=_0x553e31+'|'+os['hostname']()+'|'+_0x435415[_0x7a6b1f('0x11')]+'|'+_0x435415['ipAddress'],_0x3bf9ee=crypto[_0x7a6b1f('0xf')](_0x7a6b1f('0x8'))[_0x7a6b1f('0x10')](_0x3fbfb7)[_0x7a6b1f('0xe')](_0x7a6b1f('0x7'));return _0x3bf9ee[_0x7a6b1f('0x1f')](0x0,0x8)+'-'+_0x3bf9ee[_0x7a6b1f('0x1f')](0x8,0xc)+'-'+_0x3bf9ee['substring'](0xc,0x10)+'-'+_0x3bf9ee['substring'](0x10,0x14)+'-'+_0x3bf9ee[_0x7a6b1f('0x1f')](0x14);}}}module[_0x98d5be('0x17')]={'getUuid':getUuid,'getFirstInterface':getFirstInterface,'getCPUhash':getCPUhash}; \ No newline at end of file diff --git a/server/config/license/index.js b/server/config/license/index.js index 61d7762..481764f 100644 --- a/server/config/license/index.js +++ b/server/config/license/index.js @@ -1 +1 @@ -const a844_0x1856=['diff','active','Alert','MOTLICENSE','Motion\x20License\x20Alert','data2','openIssue','%s\x20-\x20GRAY\x20PERIOD\x20STARTED\x20AT\x20%s','info','../../components/encryptor','fullname','finally','request-promise-native','../logger','https://www.xcallymotion.com','||FIELD||VALUE||\x0a','getUuid','getFirstInterface','NEW\x20UUID\x20DETECTED:\x20FROM\x20%s\x20TO\x20%s','THE\x20LICENSE\x20HAS\x20BEEN\x20DISABLED','get','license','|uuid|','data1','catch','findOne','encryptString','util','Changed','then','GET','ipAddress','|name|','admin','Disabled','uuid','User','|reason|','format','error','default','decryptString','message','|machineUuid|','%s/api/servers/%s/check?version=%s','./hardware','../../api/jira/jira.controller','update','../../../package.json','YYYY-MM-DD\x20HH:mm','email'];(function(_0x3ac5fe,_0x18564c){const _0x393030=function(_0x2c6116){while(--_0x2c6116){_0x3ac5fe['push'](_0x3ac5fe['shift']());}};_0x393030(++_0x18564c);}(a844_0x1856,0x150));const a844_0x3930=function(_0x3ac5fe,_0x18564c){_0x3ac5fe=_0x3ac5fe-0x0;let _0x393030=a844_0x1856[_0x3ac5fe];return _0x393030;};const _0x26adac=a844_0x3930;'use strict';const {version}=require(_0x26adac('0x12')),util=require(_0x26adac('0x30')),encryptor=require(_0x26adac('0x1e')),moment=require('moment'),rp=require(_0x26adac('0x21')),db=require('../../mysqldb')['db'],hardware=require(_0x26adac('0xf')),logger=require(_0x26adac('0x22'))(_0x26adac('0x2a')),jira=require(_0x26adac('0x10')),HOST=_0x26adac('0x23'),TIME=0x3c*0x1388,DAYS=0x7;let GRAY_PERIOD_REASON,ADMIN,oldToken;function httpRequest(_0x2c6116){return new Promise(function(_0x5812ea,_0x3a6060){const _0x380443=a844_0x3930;let _0x5f072a=util[_0x380443('0x8')](_0x380443('0xe'),HOST,_0x2c6116,version);oldToken&&(_0x5f072a=util['format']('%s/api/servers/%s/check?version=%s&oldtoken=%s',HOST,_0x2c6116,version,oldToken));const _0x2ddde3={'uri':_0x5f072a,'method':_0x380443('0x0'),'timeout':0xea60,'json':!![]};return rp(_0x2ddde3)[_0x380443('0x32')](function(_0x4af66d){_0x5812ea(_0x4af66d);})['catch'](function(_0x2193b7){_0x3a6060(_0x2193b7);});});}function sendJiraAlert(_0x49aad7,_0x32fdcf,_0x55fa48){const _0x2eb484=_0x26adac;let _0x1d6bc1=_0x2eb484('0x24');return db[_0x2eb484('0x6')][_0x2eb484('0x2e')]({'where':{'role':_0x2eb484('0x3')},'attributes':[_0x2eb484('0x1f'),'email'],'raw':!![]})[_0x2eb484('0x32')](function(_0x50fb1a){const _0x870b0d=_0x2eb484;return ADMIN=_0x50fb1a,_0x1d6bc1+=_0x870b0d('0x7')+_0x55fa48+'|\x0a',_0x1d6bc1+=_0x870b0d('0x2b')+_0x49aad7+'|\x0a',_0x1d6bc1+=_0x870b0d('0xd')+_0x32fdcf+'|\x0a',_0x1d6bc1+=_0x870b0d('0x2')+ADMIN[_0x870b0d('0x1f')]+'|\x0a',_0x1d6bc1+='|email|'+ADMIN[_0x870b0d('0x14')]+'|\x0a',_0x1d6bc1;})[_0x2eb484('0x32')](function(_0x43bf81){const _0x1021ac=_0x2eb484,_0x132857=hardware[_0x1021ac('0x26')]()[_0x1021ac('0x1')];return jira[_0x1021ac('0x1b')]({'key':_0x1021ac('0x18'),'summary':_0x1021ac('0x19'),'description':_0x43bf81,'issuetype':_0x1021ac('0x17'),'oldToken':_0x49aad7,'newToken':_0x32fdcf,'email':ADMIN['email'],'name':ADMIN[_0x1021ac('0x1f')],'reason':GRAY_PERIOD_REASON,'ip':_0x132857});});}function manageLicense(_0x2396a4,_0x31e0fa){const _0x4b964b=_0x26adac,_0x1ea410=_0x31e0fa[_0x4b964b('0x29')]({'plain':!![]});httpRequest(_0x2396a4)[_0x4b964b('0x32')](function(_0x281fc7){const _0xdf4826=_0x4b964b;oldToken&&(oldToken=undefined);if(_0x281fc7[_0xdf4826('0x16')]){(!_0x1ea410[_0xdf4826('0x2a')]&&_0x1ea410['license']!=_0x281fc7[_0xdf4826('0x2a')]||_0x1ea410[_0xdf4826('0x2a')]&&_0x1ea410[_0xdf4826('0x1a')])&&logger[_0xdf4826('0x1d')]('THE\x20LICENSE\x20HAS\x20BEEN\x20ENABLED');_0x1ea410[_0xdf4826('0x2a')]&&!_0x1ea410[_0xdf4826('0x1a')]&&_0x1ea410['license']!=_0x281fc7[_0xdf4826('0x2a')]&&logger[_0xdf4826('0x1d')]('THE\x20LICENSE\x20HAS\x20BEEN\x20UPDATED');if(_0x1ea410[_0xdf4826('0x2a')]&&!_0x1ea410[_0xdf4826('0x1a')]&&_0x1ea410[_0xdf4826('0x2a')]==_0x281fc7['license'])return _0x31e0fa;return _0x31e0fa[_0xdf4826('0x11')]({'data1':_0x2396a4,'data2':null,'license':_0x281fc7[_0xdf4826('0x2a')]});}else{if(_0x281fc7['license']||_0x1ea410[_0xdf4826('0x2a')]){if(!_0x1ea410[_0xdf4826('0x1a')])return _0x1ea410[_0xdf4826('0x2c')]==_0x2396a4?(GRAY_PERIOD_REASON=_0xdf4826('0x4'),logger[_0xdf4826('0x1d')](_0xdf4826('0x28'))):(GRAY_PERIOD_REASON=_0xdf4826('0x31'),oldToken=_0x1ea410[_0xdf4826('0x2c')],logger[_0xdf4826('0x1d')](_0xdf4826('0x27'),_0x1ea410[_0xdf4826('0x2c')],_0x2396a4)),sendJiraAlert(_0x1ea410['data1'],_0x281fc7[_0xdf4826('0x5')],GRAY_PERIOD_REASON),logger['info'](_0xdf4826('0x1c'),GRAY_PERIOD_REASON['toUpperCase'](),moment()[_0xdf4826('0x8')](_0xdf4826('0x13'))),_0x31e0fa[_0xdf4826('0x11')]({'data2':encryptor[_0xdf4826('0x2f')](moment()[_0xdf4826('0x8')]('YYYY-MM-DD\x20HH:mm'))});else{if(moment()[_0xdf4826('0x15')](encryptor[_0xdf4826('0xb')](_0x1ea410['data2']),'days')>DAYS)return logger[_0xdf4826('0x1d')]('DEMO\x20START\x20AT\x20%s',moment()[_0xdf4826('0x8')](_0xdf4826('0x13'))),_0x31e0fa[_0xdf4826('0x11')]({'data1':_0x2396a4,'data2':null,'license':null});}}else{if(_0x1ea410[_0xdf4826('0x2c')]!=_0x2396a4)return logger['info']('NEW\x20UUID\x20DETECTED:\x20FROM\x20%s\x20TO\x20%s',_0x1ea410[_0xdf4826('0x2c')],_0x2396a4),_0x31e0fa[_0xdf4826('0x11')]({'data1':_0x2396a4,'data2':null,'license':null});}}return _0x31e0fa;})[_0x4b964b('0x32')](function(_0x2aaefa){_0x31e0fa=_0x2aaefa;})[_0x4b964b('0x2d')](function(_0x2e21eb){const _0xa4ac16=_0x4b964b;logger[_0xa4ac16('0x9')](_0x2e21eb[_0xa4ac16('0xc')]);})[_0x4b964b('0x20')](function(){setTimeout(function(){manageLicense(hardware['getUuid'](),_0x31e0fa);},TIME);});}function defaultLicense(){const _0x1c96f0=_0x26adac,_0x121be9=hardware[_0x1c96f0('0x25')]();return _0x121be9?db['License']['findOrCreate']({'where':{'id':0x1},'defaults':{'data1':_0x121be9}})['then'](function([_0xf8c033]){const _0x3f5fb4=_0x1c96f0;logger[_0x3f5fb4('0x1d')]('SERVICE\x20LICENSE\x20STARTED\x20%s',_0x121be9),manageLicense(_0x121be9,_0xf8c033);})[_0x1c96f0('0x2d')](function(_0x1bd8a6){const _0x3aa605=_0x1c96f0;logger[_0x3aa605('0x9')](_0x1bd8a6[_0x3aa605('0xc')]);throw _0x1bd8a6;}):Promise['reject'](new Error('No\x20UUID\x20found'));}exports[_0x26adac('0xa')]=defaultLicense; \ No newline at end of file +const a844_0x2823=['|machineUuid|','message','THE\x20LICENSE\x20HAS\x20BEEN\x20ENABLED','email','License','uuid','|name|','%s/api/servers/%s/check?version=%s','SERVICE\x20LICENSE\x20STARTED\x20%s','format','admin','YYYY-MM-DD\x20HH:mm','%s/api/servers/%s/check?version=%s&oldtoken=%s','Alert','util','getFirstInterface','fullname','../logger','|email|','MOTLICENSE','encryptString','THE\x20LICENSE\x20HAS\x20BEEN\x20DISABLED','User','update','toUpperCase','|reason|','reject','Changed','Disabled','%s\x20-\x20GRAY\x20PERIOD\x20STARTED\x20AT\x20%s','catch','then','|uuid|','||FIELD||VALUE||\x0a','./hardware','GET','decryptString','getUuid','openIssue','get','diff','error','../../../package.json','data1','finally','No\x20UUID\x20found','data2','ipAddress','license','request-promise-native','days','NEW\x20UUID\x20DETECTED:\x20FROM\x20%s\x20TO\x20%s','https://www.xcallymotion.com','Motion\x20License\x20Alert','info','findOne'];(function(_0x432a4c,_0x282311){const _0x30c30b=function(_0x73b067){while(--_0x73b067){_0x432a4c['push'](_0x432a4c['shift']());}};_0x30c30b(++_0x282311);}(a844_0x2823,0x1c9));const a844_0x30c3=function(_0x432a4c,_0x282311){_0x432a4c=_0x432a4c-0x0;let _0x30c30b=a844_0x2823[_0x432a4c];return _0x30c30b;};const _0x4b0845=a844_0x30c3;'use strict';const {version}=require(_0x4b0845('0x21')),util=require(_0x4b0845('0x5')),encryptor=require('../../components/encryptor'),moment=require('moment'),rp=require(_0x4b0845('0x28')),db=require('../../mysqldb')['db'],hardware=require(_0x4b0845('0x19')),logger=require(_0x4b0845('0x8'))(_0x4b0845('0x27')),jira=require('../../api/jira/jira.controller'),HOST=_0x4b0845('0x2b'),TIME=0x3c*0x1388,DAYS=0x7;let GRAY_PERIOD_REASON,ADMIN,oldToken;function httpRequest(_0x73b067){return new Promise(function(_0x1affd4,_0x2c70f0){const _0x45781e=a844_0x30c3;let _0x6fcb58=util[_0x45781e('0x0')](_0x45781e('0x36'),HOST,_0x73b067,version);oldToken&&(_0x6fcb58=util[_0x45781e('0x0')](_0x45781e('0x3'),HOST,_0x73b067,version,oldToken));const _0x23da22={'uri':_0x6fcb58,'method':_0x45781e('0x1a'),'timeout':0xea60,'json':!![]};return rp(_0x23da22)[_0x45781e('0x16')](function(_0x57dab7){_0x1affd4(_0x57dab7);})[_0x45781e('0x15')](function(_0x31e5f9){_0x2c70f0(_0x31e5f9);});});}function sendJiraAlert(_0xd083cb,_0x260941,_0x565470){const _0x264142=_0x4b0845;let _0x4209a2=_0x264142('0x18');return db[_0x264142('0xd')][_0x264142('0x2e')]({'where':{'role':_0x264142('0x1')},'attributes':[_0x264142('0x7'),_0x264142('0x32')],'raw':!![]})[_0x264142('0x16')](function(_0x2d4fed){const _0x3c58a0=_0x264142;return ADMIN=_0x2d4fed,_0x4209a2+=_0x3c58a0('0x10')+_0x565470+'|\x0a',_0x4209a2+=_0x3c58a0('0x17')+_0xd083cb+'|\x0a',_0x4209a2+=_0x3c58a0('0x2f')+_0x260941+'|\x0a',_0x4209a2+=_0x3c58a0('0x35')+ADMIN[_0x3c58a0('0x7')]+'|\x0a',_0x4209a2+=_0x3c58a0('0x9')+ADMIN[_0x3c58a0('0x32')]+'|\x0a',_0x4209a2;})[_0x264142('0x16')](function(_0x2de6d6){const _0xe44b18=_0x264142,_0x4d2a7a=hardware[_0xe44b18('0x6')]()[_0xe44b18('0x26')];return jira[_0xe44b18('0x1d')]({'key':_0xe44b18('0xa'),'summary':_0xe44b18('0x2c'),'description':_0x2de6d6,'issuetype':_0xe44b18('0x4'),'oldToken':_0xd083cb,'newToken':_0x260941,'email':ADMIN[_0xe44b18('0x32')],'name':ADMIN['fullname'],'reason':GRAY_PERIOD_REASON,'ip':_0x4d2a7a});});}function manageLicense(_0x189239,_0x4d1217){const _0x240fae=_0x4b0845,_0x3fa2eb=_0x4d1217[_0x240fae('0x1e')]({'plain':!![]});httpRequest(_0x189239)[_0x240fae('0x16')](function(_0x15f536){const _0x428567=_0x240fae;oldToken&&(oldToken=undefined);if(_0x15f536['active']){(!_0x3fa2eb[_0x428567('0x27')]&&_0x3fa2eb['license']!=_0x15f536[_0x428567('0x27')]||_0x3fa2eb[_0x428567('0x27')]&&_0x3fa2eb['data2'])&&logger['info'](_0x428567('0x31'));_0x3fa2eb[_0x428567('0x27')]&&!_0x3fa2eb[_0x428567('0x25')]&&_0x3fa2eb[_0x428567('0x27')]!=_0x15f536[_0x428567('0x27')]&&logger[_0x428567('0x2d')]('THE\x20LICENSE\x20HAS\x20BEEN\x20UPDATED');if(_0x3fa2eb['license']&&!_0x3fa2eb[_0x428567('0x25')]&&_0x3fa2eb['license']==_0x15f536[_0x428567('0x27')])return _0x4d1217;return _0x4d1217[_0x428567('0xe')]({'data1':_0x189239,'data2':null,'license':_0x15f536['license']});}else{if(_0x15f536['license']||_0x3fa2eb['license']){if(!_0x3fa2eb[_0x428567('0x25')])return _0x3fa2eb['data1']==_0x189239?(GRAY_PERIOD_REASON=_0x428567('0x13'),logger[_0x428567('0x2d')](_0x428567('0xc'))):(GRAY_PERIOD_REASON=_0x428567('0x12'),oldToken=_0x3fa2eb[_0x428567('0x22')],logger[_0x428567('0x2d')](_0x428567('0x2a'),_0x3fa2eb[_0x428567('0x22')],_0x189239)),sendJiraAlert(_0x3fa2eb['data1'],_0x15f536[_0x428567('0x34')],GRAY_PERIOD_REASON),logger[_0x428567('0x2d')](_0x428567('0x14'),GRAY_PERIOD_REASON[_0x428567('0xf')](),moment()[_0x428567('0x0')](_0x428567('0x2'))),_0x4d1217['update']({'data2':encryptor[_0x428567('0xb')](moment()['format'](_0x428567('0x2')))});else{if(moment()[_0x428567('0x1f')](encryptor[_0x428567('0x1b')](_0x3fa2eb[_0x428567('0x25')]),_0x428567('0x29'))>DAYS)return logger['info']('DEMO\x20START\x20AT\x20%s',moment()[_0x428567('0x0')](_0x428567('0x2'))),_0x4d1217[_0x428567('0xe')]({'data1':_0x189239,'data2':null,'license':null});}}else{if(_0x3fa2eb[_0x428567('0x22')]!=_0x189239)return logger[_0x428567('0x2d')](_0x428567('0x2a'),_0x3fa2eb[_0x428567('0x22')],_0x189239),_0x4d1217['update']({'data1':_0x189239,'data2':null,'license':null});}}return _0x4d1217;})[_0x240fae('0x16')](function(_0x5124ad){_0x4d1217=_0x5124ad;})['catch'](function(_0x5c12c4){const _0x31c679=_0x240fae;logger[_0x31c679('0x20')](_0x5c12c4[_0x31c679('0x30')]);})[_0x240fae('0x23')](function(){setTimeout(function(){const _0x10fe8f=a844_0x30c3;manageLicense(hardware[_0x10fe8f('0x1c')](),_0x4d1217);},TIME);});}function defaultLicense(){const _0x365869=_0x4b0845,_0x10c56e=hardware['getUuid']();return _0x10c56e?db[_0x365869('0x33')]['findOrCreate']({'where':{'id':0x1},'defaults':{'data1':_0x10c56e}})['then'](function([_0x513759]){const _0x3af07c=_0x365869;logger['info'](_0x3af07c('0x37'),_0x10c56e),manageLicense(_0x10c56e,_0x513759);})['catch'](function(_0x4ebb1a){const _0x17722c=_0x365869;logger[_0x17722c('0x20')](_0x4ebb1a['message']);throw _0x4ebb1a;}):Promise[_0x365869('0x11')](new Error(_0x365869('0x24')));}exports['default']=defaultLicense; \ No newline at end of file diff --git a/server/config/license/util.js b/server/config/license/util.js index 57764b4..8348439 100644 --- a/server/config/license/util.js +++ b/server/config/license/util.js @@ -1 +1 @@ -const a845_0x7dcb=['License','countBy','format','machineUuid','util','data1','%s:%s:%s','then','Demo\x20license','split','disabled','isEmpty','License\x20limit\x20reached\x20for\x20telephones','decryptString','demo','data2','License\x20key\x20value\x20not\x20found','./hardware','COUNT','moment','telephones','getUuid','days','pick','message','telephone','catch','changed','role','users','../../mysqldb','defaults','user','License\x20limit\x20reached\x20for\x20users','2027-01-01T00:00:00.000Z','sequelize','lodash','deadline','count','license','grayReason','admin','uuid','findAll'];(function(_0x3256fa,_0x7dcbda){const _0x11de8a=function(_0x16d6aa){while(--_0x16d6aa){_0x3256fa['push'](_0x3256fa['shift']());}};_0x11de8a(++_0x7dcbda);}(a845_0x7dcb,0xe7));const a845_0x11de=function(_0x3256fa,_0x7dcbda){_0x3256fa=_0x3256fa-0x0;let _0x11de8a=a845_0x7dcb[_0x3256fa];return _0x11de8a;};const _0x2170f4=a845_0x11de;'use strict';const encryptor=require('../../components/encryptor'),util=require(_0x2170f4('0x25')),_=require(_0x2170f4('0x19')),moment=require(_0x2170f4('0x8')),hardware=require(_0x2170f4('0x6')),db=require(_0x2170f4('0x13'))['db'],{Op,fn,col}=require(_0x2170f4('0x18')),demoLicense={'demo':!![],'agents':0x2,'telephones':0x0,'users':0x1,'expiration':_0x2170f4('0x17'),'chat':![],'mail':![],'fax':![],'messaging':![],'whatsapp':![],'cm':![],'dialer':![],'jscripty':![],'openchannel':![],'callysquare':0x2,'webrtc':![],'jaws':![],'custom':![],'description':_0x2170f4('0x29'),'machineUuid':hardware[_0x2170f4('0xa')](),'virtual':0x0,'voice':!![],'screenrecording':![],'preferred':![],'ai':![]},breakingLicense={'breaking':!![],'demo':!![],'agents':0x2,'telephones':0x0,'users':0x1,'expiration':_0x2170f4('0x17'),'chat':![],'mail':![],'fax':![],'messaging':![],'whatsapp':![],'cm':![],'dialer':![],'jscripty':![],'openchannel':![],'callysquare':0x2,'webrtc':![],'jaws':![],'custom':![],'update':![],'description':'Breaking\x20license','machineUuid':hardware[_0x2170f4('0xa')](),'virtual':0x0,'voice':!![],'screenrecording':![],'preferred':![],'ai':![]};function getLicense(_0x16d6aa){return new Promise(function(_0x28c6e7,_0x445272){const _0x3f7bbd=a845_0x11de;return db[_0x3f7bbd('0x21')]['findOne'](_[_0x3f7bbd('0x14')](_0x16d6aa,{'raw':!![],'where':{'id':0x1}}))['then'](function(_0x114d7f){return checkLicense(_0x114d7f,null);})['then'](function(_0x4a230d){_0x28c6e7(_0x4a230d);return;})[_0x3f7bbd('0xf')](function(_0x3c9c7d){_0x445272(_0x3c9c7d);});});}function checkLicense(_0x3cdd29,_0x49d5c3){const _0x165054=_0x2170f4;if(!_0x3cdd29)return demoLicense[_0x165054('0x1f')]=_0x3cdd29[_0x165054('0x26')],demoLicense;try{const _0x5985ca=_0x49d5c3||_0x3cdd29[_0x165054('0x1c')];if(_[_0x165054('0x0')](_0x5985ca))throw new Error(_0x165054('0x5'));const _0x1972fc=_0x3cdd29[_0x165054('0x26')],_0xf7beb6=_0x3cdd29[_0x165054('0x4')],_0x1702f5=_0x1972fc['split']('-')[0x4],_0x5831c4=_0x1972fc[_0x165054('0x2a')]('-')[0x0],_0xc7620b=encryptor[_0x165054('0x2')](_0x5985ca,util[_0x165054('0x23')](_0x165054('0x27'),_0x1702f5,_0x1972fc,_0x5831c4)),_0x167e97=JSON['parse'](_0xc7620b);_0x167e97[_0x165054('0x3')]=![],_0x167e97[_0x165054('0x1f')]=_0x1972fc,_0x167e97[_0x165054('0x24')]=hardware['getUuid']();if(_0xf7beb6){const _0x1a476=encryptor[_0x165054('0x2')](_0xf7beb6);_0x167e97['gray']=_0x1a476,_0x167e97[_0x165054('0x1a')]=moment(_0x1a476)['add'](0x7,_0x165054('0xb'))[_0x165054('0x23')](),_0x167e97[_0x165054('0x1d')]=_0x167e97[_0x165054('0x1f')]!=_0x167e97[_0x165054('0x24')]?_0x165054('0x10'):_0x165054('0x2b');}return _0x167e97;}catch(_0x5925a9){return breakingLicense[_0x165054('0x1f')]=_0x3cdd29[_0x165054('0x26')],breakingLicense[_0x165054('0xd')]=_0x5925a9['message'],breakingLicense;}}function getLimits(){return new Promise(function(_0x11fdf4,_0x5d1fc1){const _0x2cb5dc=a845_0x11de;getLicense()[_0x2cb5dc('0x28')](function(_0x4b607e){const _0x3e0ee2=_0x2cb5dc;return db['User'][_0x3e0ee2('0x20')]({'attributes':['role',[fn(_0x3e0ee2('0x7'),col(_0x3e0ee2('0x11'))),_0x3e0ee2('0x1b')]],'group':_0x3e0ee2('0x11'),'where':{'role':{[Op['or']]:['admin',_0x3e0ee2('0x15'),_0x3e0ee2('0xe')]}},'raw':!![]})[_0x3e0ee2('0x28')](function(_0x4bd73e){const _0x439138=_0x3e0ee2,_0x1e008e={'user':_0x4b607e[_0x439138('0x12')]||0x0,'telephone':_0x4b607e[_0x439138('0x9')]||0x0};_0x4bd73e['forEach'](function(_0x3fc047){const _0x63ce44=_0x439138,_0x50d584=_0x3fc047[_0x63ce44('0x11')]===_0x63ce44('0x1e')?_0x63ce44('0x15'):_0x3fc047['role'];_0x1e008e[_0x50d584]-=_0x3fc047[_0x63ce44('0x1b')];if(_0x1e008e[_0x50d584]<0x0)_0x1e008e[_0x50d584]=0x0;}),_0x11fdf4(_0x1e008e);return;});})['catch'](function(_0x536bc3){_0x5d1fc1(_0x536bc3);});});}function checkUserLimits(_0x4d7afb){return new Promise(function(_0x26e6ff,_0x29bbbb){const _0x423a99=a845_0x11de;getLimits()[_0x423a99('0x28')](function(_0x17c0b3){const _0x36665a=_0x423a99,_0x2e7588=_[_0x36665a('0xc')](_[_0x36665a('0x22')](_0x4d7afb,_0x36665a('0x11')),['admin',_0x36665a('0x15'),_0x36665a('0xe')]),_0x2508c7=(_0x2e7588[_0x36665a('0x1e')]||0x0)+(_0x2e7588[_0x36665a('0x15')]||0x0),_0x3cfcef=_0x2e7588[_0x36665a('0xe')]||0x0;if(_0x2508c7>_0x17c0b3['user'])return _0x29bbbb(_0x36665a('0x16'));if(_0x3cfcef>_0x17c0b3[_0x36665a('0xe')])return _0x29bbbb(_0x36665a('0x1'));return _0x26e6ff();})[_0x423a99('0xf')](function(_0x3006e2){_0x29bbbb(_0x3006e2);});});}module['exports']={'checkLicense':checkLicense,'checkUserLimits':checkUserLimits,'getLicense':getLicense}; \ No newline at end of file +const a845_0x3d95=['License\x20limit\x20reached\x20for\x20users','grayReason','catch','then','message','defaults','decryptString','telephone','uuid','License\x20key\x20value\x20not\x20found','deadline','COUNT','count','getUuid','../../components/encryptor','admin','disabled','%s:%s:%s','changed','telephones','findAll','users','countBy','lodash','User','sequelize','demo','data1','Demo\x20license','user','../../mysqldb','data2','isEmpty','2027-01-01T00:00:00.000Z','exports','format','gray','split','forEach','./hardware','License\x20limit\x20reached\x20for\x20telephones','pick','findOne','license','add','days','role'];(function(_0x40976f,_0x3d954c){const _0x1435bb=function(_0x3c2986){while(--_0x3c2986){_0x40976f['push'](_0x40976f['shift']());}};_0x1435bb(++_0x3d954c);}(a845_0x3d95,0x1a0));const a845_0x1435=function(_0x40976f,_0x3d954c){_0x40976f=_0x40976f-0x0;let _0x1435bb=a845_0x3d95[_0x40976f];return _0x1435bb;};const _0x5b21f8=a845_0x1435;'use strict';const encryptor=require(_0x5b21f8('0x15')),util=require('util'),_=require(_0x5b21f8('0x1e')),moment=require('moment'),hardware=require(_0x5b21f8('0x2e')),db=require(_0x5b21f8('0x25'))['db'],{Op,fn,col}=require(_0x5b21f8('0x20')),demoLicense={'demo':!![],'agents':0x2,'telephones':0x0,'users':0x1,'expiration':_0x5b21f8('0x28'),'chat':![],'mail':![],'fax':![],'messaging':![],'whatsapp':![],'cm':![],'dialer':![],'jscripty':![],'openchannel':![],'callysquare':0x2,'webrtc':![],'jaws':![],'custom':![],'description':_0x5b21f8('0x23'),'machineUuid':hardware['getUuid'](),'virtual':0x0,'voice':!![],'screenrecording':![],'preferred':![],'ai':![]},breakingLicense={'breaking':!![],'demo':!![],'agents':0x2,'telephones':0x0,'users':0x1,'expiration':_0x5b21f8('0x28'),'chat':![],'mail':![],'fax':![],'messaging':![],'whatsapp':![],'cm':![],'dialer':![],'jscripty':![],'openchannel':![],'callysquare':0x2,'webrtc':![],'jaws':![],'custom':![],'update':![],'description':'Breaking\x20license','machineUuid':hardware[_0x5b21f8('0x14')](),'virtual':0x0,'voice':!![],'screenrecording':![],'preferred':![],'ai':![]};function getLicense(_0x3c2986){return new Promise(function(_0x57f1fe,_0x1c44e1){const _0x20da1e=a845_0x1435;return db['License'][_0x20da1e('0x2')](_[_0x20da1e('0xc')](_0x3c2986,{'raw':!![],'where':{'id':0x1}}))[_0x20da1e('0xa')](function(_0x2954a7){return checkLicense(_0x2954a7,null);})['then'](function(_0x5a7140){_0x57f1fe(_0x5a7140);return;})[_0x20da1e('0x9')](function(_0x7160d2){_0x1c44e1(_0x7160d2);});});}function checkLicense(_0x6a0fd5,_0x53ec08){const _0x1d9e34=_0x5b21f8;if(!_0x6a0fd5)return demoLicense[_0x1d9e34('0xf')]=_0x6a0fd5[_0x1d9e34('0x22')],demoLicense;try{const _0x325237=_0x53ec08||_0x6a0fd5[_0x1d9e34('0x3')];if(_[_0x1d9e34('0x27')](_0x325237))throw new Error(_0x1d9e34('0x10'));const _0x5d2c70=_0x6a0fd5[_0x1d9e34('0x22')],_0x3bb38e=_0x6a0fd5[_0x1d9e34('0x26')],_0x562011=_0x5d2c70[_0x1d9e34('0x2c')]('-')[0x4],_0x47e3fb=_0x5d2c70[_0x1d9e34('0x2c')]('-')[0x0],_0x2cffdf=encryptor[_0x1d9e34('0xd')](_0x325237,util[_0x1d9e34('0x2a')](_0x1d9e34('0x18'),_0x562011,_0x5d2c70,_0x47e3fb)),_0xf4a940=JSON['parse'](_0x2cffdf);_0xf4a940[_0x1d9e34('0x21')]=![],_0xf4a940[_0x1d9e34('0xf')]=_0x5d2c70,_0xf4a940['machineUuid']=hardware[_0x1d9e34('0x14')]();if(_0x3bb38e){const _0x2320e4=encryptor['decryptString'](_0x3bb38e);_0xf4a940[_0x1d9e34('0x2b')]=_0x2320e4,_0xf4a940[_0x1d9e34('0x11')]=moment(_0x2320e4)[_0x1d9e34('0x4')](0x7,_0x1d9e34('0x5'))[_0x1d9e34('0x2a')](),_0xf4a940[_0x1d9e34('0x8')]=_0xf4a940['uuid']!=_0xf4a940['machineUuid']?_0x1d9e34('0x19'):_0x1d9e34('0x17');}return _0xf4a940;}catch(_0xa533e7){return breakingLicense[_0x1d9e34('0xf')]=_0x6a0fd5[_0x1d9e34('0x22')],breakingLicense[_0x1d9e34('0xb')]=_0xa533e7[_0x1d9e34('0xb')],breakingLicense;}}function getLimits(){return new Promise(function(_0x363163,_0x39d938){const _0x294be7=a845_0x1435;getLicense()[_0x294be7('0xa')](function(_0x4a99be){const _0x169607=_0x294be7;return db[_0x169607('0x1f')][_0x169607('0x1b')]({'attributes':[_0x169607('0x6'),[fn(_0x169607('0x12'),col('role')),'count']],'group':_0x169607('0x6'),'where':{'role':{[Op['or']]:['admin','user',_0x169607('0xe')]}},'raw':!![]})[_0x169607('0xa')](function(_0x14b2fd){const _0x3f92e7=_0x169607,_0x5b47a5={'user':_0x4a99be[_0x3f92e7('0x1c')]||0x0,'telephone':_0x4a99be[_0x3f92e7('0x1a')]||0x0};_0x14b2fd[_0x3f92e7('0x2d')](function(_0x549163){const _0x7694f=_0x3f92e7,_0x2512a8=_0x549163['role']===_0x7694f('0x16')?'user':_0x549163[_0x7694f('0x6')];_0x5b47a5[_0x2512a8]-=_0x549163[_0x7694f('0x13')];if(_0x5b47a5[_0x2512a8]<0x0)_0x5b47a5[_0x2512a8]=0x0;}),_0x363163(_0x5b47a5);return;});})[_0x294be7('0x9')](function(_0x110d68){_0x39d938(_0x110d68);});});}function checkUserLimits(_0x1c13ff){return new Promise(function(_0x16d59a,_0xfbbe5a){const _0x3bb8f3=a845_0x1435;getLimits()[_0x3bb8f3('0xa')](function(_0x528e0d){const _0x4dc2b7=_0x3bb8f3,_0xd53f46=_[_0x4dc2b7('0x1')](_[_0x4dc2b7('0x1d')](_0x1c13ff,_0x4dc2b7('0x6')),[_0x4dc2b7('0x16'),_0x4dc2b7('0x24'),'telephone']),_0x3ee9c8=(_0xd53f46[_0x4dc2b7('0x16')]||0x0)+(_0xd53f46[_0x4dc2b7('0x24')]||0x0),_0x4fc59e=_0xd53f46[_0x4dc2b7('0xe')]||0x0;if(_0x3ee9c8>_0x528e0d[_0x4dc2b7('0x24')])return _0xfbbe5a(_0x4dc2b7('0x7'));if(_0x4fc59e>_0x528e0d[_0x4dc2b7('0xe')])return _0xfbbe5a(_0x4dc2b7('0x0'));return _0x16d59a();})['catch'](function(_0x3bb850){_0xfbbe5a(_0x3bb850);});});}module[_0x5b21f8('0x29')]={'checkLicense':checkLicense,'checkUserLimits':checkUserLimits,'getLicense':getLicense}; \ No newline at end of file diff --git a/server/config/local.env.js b/server/config/local.env.js index 56f14ac..0c5f85f 100644 --- a/server/config/local.env.js +++ b/server/config/local.env.js @@ -1 +1 @@ -var a846_0x460f=['app-id','exports'];(function(_0x33732e,_0x460fee){var _0x51bc6c=function(_0x1c8a24){while(--_0x1c8a24){_0x33732e['push'](_0x33732e['shift']());}};_0x51bc6c(++_0x460fee);}(a846_0x460f,0x105));var a846_0x51bc=function(_0x33732e,_0x460fee){_0x33732e=_0x33732e-0x0;var _0x51bc6c=a846_0x460f[_0x33732e];return _0x51bc6c;};var _0x219a24=a846_0x51bc;'use strict';module[_0x219a24('0x0')]={'DOMAIN':'http://localhost:9000','SESSION_SECRET':'myappanuglar-secret','GOOGLE_ID':_0x219a24('0x1'),'GOOGLE_SECRET':'secret','DEBUG':''}; \ No newline at end of file +var a846_0x36fd=['myappanuglar-secret','http://localhost:9000','exports','secret'];(function(_0x33535d,_0x36fdbb){var _0x303d49=function(_0x14f1d6){while(--_0x14f1d6){_0x33535d['push'](_0x33535d['shift']());}};_0x303d49(++_0x36fdbb);}(a846_0x36fd,0x187));var a846_0x303d=function(_0x33535d,_0x36fdbb){_0x33535d=_0x33535d-0x0;var _0x303d49=a846_0x36fd[_0x33535d];return _0x303d49;};var _0x291d42=a846_0x303d;'use strict';module[_0x291d42('0x3')]={'DOMAIN':_0x291d42('0x2'),'SESSION_SECRET':_0x291d42('0x1'),'GOOGLE_ID':'app-id','GOOGLE_SECRET':_0x291d42('0x0'),'DEBUG':''}; \ No newline at end of file diff --git a/server/config/logger.js b/server/config/logger.js index b5ef739..45e470f 100644 --- a/server/config/logger.js +++ b/server/config/logger.js @@ -1 +1 @@ -const a847_0x42e9=['assign','./config.service','exports','logPath','path','createLogger','%s-%s','safe-stable-stringify','triple-beam','debugLevel','util','winston','transports','%s-%s.log','format','getConfigService','error','join','info'];(function(_0x3b6345,_0x42e948){const _0x4fcf33=function(_0x1c0fe6){while(--_0x1c0fe6){_0x3b6345['push'](_0x3b6345['shift']());}};_0x4fcf33(++_0x42e948);}(a847_0x42e9,0x1a6));const a847_0x4fcf=function(_0x3b6345,_0x42e948){_0x3b6345=_0x3b6345-0x0;let _0x4fcf33=a847_0x42e9[_0x3b6345];return _0x4fcf33;};const _0x34b60d=a847_0x4fcf;'use strict';const moment=require('moment'),winston=require(_0x34b60d('0x7')),util=require(_0x34b60d('0x6')),path=require(_0x34b60d('0x0')),{MESSAGE}=require(_0x34b60d('0x4')),jsonStringify=require(_0x34b60d('0x3')),cs=require(_0x34b60d('0x10'))[_0x34b60d('0xb')](),logPath=cs[_0x34b60d('0x12')];function filename(_0x1c0fe6,_0x1820f8){const _0x99013e=_0x34b60d;return path[_0x99013e('0xd')](logPath,util[_0x99013e('0xa')](_0x99013e('0x9'),_0x1c0fe6,_0x1820f8));}const MotionFormatter=_0x124fc7=>winston[_0x34b60d('0xa')](_0x4be3b5=>{const _0x2f6147=_0x34b60d,_0x85c413=moment()[_0x2f6147('0xa')]('YYYY-MM-DD\x20HH:mm:ss'),{level:_0x43ce67,message:_0x467478}=_0x4be3b5,_0x5f5771=jsonStringify(Object[_0x2f6147('0xf')]({},_0x4be3b5,{'level':undefined,'message':undefined,'splat':undefined}));return _0x4be3b5[MESSAGE]='['+_0x85c413+']\x20['+_0x43ce67['toUpperCase']()+']\x20'+_0x124fc7+'\x20-\x20'+_0x467478+'\x20'+(_0x5f5771==='{}'?'':_0x5f5771),_0x4be3b5;})();module[_0x34b60d('0x11')]=function(_0x547a9d){const _0x5c55ed=_0x34b60d;return winston[_0x5c55ed('0x1')]({'transports':[new winston[(_0x5c55ed('0x8'))]['File']({'name':util[_0x5c55ed('0xa')](_0x5c55ed('0x2'),_0x547a9d,_0x5c55ed('0xc')),'filename':filename(_0x547a9d,_0x5c55ed('0xc')),'level':_0x5c55ed('0xc'),'maxsize':0xa00000,'maxFiles':0xa,'tailable':!![],'format':MotionFormatter(_0x547a9d)}),new winston[(_0x5c55ed('0x8'))]['File']({'name':util[_0x5c55ed('0xa')](_0x5c55ed('0x2'),_0x547a9d,_0x5c55ed('0xe')),'filename':filename(_0x547a9d,_0x5c55ed('0xe')),'level':_0x5c55ed('0xe'),'maxsize':0xa00000,'maxFiles':0xa,'tailable':!![],'format':MotionFormatter(_0x547a9d)}),new winston[(_0x5c55ed('0x8'))]['Console']({'level':cs[_0x5c55ed('0x5')],'format':MotionFormatter(_0x547a9d)})]});}; \ No newline at end of file +const a847_0x2a3e=['triple-beam','YYYY-MM-DD\x20HH:mm:ss','error','winston','transports','exports','safe-stable-stringify','%s-%s.log','debugLevel','createLogger','format','logPath','info','join','Console','File','\x20-\x20','assign','util'];(function(_0xdc8916,_0x2a3e00){const _0x14832a=function(_0x3bcd88){while(--_0x3bcd88){_0xdc8916['push'](_0xdc8916['shift']());}};_0x14832a(++_0x2a3e00);}(a847_0x2a3e,0xa7));const a847_0x1483=function(_0xdc8916,_0x2a3e00){_0xdc8916=_0xdc8916-0x0;let _0x14832a=a847_0x2a3e[_0xdc8916];return _0x14832a;};const _0x4109ac=a847_0x1483;'use strict';const moment=require('moment'),winston=require(_0x4109ac('0x7')),util=require(_0x4109ac('0x3')),path=require('path'),{MESSAGE}=require(_0x4109ac('0x4')),jsonStringify=require(_0x4109ac('0xa')),cs=require('./config.service')['getConfigService'](),logPath=cs[_0x4109ac('0xf')];function filename(_0x3bcd88,_0x2c601e){const _0x7d18d2=_0x4109ac;return path[_0x7d18d2('0x11')](logPath,util[_0x7d18d2('0xe')](_0x7d18d2('0xb'),_0x3bcd88,_0x2c601e));}const MotionFormatter=_0x2f9bb6=>winston['format'](_0x34e4fa=>{const _0x11ed92=_0x4109ac,_0x13052=moment()[_0x11ed92('0xe')](_0x11ed92('0x5')),{level:_0x23824d,message:_0x3cc629}=_0x34e4fa,_0x3526bd=jsonStringify(Object[_0x11ed92('0x2')]({},_0x34e4fa,{'level':undefined,'message':undefined,'splat':undefined}));return _0x34e4fa[MESSAGE]='['+_0x13052+']\x20['+_0x23824d['toUpperCase']()+']\x20'+_0x2f9bb6+_0x11ed92('0x1')+_0x3cc629+'\x20'+(_0x3526bd==='{}'?'':_0x3526bd),_0x34e4fa;})();module[_0x4109ac('0x9')]=function(_0x344c0d){const _0x4733f3=_0x4109ac;return winston[_0x4733f3('0xd')]({'transports':[new winston[(_0x4733f3('0x8'))][(_0x4733f3('0x0'))]({'name':util['format']('%s-%s',_0x344c0d,_0x4733f3('0x6')),'filename':filename(_0x344c0d,_0x4733f3('0x6')),'level':_0x4733f3('0x6'),'maxsize':0xa00000,'maxFiles':0xa,'tailable':!![],'format':MotionFormatter(_0x344c0d)}),new winston['transports'][(_0x4733f3('0x0'))]({'name':util['format']('%s-%s',_0x344c0d,_0x4733f3('0x10')),'filename':filename(_0x344c0d,_0x4733f3('0x10')),'level':_0x4733f3('0x10'),'maxsize':0xa00000,'maxFiles':0xa,'tailable':!![],'format':MotionFormatter(_0x344c0d)}),new winston['transports'][(_0x4733f3('0x12'))]({'level':cs[_0x4733f3('0xc')],'format':MotionFormatter(_0x344c0d)})]});}; \ No newline at end of file diff --git a/server/config/pm2/config.js b/server/config/pm2/config.js index ce93c32..f64475a 100644 --- a/server/config/pm2/config.js +++ b/server/config/pm2/config.js @@ -1 +1 @@ -const a848_0xb028=['services/express/index.js','path','join','agi','services/email/index.js','xdr','services/routing/index.js','email','ami','express','appRoot','services/agi/index.js','services/ami/index.js','exports','services/xdr/index.js'];(function(_0x5e55d6,_0xb02859){const _0x4e72be=function(_0x1364a1){while(--_0x1364a1){_0x5e55d6['push'](_0x5e55d6['shift']());}};_0x4e72be(++_0xb02859);}(a848_0xb028,0x111));const a848_0x4e72=function(_0x5e55d6,_0xb02859){_0x5e55d6=_0x5e55d6-0x0;let _0x4e72be=a848_0xb028[_0x5e55d6];return _0x4e72be;};const _0x376e08=a848_0x4e72;'use strict';const path=require(_0x376e08('0xd')),config={'apps':[{'wait_ready':!![],'name':_0x376e08('0x6'),'script':path['join'](global['appRoot'],_0x376e08('0xc'))},{'name':_0x376e08('0x5'),'script':path[_0x376e08('0xe')](global[_0x376e08('0x7')],_0x376e08('0x9'))},{'name':_0x376e08('0x0'),'script':path[_0x376e08('0xe')](global[_0x376e08('0x7')],_0x376e08('0x8'))},{'name':_0x376e08('0x4'),'script':path[_0x376e08('0xe')](global[_0x376e08('0x7')],_0x376e08('0x1'))},{'name':'routing','script':path[_0x376e08('0xe')](global[_0x376e08('0x7')],_0x376e08('0x3'))},{'name':_0x376e08('0x2'),'script':path[_0x376e08('0xe')](global['appRoot'],_0x376e08('0xb'))}]};module[_0x376e08('0xa')]=config; \ No newline at end of file +const a848_0x59f9=['appRoot','express','services/email/index.js','routing','ami','path','agi','services/express/index.js','exports','join','services/ami/index.js'];(function(_0x5667cc,_0x59f9d6){const _0x558839=function(_0x39432e){while(--_0x39432e){_0x5667cc['push'](_0x5667cc['shift']());}};_0x558839(++_0x59f9d6);}(a848_0x59f9,0xf6));const a848_0x5588=function(_0x5667cc,_0x59f9d6){_0x5667cc=_0x5667cc-0x0;let _0x558839=a848_0x59f9[_0x5667cc];return _0x558839;};const _0x78d160=a848_0x5588;'use strict';const path=require(_0x78d160('0x1')),config={'apps':[{'wait_ready':!![],'name':_0x78d160('0x8'),'script':path[_0x78d160('0x5')](global[_0x78d160('0x7')],_0x78d160('0x3'))},{'name':_0x78d160('0x0'),'script':path[_0x78d160('0x5')](global[_0x78d160('0x7')],_0x78d160('0x6'))},{'name':_0x78d160('0x2'),'script':path[_0x78d160('0x5')](global[_0x78d160('0x7')],'services/agi/index.js')},{'name':'email','script':path['join'](global[_0x78d160('0x7')],_0x78d160('0x9'))},{'name':_0x78d160('0xa'),'script':path[_0x78d160('0x5')](global[_0x78d160('0x7')],'services/routing/index.js')},{'name':'xdr','script':path[_0x78d160('0x5')](global[_0x78d160('0x7')],'services/xdr/index.js')}]};module[_0x78d160('0x4')]=config; \ No newline at end of file diff --git a/server/config/pm2/index.js b/server/config/pm2/index.js index 61c22e7..8ec60a4 100644 --- a/server/config/pm2/index.js +++ b/server/config/pm2/index.js @@ -1 +1 @@ -const a849_0xc6d5=['list','dump','restart','nodeArgs','environment','interpreter_args','isTest','node_args','delete','connected','stop','debug','--inspect','saved','../config.service','getConfigService','then','disconnect','pm2','start','describe','interpreter','vscode_debugger','interpreterArgs'];(function(_0x17c87d,_0xc6d5d5){const _0x2e1898=function(_0x199bea){while(--_0x199bea){_0x17c87d['push'](_0x17c87d['shift']());}};_0x2e1898(++_0xc6d5d5);}(a849_0xc6d5,0x1a6));const a849_0x2e18=function(_0x17c87d,_0xc6d5d5){_0x17c87d=_0x17c87d-0x0;let _0x2e1898=a849_0xc6d5[_0x17c87d];return _0x2e1898;};const _0xfe2ae=a849_0x2e18;'use strict';const pm2=require(_0xfe2ae('0x4')),cs=require(_0xfe2ae('0x0'))[_0xfe2ae('0x1')]();function connect(){return new Promise(function(_0x199bea,_0x1d1c4a){return pm2['connect'](function(_0x2150ce){const _0x226b94=a849_0x2e18;_0x2150ce?_0x1d1c4a(_0x2150ce):_0x199bea(_0x226b94('0x13'));});});}exports[_0xfe2ae('0x5')]=function(_0x3d9734){const _0x5ebe04=_0xfe2ae;return!(cs['isProduction']||cs[_0x5ebe04('0x10')]||cs[_0x5ebe04('0xe')]===_0x5ebe04('0x8'))&&(_0x3d9734[_0x5ebe04('0x7')]='node',_0x3d9734[_0x5ebe04('0xf')]=['--inspect'],_0x3d9734[_0x5ebe04('0x11')]=[_0x5ebe04('0x16')],_0x3d9734[_0x5ebe04('0x9')]=[_0x5ebe04('0x16')],_0x3d9734[_0x5ebe04('0xd')]=[_0x5ebe04('0x16')]),connect()[_0x5ebe04('0x2')](function(){return new Promise(function(_0x95a3d4,_0x264f4e){const _0x5c4ee3=a849_0x2e18;return pm2[_0x5c4ee3('0x5')](_0x3d9734,function(_0x7b10b3,_0x5de727){const _0x8c507f=_0x5c4ee3;_0x7b10b3?_0x264f4e(_0x7b10b3):(pm2[_0x8c507f('0x3')](),_0x95a3d4(_0x5de727));});});});},exports[_0xfe2ae('0x14')]=function(_0x111c18){const _0x472577=_0xfe2ae;return connect()[_0x472577('0x2')](function(){return new Promise(function(_0x120d69,_0x5cb269){const _0x2bfc89=a849_0x2e18;return pm2[_0x2bfc89('0x14')](_0x111c18,function(_0xa2a18f,_0x44c3f3){const _0x72533d=_0x2bfc89;_0xa2a18f?_0x5cb269(_0xa2a18f):(console[_0x72533d('0x15')]('Stopped',_0x111c18),_0x120d69(_0x44c3f3));});});});},exports[_0xfe2ae('0xc')]=function(_0x5c3e80){return connect()['then'](function(){return new Promise(function(_0x293e0e,_0x2c08ea){const _0x16cb31=a849_0x2e18;return pm2[_0x16cb31('0xc')](_0x5c3e80,function(_0x68957d,_0x104044){_0x68957d?_0x2c08ea(_0x68957d):(console['debug']('Restarted',_0x5c3e80),_0x293e0e(_0x104044));});});});},exports[_0xfe2ae('0xa')]=function(){return connect()['then'](function(){return new Promise(function(_0x5183de,_0x2fd255){const _0x293bea=a849_0x2e18;return pm2[_0x293bea('0xa')](function(_0x46a8cf,_0x4406ed){_0x46a8cf?_0x2fd255(_0x46a8cf):_0x5183de(_0x4406ed);});});});},exports[_0xfe2ae('0x6')]=function(_0x2f92fa){return connect()['then'](function(){return new Promise(function(_0x1d6286,_0xfc6bf5){return pm2['describe'](_0x2f92fa,function(_0x538e4d,_0x5dad38){_0x538e4d?_0xfc6bf5(_0x538e4d):_0x1d6286(_0x5dad38);});});});},exports[_0xfe2ae('0x12')]=function(_0x41b743){const _0x5c5c25=_0xfe2ae;return connect()[_0x5c5c25('0x2')](function(){return new Promise(function(_0x57521b,_0x24275d){const _0x62fe19=a849_0x2e18;return pm2[_0x62fe19('0x12')](_0x41b743,function(_0x4e23c2,_0x5b0bcb){const _0x5de6c6=_0x62fe19;_0x4e23c2?_0x24275d(_0x4e23c2):(console[_0x5de6c6('0x15')]('Stopped\x20and\x20Deleted',_0x41b743),_0x57521b(_0x5b0bcb));});});});},exports[_0xfe2ae('0xb')]=function(){const _0x1717a0=_0xfe2ae;return connect()[_0x1717a0('0x2')](function(){return new Promise(function(_0x5bd602,_0x6cad24){const _0x44da46=a849_0x2e18;return pm2[_0x44da46('0xb')](function(_0x66026){const _0x50b0e6=_0x44da46;_0x66026?_0x6cad24(_0x66026):_0x5bd602(_0x50b0e6('0x17'));});});});}; \ No newline at end of file +const a849_0x15ac=['environment','list','Stopped\x20and\x20Deleted','stop','Stopped','dump','../config.service','describe','pm2','Restarted','--inspect','start','delete','node','connected','interpreter','getConfigService','debug','vscode_debugger','node_args','interpreterArgs','interpreter_args','nodeArgs','connect','restart','then'];(function(_0x396fc6,_0x15ac09){const _0x206426=function(_0x1ea335){while(--_0x1ea335){_0x396fc6['push'](_0x396fc6['shift']());}};_0x206426(++_0x15ac09);}(a849_0x15ac,0xb0));const a849_0x2064=function(_0x396fc6,_0x15ac09){_0x396fc6=_0x396fc6-0x0;let _0x206426=a849_0x15ac[_0x396fc6];return _0x206426;};const _0xe8ded7=a849_0x2064;'use strict';const pm2=require(_0xe8ded7('0xe')),cs=require(_0xe8ded7('0xc'))[_0xe8ded7('0x16')]();function connect(){return new Promise(function(_0x1ea335,_0x1f3dce){const _0x3a5436=a849_0x2064;return pm2[_0x3a5436('0x3')](function(_0x5fbe46){const _0x19c8d0=_0x3a5436;_0x5fbe46?_0x1f3dce(_0x5fbe46):_0x1ea335(_0x19c8d0('0x14'));});});}exports[_0xe8ded7('0x11')]=function(_0xccb9cd){const _0x2e5015=_0xe8ded7;return!(cs['isProduction']||cs['isTest']||cs[_0x2e5015('0x6')]===_0x2e5015('0x18'))&&(_0xccb9cd[_0x2e5015('0x15')]=_0x2e5015('0x13'),_0xccb9cd[_0x2e5015('0x1')]=[_0x2e5015('0x10')],_0xccb9cd[_0x2e5015('0x19')]=['--inspect'],_0xccb9cd[_0x2e5015('0x0')]=[_0x2e5015('0x10')],_0xccb9cd[_0x2e5015('0x2')]=[_0x2e5015('0x10')]),connect()[_0x2e5015('0x5')](function(){return new Promise(function(_0x12abca,_0x1fb532){return pm2['start'](_0xccb9cd,function(_0x480bf3,_0x5e976e){_0x480bf3?_0x1fb532(_0x480bf3):(pm2['disconnect'](),_0x12abca(_0x5e976e));});});});},exports[_0xe8ded7('0x9')]=function(_0x24d4e9){return connect()['then'](function(){return new Promise(function(_0x57063b,_0x7bea02){return pm2['stop'](_0x24d4e9,function(_0x588da5,_0x5ac1d4){const _0x1b7358=a849_0x2064;_0x588da5?_0x7bea02(_0x588da5):(console[_0x1b7358('0x17')](_0x1b7358('0xa'),_0x24d4e9),_0x57063b(_0x5ac1d4));});});});},exports['restart']=function(_0x36c2ea){const _0xace050=_0xe8ded7;return connect()[_0xace050('0x5')](function(){return new Promise(function(_0x13b427,_0x2b2334){const _0x1c708f=a849_0x2064;return pm2[_0x1c708f('0x4')](_0x36c2ea,function(_0x3a3e5e,_0x1d731f){const _0x410131=_0x1c708f;_0x3a3e5e?_0x2b2334(_0x3a3e5e):(console[_0x410131('0x17')](_0x410131('0xf'),_0x36c2ea),_0x13b427(_0x1d731f));});});});},exports[_0xe8ded7('0x7')]=function(){const _0x53ff90=_0xe8ded7;return connect()[_0x53ff90('0x5')](function(){return new Promise(function(_0x12c207,_0xb4d504){return pm2['list'](function(_0x2c717a,_0x23a580){_0x2c717a?_0xb4d504(_0x2c717a):_0x12c207(_0x23a580);});});});},exports[_0xe8ded7('0xd')]=function(_0x36fcc7){const _0x5c1eb7=_0xe8ded7;return connect()[_0x5c1eb7('0x5')](function(){return new Promise(function(_0x5effe6,_0x169a14){return pm2['describe'](_0x36fcc7,function(_0x49e01c,_0x246cdd){_0x49e01c?_0x169a14(_0x49e01c):_0x5effe6(_0x246cdd);});});});},exports['delete']=function(_0x362a72){const _0x37cd8a=_0xe8ded7;return connect()[_0x37cd8a('0x5')](function(){return new Promise(function(_0x445386,_0x49d9b9){const _0x2ef101=a849_0x2064;return pm2[_0x2ef101('0x12')](_0x362a72,function(_0xca4916,_0xfd54ad){const _0x36e8c1=_0x2ef101;_0xca4916?_0x49d9b9(_0xca4916):(console[_0x36e8c1('0x17')](_0x36e8c1('0x8'),_0x362a72),_0x445386(_0xfd54ad));});});});},exports[_0xe8ded7('0xb')]=function(){return connect()['then'](function(){return new Promise(function(_0x2ceeba,_0x397e9a){return pm2['dump'](function(_0x1fba45){_0x1fba45?_0x397e9a(_0x1fba45):_0x2ceeba('saved');});});});}; \ No newline at end of file diff --git a/server/config/schedule/chat.js b/server/config/schedule/chat.js index eb18c41..b0991f4 100644 --- a/server/config/schedule/chat.js +++ b/server/config/schedule/chat.js @@ -1 +1 @@ -const a850_0x57a3=['update','chatTimeout','map','subtract','../../mysqldb','emit','lastMsgAt','findAll','YYYY-MM-DD\x20HH:mm:ss','chatInteraction:update','catch','system','then','error','Setting','start','timeout','minutes','findOne'];(function(_0x12d6f2,_0x57a3e9){const _0x11c94c=function(_0x26e00d){while(--_0x26e00d){_0x12d6f2['push'](_0x12d6f2['shift']());}};_0x11c94c(++_0x57a3e9);}(a850_0x57a3,0x1da));const a850_0x11c9=function(_0x12d6f2,_0x57a3e9){_0x12d6f2=_0x12d6f2-0x0;let _0x11c94c=a850_0x57a3[_0x12d6f2];return _0x11c94c;};const _0x3d9cf7=a850_0x11c9;'use strict';const _=require('lodash'),moment=require('moment'),db=require(_0x3d9cf7('0x5'))['db'],{getSocket}=require('../../rediscache'),io=getSocket();function closeInteractions(){const _0x245302=_0x3d9cf7;let _0x26e00d=0x0,_0x2b8572=[];return db[_0x245302('0xf')][_0x245302('0x0')]({'raw':!![],'attributes':['id','chatTimeout'],'where':{'id':0x1}})[_0x245302('0xd')](function(_0x8dc2d){const _0x1ee184=_0x245302;return _0x26e00d=_0x8dc2d[_0x1ee184('0x2')],_0x26e00d?db['ChatInteraction'][_0x1ee184('0x8')]({'raw':!![],'attributes':['id',_0x1ee184('0x7')],'where':{'closed':![],'lastMsgAt':{'$lt':moment()[_0x1ee184('0x4')](_0x8dc2d[_0x1ee184('0x2')],_0x1ee184('0x12'))}}}):[];})[_0x245302('0xd')](function(_0x3bdb73){const _0x1d8792=_0x245302;_0x2b8572=_0x3bdb73;if(_0x26e00d)return db['ChatInteraction'][_0x1d8792('0x1')]({'closeReason':_0x1d8792('0xc'),'disposition':_0x1d8792('0x11'),'closed':!![],'closedAt':moment()['format'](_0x1d8792('0x9'))},{'where':{'id':_[_0x1d8792('0x3')](_0x2b8572||[],'id')}});})[_0x245302('0xd')](function(){const _0x34f49a=_0x245302;for(let _0x31a516=0x0;_0x31a516<_0x2b8572['length'];_0x31a516++){io[_0x34f49a('0x6')](_0x34f49a('0xa'),{'id':_0x2b8572[_0x31a516]['id'],'closed':!![]});}})[_0x245302('0xb')](function(_0x27a57e){const _0x475620=_0x245302;console[_0x475620('0xe')](_0x27a57e);});}exports[_0x3d9cf7('0x10')]=function(){return setInterval(function(){return closeInteractions();},0x3c*0x3e8),closeInteractions();}; \ No newline at end of file +const a850_0x21c7=['map','timeout','system','minutes','format','emit','start','findOne','then','moment','error','../../rediscache','update','catch','chatInteraction:update','YYYY-MM-DD\x20HH:mm:ss','chatTimeout','lodash','ChatInteraction','subtract','../../mysqldb'];(function(_0x20000,_0x21c7c9){const _0x34845b=function(_0x801a6c){while(--_0x801a6c){_0x20000['push'](_0x20000['shift']());}};_0x34845b(++_0x21c7c9);}(a850_0x21c7,0x18e));const a850_0x3484=function(_0x20000,_0x21c7c9){_0x20000=_0x20000-0x0;let _0x34845b=a850_0x21c7[_0x20000];return _0x34845b;};const _0x214ca2=a850_0x3484;'use strict';const _=require(_0x214ca2('0x12')),moment=require(_0x214ca2('0xa')),db=require(_0x214ca2('0x0'))['db'],{getSocket}=require(_0x214ca2('0xc')),io=getSocket();function closeInteractions(){const _0x3aac4a=_0x214ca2;let _0x801a6c=0x0,_0x146adc=[];return db['Setting'][_0x3aac4a('0x8')]({'raw':!![],'attributes':['id','chatTimeout'],'where':{'id':0x1}})[_0x3aac4a('0x9')](function(_0x45d78d){const _0x13f611=_0x3aac4a;return _0x801a6c=_0x45d78d[_0x13f611('0x11')],_0x801a6c?db[_0x13f611('0x13')]['findAll']({'raw':!![],'attributes':['id','lastMsgAt'],'where':{'closed':![],'lastMsgAt':{'$lt':moment()[_0x13f611('0x14')](_0x45d78d['chatTimeout'],_0x13f611('0x4'))}}}):[];})[_0x3aac4a('0x9')](function(_0x17fba6){const _0x11f2a9=_0x3aac4a;_0x146adc=_0x17fba6;if(_0x801a6c)return db['ChatInteraction'][_0x11f2a9('0xd')]({'closeReason':_0x11f2a9('0x3'),'disposition':_0x11f2a9('0x2'),'closed':!![],'closedAt':moment()[_0x11f2a9('0x5')](_0x11f2a9('0x10'))},{'where':{'id':_[_0x11f2a9('0x1')](_0x146adc||[],'id')}});})['then'](function(){const _0x5da9eb=_0x3aac4a;for(let _0x355af3=0x0;_0x355af3<_0x146adc['length'];_0x355af3++){io[_0x5da9eb('0x6')](_0x5da9eb('0xf'),{'id':_0x146adc[_0x355af3]['id'],'closed':!![]});}})[_0x3aac4a('0xe')](function(_0xd25b91){const _0x10b563=_0x3aac4a;console[_0x10b563('0xb')](_0xd25b91);});}exports[_0x214ca2('0x7')]=function(){return setInterval(function(){return closeInteractions();},0x3c*0x3e8),closeInteractions();}; \ No newline at end of file diff --git a/server/config/schedule/index.js b/server/config/schedule/index.js index b1cc078..ad41bc7 100644 --- a/server/config/schedule/index.js +++ b/server/config/schedule/index.js @@ -1 +1 @@ -const a851_0x867e=['join','scheduled','subtractNumber','update\x20cron','cron','difference','savename','attachments','name','message','endAt','pass','MailServerOut','auth','startAt','%s.%s','authentication','extname','YYYY-MM-DD\x20HH:mm:ss','Sent','catch','text','update','../../api/analyticDefaultReport/analyticDefaultReport.controller','CustomReportId','zip','exec\x20defaul\x20report\x20id:%s','cron-job-manager','keyBy','../../files/reports','error\x20mail','isNil','../../mysqldb','jobs','resolve','stop\x20cron','start','isBetween','intersection','client','subtractUnit\x20null\x20or\x20undefined','active','secure','\x22%s\x22\x20<%s>','deleteJob','add\x20cron','subtract','bcc','stringify','subtractNumber\x20null\x20or\x20undefined','runReport','format','service','port','Info\x20report:\x0a%s\x0aPlease\x20see\x20the\x20attachments\x0aThis\x20is\x20an\x20automatically\x20generated\x20email\x20–\x20please\x20do\x20not\x20reply\x20to\x20it.\x0a\x0a','sendIfEmpty','subtractUnit','MailAccount','lodash','delete\x20cron','status','jayson/promise','then','exec\x20custom\x20report\x20id:%s','Smtp','email\x20sent','DefaultReportId','index','length','http','toString','exists','basename','stop','keys','user','findAll','run\x20job','run','email','Report\x20%s\x20last\x20%s\x20%s','info','empty\x20file,\x20email\x20not\x20sent','add','error','host'];(function(_0x379ff2,_0x867e3c){const _0x2255f6=function(_0x4e38ca){while(--_0x4e38ca){_0x379ff2['push'](_0x379ff2['shift']());}};_0x2255f6(++_0x867e3c);}(a851_0x867e,0xc7));const a851_0x2255=function(_0x379ff2,_0x867e3c){_0x379ff2=_0x379ff2-0x0;let _0x2255f6=a851_0x867e[_0x379ff2];return _0x2255f6;};const _0x257049=a851_0x2255;'use strict';const fs=require('fs'),util=require('util'),path=require('path'),_=require(_0x257049('0x1f')),moment=require('moment'),CronJobManager=require(_0x257049('0x0')),jayson=require(_0x257049('0x22')),logger=require('../logger')('schedule'),db=require(_0x257049('0x5'))['db'],analyticCustomReportController=require('../../api/analyticCustomReport/analyticCustomReport.controller'),analyticDefaultReportController=require(_0x257049('0x52')),client=jayson[_0x257049('0xc')][_0x257049('0x2a')]({'port':0x232b}),manager=new CronJobManager();function handleSendEmail(_0x4e38ca,_0x56f6f7){return function(){const _0x48b737=a851_0x2255;logger['info']('Try\x20to\x20send\x20a\x20mail\x20to',_0x4e38ca[_0x48b737('0x34')]);let _0x544680=!![];const _0x185bf4={'tls':{'rejectUnauthorized':![]}};_0x4e38ca[_0x48b737('0x1e')][_0x48b737('0x25')][_0x48b737('0x19')]?_0x185bf4['service']=_0x4e38ca[_0x48b737('0x1e')]['Smtp'][_0x48b737('0x19')]:(_0x185bf4[_0x48b737('0x3a')]=_0x4e38ca[_0x48b737('0x1e')][_0x48b737('0x25')][_0x48b737('0x3a')],_0x185bf4[_0x48b737('0x1a')]=_0x4e38ca[_0x48b737('0x1e')][_0x48b737('0x25')][_0x48b737('0x1a')],_0x185bf4[_0x48b737('0xf')]=_0x4e38ca[_0x48b737('0x1e')][_0x48b737('0x25')]['secure']);_0x4e38ca[_0x48b737('0x1e')]['Smtp'][_0x48b737('0x4b')]&&(_0x185bf4[_0x48b737('0x48')]={'user':_0x4e38ca[_0x48b737('0x1e')][_0x48b737('0x25')][_0x48b737('0x30')],'pass':_0x4e38ca['MailAccount'][_0x48b737('0x25')][_0x48b737('0x46')]});const _0x4051e9={'account':_0x185bf4,'message':{'from':util[_0x48b737('0x18')](_0x48b737('0x10'),_0x4e38ca[_0x48b737('0x1e')][_0x48b737('0x43')],_0x4e38ca[_0x48b737('0x1e')]['email']||_0x4e38ca['MailAccount'][_0x48b737('0x25')]['user']),'to':_0x4e38ca[_0x48b737('0x34')],'cc':_0x4e38ca['cc'],'bcc':_0x4e38ca[_0x48b737('0x14')],'subject':util['format'](_0x48b737('0x35'),_0x56f6f7[_0x48b737('0x43')],_0x4e38ca[_0x48b737('0x3d')],_0x4e38ca['subtractUnit'])}},_0x1207ca=path[_0x48b737('0x3b')](__dirname,_0x48b737('0x2')),_0x5e02c1=_0x56f6f7[_0x48b737('0x41')],_0x4ad1ce=util[_0x48b737('0x18')](_0x48b737('0x4a'),path[_0x48b737('0x2d')](_0x56f6f7['savename'],path[_0x48b737('0x4c')](_0x56f6f7[_0x48b737('0x41')])),_0x48b737('0x54')),_0x4aad27=path[_0x48b737('0x3b')](_0x1207ca,_0x5e02c1),_0x12d0d8=path[_0x48b737('0x3b')](_0x1207ca,_0x4ad1ce);if(fs['existsSync'](_0x4aad27))_0x56f6f7[_0x48b737('0x21')]=_0x48b737('0x4e'),_0x4051e9[_0x48b737('0x44')][_0x48b737('0x42')]=[{'filename':_0x5e02c1,'path':_0x4aad27}],_0x4051e9['message'][_0x48b737('0x50')]=util['format'](_0x48b737('0x1b'),JSON[_0x48b737('0x15')](_0x56f6f7,null,0x2));else fs['existsSync'](_0x12d0d8)?(_0x56f6f7['status']=_0x48b737('0x4e'),_0x4051e9['message']['attachments']=[{'filename':_0x4ad1ce,'path':_0x12d0d8}]):(_0x4051e9[_0x48b737('0x44')]['text']='Report\x20empty\x0aThis\x20is\x20an\x20automatically\x20generated\x20email\x20–\x20please\x20do\x20not\x20reply\x20to\x20this\x20email.\x0a\x0a',!_0x4e38ca[_0x48b737('0x1c')]&&(_0x544680=![],logger[_0x48b737('0x36')](_0x48b737('0x37'))));if(_0x544680)return client['request']('SendMail',_0x4051e9)[_0x48b737('0x23')](function(_0x436d85){const _0x23998d=_0x48b737;if(_0x436d85[_0x23998d('0x39')])return logger[_0x23998d('0x39')]('error\x20mail',JSON['stringify'](_0x436d85));return logger['info'](_0x23998d('0x26'));})[_0x48b737('0x4f')](function(_0x47b6fd){const _0x222591=_0x48b737;return logger[_0x222591('0x39')](_0x222591('0x3'),JSON[_0x222591('0x15')](_0x47b6fd));});};}function handleError(){return function(_0x49f1ef){const _0x3f5bfa=a851_0x2255;return logger[_0x3f5bfa('0x39')](JSON[_0x3f5bfa('0x15')](_0x49f1ef));};}function handleResult(_0x41c4c6){return function(_0x5b5086){const _0x560c5c=a851_0x2255;logger[_0x560c5c('0x36')]('data',JSON[_0x560c5c('0x15')](_0x5b5086)),_0x41c4c6[_0x560c5c('0x1e')]&&_0x41c4c6[_0x560c5c('0x1e')][_0x560c5c('0x25')]&&!_['isNil'](_0x41c4c6[_0x560c5c('0x34')])&&setTimeout(handleSendEmail(_0x41c4c6,_0x5b5086),0x3c*0x3e8);};}function handleJob(_0x193a5e){return function(){const _0x542a18=a851_0x2255;try{if(_[_0x542a18('0x4')](_0x193a5e[_0x542a18('0x3d')]))return logger['info'](_0x542a18('0x16'));if(_[_0x542a18('0x4')](_0x193a5e[_0x542a18('0x1d')]))return logger[_0x542a18('0x36')](_0x542a18('0xd'));const _0x288718={'startDate':moment()[_0x542a18('0x13')](_0x193a5e['subtractNumber'],_0x193a5e[_0x542a18('0x1d')])[_0x542a18('0x18')]('YYYY-MM-DD\x20HH:mm:ss'),'endDate':moment()[_0x542a18('0x18')](_0x542a18('0x4d')),'type':_0x542a18('0x3c'),'output':_0x193a5e['output'],'name':_0x193a5e[_0x542a18('0x43')]};if(!_[_0x542a18('0x4')](_0x193a5e['DefaultReportId']))return logger[_0x542a18('0x36')](_0x542a18('0x55'),_0x193a5e[_0x542a18('0x27')]),analyticDefaultReportController[_0x542a18('0x17')]({'id':_0x193a5e[_0x542a18('0x27')]},_0x288718)['then'](handleResult(_0x193a5e))[_0x542a18('0x4f')](handleError());if(!_['isNil'](_0x193a5e['CustomReportId']))return logger[_0x542a18('0x36')](_0x542a18('0x24'),_0x193a5e[_0x542a18('0x53')]),analyticCustomReportController[_0x542a18('0x17')]({'id':_0x193a5e[_0x542a18('0x53')]},_0x288718)[_0x542a18('0x23')](handleResult(_0x193a5e))[_0x542a18('0x4f')](handleError());}catch(_0x357c89){logger['error'](JSON[_0x542a18('0x15')](_0x357c89));}return logger[_0x542a18('0x36')]('no\x20report\x20id');};}function getJobs(_0x5c45ce){const _0x3f192e=_0x257049,_0x1143c0={};return _0x5c45ce&&(_0x1143c0['id']=_0x5c45ce),db['Schedule'][_0x3f192e('0x31')]({'where':_0x1143c0,'include':[{'model':db[_0x3f192e('0x1e')],'attributes':['id',_0x3f192e('0x43'),_0x3f192e('0x34')],'include':[{'model':db[_0x3f192e('0x47')],'as':'Smtp'}]}]})[_0x3f192e('0x23')](function(_0xab1e0c){const _0x19adeb=_0x3f192e,_0x5ee057=_[_0x19adeb('0x2f')](manager[_0x19adeb('0x6')]),_0x10e92b=_['map'](_0xab1e0c,function(_0x52ae72){return _0x52ae72['id']['toString']();}),_0x4ce2b4=_[_0x19adeb('0x1')](_0xab1e0c,function(_0x3adede){const _0x4d068=_0x19adeb;return _0x3adede['id'][_0x4d068('0x2b')]();}),_0x11668d=_0x5c45ce?_0x10e92b:_[_0x19adeb('0x40')](_0x10e92b,_0x5ee057),_0x5a71c3=_[_0x19adeb('0xb')](_0x10e92b,_0x5ee057),_0x47f117=_[_0x19adeb('0x40')](_0x5ee057,_0x10e92b);let _0x555bee,_0x3c5d41;for(_0x555bee=0x0;_0x555bee<_0x47f117[_0x19adeb('0x29')]&&!_0x5c45ce;_0x555bee+=0x1){_0x3c5d41=_0x47f117[_0x555bee][_0x19adeb('0x2b')](),manager[_0x19adeb('0x2c')](_0x3c5d41)&&(manager[_0x19adeb('0x2e')](_0x3c5d41),manager['deleteJob'](_0x3c5d41),logger[_0x19adeb('0x36')](_0x19adeb('0x20'),_0x3c5d41));}logger[_0x19adeb('0x36')]('toRun',JSON[_0x19adeb('0x15')](_0x11668d));for(_0x555bee=0x0;_0x555bee<_0x11668d[_0x19adeb('0x29')];_0x555bee+=0x1){_0x3c5d41=_0x11668d[_0x555bee][_0x19adeb('0x2b')](),logger[_0x19adeb('0x36')](_0x19adeb('0x28'),_0x3c5d41);if(_0x5c45ce)logger[_0x19adeb('0x36')]('my\x20id',_0x5c45ce),logger[_0x19adeb('0x36')](JSON[_0x19adeb('0x15')](_0x4ce2b4[_0x3c5d41])),Promise[_0x19adeb('0x7')]()[_0x19adeb('0x23')](handleJob(_0x4ce2b4[_0x3c5d41])),logger['info'](_0x19adeb('0x32'),_0x4ce2b4[_0x3c5d41][_0x19adeb('0x43')],_0x4ce2b4[_0x3c5d41][_0x19adeb('0x3f')]);else{if(_0x4ce2b4[_0x3c5d41][_0x19adeb('0x3f')]&&_0x4ce2b4[_0x3c5d41][_0x19adeb('0xe')]&&moment()[_0x19adeb('0xa')](_0x4ce2b4[_0x3c5d41][_0x19adeb('0x49')],_0x4ce2b4[_0x3c5d41][_0x19adeb('0x45')]))manager[_0x19adeb('0x38')](_0x3c5d41,_0x4ce2b4[_0x3c5d41]['cron'],handleJob(_0x4ce2b4[_0x3c5d41])),manager[_0x19adeb('0x9')](_0x3c5d41),logger['info'](_0x19adeb('0x12'),_0x4ce2b4[_0x3c5d41]['name'],_0x4ce2b4[_0x3c5d41][_0x19adeb('0x3f')]);else manager[_0x19adeb('0x2c')](_0x3c5d41)&&(manager[_0x19adeb('0x2e')](_0x3c5d41),manager[_0x19adeb('0x11')](_0x3c5d41),logger[_0x19adeb('0x36')](_0x19adeb('0x8'),_0x4ce2b4[_0x3c5d41][_0x19adeb('0x43')],_0x4ce2b4[_0x3c5d41][_0x19adeb('0x3f')]));}}for(_0x555bee=0x0,_0x3c5d41;_0x555bee<_0x5a71c3[_0x19adeb('0x29')]&&!_0x5c45ce;_0x555bee+=0x1){_0x3c5d41=_0x5a71c3[_0x555bee][_0x19adeb('0x2b')](),manager[_0x19adeb('0x2c')](_0x3c5d41)&&(_0x4ce2b4[_0x3c5d41][_0x19adeb('0x3f')]&&_0x4ce2b4[_0x3c5d41][_0x19adeb('0xe')]&&moment()[_0x19adeb('0xa')](_0x4ce2b4[_0x3c5d41][_0x19adeb('0x49')],_0x4ce2b4[_0x3c5d41]['endAt'])?(manager[_0x19adeb('0x51')](_0x3c5d41,_0x4ce2b4[_0x3c5d41][_0x19adeb('0x3f')],handleJob(_0x4ce2b4[_0x3c5d41])),logger[_0x19adeb('0x36')](_0x19adeb('0x3e'),_0x4ce2b4[_0x3c5d41]['name'],_0x4ce2b4[_0x3c5d41][_0x19adeb('0x3f')])):(manager['stop'](_0x3c5d41),manager[_0x19adeb('0x11')](_0x3c5d41),logger[_0x19adeb('0x36')](_0x19adeb('0x8'),_0x4ce2b4[_0x3c5d41][_0x19adeb('0x43')],_0x4ce2b4[_0x3c5d41][_0x19adeb('0x3f')])));}})[_0x3f192e('0x4f')](function(_0x4e231b){const _0x3756b8=_0x3f192e;logger[_0x3756b8('0x39')](JSON['stringify'](_0x4e231b));});}exports[_0x257049('0x33')]=function(_0x5bdbce){return getJobs(_0x5bdbce);},exports[_0x257049('0x9')]=function(){return setInterval(function(){return getJobs();},0x3c*0x3e8),getJobs();}; \ No newline at end of file +const a851_0x6634=['Report\x20empty\x0aThis\x20is\x20an\x20automatically\x20generated\x20email\x20–\x20please\x20do\x20not\x20reply\x20to\x20this\x20email.\x0a\x0a','authentication','keyBy','info','format','MailAccount','basename','toRun','SendMail','user','subtractUnit','keys','toString','run\x20job','Sent','Try\x20to\x20send\x20a\x20mail\x20to','email','join','deleteJob','util','subtractNumber\x20null\x20or\x20undefined','runReport','update\x20cron','jobs','catch','then','isNil','auth','Smtp','CustomReportId','MailServerOut','YYYY-MM-DD\x20HH:mm:ss','start','pass','run','cron','extname','text','resolve','stop','../../api/analyticCustomReport/analyticCustomReport.controller','update','error','subtractNumber','message','exists','findAll','add','name','scheduled','intersection','Schedule','%s.%s','attachments','output','existsSync','savename','request','subtractUnit\x20null\x20or\x20undefined','../../mysqldb','service','lodash','empty\x20file,\x20email\x20not\x20sent','path','stop\x20cron','status','client','error\x20mail','host','length','endAt','no\x20report\x20id','startAt','schedule','\x22%s\x22\x20<%s>','exec\x20custom\x20report\x20id:%s','difference','index','../logger','delete\x20cron','isBetween','stringify','map','Info\x20report:\x0a%s\x0aPlease\x20see\x20the\x20attachments\x0aThis\x20is\x20an\x20automatically\x20generated\x20email\x20–\x20please\x20do\x20not\x20reply\x20to\x20it.\x0a\x0a','http','email\x20sent','active','port','cron-job-manager','sendIfEmpty'];(function(_0x34e84d,_0x6634){const _0x24cae0=function(_0x3faaae){while(--_0x3faaae){_0x34e84d['push'](_0x34e84d['shift']());}};_0x24cae0(++_0x6634);}(a851_0x6634,0x15a));const a851_0x24ca=function(_0x34e84d,_0x6634){_0x34e84d=_0x34e84d-0x0;let _0x24cae0=a851_0x6634[_0x34e84d];return _0x24cae0;};const _0x38d345=a851_0x24ca;'use strict';const fs=require('fs'),util=require(_0x38d345('0x21')),path=require(_0x38d345('0x4d')),_=require(_0x38d345('0x4b')),moment=require('moment'),CronJobManager=require(_0x38d345('0xc')),jayson=require('jayson/promise'),logger=require(_0x38d345('0x2'))(_0x38d345('0x57')),db=require(_0x38d345('0x49'))['db'],analyticCustomReportController=require(_0x38d345('0x36')),analyticDefaultReportController=require('../../api/analyticDefaultReport/analyticDefaultReport.controller'),client=jayson[_0x38d345('0x50')][_0x38d345('0x8')]({'port':0x232b}),manager=new CronJobManager();function handleSendEmail(_0x3faaae,_0x24ffe5){return function(){const _0x404384=a851_0x24ca;logger['info'](_0x404384('0x1d'),_0x3faaae[_0x404384('0x1e')]);let _0x435f13=!![];const _0x52a49d={'tls':{'rejectUnauthorized':![]}};_0x3faaae[_0x404384('0x13')][_0x404384('0x2a')]['service']?_0x52a49d[_0x404384('0x4a')]=_0x3faaae['MailAccount'][_0x404384('0x2a')][_0x404384('0x4a')]:(_0x52a49d['host']=_0x3faaae[_0x404384('0x13')][_0x404384('0x2a')][_0x404384('0x52')],_0x52a49d[_0x404384('0xb')]=_0x3faaae[_0x404384('0x13')][_0x404384('0x2a')][_0x404384('0xb')],_0x52a49d['secure']=_0x3faaae[_0x404384('0x13')]['Smtp']['secure']);_0x3faaae[_0x404384('0x13')][_0x404384('0x2a')][_0x404384('0xf')]&&(_0x52a49d[_0x404384('0x29')]={'user':_0x3faaae[_0x404384('0x13')][_0x404384('0x2a')][_0x404384('0x17')],'pass':_0x3faaae['MailAccount']['Smtp'][_0x404384('0x2f')]});const _0xcffd36={'account':_0x52a49d,'message':{'from':util['format'](_0x404384('0x58'),_0x3faaae['MailAccount'][_0x404384('0x3e')],_0x3faaae[_0x404384('0x13')][_0x404384('0x1e')]||_0x3faaae[_0x404384('0x13')][_0x404384('0x2a')][_0x404384('0x17')]),'to':_0x3faaae[_0x404384('0x1e')],'cc':_0x3faaae['cc'],'bcc':_0x3faaae['bcc'],'subject':util[_0x404384('0x12')]('Report\x20%s\x20last\x20%s\x20%s',_0x24ffe5[_0x404384('0x3e')],_0x3faaae[_0x404384('0x39')],_0x3faaae[_0x404384('0x18')])}},_0x35b92f=path['join'](__dirname,'../../files/reports'),_0x4fc3be=_0x24ffe5[_0x404384('0x46')],_0x10e80d=util[_0x404384('0x12')](_0x404384('0x42'),path[_0x404384('0x14')](_0x24ffe5[_0x404384('0x46')],path[_0x404384('0x32')](_0x24ffe5[_0x404384('0x46')])),'zip'),_0x37a6ef=path[_0x404384('0x1f')](_0x35b92f,_0x4fc3be),_0xc6ce13=path[_0x404384('0x1f')](_0x35b92f,_0x10e80d);if(fs[_0x404384('0x45')](_0x37a6ef))_0x24ffe5[_0x404384('0x4f')]=_0x404384('0x1c'),_0xcffd36[_0x404384('0x3a')][_0x404384('0x43')]=[{'filename':_0x4fc3be,'path':_0x37a6ef}],_0xcffd36[_0x404384('0x3a')][_0x404384('0x33')]=util[_0x404384('0x12')](_0x404384('0x7'),JSON[_0x404384('0x5')](_0x24ffe5,null,0x2));else fs[_0x404384('0x45')](_0xc6ce13)?(_0x24ffe5[_0x404384('0x4f')]=_0x404384('0x1c'),_0xcffd36[_0x404384('0x3a')]['attachments']=[{'filename':_0x10e80d,'path':_0xc6ce13}]):(_0xcffd36[_0x404384('0x3a')][_0x404384('0x33')]=_0x404384('0xe'),!_0x3faaae[_0x404384('0xd')]&&(_0x435f13=![],logger['info'](_0x404384('0x4c'))));if(_0x435f13)return client[_0x404384('0x47')](_0x404384('0x16'),_0xcffd36)[_0x404384('0x27')](function(_0x3b7dd9){const _0x4446cf=_0x404384;if(_0x3b7dd9[_0x4446cf('0x38')])return logger[_0x4446cf('0x38')](_0x4446cf('0x51'),JSON[_0x4446cf('0x5')](_0x3b7dd9));return logger[_0x4446cf('0x11')](_0x4446cf('0x9'));})[_0x404384('0x26')](function(_0x597fb3){const _0x39898e=_0x404384;return logger['error'](_0x39898e('0x51'),JSON[_0x39898e('0x5')](_0x597fb3));});};}function handleError(){return function(_0x15601b){const _0x2d7bb8=a851_0x24ca;return logger[_0x2d7bb8('0x38')](JSON['stringify'](_0x15601b));};}function handleResult(_0x2103df){return function(_0xa94584){const _0x1bda10=a851_0x24ca;logger['info']('data',JSON[_0x1bda10('0x5')](_0xa94584)),_0x2103df['MailAccount']&&_0x2103df[_0x1bda10('0x13')][_0x1bda10('0x2a')]&&!_[_0x1bda10('0x28')](_0x2103df[_0x1bda10('0x1e')])&&setTimeout(handleSendEmail(_0x2103df,_0xa94584),0x3c*0x3e8);};}function handleJob(_0xec62f6){return function(){const _0x3f981a=a851_0x24ca;try{if(_[_0x3f981a('0x28')](_0xec62f6[_0x3f981a('0x39')]))return logger[_0x3f981a('0x11')](_0x3f981a('0x22'));if(_['isNil'](_0xec62f6[_0x3f981a('0x18')]))return logger[_0x3f981a('0x11')](_0x3f981a('0x48'));const _0x1275b0={'startDate':moment()['subtract'](_0xec62f6[_0x3f981a('0x39')],_0xec62f6[_0x3f981a('0x18')])[_0x3f981a('0x12')](_0x3f981a('0x2d')),'endDate':moment()[_0x3f981a('0x12')](_0x3f981a('0x2d')),'type':_0x3f981a('0x3f'),'output':_0xec62f6[_0x3f981a('0x44')],'name':_0xec62f6[_0x3f981a('0x3e')]};if(!_[_0x3f981a('0x28')](_0xec62f6['DefaultReportId']))return logger[_0x3f981a('0x11')]('exec\x20defaul\x20report\x20id:%s',_0xec62f6['DefaultReportId']),analyticDefaultReportController['runReport']({'id':_0xec62f6['DefaultReportId']},_0x1275b0)['then'](handleResult(_0xec62f6))[_0x3f981a('0x26')](handleError());if(!_[_0x3f981a('0x28')](_0xec62f6[_0x3f981a('0x2b')]))return logger[_0x3f981a('0x11')](_0x3f981a('0x59'),_0xec62f6[_0x3f981a('0x2b')]),analyticCustomReportController[_0x3f981a('0x23')]({'id':_0xec62f6[_0x3f981a('0x2b')]},_0x1275b0)[_0x3f981a('0x27')](handleResult(_0xec62f6))['catch'](handleError());}catch(_0x707b5f){logger[_0x3f981a('0x38')](JSON[_0x3f981a('0x5')](_0x707b5f));}return logger[_0x3f981a('0x11')](_0x3f981a('0x55'));};}function getJobs(_0x2fe6e9){const _0x583786=_0x38d345,_0x165ff8={};return _0x2fe6e9&&(_0x165ff8['id']=_0x2fe6e9),db[_0x583786('0x41')][_0x583786('0x3c')]({'where':_0x165ff8,'include':[{'model':db[_0x583786('0x13')],'attributes':['id',_0x583786('0x3e'),_0x583786('0x1e')],'include':[{'model':db[_0x583786('0x2c')],'as':_0x583786('0x2a')}]}]})[_0x583786('0x27')](function(_0x14f64d){const _0x4f94a6=_0x583786,_0x392eb0=_[_0x4f94a6('0x19')](manager[_0x4f94a6('0x25')]),_0x1dc57e=_[_0x4f94a6('0x6')](_0x14f64d,function(_0x5f4cc3){return _0x5f4cc3['id']['toString']();}),_0x2f614e=_[_0x4f94a6('0x10')](_0x14f64d,function(_0x4a8568){const _0x50022d=_0x4f94a6;return _0x4a8568['id'][_0x50022d('0x1a')]();}),_0x164019=_0x2fe6e9?_0x1dc57e:_[_0x4f94a6('0x0')](_0x1dc57e,_0x392eb0),_0x314ef3=_[_0x4f94a6('0x40')](_0x1dc57e,_0x392eb0),_0x372779=_[_0x4f94a6('0x0')](_0x392eb0,_0x1dc57e);let _0x18ec94,_0x986870;for(_0x18ec94=0x0;_0x18ec94<_0x372779[_0x4f94a6('0x53')]&&!_0x2fe6e9;_0x18ec94+=0x1){_0x986870=_0x372779[_0x18ec94][_0x4f94a6('0x1a')](),manager['exists'](_0x986870)&&(manager[_0x4f94a6('0x35')](_0x986870),manager[_0x4f94a6('0x20')](_0x986870),logger[_0x4f94a6('0x11')](_0x4f94a6('0x3'),_0x986870));}logger[_0x4f94a6('0x11')](_0x4f94a6('0x15'),JSON[_0x4f94a6('0x5')](_0x164019));for(_0x18ec94=0x0;_0x18ec94<_0x164019['length'];_0x18ec94+=0x1){_0x986870=_0x164019[_0x18ec94]['toString'](),logger[_0x4f94a6('0x11')](_0x4f94a6('0x1'),_0x986870);if(_0x2fe6e9)logger[_0x4f94a6('0x11')]('my\x20id',_0x2fe6e9),logger['info'](JSON[_0x4f94a6('0x5')](_0x2f614e[_0x986870])),Promise[_0x4f94a6('0x34')]()[_0x4f94a6('0x27')](handleJob(_0x2f614e[_0x986870])),logger[_0x4f94a6('0x11')](_0x4f94a6('0x1b'),_0x2f614e[_0x986870][_0x4f94a6('0x3e')],_0x2f614e[_0x986870][_0x4f94a6('0x31')]);else{if(_0x2f614e[_0x986870][_0x4f94a6('0x31')]&&_0x2f614e[_0x986870][_0x4f94a6('0xa')]&&moment()['isBetween'](_0x2f614e[_0x986870][_0x4f94a6('0x56')],_0x2f614e[_0x986870][_0x4f94a6('0x54')]))manager[_0x4f94a6('0x3d')](_0x986870,_0x2f614e[_0x986870]['cron'],handleJob(_0x2f614e[_0x986870])),manager[_0x4f94a6('0x2e')](_0x986870),logger['info']('add\x20cron',_0x2f614e[_0x986870][_0x4f94a6('0x3e')],_0x2f614e[_0x986870][_0x4f94a6('0x31')]);else manager['exists'](_0x986870)&&(manager[_0x4f94a6('0x35')](_0x986870),manager[_0x4f94a6('0x20')](_0x986870),logger[_0x4f94a6('0x11')](_0x4f94a6('0x4e'),_0x2f614e[_0x986870][_0x4f94a6('0x3e')],_0x2f614e[_0x986870][_0x4f94a6('0x31')]));}}for(_0x18ec94=0x0,_0x986870;_0x18ec94<_0x314ef3['length']&&!_0x2fe6e9;_0x18ec94+=0x1){_0x986870=_0x314ef3[_0x18ec94][_0x4f94a6('0x1a')](),manager[_0x4f94a6('0x3b')](_0x986870)&&(_0x2f614e[_0x986870][_0x4f94a6('0x31')]&&_0x2f614e[_0x986870][_0x4f94a6('0xa')]&&moment()[_0x4f94a6('0x4')](_0x2f614e[_0x986870][_0x4f94a6('0x56')],_0x2f614e[_0x986870][_0x4f94a6('0x54')])?(manager[_0x4f94a6('0x37')](_0x986870,_0x2f614e[_0x986870][_0x4f94a6('0x31')],handleJob(_0x2f614e[_0x986870])),logger[_0x4f94a6('0x11')](_0x4f94a6('0x24'),_0x2f614e[_0x986870][_0x4f94a6('0x3e')],_0x2f614e[_0x986870][_0x4f94a6('0x31')])):(manager['stop'](_0x986870),manager[_0x4f94a6('0x20')](_0x986870),logger[_0x4f94a6('0x11')](_0x4f94a6('0x4e'),_0x2f614e[_0x986870]['name'],_0x2f614e[_0x986870][_0x4f94a6('0x31')])));}})[_0x583786('0x26')](function(_0x5e94df){const _0x5422b3=_0x583786;logger[_0x5422b3('0x38')](JSON[_0x5422b3('0x5')](_0x5e94df));});}exports[_0x38d345('0x30')]=function(_0x8e0484){return getJobs(_0x8e0484);},exports[_0x38d345('0x2e')]=function(){return setInterval(function(){return getJobs();},0x3c*0x3e8),getJobs();}; \ No newline at end of file diff --git a/server/config/schedule/transcribe.js b/server/config/schedule/transcribe.js index c42f4da..483ebcb 100644 --- a/server/config/schedule/transcribe.js +++ b/server/config/schedule/transcribe.js @@ -1 +1 @@ -const a852_0xe729=['[RECORDING:%d]\x20Transcript\x20Job\x20status\x20not\x20managed','tempSentiment','Cloud\x20Provider\x20not\x20configured','[RECORDING:%d]\x20Sentiment\x20Analysis\x20available','Settings\x20not\x20available','detectSentiment','Sentiment\x20Analysis\x20not\x20configured','request-promise-native','name','[RECORDING:%d]\x20Get\x20status\x20for\x20transcript\x20job\x20(%s)','TranscriptionJobStatus','Comprehend','util','Sentiment','[RECORDING:%d]\x20Transcript\x20downloaded','VoiceRecording','Positive','transcribeAccountId','Sentiment\x20Analysis\x20not\x20requested','[RECORDING:%d]\x20Requesting\x20sentiment\x20analysis','TranscriptionJob','forEach','Transcript\x20not\x20available','info','[RECORDING:%d]\x20Error\x20running\x20Transcribe\x20&\x20Sentiment\x20Analysis','language','transcribeName','findAll','fileText','Setting','Cloud\x20Provider\x20not\x20available','sequelize','data1','sentiment','transcribeRegion','sentimentAccountId','substring','resolve','getTranscriptionJob','data2','catch','transcripts','aws-sdk','sentimentRegion','TranscribeService','FailureReason','format','[RECORDING:%d]\x20Get\x20transcript','FAILED','results','SentimentScore','Transcribe\x20not\x20configured','CloudProvider','inspect','SequelizeValidationError','findOne','update','../../config/logger','[RECORDING:%d]\x20Voice\x20Recording\x20entry\x20updated','push','transcribe','length','then','TranscriptFileUri','No\x20transcribe\x20job\x20to\x20check','bucket','Neutral','transcript','Mixed','Transcript','../../mysqldb','IN_PROGRESS'];(function(_0x2e1b98,_0xe7290f){const _0x3a24e5=function(_0x31ffad){while(--_0x31ffad){_0x2e1b98['push'](_0x2e1b98['shift']());}};_0x3a24e5(++_0xe7290f);}(a852_0xe729,0x19e));const a852_0x3a24=function(_0x2e1b98,_0xe7290f){_0x2e1b98=_0x2e1b98-0x0;let _0x3a24e5=a852_0xe729[_0x2e1b98];return _0x3a24e5;};const _0x331363=a852_0x3a24,AWS=require(_0x331363('0x3c')),rp=require(_0x331363('0x19')),util=require(_0x331363('0x1e')),db=require(_0x331363('0x10'))['db'],{ValidationError}=require(_0x331363('0x31')),logger=require(_0x331363('0x3'))(_0x331363('0x6'));function getTranscriptionJob(_0x31ffad,_0x47921d,_0x446471,_0x363779){return new Promise(function(_0x538ed9,_0x580e07){const _0x408e16=a852_0x3a24,_0x9f396d=new AWS[(_0x408e16('0x3e'))]({'accessKeyId':_0x47921d,'secretAccessKey':_0x31ffad,'region':_0x446471});_0x9f396d[_0x408e16('0x38')]({'TranscriptionJobName':_0x363779},function(_0x3ed6c6,_0x5b79c6){return _0x3ed6c6?_0x580e07(_0x3ed6c6):_0x538ed9(_0x5b79c6);});});}function sentiment(_0x5b2eb8,_0x4f9d70,_0x58076b,_0x245986,_0x3ee370){return new Promise(function(_0x2d477b,_0x4329f6){const _0x4c67c8=a852_0x3a24,_0x237ee2=new AWS[(_0x4c67c8('0x1d'))]({'accessKeyId':_0x4f9d70,'secretAccessKey':_0x5b2eb8,'region':_0x58076b});_0x237ee2[_0x4c67c8('0x17')]({'Text':_0x245986,'LanguageCode':_0x3ee370[_0x4c67c8('0x36')](0x0,0x2)},function(_0x512b0c,_0x3e6deb){return _0x512b0c?_0x4329f6(_0x512b0c):_0x2d477b(_0x3e6deb);});});}function checkTranscribeJob(_0x18c993,_0x2fce26,_0x392ade){let _0x489fe5;return new Promise(function(_0x64de5a){const _0x211cf6=a852_0x3a24;return logger[_0x211cf6('0x29')](util[_0x211cf6('0x40')](_0x211cf6('0x1b'),_0x18c993['id'],_0x18c993['transcribeName'])),getTranscriptionJob(_0x392ade[_0x211cf6('0x32')],_0x392ade[_0x211cf6('0x39')],_0x2fce26[_0x211cf6('0x34')],_0x18c993[_0x211cf6('0x2c')])[_0x211cf6('0x8')](function(_0x27fb73){const _0x5d1ed8=_0x211cf6;logger[_0x5d1ed8('0x29')](util[_0x5d1ed8('0x40')]('[RECORDING:%d]\x20Status\x20of\x20transcript\x20job\x20(%s):\x20%s',_0x18c993['id'],_0x18c993[_0x5d1ed8('0x2c')],_0x27fb73[_0x5d1ed8('0x26')][_0x5d1ed8('0x1c')]));if(!_0x18c993[_0x5d1ed8('0x2e')])switch(_0x27fb73[_0x5d1ed8('0x26')][_0x5d1ed8('0x1c')]){case'COMPLETED':{const _0x2898c7={'transcribeStatus':_0x27fb73['TranscriptionJob'][_0x5d1ed8('0x1c')],'fileUri':_0x27fb73['TranscriptionJob'][_0x5d1ed8('0xf')][_0x5d1ed8('0x9')]};return logger[_0x5d1ed8('0x29')](util['format'](_0x5d1ed8('0x41'),_0x18c993['id'])),rp({'uri':_0x27fb73[_0x5d1ed8('0x26')][_0x5d1ed8('0xf')][_0x5d1ed8('0x9')],'json':!![]})['then'](function(_0x469b49){const _0x272061=_0x5d1ed8;logger[_0x272061('0x29')](util['format'](_0x272061('0x20'),_0x18c993['id']));if(_0x469b49&&_0x469b49[_0x272061('0x43')]&&_0x469b49['results'][_0x272061('0x3b')]&&_0x469b49['results']['transcripts']['length']){_0x2898c7[_0x272061('0x2e')]='';for(let _0x38121b=0x0;_0x38121b<_0x469b49['results']['transcripts'][_0x272061('0x7')];_0x38121b++){_0x2898c7[_0x272061('0x2e')]+=_0x469b49[_0x272061('0x43')][_0x272061('0x3b')][_0x38121b][_0x272061('0xd')]+'';}}return _0x18c993[_0x272061('0x2')](_0x2898c7);})['then'](function(){const _0x577e0b=_0x5d1ed8;logger['info'](util[_0x577e0b('0x40')](_0x577e0b('0x4'),_0x18c993['id']));if(!_0x18c993[_0x577e0b('0x13')])throw new ValidationError(_0x577e0b('0x24'));if(!_0x2fce26[_0x577e0b('0x33')]||!_0x2fce26['sentimentAccountId']||!_0x2fce26['sentimentRegion']||!_0x2fce26['language']||!_0x2fce26[_0x577e0b('0xb')])throw new ValidationError('Sentiment\x20Analysis\x20not\x20configured');if(!_0x2898c7[_0x577e0b('0x2e')])throw new Error(_0x577e0b('0x28'));return _0x2fce26[_0x577e0b('0x35')]===_0x392ade['id']?_0x392ade:db[_0x577e0b('0x46')][_0x577e0b('0x1')]({'where':{'id':_0x2fce26[_0x577e0b('0x35')]}});})[_0x5d1ed8('0x8')](function(_0x20a2ce){const _0x3f468a=_0x5d1ed8;if(!_0x20a2ce)throw new ValidationError('Cloud\x20Provider\x20not\x20available');if(!_0x20a2ce[_0x3f468a('0x32')]||!_0x20a2ce['data2'])throw new ValidationError(_0x3f468a('0x14'));return _0x489fe5=_0x20a2ce,logger[_0x3f468a('0x29')](util[_0x3f468a('0x40')](_0x3f468a('0x25'),_0x18c993['id'])),sentiment(_0x489fe5['data1'],_0x489fe5[_0x3f468a('0x39')],_0x2fce26[_0x3f468a('0x3d')],_0x2898c7['fileText'],_0x2fce26[_0x3f468a('0x2b')]);})[_0x5d1ed8('0x8')](function(_0x4ca608){const _0x23864b=_0x5d1ed8;return logger[_0x23864b('0x29')](util[_0x23864b('0x40')](_0x23864b('0x15'),_0x18c993['id'])),_0x18c993[_0x23864b('0x2')]({'sentiment':_0x4ca608[_0x23864b('0x1f')],'sPositive':_0x4ca608[_0x23864b('0x44')][_0x23864b('0x22')],'sNegative':_0x4ca608[_0x23864b('0x44')]['Negative'],'sMixed':_0x4ca608[_0x23864b('0x44')][_0x23864b('0xe')],'sNeutral':_0x4ca608[_0x23864b('0x44')]['Neutral']});})[_0x5d1ed8('0x8')](function(){const _0x37a967=_0x5d1ed8;logger[_0x37a967('0x29')](util[_0x37a967('0x40')]('[RECORDING:%d]\x20Voice\x20Recording\x20entry\x20updated',_0x18c993['id'])),_0x64de5a();});}case _0x5d1ed8('0x42'):return _0x18c993[_0x5d1ed8('0x2')]({'transcribeStatus':_0x5d1ed8('0x42'),'failureReason':_0x27fb73[_0x5d1ed8('0x26')][_0x5d1ed8('0x3f')]})[_0x5d1ed8('0x8')](function(){const _0x426bae=_0x5d1ed8;logger['info'](util[_0x426bae('0x40')](_0x426bae('0x4'),_0x18c993['id'])),_0x64de5a();});default:logger[_0x5d1ed8('0x29')](util[_0x5d1ed8('0x40')](_0x5d1ed8('0x12'),_0x18c993['id']));break;}else return Promise[_0x5d1ed8('0x37')]()[_0x5d1ed8('0x8')](function(){const _0x49f898=_0x5d1ed8;if(!_0x18c993[_0x49f898('0x13')])throw new ValidationError(_0x49f898('0x24'));if(!_0x2fce26['sentiment']||!_0x2fce26[_0x49f898('0x35')]||!_0x2fce26[_0x49f898('0x3d')]||!_0x2fce26[_0x49f898('0x2b')]||!_0x2fce26['bucket'])throw new ValidationError(_0x49f898('0x18'));if(!_0x18c993[_0x49f898('0x2e')])throw new Error(_0x49f898('0x28'));return _0x2fce26[_0x49f898('0x35')]===_0x392ade['id']?_0x392ade:db[_0x49f898('0x46')][_0x49f898('0x1')]({'where':{'id':_0x2fce26['sentimentAccountId']}});})[_0x5d1ed8('0x8')](function(_0x49503e){const _0x3e89cd=_0x5d1ed8;if(!_0x49503e)throw new ValidationError(_0x3e89cd('0x30'));if(!_0x49503e[_0x3e89cd('0x32')]||!_0x49503e[_0x3e89cd('0x39')])throw new ValidationError(_0x3e89cd('0x14'));return _0x489fe5=_0x49503e,logger[_0x3e89cd('0x29')](util['format'](_0x3e89cd('0x25'),_0x18c993['id'])),sentiment(_0x489fe5[_0x3e89cd('0x32')],_0x489fe5[_0x3e89cd('0x39')],_0x2fce26[_0x3e89cd('0x3d')],_0x18c993[_0x3e89cd('0x2e')],_0x2fce26[_0x3e89cd('0x2b')]);})[_0x5d1ed8('0x8')](function(_0x3c24ed){const _0x24eab4=_0x5d1ed8;return logger[_0x24eab4('0x29')](util[_0x24eab4('0x40')](_0x24eab4('0x15'),_0x18c993['id'])),_0x18c993[_0x24eab4('0x2')]({'sentiment':_0x3c24ed[_0x24eab4('0x1f')],'sPositive':_0x3c24ed['SentimentScore'][_0x24eab4('0x22')],'sNegative':_0x3c24ed[_0x24eab4('0x44')]['Negative'],'sMixed':_0x3c24ed[_0x24eab4('0x44')][_0x24eab4('0xe')],'sNeutral':_0x3c24ed[_0x24eab4('0x44')][_0x24eab4('0xc')],'transcribeStatus':'COMPLETED'});})[_0x5d1ed8('0x8')](function(){const _0x8abd6a=_0x5d1ed8;logger[_0x8abd6a('0x29')](util['format'](_0x8abd6a('0x4'),_0x18c993['id'])),_0x64de5a();});})['catch'](function(_0x479596){const _0x4f4a85=_0x211cf6;_0x479596&&((!_0x479596[_0x4f4a85('0x1a')]||_0x479596['name']!=='SequelizeValidationError')&&logger['error'](util['format'](_0x4f4a85('0x2a'),_0x18c993['id']),util[_0x4f4a85('0x47')](_0x479596,{'showHidden':![],'depth':null}))),_0x64de5a();});});}function checkTranscribe(){const _0x802e0c=_0x331363;let _0x17c013,_0xc3cc37,_0x4e475a;return db[_0x802e0c('0x21')][_0x802e0c('0x2d')]({'where':{'transcribeStatus':_0x802e0c('0x11')}})[_0x802e0c('0x8')](function(_0x225f46){const _0x41b91b=_0x802e0c;if(!_0x225f46||!_0x225f46[_0x41b91b('0x7')])throw new ValidationError(_0x41b91b('0xa'));return _0x17c013=_0x225f46,db[_0x41b91b('0x2f')][_0x41b91b('0x1')]({'where':{'id':0x1}});})['then'](function(_0x1f92ca){const _0x490f94=_0x802e0c;if(!_0x1f92ca)throw new ValidationError(_0x490f94('0x16'));_0xc3cc37=_0x1f92ca;if(!_0xc3cc37[_0x490f94('0x6')]||!_0xc3cc37['transcribeAccountId']||!_0xc3cc37[_0x490f94('0x34')]||!_0xc3cc37[_0x490f94('0x2b')]||!_0xc3cc37[_0x490f94('0xb')])throw new ValidationError(_0x490f94('0x45'));return db[_0x490f94('0x46')][_0x490f94('0x1')]({'where':{'id':_0xc3cc37[_0x490f94('0x23')]}});})[_0x802e0c('0x8')](function(_0x3968bf){const _0x36566d=_0x802e0c;if(!_0x3968bf)throw new ValidationError(_0x36566d('0x30'));if(!_0x3968bf['data1']||!_0x3968bf['data2'])throw new ValidationError(_0x36566d('0x14'));_0x4e475a=_0x3968bf;const _0x6c37=[];return _0x17c013[_0x36566d('0x27')](function(_0x4b834e){const _0x1b1cd=_0x36566d;_0x6c37[_0x1b1cd('0x5')](checkTranscribeJob(_0x4b834e,_0xc3cc37,_0x4e475a));}),Promise['all'](_0x6c37);})[_0x802e0c('0x3a')](function(_0x48f743){const _0x3abcc2=_0x802e0c;_0x48f743&&((!_0x48f743['name']||_0x48f743[_0x3abcc2('0x1a')]!==_0x3abcc2('0x0'))&&logger['error'](util['inspect'](_0x48f743,{'showHidden':![],'depth':null})));});}exports['start']=function(){return setInterval(function(){return checkTranscribe();},0x3c*0x3e8),checkTranscribe();}; \ No newline at end of file +const a852_0x18ca=['[RECORDING:%d]\x20Get\x20transcript','TranscriptionJobStatus','data2','TranscriptionJob','update','util','findOne','transcribeName','inspect','data1','[RECORDING:%d]\x20Transcript\x20Job\x20status\x20not\x20managed','push','Comprehend','tempSentiment','VoiceRecording','sentimentAccountId','transcribe','bucket','Neutral','transcript','request-promise-native','../../mysqldb','then','[RECORDING:%d]\x20Requesting\x20sentiment\x20analysis','transcribeRegion','FAILED','Transcribe\x20not\x20configured','Cloud\x20Provider\x20not\x20available','transcribeAccountId','aws-sdk','sentiment','getTranscriptionJob','Negative','Sentiment\x20Analysis\x20not\x20configured','[RECORDING:%d]\x20Get\x20status\x20for\x20transcript\x20job\x20(%s)','[RECORDING:%d]\x20Sentiment\x20Analysis\x20available','../../config/logger','name','Mixed','detectSentiment','CloudProvider','results','SequelizeValidationError','Settings\x20not\x20available','findAll','resolve','all','[RECORDING:%d]\x20Error\x20running\x20Transcribe\x20&\x20Sentiment\x20Analysis','[RECORDING:%d]\x20Voice\x20Recording\x20entry\x20updated','start','substring','TranscriptFileUri','[RECORDING:%d]\x20Transcript\x20downloaded','IN_PROGRESS','sentimentRegion','Transcript','info','length','[RECORDING:%d]\x20Status\x20of\x20transcript\x20job\x20(%s):\x20%s','format','Transcript\x20not\x20available','COMPLETED','fileText','Positive','language','catch','Sentiment','Cloud\x20Provider\x20not\x20configured','transcripts','error','SentimentScore','Sentiment\x20Analysis\x20not\x20requested'];(function(_0x224339,_0x18cae2){const _0x176e72=function(_0x382b88){while(--_0x382b88){_0x224339['push'](_0x224339['shift']());}};_0x176e72(++_0x18cae2);}(a852_0x18ca,0x1dd));const a852_0x176e=function(_0x224339,_0x18cae2){_0x224339=_0x224339-0x0;let _0x176e72=a852_0x18ca[_0x224339];return _0x176e72;};const _0x43d0e4=a852_0x176e,AWS=require(_0x43d0e4('0x38')),rp=require(_0x43d0e4('0x2f')),util=require(_0x43d0e4('0x20')),db=require(_0x43d0e4('0x30'))['db'],{ValidationError}=require('sequelize'),logger=require(_0x43d0e4('0x3f'))(_0x43d0e4('0x2b'));function getTranscriptionJob(_0x382b88,_0x24be92,_0x558f54,_0x441155){return new Promise(function(_0x527f6a,_0x11de8f){const _0x5558fa=a852_0x176e,_0x1446f4=new AWS['TranscribeService']({'accessKeyId':_0x24be92,'secretAccessKey':_0x382b88,'region':_0x558f54});_0x1446f4[_0x5558fa('0x3a')]({'TranscriptionJobName':_0x441155},function(_0x491e96,_0x49d67f){return _0x491e96?_0x11de8f(_0x491e96):_0x527f6a(_0x49d67f);});});}function sentiment(_0x858484,_0x1733af,_0x3ae33e,_0x525c12,_0x4269b6){return new Promise(function(_0x13847d,_0x492f18){const _0x4b0194=a852_0x176e,_0x4a8bfd=new AWS[(_0x4b0194('0x27'))]({'accessKeyId':_0x1733af,'secretAccessKey':_0x858484,'region':_0x3ae33e});_0x4a8bfd[_0x4b0194('0x42')]({'Text':_0x525c12,'LanguageCode':_0x4269b6[_0x4b0194('0x5')](0x0,0x2)},function(_0x5c4356,_0x595a6d){return _0x5c4356?_0x492f18(_0x5c4356):_0x13847d(_0x595a6d);});});}function checkTranscribeJob(_0x1bccfe,_0x654d35,_0x2c20e6){let _0x4c7a04;return new Promise(function(_0x1815b1){const _0x3593e3=a852_0x176e;return logger[_0x3593e3('0xb')](util[_0x3593e3('0xe')](_0x3593e3('0x3d'),_0x1bccfe['id'],_0x1bccfe[_0x3593e3('0x22')])),getTranscriptionJob(_0x2c20e6['data1'],_0x2c20e6['data2'],_0x654d35[_0x3593e3('0x33')],_0x1bccfe['transcribeName'])['then'](function(_0x4db1df){const _0x5dfa15=_0x3593e3;logger[_0x5dfa15('0xb')](util[_0x5dfa15('0xe')](_0x5dfa15('0xd'),_0x1bccfe['id'],_0x1bccfe[_0x5dfa15('0x22')],_0x4db1df[_0x5dfa15('0x1e')][_0x5dfa15('0x1c')]));if(!_0x1bccfe[_0x5dfa15('0x11')])switch(_0x4db1df[_0x5dfa15('0x1e')]['TranscriptionJobStatus']){case _0x5dfa15('0x10'):{const _0x3a7a4c={'transcribeStatus':_0x4db1df['TranscriptionJob'][_0x5dfa15('0x1c')],'fileUri':_0x4db1df['TranscriptionJob'][_0x5dfa15('0xa')]['TranscriptFileUri']};return logger['info'](util[_0x5dfa15('0xe')](_0x5dfa15('0x1b'),_0x1bccfe['id'])),rp({'uri':_0x4db1df[_0x5dfa15('0x1e')][_0x5dfa15('0xa')][_0x5dfa15('0x6')],'json':!![]})[_0x5dfa15('0x31')](function(_0xdb796d){const _0x2b2d72=_0x5dfa15;logger['info'](util[_0x2b2d72('0xe')](_0x2b2d72('0x7'),_0x1bccfe['id']));if(_0xdb796d&&_0xdb796d['results']&&_0xdb796d[_0x2b2d72('0x44')][_0x2b2d72('0x17')]&&_0xdb796d[_0x2b2d72('0x44')][_0x2b2d72('0x17')]['length']){_0x3a7a4c[_0x2b2d72('0x11')]='';for(let _0x204a40=0x0;_0x204a40<_0xdb796d[_0x2b2d72('0x44')]['transcripts'][_0x2b2d72('0xc')];_0x204a40++){_0x3a7a4c[_0x2b2d72('0x11')]+=_0xdb796d[_0x2b2d72('0x44')][_0x2b2d72('0x17')][_0x204a40][_0x2b2d72('0x2e')]+'';}}return _0x1bccfe[_0x2b2d72('0x1f')](_0x3a7a4c);})[_0x5dfa15('0x31')](function(){const _0x3ec91b=_0x5dfa15;logger[_0x3ec91b('0xb')](util[_0x3ec91b('0xe')](_0x3ec91b('0x3'),_0x1bccfe['id']));if(!_0x1bccfe['tempSentiment'])throw new ValidationError(_0x3ec91b('0x1a'));if(!_0x654d35[_0x3ec91b('0x39')]||!_0x654d35[_0x3ec91b('0x2a')]||!_0x654d35[_0x3ec91b('0x9')]||!_0x654d35['language']||!_0x654d35[_0x3ec91b('0x2c')])throw new ValidationError(_0x3ec91b('0x3c'));if(!_0x3a7a4c[_0x3ec91b('0x11')])throw new Error(_0x3ec91b('0xf'));return _0x654d35[_0x3ec91b('0x2a')]===_0x2c20e6['id']?_0x2c20e6:db[_0x3ec91b('0x43')]['findOne']({'where':{'id':_0x654d35['sentimentAccountId']}});})[_0x5dfa15('0x31')](function(_0x655ab){const _0x3ddbad=_0x5dfa15;if(!_0x655ab)throw new ValidationError(_0x3ddbad('0x36'));if(!_0x655ab['data1']||!_0x655ab['data2'])throw new ValidationError(_0x3ddbad('0x16'));return _0x4c7a04=_0x655ab,logger[_0x3ddbad('0xb')](util[_0x3ddbad('0xe')]('[RECORDING:%d]\x20Requesting\x20sentiment\x20analysis',_0x1bccfe['id'])),sentiment(_0x4c7a04[_0x3ddbad('0x24')],_0x4c7a04[_0x3ddbad('0x1d')],_0x654d35['sentimentRegion'],_0x3a7a4c['fileText'],_0x654d35[_0x3ddbad('0x13')]);})[_0x5dfa15('0x31')](function(_0x446eee){const _0xd01f7e=_0x5dfa15;return logger[_0xd01f7e('0xb')](util[_0xd01f7e('0xe')](_0xd01f7e('0x3e'),_0x1bccfe['id'])),_0x1bccfe[_0xd01f7e('0x1f')]({'sentiment':_0x446eee[_0xd01f7e('0x15')],'sPositive':_0x446eee[_0xd01f7e('0x19')][_0xd01f7e('0x12')],'sNegative':_0x446eee['SentimentScore'][_0xd01f7e('0x3b')],'sMixed':_0x446eee[_0xd01f7e('0x19')][_0xd01f7e('0x41')],'sNeutral':_0x446eee[_0xd01f7e('0x19')][_0xd01f7e('0x2d')]});})[_0x5dfa15('0x31')](function(){const _0x369326=_0x5dfa15;logger[_0x369326('0xb')](util[_0x369326('0xe')](_0x369326('0x3'),_0x1bccfe['id'])),_0x1815b1();});}case'FAILED':return _0x1bccfe[_0x5dfa15('0x1f')]({'transcribeStatus':_0x5dfa15('0x34'),'failureReason':_0x4db1df[_0x5dfa15('0x1e')]['FailureReason']})[_0x5dfa15('0x31')](function(){const _0x599c8f=_0x5dfa15;logger['info'](util[_0x599c8f('0xe')](_0x599c8f('0x3'),_0x1bccfe['id'])),_0x1815b1();});default:logger[_0x5dfa15('0xb')](util['format'](_0x5dfa15('0x25'),_0x1bccfe['id']));break;}else return Promise[_0x5dfa15('0x0')]()[_0x5dfa15('0x31')](function(){const _0x45d370=_0x5dfa15;if(!_0x1bccfe[_0x45d370('0x28')])throw new ValidationError('Sentiment\x20Analysis\x20not\x20requested');if(!_0x654d35[_0x45d370('0x39')]||!_0x654d35['sentimentAccountId']||!_0x654d35['sentimentRegion']||!_0x654d35[_0x45d370('0x13')]||!_0x654d35[_0x45d370('0x2c')])throw new ValidationError('Sentiment\x20Analysis\x20not\x20configured');if(!_0x1bccfe[_0x45d370('0x11')])throw new Error('Transcript\x20not\x20available');return _0x654d35[_0x45d370('0x2a')]===_0x2c20e6['id']?_0x2c20e6:db[_0x45d370('0x43')]['findOne']({'where':{'id':_0x654d35['sentimentAccountId']}});})[_0x5dfa15('0x31')](function(_0x12c2bb){const _0x230902=_0x5dfa15;if(!_0x12c2bb)throw new ValidationError(_0x230902('0x36'));if(!_0x12c2bb[_0x230902('0x24')]||!_0x12c2bb[_0x230902('0x1d')])throw new ValidationError(_0x230902('0x16'));return _0x4c7a04=_0x12c2bb,logger['info'](util[_0x230902('0xe')](_0x230902('0x32'),_0x1bccfe['id'])),sentiment(_0x4c7a04[_0x230902('0x24')],_0x4c7a04[_0x230902('0x1d')],_0x654d35[_0x230902('0x9')],_0x1bccfe['fileText'],_0x654d35[_0x230902('0x13')]);})[_0x5dfa15('0x31')](function(_0x3309b7){const _0x33261c=_0x5dfa15;return logger[_0x33261c('0xb')](util[_0x33261c('0xe')]('[RECORDING:%d]\x20Sentiment\x20Analysis\x20available',_0x1bccfe['id'])),_0x1bccfe[_0x33261c('0x1f')]({'sentiment':_0x3309b7[_0x33261c('0x15')],'sPositive':_0x3309b7[_0x33261c('0x19')][_0x33261c('0x12')],'sNegative':_0x3309b7[_0x33261c('0x19')][_0x33261c('0x3b')],'sMixed':_0x3309b7[_0x33261c('0x19')][_0x33261c('0x41')],'sNeutral':_0x3309b7[_0x33261c('0x19')][_0x33261c('0x2d')],'transcribeStatus':_0x33261c('0x10')});})['then'](function(){const _0x48e920=_0x5dfa15;logger[_0x48e920('0xb')](util[_0x48e920('0xe')](_0x48e920('0x3'),_0x1bccfe['id'])),_0x1815b1();});})['catch'](function(_0x50cd55){const _0x20df51=_0x3593e3;_0x50cd55&&((!_0x50cd55[_0x20df51('0x40')]||_0x50cd55['name']!==_0x20df51('0x45'))&&logger[_0x20df51('0x18')](util[_0x20df51('0xe')](_0x20df51('0x2'),_0x1bccfe['id']),util['inspect'](_0x50cd55,{'showHidden':![],'depth':null}))),_0x1815b1();});});}function checkTranscribe(){const _0x1ff895=_0x43d0e4;let _0x415195,_0xac7987,_0x27605e;return db[_0x1ff895('0x29')][_0x1ff895('0x47')]({'where':{'transcribeStatus':_0x1ff895('0x8')}})[_0x1ff895('0x31')](function(_0x44a4f7){const _0x276f17=_0x1ff895;if(!_0x44a4f7||!_0x44a4f7[_0x276f17('0xc')])throw new ValidationError('No\x20transcribe\x20job\x20to\x20check');return _0x415195=_0x44a4f7,db['Setting'][_0x276f17('0x21')]({'where':{'id':0x1}});})[_0x1ff895('0x31')](function(_0x42027a){const _0x57957a=_0x1ff895;if(!_0x42027a)throw new ValidationError(_0x57957a('0x46'));_0xac7987=_0x42027a;if(!_0xac7987[_0x57957a('0x2b')]||!_0xac7987[_0x57957a('0x37')]||!_0xac7987[_0x57957a('0x33')]||!_0xac7987[_0x57957a('0x13')]||!_0xac7987[_0x57957a('0x2c')])throw new ValidationError(_0x57957a('0x35'));return db['CloudProvider'][_0x57957a('0x21')]({'where':{'id':_0xac7987[_0x57957a('0x37')]}});})[_0x1ff895('0x31')](function(_0x37cf6c){const _0x2087cc=_0x1ff895;if(!_0x37cf6c)throw new ValidationError(_0x2087cc('0x36'));if(!_0x37cf6c[_0x2087cc('0x24')]||!_0x37cf6c[_0x2087cc('0x1d')])throw new ValidationError(_0x2087cc('0x16'));_0x27605e=_0x37cf6c;const _0x2c67be=[];return _0x415195['forEach'](function(_0x2540d3){const _0x396900=_0x2087cc;_0x2c67be[_0x396900('0x26')](checkTranscribeJob(_0x2540d3,_0xac7987,_0x27605e));}),Promise[_0x2087cc('0x1')](_0x2c67be);})[_0x1ff895('0x14')](function(_0x194d7d){const _0x150263=_0x1ff895;_0x194d7d&&((!_0x194d7d[_0x150263('0x40')]||_0x194d7d['name']!=='SequelizeValidationError')&&logger[_0x150263('0x18')](util[_0x150263('0x23')](_0x194d7d,{'showHidden':![],'depth':null})));});}exports[_0x43d0e4('0x4')]=function(){return setInterval(function(){return checkTranscribe();},0x3c*0x3e8),checkTranscribe();}; \ No newline at end of file diff --git a/server/config/seedContact.js b/server/config/seedContact.js index 39d68a8..6a4500d 100644 --- a/server/config/seedContact.js +++ b/server/config/seedContact.js @@ -1 +1 @@ -const a853_0x500b=['contacts1','innocenzo.biondo','hopper2','log','push','finished\x20populating','contacts2','../mysqldb','@xcally.com','CmContact','CmHopper','then','Biondo','now','bulkCreate'];(function(_0x4e1237,_0x500b7){const _0x5f0c94=function(_0x21f5c8){while(--_0x21f5c8){_0x4e1237['push'](_0x4e1237['shift']());}};_0x5f0c94(++_0x500b7);}(a853_0x500b,0x1dd));const a853_0x5f0c=function(_0x4e1237,_0x500b7){_0x4e1237=_0x4e1237-0x0;let _0x5f0c94=a853_0x500b[_0x4e1237];return _0x5f0c94;};const _0x2dcae5=a853_0x5f0c;'use strict';const db=require(_0x2dcae5('0xa'))['db'],contacts=[],hopper=[],contacts2=[],hopper2=[];for(let i=0x1;i<=0x4b0;i+=0x1){contacts[_0x2dcae5('0x7')]({'id':i,'firstName':'Innocenzo'+i,'lastName':_0x2dcae5('0x0')+i,'phone':0xf879fb460+i,'email':_0x2dcae5('0x4')+i+_0x2dcae5('0xb')});}for(let i=0x1;i<=0x4b0;i+=0x1){hopper['push']({'id':i,'active':![],'scheduledat':Date[_0x2dcae5('0x1')](),'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0,'ContactId':i,'ListId':0x1,'UserId':0x1,'VoiceQueueId':0x3fd,'createdAt':Date['now'](),'updatedAt':Date['now']()});}for(let i=0x4b1;i<=0x960;i+=0x1){contacts2[_0x2dcae5('0x7')]({'id':i,'firstName':'Innocenzo'+i,'lastName':_0x2dcae5('0x0')+i,'phone':0xf879fb460+i,'email':_0x2dcae5('0x4')+i+_0x2dcae5('0xb')});}for(let i=0x4b1;i<=0x960;i+=0x1){hopper2[_0x2dcae5('0x7')]({'id':i,'active':![],'scheduledat':Date[_0x2dcae5('0x1')](),'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0,'ContactId':i,'ListId':0x1,'UserId':0x1,'VoiceQueueId':0x3fd,'createdAt':Date[_0x2dcae5('0x1')](),'updatedAt':Date[_0x2dcae5('0x1')]()});}db[_0x2dcae5('0xc')]['destroy']({'where':{}})[_0x2dcae5('0xe')](function(){const _0x428926=_0x2dcae5;return db['CmContact'][_0x428926('0x2')](contacts);})[_0x2dcae5('0xe')](function(){const _0x1f973d=_0x2dcae5;return console[_0x1f973d('0x6')](_0x1f973d('0x8'),_0x1f973d('0x3')),db[_0x1f973d('0xd')]['destroy']({'where':{}});})['then'](function(){const _0x5f2080=_0x2dcae5;return db[_0x5f2080('0xd')][_0x5f2080('0x2')](hopper);})[_0x2dcae5('0xe')](function(){const _0x17a439=_0x2dcae5;return console[_0x17a439('0x6')](_0x17a439('0x8'),'hopper1'),db[_0x17a439('0xc')][_0x17a439('0x2')](contacts2);})[_0x2dcae5('0xe')](function(){const _0x27ef2e=_0x2dcae5;return console[_0x27ef2e('0x6')](_0x27ef2e('0x8'),_0x27ef2e('0x9')),db[_0x27ef2e('0xd')][_0x27ef2e('0x2')](hopper2);})['then'](function(){const _0x2ee822=_0x2dcae5;console[_0x2ee822('0x6')](_0x2ee822('0x8'),_0x2ee822('0x5'));})['catch'](function(_0x21f5c8){const _0x334703=_0x2dcae5;console[_0x334703('0x6')](_0x21f5c8);}); \ No newline at end of file +const a853_0x5629=['log','finished\x20populating','bulkCreate','../mysqldb','Biondo','now','then','hopper1','CmHopper','CmContact','contacts1','push','destroy','Innocenzo','innocenzo.biondo','@xcally.com','contacts2','catch'];(function(_0x4e189f,_0x562973){const _0x42a090=function(_0x110056){while(--_0x110056){_0x4e189f['push'](_0x4e189f['shift']());}};_0x42a090(++_0x562973);}(a853_0x5629,0x1e4));const a853_0x42a0=function(_0x4e189f,_0x562973){_0x4e189f=_0x4e189f-0x0;let _0x42a090=a853_0x5629[_0x4e189f];return _0x42a090;};const _0x42bf5c=a853_0x42a0;'use strict';const db=require(_0x42bf5c('0x5'))['db'],contacts=[],hopper=[],contacts2=[],hopper2=[];for(let i=0x1;i<=0x4b0;i+=0x1){contacts[_0x42bf5c('0xd')]({'id':i,'firstName':_0x42bf5c('0xf')+i,'lastName':'Biondo'+i,'phone':0xf879fb460+i,'email':_0x42bf5c('0x10')+i+_0x42bf5c('0x11')});}for(let i=0x1;i<=0x4b0;i+=0x1){hopper[_0x42bf5c('0xd')]({'id':i,'active':![],'scheduledat':Date[_0x42bf5c('0x7')](),'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0,'ContactId':i,'ListId':0x1,'UserId':0x1,'VoiceQueueId':0x3fd,'createdAt':Date[_0x42bf5c('0x7')](),'updatedAt':Date[_0x42bf5c('0x7')]()});}for(let i=0x4b1;i<=0x960;i+=0x1){contacts2[_0x42bf5c('0xd')]({'id':i,'firstName':_0x42bf5c('0xf')+i,'lastName':_0x42bf5c('0x6')+i,'phone':0xf879fb460+i,'email':_0x42bf5c('0x10')+i+_0x42bf5c('0x11')});}for(let i=0x4b1;i<=0x960;i+=0x1){hopper2[_0x42bf5c('0xd')]({'id':i,'active':![],'scheduledat':Date[_0x42bf5c('0x7')](),'countbusyretry':0x0,'countcongestionretry':0x0,'countnoanswerretry':0x0,'ContactId':i,'ListId':0x1,'UserId':0x1,'VoiceQueueId':0x3fd,'createdAt':Date['now'](),'updatedAt':Date[_0x42bf5c('0x7')]()});}db[_0x42bf5c('0xb')][_0x42bf5c('0xe')]({'where':{}})[_0x42bf5c('0x8')](function(){const _0x308fc2=_0x42bf5c;return db[_0x308fc2('0xb')][_0x308fc2('0x4')](contacts);})[_0x42bf5c('0x8')](function(){const _0x1fbdd1=_0x42bf5c;return console['log'](_0x1fbdd1('0x3'),_0x1fbdd1('0xc')),db[_0x1fbdd1('0xa')][_0x1fbdd1('0xe')]({'where':{}});})[_0x42bf5c('0x8')](function(){const _0x4da008=_0x42bf5c;return db[_0x4da008('0xa')][_0x4da008('0x4')](hopper);})[_0x42bf5c('0x8')](function(){const _0x5439b8=_0x42bf5c;return console[_0x5439b8('0x2')](_0x5439b8('0x3'),_0x5439b8('0x9')),db[_0x5439b8('0xb')][_0x5439b8('0x4')](contacts2);})[_0x42bf5c('0x8')](function(){const _0x5bc448=_0x42bf5c;return console[_0x5bc448('0x2')]('finished\x20populating',_0x5bc448('0x0')),db[_0x5bc448('0xa')][_0x5bc448('0x4')](hopper2);})[_0x42bf5c('0x8')](function(){const _0x423dff=_0x42bf5c;console['log'](_0x423dff('0x3'),'hopper2');})[_0x42bf5c('0x1')](function(_0x110056){const _0x2e12fe=_0x42bf5c;console[_0x2e12fe('0x2')](_0x110056);}); \ No newline at end of file diff --git a/server/config/seedDB/analyticReports.js b/server/config/seedDB/analyticReports.js index 3aba0dd..fd62abc 100644 --- a/server/config/seedDB/analyticReports.js +++ b/server/config/seedDB/analyticReports.js @@ -1 +1 @@ -const a854_0x2666=['default','fields','Analytic\x20Custom\x20Reports\x20have\x20been\x20created','destroy','ReportId','app','length','../../mysqldb','then','../logger','Analytic\x20Default\x20Reports\x20have\x20been\x20created','AnalyticCustomReport','createCustom','./report','catch','AnalyticFieldReport','error','motion','message','Can\x27t\x20create\x20Analytic\x20Custom\x20Report','bulkCreate','custom','DefaultReportId','Can\x27t\x20create\x20Analytic\x20Default\x20Report','info','CustomReportId','AnalyticDefaultReport'];(function(_0x3df0f4,_0x2666b4){const _0x6d1c3f=function(_0x3e9932){while(--_0x3e9932){_0x3df0f4['push'](_0x3df0f4['shift']());}};_0x6d1c3f(++_0x2666b4);}(a854_0x2666,0x145));const a854_0x6d1c=function(_0x3df0f4,_0x2666b4){_0x3df0f4=_0x3df0f4-0x0;let _0x6d1c3f=a854_0x2666[_0x3df0f4];return _0x6d1c3f;};const _0x9712f3=a854_0x6d1c;'use strict';const db=require(_0x9712f3('0x6'))['db'],logger=require(_0x9712f3('0x8'))(_0x9712f3('0x4')),report=require(_0x9712f3('0xc'));exports['createDefault']=function(){const _0xa77df2=_0x9712f3;return db[_0xa77df2('0x19')][_0xa77df2('0x2')]({'where':{}})[_0xa77df2('0x7')](function(){const _0xecdfad=_0xa77df2;return db[_0xecdfad('0x19')][_0xecdfad('0x13')](report[_0xecdfad('0x1a')](_0xecdfad('0x10')),{'ignoreDuplicates':!![],'individualHooks':!![]});})[_0xa77df2('0x7')](function(_0x3e9932){const _0x3466e4=_0xa77df2,_0x1e2c46=report[_0x3466e4('0x0')]();for(let _0x1c1360=0x0;_0x1c1360<_0x3e9932[_0x3466e4('0x5')];_0x1c1360+=0x1){if(_0x1e2c46[_0x3e9932[_0x1c1360]['id']]){for(let _0x1ea959=0x0;_0x1ea959<_0x1e2c46[_0x3e9932[_0x1c1360]['id']][_0x3466e4('0x5')];_0x1ea959+=0x1){_0x1e2c46[_0x3e9932[_0x1c1360]['id']][_0x1ea959][_0x3466e4('0x15')]=_0x1e2c46[_0x3e9932[_0x1c1360]['id']][_0x1ea959][_0x3466e4('0x3')],delete _0x1e2c46[_0x3e9932[_0x1c1360]['id']][_0x1ea959][_0x3466e4('0x3')];}db[_0x3466e4('0xe')][_0x3466e4('0x13')](_0x1e2c46[_0x3e9932[_0x1c1360]['id']]);}}})[_0xa77df2('0x7')](function(){const _0x1a310b=_0xa77df2;logger[_0x1a310b('0x17')](_0x1a310b('0x9'));})[_0xa77df2('0xd')](function(_0x512f1c){const _0x2d0cf1=_0xa77df2;logger[_0x2d0cf1('0xf')](_0x2d0cf1('0x16'),_0x512f1c[_0x2d0cf1('0x11')]);});},exports[_0x9712f3('0xb')]=function(){const _0x15a928=_0x9712f3;return db[_0x15a928('0xa')][_0x15a928('0x13')](report[_0x15a928('0x1a')](_0x15a928('0x14')),{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x15a928('0x7')](function(_0x4c5eca){const _0x4f6b95=_0x15a928,_0x8b0b0d=report[_0x4f6b95('0x0')]();for(let _0x24f8b8=0x0;_0x24f8b8<_0x4c5eca[_0x4f6b95('0x5')];_0x24f8b8+=0x1){if(_0x8b0b0d[_0x4c5eca[_0x24f8b8]['id']]){for(let _0x59857f=0x0;_0x59857f<_0x8b0b0d[_0x4c5eca[_0x24f8b8]['id']]['length'];_0x59857f+=0x1){_0x8b0b0d[_0x4c5eca[_0x24f8b8]['id']][_0x59857f][_0x4f6b95('0x18')]=_0x8b0b0d[_0x4c5eca[_0x24f8b8]['id']][_0x59857f][_0x4f6b95('0x3')],delete _0x8b0b0d[_0x4c5eca[_0x24f8b8]['id']][_0x59857f][_0x4f6b95('0x3')];}db[_0x4f6b95('0xe')][_0x4f6b95('0x13')](_0x8b0b0d[_0x4c5eca[_0x24f8b8]['id']]);}}})['then'](function(){const _0x576f57=_0x15a928;logger['info'](_0x576f57('0x1'));})[_0x15a928('0xd')](function(){const _0x2441dd=_0x15a928;logger[_0x2441dd('0xf')](_0x2441dd('0x12'));});}; \ No newline at end of file +const a854_0x262f=['motion','Analytic\x20Custom\x20Reports\x20have\x20been\x20created','../../mysqldb','message','../logger','info','error','length','then','bulkCreate','default','AnalyticCustomReport','custom','DefaultReportId','catch','fields','Can\x27t\x20create\x20Analytic\x20Custom\x20Report','./report','AnalyticDefaultReport','ReportId','Can\x27t\x20create\x20Analytic\x20Default\x20Report','destroy','AnalyticFieldReport'];(function(_0x5ee9c5,_0x262f14){const _0x18ddbc=function(_0x44fc98){while(--_0x44fc98){_0x5ee9c5['push'](_0x5ee9c5['shift']());}};_0x18ddbc(++_0x262f14);}(a854_0x262f,0x129));const a854_0x18dd=function(_0x5ee9c5,_0x262f14){_0x5ee9c5=_0x5ee9c5-0x0;let _0x18ddbc=a854_0x262f[_0x5ee9c5];return _0x18ddbc;};const _0x515483=a854_0x18dd;'use strict';const db=require(_0x515483('0x4'))['db'],logger=require(_0x515483('0x6'))('app'),report=require(_0x515483('0x13'));exports['createDefault']=function(){const _0x587688=_0x515483;return db[_0x587688('0x14')][_0x587688('0x0')]({'where':{}})[_0x587688('0xa')](function(){const _0xfcc635=_0x587688;return db[_0xfcc635('0x14')][_0xfcc635('0xb')](report[_0xfcc635('0xc')](_0xfcc635('0x2')),{'ignoreDuplicates':!![],'individualHooks':!![]});})[_0x587688('0xa')](function(_0x44fc98){const _0x42a580=_0x587688,_0x98be43=report['fields']();for(let _0x45af00=0x0;_0x45af00<_0x44fc98[_0x42a580('0x9')];_0x45af00+=0x1){if(_0x98be43[_0x44fc98[_0x45af00]['id']]){for(let _0x75fe9d=0x0;_0x75fe9d<_0x98be43[_0x44fc98[_0x45af00]['id']][_0x42a580('0x9')];_0x75fe9d+=0x1){_0x98be43[_0x44fc98[_0x45af00]['id']][_0x75fe9d][_0x42a580('0xf')]=_0x98be43[_0x44fc98[_0x45af00]['id']][_0x75fe9d][_0x42a580('0x15')],delete _0x98be43[_0x44fc98[_0x45af00]['id']][_0x75fe9d][_0x42a580('0x15')];}db[_0x42a580('0x1')][_0x42a580('0xb')](_0x98be43[_0x44fc98[_0x45af00]['id']]);}}})[_0x587688('0xa')](function(){const _0x4344d2=_0x587688;logger[_0x4344d2('0x7')]('Analytic\x20Default\x20Reports\x20have\x20been\x20created');})['catch'](function(_0xcbd947){const _0x1faff5=_0x587688;logger[_0x1faff5('0x8')](_0x1faff5('0x16'),_0xcbd947[_0x1faff5('0x5')]);});},exports['createCustom']=function(){const _0x11f073=_0x515483;return db[_0x11f073('0xd')][_0x11f073('0xb')](report[_0x11f073('0xc')](_0x11f073('0xe')),{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(_0x425203){const _0x460ec9=_0x11f073,_0x5d41e8=report[_0x460ec9('0x11')]();for(let _0x4e5666=0x0;_0x4e5666<_0x425203[_0x460ec9('0x9')];_0x4e5666+=0x1){if(_0x5d41e8[_0x425203[_0x4e5666]['id']]){for(let _0x4b64b3=0x0;_0x4b64b3<_0x5d41e8[_0x425203[_0x4e5666]['id']][_0x460ec9('0x9')];_0x4b64b3+=0x1){_0x5d41e8[_0x425203[_0x4e5666]['id']][_0x4b64b3]['CustomReportId']=_0x5d41e8[_0x425203[_0x4e5666]['id']][_0x4b64b3][_0x460ec9('0x15')],delete _0x5d41e8[_0x425203[_0x4e5666]['id']][_0x4b64b3]['ReportId'];}db[_0x460ec9('0x1')][_0x460ec9('0xb')](_0x5d41e8[_0x425203[_0x4e5666]['id']]);}}})[_0x11f073('0xa')](function(){const _0x343ed6=_0x11f073;logger[_0x343ed6('0x7')](_0x343ed6('0x3'));})[_0x11f073('0x10')](function(){const _0x3d414f=_0x11f073;logger[_0x3d414f('0x8')](_0x3d414f('0x12'));});}; \ No newline at end of file diff --git a/server/config/seedDB/analyticTreeReports.js b/server/config/seedDB/analyticTreeReports.js index 3157b21..8ed4a4b 100644 --- a/server/config/seedDB/analyticTreeReports.js +++ b/server/config/seedDB/analyticTreeReports.js @@ -1 +1 @@ -const a855_0x1179=['update','createCustom','AnalyticTreeReport','findOrCreate','Can\x27t\x20create\x20Analytic\x20Tree\x20Custom\x20Report','./tree','custom','stringify','motion','bulkCreate','Can\x27t\x20create\x20Analytic\x20Tree\x20Default\x20Report','../logger','error','Analytic\x20Tree\x20Custom\x20Reports\x20have\x20been\x20created','Analytic\x20Tree\x20Default\x20Reports\x20have\x20been\x20created','../../mysqldb','catch','info','then'];(function(_0x141664,_0x11792d){const _0x456fc9=function(_0x1c8262){while(--_0x1c8262){_0x141664['push'](_0x141664['shift']());}};_0x456fc9(++_0x11792d);}(a855_0x1179,0xf5));const a855_0x456f=function(_0x141664,_0x11792d){_0x141664=_0x141664-0x0;let _0x456fc9=a855_0x1179[_0x141664];return _0x456fc9;};const _0x4442f8=a855_0x456f;'use strict';const db=require(_0x4442f8('0x11'))['db'],logger=require(_0x4442f8('0xd'))('app'),tree=require(_0x4442f8('0x7'));exports['createDefault']=function(){const _0x32c994=_0x4442f8;return db[_0x32c994('0x4')][_0x32c994('0x5')]({'where':{'id':0x1},'defaults':{'id':0x1,'tree':JSON[_0x32c994('0x9')](tree[_0x32c994('0xa')])}})['then'](function([_0x1c8262,_0x29ebb4]){const _0x5bf83c=_0x32c994;if(!_0x29ebb4)return _0x1c8262[_0x5bf83c('0x2')]({'tree':JSON['stringify'](tree[_0x5bf83c('0xa')])});return _0x1c8262;})[_0x32c994('0x1')](function(){const _0x8d2e0c=_0x32c994;logger[_0x8d2e0c('0x0')](_0x8d2e0c('0x10'));})[_0x32c994('0x12')](function(){const _0x356a7a=_0x32c994;logger[_0x356a7a('0xe')](_0x356a7a('0xc'));});},exports[_0x4442f8('0x3')]=function(){const _0x57b830=_0x4442f8;return db['AnalyticTreeReport'][_0x57b830('0xb')]([{'id':0x2,'tree':JSON[_0x57b830('0x9')](tree[_0x57b830('0x8')])}],{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(){const _0x18bb32=_0x57b830;logger[_0x18bb32('0x0')](_0x18bb32('0xf'));})[_0x57b830('0x12')](function(){const _0x4782f0=_0x57b830;logger['error'](_0x4782f0('0x6'));});}; \ No newline at end of file +const a855_0x3eed=['motion','then','app','createCustom','update','../../mysqldb','catch','Can\x27t\x20create\x20Analytic\x20Tree\x20Custom\x20Report','info','../logger','AnalyticTreeReport','Can\x27t\x20create\x20Analytic\x20Tree\x20Default\x20Report','custom','error','createDefault','Analytic\x20Tree\x20Custom\x20Reports\x20have\x20been\x20created','stringify','Analytic\x20Tree\x20Default\x20Reports\x20have\x20been\x20created','findOrCreate','bulkCreate'];(function(_0x26efbf,_0x3eedd9){const _0x1b49e3=function(_0x136fad){while(--_0x136fad){_0x26efbf['push'](_0x26efbf['shift']());}};_0x1b49e3(++_0x3eedd9);}(a855_0x3eed,0xf2));const a855_0x1b49=function(_0x26efbf,_0x3eedd9){_0x26efbf=_0x26efbf-0x0;let _0x1b49e3=a855_0x3eed[_0x26efbf];return _0x1b49e3;};const _0x65c24c=a855_0x1b49;'use strict';const db=require(_0x65c24c('0x3'))['db'],logger=require(_0x65c24c('0x7'))(_0x65c24c('0x0')),tree=require('./tree');exports[_0x65c24c('0xc')]=function(){const _0x114024=_0x65c24c;return db['AnalyticTreeReport'][_0x114024('0x10')]({'where':{'id':0x1},'defaults':{'id':0x1,'tree':JSON['stringify'](tree[_0x114024('0x12')])}})[_0x114024('0x13')](function([_0x136fad,_0x2db91f]){const _0x5ba8af=_0x114024;if(!_0x2db91f)return _0x136fad[_0x5ba8af('0x2')]({'tree':JSON[_0x5ba8af('0xe')](tree['motion'])});return _0x136fad;})[_0x114024('0x13')](function(){const _0x42a7ca=_0x114024;logger['info'](_0x42a7ca('0xf'));})[_0x114024('0x4')](function(){const _0x3d7d81=_0x114024;logger[_0x3d7d81('0xb')](_0x3d7d81('0x9'));});},exports[_0x65c24c('0x1')]=function(){const _0x21e27b=_0x65c24c;return db[_0x21e27b('0x8')][_0x21e27b('0x11')]([{'id':0x2,'tree':JSON[_0x21e27b('0xe')](tree[_0x21e27b('0xa')])}],{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x21e27b('0x13')](function(){const _0x2b3743=_0x21e27b;logger[_0x2b3743('0x6')](_0x2b3743('0xd'));})['catch'](function(){const _0x4217b6=_0x21e27b;logger[_0x4217b6('0xb')](_0x4217b6('0x5'));});}; \ No newline at end of file diff --git a/server/config/seedDB/chanspy.js b/server/config/seedDB/chanspy.js index c39acf9..783f301 100644 --- a/server/config/seedDB/chanspy.js +++ b/server/config/seedDB/chanspy.js @@ -1 +1 @@ -const a856_0x27cd=['OnlyListen','../logger','bulkCreate','spy2','error','create','The\x20supervisor\x20can\x20just\x20listen\x20to\x20the\x20phone\x20call','spy4','Listen&TalkBoth','info','then','The\x20supervisor\x20can\x20listen\x20and\x20talk\x20to\x20the\x20agent.\x20The\x20customer\x20will\x20not\x20listen\x20to\x20the\x20supervisor\x20voice','The\x20supervisor\x20can\x20only\x20listen\x20the\x20agent\x20channel\x20(neither\x20the\x20agent\x20nor\x20the\x20customer\x20will\x20listen\x20to\x20the\x20supervisor\x20voice)','catch','../../mysqldb','VoiceChanSpy','OnlyListenBoth','The\x20supervisor\x20can\x20listen\x20and\x20talk\x20both\x20to\x20the\x20agent\x20and\x20to\x20the\x20customer,\x20like\x20a\x20pure\x203\x20way\x20conference\x20room','spy1'];(function(_0x551319,_0x27cdef){const _0x6ad50=function(_0x21562f){while(--_0x21562f){_0x551319['push'](_0x551319['shift']());}};_0x6ad50(++_0x27cdef);}(a856_0x27cd,0x174));const a856_0x6ad5=function(_0x551319,_0x27cdef){_0x551319=_0x551319-0x0;let _0x6ad50=a856_0x27cd[_0x551319];return _0x6ad50;};const _0xf6e8ff=a856_0x6ad5;'use strict';const db=require(_0xf6e8ff('0x3'))['db'],logger=require(_0xf6e8ff('0x9'))('app'),chanSpy=[{'id':0x1,'name':'Listen&TalkOne','prefix':_0xf6e8ff('0x7'),'options':['b','w','E','S'],'description':_0xf6e8ff('0x0')},{'id':0x2,'name':_0xf6e8ff('0x8'),'prefix':_0xf6e8ff('0xb'),'options':['b','o','E','S'],'description':_0xf6e8ff('0x1')},{'id':0x3,'name':_0xf6e8ff('0x10'),'prefix':'spy3','options':['B','w','E','S'],'description':_0xf6e8ff('0x6')},{'id':0x4,'name':_0xf6e8ff('0x5'),'prefix':_0xf6e8ff('0xf'),'options':['B','o','E','S'],'description':_0xf6e8ff('0xe')}];exports[_0xf6e8ff('0xd')]=function(){const _0x172567=_0xf6e8ff;return db[_0x172567('0x4')][_0x172567('0xa')](chanSpy,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x172567('0x12')](function(){const _0x350345=_0x172567;logger[_0x350345('0x11')]('ChanSpy\x20have\x20been\x20created');})[_0x172567('0x2')](function(){const _0x183067=_0x172567;logger[_0x183067('0xc')]('Can\x27t\x20create\x20ChanSpy');});}; \ No newline at end of file +const a856_0x2173=['The\x20supervisor\x20can\x20listen\x20and\x20talk\x20to\x20the\x20agent.\x20The\x20customer\x20will\x20not\x20listen\x20to\x20the\x20supervisor\x20voice','spy1','spy2','ChanSpy\x20have\x20been\x20created','OnlyListenBoth','error','bulkCreate','The\x20supervisor\x20can\x20listen\x20and\x20talk\x20both\x20to\x20the\x20agent\x20and\x20to\x20the\x20customer,\x20like\x20a\x20pure\x203\x20way\x20conference\x20room','app','catch','../../mysqldb','spy3','Listen&TalkBoth','OnlyListen','../logger'];(function(_0x5634b5,_0x217342){const _0x1a2a21=function(_0x35e3b0){while(--_0x35e3b0){_0x5634b5['push'](_0x5634b5['shift']());}};_0x1a2a21(++_0x217342);}(a856_0x2173,0x18f));const a856_0x1a2a=function(_0x5634b5,_0x217342){_0x5634b5=_0x5634b5-0x0;let _0x1a2a21=a856_0x2173[_0x5634b5];return _0x1a2a21;};const _0x3d4724=a856_0x1a2a;'use strict';const db=require(_0x3d4724('0x1'))['db'],logger=require(_0x3d4724('0x5'))(_0x3d4724('0xe')),chanSpy=[{'id':0x1,'name':'Listen&TalkOne','prefix':_0x3d4724('0x7'),'options':['b','w','E','S'],'description':_0x3d4724('0x6')},{'id':0x2,'name':_0x3d4724('0x4'),'prefix':_0x3d4724('0x8'),'options':['b','o','E','S'],'description':'The\x20supervisor\x20can\x20only\x20listen\x20the\x20agent\x20channel\x20(neither\x20the\x20agent\x20nor\x20the\x20customer\x20will\x20listen\x20to\x20the\x20supervisor\x20voice)'},{'id':0x3,'name':_0x3d4724('0x3'),'prefix':_0x3d4724('0x2'),'options':['B','w','E','S'],'description':_0x3d4724('0xd')},{'id':0x4,'name':_0x3d4724('0xa'),'prefix':'spy4','options':['B','o','E','S'],'description':'The\x20supervisor\x20can\x20just\x20listen\x20to\x20the\x20phone\x20call'}];exports['create']=function(){const _0x3b5e81=_0x3d4724;return db['VoiceChanSpy'][_0x3b5e81('0xc')](chanSpy,{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(){const _0xb444cd=_0x3b5e81;logger['info'](_0xb444cd('0x9'));})[_0x3b5e81('0x0')](function(){const _0x2a7117=_0x3b5e81;logger[_0x2a7117('0xb')]('Can\x27t\x20create\x20ChanSpy');});}; \ No newline at end of file diff --git a/server/config/seedDB/companies.js b/server/config/seedDB/companies.js index 4802c4d..e59f83d 100644 --- a/server/config/seedDB/companies.js +++ b/server/config/seedDB/companies.js @@ -1 +1 @@ -const a857_0x3ac8=['www.xcallymotion.com','create','+3901119886500','app','09668910012','company\x20auto\x20generated','info@xcally.com','error','+390110960070','catch','xcally.com','../logger','Turin','info','Can\x27t\x20create\x20Companies','Xenialab','CmCompany','10128','../../mysqldb'];(function(_0x569b3c,_0x3ac834){const _0x4a1284=function(_0x2daf48){while(--_0x2daf48){_0x569b3c['push'](_0x569b3c['shift']());}};_0x4a1284(++_0x3ac834);}(a857_0x3ac8,0xc8));const a857_0x4a12=function(_0x569b3c,_0x3ac834){_0x569b3c=_0x569b3c-0x0;let _0x4a1284=a857_0x3ac8[_0x569b3c];return _0x4a1284;};const _0x19788f=a857_0x4a12;'use strict';const db=require(_0x19788f('0x8'))['db'],logger=require(_0x19788f('0x1'))(_0x19788f('0xc')),companies=[{'id':0x1,'name':_0x19788f('0x5'),'type':'srl','vat':_0x19788f('0xd'),'phone':_0x19788f('0xb'),'fax':_0x19788f('0x11'),'website':_0x19788f('0x9'),'email':_0x19788f('0xf'),'emailDomain':_0x19788f('0x0'),'street':'Corso\x20Vittorio\x20Emanuele\x20II,\x20111','postalCode':_0x19788f('0x7'),'city':_0x19788f('0x2'),'country':'Italy','description':_0x19788f('0xe')}];exports[_0x19788f('0xa')]=function(){const _0x19f8be=_0x19788f;return db[_0x19f8be('0x6')]['bulkCreate'](companies,{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(){const _0x5f4d3e=_0x19f8be;logger[_0x5f4d3e('0x3')]('Companies\x20have\x20been\x20created');})[_0x19f8be('0x12')](function(){const _0x133d23=_0x19f8be;logger[_0x133d23('0x10')](_0x133d23('0x4'));});}; \ No newline at end of file +const a857_0x2176=['app','Corso\x20Vittorio\x20Emanuele\x20II,\x20111','../../mysqldb','srl','Companies\x20have\x20been\x20created','../logger','then','Can\x27t\x20create\x20Companies','Turin','info@xcally.com','Xenialab','www.xcallymotion.com','error','create','+390110960070'];(function(_0x2bfe4a,_0x2176d7){const _0x42309e=function(_0x1270e4){while(--_0x1270e4){_0x2bfe4a['push'](_0x2bfe4a['shift']());}};_0x42309e(++_0x2176d7);}(a857_0x2176,0x1c9));const a857_0x4230=function(_0x2bfe4a,_0x2176d7){_0x2bfe4a=_0x2bfe4a-0x0;let _0x42309e=a857_0x2176[_0x2bfe4a];return _0x42309e;};const _0x13fb3f=a857_0x4230;'use strict';const db=require(_0x13fb3f('0xa'))['db'],logger=require(_0x13fb3f('0xd'))(_0x13fb3f('0x8')),companies=[{'id':0x1,'name':_0x13fb3f('0x3'),'type':_0x13fb3f('0xb'),'vat':'09668910012','phone':'+3901119886500','fax':_0x13fb3f('0x7'),'website':_0x13fb3f('0x4'),'email':_0x13fb3f('0x2'),'emailDomain':'xcally.com','street':_0x13fb3f('0x9'),'postalCode':'10128','city':_0x13fb3f('0x1'),'country':'Italy','description':'company\x20auto\x20generated'}];exports[_0x13fb3f('0x6')]=function(){const _0x11d606=_0x13fb3f;return db['CmCompany']['bulkCreate'](companies,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x11d606('0xe')](function(){const _0x201f89=_0x11d606;logger['info'](_0x201f89('0xc'));})['catch'](function(){const _0x315fdb=_0x11d606;logger[_0x315fdb('0x5')](_0x315fdb('0x0'));});}; \ No newline at end of file diff --git a/server/config/seedDB/contacts.js b/server/config/seedDB/contacts.js index 12892fe..fe7d4f6 100644 --- a/server/config/seedDB/contacts.js +++ b/server/config/seedDB/contacts.js @@ -1 +1 @@ -const a858_0x2673=['Andrea','getNames','andrea.bianco@xcally.com','random','error','456','create','info','Giuseppe','catch','contact\x20auto\x20generated','bulkCreate','Mario','then','length','Contacts\x20have\x20been\x20created','789','CmContact','Verdi','Can\x27t\x20create\x20Contacts','../logger','123','floor','Bianco','../../mysqldb','Rossi','./tags'];(function(_0x3081da,_0x2673c5){const _0x9c0cf1=function(_0x41828e){while(--_0x41828e){_0x3081da['push'](_0x3081da['shift']());}};_0x9c0cf1(++_0x2673c5);}(a858_0x2673,0x17c));const a858_0x9c0c=function(_0x3081da,_0x2673c5){_0x3081da=_0x3081da-0x0;let _0x9c0cf1=a858_0x2673[_0x3081da];return _0x9c0cf1;};const _0x5963e4=a858_0x9c0c;'use strict';const db=require(_0x5963e4('0x16'))['db'],logger=require(_0x5963e4('0x12'))('app'),tags=require(_0x5963e4('0x18'))[_0x5963e4('0x1a')](),getRandomTag=function(){const _0x14edaf=_0x5963e4,_0x41828e=tags[_0x14edaf('0xc')]-0x1;return[tags[Math[_0x14edaf('0x14')](Math[_0x14edaf('0x1')]()*_0x41828e)+0x1]];},contacts=[{'id':0x1,'firstName':_0x5963e4('0xa'),'lastName':_0x5963e4('0x17'),'phone':_0x5963e4('0x13'),'email':'mario.rossi@xcally.com','ListId':0x1,'CompanyId':0x1,'tags':getRandomTag(),'description':_0x5963e4('0x8')},{'id':0x2,'firstName':_0x5963e4('0x6'),'lastName':_0x5963e4('0x10'),'phone':_0x5963e4('0x3'),'email':'giuseppe.verdi@xcally.com','ListId':0x1,'CompanyId':0x1,'tags':getRandomTag(),'description':_0x5963e4('0x8')},{'id':0x3,'firstName':_0x5963e4('0x19'),'lastName':_0x5963e4('0x15'),'phone':_0x5963e4('0xe'),'email':_0x5963e4('0x0'),'ListId':0x2,'CompanyId':0x1,'tags':getRandomTag(),'description':_0x5963e4('0x8')}];exports[_0x5963e4('0x4')]=function(){const _0x2b8fcc=_0x5963e4;return db[_0x2b8fcc('0xf')][_0x2b8fcc('0x9')](contacts,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x2b8fcc('0xb')](function(){const _0x1889e3=_0x2b8fcc;logger[_0x1889e3('0x5')](_0x1889e3('0xd'));})[_0x2b8fcc('0x7')](function(){const _0x9e1501=_0x2b8fcc;logger[_0x9e1501('0x2')](_0x9e1501('0x11'));});}; \ No newline at end of file +const a858_0x3083=['123','Bianco','random','Verdi','CmContact','Andrea','getNames','andrea.bianco@xcally.com','../logger','app','then','456','Contacts\x20have\x20been\x20created','Can\x27t\x20create\x20Contacts','error','catch','Rossi','mario.rossi@xcally.com','789','contact\x20auto\x20generated','length','Mario','create'];(function(_0x5db40b,_0x308395){const _0xaa54ac=function(_0x4d1536){while(--_0x4d1536){_0x5db40b['push'](_0x5db40b['shift']());}};_0xaa54ac(++_0x308395);}(a858_0x3083,0xbb));const a858_0xaa54=function(_0x5db40b,_0x308395){_0x5db40b=_0x5db40b-0x0;let _0xaa54ac=a858_0x3083[_0x5db40b];return _0xaa54ac;};const _0x479a19=a858_0xaa54;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x479a19('0x5'))(_0x479a19('0x6')),tags=require('./tags')[_0x479a19('0x3')](),getRandomTag=function(){const _0x504a53=_0x479a19,_0x4d1536=tags[_0x504a53('0x11')]-0x1;return[tags[Math['floor'](Math[_0x504a53('0x16')]()*_0x4d1536)+0x1]];},contacts=[{'id':0x1,'firstName':_0x479a19('0x12'),'lastName':_0x479a19('0xd'),'phone':_0x479a19('0x14'),'email':_0x479a19('0xe'),'ListId':0x1,'CompanyId':0x1,'tags':getRandomTag(),'description':_0x479a19('0x10')},{'id':0x2,'firstName':'Giuseppe','lastName':_0x479a19('0x0'),'phone':_0x479a19('0x8'),'email':'giuseppe.verdi@xcally.com','ListId':0x1,'CompanyId':0x1,'tags':getRandomTag(),'description':'contact\x20auto\x20generated'},{'id':0x3,'firstName':_0x479a19('0x2'),'lastName':_0x479a19('0x15'),'phone':_0x479a19('0xf'),'email':_0x479a19('0x4'),'ListId':0x2,'CompanyId':0x1,'tags':getRandomTag(),'description':_0x479a19('0x10')}];exports[_0x479a19('0x13')]=function(){const _0x28b901=_0x479a19;return db[_0x28b901('0x1')]['bulkCreate'](contacts,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x28b901('0x7')](function(){const _0x5ae8bf=_0x28b901;logger['info'](_0x5ae8bf('0x9'));})[_0x28b901('0xc')](function(){const _0x45a0cd=_0x28b901;logger[_0x45a0cd('0xb')](_0x45a0cd('0xa'));});}; \ No newline at end of file diff --git a/server/config/seedDB/dispositions.js b/server/config/seedDB/dispositions.js index 93dcd97..9c2941f 100644 --- a/server/config/seedDB/dispositions.js +++ b/server/config/seedDB/dispositions.js @@ -1 +1 @@ -const a859_0x125a=['create','Answer\x20Machine','Special','app','../logger','Not\x20Interested','catch','bulkCreate','info','then','Sold','Interested','Fax','../../mysqldb','Disposition','Dispositions\x20have\x20been\x20created'];(function(_0x4bdb87,_0x125a2b){const _0x302145=function(_0x200e23){while(--_0x200e23){_0x4bdb87['push'](_0x4bdb87['shift']());}};_0x302145(++_0x125a2b);}(a859_0x125a,0x1a8));const a859_0x3021=function(_0x4bdb87,_0x125a2b){_0x4bdb87=_0x4bdb87-0x0;let _0x302145=a859_0x125a[_0x4bdb87];return _0x302145;};const _0x8956f3=a859_0x3021;'use strict';const db=require(_0x8956f3('0x5'))['db'],logger=require(_0x8956f3('0xc'))(_0x8956f3('0xb')),dispositions=[{'name':_0x8956f3('0x4')},{'name':_0x8956f3('0x9')},{'name':_0x8956f3('0x3')},{'name':_0x8956f3('0xd')},{'name':_0x8956f3('0x2')},{'name':_0x8956f3('0xa')}];exports[_0x8956f3('0x8')]=function(){const _0x228273=_0x8956f3;return db[_0x228273('0x6')][_0x228273('0xf')](dispositions,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x228273('0x1')](function(){const _0x157f92=_0x228273;logger[_0x157f92('0x0')](_0x157f92('0x7'));})[_0x228273('0xe')](function(){logger['error']('Can\x27t\x20create\x20Companies');});}; \ No newline at end of file +const a859_0x396b=['../logger','Interested','Answer\x20Machine','Sold','bulkCreate','create','Can\x27t\x20create\x20Companies','Special','catch','Disposition','Dispositions\x20have\x20been\x20created','info','Not\x20Interested','../../mysqldb'];(function(_0x334552,_0x396bdb){const _0x2fea3a=function(_0x1e9a52){while(--_0x1e9a52){_0x334552['push'](_0x334552['shift']());}};_0x2fea3a(++_0x396bdb);}(a859_0x396b,0xb2));const a859_0x2fea=function(_0x334552,_0x396bdb){_0x334552=_0x334552-0x0;let _0x2fea3a=a859_0x396b[_0x334552];return _0x2fea3a;};const _0x5a9df3=a859_0x2fea;'use strict';const db=require(_0x5a9df3('0x3'))['db'],logger=require(_0x5a9df3('0x4'))('app'),dispositions=[{'name':'Fax'},{'name':_0x5a9df3('0x6')},{'name':_0x5a9df3('0x5')},{'name':_0x5a9df3('0x2')},{'name':_0x5a9df3('0x7')},{'name':_0x5a9df3('0xb')}];exports[_0x5a9df3('0x9')]=function(){const _0x352c49=_0x5a9df3;return db[_0x352c49('0xd')][_0x352c49('0x8')](dispositions,{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(){const _0x2783b4=_0x352c49;logger[_0x2783b4('0x1')](_0x2783b4('0x0'));})[_0x352c49('0xc')](function(){const _0x550142=_0x352c49;logger['error'](_0x550142('0xa'));});}; \ No newline at end of file diff --git a/server/config/seedDB/index.js b/server/config/seedDB/index.js index 27c91be..de34467 100644 --- a/server/config/seedDB/index.js +++ b/server/config/seedDB/index.js @@ -1 +1 @@ -const a860_0x5c8e=['./squareProjects','stringify','Default\x20seed','./lists','../../mysqldb','./analyticReports','createDefault','./variables','app','./users','error','./pauses','./userProfiles','./analyticTreeReports','./migrations','./intervals','./dispositions','./mailSubstatuses','create','./trunks','./voiceContexts','./voiceExtensions','./sounds','createCustom','./teams','Settings\x20have\x20been\x20created','default','./voiceMusicOnHold','./contacts','findOrCreate','./tags'];(function(_0x35b73e,_0x5c8e3e){const _0x2c2f8d=function(_0x3a6d4){while(--_0x3a6d4){_0x35b73e['push'](_0x35b73e['shift']());}};_0x2c2f8d(++_0x5c8e3e);}(a860_0x5c8e,0x154));const a860_0x2c2f=function(_0x35b73e,_0x5c8e3e){_0x35b73e=_0x35b73e-0x0;let _0x2c2f8d=a860_0x5c8e[_0x35b73e];return _0x2c2f8d;};const _0x3310ef=a860_0x2c2f;'use strict';const db=require(_0x3310ef('0x5'))['db'],logger=require('../logger')(_0x3310ef('0x9'));async function defaultSeed(){const _0xf084b3=_0x3310ef;try{const [,_0x3a6d4]=await db['Setting'][_0xf084b3('0x1e')]({'where':{'id':0x1},'defaults':{'firstSetup':!![]}});_0x3a6d4?(logger['info'](_0xf084b3('0x1a')),await require('./analyticTreeReports')[_0xf084b3('0x18')](),await require('./analyticReports')[_0xf084b3('0x18')](),await require(_0xf084b3('0xf'))[_0xf084b3('0x13')](),await require(_0xf084b3('0x10'))[_0xf084b3('0x13')](),await require(_0xf084b3('0xd'))[_0xf084b3('0x13')](),await require(_0xf084b3('0xa'))['create'](),await require(_0xf084b3('0x19'))[_0xf084b3('0x13')](),await require(_0xf084b3('0x14'))[_0xf084b3('0x13')](),await require('./voiceQueues')['create'](),await require('./chanspy')[_0xf084b3('0x13')](),await require(_0xf084b3('0x1c'))[_0xf084b3('0x13')](),await require(_0xf084b3('0x8'))[_0xf084b3('0x13')](),await require(_0xf084b3('0xc'))[_0xf084b3('0x13')](),await require(_0xf084b3('0x0'))['create'](),await require('./companies')[_0xf084b3('0x13')](),await require(_0xf084b3('0x17'))[_0xf084b3('0x13')](),await require('./squareOdbc')[_0xf084b3('0x13')](),await require(_0xf084b3('0x1'))[_0xf084b3('0x13')](),await require('./jscriptyProjects')[_0xf084b3('0x13')](),await require(_0xf084b3('0x16'))[_0xf084b3('0x13')](),await require(_0xf084b3('0x12'))[_0xf084b3('0x13')](),await require(_0xf084b3('0x11'))[_0xf084b3('0x13')](),await require(_0xf084b3('0x4'))[_0xf084b3('0x13')](),await require(_0xf084b3('0x1d'))['create']()):(await require(_0xf084b3('0x15'))[_0xf084b3('0x13')](),await require(_0xf084b3('0x16'))['createAlways'](),await require('./mailAccounts')[_0xf084b3('0x13')](),await require(_0xf084b3('0xe'))[_0xf084b3('0x7')](),await require(_0xf084b3('0x6'))['createDefault']());}catch(_0x1dd85d){logger[_0xf084b3('0xb')](_0xf084b3('0x3'),JSON[_0xf084b3('0x2')](_0x1dd85d));}}exports[_0x3310ef('0x1b')]=defaultSeed; \ No newline at end of file +const a860_0x1d92=['./voiceContexts','./jscriptyProjects','./companies','Setting','./squareProjects','Default\x20seed','./mailSubstatuses','../logger','findOrCreate','createCustom','./contacts','stringify','./pauses','createDefault','./tags','create','./lists','./teams','./dispositions','Settings\x20have\x20been\x20created','./analyticTreeReports','createAlways','./voiceMusicOnHold','./mailAccounts','info','./analyticReports','./migrations','./voiceExtensions','./sounds','./chanspy','app','../../mysqldb'];(function(_0x374652,_0x1d9256){const _0x37c29c=function(_0x2374bc){while(--_0x2374bc){_0x374652['push'](_0x374652['shift']());}};_0x37c29c(++_0x1d9256);}(a860_0x1d92,0xbf));const a860_0x37c2=function(_0x374652,_0x1d9256){_0x374652=_0x374652-0x0;let _0x37c29c=a860_0x1d92[_0x374652];return _0x37c29c;};const _0x4d5ad4=a860_0x37c2;'use strict';const db=require(_0x4d5ad4('0x0'))['db'],logger=require(_0x4d5ad4('0x8'))(_0x4d5ad4('0x1f'));async function defaultSeed(){const _0x334214=_0x4d5ad4;try{const [,_0x2374bc]=await db[_0x334214('0x4')][_0x334214('0x9')]({'where':{'id':0x1},'defaults':{'firstSetup':!![]}});_0x2374bc?(logger[_0x334214('0x19')](_0x334214('0x14')),await require(_0x334214('0x15'))[_0x334214('0xa')](),await require(_0x334214('0x1a'))['createCustom'](),await require(_0x334214('0x1b'))[_0x334214('0x10')](),await require('./intervals')[_0x334214('0x10')](),await require('./userProfiles')[_0x334214('0x10')](),await require('./users')[_0x334214('0x10')](),await require(_0x334214('0x12'))[_0x334214('0x10')](),await require('./trunks')['create'](),await require('./voiceQueues')[_0x334214('0x10')](),await require(_0x334214('0x1e'))[_0x334214('0x10')](),await require(_0x334214('0x17'))[_0x334214('0x10')](),await require('./variables')[_0x334214('0x10')](),await require(_0x334214('0xd'))[_0x334214('0x10')](),await require(_0x334214('0xf'))[_0x334214('0x10')](),await require(_0x334214('0x3'))['create'](),await require(_0x334214('0x1d'))[_0x334214('0x10')](),await require('./squareOdbc')[_0x334214('0x10')](),await require(_0x334214('0x5'))[_0x334214('0x10')](),await require(_0x334214('0x2'))[_0x334214('0x10')](),await require(_0x334214('0x1c'))['create'](),await require(_0x334214('0x7'))[_0x334214('0x10')](),await require(_0x334214('0x13'))[_0x334214('0x10')](),await require(_0x334214('0x11'))[_0x334214('0x10')](),await require(_0x334214('0xb'))['create']()):(await require(_0x334214('0x1'))[_0x334214('0x10')](),await require(_0x334214('0x1c'))[_0x334214('0x16')](),await require(_0x334214('0x18'))[_0x334214('0x10')](),await require(_0x334214('0x15'))[_0x334214('0xe')](),await require(_0x334214('0x1a'))[_0x334214('0xe')]());}catch(_0x34fe46){logger['error'](_0x334214('0x6'),JSON[_0x334214('0xc')](_0x34fe46));}}exports['default']=defaultSeed; \ No newline at end of file diff --git a/server/config/seedDB/intervals.js b/server/config/seedDB/intervals.js index 3eff905..9d520b8 100644 --- a/server/config/seedDB/intervals.js +++ b/server/config/seedDB/intervals.js @@ -1 +1 @@ -const a861_0x3acd=['14:00-18:00,mon-fri,*,*','Holidays','flat','working\x20time\x20auto\x20generated','Can\x27t\x20create\x20Intevals','Morning','filter','../../mysqldb','name','isArray','app','*,*,31,oct','Interval','info','findAll','exports','../logger','map','bulkCreate','WorkingTime','09:00-13:00,mon-fri,*,*'];(function(_0x5a0264,_0x3acdb7){const _0xa5317=function(_0x929627){while(--_0x929627){_0x5a0264['push'](_0x5a0264['shift']());}};_0xa5317(++_0x3acdb7);}(a861_0x3acd,0xef));const a861_0xa531=function(_0x5a0264,_0x3acdb7){_0x5a0264=_0x5a0264-0x0;let _0xa5317=a861_0x3acd[_0x5a0264];return _0xa5317;};const _0x3f7888=a861_0xa531;'use strict';const db=require(_0x3f7888('0x14'))['db'],logger=require(_0x3f7888('0x8'))(_0x3f7888('0x2')),subIntervals={'WorkingTime':[{'name':_0x3f7888('0x12'),'interval':_0x3f7888('0xc')},{'name':'Afternoon','interval':_0x3f7888('0xd')}],'Holidays':[{'name':'Christmas','interval':'*,*,25,dec'},{'name':'NewYear','interval':'*,*,1,jan'},{'name':'Valentines','interval':'*,*,14,feb'},{'name':'Halloween','interval':_0x3f7888('0x3')}]},intervals=[{'id':0x1,'name':_0x3f7888('0xb'),'description':_0x3f7888('0x10')},{'id':0x2,'name':_0x3f7888('0xe'),'description':'working\x20time\x20auto\x20generated'}];async function create(){const _0x4708a7=_0x3f7888;try{await db['Interval'][_0x4708a7('0xa')](intervals,{'ignoreDuplicates':!![],'individualHooks':!![]});const _0x929627=await db[_0x4708a7('0x4')][_0x4708a7('0x6')](),_0x1e2dff=_0x929627[_0x4708a7('0x9')](_0x51aa45=>{const _0x3b623e=_0x4708a7,_0x1d0722=subIntervals[_0x51aa45[_0x3b623e('0x0')]];return Array[_0x3b623e('0x1')](_0x1d0722)?_0x1d0722[_0x3b623e('0x9')](_0x16b616=>{const {description:_0x468033,id:_0x1ce7cd}=_0x51aa45;return{'description':_0x468033,'IntervalId':_0x1ce7cd,..._0x16b616};}):null;})[_0x4708a7('0x13')](_0x362d8c=>_0x362d8c!==null)[_0x4708a7('0xf')]();await db[_0x4708a7('0x4')][_0x4708a7('0xa')](_0x1e2dff,{'ignoreDuplicates':!![],'individualHooks':!![]}),logger[_0x4708a7('0x5')]('Intervals\x20have\x20been\x20created');}catch(_0x2a3cb0){logger['error'](_0x4708a7('0x11'),_0x2a3cb0);throw _0x2a3cb0;}}module[_0x3f7888('0x7')]={'create':create}; \ No newline at end of file +const a861_0x1293=['WorkingTime','Valentines','14:00-18:00,mon-fri,*,*','09:00-13:00,mon-fri,*,*','../../mysqldb','Holidays','info','isArray','Can\x27t\x20create\x20Intevals','working\x20time\x20auto\x20generated','*,*,14,feb','*,*,31,oct','NewYear','name','*,*,25,dec','*,*,1,jan','filter','Afternoon','Interval','findAll','bulkCreate','../logger','map','flat','Christmas','Morning'];(function(_0x12ce5d,_0x1293b4){const _0x58c8d8=function(_0x29cf23){while(--_0x29cf23){_0x12ce5d['push'](_0x12ce5d['shift']());}};_0x58c8d8(++_0x1293b4);}(a861_0x1293,0x16e));const a861_0x58c8=function(_0x12ce5d,_0x1293b4){_0x12ce5d=_0x12ce5d-0x0;let _0x58c8d8=a861_0x1293[_0x12ce5d];return _0x58c8d8;};const _0x390896=a861_0x58c8;'use strict';const db=require(_0x390896('0x2'))['db'],logger=require(_0x390896('0x13'))('app'),subIntervals={'WorkingTime':[{'name':_0x390896('0x17'),'interval':_0x390896('0x1')},{'name':_0x390896('0xf'),'interval':_0x390896('0x0')}],'Holidays':[{'name':_0x390896('0x16'),'interval':_0x390896('0xc')},{'name':_0x390896('0xa'),'interval':_0x390896('0xd')},{'name':_0x390896('0x19'),'interval':_0x390896('0x8')},{'name':'Halloween','interval':_0x390896('0x9')}]},intervals=[{'id':0x1,'name':_0x390896('0x18'),'description':_0x390896('0x7')},{'id':0x2,'name':_0x390896('0x3'),'description':_0x390896('0x7')}];async function create(){const _0x28d31b=_0x390896;try{await db[_0x28d31b('0x10')]['bulkCreate'](intervals,{'ignoreDuplicates':!![],'individualHooks':!![]});const _0x29cf23=await db[_0x28d31b('0x10')][_0x28d31b('0x11')](),_0x139ac1=_0x29cf23[_0x28d31b('0x14')](_0x626cd7=>{const _0x5092e3=_0x28d31b,_0x2be5a0=subIntervals[_0x626cd7[_0x5092e3('0xb')]];return Array[_0x5092e3('0x5')](_0x2be5a0)?_0x2be5a0[_0x5092e3('0x14')](_0x15293d=>{const {description:_0x1245e9,id:_0x8fc2d4}=_0x626cd7;return{'description':_0x1245e9,'IntervalId':_0x8fc2d4,..._0x15293d};}):null;})[_0x28d31b('0xe')](_0x3c9ae1=>_0x3c9ae1!==null)[_0x28d31b('0x15')]();await db[_0x28d31b('0x10')][_0x28d31b('0x12')](_0x139ac1,{'ignoreDuplicates':!![],'individualHooks':!![]}),logger[_0x28d31b('0x4')]('Intervals\x20have\x20been\x20created');}catch(_0x2d0ad1){logger['error'](_0x28d31b('0x6'),_0x2d0ad1);throw _0x2d0ad1;}}module['exports']={'create':create}; \ No newline at end of file diff --git a/server/config/seedDB/jscriptyProjects.js b/server/config/seedDB/jscriptyProjects.js index 4f63bb6..6aef128 100644 --- a/server/config/seedDB/jscriptyProjects.js +++ b/server/config/seedDB/jscriptyProjects.js @@ -1 +1 @@ -const a862_0x465c=['.json','utf-8','customerSatisfation','../../mysqldb','Customer\x20Satisfaction\x20auto\x20generated','join','catch','CustomerSatisfaction','then','app','error','create','Jscripty\x20Projects\x20have\x20been\x20created','path','JscriptyProject','Can\x27t\x20create\x20Jscripty\x20Projects'];(function(_0x331d32,_0x465c7c){const _0x40aa07=function(_0x2d6cd7){while(--_0x2d6cd7){_0x331d32['push'](_0x331d32['shift']());}};_0x40aa07(++_0x465c7c);}(a862_0x465c,0xd2));const a862_0x40aa=function(_0x331d32,_0x465c7c){_0x331d32=_0x331d32-0x0;let _0x40aa07=a862_0x465c[_0x331d32];return _0x40aa07;};const _0x45afe1=a862_0x40aa;'use strict';const fs=require('fs'),path=require(_0x45afe1('0xb')),db=require(_0x45afe1('0x1'))['db'],logger=require('../logger')(_0x45afe1('0x7')),getJson=function(_0x2d6cd7){const _0x3f1700=_0x45afe1;return fs['readFileSync'](path[_0x3f1700('0x3')](__dirname,'jscripty',_0x2d6cd7+_0x3f1700('0xe')),{'encoding':_0x3f1700('0xf')});},jscriptyProjects=[{'id':0x1,'name':_0x45afe1('0x5'),'description':_0x45afe1('0x2'),'formData':getJson(_0x45afe1('0x0'))}];exports[_0x45afe1('0x9')]=function(){const _0x2a6347=_0x45afe1;return db[_0x2a6347('0xc')]['bulkCreate'](jscriptyProjects,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x2a6347('0x6')](function(){const _0x11aad0=_0x2a6347;logger['info'](_0x11aad0('0xa'));})[_0x2a6347('0x4')](function(){const _0x48240d=_0x2a6347;logger[_0x48240d('0x8')](_0x48240d('0xd'));});}; \ No newline at end of file +const a862_0x5edd=['Can\x27t\x20create\x20Jscripty\x20Projects','Jscripty\x20Projects\x20have\x20been\x20created','info','utf-8','.json','../../mysqldb','path','bulkCreate','error','catch','join','jscripty','CustomerSatisfaction','customerSatisfation','create','app','../logger','then'];(function(_0x5b902b,_0x5eddd9){const _0x266ec3=function(_0xf1ab22){while(--_0xf1ab22){_0x5b902b['push'](_0x5b902b['shift']());}};_0x266ec3(++_0x5eddd9);}(a862_0x5edd,0x64));const a862_0x266e=function(_0x5b902b,_0x5eddd9){_0x5b902b=_0x5b902b-0x0;let _0x266ec3=a862_0x5edd[_0x5b902b];return _0x266ec3;};const _0x7e6282=a862_0x266e;'use strict';const fs=require('fs'),path=require(_0x7e6282('0xe')),db=require(_0x7e6282('0xd'))['db'],logger=require(_0x7e6282('0x6'))(_0x7e6282('0x5')),getJson=function(_0xf1ab22){const _0x468e77=_0x7e6282;return fs['readFileSync'](path[_0x468e77('0x0')](__dirname,_0x468e77('0x1'),_0xf1ab22+_0x468e77('0xc')),{'encoding':_0x468e77('0xb')});},jscriptyProjects=[{'id':0x1,'name':_0x7e6282('0x2'),'description':'Customer\x20Satisfaction\x20auto\x20generated','formData':getJson(_0x7e6282('0x3'))}];exports[_0x7e6282('0x4')]=function(){const _0xebbf1a=_0x7e6282;return db['JscriptyProject'][_0xebbf1a('0xf')](jscriptyProjects,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0xebbf1a('0x7')](function(){const _0x1571c0=_0xebbf1a;logger[_0x1571c0('0xa')](_0x1571c0('0x9'));})[_0xebbf1a('0x11')](function(){const _0xd5716c=_0xebbf1a;logger[_0xd5716c('0x10')](_0xd5716c('0x8'));});}; \ No newline at end of file diff --git a/server/config/seedDB/lists.js b/server/config/seedDB/lists.js index e8fa488..9c7a5ea 100644 --- a/server/config/seedDB/lists.js +++ b/server/config/seedDB/lists.js @@ -1 +1 @@ -const a863_0x44e8=['app','Black\x20List','CmList','public\x20list\x20auto\x20generated','catch','../logger','info','Callback\x20List','../../mysqldb','bulkCreate','error','Lists\x20have\x20been\x20created','black\x20list\x20auto\x20generated','Public\x20List','then'];(function(_0x4060b0,_0x44e8b9){const _0x55026a=function(_0x429aad){while(--_0x429aad){_0x4060b0['push'](_0x4060b0['shift']());}};_0x55026a(++_0x44e8b9);}(a863_0x44e8,0xeb));const a863_0x5502=function(_0x4060b0,_0x44e8b9){_0x4060b0=_0x4060b0-0x0;let _0x55026a=a863_0x44e8[_0x4060b0];return _0x55026a;};const _0x4e682d=a863_0x5502;'use strict';const db=require(_0x4e682d('0xd'))['db'],logger=require(_0x4e682d('0xa'))(_0x4e682d('0x5')),lists=[{'id':0x1,'name':_0x4e682d('0x3'),'description':_0x4e682d('0x8')},{'id':0x2,'name':_0x4e682d('0x6'),'description':_0x4e682d('0x2')},{'id':0x3,'name':_0x4e682d('0xc'),'description':'Callback\x20list\x20auto\x20generated'}];exports['create']=function(){const _0x3a398e=_0x4e682d;return db[_0x3a398e('0x7')][_0x3a398e('0xe')](lists,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x3a398e('0x4')](function(){const _0x235d40=_0x3a398e;logger[_0x235d40('0xb')](_0x235d40('0x1'));})[_0x3a398e('0x9')](function(){const _0x1b0a95=_0x3a398e;logger[_0x1b0a95('0x0')]('Can\x27t\x20create\x20Lists');});}; \ No newline at end of file +const a863_0x38ec=['info','../../mysqldb','../logger','then','CmList','Public\x20List','create','Black\x20List','bulkCreate','Callback\x20List','Callback\x20list\x20auto\x20generated','black\x20list\x20auto\x20generated','Lists\x20have\x20been\x20created','error','public\x20list\x20auto\x20generated'];(function(_0x3a993d,_0x38ec72){const _0x13f7a5=function(_0x3fdf50){while(--_0x3fdf50){_0x3a993d['push'](_0x3a993d['shift']());}};_0x13f7a5(++_0x38ec72);}(a863_0x38ec,0x196));const a863_0x13f7=function(_0x3a993d,_0x38ec72){_0x3a993d=_0x3a993d-0x0;let _0x13f7a5=a863_0x38ec[_0x3a993d];return _0x13f7a5;};const _0x5c7064=a863_0x13f7;'use strict';const db=require(_0x5c7064('0x0'))['db'],logger=require(_0x5c7064('0x1'))('app'),lists=[{'id':0x1,'name':_0x5c7064('0x4'),'description':_0x5c7064('0xd')},{'id':0x2,'name':_0x5c7064('0x6'),'description':_0x5c7064('0xa')},{'id':0x3,'name':_0x5c7064('0x8'),'description':_0x5c7064('0x9')}];exports[_0x5c7064('0x5')]=function(){const _0x203172=_0x5c7064;return db[_0x203172('0x3')][_0x203172('0x7')](lists,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x203172('0x2')](function(){const _0x30bfe4=_0x203172;logger[_0x30bfe4('0xe')](_0x30bfe4('0xb'));})['catch'](function(){const _0x4273db=_0x203172;logger[_0x4273db('0xc')]('Can\x27t\x20create\x20Lists');});}; \ No newline at end of file diff --git a/server/config/seedDB/mailAccounts.js b/server/config/seedDB/mailAccounts.js index 916c2ba..f99859c 100644 --- a/server/config/seedDB/mailAccounts.js +++ b/server/config/seedDB/mailAccounts.js @@ -1 +1 @@ -const a864_0x5854=['service\x20motion\x20smtp\x20auto\x20generated','service\x20motion\x20imap\x20auto\x20generated','then','password','MailAccount','username','SERV','email@xcally.com','Can\x27t\x20create\x20Mail\x20Accounts','info','127.0.0.1','service\x20motion\x20account\x20auto\x20generated','MailServerIn','MailServerOut','catch','findOrCreate','Service\x20Mail','../../mysqldb'];(function(_0x2b2401,_0x5854a9){const _0x53f2f3=function(_0x4ab217){while(--_0x4ab217){_0x2b2401['push'](_0x2b2401['shift']());}};_0x53f2f3(++_0x5854a9);}(a864_0x5854,0xec));const a864_0x53f2=function(_0x2b2401,_0x5854a9){_0x2b2401=_0x2b2401-0x0;let _0x53f2f3=a864_0x5854[_0x2b2401];return _0x53f2f3;};const _0x2632d4=a864_0x53f2;'use strict';const db=require(_0x2632d4('0xf'))['db'],logger=require('../logger')('app');exports['create']=function(){const _0x56e1e7=_0x2632d4;let _0x4ab217;return db[_0x56e1e7('0x2')][_0x56e1e7('0xd')]({'where':{'service':!![]},'defaults':{'name':_0x56e1e7('0xe'),'key':_0x56e1e7('0x4'),'email':_0x56e1e7('0x5'),'service':!![],'description':_0x56e1e7('0x9'),'active':![],'ListId':0x1}})[_0x56e1e7('0x0')](function([_0x2e103f,_0x365d8b]){const _0x250508=_0x56e1e7;return _0x365d8b&&logger[_0x250508('0x7')](_0x250508('0x9')),_0x4ab217=_0x2e103f,db[_0x250508('0xb')][_0x250508('0xd')]({'where':{'MailAccountId':_0x4ab217['id']},'defaults':{'host':_0x250508('0x8'),'user':_0x250508('0x3'),'pass':_0x250508('0x1'),'port':0x19,'secure':![],'authentication':![],'MailAccountId':_0x4ab217['id'],'description':_0x250508('0x10')}});})[_0x56e1e7('0x0')](function([,_0x5f52cf]){const _0x4d7e4b=_0x56e1e7;return _0x5f52cf&&logger[_0x4d7e4b('0x7')](_0x4d7e4b('0x10')),db[_0x4d7e4b('0xa')][_0x4d7e4b('0xd')]({'where':{'MailAccountId':_0x4ab217['id']},'defaults':{'host':_0x4d7e4b('0x8'),'user':_0x4d7e4b('0x3'),'password':_0x4d7e4b('0x1'),'port':0x3e1,'MailAccountId':_0x4ab217['id'],'description':_0x4d7e4b('0x11')}});})[_0x56e1e7('0x0')](function([,_0x529862]){const _0xc979b6=_0x56e1e7;_0x529862&&logger['info'](_0xc979b6('0x11'));})[_0x56e1e7('0xc')](function(){const _0x5aad2a=_0x56e1e7;logger['error'](_0x5aad2a('0x6'));});}; \ No newline at end of file +const a864_0x34de=['then','MailServerIn','create','Can\x27t\x20create\x20Mail\x20Accounts','error','../../mysqldb','findOrCreate','SERV','service\x20motion\x20smtp\x20auto\x20generated','../logger','MailAccount','username','service\x20motion\x20account\x20auto\x20generated','service\x20motion\x20imap\x20auto\x20generated','catch','info','password','127.0.0.1','MailServerOut','Service\x20Mail'];(function(_0xc28f1b,_0x34dee7){const _0x4a6c97=function(_0x261751){while(--_0x261751){_0xc28f1b['push'](_0xc28f1b['shift']());}};_0x4a6c97(++_0x34dee7);}(a864_0x34de,0x1aa));const a864_0x4a6c=function(_0xc28f1b,_0x34dee7){_0xc28f1b=_0xc28f1b-0x0;let _0x4a6c97=a864_0x34de[_0xc28f1b];return _0x4a6c97;};const _0x50ad82=a864_0x4a6c;'use strict';const db=require(_0x50ad82('0x13'))['db'],logger=require(_0x50ad82('0x3'))('app');exports[_0x50ad82('0x10')]=function(){const _0x180efe=_0x50ad82;let _0x261751;return db[_0x180efe('0x4')][_0x180efe('0x0')]({'where':{'service':!![]},'defaults':{'name':_0x180efe('0xd'),'key':_0x180efe('0x1'),'email':'email@xcally.com','service':!![],'description':_0x180efe('0x6'),'active':![],'ListId':0x1}})[_0x180efe('0xe')](function([_0x167388,_0x233f60]){const _0x5a9249=_0x180efe;return _0x233f60&&logger[_0x5a9249('0x9')](_0x5a9249('0x6')),_0x261751=_0x167388,db[_0x5a9249('0xc')][_0x5a9249('0x0')]({'where':{'MailAccountId':_0x261751['id']},'defaults':{'host':_0x5a9249('0xb'),'user':_0x5a9249('0x5'),'pass':_0x5a9249('0xa'),'port':0x19,'secure':![],'authentication':![],'MailAccountId':_0x261751['id'],'description':_0x5a9249('0x2')}});})[_0x180efe('0xe')](function([,_0x52dbd7]){const _0x403406=_0x180efe;return _0x52dbd7&&logger[_0x403406('0x9')]('service\x20motion\x20smtp\x20auto\x20generated'),db[_0x403406('0xf')][_0x403406('0x0')]({'where':{'MailAccountId':_0x261751['id']},'defaults':{'host':'127.0.0.1','user':_0x403406('0x5'),'password':_0x403406('0xa'),'port':0x3e1,'MailAccountId':_0x261751['id'],'description':'service\x20motion\x20imap\x20auto\x20generated'}});})[_0x180efe('0xe')](function([,_0x36a06d]){const _0x156b28=_0x180efe;_0x36a06d&&logger[_0x156b28('0x9')](_0x156b28('0x7'));})[_0x180efe('0x8')](function(){const _0x6908f4=_0x180efe;logger[_0x6908f4('0x12')](_0x6908f4('0x11'));});}; \ No newline at end of file diff --git a/server/config/seedDB/mailSubstatuses.js b/server/config/seedDB/mailSubstatuses.js index 27a48e1..bc85879 100644 --- a/server/config/seedDB/mailSubstatuses.js +++ b/server/config/seedDB/mailSubstatuses.js @@ -1 +1 @@ -const a865_0x3cff=['then','create','info','MailSubstatus','error','app','../logger','Substatues\x20have\x20been\x20created','Pending\x20status\x20for\x20mail\x20interaction'];(function(_0x4b0094,_0x3cff1a){const _0x404361=function(_0x4bb8a1){while(--_0x4bb8a1){_0x4b0094['push'](_0x4b0094['shift']());}};_0x404361(++_0x3cff1a);}(a865_0x3cff,0xc2));const a865_0x4043=function(_0x4b0094,_0x3cff1a){_0x4b0094=_0x4b0094-0x0;let _0x404361=a865_0x3cff[_0x4b0094];return _0x404361;};const _0x10c7a2=a865_0x4043;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x10c7a2('0x1'))(_0x10c7a2('0x0')),items=[{'id':0x1,'name':'pending','description':_0x10c7a2('0x3')}];exports[_0x10c7a2('0x5')]=function(){const _0x504cf9=_0x10c7a2;return db[_0x504cf9('0x7')]['bulkCreate'](items,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x504cf9('0x4')](function(){const _0x3c631a=_0x504cf9;logger[_0x3c631a('0x6')](_0x3c631a('0x2'));})['catch'](function(){const _0x3e7b67=_0x504cf9;logger[_0x3e7b67('0x8')]('Can\x27t\x20create\x20MailSubstatuses');});}; \ No newline at end of file +const a865_0x4b4f=['Pending\x20status\x20for\x20mail\x20interaction','catch','Substatues\x20have\x20been\x20created','../logger','pending','../../mysqldb','error','Can\x27t\x20create\x20MailSubstatuses','info','app','then','MailSubstatus'];(function(_0x819634,_0x4b4f53){const _0x371e47=function(_0x3a853c){while(--_0x3a853c){_0x819634['push'](_0x819634['shift']());}};_0x371e47(++_0x4b4f53);}(a865_0x4b4f,0x154));const a865_0x371e=function(_0x819634,_0x4b4f53){_0x819634=_0x819634-0x0;let _0x371e47=a865_0x4b4f[_0x819634];return _0x371e47;};const _0x5d19af=a865_0x371e;'use strict';const db=require(_0x5d19af('0x1'))['db'],logger=require(_0x5d19af('0xb'))(_0x5d19af('0x5')),items=[{'id':0x1,'name':_0x5d19af('0x0'),'description':_0x5d19af('0x8')}];exports['create']=function(){const _0x2988ee=_0x5d19af;return db[_0x2988ee('0x7')]['bulkCreate'](items,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x2988ee('0x6')](function(){const _0x26edcc=_0x2988ee;logger[_0x26edcc('0x4')](_0x26edcc('0xa'));})[_0x2988ee('0x9')](function(){const _0x3e68e1=_0x2988ee;logger[_0x3e68e1('0x2')](_0x3e68e1('0x3'));});}; \ No newline at end of file diff --git a/server/config/seedDB/migrations.js b/server/config/seedDB/migrations.js index 1a995df..1185a48 100644 --- a/server/config/seedDB/migrations.js +++ b/server/config/seedDB/migrations.js @@ -1 +1 @@ -const a866_0xa5fd=['Migration','../logger','.js','../../mysqldb','../../../package.json','create','error','Can\x27t\x20create\x20Version','Version\x20have\x20been\x20created','app'];(function(_0xd76605,_0xa5fd28){const _0x65557=function(_0x1a959c){while(--_0x1a959c){_0xd76605['push'](_0xd76605['shift']());}};_0x65557(++_0xa5fd28);}(a866_0xa5fd,0x174));const a866_0x6555=function(_0xd76605,_0xa5fd28){_0xd76605=_0xd76605-0x0;let _0x65557=a866_0xa5fd[_0xd76605];return _0x65557;};const _0x43844a=a866_0x6555;'use strict';const db=require(_0x43844a('0x1'))['db'],logger=require(_0x43844a('0x9'))(_0x43844a('0x7')),{version:packageVersion}=require(_0x43844a('0x2'));exports[_0x43844a('0x3')]=function(){const _0x482180=_0x43844a;return db[_0x482180('0x8')][_0x482180('0x3')]({'version':packageVersion+_0x482180('0x0')})['then'](function(){const _0x37176a=_0x482180;logger['info'](_0x37176a('0x6'));})['catch'](function(){const _0x3667a2=_0x482180;logger[_0x3667a2('0x4')](_0x3667a2('0x5'));});}; \ No newline at end of file +const a866_0x2a0d=['../logger','create','error','../../mysqldb','catch','.js','then','../../../package.json','info'];(function(_0x369256,_0x2a0dfb){const _0x211c42=function(_0x208355){while(--_0x208355){_0x369256['push'](_0x369256['shift']());}};_0x211c42(++_0x2a0dfb);}(a866_0x2a0d,0x14c));const a866_0x211c=function(_0x369256,_0x2a0dfb){_0x369256=_0x369256-0x0;let _0x211c42=a866_0x2a0d[_0x369256];return _0x211c42;};const _0x5019b5=a866_0x211c;'use strict';const db=require(_0x5019b5('0x4'))['db'],logger=require(_0x5019b5('0x1'))('app'),{version:packageVersion}=require(_0x5019b5('0x8'));exports[_0x5019b5('0x2')]=function(){const _0x21afc8=_0x5019b5;return db['Migration'][_0x21afc8('0x2')]({'version':packageVersion+_0x21afc8('0x6')})[_0x21afc8('0x7')](function(){const _0x4dcb8a=_0x21afc8;logger[_0x4dcb8a('0x0')]('Version\x20have\x20been\x20created');})[_0x21afc8('0x5')](function(){const _0x385f8d=_0x21afc8;logger[_0x385f8d('0x3')]('Can\x27t\x20create\x20Version');});}; \ No newline at end of file diff --git a/server/config/seedDB/pauses.js b/server/config/seedDB/pauses.js index 47c6edf..d2c8a86 100644 --- a/server/config/seedDB/pauses.js +++ b/server/config/seedDB/pauses.js @@ -1 +1 @@ -const a867_0x8a56=['create','app','then','Can\x27t\x20create\x20Pauses','Pauses\x20have\x20been\x20created','catch','BACKOFFICE','AFTERCALL','../../mysqldb','bulkCreate','Pause','../logger'];(function(_0x36031e,_0x8a56de){const _0x46acd0=function(_0x104bc3){while(--_0x104bc3){_0x36031e['push'](_0x36031e['shift']());}};_0x46acd0(++_0x8a56de);}(a867_0x8a56,0x152));const a867_0x46ac=function(_0x36031e,_0x8a56de){_0x36031e=_0x36031e-0x0;let _0x46acd0=a867_0x8a56[_0x36031e];return _0x46acd0;};const _0x1cd8dd=a867_0x46ac;'use strict';const db=require(_0x1cd8dd('0x6'))['db'],logger=require(_0x1cd8dd('0x9'))(_0x1cd8dd('0xb')),pauses=[{'id':0x1,'name':_0x1cd8dd('0x4'),'description':'backoffice\x20pause\x20auto\x20generated'},{'id':0x2,'name':_0x1cd8dd('0x5'),'description':'aftercall\x20pause\x20auto\x20generated'}];exports[_0x1cd8dd('0xa')]=function(){const _0x288ac0=_0x1cd8dd;return db[_0x288ac0('0x8')][_0x288ac0('0x7')](pauses,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x288ac0('0x0')](function(){const _0x2b9d54=_0x288ac0;logger['info'](_0x2b9d54('0x2'));})[_0x288ac0('0x3')](function(){const _0x4c07c1=_0x288ac0;logger['error'](_0x4c07c1('0x1'));});}; \ No newline at end of file +const a867_0x2c87=['AFTERCALL','BACKOFFICE','bulkCreate','aftercall\x20pause\x20auto\x20generated','backoffice\x20pause\x20auto\x20generated','../logger','Pause','error'];(function(_0x250f74,_0x2c87f2){const _0x35119a=function(_0x578896){while(--_0x578896){_0x250f74['push'](_0x250f74['shift']());}};_0x35119a(++_0x2c87f2);}(a867_0x2c87,0xc8));const a867_0x3511=function(_0x250f74,_0x2c87f2){_0x250f74=_0x250f74-0x0;let _0x35119a=a867_0x2c87[_0x250f74];return _0x35119a;};const _0x3f6f29=a867_0x3511;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x3f6f29('0x5'))('app'),pauses=[{'id':0x1,'name':_0x3f6f29('0x1'),'description':_0x3f6f29('0x4')},{'id':0x2,'name':_0x3f6f29('0x0'),'description':_0x3f6f29('0x3')}];exports['create']=function(){const _0x349c03=_0x3f6f29;return db[_0x349c03('0x6')][_0x349c03('0x2')](pauses,{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(){logger['info']('Pauses\x20have\x20been\x20created');})['catch'](function(){const _0x40e5ad=_0x349c03;logger[_0x40e5ad('0x7')]('Can\x27t\x20create\x20Pauses');});}; \ No newline at end of file diff --git a/server/config/seedDB/report/default.js b/server/config/seedDB/report/default.js index 879a76b..20096ba 100644 --- a/server/config/seedDB/report/default.js +++ b/server/config/seedDB/report/default.js @@ -1 +1 @@ -var a868_0x23dd=['mail_interactions','WhatsApp\x20interactions\x20by\x20date','Unanswered\x20calls\x20summary\x20by\x20queue','CallySquare\x20Blocks\x20Detail','Calls\x20distribution\x20by\x20day\x20of\x20the\x20month','Agent\x20Disposition\x20Rate','Calls\x20distribution\x20by\x20queue','Blocks','Sms\x20interactions\x20by\x20queue','Calls\x20by\x20Type','[{\x22parentKey\x22:\x22ChatWebsiteId\x22,\x22foreignTable\x22:\x22chat_websites\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','[{\x22parentKey\x22:\x22OpenchannelQueueId\x22,\x22foreignTable\x22:\x22openchannel_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Sms\x20interactions\x20by\x20account','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22openchannel_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22openchannel_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22openchannel_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','[{\x22parentKey\x22:\x22WhatsappQueueId\x22,\x22foreignTable\x22:\x22whatsapp_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','_voice_queues_unanswered','WhatsApp\x20interactions\x20by\x20agent','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22openchannel_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22whatsapp_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','Summary\x20of\x20outbound\x20calls\x20grouped\x20by\x20date','Disposition\x20Rate','Openchannel\x20interactions\x20by\x20date','Agent\x27s\x20status\x20detail','Answer\x20Time\x20by\x20Queue','Fax\x20By\x20Queue','Answer\x20Time\x20by\x20Hour','Openchannel\x20Account\x20Times','[{\x22parentKey\x22:\x22SmsQueueId\x22,\x22foreignTable\x22:\x22sms_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Activities\x20Summary','Sms\x20Account\x20Summary','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27queue\x27\x22}]}}','report_member','Fax\x20By\x20Date','_mail','Summary','WhatsApp\x20By\x20Agent','report_agent','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27LOGIN\x27\x22,\x22required\x22:true},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22channel\x22,\x22value\x22:\x22\x27voice\x27\x22,\x22required\x22:true}]}}','WhatsApp\x20interaction\x20times\x20by\x20account','Outbound\x20Calls\x20by\x20Agent','Unanswered\x20by\x20Queue','Openchannel\x20interactions\x20by\x20agent','_sms','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27ivr\x27\x22}]}}','Chat\x20interactions\x20by\x20queue','_voice_recordings','WhatsApp\x20Account\x20Summary','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[]}}','Manual\x20outbound\x20calls\x20detailed\x20report','[{\x22parentKey\x22:\x22WhatsappAccountId\x22,\x22foreignTable\x22:\x22whatsapp_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','_bull_queue_campaigns','Email\x20interactions\x20by\x20account','cm_hopper_final','Abandon\x20time\x20performance\x20by\x20queue','Email\x20interaction\x20times\x20by\x20account','Calls\x20by\x20Queue','[{\x22parentKey\x22:\x22MailQueueId\x22,\x22foreignTable\x22:\x22mail_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22whatsapp_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22whatsapp_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22whatsapp_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','Chat\x20interactions\x20by\x20agent','Email\x20Account\x20Summary','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27outbound\x27\x22,\x22required\x22:true}]}}','_voice_queues','Queues\x20answer\x20time\x20performance','[{\x22parentKey\x22:\x22SmsAccountId\x22,\x22foreignTable\x22:\x22sms_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22sms_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','Chat\x20interactions\x20by\x20date','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22channel\x22,\x22value\x22:\x22\x27voice\x27\x22,\x22required\x22:true}]}}','[{\x22parentKey\x22:\x22OpenchannelAccountId\x22,\x22foreignTable\x22:\x22openchannel_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Sms\x20interaction\x20times\x20by\x20account','Sms\x20interactions\x20by\x20agent','whatsapp_interactions','Openchannel\x20By\x20Agent','Calls\x20detail\x20(cdr)','Pause\x20Details','[{\x22parentKey\x22:\x22UserId\x22,\x22foreignTable\x22:\x22users\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27queue\x27\x22},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22state\x22,\x22value\x22:\x224\x22}]}}','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22chat_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22chat_interactions.disposition\x22,\x22value\x22:\x22\x22},{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22chat_interactions.disposition\x22,\x22value\x22:\x22\x27abandoned\x27\x22},{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22chat_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22}]}}]}}]}}','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22queuecallercomplete\x22,\x22value\x22:\x220\x22,\x22required\x22:true}]}}','Outbound\x20calls\x20grouped\x20by\x20disposition','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22mail_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22mail_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22mail_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','Email\x20interactions\x20by\x20agent','Sentiment\x20by\x20agent','Calls\x20Result','Records\x20rating\x20by\x20agent','Chat\x20interaction\x20times\x20by\x20website','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22voice_recordings.sentiment\x22,\x22value\x22:\x22\x22}]}}','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22fax_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22fax_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22fax_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','Email\x20By\x20Date','Summary\x20report\x20of\x20the\x20calls\x20type','Sms\x20interactions\x20by\x20date','Fax\x20Account\x20Summary','_bull_ivr_campaigns','report_square_details','Agent\x27s\x20activities\x20report','Agent\x20Calls','openchannel_interactions','WhatsApp\x20interactions\x20by\x20account','report_chat_queue','List\x20Penetration\x20Rate','Outbound\x20Calls\x20by\x20Date','_voice_callysquare','Fax\x20interaction\x20times\x20by\x20account','cm_hopper_history','Details','Calls\x20by\x20Date','Website\x20Times','Disconnection\x20Cause','Sentiment\x20Summary','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27PAUSE\x27\x22,\x22required\x22:true},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22channel\x22,\x22value\x22:\x22\x27voice\x27\x22,\x22required\x22:true}]}}','Unmanaged\x20calls','Fax\x20By\x20Agent','Calls\x20Summary','Chat\x20interactions\x20by\x20website','report_openchannel_queue','Campaign\x20Calls','Sms\x20By\x20Queue','voice_recordings','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22agentcomplete\x22,\x22value\x22:\x221\x22,\x22required\x22:true}]}}','Fax\x20interactions\x20by\x20date','Abandon\x20Time\x20by\x20Queue','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22fax_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','sms_interactions','_voice_calls','Sentiment\x20by\x20Agent','_chat','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22queuecallerexit\x22,\x22value\x22:\x221\x22,\x22required\x22:true}]}}','Unmanaged\x20calls\x20summary','_fax','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22voice_recordings.sentiment\x22,\x22value\x22:\x22NULL\x22}]}}','Openchannel\x20By\x20Queue','Sms\x20By\x20Agent','Calls\x20by\x20Day','Simple\x20queue\x20calls\x20overview','_whatsapp','Queue\x20calls\x20summary\x20by\x20date','_openchannel','Email\x20interactions\x20by\x20date','[{\x22parentKey\x22:\x22MailAccountId\x22,\x22foreignTable\x22:\x22mail_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','_voice_queues_distribution','_voice_queues_answered','Openchannel\x20Account\x20Summary','_voice_agents','_agents','Email\x20By\x20Agent','Email\x20By\x20Queue','report_square','Agents\x20status\x20details','WhatsApp\x20Account\x20Times','Website\x20Summary','fax_interactions','report_whatsapp_queue','Calls\x20distribution\x20by\x20day\x20of\x20the\x20week','[{\x22parentKey\x22:\x22ChatQueueId\x22,\x22foreignTable\x22:\x22chat_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','WhatsApp\x20By\x20Queue','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22channel\x22,\x22value\x22:\x22\x27voice\x27\x22,\x22required\x22:true},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27PAUSE\x27\x22,\x22required\x22:true}]}}','Chat\x20By\x20Queue','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22sms_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22sms_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22sms_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','Fax\x20interactions\x20by\x20queue','report_queue','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22queue\x22,\x22value\x22:\x22\x22,\x22required\x22:false},{\x22condition\x22:\x22>\x22,\x22field\x22:\x22rating\x22,\x22value\x22:\x220\x22,\x22required\x22:true}]}}','Records\x20rating\x20by\x20queue','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22mail_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','Agent\x27s\x20pause\x20time','Email\x20Account\x20Times','chat_interactions','Detailed\x20report\x20about\x20answered\x20queue\x20calls','Openchannel\x20interactions\x20by\x20queue','Rating\x20by\x20Queue','report_call','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27queue\x27\x22},{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22disposition\x22,\x22value\x22:\x22\x22},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22state\x22,\x22value\x22:\x224\x22}]}}','CallySquare\x20Summary','[{\x22parentKey\x22:\x22FaxQueueId\x22,\x22foreignTable\x22:\x22fax_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Calls\x20by\x20Agent','Sms\x20By\x20Date','Calls\x20by\x20Hour'];(function(_0x385d72,_0x23dde0){var _0x31522f=function(_0x11cbac){while(--_0x11cbac){_0x385d72['push'](_0x385d72['shift']());}};_0x31522f(++_0x23dde0);}(a868_0x23dd,0x77));var a868_0x3152=function(_0x385d72,_0x23dde0){_0x385d72=_0x385d72-0x0;var _0x31522f=a868_0x23dd[_0x385d72];return _0x31522f;};'use strict';module['exports']=function(_0x11cbac){var _0x2ae5ce=a868_0x3152;return[{'id':0x1,'name':_0x2ae5ce('0x9f'),'description':'Detailed\x20queues\x20report','parent':_0x11cbac+_0x2ae5ce('0x75'),'table':_0x2ae5ce('0x27'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[]}}'},{'id':0x2,'name':_0x2ae5ce('0x8a'),'description':_0x2ae5ce('0xd'),'parent':_0x11cbac+_0x2ae5ce('0x75'),'table':_0x2ae5ce('0x27'),'conditions':_0x2ae5ce('0x67')},{'id':0x3,'name':_0x2ae5ce('0x9f'),'description':_0x2ae5ce('0x2e'),'parent':_0x11cbac+_0x2ae5ce('0x14'),'table':_0x2ae5ce('0x5c'),'conditions':_0x2ae5ce('0xad')},{'id':0x4,'name':_0x2ae5ce('0x35'),'description':'Agent\x20calls\x20timer\x20Handle\x20time=\x20talk\x20time\x20+\x20ACW\x20time','parent':_0x11cbac+'_voice_queues_answered','table':_0x2ae5ce('0x5c'),'conditions':_0x2ae5ce('0xad')},{'id':0x5,'name':_0x2ae5ce('0x6f'),'description':'Queue\x20timer\x20Handle\x20Time=\x20Talk\x20Time\x20+\x20AVG\x20TIme','parent':_0x11cbac+'_voice_queues_answered','table':'report_agent','conditions':_0x2ae5ce('0xad')},{'id':0x6,'name':_0x2ae5ce('0x4f'),'description':_0x2ae5ce('0x76'),'parent':_0x11cbac+_0x2ae5ce('0x14'),'table':'report_agent','conditions':_0x2ae5ce('0xad')},{'id':0x7,'name':_0x2ae5ce('0xa2'),'description':'Summary\x20of\x20the\x20calls\x20disconnection\x20causes','parent':_0x11cbac+_0x2ae5ce('0x14'),'table':_0x2ae5ce('0x5c'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22agentcomplete\x22,\x22value\x22:\x221\x22,\x22required\x22:true}]}}'},{'id':0x8,'name':_0x2ae5ce('0x51'),'description':'Answer\x20time\x20\x20by\x20hour','parent':_0x11cbac+_0x2ae5ce('0x14'),'table':'report_agent','conditions':_0x2ae5ce('0xad')},{'id':0x9,'name':_0x2ae5ce('0x9f'),'description':'Detailed\x20report\x20about\x20the\x20unanswered\x20calls','parent':_0x11cbac+_0x2ae5ce('0x47'),'table':_0x2ae5ce('0x27'),'conditions':_0x2ae5ce('0x85')},{'id':0xa,'name':_0x2ae5ce('0x60'),'description':_0x2ae5ce('0x3a'),'parent':_0x11cbac+_0x2ae5ce('0x47'),'table':'report_queue','conditions':_0x2ae5ce('0x85')},{'id':0xb,'name':_0x2ae5ce('0xa5'),'description':_0x2ae5ce('0x7'),'parent':_0x11cbac+_0x2ae5ce('0x47'),'table':_0x2ae5ce('0x27'),'conditions':_0x2ae5ce('0x6')},{'id':0xc,'name':_0x2ae5ce('0x0'),'description':_0x2ae5ce('0x6d'),'parent':_0x11cbac+'_voice_queues_unanswered','table':_0x2ae5ce('0x27'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22queuecallerabandon\x22,\x22value\x22:\x221\x22,\x22required\x22:true}]}}'},{'id':0xd,'name':_0x2ae5ce('0xa0'),'description':_0x2ae5ce('0xf'),'parent':_0x11cbac+'_voice_queues_distribution','table':_0x2ae5ce('0x27'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[]}}'},{'id':0xe,'name':_0x2ae5ce('0x37'),'description':'Calls\x20distribution\x20by\x20hour','parent':_0x11cbac+_0x2ae5ce('0x13'),'table':'report_queue','conditions':_0x2ae5ce('0x67')},{'id':0xf,'name':_0x2ae5ce('0xc'),'description':_0x2ae5ce('0x3c'),'parent':_0x11cbac+_0x2ae5ce('0x13'),'table':_0x2ae5ce('0x27'),'conditions':_0x2ae5ce('0x67')},{'id':0x10,'name':'Calls\x20by\x20Weekday','description':_0x2ae5ce('0x20'),'parent':_0x11cbac+'_voice_queues_distribution','table':'report_queue','conditions':_0x2ae5ce('0x67')},{'id':0x11,'name':'Summary','description':_0x2ae5ce('0x3e'),'parent':_0x11cbac+_0x2ae5ce('0x75'),'table':'report_queue','conditions':_0x2ae5ce('0x67')},{'id':0x12,'name':_0x2ae5ce('0x9f'),'description':_0x2ae5ce('0x80'),'parent':_0x11cbac+'_voice_calls','table':'report_call','conditions':_0x2ae5ce('0x67')},{'id':0x13,'name':'Outbound','description':_0x2ae5ce('0x68'),'parent':_0x11cbac+'_voice_calls','table':'report_call','conditions':_0x2ae5ce('0x74')},{'id':0x14,'name':_0x2ae5ce('0x41'),'description':_0x2ae5ce('0x90'),'parent':_0x11cbac+_0x2ae5ce('0x3'),'table':'report_call','conditions':_0x2ae5ce('0x67')},{'id':0x15,'name':'Outbound\x20Calls\x20Disposition','description':_0x2ae5ce('0x86'),'parent':_0x11cbac+_0x2ae5ce('0x3'),'table':_0x2ae5ce('0x31'),'conditions':_0x2ae5ce('0x74')},{'id':0x16,'name':_0x2ae5ce('0x5f'),'description':'Summary\x20of\x20outbound\x20calls\x20grouped\x20by\x20agent','parent':_0x11cbac+_0x2ae5ce('0x3'),'table':_0x2ae5ce('0x31'),'conditions':_0x2ae5ce('0x74')},{'id':0x17,'name':_0x2ae5ce('0x9b'),'description':_0x2ae5ce('0x4b'),'parent':_0x11cbac+_0x2ae5ce('0x3'),'table':'report_call','conditions':_0x2ae5ce('0x74')},{'id':0x18,'name':'Login\x20Time','description':'Agent\x27s\x20login\x20time','parent':_0x11cbac+_0x2ae5ce('0x17'),'table':_0x2ae5ce('0x57'),'conditions':_0x2ae5ce('0x5d')},{'id':0x19,'name':_0x2ae5ce('0x54'),'description':_0x2ae5ce('0x95'),'parent':_0x11cbac+_0x2ae5ce('0x16'),'table':_0x2ae5ce('0x57'),'conditions':_0x2ae5ce('0x7a')},{'id':0x1a,'name':_0x2ae5ce('0x81'),'description':_0x2ae5ce('0x1b'),'parent':_0x11cbac+_0x2ae5ce('0x16'),'table':_0x2ae5ce('0x57'),'conditions':_0x2ae5ce('0x23')},{'id':0x1b,'name':_0x2ae5ce('0x9f'),'description':_0x2ae5ce('0x4e'),'parent':_0x11cbac+_0x2ae5ce('0x16'),'table':_0x2ae5ce('0x57'),'conditions':_0x2ae5ce('0x7a')},{'id':0x1c,'name':'Pause\x20Time','description':_0x2ae5ce('0x2b'),'parent':_0x11cbac+'_voice_agents','table':_0x2ae5ce('0x57'),'conditions':_0x2ae5ce('0xa4')},{'id':0x1d,'name':_0x2ae5ce('0x5a'),'description':_0x2ae5ce('0x33'),'parent':_0x11cbac+_0x2ae5ce('0x9c'),'table':_0x2ae5ce('0x1a'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[]}}'},{'id':0x1e,'name':_0x2ae5ce('0x3f'),'description':_0x2ae5ce('0x3b'),'parent':_0x11cbac+_0x2ae5ce('0x9c'),'table':_0x2ae5ce('0x94'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[]}}'},{'id':0x1f,'name':'Rating\x20by\x20Agent','description':_0x2ae5ce('0x8b'),'parent':_0x11cbac+_0x2ae5ce('0x65'),'table':'voice_recordings','conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22>\x22,\x22field\x22:\x22rating\x22,\x22value\x22:\x220\x22,\x22required\x22:true}]}}'},{'id':0x20,'name':_0x2ae5ce('0x30'),'description':_0x2ae5ce('0x29'),'parent':_0x11cbac+'_voice_recordings','table':_0x2ae5ce('0xac'),'conditions':_0x2ae5ce('0x28')},{'id':0x21,'name':_0x2ae5ce('0x9f'),'description':'','parent':_0x11cbac+_0x2ae5ce('0x6a'),'table':_0x2ae5ce('0x6c'),'conditions':_0x2ae5ce('0x56')},{'id':0x22,'name':_0x2ae5ce('0xa7'),'description':'','parent':_0x11cbac+_0x2ae5ce('0x6a'),'table':_0x2ae5ce('0x9e'),'conditions':_0x2ae5ce('0x56')},{'id':0x23,'name':_0x2ae5ce('0xaa'),'description':'','parent':_0x11cbac+'_bull_queue_campaigns','table':_0x2ae5ce('0x6c'),'conditions':_0x2ae5ce('0x56')},{'id':0x24,'name':_0x2ae5ce('0x9a'),'description':'','parent':_0x11cbac+_0x2ae5ce('0x6a'),'table':_0x2ae5ce('0x6c'),'conditions':_0x2ae5ce('0x56')},{'id':0x25,'name':_0x2ae5ce('0x96'),'description':'','parent':_0x11cbac+_0x2ae5ce('0x6a'),'table':_0x2ae5ce('0x6c'),'conditions':_0x2ae5ce('0x83')},{'id':0x26,'name':_0x2ae5ce('0x4c'),'description':'','parent':_0x11cbac+_0x2ae5ce('0x6a'),'table':_0x2ae5ce('0x6c'),'conditions':_0x2ae5ce('0x32')},{'id':0x27,'name':_0x2ae5ce('0x3d'),'description':'','parent':_0x11cbac+'_bull_queue_campaigns','table':'cm_hopper_final','conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27queue\x27\x22},{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22disposition\x22,\x22value\x22:\x22\x22},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22state\x22,\x22value\x22:\x224\x22}]}}'},{'id':0x28,'name':_0x2ae5ce('0x9f'),'description':'','parent':_0x11cbac+_0x2ae5ce('0x93'),'table':_0x2ae5ce('0x6c'),'conditions':_0x2ae5ce('0x63')},{'id':0x29,'name':'Calls\x20Summary','description':'','parent':_0x11cbac+'_bull_ivr_campaigns','table':_0x2ae5ce('0x9e'),'conditions':_0x2ae5ce('0x63')},{'id':0x2a,'name':_0x2ae5ce('0xaa'),'description':'','parent':_0x11cbac+_0x2ae5ce('0x93'),'table':'cm_hopper_final','conditions':_0x2ae5ce('0x63')},{'id':0x2b,'name':_0x2ae5ce('0x9a'),'description':'','parent':_0x11cbac+_0x2ae5ce('0x93'),'table':_0x2ae5ce('0x6c'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27ivr\x27\x22}]}}'},{'id':0x2c,'name':_0x2ae5ce('0x1d'),'description':_0x2ae5ce('0xa8'),'parent':_0x11cbac+'_chat','table':_0x2ae5ce('0x2d'),'joins':_0x2ae5ce('0x42')},{'id':0x2d,'name':_0x2ae5ce('0xa1'),'description':_0x2ae5ce('0x8c'),'parent':_0x11cbac+'_chat','table':_0x2ae5ce('0x2d'),'conditions':_0x2ae5ce('0x84'),'joins':_0x2ae5ce('0x42')},{'id':0x2e,'name':'Chat\x20By\x20Agent','description':_0x2ae5ce('0x72'),'parent':_0x11cbac+_0x2ae5ce('0x5'),'table':_0x2ae5ce('0x2d'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22chat_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','joins':_0x2ae5ce('0x82')},{'id':0x2f,'name':'Chat\x20By\x20Date','description':_0x2ae5ce('0x79'),'parent':_0x11cbac+_0x2ae5ce('0x5'),'table':_0x2ae5ce('0x2d'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22chat_interactions.closed\x22,\x22value\x22:\x221\x22}]}}'},{'id':0x30,'name':_0x2ae5ce('0x24'),'description':_0x2ae5ce('0x64'),'parent':_0x11cbac+'_chat','table':_0x2ae5ce('0x99'),'joins':_0x2ae5ce('0x21')},{'id':0x31,'name':_0x2ae5ce('0x73'),'description':_0x2ae5ce('0x6b'),'parent':_0x11cbac+_0x2ae5ce('0x59'),'table':_0x2ae5ce('0x38'),'joins':_0x2ae5ce('0x12')},{'id':0x32,'name':_0x2ae5ce('0x2c'),'description':_0x2ae5ce('0x6e'),'parent':_0x11cbac+_0x2ae5ce('0x59'),'table':'mail_interactions','conditions':_0x2ae5ce('0x87'),'joins':_0x2ae5ce('0x12')},{'id':0x33,'name':_0x2ae5ce('0x18'),'description':_0x2ae5ce('0x88'),'parent':_0x11cbac+_0x2ae5ce('0x59'),'table':_0x2ae5ce('0x38'),'conditions':_0x2ae5ce('0x2a'),'joins':'[{\x22parentKey\x22:\x22UserId\x22,\x22foreignTable\x22:\x22users\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x34,'name':_0x2ae5ce('0x8f'),'description':_0x2ae5ce('0x11'),'parent':_0x11cbac+'_mail','table':_0x2ae5ce('0x38'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22mail_interactions.closed\x22,\x22value\x22:\x221\x22}]}}'},{'id':0x35,'name':_0x2ae5ce('0x19'),'description':'Email\x20interactions\x20by\x20queue','parent':_0x11cbac+_0x2ae5ce('0x59'),'table':'report_mail_queue','joins':_0x2ae5ce('0x70')},{'id':0x36,'name':_0x2ae5ce('0x15'),'description':'Openchannel\x20interactions\x20by\x20account','parent':_0x11cbac+_0x2ae5ce('0x10'),'table':_0x2ae5ce('0x97'),'joins':_0x2ae5ce('0x7b')},{'id':0x37,'name':_0x2ae5ce('0x52'),'description':'Openchannel\x20interaction\x20times\x20by\x20account','parent':_0x11cbac+_0x2ae5ce('0x10'),'table':_0x2ae5ce('0x97'),'conditions':_0x2ae5ce('0x45'),'joins':_0x2ae5ce('0x7b')},{'id':0x38,'name':_0x2ae5ce('0x7f'),'description':_0x2ae5ce('0x61'),'parent':_0x11cbac+_0x2ae5ce('0x10'),'table':_0x2ae5ce('0x97'),'conditions':_0x2ae5ce('0x49'),'joins':_0x2ae5ce('0x82')},{'id':0x39,'name':'Openchannel\x20By\x20Date','description':_0x2ae5ce('0x4d'),'parent':_0x11cbac+_0x2ae5ce('0x10'),'table':'openchannel_interactions','conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22openchannel_interactions.closed\x22,\x22value\x22:\x221\x22}]}}'},{'id':0x3a,'name':_0x2ae5ce('0xa'),'description':_0x2ae5ce('0x2f'),'parent':_0x11cbac+_0x2ae5ce('0x10'),'table':_0x2ae5ce('0xa9'),'joins':_0x2ae5ce('0x43')},{'id':0x3b,'name':_0x2ae5ce('0x55'),'description':_0x2ae5ce('0x44'),'parent':_0x11cbac+_0x2ae5ce('0x62'),'table':_0x2ae5ce('0x2'),'joins':'[{\x22parentKey\x22:\x22SmsAccountId\x22,\x22foreignTable\x22:\x22sms_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x3c,'name':'Sms\x20Account\x20Times','description':_0x2ae5ce('0x7c'),'parent':_0x11cbac+_0x2ae5ce('0x62'),'table':_0x2ae5ce('0x2'),'conditions':_0x2ae5ce('0x25'),'joins':_0x2ae5ce('0x77')},{'id':0x3d,'name':_0x2ae5ce('0xb'),'description':_0x2ae5ce('0x7d'),'parent':_0x11cbac+_0x2ae5ce('0x62'),'table':'sms_interactions','conditions':_0x2ae5ce('0x78'),'joins':_0x2ae5ce('0x82')},{'id':0x3e,'name':_0x2ae5ce('0x36'),'description':_0x2ae5ce('0x91'),'parent':_0x11cbac+_0x2ae5ce('0x62'),'table':_0x2ae5ce('0x2'),'conditions':_0x2ae5ce('0x78')},{'id':0x3f,'name':_0x2ae5ce('0xab'),'description':_0x2ae5ce('0x40'),'parent':_0x11cbac+_0x2ae5ce('0x62'),'table':'report_sms_queue','joins':_0x2ae5ce('0x53')},{'id':0x40,'name':_0x2ae5ce('0x92'),'description':'Fax\x20interactions\x20by\x20account','parent':_0x11cbac+_0x2ae5ce('0x8'),'table':_0x2ae5ce('0x1e'),'joins':'[{\x22parentKey\x22:\x22FaxAccountId\x22,\x22foreignTable\x22:\x22fax_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x41,'name':'Fax\x20Account\x20Times','description':_0x2ae5ce('0x9d'),'parent':_0x11cbac+_0x2ae5ce('0x8'),'table':'fax_interactions','conditions':_0x2ae5ce('0x8e'),'joins':'[{\x22parentKey\x22:\x22FaxAccountId\x22,\x22foreignTable\x22:\x22fax_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x42,'name':_0x2ae5ce('0xa6'),'description':'Fax\x20interactions\x20by\x20agent','parent':_0x11cbac+'_fax','table':_0x2ae5ce('0x1e'),'conditions':_0x2ae5ce('0x1'),'joins':'[{\x22parentKey\x22:\x22UserId\x22,\x22foreignTable\x22:\x22users\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x43,'name':_0x2ae5ce('0x58'),'description':_0x2ae5ce('0xae'),'parent':_0x11cbac+_0x2ae5ce('0x8'),'table':_0x2ae5ce('0x1e'),'conditions':_0x2ae5ce('0x1')},{'id':0x44,'name':_0x2ae5ce('0x50'),'description':_0x2ae5ce('0x26'),'parent':_0x11cbac+_0x2ae5ce('0x8'),'table':'report_fax_queue','joins':_0x2ae5ce('0x34')},{'id':0x45,'name':_0x2ae5ce('0x66'),'description':_0x2ae5ce('0x98'),'parent':_0x11cbac+_0x2ae5ce('0xe'),'table':'whatsapp_interactions','joins':_0x2ae5ce('0x69')},{'id':0x46,'name':_0x2ae5ce('0x1c'),'description':_0x2ae5ce('0x5e'),'parent':_0x11cbac+_0x2ae5ce('0xe'),'table':_0x2ae5ce('0x7e'),'conditions':_0x2ae5ce('0x71'),'joins':'[{\x22parentKey\x22:\x22WhatsappAccountId\x22,\x22foreignTable\x22:\x22whatsapp_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x47,'name':_0x2ae5ce('0x5b'),'description':_0x2ae5ce('0x48'),'parent':_0x11cbac+'_whatsapp','table':_0x2ae5ce('0x7e'),'conditions':_0x2ae5ce('0x4a'),'joins':'[{\x22parentKey\x22:\x22UserId\x22,\x22foreignTable\x22:\x22users\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x48,'name':'WhatsApp\x20By\x20Date','description':_0x2ae5ce('0x39'),'parent':_0x11cbac+'_whatsapp','table':_0x2ae5ce('0x7e'),'conditions':_0x2ae5ce('0x4a')},{'id':0x49,'name':_0x2ae5ce('0x22'),'description':'WhatsApp\x20interactions\x20by\x20queue','parent':_0x11cbac+_0x2ae5ce('0xe'),'table':_0x2ae5ce('0x1f'),'joins':_0x2ae5ce('0x46')},{'id':0x4a,'name':_0x2ae5ce('0x4'),'description':_0x2ae5ce('0x89'),'parent':_0x11cbac+_0x2ae5ce('0x65'),'table':_0x2ae5ce('0xac'),'conditions':_0x2ae5ce('0x9'),'joins':_0x2ae5ce('0x82')},{'id':0x4b,'name':_0x2ae5ce('0xa3'),'description':'Sentiment\x20Summary','parent':_0x11cbac+_0x2ae5ce('0x65'),'table':_0x2ae5ce('0xac'),'conditions':_0x2ae5ce('0x8d')}];}; \ No newline at end of file +var a868_0x160a=['Chat\x20interactions\x20by\x20agent','Fax\x20interactions\x20by\x20agent','Outbound\x20Calls\x20by\x20Date','Fax\x20Account\x20Times','[{\x22parentKey\x22:\x22MailAccountId\x22,\x22foreignTable\x22:\x22mail_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Details','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27PAUSE\x27\x22,\x22required\x22:true},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22channel\x22,\x22value\x22:\x22\x27voice\x27\x22,\x22required\x22:true}]}}','Answer\x20time\x20\x20by\x20hour','Simple\x20queue\x20calls\x20overview','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27queue\x27\x22}]}}','Openchannel\x20Account\x20Summary','_bull_ivr_campaigns','Login\x20Time','Detailed\x20queues\x20report','WhatsApp\x20interactions\x20by\x20agent','Openchannel\x20By\x20Agent','_voice_agents','WhatsApp\x20By\x20Agent','Chat\x20interactions\x20by\x20date','CallySquare\x20Summary','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22openchannel_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','_whatsapp','voice_recordings','_openchannel','whatsapp_interactions','Calls\x20by\x20Hour','mail_interactions','Chat\x20interactions\x20by\x20website','Openchannel\x20interactions\x20by\x20account','[{\x22parentKey\x22:\x22OpenchannelAccountId\x22,\x22foreignTable\x22:\x22openchannel_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Calls\x20by\x20Queue','Calls\x20Result','report_fax_queue','_voice_queues','Sms\x20By\x20Date','Website\x20Summary','Fax\x20By\x20Queue','chat_interactions','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22sms_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','_agents','Email\x20By\x20Queue','fax_interactions','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22voice_recordings.sentiment\x22,\x22value\x22:\x22NULL\x22}]}}','List\x20Penetration\x20Rate','Calls\x20distribution\x20by\x20day\x20of\x20the\x20month','Agent\x20Calls','Abandon\x20Time\x20by\x20Queue','Fax\x20By\x20Agent','Queues\x20answer\x20time\x20performance','report_agent','Chat\x20interaction\x20times\x20by\x20website','_sms','report_member','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22channel\x22,\x22value\x22:\x22\x27voice\x27\x22,\x22required\x22:true}]}}','Openchannel\x20By\x20Queue','[{\x22parentKey\x22:\x22SmsAccountId\x22,\x22foreignTable\x22:\x22sms_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Outbound\x20Calls\x20Disposition','openchannel_interactions','Detailed\x20report\x20about\x20answered\x20queue\x20calls','Pause\x20Details','Summary\x20report\x20of\x20the\x20calls\x20type','WhatsApp\x20interactions\x20by\x20date','WhatsApp\x20Account\x20Times','Calls\x20distribution\x20by\x20hour','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22fax_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','Openchannel\x20interactions\x20by\x20agent','_voice_queues_distribution','Unanswered\x20by\x20Queue','Summary','WhatsApp\x20interactions\x20by\x20queue','Fax\x20Account\x20Summary','Answer\x20Time\x20by\x20Queue','Calls\x20by\x20Day','Abandon\x20time\x20performance\x20by\x20queue','Sms\x20By\x20Agent','Email\x20interactions\x20by\x20account','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22chat_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','Fax\x20interactions\x20by\x20queue','[{\x22parentKey\x22:\x22MailQueueId\x22,\x22foreignTable\x22:\x22mail_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27outbound\x27\x22,\x22required\x22:true}]}}','Chat\x20By\x20Agent','Chat\x20By\x20Queue','Queue\x20calls\x20summary\x20by\x20date','[{\x22parentKey\x22:\x22WhatsappQueueId\x22,\x22foreignTable\x22:\x22whatsapp_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','[{\x22parentKey\x22:\x22ChatWebsiteId\x22,\x22foreignTable\x22:\x22chat_websites\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Sms\x20interactions\x20by\x20date','[{\x22parentKey\x22:\x22UserId\x22,\x22foreignTable\x22:\x22users\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','[{\x22parentKey\x22:\x22ChatQueueId\x22,\x22foreignTable\x22:\x22chat_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Email\x20By\x20Date','CallySquare\x20Blocks\x20Detail','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22voice_recordings.sentiment\x22,\x22value\x22:\x22\x22}]}}','Sms\x20interactions\x20by\x20queue','Agent\x20Disposition\x20Rate','Summary\x20of\x20outbound\x20calls\x20grouped\x20by\x20date','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22queuecallercomplete\x22,\x22value\x22:\x220\x22,\x22required\x22:true}]}}','_voice_calls','Calls\x20by\x20Weekday','Rating\x20by\x20Agent','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22mail_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','[{\x22parentKey\x22:\x22WhatsappAccountId\x22,\x22foreignTable\x22:\x22whatsapp_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Calls\x20by\x20Agent','report_queue','Sms\x20interaction\x20times\x20by\x20account','report_sms_queue','Sms\x20interactions\x20by\x20account','Email\x20interactions\x20by\x20queue','Openchannel\x20Account\x20Times','_mail','Email\x20interactions\x20by\x20agent','_fax','Agent\x27s\x20activities\x20report','Sms\x20Account\x20Summary','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22channel\x22,\x22value\x22:\x22\x27voice\x27\x22,\x22required\x22:true},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27PAUSE\x27\x22,\x22required\x22:true}]}}','Outbound','Calls\x20Summary','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27queue\x27\x22},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22state\x22,\x22value\x22:\x224\x22}]}}','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22queuecallerexit\x22,\x22value\x22:\x221\x22,\x22required\x22:true}]}}','Rating\x20by\x20Queue','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22whatsapp_interactions.closed\x22,\x22value\x22:\x221\x22}]}}','WhatsApp\x20interactions\x20by\x20account','sms_interactions','Agents\x20status\x20details','Detailed\x20report\x20about\x20the\x20unanswered\x20calls','[{\x22parentKey\x22:\x22FaxQueueId\x22,\x22foreignTable\x22:\x22fax_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','cm_hopper_final','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27LOGIN\x27\x22,\x22required\x22:true},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22channel\x22,\x22value\x22:\x22\x27voice\x27\x22,\x22required\x22:true}]}}','Openchannel\x20By\x20Date','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22fax_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22fax_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22fax_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22>\x22,\x22field\x22:\x22rating\x22,\x22value\x22:\x220\x22,\x22required\x22:true}]}}','_voice_queues_answered','Sentiment\x20Summary','Disconnection\x20Cause','_voice_callysquare','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22whatsapp_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22whatsapp_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22whatsapp_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22queue\x22,\x22value\x22:\x22\x22,\x22required\x22:false},{\x22condition\x22:\x22>\x22,\x22field\x22:\x22rating\x22,\x22value\x22:\x220\x22,\x22required\x22:true}]}}','Email\x20interaction\x20times\x20by\x20account','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22openchannel_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22openchannel_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22openchannel_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','Activities\x20Summary','Queue\x20timer\x20Handle\x20Time=\x20Talk\x20Time\x20+\x20AVG\x20TIme','Sentiment\x20by\x20agent','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[]}}','Email\x20interactions\x20by\x20date','Openchannel\x20interaction\x20times\x20by\x20account','Agent\x27s\x20pause\x20time','WhatsApp\x20interaction\x20times\x20by\x20account','Campaign\x20Calls','cm_hopper_history','report_square_details','Email\x20By\x20Agent','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27ivr\x27\x22}]}}','_chat','[{\x22parentKey\x22:\x22FaxAccountId\x22,\x22foreignTable\x22:\x22fax_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22queuecallerabandon\x22,\x22value\x22:\x221\x22,\x22required\x22:true}]}}','_bull_queue_campaigns','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27queue\x27\x22},{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22disposition\x22,\x22value\x22:\x22\x22},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22state\x22,\x22value\x22:\x224\x22}]}}','Sms\x20By\x20Queue','_voice_recordings','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22agentcomplete\x22,\x22value\x22:\x221\x22,\x22required\x22:true}]}}','{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22sms_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22sms_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22sms_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','report_call','Unmanaged\x20calls','Fax\x20interactions\x20by\x20date','[{\x22parentKey\x22:\x22OpenchannelQueueId\x22,\x22foreignTable\x22:\x22openchannel_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]','Pause\x20Time','Manual\x20outbound\x20calls\x20detailed\x20report'];(function(_0x216369,_0x160a5a){var _0x53dffc=function(_0x26426b){while(--_0x26426b){_0x216369['push'](_0x216369['shift']());}};_0x53dffc(++_0x160a5a);}(a868_0x160a,0x90));var a868_0x53df=function(_0x216369,_0x160a5a){_0x216369=_0x216369-0x0;var _0x53dffc=a868_0x160a[_0x216369];return _0x53dffc;};'use strict';module['exports']=function(_0x26426b){var _0x1ac95d=a868_0x53df;return[{'id':0x1,'name':_0x1ac95d('0x1a'),'description':_0x1ac95d('0x22'),'parent':_0x26426b+'_voice_queues','table':'report_queue','conditions':_0x1ac95d('0xa1')},{'id':0x2,'name':_0x1ac95d('0x34'),'description':_0x1ac95d('0x1d'),'parent':_0x26426b+_0x1ac95d('0x36'),'table':_0x1ac95d('0x7a'),'conditions':_0x1ac95d('0xa1')},{'id':0x3,'name':'Details','description':_0x1ac95d('0x4f'),'parent':_0x26426b+_0x1ac95d('0x96'),'table':_0x1ac95d('0x46'),'conditions':_0x1ac95d('0xd')},{'id':0x4,'name':_0x1ac95d('0x79'),'description':'Agent\x20calls\x20timer\x20Handle\x20time=\x20talk\x20time\x20+\x20ACW\x20time','parent':_0x26426b+_0x1ac95d('0x96'),'table':_0x1ac95d('0x46'),'conditions':_0x1ac95d('0xd')},{'id':0x5,'name':_0x1ac95d('0x33'),'description':_0x1ac95d('0x9f'),'parent':_0x26426b+_0x1ac95d('0x96'),'table':_0x1ac95d('0x46'),'conditions':_0x1ac95d('0xd')},{'id':0x6,'name':_0x1ac95d('0x5c'),'description':_0x1ac95d('0x45'),'parent':_0x26426b+_0x1ac95d('0x96'),'table':'report_agent','conditions':_0x1ac95d('0xd')},{'id':0x7,'name':_0x1ac95d('0x98'),'description':'Summary\x20of\x20the\x20calls\x20disconnection\x20causes','parent':_0x26426b+_0x1ac95d('0x96'),'table':_0x1ac95d('0x46'),'conditions':_0x1ac95d('0xd')},{'id':0x8,'name':'Answer\x20Time\x20by\x20Hour','description':_0x1ac95d('0x1c'),'parent':_0x26426b+_0x1ac95d('0x96'),'table':'report_agent','conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22agentcomplete\x22,\x22value\x22:\x221\x22,\x22required\x22:true}]}}'},{'id':0x9,'name':_0x1ac95d('0x1a'),'description':_0x1ac95d('0x8f'),'parent':_0x26426b+'_voice_queues_unanswered','table':_0x1ac95d('0x7a'),'conditions':_0x1ac95d('0x73')},{'id':0xa,'name':_0x1ac95d('0x58'),'description':'Unanswered\x20calls\x20summary\x20by\x20queue','parent':_0x26426b+'_voice_queues_unanswered','table':'report_queue','conditions':_0x1ac95d('0x73')},{'id':0xb,'name':_0x1ac95d('0x10'),'description':'Unmanaged\x20calls\x20summary','parent':_0x26426b+'_voice_queues_unanswered','table':'report_queue','conditions':_0x1ac95d('0x89')},{'id':0xc,'name':_0x1ac95d('0x43'),'description':_0x1ac95d('0x5e'),'parent':_0x26426b+'_voice_queues_unanswered','table':'report_queue','conditions':_0x1ac95d('0x8')},{'id':0xd,'name':'Calls\x20by\x20Date','description':_0x1ac95d('0x67'),'parent':_0x26426b+_0x1ac95d('0x57'),'table':_0x1ac95d('0x7a'),'conditions':_0x1ac95d('0xa1')},{'id':0xe,'name':_0x1ac95d('0x2e'),'description':_0x1ac95d('0x54'),'parent':_0x26426b+_0x1ac95d('0x57'),'table':'report_queue','conditions':_0x1ac95d('0xa1')},{'id':0xf,'name':_0x1ac95d('0x5d'),'description':_0x1ac95d('0x41'),'parent':_0x26426b+_0x1ac95d('0x57'),'table':'report_queue','conditions':_0x1ac95d('0xa1')},{'id':0x10,'name':_0x1ac95d('0x75'),'description':'Calls\x20distribution\x20by\x20day\x20of\x20the\x20week','parent':_0x26426b+'_voice_queues_distribution','table':_0x1ac95d('0x7a'),'conditions':_0x1ac95d('0xa1')},{'id':0x11,'name':_0x1ac95d('0x59'),'description':'Calls\x20distribution\x20by\x20queue','parent':_0x26426b+_0x1ac95d('0x36'),'table':_0x1ac95d('0x7a'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[]}}'},{'id':0x12,'name':'Details','description':'Calls\x20detail\x20(cdr)','parent':_0x26426b+_0x1ac95d('0x74'),'table':_0x1ac95d('0xf'),'conditions':_0x1ac95d('0xa1')},{'id':0x13,'name':_0x1ac95d('0x86'),'description':_0x1ac95d('0x14'),'parent':_0x26426b+_0x1ac95d('0x74'),'table':_0x1ac95d('0xf'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27outbound\x27\x22,\x22required\x22:true}]}}'},{'id':0x14,'name':'Calls\x20by\x20Type','description':_0x1ac95d('0x51'),'parent':_0x26426b+'_voice_calls','table':_0x1ac95d('0xf'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[]}}'},{'id':0x15,'name':_0x1ac95d('0x4d'),'description':'Outbound\x20calls\x20grouped\x20by\x20disposition','parent':_0x26426b+_0x1ac95d('0x74'),'table':_0x1ac95d('0xf'),'conditions':_0x1ac95d('0x64')},{'id':0x16,'name':'Outbound\x20Calls\x20by\x20Agent','description':'Summary\x20of\x20outbound\x20calls\x20grouped\x20by\x20agent','parent':_0x26426b+_0x1ac95d('0x74'),'table':_0x1ac95d('0xf'),'conditions':_0x1ac95d('0x64')},{'id':0x17,'name':_0x1ac95d('0x17'),'description':_0x1ac95d('0x72'),'parent':_0x26426b+_0x1ac95d('0x74'),'table':_0x1ac95d('0xf'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22type\x22,\x22value\x22:\x22\x27outbound\x27\x22,\x22required\x22:true}]}}'},{'id':0x18,'name':_0x1ac95d('0x21'),'description':'Agent\x27s\x20login\x20time','parent':_0x26426b+_0x1ac95d('0x3c'),'table':_0x1ac95d('0x49'),'conditions':_0x1ac95d('0x92')},{'id':0x19,'name':_0x1ac95d('0x9e'),'description':_0x1ac95d('0x83'),'parent':_0x26426b+'_voice_agents','table':_0x1ac95d('0x49'),'conditions':_0x1ac95d('0x4a')},{'id':0x1a,'name':_0x1ac95d('0x50'),'description':_0x1ac95d('0x8e'),'parent':_0x26426b+_0x1ac95d('0x25'),'table':_0x1ac95d('0x49'),'conditions':_0x1ac95d('0x85')},{'id':0x1b,'name':'Details','description':'Agent\x27s\x20status\x20detail','parent':_0x26426b+_0x1ac95d('0x25'),'table':_0x1ac95d('0x49'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22channel\x22,\x22value\x22:\x22\x27voice\x27\x22,\x22required\x22:true}]}}'},{'id':0x1c,'name':_0x1ac95d('0x13'),'description':_0x1ac95d('0xa4'),'parent':_0x26426b+_0x1ac95d('0x25'),'table':_0x1ac95d('0x49'),'conditions':_0x1ac95d('0x1b')},{'id':0x1d,'name':_0x1ac95d('0x59'),'description':_0x1ac95d('0x28'),'parent':_0x26426b+'_voice_callysquare','table':'report_square','conditions':_0x1ac95d('0xa1')},{'id':0x1e,'name':'Blocks','description':_0x1ac95d('0x6e'),'parent':_0x26426b+_0x1ac95d('0x99'),'table':_0x1ac95d('0x3'),'conditions':_0x1ac95d('0xa1')},{'id':0x1f,'name':_0x1ac95d('0x76'),'description':'Records\x20rating\x20by\x20agent','parent':_0x26426b+_0x1ac95d('0xc'),'table':_0x1ac95d('0x2b'),'conditions':_0x1ac95d('0x95')},{'id':0x20,'name':_0x1ac95d('0x8a'),'description':'Records\x20rating\x20by\x20queue','parent':_0x26426b+_0x1ac95d('0xc'),'table':_0x1ac95d('0x2b'),'conditions':_0x1ac95d('0x9b')},{'id':0x21,'name':_0x1ac95d('0x1a'),'description':'','parent':_0x26426b+_0x1ac95d('0x9'),'table':'cm_hopper_final','conditions':_0x1ac95d('0x1e')},{'id':0x22,'name':_0x1ac95d('0x87'),'description':'','parent':_0x26426b+'_bull_queue_campaigns','table':_0x1ac95d('0x2'),'conditions':_0x1ac95d('0x1e')},{'id':0x23,'name':_0x1ac95d('0x1'),'description':'','parent':_0x26426b+_0x1ac95d('0x9'),'table':_0x1ac95d('0x91'),'conditions':_0x1ac95d('0x1e')},{'id':0x24,'name':_0x1ac95d('0x40'),'description':'','parent':_0x26426b+_0x1ac95d('0x9'),'table':_0x1ac95d('0x91'),'conditions':_0x1ac95d('0x1e')},{'id':0x25,'name':_0x1ac95d('0x42'),'description':'','parent':_0x26426b+_0x1ac95d('0x9'),'table':'cm_hopper_final','conditions':_0x1ac95d('0x88')},{'id':0x26,'name':'Disposition\x20Rate','description':'','parent':_0x26426b+_0x1ac95d('0x9'),'table':_0x1ac95d('0x91'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27queue\x27\x22},{\x22condition\x22:\x22IS\x20NOT\x20NULL\x22,\x22field\x22:\x22disposition\x22,\x22value\x22:\x22\x22},{\x22condition\x22:\x22=\x22,\x22field\x22:\x22state\x22,\x22value\x22:\x224\x22}]}}'},{'id':0x27,'name':_0x1ac95d('0x71'),'description':'','parent':_0x26426b+'_bull_queue_campaigns','table':_0x1ac95d('0x91'),'conditions':_0x1ac95d('0xa')},{'id':0x28,'name':_0x1ac95d('0x1a'),'description':'','parent':_0x26426b+_0x1ac95d('0x20'),'table':_0x1ac95d('0x91'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27ivr\x27\x22}]}}'},{'id':0x29,'name':'Calls\x20Summary','description':'','parent':_0x26426b+_0x1ac95d('0x20'),'table':_0x1ac95d('0x2'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22campaigntype\x22,\x22value\x22:\x22\x27ivr\x27\x22}]}}'},{'id':0x2a,'name':'Campaign\x20Calls','description':'','parent':_0x26426b+_0x1ac95d('0x20'),'table':_0x1ac95d('0x91'),'conditions':_0x1ac95d('0x5')},{'id':0x2b,'name':_0x1ac95d('0x40'),'description':'','parent':_0x26426b+_0x1ac95d('0x20'),'table':_0x1ac95d('0x91'),'conditions':_0x1ac95d('0x5')},{'id':0x2c,'name':_0x1ac95d('0x38'),'description':_0x1ac95d('0x30'),'parent':_0x26426b+_0x1ac95d('0x6'),'table':_0x1ac95d('0x3a'),'joins':_0x1ac95d('0x69')},{'id':0x2d,'name':'Website\x20Times','description':_0x1ac95d('0x47'),'parent':_0x26426b+_0x1ac95d('0x6'),'table':_0x1ac95d('0x3a'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22chat_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22chat_interactions.disposition\x22,\x22value\x22:\x22\x22},{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22chat_interactions.disposition\x22,\x22value\x22:\x22\x27abandoned\x27\x22},{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22chat_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22}]}}]}}]}}','joins':_0x1ac95d('0x69')},{'id':0x2e,'name':_0x1ac95d('0x65'),'description':_0x1ac95d('0x15'),'parent':_0x26426b+_0x1ac95d('0x6'),'table':_0x1ac95d('0x3a'),'conditions':_0x1ac95d('0x61'),'joins':_0x1ac95d('0x6b')},{'id':0x2f,'name':'Chat\x20By\x20Date','description':_0x1ac95d('0x27'),'parent':_0x26426b+'_chat','table':_0x1ac95d('0x3a'),'conditions':_0x1ac95d('0x61')},{'id':0x30,'name':_0x1ac95d('0x66'),'description':'Chat\x20interactions\x20by\x20queue','parent':_0x26426b+_0x1ac95d('0x6'),'table':'report_chat_queue','joins':_0x1ac95d('0x6c')},{'id':0x31,'name':'Email\x20Account\x20Summary','description':_0x1ac95d('0x60'),'parent':_0x26426b+_0x1ac95d('0x80'),'table':_0x1ac95d('0x2f'),'joins':'[{\x22parentKey\x22:\x22MailAccountId\x22,\x22foreignTable\x22:\x22mail_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x32,'name':'Email\x20Account\x20Times','description':_0x1ac95d('0x9c'),'parent':_0x26426b+_0x1ac95d('0x80'),'table':'mail_interactions','conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22mail_interactions.closed\x22,\x22value\x22:\x221\x22},{\x22group\x22:{\x22operator\x22:\x22OR\x22,\x22rules\x22:[{\x22condition\x22:\x22!=\x22,\x22field\x22:\x22mail_interactions.disposition\x22,\x22value\x22:\x22\x27unmanaged\x27\x22},{\x22condition\x22:\x22IS\x20NULL\x22,\x22field\x22:\x22mail_interactions.disposition\x22,\x22value\x22:\x22\x22}]}}]}}','joins':_0x1ac95d('0x19')},{'id':0x33,'name':_0x1ac95d('0x4'),'description':_0x1ac95d('0x81'),'parent':_0x26426b+_0x1ac95d('0x80'),'table':_0x1ac95d('0x2f'),'conditions':_0x1ac95d('0x77'),'joins':_0x1ac95d('0x6b')},{'id':0x34,'name':_0x1ac95d('0x6d'),'description':_0x1ac95d('0xa2'),'parent':_0x26426b+_0x1ac95d('0x80'),'table':_0x1ac95d('0x2f'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22mail_interactions.closed\x22,\x22value\x22:\x221\x22}]}}'},{'id':0x35,'name':_0x1ac95d('0x3d'),'description':_0x1ac95d('0x7e'),'parent':_0x26426b+'_mail','table':'report_mail_queue','joins':_0x1ac95d('0x63')},{'id':0x36,'name':_0x1ac95d('0x1f'),'description':_0x1ac95d('0x31'),'parent':_0x26426b+'_openchannel','table':_0x1ac95d('0x4e'),'joins':'[{\x22parentKey\x22:\x22OpenchannelAccountId\x22,\x22foreignTable\x22:\x22openchannel_accounts\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x37,'name':_0x1ac95d('0x7f'),'description':_0x1ac95d('0xa3'),'parent':_0x26426b+_0x1ac95d('0x2c'),'table':_0x1ac95d('0x4e'),'conditions':_0x1ac95d('0x9d'),'joins':_0x1ac95d('0x32')},{'id':0x38,'name':_0x1ac95d('0x24'),'description':_0x1ac95d('0x56'),'parent':_0x26426b+_0x1ac95d('0x2c'),'table':_0x1ac95d('0x4e'),'conditions':_0x1ac95d('0x29'),'joins':_0x1ac95d('0x6b')},{'id':0x39,'name':_0x1ac95d('0x93'),'description':'Openchannel\x20interactions\x20by\x20date','parent':_0x26426b+_0x1ac95d('0x2c'),'table':_0x1ac95d('0x4e'),'conditions':_0x1ac95d('0x29')},{'id':0x3a,'name':_0x1ac95d('0x4b'),'description':'Openchannel\x20interactions\x20by\x20queue','parent':_0x26426b+'_openchannel','table':'report_openchannel_queue','joins':_0x1ac95d('0x12')},{'id':0x3b,'name':_0x1ac95d('0x84'),'description':_0x1ac95d('0x7d'),'parent':_0x26426b+_0x1ac95d('0x48'),'table':'sms_interactions','joins':_0x1ac95d('0x4c')},{'id':0x3c,'name':'Sms\x20Account\x20Times','description':_0x1ac95d('0x7b'),'parent':_0x26426b+_0x1ac95d('0x48'),'table':_0x1ac95d('0x8d'),'conditions':_0x1ac95d('0xe'),'joins':_0x1ac95d('0x4c')},{'id':0x3d,'name':_0x1ac95d('0x5f'),'description':'Sms\x20interactions\x20by\x20agent','parent':_0x26426b+'_sms','table':'sms_interactions','conditions':_0x1ac95d('0x3b'),'joins':_0x1ac95d('0x6b')},{'id':0x3e,'name':_0x1ac95d('0x37'),'description':_0x1ac95d('0x6a'),'parent':_0x26426b+'_sms','table':_0x1ac95d('0x8d'),'conditions':'{\x22group\x22:{\x22operator\x22:\x22AND\x22,\x22rules\x22:[{\x22condition\x22:\x22=\x22,\x22field\x22:\x22sms_interactions.closed\x22,\x22value\x22:\x221\x22}]}}'},{'id':0x3f,'name':_0x1ac95d('0xb'),'description':_0x1ac95d('0x70'),'parent':_0x26426b+_0x1ac95d('0x48'),'table':_0x1ac95d('0x7c'),'joins':'[{\x22parentKey\x22:\x22SmsQueueId\x22,\x22foreignTable\x22:\x22sms_queues\x22,\x22foreignKey\x22:\x22id\x22,\x22type\x22:\x22join\x22}]'},{'id':0x40,'name':_0x1ac95d('0x5b'),'description':'Fax\x20interactions\x20by\x20account','parent':_0x26426b+_0x1ac95d('0x82'),'table':_0x1ac95d('0x3e'),'joins':_0x1ac95d('0x7')},{'id':0x41,'name':_0x1ac95d('0x18'),'description':'Fax\x20interaction\x20times\x20by\x20account','parent':_0x26426b+_0x1ac95d('0x82'),'table':_0x1ac95d('0x3e'),'conditions':_0x1ac95d('0x94'),'joins':_0x1ac95d('0x7')},{'id':0x42,'name':_0x1ac95d('0x44'),'description':_0x1ac95d('0x16'),'parent':_0x26426b+'_fax','table':_0x1ac95d('0x3e'),'conditions':_0x1ac95d('0x55'),'joins':_0x1ac95d('0x6b')},{'id':0x43,'name':'Fax\x20By\x20Date','description':_0x1ac95d('0x11'),'parent':_0x26426b+'_fax','table':_0x1ac95d('0x3e'),'conditions':_0x1ac95d('0x55')},{'id':0x44,'name':_0x1ac95d('0x39'),'description':_0x1ac95d('0x62'),'parent':_0x26426b+_0x1ac95d('0x82'),'table':_0x1ac95d('0x35'),'joins':_0x1ac95d('0x90')},{'id':0x45,'name':'WhatsApp\x20Account\x20Summary','description':_0x1ac95d('0x8c'),'parent':_0x26426b+_0x1ac95d('0x2a'),'table':_0x1ac95d('0x2d'),'joins':_0x1ac95d('0x78')},{'id':0x46,'name':_0x1ac95d('0x53'),'description':_0x1ac95d('0x0'),'parent':_0x26426b+'_whatsapp','table':_0x1ac95d('0x2d'),'conditions':_0x1ac95d('0x9a'),'joins':_0x1ac95d('0x78')},{'id':0x47,'name':_0x1ac95d('0x26'),'description':_0x1ac95d('0x23'),'parent':_0x26426b+_0x1ac95d('0x2a'),'table':_0x1ac95d('0x2d'),'conditions':_0x1ac95d('0x8b'),'joins':_0x1ac95d('0x6b')},{'id':0x48,'name':'WhatsApp\x20By\x20Date','description':_0x1ac95d('0x52'),'parent':_0x26426b+_0x1ac95d('0x2a'),'table':'whatsapp_interactions','conditions':_0x1ac95d('0x8b')},{'id':0x49,'name':'WhatsApp\x20By\x20Queue','description':_0x1ac95d('0x5a'),'parent':_0x26426b+_0x1ac95d('0x2a'),'table':'report_whatsapp_queue','joins':_0x1ac95d('0x68')},{'id':0x4a,'name':'Sentiment\x20by\x20Agent','description':_0x1ac95d('0xa0'),'parent':_0x26426b+_0x1ac95d('0xc'),'table':_0x1ac95d('0x2b'),'conditions':_0x1ac95d('0x3f'),'joins':_0x1ac95d('0x6b')},{'id':0x4b,'name':_0x1ac95d('0x97'),'description':'Sentiment\x20Summary','parent':_0x26426b+_0x1ac95d('0xc'),'table':_0x1ac95d('0x2b'),'conditions':_0x1ac95d('0x6f')}];}; \ No newline at end of file diff --git a/server/config/seedDB/report/fields.js b/server/config/seedDB/report/fields.js index 2e78373..0daa6c2 100644 --- a/server/config/seedDB/report/fields.js +++ b/server/config/seedDB/report/fields.js @@ -1 +1 @@ -const a869_0x555a=['HoldTime','disposition','AgentACW','reason','COUNT(IF(holdtime<10,1,NULL))','position','voice_recordings.sentiment','openchannel_interactions.createdAt','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(mail_interactions.createdAt)))','ROUND(COUNT(IF(closed=1\x20&&\x20disposition=\x27abandoned\x27,1,NULL))/COUNT(id)\x20*100,1)','UniqueID','fax_interactions.createdAt','fax_accounts.name','AVG\x20Hold\x20Time','voice_recordings.UserId','CASE\x20WHEN\x20queuecallercomplete=1\x20THEN\x20\x27YES\x27\x20ELSE\x20\x27NO\x27\x20END','sms_queues.name','agentcompleteAt','calleridnum','UNIX_TIMESTAMP(queuecallerExitAt)-UNIX_TIMESTAMP(queuecallerjoinAt)','Penetration\x20Rate','Abandoned<10s','Tot\x20ACWTime','dropreason','Interactions','AgentACWTime','Calls','Pause','TOT','chat_websites.name','QueueExitAt','COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27NEGATIVE\x27,1,NULL))','Tot\x20AbandonTime','COUNT\x20DISTINCT','type','HOUR','starttime','queuecallerjoinAt','countglobal','CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27NEUTRAL\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','Tot\x20Abandoned','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(whatsapp_interactions.createdAt)','Calls\x20(%)','Avg\x20Handle\x20Time','Hold\x20Time','AvgACWTime','Sentiment\x20TOT','ROUND(SUM(IF(state=4,1,0))/COUNT(*)*100,1)','BlackList','campaign','DID','talktime\x20+\x20acwtime','queuecallerleaveAt','CallerID','AVG\x20Talk\x20Time','COUNT(IF(closed=0,1,NULL))','queuecallercomplete','ROUND(COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=120,1,NULL))\x20\x20/\x20SUM(queuecallerabandon)\x20*100,1)','exten','Complete','billableseconds','UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)','Talk\x20Time','Abandoned\x2060-120s','COUNT(IF(holdtime\x20>=30,1,NULL))','node','COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27POSITIVE\x27,1,NULL))','Data','CallerId','DESC','Interface','Tot\x20Duration','COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=10\x20AND\x20UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<60,1,NULL))','Negative(%)','COUNT(IF(holdtime\x20>=10\x20AND\x20holdtime\x20<20,1,NULL))','TotTalkTime','Abandoned\x20(%)','sms_interactions.id','POSITIVE','QueueAbandon','sms_interactions.createdAt','Global\x20Count','openchannel_interactions.closed','LeaveAt','Answered\x2020-30s','LastApp','ROUND(COUNT(IF(holdtime\x20>=20\x20AND\x20holdtime\x20<30,1,NULL))\x20/\x20SUM(agentcomplete)\x20*100,1)','Abandon','chat_interactions.id','COUNT(IF(holdtime\x20>=20\x20AND\x20holdtime\x20<30,1,NULL))','Tot\x20HoldTime','ROUND(COUNT(id)*100/(SELECT\x20COUNT(*)\x20FROM\x20cm_hopper_final\x20WHERE\x20state=4\x20and\x20campaigntype=\x27queue\x27),2)','Login\x20Time','Unique\x20Id','COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27MIXED\x27,1,NULL))','Abandoned','UnmanagedReason','Neutral(%)','MIXED','AgentCompleteAt','dnid','blacklist','CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27MIXED\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','CASE\x20WHEN\x20type=\x27LOGIN\x27\x20THEN\x20UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)\x20END','agentcomplete','membername','Total','Total\x20Calls','Type','whatsapp_interactions.closed','groupBy','Abandoned\x2010-60s','mail_queues.name','agentconnectAt','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(chat_interactions.createdAt)','Disposition','whatsapp_accounts.name','mail_interactions.closed','ROUND(count(id)*100/(SELECT\x20COUNT(*)\x20FROM\x20cm_hopper_history\x20WHERE\x20campaigntype=\x27queue\x27),2)','Sms\x20Account','COUNT(IF(reason=\x27timeout\x27,1,NULL))','Duration','Fax\x20Account','exports','AgentCalledAt','Answer\x20Rate\x20>30s','queue','acwtime','Start\x20Time','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(openchannel_interactions.createdAt)))','QueueLeaveAt','JoinAt','COUNT(IF(closed=1,1,NULL))','ROUND(COUNT(IF(holdtime\x20>=30,1,NULL))\x20/\x20SUM(agentcomplete)\x20*100,1)','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(openchannel_interactions.createdAt)','ExitAt','COUNT(IF(closed=1\x20&&\x20disposition\x20=\x27abandoned\x27,1,NULL))','Answer\x20Rate','mail_accounts.name','ROUND(AVG(UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)))','Offered','NEUTRAL','COUNT(IF(closed=1\x20&&\x20disposition\x20=\x27unmanaged\x27,1,NULL))','AvgAbandonTime','CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27NEGATIVE\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','COUNT','answertime','report_chat_queue.id','Tot\x20Answered','Abandoned\x20Rate>120s','ROUND(AVG(duration))','AVG\x20Interaction\x20Time','destinationchannel','Destination','fax_interactions.id','data1','Project\x20Name','queuecallerexitAt','EndTime','mail_interactions.id','PauseType','Completed','calleridname','queuecallerabandon','ROUND(SUM(queuecallercomplete)/COUNT(DISTINCT\x20uniqueid)*100,1)','callerid','chat_interactions.createdAt','Abandoned\x20Rate<10s','Answered','ROUND(AVG(acwtime))','SUM(IF(state=4,1,0))','AVG','statedesc','report_whatsapp_queue.id','SEC_TO_TIME(AVG(talktime))','COUNT(IF(closed=1\x20&&\x20((disposition\x20!=\x27unmanaged\x27\x20&&\x20disposition\x20!=\x27abandoned\x27)\x20||\x20disposition\x20IS\x20NULL),1,NULL))','AbandonAt','ROUND(AVG(UNIX_TIMESTAMP(queuecallerExitAt)-UNIX_TIMESTAMP(queuecallerjoinAt)))','Source','project_name','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(sms_interactions.createdAt)','AgentExtension','Open','lodash','ROUND(COUNT(IF(holdtime\x20>=10\x20AND\x20holdtime\x20<20,1,NULL))\x20/\x20SUM(agentcomplete)\x20*100,1)','COUNT(IF(reason=\x27accepted\x27,1,NULL))','CASE\x20WHEN\x20type=\x27PAUSE\x27\x20THEN\x20UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)\x20END','Avg\x20Duration','COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<10,1,NULL))','Avg\x20TalkTime','Completed\x20(%)','DAY(queuecallerjoinat)','Abandoned>120s','NEGATIVE','holdtime','CompleteAt','AbandonTime','UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)','ROUND(AVG(UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)))','SEC_TO_TIME','Tag','State','TalkTime','ASC','Contacts','whatsapp_interactions.createdAt','endtime','agentacw','SUBSTRING_INDEX(channel,\x20\x22-\x22,\x201)','Answer\x20Rate\x20<10s','Campaign\x20Name','report_mail_queue.id','queuecallerjoinat','whatsapp_interactions.id','openchannel_accounts.name','openchannel_interactions.id','Agent','Queue','QueueExit','ROUND(AVG(holdtime))','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(sms_interactions.createdAt)))','DATE','exitAt','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(whatsapp_interactions.createdAt)))','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(createdAt)))','UniqueId','QueueJoinAt','Billsec','Date','CallerIdName','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(fax_interactions.createdAt)','Rated\x20Calls','destination','CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27POSITIVE\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','IF(queuecallercomplete=1,holdtime,null)','enterAt','LastEvent','HangupReason','Answered\x20>30s','Web\x20Site','Unmanaged\x20HoldTime','Abandoned\x20Rate\x2010-60s','AvgHandleTime','Timeout','report_openchannel_queue.id','Tot\x20Handle\x20Time','UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)','agentcalledAt','users.fullname','mail_interactions.createdAt','Total\x20Rating','AvgTalkTime','Unmanaged','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(fax_interactions.createdAt)))','ROUND(AVG(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)))','queuecallerexit','queuecallerexitreason','lastapplication','Closed','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(createdAt)','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(chat_interactions.createdAt)))','tag','SUM','Avg\x20HoldTime','Tot\x20TalkTime','openchannel_queues.name','CallerIdNum','sms_interactions.closed','LastData','AgentComplete','Hour','chat_queues.name','Interaction\x20Time','StartTime','Whatsapp\x20Account','Event','Avg\x20ACWTime','ListId','queuecallerabandonAt','ROUND(AVG(talktime))','Accepted','uniqueid','ROUND(COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=10\x20AND\x20UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<60,1,NULL))\x20\x20/\x20SUM(queuecallerabandon)\x20*100,1)','rating','UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)','Mixed(%)','DestChannel','QueueExitReason','duration','Email\x20Account','Drop\x20Reason','ROUND(COUNT(IF(closed=1,1,NULL))/COUNT(id)\x20*100,1)','Openchannel\x20Account','Managed','AgentConnectAt','Abandon\x20Time','talktime','AnswerTime','sms_accounts.name','EnterAt','Avg\x20Unmanaged\x20TIme','Answered\x20<10s'];(function(_0x4994fa,_0x555a88){const _0x39d921=function(_0x1a5a61){while(--_0x1a5a61){_0x4994fa['push'](_0x4994fa['shift']());}};_0x39d921(++_0x555a88);}(a869_0x555a,0x172));const a869_0x39d9=function(_0x4994fa,_0x555a88){_0x4994fa=_0x4994fa-0x0;let _0x39d921=a869_0x555a[_0x4994fa];return _0x39d921;};const _0x42b00e=a869_0x39d9;'use strict';const _=require(_0x42b00e('0x73'));module[_0x42b00e('0x37')]=function(){const _0x12dc95=_0x42b00e,_0x1a5a61=[{'field':'uniqueid','alias':_0x12dc95('0x9d'),'ReportId':0x1},{'field':'calleridnum','alias':_0x12dc95('0xc6'),'ReportId':0x1},{'field':'calleridname','alias':_0x12dc95('0xa1'),'ReportId':0x1},{'field':_0x12dc95('0x3a'),'alias':_0x12dc95('0x95'),'ReportId':0x1},{'field':_0x12dc95('0x10f'),'alias':_0x12dc95('0x9e'),'ReportId':0x1},{'field':_0x12dc95('0x11e'),'alias':_0x12dc95('0x3e'),'ReportId':0x1},{'field':'queuecallerabandon','alias':_0x12dc95('0xb'),'ReportId':0x1},{'field':'queuecallerabandonAt','alias':'QueueAbandonAt','ReportId':0x1},{'field':_0x12dc95('0x122'),'alias':_0x12dc95('0x125'),'ReportId':0x1},{'field':'queuecallercompleteAt','alias':_0x12dc95('0x7f'),'ReportId':0x1},{'field':_0x12dc95('0xbb'),'alias':_0x12dc95('0x96'),'ReportId':0x1},{'field':_0x12dc95('0x59'),'alias':_0x12dc95('0x108'),'ReportId':0x1},{'field':_0x12dc95('0xbc'),'alias':_0x12dc95('0xdb'),'ReportId':0x1},{'field':_0x12dc95('0x124'),'alias':_0x12dc95('0x11c'),'ReportId':0x1},{'field':_0x12dc95('0x127'),'alias':_0x12dc95('0x86'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x1},{'field':'UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)','alias':_0x12dc95('0x80'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0x1},{'field':_0x12dc95('0xa6'),'alias':_0x12dc95('0xe5'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x1},{'field':'calleridnum','alias':_0x12dc95('0x11f'),'ReportId':0x2},{'field':_0x12dc95('0x3a'),'alias':'Queue','ReportId':0x2},{'field':'queuecallerjoinAt','alias':'StartTime','ReportId':0x2},{'field':'CASE\x20WHEN\x20queuecallercomplete=1\x20THEN\x20queuecallercompleteAt\x20ELSE\x20queuecallerLeaveAt\x20END','alias':_0x12dc95('0x5a'),'custom':0x1,'ReportId':0x2},{'field':_0x12dc95('0x7e'),'alias':_0x12dc95('0xea'),'format':'SEC_TO_TIME','ReportId':0x2},{'field':_0x12dc95('0xf9'),'alias':_0x12dc95('0x64'),'custom':0x1,'ReportId':0x2},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x9d'),'ReportId':0x3},{'field':_0x12dc95('0xfc'),'alias':'CallerIdNum','ReportId':0x3},{'field':_0x12dc95('0x5e'),'alias':_0x12dc95('0xa1'),'ReportId':0x3},{'field':_0x12dc95('0x3a'),'alias':_0x12dc95('0x95'),'ReportId':0x3},{'field':_0x12dc95('0x25'),'alias':_0x12dc95('0x94'),'ReportId':0x3},{'field':_0x12dc95('0xb3'),'alias':_0x12dc95('0x38'),'ReportId':0x3},{'field':'agentconnectAt','alias':_0x12dc95('0xe2'),'ReportId':0x3},{'field':_0x12dc95('0xfb'),'alias':_0x12dc95('0x1f'),'ReportId':0x3},{'field':_0x12dc95('0x7e'),'alias':_0x12dc95('0xe5'),'ReportId':0x3},{'field':_0x12dc95('0xe4'),'alias':_0x12dc95('0x86'),'ReportId':0x3},{'field':_0x12dc95('0x8b'),'alias':_0x12dc95('0xec'),'ReportId':0x3},{'field':_0x12dc95('0x3b'),'alias':_0x12dc95('0x103'),'ReportId':0x3},{'field':_0x12dc95('0x24'),'alias':_0x12dc95('0xc9'),'ReportId':0x3},{'field':_0x12dc95('0xed'),'alias':_0x12dc95('0xa9'),'ReportId':0x3},{'field':'lastevent','alias':_0x12dc95('0xa8'),'ReportId':0x3},{'field':_0x12dc95('0x124'),'alias':_0x12dc95('0x11c'),'ReportId':0x3},{'field':_0x12dc95('0x25'),'alias':_0x12dc95('0x94'),'groupBy':0x1,'ReportId':0x4},{'field':_0x12dc95('0x24'),'alias':_0x12dc95('0x5d'),'function':_0x12dc95('0xc2'),'ReportId':0x4},{'field':_0x12dc95('0xe4'),'alias':_0x12dc95('0x7'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'ReportId':0x4},{'field':'acwtime','alias':'TotACWTime','function':'SUM','format':_0x12dc95('0x83'),'ReportId':0x4},{'field':_0x12dc95('0x11d'),'alias':'TotHandleTime','function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x4},{'field':'ROUND(AVG(talktime))','alias':_0x12dc95('0xb7'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x4},{'field':_0x12dc95('0x65'),'alias':_0x12dc95('0x117'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x4},{'field':'ROUND(SUM(talktime\x20+\x20acwtime)/COUNT(agentcomplete))','alias':_0x12dc95('0xae'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x4},{'field':_0x12dc95('0x3a'),'alias':'Queue','groupBy':0x1,'ReportId':0x5},{'field':_0x12dc95('0x24'),'alias':'Completed','function':_0x12dc95('0xc2'),'ReportId':0x5},{'field':_0x12dc95('0xe4'),'alias':_0x12dc95('0xc4'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'ReportId':0x5},{'field':_0x12dc95('0x7e'),'alias':_0x12dc95('0x16'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'ReportId':0x5},{'field':'acwtime','alias':_0x12dc95('0x100'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'ReportId':0x5},{'field':_0x12dc95('0x11d'),'alias':_0x12dc95('0xb1'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x5},{'field':_0x12dc95('0xd3'),'alias':_0x12dc95('0x79'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0x5},{'field':_0x12dc95('0x97'),'alias':_0x12dc95('0xc3'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x5},{'field':_0x12dc95('0x65'),'alias':_0x12dc95('0xd0'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x5},{'field':'ROUND(SUM(talktime\x20+\x20acwtime)/COUNT(agentcomplete))','alias':_0x12dc95('0x115'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0x5},{'field':_0x12dc95('0x3a'),'alias':_0x12dc95('0x95'),'groupBy':0x1,'ReportId':0x6},{'field':_0x12dc95('0x24'),'alias':_0x12dc95('0x50'),'function':_0x12dc95('0xc2'),'ReportId':0x6},{'field':_0x12dc95('0xee'),'alias':_0x12dc95('0xe9'),'custom':0x1,'ReportId':0x6},{'field':'ROUND(COUNT(IF(holdtime<10,1,NULL))\x20/\x20SUM(agentcomplete)\x20*100,1)','alias':_0x12dc95('0x8d'),'custom':0x1,'ReportId':0x6},{'field':_0x12dc95('0x6'),'alias':'Answered\x2010-20s','custom':0x1,'ReportId':0x6},{'field':_0x12dc95('0x74'),'alias':'Answer\x20Rate\x2010-20s','custom':0x1,'ReportId':0x6},{'field':_0x12dc95('0x15'),'alias':_0x12dc95('0x10'),'custom':0x1,'ReportId':0x6},{'field':_0x12dc95('0x12'),'alias':'Answer\x20Rate\x2020-30s','custom':0x1,'ReportId':0x6},{'field':_0x12dc95('0x12a'),'alias':_0x12dc95('0xaa'),'custom':0x1,'ReportId':0x6},{'field':_0x12dc95('0x41'),'alias':_0x12dc95('0x39'),'custom':0x1,'ReportId':0x6},{'field':_0x12dc95('0xed'),'alias':'Reason','groupBy':0x1,'ReportId':0x7},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x104'),'function':_0x12dc95('0x4d'),'ReportId':0x7},{'field':_0x12dc95('0x2d'),'alias':_0x12dc95('0xca'),'format':_0x12dc95('0x10d'),'groupBy':0x1,'ReportId':0x8},{'field':_0x12dc95('0x24'),'alias':_0x12dc95('0x50'),'function':'SUM','ReportId':0x8},{'field':'COUNT(IF(holdtime<10,1,NULL))','alias':_0x12dc95('0xe9'),'custom':0x1,'ReportId':0x8},{'field':_0x12dc95('0x6'),'alias':'Answered\x2010-20s','custom':0x1,'ReportId':0x8},{'field':_0x12dc95('0x15'),'alias':'Answered\x2020-30s','custom':0x1,'ReportId':0x8},{'field':_0x12dc95('0x12a'),'alias':_0x12dc95('0xaa'),'custom':0x1,'ReportId':0x8},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x9d'),'ReportId':0x9},{'field':'calleridnum','alias':_0x12dc95('0xc6'),'ReportId':0x9},{'field':'queue','alias':_0x12dc95('0x95'),'ReportId':0x9},{'field':_0x12dc95('0x10f'),'alias':_0x12dc95('0x3f'),'ReportId':0x9},{'field':'queuecallerleaveAt','alias':_0x12dc95('0xf'),'ReportId':0x9},{'field':_0x12dc95('0x5f'),'alias':_0x12dc95('0x13'),'ReportId':0x9},{'field':_0x12dc95('0xd2'),'alias':_0x12dc95('0x6c'),'ReportId':0x9},{'field':_0x12dc95('0xbb'),'alias':_0x12dc95('0xb8'),'ReportId':0x9},{'field':_0x12dc95('0x59'),'alias':'UnmanagedAt','ReportId':0x9},{'field':_0x12dc95('0xbc'),'alias':_0x12dc95('0x1c'),'ReportId':0x9},{'field':_0x12dc95('0xef'),'alias':'QueuePosition','ReportId':0x9},{'field':_0x12dc95('0x124'),'alias':_0x12dc95('0x11c'),'ReportId':0x9},{'field':_0x12dc95('0xd8'),'alias':_0x12dc95('0xe3'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x9},{'field':_0x12dc95('0xfd'),'alias':_0x12dc95('0xac'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x9},{'field':'queue','alias':_0x12dc95('0x95'),'groupBy':0x1,'ReportId':0xa},{'field':_0x12dc95('0x5f'),'alias':_0x12dc95('0x1b'),'function':'SUM','ReportId':0xa},{'field':'queuecallerexit','alias':'Unmanaged','function':_0x12dc95('0xc2'),'ReportId':0xa},{'field':_0x12dc95('0xd8'),'alias':_0x12dc95('0x10a'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xa},{'field':_0x12dc95('0xba'),'alias':_0x12dc95('0x4b'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xa},{'field':_0x12dc95('0xfd'),'alias':'Tot\x20Unmanaged\x20Time','function':'SUM','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xa},{'field':_0x12dc95('0x6d'),'alias':_0x12dc95('0xe8'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xa},{'field':'queuecallerexitreason','alias':'Reason','groupBy':0x1,'ReportId':0xb},{'field':'queuecallerexit','alias':_0x12dc95('0x104'),'function':'SUM','ReportId':0xb},{'field':_0x12dc95('0xfd'),'alias':'Tot\x20Unmanaged\x20Time','function':_0x12dc95('0xc2'),'custom':0x1,'ReportId':0xb},{'field':_0x12dc95('0x3a'),'alias':'Queue','groupBy':0x1,'ReportId':0xc},{'field':_0x12dc95('0x5f'),'alias':_0x12dc95('0x112'),'function':_0x12dc95('0xc2'),'ReportId':0xc},{'field':_0x12dc95('0x78'),'alias':_0x12dc95('0xff'),'custom':0x1,'ReportId':0xc},{'field':'ROUND(COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<10,1,NULL))\x20/\x20SUM(queuecallerabandon)\x20*100,1)','alias':_0x12dc95('0x63'),'custom':0x1,'ReportId':0xc},{'field':_0x12dc95('0x4'),'alias':_0x12dc95('0x2b'),'custom':0x1,'ReportId':0xc},{'field':_0x12dc95('0xd6'),'alias':_0x12dc95('0xad'),'custom':0x1,'ReportId':0xc},{'field':'COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=60\x20AND\x20UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<120,1,NULL))','alias':_0x12dc95('0x129'),'custom':0x1,'ReportId':0xc},{'field':'ROUND(COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=60\x20AND\x20UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<120,1,NULL))\x20\x20\x20/\x20SUM(queuecallerabandon)\x20*100,1)','alias':'Abandoned\x20Rate\x2060-120s','custom':0x1,'ReportId':0xc},{'field':'COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=120,1,NULL))','alias':_0x12dc95('0x7c'),'custom':0x1,'ReportId':0xc},{'field':_0x12dc95('0x123'),'alias':_0x12dc95('0x51'),'custom':0x1,'ReportId':0xc},{'field':'queuecallerjoinat','alias':'Date','format':_0x12dc95('0x99'),'groupBy':0x1,'custom':0x1,'ReportId':0xd},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x48'),'function':_0x12dc95('0x10b'),'ReportId':0xd},{'field':_0x12dc95('0x122'),'alias':_0x12dc95('0x5d'),'function':_0x12dc95('0xc2'),'ReportId':0xd},{'field':_0x12dc95('0x5f'),'alias':'Abandoned','function':_0x12dc95('0xc2'),'custom':0x1,'ReportId':0xd},{'field':_0x12dc95('0xbb'),'alias':_0x12dc95('0xb8'),'function':_0x12dc95('0xc2'),'custom':0x1,'ReportId':0xd},{'field':_0x12dc95('0x127'),'alias':_0x12dc95('0xc4'),'function':'SUM','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xd},{'field':_0x12dc95('0x47'),'alias':'AvgTalkTime','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xd},{'field':_0x12dc95('0xba'),'alias':'AvgAbandonTime','format':'SEC_TO_TIME','custom':0x1,'ReportId':0xd},{'field':_0x12dc95('0x90'),'alias':_0x12dc95('0xca'),'format':'HOUR','groupBy':0x1,'custom':0x1,'ReportId':0xe},{'field':'uniqueid','alias':_0x12dc95('0x48'),'function':_0x12dc95('0x10b'),'ReportId':0xe},{'field':_0x12dc95('0x122'),'alias':_0x12dc95('0x64'),'function':_0x12dc95('0xc2'),'ReportId':0xe},{'field':_0x12dc95('0x60'),'alias':_0x12dc95('0x45'),'custom':0x1,'ReportId':0xe},{'field':_0x12dc95('0x5f'),'alias':_0x12dc95('0x1b'),'function':'SUM','ReportId':0xe},{'field':_0x12dc95('0xbb'),'alias':_0x12dc95('0xb8'),'function':_0x12dc95('0xc2'),'ReportId':0xe},{'field':_0x12dc95('0x127'),'alias':_0x12dc95('0xc4'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xe},{'field':'ROUND(AVG(UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)))','alias':'AvgTalkTime','format':'SEC_TO_TIME','custom':0x1,'ReportId':0xe},{'field':_0x12dc95('0xba'),'alias':'AvgAbandonTime','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xe},{'field':_0x12dc95('0x7b'),'alias':'Day','groupBy':0x1,'custom':0x1,'ReportId':0xf},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x48'),'function':_0x12dc95('0x10b'),'ReportId':0xf},{'field':'queuecallercomplete','alias':_0x12dc95('0x64'),'function':_0x12dc95('0xc2'),'ReportId':0xf},{'field':_0x12dc95('0x60'),'alias':'Answer\x20Rate','custom':0x1,'ReportId':0xf},{'field':_0x12dc95('0x5f'),'alias':'Abandoned','function':_0x12dc95('0xc2'),'ReportId':0xf},{'field':'queuecallerexit','alias':_0x12dc95('0xb8'),'function':_0x12dc95('0xc2'),'ReportId':0xf},{'field':_0x12dc95('0x127'),'alias':_0x12dc95('0xc4'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xf},{'field':_0x12dc95('0x47'),'alias':_0x12dc95('0xb7'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0xf},{'field':_0x12dc95('0xba'),'alias':_0x12dc95('0x4b'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0xf},{'field':'DAYNAME(queuecallerjoinat)','alias':'DayOfWeek','groupBy':0x1,'custom':0x1,'ReportId':0x10},{'field':_0x12dc95('0xd5'),'alias':'Offered','function':_0x12dc95('0x10b'),'ReportId':0x10},{'field':_0x12dc95('0x122'),'alias':_0x12dc95('0x64'),'function':_0x12dc95('0xc2'),'ReportId':0x10},{'field':_0x12dc95('0x60'),'alias':'Answer\x20Rate','custom':0x1,'ReportId':0x10},{'field':_0x12dc95('0x5f'),'alias':'Abandoned','function':_0x12dc95('0xc2'),'orderBy':_0x12dc95('0x87'),'ReportId':0x10},{'field':_0x12dc95('0xbb'),'alias':_0x12dc95('0xb8'),'function':_0x12dc95('0xc2'),'ReportId':0x10},{'field':_0x12dc95('0x127'),'alias':_0x12dc95('0xc4'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x10},{'field':'ROUND(AVG(UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)))','alias':_0x12dc95('0xb7'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x10},{'field':_0x12dc95('0xba'),'alias':'AvgAbandonTime','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x10},{'field':_0x12dc95('0x3a'),'alias':_0x12dc95('0x95'),'groupBy':0x1,'ReportId':0x11},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x48'),'function':_0x12dc95('0x10b'),'ReportId':0x11},{'field':_0x12dc95('0x122'),'alias':_0x12dc95('0x64'),'function':_0x12dc95('0xc2'),'ReportId':0x11},{'field':_0x12dc95('0x60'),'alias':_0x12dc95('0x45'),'custom':0x1,'ReportId':0x11},{'field':'queuecallerabandon','alias':_0x12dc95('0x1b'),'function':_0x12dc95('0xc2'),'ReportId':0x11},{'field':_0x12dc95('0xbb'),'alias':'Unmanaged','function':_0x12dc95('0xc2'),'ReportId':0x11},{'field':'UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)','alias':'Tot\x20TalkTime','function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x11},{'field':_0x12dc95('0x47'),'alias':'AvgTalkTime','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x11},{'field':'ROUND(AVG(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)))','alias':_0x12dc95('0x4b'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x11},{'field':_0x12dc95('0xd5'),'alias':'UniqueID','ReportId':0x12},{'field':_0x12dc95('0x10c'),'alias':'Type','ReportId':0x12},{'field':'tag','alias':_0x12dc95('0x84'),'ReportId':0x12},{'field':'source','alias':_0x12dc95('0x6e'),'ReportId':0x12},{'field':_0x12dc95('0xa4'),'alias':_0x12dc95('0x55'),'ReportId':0x12},{'field':_0x12dc95('0x61'),'alias':_0x12dc95('0x11f'),'ReportId':0x12},{'field':_0x12dc95('0x54'),'alias':_0x12dc95('0xda'),'ReportId':0x12},{'field':_0x12dc95('0xbd'),'alias':_0x12dc95('0x11'),'ReportId':0x12},{'field':'lastdata','alias':_0x12dc95('0xc8'),'ReportId':0x12},{'field':_0x12dc95('0x10e'),'alias':_0x12dc95('0xcd'),'ReportId':0x12},{'field':_0x12dc95('0x4e'),'alias':_0x12dc95('0xe5'),'ReportId':0x12},{'field':_0x12dc95('0x8a'),'alias':_0x12dc95('0x5a'),'ReportId':0x12},{'field':_0x12dc95('0xdc'),'alias':_0x12dc95('0x35'),'ReportId':0x12},{'field':_0x12dc95('0xeb'),'alias':_0x12dc95('0x2f'),'ReportId':0x12},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0xf4'),'ReportId':0x13},{'field':'accountcode','alias':_0x12dc95('0x71'),'ReportId':0x13},{'field':'source','alias':_0x12dc95('0x6e'),'ReportId':0x13},{'field':_0x12dc95('0xa4'),'alias':'Destination','ReportId':0x13},{'field':_0x12dc95('0x61'),'alias':'CallerId','ReportId':0x13},{'field':_0x12dc95('0x10e'),'alias':_0x12dc95('0xcd'),'ReportId':0x13},{'field':_0x12dc95('0x4e'),'alias':_0x12dc95('0xe5'),'ReportId':0x13},{'field':_0x12dc95('0x8a'),'alias':_0x12dc95('0x5a'),'ReportId':0x13},{'field':'duration','alias':_0x12dc95('0x35'),'format':_0x12dc95('0x83'),'ReportId':0x13},{'field':_0x12dc95('0x126'),'alias':_0x12dc95('0x9f'),'format':'SEC_TO_TIME','ReportId':0x13},{'field':'disposition','alias':_0x12dc95('0x2f'),'ReportId':0x13},{'field':_0x12dc95('0xc1'),'alias':'Tag','ReportId':0x13},{'field':_0x12dc95('0x10c'),'alias':_0x12dc95('0x28'),'groupBy':0x1,'ReportId':0x14},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x104'),'function':'COUNT','ReportId':0x14},{'field':_0x12dc95('0xdc'),'alias':_0x12dc95('0x3'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'ReportId':0x14},{'field':_0x12dc95('0x52'),'alias':'Avg\x20Duration','format':'SEC_TO_TIME','custom':0x1,'ReportId':0x14},{'field':_0x12dc95('0xeb'),'alias':_0x12dc95('0x2f'),'groupBy':0x1,'ReportId':0x15},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x104'),'function':_0x12dc95('0x4d'),'ReportId':0x15},{'field':_0x12dc95('0xdc'),'alias':_0x12dc95('0x3'),'function':'SUM','format':_0x12dc95('0x83'),'ReportId':0x15},{'field':'ROUND(AVG(duration))','alias':'Avg\x20Duration','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x15},{'field':_0x12dc95('0x8c'),'alias':'Agent','groupBy':0x1,'custom':0x1,'ReportId':0x16},{'field':_0x12dc95('0xd5'),'alias':'Calls','function':_0x12dc95('0x4d'),'ReportId':0x16},{'field':_0x12dc95('0xdc'),'alias':'Tot\x20Duration','function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'ReportId':0x16},{'field':'ROUND(AVG(duration))','alias':_0x12dc95('0x77'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x16},{'field':_0x12dc95('0x10e'),'alias':'Date','format':_0x12dc95('0x99'),'groupBy':0x1,'ReportId':0x17},{'field':_0x12dc95('0xd5'),'alias':'Calls','function':'COUNT','ReportId':0x17},{'field':_0x12dc95('0xdc'),'alias':_0x12dc95('0x3'),'function':'SUM','format':_0x12dc95('0x83'),'ReportId':0x17},{'field':_0x12dc95('0x52'),'alias':_0x12dc95('0x77'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x17},{'field':_0x12dc95('0x25'),'alias':_0x12dc95('0x94'),'groupBy':0x1,'orderBy':_0x12dc95('0x87'),'ReportId':0x18},{'field':_0x12dc95('0x81'),'alias':'Duration','function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x18},{'field':_0x12dc95('0x25'),'alias':_0x12dc95('0x94'),'groupBy':0x1,'ReportId':0x19},{'field':_0x12dc95('0x23'),'alias':_0x12dc95('0x18'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x19},{'field':'CASE\x20WHEN\x20type=\x27TALKING\x27\x20THEN\x20UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)\x20END','alias':_0x12dc95('0x128'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x19},{'field':_0x12dc95('0x76'),'alias':'Pause\x20Time','function':'SUM','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x19},{'field':_0x12dc95('0x25'),'alias':_0x12dc95('0x94'),'ReportId':0x1a},{'field':_0x12dc95('0xa7'),'alias':_0x12dc95('0xe7'),'ReportId':0x1a},{'field':_0x12dc95('0x9a'),'alias':_0x12dc95('0x43'),'ReportId':0x1a},{'field':_0x12dc95('0x57'),'alias':_0x12dc95('0x105'),'ReportId':0x1a},{'field':_0x12dc95('0xdc'),'alias':'Duration','format':_0x12dc95('0x83'),'ReportId':0x1a},{'field':_0x12dc95('0x25'),'alias':_0x12dc95('0x94'),'ReportId':0x1b},{'field':'interface','alias':_0x12dc95('0x2'),'ReportId':0x1b},{'field':_0x12dc95('0x10c'),'alias':_0x12dc95('0xcf'),'ReportId':0x1b},{'field':_0x12dc95('0x57'),'alias':'Type','ReportId':0x1b},{'field':_0x12dc95('0xa7'),'alias':_0x12dc95('0xe7'),'ReportId':0x1b},{'field':_0x12dc95('0x9a'),'alias':_0x12dc95('0x43'),'ReportId':0x1b},{'field':'UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)','alias':_0x12dc95('0x35'),'format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x1b},{'field':_0x12dc95('0x25'),'alias':_0x12dc95('0x94'),'groupBy':0x1,'orderBy':'ASC','ReportId':0x1c},{'field':_0x12dc95('0x57'),'alias':_0x12dc95('0x5c'),'groupBy':0x1,'orderBy':_0x12dc95('0x87'),'ReportId':0x1c},{'field':_0x12dc95('0x81'),'alias':'Duration','function':'SUM','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x1c},{'field':_0x12dc95('0x6f'),'alias':'Project\x20Name','ReportId':0x1d},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x9d'),'ReportId':0x1d},{'field':_0x12dc95('0x61'),'alias':_0x12dc95('0x0'),'ReportId':0x1d},{'field':_0x12dc95('0x20'),'alias':_0x12dc95('0x11c'),'ReportId':0x1d},{'field':'joinAt','alias':_0x12dc95('0x3c'),'orderBy':_0x12dc95('0x87'),'ReportId':0x1d},{'field':'leaveAt','alias':'End\x20Time','ReportId':0x1d},{'field':_0x12dc95('0xb2'),'alias':'Duration','format':_0x12dc95('0x83'),'custom':0x1,'ReportId':0x1d},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x19'),'ReportId':0x1e},{'field':_0x12dc95('0x6f'),'alias':_0x12dc95('0x58'),'ReportId':0x1e},{'field':_0x12dc95('0x61'),'alias':'Caller\x20Id','ReportId':0x1e},{'field':_0x12dc95('0x12b'),'alias':'Block','ReportId':0x1e},{'field':'data','alias':_0x12dc95('0x12d'),'ReportId':0x1e},{'field':'connectedlinename','alias':_0x12dc95('0x94'),'groupBy':0x1,'ReportId':0x1f},{'field':'uniqueid','alias':'Recorded\x20Calls','function':_0x12dc95('0x4d'),'ReportId':0x1f},{'field':_0x12dc95('0xd7'),'alias':'Total\x20Rating','function':_0x12dc95('0xc2'),'ReportId':0x1f},{'field':_0x12dc95('0xd7'),'alias':'Avg\x20Rating','function':_0x12dc95('0x67'),'ReportId':0x1f},{'field':_0x12dc95('0x3a'),'alias':_0x12dc95('0x95'),'groupBy':0x1,'ReportId':0x20},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0xa3'),'function':_0x12dc95('0x4d'),'ReportId':0x20},{'field':_0x12dc95('0xd7'),'alias':_0x12dc95('0xb6'),'function':_0x12dc95('0xc2'),'ReportId':0x20},{'field':_0x12dc95('0xd7'),'alias':'Avg\x20Rating','function':_0x12dc95('0x67'),'ReportId':0x20},{'field':_0x12dc95('0x11b'),'alias':_0x12dc95('0x8e'),'ReportId':0x21},{'field':_0x12dc95('0xfc'),'alias':'CallerIdNum','ReportId':0x21},{'field':_0x12dc95('0x10e'),'alias':'LastCallAt','orderBy':_0x12dc95('0x1'),'ReportId':0x21},{'field':'statedesc','alias':_0x12dc95('0x85'),'ReportId':0x21},{'field':_0x12dc95('0x110'),'alias':'Global\x20Count','ReportId':0x21},{'field':_0x12dc95('0x101'),'alias':_0x12dc95('0xde'),'ReportId':0x21},{'field':_0x12dc95('0x21'),'alias':'BlackList','ReportId':0x21},{'field':_0x12dc95('0x25'),'alias':_0x12dc95('0x94'),'ReportId':0x21},{'field':_0x12dc95('0xe4'),'alias':_0x12dc95('0x128'),'ReportId':0x21},{'field':_0x12dc95('0xeb'),'alias':_0x12dc95('0x2f'),'ReportId':0x21},{'field':_0x12dc95('0xd5'),'alias':_0x12dc95('0x9d'),'ReportId':0x21},{'field':_0x12dc95('0x68'),'alias':_0x12dc95('0x85'),'groupBy':!![],'orderBy':_0x12dc95('0x87'),'ReportId':0x22},{'field':'id','alias':'Calls','function':_0x12dc95('0x4d'),'ReportId':0x22},{'field':_0x12dc95('0x32'),'alias':'Calls\x20(%)','custom':!![],'ReportId':0x22},{'field':'campaign','alias':_0x12dc95('0x8e'),'orderBy':_0x12dc95('0x87'),'groupBy':!![],'ReportId':0x23},{'field':_0x12dc95('0x68'),'alias':_0x12dc95('0x85'),'groupBy':!![],'ReportId':0x23},{'field':'id','alias':_0x12dc95('0x27'),'function':_0x12dc95('0x4d'),'ReportId':0x23},{'field':_0x12dc95('0xd1'),'groupBy':!![],'orderBy':_0x12dc95('0x87'),'ReportId':0x24},{'field':'id','alias':_0x12dc95('0x88'),'function':_0x12dc95('0x4d'),'ReportId':0x24},{'field':_0x12dc95('0x66'),'alias':_0x12dc95('0xe1'),'custom':!![],'ReportId':0x24},{'field':_0x12dc95('0x119'),'alias':_0x12dc95('0xfe'),'custom':!![],'ReportId':0x24},{'field':'membername','alias':_0x12dc95('0x94'),'groupBy':!![],'orderBy':_0x12dc95('0x87'),'ReportId':0x25},{'field':'id','alias':_0x12dc95('0x104'),'function':_0x12dc95('0x4d'),'ReportId':0x25},{'field':_0x12dc95('0x6a'),'alias':_0x12dc95('0x120'),'custom':!![],'ReportId':0x25},{'field':_0x12dc95('0xeb'),'alias':_0x12dc95('0x2f'),'groupBy':!![],'ReportId':0x26},{'field':'id','alias':_0x12dc95('0x26'),'function':_0x12dc95('0x4d'),'ReportId':0x26},{'field':'ROUND(COUNT(id)*100/(SELECT\x20COUNT(*)\x20FROM\x20cm_hopper_final\x20WHERE\x20state=4\x20and\x20campaigntype=\x27queue\x27),2)','alias':'Total\x20(%)','custom':!![],'ReportId':0x26},{'field':_0x12dc95('0x25'),'alias':_0x12dc95('0x94'),'groupBy':!![],'ReportId':0x27},{'field':'disposition','alias':_0x12dc95('0x2f'),'groupBy':!![],'ReportId':0x27},{'field':'id','alias':'Total','function':'COUNT','ReportId':0x27},{'field':_0x12dc95('0x17'),'alias':'Total\x20(%)','custom':!![],'ReportId':0x27},{'field':_0x12dc95('0x11b'),'alias':_0x12dc95('0x8e'),'ReportId':0x28},{'field':_0x12dc95('0xfc'),'alias':_0x12dc95('0xc6'),'ReportId':0x28},{'field':_0x12dc95('0x10e'),'alias':'LastCallAt','orderBy':'DESC','ReportId':0x28},{'field':'statedesc','alias':_0x12dc95('0x85'),'ReportId':0x28},{'field':_0x12dc95('0x110'),'alias':_0x12dc95('0xd'),'ReportId':0x28},{'field':_0x12dc95('0x101'),'alias':'Drop\x20Reason','ReportId':0x28},{'field':_0x12dc95('0x21'),'alias':_0x12dc95('0x11a'),'ReportId':0x28},{'field':_0x12dc95('0xe4'),'alias':'Talk\x20Time','ReportId':0x28},{'field':'uniqueid','alias':_0x12dc95('0x9d'),'ReportId':0x28},{'field':_0x12dc95('0x68'),'alias':_0x12dc95('0x85'),'groupBy':!![],'orderBy':_0x12dc95('0x87'),'ReportId':0x29},{'field':'id','alias':_0x12dc95('0x104'),'function':_0x12dc95('0x4d'),'ReportId':0x29},{'field':'ROUND(count(id)*100/(SELECT\x20COUNT(*)\x20FROM\x20cm_hopper_history\x20WHERE\x20campaigntype=\x27ivr\x27),2)','alias':_0x12dc95('0x114'),'custom':!![],'ReportId':0x29},{'field':'campaign','alias':_0x12dc95('0x8e'),'orderBy':'ASC','groupBy':!![],'ReportId':0x2a},{'field':'statedesc','alias':_0x12dc95('0x85'),'groupBy':!![],'ReportId':0x2a},{'field':'id','alias':_0x12dc95('0x27'),'function':_0x12dc95('0x4d'),'ReportId':0x2a},{'field':_0x12dc95('0xd1'),'groupBy':!![],'orderBy':_0x12dc95('0x87'),'ReportId':0x2b},{'field':'id','alias':'Contacts','function':'COUNT','ReportId':0x2b},{'field':'SUM(IF(state=4,1,0))','alias':'Managed','custom':!![],'ReportId':0x2b},{'field':'ROUND(SUM(IF(state=4,1,0))/COUNT(*)*100,1)','alias':_0x12dc95('0xfe'),'custom':!![],'ReportId':0x2b},{'field':_0x12dc95('0x107'),'alias':_0x12dc95('0xab'),'groupBy':!![],'ReportId':0x2c},{'field':_0x12dc95('0x14'),'alias':'Interactions','function':_0x12dc95('0x4d'),'ReportId':0x2c},{'field':_0x12dc95('0x121'),'alias':'Open','custom':!![],'ReportId':0x2c},{'field':'COUNT(IF(closed=1\x20&&\x20((disposition\x20!=\x27unmanaged\x27\x20&&\x20disposition\x20!=\x27abandoned\x27)\x20||\x20disposition\x20IS\x20NULL),1,NULL))','alias':_0x12dc95('0xbe'),'custom':!![],'ReportId':0x2c},{'field':_0x12dc95('0x4a'),'alias':_0x12dc95('0xb8'),'custom':!![],'ReportId':0x2c},{'field':'COUNT(IF(closed=1\x20&&\x20disposition\x20=\x27abandoned\x27,1,NULL))','alias':'Abandoned','custom':!![],'ReportId':0x2c},{'field':_0x12dc95('0x107'),'alias':_0x12dc95('0xab'),'groupBy':!![],'ReportId':0x2d},{'field':_0x12dc95('0x2e'),'alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x2d},{'field':_0x12dc95('0xc0'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x2d},{'field':_0x12dc95('0xb4'),'alias':'Agent','groupBy':!![],'ReportId':0x2e},{'field':'chat_interactions.closed','alias':_0x12dc95('0xbe'),'function':_0x12dc95('0xc2'),'ReportId':0x2e},{'field':_0x12dc95('0x2e'),'alias':_0x12dc95('0xcc'),'function':'SUM','format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x2e},{'field':_0x12dc95('0xc0'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x2e},{'field':_0x12dc95('0x62'),'alias':_0x12dc95('0xa0'),'format':'DATE','groupBy':!![],'custom':!![],'ReportId':0x2f},{'field':_0x12dc95('0x14'),'alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x2f},{'field':_0x12dc95('0x6b'),'alias':_0x12dc95('0x5d'),'custom':!![],'ReportId':0x2f},{'field':'ROUND(COUNT(IF(closed=1\x20&&\x20((disposition\x20!=\x27unmanaged\x27\x20&&\x20disposition\x20!=\x27abandoned\x27)\x20||\x20disposition\x20IS\x20NULL),1,NULL))/COUNT(id)\x20*100,1)','alias':_0x12dc95('0x7a'),'custom':!![],'ReportId':0x2f},{'field':'COUNT(IF(closed=1\x20&&\x20disposition\x20=\x27unmanaged\x27,1,NULL))','alias':'Unmanaged','custom':!![],'ReportId':0x2f},{'field':'ROUND(COUNT(IF(closed=1\x20&&\x20disposition=\x27unmanaged\x27,1,NULL))/COUNT(id)\x20*100,1)','alias':'Unmanaged\x20(%)','custom':!![],'ReportId':0x2f},{'field':_0x12dc95('0x44'),'alias':_0x12dc95('0x1b'),'custom':!![],'ReportId':0x2f},{'field':_0x12dc95('0xf3'),'alias':_0x12dc95('0x8'),'custom':!![],'ReportId':0x2f},{'field':_0x12dc95('0xbf'),'alias':'Interaction\x20Time','function':_0x12dc95('0xc2'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x2f},{'field':_0x12dc95('0x9c'),'alias':_0x12dc95('0x53'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x2f},{'field':_0x12dc95('0xcb'),'alias':_0x12dc95('0x95'),'groupBy':!![],'ReportId':0x30},{'field':_0x12dc95('0x4f'),'alias':_0x12dc95('0x102'),'function':'COUNT','ReportId':0x30},{'field':_0x12dc95('0x75'),'alias':_0x12dc95('0xd4'),'custom':!![],'ReportId':0x30},{'field':_0x12dc95('0x34'),'alias':_0x12dc95('0xaf'),'custom':!![],'ReportId':0x30},{'field':_0x12dc95('0xb2'),'alias':_0x12dc95('0x116'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x30},{'field':_0x12dc95('0x82'),'alias':'AVG\x20Hold\x20Time','format':'SEC_TO_TIME','custom':!![],'ReportId':0x30},{'field':'mail_accounts.name','alias':_0x12dc95('0xdd'),'groupBy':!![],'ReportId':0x31},{'field':_0x12dc95('0x5b'),'alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x31},{'field':_0x12dc95('0x121'),'alias':_0x12dc95('0x72'),'custom':!![],'ReportId':0x31},{'field':_0x12dc95('0x40'),'alias':_0x12dc95('0xbe'),'custom':!![],'ReportId':0x31},{'field':_0x12dc95('0x46'),'alias':'Email\x20Account','groupBy':!![],'ReportId':0x32},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(mail_interactions.createdAt)','alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x32},{'field':_0x12dc95('0xf2'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x32},{'field':_0x12dc95('0xb4'),'alias':_0x12dc95('0x94'),'groupBy':!![],'ReportId':0x33},{'field':_0x12dc95('0x31'),'alias':_0x12dc95('0xbe'),'function':_0x12dc95('0xc2'),'ReportId':0x33},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(mail_interactions.createdAt)','alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x33},{'field':_0x12dc95('0xf2'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x33},{'field':_0x12dc95('0xb5'),'alias':'Date','format':_0x12dc95('0x99'),'groupBy':!![],'custom':!![],'ReportId':0x34},{'field':_0x12dc95('0x5b'),'alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x34},{'field':_0x12dc95('0x40'),'alias':_0x12dc95('0x5d'),'custom':!![],'ReportId':0x34},{'field':_0x12dc95('0xdf'),'alias':_0x12dc95('0x7a'),'custom':!![],'ReportId':0x34},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(createdAt)','alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x34},{'field':_0x12dc95('0x9c'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x34},{'field':_0x12dc95('0x2c'),'alias':'Queue','groupBy':!![],'ReportId':0x35},{'field':_0x12dc95('0x8f'),'alias':'Interactions','function':_0x12dc95('0x4d'),'ReportId':0x35},{'field':_0x12dc95('0x75'),'alias':_0x12dc95('0xd4'),'custom':!![],'ReportId':0x35},{'field':_0x12dc95('0x34'),'alias':_0x12dc95('0xaf'),'custom':!![],'ReportId':0x35},{'field':'UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)','alias':_0x12dc95('0x116'),'function':'SUM','format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x35},{'field':_0x12dc95('0x82'),'alias':'AVG\x20Hold\x20Time','format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x35},{'field':'openchannel_accounts.name','alias':_0x12dc95('0xe0'),'groupBy':!![],'ReportId':0x36},{'field':_0x12dc95('0x93'),'alias':'Interactions','function':'COUNT','ReportId':0x36},{'field':_0x12dc95('0x121'),'alias':_0x12dc95('0x72'),'custom':!![],'ReportId':0x36},{'field':_0x12dc95('0x40'),'alias':_0x12dc95('0xbe'),'custom':!![],'ReportId':0x36},{'field':_0x12dc95('0x92'),'alias':_0x12dc95('0xe0'),'groupBy':!![],'ReportId':0x37},{'field':_0x12dc95('0x42'),'alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x37},{'field':_0x12dc95('0x3d'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x37},{'field':_0x12dc95('0xb4'),'alias':_0x12dc95('0x94'),'groupBy':!![],'ReportId':0x38},{'field':_0x12dc95('0xe'),'alias':_0x12dc95('0xbe'),'function':'SUM','ReportId':0x38},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(openchannel_interactions.createdAt)','alias':'Interaction\x20Time','function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x38},{'field':'ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(openchannel_interactions.createdAt)))','alias':'AVG\x20Interaction\x20Time','format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x38},{'field':_0x12dc95('0xf1'),'alias':_0x12dc95('0xa0'),'format':_0x12dc95('0x99'),'groupBy':!![],'custom':!![],'ReportId':0x39},{'field':_0x12dc95('0x93'),'alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x39},{'field':_0x12dc95('0x40'),'alias':_0x12dc95('0x5d'),'custom':!![],'ReportId':0x39},{'field':'ROUND(COUNT(IF(closed=1,1,NULL))/COUNT(id)\x20*100,1)','alias':_0x12dc95('0x7a'),'custom':!![],'ReportId':0x39},{'field':_0x12dc95('0xbf'),'alias':_0x12dc95('0xcc'),'function':'SUM','format':'SEC_TO_TIME','custom':!![],'ReportId':0x39},{'field':_0x12dc95('0x9c'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x39},{'field':_0x12dc95('0xc5'),'alias':_0x12dc95('0x95'),'groupBy':!![],'ReportId':0x3a},{'field':_0x12dc95('0xb0'),'alias':'Interactions','function':_0x12dc95('0x4d'),'ReportId':0x3a},{'field':_0x12dc95('0x75'),'alias':_0x12dc95('0xd4'),'custom':!![],'ReportId':0x3a},{'field':'COUNT(IF(reason=\x27timeout\x27,1,NULL))','alias':'Timeout','custom':!![],'ReportId':0x3a},{'field':'UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)','alias':'Hold\x20Time','function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x3a},{'field':_0x12dc95('0x82'),'alias':_0x12dc95('0xf7'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x3a},{'field':_0x12dc95('0xe6'),'alias':_0x12dc95('0x33'),'groupBy':!![],'ReportId':0x3b},{'field':_0x12dc95('0x9'),'alias':_0x12dc95('0x102'),'function':'COUNT','ReportId':0x3b},{'field':_0x12dc95('0x121'),'alias':_0x12dc95('0x72'),'custom':!![],'ReportId':0x3b},{'field':'COUNT(IF(closed=1,1,NULL))','alias':_0x12dc95('0xbe'),'custom':!![],'ReportId':0x3b},{'field':_0x12dc95('0xe6'),'alias':'Sms\x20Account','groupBy':!![],'ReportId':0x3c},{'field':_0x12dc95('0x70'),'alias':_0x12dc95('0xcc'),'function':'SUM','format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x3c},{'field':_0x12dc95('0x98'),'alias':_0x12dc95('0x53'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x3c},{'field':_0x12dc95('0xb4'),'alias':_0x12dc95('0x94'),'groupBy':!![],'ReportId':0x3d},{'field':_0x12dc95('0xc7'),'alias':'Closed','function':_0x12dc95('0xc2'),'ReportId':0x3d},{'field':_0x12dc95('0x70'),'alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x3d},{'field':_0x12dc95('0x98'),'alias':'AVG\x20Interaction\x20Time','format':'SEC_TO_TIME','custom':!![],'ReportId':0x3d},{'field':_0x12dc95('0xc'),'alias':_0x12dc95('0xa0'),'format':_0x12dc95('0x99'),'groupBy':!![],'custom':!![],'ReportId':0x3e},{'field':'sms_interactions.id','alias':_0x12dc95('0x102'),'function':'COUNT','ReportId':0x3e},{'field':_0x12dc95('0x40'),'alias':_0x12dc95('0x5d'),'custom':!![],'ReportId':0x3e},{'field':_0x12dc95('0xdf'),'alias':_0x12dc95('0x7a'),'custom':!![],'ReportId':0x3e},{'field':_0x12dc95('0xbf'),'alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x3e},{'field':_0x12dc95('0x9c'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x3e},{'field':_0x12dc95('0xfa'),'alias':_0x12dc95('0x95'),'groupBy':!![],'ReportId':0x3f},{'field':'report_sms_queue.id','alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x3f},{'field':_0x12dc95('0x75'),'alias':_0x12dc95('0xd4'),'custom':!![],'ReportId':0x3f},{'field':_0x12dc95('0x34'),'alias':_0x12dc95('0xaf'),'custom':!![],'ReportId':0x3f},{'field':'UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)','alias':_0x12dc95('0x116'),'function':'SUM','format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x3f},{'field':_0x12dc95('0x82'),'alias':_0x12dc95('0xf7'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x3f},{'field':'fax_queues.name','alias':_0x12dc95('0x95'),'groupBy':!![],'ReportId':0x44},{'field':'report_fax_queue.id','alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x44},{'field':_0x12dc95('0x75'),'alias':_0x12dc95('0xd4'),'custom':!![],'ReportId':0x44},{'field':'COUNT(IF(reason=\x27timeout\x27,1,NULL))','alias':_0x12dc95('0xaf'),'custom':!![],'ReportId':0x44},{'field':_0x12dc95('0xb2'),'alias':_0x12dc95('0x116'),'function':'SUM','format':'SEC_TO_TIME','custom':!![],'ReportId':0x44},{'field':'ROUND(AVG(UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)))','alias':_0x12dc95('0xf7'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x44},{'field':_0x12dc95('0xf5'),'alias':_0x12dc95('0xa0'),'format':'DATE','groupBy':!![],'custom':!![],'ReportId':0x43},{'field':_0x12dc95('0x56'),'alias':'Interactions','function':'COUNT','ReportId':0x43},{'field':'COUNT(IF(closed=1,1,NULL))','alias':_0x12dc95('0x5d'),'custom':!![],'ReportId':0x43},{'field':_0x12dc95('0xdf'),'alias':_0x12dc95('0x7a'),'custom':!![],'ReportId':0x43},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(createdAt)','alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x43},{'field':_0x12dc95('0x9c'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x43},{'field':'users.fullname','alias':_0x12dc95('0x94'),'groupBy':!![],'ReportId':0x42},{'field':'fax_interactions.closed','alias':_0x12dc95('0xbe'),'function':'SUM','ReportId':0x42},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(fax_interactions.createdAt)','alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x42},{'field':_0x12dc95('0xb9'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x42},{'field':'fax_accounts.name','alias':_0x12dc95('0x36'),'groupBy':!![],'ReportId':0x41},{'field':_0x12dc95('0xa2'),'alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x41},{'field':_0x12dc95('0xb9'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x41},{'field':_0x12dc95('0xf6'),'alias':_0x12dc95('0x36'),'groupBy':!![],'ReportId':0x40},{'field':_0x12dc95('0x56'),'alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x40},{'field':_0x12dc95('0x121'),'alias':_0x12dc95('0x72'),'custom':!![],'ReportId':0x40},{'field':_0x12dc95('0x40'),'alias':_0x12dc95('0xbe'),'custom':!![],'ReportId':0x40},{'field':_0x12dc95('0xf8'),'alias':'UserId','groupBy':!![],'custom':![],'ReportId':0x4a},{'field':_0x12dc95('0xb4'),'alias':'Full\x20Name','groupBy':![],'custom':![],'ReportId':0x4a},{'field':_0x12dc95('0x12c'),'alias':_0x12dc95('0xa'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x12dc95('0x109'),'alias':_0x12dc95('0x7d'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':'COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27NEUTRAL\x27,1,NULL))','alias':_0x12dc95('0x49'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x12dc95('0x1a'),'alias':_0x12dc95('0x1e'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x12dc95('0xf0'),'alias':_0x12dc95('0x106'),'function':_0x12dc95('0x4d'),'groupBy':![],'custom':![],'ReportId':0x4a},{'field':_0x12dc95('0xa5'),'alias':'Positive(%)','groupBy':![],'custom':!![],'ReportId':0x45},{'field':_0x12dc95('0x4c'),'alias':_0x12dc95('0x5'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':'CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27NEUTRAL\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','alias':_0x12dc95('0x1d'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x12dc95('0x22'),'alias':_0x12dc95('0xd9'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x12dc95('0xf0'),'alias':_0x12dc95('0x118'),'function':_0x12dc95('0x4d'),'groupBy':![],'custom':![],'ReportId':0x4b},{'field':_0x12dc95('0x12c'),'alias':_0x12dc95('0xa'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x12dc95('0x109'),'alias':_0x12dc95('0x7d'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':'COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27NEUTRAL\x27,1,NULL))','alias':_0x12dc95('0x49'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x12dc95('0x1a'),'alias':_0x12dc95('0x1e'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x12dc95('0xa5'),'alias':'Positive(%)','groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x12dc95('0x4c'),'alias':_0x12dc95('0x5'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x12dc95('0x111'),'alias':_0x12dc95('0x1d'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x12dc95('0x22'),'alias':_0x12dc95('0xd9'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x12dc95('0x30'),'alias':'Whatsapp\x20Account','groupBy':!![],'ReportId':0x45},{'field':_0x12dc95('0x91'),'alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x45},{'field':'COUNT(IF(closed=0,1,NULL))','alias':_0x12dc95('0x72'),'custom':!![],'ReportId':0x45},{'field':'COUNT(IF(closed=1,1,NULL))','alias':_0x12dc95('0xbe'),'custom':!![],'ReportId':0x45},{'field':'whatsapp_accounts.name','alias':_0x12dc95('0xce'),'groupBy':!![],'ReportId':0x46},{'field':_0x12dc95('0x113'),'alias':_0x12dc95('0xcc'),'function':'SUM','format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x46},{'field':_0x12dc95('0x9b'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x46},{'field':_0x12dc95('0xb4'),'alias':_0x12dc95('0x94'),'groupBy':!![],'ReportId':0x47},{'field':_0x12dc95('0x29'),'alias':_0x12dc95('0xbe'),'function':_0x12dc95('0xc2'),'ReportId':0x47},{'field':_0x12dc95('0x113'),'alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x47},{'field':_0x12dc95('0x9b'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x47},{'field':_0x12dc95('0x89'),'alias':'Date','format':'DATE','groupBy':!![],'custom':!![],'ReportId':0x48},{'field':_0x12dc95('0x91'),'alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x48},{'field':_0x12dc95('0x40'),'alias':_0x12dc95('0x5d'),'custom':!![],'ReportId':0x48},{'field':_0x12dc95('0xdf'),'alias':'Completed\x20(%)','custom':!![],'ReportId':0x48},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(createdAt)','alias':_0x12dc95('0xcc'),'function':_0x12dc95('0xc2'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x48},{'field':_0x12dc95('0x9c'),'alias':_0x12dc95('0x53'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x48},{'field':'whatsapp_queues.name','alias':'Queue','groupBy':!![],'ReportId':0x49},{'field':_0x12dc95('0x69'),'alias':_0x12dc95('0x102'),'function':_0x12dc95('0x4d'),'ReportId':0x49},{'field':_0x12dc95('0x75'),'alias':'Accepted','custom':!![],'ReportId':0x49},{'field':_0x12dc95('0x34'),'alias':_0x12dc95('0xaf'),'custom':!![],'ReportId':0x49},{'field':_0x12dc95('0xb2'),'alias':_0x12dc95('0x116'),'function':'SUM','format':'SEC_TO_TIME','custom':!![],'ReportId':0x49},{'field':'ROUND(AVG(UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)))','alias':_0x12dc95('0xf7'),'format':_0x12dc95('0x83'),'custom':!![],'ReportId':0x49}];return _[_0x12dc95('0x2a')](_0x1a5a61,'ReportId');}; \ No newline at end of file +const a869_0x4f02=['COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27NEGATIVE\x27,1,NULL))','Rated\x20Calls','AgentACW','ROUND(COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<10,1,NULL))\x20/\x20SUM(queuecallerabandon)\x20*100,1)','destinationchannel','QueueExitAt','TalkTime','COUNT(IF(holdtime<10,1,NULL))','COUNT(IF(closed=1,1,NULL))','Type','answertime','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(fax_interactions.createdAt)))','Campaign\x20Name','Completed','queuecallerexit','rating','holdtime','Unmanaged\x20(%)','Avg\x20Handle\x20Time','queuecallerabandon','HoldTime','COUNT(IF(closed=0,1,NULL))','report_sms_queue.id','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(mail_interactions.createdAt)','Abandoned>120s','report_chat_queue.id','UNIX_TIMESTAMP(queuecallerExitAt)-UNIX_TIMESTAMP(queuecallerjoinAt)','AvgAbandonTime','openchannel_accounts.name','ROUND(COUNT(IF(holdtime\x20>=20\x20AND\x20holdtime\x20<30,1,NULL))\x20/\x20SUM(agentcomplete)\x20*100,1)','Project\x20Name','Drop\x20Reason','CallerIdNum','fax_accounts.name','COUNT(IF(closed=1\x20&&\x20((disposition\x20!=\x27unmanaged\x27\x20&&\x20disposition\x20!=\x27abandoned\x27)\x20||\x20disposition\x20IS\x20NULL),1,NULL))','TotHandleTime','Global\x20Count','COUNT(IF(reason=\x27timeout\x27,1,NULL))','openchannel_interactions.id','BlackList','Open','agentconnectAt','Answered\x2020-30s','UnmanagedReason','membername','Avg\x20TalkTime','fax_interactions.createdAt','talktime\x20+\x20acwtime','Disposition','LastApp','UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)','exitAt','SUM','Closed','DATE','CompleteAt','data1','Tot\x20Answered','COUNT(IF(holdtime\x20>=10\x20AND\x20holdtime\x20<20,1,NULL))','Billsec','Completed\x20(%)','SUM(IF(state=4,1,0))','Calls\x20(%)','agentcalledAt','CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27MIXED\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27POSITIVE\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','ROUND(COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=10\x20AND\x20UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<60,1,NULL))\x20\x20/\x20SUM(queuecallerabandon)\x20*100,1)','COUNT','Data','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(whatsapp_interactions.createdAt)))','ROUND(count(id)*100/(SELECT\x20COUNT(*)\x20FROM\x20cm_hopper_history\x20WHERE\x20campaigntype=\x27queue\x27),2)','Tot\x20AbandonTime','Answered\x20>30s','COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=60\x20AND\x20UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<120,1,NULL))','LastCallAt','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(mail_interactions.createdAt)))','destination','acwtime','IF(queuecallercomplete=1,holdtime,null)','AnswerTime','fax_interactions.closed','mail_interactions.createdAt','AgentExtension','Managed','agentcomplete','Hold\x20Time','Negative(%)','ROUND(AVG(acwtime))','QueueJoinAt','Answered','Abandoned\x20Rate\x2010-60s','callerid','Abandoned\x20Rate<10s','StartTime','uniqueid','DESC','MIXED','ROUND(SUM(queuecallercomplete)/COUNT(DISTINCT\x20uniqueid)*100,1)','leaveAt','Tag','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(createdAt)))','TotTalkTime','Penetration\x20Rate','Pause','Openchannel\x20Account','ROUND(COUNT(IF(closed=1\x20&&\x20((disposition\x20!=\x27unmanaged\x27\x20&&\x20disposition\x20!=\x27abandoned\x27)\x20||\x20disposition\x20IS\x20NULL),1,NULL))/COUNT(id)\x20*100,1)','COUNT(IF(closed=1\x20&&\x20disposition\x20=\x27unmanaged\x27,1,NULL))','AvgTalkTime','queuecallerexitreason','statedesc','UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)','groupBy','whatsapp_interactions.id','UniqueID','whatsapp_interactions.closed','sms_queues.name','HangupReason','Queue','DID','ROUND(count(id)*100/(SELECT\x20COUNT(*)\x20FROM\x20cm_hopper_history\x20WHERE\x20campaigntype=\x27ivr\x27),2)','UnmanagedAt','sms_interactions.id','voice_recordings.sentiment','Talk\x20Time','COUNT(IF(reason=\x27accepted\x27,1,NULL))','ROUND(COUNT(IF(closed=1,1,NULL))/COUNT(id)\x20*100,1)','lastevent','ROUND(AVG(UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)))','Login\x20Time','Whatsapp\x20Account','TOT','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(whatsapp_interactions.createdAt)','ROUND(COUNT(IF(holdtime<10,1,NULL))\x20/\x20SUM(agentcomplete)\x20*100,1)','disposition','Avg\x20Duration','Answer\x20Rate\x20<10s','Calls','chat_interactions.id','CallerId','Email\x20Account','agentcompleteAt','queuecallerleaveAt','Abandoned\x20(%)','chat_interactions.closed','type','EnterAt','Mixed(%)','COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<10,1,NULL))','Fax\x20Account','Offered','Destination','NEGATIVE','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(openchannel_interactions.createdAt)','Abandoned\x20Rate>120s','Neutral(%)','openchannel_interactions.closed','DAYNAME(queuecallerjoinat)','AVG','Agent','lastdata','COUNT(IF(holdtime\x20>=30,1,NULL))','enterAt','Tot\x20TalkTime','countglobal','CASE\x20WHEN\x20type=\x27TALKING\x27\x20THEN\x20UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)\x20END','Accepted','NEUTRAL','chat_interactions.createdAt','users.fullname','sms_interactions.closed','Reason','CallerID','Tot\x20Abandoned','Start\x20Time','DAY(queuecallerjoinat)','ROUND(AVG(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)))','AVG\x20Hold\x20Time','Tot\x20Unmanaged\x20Time','agentacw','ROUND(SUM(talktime\x20+\x20acwtime)/COUNT(agentcomplete))','source','Sentiment\x20TOT','dropreason','starttime','exten','Answer\x20Rate','chat_websites.name','Abandoned','openchannel_interactions.createdAt','Tot\x20Duration','ROUND(COUNT(id)*100/(SELECT\x20COUNT(*)\x20FROM\x20cm_hopper_final\x20WHERE\x20state=4\x20and\x20campaigntype=\x27queue\x27),2)','endtime','UniqueId','ListId','sms_interactions.createdAt','DestChannel','ASC','Event','Total\x20Calls','UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)','queuecallerexitAt','AVG\x20Talk\x20Time','COUNT(IF(closed=1\x20&&\x20disposition\x20=\x27abandoned\x27,1,NULL))','ROUND(SUM(IF(state=4,1,0))/COUNT(*)*100,1)','Source','SEC_TO_TIME(AVG(talktime))','POSITIVE','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(sms_interactions.createdAt)))','QueueAbandon','project_name','lastapplication','report_openchannel_queue.id','SEC_TO_TIME','Abandoned\x2060-120s','mail_accounts.name','report_whatsapp_queue.id','COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27POSITIVE\x27,1,NULL))','tag','mail_queues.name','reason','Timeout','sms_accounts.name','fax_queues.name','connectedlinename','QueuePosition','calleridnum','queuecallerabandonAt','billableseconds','queuecallercompleteAt','ROUND(AVG(talktime))','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(chat_interactions.createdAt)','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(sms_interactions.createdAt)','ROUND(COUNT(IF(holdtime\x20>=10\x20AND\x20holdtime\x20<20,1,NULL))\x20/\x20SUM(agentcomplete)\x20*100,1)','Total\x20Rating','EndTime','Unique\x20Id','mail_interactions.closed','fax_interactions.id','ROUND(AVG(UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)))','CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27NEGATIVE\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','Interaction\x20Time','duration','HOUR','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(createdAt)','Unmanaged','CASE\x20WHEN\x20type=\x27LOGIN\x27\x20THEN\x20UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)\x20END','campaign','Interface','Full\x20Name','queue','AgentCalledAt','Positive(%)','Sms\x20Account','Hour','AgentCompleteAt','calleridname','UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(fax_interactions.createdAt)','ROUND(COUNT(IF(closed=1\x20&&\x20disposition=\x27abandoned\x27,1,NULL))/COUNT(id)\x20*100,1)','COUNT\x20DISTINCT','ROUND(AVG(holdtime))','Answered\x2010-20s','AvgACWTime','CASE\x20WHEN\x20queuecallercomplete=1\x20THEN\x20\x27YES\x27\x20ELSE\x20\x27NO\x27\x20END','ROUND(AVG(duration))','mail_interactions.id','Unmanaged\x20HoldTime','QueueExitReason','State','Pause\x20Time','ROUND(COUNT(IF(closed=1\x20&&\x20disposition=\x27unmanaged\x27,1,NULL))/COUNT(id)\x20*100,1)','CallerIdName','queuecallerjoinAt','Duration','LeaveAt','ROUND(COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=60\x20AND\x20UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<120,1,NULL))\x20\x20\x20/\x20SUM(queuecallerabandon)\x20*100,1)','CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27NEUTRAL\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','voice_recordings.UserId','COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27MIXED\x27,1,NULL))','CASE\x20WHEN\x20type=\x27PAUSE\x27\x20THEN\x20UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)\x20END','Date','queuecallerjoinat','talktime','UserId','Complete','Tot\x20ACWTime','interface','blacklist','queuecallercomplete','node','Caller\x20Id','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(chat_interactions.createdAt)))','Abandoned<10s','ROUND(AVG(UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(openchannel_interactions.createdAt)))','Interactions','ReportId','QueueLeaveAt','COUNT(IF(holdtime\x20>=20\x20AND\x20holdtime\x20<30,1,NULL))','COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27NEUTRAL\x27,1,NULL))','AgentComplete','Answered\x20<10s','Contacts','AgentACWTime','QueueExit','UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)','LastEvent','whatsapp_accounts.name','data','COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=120,1,NULL))','AbandonTime','AVG\x20Interaction\x20Time'];(function(_0xc769d8,_0x4f02f6){const _0x3d0738=function(_0x471fe9){while(--_0x471fe9){_0xc769d8['push'](_0xc769d8['shift']());}};_0x3d0738(++_0x4f02f6);}(a869_0x4f02,0x1e0));const a869_0x3d07=function(_0xc769d8,_0x4f02f6){_0xc769d8=_0xc769d8-0x0;let _0x3d0738=a869_0x4f02[_0xc769d8];return _0x3d0738;};'use strict';const _=require('lodash');module['exports']=function(){const _0x3f26fd=a869_0x3d07,_0x471fe9=[{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x16'),'ReportId':0x1},{'field':'calleridnum','alias':_0x3f26fd('0xac'),'ReportId':0x1},{'field':_0x3f26fd('0x55'),'alias':_0x3f26fd('0x64'),'ReportId':0x1},{'field':_0x3f26fd('0x4f'),'alias':_0x3f26fd('0x101'),'ReportId':0x1},{'field':_0x3f26fd('0x65'),'alias':_0x3f26fd('0xe4'),'ReportId':0x1},{'field':_0x3f26fd('0x119'),'alias':_0x3f26fd('0x7d'),'ReportId':0x1},{'field':_0x3f26fd('0x9f'),'alias':_0x3f26fd('0x26'),'ReportId':0x1},{'field':'queuecallerabandonAt','alias':'QueueAbandonAt','ReportId':0x1},{'field':'queuecallercomplete','alias':_0x3f26fd('0x71'),'ReportId':0x1},{'field':_0x3f26fd('0x3a'),'alias':_0x3f26fd('0xc3'),'ReportId':0x1},{'field':_0x3f26fd('0x9a'),'alias':_0x3f26fd('0x84'),'ReportId':0x1},{'field':_0x3f26fd('0x1e'),'alias':_0x3f26fd('0x91'),'ReportId':0x1},{'field':_0x3f26fd('0xf8'),'alias':_0x3f26fd('0x60'),'ReportId':0x1},{'field':'exten','alias':_0x3f26fd('0x102'),'ReportId':0x1},{'field':_0x3f26fd('0xbe'),'alias':_0x3f26fd('0x92'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x1},{'field':_0x3f26fd('0xfa'),'alias':_0x3f26fd('0x8a'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x1},{'field':_0x3f26fd('0xda'),'alias':_0x3f26fd('0xdb'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x1},{'field':_0x3f26fd('0x37'),'alias':_0x3f26fd('0x1'),'ReportId':0x2},{'field':_0x3f26fd('0x4f'),'alias':_0x3f26fd('0x101'),'ReportId':0x2},{'field':'queuecallerjoinAt','alias':'StartTime','ReportId':0x2},{'field':'CASE\x20WHEN\x20queuecallercomplete=1\x20THEN\x20queuecallercompleteAt\x20ELSE\x20queuecallerLeaveAt\x20END','alias':_0x3f26fd('0x40'),'custom':0x1,'ReportId':0x2},{'field':_0x3f26fd('0x9c'),'alias':_0x3f26fd('0xa0'),'format':_0x3f26fd('0x2a'),'ReportId':0x2},{'field':_0x3f26fd('0x5c'),'alias':_0x3f26fd('0xe5'),'custom':0x1,'ReportId':0x2},{'field':_0x3f26fd('0xea'),'alias':'UniqueId','ReportId':0x3},{'field':_0x3f26fd('0x37'),'alias':'CallerIdNum','ReportId':0x3},{'field':_0x3f26fd('0x55'),'alias':_0x3f26fd('0x64'),'ReportId':0x3},{'field':_0x3f26fd('0x4f'),'alias':_0x3f26fd('0x101'),'ReportId':0x3},{'field':_0x3f26fd('0xb8'),'alias':_0x3f26fd('0x12a'),'ReportId':0x3},{'field':_0x3f26fd('0xcb'),'alias':_0x3f26fd('0x50'),'ReportId':0x3},{'field':_0x3f26fd('0xb5'),'alias':'AgentConnectAt','ReportId':0x3},{'field':_0x3f26fd('0x118'),'alias':_0x3f26fd('0x54'),'ReportId':0x3},{'field':_0x3f26fd('0x9c'),'alias':'AnswerTime','ReportId':0x3},{'field':_0x3f26fd('0x6f'),'alias':_0x3f26fd('0x92'),'ReportId':0x3},{'field':_0x3f26fd('0x8'),'alias':_0x3f26fd('0x8e'),'ReportId':0x3},{'field':_0x3f26fd('0xd9'),'alias':_0x3f26fd('0x83'),'ReportId':0x3},{'field':_0x3f26fd('0xe0'),'alias':_0x3f26fd('0x80'),'ReportId':0x3},{'field':_0x3f26fd('0x31'),'alias':_0x3f26fd('0x100'),'ReportId':0x3},{'field':_0x3f26fd('0x10a'),'alias':_0x3f26fd('0x86'),'ReportId':0x3},{'field':_0x3f26fd('0xe'),'alias':_0x3f26fd('0x102'),'ReportId':0x3},{'field':_0x3f26fd('0xb8'),'alias':_0x3f26fd('0x12a'),'groupBy':0x1,'ReportId':0x4},{'field':_0x3f26fd('0xe0'),'alias':_0x3f26fd('0x99'),'function':'SUM','ReportId':0x4},{'field':_0x3f26fd('0x6f'),'alias':_0x3f26fd('0xf1'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'ReportId':0x4},{'field':_0x3f26fd('0xd9'),'alias':'TotACWTime','function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'ReportId':0x4},{'field':_0x3f26fd('0xbb'),'alias':_0x3f26fd('0xaf'),'function':_0x3f26fd('0xc0'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0x4},{'field':_0x3f26fd('0x3b'),'alias':_0x3f26fd('0xf7'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0x4},{'field':_0x3f26fd('0xe3'),'alias':_0x3f26fd('0x5b'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x4},{'field':'ROUND(SUM(talktime\x20+\x20acwtime)/COUNT(agentcomplete))','alias':'AvgHandleTime','format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x4},{'field':'queue','alias':_0x3f26fd('0x101'),'groupBy':0x1,'ReportId':0x5},{'field':_0x3f26fd('0xe0'),'alias':'Completed','function':_0x3f26fd('0xc0'),'ReportId':0x5},{'field':'talktime','alias':_0x3f26fd('0x12e'),'function':'SUM','format':_0x3f26fd('0x2a'),'ReportId':0x5},{'field':_0x3f26fd('0x9c'),'alias':'Tot\x20HoldTime','function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'ReportId':0x5},{'field':_0x3f26fd('0xd9'),'alias':_0x3f26fd('0x72'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'ReportId':0x5},{'field':_0x3f26fd('0xbb'),'alias':'Tot\x20Handle\x20Time','function':'SUM','format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x5},{'field':_0x3f26fd('0x3b'),'alias':_0x3f26fd('0xb9'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x5},{'field':_0x3f26fd('0x59'),'alias':'Avg\x20HoldTime','format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x5},{'field':_0x3f26fd('0xe3'),'alias':'Avg\x20ACWTime','format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x5},{'field':_0x3f26fd('0x9'),'alias':_0x3f26fd('0x9e'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x5},{'field':_0x3f26fd('0x4f'),'alias':_0x3f26fd('0x101'),'groupBy':0x1,'ReportId':0x6},{'field':_0x3f26fd('0xe0'),'alias':_0x3f26fd('0xc5'),'function':_0x3f26fd('0xc0'),'ReportId':0x6},{'field':_0x3f26fd('0x93'),'alias':_0x3f26fd('0x81'),'custom':0x1,'ReportId':0x6},{'field':_0x3f26fd('0x110'),'alias':_0x3f26fd('0x113'),'custom':0x1,'ReportId':0x6},{'field':_0x3f26fd('0xc6'),'alias':_0x3f26fd('0x5a'),'custom':0x1,'ReportId':0x6},{'field':_0x3f26fd('0x3e'),'alias':'Answer\x20Rate\x2010-20s','custom':0x1,'ReportId':0x6},{'field':_0x3f26fd('0x7e'),'alias':'Answered\x2020-30s','custom':0x1,'ReportId':0x6},{'field':_0x3f26fd('0xa9'),'alias':'Answer\x20Rate\x2020-30s','custom':0x1,'ReportId':0x6},{'field':_0x3f26fd('0x12c'),'alias':'Answered\x20>30s','custom':0x1,'ReportId':0x6},{'field':'ROUND(COUNT(IF(holdtime\x20>=30,1,NULL))\x20/\x20SUM(agentcomplete)\x20*100,1)','alias':'Answer\x20Rate\x20>30s','custom':0x1,'ReportId':0x6},{'field':_0x3f26fd('0x31'),'alias':_0x3f26fd('0x0'),'groupBy':0x1,'ReportId':0x7},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x114'),'function':_0x3f26fd('0xcf'),'ReportId':0x7},{'field':'agentconnectAt','alias':_0x3f26fd('0x53'),'format':_0x3f26fd('0x48'),'groupBy':0x1,'ReportId':0x8},{'field':_0x3f26fd('0xe0'),'alias':_0x3f26fd('0xc5'),'function':'SUM','ReportId':0x8},{'field':_0x3f26fd('0x93'),'alias':_0x3f26fd('0x81'),'custom':0x1,'ReportId':0x8},{'field':_0x3f26fd('0xc6'),'alias':_0x3f26fd('0x5a'),'custom':0x1,'ReportId':0x8},{'field':_0x3f26fd('0x7e'),'alias':_0x3f26fd('0xb6'),'custom':0x1,'ReportId':0x8},{'field':_0x3f26fd('0x12c'),'alias':_0x3f26fd('0xd4'),'custom':0x1,'ReportId':0x8},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x16'),'ReportId':0x9},{'field':_0x3f26fd('0x37'),'alias':_0x3f26fd('0xac'),'ReportId':0x9},{'field':_0x3f26fd('0x4f'),'alias':'Queue','ReportId':0x9},{'field':_0x3f26fd('0x65'),'alias':'JoinAt','ReportId':0x9},{'field':_0x3f26fd('0x119'),'alias':_0x3f26fd('0x67'),'ReportId':0x9},{'field':_0x3f26fd('0x9f'),'alias':'Abandon','ReportId':0x9},{'field':_0x3f26fd('0x38'),'alias':'AbandonAt','ReportId':0x9},{'field':_0x3f26fd('0x9a'),'alias':_0x3f26fd('0x4a'),'ReportId':0x9},{'field':_0x3f26fd('0x1e'),'alias':_0x3f26fd('0x104'),'ReportId':0x9},{'field':_0x3f26fd('0xf8'),'alias':_0x3f26fd('0xb7'),'ReportId':0x9},{'field':'position','alias':_0x3f26fd('0x36'),'ReportId':0x9},{'field':_0x3f26fd('0xe'),'alias':_0x3f26fd('0x102'),'ReportId':0x9},{'field':_0x3f26fd('0xfa'),'alias':'Abandon\x20Time','format':'SEC_TO_TIME','custom':0x1,'ReportId':0x9},{'field':_0x3f26fd('0xa6'),'alias':_0x3f26fd('0x5f'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x9},{'field':_0x3f26fd('0x4f'),'alias':_0x3f26fd('0x101'),'groupBy':0x1,'ReportId':0xa},{'field':'queuecallerabandon','alias':'Abandoned','function':'SUM','ReportId':0xa},{'field':'queuecallerexit','alias':_0x3f26fd('0x4a'),'function':_0x3f26fd('0xc0'),'ReportId':0xa},{'field':_0x3f26fd('0xfa'),'alias':_0x3f26fd('0xd3'),'function':_0x3f26fd('0xc0'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0xa},{'field':_0x3f26fd('0x5'),'alias':'AvgAbandonTime','format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xa},{'field':_0x3f26fd('0xa6'),'alias':_0x3f26fd('0x7'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xa},{'field':'ROUND(AVG(UNIX_TIMESTAMP(queuecallerExitAt)-UNIX_TIMESTAMP(queuecallerjoinAt)))','alias':'Avg\x20Unmanaged\x20TIme','format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xa},{'field':_0x3f26fd('0xf8'),'alias':_0x3f26fd('0x0'),'groupBy':0x1,'ReportId':0xb},{'field':'queuecallerexit','alias':'Calls','function':_0x3f26fd('0xc0'),'ReportId':0xb},{'field':_0x3f26fd('0xa6'),'alias':_0x3f26fd('0x7'),'function':_0x3f26fd('0xc0'),'custom':0x1,'ReportId':0xb},{'field':_0x3f26fd('0x4f'),'alias':_0x3f26fd('0x101'),'groupBy':0x1,'ReportId':0xc},{'field':_0x3f26fd('0x9f'),'alias':_0x3f26fd('0x2'),'function':'SUM','ReportId':0xc},{'field':_0x3f26fd('0x11f'),'alias':_0x3f26fd('0x79'),'custom':0x1,'ReportId':0xc},{'field':_0x3f26fd('0x8f'),'alias':_0x3f26fd('0xe8'),'custom':0x1,'ReportId':0xc},{'field':'COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=10\x20AND\x20UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20<60,1,NULL))','alias':'Abandoned\x2010-60s','custom':0x1,'ReportId':0xc},{'field':_0x3f26fd('0xce'),'alias':_0x3f26fd('0xe6'),'custom':0x1,'ReportId':0xc},{'field':_0x3f26fd('0xd5'),'alias':_0x3f26fd('0x2b'),'custom':0x1,'ReportId':0xc},{'field':_0x3f26fd('0x68'),'alias':'Abandoned\x20Rate\x2060-120s','custom':0x1,'ReportId':0xc},{'field':_0x3f26fd('0x89'),'alias':_0x3f26fd('0xa4'),'custom':0x1,'ReportId':0xc},{'field':'ROUND(COUNT(IF(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)\x20>=120,1,NULL))\x20\x20/\x20SUM(queuecallerabandon)\x20*100,1)','alias':_0x3f26fd('0x125'),'custom':0x1,'ReportId':0xc},{'field':_0x3f26fd('0x6e'),'alias':_0x3f26fd('0x6d'),'format':_0x3f26fd('0xc2'),'groupBy':0x1,'custom':0x1,'ReportId':0xd},{'field':'uniqueid','alias':'Offered','function':_0x3f26fd('0x58'),'ReportId':0xd},{'field':_0x3f26fd('0x75'),'alias':_0x3f26fd('0x99'),'function':_0x3f26fd('0xc0'),'ReportId':0xd},{'field':'queuecallerabandon','alias':_0x3f26fd('0x11'),'function':'SUM','custom':0x1,'ReportId':0xd},{'field':_0x3f26fd('0x9a'),'alias':'Unmanaged','function':_0x3f26fd('0xc0'),'custom':0x1,'ReportId':0xd},{'field':_0x3f26fd('0xbe'),'alias':'Tot\x20TalkTime','function':'SUM','format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xd},{'field':_0x3f26fd('0x44'),'alias':_0x3f26fd('0xf7'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xd},{'field':_0x3f26fd('0x5'),'alias':_0x3f26fd('0xa7'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xd},{'field':_0x3f26fd('0x6e'),'alias':_0x3f26fd('0x53'),'format':_0x3f26fd('0x48'),'groupBy':0x1,'custom':0x1,'ReportId':0xe},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x121'),'function':'COUNT\x20DISTINCT','ReportId':0xe},{'field':_0x3f26fd('0x75'),'alias':'Answered','function':_0x3f26fd('0xc0'),'ReportId':0xe},{'field':_0x3f26fd('0xed'),'alias':_0x3f26fd('0xf'),'custom':0x1,'ReportId':0xe},{'field':_0x3f26fd('0x9f'),'alias':_0x3f26fd('0x11'),'function':_0x3f26fd('0xc0'),'ReportId':0xe},{'field':_0x3f26fd('0x9a'),'alias':'Unmanaged','function':_0x3f26fd('0xc0'),'ReportId':0xe},{'field':_0x3f26fd('0xbe'),'alias':'Tot\x20TalkTime','function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xe},{'field':'ROUND(AVG(UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)))','alias':_0x3f26fd('0xf7'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xe},{'field':'ROUND(AVG(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)))','alias':_0x3f26fd('0xa7'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0xe},{'field':_0x3f26fd('0x4'),'alias':'Day','groupBy':0x1,'custom':0x1,'ReportId':0xf},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x121'),'function':'COUNT\x20DISTINCT','ReportId':0xf},{'field':_0x3f26fd('0x75'),'alias':_0x3f26fd('0xe5'),'function':'SUM','ReportId':0xf},{'field':_0x3f26fd('0xed'),'alias':_0x3f26fd('0xf'),'custom':0x1,'ReportId':0xf},{'field':'queuecallerabandon','alias':_0x3f26fd('0x11'),'function':_0x3f26fd('0xc0'),'ReportId':0xf},{'field':_0x3f26fd('0x9a'),'alias':'Unmanaged','function':_0x3f26fd('0xc0'),'ReportId':0xf},{'field':_0x3f26fd('0xbe'),'alias':'Tot\x20TalkTime','function':'SUM','format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xf},{'field':_0x3f26fd('0x44'),'alias':_0x3f26fd('0xf7'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0xf},{'field':_0x3f26fd('0x5'),'alias':_0x3f26fd('0xa7'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0xf},{'field':_0x3f26fd('0x128'),'alias':'DayOfWeek','groupBy':0x1,'custom':0x1,'ReportId':0x10},{'field':_0x3f26fd('0xea'),'alias':'Offered','function':_0x3f26fd('0x58'),'ReportId':0x10},{'field':_0x3f26fd('0x75'),'alias':_0x3f26fd('0xe5'),'function':_0x3f26fd('0xc0'),'ReportId':0x10},{'field':_0x3f26fd('0xed'),'alias':_0x3f26fd('0xf'),'custom':0x1,'ReportId':0x10},{'field':'queuecallerabandon','alias':_0x3f26fd('0x11'),'function':_0x3f26fd('0xc0'),'orderBy':_0x3f26fd('0x1a'),'ReportId':0x10},{'field':_0x3f26fd('0x9a'),'alias':_0x3f26fd('0x4a'),'function':_0x3f26fd('0xc0'),'ReportId':0x10},{'field':'UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)','alias':_0x3f26fd('0x12e'),'function':_0x3f26fd('0xc0'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0x10},{'field':_0x3f26fd('0x44'),'alias':_0x3f26fd('0xf7'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x10},{'field':'ROUND(AVG(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)))','alias':_0x3f26fd('0xa7'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x10},{'field':_0x3f26fd('0x4f'),'alias':_0x3f26fd('0x101'),'groupBy':0x1,'ReportId':0x11},{'field':'uniqueid','alias':_0x3f26fd('0x121'),'function':_0x3f26fd('0x58'),'ReportId':0x11},{'field':'queuecallercomplete','alias':_0x3f26fd('0xe5'),'function':_0x3f26fd('0xc0'),'ReportId':0x11},{'field':_0x3f26fd('0xed'),'alias':'Answer\x20Rate','custom':0x1,'ReportId':0x11},{'field':'queuecallerabandon','alias':_0x3f26fd('0x11'),'function':_0x3f26fd('0xc0'),'ReportId':0x11},{'field':_0x3f26fd('0x9a'),'alias':'Unmanaged','function':_0x3f26fd('0xc0'),'ReportId':0x11},{'field':'UNIX_TIMESTAMP(queuecallercompleteAt)-UNIX_TIMESTAMP(queuecallerleaveAt)','alias':'Tot\x20TalkTime','function':'SUM','format':'SEC_TO_TIME','custom':0x1,'ReportId':0x11},{'field':_0x3f26fd('0x44'),'alias':_0x3f26fd('0xf7'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x11},{'field':'ROUND(AVG(UNIX_TIMESTAMP(queuecallerAbandonAt)-UNIX_TIMESTAMP(queuecallerjoinAt)))','alias':'AvgAbandonTime','format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x11},{'field':_0x3f26fd('0xea'),'alias':'UniqueID','ReportId':0x12},{'field':'type','alias':_0x3f26fd('0x95'),'ReportId':0x12},{'field':_0x3f26fd('0x2f'),'alias':_0x3f26fd('0xef'),'ReportId':0x12},{'field':_0x3f26fd('0xa'),'alias':_0x3f26fd('0x22'),'ReportId':0x12},{'field':_0x3f26fd('0xd8'),'alias':_0x3f26fd('0x122'),'ReportId':0x12},{'field':'callerid','alias':'CallerID','ReportId':0x12},{'field':_0x3f26fd('0x90'),'alias':_0x3f26fd('0x19'),'ReportId':0x12},{'field':_0x3f26fd('0x28'),'alias':_0x3f26fd('0xbd'),'ReportId':0x12},{'field':_0x3f26fd('0x12b'),'alias':'LastData','ReportId':0x12},{'field':'starttime','alias':_0x3f26fd('0xe9'),'ReportId':0x12},{'field':_0x3f26fd('0x96'),'alias':_0x3f26fd('0xdb'),'ReportId':0x12},{'field':_0x3f26fd('0x15'),'alias':_0x3f26fd('0x40'),'ReportId':0x12},{'field':'duration','alias':'Duration','ReportId':0x12},{'field':_0x3f26fd('0x111'),'alias':_0x3f26fd('0xbc'),'ReportId':0x12},{'field':'uniqueid','alias':_0x3f26fd('0xfd'),'ReportId':0x13},{'field':'accountcode','alias':_0x3f26fd('0xde'),'ReportId':0x13},{'field':_0x3f26fd('0xa'),'alias':_0x3f26fd('0x22'),'ReportId':0x13},{'field':_0x3f26fd('0xd8'),'alias':'Destination','ReportId':0x13},{'field':_0x3f26fd('0xe7'),'alias':_0x3f26fd('0x116'),'ReportId':0x13},{'field':_0x3f26fd('0xd'),'alias':_0x3f26fd('0xe9'),'ReportId':0x13},{'field':_0x3f26fd('0x96'),'alias':'AnswerTime','ReportId':0x13},{'field':_0x3f26fd('0x15'),'alias':_0x3f26fd('0x40'),'ReportId':0x13},{'field':_0x3f26fd('0x47'),'alias':_0x3f26fd('0x66'),'format':_0x3f26fd('0x2a'),'ReportId':0x13},{'field':_0x3f26fd('0x39'),'alias':_0x3f26fd('0xc7'),'format':'SEC_TO_TIME','ReportId':0x13},{'field':'disposition','alias':'Disposition','ReportId':0x13},{'field':_0x3f26fd('0x2f'),'alias':_0x3f26fd('0xef'),'ReportId':0x13},{'field':_0x3f26fd('0x11c'),'alias':_0x3f26fd('0x95'),'groupBy':0x1,'ReportId':0x14},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x114'),'function':_0x3f26fd('0xcf'),'ReportId':0x14},{'field':_0x3f26fd('0x47'),'alias':_0x3f26fd('0x13'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'ReportId':0x14},{'field':_0x3f26fd('0x5d'),'alias':_0x3f26fd('0x112'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x14},{'field':'disposition','alias':_0x3f26fd('0xbc'),'groupBy':0x1,'ReportId':0x15},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x114'),'function':_0x3f26fd('0xcf'),'ReportId':0x15},{'field':_0x3f26fd('0x47'),'alias':_0x3f26fd('0x13'),'function':'SUM','format':_0x3f26fd('0x2a'),'ReportId':0x15},{'field':_0x3f26fd('0x5d'),'alias':_0x3f26fd('0x112'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x15},{'field':'SUBSTRING_INDEX(channel,\x20\x22-\x22,\x201)','alias':'Agent','groupBy':0x1,'custom':0x1,'ReportId':0x16},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x114'),'function':_0x3f26fd('0xcf'),'ReportId':0x16},{'field':_0x3f26fd('0x47'),'alias':_0x3f26fd('0x13'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'ReportId':0x16},{'field':_0x3f26fd('0x5d'),'alias':_0x3f26fd('0x112'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0x16},{'field':_0x3f26fd('0xd'),'alias':_0x3f26fd('0x6d'),'format':_0x3f26fd('0xc2'),'groupBy':0x1,'ReportId':0x17},{'field':_0x3f26fd('0xea'),'alias':'Calls','function':'COUNT','ReportId':0x17},{'field':_0x3f26fd('0x47'),'alias':_0x3f26fd('0x13'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'ReportId':0x17},{'field':'ROUND(AVG(duration))','alias':_0x3f26fd('0x112'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x17},{'field':'membername','alias':_0x3f26fd('0x12a'),'groupBy':0x1,'orderBy':'ASC','ReportId':0x18},{'field':_0x3f26fd('0x1d'),'alias':_0x3f26fd('0x66'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x18},{'field':_0x3f26fd('0xb8'),'alias':_0x3f26fd('0x12a'),'groupBy':0x1,'ReportId':0x19},{'field':_0x3f26fd('0x4b'),'alias':_0x3f26fd('0x10c'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x19},{'field':_0x3f26fd('0x130'),'alias':_0x3f26fd('0x107'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x19},{'field':_0x3f26fd('0x6c'),'alias':_0x3f26fd('0x62'),'function':_0x3f26fd('0xc0'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0x19},{'field':_0x3f26fd('0xb8'),'alias':_0x3f26fd('0x12a'),'ReportId':0x1a},{'field':'enterAt','alias':_0x3f26fd('0x11d'),'ReportId':0x1a},{'field':_0x3f26fd('0xbf'),'alias':'ExitAt','ReportId':0x1a},{'field':_0x3f26fd('0xc4'),'alias':_0x3f26fd('0xf3'),'ReportId':0x1a},{'field':_0x3f26fd('0x47'),'alias':_0x3f26fd('0x66'),'format':_0x3f26fd('0x2a'),'ReportId':0x1a},{'field':_0x3f26fd('0xb8'),'alias':'Agent','ReportId':0x1b},{'field':_0x3f26fd('0x73'),'alias':_0x3f26fd('0x4d'),'ReportId':0x1b},{'field':_0x3f26fd('0x11c'),'alias':_0x3f26fd('0x1b'),'ReportId':0x1b},{'field':_0x3f26fd('0xc4'),'alias':_0x3f26fd('0x95'),'ReportId':0x1b},{'field':_0x3f26fd('0x12d'),'alias':_0x3f26fd('0x11d'),'ReportId':0x1b},{'field':_0x3f26fd('0xbf'),'alias':'ExitAt','ReportId':0x1b},{'field':'UNIX_TIMESTAMP(exitAt)-UNIX_TIMESTAMP(enterAt)','alias':_0x3f26fd('0x66'),'format':'SEC_TO_TIME','custom':0x1,'ReportId':0x1b},{'field':'membername','alias':_0x3f26fd('0x12a'),'groupBy':0x1,'orderBy':'ASC','ReportId':0x1c},{'field':_0x3f26fd('0xc4'),'alias':'PauseType','groupBy':0x1,'orderBy':_0x3f26fd('0x1a'),'ReportId':0x1c},{'field':_0x3f26fd('0x1d'),'alias':_0x3f26fd('0x66'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x1c},{'field':_0x3f26fd('0x27'),'alias':'Project\x20Name','ReportId':0x1d},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x16'),'ReportId':0x1d},{'field':'callerid','alias':'CallerId','ReportId':0x1d},{'field':'dnid','alias':'DID','ReportId':0x1d},{'field':'joinAt','alias':_0x3f26fd('0x3'),'orderBy':_0x3f26fd('0x1a'),'ReportId':0x1d},{'field':_0x3f26fd('0xee'),'alias':'End\x20Time','ReportId':0x1d},{'field':_0x3f26fd('0x85'),'alias':_0x3f26fd('0x66'),'format':_0x3f26fd('0x2a'),'custom':0x1,'ReportId':0x1d},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x41'),'ReportId':0x1e},{'field':_0x3f26fd('0x27'),'alias':_0x3f26fd('0xaa'),'ReportId':0x1e},{'field':'callerid','alias':_0x3f26fd('0x77'),'ReportId':0x1e},{'field':_0x3f26fd('0x76'),'alias':'Block','ReportId':0x1e},{'field':_0x3f26fd('0x88'),'alias':_0x3f26fd('0xd0'),'ReportId':0x1e},{'field':_0x3f26fd('0x35'),'alias':_0x3f26fd('0x12a'),'groupBy':0x1,'ReportId':0x1f},{'field':_0x3f26fd('0xea'),'alias':'Recorded\x20Calls','function':_0x3f26fd('0xcf'),'ReportId':0x1f},{'field':_0x3f26fd('0x9b'),'alias':_0x3f26fd('0x3f'),'function':_0x3f26fd('0xc0'),'ReportId':0x1f},{'field':_0x3f26fd('0x9b'),'alias':'Avg\x20Rating','function':_0x3f26fd('0x129'),'ReportId':0x1f},{'field':'queue','alias':_0x3f26fd('0x101'),'groupBy':0x1,'ReportId':0x20},{'field':_0x3f26fd('0xea'),'alias':_0x3f26fd('0x8d'),'function':_0x3f26fd('0xcf'),'ReportId':0x20},{'field':_0x3f26fd('0x9b'),'alias':_0x3f26fd('0x3f'),'function':_0x3f26fd('0xc0'),'ReportId':0x20},{'field':_0x3f26fd('0x9b'),'alias':'Avg\x20Rating','function':'AVG','ReportId':0x20},{'field':_0x3f26fd('0x4c'),'alias':_0x3f26fd('0x98'),'ReportId':0x21},{'field':_0x3f26fd('0x37'),'alias':_0x3f26fd('0xac'),'ReportId':0x21},{'field':_0x3f26fd('0xd'),'alias':'LastCallAt','orderBy':'DESC','ReportId':0x21},{'field':'statedesc','alias':_0x3f26fd('0x61'),'ReportId':0x21},{'field':_0x3f26fd('0x12f'),'alias':'Global\x20Count','ReportId':0x21},{'field':_0x3f26fd('0xc'),'alias':_0x3f26fd('0xab'),'ReportId':0x21},{'field':_0x3f26fd('0x74'),'alias':_0x3f26fd('0xb3'),'ReportId':0x21},{'field':'membername','alias':'Agent','ReportId':0x21},{'field':'talktime','alias':_0x3f26fd('0x107'),'ReportId':0x21},{'field':_0x3f26fd('0x111'),'alias':'Disposition','ReportId':0x21},{'field':_0x3f26fd('0xea'),'alias':'UniqueId','ReportId':0x21},{'field':_0x3f26fd('0xf9'),'alias':'State','groupBy':!![],'orderBy':_0x3f26fd('0x1a'),'ReportId':0x22},{'field':'id','alias':_0x3f26fd('0x114'),'function':_0x3f26fd('0xcf'),'ReportId':0x22},{'field':_0x3f26fd('0xd2'),'alias':_0x3f26fd('0xca'),'custom':!![],'ReportId':0x22},{'field':_0x3f26fd('0x4c'),'alias':_0x3f26fd('0x98'),'orderBy':_0x3f26fd('0x1a'),'groupBy':!![],'ReportId':0x23},{'field':'statedesc','alias':'State','groupBy':!![],'ReportId':0x23},{'field':'id','alias':'Total\x20Calls','function':'COUNT','ReportId':0x23},{'field':'ListId','groupBy':!![],'orderBy':_0x3f26fd('0x1a'),'ReportId':0x24},{'field':'id','alias':_0x3f26fd('0x82'),'function':_0x3f26fd('0xcf'),'ReportId':0x24},{'field':_0x3f26fd('0xc9'),'alias':_0x3f26fd('0xdf'),'custom':!![],'ReportId':0x24},{'field':'ROUND(SUM(IF(state=4,1,0))/COUNT(*)*100,1)','alias':'Penetration\x20Rate','custom':!![],'ReportId':0x24},{'field':_0x3f26fd('0xb8'),'alias':_0x3f26fd('0x12a'),'groupBy':!![],'orderBy':_0x3f26fd('0x1a'),'ReportId':0x25},{'field':'id','alias':_0x3f26fd('0x114'),'function':'COUNT','ReportId':0x25},{'field':_0x3f26fd('0x23'),'alias':_0x3f26fd('0x1f'),'custom':!![],'ReportId':0x25},{'field':'disposition','alias':_0x3f26fd('0xbc'),'groupBy':!![],'ReportId':0x26},{'field':'id','alias':'Total','function':'COUNT','ReportId':0x26},{'field':_0x3f26fd('0x14'),'alias':'Total\x20(%)','custom':!![],'ReportId':0x26},{'field':_0x3f26fd('0xb8'),'alias':_0x3f26fd('0x12a'),'groupBy':!![],'ReportId':0x27},{'field':'disposition','alias':_0x3f26fd('0xbc'),'groupBy':!![],'ReportId':0x27},{'field':'id','alias':'Total','function':_0x3f26fd('0xcf'),'ReportId':0x27},{'field':_0x3f26fd('0x14'),'alias':'Total\x20(%)','custom':!![],'ReportId':0x27},{'field':_0x3f26fd('0x4c'),'alias':_0x3f26fd('0x98'),'ReportId':0x28},{'field':_0x3f26fd('0x37'),'alias':'CallerIdNum','ReportId':0x28},{'field':'starttime','alias':_0x3f26fd('0xd6'),'orderBy':_0x3f26fd('0xeb'),'ReportId':0x28},{'field':_0x3f26fd('0xf9'),'alias':'State','ReportId':0x28},{'field':_0x3f26fd('0x12f'),'alias':_0x3f26fd('0xb0'),'ReportId':0x28},{'field':_0x3f26fd('0xc'),'alias':_0x3f26fd('0xab'),'ReportId':0x28},{'field':_0x3f26fd('0x74'),'alias':_0x3f26fd('0xb3'),'ReportId':0x28},{'field':_0x3f26fd('0x6f'),'alias':_0x3f26fd('0x107'),'ReportId':0x28},{'field':_0x3f26fd('0xea'),'alias':'UniqueId','ReportId':0x28},{'field':'statedesc','alias':_0x3f26fd('0x61'),'groupBy':!![],'orderBy':_0x3f26fd('0x1a'),'ReportId':0x29},{'field':'id','alias':'Calls','function':_0x3f26fd('0xcf'),'ReportId':0x29},{'field':_0x3f26fd('0x103'),'alias':_0x3f26fd('0xca'),'custom':!![],'ReportId':0x29},{'field':_0x3f26fd('0x4c'),'alias':_0x3f26fd('0x98'),'orderBy':_0x3f26fd('0x1a'),'groupBy':!![],'ReportId':0x2a},{'field':'statedesc','alias':_0x3f26fd('0x61'),'groupBy':!![],'ReportId':0x2a},{'field':'id','alias':_0x3f26fd('0x1c'),'function':_0x3f26fd('0xcf'),'ReportId':0x2a},{'field':_0x3f26fd('0x17'),'groupBy':!![],'orderBy':_0x3f26fd('0x1a'),'ReportId':0x2b},{'field':'id','alias':'Contacts','function':_0x3f26fd('0xcf'),'ReportId':0x2b},{'field':_0x3f26fd('0xc9'),'alias':'Managed','custom':!![],'ReportId':0x2b},{'field':_0x3f26fd('0x21'),'alias':_0x3f26fd('0xf2'),'custom':!![],'ReportId':0x2b},{'field':_0x3f26fd('0x10'),'alias':'Web\x20Site','groupBy':!![],'ReportId':0x2c},{'field':_0x3f26fd('0x115'),'alias':_0x3f26fd('0x7b'),'function':'COUNT','ReportId':0x2c},{'field':_0x3f26fd('0xa1'),'alias':'Open','custom':!![],'ReportId':0x2c},{'field':_0x3f26fd('0xae'),'alias':'Closed','custom':!![],'ReportId':0x2c},{'field':_0x3f26fd('0xf6'),'alias':_0x3f26fd('0x4a'),'custom':!![],'ReportId':0x2c},{'field':_0x3f26fd('0x20'),'alias':'Abandoned','custom':!![],'ReportId':0x2c},{'field':'chat_websites.name','alias':'Web\x20Site','groupBy':!![],'ReportId':0x2d},{'field':_0x3f26fd('0x3c'),'alias':'Interaction\x20Time','function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x2d},{'field':_0x3f26fd('0x78'),'alias':'AVG\x20Interaction\x20Time','format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x2d},{'field':_0x3f26fd('0x134'),'alias':_0x3f26fd('0x12a'),'groupBy':!![],'ReportId':0x2e},{'field':_0x3f26fd('0x11b'),'alias':_0x3f26fd('0xc1'),'function':_0x3f26fd('0xc0'),'ReportId':0x2e},{'field':_0x3f26fd('0x3c'),'alias':_0x3f26fd('0x46'),'function':_0x3f26fd('0xc0'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x2e},{'field':_0x3f26fd('0x78'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x2e},{'field':_0x3f26fd('0x133'),'alias':'Date','format':_0x3f26fd('0xc2'),'groupBy':!![],'custom':!![],'ReportId':0x2f},{'field':'chat_interactions.id','alias':_0x3f26fd('0x7b'),'function':_0x3f26fd('0xcf'),'ReportId':0x2f},{'field':_0x3f26fd('0xae'),'alias':_0x3f26fd('0x99'),'custom':!![],'ReportId':0x2f},{'field':_0x3f26fd('0xf5'),'alias':_0x3f26fd('0xc8'),'custom':!![],'ReportId':0x2f},{'field':'COUNT(IF(closed=1\x20&&\x20disposition\x20=\x27unmanaged\x27,1,NULL))','alias':_0x3f26fd('0x4a'),'custom':!![],'ReportId':0x2f},{'field':_0x3f26fd('0x63'),'alias':_0x3f26fd('0x9d'),'custom':!![],'ReportId':0x2f},{'field':_0x3f26fd('0x20'),'alias':'Abandoned','custom':!![],'ReportId':0x2f},{'field':_0x3f26fd('0x57'),'alias':_0x3f26fd('0x11a'),'custom':!![],'ReportId':0x2f},{'field':_0x3f26fd('0x49'),'alias':_0x3f26fd('0x46'),'function':_0x3f26fd('0xc0'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x2f},{'field':_0x3f26fd('0xf0'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x2f},{'field':'chat_queues.name','alias':'Queue','groupBy':!![],'ReportId':0x30},{'field':_0x3f26fd('0xa5'),'alias':'Interactions','function':_0x3f26fd('0xcf'),'ReportId':0x30},{'field':_0x3f26fd('0x108'),'alias':_0x3f26fd('0x131'),'custom':!![],'ReportId':0x30},{'field':_0x3f26fd('0xb1'),'alias':_0x3f26fd('0x32'),'custom':!![],'ReportId':0x30},{'field':_0x3f26fd('0x85'),'alias':_0x3f26fd('0xe1'),'function':'SUM','format':'SEC_TO_TIME','custom':!![],'ReportId':0x30},{'field':_0x3f26fd('0x10b'),'alias':_0x3f26fd('0x6'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x30},{'field':_0x3f26fd('0x2c'),'alias':_0x3f26fd('0x117'),'groupBy':!![],'ReportId':0x31},{'field':'mail_interactions.id','alias':_0x3f26fd('0x7b'),'function':_0x3f26fd('0xcf'),'ReportId':0x31},{'field':_0x3f26fd('0xa1'),'alias':_0x3f26fd('0xb4'),'custom':!![],'ReportId':0x31},{'field':'COUNT(IF(closed=1,1,NULL))','alias':_0x3f26fd('0xc1'),'custom':!![],'ReportId':0x31},{'field':_0x3f26fd('0x2c'),'alias':_0x3f26fd('0x117'),'groupBy':!![],'ReportId':0x32},{'field':_0x3f26fd('0xa3'),'alias':_0x3f26fd('0x46'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x32},{'field':_0x3f26fd('0xd7'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x32},{'field':_0x3f26fd('0x134'),'alias':_0x3f26fd('0x12a'),'groupBy':!![],'ReportId':0x33},{'field':_0x3f26fd('0x42'),'alias':_0x3f26fd('0xc1'),'function':_0x3f26fd('0xc0'),'ReportId':0x33},{'field':_0x3f26fd('0xa3'),'alias':'Interaction\x20Time','function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x33},{'field':_0x3f26fd('0xd7'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x33},{'field':_0x3f26fd('0xdd'),'alias':_0x3f26fd('0x6d'),'format':_0x3f26fd('0xc2'),'groupBy':!![],'custom':!![],'ReportId':0x34},{'field':_0x3f26fd('0x5e'),'alias':_0x3f26fd('0x7b'),'function':_0x3f26fd('0xcf'),'ReportId':0x34},{'field':_0x3f26fd('0x94'),'alias':_0x3f26fd('0x99'),'custom':!![],'ReportId':0x34},{'field':'ROUND(COUNT(IF(closed=1,1,NULL))/COUNT(id)\x20*100,1)','alias':'Completed\x20(%)','custom':!![],'ReportId':0x34},{'field':_0x3f26fd('0x49'),'alias':'Interaction\x20Time','function':'SUM','format':'SEC_TO_TIME','custom':!![],'ReportId':0x34},{'field':_0x3f26fd('0xf0'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x34},{'field':_0x3f26fd('0x30'),'alias':_0x3f26fd('0x101'),'groupBy':!![],'ReportId':0x35},{'field':'report_mail_queue.id','alias':_0x3f26fd('0x7b'),'function':_0x3f26fd('0xcf'),'ReportId':0x35},{'field':'COUNT(IF(reason=\x27accepted\x27,1,NULL))','alias':_0x3f26fd('0x131'),'custom':!![],'ReportId':0x35},{'field':_0x3f26fd('0xb1'),'alias':_0x3f26fd('0x32'),'custom':!![],'ReportId':0x35},{'field':_0x3f26fd('0x85'),'alias':'Hold\x20Time','function':'SUM','format':'SEC_TO_TIME','custom':!![],'ReportId':0x35},{'field':_0x3f26fd('0x10b'),'alias':_0x3f26fd('0x6'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x35},{'field':'openchannel_accounts.name','alias':_0x3f26fd('0xf4'),'groupBy':!![],'ReportId':0x36},{'field':'openchannel_interactions.id','alias':_0x3f26fd('0x7b'),'function':_0x3f26fd('0xcf'),'ReportId':0x36},{'field':'COUNT(IF(closed=0,1,NULL))','alias':_0x3f26fd('0xb4'),'custom':!![],'ReportId':0x36},{'field':_0x3f26fd('0x94'),'alias':_0x3f26fd('0xc1'),'custom':!![],'ReportId':0x36},{'field':_0x3f26fd('0xa8'),'alias':_0x3f26fd('0xf4'),'groupBy':!![],'ReportId':0x37},{'field':_0x3f26fd('0x124'),'alias':_0x3f26fd('0x46'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x37},{'field':_0x3f26fd('0x7a'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x37},{'field':_0x3f26fd('0x134'),'alias':_0x3f26fd('0x12a'),'groupBy':!![],'ReportId':0x38},{'field':_0x3f26fd('0x127'),'alias':'Closed','function':_0x3f26fd('0xc0'),'ReportId':0x38},{'field':_0x3f26fd('0x124'),'alias':_0x3f26fd('0x46'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x38},{'field':_0x3f26fd('0x7a'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x38},{'field':_0x3f26fd('0x12'),'alias':_0x3f26fd('0x6d'),'format':_0x3f26fd('0xc2'),'groupBy':!![],'custom':!![],'ReportId':0x39},{'field':_0x3f26fd('0xb2'),'alias':_0x3f26fd('0x7b'),'function':_0x3f26fd('0xcf'),'ReportId':0x39},{'field':_0x3f26fd('0x94'),'alias':'Completed','custom':!![],'ReportId':0x39},{'field':_0x3f26fd('0x109'),'alias':_0x3f26fd('0xc8'),'custom':!![],'ReportId':0x39},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(createdAt)','alias':'Interaction\x20Time','function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x39},{'field':_0x3f26fd('0xf0'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x39},{'field':'openchannel_queues.name','alias':_0x3f26fd('0x101'),'groupBy':!![],'ReportId':0x3a},{'field':_0x3f26fd('0x29'),'alias':'Interactions','function':_0x3f26fd('0xcf'),'ReportId':0x3a},{'field':_0x3f26fd('0x108'),'alias':_0x3f26fd('0x131'),'custom':!![],'ReportId':0x3a},{'field':_0x3f26fd('0xb1'),'alias':_0x3f26fd('0x32'),'custom':!![],'ReportId':0x3a},{'field':_0x3f26fd('0x85'),'alias':_0x3f26fd('0xe1'),'function':'SUM','format':'SEC_TO_TIME','custom':!![],'ReportId':0x3a},{'field':_0x3f26fd('0x10b'),'alias':_0x3f26fd('0x6'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x3a},{'field':_0x3f26fd('0x33'),'alias':_0x3f26fd('0x52'),'groupBy':!![],'ReportId':0x3b},{'field':_0x3f26fd('0x105'),'alias':_0x3f26fd('0x7b'),'function':'COUNT','ReportId':0x3b},{'field':_0x3f26fd('0xa1'),'alias':_0x3f26fd('0xb4'),'custom':!![],'ReportId':0x3b},{'field':_0x3f26fd('0x94'),'alias':'Closed','custom':!![],'ReportId':0x3b},{'field':'sms_accounts.name','alias':_0x3f26fd('0x52'),'groupBy':!![],'ReportId':0x3c},{'field':_0x3f26fd('0x3d'),'alias':_0x3f26fd('0x46'),'function':'SUM','format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x3c},{'field':_0x3f26fd('0x25'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x3c},{'field':_0x3f26fd('0x134'),'alias':_0x3f26fd('0x12a'),'groupBy':!![],'ReportId':0x3d},{'field':_0x3f26fd('0x135'),'alias':_0x3f26fd('0xc1'),'function':_0x3f26fd('0xc0'),'ReportId':0x3d},{'field':_0x3f26fd('0x3d'),'alias':_0x3f26fd('0x46'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x3d},{'field':_0x3f26fd('0x25'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x3d},{'field':_0x3f26fd('0x18'),'alias':_0x3f26fd('0x6d'),'format':_0x3f26fd('0xc2'),'groupBy':!![],'custom':!![],'ReportId':0x3e},{'field':_0x3f26fd('0x105'),'alias':_0x3f26fd('0x7b'),'function':'COUNT','ReportId':0x3e},{'field':_0x3f26fd('0x94'),'alias':_0x3f26fd('0x99'),'custom':!![],'ReportId':0x3e},{'field':_0x3f26fd('0x109'),'alias':_0x3f26fd('0xc8'),'custom':!![],'ReportId':0x3e},{'field':_0x3f26fd('0x49'),'alias':'Interaction\x20Time','function':'SUM','format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x3e},{'field':_0x3f26fd('0xf0'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x3e},{'field':_0x3f26fd('0xff'),'alias':_0x3f26fd('0x101'),'groupBy':!![],'ReportId':0x3f},{'field':_0x3f26fd('0xa2'),'alias':_0x3f26fd('0x7b'),'function':'COUNT','ReportId':0x3f},{'field':_0x3f26fd('0x108'),'alias':_0x3f26fd('0x131'),'custom':!![],'ReportId':0x3f},{'field':_0x3f26fd('0xb1'),'alias':_0x3f26fd('0x32'),'custom':!![],'ReportId':0x3f},{'field':'UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)','alias':_0x3f26fd('0xe1'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x3f},{'field':'ROUND(AVG(UNIX_TIMESTAMP(leaveAt)-UNIX_TIMESTAMP(joinAt)))','alias':'AVG\x20Hold\x20Time','format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x3f},{'field':_0x3f26fd('0x34'),'alias':_0x3f26fd('0x101'),'groupBy':!![],'ReportId':0x44},{'field':'report_fax_queue.id','alias':'Interactions','function':_0x3f26fd('0xcf'),'ReportId':0x44},{'field':_0x3f26fd('0x108'),'alias':'Accepted','custom':!![],'ReportId':0x44},{'field':_0x3f26fd('0xb1'),'alias':'Timeout','custom':!![],'ReportId':0x44},{'field':_0x3f26fd('0x85'),'alias':_0x3f26fd('0xe1'),'function':_0x3f26fd('0xc0'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x44},{'field':_0x3f26fd('0x10b'),'alias':'AVG\x20Hold\x20Time','format':'SEC_TO_TIME','custom':!![],'ReportId':0x44},{'field':_0x3f26fd('0xba'),'alias':_0x3f26fd('0x6d'),'format':_0x3f26fd('0xc2'),'groupBy':!![],'custom':!![],'ReportId':0x43},{'field':_0x3f26fd('0x43'),'alias':'Interactions','function':'COUNT','ReportId':0x43},{'field':_0x3f26fd('0x94'),'alias':_0x3f26fd('0x99'),'custom':!![],'ReportId':0x43},{'field':_0x3f26fd('0x109'),'alias':'Completed\x20(%)','custom':!![],'ReportId':0x43},{'field':_0x3f26fd('0x49'),'alias':'Interaction\x20Time','function':'SUM','format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x43},{'field':_0x3f26fd('0xf0'),'alias':_0x3f26fd('0x8b'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x43},{'field':_0x3f26fd('0x134'),'alias':_0x3f26fd('0x12a'),'groupBy':!![],'ReportId':0x42},{'field':_0x3f26fd('0xdc'),'alias':_0x3f26fd('0xc1'),'function':_0x3f26fd('0xc0'),'ReportId':0x42},{'field':_0x3f26fd('0x56'),'alias':_0x3f26fd('0x46'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x42},{'field':_0x3f26fd('0x97'),'alias':'AVG\x20Interaction\x20Time','format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x42},{'field':_0x3f26fd('0xad'),'alias':_0x3f26fd('0x120'),'groupBy':!![],'ReportId':0x41},{'field':_0x3f26fd('0x56'),'alias':_0x3f26fd('0x46'),'function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x41},{'field':_0x3f26fd('0x97'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x41},{'field':_0x3f26fd('0xad'),'alias':'Fax\x20Account','groupBy':!![],'ReportId':0x40},{'field':_0x3f26fd('0x43'),'alias':'Interactions','function':_0x3f26fd('0xcf'),'ReportId':0x40},{'field':_0x3f26fd('0xa1'),'alias':'Open','custom':!![],'ReportId':0x40},{'field':_0x3f26fd('0x94'),'alias':'Closed','custom':!![],'ReportId':0x40},{'field':_0x3f26fd('0x6a'),'alias':_0x3f26fd('0x70'),'groupBy':!![],'custom':![],'ReportId':0x4a},{'field':'users.fullname','alias':_0x3f26fd('0x4e'),'groupBy':![],'custom':![],'ReportId':0x4a},{'field':_0x3f26fd('0x2e'),'alias':_0x3f26fd('0x24'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':'COUNT\x20(IF(voice_recordings.sentiment\x20=\x20\x27NEGATIVE\x27,1,NULL))','alias':_0x3f26fd('0x123'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x3f26fd('0x7f'),'alias':_0x3f26fd('0x132'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x3f26fd('0x6b'),'alias':_0x3f26fd('0xec'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':'voice_recordings.sentiment','alias':_0x3f26fd('0x10e'),'function':_0x3f26fd('0xcf'),'groupBy':![],'custom':![],'ReportId':0x4a},{'field':_0x3f26fd('0xcd'),'alias':_0x3f26fd('0x51'),'groupBy':![],'custom':!![],'ReportId':0x45},{'field':'CONCAT(ROUND((\x20(SELECT\x20COUNT(IF(voice_recordings.sentiment\x20=\x20\x27NEGATIVE\x27,1,NULL)))*100/\x20COUNT\x20(voice_recordings.sentiment)),2),\x27%\x27)','alias':_0x3f26fd('0xe2'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x3f26fd('0x69'),'alias':_0x3f26fd('0x126'),'groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x3f26fd('0xcc'),'alias':'Mixed(%)','groupBy':![],'custom':!![],'ReportId':0x4a},{'field':_0x3f26fd('0x106'),'alias':_0x3f26fd('0xb'),'function':_0x3f26fd('0xcf'),'groupBy':![],'custom':![],'ReportId':0x4b},{'field':_0x3f26fd('0x2e'),'alias':_0x3f26fd('0x24'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x3f26fd('0x8c'),'alias':'NEGATIVE','groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x3f26fd('0x7f'),'alias':_0x3f26fd('0x132'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x3f26fd('0x6b'),'alias':_0x3f26fd('0xec'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x3f26fd('0xcd'),'alias':_0x3f26fd('0x51'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x3f26fd('0x45'),'alias':'Negative(%)','groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x3f26fd('0x69'),'alias':_0x3f26fd('0x126'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x3f26fd('0xcc'),'alias':_0x3f26fd('0x11e'),'groupBy':![],'custom':!![],'ReportId':0x4b},{'field':_0x3f26fd('0x87'),'alias':_0x3f26fd('0x10d'),'groupBy':!![],'ReportId':0x45},{'field':_0x3f26fd('0xfc'),'alias':'Interactions','function':_0x3f26fd('0xcf'),'ReportId':0x45},{'field':_0x3f26fd('0xa1'),'alias':_0x3f26fd('0xb4'),'custom':!![],'ReportId':0x45},{'field':_0x3f26fd('0x94'),'alias':_0x3f26fd('0xc1'),'custom':!![],'ReportId':0x45},{'field':'whatsapp_accounts.name','alias':_0x3f26fd('0x10d'),'groupBy':!![],'ReportId':0x46},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(whatsapp_interactions.createdAt)','alias':'Interaction\x20Time','function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x46},{'field':_0x3f26fd('0xd1'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x46},{'field':_0x3f26fd('0x134'),'alias':_0x3f26fd('0x12a'),'groupBy':!![],'ReportId':0x47},{'field':_0x3f26fd('0xfe'),'alias':'Closed','function':'SUM','ReportId':0x47},{'field':_0x3f26fd('0x10f'),'alias':_0x3f26fd('0x46'),'function':'SUM','format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x47},{'field':_0x3f26fd('0xd1'),'alias':_0x3f26fd('0x8b'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x47},{'field':'whatsapp_interactions.createdAt','alias':_0x3f26fd('0x6d'),'format':'DATE','groupBy':!![],'custom':!![],'ReportId':0x48},{'field':'whatsapp_interactions.id','alias':_0x3f26fd('0x7b'),'function':_0x3f26fd('0xcf'),'ReportId':0x48},{'field':_0x3f26fd('0x94'),'alias':_0x3f26fd('0x99'),'custom':!![],'ReportId':0x48},{'field':_0x3f26fd('0x109'),'alias':_0x3f26fd('0xc8'),'custom':!![],'ReportId':0x48},{'field':'UNIX_TIMESTAMP(closedAt)-UNIX_TIMESTAMP(createdAt)','alias':'Interaction\x20Time','function':_0x3f26fd('0xc0'),'format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x48},{'field':_0x3f26fd('0xf0'),'alias':'AVG\x20Interaction\x20Time','format':'SEC_TO_TIME','custom':!![],'ReportId':0x48},{'field':'whatsapp_queues.name','alias':_0x3f26fd('0x101'),'groupBy':!![],'ReportId':0x49},{'field':_0x3f26fd('0x2d'),'alias':_0x3f26fd('0x7b'),'function':_0x3f26fd('0xcf'),'ReportId':0x49},{'field':_0x3f26fd('0x108'),'alias':_0x3f26fd('0x131'),'custom':!![],'ReportId':0x49},{'field':_0x3f26fd('0xb1'),'alias':_0x3f26fd('0x32'),'custom':!![],'ReportId':0x49},{'field':_0x3f26fd('0x85'),'alias':_0x3f26fd('0xe1'),'function':'SUM','format':_0x3f26fd('0x2a'),'custom':!![],'ReportId':0x49},{'field':_0x3f26fd('0x10b'),'alias':_0x3f26fd('0x6'),'format':'SEC_TO_TIME','custom':!![],'ReportId':0x49}];return _[_0x3f26fd('0xfb')](_0x471fe9,_0x3f26fd('0x7c'));}; \ No newline at end of file diff --git a/server/config/seedDB/report/index.js b/server/config/seedDB/report/index.js index a04c353..0b5ceb7 100644 --- a/server/config/seedDB/report/index.js +++ b/server/config/seedDB/report/index.js @@ -1 +1 @@ -var a870_0xab8e=['./default','exports'];(function(_0x386a6d,_0xab8e33){var _0x10027b=function(_0x107382){while(--_0x107382){_0x386a6d['push'](_0x386a6d['shift']());}};_0x10027b(++_0xab8e33);}(a870_0xab8e,0x13c));var a870_0x1002=function(_0x386a6d,_0xab8e33){_0x386a6d=_0x386a6d-0x0;var _0x10027b=a870_0xab8e[_0x386a6d];return _0x10027b;};var _0x13ddd6=a870_0x1002;'use strict';module[_0x13ddd6('0x1')]={'default':require(_0x13ddd6('0x0')),'fields':require('./fields')}; \ No newline at end of file +'use strict';module['exports']={'default':require('./default'),'fields':require('./fields')}; \ No newline at end of file diff --git a/server/config/seedDB/sounds.js b/server/config/seedDB/sounds.js index e8a5263..94470d4 100644 --- a/server/config/seedDB/sounds.js +++ b/server/config/seedDB/sounds.js @@ -1 +1 @@ -const a871_0x5342=['wav','Order\x20Shipped','Call\x20Rating\x20Message','Agent\x20End\x20Pause','Agent\x20Login','thanx','create','agentmanagement-pause','app','Agent\x20Action\x20Failure','Order\x20Message','error','Can\x27t\x20create\x20Sounds','Agent\x20Menu','order-number','Thank\x20You','Agent\x20Logout','Welcome\x20Message','Order\x20Elaborated','agentmanagement-action-failure','agentmanagement-unpause','agentmanagement-login','Sounds\x20have\x20been\x20created','../logger','mp3','order-elaborated','agentmanagement-logout','Agent\x20Pause','info','then','welcome-acme','catch','../../mysqldb','bulkCreate','auto\x20generated\x20sound'];(function(_0x5d984b,_0x5342ea){const _0x160337=function(_0x3690e8){while(--_0x3690e8){_0x5d984b['push'](_0x5d984b['shift']());}};_0x160337(++_0x5342ea);}(a871_0x5342,0x14c));const a871_0x1603=function(_0x5d984b,_0x5342ea){_0x5d984b=_0x5d984b-0x0;let _0x160337=a871_0x5342[_0x5d984b];return _0x160337;};const _0x2eb120=a871_0x1603;'use strict';const db=require(_0x2eb120('0xf'))['db'],logger=require(_0x2eb120('0x6'))(_0x2eb120('0x1a')),sounds=[{'id':0x1,'name':_0x2eb120('0x0'),'save_name':_0x2eb120('0xd'),'display_name':_0x2eb120('0x0'),'original_format':_0x2eb120('0x12'),'converted_format':_0x2eb120('0x12'),'description':_0x2eb120('0x11')},{'id':0x2,'name':_0x2eb120('0x1c'),'save_name':_0x2eb120('0x20'),'display_name':'Order\x20Message','original_format':_0x2eb120('0x12'),'converted_format':_0x2eb120('0x12'),'description':_0x2eb120('0x11')},{'id':0x3,'name':_0x2eb120('0x13'),'save_name':'order-shipped','display_name':'Order\x20Shipped','original_format':'wav','converted_format':_0x2eb120('0x12'),'description':_0x2eb120('0x11')},{'id':0x4,'name':_0x2eb120('0x1'),'save_name':_0x2eb120('0x8'),'display_name':'Order\x20Elaborated','original_format':'wav','converted_format':_0x2eb120('0x12'),'description':_0x2eb120('0x11')},{'id':0x5,'name':'Call\x20Rating\x20Message','save_name':'rate-call','display_name':_0x2eb120('0x14'),'original_format':'wav','converted_format':_0x2eb120('0x12'),'description':'auto\x20generated\x20sound'},{'id':0x6,'name':'Thank\x20You','save_name':_0x2eb120('0x17'),'display_name':_0x2eb120('0x21'),'original_format':'wav','converted_format':_0x2eb120('0x12'),'description':_0x2eb120('0x11')},{'id':0x7,'name':_0x2eb120('0x16'),'save_name':_0x2eb120('0x4'),'display_name':_0x2eb120('0x16'),'original_format':'mp3','converted_format':_0x2eb120('0x12'),'description':'auto\x20generated\x20sound'},{'id':0x8,'name':_0x2eb120('0x22'),'save_name':_0x2eb120('0x9'),'display_name':_0x2eb120('0x22'),'original_format':_0x2eb120('0x7'),'converted_format':'wav','description':_0x2eb120('0x11')},{'id':0x9,'name':_0x2eb120('0x1f'),'save_name':'agentmanagement-menu','display_name':_0x2eb120('0x1f'),'original_format':'wav','converted_format':_0x2eb120('0x12'),'description':_0x2eb120('0x11')},{'id':0xa,'name':_0x2eb120('0xa'),'save_name':_0x2eb120('0x19'),'display_name':_0x2eb120('0xa'),'original_format':_0x2eb120('0x7'),'converted_format':_0x2eb120('0x12'),'description':_0x2eb120('0x11')},{'id':0xb,'name':_0x2eb120('0x15'),'save_name':_0x2eb120('0x3'),'display_name':_0x2eb120('0x15'),'original_format':_0x2eb120('0x7'),'converted_format':_0x2eb120('0x12'),'description':_0x2eb120('0x11')},{'id':0xc,'name':_0x2eb120('0x1b'),'save_name':_0x2eb120('0x2'),'display_name':_0x2eb120('0x1b'),'original_format':'wav','converted_format':_0x2eb120('0x12'),'description':_0x2eb120('0x11')}];exports[_0x2eb120('0x18')]=function(){const _0x5cb307=_0x2eb120;return db['Sound'][_0x5cb307('0x10')](sounds,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x5cb307('0xc')](function(){const _0x88b530=_0x5cb307;logger[_0x88b530('0xb')](_0x88b530('0x5'));})[_0x5cb307('0xe')](function(){const _0x3019f1=_0x5cb307;logger[_0x3019f1('0x1d')](_0x3019f1('0x1e'));});}; \ No newline at end of file +const a871_0x4613=['wav','agentmanagement-login','Sound','create','auto\x20generated\x20sound','Agent\x20Pause','Can\x27t\x20create\x20Sounds','then','app','Thank\x20You','Agent\x20Login','Call\x20Rating\x20Message','Order\x20Message','Welcome\x20Message','order-elaborated','thanx','Agent\x20Logout','agentmanagement-logout','order-shipped','Agent\x20End\x20Pause','Order\x20Elaborated','agentmanagement-action-failure','Sounds\x20have\x20been\x20created','mp3','info','Agent\x20Menu','agentmanagement-pause'];(function(_0x81ceb8,_0x461396){const _0x18e28e=function(_0x5ef242){while(--_0x5ef242){_0x81ceb8['push'](_0x81ceb8['shift']());}};_0x18e28e(++_0x461396);}(a871_0x4613,0xbc));const a871_0x18e2=function(_0x81ceb8,_0x461396){_0x81ceb8=_0x81ceb8-0x0;let _0x18e28e=a871_0x4613[_0x81ceb8];return _0x18e28e;};const _0x19faf7=a871_0x18e2;'use strict';const db=require('../../mysqldb')['db'],logger=require('../logger')(_0x19faf7('0x9')),sounds=[{'id':0x1,'name':_0x19faf7('0xe'),'save_name':'welcome-acme','display_name':_0x19faf7('0xe'),'original_format':'wav','converted_format':_0x19faf7('0x1'),'description':'auto\x20generated\x20sound'},{'id':0x2,'name':'Order\x20Message','save_name':'order-number','display_name':_0x19faf7('0xd'),'original_format':'wav','converted_format':_0x19faf7('0x1'),'description':'auto\x20generated\x20sound'},{'id':0x3,'name':'Order\x20Shipped','save_name':_0x19faf7('0x13'),'display_name':'Order\x20Shipped','original_format':_0x19faf7('0x1'),'converted_format':_0x19faf7('0x1'),'description':_0x19faf7('0x5')},{'id':0x4,'name':_0x19faf7('0x15'),'save_name':_0x19faf7('0xf'),'display_name':_0x19faf7('0x15'),'original_format':_0x19faf7('0x1'),'converted_format':_0x19faf7('0x1'),'description':_0x19faf7('0x5')},{'id':0x5,'name':_0x19faf7('0xc'),'save_name':'rate-call','display_name':'Call\x20Rating\x20Message','original_format':_0x19faf7('0x1'),'converted_format':_0x19faf7('0x1'),'description':'auto\x20generated\x20sound'},{'id':0x6,'name':_0x19faf7('0xa'),'save_name':_0x19faf7('0x10'),'display_name':_0x19faf7('0xa'),'original_format':_0x19faf7('0x1'),'converted_format':_0x19faf7('0x1'),'description':_0x19faf7('0x5')},{'id':0x7,'name':_0x19faf7('0xb'),'save_name':_0x19faf7('0x2'),'display_name':_0x19faf7('0xb'),'original_format':'mp3','converted_format':'wav','description':'auto\x20generated\x20sound'},{'id':0x8,'name':_0x19faf7('0x11'),'save_name':_0x19faf7('0x12'),'display_name':'Agent\x20Logout','original_format':_0x19faf7('0x18'),'converted_format':_0x19faf7('0x1'),'description':_0x19faf7('0x5')},{'id':0x9,'name':_0x19faf7('0x1a'),'save_name':'agentmanagement-menu','display_name':_0x19faf7('0x1a'),'original_format':_0x19faf7('0x1'),'converted_format':_0x19faf7('0x1'),'description':_0x19faf7('0x5')},{'id':0xa,'name':_0x19faf7('0x6'),'save_name':_0x19faf7('0x0'),'display_name':_0x19faf7('0x6'),'original_format':_0x19faf7('0x18'),'converted_format':_0x19faf7('0x1'),'description':_0x19faf7('0x5')},{'id':0xb,'name':_0x19faf7('0x14'),'save_name':'agentmanagement-unpause','display_name':'Agent\x20End\x20Pause','original_format':_0x19faf7('0x18'),'converted_format':'wav','description':_0x19faf7('0x5')},{'id':0xc,'name':'Agent\x20Action\x20Failure','save_name':_0x19faf7('0x16'),'display_name':'Agent\x20Action\x20Failure','original_format':_0x19faf7('0x1'),'converted_format':'wav','description':_0x19faf7('0x5')}];exports[_0x19faf7('0x4')]=function(){const _0x2fb95d=_0x19faf7;return db[_0x2fb95d('0x3')]['bulkCreate'](sounds,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x2fb95d('0x8')](function(){const _0x28a65c=_0x2fb95d;logger[_0x28a65c('0x19')](_0x28a65c('0x17'));})['catch'](function(){const _0x2c3d47=_0x2fb95d;logger['error'](_0x2c3d47('0x7'));});}; \ No newline at end of file diff --git a/server/config/seedDB/squareOdbc.js b/server/config/seedDB/squareOdbc.js index de92552..f04abf1 100644 --- a/server/config/seedDB/squareOdbc.js +++ b/server/config/seedDB/squareOdbc.js @@ -1 +1 @@ -const a872_0x370b=['bulkCreate','ODBC\x20have\x20been\x20created','../../mysqldb','info','app','catch','SquareOdbc','then','xcally\x20motion\x20db\x20auto\x20generated','../logger','xcally-motion-database','DRIVER=MySQL;SERVER=127.0.0.1;UID=xcall;PWD=xC@LL1234;DATABASE=motion2'];(function(_0x6efea,_0x370bdd){const _0x40ba69=function(_0x17d327){while(--_0x17d327){_0x6efea['push'](_0x6efea['shift']());}};_0x40ba69(++_0x370bdd);}(a872_0x370b,0xe7));const a872_0x40ba=function(_0x6efea,_0x370bdd){_0x6efea=_0x6efea-0x0;let _0x40ba69=a872_0x370b[_0x6efea];return _0x40ba69;};const _0x2ff28b=a872_0x40ba;'use strict';const db=require(_0x2ff28b('0xb'))['db'],logger=require(_0x2ff28b('0x6'))(_0x2ff28b('0x1')),odbc=[{'id':0x1,'name':_0x2ff28b('0x7'),'dsn':_0x2ff28b('0x8'),'description':_0x2ff28b('0x5')}];exports['create']=function(){const _0x2a68b8=_0x2ff28b;return db[_0x2a68b8('0x3')][_0x2a68b8('0x9')](odbc,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x2a68b8('0x4')](function(){const _0xcf54a4=_0x2a68b8;logger[_0xcf54a4('0x0')](_0xcf54a4('0xa'));})[_0x2a68b8('0x2')](function(){logger['error']('Can\x27t\x20create\x20ODBC');});}; \ No newline at end of file +const a872_0x11d7=['xcally\x20motion\x20db\x20auto\x20generated','create','DRIVER=MySQL;SERVER=127.0.0.1;UID=xcall;PWD=xC@LL1234;DATABASE=motion2','Can\x27t\x20create\x20ODBC','then','../../mysqldb','error','SquareOdbc'];(function(_0x4be4f6,_0x11d71c){const _0x2a7884=function(_0x1a0838){while(--_0x1a0838){_0x4be4f6['push'](_0x4be4f6['shift']());}};_0x2a7884(++_0x11d71c);}(a872_0x11d7,0x71));const a872_0x2a78=function(_0x4be4f6,_0x11d71c){_0x4be4f6=_0x4be4f6-0x0;let _0x2a7884=a872_0x11d7[_0x4be4f6];return _0x2a7884;};const _0x1dcb04=a872_0x2a78;'use strict';const db=require(_0x1dcb04('0x4'))['db'],logger=require('../logger')('app'),odbc=[{'id':0x1,'name':'xcally-motion-database','dsn':_0x1dcb04('0x1'),'description':_0x1dcb04('0x7')}];exports[_0x1dcb04('0x0')]=function(){const _0x5c0a6c=_0x1dcb04;return db[_0x5c0a6c('0x6')]['bulkCreate'](odbc,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x5c0a6c('0x3')](function(){logger['info']('ODBC\x20have\x20been\x20created');})['catch'](function(){const _0x1ca445=_0x5c0a6c;logger[_0x1ca445('0x5')](_0x1ca445('0x2'));});}; \ No newline at end of file diff --git a/server/config/seedDB/squareProjects.js b/server/config/seedDB/squareProjects.js index 8bee303..e3b7c03 100644 --- a/server/config/seedDB/squareProjects.js +++ b/server/config/seedDB/squareProjects.js @@ -1 +1 @@ -const a873_0x1b2f=['info','Survey','app','create','xml','CSI','join','../logger','Square\x20Projects\x20have\x20been\x20created','.xml','../../mysqldb','path','utf-8','Can\x27t\x20create\x20Square\x20Projects','SquareProject','AutoAttendant','bulkCreate','error','Customer\x20Satisfaction\x20IVR\x20sample\x20auto\x20generated','readFileSync','Orders','AgentManagement'];(function(_0x4bd43e,_0x1b2fa2){const _0x2525a3=function(_0x4f98f4){while(--_0x4f98f4){_0x4bd43e['push'](_0x4bd43e['shift']());}};_0x2525a3(++_0x1b2fa2);}(a873_0x1b2f,0x1e2));const a873_0x2525=function(_0x4bd43e,_0x1b2fa2){_0x4bd43e=_0x4bd43e-0x0;let _0x2525a3=a873_0x1b2f[_0x4bd43e];return _0x2525a3;};const _0x287f8d=a873_0x2525;'use strict';const fs=require('fs'),path=require(_0x287f8d('0xd')),db=require(_0x287f8d('0xc'))['db'],logger=require(_0x287f8d('0x9'))(_0x287f8d('0x4')),getXml=function(_0x4f98f4){const _0x4fb842=_0x287f8d;return fs[_0x4fb842('0x15')](path[_0x4fb842('0x8')](__dirname,_0x4fb842('0x6'),_0x4f98f4+_0x4fb842('0xb')),{'encoding':_0x4fb842('0xe')});},squareProjects=[{'id':0x1,'name':'AutoAttendant','description':'Basic\x20IVR\x20sample\x20auto\x20generated','preproduction':getXml(_0x287f8d('0x11')),'production':getXml(_0x287f8d('0x11'))},{'id':0x2,'name':'CSI','description':_0x287f8d('0x14'),'preproduction':getXml(_0x287f8d('0x7')),'production':getXml('CSI')},{'id':0x3,'name':'Orders','description':'Order\x20DB\x20IVR\x20sample\x20auto\x20generated','preproduction':getXml('Orders'),'production':getXml(_0x287f8d('0x0'))},{'id':0x4,'name':_0x287f8d('0x3'),'description':'Survey\x20IVR\x20sample\x20auto\x20generated','preproduction':getXml('Survey'),'production':getXml(_0x287f8d('0x3'))},{'id':0x5,'name':_0x287f8d('0x1'),'description':'Agent\x20Management\x20sample\x20auto\x20generated','preproduction':getXml(_0x287f8d('0x1')),'production':getXml('AgentManagement')}];exports[_0x287f8d('0x5')]=function(){const _0x41117b=_0x287f8d;return db[_0x41117b('0x10')][_0x41117b('0x12')](squareProjects,{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(){const _0x21ef3d=_0x41117b;logger[_0x21ef3d('0x2')](_0x21ef3d('0xa'));})['catch'](function(){const _0x4c54ae=_0x41117b;logger[_0x4c54ae('0x13')](_0x4c54ae('0xf'));});}; \ No newline at end of file +const a873_0x40e1=['.xml','path','Agent\x20Management\x20sample\x20auto\x20generated','error','../logger','then','readFileSync','AutoAttendant','bulkCreate','Survey','utf-8','SquareProject','catch','Orders','../../mysqldb','Order\x20DB\x20IVR\x20sample\x20auto\x20generated','info','AgentManagement','Basic\x20IVR\x20sample\x20auto\x20generated','app','Can\x27t\x20create\x20Square\x20Projects','Customer\x20Satisfaction\x20IVR\x20sample\x20auto\x20generated','join','CSI'];(function(_0x131482,_0x40e1c1){const _0x2d4fd1=function(_0x420d6b){while(--_0x420d6b){_0x131482['push'](_0x131482['shift']());}};_0x2d4fd1(++_0x40e1c1);}(a873_0x40e1,0x1eb));const a873_0x2d4f=function(_0x131482,_0x40e1c1){_0x131482=_0x131482-0x0;let _0x2d4fd1=a873_0x40e1[_0x131482];return _0x2d4fd1;};const _0x50b68c=a873_0x2d4f;'use strict';const fs=require('fs'),path=require(_0x50b68c('0xe')),db=require(_0x50b68c('0x3'))['db'],logger=require(_0x50b68c('0x11'))(_0x50b68c('0x8')),getXml=function(_0x420d6b){const _0x5ca4d4=_0x50b68c;return fs[_0x5ca4d4('0x13')](path[_0x5ca4d4('0xb')](__dirname,'xml',_0x420d6b+_0x5ca4d4('0xd')),{'encoding':_0x5ca4d4('0x17')});},squareProjects=[{'id':0x1,'name':_0x50b68c('0x14'),'description':_0x50b68c('0x7'),'preproduction':getXml(_0x50b68c('0x14')),'production':getXml(_0x50b68c('0x14'))},{'id':0x2,'name':'CSI','description':_0x50b68c('0xa'),'preproduction':getXml(_0x50b68c('0xc')),'production':getXml(_0x50b68c('0xc'))},{'id':0x3,'name':_0x50b68c('0x2'),'description':_0x50b68c('0x4'),'preproduction':getXml('Orders'),'production':getXml(_0x50b68c('0x2'))},{'id':0x4,'name':_0x50b68c('0x16'),'description':'Survey\x20IVR\x20sample\x20auto\x20generated','preproduction':getXml(_0x50b68c('0x16')),'production':getXml(_0x50b68c('0x16'))},{'id':0x5,'name':_0x50b68c('0x6'),'description':_0x50b68c('0xf'),'preproduction':getXml('AgentManagement'),'production':getXml(_0x50b68c('0x6'))}];exports['create']=function(){const _0x35be77=_0x50b68c;return db[_0x35be77('0x0')][_0x35be77('0x15')](squareProjects,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x35be77('0x12')](function(){const _0x5a21bd=_0x35be77;logger[_0x5a21bd('0x5')]('Square\x20Projects\x20have\x20been\x20created');})[_0x35be77('0x1')](function(){const _0x210841=_0x35be77;logger[_0x210841('0x10')](_0x210841('0x9'));});}; \ No newline at end of file diff --git a/server/config/seedDB/tags.js b/server/config/seedDB/tags.js index a1e2681..e1ee5b6 100644 --- a/server/config/seedDB/tags.js +++ b/server/config/seedDB/tags.js @@ -1 +1 @@ -const a874_0x2127=['tag\x20about_sales\x20auto\x20generated','Tags\x20have\x20been\x20created','Can\x27t\x20create\x20Tags','forums','faq','../logger','defective','getNames','info','name','tag\x20installation\x20auto\x20generated','tag\x20forums\x20auto\x20generated','app','../../mysqldb','about_sales','error','Tag','tag\x20defective\x20auto\x20generated','tag\x20faq\x20auto\x20generated','create','bulkCreate'];(function(_0x54cf89,_0x212766){const _0x1ba05a=function(_0x4d1cac){while(--_0x4d1cac){_0x54cf89['push'](_0x54cf89['shift']());}};_0x1ba05a(++_0x212766);}(a874_0x2127,0xde));const a874_0x1ba0=function(_0x54cf89,_0x212766){_0x54cf89=_0x54cf89-0x0;let _0x1ba05a=a874_0x2127[_0x54cf89];return _0x1ba05a;};const _0xe2aabd=a874_0x1ba0;'use strict';const _=require('lodash'),db=require(_0xe2aabd('0x1'))['db'],logger=require(_0xe2aabd('0xe'))(_0xe2aabd('0x0')),tags=[{'id':0x1,'name':_0xe2aabd('0xc'),'description':_0xe2aabd('0x14')},{'id':0x2,'name':_0xe2aabd('0xf'),'description':_0xe2aabd('0x5')},{'id':0x3,'name':_0xe2aabd('0xd'),'description':_0xe2aabd('0x6')},{'id':0x4,'name':'installation','description':_0xe2aabd('0x13')},{'id':0x5,'name':_0xe2aabd('0x2'),'description':_0xe2aabd('0x9')}];exports[_0xe2aabd('0x7')]=function(){const _0x4888e8=_0xe2aabd;return db[_0x4888e8('0x4')][_0x4888e8('0x8')](tags,{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(){const _0x85ab18=_0x4888e8;logger[_0x85ab18('0x11')](_0x85ab18('0xa'));})['catch'](function(){const _0x5b424a=_0x4888e8;logger[_0x5b424a('0x3')](_0x5b424a('0xb'));});},exports[_0xe2aabd('0x10')]=function(){const _0x48693c=_0xe2aabd;return _['map'](tags,_0x48693c('0x12'));}; \ No newline at end of file +const a874_0x2d3c=['faq','catch','Tag','forums','name','map','Tags\x20have\x20been\x20created','tag\x20defective\x20auto\x20generated','Can\x27t\x20create\x20Tags','app','../logger','info','then','about_sales','tag\x20faq\x20auto\x20generated','../../mysqldb','installation','tag\x20about_sales\x20auto\x20generated','create','bulkCreate'];(function(_0x49bdfc,_0x2d3c83){const _0x27100a=function(_0x5d82d2){while(--_0x5d82d2){_0x49bdfc['push'](_0x49bdfc['shift']());}};_0x27100a(++_0x2d3c83);}(a874_0x2d3c,0x10e));const a874_0x2710=function(_0x49bdfc,_0x2d3c83){_0x49bdfc=_0x49bdfc-0x0;let _0x27100a=a874_0x2d3c[_0x49bdfc];return _0x27100a;};const _0x29049d=a874_0x2710;'use strict';const _=require('lodash'),db=require(_0x29049d('0x5'))['db'],logger=require(_0x29049d('0x0'))(_0x29049d('0x13')),tags=[{'id':0x1,'name':_0x29049d('0xd'),'description':'tag\x20forums\x20auto\x20generated'},{'id':0x2,'name':'defective','description':_0x29049d('0x11')},{'id':0x3,'name':_0x29049d('0xa'),'description':_0x29049d('0x4')},{'id':0x4,'name':_0x29049d('0x6'),'description':'tag\x20installation\x20auto\x20generated'},{'id':0x5,'name':_0x29049d('0x3'),'description':_0x29049d('0x7')}];exports[_0x29049d('0x8')]=function(){const _0x31915b=_0x29049d;return db[_0x31915b('0xc')][_0x31915b('0x9')](tags,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x31915b('0x2')](function(){const _0x3ad49f=_0x31915b;logger[_0x3ad49f('0x1')](_0x3ad49f('0x10'));})[_0x31915b('0xb')](function(){const _0x49d8af=_0x31915b;logger['error'](_0x49d8af('0x12'));});},exports['getNames']=function(){const _0x439a16=_0x29049d;return _[_0x439a16('0xf')](tags,_0x439a16('0xe'));}; \ No newline at end of file diff --git a/server/config/seedDB/teams.js b/server/config/seedDB/teams.js index 89d37c2..ab0e5fd 100644 --- a/server/config/seedDB/teams.js +++ b/server/config/seedDB/teams.js @@ -1 +1 @@ -const a875_0x576f=['../../mysqldb','info','app','bulkCreate','demo\x20team\x20auto\x20generated','Demo\x20Team','addAgents','Team','then','Can\x27t\x20create\x20Teams','../logger','Teams\x20have\x20been\x20created'];(function(_0x1eb501,_0x576fb9){const _0x2c88cf=function(_0x1d8c87){while(--_0x1d8c87){_0x1eb501['push'](_0x1eb501['shift']());}};_0x2c88cf(++_0x576fb9);}(a875_0x576f,0x8b));const a875_0x2c88=function(_0x1eb501,_0x576fb9){_0x1eb501=_0x1eb501-0x0;let _0x2c88cf=a875_0x576f[_0x1eb501];return _0x2c88cf;};const _0x5aaca5=a875_0x2c88;'use strict';const db=require(_0x5aaca5('0x5'))['db'],logger=require(_0x5aaca5('0x3'))(_0x5aaca5('0x7')),teams=[{'id':0x1,'name':_0x5aaca5('0xa'),'description':_0x5aaca5('0x9')}];exports['create']=function(){const _0x283318=_0x5aaca5;return db[_0x283318('0x0')][_0x283318('0x8')](teams,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x283318('0x1')](function(_0x1d8c87){const _0x10a56f=_0x283318;for(let _0x3448c5=0x0;_0x3448c5<_0x1d8c87['length'];_0x3448c5+=0x1){_0x1d8c87[_0x3448c5][_0x10a56f('0xb')]([0x2,0x3]);}})[_0x283318('0x1')](function(){const _0x5a698b=_0x283318;logger[_0x5a698b('0x6')](_0x5a698b('0x4'));})['catch'](function(){const _0x229727=_0x283318;logger['error'](_0x229727('0x2'));});}; \ No newline at end of file +const a875_0x5d54=['catch','Demo\x20Team','Can\x27t\x20create\x20Teams','bulkCreate','create','length','Team','then','addAgents','info','Teams\x20have\x20been\x20created'];(function(_0x3dbe64,_0x5d5467){const _0x2b803e=function(_0x155663){while(--_0x155663){_0x3dbe64['push'](_0x3dbe64['shift']());}};_0x2b803e(++_0x5d5467);}(a875_0x5d54,0xcb));const a875_0x2b80=function(_0x3dbe64,_0x5d5467){_0x3dbe64=_0x3dbe64-0x0;let _0x2b803e=a875_0x5d54[_0x3dbe64];return _0x2b803e;};const _0x3ac63d=a875_0x2b80;'use strict';const db=require('../../mysqldb')['db'],logger=require('../logger')('app'),teams=[{'id':0x1,'name':_0x3ac63d('0x7'),'description':'demo\x20team\x20auto\x20generated'}];exports[_0x3ac63d('0xa')]=function(){const _0x37bf7e=_0x3ac63d;return db[_0x37bf7e('0x1')][_0x37bf7e('0x9')](teams,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x37bf7e('0x2')](function(_0x155663){const _0x1958e2=_0x37bf7e;for(let _0x20bb42=0x0;_0x20bb42<_0x155663[_0x1958e2('0x0')];_0x20bb42+=0x1){_0x155663[_0x20bb42][_0x1958e2('0x3')]([0x2,0x3]);}})[_0x37bf7e('0x2')](function(){const _0x5a885f=_0x37bf7e;logger[_0x5a885f('0x4')](_0x5a885f('0x5'));})[_0x37bf7e('0x6')](function(){const _0x523ab8=_0x37bf7e;logger['error'](_0x523ab8('0x8'));});}; \ No newline at end of file diff --git a/server/config/seedDB/tree/index.js b/server/config/seedDB/tree/index.js index 2868131..77c562c 100644 --- a/server/config/seedDB/tree/index.js +++ b/server/config/seedDB/tree/index.js @@ -1 +1 @@ -var a876_0x540f=['icon\x20s20\x20icon-email','Distribution','queue_campaigns','Email','chat','Chat','Cally\x20Square','icon\x20s20\x20icon-microphone','voice','icon\x20s20\x20icon-account-multiple','icon-laptop-chromebook','openchannel','icon\x20s20\x20icon-deskphone','icon\x20s20\x20icon-whatsapp','Fax','Recordings','answered','Agents','Openchannel','icon\x20s20\x20','Unanswered','icon\x20s20\x20icon-fire','unanswered','icon\x20s20\x20icon-sitemap','ivr_campaigns','distribution','Motion','custom','whatsapp','queues','bull','Custom','motion','calls','mail','icon\x20s20\x20icon-message-text','icon\x20s20\x20icon-phone-log','callysquare','icon\x20s20\x20icon-phone-dots','Queues','icon\x20s20\x20icon-google-earth','WhatsApp\x20Connector','Answered','agents','icon\x20s20\x20icon-stackoverflow'];(function(_0x2a5904,_0x540fff){var _0x5dd80e=function(_0x4c62cd){while(--_0x4c62cd){_0x2a5904['push'](_0x2a5904['shift']());}};_0x5dd80e(++_0x540fff);}(a876_0x540f,0x8d));var a876_0x5dd8=function(_0x2a5904,_0x540fff){_0x2a5904=_0x2a5904-0x0;var _0x5dd80e=a876_0x540f[_0x2a5904];return _0x5dd80e;};var _0xab324=a876_0x5dd8;'use strict';function getQueuesChildren(_0x4c62cd){var _0x4e16d2=a876_0x5dd8;return _0x4c62cd+='_',[{'id':_0x4c62cd+_0x4e16d2('0xa'),'text':_0x4e16d2('0x24')},{'id':_0x4c62cd+_0x4e16d2('0x10'),'text':_0x4e16d2('0xe')},{'id':_0x4c62cd+_0x4e16d2('0x13'),'text':_0x4e16d2('0x28')}];}function getVoiceChildren(_0x534817){var _0x40f136=a876_0x5dd8;return _0x534817+='_',[{'id':_0x534817+'queues','text':_0x40f136('0x21'),'icon':_0x40f136('0x26'),'children':getQueuesChildren(_0x534817+_0x40f136('0x17'))},{'id':_0x534817+_0x40f136('0x1b'),'text':'Calls','icon':_0x40f136('0x20')},{'id':_0x534817+_0x40f136('0x25'),'text':_0x40f136('0xb'),'icon':_0x40f136('0x3')},{'id':_0x534817+_0x40f136('0x1f'),'text':_0x40f136('0x0'),'icon':_0x40f136('0x11')},{'id':_0x534817+'recordings','text':_0x40f136('0x9'),'icon':_0x40f136('0x1')}];}function getBullChildren(_0x2e097e){var _0x6d3a15=a876_0x5dd8;return _0x2e097e+='_',[{'id':_0x2e097e+_0x6d3a15('0x29'),'text':'Queue\x20Campaigns','icon':_0x6d3a15('0x26')},{'id':_0x2e097e+_0x6d3a15('0x12'),'text':'IVR\x20Campaigns','icon':_0x6d3a15('0x11')}];}function getMotionChildren(_0x2aec68){var _0x262f9c=a876_0x5dd8;return _0x2aec68+='_',[{'id':_0x2aec68+_0x262f9c('0x2'),'text':'Voice','icon':_0x262f9c('0x1e'),'children':getVoiceChildren(_0x2aec68+'voice')},{'id':_0x2aec68+_0x262f9c('0x18'),'text':'Motion\x20Bull','icon':_0x262f9c('0xf'),'children':getBullChildren(_0x2aec68+_0x262f9c('0x18'))},{'id':_0x2aec68+_0x262f9c('0x2b'),'text':_0x262f9c('0x2c'),'icon':'icon\x20s20\x20icon-hangouts'},{'id':_0x2aec68+_0x262f9c('0x1c'),'text':_0x262f9c('0x2a'),'icon':_0x262f9c('0x27')},{'id':_0x2aec68+_0x262f9c('0x5'),'text':_0x262f9c('0xc'),'icon':_0x262f9c('0x22')},{'id':_0x2aec68+'sms','text':'Sms','icon':_0x262f9c('0x1d')},{'id':_0x2aec68+'fax','text':_0x262f9c('0x8'),'icon':_0x262f9c('0x6')},{'id':_0x2aec68+_0x262f9c('0x16'),'text':_0x262f9c('0x23'),'icon':_0x262f9c('0x7')},{'id':_0x2aec68+_0x262f9c('0x25'),'text':'Agents','icon':'icon\x20s20\x20icon-account-multiple'}];}function getTree(_0xe72ff6){var _0x5712b6=a876_0x5dd8;return[{'id':_0xe72ff6?_0x5712b6('0x15'):_0x5712b6('0x1a'),'text':(_0xe72ff6?_0x5712b6('0x19'):_0x5712b6('0x14'))+'\x20Reports','icon':_0x5712b6('0xd')+(_0xe72ff6?_0x5712b6('0x4'):'icon-cloud'),'state':{'opened':!![],'selected':!![]},'children':getMotionChildren(_0xe72ff6?_0x5712b6('0x15'):_0x5712b6('0x1a'))}];}exports[_0xab324('0x1a')]=getTree(![]),exports[_0xab324('0x15')]=getTree(!![]); \ No newline at end of file +var a876_0x1e67=['Unanswered','Chat','Voice','icon\x20s20\x20icon-deskphone','queues','Motion\x20Bull','custom','whatsapp','icon\x20s20\x20icon-google-earth','Custom','openchannel','icon\x20s20\x20icon-message-text','icon\x20s20\x20icon-email','icon-laptop-chromebook','icon\x20s20\x20icon-fire','motion','icon-cloud','Cally\x20Square','WhatsApp\x20Connector','icon\x20s20\x20icon-whatsapp','recordings','distribution','Distribution','icon\x20s20\x20icon-sitemap','Motion','Answered','icon\x20s20\x20icon-phone-log','fax','sms','ivr_campaigns','icon\x20s20\x20icon-stackoverflow','answered','icon\x20s20\x20icon-microphone','icon\x20s20\x20icon-account-multiple','Fax','agents','icon\x20s20\x20','icon\x20s20\x20icon-hangouts','\x20Reports','Agents','Recordings','mail','icon\x20s20\x20icon-phone-dots','voice','Queue\x20Campaigns','Queues','bull','Calls','unanswered'];(function(_0x38e7b4,_0x1e6734){var _0x5c699a=function(_0x5d63f2){while(--_0x5d63f2){_0x38e7b4['push'](_0x38e7b4['shift']());}};_0x5c699a(++_0x1e6734);}(a876_0x1e67,0xb5));var a876_0x5c69=function(_0x38e7b4,_0x1e6734){_0x38e7b4=_0x38e7b4-0x0;var _0x5c699a=a876_0x1e67[_0x38e7b4];return _0x5c699a;};var _0x298b47=a876_0x5c69;'use strict';function getQueuesChildren(_0x5d63f2){var _0x3f5e50=a876_0x5c69;return _0x5d63f2+='_',[{'id':_0x5d63f2+_0x3f5e50('0x2e'),'text':_0x3f5e50('0x28')},{'id':_0x5d63f2+_0x3f5e50('0xe'),'text':_0x3f5e50('0xf')},{'id':_0x5d63f2+_0x3f5e50('0x24'),'text':_0x3f5e50('0x25')}];}function getVoiceChildren(_0x555bf8){var _0x279d8=a876_0x5c69;return _0x555bf8+='_',[{'id':_0x555bf8+_0x279d8('0x13'),'text':_0x279d8('0xb'),'icon':_0x279d8('0x2d'),'children':getQueuesChildren(_0x555bf8+'queues')},{'id':_0x555bf8+'calls','text':_0x279d8('0xd'),'icon':_0x279d8('0x8')},{'id':_0x555bf8+_0x279d8('0x1'),'text':_0x279d8('0x5'),'icon':_0x279d8('0x30')},{'id':_0x555bf8+'callysquare','text':_0x279d8('0x20'),'icon':_0x279d8('0x26')},{'id':_0x555bf8+_0x279d8('0x23'),'text':_0x279d8('0x6'),'icon':_0x279d8('0x2f')}];}function getBullChildren(_0x27f2b2){var _0x78023=a876_0x5c69;return _0x27f2b2+='_',[{'id':_0x27f2b2+'queue_campaigns','text':_0x78023('0xa'),'icon':_0x78023('0x2d')},{'id':_0x27f2b2+_0x78023('0x2c'),'text':'IVR\x20Campaigns','icon':'icon\x20s20\x20icon-sitemap'}];}function getMotionChildren(_0x13cfc8){var _0x8987a7=a876_0x5c69;return _0x13cfc8+='_',[{'id':_0x13cfc8+_0x8987a7('0x9'),'text':_0x8987a7('0x11'),'icon':_0x8987a7('0x29'),'children':getVoiceChildren(_0x13cfc8+_0x8987a7('0x9'))},{'id':_0x13cfc8+_0x8987a7('0xc'),'text':_0x8987a7('0x14'),'icon':_0x8987a7('0x1d'),'children':getBullChildren(_0x13cfc8+_0x8987a7('0xc'))},{'id':_0x13cfc8+'chat','text':_0x8987a7('0x10'),'icon':_0x8987a7('0x3')},{'id':_0x13cfc8+_0x8987a7('0x7'),'text':'Email','icon':_0x8987a7('0x1b')},{'id':_0x13cfc8+_0x8987a7('0x19'),'text':'Openchannel','icon':_0x8987a7('0x17')},{'id':_0x13cfc8+_0x8987a7('0x2b'),'text':'Sms','icon':_0x8987a7('0x1a')},{'id':_0x13cfc8+_0x8987a7('0x2a'),'text':_0x8987a7('0x0'),'icon':_0x8987a7('0x12')},{'id':_0x13cfc8+_0x8987a7('0x16'),'text':_0x8987a7('0x21'),'icon':_0x8987a7('0x22')},{'id':_0x13cfc8+_0x8987a7('0x1'),'text':_0x8987a7('0x5'),'icon':_0x8987a7('0x30')}];}function getTree(_0x3a4f72){var _0xdea63e=a876_0x5c69;return[{'id':_0x3a4f72?_0xdea63e('0x15'):_0xdea63e('0x1e'),'text':(_0x3a4f72?_0xdea63e('0x18'):_0xdea63e('0x27'))+_0xdea63e('0x4'),'icon':_0xdea63e('0x2')+(_0x3a4f72?_0xdea63e('0x1c'):_0xdea63e('0x1f')),'state':{'opened':!![],'selected':!![]},'children':getMotionChildren(_0x3a4f72?_0xdea63e('0x15'):_0xdea63e('0x1e'))}];}exports[_0x298b47('0x1e')]=getTree(![]),exports[_0x298b47('0x15')]=getTree(!![]); \ No newline at end of file diff --git a/server/config/seedDB/trunks.js b/server/config/seedDB/trunks.js index d11d158..72029bb 100644 --- a/server/config/seedDB/trunks.js +++ b/server/config/seedDB/trunks.js @@ -1 +1 @@ -const a877_0x59eb=['then','catch','create','../../mysqldb','trunk\x20demo\x20auto\x20generated','Can\x27t\x20create\x20Trunks','error','app','demo','Trunk'];(function(_0x4b8a24,_0x59ebc4){const _0x2c7fee=function(_0x41ec14){while(--_0x41ec14){_0x4b8a24['push'](_0x4b8a24['shift']());}};_0x2c7fee(++_0x59ebc4);}(a877_0x59eb,0x192));const a877_0x2c7f=function(_0x4b8a24,_0x59ebc4){_0x4b8a24=_0x4b8a24-0x0;let _0x2c7fee=a877_0x59eb[_0x4b8a24];return _0x2c7fee;};const _0x2d75bb=a877_0x2c7f;'use strict';const db=require(_0x2d75bb('0x1'))['db'],logger=require('../logger')(_0x2d75bb('0x5')),trunks=[{'id':0x1,'name':_0x2d75bb('0x6'),'secret':'55xcally55','defaultuser':_0x2d75bb('0x6'),'description':_0x2d75bb('0x2')}];exports[_0x2d75bb('0x0')]=function(){const _0x369d65=_0x2d75bb;return db[_0x369d65('0x7')]['bulkCreate'](trunks,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x369d65('0x8')](function(){logger['info']('Trunks\x20have\x20been\x20created');})[_0x369d65('0x9')](function(){const _0x156087=_0x369d65;logger[_0x156087('0x4')](_0x156087('0x3'));});}; \ No newline at end of file +const a877_0x3216=['bulkCreate','trunk\x20demo\x20auto\x20generated','demo','info','../logger','Can\x27t\x20create\x20Trunks','create','../../mysqldb','catch','then'];(function(_0x2dbd07,_0x3216ca){const _0x591a2c=function(_0x12742a){while(--_0x12742a){_0x2dbd07['push'](_0x2dbd07['shift']());}};_0x591a2c(++_0x3216ca);}(a877_0x3216,0x99));const a877_0x591a=function(_0x2dbd07,_0x3216ca){_0x2dbd07=_0x2dbd07-0x0;let _0x591a2c=a877_0x3216[_0x2dbd07];return _0x591a2c;};const _0x443275=a877_0x591a;'use strict';const db=require(_0x443275('0x4'))['db'],logger=require(_0x443275('0x1'))('app'),trunks=[{'id':0x1,'name':_0x443275('0x9'),'secret':'55xcally55','defaultuser':_0x443275('0x9'),'description':_0x443275('0x8')}];exports[_0x443275('0x3')]=function(){const _0x29e0ce=_0x443275;return db['Trunk'][_0x29e0ce('0x7')](trunks,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x29e0ce('0x6')](function(){const _0x2871c8=_0x29e0ce;logger[_0x2871c8('0x0')]('Trunks\x20have\x20been\x20created');})[_0x29e0ce('0x5')](function(){const _0x5e28c2=_0x29e0ce;logger['error'](_0x5e28c2('0x2'));});}; \ No newline at end of file diff --git a/server/config/seedDB/userProfiles.js b/server/config/seedDB/userProfiles.js index 5660a8a..3c07ae3 100644 --- a/server/config/seedDB/userProfiles.js +++ b/server/config/seedDB/userProfiles.js @@ -1 +1 @@ -const a878_0x1157=['../logger','then','create','Auto\x20generated\x20User\x20Profile','Default','error','info','UserProfile','bulkCreate'];(function(_0x376302,_0x115777){const _0x42090f=function(_0x5c2af0){while(--_0x5c2af0){_0x376302['push'](_0x376302['shift']());}};_0x42090f(++_0x115777);}(a878_0x1157,0x92));const a878_0x4209=function(_0x376302,_0x115777){_0x376302=_0x376302-0x0;let _0x42090f=a878_0x1157[_0x376302];return _0x42090f;};const _0x53625d=a878_0x4209;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x53625d('0x7'))('app'),userProfiles=[{'id':0x1,'name':_0x53625d('0x2'),'crudPermissions':['r','e','d'],'description':_0x53625d('0x1')}];exports[_0x53625d('0x0')]=function(){const _0x49d6af=_0x53625d;return db[_0x49d6af('0x5')][_0x49d6af('0x6')](userProfiles,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x49d6af('0x8')](function(){const _0x4d1b59=_0x49d6af;logger[_0x4d1b59('0x4')]('User\x20Profiles\x20have\x20been\x20created');})['catch'](function(){const _0xebc029=_0x49d6af;logger[_0xebc029('0x3')]('Can\x27t\x20create\x20User\x20Profiles');});}; \ No newline at end of file +const a878_0x44a5=['../../mysqldb','Can\x27t\x20create\x20User\x20Profiles','bulkCreate','create','Auto\x20generated\x20User\x20Profile','Default','info','app','../logger','then','UserProfile'];(function(_0x49a4d3,_0x44a516){const _0x4163f7=function(_0x2f6880){while(--_0x2f6880){_0x49a4d3['push'](_0x49a4d3['shift']());}};_0x4163f7(++_0x44a516);}(a878_0x44a5,0xc3));const a878_0x4163=function(_0x49a4d3,_0x44a516){_0x49a4d3=_0x49a4d3-0x0;let _0x4163f7=a878_0x44a5[_0x49a4d3];return _0x4163f7;};const _0x3b5a95=a878_0x4163;'use strict';const db=require(_0x3b5a95('0x3'))['db'],logger=require(_0x3b5a95('0x0'))(_0x3b5a95('0xa')),userProfiles=[{'id':0x1,'name':_0x3b5a95('0x8'),'crudPermissions':['r','e','d'],'description':_0x3b5a95('0x7')}];exports[_0x3b5a95('0x6')]=function(){const _0x37de03=_0x3b5a95;return db[_0x37de03('0x2')][_0x37de03('0x5')](userProfiles,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x37de03('0x1')](function(){const _0xe62ac9=_0x37de03;logger[_0xe62ac9('0x9')]('User\x20Profiles\x20have\x20been\x20created');})['catch'](function(){const _0x3020f7=_0x37de03;logger['error'](_0x3020f7('0x4'));});}; \ No newline at end of file diff --git a/server/config/seedDB/users.js b/server/config/seedDB/users.js index d17c95f..0b5b476 100644 --- a/server/config/seedDB/users.js +++ b/server/config/seedDB/users.js @@ -1 +1 @@ -const a879_0x1e73=['jane.miller@xcally.com','Administrator','John\x20Doe','../logger','john.doe@xcally.com','agent\x20auto\x20generated','split','agent','101,102,103,113,110,104,105,106,107,108,109,100,111,114','../../mysqldb','Can\x27t\x20create\x20Users','bulkCreate','info','error','then','user\x20auto\x20generated','app','Jane\x20Miller','catch','password','shuttle55','admin'];(function(_0x5addd1,_0x1e73db){const _0xb3bd58=function(_0x8b0d48){while(--_0x8b0d48){_0x5addd1['push'](_0x5addd1['shift']());}};_0xb3bd58(++_0x1e73db);}(a879_0x1e73,0x1b3));const a879_0xb3bd=function(_0x5addd1,_0x1e73db){_0x5addd1=_0x5addd1-0x0;let _0xb3bd58=a879_0x1e73[_0x5addd1];return _0xb3bd58;};const _0x59fceb=a879_0xb3bd;'use strict';const db=require(_0x59fceb('0xe'))['db'],logger=require(_0x59fceb('0x8'))(_0x59fceb('0x15')),users=[{'id':0x1,'role':_0x59fceb('0x4'),'name':'admin','password':_0x59fceb('0x2'),'fullname':_0x59fceb('0x6'),'email':'admin@xcally.com','internal':0x3e8,'description':_0x59fceb('0x14')},{'id':0x2,'role':'agent','name':'john.doe','email':_0x59fceb('0x9'),'password':_0x59fceb('0x3'),'fullname':_0x59fceb('0x7'),'internal':0x3e9,'permissions':_0x59fceb('0xd')[_0x59fceb('0xb')](','),'description':_0x59fceb('0xa')},{'id':0x3,'role':_0x59fceb('0xc'),'name':'jane.miller','email':_0x59fceb('0x5'),'password':'shuttle55','fullname':_0x59fceb('0x0'),'internal':0x3ea,'permissions':_0x59fceb('0xd')['split'](','),'description':_0x59fceb('0xa')}];exports['create']=function(){const _0x33e803=_0x59fceb;return db['User'][_0x33e803('0x10')](users,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x33e803('0x13')](function(){const _0x45e181=_0x33e803;logger[_0x45e181('0x11')]('Users\x20have\x20been\x20created');})[_0x33e803('0x1')](function(_0x8b0d48){const _0x3143c2=_0x33e803;logger[_0x3143c2('0x12')](_0x3143c2('0xf'),_0x8b0d48);});}; \ No newline at end of file +const a879_0x5b32=['jane.miller','info','agent\x20auto\x20generated','catch','john.doe','john.doe@xcally.com','Can\x27t\x20create\x20Users','bulkCreate','Users\x20have\x20been\x20created','agent','user\x20auto\x20generated','create','admin@xcally.com','shuttle55','Administrator','User','app','../../mysqldb','error','password','101,102,103,113,110,104,105,106,107,108,109,100,111,114','../logger','jane.miller@xcally.com'];(function(_0x4ee5c4,_0x5b328d){const _0x257e2d=function(_0x10312f){while(--_0x10312f){_0x4ee5c4['push'](_0x4ee5c4['shift']());}};_0x257e2d(++_0x5b328d);}(a879_0x5b32,0x1d1));const a879_0x257e=function(_0x4ee5c4,_0x5b328d){_0x4ee5c4=_0x4ee5c4-0x0;let _0x257e2d=a879_0x5b32[_0x4ee5c4];return _0x257e2d;};const _0x4e89a0=a879_0x257e;'use strict';const db=require(_0x4e89a0('0xc'))['db'],logger=require(_0x4e89a0('0x10'))(_0x4e89a0('0xb')),users=[{'id':0x1,'role':'admin','name':'admin','password':_0x4e89a0('0xe'),'fullname':_0x4e89a0('0x9'),'email':_0x4e89a0('0x7'),'internal':0x3e8,'description':_0x4e89a0('0x5')},{'id':0x2,'role':_0x4e89a0('0x4'),'name':_0x4e89a0('0x16'),'email':_0x4e89a0('0x0'),'password':_0x4e89a0('0x8'),'fullname':'John\x20Doe','internal':0x3e9,'permissions':_0x4e89a0('0xf')['split'](','),'description':_0x4e89a0('0x14')},{'id':0x3,'role':'agent','name':_0x4e89a0('0x12'),'email':_0x4e89a0('0x11'),'password':_0x4e89a0('0x8'),'fullname':'Jane\x20Miller','internal':0x3ea,'permissions':_0x4e89a0('0xf')['split'](','),'description':_0x4e89a0('0x14')}];exports[_0x4e89a0('0x6')]=function(){const _0x1f6fdf=_0x4e89a0;return db[_0x1f6fdf('0xa')][_0x1f6fdf('0x2')](users,{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(){const _0x1d52eb=_0x1f6fdf;logger[_0x1d52eb('0x13')](_0x1d52eb('0x3'));})[_0x1f6fdf('0x15')](function(_0x10312f){const _0x28ecaa=_0x1f6fdf;logger[_0x28ecaa('0xd')](_0x28ecaa('0x1'),_0x10312f);});}; \ No newline at end of file diff --git a/server/config/seedDB/variables.js b/server/config/seedDB/variables.js index e668bde..4a3ade0 100644 --- a/server/config/seedDB/variables.js +++ b/server/config/seedDB/variables.js @@ -1 +1 @@ -const a880_0x5d00=['bulkCreate','CALLERID(name)','EMAIL','variable\x20useful\x20for\x20agent\x20popup\x20auto\x20generated','COUNTER','variable\x20dialed\x20number\x20identifier\x20auto\x20generated','Variables\x20have\x20been\x20created','variable\x20number\x20of\x20the\x20caller\x20auto\x20generated','VAR2','CALLERID(dnid)','RESULT','VAR1','UNIQUEID','DBRESULT','Variable','INPUT','info','CHANNEL(language)','variable\x20for\x20db\x20query\x20result\x20auto\x20generated','RATE','EXTRAVAR','app','CHOICE','../logger','VAR3','LASTNAME','variable\x20for\x20order\x20auto\x20generated','variable\x20select\x20a\x20natural\x20language\x20file\x20when\x20available\x20auto\x20generated','CALLERID(num)','then','Can\x27t\x20create\x20Variables','variable\x20auto\x20generated','catch','ORDER','error','FIRSTNAME','generic\x20variable\x20auto\x20generated','variable\x20for\x20menu\x20auto\x20generated'];(function(_0x153ffa,_0x5d00e4){const _0x9aead1=function(_0x5d0056){while(--_0x5d0056){_0x153ffa['push'](_0x153ffa['shift']());}};_0x9aead1(++_0x5d00e4);}(a880_0x5d00,0x12e));const a880_0x9aea=function(_0x153ffa,_0x5d00e4){_0x153ffa=_0x153ffa-0x0;let _0x9aead1=a880_0x5d00[_0x153ffa];return _0x9aead1;};const _0x4fa27e=a880_0x9aea;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x4fa27e('0x19'))(_0x4fa27e('0x17')),variables=[{'id':0x1,'name':_0x4fa27e('0x18'),'description':_0x4fa27e('0x1')},{'id':0x2,'name':'ORDERNUM','description':_0x4fa27e('0x1c')},{'id':0x3,'name':_0x4fa27e('0xf'),'description':_0x4fa27e('0x14')},{'id':0x4,'name':_0x4fa27e('0x15'),'description':'variable\x20for\x20rate\x20call\x20auto\x20generated'},{'id':0x5,'name':_0x4fa27e('0xb'),'description':_0x4fa27e('0x7')},{'id':0x6,'name':_0x4fa27e('0x3'),'description':'variable\x20name\x20of\x20the\x20caller\x20auto\x20generated'},{'id':0x7,'name':_0x4fa27e('0x1e'),'description':_0x4fa27e('0x9')},{'id':0x8,'name':_0x4fa27e('0x13'),'description':_0x4fa27e('0x1d')},{'id':0x9,'name':_0x4fa27e('0x6'),'description':_0x4fa27e('0x21')},{'id':0xa,'name':_0x4fa27e('0x4'),'description':_0x4fa27e('0x21')},{'id':0xb,'name':_0x4fa27e('0x16'),'description':_0x4fa27e('0x5')},{'id':0xc,'name':_0x4fa27e('0x25'),'description':'variable\x20auto\x20generated'},{'id':0xd,'name':_0x4fa27e('0x1b'),'description':'variable\x20auto\x20generated'},{'id':0xe,'name':_0x4fa27e('0x11'),'description':_0x4fa27e('0x21')},{'id':0xf,'name':'OPTION','description':_0x4fa27e('0x21')},{'id':0x10,'name':_0x4fa27e('0x23'),'description':'variable\x20auto\x20generated'},{'id':0x11,'name':'PHONE','description':'variable\x20auto\x20generated'},{'id':0x12,'name':_0x4fa27e('0xc'),'description':_0x4fa27e('0x21')},{'id':0x13,'name':_0x4fa27e('0xe'),'description':'variable\x20current\x20call\x20unique\x20identifier\x20auto\x20generated'},{'id':0x14,'name':_0x4fa27e('0xd'),'description':_0x4fa27e('0x0')},{'id':0x15,'name':_0x4fa27e('0xa'),'description':_0x4fa27e('0x0')},{'id':0x16,'name':_0x4fa27e('0x1a'),'description':_0x4fa27e('0x0')}];exports['create']=function(){const _0x31ce46=_0x4fa27e;return db[_0x31ce46('0x10')][_0x31ce46('0x2')](variables,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x31ce46('0x1f')](function(){const _0x500e79=_0x31ce46;logger[_0x500e79('0x12')](_0x500e79('0x8'));})[_0x31ce46('0x22')](function(){const _0x47b282=_0x31ce46;logger[_0x47b282('0x24')](_0x47b282('0x20'));});}; \ No newline at end of file +const a880_0xdd7e=['CHOICE','variable\x20auto\x20generated','Variables\x20have\x20been\x20created','variable\x20for\x20rate\x20call\x20auto\x20generated','CHANNEL(language)','then','EXTRAVAR','variable\x20for\x20menu\x20auto\x20generated','LASTNAME','CALLERID(num)','PHONE','variable\x20name\x20of\x20the\x20caller\x20auto\x20generated','catch','DBRESULT','CALLERID(name)','bulkCreate','EMAIL','create','VAR1','app','Variable','variable\x20useful\x20for\x20agent\x20popup\x20auto\x20generated','ORDER','variable\x20number\x20of\x20the\x20caller\x20auto\x20generated','INPUT','variable\x20for\x20db\x20query\x20result\x20auto\x20generated','OPTION','info','variable\x20for\x20order\x20auto\x20generated','Can\x27t\x20create\x20Variables','ORDERNUM','../logger','generic\x20variable\x20auto\x20generated','variable\x20current\x20call\x20unique\x20identifier\x20auto\x20generated'];(function(_0x13d5b5,_0xdd7ed2){const _0xfef36=function(_0x5f4d47){while(--_0x5f4d47){_0x13d5b5['push'](_0x13d5b5['shift']());}};_0xfef36(++_0xdd7ed2);}(a880_0xdd7e,0x19b));const a880_0xfef3=function(_0x13d5b5,_0xdd7ed2){_0x13d5b5=_0x13d5b5-0x0;let _0xfef36=a880_0xdd7e[_0x13d5b5];return _0xfef36;};const _0x2321f8=a880_0xfef3;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x2321f8('0x1c'))(_0x2321f8('0x10')),variables=[{'id':0x1,'name':_0x2321f8('0x1f'),'description':_0x2321f8('0x4')},{'id':0x2,'name':_0x2321f8('0x1b'),'description':_0x2321f8('0x19')},{'id':0x3,'name':_0x2321f8('0xa'),'description':_0x2321f8('0x16')},{'id':0x4,'name':'RATE','description':_0x2321f8('0x0')},{'id':0x5,'name':'CALLERID(dnid)','description':'variable\x20dialed\x20number\x20identifier\x20auto\x20generated'},{'id':0x6,'name':_0x2321f8('0xb'),'description':_0x2321f8('0x8')},{'id':0x7,'name':_0x2321f8('0x6'),'description':_0x2321f8('0x14')},{'id':0x8,'name':_0x2321f8('0x1'),'description':'variable\x20select\x20a\x20natural\x20language\x20file\x20when\x20available\x20auto\x20generated'},{'id':0x9,'name':'COUNTER','description':_0x2321f8('0x20')},{'id':0xa,'name':_0x2321f8('0xd'),'description':_0x2321f8('0x20')},{'id':0xb,'name':_0x2321f8('0x3'),'description':_0x2321f8('0x12')},{'id':0xc,'name':'FIRSTNAME','description':_0x2321f8('0x20')},{'id':0xd,'name':_0x2321f8('0x5'),'description':_0x2321f8('0x20')},{'id':0xe,'name':_0x2321f8('0x15'),'description':_0x2321f8('0x20')},{'id':0xf,'name':_0x2321f8('0x17'),'description':_0x2321f8('0x20')},{'id':0x10,'name':_0x2321f8('0x13'),'description':_0x2321f8('0x20')},{'id':0x11,'name':_0x2321f8('0x7'),'description':_0x2321f8('0x20')},{'id':0x12,'name':'RESULT','description':_0x2321f8('0x20')},{'id':0x13,'name':'UNIQUEID','description':_0x2321f8('0x1e')},{'id':0x14,'name':_0x2321f8('0xf'),'description':_0x2321f8('0x1d')},{'id':0x15,'name':'VAR2','description':_0x2321f8('0x1d')},{'id':0x16,'name':'VAR3','description':_0x2321f8('0x1d')}];exports[_0x2321f8('0xe')]=function(){const _0xe99c24=_0x2321f8;return db[_0xe99c24('0x11')][_0xe99c24('0xc')](variables,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0xe99c24('0x2')](function(){const _0x4aa50d=_0xe99c24;logger[_0x4aa50d('0x18')](_0x4aa50d('0x21'));})[_0xe99c24('0x9')](function(){const _0x2a0b92=_0xe99c24;logger['error'](_0x2a0b92('0x1a'));});}; \ No newline at end of file diff --git a/server/config/seedDB/voiceContexts.js b/server/config/seedDB/voiceContexts.js index a8f82b6..3655182 100644 --- a/server/config/seedDB/voiceContexts.js +++ b/server/config/seedDB/voiceContexts.js @@ -1 +1 @@ -const a881_0x5d0f=['VoiceContext','findOrCreate','info','from-voip-provider','name','default\x20entry\x20context\x20(DO\x20NOT\x20DELETE)','from-sip','../logger','xcally-mixmonitor-context','Context\x20','error','app','\x20have\x20been\x20created','\x20context','inbound-fax','from-voicemail'];(function(_0x4b1228,_0x5d0fcd){const _0x5ac9c4=function(_0x16343f){while(--_0x16343f){_0x4b1228['push'](_0x4b1228['shift']());}};_0x5ac9c4(++_0x5d0fcd);}(a881_0x5d0f,0x1f1));const a881_0x5ac9=function(_0x4b1228,_0x5d0fcd){_0x4b1228=_0x4b1228-0x0;let _0x5ac9c4=a881_0x5d0f[_0x4b1228];return _0x5ac9c4;};const _0xe38316=a881_0x5ac9;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0xe38316('0x6'))(_0xe38316('0xa')),voiceContexts=[{'name':_0xe38316('0x5'),'description':_0xe38316('0x4'),'defaultEntry':!![]},{'name':_0xe38316('0x2'),'description':_0xe38316('0x4'),'defaultEntry':!![]},{'name':_0xe38316('0xd'),'description':_0xe38316('0x4'),'defaultEntry':!![]},{'name':'outbound-fax','description':_0xe38316('0x4'),'defaultEntry':!![]},{'name':_0xe38316('0xe'),'description':_0xe38316('0x4'),'defaultEntry':!![]},{'name':_0xe38316('0x7'),'description':'default\x20entry\x20context\x20(DO\x20NOT\x20DELETE)','defaultEntry':!![]}];async function create(){const _0x202876=_0xe38316;for(const _0x16343f of voiceContexts){try{const [,_0x500748]=await db[_0x202876('0xf')][_0x202876('0x0')]({'where':{'name':_0x16343f[_0x202876('0x3')]},'defaults':_0x16343f});_0x500748&&logger[_0x202876('0x1')](_0x202876('0x8')+_0x16343f[_0x202876('0x3')]+_0x202876('0xb'));}catch(_0x21880b){logger[_0x202876('0x9')]('Can\x27t\x20create\x20'+_0x16343f[_0x202876('0x3')]+_0x202876('0xc'),_0x21880b);}}}module['exports']={'create':create}; \ No newline at end of file +const a881_0x3c2b=['info','from-voip-provider','inbound-fax','from-sip','exports','xcally-mixmonitor-context','error','../logger','\x20have\x20been\x20created','outbound-fax','Can\x27t\x20create\x20','Context\x20','\x20context','default\x20entry\x20context\x20(DO\x20NOT\x20DELETE)','from-voicemail','VoiceContext','name'];(function(_0x3e542e,_0x3c2bdc){const _0x2f1a32=function(_0x4b2174){while(--_0x4b2174){_0x3e542e['push'](_0x3e542e['shift']());}};_0x2f1a32(++_0x3c2bdc);}(a881_0x3c2b,0xe0));const a881_0x2f1a=function(_0x3e542e,_0x3c2bdc){_0x3e542e=_0x3e542e-0x0;let _0x2f1a32=a881_0x3c2b[_0x3e542e];return _0x2f1a32;};const _0x2bab3c=a881_0x2f1a;'use strict';const db=require('../../mysqldb')['db'],logger=require(_0x2bab3c('0x4'))('app'),voiceContexts=[{'name':_0x2bab3c('0x0'),'description':'default\x20entry\x20context\x20(DO\x20NOT\x20DELETE)','defaultEntry':!![]},{'name':_0x2bab3c('0xf'),'description':_0x2bab3c('0xa'),'defaultEntry':!![]},{'name':_0x2bab3c('0x10'),'description':_0x2bab3c('0xa'),'defaultEntry':!![]},{'name':_0x2bab3c('0x6'),'description':_0x2bab3c('0xa'),'defaultEntry':!![]},{'name':_0x2bab3c('0xb'),'description':_0x2bab3c('0xa'),'defaultEntry':!![]},{'name':_0x2bab3c('0x2'),'description':_0x2bab3c('0xa'),'defaultEntry':!![]}];async function create(){const _0x170edf=_0x2bab3c;for(const _0x4b2174 of voiceContexts){try{const [,_0x191fcf]=await db[_0x170edf('0xc')]['findOrCreate']({'where':{'name':_0x4b2174['name']},'defaults':_0x4b2174});_0x191fcf&&logger[_0x170edf('0xe')](_0x170edf('0x8')+_0x4b2174[_0x170edf('0xd')]+_0x170edf('0x5'));}catch(_0x4cf079){logger[_0x170edf('0x3')](_0x170edf('0x7')+_0x4b2174[_0x170edf('0xd')]+_0x170edf('0x9'),_0x4cf079);}}}module[_0x2bab3c('0x1')]={'create':create}; \ No newline at end of file diff --git a/server/config/seedDB/voiceExtensions.js b/server/config/seedDB/voiceExtensions.js index e86d37a..cd2f7df 100644 --- a/server/config/seedDB/voiceExtensions.js +++ b/server/config/seedDB/voiceExtensions.js @@ -1 +1 @@ -const a882_0x2257=['from-sip','Return','catch\x20all\x20inbound\x20calls\x20auto\x20generated','priority','outbound','${XMF-PATH},d','silence/1','info','outboundrouteid=','XCALLY-MOTION-ANSWER=0','length','_XCALLY_MIXMONITOR_FORMAT=wav','demo-congrats','type','Can\x27t\x20create\x20Voice\x20Extensions','context','../logger','queue','createAlways','agi://127.0.0.1/square,Orders','Playback','GotoIf','FAXOPT(ecm)=${XMF-ECM}','from-voip-provider','${XMD-AMDINITIALSILENCE},${XMD-AMDGREETING},${XMD-AMDAFTERGREETINGSILENCE},${XMD-AMDTOTALANALYSISTIME},${XMD-AMDMINWORDLENGTH},${XMD-AMDBETWEENWORDSSILENCE},${XMD-AMDMAXIMUMNUMBEROFWORDS},${XMD-AMDSILENCETHRESHOLD},${XMD-AMDMAXIMUMWORDLENGTH}','agi://127.0.0.1/square,Survey','${XMD-DIALCHANNEL},${XMD-DIALTIMEOUT},${XMD-DIALOPTIONS},${XMD-DIALURL}','6001','forward\x20to\x20Support\x20queue\x20auto\x20generated','MONITOR_OPTIONS=ab','agi://127.0.0.1/square,AutoAttendant','echo\x20test\x20demo\x20auto\x20generated','CALLERID(all)=${XMD-CALLERID}','CDR(type)=outbound','destroy','XCALLY-MOTION-PROGRESS=0','_[x][c][a][l][l][y][Q][u][e][u][e][E][x][t][e][n][s][i][o][n].','failed','FAXOPT(t38timeout)=${XMF-T38TIMEOUT}','forward\x20to\x20Agent\x20Management\x20IVR\x20auto\x20generated','exten','Echo','AGI','sequelize','agi','$[\x22${XMD-AGIAFTER}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGIAFTER})','Wait','6666','../../mysqldb','xcally-motion-fax','CDR(type)=internal','demo-echodone','forward\x20to\x20Orders\x20IVR\x20auto\x20generated','FAXOPT(minrate)=${XMF-MINRATE}','agi://127.0.0.1/square,CSI','lodash','MixMonitor','internal','6668','$[\x22${XMD-QUEUE}\x22\x20!=\x20\x22NONE\x22\x20]?QUEUE(${XMD-QUEUE})','VoiceExtension','description','6667','defaults','Execif','create','SendFax','FAXOPT(modem)=${XMF-MODEM}','system','$[\x22${XMD-AMD}\x22\x20!=\x20\x22NONE\x22\x20]?5:11','error','6000','600','CDR(type)=outbound-fax','Support,xX,,,300,,,,,','$[\x22${AMDSTATUS}\x22\x20==\x20\x22MACHINE\x22\x20]?14:11','CDR(type)=dialer','app','xcally-motion-preview','fax\x20extensions\x20auto\x20generated','Answer','demo-echotest','$[\x22${XMD-AGI}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGI})','FAXOPT(localstationid)=${XMF-LOCALSTATIONID}','Progress','FAXOPT(headerinfo)=${XMF-HEADERINFO}','Hangup','Background','then','CDR(type)=inbound','FAXOPT(maxrate)=${XMF-MAXRATE}','Set','forward\x20to\x20Auto\x20Attendant\x20IVR\x20auto\x20generated','Sales,xX,,,300,,,,,','Dial','${EXTEN:20},xX','Queue','dialer\x20extensions\x20auto\x20generated','forward\x20to\x20CSI\x20IVR\x20auto\x20generated'];(function(_0x2a2438,_0x225780){const _0x1764ac=function(_0x3540c7){while(--_0x3540c7){_0x2a2438['push'](_0x2a2438['shift']());}};_0x1764ac(++_0x225780);}(a882_0x2257,0x127));const a882_0x1764=function(_0x2a2438,_0x225780){_0x2a2438=_0x2a2438-0x0;let _0x1764ac=a882_0x2257[_0x2a2438];return _0x1764ac;};const _0x560477=a882_0x1764;'use strict';const _=require(_0x560477('0x39')),db=require(_0x560477('0x32'))['db'],{Op}=require(_0x560477('0x2d')),logger=require(_0x560477('0x12'))(_0x560477('0x4f')),applications={0x258:[{'app':_0x560477('0x5d'),'appdata':'CDR(type)=internal'},{'app':_0x560477('0x52')},{'app':_0x560477('0x16'),'appdata':_0x560477('0x53'),'isApp':!![]},{'app':_0x560477('0x2b'),'isApp':!![]},{'app':_0x560477('0x16'),'appdata':_0x560477('0x35'),'isApp':!![]},{'app':'Hangup'}],0x1770:[{'app':'Set','appdata':_0x560477('0x34')},{'app':_0x560477('0x52')},{'app':_0x560477('0x62'),'appdata':_0x560477('0x4c'),'appType':_0x560477('0x13'),'isApp':!![]},{'app':_0x560477('0x58')}],0x1771:[{'app':_0x560477('0x5d'),'appdata':_0x560477('0x34')},{'app':_0x560477('0x52')},{'app':_0x560477('0x62'),'appdata':_0x560477('0x5f'),'appType':_0x560477('0x13'),'isApp':!![]},{'app':_0x560477('0x58')}],0x1a0a:[{'app':_0x560477('0x5d'),'appdata':_0x560477('0x34')},{'app':_0x560477('0x2c'),'appdata':_0x560477('0x20'),'appType':'agi','isApp':!![]},{'app':_0x560477('0x58')}],0x1a0b:[{'app':'Set','appdata':'CDR(type)=internal'},{'app':_0x560477('0x2c'),'appdata':_0x560477('0x15'),'appType':'agi','isApp':!![]},{'app':_0x560477('0x58')}],0x1a0c:[{'app':_0x560477('0x5d'),'appdata':_0x560477('0x34')},{'app':_0x560477('0x2c'),'appdata':_0x560477('0x38'),'appType':_0x560477('0x2e'),'isApp':!![]},{'app':_0x560477('0x58')}],0x1a0d:[{'app':_0x560477('0x5d'),'appdata':'CDR(type)=internal'},{'app':_0x560477('0x2c'),'appdata':_0x560477('0x1b'),'appType':_0x560477('0x2e'),'isApp':!![]},{'app':_0x560477('0x58')}],0x1a0e:[{'app':_0x560477('0x5d'),'appdata':'CDR(type)=internal'},{'app':_0x560477('0x2c'),'appdata':'agi://127.0.0.1/square,AgentManagement','appType':_0x560477('0x2e'),'isApp':!![]},{'app':_0x560477('0x58')}],'xcally-motion-dialer':[{'app':_0x560477('0x5d'),'appdata':'CDR(type)=dialer'},{'app':_0x560477('0x5d'),'appdata':'CALLERID(all)=${XMD-CALLERID}'},{'app':_0x560477('0x17'),'appdata':_0x560477('0x47')},{'app':'Answer','appdata':''},{'app':_0x560477('0x59'),'appdata':_0x560477('0x8')},{'app':'AMD','appdata':_0x560477('0x1a')},{'app':_0x560477('0x17'),'appdata':'$[\x22${AMDSTATUS}\x22\x20==\x20\x22HUMAN\x22\x20]?11:9'},{'app':_0x560477('0x17'),'appdata':'$[\x22${AMDSTATUS}\x22\x20==\x20\x22NOTSURE\x22\x20]?11:10'},{'app':'GotoIf','appdata':_0x560477('0x4d')},{'app':_0x560477('0x42'),'appdata':_0x560477('0x54')},{'app':_0x560477('0x42'),'appdata':_0x560477('0x3d')},{'app':_0x560477('0x42'),'appdata':_0x560477('0x2f')},{'app':'Hangup'}],'xcally-motion-fax':[{'app':_0x560477('0x5d'),'appdata':_0x560477('0x4b')},{'app':_0x560477('0x30'),'appdata':'6'},{'app':'Set','appdata':_0x560477('0x18')},{'app':'Set','appdata':_0x560477('0x57')},{'app':_0x560477('0x5d'),'appdata':_0x560477('0x55')},{'app':_0x560477('0x5d'),'appdata':_0x560477('0x5c')},{'app':_0x560477('0x5d'),'appdata':_0x560477('0x37')},{'app':_0x560477('0x5d'),'appdata':_0x560477('0x45')},{'app':_0x560477('0x5d'),'appdata':_0x560477('0x28')},{'app':_0x560477('0x44'),'appdata':_0x560477('0x7')}],'xcally-motion-preview':[{'app':_0x560477('0x5d'),'appdata':_0x560477('0x4e')},{'app':_0x560477('0x5d'),'appdata':_0x560477('0x22')},{'app':_0x560477('0x42'),'appdata':'$[\x22${XMD-AGI}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGI})'},{'app':_0x560477('0x60'),'appdata':_0x560477('0x1c')},{'app':_0x560477('0x42'),'appdata':_0x560477('0x2f')},{'app':_0x560477('0x58')}],'_.':[{'app':_0x560477('0x5d'),'appdata':_0x560477('0x23')},{'app':'Set','appdata':_0x560477('0xb')},{'app':_0x560477('0x5d'),'appdata':_0x560477('0x25')},{'app':_0x560477('0x5d'),'appdata':_0x560477('0x1f')},{'app':_0x560477('0x5d'),'outboundrouteid':!![]},{'app':'Set','appdata':'_XCALLY_MIXMONITOR_UNIQUEID=${UNIQUEID}'},{'app':_0x560477('0x5d'),'appdata':_0x560477('0xd')},{'app':_0x560477('0x16'),'appdata':_0x560477('0xe'),'appType':'custom','isApp':!![]},{'app':'Hangup'}],'_X.':[{'app':_0x560477('0x5d'),'appdata':_0x560477('0x5b')},{'app':_0x560477('0x52')},{'app':_0x560477('0x16'),'appdata':'demo-congrats','isApp':!![]},{'app':_0x560477('0x58')}],'h':[{'app':_0x560477('0x58')}],'failed':[{'app':_0x560477('0x58')}]},voiceExtensions=[{'type':'internal','context':_0x560477('0x2'),'exten':_0x560477('0x4a'),'description':_0x560477('0x21')},{'type':'internal','context':_0x560477('0x2'),'exten':_0x560477('0x49'),'description':_0x560477('0x1e')},{'type':'internal','context':_0x560477('0x2'),'exten':_0x560477('0x1d'),'description':'forward\x20to\x20Sales\x20queue\x20auto\x20generated'},{'type':'internal','context':_0x560477('0x2'),'exten':_0x560477('0x31'),'description':_0x560477('0x5e')},{'type':_0x560477('0x3b'),'context':_0x560477('0x2'),'exten':_0x560477('0x40'),'description':_0x560477('0x36')},{'type':_0x560477('0x3b'),'context':_0x560477('0x2'),'exten':_0x560477('0x3c'),'description':_0x560477('0x1')},{'type':_0x560477('0x3b'),'context':_0x560477('0x2'),'exten':'6669','description':'forward\x20to\x20Survey\x20IVR\x20auto\x20generated'},{'type':_0x560477('0x3b'),'context':_0x560477('0x2'),'exten':'6670','description':_0x560477('0x29')},{'type':_0x560477('0x46'),'context':'from-sip','exten':'xcally-motion-dialer','description':_0x560477('0x0')},{'type':_0x560477('0x46'),'context':'from-sip','exten':_0x560477('0x33'),'description':_0x560477('0x51')},{'type':'system','context':_0x560477('0x2'),'exten':_0x560477('0x50'),'description':_0x560477('0x0')},{'type':_0x560477('0x6'),'context':_0x560477('0x2'),'exten':'_.','description':'demo\x20outbound\x20calls\x20auto\x20generated'},{'type':'inbound','context':_0x560477('0x19'),'exten':'_X.','description':_0x560477('0x4')},{'type':_0x560477('0x46'),'context':_0x560477('0x2'),'exten':'h','description':'catch\x20hangup\x20event\x20auto\x20generated'},{'type':_0x560477('0x46'),'context':'from-sip','exten':_0x560477('0x27'),'description':'catch\x20failed\x20event\x20auto\x20generated'}],applicationsAlways={'s':[{'app':_0x560477('0x3a'),'appdata':'${XCALLY_MIXMONITOR_UNIQUEID}.${XCALLY_MIXMONITOR_FORMAT},ab'},{'app':_0x560477('0x3')}],'_[x][c][a][l][l][y][Q][u][e][u][e][E][x][t][e][n][s][i][o][n].':[{'app':_0x560477('0x56')},{'app':_0x560477('0x62'),'appdata':_0x560477('0x61')}]},voiceExtensionsAlways=[{'type':_0x560477('0x46'),'context':'xcally-mixmonitor-context','exten':'s'},{'type':'system','context':'from-sip','exten':_0x560477('0x26')}];function createExtensions(_0x3540c7,_0x336e85){const _0x3e9728=_0x560477;return db['VoiceExtension']['bulkCreate'](_0x3540c7,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x3e9728('0x5a')](function(_0x19afc8){const _0x4d7d53=_0x3e9728;for(let _0x47f954=0x0;_0x47f954<_0x19afc8[_0x4d7d53('0xc')];_0x47f954+=0x1){if(_0x336e85[_0x19afc8[_0x47f954]['exten']])for(let _0xbf48e3=0x0;_0xbf48e3<_0x336e85[_0x19afc8[_0x47f954][_0x4d7d53('0x2a')]][_0x4d7d53('0xc')];_0xbf48e3+=0x1){_0x336e85[_0x19afc8[_0x47f954][_0x4d7d53('0x2a')]][_0xbf48e3]['outboundrouteid']&&(_0x336e85[_0x19afc8[_0x47f954]['exten']][_0xbf48e3]['appdata']=_0x4d7d53('0xa')+_0x19afc8[_0x47f954]['id'],delete _0x336e85[_0x19afc8[_0x47f954][_0x4d7d53('0x2a')]][_0xbf48e3]['outboundrouteid']),_0x336e85[_0x19afc8[_0x47f954][_0x4d7d53('0x2a')]][_0xbf48e3]=_[_0x4d7d53('0x41')](_0x336e85[_0x19afc8[_0x47f954]['exten']][_0xbf48e3],{'isApp':![],'appType':'custom','type':_0x19afc8[_0x47f954][_0x4d7d53('0xf')],'context':_0x19afc8[_0x47f954][_0x4d7d53('0x11')],'exten':_0x19afc8[_0x47f954][_0x4d7d53('0x2a')],'priority':parseInt(_0x19afc8[_0x47f954][_0x4d7d53('0x5')],0xa)+0x1+_0xbf48e3,'description':_0x19afc8[_0x47f954][_0x4d7d53('0x3f')],'VoiceExtensionId':_0x19afc8[_0x47f954]['id']}),db[_0x4d7d53('0x3e')][_0x4d7d53('0x43')](_0x336e85[_0x19afc8[_0x47f954][_0x4d7d53('0x2a')]][_0xbf48e3]);}}})[_0x3e9728('0x5a')](function(){const _0xb48db=_0x3e9728;logger[_0xb48db('0x9')]('Voice\x20Extensions\x20have\x20been\x20created');})['catch'](function(_0xeb23c6){const _0x56e276=_0x3e9728;logger[_0x56e276('0x48')](_0x56e276('0x10'),_0xeb23c6);});}exports[_0x560477('0x43')]=function(){createExtensions(voiceExtensions,applications);},exports[_0x560477('0x14')]=function(){const _0x1150cd=_0x560477;return db[_0x1150cd('0x3e')][_0x1150cd('0x24')]({'where':{[Op['or']]:voiceExtensionsAlways}})[_0x1150cd('0x5a')](function(){createExtensions(voiceExtensionsAlways,applicationsAlways);})['catch'](function(_0x1cefad){const _0x391858=_0x1150cd;logger[_0x391858('0x48')]('Can\x27t\x20create\x20Voice\x20Extensions',_0x1cefad);});}; \ No newline at end of file +const a882_0x4da5=['$[\x22${XMD-AGI}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGI})','Wait','forward\x20to\x20Survey\x20IVR\x20auto\x20generated','6666','FAXOPT(ecm)=${XMF-ECM}','CALLERID(all)=${XMD-CALLERID}','Can\x27t\x20create\x20Voice\x20Extensions','$[\x22${AMDSTATUS}\x22\x20==\x20\x22HUMAN\x22\x20]?11:9','600','Voice\x20Extensions\x20have\x20been\x20created','forward\x20to\x20Orders\x20IVR\x20auto\x20generated','${XMD-DIALCHANNEL},${XMD-DIALTIMEOUT},${XMD-DIALOPTIONS},${XMD-DIALURL}','priority','../logger','FAXOPT(headerinfo)=${XMF-HEADERINFO}','FAXOPT(minrate)=${XMF-MINRATE}','_XCALLY_MIXMONITOR_FORMAT=wav','length','xcally-motion-dialer','${XMF-PATH},d','internal','agi://127.0.0.1/square,CSI','CDR(type)=dialer','create','appdata','CDR(type)=inbound','agi://127.0.0.1/square,Orders','XCALLY-MOTION-PROGRESS=0','forward\x20to\x20Auto\x20Attendant\x20IVR\x20auto\x20generated','error','Playback','FAXOPT(maxrate)=${XMF-MAXRATE}','agi://127.0.0.1/square,AutoAttendant','catch\x20failed\x20event\x20auto\x20generated','xcally-motion-fax','../../mysqldb','demo-echotest','CDR(type)=outbound','info','MixMonitor','then','catch','Answer','_X.','exten','from-voip-provider','CDR(type)=internal','agi','lodash','AMD','VoiceExtension','6670','from-sip','createAlways','context','MONITOR_OPTIONS=ab','${XCALLY_MIXMONITOR_UNIQUEID}.${XCALLY_MIXMONITOR_FORMAT},ab','demo-congrats','_XCALLY_MIXMONITOR_UNIQUEID=${UNIQUEID}','FAXOPT(localstationid)=${XMF-LOCALSTATIONID}','app','forward\x20to\x20Sales\x20queue\x20auto\x20generated','Progress','6001','system','demo-echodone','CDR(type)=outbound-fax','Support,xX,,,300,,,,,','Return','agi://127.0.0.1/square,AgentManagement','AGI','type','Queue','$[\x22${XMD-AGIAFTER}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGIAFTER})','$[\x22${AMDSTATUS}\x22\x20==\x20\x22NOTSURE\x22\x20]?11:10','forward\x20to\x20Support\x20queue\x20auto\x20generated','6669','FAXOPT(modem)=${XMF-MODEM}','Execif','GotoIf','bulkCreate','Hangup','FAXOPT(t38timeout)=${XMF-T38TIMEOUT}','forward\x20to\x20Agent\x20Management\x20IVR\x20auto\x20generated','sequelize','description','Background','6668','Set','outbound','agi://127.0.0.1/square,Survey','queue','demo\x20outbound\x20calls\x20auto\x20generated','dialer\x20extensions\x20auto\x20generated','outboundrouteid'];(function(_0x246911,_0x4da584){const _0x57a3c4=function(_0x34c073){while(--_0x34c073){_0x246911['push'](_0x246911['shift']());}};_0x57a3c4(++_0x4da584);}(a882_0x4da5,0xc8));const a882_0x57a3=function(_0x246911,_0x4da584){_0x246911=_0x246911-0x0;let _0x57a3c4=a882_0x4da5[_0x246911];return _0x57a3c4;};const _0x3e5a1f=a882_0x57a3;'use strict';const _=require(_0x3e5a1f('0x26')),db=require(_0x3e5a1f('0x19'))['db'],{Op}=require(_0x3e5a1f('0x4a')),logger=require(_0x3e5a1f('0x3'))(_0x3e5a1f('0x32')),applications={0x258:[{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x24')},{'app':'Answer'},{'app':_0x3e5a1f('0x14'),'appdata':_0x3e5a1f('0x1a'),'isApp':!![]},{'app':'Echo','isApp':!![]},{'app':_0x3e5a1f('0x14'),'appdata':_0x3e5a1f('0x37'),'isApp':!![]},{'app':_0x3e5a1f('0x47')}],0x1770:[{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x24')},{'app':'Answer'},{'app':_0x3e5a1f('0x3e'),'appdata':_0x3e5a1f('0x39'),'appType':_0x3e5a1f('0x51'),'isApp':!![]},{'app':_0x3e5a1f('0x47')}],0x1771:[{'app':_0x3e5a1f('0x4e'),'appdata':'CDR(type)=internal'},{'app':_0x3e5a1f('0x20')},{'app':_0x3e5a1f('0x3e'),'appdata':'Sales,xX,,,300,,,,,','appType':_0x3e5a1f('0x51'),'isApp':!![]},{'app':_0x3e5a1f('0x47')}],0x1a0a:[{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x24')},{'app':_0x3e5a1f('0x3c'),'appdata':_0x3e5a1f('0x16'),'appType':_0x3e5a1f('0x25'),'isApp':!![]},{'app':'Hangup'}],0x1a0b:[{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x24')},{'app':_0x3e5a1f('0x3c'),'appdata':_0x3e5a1f('0x10'),'appType':_0x3e5a1f('0x25'),'isApp':!![]},{'app':_0x3e5a1f('0x47')}],0x1a0c:[{'app':_0x3e5a1f('0x4e'),'appdata':'CDR(type)=internal'},{'app':_0x3e5a1f('0x3c'),'appdata':_0x3e5a1f('0xb'),'appType':_0x3e5a1f('0x25'),'isApp':!![]},{'app':_0x3e5a1f('0x47')}],0x1a0d:[{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x24')},{'app':_0x3e5a1f('0x3c'),'appdata':_0x3e5a1f('0x50'),'appType':_0x3e5a1f('0x25'),'isApp':!![]},{'app':_0x3e5a1f('0x47')}],0x1a0e:[{'app':_0x3e5a1f('0x4e'),'appdata':'CDR(type)=internal'},{'app':'AGI','appdata':_0x3e5a1f('0x3b'),'appType':'agi','isApp':!![]},{'app':'Hangup'}],'xcally-motion-dialer':[{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0xc')},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x5a')},{'app':_0x3e5a1f('0x45'),'appdata':'$[\x22${XMD-AMD}\x22\x20!=\x20\x22NONE\x22\x20]?5:11'},{'app':_0x3e5a1f('0x20'),'appdata':''},{'app':_0x3e5a1f('0x4c'),'appdata':'silence/1'},{'app':_0x3e5a1f('0x27'),'appdata':'${XMD-AMDINITIALSILENCE},${XMD-AMDGREETING},${XMD-AMDAFTERGREETINGSILENCE},${XMD-AMDTOTALANALYSISTIME},${XMD-AMDMINWORDLENGTH},${XMD-AMDBETWEENWORDSSILENCE},${XMD-AMDMAXIMUMNUMBEROFWORDS},${XMD-AMDSILENCETHRESHOLD},${XMD-AMDMAXIMUMWORDLENGTH}'},{'app':_0x3e5a1f('0x45'),'appdata':_0x3e5a1f('0x5c')},{'app':_0x3e5a1f('0x45'),'appdata':_0x3e5a1f('0x40')},{'app':'GotoIf','appdata':'$[\x22${AMDSTATUS}\x22\x20==\x20\x22MACHINE\x22\x20]?14:11'},{'app':_0x3e5a1f('0x44'),'appdata':_0x3e5a1f('0x55')},{'app':_0x3e5a1f('0x44'),'appdata':'$[\x22${XMD-QUEUE}\x22\x20!=\x20\x22NONE\x22\x20]?QUEUE(${XMD-QUEUE})'},{'app':_0x3e5a1f('0x44'),'appdata':'$[\x22${XMD-AGIAFTER}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGIAFTER})'},{'app':_0x3e5a1f('0x47')}],'xcally-motion-fax':[{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x38')},{'app':_0x3e5a1f('0x56'),'appdata':'6'},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x59')},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x4')},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x31')},{'app':'Set','appdata':_0x3e5a1f('0x15')},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x5')},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x43')},{'app':'Set','appdata':_0x3e5a1f('0x48')},{'app':'SendFax','appdata':_0x3e5a1f('0x9')}],'xcally-motion-preview':[{'app':'Set','appdata':'CDR(type)=dialer'},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x5a')},{'app':_0x3e5a1f('0x44'),'appdata':_0x3e5a1f('0x55')},{'app':'Dial','appdata':_0x3e5a1f('0x1')},{'app':_0x3e5a1f('0x44'),'appdata':_0x3e5a1f('0x3f')},{'app':'Hangup'}],'_.':[{'app':'Set','appdata':_0x3e5a1f('0x1b')},{'app':'Set','appdata':'XCALLY-MOTION-ANSWER=0'},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x11')},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x2d')},{'app':_0x3e5a1f('0x4e'),'outboundrouteid':!![]},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x30')},{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0x6')},{'app':'Playback','appdata':_0x3e5a1f('0x2f'),'appType':'custom','isApp':!![]},{'app':_0x3e5a1f('0x47')}],'_X.':[{'app':_0x3e5a1f('0x4e'),'appdata':_0x3e5a1f('0xf')},{'app':'Answer'},{'app':_0x3e5a1f('0x14'),'appdata':_0x3e5a1f('0x2f'),'isApp':!![]},{'app':_0x3e5a1f('0x47')}],'h':[{'app':_0x3e5a1f('0x47')}],'failed':[{'app':_0x3e5a1f('0x47')}]},voiceExtensions=[{'type':'internal','context':_0x3e5a1f('0x2a'),'exten':_0x3e5a1f('0x5d'),'description':'echo\x20test\x20demo\x20auto\x20generated'},{'type':'internal','context':_0x3e5a1f('0x2a'),'exten':'6000','description':_0x3e5a1f('0x41')},{'type':_0x3e5a1f('0xa'),'context':_0x3e5a1f('0x2a'),'exten':_0x3e5a1f('0x35'),'description':_0x3e5a1f('0x33')},{'type':_0x3e5a1f('0xa'),'context':_0x3e5a1f('0x2a'),'exten':_0x3e5a1f('0x58'),'description':_0x3e5a1f('0x12')},{'type':'internal','context':'from-sip','exten':'6667','description':_0x3e5a1f('0x0')},{'type':_0x3e5a1f('0xa'),'context':_0x3e5a1f('0x2a'),'exten':_0x3e5a1f('0x4d'),'description':'forward\x20to\x20CSI\x20IVR\x20auto\x20generated'},{'type':_0x3e5a1f('0xa'),'context':_0x3e5a1f('0x2a'),'exten':_0x3e5a1f('0x42'),'description':_0x3e5a1f('0x57')},{'type':_0x3e5a1f('0xa'),'context':'from-sip','exten':_0x3e5a1f('0x29'),'description':_0x3e5a1f('0x49')},{'type':_0x3e5a1f('0x36'),'context':_0x3e5a1f('0x2a'),'exten':_0x3e5a1f('0x8'),'description':_0x3e5a1f('0x53')},{'type':'system','context':_0x3e5a1f('0x2a'),'exten':_0x3e5a1f('0x18'),'description':'fax\x20extensions\x20auto\x20generated'},{'type':_0x3e5a1f('0x36'),'context':_0x3e5a1f('0x2a'),'exten':'xcally-motion-preview','description':_0x3e5a1f('0x53')},{'type':_0x3e5a1f('0x4f'),'context':_0x3e5a1f('0x2a'),'exten':'_.','description':_0x3e5a1f('0x52')},{'type':'inbound','context':_0x3e5a1f('0x23'),'exten':_0x3e5a1f('0x21'),'description':'catch\x20all\x20inbound\x20calls\x20auto\x20generated'},{'type':_0x3e5a1f('0x36'),'context':_0x3e5a1f('0x2a'),'exten':'h','description':'catch\x20hangup\x20event\x20auto\x20generated'},{'type':_0x3e5a1f('0x36'),'context':_0x3e5a1f('0x2a'),'exten':'failed','description':_0x3e5a1f('0x17')}],applicationsAlways={'s':[{'app':_0x3e5a1f('0x1d'),'appdata':_0x3e5a1f('0x2e')},{'app':_0x3e5a1f('0x3a')}],'_[x][c][a][l][l][y][Q][u][e][u][e][E][x][t][e][n][s][i][o][n].':[{'app':_0x3e5a1f('0x34')},{'app':_0x3e5a1f('0x3e'),'appdata':'${EXTEN:20},xX'}]},voiceExtensionsAlways=[{'type':_0x3e5a1f('0x36'),'context':'xcally-mixmonitor-context','exten':'s'},{'type':_0x3e5a1f('0x36'),'context':_0x3e5a1f('0x2a'),'exten':'_[x][c][a][l][l][y][Q][u][e][u][e][E][x][t][e][n][s][i][o][n].'}];function createExtensions(_0x34c073,_0x49b526){const _0x526914=_0x3e5a1f;return db[_0x526914('0x28')][_0x526914('0x46')](_0x34c073,{'ignoreDuplicates':!![],'individualHooks':!![]})['then'](function(_0x11360c){const _0x30569e=_0x526914;for(let _0x3941a3=0x0;_0x3941a3<_0x11360c[_0x30569e('0x7')];_0x3941a3+=0x1){if(_0x49b526[_0x11360c[_0x3941a3]['exten']])for(let _0x5389e2=0x0;_0x5389e2<_0x49b526[_0x11360c[_0x3941a3][_0x30569e('0x22')]][_0x30569e('0x7')];_0x5389e2+=0x1){_0x49b526[_0x11360c[_0x3941a3]['exten']][_0x5389e2][_0x30569e('0x54')]&&(_0x49b526[_0x11360c[_0x3941a3][_0x30569e('0x22')]][_0x5389e2][_0x30569e('0xe')]='outboundrouteid='+_0x11360c[_0x3941a3]['id'],delete _0x49b526[_0x11360c[_0x3941a3][_0x30569e('0x22')]][_0x5389e2][_0x30569e('0x54')]),_0x49b526[_0x11360c[_0x3941a3]['exten']][_0x5389e2]=_['defaults'](_0x49b526[_0x11360c[_0x3941a3][_0x30569e('0x22')]][_0x5389e2],{'isApp':![],'appType':'custom','type':_0x11360c[_0x3941a3][_0x30569e('0x3d')],'context':_0x11360c[_0x3941a3][_0x30569e('0x2c')],'exten':_0x11360c[_0x3941a3][_0x30569e('0x22')],'priority':parseInt(_0x11360c[_0x3941a3][_0x30569e('0x2')],0xa)+0x1+_0x5389e2,'description':_0x11360c[_0x3941a3][_0x30569e('0x4b')],'VoiceExtensionId':_0x11360c[_0x3941a3]['id']}),db[_0x30569e('0x28')][_0x30569e('0xd')](_0x49b526[_0x11360c[_0x3941a3][_0x30569e('0x22')]][_0x5389e2]);}}})[_0x526914('0x1e')](function(){const _0x50092d=_0x526914;logger[_0x50092d('0x1c')](_0x50092d('0x5e'));})[_0x526914('0x1f')](function(_0xafbf4c){const _0x15c2f0=_0x526914;logger[_0x15c2f0('0x13')](_0x15c2f0('0x5b'),_0xafbf4c);});}exports[_0x3e5a1f('0xd')]=function(){createExtensions(voiceExtensions,applications);},exports[_0x3e5a1f('0x2b')]=function(){const _0x325dec=_0x3e5a1f;return db[_0x325dec('0x28')]['destroy']({'where':{[Op['or']]:voiceExtensionsAlways}})[_0x325dec('0x1e')](function(){createExtensions(voiceExtensionsAlways,applicationsAlways);})[_0x325dec('0x1f')](function(_0x6d07a1){logger['error']('Can\x27t\x20create\x20Voice\x20Extensions',_0x6d07a1);});}; \ No newline at end of file diff --git a/server/config/seedDB/voiceMusicOnHold.js b/server/config/seedDB/voiceMusicOnHold.js index d175de7..0d3cbb9 100644 --- a/server/config/seedDB/voiceMusicOnHold.js +++ b/server/config/seedDB/voiceMusicOnHold.js @@ -1 +1 @@ -const a883_0x2408=['default\x20moh\x20auto\x20generated','random','/var/opt/motion2/server/files/moh/wait/','wait','noice\x20moh\x20auto\x20generated','../../mysqldb','info','error','VoiceMusicOnHold','then','app','files','/var/lib/asterisk/moh/','noice','Can\x27t\x20create\x20Music\x20on\x20hold','/var/opt/motion2/server/files/moh/noice/','bulkCreate','default','create','wav'];(function(_0x4906a7,_0x2408cd){const _0x486bd6=function(_0x1fafd5){while(--_0x1fafd5){_0x4906a7['push'](_0x4906a7['shift']());}};_0x486bd6(++_0x2408cd);}(a883_0x2408,0x1f2));const a883_0x486b=function(_0x4906a7,_0x2408cd){_0x4906a7=_0x4906a7-0x0;let _0x486bd6=a883_0x2408[_0x4906a7];return _0x486bd6;};const _0x206828=a883_0x486b;'use strict';const db=require(_0x206828('0x7'))['db'],logger=require('../logger')(_0x206828('0xc')),voiceMusicOnHold=[{'id':0x1,'name':_0x206828('0x13'),'directory':_0x206828('0xe'),'mode':_0x206828('0xd'),'sort':_0x206828('0x3'),'format':_0x206828('0x1'),'defaultEntry':!![],'description':_0x206828('0x2')},{'id':0x2,'name':_0x206828('0xf'),'directory':_0x206828('0x11'),'mode':_0x206828('0xd'),'sort':'random','format':_0x206828('0x1'),'defaultEntry':!![],'description':_0x206828('0x6')},{'id':0x3,'name':_0x206828('0x5'),'directory':_0x206828('0x4'),'mode':_0x206828('0xd'),'sort':'random','format':_0x206828('0x1'),'defaultEntry':!![],'description':'wait\x20moh\x20auto\x20generated'}];exports[_0x206828('0x0')]=function(){const _0x51156a=_0x206828;return db[_0x51156a('0xa')][_0x51156a('0x12')](voiceMusicOnHold,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x51156a('0xb')](function(){const _0x355243=_0x51156a;logger[_0x355243('0x8')]('Music\x20on\x20hold\x20have\x20been\x20created');})['catch'](function(){const _0x1fa824=_0x51156a;logger[_0x1fa824('0x9')](_0x1fa824('0x10'));});}; \ No newline at end of file +const a883_0x1d66=['create','default\x20moh\x20auto\x20generated','random','/var/opt/motion2/server/files/moh/noice/','../../mysqldb','../logger','info','bulkCreate','/var/opt/motion2/server/files/moh/wait/','noice','wav','then','catch','/var/lib/asterisk/moh/','app','files'];(function(_0x1a22c8,_0x1d6604){const _0x255536=function(_0x371dc6){while(--_0x371dc6){_0x1a22c8['push'](_0x1a22c8['shift']());}};_0x255536(++_0x1d6604);}(a883_0x1d66,0x159));const a883_0x2555=function(_0x1a22c8,_0x1d6604){_0x1a22c8=_0x1a22c8-0x0;let _0x255536=a883_0x1d66[_0x1a22c8];return _0x255536;};const _0x1cc492=a883_0x2555;'use strict';const db=require(_0x1cc492('0xb'))['db'],logger=require(_0x1cc492('0xc'))(_0x1cc492('0x5')),voiceMusicOnHold=[{'id':0x1,'name':'default','directory':_0x1cc492('0x4'),'mode':'files','sort':_0x1cc492('0x9'),'format':_0x1cc492('0x1'),'defaultEntry':!![],'description':_0x1cc492('0x8')},{'id':0x2,'name':_0x1cc492('0x0'),'directory':_0x1cc492('0xa'),'mode':_0x1cc492('0x6'),'sort':_0x1cc492('0x9'),'format':_0x1cc492('0x1'),'defaultEntry':!![],'description':'noice\x20moh\x20auto\x20generated'},{'id':0x3,'name':'wait','directory':_0x1cc492('0xf'),'mode':_0x1cc492('0x6'),'sort':_0x1cc492('0x9'),'format':_0x1cc492('0x1'),'defaultEntry':!![],'description':'wait\x20moh\x20auto\x20generated'}];exports[_0x1cc492('0x7')]=function(){const _0x54c895=_0x1cc492;return db['VoiceMusicOnHold'][_0x54c895('0xe')](voiceMusicOnHold,{'ignoreDuplicates':!![],'individualHooks':!![]})[_0x54c895('0x2')](function(){const _0x4b3edc=_0x54c895;logger[_0x4b3edc('0xd')]('Music\x20on\x20hold\x20have\x20been\x20created');})[_0x54c895('0x3')](function(){logger['error']('Can\x27t\x20create\x20Music\x20on\x20hold');});}; \ No newline at end of file diff --git a/server/config/seedDB/voiceQueues.js b/server/config/seedDB/voiceQueues.js index f2761d9..804bb3e 100644 --- a/server/config/seedDB/voiceQueues.js +++ b/server/config/seedDB/voiceQueues.js @@ -1 +1 @@ -const a884_0x4a25=['Can\x27t\x20create\x20Voice\x20Queues','app','outbound','Telemarketing','Voice\x20Queues\x20have\x20been\x20created','VoiceQueue','type','addBlackLists','Sales','Support','error','addAgents','inbound','exports','inbound\x20voice\x20queue\x20auto\x20generated','rrmemory','findAll','wait','bulkCreate','noice','addTeams','outbound\x20voice\x20queue\x20campaign\x20auto\x20generated','addLists'];(function(_0x3e91e2,_0x4a2583){const _0x2a8c31=function(_0x529362){while(--_0x529362){_0x3e91e2['push'](_0x3e91e2['shift']());}};_0x2a8c31(++_0x4a2583);}(a884_0x4a25,0x19c));const a884_0x2a8c=function(_0x3e91e2,_0x4a2583){_0x3e91e2=_0x3e91e2-0x0;let _0x2a8c31=a884_0x4a25[_0x3e91e2];return _0x2a8c31;};const _0x245936=a884_0x2a8c;'use strict';const db=require('../../mysqldb')['db'],logger=require('../logger')(_0x245936('0x3')),voiceQueues=[{'id':0x1,'type':_0x245936('0xe'),'name':_0x245936('0xb'),'strategy':'ringall','musiconhold':_0x245936('0x13'),'description':'inbound\x20voice\x20queue\x20auto\x20generated'},{'id':0x2,'type':_0x245936('0xe'),'name':_0x245936('0xa'),'strategy':'ringall','musiconhold':_0x245936('0x13'),'description':_0x245936('0x10')},{'id':0x3,'type':_0x245936('0x4'),'name':'Survey','strategy':_0x245936('0x11'),'TrunkId':0x1,'IntervalId':0x1,'musiconhold':'noice','description':_0x245936('0x0')},{'id':0x4,'type':_0x245936('0x4'),'name':_0x245936('0x5'),'strategy':_0x245936('0x11'),'TrunkId':0x1,'IntervalId':0x1,'musiconhold':'noice','description':_0x245936('0x0')},{'id':0x5,'type':_0x245936('0x4'),'name':'CallbackCampaign','strategy':_0x245936('0x11'),'TrunkId':0x1,'IntervalId':0x1,'musiconhold':_0x245936('0x15'),'description':_0x245936('0x0')}];async function create(){const _0x4c7dde=_0x245936;try{await db['VoiceQueue'][_0x4c7dde('0x14')](voiceQueues,{'ignoreDuplicates':!![],'individualHooks':!![]});const _0x529362=await db[_0x4c7dde('0x7')][_0x4c7dde('0x12')]();for(const _0x95c05d of _0x529362){await _0x95c05d[_0x4c7dde('0xd')]([0x2,0x3],{'ignoreDuplicates':!![],'individualHooks':!![]}),await _0x95c05d[_0x4c7dde('0x16')]([0x1],{'ignoreDuplicates':!![],'individualHooks':!![]}),_0x95c05d[_0x4c7dde('0x8')]===_0x4c7dde('0x4')&&_0x95c05d['id']!==0x5&&(await _0x95c05d[_0x4c7dde('0x1')]([0x1],{'ignoreDuplicates':!![],'individualHooks':!![]}),await _0x95c05d[_0x4c7dde('0x9')]([0x2],{'ignoreDuplicates':!![],'individualHooks':!![]})),_0x95c05d['id']===0x5&&await _0x95c05d[_0x4c7dde('0x1')]([0x3],{'ignoreDuplicates':!![],'individualHooks':!![]});}logger['info'](_0x4c7dde('0x6'));}catch(_0x380756){logger[_0x4c7dde('0xc')](_0x4c7dde('0x2'),_0x380756);throw _0x380756;}}module[_0x245936('0xf')]={'create':create}; \ No newline at end of file +const a884_0x9bec=['VoiceQueue','inbound','noice','CallbackCampaign','info','app','rrmemory','../../mysqldb','error','Telemarketing','type','Sales','ringall','addAgents','Can\x27t\x20create\x20Voice\x20Queues','Support','Survey','outbound','addBlackLists','wait','Voice\x20Queues\x20have\x20been\x20created','findAll','outbound\x20voice\x20queue\x20campaign\x20auto\x20generated','../logger','inbound\x20voice\x20queue\x20auto\x20generated','exports','bulkCreate'];(function(_0x2c10fe,_0x9bec92){const _0x3c2e31=function(_0x5b00a8){while(--_0x5b00a8){_0x2c10fe['push'](_0x2c10fe['shift']());}};_0x3c2e31(++_0x9bec92);}(a884_0x9bec,0x1e6));const a884_0x3c2e=function(_0x2c10fe,_0x9bec92){_0x2c10fe=_0x2c10fe-0x0;let _0x3c2e31=a884_0x9bec[_0x2c10fe];return _0x3c2e31;};const _0x39a16f=a884_0x3c2e;'use strict';const db=require(_0x39a16f('0x7'))['db'],logger=require(_0x39a16f('0x17'))(_0x39a16f('0x5')),voiceQueues=[{'id':0x1,'type':_0x39a16f('0x1'),'name':_0x39a16f('0xf'),'strategy':_0x39a16f('0xc'),'musiconhold':_0x39a16f('0x13'),'description':_0x39a16f('0x18')},{'id':0x2,'type':_0x39a16f('0x1'),'name':_0x39a16f('0xb'),'strategy':_0x39a16f('0xc'),'musiconhold':'wait','description':'inbound\x20voice\x20queue\x20auto\x20generated'},{'id':0x3,'type':_0x39a16f('0x11'),'name':_0x39a16f('0x10'),'strategy':_0x39a16f('0x6'),'TrunkId':0x1,'IntervalId':0x1,'musiconhold':_0x39a16f('0x2'),'description':_0x39a16f('0x16')},{'id':0x4,'type':'outbound','name':_0x39a16f('0x9'),'strategy':'rrmemory','TrunkId':0x1,'IntervalId':0x1,'musiconhold':_0x39a16f('0x2'),'description':_0x39a16f('0x16')},{'id':0x5,'type':'outbound','name':_0x39a16f('0x3'),'strategy':_0x39a16f('0x6'),'TrunkId':0x1,'IntervalId':0x1,'musiconhold':_0x39a16f('0x2'),'description':'outbound\x20voice\x20queue\x20campaign\x20auto\x20generated'}];async function create(){const _0xa2e9ba=_0x39a16f;try{await db[_0xa2e9ba('0x0')][_0xa2e9ba('0x1a')](voiceQueues,{'ignoreDuplicates':!![],'individualHooks':!![]});const _0x5b00a8=await db['VoiceQueue'][_0xa2e9ba('0x15')]();for(const _0x46a169 of _0x5b00a8){await _0x46a169[_0xa2e9ba('0xd')]([0x2,0x3],{'ignoreDuplicates':!![],'individualHooks':!![]}),await _0x46a169['addTeams']([0x1],{'ignoreDuplicates':!![],'individualHooks':!![]}),_0x46a169[_0xa2e9ba('0xa')]===_0xa2e9ba('0x11')&&_0x46a169['id']!==0x5&&(await _0x46a169['addLists']([0x1],{'ignoreDuplicates':!![],'individualHooks':!![]}),await _0x46a169[_0xa2e9ba('0x12')]([0x2],{'ignoreDuplicates':!![],'individualHooks':!![]})),_0x46a169['id']===0x5&&await _0x46a169['addLists']([0x3],{'ignoreDuplicates':!![],'individualHooks':!![]});}logger[_0xa2e9ba('0x4')](_0xa2e9ba('0x14'));}catch(_0x193125){logger[_0xa2e9ba('0x8')](_0xa2e9ba('0xe'),_0x193125);throw _0x193125;}}module[_0x39a16f('0x19')]={'create':create}; \ No newline at end of file diff --git a/server/config/seedUsers.js b/server/config/seedUsers.js index 13a0161..1c20272 100644 --- a/server/config/seedUsers.js +++ b/server/config/seedUsers.js @@ -1 +1 @@ -const a885_0x2237=['/etc/pki/tls/certs/motion.crt','\x22%s\x22\x20<%s>','push','friend','util','wss','udp','bulkCreate','password','add\x20user','agent','ulaw','%s%s','then','catch','log','yes','/etc/pki/tls/private/motion.key','User','%s%s@xcally.com','format','../mysqldb'];(function(_0x4e9b1f,_0x2237d3){const _0x42f18f=function(_0x3d3759){while(--_0x3d3759){_0x4e9b1f['push'](_0x4e9b1f['shift']());}};_0x42f18f(++_0x2237d3);}(a885_0x2237,0x148));const a885_0x42f1=function(_0x4e9b1f,_0x2237d3){_0x4e9b1f=_0x4e9b1f-0x0;let _0x42f18f=a885_0x2237[_0x4e9b1f];return _0x42f18f;};const _0x97718=a885_0x42f1;'use strict';const util=require(_0x97718('0x6')),db=require(_0x97718('0x1'))['db'],users=[];for(let i=0x1;i<=0xc8;i+=0x1){users[_0x97718('0x4')]({'name':util[_0x97718('0x0')](_0x97718('0xe'),_0x97718('0xc'),i),'fullname':util[_0x97718('0x0')](_0x97718('0xe'),_0x97718('0xc'),i),'email':util[_0x97718('0x0')](_0x97718('0x15'),_0x97718('0xc'),i),'role':_0x97718('0xc'),'password':_0x97718('0xa'),'internal':0xfa0+i,'type':_0x97718('0x5'),'transport':[_0x97718('0x8'),'ws',_0x97718('0x7')],'disallow':['all'],'allow':[_0x97718('0xd')],'defaultuser':util['format'](_0x97718('0xe'),'agent',i),'encryption':_0x97718('0x12'),'avpf':_0x97718('0x12'),'force_avp':'yes','icesupport':_0x97718('0x12'),'dtlsenable':_0x97718('0x12'),'dtlsverify':'no','dtlscertfile':_0x97718('0x2'),'dtlsprivatekey':_0x97718('0x13'),'dtlssetup':'actpass','callerid':util[_0x97718('0x0')](_0x97718('0x3'),util['format'](_0x97718('0xe'),_0x97718('0xc'),i),0xfa0+i)});}db[_0x97718('0x14')][_0x97718('0x9')](users)[_0x97718('0xf')](function(){const _0x31d373=_0x97718;console[_0x31d373('0x11')](_0x31d373('0xb'));})[_0x97718('0x10')](function(_0x3d3759){const _0x52b97a=_0x97718;console[_0x52b97a('0x11')](_0x3d3759);}); \ No newline at end of file +const a885_0x1907=['util','all','log','udp','format','friend','agent','catch','\x22%s\x22\x20<%s>','add\x20user','/etc/pki/tls/certs/motion.crt','then','yes','%s%s@xcally.com','../mysqldb','password','bulkCreate','/etc/pki/tls/private/motion.key','ulaw','push','User','wss'];(function(_0x4777cf,_0x19071a){const _0x5b4162=function(_0xc0e47b){while(--_0xc0e47b){_0x4777cf['push'](_0x4777cf['shift']());}};_0x5b4162(++_0x19071a);}(a885_0x1907,0x1c8));const a885_0x5b41=function(_0x4777cf,_0x19071a){_0x4777cf=_0x4777cf-0x0;let _0x5b4162=a885_0x1907[_0x4777cf];return _0x5b4162;};const _0x5355b2=a885_0x5b41;'use strict';const util=require(_0x5355b2('0x6')),db=require(_0x5355b2('0x14'))['db'],users=[];for(let i=0x1;i<=0xc8;i+=0x1){users[_0x5355b2('0x3')]({'name':util['format']('%s%s',_0x5355b2('0xc'),i),'fullname':util[_0x5355b2('0xa')]('%s%s',_0x5355b2('0xc'),i),'email':util['format'](_0x5355b2('0x13'),_0x5355b2('0xc'),i),'role':_0x5355b2('0xc'),'password':_0x5355b2('0x15'),'internal':0xfa0+i,'type':_0x5355b2('0xb'),'transport':[_0x5355b2('0x9'),'ws',_0x5355b2('0x5')],'disallow':[_0x5355b2('0x7')],'allow':[_0x5355b2('0x2')],'defaultuser':util[_0x5355b2('0xa')]('%s%s',_0x5355b2('0xc'),i),'encryption':_0x5355b2('0x12'),'avpf':_0x5355b2('0x12'),'force_avp':_0x5355b2('0x12'),'icesupport':_0x5355b2('0x12'),'dtlsenable':_0x5355b2('0x12'),'dtlsverify':'no','dtlscertfile':_0x5355b2('0x10'),'dtlsprivatekey':_0x5355b2('0x1'),'dtlssetup':'actpass','callerid':util['format'](_0x5355b2('0xe'),util[_0x5355b2('0xa')]('%s%s',_0x5355b2('0xc'),i),0xfa0+i)});}db[_0x5355b2('0x4')][_0x5355b2('0x0')](users)[_0x5355b2('0x11')](function(){const _0x146f8d=_0x5355b2;console[_0x146f8d('0x8')](_0x146f8d('0xf'));})[_0x5355b2('0xd')](function(_0xc0e47b){const _0x520ff6=_0x5355b2;console[_0x520ff6('0x8')](_0xc0e47b);}); \ No newline at end of file diff --git a/server/config/socketio.js b/server/config/socketio.js index 0c3ec82..282d558 100644 --- a/server/config/socketio.js +++ b/server/config/socketio.js @@ -1 +1 @@ -const a886_0x283c=['Telephones','whatsapp','FaxInteraction','getSmsQueues','where','push','WhatsappQueue','disconnect','SmsInteraction','OpenchannelQueue','OpenchannelQueues','query','UserProfileSection','ChatInteractions','util','lodash','campaign:%s:%s','remotePort','User','user_has_fax_interactions:remove','OpenchannelInteractions','include','DISCONNECTED','address','MailInteraction','voice','map','log','removeOpenchannelInteractions','getWhatsappQueues','UserProfileResource','getVoiceQueues','resourceId','findAll','../mysqldb','SocketIO\x20','sms','user_has_chat_interactions:remove','FaxInteractions','VoiceQueues','IvrCampaigns','emit','default','name','getMailQueues','openchannel','removeMailInteractions','user:%s','connection','Trunks','MailQueues','getFaxQueues','ivr','length','remoteAddress','Campaign','request','MailInteractions','connectedAt','trunk:%s','Agents','WhatsappInteractions','then','nsp','user_has_mail_interactions:remove','%s:queue:%s','format','SmsInteractions','catch','ChatQueues','leave','FaxQueues','SmsQueues','MailQueue','telephone','voice:inbound','VoiceQueue','WhatsappInteraction','SmsQueue','undefined','handshake','Trunk','CONNECTED','userProfileId','ChatQueue','type','role','agent','findOne','WhatsappQueues','ChatInteraction'];(function(_0x612778,_0x283c36){const _0x5db194=function(_0x1d7ff3){while(--_0x1d7ff3){_0x612778['push'](_0x612778['shift']());}};_0x5db194(++_0x283c36);}(a886_0x283c,0x1d8));const a886_0x5db1=function(_0x612778,_0x283c36){_0x612778=_0x612778-0x0;let _0x5db194=a886_0x283c[_0x612778];return _0x5db194;};const _0x98fdfc=a886_0x5db1;'use strict';const _=require(_0x98fdfc('0x59')),util=require(_0x98fdfc('0x58')),db=require(_0x98fdfc('0x11'))['db'],queryQueues={'attributes':['id',_0x98fdfc('0x1a')],'include':[{'as':_0x98fdfc('0x2b'),'model':db[_0x98fdfc('0x1')],'attributes':['id','name','role'],'raw':!![],'where':{'role':_0x98fdfc('0x46')},'required':![]}]},queryTelephones={'raw':!![],'attributes':['id',_0x98fdfc('0x1a')],'where':{'role':'telephone'}},queryTrunks={'raw':!![],'attributes':['id','name']},queryAgents={'raw':!![],'attributes':['id',_0x98fdfc('0x1a')],'where':{'role':_0x98fdfc('0x46')}},queryCampaigns={'raw':!![],'attributes':['id',_0x98fdfc('0x1a'),_0x98fdfc('0x44')],'where':{'type':'ivr'}};function getAssociatedResources(_0x1d7ff3,_0x463e60,_0x17b6e8){const _0x474a47=_0x98fdfc;return db[_0x474a47('0x56')][_0x474a47('0x47')]({'where':{'name':_0x1d7ff3,'userProfileId':_0x463e60},'raw':!![]})['then'](function(_0x3ac94b){const _0x14e1db=_0x474a47;if(_0x3ac94b){if(_0x3ac94b['autoAssociation']){let _0x49faa5;switch(_0x1d7ff3){case _0x14e1db('0x16'):case'ChatQueues':case _0x14e1db('0x36'):case _0x14e1db('0x37'):case _0x14e1db('0x21'):case _0x14e1db('0x54'):case _0x14e1db('0x48'):_0x49faa5=queryQueues;break;case'Telephones':_0x49faa5=queryTelephones;break;case _0x14e1db('0x20'):_0x49faa5=queryTrunks;break;case _0x14e1db('0x17'):_0x49faa5=queryCampaigns;break;default:break;}return _0x49faa5?db[_0x17b6e8]['findAll'](_0x49faa5):_0x49faa5;}else return db[_0x14e1db('0xd')][_0x14e1db('0x10')]({'attributes':[_0x14e1db('0xf')],'where':{'sectionId':_0x3ac94b['id']},'raw':!![]})[_0x14e1db('0x2d')](function(_0x325448){const _0x25b2f8=_0x14e1db;if(_0x325448){const _0x3f7978={'where':{'id':_[_0x25b2f8('0x9')](_0x325448,_0x25b2f8('0xf'))},'raw':!![]};switch(_0x17b6e8){case _0x25b2f8('0x1'):_0x3f7978['where'][_0x25b2f8('0x45')]=_0x25b2f8('0x39');break;case _0x25b2f8('0x26'):_0x3f7978[_0x25b2f8('0x4e')]['type']=_0x25b2f8('0x23');break;}return db[_0x17b6e8][_0x25b2f8('0x10')](_0x3f7978);}else return[];});}else return[];})['then'](function(_0xc9187d){return _0xc9187d;});}function joinOrLeaveQueues(_0x382a05,_0x5000c2,_0x52e931,_0x1e74eb){const _0x7b43d9=_0x98fdfc;_0x382a05[_0x5000c2](util[_0x7b43d9('0x31')](_0x7b43d9('0x30'),_0x52e931,_0x1e74eb[_0x7b43d9('0x1a')]));if(_0x1e74eb[_0x7b43d9('0x2b')])for(let _0x1b98f6=0x0;_0x1b98f6<_0x1e74eb['Agents'][_0x7b43d9('0x24')];_0x1b98f6+=0x1){_0x382a05[_0x5000c2](util['format'](_0x7b43d9('0x1e'),_0x1e74eb[_0x7b43d9('0x2b')][_0x1b98f6][_0x7b43d9('0x1a')]));}}function joinOrLeave(_0x55b793,_0xb155a5,_0x40ea9a){const _0xffbc1b=_0x98fdfc;let _0x2506aa;_0x55b793['handshake']['query']['id']&&db[_0xffbc1b('0x1')][_0xffbc1b('0x47')]({'attributes':['id',_0xffbc1b('0x1a'),_0xffbc1b('0x45'),_0xffbc1b('0x42')],'where':{'id':_0x55b793[_0xffbc1b('0x3f')][_0xffbc1b('0x55')]['id']},'include':[{'model':db[_0xffbc1b('0x49')],'as':_0xffbc1b('0x57'),'attributes':['id'],'raw':!![]},{'model':db[_0xffbc1b('0x7')],'as':_0xffbc1b('0x28'),'attributes':['id'],'raw':!![]},{'model':db[_0xffbc1b('0x4c')],'as':_0xffbc1b('0x15'),'attributes':['id'],'raw':!![]},{'model':db[_0xffbc1b('0x52')],'as':_0xffbc1b('0x32'),'attributes':['id'],'raw':!![]},{'model':db['OpenchannelInteraction'],'as':_0xffbc1b('0x3'),'attributes':['id'],'raw':!![]},{'model':db[_0xffbc1b('0x3c')],'as':_0xffbc1b('0x2c'),'attributes':['id'],'raw':!![]}]})[_0xffbc1b('0x2d')](function(_0x3ba690){const _0x3d1d9d=_0xffbc1b;if(_0x3ba690){_0x2506aa=_0x3ba690,_0x55b793[_0xb155a5](util['format'](_0x3d1d9d('0x1e'),_0x3ba690['name']));const _0x5d37c8=[];switch(_0x3ba690[_0x3d1d9d('0x45')]){case'admin':_0x55b793[_0xb155a5]('voice:inbound'),_0x55b793[_0xb155a5]('voice:outbound');typeof queryQueues[_0x3d1d9d('0x4')]!==_0x3d1d9d('0x3e')&&delete queryQueues[_0x3d1d9d('0x4')];_0x5d37c8['push'](db[_0x3d1d9d('0x3b')][_0x3d1d9d('0x10')](queryQueues)),_0x5d37c8[_0x3d1d9d('0x4f')](db[_0x3d1d9d('0x43')][_0x3d1d9d('0x10')](queryQueues)),_0x5d37c8['push'](db['FaxQueue'][_0x3d1d9d('0x10')](queryQueues)),_0x5d37c8[_0x3d1d9d('0x4f')](db[_0x3d1d9d('0x3d')][_0x3d1d9d('0x10')](queryQueues)),_0x5d37c8[_0x3d1d9d('0x4f')](db[_0x3d1d9d('0x38')][_0x3d1d9d('0x10')](queryQueues)),_0x5d37c8[_0x3d1d9d('0x4f')](db[_0x3d1d9d('0x53')][_0x3d1d9d('0x10')](queryQueues)),_0x5d37c8[_0x3d1d9d('0x4f')](db[_0x3d1d9d('0x50')][_0x3d1d9d('0x10')](queryQueues)),_0x5d37c8[_0x3d1d9d('0x4f')](db[_0x3d1d9d('0x1')][_0x3d1d9d('0x10')](queryTelephones)),_0x5d37c8['push'](db[_0x3d1d9d('0x40')]['findAll'](queryTrunks)),_0x5d37c8[_0x3d1d9d('0x4f')](db[_0x3d1d9d('0x26')][_0x3d1d9d('0x10')](queryCampaigns)),_0x5d37c8[_0x3d1d9d('0x4f')](db[_0x3d1d9d('0x1')]['findAll'](queryAgents));break;case'user':_0x55b793[_0xb155a5](_0x3d1d9d('0x3a')),_0x55b793[_0xb155a5]('voice:outbound'),_0x5d37c8[_0x3d1d9d('0x4f')](getAssociatedResources(_0x3d1d9d('0x16'),_0x3ba690[_0x3d1d9d('0x42')],_0x3d1d9d('0x3b'))),_0x5d37c8[_0x3d1d9d('0x4f')](getAssociatedResources(_0x3d1d9d('0x34'),_0x3ba690[_0x3d1d9d('0x42')],_0x3d1d9d('0x43'))),_0x5d37c8[_0x3d1d9d('0x4f')](getAssociatedResources(_0x3d1d9d('0x36'),_0x3ba690[_0x3d1d9d('0x42')],'FaxQueue')),_0x5d37c8[_0x3d1d9d('0x4f')](getAssociatedResources(_0x3d1d9d('0x37'),_0x3ba690[_0x3d1d9d('0x42')],_0x3d1d9d('0x3d'))),_0x5d37c8[_0x3d1d9d('0x4f')](getAssociatedResources(_0x3d1d9d('0x21'),_0x3ba690[_0x3d1d9d('0x42')],_0x3d1d9d('0x38'))),_0x5d37c8['push'](getAssociatedResources(_0x3d1d9d('0x54'),_0x3ba690[_0x3d1d9d('0x42')],_0x3d1d9d('0x53'))),_0x5d37c8[_0x3d1d9d('0x4f')](getAssociatedResources('WhatsappQueues',_0x3ba690[_0x3d1d9d('0x42')],'WhatsappQueue')),_0x5d37c8[_0x3d1d9d('0x4f')](getAssociatedResources(_0x3d1d9d('0x4a'),_0x3ba690[_0x3d1d9d('0x42')],_0x3d1d9d('0x1'))),_0x5d37c8[_0x3d1d9d('0x4f')](getAssociatedResources('Trunks',_0x3ba690['userProfileId'],_0x3d1d9d('0x40'))),_0x5d37c8['push'](getAssociatedResources(_0x3d1d9d('0x17'),_0x3ba690[_0x3d1d9d('0x42')],_0x3d1d9d('0x26'))),_0x5d37c8[_0x3d1d9d('0x4f')](db[_0x3d1d9d('0x1')][_0x3d1d9d('0x10')](queryAgents));break;case _0x3d1d9d('0x46'):_0x55b793[_0xb155a5](_0x3d1d9d('0x3a')),_0x55b793[_0xb155a5]('voice:outbound'),_0x5d37c8['push'](_0x3ba690[_0x3d1d9d('0xe')]({'attributes':['id','name']})),_0x5d37c8[_0x3d1d9d('0x4f')](_0x3ba690['getChatQueues']({'attributes':['id','name']})),_0x5d37c8[_0x3d1d9d('0x4f')](_0x3ba690[_0x3d1d9d('0x22')]({'attributes':['id',_0x3d1d9d('0x1a')]})),_0x5d37c8['push'](_0x3ba690[_0x3d1d9d('0x4d')]({'attributes':['id','name']})),_0x5d37c8[_0x3d1d9d('0x4f')](_0x3ba690[_0x3d1d9d('0x1b')]({'attributes':['id',_0x3d1d9d('0x1a')]})),_0x5d37c8[_0x3d1d9d('0x4f')](_0x3ba690['getOpenchannelQueues']({'attributes':['id',_0x3d1d9d('0x1a')]})),_0x5d37c8[_0x3d1d9d('0x4f')](_0x3ba690[_0x3d1d9d('0xc')]({'attributes':['id',_0x3d1d9d('0x1a')]}));break;}return Promise['all'](_0x5d37c8);}})['then'](function(_0xac651){const _0x1c5def=_0xffbc1b;if(_0xac651&&_0xac651[_0x1c5def('0x24')])for(let _0x1d0fa0=0x0;_0x1d0fa0<_0xac651[_0x1c5def('0x24')];_0x1d0fa0+=0x1){for(let _0x14dcec=0x0;_0x14dcec<_0xac651[_0x1d0fa0][_0x1c5def('0x24')];_0x14dcec+=0x1){switch(_0x1d0fa0){case 0x0:joinOrLeaveQueues(_0x55b793,_0xb155a5,_0x1c5def('0x8'),_0xac651[_0x1d0fa0][_0x14dcec]);break;case 0x1:joinOrLeaveQueues(_0x55b793,_0xb155a5,'chat',_0xac651[_0x1d0fa0][_0x14dcec]);break;case 0x2:joinOrLeaveQueues(_0x55b793,_0xb155a5,'fax',_0xac651[_0x1d0fa0][_0x14dcec]);break;case 0x3:joinOrLeaveQueues(_0x55b793,_0xb155a5,_0x1c5def('0x13'),_0xac651[_0x1d0fa0][_0x14dcec]);break;case 0x4:joinOrLeaveQueues(_0x55b793,_0xb155a5,'mail',_0xac651[_0x1d0fa0][_0x14dcec]);break;case 0x5:joinOrLeaveQueues(_0x55b793,_0xb155a5,_0x1c5def('0x1c'),_0xac651[_0x1d0fa0][_0x14dcec]);break;case 0x6:joinOrLeaveQueues(_0x55b793,_0xb155a5,_0x1c5def('0x4b'),_0xac651[_0x1d0fa0][_0x14dcec]);break;case 0x7:_0x55b793[_0xb155a5](util[_0x1c5def('0x31')]('telephone:%s',_0xac651[_0x1d0fa0][_0x14dcec][_0x1c5def('0x1a')]));break;case 0x8:_0x55b793[_0xb155a5](util[_0x1c5def('0x31')](_0x1c5def('0x2a'),_0xac651[_0x1d0fa0][_0x14dcec][_0x1c5def('0x1a')]));break;case 0x9:_0x55b793[_0xb155a5](util[_0x1c5def('0x31')](_0x1c5def('0x5a'),_0xac651[_0x1d0fa0][_0x14dcec][_0x1c5def('0x44')],_0xac651[_0x1d0fa0][_0x14dcec][_0x1c5def('0x1a')]));break;case 0xa:_0x55b793[_0xb155a5](util[_0x1c5def('0x31')](_0x1c5def('0x1e'),_0xac651[_0x1d0fa0][_0x14dcec][_0x1c5def('0x1a')]));break;}}}})['then'](function(){const _0x2a14e5=_0xffbc1b;if(_0xb155a5===_0x2a14e5('0x35')){const _0x2e9a3a=_['map'](_0x2506aa['ChatInteractions'],'id');return _0x2506aa['removeChatInteractions'](_0x2e9a3a)[_0x2a14e5('0x2d')](function(){const _0x3e1377=_0x2a14e5;for(let _0x23af3e=0x0;_0x23af3e<_0x2e9a3a[_0x3e1377('0x24')];_0x23af3e+=0x1){_0x40ea9a['emit'](_0x3e1377('0x14'),{'ChatInteractionId':Number(_0x2e9a3a[_0x23af3e]),'UserId':Number(_0x2506aa['id'])});}});}})['then'](function(){const _0x2512ed=_0xffbc1b;if(_0xb155a5==='leave'){const _0x4f7fdc=_['map'](_0x2506aa[_0x2512ed('0x28')],'id');return _0x2506aa[_0x2512ed('0x1d')](_0x4f7fdc)[_0x2512ed('0x2d')](function(){const _0x460ff4=_0x2512ed;for(let _0x49ce98=0x0;_0x49ce98<_0x4f7fdc[_0x460ff4('0x24')];_0x49ce98+=0x1){_0x40ea9a['emit'](_0x460ff4('0x2f'),{'MailInteractionId':Number(_0x4f7fdc[_0x49ce98]),'UserId':Number(_0x2506aa['id'])});}});}})[_0xffbc1b('0x2d')](function(){const _0x38f911=_0xffbc1b;if(_0xb155a5==='leave'){const _0x3ef807=_[_0x38f911('0x9')](_0x2506aa['FaxInteractions'],'id');return _0x2506aa['removeFaxInteractions'](_0x3ef807)[_0x38f911('0x2d')](function(){const _0x196d07=_0x38f911;for(let _0x10def3=0x0;_0x10def3<_0x3ef807[_0x196d07('0x24')];_0x10def3+=0x1){_0x40ea9a[_0x196d07('0x18')](_0x196d07('0x2'),{'FaxInteractionId':Number(_0x3ef807[_0x10def3]),'UserId':Number(_0x2506aa['id'])});}});}})[_0xffbc1b('0x2d')](function(){const _0x55b7b2=_0xffbc1b;if(_0xb155a5===_0x55b7b2('0x35')){const _0x41d124=_['map'](_0x2506aa[_0x55b7b2('0x32')],'id');return _0x2506aa['removeSmsInteractions'](_0x41d124)[_0x55b7b2('0x2d')](function(){const _0x4666de=_0x55b7b2;for(let _0x3e1abd=0x0;_0x3e1abd<_0x41d124[_0x4666de('0x24')];_0x3e1abd+=0x1){_0x40ea9a[_0x4666de('0x18')]('user_has_sms_interactions:remove',{'SmsInteractionId':Number(_0x41d124[_0x3e1abd]),'UserId':Number(_0x2506aa['id'])});}});}})[_0xffbc1b('0x2d')](function(){const _0x391989=_0xffbc1b;if(_0xb155a5===_0x391989('0x35')){const _0x182b8a=_['map'](_0x2506aa['OpenchannelInteractions'],'id');return _0x2506aa[_0x391989('0xb')](_0x182b8a)['then'](function(){const _0x534333=_0x391989;for(let _0x4a2a00=0x0;_0x4a2a00<_0x182b8a['length'];_0x4a2a00+=0x1){_0x40ea9a[_0x534333('0x18')]('user_has_openchannel_interactions:remove',{'OpenchannelInteractionId':Number(_0x182b8a[_0x4a2a00]),'UserId':Number(_0x2506aa['id'])});}});}})[_0xffbc1b('0x2d')](function(){const _0x449f24=_0xffbc1b;if(_0xb155a5===_0x449f24('0x35')){const _0x3ef787=_[_0x449f24('0x9')](_0x2506aa['WhatsappInteractions'],'id');return _0x2506aa['removeWhatsappInteractions'](_0x3ef787)['then'](function(){const _0x7c0dc7=_0x449f24;for(let _0x22f28d=0x0;_0x22f28d<_0x3ef787[_0x7c0dc7('0x24')];_0x22f28d+=0x1){_0x40ea9a[_0x7c0dc7('0x18')]('user_has_whatsapp_interactions:remove',{'WhatsappInteractionId':Number(_0x3ef787[_0x22f28d]),'UserId':Number(_0x2506aa['id'])});}});}})[_0xffbc1b('0x33')](function(_0x52af67){const _0x318c6b=_0xffbc1b;_0x55b793[_0x318c6b('0xa')](_0x52af67);});}function onDisconnect(_0x430166,_0x2fa409){const _0x59d529=_0x98fdfc;joinOrLeave(_0x430166,_0x59d529('0x35'),_0x2fa409);}function onConnect(_0x2d4471){joinOrLeave(_0x2d4471,'join');}exports[_0x98fdfc('0x19')]=function(_0xf3559c){const _0x2dc287=_0x98fdfc;_0xf3559c['on'](_0x2dc287('0x1f'),function(_0x4578ed){const _0x14f0f3=_0x2dc287;_0x4578ed['setMaxListeners'](0x0),_0x4578ed[_0x14f0f3('0x6')]=_0x4578ed[_0x14f0f3('0x27')][_0x14f0f3('0x1f')][_0x14f0f3('0x25')]+':'+_0x4578ed[_0x14f0f3('0x27')][_0x14f0f3('0x1f')][_0x14f0f3('0x0')],_0x4578ed[_0x14f0f3('0x29')]=new Date(),_0x4578ed[_0x14f0f3('0xa')]=function(_0xe81af9){const _0x56f5e1=_0x14f0f3;console['log'](_0x56f5e1('0x12')+_0x4578ed[_0x56f5e1('0x2e')][_0x56f5e1('0x1a')]+'['+_0x4578ed[_0x56f5e1('0x6')]+']',_0xe81af9);},_0x4578ed['on'](_0x14f0f3('0x51'),function(){const _0xb1616c=_0x14f0f3;onDisconnect(_0x4578ed,_0xf3559c),_0x4578ed[_0xb1616c('0xa')](_0xb1616c('0x5'));}),onConnect(_0x4578ed),_0x4578ed[_0x14f0f3('0xa')](_0x14f0f3('0x41'));});}; \ No newline at end of file +const a886_0x9518=['FaxQueues','length','where','voice:outbound','findAll','handshake','ChatQueue','getSmsQueues','getMailQueues','sms','admin','openchannel','type','getFaxQueues','address','Trunks','lodash','user_has_sms_interactions:remove','push','DISCONNECTED','WhatsappInteractions','OpenchannelQueue','request','OpenchannelQueues','default','WhatsappInteraction','telephone','telephone:%s','leave','role','Campaign','VoiceQueues','%s:queue:%s','resourceId','include','MailInteractions','MailInteraction','format','then','SmsInteraction','../mysqldb','user_has_whatsapp_interactions:remove','user_has_openchannel_interactions:remove','removeOpenchannelInteractions','user_has_chat_interactions:remove','user','connectedAt','SmsInteractions','userProfileId','fax','user:%s','User','Agents','WhatsappQueues','ivr','emit','FaxInteractions','voice:inbound','Trunk','campaign:%s:%s','FaxQueue','SocketIO\x20','WhatsappQueue','agent','MailQueue','findOne','remotePort','OpenchannelInteractions','util','join','getChatQueues','voice','disconnect','getWhatsappQueues','removeFaxInteractions','MailQueues','nsp','IvrCampaigns','FaxInteraction','catch','remoteAddress','log','removeWhatsappInteractions','UserProfileSection','ChatQueues','removeChatInteractions','query','connection','removeSmsInteractions','name','user_has_fax_interactions:remove','ChatInteractions','getVoiceQueues','OpenchannelInteraction','SmsQueue','ChatInteraction','map','autoAssociation'];(function(_0xd79b12,_0x9518c5){const _0x31134d=function(_0x567666){while(--_0x567666){_0xd79b12['push'](_0xd79b12['shift']());}};_0x31134d(++_0x9518c5);}(a886_0x9518,0x10a));const a886_0x3113=function(_0xd79b12,_0x9518c5){_0xd79b12=_0xd79b12-0x0;let _0x31134d=a886_0x9518[_0xd79b12];return _0x31134d;};const _0x34b273=a886_0x3113;'use strict';const _=require(_0x34b273('0x2c')),util=require(_0x34b273('0x60')),db=require(_0x34b273('0x44'))['db'],queryQueues={'attributes':['id',_0x34b273('0x13')],'include':[{'as':_0x34b273('0x50'),'model':db[_0x34b273('0x4f')],'attributes':['id',_0x34b273('0x13'),_0x34b273('0x39')],'raw':!![],'where':{'role':_0x34b273('0x5b')},'required':![]}]},queryTelephones={'raw':!![],'attributes':['id',_0x34b273('0x13')],'where':{'role':_0x34b273('0x36')}},queryTrunks={'raw':!![],'attributes':['id',_0x34b273('0x13')]},queryAgents={'raw':!![],'attributes':['id',_0x34b273('0x13')],'where':{'role':_0x34b273('0x5b')}},queryCampaigns={'raw':!![],'attributes':['id',_0x34b273('0x13'),_0x34b273('0x28')],'where':{'type':_0x34b273('0x52')}};function getAssociatedResources(_0x567666,_0xaa501,_0x274f99){const _0x420baa=_0x34b273;return db[_0x420baa('0xd')][_0x420baa('0x5d')]({'where':{'name':_0x567666,'userProfileId':_0xaa501},'raw':!![]})['then'](function(_0x3d1f9a){const _0x28817a=_0x420baa;if(_0x3d1f9a){if(_0x3d1f9a[_0x28817a('0x1b')]){let _0xa69cef;switch(_0x567666){case'VoiceQueues':case _0x28817a('0xe'):case'FaxQueues':case'SmsQueues':case _0x28817a('0x5'):case _0x28817a('0x33'):case _0x28817a('0x51'):_0xa69cef=queryQueues;break;case'Telephones':_0xa69cef=queryTelephones;break;case _0x28817a('0x2b'):_0xa69cef=queryTrunks;break;case _0x28817a('0x7'):_0xa69cef=queryCampaigns;break;default:break;}return _0xa69cef?db[_0x274f99][_0x28817a('0x20')](_0xa69cef):_0xa69cef;}else return db['UserProfileResource']['findAll']({'attributes':[_0x28817a('0x3d')],'where':{'sectionId':_0x3d1f9a['id']},'raw':!![]})[_0x28817a('0x42')](function(_0x56936a){const _0x5146e1=_0x28817a;if(_0x56936a){const _0x22ce57={'where':{'id':_[_0x5146e1('0x1a')](_0x56936a,_0x5146e1('0x3d'))},'raw':!![]};switch(_0x274f99){case'User':_0x22ce57[_0x5146e1('0x1e')][_0x5146e1('0x39')]='telephone';break;case _0x5146e1('0x3a'):_0x22ce57[_0x5146e1('0x1e')][_0x5146e1('0x28')]='ivr';break;}return db[_0x274f99][_0x5146e1('0x20')](_0x22ce57);}else return[];});}else return[];})[_0x420baa('0x42')](function(_0x19404f){return _0x19404f;});}function joinOrLeaveQueues(_0x48ed51,_0x49dd2c,_0x200a26,_0x41d04e){const _0x22e8b4=_0x34b273;_0x48ed51[_0x49dd2c](util[_0x22e8b4('0x41')](_0x22e8b4('0x3c'),_0x200a26,_0x41d04e[_0x22e8b4('0x13')]));if(_0x41d04e[_0x22e8b4('0x50')])for(let _0x2a2602=0x0;_0x2a2602<_0x41d04e[_0x22e8b4('0x50')][_0x22e8b4('0x1d')];_0x2a2602+=0x1){_0x48ed51[_0x49dd2c](util[_0x22e8b4('0x41')](_0x22e8b4('0x4e'),_0x41d04e[_0x22e8b4('0x50')][_0x2a2602][_0x22e8b4('0x13')]));}}function joinOrLeave(_0x548fe4,_0x35d30f,_0x4a2af6){const _0x3f93d9=_0x34b273;let _0x15bcad;_0x548fe4[_0x3f93d9('0x21')][_0x3f93d9('0x10')]['id']&&db[_0x3f93d9('0x4f')]['findOne']({'attributes':['id','name',_0x3f93d9('0x39'),_0x3f93d9('0x4c')],'where':{'id':_0x548fe4[_0x3f93d9('0x21')][_0x3f93d9('0x10')]['id']},'include':[{'model':db[_0x3f93d9('0x19')],'as':'ChatInteractions','attributes':['id'],'raw':!![]},{'model':db[_0x3f93d9('0x40')],'as':_0x3f93d9('0x3f'),'attributes':['id'],'raw':!![]},{'model':db[_0x3f93d9('0x8')],'as':'FaxInteractions','attributes':['id'],'raw':!![]},{'model':db[_0x3f93d9('0x43')],'as':_0x3f93d9('0x4b'),'attributes':['id'],'raw':!![]},{'model':db[_0x3f93d9('0x17')],'as':'OpenchannelInteractions','attributes':['id'],'raw':!![]},{'model':db[_0x3f93d9('0x35')],'as':_0x3f93d9('0x30'),'attributes':['id'],'raw':!![]}]})[_0x3f93d9('0x42')](function(_0x51024d){const _0x3f9085=_0x3f93d9;if(_0x51024d){_0x15bcad=_0x51024d,_0x548fe4[_0x35d30f](util[_0x3f9085('0x41')](_0x3f9085('0x4e'),_0x51024d[_0x3f9085('0x13')]));const _0xf143f2=[];switch(_0x51024d['role']){case _0x3f9085('0x26'):_0x548fe4[_0x35d30f](_0x3f9085('0x55')),_0x548fe4[_0x35d30f](_0x3f9085('0x1f'));typeof queryQueues[_0x3f9085('0x3e')]!=='undefined'&&delete queryQueues[_0x3f9085('0x3e')];_0xf143f2['push'](db['VoiceQueue'][_0x3f9085('0x20')](queryQueues)),_0xf143f2['push'](db[_0x3f9085('0x22')][_0x3f9085('0x20')](queryQueues)),_0xf143f2[_0x3f9085('0x2e')](db['FaxQueue'][_0x3f9085('0x20')](queryQueues)),_0xf143f2[_0x3f9085('0x2e')](db[_0x3f9085('0x18')][_0x3f9085('0x20')](queryQueues)),_0xf143f2[_0x3f9085('0x2e')](db[_0x3f9085('0x5c')][_0x3f9085('0x20')](queryQueues)),_0xf143f2[_0x3f9085('0x2e')](db[_0x3f9085('0x31')][_0x3f9085('0x20')](queryQueues)),_0xf143f2[_0x3f9085('0x2e')](db[_0x3f9085('0x5a')][_0x3f9085('0x20')](queryQueues)),_0xf143f2['push'](db[_0x3f9085('0x4f')][_0x3f9085('0x20')](queryTelephones)),_0xf143f2[_0x3f9085('0x2e')](db[_0x3f9085('0x56')][_0x3f9085('0x20')](queryTrunks)),_0xf143f2['push'](db[_0x3f9085('0x3a')][_0x3f9085('0x20')](queryCampaigns)),_0xf143f2[_0x3f9085('0x2e')](db[_0x3f9085('0x4f')][_0x3f9085('0x20')](queryAgents));break;case _0x3f9085('0x49'):_0x548fe4[_0x35d30f](_0x3f9085('0x55')),_0x548fe4[_0x35d30f](_0x3f9085('0x1f')),_0xf143f2[_0x3f9085('0x2e')](getAssociatedResources(_0x3f9085('0x3b'),_0x51024d[_0x3f9085('0x4c')],'VoiceQueue')),_0xf143f2[_0x3f9085('0x2e')](getAssociatedResources(_0x3f9085('0xe'),_0x51024d[_0x3f9085('0x4c')],_0x3f9085('0x22'))),_0xf143f2[_0x3f9085('0x2e')](getAssociatedResources(_0x3f9085('0x1c'),_0x51024d['userProfileId'],_0x3f9085('0x58'))),_0xf143f2[_0x3f9085('0x2e')](getAssociatedResources('SmsQueues',_0x51024d[_0x3f9085('0x4c')],_0x3f9085('0x18'))),_0xf143f2[_0x3f9085('0x2e')](getAssociatedResources('MailQueues',_0x51024d['userProfileId'],_0x3f9085('0x5c'))),_0xf143f2['push'](getAssociatedResources(_0x3f9085('0x33'),_0x51024d['userProfileId'],_0x3f9085('0x31'))),_0xf143f2['push'](getAssociatedResources('WhatsappQueues',_0x51024d[_0x3f9085('0x4c')],'WhatsappQueue')),_0xf143f2[_0x3f9085('0x2e')](getAssociatedResources('Telephones',_0x51024d[_0x3f9085('0x4c')],_0x3f9085('0x4f'))),_0xf143f2['push'](getAssociatedResources(_0x3f9085('0x2b'),_0x51024d[_0x3f9085('0x4c')],_0x3f9085('0x56'))),_0xf143f2[_0x3f9085('0x2e')](getAssociatedResources(_0x3f9085('0x7'),_0x51024d[_0x3f9085('0x4c')],'Campaign')),_0xf143f2[_0x3f9085('0x2e')](db[_0x3f9085('0x4f')]['findAll'](queryAgents));break;case'agent':_0x548fe4[_0x35d30f](_0x3f9085('0x55')),_0x548fe4[_0x35d30f](_0x3f9085('0x1f')),_0xf143f2['push'](_0x51024d[_0x3f9085('0x16')]({'attributes':['id','name']})),_0xf143f2[_0x3f9085('0x2e')](_0x51024d[_0x3f9085('0x0')]({'attributes':['id','name']})),_0xf143f2[_0x3f9085('0x2e')](_0x51024d[_0x3f9085('0x29')]({'attributes':['id','name']})),_0xf143f2[_0x3f9085('0x2e')](_0x51024d[_0x3f9085('0x23')]({'attributes':['id',_0x3f9085('0x13')]})),_0xf143f2[_0x3f9085('0x2e')](_0x51024d[_0x3f9085('0x24')]({'attributes':['id',_0x3f9085('0x13')]})),_0xf143f2[_0x3f9085('0x2e')](_0x51024d['getOpenchannelQueues']({'attributes':['id',_0x3f9085('0x13')]})),_0xf143f2[_0x3f9085('0x2e')](_0x51024d[_0x3f9085('0x3')]({'attributes':['id',_0x3f9085('0x13')]}));break;}return Promise['all'](_0xf143f2);}})[_0x3f93d9('0x42')](function(_0x31893f){const _0x41acde=_0x3f93d9;if(_0x31893f&&_0x31893f[_0x41acde('0x1d')])for(let _0x173c5b=0x0;_0x173c5b<_0x31893f[_0x41acde('0x1d')];_0x173c5b+=0x1){for(let _0x4ea0e6=0x0;_0x4ea0e6<_0x31893f[_0x173c5b][_0x41acde('0x1d')];_0x4ea0e6+=0x1){switch(_0x173c5b){case 0x0:joinOrLeaveQueues(_0x548fe4,_0x35d30f,_0x41acde('0x1'),_0x31893f[_0x173c5b][_0x4ea0e6]);break;case 0x1:joinOrLeaveQueues(_0x548fe4,_0x35d30f,'chat',_0x31893f[_0x173c5b][_0x4ea0e6]);break;case 0x2:joinOrLeaveQueues(_0x548fe4,_0x35d30f,_0x41acde('0x4d'),_0x31893f[_0x173c5b][_0x4ea0e6]);break;case 0x3:joinOrLeaveQueues(_0x548fe4,_0x35d30f,_0x41acde('0x25'),_0x31893f[_0x173c5b][_0x4ea0e6]);break;case 0x4:joinOrLeaveQueues(_0x548fe4,_0x35d30f,'mail',_0x31893f[_0x173c5b][_0x4ea0e6]);break;case 0x5:joinOrLeaveQueues(_0x548fe4,_0x35d30f,_0x41acde('0x27'),_0x31893f[_0x173c5b][_0x4ea0e6]);break;case 0x6:joinOrLeaveQueues(_0x548fe4,_0x35d30f,'whatsapp',_0x31893f[_0x173c5b][_0x4ea0e6]);break;case 0x7:_0x548fe4[_0x35d30f](util[_0x41acde('0x41')](_0x41acde('0x37'),_0x31893f[_0x173c5b][_0x4ea0e6][_0x41acde('0x13')]));break;case 0x8:_0x548fe4[_0x35d30f](util['format']('trunk:%s',_0x31893f[_0x173c5b][_0x4ea0e6][_0x41acde('0x13')]));break;case 0x9:_0x548fe4[_0x35d30f](util[_0x41acde('0x41')](_0x41acde('0x57'),_0x31893f[_0x173c5b][_0x4ea0e6][_0x41acde('0x28')],_0x31893f[_0x173c5b][_0x4ea0e6]['name']));break;case 0xa:_0x548fe4[_0x35d30f](util[_0x41acde('0x41')]('user:%s',_0x31893f[_0x173c5b][_0x4ea0e6]['name']));break;}}}})['then'](function(){const _0x20c154=_0x3f93d9;if(_0x35d30f==='leave'){const _0x3e57ad=_[_0x20c154('0x1a')](_0x15bcad[_0x20c154('0x15')],'id');return _0x15bcad[_0x20c154('0xf')](_0x3e57ad)['then'](function(){const _0x255dc3=_0x20c154;for(let _0x288bdb=0x0;_0x288bdb<_0x3e57ad[_0x255dc3('0x1d')];_0x288bdb+=0x1){_0x4a2af6[_0x255dc3('0x53')](_0x255dc3('0x48'),{'ChatInteractionId':Number(_0x3e57ad[_0x288bdb]),'UserId':Number(_0x15bcad['id'])});}});}})[_0x3f93d9('0x42')](function(){const _0x5b674b=_0x3f93d9;if(_0x35d30f===_0x5b674b('0x38')){const _0x1b3a1e=_[_0x5b674b('0x1a')](_0x15bcad[_0x5b674b('0x3f')],'id');return _0x15bcad['removeMailInteractions'](_0x1b3a1e)['then'](function(){const _0x45b006=_0x5b674b;for(let _0x5dbcb4=0x0;_0x5dbcb4<_0x1b3a1e[_0x45b006('0x1d')];_0x5dbcb4+=0x1){_0x4a2af6[_0x45b006('0x53')]('user_has_mail_interactions:remove',{'MailInteractionId':Number(_0x1b3a1e[_0x5dbcb4]),'UserId':Number(_0x15bcad['id'])});}});}})['then'](function(){const _0x2e7ddd=_0x3f93d9;if(_0x35d30f==='leave'){const _0x201419=_[_0x2e7ddd('0x1a')](_0x15bcad[_0x2e7ddd('0x54')],'id');return _0x15bcad[_0x2e7ddd('0x4')](_0x201419)[_0x2e7ddd('0x42')](function(){const _0x30ca09=_0x2e7ddd;for(let _0x20e0fe=0x0;_0x20e0fe<_0x201419['length'];_0x20e0fe+=0x1){_0x4a2af6[_0x30ca09('0x53')](_0x30ca09('0x14'),{'FaxInteractionId':Number(_0x201419[_0x20e0fe]),'UserId':Number(_0x15bcad['id'])});}});}})[_0x3f93d9('0x42')](function(){const _0x434f62=_0x3f93d9;if(_0x35d30f===_0x434f62('0x38')){const _0x290693=_[_0x434f62('0x1a')](_0x15bcad[_0x434f62('0x4b')],'id');return _0x15bcad[_0x434f62('0x12')](_0x290693)[_0x434f62('0x42')](function(){const _0x5e231d=_0x434f62;for(let _0x282ffd=0x0;_0x282ffd<_0x290693[_0x5e231d('0x1d')];_0x282ffd+=0x1){_0x4a2af6[_0x5e231d('0x53')](_0x5e231d('0x2d'),{'SmsInteractionId':Number(_0x290693[_0x282ffd]),'UserId':Number(_0x15bcad['id'])});}});}})['then'](function(){const _0x3a3614=_0x3f93d9;if(_0x35d30f==='leave'){const _0x177208=_[_0x3a3614('0x1a')](_0x15bcad[_0x3a3614('0x5f')],'id');return _0x15bcad[_0x3a3614('0x47')](_0x177208)['then'](function(){const _0x6a6ab8=_0x3a3614;for(let _0x5b4e60=0x0;_0x5b4e60<_0x177208['length'];_0x5b4e60+=0x1){_0x4a2af6[_0x6a6ab8('0x53')](_0x6a6ab8('0x46'),{'OpenchannelInteractionId':Number(_0x177208[_0x5b4e60]),'UserId':Number(_0x15bcad['id'])});}});}})['then'](function(){const _0x4542a3=_0x3f93d9;if(_0x35d30f===_0x4542a3('0x38')){const _0x1ca9dd=_['map'](_0x15bcad['WhatsappInteractions'],'id');return _0x15bcad[_0x4542a3('0xc')](_0x1ca9dd)[_0x4542a3('0x42')](function(){const _0x3efa78=_0x4542a3;for(let _0x57533d=0x0;_0x57533d<_0x1ca9dd[_0x3efa78('0x1d')];_0x57533d+=0x1){_0x4a2af6[_0x3efa78('0x53')](_0x3efa78('0x45'),{'WhatsappInteractionId':Number(_0x1ca9dd[_0x57533d]),'UserId':Number(_0x15bcad['id'])});}});}})[_0x3f93d9('0x9')](function(_0x5481cb){const _0x1dd472=_0x3f93d9;_0x548fe4[_0x1dd472('0xb')](_0x5481cb);});}function onDisconnect(_0x3e2d86,_0x4c1a2b){const _0x46a333=_0x34b273;joinOrLeave(_0x3e2d86,_0x46a333('0x38'),_0x4c1a2b);}function onConnect(_0x461144){const _0x31081a=_0x34b273;joinOrLeave(_0x461144,_0x31081a('0x61'));}exports[_0x34b273('0x34')]=function(_0x1b4bb4){const _0x3cd04a=_0x34b273;_0x1b4bb4['on'](_0x3cd04a('0x11'),function(_0x20f881){const _0x5d07e0=_0x3cd04a;_0x20f881['setMaxListeners'](0x0),_0x20f881[_0x5d07e0('0x2a')]=_0x20f881[_0x5d07e0('0x32')][_0x5d07e0('0x11')][_0x5d07e0('0xa')]+':'+_0x20f881['request'][_0x5d07e0('0x11')][_0x5d07e0('0x5e')],_0x20f881[_0x5d07e0('0x4a')]=new Date(),_0x20f881[_0x5d07e0('0xb')]=function(_0x5c1a8b){const _0x346666=_0x5d07e0;console['log'](_0x346666('0x59')+_0x20f881[_0x346666('0x6')][_0x346666('0x13')]+'['+_0x20f881['address']+']',_0x5c1a8b);},_0x20f881['on'](_0x5d07e0('0x2'),function(){const _0x31c6ec=_0x5d07e0;onDisconnect(_0x20f881,_0x1b4bb4),_0x20f881[_0x31c6ec('0xb')](_0x31c6ec('0x2f'));}),onConnect(_0x20f881),_0x20f881[_0x5d07e0('0xb')]('CONNECTED');});}; \ No newline at end of file diff --git a/server/config/triggers/index.js b/server/config/triggers/index.js index e63fc98..2fe8c3f 100644 --- a/server/config/triggers/index.js +++ b/server/config/triggers/index.js @@ -1 +1 @@ -const a887_0xe59a=['findOne','http','Fax','Chat','default','toLowerCase','afterUpdate','closed','get','closedinteraction','outgoingmessage','name','opened','Trigger,\x20%s','then','../logger','client','length','incomingmessage','interface','ChatInteraction','changed','UserId','callback','condition','channel','FaxInteraction','request','WhatsappMessage','OpenchannelInteraction','Openchannel','newmessage','WhatsappInteraction','afterCreate','catch','addHook','User','error','util','Whatsapp','OpenchannelMessage','triggers','format','Sms','SIP/%s','info','model','direction','event','Mail','FaxMessage','EventManager','newinteraction','SmsInteraction','jayson/promise','undefined'];(function(_0x17dd75,_0xe59af6){const _0x3de609=function(_0x1bf90d){while(--_0x1bf90d){_0x17dd75['push'](_0x17dd75['shift']());}};_0x3de609(++_0xe59af6);}(a887_0xe59a,0x180));const a887_0x3de6=function(_0x17dd75,_0xe59af6){_0x17dd75=_0x17dd75-0x0;let _0x3de609=a887_0xe59a[_0x17dd75];return _0x3de609;};const _0x477a29=a887_0x3de6;'use strict';const util=require(_0x477a29('0x2e')),db=require('../../mysqldb')['db'],jayson=require(_0x477a29('0x6')),logger=require(_0x477a29('0x17'))(_0x477a29('0x31')),client=jayson[_0x477a29('0x18')][_0x477a29('0x9')]({'port':0x232a}),triggers=[{'channel':_0x477a29('0xb'),'model':_0x477a29('0x1c'),'event':_0x477a29('0x29'),'condition':_0x477a29('0x4'),'callback':afterCreate},{'channel':_0x477a29('0xb'),'model':'ChatInteraction','event':'afterUpdate','condition':_0x477a29('0x11'),'callback':afterUpdate},{'channel':'Chat','model':'ChatMessage','event':_0x477a29('0x29'),'condition':_0x477a29('0x27'),'callback':afterCreateMessage},{'channel':_0x477a29('0x33'),'model':'SmsInteraction','event':_0x477a29('0x29'),'condition':_0x477a29('0x4'),'callback':afterCreate},{'channel':_0x477a29('0x33'),'model':_0x477a29('0x5'),'event':_0x477a29('0xe'),'condition':_0x477a29('0x11'),'callback':afterUpdate},{'channel':_0x477a29('0x33'),'model':'SmsMessage','event':_0x477a29('0x29'),'condition':'newmessage','callback':afterCreateMessage},{'channel':_0x477a29('0x2f'),'model':_0x477a29('0x28'),'event':'afterCreate','condition':_0x477a29('0x4'),'callback':afterCreate},{'channel':_0x477a29('0x2f'),'model':_0x477a29('0x28'),'event':_0x477a29('0xe'),'condition':_0x477a29('0x11'),'callback':afterUpdate},{'channel':'Whatsapp','model':_0x477a29('0x24'),'event':_0x477a29('0x29'),'condition':_0x477a29('0x27'),'callback':afterCreateMessage},{'channel':_0x477a29('0xa'),'model':_0x477a29('0x22'),'event':_0x477a29('0x29'),'condition':'newinteraction','callback':afterCreate},{'channel':_0x477a29('0xa'),'model':_0x477a29('0x22'),'event':_0x477a29('0xe'),'condition':_0x477a29('0x11'),'callback':afterUpdate},{'channel':_0x477a29('0xa'),'model':_0x477a29('0x2'),'event':_0x477a29('0x29'),'condition':'newmessage','callback':afterCreateMessage},{'channel':_0x477a29('0x1'),'model':'MailInteraction','event':_0x477a29('0x29'),'condition':_0x477a29('0x4'),'callback':afterCreate},{'channel':_0x477a29('0x1'),'model':'MailInteraction','event':'afterUpdate','condition':'closedinteraction','callback':afterUpdate},{'channel':'Mail','model':'MailMessage','event':_0x477a29('0x29'),'condition':'newmessage','callback':afterCreateMessage},{'channel':_0x477a29('0x26'),'model':_0x477a29('0x25'),'event':_0x477a29('0x29'),'condition':_0x477a29('0x4'),'callback':afterCreate},{'channel':_0x477a29('0x26'),'model':_0x477a29('0x25'),'event':'afterUpdate','condition':'closedinteraction','callback':afterUpdate},{'channel':'Openchannel','model':_0x477a29('0x30'),'event':_0x477a29('0x29'),'condition':_0x477a29('0x27'),'callback':afterCreateMessage}];function request(_0x1bf90d){const _0x11ed3b=_0x477a29;return client[_0x11ed3b('0x23')](_0x11ed3b('0x3'),_0x1bf90d)['then'](function(_0x4b8371){const _0x45d198=_0x11ed3b;logger[_0x45d198('0x35')](_0x45d198('0x15'),_0x45d198('0x3'),_0x4b8371),_0x4b8371[_0x45d198('0x2d')]&&(_0x4b8371[_0x45d198('0x2d')]['code']===0x1f4&&logger[_0x45d198('0x2d')](_0x45d198('0x15'),_0x45d198('0x3'),_0x4b8371[_0x45d198('0x2d')]));})[_0x11ed3b('0x2a')](function(_0x4df724){const _0x47e423=_0x11ed3b;logger[_0x47e423('0x2d')](_0x47e423('0x15'),_0x47e423('0x3'),_0x4df724);});}function afterCreateMessage(_0x18627d){return function(_0x20aa72){const _0x1219ef=a887_0x3de6;return _0x20aa72=_0x20aa72[_0x1219ef('0x10')]({'plain':!![]}),_0x20aa72[_0x1219ef('0x21')]=_0x18627d,_0x20aa72[_0x1219ef('0x0')]=_0x20aa72[_0x1219ef('0x37')],_0x20aa72[_0x1219ef('0x1e')]?db[_0x1219ef('0x2c')][_0x1219ef('0x8')]({'where':{'id':_0x20aa72[_0x1219ef('0x1e')]},'attributes':['id',_0x1219ef('0x13')],'raw':!![]})[_0x1219ef('0x16')](function(_0x2ec738){const _0xb729c2=_0x1219ef;return _0x20aa72[_0xb729c2('0x1b')]=util['format'](_0xb729c2('0x34'),_0x2ec738[_0xb729c2('0x13')]),_0x20aa72['channel']=_0x18627d,request({'event':_0xb729c2('0x1a'),'message':_0x20aa72});})['catch'](function(_0x58b19c){const _0x177338=_0x1219ef;console[_0x177338('0x2d')](_0x58b19c);}):request({'event':_0x1219ef('0x12'),'message':_0x20aa72});};}function afterCreate(_0x211a70,_0x187835){return function(_0x40ff3f){const _0x4b07d6=a887_0x3de6;return _0x40ff3f=_0x40ff3f[_0x4b07d6('0x10')]({'plain':!![]}),_0x40ff3f['channel']=_0x211a70,_0x40ff3f[_0x4b07d6('0x0')]=_0x4b07d6('0x14'),request({'event':_0x187835,'message':_0x40ff3f});};}function afterUpdate(_0x2e996a,_0x54e599){return function(_0x125231){const _0x558387=a887_0x3de6;if(_0x125231[_0x558387('0x1d')]('closed')&&_0x125231[_0x558387('0xf')])return _0x125231=_0x125231[_0x558387('0x10')]({'plain':!![]}),_0x125231[_0x558387('0x21')]=_0x2e996a,_0x125231[_0x558387('0x0')]=_0x558387('0xf'),_0x125231['UserId']?db[_0x558387('0x2c')]['findOne']({'where':{'id':_0x125231[_0x558387('0x1e')]},'attributes':['id',_0x558387('0x13')],'raw':!![]})[_0x558387('0x16')](function(_0x446151){const _0x534e92=_0x558387;return _0x125231['interface']=util[_0x534e92('0x32')](_0x534e92('0x34'),_0x446151[_0x534e92('0x13')]),request({'event':_0x54e599,'message':_0x125231});})[_0x558387('0x2a')](function(_0x108689){const _0x552541=_0x558387;console[_0x552541('0x2d')](_0x108689);}):request({'event':_0x54e599,'message':_0x125231});};}exports[_0x477a29('0xc')]=function(){const _0x9ae696=_0x477a29;for(let _0x305332=0x0;_0x305332=_0x36e07b['agents'])throw Error(_0x4e8ffc('0x16'));_0x46bc52(_0x3d7909);})[_0x18a388('0x2')](function(_0x3bfe48){_0x2c6d29(_0x3bfe48);});});}; \ No newline at end of file +const a888_0x5e37=['chat','voice','isUndefined','Maximum\x20login\x20has\x20been\x20reached','getLicense','includes','toLowerCase','openchannel','User','agents','sms','fax','lodash','mail','getChannels','agent','then','update','clearBlockUser','./license/util','whatsapp','isValidChannel','role','../mysqldb','count'];(function(_0x417cb7,_0x5e37eb){const _0x3f41ee=function(_0x3507ea){while(--_0x3507ea){_0x417cb7['push'](_0x417cb7['shift']());}};_0x3f41ee(++_0x5e37eb);}(a888_0x5e37,0xb1));const a888_0x3f41=function(_0x417cb7,_0x5e37eb){_0x417cb7=_0x417cb7-0x0;let _0x3f41ee=a888_0x5e37[_0x417cb7];return _0x3f41ee;};const _0x56a916=a888_0x3f41;'use strict';const _=require(_0x56a916('0xa')),db=require(_0x56a916('0x15'))['db'],util=require(_0x56a916('0x11')),{Op}=require('sequelize'),channels=[_0x56a916('0x18'),_0x56a916('0xb'),_0x56a916('0x17'),_0x56a916('0x9'),_0x56a916('0x8'),_0x56a916('0x12'),_0x56a916('0x5')];exports[_0x56a916('0xc')]=function(){return channels;},exports[_0x56a916('0x13')]=function(_0x3507ea){const _0xdd6445=_0x56a916;return _0x3507ea=_0x3507ea[_0xdd6445('0x4')](),_[_0xdd6445('0x3')](channels,_0x3507ea);},exports[_0x56a916('0x10')]=function(_0x596a22,_0x9adb9f,_0x30b373,_0x532152){const _0x4315bf=_0x56a916,_0x15b6dd={'loginAttempts':_0x9adb9f,'blocked':_0x30b373};return!_[_0x4315bf('0x0')](_0x532152)&&(_0x15b6dd['blockedAt']=_0x532152),_0x596a22[_0x4315bf('0xf')](_0x15b6dd);},exports[_0x56a916('0x2')]=function(_0x46dc2f){return new Promise(function(_0x4f5b43,_0x498ec2){const _0x34bf23=a888_0x3f41;let _0x17acfa=0x0;_0x46dc2f[_0x34bf23('0x14')]!=='agent'&&_0x4f5b43(_0x46dc2f),db[_0x34bf23('0x6')][_0x34bf23('0x16')]({'where':{'role':_0x34bf23('0xd'),'online':!![],'id':{[Op['ne']]:_0x46dc2f['id']}}})[_0x34bf23('0xe')](function(_0x42b0fe){return _0x17acfa=_0x42b0fe,util['getLicense']();})[_0x34bf23('0xe')](function(_0x5bb07c){const _0x130737=_0x34bf23;if(_0x5bb07c&&_0x5bb07c[_0x130737('0x7')]&&_0x17acfa>=_0x5bb07c[_0x130737('0x7')])throw Error(_0x130737('0x1'));_0x4f5b43(_0x46dc2f);})['catch'](function(_0x1baef3){_0x498ec2(_0x1baef3);});});}; \ No newline at end of file diff --git a/server/errors/index.js b/server/errors/index.js index e8bfdb4..547e133 100644 --- a/server/errors/index.js +++ b/server/errors/index.js @@ -1 +1 @@ -const a889_0x1dd3=['render','status','exports','json'];(function(_0x191cf6,_0x1dd375){const _0x3dfc4f=function(_0x102a38){while(--_0x102a38){_0x191cf6['push'](_0x191cf6['shift']());}};_0x3dfc4f(++_0x1dd375);}(a889_0x1dd3,0xd0));const a889_0x3dfc=function(_0x191cf6,_0x1dd375){_0x191cf6=_0x191cf6-0x0;let _0x3dfc4f=a889_0x1dd3[_0x191cf6];return _0x3dfc4f;};const _0xacd06e=a889_0x3dfc;'use strict';module[_0xacd06e('0x2')][0x194]=function pageNotFound(_0x102a38,_0x1ff0c2){const _0xc52b11=_0xacd06e,_0x31e227='404',_0x46824a=0x194,_0x190a8b={'status':_0x46824a};_0x1ff0c2[_0xc52b11('0x1')](_0x190a8b[_0xc52b11('0x1')]),_0x1ff0c2[_0xc52b11('0x0')](_0x31e227,{},function(_0x505b86,_0x4ac436){const _0x19742c=_0xc52b11;if(_0x505b86)return _0x1ff0c2['status'](_0x190a8b[_0x19742c('0x1')])[_0x19742c('0x3')](_0x190a8b);_0x1ff0c2['send'](_0x4ac436);});}; \ No newline at end of file +const a889_0x482c=['send','404','json','render','status'];(function(_0x532e75,_0x482c19){const _0x40b710=function(_0x512337){while(--_0x512337){_0x532e75['push'](_0x532e75['shift']());}};_0x40b710(++_0x482c19);}(a889_0x482c,0x181));const a889_0x40b7=function(_0x532e75,_0x482c19){_0x532e75=_0x532e75-0x0;let _0x40b710=a889_0x482c[_0x532e75];return _0x40b710;};'use strict';module['exports'][0x194]=function pageNotFound(_0x512337,_0x518f53){const _0x3edf7b=a889_0x40b7,_0x36617a=_0x3edf7b('0x1'),_0x5c69cc=0x194,_0xa6b7d3={'status':_0x5c69cc};_0x518f53[_0x3edf7b('0x4')](_0xa6b7d3[_0x3edf7b('0x4')]),_0x518f53[_0x3edf7b('0x3')](_0x36617a,{},function(_0x1812d9,_0x163923){const _0x298ca9=_0x3edf7b;if(_0x1812d9)return _0x518f53[_0x298ca9('0x4')](_0xa6b7d3[_0x298ca9('0x4')])[_0x298ca9('0x2')](_0xa6b7d3);_0x518f53[_0x298ca9('0x0')](_0x163923);});}; \ No newline at end of file diff --git a/server/globals.js b/server/globals.js index 366448d..e88355d 100644 --- a/server/globals.js +++ b/server/globals.js @@ -1 +1 @@ -const a890_0x527b=['appRoot','path'];(function(_0x41554d,_0x527b75){const _0x1e2138=function(_0x16d51c){while(--_0x16d51c){_0x41554d['push'](_0x41554d['shift']());}};_0x1e2138(++_0x527b75);}(a890_0x527b,0x141));const a890_0x1e21=function(_0x41554d,_0x527b75){_0x41554d=_0x41554d-0x0;let _0x1e2138=a890_0x527b[_0x41554d];return _0x1e2138;};const _0x1826b9=a890_0x1e21,path=require(_0x1826b9('0x0'));global[_0x1826b9('0x1')]=path['resolve'](__dirname); \ No newline at end of file +const a890_0x4afa=['resolve','path'];(function(_0x49b2b4,_0x4afa46){const _0x26b622=function(_0x3ac20b){while(--_0x3ac20b){_0x49b2b4['push'](_0x49b2b4['shift']());}};_0x26b622(++_0x4afa46);}(a890_0x4afa,0x193));const a890_0x26b6=function(_0x49b2b4,_0x4afa46){_0x49b2b4=_0x49b2b4-0x0;let _0x26b622=a890_0x4afa[_0x49b2b4];return _0x26b622;};const _0x240889=a890_0x26b6,path=require(_0x240889('0x0'));global['appRoot']=path[_0x240889('0x1')](__dirname); \ No newline at end of file diff --git a/server/migrations/2.0.12.js b/server/migrations/2.0.12.js index 33f7902..12143c4 100644 --- a/server/migrations/2.0.12.js +++ b/server/migrations/2.0.12.js @@ -1 +1 @@ -var a891_0xe95c=['exports'];(function(_0x269842,_0xe95c81){var _0x21a4c6=function(_0x3cefd1){while(--_0x3cefd1){_0x269842['push'](_0x269842['shift']());}};_0x21a4c6(++_0xe95c81);}(a891_0xe95c,0x1de));var a891_0x21a4=function(_0x269842,_0xe95c81){_0x269842=_0x269842-0x0;var _0x21a4c6=a891_0xe95c[_0x269842];return _0x21a4c6;};var _0x37743c=a891_0x21a4;'use strict';module[_0x37743c('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file +'use strict';module['exports']={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.13.js b/server/migrations/2.0.13.js index 0f11994..02f747a 100644 --- a/server/migrations/2.0.13.js +++ b/server/migrations/2.0.13.js @@ -1 +1 @@ -const a892_0x33ec=['prototype','STRING','users','addColumn','DATE','deletedat','queryInterface','exports','then','Removed\x20column\x20%s\x20from\x20%s','BOOLEAN','catch','../config/logger','rescheduled','info','phoneBarRingInUse','removeColumn','Added\x20column\x20%s\x20to\x20%s','deleted','cm_hopper_final','stringify','renameColumn','reschedule'];(function(_0xe08e7c,_0x33ec18){const _0x5efde5=function(_0x50cb34){while(--_0x50cb34){_0xe08e7c['push'](_0xe08e7c['shift']());}};_0x5efde5(++_0x33ec18);}(a892_0x33ec,0x169));const a892_0x5efd=function(_0xe08e7c,_0x33ec18){_0xe08e7c=_0xe08e7c-0x0;let _0x5efde5=a892_0x33ec[_0xe08e7c];return _0x5efde5;};const _0x3cd409=a892_0x5efd;'use strict';const logger=require(_0x3cd409('0x13'))('migration'),Migration=function(_0x50cb34){const _0xd0d12=_0x3cd409;this[_0xd0d12('0xd')]=_0x50cb34;};Migration[_0x3cd409('0x7')][_0x3cd409('0xa')]=function(_0x383c4a,_0x47ba3d,_0x4cc5e7){const _0xf42a2a=_0x3cd409;return this[_0xf42a2a('0xd')][_0xf42a2a('0xa')](_0x383c4a,_0x47ba3d,_0x4cc5e7)['then'](function(){const _0x214bf8=_0xf42a2a;logger[_0x214bf8('0x15')](_0x214bf8('0x1'),_0x47ba3d,_0x383c4a);})[_0xf42a2a('0x12')](function(_0x52cfb0){const _0x3d3b6d=_0xf42a2a;logger[_0x3d3b6d('0x15')](JSON[_0x3d3b6d('0x4')](_0x52cfb0));});},Migration['prototype'][_0x3cd409('0x0')]=function(_0x2ff750,_0x1df88e){const _0x4798bf=_0x3cd409;return this[_0x4798bf('0xd')][_0x4798bf('0x0')](_0x2ff750,_0x1df88e)[_0x4798bf('0xf')](function(){const _0x4a2150=_0x4798bf;logger[_0x4a2150('0x15')](_0x4a2150('0x10'),_0x1df88e,_0x2ff750);})[_0x4798bf('0x12')](function(_0x4412f8){const _0x1d9760=_0x4798bf;logger[_0x1d9760('0x15')](JSON[_0x1d9760('0x4')](_0x4412f8));});},Migration[_0x3cd409('0x7')][_0x3cd409('0x5')]=function(_0x4c1043,_0x28bb36,_0x377848){const _0x2cf70a=_0x3cd409;return this[_0x2cf70a('0xd')]['renameColumn'](_0x4c1043,_0x28bb36,_0x377848)['then'](function(){const _0x45c32c=_0x2cf70a;logger[_0x45c32c('0x15')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x28bb36,_0x377848,_0x4c1043);})[_0x2cf70a('0x12')](function(_0x45c784){const _0x5c04a3=_0x2cf70a;logger['info'](JSON[_0x5c04a3('0x4')](_0x45c784));});},module[_0x3cd409('0xe')]={'up':function(_0x5a6fb3,_0x37718f){const _0x3e7de0=_0x3cd409,_0x2ddb71=new Migration(_0x5a6fb3);_0x2ddb71[_0x3e7de0('0xa')](_0x3e7de0('0x3'),_0x3e7de0('0xc'),{'type':_0x37718f[_0x3e7de0('0xb')]}),_0x2ddb71[_0x3e7de0('0xa')](_0x3e7de0('0x9'),_0x3e7de0('0x16'),{'type':_0x37718f[_0x3e7de0('0x11')],'defaultValue':![]}),_0x2ddb71[_0x3e7de0('0xa')]('cm_hopper_final',_0x3e7de0('0x2'),{'type':_0x37718f[_0x3e7de0('0x8')],'defaultValue':null}),_0x2ddb71[_0x3e7de0('0x5')](_0x3e7de0('0x3'),'reschedule',_0x3e7de0('0x14'));},'down':function(_0x1b56c3,_0x43ffa8){const _0x2de291=_0x3cd409,_0x3a5ef4=new Migration(_0x1b56c3,_0x43ffa8);_0x3a5ef4[_0x2de291('0x0')](_0x2de291('0x9'),_0x2de291('0x16')),_0x3a5ef4[_0x2de291('0x0')](_0x2de291('0x3'),_0x2de291('0xc')),_0x3a5ef4['removeColumn'](_0x2de291('0x3'),_0x2de291('0x2')),_0x3a5ef4[_0x2de291('0x5')](_0x2de291('0x3'),_0x2de291('0x14'),_0x2de291('0x6'));}}; \ No newline at end of file +const a892_0x4bbd=['exports','renameColumn','info','BOOLEAN','phoneBarRingInUse','reschedule','Removed\x20column\x20%s\x20from\x20%s','rescheduled','deleted','then','queryInterface','addColumn','users','catch','migration','removeColumn','stringify','prototype','cm_hopper_final','STRING','deletedat','Added\x20column\x20%s\x20to\x20%s'];(function(_0x24aa42,_0x4bbd20){const _0x76bcab=function(_0x38ce06){while(--_0x38ce06){_0x24aa42['push'](_0x24aa42['shift']());}};_0x76bcab(++_0x4bbd20);}(a892_0x4bbd,0xb2));const a892_0x76bc=function(_0x24aa42,_0x4bbd20){_0x24aa42=_0x24aa42-0x0;let _0x76bcab=a892_0x4bbd[_0x24aa42];return _0x76bcab;};const _0x289fa9=a892_0x76bc;'use strict';const logger=require('../config/logger')(_0x289fa9('0xc')),Migration=function(_0x38ce06){const _0x32b400=_0x289fa9;this[_0x32b400('0x8')]=_0x38ce06;};Migration['prototype'][_0x289fa9('0x9')]=function(_0x4c01df,_0x19100b,_0x2036de){const _0x2ce8ec=_0x289fa9;return this[_0x2ce8ec('0x8')][_0x2ce8ec('0x9')](_0x4c01df,_0x19100b,_0x2036de)[_0x2ce8ec('0x7')](function(){const _0x1a109=_0x2ce8ec;logger[_0x1a109('0x0')](_0x1a109('0x13'),_0x19100b,_0x4c01df);})[_0x2ce8ec('0xb')](function(_0x49f390){const _0x56dba4=_0x2ce8ec;logger[_0x56dba4('0x0')](JSON[_0x56dba4('0xe')](_0x49f390));});},Migration['prototype']['removeColumn']=function(_0x36b678,_0x702e73){const _0x34e663=_0x289fa9;return this[_0x34e663('0x8')][_0x34e663('0xd')](_0x36b678,_0x702e73)[_0x34e663('0x7')](function(){const _0x14d0e5=_0x34e663;logger[_0x14d0e5('0x0')](_0x14d0e5('0x4'),_0x702e73,_0x36b678);})[_0x34e663('0xb')](function(_0x5d6d3c){const _0x1908e9=_0x34e663;logger[_0x1908e9('0x0')](JSON[_0x1908e9('0xe')](_0x5d6d3c));});},Migration[_0x289fa9('0xf')][_0x289fa9('0x15')]=function(_0x2dbe83,_0x28d595,_0x587a2f){const _0x3c457a=_0x289fa9;return this[_0x3c457a('0x8')]['renameColumn'](_0x2dbe83,_0x28d595,_0x587a2f)[_0x3c457a('0x7')](function(){const _0x170695=_0x3c457a;logger[_0x170695('0x0')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x28d595,_0x587a2f,_0x2dbe83);})[_0x3c457a('0xb')](function(_0x6a9292){const _0x1180bf=_0x3c457a;logger[_0x1180bf('0x0')](JSON[_0x1180bf('0xe')](_0x6a9292));});},module[_0x289fa9('0x14')]={'up':function(_0x1ace02,_0x49f646){const _0x45f1f0=_0x289fa9,_0x343336=new Migration(_0x1ace02);_0x343336[_0x45f1f0('0x9')](_0x45f1f0('0x10'),_0x45f1f0('0x12'),{'type':_0x49f646['DATE']}),_0x343336[_0x45f1f0('0x9')](_0x45f1f0('0xa'),_0x45f1f0('0x2'),{'type':_0x49f646[_0x45f1f0('0x1')],'defaultValue':![]}),_0x343336['addColumn']('cm_hopper_final',_0x45f1f0('0x6'),{'type':_0x49f646[_0x45f1f0('0x11')],'defaultValue':null}),_0x343336[_0x45f1f0('0x15')]('cm_hopper_final',_0x45f1f0('0x3'),_0x45f1f0('0x5'));},'down':function(_0x57cd6c,_0x170fc2){const _0x4c9086=_0x289fa9,_0x59a459=new Migration(_0x57cd6c,_0x170fc2);_0x59a459[_0x4c9086('0xd')]('users','phoneBarRingInUse'),_0x59a459[_0x4c9086('0xd')]('cm_hopper_final',_0x4c9086('0x12')),_0x59a459[_0x4c9086('0xd')](_0x4c9086('0x10'),'deleted'),_0x59a459[_0x4c9086('0x15')](_0x4c9086('0x10'),_0x4c9086('0x5'),'reschedule');}}; \ No newline at end of file diff --git a/server/migrations/2.0.14.js b/server/migrations/2.0.14.js index e784958..256be5e 100644 --- a/server/migrations/2.0.14.js +++ b/server/migrations/2.0.14.js @@ -1 +1 @@ -var a893_0xdc55=['exports'];(function(_0x4d7e2e,_0xdc55f9){var _0x364a38=function(_0x1affa8){while(--_0x1affa8){_0x4d7e2e['push'](_0x4d7e2e['shift']());}};_0x364a38(++_0xdc55f9);}(a893_0xdc55,0x10b));var a893_0x364a=function(_0x4d7e2e,_0xdc55f9){_0x4d7e2e=_0x4d7e2e-0x0;var _0x364a38=a893_0xdc55[_0x4d7e2e];return _0x364a38;};var _0x5d6dce=a893_0x364a;'use strict';module[_0x5d6dce('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file +var a893_0x5e2f=['exports'];(function(_0x516864,_0x5e2fe4){var _0x12ac41=function(_0x103dee){while(--_0x103dee){_0x516864['push'](_0x516864['shift']());}};_0x12ac41(++_0x5e2fe4);}(a893_0x5e2f,0x1ed));var a893_0x12ac=function(_0x516864,_0x5e2fe4){_0x516864=_0x516864-0x0;var _0x12ac41=a893_0x5e2f[_0x516864];return _0x12ac41;};var _0x1a80c2=a893_0x12ac;'use strict';module[_0x1a80c2('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.15.js b/server/migrations/2.0.15.js index 5b0b0b7..12143c4 100644 --- a/server/migrations/2.0.15.js +++ b/server/migrations/2.0.15.js @@ -1 +1 @@ -var a894_0x5e44=['exports'];(function(_0x2b3cea,_0x5e442c){var _0x5cd8c5=function(_0x12b842){while(--_0x12b842){_0x2b3cea['push'](_0x2b3cea['shift']());}};_0x5cd8c5(++_0x5e442c);}(a894_0x5e44,0xdc));var a894_0x5cd8=function(_0x2b3cea,_0x5e442c){_0x2b3cea=_0x2b3cea-0x0;var _0x5cd8c5=a894_0x5e44[_0x2b3cea];return _0x5cd8c5;};var _0x33945f=a894_0x5cd8;'use strict';module[_0x33945f('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file +'use strict';module['exports']={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.16.js b/server/migrations/2.0.16.js index 91a834c..6938bfe 100644 --- a/server/migrations/2.0.16.js +++ b/server/migrations/2.0.16.js @@ -1 +1 @@ -var a895_0x1225=['exports'];(function(_0xb49988,_0x12254e){var _0x38523c=function(_0x33ba48){while(--_0x33ba48){_0xb49988['push'](_0xb49988['shift']());}};_0x38523c(++_0x12254e);}(a895_0x1225,0x180));var a895_0x3852=function(_0xb49988,_0x12254e){_0xb49988=_0xb49988-0x0;var _0x38523c=a895_0x1225[_0xb49988];return _0x38523c;};var _0x4a8f98=a895_0x3852;'use strict';module[_0x4a8f98('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file +var a895_0x2844=['exports'];(function(_0x504099,_0x284481){var _0x1b7165=function(_0x179cee){while(--_0x179cee){_0x504099['push'](_0x504099['shift']());}};_0x1b7165(++_0x284481);}(a895_0x2844,0x1b9));var a895_0x1b71=function(_0x504099,_0x284481){_0x504099=_0x504099-0x0;var _0x1b7165=a895_0x2844[_0x504099];return _0x1b7165;};var _0xad6f0b=a895_0x1b71;'use strict';module[_0xad6f0b('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.17.js b/server/migrations/2.0.17.js index 83dd172..d14f016 100644 --- a/server/migrations/2.0.17.js +++ b/server/migrations/2.0.17.js @@ -1 +1 @@ -var a896_0x3e96=['exports'];(function(_0x2c765a,_0x3e9613){var _0x41e5d4=function(_0x94a37e){while(--_0x94a37e){_0x2c765a['push'](_0x2c765a['shift']());}};_0x41e5d4(++_0x3e9613);}(a896_0x3e96,0xb8));var a896_0x41e5=function(_0x2c765a,_0x3e9613){_0x2c765a=_0x2c765a-0x0;var _0x41e5d4=a896_0x3e96[_0x2c765a];return _0x41e5d4;};var _0x16b239=a896_0x41e5;'use strict';module[_0x16b239('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file +var a896_0x42c0=['exports'];(function(_0x372523,_0x42c06f){var _0x3be2d4=function(_0x437db7){while(--_0x437db7){_0x372523['push'](_0x372523['shift']());}};_0x3be2d4(++_0x42c06f);}(a896_0x42c0,0xe0));var a896_0x3be2=function(_0x372523,_0x42c06f){_0x372523=_0x372523-0x0;var _0x3be2d4=a896_0x42c0[_0x372523];return _0x3be2d4;};var _0x5702ce=a896_0x3be2;'use strict';module[_0x5702ce('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.19.js b/server/migrations/2.0.19.js index 187b965..7299c09 100644 --- a/server/migrations/2.0.19.js +++ b/server/migrations/2.0.19.js @@ -1 +1 @@ -var a898_0x2918=['exports'];(function(_0x4d45fd,_0x29181a){var _0x35ccd2=function(_0xddf4e6){while(--_0xddf4e6){_0x4d45fd['push'](_0x4d45fd['shift']());}};_0x35ccd2(++_0x29181a);}(a898_0x2918,0x8e));var a898_0x35cc=function(_0x4d45fd,_0x29181a){_0x4d45fd=_0x4d45fd-0x0;var _0x35ccd2=a898_0x2918[_0x4d45fd];return _0x35ccd2;};var _0x4f1992=a898_0x35cc;'use strict';module[_0x4f1992('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file +var a898_0x1d8d=['exports'];(function(_0xffb2db,_0x1d8dbe){var _0x2fef61=function(_0x12e242){while(--_0x12e242){_0xffb2db['push'](_0xffb2db['shift']());}};_0x2fef61(++_0x1d8dbe);}(a898_0x1d8d,0x13f));var a898_0x2fef=function(_0xffb2db,_0x1d8dbe){_0xffb2db=_0xffb2db-0x0;var _0x2fef61=a898_0x1d8d[_0xffb2db];return _0x2fef61;};var _0x18e222=a898_0x2fef;'use strict';module[_0x18e222('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.20.js b/server/migrations/2.0.20.js index 13e04fe..0cd7138 100644 --- a/server/migrations/2.0.20.js +++ b/server/migrations/2.0.20.js @@ -1 +1 @@ -const a899_0x8370=['then','catch','queryInterface','Added\x20column\x20%s\x20to\x20%s','table\x20dropped\x20%s','Removed\x20column\x20%s\x20from\x20%s','report_jscripty_sessions','prototype','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addColumn','renameColumn','migration','dropTable','removeColumn','report_jscripty_inputs','report_jscripty_questions','exports','../config/logger','info','stringify'];(function(_0x210b88,_0x837052){const _0x24e134=function(_0x1c66d4){while(--_0x1c66d4){_0x210b88['push'](_0x210b88['shift']());}};_0x24e134(++_0x837052);}(a899_0x8370,0x10c));const a899_0x24e1=function(_0x210b88,_0x837052){_0x210b88=_0x210b88-0x0;let _0x24e134=a899_0x8370[_0x210b88];return _0x24e134;};const _0x4d82e7=a899_0x24e1;'use strict';const logger=require(_0x4d82e7('0x9'))(_0x4d82e7('0x3')),Migration=function(_0x1c66d4){const _0x9c8a01=_0x4d82e7;this[_0x9c8a01('0xe')]=_0x1c66d4;};Migration[_0x4d82e7('0x13')][_0x4d82e7('0x1')]=function(_0x188919,_0x449087,_0x58c8cc){const _0x12f001=_0x4d82e7;return this[_0x12f001('0xe')][_0x12f001('0x1')](_0x188919,_0x449087,_0x58c8cc)['then'](function(){const _0x5ecc62=_0x12f001;logger[_0x5ecc62('0xa')](_0x5ecc62('0xf'),_0x449087,_0x188919);})[_0x12f001('0xd')](function(_0xc1aa3){const _0x56e146=_0x12f001;logger[_0x56e146('0xa')](JSON[_0x56e146('0xb')](_0xc1aa3));});},Migration['prototype'][_0x4d82e7('0x5')]=function(_0x2065e5,_0x548e35){const _0x15ffd4=_0x4d82e7;return this['queryInterface']['removeColumn'](_0x2065e5,_0x548e35)[_0x15ffd4('0xc')](function(){const _0x1ec5dd=_0x15ffd4;logger[_0x1ec5dd('0xa')](_0x1ec5dd('0x11'),_0x548e35,_0x2065e5);})['catch'](function(_0x7fea03){const _0x4004b8=_0x15ffd4;logger[_0x4004b8('0xa')](JSON[_0x4004b8('0xb')](_0x7fea03));});},Migration[_0x4d82e7('0x13')]['renameColumn']=function(_0x30d9d8,_0xa28cb9,_0x41ba52){const _0x33bd49=_0x4d82e7;return this[_0x33bd49('0xe')][_0x33bd49('0x2')](_0x30d9d8,_0xa28cb9,_0x41ba52)[_0x33bd49('0xc')](function(){const _0x24856d=_0x33bd49;logger[_0x24856d('0xa')](_0x24856d('0x0'),_0xa28cb9,_0x41ba52,_0x30d9d8);})[_0x33bd49('0xd')](function(_0x3afaff){const _0x112265=_0x33bd49;logger[_0x112265('0xa')](JSON[_0x112265('0xb')](_0x3afaff));});},Migration['prototype'][_0x4d82e7('0x4')]=function(_0x207156){const _0x48f4a7=_0x4d82e7;return this[_0x48f4a7('0xe')][_0x48f4a7('0x4')](_0x207156)[_0x48f4a7('0xc')](function(){const _0x498bd6=_0x48f4a7;logger[_0x498bd6('0xa')](_0x498bd6('0x10'),_0x207156);})[_0x48f4a7('0xd')](function(_0x1eb6e7){const _0x496841=_0x48f4a7;logger['info'](JSON[_0x496841('0xb')](_0x1eb6e7));});},module[_0x4d82e7('0x8')]={'up':function(_0x1dc347){const _0x92650f=_0x4d82e7,_0x48046d=new Migration(_0x1dc347);_0x48046d['dropTable']('jscripty_projects'),_0x48046d[_0x92650f('0x4')](_0x92650f('0x6')),_0x48046d[_0x92650f('0x4')](_0x92650f('0x7')),_0x48046d[_0x92650f('0x4')](_0x92650f('0x12'));},'down':function(){}}; \ No newline at end of file +const a899_0x2ff6=['Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','renameColumn','info','queryInterface','stringify','catch','Added\x20column\x20%s\x20to\x20%s','Removed\x20column\x20%s\x20from\x20%s','table\x20dropped\x20%s','report_jscripty_inputs','dropTable','then','addColumn','removeColumn','prototype','jscripty_projects','report_jscripty_questions'];(function(_0x509d15,_0x2ff66e){const _0x154d0a=function(_0x22a901){while(--_0x22a901){_0x509d15['push'](_0x509d15['shift']());}};_0x154d0a(++_0x2ff66e);}(a899_0x2ff6,0x190));const a899_0x154d=function(_0x509d15,_0x2ff66e){_0x509d15=_0x509d15-0x0;let _0x154d0a=a899_0x2ff6[_0x509d15];return _0x154d0a;};const _0x515767=a899_0x154d;'use strict';const logger=require('../config/logger')('migration'),Migration=function(_0x22a901){const _0x26a28b=a899_0x154d;this[_0x26a28b('0xb')]=_0x22a901;};Migration[_0x515767('0x5')][_0x515767('0x3')]=function(_0x39119c,_0x3df93a,_0x6acd70){const _0x3c928b=_0x515767;return this['queryInterface']['addColumn'](_0x39119c,_0x3df93a,_0x6acd70)['then'](function(){const _0x239018=a899_0x154d;logger[_0x239018('0xa')](_0x239018('0xe'),_0x3df93a,_0x39119c);})[_0x3c928b('0xd')](function(_0x3f939f){logger['info'](JSON['stringify'](_0x3f939f));});},Migration[_0x515767('0x5')][_0x515767('0x4')]=function(_0x30bfc8,_0x10cb48){const _0x401a36=_0x515767;return this[_0x401a36('0xb')][_0x401a36('0x4')](_0x30bfc8,_0x10cb48)[_0x401a36('0x2')](function(){const _0x521b22=_0x401a36;logger[_0x521b22('0xa')](_0x521b22('0xf'),_0x10cb48,_0x30bfc8);})['catch'](function(_0x26c3bb){const _0x5b2ebf=_0x401a36;logger[_0x5b2ebf('0xa')](JSON['stringify'](_0x26c3bb));});},Migration['prototype'][_0x515767('0x9')]=function(_0x15fc0a,_0x1ea545,_0x269523){const _0x1dee1b=_0x515767;return this[_0x1dee1b('0xb')]['renameColumn'](_0x15fc0a,_0x1ea545,_0x269523)[_0x1dee1b('0x2')](function(){const _0x1568f5=_0x1dee1b;logger[_0x1568f5('0xa')](_0x1568f5('0x8'),_0x1ea545,_0x269523,_0x15fc0a);})[_0x1dee1b('0xd')](function(_0x3c91aa){const _0x39ed60=_0x1dee1b;logger[_0x39ed60('0xa')](JSON[_0x39ed60('0xc')](_0x3c91aa));});},Migration[_0x515767('0x5')][_0x515767('0x1')]=function(_0x2f0de3){const _0x4aa903=_0x515767;return this['queryInterface'][_0x4aa903('0x1')](_0x2f0de3)[_0x4aa903('0x2')](function(){const _0x120e7c=_0x4aa903;logger['info'](_0x120e7c('0x10'),_0x2f0de3);})['catch'](function(_0x4c98b5){const _0x5bcb01=_0x4aa903;logger[_0x5bcb01('0xa')](JSON[_0x5bcb01('0xc')](_0x4c98b5));});},module['exports']={'up':function(_0x25084e){const _0x5ab0ef=_0x515767,_0x153dff=new Migration(_0x25084e);_0x153dff[_0x5ab0ef('0x1')](_0x5ab0ef('0x6')),_0x153dff[_0x5ab0ef('0x1')](_0x5ab0ef('0x0')),_0x153dff[_0x5ab0ef('0x1')](_0x5ab0ef('0x7')),_0x153dff[_0x5ab0ef('0x1')]('report_jscripty_sessions');},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.21.js b/server/migrations/2.0.21.js index e4918da..470ca00 100644 --- a/server/migrations/2.0.21.js +++ b/server/migrations/2.0.21.js @@ -1 +1 @@ -const a900_0x1c7c=['prototype','then','table\x20dropped\x20%s','queryInterface','report_jscripty_sessions','Removed\x20column\x20%s\x20from\x20%s','../config/logger','report_jscripty_inputs','jscripty_projects','catch','dropTable','report_jscripty_questions','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','renameColumn','stringify','addColumn','migration','removeColumn','info'];(function(_0x39e6fb,_0x1c7c9f){const _0x25eec8=function(_0x510cc5){while(--_0x510cc5){_0x39e6fb['push'](_0x39e6fb['shift']());}};_0x25eec8(++_0x1c7c9f);}(a900_0x1c7c,0xaf));const a900_0x25ee=function(_0x39e6fb,_0x1c7c9f){_0x39e6fb=_0x39e6fb-0x0;let _0x25eec8=a900_0x1c7c[_0x39e6fb];return _0x25eec8;};const _0x43e84d=a900_0x25ee;'use strict';const logger=require(_0x43e84d('0x2'))(_0x43e84d('0xc')),Migration=function(_0x510cc5){const _0x23f0e9=_0x43e84d;this[_0x23f0e9('0x12')]=_0x510cc5;};Migration['prototype'][_0x43e84d('0xb')]=function(_0x53b49b,_0x3ba556,_0x3bd012){const _0x3a4b4b=_0x43e84d;return this[_0x3a4b4b('0x12')][_0x3a4b4b('0xb')](_0x53b49b,_0x3ba556,_0x3bd012)[_0x3a4b4b('0x10')](function(){const _0x3839d7=_0x3a4b4b;logger[_0x3839d7('0xe')]('Added\x20column\x20%s\x20to\x20%s',_0x3ba556,_0x53b49b);})[_0x3a4b4b('0x5')](function(_0x2facdd){const _0x5c6a6c=_0x3a4b4b;logger[_0x5c6a6c('0xe')](JSON[_0x5c6a6c('0xa')](_0x2facdd));});},Migration[_0x43e84d('0xf')][_0x43e84d('0xd')]=function(_0x3484c4,_0x25768a){const _0xd5a69=_0x43e84d;return this[_0xd5a69('0x12')]['removeColumn'](_0x3484c4,_0x25768a)[_0xd5a69('0x10')](function(){const _0x3017ee=_0xd5a69;logger[_0x3017ee('0xe')](_0x3017ee('0x1'),_0x25768a,_0x3484c4);})['catch'](function(_0x1a4f78){const _0x3e1c5e=_0xd5a69;logger['info'](JSON[_0x3e1c5e('0xa')](_0x1a4f78));});},Migration[_0x43e84d('0xf')][_0x43e84d('0x9')]=function(_0x9d159b,_0x3bb345,_0x3b172b){const _0x59c6f4=_0x43e84d;return this[_0x59c6f4('0x12')]['renameColumn'](_0x9d159b,_0x3bb345,_0x3b172b)[_0x59c6f4('0x10')](function(){const _0x45d1a7=_0x59c6f4;logger['info'](_0x45d1a7('0x8'),_0x3bb345,_0x3b172b,_0x9d159b);})[_0x59c6f4('0x5')](function(_0x3852c2){const _0x1ba58c=_0x59c6f4;logger[_0x1ba58c('0xe')](JSON[_0x1ba58c('0xa')](_0x3852c2));});},Migration[_0x43e84d('0xf')][_0x43e84d('0x6')]=function(_0x102d1f){const _0x4a2123=_0x43e84d;return this[_0x4a2123('0x12')]['dropTable'](_0x102d1f)[_0x4a2123('0x10')](function(){const _0x10255a=_0x4a2123;logger[_0x10255a('0xe')](_0x10255a('0x11'),_0x102d1f);})[_0x4a2123('0x5')](function(_0x39b37a){const _0x46d289=_0x4a2123;logger[_0x46d289('0xe')](JSON[_0x46d289('0xa')](_0x39b37a));});},module['exports']={'up':function(_0x2aa291){const _0x4e7499=_0x43e84d,_0x544598=new Migration(_0x2aa291);_0x544598['dropTable'](_0x4e7499('0x4'),{'force':!![]}),_0x544598[_0x4e7499('0x6')](_0x4e7499('0x3'),{'force':!![]}),_0x544598['dropTable'](_0x4e7499('0x7'),{'force':!![]}),_0x544598[_0x4e7499('0x6')](_0x4e7499('0x0'),{'force':!![]});},'down':function(){}}; \ No newline at end of file +const a900_0x5dd3=['removeColumn','catch','then','addColumn','stringify','renameColumn','prototype','dropTable','table\x20dropped\x20%s','info','queryInterface','report_jscripty_questions','Removed\x20column\x20%s\x20from\x20%s','exports','jscripty_projects','Added\x20column\x20%s\x20to\x20%s','report_jscripty_inputs'];(function(_0x667a8,_0x5dd39a){const _0x3e8991=function(_0x483348){while(--_0x483348){_0x667a8['push'](_0x667a8['shift']());}};_0x3e8991(++_0x5dd39a);}(a900_0x5dd3,0x19e));const a900_0x3e89=function(_0x667a8,_0x5dd39a){_0x667a8=_0x667a8-0x0;let _0x3e8991=a900_0x5dd3[_0x667a8];return _0x3e8991;};const _0xc92c1a=a900_0x3e89;'use strict';const logger=require('../config/logger')('migration'),Migration=function(_0x483348){this['queryInterface']=_0x483348;};Migration[_0xc92c1a('0x0')]['addColumn']=function(_0x1fb7eb,_0x5d32b5,_0x3b0c4b){const _0x350250=_0xc92c1a;return this['queryInterface'][_0x350250('0xe')](_0x1fb7eb,_0x5d32b5,_0x3b0c4b)[_0x350250('0xd')](function(){const _0x31c33c=_0x350250;logger[_0x31c33c('0x3')](_0x31c33c('0x9'),_0x5d32b5,_0x1fb7eb);})[_0x350250('0xc')](function(_0x32a7b0){const _0x3eb7a2=_0x350250;logger[_0x3eb7a2('0x3')](JSON[_0x3eb7a2('0xf')](_0x32a7b0));});},Migration[_0xc92c1a('0x0')][_0xc92c1a('0xb')]=function(_0x49a002,_0x33e9dc){const _0x133d92=_0xc92c1a;return this['queryInterface']['removeColumn'](_0x49a002,_0x33e9dc)[_0x133d92('0xd')](function(){const _0x657fcb=_0x133d92;logger['info'](_0x657fcb('0x6'),_0x33e9dc,_0x49a002);})['catch'](function(_0x3a2e86){const _0x2062e0=_0x133d92;logger[_0x2062e0('0x3')](JSON[_0x2062e0('0xf')](_0x3a2e86));});},Migration[_0xc92c1a('0x0')][_0xc92c1a('0x10')]=function(_0x26252b,_0x98ac3b,_0x2a9ab6){const _0x4a1d0c=_0xc92c1a;return this[_0x4a1d0c('0x4')][_0x4a1d0c('0x10')](_0x26252b,_0x98ac3b,_0x2a9ab6)[_0x4a1d0c('0xd')](function(){const _0x46e146=_0x4a1d0c;logger[_0x46e146('0x3')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x98ac3b,_0x2a9ab6,_0x26252b);})[_0x4a1d0c('0xc')](function(_0x1af54a){const _0x1f45a5=_0x4a1d0c;logger[_0x1f45a5('0x3')](JSON['stringify'](_0x1af54a));});},Migration[_0xc92c1a('0x0')][_0xc92c1a('0x1')]=function(_0x50bca6){const _0x3b23b9=_0xc92c1a;return this[_0x3b23b9('0x4')]['dropTable'](_0x50bca6)[_0x3b23b9('0xd')](function(){const _0x607ddc=_0x3b23b9;logger[_0x607ddc('0x3')](_0x607ddc('0x2'),_0x50bca6);})[_0x3b23b9('0xc')](function(_0x4f0544){const _0x3a1e97=_0x3b23b9;logger['info'](JSON[_0x3a1e97('0xf')](_0x4f0544));});},module[_0xc92c1a('0x7')]={'up':function(_0x3ea0f0){const _0x548f11=_0xc92c1a,_0x9f3649=new Migration(_0x3ea0f0);_0x9f3649[_0x548f11('0x1')](_0x548f11('0x8'),{'force':!![]}),_0x9f3649[_0x548f11('0x1')](_0x548f11('0xa'),{'force':!![]}),_0x9f3649[_0x548f11('0x1')](_0x548f11('0x5'),{'force':!![]}),_0x9f3649[_0x548f11('0x1')]('report_jscripty_sessions',{'force':!![]});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.22.js b/server/migrations/2.0.22.js index 5b7cf34..40521af 100644 --- a/server/migrations/2.0.22.js +++ b/server/migrations/2.0.22.js @@ -1 +1 @@ -const a901_0x1fd6=['then','Removed\x20column\x20%s\x20from\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','queryInterface','dropTable','info','stringify','../config/logger','prototype','table\x20dropped\x20%s','catch','migration','report_jscripty_questions','report_jscripty_answers','exports','addColumn','renameColumn','removeColumn'];(function(_0x5aaa3f,_0x1fd6e1){const _0x467318=function(_0x1b6e66){while(--_0x1b6e66){_0x5aaa3f['push'](_0x5aaa3f['shift']());}};_0x467318(++_0x1fd6e1);}(a901_0x1fd6,0xd5));const a901_0x4673=function(_0x5aaa3f,_0x1fd6e1){_0x5aaa3f=_0x5aaa3f-0x0;let _0x467318=a901_0x1fd6[_0x5aaa3f];return _0x467318;};const _0x4d1052=a901_0x4673;'use strict';const logger=require(_0x4d1052('0xa'))(_0x4d1052('0xe')),Migration=function(_0x1b6e66){const _0x183d99=_0x4d1052;this[_0x183d99('0x6')]=_0x1b6e66;};Migration[_0x4d1052('0xb')][_0x4d1052('0x0')]=function(_0x84e422,_0x57a63b,_0x6439b){const _0x40495d=_0x4d1052;return this[_0x40495d('0x6')][_0x40495d('0x0')](_0x84e422,_0x57a63b,_0x6439b)[_0x40495d('0x3')](function(){const _0xae7b8e=_0x40495d;logger[_0xae7b8e('0x8')]('Added\x20column\x20%s\x20to\x20%s',_0x57a63b,_0x84e422);})['catch'](function(_0x4f0462){const _0x323ebd=_0x40495d;logger[_0x323ebd('0x8')](JSON[_0x323ebd('0x9')](_0x4f0462));});},Migration[_0x4d1052('0xb')]['removeColumn']=function(_0x3704bc,_0x8b7d2f){const _0x634fa4=_0x4d1052;return this[_0x634fa4('0x6')][_0x634fa4('0x2')](_0x3704bc,_0x8b7d2f)[_0x634fa4('0x3')](function(){const _0x250843=_0x634fa4;logger[_0x250843('0x8')](_0x250843('0x4'),_0x8b7d2f,_0x3704bc);})[_0x634fa4('0xd')](function(_0x9b5c14){const _0x4cd6b9=_0x634fa4;logger['info'](JSON[_0x4cd6b9('0x9')](_0x9b5c14));});},Migration[_0x4d1052('0xb')][_0x4d1052('0x1')]=function(_0x17bc16,_0x5ad506,_0x598874){const _0x30fd8e=_0x4d1052;return this[_0x30fd8e('0x6')][_0x30fd8e('0x1')](_0x17bc16,_0x5ad506,_0x598874)[_0x30fd8e('0x3')](function(){const _0x4b6d89=_0x30fd8e;logger['info'](_0x4b6d89('0x5'),_0x5ad506,_0x598874,_0x17bc16);})[_0x30fd8e('0xd')](function(_0xadd372){const _0x2a6523=_0x30fd8e;logger[_0x2a6523('0x8')](JSON[_0x2a6523('0x9')](_0xadd372));});},Migration[_0x4d1052('0xb')][_0x4d1052('0x7')]=function(_0x439a79){const _0x3c10c9=_0x4d1052;return this['queryInterface'][_0x3c10c9('0x7')](_0x439a79)[_0x3c10c9('0x3')](function(){const _0x1856d8=_0x3c10c9;logger['info'](_0x1856d8('0xc'),_0x439a79);})['catch'](function(_0xb54da4){const _0x35b4e4=_0x3c10c9;logger[_0x35b4e4('0x8')](JSON['stringify'](_0xb54da4));});},module[_0x4d1052('0x11')]={'up':function(_0x10ed31){const _0x606e34=_0x4d1052,_0x5e94ec=new Migration(_0x10ed31);_0x5e94ec[_0x606e34('0x7')](_0x606e34('0x10'),{'force':!![]}),_0x5e94ec[_0x606e34('0x7')](_0x606e34('0xf'),{'force':!![]}),_0x5e94ec[_0x606e34('0x7')]('report_jscripty_sessions',{'force':!![]});},'down':function(){}}; \ No newline at end of file +const a901_0x3816=['removeColumn','../config/logger','stringify','report_jscripty_sessions','info','table\x20dropped\x20%s','then','Removed\x20column\x20%s\x20from\x20%s','dropTable','queryInterface','renameColumn','prototype','report_jscripty_questions','report_jscripty_answers','exports','addColumn','catch'];(function(_0x1237b8,_0x381662){const _0x58eadb=function(_0x5491a2){while(--_0x5491a2){_0x1237b8['push'](_0x1237b8['shift']());}};_0x58eadb(++_0x381662);}(a901_0x3816,0x15d));const a901_0x58ea=function(_0x1237b8,_0x381662){_0x1237b8=_0x1237b8-0x0;let _0x58eadb=a901_0x3816[_0x1237b8];return _0x58eadb;};const _0x5a1401=a901_0x58ea;'use strict';const logger=require(_0x5a1401('0x9'))('migration'),Migration=function(_0x5491a2){const _0x54571f=_0x5a1401;this[_0x54571f('0x0')]=_0x5491a2;};Migration[_0x5a1401('0x2')]['addColumn']=function(_0x2ff118,_0x1b3d6f,_0x579867){const _0x2985ad=_0x5a1401;return this['queryInterface'][_0x2985ad('0x6')](_0x2ff118,_0x1b3d6f,_0x579867)[_0x2985ad('0xe')](function(){const _0x288832=_0x2985ad;logger[_0x288832('0xc')]('Added\x20column\x20%s\x20to\x20%s',_0x1b3d6f,_0x2ff118);})[_0x2985ad('0x7')](function(_0x928d9f){const _0x291386=_0x2985ad;logger[_0x291386('0xc')](JSON['stringify'](_0x928d9f));});},Migration[_0x5a1401('0x2')]['removeColumn']=function(_0x515456,_0x32a314){const _0x5ce533=_0x5a1401;return this[_0x5ce533('0x0')][_0x5ce533('0x8')](_0x515456,_0x32a314)[_0x5ce533('0xe')](function(){const _0x2fc059=_0x5ce533;logger[_0x2fc059('0xc')](_0x2fc059('0xf'),_0x32a314,_0x515456);})['catch'](function(_0x497c55){const _0x1359ee=_0x5ce533;logger[_0x1359ee('0xc')](JSON['stringify'](_0x497c55));});},Migration[_0x5a1401('0x2')][_0x5a1401('0x1')]=function(_0x426624,_0x389b98,_0x533ace){const _0x5dc0dd=_0x5a1401;return this[_0x5dc0dd('0x0')][_0x5dc0dd('0x1')](_0x426624,_0x389b98,_0x533ace)[_0x5dc0dd('0xe')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x389b98,_0x533ace,_0x426624);})[_0x5dc0dd('0x7')](function(_0x385bc5){const _0xf62a20=_0x5dc0dd;logger['info'](JSON[_0xf62a20('0xa')](_0x385bc5));});},Migration[_0x5a1401('0x2')][_0x5a1401('0x10')]=function(_0x27940d){const _0x4d61f4=_0x5a1401;return this[_0x4d61f4('0x0')][_0x4d61f4('0x10')](_0x27940d)['then'](function(){const _0x30f47f=_0x4d61f4;logger['info'](_0x30f47f('0xd'),_0x27940d);})[_0x4d61f4('0x7')](function(_0x56ba64){logger['info'](JSON['stringify'](_0x56ba64));});},module[_0x5a1401('0x5')]={'up':function(_0x4ec0a9){const _0x4e8080=_0x5a1401,_0x584a32=new Migration(_0x4ec0a9);_0x584a32[_0x4e8080('0x10')](_0x4e8080('0x4'),{'force':!![]}),_0x584a32[_0x4e8080('0x10')](_0x4e8080('0x3'),{'force':!![]}),_0x584a32[_0x4e8080('0x10')](_0x4e8080('0xb'),{'force':!![]});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.23.js b/server/migrations/2.0.23.js index 6a747f5..e27e075 100644 --- a/server/migrations/2.0.23.js +++ b/server/migrations/2.0.23.js @@ -1 +1 @@ -const a902_0x3ee9=['addColumn','int_zendesk_accounts','stringify','prototype','openchannel_messages','renameColumn','Removed\x20column\x20%s\x20from\x20%s','exports','ENUM','openchannel_accounts','type','then','newTab','user_has_openchannel_rooms','dropTable','removeColumn','info','queryInterface','catch','integrationTab','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','table\x20dropped\x20%s'];(function(_0x47e709,_0x3ee90b){const _0x2b89bf=function(_0x4a6b6c){while(--_0x4a6b6c){_0x47e709['push'](_0x47e709['shift']());}};_0x2b89bf(++_0x3ee90b);}(a902_0x3ee9,0x65));const a902_0x2b89=function(_0x47e709,_0x3ee90b){_0x47e709=_0x47e709-0x0;let _0x2b89bf=a902_0x3ee9[_0x47e709];return _0x2b89bf;};const _0xa95116=a902_0x2b89;'use strict';const logger=require('../config/logger')('migration'),Migration=function(_0x4a6b6c){const _0x576b78=a902_0x2b89;this[_0x576b78('0x4')]=_0x4a6b6c;};Migration['prototype'][_0xa95116('0x9')]=function(_0x4243db,_0x548adb,_0x248c14){const _0xa1ddd6=_0xa95116;return this['queryInterface']['addColumn'](_0x4243db,_0x548adb,_0x248c14)['then'](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x548adb,_0x4243db);})[_0xa1ddd6('0x5')](function(_0x135040){const _0x19c789=_0xa1ddd6;logger[_0x19c789('0x3')](JSON[_0x19c789('0xb')](_0x135040));});},Migration['prototype'][_0xa95116('0x2')]=function(_0x2b5a78,_0x5a829e){const _0x49d914=_0xa95116;return this[_0x49d914('0x4')]['removeColumn'](_0x2b5a78,_0x5a829e)['then'](function(){const _0x2c7405=_0x49d914;logger[_0x2c7405('0x3')](_0x2c7405('0xf'),_0x5a829e,_0x2b5a78);})['catch'](function(_0x1b805e){const _0x596e9d=_0x49d914;logger['info'](JSON[_0x596e9d('0xb')](_0x1b805e));});},Migration['prototype']['renameColumn']=function(_0xb97bda,_0x3ec5d8,_0x1fd9f2){const _0x59c7f2=_0xa95116;return this[_0x59c7f2('0x4')][_0x59c7f2('0xe')](_0xb97bda,_0x3ec5d8,_0x1fd9f2)[_0x59c7f2('0x14')](function(){const _0x3bf068=_0x59c7f2;logger[_0x3bf068('0x3')](_0x3bf068('0x7'),_0x3ec5d8,_0x1fd9f2,_0xb97bda);})['catch'](function(_0x3a3fcd){logger['info'](JSON['stringify'](_0x3a3fcd));});},Migration[_0xa95116('0xc')][_0xa95116('0x1')]=function(_0x5c755b){const _0x248588=_0xa95116;return this['queryInterface']['dropTable'](_0x5c755b)[_0x248588('0x14')](function(){const _0x46bc28=_0x248588;logger[_0x46bc28('0x3')](_0x46bc28('0x8'),_0x5c755b);})['catch'](function(_0x11e3e3){const _0x2f8039=_0x248588;logger[_0x2f8039('0x3')](JSON[_0x2f8039('0xb')](_0x11e3e3));});},module[_0xa95116('0x10')]={'up':function(_0x300946,_0xdde8d2){const _0x754e85=_0xa95116,_0x6eee2c=new Migration(_0x300946);_0x6eee2c[_0x754e85('0x9')]('int_salesforce_accounts',_0x754e85('0x13'),{'type':_0xdde8d2['ENUM'](_0x754e85('0x6'),_0x754e85('0x15')),'defaultValue':_0x754e85('0x6')}),_0x6eee2c[_0x754e85('0x9')](_0x754e85('0xa'),'type',{'type':_0xdde8d2[_0x754e85('0x11')]('integrationTab',_0x754e85('0x15')),'defaultValue':_0x754e85('0x6')}),_0x6eee2c['dropTable'](_0x754e85('0x0'),{'force':!![]}),_0x6eee2c[_0x754e85('0x1')](_0x754e85('0xd'),{'force':!![]}),_0x6eee2c['dropTable']('openchannel_rooms',{'force':!![]}),_0x6eee2c[_0x754e85('0x1')]('openchannel_applications',{'force':!![]}),_0x6eee2c[_0x754e85('0x1')](_0x754e85('0x12'),{'force':!![]});},'down':function(_0x3c0772){const _0x4f6397=_0xa95116,_0x5c8275=new Migration(_0x3c0772);_0x5c8275[_0x4f6397('0x2')]('int_salesforce_accounts',_0x4f6397('0x13')),_0x5c8275['removeColumn'](_0x4f6397('0xa'),_0x4f6397('0x13'));}}; \ No newline at end of file +const a902_0x2765=['migration','renameColumn','newTab','ENUM','int_salesforce_accounts','openchannel_applications','type','dropTable','info','exports','prototype','integrationTab','addColumn','stringify','catch','int_zendesk_accounts','openchannel_messages','then','openchannel_accounts','../config/logger','removeColumn','table\x20dropped\x20%s','queryInterface','Removed\x20column\x20%s\x20from\x20%s'];(function(_0x46f670,_0x27650f){const _0x1fad70=function(_0x516de0){while(--_0x516de0){_0x46f670['push'](_0x46f670['shift']());}};_0x1fad70(++_0x27650f);}(a902_0x2765,0x1c2));const a902_0x1fad=function(_0x46f670,_0x27650f){_0x46f670=_0x46f670-0x0;let _0x1fad70=a902_0x2765[_0x46f670];return _0x1fad70;};const _0x332714=a902_0x1fad;'use strict';const logger=require(_0x332714('0x1'))(_0x332714('0x6')),Migration=function(_0x516de0){const _0x2c715c=_0x332714;this[_0x2c715c('0x4')]=_0x516de0;};Migration[_0x332714('0x10')][_0x332714('0x12')]=function(_0xd1a6d7,_0x42374e,_0x46ddc8){const _0x5b05db=_0x332714;return this[_0x5b05db('0x4')][_0x5b05db('0x12')](_0xd1a6d7,_0x42374e,_0x46ddc8)[_0x5b05db('0x17')](function(){const _0x2abc1e=_0x5b05db;logger[_0x2abc1e('0xe')]('Added\x20column\x20%s\x20to\x20%s',_0x42374e,_0xd1a6d7);})[_0x5b05db('0x14')](function(_0x458759){const _0x5749fe=_0x5b05db;logger[_0x5749fe('0xe')](JSON[_0x5749fe('0x13')](_0x458759));});},Migration[_0x332714('0x10')][_0x332714('0x2')]=function(_0xa81a18,_0x2c6381){const _0x34b2dd=_0x332714;return this['queryInterface']['removeColumn'](_0xa81a18,_0x2c6381)[_0x34b2dd('0x17')](function(){const _0x43b427=_0x34b2dd;logger[_0x43b427('0xe')](_0x43b427('0x5'),_0x2c6381,_0xa81a18);})[_0x34b2dd('0x14')](function(_0x20589f){const _0x4b1f96=_0x34b2dd;logger[_0x4b1f96('0xe')](JSON[_0x4b1f96('0x13')](_0x20589f));});},Migration[_0x332714('0x10')][_0x332714('0x7')]=function(_0x39d997,_0x43b7d4,_0x26c8ca){const _0x410f97=_0x332714;return this['queryInterface'][_0x410f97('0x7')](_0x39d997,_0x43b7d4,_0x26c8ca)['then'](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x43b7d4,_0x26c8ca,_0x39d997);})[_0x410f97('0x14')](function(_0x1b73d3){const _0x37978a=_0x410f97;logger[_0x37978a('0xe')](JSON['stringify'](_0x1b73d3));});},Migration[_0x332714('0x10')][_0x332714('0xd')]=function(_0x47fff2){const _0x5f4a7b=_0x332714;return this['queryInterface'][_0x5f4a7b('0xd')](_0x47fff2)[_0x5f4a7b('0x17')](function(){const _0x125e85=_0x5f4a7b;logger['info'](_0x125e85('0x3'),_0x47fff2);})['catch'](function(_0x3ad629){logger['info'](JSON['stringify'](_0x3ad629));});},module[_0x332714('0xf')]={'up':function(_0x14c4a8,_0x29729e){const _0x122345=_0x332714,_0x1145a0=new Migration(_0x14c4a8);_0x1145a0[_0x122345('0x12')]('int_salesforce_accounts',_0x122345('0xc'),{'type':_0x29729e[_0x122345('0x9')](_0x122345('0x11'),_0x122345('0x8')),'defaultValue':_0x122345('0x11')}),_0x1145a0[_0x122345('0x12')](_0x122345('0x15'),_0x122345('0xc'),{'type':_0x29729e[_0x122345('0x9')]('integrationTab',_0x122345('0x8')),'defaultValue':_0x122345('0x11')}),_0x1145a0[_0x122345('0xd')]('user_has_openchannel_rooms',{'force':!![]}),_0x1145a0[_0x122345('0xd')](_0x122345('0x16'),{'force':!![]}),_0x1145a0[_0x122345('0xd')]('openchannel_rooms',{'force':!![]}),_0x1145a0[_0x122345('0xd')](_0x122345('0xb'),{'force':!![]}),_0x1145a0['dropTable'](_0x122345('0x0'),{'force':!![]});},'down':function(_0x4f0b91){const _0x36b28f=_0x332714,_0x600783=new Migration(_0x4f0b91);_0x600783[_0x36b28f('0x2')](_0x36b28f('0xa'),'type'),_0x600783[_0x36b28f('0x2')](_0x36b28f('0x15'),_0x36b28f('0xc'));}}; \ No newline at end of file diff --git a/server/migrations/2.0.24.js b/server/migrations/2.0.24.js index 9782cd8..8055bae 100644 --- a/server/migrations/2.0.24.js +++ b/server/migrations/2.0.24.js @@ -1 +1 @@ -const a903_0x80c9=['prototype','Added\x20column\x20%s\x20to\x20%s','info','queryInterface','renameColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','exports','../config/logger','catch','stringify','addColumn','removeColumn','dropTable','Removed\x20column\x20%s\x20from\x20%s','then'];(function(_0x516a56,_0x80c915){const _0x342079=function(_0xc1b523){while(--_0xc1b523){_0x516a56['push'](_0x516a56['shift']());}};_0x342079(++_0x80c915);}(a903_0x80c9,0xb1));const a903_0x3420=function(_0x516a56,_0x80c915){_0x516a56=_0x516a56-0x0;let _0x342079=a903_0x80c9[_0x516a56];return _0x342079;};const _0x2f8f80=a903_0x3420;'use strict';const logger=require(_0x2f8f80('0xa'))('migration'),Migration=function(_0xc1b523){this['queryInterface']=_0xc1b523;};Migration[_0x2f8f80('0x3')][_0x2f8f80('0xd')]=function(_0x38cf73,_0x192c1b,_0x44eb3b){const _0x260955=_0x2f8f80;return this[_0x260955('0x6')][_0x260955('0xd')](_0x38cf73,_0x192c1b,_0x44eb3b)[_0x260955('0x2')](function(){const _0x239b95=_0x260955;logger[_0x239b95('0x5')](_0x239b95('0x4'),_0x192c1b,_0x38cf73);})['catch'](function(_0x32c68e){const _0x3a8459=_0x260955;logger[_0x3a8459('0x5')](JSON[_0x3a8459('0xc')](_0x32c68e));});},Migration[_0x2f8f80('0x3')][_0x2f8f80('0xe')]=function(_0x58ee2d,_0x3da8d6){const _0x10eaa3=_0x2f8f80;return this[_0x10eaa3('0x6')][_0x10eaa3('0xe')](_0x58ee2d,_0x3da8d6)[_0x10eaa3('0x2')](function(){const _0x5e0b7c=_0x10eaa3;logger[_0x5e0b7c('0x5')](_0x5e0b7c('0x1'),_0x3da8d6,_0x58ee2d);})[_0x10eaa3('0xb')](function(_0x1f8645){const _0x4b3ce0=_0x10eaa3;logger[_0x4b3ce0('0x5')](JSON[_0x4b3ce0('0xc')](_0x1f8645));});},Migration[_0x2f8f80('0x3')]['renameColumn']=function(_0x29f627,_0x2a752d,_0x11547e){const _0x57e310=_0x2f8f80;return this[_0x57e310('0x6')][_0x57e310('0x7')](_0x29f627,_0x2a752d,_0x11547e)[_0x57e310('0x2')](function(){const _0x12fc84=_0x57e310;logger['info'](_0x12fc84('0x8'),_0x2a752d,_0x11547e,_0x29f627);})['catch'](function(_0x15636f){const _0x18ac66=_0x57e310;logger[_0x18ac66('0x5')](JSON[_0x18ac66('0xc')](_0x15636f));});},Migration[_0x2f8f80('0x3')][_0x2f8f80('0x0')]=function(_0x4caa8b){const _0x1ebe57=_0x2f8f80;return this[_0x1ebe57('0x6')][_0x1ebe57('0x0')](_0x4caa8b)[_0x1ebe57('0x2')](function(){const _0x3d79e7=_0x1ebe57;logger[_0x3d79e7('0x5')]('table\x20dropped\x20%s',_0x4caa8b);})['catch'](function(_0x39d31b){logger['info'](JSON['stringify'](_0x39d31b));});},module[_0x2f8f80('0x9')]={'up':function(_0x47532b){const _0xc940db=new Migration(_0x47532b);_0xc940db['dropTable']('tools_schedules',{'force':!![]});},'down':function(){}}; \ No newline at end of file +const a903_0x57b7=['then','removeColumn','dropTable','addColumn','table\x20dropped\x20%s','stringify','prototype','catch','renameColumn','exports','Removed\x20column\x20%s\x20from\x20%s','tools_schedules','queryInterface','../config/logger','info'];(function(_0x154bcc,_0x57b7e3){const _0x4bcde0=function(_0x169012){while(--_0x169012){_0x154bcc['push'](_0x154bcc['shift']());}};_0x4bcde0(++_0x57b7e3);}(a903_0x57b7,0x11b));const a903_0x4bcd=function(_0x154bcc,_0x57b7e3){_0x154bcc=_0x154bcc-0x0;let _0x4bcde0=a903_0x57b7[_0x154bcc];return _0x4bcde0;};const _0x412e35=a903_0x4bcd;'use strict';const logger=require(_0x412e35('0x0'))('migration'),Migration=function(_0x169012){const _0x4ce319=_0x412e35;this[_0x4ce319('0xe')]=_0x169012;};Migration['prototype'][_0x412e35('0x5')]=function(_0x47c0dd,_0x44f63b,_0x532230){const _0x37d054=_0x412e35;return this[_0x37d054('0xe')][_0x37d054('0x5')](_0x47c0dd,_0x44f63b,_0x532230)[_0x37d054('0x2')](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x44f63b,_0x47c0dd);})[_0x37d054('0x9')](function(_0x5dafcf){const _0x49ade4=_0x37d054;logger[_0x49ade4('0x1')](JSON[_0x49ade4('0x7')](_0x5dafcf));});},Migration['prototype']['removeColumn']=function(_0x56d79a,_0x11130c){const _0x2cf2ea=_0x412e35;return this[_0x2cf2ea('0xe')][_0x2cf2ea('0x3')](_0x56d79a,_0x11130c)['then'](function(){const _0x46d6bb=_0x2cf2ea;logger[_0x46d6bb('0x1')](_0x46d6bb('0xc'),_0x11130c,_0x56d79a);})['catch'](function(_0x44b59b){const _0x28844a=_0x2cf2ea;logger[_0x28844a('0x1')](JSON[_0x28844a('0x7')](_0x44b59b));});},Migration['prototype'][_0x412e35('0xa')]=function(_0x1c9d12,_0x36719b,_0x4946f9){const _0x4c0851=_0x412e35;return this[_0x4c0851('0xe')]['renameColumn'](_0x1c9d12,_0x36719b,_0x4946f9)[_0x4c0851('0x2')](function(){const _0x3277da=_0x4c0851;logger[_0x3277da('0x1')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x36719b,_0x4946f9,_0x1c9d12);})[_0x4c0851('0x9')](function(_0x5eee92){const _0x57a491=_0x4c0851;logger[_0x57a491('0x1')](JSON[_0x57a491('0x7')](_0x5eee92));});},Migration[_0x412e35('0x8')][_0x412e35('0x4')]=function(_0xdb45cc){const _0x41c7f1=_0x412e35;return this[_0x41c7f1('0xe')][_0x41c7f1('0x4')](_0xdb45cc)['then'](function(){const _0x27f041=_0x41c7f1;logger['info'](_0x27f041('0x6'),_0xdb45cc);})[_0x41c7f1('0x9')](function(_0x506eb7){const _0x4589ed=_0x41c7f1;logger[_0x4589ed('0x1')](JSON[_0x4589ed('0x7')](_0x506eb7));});},module[_0x412e35('0xb')]={'up':function(_0x170e77){const _0x76a056=_0x412e35,_0x56d974=new Migration(_0x170e77);_0x56d974[_0x76a056('0x4')](_0x76a056('0xd'),{'force':!![]});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.25.js b/server/migrations/2.0.25.js index 0dab0cf..efa1834 100644 --- a/server/migrations/2.0.25.js +++ b/server/migrations/2.0.25.js @@ -1 +1 @@ -const a904_0x288f=['users','util','inspect','insertExtension','dialPrefix','catch','tools_trunks','queryInterface','sequelize','ulaw;gsm;alaw','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`appType`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27failed\x27,\x20\x272\x27,\x20\x27Hangup\x27,\x20\x27system\x27,\x20\x27catch\x20failed\x20event\x20auto\x20generated\x27,\x20\x27custom\x27,\x20NOW(),\x20NOW());','voice_queues','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`appType`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27failed\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27system\x27,\x20\x27catch\x20failed\x20event\x20auto\x20generated\x27,\x20\x27custom\x27,\x20NOW(),\x20NOW());','STRING','migration','info','prototype','../config/logger','changeColumn','query','exports','Insert\x20new\x20row\x20in\x20voice_extensions','then','allow','addColumn','Added\x20column\x20%s\x20to\x20%s'];(function(_0x1fbec7,_0x288f81){const _0x243350=function(_0x4e39c6){while(--_0x4e39c6){_0x1fbec7['push'](_0x1fbec7['shift']());}};_0x243350(++_0x288f81);}(a904_0x288f,0x159));const a904_0x2433=function(_0x1fbec7,_0x288f81){_0x1fbec7=_0x1fbec7-0x0;let _0x243350=a904_0x288f[_0x1fbec7];return _0x243350;};const _0x1ff453=a904_0x2433;'use strict';const logger=require(_0x1ff453('0xa'))(_0x1ff453('0x7')),util=require(_0x1ff453('0x14')),Migration=function(_0x4e39c6){const _0x519ca3=_0x1ff453;this[_0x519ca3('0x0')]=_0x4e39c6;};Migration['prototype'][_0x1ff453('0x16')]=function(_0x5363e2){const _0x279c4e=_0x1ff453;return this[_0x279c4e('0x0')][_0x279c4e('0x1')][_0x279c4e('0xc')](_0x5363e2)['then'](function(){const _0x157c50=_0x279c4e;logger[_0x157c50('0x8')](_0x157c50('0xe'));})['catch'](function(_0x29e858){const _0x3b3d20=_0x279c4e;logger[_0x3b3d20('0x8')](util[_0x3b3d20('0x15')](_0x29e858,{'showHidden':![],'depth':null}));});},Migration[_0x1ff453('0x9')][_0x1ff453('0xb')]=function(_0x40e256,_0x1ca10c,_0x577848){const _0x388f28=_0x1ff453;return this['queryInterface'][_0x388f28('0xb')](_0x40e256,_0x1ca10c,_0x577848)[_0x388f28('0xf')](function(){const _0x42e3f2=_0x388f28;logger[_0x42e3f2('0x8')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x1ca10c,_0x40e256);})[_0x388f28('0x18')](function(_0x201f0a){const _0x508323=_0x388f28;logger[_0x508323('0x8')](util[_0x508323('0x15')](_0x201f0a,{'showHidden':![],'depth':null}));});},Migration['prototype'][_0x1ff453('0x11')]=function(_0x478331,_0x2e61b9,_0x36d54f){const _0x477fd9=_0x1ff453;return this[_0x477fd9('0x0')]['addColumn'](_0x478331,_0x2e61b9,_0x36d54f)[_0x477fd9('0xf')](function(){const _0x2297b9=_0x477fd9;logger[_0x2297b9('0x8')](_0x2297b9('0x12'),_0x2e61b9,_0x478331);})['catch'](function(_0x248293){logger['info'](JSON['stringify'](_0x248293));});},module[_0x1ff453('0xd')]={'up':function(_0x37a159,_0x1029b1){const _0x5231bb=_0x1ff453,_0x3176d2=new Migration(_0x37a159);_0x3176d2[_0x5231bb('0x16')](_0x5231bb('0x5')),_0x3176d2[_0x5231bb('0x16')](_0x5231bb('0x3')),_0x3176d2[_0x5231bb('0xb')](_0x5231bb('0x13'),_0x5231bb('0x10'),{'type':_0x1029b1['STRING'],'defaultValue':'ulaw;gsm'}),_0x3176d2['changeColumn'](_0x5231bb('0x19'),_0x5231bb('0x10'),{'type':_0x1029b1['STRING'],'defaultValue':_0x5231bb('0x2')}),_0x3176d2['addColumn'](_0x5231bb('0x4'),_0x5231bb('0x17'),{'type':_0x1029b1[_0x5231bb('0x6')],'defaultValue':null});},'down':function(){}}; \ No newline at end of file +const a904_0xca11=['dialPrefix','migration','changeColumn','users','info','STRING','queryInterface','voice_queues','then','stringify','catch','ulaw;gsm','sequelize','ulaw;gsm;alaw','insertExtension','allow','Added\x20column\x20%s\x20to\x20%s','tools_trunks','Insert\x20new\x20row\x20in\x20voice_extensions','prototype'];(function(_0x291781,_0xca1124){const _0x37ae47=function(_0x434e8b){while(--_0x434e8b){_0x291781['push'](_0x291781['shift']());}};_0x37ae47(++_0xca1124);}(a904_0xca11,0xdf));const a904_0x37ae=function(_0x291781,_0xca1124){_0x291781=_0x291781-0x0;let _0x37ae47=a904_0xca11[_0x291781];return _0x37ae47;};const _0xd34444=a904_0x37ae;'use strict';const logger=require('../config/logger')(_0xd34444('0x12')),util=require('util'),Migration=function(_0x434e8b){const _0x5740a1=_0xd34444;this[_0x5740a1('0x3')]=_0x434e8b;};Migration[_0xd34444('0x10')][_0xd34444('0xb')]=function(_0x5859a8){const _0xed3e2c=_0xd34444;return this['queryInterface'][_0xed3e2c('0x9')]['query'](_0x5859a8)['then'](function(){const _0x763370=_0xed3e2c;logger[_0x763370('0x1')](_0x763370('0xf'));})['catch'](function(_0x6a10b7){const _0x4dda07=_0xed3e2c;logger[_0x4dda07('0x1')](util['inspect'](_0x6a10b7,{'showHidden':![],'depth':null}));});},Migration['prototype'][_0xd34444('0x13')]=function(_0x3a1b6f,_0x41851a,_0x6c3b9){const _0x5cc082=_0xd34444;return this[_0x5cc082('0x3')]['changeColumn'](_0x3a1b6f,_0x41851a,_0x6c3b9)['then'](function(){const _0x2c3297=_0x5cc082;logger[_0x2c3297('0x1')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x41851a,_0x3a1b6f);})[_0x5cc082('0x7')](function(_0x3b9ecd){const _0x39ab1c=_0x5cc082;logger[_0x39ab1c('0x1')](util['inspect'](_0x3b9ecd,{'showHidden':![],'depth':null}));});},Migration['prototype']['addColumn']=function(_0x1d457b,_0x5b06e1,_0x2bbd41){const _0x22a1d3=_0xd34444;return this[_0x22a1d3('0x3')]['addColumn'](_0x1d457b,_0x5b06e1,_0x2bbd41)[_0x22a1d3('0x5')](function(){const _0x1b3fa1=_0x22a1d3;logger['info'](_0x1b3fa1('0xd'),_0x5b06e1,_0x1d457b);})['catch'](function(_0x37e4fa){const _0x6185ee=_0x22a1d3;logger[_0x6185ee('0x1')](JSON[_0x6185ee('0x6')](_0x37e4fa));});},module['exports']={'up':function(_0x3aa769,_0xb2129c){const _0xe75e05=_0xd34444,_0x7f2c98=new Migration(_0x3aa769);_0x7f2c98[_0xe75e05('0xb')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`appType`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27failed\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27system\x27,\x20\x27catch\x20failed\x20event\x20auto\x20generated\x27,\x20\x27custom\x27,\x20NOW(),\x20NOW());'),_0x7f2c98[_0xe75e05('0xb')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`appType`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27failed\x27,\x20\x272\x27,\x20\x27Hangup\x27,\x20\x27system\x27,\x20\x27catch\x20failed\x20event\x20auto\x20generated\x27,\x20\x27custom\x27,\x20NOW(),\x20NOW());'),_0x7f2c98[_0xe75e05('0x13')](_0xe75e05('0x0'),_0xe75e05('0xc'),{'type':_0xb2129c[_0xe75e05('0x2')],'defaultValue':_0xe75e05('0x8')}),_0x7f2c98['changeColumn'](_0xe75e05('0xe'),_0xe75e05('0xc'),{'type':_0xb2129c[_0xe75e05('0x2')],'defaultValue':_0xe75e05('0xa')}),_0x7f2c98['addColumn'](_0xe75e05('0x4'),_0xe75e05('0x11'),{'type':_0xb2129c[_0xe75e05('0x2')],'defaultValue':null});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.26.js b/server/migrations/2.0.26.js index 0e4a737..27b7cf3 100644 --- a/server/migrations/2.0.26.js +++ b/server/migrations/2.0.26.js @@ -1 +1 @@ -const a905_0x507d=['catch','queryInterface','voice_queues','STRING','allow','INTEGER','stringify','util','exports','yes','timeout','mail_accounts','tools_trunks','onlyIfOpen','inspect','email','changeColumn','pai','then','never','dialCheckDuplicateType','migration','always','info','ENUM','Added\x20column\x20%s\x20to\x20%s','prototype','campaigns','ulaw;alaw;gsm','sendrpid','authentication','addColumn'];(function(_0x37c45a,_0x507d1b){const _0x36a3aa=function(_0x4d67b9){while(--_0x4d67b9){_0x37c45a['push'](_0x37c45a['shift']());}};_0x36a3aa(++_0x507d1b);}(a905_0x507d,0x183));const a905_0x36a3=function(_0x37c45a,_0x507d1b){_0x37c45a=_0x37c45a-0x0;let _0x36a3aa=a905_0x507d[_0x37c45a];return _0x36a3aa;};const _0x54ec8d=a905_0x36a3;'use strict';const logger=require('../config/logger')(_0x54ec8d('0x12')),util=require(_0x54ec8d('0x4')),Migration=function(_0x4d67b9){const _0x45eab9=_0x54ec8d;this[_0x45eab9('0x1e')]=_0x4d67b9;};Migration[_0x54ec8d('0x17')]['changeColumn']=function(_0x50ce44,_0x8cad61,_0x2eb658){const _0x309a99=_0x54ec8d;return this[_0x309a99('0x1e')][_0x309a99('0xd')](_0x50ce44,_0x8cad61,_0x2eb658)['then'](function(){const _0x2153f9=_0x309a99;logger[_0x2153f9('0x14')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x8cad61,_0x50ce44);})[_0x309a99('0x1d')](function(_0x52d4cf){const _0x221b41=_0x309a99;logger['info'](util[_0x221b41('0xb')](_0x52d4cf,{'showHidden':![],'depth':null}));});},Migration[_0x54ec8d('0x17')][_0x54ec8d('0x1c')]=function(_0x4dafa7,_0x1049a1,_0x385ac1){const _0x3794ea=_0x54ec8d;return this[_0x3794ea('0x1e')][_0x3794ea('0x1c')](_0x4dafa7,_0x1049a1,_0x385ac1)[_0x3794ea('0xf')](function(){const _0x564ed3=_0x3794ea;logger['info'](_0x564ed3('0x16'),_0x1049a1,_0x4dafa7);})['catch'](function(_0x9807a){const _0x2a6b55=_0x3794ea;logger[_0x2a6b55('0x14')](JSON[_0x2a6b55('0x3')](_0x9807a));});},module[_0x54ec8d('0x5')]={'up':function(_0x4354e6,_0x1dcf1b){const _0x426746=_0x54ec8d,_0x29961b=new Migration(_0x4354e6);_0x29961b[_0x426746('0xd')]('tools_trunks',_0x426746('0x1a'),{'type':_0x1dcf1b[_0x426746('0x15')](_0x426746('0x6'),'no',_0x426746('0xe')),'defaultValue':'no'}),_0x29961b[_0x426746('0x1c')]('mail_servers_out',_0x426746('0x1b'),{'type':_0x1dcf1b['BOOLEAN'],'defaultValue':!![]}),_0x29961b[_0x426746('0xd')]('voice_queues',_0x426746('0x7'),{'type':_0x1dcf1b['INTEGER'](0xb),'defaultValue':0xf}),_0x29961b[_0x426746('0xd')](_0x426746('0x1f'),'retry',{'type':_0x1dcf1b[_0x426746('0x2')](0xb),'defaultValue':0x2}),_0x29961b[_0x426746('0xd')]('users',_0x426746('0x1'),{'type':_0x1dcf1b[_0x426746('0x0')],'allowNull':![],'defaultValue':_0x426746('0x19')}),_0x29961b[_0x426746('0xd')](_0x426746('0x9'),'allow',{'type':_0x1dcf1b[_0x426746('0x0')],'allowNull':![],'defaultValue':_0x426746('0x19')}),_0x29961b[_0x426746('0x1c')]('voice_queues',_0x426746('0x11'),{'type':_0x1dcf1b[_0x426746('0x15')](_0x426746('0x13'),'never',_0x426746('0xa')),'defaultValue':_0x426746('0x13')}),_0x29961b[_0x426746('0x1c')](_0x426746('0x18'),_0x426746('0x11'),{'type':_0x1dcf1b['ENUM'](_0x426746('0x13'),_0x426746('0x10'),_0x426746('0xa')),'defaultValue':_0x426746('0x13')}),_0x29961b[_0x426746('0x1c')](_0x426746('0x8'),_0x426746('0xc'),{'type':_0x1dcf1b[_0x426746('0x0')]});},'down':function(){}}; \ No newline at end of file +const a905_0x4531=['exports','ulaw;alaw;gsm','never','timeout','onlyIfOpen','BOOLEAN','then','voice_queues','dialCheckDuplicateType','users','queryInterface','inspect','Added\x20column\x20%s\x20to\x20%s','ENUM','addColumn','campaigns','tools_trunks','prototype','STRING','allow','changeColumn','INTEGER','always','email','util','info','yes','migration'];(function(_0x3c1e45,_0x453159){const _0x3e2be8=function(_0x9bfaa2){while(--_0x9bfaa2){_0x3c1e45['push'](_0x3c1e45['shift']());}};_0x3e2be8(++_0x453159);}(a905_0x4531,0x6c));const a905_0x3e2b=function(_0x3c1e45,_0x453159){_0x3c1e45=_0x3c1e45-0x0;let _0x3e2be8=a905_0x4531[_0x3c1e45];return _0x3e2be8;};const _0x1e8251=a905_0x3e2b;'use strict';const logger=require('../config/logger')(_0x1e8251('0x3')),util=require(_0x1e8251('0x0')),Migration=function(_0x9bfaa2){const _0x43dc8a=_0x1e8251;this[_0x43dc8a('0xe')]=_0x9bfaa2;};Migration['prototype'][_0x1e8251('0x18')]=function(_0x3249b6,_0x358b1b,_0x458405){const _0x49d0f9=_0x1e8251;return this['queryInterface'][_0x49d0f9('0x18')](_0x3249b6,_0x358b1b,_0x458405)[_0x49d0f9('0xa')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x358b1b,_0x3249b6);})['catch'](function(_0x1b16f3){const _0x293974=_0x49d0f9;logger['info'](util[_0x293974('0xf')](_0x1b16f3,{'showHidden':![],'depth':null}));});},Migration[_0x1e8251('0x15')][_0x1e8251('0x12')]=function(_0xc13c6d,_0x41552d,_0x415bf7){const _0x6d925f=_0x1e8251;return this['queryInterface']['addColumn'](_0xc13c6d,_0x41552d,_0x415bf7)[_0x6d925f('0xa')](function(){const _0x5b8b02=_0x6d925f;logger[_0x5b8b02('0x1')](_0x5b8b02('0x10'),_0x41552d,_0xc13c6d);})['catch'](function(_0x2dc696){const _0x533231=_0x6d925f;logger[_0x533231('0x1')](JSON['stringify'](_0x2dc696));});},module[_0x1e8251('0x4')]={'up':function(_0xa7558d,_0x372b81){const _0x4a9976=_0x1e8251,_0x21d362=new Migration(_0xa7558d);_0x21d362[_0x4a9976('0x18')](_0x4a9976('0x14'),'sendrpid',{'type':_0x372b81['ENUM'](_0x4a9976('0x2'),'no','pai'),'defaultValue':'no'}),_0x21d362[_0x4a9976('0x12')]('mail_servers_out','authentication',{'type':_0x372b81[_0x4a9976('0x9')],'defaultValue':!![]}),_0x21d362[_0x4a9976('0x18')](_0x4a9976('0xb'),_0x4a9976('0x7'),{'type':_0x372b81[_0x4a9976('0x19')](0xb),'defaultValue':0xf}),_0x21d362[_0x4a9976('0x18')](_0x4a9976('0xb'),'retry',{'type':_0x372b81[_0x4a9976('0x19')](0xb),'defaultValue':0x2}),_0x21d362[_0x4a9976('0x18')](_0x4a9976('0xd'),_0x4a9976('0x17'),{'type':_0x372b81[_0x4a9976('0x16')],'allowNull':![],'defaultValue':_0x4a9976('0x5')}),_0x21d362[_0x4a9976('0x18')](_0x4a9976('0x14'),'allow',{'type':_0x372b81[_0x4a9976('0x16')],'allowNull':![],'defaultValue':_0x4a9976('0x5')}),_0x21d362[_0x4a9976('0x12')]('voice_queues',_0x4a9976('0xc'),{'type':_0x372b81[_0x4a9976('0x11')]('always',_0x4a9976('0x6'),_0x4a9976('0x8')),'defaultValue':_0x4a9976('0x1a')}),_0x21d362[_0x4a9976('0x12')](_0x4a9976('0x13'),'dialCheckDuplicateType',{'type':_0x372b81[_0x4a9976('0x11')](_0x4a9976('0x1a'),_0x4a9976('0x6'),_0x4a9976('0x8')),'defaultValue':_0x4a9976('0x1a')}),_0x21d362['addColumn']('mail_accounts',_0x4a9976('0x1b'),{'type':_0x372b81['STRING']});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.27.js b/server/migrations/2.0.27.js index 12143c4..feeb70b 100644 --- a/server/migrations/2.0.27.js +++ b/server/migrations/2.0.27.js @@ -1 +1 @@ -'use strict';module['exports']={'up':function(){},'down':function(){}}; \ No newline at end of file +var a906_0xde31=['exports'];(function(_0x4548ee,_0xde3150){var _0x3e9c2a=function(_0x3eb0c8){while(--_0x3eb0c8){_0x4548ee['push'](_0x4548ee['shift']());}};_0x3e9c2a(++_0xde3150);}(a906_0xde31,0x10f));var a906_0x3e9c=function(_0x4548ee,_0xde3150){_0x4548ee=_0x4548ee-0x0;var _0x3e9c2a=a906_0xde31[_0x4548ee];return _0x3e9c2a;};var _0x2b51f9=a906_0x3e9c;'use strict';module[_0x2b51f9('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.28.js b/server/migrations/2.0.28.js index 3490d01..12143c4 100644 --- a/server/migrations/2.0.28.js +++ b/server/migrations/2.0.28.js @@ -1 +1 @@ -var a907_0x3475=['exports'];(function(_0x26ecbf,_0x3475c6){var _0x44fcf0=function(_0x39e2ea){while(--_0x39e2ea){_0x26ecbf['push'](_0x26ecbf['shift']());}};_0x44fcf0(++_0x3475c6);}(a907_0x3475,0xd2));var a907_0x44fc=function(_0x26ecbf,_0x3475c6){_0x26ecbf=_0x26ecbf-0x0;var _0x44fcf0=a907_0x3475[_0x26ecbf];return _0x44fcf0;};var _0x4f1d3e=a907_0x44fc;'use strict';module[_0x4f1d3e('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file +'use strict';module['exports']={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.29.js b/server/migrations/2.0.29.js index d953686..fb6733b 100644 --- a/server/migrations/2.0.29.js +++ b/server/migrations/2.0.29.js @@ -1 +1 @@ -const a908_0x4483=['Changed\x20column\x20%s\x20in\x20table\x20%s','#AMD\x20Between\x20Words\x20Silence','user_has_openchannel_interactions','finally','dialAMDSilenceThreshold','dropTable','tail','chat_interactions','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2710\x27,\x20\x27execif\x27,\x20\x27$[\x22${XMD-QUEUE}\x22\x20!=\x20\x22NONE\x22\x20]?QUEUE(${XMD-QUEUE})\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','addIndex','chat_dispositions','../config/logger','query\x20%s','dialAMDMaximumNumberOfWords','dialAMDMinWordLength','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x279\x27,\x20\x27execif\x27,\x20\x27$[\x22${XMD-AGI}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGI})\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','chat_messages','user_has_chat_rooms','dialAMDGreeting','phoneBarDnd','catch','sequelize','campaigns','queryInterface','#AMD\x20Silence\x20Threshold\x20(min:0,\x20max:32767)','info','enqueue','dialAMDActive','phoneBarNoReply','query','STRING','cm_hopper_final','migration','dialAMDMaximumWordLength','team_has_chat_queues','Queue\x20Timeout\x20Seconds\x20(min:1,\x20max:999)','#AMD\x20Maximum\x20Number\x20Of\x20Words','table\x20dropped\x20%s','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x276\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22HUMAN\x22\x20]?9:7\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','users','voice_queues','BOOLEAN','cm_hopper','INTEGER','dialAMDTotalAnalysisTime','phone','prototype','addIndex\x20%s\x20%s\x20%s','final','dialAMDInitialSilence','DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20exten\x20=\x20\x27xcally-motion-dialer\x27;','sequence','chat_enquiries','user_has_chat_queues','#AMD\x20Total\x20Analysis\x20Time','then','phoneBarUnconditional','UNSIGNED','phoneBarNoReplyNumber','changeColumn','#AMD\x20After\x20Greeting\x20Silence','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x273\x27,\x20\x27set\x27,\x20\x27CALLERID(all)=${XMD-CALLERID}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','openchannel_interactions','#AMD\x20Min\x20Word\x20Length','dialQueueTimeout','join','#AMD\x20Greeting','addColumn','dialAMDAfterGreetingSilence','dialAMDBetweenWordsSilence','Added\x20column\x20%s\x20to\x20%s','#AMD\x20Initial\x20Silence','phoneBarBusy','#AMD\x20Maximum\x20Word\x20Length','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x278\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22MACHINE\x22\x20]?11:9\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'];(function(_0x5628ee,_0x448360){const _0x34cd93=function(_0x143af3){while(--_0x143af3){_0x5628ee['push'](_0x5628ee['shift']());}};_0x34cd93(++_0x448360);}(a908_0x4483,0xf4));const a908_0x34cd=function(_0x5628ee,_0x448360){_0x5628ee=_0x5628ee-0x0;let _0x34cd93=a908_0x4483[_0x5628ee];return _0x34cd93;};const _0x42294e=a908_0x34cd;'use strict';const logger=require(_0x42294e('0x43'))(_0x42294e('0xd')),Sequence=function(){};Sequence[_0x42294e('0x1b')]['enqueue']=function(_0x143af3){const _0x1a989b=_0x42294e;this[_0x1a989b('0x3e')]=this[_0x1a989b('0x3e')]?this[_0x1a989b('0x3e')][_0x1a989b('0x3b')](_0x143af3):_0x143af3();};const Migration=function(_0x23e63d){const _0x5a0444=_0x42294e;this[_0x5a0444('0x4')]=_0x23e63d,this[_0x5a0444('0x20')]=new Sequence();};Migration[_0x42294e('0x1b')][_0x42294e('0x28')]=function(_0x296b6e,_0x1c483b,_0x464297){const _0x1417e3=_0x42294e,_0x1f3037=this;this[_0x1417e3('0x20')][_0x1417e3('0x7')](function(){const _0x434183=_0x1417e3;return _0x1f3037[_0x434183('0x4')][_0x434183('0x28')](_0x296b6e,_0x1c483b,_0x464297)[_0x434183('0x24')](function(){const _0x27fb75=_0x434183;logger[_0x27fb75('0x6')](_0x27fb75('0x38'),_0x1c483b,_0x296b6e);})[_0x434183('0x1')](function(_0x5e1511){const _0x26e2ab=_0x434183;logger[_0x26e2ab('0x6')](JSON['stringify'](_0x5e1511));});});},Migration['prototype'][_0x42294e('0x30')]=function(_0x500e20,_0x52caad,_0x21aff2){const _0x41b567=_0x42294e,_0x3316d1=this;this[_0x41b567('0x20')][_0x41b567('0x7')](function(){const _0x28df91=_0x41b567;return _0x3316d1[_0x28df91('0x4')][_0x28df91('0x30')](_0x500e20,_0x52caad,_0x21aff2)['then'](function(){const _0xb60190=_0x28df91;logger[_0xb60190('0x6')](_0xb60190('0x33'),_0x52caad,_0x500e20);})['catch'](function(_0x48d0d3){const _0x563c5a=_0x28df91;logger[_0x563c5a('0x6')](JSON['stringify'](_0x48d0d3));});});},Migration[_0x42294e('0x1b')][_0x42294e('0x3d')]=function(_0x584439){const _0x2ee48f=_0x42294e,_0x270f17=this;this[_0x2ee48f('0x20')][_0x2ee48f('0x7')](function(){const _0x51bf24=_0x2ee48f;return _0x270f17['queryInterface'][_0x51bf24('0x3d')](_0x584439,{'force':!![]})[_0x51bf24('0x24')](function(){const _0x3bc843=_0x51bf24;logger[_0x3bc843('0x6')](_0x3bc843('0x12'),_0x584439);})['catch'](function(_0xf2e3e3){logger['info'](JSON['stringify'](_0xf2e3e3));});});},Migration[_0x42294e('0x1b')]['addIndex']=function(_0x3c1a6b,_0x3c21ea,_0x5f16dd){const _0x16aa1c=this;this['sequence']['enqueue'](function(){const _0x37e19c=a908_0x34cd;return _0x16aa1c['queryInterface'][_0x37e19c('0x41')](_0x3c1a6b,_0x3c21ea,{'indexName':_0x5f16dd})[_0x37e19c('0x24')](function(){const _0x14b234=_0x37e19c;logger[_0x14b234('0x6')](_0x14b234('0x1c'),_0x3c1a6b,_0x3c21ea[_0x14b234('0x2e')](','),_0x5f16dd);})[_0x37e19c('0x1')](function(_0x10ee71){const _0x5613d2=_0x37e19c;logger[_0x5613d2('0x6')](JSON['stringify'](_0x10ee71));});});},Migration['prototype']['query']=function(_0x2f5be6){const _0x14f41c=_0x42294e,_0x49cc6a=this;this['sequence'][_0x14f41c('0x7')](function(){const _0x2b1516=_0x14f41c;return _0x49cc6a[_0x2b1516('0x4')][_0x2b1516('0x2')][_0x2b1516('0xa')](_0x2f5be6)['then'](function(){const _0x1833c4=_0x2b1516;logger[_0x1833c4('0x6')](_0x1833c4('0x44'),_0x2f5be6);})[_0x2b1516('0x1')](function(_0xad49a3){const _0x1e44b5=_0x2b1516;logger[_0x1e44b5('0x6')](JSON['stringify'](_0xad49a3));});});},Migration[_0x42294e('0x1b')]['final']=function(_0x1b0ae8){const _0x133aaa=_0x42294e;this[_0x133aaa('0x20')][_0x133aaa('0x7')](function(){return _0x1b0ae8();});},module['exports']={'up':function(_0x3ca249,_0x57e8fc){return new Promise(function(_0x1f3c1f){const _0x54279e=a908_0x34cd,_0x14d7e9=new Migration(_0x3ca249);_0x14d7e9['dropTable'](_0x54279e('0x49')),_0x14d7e9[_0x54279e('0x3d')](_0x54279e('0x21')),_0x14d7e9[_0x54279e('0x3d')](_0x54279e('0x48')),_0x14d7e9[_0x54279e('0x3d')]('chat_proactive_actions'),_0x14d7e9[_0x54279e('0x3d')](_0x54279e('0x42')),_0x14d7e9['dropTable']('chat_applications'),_0x14d7e9[_0x54279e('0x3d')]('user_has_chat_interactions'),_0x14d7e9['dropTable'](_0x54279e('0x3f')),_0x14d7e9[_0x54279e('0x3d')](_0x54279e('0xf')),_0x14d7e9[_0x54279e('0x3d')](_0x54279e('0x22')),_0x14d7e9['dropTable']('chat_queues'),_0x14d7e9['dropTable']('chat_websites'),_0x14d7e9['dropTable']('openchannel_messages'),_0x14d7e9[_0x54279e('0x3d')](_0x54279e('0x3a')),_0x14d7e9[_0x54279e('0x3d')](_0x54279e('0x2b')),_0x14d7e9[_0x54279e('0x41')](_0x54279e('0x17'),[_0x54279e('0x1a')],_0x54279e('0x1a')),_0x14d7e9[_0x54279e('0x41')](_0x54279e('0xc'),['calleridnum'],'calleridnum'),_0x14d7e9['addColumn'](_0x54279e('0x14'),'phoneBarUnconditionalNumber',{'type':_0x57e8fc[_0x54279e('0xb')]}),_0x14d7e9[_0x54279e('0x30')]('users',_0x54279e('0x27'),{'type':_0x57e8fc[_0x54279e('0xb')]}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x14'),'phoneBarBusyNumber',{'type':_0x57e8fc[_0x54279e('0xb')]}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x14'),_0x54279e('0x25'),{'type':_0x57e8fc[_0x54279e('0x16')],'defaultValue':![]}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x14'),_0x54279e('0x9'),{'type':_0x57e8fc[_0x54279e('0x16')],'defaultValue':![]}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x14'),_0x54279e('0x35'),{'type':_0x57e8fc['BOOLEAN'],'defaultValue':![]}),_0x14d7e9['addColumn'](_0x54279e('0x14'),_0x54279e('0x0'),{'type':_0x57e8fc[_0x54279e('0x16')],'defaultValue':!![]}),_0x14d7e9[_0x54279e('0x28')](_0x54279e('0x3'),_0x54279e('0x2d'),{'type':_0x57e8fc['INTEGER'](0x3)[_0x54279e('0x26')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x54279e('0x10')}),_0x14d7e9['addColumn'](_0x54279e('0x15'),_0x54279e('0x8'),{'type':_0x57e8fc[_0x54279e('0x16')],'defaultValue':0x0,'comment':'Active/Disactive\x20AMD'}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x15'),_0x54279e('0x1e'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x9c4,'comment':_0x54279e('0x34')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x15'),'dialAMDGreeting',{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x5dc,'comment':_0x54279e('0x2f')}),_0x14d7e9[_0x54279e('0x30')]('voice_queues','dialAMDAfterGreetingSilence',{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x320,'comment':_0x54279e('0x29')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x15'),_0x54279e('0x19'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x1388,'comment':_0x54279e('0x23')}),_0x14d7e9[_0x54279e('0x30')]('voice_queues',_0x54279e('0x46'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x64,'comment':_0x54279e('0x2c')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x15'),_0x54279e('0x32'),{'type':_0x57e8fc['INTEGER'](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x32,'comment':_0x54279e('0x39')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x15'),_0x54279e('0x45'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x3,'comment':_0x54279e('0x11')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x15'),_0x54279e('0x3c'),{'type':_0x57e8fc[_0x54279e('0x18')](0x5)[_0x54279e('0x26')],'validate':{'min':0x0,'max':0x7fff},'defaultValue':0x100,'comment':_0x54279e('0x5')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x15'),_0x54279e('0xe'),{'type':_0x57e8fc['INTEGER'](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x1388,'comment':_0x54279e('0x36')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x3'),'dialAMDActive',{'type':_0x57e8fc['BOOLEAN'],'defaultValue':0x0,'comment':'Active/Disactive\x20AMD'}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x3'),'dialAMDInitialSilence',{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x9c4,'comment':_0x54279e('0x34')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x3'),_0x54279e('0x4a'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)['UNSIGNED'],'validate':{'min':0x0},'defaultValue':0x5dc,'comment':'#AMD\x20Greeting'}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x3'),_0x54279e('0x31'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x320,'comment':_0x54279e('0x29')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x3'),_0x54279e('0x19'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x1388,'comment':_0x54279e('0x23')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x3'),_0x54279e('0x46'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)['UNSIGNED'],'validate':{'min':0x0},'defaultValue':0x64,'comment':_0x54279e('0x2c')}),_0x14d7e9[_0x54279e('0x30')](_0x54279e('0x3'),_0x54279e('0x32'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)['UNSIGNED'],'validate':{'min':0x0},'defaultValue':0x32,'comment':_0x54279e('0x39')}),_0x14d7e9[_0x54279e('0x30')]('campaigns',_0x54279e('0x45'),{'type':_0x57e8fc[_0x54279e('0x18')](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x3,'comment':_0x54279e('0x11')}),_0x14d7e9[_0x54279e('0x30')]('campaigns',_0x54279e('0x3c'),{'type':_0x57e8fc[_0x54279e('0x18')](0x5)[_0x54279e('0x26')],'validate':{'min':0x0,'max':0x7fff},'defaultValue':0x100,'comment':'#AMD\x20Silence\x20Threshold\x20(min:0,\x20max:32767)'}),_0x14d7e9['addColumn'](_0x54279e('0x3'),_0x54279e('0xe'),{'type':_0x57e8fc['INTEGER'](0x9)[_0x54279e('0x26')],'validate':{'min':0x0},'defaultValue':0x1388,'comment':_0x54279e('0x36')}),_0x14d7e9[_0x54279e('0xa')](_0x54279e('0x1f')),_0x14d7e9['query']('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x14d7e9[_0x54279e('0xa')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x272\x27,\x20\x27set\x27,\x20\x27CDR(type)=dialer\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x14d7e9[_0x54279e('0xa')](_0x54279e('0x2a')),_0x14d7e9[_0x54279e('0xa')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x274\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${XMD-AMD}\x22\x20!=\x20\x22NONE\x22\x20]?5:9\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x14d7e9['query']('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x275\x27,\x20\x27amd\x27,\x20\x27${XMD-AMDINITIALSILENCE},${XMD-AMDGREETING},${XMD-AMDAFTERGREETINGSILENCE},${XMD-AMDTOTALANALYSISTIME},${XMD-AMDMINWORDLENGTH},${XMD-AMDBETWEENWORDSSILENCE},${XMD-AMDMAXIMUMNUMBEROFWORDS},${XMD-AMDSILENCETHRESHOLD},${XMD-AMDMAXIMUMWORDLENGTH}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x14d7e9[_0x54279e('0xa')](_0x54279e('0x13')),_0x14d7e9[_0x54279e('0xa')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x277\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22NOTSURE\x22\x20]?9:8\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x14d7e9['query'](_0x54279e('0x37')),_0x14d7e9[_0x54279e('0xa')](_0x54279e('0x47')),_0x14d7e9[_0x54279e('0xa')](_0x54279e('0x40')),_0x14d7e9[_0x54279e('0xa')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2711\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x14d7e9[_0x54279e('0x1d')](_0x1f3c1f);});},'down':function(){}}; \ No newline at end of file +const a908_0x2224=['phoneBarNoReplyNumber','then','final','campaigns','../config/logger','phoneBarUnconditionalNumber','migration','finally','phoneBarBusy','chat_queues','Queue\x20Timeout\x20Seconds\x20(min:1,\x20max:999)','dialAMDInitialSilence','#AMD\x20Maximum\x20Number\x20Of\x20Words','dialQueueTimeout','catch','chat_websites','cm_hopper_final','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','dropTable','dialAMDActive','chat_applications','users','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x273\x27,\x20\x27set\x27,\x20\x27CALLERID(all)=${XMD-CALLERID}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','dialAMDGreeting','dialAMDAfterGreetingSilence','openchannel_messages','calleridnum','table\x20dropped\x20%s','#AMD\x20Min\x20Word\x20Length','STRING','user_has_chat_interactions','chat_interactions','sequelize','UNSIGNED','dialAMDMaximumWordLength','changeColumn','addIndex','dialAMDMaximumNumberOfWords','query\x20%s','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x274\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${XMD-AMD}\x22\x20!=\x20\x22NONE\x22\x20]?5:9\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x276\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22HUMAN\x22\x20]?9:7\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','Added\x20column\x20%s\x20to\x20%s','chat_dispositions','chat_messages','dialAMDSilenceThreshold','chat_enquiries','phoneBarNoReply','join','queryInterface','sequence','voice_queues','INTEGER','cm_hopper','info','query','dialAMDTotalAnalysisTime','dialAMDMinWordLength','Changed\x20column\x20%s\x20in\x20table\x20%s','#AMD\x20Greeting','Active/Disactive\x20AMD','#AMD\x20After\x20Greeting\x20Silence','exports','addColumn','phone','#AMD\x20Maximum\x20Word\x20Length','#AMD\x20Initial\x20Silence','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x277\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22NOTSURE\x22\x20]?9:8\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','stringify','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x275\x27,\x20\x27amd\x27,\x20\x27${XMD-AMDINITIALSILENCE},${XMD-AMDGREETING},${XMD-AMDAFTERGREETINGSILENCE},${XMD-AMDTOTALANALYSISTIME},${XMD-AMDMINWORDLENGTH},${XMD-AMDBETWEENWORDSSILENCE},${XMD-AMDMAXIMUMNUMBEROFWORDS},${XMD-AMDSILENCETHRESHOLD},${XMD-AMDMAXIMUMWORDLENGTH}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','BOOLEAN','prototype','user_has_chat_rooms','#AMD\x20Silence\x20Threshold\x20(min:0,\x20max:32767)','addIndex\x20%s\x20%s\x20%s','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2711\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','enqueue','tail','phoneBarUnconditional','dialAMDBetweenWordsSilence'];(function(_0x58d6f7,_0x222483){const _0x42dc3b=function(_0x583354){while(--_0x583354){_0x58d6f7['push'](_0x58d6f7['shift']());}};_0x42dc3b(++_0x222483);}(a908_0x2224,0xe4));const a908_0x42dc=function(_0x58d6f7,_0x222483){_0x58d6f7=_0x58d6f7-0x0;let _0x42dc3b=a908_0x2224[_0x58d6f7];return _0x42dc3b;};const _0x5543b4=a908_0x42dc;'use strict';const logger=require(_0x5543b4('0xd'))(_0x5543b4('0xf')),Sequence=function(){};Sequence[_0x5543b4('0x0')][_0x5543b4('0x5')]=function(_0x583354){const _0x1bb5f9=_0x5543b4;this[_0x1bb5f9('0x6')]=this[_0x1bb5f9('0x6')]?this['tail'][_0x1bb5f9('0x10')](_0x583354):_0x583354();};const Migration=function(_0x1885e9){const _0x46355e=_0x5543b4;this[_0x46355e('0x39')]=_0x1885e9,this[_0x46355e('0x3a')]=new Sequence();};Migration['prototype'][_0x5543b4('0x2c')]=function(_0x121617,_0x598fae,_0x3e7bee){const _0x3e473b=_0x5543b4,_0x3b30e4=this;this['sequence'][_0x3e473b('0x5')](function(){const _0x36141f=_0x3e473b;return _0x3b30e4['queryInterface'][_0x36141f('0x2c')](_0x121617,_0x598fae,_0x3e7bee)[_0x36141f('0xa')](function(){const _0x1c209d=_0x36141f;logger[_0x1c209d('0x3e')](_0x1c209d('0x42'),_0x598fae,_0x121617);})['catch'](function(_0x36eb1f){const _0x7686d8=_0x36141f;logger['info'](JSON[_0x7686d8('0x4c')](_0x36eb1f));});});},Migration[_0x5543b4('0x0')][_0x5543b4('0x47')]=function(_0x29d27a,_0x429c8d,_0x48e578){const _0x16c422=_0x5543b4,_0x4fa36c=this;this[_0x16c422('0x3a')]['enqueue'](function(){const _0x118468=_0x16c422;return _0x4fa36c['queryInterface']['addColumn'](_0x29d27a,_0x429c8d,_0x48e578)[_0x118468('0xa')](function(){const _0x23e6e8=_0x118468;logger[_0x23e6e8('0x3e')](_0x23e6e8('0x32'),_0x429c8d,_0x29d27a);})['catch'](function(_0x56b6dc){const _0x668294=_0x118468;logger[_0x668294('0x3e')](JSON[_0x668294('0x4c')](_0x56b6dc));});});},Migration['prototype']['dropTable']=function(_0x1a7f88){const _0x2779be=_0x5543b4,_0x96450e=this;this['sequence'][_0x2779be('0x5')](function(){const _0x27b591=_0x2779be;return _0x96450e['queryInterface'][_0x27b591('0x1b')](_0x1a7f88,{'force':!![]})[_0x27b591('0xa')](function(){const _0x4198bc=_0x27b591;logger[_0x4198bc('0x3e')](_0x4198bc('0x24'),_0x1a7f88);})[_0x27b591('0x17')](function(_0x4c8de0){const _0x2564a3=_0x27b591;logger[_0x2564a3('0x3e')](JSON[_0x2564a3('0x4c')](_0x4c8de0));});});},Migration['prototype'][_0x5543b4('0x2d')]=function(_0x203e3f,_0x39ead7,_0x514da3){const _0x409d9e=_0x5543b4,_0x33b24e=this;this[_0x409d9e('0x3a')][_0x409d9e('0x5')](function(){const _0x2653de=_0x409d9e;return _0x33b24e[_0x2653de('0x39')][_0x2653de('0x2d')](_0x203e3f,_0x39ead7,{'indexName':_0x514da3})[_0x2653de('0xa')](function(){const _0x5aceb8=_0x2653de;logger[_0x5aceb8('0x3e')](_0x5aceb8('0x3'),_0x203e3f,_0x39ead7[_0x5aceb8('0x38')](','),_0x514da3);})['catch'](function(_0x258447){logger['info'](JSON['stringify'](_0x258447));});});},Migration[_0x5543b4('0x0')][_0x5543b4('0x3f')]=function(_0x82ce03){const _0x4c6f16=this;this['sequence']['enqueue'](function(){const _0x52031a=a908_0x42dc;return _0x4c6f16[_0x52031a('0x39')][_0x52031a('0x29')][_0x52031a('0x3f')](_0x82ce03)[_0x52031a('0xa')](function(){const _0xbee2e9=_0x52031a;logger[_0xbee2e9('0x3e')](_0xbee2e9('0x2f'),_0x82ce03);})['catch'](function(_0x1059aa){const _0x5871a3=_0x52031a;logger[_0x5871a3('0x3e')](JSON[_0x5871a3('0x4c')](_0x1059aa));});});},Migration[_0x5543b4('0x0')][_0x5543b4('0xb')]=function(_0x1d966f){const _0x27b3f2=_0x5543b4;this[_0x27b3f2('0x3a')][_0x27b3f2('0x5')](function(){return _0x1d966f();});},module[_0x5543b4('0x46')]={'up':function(_0x4e5991,_0x49a2a8){return new Promise(function(_0x179f6f){const _0x2df7b9=a908_0x42dc,_0x35cb08=new Migration(_0x4e5991);_0x35cb08[_0x2df7b9('0x1b')](_0x2df7b9('0x1')),_0x35cb08[_0x2df7b9('0x1b')](_0x2df7b9('0x36')),_0x35cb08[_0x2df7b9('0x1b')](_0x2df7b9('0x34')),_0x35cb08[_0x2df7b9('0x1b')]('chat_proactive_actions'),_0x35cb08['dropTable'](_0x2df7b9('0x33')),_0x35cb08[_0x2df7b9('0x1b')](_0x2df7b9('0x1d')),_0x35cb08[_0x2df7b9('0x1b')](_0x2df7b9('0x27')),_0x35cb08[_0x2df7b9('0x1b')](_0x2df7b9('0x28')),_0x35cb08[_0x2df7b9('0x1b')]('team_has_chat_queues'),_0x35cb08[_0x2df7b9('0x1b')]('user_has_chat_queues'),_0x35cb08[_0x2df7b9('0x1b')](_0x2df7b9('0x12')),_0x35cb08['dropTable'](_0x2df7b9('0x18')),_0x35cb08['dropTable'](_0x2df7b9('0x22')),_0x35cb08['dropTable']('user_has_openchannel_interactions'),_0x35cb08[_0x2df7b9('0x1b')]('openchannel_interactions'),_0x35cb08[_0x2df7b9('0x2d')](_0x2df7b9('0x3d'),[_0x2df7b9('0x48')],_0x2df7b9('0x48')),_0x35cb08[_0x2df7b9('0x2d')](_0x2df7b9('0x19'),[_0x2df7b9('0x23')],_0x2df7b9('0x23')),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x1e'),_0x2df7b9('0xe'),{'type':_0x49a2a8['STRING']}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x1e'),_0x2df7b9('0x9'),{'type':_0x49a2a8[_0x2df7b9('0x26')]}),_0x35cb08['addColumn']('users','phoneBarBusyNumber',{'type':_0x49a2a8['STRING']}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x1e'),_0x2df7b9('0x7'),{'type':_0x49a2a8[_0x2df7b9('0x4e')],'defaultValue':![]}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x1e'),_0x2df7b9('0x37'),{'type':_0x49a2a8[_0x2df7b9('0x4e')],'defaultValue':![]}),_0x35cb08[_0x2df7b9('0x47')]('users',_0x2df7b9('0x11'),{'type':_0x49a2a8['BOOLEAN'],'defaultValue':![]}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x1e'),'phoneBarDnd',{'type':_0x49a2a8['BOOLEAN'],'defaultValue':!![]}),_0x35cb08[_0x2df7b9('0x2c')]('campaigns',_0x2df7b9('0x16'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x3)[_0x2df7b9('0x2a')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x2df7b9('0x13')}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x3b'),'dialAMDActive',{'type':_0x49a2a8[_0x2df7b9('0x4e')],'defaultValue':0x0,'comment':_0x2df7b9('0x44')}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x3b'),_0x2df7b9('0x14'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x9c4,'comment':_0x2df7b9('0x4a')}),_0x35cb08[_0x2df7b9('0x47')]('voice_queues','dialAMDGreeting',{'type':_0x49a2a8['INTEGER'](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x5dc,'comment':'#AMD\x20Greeting'}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x3b'),'dialAMDAfterGreetingSilence',{'type':_0x49a2a8['INTEGER'](0x9)['UNSIGNED'],'validate':{'min':0x0},'defaultValue':0x320,'comment':_0x2df7b9('0x45')}),_0x35cb08['addColumn'](_0x2df7b9('0x3b'),_0x2df7b9('0x40'),{'type':_0x49a2a8['INTEGER'](0x9)['UNSIGNED'],'validate':{'min':0x0},'defaultValue':0x1388,'comment':'#AMD\x20Total\x20Analysis\x20Time'}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x3b'),_0x2df7b9('0x41'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x9)['UNSIGNED'],'validate':{'min':0x0},'defaultValue':0x64,'comment':_0x2df7b9('0x25')}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x3b'),_0x2df7b9('0x8'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x32,'comment':'#AMD\x20Between\x20Words\x20Silence'}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x3b'),_0x2df7b9('0x2e'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x9)['UNSIGNED'],'validate':{'min':0x0},'defaultValue':0x3,'comment':_0x2df7b9('0x15')}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0x3b'),_0x2df7b9('0x35'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x5)[_0x2df7b9('0x2a')],'validate':{'min':0x0,'max':0x7fff},'defaultValue':0x100,'comment':'#AMD\x20Silence\x20Threshold\x20(min:0,\x20max:32767)'}),_0x35cb08[_0x2df7b9('0x47')]('voice_queues','dialAMDMaximumWordLength',{'type':_0x49a2a8['INTEGER'](0x9)['UNSIGNED'],'validate':{'min':0x0},'defaultValue':0x1388,'comment':_0x2df7b9('0x49')}),_0x35cb08[_0x2df7b9('0x47')]('campaigns',_0x2df7b9('0x1c'),{'type':_0x49a2a8[_0x2df7b9('0x4e')],'defaultValue':0x0,'comment':'Active/Disactive\x20AMD'}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0xc'),_0x2df7b9('0x14'),{'type':_0x49a2a8['INTEGER'](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x9c4,'comment':'#AMD\x20Initial\x20Silence'}),_0x35cb08[_0x2df7b9('0x47')]('campaigns',_0x2df7b9('0x20'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x5dc,'comment':_0x2df7b9('0x43')}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0xc'),_0x2df7b9('0x21'),{'type':_0x49a2a8['INTEGER'](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x320,'comment':'#AMD\x20After\x20Greeting\x20Silence'}),_0x35cb08[_0x2df7b9('0x47')]('campaigns',_0x2df7b9('0x40'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x1388,'comment':'#AMD\x20Total\x20Analysis\x20Time'}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0xc'),_0x2df7b9('0x41'),{'type':_0x49a2a8['INTEGER'](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x64,'comment':'#AMD\x20Min\x20Word\x20Length'}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0xc'),_0x2df7b9('0x8'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x32,'comment':'#AMD\x20Between\x20Words\x20Silence'}),_0x35cb08['addColumn'](_0x2df7b9('0xc'),_0x2df7b9('0x2e'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x3,'comment':'#AMD\x20Maximum\x20Number\x20Of\x20Words'}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0xc'),_0x2df7b9('0x35'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x5)[_0x2df7b9('0x2a')],'validate':{'min':0x0,'max':0x7fff},'defaultValue':0x100,'comment':_0x2df7b9('0x2')}),_0x35cb08[_0x2df7b9('0x47')](_0x2df7b9('0xc'),_0x2df7b9('0x2b'),{'type':_0x49a2a8[_0x2df7b9('0x3c')](0x9)[_0x2df7b9('0x2a')],'validate':{'min':0x0},'defaultValue':0x1388,'comment':_0x2df7b9('0x49')}),_0x35cb08['query']('DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20exten\x20=\x20\x27xcally-motion-dialer\x27;'),_0x35cb08['query'](_0x2df7b9('0x1a')),_0x35cb08[_0x2df7b9('0x3f')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x272\x27,\x20\x27set\x27,\x20\x27CDR(type)=dialer\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x35cb08[_0x2df7b9('0x3f')](_0x2df7b9('0x1f')),_0x35cb08[_0x2df7b9('0x3f')](_0x2df7b9('0x30')),_0x35cb08['query'](_0x2df7b9('0x4d')),_0x35cb08[_0x2df7b9('0x3f')](_0x2df7b9('0x31')),_0x35cb08['query'](_0x2df7b9('0x4b')),_0x35cb08[_0x2df7b9('0x3f')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x278\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22MACHINE\x22\x20]?11:9\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x35cb08[_0x2df7b9('0x3f')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x279\x27,\x20\x27execif\x27,\x20\x27$[\x22${XMD-AGI}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGI})\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x35cb08[_0x2df7b9('0x3f')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2710\x27,\x20\x27execif\x27,\x20\x27$[\x22${XMD-QUEUE}\x22\x20!=\x20\x22NONE\x22\x20]?QUEUE(${XMD-QUEUE})\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x35cb08[_0x2df7b9('0x3f')](_0x2df7b9('0x4')),_0x35cb08[_0x2df7b9('0xb')](_0x179f6f);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.30.js b/server/migrations/2.0.30.js index 079af4b..abc0c8b 100644 --- a/server/migrations/2.0.30.js +++ b/server/migrations/2.0.30.js @@ -1 +1 @@ -const a909_0x21c1=['query\x20%s','sequelize','join','migration','enqueue','finally','team_has_chat_queues','chat_interactions','UNSIGNED','addIndex','chat_applications','voice_queues','prototype','chat_queues','changeColumn','chat_websites','exports','chat_enquiries','addIndex\x20%s\x20%s\x20%s','user_has_chat_rooms','sequence','then','tail','Changed\x20column\x20%s\x20in\x20table\x20%s','catch','chat_websites_fields','table\x20dropped\x20%s','dialQueueTimeout','Queue\x20Timeout\x20Seconds\x20(min:1,\x20max:999)','queryInterface','stringify','info','INTEGER','user_has_chat_queues','query','user_has_chat_interactions','dropTable','chat_messages','chat_dispositions'];(function(_0x16b515,_0x21c188){const _0x432028=function(_0x5277e2){while(--_0x5277e2){_0x16b515['push'](_0x16b515['shift']());}};_0x432028(++_0x21c188);}(a909_0x21c1,0xc1));const a909_0x4320=function(_0x16b515,_0x21c188){_0x16b515=_0x16b515-0x0;let _0x432028=a909_0x21c1[_0x16b515];return _0x432028;};const _0x2e13a0=a909_0x4320;'use strict';const logger=require('../config/logger')(_0x2e13a0('0x5')),Sequence=function(){};Sequence[_0x2e13a0('0xe')][_0x2e13a0('0x6')]=function(_0x5277e2){const _0x1c653b=_0x2e13a0;this[_0x1c653b('0x18')]=this['tail']?this[_0x1c653b('0x18')][_0x1c653b('0x7')](_0x5277e2):_0x5277e2();};const Migration=function(_0x39d253){const _0x2b4d9e=_0x2e13a0;this[_0x2b4d9e('0x1f')]=_0x39d253,this[_0x2b4d9e('0x16')]=new Sequence();};Migration[_0x2e13a0('0xe')][_0x2e13a0('0x10')]=function(_0x1b7da1,_0x207ae9,_0x3170cb){const _0x11a24d=this;this['sequence']['enqueue'](function(){const _0x108221=a909_0x4320;return _0x11a24d[_0x108221('0x1f')]['changeColumn'](_0x1b7da1,_0x207ae9,_0x3170cb)[_0x108221('0x17')](function(){const _0x1c14f9=_0x108221;logger['info'](_0x1c14f9('0x19'),_0x207ae9,_0x1b7da1);})[_0x108221('0x1a')](function(_0x327ab8){const _0x59cda7=_0x108221;logger[_0x59cda7('0x21')](JSON[_0x59cda7('0x20')](_0x327ab8));});});},Migration[_0x2e13a0('0xe')]['addColumn']=function(_0x2fbb4d,_0x50b6e1,_0x2683e9){const _0x38bfa0=_0x2e13a0,_0x2d9ef0=this;this[_0x38bfa0('0x16')][_0x38bfa0('0x6')](function(){const _0x248af5=_0x38bfa0;return _0x2d9ef0[_0x248af5('0x1f')]['addColumn'](_0x2fbb4d,_0x50b6e1,_0x2683e9)[_0x248af5('0x17')](function(){const _0x4d4005=_0x248af5;logger[_0x4d4005('0x21')]('Added\x20column\x20%s\x20to\x20%s',_0x50b6e1,_0x2fbb4d);})[_0x248af5('0x1a')](function(_0x584ba4){const _0x5f0118=_0x248af5;logger[_0x5f0118('0x21')](JSON[_0x5f0118('0x20')](_0x584ba4));});});},Migration[_0x2e13a0('0xe')][_0x2e13a0('0x26')]=function(_0x231458){const _0xc43ae6=_0x2e13a0,_0x2254eb=this;this[_0xc43ae6('0x16')][_0xc43ae6('0x6')](function(){const _0x3e4e28=_0xc43ae6;return _0x2254eb[_0x3e4e28('0x1f')][_0x3e4e28('0x26')](_0x231458,{'force':!![]})['then'](function(){const _0x37f38a=_0x3e4e28;logger['info'](_0x37f38a('0x1c'),_0x231458);})[_0x3e4e28('0x1a')](function(_0x2f74fa){const _0xeb6751=_0x3e4e28;logger[_0xeb6751('0x21')](JSON[_0xeb6751('0x20')](_0x2f74fa));});});},Migration[_0x2e13a0('0xe')][_0x2e13a0('0xb')]=function(_0x3dce3e,_0x246052,_0x1c5c54){const _0xf63586=_0x2e13a0,_0x216856=this;this[_0xf63586('0x16')][_0xf63586('0x6')](function(){const _0x81941f=_0xf63586;return _0x216856[_0x81941f('0x1f')][_0x81941f('0xb')](_0x3dce3e,_0x246052,{'indexName':_0x1c5c54})[_0x81941f('0x17')](function(){const _0x1a734b=_0x81941f;logger[_0x1a734b('0x21')](_0x1a734b('0x14'),_0x3dce3e,_0x246052[_0x1a734b('0x4')](','),_0x1c5c54);})[_0x81941f('0x1a')](function(_0x1406c7){const _0x573f95=_0x81941f;logger[_0x573f95('0x21')](JSON['stringify'](_0x1406c7));});});},Migration[_0x2e13a0('0xe')][_0x2e13a0('0x24')]=function(_0x4db17b){const _0x1e4c17=_0x2e13a0,_0x53799d=this;this['sequence'][_0x1e4c17('0x6')](function(){const _0x2a5980=_0x1e4c17;return _0x53799d['queryInterface'][_0x2a5980('0x3')][_0x2a5980('0x24')](_0x4db17b)['then'](function(){const _0x27aabd=_0x2a5980;logger[_0x27aabd('0x21')](_0x27aabd('0x2'),_0x4db17b);})[_0x2a5980('0x1a')](function(_0x3f36c5){const _0xeb236a=_0x2a5980;logger[_0xeb236a('0x21')](JSON[_0xeb236a('0x20')](_0x3f36c5));});});},Migration['prototype']['final']=function(_0x499a8b){this['sequence']['enqueue'](function(){return _0x499a8b();});},module[_0x2e13a0('0x12')]={'up':function(_0x3067d6,_0x3a1460){return new Promise(function(_0x14e6d9){const _0x294602=a909_0x4320,_0x218042=new Migration(_0x3067d6);_0x218042[_0x294602('0x26')](_0x294602('0x15')),_0x218042[_0x294602('0x26')](_0x294602('0x13')),_0x218042[_0x294602('0x26')](_0x294602('0x0')),_0x218042[_0x294602('0x26')]('chat_proactive_actions'),_0x218042[_0x294602('0x26')](_0x294602('0x1')),_0x218042[_0x294602('0x26')](_0x294602('0xc')),_0x218042[_0x294602('0x26')](_0x294602('0x25')),_0x218042[_0x294602('0x26')](_0x294602('0x9')),_0x218042[_0x294602('0x26')](_0x294602('0x8')),_0x218042[_0x294602('0x26')](_0x294602('0x23')),_0x218042[_0x294602('0x26')](_0x294602('0xf')),_0x218042[_0x294602('0x26')]('chat_visitors'),_0x218042[_0x294602('0x26')](_0x294602('0x1b')),_0x218042['dropTable'](_0x294602('0x11')),_0x218042[_0x294602('0x10')](_0x294602('0xd'),_0x294602('0x1d'),{'type':_0x3a1460[_0x294602('0x22')](0x3)[_0x294602('0xa')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x294602('0x1e')}),_0x218042['final'](_0x14e6d9);});},'down':function(){}}; \ No newline at end of file +const a909_0x269f=['join','enqueue','queryInterface','final','stringify','chat_queues','voice_queues','chat_enquiries','finally','INTEGER','then','chat_messages','tail','user_has_chat_rooms','query\x20%s','catch','UNSIGNED','chat_interactions','addColumn','team_has_chat_queues','../config/logger','dialQueueTimeout','prototype','chat_proactive_actions','user_has_chat_queues','sequence','chat_websites','user_has_chat_interactions','addIndex','chat_dispositions','sequelize','chat_visitors','changeColumn','chat_applications','dropTable','query','migration','Queue\x20Timeout\x20Seconds\x20(min:1,\x20max:999)','info','Changed\x20column\x20%s\x20in\x20table\x20%s'];(function(_0x5e3723,_0x269f14){const _0x2c0547=function(_0x3aa7e6){while(--_0x3aa7e6){_0x5e3723['push'](_0x5e3723['shift']());}};_0x2c0547(++_0x269f14);}(a909_0x269f,0x179));const a909_0x2c05=function(_0x5e3723,_0x269f14){_0x5e3723=_0x5e3723-0x0;let _0x2c0547=a909_0x269f[_0x5e3723];return _0x2c0547;};const _0x568813=a909_0x2c05;'use strict';const logger=require(_0x568813('0x3'))(_0x568813('0x13')),Sequence=function(){};Sequence['prototype'][_0x568813('0x18')]=function(_0x3aa7e6){const _0x4ee20c=_0x568813;this[_0x4ee20c('0x23')]=this['tail']?this[_0x4ee20c('0x23')][_0x4ee20c('0x1f')](_0x3aa7e6):_0x3aa7e6();};const Migration=function(_0x270f36){this['queryInterface']=_0x270f36,this['sequence']=new Sequence();};Migration[_0x568813('0x5')][_0x568813('0xf')]=function(_0x15bc1f,_0x37fef1,_0x29f92e){const _0x417882=_0x568813,_0x58517b=this;this['sequence'][_0x417882('0x18')](function(){const _0x5f516e=_0x417882;return _0x58517b[_0x5f516e('0x19')][_0x5f516e('0xf')](_0x15bc1f,_0x37fef1,_0x29f92e)[_0x5f516e('0x21')](function(){const _0x4af4ee=_0x5f516e;logger[_0x4af4ee('0x15')](_0x4af4ee('0x16'),_0x37fef1,_0x15bc1f);})['catch'](function(_0x88322c){const _0x5395b6=_0x5f516e;logger[_0x5395b6('0x15')](JSON[_0x5395b6('0x1b')](_0x88322c));});});},Migration[_0x568813('0x5')][_0x568813('0x1')]=function(_0x2afc66,_0x384698,_0x286390){const _0x298378=_0x568813,_0x4e973f=this;this[_0x298378('0x8')][_0x298378('0x18')](function(){const _0x2701e7=_0x298378;return _0x4e973f[_0x2701e7('0x19')][_0x2701e7('0x1')](_0x2afc66,_0x384698,_0x286390)[_0x2701e7('0x21')](function(){const _0x34df32=_0x2701e7;logger[_0x34df32('0x15')]('Added\x20column\x20%s\x20to\x20%s',_0x384698,_0x2afc66);})[_0x2701e7('0x26')](function(_0x296a6e){const _0x1024a9=_0x2701e7;logger['info'](JSON[_0x1024a9('0x1b')](_0x296a6e));});});},Migration[_0x568813('0x5')][_0x568813('0x11')]=function(_0x43ed31){const _0x430275=_0x568813,_0x1ad84e=this;this[_0x430275('0x8')][_0x430275('0x18')](function(){const _0x5dce1a=_0x430275;return _0x1ad84e[_0x5dce1a('0x19')][_0x5dce1a('0x11')](_0x43ed31,{'force':!![]})[_0x5dce1a('0x21')](function(){logger['info']('table\x20dropped\x20%s',_0x43ed31);})[_0x5dce1a('0x26')](function(_0x130afb){const _0x19ee11=_0x5dce1a;logger[_0x19ee11('0x15')](JSON[_0x19ee11('0x1b')](_0x130afb));});});},Migration[_0x568813('0x5')][_0x568813('0xb')]=function(_0x39f3ab,_0x529743,_0x2460a5){const _0x1d98bd=_0x568813,_0x258510=this;this[_0x1d98bd('0x8')][_0x1d98bd('0x18')](function(){const _0xa5314f=_0x1d98bd;return _0x258510['queryInterface'][_0xa5314f('0xb')](_0x39f3ab,_0x529743,{'indexName':_0x2460a5})['then'](function(){const _0x3cd25b=_0xa5314f;logger[_0x3cd25b('0x15')]('addIndex\x20%s\x20%s\x20%s',_0x39f3ab,_0x529743[_0x3cd25b('0x17')](','),_0x2460a5);})[_0xa5314f('0x26')](function(_0x5df33c){const _0x34ff3b=_0xa5314f;logger[_0x34ff3b('0x15')](JSON[_0x34ff3b('0x1b')](_0x5df33c));});});},Migration[_0x568813('0x5')][_0x568813('0x12')]=function(_0x3dacdc){const _0x2c95c2=_0x568813,_0x393c4a=this;this[_0x2c95c2('0x8')][_0x2c95c2('0x18')](function(){const _0x44cc34=_0x2c95c2;return _0x393c4a[_0x44cc34('0x19')][_0x44cc34('0xd')][_0x44cc34('0x12')](_0x3dacdc)['then'](function(){const _0x184bbd=_0x44cc34;logger[_0x184bbd('0x15')](_0x184bbd('0x25'),_0x3dacdc);})[_0x44cc34('0x26')](function(_0x4bf549){const _0x48b5d9=_0x44cc34;logger[_0x48b5d9('0x15')](JSON[_0x48b5d9('0x1b')](_0x4bf549));});});},Migration[_0x568813('0x5')][_0x568813('0x1a')]=function(_0x5e7d28){const _0x34150c=_0x568813;this[_0x34150c('0x8')][_0x34150c('0x18')](function(){return _0x5e7d28();});},module['exports']={'up':function(_0x34bf44,_0x36593a){return new Promise(function(_0x243632){const _0x282f28=a909_0x2c05,_0x3802f9=new Migration(_0x34bf44);_0x3802f9[_0x282f28('0x11')](_0x282f28('0x24')),_0x3802f9[_0x282f28('0x11')](_0x282f28('0x1e')),_0x3802f9[_0x282f28('0x11')](_0x282f28('0x22')),_0x3802f9['dropTable'](_0x282f28('0x6')),_0x3802f9['dropTable'](_0x282f28('0xc')),_0x3802f9[_0x282f28('0x11')](_0x282f28('0x10')),_0x3802f9[_0x282f28('0x11')](_0x282f28('0xa')),_0x3802f9[_0x282f28('0x11')](_0x282f28('0x0')),_0x3802f9[_0x282f28('0x11')](_0x282f28('0x2')),_0x3802f9['dropTable'](_0x282f28('0x7')),_0x3802f9[_0x282f28('0x11')](_0x282f28('0x1c')),_0x3802f9[_0x282f28('0x11')](_0x282f28('0xe')),_0x3802f9['dropTable']('chat_websites_fields'),_0x3802f9[_0x282f28('0x11')](_0x282f28('0x9')),_0x3802f9[_0x282f28('0xf')](_0x282f28('0x1d'),_0x282f28('0x4'),{'type':_0x36593a[_0x282f28('0x20')](0x3)[_0x282f28('0x27')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x3e7},'comment':_0x282f28('0x14')}),_0x3802f9[_0x282f28('0x1a')](_0x243632);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.31.js b/server/migrations/2.0.31.js index e81aea3..c731546 100644 --- a/server/migrations/2.0.31.js +++ b/server/migrations/2.0.31.js @@ -1 +1 @@ -const a910_0x5661=['sms_accounts','twitter','users','sms_queues','user_has_sms_queues','Added\x20column\x20%s\x20to\x20%s','sms_dispositions','sms_applications','join','../config/logger','sms_messages','report_jscripty_answers','prototype','cm_contacts','transfertype','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x272\x27,\x20\x27set\x27,\x20\x27CDR(type)=dialer\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','enqueue','stringify','sequelize','sms_interactions','table\x20dropped\x20%s','STRING','exports','query','final','IntervalId','facebook','FORWARD,\x20BLIND,\x20ATTENDED','info','transferexten','finally','report_queue','transferuniqueid','Changed\x20column\x20%s\x20in\x20table\x20%s','report_jscripty_questions','team_has_sms_queues','addIndex','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x273\x27,\x20\x27set\x27,\x20\x27CALLERID(all)=${XMD-CALLERID}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','then','BOOLEAN','addColumn','catch','user_has_sms_interactions','chat_websites','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x274\x27,\x20\x27dial\x27,\x20\x27${XMD-DIALCHANNEL},${XMD-DIALTIMEOUT},${XMD-DIALOPTIONS},${XMD-DIALURL}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','changeColumn','tail','sequence','query\x20%s','INTEGER','dropTable','queryInterface'];(function(_0x376424,_0x5661c3){const _0x32d336=function(_0x457d65){while(--_0x457d65){_0x376424['push'](_0x376424['shift']());}};_0x32d336(++_0x5661c3);}(a910_0x5661,0xf3));const a910_0x32d3=function(_0x376424,_0x5661c3){_0x376424=_0x376424-0x0;let _0x32d336=a910_0x5661[_0x376424];return _0x32d336;};const _0x1b39ff=a910_0x32d3;'use strict';const logger=require(_0x1b39ff('0x1a'))('migration'),Sequence=function(){};Sequence[_0x1b39ff('0x1d')][_0x1b39ff('0x21')]=function(_0x457d65){const _0x2128cb=_0x1b39ff;this[_0x2128cb('0xb')]=this['tail']?this[_0x2128cb('0xb')][_0x2128cb('0x2f')](_0x457d65):_0x457d65();};const Migration=function(_0x551c8a){const _0x134e18=_0x1b39ff;this[_0x134e18('0x10')]=_0x551c8a,this[_0x134e18('0xc')]=new Sequence();};Migration['prototype'][_0x1b39ff('0xa')]=function(_0x59a3e6,_0x35c0a3,_0x289180){const _0x55e634=_0x1b39ff,_0x3dc601=this;this[_0x55e634('0xc')][_0x55e634('0x21')](function(){const _0x2968ed=_0x55e634;return _0x3dc601[_0x2968ed('0x10')][_0x2968ed('0xa')](_0x59a3e6,_0x35c0a3,_0x289180)['then'](function(){const _0x41f040=_0x2968ed;logger[_0x41f040('0x2d')](_0x41f040('0x32'),_0x35c0a3,_0x59a3e6);})[_0x2968ed('0x6')](function(_0x59f7d1){const _0x151b17=_0x2968ed;logger[_0x151b17('0x2d')](JSON[_0x151b17('0x22')](_0x59f7d1));});});},Migration[_0x1b39ff('0x1d')][_0x1b39ff('0x5')]=function(_0x3a4c06,_0x403932,_0x319754){const _0x3e20c0=_0x1b39ff,_0x336f31=this;this[_0x3e20c0('0xc')][_0x3e20c0('0x21')](function(){const _0x14e9ee=_0x3e20c0;return _0x336f31[_0x14e9ee('0x10')]['addColumn'](_0x3a4c06,_0x403932,_0x319754)[_0x14e9ee('0x3')](function(){const _0x75aaa6=_0x14e9ee;logger['info'](_0x75aaa6('0x16'),_0x403932,_0x3a4c06);})[_0x14e9ee('0x6')](function(_0x69aa8f){logger['info'](JSON['stringify'](_0x69aa8f));});});},Migration[_0x1b39ff('0x1d')][_0x1b39ff('0xf')]=function(_0x1090fb){const _0x38003f=_0x1b39ff,_0x318961=this;this['sequence'][_0x38003f('0x21')](function(){const _0x1d283c=_0x38003f;return _0x318961[_0x1d283c('0x10')][_0x1d283c('0xf')](_0x1090fb,{'force':!![]})['then'](function(){const _0x13068a=_0x1d283c;logger[_0x13068a('0x2d')](_0x13068a('0x25'),_0x1090fb);})['catch'](function(_0x338a36){const _0x13dda8=_0x1d283c;logger['info'](JSON[_0x13dda8('0x22')](_0x338a36));});});},Migration[_0x1b39ff('0x1d')][_0x1b39ff('0x1')]=function(_0x32d375,_0x5f2dd6,_0xa56f1f){const _0x1aeae1=_0x1b39ff,_0x1e14dd=this;this[_0x1aeae1('0xc')]['enqueue'](function(){const _0x50f97e=_0x1aeae1;return _0x1e14dd[_0x50f97e('0x10')][_0x50f97e('0x1')](_0x32d375,_0x5f2dd6,{'indexName':_0xa56f1f})['then'](function(){const _0xe8d3e0=_0x50f97e;logger[_0xe8d3e0('0x2d')]('addIndex\x20%s\x20%s\x20%s',_0x32d375,_0x5f2dd6[_0xe8d3e0('0x19')](','),_0xa56f1f);})[_0x50f97e('0x6')](function(_0x1155f7){const _0x92b308=_0x50f97e;logger['info'](JSON[_0x92b308('0x22')](_0x1155f7));});});},Migration[_0x1b39ff('0x1d')][_0x1b39ff('0x28')]=function(_0x4eb3c4){const _0x403251=this;this['sequence']['enqueue'](function(){const _0x3403dd=a910_0x32d3;return _0x403251['queryInterface'][_0x3403dd('0x23')][_0x3403dd('0x28')](_0x4eb3c4)[_0x3403dd('0x3')](function(){const _0x1afdd9=_0x3403dd;logger['info'](_0x1afdd9('0xd'),_0x4eb3c4);})['catch'](function(_0x45957c){const _0x18fb17=_0x3403dd;logger[_0x18fb17('0x2d')](JSON[_0x18fb17('0x22')](_0x45957c));});});},Migration[_0x1b39ff('0x1d')][_0x1b39ff('0x29')]=function(_0x5dc1f0){const _0x17981d=_0x1b39ff;this['sequence'][_0x17981d('0x21')](function(){return _0x5dc1f0();});},module[_0x1b39ff('0x27')]={'up':function(_0x41f49d,_0x259031){return new Promise(function(_0xe68f45){const _0x2961da=a910_0x32d3,_0x279cff=new Migration(_0x41f49d);_0x279cff[_0x2961da('0xf')](_0x2961da('0x1b')),_0x279cff['dropTable'](_0x2961da('0x17')),_0x279cff[_0x2961da('0xf')](_0x2961da('0x18')),_0x279cff['dropTable'](_0x2961da('0x7')),_0x279cff[_0x2961da('0xf')](_0x2961da('0x24')),_0x279cff[_0x2961da('0xf')](_0x2961da('0x0')),_0x279cff[_0x2961da('0xf')](_0x2961da('0x15')),_0x279cff[_0x2961da('0xf')](_0x2961da('0x14')),_0x279cff[_0x2961da('0xf')](_0x2961da('0x11')),_0x279cff[_0x2961da('0x5')]('cm_contacts',_0x2961da('0x2b'),{'type':_0x259031[_0x2961da('0x26')]}),_0x279cff[_0x2961da('0x5')](_0x2961da('0x1e'),_0x2961da('0x12'),{'type':_0x259031[_0x2961da('0x26')]}),_0x279cff[_0x2961da('0x28')]('ALTER\x20TABLE\x20chat_websites\x20DROP\x20FOREIGN\x20KEY\x20chat_websites_ibfk_2'),_0x279cff['query']('ALTER\x20TABLE\x20chat_websites\x20DROP\x20COLUMN\x20OfflineTemplateId'),_0x279cff[_0x2961da('0x5')]('chat_websites','timezone',{'type':_0x259031[_0x2961da('0x26')]}),_0x279cff[_0x2961da('0x5')](_0x2961da('0x8'),'token',{'type':_0x259031[_0x2961da('0x26')]}),_0x279cff[_0x2961da('0x5')](_0x2961da('0x8'),_0x2961da('0x2a'),{'type':_0x259031[_0x2961da('0xe')](0xb)}),_0x279cff[_0x2961da('0x28')]('ALTER\x20TABLE\x20chat_websites\x20ADD\x20CONSTRAINT\x20chat_websites_ibfk_2\x20FOREIGN\x20KEY\x20(IntervalId)\x20REFERENCES\x20tools_intervals(id)\x20ON\x20UPDATE\x20CASCADE\x20ON\x20DELETE\x20SET\x20NULL'),_0x279cff['addColumn'](_0x2961da('0x30'),'transfer',{'type':_0x259031[_0x2961da('0x4')],'defaultValue':![]}),_0x279cff[_0x2961da('0x5')](_0x2961da('0x30'),_0x2961da('0x1f'),{'type':_0x259031[_0x2961da('0x26')],'comment':_0x2961da('0x2c')}),_0x279cff[_0x2961da('0x5')](_0x2961da('0x30'),_0x2961da('0x2e'),{'type':_0x259031[_0x2961da('0x26')]}),_0x279cff[_0x2961da('0x5')]('report_queue',_0x2961da('0x31'),{'type':_0x259031['STRING']}),_0x279cff['addColumn'](_0x2961da('0x1c'),'questionId',{'type':_0x259031['STRING']}),_0x279cff[_0x2961da('0x5')](_0x2961da('0x33'),'questionId',{'type':_0x259031[_0x2961da('0x26')]}),_0x279cff[_0x2961da('0x5')](_0x2961da('0x13'),'phoneBarUnansweredCallBadge',{'type':_0x259031[_0x2961da('0x4')],'defaultValue':!![]}),_0x279cff['query']('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x279cff[_0x2961da('0x28')](_0x2961da('0x20')),_0x279cff[_0x2961da('0x28')](_0x2961da('0x2')),_0x279cff['query'](_0x2961da('0x9')),_0x279cff[_0x2961da('0x28')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x275\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x279cff[_0x2961da('0x29')](_0xe68f45);});},'down':function(){}}; \ No newline at end of file +const a910_0x2878=['queryInterface','stringify','user_has_sms_interactions','INTEGER','changeColumn','sms_queues','catch','STRING','transferexten','exports','transfertype','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x274\x27,\x20\x27dial\x27,\x20\x27${XMD-DIALCHANNEL},${XMD-DIALTIMEOUT},${XMD-DIALOPTIONS},${XMD-DIALURL}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x275\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','prototype','transferuniqueid','token','report_jscripty_questions','table\x20dropped\x20%s','dropTable','Added\x20column\x20%s\x20to\x20%s','twitter','BOOLEAN','final','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x273\x27,\x20\x27set\x27,\x20\x27CALLERID(all)=${XMD-CALLERID}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','sms_messages','ALTER\x20TABLE\x20chat_websites\x20DROP\x20COLUMN\x20OfflineTemplateId','user_has_sms_queues','users','join','Changed\x20column\x20%s\x20in\x20table\x20%s','report_queue','sequence','addIndex','enqueue','addColumn','cm_contacts','tail','chat_websites','info','query\x20%s','sms_accounts','then','query','transfer','../config/logger','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x272\x27,\x20\x27set\x27,\x20\x27CDR(type)=dialer\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','FORWARD,\x20BLIND,\x20ATTENDED','questionId'];(function(_0x19aaa4,_0x2878a0){const _0xb732d6=function(_0x5270f3){while(--_0x5270f3){_0x19aaa4['push'](_0x19aaa4['shift']());}};_0xb732d6(++_0x2878a0);}(a910_0x2878,0x1e4));const a910_0xb732=function(_0x19aaa4,_0x2878a0){_0x19aaa4=_0x19aaa4-0x0;let _0xb732d6=a910_0x2878[_0x19aaa4];return _0xb732d6;};const _0xe9b8b4=a910_0xb732;'use strict';const logger=require(_0xe9b8b4('0x28'))('migration'),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x5270f3){const _0x59869e=_0xe9b8b4;this[_0x59869e('0x20')]=this[_0x59869e('0x20')]?this[_0x59869e('0x20')]['finally'](_0x5270f3):_0x5270f3();};const Migration=function(_0x2b96dc){const _0x1357d2=_0xe9b8b4;this[_0x1357d2('0x2c')]=_0x2b96dc,this['sequence']=new Sequence();};Migration['prototype'][_0xe9b8b4('0x0')]=function(_0x4c2fc9,_0x3be719,_0x2c899b){const _0x25d38d=_0xe9b8b4,_0x584344=this;this[_0x25d38d('0x1b')][_0x25d38d('0x1d')](function(){const _0x386054=_0x25d38d;return _0x584344['queryInterface']['changeColumn'](_0x4c2fc9,_0x3be719,_0x2c899b)[_0x386054('0x25')](function(){const _0x363c98=_0x386054;logger[_0x363c98('0x22')](_0x363c98('0x19'),_0x3be719,_0x4c2fc9);})['catch'](function(_0x3803bf){const _0x49ddb6=_0x386054;logger[_0x49ddb6('0x22')](JSON['stringify'](_0x3803bf));});});},Migration[_0xe9b8b4('0x9')][_0xe9b8b4('0x1e')]=function(_0xaa5881,_0x587999,_0x10d161){const _0x381dad=_0xe9b8b4,_0x5187d7=this;this[_0x381dad('0x1b')][_0x381dad('0x1d')](function(){const _0x57e03d=_0x381dad;return _0x5187d7[_0x57e03d('0x2c')][_0x57e03d('0x1e')](_0xaa5881,_0x587999,_0x10d161)[_0x57e03d('0x25')](function(){const _0x4c3c69=_0x57e03d;logger['info'](_0x4c3c69('0xf'),_0x587999,_0xaa5881);})[_0x57e03d('0x2')](function(_0x330ac3){const _0x1b18b7=_0x57e03d;logger[_0x1b18b7('0x22')](JSON[_0x1b18b7('0x2d')](_0x330ac3));});});},Migration['prototype'][_0xe9b8b4('0xe')]=function(_0x49c12d){const _0x1bf739=_0xe9b8b4,_0x205d6f=this;this[_0x1bf739('0x1b')]['enqueue'](function(){const _0x85c4ec=_0x1bf739;return _0x205d6f[_0x85c4ec('0x2c')]['dropTable'](_0x49c12d,{'force':!![]})[_0x85c4ec('0x25')](function(){const _0x58efbd=_0x85c4ec;logger['info'](_0x58efbd('0xd'),_0x49c12d);})['catch'](function(_0x445f1b){const _0x40bcd8=_0x85c4ec;logger[_0x40bcd8('0x22')](JSON[_0x40bcd8('0x2d')](_0x445f1b));});});},Migration[_0xe9b8b4('0x9')][_0xe9b8b4('0x1c')]=function(_0x340d04,_0x3be246,_0x1f3938){const _0xcf768c=_0xe9b8b4,_0x5d7158=this;this[_0xcf768c('0x1b')][_0xcf768c('0x1d')](function(){const _0x5f1911=_0xcf768c;return _0x5d7158[_0x5f1911('0x2c')][_0x5f1911('0x1c')](_0x340d04,_0x3be246,{'indexName':_0x1f3938})[_0x5f1911('0x25')](function(){const _0x13c048=_0x5f1911;logger[_0x13c048('0x22')]('addIndex\x20%s\x20%s\x20%s',_0x340d04,_0x3be246[_0x13c048('0x18')](','),_0x1f3938);})[_0x5f1911('0x2')](function(_0x5c42b3){const _0x32a4fb=_0x5f1911;logger[_0x32a4fb('0x22')](JSON[_0x32a4fb('0x2d')](_0x5c42b3));});});},Migration[_0xe9b8b4('0x9')][_0xe9b8b4('0x26')]=function(_0x5c846d){const _0x2d3ed8=_0xe9b8b4,_0x4efe08=this;this[_0x2d3ed8('0x1b')][_0x2d3ed8('0x1d')](function(){const _0x39854a=_0x2d3ed8;return _0x4efe08[_0x39854a('0x2c')]['sequelize'][_0x39854a('0x26')](_0x5c846d)[_0x39854a('0x25')](function(){const _0x3519aa=_0x39854a;logger['info'](_0x3519aa('0x23'),_0x5c846d);})['catch'](function(_0x411e4e){const _0xc9c048=_0x39854a;logger[_0xc9c048('0x22')](JSON[_0xc9c048('0x2d')](_0x411e4e));});});},Migration['prototype'][_0xe9b8b4('0x12')]=function(_0x9a8a4f){const _0x11b77e=_0xe9b8b4;this[_0x11b77e('0x1b')][_0x11b77e('0x1d')](function(){return _0x9a8a4f();});},module[_0xe9b8b4('0x5')]={'up':function(_0x4f875c,_0x3972b9){return new Promise(function(_0x5eb49d){const _0x154a6e=a910_0xb732,_0x1dec17=new Migration(_0x4f875c);_0x1dec17[_0x154a6e('0xe')](_0x154a6e('0x14')),_0x1dec17['dropTable']('sms_dispositions'),_0x1dec17[_0x154a6e('0xe')]('sms_applications'),_0x1dec17[_0x154a6e('0xe')](_0x154a6e('0x2e')),_0x1dec17[_0x154a6e('0xe')]('sms_interactions'),_0x1dec17[_0x154a6e('0xe')]('team_has_sms_queues'),_0x1dec17['dropTable'](_0x154a6e('0x16')),_0x1dec17[_0x154a6e('0xe')](_0x154a6e('0x1')),_0x1dec17[_0x154a6e('0xe')](_0x154a6e('0x24')),_0x1dec17['addColumn'](_0x154a6e('0x1f'),'facebook',{'type':_0x3972b9[_0x154a6e('0x3')]}),_0x1dec17[_0x154a6e('0x1e')]('cm_contacts',_0x154a6e('0x10'),{'type':_0x3972b9[_0x154a6e('0x3')]}),_0x1dec17[_0x154a6e('0x26')]('ALTER\x20TABLE\x20chat_websites\x20DROP\x20FOREIGN\x20KEY\x20chat_websites_ibfk_2'),_0x1dec17[_0x154a6e('0x26')](_0x154a6e('0x15')),_0x1dec17[_0x154a6e('0x1e')](_0x154a6e('0x21'),'timezone',{'type':_0x3972b9['STRING']}),_0x1dec17[_0x154a6e('0x1e')](_0x154a6e('0x21'),_0x154a6e('0xb'),{'type':_0x3972b9[_0x154a6e('0x3')]}),_0x1dec17[_0x154a6e('0x1e')](_0x154a6e('0x21'),'IntervalId',{'type':_0x3972b9[_0x154a6e('0x2f')](0xb)}),_0x1dec17[_0x154a6e('0x26')]('ALTER\x20TABLE\x20chat_websites\x20ADD\x20CONSTRAINT\x20chat_websites_ibfk_2\x20FOREIGN\x20KEY\x20(IntervalId)\x20REFERENCES\x20tools_intervals(id)\x20ON\x20UPDATE\x20CASCADE\x20ON\x20DELETE\x20SET\x20NULL'),_0x1dec17['addColumn'](_0x154a6e('0x1a'),_0x154a6e('0x27'),{'type':_0x3972b9['BOOLEAN'],'defaultValue':![]}),_0x1dec17[_0x154a6e('0x1e')](_0x154a6e('0x1a'),_0x154a6e('0x6'),{'type':_0x3972b9[_0x154a6e('0x3')],'comment':_0x154a6e('0x2a')}),_0x1dec17[_0x154a6e('0x1e')](_0x154a6e('0x1a'),_0x154a6e('0x4'),{'type':_0x3972b9[_0x154a6e('0x3')]}),_0x1dec17[_0x154a6e('0x1e')]('report_queue',_0x154a6e('0xa'),{'type':_0x3972b9['STRING']}),_0x1dec17[_0x154a6e('0x1e')]('report_jscripty_answers',_0x154a6e('0x2b'),{'type':_0x3972b9[_0x154a6e('0x3')]}),_0x1dec17[_0x154a6e('0x1e')](_0x154a6e('0xc'),_0x154a6e('0x2b'),{'type':_0x3972b9[_0x154a6e('0x3')]}),_0x1dec17[_0x154a6e('0x1e')](_0x154a6e('0x17'),'phoneBarUnansweredCallBadge',{'type':_0x3972b9[_0x154a6e('0x11')],'defaultValue':!![]}),_0x1dec17[_0x154a6e('0x26')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x1dec17[_0x154a6e('0x26')](_0x154a6e('0x29')),_0x1dec17[_0x154a6e('0x26')](_0x154a6e('0x13')),_0x1dec17['query'](_0x154a6e('0x7')),_0x1dec17['query'](_0x154a6e('0x8')),_0x1dec17['final'](_0x5eb49d);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.32.js b/server/migrations/2.0.32.js index 12143c4..b62df7c 100644 --- a/server/migrations/2.0.32.js +++ b/server/migrations/2.0.32.js @@ -1 +1 @@ -'use strict';module['exports']={'up':function(){},'down':function(){}}; \ No newline at end of file +var a911_0x72b3=['exports'];(function(_0x3c2b8d,_0x72b375){var _0x10c175=function(_0x2ea736){while(--_0x2ea736){_0x3c2b8d['push'](_0x3c2b8d['shift']());}};_0x10c175(++_0x72b375);}(a911_0x72b3,0xd8));var a911_0x10c1=function(_0x3c2b8d,_0x72b375){_0x3c2b8d=_0x3c2b8d-0x0;var _0x10c175=a911_0x72b3[_0x3c2b8d];return _0x10c175;};var _0x541179=a911_0x10c1;'use strict';module[_0x541179('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.33.js b/server/migrations/2.0.33.js index 3953e1a..bde68b9 100644 --- a/server/migrations/2.0.33.js +++ b/server/migrations/2.0.33.js @@ -1 +1 @@ -const a912_0x22f6=['fax_dispositions','thumb','sms_messages','then','forwardTranscript','timeout','addIndex','util','chat_websites','exports','mapKeyOffline','catch','inspect','fax_applications','info','actions','closingMessage','fax_messages','enqueue','Changed\x20column\x20%s\x20in\x20table\x20%s','user_has_openchannel_queues','sitepic','user_has_fax_interactions','star','ratingType','finally','Send','color_button','cm_hopper','queue','Removed\x20column\x20%s\x20from\x20%s','enableRating','closeUrl','INTEGER','agentAlias','ratingValue','BOOLEAN','fidelity','STRING','rejectMethod','chat_interactions','Added\x20column\x20%s\x20to\x20%s','closeMethod','query','tail','removeColumn','changeColumn','migration','TEXT','sequence','team_has_fax_queues','join','prototype','stringify','forwardOffline','addColumn','sequelize','Agent','user_has_fax_rooms','color','queryInterface','fax_accounts','mailTranscript','user_has_fax_queues','table\x20dropped\x20%s','closingMessageButton','assigned','fax_rooms','acceptUrl','UNSIGNED','#9f946a','priority','query\x20%s','dropTable'];(function(_0x449e21,_0x22f671){const _0xbdc44=function(_0x523117){while(--_0x523117){_0x449e21['push'](_0x449e21['shift']());}};_0xbdc44(++_0x22f671);}(a912_0x22f6,0xcd));const a912_0xbdc4=function(_0x449e21,_0x22f671){_0x449e21=_0x449e21-0x0;let _0xbdc44=a912_0x22f6[_0x449e21];return _0xbdc44;};const _0x1f1be9=a912_0xbdc4;'use strict';const logger=require('../config/logger')(_0x1f1be9('0x40')),util=require(_0x1f1be9('0x18')),Sequence=function(){};Sequence[_0x1f1be9('0x45')][_0x1f1be9('0x23')]=function(_0x523117){const _0x26372=_0x1f1be9;this[_0x26372('0x3d')]=this[_0x26372('0x3d')]?this[_0x26372('0x3d')][_0x26372('0x2a')](_0x523117):_0x523117();};const Migration=function(_0x18a03e){const _0x1e9761=_0x1f1be9;this[_0x1e9761('0x3')]=_0x18a03e,this[_0x1e9761('0x42')]=new Sequence();};Migration[_0x1f1be9('0x45')]['changeColumn']=function(_0x218e05,_0x4b2a94,_0xe58283){const _0x5e9473=_0x1f1be9,_0x9eda12=this;this[_0x5e9473('0x42')]['enqueue'](function(){const _0x2d09cc=_0x5e9473;return _0x9eda12[_0x2d09cc('0x3')][_0x2d09cc('0x3f')](_0x218e05,_0x4b2a94,_0xe58283)[_0x2d09cc('0x14')](function(){const _0x35620b=_0x2d09cc;logger[_0x35620b('0x1f')](_0x35620b('0x24'),_0x4b2a94,_0x218e05);})[_0x2d09cc('0x1c')](function(_0x3b9063){const _0x225f89=_0x2d09cc;logger[_0x225f89('0x1f')](JSON[_0x225f89('0x46')](_0x3b9063));});});},Migration[_0x1f1be9('0x45')][_0x1f1be9('0x48')]=function(_0x2edb12,_0x4bdeb3,_0x2ae0ba){const _0x109ddf=_0x1f1be9,_0x13b7d2=this;this[_0x109ddf('0x42')][_0x109ddf('0x23')](function(){const _0x4e7133=_0x109ddf;return _0x13b7d2[_0x4e7133('0x3')][_0x4e7133('0x48')](_0x2edb12,_0x4bdeb3,_0x2ae0ba)[_0x4e7133('0x14')](function(){const _0xa7ca9b=_0x4e7133;logger[_0xa7ca9b('0x1f')](_0xa7ca9b('0x3a'),_0x4bdeb3,_0x2edb12);})[_0x4e7133('0x1c')](function(_0x1f8e10){logger['info'](JSON['stringify'](_0x1f8e10));});});},Migration[_0x1f1be9('0x45')]['dropTable']=function(_0x135714){const _0x53ee36=this;this['sequence']['enqueue'](function(){const _0x586ebd=a912_0xbdc4;return _0x53ee36[_0x586ebd('0x3')][_0x586ebd('0x10')](_0x135714,{'force':!![]})['then'](function(){const _0x4bd481=_0x586ebd;logger['info'](_0x4bd481('0x7'),_0x135714);})['catch'](function(_0xbff14b){const _0x130271=_0x586ebd;logger[_0x130271('0x1f')](JSON[_0x130271('0x46')](_0xbff14b));});});},Migration[_0x1f1be9('0x45')][_0x1f1be9('0x17')]=function(_0x38a852,_0x2ed7f3,_0x2e3ee1){const _0x2d9130=_0x1f1be9,_0x2cd3bc=this;this['sequence'][_0x2d9130('0x23')](function(){const _0x63d401=_0x2d9130;return _0x2cd3bc[_0x63d401('0x3')]['addIndex'](_0x38a852,_0x2ed7f3,{'indexName':_0x2e3ee1})[_0x63d401('0x14')](function(){const _0x5c7c85=_0x63d401;logger[_0x5c7c85('0x1f')]('addIndex\x20%s\x20%s\x20%s',_0x38a852,_0x2ed7f3[_0x5c7c85('0x44')](','),_0x2e3ee1);})[_0x63d401('0x1c')](function(_0x30ccb9){logger['info'](JSON['stringify'](_0x30ccb9));});});},Migration[_0x1f1be9('0x45')][_0x1f1be9('0x3c')]=function(_0x10f40f){const _0x21b91e=_0x1f1be9,_0xf834a0=this;this[_0x21b91e('0x42')][_0x21b91e('0x23')](function(){const _0x32f96e=_0x21b91e;return _0xf834a0[_0x32f96e('0x3')][_0x32f96e('0x49')]['query'](_0x10f40f)[_0x32f96e('0x14')](function(){const _0x3d9f67=_0x32f96e;logger[_0x3d9f67('0x1f')](_0x3d9f67('0xf'),_0x10f40f);})[_0x32f96e('0x1c')](function(_0x196f95){const _0x3d63a4=_0x32f96e;logger[_0x3d63a4('0x1f')](JSON[_0x3d63a4('0x46')](_0x196f95));});});},Migration['prototype']['removeColumn']=function(_0x2cfa85,_0x4693d8){const _0xdf6f23=_0x1f1be9,_0x3e1fe8=this;this[_0xdf6f23('0x42')][_0xdf6f23('0x23')](function(){const _0x50b8e4=_0xdf6f23;return _0x3e1fe8['queryInterface'][_0x50b8e4('0x3e')](_0x2cfa85,_0x4693d8)['then'](function(){const _0x410649=_0x50b8e4;logger[_0x410649('0x1f')](_0x410649('0x2f'),_0x4693d8,_0x2cfa85);})[_0x50b8e4('0x1c')](function(_0x541dc1){const _0x2a0cf9=_0x50b8e4;logger[_0x2a0cf9('0x1f')](util[_0x2a0cf9('0x1d')](_0x541dc1,{'showHidden':![],'depth':null}));});});},Migration[_0x1f1be9('0x45')]['final']=function(_0x540132){const _0xc5c43c=_0x1f1be9;this[_0xc5c43c('0x42')][_0xc5c43c('0x23')](function(){return _0x540132();});},module[_0x1f1be9('0x1a')]={'up':function(_0x3fe40d,_0x3b66e5){return new Promise(function(_0x2bba54){const _0x308e66=a912_0xbdc4,_0xc592b7=new Migration(_0x3fe40d);_0xc592b7['addColumn'](_0x308e66('0x19'),_0x308e66('0x33'),{'type':_0x3b66e5['STRING'],'defaultValue':_0x308e66('0x0')}),_0xc592b7[_0x308e66('0x48')]('chat_websites',_0x308e66('0x1b'),{'type':_0x3b66e5[_0x308e66('0x37')],'defaultValue':'email'}),_0xc592b7[_0x308e66('0x48')](_0x308e66('0x19'),_0x308e66('0x26'),{'type':_0x3b66e5['TEXT']}),_0xc592b7[_0x308e66('0x48')](_0x308e66('0x19'),_0x308e66('0x21'),{'type':_0x3b66e5[_0x308e66('0x41')]}),_0xc592b7[_0x308e66('0x48')]('chat_websites',_0x308e66('0x8'),{'type':_0x3b66e5['STRING'],'defaultValue':_0x308e66('0x2b')}),_0xc592b7[_0x308e66('0x48')](_0x308e66('0x19'),_0x308e66('0x30'),{'type':_0x3b66e5['BOOLEAN'],'defaultValue':![]}),_0xc592b7[_0x308e66('0x48')]('chat_websites',_0x308e66('0x29'),{'type':_0x3b66e5['ENUM'](_0x308e66('0x28'),_0x308e66('0x12')),'defaultValue':_0x308e66('0x28')}),_0xc592b7['addColumn'](_0x308e66('0x19'),'ratingStarsNumber',{'type':_0x3b66e5[_0x308e66('0x32')],'defaultValue':0x5}),_0xc592b7[_0x308e66('0x48')](_0x308e66('0x39'),_0x308e66('0x34'),{'type':_0x3b66e5[_0x308e66('0x32')]}),_0xc592b7['addColumn'](_0x308e66('0x39'),'ratingMessage',{'type':_0x3b66e5[_0x308e66('0x41')]}),_0xc592b7['addColumn'](_0x308e66('0x39'),'pathTranscript',{'type':_0x3b66e5[_0x308e66('0x41')]}),_0xc592b7['addColumn'](_0x308e66('0x39'),_0x308e66('0x5'),{'type':_0x3b66e5[_0x308e66('0x37')]}),_0xc592b7['addColumn'](_0x308e66('0x19'),_0x308e66('0x15'),{'type':_0x3b66e5[_0x308e66('0x35')],'defaultValue':![]}),_0xc592b7['addColumn']('chat_websites',_0x308e66('0x47'),{'type':_0x3b66e5[_0x308e66('0x35')],'defaultValue':![]}),_0xc592b7[_0x308e66('0x48')]('chat_websites','forwardOfflineAddress',{'type':_0x3b66e5['STRING'],'validate':{'isEmail':!![]}}),_0xc592b7[_0x308e66('0x3f')](_0x308e66('0x19'),_0x308e66('0x2'),{'type':_0x3b66e5['STRING'],'allowNull':![],'defaultValue':_0x308e66('0xd')}),_0xc592b7['changeColumn'](_0x308e66('0x19'),_0x308e66('0x2c'),{'type':_0x3b66e5['STRING'],'allowNull':![],'defaultValue':_0x308e66('0xd')}),_0xc592b7['dropTable']('fax_attachments'),_0xc592b7[_0x308e66('0x10')](_0x308e66('0x1')),_0xc592b7[_0x308e66('0x10')](_0x308e66('0xa')),_0xc592b7[_0x308e66('0x10')](_0x308e66('0x22')),_0xc592b7['dropTable'](_0x308e66('0x11')),_0xc592b7[_0x308e66('0x10')](_0x308e66('0x1e')),_0xc592b7[_0x308e66('0x10')](_0x308e66('0x27')),_0xc592b7['dropTable']('fax_interactions'),_0xc592b7[_0x308e66('0x10')](_0x308e66('0x43')),_0xc592b7['dropTable'](_0x308e66('0x6')),_0xc592b7[_0x308e66('0x10')]('fax_queues'),_0xc592b7['removeColumn'](_0x308e66('0x4'),_0x308e66('0x36')),_0xc592b7[_0x308e66('0x3e')](_0x308e66('0x4'),_0x308e66('0x16')),_0xc592b7['removeColumn'](_0x308e66('0x4'),_0x308e66('0xb')),_0xc592b7[_0x308e66('0x3e')](_0x308e66('0x4'),'rejectUrl'),_0xc592b7[_0x308e66('0x3e')](_0x308e66('0x4'),'acceptMethod'),_0xc592b7['removeColumn']('fax_accounts',_0x308e66('0x38')),_0xc592b7[_0x308e66('0x3e')](_0x308e66('0x4'),_0x308e66('0x20')),_0xc592b7['removeColumn'](_0x308e66('0x4'),_0x308e66('0x31')),_0xc592b7['removeColumn']('fax_accounts',_0x308e66('0x3b')),_0xc592b7['removeColumn']('user_has_chat_queues',_0x308e66('0x9')),_0xc592b7['removeColumn']('user_has_chat_queues',_0x308e66('0x2e')),_0xc592b7[_0x308e66('0x3e')](_0x308e66('0x25'),_0x308e66('0x9')),_0xc592b7[_0x308e66('0x3e')](_0x308e66('0x25'),_0x308e66('0x2e')),_0xc592b7[_0x308e66('0x48')]('cm_hopper',_0x308e66('0xe'),{'type':_0x3b66e5[_0x308e66('0x32')](0x2)[_0x308e66('0xc')],'defaultValue':0x2}),_0xc592b7[_0x308e66('0x17')](_0x308e66('0x2d'),['priority'],_0x308e66('0xe')),_0xc592b7[_0x308e66('0x10')](_0x308e66('0x13')),_0xc592b7['final'](_0x2bba54);});},'down':function(){}}; \ No newline at end of file +const a912_0x3dd5=['chat_interactions','join','fax_interactions','fax_queues','ratingMessage','actions','mapKeyOffline','sequelize','info','catch','addIndex','agentAlias','dropTable','UNSIGNED','ratingType','cm_hopper','sitepic','rejectUrl','TEXT','enqueue','priority','STRING','closeMethod','acceptMethod','addIndex\x20%s\x20%s\x20%s','Send','timeout','addColumn','email','final','#9f946a','user_has_fax_interactions','forwardOffline','ratingValue','assigned','prototype','fax_dispositions','removeColumn','queue','Added\x20column\x20%s\x20to\x20%s','rejectMethod','migration','sequence','thumb','closeUrl','color_button','team_has_fax_queues','fax_applications','forwardTranscript','mailTranscript','user_has_chat_queues','stringify','acceptUrl','closingMessage','util','ENUM','BOOLEAN','tail','enableRating','fax_attachments','query','query\x20%s','user_has_openchannel_queues','fax_rooms','queryInterface','Changed\x20column\x20%s\x20in\x20table\x20%s','INTEGER','changeColumn','Agent','chat_websites','star','fax_accounts','closingMessageButton','then'];(function(_0x143ae3,_0x3dd5c4){const _0x764940=function(_0x57097a){while(--_0x57097a){_0x143ae3['push'](_0x143ae3['shift']());}};_0x764940(++_0x3dd5c4);}(a912_0x3dd5,0x14c));const a912_0x7649=function(_0x143ae3,_0x3dd5c4){_0x143ae3=_0x143ae3-0x0;let _0x764940=a912_0x3dd5[_0x143ae3];return _0x764940;};const _0x3876e7=a912_0x7649;'use strict';const logger=require('../config/logger')(_0x3876e7('0x5')),util=require(_0x3876e7('0x12')),Sequence=function(){};Sequence[_0x3876e7('0x49')][_0x3876e7('0x39')]=function(_0x57097a){const _0x17fdcf=_0x3876e7;this[_0x17fdcf('0x15')]=this[_0x17fdcf('0x15')]?this[_0x17fdcf('0x15')]['finally'](_0x57097a):_0x57097a();};const Migration=function(_0x5d4d6a){const _0x4acb8a=_0x3876e7;this[_0x4acb8a('0x1c')]=_0x5d4d6a,this[_0x4acb8a('0x6')]=new Sequence();};Migration[_0x3876e7('0x49')][_0x3876e7('0x1f')]=function(_0x425eea,_0x122fc7,_0x2fafc8){const _0x13e3f0=_0x3876e7,_0x404601=this;this[_0x13e3f0('0x6')][_0x13e3f0('0x39')](function(){const _0x139082=_0x13e3f0;return _0x404601[_0x139082('0x1c')][_0x139082('0x1f')](_0x425eea,_0x122fc7,_0x2fafc8)['then'](function(){const _0x5c991e=_0x139082;logger[_0x5c991e('0x2e')](_0x5c991e('0x1d'),_0x122fc7,_0x425eea);})['catch'](function(_0x2d6727){const _0x1c8856=_0x139082;logger[_0x1c8856('0x2e')](JSON['stringify'](_0x2d6727));});});},Migration['prototype'][_0x3876e7('0x41')]=function(_0x7018b7,_0x502916,_0x706281){const _0xcee195=_0x3876e7,_0xe34c3=this;this['sequence'][_0xcee195('0x39')](function(){const _0x279fd6=_0xcee195;return _0xe34c3[_0x279fd6('0x1c')][_0x279fd6('0x41')](_0x7018b7,_0x502916,_0x706281)['then'](function(){const _0x43afc3=_0x279fd6;logger[_0x43afc3('0x2e')](_0x43afc3('0x3'),_0x502916,_0x7018b7);})['catch'](function(_0x1ea0ff){const _0x43e532=_0x279fd6;logger[_0x43e532('0x2e')](JSON[_0x43e532('0xf')](_0x1ea0ff));});});},Migration['prototype'][_0x3876e7('0x32')]=function(_0x356d88){const _0x58701b=_0x3876e7,_0x33a8de=this;this[_0x58701b('0x6')]['enqueue'](function(){const _0x5c841b=_0x58701b;return _0x33a8de[_0x5c841b('0x1c')][_0x5c841b('0x32')](_0x356d88,{'force':!![]})[_0x5c841b('0x25')](function(){const _0xed6288=_0x5c841b;logger[_0xed6288('0x2e')]('table\x20dropped\x20%s',_0x356d88);})[_0x5c841b('0x2f')](function(_0x25e138){const _0x21b7e1=_0x5c841b;logger['info'](JSON[_0x21b7e1('0xf')](_0x25e138));});});},Migration[_0x3876e7('0x49')][_0x3876e7('0x30')]=function(_0x426649,_0x5ea5f3,_0x5e9e6f){const _0x4be631=_0x3876e7,_0x55aac3=this;this[_0x4be631('0x6')][_0x4be631('0x39')](function(){const _0x35fa36=_0x4be631;return _0x55aac3['queryInterface']['addIndex'](_0x426649,_0x5ea5f3,{'indexName':_0x5e9e6f})[_0x35fa36('0x25')](function(){const _0x5e919b=_0x35fa36;logger[_0x5e919b('0x2e')](_0x5e919b('0x3e'),_0x426649,_0x5ea5f3[_0x5e919b('0x27')](','),_0x5e9e6f);})[_0x35fa36('0x2f')](function(_0x4fee6f){const _0x5086a3=_0x35fa36;logger[_0x5086a3('0x2e')](JSON['stringify'](_0x4fee6f));});});},Migration[_0x3876e7('0x49')][_0x3876e7('0x18')]=function(_0x300e3c){const _0x5bdb27=_0x3876e7,_0x5ea095=this;this[_0x5bdb27('0x6')][_0x5bdb27('0x39')](function(){const _0x471a05=_0x5bdb27;return _0x5ea095['queryInterface'][_0x471a05('0x2d')][_0x471a05('0x18')](_0x300e3c)[_0x471a05('0x25')](function(){const _0x54e210=_0x471a05;logger[_0x54e210('0x2e')](_0x54e210('0x19'),_0x300e3c);})[_0x471a05('0x2f')](function(_0x3fdc9e){const _0x25a6b9=_0x471a05;logger[_0x25a6b9('0x2e')](JSON[_0x25a6b9('0xf')](_0x3fdc9e));});});},Migration[_0x3876e7('0x49')]['removeColumn']=function(_0x4fb89b,_0x2a14ca){const _0x4b0e68=_0x3876e7,_0x1b61c2=this;this[_0x4b0e68('0x6')][_0x4b0e68('0x39')](function(){const _0x538d99=_0x4b0e68;return _0x1b61c2[_0x538d99('0x1c')][_0x538d99('0x1')](_0x4fb89b,_0x2a14ca)['then'](function(){const _0xda909f=_0x538d99;logger[_0xda909f('0x2e')]('Removed\x20column\x20%s\x20from\x20%s',_0x2a14ca,_0x4fb89b);})[_0x538d99('0x2f')](function(_0x1ab9f0){logger['info'](util['inspect'](_0x1ab9f0,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x4f9f7f){const _0x49f50c=_0x3876e7;this[_0x49f50c('0x6')][_0x49f50c('0x39')](function(){return _0x4f9f7f();});},module['exports']={'up':function(_0x32560,_0x32c597){return new Promise(function(_0x57bae5){const _0x35f410=a912_0x7649,_0x2ce18b=new Migration(_0x32560);_0x2ce18b[_0x35f410('0x41')](_0x35f410('0x21'),_0x35f410('0x31'),{'type':_0x32c597[_0x35f410('0x3b')],'defaultValue':_0x35f410('0x20')}),_0x2ce18b['addColumn'](_0x35f410('0x21'),_0x35f410('0x2c'),{'type':_0x32c597[_0x35f410('0x3b')],'defaultValue':_0x35f410('0x42')}),_0x2ce18b[_0x35f410('0x41')](_0x35f410('0x21'),_0x35f410('0x36'),{'type':_0x32c597[_0x35f410('0x38')]}),_0x2ce18b[_0x35f410('0x41')](_0x35f410('0x21'),_0x35f410('0x11'),{'type':_0x32c597[_0x35f410('0x38')]}),_0x2ce18b[_0x35f410('0x41')]('chat_websites',_0x35f410('0x24'),{'type':_0x32c597[_0x35f410('0x3b')],'defaultValue':_0x35f410('0x3f')}),_0x2ce18b[_0x35f410('0x41')]('chat_websites',_0x35f410('0x16'),{'type':_0x32c597[_0x35f410('0x14')],'defaultValue':![]}),_0x2ce18b[_0x35f410('0x41')]('chat_websites',_0x35f410('0x34'),{'type':_0x32c597[_0x35f410('0x13')](_0x35f410('0x22'),_0x35f410('0x7')),'defaultValue':_0x35f410('0x22')}),_0x2ce18b[_0x35f410('0x41')]('chat_websites','ratingStarsNumber',{'type':_0x32c597[_0x35f410('0x1e')],'defaultValue':0x5}),_0x2ce18b['addColumn']('chat_interactions',_0x35f410('0x47'),{'type':_0x32c597[_0x35f410('0x1e')]}),_0x2ce18b[_0x35f410('0x41')]('chat_interactions',_0x35f410('0x2a'),{'type':_0x32c597[_0x35f410('0x38')]}),_0x2ce18b[_0x35f410('0x41')](_0x35f410('0x26'),'pathTranscript',{'type':_0x32c597['TEXT']}),_0x2ce18b[_0x35f410('0x41')](_0x35f410('0x26'),_0x35f410('0xd'),{'type':_0x32c597[_0x35f410('0x3b')]}),_0x2ce18b[_0x35f410('0x41')](_0x35f410('0x21'),_0x35f410('0xc'),{'type':_0x32c597[_0x35f410('0x14')],'defaultValue':![]}),_0x2ce18b[_0x35f410('0x41')](_0x35f410('0x21'),_0x35f410('0x46'),{'type':_0x32c597[_0x35f410('0x14')],'defaultValue':![]}),_0x2ce18b[_0x35f410('0x41')]('chat_websites','forwardOfflineAddress',{'type':_0x32c597[_0x35f410('0x3b')],'validate':{'isEmail':!![]}}),_0x2ce18b[_0x35f410('0x1f')]('chat_websites','color',{'type':_0x32c597[_0x35f410('0x3b')],'allowNull':![],'defaultValue':'#9f946a'}),_0x2ce18b[_0x35f410('0x1f')](_0x35f410('0x21'),_0x35f410('0x9'),{'type':_0x32c597[_0x35f410('0x3b')],'allowNull':![],'defaultValue':_0x35f410('0x44')}),_0x2ce18b[_0x35f410('0x32')](_0x35f410('0x17')),_0x2ce18b[_0x35f410('0x32')]('user_has_fax_rooms'),_0x2ce18b[_0x35f410('0x32')](_0x35f410('0x1b')),_0x2ce18b['dropTable']('fax_messages'),_0x2ce18b['dropTable'](_0x35f410('0x0')),_0x2ce18b[_0x35f410('0x32')](_0x35f410('0xb')),_0x2ce18b[_0x35f410('0x32')](_0x35f410('0x45')),_0x2ce18b['dropTable'](_0x35f410('0x28')),_0x2ce18b['dropTable'](_0x35f410('0xa')),_0x2ce18b[_0x35f410('0x32')]('user_has_fax_queues'),_0x2ce18b[_0x35f410('0x32')](_0x35f410('0x29')),_0x2ce18b[_0x35f410('0x1')]('fax_accounts','fidelity'),_0x2ce18b['removeColumn'](_0x35f410('0x23'),_0x35f410('0x40')),_0x2ce18b[_0x35f410('0x1')](_0x35f410('0x23'),_0x35f410('0x10')),_0x2ce18b[_0x35f410('0x1')]('fax_accounts',_0x35f410('0x37')),_0x2ce18b[_0x35f410('0x1')]('fax_accounts',_0x35f410('0x3d')),_0x2ce18b[_0x35f410('0x1')]('fax_accounts',_0x35f410('0x4')),_0x2ce18b[_0x35f410('0x1')]('fax_accounts',_0x35f410('0x2b')),_0x2ce18b['removeColumn'](_0x35f410('0x23'),_0x35f410('0x8')),_0x2ce18b[_0x35f410('0x1')](_0x35f410('0x23'),_0x35f410('0x3c')),_0x2ce18b[_0x35f410('0x1')](_0x35f410('0xe'),_0x35f410('0x48')),_0x2ce18b['removeColumn']('user_has_chat_queues',_0x35f410('0x2')),_0x2ce18b[_0x35f410('0x1')](_0x35f410('0x1a'),_0x35f410('0x48')),_0x2ce18b[_0x35f410('0x1')](_0x35f410('0x1a'),_0x35f410('0x2')),_0x2ce18b['addColumn'](_0x35f410('0x35'),_0x35f410('0x3a'),{'type':_0x32c597[_0x35f410('0x1e')](0x2)[_0x35f410('0x33')],'defaultValue':0x2}),_0x2ce18b[_0x35f410('0x30')]('cm_hopper',[_0x35f410('0x3a')],_0x35f410('0x3a')),_0x2ce18b[_0x35f410('0x32')]('sms_messages'),_0x2ce18b[_0x35f410('0x43')](_0x57bae5);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.34.js b/server/migrations/2.0.34.js index 1e4d37d..ec0110f 100644 --- a/server/migrations/2.0.34.js +++ b/server/migrations/2.0.34.js @@ -1 +1 @@ -const a913_0x1865=['addIndex','catch','autoclose','actions','deviceVendor','Changed\x20column\x20%s\x20in\x20table\x20%s','mail_queues','query','timeout','ALTER\x20TABLE\x20mail_messages\x20DROP\x20FOREIGN\x20KEY\x20mail_messages_ibfk_1','acceptMethod','final','mail_accounts','ALTER\x20TABLE\x20mail_messages\x20DROP\x20COLUMN\x20MailRoomId','INTEGER','skipUnmanaged','join','mail_interactions','voice_queues','AttachmentId','Added\x20column\x20%s\x20to\x20%s','enableCustomerWriting','mail_messages','removeColumn','query\x20%s','ALTER\x20TABLE\x20mail_messages\x20DROP\x20COLUMN\x20UserId','deviceModel','then','sms_accounts','info','forwardTranscriptMessage','addColumn','custom','recallme','prototype','sendUnmanaged','dropTable','Removed\x20column\x20%s\x20from\x20%s','STRING','changeColumn','enableFeedback','mail_rooms','table\x20dropped\x20%s','stringify','sequence','cm_hopper_final','osName','cm_hopper_history','unmanagedMessage','osVersion','Skip','accountSid','skipMessageButton','rejectMethod','ALTER\x20TABLE\x20mail_messages\x20DROP\x20FOREIGN\x20KEY\x20mail_messages_ibfk_2','user_has_mail_rooms','openchannel_accounts','key','Your\x20request\x20has\x20not\x20been\x20processed.','signature','browserName','BOOLEAN','fidelity','deviceType','chat_interactions','voice_recordings','chat_messages','ALTER\x20TABLE\x20mail_rooms\x20DROP\x20COLUMN\x20MailAccountId','conditionAgreement','cm_hopper','waitingTitle','closeMethod','mail_servers_out','rejectUrl','waitingMessage','active','migration','chat_websites','CREATE\x20TABLE\x20`mail_messages`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`body`\x20longtext\x20COLLATE\x20utf8mb4_unicode_ci\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`read`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`direction`\x20enum(\x27in\x27,\x27out\x27)\x20COLLATE\x20utf8mb4_unicode_ci\x20NOT\x20NULL\x20DEFAULT\x20\x27out\x27,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`messageId`\x20varchar(190)\x20COLLATE\x20utf8mb4_unicode_ci\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`from`\x20varchar(255)\x20COLLATE\x20utf8mb4_unicode_ci\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`to`\x20longtext\x20COLLATE\x20utf8mb4_unicode_ci,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`cc`\x20longtext\x20COLLATE\x20utf8mb4_unicode_ci,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`bcc`\x20longtext\x20COLLATE\x20utf8mb4_unicode_ci,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`subject`\x20text\x20COLLATE\x20utf8mb4_unicode_ci,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`sentAt`\x20datetime\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`MailAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`MailInteractionId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`ContactId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailAccountId`\x20(`MailAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailInteractionId`\x20(`MailInteractionId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`ContactId`\x20(`ContactId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`messageId`\x20(`messageId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_messages_ibfk_1`\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20REFERENCES\x20`mail_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_messages_ibfk_2`\x20FOREIGN\x20KEY\x20(`MailInteractionId`)\x20REFERENCES\x20`mail_interactions`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_messages_ibfk_3`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_messages_ibfk_4`\x20FOREIGN\x20KEY\x20(`ContactId`)\x20REFERENCES\x20`cm_contacts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8mb4\x20COLLATE=utf8mb4_unicode_ci;','mail_servers_in','state','dialRecallInQueue','ALTER\x20TABLE\x20`chat_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`chat_messages_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`AttachmentId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20attachments(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL','closeUrl','phone','mail_applications','mail_attachments','exports','tail','CREATE\x20TABLE\x20`mail_interactions`\x20(\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20`closed`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,\x20\x20\x20\x20\x20\x20\x20`closedAt`\x20datetime\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`disposition`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`note`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`inReplyTo`\x20varchar(190)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`to`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`cc`\x20longtext,\x20\x20\x20\x20\x20\x20\x20`subject`\x20text,\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`MailAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`ContactId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailAccountId`\x20(`MailAccountId`),\x20\x20\x20\x20\x20\x20\x20KEY\x20`ContactId`\x20(`ContactId`),\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_interactions_ibfk_1`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_interactions_ibfk_2`\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20REFERENCES\x20`mail_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_interactions_ibfk_3`\x20FOREIGN\x20KEY\x20(`ContactId`)\x20REFERENCES\x20`cm_contacts`\x20(`id`)\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','fax_attachments','UNSIGNED','ALTER\x20TABLE\x20analytics_extracted_reports\x20DROP\x20FOREIGN\x20KEY\x20analytics_extracted_reports_ibfk_1','enqueue','All\x20of\x20our\x20agents\x20are\x20busy\x20at\x20this\x20time.\x20Your\x20chat\x20is\x20very\x20important\x20to\x20us.','closingMessage','ALTER\x20TABLE\x20mail_rooms\x20DROP\x20FOREIGN\x20KEY\x20mail_rooms_ibfk_1','util','addIndex\x20%s\x20%s\x20%s','user_has_mail_interactions','queryInterface','acceptUrl'];(function(_0x3a6c68,_0x18659c){const _0x13fee8=function(_0x3962ce){while(--_0x3962ce){_0x3a6c68['push'](_0x3a6c68['shift']());}};_0x13fee8(++_0x18659c);}(a913_0x1865,0x81));const a913_0x13fe=function(_0x3a6c68,_0x18659c){_0x3a6c68=_0x3a6c68-0x0;let _0x13fee8=a913_0x1865[_0x3a6c68];return _0x13fee8;};const _0x1dc3bf=a913_0x13fe;'use strict';const logger=require('../config/logger')(_0x1dc3bf('0x31')),util=require(_0x1dc3bf('0x46')),Sequence=function(){};Sequence[_0x1dc3bf('0x7')][_0x1dc3bf('0x42')]=function(_0x3962ce){const _0x13a0bc=_0x1dc3bf;this[_0x13a0bc('0x3d')]=this['tail']?this['tail']['finally'](_0x3962ce):_0x3962ce();};const Migration=function(_0x2b68e5){const _0x50da75=_0x1dc3bf;this[_0x50da75('0x49')]=_0x2b68e5,this[_0x50da75('0x11')]=new Sequence();};Migration[_0x1dc3bf('0x7')][_0x1dc3bf('0xc')]=function(_0x34a64d,_0x59c20d,_0x3b1d46){const _0x11a781=_0x1dc3bf,_0x4f9c15=this;this[_0x11a781('0x11')][_0x11a781('0x42')](function(){const _0x6d9285=_0x11a781;return _0x4f9c15['queryInterface'][_0x6d9285('0xc')](_0x34a64d,_0x59c20d,_0x3b1d46)[_0x6d9285('0x0')](function(){const _0xe07bfb=_0x6d9285;logger[_0xe07bfb('0x2')](_0xe07bfb('0x50'),_0x59c20d,_0x34a64d);})[_0x6d9285('0x4c')](function(_0x23ab17){const _0x4ece8a=_0x6d9285;logger[_0x4ece8a('0x2')](JSON['stringify'](_0x23ab17));});});},Migration[_0x1dc3bf('0x7')][_0x1dc3bf('0x4')]=function(_0x23e994,_0x2b7838,_0x380d82){const _0x2ccea5=_0x1dc3bf,_0x98843=this;this[_0x2ccea5('0x11')][_0x2ccea5('0x42')](function(){const _0x433f44=_0x2ccea5;return _0x98843[_0x433f44('0x49')][_0x433f44('0x4')](_0x23e994,_0x2b7838,_0x380d82)[_0x433f44('0x0')](function(){const _0x196b1e=_0x433f44;logger['info'](_0x196b1e('0x5f'),_0x2b7838,_0x23e994);})[_0x433f44('0x4c')](function(_0x4d53dc){const _0x5e1745=_0x433f44;logger['info'](JSON[_0x5e1745('0x10')](_0x4d53dc));});});},Migration['prototype'][_0x1dc3bf('0x9')]=function(_0x27a3e4){const _0x3ca3fe=_0x1dc3bf,_0x25b392=this;this[_0x3ca3fe('0x11')][_0x3ca3fe('0x42')](function(){const _0x37b306=_0x3ca3fe;return _0x25b392[_0x37b306('0x49')]['dropTable'](_0x27a3e4,{'force':!![]})[_0x37b306('0x0')](function(){const _0x135961=_0x37b306;logger[_0x135961('0x2')](_0x135961('0xf'),_0x27a3e4);})[_0x37b306('0x4c')](function(_0xd5cadf){const _0x16bf81=_0x37b306;logger[_0x16bf81('0x2')](JSON[_0x16bf81('0x10')](_0xd5cadf));});});},Migration[_0x1dc3bf('0x7')][_0x1dc3bf('0x4b')]=function(_0x13843d,_0x12ef69,_0x3bd751){const _0x5c1ff9=_0x1dc3bf,_0xebacdb=this;this[_0x5c1ff9('0x11')][_0x5c1ff9('0x42')](function(){const _0x5a35c1=_0x5c1ff9;return _0xebacdb[_0x5a35c1('0x49')]['addIndex'](_0x13843d,_0x12ef69,{'indexName':_0x3bd751})[_0x5a35c1('0x0')](function(){const _0x3247ed=_0x5a35c1;logger['info'](_0x3247ed('0x47'),_0x13843d,_0x12ef69[_0x3247ed('0x5b')](','),_0x3bd751);})['catch'](function(_0x1e17eb){const _0x38b124=_0x5a35c1;logger['info'](JSON[_0x38b124('0x10')](_0x1e17eb));});});},Migration['prototype'][_0x1dc3bf('0x52')]=function(_0x153f6d){const _0x743930=_0x1dc3bf,_0x4e9b43=this;this[_0x743930('0x11')][_0x743930('0x42')](function(){const _0x1fa5b1=_0x743930;return _0x4e9b43[_0x1fa5b1('0x49')]['sequelize']['query'](_0x153f6d)[_0x1fa5b1('0x0')](function(){const _0x155e95=_0x1fa5b1;logger[_0x155e95('0x2')](_0x155e95('0x63'),_0x153f6d);})[_0x1fa5b1('0x4c')](function(_0xa1213){const _0x272f21=_0x1fa5b1;logger['info'](JSON[_0x272f21('0x10')](_0xa1213));});});},Migration[_0x1dc3bf('0x7')][_0x1dc3bf('0x62')]=function(_0x383577,_0x4b6350){const _0x48d414=_0x1dc3bf,_0x2c4689=this;this[_0x48d414('0x11')]['enqueue'](function(){const _0xc7713e=_0x48d414;return _0x2c4689['queryInterface']['removeColumn'](_0x383577,_0x4b6350)[_0xc7713e('0x0')](function(){const _0x17e625=_0xc7713e;logger[_0x17e625('0x2')](_0x17e625('0xa'),_0x4b6350,_0x383577);})[_0xc7713e('0x4c')](function(_0x40010d){const _0x4bbbf3=_0xc7713e;logger[_0x4bbbf3('0x2')](util['inspect'](_0x40010d,{'showHidden':![],'depth':null}));});});},Migration[_0x1dc3bf('0x7')][_0x1dc3bf('0x56')]=function(_0x487e8e){const _0x248c36=_0x1dc3bf;this['sequence'][_0x248c36('0x42')](function(){return _0x487e8e();});},module[_0x1dc3bf('0x3c')]={'up':function(_0x27a5c6,_0x5655cd){return new Promise(function(_0x45bda1){const _0x3c51da=a913_0x13fe,_0x29d5f6=new Migration(_0x27a5c6);_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x32'),_0x3c51da('0x1e'),{'type':_0x5655cd[_0x3c51da('0xb')],'allowNull':![]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x32'),_0x3c51da('0x3'),{'type':_0x5655cd[_0x3c51da('0xb')]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x32'),_0x3c51da('0x19'),{'type':_0x5655cd[_0x3c51da('0xb')],'defaultValue':_0x3c51da('0x17')}),_0x29d5f6[_0x3c51da('0x4')]('chat_websites',_0x3c51da('0xd'),{'type':_0x5655cd[_0x3c51da('0x22')],'defaultValue':![]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x32'),_0x3c51da('0x60'),{'type':_0x5655cd[_0x3c51da('0x22')],'defaultValue':![]}),_0x29d5f6[_0x3c51da('0x4')]('chat_websites',_0x3c51da('0x29'),{'type':_0x5655cd[_0x3c51da('0x22')],'defaultValue':![]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x32'),_0x3c51da('0x2b'),{'type':_0x5655cd['STRING'],'defaultValue':_0x3c51da('0x43')}),_0x29d5f6[_0x3c51da('0x4')]('chat_websites',_0x3c51da('0x2f'),{'type':_0x5655cd['STRING'],'defaultValue':'Please\x20hold\x20and\x20we\x20will\x20answer\x20your\x20request\x20as\x20soon\x20as\x20possible.'}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x32'),_0x3c51da('0x4d'),{'type':_0x5655cd[_0x3c51da('0x22')],'defaultValue':!![]}),_0x29d5f6['addColumn'](_0x3c51da('0x32'),_0x3c51da('0x15'),{'type':_0x5655cd['STRING'],'defaultValue':_0x3c51da('0x1f')}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x32'),'enableUnmanagedNote',{'type':_0x5655cd[_0x3c51da('0x22')],'defaultValue':!![]}),_0x29d5f6[_0x3c51da('0x4')]('chat_websites',_0x3c51da('0x8'),{'type':_0x5655cd[_0x3c51da('0xb')],'defaultValue':'Send'}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x32'),_0x3c51da('0x5a'),{'type':_0x5655cd[_0x3c51da('0xb')],'defaultValue':'Skip'}),_0x29d5f6[_0x3c51da('0xc')](_0x3c51da('0x32'),_0x3c51da('0x44'),{'type':_0x5655cd[_0x3c51da('0xb')],'defaultValue':'Thanks\x20you\x20for\x20your\x20time!'}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x25'),_0x3c51da('0x21'),{'type':_0x5655cd[_0x3c51da('0xb')]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x25'),'browserVersion',{'type':_0x5655cd['STRING']}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x25'),_0x3c51da('0x13'),{'type':_0x5655cd[_0x3c51da('0xb')]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x25'),_0x3c51da('0x16'),{'type':_0x5655cd[_0x3c51da('0xb')]}),_0x29d5f6['addColumn'](_0x3c51da('0x25'),_0x3c51da('0x65'),{'type':_0x5655cd[_0x3c51da('0xb')]}),_0x29d5f6['addColumn'](_0x3c51da('0x25'),_0x3c51da('0x4f'),{'type':_0x5655cd[_0x3c51da('0xb')]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x25'),_0x3c51da('0x24'),{'type':_0x5655cd['STRING']}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x27'),_0x3c51da('0x5e'),{'type':_0x5655cd[_0x3c51da('0x59')]}),_0x29d5f6['query'](_0x3c51da('0x37')),_0x29d5f6['addColumn'](_0x3c51da('0x5d'),'dialRecallMeTimeout',{'type':_0x5655cd[_0x3c51da('0x59')](0x5)[_0x3c51da('0x40')],'defaultValue':0x1e}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x5d'),_0x3c51da('0x36'),{'type':_0x5655cd['BOOLEAN'],'defaultValue':![]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x2a'),_0x3c51da('0x6'),{'type':_0x5655cd[_0x3c51da('0x22')],'defaultValue':![]}),_0x29d5f6['addColumn'](_0x3c51da('0x12'),_0x3c51da('0x6'),{'type':_0x5655cd[_0x3c51da('0x22')],'defaultValue':![]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x14'),_0x3c51da('0x6'),{'type':_0x5655cd[_0x3c51da('0x22')],'defaultValue':![]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x26'),'userDisposition',{'type':_0x5655cd[_0x3c51da('0xb')]}),_0x29d5f6[_0x3c51da('0x9')](_0x3c51da('0x1c')),_0x29d5f6[_0x3c51da('0x52')](_0x3c51da('0x45')),_0x29d5f6[_0x3c51da('0x52')](_0x3c51da('0x28')),_0x29d5f6['dropTable'](_0x3c51da('0xe')),_0x29d5f6['query'](_0x3c51da('0x41')),_0x29d5f6[_0x3c51da('0x52')]('ALTER\x20TABLE\x20mail_messages\x20DROP\x20COLUMN\x20MailMessageId'),_0x29d5f6[_0x3c51da('0x52')](_0x3c51da('0x54')),_0x29d5f6['query'](_0x3c51da('0x58')),_0x29d5f6[_0x3c51da('0x52')](_0x3c51da('0x1b')),_0x29d5f6[_0x3c51da('0x52')](_0x3c51da('0x64')),_0x29d5f6[_0x3c51da('0x9')](_0x3c51da('0x61')),_0x29d5f6[_0x3c51da('0x9')](_0x3c51da('0x3b')),_0x29d5f6[_0x3c51da('0x9')]('mail_dispositions'),_0x29d5f6[_0x3c51da('0x9')](_0x3c51da('0x3a')),_0x29d5f6[_0x3c51da('0x9')](_0x3c51da('0x48')),_0x29d5f6[_0x3c51da('0x9')](_0x3c51da('0x5c')),_0x29d5f6[_0x3c51da('0x9')]('team_has_mail_queues'),_0x29d5f6[_0x3c51da('0x9')]('user_has_mail_queues'),_0x29d5f6['dropTable'](_0x3c51da('0x51')),_0x29d5f6[_0x3c51da('0x62')]('mail_accounts',_0x3c51da('0x23')),_0x29d5f6[_0x3c51da('0x62')]('mail_accounts',_0x3c51da('0x53')),_0x29d5f6[_0x3c51da('0x62')](_0x3c51da('0x57'),'whiteLabel'),_0x29d5f6[_0x3c51da('0x62')](_0x3c51da('0x57'),_0x3c51da('0x4a')),_0x29d5f6[_0x3c51da('0x62')](_0x3c51da('0x57'),_0x3c51da('0x2e')),_0x29d5f6[_0x3c51da('0x62')](_0x3c51da('0x57'),_0x3c51da('0x55')),_0x29d5f6['removeColumn'](_0x3c51da('0x57'),_0x3c51da('0x1a')),_0x29d5f6['removeColumn'](_0x3c51da('0x57'),_0x3c51da('0x4e')),_0x29d5f6['removeColumn'](_0x3c51da('0x57'),_0x3c51da('0x38')),_0x29d5f6['removeColumn'](_0x3c51da('0x57'),_0x3c51da('0x2c')),_0x29d5f6['removeColumn'](_0x3c51da('0x57'),_0x3c51da('0x20')),_0x29d5f6['removeColumn']('mail_accounts',_0x3c51da('0x5')),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x57'),_0x3c51da('0x30'),{'type':_0x5655cd[_0x3c51da('0x22')],'defaultValue':!![]}),_0x29d5f6[_0x3c51da('0x62')](_0x3c51da('0x2d'),_0x3c51da('0x35')),_0x29d5f6['dropTable'](_0x3c51da('0x34')),_0x29d5f6['query'](_0x3c51da('0x3e')),_0x29d5f6[_0x3c51da('0x52')](_0x3c51da('0x33')),_0x29d5f6[_0x3c51da('0x52')]('CREATE\x20TABLE\x20`attachments`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20\x20`name`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`basename`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`type`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`MailMessageId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailMessageId`\x20(`MailMessageId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`attachments_ibfk_1`\x20FOREIGN\x20KEY\x20(`MailMessageId`)\x20REFERENCES\x20`mail_messages`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20AUTO_INCREMENT=5\x20DEFAULT\x20CHARSET=utf8;'),_0x29d5f6[_0x3c51da('0x9')](_0x3c51da('0x3f')),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x1'),_0x3c51da('0x39'),{'type':_0x5655cd[_0x3c51da('0xb')]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x1'),_0x3c51da('0x18'),{'type':_0x5655cd['STRING']}),_0x29d5f6[_0x3c51da('0x4')]('sms_accounts','authToken',{'type':_0x5655cd[_0x3c51da('0xb')]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x1'),_0x3c51da('0x1e'),{'type':_0x5655cd['STRING'],'allowNull':![]}),_0x29d5f6[_0x3c51da('0x52')]('ALTER\x20TABLE\x20users\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8\x20COLLATE\x20utf8_bin;'),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x1d'),_0x3c51da('0x1e'),{'type':_0x5655cd[_0x3c51da('0xb')],'allowNull':![]}),_0x29d5f6[_0x3c51da('0x4')]('fax_accounts','key',{'type':_0x5655cd[_0x3c51da('0xb')],'allowNull':![]}),_0x29d5f6[_0x3c51da('0x4')](_0x3c51da('0x57'),_0x3c51da('0x1e'),{'type':_0x5655cd[_0x3c51da('0xb')],'allowNull':![]}),_0x29d5f6[_0x3c51da('0x56')](_0x45bda1);});},'down':function(){}}; \ No newline at end of file +const a913_0x334b=['team_has_mail_queues','ALTER\x20TABLE\x20mail_rooms\x20DROP\x20FOREIGN\x20KEY\x20mail_rooms_ibfk_1','enableCustomerWriting','userDisposition','CREATE\x20TABLE\x20`mail_interactions`\x20(\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20`closed`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,\x20\x20\x20\x20\x20\x20\x20`closedAt`\x20datetime\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`disposition`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`note`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`inReplyTo`\x20varchar(190)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`to`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`cc`\x20longtext,\x20\x20\x20\x20\x20\x20\x20`subject`\x20text,\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`MailAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20`ContactId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailAccountId`\x20(`MailAccountId`),\x20\x20\x20\x20\x20\x20\x20KEY\x20`ContactId`\x20(`ContactId`),\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_interactions_ibfk_1`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_interactions_ibfk_2`\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20REFERENCES\x20`mail_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_interactions_ibfk_3`\x20FOREIGN\x20KEY\x20(`ContactId`)\x20REFERENCES\x20`cm_contacts`\x20(`id`)\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','dialRecallInQueue','voice_recordings','Thanks\x20you\x20for\x20your\x20time!','ALTER\x20TABLE\x20mail_messages\x20DROP\x20COLUMN\x20MailMessageId','sendUnmanaged','final','openchannel_accounts','user_has_mail_queues','mail_attachments','ALTER\x20TABLE\x20mail_rooms\x20DROP\x20COLUMN\x20MailAccountId','fax_accounts','Removed\x20column\x20%s\x20from\x20%s','prototype','STRING','INTEGER','autoclose','BOOLEAN','cm_hopper_final','mail_applications','dropTable','active','enableFeedback','recallme','deviceModel','exports','rejectMethod','mail_servers_out','CREATE\x20TABLE\x20`attachments`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20\x20`name`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`basename`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`type`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`MailMessageId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailMessageId`\x20(`MailMessageId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`attachments_ibfk_1`\x20FOREIGN\x20KEY\x20(`MailMessageId`)\x20REFERENCES\x20`mail_messages`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20AUTO_INCREMENT=5\x20DEFAULT\x20CHARSET=utf8;','enableUnmanagedNote','osVersion','UNSIGNED','rejectUrl','removeColumn','inspect','fax_attachments','acceptUrl','mail_accounts','waitingMessage','sequence','closeUrl','tail','queryInterface','Skip','custom','acceptMethod','mail_interactions','ALTER\x20TABLE\x20`chat_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`chat_messages_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`AttachmentId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20attachments(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL','user_has_mail_interactions','browserName','sequelize','authToken','ALTER\x20TABLE\x20mail_messages\x20DROP\x20COLUMN\x20MailRoomId','ALTER\x20TABLE\x20mail_messages\x20DROP\x20FOREIGN\x20KEY\x20mail_messages_ibfk_1','cm_hopper_history','Please\x20hold\x20and\x20we\x20will\x20answer\x20your\x20request\x20as\x20soon\x20as\x20possible.','Your\x20request\x20has\x20not\x20been\x20processed.','conditionAgreement','query','addIndex\x20%s\x20%s\x20%s','mail_messages','CREATE\x20TABLE\x20`mail_messages`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`body`\x20longtext\x20COLLATE\x20utf8mb4_unicode_ci\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`read`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`direction`\x20enum(\x27in\x27,\x27out\x27)\x20COLLATE\x20utf8mb4_unicode_ci\x20NOT\x20NULL\x20DEFAULT\x20\x27out\x27,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`messageId`\x20varchar(190)\x20COLLATE\x20utf8mb4_unicode_ci\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`from`\x20varchar(255)\x20COLLATE\x20utf8mb4_unicode_ci\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`to`\x20longtext\x20COLLATE\x20utf8mb4_unicode_ci,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`cc`\x20longtext\x20COLLATE\x20utf8mb4_unicode_ci,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`bcc`\x20longtext\x20COLLATE\x20utf8mb4_unicode_ci,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`subject`\x20text\x20COLLATE\x20utf8mb4_unicode_ci,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`sentAt`\x20datetime\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`MailAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`MailInteractionId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20`ContactId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailAccountId`\x20(`MailAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailInteractionId`\x20(`MailInteractionId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`ContactId`\x20(`ContactId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`messageId`\x20(`messageId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_messages_ibfk_1`\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20REFERENCES\x20`mail_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_messages_ibfk_2`\x20FOREIGN\x20KEY\x20(`MailInteractionId`)\x20REFERENCES\x20`mail_interactions`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_messages_ibfk_3`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`mail_messages_ibfk_4`\x20FOREIGN\x20KEY\x20(`ContactId`)\x20REFERENCES\x20`cm_contacts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8mb4\x20COLLATE=utf8mb4_unicode_ci;','deviceVendor','phone','dialRecallMeTimeout','Added\x20column\x20%s\x20to\x20%s','voice_queues','signature','mail_rooms','whiteLabel','chat_websites','deviceType','All\x20of\x20our\x20agents\x20are\x20busy\x20at\x20this\x20time.\x20Your\x20chat\x20is\x20very\x20important\x20to\x20us.','closingMessage','timeout','catch','enqueue','info','unmanagedMessage','state','chat_interactions','AttachmentId','mail_dispositions','skipUnmanaged','forwardTranscriptMessage','accountSid','stringify','../config/logger','ALTER\x20TABLE\x20mail_messages\x20DROP\x20COLUMN\x20UserId','then','addColumn','changeColumn','mail_servers_in','ALTER\x20TABLE\x20analytics_extracted_reports\x20DROP\x20FOREIGN\x20KEY\x20analytics_extracted_reports_ibfk_1','Send','key','Changed\x20column\x20%s\x20in\x20table\x20%s','user_has_mail_rooms','sms_accounts','util'];(function(_0x126476,_0x334bae){const _0x41a9d4=function(_0x3b2126){while(--_0x3b2126){_0x126476['push'](_0x126476['shift']());}};_0x41a9d4(++_0x334bae);}(a913_0x334b,0x118));const a913_0x41a9=function(_0x126476,_0x334bae){_0x126476=_0x126476-0x0;let _0x41a9d4=a913_0x334b[_0x126476];return _0x41a9d4;};const _0x120ab7=a913_0x41a9;'use strict';const logger=require(_0x120ab7('0x13'))('migration'),util=require(_0x120ab7('0x1f')),Sequence=function(){};Sequence[_0x120ab7('0x31')][_0x120ab7('0x8')]=function(_0x3b2126){const _0x332c27=_0x120ab7;this[_0x332c27('0x4d')]=this[_0x332c27('0x4d')]?this[_0x332c27('0x4d')]['finally'](_0x3b2126):_0x3b2126();};const Migration=function(_0x5a5e59){const _0x1508b6=_0x120ab7;this['queryInterface']=_0x5a5e59,this[_0x1508b6('0x4b')]=new Sequence();};Migration[_0x120ab7('0x31')][_0x120ab7('0x17')]=function(_0x39c6d3,_0x2d8eac,_0x34dc26){const _0x4cc08b=_0x120ab7,_0x4cdbf7=this;this['sequence'][_0x4cc08b('0x8')](function(){const _0x5bd93d=_0x4cc08b;return _0x4cdbf7[_0x5bd93d('0x4e')]['changeColumn'](_0x39c6d3,_0x2d8eac,_0x34dc26)[_0x5bd93d('0x15')](function(){const _0x2fadf9=_0x5bd93d;logger['info'](_0x2fadf9('0x1c'),_0x2d8eac,_0x39c6d3);})['catch'](function(_0x4b6664){const _0x386733=_0x5bd93d;logger['info'](JSON[_0x386733('0x12')](_0x4b6664));});});},Migration[_0x120ab7('0x31')]['addColumn']=function(_0x1c8e58,_0x18be6f,_0x137293){const _0x3cd4ad=_0x120ab7,_0x175601=this;this[_0x3cd4ad('0x4b')][_0x3cd4ad('0x8')](function(){const _0x29737b=_0x3cd4ad;return _0x175601[_0x29737b('0x4e')]['addColumn'](_0x1c8e58,_0x18be6f,_0x137293)[_0x29737b('0x15')](function(){const _0x2d75bd=_0x29737b;logger['info'](_0x2d75bd('0x65'),_0x18be6f,_0x1c8e58);})[_0x29737b('0x7')](function(_0x3d85bd){const _0x37c65d=_0x29737b;logger[_0x37c65d('0x9')](JSON[_0x37c65d('0x12')](_0x3d85bd));});});},Migration[_0x120ab7('0x31')][_0x120ab7('0x38')]=function(_0x4b6abf){const _0x5bd66c=_0x120ab7,_0x54c8a5=this;this[_0x5bd66c('0x4b')][_0x5bd66c('0x8')](function(){const _0x474469=_0x5bd66c;return _0x54c8a5[_0x474469('0x4e')][_0x474469('0x38')](_0x4b6abf,{'force':!![]})['then'](function(){const _0x227377=_0x474469;logger[_0x227377('0x9')]('table\x20dropped\x20%s',_0x4b6abf);})[_0x474469('0x7')](function(_0x33309d){const _0x21864a=_0x474469;logger[_0x21864a('0x9')](JSON[_0x21864a('0x12')](_0x33309d));});});},Migration[_0x120ab7('0x31')]['addIndex']=function(_0x5bc6f3,_0x157c4a,_0x58bace){const _0x12d930=_0x120ab7,_0xe63c0b=this;this[_0x12d930('0x4b')][_0x12d930('0x8')](function(){const _0x1c6f34=_0x12d930;return _0xe63c0b[_0x1c6f34('0x4e')]['addIndex'](_0x5bc6f3,_0x157c4a,{'indexName':_0x58bace})[_0x1c6f34('0x15')](function(){const _0x309338=_0x1c6f34;logger['info'](_0x309338('0x5f'),_0x5bc6f3,_0x157c4a['join'](','),_0x58bace);})[_0x1c6f34('0x7')](function(_0x2658e4){const _0x163d6f=_0x1c6f34;logger[_0x163d6f('0x9')](JSON[_0x163d6f('0x12')](_0x2658e4));});});},Migration['prototype'][_0x120ab7('0x5e')]=function(_0x173f9e){const _0x3cd339=_0x120ab7,_0x1a8991=this;this[_0x3cd339('0x4b')][_0x3cd339('0x8')](function(){const _0xbab41d=_0x3cd339;return _0x1a8991[_0xbab41d('0x4e')][_0xbab41d('0x56')][_0xbab41d('0x5e')](_0x173f9e)[_0xbab41d('0x15')](function(){const _0x54fe28=_0xbab41d;logger[_0x54fe28('0x9')]('query\x20%s',_0x173f9e);})['catch'](function(_0x338658){const _0x535127=_0xbab41d;logger[_0x535127('0x9')](JSON[_0x535127('0x12')](_0x338658));});});},Migration['prototype']['removeColumn']=function(_0x32c19e,_0x14cca7){const _0x3cdcb6=_0x120ab7,_0x55ed6b=this;this[_0x3cdcb6('0x4b')][_0x3cdcb6('0x8')](function(){const _0x35ab06=_0x3cdcb6;return _0x55ed6b['queryInterface'][_0x35ab06('0x45')](_0x32c19e,_0x14cca7)['then'](function(){const _0x18692f=_0x35ab06;logger[_0x18692f('0x9')](_0x18692f('0x30'),_0x14cca7,_0x32c19e);})[_0x35ab06('0x7')](function(_0x427ceb){const _0x25aa8d=_0x35ab06;logger['info'](util[_0x25aa8d('0x46')](_0x427ceb,{'showHidden':![],'depth':null}));});});},Migration[_0x120ab7('0x31')][_0x120ab7('0x2a')]=function(_0xae930c){const _0x17b141=_0x120ab7;this[_0x17b141('0x4b')]['enqueue'](function(){return _0xae930c();});},module[_0x120ab7('0x3d')]={'up':function(_0x3de9e5,_0x38ffbd){return new Promise(function(_0x454e6a){const _0x2bd4e0=a913_0x41a9,_0xdc1680=new Migration(_0x3de9e5);_0xdc1680['addColumn'](_0x2bd4e0('0x2'),_0x2bd4e0('0x1b'),{'type':_0x38ffbd[_0x2bd4e0('0x32')],'allowNull':![]}),_0xdc1680['addColumn'](_0x2bd4e0('0x2'),_0x2bd4e0('0x10'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2'),'skipMessageButton',{'type':_0x38ffbd[_0x2bd4e0('0x32')],'defaultValue':_0x2bd4e0('0x4f')}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2'),_0x2bd4e0('0x3a'),{'type':_0x38ffbd[_0x2bd4e0('0x35')],'defaultValue':![]}),_0xdc1680[_0x2bd4e0('0x16')]('chat_websites',_0x2bd4e0('0x22'),{'type':_0x38ffbd[_0x2bd4e0('0x35')],'defaultValue':![]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2'),_0x2bd4e0('0x5d'),{'type':_0x38ffbd['BOOLEAN'],'defaultValue':![]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2'),'waitingTitle',{'type':_0x38ffbd[_0x2bd4e0('0x32')],'defaultValue':_0x2bd4e0('0x4')}),_0xdc1680[_0x2bd4e0('0x16')]('chat_websites',_0x2bd4e0('0x4a'),{'type':_0x38ffbd[_0x2bd4e0('0x32')],'defaultValue':_0x2bd4e0('0x5b')}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2'),_0x2bd4e0('0x34'),{'type':_0x38ffbd['BOOLEAN'],'defaultValue':!![]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2'),_0x2bd4e0('0xa'),{'type':_0x38ffbd[_0x2bd4e0('0x32')],'defaultValue':_0x2bd4e0('0x5c')}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2'),_0x2bd4e0('0x41'),{'type':_0x38ffbd[_0x2bd4e0('0x35')],'defaultValue':!![]}),_0xdc1680['addColumn']('chat_websites',_0x2bd4e0('0x29'),{'type':_0x38ffbd[_0x2bd4e0('0x32')],'defaultValue':_0x2bd4e0('0x1a')}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2'),_0x2bd4e0('0xf'),{'type':_0x38ffbd[_0x2bd4e0('0x32')],'defaultValue':_0x2bd4e0('0x4f')}),_0xdc1680[_0x2bd4e0('0x17')](_0x2bd4e0('0x2'),_0x2bd4e0('0x5'),{'type':_0x38ffbd[_0x2bd4e0('0x32')],'defaultValue':_0x2bd4e0('0x27')}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0xc'),_0x2bd4e0('0x55'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680['addColumn']('chat_interactions','browserVersion',{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0xc'),'osName',{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0xc'),_0x2bd4e0('0x42'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680[_0x2bd4e0('0x16')]('chat_interactions',_0x2bd4e0('0x3c'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680['addColumn']('chat_interactions',_0x2bd4e0('0x62'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680['addColumn'](_0x2bd4e0('0xc'),_0x2bd4e0('0x3'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680['addColumn']('chat_messages',_0x2bd4e0('0xd'),{'type':_0x38ffbd['INTEGER']}),_0xdc1680['query'](_0x2bd4e0('0x53')),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x66'),_0x2bd4e0('0x64'),{'type':_0x38ffbd[_0x2bd4e0('0x33')](0x5)[_0x2bd4e0('0x43')],'defaultValue':0x1e}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x66'),_0x2bd4e0('0x25'),{'type':_0x38ffbd['BOOLEAN'],'defaultValue':![]}),_0xdc1680[_0x2bd4e0('0x16')]('cm_hopper',_0x2bd4e0('0x3b'),{'type':_0x38ffbd[_0x2bd4e0('0x35')],'defaultValue':![]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x36'),_0x2bd4e0('0x3b'),{'type':_0x38ffbd[_0x2bd4e0('0x35')],'defaultValue':![]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x5a'),_0x2bd4e0('0x3b'),{'type':_0x38ffbd[_0x2bd4e0('0x35')],'defaultValue':![]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x26'),_0x2bd4e0('0x23'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x1d')),_0xdc1680[_0x2bd4e0('0x5e')](_0x2bd4e0('0x21')),_0xdc1680[_0x2bd4e0('0x5e')](_0x2bd4e0('0x2e')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x0')),_0xdc1680['query'](_0x2bd4e0('0x19')),_0xdc1680[_0x2bd4e0('0x5e')](_0x2bd4e0('0x28')),_0xdc1680[_0x2bd4e0('0x5e')](_0x2bd4e0('0x59')),_0xdc1680[_0x2bd4e0('0x5e')](_0x2bd4e0('0x58')),_0xdc1680[_0x2bd4e0('0x5e')]('ALTER\x20TABLE\x20mail_messages\x20DROP\x20FOREIGN\x20KEY\x20mail_messages_ibfk_2'),_0xdc1680[_0x2bd4e0('0x5e')](_0x2bd4e0('0x14')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x60')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x2d')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0xe')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x37')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x54')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x52')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x20')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x2c')),_0xdc1680[_0x2bd4e0('0x38')]('mail_queues'),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),'fidelity'),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),_0x2bd4e0('0x6')),_0xdc1680[_0x2bd4e0('0x45')]('mail_accounts',_0x2bd4e0('0x1')),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),_0x2bd4e0('0x48')),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),_0x2bd4e0('0x44')),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),_0x2bd4e0('0x51')),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),_0x2bd4e0('0x3e')),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),'actions'),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),_0x2bd4e0('0x4c')),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),'closeMethod'),_0xdc1680[_0x2bd4e0('0x45')]('mail_accounts',_0x2bd4e0('0x67')),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x49'),_0x2bd4e0('0x50')),_0xdc1680[_0x2bd4e0('0x16')]('mail_accounts',_0x2bd4e0('0x39'),{'type':_0x38ffbd['BOOLEAN'],'defaultValue':!![]}),_0xdc1680[_0x2bd4e0('0x45')](_0x2bd4e0('0x3f'),_0x2bd4e0('0xb')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x18')),_0xdc1680[_0x2bd4e0('0x5e')](_0x2bd4e0('0x24')),_0xdc1680[_0x2bd4e0('0x5e')](_0x2bd4e0('0x61')),_0xdc1680[_0x2bd4e0('0x5e')](_0x2bd4e0('0x40')),_0xdc1680[_0x2bd4e0('0x38')](_0x2bd4e0('0x47')),_0xdc1680['addColumn'](_0x2bd4e0('0x1e'),_0x2bd4e0('0x63'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x1e'),_0x2bd4e0('0x11'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x1e'),_0x2bd4e0('0x57'),{'type':_0x38ffbd[_0x2bd4e0('0x32')]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x1e'),_0x2bd4e0('0x1b'),{'type':_0x38ffbd[_0x2bd4e0('0x32')],'allowNull':![]}),_0xdc1680['query']('ALTER\x20TABLE\x20users\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8\x20COLLATE\x20utf8_bin;'),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2b'),_0x2bd4e0('0x1b'),{'type':_0x38ffbd['STRING'],'allowNull':![]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x2f'),_0x2bd4e0('0x1b'),{'type':_0x38ffbd[_0x2bd4e0('0x32')],'allowNull':![]}),_0xdc1680[_0x2bd4e0('0x16')](_0x2bd4e0('0x49'),_0x2bd4e0('0x1b'),{'type':_0x38ffbd[_0x2bd4e0('0x32')],'allowNull':![]}),_0xdc1680[_0x2bd4e0('0x2a')](_0x454e6a);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.35.js b/server/migrations/2.0.35.js index f341c30..a40ac30 100644 --- a/server/migrations/2.0.35.js +++ b/server/migrations/2.0.35.js @@ -1 +1 @@ -const a914_0x38e2=['addColumn','long','direction','retry','query','DESC','users','dialOrderByScheduledAt','enqueue','ALTER\x20TABLE\x20`chat_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`chat_messages_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`AttachmentId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20attachments(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL','mail_accounts','table\x20dropped\x20%s','util','query\x20%s','final','html','campaigns','tail','sequence','fromId','STRING','bcc','ALTER\x20TABLE\x20mail_messages\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;','addIndex','text','voiceSource','ALTER\x20TABLE\x20`mail_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_messages_ibfk_1`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20mail_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL','INTEGER','ASC','ALTER\x20TABLE\x20`mail_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_messages_ibfk_3`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`UserId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20users(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL','ALTER\x20TABLE\x20`mail_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_messages_ibfk_4`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`ContactId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20cm_contacts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','DATE','joins','Added\x20column\x20%s\x20to\x20%s','accountId','MailInteractionId','analytics_default_reports','stringify','sequelize','TEXT','Send','accountName','inReplyTo','referer','report_mail_session','queryInterface','MailAccountId','migration','report_sms_session','ENUM','mail_interactions','read','tools_templates','info','mail_messages','edited','offline_chat_button','catch','enableCustomerAttachment','ALTER\x20TABLE\x20`mail_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_messages_ibfk_2`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`MailInteractionId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20mail_interactions(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','attachment','ALTER\x20TABLE\x20chat_interactions\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;','phoneBarAutoAnswerDelay','userFullname','dropTable','report_openchannel','chat_interactions','addIndex\x20%s\x20%s\x20%s','customerIp','changeColumn','removeColumn','attach','BOOLEAN','editedat','userName','report_fax','ratingType','chat_websites','report_openchannel_session','reason','then','join','report_mail','signature','prototype','phoneBarEnableDtmfTone','body','ContactId','report_fax_session','finally','subject','cm_hopper_history','out','auto','messageId'];(function(_0x41f8c7,_0x38e203){const _0x218331=function(_0x2d5fdd){while(--_0x2d5fdd){_0x41f8c7['push'](_0x41f8c7['shift']());}};_0x218331(++_0x38e203);}(a914_0x38e2,0xe4));const a914_0x2183=function(_0x41f8c7,_0x38e203){_0x41f8c7=_0x41f8c7-0x0;let _0x218331=a914_0x38e2[_0x41f8c7];return _0x218331;};const _0x697cd3=a914_0x2183;'use strict';const logger=require('../config/logger')(_0x697cd3('0x9')),util=require(_0x697cd3('0x45')),Sequence=function(){};Sequence[_0x697cd3('0x2e')][_0x697cd3('0x41')]=function(_0x2d5fdd){const _0x4a7112=_0x697cd3;this['tail']=this[_0x4a7112('0x4a')]?this[_0x4a7112('0x4a')][_0x4a7112('0x33')](_0x2d5fdd):_0x2d5fdd();};const Migration=function(_0x4a9628){const _0x22a927=_0x697cd3;this[_0x22a927('0x7')]=_0x4a9628,this['sequence']=new Sequence();};Migration['prototype'][_0x697cd3('0x1f')]=function(_0x391870,_0x1a1545,_0x40b86a){const _0x3c1a2e=this;this['sequence']['enqueue'](function(){const _0x5bd0e6=a914_0x2183;return _0x3c1a2e[_0x5bd0e6('0x7')][_0x5bd0e6('0x1f')](_0x391870,_0x1a1545,_0x40b86a)[_0x5bd0e6('0x2a')](function(){const _0x5490a2=_0x5bd0e6;logger[_0x5490a2('0xf')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x1a1545,_0x391870);})[_0x5bd0e6('0x13')](function(_0x17c2ce){const _0xdd8a70=_0x5bd0e6;logger[_0xdd8a70('0xf')](JSON[_0xdd8a70('0x5e')](_0x17c2ce));});});},Migration[_0x697cd3('0x2e')][_0x697cd3('0x39')]=function(_0x59435b,_0x5097e9,_0x1f7625){const _0x5bd0d3=_0x697cd3,_0xda06c5=this;this[_0x5bd0d3('0x4b')][_0x5bd0d3('0x41')](function(){const _0x4e438e=_0x5bd0d3;return _0xda06c5[_0x4e438e('0x7')]['addColumn'](_0x59435b,_0x5097e9,_0x1f7625)[_0x4e438e('0x2a')](function(){const _0x4d1592=_0x4e438e;logger['info'](_0x4d1592('0x5a'),_0x5097e9,_0x59435b);})['catch'](function(_0x1385ed){const _0x2b8287=_0x4e438e;logger[_0x2b8287('0xf')](JSON['stringify'](_0x1385ed));});});},Migration['prototype']['dropTable']=function(_0x1795c6){const _0x51d52f=this;this['sequence']['enqueue'](function(){const _0x37570a=a914_0x2183;return _0x51d52f[_0x37570a('0x7')][_0x37570a('0x1a')](_0x1795c6,{'force':!![]})[_0x37570a('0x2a')](function(){const _0x3b52d5=_0x37570a;logger[_0x3b52d5('0xf')](_0x3b52d5('0x44'),_0x1795c6);})[_0x37570a('0x13')](function(_0x1ec660){const _0x35573e=_0x37570a;logger[_0x35573e('0xf')](JSON[_0x35573e('0x5e')](_0x1ec660));});});},Migration[_0x697cd3('0x2e')][_0x697cd3('0x50')]=function(_0x6b48fa,_0x24d014,_0x3b702e){const _0x5b88cd=_0x697cd3,_0x52a31e=this;this[_0x5b88cd('0x4b')][_0x5b88cd('0x41')](function(){const _0x392ed3=_0x5b88cd;return _0x52a31e[_0x392ed3('0x7')][_0x392ed3('0x50')](_0x6b48fa,_0x24d014,{'indexName':_0x3b702e})[_0x392ed3('0x2a')](function(){const _0x4eee32=_0x392ed3;logger['info'](_0x4eee32('0x1d'),_0x6b48fa,_0x24d014[_0x4eee32('0x2b')](','),_0x3b702e);})[_0x392ed3('0x13')](function(_0x368548){const _0x131b46=_0x392ed3;logger[_0x131b46('0xf')](JSON[_0x131b46('0x5e')](_0x368548));});});},Migration['prototype'][_0x697cd3('0x3d')]=function(_0x228d8f){const _0x116764=this;this['sequence']['enqueue'](function(){const _0x547f19=a914_0x2183;return _0x116764[_0x547f19('0x7')][_0x547f19('0x0')]['query'](_0x228d8f)[_0x547f19('0x2a')](function(){const _0x3cc90c=_0x547f19;logger['info'](_0x3cc90c('0x46'),_0x228d8f);})[_0x547f19('0x13')](function(_0x20e7f4){const _0x2a1d62=_0x547f19;logger[_0x2a1d62('0xf')](JSON[_0x2a1d62('0x5e')](_0x20e7f4));});});},Migration[_0x697cd3('0x2e')][_0x697cd3('0x20')]=function(_0x1d5b5d,_0x4c7ce0){const _0x168115=_0x697cd3,_0x57a0b6=this;this[_0x168115('0x4b')][_0x168115('0x41')](function(){const _0x50d8af=_0x168115;return _0x57a0b6[_0x50d8af('0x7')][_0x50d8af('0x20')](_0x1d5b5d,_0x4c7ce0)[_0x50d8af('0x2a')](function(){const _0x221561=_0x50d8af;logger[_0x221561('0xf')]('Removed\x20column\x20%s\x20from\x20%s',_0x4c7ce0,_0x1d5b5d);})[_0x50d8af('0x13')](function(_0x15ac88){logger['info'](util['inspect'](_0x15ac88,{'showHidden':![],'depth':null}));});});},Migration[_0x697cd3('0x2e')]['final']=function(_0xe1b67e){const _0x41d8d2=_0x697cd3;this[_0x41d8d2('0x4b')]['enqueue'](function(){return _0xe1b67e();});},module['exports']={'up':function(_0x2b116c,_0x1796f2){return new Promise(function(_0x55a05f){const _0x29d1e9=a914_0x2183,_0x3799f2=new Migration(_0x2b116c);_0x3799f2[_0x29d1e9('0x39')]('analytics_custom_reports',_0x29d1e9('0x59'),{'type':_0x1796f2['TEXT']}),_0x3799f2['addColumn'](_0x29d1e9('0x5d'),_0x29d1e9('0x59'),{'type':_0x1796f2[_0x29d1e9('0x1')]}),_0x3799f2['query'](_0x29d1e9('0x42')),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x27'),_0x29d1e9('0x12'),{'type':_0x1796f2['STRING'],'defaultValue':_0x29d1e9('0x2')}),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x27'),_0x29d1e9('0x14'),{'type':_0x1796f2['BOOLEAN'],'defaultValue':![]}),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x1c'),_0x29d1e9('0x5'),{'type':_0x1796f2[_0x29d1e9('0x4d')]}),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x1c'),_0x29d1e9('0x1e'),{'type':_0x1796f2['STRING']}),_0x3799f2[_0x29d1e9('0x39')]('chat_interactions',_0x29d1e9('0x26'),{'type':_0x1796f2[_0x29d1e9('0xb')]('star','thumb'),'defaultValue':'star'}),_0x3799f2[_0x29d1e9('0x3d')](_0x29d1e9('0x17')),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x10'),_0x29d1e9('0x30'),{'type':_0x1796f2[_0x29d1e9('0x1')](_0x29d1e9('0x3a')),'allowNull':![]}),_0x3799f2[_0x29d1e9('0x39')]('mail_messages',_0x29d1e9('0xd'),{'type':_0x1796f2[_0x29d1e9('0x22')],'defaultValue':![]}),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x10'),_0x29d1e9('0x3b'),{'type':_0x1796f2[_0x29d1e9('0xb')]('in',_0x29d1e9('0x36')),'defaultValue':'out','allowNull':![]}),_0x3799f2[_0x29d1e9('0x1f')](_0x29d1e9('0x10'),_0x29d1e9('0x38'),{'type':_0x1796f2[_0x29d1e9('0x4d')](0xbe)}),_0x3799f2[_0x29d1e9('0x20')]('mail_messages',_0x29d1e9('0x4')),_0x3799f2[_0x29d1e9('0x1f')]('mail_messages','to',{'type':_0x1796f2[_0x29d1e9('0x1')](_0x29d1e9('0x3a'))}),_0x3799f2['changeColumn']('mail_messages','cc',{'type':_0x1796f2[_0x29d1e9('0x1')](_0x29d1e9('0x3a'))}),_0x3799f2[_0x29d1e9('0x1f')](_0x29d1e9('0x10'),_0x29d1e9('0x4e'),{'type':_0x1796f2[_0x29d1e9('0x1')](_0x29d1e9('0x3a'))}),_0x3799f2[_0x29d1e9('0x1f')](_0x29d1e9('0x10'),_0x29d1e9('0x34'),{'type':_0x1796f2[_0x29d1e9('0x1')]}),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x10'),'sentAt',{'type':_0x1796f2['DATE']}),_0x3799f2['addColumn']('mail_messages','attach',{'type':_0x1796f2[_0x29d1e9('0x54')],'defaultValue':0x0}),_0x3799f2[_0x29d1e9('0x20')](_0x29d1e9('0x10'),_0x29d1e9('0x4c')),_0x3799f2['removeColumn'](_0x29d1e9('0x10'),_0x29d1e9('0x16')),_0x3799f2['removeColumn'](_0x29d1e9('0x10'),_0x29d1e9('0x51')),_0x3799f2[_0x29d1e9('0x20')]('mail_messages',_0x29d1e9('0x48')),_0x3799f2['removeColumn']('mail_messages',_0x29d1e9('0x29')),_0x3799f2['removeColumn'](_0x29d1e9('0x10'),_0x29d1e9('0x37')),_0x3799f2['removeColumn'](_0x29d1e9('0x10'),'status'),_0x3799f2[_0x29d1e9('0x20')](_0x29d1e9('0x10'),_0x29d1e9('0x3c')),_0x3799f2['removeColumn'](_0x29d1e9('0x10'),_0x29d1e9('0x52')),_0x3799f2[_0x29d1e9('0x20')](_0x29d1e9('0x10'),_0x29d1e9('0x24')),_0x3799f2[_0x29d1e9('0x20')](_0x29d1e9('0x10'),_0x29d1e9('0x19')),_0x3799f2[_0x29d1e9('0x20')]('mail_messages',_0x29d1e9('0x5b')),_0x3799f2['removeColumn'](_0x29d1e9('0x10'),_0x29d1e9('0x3')),_0x3799f2[_0x29d1e9('0x20')](_0x29d1e9('0x10'),'MailInteractionId'),_0x3799f2['addColumn'](_0x29d1e9('0x10'),_0x29d1e9('0x8'),{'type':_0x1796f2[_0x29d1e9('0x54')]}),_0x3799f2['query'](_0x29d1e9('0x53')),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x10'),_0x29d1e9('0x5c'),{'type':_0x1796f2[_0x29d1e9('0x54')]}),_0x3799f2['query'](_0x29d1e9('0x15')),_0x3799f2['addColumn'](_0x29d1e9('0x10'),'UserId',{'type':_0x1796f2['INTEGER']}),_0x3799f2[_0x29d1e9('0x3d')](_0x29d1e9('0x56')),_0x3799f2['addColumn']('mail_messages',_0x29d1e9('0x31'),{'type':_0x1796f2[_0x29d1e9('0x54')]}),_0x3799f2['query'](_0x29d1e9('0x57')),_0x3799f2[_0x29d1e9('0x3d')](_0x29d1e9('0x4f')),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0xc'),_0x29d1e9('0x21'),{'type':_0x1796f2[_0x29d1e9('0x22')],'defaultValue':![]}),_0x3799f2['addColumn'](_0x29d1e9('0x43'),_0x29d1e9('0x2d'),{'type':_0x1796f2[_0x29d1e9('0x1')]}),_0x3799f2['removeColumn'](_0x29d1e9('0xe'),_0x29d1e9('0x34')),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x3f'),_0x29d1e9('0x2f'),{'type':_0x1796f2[_0x29d1e9('0x22')],'defaultValue':![]}),_0x3799f2[_0x29d1e9('0x39')]('users',_0x29d1e9('0x18'),{'type':_0x1796f2[_0x29d1e9('0x54')],'defaultValue':0x0}),_0x3799f2[_0x29d1e9('0x1a')](_0x29d1e9('0x1b')),_0x3799f2['dropTable'](_0x29d1e9('0x28')),_0x3799f2[_0x29d1e9('0x1a')]('report_chat'),_0x3799f2[_0x29d1e9('0x1a')]('report_chat_session'),_0x3799f2[_0x29d1e9('0x1a')](_0x29d1e9('0x25')),_0x3799f2[_0x29d1e9('0x1a')](_0x29d1e9('0x32')),_0x3799f2[_0x29d1e9('0x1a')](_0x29d1e9('0x2c')),_0x3799f2[_0x29d1e9('0x1a')](_0x29d1e9('0x6')),_0x3799f2[_0x29d1e9('0x1a')]('report_sms'),_0x3799f2[_0x29d1e9('0x1a')](_0x29d1e9('0xa')),_0x3799f2[_0x29d1e9('0x39')]('cm_hopper_history',_0x29d1e9('0x23'),{'type':_0x1796f2[_0x29d1e9('0x58')]}),_0x3799f2[_0x29d1e9('0x39')](_0x29d1e9('0x35'),_0x29d1e9('0x11'),{'type':_0x1796f2[_0x29d1e9('0x22')],'defaultValue':![]}),_0x3799f2[_0x29d1e9('0x39')]('voice_queues','dialOrderByScheduledAt',{'type':_0x1796f2['ENUM'](_0x29d1e9('0x3e'),_0x29d1e9('0x55')),'defaultValue':_0x29d1e9('0x3e')}),_0x3799f2['addColumn'](_0x29d1e9('0x49'),_0x29d1e9('0x40'),{'type':_0x1796f2['ENUM'](_0x29d1e9('0x3e'),'ASC'),'defaultValue':_0x29d1e9('0x3e')}),_0x3799f2[_0x29d1e9('0x47')](_0x55a05f);});},'down':function(){}}; \ No newline at end of file +const a914_0x24b2=['sequelize','report_fax_session','../config/logger','then','attach','customerIp','addIndex','changeColumn','retry','ratingType','edited','finally','userFullname','bcc','text','UserId','dropTable','removeColumn','catch','body','analytics_custom_reports','accountName','mail_accounts','ALTER\x20TABLE\x20`mail_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_messages_ibfk_4`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`ContactId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20cm_contacts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','util','subject','mail_messages','out','cm_hopper_history','MailInteractionId','auto','direction','userName','ALTER\x20TABLE\x20`mail_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_messages_ibfk_2`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`MailInteractionId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20mail_interactions(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','report_sms_session','Changed\x20column\x20%s\x20in\x20table\x20%s','thumb','report_openchannel_session','messageId','ALTER\x20TABLE\x20chat_interactions\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;','DATE','long','BOOLEAN','dialOrderByScheduledAt','report_mail','query','sequence','chat_websites','chat_interactions','migration','join','prototype','ContactId','users','Send','Removed\x20column\x20%s\x20from\x20%s','addIndex\x20%s\x20%s\x20%s','final','accountId','signature','html','analytics_default_reports','voiceSource','report_fax','fromId','addColumn','campaigns','Added\x20column\x20%s\x20to\x20%s','stringify','DESC','reason','tools_templates','joins','voice_queues','STRING','TEXT','ENUM','ALTER\x20TABLE\x20`mail_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_messages_ibfk_1`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20mail_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL','editedat','phoneBarEnableDtmfTone','exports','INTEGER','info','enqueue','enableCustomerAttachment','queryInterface'];(function(_0x32c31b,_0x24b2bc){const _0x53ab92=function(_0x9839a1){while(--_0x9839a1){_0x32c31b['push'](_0x32c31b['shift']());}};_0x53ab92(++_0x24b2bc);}(a914_0x24b2,0x1f4));const a914_0x53ab=function(_0x32c31b,_0x24b2bc){_0x32c31b=_0x32c31b-0x0;let _0x53ab92=a914_0x24b2[_0x32c31b];return _0x53ab92;};const _0x5a86bf=a914_0x53ab;'use strict';const logger=require(_0x5a86bf('0x12'))(_0x5a86bf('0x41')),util=require(_0x5a86bf('0x28')),Sequence=function(){};Sequence['prototype'][_0x5a86bf('0xd')]=function(_0x9839a1){const _0x17f5ae=_0x5a86bf;this['tail']=this['tail']?this['tail'][_0x17f5ae('0x1b')](_0x9839a1):_0x9839a1();};const Migration=function(_0x37b14d){const _0x2ff7cb=_0x5a86bf;this['queryInterface']=_0x37b14d,this[_0x2ff7cb('0x3e')]=new Sequence();};Migration[_0x5a86bf('0x43')]['changeColumn']=function(_0xa72bb0,_0xe57a88,_0x205c10){const _0x4fc315=_0x5a86bf,_0x4d4e8d=this;this['sequence'][_0x4fc315('0xd')](function(){const _0x21220f=_0x4fc315;return _0x4d4e8d[_0x21220f('0xf')][_0x21220f('0x17')](_0xa72bb0,_0xe57a88,_0x205c10)[_0x21220f('0x13')](function(){const _0x46dada=_0x21220f;logger[_0x46dada('0xc')](_0x46dada('0x33'),_0xe57a88,_0xa72bb0);})['catch'](function(_0x185b4f){const _0x3765d7=_0x21220f;logger[_0x3765d7('0xc')](JSON[_0x3765d7('0x54')](_0x185b4f));});});},Migration[_0x5a86bf('0x43')][_0x5a86bf('0x51')]=function(_0x5d65c5,_0x5d70f1,_0x1cdf36){const _0x21977a=_0x5a86bf,_0x70dd20=this;this[_0x21977a('0x3e')]['enqueue'](function(){const _0x4391fe=_0x21977a;return _0x70dd20['queryInterface'][_0x4391fe('0x51')](_0x5d65c5,_0x5d70f1,_0x1cdf36)[_0x4391fe('0x13')](function(){const _0x5cb816=_0x4391fe;logger[_0x5cb816('0xc')](_0x5cb816('0x53'),_0x5d70f1,_0x5d65c5);})['catch'](function(_0x58e343){const _0x12129c=_0x4391fe;logger['info'](JSON[_0x12129c('0x54')](_0x58e343));});});},Migration[_0x5a86bf('0x43')]['dropTable']=function(_0x536504){const _0x17717b=_0x5a86bf,_0x52d57f=this;this[_0x17717b('0x3e')][_0x17717b('0xd')](function(){const _0x522482=_0x17717b;return _0x52d57f[_0x522482('0xf')][_0x522482('0x20')](_0x536504,{'force':!![]})[_0x522482('0x13')](function(){const _0x37722a=_0x522482;logger[_0x37722a('0xc')]('table\x20dropped\x20%s',_0x536504);})[_0x522482('0x22')](function(_0x53dd5d){const _0x4984a6=_0x522482;logger[_0x4984a6('0xc')](JSON['stringify'](_0x53dd5d));});});},Migration[_0x5a86bf('0x43')][_0x5a86bf('0x16')]=function(_0x51c2c3,_0x5d9527,_0x3ccc60){const _0xd14e72=_0x5a86bf,_0xeb5793=this;this[_0xd14e72('0x3e')]['enqueue'](function(){const _0x4282a2=_0xd14e72;return _0xeb5793[_0x4282a2('0xf')][_0x4282a2('0x16')](_0x51c2c3,_0x5d9527,{'indexName':_0x3ccc60})[_0x4282a2('0x13')](function(){const _0x422b96=_0x4282a2;logger[_0x422b96('0xc')](_0x422b96('0x48'),_0x51c2c3,_0x5d9527[_0x422b96('0x42')](','),_0x3ccc60);})[_0x4282a2('0x22')](function(_0x5d04b5){const _0x27c7d4=_0x4282a2;logger[_0x27c7d4('0xc')](JSON[_0x27c7d4('0x54')](_0x5d04b5));});});},Migration[_0x5a86bf('0x43')][_0x5a86bf('0x3d')]=function(_0x1fb06e){const _0x547dc7=_0x5a86bf,_0x1dd264=this;this['sequence'][_0x547dc7('0xd')](function(){const _0x286fc5=_0x547dc7;return _0x1dd264[_0x286fc5('0xf')][_0x286fc5('0x10')][_0x286fc5('0x3d')](_0x1fb06e)['then'](function(){const _0x2ca38f=_0x286fc5;logger[_0x2ca38f('0xc')]('query\x20%s',_0x1fb06e);})[_0x286fc5('0x22')](function(_0x595ab5){const _0x59ffed=_0x286fc5;logger[_0x59ffed('0xc')](JSON[_0x59ffed('0x54')](_0x595ab5));});});},Migration[_0x5a86bf('0x43')][_0x5a86bf('0x21')]=function(_0x355e68,_0xc0a428){const _0x557558=_0x5a86bf,_0x2ee462=this;this['sequence'][_0x557558('0xd')](function(){const _0x88e48d=_0x557558;return _0x2ee462[_0x88e48d('0xf')][_0x88e48d('0x21')](_0x355e68,_0xc0a428)[_0x88e48d('0x13')](function(){const _0x3f247d=_0x88e48d;logger[_0x3f247d('0xc')](_0x3f247d('0x47'),_0xc0a428,_0x355e68);})[_0x88e48d('0x22')](function(_0x3198b9){const _0x16f9d2=_0x88e48d;logger[_0x16f9d2('0xc')](util['inspect'](_0x3198b9,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x5a86bf('0x49')]=function(_0xd889f6){const _0x15e42d=_0x5a86bf;this['sequence'][_0x15e42d('0xd')](function(){return _0xd889f6();});},module[_0x5a86bf('0xa')]={'up':function(_0x18b7d5,_0x24d5fc){return new Promise(function(_0x223baa){const _0x15e7c6=a914_0x53ab,_0x3a77ef=new Migration(_0x18b7d5);_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x24'),'joins',{'type':_0x24d5fc[_0x15e7c6('0x5')]}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x4d'),_0x15e7c6('0x2'),{'type':_0x24d5fc[_0x15e7c6('0x5')]}),_0x3a77ef[_0x15e7c6('0x3d')]('ALTER\x20TABLE\x20`chat_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`chat_messages_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`AttachmentId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20attachments(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL'),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x3f'),'offline_chat_button',{'type':_0x24d5fc[_0x15e7c6('0x4')],'defaultValue':_0x15e7c6('0x46')}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x3f'),_0x15e7c6('0xe'),{'type':_0x24d5fc[_0x15e7c6('0x3a')],'defaultValue':![]}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x40'),'referer',{'type':_0x24d5fc['STRING']}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x40'),_0x15e7c6('0x15'),{'type':_0x24d5fc[_0x15e7c6('0x4')]}),_0x3a77ef['addColumn'](_0x15e7c6('0x40'),_0x15e7c6('0x19'),{'type':_0x24d5fc[_0x15e7c6('0x6')]('star',_0x15e7c6('0x34')),'defaultValue':'star'}),_0x3a77ef[_0x15e7c6('0x3d')](_0x15e7c6('0x37')),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x2a'),_0x15e7c6('0x23'),{'type':_0x24d5fc[_0x15e7c6('0x5')]('long'),'allowNull':![]}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x2a'),'read',{'type':_0x24d5fc['BOOLEAN'],'defaultValue':![]}),_0x3a77ef['addColumn'](_0x15e7c6('0x2a'),_0x15e7c6('0x2f'),{'type':_0x24d5fc[_0x15e7c6('0x6')]('in',_0x15e7c6('0x2b')),'defaultValue':_0x15e7c6('0x2b'),'allowNull':![]}),_0x3a77ef[_0x15e7c6('0x17')]('mail_messages',_0x15e7c6('0x36'),{'type':_0x24d5fc[_0x15e7c6('0x4')](0xbe)}),_0x3a77ef[_0x15e7c6('0x21')](_0x15e7c6('0x2a'),'inReplyTo'),_0x3a77ef['changeColumn'](_0x15e7c6('0x2a'),'to',{'type':_0x24d5fc[_0x15e7c6('0x5')](_0x15e7c6('0x39'))}),_0x3a77ef['changeColumn'](_0x15e7c6('0x2a'),'cc',{'type':_0x24d5fc['TEXT'](_0x15e7c6('0x39'))}),_0x3a77ef[_0x15e7c6('0x17')](_0x15e7c6('0x2a'),_0x15e7c6('0x1d'),{'type':_0x24d5fc[_0x15e7c6('0x5')]('long')}),_0x3a77ef[_0x15e7c6('0x17')](_0x15e7c6('0x2a'),_0x15e7c6('0x29'),{'type':_0x24d5fc['TEXT']}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x2a'),'sentAt',{'type':_0x24d5fc[_0x15e7c6('0x38')]}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x2a'),_0x15e7c6('0x14'),{'type':_0x24d5fc['INTEGER'],'defaultValue':0x0}),_0x3a77ef['removeColumn']('mail_messages',_0x15e7c6('0x50')),_0x3a77ef[_0x15e7c6('0x21')](_0x15e7c6('0x2a'),'attachment'),_0x3a77ef['removeColumn'](_0x15e7c6('0x2a'),_0x15e7c6('0x1e')),_0x3a77ef[_0x15e7c6('0x21')]('mail_messages',_0x15e7c6('0x4c')),_0x3a77ef[_0x15e7c6('0x21')](_0x15e7c6('0x2a'),_0x15e7c6('0x0')),_0x3a77ef['removeColumn']('mail_messages',_0x15e7c6('0x2e')),_0x3a77ef[_0x15e7c6('0x21')](_0x15e7c6('0x2a'),'status'),_0x3a77ef[_0x15e7c6('0x21')](_0x15e7c6('0x2a'),_0x15e7c6('0x18')),_0x3a77ef['removeColumn']('mail_messages',_0x15e7c6('0x4e')),_0x3a77ef['removeColumn'](_0x15e7c6('0x2a'),_0x15e7c6('0x30')),_0x3a77ef['removeColumn']('mail_messages',_0x15e7c6('0x1c')),_0x3a77ef['removeColumn']('mail_messages',_0x15e7c6('0x4a')),_0x3a77ef['removeColumn'](_0x15e7c6('0x2a'),_0x15e7c6('0x25')),_0x3a77ef[_0x15e7c6('0x21')](_0x15e7c6('0x2a'),_0x15e7c6('0x2d')),_0x3a77ef['addColumn'](_0x15e7c6('0x2a'),'MailAccountId',{'type':_0x24d5fc[_0x15e7c6('0xb')]}),_0x3a77ef[_0x15e7c6('0x3d')](_0x15e7c6('0x7')),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x2a'),_0x15e7c6('0x2d'),{'type':_0x24d5fc['INTEGER']}),_0x3a77ef[_0x15e7c6('0x3d')](_0x15e7c6('0x31')),_0x3a77ef['addColumn'](_0x15e7c6('0x2a'),_0x15e7c6('0x1f'),{'type':_0x24d5fc['INTEGER']}),_0x3a77ef[_0x15e7c6('0x3d')]('ALTER\x20TABLE\x20`mail_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_messages_ibfk_3`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`UserId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20users(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL'),_0x3a77ef['addColumn']('mail_messages',_0x15e7c6('0x44'),{'type':_0x24d5fc[_0x15e7c6('0xb')]}),_0x3a77ef[_0x15e7c6('0x3d')](_0x15e7c6('0x27')),_0x3a77ef[_0x15e7c6('0x3d')]('ALTER\x20TABLE\x20mail_messages\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;'),_0x3a77ef['addColumn']('mail_interactions',_0x15e7c6('0x14'),{'type':_0x24d5fc[_0x15e7c6('0x3a')],'defaultValue':![]}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x26'),_0x15e7c6('0x4b'),{'type':_0x24d5fc[_0x15e7c6('0x5')]}),_0x3a77ef[_0x15e7c6('0x21')](_0x15e7c6('0x1'),'subject'),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x45'),_0x15e7c6('0x9'),{'type':_0x24d5fc[_0x15e7c6('0x3a')],'defaultValue':![]}),_0x3a77ef['addColumn'](_0x15e7c6('0x45'),'phoneBarAutoAnswerDelay',{'type':_0x24d5fc[_0x15e7c6('0xb')],'defaultValue':0x0}),_0x3a77ef['dropTable']('report_openchannel'),_0x3a77ef[_0x15e7c6('0x20')](_0x15e7c6('0x35')),_0x3a77ef[_0x15e7c6('0x20')]('report_chat'),_0x3a77ef[_0x15e7c6('0x20')]('report_chat_session'),_0x3a77ef[_0x15e7c6('0x20')](_0x15e7c6('0x4f')),_0x3a77ef[_0x15e7c6('0x20')](_0x15e7c6('0x11')),_0x3a77ef[_0x15e7c6('0x20')](_0x15e7c6('0x3c')),_0x3a77ef[_0x15e7c6('0x20')]('report_mail_session'),_0x3a77ef[_0x15e7c6('0x20')]('report_sms'),_0x3a77ef[_0x15e7c6('0x20')](_0x15e7c6('0x32')),_0x3a77ef[_0x15e7c6('0x51')]('cm_hopper_history',_0x15e7c6('0x8'),{'type':_0x24d5fc[_0x15e7c6('0x38')]}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x2c'),_0x15e7c6('0x1a'),{'type':_0x24d5fc[_0x15e7c6('0x3a')],'defaultValue':![]}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x3'),_0x15e7c6('0x3b'),{'type':_0x24d5fc['ENUM'](_0x15e7c6('0x55'),'ASC'),'defaultValue':_0x15e7c6('0x55')}),_0x3a77ef[_0x15e7c6('0x51')](_0x15e7c6('0x52'),'dialOrderByScheduledAt',{'type':_0x24d5fc[_0x15e7c6('0x6')]('DESC','ASC'),'defaultValue':'DESC'}),_0x3a77ef[_0x15e7c6('0x49')](_0x223baa);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.36.js b/server/migrations/2.0.36.js index b520470..944edaa 100644 --- a/server/migrations/2.0.36.js +++ b/server/migrations/2.0.36.js @@ -1 +1 @@ -const a915_0x3e77=['Changed\x20column\x20%s\x20in\x20table\x20%s','tail','stringify','prototype','AttachmentId','final','info','migration','removeColumn','exports','addColumn','dropTable','sequelize','queryInterface','INTEGER','inspect','Added\x20column\x20%s\x20to\x20%s','addIndex','catch','query','../config/logger','then','query\x20%s','sequence','enqueue','openchannel_messages','join','Removed\x20column\x20%s\x20from\x20%s'];(function(_0x997bb0,_0x3e7754){const _0x37a6ae=function(_0x1e4427){while(--_0x1e4427){_0x997bb0['push'](_0x997bb0['shift']());}};_0x37a6ae(++_0x3e7754);}(a915_0x3e77,0x1a2));const a915_0x37a6=function(_0x997bb0,_0x3e7754){_0x997bb0=_0x997bb0-0x0;let _0x37a6ae=a915_0x3e77[_0x997bb0];return _0x37a6ae;};const _0x1d2e7a=a915_0x37a6;'use strict';const logger=require(_0x1d2e7a('0x16'))(_0x1d2e7a('0x9')),util=require('util'),Sequence=function(){};Sequence[_0x1d2e7a('0x5')]['enqueue']=function(_0x1e4427){const _0x1d45be=_0x1d2e7a;this[_0x1d45be('0x3')]=this[_0x1d45be('0x3')]?this[_0x1d45be('0x3')]['finally'](_0x1e4427):_0x1e4427();};const Migration=function(_0x4cdf29){const _0x2e63d6=_0x1d2e7a;this[_0x2e63d6('0xf')]=_0x4cdf29,this[_0x2e63d6('0x19')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x392376,_0x368147,_0x16c431){const _0x5cf0c1=_0x1d2e7a,_0x3a3820=this;this[_0x5cf0c1('0x19')]['enqueue'](function(){const _0x26b479=_0x5cf0c1;return _0x3a3820['queryInterface']['changeColumn'](_0x392376,_0x368147,_0x16c431)['then'](function(){const _0x28fd99=a915_0x37a6;logger[_0x28fd99('0x8')](_0x28fd99('0x2'),_0x368147,_0x392376);})[_0x26b479('0x14')](function(_0x46cb45){const _0x11dce4=_0x26b479;logger[_0x11dce4('0x8')](JSON[_0x11dce4('0x4')](_0x46cb45));});});},Migration[_0x1d2e7a('0x5')][_0x1d2e7a('0xc')]=function(_0x572e98,_0x2a9d3d,_0x1001b3){const _0x1bd0cc=_0x1d2e7a,_0x56c441=this;this[_0x1bd0cc('0x19')]['enqueue'](function(){const _0x56d8f0=_0x1bd0cc;return _0x56c441[_0x56d8f0('0xf')][_0x56d8f0('0xc')](_0x572e98,_0x2a9d3d,_0x1001b3)[_0x56d8f0('0x17')](function(){const _0x3e3108=_0x56d8f0;logger['info'](_0x3e3108('0x12'),_0x2a9d3d,_0x572e98);})[_0x56d8f0('0x14')](function(_0x4f9570){logger['info'](JSON['stringify'](_0x4f9570));});});},Migration[_0x1d2e7a('0x5')][_0x1d2e7a('0xd')]=function(_0x15c248){const _0x28ea77=_0x1d2e7a,_0x63cd66=this;this['sequence'][_0x28ea77('0x1a')](function(){const _0x3b2227=_0x28ea77;return _0x63cd66[_0x3b2227('0xf')][_0x3b2227('0xd')](_0x15c248,{'force':!![]})['then'](function(){const _0x545eec=_0x3b2227;logger[_0x545eec('0x8')]('table\x20dropped\x20%s',_0x15c248);})[_0x3b2227('0x14')](function(_0x32067f){const _0x55eee7=_0x3b2227;logger[_0x55eee7('0x8')](JSON[_0x55eee7('0x4')](_0x32067f));});});},Migration[_0x1d2e7a('0x5')][_0x1d2e7a('0x13')]=function(_0x30f48f,_0x4f7881,_0x4189bd){const _0x46f8ea=_0x1d2e7a,_0x15799f=this;this[_0x46f8ea('0x19')]['enqueue'](function(){const _0x1aaac8=_0x46f8ea;return _0x15799f[_0x1aaac8('0xf')][_0x1aaac8('0x13')](_0x30f48f,_0x4f7881,{'indexName':_0x4189bd})['then'](function(){const _0x4242cd=_0x1aaac8;logger[_0x4242cd('0x8')]('addIndex\x20%s\x20%s\x20%s',_0x30f48f,_0x4f7881[_0x4242cd('0x0')](','),_0x4189bd);})[_0x1aaac8('0x14')](function(_0x1e9070){const _0x57bb52=_0x1aaac8;logger[_0x57bb52('0x8')](JSON['stringify'](_0x1e9070));});});},Migration[_0x1d2e7a('0x5')][_0x1d2e7a('0x15')]=function(_0xdd3661){const _0x35f040=_0x1d2e7a,_0x11e088=this;this['sequence'][_0x35f040('0x1a')](function(){const _0xf2274f=_0x35f040;return _0x11e088[_0xf2274f('0xf')][_0xf2274f('0xe')]['query'](_0xdd3661)[_0xf2274f('0x17')](function(){const _0x4e9b0e=_0xf2274f;logger['info'](_0x4e9b0e('0x18'),_0xdd3661);})[_0xf2274f('0x14')](function(_0x1860bc){const _0x50cbea=_0xf2274f;logger[_0x50cbea('0x8')](JSON[_0x50cbea('0x4')](_0x1860bc));});});},Migration[_0x1d2e7a('0x5')][_0x1d2e7a('0xa')]=function(_0x5bf5e3,_0x739a84){const _0x35dc9a=_0x1d2e7a,_0x4c6d79=this;this[_0x35dc9a('0x19')][_0x35dc9a('0x1a')](function(){const _0xebab58=_0x35dc9a;return _0x4c6d79['queryInterface'][_0xebab58('0xa')](_0x5bf5e3,_0x739a84)[_0xebab58('0x17')](function(){const _0x3f93e7=_0xebab58;logger[_0x3f93e7('0x8')](_0x3f93e7('0x1'),_0x739a84,_0x5bf5e3);})[_0xebab58('0x14')](function(_0xacb1d){const _0x5824ee=_0xebab58;logger[_0x5824ee('0x8')](util[_0x5824ee('0x11')](_0xacb1d,{'showHidden':![],'depth':null}));});});},Migration[_0x1d2e7a('0x5')]['final']=function(_0x423e80){const _0x113d79=_0x1d2e7a;this[_0x113d79('0x19')]['enqueue'](function(){return _0x423e80();});},module[_0x1d2e7a('0xb')]={'up':function(_0x559727,_0x2c31ad){return new Promise(function(_0x41bdf4){const _0x1cb681=a915_0x37a6,_0x3d539d=new Migration(_0x559727);_0x3d539d[_0x1cb681('0xc')](_0x1cb681('0x1b'),_0x1cb681('0x6'),{'type':_0x2c31ad[_0x1cb681('0x10')]}),_0x3d539d[_0x1cb681('0x15')]('ALTER\x20TABLE\x20`openchannel_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`openchannel_messages_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`AttachmentId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20attachments(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL'),_0x3d539d[_0x1cb681('0x7')](_0x41bdf4);});},'down':function(){}}; \ No newline at end of file +const a915_0x12d3=['sequence','INTEGER','query','exports','table\x20dropped\x20%s','prototype','sequelize','Changed\x20column\x20%s\x20in\x20table\x20%s','../config/logger','ALTER\x20TABLE\x20`openchannel_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`openchannel_messages_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`AttachmentId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20attachments(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL','dropTable','AttachmentId','enqueue','addIndex\x20%s\x20%s\x20%s','addColumn','stringify','openchannel_messages','util','changeColumn','tail','removeColumn','queryInterface','join','addIndex','finally','Removed\x20column\x20%s\x20from\x20%s','Added\x20column\x20%s\x20to\x20%s','then','catch','info'];(function(_0x1f2f9d,_0x12d356){const _0x559b02=function(_0x4b3b29){while(--_0x4b3b29){_0x1f2f9d['push'](_0x1f2f9d['shift']());}};_0x559b02(++_0x12d356);}(a915_0x12d3,0x108));const a915_0x559b=function(_0x1f2f9d,_0x12d356){_0x1f2f9d=_0x1f2f9d-0x0;let _0x559b02=a915_0x12d3[_0x1f2f9d];return _0x559b02;};const _0x596a70=a915_0x559b;'use strict';const logger=require(_0x596a70('0xe'))('migration'),util=require(_0x596a70('0x17')),Sequence=function(){};Sequence[_0x596a70('0xb')][_0x596a70('0x12')]=function(_0x4b3b29){const _0x20de74=_0x596a70;this['tail']=this['tail']?this[_0x20de74('0x19')][_0x20de74('0x0')](_0x4b3b29):_0x4b3b29();};const Migration=function(_0x594618){const _0x2afa6d=_0x596a70;this[_0x2afa6d('0x1b')]=_0x594618,this[_0x2afa6d('0x6')]=new Sequence();};Migration[_0x596a70('0xb')][_0x596a70('0x18')]=function(_0x3edc91,_0x79c512,_0x5f4424){const _0x34db4d=_0x596a70,_0x1afbef=this;this['sequence'][_0x34db4d('0x12')](function(){const _0x13ab0d=_0x34db4d;return _0x1afbef['queryInterface'][_0x13ab0d('0x18')](_0x3edc91,_0x79c512,_0x5f4424)[_0x13ab0d('0x3')](function(){const _0x1c1ee3=_0x13ab0d;logger[_0x1c1ee3('0x5')](_0x1c1ee3('0xd'),_0x79c512,_0x3edc91);})['catch'](function(_0x44ab5b){const _0x35cd0d=_0x13ab0d;logger['info'](JSON[_0x35cd0d('0x15')](_0x44ab5b));});});},Migration['prototype'][_0x596a70('0x14')]=function(_0x14ce2d,_0x45cc9a,_0x21c79c){const _0x136df7=this;this['sequence']['enqueue'](function(){const _0x1356be=a915_0x559b;return _0x136df7[_0x1356be('0x1b')][_0x1356be('0x14')](_0x14ce2d,_0x45cc9a,_0x21c79c)[_0x1356be('0x3')](function(){const _0x468aef=_0x1356be;logger[_0x468aef('0x5')](_0x468aef('0x2'),_0x45cc9a,_0x14ce2d);})[_0x1356be('0x4')](function(_0x1013c6){const _0x4d956b=_0x1356be;logger[_0x4d956b('0x5')](JSON['stringify'](_0x1013c6));});});},Migration['prototype']['dropTable']=function(_0x5d63b8){const _0x5bc7f5=_0x596a70,_0x5befcb=this;this[_0x5bc7f5('0x6')][_0x5bc7f5('0x12')](function(){const _0x2238d8=_0x5bc7f5;return _0x5befcb[_0x2238d8('0x1b')][_0x2238d8('0x10')](_0x5d63b8,{'force':!![]})[_0x2238d8('0x3')](function(){const _0x455956=_0x2238d8;logger['info'](_0x455956('0xa'),_0x5d63b8);})[_0x2238d8('0x4')](function(_0x1ef12c){const _0x5cdb7d=_0x2238d8;logger[_0x5cdb7d('0x5')](JSON[_0x5cdb7d('0x15')](_0x1ef12c));});});},Migration['prototype'][_0x596a70('0x1d')]=function(_0x483b0d,_0x1a80ef,_0x42c9de){const _0x22104a=_0x596a70,_0x561c13=this;this[_0x22104a('0x6')][_0x22104a('0x12')](function(){const _0x28a503=_0x22104a;return _0x561c13[_0x28a503('0x1b')][_0x28a503('0x1d')](_0x483b0d,_0x1a80ef,{'indexName':_0x42c9de})[_0x28a503('0x3')](function(){const _0x1f559f=_0x28a503;logger[_0x1f559f('0x5')](_0x1f559f('0x13'),_0x483b0d,_0x1a80ef[_0x1f559f('0x1c')](','),_0x42c9de);})[_0x28a503('0x4')](function(_0x2df166){const _0x12929d=_0x28a503;logger['info'](JSON[_0x12929d('0x15')](_0x2df166));});});},Migration[_0x596a70('0xb')][_0x596a70('0x8')]=function(_0x5836a4){const _0x4bdfc7=_0x596a70,_0x2362a1=this;this[_0x4bdfc7('0x6')][_0x4bdfc7('0x12')](function(){const _0x7ff2a8=_0x4bdfc7;return _0x2362a1[_0x7ff2a8('0x1b')][_0x7ff2a8('0xc')][_0x7ff2a8('0x8')](_0x5836a4)[_0x7ff2a8('0x3')](function(){const _0x543840=_0x7ff2a8;logger[_0x543840('0x5')]('query\x20%s',_0x5836a4);})[_0x7ff2a8('0x4')](function(_0x45edb3){const _0x22ca9a=_0x7ff2a8;logger[_0x22ca9a('0x5')](JSON[_0x22ca9a('0x15')](_0x45edb3));});});},Migration[_0x596a70('0xb')]['removeColumn']=function(_0x2f1521,_0x596ad8){const _0x56faaf=_0x596a70,_0x4d1d17=this;this['sequence'][_0x56faaf('0x12')](function(){const _0x4b34b7=_0x56faaf;return _0x4d1d17[_0x4b34b7('0x1b')][_0x4b34b7('0x1a')](_0x2f1521,_0x596ad8)[_0x4b34b7('0x3')](function(){const _0xeccfad=_0x4b34b7;logger[_0xeccfad('0x5')](_0xeccfad('0x1'),_0x596ad8,_0x2f1521);})[_0x4b34b7('0x4')](function(_0x2215b1){const _0x4e65df=_0x4b34b7;logger[_0x4e65df('0x5')](util['inspect'](_0x2215b1,{'showHidden':![],'depth':null}));});});},Migration[_0x596a70('0xb')]['final']=function(_0x2ce6a6){const _0x12b9c9=_0x596a70;this[_0x12b9c9('0x6')][_0x12b9c9('0x12')](function(){return _0x2ce6a6();});},module[_0x596a70('0x9')]={'up':function(_0x2192ea,_0x281e65){return new Promise(function(_0x250927){const _0x100bfe=a915_0x559b,_0x31cb01=new Migration(_0x2192ea);_0x31cb01[_0x100bfe('0x14')](_0x100bfe('0x16'),_0x100bfe('0x11'),{'type':_0x281e65[_0x100bfe('0x7')]}),_0x31cb01[_0x100bfe('0x8')](_0x100bfe('0xf')),_0x31cb01['final'](_0x250927);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.37.js b/server/migrations/2.0.37.js index e97286d..25d3176 100644 --- a/server/migrations/2.0.37.js +++ b/server/migrations/2.0.37.js @@ -1 +1 @@ -const a916_0x1f5a=['addColumn','phone','changeColumn','stringify','STRING','dropTable','addIndex','join','prototype','jscripty_projects','Added\x20column\x20%s\x20to\x20%s','queryInterface','sequence','sms_interactions','tail','inspect','Changed\x20column\x20%s\x20in\x20table\x20%s','table\x20dropped\x20%s','removeColumn','query\x20%s','enqueue','info','migration','catch','query','completed','../config/logger','then','exports','util','addIndex\x20%s\x20%s\x20%s','UPDATE\x20report_jscripty_sessions\x20SET\x20completed\x20=\x20true','BOOLEAN','final','finally'];(function(_0x2cccd1,_0x1f5a28){const _0x360446=function(_0x2f1b14){while(--_0x2f1b14){_0x2cccd1['push'](_0x2cccd1['shift']());}};_0x360446(++_0x1f5a28);}(a916_0x1f5a,0xec));const a916_0x3604=function(_0x2cccd1,_0x1f5a28){_0x2cccd1=_0x2cccd1-0x0;let _0x360446=a916_0x1f5a[_0x2cccd1];return _0x360446;};const _0x316048=a916_0x3604;'use strict';const logger=require(_0x316048('0x0'))(_0x316048('0x1f')),util=require(_0x316048('0x3')),Sequence=function(){};Sequence[_0x316048('0x11')]['enqueue']=function(_0x2f1b14){const _0xaecbfc=_0x316048;this[_0xaecbfc('0x17')]=this[_0xaecbfc('0x17')]?this[_0xaecbfc('0x17')][_0xaecbfc('0x8')](_0x2f1b14):_0x2f1b14();};const Migration=function(_0x464c34){const _0x139ee3=_0x316048;this[_0x139ee3('0x14')]=_0x464c34,this[_0x139ee3('0x15')]=new Sequence();};Migration[_0x316048('0x11')][_0x316048('0xb')]=function(_0x40fa48,_0x2fb056,_0xb479f0){const _0x374709=_0x316048,_0x206cc8=this;this[_0x374709('0x15')][_0x374709('0x1d')](function(){const _0x354a0e=_0x374709;return _0x206cc8['queryInterface'][_0x354a0e('0xb')](_0x40fa48,_0x2fb056,_0xb479f0)[_0x354a0e('0x1')](function(){const _0x16ea2e=_0x354a0e;logger[_0x16ea2e('0x1e')](_0x16ea2e('0x19'),_0x2fb056,_0x40fa48);})[_0x354a0e('0x20')](function(_0x3773f3){const _0x5d7c68=_0x354a0e;logger[_0x5d7c68('0x1e')](JSON['stringify'](_0x3773f3));});});},Migration[_0x316048('0x11')][_0x316048('0x9')]=function(_0x1f1e00,_0x23f509,_0x4c5a2a){const _0x43a5df=this;this['sequence']['enqueue'](function(){const _0x564898=a916_0x3604;return _0x43a5df[_0x564898('0x14')][_0x564898('0x9')](_0x1f1e00,_0x23f509,_0x4c5a2a)[_0x564898('0x1')](function(){const _0xab6269=_0x564898;logger['info'](_0xab6269('0x13'),_0x23f509,_0x1f1e00);})[_0x564898('0x20')](function(_0x6bc80d){const _0x4757b4=_0x564898;logger[_0x4757b4('0x1e')](JSON[_0x4757b4('0xc')](_0x6bc80d));});});},Migration[_0x316048('0x11')]['dropTable']=function(_0x47e55b){const _0x3b2818=_0x316048,_0x26578f=this;this[_0x3b2818('0x15')][_0x3b2818('0x1d')](function(){const _0x398164=_0x3b2818;return _0x26578f[_0x398164('0x14')][_0x398164('0xe')](_0x47e55b,{'force':!![]})[_0x398164('0x1')](function(){const _0x2a4cef=_0x398164;logger[_0x2a4cef('0x1e')](_0x2a4cef('0x1a'),_0x47e55b);})[_0x398164('0x20')](function(_0x5948b9){const _0x1e0890=_0x398164;logger[_0x1e0890('0x1e')](JSON[_0x1e0890('0xc')](_0x5948b9));});});},Migration[_0x316048('0x11')][_0x316048('0xf')]=function(_0x5a04c5,_0x86110a,_0x238021){const _0x3ad690=_0x316048,_0x45a259=this;this[_0x3ad690('0x15')][_0x3ad690('0x1d')](function(){const _0x330dae=_0x3ad690;return _0x45a259[_0x330dae('0x14')][_0x330dae('0xf')](_0x5a04c5,_0x86110a,{'indexName':_0x238021})[_0x330dae('0x1')](function(){const _0x43bdd1=_0x330dae;logger[_0x43bdd1('0x1e')](_0x43bdd1('0x4'),_0x5a04c5,_0x86110a[_0x43bdd1('0x10')](','),_0x238021);})[_0x330dae('0x20')](function(_0x3f90bb){logger['info'](JSON['stringify'](_0x3f90bb));});});},Migration[_0x316048('0x11')]['query']=function(_0x1caeea){const _0x33156b=_0x316048,_0x45711e=this;this[_0x33156b('0x15')][_0x33156b('0x1d')](function(){const _0x41de44=_0x33156b;return _0x45711e[_0x41de44('0x14')]['sequelize'][_0x41de44('0x21')](_0x1caeea)['then'](function(){const _0x1cd0a9=_0x41de44;logger[_0x1cd0a9('0x1e')](_0x1cd0a9('0x1c'),_0x1caeea);})[_0x41de44('0x20')](function(_0xc5c168){const _0x4639a1=_0x41de44;logger[_0x4639a1('0x1e')](JSON['stringify'](_0xc5c168));});});},Migration[_0x316048('0x11')]['removeColumn']=function(_0x599574,_0x3b7de2){const _0x4b5da6=_0x316048,_0x47a544=this;this['sequence'][_0x4b5da6('0x1d')](function(){const _0x790745=_0x4b5da6;return _0x47a544['queryInterface'][_0x790745('0x1b')](_0x599574,_0x3b7de2)[_0x790745('0x1')](function(){const _0xefc637=_0x790745;logger[_0xefc637('0x1e')]('Removed\x20column\x20%s\x20from\x20%s',_0x3b7de2,_0x599574);})['catch'](function(_0x106a82){const _0x336153=_0x790745;logger[_0x336153('0x1e')](util[_0x336153('0x18')](_0x106a82,{'showHidden':![],'depth':null}));});});},Migration[_0x316048('0x11')][_0x316048('0x7')]=function(_0x5287aa){const _0x4c4173=_0x316048;this['sequence'][_0x4c4173('0x1d')](function(){return _0x5287aa();});},module[_0x316048('0x2')]={'up':function(_0x4e87c8,_0x52c256){return new Promise(function(_0x4bde39){const _0x5d8cc4=a916_0x3604,_0xd9a94=new Migration(_0x4e87c8);_0xd9a94['addColumn'](_0x5d8cc4('0x12'),'enableUncompleteSave',{'type':_0x52c256['BOOLEAN'],'defaultValue':!![]}),_0xd9a94[_0x5d8cc4('0x9')]('report_jscripty_sessions',_0x5d8cc4('0x22'),{'type':_0x52c256[_0x5d8cc4('0x6')],'defaultValue':![]}),_0xd9a94[_0x5d8cc4('0x21')](_0x5d8cc4('0x5')),_0xd9a94['addColumn'](_0x5d8cc4('0x16'),_0x5d8cc4('0xa'),{'type':_0x52c256[_0x5d8cc4('0xd')]}),_0xd9a94['addColumn']('sms_messages',_0x5d8cc4('0xa'),{'type':_0x52c256[_0x5d8cc4('0xd')]}),_0xd9a94[_0x5d8cc4('0x7')](_0x4bde39);});},'down':function(){}}; \ No newline at end of file +const a916_0x30c2=['report_jscripty_sessions','join','sequence','enqueue','query','final','changeColumn','tail','dropTable','removeColumn','BOOLEAN','table\x20dropped\x20%s','addIndex','inspect','Added\x20column\x20%s\x20to\x20%s','prototype','stringify','info','then','phone','Changed\x20column\x20%s\x20in\x20table\x20%s','addColumn','STRING','../config/logger','queryInterface','query\x20%s','sms_interactions','catch','UPDATE\x20report_jscripty_sessions\x20SET\x20completed\x20=\x20true','enableUncompleteSave','migration','Removed\x20column\x20%s\x20from\x20%s'];(function(_0x4aad90,_0x30c2b6){const _0x283c08=function(_0x500123){while(--_0x500123){_0x4aad90['push'](_0x4aad90['shift']());}};_0x283c08(++_0x30c2b6);}(a916_0x30c2,0x186));const a916_0x283c=function(_0x4aad90,_0x30c2b6){_0x4aad90=_0x4aad90-0x0;let _0x283c08=a916_0x30c2[_0x4aad90];return _0x283c08;};const _0x42ade0=a916_0x283c;'use strict';const logger=require(_0x42ade0('0x11'))(_0x42ade0('0x18')),util=require('util'),Sequence=function(){};Sequence[_0x42ade0('0x9')][_0x42ade0('0x1d')]=function(_0x500123){const _0x3fe5a4=_0x42ade0;this[_0x3fe5a4('0x1')]=this['tail']?this[_0x3fe5a4('0x1')]['finally'](_0x500123):_0x500123();};const Migration=function(_0x3fd694){const _0x1332ca=_0x42ade0;this[_0x1332ca('0x12')]=_0x3fd694,this[_0x1332ca('0x1c')]=new Sequence();};Migration[_0x42ade0('0x9')][_0x42ade0('0x0')]=function(_0x942c06,_0x248e00,_0x58a59e){const _0x4e8eaf=_0x42ade0,_0x44463e=this;this[_0x4e8eaf('0x1c')][_0x4e8eaf('0x1d')](function(){const _0x55daaa=_0x4e8eaf;return _0x44463e[_0x55daaa('0x12')][_0x55daaa('0x0')](_0x942c06,_0x248e00,_0x58a59e)['then'](function(){const _0x527b82=_0x55daaa;logger[_0x527b82('0xb')](_0x527b82('0xe'),_0x248e00,_0x942c06);})[_0x55daaa('0x15')](function(_0x393b73){const _0x53229b=_0x55daaa;logger[_0x53229b('0xb')](JSON[_0x53229b('0xa')](_0x393b73));});});},Migration[_0x42ade0('0x9')]['addColumn']=function(_0x4f9369,_0x4392f,_0x20c014){const _0x1034b3=_0x42ade0,_0x250724=this;this['sequence'][_0x1034b3('0x1d')](function(){const _0x4372e3=_0x1034b3;return _0x250724[_0x4372e3('0x12')][_0x4372e3('0xf')](_0x4f9369,_0x4392f,_0x20c014)[_0x4372e3('0xc')](function(){const _0x2126d0=_0x4372e3;logger[_0x2126d0('0xb')](_0x2126d0('0x8'),_0x4392f,_0x4f9369);})[_0x4372e3('0x15')](function(_0x155397){const _0x485763=_0x4372e3;logger[_0x485763('0xb')](JSON[_0x485763('0xa')](_0x155397));});});},Migration[_0x42ade0('0x9')][_0x42ade0('0x2')]=function(_0x2635bb){const _0x4a4637=_0x42ade0,_0x460a73=this;this['sequence'][_0x4a4637('0x1d')](function(){const _0x2cde0d=_0x4a4637;return _0x460a73[_0x2cde0d('0x12')][_0x2cde0d('0x2')](_0x2635bb,{'force':!![]})[_0x2cde0d('0xc')](function(){const _0x7099c7=_0x2cde0d;logger[_0x7099c7('0xb')](_0x7099c7('0x5'),_0x2635bb);})[_0x2cde0d('0x15')](function(_0x9ff3be){const _0x4a5557=_0x2cde0d;logger['info'](JSON[_0x4a5557('0xa')](_0x9ff3be));});});},Migration['prototype'][_0x42ade0('0x6')]=function(_0x2df1aa,_0x4d7d24,_0x18e0aa){const _0x120385=_0x42ade0,_0x550a5d=this;this[_0x120385('0x1c')][_0x120385('0x1d')](function(){const _0x3f1d69=_0x120385;return _0x550a5d['queryInterface'][_0x3f1d69('0x6')](_0x2df1aa,_0x4d7d24,{'indexName':_0x18e0aa})['then'](function(){const _0xd99454=_0x3f1d69;logger[_0xd99454('0xb')]('addIndex\x20%s\x20%s\x20%s',_0x2df1aa,_0x4d7d24[_0xd99454('0x1b')](','),_0x18e0aa);})[_0x3f1d69('0x15')](function(_0x4ac2b7){const _0x30e728=_0x3f1d69;logger[_0x30e728('0xb')](JSON['stringify'](_0x4ac2b7));});});},Migration[_0x42ade0('0x9')][_0x42ade0('0x1e')]=function(_0x5dc117){const _0x485fcf=_0x42ade0,_0x40446f=this;this[_0x485fcf('0x1c')][_0x485fcf('0x1d')](function(){const _0x572ced=_0x485fcf;return _0x40446f[_0x572ced('0x12')]['sequelize'][_0x572ced('0x1e')](_0x5dc117)[_0x572ced('0xc')](function(){const _0x3313f3=_0x572ced;logger[_0x3313f3('0xb')](_0x3313f3('0x13'),_0x5dc117);})['catch'](function(_0x169023){const _0x3cd358=_0x572ced;logger['info'](JSON[_0x3cd358('0xa')](_0x169023));});});},Migration[_0x42ade0('0x9')]['removeColumn']=function(_0x3373a6,_0x76a56f){const _0x4a8507=_0x42ade0,_0x50b18f=this;this[_0x4a8507('0x1c')][_0x4a8507('0x1d')](function(){const _0x38367c=_0x4a8507;return _0x50b18f['queryInterface'][_0x38367c('0x3')](_0x3373a6,_0x76a56f)['then'](function(){const _0x44819a=_0x38367c;logger['info'](_0x44819a('0x19'),_0x76a56f,_0x3373a6);})['catch'](function(_0x397362){const _0x4a8415=_0x38367c;logger[_0x4a8415('0xb')](util[_0x4a8415('0x7')](_0x397362,{'showHidden':![],'depth':null}));});});},Migration[_0x42ade0('0x9')]['final']=function(_0x55f809){const _0x35a79e=_0x42ade0;this[_0x35a79e('0x1c')][_0x35a79e('0x1d')](function(){return _0x55f809();});},module['exports']={'up':function(_0x2c5484,_0x463e56){return new Promise(function(_0x3118ca){const _0x128e78=a916_0x283c,_0x43a6e8=new Migration(_0x2c5484);_0x43a6e8[_0x128e78('0xf')]('jscripty_projects',_0x128e78('0x17'),{'type':_0x463e56[_0x128e78('0x4')],'defaultValue':!![]}),_0x43a6e8[_0x128e78('0xf')](_0x128e78('0x1a'),'completed',{'type':_0x463e56[_0x128e78('0x4')],'defaultValue':![]}),_0x43a6e8[_0x128e78('0x1e')](_0x128e78('0x16')),_0x43a6e8[_0x128e78('0xf')](_0x128e78('0x14'),_0x128e78('0xd'),{'type':_0x463e56[_0x128e78('0x10')]}),_0x43a6e8[_0x128e78('0xf')]('sms_messages',_0x128e78('0xd'),{'type':_0x463e56[_0x128e78('0x10')]}),_0x43a6e8[_0x128e78('0x1f')](_0x3118ca);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.38.js b/server/migrations/2.0.38.js index 652105d..12e281c 100644 --- a/server/migrations/2.0.38.js +++ b/server/migrations/2.0.38.js @@ -1 +1 @@ -const a917_0x1754=['token','final','Removed\x20column\x20%s\x20from\x20%s','migration','STRING','dropTable','INTEGER','util','sms_messages','join','\x20Error\x20:','inspect','finally','Added\x20column\x20%s\x20to\x20%s','sequence','exec','Changed\x20column\x20%s\x20in\x20table\x20%s','addIndex','chown\x20motion:asterisk\x20/var/opt/motion2/server/files/attachments','fax_applications','prototype','queryInterface','sms_accounts','info','removeColumn','stringify','addColumn','remote','../config/logger','fax_messages','AttachmentId','enqueue','changeColumn','query\x20%s','then','query','sequelize','messageId','tools_trunks','catch','tail','t38pt_udptl','ALTER\x20TABLE\x20`fax_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`fax_messages_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`AttachmentId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20attachments(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL','addIndex\x20%s\x20%s\x20%s'];(function(_0x22d682,_0x17542f){const _0x110bcc=function(_0x57547e){while(--_0x57547e){_0x22d682['push'](_0x22d682['shift']());}};_0x110bcc(++_0x17542f);}(a917_0x1754,0x11f));const a917_0x110b=function(_0x22d682,_0x17542f){_0x22d682=_0x22d682-0x0;let _0x110bcc=a917_0x1754[_0x22d682];return _0x110bcc;};const _0x3c04c3=a917_0x110b;'use strict';const logger=require(_0x3c04c3('0x5'))(_0x3c04c3('0x18')),util=require(_0x3c04c3('0x1c')),exec=require('child_process')[_0x3c04c3('0x24')],cmd=_0x3c04c3('0x27'),ls='ls\x20-la\x20/var/opt/motion2/server/files',Sequence=function(){};Sequence[_0x3c04c3('0x29')][_0x3c04c3('0x8')]=function(_0x57547e){const _0x3c1f0d=_0x3c04c3;this[_0x3c1f0d('0x11')]=this[_0x3c1f0d('0x11')]?this['tail'][_0x3c1f0d('0x21')](_0x57547e):_0x57547e();};const Migration=function(_0xa49497){const _0x273ebf=_0x3c04c3;this[_0x273ebf('0x2a')]=_0xa49497,this[_0x273ebf('0x23')]=new Sequence();};Migration[_0x3c04c3('0x29')][_0x3c04c3('0x9')]=function(_0x1c863c,_0xb3e0c4,_0x465dd2){const _0x2630c8=this;this['sequence']['enqueue'](function(){const _0x23adba=a917_0x110b;return _0x2630c8['queryInterface']['changeColumn'](_0x1c863c,_0xb3e0c4,_0x465dd2)[_0x23adba('0xb')](function(){const _0x4c6522=_0x23adba;logger[_0x4c6522('0x0')](_0x4c6522('0x25'),_0xb3e0c4,_0x1c863c);})[_0x23adba('0x10')](function(_0x3ed5de){const _0x2bd045=_0x23adba;logger[_0x2bd045('0x0')](JSON[_0x2bd045('0x2')](_0x3ed5de));});});},Migration[_0x3c04c3('0x29')]['addColumn']=function(_0x5052a0,_0xb936b2,_0x1a13cf){const _0x21b1df=_0x3c04c3,_0x5532c5=this;this[_0x21b1df('0x23')][_0x21b1df('0x8')](function(){const _0x5f1048=_0x21b1df;return _0x5532c5[_0x5f1048('0x2a')]['addColumn'](_0x5052a0,_0xb936b2,_0x1a13cf)[_0x5f1048('0xb')](function(){const _0x5e7f91=_0x5f1048;logger[_0x5e7f91('0x0')](_0x5e7f91('0x22'),_0xb936b2,_0x5052a0);})[_0x5f1048('0x10')](function(_0x5ee2d5){const _0x1a4626=_0x5f1048;logger[_0x1a4626('0x0')](JSON[_0x1a4626('0x2')](_0x5ee2d5));});});},Migration[_0x3c04c3('0x29')][_0x3c04c3('0x1a')]=function(_0xda0359){const _0x1b98f1=_0x3c04c3,_0x4b817e=this;this['sequence'][_0x1b98f1('0x8')](function(){const _0x144bf2=_0x1b98f1;return _0x4b817e[_0x144bf2('0x2a')][_0x144bf2('0x1a')](_0xda0359,{'force':!![]})[_0x144bf2('0xb')](function(){logger['info']('table\x20dropped\x20%s',_0xda0359);})[_0x144bf2('0x10')](function(_0x14df72){logger['info'](JSON['stringify'](_0x14df72));});});},Migration[_0x3c04c3('0x29')]['addIndex']=function(_0x2672db,_0x17acbd,_0x406b3e){const _0x597c73=this;this['sequence']['enqueue'](function(){const _0x361fd8=a917_0x110b;return _0x597c73[_0x361fd8('0x2a')][_0x361fd8('0x26')](_0x2672db,_0x17acbd,{'indexName':_0x406b3e})[_0x361fd8('0xb')](function(){const _0x2cf985=_0x361fd8;logger[_0x2cf985('0x0')](_0x2cf985('0x14'),_0x2672db,_0x17acbd[_0x2cf985('0x1e')](','),_0x406b3e);})['catch'](function(_0x86a656){const _0x33625c=_0x361fd8;logger[_0x33625c('0x0')](JSON[_0x33625c('0x2')](_0x86a656));});});},Migration[_0x3c04c3('0x29')][_0x3c04c3('0xc')]=function(_0x7643b4){const _0xd991f4=_0x3c04c3,_0x43b803=this;this['sequence'][_0xd991f4('0x8')](function(){const _0x37636d=_0xd991f4;return _0x43b803['queryInterface'][_0x37636d('0xd')][_0x37636d('0xc')](_0x7643b4)[_0x37636d('0xb')](function(){const _0x3cc0b0=_0x37636d;logger[_0x3cc0b0('0x0')](_0x3cc0b0('0xa'),_0x7643b4);})[_0x37636d('0x10')](function(_0x57943d){const _0x17247e=_0x37636d;logger[_0x17247e('0x0')](JSON[_0x17247e('0x2')](_0x57943d));});});},Migration[_0x3c04c3('0x29')]['removeColumn']=function(_0x248575,_0x3d35c4){const _0x14b1ad=_0x3c04c3,_0x34295b=this;this['sequence'][_0x14b1ad('0x8')](function(){const _0x3f3fab=_0x14b1ad;return _0x34295b[_0x3f3fab('0x2a')][_0x3f3fab('0x1')](_0x248575,_0x3d35c4)[_0x3f3fab('0xb')](function(){const _0xeed059=_0x3f3fab;logger[_0xeed059('0x0')](_0xeed059('0x17'),_0x3d35c4,_0x248575);})[_0x3f3fab('0x10')](function(_0x4714bf){const _0x38074f=_0x3f3fab;logger[_0x38074f('0x0')](util[_0x38074f('0x20')](_0x4714bf,{'showHidden':![],'depth':null}));});});},Migration[_0x3c04c3('0x29')][_0x3c04c3('0x16')]=function(_0x1d2b3d){const _0x46fe50=_0x3c04c3;this[_0x46fe50('0x23')][_0x46fe50('0x8')](function(){return _0x1d2b3d();});},module['exports']={'up':function(_0x55d66f,_0x2072c6){return new Promise(function(_0x3f7526){const _0x24b594=a917_0x110b,_0x4c76dd=new Migration(_0x55d66f);_0x4c76dd[_0x24b594('0x3')](_0x24b594('0x2b'),_0x24b594('0x4'),{'type':_0x2072c6[_0x24b594('0x19')]}),_0x4c76dd[_0x24b594('0x3')](_0x24b594('0x2b'),_0x24b594('0x15'),{'type':_0x2072c6[_0x24b594('0x19')]}),_0x4c76dd[_0x24b594('0x3')](_0x24b594('0x1d'),_0x24b594('0xe'),{'type':_0x2072c6[_0x24b594('0x19')]}),exec(cmd,function(_0x469b76,_0x420983,_0x46b133){const _0x1fbd82=_0x24b594;logger[_0x1fbd82('0x0')]('Exec\x20chmod',_0x1fbd82('0x1f'),JSON['stringify'](_0x469b76),_0x420983,_0x46b133),exec(ls,function(_0x359e66,_0x490861,_0x466813){const _0x3d2850=_0x1fbd82;logger[_0x3d2850('0x0')]('Ls\x20:',_0x3d2850('0x1f'),JSON[_0x3d2850('0x2')](_0x359e66),_0x490861,_0x466813);});}),_0x4c76dd[_0x24b594('0x1a')](_0x24b594('0x28')),_0x4c76dd['addColumn'](_0x24b594('0x6'),_0x24b594('0x7'),{'type':_0x2072c6[_0x24b594('0x1b')]}),_0x4c76dd[_0x24b594('0xc')](_0x24b594('0x13')),_0x4c76dd[_0x24b594('0x3')](_0x24b594('0xf'),_0x24b594('0x12'),{'type':_0x2072c6[_0x24b594('0x19')],'defaultValue':'no'}),_0x4c76dd[_0x24b594('0x16')](_0x3f7526);});},'down':function(){}}; \ No newline at end of file +const a917_0x3b89=['t38pt_udptl','Ls\x20:','Changed\x20column\x20%s\x20in\x20table\x20%s','migration','STRING','util','remote','then','table\x20dropped\x20%s','messageId','queryInterface','INTEGER','dropTable','sms_messages','sequence','\x20Error\x20:','addIndex','stringify','changeColumn','token','removeColumn','ALTER\x20TABLE\x20`fax_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`fax_messages_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`AttachmentId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20attachments(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20SET\x20NULL','info','exec','tail','finally','chown\x20motion:asterisk\x20/var/opt/motion2/server/files/attachments','enqueue','prototype','../config/logger','tools_trunks','addColumn','query','sms_accounts','sequelize','fax_messages','query\x20%s','AttachmentId','catch','Exec\x20chmod','Added\x20column\x20%s\x20to\x20%s','addIndex\x20%s\x20%s\x20%s','final'];(function(_0x1fe41c,_0x3b892d){const _0x3e9922=function(_0x385046){while(--_0x385046){_0x1fe41c['push'](_0x1fe41c['shift']());}};_0x3e9922(++_0x3b892d);}(a917_0x3b89,0x1a9));const a917_0x3e99=function(_0x1fe41c,_0x3b892d){_0x1fe41c=_0x1fe41c-0x0;let _0x3e9922=a917_0x3b89[_0x1fe41c];return _0x3e9922;};const _0x38c476=a917_0x3e99;'use strict';const logger=require(_0x38c476('0x22'))(_0x38c476('0x8')),util=require(_0x38c476('0xa')),exec=require('child_process')[_0x38c476('0x1c')],cmd=_0x38c476('0x1f'),ls='ls\x20-la\x20/var/opt/motion2/server/files',Sequence=function(){};Sequence[_0x38c476('0x21')][_0x38c476('0x20')]=function(_0x385046){const _0x5890b0=_0x38c476;this[_0x5890b0('0x1d')]=this[_0x5890b0('0x1d')]?this[_0x5890b0('0x1d')][_0x5890b0('0x1e')](_0x385046):_0x385046();};const Migration=function(_0xbf7c62){const _0x224193=_0x38c476;this[_0x224193('0xf')]=_0xbf7c62,this[_0x224193('0x13')]=new Sequence();};Migration['prototype'][_0x38c476('0x17')]=function(_0x3c0be6,_0x5bec80,_0x45674c){const _0x4975c1=_0x38c476,_0x233ba0=this;this[_0x4975c1('0x13')][_0x4975c1('0x20')](function(){const _0x1a0f8c=_0x4975c1;return _0x233ba0[_0x1a0f8c('0xf')][_0x1a0f8c('0x17')](_0x3c0be6,_0x5bec80,_0x45674c)[_0x1a0f8c('0xc')](function(){const _0x57308f=_0x1a0f8c;logger[_0x57308f('0x1b')](_0x57308f('0x7'),_0x5bec80,_0x3c0be6);})[_0x1a0f8c('0x0')](function(_0x32bbb2){const _0x280c4c=_0x1a0f8c;logger[_0x280c4c('0x1b')](JSON[_0x280c4c('0x16')](_0x32bbb2));});});},Migration['prototype']['addColumn']=function(_0x2246e4,_0xed8df3,_0x120285){const _0x4d59cd=_0x38c476,_0x160ed0=this;this[_0x4d59cd('0x13')]['enqueue'](function(){const _0x3a9504=_0x4d59cd;return _0x160ed0[_0x3a9504('0xf')][_0x3a9504('0x24')](_0x2246e4,_0xed8df3,_0x120285)['then'](function(){const _0x20954e=_0x3a9504;logger[_0x20954e('0x1b')](_0x20954e('0x2'),_0xed8df3,_0x2246e4);})[_0x3a9504('0x0')](function(_0x518a43){const _0x4ff638=_0x3a9504;logger[_0x4ff638('0x1b')](JSON[_0x4ff638('0x16')](_0x518a43));});});},Migration[_0x38c476('0x21')]['dropTable']=function(_0x54b1eb){const _0x5652bd=this;this['sequence']['enqueue'](function(){const _0x23071b=a917_0x3e99;return _0x5652bd[_0x23071b('0xf')][_0x23071b('0x11')](_0x54b1eb,{'force':!![]})[_0x23071b('0xc')](function(){const _0x34ecdc=_0x23071b;logger[_0x34ecdc('0x1b')](_0x34ecdc('0xd'),_0x54b1eb);})[_0x23071b('0x0')](function(_0x2959ab){const _0x1a4287=_0x23071b;logger['info'](JSON[_0x1a4287('0x16')](_0x2959ab));});});},Migration['prototype'][_0x38c476('0x15')]=function(_0x8af92b,_0x512c22,_0x1dc7c8){const _0x1b47e8=_0x38c476,_0x3597ac=this;this['sequence'][_0x1b47e8('0x20')](function(){const _0xcf3eeb=_0x1b47e8;return _0x3597ac['queryInterface'][_0xcf3eeb('0x15')](_0x8af92b,_0x512c22,{'indexName':_0x1dc7c8})[_0xcf3eeb('0xc')](function(){const _0x4312ab=_0xcf3eeb;logger[_0x4312ab('0x1b')](_0x4312ab('0x3'),_0x8af92b,_0x512c22['join'](','),_0x1dc7c8);})[_0xcf3eeb('0x0')](function(_0x583fb4){const _0x2f284c=_0xcf3eeb;logger['info'](JSON[_0x2f284c('0x16')](_0x583fb4));});});},Migration[_0x38c476('0x21')][_0x38c476('0x25')]=function(_0x469223){const _0x5d072e=this;this['sequence']['enqueue'](function(){const _0x59a23c=a917_0x3e99;return _0x5d072e[_0x59a23c('0xf')][_0x59a23c('0x27')][_0x59a23c('0x25')](_0x469223)['then'](function(){const _0xaf5429=_0x59a23c;logger[_0xaf5429('0x1b')](_0xaf5429('0x29'),_0x469223);})[_0x59a23c('0x0')](function(_0x11d00c){logger['info'](JSON['stringify'](_0x11d00c));});});},Migration['prototype'][_0x38c476('0x19')]=function(_0x3fde76,_0x285c5b){const _0x962fc2=_0x38c476,_0x3725db=this;this[_0x962fc2('0x13')]['enqueue'](function(){const _0x1fc73f=_0x962fc2;return _0x3725db[_0x1fc73f('0xf')][_0x1fc73f('0x19')](_0x3fde76,_0x285c5b)['then'](function(){const _0x936064=_0x1fc73f;logger[_0x936064('0x1b')]('Removed\x20column\x20%s\x20from\x20%s',_0x285c5b,_0x3fde76);})[_0x1fc73f('0x0')](function(_0x2b71ec){const _0x495d32=_0x1fc73f;logger[_0x495d32('0x1b')](util['inspect'](_0x2b71ec,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x38c476('0x4')]=function(_0x351ea8){const _0x237f8d=_0x38c476;this[_0x237f8d('0x13')]['enqueue'](function(){return _0x351ea8();});},module['exports']={'up':function(_0x23a8ec,_0x3177f9){return new Promise(function(_0x546931){const _0x5757f7=a917_0x3e99,_0x459081=new Migration(_0x23a8ec);_0x459081['addColumn'](_0x5757f7('0x26'),_0x5757f7('0xb'),{'type':_0x3177f9['STRING']}),_0x459081['addColumn'](_0x5757f7('0x26'),_0x5757f7('0x18'),{'type':_0x3177f9['STRING']}),_0x459081[_0x5757f7('0x24')](_0x5757f7('0x12'),_0x5757f7('0xe'),{'type':_0x3177f9[_0x5757f7('0x9')]}),exec(cmd,function(_0x501fcf,_0x250c46,_0x1e32bc){const _0x522a0e=_0x5757f7;logger['info'](_0x522a0e('0x1'),'\x20Error\x20:',JSON[_0x522a0e('0x16')](_0x501fcf),_0x250c46,_0x1e32bc),exec(ls,function(_0x29b041,_0x5e19cc,_0x5132cc){const _0x58fa27=_0x522a0e;logger[_0x58fa27('0x1b')](_0x58fa27('0x6'),_0x58fa27('0x14'),JSON[_0x58fa27('0x16')](_0x29b041),_0x5e19cc,_0x5132cc);});}),_0x459081[_0x5757f7('0x11')]('fax_applications'),_0x459081[_0x5757f7('0x24')](_0x5757f7('0x28'),_0x5757f7('0x2a'),{'type':_0x3177f9[_0x5757f7('0x10')]}),_0x459081[_0x5757f7('0x25')](_0x5757f7('0x1a')),_0x459081[_0x5757f7('0x24')](_0x5757f7('0x23'),_0x5757f7('0x5'),{'type':_0x3177f9[_0x5757f7('0x9')],'defaultValue':'no'}),_0x459081[_0x5757f7('0x4')](_0x546931);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.39.js b/server/migrations/2.0.39.js index d2d1c3a..4c22d27 100644 --- a/server/migrations/2.0.39.js +++ b/server/migrations/2.0.39.js @@ -1 +1 @@ -const a918_0x19e1=['INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','exec','sequelize','settings','enqueue','prototype','sequence','Added\x20column\x20%s\x20to\x20%s','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x279\x27,\x20\x27Set\x27,\x20\x27FAXOPT(modem)=${XMF-MODEM}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','defaultPageTitle','ejs','Changed\x20column\x20%s\x20in\x20table\x20%s','then','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x276\x27,\x20\x27Set\x27,\x20\x27FAXOPT(localstationid)=${XMF-LOCALSTATIONID}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','nothing','deletedAt','Removed\x20column\x20%s\x20from\x20%s','path','utf8','ls\x20-la\x20/var/opt/motion2/server/files','stringify','/etc/asterisk/extensions_xcally_contexts.conf','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x272\x27,\x20\x27Set\x27,\x20\x27CDR(type)=outbound-fax\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','contact','removeColumn','join','ENUM','Exec\x20chmod','contact_lead','util','lead','final','spread','catch','migration','readFileSync','DATE','pageTitle','inspect','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x2710\x27,\x20\x27Set\x27,\x20\x27FAXOPT(t38timeout)=${XMF-T38TIMEOUT}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','tail','addColumn','query','table\x20dropped\x20%s','addIndex','api/voiceContext/voiceContext.model','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x274\x27,\x20\x27Set\x27,\x20\x27FAXOPT(ecm)=${XMF-ECM}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','asterisk\x20-rx\x20\x22reload\x20chan_sip.so\x22','dropTable','finally','queryInterface','checkVoiceContexts','default\x20entry\x20context\x20(DO\x20NOT\x20DELETE)','root','Ls\x20:','changeColumn','xcally-mixmonitor-context','../config/logger','../config/environment','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x273\x27,\x20\x27Wait\x27,\x20\x276\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','chmod\x20775\x20/var/opt/motion2/server/files/attachments','findOrCreate','import','info','int_salesforce_configurations','BOOLEAN','query\x20%s'];(function(_0x551b01,_0x19e1d7){const _0x5ba5b3=function(_0x1109d8){while(--_0x1109d8){_0x551b01['push'](_0x551b01['shift']());}};_0x5ba5b3(++_0x19e1d7);}(a918_0x19e1,0x10d));const a918_0x5ba5=function(_0x551b01,_0x19e1d7){_0x551b01=_0x551b01-0x0;let _0x5ba5b3=a918_0x19e1[_0x551b01];return _0x5ba5b3;};const _0x1c92be=a918_0x5ba5;'use strict';const logger=require(_0x1c92be('0x38'))(_0x1c92be('0x21')),util=require(_0x1c92be('0x1c')),ejs=require(_0x1c92be('0x9')),fs=require('fs'),path=require(_0x1c92be('0x10')),exec=require('child_process')[_0x1c92be('0x0')],config=require(_0x1c92be('0x39')),Sequence=function(){};Sequence[_0x1c92be('0x4')][_0x1c92be('0x3')]=function(_0x1109d8){const _0x4cf436=_0x1c92be;this[_0x4cf436('0x27')]=this[_0x4cf436('0x27')]?this['tail'][_0x4cf436('0x30')](_0x1109d8):_0x1109d8();};const Migration=function(_0x53c06c){const _0x3033e3=_0x1c92be;this[_0x3033e3('0x31')]=_0x53c06c,this['sequence']=new Sequence();};Migration[_0x1c92be('0x4')][_0x1c92be('0x36')]=function(_0x438047,_0x4a4d78,_0x2e8939){const _0x21b913=_0x1c92be,_0x214dbe=this;this[_0x21b913('0x5')][_0x21b913('0x3')](function(){const _0x23740c=_0x21b913;return _0x214dbe[_0x23740c('0x31')][_0x23740c('0x36')](_0x438047,_0x4a4d78,_0x2e8939)[_0x23740c('0xb')](function(){const _0x4ce2ec=_0x23740c;logger[_0x4ce2ec('0x3e')](_0x4ce2ec('0xa'),_0x4a4d78,_0x438047);})[_0x23740c('0x20')](function(_0x3affb4){const _0x25c8e6=_0x23740c;logger[_0x25c8e6('0x3e')](JSON[_0x25c8e6('0x13')](_0x3affb4));});});},Migration[_0x1c92be('0x4')][_0x1c92be('0x28')]=function(_0xf4b0cf,_0x26b13f,_0x54f162){const _0x5ce245=_0x1c92be,_0x1cf689=this;this[_0x5ce245('0x5')][_0x5ce245('0x3')](function(){const _0x111819=_0x5ce245;return _0x1cf689[_0x111819('0x31')][_0x111819('0x28')](_0xf4b0cf,_0x26b13f,_0x54f162)[_0x111819('0xb')](function(){const _0xa2b270=_0x111819;logger[_0xa2b270('0x3e')](_0xa2b270('0x6'),_0x26b13f,_0xf4b0cf);})[_0x111819('0x20')](function(_0x447c36){const _0x26bf99=_0x111819;logger[_0x26bf99('0x3e')](JSON['stringify'](_0x447c36));});});},Migration['prototype'][_0x1c92be('0x2f')]=function(_0x3c6b90){const _0x5ae6c1=_0x1c92be,_0x1ea99d=this;this[_0x5ae6c1('0x5')][_0x5ae6c1('0x3')](function(){const _0x388570=_0x5ae6c1;return _0x1ea99d[_0x388570('0x31')][_0x388570('0x2f')](_0x3c6b90,{'force':!![]})['then'](function(){const _0x240846=_0x388570;logger[_0x240846('0x3e')](_0x240846('0x2a'),_0x3c6b90);})[_0x388570('0x20')](function(_0x280830){const _0x54a46c=_0x388570;logger[_0x54a46c('0x3e')](JSON[_0x54a46c('0x13')](_0x280830));});});},Migration[_0x1c92be('0x4')][_0x1c92be('0x2b')]=function(_0x1a25af,_0xfa995a,_0x2a284e){const _0x4c2794=_0x1c92be,_0x2d31d1=this;this['sequence'][_0x4c2794('0x3')](function(){const _0x5e7493=_0x4c2794;return _0x2d31d1[_0x5e7493('0x31')]['addIndex'](_0x1a25af,_0xfa995a,{'indexName':_0x2a284e})['then'](function(){const _0x27453e=_0x5e7493;logger[_0x27453e('0x3e')]('addIndex\x20%s\x20%s\x20%s',_0x1a25af,_0xfa995a[_0x27453e('0x18')](','),_0x2a284e);})['catch'](function(_0x257ae9){const _0x2e5914=_0x5e7493;logger['info'](JSON[_0x2e5914('0x13')](_0x257ae9));});});},Migration['prototype'][_0x1c92be('0x29')]=function(_0x598a24){const _0x40df52=_0x1c92be,_0x5c83e7=this;this['sequence'][_0x40df52('0x3')](function(){const _0x4fdca2=_0x40df52;return _0x5c83e7[_0x4fdca2('0x31')][_0x4fdca2('0x1')]['query'](_0x598a24)[_0x4fdca2('0xb')](function(){const _0x47d9ee=_0x4fdca2;logger['info'](_0x47d9ee('0x41'),_0x598a24);})['catch'](function(_0x27df3a){const _0x22036d=_0x4fdca2;logger[_0x22036d('0x3e')](JSON[_0x22036d('0x13')](_0x27df3a));});});},Migration[_0x1c92be('0x4')][_0x1c92be('0x17')]=function(_0x7ccac8,_0x336296){const _0x21bac4=_0x1c92be,_0x35f039=this;this[_0x21bac4('0x5')][_0x21bac4('0x3')](function(){const _0x23c715=_0x21bac4;return _0x35f039[_0x23c715('0x31')][_0x23c715('0x17')](_0x7ccac8,_0x336296)['then'](function(){const _0xdfc3a7=_0x23c715;logger['info'](_0xdfc3a7('0xf'),_0x336296,_0x7ccac8);})[_0x23c715('0x20')](function(_0x21bc03){const _0x51caa3=_0x23c715;logger[_0x51caa3('0x3e')](util[_0x51caa3('0x25')](_0x21bc03,{'showHidden':![],'depth':null}));});});},Migration[_0x1c92be('0x4')][_0x1c92be('0x32')]=function(){const _0x39f878=_0x1c92be,_0x3095c0=this,_0x38b0a1=_0x3095c0[_0x39f878('0x31')][_0x39f878('0x1')][_0x39f878('0x3d')](path[_0x39f878('0x18')](config[_0x39f878('0x34')],_0x39f878('0x2c')));this[_0x39f878('0x5')]['enqueue'](function(){const _0x12b549=_0x39f878;return _0x38b0a1[_0x12b549('0x3c')]({'where':{'name':_0x12b549('0x37')},'defaults':{'name':_0x12b549('0x37'),'description':_0x12b549('0x33'),'defaultEntry':!![]}})[_0x12b549('0x1f')](function(){return _0x38b0a1['findAll']({'raw':!![]});})[_0x12b549('0xb')](function(_0x33d937){const _0x267855=_0x12b549,_0x26bcc8=fs[_0x267855('0x22')](path['join'](config[_0x267855('0x34')],'files/templates/context.ejs'),_0x267855('0x11')),_0x1e3749=ejs['render'](_0x26bcc8,{'contexts':_0x33d937||[]});fs['writeFileSync'](_0x267855('0x14'),_0x1e3749),exec(_0x267855('0x2e'),function(_0x35816a,_0x1a0fff,_0x1284d0){const _0x3f1a0e=_0x267855;logger[_0x3f1a0e('0x3e')](_0x3f1a0e('0x1a'),'\x20Error\x20:',JSON['stringify'](_0x35816a),_0x1a0fff,_0x1284d0);});})[_0x12b549('0x20')](function(_0x519ea4){logger['info'](JSON['stringify'](_0x519ea4));});});},Migration[_0x1c92be('0x4')]['final']=function(_0x230fde){const _0x1d56e2=_0x1c92be;this[_0x1d56e2('0x5')][_0x1d56e2('0x3')](function(){return _0x230fde();});},module['exports']={'up':function(_0x4f1547,_0xda15ce){return new Promise(function(_0x3df1e9){const _0x9d3e29=a918_0x5ba5,_0x5542ea=new Migration(_0x4f1547);_0x5542ea[_0x9d3e29('0x28')](_0x9d3e29('0x2'),_0x9d3e29('0x8'),{'type':_0xda15ce[_0x9d3e29('0x40')],'defaultValue':!![]}),_0x5542ea[_0x9d3e29('0x28')]('settings',_0x9d3e29('0x24'),{'type':_0xda15ce['STRING']}),_0x5542ea[_0x9d3e29('0x32')](),_0x5542ea['addColumn'](_0x9d3e29('0x3f'),'moduleSearch',{'type':_0xda15ce['ENUM']('contact_lead','contact',_0x9d3e29('0x1d')),'defaultValue':_0x9d3e29('0x1b')}),_0x5542ea['addColumn'](_0x9d3e29('0x3f'),'moduleCreate',{'type':_0xda15ce[_0x9d3e29('0x19')](_0x9d3e29('0xd'),_0x9d3e29('0x16'),'lead'),'defaultValue':_0x9d3e29('0x1d')}),_0x5542ea[_0x9d3e29('0x29')](_0x9d3e29('0x42')),_0x5542ea[_0x9d3e29('0x29')](_0x9d3e29('0x15')),_0x5542ea[_0x9d3e29('0x29')](_0x9d3e29('0x3a')),_0x5542ea[_0x9d3e29('0x29')](_0x9d3e29('0x2d')),_0x5542ea[_0x9d3e29('0x29')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x275\x27,\x20\x27Set\x27,\x20\x27FAXOPT(headerinfo)=${XMF-HEADERINFO}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x5542ea[_0x9d3e29('0x29')](_0x9d3e29('0xc')),_0x5542ea['query']('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x277\x27,\x20\x27Set\x27,\x20\x27FAXOPT(maxrate)=${XMF-MAXRATE}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x5542ea[_0x9d3e29('0x29')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x278\x27,\x20\x27Set\x27,\x20\x27FAXOPT(minrate)=${XMF-MINRATE}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x5542ea[_0x9d3e29('0x29')](_0x9d3e29('0x7')),_0x5542ea[_0x9d3e29('0x29')](_0x9d3e29('0x26')),_0x5542ea[_0x9d3e29('0x29')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x2711\x27,\x20\x27SendFax\x27,\x20\x27${XMF-PATH},d\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),exec(_0x9d3e29('0x3b'),function(_0x5a1a41,_0x357132,_0x56ca33){const _0x420f97=_0x9d3e29;logger[_0x420f97('0x3e')](_0x420f97('0x1a'),'\x20Error\x20:',JSON[_0x420f97('0x13')](_0x5a1a41),_0x357132,_0x56ca33),exec(_0x420f97('0x12'),function(_0x33f64e,_0x31eec9,_0x3f6216){const _0x20a1a9=_0x420f97;logger[_0x20a1a9('0x3e')](_0x20a1a9('0x35'),'\x20Error\x20:',JSON['stringify'](_0x33f64e),_0x31eec9,_0x3f6216);});}),_0x5542ea[_0x9d3e29('0x28')]('cm_contacts',_0x9d3e29('0xe'),{'type':_0xda15ce[_0x9d3e29('0x23')],'defaultValue':null}),_0x5542ea[_0x9d3e29('0x1e')](_0x3df1e9);});},'down':function(){}}; \ No newline at end of file +const a918_0x2ddc=['asterisk\x20-rx\x20\x22reload\x20chan_sip.so\x22','api/voiceContext/voiceContext.model','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x279\x27,\x20\x27Set\x27,\x20\x27FAXOPT(modem)=${XMF-MODEM}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','contact_lead','addColumn','ls\x20-la\x20/var/opt/motion2/server/files','moduleSearch','moduleCreate','table\x20dropped\x20%s','BOOLEAN','findOrCreate','checkVoiceContexts','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x275\x27,\x20\x27Set\x27,\x20\x27FAXOPT(headerinfo)=${XMF-HEADERINFO}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','nothing','default\x20entry\x20context\x20(DO\x20NOT\x20DELETE)','addIndex','inspect','readFileSync','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x2711\x27,\x20\x27SendFax\x27,\x20\x27${XMF-PATH},d\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','/etc/asterisk/extensions_xcally_contexts.conf','spread','dropTable','sequence','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x276\x27,\x20\x27Set\x27,\x20\x27FAXOPT(localstationid)=${XMF-LOCALSTATIONID}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','prototype','Exec\x20chmod','defaultPageTitle','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x2710\x27,\x20\x27Set\x27,\x20\x27FAXOPT(t38timeout)=${XMF-T38TIMEOUT}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','writeFileSync','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x277\x27,\x20\x27Set\x27,\x20\x27FAXOPT(maxrate)=${XMF-MAXRATE}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','cm_contacts','xcally-mixmonitor-context','root','path','changeColumn','then','render','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','final','finally','child_process','stringify','Removed\x20column\x20%s\x20from\x20%s','ejs','chmod\x20775\x20/var/opt/motion2/server/files/attachments','queryInterface','catch','migration','info','../config/logger','enqueue','join','STRING','\x20Error\x20:','query\x20%s','ENUM','Ls\x20:','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x273\x27,\x20\x27Wait\x27,\x20\x276\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','query','removeColumn','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x278\x27,\x20\x27Set\x27,\x20\x27FAXOPT(minrate)=${XMF-MINRATE}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','tail','sequelize','Changed\x20column\x20%s\x20in\x20table\x20%s'];(function(_0x4fe666,_0x2ddc78){const _0x3918db=function(_0x364c35){while(--_0x364c35){_0x4fe666['push'](_0x4fe666['shift']());}};_0x3918db(++_0x2ddc78);}(a918_0x2ddc,0x12f));const a918_0x3918=function(_0x4fe666,_0x2ddc78){_0x4fe666=_0x4fe666-0x0;let _0x3918db=a918_0x2ddc[_0x4fe666];return _0x3918db;};const _0xe11896=a918_0x3918;'use strict';const logger=require(_0xe11896('0x2'))(_0xe11896('0x0')),util=require('util'),ejs=require(_0xe11896('0x3c')),fs=require('fs'),path=require(_0xe11896('0x32')),exec=require(_0xe11896('0x39'))['exec'],config=require('../config/environment'),Sequence=function(){};Sequence[_0xe11896('0x29')][_0xe11896('0x3')]=function(_0x364c35){const _0x4381e2=_0xe11896;this[_0x4381e2('0xe')]=this[_0x4381e2('0xe')]?this[_0x4381e2('0xe')][_0x4381e2('0x38')](_0x364c35):_0x364c35();};const Migration=function(_0x44c785){const _0x1cd1d4=_0xe11896;this[_0x1cd1d4('0x3e')]=_0x44c785,this['sequence']=new Sequence();};Migration[_0xe11896('0x29')][_0xe11896('0x33')]=function(_0x14f604,_0x1ef050,_0x4fc505){const _0x27d97a=_0xe11896,_0xe9fb5a=this;this[_0x27d97a('0x27')][_0x27d97a('0x3')](function(){const _0x3466db=_0x27d97a;return _0xe9fb5a[_0x3466db('0x3e')]['changeColumn'](_0x14f604,_0x1ef050,_0x4fc505)[_0x3466db('0x34')](function(){const _0x1d7473=_0x3466db;logger[_0x1d7473('0x1')](_0x1d7473('0x10'),_0x1ef050,_0x14f604);})['catch'](function(_0x1ccc02){const _0x395023=_0x3466db;logger['info'](JSON[_0x395023('0x3a')](_0x1ccc02));});});},Migration['prototype'][_0xe11896('0x15')]=function(_0x9845e3,_0x1b9f18,_0x546e4e){const _0x32ea4d=_0xe11896,_0x1fa37d=this;this[_0x32ea4d('0x27')][_0x32ea4d('0x3')](function(){const _0x9a6265=_0x32ea4d;return _0x1fa37d[_0x9a6265('0x3e')]['addColumn'](_0x9845e3,_0x1b9f18,_0x546e4e)[_0x9a6265('0x34')](function(){const _0x5b223b=_0x9a6265;logger[_0x5b223b('0x1')]('Added\x20column\x20%s\x20to\x20%s',_0x1b9f18,_0x9845e3);})[_0x9a6265('0x3f')](function(_0x55fdaa){const _0xce57e8=_0x9a6265;logger[_0xce57e8('0x1')](JSON[_0xce57e8('0x3a')](_0x55fdaa));});});},Migration[_0xe11896('0x29')]['dropTable']=function(_0x38e5e1){const _0x54cde3=_0xe11896,_0x2de454=this;this['sequence'][_0x54cde3('0x3')](function(){const _0x23aff7=_0x54cde3;return _0x2de454[_0x23aff7('0x3e')][_0x23aff7('0x26')](_0x38e5e1,{'force':!![]})['then'](function(){const _0x3f1cd4=_0x23aff7;logger[_0x3f1cd4('0x1')](_0x3f1cd4('0x19'),_0x38e5e1);})[_0x23aff7('0x3f')](function(_0x4e42d0){const _0xb5646f=_0x23aff7;logger[_0xb5646f('0x1')](JSON[_0xb5646f('0x3a')](_0x4e42d0));});});},Migration['prototype'][_0xe11896('0x20')]=function(_0x50128e,_0x437ca3,_0x30bd8c){const _0x5f8f28=_0xe11896,_0x20bbc7=this;this['sequence'][_0x5f8f28('0x3')](function(){const _0x5274af=_0x5f8f28;return _0x20bbc7[_0x5274af('0x3e')][_0x5274af('0x20')](_0x50128e,_0x437ca3,{'indexName':_0x30bd8c})[_0x5274af('0x34')](function(){const _0x5aa19d=_0x5274af;logger[_0x5aa19d('0x1')]('addIndex\x20%s\x20%s\x20%s',_0x50128e,_0x437ca3[_0x5aa19d('0x4')](','),_0x30bd8c);})[_0x5274af('0x3f')](function(_0x33b7b8){const _0x5e5f07=_0x5274af;logger['info'](JSON[_0x5e5f07('0x3a')](_0x33b7b8));});});},Migration['prototype']['query']=function(_0x374210){const _0xd29b4d=_0xe11896,_0x4cd78e=this;this[_0xd29b4d('0x27')]['enqueue'](function(){const _0x212058=_0xd29b4d;return _0x4cd78e[_0x212058('0x3e')]['sequelize'][_0x212058('0xb')](_0x374210)[_0x212058('0x34')](function(){const _0x1b0d5b=_0x212058;logger[_0x1b0d5b('0x1')](_0x1b0d5b('0x7'),_0x374210);})[_0x212058('0x3f')](function(_0x4b2b8b){const _0x4ffebc=_0x212058;logger[_0x4ffebc('0x1')](JSON['stringify'](_0x4b2b8b));});});},Migration[_0xe11896('0x29')][_0xe11896('0xc')]=function(_0x480301,_0x1e470a){const _0x19c4bc=_0xe11896,_0x3fb6cb=this;this[_0x19c4bc('0x27')][_0x19c4bc('0x3')](function(){const _0x3d44dd=_0x19c4bc;return _0x3fb6cb['queryInterface'][_0x3d44dd('0xc')](_0x480301,_0x1e470a)['then'](function(){const _0x1c81d3=_0x3d44dd;logger[_0x1c81d3('0x1')](_0x1c81d3('0x3b'),_0x1e470a,_0x480301);})[_0x3d44dd('0x3f')](function(_0x3558be){const _0x40afa1=_0x3d44dd;logger[_0x40afa1('0x1')](util[_0x40afa1('0x21')](_0x3558be,{'showHidden':![],'depth':null}));});});},Migration[_0xe11896('0x29')][_0xe11896('0x1c')]=function(){const _0x202c30=_0xe11896,_0x476c1b=this,_0xe0a283=_0x476c1b[_0x202c30('0x3e')][_0x202c30('0xf')]['import'](path['join'](config[_0x202c30('0x31')],_0x202c30('0x12')));this[_0x202c30('0x27')]['enqueue'](function(){const _0x573b2c=_0x202c30;return _0xe0a283[_0x573b2c('0x1b')]({'where':{'name':_0x573b2c('0x30')},'defaults':{'name':_0x573b2c('0x30'),'description':_0x573b2c('0x1f'),'defaultEntry':!![]}})[_0x573b2c('0x25')](function(){return _0xe0a283['findAll']({'raw':!![]});})['then'](function(_0x46a692){const _0x2beb60=_0x573b2c,_0x5256ab=fs[_0x2beb60('0x22')](path['join'](config[_0x2beb60('0x31')],'files/templates/context.ejs'),'utf8'),_0x20275c=ejs[_0x2beb60('0x35')](_0x5256ab,{'contexts':_0x46a692||[]});fs[_0x2beb60('0x2d')](_0x2beb60('0x24'),_0x20275c),exec(_0x2beb60('0x11'),function(_0x736800,_0x2c8637,_0x1c0050){const _0x15832d=_0x2beb60;logger[_0x15832d('0x1')](_0x15832d('0x2a'),_0x15832d('0x6'),JSON[_0x15832d('0x3a')](_0x736800),_0x2c8637,_0x1c0050);});})[_0x573b2c('0x3f')](function(_0x85405f){const _0x354efd=_0x573b2c;logger[_0x354efd('0x1')](JSON['stringify'](_0x85405f));});});},Migration[_0xe11896('0x29')][_0xe11896('0x37')]=function(_0x42d333){const _0x5882b0=_0xe11896;this[_0x5882b0('0x27')][_0x5882b0('0x3')](function(){return _0x42d333();});},module['exports']={'up':function(_0x3a11d0,_0x31a1ee){return new Promise(function(_0x214eb9){const _0x1d4037=a918_0x3918,_0x5d93f0=new Migration(_0x3a11d0);_0x5d93f0['addColumn']('settings',_0x1d4037('0x2b'),{'type':_0x31a1ee[_0x1d4037('0x1a')],'defaultValue':!![]}),_0x5d93f0['addColumn']('settings','pageTitle',{'type':_0x31a1ee[_0x1d4037('0x5')]}),_0x5d93f0[_0x1d4037('0x1c')](),_0x5d93f0['addColumn']('int_salesforce_configurations',_0x1d4037('0x17'),{'type':_0x31a1ee[_0x1d4037('0x8')](_0x1d4037('0x14'),'contact','lead'),'defaultValue':'contact_lead'}),_0x5d93f0[_0x1d4037('0x15')]('int_salesforce_configurations',_0x1d4037('0x18'),{'type':_0x31a1ee[_0x1d4037('0x8')](_0x1d4037('0x1e'),'contact','lead'),'defaultValue':'lead'}),_0x5d93f0[_0x1d4037('0xb')](_0x1d4037('0x36')),_0x5d93f0[_0x1d4037('0xb')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x272\x27,\x20\x27Set\x27,\x20\x27CDR(type)=outbound-fax\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x5d93f0[_0x1d4037('0xb')](_0x1d4037('0xa')),_0x5d93f0[_0x1d4037('0xb')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-fax\x27,\x20\x274\x27,\x20\x27Set\x27,\x20\x27FAXOPT(ecm)=${XMF-ECM}\x27,\x20\x27system\x27,\x20\x27Fax\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x5d93f0[_0x1d4037('0xb')](_0x1d4037('0x1d')),_0x5d93f0['query'](_0x1d4037('0x28')),_0x5d93f0['query'](_0x1d4037('0x2e')),_0x5d93f0['query'](_0x1d4037('0xd')),_0x5d93f0['query'](_0x1d4037('0x13')),_0x5d93f0[_0x1d4037('0xb')](_0x1d4037('0x2c')),_0x5d93f0['query'](_0x1d4037('0x23')),exec(_0x1d4037('0x3d'),function(_0x223758,_0x376c7e,_0x3416fd){const _0x188d63=_0x1d4037;logger[_0x188d63('0x1')]('Exec\x20chmod',_0x188d63('0x6'),JSON[_0x188d63('0x3a')](_0x223758),_0x376c7e,_0x3416fd),exec(_0x188d63('0x16'),function(_0xb514be,_0x5dc8d3,_0x44e8bd){const _0x2e8d1d=_0x188d63;logger['info'](_0x2e8d1d('0x9'),_0x2e8d1d('0x6'),JSON['stringify'](_0xb514be),_0x5dc8d3,_0x44e8bd);});}),_0x5d93f0[_0x1d4037('0x15')](_0x1d4037('0x2f'),'deletedAt',{'type':_0x31a1ee['DATE'],'defaultValue':null}),_0x5d93f0[_0x1d4037('0x37')](_0x214eb9);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.40.js b/server/migrations/2.0.40.js index 4ca25cd..ac25bcd 100644 --- a/server/migrations/2.0.40.js +++ b/server/migrations/2.0.40.js @@ -1 +1 @@ -var a919_0x305e=['exports'];(function(_0x43e204,_0x305e74){var _0x39a7fc=function(_0x3242b2){while(--_0x3242b2){_0x43e204['push'](_0x43e204['shift']());}};_0x39a7fc(++_0x305e74);}(a919_0x305e,0x163));var a919_0x39a7=function(_0x43e204,_0x305e74){_0x43e204=_0x43e204-0x0;var _0x39a7fc=a919_0x305e[_0x43e204];return _0x39a7fc;};var _0x5e3e23=a919_0x39a7;'use strict';module[_0x5e3e23('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file +var a919_0x758c=['exports'];(function(_0x229575,_0x758c8c){var _0x1f9e9b=function(_0x684cd1){while(--_0x684cd1){_0x229575['push'](_0x229575['shift']());}};_0x1f9e9b(++_0x758c8c);}(a919_0x758c,0xd2));var a919_0x1f9e=function(_0x229575,_0x758c8c){_0x229575=_0x229575-0x0;var _0x1f9e9b=a919_0x758c[_0x229575];return _0x1f9e9b;};var _0x53fb49=a919_0x1f9e;'use strict';module[_0x53fb49('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.41.js b/server/migrations/2.0.41.js index ac4b247..d29e65f 100644 --- a/server/migrations/2.0.41.js +++ b/server/migrations/2.0.41.js @@ -1 +1 @@ -const a920_0x3cc6=['showAgentAvatar','sequelize','info','BOOLEAN','removeColumn','Removed\x20column\x20%s\x20from\x20%s','queryInterface','enqueue','agentAvatar','table\x20dropped\x20%s','cm_custom_fields','../config/logger','long','catch','Added\x20column\x20%s\x20to\x20%s','chat_messages','final','int_desk_accounts','then','tail','addIndex\x20%s\x20%s\x20%s','stringify','query\x20%s','TEXT','chat_interactions','changeColumn','join','migration','addIndex','finally','secret','query','prototype','sequence','util','addColumn','dropTable','chat_websites','exports'];(function(_0x29b165,_0x3cc62c){const _0x20429d=function(_0x562ebf){while(--_0x562ebf){_0x29b165['push'](_0x29b165['shift']());}};_0x20429d(++_0x3cc62c);}(a920_0x3cc6,0x1a8));const a920_0x2042=function(_0x29b165,_0x3cc62c){_0x29b165=_0x29b165-0x0;let _0x20429d=a920_0x3cc6[_0x29b165];return _0x20429d;};const _0x5027db=a920_0x2042;'use strict';const logger=require(_0x5027db('0x10'))(_0x5027db('0x20')),util=require(_0x5027db('0x0')),Sequence=function(){};Sequence[_0x5027db('0x25')]['enqueue']=function(_0x562ebf){const _0x536994=_0x5027db;this['tail']=this['tail']?this[_0x536994('0x18')][_0x536994('0x22')](_0x562ebf):_0x562ebf();};const Migration=function(_0x3ba878){const _0x4759fa=_0x5027db;this[_0x4759fa('0xb')]=_0x3ba878,this[_0x4759fa('0x26')]=new Sequence();};Migration['prototype'][_0x5027db('0x1e')]=function(_0x3d4a20,_0x4dc8ca,_0x421b44){const _0x18614b=_0x5027db,_0x15a96b=this;this[_0x18614b('0x26')]['enqueue'](function(){const _0x46b3fb=_0x18614b;return _0x15a96b[_0x46b3fb('0xb')][_0x46b3fb('0x1e')](_0x3d4a20,_0x4dc8ca,_0x421b44)[_0x46b3fb('0x17')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x4dc8ca,_0x3d4a20);})['catch'](function(_0x39eb7c){logger['info'](JSON['stringify'](_0x39eb7c));});});},Migration[_0x5027db('0x25')][_0x5027db('0x1')]=function(_0x14f152,_0x2c23f3,_0x201c4e){const _0x27ed5c=_0x5027db,_0x4348bc=this;this[_0x27ed5c('0x26')]['enqueue'](function(){const _0x2bba87=_0x27ed5c;return _0x4348bc['queryInterface'][_0x2bba87('0x1')](_0x14f152,_0x2c23f3,_0x201c4e)[_0x2bba87('0x17')](function(){const _0x3f70a3=_0x2bba87;logger[_0x3f70a3('0x7')](_0x3f70a3('0x13'),_0x2c23f3,_0x14f152);})[_0x2bba87('0x12')](function(_0x2fce55){const _0x380a7a=_0x2bba87;logger[_0x380a7a('0x7')](JSON['stringify'](_0x2fce55));});});},Migration[_0x5027db('0x25')][_0x5027db('0x2')]=function(_0x2b060e){const _0x4bb803=this;this['sequence']['enqueue'](function(){const _0x142e42=a920_0x2042;return _0x4bb803[_0x142e42('0xb')][_0x142e42('0x2')](_0x2b060e,{'force':!![]})[_0x142e42('0x17')](function(){const _0x2cb04c=_0x142e42;logger[_0x2cb04c('0x7')](_0x2cb04c('0xe'),_0x2b060e);})[_0x142e42('0x12')](function(_0x3a0be1){const _0x249692=_0x142e42;logger[_0x249692('0x7')](JSON[_0x249692('0x1a')](_0x3a0be1));});});},Migration['prototype'][_0x5027db('0x21')]=function(_0x4a8156,_0xc7582d,_0xb1a6c2){const _0x36cdfc=_0x5027db,_0x4828a1=this;this[_0x36cdfc('0x26')][_0x36cdfc('0xc')](function(){const _0x3a8387=_0x36cdfc;return _0x4828a1[_0x3a8387('0xb')]['addIndex'](_0x4a8156,_0xc7582d,{'indexName':_0xb1a6c2})[_0x3a8387('0x17')](function(){const _0x440415=_0x3a8387;logger[_0x440415('0x7')](_0x440415('0x19'),_0x4a8156,_0xc7582d[_0x440415('0x1f')](','),_0xb1a6c2);})[_0x3a8387('0x12')](function(_0xe8f2c5){const _0x3ab0e9=_0x3a8387;logger[_0x3ab0e9('0x7')](JSON['stringify'](_0xe8f2c5));});});},Migration[_0x5027db('0x25')][_0x5027db('0x24')]=function(_0x46f5c2){const _0x2ac491=this;this['sequence']['enqueue'](function(){const _0x39ac64=a920_0x2042;return _0x2ac491['queryInterface'][_0x39ac64('0x6')][_0x39ac64('0x24')](_0x46f5c2)[_0x39ac64('0x17')](function(){const _0xa42e4e=_0x39ac64;logger[_0xa42e4e('0x7')](_0xa42e4e('0x1b'),_0x46f5c2);})[_0x39ac64('0x12')](function(_0x58dca1){const _0xdf4533=_0x39ac64;logger[_0xdf4533('0x7')](JSON[_0xdf4533('0x1a')](_0x58dca1));});});},Migration[_0x5027db('0x25')][_0x5027db('0x9')]=function(_0x4b8eee,_0x15ab40){const _0x2579df=_0x5027db,_0x362bd3=this;this[_0x2579df('0x26')][_0x2579df('0xc')](function(){const _0x31d4c1=_0x2579df;return _0x362bd3[_0x31d4c1('0xb')][_0x31d4c1('0x9')](_0x4b8eee,_0x15ab40)[_0x31d4c1('0x17')](function(){const _0x5acb47=_0x31d4c1;logger[_0x5acb47('0x7')](_0x5acb47('0xa'),_0x15ab40,_0x4b8eee);})['catch'](function(_0x2fef2a){const _0x98d6f9=_0x31d4c1;logger[_0x98d6f9('0x7')](util['inspect'](_0x2fef2a,{'showHidden':![],'depth':null}));});});},Migration[_0x5027db('0x25')][_0x5027db('0x15')]=function(_0x5add60){const _0x3bf2a2=_0x5027db;this[_0x3bf2a2('0x26')][_0x3bf2a2('0xc')](function(){return _0x5add60();});},module[_0x5027db('0x4')]={'up':function(_0x2a3504,_0x3d7fe4){return new Promise(function(_0xd4f084){const _0x101dbf=a920_0x2042,_0x181b20=new Migration(_0x2a3504);_0x181b20['addColumn'](_0x101dbf('0x16'),'serverUrl',{'type':_0x3d7fe4['STRING']}),_0x181b20[_0x101dbf('0x1')](_0x101dbf('0x1d'),'formData',{'type':_0x3d7fe4['TEXT'](_0x101dbf('0x11'))}),_0x181b20[_0x101dbf('0x1')](_0x101dbf('0x14'),_0x101dbf('0x23'),{'type':_0x3d7fe4[_0x101dbf('0x8')],'defaultValue':![]}),_0x181b20[_0x101dbf('0x1')](_0x101dbf('0x3'),_0x101dbf('0xd'),{'type':_0x3d7fe4[_0x101dbf('0x1c')]}),_0x181b20[_0x101dbf('0x1')]('chat_websites',_0x101dbf('0x5'),{'type':_0x3d7fe4['BOOLEAN'],'defaultValue':![]}),_0x181b20[_0x101dbf('0x1e')](_0x101dbf('0xf'),'values',{'type':_0x3d7fe4[_0x101dbf('0x1c')](_0x101dbf('0x11'))}),_0x181b20[_0x101dbf('0x15')](_0xd4f084);});},'down':function(){}}; \ No newline at end of file +const a920_0x4b65=['long','values','inspect','join','stringify','../config/logger','TEXT','agentAvatar','final','info','dropTable','chat_interactions','then','formData','Removed\x20column\x20%s\x20from\x20%s','queryInterface','addIndex\x20%s\x20%s\x20%s','util','tail','enqueue','migration','Changed\x20column\x20%s\x20in\x20table\x20%s','cm_custom_fields','STRING','BOOLEAN','query','changeColumn','catch','removeColumn','sequence','Added\x20column\x20%s\x20to\x20%s','int_desk_accounts','showAgentAvatar','prototype','serverUrl','chat_websites','addColumn'];(function(_0x590086,_0x4b6555){const _0x2f8d39=function(_0x3225cc){while(--_0x3225cc){_0x590086['push'](_0x590086['shift']());}};_0x2f8d39(++_0x4b6555);}(a920_0x4b65,0x8d));const a920_0x2f8d=function(_0x590086,_0x4b6555){_0x590086=_0x590086-0x0;let _0x2f8d39=a920_0x4b65[_0x590086];return _0x2f8d39;};const _0x23bea3=a920_0x2f8d;'use strict';const logger=require(_0x23bea3('0xc'))(_0x23bea3('0x1b')),util=require(_0x23bea3('0x18')),Sequence=function(){};Sequence[_0x23bea3('0x3')][_0x23bea3('0x1a')]=function(_0x3225cc){const _0x462a10=_0x23bea3;this['tail']=this[_0x462a10('0x19')]?this[_0x462a10('0x19')]['finally'](_0x3225cc):_0x3225cc();};const Migration=function(_0x1f6559){const _0x203ccb=_0x23bea3;this[_0x203ccb('0x16')]=_0x1f6559,this[_0x203ccb('0x24')]=new Sequence();};Migration['prototype'][_0x23bea3('0x21')]=function(_0x1ac53f,_0xc535ab,_0x4c178e){const _0x4403f0=_0x23bea3,_0x57cedc=this;this[_0x4403f0('0x24')]['enqueue'](function(){const _0x31265a=_0x4403f0;return _0x57cedc[_0x31265a('0x16')][_0x31265a('0x21')](_0x1ac53f,_0xc535ab,_0x4c178e)['then'](function(){const _0xc47681=_0x31265a;logger[_0xc47681('0x10')](_0xc47681('0x1c'),_0xc535ab,_0x1ac53f);})[_0x31265a('0x22')](function(_0x55438f){const _0x3205df=_0x31265a;logger[_0x3205df('0x10')](JSON[_0x3205df('0xb')](_0x55438f));});});},Migration[_0x23bea3('0x3')][_0x23bea3('0x6')]=function(_0x2463ab,_0x41b5ab,_0x5a2ef4){const _0x1a74b7=this;this['sequence']['enqueue'](function(){const _0x4973ed=a920_0x2f8d;return _0x1a74b7[_0x4973ed('0x16')]['addColumn'](_0x2463ab,_0x41b5ab,_0x5a2ef4)[_0x4973ed('0x13')](function(){const _0x1b70b5=_0x4973ed;logger[_0x1b70b5('0x10')](_0x1b70b5('0x0'),_0x41b5ab,_0x2463ab);})['catch'](function(_0x1b7787){const _0x26996f=_0x4973ed;logger[_0x26996f('0x10')](JSON[_0x26996f('0xb')](_0x1b7787));});});},Migration[_0x23bea3('0x3')]['dropTable']=function(_0x3590de){const _0x1c0a30=_0x23bea3,_0x578290=this;this[_0x1c0a30('0x24')]['enqueue'](function(){const _0x4f20e2=_0x1c0a30;return _0x578290[_0x4f20e2('0x16')][_0x4f20e2('0x11')](_0x3590de,{'force':!![]})[_0x4f20e2('0x13')](function(){logger['info']('table\x20dropped\x20%s',_0x3590de);})[_0x4f20e2('0x22')](function(_0x3c7bbd){const _0x3be746=_0x4f20e2;logger['info'](JSON[_0x3be746('0xb')](_0x3c7bbd));});});},Migration['prototype']['addIndex']=function(_0x3d43dc,_0x360b6e,_0xe630c3){const _0x33d604=_0x23bea3,_0x1a0716=this;this[_0x33d604('0x24')]['enqueue'](function(){const _0x4b6bae=_0x33d604;return _0x1a0716[_0x4b6bae('0x16')]['addIndex'](_0x3d43dc,_0x360b6e,{'indexName':_0xe630c3})[_0x4b6bae('0x13')](function(){const _0x23548e=_0x4b6bae;logger[_0x23548e('0x10')](_0x23548e('0x17'),_0x3d43dc,_0x360b6e[_0x23548e('0xa')](','),_0xe630c3);})[_0x4b6bae('0x22')](function(_0xbf65c3){const _0x281398=_0x4b6bae;logger[_0x281398('0x10')](JSON[_0x281398('0xb')](_0xbf65c3));});});},Migration[_0x23bea3('0x3')][_0x23bea3('0x20')]=function(_0x2fac2d){const _0x376d65=_0x23bea3,_0x2d0e4f=this;this[_0x376d65('0x24')][_0x376d65('0x1a')](function(){const _0x16a10a=_0x376d65;return _0x2d0e4f[_0x16a10a('0x16')]['sequelize'][_0x16a10a('0x20')](_0x2fac2d)['then'](function(){const _0x2bd852=_0x16a10a;logger[_0x2bd852('0x10')]('query\x20%s',_0x2fac2d);})[_0x16a10a('0x22')](function(_0x2278d0){const _0x1e7d97=_0x16a10a;logger[_0x1e7d97('0x10')](JSON[_0x1e7d97('0xb')](_0x2278d0));});});},Migration['prototype'][_0x23bea3('0x23')]=function(_0x3a55f0,_0x3e9d50){const _0xef2933=_0x23bea3,_0x5c2f2d=this;this[_0xef2933('0x24')][_0xef2933('0x1a')](function(){const _0x41f45d=_0xef2933;return _0x5c2f2d[_0x41f45d('0x16')][_0x41f45d('0x23')](_0x3a55f0,_0x3e9d50)[_0x41f45d('0x13')](function(){const _0x2cd401=_0x41f45d;logger['info'](_0x2cd401('0x15'),_0x3e9d50,_0x3a55f0);})[_0x41f45d('0x22')](function(_0x7679a7){const _0x29b397=_0x41f45d;logger[_0x29b397('0x10')](util[_0x29b397('0x9')](_0x7679a7,{'showHidden':![],'depth':null}));});});},Migration[_0x23bea3('0x3')][_0x23bea3('0xf')]=function(_0x3dea9b){const _0x297de8=_0x23bea3;this[_0x297de8('0x24')][_0x297de8('0x1a')](function(){return _0x3dea9b();});},module['exports']={'up':function(_0x4d478d,_0x39c74a){return new Promise(function(_0x32381a){const _0x50872c=a920_0x2f8d,_0x53fc05=new Migration(_0x4d478d);_0x53fc05[_0x50872c('0x6')](_0x50872c('0x1'),_0x50872c('0x4'),{'type':_0x39c74a[_0x50872c('0x1e')]}),_0x53fc05[_0x50872c('0x6')](_0x50872c('0x12'),_0x50872c('0x14'),{'type':_0x39c74a[_0x50872c('0xd')](_0x50872c('0x7'))}),_0x53fc05['addColumn']('chat_messages','secret',{'type':_0x39c74a[_0x50872c('0x1f')],'defaultValue':![]}),_0x53fc05[_0x50872c('0x6')](_0x50872c('0x5'),_0x50872c('0xe'),{'type':_0x39c74a[_0x50872c('0xd')]}),_0x53fc05[_0x50872c('0x6')](_0x50872c('0x5'),_0x50872c('0x2'),{'type':_0x39c74a[_0x50872c('0x1f')],'defaultValue':![]}),_0x53fc05[_0x50872c('0x21')](_0x50872c('0x1d'),_0x50872c('0x8'),{'type':_0x39c74a[_0x50872c('0xd')]('long')}),_0x53fc05['final'](_0x32381a);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.42.js b/server/migrations/2.0.42.js index bc436e8..417277d 100644 --- a/server/migrations/2.0.42.js +++ b/server/migrations/2.0.42.js @@ -1 +1 @@ -const a921_0x3fd5=['util','sequelize','finally','openchannel_messages','exports','cf_','Added\x20column\x20%s\x20to\x20%s','api/cmCustomField/cmCustomField.model','sequence','prototype','dropTable','TEXT','number','BOOLEAN','addIndex\x20%s\x20%s\x20%s','getCustomFields','secret','tail','import','stringify','catch','query','enqueue','tools_tags','inspect','../config/environment','final','path','notIn','addColumn','query\x20%s','../config/logger','removeColumn','queryInterface','info','failMessage','join','addIndex','root','findAll','migration','STRING','switch','changeColumn','#0091EA','then'];(function(_0x140667,_0x3fd588){const _0x2f2e0b=function(_0x1ab719){while(--_0x1ab719){_0x140667['push'](_0x140667['shift']());}};_0x2f2e0b(++_0x3fd588);}(a921_0x3fd5,0x1a2));const a921_0x2f2e=function(_0x140667,_0x3fd588){_0x140667=_0x140667-0x0;let _0x2f2e0b=a921_0x3fd5[_0x140667];return _0x2f2e0b;};const _0x2d349e=a921_0x2f2e;'use strict';const logger=require(_0x2d349e('0x1b'))(_0x2d349e('0x24')),util=require(_0x2d349e('0x2a')),path=require(_0x2d349e('0x17')),config=require(_0x2d349e('0x15')),{Op}=require(_0x2d349e('0x2b')),Sequence=function(){};Sequence[_0x2d349e('0x5')][_0x2d349e('0x12')]=function(_0x1ab719){const _0x5b0d5e=_0x2d349e;this[_0x5b0d5e('0xd')]=this['tail']?this['tail'][_0x5b0d5e('0x2c')](_0x1ab719):_0x1ab719();};const Migration=function(_0x1fc5a7){const _0x2fbabf=_0x2d349e;this[_0x2fbabf('0x1d')]=_0x1fc5a7,this[_0x2fbabf('0x4')]=new Sequence();};Migration[_0x2d349e('0x5')]['changeColumn']=function(_0x318304,_0x123cc6,_0x29cbd5){const _0x15ef21=_0x2d349e,_0x547eb7=this;this[_0x15ef21('0x4')][_0x15ef21('0x12')](function(){const _0x4c160f=_0x15ef21;return _0x547eb7[_0x4c160f('0x1d')][_0x4c160f('0x27')](_0x318304,_0x123cc6,_0x29cbd5)['then'](function(){const _0x2edba1=_0x4c160f;logger[_0x2edba1('0x1e')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x123cc6,_0x318304);})[_0x4c160f('0x10')](function(_0x5150be){const _0xd0692b=_0x4c160f;logger[_0xd0692b('0x1e')](JSON[_0xd0692b('0xf')](_0x5150be));});});},Migration[_0x2d349e('0x5')][_0x2d349e('0x19')]=function(_0x4d2bfc,_0x526200,_0x47c5d7){const _0x52900c=_0x2d349e,_0x226647=this;this['sequence'][_0x52900c('0x12')](function(){const _0x232928=_0x52900c;return _0x226647[_0x232928('0x1d')][_0x232928('0x19')](_0x4d2bfc,_0x526200,_0x47c5d7)[_0x232928('0x29')](function(){const _0x40229a=_0x232928;logger[_0x40229a('0x1e')](_0x40229a('0x2'),_0x526200,_0x4d2bfc);})[_0x232928('0x10')](function(_0x3755ca){const _0xb29181=_0x232928;logger['info'](JSON[_0xb29181('0xf')](_0x3755ca));});});},Migration['prototype'][_0x2d349e('0x6')]=function(_0x4b3924){const _0x1765cd=_0x2d349e,_0x52af4e=this;this['sequence'][_0x1765cd('0x12')](function(){const _0x313200=_0x1765cd;return _0x52af4e[_0x313200('0x1d')][_0x313200('0x6')](_0x4b3924,{'force':!![]})[_0x313200('0x29')](function(){logger['info']('table\x20dropped\x20%s',_0x4b3924);})['catch'](function(_0x56901a){const _0x159cf0=_0x313200;logger['info'](JSON[_0x159cf0('0xf')](_0x56901a));});});},Migration[_0x2d349e('0x5')][_0x2d349e('0x21')]=function(_0xab4c17,_0x2cdfd4,_0x5d4dc0){const _0x255157=_0x2d349e,_0x1fa25a=this;this[_0x255157('0x4')][_0x255157('0x12')](function(){const _0x5ee0f6=_0x255157;return _0x1fa25a[_0x5ee0f6('0x1d')]['addIndex'](_0xab4c17,_0x2cdfd4,{'indexName':_0x5d4dc0})[_0x5ee0f6('0x29')](function(){const _0x4713b3=_0x5ee0f6;logger[_0x4713b3('0x1e')](_0x4713b3('0xa'),_0xab4c17,_0x2cdfd4[_0x4713b3('0x20')](','),_0x5d4dc0);})[_0x5ee0f6('0x10')](function(_0x22ac8c){const _0x4e71ba=_0x5ee0f6;logger[_0x4e71ba('0x1e')](JSON['stringify'](_0x22ac8c));});});},Migration['prototype']['query']=function(_0x2ab8b6){const _0xcc8a2b=_0x2d349e,_0x5f2145=this;this[_0xcc8a2b('0x4')][_0xcc8a2b('0x12')](function(){const _0x1316b6=_0xcc8a2b;return _0x5f2145['queryInterface'][_0x1316b6('0x2b')][_0x1316b6('0x11')](_0x2ab8b6)[_0x1316b6('0x29')](function(){const _0x36ecf6=_0x1316b6;logger[_0x36ecf6('0x1e')](_0x36ecf6('0x1a'),_0x2ab8b6);})['catch'](function(_0x27f874){const _0x24cfbd=_0x1316b6;logger[_0x24cfbd('0x1e')](JSON[_0x24cfbd('0xf')](_0x27f874));});});},Migration[_0x2d349e('0x5')][_0x2d349e('0x1c')]=function(_0x2f62ce,_0x5b5232){const _0x2faf4e=_0x2d349e,_0x67cb9c=this;this[_0x2faf4e('0x4')][_0x2faf4e('0x12')](function(){const _0x2d0149=_0x2faf4e;return _0x67cb9c[_0x2d0149('0x1d')]['removeColumn'](_0x2f62ce,_0x5b5232)[_0x2d0149('0x29')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x5b5232,_0x2f62ce);})['catch'](function(_0x5f0cb2){const _0x45c8aa=_0x2d0149;logger['info'](util[_0x45c8aa('0x14')](_0x5f0cb2,{'showHidden':![],'depth':null}));});});},Migration[_0x2d349e('0x5')][_0x2d349e('0xb')]=function(){const _0x27d73e=_0x2d349e,_0x2bcb83=this,_0x2abc51=_0x2bcb83[_0x27d73e('0x1d')][_0x27d73e('0x2b')][_0x27d73e('0xe')](path[_0x27d73e('0x20')](config[_0x27d73e('0x22')],_0x27d73e('0x3')));return _0x2abc51[_0x27d73e('0x23')]({'where':{'type':{[Op[_0x27d73e('0x18')]]:[_0x27d73e('0x8'),_0x27d73e('0x26')]}},'attributes':['id']})[_0x27d73e('0x29')](function(_0xb41cf7){return _0xb41cf7;})[_0x27d73e('0x10')](function(_0x445631){const _0x713eb=_0x27d73e;logger['info'](JSON[_0x713eb('0xf')](_0x445631));});},Migration[_0x2d349e('0x5')][_0x2d349e('0x16')]=function(_0x27aa98){const _0xa43aeb=_0x2d349e;this[_0xa43aeb('0x4')][_0xa43aeb('0x12')](function(){return _0x27aa98();});},module[_0x2d349e('0x0')]={'up':function(_0x4379ae,_0x4af946){return new Promise(function(_0xdf84b6){const _0x21b915=a921_0x2f2e,_0x2aba8d=new Migration(_0x4379ae);_0x2aba8d[_0x21b915('0x19')](_0x21b915('0x13'),'color',{'type':_0x4af946['STRING'],'defaultValue':_0x21b915('0x28')}),_0x2aba8d[_0x21b915('0x19')](_0x21b915('0x2d'),_0x21b915('0xc'),{'type':_0x4af946[_0x21b915('0x9')],'defaultValue':![]}),_0x2aba8d[_0x21b915('0xb')]()[_0x21b915('0x29')](function(_0x1c1fd2){const _0x4b32d3=_0x21b915;if(_0x1c1fd2)for(let _0x491b35=0x0,_0x572442=_0x1c1fd2['length'];_0x491b35<_0x572442;_0x491b35++){_0x2aba8d[_0x4b32d3('0x27')]('cm_contacts',_0x4b32d3('0x1')+_0x1c1fd2[_0x491b35]['id'],{'type':_0x4af946['TEXT']});}}),_0x2aba8d[_0x21b915('0x19')]('fax_messages',_0x21b915('0x1f'),{'type':_0x4af946[_0x21b915('0x7')]}),_0x2aba8d['addColumn']('users','extensionMonitor',{'type':_0x4af946[_0x21b915('0x25')],'defaultValue':''}),_0x2aba8d[_0x21b915('0x16')](_0xdf84b6);});},'down':function(){}}; \ No newline at end of file +const a921_0x4e0c=['getCustomFields','users','../config/logger','table\x20dropped\x20%s','enqueue','api/cmCustomField/cmCustomField.model','#0091EA','sequence','openchannel_messages','query','Removed\x20column\x20%s\x20from\x20%s','sequelize','BOOLEAN','color','findAll','STRING','finally','tools_tags','migration','final','secret','switch','cm_contacts','notIn','changeColumn','then','number','util','info','Changed\x20column\x20%s\x20in\x20table\x20%s','tail','inspect','addColumn','dropTable','fax_messages','removeColumn','queryInterface','length','join','stringify','../config/environment','Added\x20column\x20%s\x20to\x20%s','query\x20%s','catch','prototype','TEXT','cf_'];(function(_0x1de914,_0x4e0cef){const _0x3647e8=function(_0x53323c){while(--_0x53323c){_0x1de914['push'](_0x1de914['shift']());}};_0x3647e8(++_0x4e0cef);}(a921_0x4e0c,0xf5));const a921_0x3647=function(_0x1de914,_0x4e0cef){_0x1de914=_0x1de914-0x0;let _0x3647e8=a921_0x4e0c[_0x1de914];return _0x3647e8;};const _0x4c6672=a921_0x3647;'use strict';const logger=require(_0x4c6672('0x27'))(_0x4c6672('0x8')),util=require(_0x4c6672('0x11')),path=require('path'),config=require(_0x4c6672('0x1e')),{Op}=require(_0x4c6672('0x1')),Sequence=function(){};Sequence[_0x4c6672('0x22')][_0x4c6672('0x29')]=function(_0x53323c){const _0x56fcbd=_0x4c6672;this[_0x56fcbd('0x14')]=this[_0x56fcbd('0x14')]?this[_0x56fcbd('0x14')][_0x56fcbd('0x6')](_0x53323c):_0x53323c();};const Migration=function(_0x5d82b2){const _0x509f68=_0x4c6672;this[_0x509f68('0x1a')]=_0x5d82b2,this['sequence']=new Sequence();};Migration[_0x4c6672('0x22')][_0x4c6672('0xe')]=function(_0x5c2413,_0x437bc5,_0x24e6a8){const _0x1a7225=_0x4c6672,_0x157923=this;this[_0x1a7225('0x2c')][_0x1a7225('0x29')](function(){const _0x291b46=_0x1a7225;return _0x157923[_0x291b46('0x1a')][_0x291b46('0xe')](_0x5c2413,_0x437bc5,_0x24e6a8)[_0x291b46('0xf')](function(){const _0x31d860=_0x291b46;logger[_0x31d860('0x12')](_0x31d860('0x13'),_0x437bc5,_0x5c2413);})['catch'](function(_0x4d21f3){const _0x274e98=_0x291b46;logger[_0x274e98('0x12')](JSON[_0x274e98('0x1d')](_0x4d21f3));});});},Migration[_0x4c6672('0x22')][_0x4c6672('0x16')]=function(_0x3ec77f,_0x134140,_0x2ee70b){const _0x12dd9c=_0x4c6672,_0x529542=this;this[_0x12dd9c('0x2c')][_0x12dd9c('0x29')](function(){const _0x1285ca=_0x12dd9c;return _0x529542[_0x1285ca('0x1a')]['addColumn'](_0x3ec77f,_0x134140,_0x2ee70b)[_0x1285ca('0xf')](function(){const _0x4f6ef9=_0x1285ca;logger[_0x4f6ef9('0x12')](_0x4f6ef9('0x1f'),_0x134140,_0x3ec77f);})[_0x1285ca('0x21')](function(_0x5e93fb){const _0x2a668a=_0x1285ca;logger['info'](JSON[_0x2a668a('0x1d')](_0x5e93fb));});});},Migration[_0x4c6672('0x22')]['dropTable']=function(_0x3ba713){const _0x443a96=_0x4c6672,_0x363945=this;this[_0x443a96('0x2c')][_0x443a96('0x29')](function(){const _0x3ac319=_0x443a96;return _0x363945['queryInterface'][_0x3ac319('0x17')](_0x3ba713,{'force':!![]})[_0x3ac319('0xf')](function(){const _0x1bb72c=_0x3ac319;logger[_0x1bb72c('0x12')](_0x1bb72c('0x28'),_0x3ba713);})[_0x3ac319('0x21')](function(_0x37b7fa){const _0x2f027e=_0x3ac319;logger['info'](JSON[_0x2f027e('0x1d')](_0x37b7fa));});});},Migration[_0x4c6672('0x22')]['addIndex']=function(_0x30a2bb,_0x564f8c,_0x41d4a9){const _0x299ede=_0x4c6672,_0x2b47c5=this;this[_0x299ede('0x2c')][_0x299ede('0x29')](function(){const _0x2d5e90=_0x299ede;return _0x2b47c5['queryInterface']['addIndex'](_0x30a2bb,_0x564f8c,{'indexName':_0x41d4a9})[_0x2d5e90('0xf')](function(){const _0x1b1b64=_0x2d5e90;logger[_0x1b1b64('0x12')]('addIndex\x20%s\x20%s\x20%s',_0x30a2bb,_0x564f8c[_0x1b1b64('0x1c')](','),_0x41d4a9);})[_0x2d5e90('0x21')](function(_0x3ca925){const _0x18ed21=_0x2d5e90;logger['info'](JSON[_0x18ed21('0x1d')](_0x3ca925));});});},Migration['prototype'][_0x4c6672('0x2e')]=function(_0x13b9b0){const _0x2c58ef=_0x4c6672,_0x1a2a45=this;this[_0x2c58ef('0x2c')]['enqueue'](function(){const _0x3eae84=_0x2c58ef;return _0x1a2a45[_0x3eae84('0x1a')][_0x3eae84('0x1')][_0x3eae84('0x2e')](_0x13b9b0)[_0x3eae84('0xf')](function(){const _0x14ef61=_0x3eae84;logger[_0x14ef61('0x12')](_0x14ef61('0x20'),_0x13b9b0);})[_0x3eae84('0x21')](function(_0x358fe8){const _0x208a77=_0x3eae84;logger[_0x208a77('0x12')](JSON[_0x208a77('0x1d')](_0x358fe8));});});},Migration[_0x4c6672('0x22')][_0x4c6672('0x19')]=function(_0x576449,_0x5e2617){const _0xd2268b=_0x4c6672,_0x2d4b9a=this;this[_0xd2268b('0x2c')][_0xd2268b('0x29')](function(){const _0x1acca7=_0xd2268b;return _0x2d4b9a[_0x1acca7('0x1a')][_0x1acca7('0x19')](_0x576449,_0x5e2617)[_0x1acca7('0xf')](function(){const _0x349286=_0x1acca7;logger[_0x349286('0x12')](_0x349286('0x0'),_0x5e2617,_0x576449);})[_0x1acca7('0x21')](function(_0x1b614b){const _0x49b3d8=_0x1acca7;logger[_0x49b3d8('0x12')](util[_0x49b3d8('0x15')](_0x1b614b,{'showHidden':![],'depth':null}));});});},Migration[_0x4c6672('0x22')][_0x4c6672('0x25')]=function(){const _0xfdffe3=_0x4c6672,_0x4d9031=this,_0x367f97=_0x4d9031[_0xfdffe3('0x1a')][_0xfdffe3('0x1')]['import'](path[_0xfdffe3('0x1c')](config['root'],_0xfdffe3('0x2a')));return _0x367f97[_0xfdffe3('0x4')]({'where':{'type':{[Op[_0xfdffe3('0xd')]]:[_0xfdffe3('0x10'),_0xfdffe3('0xb')]}},'attributes':['id']})['then'](function(_0x59f6f2){return _0x59f6f2;})['catch'](function(_0x6e2481){const _0x536575=_0xfdffe3;logger['info'](JSON[_0x536575('0x1d')](_0x6e2481));});},Migration[_0x4c6672('0x22')][_0x4c6672('0x9')]=function(_0x456bc9){const _0x511df1=_0x4c6672;this[_0x511df1('0x2c')]['enqueue'](function(){return _0x456bc9();});},module['exports']={'up':function(_0x4f872e,_0x3b3ca4){return new Promise(function(_0x24b319){const _0x38ee7b=a921_0x3647,_0x57483d=new Migration(_0x4f872e);_0x57483d[_0x38ee7b('0x16')](_0x38ee7b('0x7'),_0x38ee7b('0x3'),{'type':_0x3b3ca4[_0x38ee7b('0x5')],'defaultValue':_0x38ee7b('0x2b')}),_0x57483d[_0x38ee7b('0x16')](_0x38ee7b('0x2d'),_0x38ee7b('0xa'),{'type':_0x3b3ca4[_0x38ee7b('0x2')],'defaultValue':![]}),_0x57483d['getCustomFields']()[_0x38ee7b('0xf')](function(_0x104728){const _0x409869=_0x38ee7b;if(_0x104728)for(let _0x4b8da4=0x0,_0x43da6b=_0x104728[_0x409869('0x1b')];_0x4b8da4<_0x43da6b;_0x4b8da4++){_0x57483d[_0x409869('0xe')](_0x409869('0xc'),_0x409869('0x24')+_0x104728[_0x4b8da4]['id'],{'type':_0x3b3ca4['TEXT']});}}),_0x57483d[_0x38ee7b('0x16')](_0x38ee7b('0x18'),'failMessage',{'type':_0x3b3ca4[_0x38ee7b('0x23')]}),_0x57483d[_0x38ee7b('0x16')](_0x38ee7b('0x26'),'extensionMonitor',{'type':_0x3b3ca4[_0x38ee7b('0x5')],'defaultValue':''}),_0x57483d[_0x38ee7b('0x9')](_0x24b319);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.43.js b/server/migrations/2.0.43.js index c64fc2f..2b6d20a 100644 --- a/server/migrations/2.0.43.js +++ b/server/migrations/2.0.43.js @@ -1 +1 @@ -const a922_0x3e5c=['migration','addIndex','enqueue','sequence','catch','finally','stringify','then','final','Changed\x20column\x20%s\x20in\x20table\x20%s','query\x20%s','tail','dropTable','mail_messages','info','table\x20dropped\x20%s','Removed\x20column\x20%s\x20from\x20%s','query','changeColumn','queryInterface','exports','prototype','addColumn','removeColumn','join','util'];(function(_0x5bc8f9,_0x3e5cc3){const _0x24d93f=function(_0x8e1bcd){while(--_0x8e1bcd){_0x5bc8f9['push'](_0x5bc8f9['shift']());}};_0x24d93f(++_0x3e5cc3);}(a922_0x3e5c,0x12d));const a922_0x24d9=function(_0x5bc8f9,_0x3e5cc3){_0x5bc8f9=_0x5bc8f9-0x0;let _0x24d93f=a922_0x3e5c[_0x5bc8f9];return _0x24d93f;};const _0x2509af=a922_0x24d9;'use strict';const logger=require('../config/logger')(_0x2509af('0xb')),util=require(_0x2509af('0xa')),Sequence=function(){};Sequence[_0x2509af('0x6')][_0x2509af('0xd')]=function(_0x8e1bcd){const _0x12e1a5=_0x2509af;this['tail']=this['tail']?this[_0x12e1a5('0x16')][_0x12e1a5('0x10')](_0x8e1bcd):_0x8e1bcd();};const Migration=function(_0x1204e2){const _0x3f5ba3=_0x2509af;this[_0x3f5ba3('0x4')]=_0x1204e2,this[_0x3f5ba3('0xe')]=new Sequence();};Migration[_0x2509af('0x6')][_0x2509af('0x3')]=function(_0x52ec93,_0x2aff15,_0x421f51){const _0x54399d=_0x2509af,_0x35eb6f=this;this[_0x54399d('0xe')][_0x54399d('0xd')](function(){const _0x4fb42c=_0x54399d;return _0x35eb6f[_0x4fb42c('0x4')][_0x4fb42c('0x3')](_0x52ec93,_0x2aff15,_0x421f51)[_0x4fb42c('0x12')](function(){const _0x59c9d8=_0x4fb42c;logger['info'](_0x59c9d8('0x14'),_0x2aff15,_0x52ec93);})[_0x4fb42c('0xf')](function(_0x3d615d){const _0xc1be70=_0x4fb42c;logger['info'](JSON[_0xc1be70('0x11')](_0x3d615d));});});},Migration[_0x2509af('0x6')][_0x2509af('0x7')]=function(_0x12b543,_0x29d19d,_0x7662a0){const _0x2a98f=_0x2509af,_0x3bb509=this;this['sequence'][_0x2a98f('0xd')](function(){const _0xe56afd=_0x2a98f;return _0x3bb509[_0xe56afd('0x4')][_0xe56afd('0x7')](_0x12b543,_0x29d19d,_0x7662a0)[_0xe56afd('0x12')](function(){const _0x2734e2=_0xe56afd;logger[_0x2734e2('0x19')]('Added\x20column\x20%s\x20to\x20%s',_0x29d19d,_0x12b543);})[_0xe56afd('0xf')](function(_0x3f9317){const _0x3bd1e0=_0xe56afd;logger[_0x3bd1e0('0x19')](JSON['stringify'](_0x3f9317));});});},Migration[_0x2509af('0x6')]['dropTable']=function(_0x1cc9c4){const _0x3ee040=this;this['sequence']['enqueue'](function(){const _0x7a2039=a922_0x24d9;return _0x3ee040['queryInterface'][_0x7a2039('0x17')](_0x1cc9c4,{'force':!![]})[_0x7a2039('0x12')](function(){const _0x256327=_0x7a2039;logger[_0x256327('0x19')](_0x256327('0x0'),_0x1cc9c4);})['catch'](function(_0x34bed5){const _0x27249c=_0x7a2039;logger[_0x27249c('0x19')](JSON[_0x27249c('0x11')](_0x34bed5));});});},Migration[_0x2509af('0x6')]['addIndex']=function(_0x5c3501,_0xe1fd15,_0x525c70){const _0x40ed49=_0x2509af,_0x427fd6=this;this[_0x40ed49('0xe')]['enqueue'](function(){const _0x99fda2=_0x40ed49;return _0x427fd6[_0x99fda2('0x4')][_0x99fda2('0xc')](_0x5c3501,_0xe1fd15,{'indexName':_0x525c70})['then'](function(){const _0x19c4c2=_0x99fda2;logger[_0x19c4c2('0x19')]('addIndex\x20%s\x20%s\x20%s',_0x5c3501,_0xe1fd15[_0x19c4c2('0x9')](','),_0x525c70);})[_0x99fda2('0xf')](function(_0x59771e){const _0x4ba8dd=_0x99fda2;logger[_0x4ba8dd('0x19')](JSON[_0x4ba8dd('0x11')](_0x59771e));});});},Migration[_0x2509af('0x6')]['query']=function(_0x4ca3e2){const _0x40ca4a=_0x2509af,_0x3d4b46=this;this[_0x40ca4a('0xe')][_0x40ca4a('0xd')](function(){const _0x2c7b1b=_0x40ca4a;return _0x3d4b46['queryInterface']['sequelize'][_0x2c7b1b('0x2')](_0x4ca3e2)['then'](function(){const _0x536252=_0x2c7b1b;logger[_0x536252('0x19')](_0x536252('0x15'),_0x4ca3e2);})[_0x2c7b1b('0xf')](function(_0x33ab74){const _0x4f808b=_0x2c7b1b;logger['info'](JSON[_0x4f808b('0x11')](_0x33ab74));});});},Migration[_0x2509af('0x6')][_0x2509af('0x8')]=function(_0x3a02de,_0x3fcfbb){const _0x4e0779=_0x2509af,_0x5985e7=this;this[_0x4e0779('0xe')][_0x4e0779('0xd')](function(){const _0x3b2597=_0x4e0779;return _0x5985e7[_0x3b2597('0x4')]['removeColumn'](_0x3a02de,_0x3fcfbb)['then'](function(){const _0x451cea=_0x3b2597;logger[_0x451cea('0x19')](_0x451cea('0x1'),_0x3fcfbb,_0x3a02de);})['catch'](function(_0x1b99ba){const _0x25f3e=_0x3b2597;logger[_0x25f3e('0x19')](util['inspect'](_0x1b99ba,{'showHidden':![],'depth':null}));});});},Migration[_0x2509af('0x6')][_0x2509af('0x13')]=function(_0x161158){const _0x5139f0=_0x2509af;this[_0x5139f0('0xe')][_0x5139f0('0xd')](function(){return _0x161158();});},module[_0x2509af('0x5')]={'up':function(_0xeb513b,_0x50b6ba){return new Promise(function(_0x839ae0){const _0x3834e1=a922_0x24d9,_0x1a80e9=new Migration(_0xeb513b);_0x1a80e9[_0x3834e1('0x7')](_0x3834e1('0x18'),'secret',{'type':_0x50b6ba['BOOLEAN'],'defaultValue':![]}),_0x1a80e9[_0x3834e1('0x13')](_0x839ae0);});},'down':function(){}}; \ No newline at end of file +const a922_0x479c=['dropTable','stringify','Removed\x20column\x20%s\x20from\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','enqueue','queryInterface','table\x20dropped\x20%s','then','finally','util','addIndex','final','removeColumn','changeColumn','migration','addColumn','sequence','prototype','secret','Added\x20column\x20%s\x20to\x20%s','query','inspect','join','info','mail_messages','catch','addIndex\x20%s\x20%s\x20%s','tail','../config/logger','exports'];(function(_0x51312a,_0x479c9e){const _0x4d4f9e=function(_0x298ec3){while(--_0x298ec3){_0x51312a['push'](_0x51312a['shift']());}};_0x4d4f9e(++_0x479c9e);}(a922_0x479c,0x14c));const a922_0x4d4f=function(_0x51312a,_0x479c9e){_0x51312a=_0x51312a-0x0;let _0x4d4f9e=a922_0x479c[_0x51312a];return _0x4d4f9e;};const _0x4ad5f2=a922_0x4d4f;'use strict';const logger=require(_0x4ad5f2('0x1a'))(_0x4ad5f2('0xc')),util=require(_0x4ad5f2('0x7')),Sequence=function(){};Sequence[_0x4ad5f2('0xf')][_0x4ad5f2('0x2')]=function(_0x298ec3){const _0x122e54=_0x4ad5f2;this[_0x122e54('0x19')]=this['tail']?this[_0x122e54('0x19')][_0x122e54('0x6')](_0x298ec3):_0x298ec3();};const Migration=function(_0x8101ef){const _0x57948=_0x4ad5f2;this[_0x57948('0x3')]=_0x8101ef,this['sequence']=new Sequence();};Migration['prototype']['changeColumn']=function(_0x1b6183,_0x1d2f92,_0x12b9ad){const _0x271107=_0x4ad5f2,_0x267769=this;this[_0x271107('0xe')][_0x271107('0x2')](function(){const _0x9a83ce=_0x271107;return _0x267769[_0x9a83ce('0x3')][_0x9a83ce('0xb')](_0x1b6183,_0x1d2f92,_0x12b9ad)[_0x9a83ce('0x5')](function(){const _0x1be286=_0x9a83ce;logger[_0x1be286('0x15')](_0x1be286('0x1'),_0x1d2f92,_0x1b6183);})['catch'](function(_0x565333){const _0x356f8a=_0x9a83ce;logger[_0x356f8a('0x15')](JSON[_0x356f8a('0x1d')](_0x565333));});});},Migration[_0x4ad5f2('0xf')][_0x4ad5f2('0xd')]=function(_0xae40b1,_0x1d2a53,_0x3262da){const _0x13c857=_0x4ad5f2,_0x1ef0d6=this;this[_0x13c857('0xe')]['enqueue'](function(){const _0x91571e=_0x13c857;return _0x1ef0d6['queryInterface'][_0x91571e('0xd')](_0xae40b1,_0x1d2a53,_0x3262da)[_0x91571e('0x5')](function(){const _0x1e2965=_0x91571e;logger[_0x1e2965('0x15')](_0x1e2965('0x11'),_0x1d2a53,_0xae40b1);})['catch'](function(_0x590de3){const _0x9ed572=_0x91571e;logger[_0x9ed572('0x15')](JSON[_0x9ed572('0x1d')](_0x590de3));});});},Migration['prototype'][_0x4ad5f2('0x1c')]=function(_0x123df4){const _0x10e8fb=_0x4ad5f2,_0x492408=this;this[_0x10e8fb('0xe')][_0x10e8fb('0x2')](function(){const _0x3783f7=_0x10e8fb;return _0x492408[_0x3783f7('0x3')][_0x3783f7('0x1c')](_0x123df4,{'force':!![]})[_0x3783f7('0x5')](function(){const _0x2687bd=_0x3783f7;logger[_0x2687bd('0x15')](_0x2687bd('0x4'),_0x123df4);})[_0x3783f7('0x17')](function(_0x20526d){const _0x2a8d77=_0x3783f7;logger[_0x2a8d77('0x15')](JSON[_0x2a8d77('0x1d')](_0x20526d));});});},Migration['prototype'][_0x4ad5f2('0x8')]=function(_0x16373b,_0x1f1710,_0x364c86){const _0x3b1edb=_0x4ad5f2,_0x129d10=this;this['sequence'][_0x3b1edb('0x2')](function(){const _0x31fdc4=_0x3b1edb;return _0x129d10[_0x31fdc4('0x3')][_0x31fdc4('0x8')](_0x16373b,_0x1f1710,{'indexName':_0x364c86})[_0x31fdc4('0x5')](function(){const _0x43a494=_0x31fdc4;logger[_0x43a494('0x15')](_0x43a494('0x18'),_0x16373b,_0x1f1710[_0x43a494('0x14')](','),_0x364c86);})[_0x31fdc4('0x17')](function(_0x4b5275){const _0x1d0846=_0x31fdc4;logger[_0x1d0846('0x15')](JSON[_0x1d0846('0x1d')](_0x4b5275));});});},Migration[_0x4ad5f2('0xf')][_0x4ad5f2('0x12')]=function(_0x2e1293){const _0x4c6d52=_0x4ad5f2,_0x12d249=this;this['sequence'][_0x4c6d52('0x2')](function(){const _0x14739c=_0x4c6d52;return _0x12d249[_0x14739c('0x3')]['sequelize'][_0x14739c('0x12')](_0x2e1293)[_0x14739c('0x5')](function(){const _0x145ec8=_0x14739c;logger[_0x145ec8('0x15')]('query\x20%s',_0x2e1293);})[_0x14739c('0x17')](function(_0x173122){const _0x33133d=_0x14739c;logger[_0x33133d('0x15')](JSON[_0x33133d('0x1d')](_0x173122));});});},Migration[_0x4ad5f2('0xf')][_0x4ad5f2('0xa')]=function(_0x3de3f7,_0x4ab951){const _0x410e45=_0x4ad5f2,_0xd3f73e=this;this['sequence'][_0x410e45('0x2')](function(){const _0x256056=_0x410e45;return _0xd3f73e[_0x256056('0x3')][_0x256056('0xa')](_0x3de3f7,_0x4ab951)[_0x256056('0x5')](function(){const _0x41691c=_0x256056;logger[_0x41691c('0x15')](_0x41691c('0x0'),_0x4ab951,_0x3de3f7);})[_0x256056('0x17')](function(_0x52d86d){const _0x2a7bd6=_0x256056;logger[_0x2a7bd6('0x15')](util[_0x2a7bd6('0x13')](_0x52d86d,{'showHidden':![],'depth':null}));});});},Migration[_0x4ad5f2('0xf')][_0x4ad5f2('0x9')]=function(_0x214ace){const _0x471074=_0x4ad5f2;this['sequence'][_0x471074('0x2')](function(){return _0x214ace();});},module[_0x4ad5f2('0x1b')]={'up':function(_0x3f4e0e,_0x3e9ca1){return new Promise(function(_0x47e30d){const _0x1e973d=a922_0x4d4f,_0x248bb7=new Migration(_0x3f4e0e);_0x248bb7[_0x1e973d('0xd')](_0x1e973d('0x16'),_0x1e973d('0x10'),{'type':_0x3e9ca1['BOOLEAN'],'defaultValue':![]}),_0x248bb7[_0x1e973d('0x9')](_0x47e30d);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.44.js b/server/migrations/2.0.44.js index e180c8d..1968b17 100644 --- a/server/migrations/2.0.44.js +++ b/server/migrations/2.0.44.js @@ -1 +1 @@ -const a923_0x5843=['chat_interactions','read1stAt','addIndex\x20%s\x20%s\x20%s','threadId','openchannel_messages','query\x20%s','then','addColumn','ALTER\x20TABLE\x20mail_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20MailAccountId)','final','enqueue','tail','catch','info','voice_dispositions','addIndex','Removed\x20column\x20%s\x20from\x20%s','inspect','Changed\x20column\x20%s\x20in\x20table\x20%s','substatusAt','util','migration','fax_messages','Do\x20you\x20want\x20to\x20close\x20the\x20interaction?','DATE','openchannel_interactions','fax_interactions','dropTable','join','mail_interactions','ALTER\x20TABLE\x20voice_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20ListId)','substatus','sequence','query','stringify','table\x20dropped\x20%s','ALTER\x20TABLE\x20openchannel_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20OpenchannelAccountId)','openchannel_dispositions','chat_dispositions','finally','ALTER\x20TABLE\x20chat_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20ChatAccountId)','STRING','sms_messages','chat_messages','ALTER\x20TABLE\x20fax_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20FaxAccountId)','Added\x20column\x20%s\x20to\x20%s','removeColumn','changeColumn','name','ALTER\x20TABLE\x20sms_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20SmsAccountId)','queryInterface','prototype','nameAndAccount','readAt'];(function(_0x124d5e,_0x58439f){const _0x414da1=function(_0x33d222){while(--_0x33d222){_0x124d5e['push'](_0x124d5e['shift']());}};_0x414da1(++_0x58439f);}(a923_0x5843,0x104));const a923_0x414d=function(_0x124d5e,_0x58439f){_0x124d5e=_0x124d5e-0x0;let _0x414da1=a923_0x5843[_0x124d5e];return _0x414da1;};const _0x3803ef=a923_0x414d;'use strict';const logger=require('../config/logger')(_0x3803ef('0x1f')),util=require(_0x3803ef('0x1e')),Sequence=function(){};Sequence['prototype'][_0x3803ef('0x14')]=function(_0x33d222){const _0x294884=_0x3803ef;this['tail']=this[_0x294884('0x15')]?this[_0x294884('0x15')][_0x294884('0x31')](_0x33d222):_0x33d222();};const Migration=function(_0x1c1449){const _0x4e9cfc=_0x3803ef;this[_0x4e9cfc('0x6')]=_0x1c1449,this[_0x4e9cfc('0x2a')]=new Sequence();};Migration[_0x3803ef('0x7')][_0x3803ef('0x3')]=function(_0x2700af,_0x466c40,_0x162661){const _0x5e54e3=_0x3803ef,_0x2e1fac=this;this[_0x5e54e3('0x2a')][_0x5e54e3('0x14')](function(){const _0x22695a=_0x5e54e3;return _0x2e1fac[_0x22695a('0x6')]['changeColumn'](_0x2700af,_0x466c40,_0x162661)[_0x22695a('0x10')](function(){const _0x160cc2=_0x22695a;logger[_0x160cc2('0x17')](_0x160cc2('0x1c'),_0x466c40,_0x2700af);})[_0x22695a('0x16')](function(_0x2bcf6e){const _0x4931f1=_0x22695a;logger[_0x4931f1('0x17')](JSON[_0x4931f1('0x2c')](_0x2bcf6e));});});},Migration[_0x3803ef('0x7')][_0x3803ef('0x11')]=function(_0x1db272,_0x428c00,_0x7baee1){const _0x9d8318=_0x3803ef,_0x57fa99=this;this[_0x9d8318('0x2a')][_0x9d8318('0x14')](function(){const _0x1a3bcb=_0x9d8318;return _0x57fa99['queryInterface']['addColumn'](_0x1db272,_0x428c00,_0x7baee1)[_0x1a3bcb('0x10')](function(){const _0x1b9208=_0x1a3bcb;logger['info'](_0x1b9208('0x1'),_0x428c00,_0x1db272);})[_0x1a3bcb('0x16')](function(_0x537d1e){const _0x39ac3a=_0x1a3bcb;logger[_0x39ac3a('0x17')](JSON[_0x39ac3a('0x2c')](_0x537d1e));});});},Migration[_0x3803ef('0x7')]['dropTable']=function(_0x32d491){const _0x5a42aa=_0x3803ef,_0x164a35=this;this[_0x5a42aa('0x2a')]['enqueue'](function(){const _0x581335=_0x5a42aa;return _0x164a35[_0x581335('0x6')][_0x581335('0x25')](_0x32d491,{'force':!![]})[_0x581335('0x10')](function(){const _0x57fb99=_0x581335;logger[_0x57fb99('0x17')](_0x57fb99('0x2d'),_0x32d491);})['catch'](function(_0x5bb86e){const _0x121553=_0x581335;logger[_0x121553('0x17')](JSON[_0x121553('0x2c')](_0x5bb86e));});});},Migration[_0x3803ef('0x7')][_0x3803ef('0x19')]=function(_0x5162e2,_0xb09c68,_0x420e36){const _0x2c6404=_0x3803ef,_0x4e8b1c=this;this['sequence'][_0x2c6404('0x14')](function(){const _0x3fe9ab=_0x2c6404;return _0x4e8b1c['queryInterface'][_0x3fe9ab('0x19')](_0x5162e2,_0xb09c68,{'indexName':_0x420e36})[_0x3fe9ab('0x10')](function(){const _0x45c28b=_0x3fe9ab;logger[_0x45c28b('0x17')](_0x45c28b('0xc'),_0x5162e2,_0xb09c68[_0x45c28b('0x26')](','),_0x420e36);})[_0x3fe9ab('0x16')](function(_0x5baef1){const _0x225b49=_0x3fe9ab;logger[_0x225b49('0x17')](JSON['stringify'](_0x5baef1));});});},Migration[_0x3803ef('0x7')][_0x3803ef('0x2b')]=function(_0x425ac0){const _0x11fe6a=_0x3803ef,_0x2622e0=this;this[_0x11fe6a('0x2a')][_0x11fe6a('0x14')](function(){const _0x1053cb=_0x11fe6a;return _0x2622e0['queryInterface']['sequelize']['query'](_0x425ac0)[_0x1053cb('0x10')](function(){const _0x2baa86=_0x1053cb;logger[_0x2baa86('0x17')](_0x2baa86('0xf'),_0x425ac0);})[_0x1053cb('0x16')](function(_0x2b7aaa){const _0x20bf8a=_0x1053cb;logger[_0x20bf8a('0x17')](JSON[_0x20bf8a('0x2c')](_0x2b7aaa));});});},Migration[_0x3803ef('0x7')]['removeColumn']=function(_0x1f87d9,_0x438e1e){const _0x51fd62=_0x3803ef,_0x4ce309=this;this[_0x51fd62('0x2a')]['enqueue'](function(){const _0x4799ba=_0x51fd62;return _0x4ce309[_0x4799ba('0x6')][_0x4799ba('0x2')](_0x1f87d9,_0x438e1e)[_0x4799ba('0x10')](function(){const _0x29d7d5=_0x4799ba;logger[_0x29d7d5('0x17')](_0x29d7d5('0x1a'),_0x438e1e,_0x1f87d9);})[_0x4799ba('0x16')](function(_0x16410b){const _0x2c3264=_0x4799ba;logger[_0x2c3264('0x17')](util[_0x2c3264('0x1b')](_0x16410b,{'showHidden':![],'depth':null}));});});},Migration[_0x3803ef('0x7')][_0x3803ef('0x13')]=function(_0x4ffd0e){const _0x46c69f=_0x3803ef;this[_0x46c69f('0x2a')][_0x46c69f('0x14')](function(){return _0x4ffd0e();});},module['exports']={'up':function(_0x189db4,_0x29e32a){return new Promise(function(_0x50679d){const _0x3820d4=a923_0x414d,_0x88d3de=new Migration(_0x189db4);_0x88d3de[_0x3820d4('0x11')]('chat_websites','closingQuestion',{'type':_0x29e32a[_0x3820d4('0x33')],'defaultValue':_0x3820d4('0x21')}),_0x88d3de[_0x3820d4('0x11')](_0x3820d4('0xa'),_0x3820d4('0xb'),{'type':_0x29e32a['DATE']}),_0x88d3de[_0x3820d4('0x11')](_0x3820d4('0x35'),_0x3820d4('0x9'),{'type':_0x29e32a[_0x3820d4('0x22')]}),_0x88d3de[_0x3820d4('0x11')](_0x3820d4('0x24'),_0x3820d4('0xb'),{'type':_0x29e32a[_0x3820d4('0x22')]}),_0x88d3de[_0x3820d4('0x11')](_0x3820d4('0x20'),'readAt',{'type':_0x29e32a[_0x3820d4('0x22')]}),_0x88d3de[_0x3820d4('0x11')]('openchannel_interactions',_0x3820d4('0xb'),{'type':_0x29e32a[_0x3820d4('0x22')]}),_0x88d3de[_0x3820d4('0x11')](_0x3820d4('0x23'),_0x3820d4('0xd'),{'type':_0x29e32a['STRING']}),_0x88d3de[_0x3820d4('0x11')]('openchannel_interactions','externalUrl',{'type':_0x29e32a[_0x3820d4('0x33')]}),_0x88d3de['addColumn'](_0x3820d4('0xe'),'readAt',{'type':_0x29e32a['DATE']}),_0x88d3de[_0x3820d4('0x11')](_0x3820d4('0x27'),'read1stAt',{'type':_0x29e32a['DATE']}),_0x88d3de[_0x3820d4('0x11')](_0x3820d4('0x27'),_0x3820d4('0x29'),{'type':_0x29e32a[_0x3820d4('0x33')](0x3c)}),_0x88d3de[_0x3820d4('0x11')](_0x3820d4('0x27'),_0x3820d4('0x1d'),{'type':_0x29e32a[_0x3820d4('0x22')]}),_0x88d3de['addColumn']('mail_messages','readAt',{'type':_0x29e32a[_0x3820d4('0x22')]}),_0x88d3de['addColumn']('sms_interactions','read1stAt',{'type':_0x29e32a['DATE']}),_0x88d3de[_0x3820d4('0x11')](_0x3820d4('0x34'),_0x3820d4('0x9'),{'type':_0x29e32a[_0x3820d4('0x22')]}),_0x88d3de['changeColumn'](_0x3820d4('0x30'),_0x3820d4('0x4'),{'type':_0x29e32a['STRING'],'unique':'nameAndAccount','allowNull':![]}),_0x88d3de[_0x3820d4('0x3')]('fax_dispositions',_0x3820d4('0x4'),{'type':_0x29e32a['STRING'],'unique':_0x3820d4('0x8'),'allowNull':![]}),_0x88d3de[_0x3820d4('0x3')](_0x3820d4('0x2f'),_0x3820d4('0x4'),{'type':_0x29e32a['STRING'],'unique':_0x3820d4('0x8'),'allowNull':![]}),_0x88d3de[_0x3820d4('0x3')]('sms_dispositions',_0x3820d4('0x4'),{'type':_0x29e32a['STRING'],'unique':_0x3820d4('0x8'),'allowNull':![]}),_0x88d3de['changeColumn'](_0x3820d4('0x18'),_0x3820d4('0x4'),{'type':_0x29e32a[_0x3820d4('0x33')],'unique':_0x3820d4('0x8'),'allowNull':![]}),_0x88d3de[_0x3820d4('0x2b')](_0x3820d4('0x32')),_0x88d3de[_0x3820d4('0x2b')](_0x3820d4('0x0')),_0x88d3de[_0x3820d4('0x2b')](_0x3820d4('0x2e')),_0x88d3de[_0x3820d4('0x2b')](_0x3820d4('0x5')),_0x88d3de[_0x3820d4('0x2b')](_0x3820d4('0x28')),_0x88d3de[_0x3820d4('0x3')]('mail_dispositions',_0x3820d4('0x4'),{'type':_0x29e32a[_0x3820d4('0x33')],'unique':_0x3820d4('0x8'),'allowNull':![]}),_0x88d3de['query']('ALTER\x20TABLE\x20mail_dispositions\x20DROP\x20INDEX\x20name'),_0x88d3de[_0x3820d4('0x2b')](_0x3820d4('0x12')),_0x88d3de[_0x3820d4('0x13')](_0x50679d);});},'down':function(){}}; \ No newline at end of file +const a923_0x499b=['nameAndAccount','Changed\x20column\x20%s\x20in\x20table\x20%s','openchannel_dispositions','../config/logger','sequence','finally','threadId','ALTER\x20TABLE\x20chat_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20ChatAccountId)','stringify','sms_interactions','addIndex\x20%s\x20%s\x20%s','closingQuestion','mail_interactions','migration','DATE','externalUrl','fax_dispositions','changeColumn','openchannel_interactions','tail','fax_messages','openchannel_messages','ALTER\x20TABLE\x20fax_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20FaxAccountId)','chat_dispositions','name','join','catch','query','prototype','info','ALTER\x20TABLE\x20openchannel_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20OpenchannelAccountId)','read1stAt','STRING','removeColumn','enqueue','ALTER\x20TABLE\x20mail_dispositions\x20DROP\x20INDEX\x20name','ALTER\x20TABLE\x20sms_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20SmsAccountId)','Added\x20column\x20%s\x20to\x20%s','chat_websites','ALTER\x20TABLE\x20voice_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20ListId)','then','Do\x20you\x20want\x20to\x20close\x20the\x20interaction?','substatus','sms_messages','queryInterface','dropTable','readAt','ALTER\x20TABLE\x20mail_dispositions\x20add\x20UNIQUE\x20INDEX\x20nameAndAccount\x20(name,\x20MailAccountId)','exports','mail_dispositions','addColumn'];(function(_0x19ce71,_0x499b72){const _0x44886b=function(_0x33560c){while(--_0x33560c){_0x19ce71['push'](_0x19ce71['shift']());}};_0x44886b(++_0x499b72);}(a923_0x499b,0xbe));const a923_0x4488=function(_0x19ce71,_0x499b72){_0x19ce71=_0x19ce71-0x0;let _0x44886b=a923_0x499b[_0x19ce71];return _0x44886b;};const _0x173a79=a923_0x4488;'use strict';const logger=require(_0x173a79('0x11'))(_0x173a79('0x1b')),util=require('util'),Sequence=function(){};Sequence[_0x173a79('0x2a')][_0x173a79('0x30')]=function(_0x33560c){const _0x2a8fe2=_0x173a79;this[_0x2a8fe2('0x21')]=this[_0x2a8fe2('0x21')]?this[_0x2a8fe2('0x21')][_0x2a8fe2('0x13')](_0x33560c):_0x33560c();};const Migration=function(_0x101b9c){const _0xc86e2=_0x173a79;this[_0xc86e2('0x7')]=_0x101b9c,this[_0xc86e2('0x12')]=new Sequence();};Migration[_0x173a79('0x2a')][_0x173a79('0x1f')]=function(_0x21b66e,_0x114fcd,_0x4b0bb0){const _0x4c153e=_0x173a79,_0x5d0887=this;this[_0x4c153e('0x12')][_0x4c153e('0x30')](function(){const _0x2122a9=_0x4c153e;return _0x5d0887[_0x2122a9('0x7')][_0x2122a9('0x1f')](_0x21b66e,_0x114fcd,_0x4b0bb0)[_0x2122a9('0x3')](function(){const _0x274142=_0x2122a9;logger[_0x274142('0x2b')](_0x274142('0xf'),_0x114fcd,_0x21b66e);})[_0x2122a9('0x28')](function(_0x213cf7){const _0x41baab=_0x2122a9;logger[_0x41baab('0x2b')](JSON[_0x41baab('0x16')](_0x213cf7));});});},Migration[_0x173a79('0x2a')][_0x173a79('0xd')]=function(_0x18cf2b,_0x11cb2a,_0x2e62a3){const _0x438bee=_0x173a79,_0x81f348=this;this[_0x438bee('0x12')][_0x438bee('0x30')](function(){const _0x4c28ae=_0x438bee;return _0x81f348[_0x4c28ae('0x7')][_0x4c28ae('0xd')](_0x18cf2b,_0x11cb2a,_0x2e62a3)[_0x4c28ae('0x3')](function(){const _0x26b04c=_0x4c28ae;logger[_0x26b04c('0x2b')](_0x26b04c('0x0'),_0x11cb2a,_0x18cf2b);})[_0x4c28ae('0x28')](function(_0x1a6c5c){const _0x31a816=_0x4c28ae;logger[_0x31a816('0x2b')](JSON[_0x31a816('0x16')](_0x1a6c5c));});});},Migration[_0x173a79('0x2a')][_0x173a79('0x8')]=function(_0x36d2ae){const _0x5a5ab4=_0x173a79,_0x355055=this;this[_0x5a5ab4('0x12')]['enqueue'](function(){const _0x1c687e=_0x5a5ab4;return _0x355055['queryInterface'][_0x1c687e('0x8')](_0x36d2ae,{'force':!![]})['then'](function(){const _0x20743e=_0x1c687e;logger[_0x20743e('0x2b')]('table\x20dropped\x20%s',_0x36d2ae);})['catch'](function(_0xf02a29){const _0xb62b2f=_0x1c687e;logger['info'](JSON[_0xb62b2f('0x16')](_0xf02a29));});});},Migration['prototype']['addIndex']=function(_0x13a0e6,_0xe7dcbb,_0xddb184){const _0x1a1a47=_0x173a79,_0x4db5fd=this;this[_0x1a1a47('0x12')][_0x1a1a47('0x30')](function(){const _0x418fe8=_0x1a1a47;return _0x4db5fd[_0x418fe8('0x7')]['addIndex'](_0x13a0e6,_0xe7dcbb,{'indexName':_0xddb184})[_0x418fe8('0x3')](function(){const _0x1f27a1=_0x418fe8;logger[_0x1f27a1('0x2b')](_0x1f27a1('0x18'),_0x13a0e6,_0xe7dcbb[_0x1f27a1('0x27')](','),_0xddb184);})[_0x418fe8('0x28')](function(_0x57e9db){const _0x587d16=_0x418fe8;logger[_0x587d16('0x2b')](JSON[_0x587d16('0x16')](_0x57e9db));});});},Migration[_0x173a79('0x2a')][_0x173a79('0x29')]=function(_0x4cc61e){const _0x46780d=_0x173a79,_0x22e8e5=this;this[_0x46780d('0x12')][_0x46780d('0x30')](function(){const _0x506d12=_0x46780d;return _0x22e8e5[_0x506d12('0x7')]['sequelize']['query'](_0x4cc61e)[_0x506d12('0x3')](function(){logger['info']('query\x20%s',_0x4cc61e);})[_0x506d12('0x28')](function(_0x124ba5){const _0x281fa2=_0x506d12;logger[_0x281fa2('0x2b')](JSON[_0x281fa2('0x16')](_0x124ba5));});});},Migration['prototype'][_0x173a79('0x2f')]=function(_0x1c23a3,_0x9d40b1){const _0x4dd523=_0x173a79,_0xafdea3=this;this['sequence'][_0x4dd523('0x30')](function(){const _0x520379=_0x4dd523;return _0xafdea3[_0x520379('0x7')][_0x520379('0x2f')](_0x1c23a3,_0x9d40b1)[_0x520379('0x3')](function(){const _0x254a9f=_0x520379;logger[_0x254a9f('0x2b')]('Removed\x20column\x20%s\x20from\x20%s',_0x9d40b1,_0x1c23a3);})[_0x520379('0x28')](function(_0x584c2d){const _0x346e2b=_0x520379;logger[_0x346e2b('0x2b')](util['inspect'](_0x584c2d,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x9159ae){const _0x1f0c7b=_0x173a79;this[_0x1f0c7b('0x12')][_0x1f0c7b('0x30')](function(){return _0x9159ae();});},module[_0x173a79('0xb')]={'up':function(_0x4078a9,_0x996792){return new Promise(function(_0x23a26a){const _0xb977b2=a923_0x4488,_0xb438ad=new Migration(_0x4078a9);_0xb438ad[_0xb977b2('0xd')](_0xb977b2('0x1'),_0xb977b2('0x19'),{'type':_0x996792[_0xb977b2('0x2e')],'defaultValue':_0xb977b2('0x4')}),_0xb438ad[_0xb977b2('0xd')]('chat_interactions',_0xb977b2('0x2d'),{'type':_0x996792[_0xb977b2('0x1c')]}),_0xb438ad[_0xb977b2('0xd')]('chat_messages','readAt',{'type':_0x996792[_0xb977b2('0x1c')]}),_0xb438ad[_0xb977b2('0xd')]('fax_interactions',_0xb977b2('0x2d'),{'type':_0x996792[_0xb977b2('0x1c')]}),_0xb438ad['addColumn'](_0xb977b2('0x22'),'readAt',{'type':_0x996792['DATE']}),_0xb438ad[_0xb977b2('0xd')](_0xb977b2('0x20'),_0xb977b2('0x2d'),{'type':_0x996792['DATE']}),_0xb438ad[_0xb977b2('0xd')](_0xb977b2('0x20'),_0xb977b2('0x14'),{'type':_0x996792[_0xb977b2('0x2e')]}),_0xb438ad[_0xb977b2('0xd')](_0xb977b2('0x20'),_0xb977b2('0x1d'),{'type':_0x996792[_0xb977b2('0x2e')]}),_0xb438ad[_0xb977b2('0xd')](_0xb977b2('0x23'),_0xb977b2('0x9'),{'type':_0x996792[_0xb977b2('0x1c')]}),_0xb438ad['addColumn'](_0xb977b2('0x1a'),_0xb977b2('0x2d'),{'type':_0x996792[_0xb977b2('0x1c')]}),_0xb438ad['addColumn']('mail_interactions',_0xb977b2('0x5'),{'type':_0x996792[_0xb977b2('0x2e')](0x3c)}),_0xb438ad[_0xb977b2('0xd')](_0xb977b2('0x1a'),'substatusAt',{'type':_0x996792[_0xb977b2('0x1c')]}),_0xb438ad[_0xb977b2('0xd')]('mail_messages','readAt',{'type':_0x996792['DATE']}),_0xb438ad[_0xb977b2('0xd')](_0xb977b2('0x17'),_0xb977b2('0x2d'),{'type':_0x996792[_0xb977b2('0x1c')]}),_0xb438ad[_0xb977b2('0xd')](_0xb977b2('0x6'),_0xb977b2('0x9'),{'type':_0x996792['DATE']}),_0xb438ad[_0xb977b2('0x1f')](_0xb977b2('0x25'),_0xb977b2('0x26'),{'type':_0x996792[_0xb977b2('0x2e')],'unique':_0xb977b2('0xe'),'allowNull':![]}),_0xb438ad[_0xb977b2('0x1f')](_0xb977b2('0x1e'),_0xb977b2('0x26'),{'type':_0x996792[_0xb977b2('0x2e')],'unique':'nameAndAccount','allowNull':![]}),_0xb438ad['changeColumn'](_0xb977b2('0x10'),_0xb977b2('0x26'),{'type':_0x996792[_0xb977b2('0x2e')],'unique':'nameAndAccount','allowNull':![]}),_0xb438ad['changeColumn']('sms_dispositions',_0xb977b2('0x26'),{'type':_0x996792[_0xb977b2('0x2e')],'unique':_0xb977b2('0xe'),'allowNull':![]}),_0xb438ad[_0xb977b2('0x1f')]('voice_dispositions',_0xb977b2('0x26'),{'type':_0x996792[_0xb977b2('0x2e')],'unique':_0xb977b2('0xe'),'allowNull':![]}),_0xb438ad[_0xb977b2('0x29')](_0xb977b2('0x15')),_0xb438ad[_0xb977b2('0x29')](_0xb977b2('0x24')),_0xb438ad[_0xb977b2('0x29')](_0xb977b2('0x2c')),_0xb438ad['query'](_0xb977b2('0x32')),_0xb438ad[_0xb977b2('0x29')](_0xb977b2('0x2')),_0xb438ad[_0xb977b2('0x1f')](_0xb977b2('0xc'),_0xb977b2('0x26'),{'type':_0x996792[_0xb977b2('0x2e')],'unique':_0xb977b2('0xe'),'allowNull':![]}),_0xb438ad[_0xb977b2('0x29')](_0xb977b2('0x31')),_0xb438ad[_0xb977b2('0x29')](_0xb977b2('0xa')),_0xb438ad['final'](_0x23a26a);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.45.js b/server/migrations/2.0.45.js index 983b5f6..6c8fe86 100644 --- a/server/migrations/2.0.45.js +++ b/server/migrations/2.0.45.js @@ -1 +1 @@ -var a924_0x1558=['exports'];(function(_0x5c69de,_0x1558db){var _0x45defc=function(_0x27f37c){while(--_0x27f37c){_0x5c69de['push'](_0x5c69de['shift']());}};_0x45defc(++_0x1558db);}(a924_0x1558,0xcf));var a924_0x45de=function(_0x5c69de,_0x1558db){_0x5c69de=_0x5c69de-0x0;var _0x45defc=a924_0x1558[_0x5c69de];return _0x45defc;};var _0xf3030d=a924_0x45de;'use strict';module[_0xf3030d('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file +var a924_0x570c=['exports'];(function(_0x56bd06,_0x570cad){var _0x1675c7=function(_0x366970){while(--_0x366970){_0x56bd06['push'](_0x56bd06['shift']());}};_0x1675c7(++_0x570cad);}(a924_0x570c,0x87));var a924_0x1675=function(_0x56bd06,_0x570cad){_0x56bd06=_0x56bd06-0x0;var _0x1675c7=a924_0x570c[_0x56bd06];return _0x1675c7;};var _0x1f089b=a924_0x1675;'use strict';module[_0x1f089b('0x0')]={'up':function(){},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.46.js b/server/migrations/2.0.46.js index 41fb219..f56d7b6 100644 --- a/server/migrations/2.0.46.js +++ b/server/migrations/2.0.46.js @@ -1 +1 @@ -const a925_0x1808=['query\x20%s','Note','sequelize','placeholderMessage','changeColumn','sequence','stringify','final','Changed\x20column\x20%s\x20in\x20table\x20%s','fax_interactions','enqueue','UPDATE\x20fax_interactions\x20as\x20t1\x20JOIN\x20cm_contacts\x20AS\x20t2\x20ON\x20t1.ContactId\x20=\x20t2.id\x20SET\x20t1.fax\x20=\x20t2.fax','dropTable','finally','removeColumn','Added\x20column\x20%s\x20to\x20%s','tail','addColumn','addIndex\x20%s\x20%s\x20%s','join','table\x20dropped\x20%s','STRING','Type\x20a\x20message','users','queryInterface','catch','info','prototype','crudPermissions','UPDATE\x20users\x20SET\x20permissions=\x27101,102,103,104,105,106,107,108,109,100\x27\x20WHERE\x20role=\x27agent\x27\x20AND\x20(permissions\x20IS\x20NULL\x20OR\x20permissions\x20=\x20\x27\x27)','../config/logger','noteTitle','then','chat_websites','INTEGER','showWebBar','Removed\x20column\x20%s\x20from\x20%s','migration','addIndex','query','fax'];(function(_0xfcfda5,_0x1808c1){const _0x568601=function(_0x571013){while(--_0x571013){_0xfcfda5['push'](_0xfcfda5['shift']());}};_0x568601(++_0x1808c1);}(a925_0x1808,0x17d));const a925_0x5686=function(_0xfcfda5,_0x1808c1){_0xfcfda5=_0xfcfda5-0x0;let _0x568601=a925_0x1808[_0xfcfda5];return _0x568601;};const _0x5695ad=a925_0x5686;'use strict';const logger=require(_0x5695ad('0x12'))(_0x5695ad('0x19')),util=require('util'),Sequence=function(){};Sequence[_0x5695ad('0xf')][_0x5695ad('0x27')]=function(_0x571013){const _0x1f1865=_0x5695ad;this['tail']=this['tail']?this[_0x1f1865('0x4')][_0x1f1865('0x1')](_0x571013):_0x571013();};const Migration=function(_0x184b7b){const _0x3fe85e=_0x5695ad;this[_0x3fe85e('0xc')]=_0x184b7b,this['sequence']=new Sequence();};Migration['prototype'][_0x5695ad('0x21')]=function(_0x53ca4a,_0x4cb80f,_0x457175){const _0xe022f7=_0x5695ad,_0x26fb26=this;this[_0xe022f7('0x22')][_0xe022f7('0x27')](function(){const _0x593b41=_0xe022f7;return _0x26fb26['queryInterface']['changeColumn'](_0x53ca4a,_0x4cb80f,_0x457175)['then'](function(){const _0x703a5e=a925_0x5686;logger[_0x703a5e('0xe')](_0x703a5e('0x25'),_0x4cb80f,_0x53ca4a);})[_0x593b41('0xd')](function(_0x30009b){const _0x50ecbe=_0x593b41;logger[_0x50ecbe('0xe')](JSON[_0x50ecbe('0x23')](_0x30009b));});});},Migration[_0x5695ad('0xf')][_0x5695ad('0x5')]=function(_0x4a0a79,_0x228704,_0x3277c4){const _0x3b27b3=_0x5695ad,_0x3d3c85=this;this[_0x3b27b3('0x22')]['enqueue'](function(){const _0x2bc3fb=_0x3b27b3;return _0x3d3c85[_0x2bc3fb('0xc')][_0x2bc3fb('0x5')](_0x4a0a79,_0x228704,_0x3277c4)[_0x2bc3fb('0x14')](function(){const _0x4f6865=_0x2bc3fb;logger[_0x4f6865('0xe')](_0x4f6865('0x3'),_0x228704,_0x4a0a79);})[_0x2bc3fb('0xd')](function(_0x2c85e4){const _0x2fd145=_0x2bc3fb;logger[_0x2fd145('0xe')](JSON[_0x2fd145('0x23')](_0x2c85e4));});});},Migration['prototype'][_0x5695ad('0x0')]=function(_0x1e8693){const _0x2d6960=_0x5695ad,_0x28cd93=this;this['sequence'][_0x2d6960('0x27')](function(){const _0x16d5b0=_0x2d6960;return _0x28cd93[_0x16d5b0('0xc')]['dropTable'](_0x1e8693,{'force':!![]})[_0x16d5b0('0x14')](function(){const _0x45803a=_0x16d5b0;logger[_0x45803a('0xe')](_0x45803a('0x8'),_0x1e8693);})[_0x16d5b0('0xd')](function(_0x1c01dc){const _0x87a8a5=_0x16d5b0;logger[_0x87a8a5('0xe')](JSON['stringify'](_0x1c01dc));});});},Migration[_0x5695ad('0xf')][_0x5695ad('0x1a')]=function(_0x390bc7,_0x2067ef,_0x31e788){const _0x8d2b55=_0x5695ad,_0x58131c=this;this['sequence'][_0x8d2b55('0x27')](function(){const _0x19521f=_0x8d2b55;return _0x58131c[_0x19521f('0xc')][_0x19521f('0x1a')](_0x390bc7,_0x2067ef,{'indexName':_0x31e788})['then'](function(){const _0x569729=_0x19521f;logger['info'](_0x569729('0x6'),_0x390bc7,_0x2067ef[_0x569729('0x7')](','),_0x31e788);})[_0x19521f('0xd')](function(_0x365ffb){const _0x59d3d0=_0x19521f;logger[_0x59d3d0('0xe')](JSON[_0x59d3d0('0x23')](_0x365ffb));});});},Migration[_0x5695ad('0xf')]['query']=function(_0x182ca1){const _0x673bca=_0x5695ad,_0x2f01b7=this;this[_0x673bca('0x22')][_0x673bca('0x27')](function(){const _0x176d69=_0x673bca;return _0x2f01b7['queryInterface'][_0x176d69('0x1f')][_0x176d69('0x1b')](_0x182ca1)['then'](function(){const _0x3b9b6c=_0x176d69;logger[_0x3b9b6c('0xe')](_0x3b9b6c('0x1d'),_0x182ca1);})[_0x176d69('0xd')](function(_0x36945d){const _0x40863b=_0x176d69;logger[_0x40863b('0xe')](JSON[_0x40863b('0x23')](_0x36945d));});});},Migration[_0x5695ad('0xf')][_0x5695ad('0x2')]=function(_0x3d3bc2,_0x5eb816){const _0x5b6cf7=_0x5695ad,_0x5e956b=this;this['sequence'][_0x5b6cf7('0x27')](function(){const _0xff68ea=_0x5b6cf7;return _0x5e956b[_0xff68ea('0xc')]['removeColumn'](_0x3d3bc2,_0x5eb816)[_0xff68ea('0x14')](function(){const _0x2e9da9=_0xff68ea;logger[_0x2e9da9('0xe')](_0x2e9da9('0x18'),_0x5eb816,_0x3d3bc2);})['catch'](function(_0x312d38){const _0x270e14=_0xff68ea;logger[_0x270e14('0xe')](util['inspect'](_0x312d38,{'showHidden':![],'depth':null}));});});},Migration[_0x5695ad('0xf')][_0x5695ad('0x24')]=function(_0x3f2eaa){const _0x490f71=_0x5695ad;this[_0x490f71('0x22')][_0x490f71('0x27')](function(){return _0x3f2eaa();});},module['exports']={'up':function(_0x473c14,_0x4e8387){return new Promise(function(_0x5cdf53){const _0x4345b6=a925_0x5686,_0x23c9b7=new Migration(_0x473c14);_0x23c9b7[_0x4345b6('0x21')](_0x4345b6('0xb'),_0x4345b6('0x17'),{'type':_0x4e8387[_0x4345b6('0x16')],'defaultValue':0x0}),_0x23c9b7[_0x4345b6('0x1b')](_0x4345b6('0x11')),_0x23c9b7[_0x4345b6('0x5')]('users',_0x4345b6('0x10'),{'type':_0x4e8387[_0x4345b6('0x16')],'defaultValue':0x0}),_0x23c9b7[_0x4345b6('0x5')](_0x4345b6('0x15'),_0x4345b6('0x13'),{'type':_0x4e8387[_0x4345b6('0x9')],'defaultValue':_0x4345b6('0x1e')}),_0x23c9b7[_0x4345b6('0x5')](_0x4345b6('0x15'),_0x4345b6('0x20'),{'type':_0x4e8387[_0x4345b6('0x9')],'defaultValue':_0x4345b6('0xa')}),_0x23c9b7[_0x4345b6('0x5')](_0x4345b6('0x26'),_0x4345b6('0x1c'),{'type':_0x4e8387[_0x4345b6('0x9')]}),_0x23c9b7[_0x4345b6('0x1b')](_0x4345b6('0x28')),_0x23c9b7[_0x4345b6('0x24')](_0x5cdf53);});},'down':function(){}}; \ No newline at end of file +const a925_0x15ab=['UPDATE\x20fax_interactions\x20as\x20t1\x20JOIN\x20cm_contacts\x20AS\x20t2\x20ON\x20t1.ContactId\x20=\x20t2.id\x20SET\x20t1.fax\x20=\x20t2.fax','Added\x20column\x20%s\x20to\x20%s','Note','query','fax_interactions','finally','sequelize','prototype','dropTable','addColumn','INTEGER','sequence','users','enqueue','Type\x20a\x20message','addIndex','stringify','catch','STRING','changeColumn','../config/logger','info','removeColumn','Removed\x20column\x20%s\x20from\x20%s','table\x20dropped\x20%s','join','tail','fax','exports','then','showWebBar','queryInterface','noteTitle','chat_websites'];(function(_0x3f26aa,_0x15aba4){const _0x31c0b8=function(_0x3729a2){while(--_0x3729a2){_0x3f26aa['push'](_0x3f26aa['shift']());}};_0x31c0b8(++_0x15aba4);}(a925_0x15ab,0x6f));const a925_0x31c0=function(_0x3f26aa,_0x15aba4){_0x3f26aa=_0x3f26aa-0x0;let _0x31c0b8=a925_0x15ab[_0x3f26aa];return _0x31c0b8;};const _0x4dee16=a925_0x31c0;'use strict';const logger=require(_0x4dee16('0xb'))('migration'),util=require('util'),Sequence=function(){};Sequence[_0x4dee16('0x20')][_0x4dee16('0x4')]=function(_0x3729a2){const _0x8e443d=_0x4dee16;this[_0x8e443d('0x11')]=this[_0x8e443d('0x11')]?this['tail'][_0x8e443d('0x1e')](_0x3729a2):_0x3729a2();};const Migration=function(_0x158830){const _0x15af48=_0x4dee16;this[_0x15af48('0x16')]=_0x158830,this[_0x15af48('0x2')]=new Sequence();};Migration[_0x4dee16('0x20')][_0x4dee16('0xa')]=function(_0x2e1cdf,_0x1a83db,_0x10a1ae){const _0x3e8e5e=_0x4dee16,_0x332841=this;this['sequence'][_0x3e8e5e('0x4')](function(){const _0x1336c9=_0x3e8e5e;return _0x332841[_0x1336c9('0x16')]['changeColumn'](_0x2e1cdf,_0x1a83db,_0x10a1ae)[_0x1336c9('0x14')](function(){const _0xddc243=_0x1336c9;logger[_0xddc243('0xc')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x1a83db,_0x2e1cdf);})[_0x1336c9('0x8')](function(_0x19b560){const _0x21e78d=_0x1336c9;logger[_0x21e78d('0xc')](JSON['stringify'](_0x19b560));});});},Migration['prototype'][_0x4dee16('0x0')]=function(_0x565c36,_0x226206,_0x36a975){const _0x514b43=_0x4dee16,_0x3a9c5e=this;this[_0x514b43('0x2')][_0x514b43('0x4')](function(){const _0x263224=_0x514b43;return _0x3a9c5e[_0x263224('0x16')][_0x263224('0x0')](_0x565c36,_0x226206,_0x36a975)[_0x263224('0x14')](function(){const _0x21f3f8=_0x263224;logger[_0x21f3f8('0xc')](_0x21f3f8('0x1a'),_0x226206,_0x565c36);})[_0x263224('0x8')](function(_0x2c7763){const _0x68915a=_0x263224;logger[_0x68915a('0xc')](JSON[_0x68915a('0x7')](_0x2c7763));});});},Migration[_0x4dee16('0x20')][_0x4dee16('0x21')]=function(_0x339857){const _0x5824cf=_0x4dee16,_0x5d8bdb=this;this[_0x5824cf('0x2')][_0x5824cf('0x4')](function(){const _0x7c19ff=_0x5824cf;return _0x5d8bdb['queryInterface'][_0x7c19ff('0x21')](_0x339857,{'force':!![]})['then'](function(){const _0xb0b50d=_0x7c19ff;logger[_0xb0b50d('0xc')](_0xb0b50d('0xf'),_0x339857);})[_0x7c19ff('0x8')](function(_0x205fd8){const _0x45ed08=_0x7c19ff;logger['info'](JSON[_0x45ed08('0x7')](_0x205fd8));});});},Migration['prototype'][_0x4dee16('0x6')]=function(_0x20671f,_0x3e5dc2,_0x1a1ca4){const _0x1b3a67=_0x4dee16,_0x2c9b89=this;this[_0x1b3a67('0x2')][_0x1b3a67('0x4')](function(){const _0x57605e=_0x1b3a67;return _0x2c9b89[_0x57605e('0x16')][_0x57605e('0x6')](_0x20671f,_0x3e5dc2,{'indexName':_0x1a1ca4})[_0x57605e('0x14')](function(){const _0x17248b=_0x57605e;logger[_0x17248b('0xc')]('addIndex\x20%s\x20%s\x20%s',_0x20671f,_0x3e5dc2[_0x17248b('0x10')](','),_0x1a1ca4);})[_0x57605e('0x8')](function(_0x15e109){const _0x253e40=_0x57605e;logger[_0x253e40('0xc')](JSON[_0x253e40('0x7')](_0x15e109));});});},Migration[_0x4dee16('0x20')][_0x4dee16('0x1c')]=function(_0x4717bb){const _0x3c54e6=this;this['sequence']['enqueue'](function(){const _0x5ca706=a925_0x31c0;return _0x3c54e6['queryInterface'][_0x5ca706('0x1f')][_0x5ca706('0x1c')](_0x4717bb)[_0x5ca706('0x14')](function(){const _0x928d58=_0x5ca706;logger[_0x928d58('0xc')]('query\x20%s',_0x4717bb);})[_0x5ca706('0x8')](function(_0x4480ca){const _0xd081c1=_0x5ca706;logger[_0xd081c1('0xc')](JSON[_0xd081c1('0x7')](_0x4480ca));});});},Migration[_0x4dee16('0x20')][_0x4dee16('0xd')]=function(_0x37a593,_0x520c65){const _0x3f435d=_0x4dee16,_0x52ac92=this;this[_0x3f435d('0x2')][_0x3f435d('0x4')](function(){const _0x34abe8=_0x3f435d;return _0x52ac92[_0x34abe8('0x16')]['removeColumn'](_0x37a593,_0x520c65)[_0x34abe8('0x14')](function(){const _0x3af8c3=_0x34abe8;logger[_0x3af8c3('0xc')](_0x3af8c3('0xe'),_0x520c65,_0x37a593);})[_0x34abe8('0x8')](function(_0x32fa85){logger['info'](util['inspect'](_0x32fa85,{'showHidden':![],'depth':null}));});});},Migration[_0x4dee16('0x20')]['final']=function(_0x3903ae){const _0x1db8eb=_0x4dee16;this[_0x1db8eb('0x2')]['enqueue'](function(){return _0x3903ae();});},module[_0x4dee16('0x13')]={'up':function(_0x41a5b8,_0x27c20c){return new Promise(function(_0x5b91c0){const _0x5a27ae=a925_0x31c0,_0x68ba0=new Migration(_0x41a5b8);_0x68ba0[_0x5a27ae('0xa')](_0x5a27ae('0x3'),_0x5a27ae('0x15'),{'type':_0x27c20c[_0x5a27ae('0x1')],'defaultValue':0x0}),_0x68ba0[_0x5a27ae('0x1c')]('UPDATE\x20users\x20SET\x20permissions=\x27101,102,103,104,105,106,107,108,109,100\x27\x20WHERE\x20role=\x27agent\x27\x20AND\x20(permissions\x20IS\x20NULL\x20OR\x20permissions\x20=\x20\x27\x27)'),_0x68ba0[_0x5a27ae('0x0')](_0x5a27ae('0x3'),'crudPermissions',{'type':_0x27c20c[_0x5a27ae('0x1')],'defaultValue':0x0}),_0x68ba0[_0x5a27ae('0x0')](_0x5a27ae('0x18'),_0x5a27ae('0x17'),{'type':_0x27c20c[_0x5a27ae('0x9')],'defaultValue':_0x5a27ae('0x1b')}),_0x68ba0[_0x5a27ae('0x0')](_0x5a27ae('0x18'),'placeholderMessage',{'type':_0x27c20c[_0x5a27ae('0x9')],'defaultValue':_0x5a27ae('0x5')}),_0x68ba0['addColumn'](_0x5a27ae('0x1d'),_0x5a27ae('0x12'),{'type':_0x27c20c[_0x5a27ae('0x9')]}),_0x68ba0['query'](_0x5a27ae('0x19')),_0x68ba0['final'](_0x5b91c0);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.47.js b/server/migrations/2.0.47.js index 6467808..dc38f19 100644 --- a/server/migrations/2.0.47.js +++ b/server/migrations/2.0.47.js @@ -1 +1 @@ -const a926_0x5ef7=['data','type','final','TEXT','stringify','DELETE\x20FROM\x20dashboards','dashboards','addIndex','enqueue','dropTable','formSubmitFailureMessage','removeColumn','dashboard_items','catch','long','interval','Changed\x20column\x20%s\x20in\x20table\x20%s','addIndex\x20%s\x20%s\x20%s','attrs','info','query','queryInterface','prototype','query\x20%s','Removed\x20column\x20%s\x20from\x20%s','addColumn','sequence','changeColumn','util','Form\x20submission\x20error','chat_websites','table\x20dropped\x20%s','then','title','STRING','BOOLEAN','exports','formSubmitSuccessMessage','join','finally','tail','migration','sequelize'];(function(_0x5acdb0,_0x5ef728){const _0x209f1f=function(_0x3bf8dd){while(--_0x3bf8dd){_0x5acdb0['push'](_0x5acdb0['shift']());}};_0x209f1f(++_0x5ef728);}(a926_0x5ef7,0x66));const a926_0x209f=function(_0x5acdb0,_0x5ef728){_0x5acdb0=_0x5acdb0-0x0;let _0x209f1f=a926_0x5ef7[_0x5acdb0];return _0x209f1f;};const _0x4d66c2=a926_0x209f;'use strict';const logger=require('../config/logger')(_0x4d66c2('0x19')),util=require(_0x4d66c2('0xc')),Sequence=function(){};Sequence[_0x4d66c2('0x6')][_0x4d66c2('0x23')]=function(_0x3bf8dd){const _0x388825=_0x4d66c2;this['tail']=this[_0x388825('0x18')]?this[_0x388825('0x18')][_0x388825('0x17')](_0x3bf8dd):_0x3bf8dd();};const Migration=function(_0x3eecb4){const _0x1efd07=_0x4d66c2;this[_0x1efd07('0x5')]=_0x3eecb4,this[_0x1efd07('0xa')]=new Sequence();};Migration[_0x4d66c2('0x6')]['changeColumn']=function(_0xf4412c,_0x28841e,_0x17aecd){const _0x480dac=_0x4d66c2,_0x55499b=this;this[_0x480dac('0xa')][_0x480dac('0x23')](function(){const _0x245a1d=_0x480dac;return _0x55499b[_0x245a1d('0x5')][_0x245a1d('0xb')](_0xf4412c,_0x28841e,_0x17aecd)['then'](function(){const _0x327570=_0x245a1d;logger[_0x327570('0x3')](_0x327570('0x0'),_0x28841e,_0xf4412c);})[_0x245a1d('0x28')](function(_0x331558){const _0x3c35ef=_0x245a1d;logger[_0x3c35ef('0x3')](JSON['stringify'](_0x331558));});});},Migration[_0x4d66c2('0x6')][_0x4d66c2('0x9')]=function(_0x457195,_0x59ebcd,_0x39aa54){const _0xf22961=_0x4d66c2,_0x28f666=this;this['sequence'][_0xf22961('0x23')](function(){const _0x5a8887=_0xf22961;return _0x28f666[_0x5a8887('0x5')][_0x5a8887('0x9')](_0x457195,_0x59ebcd,_0x39aa54)[_0x5a8887('0x10')](function(){const _0x576990=_0x5a8887;logger[_0x576990('0x3')]('Added\x20column\x20%s\x20to\x20%s',_0x59ebcd,_0x457195);})['catch'](function(_0x3794ac){const _0xea4477=_0x5a8887;logger[_0xea4477('0x3')](JSON['stringify'](_0x3794ac));});});},Migration[_0x4d66c2('0x6')][_0x4d66c2('0x24')]=function(_0x332c92){const _0x36cd47=_0x4d66c2,_0x12bd50=this;this[_0x36cd47('0xa')][_0x36cd47('0x23')](function(){const _0x218380=_0x36cd47;return _0x12bd50[_0x218380('0x5')][_0x218380('0x24')](_0x332c92,{'force':!![]})[_0x218380('0x10')](function(){const _0x38d14d=_0x218380;logger[_0x38d14d('0x3')](_0x38d14d('0xf'),_0x332c92);})['catch'](function(_0x147e15){const _0x3f9554=_0x218380;logger[_0x3f9554('0x3')](JSON['stringify'](_0x147e15));});});},Migration[_0x4d66c2('0x6')][_0x4d66c2('0x22')]=function(_0x1d05aa,_0x42bdac,_0xc24e57){const _0x2a92ae=_0x4d66c2,_0x17396a=this;this['sequence'][_0x2a92ae('0x23')](function(){const _0x4e822b=_0x2a92ae;return _0x17396a[_0x4e822b('0x5')][_0x4e822b('0x22')](_0x1d05aa,_0x42bdac,{'indexName':_0xc24e57})['then'](function(){const _0x30dc4a=_0x4e822b;logger['info'](_0x30dc4a('0x1'),_0x1d05aa,_0x42bdac[_0x30dc4a('0x16')](','),_0xc24e57);})['catch'](function(_0x3731f7){const _0x40fd2d=_0x4e822b;logger[_0x40fd2d('0x3')](JSON[_0x40fd2d('0x1f')](_0x3731f7));});});},Migration[_0x4d66c2('0x6')][_0x4d66c2('0x4')]=function(_0x319a67){const _0x480d59=_0x4d66c2,_0x1065a5=this;this[_0x480d59('0xa')][_0x480d59('0x23')](function(){const _0x149aa2=_0x480d59;return _0x1065a5['queryInterface'][_0x149aa2('0x1a')][_0x149aa2('0x4')](_0x319a67)[_0x149aa2('0x10')](function(){const _0x18cf3c=_0x149aa2;logger[_0x18cf3c('0x3')](_0x18cf3c('0x7'),_0x319a67);})[_0x149aa2('0x28')](function(_0x57d276){const _0x5677f3=_0x149aa2;logger[_0x5677f3('0x3')](JSON[_0x5677f3('0x1f')](_0x57d276));});});},Migration[_0x4d66c2('0x6')]['removeColumn']=function(_0x16118e,_0x1072d2){const _0x17b281=_0x4d66c2,_0x39304b=this;this['sequence'][_0x17b281('0x23')](function(){const _0x17079c=_0x17b281;return _0x39304b['queryInterface'][_0x17079c('0x26')](_0x16118e,_0x1072d2)[_0x17079c('0x10')](function(){const _0x1588d4=_0x17079c;logger[_0x1588d4('0x3')](_0x1588d4('0x8'),_0x1072d2,_0x16118e);})[_0x17079c('0x28')](function(_0xee12bd){logger['info'](util['inspect'](_0xee12bd,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x4d66c2('0x1d')]=function(_0x2e2661){const _0x3a72aa=_0x4d66c2;this[_0x3a72aa('0xa')][_0x3a72aa('0x23')](function(){return _0x2e2661();});},module[_0x4d66c2('0x14')]={'up':function(_0x54ac99,_0x575dc7){return new Promise(function(_0x1b6908){const _0x10849f=a926_0x209f,_0x32593f=new Migration(_0x54ac99);_0x32593f[_0x10849f('0x4')](_0x10849f('0x20')),_0x32593f[_0x10849f('0x26')](_0x10849f('0x21'),_0x10849f('0x2a')),_0x32593f[_0x10849f('0xb')]('dashboard_items',_0x10849f('0x1c'),{'type':_0x575dc7['STRING'](0x14),'allowNull':![],'validate':{'len':[0x1,0x14]}}),_0x32593f['removeColumn'](_0x10849f('0x27'),_0x10849f('0x4')),_0x32593f[_0x10849f('0x26')](_0x10849f('0x27'),_0x10849f('0x1b')),_0x32593f[_0x10849f('0x9')](_0x10849f('0x27'),_0x10849f('0x11'),{'type':_0x575dc7[_0x10849f('0x12')](0x14),'validate':{'len':[0x0,0x14]}}),_0x32593f['addColumn'](_0x10849f('0x27'),_0x10849f('0x2'),{'type':_0x575dc7[_0x10849f('0x1e')](_0x10849f('0x29'))}),_0x32593f[_0x10849f('0x9')]('sms_messages','secret',{'type':_0x575dc7[_0x10849f('0x13')],'defaultValue':![]}),_0x32593f['addColumn'](_0x10849f('0xe'),_0x10849f('0x15'),{'type':_0x575dc7[_0x10849f('0x12')],'defaultValue':'Form\x20properly\x20submitted'}),_0x32593f[_0x10849f('0x9')](_0x10849f('0xe'),_0x10849f('0x25'),{'type':_0x575dc7[_0x10849f('0x12')],'defaultValue':_0x10849f('0xd')}),_0x32593f['final'](_0x1b6908);});},'down':function(){}}; \ No newline at end of file +const a926_0x1ffd=['join','enqueue','dashboard_items','sequelize','sms_messages','../config/logger','exports','chat_websites','finally','sequence','addIndex\x20%s\x20%s\x20%s','tail','stringify','util','query','table\x20dropped\x20%s','dropTable','secret','prototype','long','Form\x20properly\x20submitted','addColumn','changeColumn','data','type','Added\x20column\x20%s\x20to\x20%s','STRING','BOOLEAN','DELETE\x20FROM\x20dashboards','removeColumn','info','queryInterface','inspect','then','catch','dashboards','Changed\x20column\x20%s\x20in\x20table\x20%s'];(function(_0x252cde,_0x1ffd30){const _0x22ee7a=function(_0x267117){while(--_0x267117){_0x252cde['push'](_0x252cde['shift']());}};_0x22ee7a(++_0x1ffd30);}(a926_0x1ffd,0x1b8));const a926_0x22ee=function(_0x252cde,_0x1ffd30){_0x252cde=_0x252cde-0x0;let _0x22ee7a=a926_0x1ffd[_0x252cde];return _0x22ee7a;};const _0x28ab6e=a926_0x22ee;'use strict';const logger=require(_0x28ab6e('0x9'))('migration'),util=require(_0x28ab6e('0x11')),Sequence=function(){};Sequence[_0x28ab6e('0x16')][_0x28ab6e('0x5')]=function(_0x267117){const _0x96a8d8=_0x28ab6e;this[_0x96a8d8('0xf')]=this['tail']?this['tail'][_0x96a8d8('0xc')](_0x267117):_0x267117();};const Migration=function(_0x349623){const _0x139df4=_0x28ab6e;this[_0x139df4('0x23')]=_0x349623,this[_0x139df4('0xd')]=new Sequence();};Migration[_0x28ab6e('0x16')][_0x28ab6e('0x1a')]=function(_0xc42a23,_0x2bfe2e,_0x4acc3e){const _0x396df0=_0x28ab6e,_0x31fd6e=this;this[_0x396df0('0xd')]['enqueue'](function(){const _0x473a30=_0x396df0;return _0x31fd6e['queryInterface'][_0x473a30('0x1a')](_0xc42a23,_0x2bfe2e,_0x4acc3e)[_0x473a30('0x0')](function(){const _0x23b19a=_0x473a30;logger[_0x23b19a('0x22')](_0x23b19a('0x3'),_0x2bfe2e,_0xc42a23);})['catch'](function(_0x265b86){const _0x20b530=_0x473a30;logger['info'](JSON[_0x20b530('0x10')](_0x265b86));});});},Migration['prototype'][_0x28ab6e('0x19')]=function(_0x3feb9e,_0x584e85,_0x25dbd0){const _0x35b319=_0x28ab6e,_0x1d3656=this;this[_0x35b319('0xd')][_0x35b319('0x5')](function(){const _0x217333=_0x35b319;return _0x1d3656[_0x217333('0x23')][_0x217333('0x19')](_0x3feb9e,_0x584e85,_0x25dbd0)[_0x217333('0x0')](function(){const _0x305646=_0x217333;logger[_0x305646('0x22')](_0x305646('0x1d'),_0x584e85,_0x3feb9e);})[_0x217333('0x1')](function(_0x483984){const _0x4aa435=_0x217333;logger[_0x4aa435('0x22')](JSON['stringify'](_0x483984));});});},Migration[_0x28ab6e('0x16')][_0x28ab6e('0x14')]=function(_0x2f4301){const _0x5cbb33=_0x28ab6e,_0x2973d6=this;this[_0x5cbb33('0xd')][_0x5cbb33('0x5')](function(){const _0x21c1c4=_0x5cbb33;return _0x2973d6[_0x21c1c4('0x23')]['dropTable'](_0x2f4301,{'force':!![]})[_0x21c1c4('0x0')](function(){const _0x8c508d=_0x21c1c4;logger[_0x8c508d('0x22')](_0x8c508d('0x13'),_0x2f4301);})[_0x21c1c4('0x1')](function(_0x36b67b){const _0x8cce0d=_0x21c1c4;logger[_0x8cce0d('0x22')](JSON[_0x8cce0d('0x10')](_0x36b67b));});});},Migration[_0x28ab6e('0x16')]['addIndex']=function(_0x6e0ade,_0x31b76e,_0x5df73c){const _0x4c4ddf=this;this['sequence']['enqueue'](function(){const _0x3735a5=a926_0x22ee;return _0x4c4ddf[_0x3735a5('0x23')]['addIndex'](_0x6e0ade,_0x31b76e,{'indexName':_0x5df73c})[_0x3735a5('0x0')](function(){const _0x3b81d3=_0x3735a5;logger[_0x3b81d3('0x22')](_0x3b81d3('0xe'),_0x6e0ade,_0x31b76e[_0x3b81d3('0x4')](','),_0x5df73c);})[_0x3735a5('0x1')](function(_0x13f267){const _0x383962=_0x3735a5;logger[_0x383962('0x22')](JSON[_0x383962('0x10')](_0x13f267));});});},Migration[_0x28ab6e('0x16')]['query']=function(_0x125c81){const _0x223430=_0x28ab6e,_0x2b2996=this;this[_0x223430('0xd')][_0x223430('0x5')](function(){const _0x110d3b=_0x223430;return _0x2b2996['queryInterface'][_0x110d3b('0x7')]['query'](_0x125c81)[_0x110d3b('0x0')](function(){const _0xbf9d22=_0x110d3b;logger[_0xbf9d22('0x22')]('query\x20%s',_0x125c81);})[_0x110d3b('0x1')](function(_0x59b7ef){const _0x49b31f=_0x110d3b;logger[_0x49b31f('0x22')](JSON[_0x49b31f('0x10')](_0x59b7ef));});});},Migration[_0x28ab6e('0x16')][_0x28ab6e('0x21')]=function(_0xb94df5,_0x1068b7){const _0x10f886=_0x28ab6e,_0x519fd2=this;this[_0x10f886('0xd')][_0x10f886('0x5')](function(){const _0xfca8ab=_0x10f886;return _0x519fd2[_0xfca8ab('0x23')][_0xfca8ab('0x21')](_0xb94df5,_0x1068b7)['then'](function(){const _0x31cc6e=_0xfca8ab;logger[_0x31cc6e('0x22')]('Removed\x20column\x20%s\x20from\x20%s',_0x1068b7,_0xb94df5);})['catch'](function(_0x20ce10){const _0x2910c8=_0xfca8ab;logger[_0x2910c8('0x22')](util[_0x2910c8('0x24')](_0x20ce10,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x7f4ff){const _0x149ae9=_0x28ab6e;this['sequence'][_0x149ae9('0x5')](function(){return _0x7f4ff();});},module[_0x28ab6e('0xa')]={'up':function(_0x4cf68c,_0x5e3808){return new Promise(function(_0x136ee7){const _0x9be6e=a926_0x22ee,_0x11caab=new Migration(_0x4cf68c);_0x11caab[_0x9be6e('0x12')](_0x9be6e('0x20')),_0x11caab[_0x9be6e('0x21')](_0x9be6e('0x2'),'interval'),_0x11caab[_0x9be6e('0x1a')](_0x9be6e('0x6'),_0x9be6e('0x1c'),{'type':_0x5e3808[_0x9be6e('0x1e')](0x14),'allowNull':![],'validate':{'len':[0x1,0x14]}}),_0x11caab['removeColumn']('dashboard_items',_0x9be6e('0x12')),_0x11caab[_0x9be6e('0x21')]('dashboard_items',_0x9be6e('0x1b')),_0x11caab[_0x9be6e('0x19')](_0x9be6e('0x6'),'title',{'type':_0x5e3808[_0x9be6e('0x1e')](0x14),'validate':{'len':[0x0,0x14]}}),_0x11caab[_0x9be6e('0x19')](_0x9be6e('0x6'),'attrs',{'type':_0x5e3808['TEXT'](_0x9be6e('0x17'))}),_0x11caab[_0x9be6e('0x19')](_0x9be6e('0x8'),_0x9be6e('0x15'),{'type':_0x5e3808[_0x9be6e('0x1f')],'defaultValue':![]}),_0x11caab[_0x9be6e('0x19')](_0x9be6e('0xb'),'formSubmitSuccessMessage',{'type':_0x5e3808[_0x9be6e('0x1e')],'defaultValue':_0x9be6e('0x18')}),_0x11caab[_0x9be6e('0x19')](_0x9be6e('0xb'),'formSubmitFailureMessage',{'type':_0x5e3808['STRING'],'defaultValue':'Form\x20submission\x20error'}),_0x11caab['final'](_0x136ee7);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.48.js b/server/migrations/2.0.48.js index 17717cd..dab9b92 100644 --- a/server/migrations/2.0.48.js +++ b/server/migrations/2.0.48.js @@ -1 +1 @@ -const a927_0xb89f=[';\x20TURN\x20server\x20list\x0a','/etc/asterisk/res_stun_monitor.conf','sms_interactions','UPDATE\x20fax_interactions\x20t1,\x20(SELECT\x20FaxInteractionId,\x20MIN(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction\x20FROM\x20fax_messages\x20WHERE\x20FaxInteractionId\x20IS\x20NOT\x20NULL\x20GROUP\x20BY\x20FaxInteractionId)\x20t2\x20SET\x20t1.firstMsgDirection\x20=\x20t2.direction\x20WHERE\x20t1.id\x20=\x20t2.FaxInteractionId;','fax_interactions','settings','enqueue','readFileSync','query','changeColumn','then','Changed\x20column\x20%s\x20in\x20table\x20%s','stringify','info','utf8','sequence','#include\x20\x22stun_xcally.conf\x22','query\x20%s','lodash','turnusername','dropTable','inspect','queryInterface','yes','final','UPDATE\x20users\x20SET\x20rtcp_mux=\x27yes\x27\x20WHERE\x20showWebBar=2','#include\x20\x22stun_xcally.conf\x22\x0a#include\x20\x22turn_xcally.conf\x22\x0a[ice_host_candidates]','STRING','users','firstMsgDirection','finally','addIndex\x20%s\x20%s\x20%s','ENUM','tail','replace','util','catch','exports','prototype','addColumn','[ice_host_candidates]','migration','out','turnpassword','Removed\x20column\x20%s\x20from\x20%s','/etc/asterisk/turn_xcally.conf','../config/logger','UPDATE\x20mail_interactions\x20t1,\x20(SELECT\x20MailInteractionId,\x20MIN(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction\x20FROM\x20mail_messages\x20WHERE\x20MailInteractionId\x20IS\x20NOT\x20NULL\x20GROUP\x20BY\x20MailInteractionId)\x20t2\x20SET\x20t1.firstMsgDirection\x20=\x20t2.direction\x20WHERE\x20t1.id\x20=\x20t2.MailInteractionId;','writeFileSync','addIndex','rtcp_mux','removeColumn','turnaddr','appendFileSync'];(function(_0x4e3e2b,_0xb89feb){const _0x3d7f06=function(_0x15a193){while(--_0x15a193){_0x4e3e2b['push'](_0x4e3e2b['shift']());}};_0x3d7f06(++_0xb89feb);}(a927_0xb89f,0x12a));const a927_0x3d7f=function(_0x4e3e2b,_0xb89feb){_0x4e3e2b=_0x4e3e2b-0x0;let _0x3d7f06=a927_0xb89f[_0x4e3e2b];return _0x3d7f06;};const _0x5c1e0b=a927_0x3d7f;'use strict';const fs=require('fs'),util=require(_0x5c1e0b('0x7')),_=require(_0x5c1e0b('0x2c')),logger=require(_0x5c1e0b('0x12'))(_0x5c1e0b('0xd')),Sequence=function(){};Sequence[_0x5c1e0b('0xa')][_0x5c1e0b('0x20')]=function(_0x15a193){const _0x2a5389=_0x5c1e0b;this[_0x2a5389('0x5')]=this[_0x2a5389('0x5')]?this[_0x2a5389('0x5')][_0x2a5389('0x2')](_0x15a193):_0x15a193();};const Migration=function(_0x488b7b){const _0x307b14=_0x5c1e0b;this[_0x307b14('0x30')]=_0x488b7b,this[_0x307b14('0x29')]=new Sequence();};Migration[_0x5c1e0b('0xa')][_0x5c1e0b('0x23')]=function(_0x194399,_0x33c40a,_0xc4e156){const _0x633c4=_0x5c1e0b,_0x50de86=this;this[_0x633c4('0x29')][_0x633c4('0x20')](function(){const _0x5c6d8f=_0x633c4;return _0x50de86[_0x5c6d8f('0x30')]['changeColumn'](_0x194399,_0x33c40a,_0xc4e156)[_0x5c6d8f('0x24')](function(){const _0x2e48cb=_0x5c6d8f;logger[_0x2e48cb('0x27')](_0x2e48cb('0x25'),_0x33c40a,_0x194399);})['catch'](function(_0xfaab39){const _0x1cb1bd=_0x5c6d8f;logger['info'](JSON[_0x1cb1bd('0x26')](_0xfaab39));});});},Migration[_0x5c1e0b('0xa')][_0x5c1e0b('0xb')]=function(_0x1fed16,_0x4cfb6c,_0x1e49af){const _0x416d66=_0x5c1e0b,_0x5f01e7=this;this[_0x416d66('0x29')][_0x416d66('0x20')](function(){const _0x303b47=_0x416d66;return _0x5f01e7[_0x303b47('0x30')][_0x303b47('0xb')](_0x1fed16,_0x4cfb6c,_0x1e49af)['then'](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x4cfb6c,_0x1fed16);})[_0x303b47('0x8')](function(_0x397447){const _0x4b54ec=_0x303b47;logger['info'](JSON[_0x4b54ec('0x26')](_0x397447));});});},Migration[_0x5c1e0b('0xa')][_0x5c1e0b('0x2e')]=function(_0x19e984){const _0x588a58=_0x5c1e0b,_0x384b4a=this;this[_0x588a58('0x29')]['enqueue'](function(){const _0x506e14=_0x588a58;return _0x384b4a[_0x506e14('0x30')]['dropTable'](_0x19e984,{'force':!![]})['then'](function(){const _0x3eebe9=_0x506e14;logger[_0x3eebe9('0x27')]('table\x20dropped\x20%s',_0x19e984);})[_0x506e14('0x8')](function(_0x104eb9){const _0x2c6bd=_0x506e14;logger[_0x2c6bd('0x27')](JSON[_0x2c6bd('0x26')](_0x104eb9));});});},Migration[_0x5c1e0b('0xa')][_0x5c1e0b('0x15')]=function(_0xa1e025,_0x575b2c,_0x39996b){const _0x3a0bd3=_0x5c1e0b,_0x56ab8f=this;this[_0x3a0bd3('0x29')][_0x3a0bd3('0x20')](function(){const _0x511e11=_0x3a0bd3;return _0x56ab8f['queryInterface'][_0x511e11('0x15')](_0xa1e025,_0x575b2c,{'indexName':_0x39996b})[_0x511e11('0x24')](function(){const _0x1865a4=_0x511e11;logger[_0x1865a4('0x27')](_0x1865a4('0x3'),_0xa1e025,_0x575b2c['join'](','),_0x39996b);})[_0x511e11('0x8')](function(_0x517bbe){const _0x204827=_0x511e11;logger['info'](JSON[_0x204827('0x26')](_0x517bbe));});});},Migration['prototype'][_0x5c1e0b('0x22')]=function(_0xf9c185){const _0x56d589=_0x5c1e0b,_0x384084=this;this['sequence'][_0x56d589('0x20')](function(){const _0x6d3ec0=_0x56d589;return _0x384084[_0x6d3ec0('0x30')]['sequelize'][_0x6d3ec0('0x22')](_0xf9c185)[_0x6d3ec0('0x24')](function(){const _0x17fb9d=_0x6d3ec0;logger[_0x17fb9d('0x27')](_0x17fb9d('0x2b'),_0xf9c185);})['catch'](function(_0x13013e){const _0x51c90a=_0x6d3ec0;logger[_0x51c90a('0x27')](JSON[_0x51c90a('0x26')](_0x13013e));});});},Migration[_0x5c1e0b('0xa')][_0x5c1e0b('0x17')]=function(_0xd2e19d,_0x158c87){const _0x379141=_0x5c1e0b,_0x5b0618=this;this[_0x379141('0x29')][_0x379141('0x20')](function(){const _0x2abdf2=_0x379141;return _0x5b0618['queryInterface']['removeColumn'](_0xd2e19d,_0x158c87)[_0x2abdf2('0x24')](function(){const _0x53cfd5=_0x2abdf2;logger[_0x53cfd5('0x27')](_0x53cfd5('0x10'),_0x158c87,_0xd2e19d);})[_0x2abdf2('0x8')](function(_0x14a34b){const _0x3ed0c2=_0x2abdf2;logger['info'](util[_0x3ed0c2('0x2f')](_0x14a34b,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x5c1e0b('0x32')]=function(_0x1fb4dd){const _0x5b7bc4=_0x5c1e0b;this[_0x5b7bc4('0x29')][_0x5b7bc4('0x20')](function(){return _0x1fb4dd();});},module[_0x5c1e0b('0x9')]={'up':function(_0x53e8e3,_0x5b77a6){return new Promise(function(_0x5a48e5){const _0x4fe195=a927_0x3d7f,_0x3f1ed5=new Migration(_0x53e8e3);_0x3f1ed5[_0x4fe195('0xb')](_0x4fe195('0x1f'),_0x4fe195('0x18'),{'type':_0x5b77a6[_0x4fe195('0x35')]}),_0x3f1ed5[_0x4fe195('0xb')](_0x4fe195('0x1f'),_0x4fe195('0x2d'),{'type':_0x5b77a6['STRING']}),_0x3f1ed5[_0x4fe195('0xb')]('settings',_0x4fe195('0xf'),{'type':_0x5b77a6['STRING']}),_0x3f1ed5[_0x4fe195('0xb')](_0x4fe195('0x0'),_0x4fe195('0x16'),{'type':_0x5b77a6[_0x4fe195('0x4')](_0x4fe195('0x31'),'no'),'defaultValue':'no'}),_0x3f1ed5[_0x4fe195('0x22')](_0x4fe195('0x33')),_0x3f1ed5['addColumn'](_0x4fe195('0x1c'),_0x4fe195('0x1'),{'type':_0x5b77a6[_0x4fe195('0x4')]('in','out'),'defaultValue':'in','allowNull':![]}),_0x3f1ed5['query']('UPDATE\x20sms_interactions\x20t1,\x20(SELECT\x20SmsInteractionId,\x20MIN(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction\x20FROM\x20sms_messages\x20WHERE\x20SmsInteractionId\x20IS\x20NOT\x20NULL\x20GROUP\x20BY\x20SmsInteractionId)\x20t2\x20SET\x20t1.firstMsgDirection\x20=\x20t2.direction\x20WHERE\x20t1.id\x20=\x20t2.SmsInteractionId;'),_0x3f1ed5[_0x4fe195('0xb')]('mail_interactions',_0x4fe195('0x1'),{'type':_0x5b77a6[_0x4fe195('0x4')]('in',_0x4fe195('0xe')),'defaultValue':'in','allowNull':![]}),_0x3f1ed5[_0x4fe195('0x22')](_0x4fe195('0x13')),_0x3f1ed5['addColumn'](_0x4fe195('0x1e'),'firstMsgDirection',{'type':_0x5b77a6[_0x4fe195('0x4')]('in',_0x4fe195('0xe')),'defaultValue':'in','allowNull':![]}),_0x3f1ed5[_0x4fe195('0x22')](_0x4fe195('0x1d'));try{fs['writeFileSync']('/etc/asterisk/stun_xcally.conf',';\x20STUN\x20server\x20list\x0a',{'encoding':'utf8'}),fs[_0x4fe195('0x14')](_0x4fe195('0x11'),_0x4fe195('0x1a'),{'encoding':'utf8'});let _0x51b5a0=fs[_0x4fe195('0x21')]('/etc/asterisk/rtp.conf',{'encoding':_0x4fe195('0x28')});_0x51b5a0=_[_0x4fe195('0x6')](_0x51b5a0,_0x4fe195('0xc'),_0x4fe195('0x34')),fs['writeFileSync']('/etc/asterisk/rtp.conf',_0x51b5a0,{'encoding':_0x4fe195('0x28')}),fs[_0x4fe195('0x19')](_0x4fe195('0x1b'),_0x4fe195('0x2a'),{'encoding':_0x4fe195('0x28')});}catch(_0xf9f9f7){logger['info'](JSON[_0x4fe195('0x26')](_0xf9f9f7));}_0x3f1ed5[_0x4fe195('0x32')](_0x5a48e5);});},'down':function(){}}; \ No newline at end of file +const a927_0x4cad=['sms_interactions','table\x20dropped\x20%s','tail','replace','stringify','../config/logger','query','query\x20%s','fax_interactions','UPDATE\x20users\x20SET\x20rtcp_mux=\x27yes\x27\x20WHERE\x20showWebBar=2','queryInterface','yes','#include\x20\x22stun_xcally.conf\x22','sequelize','utf8','rtcp_mux','turnpassword','addIndex','then','final','/etc/asterisk/turn_xcally.conf','Changed\x20column\x20%s\x20in\x20table\x20%s','Removed\x20column\x20%s\x20from\x20%s','firstMsgDirection','ENUM','appendFileSync','info','addIndex\x20%s\x20%s\x20%s','/etc/asterisk/rtp.conf','finally','util','removeColumn','STRING','UPDATE\x20sms_interactions\x20t1,\x20(SELECT\x20SmsInteractionId,\x20MIN(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction\x20FROM\x20sms_messages\x20WHERE\x20SmsInteractionId\x20IS\x20NOT\x20NULL\x20GROUP\x20BY\x20SmsInteractionId)\x20t2\x20SET\x20t1.firstMsgDirection\x20=\x20t2.direction\x20WHERE\x20t1.id\x20=\x20t2.SmsInteractionId;','addColumn','turnusername','users','catch','out','migration','changeColumn','Added\x20column\x20%s\x20to\x20%s','sequence','settings','UPDATE\x20mail_interactions\x20t1,\x20(SELECT\x20MailInteractionId,\x20MIN(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction\x20FROM\x20mail_messages\x20WHERE\x20MailInteractionId\x20IS\x20NOT\x20NULL\x20GROUP\x20BY\x20MailInteractionId)\x20t2\x20SET\x20t1.firstMsgDirection\x20=\x20t2.direction\x20WHERE\x20t1.id\x20=\x20t2.MailInteractionId;','/etc/asterisk/stun_xcally.conf','exports',';\x20STUN\x20server\x20list\x0a','enqueue','writeFileSync','lodash','prototype','UPDATE\x20fax_interactions\x20t1,\x20(SELECT\x20FaxInteractionId,\x20MIN(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction\x20FROM\x20fax_messages\x20WHERE\x20FaxInteractionId\x20IS\x20NOT\x20NULL\x20GROUP\x20BY\x20FaxInteractionId)\x20t2\x20SET\x20t1.firstMsgDirection\x20=\x20t2.direction\x20WHERE\x20t1.id\x20=\x20t2.FaxInteractionId;','[ice_host_candidates]'];(function(_0x14bde1,_0x4cadc1){const _0x4c4593=function(_0x1ed80f){while(--_0x1ed80f){_0x14bde1['push'](_0x14bde1['shift']());}};_0x4c4593(++_0x4cadc1);}(a927_0x4cad,0xda));const a927_0x4c45=function(_0x14bde1,_0x4cadc1){_0x14bde1=_0x14bde1-0x0;let _0x4c4593=a927_0x4cad[_0x14bde1];return _0x4c4593;};const _0x1b2462=a927_0x4c45;'use strict';const fs=require('fs'),util=require(_0x1b2462('0x1c')),_=require(_0x1b2462('0x30')),logger=require(_0x1b2462('0x3'))(_0x1b2462('0x25')),Sequence=function(){};Sequence[_0x1b2462('0x31')]['enqueue']=function(_0x1ed80f){const _0x32d320=_0x1b2462;this[_0x32d320('0x0')]=this[_0x32d320('0x0')]?this[_0x32d320('0x0')][_0x32d320('0x1b')](_0x1ed80f):_0x1ed80f();};const Migration=function(_0x29fede){const _0x541185=_0x1b2462;this[_0x541185('0x8')]=_0x29fede,this[_0x541185('0x28')]=new Sequence();};Migration[_0x1b2462('0x31')][_0x1b2462('0x26')]=function(_0x512174,_0x5eefef,_0x5db070){const _0x3d533a=_0x1b2462,_0x2f2883=this;this['sequence'][_0x3d533a('0x2e')](function(){const _0x1911d7=_0x3d533a;return _0x2f2883[_0x1911d7('0x8')][_0x1911d7('0x26')](_0x512174,_0x5eefef,_0x5db070)['then'](function(){const _0x201aff=_0x1911d7;logger[_0x201aff('0x18')](_0x201aff('0x13'),_0x5eefef,_0x512174);})[_0x1911d7('0x23')](function(_0x360430){const _0x1f29bd=_0x1911d7;logger[_0x1f29bd('0x18')](JSON[_0x1f29bd('0x2')](_0x360430));});});},Migration['prototype'][_0x1b2462('0x20')]=function(_0x5c9a69,_0x3a5c00,_0xa6a8ab){const _0x3a1cbf=_0x1b2462,_0x27fcb7=this;this[_0x3a1cbf('0x28')][_0x3a1cbf('0x2e')](function(){const _0x5007f9=_0x3a1cbf;return _0x27fcb7[_0x5007f9('0x8')][_0x5007f9('0x20')](_0x5c9a69,_0x3a5c00,_0xa6a8ab)['then'](function(){const _0x2143a9=_0x5007f9;logger['info'](_0x2143a9('0x27'),_0x3a5c00,_0x5c9a69);})[_0x5007f9('0x23')](function(_0x5dad62){const _0x5b0f01=_0x5007f9;logger[_0x5b0f01('0x18')](JSON[_0x5b0f01('0x2')](_0x5dad62));});});},Migration['prototype']['dropTable']=function(_0x20f26b){const _0x296e5b=_0x1b2462,_0x419cab=this;this[_0x296e5b('0x28')][_0x296e5b('0x2e')](function(){const _0xc9e71c=_0x296e5b;return _0x419cab['queryInterface']['dropTable'](_0x20f26b,{'force':!![]})[_0xc9e71c('0x10')](function(){const _0x406de0=_0xc9e71c;logger['info'](_0x406de0('0x35'),_0x20f26b);})['catch'](function(_0x3611aa){const _0x138d2e=_0xc9e71c;logger[_0x138d2e('0x18')](JSON[_0x138d2e('0x2')](_0x3611aa));});});},Migration[_0x1b2462('0x31')][_0x1b2462('0xf')]=function(_0x3d9fa6,_0x34237a,_0x224052){const _0x42a01d=_0x1b2462,_0x5f3ccf=this;this[_0x42a01d('0x28')][_0x42a01d('0x2e')](function(){const _0x1ac912=_0x42a01d;return _0x5f3ccf[_0x1ac912('0x8')][_0x1ac912('0xf')](_0x3d9fa6,_0x34237a,{'indexName':_0x224052})['then'](function(){const _0xc2c0eb=_0x1ac912;logger['info'](_0xc2c0eb('0x19'),_0x3d9fa6,_0x34237a['join'](','),_0x224052);})[_0x1ac912('0x23')](function(_0x52115d){const _0x1c4ea3=_0x1ac912;logger[_0x1c4ea3('0x18')](JSON[_0x1c4ea3('0x2')](_0x52115d));});});},Migration['prototype']['query']=function(_0x33345a){const _0x25c34f=this;this['sequence']['enqueue'](function(){const _0x34a8c7=a927_0x4c45;return _0x25c34f[_0x34a8c7('0x8')][_0x34a8c7('0xb')][_0x34a8c7('0x4')](_0x33345a)[_0x34a8c7('0x10')](function(){const _0x1d8c06=_0x34a8c7;logger[_0x1d8c06('0x18')](_0x1d8c06('0x5'),_0x33345a);})[_0x34a8c7('0x23')](function(_0x10f3d3){const _0x16cead=_0x34a8c7;logger['info'](JSON[_0x16cead('0x2')](_0x10f3d3));});});},Migration['prototype'][_0x1b2462('0x1d')]=function(_0x375ede,_0x1df714){const _0x17f47b=_0x1b2462,_0x56254f=this;this[_0x17f47b('0x28')][_0x17f47b('0x2e')](function(){const _0x531c14=_0x17f47b;return _0x56254f['queryInterface'][_0x531c14('0x1d')](_0x375ede,_0x1df714)[_0x531c14('0x10')](function(){const _0x467f9a=_0x531c14;logger[_0x467f9a('0x18')](_0x467f9a('0x14'),_0x1df714,_0x375ede);})[_0x531c14('0x23')](function(_0x2536bb){const _0x100afd=_0x531c14;logger[_0x100afd('0x18')](util['inspect'](_0x2536bb,{'showHidden':![],'depth':null}));});});},Migration[_0x1b2462('0x31')]['final']=function(_0x475da0){const _0x1daabe=_0x1b2462;this['sequence'][_0x1daabe('0x2e')](function(){return _0x475da0();});},module[_0x1b2462('0x2c')]={'up':function(_0x309957,_0x4f56ce){return new Promise(function(_0x5e8363){const _0x4260fb=a927_0x4c45,_0x2edc12=new Migration(_0x309957);_0x2edc12[_0x4260fb('0x20')](_0x4260fb('0x29'),'turnaddr',{'type':_0x4f56ce[_0x4260fb('0x1e')]}),_0x2edc12[_0x4260fb('0x20')]('settings',_0x4260fb('0x21'),{'type':_0x4f56ce[_0x4260fb('0x1e')]}),_0x2edc12[_0x4260fb('0x20')](_0x4260fb('0x29'),_0x4260fb('0xe'),{'type':_0x4f56ce[_0x4260fb('0x1e')]}),_0x2edc12[_0x4260fb('0x20')](_0x4260fb('0x22'),_0x4260fb('0xd'),{'type':_0x4f56ce['ENUM'](_0x4260fb('0x9'),'no'),'defaultValue':'no'}),_0x2edc12[_0x4260fb('0x4')](_0x4260fb('0x7')),_0x2edc12['addColumn'](_0x4260fb('0x34'),_0x4260fb('0x15'),{'type':_0x4f56ce[_0x4260fb('0x16')]('in',_0x4260fb('0x24')),'defaultValue':'in','allowNull':![]}),_0x2edc12['query'](_0x4260fb('0x1f')),_0x2edc12['addColumn']('mail_interactions',_0x4260fb('0x15'),{'type':_0x4f56ce[_0x4260fb('0x16')]('in',_0x4260fb('0x24')),'defaultValue':'in','allowNull':![]}),_0x2edc12[_0x4260fb('0x4')](_0x4260fb('0x2a')),_0x2edc12[_0x4260fb('0x20')](_0x4260fb('0x6'),'firstMsgDirection',{'type':_0x4f56ce[_0x4260fb('0x16')]('in',_0x4260fb('0x24')),'defaultValue':'in','allowNull':![]}),_0x2edc12[_0x4260fb('0x4')](_0x4260fb('0x32'));try{fs[_0x4260fb('0x2f')](_0x4260fb('0x2b'),_0x4260fb('0x2d'),{'encoding':_0x4260fb('0xc')}),fs[_0x4260fb('0x2f')](_0x4260fb('0x12'),';\x20TURN\x20server\x20list\x0a',{'encoding':_0x4260fb('0xc')});let _0x1ab2c0=fs['readFileSync'](_0x4260fb('0x1a'),{'encoding':'utf8'});_0x1ab2c0=_[_0x4260fb('0x1')](_0x1ab2c0,_0x4260fb('0x33'),'#include\x20\x22stun_xcally.conf\x22\x0a#include\x20\x22turn_xcally.conf\x22\x0a[ice_host_candidates]'),fs[_0x4260fb('0x2f')](_0x4260fb('0x1a'),_0x1ab2c0,{'encoding':_0x4260fb('0xc')}),fs[_0x4260fb('0x17')]('/etc/asterisk/res_stun_monitor.conf',_0x4260fb('0xa'),{'encoding':_0x4260fb('0xc')});}catch(_0x44357d){logger['info'](JSON[_0x4260fb('0x2')](_0x44357d));}_0x2edc12[_0x4260fb('0x11')](_0x5e8363);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.49.js b/server/migrations/2.0.49.js index 6803fc8..efe60e7 100644 --- a/server/migrations/2.0.49.js +++ b/server/migrations/2.0.49.js @@ -1 +1 @@ -const a928_0x14c9=['STRING','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2711\x27,\x20\x27Execif\x27,\x20\x27$[\x22${XMD-AGIAFTER}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGIAFTER})\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','table\x20dropped\x20%s','DATE','../config/logger','exports','finally','dialAgiAfterHangupAgent','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x276\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','addColumn','offlineMessageSubject','queryInterface','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x275\x27,\x20\x27dial\x27,\x20\x27${XMD-DIALCHANNEL},${XMD-DIALTIMEOUT},${XMD-DIALOPTIONS},${XMD-DIALURL}\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','password','voice_queues','inspect','stringify','migration','enqueue','dropTable','query','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2712\x27,\x20\x27Hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20`exten`=\x27xcally-motion-preview\x27\x20AND\x20`priority`=\x205','sms_accounts','addIndex\x20%s\x20%s\x20%s','smsMethod','sequelize','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x274\x27,\x20\x27Execif\x27,\x20\x27$[\x22${XMD-AGI}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGI})\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','allowmessenger','cm_hopper_final','senderString','DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20`exten`=\x27xcally-motion-preview\x27\x20AND\x20`priority`=\x204','sequence','BOOLEAN','DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20`exten`=\x27xcally-motion-dialer\x27\x20AND\x20`priority`=\x2011','offlineMessageBody','changeColumn','phoneBarOutboundProxy','removeColumn','chat_websites','query\x20%s','basic','dialQueueProject2','final','ENUM','catch','prototype','addIndex','Removed\x20column\x20%s\x20from\x20%s','then','info','users','tail','classic+'];(function(_0xbc056c,_0x14c94c){const _0x35cf5b=function(_0x12c1b0){while(--_0x12c1b0){_0xbc056c['push'](_0xbc056c['shift']());}};_0x35cf5b(++_0x14c94c);}(a928_0x14c9,0x1a4));const a928_0x35cf=function(_0xbc056c,_0x14c94c){_0xbc056c=_0xbc056c-0x0;let _0x35cf5b=a928_0x14c9[_0xbc056c];return _0x35cf5b;};const _0x1a9396=a928_0x35cf;'use strict';const util=require('util'),logger=require(_0x1a9396('0x10'))(_0x1a9396('0x1d')),Sequence=function(){};Sequence['prototype'][_0x1a9396('0x1e')]=function(_0x12c1b0){const _0x191bfc=_0x1a9396;this[_0x191bfc('0xa')]=this['tail']?this['tail'][_0x191bfc('0x12')](_0x12c1b0):_0x12c1b0();};const Migration=function(_0x2a05fb){const _0x20ec14=_0x1a9396;this[_0x20ec14('0x17')]=_0x2a05fb,this['sequence']=new Sequence();};Migration['prototype']['changeColumn']=function(_0x552c0b,_0x150168,_0x27c051){const _0x3569c5=_0x1a9396,_0x10e5c8=this;this['sequence'][_0x3569c5('0x1e')](function(){const _0x4f5666=_0x3569c5;return _0x10e5c8[_0x4f5666('0x17')][_0x4f5666('0x30')](_0x552c0b,_0x150168,_0x27c051)[_0x4f5666('0x7')](function(){const _0x595b6f=_0x4f5666;logger[_0x595b6f('0x8')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x150168,_0x552c0b);})[_0x4f5666('0x3')](function(_0x3f1945){const _0x588f60=_0x4f5666;logger[_0x588f60('0x8')](JSON[_0x588f60('0x1c')](_0x3f1945));});});},Migration['prototype'][_0x1a9396('0x15')]=function(_0x4ceaa1,_0x116ee5,_0x397185){const _0x25561d=_0x1a9396,_0x563564=this;this[_0x25561d('0x2c')][_0x25561d('0x1e')](function(){const _0x3a9172=_0x25561d;return _0x563564[_0x3a9172('0x17')][_0x3a9172('0x15')](_0x4ceaa1,_0x116ee5,_0x397185)['then'](function(){const _0x51bad0=_0x3a9172;logger[_0x51bad0('0x8')]('Added\x20column\x20%s\x20to\x20%s',_0x116ee5,_0x4ceaa1);})[_0x3a9172('0x3')](function(_0x37a1dc){const _0x50183f=_0x3a9172;logger[_0x50183f('0x8')](JSON['stringify'](_0x37a1dc));});});},Migration[_0x1a9396('0x4')][_0x1a9396('0x1f')]=function(_0x4811e4){const _0x47f2db=_0x1a9396,_0x582999=this;this[_0x47f2db('0x2c')][_0x47f2db('0x1e')](function(){const _0x1f6a67=_0x47f2db;return _0x582999[_0x1f6a67('0x17')][_0x1f6a67('0x1f')](_0x4811e4,{'force':!![]})[_0x1f6a67('0x7')](function(){const _0x1fbe61=_0x1f6a67;logger['info'](_0x1fbe61('0xe'),_0x4811e4);})[_0x1f6a67('0x3')](function(_0xd69f60){const _0x1a43da=_0x1f6a67;logger[_0x1a43da('0x8')](JSON['stringify'](_0xd69f60));});});},Migration[_0x1a9396('0x4')][_0x1a9396('0x5')]=function(_0x12058b,_0xfce33a,_0x593746){const _0x2cb570=_0x1a9396,_0x354cc5=this;this[_0x2cb570('0x2c')]['enqueue'](function(){const _0x375877=_0x2cb570;return _0x354cc5['queryInterface'][_0x375877('0x5')](_0x12058b,_0xfce33a,{'indexName':_0x593746})[_0x375877('0x7')](function(){const _0x56ad7d=_0x375877;logger[_0x56ad7d('0x8')](_0x56ad7d('0x24'),_0x12058b,_0xfce33a['join'](','),_0x593746);})[_0x375877('0x3')](function(_0x90f398){const _0x31fb61=_0x375877;logger[_0x31fb61('0x8')](JSON[_0x31fb61('0x1c')](_0x90f398));});});},Migration['prototype'][_0x1a9396('0x20')]=function(_0x2d7a90){const _0xa03f8a=_0x1a9396,_0x45d8a8=this;this[_0xa03f8a('0x2c')]['enqueue'](function(){const _0x541182=_0xa03f8a;return _0x45d8a8[_0x541182('0x17')][_0x541182('0x26')][_0x541182('0x20')](_0x2d7a90)[_0x541182('0x7')](function(){const _0x8dd318=_0x541182;logger[_0x8dd318('0x8')](_0x8dd318('0x34'),_0x2d7a90);})[_0x541182('0x3')](function(_0xf7b68e){const _0x3765a9=_0x541182;logger[_0x3765a9('0x8')](JSON[_0x3765a9('0x1c')](_0xf7b68e));});});},Migration[_0x1a9396('0x4')][_0x1a9396('0x32')]=function(_0x16c2a3,_0x25988a){const _0x116473=_0x1a9396,_0x1e7ba7=this;this[_0x116473('0x2c')][_0x116473('0x1e')](function(){const _0x349f23=_0x116473;return _0x1e7ba7[_0x349f23('0x17')][_0x349f23('0x32')](_0x16c2a3,_0x25988a)[_0x349f23('0x7')](function(){const _0x485883=_0x349f23;logger[_0x485883('0x8')](_0x485883('0x6'),_0x25988a,_0x16c2a3);})['catch'](function(_0x295074){const _0x29371d=_0x349f23;logger[_0x29371d('0x8')](util[_0x29371d('0x1b')](_0x295074,{'showHidden':![],'depth':null}));});});},Migration[_0x1a9396('0x4')][_0x1a9396('0x1')]=function(_0x454b18){const _0x56e493=_0x1a9396;this[_0x56e493('0x2c')][_0x56e493('0x1e')](function(){return _0x454b18();});},module[_0x1a9396('0x11')]={'up':function(_0x469f5f,_0x3bad71){return new Promise(function(_0x1244b9){const _0x17c8fa=a928_0x35cf,_0x4debeb=new Migration(_0x469f5f);_0x4debeb[_0x17c8fa('0x15')](_0x17c8fa('0x23'),_0x17c8fa('0x25'),{'type':_0x3bad71[_0x17c8fa('0x2')](_0x17c8fa('0x35'),'classic',_0x17c8fa('0xb'))}),_0x4debeb[_0x17c8fa('0x15')](_0x17c8fa('0x23'),'username',{'type':_0x3bad71['STRING']}),_0x4debeb['addColumn'](_0x17c8fa('0x23'),_0x17c8fa('0x19'),{'type':_0x3bad71[_0x17c8fa('0xc')]}),_0x4debeb[_0x17c8fa('0x15')](_0x17c8fa('0x23'),_0x17c8fa('0x2a'),{'type':_0x3bad71[_0x17c8fa('0xc')]}),_0x4debeb[_0x17c8fa('0x15')](_0x17c8fa('0x23'),'deliveryReport',{'type':_0x3bad71[_0x17c8fa('0x2d')],'defaultValue':![]}),_0x4debeb[_0x17c8fa('0x15')](_0x17c8fa('0x9'),_0x17c8fa('0x28'),{'type':_0x3bad71[_0x17c8fa('0x2d')],'defaultValue':!![]}),_0x4debeb['addColumn'](_0x17c8fa('0x9'),_0x17c8fa('0x31'),{'type':_0x3bad71['STRING']}),_0x4debeb['addColumn'](_0x17c8fa('0x33'),_0x17c8fa('0x16'),{'type':_0x3bad71[_0x17c8fa('0xc')],'defaultValue':'New\x20offline\x20message\x20from\x20websiteName'}),_0x4debeb[_0x17c8fa('0x15')](_0x17c8fa('0x33'),_0x17c8fa('0x2f'),{'type':_0x3bad71[_0x17c8fa('0xc')],'defaultValue':'You\x20received\x20a\x20new\x20offline\x20message\x20from\x20websiteName.\x20Here\x20you\x20can\x20find\x20the\x20details\x20of\x20the\x20request:'}),_0x4debeb[_0x17c8fa('0x15')]('voice_queues',_0x17c8fa('0x0'),{'type':_0x3bad71[_0x17c8fa('0xc')]}),_0x4debeb[_0x17c8fa('0x15')](_0x17c8fa('0x1a'),'dialAgiAfterHangupClient',{'type':_0x3bad71[_0x17c8fa('0x2d')],'defaultValue':![]}),_0x4debeb[_0x17c8fa('0x15')](_0x17c8fa('0x1a'),_0x17c8fa('0x13'),{'type':_0x3bad71['BOOLEAN'],'defaultValue':![]}),_0x4debeb[_0x17c8fa('0x20')](_0x17c8fa('0x2e')),_0x4debeb[_0x17c8fa('0x20')](_0x17c8fa('0xd')),_0x4debeb[_0x17c8fa('0x20')](_0x17c8fa('0x21')),_0x4debeb['query'](_0x17c8fa('0x2b')),_0x4debeb[_0x17c8fa('0x20')](_0x17c8fa('0x22')),_0x4debeb['query'](_0x17c8fa('0x27')),_0x4debeb[_0x17c8fa('0x20')](_0x17c8fa('0x18')),_0x4debeb[_0x17c8fa('0x20')](_0x17c8fa('0x14')),_0x4debeb[_0x17c8fa('0x15')](_0x17c8fa('0x29'),'agiafterat',{'type':_0x3bad71[_0x17c8fa('0xf')]}),_0x4debeb[_0x17c8fa('0x1')](_0x1244b9);});},'down':function(){}}; \ No newline at end of file +const a928_0x2cd1=['migration','sequence','exports','password','table\x20dropped\x20%s','ENUM','finally','queryInterface','then','allowmessenger','phoneBarOutboundProxy','Added\x20column\x20%s\x20to\x20%s','senderString','removeColumn','query\x20%s','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x275\x27,\x20\x27dial\x27,\x20\x27${XMD-DIALCHANNEL},${XMD-DIALTIMEOUT},${XMD-DIALOPTIONS},${XMD-DIALURL}\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','sequelize','catch','util','../config/logger','addColumn','info','enqueue','final','Changed\x20column\x20%s\x20in\x20table\x20%s','addIndex\x20%s\x20%s\x20%s','inspect','dialQueueProject2','offlineMessageBody','tail','BOOLEAN','classic','DATE','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2712\x27,\x20\x27Hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','dialAgiAfterHangupClient','changeColumn','username','cm_hopper_final','New\x20offline\x20message\x20from\x20websiteName','You\x20received\x20a\x20new\x20offline\x20message\x20from\x20websiteName.\x20Here\x20you\x20can\x20find\x20the\x20details\x20of\x20the\x20request:','users','deliveryReport','DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20`exten`=\x27xcally-motion-preview\x27\x20AND\x20`priority`=\x204','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x276\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','stringify','dropTable','query','STRING','addIndex','offlineMessageSubject','prototype','join','chat_websites','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2711\x27,\x20\x27Execif\x27,\x20\x27$[\x22${XMD-AGIAFTER}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGIAFTER})\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','Removed\x20column\x20%s\x20from\x20%s','sms_accounts','voice_queues'];(function(_0x388376,_0x2cd1d3){const _0x4d64d7=function(_0x30b1f4){while(--_0x30b1f4){_0x388376['push'](_0x388376['shift']());}};_0x4d64d7(++_0x2cd1d3);}(a928_0x2cd1,0xc5));const a928_0x4d64=function(_0x388376,_0x2cd1d3){_0x388376=_0x388376-0x0;let _0x4d64d7=a928_0x2cd1[_0x388376];return _0x4d64d7;};const _0x38d869=a928_0x4d64;'use strict';const util=require(_0x38d869('0x31')),logger=require(_0x38d869('0x32'))(_0x38d869('0x1f')),Sequence=function(){};Sequence[_0x38d869('0x18')]['enqueue']=function(_0x30b1f4){const _0x925e42=_0x38d869;this[_0x925e42('0x3')]=this['tail']?this[_0x925e42('0x3')][_0x925e42('0x25')](_0x30b1f4):_0x30b1f4();};const Migration=function(_0x543d83){const _0x48793e=_0x38d869;this['queryInterface']=_0x543d83,this[_0x48793e('0x20')]=new Sequence();};Migration[_0x38d869('0x18')][_0x38d869('0x9')]=function(_0x197977,_0x56339e,_0x2f4b5d){const _0x134fc1=_0x38d869,_0x43f915=this;this[_0x134fc1('0x20')]['enqueue'](function(){const _0xf445c4=_0x134fc1;return _0x43f915[_0xf445c4('0x26')][_0xf445c4('0x9')](_0x197977,_0x56339e,_0x2f4b5d)[_0xf445c4('0x27')](function(){const _0xbb4093=_0xf445c4;logger[_0xbb4093('0x34')](_0xbb4093('0x37'),_0x56339e,_0x197977);})[_0xf445c4('0x30')](function(_0x2212a6){const _0x791623=_0xf445c4;logger[_0x791623('0x34')](JSON['stringify'](_0x2212a6));});});},Migration[_0x38d869('0x18')]['addColumn']=function(_0x5e2387,_0x523389,_0x310031){const _0x47bcf6=_0x38d869,_0x1828aa=this;this[_0x47bcf6('0x20')][_0x47bcf6('0x35')](function(){const _0x73508e=_0x47bcf6;return _0x1828aa[_0x73508e('0x26')][_0x73508e('0x33')](_0x5e2387,_0x523389,_0x310031)[_0x73508e('0x27')](function(){const _0x2399fb=_0x73508e;logger['info'](_0x2399fb('0x2a'),_0x523389,_0x5e2387);})[_0x73508e('0x30')](function(_0x4d19dc){const _0x241bfe=_0x73508e;logger['info'](JSON[_0x241bfe('0x12')](_0x4d19dc));});});},Migration['prototype'][_0x38d869('0x13')]=function(_0x349abf){const _0x4c4af8=_0x38d869,_0x3cfc05=this;this[_0x4c4af8('0x20')]['enqueue'](function(){const _0x4ca7f8=_0x4c4af8;return _0x3cfc05['queryInterface']['dropTable'](_0x349abf,{'force':!![]})[_0x4ca7f8('0x27')](function(){const _0x4815c0=_0x4ca7f8;logger['info'](_0x4815c0('0x23'),_0x349abf);})[_0x4ca7f8('0x30')](function(_0x55c9a8){const _0x268773=_0x4ca7f8;logger[_0x268773('0x34')](JSON['stringify'](_0x55c9a8));});});},Migration[_0x38d869('0x18')][_0x38d869('0x16')]=function(_0x4b6f00,_0x174800,_0x27970e){const _0xdbdb12=_0x38d869,_0x356948=this;this['sequence'][_0xdbdb12('0x35')](function(){const _0x1ee224=_0xdbdb12;return _0x356948[_0x1ee224('0x26')][_0x1ee224('0x16')](_0x4b6f00,_0x174800,{'indexName':_0x27970e})[_0x1ee224('0x27')](function(){const _0xa97b7e=_0x1ee224;logger[_0xa97b7e('0x34')](_0xa97b7e('0x38'),_0x4b6f00,_0x174800[_0xa97b7e('0x19')](','),_0x27970e);})[_0x1ee224('0x30')](function(_0x1582d2){const _0xf5606f=_0x1ee224;logger['info'](JSON[_0xf5606f('0x12')](_0x1582d2));});});},Migration[_0x38d869('0x18')][_0x38d869('0x14')]=function(_0x1d1129){const _0x2d5a75=_0x38d869,_0x5f030c=this;this[_0x2d5a75('0x20')]['enqueue'](function(){const _0x3e0e5e=_0x2d5a75;return _0x5f030c['queryInterface'][_0x3e0e5e('0x2f')]['query'](_0x1d1129)[_0x3e0e5e('0x27')](function(){const _0x2ab4b2=_0x3e0e5e;logger[_0x2ab4b2('0x34')](_0x2ab4b2('0x2d'),_0x1d1129);})[_0x3e0e5e('0x30')](function(_0x51889c){const _0x5d9950=_0x3e0e5e;logger[_0x5d9950('0x34')](JSON['stringify'](_0x51889c));});});},Migration[_0x38d869('0x18')][_0x38d869('0x2c')]=function(_0x197746,_0x2205e8){const _0x1c1c44=_0x38d869,_0x204d67=this;this[_0x1c1c44('0x20')][_0x1c1c44('0x35')](function(){const _0x55b758=_0x1c1c44;return _0x204d67['queryInterface'][_0x55b758('0x2c')](_0x197746,_0x2205e8)['then'](function(){const _0x4639dd=_0x55b758;logger['info'](_0x4639dd('0x1c'),_0x2205e8,_0x197746);})[_0x55b758('0x30')](function(_0x6e9330){const _0x21b99f=_0x55b758;logger[_0x21b99f('0x34')](util[_0x21b99f('0x0')](_0x6e9330,{'showHidden':![],'depth':null}));});});},Migration[_0x38d869('0x18')][_0x38d869('0x36')]=function(_0x333111){const _0x560680=_0x38d869;this[_0x560680('0x20')]['enqueue'](function(){return _0x333111();});},module[_0x38d869('0x21')]={'up':function(_0x5393f4,_0x17921d){return new Promise(function(_0x5430f3){const _0x1352a7=a928_0x4d64,_0x2971ab=new Migration(_0x5393f4);_0x2971ab['addColumn'](_0x1352a7('0x1d'),'smsMethod',{'type':_0x17921d[_0x1352a7('0x24')]('basic',_0x1352a7('0x5'),'classic+')}),_0x2971ab['addColumn'](_0x1352a7('0x1d'),_0x1352a7('0xa'),{'type':_0x17921d[_0x1352a7('0x15')]}),_0x2971ab[_0x1352a7('0x33')](_0x1352a7('0x1d'),_0x1352a7('0x22'),{'type':_0x17921d[_0x1352a7('0x15')]}),_0x2971ab['addColumn'](_0x1352a7('0x1d'),_0x1352a7('0x2b'),{'type':_0x17921d['STRING']}),_0x2971ab[_0x1352a7('0x33')]('sms_accounts',_0x1352a7('0xf'),{'type':_0x17921d['BOOLEAN'],'defaultValue':![]}),_0x2971ab['addColumn'](_0x1352a7('0xe'),_0x1352a7('0x28'),{'type':_0x17921d[_0x1352a7('0x4')],'defaultValue':!![]}),_0x2971ab[_0x1352a7('0x33')]('users',_0x1352a7('0x29'),{'type':_0x17921d[_0x1352a7('0x15')]}),_0x2971ab[_0x1352a7('0x33')](_0x1352a7('0x1a'),_0x1352a7('0x17'),{'type':_0x17921d[_0x1352a7('0x15')],'defaultValue':_0x1352a7('0xc')}),_0x2971ab[_0x1352a7('0x33')]('chat_websites',_0x1352a7('0x2'),{'type':_0x17921d[_0x1352a7('0x15')],'defaultValue':_0x1352a7('0xd')}),_0x2971ab[_0x1352a7('0x33')](_0x1352a7('0x1e'),_0x1352a7('0x1'),{'type':_0x17921d[_0x1352a7('0x15')]}),_0x2971ab[_0x1352a7('0x33')](_0x1352a7('0x1e'),_0x1352a7('0x8'),{'type':_0x17921d[_0x1352a7('0x4')],'defaultValue':![]}),_0x2971ab[_0x1352a7('0x33')]('voice_queues','dialAgiAfterHangupAgent',{'type':_0x17921d['BOOLEAN'],'defaultValue':![]}),_0x2971ab[_0x1352a7('0x14')]('DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20`exten`=\x27xcally-motion-dialer\x27\x20AND\x20`priority`=\x2011'),_0x2971ab['query'](_0x1352a7('0x1b')),_0x2971ab[_0x1352a7('0x14')](_0x1352a7('0x7')),_0x2971ab[_0x1352a7('0x14')](_0x1352a7('0x10')),_0x2971ab[_0x1352a7('0x14')]('DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20`exten`=\x27xcally-motion-preview\x27\x20AND\x20`priority`=\x205'),_0x2971ab[_0x1352a7('0x14')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x274\x27,\x20\x27Execif\x27,\x20\x27$[\x22${XMD-AGI}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGI})\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x2971ab[_0x1352a7('0x14')](_0x1352a7('0x2e')),_0x2971ab[_0x1352a7('0x14')](_0x1352a7('0x11')),_0x2971ab[_0x1352a7('0x33')](_0x1352a7('0xb'),'agiafterat',{'type':_0x17921d[_0x1352a7('0x6')]}),_0x2971ab['final'](_0x5430f3);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.50.js b/server/migrations/2.0.50.js index b475653..79f1925 100644 --- a/server/migrations/2.0.50.js +++ b/server/migrations/2.0.50.js @@ -1 +1 @@ -const a929_0x38e8=['finally','then','DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20`exten`=\x27xcally-motion-preview\x27\x20AND\x20`priority`=\x206','preview','Removed\x20column\x20%s\x20from\x20%s','query\x20%s','queryInterface','addIndex','sms_messages','join','sequence','Added\x20column\x20%s\x20to\x20%s','voice_queues','query','power','../config/logger','inspect','Changed\x20column\x20%s\x20in\x20table\x20%s','dialMethod','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x277\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','dropTable','addIndex\x20%s\x20%s\x20%s','addColumn','enqueue','booked','progressive','info','removeColumn','ENUM','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x276\x27,\x20\x27Execif\x27,\x20\x27$[\x22${XMD-AGIAFTER}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGIAFTER})\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','catch','tail','changeColumn','sequelize','messageId','final','exports','stringify','table\x20dropped\x20%s','prototype'];(function(_0x39ca8f,_0x38e88e){const _0x67369b=function(_0x475f13){while(--_0x475f13){_0x39ca8f['push'](_0x39ca8f['shift']());}};_0x67369b(++_0x38e88e);}(a929_0x38e8,0x193));const a929_0x6736=function(_0x39ca8f,_0x38e88e){_0x39ca8f=_0x39ca8f-0x0;let _0x67369b=a929_0x38e8[_0x39ca8f];return _0x67369b;};const _0x8df0b9=a929_0x6736;'use strict';const util=require('util'),logger=require(_0x8df0b9('0xc'))('migration'),Sequence=function(){};Sequence[_0x8df0b9('0x24')]['enqueue']=function(_0x475f13){const _0x195385=_0x8df0b9;this['tail']=this[_0x195385('0x1c')]?this[_0x195385('0x1c')][_0x195385('0x25')](_0x475f13):_0x475f13();};const Migration=function(_0x19d497){const _0x4afddf=_0x8df0b9;this[_0x4afddf('0x3')]=_0x19d497,this['sequence']=new Sequence();};Migration[_0x8df0b9('0x24')][_0x8df0b9('0x1d')]=function(_0x47cd19,_0x2ab525,_0x23cdfe){const _0x24d7a0=_0x8df0b9,_0x166c8d=this;this['sequence'][_0x24d7a0('0x14')](function(){const _0x5a0cda=_0x24d7a0;return _0x166c8d[_0x5a0cda('0x3')][_0x5a0cda('0x1d')](_0x47cd19,_0x2ab525,_0x23cdfe)[_0x5a0cda('0x26')](function(){const _0x14252d=_0x5a0cda;logger[_0x14252d('0x17')](_0x14252d('0xe'),_0x2ab525,_0x47cd19);})[_0x5a0cda('0x1b')](function(_0x39b983){const _0x5381fe=_0x5a0cda;logger[_0x5381fe('0x17')](JSON[_0x5381fe('0x22')](_0x39b983));});});},Migration[_0x8df0b9('0x24')][_0x8df0b9('0x13')]=function(_0x58c7e1,_0x4e7abe,_0x28994d){const _0x57cac2=_0x8df0b9,_0x26de57=this;this[_0x57cac2('0x7')][_0x57cac2('0x14')](function(){const _0x17d990=_0x57cac2;return _0x26de57['queryInterface']['addColumn'](_0x58c7e1,_0x4e7abe,_0x28994d)[_0x17d990('0x26')](function(){const _0x3d2176=_0x17d990;logger[_0x3d2176('0x17')](_0x3d2176('0x8'),_0x4e7abe,_0x58c7e1);})[_0x17d990('0x1b')](function(_0x307b60){const _0x1018e0=_0x17d990;logger['info'](JSON[_0x1018e0('0x22')](_0x307b60));});});},Migration['prototype'][_0x8df0b9('0x11')]=function(_0x1a4d15){const _0xf8391f=_0x8df0b9,_0x552211=this;this[_0xf8391f('0x7')][_0xf8391f('0x14')](function(){const _0x208298=_0xf8391f;return _0x552211[_0x208298('0x3')]['dropTable'](_0x1a4d15,{'force':!![]})[_0x208298('0x26')](function(){const _0x2fda4b=_0x208298;logger[_0x2fda4b('0x17')](_0x2fda4b('0x23'),_0x1a4d15);})['catch'](function(_0xe73e5a){const _0x1019fa=_0x208298;logger[_0x1019fa('0x17')](JSON['stringify'](_0xe73e5a));});});},Migration[_0x8df0b9('0x24')][_0x8df0b9('0x4')]=function(_0xdd7eb6,_0x8827aa,_0x1ba1e0){const _0x53cffb=_0x8df0b9,_0x4242bd=this;this['sequence'][_0x53cffb('0x14')](function(){const _0x234d29=_0x53cffb;return _0x4242bd['queryInterface'][_0x234d29('0x4')](_0xdd7eb6,_0x8827aa,{'indexName':_0x1ba1e0})['then'](function(){const _0x1672c6=_0x234d29;logger['info'](_0x1672c6('0x12'),_0xdd7eb6,_0x8827aa[_0x1672c6('0x6')](','),_0x1ba1e0);})[_0x234d29('0x1b')](function(_0x26cc49){const _0x5f29d3=_0x234d29;logger[_0x5f29d3('0x17')](JSON[_0x5f29d3('0x22')](_0x26cc49));});});},Migration[_0x8df0b9('0x24')][_0x8df0b9('0xa')]=function(_0x36dac){const _0x36f353=_0x8df0b9,_0x2ec086=this;this[_0x36f353('0x7')][_0x36f353('0x14')](function(){const _0x3ceabf=_0x36f353;return _0x2ec086['queryInterface'][_0x3ceabf('0x1e')][_0x3ceabf('0xa')](_0x36dac)[_0x3ceabf('0x26')](function(){const _0x1ee011=_0x3ceabf;logger[_0x1ee011('0x17')](_0x1ee011('0x2'),_0x36dac);})[_0x3ceabf('0x1b')](function(_0x1497ea){const _0x548923=_0x3ceabf;logger['info'](JSON[_0x548923('0x22')](_0x1497ea));});});},Migration[_0x8df0b9('0x24')][_0x8df0b9('0x18')]=function(_0x2623e8,_0x7c855b){const _0x1f4608=_0x8df0b9,_0x3b4857=this;this[_0x1f4608('0x7')][_0x1f4608('0x14')](function(){const _0x5474c4=_0x1f4608;return _0x3b4857[_0x5474c4('0x3')]['removeColumn'](_0x2623e8,_0x7c855b)['then'](function(){const _0x4d8cd3=_0x5474c4;logger[_0x4d8cd3('0x17')](_0x4d8cd3('0x1'),_0x7c855b,_0x2623e8);})[_0x5474c4('0x1b')](function(_0x33155f){const _0x14ca71=_0x5474c4;logger[_0x14ca71('0x17')](util[_0x14ca71('0xd')](_0x33155f,{'showHidden':![],'depth':null}));});});},Migration[_0x8df0b9('0x24')][_0x8df0b9('0x20')]=function(_0x24cfbc){const _0x2b0a04=_0x8df0b9;this[_0x2b0a04('0x7')]['enqueue'](function(){return _0x24cfbc();});},module[_0x8df0b9('0x21')]={'up':function(_0x41b0a4,_0x4d1990){return new Promise(function(_0x59d346){const _0x3d341c=a929_0x6736,_0x327656=new Migration(_0x41b0a4);_0x327656['changeColumn']('sms_messages',_0x3d341c('0x1f'),{'type':_0x4d1990['STRING'](0xbe)}),_0x327656[_0x3d341c('0x4')](_0x3d341c('0x5'),['messageId'],_0x3d341c('0x1f')),_0x327656['changeColumn'](_0x3d341c('0x9'),_0x3d341c('0xf'),{'type':_0x4d1990[_0x3d341c('0x19')](_0x3d341c('0x0'),'progressive',_0x3d341c('0xb'),'predictive',_0x3d341c('0x15')),'defaultValue':_0x3d341c('0x16')}),_0x327656[_0x3d341c('0xa')](_0x3d341c('0x27')),_0x327656[_0x3d341c('0xa')](_0x3d341c('0x1a')),_0x327656['query'](_0x3d341c('0x10')),_0x327656['final'](_0x59d346);});},'down':function(){}}; \ No newline at end of file +const a929_0x3c04=['table\x20dropped\x20%s','tail','query','power','dropTable','predictive','info','../config/logger','finally','exports','catch','changeColumn','prototype','stringify','util','preview','voice_queues','messageId','Added\x20column\x20%s\x20to\x20%s','sms_messages','then','addColumn','query\x20%s','enqueue','sequence','addIndex','removeColumn','dialMethod','migration','inspect','queryInterface','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x277\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20`exten`=\x27xcally-motion-preview\x27\x20AND\x20`priority`=\x206','final','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-preview\x27,\x20\x276\x27,\x20\x27Execif\x27,\x20\x27$[\x22${XMD-AGIAFTER}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGIAFTER})\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','Removed\x20column\x20%s\x20from\x20%s','STRING','progressive'];(function(_0x18fb79,_0x3c04c4){const _0x3000da=function(_0x1bbdc0){while(--_0x1bbdc0){_0x18fb79['push'](_0x18fb79['shift']());}};_0x3000da(++_0x3c04c4);}(a929_0x3c04,0x15e));const a929_0x3000=function(_0x18fb79,_0x3c04c4){_0x18fb79=_0x18fb79-0x0;let _0x3000da=a929_0x3c04[_0x18fb79];return _0x3000da;};const _0x55c155=a929_0x3000;'use strict';const util=require(_0x55c155('0x6')),logger=require(_0x55c155('0x25'))(_0x55c155('0x14')),Sequence=function(){};Sequence[_0x55c155('0x4')][_0x55c155('0xf')]=function(_0x1bbdc0){const _0x3c5d1b=_0x55c155;this[_0x3c5d1b('0x1f')]=this[_0x3c5d1b('0x1f')]?this[_0x3c5d1b('0x1f')][_0x3c5d1b('0x0')](_0x1bbdc0):_0x1bbdc0();};const Migration=function(_0x17b321){const _0x4ef8b0=_0x55c155;this[_0x4ef8b0('0x16')]=_0x17b321,this['sequence']=new Sequence();};Migration[_0x55c155('0x4')][_0x55c155('0x3')]=function(_0x3d8061,_0x200f6d,_0x173355){const _0x2d6579=_0x55c155,_0x53b909=this;this['sequence'][_0x2d6579('0xf')](function(){const _0x3727f7=_0x2d6579;return _0x53b909[_0x3727f7('0x16')][_0x3727f7('0x3')](_0x3d8061,_0x200f6d,_0x173355)[_0x3727f7('0xc')](function(){const _0x2f5465=_0x3727f7;logger[_0x2f5465('0x24')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x200f6d,_0x3d8061);})['catch'](function(_0x1bec7f){const _0x3179c9=_0x3727f7;logger[_0x3179c9('0x24')](JSON['stringify'](_0x1bec7f));});});},Migration[_0x55c155('0x4')][_0x55c155('0xd')]=function(_0x38b0df,_0x19e1f1,_0x33de17){const _0x10a4df=_0x55c155,_0x12e107=this;this[_0x10a4df('0x10')][_0x10a4df('0xf')](function(){const _0x17a621=_0x10a4df;return _0x12e107['queryInterface'][_0x17a621('0xd')](_0x38b0df,_0x19e1f1,_0x33de17)[_0x17a621('0xc')](function(){const _0x40e8b7=_0x17a621;logger[_0x40e8b7('0x24')](_0x40e8b7('0xa'),_0x19e1f1,_0x38b0df);})['catch'](function(_0x4b6239){const _0x53f843=_0x17a621;logger['info'](JSON[_0x53f843('0x5')](_0x4b6239));});});},Migration['prototype'][_0x55c155('0x22')]=function(_0xda3d8b){const _0x57edd7=_0x55c155,_0x4c63cc=this;this['sequence'][_0x57edd7('0xf')](function(){const _0x10de4c=_0x57edd7;return _0x4c63cc[_0x10de4c('0x16')][_0x10de4c('0x22')](_0xda3d8b,{'force':!![]})[_0x10de4c('0xc')](function(){const _0x29b411=_0x10de4c;logger[_0x29b411('0x24')](_0x29b411('0x1e'),_0xda3d8b);})[_0x10de4c('0x2')](function(_0x30fffd){const _0x53da20=_0x10de4c;logger['info'](JSON[_0x53da20('0x5')](_0x30fffd));});});},Migration['prototype'][_0x55c155('0x11')]=function(_0x123557,_0x254835,_0x46a4fa){const _0x59c35e=_0x55c155,_0x5c1d5f=this;this['sequence'][_0x59c35e('0xf')](function(){const _0x341235=_0x59c35e;return _0x5c1d5f[_0x341235('0x16')][_0x341235('0x11')](_0x123557,_0x254835,{'indexName':_0x46a4fa})[_0x341235('0xc')](function(){const _0x94da46=_0x341235;logger[_0x94da46('0x24')]('addIndex\x20%s\x20%s\x20%s',_0x123557,_0x254835['join'](','),_0x46a4fa);})[_0x341235('0x2')](function(_0x15b477){const _0x27322d=_0x341235;logger[_0x27322d('0x24')](JSON[_0x27322d('0x5')](_0x15b477));});});},Migration[_0x55c155('0x4')][_0x55c155('0x20')]=function(_0x3e5e84){const _0x38fc9f=_0x55c155,_0x3dd8c0=this;this[_0x38fc9f('0x10')][_0x38fc9f('0xf')](function(){const _0x42b49d=_0x38fc9f;return _0x3dd8c0[_0x42b49d('0x16')]['sequelize']['query'](_0x3e5e84)[_0x42b49d('0xc')](function(){const _0x4b073d=_0x42b49d;logger[_0x4b073d('0x24')](_0x4b073d('0xe'),_0x3e5e84);})[_0x42b49d('0x2')](function(_0x194fe7){const _0x565fb8=_0x42b49d;logger[_0x565fb8('0x24')](JSON[_0x565fb8('0x5')](_0x194fe7));});});},Migration[_0x55c155('0x4')][_0x55c155('0x12')]=function(_0x30f9ff,_0x9dfb7d){const _0x2368fb=_0x55c155,_0x52b912=this;this[_0x2368fb('0x10')][_0x2368fb('0xf')](function(){const _0x5bf38e=_0x2368fb;return _0x52b912[_0x5bf38e('0x16')]['removeColumn'](_0x30f9ff,_0x9dfb7d)[_0x5bf38e('0xc')](function(){const _0x13ee0a=_0x5bf38e;logger[_0x13ee0a('0x24')](_0x13ee0a('0x1b'),_0x9dfb7d,_0x30f9ff);})[_0x5bf38e('0x2')](function(_0x4ce4c3){const _0x393392=_0x5bf38e;logger[_0x393392('0x24')](util[_0x393392('0x15')](_0x4ce4c3,{'showHidden':![],'depth':null}));});});},Migration[_0x55c155('0x4')]['final']=function(_0x527019){const _0x16652e=_0x55c155;this[_0x16652e('0x10')]['enqueue'](function(){return _0x527019();});},module[_0x55c155('0x1')]={'up':function(_0x1baf01,_0x57ed8e){return new Promise(function(_0x3e1a42){const _0x2180f4=a929_0x3000,_0x1bf2fe=new Migration(_0x1baf01);_0x1bf2fe[_0x2180f4('0x3')]('sms_messages',_0x2180f4('0x9'),{'type':_0x57ed8e[_0x2180f4('0x1c')](0xbe)}),_0x1bf2fe[_0x2180f4('0x11')](_0x2180f4('0xb'),['messageId'],'messageId'),_0x1bf2fe[_0x2180f4('0x3')](_0x2180f4('0x8'),_0x2180f4('0x13'),{'type':_0x57ed8e['ENUM'](_0x2180f4('0x7'),_0x2180f4('0x1d'),_0x2180f4('0x21'),_0x2180f4('0x23'),'booked'),'defaultValue':_0x2180f4('0x1d')}),_0x1bf2fe[_0x2180f4('0x20')](_0x2180f4('0x18')),_0x1bf2fe[_0x2180f4('0x20')](_0x2180f4('0x1a')),_0x1bf2fe[_0x2180f4('0x20')](_0x2180f4('0x17')),_0x1bf2fe[_0x2180f4('0x19')](_0x3e1a42);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.51.js b/server/migrations/2.0.51.js index 9fc07fe..aefdbbb 100644 --- a/server/migrations/2.0.51.js +++ b/server/migrations/2.0.51.js @@ -1 +1 @@ -const a930_0x1e5a=['chat_interactions','UPDATE\x20users\x20SET\x20permissions=\x27101,102,103,110,104,105,106,107,108,109,100\x27\x20WHERE\x20permissions=\x27101,102,103,104,105,106,107,108,109,100\x27','length','ALTER\x20TABLE\x20`chat_internal_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`chat_internal_messages_ibfk_3`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`ChatGroupId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20chat_groups(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','migration','uniqueid','final','join','ChatGroupId','addColumn','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2711\x27,\x20\x27execif\x27,\x20\x27$[\x22${XMD-AGI}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGI})\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','util','addIndex\x20%s\x20%s\x20%s','dropTable','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2710\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22MACHINE\x22\x20]?14:11\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2714\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','lastMsgAt','addIndex','cm_contacts','inspect','ENUM','UPDATE\x20fax_interactions\x20t1,\x20(SELECT\x20FaxInteractionId,\x20MAX(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction,\x20ANY_VALUE(createdAt)\x20AS\x20createdAt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20fax_messages\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20FaxInteractionId\x20IS\x20NOT\x20NULL\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GROUP\x20BY\x20FaxInteractionId)\x20t2\x20SET\x20t1.lastMsgDirection\x20=\x20t2.direction,\x20t1.lastMsgAt\x20=\x20t2.createdAt\x20WHERE\x20t1.id\x20=\x20t2.FaxInteractionId;','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2713\x27,\x20\x27Execif\x27,\x20\x27$[\x22${XMD-AGIAFTER}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGIAFTER})\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','info','note','_messages\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x277\x27,\x20\x27amd\x27,\x20\x27${XMD-AMDINITIALSILENCE},${XMD-AMDGREETING},${XMD-AMDAFTERGREETINGSILENCE},${XMD-AMDTOTALANALYSISTIME},${XMD-AMDMINWORDLENGTH},${XMD-AMDBETWEENWORDSSILENCE},${XMD-AMDMAXIMUMNUMBEROFWORDS},${XMD-AMDSILENCETHRESHOLD},${XMD-AMDMAXIMUMWORDLENGTH}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','INTEGER','table\x20dropped\x20%s','out','changeColumn','openchannel_interactions','InteractionId)\x20t2\x20SET\x20t1.lastMsgDirection\x20=\x20t2.direction,\x20t1.lastMsgAt\x20=\x20t2.createdAt\x20WHERE\x20t1.id\x20=\x20t2.','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x276\x27,\x20\x27background\x27,\x20\x27silence/1\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','phone','Changed\x20column\x20%s\x20in\x20table\x20%s','connectel','enqueue','DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20exten\x20=\x20\x27xcally-motion-dialer\x27;','DATE','toLowerCase','then','fax_interactions','sequence','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x273\x27,\x20\x27set\x27,\x20\x27CALLERID(all)=${XMD-CALLERID}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','finally','type','Mail','ChatInternalMessageId','chat_internal_messages','InteractionId;','lastMsgDirection','report_member','stringify','membername_interface','STRING','Chat','cm_hopper_final','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','query\x20%s','twilio','query','sms_interactions','UPDATE\x20','sms_accounts','Sms','prototype','exports','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2712\x27,\x20\x27execif\x27,\x20\x27$[\x22${XMD-QUEUE}\x22\x20!=\x20\x22NONE\x22\x20]?QUEUE(${XMD-QUEUE})\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','tail','mail_interactions','interface','../config/logger','queryInterface','Openchannel','cm_hopper_history','catch','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x279\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22NOTSURE\x22\x20]?11:10\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','sequelize'];(function(_0x7e32d1,_0x1e5a07){const _0x574bb4=function(_0x2e7acd){while(--_0x2e7acd){_0x7e32d1['push'](_0x7e32d1['shift']());}};_0x574bb4(++_0x1e5a07);}(a930_0x1e5a,0x1ae));const a930_0x574b=function(_0x7e32d1,_0x1e5a07){_0x7e32d1=_0x7e32d1-0x0;let _0x574bb4=a930_0x1e5a[_0x7e32d1];return _0x574bb4;};const _0x20fb2e=a930_0x574b;'use strict';const util=require(_0x20fb2e('0x37')),logger=require(_0x20fb2e('0x25'))(_0x20fb2e('0x30')),Sequence=function(){};Sequence['prototype'][_0x20fb2e('0x2')]=function(_0x2e7acd){const _0x193b65=_0x20fb2e;this[_0x193b65('0x22')]=this['tail']?this[_0x193b65('0x22')][_0x193b65('0xa')](_0x2e7acd):_0x2e7acd();};const Migration=function(_0x49183c){const _0x5a3f2f=_0x20fb2e;this[_0x5a3f2f('0x26')]=_0x49183c,this[_0x5a3f2f('0x8')]=new Sequence();};Migration[_0x20fb2e('0x1f')][_0x20fb2e('0x4a')]=function(_0x44d024,_0x268e2f,_0x22e908){const _0x4e0413=_0x20fb2e,_0x227dc6=this;this[_0x4e0413('0x8')][_0x4e0413('0x2')](function(){const _0x3ccf6d=_0x4e0413;return _0x227dc6[_0x3ccf6d('0x26')][_0x3ccf6d('0x4a')](_0x44d024,_0x268e2f,_0x22e908)[_0x3ccf6d('0x6')](function(){const _0x26102c=_0x3ccf6d;logger[_0x26102c('0x43')](_0x26102c('0x0'),_0x268e2f,_0x44d024);})[_0x3ccf6d('0x29')](function(_0x402dc9){const _0x2dddf5=_0x3ccf6d;logger[_0x2dddf5('0x43')](JSON[_0x2dddf5('0x12')](_0x402dc9));});});},Migration[_0x20fb2e('0x1f')]['addColumn']=function(_0x47685b,_0x301ec6,_0x139776){const _0x3ebab3=_0x20fb2e,_0x363e10=this;this[_0x3ebab3('0x8')]['enqueue'](function(){const _0x522042=_0x3ebab3;return _0x363e10[_0x522042('0x26')][_0x522042('0x35')](_0x47685b,_0x301ec6,_0x139776)[_0x522042('0x6')](function(){const _0x26ab84=_0x522042;logger[_0x26ab84('0x43')]('Added\x20column\x20%s\x20to\x20%s',_0x301ec6,_0x47685b);})['catch'](function(_0x3fa740){const _0x46505a=_0x522042;logger[_0x46505a('0x43')](JSON[_0x46505a('0x12')](_0x3fa740));});});},Migration[_0x20fb2e('0x1f')]['dropTable']=function(_0x147278){const _0x3a8c24=_0x20fb2e,_0x291fd3=this;this[_0x3a8c24('0x8')][_0x3a8c24('0x2')](function(){const _0xd5b2f5=_0x3a8c24;return _0x291fd3[_0xd5b2f5('0x26')][_0xd5b2f5('0x39')](_0x147278,{'force':!![]})[_0xd5b2f5('0x6')](function(){const _0x31da27=_0xd5b2f5;logger[_0x31da27('0x43')](_0x31da27('0x48'),_0x147278);})['catch'](function(_0x51bddc){const _0x2b92f0=_0xd5b2f5;logger[_0x2b92f0('0x43')](JSON[_0x2b92f0('0x12')](_0x51bddc));});});},Migration['prototype'][_0x20fb2e('0x3d')]=function(_0x1a1b72,_0x4388b7,_0x299f52){const _0xa7bc25=_0x20fb2e,_0x2fb171=this;this[_0xa7bc25('0x8')][_0xa7bc25('0x2')](function(){const _0x54d74a=_0xa7bc25;return _0x2fb171[_0x54d74a('0x26')][_0x54d74a('0x3d')](_0x1a1b72,_0x4388b7,{'indexName':_0x299f52})[_0x54d74a('0x6')](function(){const _0x4e5bba=_0x54d74a;logger[_0x4e5bba('0x43')](_0x4e5bba('0x38'),_0x1a1b72,_0x4388b7[_0x4e5bba('0x33')](','),_0x299f52);})[_0x54d74a('0x29')](function(_0x3cf778){const _0x4fcda7=_0x54d74a;logger['info'](JSON[_0x4fcda7('0x12')](_0x3cf778));});});},Migration[_0x20fb2e('0x1f')][_0x20fb2e('0x1a')]=function(_0x3438dd){const _0x46c98c=_0x20fb2e,_0x10fe64=this;this[_0x46c98c('0x8')][_0x46c98c('0x2')](function(){const _0x4fb2e0=_0x46c98c;return _0x10fe64[_0x4fb2e0('0x26')][_0x4fb2e0('0x2b')][_0x4fb2e0('0x1a')](_0x3438dd)[_0x4fb2e0('0x6')](function(){const _0x5c7ba6=_0x4fb2e0;logger[_0x5c7ba6('0x43')](_0x5c7ba6('0x18'),_0x3438dd);})[_0x4fb2e0('0x29')](function(_0x172216){const _0x27513b=_0x4fb2e0;logger[_0x27513b('0x43')](JSON[_0x27513b('0x12')](_0x172216));});});},Migration[_0x20fb2e('0x1f')]['removeColumn']=function(_0x3e88a2,_0x3ae599){const _0x35bab3=_0x20fb2e,_0xfcab6f=this;this['sequence'][_0x35bab3('0x2')](function(){const _0x1bfc2e=_0x35bab3;return _0xfcab6f[_0x1bfc2e('0x26')]['removeColumn'](_0x3e88a2,_0x3ae599)[_0x1bfc2e('0x6')](function(){const _0x335c41=_0x1bfc2e;logger[_0x335c41('0x43')]('Removed\x20column\x20%s\x20from\x20%s',_0x3ae599,_0x3e88a2);})[_0x1bfc2e('0x29')](function(_0x552f30){const _0x34dbb3=_0x1bfc2e;logger[_0x34dbb3('0x43')](util[_0x34dbb3('0x3f')](_0x552f30,{'showHidden':![],'depth':null}));});});},Migration[_0x20fb2e('0x1f')][_0x20fb2e('0x32')]=function(_0x5bf3da){const _0xb7eec7=_0x20fb2e;this[_0xb7eec7('0x8')]['enqueue'](function(){return _0x5bf3da();});},module[_0x20fb2e('0x20')]={'up':function(_0xed434c,_0x3e7762){return new Promise(function(_0x4242c2){const _0x41bef8=a930_0x574b,_0x2f2df0=new Migration(_0xed434c);_0x2f2df0[_0x41bef8('0x35')](_0x41bef8('0xe'),_0x41bef8('0xd'),{'type':_0x3e7762[_0x41bef8('0x47')]}),_0x2f2df0['addColumn'](_0x41bef8('0xe'),_0x41bef8('0x34'),{'type':_0x3e7762[_0x41bef8('0x47')]}),_0x2f2df0[_0x41bef8('0x1a')](_0x41bef8('0x2f')),_0x2f2df0['addColumn'](_0x41bef8('0x2c'),_0x41bef8('0x10'),{'type':_0x3e7762[_0x41bef8('0x40')]('in',_0x41bef8('0x49')),'defaultValue':'in','allowNull':![]}),_0x2f2df0['addColumn'](_0x41bef8('0x2c'),'lastMsgAt',{'type':_0x3e7762[_0x41bef8('0x4')]}),_0x2f2df0[_0x41bef8('0x35')](_0x41bef8('0x23'),'lastMsgDirection',{'type':_0x3e7762['ENUM']('in','out'),'defaultValue':'in','allowNull':![]}),_0x2f2df0['addColumn'](_0x41bef8('0x23'),_0x41bef8('0x3c'),{'type':_0x3e7762[_0x41bef8('0x4')]}),_0x2f2df0['addColumn']('sms_interactions','lastMsgDirection',{'type':_0x3e7762[_0x41bef8('0x40')]('in',_0x41bef8('0x49')),'defaultValue':'in','allowNull':![]}),_0x2f2df0[_0x41bef8('0x35')](_0x41bef8('0x1b'),'lastMsgAt',{'type':_0x3e7762[_0x41bef8('0x4')]}),_0x2f2df0[_0x41bef8('0x35')](_0x41bef8('0x4b'),_0x41bef8('0x10'),{'type':_0x3e7762['ENUM']('in',_0x41bef8('0x49')),'defaultValue':'in','allowNull':![]}),_0x2f2df0[_0x41bef8('0x35')](_0x41bef8('0x4b'),_0x41bef8('0x3c'),{'type':_0x3e7762['DATE']}),_0x2f2df0[_0x41bef8('0x35')](_0x41bef8('0x7'),'lastMsgDirection',{'type':_0x3e7762['ENUM']('in',_0x41bef8('0x49')),'defaultValue':'in','allowNull':![]}),_0x2f2df0[_0x41bef8('0x35')](_0x41bef8('0x7'),_0x41bef8('0x3c'),{'type':_0x3e7762[_0x41bef8('0x4')]});const _0x479d10=[_0x41bef8('0x15'),_0x41bef8('0xc'),_0x41bef8('0x1e'),_0x41bef8('0x27')];for(let _0x6f4215=0x0;_0x6f4215<_0x479d10[_0x41bef8('0x2e')];_0x6f4215++){_0x2f2df0[_0x41bef8('0x1a')](_0x41bef8('0x1c')+_0x479d10[_0x6f4215]['toLowerCase']()+'_interactions\x20t1,\x20(SELECT\x20'+_0x479d10[_0x6f4215]+'InteractionId,\x20MAX(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction,\x20ANY_VALUE(createdAt)\x20AS\x20createdAt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20'+_0x479d10[_0x6f4215][_0x41bef8('0x5')]()+_0x41bef8('0x45')+_0x479d10[_0x6f4215]+'InteractionId\x20IS\x20NOT\x20NULL\x20AND\x20(direction=\x27in\x27\x20OR\x20(direction=\x27out\x27\x20AND\x20secret=0\x20AND\x20UserId\x20IS\x20NOT\x20NULL))\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GROUP\x20BY\x20'+_0x479d10[_0x6f4215]+_0x41bef8('0x4c')+_0x479d10[_0x6f4215]+_0x41bef8('0xf'));}_0x2f2df0['query'](_0x41bef8('0x41')),_0x2f2df0[_0x41bef8('0x4a')](_0x41bef8('0x1d'),_0x41bef8('0xb'),{'type':_0x3e7762[_0x41bef8('0x40')](_0x41bef8('0x19'),'skebby',_0x41bef8('0x1'))}),_0x2f2df0['addColumn']('report_call',_0x41bef8('0x44'),{'type':_0x3e7762[_0x41bef8('0x14')]}),_0x2f2df0[_0x41bef8('0x3d')](_0x41bef8('0x3e'),[_0x41bef8('0x4e')],_0x41bef8('0x4e')),_0x2f2df0['addIndex'](_0x41bef8('0x16'),['uniqueid'],_0x41bef8('0x31')),_0x2f2df0[_0x41bef8('0x3d')](_0x41bef8('0x28'),[_0x41bef8('0x31')],_0x41bef8('0x31')),_0x2f2df0['addIndex']('voice_recordings',[_0x41bef8('0x31')],'uniqueid'),_0x2f2df0[_0x41bef8('0x3d')](_0x41bef8('0x11'),['membername',_0x41bef8('0x24')],_0x41bef8('0x13')),_0x2f2df0[_0x41bef8('0x1a')](_0x41bef8('0x2d')),_0x2f2df0[_0x41bef8('0x1a')](_0x41bef8('0x3')),_0x2f2df0[_0x41bef8('0x1a')](_0x41bef8('0x17')),_0x2f2df0[_0x41bef8('0x1a')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x272\x27,\x20\x27set\x27,\x20\x27CDR(type)=dialer\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x2f2df0['query'](_0x41bef8('0x9')),_0x2f2df0['query']('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x274\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${XMD-AMD}\x22\x20!=\x20\x22NONE\x22\x20]?5:11\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x2f2df0[_0x41bef8('0x1a')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x275\x27,\x20\x27answer\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x2f2df0[_0x41bef8('0x1a')](_0x41bef8('0x4d')),_0x2f2df0['query'](_0x41bef8('0x46')),_0x2f2df0['query']('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x278\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22HUMAN\x22\x20]?11:9\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x2f2df0['query'](_0x41bef8('0x2a')),_0x2f2df0[_0x41bef8('0x1a')](_0x41bef8('0x3a')),_0x2f2df0['query'](_0x41bef8('0x36')),_0x2f2df0[_0x41bef8('0x1a')](_0x41bef8('0x21')),_0x2f2df0['query'](_0x41bef8('0x42')),_0x2f2df0[_0x41bef8('0x1a')](_0x41bef8('0x3b')),_0x2f2df0['final'](_0x4242c2);});},'down':function(){}}; \ No newline at end of file +const a930_0x47c6=['sms_interactions','migration','ENUM','InteractionId\x20IS\x20NOT\x20NULL\x20AND\x20(direction=\x27in\x27\x20OR\x20(direction=\x27out\x27\x20AND\x20secret=0\x20AND\x20UserId\x20IS\x20NOT\x20NULL))\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GROUP\x20BY\x20','note','stringify','connectel','exports','toLowerCase','then','sequence','prototype','util','table\x20dropped\x20%s','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x273\x27,\x20\x27set\x27,\x20\x27CALLERID(all)=${XMD-CALLERID}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','report_call','sms_accounts','INTEGER','addColumn','info','sequelize','inspect','openchannel_interactions','membername','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x275\x27,\x20\x27answer\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x274\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${XMD-AMD}\x22\x20!=\x20\x22NONE\x22\x20]?5:11\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','interface','catch','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x271\x27,\x20\x27NoOp\x27,\x20\x27\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','STRING','twilio','tail','mail_interactions','cm_hopper_history','membername_interface','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x279\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22NOTSURE\x22\x20]?11:10\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','queryInterface','addIndex','../config/logger','chat_internal_messages','finally','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x277\x27,\x20\x27amd\x27,\x20\x27${XMD-AMDINITIALSILENCE},${XMD-AMDGREETING},${XMD-AMDAFTERGREETINGSILENCE},${XMD-AMDTOTALANALYSISTIME},${XMD-AMDMINWORDLENGTH},${XMD-AMDBETWEENWORDSSILENCE},${XMD-AMDMAXIMUMNUMBEROFWORDS},${XMD-AMDSILENCETHRESHOLD},${XMD-AMDMAXIMUMWORDLENGTH}\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','ALTER\x20TABLE\x20`chat_internal_messages`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`chat_internal_messages_ibfk_3`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`ChatGroupId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20chat_groups(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','Removed\x20column\x20%s\x20from\x20%s','_interactions\x20t1,\x20(SELECT\x20','DELETE\x20FROM\x20`voice_extensions`\x20WHERE\x20exten\x20=\x20\x27xcally-motion-dialer\x27;','UPDATE\x20fax_interactions\x20t1,\x20(SELECT\x20FaxInteractionId,\x20MAX(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction,\x20ANY_VALUE(createdAt)\x20AS\x20createdAt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20fax_messages\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20FaxInteractionId\x20IS\x20NOT\x20NULL\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GROUP\x20BY\x20FaxInteractionId)\x20t2\x20SET\x20t1.lastMsgDirection\x20=\x20t2.direction,\x20t1.lastMsgAt\x20=\x20t2.createdAt\x20WHERE\x20t1.id\x20=\x20t2.FaxInteractionId;','_messages\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20','Openchannel','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2711\x27,\x20\x27execif\x27,\x20\x27$[\x22${XMD-AGI}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGI})\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','Added\x20column\x20%s\x20to\x20%s','lastMsgAt','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x272\x27,\x20\x27set\x27,\x20\x27CDR(type)=dialer\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2712\x27,\x20\x27execif\x27,\x20\x27$[\x22${XMD-QUEUE}\x22\x20!=\x20\x22NONE\x22\x20]?QUEUE(${XMD-QUEUE})\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','Changed\x20column\x20%s\x20in\x20table\x20%s','report_member','changeColumn','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2710\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22MACHINE\x22\x20]?14:11\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','UPDATE\x20','chat_interactions','lastMsgDirection','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2713\x27,\x20\x27Execif\x27,\x20\x27$[\x22${XMD-AGIAFTER}\x22\x20!=\x20\x22NONE\x22\x20]?AGI(${XMD-AGIAFTER})\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x276\x27,\x20\x27background\x27,\x20\x27silence/1\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','UPDATE\x20users\x20SET\x20permissions=\x27101,102,103,110,104,105,106,107,108,109,100\x27\x20WHERE\x20permissions=\x27101,102,103,104,105,106,107,108,109,100\x27','enqueue','InteractionId)\x20t2\x20SET\x20t1.lastMsgDirection\x20=\x20t2.direction,\x20t1.lastMsgAt\x20=\x20t2.createdAt\x20WHERE\x20t1.id\x20=\x20t2.','uniqueid','cm_contacts','phone','dropTable','INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`appdata`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x278\x27,\x20\x27gotoif\x27,\x20\x27$[\x22${AMDSTATUS}\x22\x20==\x20\x22HUMAN\x22\x20]?11:9\x27,\x20\x27system\x27,\x20\x27Dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());','query','InteractionId,\x20MAX(id)\x20AS\x20messageid,\x20ANY_VALUE(direction)\x20AS\x20direction,\x20ANY_VALUE(createdAt)\x20AS\x20createdAt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20','type','DATE','out','final','removeColumn','skebby'];(function(_0x309ff6,_0x47c66e){const _0x4cb651=function(_0x4c12cf){while(--_0x4c12cf){_0x309ff6['push'](_0x309ff6['shift']());}};_0x4cb651(++_0x47c66e);}(a930_0x47c6,0x1a5));const a930_0x4cb6=function(_0x309ff6,_0x47c66e){_0x309ff6=_0x309ff6-0x0;let _0x4cb651=a930_0x47c6[_0x309ff6];return _0x4cb651;};const _0x4037a9=a930_0x4cb6;'use strict';const util=require(_0x4037a9('0x41')),logger=require(_0x4037a9('0xc'))(_0x4037a9('0x36')),Sequence=function(){};Sequence[_0x4037a9('0x40')][_0x4037a9('0x26')]=function(_0x4c12cf){const _0x2c743a=_0x4037a9;this[_0x2c743a('0x5')]=this[_0x2c743a('0x5')]?this[_0x2c743a('0x5')][_0x2c743a('0xe')](_0x4c12cf):_0x4c12cf();};const Migration=function(_0x431640){const _0x532b5f=_0x4037a9;this[_0x532b5f('0xa')]=_0x431640,this[_0x532b5f('0x3f')]=new Sequence();};Migration[_0x4037a9('0x40')][_0x4037a9('0x1e')]=function(_0x1dd017,_0x485fd3,_0x5a5862){const _0x11ba33=_0x4037a9,_0x9ef653=this;this[_0x11ba33('0x3f')]['enqueue'](function(){const _0x3252cd=_0x11ba33;return _0x9ef653[_0x3252cd('0xa')][_0x3252cd('0x1e')](_0x1dd017,_0x485fd3,_0x5a5862)[_0x3252cd('0x3e')](function(){const _0x205a64=_0x3252cd;logger[_0x205a64('0x48')](_0x205a64('0x1c'),_0x485fd3,_0x1dd017);})[_0x3252cd('0x1')](function(_0x504cfd){const _0x27d218=_0x3252cd;logger[_0x27d218('0x48')](JSON[_0x27d218('0x3a')](_0x504cfd));});});},Migration[_0x4037a9('0x40')]['addColumn']=function(_0x219cd1,_0x4b3803,_0x37a78d){const _0x157438=_0x4037a9,_0x2f7f52=this;this['sequence'][_0x157438('0x26')](function(){const _0x3f4c43=_0x157438;return _0x2f7f52[_0x3f4c43('0xa')][_0x3f4c43('0x47')](_0x219cd1,_0x4b3803,_0x37a78d)[_0x3f4c43('0x3e')](function(){const _0xa07e70=_0x3f4c43;logger[_0xa07e70('0x48')](_0xa07e70('0x18'),_0x4b3803,_0x219cd1);})[_0x3f4c43('0x1')](function(_0x32463c){const _0x1fbad8=_0x3f4c43;logger[_0x1fbad8('0x48')](JSON[_0x1fbad8('0x3a')](_0x32463c));});});},Migration[_0x4037a9('0x40')][_0x4037a9('0x2b')]=function(_0x2982fc){const _0x5c2d77=_0x4037a9,_0x507195=this;this[_0x5c2d77('0x3f')][_0x5c2d77('0x26')](function(){const _0x3f89c6=_0x5c2d77;return _0x507195[_0x3f89c6('0xa')][_0x3f89c6('0x2b')](_0x2982fc,{'force':!![]})[_0x3f89c6('0x3e')](function(){const _0x29422c=_0x3f89c6;logger[_0x29422c('0x48')](_0x29422c('0x42'),_0x2982fc);})[_0x3f89c6('0x1')](function(_0x4e2a0b){const _0x57ef7e=_0x3f89c6;logger[_0x57ef7e('0x48')](JSON['stringify'](_0x4e2a0b));});});},Migration[_0x4037a9('0x40')][_0x4037a9('0xb')]=function(_0x57e955,_0x3da5b9,_0x5921bd){const _0x56e9f5=_0x4037a9,_0x4333c3=this;this[_0x56e9f5('0x3f')][_0x56e9f5('0x26')](function(){const _0x34039e=_0x56e9f5;return _0x4333c3[_0x34039e('0xa')][_0x34039e('0xb')](_0x57e955,_0x3da5b9,{'indexName':_0x5921bd})[_0x34039e('0x3e')](function(){const _0x486462=_0x34039e;logger[_0x486462('0x48')]('addIndex\x20%s\x20%s\x20%s',_0x57e955,_0x3da5b9['join'](','),_0x5921bd);})['catch'](function(_0x53d34e){const _0x46b8e5=_0x34039e;logger[_0x46b8e5('0x48')](JSON[_0x46b8e5('0x3a')](_0x53d34e));});});},Migration[_0x4037a9('0x40')][_0x4037a9('0x2d')]=function(_0x282c1b){const _0x13ca82=_0x4037a9,_0x1d0856=this;this[_0x13ca82('0x3f')][_0x13ca82('0x26')](function(){const _0xbc9deb=_0x13ca82;return _0x1d0856[_0xbc9deb('0xa')][_0xbc9deb('0x49')][_0xbc9deb('0x2d')](_0x282c1b)['then'](function(){logger['info']('query\x20%s',_0x282c1b);})['catch'](function(_0x583512){logger['info'](JSON['stringify'](_0x583512));});});},Migration[_0x4037a9('0x40')][_0x4037a9('0x33')]=function(_0x2d1598,_0x4a8e44){const _0x5697a4=_0x4037a9,_0x3f2e88=this;this[_0x5697a4('0x3f')][_0x5697a4('0x26')](function(){const _0x5c0386=_0x5697a4;return _0x3f2e88['queryInterface'][_0x5c0386('0x33')](_0x2d1598,_0x4a8e44)[_0x5c0386('0x3e')](function(){const _0x589327=_0x5c0386;logger['info'](_0x589327('0x11'),_0x4a8e44,_0x2d1598);})[_0x5c0386('0x1')](function(_0x788fc7){const _0x1e429a=_0x5c0386;logger[_0x1e429a('0x48')](util[_0x1e429a('0x4a')](_0x788fc7,{'showHidden':![],'depth':null}));});});},Migration[_0x4037a9('0x40')][_0x4037a9('0x32')]=function(_0x57acea){const _0x1d19f5=_0x4037a9;this[_0x1d19f5('0x3f')]['enqueue'](function(){return _0x57acea();});},module[_0x4037a9('0x3c')]={'up':function(_0x32d368,_0x5c124c){return new Promise(function(_0x542a26){const _0x9e08f0=a930_0x4cb6,_0x16258c=new Migration(_0x32d368);_0x16258c[_0x9e08f0('0x47')](_0x9e08f0('0xd'),'ChatInternalMessageId',{'type':_0x5c124c[_0x9e08f0('0x46')]}),_0x16258c[_0x9e08f0('0x47')](_0x9e08f0('0xd'),'ChatGroupId',{'type':_0x5c124c[_0x9e08f0('0x46')]}),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x10')),_0x16258c[_0x9e08f0('0x47')](_0x9e08f0('0x21'),_0x9e08f0('0x22'),{'type':_0x5c124c[_0x9e08f0('0x37')]('in',_0x9e08f0('0x31')),'defaultValue':'in','allowNull':![]}),_0x16258c[_0x9e08f0('0x47')]('chat_interactions',_0x9e08f0('0x19'),{'type':_0x5c124c[_0x9e08f0('0x30')]}),_0x16258c['addColumn'](_0x9e08f0('0x6'),_0x9e08f0('0x22'),{'type':_0x5c124c[_0x9e08f0('0x37')]('in',_0x9e08f0('0x31')),'defaultValue':'in','allowNull':![]}),_0x16258c[_0x9e08f0('0x47')](_0x9e08f0('0x6'),_0x9e08f0('0x19'),{'type':_0x5c124c[_0x9e08f0('0x30')]}),_0x16258c[_0x9e08f0('0x47')](_0x9e08f0('0x35'),_0x9e08f0('0x22'),{'type':_0x5c124c[_0x9e08f0('0x37')]('in',_0x9e08f0('0x31')),'defaultValue':'in','allowNull':![]}),_0x16258c['addColumn'](_0x9e08f0('0x35'),_0x9e08f0('0x19'),{'type':_0x5c124c[_0x9e08f0('0x30')]}),_0x16258c[_0x9e08f0('0x47')](_0x9e08f0('0x4b'),'lastMsgDirection',{'type':_0x5c124c[_0x9e08f0('0x37')]('in',_0x9e08f0('0x31')),'defaultValue':'in','allowNull':![]}),_0x16258c[_0x9e08f0('0x47')](_0x9e08f0('0x4b'),_0x9e08f0('0x19'),{'type':_0x5c124c[_0x9e08f0('0x30')]}),_0x16258c[_0x9e08f0('0x47')]('fax_interactions',_0x9e08f0('0x22'),{'type':_0x5c124c[_0x9e08f0('0x37')]('in','out'),'defaultValue':'in','allowNull':![]}),_0x16258c[_0x9e08f0('0x47')]('fax_interactions',_0x9e08f0('0x19'),{'type':_0x5c124c[_0x9e08f0('0x30')]});const _0x5cb951=['Chat','Mail','Sms',_0x9e08f0('0x16')];for(let _0x35e60e=0x0;_0x35e60e<_0x5cb951['length'];_0x35e60e++){_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x20')+_0x5cb951[_0x35e60e][_0x9e08f0('0x3d')]()+_0x9e08f0('0x12')+_0x5cb951[_0x35e60e]+_0x9e08f0('0x2e')+_0x5cb951[_0x35e60e][_0x9e08f0('0x3d')]()+_0x9e08f0('0x15')+_0x5cb951[_0x35e60e]+_0x9e08f0('0x38')+_0x5cb951[_0x35e60e]+_0x9e08f0('0x27')+_0x5cb951[_0x35e60e]+'InteractionId;');}_0x16258c['query'](_0x9e08f0('0x14')),_0x16258c[_0x9e08f0('0x1e')](_0x9e08f0('0x45'),_0x9e08f0('0x2f'),{'type':_0x5c124c[_0x9e08f0('0x37')](_0x9e08f0('0x4'),_0x9e08f0('0x34'),_0x9e08f0('0x3b'))}),_0x16258c['addColumn'](_0x9e08f0('0x44'),_0x9e08f0('0x39'),{'type':_0x5c124c[_0x9e08f0('0x3')]}),_0x16258c[_0x9e08f0('0xb')](_0x9e08f0('0x29'),[_0x9e08f0('0x2a')],_0x9e08f0('0x2a')),_0x16258c['addIndex']('cm_hopper_final',['uniqueid'],_0x9e08f0('0x28')),_0x16258c[_0x9e08f0('0xb')](_0x9e08f0('0x7'),[_0x9e08f0('0x28')],_0x9e08f0('0x28')),_0x16258c[_0x9e08f0('0xb')]('voice_recordings',['uniqueid'],_0x9e08f0('0x28')),_0x16258c[_0x9e08f0('0xb')](_0x9e08f0('0x1d'),[_0x9e08f0('0x4c'),_0x9e08f0('0x0')],_0x9e08f0('0x8')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x25')),_0x16258c['query'](_0x9e08f0('0x13')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x2')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x1a')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x43')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x4e')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x4d')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x24')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0xf')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x2c')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x9')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x1f')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x17')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x1b')),_0x16258c[_0x9e08f0('0x2d')](_0x9e08f0('0x23')),_0x16258c[_0x9e08f0('0x2d')]('INSERT\x20INTO\x20`voice_extensions`\x20(`context`,\x20`exten`,\x20`priority`,\x20`app`,\x20`type`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27from-sip\x27,\x20\x27xcally-motion-dialer\x27,\x20\x2714\x27,\x20\x27hangup\x27,\x20\x27system\x27,\x20\x27dialer\x20extensions\x20auto\x20generated\x27,\x20NOW(),\x20NOW());'),_0x16258c['final'](_0x542a26);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.52.js b/server/migrations/2.0.52.js index af59eaf..3011185 100644 --- a/server/migrations/2.0.52.js +++ b/server/migrations/2.0.52.js @@ -1 +1 @@ -const a931_0x320c=['Added\x20column\x20%s\x20to\x20%s','info','clicksend','type','catch','users','query\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_2`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`FaxAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20fax_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','SmsAccountId','ENUM','#2196f3','holdtime','callRecordingEncryption','ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_3`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`SmsAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20sms_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','tail','tools_canned_answers','ChatWebsiteId','changeColumn','stringify','passwordExpiresDays','queryInterface','query','twilio','FaxAccountId','removeColumn','background','OpenchannelAccountId','ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_4`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`OpenchannelAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20openchannel_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','dropTable','sequelize','finally','addIndex\x20%s\x20%s\x20%s','report_dial','INTEGER','STRING','sequence','join','dashboard_items','then','link','addIndex','inspect','ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`ChatWebsiteId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20chat_websites(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','settings','MailAccountId','../config/logger','duration','DATE','sms_accounts','Removed\x20column\x20%s\x20from\x20%s','table\x20dropped\x20%s','skebby','addColumn','#ffffff','final','enqueue','prototype','billableseconds'];(function(_0xf065b0,_0x320c10){const _0x347d7a=function(_0x57811c){while(--_0x57811c){_0xf065b0['push'](_0xf065b0['shift']());}};_0x347d7a(++_0x320c10);}(a931_0x320c,0x155));const a931_0x347d=function(_0xf065b0,_0x320c10){_0xf065b0=_0xf065b0-0x0;let _0x347d7a=a931_0x320c[_0xf065b0];return _0x347d7a;};const _0x5babbb=a931_0x347d;'use strict';const util=require('util'),logger=require(_0x5babbb('0x0'))('migration'),Sequence=function(){};Sequence[_0x5babbb('0xb')][_0x5babbb('0xa')]=function(_0x57811c){const _0xc08bce=_0x5babbb;this[_0xc08bce('0x1c')]=this[_0xc08bce('0x1c')]?this['tail'][_0xc08bce('0x2c')](_0x57811c):_0x57811c();};const Migration=function(_0x5d132c){this['queryInterface']=_0x5d132c,this['sequence']=new Sequence();};Migration[_0x5babbb('0xb')][_0x5babbb('0x1f')]=function(_0x4e5a5c,_0x519f30,_0x43290f){const _0x42a5a4=_0x5babbb,_0x361389=this;this[_0x42a5a4('0x31')][_0x42a5a4('0xa')](function(){const _0x199c46=_0x42a5a4;return _0x361389[_0x199c46('0x22')][_0x199c46('0x1f')](_0x4e5a5c,_0x519f30,_0x43290f)[_0x199c46('0x34')](function(){const _0x2cac65=_0x199c46;logger['info'](_0x2cac65('0x14'),_0x519f30,_0x4e5a5c);})[_0x199c46('0x11')](function(_0x3dc711){const _0x2af3d9=_0x199c46;logger[_0x2af3d9('0xe')](JSON[_0x2af3d9('0x20')](_0x3dc711));});});},Migration['prototype'][_0x5babbb('0x7')]=function(_0x58b217,_0x20f475,_0xe856e2){const _0x3b0b0d=_0x5babbb,_0x2f174e=this;this[_0x3b0b0d('0x31')][_0x3b0b0d('0xa')](function(){const _0x3ef808=_0x3b0b0d;return _0x2f174e[_0x3ef808('0x22')][_0x3ef808('0x7')](_0x58b217,_0x20f475,_0xe856e2)[_0x3ef808('0x34')](function(){const _0x40240b=_0x3ef808;logger[_0x40240b('0xe')](_0x40240b('0xd'),_0x20f475,_0x58b217);})[_0x3ef808('0x11')](function(_0x3eab3b){const _0x3fc304=_0x3ef808;logger[_0x3fc304('0xe')](JSON[_0x3fc304('0x20')](_0x3eab3b));});});},Migration[_0x5babbb('0xb')][_0x5babbb('0x2a')]=function(_0x1de54e){const _0x1fbc20=_0x5babbb,_0x14d7c2=this;this[_0x1fbc20('0x31')][_0x1fbc20('0xa')](function(){const _0xceeae4=_0x1fbc20;return _0x14d7c2[_0xceeae4('0x22')][_0xceeae4('0x2a')](_0x1de54e,{'force':!![]})[_0xceeae4('0x34')](function(){const _0x12fb42=_0xceeae4;logger['info'](_0x12fb42('0x5'),_0x1de54e);})['catch'](function(_0x81b5f7){const _0x444388=_0xceeae4;logger[_0x444388('0xe')](JSON['stringify'](_0x81b5f7));});});},Migration[_0x5babbb('0xb')][_0x5babbb('0x36')]=function(_0x348b5f,_0x4c8688,_0x206072){const _0xf07964=_0x5babbb,_0x528ef8=this;this[_0xf07964('0x31')]['enqueue'](function(){const _0x3f8955=_0xf07964;return _0x528ef8['queryInterface']['addIndex'](_0x348b5f,_0x4c8688,{'indexName':_0x206072})[_0x3f8955('0x34')](function(){const _0x2f6a4e=_0x3f8955;logger[_0x2f6a4e('0xe')](_0x2f6a4e('0x2d'),_0x348b5f,_0x4c8688[_0x2f6a4e('0x32')](','),_0x206072);})[_0x3f8955('0x11')](function(_0x23ec26){const _0x182a8e=_0x3f8955;logger[_0x182a8e('0xe')](JSON[_0x182a8e('0x20')](_0x23ec26));});});},Migration[_0x5babbb('0xb')]['query']=function(_0x3a12e4){const _0x5b539=_0x5babbb,_0x378e58=this;this[_0x5b539('0x31')][_0x5b539('0xa')](function(){const _0x5107c4=_0x5b539;return _0x378e58[_0x5107c4('0x22')][_0x5107c4('0x2b')][_0x5107c4('0x23')](_0x3a12e4)['then'](function(){const _0x29f3f2=_0x5107c4;logger[_0x29f3f2('0xe')](_0x29f3f2('0x13'),_0x3a12e4);})[_0x5107c4('0x11')](function(_0x394592){const _0x106fc0=_0x5107c4;logger[_0x106fc0('0xe')](JSON['stringify'](_0x394592));});});},Migration[_0x5babbb('0xb')][_0x5babbb('0x26')]=function(_0x4e9d33,_0x283c2e){const _0x3e8a79=_0x5babbb,_0x2d9066=this;this[_0x3e8a79('0x31')]['enqueue'](function(){const _0x4a9db7=_0x3e8a79;return _0x2d9066[_0x4a9db7('0x22')]['removeColumn'](_0x4e9d33,_0x283c2e)[_0x4a9db7('0x34')](function(){const _0x26e9bd=_0x4a9db7;logger[_0x26e9bd('0xe')](_0x26e9bd('0x4'),_0x283c2e,_0x4e9d33);})[_0x4a9db7('0x11')](function(_0x4bd154){const _0x40e166=_0x4a9db7;logger[_0x40e166('0xe')](util[_0x40e166('0x37')](_0x4bd154,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x5ae306){const _0x2887aa=_0x5babbb;this['sequence'][_0x2887aa('0xa')](function(){return _0x5ae306();});},module['exports']={'up':function(_0x128e0a,_0x5431ef){return new Promise(function(_0x4950b0){const _0x59e6ac=a931_0x347d,_0x1f135e=new Migration(_0x128e0a);_0x1f135e['addColumn'](_0x59e6ac('0x39'),_0x59e6ac('0x1a'),{'type':_0x5431ef['BOOLEAN'],'defaultValue':![]}),_0x1f135e[_0x59e6ac('0x7')](_0x59e6ac('0x39'),_0x59e6ac('0x21'),{'type':_0x5431ef[_0x59e6ac('0x2f')](0xb),'defaultValue':0x5a}),_0x1f135e['query']('UPDATE\x20settings\x20SET\x20securePassword=false\x20WHERE\x20id=1'),_0x1f135e[_0x59e6ac('0x7')](_0x59e6ac('0x1d'),_0x59e6ac('0x3a'),{'type':_0x5431ef[_0x59e6ac('0x2f')]}),_0x1f135e[_0x59e6ac('0x7')](_0x59e6ac('0x1d'),_0x59e6ac('0x25'),{'type':_0x5431ef['INTEGER']}),_0x1f135e['addColumn'](_0x59e6ac('0x1d'),_0x59e6ac('0x16'),{'type':_0x5431ef[_0x59e6ac('0x2f')]}),_0x1f135e[_0x59e6ac('0x7')](_0x59e6ac('0x1d'),_0x59e6ac('0x28'),{'type':_0x5431ef[_0x59e6ac('0x2f')]}),_0x1f135e[_0x59e6ac('0x7')](_0x59e6ac('0x1d'),_0x59e6ac('0x1e'),{'type':_0x5431ef[_0x59e6ac('0x2f')]}),_0x1f135e[_0x59e6ac('0x23')]('ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_1`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20mail_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE'),_0x1f135e[_0x59e6ac('0x23')](_0x59e6ac('0x15')),_0x1f135e[_0x59e6ac('0x23')](_0x59e6ac('0x1b')),_0x1f135e[_0x59e6ac('0x23')](_0x59e6ac('0x29')),_0x1f135e[_0x59e6ac('0x23')](_0x59e6ac('0x38')),_0x1f135e[_0x59e6ac('0x7')](_0x59e6ac('0x12'),'passwordResetAt',{'type':_0x5431ef[_0x59e6ac('0x2')],'defaultValue':null}),_0x1f135e['query']('UPDATE\x20users\x20SET\x20passwordResetAt=NOW()'),_0x1f135e['addColumn']('report_dial',_0x59e6ac('0x1'),{'type':_0x5431ef['INTEGER']}),_0x1f135e[_0x59e6ac('0x7')](_0x59e6ac('0x2e'),_0x59e6ac('0x19'),{'type':_0x5431ef['INTEGER']}),_0x1f135e['addColumn'](_0x59e6ac('0x2e'),_0x59e6ac('0xc'),{'type':_0x5431ef[_0x59e6ac('0x2f')]}),_0x1f135e['changeColumn'](_0x59e6ac('0x3'),_0x59e6ac('0x10'),{'type':_0x5431ef[_0x59e6ac('0x17')](_0x59e6ac('0x24'),_0x59e6ac('0x6'),'connectel',_0x59e6ac('0xf'))}),_0x1f135e['addColumn'](_0x59e6ac('0x33'),_0x59e6ac('0x27'),{'type':_0x5431ef['STRING'],'allowNull':![],'defaultValue':_0x59e6ac('0x8'),'validate':{'notEmpty':!![]}}),_0x1f135e[_0x59e6ac('0x7')](_0x59e6ac('0x33'),'foreground',{'type':_0x5431ef[_0x59e6ac('0x30')],'allowNull':![],'defaultValue':_0x59e6ac('0x18'),'validate':{'notEmpty':!![]}}),_0x1f135e[_0x59e6ac('0x7')](_0x59e6ac('0x33'),_0x59e6ac('0x35'),{'type':_0x5431ef[_0x59e6ac('0x30')]}),_0x1f135e[_0x59e6ac('0x9')](_0x4950b0);});},'down':function(){}}; \ No newline at end of file +const a931_0x5e90=['dashboard_items','STRING','tail','inspect','SmsAccountId','removeColumn','sequence','finally','dropTable','sequelize','report_dial','holdtime','BOOLEAN','addColumn','final','FaxAccountId','info','then','passwordExpiresDays','queryInterface','Added\x20column\x20%s\x20to\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','stringify','type','Removed\x20column\x20%s\x20from\x20%s','#2196f3','duration','ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_2`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`FaxAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20fax_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','sms_accounts','clicksend','query','changeColumn','twilio','callRecordingEncryption','table\x20dropped\x20%s','../config/logger','prototype','util','UPDATE\x20users\x20SET\x20passwordResetAt=NOW()','join','users','tools_canned_answers','addIndex','ENUM','skebby','INTEGER','settings','ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_4`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`OpenchannelAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20openchannel_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','enqueue','addIndex\x20%s\x20%s\x20%s','catch','exports'];(function(_0x127e41,_0x5e90d8){const _0x50125b=function(_0x5ee65a){while(--_0x5ee65a){_0x127e41['push'](_0x127e41['shift']());}};_0x50125b(++_0x5e90d8);}(a931_0x5e90,0x119));const a931_0x5012=function(_0x127e41,_0x5e90d8){_0x127e41=_0x127e41-0x0;let _0x50125b=a931_0x5e90[_0x127e41];return _0x50125b;};const _0x1ef5d2=a931_0x5012;'use strict';const util=require(_0x1ef5d2('0x10')),logger=require(_0x1ef5d2('0xe'))('migration'),Sequence=function(){};Sequence[_0x1ef5d2('0xf')][_0x1ef5d2('0x1b')]=function(_0x5ee65a){const _0x2c52c9=_0x1ef5d2;this[_0x2c52c9('0x21')]=this['tail']?this['tail'][_0x2c52c9('0x26')](_0x5ee65a):_0x5ee65a();};const Migration=function(_0x5f0af9){const _0x3ccc0f=_0x1ef5d2;this['queryInterface']=_0x5f0af9,this[_0x3ccc0f('0x25')]=new Sequence();};Migration[_0x1ef5d2('0xf')][_0x1ef5d2('0xa')]=function(_0x25a7e4,_0x33ffdd,_0x5d84b9){const _0x2d4e50=_0x1ef5d2,_0x4e000a=this;this[_0x2d4e50('0x25')][_0x2d4e50('0x1b')](function(){const _0x19d723=_0x2d4e50;return _0x4e000a[_0x19d723('0x32')][_0x19d723('0xa')](_0x25a7e4,_0x33ffdd,_0x5d84b9)[_0x19d723('0x30')](function(){const _0x3eec5c=_0x19d723;logger[_0x3eec5c('0x2f')](_0x3eec5c('0x0'),_0x33ffdd,_0x25a7e4);})[_0x19d723('0x1d')](function(_0x1aebf3){const _0x1dae34=_0x19d723;logger[_0x1dae34('0x2f')](JSON['stringify'](_0x1aebf3));});});},Migration['prototype'][_0x1ef5d2('0x2c')]=function(_0x1e5786,_0x43eb5f,_0x3a3d58){const _0x330cad=_0x1ef5d2,_0x381211=this;this[_0x330cad('0x25')]['enqueue'](function(){const _0x2e5ed2=_0x330cad;return _0x381211[_0x2e5ed2('0x32')][_0x2e5ed2('0x2c')](_0x1e5786,_0x43eb5f,_0x3a3d58)[_0x2e5ed2('0x30')](function(){const _0x33c553=_0x2e5ed2;logger[_0x33c553('0x2f')](_0x33c553('0x33'),_0x43eb5f,_0x1e5786);})[_0x2e5ed2('0x1d')](function(_0x55b904){const _0x5968b5=_0x2e5ed2;logger['info'](JSON[_0x5968b5('0x1')](_0x55b904));});});},Migration[_0x1ef5d2('0xf')][_0x1ef5d2('0x27')]=function(_0xd5b6d6){const _0x26aeeb=_0x1ef5d2,_0x446437=this;this[_0x26aeeb('0x25')][_0x26aeeb('0x1b')](function(){const _0x4eca67=_0x26aeeb;return _0x446437['queryInterface'][_0x4eca67('0x27')](_0xd5b6d6,{'force':!![]})[_0x4eca67('0x30')](function(){const _0x56cf36=_0x4eca67;logger[_0x56cf36('0x2f')](_0x56cf36('0xd'),_0xd5b6d6);})[_0x4eca67('0x1d')](function(_0x476dee){const _0x142813=_0x4eca67;logger[_0x142813('0x2f')](JSON['stringify'](_0x476dee));});});},Migration[_0x1ef5d2('0xf')][_0x1ef5d2('0x15')]=function(_0x45ab25,_0x35802b,_0x25f733){const _0x67158=_0x1ef5d2,_0x45389c=this;this[_0x67158('0x25')][_0x67158('0x1b')](function(){const _0xed52f8=_0x67158;return _0x45389c[_0xed52f8('0x32')][_0xed52f8('0x15')](_0x45ab25,_0x35802b,{'indexName':_0x25f733})[_0xed52f8('0x30')](function(){const _0x3b3952=_0xed52f8;logger['info'](_0x3b3952('0x1c'),_0x45ab25,_0x35802b[_0x3b3952('0x12')](','),_0x25f733);})[_0xed52f8('0x1d')](function(_0x57d250){const _0x8e9db4=_0xed52f8;logger['info'](JSON[_0x8e9db4('0x1')](_0x57d250));});});},Migration['prototype'][_0x1ef5d2('0x9')]=function(_0x1778a4){const _0x280ec7=_0x1ef5d2,_0x190e88=this;this[_0x280ec7('0x25')][_0x280ec7('0x1b')](function(){const _0x52f3ee=_0x280ec7;return _0x190e88[_0x52f3ee('0x32')][_0x52f3ee('0x28')]['query'](_0x1778a4)[_0x52f3ee('0x30')](function(){const _0x17b850=_0x52f3ee;logger[_0x17b850('0x2f')]('query\x20%s',_0x1778a4);})[_0x52f3ee('0x1d')](function(_0x37e888){const _0x4f141f=_0x52f3ee;logger[_0x4f141f('0x2f')](JSON['stringify'](_0x37e888));});});},Migration[_0x1ef5d2('0xf')][_0x1ef5d2('0x24')]=function(_0x1d61ef,_0x569620){const _0x335492=_0x1ef5d2,_0x373086=this;this[_0x335492('0x25')][_0x335492('0x1b')](function(){const _0x52014c=_0x335492;return _0x373086[_0x52014c('0x32')]['removeColumn'](_0x1d61ef,_0x569620)['then'](function(){const _0x38f14f=_0x52014c;logger[_0x38f14f('0x2f')](_0x38f14f('0x3'),_0x569620,_0x1d61ef);})[_0x52014c('0x1d')](function(_0x4c2f19){const _0x1b4a9a=_0x52014c;logger[_0x1b4a9a('0x2f')](util[_0x1b4a9a('0x22')](_0x4c2f19,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0xac879f){const _0xb9c9c8=_0x1ef5d2;this[_0xb9c9c8('0x25')]['enqueue'](function(){return _0xac879f();});},module[_0x1ef5d2('0x1e')]={'up':function(_0x4d5b90,_0x1d5cfd){return new Promise(function(_0x406b46){const _0x3c0be7=a931_0x5012,_0x3fa22f=new Migration(_0x4d5b90);_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x19'),_0x3c0be7('0xc'),{'type':_0x1d5cfd[_0x3c0be7('0x2b')],'defaultValue':![]}),_0x3fa22f['addColumn'](_0x3c0be7('0x19'),_0x3c0be7('0x31'),{'type':_0x1d5cfd[_0x3c0be7('0x18')](0xb),'defaultValue':0x5a}),_0x3fa22f[_0x3c0be7('0x9')]('UPDATE\x20settings\x20SET\x20securePassword=false\x20WHERE\x20id=1'),_0x3fa22f[_0x3c0be7('0x2c')]('tools_canned_answers','MailAccountId',{'type':_0x1d5cfd['INTEGER']}),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x14'),_0x3c0be7('0x2e'),{'type':_0x1d5cfd['INTEGER']}),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x14'),_0x3c0be7('0x23'),{'type':_0x1d5cfd[_0x3c0be7('0x18')]}),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x14'),'OpenchannelAccountId',{'type':_0x1d5cfd[_0x3c0be7('0x18')]}),_0x3fa22f[_0x3c0be7('0x2c')]('tools_canned_answers','ChatWebsiteId',{'type':_0x1d5cfd[_0x3c0be7('0x18')]}),_0x3fa22f[_0x3c0be7('0x9')]('ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_1`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20mail_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE'),_0x3fa22f['query'](_0x3c0be7('0x6')),_0x3fa22f[_0x3c0be7('0x9')]('ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_3`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`SmsAccountId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20sms_accounts(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE'),_0x3fa22f[_0x3c0be7('0x9')](_0x3c0be7('0x1a')),_0x3fa22f['query']('ALTER\x20TABLE\x20`tools_canned_answers`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`ChatWebsiteId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20chat_websites(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE'),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x13'),'passwordResetAt',{'type':_0x1d5cfd['DATE'],'defaultValue':null}),_0x3fa22f[_0x3c0be7('0x9')](_0x3c0be7('0x11')),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x29'),_0x3c0be7('0x5'),{'type':_0x1d5cfd[_0x3c0be7('0x18')]}),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x29'),_0x3c0be7('0x2a'),{'type':_0x1d5cfd[_0x3c0be7('0x18')]}),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x29'),'billableseconds',{'type':_0x1d5cfd['INTEGER']}),_0x3fa22f['changeColumn'](_0x3c0be7('0x7'),_0x3c0be7('0x2'),{'type':_0x1d5cfd[_0x3c0be7('0x16')](_0x3c0be7('0xb'),_0x3c0be7('0x17'),'connectel',_0x3c0be7('0x8'))}),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x1f'),'background',{'type':_0x1d5cfd[_0x3c0be7('0x20')],'allowNull':![],'defaultValue':'#ffffff','validate':{'notEmpty':!![]}}),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x1f'),'foreground',{'type':_0x1d5cfd['STRING'],'allowNull':![],'defaultValue':_0x3c0be7('0x4'),'validate':{'notEmpty':!![]}}),_0x3fa22f[_0x3c0be7('0x2c')](_0x3c0be7('0x1f'),'link',{'type':_0x1d5cfd[_0x3c0be7('0x20')]}),_0x3fa22f[_0x3c0be7('0x2d')](_0x406b46);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.53.js b/server/migrations/2.0.53.js index 7a41bb3..8cbfde0 100644 --- a/server/migrations/2.0.53.js +++ b/server/migrations/2.0.53.js @@ -1 +1 @@ -const a932_0x1b36=['dropTable','sequence','final','insecure','join','output','prototype','sms_accounts','changeColumn','util','csv','xls','users','query','tail','STRING','Removed\x20column\x20%s\x20from\x20%s','pdf','enqueue','query\x20%s','type','ENUM','then','twilio','table\x20dropped\x20%s','finally','analytics_extracted_reports','addColumn','description','queryInterface','clicksend','inspect','catch','stringify','connectel','../config/logger','skebby','xlsx','exports','info'];(function(_0x181daf,_0x1b3685){const _0x1030e4=function(_0x24f963){while(--_0x24f963){_0x181daf['push'](_0x181daf['shift']());}};_0x1030e4(++_0x1b3685);}(a932_0x1b36,0x1ea));const a932_0x1030=function(_0x181daf,_0x1b3685){_0x181daf=_0x181daf-0x0;let _0x1030e4=a932_0x1b36[_0x181daf];return _0x1030e4;};const _0x3021c0=a932_0x1030;'use strict';const util=require(_0x3021c0('0x27')),logger=require(_0x3021c0('0x19'))('migration'),Sequence=function(){};Sequence['prototype'][_0x3021c0('0x8')]=function(_0x24f963){const _0x48c984=_0x3021c0;this[_0x48c984('0x4')]=this['tail']?this[_0x48c984('0x4')][_0x48c984('0xf')](_0x24f963):_0x24f963();};const Migration=function(_0x53bf5f){const _0x2cfeda=_0x3021c0;this[_0x2cfeda('0x13')]=_0x53bf5f,this[_0x2cfeda('0x1f')]=new Sequence();};Migration[_0x3021c0('0x24')][_0x3021c0('0x26')]=function(_0x1592fb,_0x480dee,_0x21b4f2){const _0x3f3f17=_0x3021c0,_0x251af5=this;this['sequence'][_0x3f3f17('0x8')](function(){const _0xd2fd8f=_0x3f3f17;return _0x251af5['queryInterface'][_0xd2fd8f('0x26')](_0x1592fb,_0x480dee,_0x21b4f2)[_0xd2fd8f('0xc')](function(){const _0x144ee5=_0xd2fd8f;logger[_0x144ee5('0x1d')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x480dee,_0x1592fb);})[_0xd2fd8f('0x16')](function(_0x108375){const _0xa6cde7=_0xd2fd8f;logger[_0xa6cde7('0x1d')](JSON[_0xa6cde7('0x17')](_0x108375));});});},Migration[_0x3021c0('0x24')][_0x3021c0('0x11')]=function(_0x2ba017,_0x191072,_0x2f4220){const _0x12fd8e=_0x3021c0,_0x501071=this;this[_0x12fd8e('0x1f')]['enqueue'](function(){const _0x1637c3=_0x12fd8e;return _0x501071[_0x1637c3('0x13')][_0x1637c3('0x11')](_0x2ba017,_0x191072,_0x2f4220)['then'](function(){const _0x165f6d=_0x1637c3;logger[_0x165f6d('0x1d')]('Added\x20column\x20%s\x20to\x20%s',_0x191072,_0x2ba017);})[_0x1637c3('0x16')](function(_0x4c96e9){const _0x3fc7ab=_0x1637c3;logger['info'](JSON[_0x3fc7ab('0x17')](_0x4c96e9));});});},Migration[_0x3021c0('0x24')][_0x3021c0('0x1e')]=function(_0x12906d){const _0x1ce7d4=_0x3021c0,_0x4d6903=this;this[_0x1ce7d4('0x1f')][_0x1ce7d4('0x8')](function(){const _0x3a0cc8=_0x1ce7d4;return _0x4d6903[_0x3a0cc8('0x13')][_0x3a0cc8('0x1e')](_0x12906d,{'force':!![]})[_0x3a0cc8('0xc')](function(){const _0x718b13=_0x3a0cc8;logger['info'](_0x718b13('0xe'),_0x12906d);})[_0x3a0cc8('0x16')](function(_0x29f69b){const _0x1cc538=_0x3a0cc8;logger[_0x1cc538('0x1d')](JSON[_0x1cc538('0x17')](_0x29f69b));});});},Migration['prototype']['addIndex']=function(_0x4ef70c,_0x28c7d1,_0x2c834d){const _0x3dfec8=_0x3021c0,_0x43d323=this;this[_0x3dfec8('0x1f')][_0x3dfec8('0x8')](function(){const _0x338590=_0x3dfec8;return _0x43d323[_0x338590('0x13')]['addIndex'](_0x4ef70c,_0x28c7d1,{'indexName':_0x2c834d})[_0x338590('0xc')](function(){const _0x4eee7a=_0x338590;logger[_0x4eee7a('0x1d')]('addIndex\x20%s\x20%s\x20%s',_0x4ef70c,_0x28c7d1[_0x4eee7a('0x22')](','),_0x2c834d);})['catch'](function(_0x4ea1a8){const _0x1c5ec5=_0x338590;logger[_0x1c5ec5('0x1d')](JSON['stringify'](_0x4ea1a8));});});},Migration[_0x3021c0('0x24')][_0x3021c0('0x3')]=function(_0x218a7d){const _0x3fdfeb=_0x3021c0,_0x4433dd=this;this[_0x3fdfeb('0x1f')]['enqueue'](function(){const _0x2d8e45=_0x3fdfeb;return _0x4433dd['queryInterface']['sequelize'][_0x2d8e45('0x3')](_0x218a7d)['then'](function(){const _0x101707=_0x2d8e45;logger[_0x101707('0x1d')](_0x101707('0x9'),_0x218a7d);})[_0x2d8e45('0x16')](function(_0x3e2a49){const _0x132616=_0x2d8e45;logger[_0x132616('0x1d')](JSON[_0x132616('0x17')](_0x3e2a49));});});},Migration['prototype']['removeColumn']=function(_0xbb180f,_0x19c05c){const _0xbf038=_0x3021c0,_0x3d2075=this;this[_0xbf038('0x1f')][_0xbf038('0x8')](function(){const _0x2c386d=_0xbf038;return _0x3d2075['queryInterface']['removeColumn'](_0xbb180f,_0x19c05c)[_0x2c386d('0xc')](function(){const _0xffd4c0=_0x2c386d;logger[_0xffd4c0('0x1d')](_0xffd4c0('0x6'),_0x19c05c,_0xbb180f);})['catch'](function(_0x37bc3d){const _0xa03cfe=_0x2c386d;logger[_0xa03cfe('0x1d')](util[_0xa03cfe('0x15')](_0x37bc3d,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x3021c0('0x20')]=function(_0x47007e){const _0x294f9a=_0x3021c0;this[_0x294f9a('0x1f')][_0x294f9a('0x8')](function(){return _0x47007e();});},module[_0x3021c0('0x1c')]={'up':function(_0x2473e3,_0x94a3ac){return new Promise(function(_0x3b64d6){const _0x3afdfe=a932_0x1030,_0x3099ba=new Migration(_0x2473e3);_0x3099ba[_0x3afdfe('0x26')]('cm_contacts',_0x3afdfe('0x12'),{'type':_0x94a3ac['TEXT']}),_0x3099ba['changeColumn'](_0x3afdfe('0x25'),_0x3afdfe('0xa'),{'type':_0x94a3ac[_0x3afdfe('0xb')](_0x3afdfe('0xd'),_0x3afdfe('0x1a'),_0x3afdfe('0x18'),_0x3afdfe('0x14'),'plivo')}),_0x3099ba[_0x3afdfe('0x26')](_0x3afdfe('0x10'),'output',{'type':_0x94a3ac[_0x3afdfe('0xb')](_0x3afdfe('0x0'),_0x3afdfe('0x7'),_0x3afdfe('0x1'),'xlsx'),'allowNull':![],'defaultValue':_0x3afdfe('0x0')}),_0x3099ba[_0x3afdfe('0x3')]('UPDATE\x20analytics_extracted_reports\x20SET\x20output=\x27xlsx\x27\x20WHERE\x20output=\x27xls\x27'),_0x3099ba['changeColumn'](_0x3afdfe('0x10'),_0x3afdfe('0x23'),{'type':_0x94a3ac[_0x3afdfe('0xb')](_0x3afdfe('0x0'),_0x3afdfe('0x7'),_0x3afdfe('0x1b')),'allowNull':![],'defaultValue':'csv'}),_0x3099ba[_0x3afdfe('0x3')]('UPDATE\x20users\x20SET\x20insecure=NULL\x20WHERE\x20insecure=\x27port,invite\x27'),_0x3099ba[_0x3afdfe('0x26')](_0x3afdfe('0x2'),_0x3afdfe('0x21'),{'type':_0x94a3ac[_0x3afdfe('0x5')],'allowNull':!![]}),_0x3099ba[_0x3afdfe('0x20')](_0x3b64d6);});},'down':function(){}}; \ No newline at end of file +const a932_0x5ac9=['Added\x20column\x20%s\x20to\x20%s','changeColumn','join','ENUM','query','inspect','UPDATE\x20analytics_extracted_reports\x20SET\x20output=\x27xlsx\x27\x20WHERE\x20output=\x27xls\x27','cm_contacts','xls','catch','twilio','pdf','info','connectel','dropTable','description','csv','removeColumn','clicksend','output','then','../config/logger','plivo','type','analytics_extracted_reports','migration','stringify','prototype','Removed\x20column\x20%s\x20from\x20%s','addIndex','final','sequence','queryInterface','sequelize','tail','users','TEXT','enqueue','exports'];(function(_0x280beb,_0x5ac964){const _0x538b5d=function(_0x2fc239){while(--_0x2fc239){_0x280beb['push'](_0x280beb['shift']());}};_0x538b5d(++_0x5ac964);}(a932_0x5ac9,0x73));const a932_0x538b=function(_0x280beb,_0x5ac964){_0x280beb=_0x280beb-0x0;let _0x538b5d=a932_0x5ac9[_0x280beb];return _0x538b5d;};const _0x526aff=a932_0x538b;'use strict';const util=require('util'),logger=require(_0x526aff('0x17'))(_0x526aff('0x1b')),Sequence=function(){};Sequence['prototype'][_0x526aff('0x0')]=function(_0x2fc239){const _0x71dcca=_0x526aff;this[_0x71dcca('0x24')]=this['tail']?this[_0x71dcca('0x24')]['finally'](_0x2fc239):_0x2fc239();};const Migration=function(_0x5eed3d){const _0x2f986c=_0x526aff;this[_0x2f986c('0x22')]=_0x5eed3d,this[_0x2f986c('0x21')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x310988,_0x5d9fe4,_0x1c13be){const _0x33641c=_0x526aff,_0x54e3dc=this;this[_0x33641c('0x21')][_0x33641c('0x0')](function(){const _0x564a46=_0x33641c;return _0x54e3dc[_0x564a46('0x22')]['changeColumn'](_0x310988,_0x5d9fe4,_0x1c13be)[_0x564a46('0x16')](function(){const _0x1dca79=_0x564a46;logger[_0x1dca79('0xe')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x5d9fe4,_0x310988);})[_0x564a46('0xb')](function(_0x1ef511){const _0x4e6be4=_0x564a46;logger[_0x4e6be4('0xe')](JSON['stringify'](_0x1ef511));});});},Migration['prototype']['addColumn']=function(_0x1d8cdd,_0x58cce1,_0x35fb81){const _0x24a9a5=_0x526aff,_0x596020=this;this[_0x24a9a5('0x21')]['enqueue'](function(){const _0x1cfaed=_0x24a9a5;return _0x596020['queryInterface']['addColumn'](_0x1d8cdd,_0x58cce1,_0x35fb81)[_0x1cfaed('0x16')](function(){const _0x20f46a=_0x1cfaed;logger['info'](_0x20f46a('0x2'),_0x58cce1,_0x1d8cdd);})[_0x1cfaed('0xb')](function(_0x107e7f){logger['info'](JSON['stringify'](_0x107e7f));});});},Migration['prototype'][_0x526aff('0x10')]=function(_0x2949b2){const _0x42142f=_0x526aff,_0x46c556=this;this['sequence'][_0x42142f('0x0')](function(){const _0x4800c8=_0x42142f;return _0x46c556[_0x4800c8('0x22')][_0x4800c8('0x10')](_0x2949b2,{'force':!![]})[_0x4800c8('0x16')](function(){const _0x5f211e=_0x4800c8;logger[_0x5f211e('0xe')]('table\x20dropped\x20%s',_0x2949b2);})['catch'](function(_0x3c6ac4){const _0x4c6fa4=_0x4800c8;logger[_0x4c6fa4('0xe')](JSON[_0x4c6fa4('0x1c')](_0x3c6ac4));});});},Migration[_0x526aff('0x1d')][_0x526aff('0x1f')]=function(_0x71d22a,_0x36c3bd,_0x1a47e9){const _0x58bed7=_0x526aff,_0x529c58=this;this[_0x58bed7('0x21')][_0x58bed7('0x0')](function(){const _0x58a640=_0x58bed7;return _0x529c58[_0x58a640('0x22')]['addIndex'](_0x71d22a,_0x36c3bd,{'indexName':_0x1a47e9})['then'](function(){const _0x5979ec=_0x58a640;logger['info']('addIndex\x20%s\x20%s\x20%s',_0x71d22a,_0x36c3bd[_0x5979ec('0x4')](','),_0x1a47e9);})['catch'](function(_0x51ab00){const _0x430da0=_0x58a640;logger[_0x430da0('0xe')](JSON['stringify'](_0x51ab00));});});},Migration[_0x526aff('0x1d')]['query']=function(_0xe11ee1){const _0x2abb00=_0x526aff,_0x1e7d3d=this;this[_0x2abb00('0x21')]['enqueue'](function(){const _0x13c573=_0x2abb00;return _0x1e7d3d['queryInterface'][_0x13c573('0x23')]['query'](_0xe11ee1)['then'](function(){const _0x3d9bcf=_0x13c573;logger[_0x3d9bcf('0xe')]('query\x20%s',_0xe11ee1);})[_0x13c573('0xb')](function(_0x4a1012){const _0xe41620=_0x13c573;logger[_0xe41620('0xe')](JSON[_0xe41620('0x1c')](_0x4a1012));});});},Migration[_0x526aff('0x1d')][_0x526aff('0x13')]=function(_0x5f3d06,_0x70ad55){const _0x560552=_0x526aff,_0x1c572f=this;this['sequence'][_0x560552('0x0')](function(){const _0x9a0693=_0x560552;return _0x1c572f[_0x9a0693('0x22')][_0x9a0693('0x13')](_0x5f3d06,_0x70ad55)[_0x9a0693('0x16')](function(){const _0x2c14fa=_0x9a0693;logger[_0x2c14fa('0xe')](_0x2c14fa('0x1e'),_0x70ad55,_0x5f3d06);})[_0x9a0693('0xb')](function(_0x4f7656){const _0x527264=_0x9a0693;logger[_0x527264('0xe')](util[_0x527264('0x7')](_0x4f7656,{'showHidden':![],'depth':null}));});});},Migration[_0x526aff('0x1d')][_0x526aff('0x20')]=function(_0x370674){const _0x196a72=_0x526aff;this['sequence'][_0x196a72('0x0')](function(){return _0x370674();});},module[_0x526aff('0x1')]={'up':function(_0x41b380,_0x2e41ed){return new Promise(function(_0x14e8cb){const _0x147e29=a932_0x538b,_0x399ab7=new Migration(_0x41b380);_0x399ab7[_0x147e29('0x3')](_0x147e29('0x9'),_0x147e29('0x11'),{'type':_0x2e41ed[_0x147e29('0x26')]}),_0x399ab7[_0x147e29('0x3')]('sms_accounts',_0x147e29('0x19'),{'type':_0x2e41ed['ENUM'](_0x147e29('0xc'),'skebby',_0x147e29('0xf'),_0x147e29('0x14'),_0x147e29('0x18'))}),_0x399ab7[_0x147e29('0x3')](_0x147e29('0x1a'),_0x147e29('0x15'),{'type':_0x2e41ed['ENUM'](_0x147e29('0x12'),_0x147e29('0xd'),_0x147e29('0xa'),'xlsx'),'allowNull':![],'defaultValue':_0x147e29('0x12')}),_0x399ab7[_0x147e29('0x6')](_0x147e29('0x8')),_0x399ab7[_0x147e29('0x3')](_0x147e29('0x1a'),_0x147e29('0x15'),{'type':_0x2e41ed[_0x147e29('0x5')](_0x147e29('0x12'),'pdf','xlsx'),'allowNull':![],'defaultValue':_0x147e29('0x12')}),_0x399ab7[_0x147e29('0x6')]('UPDATE\x20users\x20SET\x20insecure=NULL\x20WHERE\x20insecure=\x27port,invite\x27'),_0x399ab7[_0x147e29('0x3')](_0x147e29('0x25'),'insecure',{'type':_0x2e41ed['STRING'],'allowNull':!![]}),_0x399ab7[_0x147e29('0x20')](_0x14e8cb);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.54.js b/server/migrations/2.0.54.js index 7cff47c..de1a926 100644 --- a/server/migrations/2.0.54.js +++ b/server/migrations/2.0.54.js @@ -1 +1 @@ -const a933_0x5a07=['dropTable','UNSIGNED','queryInterface','addColumn','UPDATE\x20users\x20SET\x20nat=\x27force_rport,comedia\x27\x20WHERE\x20nat\x20IS\x20NULL','output','addIndex','markAsUnread','tools_schedules','enqueue','../config/logger','INTEGER','csv','exports','xls','pdf','prototype','addIndex\x20%s\x20%s\x20%s','final','query\x20%s','join','signature','chat_websites','Removed\x20column\x20%s\x20from\x20%s','renameColumn','changeColumn','Added\x20column\x20%s\x20to\x20%s','textColor','then','migration','stringify','xlsx','#ffffff','mail_accounts','ENUM','fontFamily','sequence','Changed\x20column\x20%s\x20in\x20table\x20%s','catch','UPDATE\x20users\x20SET\x20transport=\x27wss\x27\x20WHERE\x20avpf\x20IS\x20NOT\x20NULL','removeColumn','table\x20dropped\x20%s','STRING','UPDATE\x20tools_schedules\x20SET\x20output=\x27xlsx\x27\x20WHERE\x20output=\x27xls\x27','template','query','tail','fontSize','info','timezone','inspect'];(function(_0x99bced,_0x5a07a0){const _0x2234d2=function(_0x513ac8){while(--_0x513ac8){_0x99bced['push'](_0x99bced['shift']());}};_0x2234d2(++_0x5a07a0);}(a933_0x5a07,0x16a));const a933_0x2234=function(_0x99bced,_0x5a07a0){_0x99bced=_0x99bced-0x0;let _0x2234d2=a933_0x5a07[_0x99bced];return _0x2234d2;};const _0x1ceeeb=a933_0x2234;'use strict';const util=require('util'),logger=require(_0x1ceeeb('0x5'))(_0x1ceeeb('0x18')),Sequence=function(){};Sequence[_0x1ceeeb('0xb')][_0x1ceeeb('0x4')]=function(_0x513ac8){const _0xa5264e=_0x1ceeeb;this[_0xa5264e('0x29')]=this['tail']?this[_0xa5264e('0x29')]['finally'](_0x513ac8):_0x513ac8();};const Migration=function(_0x2f1c5c){const _0x2a2408=_0x1ceeeb;this['queryInterface']=_0x2f1c5c,this[_0x2a2408('0x1f')]=new Sequence();};Migration[_0x1ceeeb('0xb')][_0x1ceeeb('0x14')]=function(_0x1f78a2,_0x1c6684,_0x51502f){const _0x424831=_0x1ceeeb,_0x492d82=this;this['sequence'][_0x424831('0x4')](function(){const _0x41d551=_0x424831;return _0x492d82[_0x41d551('0x30')][_0x41d551('0x14')](_0x1f78a2,_0x1c6684,_0x51502f)['then'](function(){const _0x3cdc5a=_0x41d551;logger[_0x3cdc5a('0x2b')](_0x3cdc5a('0x20'),_0x1c6684,_0x1f78a2);})['catch'](function(_0x2767fc){const _0x4eb84b=_0x41d551;logger[_0x4eb84b('0x2b')](JSON[_0x4eb84b('0x19')](_0x2767fc));});});},Migration[_0x1ceeeb('0xb')][_0x1ceeeb('0x31')]=function(_0x56b996,_0x3919b4,_0x328160){const _0x48ce6e=_0x1ceeeb,_0x4eb767=this;this[_0x48ce6e('0x1f')][_0x48ce6e('0x4')](function(){const _0xc875e7=_0x48ce6e;return _0x4eb767[_0xc875e7('0x30')][_0xc875e7('0x31')](_0x56b996,_0x3919b4,_0x328160)[_0xc875e7('0x17')](function(){const _0x3f3093=_0xc875e7;logger[_0x3f3093('0x2b')](_0x3f3093('0x15'),_0x3919b4,_0x56b996);})[_0xc875e7('0x21')](function(_0x29fa4a){const _0x12b587=_0xc875e7;logger[_0x12b587('0x2b')](JSON[_0x12b587('0x19')](_0x29fa4a));});});},Migration[_0x1ceeeb('0xb')][_0x1ceeeb('0x2e')]=function(_0x28a505){const _0x4ee28e=_0x1ceeeb,_0x51aa2a=this;this['sequence'][_0x4ee28e('0x4')](function(){const _0x56e906=_0x4ee28e;return _0x51aa2a[_0x56e906('0x30')]['dropTable'](_0x28a505,{'force':!![]})[_0x56e906('0x17')](function(){const _0x5cc0df=_0x56e906;logger[_0x5cc0df('0x2b')](_0x5cc0df('0x24'),_0x28a505);})[_0x56e906('0x21')](function(_0xc7a7ee){const _0xb9a263=_0x56e906;logger[_0xb9a263('0x2b')](JSON[_0xb9a263('0x19')](_0xc7a7ee));});});},Migration[_0x1ceeeb('0xb')][_0x1ceeeb('0x1')]=function(_0x453dfc,_0x3143ae,_0x213e27){const _0x3ae1c4=_0x1ceeeb,_0x17084a=this;this[_0x3ae1c4('0x1f')][_0x3ae1c4('0x4')](function(){const _0x189ee5=_0x3ae1c4;return _0x17084a['queryInterface'][_0x189ee5('0x1')](_0x453dfc,_0x3143ae,{'indexName':_0x213e27})[_0x189ee5('0x17')](function(){const _0x3f6a96=_0x189ee5;logger[_0x3f6a96('0x2b')](_0x3f6a96('0xc'),_0x453dfc,_0x3143ae[_0x3f6a96('0xf')](','),_0x213e27);})['catch'](function(_0x5922b3){const _0x2fc36c=_0x189ee5;logger[_0x2fc36c('0x2b')](JSON[_0x2fc36c('0x19')](_0x5922b3));});});},Migration[_0x1ceeeb('0xb')][_0x1ceeeb('0x28')]=function(_0x4ac1bf){const _0x49e5f1=_0x1ceeeb,_0x1624b3=this;this['sequence'][_0x49e5f1('0x4')](function(){const _0x3d37a5=_0x49e5f1;return _0x1624b3[_0x3d37a5('0x30')]['sequelize'][_0x3d37a5('0x28')](_0x4ac1bf)['then'](function(){const _0x52e920=_0x3d37a5;logger[_0x52e920('0x2b')](_0x52e920('0xe'),_0x4ac1bf);})[_0x3d37a5('0x21')](function(_0xc04901){logger['info'](JSON['stringify'](_0xc04901));});});},Migration[_0x1ceeeb('0xb')][_0x1ceeeb('0x23')]=function(_0x1c9c25,_0x47d19b){const _0x41b0d0=_0x1ceeeb,_0x36429e=this;this[_0x41b0d0('0x1f')][_0x41b0d0('0x4')](function(){const _0x2f685d=_0x41b0d0;return _0x36429e['queryInterface'][_0x2f685d('0x23')](_0x1c9c25,_0x47d19b)[_0x2f685d('0x17')](function(){const _0x317099=_0x2f685d;logger[_0x317099('0x2b')](_0x317099('0x12'),_0x47d19b,_0x1c9c25);})[_0x2f685d('0x21')](function(_0x40dddd){const _0x2eb843=_0x2f685d;logger['info'](util[_0x2eb843('0x2d')](_0x40dddd,{'showHidden':![],'depth':null}));});});},Migration[_0x1ceeeb('0xb')]['renameColumn']=function(_0x5375b8,_0x64cf9e,_0x4240ca){const _0x357ece=_0x1ceeeb,_0x3ace42=this;this[_0x357ece('0x1f')]['enqueue'](function(){const _0x3fb7fa=_0x357ece;return _0x3ace42['queryInterface']['renameColumn'](_0x5375b8,_0x64cf9e,_0x4240ca)[_0x3fb7fa('0x17')](function(){const _0x4432a9=_0x3fb7fa;logger[_0x4432a9('0x2b')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x64cf9e,_0x4240ca,_0x5375b8);})[_0x3fb7fa('0x21')](function(_0x37e113){const _0x577b17=_0x3fb7fa;logger[_0x577b17('0x2b')](util[_0x577b17('0x2d')](_0x37e113,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x7ca663){const _0x2cbf07=_0x1ceeeb;this[_0x2cbf07('0x1f')][_0x2cbf07('0x4')](function(){return _0x7ca663();});},module[_0x1ceeeb('0x8')]={'up':function(_0x2c816d,_0x18c657){return new Promise(function(_0x5e39ce){const _0x273437=a933_0x2234,_0x464092=new Migration(_0x2c816d);_0x464092['addColumn'](_0x273437('0x11'),_0x273437('0x16'),{'type':_0x18c657[_0x273437('0x25')],'allowNull':![],'defaultValue':_0x273437('0x1b'),'validate':{'notEmpty':!![]}}),_0x464092['addColumn'](_0x273437('0x11'),_0x273437('0x2a'),{'type':_0x18c657[_0x273437('0x6')],'defaultValue':0xf}),_0x464092[_0x273437('0x31')](_0x273437('0x11'),_0x273437('0x2c'),{'type':_0x18c657[_0x273437('0x25')]}),_0x464092['query'](_0x273437('0x32')),_0x464092[_0x273437('0x28')]('UPDATE\x20users\x20SET\x20transport=\x27udp\x27\x20WHERE\x20avpf\x20IS\x20NULL\x20AND\x20transport\x20IS\x20NULL'),_0x464092[_0x273437('0x28')](_0x273437('0x22')),_0x464092['changeColumn'](_0x273437('0x3'),'output',{'type':_0x18c657[_0x273437('0x1d')]('csv',_0x273437('0xa'),_0x273437('0x9'),_0x273437('0x1a')),'allowNull':![],'defaultValue':'csv'}),_0x464092[_0x273437('0x28')](_0x273437('0x26')),_0x464092[_0x273437('0x14')]('tools_schedules',_0x273437('0x0'),{'type':_0x18c657[_0x273437('0x1d')](_0x273437('0x7'),_0x273437('0xa'),_0x273437('0x1a')),'allowNull':![],'defaultValue':_0x273437('0x7')}),_0x464092[_0x273437('0x31')](_0x273437('0x1c'),_0x273437('0x2'),{'type':_0x18c657['BOOLEAN'],'defaultValue':![]}),_0x464092[_0x273437('0x31')](_0x273437('0x1c'),_0x273437('0x1e'),{'type':_0x18c657[_0x273437('0x25')],'allowNull':![],'defaultValue':'Arial,Helvetica,sans-serif'}),_0x464092[_0x273437('0x31')](_0x273437('0x1c'),_0x273437('0x2a'),{'type':_0x18c657[_0x273437('0x6')](0x2)[_0x273437('0x2f')],'defaultValue':0xd,'validate':{'min':0x8,'max':0x48}}),_0x464092[_0x273437('0x13')](_0x273437('0x1c'),_0x273437('0x10'),_0x273437('0x27')),_0x464092[_0x273437('0xd')](_0x5e39ce);});},'down':function(){}}; \ No newline at end of file +const a933_0x25f6=['catch','final','renameColumn','inspect','csv','Added\x20column\x20%s\x20to\x20%s','#ffffff','query','fontSize','info','xls','dropTable','ENUM','addIndex','INTEGER','addColumn','xlsx','template','tools_schedules','migration','queryInterface','fontFamily','exports','stringify','sequence','mail_accounts','removeColumn','UPDATE\x20users\x20SET\x20nat=\x27force_rport,comedia\x27\x20WHERE\x20nat\x20IS\x20NULL','BOOLEAN','tail','output','UPDATE\x20users\x20SET\x20transport=\x27wss\x27\x20WHERE\x20avpf\x20IS\x20NOT\x20NULL','chat_websites','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','then','Arial,Helvetica,sans-serif','prototype','timezone','table\x20dropped\x20%s','markAsUnread','enqueue','addIndex\x20%s\x20%s\x20%s','changeColumn','sequelize','UNSIGNED','STRING'];(function(_0x5ac04d,_0x25f632){const _0x2aa696=function(_0x27cd70){while(--_0x27cd70){_0x5ac04d['push'](_0x5ac04d['shift']());}};_0x2aa696(++_0x25f632);}(a933_0x25f6,0x99));const a933_0x2aa6=function(_0x5ac04d,_0x25f632){_0x5ac04d=_0x5ac04d-0x0;let _0x2aa696=a933_0x25f6[_0x5ac04d];return _0x2aa696;};const _0xbefd15=a933_0x2aa6;'use strict';const util=require('util'),logger=require('../config/logger')(_0xbefd15('0x4')),Sequence=function(){};Sequence[_0xbefd15('0x15')]['enqueue']=function(_0x27cd70){const _0x56bf37=_0xbefd15;this[_0x56bf37('0xe')]=this[_0x56bf37('0xe')]?this[_0x56bf37('0xe')]['finally'](_0x27cd70):_0x27cd70();};const Migration=function(_0x5f3895){const _0x2c0933=_0xbefd15;this[_0x2c0933('0x5')]=_0x5f3895,this[_0x2c0933('0x9')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x3d8d71,_0x9c5d9e,_0x502abb){const _0x25a954=_0xbefd15,_0xcb2029=this;this[_0x25a954('0x9')][_0x25a954('0x19')](function(){const _0xec61eb=_0x25a954;return _0xcb2029[_0xec61eb('0x5')][_0xec61eb('0x1b')](_0x3d8d71,_0x9c5d9e,_0x502abb)[_0xec61eb('0x13')](function(){const _0x2f2588=_0xec61eb;logger[_0x2f2588('0x28')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x9c5d9e,_0x3d8d71);})[_0xec61eb('0x1f')](function(_0x4058f9){const _0x10bf87=_0xec61eb;logger[_0x10bf87('0x28')](JSON['stringify'](_0x4058f9));});});},Migration[_0xbefd15('0x15')]['addColumn']=function(_0xa218e6,_0x164101,_0xbd465c){const _0x30b0a3=_0xbefd15,_0x44db93=this;this[_0x30b0a3('0x9')][_0x30b0a3('0x19')](function(){const _0x23f0e7=_0x30b0a3;return _0x44db93[_0x23f0e7('0x5')]['addColumn'](_0xa218e6,_0x164101,_0xbd465c)[_0x23f0e7('0x13')](function(){const _0x4e04c8=_0x23f0e7;logger[_0x4e04c8('0x28')](_0x4e04c8('0x24'),_0x164101,_0xa218e6);})['catch'](function(_0x4ab223){const _0x372fa3=_0x23f0e7;logger[_0x372fa3('0x28')](JSON[_0x372fa3('0x8')](_0x4ab223));});});},Migration['prototype'][_0xbefd15('0x2a')]=function(_0x27008f){const _0x497c10=_0xbefd15,_0x4f836a=this;this['sequence'][_0x497c10('0x19')](function(){const _0x41887b=_0x497c10;return _0x4f836a[_0x41887b('0x5')][_0x41887b('0x2a')](_0x27008f,{'force':!![]})[_0x41887b('0x13')](function(){const _0x3eafec=_0x41887b;logger['info'](_0x3eafec('0x17'),_0x27008f);})['catch'](function(_0x4ebb47){const _0x4e76b1=_0x41887b;logger[_0x4e76b1('0x28')](JSON[_0x4e76b1('0x8')](_0x4ebb47));});});},Migration[_0xbefd15('0x15')]['addIndex']=function(_0x2e4c73,_0x1526b6,_0x3c26de){const _0x1c8f92=_0xbefd15,_0x2ee83f=this;this['sequence'][_0x1c8f92('0x19')](function(){const _0x17ca44=_0x1c8f92;return _0x2ee83f['queryInterface'][_0x17ca44('0x2c')](_0x2e4c73,_0x1526b6,{'indexName':_0x3c26de})[_0x17ca44('0x13')](function(){const _0x35a945=_0x17ca44;logger[_0x35a945('0x28')](_0x35a945('0x1a'),_0x2e4c73,_0x1526b6['join'](','),_0x3c26de);})[_0x17ca44('0x1f')](function(_0x2412b0){const _0x58bf08=_0x17ca44;logger[_0x58bf08('0x28')](JSON[_0x58bf08('0x8')](_0x2412b0));});});},Migration[_0xbefd15('0x15')][_0xbefd15('0x26')]=function(_0x3ca322){const _0x3b6a9a=_0xbefd15,_0x39b461=this;this[_0x3b6a9a('0x9')][_0x3b6a9a('0x19')](function(){const _0x2d3b9c=_0x3b6a9a;return _0x39b461['queryInterface'][_0x2d3b9c('0x1c')]['query'](_0x3ca322)[_0x2d3b9c('0x13')](function(){logger['info']('query\x20%s',_0x3ca322);})['catch'](function(_0x2c6032){const _0x4a7fd9=_0x2d3b9c;logger['info'](JSON[_0x4a7fd9('0x8')](_0x2c6032));});});},Migration[_0xbefd15('0x15')][_0xbefd15('0xb')]=function(_0x13bcbe,_0x68f38c){const _0x5d93d9=_0xbefd15,_0x285735=this;this[_0x5d93d9('0x9')][_0x5d93d9('0x19')](function(){const _0x3ec7ba=_0x5d93d9;return _0x285735[_0x3ec7ba('0x5')][_0x3ec7ba('0xb')](_0x13bcbe,_0x68f38c)[_0x3ec7ba('0x13')](function(){const _0x505ee7=_0x3ec7ba;logger[_0x505ee7('0x28')]('Removed\x20column\x20%s\x20from\x20%s',_0x68f38c,_0x13bcbe);})[_0x3ec7ba('0x1f')](function(_0x1bcac1){const _0x8dae1=_0x3ec7ba;logger[_0x8dae1('0x28')](util[_0x8dae1('0x22')](_0x1bcac1,{'showHidden':![],'depth':null}));});});},Migration[_0xbefd15('0x15')]['renameColumn']=function(_0x36c575,_0x3c69a8,_0x371e55){const _0x5c86bc=_0xbefd15,_0x15ceb6=this;this['sequence'][_0x5c86bc('0x19')](function(){const _0x3631e1=_0x5c86bc;return _0x15ceb6[_0x3631e1('0x5')][_0x3631e1('0x21')](_0x36c575,_0x3c69a8,_0x371e55)[_0x3631e1('0x13')](function(){const _0x58f37e=_0x3631e1;logger[_0x58f37e('0x28')](_0x58f37e('0x12'),_0x3c69a8,_0x371e55,_0x36c575);})[_0x3631e1('0x1f')](function(_0x2aa4a5){const _0xddc680=_0x3631e1;logger[_0xddc680('0x28')](util[_0xddc680('0x22')](_0x2aa4a5,{'showHidden':![],'depth':null}));});});},Migration[_0xbefd15('0x15')][_0xbefd15('0x20')]=function(_0x21f0d0){const _0x711712=_0xbefd15;this[_0x711712('0x9')]['enqueue'](function(){return _0x21f0d0();});},module[_0xbefd15('0x7')]={'up':function(_0x38c9fd,_0x50b61c){return new Promise(function(_0x460156){const _0x5d13a0=a933_0x2aa6,_0x485bac=new Migration(_0x38c9fd);_0x485bac[_0x5d13a0('0x0')](_0x5d13a0('0x11'),'textColor',{'type':_0x50b61c['STRING'],'allowNull':![],'defaultValue':_0x5d13a0('0x25'),'validate':{'notEmpty':!![]}}),_0x485bac['addColumn'](_0x5d13a0('0x11'),_0x5d13a0('0x27'),{'type':_0x50b61c[_0x5d13a0('0x2d')],'defaultValue':0xf}),_0x485bac[_0x5d13a0('0x0')](_0x5d13a0('0x11'),_0x5d13a0('0x16'),{'type':_0x50b61c[_0x5d13a0('0x1e')]}),_0x485bac['query'](_0x5d13a0('0xc')),_0x485bac[_0x5d13a0('0x26')]('UPDATE\x20users\x20SET\x20transport=\x27udp\x27\x20WHERE\x20avpf\x20IS\x20NULL\x20AND\x20transport\x20IS\x20NULL'),_0x485bac[_0x5d13a0('0x26')](_0x5d13a0('0x10')),_0x485bac[_0x5d13a0('0x1b')](_0x5d13a0('0x3'),'output',{'type':_0x50b61c[_0x5d13a0('0x2b')]('csv','pdf',_0x5d13a0('0x29'),_0x5d13a0('0x1')),'allowNull':![],'defaultValue':_0x5d13a0('0x23')}),_0x485bac[_0x5d13a0('0x26')]('UPDATE\x20tools_schedules\x20SET\x20output=\x27xlsx\x27\x20WHERE\x20output=\x27xls\x27'),_0x485bac['changeColumn'](_0x5d13a0('0x3'),_0x5d13a0('0xf'),{'type':_0x50b61c[_0x5d13a0('0x2b')](_0x5d13a0('0x23'),'pdf',_0x5d13a0('0x1')),'allowNull':![],'defaultValue':_0x5d13a0('0x23')}),_0x485bac[_0x5d13a0('0x0')](_0x5d13a0('0xa'),_0x5d13a0('0x18'),{'type':_0x50b61c[_0x5d13a0('0xd')],'defaultValue':![]}),_0x485bac['addColumn'](_0x5d13a0('0xa'),_0x5d13a0('0x6'),{'type':_0x50b61c[_0x5d13a0('0x1e')],'allowNull':![],'defaultValue':_0x5d13a0('0x14')}),_0x485bac[_0x5d13a0('0x0')]('mail_accounts','fontSize',{'type':_0x50b61c[_0x5d13a0('0x2d')](0x2)[_0x5d13a0('0x1d')],'defaultValue':0xd,'validate':{'min':0x8,'max':0x48}}),_0x485bac[_0x5d13a0('0x21')](_0x5d13a0('0xa'),'signature',_0x5d13a0('0x2')),_0x485bac[_0x5d13a0('0x20')](_0x460156);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.55.js b/server/migrations/2.0.55.js index 44823cd..a6158d5 100644 --- a/server/migrations/2.0.55.js +++ b/server/migrations/2.0.55.js @@ -1 +1 @@ -const a934_0x23a1=['then','Removed\x20column\x20%s\x20from\x20%s','addIndex','addIndex\x20%s\x20%s\x20%s','table\x20dropped\x20%s','migration','query\x20%s','join','prototype','query','final','enqueue','inspect','info','renameColumn','changeColumn','../config/logger','finally','catch','Changed\x20column\x20%s\x20in\x20table\x20%s','exports','dropTable','tail','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','sequence','removeColumn','Added\x20column\x20%s\x20to\x20%s','util','stringify','CREATE\x20TABLE\x20`mail_substatuses`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20\x20`name`\x20varchar(255)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`description`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name`\x20(`name`)\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','INSERT\x20INTO\x20`mail_substatuses`\x20(`name`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27pending\x27,\x20\x27Pending\x20status\x20for\x20mail\x20interaction\x27,\x20NOW(),\x20NOW());','queryInterface','addColumn'];(function(_0xc6de80,_0x23a131){const _0x4d91e6=function(_0x1b8119){while(--_0x1b8119){_0xc6de80['push'](_0xc6de80['shift']());}};_0x4d91e6(++_0x23a131);}(a934_0x23a1,0x77));const a934_0x4d91=function(_0xc6de80,_0x23a131){_0xc6de80=_0xc6de80-0x0;let _0x4d91e6=a934_0x23a1[_0xc6de80];return _0x4d91e6;};const _0xc3a6c2=a934_0x4d91;'use strict';const util=require(_0xc3a6c2('0x7')),logger=require(_0xc3a6c2('0x1d'))(_0xc3a6c2('0x12')),Sequence=function(){};Sequence[_0xc3a6c2('0x15')][_0xc3a6c2('0x18')]=function(_0x1b8119){const _0x33142d=_0xc3a6c2;this['tail']=this[_0x33142d('0x2')]?this['tail'][_0x33142d('0x1e')](_0x1b8119):_0x1b8119();};const Migration=function(_0x51435d){const _0x199913=_0xc3a6c2;this[_0x199913('0xb')]=_0x51435d,this[_0x199913('0x4')]=new Sequence();};Migration[_0xc3a6c2('0x15')]['changeColumn']=function(_0x399c6e,_0x26dfd0,_0x1a7750){const _0x4064ff=_0xc3a6c2,_0x14ca37=this;this[_0x4064ff('0x4')]['enqueue'](function(){const _0x35dbe4=_0x4064ff;return _0x14ca37[_0x35dbe4('0xb')][_0x35dbe4('0x1c')](_0x399c6e,_0x26dfd0,_0x1a7750)['then'](function(){const _0x1e5c28=_0x35dbe4;logger[_0x1e5c28('0x1a')](_0x1e5c28('0x20'),_0x26dfd0,_0x399c6e);})['catch'](function(_0xd7aff5){const _0x4ffabc=_0x35dbe4;logger[_0x4ffabc('0x1a')](JSON[_0x4ffabc('0x8')](_0xd7aff5));});});},Migration[_0xc3a6c2('0x15')]['addColumn']=function(_0x4730d6,_0x392aef,_0x4a3c23){const _0x42570f=_0xc3a6c2,_0x2938b0=this;this[_0x42570f('0x4')]['enqueue'](function(){const _0x424027=_0x42570f;return _0x2938b0[_0x424027('0xb')][_0x424027('0xc')](_0x4730d6,_0x392aef,_0x4a3c23)[_0x424027('0xd')](function(){const _0x24a2a1=_0x424027;logger[_0x24a2a1('0x1a')](_0x24a2a1('0x6'),_0x392aef,_0x4730d6);})[_0x424027('0x1f')](function(_0x1236af){const _0x4aeb7f=_0x424027;logger[_0x4aeb7f('0x1a')](JSON[_0x4aeb7f('0x8')](_0x1236af));});});},Migration['prototype'][_0xc3a6c2('0x1')]=function(_0x50dbe3){const _0x300bbe=_0xc3a6c2,_0x2954ce=this;this[_0x300bbe('0x4')][_0x300bbe('0x18')](function(){const _0x219d74=_0x300bbe;return _0x2954ce[_0x219d74('0xb')][_0x219d74('0x1')](_0x50dbe3,{'force':!![]})[_0x219d74('0xd')](function(){const _0x43adf9=_0x219d74;logger[_0x43adf9('0x1a')](_0x43adf9('0x11'),_0x50dbe3);})[_0x219d74('0x1f')](function(_0x283c4e){const _0x556506=_0x219d74;logger[_0x556506('0x1a')](JSON[_0x556506('0x8')](_0x283c4e));});});},Migration[_0xc3a6c2('0x15')][_0xc3a6c2('0xf')]=function(_0x4af5ac,_0x26dacf,_0x33e172){const _0x289490=_0xc3a6c2,_0x445fa9=this;this[_0x289490('0x4')][_0x289490('0x18')](function(){const _0x5498ee=_0x289490;return _0x445fa9['queryInterface'][_0x5498ee('0xf')](_0x4af5ac,_0x26dacf,{'indexName':_0x33e172})[_0x5498ee('0xd')](function(){const _0x1aceb1=_0x5498ee;logger[_0x1aceb1('0x1a')](_0x1aceb1('0x10'),_0x4af5ac,_0x26dacf[_0x1aceb1('0x14')](','),_0x33e172);})[_0x5498ee('0x1f')](function(_0x53c8e1){const _0x4f69b9=_0x5498ee;logger[_0x4f69b9('0x1a')](JSON[_0x4f69b9('0x8')](_0x53c8e1));});});},Migration[_0xc3a6c2('0x15')][_0xc3a6c2('0x16')]=function(_0x2cfbc1){const _0x5875e0=_0xc3a6c2,_0x29326c=this;this[_0x5875e0('0x4')]['enqueue'](function(){const _0x44d86a=_0x5875e0;return _0x29326c[_0x44d86a('0xb')]['sequelize'][_0x44d86a('0x16')](_0x2cfbc1)[_0x44d86a('0xd')](function(){const _0x44a886=_0x44d86a;logger[_0x44a886('0x1a')](_0x44a886('0x13'),_0x2cfbc1);})['catch'](function(_0x13a258){const _0x131509=_0x44d86a;logger[_0x131509('0x1a')](JSON[_0x131509('0x8')](_0x13a258));});});},Migration['prototype'][_0xc3a6c2('0x5')]=function(_0x16c0a5,_0x43e439){const _0x38cf82=_0xc3a6c2,_0x1fcd5b=this;this[_0x38cf82('0x4')][_0x38cf82('0x18')](function(){const _0x3a52da=_0x38cf82;return _0x1fcd5b['queryInterface'][_0x3a52da('0x5')](_0x16c0a5,_0x43e439)['then'](function(){const _0x30a018=_0x3a52da;logger[_0x30a018('0x1a')](_0x30a018('0xe'),_0x43e439,_0x16c0a5);})['catch'](function(_0x57581b){const _0x4a9e42=_0x3a52da;logger[_0x4a9e42('0x1a')](util['inspect'](_0x57581b,{'showHidden':![],'depth':null}));});});},Migration[_0xc3a6c2('0x15')][_0xc3a6c2('0x1b')]=function(_0x354f15,_0x35ea5f,_0x5436a4){const _0x47d2ac=_0xc3a6c2,_0x37dbcf=this;this[_0x47d2ac('0x4')][_0x47d2ac('0x18')](function(){const _0x35834c=_0x47d2ac;return _0x37dbcf['queryInterface'][_0x35834c('0x1b')](_0x354f15,_0x35ea5f,_0x5436a4)[_0x35834c('0xd')](function(){const _0x1131b3=_0x35834c;logger['info'](_0x1131b3('0x3'),_0x35ea5f,_0x5436a4,_0x354f15);})[_0x35834c('0x1f')](function(_0x5cd402){const _0x440ebe=_0x35834c;logger[_0x440ebe('0x1a')](util[_0x440ebe('0x19')](_0x5cd402,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0xc3a6c2('0x17')]=function(_0x4a956c){const _0x4d655e=_0xc3a6c2;this[_0x4d655e('0x4')]['enqueue'](function(){return _0x4a956c();});},module[_0xc3a6c2('0x0')]={'up':function(_0x154858,_0x358379){return new Promise(function(_0x505243){const _0x52a3c5=a934_0x4d91,_0x396a5f=new Migration(_0x154858);_0x396a5f['addColumn']('sms_accounts','authId',{'type':_0x358379['STRING']}),_0x396a5f[_0x52a3c5('0x16')](_0x52a3c5('0x9')),_0x396a5f['query'](_0x52a3c5('0xa')),_0x396a5f['final'](_0x505243);});},'down':function(){}}; \ No newline at end of file +const a934_0x3079=['Changed\x20column\x20%s\x20in\x20table\x20%s','tail','join','addColumn','enqueue','renameColumn','INSERT\x20INTO\x20`mail_substatuses`\x20(`name`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27pending\x27,\x20\x27Pending\x20status\x20for\x20mail\x20interaction\x27,\x20NOW(),\x20NOW());','catch','../config/logger','stringify','table\x20dropped\x20%s','STRING','removeColumn','queryInterface','addIndex\x20%s\x20%s\x20%s','Added\x20column\x20%s\x20to\x20%s','sequelize','changeColumn','authId','info','inspect','sequence','dropTable','prototype','migration','final','exports','then','query','addIndex','CREATE\x20TABLE\x20`mail_substatuses`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20\x20`name`\x20varchar(255)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`description`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name`\x20(`name`)\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;'];(function(_0x451c31,_0x3079cb){const _0x146b0a=function(_0xbb2401){while(--_0xbb2401){_0x451c31['push'](_0x451c31['shift']());}};_0x146b0a(++_0x3079cb);}(a934_0x3079,0x13f));const a934_0x146b=function(_0x451c31,_0x3079cb){_0x451c31=_0x451c31-0x0;let _0x146b0a=a934_0x3079[_0x451c31];return _0x146b0a;};const _0x39fad1=a934_0x146b;'use strict';const util=require('util'),logger=require(_0x39fad1('0x1e'))(_0x39fad1('0xf')),Sequence=function(){};Sequence[_0x39fad1('0xe')][_0x39fad1('0x1a')]=function(_0xbb2401){const _0x14d3ca=_0x39fad1;this[_0x14d3ca('0x17')]=this[_0x14d3ca('0x17')]?this['tail']['finally'](_0xbb2401):_0xbb2401();};const Migration=function(_0x1cc8a6){const _0x2b5729=_0x39fad1;this[_0x2b5729('0x4')]=_0x1cc8a6,this[_0x2b5729('0xc')]=new Sequence();};Migration[_0x39fad1('0xe')][_0x39fad1('0x8')]=function(_0x177624,_0x5d45fa,_0x3252c4){const _0x241a3b=_0x39fad1,_0x385a60=this;this[_0x241a3b('0xc')][_0x241a3b('0x1a')](function(){const _0x4c8955=_0x241a3b;return _0x385a60[_0x4c8955('0x4')][_0x4c8955('0x8')](_0x177624,_0x5d45fa,_0x3252c4)[_0x4c8955('0x12')](function(){const _0x1506fa=_0x4c8955;logger[_0x1506fa('0xa')](_0x1506fa('0x16'),_0x5d45fa,_0x177624);})[_0x4c8955('0x1d')](function(_0x16d59f){const _0x8a36a5=_0x4c8955;logger[_0x8a36a5('0xa')](JSON[_0x8a36a5('0x0')](_0x16d59f));});});},Migration[_0x39fad1('0xe')][_0x39fad1('0x19')]=function(_0x52b6f2,_0x210a28,_0x25420e){const _0xdd2293=_0x39fad1,_0x24c49a=this;this[_0xdd2293('0xc')][_0xdd2293('0x1a')](function(){const _0x5eb513=_0xdd2293;return _0x24c49a[_0x5eb513('0x4')][_0x5eb513('0x19')](_0x52b6f2,_0x210a28,_0x25420e)['then'](function(){const _0x497841=_0x5eb513;logger[_0x497841('0xa')](_0x497841('0x6'),_0x210a28,_0x52b6f2);})[_0x5eb513('0x1d')](function(_0x47cb4a){const _0x3f9323=_0x5eb513;logger['info'](JSON[_0x3f9323('0x0')](_0x47cb4a));});});},Migration[_0x39fad1('0xe')][_0x39fad1('0xd')]=function(_0x381c90){const _0x159b24=_0x39fad1,_0x19dfb9=this;this['sequence'][_0x159b24('0x1a')](function(){const _0x4414a9=_0x159b24;return _0x19dfb9['queryInterface'][_0x4414a9('0xd')](_0x381c90,{'force':!![]})[_0x4414a9('0x12')](function(){const _0x5e9642=_0x4414a9;logger[_0x5e9642('0xa')](_0x5e9642('0x1'),_0x381c90);})[_0x4414a9('0x1d')](function(_0x30b7db){const _0x2cbcad=_0x4414a9;logger[_0x2cbcad('0xa')](JSON[_0x2cbcad('0x0')](_0x30b7db));});});},Migration[_0x39fad1('0xe')][_0x39fad1('0x14')]=function(_0x5aaabb,_0x2b6c2a,_0x6f6d0a){const _0x128072=_0x39fad1,_0x33b23c=this;this[_0x128072('0xc')][_0x128072('0x1a')](function(){const _0x2f9de8=_0x128072;return _0x33b23c[_0x2f9de8('0x4')][_0x2f9de8('0x14')](_0x5aaabb,_0x2b6c2a,{'indexName':_0x6f6d0a})[_0x2f9de8('0x12')](function(){const _0x53a15f=_0x2f9de8;logger[_0x53a15f('0xa')](_0x53a15f('0x5'),_0x5aaabb,_0x2b6c2a[_0x53a15f('0x18')](','),_0x6f6d0a);})[_0x2f9de8('0x1d')](function(_0x308c4f){const _0x47947=_0x2f9de8;logger[_0x47947('0xa')](JSON[_0x47947('0x0')](_0x308c4f));});});},Migration[_0x39fad1('0xe')][_0x39fad1('0x13')]=function(_0x4338fa){const _0x2512e3=_0x39fad1,_0x34322c=this;this['sequence'][_0x2512e3('0x1a')](function(){const _0x358454=_0x2512e3;return _0x34322c[_0x358454('0x4')][_0x358454('0x7')]['query'](_0x4338fa)[_0x358454('0x12')](function(){const _0x42a051=_0x358454;logger[_0x42a051('0xa')]('query\x20%s',_0x4338fa);})[_0x358454('0x1d')](function(_0x33f3d6){logger['info'](JSON['stringify'](_0x33f3d6));});});},Migration['prototype'][_0x39fad1('0x3')]=function(_0x32695e,_0x1c478d){const _0x4a98c3=_0x39fad1,_0x190e79=this;this[_0x4a98c3('0xc')][_0x4a98c3('0x1a')](function(){const _0x5836c6=_0x4a98c3;return _0x190e79['queryInterface'][_0x5836c6('0x3')](_0x32695e,_0x1c478d)[_0x5836c6('0x12')](function(){const _0x266793=_0x5836c6;logger[_0x266793('0xa')]('Removed\x20column\x20%s\x20from\x20%s',_0x1c478d,_0x32695e);})[_0x5836c6('0x1d')](function(_0x54a06e){const _0x5bcbc9=_0x5836c6;logger[_0x5bcbc9('0xa')](util[_0x5bcbc9('0xb')](_0x54a06e,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x39fad1('0x1b')]=function(_0x33f001,_0x49f5b4,_0x3a8580){const _0x12acc4=_0x39fad1,_0x18b4ef=this;this[_0x12acc4('0xc')]['enqueue'](function(){const _0x40ca17=_0x12acc4;return _0x18b4ef[_0x40ca17('0x4')][_0x40ca17('0x1b')](_0x33f001,_0x49f5b4,_0x3a8580)[_0x40ca17('0x12')](function(){const _0x2311fd=_0x40ca17;logger[_0x2311fd('0xa')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x49f5b4,_0x3a8580,_0x33f001);})[_0x40ca17('0x1d')](function(_0x551c42){const _0x425a0e=_0x40ca17;logger['info'](util[_0x425a0e('0xb')](_0x551c42,{'showHidden':![],'depth':null}));});});},Migration[_0x39fad1('0xe')][_0x39fad1('0x10')]=function(_0xae10bc){const _0x4c4086=_0x39fad1;this[_0x4c4086('0xc')]['enqueue'](function(){return _0xae10bc();});},module[_0x39fad1('0x11')]={'up':function(_0x1669f9,_0x394fcf){return new Promise(function(_0x5d1300){const _0x1637f1=a934_0x146b,_0x572d09=new Migration(_0x1669f9);_0x572d09[_0x1637f1('0x19')]('sms_accounts',_0x1637f1('0x9'),{'type':_0x394fcf[_0x1637f1('0x2')]}),_0x572d09[_0x1637f1('0x13')](_0x1637f1('0x15')),_0x572d09[_0x1637f1('0x13')](_0x1637f1('0x1c')),_0x572d09[_0x1637f1('0x10')](_0x5d1300);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.56.js b/server/migrations/2.0.56.js index ce9296a..2d145bc 100644 --- a/server/migrations/2.0.56.js +++ b/server/migrations/2.0.56.js @@ -1 +1 @@ -const a935_0x39e3=['UPDATE\x20fax_accounts\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}\x27','tail','migration','addIndex\x20%s\x20%s\x20%s','sms_accounts','enqueue','query','info','catch','UPDATE\x20chat_websites\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}\x27','queryInterface','voice_queues','STRING','final','roundrobin','finally','Added\x20column\x20%s\x20to\x20%s','addIndex','linear','mail_accounts','leastrecent','then','notificationShake','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','notificationTemplate','Removed\x20column\x20%s\x20from\x20%s','changeColumn','prototype','TEXT','wrandom','UPDATE\x20mail_accounts\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}
Subject\x20:\x20{{message.subject}}\x27','sequelize','UPDATE\x20openchannel_accounts\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}\x27','inspect','sequence','basename','Changed\x20column\x20%s\x20in\x20table\x20%s','fax_accounts','addColumn','util','BOOLEAN','ENUM','dropTable','rrordered','stringify','query\x20%s','removeColumn','ringall','chat_websites','openchannel_accounts','strategy','fewestcalls','notificationSound'];(function(_0xd85171,_0x39e340){const _0xa5ca1=function(_0x161580){while(--_0x161580){_0xd85171['push'](_0xd85171['shift']());}};_0xa5ca1(++_0x39e340);}(a935_0x39e3,0x107));const a935_0xa5ca=function(_0xd85171,_0x39e340){_0xd85171=_0xd85171-0x0;let _0xa5ca1=a935_0x39e3[_0xd85171];return _0xa5ca1;};const _0x49fd0b=a935_0xa5ca;'use strict';const util=require(_0x49fd0b('0x29')),logger=require('../config/logger')(_0x49fd0b('0x4')),Sequence=function(){};Sequence['prototype'][_0x49fd0b('0x7')]=function(_0x161580){const _0x33fc5c=_0x49fd0b;this[_0x33fc5c('0x3')]=this['tail']?this['tail'][_0x33fc5c('0x11')](_0x161580):_0x161580();};const Migration=function(_0x5f33eb){const _0x41f15f=_0x49fd0b;this[_0x41f15f('0xc')]=_0x5f33eb,this['sequence']=new Sequence();};Migration['prototype'][_0x49fd0b('0x1c')]=function(_0x37c6ac,_0x43c886,_0x12a07a){const _0x5112a5=_0x49fd0b,_0x4a1160=this;this[_0x5112a5('0x24')]['enqueue'](function(){const _0x1ad223=_0x5112a5;return _0x4a1160[_0x1ad223('0xc')][_0x1ad223('0x1c')](_0x37c6ac,_0x43c886,_0x12a07a)[_0x1ad223('0x17')](function(){const _0x24fabc=_0x1ad223;logger[_0x24fabc('0x9')](_0x24fabc('0x26'),_0x43c886,_0x37c6ac);})[_0x1ad223('0xa')](function(_0x5d1cb5){const _0x18a17c=_0x1ad223;logger[_0x18a17c('0x9')](JSON[_0x18a17c('0x2e')](_0x5d1cb5));});});},Migration[_0x49fd0b('0x1d')][_0x49fd0b('0x28')]=function(_0x1d4575,_0x2f1d26,_0x580838){const _0x13f87f=_0x49fd0b,_0x39bf90=this;this['sequence'][_0x13f87f('0x7')](function(){const _0x2492f5=_0x13f87f;return _0x39bf90[_0x2492f5('0xc')][_0x2492f5('0x28')](_0x1d4575,_0x2f1d26,_0x580838)[_0x2492f5('0x17')](function(){const _0x4bc571=_0x2492f5;logger[_0x4bc571('0x9')](_0x4bc571('0x12'),_0x2f1d26,_0x1d4575);})[_0x2492f5('0xa')](function(_0x305724){const _0x1173e1=_0x2492f5;logger['info'](JSON[_0x1173e1('0x2e')](_0x305724));});});},Migration[_0x49fd0b('0x1d')][_0x49fd0b('0x2c')]=function(_0x3a1bf4){const _0x326555=_0x49fd0b,_0x59dcbe=this;this[_0x326555('0x24')][_0x326555('0x7')](function(){const _0x546c52=_0x326555;return _0x59dcbe[_0x546c52('0xc')][_0x546c52('0x2c')](_0x3a1bf4,{'force':!![]})[_0x546c52('0x17')](function(){const _0x223717=_0x546c52;logger[_0x223717('0x9')]('table\x20dropped\x20%s',_0x3a1bf4);})[_0x546c52('0xa')](function(_0xb0cea6){const _0x18c4b2=_0x546c52;logger[_0x18c4b2('0x9')](JSON['stringify'](_0xb0cea6));});});},Migration[_0x49fd0b('0x1d')]['addIndex']=function(_0x5c4cfd,_0x1d5e14,_0x546c87){const _0x7620bb=_0x49fd0b,_0x298cc0=this;this[_0x7620bb('0x24')][_0x7620bb('0x7')](function(){const _0x4085d5=_0x7620bb;return _0x298cc0['queryInterface'][_0x4085d5('0x13')](_0x5c4cfd,_0x1d5e14,{'indexName':_0x546c87})['then'](function(){const _0x39ecb1=_0x4085d5;logger['info'](_0x39ecb1('0x5'),_0x5c4cfd,_0x1d5e14['join'](','),_0x546c87);})[_0x4085d5('0xa')](function(_0x13dcc2){const _0xba35c=_0x4085d5;logger[_0xba35c('0x9')](JSON[_0xba35c('0x2e')](_0x13dcc2));});});},Migration[_0x49fd0b('0x1d')]['query']=function(_0x15a50a){const _0x9444cc=this;this['sequence']['enqueue'](function(){const _0x7b8d8e=a935_0xa5ca;return _0x9444cc[_0x7b8d8e('0xc')][_0x7b8d8e('0x21')][_0x7b8d8e('0x8')](_0x15a50a)[_0x7b8d8e('0x17')](function(){const _0x24dcda=_0x7b8d8e;logger[_0x24dcda('0x9')](_0x24dcda('0x2f'),_0x15a50a);})[_0x7b8d8e('0xa')](function(_0x6b9fdc){const _0x23811a=_0x7b8d8e;logger[_0x23811a('0x9')](JSON[_0x23811a('0x2e')](_0x6b9fdc));});});},Migration[_0x49fd0b('0x1d')][_0x49fd0b('0x30')]=function(_0x131417,_0x184e63){const _0x5ad85f=_0x49fd0b,_0x343a61=this;this[_0x5ad85f('0x24')][_0x5ad85f('0x7')](function(){const _0x87ee69=_0x5ad85f;return _0x343a61[_0x87ee69('0xc')]['removeColumn'](_0x131417,_0x184e63)[_0x87ee69('0x17')](function(){const _0x16e967=_0x87ee69;logger[_0x16e967('0x9')](_0x16e967('0x1b'),_0x184e63,_0x131417);})['catch'](function(_0x4c9415){const _0x4e9e57=_0x87ee69;logger[_0x4e9e57('0x9')](util[_0x4e9e57('0x23')](_0x4c9415,{'showHidden':![],'depth':null}));});});},Migration['prototype']['renameColumn']=function(_0x50c5e4,_0x4448fb,_0x5c0b0f){const _0x22864f=_0x49fd0b,_0x28d23c=this;this['sequence'][_0x22864f('0x7')](function(){const _0x513025=_0x22864f;return _0x28d23c['queryInterface']['renameColumn'](_0x50c5e4,_0x4448fb,_0x5c0b0f)[_0x513025('0x17')](function(){const _0x59eefe=_0x513025;logger[_0x59eefe('0x9')](_0x59eefe('0x19'),_0x4448fb,_0x5c0b0f,_0x50c5e4);})['catch'](function(_0x49c7b){const _0x12e110=_0x513025;logger[_0x12e110('0x9')](util[_0x12e110('0x23')](_0x49c7b,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x49fd0b('0xf')]=function(_0x4367a6){const _0x4c26d5=_0x49fd0b;this[_0x4c26d5('0x24')][_0x4c26d5('0x7')](function(){return _0x4367a6();});},module['exports']={'up':function(_0x1dfbb6,_0x91ff16){return new Promise(function(_0x1afa39){const _0x4ce042=a935_0xa5ca,_0x15b7bf=new Migration(_0x1dfbb6);_0x15b7bf['changeColumn'](_0x4ce042('0xd'),_0x4ce042('0x34'),{'type':_0x91ff16[_0x4ce042('0x2b')](_0x4ce042('0x10'),_0x4ce042('0x31'),_0x4ce042('0x16'),_0x4ce042('0x0'),'random','rrmemory',_0x4ce042('0x14'),_0x4ce042('0x1f'),_0x4ce042('0x2d')),'allowNull':![],'defaultValue':_0x4ce042('0x31')}),_0x15b7bf[_0x4ce042('0x28')]('analytics_extracted_reports',_0x4ce042('0x25'),{'type':_0x91ff16[_0x4ce042('0xe')],'allowNull':![]}),_0x15b7bf[_0x4ce042('0x28')]('mail_accounts',_0x4ce042('0x1a'),{'type':_0x91ff16[_0x4ce042('0x1e')]}),_0x15b7bf[_0x4ce042('0x28')](_0x4ce042('0x15'),'notificationSound',{'type':_0x91ff16[_0x4ce042('0x2a')],'defaultValue':!![]}),_0x15b7bf[_0x4ce042('0x28')](_0x4ce042('0x15'),_0x4ce042('0x18'),{'type':_0x91ff16[_0x4ce042('0x2a')],'defaultValue':![]}),_0x15b7bf['addColumn'](_0x4ce042('0x32'),'notificationTemplate',{'type':_0x91ff16[_0x4ce042('0x1e')]}),_0x15b7bf[_0x4ce042('0x28')](_0x4ce042('0x32'),_0x4ce042('0x1'),{'type':_0x91ff16[_0x4ce042('0x2a')],'defaultValue':!![]}),_0x15b7bf[_0x4ce042('0x28')](_0x4ce042('0x32'),'notificationShake',{'type':_0x91ff16['BOOLEAN'],'defaultValue':![]}),_0x15b7bf[_0x4ce042('0x28')]('fax_accounts',_0x4ce042('0x1a'),{'type':_0x91ff16[_0x4ce042('0x1e')]}),_0x15b7bf[_0x4ce042('0x28')](_0x4ce042('0x27'),_0x4ce042('0x1'),{'type':_0x91ff16[_0x4ce042('0x2a')],'defaultValue':!![]}),_0x15b7bf[_0x4ce042('0x28')](_0x4ce042('0x27'),_0x4ce042('0x18'),{'type':_0x91ff16['BOOLEAN'],'defaultValue':![]}),_0x15b7bf['addColumn'](_0x4ce042('0x6'),'notificationTemplate',{'type':_0x91ff16[_0x4ce042('0x1e')]}),_0x15b7bf[_0x4ce042('0x28')](_0x4ce042('0x6'),_0x4ce042('0x1'),{'type':_0x91ff16[_0x4ce042('0x2a')],'defaultValue':!![]}),_0x15b7bf[_0x4ce042('0x28')]('sms_accounts',_0x4ce042('0x18'),{'type':_0x91ff16['BOOLEAN'],'defaultValue':![]}),_0x15b7bf[_0x4ce042('0x28')](_0x4ce042('0x33'),_0x4ce042('0x1a'),{'type':_0x91ff16[_0x4ce042('0x1e')]}),_0x15b7bf[_0x4ce042('0x28')]('openchannel_accounts',_0x4ce042('0x1'),{'type':_0x91ff16[_0x4ce042('0x2a')],'defaultValue':!![]}),_0x15b7bf[_0x4ce042('0x28')]('openchannel_accounts','notificationShake',{'type':_0x91ff16['BOOLEAN'],'defaultValue':![]}),_0x15b7bf[_0x4ce042('0x8')](_0x4ce042('0xb')),_0x15b7bf[_0x4ce042('0x8')](_0x4ce042('0x20')),_0x15b7bf[_0x4ce042('0x8')]('UPDATE\x20sms_accounts\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}\x27'),_0x15b7bf[_0x4ce042('0x8')](_0x4ce042('0x2')),_0x15b7bf[_0x4ce042('0x8')](_0x4ce042('0x22')),_0x15b7bf[_0x4ce042('0xf')](_0x1afa39);});},'down':function(){}}; \ No newline at end of file +const a935_0x33a5=['UPDATE\x20mail_accounts\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}
Subject\x20:\x20{{message.subject}}\x27','addIndex','notificationShake','STRING','BOOLEAN','sequence','UPDATE\x20openchannel_accounts\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}\x27','openchannel_accounts','leastrecent','mail_accounts','query\x20%s','catch','Changed\x20column\x20%s\x20in\x20table\x20%s','../config/logger','renameColumn','migration','stringify','then','dropTable','wrandom','fax_accounts','TEXT','UPDATE\x20chat_websites\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}\x27','info','tail','changeColumn','random','query','roundrobin','chat_websites','basename','strategy','UPDATE\x20sms_accounts\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}\x27','linear','addColumn','analytics_extracted_reports','ringall','sms_accounts','UPDATE\x20fax_accounts\x20SET\x20notificationTemplate=\x27Account:\x20{{account.name}}
{{#queue}}Queue:\x20{{queue.name}}
{{/queue}}From\x20:\x20{{from}}\x27','addIndex\x20%s\x20%s\x20%s','final','Removed\x20column\x20%s\x20from\x20%s','notificationTemplate','prototype','inspect','Added\x20column\x20%s\x20to\x20%s','finally','notificationSound','enqueue','table\x20dropped\x20%s','queryInterface','voice_queues'];(function(_0x2a25b4,_0x33a588){const _0x5260f7=function(_0x296d26){while(--_0x296d26){_0x2a25b4['push'](_0x2a25b4['shift']());}};_0x5260f7(++_0x33a588);}(a935_0x33a5,0xc9));const a935_0x5260=function(_0x2a25b4,_0x33a588){_0x2a25b4=_0x2a25b4-0x0;let _0x5260f7=a935_0x33a5[_0x2a25b4];return _0x5260f7;};const _0x297e87=a935_0x5260;'use strict';const util=require('util'),logger=require(_0x297e87('0x14'))(_0x297e87('0x16')),Sequence=function(){};Sequence[_0x297e87('0x32')]['enqueue']=function(_0x296d26){const _0x5ad180=_0x297e87;this[_0x5ad180('0x1f')]=this[_0x5ad180('0x1f')]?this['tail'][_0x5ad180('0x1')](_0x296d26):_0x296d26();};const Migration=function(_0x3ce690){const _0x4e985a=_0x297e87;this[_0x4e985a('0x5')]=_0x3ce690,this[_0x4e985a('0xc')]=new Sequence();};Migration[_0x297e87('0x32')][_0x297e87('0x20')]=function(_0x3bd079,_0x556cf1,_0x13edd6){const _0x401d8e=_0x297e87,_0x11f834=this;this[_0x401d8e('0xc')][_0x401d8e('0x3')](function(){const _0x46fd40=_0x401d8e;return _0x11f834[_0x46fd40('0x5')][_0x46fd40('0x20')](_0x3bd079,_0x556cf1,_0x13edd6)[_0x46fd40('0x18')](function(){const _0x22d45b=_0x46fd40;logger[_0x22d45b('0x1e')](_0x22d45b('0x13'),_0x556cf1,_0x3bd079);})[_0x46fd40('0x12')](function(_0x5a424f){const _0x5a7a6c=_0x46fd40;logger[_0x5a7a6c('0x1e')](JSON[_0x5a7a6c('0x17')](_0x5a424f));});});},Migration['prototype'][_0x297e87('0x29')]=function(_0x508168,_0x4b53ae,_0x49eeb2){const _0x5c7828=_0x297e87,_0x3445f6=this;this['sequence'][_0x5c7828('0x3')](function(){const _0x3923e2=_0x5c7828;return _0x3445f6[_0x3923e2('0x5')][_0x3923e2('0x29')](_0x508168,_0x4b53ae,_0x49eeb2)['then'](function(){const _0x1ee8ab=_0x3923e2;logger[_0x1ee8ab('0x1e')](_0x1ee8ab('0x0'),_0x4b53ae,_0x508168);})[_0x3923e2('0x12')](function(_0x5abe11){const _0x315ade=_0x3923e2;logger[_0x315ade('0x1e')](JSON[_0x315ade('0x17')](_0x5abe11));});});},Migration['prototype']['dropTable']=function(_0x206ded){const _0x56a2ff=_0x297e87,_0x414bc8=this;this['sequence'][_0x56a2ff('0x3')](function(){const _0x3ec41b=_0x56a2ff;return _0x414bc8[_0x3ec41b('0x5')][_0x3ec41b('0x19')](_0x206ded,{'force':!![]})[_0x3ec41b('0x18')](function(){const _0x28256e=_0x3ec41b;logger[_0x28256e('0x1e')](_0x28256e('0x4'),_0x206ded);})[_0x3ec41b('0x12')](function(_0x55a29e){const _0x148a09=_0x3ec41b;logger['info'](JSON[_0x148a09('0x17')](_0x55a29e));});});},Migration['prototype'][_0x297e87('0x8')]=function(_0x30e30c,_0xb875e4,_0x3df3b5){const _0x585944=_0x297e87,_0x44e28e=this;this[_0x585944('0xc')]['enqueue'](function(){const _0x2e2718=_0x585944;return _0x44e28e[_0x2e2718('0x5')]['addIndex'](_0x30e30c,_0xb875e4,{'indexName':_0x3df3b5})[_0x2e2718('0x18')](function(){const _0x420a72=_0x2e2718;logger[_0x420a72('0x1e')](_0x420a72('0x2e'),_0x30e30c,_0xb875e4['join'](','),_0x3df3b5);})[_0x2e2718('0x12')](function(_0x3d2f80){const _0x4904fe=_0x2e2718;logger[_0x4904fe('0x1e')](JSON[_0x4904fe('0x17')](_0x3d2f80));});});},Migration[_0x297e87('0x32')][_0x297e87('0x22')]=function(_0x3a4cd8){const _0x9116af=_0x297e87,_0x352953=this;this[_0x9116af('0xc')][_0x9116af('0x3')](function(){const _0x288b6c=_0x9116af;return _0x352953[_0x288b6c('0x5')]['sequelize']['query'](_0x3a4cd8)[_0x288b6c('0x18')](function(){const _0x173caa=_0x288b6c;logger[_0x173caa('0x1e')](_0x173caa('0x11'),_0x3a4cd8);})[_0x288b6c('0x12')](function(_0x4436a3){const _0x1a44fb=_0x288b6c;logger[_0x1a44fb('0x1e')](JSON[_0x1a44fb('0x17')](_0x4436a3));});});},Migration['prototype']['removeColumn']=function(_0x1f70c6,_0x2044bb){const _0x35e4bf=_0x297e87,_0x438475=this;this['sequence'][_0x35e4bf('0x3')](function(){const _0x3b53c3=_0x35e4bf;return _0x438475[_0x3b53c3('0x5')]['removeColumn'](_0x1f70c6,_0x2044bb)[_0x3b53c3('0x18')](function(){const _0x42451c=_0x3b53c3;logger[_0x42451c('0x1e')](_0x42451c('0x30'),_0x2044bb,_0x1f70c6);})['catch'](function(_0x57213c){const _0x720a32=_0x3b53c3;logger[_0x720a32('0x1e')](util[_0x720a32('0x33')](_0x57213c,{'showHidden':![],'depth':null}));});});},Migration[_0x297e87('0x32')][_0x297e87('0x15')]=function(_0x136c61,_0x3f6b10,_0x9e1ad8){const _0x2f03e2=_0x297e87,_0x11687c=this;this[_0x2f03e2('0xc')][_0x2f03e2('0x3')](function(){const _0x38966f=_0x2f03e2;return _0x11687c['queryInterface']['renameColumn'](_0x136c61,_0x3f6b10,_0x9e1ad8)[_0x38966f('0x18')](function(){const _0x2c6a52=_0x38966f;logger[_0x2c6a52('0x1e')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x3f6b10,_0x9e1ad8,_0x136c61);})[_0x38966f('0x12')](function(_0x3b58ad){const _0x2f7978=_0x38966f;logger[_0x2f7978('0x1e')](util[_0x2f7978('0x33')](_0x3b58ad,{'showHidden':![],'depth':null}));});});},Migration[_0x297e87('0x32')][_0x297e87('0x2f')]=function(_0x42904b){const _0x353741=_0x297e87;this['sequence'][_0x353741('0x3')](function(){return _0x42904b();});},module['exports']={'up':function(_0x42c624,_0x460d1c){return new Promise(function(_0x2b526c){const _0x30c54f=a935_0x5260,_0x453c46=new Migration(_0x42c624);_0x453c46[_0x30c54f('0x20')](_0x30c54f('0x6'),_0x30c54f('0x26'),{'type':_0x460d1c['ENUM'](_0x30c54f('0x23'),_0x30c54f('0x2b'),_0x30c54f('0xf'),'fewestcalls',_0x30c54f('0x21'),'rrmemory',_0x30c54f('0x28'),_0x30c54f('0x1a'),'rrordered'),'allowNull':![],'defaultValue':'ringall'}),_0x453c46[_0x30c54f('0x29')](_0x30c54f('0x2a'),_0x30c54f('0x25'),{'type':_0x460d1c[_0x30c54f('0xa')],'allowNull':![]}),_0x453c46[_0x30c54f('0x29')](_0x30c54f('0x10'),_0x30c54f('0x31'),{'type':_0x460d1c[_0x30c54f('0x1c')]}),_0x453c46[_0x30c54f('0x29')](_0x30c54f('0x10'),_0x30c54f('0x2'),{'type':_0x460d1c[_0x30c54f('0xb')],'defaultValue':!![]}),_0x453c46[_0x30c54f('0x29')](_0x30c54f('0x10'),_0x30c54f('0x9'),{'type':_0x460d1c[_0x30c54f('0xb')],'defaultValue':![]}),_0x453c46[_0x30c54f('0x29')](_0x30c54f('0x24'),_0x30c54f('0x31'),{'type':_0x460d1c[_0x30c54f('0x1c')]}),_0x453c46['addColumn'](_0x30c54f('0x24'),_0x30c54f('0x2'),{'type':_0x460d1c['BOOLEAN'],'defaultValue':!![]}),_0x453c46[_0x30c54f('0x29')]('chat_websites',_0x30c54f('0x9'),{'type':_0x460d1c[_0x30c54f('0xb')],'defaultValue':![]}),_0x453c46['addColumn'](_0x30c54f('0x1b'),'notificationTemplate',{'type':_0x460d1c[_0x30c54f('0x1c')]}),_0x453c46[_0x30c54f('0x29')]('fax_accounts',_0x30c54f('0x2'),{'type':_0x460d1c['BOOLEAN'],'defaultValue':!![]}),_0x453c46['addColumn'](_0x30c54f('0x1b'),_0x30c54f('0x9'),{'type':_0x460d1c[_0x30c54f('0xb')],'defaultValue':![]}),_0x453c46[_0x30c54f('0x29')](_0x30c54f('0x2c'),_0x30c54f('0x31'),{'type':_0x460d1c[_0x30c54f('0x1c')]}),_0x453c46[_0x30c54f('0x29')]('sms_accounts',_0x30c54f('0x2'),{'type':_0x460d1c['BOOLEAN'],'defaultValue':!![]}),_0x453c46[_0x30c54f('0x29')](_0x30c54f('0x2c'),'notificationShake',{'type':_0x460d1c[_0x30c54f('0xb')],'defaultValue':![]}),_0x453c46[_0x30c54f('0x29')](_0x30c54f('0xe'),_0x30c54f('0x31'),{'type':_0x460d1c['TEXT']}),_0x453c46['addColumn']('openchannel_accounts',_0x30c54f('0x2'),{'type':_0x460d1c[_0x30c54f('0xb')],'defaultValue':!![]}),_0x453c46[_0x30c54f('0x29')](_0x30c54f('0xe'),'notificationShake',{'type':_0x460d1c[_0x30c54f('0xb')],'defaultValue':![]}),_0x453c46[_0x30c54f('0x22')](_0x30c54f('0x1d')),_0x453c46[_0x30c54f('0x22')](_0x30c54f('0x7')),_0x453c46[_0x30c54f('0x22')](_0x30c54f('0x27')),_0x453c46[_0x30c54f('0x22')](_0x30c54f('0x2d')),_0x453c46[_0x30c54f('0x22')](_0x30c54f('0xd')),_0x453c46[_0x30c54f('0x2f')](_0x2b526c);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.57.js b/server/migrations/2.0.57.js index bc4fba2..b8dc262 100644 --- a/server/migrations/2.0.57.js +++ b/server/migrations/2.0.57.js @@ -1 +1 @@ -const a936_0x9d17=['catch','Added\x20column\x20%s\x20to\x20%s','periodic_announce','voice_queues','addColumn','enqueue','join','tail','chat_websites','UPDATE\x20report_queue\x20SET\x20lastAssignedTo=NULL\x20\x20WHERE\x20lastAssignedTo=\x22\x22','finally','migration','table\x20dropped\x20%s','info','addIndex','prototype','dropTable','stringify','changeColumn','then','query\x20%s','inspect','addIndex\x20%s\x20%s\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','UPDATE\x20users\x20SET\x20permissions=\x27101,102,103,110,104,105,106,107,108,109,100,111\x27\x20WHERE\x20permissions=\x27101,102,103,110,104,105,106,107,108,109,100\x27','removeColumn','sequelize','util','renameColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','queryInterface','query','sequence','TEXT'];(function(_0x3dfe7f,_0x9d172f){const _0x5391fd=function(_0x2a2fbc){while(--_0x2a2fbc){_0x3dfe7f['push'](_0x3dfe7f['shift']());}};_0x5391fd(++_0x9d172f);}(a936_0x9d17,0x93));const a936_0x5391=function(_0x3dfe7f,_0x9d172f){_0x3dfe7f=_0x3dfe7f-0x0;let _0x5391fd=a936_0x9d17[_0x3dfe7f];return _0x5391fd;};const _0x3c3be2=a936_0x5391;'use strict';const util=require(_0x3c3be2('0x10')),logger=require('../config/logger')(_0x3c3be2('0x0')),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x2a2fbc){const _0x38649c=_0x3c3be2;this[_0x38649c('0x1e')]=this[_0x38649c('0x1e')]?this[_0x38649c('0x1e')][_0x38649c('0x21')](_0x2a2fbc):_0x2a2fbc();};const Migration=function(_0x5d0c98){const _0x407aa4=_0x3c3be2;this[_0x407aa4('0x13')]=_0x5d0c98,this[_0x407aa4('0x15')]=new Sequence();};Migration[_0x3c3be2('0x4')]['changeColumn']=function(_0x4fdb92,_0x1c74db,_0x3ccb7e){const _0x4989bc=_0x3c3be2,_0x275b14=this;this[_0x4989bc('0x15')][_0x4989bc('0x1c')](function(){const _0x66def1=_0x4989bc;return _0x275b14['queryInterface']['changeColumn'](_0x4fdb92,_0x1c74db,_0x3ccb7e)[_0x66def1('0x8')](function(){const _0x11a65c=_0x66def1;logger[_0x11a65c('0x2')](_0x11a65c('0x12'),_0x1c74db,_0x4fdb92);})[_0x66def1('0x17')](function(_0x47e44b){const _0x7bc4f9=_0x66def1;logger[_0x7bc4f9('0x2')](JSON[_0x7bc4f9('0x6')](_0x47e44b));});});},Migration[_0x3c3be2('0x4')][_0x3c3be2('0x1b')]=function(_0xa62150,_0x78422e,_0x2459f2){const _0x3aa977=_0x3c3be2,_0x24b4e2=this;this['sequence'][_0x3aa977('0x1c')](function(){const _0x441d28=_0x3aa977;return _0x24b4e2[_0x441d28('0x13')][_0x441d28('0x1b')](_0xa62150,_0x78422e,_0x2459f2)['then'](function(){const _0x3f077b=_0x441d28;logger[_0x3f077b('0x2')](_0x3f077b('0x18'),_0x78422e,_0xa62150);})['catch'](function(_0x35b4e8){const _0x10c0c4=_0x441d28;logger[_0x10c0c4('0x2')](JSON[_0x10c0c4('0x6')](_0x35b4e8));});});},Migration[_0x3c3be2('0x4')][_0x3c3be2('0x5')]=function(_0x48ad5d){const _0x271b1a=_0x3c3be2,_0x4569d5=this;this[_0x271b1a('0x15')][_0x271b1a('0x1c')](function(){const _0x3c727=_0x271b1a;return _0x4569d5[_0x3c727('0x13')][_0x3c727('0x5')](_0x48ad5d,{'force':!![]})['then'](function(){const _0xfc9d98=_0x3c727;logger[_0xfc9d98('0x2')](_0xfc9d98('0x1'),_0x48ad5d);})[_0x3c727('0x17')](function(_0x950ac8){const _0x27e35a=_0x3c727;logger[_0x27e35a('0x2')](JSON[_0x27e35a('0x6')](_0x950ac8));});});},Migration[_0x3c3be2('0x4')][_0x3c3be2('0x3')]=function(_0x20f66f,_0x2743e5,_0x4dcdc2){const _0x4b96b6=_0x3c3be2,_0x12af17=this;this[_0x4b96b6('0x15')][_0x4b96b6('0x1c')](function(){const _0x3599c8=_0x4b96b6;return _0x12af17[_0x3599c8('0x13')][_0x3599c8('0x3')](_0x20f66f,_0x2743e5,{'indexName':_0x4dcdc2})[_0x3599c8('0x8')](function(){const _0x4c92e8=_0x3599c8;logger['info'](_0x4c92e8('0xb'),_0x20f66f,_0x2743e5[_0x4c92e8('0x1d')](','),_0x4dcdc2);})[_0x3599c8('0x17')](function(_0x1975cf){const _0x3c179a=_0x3599c8;logger[_0x3c179a('0x2')](JSON['stringify'](_0x1975cf));});});},Migration['prototype'][_0x3c3be2('0x14')]=function(_0xf55eb5){const _0x58f3a4=_0x3c3be2,_0x20eac2=this;this['sequence'][_0x58f3a4('0x1c')](function(){const _0x3aed01=_0x58f3a4;return _0x20eac2[_0x3aed01('0x13')][_0x3aed01('0xf')]['query'](_0xf55eb5)[_0x3aed01('0x8')](function(){const _0x4a9453=_0x3aed01;logger[_0x4a9453('0x2')](_0x4a9453('0x9'),_0xf55eb5);})[_0x3aed01('0x17')](function(_0x2b474f){const _0x5966ec=_0x3aed01;logger[_0x5966ec('0x2')](JSON['stringify'](_0x2b474f));});});},Migration[_0x3c3be2('0x4')][_0x3c3be2('0xe')]=function(_0x11fc7,_0x1e89c5){const _0x3fa48a=_0x3c3be2,_0x1a67a7=this;this['sequence'][_0x3fa48a('0x1c')](function(){const _0x5d2710=_0x3fa48a;return _0x1a67a7[_0x5d2710('0x13')][_0x5d2710('0xe')](_0x11fc7,_0x1e89c5)[_0x5d2710('0x8')](function(){const _0x46ce71=_0x5d2710;logger[_0x46ce71('0x2')]('Removed\x20column\x20%s\x20from\x20%s',_0x1e89c5,_0x11fc7);})[_0x5d2710('0x17')](function(_0x40deb1){const _0x52091f=_0x5d2710;logger[_0x52091f('0x2')](util[_0x52091f('0xa')](_0x40deb1,{'showHidden':![],'depth':null}));});});},Migration[_0x3c3be2('0x4')]['renameColumn']=function(_0x512201,_0x15463f,_0x592db8){const _0x438158=_0x3c3be2,_0x33c77c=this;this[_0x438158('0x15')][_0x438158('0x1c')](function(){const _0x2ecf81=_0x438158;return _0x33c77c[_0x2ecf81('0x13')][_0x2ecf81('0x11')](_0x512201,_0x15463f,_0x592db8)[_0x2ecf81('0x8')](function(){const _0x42e47c=_0x2ecf81;logger[_0x42e47c('0x2')](_0x42e47c('0xc'),_0x15463f,_0x592db8,_0x512201);})[_0x2ecf81('0x17')](function(_0x47c732){const _0x2bb419=_0x2ecf81;logger['info'](util[_0x2bb419('0xa')](_0x47c732,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0xe97264){const _0x412b84=_0x3c3be2;this[_0x412b84('0x15')]['enqueue'](function(){return _0xe97264();});},module['exports']={'up':function(_0x20474b,_0x4d2242){return new Promise(function(_0x509271){const _0x1af513=a936_0x5391,_0x64e3f8=new Migration(_0x20474b);_0x64e3f8[_0x1af513('0x1b')](_0x1af513('0x1f'),'hideWhenOffline',{'type':_0x4d2242['BOOLEAN'],'defaultValue':![]}),_0x64e3f8[_0x1af513('0x7')](_0x1af513('0x1a'),_0x1af513('0x19'),{'type':_0x4d2242[_0x1af513('0x16')]}),_0x64e3f8[_0x1af513('0x14')](_0x1af513('0xd')),_0x64e3f8[_0x1af513('0x14')](_0x1af513('0x20')),_0x64e3f8['final'](_0x509271);});},'down':function(){}}; \ No newline at end of file +const a936_0x4550=['addIndex','voice_queues','info','enqueue','query','dropTable','../config/logger','prototype','stringify','UPDATE\x20users\x20SET\x20permissions=\x27101,102,103,110,104,105,106,107,108,109,100,111\x27\x20WHERE\x20permissions=\x27101,102,103,110,104,105,106,107,108,109,100\x27','addColumn','BOOLEAN','sequence','renameColumn','tail','Added\x20column\x20%s\x20to\x20%s','catch','final','migration','periodic_announce','Changed\x20column\x20%s\x20in\x20table\x20%s','inspect','sequelize','chat_websites','join','removeColumn','queryInterface','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','query\x20%s','finally','changeColumn','UPDATE\x20report_queue\x20SET\x20lastAssignedTo=NULL\x20\x20WHERE\x20lastAssignedTo=\x22\x22','then','TEXT'];(function(_0x3d9d88,_0x4550df){const _0x33593c=function(_0x4176b7){while(--_0x4176b7){_0x3d9d88['push'](_0x3d9d88['shift']());}};_0x33593c(++_0x4550df);}(a936_0x4550,0xdb));const a936_0x3359=function(_0x3d9d88,_0x4550df){_0x3d9d88=_0x3d9d88-0x0;let _0x33593c=a936_0x4550[_0x3d9d88];return _0x33593c;};const _0x1a933a=a936_0x3359;'use strict';const util=require('util'),logger=require(_0x1a933a('0x19'))(_0x1a933a('0x3')),Sequence=function(){};Sequence['prototype'][_0x1a933a('0x16')]=function(_0x4176b7){const _0x58f7d8=_0x1a933a;this[_0x58f7d8('0x21')]=this[_0x58f7d8('0x21')]?this['tail'][_0x58f7d8('0xe')](_0x4176b7):_0x4176b7();};const Migration=function(_0x41b5b0){this['queryInterface']=_0x41b5b0,this['sequence']=new Sequence();};Migration[_0x1a933a('0x1a')]['changeColumn']=function(_0x1c841d,_0x1ac85b,_0x109131){const _0x39ba5b=_0x1a933a,_0x5b9057=this;this['sequence'][_0x39ba5b('0x16')](function(){const _0xcdadbf=_0x39ba5b;return _0x5b9057[_0xcdadbf('0xb')][_0xcdadbf('0xf')](_0x1c841d,_0x1ac85b,_0x109131)[_0xcdadbf('0x11')](function(){const _0x384ff5=_0xcdadbf;logger[_0x384ff5('0x15')](_0x384ff5('0x5'),_0x1ac85b,_0x1c841d);})[_0xcdadbf('0x1')](function(_0x144352){const _0x40a16c=_0xcdadbf;logger[_0x40a16c('0x15')](JSON['stringify'](_0x144352));});});},Migration[_0x1a933a('0x1a')][_0x1a933a('0x1d')]=function(_0x192088,_0x4f9ff9,_0x33102c){const _0x455480=_0x1a933a,_0x169c74=this;this['sequence'][_0x455480('0x16')](function(){const _0x51b9f6=_0x455480;return _0x169c74[_0x51b9f6('0xb')]['addColumn'](_0x192088,_0x4f9ff9,_0x33102c)[_0x51b9f6('0x11')](function(){const _0x2e81df=_0x51b9f6;logger[_0x2e81df('0x15')](_0x2e81df('0x0'),_0x4f9ff9,_0x192088);})[_0x51b9f6('0x1')](function(_0x58f07e){const _0x4ee0a9=_0x51b9f6;logger[_0x4ee0a9('0x15')](JSON[_0x4ee0a9('0x1b')](_0x58f07e));});});},Migration[_0x1a933a('0x1a')]['dropTable']=function(_0x32ac85){const _0x3a868a=_0x1a933a,_0x534c0e=this;this[_0x3a868a('0x1f')][_0x3a868a('0x16')](function(){const _0x2e041d=_0x3a868a;return _0x534c0e['queryInterface'][_0x2e041d('0x18')](_0x32ac85,{'force':!![]})[_0x2e041d('0x11')](function(){logger['info']('table\x20dropped\x20%s',_0x32ac85);})['catch'](function(_0x45d360){const _0x2c68d1=_0x2e041d;logger[_0x2c68d1('0x15')](JSON[_0x2c68d1('0x1b')](_0x45d360));});});},Migration['prototype'][_0x1a933a('0x13')]=function(_0x1b295b,_0x335e06,_0x5b48ea){const _0x44ed24=_0x1a933a,_0x4bfc29=this;this[_0x44ed24('0x1f')]['enqueue'](function(){const _0x17e039=_0x44ed24;return _0x4bfc29[_0x17e039('0xb')]['addIndex'](_0x1b295b,_0x335e06,{'indexName':_0x5b48ea})[_0x17e039('0x11')](function(){const _0x1dd178=_0x17e039;logger[_0x1dd178('0x15')]('addIndex\x20%s\x20%s\x20%s',_0x1b295b,_0x335e06[_0x1dd178('0x9')](','),_0x5b48ea);})['catch'](function(_0x5504e0){const _0x3bbe9c=_0x17e039;logger[_0x3bbe9c('0x15')](JSON['stringify'](_0x5504e0));});});},Migration[_0x1a933a('0x1a')][_0x1a933a('0x17')]=function(_0x1d4297){const _0x59b8f2=_0x1a933a,_0xf1d863=this;this['sequence'][_0x59b8f2('0x16')](function(){const _0x20d99f=_0x59b8f2;return _0xf1d863[_0x20d99f('0xb')][_0x20d99f('0x7')][_0x20d99f('0x17')](_0x1d4297)['then'](function(){const _0x5ae463=_0x20d99f;logger[_0x5ae463('0x15')](_0x5ae463('0xd'),_0x1d4297);})[_0x20d99f('0x1')](function(_0x2fcbb5){const _0x355c60=_0x20d99f;logger[_0x355c60('0x15')](JSON[_0x355c60('0x1b')](_0x2fcbb5));});});},Migration[_0x1a933a('0x1a')][_0x1a933a('0xa')]=function(_0x581a4f,_0x367ec3){const _0x3ba7ee=_0x1a933a,_0x4c584e=this;this[_0x3ba7ee('0x1f')][_0x3ba7ee('0x16')](function(){const _0x4fe5a2=_0x3ba7ee;return _0x4c584e['queryInterface'][_0x4fe5a2('0xa')](_0x581a4f,_0x367ec3)[_0x4fe5a2('0x11')](function(){const _0x2ebaeb=_0x4fe5a2;logger[_0x2ebaeb('0x15')]('Removed\x20column\x20%s\x20from\x20%s',_0x367ec3,_0x581a4f);})['catch'](function(_0xdcc02c){const _0x13fc38=_0x4fe5a2;logger['info'](util[_0x13fc38('0x6')](_0xdcc02c,{'showHidden':![],'depth':null}));});});},Migration[_0x1a933a('0x1a')][_0x1a933a('0x20')]=function(_0x3efe33,_0x25c0b9,_0x38eef1){const _0x21924b=_0x1a933a,_0x433973=this;this[_0x21924b('0x1f')][_0x21924b('0x16')](function(){const _0x21fada=_0x21924b;return _0x433973[_0x21fada('0xb')]['renameColumn'](_0x3efe33,_0x25c0b9,_0x38eef1)['then'](function(){const _0x2cfeb2=_0x21fada;logger[_0x2cfeb2('0x15')](_0x2cfeb2('0xc'),_0x25c0b9,_0x38eef1,_0x3efe33);})['catch'](function(_0x1f4bf9){const _0x3d375d=_0x21fada;logger[_0x3d375d('0x15')](util[_0x3d375d('0x6')](_0x1f4bf9,{'showHidden':![],'depth':null}));});});},Migration[_0x1a933a('0x1a')][_0x1a933a('0x2')]=function(_0x32bf0e){const _0x2dd7a1=_0x1a933a;this['sequence'][_0x2dd7a1('0x16')](function(){return _0x32bf0e();});},module['exports']={'up':function(_0xe1d6d0,_0x4642b2){return new Promise(function(_0x1bca7e){const _0x2cfdb8=a936_0x3359,_0x5f20d7=new Migration(_0xe1d6d0);_0x5f20d7[_0x2cfdb8('0x1d')](_0x2cfdb8('0x8'),'hideWhenOffline',{'type':_0x4642b2[_0x2cfdb8('0x1e')],'defaultValue':![]}),_0x5f20d7[_0x2cfdb8('0xf')](_0x2cfdb8('0x14'),_0x2cfdb8('0x4'),{'type':_0x4642b2[_0x2cfdb8('0x12')]}),_0x5f20d7[_0x2cfdb8('0x17')](_0x2cfdb8('0x1c')),_0x5f20d7[_0x2cfdb8('0x17')](_0x2cfdb8('0x10')),_0x5f20d7[_0x2cfdb8('0x2')](_0x1bca7e);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.58.js b/server/migrations/2.0.58.js index bce830b..51a58b6 100644 --- a/server/migrations/2.0.58.js +++ b/server/migrations/2.0.58.js @@ -1 +1 @@ -const a937_0xfa33=['migration','info','prototype','inspect','exports','tail','queue','../config/logger','queuecallerexitreason','then','removeColumn','INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Login\x27,\x20\x27agentmanagement-login\x27,\x20\x27Agent\x20Login\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27mp3\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);','queryInterface','INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20End\x20Pause\x27,\x20\x27agentmanagement-unpause\x27,\x20\x27Agent\x20End\x20Pause\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27mp3\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);','changeColumn','Removed\x20column\x20%s\x20from\x20%s','stringify','INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Action\x20Failure\x27,\x20\x27agentmanagement-action-failure\x27,\x20\x27Agent\x20Action\x20Failure\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);','enqueue','disposition','query\x20%s','ALTER\x20TABLE\x20`voice_voicemail_messages`\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`voice_voicemail_messages_ibfk_1`\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`mailboxuser`)\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20voice_voicemail(`mailbox`)\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','renameColumn','query','addIndex','INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Menu\x27,\x20\x27agentmanagement-menu\x27,\x20\x27Agent\x20Menu\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);','addColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','catch','report_queue','dropTable','sequence','final','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s'];(function(_0xf1fecf,_0xfa33ad){const _0x11430f=function(_0x527bc3){while(--_0x527bc3){_0xf1fecf['push'](_0xf1fecf['shift']());}};_0x11430f(++_0xfa33ad);}(a937_0xfa33,0x1b3));const a937_0x1143=function(_0xf1fecf,_0xfa33ad){_0xf1fecf=_0xf1fecf-0x0;let _0x11430f=a937_0xfa33[_0xf1fecf];return _0x11430f;};const _0x5c0e13=a937_0x1143;'use strict';const util=require('util'),logger=require(_0x5c0e13('0xe'))(_0x5c0e13('0x7')),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x527bc3){const _0x445def=_0x5c0e13;this['tail']=this[_0x445def('0xc')]?this[_0x445def('0xc')]['finally'](_0x527bc3):_0x527bc3();};const Migration=function(_0x134460){const _0x50d925=_0x5c0e13;this[_0x50d925('0x13')]=_0x134460,this[_0x50d925('0x4')]=new Sequence();};Migration[_0x5c0e13('0x9')][_0x5c0e13('0x15')]=function(_0x372d68,_0x35182b,_0x28bbd4){const _0xd3681c=_0x5c0e13,_0x3224ad=this;this[_0xd3681c('0x4')][_0xd3681c('0x19')](function(){const _0x3f633d=_0xd3681c;return _0x3224ad[_0x3f633d('0x13')][_0x3f633d('0x15')](_0x372d68,_0x35182b,_0x28bbd4)[_0x3f633d('0x10')](function(){const _0x150e29=_0x3f633d;logger['info'](_0x150e29('0x0'),_0x35182b,_0x372d68);})[_0x3f633d('0x1')](function(_0x49e3a9){const _0x5ba228=_0x3f633d;logger['info'](JSON[_0x5ba228('0x17')](_0x49e3a9));});});},Migration[_0x5c0e13('0x9')][_0x5c0e13('0x21')]=function(_0x24f9c4,_0x38b0e2,_0x3641d3){const _0x123c1a=_0x5c0e13,_0x5a53bf=this;this[_0x123c1a('0x4')][_0x123c1a('0x19')](function(){const _0xdb55cc=_0x123c1a;return _0x5a53bf[_0xdb55cc('0x13')]['addColumn'](_0x24f9c4,_0x38b0e2,_0x3641d3)['then'](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x38b0e2,_0x24f9c4);})[_0xdb55cc('0x1')](function(_0xe07856){const _0x1a0569=_0xdb55cc;logger[_0x1a0569('0x8')](JSON['stringify'](_0xe07856));});});},Migration[_0x5c0e13('0x9')][_0x5c0e13('0x3')]=function(_0x3af6e4){const _0xb3d77a=_0x5c0e13,_0xab1773=this;this[_0xb3d77a('0x4')][_0xb3d77a('0x19')](function(){const _0xa8b7fa=_0xb3d77a;return _0xab1773[_0xa8b7fa('0x13')][_0xa8b7fa('0x3')](_0x3af6e4,{'force':!![]})[_0xa8b7fa('0x10')](function(){logger['info']('table\x20dropped\x20%s',_0x3af6e4);})[_0xa8b7fa('0x1')](function(_0x53641d){const _0x5ecbab=_0xa8b7fa;logger[_0x5ecbab('0x8')](JSON[_0x5ecbab('0x17')](_0x53641d));});});},Migration['prototype'][_0x5c0e13('0x1f')]=function(_0x3d3662,_0x4deb86,_0x577aa4){const _0x5bcd73=this;this['sequence']['enqueue'](function(){const _0x110490=a937_0x1143;return _0x5bcd73[_0x110490('0x13')][_0x110490('0x1f')](_0x3d3662,_0x4deb86,{'indexName':_0x577aa4})[_0x110490('0x10')](function(){const _0x5e2e76=_0x110490;logger[_0x5e2e76('0x8')]('addIndex\x20%s\x20%s\x20%s',_0x3d3662,_0x4deb86['join'](','),_0x577aa4);})['catch'](function(_0x5a9037){const _0x40a3f9=_0x110490;logger[_0x40a3f9('0x8')](JSON[_0x40a3f9('0x17')](_0x5a9037));});});},Migration['prototype'][_0x5c0e13('0x1e')]=function(_0x11490f){const _0xf3f5ba=_0x5c0e13,_0x30ed0d=this;this[_0xf3f5ba('0x4')][_0xf3f5ba('0x19')](function(){const _0x1555fe=_0xf3f5ba;return _0x30ed0d[_0x1555fe('0x13')]['sequelize']['query'](_0x11490f)[_0x1555fe('0x10')](function(){const _0x3026a6=_0x1555fe;logger['info'](_0x3026a6('0x1b'),_0x11490f);})[_0x1555fe('0x1')](function(_0x53718b){const _0x3dde96=_0x1555fe;logger['info'](JSON[_0x3dde96('0x17')](_0x53718b));});});},Migration[_0x5c0e13('0x9')]['removeColumn']=function(_0x94c11c,_0x4c8685){const _0x43911b=_0x5c0e13,_0x45f2b7=this;this['sequence'][_0x43911b('0x19')](function(){const _0x5671e5=_0x43911b;return _0x45f2b7[_0x5671e5('0x13')][_0x5671e5('0x11')](_0x94c11c,_0x4c8685)[_0x5671e5('0x10')](function(){const _0x1e9565=_0x5671e5;logger[_0x1e9565('0x8')](_0x1e9565('0x16'),_0x4c8685,_0x94c11c);})[_0x5671e5('0x1')](function(_0x3c4a9e){const _0xb6cd00=_0x5671e5;logger[_0xb6cd00('0x8')](util[_0xb6cd00('0xa')](_0x3c4a9e,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x5c0e13('0x1d')]=function(_0x2c373a,_0x99ade3,_0x2f5777){const _0x24251a=_0x5c0e13,_0x527875=this;this[_0x24251a('0x4')][_0x24251a('0x19')](function(){const _0x5bfb21=_0x24251a;return _0x527875['queryInterface']['renameColumn'](_0x2c373a,_0x99ade3,_0x2f5777)['then'](function(){const _0x200434=a937_0x1143;logger[_0x200434('0x8')](_0x200434('0x6'),_0x99ade3,_0x2f5777,_0x2c373a);})[_0x5bfb21('0x1')](function(_0x4d370c){const _0x4432b5=_0x5bfb21;logger['info'](util[_0x4432b5('0xa')](_0x4d370c,{'showHidden':![],'depth':null}));});});},Migration[_0x5c0e13('0x9')][_0x5c0e13('0x5')]=function(_0x534fb3){const _0x38daf1=_0x5c0e13;this[_0x38daf1('0x4')]['enqueue'](function(){return _0x534fb3();});},module[_0x5c0e13('0xb')]={'up':function(_0x29904b,_0x46a109){return new Promise(function(_0x18bdc3){const _0x3773d4=a937_0x1143,_0x2f44e8=new Migration(_0x29904b);_0x2f44e8['query'](_0x3773d4('0x1c')),_0x2f44e8['addIndex']('report_queue',[_0x3773d4('0xd')],'queue'),_0x2f44e8[_0x3773d4('0x1f')](_0x3773d4('0x2'),[_0x3773d4('0xf')],_0x3773d4('0xf')),_0x2f44e8[_0x3773d4('0x21')](_0x3773d4('0x2'),_0x3773d4('0x1a'),{'type':_0x46a109['STRING']}),_0x2f44e8[_0x3773d4('0x1e')]('INSERT\x20INTO\x20`square_projects`\x20(`name`,\x20`description`,\x20`notes`,\x20`preproduction`,\x20`production`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27AgentManagement\x27,\x20\x27Agent\x20Management\x20sample\x20auto\x20generated\x27,\x20NULL,\x20X\x273C6D7847726170684D6F64656C20677269643D223122206775696465733D22312220746F6F6C746970733D22312220636F6E6E6563743D22312220666F6C643D22312220706167653D22302220706167655363616C653D223122207061676557696474683D223832362220706167654865696768743D2231313639223E0A20203C726F6F743E0A202020203C6D7843656C6C2069643D2230222F3E0A202020203C6D7843656C6C2069643D22312220706172656E743D2230222F3E0A202020203C7374617274206C6162656C3D2253746172742220616E737765723D22796573222069643D2239223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F656E7472792F73746172745F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D2234302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F73746172743E0A202020203C6D656E75206C6162656C3D224D656E75222066696C655F69643D222220726573706F6E73653D2235222064696769743D2231222072657472793D223122207661726961626C655F69643D2230222069643D223136223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F6D656E755F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223137302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6D656E753E0A202020203C6C6F67696E206C6162656C3D224C6F67696E222066696E6442793D22696E7465726E616C222069643D223339223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F6C6F67696E5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D223132222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6C6F67696E3E0A202020203C7061757365206C6162656C3D225061757365222066696E6442793D22696E7465726E616C222070617573655F69643D22222069643D223430223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F70617573655F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22333434222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F70617573653E0A202020203C756E7061757365206C6162656C3D22556E7061757365222066696E6442793D22696E7465726E616C222069643D223431223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F756E70617573655F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22343634222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F756E70617573653E0A202020203C6C6F676F7574206C6162656C3D224C6F676F7574222066696E6442793D22696E7465726E616C222069643D223432223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F6C6F676F75745F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22313332222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6C6F676F75743E0A202020203C6D7843656C6C2069643D223433222076616C75653D22312220706172656E743D22312220736F757263653D22313622207461726765743D2233392220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223231302220793D22313432222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223434222076616C75653D22322220706172656E743D22312220736F757263653D22313622207461726765743D2234322220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223435222076616C75653D22332220706172656E743D22312220736F757263653D22313622207461726765743D2234302220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223436222076616C75653D22342220706172656E743D22312220736F757263653D22313622207461726765743D2234312220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223231302220793D22343134222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2234372220706172656E743D22312220736F757263653D223922207461726765743D2231362220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223438223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223435302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C6D7843656C6C2069643D223530222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343222207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223531222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343022207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C68616E677570206C6162656C3D2248616E677570222069643D223533223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F63616C6C5F6D616E6167656D656E742F68616E6775705F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223735302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F68616E6775703E0A202020203C6D7843656C6C2069643D2235342220706172656E743D22312220736F757263653D22343822207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223535222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22333922207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223439302220793D22313730222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223536222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343122207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223439302220793D22333930222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223537223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22313332222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223538223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D223132222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223539223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22333434222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223630223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22343634222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C6D7843656C6C2069643D223631222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22333922207461726765743D2235382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223632222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343222207461726765743D2235372220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223633222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343022207461726765743D2235392220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223634222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343122207461726765743D2236302220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236352220706172656E743D22312220736F757263653D22353822207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236362220706172656E743D22312220736F757263653D22353722207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236372220706172656E743D22312220736F757263653D22353922207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236382220706172656E743D22312220736F757263653D22363022207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A20203C2F726F6F743E0A3C2F6D7847726170684D6F64656C3E\x27,\x20X\x273C6D7847726170684D6F64656C20677269643D223122206775696465733D22312220746F6F6C746970733D22312220636F6E6E6563743D22312220666F6C643D22312220706167653D22302220706167655363616C653D223122207061676557696474683D223832362220706167654865696768743D2231313639223E0A20203C726F6F743E0A202020203C6D7843656C6C2069643D2230222F3E0A202020203C6D7843656C6C2069643D22312220706172656E743D2230222F3E0A202020203C7374617274206C6162656C3D2253746172742220616E737765723D22796573222069643D2239223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F656E7472792F73746172745F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D2234302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F73746172743E0A202020203C6D656E75206C6162656C3D224D656E75222066696C655F69643D222220726573706F6E73653D2235222064696769743D2231222072657472793D223122207661726961626C655F69643D2230222069643D223136223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F6D656E755F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223137302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6D656E753E0A202020203C6C6F67696E206C6162656C3D224C6F67696E222066696E6442793D22696E7465726E616C222069643D223339223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F6C6F67696E5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D223132222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6C6F67696E3E0A202020203C7061757365206C6162656C3D225061757365222066696E6442793D22696E7465726E616C222070617573655F69643D22222069643D223430223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F70617573655F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22333434222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F70617573653E0A202020203C756E7061757365206C6162656C3D22556E7061757365222066696E6442793D22696E7465726E616C222069643D223431223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F756E70617573655F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22343634222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F756E70617573653E0A202020203C6C6F676F7574206C6162656C3D224C6F676F7574222066696E6442793D22696E7465726E616C222069643D223432223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F6C6F676F75745F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22313332222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6C6F676F75743E0A202020203C6D7843656C6C2069643D223433222076616C75653D22312220706172656E743D22312220736F757263653D22313622207461726765743D2233392220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223231302220793D22313432222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223434222076616C75653D22322220706172656E743D22312220736F757263653D22313622207461726765743D2234322220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223435222076616C75653D22332220706172656E743D22312220736F757263653D22313622207461726765743D2234302220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223436222076616C75653D22342220706172656E743D22312220736F757263653D22313622207461726765743D2234312220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223231302220793D22343134222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2234372220706172656E743D22312220736F757263653D223922207461726765743D2231362220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223438223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223435302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C6D7843656C6C2069643D223530222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343222207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223531222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343022207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C68616E677570206C6162656C3D2248616E677570222069643D223533223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F63616C6C5F6D616E6167656D656E742F68616E6775705F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223735302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F68616E6775703E0A202020203C6D7843656C6C2069643D2235342220706172656E743D22312220736F757263653D22343822207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223535222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22333922207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223439302220793D22313730222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223536222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343122207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223439302220793D22333930222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223537223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22313332222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223538223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D223132222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223539223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22333434222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223630223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22343634222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C6D7843656C6C2069643D223631222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22333922207461726765743D2235382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223632222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343222207461726765743D2235372220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223633222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343022207461726765743D2235392220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223634222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343122207461726765743D2236302220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236352220706172656E743D22312220736F757263653D22353822207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236362220706172656E743D22312220736F757263653D22353722207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236372220706172656E743D22312220736F757263653D22353922207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236382220706172656E743D22312220736F757263653D22363022207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A20203C2F726F6F743E0A3C2F6D7847726170684D6F64656C3E\x27,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);'),_0x2f44e8[_0x3773d4('0x1e')](_0x3773d4('0x12')),_0x2f44e8['query']('INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Logout\x27,\x20\x27agentmanagement-logout\x27,\x20\x27Agent\x20Logout\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27mp3\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);'),_0x2f44e8['query'](_0x3773d4('0x20')),_0x2f44e8['query']('INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Pause\x27,\x20\x27agentmanagement-pause\x27,\x20\x27Agent\x20Pause\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27mp3\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);'),_0x2f44e8[_0x3773d4('0x1e')](_0x3773d4('0x14')),_0x2f44e8[_0x3773d4('0x1e')](_0x3773d4('0x18')),_0x2f44e8[_0x3773d4('0x5')](_0x18bdc3);});},'down':function(){}}; \ No newline at end of file +const a937_0xd85e=['removeColumn','INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Action\x20Failure\x27,\x20\x27agentmanagement-action-failure\x27,\x20\x27Agent\x20Action\x20Failure\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);','report_queue','Changed\x20column\x20%s\x20in\x20table\x20%s','Added\x20column\x20%s\x20to\x20%s','inspect','sequelize','join','addIndex','ALTER\x20TABLE\x20`voice_voicemail_messages`\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`voice_voicemail_messages_ibfk_1`\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`mailboxuser`)\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20voice_voicemail(`mailbox`)\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','addIndex\x20%s\x20%s\x20%s','sequence','stringify','renameColumn','disposition','info','changeColumn','INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Pause\x27,\x20\x27agentmanagement-pause\x27,\x20\x27Agent\x20Pause\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27mp3\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);','../config/logger','query\x20%s','query','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','INSERT\x20INTO\x20`square_projects`\x20(`name`,\x20`description`,\x20`notes`,\x20`preproduction`,\x20`production`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27AgentManagement\x27,\x20\x27Agent\x20Management\x20sample\x20auto\x20generated\x27,\x20NULL,\x20X\x273C6D7847726170684D6F64656C20677269643D223122206775696465733D22312220746F6F6C746970733D22312220636F6E6E6563743D22312220666F6C643D22312220706167653D22302220706167655363616C653D223122207061676557696474683D223832362220706167654865696768743D2231313639223E0A20203C726F6F743E0A202020203C6D7843656C6C2069643D2230222F3E0A202020203C6D7843656C6C2069643D22312220706172656E743D2230222F3E0A202020203C7374617274206C6162656C3D2253746172742220616E737765723D22796573222069643D2239223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F656E7472792F73746172745F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D2234302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F73746172743E0A202020203C6D656E75206C6162656C3D224D656E75222066696C655F69643D222220726573706F6E73653D2235222064696769743D2231222072657472793D223122207661726961626C655F69643D2230222069643D223136223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F6D656E755F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223137302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6D656E753E0A202020203C6C6F67696E206C6162656C3D224C6F67696E222066696E6442793D22696E7465726E616C222069643D223339223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F6C6F67696E5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D223132222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6C6F67696E3E0A202020203C7061757365206C6162656C3D225061757365222066696E6442793D22696E7465726E616C222070617573655F69643D22222069643D223430223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F70617573655F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22333434222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F70617573653E0A202020203C756E7061757365206C6162656C3D22556E7061757365222066696E6442793D22696E7465726E616C222069643D223431223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F756E70617573655F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22343634222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F756E70617573653E0A202020203C6C6F676F7574206C6162656C3D224C6F676F7574222066696E6442793D22696E7465726E616C222069643D223432223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F6C6F676F75745F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22313332222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6C6F676F75743E0A202020203C6D7843656C6C2069643D223433222076616C75653D22312220706172656E743D22312220736F757263653D22313622207461726765743D2233392220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223231302220793D22313432222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223434222076616C75653D22322220706172656E743D22312220736F757263653D22313622207461726765743D2234322220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223435222076616C75653D22332220706172656E743D22312220736F757263653D22313622207461726765743D2234302220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223436222076616C75653D22342220706172656E743D22312220736F757263653D22313622207461726765743D2234312220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223231302220793D22343134222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2234372220706172656E743D22312220736F757263653D223922207461726765743D2231362220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223438223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223435302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C6D7843656C6C2069643D223530222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343222207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223531222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343022207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C68616E677570206C6162656C3D2248616E677570222069643D223533223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F63616C6C5F6D616E6167656D656E742F68616E6775705F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223735302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F68616E6775703E0A202020203C6D7843656C6C2069643D2235342220706172656E743D22312220736F757263653D22343822207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223535222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22333922207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223439302220793D22313730222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223536222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343122207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223439302220793D22333930222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223537223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22313332222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223538223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D223132222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223539223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22333434222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223630223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22343634222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C6D7843656C6C2069643D223631222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22333922207461726765743D2235382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223632222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343222207461726765743D2235372220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223633222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343022207461726765743D2235392220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223634222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343122207461726765743D2236302220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236352220706172656E743D22312220736F757263653D22353822207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236362220706172656E743D22312220736F757263653D22353722207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236372220706172656E743D22312220736F757263653D22353922207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236382220706172656E743D22312220736F757263653D22363022207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A20203C2F726F6F743E0A3C2F6D7847726170684D6F64656C3E\x27,\x20X\x273C6D7847726170684D6F64656C20677269643D223122206775696465733D22312220746F6F6C746970733D22312220636F6E6E6563743D22312220666F6C643D22312220706167653D22302220706167655363616C653D223122207061676557696474683D223832362220706167654865696768743D2231313639223E0A20203C726F6F743E0A202020203C6D7843656C6C2069643D2230222F3E0A202020203C6D7843656C6C2069643D22312220706172656E743D2230222F3E0A202020203C7374617274206C6162656C3D2253746172742220616E737765723D22796573222069643D2239223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F656E7472792F73746172745F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D2234302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F73746172743E0A202020203C6D656E75206C6162656C3D224D656E75222066696C655F69643D222220726573706F6E73653D2235222064696769743D2231222072657472793D223122207661726961626C655F69643D2230222069643D223136223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F6D656E755F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223137302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6D656E753E0A202020203C6C6F67696E206C6162656C3D224C6F67696E222066696E6442793D22696E7465726E616C222069643D223339223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F6C6F67696E5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D223132222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6C6F67696E3E0A202020203C7061757365206C6162656C3D225061757365222066696E6442793D22696E7465726E616C222070617573655F69643D22222069643D223430223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F70617573655F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22333434222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F70617573653E0A202020203C756E7061757365206C6162656C3D22556E7061757365222066696E6442793D22696E7465726E616C222069643D223431223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F756E70617573655F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22343634222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F756E70617573653E0A202020203C6C6F676F7574206C6162656C3D224C6F676F7574222066696E6442793D22696E7465726E616C222069643D223432223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F6167656E745F6D616E6167656D656E742F6C6F676F75745F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223332302220793D22313332222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F6C6F676F75743E0A202020203C6D7843656C6C2069643D223433222076616C75653D22312220706172656E743D22312220736F757263653D22313622207461726765743D2233392220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223231302220793D22313432222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223434222076616C75653D22322220706172656E743D22312220736F757263653D22313622207461726765743D2234322220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223435222076616C75653D22332220706172656E743D22312220736F757263653D22313622207461726765743D2234302220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223436222076616C75653D22342220706172656E743D22312220736F757263653D22313622207461726765743D2234312220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223231302220793D22343134222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2234372220706172656E743D22312220736F757263653D223922207461726765743D2231362220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223438223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223435302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C6D7843656C6C2069643D223530222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343222207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223531222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343022207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C68616E677570206C6162656C3D2248616E677570222069643D223533223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F63616C6C5F6D616E6167656D656E742F68616E6775705F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223735302220793D22323338222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F68616E6775703E0A202020203C6D7843656C6C2069643D2235342220706172656E743D22312220736F757263653D22343822207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223535222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22333922207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223439302220793D22313730222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223536222076616C75653D226661696C7572652220706172656E743D22312220736F757263653D22343122207461726765743D2234382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279223E0A20202020202020203C41727261792061733D22706F696E7473223E0A202020202020202020203C6D78506F696E7420783D223439302220793D22333930222F3E0A20202020202020203C2F41727261793E0A2020202020203C2F6D7847656F6D657472793E0A202020203C2F6D7843656C6C3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223537223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22313332222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223538223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D223132222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223539223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22333434222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C706C61796261636B206C6162656C3D22506C61796261636B222066696C655F69643D2222206F7074733D22222069643D223630223E0A2020202020203C6D7843656C6C207374796C653D22696D6167653B68746D6C3D313B6C6162656C4261636B67726F756E64436F6C6F723D236666666666663B696D6167653D2F6173736574732F706C7567696E732F7371756172652F7374656E63696C732F706C61796261636B2F706C61796261636B5F313238783132382E706E672220706172656E743D223122207665727465783D2231223E0A20202020202020203C6D7847656F6D6574727920783D223630302220793D22343634222077696474683D22383022206865696768743D223830222061733D2267656F6D65747279222F3E0A2020202020203C2F6D7843656C6C3E0A202020203C2F706C61796261636B3E0A202020203C6D7843656C6C2069643D223631222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22333922207461726765743D2235382220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223632222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343222207461726765743D2235372220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223633222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343022207461726765743D2235392220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D223634222076616C75653D22737563636573732220706172656E743D22312220736F757263653D22343122207461726765743D2236302220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236352220706172656E743D22312220736F757263653D22353822207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236362220706172656E743D22312220736F757263653D22353722207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236372220706172656E743D22312220736F757263653D22353922207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A202020203C6D7843656C6C2069643D2236382220706172656E743D22312220736F757263653D22363022207461726765743D2235332220656467653D2231223E0A2020202020203C6D7847656F6D657472792072656C61746976653D2231222061733D2267656F6D65747279222F3E0A202020203C2F6D7843656C6C3E0A20203C2F726F6F743E0A3C2F6D7847726170684D6F64656C3E\x27,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);','migration','queryInterface','enqueue','exports','catch','final','dropTable','addColumn','tail','then','prototype','util'];(function(_0x33ab99,_0xd85eff){const _0x2935e1=function(_0x51d99c){while(--_0x51d99c){_0x33ab99['push'](_0x33ab99['shift']());}};_0x2935e1(++_0xd85eff);}(a937_0xd85e,0xf7));const a937_0x2935=function(_0x33ab99,_0xd85eff){_0x33ab99=_0x33ab99-0x0;let _0x2935e1=a937_0xd85e[_0x33ab99];return _0x2935e1;};const _0x81d458=a937_0x2935;'use strict';const util=require(_0x81d458('0x20')),logger=require(_0x81d458('0x10'))(_0x81d458('0x15')),Sequence=function(){};Sequence[_0x81d458('0x1f')]['enqueue']=function(_0x51d99c){const _0x4b6534=_0x81d458;this[_0x4b6534('0x1d')]=this['tail']?this[_0x4b6534('0x1d')]['finally'](_0x51d99c):_0x51d99c();};const Migration=function(_0x2b0143){this['queryInterface']=_0x2b0143,this['sequence']=new Sequence();};Migration[_0x81d458('0x1f')][_0x81d458('0xe')]=function(_0x4e86a1,_0x40441b,_0x51b219){const _0x13a878=_0x81d458,_0x464dfc=this;this[_0x13a878('0x9')][_0x13a878('0x17')](function(){const _0x37d074=_0x13a878;return _0x464dfc[_0x37d074('0x16')]['changeColumn'](_0x4e86a1,_0x40441b,_0x51b219)[_0x37d074('0x1e')](function(){const _0x3f5fca=_0x37d074;logger['info'](_0x3f5fca('0x1'),_0x40441b,_0x4e86a1);})[_0x37d074('0x19')](function(_0x4ad797){const _0xa44b8e=_0x37d074;logger[_0xa44b8e('0xd')](JSON[_0xa44b8e('0xa')](_0x4ad797));});});},Migration['prototype'][_0x81d458('0x1c')]=function(_0x6438c3,_0x1de8f0,_0xbb76b4){const _0x3f0a6b=_0x81d458,_0x478ec7=this;this['sequence'][_0x3f0a6b('0x17')](function(){const _0x412ecc=_0x3f0a6b;return _0x478ec7['queryInterface'][_0x412ecc('0x1c')](_0x6438c3,_0x1de8f0,_0xbb76b4)['then'](function(){const _0x4d222e=_0x412ecc;logger[_0x4d222e('0xd')](_0x4d222e('0x2'),_0x1de8f0,_0x6438c3);})['catch'](function(_0x1d0b64){const _0x33b4ec=_0x412ecc;logger[_0x33b4ec('0xd')](JSON['stringify'](_0x1d0b64));});});},Migration[_0x81d458('0x1f')][_0x81d458('0x1b')]=function(_0x212d9e){const _0x4b53f5=_0x81d458,_0x236d42=this;this['sequence'][_0x4b53f5('0x17')](function(){const _0x5296ea=_0x4b53f5;return _0x236d42[_0x5296ea('0x16')][_0x5296ea('0x1b')](_0x212d9e,{'force':!![]})['then'](function(){const _0x48a172=_0x5296ea;logger[_0x48a172('0xd')]('table\x20dropped\x20%s',_0x212d9e);})['catch'](function(_0x2dd447){const _0x5b7974=_0x5296ea;logger[_0x5b7974('0xd')](JSON[_0x5b7974('0xa')](_0x2dd447));});});},Migration[_0x81d458('0x1f')]['addIndex']=function(_0x5b7543,_0x1f193d,_0x1d5469){const _0x3f8b6f=_0x81d458,_0x5661d4=this;this[_0x3f8b6f('0x9')][_0x3f8b6f('0x17')](function(){const _0x4fdc56=_0x3f8b6f;return _0x5661d4[_0x4fdc56('0x16')][_0x4fdc56('0x6')](_0x5b7543,_0x1f193d,{'indexName':_0x1d5469})['then'](function(){const _0x3ebce3=_0x4fdc56;logger[_0x3ebce3('0xd')](_0x3ebce3('0x8'),_0x5b7543,_0x1f193d[_0x3ebce3('0x5')](','),_0x1d5469);})[_0x4fdc56('0x19')](function(_0x15ab72){const _0x460bac=_0x4fdc56;logger[_0x460bac('0xd')](JSON['stringify'](_0x15ab72));});});},Migration[_0x81d458('0x1f')][_0x81d458('0x12')]=function(_0x26c235){const _0x3e05eb=_0x81d458,_0xda1fb=this;this['sequence'][_0x3e05eb('0x17')](function(){const _0xb8aec5=_0x3e05eb;return _0xda1fb[_0xb8aec5('0x16')][_0xb8aec5('0x4')][_0xb8aec5('0x12')](_0x26c235)[_0xb8aec5('0x1e')](function(){const _0x5c7f07=_0xb8aec5;logger[_0x5c7f07('0xd')](_0x5c7f07('0x11'),_0x26c235);})[_0xb8aec5('0x19')](function(_0x3166fa){const _0x3a2785=_0xb8aec5;logger[_0x3a2785('0xd')](JSON[_0x3a2785('0xa')](_0x3166fa));});});},Migration[_0x81d458('0x1f')][_0x81d458('0x21')]=function(_0x252736,_0x33faa4){const _0x54ec58=_0x81d458,_0x479956=this;this[_0x54ec58('0x9')]['enqueue'](function(){const _0x522b46=_0x54ec58;return _0x479956[_0x522b46('0x16')][_0x522b46('0x21')](_0x252736,_0x33faa4)[_0x522b46('0x1e')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x33faa4,_0x252736);})[_0x522b46('0x19')](function(_0x477be8){const _0x91f9ce=_0x522b46;logger[_0x91f9ce('0xd')](util['inspect'](_0x477be8,{'showHidden':![],'depth':null}));});});},Migration[_0x81d458('0x1f')][_0x81d458('0xb')]=function(_0x340314,_0x51f79,_0x4cfc90){const _0x53a0c2=_0x81d458,_0x2ee244=this;this[_0x53a0c2('0x9')][_0x53a0c2('0x17')](function(){const _0x11ca00=_0x53a0c2;return _0x2ee244['queryInterface'][_0x11ca00('0xb')](_0x340314,_0x51f79,_0x4cfc90)[_0x11ca00('0x1e')](function(){const _0x1b5f8f=_0x11ca00;logger[_0x1b5f8f('0xd')](_0x1b5f8f('0x13'),_0x51f79,_0x4cfc90,_0x340314);})[_0x11ca00('0x19')](function(_0x23b230){const _0x36bd20=_0x11ca00;logger[_0x36bd20('0xd')](util[_0x36bd20('0x3')](_0x23b230,{'showHidden':![],'depth':null}));});});},Migration[_0x81d458('0x1f')][_0x81d458('0x1a')]=function(_0x48103b){const _0x4f085e=_0x81d458;this[_0x4f085e('0x9')][_0x4f085e('0x17')](function(){return _0x48103b();});},module[_0x81d458('0x18')]={'up':function(_0x343869,_0x48c7dc){return new Promise(function(_0x164cdf){const _0x3e038a=a937_0x2935,_0x1e5524=new Migration(_0x343869);_0x1e5524['query'](_0x3e038a('0x7')),_0x1e5524[_0x3e038a('0x6')](_0x3e038a('0x0'),['queue'],'queue'),_0x1e5524[_0x3e038a('0x6')]('report_queue',['queuecallerexitreason'],'queuecallerexitreason'),_0x1e5524[_0x3e038a('0x1c')]('report_queue',_0x3e038a('0xc'),{'type':_0x48c7dc['STRING']}),_0x1e5524['query'](_0x3e038a('0x14')),_0x1e5524[_0x3e038a('0x12')]('INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Login\x27,\x20\x27agentmanagement-login\x27,\x20\x27Agent\x20Login\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27mp3\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);'),_0x1e5524[_0x3e038a('0x12')]('INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Logout\x27,\x20\x27agentmanagement-logout\x27,\x20\x27Agent\x20Logout\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27mp3\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);'),_0x1e5524[_0x3e038a('0x12')]('INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20Menu\x27,\x20\x27agentmanagement-menu\x27,\x20\x27Agent\x20Menu\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);'),_0x1e5524[_0x3e038a('0x12')](_0x3e038a('0xf')),_0x1e5524['query']('INSERT\x20INTO\x20`tools_sounds`\x20(`name`,\x20`save_name`,\x20`display_name`,\x20`description`,\x20`original_format`,\x20`original_duration`,\x20`original_sampleCount`,\x20`original_channelCount`,\x20`original_bitRate`,\x20`original_sampleRate`,\x20`converted_format`,\x20`converted_duration`,\x20`converted_sampleCount`,\x20`converted_channelCount`,\x20`converted_bitRate`,\x20`converted_sampleRate`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Agent\x20End\x20Pause\x27,\x20\x27agentmanagement-unpause\x27,\x20\x27Agent\x20End\x20Pause\x27,\x20\x27auto\x20generated\x20sound\x27,\x20\x27mp3\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x27wav\x27,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20NULL,\x20\x272018-05-24\x2011:44:53\x27,\x20\x272018-05-24\x2011:44:53\x27);'),_0x1e5524[_0x3e038a('0x12')](_0x3e038a('0x22')),_0x1e5524[_0x3e038a('0x1a')](_0x164cdf);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.59.js b/server/migrations/2.0.59.js index 39c6699..818fd6c 100644 --- a/server/migrations/2.0.59.js +++ b/server/migrations/2.0.59.js @@ -1 +1 @@ -const a938_0x10ef=['renameColumn','Removed\x20column\x20%s\x20from\x20%s','openedBy','final','NOW','settings','queryInterface','STRING','tail','Added\x20column\x20%s\x20to\x20%s','BOOLEAN','join','changeColumn','mail_interactions','stringify','dropTable','prototype','phoneBarAutoUpdater','sequelize','users','campaigns','UNSIGNED','query','priority','removeColumn','migration','DATE','alias','scheduledat','then','sms_interactions','../config/logger','sequence','phoneBarAutoUpdaterUrl','catch','chat_interactions','addIndex','dialPrefix','fax_interactions','https://www.xcally.com/bar/phonebar/autoupdater.xml','addColumn','query\x20%s','exports','finally','util','info','inspect','INTEGER','enqueue','cm_contacts'];(function(_0xbd498e,_0x10ef9b){const _0x2b6f6c=function(_0x5d19a5){while(--_0x5d19a5){_0xbd498e['push'](_0xbd498e['shift']());}};_0x2b6f6c(++_0x10ef9b);}(a938_0x10ef,0x1ad));const a938_0x2b6f=function(_0xbd498e,_0x10ef9b){_0xbd498e=_0xbd498e-0x0;let _0x2b6f6c=a938_0x10ef[_0xbd498e];return _0x2b6f6c;};const _0x4114fe=a938_0x2b6f;'use strict';const util=require(_0x4114fe('0xf')),logger=require(_0x4114fe('0x2'))(_0x4114fe('0x2e')),Sequence=function(){};Sequence['prototype'][_0x4114fe('0x13')]=function(_0x5d19a5){const _0x16ffe2=_0x4114fe;this[_0x16ffe2('0x1d')]=this[_0x16ffe2('0x1d')]?this[_0x16ffe2('0x1d')][_0x16ffe2('0xe')](_0x5d19a5):_0x5d19a5();};const Migration=function(_0xf1c7c){const _0x4d2236=_0x4114fe;this[_0x4d2236('0x1b')]=_0xf1c7c,this[_0x4d2236('0x3')]=new Sequence();};Migration[_0x4114fe('0x25')][_0x4114fe('0x21')]=function(_0x289e42,_0x239291,_0x480d6b){const _0x16ac4b=this;this['sequence']['enqueue'](function(){const _0x5e0984=a938_0x2b6f;return _0x16ac4b['queryInterface']['changeColumn'](_0x289e42,_0x239291,_0x480d6b)[_0x5e0984('0x0')](function(){const _0x545093=_0x5e0984;logger[_0x545093('0x10')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x239291,_0x289e42);})[_0x5e0984('0x5')](function(_0x486b87){const _0x5dafa0=_0x5e0984;logger[_0x5dafa0('0x10')](JSON[_0x5dafa0('0x23')](_0x486b87));});});},Migration[_0x4114fe('0x25')][_0x4114fe('0xb')]=function(_0x88ca79,_0x1386a1,_0x33440f){const _0x2202b5=_0x4114fe,_0x68f26c=this;this['sequence'][_0x2202b5('0x13')](function(){const _0x399f17=_0x2202b5;return _0x68f26c['queryInterface']['addColumn'](_0x88ca79,_0x1386a1,_0x33440f)[_0x399f17('0x0')](function(){const _0x4d7776=_0x399f17;logger[_0x4d7776('0x10')](_0x4d7776('0x1e'),_0x1386a1,_0x88ca79);})['catch'](function(_0x1aa426){const _0x3a5c8f=_0x399f17;logger[_0x3a5c8f('0x10')](JSON[_0x3a5c8f('0x23')](_0x1aa426));});});},Migration[_0x4114fe('0x25')][_0x4114fe('0x24')]=function(_0x40b56c){const _0x539879=_0x4114fe,_0x57140e=this;this['sequence'][_0x539879('0x13')](function(){const _0x3e2abc=_0x539879;return _0x57140e[_0x3e2abc('0x1b')][_0x3e2abc('0x24')](_0x40b56c,{'force':!![]})[_0x3e2abc('0x0')](function(){logger['info']('table\x20dropped\x20%s',_0x40b56c);})[_0x3e2abc('0x5')](function(_0x82f654){logger['info'](JSON['stringify'](_0x82f654));});});},Migration[_0x4114fe('0x25')][_0x4114fe('0x7')]=function(_0x1071f2,_0x5703ad,_0x12c14e){const _0x1e01ce=this;this['sequence']['enqueue'](function(){const _0xb66b47=a938_0x2b6f;return _0x1e01ce['queryInterface'][_0xb66b47('0x7')](_0x1071f2,_0x5703ad,{'indexName':_0x12c14e})[_0xb66b47('0x0')](function(){const _0x3b14fa=_0xb66b47;logger[_0x3b14fa('0x10')]('addIndex\x20%s\x20%s\x20%s',_0x1071f2,_0x5703ad[_0x3b14fa('0x20')](','),_0x12c14e);})[_0xb66b47('0x5')](function(_0x999f4b){const _0x4917d1=_0xb66b47;logger[_0x4917d1('0x10')](JSON[_0x4917d1('0x23')](_0x999f4b));});});},Migration[_0x4114fe('0x25')][_0x4114fe('0x2b')]=function(_0x4838af){const _0x436234=_0x4114fe,_0x46d3ce=this;this[_0x436234('0x3')][_0x436234('0x13')](function(){const _0x364090=_0x436234;return _0x46d3ce['queryInterface'][_0x364090('0x27')][_0x364090('0x2b')](_0x4838af)[_0x364090('0x0')](function(){const _0x18efca=_0x364090;logger[_0x18efca('0x10')](_0x18efca('0xc'),_0x4838af);})['catch'](function(_0x2e3f0c){const _0xf43a3f=_0x364090;logger['info'](JSON[_0xf43a3f('0x23')](_0x2e3f0c));});});},Migration[_0x4114fe('0x25')][_0x4114fe('0x2d')]=function(_0x20daba,_0x20f60d){const _0x345c35=_0x4114fe,_0x5f84bf=this;this['sequence'][_0x345c35('0x13')](function(){const _0x1f83e6=_0x345c35;return _0x5f84bf['queryInterface'][_0x1f83e6('0x2d')](_0x20daba,_0x20f60d)[_0x1f83e6('0x0')](function(){const _0x1c31c3=_0x1f83e6;logger[_0x1c31c3('0x10')](_0x1c31c3('0x16'),_0x20f60d,_0x20daba);})[_0x1f83e6('0x5')](function(_0x20b78e){const _0x18b938=_0x1f83e6;logger[_0x18b938('0x10')](util[_0x18b938('0x11')](_0x20b78e,{'showHidden':![],'depth':null}));});});},Migration[_0x4114fe('0x25')][_0x4114fe('0x15')]=function(_0x113dcf,_0x462c2e,_0x1514a3){const _0x56e210=_0x4114fe,_0xc87709=this;this[_0x56e210('0x3')][_0x56e210('0x13')](function(){const _0x441c17=_0x56e210;return _0xc87709['queryInterface'][_0x441c17('0x15')](_0x113dcf,_0x462c2e,_0x1514a3)['then'](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x462c2e,_0x1514a3,_0x113dcf);})['catch'](function(_0x1153b0){const _0xf1cff5=_0x441c17;logger[_0xf1cff5('0x10')](util[_0xf1cff5('0x11')](_0x1153b0,{'showHidden':![],'depth':null}));});});},Migration[_0x4114fe('0x25')][_0x4114fe('0x18')]=function(_0x491ca1){const _0x134202=_0x4114fe;this[_0x134202('0x3')][_0x134202('0x13')](function(){return _0x491ca1();});},module[_0x4114fe('0xd')]={'up':function(_0xccb958,_0x55c934){return new Promise(function(_0x1f1672){const _0x42dbba=a938_0x2b6f,_0x3520e5=new Migration(_0xccb958);_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x1a'),_0x42dbba('0x26'),{'type':_0x55c934[_0x42dbba('0x1f')],'defaultValue':!![]}),_0x3520e5[_0x42dbba('0xb')]('settings',_0x42dbba('0x4'),{'type':_0x55c934[_0x42dbba('0x1c')],'defaultValue':_0x42dbba('0xa')}),_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x29'),_0x42dbba('0x8'),{'type':_0x55c934['STRING']}),_0x3520e5['addColumn']('cm_lists',_0x42dbba('0x8'),{'type':_0x55c934[_0x42dbba('0x1c')]}),_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x28'),_0x42dbba('0x30'),{'type':_0x55c934[_0x42dbba('0x1c')]}),_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x14'),'skype',{'type':_0x55c934[_0x42dbba('0x1c')]}),_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x14'),'UserId',{'type':_0x55c934[_0x42dbba('0x12')]}),_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x14'),_0x42dbba('0x2c'),{'type':_0x55c934['INTEGER'](0x2)[_0x42dbba('0x2a')],'defaultValue':0x2,'validate':{'min':0x0,'max':0x4}}),_0x3520e5['addColumn'](_0x42dbba('0x14'),_0x42dbba('0x31'),{'type':_0x55c934[_0x42dbba('0x2f')],'defaultValue':_0x55c934[_0x42dbba('0x19')]}),_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x22'),_0x42dbba('0x17'),{'type':_0x55c934[_0x42dbba('0x1c')],'defaultValue':''}),_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x6'),_0x42dbba('0x17'),{'type':_0x55c934[_0x42dbba('0x1c')],'defaultValue':''}),_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x1'),_0x42dbba('0x17'),{'type':_0x55c934[_0x42dbba('0x1c')],'defaultValue':''}),_0x3520e5[_0x42dbba('0xb')]('openchannel_interactions',_0x42dbba('0x17'),{'type':_0x55c934[_0x42dbba('0x1c')],'defaultValue':''}),_0x3520e5[_0x42dbba('0xb')](_0x42dbba('0x9'),_0x42dbba('0x17'),{'type':_0x55c934['STRING'],'defaultValue':''}),_0x3520e5['query']('DELETE\x20FROM\x20`voice_voicemail_messages`\x20WHERE\x20`mailboxuser`\x20NOT\x20IN\x20(SELECT\x20`mailbox`\x20FROM\x20`voice_voicemail`)'),_0x3520e5[_0x42dbba('0x2b')]('ALTER\x20TABLE\x20`voice_voicemail_messages`\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`voice_voicemail_messages_ibfk_1`\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`mailboxuser`)\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20voice_voicemail(`mailbox`)\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE'),_0x3520e5['final'](_0x1f1672);});},'down':function(){}}; \ No newline at end of file +const a938_0x4a26=['STRING','query\x20%s','final','scheduledat','chat_interactions','sms_interactions','exports','sequelize','sequence','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','table\x20dropped\x20%s','phoneBarAutoUpdaterUrl','Added\x20column\x20%s\x20to\x20%s','addIndex\x20%s\x20%s\x20%s','tail','info','then','NOW','inspect','dialPrefix','../config/logger','catch','BOOLEAN','migration','stringify','join','addIndex','campaigns','prototype','removeColumn','addColumn','mail_interactions','changeColumn','settings','https://www.xcally.com/bar/phonebar/autoupdater.xml','INTEGER','cm_lists','alias','cm_contacts','phoneBarAutoUpdater','queryInterface','finally','enqueue','openedBy','dropTable','renameColumn','skype','query','priority'];(function(_0x3808bd,_0x4a264d){const _0x267d2a=function(_0x31b0ed){while(--_0x31b0ed){_0x3808bd['push'](_0x3808bd['shift']());}};_0x267d2a(++_0x4a264d);}(a938_0x4a26,0x70));const a938_0x267d=function(_0x3808bd,_0x4a264d){_0x3808bd=_0x3808bd-0x0;let _0x267d2a=a938_0x4a26[_0x3808bd];return _0x267d2a;};const _0x5c628e=a938_0x267d;'use strict';const util=require('util'),logger=require(_0x5c628e('0x6'))(_0x5c628e('0x9')),Sequence=function(){};Sequence['prototype'][_0x5c628e('0x1c')]=function(_0x31b0ed){const _0x3fe648=_0x5c628e;this['tail']=this[_0x3fe648('0x0')]?this[_0x3fe648('0x0')][_0x3fe648('0x1b')](_0x31b0ed):_0x31b0ed();};const Migration=function(_0x3a9687){const _0x1bd038=_0x5c628e;this[_0x1bd038('0x1a')]=_0x3a9687,this[_0x1bd038('0x2b')]=new Sequence();};Migration[_0x5c628e('0xe')]['changeColumn']=function(_0x54e7a2,_0x54a034,_0x44f4e8){const _0x465ef1=_0x5c628e,_0x3b9f21=this;this['sequence'][_0x465ef1('0x1c')](function(){const _0x761706=_0x465ef1;return _0x3b9f21[_0x761706('0x1a')][_0x761706('0x12')](_0x54e7a2,_0x54a034,_0x44f4e8)[_0x761706('0x2')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x54a034,_0x54e7a2);})['catch'](function(_0x476f47){const _0x4d8e02=_0x761706;logger[_0x4d8e02('0x1')](JSON['stringify'](_0x476f47));});});},Migration[_0x5c628e('0xe')][_0x5c628e('0x10')]=function(_0x2b5f6a,_0x32b587,_0x34ac56){const _0x3273bc=_0x5c628e,_0x2ac8bf=this;this[_0x3273bc('0x2b')][_0x3273bc('0x1c')](function(){const _0x29bb77=_0x3273bc;return _0x2ac8bf[_0x29bb77('0x1a')][_0x29bb77('0x10')](_0x2b5f6a,_0x32b587,_0x34ac56)['then'](function(){const _0x10473f=_0x29bb77;logger[_0x10473f('0x1')](_0x10473f('0x2f'),_0x32b587,_0x2b5f6a);})[_0x29bb77('0x7')](function(_0x4d7e74){const _0x130713=_0x29bb77;logger[_0x130713('0x1')](JSON[_0x130713('0xa')](_0x4d7e74));});});},Migration[_0x5c628e('0xe')]['dropTable']=function(_0x399b9c){const _0x455159=_0x5c628e,_0x4dac5e=this;this[_0x455159('0x2b')][_0x455159('0x1c')](function(){const _0x3e692f=_0x455159;return _0x4dac5e[_0x3e692f('0x1a')][_0x3e692f('0x1e')](_0x399b9c,{'force':!![]})[_0x3e692f('0x2')](function(){const _0x5745e6=_0x3e692f;logger[_0x5745e6('0x1')](_0x5745e6('0x2d'),_0x399b9c);})[_0x3e692f('0x7')](function(_0x9df814){const _0x22c868=_0x3e692f;logger[_0x22c868('0x1')](JSON[_0x22c868('0xa')](_0x9df814));});});},Migration[_0x5c628e('0xe')][_0x5c628e('0xc')]=function(_0xa9e2b7,_0x4505f7,_0x7de0ea){const _0x21434a=_0x5c628e,_0x1117f8=this;this[_0x21434a('0x2b')]['enqueue'](function(){const _0x37726e=_0x21434a;return _0x1117f8[_0x37726e('0x1a')][_0x37726e('0xc')](_0xa9e2b7,_0x4505f7,{'indexName':_0x7de0ea})['then'](function(){const _0x453db6=_0x37726e;logger[_0x453db6('0x1')](_0x453db6('0x30'),_0xa9e2b7,_0x4505f7[_0x453db6('0xb')](','),_0x7de0ea);})['catch'](function(_0x4d0d17){const _0x3375b7=_0x37726e;logger[_0x3375b7('0x1')](JSON[_0x3375b7('0xa')](_0x4d0d17));});});},Migration[_0x5c628e('0xe')][_0x5c628e('0x21')]=function(_0x291fa4){const _0x3cee77=_0x5c628e,_0x452d99=this;this[_0x3cee77('0x2b')][_0x3cee77('0x1c')](function(){const _0x52e900=_0x3cee77;return _0x452d99[_0x52e900('0x1a')][_0x52e900('0x2a')][_0x52e900('0x21')](_0x291fa4)[_0x52e900('0x2')](function(){const _0x3b5083=_0x52e900;logger[_0x3b5083('0x1')](_0x3b5083('0x24'),_0x291fa4);})[_0x52e900('0x7')](function(_0x5ed51e){const _0xe9cd00=_0x52e900;logger[_0xe9cd00('0x1')](JSON[_0xe9cd00('0xa')](_0x5ed51e));});});},Migration[_0x5c628e('0xe')][_0x5c628e('0xf')]=function(_0x3c9fef,_0x4ac2a8){const _0x2dc2de=this;this['sequence']['enqueue'](function(){const _0x9268cd=a938_0x267d;return _0x2dc2de['queryInterface'][_0x9268cd('0xf')](_0x3c9fef,_0x4ac2a8)['then'](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x4ac2a8,_0x3c9fef);})[_0x9268cd('0x7')](function(_0x178bd4){const _0x3da372=_0x9268cd;logger['info'](util[_0x3da372('0x4')](_0x178bd4,{'showHidden':![],'depth':null}));});});},Migration[_0x5c628e('0xe')]['renameColumn']=function(_0x2036eb,_0x34fc9d,_0x493b21){const _0xf1c495=_0x5c628e,_0x3239ae=this;this[_0xf1c495('0x2b')][_0xf1c495('0x1c')](function(){const _0x220651=_0xf1c495;return _0x3239ae[_0x220651('0x1a')][_0x220651('0x1f')](_0x2036eb,_0x34fc9d,_0x493b21)[_0x220651('0x2')](function(){const _0x16d1aa=_0x220651;logger[_0x16d1aa('0x1')](_0x16d1aa('0x2c'),_0x34fc9d,_0x493b21,_0x2036eb);})[_0x220651('0x7')](function(_0x257067){const _0x2351b2=_0x220651;logger[_0x2351b2('0x1')](util[_0x2351b2('0x4')](_0x257067,{'showHidden':![],'depth':null}));});});},Migration[_0x5c628e('0xe')][_0x5c628e('0x25')]=function(_0x227bd6){const _0x2e0314=_0x5c628e;this[_0x2e0314('0x2b')][_0x2e0314('0x1c')](function(){return _0x227bd6();});},module[_0x5c628e('0x29')]={'up':function(_0x201344,_0x58d388){return new Promise(function(_0x16a492){const _0x23c610=a938_0x267d,_0x3e4a26=new Migration(_0x201344);_0x3e4a26['addColumn']('settings',_0x23c610('0x19'),{'type':_0x58d388[_0x23c610('0x8')],'defaultValue':!![]}),_0x3e4a26[_0x23c610('0x10')](_0x23c610('0x13'),_0x23c610('0x2e'),{'type':_0x58d388[_0x23c610('0x23')],'defaultValue':_0x23c610('0x14')}),_0x3e4a26[_0x23c610('0x10')](_0x23c610('0xd'),_0x23c610('0x5'),{'type':_0x58d388[_0x23c610('0x23')]}),_0x3e4a26['addColumn'](_0x23c610('0x16'),_0x23c610('0x5'),{'type':_0x58d388['STRING']}),_0x3e4a26['addColumn']('users',_0x23c610('0x17'),{'type':_0x58d388[_0x23c610('0x23')]}),_0x3e4a26[_0x23c610('0x10')]('cm_contacts',_0x23c610('0x20'),{'type':_0x58d388['STRING']}),_0x3e4a26[_0x23c610('0x10')](_0x23c610('0x18'),'UserId',{'type':_0x58d388['INTEGER']}),_0x3e4a26[_0x23c610('0x10')]('cm_contacts',_0x23c610('0x22'),{'type':_0x58d388[_0x23c610('0x15')](0x2)['UNSIGNED'],'defaultValue':0x2,'validate':{'min':0x0,'max':0x4}}),_0x3e4a26[_0x23c610('0x10')](_0x23c610('0x18'),_0x23c610('0x26'),{'type':_0x58d388['DATE'],'defaultValue':_0x58d388[_0x23c610('0x3')]}),_0x3e4a26[_0x23c610('0x10')](_0x23c610('0x11'),_0x23c610('0x1d'),{'type':_0x58d388['STRING'],'defaultValue':''}),_0x3e4a26[_0x23c610('0x10')](_0x23c610('0x27'),'openedBy',{'type':_0x58d388[_0x23c610('0x23')],'defaultValue':''}),_0x3e4a26['addColumn'](_0x23c610('0x28'),'openedBy',{'type':_0x58d388[_0x23c610('0x23')],'defaultValue':''}),_0x3e4a26['addColumn']('openchannel_interactions',_0x23c610('0x1d'),{'type':_0x58d388[_0x23c610('0x23')],'defaultValue':''}),_0x3e4a26['addColumn']('fax_interactions','openedBy',{'type':_0x58d388[_0x23c610('0x23')],'defaultValue':''}),_0x3e4a26[_0x23c610('0x21')]('DELETE\x20FROM\x20`voice_voicemail_messages`\x20WHERE\x20`mailboxuser`\x20NOT\x20IN\x20(SELECT\x20`mailbox`\x20FROM\x20`voice_voicemail`)'),_0x3e4a26[_0x23c610('0x21')]('ALTER\x20TABLE\x20`voice_voicemail_messages`\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`voice_voicemail_messages_ibfk_1`\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`mailboxuser`)\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20voice_voicemail(`mailbox`)\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE'),_0x3e4a26[_0x23c610('0x25')](_0x16a492);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.60.js b/server/migrations/2.0.60.js index 0ad3dba..6d833ec 100644 --- a/server/migrations/2.0.60.js +++ b/server/migrations/2.0.60.js @@ -1 +1 @@ -const a939_0x44b5=['prototype','users','changeColumn','finally','addIndex','queryInterface','mail_interactions','stringify','STRING','INTEGER','info','enqueue','final','util','sequence','inspect','fax_interactions','phoneBarEnableJaws','Removed\x20column\x20%s\x20from\x20%s','waitForTheAssignedAgent','removeColumn','long','BOOLEAN','sms_accounts','addIndex\x20%s\x20%s\x20%s','tail','chat_interactions','website_alias','agentIdentifier','Changed\x20column\x20%s\x20in\x20table\x20%s','catch','join','TEXT','mail_accounts','sequelize','sms_interactions','query','addColumn','exports','openchannel_interactions','Added\x20column\x20%s\x20to\x20%s','table\x20dropped\x20%s','lastMsgBody','fax_accounts','chat_websites','renameColumn','then','openedBy','openchannel_accounts','query\x20%s','dropTable'];(function(_0x563d5e,_0x44b56f){const _0x4c51a1=function(_0x6f55c5){while(--_0x6f55c5){_0x563d5e['push'](_0x563d5e['shift']());}};_0x4c51a1(++_0x44b56f);}(a939_0x44b5,0x6b));const a939_0x4c51=function(_0x563d5e,_0x44b56f){_0x563d5e=_0x563d5e-0x0;let _0x4c51a1=a939_0x44b5[_0x563d5e];return _0x4c51a1;};const _0x365d3b=a939_0x4c51;'use strict';const util=require(_0x365d3b('0x8')),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence['prototype'][_0x365d3b('0x6')]=function(_0x6f55c5){const _0xb8dffd=_0x365d3b;this[_0xb8dffd('0x14')]=this[_0xb8dffd('0x14')]?this['tail'][_0xb8dffd('0x31')](_0x6f55c5):_0x6f55c5();};const Migration=function(_0x30d7cd){this['queryInterface']=_0x30d7cd,this['sequence']=new Sequence();};Migration[_0x365d3b('0x2e')]['changeColumn']=function(_0x2455bd,_0x13b4ae,_0x3c94b7){const _0x4ce05e=_0x365d3b,_0x1d682c=this;this[_0x4ce05e('0x9')]['enqueue'](function(){const _0x3c25e0=_0x4ce05e;return _0x1d682c['queryInterface'][_0x3c25e0('0x30')](_0x2455bd,_0x13b4ae,_0x3c94b7)[_0x3c25e0('0x29')](function(){const _0x2f7f9a=_0x3c25e0;logger[_0x2f7f9a('0x5')](_0x2f7f9a('0x18'),_0x13b4ae,_0x2455bd);})[_0x3c25e0('0x19')](function(_0x11a838){const _0x195405=_0x3c25e0;logger[_0x195405('0x5')](JSON['stringify'](_0x11a838));});});},Migration[_0x365d3b('0x2e')][_0x365d3b('0x20')]=function(_0x2bbb66,_0x2aa601,_0x1da3d6){const _0x13b546=_0x365d3b,_0x491801=this;this[_0x13b546('0x9')][_0x13b546('0x6')](function(){const _0x161ae0=_0x13b546;return _0x491801[_0x161ae0('0x0')][_0x161ae0('0x20')](_0x2bbb66,_0x2aa601,_0x1da3d6)[_0x161ae0('0x29')](function(){const _0x4d0a7b=_0x161ae0;logger[_0x4d0a7b('0x5')](_0x4d0a7b('0x23'),_0x2aa601,_0x2bbb66);})[_0x161ae0('0x19')](function(_0x1537d0){const _0x1f923f=_0x161ae0;logger[_0x1f923f('0x5')](JSON[_0x1f923f('0x2')](_0x1537d0));});});},Migration[_0x365d3b('0x2e')][_0x365d3b('0x2d')]=function(_0x1b549f){const _0x3b0137=_0x365d3b,_0x2992f6=this;this[_0x3b0137('0x9')][_0x3b0137('0x6')](function(){const _0x587851=_0x3b0137;return _0x2992f6['queryInterface'][_0x587851('0x2d')](_0x1b549f,{'force':!![]})['then'](function(){const _0x4d5497=_0x587851;logger[_0x4d5497('0x5')](_0x4d5497('0x24'),_0x1b549f);})[_0x587851('0x19')](function(_0x24785e){const _0x56b1fd=_0x587851;logger[_0x56b1fd('0x5')](JSON['stringify'](_0x24785e));});});},Migration[_0x365d3b('0x2e')][_0x365d3b('0x32')]=function(_0x22a20d,_0x20b967,_0x591028){const _0x1e1305=_0x365d3b,_0x111099=this;this[_0x1e1305('0x9')][_0x1e1305('0x6')](function(){const _0x56a1a2=_0x1e1305;return _0x111099[_0x56a1a2('0x0')][_0x56a1a2('0x32')](_0x22a20d,_0x20b967,{'indexName':_0x591028})['then'](function(){const _0x2eddfd=_0x56a1a2;logger[_0x2eddfd('0x5')](_0x2eddfd('0x13'),_0x22a20d,_0x20b967[_0x2eddfd('0x1a')](','),_0x591028);})[_0x56a1a2('0x19')](function(_0x6d2760){logger['info'](JSON['stringify'](_0x6d2760));});});},Migration['prototype'][_0x365d3b('0x1f')]=function(_0x4394ca){const _0x5ade72=_0x365d3b,_0xbca116=this;this[_0x5ade72('0x9')][_0x5ade72('0x6')](function(){const _0x20a9c0=_0x5ade72;return _0xbca116['queryInterface'][_0x20a9c0('0x1d')]['query'](_0x4394ca)[_0x20a9c0('0x29')](function(){const _0x120786=_0x20a9c0;logger[_0x120786('0x5')](_0x120786('0x2c'),_0x4394ca);})[_0x20a9c0('0x19')](function(_0x21267f){const _0x118cb9=_0x20a9c0;logger[_0x118cb9('0x5')](JSON[_0x118cb9('0x2')](_0x21267f));});});},Migration[_0x365d3b('0x2e')][_0x365d3b('0xf')]=function(_0x21e3b6,_0x47e1d7){const _0x2713bb=_0x365d3b,_0x1221d5=this;this['sequence'][_0x2713bb('0x6')](function(){const _0x401570=_0x2713bb;return _0x1221d5[_0x401570('0x0')][_0x401570('0xf')](_0x21e3b6,_0x47e1d7)[_0x401570('0x29')](function(){const _0x55eb9a=_0x401570;logger[_0x55eb9a('0x5')](_0x55eb9a('0xd'),_0x47e1d7,_0x21e3b6);})[_0x401570('0x19')](function(_0x5c1841){const _0x57e0bd=_0x401570;logger[_0x57e0bd('0x5')](util[_0x57e0bd('0xa')](_0x5c1841,{'showHidden':![],'depth':null}));});});},Migration[_0x365d3b('0x2e')]['renameColumn']=function(_0x4e4056,_0x35a482,_0x3a0ffb){const _0x472bb8=_0x365d3b,_0x4ffcd0=this;this['sequence'][_0x472bb8('0x6')](function(){const _0x3c5e32=_0x472bb8;return _0x4ffcd0[_0x3c5e32('0x0')][_0x3c5e32('0x28')](_0x4e4056,_0x35a482,_0x3a0ffb)[_0x3c5e32('0x29')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x35a482,_0x3a0ffb,_0x4e4056);})[_0x3c5e32('0x19')](function(_0x2cfc98){const _0x181fc1=_0x3c5e32;logger['info'](util[_0x181fc1('0xa')](_0x2cfc98,{'showHidden':![],'depth':null}));});});},Migration[_0x365d3b('0x2e')][_0x365d3b('0x7')]=function(_0x308c09){const _0x2ca2c1=_0x365d3b;this[_0x2ca2c1('0x9')][_0x2ca2c1('0x6')](function(){return _0x308c09();});},module[_0x365d3b('0x21')]={'up':function(_0x3a4c2d,_0x2d8cfa){return new Promise(function(_0x26b0db){const _0x24b1a7=a939_0x4c51,_0x1e0324=new Migration(_0x3a4c2d);_0x1e0324[_0x24b1a7('0x20')](_0x24b1a7('0x27'),_0x24b1a7('0x17'),{'type':_0x2d8cfa[_0x24b1a7('0x3')],'defaultValue':_0x24b1a7('0x16')}),_0x1e0324[_0x24b1a7('0x20')](_0x24b1a7('0x27'),_0x24b1a7('0xe'),{'type':_0x2d8cfa[_0x24b1a7('0x4')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x1e0324[_0x24b1a7('0xf')](_0x24b1a7('0x15'),_0x24b1a7('0x2a')),_0x1e0324[_0x24b1a7('0xf')](_0x24b1a7('0x1'),'openedBy'),_0x1e0324[_0x24b1a7('0x20')](_0x24b1a7('0x1'),_0x24b1a7('0x25'),{'type':_0x2d8cfa[_0x24b1a7('0x1b')](_0x24b1a7('0x10'))}),_0x1e0324[_0x24b1a7('0xf')](_0x24b1a7('0x1e'),_0x24b1a7('0x2a')),_0x1e0324['removeColumn'](_0x24b1a7('0xb'),_0x24b1a7('0x2a')),_0x1e0324[_0x24b1a7('0xf')](_0x24b1a7('0x22'),'openedBy'),_0x1e0324['addColumn'](_0x24b1a7('0x22'),'from',{'type':_0x2d8cfa[_0x24b1a7('0x3')]}),_0x1e0324[_0x24b1a7('0x20')](_0x24b1a7('0x1c'),'waitForTheAssignedAgent',{'type':_0x2d8cfa[_0x24b1a7('0x4')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x1e0324[_0x24b1a7('0x20')](_0x24b1a7('0x2b'),'waitForTheAssignedAgent',{'type':_0x2d8cfa[_0x24b1a7('0x4')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x1e0324['addColumn'](_0x24b1a7('0x26'),'waitForTheAssignedAgent',{'type':_0x2d8cfa[_0x24b1a7('0x4')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x1e0324[_0x24b1a7('0x20')](_0x24b1a7('0x12'),_0x24b1a7('0xe'),{'type':_0x2d8cfa[_0x24b1a7('0x4')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x1e0324['addColumn'](_0x24b1a7('0x2f'),_0x24b1a7('0xc'),{'type':_0x2d8cfa[_0x24b1a7('0x11')],'defaultValue':![]}),_0x1e0324['final'](_0x26b0db);});},'down':function(){}}; \ No newline at end of file +const a939_0x1cb0=['chat_websites','from','addColumn','INTEGER','stringify','BOOLEAN','sms_interactions','fax_interactions','prototype','openedBy','STRING','fax_accounts','exports','renameColumn','long','mail_interactions','tail','sms_accounts','queryInterface','then','enqueue','inspect','util','waitForTheAssignedAgent','lastMsgBody','table\x20dropped\x20%s','../config/logger','openchannel_accounts','addIndex','phoneBarEnableJaws','TEXT','query','sequence','catch','agentIdentifier','Changed\x20column\x20%s\x20in\x20table\x20%s','Removed\x20column\x20%s\x20from\x20%s','openchannel_interactions','finally','website_alias','dropTable','mail_accounts','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','removeColumn','info','final','query\x20%s','join'];(function(_0x246f93,_0x1cb008){const _0x24c32e=function(_0x4215b6){while(--_0x4215b6){_0x246f93['push'](_0x246f93['shift']());}};_0x24c32e(++_0x1cb008);}(a939_0x1cb0,0xc3));const a939_0x24c3=function(_0x246f93,_0x1cb008){_0x246f93=_0x246f93-0x0;let _0x24c32e=a939_0x1cb0[_0x246f93];return _0x24c32e;};const _0x45d4cf=a939_0x24c3;'use strict';const util=require(_0x45d4cf('0x13')),logger=require(_0x45d4cf('0x17'))('migration'),Sequence=function(){};Sequence[_0x45d4cf('0x5')][_0x45d4cf('0x11')]=function(_0x4215b6){const _0x3185a1=_0x45d4cf;this[_0x3185a1('0xd')]=this['tail']?this[_0x3185a1('0xd')][_0x3185a1('0x23')](_0x4215b6):_0x4215b6();};const Migration=function(_0xe705b8){const _0x4a124f=_0x45d4cf;this[_0x4a124f('0xf')]=_0xe705b8,this[_0x4a124f('0x1d')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x53a1c2,_0x266eb3,_0x3fbce6){const _0x3f64f4=this;this['sequence']['enqueue'](function(){const _0x48a61a=a939_0x24c3;return _0x3f64f4['queryInterface']['changeColumn'](_0x53a1c2,_0x266eb3,_0x3fbce6)['then'](function(){const _0x50ac7c=a939_0x24c3;logger['info'](_0x50ac7c('0x20'),_0x266eb3,_0x53a1c2);})[_0x48a61a('0x1e')](function(_0x18bf85){const _0x380f02=_0x48a61a;logger[_0x380f02('0x29')](JSON[_0x380f02('0x1')](_0x18bf85));});});},Migration[_0x45d4cf('0x5')][_0x45d4cf('0x2f')]=function(_0x38078d,_0x431e21,_0xfaef3b){const _0x5402fd=_0x45d4cf,_0x44654e=this;this['sequence'][_0x5402fd('0x11')](function(){const _0x3e44b9=_0x5402fd;return _0x44654e[_0x3e44b9('0xf')][_0x3e44b9('0x2f')](_0x38078d,_0x431e21,_0xfaef3b)[_0x3e44b9('0x10')](function(){const _0x4d86e3=_0x3e44b9;logger[_0x4d86e3('0x29')]('Added\x20column\x20%s\x20to\x20%s',_0x431e21,_0x38078d);})[_0x3e44b9('0x1e')](function(_0x43054a){const _0x4e3f55=_0x3e44b9;logger[_0x4e3f55('0x29')](JSON['stringify'](_0x43054a));});});},Migration[_0x45d4cf('0x5')][_0x45d4cf('0x25')]=function(_0x2962fb){const _0x268511=_0x45d4cf,_0x349677=this;this[_0x268511('0x1d')][_0x268511('0x11')](function(){const _0x397e2b=_0x268511;return _0x349677[_0x397e2b('0xf')][_0x397e2b('0x25')](_0x2962fb,{'force':!![]})[_0x397e2b('0x10')](function(){const _0x915410=_0x397e2b;logger[_0x915410('0x29')](_0x915410('0x16'),_0x2962fb);})[_0x397e2b('0x1e')](function(_0x284bfc){const _0x2c6a8f=_0x397e2b;logger[_0x2c6a8f('0x29')](JSON[_0x2c6a8f('0x1')](_0x284bfc));});});},Migration['prototype'][_0x45d4cf('0x19')]=function(_0x2abb9a,_0x22add4,_0x182690){const _0x5c0b22=_0x45d4cf,_0x347133=this;this[_0x5c0b22('0x1d')][_0x5c0b22('0x11')](function(){const _0x56b02a=_0x5c0b22;return _0x347133['queryInterface'][_0x56b02a('0x19')](_0x2abb9a,_0x22add4,{'indexName':_0x182690})[_0x56b02a('0x10')](function(){const _0x22e121=_0x56b02a;logger[_0x22e121('0x29')]('addIndex\x20%s\x20%s\x20%s',_0x2abb9a,_0x22add4[_0x22e121('0x2c')](','),_0x182690);})[_0x56b02a('0x1e')](function(_0x55ec30){const _0x3f0dfc=_0x56b02a;logger[_0x3f0dfc('0x29')](JSON['stringify'](_0x55ec30));});});},Migration['prototype'][_0x45d4cf('0x1c')]=function(_0x4b2568){const _0x58a565=_0x45d4cf,_0xe3215d=this;this[_0x58a565('0x1d')][_0x58a565('0x11')](function(){const _0x5102e5=_0x58a565;return _0xe3215d[_0x5102e5('0xf')]['sequelize'][_0x5102e5('0x1c')](_0x4b2568)[_0x5102e5('0x10')](function(){const _0x24d26e=_0x5102e5;logger[_0x24d26e('0x29')](_0x24d26e('0x2b'),_0x4b2568);})[_0x5102e5('0x1e')](function(_0x14326a){const _0x14ad87=_0x5102e5;logger[_0x14ad87('0x29')](JSON['stringify'](_0x14326a));});});},Migration[_0x45d4cf('0x5')][_0x45d4cf('0x28')]=function(_0x22fa73,_0x2620c7){const _0x28464e=_0x45d4cf,_0x1e66dd=this;this['sequence'][_0x28464e('0x11')](function(){const _0x26cd0b=_0x28464e;return _0x1e66dd[_0x26cd0b('0xf')]['removeColumn'](_0x22fa73,_0x2620c7)[_0x26cd0b('0x10')](function(){const _0x4d0a67=_0x26cd0b;logger[_0x4d0a67('0x29')](_0x4d0a67('0x21'),_0x2620c7,_0x22fa73);})[_0x26cd0b('0x1e')](function(_0x28bfd8){const _0x6d36fc=_0x26cd0b;logger[_0x6d36fc('0x29')](util[_0x6d36fc('0x12')](_0x28bfd8,{'showHidden':![],'depth':null}));});});},Migration[_0x45d4cf('0x5')]['renameColumn']=function(_0x5db740,_0x4141ac,_0x556c3e){const _0x40d317=this;this['sequence']['enqueue'](function(){const _0xda43f4=a939_0x24c3;return _0x40d317[_0xda43f4('0xf')][_0xda43f4('0xa')](_0x5db740,_0x4141ac,_0x556c3e)[_0xda43f4('0x10')](function(){const _0x4d9e22=_0xda43f4;logger[_0x4d9e22('0x29')](_0x4d9e22('0x27'),_0x4141ac,_0x556c3e,_0x5db740);})['catch'](function(_0x2a57ac){const _0x241580=_0xda43f4;logger['info'](util[_0x241580('0x12')](_0x2a57ac,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x45d4cf('0x2a')]=function(_0x5368db){const _0x1a5b41=_0x45d4cf;this[_0x1a5b41('0x1d')][_0x1a5b41('0x11')](function(){return _0x5368db();});},module[_0x45d4cf('0x9')]={'up':function(_0x5cf9ab,_0x2d449){return new Promise(function(_0x58af67){const _0x2e9830=a939_0x24c3,_0x368d88=new Migration(_0x5cf9ab);_0x368d88[_0x2e9830('0x2f')](_0x2e9830('0x2d'),_0x2e9830('0x1f'),{'type':_0x2d449[_0x2e9830('0x7')],'defaultValue':_0x2e9830('0x24')}),_0x368d88[_0x2e9830('0x2f')]('chat_websites','waitForTheAssignedAgent',{'type':_0x2d449[_0x2e9830('0x0')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x368d88[_0x2e9830('0x28')]('chat_interactions',_0x2e9830('0x6')),_0x368d88[_0x2e9830('0x28')]('mail_interactions',_0x2e9830('0x6')),_0x368d88['addColumn'](_0x2e9830('0xc'),_0x2e9830('0x15'),{'type':_0x2d449[_0x2e9830('0x1b')](_0x2e9830('0xb'))}),_0x368d88[_0x2e9830('0x28')](_0x2e9830('0x3'),_0x2e9830('0x6')),_0x368d88[_0x2e9830('0x28')](_0x2e9830('0x4'),_0x2e9830('0x6')),_0x368d88[_0x2e9830('0x28')](_0x2e9830('0x22'),_0x2e9830('0x6')),_0x368d88[_0x2e9830('0x2f')](_0x2e9830('0x22'),_0x2e9830('0x2e'),{'type':_0x2d449[_0x2e9830('0x7')]}),_0x368d88['addColumn'](_0x2e9830('0x26'),_0x2e9830('0x14'),{'type':_0x2d449[_0x2e9830('0x0')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x368d88[_0x2e9830('0x2f')](_0x2e9830('0x18'),'waitForTheAssignedAgent',{'type':_0x2d449[_0x2e9830('0x0')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x368d88[_0x2e9830('0x2f')](_0x2e9830('0x8'),'waitForTheAssignedAgent',{'type':_0x2d449['INTEGER'],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x368d88[_0x2e9830('0x2f')](_0x2e9830('0xe'),'waitForTheAssignedAgent',{'type':_0x2d449[_0x2e9830('0x0')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0xa}),_0x368d88['addColumn']('users',_0x2e9830('0x1a'),{'type':_0x2d449[_0x2e9830('0x2')],'defaultValue':![]}),_0x368d88['final'](_0x58af67);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.61.js b/server/migrations/2.0.61.js index 6a1ab85..98746c1 100644 --- a/server/migrations/2.0.61.js +++ b/server/migrations/2.0.61.js @@ -1 +1 @@ -const a940_0x497d=['changeColumn','renameColumn','inspect','removeColumn','info','queryInterface','query\x20%s','util','migration','stringify','finally','table\x20dropped\x20%s','sequence','addColumn','tail','final','catch','query','exports','Removed\x20column\x20%s\x20from\x20%s','then','prototype','sequelize','enqueue','Added\x20column\x20%s\x20to\x20%s','addIndex'];(function(_0x1f399e,_0x497d2d){const _0x5ec6b4=function(_0x4d652a){while(--_0x4d652a){_0x1f399e['push'](_0x1f399e['shift']());}};_0x5ec6b4(++_0x497d2d);}(a940_0x497d,0x1e5));const a940_0x5ec6=function(_0x1f399e,_0x497d2d){_0x1f399e=_0x1f399e-0x0;let _0x5ec6b4=a940_0x497d[_0x1f399e];return _0x5ec6b4;};const _0x22216a=a940_0x5ec6;'use strict';const util=require(_0x22216a('0x10')),logger=require('../config/logger')(_0x22216a('0x11')),Sequence=function(){};Sequence[_0x22216a('0x4')][_0x22216a('0x6')]=function(_0x4d652a){const _0x6d1469=_0x22216a;this[_0x6d1469('0x17')]=this['tail']?this['tail'][_0x6d1469('0x13')](_0x4d652a):_0x4d652a();};const Migration=function(_0x421461){const _0x28d692=_0x22216a;this[_0x28d692('0xe')]=_0x421461,this[_0x28d692('0x15')]=new Sequence();};Migration[_0x22216a('0x4')]['changeColumn']=function(_0x474e92,_0x4fb00f,_0x16a0c8){const _0x5bc442=_0x22216a,_0x53f9d4=this;this[_0x5bc442('0x15')][_0x5bc442('0x6')](function(){const _0x3c50d9=_0x5bc442;return _0x53f9d4[_0x3c50d9('0xe')][_0x3c50d9('0x9')](_0x474e92,_0x4fb00f,_0x16a0c8)['then'](function(){const _0x2db59e=_0x3c50d9;logger[_0x2db59e('0xd')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x4fb00f,_0x474e92);})[_0x3c50d9('0x19')](function(_0x4d02b0){const _0x26b11d=_0x3c50d9;logger[_0x26b11d('0xd')](JSON['stringify'](_0x4d02b0));});});},Migration['prototype']['addColumn']=function(_0x17fd38,_0x469321,_0xc02c5){const _0x1da9c5=_0x22216a,_0x172563=this;this[_0x1da9c5('0x15')]['enqueue'](function(){const _0x825a3b=_0x1da9c5;return _0x172563['queryInterface'][_0x825a3b('0x16')](_0x17fd38,_0x469321,_0xc02c5)[_0x825a3b('0x3')](function(){const _0x7a76cf=_0x825a3b;logger[_0x7a76cf('0xd')](_0x7a76cf('0x7'),_0x469321,_0x17fd38);})['catch'](function(_0x272337){logger['info'](JSON['stringify'](_0x272337));});});},Migration[_0x22216a('0x4')]['dropTable']=function(_0xc64b88){const _0x6d00bd=_0x22216a,_0x27e2ca=this;this[_0x6d00bd('0x15')][_0x6d00bd('0x6')](function(){const _0x4cba49=_0x6d00bd;return _0x27e2ca[_0x4cba49('0xe')]['dropTable'](_0xc64b88,{'force':!![]})['then'](function(){const _0x36c624=_0x4cba49;logger[_0x36c624('0xd')](_0x36c624('0x14'),_0xc64b88);})[_0x4cba49('0x19')](function(_0x4345e5){const _0x1724ad=_0x4cba49;logger[_0x1724ad('0xd')](JSON[_0x1724ad('0x12')](_0x4345e5));});});},Migration[_0x22216a('0x4')][_0x22216a('0x8')]=function(_0x43cdd9,_0x581ec7,_0x43d78f){const _0xef9fc1=_0x22216a,_0x35c0b8=this;this[_0xef9fc1('0x15')][_0xef9fc1('0x6')](function(){const _0x286f0f=_0xef9fc1;return _0x35c0b8[_0x286f0f('0xe')][_0x286f0f('0x8')](_0x43cdd9,_0x581ec7,{'indexName':_0x43d78f})[_0x286f0f('0x3')](function(){const _0x1e0b53=_0x286f0f;logger[_0x1e0b53('0xd')]('addIndex\x20%s\x20%s\x20%s',_0x43cdd9,_0x581ec7['join'](','),_0x43d78f);})[_0x286f0f('0x19')](function(_0x5ad7ce){const _0x28f80a=_0x286f0f;logger[_0x28f80a('0xd')](JSON[_0x28f80a('0x12')](_0x5ad7ce));});});},Migration['prototype'][_0x22216a('0x0')]=function(_0x315dfd){const _0x538012=_0x22216a,_0x2b736=this;this['sequence'][_0x538012('0x6')](function(){const _0x55140a=_0x538012;return _0x2b736[_0x55140a('0xe')][_0x55140a('0x5')][_0x55140a('0x0')](_0x315dfd)['then'](function(){const _0x4c57e1=_0x55140a;logger['info'](_0x4c57e1('0xf'),_0x315dfd);})[_0x55140a('0x19')](function(_0x138ef3){const _0x9fb60b=_0x55140a;logger[_0x9fb60b('0xd')](JSON[_0x9fb60b('0x12')](_0x138ef3));});});},Migration[_0x22216a('0x4')]['removeColumn']=function(_0x36724f,_0x526901){const _0x2dcb78=_0x22216a,_0x3a2375=this;this[_0x2dcb78('0x15')][_0x2dcb78('0x6')](function(){const _0xc745ac=_0x2dcb78;return _0x3a2375[_0xc745ac('0xe')][_0xc745ac('0xc')](_0x36724f,_0x526901)['then'](function(){const _0x4e3eb2=_0xc745ac;logger[_0x4e3eb2('0xd')](_0x4e3eb2('0x2'),_0x526901,_0x36724f);})[_0xc745ac('0x19')](function(_0x1ab6b7){const _0x1749d9=_0xc745ac;logger[_0x1749d9('0xd')](util[_0x1749d9('0xb')](_0x1ab6b7,{'showHidden':![],'depth':null}));});});},Migration[_0x22216a('0x4')]['renameColumn']=function(_0x4802b9,_0xbc80a8,_0x1907e6){const _0x2a01cf=_0x22216a,_0x2f9e27=this;this[_0x2a01cf('0x15')][_0x2a01cf('0x6')](function(){const _0x74326c=_0x2a01cf;return _0x2f9e27[_0x74326c('0xe')][_0x74326c('0xa')](_0x4802b9,_0xbc80a8,_0x1907e6)['then'](function(){const _0x30d500=_0x74326c;logger[_0x30d500('0xd')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0xbc80a8,_0x1907e6,_0x4802b9);})['catch'](function(_0x104aa1){const _0x2b1174=_0x74326c;logger['info'](util[_0x2b1174('0xb')](_0x104aa1,{'showHidden':![],'depth':null}));});});},Migration[_0x22216a('0x4')][_0x22216a('0x18')]=function(_0x39c53f){const _0x116685=_0x22216a;this[_0x116685('0x15')][_0x116685('0x6')](function(){return _0x39c53f();});},module[_0x22216a('0x1')]={'up':function(_0x386855){return new Promise(function(_0x565f32){const _0x5e4fc3=a940_0x5ec6,_0x15d823=new Migration(_0x386855);_0x15d823[_0x5e4fc3('0x18')](_0x565f32);});},'down':function(){}}; \ No newline at end of file +const a940_0x4a2a=['join','inspect','../config/logger','info','then','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Removed\x20column\x20%s\x20from\x20%s','addIndex\x20%s\x20%s\x20%s','exports','sequelize','sequence','catch','changeColumn','stringify','tail','Added\x20column\x20%s\x20to\x20%s','addIndex','query\x20%s','query','prototype','enqueue','removeColumn','finally','final','migration','addColumn','queryInterface','dropTable'];(function(_0x295a98,_0x4a2aed){const _0x329195=function(_0x300b26){while(--_0x300b26){_0x295a98['push'](_0x295a98['shift']());}};_0x329195(++_0x4a2aed);}(a940_0x4a2a,0x178));const a940_0x3291=function(_0x295a98,_0x4a2aed){_0x295a98=_0x295a98-0x0;let _0x329195=a940_0x4a2a[_0x295a98];return _0x329195;};const _0x331c4a=a940_0x3291;'use strict';const util=require('util'),logger=require(_0x331c4a('0x12'))(_0x331c4a('0xc')),Sequence=function(){};Sequence[_0x331c4a('0x7')][_0x331c4a('0x8')]=function(_0x300b26){const _0x5b6cf3=_0x331c4a;this[_0x5b6cf3('0x2')]=this[_0x5b6cf3('0x2')]?this['tail'][_0x5b6cf3('0xa')](_0x300b26):_0x300b26();};const Migration=function(_0x112950){const _0x4bca47=_0x331c4a;this[_0x4bca47('0xe')]=_0x112950,this['sequence']=new Sequence();};Migration[_0x331c4a('0x7')]['changeColumn']=function(_0x55b175,_0x18a58c,_0x197b2b){const _0x2201fb=_0x331c4a,_0x1dcc15=this;this[_0x2201fb('0x1a')][_0x2201fb('0x8')](function(){const _0x6b74f0=_0x2201fb;return _0x1dcc15[_0x6b74f0('0xe')][_0x6b74f0('0x0')](_0x55b175,_0x18a58c,_0x197b2b)[_0x6b74f0('0x14')](function(){const _0x47cd4c=_0x6b74f0;logger[_0x47cd4c('0x13')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x18a58c,_0x55b175);})[_0x6b74f0('0x1b')](function(_0x4fe59a){const _0x4b445a=_0x6b74f0;logger['info'](JSON[_0x4b445a('0x1')](_0x4fe59a));});});},Migration['prototype'][_0x331c4a('0xd')]=function(_0x5f148d,_0x2a912b,_0x586592){const _0x1dafdd=_0x331c4a,_0x426e1d=this;this[_0x1dafdd('0x1a')]['enqueue'](function(){const _0x57a430=_0x1dafdd;return _0x426e1d[_0x57a430('0xe')][_0x57a430('0xd')](_0x5f148d,_0x2a912b,_0x586592)[_0x57a430('0x14')](function(){const _0x339495=_0x57a430;logger[_0x339495('0x13')](_0x339495('0x3'),_0x2a912b,_0x5f148d);})[_0x57a430('0x1b')](function(_0x23fc90){const _0x45e411=_0x57a430;logger[_0x45e411('0x13')](JSON[_0x45e411('0x1')](_0x23fc90));});});},Migration['prototype'][_0x331c4a('0xf')]=function(_0x504469){const _0x55596d=_0x331c4a,_0x73d608=this;this[_0x55596d('0x1a')][_0x55596d('0x8')](function(){const _0x566d55=_0x55596d;return _0x73d608['queryInterface'][_0x566d55('0xf')](_0x504469,{'force':!![]})['then'](function(){const _0x125653=_0x566d55;logger[_0x125653('0x13')]('table\x20dropped\x20%s',_0x504469);})['catch'](function(_0x22c394){const _0x5d0ff2=_0x566d55;logger[_0x5d0ff2('0x13')](JSON['stringify'](_0x22c394));});});},Migration['prototype'][_0x331c4a('0x4')]=function(_0x12e52b,_0x4b7a47,_0x52b614){const _0x51dc77=_0x331c4a,_0x308efc=this;this[_0x51dc77('0x1a')][_0x51dc77('0x8')](function(){const _0xfe5e07=_0x51dc77;return _0x308efc[_0xfe5e07('0xe')][_0xfe5e07('0x4')](_0x12e52b,_0x4b7a47,{'indexName':_0x52b614})['then'](function(){const _0x2a7b33=_0xfe5e07;logger[_0x2a7b33('0x13')](_0x2a7b33('0x17'),_0x12e52b,_0x4b7a47[_0x2a7b33('0x10')](','),_0x52b614);})[_0xfe5e07('0x1b')](function(_0x3bd080){const _0xd3f3b5=_0xfe5e07;logger[_0xd3f3b5('0x13')](JSON[_0xd3f3b5('0x1')](_0x3bd080));});});},Migration['prototype'][_0x331c4a('0x6')]=function(_0x2d1446){const _0x2407ef=_0x331c4a,_0x3b7478=this;this[_0x2407ef('0x1a')]['enqueue'](function(){const _0x8cca4=_0x2407ef;return _0x3b7478[_0x8cca4('0xe')][_0x8cca4('0x19')]['query'](_0x2d1446)[_0x8cca4('0x14')](function(){const _0x49f929=_0x8cca4;logger[_0x49f929('0x13')](_0x49f929('0x5'),_0x2d1446);})['catch'](function(_0x201f6a){const _0x2c44e4=_0x8cca4;logger['info'](JSON[_0x2c44e4('0x1')](_0x201f6a));});});},Migration['prototype'][_0x331c4a('0x9')]=function(_0x1cd75e,_0x5184ab){const _0x1de991=_0x331c4a,_0x16eff0=this;this[_0x1de991('0x1a')]['enqueue'](function(){const _0x4f856a=_0x1de991;return _0x16eff0['queryInterface'][_0x4f856a('0x9')](_0x1cd75e,_0x5184ab)[_0x4f856a('0x14')](function(){const _0x1c3f45=_0x4f856a;logger['info'](_0x1c3f45('0x16'),_0x5184ab,_0x1cd75e);})[_0x4f856a('0x1b')](function(_0x5a666b){const _0x2d3d9d=_0x4f856a;logger[_0x2d3d9d('0x13')](util[_0x2d3d9d('0x11')](_0x5a666b,{'showHidden':![],'depth':null}));});});},Migration['prototype']['renameColumn']=function(_0x57be3a,_0x2b1d16,_0x5488fc){const _0x2f3d6e=_0x331c4a,_0x3e0cc1=this;this[_0x2f3d6e('0x1a')]['enqueue'](function(){const _0xffc54b=_0x2f3d6e;return _0x3e0cc1[_0xffc54b('0xe')]['renameColumn'](_0x57be3a,_0x2b1d16,_0x5488fc)[_0xffc54b('0x14')](function(){const _0x4331ff=_0xffc54b;logger['info'](_0x4331ff('0x15'),_0x2b1d16,_0x5488fc,_0x57be3a);})['catch'](function(_0x1b2314){const _0x31a5ca=_0xffc54b;logger['info'](util[_0x31a5ca('0x11')](_0x1b2314,{'showHidden':![],'depth':null}));});});},Migration[_0x331c4a('0x7')]['final']=function(_0x3585ae){const _0x4f8216=_0x331c4a;this[_0x4f8216('0x1a')][_0x4f8216('0x8')](function(){return _0x3585ae();});},module[_0x331c4a('0x18')]={'up':function(_0xe15d35){return new Promise(function(_0xe47763){const _0x13fb25=a940_0x3291,_0x54582b=new Migration(_0xe15d35);_0x54582b[_0x13fb25('0xb')](_0xe47763);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.62.js b/server/migrations/2.0.62.js index 2b4783b..d9f0f89 100644 --- a/server/migrations/2.0.62.js +++ b/server/migrations/2.0.62.js @@ -1 +1 @@ -const a941_0x1091=['enqueue','util','cm_contacts','final','query\x20%s','Removed\x20column\x20%s\x20from\x20%s','addIndex','STRING','tail','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','bottom_right','query','inspect','table\x20dropped\x20%s','../config/logger','addColumn','tools_schedules','then','info','finally','catch','Changed\x20column\x20%s\x20in\x20table\x20%s','addIndex\x20%s\x20%s\x20%s','alignment','prototype','enableEmailPreview','stringify','renameColumn','exports','dropTable','removeColumn','settings','changeColumn','chat_websites','verticalAlignment','sequence','queryInterface','phone','sendIfEmpty','BOOLEAN'];(function(_0x3f968f,_0x109173){const _0x276d56=function(_0x58bd9b){while(--_0x58bd9b){_0x3f968f['push'](_0x3f968f['shift']());}};_0x276d56(++_0x109173);}(a941_0x1091,0xbf));const a941_0x276d=function(_0x3f968f,_0x109173){_0x3f968f=_0x3f968f-0x0;let _0x276d56=a941_0x1091[_0x3f968f];return _0x276d56;};const _0x4b14fb=a941_0x276d;'use strict';const util=require(_0x4b14fb('0xa')),logger=require(_0x4b14fb('0x17'))('migration'),Sequence=function(){};Sequence[_0x4b14fb('0x21')][_0x4b14fb('0x9')]=function(_0x58bd9b){const _0x5424bd=_0x4b14fb;this[_0x5424bd('0x11')]=this[_0x5424bd('0x11')]?this[_0x5424bd('0x11')][_0x5424bd('0x1c')](_0x58bd9b):_0x58bd9b();};const Migration=function(_0x280d81){const _0x588376=_0x4b14fb;this[_0x588376('0x5')]=_0x280d81,this[_0x588376('0x4')]=new Sequence();};Migration[_0x4b14fb('0x21')][_0x4b14fb('0x1')]=function(_0x5e0fa7,_0x5c786b,_0x33b04a){const _0x3d2098=_0x4b14fb,_0x424c4e=this;this[_0x3d2098('0x4')][_0x3d2098('0x9')](function(){const _0x3f6639=_0x3d2098;return _0x424c4e['queryInterface']['changeColumn'](_0x5e0fa7,_0x5c786b,_0x33b04a)[_0x3f6639('0x1a')](function(){const _0xf89b3d=_0x3f6639;logger[_0xf89b3d('0x1b')](_0xf89b3d('0x1e'),_0x5c786b,_0x5e0fa7);})[_0x3f6639('0x1d')](function(_0x6457c3){const _0x5641d7=_0x3f6639;logger[_0x5641d7('0x1b')](JSON[_0x5641d7('0x23')](_0x6457c3));});});},Migration[_0x4b14fb('0x21')][_0x4b14fb('0x18')]=function(_0x526cc1,_0x47d633,_0x1b0ecb){const _0x30dbf0=_0x4b14fb,_0x22fe94=this;this[_0x30dbf0('0x4')][_0x30dbf0('0x9')](function(){const _0x4a48bb=_0x30dbf0;return _0x22fe94[_0x4a48bb('0x5')][_0x4a48bb('0x18')](_0x526cc1,_0x47d633,_0x1b0ecb)[_0x4a48bb('0x1a')](function(){const _0xd09090=_0x4a48bb;logger[_0xd09090('0x1b')]('Added\x20column\x20%s\x20to\x20%s',_0x47d633,_0x526cc1);})[_0x4a48bb('0x1d')](function(_0x5e14f6){const _0x4e16db=_0x4a48bb;logger[_0x4e16db('0x1b')](JSON[_0x4e16db('0x23')](_0x5e14f6));});});},Migration['prototype'][_0x4b14fb('0x26')]=function(_0x1f8a58){const _0x391da2=_0x4b14fb,_0x115367=this;this['sequence'][_0x391da2('0x9')](function(){const _0x3b1356=_0x391da2;return _0x115367['queryInterface'][_0x3b1356('0x26')](_0x1f8a58,{'force':!![]})['then'](function(){const _0x49adf7=_0x3b1356;logger['info'](_0x49adf7('0x16'),_0x1f8a58);})[_0x3b1356('0x1d')](function(_0x4ee125){const _0x4bf2f4=_0x3b1356;logger[_0x4bf2f4('0x1b')](JSON['stringify'](_0x4ee125));});});},Migration[_0x4b14fb('0x21')][_0x4b14fb('0xf')]=function(_0x1c6923,_0x3a132f,_0x4dc935){const _0x29fb4a=_0x4b14fb,_0x4c7fe1=this;this[_0x29fb4a('0x4')][_0x29fb4a('0x9')](function(){const _0x139edd=_0x29fb4a;return _0x4c7fe1[_0x139edd('0x5')]['addIndex'](_0x1c6923,_0x3a132f,{'indexName':_0x4dc935})[_0x139edd('0x1a')](function(){const _0x463579=_0x139edd;logger['info'](_0x463579('0x1f'),_0x1c6923,_0x3a132f['join'](','),_0x4dc935);})[_0x139edd('0x1d')](function(_0x4f3b28){const _0x367051=_0x139edd;logger[_0x367051('0x1b')](JSON['stringify'](_0x4f3b28));});});},Migration['prototype'][_0x4b14fb('0x14')]=function(_0x5a6bdd){const _0x2c2b7f=_0x4b14fb,_0x538895=this;this['sequence'][_0x2c2b7f('0x9')](function(){const _0x3393b9=_0x2c2b7f;return _0x538895[_0x3393b9('0x5')]['sequelize']['query'](_0x5a6bdd)[_0x3393b9('0x1a')](function(){const _0x4c5332=_0x3393b9;logger['info'](_0x4c5332('0xd'),_0x5a6bdd);})[_0x3393b9('0x1d')](function(_0x49ed9c){const _0x5a9156=_0x3393b9;logger[_0x5a9156('0x1b')](JSON[_0x5a9156('0x23')](_0x49ed9c));});});},Migration[_0x4b14fb('0x21')]['removeColumn']=function(_0xa207c8,_0x71040){const _0x34aee3=_0x4b14fb,_0x327ba6=this;this[_0x34aee3('0x4')][_0x34aee3('0x9')](function(){const _0x3bcfc0=_0x34aee3;return _0x327ba6[_0x3bcfc0('0x5')][_0x3bcfc0('0x27')](_0xa207c8,_0x71040)[_0x3bcfc0('0x1a')](function(){const _0x2f295f=_0x3bcfc0;logger[_0x2f295f('0x1b')](_0x2f295f('0xe'),_0x71040,_0xa207c8);})[_0x3bcfc0('0x1d')](function(_0x9d1c87){const _0x3dd3f9=_0x3bcfc0;logger[_0x3dd3f9('0x1b')](util[_0x3dd3f9('0x15')](_0x9d1c87,{'showHidden':![],'depth':null}));});});},Migration[_0x4b14fb('0x21')][_0x4b14fb('0x24')]=function(_0x4455dd,_0x11c16c,_0x5a8654){const _0x31a65d=_0x4b14fb,_0xb91814=this;this['sequence'][_0x31a65d('0x9')](function(){const _0x485f78=_0x31a65d;return _0xb91814[_0x485f78('0x5')]['renameColumn'](_0x4455dd,_0x11c16c,_0x5a8654)[_0x485f78('0x1a')](function(){const _0x465f5b=_0x485f78;logger[_0x465f5b('0x1b')](_0x465f5b('0x12'),_0x11c16c,_0x5a8654,_0x4455dd);})[_0x485f78('0x1d')](function(_0xd41360){const _0x10800b=_0x485f78;logger[_0x10800b('0x1b')](util['inspect'](_0xd41360,{'showHidden':![],'depth':null}));});});},Migration[_0x4b14fb('0x21')][_0x4b14fb('0xc')]=function(_0x20d231){const _0xdb8090=_0x4b14fb;this[_0xdb8090('0x4')]['enqueue'](function(){return _0x20d231();});},module[_0x4b14fb('0x25')]={'up':function(_0x31394c,_0x187b97){return new Promise(function(_0xbef76d){const _0x4ad557=a941_0x276d,_0x41bf3b=new Migration(_0x31394c);_0x41bf3b['addColumn'](_0x4ad557('0x19'),_0x4ad557('0x7'),{'type':_0x187b97[_0x4ad557('0x8')],'defaultValue':!![]}),_0x41bf3b[_0x4ad557('0x1')](_0x4ad557('0xb'),_0x4ad557('0x6'),{'type':_0x187b97[_0x4ad557('0x10')],'allowNull':!![]}),_0x41bf3b['addColumn'](_0x4ad557('0x0'),_0x4ad557('0x22'),{'type':_0x187b97[_0x4ad557('0x8')],'defaultValue':![]}),_0x41bf3b['addColumn']('chat_websites',_0x4ad557('0x20'),{'type':_0x187b97[_0x4ad557('0x10')],'defaultValue':_0x4ad557('0x13')}),_0x41bf3b['addColumn'](_0x4ad557('0x2'),_0x4ad557('0x3'),{'type':_0x187b97['INTEGER'],'defaultValue':0x1e}),_0x41bf3b[_0x4ad557('0xc')](_0xbef76d);});},'down':function(){}}; \ No newline at end of file +const a941_0x3286=['sequelize','prototype','util','query','dropTable','tools_schedules','verticalAlignment','sequence','query\x20%s','settings','migration','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','INTEGER','info','phone','STRING','enqueue','addColumn','addIndex\x20%s\x20%s\x20%s','join','queryInterface','BOOLEAN','sendIfEmpty','catch','cm_contacts','then','table\x20dropped\x20%s','changeColumn','Added\x20column\x20%s\x20to\x20%s','stringify','removeColumn','final','enableEmailPreview','tail','bottom_right','finally','chat_websites','alignment','addIndex','Changed\x20column\x20%s\x20in\x20table\x20%s'];(function(_0x3e4537,_0x3286a9){const _0x51fd0c=function(_0x3d0972){while(--_0x3d0972){_0x3e4537['push'](_0x3e4537['shift']());}};_0x51fd0c(++_0x3286a9);}(a941_0x3286,0x19b));const a941_0x51fd=function(_0x3e4537,_0x3286a9){_0x3e4537=_0x3e4537-0x0;let _0x51fd0c=a941_0x3286[_0x3e4537];return _0x51fd0c;};const _0x584857=a941_0x51fd;'use strict';const util=require(_0x584857('0x1f')),logger=require('../config/logger')(_0x584857('0x27')),Sequence=function(){};Sequence[_0x584857('0x1e')]['enqueue']=function(_0x3d0972){const _0xd6bb3d=_0x584857;this[_0xd6bb3d('0x16')]=this[_0xd6bb3d('0x16')]?this[_0xd6bb3d('0x16')][_0xd6bb3d('0x18')](_0x3d0972):_0x3d0972();};const Migration=function(_0xe4172c){this['queryInterface']=_0xe4172c,this['sequence']=new Sequence();};Migration[_0x584857('0x1e')][_0x584857('0x10')]=function(_0x46918b,_0x305748,_0x33f713){const _0x341af3=_0x584857,_0x45d833=this;this[_0x341af3('0x24')][_0x341af3('0x5')](function(){const _0x37d1db=_0x341af3;return _0x45d833[_0x37d1db('0x9')][_0x37d1db('0x10')](_0x46918b,_0x305748,_0x33f713)['then'](function(){const _0x514749=_0x37d1db;logger[_0x514749('0x2')](_0x514749('0x1c'),_0x305748,_0x46918b);})[_0x37d1db('0xc')](function(_0x6646f9){const _0x267649=_0x37d1db;logger['info'](JSON[_0x267649('0x12')](_0x6646f9));});});},Migration[_0x584857('0x1e')][_0x584857('0x6')]=function(_0x4cf93e,_0x540260,_0x2f277c){const _0x542c8d=_0x584857,_0x124da8=this;this[_0x542c8d('0x24')][_0x542c8d('0x5')](function(){const _0x5e80d8=_0x542c8d;return _0x124da8[_0x5e80d8('0x9')]['addColumn'](_0x4cf93e,_0x540260,_0x2f277c)[_0x5e80d8('0xe')](function(){const _0x562a16=_0x5e80d8;logger['info'](_0x562a16('0x11'),_0x540260,_0x4cf93e);})[_0x5e80d8('0xc')](function(_0x86f661){const _0x21d519=_0x5e80d8;logger['info'](JSON[_0x21d519('0x12')](_0x86f661));});});},Migration['prototype'][_0x584857('0x21')]=function(_0x36017b){const _0x64cb55=_0x584857,_0xee86f5=this;this[_0x64cb55('0x24')][_0x64cb55('0x5')](function(){const _0x1265ed=_0x64cb55;return _0xee86f5[_0x1265ed('0x9')][_0x1265ed('0x21')](_0x36017b,{'force':!![]})[_0x1265ed('0xe')](function(){const _0x30fe81=_0x1265ed;logger[_0x30fe81('0x2')](_0x30fe81('0xf'),_0x36017b);})[_0x1265ed('0xc')](function(_0x21442e){const _0x112614=_0x1265ed;logger[_0x112614('0x2')](JSON[_0x112614('0x12')](_0x21442e));});});},Migration[_0x584857('0x1e')]['addIndex']=function(_0x3e58a8,_0x567eef,_0x55c2b2){const _0x2b9f54=_0x584857,_0x43c6ca=this;this[_0x2b9f54('0x24')]['enqueue'](function(){const _0x2635aa=_0x2b9f54;return _0x43c6ca[_0x2635aa('0x9')][_0x2635aa('0x1b')](_0x3e58a8,_0x567eef,{'indexName':_0x55c2b2})[_0x2635aa('0xe')](function(){const _0x2fd2c7=_0x2635aa;logger[_0x2fd2c7('0x2')](_0x2fd2c7('0x7'),_0x3e58a8,_0x567eef[_0x2fd2c7('0x8')](','),_0x55c2b2);})['catch'](function(_0x25ac79){const _0x4d4371=_0x2635aa;logger[_0x4d4371('0x2')](JSON[_0x4d4371('0x12')](_0x25ac79));});});},Migration[_0x584857('0x1e')][_0x584857('0x20')]=function(_0x543a0e){const _0x41be28=_0x584857,_0x17c3da=this;this[_0x41be28('0x24')][_0x41be28('0x5')](function(){const _0x5c49e9=_0x41be28;return _0x17c3da[_0x5c49e9('0x9')][_0x5c49e9('0x1d')][_0x5c49e9('0x20')](_0x543a0e)['then'](function(){const _0x51896e=_0x5c49e9;logger[_0x51896e('0x2')](_0x51896e('0x25'),_0x543a0e);})[_0x5c49e9('0xc')](function(_0x41856f){const _0x3d4226=_0x5c49e9;logger[_0x3d4226('0x2')](JSON[_0x3d4226('0x12')](_0x41856f));});});},Migration[_0x584857('0x1e')][_0x584857('0x13')]=function(_0x5f1ccc,_0x2ec0a4){const _0x1dba4b=_0x584857,_0xb655c=this;this[_0x1dba4b('0x24')]['enqueue'](function(){const _0x4cf93f=_0x1dba4b;return _0xb655c['queryInterface'][_0x4cf93f('0x13')](_0x5f1ccc,_0x2ec0a4)[_0x4cf93f('0xe')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x2ec0a4,_0x5f1ccc);})[_0x4cf93f('0xc')](function(_0x1c7fc4){const _0x4a3c87=_0x4cf93f;logger[_0x4a3c87('0x2')](util['inspect'](_0x1c7fc4,{'showHidden':![],'depth':null}));});});},Migration[_0x584857('0x1e')]['renameColumn']=function(_0xff1bc3,_0x16af27,_0x1abf9f){const _0x3a55ee=_0x584857,_0x37995f=this;this[_0x3a55ee('0x24')][_0x3a55ee('0x5')](function(){const _0x37f9ae=_0x3a55ee;return _0x37995f['queryInterface']['renameColumn'](_0xff1bc3,_0x16af27,_0x1abf9f)[_0x37f9ae('0xe')](function(){const _0x1f74bf=_0x37f9ae;logger[_0x1f74bf('0x2')](_0x1f74bf('0x0'),_0x16af27,_0x1abf9f,_0xff1bc3);})[_0x37f9ae('0xc')](function(_0x47f582){logger['info'](util['inspect'](_0x47f582,{'showHidden':![],'depth':null}));});});},Migration[_0x584857('0x1e')][_0x584857('0x14')]=function(_0x53e2ae){const _0x40ea68=_0x584857;this['sequence'][_0x40ea68('0x5')](function(){return _0x53e2ae();});},module['exports']={'up':function(_0x546859,_0x17d8c5){return new Promise(function(_0xdf6164){const _0x20c3a2=a941_0x51fd,_0x24c8bc=new Migration(_0x546859);_0x24c8bc['addColumn'](_0x20c3a2('0x22'),_0x20c3a2('0xb'),{'type':_0x17d8c5['BOOLEAN'],'defaultValue':!![]}),_0x24c8bc[_0x20c3a2('0x10')](_0x20c3a2('0xd'),_0x20c3a2('0x3'),{'type':_0x17d8c5[_0x20c3a2('0x4')],'allowNull':!![]}),_0x24c8bc['addColumn'](_0x20c3a2('0x26'),_0x20c3a2('0x15'),{'type':_0x17d8c5[_0x20c3a2('0xa')],'defaultValue':![]}),_0x24c8bc[_0x20c3a2('0x6')](_0x20c3a2('0x19'),_0x20c3a2('0x1a'),{'type':_0x17d8c5[_0x20c3a2('0x4')],'defaultValue':_0x20c3a2('0x17')}),_0x24c8bc[_0x20c3a2('0x6')]('chat_websites',_0x20c3a2('0x23'),{'type':_0x17d8c5[_0x20c3a2('0x1')],'defaultValue':0x1e}),_0x24c8bc[_0x20c3a2('0x14')](_0xdf6164);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.63.js b/server/migrations/2.0.63.js index 4d7dfb6..1671f20 100644 --- a/server/migrations/2.0.63.js +++ b/server/migrations/2.0.63.js @@ -1 +1 @@ -const a942_0x119b=['INTEGER','token','Changed\x20column\x20%s\x20in\x20table\x20%s','TagId','STRING','Removed\x20column\x20%s\x20from\x20%s','util','ALTER\x20TABLE\x20`sms_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`sms_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE','ALTER\x20TABLE\x20`mail_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE','query','sequence','sequelize','migration','catch','Added\x20column\x20%s\x20to\x20%s','TEXT','chat_applications','dropTable','addIndex','info','addColumn','enqueue','chat_websites','join','messagesAlignment','defaultTitle','query\x20%s','ALTER\x20TABLE\x20`openchannel_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`openchannel_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE','changeColumn','openchannel_applications','prototype','ALTER\x20TABLE\x20`fax_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`fax_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE','renameColumn','then','title','queryInterface','table\x20dropped\x20%s','data','showCustomerAvatar','tail','ALTER\x20TABLE\x20`chat_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`chat_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE','stringify','removeColumn','../config/logger','customerAvatar','final','addIndex\x20%s\x20%s\x20%s','inspect'];(function(_0x303103,_0x119b31){const _0x3bf51e=function(_0x32f951){while(--_0x32f951){_0x303103['push'](_0x303103['shift']());}};_0x3bf51e(++_0x119b31);}(a942_0x119b,0x138));const a942_0x3bf5=function(_0x303103,_0x119b31){_0x303103=_0x303103-0x0;let _0x3bf51e=a942_0x119b[_0x303103];return _0x3bf51e;};const _0x2dfd95=a942_0x3bf5;'use strict';const util=require(_0x2dfd95('0x1e')),logger=require(_0x2dfd95('0x13'))(_0x2dfd95('0x24')),Sequence=function(){};Sequence[_0x2dfd95('0x6')]['enqueue']=function(_0x32f951){const _0x624f67=_0x2dfd95;this['tail']=this[_0x624f67('0xf')]?this[_0x624f67('0xf')]['finally'](_0x32f951):_0x32f951();};const Migration=function(_0x116af4){const _0x2d31d0=_0x2dfd95;this[_0x2d31d0('0xb')]=_0x116af4,this['sequence']=new Sequence();};Migration[_0x2dfd95('0x6')][_0x2dfd95('0x4')]=function(_0x38c7db,_0x29d3d8,_0x20fcd3){const _0x597c2b=_0x2dfd95,_0x4905fe=this;this['sequence'][_0x597c2b('0x2d')](function(){const _0x2e8af6=_0x597c2b;return _0x4905fe['queryInterface']['changeColumn'](_0x38c7db,_0x29d3d8,_0x20fcd3)[_0x2e8af6('0x9')](function(){const _0x2ff707=_0x2e8af6;logger['info'](_0x2ff707('0x1a'),_0x29d3d8,_0x38c7db);})[_0x2e8af6('0x25')](function(_0x51053e){const _0x2ffcde=_0x2e8af6;logger[_0x2ffcde('0x2b')](JSON[_0x2ffcde('0x11')](_0x51053e));});});},Migration[_0x2dfd95('0x6')][_0x2dfd95('0x2c')]=function(_0x2a7b25,_0x168641,_0x144cc6){const _0x30f6f9=_0x2dfd95,_0x3551e7=this;this[_0x30f6f9('0x22')][_0x30f6f9('0x2d')](function(){const _0x19651c=_0x30f6f9;return _0x3551e7[_0x19651c('0xb')][_0x19651c('0x2c')](_0x2a7b25,_0x168641,_0x144cc6)[_0x19651c('0x9')](function(){const _0x2079cf=_0x19651c;logger[_0x2079cf('0x2b')](_0x2079cf('0x26'),_0x168641,_0x2a7b25);})[_0x19651c('0x25')](function(_0x92f359){const _0x209d7b=_0x19651c;logger[_0x209d7b('0x2b')](JSON[_0x209d7b('0x11')](_0x92f359));});});},Migration[_0x2dfd95('0x6')]['dropTable']=function(_0x40e67f){const _0x1c896b=_0x2dfd95,_0x169d87=this;this[_0x1c896b('0x22')][_0x1c896b('0x2d')](function(){const _0x3b5def=_0x1c896b;return _0x169d87['queryInterface'][_0x3b5def('0x29')](_0x40e67f,{'force':!![]})['then'](function(){const _0xc2f5fc=_0x3b5def;logger['info'](_0xc2f5fc('0xc'),_0x40e67f);})[_0x3b5def('0x25')](function(_0x2125a5){const _0x57cc9e=_0x3b5def;logger[_0x57cc9e('0x2b')](JSON[_0x57cc9e('0x11')](_0x2125a5));});});},Migration['prototype'][_0x2dfd95('0x2a')]=function(_0x59c8e7,_0x533a11,_0xde1812){const _0x3cf456=_0x2dfd95,_0x56c1f4=this;this[_0x3cf456('0x22')][_0x3cf456('0x2d')](function(){const _0x511a05=_0x3cf456;return _0x56c1f4[_0x511a05('0xb')]['addIndex'](_0x59c8e7,_0x533a11,{'indexName':_0xde1812})[_0x511a05('0x9')](function(){const _0x2760a1=_0x511a05;logger[_0x2760a1('0x2b')](_0x2760a1('0x16'),_0x59c8e7,_0x533a11[_0x2760a1('0x2f')](','),_0xde1812);})[_0x511a05('0x25')](function(_0x11b7d4){const _0x124e7c=_0x511a05;logger[_0x124e7c('0x2b')](JSON[_0x124e7c('0x11')](_0x11b7d4));});});},Migration[_0x2dfd95('0x6')]['query']=function(_0x501a05){const _0x4f783a=_0x2dfd95,_0x374c6a=this;this[_0x4f783a('0x22')]['enqueue'](function(){const _0x5613f4=_0x4f783a;return _0x374c6a[_0x5613f4('0xb')][_0x5613f4('0x23')][_0x5613f4('0x21')](_0x501a05)[_0x5613f4('0x9')](function(){const _0x469de4=_0x5613f4;logger['info'](_0x469de4('0x2'),_0x501a05);})[_0x5613f4('0x25')](function(_0xa84f9){const _0x431fd2=_0x5613f4;logger[_0x431fd2('0x2b')](JSON[_0x431fd2('0x11')](_0xa84f9));});});},Migration['prototype'][_0x2dfd95('0x12')]=function(_0x5cb968,_0x259944){const _0x31b966=_0x2dfd95,_0x100346=this;this['sequence'][_0x31b966('0x2d')](function(){const _0x4b8a22=_0x31b966;return _0x100346['queryInterface'][_0x4b8a22('0x12')](_0x5cb968,_0x259944)[_0x4b8a22('0x9')](function(){const _0x30f153=_0x4b8a22;logger[_0x30f153('0x2b')](_0x30f153('0x1d'),_0x259944,_0x5cb968);})[_0x4b8a22('0x25')](function(_0x7e4554){const _0x371516=_0x4b8a22;logger[_0x371516('0x2b')](util[_0x371516('0x17')](_0x7e4554,{'showHidden':![],'depth':null}));});});},Migration[_0x2dfd95('0x6')][_0x2dfd95('0x8')]=function(_0x2d37b2,_0x50630e,_0x20b8c1){const _0x4f11f2=_0x2dfd95,_0x3b1fc3=this;this['sequence'][_0x4f11f2('0x2d')](function(){const _0x41eea2=_0x4f11f2;return _0x3b1fc3['queryInterface']['renameColumn'](_0x2d37b2,_0x50630e,_0x20b8c1)[_0x41eea2('0x9')](function(){const _0x15ccbe=_0x41eea2;logger[_0x15ccbe('0x2b')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x50630e,_0x20b8c1,_0x2d37b2);})[_0x41eea2('0x25')](function(_0x1a6706){const _0x726f5d=_0x41eea2;logger[_0x726f5d('0x2b')](util['inspect'](_0x1a6706,{'showHidden':![],'depth':null}));});});},Migration[_0x2dfd95('0x6')]['final']=function(_0x192ddd){const _0x27addc=_0x2dfd95;this[_0x27addc('0x22')][_0x27addc('0x2d')](function(){return _0x192ddd();});},module['exports']={'up':function(_0x598d38,_0x3495fb){return new Promise(function(_0x211864){const _0x2f58b7=a942_0x3bf5,_0x103a7d=new Migration(_0x598d38);_0x103a7d['addColumn']('chat_websites',_0x2f58b7('0x0'),{'type':_0x3495fb[_0x2f58b7('0x1c')],'defaultValue':'alternate'}),_0x103a7d[_0x2f58b7('0x2c')](_0x2f58b7('0x2e'),_0x2f58b7('0x1'),{'type':_0x3495fb[_0x2f58b7('0x1c')]}),_0x103a7d[_0x2f58b7('0x2c')](_0x2f58b7('0x2e'),_0x2f58b7('0x14'),{'type':_0x3495fb[_0x2f58b7('0x27')]}),_0x103a7d['addColumn'](_0x2f58b7('0x2e'),_0x2f58b7('0xe'),{'type':_0x3495fb['BOOLEAN'],'defaultValue':![]}),_0x103a7d['addColumn'](_0x2f58b7('0x28'),_0x2f58b7('0x1b'),{'type':_0x3495fb[_0x2f58b7('0x18')]}),_0x103a7d['query'](_0x2f58b7('0x10')),_0x103a7d[_0x2f58b7('0x2c')]('fax_applications','TagId',{'type':_0x3495fb['INTEGER']}),_0x103a7d[_0x2f58b7('0x21')](_0x2f58b7('0x7')),_0x103a7d[_0x2f58b7('0x2c')]('mail_applications','TagId',{'type':_0x3495fb['INTEGER']}),_0x103a7d[_0x2f58b7('0x21')](_0x2f58b7('0x20')),_0x103a7d[_0x2f58b7('0x2c')](_0x2f58b7('0x5'),_0x2f58b7('0x1b'),{'type':_0x3495fb[_0x2f58b7('0x18')]}),_0x103a7d[_0x2f58b7('0x21')](_0x2f58b7('0x3')),_0x103a7d[_0x2f58b7('0x2c')]('sms_applications',_0x2f58b7('0x1b'),{'type':_0x3495fb['INTEGER']}),_0x103a7d[_0x2f58b7('0x21')](_0x2f58b7('0x1f')),_0x103a7d[_0x2f58b7('0x21')]('ALTER\x20TABLE\x20report_dial\x20CHANGE\x20`hodltime`\x20`holdtime`\x20INT(11)\x20DEFAULT\x20NULL'),_0x103a7d[_0x2f58b7('0x2c')]('openchannel_accounts',_0x2f58b7('0x19'),{'type':_0x3495fb[_0x2f58b7('0x1c')]}),_0x103a7d[_0x2f58b7('0x2c')]('voice_queues_log',_0x2f58b7('0xd'),{'type':_0x3495fb[_0x2f58b7('0x1c')],'allowNull':![],'defaultValue':''}),_0x103a7d['changeColumn']('dashboard_items',_0x2f58b7('0xa'),{'type':_0x3495fb['STRING'],'allowNull':![]}),_0x103a7d[_0x2f58b7('0x15')](_0x211864);});},'down':function(){}}; \ No newline at end of file +const a942_0xf5e4=['sequence','removeColumn','renameColumn','addColumn','ALTER\x20TABLE\x20`sms_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`sms_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE','ALTER\x20TABLE\x20`mail_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`mail_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE','TagId','changeColumn','BOOLEAN','ALTER\x20TABLE\x20report_dial\x20CHANGE\x20`hodltime`\x20`holdtime`\x20INT(11)\x20DEFAULT\x20NULL','Removed\x20column\x20%s\x20from\x20%s','chat_websites','chat_applications','tail','mail_applications','addIndex','defaultTitle','table\x20dropped\x20%s','then','dropTable','join','enqueue','TEXT','query\x20%s','inspect','customerAvatar','catch','Changed\x20column\x20%s\x20in\x20table\x20%s','finally','token','sms_applications','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','alternate','INTEGER','Added\x20column\x20%s\x20to\x20%s','query','../config/logger','showCustomerAvatar','title','prototype','addIndex\x20%s\x20%s\x20%s','STRING','queryInterface','openchannel_accounts','info','final','stringify','migration'];(function(_0x334f01,_0xf5e4f1){const _0x4346c3=function(_0x417051){while(--_0x417051){_0x334f01['push'](_0x334f01['shift']());}};_0x4346c3(++_0xf5e4f1);}(a942_0xf5e4,0x105));const a942_0x4346=function(_0x334f01,_0xf5e4f1){_0x334f01=_0x334f01-0x0;let _0x4346c3=a942_0xf5e4[_0x334f01];return _0x4346c3;};const _0x71f8a3=a942_0x4346;'use strict';const util=require('util'),logger=require(_0x71f8a3('0xf'))(_0x71f8a3('0x1a')),Sequence=function(){};Sequence[_0x71f8a3('0x12')][_0x71f8a3('0x0')]=function(_0x417051){const _0x585c6f=_0x71f8a3;this[_0x585c6f('0x28')]=this[_0x585c6f('0x28')]?this['tail'][_0x585c6f('0x7')](_0x417051):_0x417051();};const Migration=function(_0x53a909){const _0x2fd3ce=_0x71f8a3;this[_0x2fd3ce('0x15')]=_0x53a909,this[_0x2fd3ce('0x1b')]=new Sequence();};Migration[_0x71f8a3('0x12')]['changeColumn']=function(_0x315d8e,_0x547ae4,_0x557395){const _0x458d17=_0x71f8a3,_0x3f95f0=this;this[_0x458d17('0x1b')]['enqueue'](function(){const _0x5a3f4b=_0x458d17;return _0x3f95f0[_0x5a3f4b('0x15')][_0x5a3f4b('0x22')](_0x315d8e,_0x547ae4,_0x557395)[_0x5a3f4b('0x2d')](function(){const _0x1ad563=_0x5a3f4b;logger[_0x1ad563('0x17')](_0x1ad563('0x6'),_0x547ae4,_0x315d8e);})[_0x5a3f4b('0x5')](function(_0x280253){const _0x56454e=_0x5a3f4b;logger[_0x56454e('0x17')](JSON[_0x56454e('0x19')](_0x280253));});});},Migration[_0x71f8a3('0x12')][_0x71f8a3('0x1e')]=function(_0x4b7f9e,_0x1dfb81,_0x252836){const _0x155c52=_0x71f8a3,_0x385965=this;this[_0x155c52('0x1b')][_0x155c52('0x0')](function(){const _0x1775a2=_0x155c52;return _0x385965['queryInterface'][_0x1775a2('0x1e')](_0x4b7f9e,_0x1dfb81,_0x252836)[_0x1775a2('0x2d')](function(){const _0x4fde28=_0x1775a2;logger[_0x4fde28('0x17')](_0x4fde28('0xd'),_0x1dfb81,_0x4b7f9e);})[_0x1775a2('0x5')](function(_0x2f3e56){const _0x38b25d=_0x1775a2;logger['info'](JSON[_0x38b25d('0x19')](_0x2f3e56));});});},Migration[_0x71f8a3('0x12')][_0x71f8a3('0x2e')]=function(_0x27e9bf){const _0x3b9e7d=_0x71f8a3,_0x30c177=this;this[_0x3b9e7d('0x1b')][_0x3b9e7d('0x0')](function(){const _0x1ed2de=_0x3b9e7d;return _0x30c177[_0x1ed2de('0x15')][_0x1ed2de('0x2e')](_0x27e9bf,{'force':!![]})[_0x1ed2de('0x2d')](function(){const _0x5cefed=_0x1ed2de;logger[_0x5cefed('0x17')](_0x5cefed('0x2c'),_0x27e9bf);})[_0x1ed2de('0x5')](function(_0x7a2046){logger['info'](JSON['stringify'](_0x7a2046));});});},Migration['prototype'][_0x71f8a3('0x2a')]=function(_0x532bea,_0x54561d,_0x5cab17){const _0xf34ab1=_0x71f8a3,_0x4515b9=this;this[_0xf34ab1('0x1b')][_0xf34ab1('0x0')](function(){const _0x10b6b8=_0xf34ab1;return _0x4515b9[_0x10b6b8('0x15')][_0x10b6b8('0x2a')](_0x532bea,_0x54561d,{'indexName':_0x5cab17})[_0x10b6b8('0x2d')](function(){const _0x5ec774=_0x10b6b8;logger[_0x5ec774('0x17')](_0x5ec774('0x13'),_0x532bea,_0x54561d[_0x5ec774('0x2f')](','),_0x5cab17);})[_0x10b6b8('0x5')](function(_0x28cbe4){logger['info'](JSON['stringify'](_0x28cbe4));});});},Migration[_0x71f8a3('0x12')][_0x71f8a3('0xe')]=function(_0x499d97){const _0x3a1335=_0x71f8a3,_0x7531d=this;this[_0x3a1335('0x1b')]['enqueue'](function(){const _0x185c58=_0x3a1335;return _0x7531d[_0x185c58('0x15')]['sequelize'][_0x185c58('0xe')](_0x499d97)[_0x185c58('0x2d')](function(){const _0x27c1e1=_0x185c58;logger[_0x27c1e1('0x17')](_0x27c1e1('0x2'),_0x499d97);})[_0x185c58('0x5')](function(_0x1f9056){const _0x23c9fc=_0x185c58;logger[_0x23c9fc('0x17')](JSON[_0x23c9fc('0x19')](_0x1f9056));});});},Migration[_0x71f8a3('0x12')][_0x71f8a3('0x1c')]=function(_0x4e1ce0,_0x32245d){const _0x1ec45c=_0x71f8a3,_0xc685=this;this[_0x1ec45c('0x1b')][_0x1ec45c('0x0')](function(){const _0x5b3127=_0x1ec45c;return _0xc685[_0x5b3127('0x15')][_0x5b3127('0x1c')](_0x4e1ce0,_0x32245d)[_0x5b3127('0x2d')](function(){const _0x13cdd9=_0x5b3127;logger['info'](_0x13cdd9('0x25'),_0x32245d,_0x4e1ce0);})['catch'](function(_0x3c6d7a){const _0x4ad3fb=_0x5b3127;logger[_0x4ad3fb('0x17')](util[_0x4ad3fb('0x3')](_0x3c6d7a,{'showHidden':![],'depth':null}));});});},Migration[_0x71f8a3('0x12')]['renameColumn']=function(_0x240238,_0x5191d6,_0x2c310b){const _0x5515ea=_0x71f8a3,_0x3f0d31=this;this[_0x5515ea('0x1b')]['enqueue'](function(){const _0xc4abc0=_0x5515ea;return _0x3f0d31[_0xc4abc0('0x15')][_0xc4abc0('0x1d')](_0x240238,_0x5191d6,_0x2c310b)[_0xc4abc0('0x2d')](function(){const _0x48ce19=_0xc4abc0;logger[_0x48ce19('0x17')](_0x48ce19('0xa'),_0x5191d6,_0x2c310b,_0x240238);})[_0xc4abc0('0x5')](function(_0x2b56f6){const _0x165e02=_0xc4abc0;logger[_0x165e02('0x17')](util[_0x165e02('0x3')](_0x2b56f6,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x71f8a3('0x18')]=function(_0x2af95f){const _0x1770b2=_0x71f8a3;this[_0x1770b2('0x1b')][_0x1770b2('0x0')](function(){return _0x2af95f();});},module['exports']={'up':function(_0x48d8b8,_0x410abf){return new Promise(function(_0x5cade2){const _0x38001f=a942_0x4346,_0x1ef2f5=new Migration(_0x48d8b8);_0x1ef2f5[_0x38001f('0x1e')](_0x38001f('0x26'),'messagesAlignment',{'type':_0x410abf[_0x38001f('0x14')],'defaultValue':_0x38001f('0xb')}),_0x1ef2f5[_0x38001f('0x1e')](_0x38001f('0x26'),_0x38001f('0x2b'),{'type':_0x410abf['STRING']}),_0x1ef2f5['addColumn']('chat_websites',_0x38001f('0x4'),{'type':_0x410abf[_0x38001f('0x1')]}),_0x1ef2f5[_0x38001f('0x1e')](_0x38001f('0x26'),_0x38001f('0x10'),{'type':_0x410abf[_0x38001f('0x23')],'defaultValue':![]}),_0x1ef2f5[_0x38001f('0x1e')](_0x38001f('0x27'),'TagId',{'type':_0x410abf['INTEGER']}),_0x1ef2f5[_0x38001f('0xe')]('ALTER\x20TABLE\x20`chat_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`chat_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE'),_0x1ef2f5[_0x38001f('0x1e')]('fax_applications',_0x38001f('0x21'),{'type':_0x410abf[_0x38001f('0xc')]}),_0x1ef2f5[_0x38001f('0xe')]('ALTER\x20TABLE\x20`fax_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`fax_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE'),_0x1ef2f5[_0x38001f('0x1e')](_0x38001f('0x29'),'TagId',{'type':_0x410abf[_0x38001f('0xc')]}),_0x1ef2f5[_0x38001f('0xe')](_0x38001f('0x20')),_0x1ef2f5[_0x38001f('0x1e')]('openchannel_applications',_0x38001f('0x21'),{'type':_0x410abf['INTEGER']}),_0x1ef2f5[_0x38001f('0xe')]('ALTER\x20TABLE\x20`openchannel_applications`\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`openchannel_applications_ibfk_5`\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20tools_tags(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE'),_0x1ef2f5[_0x38001f('0x1e')](_0x38001f('0x9'),_0x38001f('0x21'),{'type':_0x410abf['INTEGER']}),_0x1ef2f5['query'](_0x38001f('0x1f')),_0x1ef2f5[_0x38001f('0xe')](_0x38001f('0x24')),_0x1ef2f5[_0x38001f('0x1e')](_0x38001f('0x16'),_0x38001f('0x8'),{'type':_0x410abf[_0x38001f('0x14')]}),_0x1ef2f5[_0x38001f('0x1e')]('voice_queues_log','data',{'type':_0x410abf[_0x38001f('0x14')],'allowNull':![],'defaultValue':''}),_0x1ef2f5[_0x38001f('0x22')]('dashboard_items',_0x38001f('0x11'),{'type':_0x410abf[_0x38001f('0x14')],'allowNull':![]}),_0x1ef2f5[_0x38001f('0x18')](_0x5cade2);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.64.js b/server/migrations/2.0.64.js index abd43fb..e80df86 100644 --- a/server/migrations/2.0.64.js +++ b/server/migrations/2.0.64.js @@ -1 +1 @@ -const a943_0x2c43=['customerAlias','tail','changeColumn','addColumn','chat_websites','sequence','renameColumn','Added\x20column\x20%s\x20to\x20%s','Removed\x20column\x20%s\x20from\x20%s','addIndex','join','dropTable','finally','removeIndex\x20%s\x20%s','removeColumn','prototype','BOOLEAN','catch','query','report_call','STRING','stringify','then','field','phoneBarEnableVideoRecording','migration','addIndex\x20%s\x20%s\x20%s','removeIndex','sequelize','TEXT','info','lastdata','final','queryInterface','enqueue','exports','inspect'];(function(_0xdaf07c,_0x2c43b1){const _0x5517e4=function(_0x3136ea){while(--_0x3136ea){_0xdaf07c['push'](_0xdaf07c['shift']());}};_0x5517e4(++_0x2c43b1);}(a943_0x2c43,0x1b6));const a943_0x5517=function(_0xdaf07c,_0x2c43b1){_0xdaf07c=_0xdaf07c-0x0;let _0x5517e4=a943_0x2c43[_0xdaf07c];return _0x5517e4;};const _0x4cc10e=a943_0x5517;'use strict';const util=require('util'),logger=require('../config/logger')(_0x4cc10e('0x1f')),Sequence=function(){};Sequence[_0x4cc10e('0x15')]['enqueue']=function(_0x3136ea){const _0x41aaa9=_0x4cc10e;this[_0x41aaa9('0x7')]=this['tail']?this[_0x41aaa9('0x7')][_0x41aaa9('0x12')](_0x3136ea):_0x3136ea();};const Migration=function(_0x47ed04){const _0x57f6fe=_0x4cc10e;this[_0x57f6fe('0x2')]=_0x47ed04,this[_0x57f6fe('0xb')]=new Sequence();};Migration[_0x4cc10e('0x15')][_0x4cc10e('0x8')]=function(_0x4fa77,_0x31aad3,_0x1607ea){const _0x4bd945=_0x4cc10e,_0x3d1581=this;this[_0x4bd945('0xb')]['enqueue'](function(){const _0x569e37=_0x4bd945;return _0x3d1581[_0x569e37('0x2')][_0x569e37('0x8')](_0x4fa77,_0x31aad3,_0x1607ea)[_0x569e37('0x1c')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x31aad3,_0x4fa77);})[_0x569e37('0x17')](function(_0x357441){logger['info'](JSON['stringify'](_0x357441));});});},Migration[_0x4cc10e('0x15')][_0x4cc10e('0x9')]=function(_0x541bd4,_0x1cc1d6,_0x51c6de){const _0x26225a=_0x4cc10e,_0x5a6ca5=this;this[_0x26225a('0xb')][_0x26225a('0x3')](function(){const _0x1775f8=_0x26225a;return _0x5a6ca5['queryInterface']['addColumn'](_0x541bd4,_0x1cc1d6,_0x51c6de)[_0x1775f8('0x1c')](function(){const _0x321b41=_0x1775f8;logger[_0x321b41('0x24')](_0x321b41('0xd'),_0x1cc1d6,_0x541bd4);})[_0x1775f8('0x17')](function(_0x50048f){const _0x11fd98=_0x1775f8;logger[_0x11fd98('0x24')](JSON[_0x11fd98('0x1b')](_0x50048f));});});},Migration[_0x4cc10e('0x15')]['dropTable']=function(_0x41be8f){const _0x36b903=this;this['sequence']['enqueue'](function(){const _0x24c3a5=a943_0x5517;return _0x36b903[_0x24c3a5('0x2')][_0x24c3a5('0x11')](_0x41be8f,{'force':!![]})[_0x24c3a5('0x1c')](function(){logger['info']('table\x20dropped\x20%s',_0x41be8f);})[_0x24c3a5('0x17')](function(_0x5620ee){const _0x16d9ab=_0x24c3a5;logger[_0x16d9ab('0x24')](JSON[_0x16d9ab('0x1b')](_0x5620ee));});});},Migration[_0x4cc10e('0x15')][_0x4cc10e('0xf')]=function(_0x302afe,_0x28100c,_0x1e2b74){const _0x284e1e=_0x4cc10e,_0x3c5b4c=this;this[_0x284e1e('0xb')][_0x284e1e('0x3')](function(){const _0x5e487c=_0x284e1e;return _0x3c5b4c[_0x5e487c('0x2')][_0x5e487c('0xf')](_0x302afe,_0x28100c,{'indexName':_0x1e2b74})[_0x5e487c('0x1c')](function(){const _0xf9c0f=_0x5e487c;logger[_0xf9c0f('0x24')](_0xf9c0f('0x20'),_0x302afe,_0x28100c[_0xf9c0f('0x10')](','),_0x1e2b74);})[_0x5e487c('0x17')](function(_0x428422){const _0xa53a3d=_0x5e487c;logger[_0xa53a3d('0x24')](JSON['stringify'](_0x428422));});});},Migration[_0x4cc10e('0x15')][_0x4cc10e('0x21')]=function(_0x544c40,_0x468a9d){const _0x2cee1e=_0x4cc10e,_0x560462=this;this[_0x2cee1e('0xb')][_0x2cee1e('0x3')](function(){const _0x54fad8=_0x2cee1e;return _0x560462[_0x54fad8('0x2')][_0x54fad8('0x21')](_0x544c40,_0x468a9d)[_0x54fad8('0x1c')](function(){const _0x20a079=_0x54fad8;logger[_0x20a079('0x24')](_0x20a079('0x13'),_0x544c40,_0x468a9d);})[_0x54fad8('0x17')](function(_0x34efbf){const _0x25944c=_0x54fad8;logger[_0x25944c('0x24')](JSON['stringify'](_0x34efbf));});});},Migration[_0x4cc10e('0x15')][_0x4cc10e('0x18')]=function(_0x38bb5a){const _0x501c4e=this;this['sequence']['enqueue'](function(){const _0x2a69cb=a943_0x5517;return _0x501c4e[_0x2a69cb('0x2')][_0x2a69cb('0x22')][_0x2a69cb('0x18')](_0x38bb5a)[_0x2a69cb('0x1c')](function(){const _0x551fc5=_0x2a69cb;logger[_0x551fc5('0x24')]('query\x20%s',_0x38bb5a);})[_0x2a69cb('0x17')](function(_0x50541e){const _0x345037=_0x2a69cb;logger['info'](JSON[_0x345037('0x1b')](_0x50541e));});});},Migration[_0x4cc10e('0x15')][_0x4cc10e('0x14')]=function(_0x115ffc,_0x42b074){const _0xb5c6cc=_0x4cc10e,_0x101aef=this;this[_0xb5c6cc('0xb')]['enqueue'](function(){const _0x27bb8b=_0xb5c6cc;return _0x101aef['queryInterface'][_0x27bb8b('0x14')](_0x115ffc,_0x42b074)['then'](function(){const _0x530477=_0x27bb8b;logger[_0x530477('0x24')](_0x530477('0xe'),_0x42b074,_0x115ffc);})[_0x27bb8b('0x17')](function(_0x515d8c){const _0x17662f=_0x27bb8b;logger[_0x17662f('0x24')](util[_0x17662f('0x5')](_0x515d8c,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x4cc10e('0xc')]=function(_0xad81a8,_0x59e1cc,_0x383f93){const _0x2d338e=_0x4cc10e,_0x3e2133=this;this['sequence'][_0x2d338e('0x3')](function(){const _0x583401=_0x2d338e;return _0x3e2133['queryInterface']['renameColumn'](_0xad81a8,_0x59e1cc,_0x383f93)['then'](function(){const _0x131274=a943_0x5517;logger[_0x131274('0x24')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x59e1cc,_0x383f93,_0xad81a8);})[_0x583401('0x17')](function(_0x303da1){const _0xd7b7c1=_0x583401;logger[_0xd7b7c1('0x24')](util[_0xd7b7c1('0x5')](_0x303da1,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x4cc10e('0x1')]=function(_0x2de9f2){const _0x54853b=_0x4cc10e;this[_0x54853b('0xb')]['enqueue'](function(){return _0x2de9f2();});},module[_0x4cc10e('0x4')]={'up':function(_0x56e3e3,_0x32f4c2){return new Promise(function(_0x1f82e3){const _0x1928dc=a943_0x5517,_0x2240e0=new Migration(_0x56e3e3);_0x2240e0[_0x1928dc('0x9')]('users',_0x1928dc('0x1e'),{'type':_0x32f4c2[_0x1928dc('0x16')],'defaultValue':![]}),_0x2240e0['changeColumn'](_0x1928dc('0x19'),_0x1928dc('0x0'),{'type':_0x32f4c2[_0x1928dc('0x23')]}),_0x2240e0[_0x1928dc('0x9')](_0x1928dc('0xa'),_0x1928dc('0x6'),{'type':_0x32f4c2[_0x1928dc('0x1a')],'defaultValue':'Me'}),_0x2240e0[_0x1928dc('0x8')]('analytics_report_fields',_0x1928dc('0x1d'),{'type':_0x32f4c2[_0x1928dc('0x23')],'allowNull':![]}),_0x2240e0[_0x1928dc('0x21')](_0x1928dc('0x19'),'uniqueid'),_0x2240e0['final'](_0x1f82e3);});},'down':function(){}}; \ No newline at end of file +const a943_0x2d64=['report_call','catch','Removed\x20column\x20%s\x20from\x20%s','finally','sequelize','uniqueid','renameColumn','field','changeColumn','dropTable','tail','BOOLEAN','inspect','query\x20%s','lastdata','table\x20dropped\x20%s','prototype','../config/logger','removeIndex','info','exports','stringify','addIndex\x20%s\x20%s\x20%s','join','Added\x20column\x20%s\x20to\x20%s','enqueue','removeIndex\x20%s\x20%s','sequence','addColumn','then','customerAlias','final','STRING','users','query','TEXT','queryInterface','Changed\x20column\x20%s\x20in\x20table\x20%s','migration','removeColumn'];(function(_0xa61e42,_0x2d642a){const _0x361e02=function(_0x53f658){while(--_0x53f658){_0xa61e42['push'](_0xa61e42['shift']());}};_0x361e02(++_0x2d642a);}(a943_0x2d64,0x1e7));const a943_0x361e=function(_0xa61e42,_0x2d642a){_0xa61e42=_0xa61e42-0x0;let _0x361e02=a943_0x2d64[_0xa61e42];return _0x361e02;};const _0x3b4970=a943_0x361e;'use strict';const util=require('util'),logger=require(_0x3b4970('0xa'))(_0x3b4970('0x1f')),Sequence=function(){};Sequence['prototype'][_0x3b4970('0x12')]=function(_0x53f658){const _0x15e4d7=_0x3b4970;this[_0x15e4d7('0x3')]=this[_0x15e4d7('0x3')]?this[_0x15e4d7('0x3')][_0x15e4d7('0x24')](_0x53f658):_0x53f658();};const Migration=function(_0xdff484){const _0xa4bfac=_0x3b4970;this[_0xa4bfac('0x1d')]=_0xdff484,this[_0xa4bfac('0x14')]=new Sequence();};Migration[_0x3b4970('0x9')][_0x3b4970('0x1')]=function(_0x1c33db,_0x13fb9b,_0x11562b){const _0xbe3519=_0x3b4970,_0x5829e1=this;this[_0xbe3519('0x14')][_0xbe3519('0x12')](function(){const _0xd91fc9=_0xbe3519;return _0x5829e1[_0xd91fc9('0x1d')][_0xd91fc9('0x1')](_0x1c33db,_0x13fb9b,_0x11562b)[_0xd91fc9('0x16')](function(){const _0x44d87e=_0xd91fc9;logger[_0x44d87e('0xc')](_0x44d87e('0x1e'),_0x13fb9b,_0x1c33db);})[_0xd91fc9('0x22')](function(_0x5b30d3){const _0x49f152=_0xd91fc9;logger[_0x49f152('0xc')](JSON['stringify'](_0x5b30d3));});});},Migration[_0x3b4970('0x9')][_0x3b4970('0x15')]=function(_0x385ceb,_0x3e74db,_0x265f00){const _0x4f9705=_0x3b4970,_0xddf07c=this;this['sequence'][_0x4f9705('0x12')](function(){const _0x35db2a=_0x4f9705;return _0xddf07c[_0x35db2a('0x1d')][_0x35db2a('0x15')](_0x385ceb,_0x3e74db,_0x265f00)[_0x35db2a('0x16')](function(){const _0x3f15e6=_0x35db2a;logger[_0x3f15e6('0xc')](_0x3f15e6('0x11'),_0x3e74db,_0x385ceb);})['catch'](function(_0x3347b5){const _0x4ea635=_0x35db2a;logger['info'](JSON[_0x4ea635('0xe')](_0x3347b5));});});},Migration[_0x3b4970('0x9')][_0x3b4970('0x2')]=function(_0x14bac5){const _0x330326=_0x3b4970,_0x5efc36=this;this[_0x330326('0x14')][_0x330326('0x12')](function(){const _0x9eb5fc=_0x330326;return _0x5efc36[_0x9eb5fc('0x1d')][_0x9eb5fc('0x2')](_0x14bac5,{'force':!![]})[_0x9eb5fc('0x16')](function(){const _0x4cec7d=_0x9eb5fc;logger[_0x4cec7d('0xc')](_0x4cec7d('0x8'),_0x14bac5);})[_0x9eb5fc('0x22')](function(_0xc01571){const _0xa09445=_0x9eb5fc;logger[_0xa09445('0xc')](JSON[_0xa09445('0xe')](_0xc01571));});});},Migration[_0x3b4970('0x9')]['addIndex']=function(_0x425133,_0x4c8718,_0xde8f6c){const _0x2068ad=_0x3b4970,_0x28450a=this;this[_0x2068ad('0x14')][_0x2068ad('0x12')](function(){const _0xd66f45=_0x2068ad;return _0x28450a[_0xd66f45('0x1d')]['addIndex'](_0x425133,_0x4c8718,{'indexName':_0xde8f6c})['then'](function(){const _0x48c575=_0xd66f45;logger[_0x48c575('0xc')](_0x48c575('0xf'),_0x425133,_0x4c8718[_0x48c575('0x10')](','),_0xde8f6c);})[_0xd66f45('0x22')](function(_0x87b80c){const _0x1ce75b=_0xd66f45;logger['info'](JSON[_0x1ce75b('0xe')](_0x87b80c));});});},Migration['prototype']['removeIndex']=function(_0x39bc56,_0x263674){const _0x4900e5=_0x3b4970,_0x5dc865=this;this[_0x4900e5('0x14')][_0x4900e5('0x12')](function(){const _0x8661cf=_0x4900e5;return _0x5dc865['queryInterface'][_0x8661cf('0xb')](_0x39bc56,_0x263674)[_0x8661cf('0x16')](function(){const _0x5b70d4=_0x8661cf;logger[_0x5b70d4('0xc')](_0x5b70d4('0x13'),_0x39bc56,_0x263674);})[_0x8661cf('0x22')](function(_0x4cf75a){const _0x229585=_0x8661cf;logger[_0x229585('0xc')](JSON[_0x229585('0xe')](_0x4cf75a));});});},Migration[_0x3b4970('0x9')][_0x3b4970('0x1b')]=function(_0x429319){const _0x5657a6=_0x3b4970,_0x3d14a3=this;this[_0x5657a6('0x14')]['enqueue'](function(){const _0x3dd2df=_0x5657a6;return _0x3d14a3['queryInterface'][_0x3dd2df('0x25')]['query'](_0x429319)[_0x3dd2df('0x16')](function(){const _0x2a6db8=_0x3dd2df;logger[_0x2a6db8('0xc')](_0x2a6db8('0x6'),_0x429319);})[_0x3dd2df('0x22')](function(_0x1398da){logger['info'](JSON['stringify'](_0x1398da));});});},Migration['prototype'][_0x3b4970('0x20')]=function(_0x5e29ca,_0x211b66){const _0x33b03a=_0x3b4970,_0x3f690d=this;this['sequence'][_0x33b03a('0x12')](function(){const _0x1e28b7=_0x33b03a;return _0x3f690d[_0x1e28b7('0x1d')][_0x1e28b7('0x20')](_0x5e29ca,_0x211b66)[_0x1e28b7('0x16')](function(){const _0x218dba=_0x1e28b7;logger['info'](_0x218dba('0x23'),_0x211b66,_0x5e29ca);})[_0x1e28b7('0x22')](function(_0x5f558e){const _0x19d058=_0x1e28b7;logger[_0x19d058('0xc')](util['inspect'](_0x5f558e,{'showHidden':![],'depth':null}));});});},Migration[_0x3b4970('0x9')][_0x3b4970('0x27')]=function(_0x4975a3,_0xa711eb,_0x5345f1){const _0x4612fb=_0x3b4970,_0x3c0e5b=this;this[_0x4612fb('0x14')][_0x4612fb('0x12')](function(){const _0x1ff91c=_0x4612fb;return _0x3c0e5b[_0x1ff91c('0x1d')][_0x1ff91c('0x27')](_0x4975a3,_0xa711eb,_0x5345f1)[_0x1ff91c('0x16')](function(){const _0x58b329=_0x1ff91c;logger[_0x58b329('0xc')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0xa711eb,_0x5345f1,_0x4975a3);})[_0x1ff91c('0x22')](function(_0x483be9){const _0x4a4ce6=_0x1ff91c;logger[_0x4a4ce6('0xc')](util[_0x4a4ce6('0x5')](_0x483be9,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x3b4970('0x18')]=function(_0x22ea51){const _0x57ee27=_0x3b4970;this[_0x57ee27('0x14')][_0x57ee27('0x12')](function(){return _0x22ea51();});},module[_0x3b4970('0xd')]={'up':function(_0x585ae5,_0x5619e4){return new Promise(function(_0xad5cbd){const _0x767de7=a943_0x361e,_0x2c9b36=new Migration(_0x585ae5);_0x2c9b36[_0x767de7('0x15')](_0x767de7('0x1a'),'phoneBarEnableVideoRecording',{'type':_0x5619e4[_0x767de7('0x4')],'defaultValue':![]}),_0x2c9b36[_0x767de7('0x1')]('report_call',_0x767de7('0x7'),{'type':_0x5619e4[_0x767de7('0x1c')]}),_0x2c9b36[_0x767de7('0x15')]('chat_websites',_0x767de7('0x17'),{'type':_0x5619e4[_0x767de7('0x19')],'defaultValue':'Me'}),_0x2c9b36[_0x767de7('0x1')]('analytics_report_fields',_0x767de7('0x0'),{'type':_0x5619e4['TEXT'],'allowNull':![]}),_0x2c9b36['removeIndex'](_0x767de7('0x21'),_0x767de7('0x26')),_0x2c9b36[_0x767de7('0x18')](_0xad5cbd);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.65.js b/server/migrations/2.0.65.js index 7657a07..a89ae1f 100644 --- a/server/migrations/2.0.65.js +++ b/server/migrations/2.0.65.js @@ -1 +1 @@ -const a944_0x5696=['join','sequence','../config/logger','renameColumn','changeColumn','final','Added\x20column\x20%s\x20to\x20%s','CREATE\x20TABLE\x20`cm_contact_has_tags`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`CmContactId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`TagId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`CmContactId`,`TagId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`TagId`\x20(`TagId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`cm_contact_has_tags_ibfk_1`\x20FOREIGN\x20KEY\x20(`CmContactId`)\x20REFERENCES\x20`cm_contacts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`cm_contact_has_tags_ibfk_2`\x20FOREIGN\x20KEY\x20(`TagId`)\x20REFERENCES\x20`tools_tags`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','removeIndex','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(3)','table\x20dropped\x20%s','sequelize','catch','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(1)','stringify','then','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(6)','addColumn','campaigns','cm_contacts','prototype','enqueue','Changed\x20column\x20%s\x20in\x20table\x20%s','tail','util','removeColumn','queryInterface','ALTER\x20TABLE\x20tmp_tools_tags\x20ADD\x20COLUMN\x20contact_id\x20INT\x20NULL','dialRandomLastDigitCallerIdNumber','finally','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(2)','CREATE\x20TABLE\x20ints(i\x20int(11)\x20DEFAULT\x20NULL,UNIQUE\x20KEY\x20i_UNIQUE\x20(i))\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8','info','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(8)','query','INTEGER','dropTable','inspect','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(9)','addIndex','INSERT\x20INTO\x20cm_contact_has_tags(createdAt,\x20updatedAt,\x20`CmContactId`,\x20`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20SELECT\x20\x20NOW(),\x20NOW(),\x20tmt.contact_id,\x20tt.id\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tmp_tools_tags\x20tmt\x20\x20\x20\x20\x20\x20\x20\x20\x20JOIN\x20tools_tags\x20tt\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20tmt.name\x20=\x20tt.name;','STRING','dialCutDigit','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(4)','voice_queues','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(0)','teams','addIndex\x20%s\x20%s\x20%s','migration','UNSIGNED','query\x20%s'];(function(_0x45fe7a,_0x569606){const _0x4d97ad=function(_0xf63a3a){while(--_0xf63a3a){_0x45fe7a['push'](_0x45fe7a['shift']());}};_0x4d97ad(++_0x569606);}(a944_0x5696,0x1ec));const a944_0x4d97=function(_0x45fe7a,_0x569606){_0x45fe7a=_0x45fe7a-0x0;let _0x4d97ad=a944_0x5696[_0x45fe7a];return _0x4d97ad;};const _0x277bd7=a944_0x4d97;'use strict';const util=require(_0x277bd7('0x2a')),logger=require(_0x277bd7('0x14'))(_0x277bd7('0xf')),Sequence=function(){};Sequence[_0x277bd7('0x26')][_0x277bd7('0x27')]=function(_0xf63a3a){const _0x557e9c=_0x277bd7;this[_0x557e9c('0x29')]=this[_0x557e9c('0x29')]?this[_0x557e9c('0x29')][_0x557e9c('0x2f')](_0xf63a3a):_0xf63a3a();};const Migration=function(_0x32b743){this['queryInterface']=_0x32b743,this['sequence']=new Sequence();};Migration[_0x277bd7('0x26')]['changeColumn']=function(_0xb40213,_0xa66f9e,_0x3b4075){const _0x5cbd75=_0x277bd7,_0x4e879d=this;this[_0x5cbd75('0x13')][_0x5cbd75('0x27')](function(){const _0x35ca3f=_0x5cbd75;return _0x4e879d['queryInterface'][_0x35ca3f('0x16')](_0xb40213,_0xa66f9e,_0x3b4075)[_0x35ca3f('0x21')](function(){const _0x150c5b=_0x35ca3f;logger['info'](_0x150c5b('0x28'),_0xa66f9e,_0xb40213);})['catch'](function(_0x49971a){const _0x2da5ab=_0x35ca3f;logger[_0x2da5ab('0x32')](JSON[_0x2da5ab('0x20')](_0x49971a));});});},Migration[_0x277bd7('0x26')][_0x277bd7('0x23')]=function(_0x48fde6,_0x143fe1,_0x3d91f2){const _0x162535=_0x277bd7,_0x4d447b=this;this[_0x162535('0x13')][_0x162535('0x27')](function(){const _0x3e8482=_0x162535;return _0x4d447b[_0x3e8482('0x2c')][_0x3e8482('0x23')](_0x48fde6,_0x143fe1,_0x3d91f2)[_0x3e8482('0x21')](function(){const _0x2441ba=_0x3e8482;logger[_0x2441ba('0x32')](_0x2441ba('0x18'),_0x143fe1,_0x48fde6);})[_0x3e8482('0x1e')](function(_0x369b9d){const _0x175c0a=_0x3e8482;logger['info'](JSON[_0x175c0a('0x20')](_0x369b9d));});});},Migration['prototype'][_0x277bd7('0x3')]=function(_0x7cabb3){const _0x4a2603=_0x277bd7,_0x2602a9=this;this['sequence'][_0x4a2603('0x27')](function(){const _0x2065aa=_0x4a2603;return _0x2602a9[_0x2065aa('0x2c')][_0x2065aa('0x3')](_0x7cabb3,{'force':!![]})[_0x2065aa('0x21')](function(){const _0x3bc246=_0x2065aa;logger[_0x3bc246('0x32')](_0x3bc246('0x1c'),_0x7cabb3);})[_0x2065aa('0x1e')](function(_0x1f0c78){const _0x21a2eb=_0x2065aa;logger['info'](JSON[_0x21a2eb('0x20')](_0x1f0c78));});});},Migration[_0x277bd7('0x26')][_0x277bd7('0x6')]=function(_0x5b0603,_0x50ec76,_0x4a8280){const _0x11f679=_0x277bd7,_0x200788=this;this['sequence'][_0x11f679('0x27')](function(){const _0x5235e3=_0x11f679;return _0x200788['queryInterface'][_0x5235e3('0x6')](_0x5b0603,_0x50ec76,{'indexName':_0x4a8280})['then'](function(){const _0x372a7c=_0x5235e3;logger[_0x372a7c('0x32')](_0x372a7c('0xe'),_0x5b0603,_0x50ec76[_0x372a7c('0x12')](','),_0x4a8280);})[_0x5235e3('0x1e')](function(_0xcd3d7d){const _0x9ccbad=_0x5235e3;logger[_0x9ccbad('0x32')](JSON[_0x9ccbad('0x20')](_0xcd3d7d));});});},Migration[_0x277bd7('0x26')]['removeIndex']=function(_0x560efa,_0xc0efe6){const _0x4e7dac=_0x277bd7,_0x31e057=this;this['sequence'][_0x4e7dac('0x27')](function(){const _0x1f44dc=_0x4e7dac;return _0x31e057[_0x1f44dc('0x2c')][_0x1f44dc('0x1a')](_0x560efa,_0xc0efe6)[_0x1f44dc('0x21')](function(){const _0x425b6c=_0x1f44dc;logger[_0x425b6c('0x32')]('removeIndex\x20%s\x20%s',_0x560efa,_0xc0efe6);})[_0x1f44dc('0x1e')](function(_0x443a22){const _0x5ab923=_0x1f44dc;logger[_0x5ab923('0x32')](JSON[_0x5ab923('0x20')](_0x443a22));});});},Migration[_0x277bd7('0x26')]['query']=function(_0x138628){const _0x4e97d7=_0x277bd7,_0x5984ea=this;this[_0x4e97d7('0x13')]['enqueue'](function(){const _0x1c1632=_0x4e97d7;return _0x5984ea[_0x1c1632('0x2c')][_0x1c1632('0x1d')]['query'](_0x138628)[_0x1c1632('0x21')](function(){const _0x54410f=_0x1c1632;logger[_0x54410f('0x32')](_0x54410f('0x11'),_0x138628);})['catch'](function(_0x595998){const _0x211d81=_0x1c1632;logger[_0x211d81('0x32')](JSON[_0x211d81('0x20')](_0x595998));});});},Migration[_0x277bd7('0x26')]['removeColumn']=function(_0x3473ac,_0x1a80fc){const _0x5947fb=_0x277bd7,_0x40e4e7=this;this['sequence'][_0x5947fb('0x27')](function(){const _0x5f1957=_0x5947fb;return _0x40e4e7[_0x5f1957('0x2c')][_0x5f1957('0x2b')](_0x3473ac,_0x1a80fc)[_0x5f1957('0x21')](function(){const _0x421929=_0x5f1957;logger[_0x421929('0x32')]('Removed\x20column\x20%s\x20from\x20%s',_0x1a80fc,_0x3473ac);})[_0x5f1957('0x1e')](function(_0x2a1022){const _0x43628c=_0x5f1957;logger[_0x43628c('0x32')](util[_0x43628c('0x4')](_0x2a1022,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x277bd7('0x15')]=function(_0x47c690,_0x33e448,_0x417dbb){const _0x2d4d97=_0x277bd7,_0x401cad=this;this[_0x2d4d97('0x13')]['enqueue'](function(){const _0x1ca4f7=_0x2d4d97;return _0x401cad[_0x1ca4f7('0x2c')][_0x1ca4f7('0x15')](_0x47c690,_0x33e448,_0x417dbb)[_0x1ca4f7('0x21')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x33e448,_0x417dbb,_0x47c690);})[_0x1ca4f7('0x1e')](function(_0x433ea6){const _0x1a94e2=_0x1ca4f7;logger[_0x1a94e2('0x32')](util['inspect'](_0x433ea6,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x277bd7('0x17')]=function(_0xe837c9){const _0x47e68b=_0x277bd7;this[_0x47e68b('0x13')][_0x47e68b('0x27')](function(){return _0xe837c9();});},module['exports']={'up':function(_0x102c05,_0x16787a){return new Promise(function(_0x2b5b13){const _0x110de1=a944_0x4d97,_0x5a6439=new Migration(_0x102c05);_0x5a6439[_0x110de1('0x23')]('voice_queues',_0x110de1('0x2e'),{'type':_0x16787a[_0x110de1('0x2')](0x3)[_0x110de1('0x10')],'defaultValue':0x0}),_0x5a6439[_0x110de1('0x23')](_0x110de1('0xb'),_0x110de1('0x9'),{'type':_0x16787a[_0x110de1('0x2')](0x3)['UNSIGNED'],'defaultValue':0x0}),_0x5a6439[_0x110de1('0x23')](_0x110de1('0x24'),_0x110de1('0x2e'),{'type':_0x16787a['INTEGER'](0x3)[_0x110de1('0x10')],'defaultValue':0x0}),_0x5a6439[_0x110de1('0x23')](_0x110de1('0x24'),_0x110de1('0x9'),{'type':_0x16787a['INTEGER'](0x3)[_0x110de1('0x10')],'defaultValue':0x0}),_0x5a6439[_0x110de1('0x23')](_0x110de1('0x25'),_0x110de1('0xd'),{'type':_0x16787a[_0x110de1('0x8')]}),_0x5a6439[_0x110de1('0x1')](_0x110de1('0x19')),_0x5a6439['query']('CREATE\x20TABLE\x20`tmp_tools_tags`\x20(\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20\x20`name`\x20varchar(255)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`color`\x20varchar(255)\x20DEFAULT\x20\x27#0091EA\x27,\x20\x20\x20\x20\x20\x20\x20\x20\x20`description`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`))\x20ENGINE=InnoDB\x20CHARSET=utf8;'),_0x5a6439[_0x110de1('0x1')](_0x110de1('0x31')),_0x5a6439[_0x110de1('0x1')](_0x110de1('0xc')),_0x5a6439[_0x110de1('0x1')](_0x110de1('0x1f')),_0x5a6439['query'](_0x110de1('0x30')),_0x5a6439['query'](_0x110de1('0x1b')),_0x5a6439['query'](_0x110de1('0xa')),_0x5a6439[_0x110de1('0x1')]('INSERT\x20INTO\x20ints(i)\x20VALUES\x20(5)'),_0x5a6439['query'](_0x110de1('0x22')),_0x5a6439[_0x110de1('0x1')]('INSERT\x20INTO\x20ints(i)\x20VALUES\x20(7)'),_0x5a6439[_0x110de1('0x1')](_0x110de1('0x0')),_0x5a6439[_0x110de1('0x1')](_0x110de1('0x5')),_0x5a6439[_0x110de1('0x1')](_0x110de1('0x2d')),_0x5a6439[_0x110de1('0x1')]('INSERT\x20INTO\x20tmp_tools_tags(\x20name,\x20createdAt,\x20updatedAt,\x20contact_id)\x20\x20\x20\x20\x20\x20\x20\x20SELECT\x20splitted_tags,\x20CURRENT_TIMESTAMP(),\x20CURRENT_TIMESTAMP()\x20,\x20id\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SELECT\x20DISTINCT\x20cm.id,\x20cm.tags,\x20TRIM(SUBSTRING_INDEX(SUBSTRING_INDEX(cm.tags,\x20\x27;\x27,\x20i+1),\x27;\x27,-1))\x20splitted_tags\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20ints\x20i,\x20cm_contacts\x20cm\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20cm.tags\x20REGEXP\x20\x27(.*;){1}\x27\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20id)\x20a\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20a.tags\x20IS\x20NOT\x20NULL\x20and\x20splitted_tags\x20<>\x20\x27\x27;'),_0x5a6439['query'](_0x110de1('0x7')),_0x5a6439[_0x110de1('0x17')](_0x2b5b13);});},'down':function(){}}; \ No newline at end of file +const a944_0x45dc=['INSERT\x20INTO\x20ints(i)\x20VALUES\x20(3)','queryInterface','query','then','removeIndex\x20%s\x20%s','sequelize','voice_queues','renameColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','INSERT\x20INTO\x20cm_contact_has_tags(createdAt,\x20updatedAt,\x20`CmContactId`,\x20`TagId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20SELECT\x20\x20NOW(),\x20NOW(),\x20tmt.contact_id,\x20tt.id\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tmp_tools_tags\x20tmt\x20\x20\x20\x20\x20\x20\x20\x20\x20JOIN\x20tools_tags\x20tt\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20tmt.name\x20=\x20tt.name;','dialCutDigit','addIndex\x20%s\x20%s\x20%s','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(8)','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(9)','ALTER\x20TABLE\x20tmp_tools_tags\x20ADD\x20COLUMN\x20contact_id\x20INT\x20NULL','finally','INTEGER','campaigns','exports','Added\x20column\x20%s\x20to\x20%s','util','UNSIGNED','dropTable','join','tail','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(2)','addIndex','prototype','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(0)','INSERT\x20INTO\x20tmp_tools_tags(\x20name,\x20createdAt,\x20updatedAt,\x20contact_id)\x20\x20\x20\x20\x20\x20\x20\x20SELECT\x20splitted_tags,\x20CURRENT_TIMESTAMP(),\x20CURRENT_TIMESTAMP()\x20,\x20id\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SELECT\x20DISTINCT\x20cm.id,\x20cm.tags,\x20TRIM(SUBSTRING_INDEX(SUBSTRING_INDEX(cm.tags,\x20\x27;\x27,\x20i+1),\x27;\x27,-1))\x20splitted_tags\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20ints\x20i,\x20cm_contacts\x20cm\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20cm.tags\x20REGEXP\x20\x27(.*;){1}\x27\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20id)\x20a\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20a.tags\x20IS\x20NOT\x20NULL\x20and\x20splitted_tags\x20<>\x20\x27\x27;','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','query\x20%s','removeIndex','removeColumn','table\x20dropped\x20%s','cm_contacts','CREATE\x20TABLE\x20ints(i\x20int(11)\x20DEFAULT\x20NULL,UNIQUE\x20KEY\x20i_UNIQUE\x20(i))\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8','final','CREATE\x20TABLE\x20`tmp_tools_tags`\x20(\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20\x20`name`\x20varchar(255)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`color`\x20varchar(255)\x20DEFAULT\x20\x27#0091EA\x27,\x20\x20\x20\x20\x20\x20\x20\x20\x20`description`\x20varchar(255)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`))\x20ENGINE=InnoDB\x20CHARSET=utf8;','INSERT\x20INTO\x20ints(i)\x20VALUES\x20(5)','info','teams','addColumn','changeColumn','inspect','catch','Removed\x20column\x20%s\x20from\x20%s','stringify','sequence','enqueue'];(function(_0x4b9c13,_0x45dc11){const _0xeaf825=function(_0x271e70){while(--_0x271e70){_0x4b9c13['push'](_0x4b9c13['shift']());}};_0xeaf825(++_0x45dc11);}(a944_0x45dc,0x155));const a944_0xeaf8=function(_0x4b9c13,_0x45dc11){_0x4b9c13=_0x4b9c13-0x0;let _0xeaf825=a944_0x45dc[_0x4b9c13];return _0xeaf825;};const _0x2d4d31=a944_0xeaf8;'use strict';const util=require(_0x2d4d31('0x1d')),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence[_0x2d4d31('0x24')][_0x2d4d31('0x8')]=function(_0x271e70){const _0x9cd785=_0x2d4d31;this['tail']=this[_0x9cd785('0x21')]?this[_0x9cd785('0x21')][_0x9cd785('0x18')](_0x271e70):_0x271e70();};const Migration=function(_0x311806){const _0x2b85b1=_0x2d4d31;this[_0x2b85b1('0xa')]=_0x311806,this[_0x2b85b1('0x7')]=new Sequence();};Migration[_0x2d4d31('0x24')][_0x2d4d31('0x2')]=function(_0x3d43fa,_0x3fbc4d,_0x129127){const _0x4992a5=_0x2d4d31,_0x374341=this;this['sequence'][_0x4992a5('0x8')](function(){const _0x3b724f=_0x4992a5;return _0x374341[_0x3b724f('0xa')][_0x3b724f('0x2')](_0x3d43fa,_0x3fbc4d,_0x129127)[_0x3b724f('0xc')](function(){const _0x157039=_0x3b724f;logger[_0x157039('0x31')](_0x157039('0x11'),_0x3fbc4d,_0x3d43fa);})['catch'](function(_0x57dd1a){const _0x3815ef=_0x3b724f;logger['info'](JSON[_0x3815ef('0x6')](_0x57dd1a));});});},Migration[_0x2d4d31('0x24')][_0x2d4d31('0x1')]=function(_0x4fabe7,_0x5ee246,_0x2fe72c){const _0x5e87cf=_0x2d4d31,_0x19e0b7=this;this[_0x5e87cf('0x7')][_0x5e87cf('0x8')](function(){const _0x4aee1b=_0x5e87cf;return _0x19e0b7['queryInterface'][_0x4aee1b('0x1')](_0x4fabe7,_0x5ee246,_0x2fe72c)[_0x4aee1b('0xc')](function(){const _0x4602a6=_0x4aee1b;logger['info'](_0x4602a6('0x1c'),_0x5ee246,_0x4fabe7);})[_0x4aee1b('0x4')](function(_0x3c7e6b){const _0x5e0b2c=_0x4aee1b;logger[_0x5e0b2c('0x31')](JSON['stringify'](_0x3c7e6b));});});},Migration[_0x2d4d31('0x24')]['dropTable']=function(_0x113271){const _0xeb8f8f=_0x2d4d31,_0x51c9e5=this;this[_0xeb8f8f('0x7')][_0xeb8f8f('0x8')](function(){const _0x1e87a3=_0xeb8f8f;return _0x51c9e5[_0x1e87a3('0xa')][_0x1e87a3('0x1f')](_0x113271,{'force':!![]})[_0x1e87a3('0xc')](function(){const _0x11649f=_0x1e87a3;logger[_0x11649f('0x31')](_0x11649f('0x2b'),_0x113271);})[_0x1e87a3('0x4')](function(_0x3c6adc){const _0x43911f=_0x1e87a3;logger[_0x43911f('0x31')](JSON['stringify'](_0x3c6adc));});});},Migration['prototype']['addIndex']=function(_0x156985,_0x5298b2,_0x4c045a){const _0x18fc2e=_0x2d4d31,_0x43055a=this;this[_0x18fc2e('0x7')][_0x18fc2e('0x8')](function(){const _0x260782=_0x18fc2e;return _0x43055a[_0x260782('0xa')][_0x260782('0x23')](_0x156985,_0x5298b2,{'indexName':_0x4c045a})[_0x260782('0xc')](function(){const _0x1158be=_0x260782;logger[_0x1158be('0x31')](_0x1158be('0x14'),_0x156985,_0x5298b2[_0x1158be('0x20')](','),_0x4c045a);})[_0x260782('0x4')](function(_0x2ed24a){const _0x570ac8=_0x260782;logger[_0x570ac8('0x31')](JSON[_0x570ac8('0x6')](_0x2ed24a));});});},Migration[_0x2d4d31('0x24')][_0x2d4d31('0x29')]=function(_0x2fa792,_0xb623e8){const _0x315667=_0x2d4d31,_0x5d4e8a=this;this[_0x315667('0x7')][_0x315667('0x8')](function(){const _0x3b33fe=_0x315667;return _0x5d4e8a[_0x3b33fe('0xa')]['removeIndex'](_0x2fa792,_0xb623e8)['then'](function(){const _0x2d49e7=_0x3b33fe;logger[_0x2d49e7('0x31')](_0x2d49e7('0xd'),_0x2fa792,_0xb623e8);})[_0x3b33fe('0x4')](function(_0x48eb47){const _0x2d7310=_0x3b33fe;logger['info'](JSON[_0x2d7310('0x6')](_0x48eb47));});});},Migration[_0x2d4d31('0x24')][_0x2d4d31('0xb')]=function(_0x410c8c){const _0x24cc7a=_0x2d4d31,_0x4a24fb=this;this['sequence'][_0x24cc7a('0x8')](function(){const _0xf98f78=_0x24cc7a;return _0x4a24fb['queryInterface'][_0xf98f78('0xe')][_0xf98f78('0xb')](_0x410c8c)[_0xf98f78('0xc')](function(){const _0x2dae0a=_0xf98f78;logger[_0x2dae0a('0x31')](_0x2dae0a('0x28'),_0x410c8c);})[_0xf98f78('0x4')](function(_0x420743){const _0x32d0de=_0xf98f78;logger[_0x32d0de('0x31')](JSON['stringify'](_0x420743));});});},Migration['prototype'][_0x2d4d31('0x2a')]=function(_0x10abd4,_0x49dc72){const _0x2a2ce4=_0x2d4d31,_0x4cbc1a=this;this[_0x2a2ce4('0x7')]['enqueue'](function(){const _0x238020=_0x2a2ce4;return _0x4cbc1a[_0x238020('0xa')][_0x238020('0x2a')](_0x10abd4,_0x49dc72)[_0x238020('0xc')](function(){const _0x39d12a=_0x238020;logger[_0x39d12a('0x31')](_0x39d12a('0x5'),_0x49dc72,_0x10abd4);})[_0x238020('0x4')](function(_0x4f65bb){const _0xd09042=_0x238020;logger['info'](util[_0xd09042('0x3')](_0x4f65bb,{'showHidden':![],'depth':null}));});});},Migration[_0x2d4d31('0x24')][_0x2d4d31('0x10')]=function(_0x597796,_0x1141e7,_0x2c8179){const _0x398971=_0x2d4d31,_0x2737a6=this;this[_0x398971('0x7')]['enqueue'](function(){const _0x352842=_0x398971;return _0x2737a6[_0x352842('0xa')][_0x352842('0x10')](_0x597796,_0x1141e7,_0x2c8179)[_0x352842('0xc')](function(){const _0x3ec643=_0x352842;logger[_0x3ec643('0x31')](_0x3ec643('0x27'),_0x1141e7,_0x2c8179,_0x597796);})['catch'](function(_0x1038ff){const _0x45035a=_0x352842;logger['info'](util[_0x45035a('0x3')](_0x1038ff,{'showHidden':![],'depth':null}));});});},Migration[_0x2d4d31('0x24')][_0x2d4d31('0x2e')]=function(_0x1c308a){this['sequence']['enqueue'](function(){return _0x1c308a();});},module[_0x2d4d31('0x1b')]={'up':function(_0x494adb,_0x3253e8){return new Promise(function(_0xb377db){const _0x1a1bd1=a944_0xeaf8,_0x4fc4d3=new Migration(_0x494adb);_0x4fc4d3[_0x1a1bd1('0x1')](_0x1a1bd1('0xf'),'dialRandomLastDigitCallerIdNumber',{'type':_0x3253e8['INTEGER'](0x3)[_0x1a1bd1('0x1e')],'defaultValue':0x0}),_0x4fc4d3['addColumn'](_0x1a1bd1('0xf'),_0x1a1bd1('0x13'),{'type':_0x3253e8[_0x1a1bd1('0x19')](0x3)[_0x1a1bd1('0x1e')],'defaultValue':0x0}),_0x4fc4d3['addColumn'](_0x1a1bd1('0x1a'),'dialRandomLastDigitCallerIdNumber',{'type':_0x3253e8[_0x1a1bd1('0x19')](0x3)[_0x1a1bd1('0x1e')],'defaultValue':0x0}),_0x4fc4d3[_0x1a1bd1('0x1')]('campaigns',_0x1a1bd1('0x13'),{'type':_0x3253e8['INTEGER'](0x3)[_0x1a1bd1('0x1e')],'defaultValue':0x0}),_0x4fc4d3[_0x1a1bd1('0x1')](_0x1a1bd1('0x2c'),_0x1a1bd1('0x0'),{'type':_0x3253e8['STRING']}),_0x4fc4d3['query']('CREATE\x20TABLE\x20`cm_contact_has_tags`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`CmContactId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`TagId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`CmContactId`,`TagId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`TagId`\x20(`TagId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`cm_contact_has_tags_ibfk_1`\x20FOREIGN\x20KEY\x20(`CmContactId`)\x20REFERENCES\x20`cm_contacts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`cm_contact_has_tags_ibfk_2`\x20FOREIGN\x20KEY\x20(`TagId`)\x20REFERENCES\x20`tools_tags`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;'),_0x4fc4d3['query'](_0x1a1bd1('0x2f')),_0x4fc4d3[_0x1a1bd1('0xb')](_0x1a1bd1('0x2d')),_0x4fc4d3[_0x1a1bd1('0xb')](_0x1a1bd1('0x25')),_0x4fc4d3['query']('INSERT\x20INTO\x20ints(i)\x20VALUES\x20(1)'),_0x4fc4d3['query'](_0x1a1bd1('0x22')),_0x4fc4d3[_0x1a1bd1('0xb')](_0x1a1bd1('0x9')),_0x4fc4d3[_0x1a1bd1('0xb')]('INSERT\x20INTO\x20ints(i)\x20VALUES\x20(4)'),_0x4fc4d3[_0x1a1bd1('0xb')](_0x1a1bd1('0x30')),_0x4fc4d3[_0x1a1bd1('0xb')]('INSERT\x20INTO\x20ints(i)\x20VALUES\x20(6)'),_0x4fc4d3[_0x1a1bd1('0xb')]('INSERT\x20INTO\x20ints(i)\x20VALUES\x20(7)'),_0x4fc4d3[_0x1a1bd1('0xb')](_0x1a1bd1('0x15')),_0x4fc4d3[_0x1a1bd1('0xb')](_0x1a1bd1('0x16')),_0x4fc4d3[_0x1a1bd1('0xb')](_0x1a1bd1('0x17')),_0x4fc4d3['query'](_0x1a1bd1('0x26')),_0x4fc4d3['query'](_0x1a1bd1('0x12')),_0x4fc4d3[_0x1a1bd1('0x2e')](_0xb377db);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.66.js b/server/migrations/2.0.66.js index 147a19d..94b8919 100644 --- a/server/migrations/2.0.66.js +++ b/server/migrations/2.0.66.js @@ -1 +1 @@ -const a945_0x3da8=['\x20CHARSET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci','bcc','prototype','changeColumn','removeIndex','removeColumn','join','removeIndex\x20%s\x20%s','TEXT','then','query\x20%s','INTEGER','finally','addIndex','sequence','dropTable','field','final','sequelize','table\x20dropped\x20%s','inspect','long','phoneBarPrefixRequired','split','splitSizeXlsx','agentTransfer','lastMsgBody','Removed\x20column\x20%s\x20from\x20%s','mail_interactions','cm_contacts','addColumn','migration','settings','../config/logger','tail','stringify','analytics_report_fields','viber','util','addIndex\x20%s\x20%s\x20%s','Added\x20column\x20%s\x20to\x20%s','users','info','tools_schedules','enqueue','mail_accounts','STRING','subject','queueTransfer','query','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','BOOLEAN','queryInterface','Changed\x20column\x20%s\x20in\x20table\x20%s','exports','catch'];(function(_0x12bbe4,_0x3da810){const _0x5d52c3=function(_0x289b6e){while(--_0x289b6e){_0x12bbe4['push'](_0x12bbe4['shift']());}};_0x5d52c3(++_0x3da810);}(a945_0x3da8,0x161));const a945_0x5d52=function(_0x12bbe4,_0x3da810){_0x12bbe4=_0x12bbe4-0x0;let _0x5d52c3=a945_0x3da8[_0x12bbe4];return _0x5d52c3;};const _0x21f531=a945_0x5d52;'use strict';const util=require(_0x21f531('0x15')),logger=require(_0x21f531('0x10'))(_0x21f531('0xe')),Sequence=function(){};Sequence[_0x21f531('0x29')]['enqueue']=function(_0x289b6e){const _0x51bd3e=_0x21f531;this[_0x51bd3e('0x11')]=this[_0x51bd3e('0x11')]?this[_0x51bd3e('0x11')][_0x51bd3e('0x33')](_0x289b6e):_0x289b6e();};const Migration=function(_0x87d11c){const _0x32d552=_0x21f531;this[_0x32d552('0x23')]=_0x87d11c,this[_0x32d552('0x35')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x588f2e,_0x53919f,_0x3060a5){const _0x2a5443=_0x21f531,_0x3a31c2=this;this['sequence'][_0x2a5443('0x1b')](function(){const _0xe8dba0=_0x2a5443;return _0x3a31c2[_0xe8dba0('0x23')][_0xe8dba0('0x2a')](_0x588f2e,_0x53919f,_0x3060a5)[_0xe8dba0('0x30')](function(){const _0x1fd32d=_0xe8dba0;logger[_0x1fd32d('0x19')](_0x1fd32d('0x24'),_0x53919f,_0x588f2e);})[_0xe8dba0('0x26')](function(_0x27e010){logger['info'](JSON['stringify'](_0x27e010));});});},Migration[_0x21f531('0x29')]['addColumn']=function(_0x206da3,_0x491100,_0x3aba05){const _0x4c7df6=_0x21f531,_0xaa28d9=this;this['sequence'][_0x4c7df6('0x1b')](function(){const _0x5ccdaf=_0x4c7df6;return _0xaa28d9[_0x5ccdaf('0x23')][_0x5ccdaf('0xd')](_0x206da3,_0x491100,_0x3aba05)['then'](function(){const _0x50bfaa=_0x5ccdaf;logger[_0x50bfaa('0x19')](_0x50bfaa('0x17'),_0x491100,_0x206da3);})[_0x5ccdaf('0x26')](function(_0x39e836){const _0x4fbc61=_0x5ccdaf;logger[_0x4fbc61('0x19')](JSON[_0x4fbc61('0x12')](_0x39e836));});});},Migration[_0x21f531('0x29')][_0x21f531('0x36')]=function(_0x212ee5){const _0x476a58=_0x21f531,_0x2c9bf5=this;this[_0x476a58('0x35')][_0x476a58('0x1b')](function(){const _0x5c6a11=_0x476a58;return _0x2c9bf5[_0x5c6a11('0x23')][_0x5c6a11('0x36')](_0x212ee5,{'force':!![]})[_0x5c6a11('0x30')](function(){const _0x1e810c=_0x5c6a11;logger[_0x1e810c('0x19')](_0x1e810c('0x2'),_0x212ee5);})['catch'](function(_0x3f7c0c){const _0x1d24e4=_0x5c6a11;logger[_0x1d24e4('0x19')](JSON[_0x1d24e4('0x12')](_0x3f7c0c));});});},Migration[_0x21f531('0x29')][_0x21f531('0x34')]=function(_0x27bed2,_0x581ca6,_0x280957){const _0xf87843=_0x21f531,_0x3bd8a7=this;this['sequence'][_0xf87843('0x1b')](function(){const _0x13697f=_0xf87843;return _0x3bd8a7[_0x13697f('0x23')]['addIndex'](_0x27bed2,_0x581ca6,{'indexName':_0x280957})['then'](function(){const _0x4fba52=_0x13697f;logger[_0x4fba52('0x19')](_0x4fba52('0x16'),_0x27bed2,_0x581ca6[_0x4fba52('0x2d')](','),_0x280957);})[_0x13697f('0x26')](function(_0x32ac92){const _0x163f15=_0x13697f;logger[_0x163f15('0x19')](JSON['stringify'](_0x32ac92));});});},Migration[_0x21f531('0x29')][_0x21f531('0x2b')]=function(_0x3dc7ff,_0x3e5209){const _0x5a87c6=_0x21f531,_0x5ebcfd=this;this[_0x5a87c6('0x35')][_0x5a87c6('0x1b')](function(){const _0x3ca9a3=_0x5a87c6;return _0x5ebcfd[_0x3ca9a3('0x23')][_0x3ca9a3('0x2b')](_0x3dc7ff,_0x3e5209)[_0x3ca9a3('0x30')](function(){const _0x4cb0d3=_0x3ca9a3;logger[_0x4cb0d3('0x19')](_0x4cb0d3('0x2e'),_0x3dc7ff,_0x3e5209);})['catch'](function(_0x3d9a1d){const _0x48ce2f=_0x3ca9a3;logger[_0x48ce2f('0x19')](JSON[_0x48ce2f('0x12')](_0x3d9a1d));});});},Migration[_0x21f531('0x29')][_0x21f531('0x20')]=function(_0x367559){const _0x2379a7=_0x21f531,_0x406c6d=this;this[_0x2379a7('0x35')][_0x2379a7('0x1b')](function(){const _0x3536cb=_0x2379a7;return _0x406c6d[_0x3536cb('0x23')][_0x3536cb('0x1')][_0x3536cb('0x20')](_0x367559)['then'](function(){const _0x5de10a=_0x3536cb;logger[_0x5de10a('0x19')](_0x5de10a('0x31'),_0x367559);})[_0x3536cb('0x26')](function(_0x52e4ef){const _0x213760=_0x3536cb;logger[_0x213760('0x19')](JSON[_0x213760('0x12')](_0x52e4ef));});});},Migration[_0x21f531('0x29')][_0x21f531('0x2c')]=function(_0x21e4b9,_0x48c1fc){const _0x229c53=_0x21f531,_0x9844dc=this;this['sequence'][_0x229c53('0x1b')](function(){const _0x50082a=_0x229c53;return _0x9844dc[_0x50082a('0x23')][_0x50082a('0x2c')](_0x21e4b9,_0x48c1fc)['then'](function(){const _0x4389cb=_0x50082a;logger['info'](_0x4389cb('0xa'),_0x48c1fc,_0x21e4b9);})[_0x50082a('0x26')](function(_0x305078){const _0x4b1d0b=_0x50082a;logger[_0x4b1d0b('0x19')](util[_0x4b1d0b('0x3')](_0x305078,{'showHidden':![],'depth':null}));});});},Migration[_0x21f531('0x29')]['renameColumn']=function(_0x412d4e,_0x330f67,_0x1e8c11){const _0x2e7bb5=_0x21f531,_0x20a2b0=this;this['sequence'][_0x2e7bb5('0x1b')](function(){const _0x1294bf=_0x2e7bb5;return _0x20a2b0[_0x1294bf('0x23')]['renameColumn'](_0x412d4e,_0x330f67,_0x1e8c11)['then'](function(){const _0x5263cb=_0x1294bf;logger[_0x5263cb('0x19')](_0x5263cb('0x21'),_0x330f67,_0x1e8c11,_0x412d4e);})['catch'](function(_0x4a774b){const _0x45f3e4=_0x1294bf;logger[_0x45f3e4('0x19')](util['inspect'](_0x4a774b,{'showHidden':![],'depth':null}));});});},Migration[_0x21f531('0x29')]['final']=function(_0x2d020b){const _0x429d81=_0x21f531;this[_0x429d81('0x35')][_0x429d81('0x1b')](function(){return _0x2d020b();});},module[_0x21f531('0x25')]={'up':function(_0x1128fd,_0x43bb4e){return new Promise(function(_0x10b122){const _0x35f8fb=a945_0x5d52,_0x5418a1=new Migration(_0x1128fd);_0x5418a1[_0x35f8fb('0x2a')](_0x35f8fb('0x13'),_0x35f8fb('0x37'),{'type':_0x43bb4e[_0x35f8fb('0x2f')]}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0x1a'),'cc',{'type':_0x43bb4e[_0x35f8fb('0x2f')]}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0x1a'),_0x35f8fb('0x28'),{'type':_0x43bb4e[_0x35f8fb('0x2f')]}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0xf'),_0x35f8fb('0x6'),{'type':_0x43bb4e[_0x35f8fb('0x22')],'defaultValue':!![]}),_0x5418a1['addColumn'](_0x35f8fb('0xf'),'splitSizeCsv',{'type':_0x43bb4e[_0x35f8fb('0x32')],'defaultValue':0x1388}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0xf'),'splitSizePdf',{'type':_0x43bb4e[_0x35f8fb('0x32')],'defaultValue':0x3e8}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0xf'),_0x35f8fb('0x7'),{'type':_0x43bb4e[_0x35f8fb('0x32')],'defaultValue':0x1388}),_0x5418a1['addColumn'](_0x35f8fb('0x1c'),_0x35f8fb('0x1f'),{'type':_0x43bb4e['BOOLEAN'],'defaultValue':![]}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0x1c'),'queueTransferTimeout',{'type':_0x43bb4e[_0x35f8fb('0x32')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0x1c'),_0x35f8fb('0x8'),{'type':_0x43bb4e[_0x35f8fb('0x22')],'defaultValue':![]}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0x1c'),'agentTransferTimeout',{'type':_0x43bb4e[_0x35f8fb('0x32')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0x18'),_0x35f8fb('0x5'),{'type':_0x43bb4e[_0x35f8fb('0x22')],'defaultValue':![]}),_0x5418a1[_0x35f8fb('0x2a')](_0x35f8fb('0xb'),_0x35f8fb('0x1e'),{'type':_0x43bb4e['TEXT']('')+'\x20CHARSET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci'}),_0x5418a1[_0x35f8fb('0x2a')](_0x35f8fb('0xb'),_0x35f8fb('0x9'),{'type':_0x43bb4e[_0x35f8fb('0x2f')](_0x35f8fb('0x4'))+_0x35f8fb('0x27')}),_0x5418a1[_0x35f8fb('0xd')](_0x35f8fb('0xc'),_0x35f8fb('0x14'),{'type':_0x43bb4e[_0x35f8fb('0x1d')]}),_0x5418a1[_0x35f8fb('0x0')](_0x10b122);});},'down':function(){}}; \ No newline at end of file +const a945_0x24d0=['Changed\x20column\x20%s\x20in\x20table\x20%s','renameColumn','lastMsgBody','dropTable','addColumn','table\x20dropped\x20%s','sequence','INTEGER','stringify','\x20CHARSET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci','join','query','BOOLEAN','queueTransfer','inspect','mail_interactions','finally','changeColumn','catch','splitSizeCsv','split','STRING','addIndex\x20%s\x20%s\x20%s','agentTransferTimeout','removeColumn','users','info','tools_schedules','final','util','removeIndex\x20%s\x20%s','TEXT','addIndex','agentTransfer','then','analytics_report_fields','queryInterface','splitSizePdf','enqueue','mail_accounts','prototype','tail','viber','splitSizeXlsx','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','removeIndex','Added\x20column\x20%s\x20to\x20%s','migration','sequelize','settings','query\x20%s'];(function(_0x527ce3,_0x24d090){const _0x4209d4=function(_0x3064a4){while(--_0x3064a4){_0x527ce3['push'](_0x527ce3['shift']());}};_0x4209d4(++_0x24d090);}(a945_0x24d0,0xf1));const a945_0x4209=function(_0x527ce3,_0x24d090){_0x527ce3=_0x527ce3-0x0;let _0x4209d4=a945_0x24d0[_0x527ce3];return _0x4209d4;};const _0x52dda1=a945_0x4209;'use strict';const util=require(_0x52dda1('0x2b')),logger=require('../config/logger')(_0x52dda1('0xa')),Sequence=function(){};Sequence['prototype'][_0x52dda1('0x1')]=function(_0x3064a4){const _0x559e80=_0x52dda1;this['tail']=this[_0x559e80('0x4')]?this['tail'][_0x559e80('0x1e')](_0x3064a4):_0x3064a4();};const Migration=function(_0x199f39){const _0x492048=_0x52dda1;this['queryInterface']=_0x199f39,this[_0x492048('0x14')]=new Sequence();};Migration[_0x52dda1('0x3')][_0x52dda1('0x1f')]=function(_0x5e11e8,_0x4a0a78,_0x3e854b){const _0x4c9b7d=_0x52dda1,_0x1613f0=this;this[_0x4c9b7d('0x14')][_0x4c9b7d('0x1')](function(){const _0x115398=_0x4c9b7d;return _0x1613f0[_0x115398('0x32')]['changeColumn'](_0x5e11e8,_0x4a0a78,_0x3e854b)[_0x115398('0x30')](function(){const _0x4b43cb=_0x115398;logger['info'](_0x4b43cb('0xe'),_0x4a0a78,_0x5e11e8);})[_0x115398('0x20')](function(_0x4add52){const _0x207d0d=_0x115398;logger[_0x207d0d('0x28')](JSON['stringify'](_0x4add52));});});},Migration[_0x52dda1('0x3')]['addColumn']=function(_0x5c502b,_0x257f1c,_0x2ca0c3){const _0x3eeaef=_0x52dda1,_0x3a10b1=this;this['sequence'][_0x3eeaef('0x1')](function(){const _0x579a28=_0x3eeaef;return _0x3a10b1[_0x579a28('0x32')]['addColumn'](_0x5c502b,_0x257f1c,_0x2ca0c3)[_0x579a28('0x30')](function(){const _0x1542d6=_0x579a28;logger[_0x1542d6('0x28')](_0x1542d6('0x9'),_0x257f1c,_0x5c502b);})['catch'](function(_0x390397){const _0x5176d0=_0x579a28;logger[_0x5176d0('0x28')](JSON[_0x5176d0('0x16')](_0x390397));});});},Migration['prototype']['dropTable']=function(_0x3e448b){const _0x10d6c0=_0x52dda1,_0x37b7c7=this;this[_0x10d6c0('0x14')][_0x10d6c0('0x1')](function(){const _0x123573=_0x10d6c0;return _0x37b7c7[_0x123573('0x32')][_0x123573('0x11')](_0x3e448b,{'force':!![]})['then'](function(){const _0x48b62d=_0x123573;logger[_0x48b62d('0x28')](_0x48b62d('0x13'),_0x3e448b);})['catch'](function(_0x234468){const _0x441e7f=_0x123573;logger[_0x441e7f('0x28')](JSON[_0x441e7f('0x16')](_0x234468));});});},Migration['prototype'][_0x52dda1('0x2e')]=function(_0x8d204e,_0x3d99de,_0x2c075a){const _0x1c9fb0=_0x52dda1,_0x17b221=this;this[_0x1c9fb0('0x14')][_0x1c9fb0('0x1')](function(){const _0x226618=_0x1c9fb0;return _0x17b221[_0x226618('0x32')][_0x226618('0x2e')](_0x8d204e,_0x3d99de,{'indexName':_0x2c075a})[_0x226618('0x30')](function(){const _0x414ac0=_0x226618;logger[_0x414ac0('0x28')](_0x414ac0('0x24'),_0x8d204e,_0x3d99de[_0x414ac0('0x18')](','),_0x2c075a);})[_0x226618('0x20')](function(_0x5b15ad){const _0xc9d8de=_0x226618;logger[_0xc9d8de('0x28')](JSON[_0xc9d8de('0x16')](_0x5b15ad));});});},Migration[_0x52dda1('0x3')][_0x52dda1('0x8')]=function(_0x2aa0c0,_0x537e95){const _0x381722=_0x52dda1,_0x519b19=this;this['sequence'][_0x381722('0x1')](function(){const _0x58f8fc=_0x381722;return _0x519b19[_0x58f8fc('0x32')][_0x58f8fc('0x8')](_0x2aa0c0,_0x537e95)['then'](function(){const _0x1a175c=_0x58f8fc;logger[_0x1a175c('0x28')](_0x1a175c('0x2c'),_0x2aa0c0,_0x537e95);})[_0x58f8fc('0x20')](function(_0x29edf2){const _0x3e8308=_0x58f8fc;logger[_0x3e8308('0x28')](JSON[_0x3e8308('0x16')](_0x29edf2));});});},Migration[_0x52dda1('0x3')][_0x52dda1('0x19')]=function(_0x457cfe){const _0x50ecd4=_0x52dda1,_0x2bb69e=this;this[_0x50ecd4('0x14')][_0x50ecd4('0x1')](function(){const _0xfd35c9=_0x50ecd4;return _0x2bb69e[_0xfd35c9('0x32')][_0xfd35c9('0xb')][_0xfd35c9('0x19')](_0x457cfe)[_0xfd35c9('0x30')](function(){const _0x169e99=_0xfd35c9;logger['info'](_0x169e99('0xd'),_0x457cfe);})[_0xfd35c9('0x20')](function(_0x210be6){const _0x2137ac=_0xfd35c9;logger[_0x2137ac('0x28')](JSON[_0x2137ac('0x16')](_0x210be6));});});},Migration['prototype'][_0x52dda1('0x26')]=function(_0x5670ac,_0x239774){const _0x37f93f=_0x52dda1,_0xb33a63=this;this[_0x37f93f('0x14')]['enqueue'](function(){const _0x87f90a=_0x37f93f;return _0xb33a63[_0x87f90a('0x32')]['removeColumn'](_0x5670ac,_0x239774)[_0x87f90a('0x30')](function(){const _0x2bea88=_0x87f90a;logger[_0x2bea88('0x28')]('Removed\x20column\x20%s\x20from\x20%s',_0x239774,_0x5670ac);})[_0x87f90a('0x20')](function(_0x1f8af1){const _0x13bb40=_0x87f90a;logger[_0x13bb40('0x28')](util[_0x13bb40('0x1c')](_0x1f8af1,{'showHidden':![],'depth':null}));});});},Migration[_0x52dda1('0x3')][_0x52dda1('0xf')]=function(_0x39fe58,_0xeac10,_0x40a4f6){const _0x4907fc=_0x52dda1,_0x1500f5=this;this[_0x4907fc('0x14')][_0x4907fc('0x1')](function(){const _0x5501a6=_0x4907fc;return _0x1500f5[_0x5501a6('0x32')][_0x5501a6('0xf')](_0x39fe58,_0xeac10,_0x40a4f6)[_0x5501a6('0x30')](function(){const _0x343c0a=_0x5501a6;logger[_0x343c0a('0x28')](_0x343c0a('0x7'),_0xeac10,_0x40a4f6,_0x39fe58);})[_0x5501a6('0x20')](function(_0x598c6a){const _0x1a34ad=_0x5501a6;logger[_0x1a34ad('0x28')](util[_0x1a34ad('0x1c')](_0x598c6a,{'showHidden':![],'depth':null}));});});},Migration[_0x52dda1('0x3')][_0x52dda1('0x2a')]=function(_0x4cf193){const _0x36ca55=_0x52dda1;this[_0x36ca55('0x14')][_0x36ca55('0x1')](function(){return _0x4cf193();});},module['exports']={'up':function(_0x3e2ca7,_0x314949){return new Promise(function(_0x4ec137){const _0x3bddb0=a945_0x4209,_0x263f32=new Migration(_0x3e2ca7);_0x263f32[_0x3bddb0('0x1f')](_0x3bddb0('0x31'),'field',{'type':_0x314949[_0x3bddb0('0x2d')]}),_0x263f32['addColumn'](_0x3bddb0('0x29'),'cc',{'type':_0x314949[_0x3bddb0('0x2d')]}),_0x263f32[_0x3bddb0('0x12')]('tools_schedules','bcc',{'type':_0x314949['TEXT']}),_0x263f32[_0x3bddb0('0x12')](_0x3bddb0('0xc'),_0x3bddb0('0x22'),{'type':_0x314949[_0x3bddb0('0x1a')],'defaultValue':!![]}),_0x263f32['addColumn'](_0x3bddb0('0xc'),_0x3bddb0('0x21'),{'type':_0x314949[_0x3bddb0('0x15')],'defaultValue':0x1388}),_0x263f32[_0x3bddb0('0x12')](_0x3bddb0('0xc'),_0x3bddb0('0x0'),{'type':_0x314949[_0x3bddb0('0x15')],'defaultValue':0x3e8}),_0x263f32[_0x3bddb0('0x12')](_0x3bddb0('0xc'),_0x3bddb0('0x6'),{'type':_0x314949[_0x3bddb0('0x15')],'defaultValue':0x1388}),_0x263f32[_0x3bddb0('0x12')](_0x3bddb0('0x2'),_0x3bddb0('0x1b'),{'type':_0x314949[_0x3bddb0('0x1a')],'defaultValue':![]}),_0x263f32[_0x3bddb0('0x12')]('mail_accounts','queueTransferTimeout',{'type':_0x314949[_0x3bddb0('0x15')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x263f32[_0x3bddb0('0x12')](_0x3bddb0('0x2'),_0x3bddb0('0x2f'),{'type':_0x314949[_0x3bddb0('0x1a')],'defaultValue':![]}),_0x263f32[_0x3bddb0('0x12')](_0x3bddb0('0x2'),_0x3bddb0('0x25'),{'type':_0x314949[_0x3bddb0('0x15')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x263f32[_0x3bddb0('0x12')](_0x3bddb0('0x27'),'phoneBarPrefixRequired',{'type':_0x314949[_0x3bddb0('0x1a')],'defaultValue':![]}),_0x263f32['changeColumn']('mail_interactions','subject',{'type':_0x314949[_0x3bddb0('0x2d')]('')+_0x3bddb0('0x17')}),_0x263f32[_0x3bddb0('0x1f')](_0x3bddb0('0x1d'),_0x3bddb0('0x10'),{'type':_0x314949[_0x3bddb0('0x2d')]('long')+_0x3bddb0('0x17')}),_0x263f32[_0x3bddb0('0x12')]('cm_contacts',_0x3bddb0('0x5'),{'type':_0x314949[_0x3bddb0('0x23')]}),_0x263f32[_0x3bddb0('0x2a')](_0x4ec137);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.67.js b/server/migrations/2.0.67.js index 58ab8db..25a3b96 100644 --- a/server/migrations/2.0.67.js +++ b/server/migrations/2.0.67.js @@ -1 +1 @@ -const a946_0x4b1c=['stringify','final','long','sequelize','CREATE\x20TABLE\x20`tools_dispositions`\x20(\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20`name`\x20varchar(255)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`MailAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`FaxAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`SmsAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`OpenchannelAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`ChatWebsiteId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`ListId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_voice`\x20(`name`,`ListId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_chat`\x20(`name`,`ChatWebsiteId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_mail`\x20(`name`,`MailAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_sms`\x20(`name`,`SmsAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_fax`\x20(`name`,`FaxAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_openchannel`\x20(`name`,`OpenchannelAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailAccountId`\x20(`MailAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`FaxAccountId`\x20(`FaxAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`SmsAccountId`\x20(`SmsAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`OpenchannelAccountId`\x20(`OpenchannelAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`ChatWebsiteId`\x20(`ChatWebsiteId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`ListId`\x20(`ListId`),\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_1`\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20REFERENCES\x20`mail_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_2`\x20FOREIGN\x20KEY\x20(`FaxAccountId`)\x20REFERENCES\x20`fax_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_3`\x20FOREIGN\x20KEY\x20(`SmsAccountId`)\x20REFERENCES\x20`sms_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_4`\x20FOREIGN\x20KEY\x20(`OpenchannelAccountId`)\x20REFERENCES\x20`openchannel_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_5`\x20FOREIGN\x20KEY\x20(`ChatWebsiteId`)\x20REFERENCES\x20`chat_websites`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_6`\x20FOREIGN\x20KEY\x20(`ListId`)\x20REFERENCES\x20`cm_lists`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','../config/logger','originCc','removeColumn','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`ChatWebsiteId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`ChatWebsiteId`\x20FROM\x20chat_dispositions;','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','prototype','then','Added\x20column\x20%s\x20to\x20%s','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`SmsAccountId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`SmsAccountId`\x20FROM\x20sms_dispositions;','Removed\x20column\x20%s\x20from\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','catch','changeColumn','CREATE\x20TABLE\x20`user_has_openchannel_accounts`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`OpenchannelAccountId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`OpenchannelAccountId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_openchannel_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`OpenchannelAccountId`)\x20REFERENCES\x20`openchannel_accounts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_openchannel_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','join','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`ListId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`ListId`\x20FROM\x20voice_dispositions;','renameColumn','INSERT\x20INTO\x20user_has_sms_accounts\x20(`UserId`,\x20`SmsAccountId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`SmsAccountId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20sms_accounts\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;','addIndex\x20%s\x20%s\x20%s','inspect','sequence','query\x20%s','CREATE\x20TABLE\x20`user_has_sms_accounts`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`SmsAccountId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`SmsAccountId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_sms_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`SmsAccountId`)\x20REFERENCES\x20`sms_accounts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_sms_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','info','CREATE\x20TABLE\x20`user_has_chat_websites`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`ChatWebsiteId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`ChatWebsiteId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_chat_websites_ibfk_1`\x20FOREIGN\x20KEY\x20(`ChatWebsiteId`)\x20REFERENCES\x20`chat_websites`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_chat_websites_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','table\x20dropped\x20%s','queryInterface','enqueue','tail','INSERT\x20INTO\x20user_has_mail_accounts\x20(`UserId`,\x20`MailAccountId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`MailAccountId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20mail_accounts\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`MailAccountId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`MailAccountId`\x20FROM\x20mail_dispositions;','INSERT\x20INTO\x20user_has_openchannel_accounts\x20(`UserId`,\x20`OpenchannelAccountId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`OpenchannelAccountId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20openchannel_accounts\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;','addColumn','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`OpenchannelAccountId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`OpenchannelAccountId`\x20FROM\x20openchannel_dispositions;','CREATE\x20TABLE\x20`user_has_fax_accounts`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`FaxAccountId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`FaxAccountId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_fax_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`FaxAccountId`)\x20REFERENCES\x20`fax_accounts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_fax_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','TEXT','addIndex','removeIndex\x20%s\x20%s','query','dropTable','removeIndex','CREATE\x20TABLE\x20`user_has_mail_accounts`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`MailAccountId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`MailAccountId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_mail_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20REFERENCES\x20`mail_accounts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_mail_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','util'];(function(_0x124186,_0x4b1c36){const _0xbfb02c=function(_0x22c5cd){while(--_0x22c5cd){_0x124186['push'](_0x124186['shift']());}};_0xbfb02c(++_0x4b1c36);}(a946_0x4b1c,0xd6));const a946_0xbfb0=function(_0x124186,_0x4b1c36){_0x124186=_0x124186-0x0;let _0xbfb02c=a946_0x4b1c[_0x124186];return _0xbfb02c;};const _0x454057=a946_0xbfb0;'use strict';const util=require(_0x454057('0x19')),logger=require(_0x454057('0x1f'))('migration'),Sequence=function(){};Sequence['prototype'][_0x454057('0xa')]=function(_0x22c5cd){const _0xe4790e=_0x454057;this['tail']=this[_0xe4790e('0xb')]?this['tail']['finally'](_0x22c5cd):_0x22c5cd();};const Migration=function(_0x251f63){const _0x305f85=_0x454057;this[_0x305f85('0x9')]=_0x251f63,this['sequence']=new Sequence();};Migration[_0x454057('0x24')][_0x454057('0x2b')]=function(_0x282813,_0x4f9ea3,_0x10e837){const _0x4da6f1=_0x454057,_0x54b6e5=this;this[_0x4da6f1('0x3')][_0x4da6f1('0xa')](function(){const _0x28cf38=_0x4da6f1;return _0x54b6e5[_0x28cf38('0x9')][_0x28cf38('0x2b')](_0x282813,_0x4f9ea3,_0x10e837)['then'](function(){const _0x192038=_0x28cf38;logger[_0x192038('0x6')](_0x192038('0x29'),_0x4f9ea3,_0x282813);})[_0x28cf38('0x2a')](function(_0x23cd1d){const _0x482f5e=_0x28cf38;logger[_0x482f5e('0x6')](JSON['stringify'](_0x23cd1d));});});},Migration[_0x454057('0x24')][_0x454057('0xf')]=function(_0x2dd8b9,_0xeaaa92,_0x67f75f){const _0x531db4=_0x454057,_0x47af85=this;this['sequence'][_0x531db4('0xa')](function(){const _0x3abd48=_0x531db4;return _0x47af85[_0x3abd48('0x9')][_0x3abd48('0xf')](_0x2dd8b9,_0xeaaa92,_0x67f75f)[_0x3abd48('0x25')](function(){const _0x315b46=_0x3abd48;logger[_0x315b46('0x6')](_0x315b46('0x26'),_0xeaaa92,_0x2dd8b9);})[_0x3abd48('0x2a')](function(_0x349530){logger['info'](JSON['stringify'](_0x349530));});});},Migration[_0x454057('0x24')][_0x454057('0x16')]=function(_0x471280){const _0x42a0e0=_0x454057,_0x462846=this;this[_0x42a0e0('0x3')]['enqueue'](function(){const _0x26d8b3=_0x42a0e0;return _0x462846[_0x26d8b3('0x9')][_0x26d8b3('0x16')](_0x471280,{'force':!![]})[_0x26d8b3('0x25')](function(){const _0xeaec2=_0x26d8b3;logger[_0xeaec2('0x6')](_0xeaec2('0x8'),_0x471280);})['catch'](function(_0x1daea6){const _0x35d354=_0x26d8b3;logger[_0x35d354('0x6')](JSON[_0x35d354('0x1a')](_0x1daea6));});});},Migration[_0x454057('0x24')][_0x454057('0x13')]=function(_0x5dc018,_0x3fa7ac,_0x2a68a4){const _0xd9957e=_0x454057,_0x4c80c4=this;this[_0xd9957e('0x3')][_0xd9957e('0xa')](function(){const _0x458d39=_0xd9957e;return _0x4c80c4['queryInterface']['addIndex'](_0x5dc018,_0x3fa7ac,{'indexName':_0x2a68a4})[_0x458d39('0x25')](function(){const _0x54fadc=_0x458d39;logger[_0x54fadc('0x6')](_0x54fadc('0x1'),_0x5dc018,_0x3fa7ac[_0x54fadc('0x2d')](','),_0x2a68a4);})[_0x458d39('0x2a')](function(_0x426135){const _0x1d6c80=_0x458d39;logger[_0x1d6c80('0x6')](JSON['stringify'](_0x426135));});});},Migration['prototype'][_0x454057('0x17')]=function(_0x317932,_0x1a1f77){const _0x12d706=_0x454057,_0x597a66=this;this[_0x12d706('0x3')][_0x12d706('0xa')](function(){const _0x3d30d8=_0x12d706;return _0x597a66[_0x3d30d8('0x9')][_0x3d30d8('0x17')](_0x317932,_0x1a1f77)[_0x3d30d8('0x25')](function(){const _0x3942de=_0x3d30d8;logger[_0x3942de('0x6')](_0x3942de('0x14'),_0x317932,_0x1a1f77);})['catch'](function(_0x5c57fc){const _0x16315e=_0x3d30d8;logger['info'](JSON[_0x16315e('0x1a')](_0x5c57fc));});});},Migration[_0x454057('0x24')][_0x454057('0x15')]=function(_0x3b54ef){const _0x3058ff=_0x454057,_0x498220=this;this[_0x3058ff('0x3')][_0x3058ff('0xa')](function(){const _0x58f004=_0x3058ff;return _0x498220[_0x58f004('0x9')][_0x58f004('0x1d')][_0x58f004('0x15')](_0x3b54ef)['then'](function(){const _0x10aed6=_0x58f004;logger[_0x10aed6('0x6')](_0x10aed6('0x4'),_0x3b54ef);})[_0x58f004('0x2a')](function(_0x65f780){const _0x5225ea=_0x58f004;logger[_0x5225ea('0x6')](JSON[_0x5225ea('0x1a')](_0x65f780));});});},Migration['prototype']['removeColumn']=function(_0x1c3eb9,_0x3c40ac){const _0x4e061f=_0x454057,_0x5342f3=this;this[_0x4e061f('0x3')][_0x4e061f('0xa')](function(){const _0x176666=_0x4e061f;return _0x5342f3[_0x176666('0x9')][_0x176666('0x21')](_0x1c3eb9,_0x3c40ac)['then'](function(){const _0x3d8086=_0x176666;logger[_0x3d8086('0x6')](_0x3d8086('0x28'),_0x3c40ac,_0x1c3eb9);})[_0x176666('0x2a')](function(_0xd47ac0){const _0x5adfa3=_0x176666;logger[_0x5adfa3('0x6')](util[_0x5adfa3('0x2')](_0xd47ac0,{'showHidden':![],'depth':null}));});});},Migration[_0x454057('0x24')]['renameColumn']=function(_0x3bc442,_0x19a403,_0x385d32){const _0x505f89=_0x454057,_0xa01721=this;this[_0x505f89('0x3')][_0x505f89('0xa')](function(){const _0x30da3c=_0x505f89;return _0xa01721[_0x30da3c('0x9')][_0x30da3c('0x2f')](_0x3bc442,_0x19a403,_0x385d32)[_0x30da3c('0x25')](function(){const _0x205b8d=_0x30da3c;logger['info'](_0x205b8d('0x23'),_0x19a403,_0x385d32,_0x3bc442);})[_0x30da3c('0x2a')](function(_0x48f126){const _0x3763e7=_0x30da3c;logger[_0x3763e7('0x6')](util['inspect'](_0x48f126,{'showHidden':![],'depth':null}));});});},Migration[_0x454057('0x24')][_0x454057('0x1b')]=function(_0x1d7d51){const _0x424918=_0x454057;this[_0x424918('0x3')][_0x424918('0xa')](function(){return _0x1d7d51();});},module['exports']={'up':function(_0x1c8aef,_0x3c0034){return new Promise(function(_0x22fe79){const _0x5c2f6b=a946_0xbfb0,_0x26e3fc=new Migration(_0x1c8aef),_0x219ccd=_0x5c2f6b('0x1e');_0x26e3fc[_0x5c2f6b('0x15')](_0x219ccd),_0x26e3fc[_0x5c2f6b('0x15')](_0x5c2f6b('0x22')),_0x26e3fc['query'](_0x5c2f6b('0xd')),_0x26e3fc[_0x5c2f6b('0x15')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`FaxAccountId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`FaxAccountId`\x20FROM\x20fax_dispositions;'),_0x26e3fc['query'](_0x5c2f6b('0x27')),_0x26e3fc[_0x5c2f6b('0x15')](_0x5c2f6b('0x10')),_0x26e3fc[_0x5c2f6b('0x15')](_0x5c2f6b('0x2e')),_0x26e3fc['query'](_0x5c2f6b('0x7')),_0x26e3fc[_0x5c2f6b('0x15')]('INSERT\x20INTO\x20user_has_chat_websites\x20(`UserId`,\x20`ChatWebsiteId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`ChatWebsiteId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20chat_websites\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;'),_0x26e3fc[_0x5c2f6b('0x15')](_0x5c2f6b('0x18')),_0x26e3fc['query'](_0x5c2f6b('0xc')),_0x26e3fc[_0x5c2f6b('0x15')](_0x5c2f6b('0x11')),_0x26e3fc[_0x5c2f6b('0x15')]('INSERT\x20INTO\x20user_has_fax_accounts\x20(`UserId`,\x20`FaxAccountId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`FaxAccountId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20fax_accounts\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;'),_0x26e3fc[_0x5c2f6b('0x15')](_0x5c2f6b('0x5')),_0x26e3fc['query'](_0x5c2f6b('0x0')),_0x26e3fc[_0x5c2f6b('0x15')](_0x5c2f6b('0x2c')),_0x26e3fc[_0x5c2f6b('0x15')](_0x5c2f6b('0xe')),_0x26e3fc[_0x5c2f6b('0xf')]('mail_messages','originTo',{'type':_0x3c0034[_0x5c2f6b('0x12')](_0x5c2f6b('0x1c'))}),_0x26e3fc[_0x5c2f6b('0xf')]('mail_messages',_0x5c2f6b('0x20'),{'type':_0x3c0034[_0x5c2f6b('0x12')](_0x5c2f6b('0x1c'))}),_0x26e3fc[_0x5c2f6b('0x1b')](_0x22fe79);});},'down':function(){}}; \ No newline at end of file +const a946_0x256d=['INSERT\x20INTO\x20user_has_sms_accounts\x20(`UserId`,\x20`SmsAccountId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`SmsAccountId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20sms_accounts\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','changeColumn','removeIndex\x20%s\x20%s','removeIndex','CREATE\x20TABLE\x20`user_has_chat_websites`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`ChatWebsiteId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`ChatWebsiteId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_chat_websites_ibfk_1`\x20FOREIGN\x20KEY\x20(`ChatWebsiteId`)\x20REFERENCES\x20`chat_websites`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_chat_websites_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','Removed\x20column\x20%s\x20from\x20%s','INSERT\x20INTO\x20user_has_openchannel_accounts\x20(`UserId`,\x20`OpenchannelAccountId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`OpenchannelAccountId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20openchannel_accounts\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;','INSERT\x20INTO\x20user_has_fax_accounts\x20(`UserId`,\x20`FaxAccountId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`FaxAccountId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20fax_accounts\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;','sequence','CREATE\x20TABLE\x20`user_has_mail_accounts`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`MailAccountId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`MailAccountId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_mail_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20REFERENCES\x20`mail_accounts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_mail_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','originCc','prototype','INSERT\x20INTO\x20user_has_mail_accounts\x20(`UserId`,\x20`MailAccountId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`MailAccountId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20mail_accounts\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`ChatWebsiteId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`ChatWebsiteId`\x20FROM\x20chat_dispositions;','addIndex','CREATE\x20TABLE\x20`user_has_sms_accounts`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`SmsAccountId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`SmsAccountId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_sms_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`SmsAccountId`)\x20REFERENCES\x20`sms_accounts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_sms_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','Changed\x20column\x20%s\x20in\x20table\x20%s','addColumn','queryInterface','info','removeColumn','query','CREATE\x20TABLE\x20`user_has_openchannel_accounts`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`OpenchannelAccountId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`OpenchannelAccountId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_openchannel_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`OpenchannelAccountId`)\x20REFERENCES\x20`openchannel_accounts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_openchannel_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','join','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`SmsAccountId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`SmsAccountId`\x20FROM\x20sms_dispositions;','Added\x20column\x20%s\x20to\x20%s','util','exports','long','../config/logger','then','final','sequelize','enqueue','migration','table\x20dropped\x20%s','renameColumn','catch','dropTable','TEXT','tail','stringify','finally','query\x20%s','mail_messages'];(function(_0x311a13,_0x256d09){const _0x546d5f=function(_0x57a08b){while(--_0x57a08b){_0x311a13['push'](_0x311a13['shift']());}};_0x546d5f(++_0x256d09);}(a946_0x256d,0xc5));const a946_0x546d=function(_0x311a13,_0x256d09){_0x311a13=_0x311a13-0x0;let _0x546d5f=a946_0x256d[_0x311a13];return _0x546d5f;};const _0x29bffd=a946_0x546d;'use strict';const util=require(_0x29bffd('0xe')),logger=require(_0x29bffd('0x11'))(_0x29bffd('0x16')),Sequence=function(){};Sequence[_0x29bffd('0x2d')]['enqueue']=function(_0x57a08b){const _0x573cce=_0x29bffd;this['tail']=this[_0x573cce('0x1c')]?this['tail'][_0x573cce('0x1e')](_0x57a08b):_0x57a08b();};const Migration=function(_0x33b9ca){const _0x557116=_0x29bffd;this[_0x557116('0x6')]=_0x33b9ca,this[_0x557116('0x2a')]=new Sequence();};Migration[_0x29bffd('0x2d')][_0x29bffd('0x23')]=function(_0x4e5a43,_0x4cf780,_0x67221){const _0x22631f=_0x29bffd,_0x72a871=this;this[_0x22631f('0x2a')]['enqueue'](function(){const _0x5762c3=_0x22631f;return _0x72a871[_0x5762c3('0x6')]['changeColumn'](_0x4e5a43,_0x4cf780,_0x67221)['then'](function(){const _0x12db99=_0x5762c3;logger[_0x12db99('0x7')](_0x12db99('0x4'),_0x4cf780,_0x4e5a43);})[_0x5762c3('0x19')](function(_0x2c9b5a){const _0x2b5d23=_0x5762c3;logger[_0x2b5d23('0x7')](JSON[_0x2b5d23('0x1d')](_0x2c9b5a));});});},Migration[_0x29bffd('0x2d')]['addColumn']=function(_0x4df652,_0x511a8c,_0x4d86c7){const _0x3e508c=_0x29bffd,_0xc77459=this;this[_0x3e508c('0x2a')][_0x3e508c('0x15')](function(){const _0x5b9a19=_0x3e508c;return _0xc77459[_0x5b9a19('0x6')]['addColumn'](_0x4df652,_0x511a8c,_0x4d86c7)[_0x5b9a19('0x12')](function(){const _0x5dc3e9=_0x5b9a19;logger[_0x5dc3e9('0x7')](_0x5dc3e9('0xd'),_0x511a8c,_0x4df652);})[_0x5b9a19('0x19')](function(_0x4bc628){const _0x1c2fca=_0x5b9a19;logger[_0x1c2fca('0x7')](JSON[_0x1c2fca('0x1d')](_0x4bc628));});});},Migration[_0x29bffd('0x2d')][_0x29bffd('0x1a')]=function(_0x2e879b){const _0x58263e=_0x29bffd,_0x1053d0=this;this['sequence'][_0x58263e('0x15')](function(){const _0x3e5c2a=_0x58263e;return _0x1053d0['queryInterface'][_0x3e5c2a('0x1a')](_0x2e879b,{'force':!![]})[_0x3e5c2a('0x12')](function(){const _0x3c1e79=_0x3e5c2a;logger[_0x3c1e79('0x7')](_0x3c1e79('0x17'),_0x2e879b);})[_0x3e5c2a('0x19')](function(_0x3e2d08){const _0x43666a=_0x3e5c2a;logger[_0x43666a('0x7')](JSON['stringify'](_0x3e2d08));});});},Migration['prototype'][_0x29bffd('0x2')]=function(_0x536703,_0x2b5335,_0x73d62d){const _0x3b12e0=_0x29bffd,_0x8da1d2=this;this[_0x3b12e0('0x2a')][_0x3b12e0('0x15')](function(){const _0x284eeb=_0x3b12e0;return _0x8da1d2['queryInterface'][_0x284eeb('0x2')](_0x536703,_0x2b5335,{'indexName':_0x73d62d})['then'](function(){const _0x3a6a6b=_0x284eeb;logger[_0x3a6a6b('0x7')]('addIndex\x20%s\x20%s\x20%s',_0x536703,_0x2b5335[_0x3a6a6b('0xb')](','),_0x73d62d);})['catch'](function(_0x274dcb){const _0x45cc71=_0x284eeb;logger[_0x45cc71('0x7')](JSON[_0x45cc71('0x1d')](_0x274dcb));});});},Migration[_0x29bffd('0x2d')][_0x29bffd('0x25')]=function(_0xabdf5b,_0x4c3a94){const _0x16e324=_0x29bffd,_0x2192e7=this;this['sequence'][_0x16e324('0x15')](function(){const _0x4087d4=_0x16e324;return _0x2192e7[_0x4087d4('0x6')][_0x4087d4('0x25')](_0xabdf5b,_0x4c3a94)[_0x4087d4('0x12')](function(){const _0x2e7f43=_0x4087d4;logger['info'](_0x2e7f43('0x24'),_0xabdf5b,_0x4c3a94);})[_0x4087d4('0x19')](function(_0x5caf52){logger['info'](JSON['stringify'](_0x5caf52));});});},Migration['prototype']['query']=function(_0x30529c){const _0x43f2a2=_0x29bffd,_0x1b382f=this;this[_0x43f2a2('0x2a')][_0x43f2a2('0x15')](function(){const _0xb75ad6=_0x43f2a2;return _0x1b382f[_0xb75ad6('0x6')][_0xb75ad6('0x14')][_0xb75ad6('0x9')](_0x30529c)[_0xb75ad6('0x12')](function(){const _0x385628=_0xb75ad6;logger['info'](_0x385628('0x1f'),_0x30529c);})[_0xb75ad6('0x19')](function(_0x207780){const _0x20e610=_0xb75ad6;logger[_0x20e610('0x7')](JSON[_0x20e610('0x1d')](_0x207780));});});},Migration['prototype'][_0x29bffd('0x8')]=function(_0x1da8a9,_0x44a77c){const _0x465682=_0x29bffd,_0x43d145=this;this[_0x465682('0x2a')]['enqueue'](function(){const _0x4863b0=_0x465682;return _0x43d145[_0x4863b0('0x6')][_0x4863b0('0x8')](_0x1da8a9,_0x44a77c)[_0x4863b0('0x12')](function(){const _0x4c7f63=_0x4863b0;logger['info'](_0x4c7f63('0x27'),_0x44a77c,_0x1da8a9);})['catch'](function(_0x6f12b4){logger['info'](util['inspect'](_0x6f12b4,{'showHidden':![],'depth':null}));});});},Migration[_0x29bffd('0x2d')][_0x29bffd('0x18')]=function(_0x236907,_0x5137c2,_0x3a15a2){const _0x14c1b2=_0x29bffd,_0x599793=this;this['sequence'][_0x14c1b2('0x15')](function(){const _0x30c4fe=_0x14c1b2;return _0x599793[_0x30c4fe('0x6')][_0x30c4fe('0x18')](_0x236907,_0x5137c2,_0x3a15a2)['then'](function(){const _0x4c91a5=_0x30c4fe;logger[_0x4c91a5('0x7')](_0x4c91a5('0x22'),_0x5137c2,_0x3a15a2,_0x236907);})[_0x30c4fe('0x19')](function(_0x324ba5){const _0x3e5e85=_0x30c4fe;logger[_0x3e5e85('0x7')](util['inspect'](_0x324ba5,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x30c36d){const _0x29864e=_0x29bffd;this[_0x29864e('0x2a')][_0x29864e('0x15')](function(){return _0x30c36d();});},module[_0x29bffd('0xf')]={'up':function(_0x298dd7,_0xb48b6e){return new Promise(function(_0x378986){const _0x1c53c9=a946_0x546d,_0x4cb049=new Migration(_0x298dd7),_0x27a98d='CREATE\x20TABLE\x20`tools_dispositions`\x20(\x20\x20\x20\x20\x20\x20\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,\x20\x20\x20\x20\x20\x20\x20\x20`name`\x20varchar(255)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`MailAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`FaxAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`SmsAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`OpenchannelAccountId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`ChatWebsiteId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20`ListId`\x20int(11)\x20DEFAULT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`id`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_voice`\x20(`name`,`ListId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_chat`\x20(`name`,`ChatWebsiteId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_mail`\x20(`name`,`MailAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_sms`\x20(`name`,`SmsAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_fax`\x20(`name`,`FaxAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20UNIQUE\x20KEY\x20`name_openchannel`\x20(`name`,`OpenchannelAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`MailAccountId`\x20(`MailAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`FaxAccountId`\x20(`FaxAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`SmsAccountId`\x20(`SmsAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`OpenchannelAccountId`\x20(`OpenchannelAccountId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`ChatWebsiteId`\x20(`ChatWebsiteId`),\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`ListId`\x20(`ListId`),\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_1`\x20FOREIGN\x20KEY\x20(`MailAccountId`)\x20REFERENCES\x20`mail_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_2`\x20FOREIGN\x20KEY\x20(`FaxAccountId`)\x20REFERENCES\x20`fax_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_3`\x20FOREIGN\x20KEY\x20(`SmsAccountId`)\x20REFERENCES\x20`sms_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_4`\x20FOREIGN\x20KEY\x20(`OpenchannelAccountId`)\x20REFERENCES\x20`openchannel_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_5`\x20FOREIGN\x20KEY\x20(`ChatWebsiteId`)\x20REFERENCES\x20`chat_websites`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`tools_dispositions_ibfk_6`\x20FOREIGN\x20KEY\x20(`ListId`)\x20REFERENCES\x20`cm_lists`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;';_0x4cb049['query'](_0x27a98d),_0x4cb049['query'](_0x1c53c9('0x1')),_0x4cb049['query']('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`MailAccountId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`MailAccountId`\x20FROM\x20mail_dispositions;'),_0x4cb049[_0x1c53c9('0x9')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`FaxAccountId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`FaxAccountId`\x20FROM\x20fax_dispositions;'),_0x4cb049[_0x1c53c9('0x9')](_0x1c53c9('0xc')),_0x4cb049[_0x1c53c9('0x9')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`OpenchannelAccountId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`OpenchannelAccountId`\x20FROM\x20openchannel_dispositions;'),_0x4cb049[_0x1c53c9('0x9')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`,\x20`ListId`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20`name`,\x20`createdAt`,\x20`updatedAt`,\x20`ListId`\x20FROM\x20voice_dispositions;'),_0x4cb049['query'](_0x1c53c9('0x26')),_0x4cb049[_0x1c53c9('0x9')]('INSERT\x20INTO\x20user_has_chat_websites\x20(`UserId`,\x20`ChatWebsiteId`,\x20`createdAt`,\x20`updatedAt`)\x20\x20\x20\x20\x20\x20\x20SELECT\x20u.id\x20as\x20`UserId`,\x20a.id\x20as\x20`ChatWebsiteId`,\x20NOW()\x20as\x20`createdAt`,\x20NOW()\x20as\x20`updatedAt`\x20\x20\x20\x20\x20\x20\x20FROM\x20users\x20as\x20u,\x20chat_websites\x20as\x20a\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20u.id,\x20a.id;'),_0x4cb049[_0x1c53c9('0x9')](_0x1c53c9('0x2b')),_0x4cb049['query'](_0x1c53c9('0x0')),_0x4cb049[_0x1c53c9('0x9')]('CREATE\x20TABLE\x20`user_has_fax_accounts`\x20(\x20\x20\x20\x20\x20\x20\x20\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`FaxAccountId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20`UserId`\x20int(11)\x20NOT\x20NULL,\x20\x20\x20\x20\x20\x20\x20\x20\x20PRIMARY\x20KEY\x20(`FaxAccountId`,`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20KEY\x20`UserId`\x20(`UserId`),\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_fax_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`FaxAccountId`)\x20REFERENCES\x20`fax_accounts`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE,\x20\x20\x20\x20\x20\x20\x20\x20\x20CONSTRAINT\x20`user_has_fax_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`UserId`)\x20REFERENCES\x20`users`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20)\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;'),_0x4cb049[_0x1c53c9('0x9')](_0x1c53c9('0x29')),_0x4cb049[_0x1c53c9('0x9')](_0x1c53c9('0x3')),_0x4cb049[_0x1c53c9('0x9')](_0x1c53c9('0x21')),_0x4cb049[_0x1c53c9('0x9')](_0x1c53c9('0xa')),_0x4cb049[_0x1c53c9('0x9')](_0x1c53c9('0x28')),_0x4cb049[_0x1c53c9('0x5')](_0x1c53c9('0x20'),'originTo',{'type':_0xb48b6e[_0x1c53c9('0x1b')](_0x1c53c9('0x10'))}),_0x4cb049[_0x1c53c9('0x5')]('mail_messages',_0x1c53c9('0x2c'),{'type':_0xb48b6e[_0x1c53c9('0x1b')](_0x1c53c9('0x10'))}),_0x4cb049[_0x1c53c9('0x13')](_0x378986);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.68.js b/server/migrations/2.0.68.js index 0b15a91..a3e5758 100644 --- a/server/migrations/2.0.68.js +++ b/server/migrations/2.0.68.js @@ -1 +1 @@ -const a947_0x5abf=['join','queryInterface','then','Changed\x20column\x20%s\x20in\x20table\x20%s','removeColumn','final','query\x20%s','dropTable','addIndex\x20%s\x20%s\x20%s','STRING','table\x20dropped\x20%s','addColumn','sequence','Added\x20column\x20%s\x20to\x20%s','removeIndex','UPDATE\x20settings\x20SET\x20messagesAlignment=\x27alternate\x27','prototype','tail','finally','changeColumn','catch','inspect','../config/logger','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Not\x20Interested\x27,\x20NOW(),\x20NOW())','renameColumn','enqueue','messagesAlignment','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Interested\x27,\x20NOW(),\x20NOW())','Removed\x20column\x20%s\x20from\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex','chat_interactions','query','stringify','info','mapKey'];(function(_0x7ff1c2,_0x5abf21){const _0x1f080d=function(_0x4bddd1){while(--_0x4bddd1){_0x7ff1c2['push'](_0x7ff1c2['shift']());}};_0x1f080d(++_0x5abf21);}(a947_0x5abf,0x65));const a947_0x1f08=function(_0x7ff1c2,_0x5abf21){_0x7ff1c2=_0x7ff1c2-0x0;let _0x1f080d=a947_0x5abf[_0x7ff1c2];return _0x1f080d;};const _0xcbd58f=a947_0x1f08;'use strict';const util=require('util'),logger=require(_0xcbd58f('0x1d'))('migration'),Sequence=function(){};Sequence[_0xcbd58f('0x17')]['enqueue']=function(_0x4bddd1){const _0x1766ce=_0xcbd58f;this['tail']=this[_0x1766ce('0x18')]?this[_0x1766ce('0x18')][_0x1766ce('0x19')](_0x4bddd1):_0x4bddd1();};const Migration=function(_0x4aab74){const _0x4ce9df=_0xcbd58f;this[_0x4ce9df('0x8')]=_0x4aab74,this[_0x4ce9df('0x13')]=new Sequence();};Migration[_0xcbd58f('0x17')]['changeColumn']=function(_0x3c9ae,_0x459f07,_0x277476){const _0x264aca=_0xcbd58f,_0x4ba09e=this;this[_0x264aca('0x13')][_0x264aca('0x20')](function(){const _0x1dd578=_0x264aca;return _0x4ba09e['queryInterface'][_0x1dd578('0x1a')](_0x3c9ae,_0x459f07,_0x277476)[_0x1dd578('0x9')](function(){const _0x13291f=_0x1dd578;logger[_0x13291f('0x5')](_0x13291f('0xa'),_0x459f07,_0x3c9ae);})[_0x1dd578('0x1b')](function(_0x4fe573){const _0x47ce3d=_0x1dd578;logger[_0x47ce3d('0x5')](JSON[_0x47ce3d('0x4')](_0x4fe573));});});},Migration[_0xcbd58f('0x17')][_0xcbd58f('0x12')]=function(_0x30003e,_0x4de1ef,_0x50b461){const _0x29491f=_0xcbd58f,_0xebfc30=this;this[_0x29491f('0x13')][_0x29491f('0x20')](function(){const _0x218cdd=_0x29491f;return _0xebfc30[_0x218cdd('0x8')][_0x218cdd('0x12')](_0x30003e,_0x4de1ef,_0x50b461)[_0x218cdd('0x9')](function(){const _0x2de3c7=_0x218cdd;logger[_0x2de3c7('0x5')](_0x2de3c7('0x14'),_0x4de1ef,_0x30003e);})['catch'](function(_0x37e892){const _0x49dd5f=_0x218cdd;logger[_0x49dd5f('0x5')](JSON[_0x49dd5f('0x4')](_0x37e892));});});},Migration['prototype'][_0xcbd58f('0xe')]=function(_0xb9d9d7){const _0x2d4922=_0xcbd58f,_0xb4984d=this;this[_0x2d4922('0x13')][_0x2d4922('0x20')](function(){const _0x86aa0c=_0x2d4922;return _0xb4984d[_0x86aa0c('0x8')]['dropTable'](_0xb9d9d7,{'force':!![]})[_0x86aa0c('0x9')](function(){const _0x958b14=_0x86aa0c;logger[_0x958b14('0x5')](_0x958b14('0x11'),_0xb9d9d7);})[_0x86aa0c('0x1b')](function(_0x28f80d){const _0x51317b=_0x86aa0c;logger['info'](JSON[_0x51317b('0x4')](_0x28f80d));});});},Migration[_0xcbd58f('0x17')][_0xcbd58f('0x1')]=function(_0x52eb55,_0x8c1a91,_0x79f00b){const _0x13dfd5=_0xcbd58f,_0x6d794a=this;this['sequence'][_0x13dfd5('0x20')](function(){const _0x40027d=_0x13dfd5;return _0x6d794a['queryInterface'][_0x40027d('0x1')](_0x52eb55,_0x8c1a91,{'indexName':_0x79f00b})[_0x40027d('0x9')](function(){const _0x5347ff=_0x40027d;logger[_0x5347ff('0x5')](_0x5347ff('0xf'),_0x52eb55,_0x8c1a91[_0x5347ff('0x7')](','),_0x79f00b);})[_0x40027d('0x1b')](function(_0x3b5512){const _0x36e0ad=_0x40027d;logger[_0x36e0ad('0x5')](JSON[_0x36e0ad('0x4')](_0x3b5512));});});},Migration['prototype'][_0xcbd58f('0x15')]=function(_0x6a794c,_0x1006cf){const _0x4b5168=_0xcbd58f,_0x31a1da=this;this[_0x4b5168('0x13')][_0x4b5168('0x20')](function(){const _0xc9e07e=_0x4b5168;return _0x31a1da[_0xc9e07e('0x8')][_0xc9e07e('0x15')](_0x6a794c,_0x1006cf)['then'](function(){const _0x17b9de=_0xc9e07e;logger[_0x17b9de('0x5')]('removeIndex\x20%s\x20%s',_0x6a794c,_0x1006cf);})[_0xc9e07e('0x1b')](function(_0x19c5c5){const _0x5db8ef=_0xc9e07e;logger[_0x5db8ef('0x5')](JSON[_0x5db8ef('0x4')](_0x19c5c5));});});},Migration['prototype'][_0xcbd58f('0x3')]=function(_0x472883){const _0x240269=_0xcbd58f,_0x3e7b6f=this;this[_0x240269('0x13')][_0x240269('0x20')](function(){const _0x5daa5=_0x240269;return _0x3e7b6f[_0x5daa5('0x8')]['sequelize'][_0x5daa5('0x3')](_0x472883)[_0x5daa5('0x9')](function(){const _0x130e43=_0x5daa5;logger[_0x130e43('0x5')](_0x130e43('0xd'),_0x472883);})[_0x5daa5('0x1b')](function(_0xfb9aa2){const _0x370981=_0x5daa5;logger[_0x370981('0x5')](JSON[_0x370981('0x4')](_0xfb9aa2));});});},Migration[_0xcbd58f('0x17')][_0xcbd58f('0xb')]=function(_0x4e2ffa,_0x3ad22d){const _0x3c1759=_0xcbd58f,_0x2bcba8=this;this[_0x3c1759('0x13')][_0x3c1759('0x20')](function(){const _0x270053=_0x3c1759;return _0x2bcba8['queryInterface'][_0x270053('0xb')](_0x4e2ffa,_0x3ad22d)['then'](function(){const _0x2e3a5a=_0x270053;logger[_0x2e3a5a('0x5')](_0x2e3a5a('0x23'),_0x3ad22d,_0x4e2ffa);})['catch'](function(_0x3cf5f6){const _0x555486=_0x270053;logger[_0x555486('0x5')](util[_0x555486('0x1c')](_0x3cf5f6,{'showHidden':![],'depth':null}));});});},Migration[_0xcbd58f('0x17')][_0xcbd58f('0x1f')]=function(_0x173236,_0x181c07,_0x315cb2){const _0x4e9c53=_0xcbd58f,_0xc39567=this;this[_0x4e9c53('0x13')][_0x4e9c53('0x20')](function(){const _0x369f15=_0x4e9c53;return _0xc39567[_0x369f15('0x8')]['renameColumn'](_0x173236,_0x181c07,_0x315cb2)[_0x369f15('0x9')](function(){const _0x45e373=_0x369f15;logger[_0x45e373('0x5')](_0x45e373('0x0'),_0x181c07,_0x315cb2,_0x173236);})[_0x369f15('0x1b')](function(_0xc543b9){const _0x73f409=_0x369f15;logger[_0x73f409('0x5')](util[_0x73f409('0x1c')](_0xc543b9,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0xcbd58f('0xc')]=function(_0x5d7f6b){const _0xae0aa2=_0xcbd58f;this[_0xae0aa2('0x13')][_0xae0aa2('0x20')](function(){return _0x5d7f6b();});},module['exports']={'up':function(_0x311825,_0x9a234b){return new Promise(function(_0x1e7eb7){const _0xfb4e6=a947_0x1f08,_0x779508=new Migration(_0x311825);_0x779508[_0xfb4e6('0x3')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Fax\x27,\x20NOW(),\x20NOW())'),_0x779508[_0xfb4e6('0x3')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Answer\x20Machine\x27,\x20NOW(),\x20NOW())'),_0x779508[_0xfb4e6('0x3')](_0xfb4e6('0x22')),_0x779508[_0xfb4e6('0x3')](_0xfb4e6('0x1e')),_0x779508[_0xfb4e6('0x3')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Sold\x27,\x20NOW(),\x20NOW())'),_0x779508[_0xfb4e6('0x3')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Special\x27,\x20NOW(),\x20NOW())'),_0x779508[_0xfb4e6('0x12')]('openchannel_accounts',_0xfb4e6('0x6'),{'type':_0x9a234b[_0xfb4e6('0x10')]}),_0x779508[_0xfb4e6('0x12')](_0xfb4e6('0x2'),'closeReason',{'type':_0x9a234b['STRING']}),_0x779508['addColumn']('settings',_0xfb4e6('0x21'),{'type':_0x9a234b[_0xfb4e6('0x10')]}),_0x779508[_0xfb4e6('0x3')](_0xfb4e6('0x16')),_0x779508[_0xfb4e6('0xc')](_0x1e7eb7);});},'down':function(){}}; \ No newline at end of file +const a947_0x2ef9=['sequence','mapKey','settings','STRING','changeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','migration','info','prototype','renameColumn','tail','addColumn','exports','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Answer\x20Machine\x27,\x20NOW(),\x20NOW())','Added\x20column\x20%s\x20to\x20%s','then','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Sold\x27,\x20NOW(),\x20NOW())','join','query','Removed\x20column\x20%s\x20from\x20%s','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Not\x20Interested\x27,\x20NOW(),\x20NOW())','addIndex','closeReason','Changed\x20column\x20%s\x20in\x20table\x20%s','removeIndex','inspect','sequelize','removeColumn','enqueue','UPDATE\x20settings\x20SET\x20messagesAlignment=\x27alternate\x27','openchannel_accounts','query\x20%s','catch','queryInterface','stringify','messagesAlignment','table\x20dropped\x20%s','chat_interactions','final','INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Interested\x27,\x20NOW(),\x20NOW())','util','dropTable','../config/logger'];(function(_0x36ce84,_0x2ef9ab){const _0x257efe=function(_0x52f3a4){while(--_0x52f3a4){_0x36ce84['push'](_0x36ce84['shift']());}};_0x257efe(++_0x2ef9ab);}(a947_0x2ef9,0x9f));const a947_0x257e=function(_0x36ce84,_0x2ef9ab){_0x36ce84=_0x36ce84-0x0;let _0x257efe=a947_0x2ef9[_0x36ce84];return _0x257efe;};const _0xc5b0ec=a947_0x257e;'use strict';const util=require(_0xc5b0ec('0xa')),logger=require(_0xc5b0ec('0xc'))(_0xc5b0ec('0x13')),Sequence=function(){};Sequence[_0xc5b0ec('0x15')][_0xc5b0ec('0x29')]=function(_0x52f3a4){const _0x465ec0=_0xc5b0ec;this[_0x465ec0('0x17')]=this[_0x465ec0('0x17')]?this['tail']['finally'](_0x52f3a4):_0x52f3a4();};const Migration=function(_0x351f39){const _0x34090a=_0xc5b0ec;this[_0x34090a('0x3')]=_0x351f39,this[_0x34090a('0xd')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x407a3c,_0x745000,_0x1980f7){const _0x158077=_0xc5b0ec,_0x39f422=this;this['sequence'][_0x158077('0x29')](function(){const _0x41dee0=_0x158077;return _0x39f422['queryInterface'][_0x41dee0('0x11')](_0x407a3c,_0x745000,_0x1980f7)[_0x41dee0('0x1c')](function(){const _0x59761f=_0x41dee0;logger[_0x59761f('0x14')](_0x59761f('0x24'),_0x745000,_0x407a3c);})[_0x41dee0('0x2')](function(_0x581b22){const _0x2b9309=_0x41dee0;logger[_0x2b9309('0x14')](JSON[_0x2b9309('0x4')](_0x581b22));});});},Migration[_0xc5b0ec('0x15')][_0xc5b0ec('0x18')]=function(_0x22c57,_0x29df84,_0x50ecf7){const _0x3eba5c=_0xc5b0ec,_0x17ecb6=this;this[_0x3eba5c('0xd')][_0x3eba5c('0x29')](function(){const _0x34bd60=_0x3eba5c;return _0x17ecb6['queryInterface']['addColumn'](_0x22c57,_0x29df84,_0x50ecf7)['then'](function(){const _0xefe161=a947_0x257e;logger[_0xefe161('0x14')](_0xefe161('0x1b'),_0x29df84,_0x22c57);})[_0x34bd60('0x2')](function(_0x53c351){const _0x23ce56=_0x34bd60;logger[_0x23ce56('0x14')](JSON[_0x23ce56('0x4')](_0x53c351));});});},Migration['prototype'][_0xc5b0ec('0xb')]=function(_0x11322d){const _0x57d307=_0xc5b0ec,_0x30261f=this;this[_0x57d307('0xd')][_0x57d307('0x29')](function(){const _0xffeb9f=_0x57d307;return _0x30261f[_0xffeb9f('0x3')][_0xffeb9f('0xb')](_0x11322d,{'force':!![]})[_0xffeb9f('0x1c')](function(){const _0x44b13b=_0xffeb9f;logger['info'](_0x44b13b('0x6'),_0x11322d);})['catch'](function(_0x328c4a){const _0xfb33fe=_0xffeb9f;logger['info'](JSON[_0xfb33fe('0x4')](_0x328c4a));});});},Migration['prototype']['addIndex']=function(_0x35a546,_0x190b4f,_0x3a9475){const _0x462f11=_0xc5b0ec,_0x28c460=this;this[_0x462f11('0xd')][_0x462f11('0x29')](function(){const _0x4cc17e=_0x462f11;return _0x28c460['queryInterface'][_0x4cc17e('0x22')](_0x35a546,_0x190b4f,{'indexName':_0x3a9475})[_0x4cc17e('0x1c')](function(){const _0x27525f=_0x4cc17e;logger['info']('addIndex\x20%s\x20%s\x20%s',_0x35a546,_0x190b4f[_0x27525f('0x1e')](','),_0x3a9475);})[_0x4cc17e('0x2')](function(_0xba530c){logger['info'](JSON['stringify'](_0xba530c));});});},Migration[_0xc5b0ec('0x15')][_0xc5b0ec('0x25')]=function(_0x38b33b,_0x1511a0){const _0x19c5d5=_0xc5b0ec,_0x37c8fb=this;this[_0x19c5d5('0xd')][_0x19c5d5('0x29')](function(){const _0x858cf9=_0x19c5d5;return _0x37c8fb[_0x858cf9('0x3')]['removeIndex'](_0x38b33b,_0x1511a0)[_0x858cf9('0x1c')](function(){logger['info']('removeIndex\x20%s\x20%s',_0x38b33b,_0x1511a0);})['catch'](function(_0x3c01dc){const _0x48dae0=_0x858cf9;logger[_0x48dae0('0x14')](JSON[_0x48dae0('0x4')](_0x3c01dc));});});},Migration['prototype'][_0xc5b0ec('0x1f')]=function(_0x57745f){const _0x385eb2=_0xc5b0ec,_0x2a3030=this;this['sequence'][_0x385eb2('0x29')](function(){const _0x32d13f=_0x385eb2;return _0x2a3030[_0x32d13f('0x3')][_0x32d13f('0x27')][_0x32d13f('0x1f')](_0x57745f)[_0x32d13f('0x1c')](function(){const _0x1aa7e1=_0x32d13f;logger[_0x1aa7e1('0x14')](_0x1aa7e1('0x1'),_0x57745f);})[_0x32d13f('0x2')](function(_0x36d9a9){const _0x188fd0=_0x32d13f;logger[_0x188fd0('0x14')](JSON[_0x188fd0('0x4')](_0x36d9a9));});});},Migration[_0xc5b0ec('0x15')][_0xc5b0ec('0x28')]=function(_0x56b595,_0x27efea){const _0x3ad4e6=_0xc5b0ec,_0x581e16=this;this['sequence'][_0x3ad4e6('0x29')](function(){const _0x2c1fba=_0x3ad4e6;return _0x581e16[_0x2c1fba('0x3')][_0x2c1fba('0x28')](_0x56b595,_0x27efea)[_0x2c1fba('0x1c')](function(){const _0x3ce5be=_0x2c1fba;logger[_0x3ce5be('0x14')](_0x3ce5be('0x20'),_0x27efea,_0x56b595);})[_0x2c1fba('0x2')](function(_0x3a0aaf){const _0x2fd9d7=_0x2c1fba;logger[_0x2fd9d7('0x14')](util[_0x2fd9d7('0x26')](_0x3a0aaf,{'showHidden':![],'depth':null}));});});},Migration[_0xc5b0ec('0x15')][_0xc5b0ec('0x16')]=function(_0x508c38,_0xb0b474,_0x42a6eb){const _0x56ec4f=_0xc5b0ec,_0x48030d=this;this[_0x56ec4f('0xd')][_0x56ec4f('0x29')](function(){const _0x47d5ec=_0x56ec4f;return _0x48030d[_0x47d5ec('0x3')][_0x47d5ec('0x16')](_0x508c38,_0xb0b474,_0x42a6eb)[_0x47d5ec('0x1c')](function(){const _0x894484=_0x47d5ec;logger['info'](_0x894484('0x12'),_0xb0b474,_0x42a6eb,_0x508c38);})[_0x47d5ec('0x2')](function(_0x5627a6){const _0x203fbd=_0x47d5ec;logger[_0x203fbd('0x14')](util[_0x203fbd('0x26')](_0x5627a6,{'showHidden':![],'depth':null}));});});},Migration[_0xc5b0ec('0x15')][_0xc5b0ec('0x8')]=function(_0x2468ec){const _0x25f9af=_0xc5b0ec;this[_0x25f9af('0xd')]['enqueue'](function(){return _0x2468ec();});},module[_0xc5b0ec('0x19')]={'up':function(_0x318349,_0x37dfb8){return new Promise(function(_0x1666f5){const _0x128575=a947_0x257e,_0xdb48a3=new Migration(_0x318349);_0xdb48a3[_0x128575('0x1f')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Fax\x27,\x20NOW(),\x20NOW())'),_0xdb48a3[_0x128575('0x1f')](_0x128575('0x1a')),_0xdb48a3[_0x128575('0x1f')](_0x128575('0x9')),_0xdb48a3[_0x128575('0x1f')](_0x128575('0x21')),_0xdb48a3[_0x128575('0x1f')](_0x128575('0x1d')),_0xdb48a3[_0x128575('0x1f')]('INSERT\x20INTO\x20tools_dispositions\x20(`name`,\x20`createdAt`,\x20`updatedAt`)\x20VALUES\x20(\x27Special\x27,\x20NOW(),\x20NOW())'),_0xdb48a3['addColumn'](_0x128575('0x0'),_0x128575('0xe'),{'type':_0x37dfb8[_0x128575('0x10')]}),_0xdb48a3[_0x128575('0x18')](_0x128575('0x7'),_0x128575('0x23'),{'type':_0x37dfb8[_0x128575('0x10')]}),_0xdb48a3[_0x128575('0x18')](_0x128575('0xf'),_0x128575('0x5'),{'type':_0x37dfb8[_0x128575('0x10')]}),_0xdb48a3[_0x128575('0x1f')](_0x128575('0x2a')),_0xdb48a3[_0x128575('0x8')](_0x1666f5);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.69.js b/server/migrations/2.0.69.js index a313022..614e976 100644 --- a/server/migrations/2.0.69.js +++ b/server/migrations/2.0.69.js @@ -1 +1 @@ -const a948_0x1bae=['name','prototype','voice_extensions','queryInterface','cm_contacts','sequelize','migration','query\x20%s','TEXT','Changed\x20column\x20%s\x20in\x20table\x20%s','dropTable','sequence','line','VoicePrefixId','table\x20dropped\x20%s','voice_prefixes','enqueue','changeColumn','addColumn','report_call','finally','removeIndex\x20%s\x20%s','answer','stringify','STRING','final','join','then','Added\x20column\x20%s\x20to\x20%s','update\x20voice_extensions\x20set\x20app\x20=\x20\x27ExecIf\x27,\x20appdata\x20=\x20CONCAT(\x27$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):Set(\x27,\x20appdata,\x20\x27)\x27)\x20where\x20appdata\x20LIKE\x20CONCAT(\x27CALLERID(all)\x27,\x20\x27%\x27)\x20and\x20type\x20=\x20\x27outbound\x27','callerIdAll','removeColumn','catch','UPDATE\x20tools_sounds\x20S1\x20JOIN\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(SELECT\x20name\x20FROM\x20tools_sounds\x20GROUP\x20BY\x20name\x20HAVING\x20COUNT(id)\x20>\x201)\x20S2\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20S1.name\x20=\x20S2.name\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SET\x20S1.name\x20=\x20CONCAT(S1.name,\x20\x27_\x27,\x20LOWER(LPAD(CONV(FLOOR(RAND()*POW(36,6)),\x2010,\x2036),\x206,\x200)))','addIndex\x20%s\x20%s\x20%s','report_jscripty_questions','tail','backgroundColor','exports','addIndex','#fafafa','prefix','renameColumn','chat_websites','report_jscripty_answers','INTEGER','removeIndex','info','query','long','inspect','../config/logger','messageFontSize'];(function(_0xedc36e,_0x1bae97){const _0x326db7=function(_0x397e03){while(--_0x397e03){_0xedc36e['push'](_0xedc36e['shift']());}};_0x326db7(++_0x1bae97);}(a948_0x1bae,0xdf));const a948_0x326d=function(_0xedc36e,_0x1bae97){_0xedc36e=_0xedc36e-0x0;let _0x326db7=a948_0x1bae[_0xedc36e];return _0x326db7;};const _0x16c5d5=a948_0x326d;'use strict';const util=require('util'),logger=require(_0x16c5d5('0x28'))(_0x16c5d5('0x30')),Sequence=function(){};Sequence[_0x16c5d5('0x2b')][_0x16c5d5('0x5')]=function(_0x397e03){const _0x23cfff=_0x16c5d5;this[_0x23cfff('0x19')]=this['tail']?this[_0x23cfff('0x19')][_0x23cfff('0x9')](_0x397e03):_0x397e03();};const Migration=function(_0x4fbe14){const _0x8232d9=_0x16c5d5;this[_0x8232d9('0x2d')]=_0x4fbe14,this['sequence']=new Sequence();};Migration[_0x16c5d5('0x2b')]['changeColumn']=function(_0x2980c2,_0x3ea665,_0x590594){const _0xf4f483=this;this['sequence']['enqueue'](function(){const _0x533d13=a948_0x326d;return _0xf4f483[_0x533d13('0x2d')][_0x533d13('0x6')](_0x2980c2,_0x3ea665,_0x590594)['then'](function(){const _0x1c29ca=_0x533d13;logger[_0x1c29ca('0x24')](_0x1c29ca('0x33'),_0x3ea665,_0x2980c2);})['catch'](function(_0x18b965){const _0x266f7e=_0x533d13;logger[_0x266f7e('0x24')](JSON[_0x266f7e('0xc')](_0x18b965));});});},Migration['prototype'][_0x16c5d5('0x7')]=function(_0x2e3d94,_0x4102c8,_0x2dcc1f){const _0x4aecba=_0x16c5d5,_0x701174=this;this['sequence'][_0x4aecba('0x5')](function(){const _0x35209a=_0x4aecba;return _0x701174['queryInterface']['addColumn'](_0x2e3d94,_0x4102c8,_0x2dcc1f)[_0x35209a('0x10')](function(){const _0xdcff29=_0x35209a;logger[_0xdcff29('0x24')](_0xdcff29('0x11'),_0x4102c8,_0x2e3d94);})['catch'](function(_0x41fb75){const _0x9ac94e=_0x35209a;logger['info'](JSON[_0x9ac94e('0xc')](_0x41fb75));});});},Migration[_0x16c5d5('0x2b')][_0x16c5d5('0x34')]=function(_0xf4d86){const _0x30378f=_0x16c5d5,_0x31b451=this;this[_0x30378f('0x0')]['enqueue'](function(){return _0x31b451['queryInterface']['dropTable'](_0xf4d86,{'force':!![]})['then'](function(){const _0x33fdb8=a948_0x326d;logger[_0x33fdb8('0x24')](_0x33fdb8('0x3'),_0xf4d86);})['catch'](function(_0x4f03f5){const _0x172f28=a948_0x326d;logger[_0x172f28('0x24')](JSON[_0x172f28('0xc')](_0x4f03f5));});});},Migration['prototype'][_0x16c5d5('0x1c')]=function(_0xb12c5,_0x36ae16,_0x511f7b){const _0x41e4fa=_0x16c5d5,_0x18bde9=this;this['sequence'][_0x41e4fa('0x5')](function(){const _0x960cff=_0x41e4fa;return _0x18bde9[_0x960cff('0x2d')][_0x960cff('0x1c')](_0xb12c5,_0x36ae16,{'indexName':_0x511f7b})['then'](function(){const _0x231675=_0x960cff;logger['info'](_0x231675('0x17'),_0xb12c5,_0x36ae16[_0x231675('0xf')](','),_0x511f7b);})[_0x960cff('0x15')](function(_0x377a5d){logger['info'](JSON['stringify'](_0x377a5d));});});},Migration['prototype'][_0x16c5d5('0x23')]=function(_0x49eccc,_0x350d08){const _0x262035=_0x16c5d5,_0x3f578c=this;this[_0x262035('0x0')][_0x262035('0x5')](function(){const _0x4f4440=_0x262035;return _0x3f578c[_0x4f4440('0x2d')][_0x4f4440('0x23')](_0x49eccc,_0x350d08)['then'](function(){const _0x212be4=_0x4f4440;logger['info'](_0x212be4('0xa'),_0x49eccc,_0x350d08);})[_0x4f4440('0x15')](function(_0x161273){const _0x39954f=_0x4f4440;logger[_0x39954f('0x24')](JSON[_0x39954f('0xc')](_0x161273));});});},Migration['prototype']['query']=function(_0x595b50){const _0x540563=_0x16c5d5,_0x514e9b=this;this['sequence'][_0x540563('0x5')](function(){const _0x128cc3=_0x540563;return _0x514e9b['queryInterface'][_0x128cc3('0x2f')]['query'](_0x595b50)['then'](function(){const _0x24b537=_0x128cc3;logger[_0x24b537('0x24')](_0x24b537('0x31'),_0x595b50);})['catch'](function(_0x236c1c){const _0xb8a3ec=_0x128cc3;logger[_0xb8a3ec('0x24')](JSON['stringify'](_0x236c1c));});});},Migration['prototype']['removeColumn']=function(_0xdae841,_0x46dfd7){const _0x14b189=_0x16c5d5,_0x11df05=this;this[_0x14b189('0x0')][_0x14b189('0x5')](function(){const _0x394de1=_0x14b189;return _0x11df05[_0x394de1('0x2d')][_0x394de1('0x14')](_0xdae841,_0x46dfd7)[_0x394de1('0x10')](function(){const _0x3fc68b=_0x394de1;logger[_0x3fc68b('0x24')]('Removed\x20column\x20%s\x20from\x20%s',_0x46dfd7,_0xdae841);})[_0x394de1('0x15')](function(_0x15476e){const _0x3228ab=_0x394de1;logger[_0x3228ab('0x24')](util[_0x3228ab('0x27')](_0x15476e,{'showHidden':![],'depth':null}));});});},Migration[_0x16c5d5('0x2b')][_0x16c5d5('0x1f')]=function(_0x555cca,_0x483b40,_0x3075b7){const _0x2441a6=_0x16c5d5,_0x17509b=this;this['sequence'][_0x2441a6('0x5')](function(){const _0x5dfc32=_0x2441a6;return _0x17509b[_0x5dfc32('0x2d')][_0x5dfc32('0x1f')](_0x555cca,_0x483b40,_0x3075b7)[_0x5dfc32('0x10')](function(){const _0x587354=_0x5dfc32;logger[_0x587354('0x24')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x483b40,_0x3075b7,_0x555cca);})[_0x5dfc32('0x15')](function(_0x80f72e){const _0x1de557=_0x5dfc32;logger['info'](util[_0x1de557('0x27')](_0x80f72e,{'showHidden':![],'depth':null}));});});},Migration[_0x16c5d5('0x2b')][_0x16c5d5('0xe')]=function(_0x459f2c){const _0x377bc5=_0x16c5d5;this[_0x377bc5('0x0')]['enqueue'](function(){return _0x459f2c();});},module[_0x16c5d5('0x1b')]={'up':function(_0x32b170,_0x5c804a){return new Promise(function(_0x4b937a){const _0x160e43=a948_0x326d,_0x593d63=new Migration(_0x32b170);_0x593d63[_0x160e43('0x6')](_0x160e43('0x21'),_0x160e43('0xb'),{'type':_0x5c804a[_0x160e43('0x32')](_0x160e43('0x26'))}),_0x593d63[_0x160e43('0x6')](_0x160e43('0x18'),_0x160e43('0xb'),{'type':_0x5c804a[_0x160e43('0x32')](_0x160e43('0x26'))}),_0x593d63[_0x160e43('0x25')](_0x160e43('0x16')),_0x593d63[_0x160e43('0x6')]('tools_sounds',_0x160e43('0x2a'),{'type':_0x5c804a[_0x160e43('0xd')],'unique':!![],'allowNull':![]}),_0x593d63[_0x160e43('0x7')](_0x160e43('0x20'),_0x160e43('0x29'),{'type':_0x5c804a[_0x160e43('0x22')],'defaultValue':0xc}),_0x593d63[_0x160e43('0x7')]('chat_websites',_0x160e43('0x1a'),{'type':_0x5c804a[_0x160e43('0xd')],'allowNull':![],'defaultValue':_0x160e43('0x1d'),'validate':{'notEmpty':!![]}}),_0x593d63['addColumn'](_0x160e43('0x2e'),_0x160e43('0x1'),{'type':_0x5c804a[_0x160e43('0xd')]}),_0x593d63[_0x160e43('0x25')]('DELETE\x20FROM\x20`voice_prefixes`'),_0x593d63[_0x160e43('0x25')]('DELETE\x20FROM\x20`user_has_voice_prefixes`'),_0x593d63['removeIndex'](_0x160e43('0x4'),_0x160e43('0x1e')),_0x593d63[_0x160e43('0x14')](_0x160e43('0x4'),_0x160e43('0x1e')),_0x593d63[_0x160e43('0x7')](_0x160e43('0x4'),_0x160e43('0x13'),{'type':_0x5c804a[_0x160e43('0xd')]}),_0x593d63[_0x160e43('0x7')](_0x160e43('0x4'),'VoiceExtensionId',{'type':_0x5c804a[_0x160e43('0x22')]}),_0x593d63[_0x160e43('0x7')](_0x160e43('0x2c'),_0x160e43('0x2'),{'type':_0x5c804a['INTEGER']}),_0x593d63[_0x160e43('0x25')]('ALTER\x20TABLE\x20`voice_extensions`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`voice_extensions_ibfk_7`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`VoicePrefixId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20voice_prefixes(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE'),_0x593d63[_0x160e43('0x25')](_0x160e43('0x12')),_0x593d63[_0x160e43('0x7')](_0x160e43('0x8'),_0x160e43('0x1e'),{'type':_0x5c804a['STRING']}),_0x593d63['final'](_0x4b937a);});},'down':function(){}}; \ No newline at end of file +const a948_0x2fdc=['long','prefix','query\x20%s','INTEGER','migration','line','removeColumn','#fafafa','voice_prefixes','addColumn','callerIdAll','tail','sequelize','VoicePrefixId','voice_extensions','DELETE\x20FROM\x20`user_has_voice_prefixes`','tools_sounds','inspect','backgroundColor','report_jscripty_questions','prototype','changeColumn','removeIndex','then','util','name','UPDATE\x20tools_sounds\x20S1\x20JOIN\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(SELECT\x20name\x20FROM\x20tools_sounds\x20GROUP\x20BY\x20name\x20HAVING\x20COUNT(id)\x20>\x201)\x20S2\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20S1.name\x20=\x20S2.name\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SET\x20S1.name\x20=\x20CONCAT(S1.name,\x20\x27_\x27,\x20LOWER(LPAD(CONV(FLOOR(RAND()*POW(36,6)),\x2010,\x2036),\x206,\x200)))','final','addIndex','VoiceExtensionId','queryInterface','Changed\x20column\x20%s\x20in\x20table\x20%s','enqueue','renameColumn','chat_websites','Added\x20column\x20%s\x20to\x20%s','../config/logger','cm_contacts','info','STRING','stringify','answer','catch','finally','dropTable','join','exports','query','ALTER\x20TABLE\x20`voice_extensions`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ADD\x20CONSTRAINT\x20`voice_extensions_ibfk_7`\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FOREIGN\x20KEY\x20(`VoicePrefixId`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20REFERENCES\x20voice_prefixes(`id`)\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20UPDATE\x20CASCADE\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ON\x20DELETE\x20CASCADE','addIndex\x20%s\x20%s\x20%s','report_call','removeIndex\x20%s\x20%s','report_jscripty_answers','sequence'];(function(_0x16921e,_0x2fdce2){const _0xae97f2=function(_0x98d09b){while(--_0x98d09b){_0x16921e['push'](_0x16921e['shift']());}};_0xae97f2(++_0x2fdce2);}(a948_0x2fdc,0x106));const a948_0xae97=function(_0x16921e,_0x2fdce2){_0x16921e=_0x16921e-0x0;let _0xae97f2=a948_0x2fdc[_0x16921e];return _0xae97f2;};const _0x36a1cb=a948_0xae97;'use strict';const util=require(_0x36a1cb('0x20')),logger=require(_0x36a1cb('0x2c'))(_0x36a1cb('0xc')),Sequence=function(){};Sequence[_0x36a1cb('0x1c')][_0x36a1cb('0x28')]=function(_0x98d09b){const _0x408e76=_0x36a1cb;this[_0x408e76('0x13')]=this['tail']?this[_0x408e76('0x13')][_0x408e76('0x33')](_0x98d09b):_0x98d09b();};const Migration=function(_0x17851f){const _0x3b9084=_0x36a1cb;this[_0x3b9084('0x26')]=_0x17851f,this[_0x3b9084('0x7')]=new Sequence();};Migration[_0x36a1cb('0x1c')][_0x36a1cb('0x1d')]=function(_0x242eb1,_0x1ef61b,_0x530a9f){const _0x2051ff=_0x36a1cb,_0x30a137=this;this[_0x2051ff('0x7')][_0x2051ff('0x28')](function(){const _0x1315f7=_0x2051ff;return _0x30a137[_0x1315f7('0x26')][_0x1315f7('0x1d')](_0x242eb1,_0x1ef61b,_0x530a9f)['then'](function(){const _0x55d7cc=_0x1315f7;logger[_0x55d7cc('0x2e')](_0x55d7cc('0x27'),_0x1ef61b,_0x242eb1);})[_0x1315f7('0x32')](function(_0xee5ab0){const _0x5b8e2f=_0x1315f7;logger['info'](JSON[_0x5b8e2f('0x30')](_0xee5ab0));});});},Migration[_0x36a1cb('0x1c')][_0x36a1cb('0x11')]=function(_0x2174a4,_0x38e452,_0x2e463e){const _0x7d378=_0x36a1cb,_0x113327=this;this[_0x7d378('0x7')]['enqueue'](function(){const _0x2d59be=_0x7d378;return _0x113327[_0x2d59be('0x26')]['addColumn'](_0x2174a4,_0x38e452,_0x2e463e)['then'](function(){const _0xe55fb5=_0x2d59be;logger[_0xe55fb5('0x2e')](_0xe55fb5('0x2b'),_0x38e452,_0x2174a4);})[_0x2d59be('0x32')](function(_0x1eabf4){const _0x29a2ca=_0x2d59be;logger['info'](JSON[_0x29a2ca('0x30')](_0x1eabf4));});});},Migration[_0x36a1cb('0x1c')]['dropTable']=function(_0x424041){const _0x257e28=_0x36a1cb,_0x51d79b=this;this[_0x257e28('0x7')]['enqueue'](function(){const _0x3e1978=_0x257e28;return _0x51d79b[_0x3e1978('0x26')][_0x3e1978('0x34')](_0x424041,{'force':!![]})[_0x3e1978('0x1f')](function(){const _0x14eaf3=_0x3e1978;logger[_0x14eaf3('0x2e')]('table\x20dropped\x20%s',_0x424041);})[_0x3e1978('0x32')](function(_0x38b4ed){const _0x408b50=_0x3e1978;logger[_0x408b50('0x2e')](JSON['stringify'](_0x38b4ed));});});},Migration[_0x36a1cb('0x1c')][_0x36a1cb('0x24')]=function(_0x1f81b2,_0x44477e,_0x1aea5d){const _0x432a06=_0x36a1cb,_0x1fbb96=this;this[_0x432a06('0x7')][_0x432a06('0x28')](function(){const _0x5a8ef6=_0x432a06;return _0x1fbb96[_0x5a8ef6('0x26')][_0x5a8ef6('0x24')](_0x1f81b2,_0x44477e,{'indexName':_0x1aea5d})[_0x5a8ef6('0x1f')](function(){const _0x118583=_0x5a8ef6;logger[_0x118583('0x2e')](_0x118583('0x3'),_0x1f81b2,_0x44477e[_0x118583('0x35')](','),_0x1aea5d);})[_0x5a8ef6('0x32')](function(_0x1381be){const _0x162487=_0x5a8ef6;logger[_0x162487('0x2e')](JSON['stringify'](_0x1381be));});});},Migration[_0x36a1cb('0x1c')][_0x36a1cb('0x1e')]=function(_0x3a124e,_0x53c412){const _0x2b7206=_0x36a1cb,_0x165677=this;this[_0x2b7206('0x7')][_0x2b7206('0x28')](function(){const _0x1ce011=_0x2b7206;return _0x165677['queryInterface']['removeIndex'](_0x3a124e,_0x53c412)[_0x1ce011('0x1f')](function(){const _0x44ba17=_0x1ce011;logger[_0x44ba17('0x2e')](_0x44ba17('0x5'),_0x3a124e,_0x53c412);})[_0x1ce011('0x32')](function(_0x15cad2){const _0x44cc0a=_0x1ce011;logger[_0x44cc0a('0x2e')](JSON[_0x44cc0a('0x30')](_0x15cad2));});});},Migration[_0x36a1cb('0x1c')][_0x36a1cb('0x1')]=function(_0x2e58ca){const _0x5b8eff=_0x36a1cb,_0x2d763a=this;this[_0x5b8eff('0x7')][_0x5b8eff('0x28')](function(){const _0xcc48de=_0x5b8eff;return _0x2d763a['queryInterface'][_0xcc48de('0x14')]['query'](_0x2e58ca)['then'](function(){const _0x1b7314=_0xcc48de;logger[_0x1b7314('0x2e')](_0x1b7314('0xa'),_0x2e58ca);})[_0xcc48de('0x32')](function(_0x5aa389){const _0x42bca4=_0xcc48de;logger[_0x42bca4('0x2e')](JSON[_0x42bca4('0x30')](_0x5aa389));});});},Migration['prototype'][_0x36a1cb('0xe')]=function(_0x1e6510,_0x1dc670){const _0x37fff0=_0x36a1cb,_0x1bfe74=this;this[_0x37fff0('0x7')][_0x37fff0('0x28')](function(){const _0x4aa532=_0x37fff0;return _0x1bfe74[_0x4aa532('0x26')][_0x4aa532('0xe')](_0x1e6510,_0x1dc670)[_0x4aa532('0x1f')](function(){const _0x5d78a4=_0x4aa532;logger[_0x5d78a4('0x2e')]('Removed\x20column\x20%s\x20from\x20%s',_0x1dc670,_0x1e6510);})[_0x4aa532('0x32')](function(_0x59592b){const _0x3289dd=_0x4aa532;logger[_0x3289dd('0x2e')](util[_0x3289dd('0x19')](_0x59592b,{'showHidden':![],'depth':null}));});});},Migration[_0x36a1cb('0x1c')][_0x36a1cb('0x29')]=function(_0x1eb3ff,_0xe66112,_0x3cb7e5){const _0x36700a=_0x36a1cb,_0x3fa733=this;this[_0x36700a('0x7')][_0x36700a('0x28')](function(){const _0x593019=_0x36700a;return _0x3fa733[_0x593019('0x26')][_0x593019('0x29')](_0x1eb3ff,_0xe66112,_0x3cb7e5)[_0x593019('0x1f')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0xe66112,_0x3cb7e5,_0x1eb3ff);})['catch'](function(_0x24bde6){const _0x5c55ad=_0x593019;logger[_0x5c55ad('0x2e')](util[_0x5c55ad('0x19')](_0x24bde6,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x36a1cb('0x23')]=function(_0x57842c){const _0x5cfc50=_0x36a1cb;this[_0x5cfc50('0x7')]['enqueue'](function(){return _0x57842c();});},module[_0x36a1cb('0x0')]={'up':function(_0x5d90db,_0x68fb74){return new Promise(function(_0x91adc){const _0x8fca4a=a948_0xae97,_0x202e2f=new Migration(_0x5d90db);_0x202e2f[_0x8fca4a('0x1d')](_0x8fca4a('0x6'),'answer',{'type':_0x68fb74['TEXT']('long')}),_0x202e2f[_0x8fca4a('0x1d')](_0x8fca4a('0x1b'),_0x8fca4a('0x31'),{'type':_0x68fb74['TEXT'](_0x8fca4a('0x8'))}),_0x202e2f[_0x8fca4a('0x1')](_0x8fca4a('0x22')),_0x202e2f[_0x8fca4a('0x1d')](_0x8fca4a('0x18'),_0x8fca4a('0x21'),{'type':_0x68fb74['STRING'],'unique':!![],'allowNull':![]}),_0x202e2f['addColumn'](_0x8fca4a('0x2a'),'messageFontSize',{'type':_0x68fb74[_0x8fca4a('0xb')],'defaultValue':0xc}),_0x202e2f[_0x8fca4a('0x11')](_0x8fca4a('0x2a'),_0x8fca4a('0x1a'),{'type':_0x68fb74['STRING'],'allowNull':![],'defaultValue':_0x8fca4a('0xf'),'validate':{'notEmpty':!![]}}),_0x202e2f[_0x8fca4a('0x11')](_0x8fca4a('0x2d'),_0x8fca4a('0xd'),{'type':_0x68fb74[_0x8fca4a('0x2f')]}),_0x202e2f['query']('DELETE\x20FROM\x20`voice_prefixes`'),_0x202e2f['query'](_0x8fca4a('0x17')),_0x202e2f[_0x8fca4a('0x1e')](_0x8fca4a('0x10'),_0x8fca4a('0x9')),_0x202e2f[_0x8fca4a('0xe')](_0x8fca4a('0x10'),_0x8fca4a('0x9')),_0x202e2f[_0x8fca4a('0x11')](_0x8fca4a('0x10'),_0x8fca4a('0x12'),{'type':_0x68fb74[_0x8fca4a('0x2f')]}),_0x202e2f['addColumn']('voice_prefixes',_0x8fca4a('0x25'),{'type':_0x68fb74['INTEGER']}),_0x202e2f['addColumn'](_0x8fca4a('0x16'),_0x8fca4a('0x15'),{'type':_0x68fb74[_0x8fca4a('0xb')]}),_0x202e2f[_0x8fca4a('0x1')](_0x8fca4a('0x2')),_0x202e2f[_0x8fca4a('0x1')]('update\x20voice_extensions\x20set\x20app\x20=\x20\x27ExecIf\x27,\x20appdata\x20=\x20CONCAT(\x27$[${LEN(${PREFIX-CALLERIDALL})}\x20>\x200]?Set(CALLERID(all)=${PREFIX-CALLERIDALL}):Set(\x27,\x20appdata,\x20\x27)\x27)\x20where\x20appdata\x20LIKE\x20CONCAT(\x27CALLERID(all)\x27,\x20\x27%\x27)\x20and\x20type\x20=\x20\x27outbound\x27'),_0x202e2f[_0x8fca4a('0x11')](_0x8fca4a('0x4'),'prefix',{'type':_0x68fb74['STRING']}),_0x202e2f[_0x8fca4a('0x23')](_0x91adc);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.70.js b/server/migrations/2.0.70.js index 904cba7..5ab584d 100644 --- a/server/migrations/2.0.70.js +++ b/server/migrations/2.0.70.js @@ -1 +1 @@ -const a949_0x1ddd=['enqueue','sequence','info','removeIndex','join','util','addIndex','removeColumn','sequelize','query','Changed\x20column\x20%s\x20in\x20table\x20%s','table\x20dropped\x20%s','prototype','queryInterface','addColumn','stringify','inspect','Added\x20column\x20%s\x20to\x20%s','exports','dropTable','catch','query\x20%s','finally','mohtime','then','INTEGER','final','renameColumn','addIndex\x20%s\x20%s\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','tail','../config/logger','report_queue'];(function(_0x550362,_0x1ddd57){const _0x47fbae=function(_0x28b763){while(--_0x28b763){_0x550362['push'](_0x550362['shift']());}};_0x47fbae(++_0x1ddd57);}(a949_0x1ddd,0x8c));const a949_0x47fb=function(_0x550362,_0x1ddd57){_0x550362=_0x550362-0x0;let _0x47fbae=a949_0x1ddd[_0x550362];return _0x47fbae;};const _0x451cbc=a949_0x47fb;'use strict';const util=require(_0x451cbc('0x1e')),logger=require(_0x451cbc('0x17'))('migration'),Sequence=function(){};Sequence[_0x451cbc('0x4')][_0x451cbc('0x19')]=function(_0x28b763){const _0x44db40=_0x451cbc;this[_0x44db40('0x16')]=this['tail']?this['tail'][_0x44db40('0xe')](_0x28b763):_0x28b763();};const Migration=function(_0x13a780){const _0x1be94d=_0x451cbc;this[_0x1be94d('0x5')]=_0x13a780,this[_0x1be94d('0x1a')]=new Sequence();};Migration[_0x451cbc('0x4')]['changeColumn']=function(_0x235f4a,_0x53a9f0,_0xffc42b){const _0x50fc93=_0x451cbc,_0x216ff0=this;this[_0x50fc93('0x1a')][_0x50fc93('0x19')](function(){const _0x4dfc52=_0x50fc93;return _0x216ff0[_0x4dfc52('0x5')]['changeColumn'](_0x235f4a,_0x53a9f0,_0xffc42b)[_0x4dfc52('0x10')](function(){const _0xb9f23a=_0x4dfc52;logger[_0xb9f23a('0x1b')](_0xb9f23a('0x2'),_0x53a9f0,_0x235f4a);})['catch'](function(_0x33190b){const _0x5aab30=_0x4dfc52;logger['info'](JSON[_0x5aab30('0x7')](_0x33190b));});});},Migration[_0x451cbc('0x4')]['addColumn']=function(_0x4a01a4,_0x26298d,_0x27d96f){const _0x7d5115=_0x451cbc,_0x141880=this;this[_0x7d5115('0x1a')][_0x7d5115('0x19')](function(){const _0x228bbf=_0x7d5115;return _0x141880[_0x228bbf('0x5')]['addColumn'](_0x4a01a4,_0x26298d,_0x27d96f)[_0x228bbf('0x10')](function(){const _0x2026a9=_0x228bbf;logger[_0x2026a9('0x1b')](_0x2026a9('0x9'),_0x26298d,_0x4a01a4);})[_0x228bbf('0xc')](function(_0x239b3f){const _0x254dbc=_0x228bbf;logger[_0x254dbc('0x1b')](JSON[_0x254dbc('0x7')](_0x239b3f));});});},Migration[_0x451cbc('0x4')][_0x451cbc('0xb')]=function(_0x2613aa){const _0xa4a304=_0x451cbc,_0x132c9f=this;this['sequence'][_0xa4a304('0x19')](function(){const _0x3de23f=_0xa4a304;return _0x132c9f[_0x3de23f('0x5')]['dropTable'](_0x2613aa,{'force':!![]})['then'](function(){const _0x18c490=_0x3de23f;logger[_0x18c490('0x1b')](_0x18c490('0x3'),_0x2613aa);})[_0x3de23f('0xc')](function(_0x58dac1){const _0x50f571=_0x3de23f;logger[_0x50f571('0x1b')](JSON['stringify'](_0x58dac1));});});},Migration['prototype'][_0x451cbc('0x1f')]=function(_0x5f239c,_0x9a7740,_0x63b8a2){const _0x4029f0=_0x451cbc,_0x4b39b8=this;this[_0x4029f0('0x1a')][_0x4029f0('0x19')](function(){const _0x3749ba=_0x4029f0;return _0x4b39b8[_0x3749ba('0x5')][_0x3749ba('0x1f')](_0x5f239c,_0x9a7740,{'indexName':_0x63b8a2})['then'](function(){const _0x549584=_0x3749ba;logger[_0x549584('0x1b')](_0x549584('0x14'),_0x5f239c,_0x9a7740[_0x549584('0x1d')](','),_0x63b8a2);})[_0x3749ba('0xc')](function(_0x44fd70){const _0x1bafde=_0x3749ba;logger[_0x1bafde('0x1b')](JSON[_0x1bafde('0x7')](_0x44fd70));});});},Migration[_0x451cbc('0x4')][_0x451cbc('0x1c')]=function(_0x2c394b,_0x15a215){const _0x557741=_0x451cbc,_0x39b46d=this;this[_0x557741('0x1a')][_0x557741('0x19')](function(){const _0x2350d2=_0x557741;return _0x39b46d[_0x2350d2('0x5')][_0x2350d2('0x1c')](_0x2c394b,_0x15a215)[_0x2350d2('0x10')](function(){logger['info']('removeIndex\x20%s\x20%s',_0x2c394b,_0x15a215);})[_0x2350d2('0xc')](function(_0x4e9649){const _0xb25465=_0x2350d2;logger[_0xb25465('0x1b')](JSON[_0xb25465('0x7')](_0x4e9649));});});},Migration[_0x451cbc('0x4')][_0x451cbc('0x1')]=function(_0x27a6ea){const _0x30c576=_0x451cbc,_0x570d4e=this;this['sequence'][_0x30c576('0x19')](function(){const _0x412464=_0x30c576;return _0x570d4e[_0x412464('0x5')][_0x412464('0x0')][_0x412464('0x1')](_0x27a6ea)[_0x412464('0x10')](function(){const _0x4dc0c6=_0x412464;logger[_0x4dc0c6('0x1b')](_0x4dc0c6('0xd'),_0x27a6ea);})[_0x412464('0xc')](function(_0xbb2a85){const _0x4e3ce5=_0x412464;logger[_0x4e3ce5('0x1b')](JSON[_0x4e3ce5('0x7')](_0xbb2a85));});});},Migration[_0x451cbc('0x4')][_0x451cbc('0x20')]=function(_0x38a42b,_0x23332b){const _0x393f22=_0x451cbc,_0x471642=this;this[_0x393f22('0x1a')]['enqueue'](function(){const _0x20be26=_0x393f22;return _0x471642['queryInterface'][_0x20be26('0x20')](_0x38a42b,_0x23332b)[_0x20be26('0x10')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x23332b,_0x38a42b);})[_0x20be26('0xc')](function(_0x451504){const _0x118db7=_0x20be26;logger[_0x118db7('0x1b')](util[_0x118db7('0x8')](_0x451504,{'showHidden':![],'depth':null}));});});},Migration[_0x451cbc('0x4')][_0x451cbc('0x13')]=function(_0x3a4169,_0x35bc30,_0x41b344){const _0x2045d9=this;this['sequence']['enqueue'](function(){const _0x486f94=a949_0x47fb;return _0x2045d9[_0x486f94('0x5')]['renameColumn'](_0x3a4169,_0x35bc30,_0x41b344)[_0x486f94('0x10')](function(){const _0x22dffd=_0x486f94;logger[_0x22dffd('0x1b')](_0x22dffd('0x15'),_0x35bc30,_0x41b344,_0x3a4169);})[_0x486f94('0xc')](function(_0x46ae95){const _0x193dfe=_0x486f94;logger[_0x193dfe('0x1b')](util[_0x193dfe('0x8')](_0x46ae95,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x4f3e01){const _0x4693f6=_0x451cbc;this[_0x4693f6('0x1a')]['enqueue'](function(){return _0x4f3e01();});},module[_0x451cbc('0xa')]={'up':function(_0x3a85c8,_0x4a2c23){return new Promise(function(_0x4cb66b){const _0x21ce58=a949_0x47fb,_0x195bbb=new Migration(_0x3a85c8);_0x195bbb[_0x21ce58('0x6')](_0x21ce58('0x18'),_0x21ce58('0xf'),{'type':_0x4a2c23[_0x21ce58('0x11')],'defaultValue':0x0}),_0x195bbb[_0x21ce58('0x6')]('report_call','mohtime',{'type':_0x4a2c23[_0x21ce58('0x11')],'defaultValue':0x0}),_0x195bbb[_0x21ce58('0x1')]('ALTER\x20TABLE\x20int_vtiger_accounts\x20ENCRYPTION=\x27Y\x27;'),_0x195bbb[_0x21ce58('0x12')](_0x4cb66b);});},'down':function(){}}; \ No newline at end of file +const a949_0x1add=['addIndex\x20%s\x20%s\x20%s','finally','addIndex','catch','enqueue','prototype','addColumn','table\x20dropped\x20%s','changeColumn','util','queryInterface','removeColumn','sequence','inspect','sequelize','removeIndex\x20%s\x20%s','renameColumn','INTEGER','migration','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','query','report_queue','report_call','Changed\x20column\x20%s\x20in\x20table\x20%s','info','then','exports','tail','stringify','dropTable','mohtime'];(function(_0xdaff99,_0x1add2f){const _0x2409af=function(_0x5e6213){while(--_0x5e6213){_0xdaff99['push'](_0xdaff99['shift']());}};_0x2409af(++_0x1add2f);}(a949_0x1add,0x103));const a949_0x2409=function(_0xdaff99,_0x1add2f){_0xdaff99=_0xdaff99-0x0;let _0x2409af=a949_0x1add[_0xdaff99];return _0x2409af;};const _0x391cbb=a949_0x2409;'use strict';const util=require(_0x391cbb('0x1d')),logger=require('../config/logger')(_0x391cbb('0x7')),Sequence=function(){};Sequence['prototype'][_0x391cbb('0x18')]=function(_0x5e6213){const _0x1bef80=_0x391cbb;this[_0x1bef80('0x10')]=this[_0x1bef80('0x10')]?this[_0x1bef80('0x10')][_0x1bef80('0x15')](_0x5e6213):_0x5e6213();};const Migration=function(_0x4fc9a6){const _0xa00ca9=_0x391cbb;this[_0xa00ca9('0x1e')]=_0x4fc9a6,this['sequence']=new Sequence();};Migration['prototype'][_0x391cbb('0x1c')]=function(_0x55028e,_0x53e423,_0xe37a79){const _0x383ef2=_0x391cbb,_0x31629c=this;this[_0x383ef2('0x1')][_0x383ef2('0x18')](function(){const _0x270a8c=_0x383ef2;return _0x31629c[_0x270a8c('0x1e')][_0x270a8c('0x1c')](_0x55028e,_0x53e423,_0xe37a79)[_0x270a8c('0xe')](function(){const _0x3b0240=_0x270a8c;logger[_0x3b0240('0xd')](_0x3b0240('0xc'),_0x53e423,_0x55028e);})[_0x270a8c('0x17')](function(_0x599de7){const _0x5281c4=_0x270a8c;logger[_0x5281c4('0xd')](JSON[_0x5281c4('0x11')](_0x599de7));});});},Migration['prototype'][_0x391cbb('0x1a')]=function(_0x1b5bc1,_0x7a2806,_0x41cd23){const _0x23d357=_0x391cbb,_0x1cea93=this;this[_0x23d357('0x1')]['enqueue'](function(){const _0x2e594e=_0x23d357;return _0x1cea93[_0x2e594e('0x1e')]['addColumn'](_0x1b5bc1,_0x7a2806,_0x41cd23)[_0x2e594e('0xe')](function(){const _0x5aa437=_0x2e594e;logger[_0x5aa437('0xd')]('Added\x20column\x20%s\x20to\x20%s',_0x7a2806,_0x1b5bc1);})[_0x2e594e('0x17')](function(_0xf1e83e){const _0x53fc4b=_0x2e594e;logger[_0x53fc4b('0xd')](JSON[_0x53fc4b('0x11')](_0xf1e83e));});});},Migration[_0x391cbb('0x19')][_0x391cbb('0x12')]=function(_0x3dbb59){const _0xf2f12f=_0x391cbb,_0x492410=this;this[_0xf2f12f('0x1')]['enqueue'](function(){const _0x40fb03=_0xf2f12f;return _0x492410[_0x40fb03('0x1e')]['dropTable'](_0x3dbb59,{'force':!![]})['then'](function(){const _0x32e380=_0x40fb03;logger[_0x32e380('0xd')](_0x32e380('0x1b'),_0x3dbb59);})[_0x40fb03('0x17')](function(_0x175b85){const _0x213533=_0x40fb03;logger['info'](JSON[_0x213533('0x11')](_0x175b85));});});},Migration[_0x391cbb('0x19')][_0x391cbb('0x16')]=function(_0xf7012e,_0x46a1dd,_0x4f4e1a){const _0x2393d8=this;this['sequence']['enqueue'](function(){const _0x592acc=a949_0x2409;return _0x2393d8[_0x592acc('0x1e')]['addIndex'](_0xf7012e,_0x46a1dd,{'indexName':_0x4f4e1a})['then'](function(){const _0x5383c4=_0x592acc;logger[_0x5383c4('0xd')](_0x5383c4('0x14'),_0xf7012e,_0x46a1dd['join'](','),_0x4f4e1a);})['catch'](function(_0x347ca5){const _0x1932c9=_0x592acc;logger[_0x1932c9('0xd')](JSON[_0x1932c9('0x11')](_0x347ca5));});});},Migration[_0x391cbb('0x19')]['removeIndex']=function(_0x43de52,_0x2704ad){const _0x4d55c3=_0x391cbb,_0x730b7d=this;this[_0x4d55c3('0x1')]['enqueue'](function(){const _0xa67372=_0x4d55c3;return _0x730b7d[_0xa67372('0x1e')]['removeIndex'](_0x43de52,_0x2704ad)[_0xa67372('0xe')](function(){const _0x1593fc=_0xa67372;logger['info'](_0x1593fc('0x4'),_0x43de52,_0x2704ad);})['catch'](function(_0x48fc16){const _0x293cc2=_0xa67372;logger[_0x293cc2('0xd')](JSON[_0x293cc2('0x11')](_0x48fc16));});});},Migration[_0x391cbb('0x19')][_0x391cbb('0x9')]=function(_0x26a355){const _0x1bcc09=_0x391cbb,_0x1a82ec=this;this[_0x1bcc09('0x1')][_0x1bcc09('0x18')](function(){const _0x390373=_0x1bcc09;return _0x1a82ec[_0x390373('0x1e')][_0x390373('0x3')][_0x390373('0x9')](_0x26a355)['then'](function(){const _0x42c883=_0x390373;logger[_0x42c883('0xd')]('query\x20%s',_0x26a355);})[_0x390373('0x17')](function(_0x4a0a29){const _0x44a1d3=_0x390373;logger[_0x44a1d3('0xd')](JSON[_0x44a1d3('0x11')](_0x4a0a29));});});},Migration['prototype'][_0x391cbb('0x0')]=function(_0x5933a4,_0x43d94e){const _0x3e44d2=_0x391cbb,_0x5484fe=this;this[_0x3e44d2('0x1')][_0x3e44d2('0x18')](function(){const _0x328c6b=_0x3e44d2;return _0x5484fe[_0x328c6b('0x1e')]['removeColumn'](_0x5933a4,_0x43d94e)['then'](function(){const _0x53d147=_0x328c6b;logger[_0x53d147('0xd')]('Removed\x20column\x20%s\x20from\x20%s',_0x43d94e,_0x5933a4);})[_0x328c6b('0x17')](function(_0x45a07f){const _0x20787f=_0x328c6b;logger[_0x20787f('0xd')](util[_0x20787f('0x2')](_0x45a07f,{'showHidden':![],'depth':null}));});});},Migration[_0x391cbb('0x19')][_0x391cbb('0x5')]=function(_0xbedcd5,_0x37eb2c,_0x583353){const _0x3026cd=_0x391cbb,_0x113cd2=this;this[_0x3026cd('0x1')]['enqueue'](function(){const _0x18c13e=_0x3026cd;return _0x113cd2[_0x18c13e('0x1e')]['renameColumn'](_0xbedcd5,_0x37eb2c,_0x583353)[_0x18c13e('0xe')](function(){const _0xdb01fa=_0x18c13e;logger[_0xdb01fa('0xd')](_0xdb01fa('0x8'),_0x37eb2c,_0x583353,_0xbedcd5);})['catch'](function(_0x16b9a3){const _0x44550a=_0x18c13e;logger[_0x44550a('0xd')](util[_0x44550a('0x2')](_0x16b9a3,{'showHidden':![],'depth':null}));});});},Migration[_0x391cbb('0x19')]['final']=function(_0x164fcf){const _0x56128f=_0x391cbb;this[_0x56128f('0x1')][_0x56128f('0x18')](function(){return _0x164fcf();});},module[_0x391cbb('0xf')]={'up':function(_0x8cdf7,_0x2585cb){return new Promise(function(_0x8f48ea){const _0x172148=a949_0x2409,_0x2ce2b6=new Migration(_0x8cdf7);_0x2ce2b6['addColumn'](_0x172148('0xa'),'mohtime',{'type':_0x2585cb[_0x172148('0x6')],'defaultValue':0x0}),_0x2ce2b6[_0x172148('0x1a')](_0x172148('0xb'),_0x172148('0x13'),{'type':_0x2585cb[_0x172148('0x6')],'defaultValue':0x0}),_0x2ce2b6[_0x172148('0x9')]('ALTER\x20TABLE\x20int_vtiger_accounts\x20ENCRYPTION=\x27Y\x27;'),_0x2ce2b6['final'](_0x8f48ea);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.71.js b/server/migrations/2.0.71.js index d44efa1..5bd4cd6 100644 --- a/server/migrations/2.0.71.js +++ b/server/migrations/2.0.71.js @@ -1 +1 @@ -const a950_0x16dd=['dropTable','Added\x20column\x20%s\x20to\x20%s','query','BOOLEAN','addIndex','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','query\x20%s','chatTimeout','INTEGER','chat_websites','sequelize','renameColumn','util','systemAvatar','catch','addColumn','prototype','agentTransfer','stringify','sequence','final','phoneBarRememberMeEnabled','queueTransferTimeout','finally','agentTransferTimeout','changeColumn','tail','inspect','TEXT','license','Removed\x20column\x20%s\x20from\x20%s','openchannel_accounts','Changed\x20column\x20%s\x20in\x20table\x20%s','data7','enableCustomerCheckmarks','STRING','queryInterface','tools_actions','sms_accounts','enqueue','settings','removeIndex\x20%s\x20%s','systemAlias','info','exports','join','then','fax_accounts','table\x20dropped\x20%s','queueTransfer','addIndex\x20%s\x20%s\x20%s'];(function(_0x576d2f,_0x16dd12){const _0x58e103=function(_0x593320){while(--_0x593320){_0x576d2f['push'](_0x576d2f['shift']());}};_0x58e103(++_0x16dd12);}(a950_0x16dd,0x10f));const a950_0x58e1=function(_0x576d2f,_0x16dd12){_0x576d2f=_0x576d2f-0x0;let _0x58e103=a950_0x16dd[_0x576d2f];return _0x58e103;};const _0x3ef18d=a950_0x58e1;'use strict';const util=require(_0x3ef18d('0x2f')),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence[_0x3ef18d('0x0')][_0x3ef18d('0x17')]=function(_0x593320){const _0xe73767=_0x3ef18d;this[_0xe73767('0xa')]=this['tail']?this['tail'][_0xe73767('0x7')](_0x593320):_0x593320();};const Migration=function(_0x5b941a){const _0x3df15e=_0x3ef18d;this[_0x3df15e('0x14')]=_0x5b941a,this[_0x3df15e('0x3')]=new Sequence();};Migration[_0x3ef18d('0x0')][_0x3ef18d('0x9')]=function(_0x375b3b,_0x331bb5,_0x533c5f){const _0x42405a=_0x3ef18d,_0x4f8bf7=this;this[_0x42405a('0x3')][_0x42405a('0x17')](function(){const _0x17d90d=_0x42405a;return _0x4f8bf7[_0x17d90d('0x14')][_0x17d90d('0x9')](_0x375b3b,_0x331bb5,_0x533c5f)[_0x17d90d('0x1e')](function(){const _0x38b93a=_0x17d90d;logger[_0x38b93a('0x1b')](_0x38b93a('0x10'),_0x331bb5,_0x375b3b);})[_0x17d90d('0x31')](function(_0x5f1db9){const _0x183644=_0x17d90d;logger['info'](JSON[_0x183644('0x2')](_0x5f1db9));});});},Migration[_0x3ef18d('0x0')][_0x3ef18d('0x32')]=function(_0x4bd3a6,_0x39fcf7,_0x3eff60){const _0x5a106f=this;this['sequence']['enqueue'](function(){const _0x1b3ffc=a950_0x58e1;return _0x5a106f[_0x1b3ffc('0x14')][_0x1b3ffc('0x32')](_0x4bd3a6,_0x39fcf7,_0x3eff60)['then'](function(){const _0x5f1934=_0x1b3ffc;logger[_0x5f1934('0x1b')](_0x5f1934('0x24'),_0x39fcf7,_0x4bd3a6);})[_0x1b3ffc('0x31')](function(_0xddec9b){const _0xde554e=_0x1b3ffc;logger[_0xde554e('0x1b')](JSON[_0xde554e('0x2')](_0xddec9b));});});},Migration[_0x3ef18d('0x0')][_0x3ef18d('0x23')]=function(_0x2c1e7c){const _0x64029d=_0x3ef18d,_0x27b670=this;this[_0x64029d('0x3')][_0x64029d('0x17')](function(){const _0x141a6b=_0x64029d;return _0x27b670[_0x141a6b('0x14')]['dropTable'](_0x2c1e7c,{'force':!![]})[_0x141a6b('0x1e')](function(){const _0x299467=_0x141a6b;logger['info'](_0x299467('0x20'),_0x2c1e7c);})[_0x141a6b('0x31')](function(_0x17f820){const _0x1d6ade=_0x141a6b;logger['info'](JSON[_0x1d6ade('0x2')](_0x17f820));});});},Migration[_0x3ef18d('0x0')][_0x3ef18d('0x27')]=function(_0x2d281a,_0x4afb34,_0x4b0ae8){const _0x22dfc4=_0x3ef18d,_0x33dc61=this;this[_0x22dfc4('0x3')][_0x22dfc4('0x17')](function(){const _0x35d56a=_0x22dfc4;return _0x33dc61[_0x35d56a('0x14')][_0x35d56a('0x27')](_0x2d281a,_0x4afb34,{'indexName':_0x4b0ae8})[_0x35d56a('0x1e')](function(){const _0x2f047a=_0x35d56a;logger[_0x2f047a('0x1b')](_0x2f047a('0x22'),_0x2d281a,_0x4afb34[_0x2f047a('0x1d')](','),_0x4b0ae8);})[_0x35d56a('0x31')](function(_0x1cd7a1){const _0x8d0d98=_0x35d56a;logger['info'](JSON[_0x8d0d98('0x2')](_0x1cd7a1));});});},Migration[_0x3ef18d('0x0')]['removeIndex']=function(_0x1cae2f,_0xc9af55){const _0x128328=_0x3ef18d,_0x378db3=this;this[_0x128328('0x3')][_0x128328('0x17')](function(){const _0x5eccb8=_0x128328;return _0x378db3[_0x5eccb8('0x14')]['removeIndex'](_0x1cae2f,_0xc9af55)['then'](function(){const _0xd47df1=_0x5eccb8;logger[_0xd47df1('0x1b')](_0xd47df1('0x19'),_0x1cae2f,_0xc9af55);})[_0x5eccb8('0x31')](function(_0x1d674f){const _0x44aaef=_0x5eccb8;logger[_0x44aaef('0x1b')](JSON[_0x44aaef('0x2')](_0x1d674f));});});},Migration[_0x3ef18d('0x0')][_0x3ef18d('0x25')]=function(_0x4da107){const _0x412596=_0x3ef18d,_0x473f52=this;this[_0x412596('0x3')][_0x412596('0x17')](function(){const _0x50acf3=_0x412596;return _0x473f52[_0x50acf3('0x14')][_0x50acf3('0x2d')]['query'](_0x4da107)[_0x50acf3('0x1e')](function(){const _0x4ee40d=_0x50acf3;logger[_0x4ee40d('0x1b')](_0x4ee40d('0x29'),_0x4da107);})[_0x50acf3('0x31')](function(_0x341358){const _0x4031a2=_0x50acf3;logger[_0x4031a2('0x1b')](JSON[_0x4031a2('0x2')](_0x341358));});});},Migration[_0x3ef18d('0x0')]['removeColumn']=function(_0x409300,_0x4563f1){const _0x3816ed=_0x3ef18d,_0x5555cf=this;this['sequence'][_0x3816ed('0x17')](function(){const _0x78fe20=_0x3816ed;return _0x5555cf[_0x78fe20('0x14')]['removeColumn'](_0x409300,_0x4563f1)[_0x78fe20('0x1e')](function(){const _0x4af8b6=_0x78fe20;logger[_0x4af8b6('0x1b')](_0x4af8b6('0xe'),_0x4563f1,_0x409300);})[_0x78fe20('0x31')](function(_0x102a96){const _0x27e5f2=_0x78fe20;logger[_0x27e5f2('0x1b')](util[_0x27e5f2('0xb')](_0x102a96,{'showHidden':![],'depth':null}));});});},Migration[_0x3ef18d('0x0')][_0x3ef18d('0x2e')]=function(_0x325c2d,_0x3f44ad,_0x122ab8){const _0x3ec845=_0x3ef18d,_0x329595=this;this[_0x3ec845('0x3')][_0x3ec845('0x17')](function(){const _0x41571d=_0x3ec845;return _0x329595[_0x41571d('0x14')][_0x41571d('0x2e')](_0x325c2d,_0x3f44ad,_0x122ab8)['then'](function(){const _0x53bd9f=_0x41571d;logger[_0x53bd9f('0x1b')](_0x53bd9f('0x28'),_0x3f44ad,_0x122ab8,_0x325c2d);})[_0x41571d('0x31')](function(_0x33d369){const _0xd6a0f3=_0x41571d;logger[_0xd6a0f3('0x1b')](util['inspect'](_0x33d369,{'showHidden':![],'depth':null}));});});},Migration[_0x3ef18d('0x0')]['final']=function(_0x3b8562){const _0x52f918=_0x3ef18d;this[_0x52f918('0x3')][_0x52f918('0x17')](function(){return _0x3b8562();});},module[_0x3ef18d('0x1c')]={'up':function(_0x3f6481,_0x373007){return new Promise(function(_0x10df1b){const _0x2bfa67=a950_0x58e1,_0x1fb3e8=new Migration(_0x3f6481);_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x2c'),_0x2bfa67('0x21'),{'type':_0x373007[_0x2bfa67('0x26')],'defaultValue':![]}),_0x1fb3e8[_0x2bfa67('0x32')]('chat_websites',_0x2bfa67('0x12'),{'type':_0x373007[_0x2bfa67('0x26')],'defaultValue':![]}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x2c'),_0x2bfa67('0x6'),{'type':_0x373007[_0x2bfa67('0x2b')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x2c'),_0x2bfa67('0x1'),{'type':_0x373007[_0x2bfa67('0x26')],'defaultValue':![]}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x2c'),_0x2bfa67('0x8'),{'type':_0x373007[_0x2bfa67('0x2b')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x1fb3e8[_0x2bfa67('0x32')]('chat_websites',_0x2bfa67('0x1a'),{'type':_0x373007[_0x2bfa67('0x13')],'defaultValue':'System'}),_0x1fb3e8['addColumn']('chat_websites',_0x2bfa67('0x30'),{'type':_0x373007[_0x2bfa67('0xc')]}),_0x1fb3e8[_0x2bfa67('0x32')]('fax_accounts',_0x2bfa67('0x21'),{'type':_0x373007[_0x2bfa67('0x26')],'defaultValue':![]}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x1f'),_0x2bfa67('0x6'),{'type':_0x373007[_0x2bfa67('0x2b')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x1f'),'agentTransfer',{'type':_0x373007[_0x2bfa67('0x26')],'defaultValue':![]}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x1f'),_0x2bfa67('0x8'),{'type':_0x373007['INTEGER'],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0xf'),'queueTransfer',{'type':_0x373007[_0x2bfa67('0x26')],'defaultValue':![]}),_0x1fb3e8['addColumn'](_0x2bfa67('0xf'),_0x2bfa67('0x6'),{'type':_0x373007[_0x2bfa67('0x2b')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x1fb3e8[_0x2bfa67('0x32')]('openchannel_accounts',_0x2bfa67('0x1'),{'type':_0x373007[_0x2bfa67('0x26')],'defaultValue':![]}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0xf'),_0x2bfa67('0x8'),{'type':_0x373007[_0x2bfa67('0x2b')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x1fb3e8['addColumn'](_0x2bfa67('0x16'),_0x2bfa67('0x21'),{'type':_0x373007['BOOLEAN'],'defaultValue':![]}),_0x1fb3e8[_0x2bfa67('0x32')]('sms_accounts',_0x2bfa67('0x6'),{'type':_0x373007[_0x2bfa67('0x2b')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x16'),_0x2bfa67('0x1'),{'type':_0x373007['BOOLEAN'],'defaultValue':![]}),_0x1fb3e8[_0x2bfa67('0x32')]('sms_accounts',_0x2bfa67('0x8'),{'type':_0x373007[_0x2bfa67('0x2b')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x18'),_0x2bfa67('0x2a'),{'type':_0x373007[_0x2bfa67('0x2b')],'defaultValue':0x1e}),_0x1fb3e8[_0x2bfa67('0x25')]('UPDATE\x20settings\x20SET\x20chatTimeout\x20=\x200;'),_0x1fb3e8[_0x2bfa67('0x32')]('settings',_0x2bfa67('0x5'),{'type':_0x373007[_0x2bfa67('0x26')],'defaultValue':!![]}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0xd'),'chatLicenseExceeded',{'type':_0x373007[_0x2bfa67('0x2b')],'defaultValue':0x0}),_0x1fb3e8[_0x2bfa67('0x32')](_0x2bfa67('0x15'),_0x2bfa67('0x11'),{'type':_0x373007[_0x2bfa67('0xc')]}),_0x1fb3e8[_0x2bfa67('0x4')](_0x10df1b);});},'down':function(){}}; \ No newline at end of file +const a950_0xf60e=['catch','chat_websites','data7','sequelize','sms_accounts','table\x20dropped\x20%s','chatLicenseExceeded','Changed\x20column\x20%s\x20in\x20table\x20%s','final','prototype','changeColumn','removeIndex','enqueue','TEXT','tail','exports','queueTransferTimeout','sequence','phoneBarRememberMeEnabled','addColumn','Removed\x20column\x20%s\x20from\x20%s','BOOLEAN','query','systemAlias','queryInterface','Added\x20column\x20%s\x20to\x20%s','agentTransferTimeout','chatTimeout','enableCustomerCheckmarks','systemAvatar','then','stringify','queueTransfer','util','migration','finally','agentTransfer','openchannel_accounts','UPDATE\x20settings\x20SET\x20chatTimeout\x20=\x200;','removeColumn','info','dropTable','license','query\x20%s','addIndex','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','INTEGER','settings','System','../config/logger','fax_accounts','STRING','removeIndex\x20%s\x20%s'];(function(_0x235c8a,_0xf60e2){const _0x3b218f=function(_0x4ad967){while(--_0x4ad967){_0x235c8a['push'](_0x235c8a['shift']());}};_0x3b218f(++_0xf60e2);}(a950_0xf60e,0xaa));const a950_0x3b21=function(_0x235c8a,_0xf60e2){_0x235c8a=_0x235c8a-0x0;let _0x3b218f=a950_0xf60e[_0x235c8a];return _0x3b218f;};const _0x219554=a950_0x3b21;'use strict';const util=require(_0x219554('0x16')),logger=require(_0x219554('0x26'))(_0x219554('0x17')),Sequence=function(){};Sequence['prototype'][_0x219554('0x1')]=function(_0x4ad967){const _0x947367=_0x219554;this['tail']=this[_0x947367('0x3')]?this[_0x947367('0x3')][_0x947367('0x18')](_0x4ad967):_0x4ad967();};const Migration=function(_0x489fcd){this['queryInterface']=_0x489fcd,this['sequence']=new Sequence();};Migration[_0x219554('0x33')]['changeColumn']=function(_0x34ff5d,_0x146232,_0x57b963){const _0x299d66=_0x219554,_0xaae818=this;this[_0x299d66('0x6')][_0x299d66('0x1')](function(){const _0x402dc8=_0x299d66;return _0xaae818[_0x402dc8('0xd')][_0x402dc8('0x34')](_0x34ff5d,_0x146232,_0x57b963)[_0x402dc8('0x13')](function(){const _0x1af403=_0x402dc8;logger['info'](_0x1af403('0x31'),_0x146232,_0x34ff5d);})[_0x402dc8('0x2a')](function(_0xbb8429){logger['info'](JSON['stringify'](_0xbb8429));});});},Migration[_0x219554('0x33')][_0x219554('0x8')]=function(_0x35722e,_0x4c6815,_0x3fb60e){const _0x244dd6=_0x219554,_0x1fbedc=this;this[_0x244dd6('0x6')][_0x244dd6('0x1')](function(){const _0x829d60=_0x244dd6;return _0x1fbedc[_0x829d60('0xd')]['addColumn'](_0x35722e,_0x4c6815,_0x3fb60e)[_0x829d60('0x13')](function(){const _0x341b14=_0x829d60;logger[_0x341b14('0x1d')](_0x341b14('0xe'),_0x4c6815,_0x35722e);})['catch'](function(_0x24c0a9){const _0x5137bb=_0x829d60;logger[_0x5137bb('0x1d')](JSON['stringify'](_0x24c0a9));});});},Migration['prototype'][_0x219554('0x1e')]=function(_0x161e80){const _0x34eaa9=_0x219554,_0x5ce9c3=this;this[_0x34eaa9('0x6')]['enqueue'](function(){const _0x4eabd6=_0x34eaa9;return _0x5ce9c3[_0x4eabd6('0xd')][_0x4eabd6('0x1e')](_0x161e80,{'force':!![]})[_0x4eabd6('0x13')](function(){const _0x1ae8e4=_0x4eabd6;logger[_0x1ae8e4('0x1d')](_0x1ae8e4('0x2f'),_0x161e80);})[_0x4eabd6('0x2a')](function(_0x376bae){const _0x5ac767=_0x4eabd6;logger[_0x5ac767('0x1d')](JSON[_0x5ac767('0x14')](_0x376bae));});});},Migration['prototype'][_0x219554('0x21')]=function(_0x19e7a5,_0xef9367,_0xe3dd23){const _0x3e2b75=_0x219554,_0x1e1d1e=this;this[_0x3e2b75('0x6')]['enqueue'](function(){const _0x2ce16b=_0x3e2b75;return _0x1e1d1e[_0x2ce16b('0xd')][_0x2ce16b('0x21')](_0x19e7a5,_0xef9367,{'indexName':_0xe3dd23})['then'](function(){const _0x4c02b0=_0x2ce16b;logger[_0x4c02b0('0x1d')]('addIndex\x20%s\x20%s\x20%s',_0x19e7a5,_0xef9367['join'](','),_0xe3dd23);})[_0x2ce16b('0x2a')](function(_0x1a83a7){const _0x360bad=_0x2ce16b;logger[_0x360bad('0x1d')](JSON[_0x360bad('0x14')](_0x1a83a7));});});},Migration[_0x219554('0x33')][_0x219554('0x0')]=function(_0x24d390,_0x91eb39){const _0xd64e46=_0x219554,_0x15ca99=this;this[_0xd64e46('0x6')][_0xd64e46('0x1')](function(){const _0x175023=_0xd64e46;return _0x15ca99[_0x175023('0xd')][_0x175023('0x0')](_0x24d390,_0x91eb39)['then'](function(){const _0xf26ea8=_0x175023;logger[_0xf26ea8('0x1d')](_0xf26ea8('0x29'),_0x24d390,_0x91eb39);})['catch'](function(_0x164ce6){const _0x3d4fee=_0x175023;logger[_0x3d4fee('0x1d')](JSON['stringify'](_0x164ce6));});});},Migration[_0x219554('0x33')][_0x219554('0xb')]=function(_0x20097c){const _0x456dc1=_0x219554,_0x2d05f6=this;this[_0x456dc1('0x6')][_0x456dc1('0x1')](function(){const _0x3f57ff=_0x456dc1;return _0x2d05f6['queryInterface'][_0x3f57ff('0x2d')]['query'](_0x20097c)['then'](function(){const _0x425f16=_0x3f57ff;logger['info'](_0x425f16('0x20'),_0x20097c);})[_0x3f57ff('0x2a')](function(_0x13ef10){const _0x407176=_0x3f57ff;logger['info'](JSON[_0x407176('0x14')](_0x13ef10));});});},Migration[_0x219554('0x33')][_0x219554('0x1c')]=function(_0x2a69a1,_0x1a4871){const _0x4dacd2=_0x219554,_0x35a99c=this;this[_0x4dacd2('0x6')]['enqueue'](function(){const _0x524bcb=_0x4dacd2;return _0x35a99c[_0x524bcb('0xd')][_0x524bcb('0x1c')](_0x2a69a1,_0x1a4871)[_0x524bcb('0x13')](function(){const _0x3df6d5=_0x524bcb;logger['info'](_0x3df6d5('0x9'),_0x1a4871,_0x2a69a1);})[_0x524bcb('0x2a')](function(_0x39f84a){logger['info'](util['inspect'](_0x39f84a,{'showHidden':![],'depth':null}));});});},Migration[_0x219554('0x33')]['renameColumn']=function(_0x432b9d,_0x356db5,_0x496f60){const _0x56a88c=_0x219554,_0x498ff4=this;this[_0x56a88c('0x6')][_0x56a88c('0x1')](function(){const _0x4a5204=_0x56a88c;return _0x498ff4['queryInterface']['renameColumn'](_0x432b9d,_0x356db5,_0x496f60)[_0x4a5204('0x13')](function(){const _0x5b378e=_0x4a5204;logger[_0x5b378e('0x1d')](_0x5b378e('0x22'),_0x356db5,_0x496f60,_0x432b9d);})[_0x4a5204('0x2a')](function(_0x366ce1){const _0x54fa2b=_0x4a5204;logger[_0x54fa2b('0x1d')](util['inspect'](_0x366ce1,{'showHidden':![],'depth':null}));});});},Migration[_0x219554('0x33')][_0x219554('0x32')]=function(_0x59d9e7){const _0x345f7b=_0x219554;this[_0x345f7b('0x6')][_0x345f7b('0x1')](function(){return _0x59d9e7();});},module[_0x219554('0x4')]={'up':function(_0xd9569,_0x335045){return new Promise(function(_0x171744){const _0x2090a1=a950_0x3b21,_0x443d98=new Migration(_0xd9569);_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x2b'),_0x2090a1('0x15'),{'type':_0x335045[_0x2090a1('0xa')],'defaultValue':![]}),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x2b'),_0x2090a1('0x11'),{'type':_0x335045[_0x2090a1('0xa')],'defaultValue':![]}),_0x443d98['addColumn']('chat_websites',_0x2090a1('0x5'),{'type':_0x335045[_0x2090a1('0x23')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x443d98[_0x2090a1('0x8')]('chat_websites','agentTransfer',{'type':_0x335045[_0x2090a1('0xa')],'defaultValue':![]}),_0x443d98['addColumn']('chat_websites',_0x2090a1('0xf'),{'type':_0x335045[_0x2090a1('0x23')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x2b'),_0x2090a1('0xc'),{'type':_0x335045[_0x2090a1('0x28')],'defaultValue':_0x2090a1('0x25')}),_0x443d98['addColumn'](_0x2090a1('0x2b'),_0x2090a1('0x12'),{'type':_0x335045['TEXT']}),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x27'),'queueTransfer',{'type':_0x335045[_0x2090a1('0xa')],'defaultValue':![]}),_0x443d98[_0x2090a1('0x8')]('fax_accounts',_0x2090a1('0x5'),{'type':_0x335045[_0x2090a1('0x23')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x443d98[_0x2090a1('0x8')]('fax_accounts',_0x2090a1('0x19'),{'type':_0x335045[_0x2090a1('0xa')],'defaultValue':![]}),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x27'),_0x2090a1('0xf'),{'type':_0x335045[_0x2090a1('0x23')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x1a'),'queueTransfer',{'type':_0x335045['BOOLEAN'],'defaultValue':![]}),_0x443d98['addColumn'](_0x2090a1('0x1a'),_0x2090a1('0x5'),{'type':_0x335045[_0x2090a1('0x23')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x443d98[_0x2090a1('0x8')]('openchannel_accounts',_0x2090a1('0x19'),{'type':_0x335045[_0x2090a1('0xa')],'defaultValue':![]}),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x1a'),_0x2090a1('0xf'),{'type':_0x335045['INTEGER'],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x2e'),_0x2090a1('0x15'),{'type':_0x335045[_0x2090a1('0xa')],'defaultValue':![]}),_0x443d98['addColumn'](_0x2090a1('0x2e'),_0x2090a1('0x5'),{'type':_0x335045[_0x2090a1('0x23')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x2e'),_0x2090a1('0x19'),{'type':_0x335045[_0x2090a1('0xa')],'defaultValue':![]}),_0x443d98[_0x2090a1('0x8')]('sms_accounts',_0x2090a1('0xf'),{'type':_0x335045[_0x2090a1('0x23')],'validate':{'min':0x1,'max':0x20c49b},'defaultValue':0x12c}),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x24'),_0x2090a1('0x10'),{'type':_0x335045[_0x2090a1('0x23')],'defaultValue':0x1e}),_0x443d98[_0x2090a1('0xb')](_0x2090a1('0x1b')),_0x443d98[_0x2090a1('0x8')](_0x2090a1('0x24'),_0x2090a1('0x7'),{'type':_0x335045[_0x2090a1('0xa')],'defaultValue':!![]}),_0x443d98['addColumn'](_0x2090a1('0x1f'),_0x2090a1('0x30'),{'type':_0x335045[_0x2090a1('0x23')],'defaultValue':0x0}),_0x443d98['addColumn']('tools_actions',_0x2090a1('0x2c'),{'type':_0x335045[_0x2090a1('0x2')]}),_0x443d98[_0x2090a1('0x32')](_0x171744);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.72.js b/server/migrations/2.0.72.js index 73457ae..b1f4c66 100644 --- a/server/migrations/2.0.72.js +++ b/server/migrations/2.0.72.js @@ -1 +1 @@ -const a951_0x21c5=['dropTable','final','addIndex\x20%s\x20%s\x20%s','enqueue','exports','sequelize','util','leaveAt','tail','table\x20dropped\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','inspect','addIndex','migration','uniqueid','removeIndex\x20%s\x20%s','catch','DELETE\x20FROM\x20user_has_voice_queues_rt\x20WHERE\x20UserId\x20NOT\x20IN\x20(SELECT\x20id\x20FROM\x20users\x20WHERE\x20role\x20=\x20\x27agent\x27)','stringify','../config/logger','query\x20%s','renameColumn','finally','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','changeColumn','query','project_name','info','sequence','report_square','prototype','queryInterface','Added\x20column\x20%s\x20to\x20%s','Removed\x20column\x20%s\x20from\x20%s','uid_pname','then','removeIndex','removeColumn','addColumn'];(function(_0x44ffc4,_0x21c5e6){const _0x44967f=function(_0xd7c8da){while(--_0xd7c8da){_0x44ffc4['push'](_0x44ffc4['shift']());}};_0x44967f(++_0x21c5e6);}(a951_0x21c5,0x1d2));const a951_0x4496=function(_0x44ffc4,_0x21c5e6){_0x44ffc4=_0x44ffc4-0x0;let _0x44967f=a951_0x21c5[_0x44ffc4];return _0x44967f;};const _0x1c1875=a951_0x4496;'use strict';const util=require(_0x1c1875('0x8')),logger=require(_0x1c1875('0x15'))(_0x1c1875('0xf')),Sequence=function(){};Sequence['prototype'][_0x1c1875('0x5')]=function(_0xd7c8da){const _0x25d2f7=_0x1c1875;this[_0x25d2f7('0xa')]=this[_0x25d2f7('0xa')]?this['tail'][_0x25d2f7('0x18')](_0xd7c8da):_0xd7c8da();};const Migration=function(_0x2a6305){const _0x39a8d4=_0x1c1875;this['queryInterface']=_0x2a6305,this[_0x39a8d4('0x1e')]=new Sequence();};Migration[_0x1c1875('0x20')][_0x1c1875('0x1a')]=function(_0x32eb57,_0x1e37c9,_0x5d1cbe){const _0x9af8e6=_0x1c1875,_0x39b635=this;this[_0x9af8e6('0x1e')][_0x9af8e6('0x5')](function(){const _0x4f8d9e=_0x9af8e6;return _0x39b635[_0x4f8d9e('0x21')][_0x4f8d9e('0x1a')](_0x32eb57,_0x1e37c9,_0x5d1cbe)['then'](function(){const _0x50195e=_0x4f8d9e;logger[_0x50195e('0x1d')](_0x50195e('0xc'),_0x1e37c9,_0x32eb57);})[_0x4f8d9e('0x12')](function(_0x5e5fe4){const _0x22f81f=_0x4f8d9e;logger['info'](JSON[_0x22f81f('0x14')](_0x5e5fe4));});});},Migration[_0x1c1875('0x20')][_0x1c1875('0x1')]=function(_0x2b8047,_0x46e407,_0x49c38c){const _0x543c0d=_0x1c1875,_0xe35996=this;this[_0x543c0d('0x1e')][_0x543c0d('0x5')](function(){const _0x5de3d6=_0x543c0d;return _0xe35996[_0x5de3d6('0x21')][_0x5de3d6('0x1')](_0x2b8047,_0x46e407,_0x49c38c)[_0x5de3d6('0x25')](function(){const _0x3ff1ec=_0x5de3d6;logger[_0x3ff1ec('0x1d')](_0x3ff1ec('0x22'),_0x46e407,_0x2b8047);})[_0x5de3d6('0x12')](function(_0xcfe83d){const _0x492fe4=_0x5de3d6;logger[_0x492fe4('0x1d')](JSON[_0x492fe4('0x14')](_0xcfe83d));});});},Migration[_0x1c1875('0x20')][_0x1c1875('0x2')]=function(_0x15b88b){const _0x141590=_0x1c1875,_0x683521=this;this[_0x141590('0x1e')][_0x141590('0x5')](function(){const _0x3e7310=_0x141590;return _0x683521[_0x3e7310('0x21')][_0x3e7310('0x2')](_0x15b88b,{'force':!![]})[_0x3e7310('0x25')](function(){const _0x491cf2=_0x3e7310;logger[_0x491cf2('0x1d')](_0x491cf2('0xb'),_0x15b88b);})[_0x3e7310('0x12')](function(_0x5901f9){const _0x429af6=_0x3e7310;logger[_0x429af6('0x1d')](JSON[_0x429af6('0x14')](_0x5901f9));});});},Migration['prototype'][_0x1c1875('0xe')]=function(_0x2f8d3e,_0x3beb76,_0x330519){const _0x5c9b18=_0x1c1875,_0x250eaf=this;this[_0x5c9b18('0x1e')][_0x5c9b18('0x5')](function(){const _0x3de77c=_0x5c9b18;return _0x250eaf[_0x3de77c('0x21')][_0x3de77c('0xe')](_0x2f8d3e,_0x3beb76,{'indexName':_0x330519})['then'](function(){const _0x1977ae=_0x3de77c;logger[_0x1977ae('0x1d')](_0x1977ae('0x4'),_0x2f8d3e,_0x3beb76['join'](','),_0x330519);})[_0x3de77c('0x12')](function(_0x53368d){const _0x26f1c0=_0x3de77c;logger[_0x26f1c0('0x1d')](JSON[_0x26f1c0('0x14')](_0x53368d));});});},Migration[_0x1c1875('0x20')][_0x1c1875('0x26')]=function(_0x3c9a7,_0x384b2e){const _0x3ca460=_0x1c1875,_0x385500=this;this[_0x3ca460('0x1e')][_0x3ca460('0x5')](function(){const _0x86284=_0x3ca460;return _0x385500['queryInterface']['removeIndex'](_0x3c9a7,_0x384b2e)[_0x86284('0x25')](function(){const _0x5840e1=_0x86284;logger['info'](_0x5840e1('0x11'),_0x3c9a7,_0x384b2e);})[_0x86284('0x12')](function(_0xd7d627){const _0x1262fe=_0x86284;logger['info'](JSON[_0x1262fe('0x14')](_0xd7d627));});});},Migration['prototype']['query']=function(_0x37c827){const _0x4b24d7=_0x1c1875,_0x517100=this;this[_0x4b24d7('0x1e')][_0x4b24d7('0x5')](function(){const _0x215e9=_0x4b24d7;return _0x517100[_0x215e9('0x21')][_0x215e9('0x7')][_0x215e9('0x1b')](_0x37c827)['then'](function(){const _0x3b17a1=_0x215e9;logger[_0x3b17a1('0x1d')](_0x3b17a1('0x16'),_0x37c827);})[_0x215e9('0x12')](function(_0x543a06){const _0x1e2593=_0x215e9;logger[_0x1e2593('0x1d')](JSON[_0x1e2593('0x14')](_0x543a06));});});},Migration['prototype'][_0x1c1875('0x0')]=function(_0x4a397c,_0x3fed08){const _0xc2e30=_0x1c1875,_0x1495dc=this;this['sequence'][_0xc2e30('0x5')](function(){const _0x17f40b=_0xc2e30;return _0x1495dc['queryInterface']['removeColumn'](_0x4a397c,_0x3fed08)[_0x17f40b('0x25')](function(){const _0x6c8be2=_0x17f40b;logger['info'](_0x6c8be2('0x23'),_0x3fed08,_0x4a397c);})[_0x17f40b('0x12')](function(_0x4606ee){const _0x3c89f6=_0x17f40b;logger[_0x3c89f6('0x1d')](util[_0x3c89f6('0xd')](_0x4606ee,{'showHidden':![],'depth':null}));});});},Migration[_0x1c1875('0x20')][_0x1c1875('0x17')]=function(_0x92941f,_0x280f45,_0x1bf531){const _0x5accb8=_0x1c1875,_0x1fc041=this;this[_0x5accb8('0x1e')][_0x5accb8('0x5')](function(){const _0x2382b2=_0x5accb8;return _0x1fc041[_0x2382b2('0x21')][_0x2382b2('0x17')](_0x92941f,_0x280f45,_0x1bf531)[_0x2382b2('0x25')](function(){const _0x50fce8=_0x2382b2;logger['info'](_0x50fce8('0x19'),_0x280f45,_0x1bf531,_0x92941f);})[_0x2382b2('0x12')](function(_0x520009){const _0x2c684c=_0x2382b2;logger[_0x2c684c('0x1d')](util[_0x2c684c('0xd')](_0x520009,{'showHidden':![],'depth':null}));});});},Migration[_0x1c1875('0x20')][_0x1c1875('0x3')]=function(_0x230514){const _0x5816bc=_0x1c1875;this[_0x5816bc('0x1e')]['enqueue'](function(){return _0x230514();});},module[_0x1c1875('0x6')]={'up':function(_0x3bc167){return new Promise(function(_0x4cf187){const _0xf418a0=a951_0x4496,_0x37e854=new Migration(_0x3bc167);_0x37e854[_0xf418a0('0x1b')](_0xf418a0('0x13')),_0x37e854[_0xf418a0('0xe')]('report_square',[_0xf418a0('0x10'),_0xf418a0('0x1c')],_0xf418a0('0x24')),_0x37e854[_0xf418a0('0xe')](_0xf418a0('0x1f'),['leaveAt'],_0xf418a0('0x9')),_0x37e854['final'](_0x4cf187);});},'down':function(){}}; \ No newline at end of file +const a951_0x2f81=['removeIndex','sequence','sequelize','Added\x20column\x20%s\x20to\x20%s','enqueue','stringify','tail','../config/logger','leaveAt','query','finally','report_square','prototype','addIndex\x20%s\x20%s\x20%s','removeIndex\x20%s\x20%s','DELETE\x20FROM\x20user_has_voice_queues_rt\x20WHERE\x20UserId\x20NOT\x20IN\x20(SELECT\x20id\x20FROM\x20users\x20WHERE\x20role\x20=\x20\x27agent\x27)','uid_pname','addColumn','exports','info','project_name','changeColumn','dropTable','addIndex','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','queryInterface','migration','catch','inspect','final','then'];(function(_0x1c4a4b,_0x2f8192){const _0x475ec4=function(_0x3c4c9e){while(--_0x3c4c9e){_0x1c4a4b['push'](_0x1c4a4b['shift']());}};_0x475ec4(++_0x2f8192);}(a951_0x2f81,0x141));const a951_0x475e=function(_0x1c4a4b,_0x2f8192){_0x1c4a4b=_0x1c4a4b-0x0;let _0x475ec4=a951_0x2f81[_0x1c4a4b];return _0x475ec4;};const _0x1ceea3=a951_0x475e;'use strict';const util=require('util'),logger=require(_0x1ceea3('0x1b'))(_0x1ceea3('0xf')),Sequence=function(){};Sequence[_0x1ceea3('0x1')][_0x1ceea3('0x18')]=function(_0x3c4c9e){const _0x13cdba=_0x1ceea3;this[_0x13cdba('0x1a')]=this[_0x13cdba('0x1a')]?this[_0x13cdba('0x1a')][_0x13cdba('0x1e')](_0x3c4c9e):_0x3c4c9e();};const Migration=function(_0x5804a5){const _0x28d801=_0x1ceea3;this[_0x28d801('0xe')]=_0x5804a5,this[_0x28d801('0x15')]=new Sequence();};Migration[_0x1ceea3('0x1')][_0x1ceea3('0xa')]=function(_0x3c8533,_0x2ef830,_0x4df5e8){const _0xe7e0ff=_0x1ceea3,_0x2e247f=this;this[_0xe7e0ff('0x15')][_0xe7e0ff('0x18')](function(){const _0x13a95e=_0xe7e0ff;return _0x2e247f['queryInterface'][_0x13a95e('0xa')](_0x3c8533,_0x2ef830,_0x4df5e8)['then'](function(){const _0x5e83a6=_0x13a95e;logger[_0x5e83a6('0x8')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x2ef830,_0x3c8533);})[_0x13a95e('0x10')](function(_0x1ed1a9){const _0x5c48e2=_0x13a95e;logger[_0x5c48e2('0x8')](JSON[_0x5c48e2('0x19')](_0x1ed1a9));});});},Migration[_0x1ceea3('0x1')][_0x1ceea3('0x6')]=function(_0xefb870,_0x47b5a5,_0xa9d05e){const _0x200f0b=_0x1ceea3,_0x3464bd=this;this[_0x200f0b('0x15')][_0x200f0b('0x18')](function(){const _0x503624=_0x200f0b;return _0x3464bd[_0x503624('0xe')][_0x503624('0x6')](_0xefb870,_0x47b5a5,_0xa9d05e)[_0x503624('0x13')](function(){const _0xad894d=_0x503624;logger[_0xad894d('0x8')](_0xad894d('0x17'),_0x47b5a5,_0xefb870);})[_0x503624('0x10')](function(_0xb94fce){const _0xebaad1=_0x503624;logger[_0xebaad1('0x8')](JSON[_0xebaad1('0x19')](_0xb94fce));});});},Migration['prototype'][_0x1ceea3('0xb')]=function(_0x175d83){const _0x3b6d31=_0x1ceea3,_0x5209a2=this;this[_0x3b6d31('0x15')][_0x3b6d31('0x18')](function(){const _0x22df37=_0x3b6d31;return _0x5209a2['queryInterface']['dropTable'](_0x175d83,{'force':!![]})[_0x22df37('0x13')](function(){const _0x5bdd5e=_0x22df37;logger[_0x5bdd5e('0x8')]('table\x20dropped\x20%s',_0x175d83);})['catch'](function(_0x3ae0f6){const _0xe230e0=_0x22df37;logger[_0xe230e0('0x8')](JSON[_0xe230e0('0x19')](_0x3ae0f6));});});},Migration[_0x1ceea3('0x1')][_0x1ceea3('0xc')]=function(_0x2d99f4,_0x3aa418,_0x5a8d56){const _0x1cdb2a=_0x1ceea3,_0x27e876=this;this[_0x1cdb2a('0x15')][_0x1cdb2a('0x18')](function(){const _0x285d85=_0x1cdb2a;return _0x27e876[_0x285d85('0xe')][_0x285d85('0xc')](_0x2d99f4,_0x3aa418,{'indexName':_0x5a8d56})[_0x285d85('0x13')](function(){const _0x1fb912=_0x285d85;logger[_0x1fb912('0x8')](_0x1fb912('0x2'),_0x2d99f4,_0x3aa418['join'](','),_0x5a8d56);})[_0x285d85('0x10')](function(_0x1f1406){const _0x4c1152=_0x285d85;logger[_0x4c1152('0x8')](JSON[_0x4c1152('0x19')](_0x1f1406));});});},Migration[_0x1ceea3('0x1')][_0x1ceea3('0x14')]=function(_0x2efdc8,_0x5d7690){const _0x10ccef=_0x1ceea3,_0x143c74=this;this[_0x10ccef('0x15')]['enqueue'](function(){const _0x5b56bc=_0x10ccef;return _0x143c74[_0x5b56bc('0xe')][_0x5b56bc('0x14')](_0x2efdc8,_0x5d7690)[_0x5b56bc('0x13')](function(){const _0x3e5a4d=_0x5b56bc;logger[_0x3e5a4d('0x8')](_0x3e5a4d('0x3'),_0x2efdc8,_0x5d7690);})[_0x5b56bc('0x10')](function(_0x4360b0){const _0x2112f2=_0x5b56bc;logger[_0x2112f2('0x8')](JSON[_0x2112f2('0x19')](_0x4360b0));});});},Migration[_0x1ceea3('0x1')][_0x1ceea3('0x1d')]=function(_0x32152a){const _0x1f8569=_0x1ceea3,_0x5148ad=this;this[_0x1f8569('0x15')][_0x1f8569('0x18')](function(){const _0x1a0039=_0x1f8569;return _0x5148ad['queryInterface'][_0x1a0039('0x16')][_0x1a0039('0x1d')](_0x32152a)[_0x1a0039('0x13')](function(){const _0x2b7c68=_0x1a0039;logger[_0x2b7c68('0x8')]('query\x20%s',_0x32152a);})[_0x1a0039('0x10')](function(_0x4908d6){const _0x3dc194=_0x1a0039;logger[_0x3dc194('0x8')](JSON['stringify'](_0x4908d6));});});},Migration[_0x1ceea3('0x1')]['removeColumn']=function(_0x395dfa,_0xc3be32){const _0x56e354=_0x1ceea3,_0x78ab81=this;this['sequence'][_0x56e354('0x18')](function(){const _0x439688=_0x56e354;return _0x78ab81[_0x439688('0xe')]['removeColumn'](_0x395dfa,_0xc3be32)[_0x439688('0x13')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0xc3be32,_0x395dfa);})[_0x439688('0x10')](function(_0x39645b){const _0x19b374=_0x439688;logger['info'](util[_0x19b374('0x11')](_0x39645b,{'showHidden':![],'depth':null}));});});},Migration[_0x1ceea3('0x1')]['renameColumn']=function(_0x28951f,_0x3eace4,_0x2e41c9){const _0x24a44d=this;this['sequence']['enqueue'](function(){const _0x144d37=a951_0x475e;return _0x24a44d['queryInterface']['renameColumn'](_0x28951f,_0x3eace4,_0x2e41c9)[_0x144d37('0x13')](function(){const _0x3e16b0=_0x144d37;logger[_0x3e16b0('0x8')](_0x3e16b0('0xd'),_0x3eace4,_0x2e41c9,_0x28951f);})[_0x144d37('0x10')](function(_0x4c3b37){const _0xf44fd6=_0x144d37;logger[_0xf44fd6('0x8')](util['inspect'](_0x4c3b37,{'showHidden':![],'depth':null}));});});},Migration[_0x1ceea3('0x1')][_0x1ceea3('0x12')]=function(_0x45f8a2){const _0x1ccc99=_0x1ceea3;this[_0x1ccc99('0x15')][_0x1ccc99('0x18')](function(){return _0x45f8a2();});},module[_0x1ceea3('0x7')]={'up':function(_0x4f7965){return new Promise(function(_0x190c4f){const _0x1b6fb7=a951_0x475e,_0x5d8183=new Migration(_0x4f7965);_0x5d8183[_0x1b6fb7('0x1d')](_0x1b6fb7('0x4')),_0x5d8183['addIndex'](_0x1b6fb7('0x0'),['uniqueid',_0x1b6fb7('0x9')],_0x1b6fb7('0x5')),_0x5d8183[_0x1b6fb7('0xc')](_0x1b6fb7('0x0'),['leaveAt'],_0x1b6fb7('0x1c')),_0x5d8183['final'](_0x190c4f);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.73.js b/server/migrations/2.0.73.js index 77be992..4cb7a97 100644 --- a/server/migrations/2.0.73.js +++ b/server/migrations/2.0.73.js @@ -1 +1 @@ -const a952_0xc034=['STRING','addIndex\x20%s\x20%s\x20%s','changeColumn','cm_hopper_history','join','removeIndex','routeid','migration','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','originatecalleridnum','query\x20%s','removeIndex\x20%s\x20%s','final','stringify','enqueue','../config/logger','addColumn','exports','catch','prototype','sequelize','tail','fb_data','info','cm_contacts','originatecalleridname','removeColumn','Removed\x20column\x20%s\x20from\x20%s','report_call','finally','then','inspect','query','INTEGER','cm_hopper_final','wechat','addIndex','queryInterface','dropTable','renameColumn','sequence'];(function(_0x132d4c,_0xc034c6){const _0xf20ecf=function(_0x4adf09){while(--_0x4adf09){_0x132d4c['push'](_0x132d4c['shift']());}};_0xf20ecf(++_0xc034c6);}(a952_0xc034,0x1ec));const a952_0xf20e=function(_0x132d4c,_0xc034c6){_0x132d4c=_0x132d4c-0x0;let _0xf20ecf=a952_0xc034[_0x132d4c];return _0xf20ecf;};const _0x146776=a952_0xf20e;'use strict';const util=require('util'),logger=require(_0x146776('0x1c'))(_0x146776('0x13')),Sequence=function(){};Sequence['prototype'][_0x146776('0x1b')]=function(_0x4adf09){const _0x10b5da=_0x146776;this[_0x10b5da('0x22')]=this['tail']?this[_0x10b5da('0x22')][_0x10b5da('0x0')](_0x4adf09):_0x4adf09();};const Migration=function(_0x455ac2){const _0x1dfab9=_0x146776;this[_0x1dfab9('0x8')]=_0x455ac2,this[_0x1dfab9('0xb')]=new Sequence();};Migration['prototype'][_0x146776('0xe')]=function(_0x5cd2df,_0xca230d,_0x320663){const _0x27d8a2=_0x146776,_0x146de7=this;this[_0x27d8a2('0xb')]['enqueue'](function(){const _0x247fd4=_0x27d8a2;return _0x146de7['queryInterface'][_0x247fd4('0xe')](_0x5cd2df,_0xca230d,_0x320663)[_0x247fd4('0x1')](function(){const _0x99a2b0=_0x247fd4;logger['info'](_0x99a2b0('0x15'),_0xca230d,_0x5cd2df);})[_0x247fd4('0x1f')](function(_0x557615){const _0x36d7d8=_0x247fd4;logger['info'](JSON[_0x36d7d8('0x1a')](_0x557615));});});},Migration['prototype'][_0x146776('0x1d')]=function(_0xcec038,_0x4293bf,_0x248a1f){const _0x5b79d3=_0x146776,_0x48bac0=this;this[_0x5b79d3('0xb')]['enqueue'](function(){const _0x3112ce=_0x5b79d3;return _0x48bac0[_0x3112ce('0x8')]['addColumn'](_0xcec038,_0x4293bf,_0x248a1f)[_0x3112ce('0x1')](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x4293bf,_0xcec038);})[_0x3112ce('0x1f')](function(_0x342f49){const _0x43c569=_0x3112ce;logger[_0x43c569('0x24')](JSON[_0x43c569('0x1a')](_0x342f49));});});},Migration[_0x146776('0x20')][_0x146776('0x9')]=function(_0x569aed){const _0x50cb34=_0x146776,_0x1b01a2=this;this[_0x50cb34('0xb')][_0x50cb34('0x1b')](function(){const _0x3ef80c=_0x50cb34;return _0x1b01a2[_0x3ef80c('0x8')][_0x3ef80c('0x9')](_0x569aed,{'force':!![]})[_0x3ef80c('0x1')](function(){logger['info']('table\x20dropped\x20%s',_0x569aed);})[_0x3ef80c('0x1f')](function(_0x5b054c){const _0x202019=_0x3ef80c;logger['info'](JSON[_0x202019('0x1a')](_0x5b054c));});});},Migration[_0x146776('0x20')][_0x146776('0x7')]=function(_0x2db3f3,_0x2648d1,_0x7981f){const _0x32b2fd=_0x146776,_0x1bdc4b=this;this[_0x32b2fd('0xb')][_0x32b2fd('0x1b')](function(){const _0x40bffd=_0x32b2fd;return _0x1bdc4b[_0x40bffd('0x8')][_0x40bffd('0x7')](_0x2db3f3,_0x2648d1,{'indexName':_0x7981f})[_0x40bffd('0x1')](function(){const _0x3df734=_0x40bffd;logger['info'](_0x3df734('0xd'),_0x2db3f3,_0x2648d1[_0x3df734('0x10')](','),_0x7981f);})[_0x40bffd('0x1f')](function(_0x120b4c){logger['info'](JSON['stringify'](_0x120b4c));});});},Migration[_0x146776('0x20')]['removeIndex']=function(_0x42a266,_0x526619){const _0x308d9c=_0x146776,_0x463956=this;this[_0x308d9c('0xb')][_0x308d9c('0x1b')](function(){const _0x58fbc2=_0x308d9c;return _0x463956[_0x58fbc2('0x8')][_0x58fbc2('0x11')](_0x42a266,_0x526619)['then'](function(){const _0x2a35ce=_0x58fbc2;logger['info'](_0x2a35ce('0x18'),_0x42a266,_0x526619);})[_0x58fbc2('0x1f')](function(_0x5c30f7){const _0x20f533=_0x58fbc2;logger[_0x20f533('0x24')](JSON[_0x20f533('0x1a')](_0x5c30f7));});});},Migration[_0x146776('0x20')][_0x146776('0x3')]=function(_0x2fb46a){const _0x15e443=_0x146776,_0x3ef407=this;this[_0x15e443('0xb')][_0x15e443('0x1b')](function(){const _0x1689f8=_0x15e443;return _0x3ef407['queryInterface'][_0x1689f8('0x21')][_0x1689f8('0x3')](_0x2fb46a)[_0x1689f8('0x1')](function(){const _0x179264=_0x1689f8;logger['info'](_0x179264('0x17'),_0x2fb46a);})[_0x1689f8('0x1f')](function(_0x1baec4){const _0x10880d=_0x1689f8;logger[_0x10880d('0x24')](JSON[_0x10880d('0x1a')](_0x1baec4));});});},Migration[_0x146776('0x20')][_0x146776('0x27')]=function(_0x479cf7,_0xdfe956){const _0x857f35=_0x146776,_0x1c5c66=this;this[_0x857f35('0xb')][_0x857f35('0x1b')](function(){const _0x1ef70c=_0x857f35;return _0x1c5c66[_0x1ef70c('0x8')][_0x1ef70c('0x27')](_0x479cf7,_0xdfe956)[_0x1ef70c('0x1')](function(){const _0x247882=_0x1ef70c;logger[_0x247882('0x24')](_0x247882('0x28'),_0xdfe956,_0x479cf7);})['catch'](function(_0x387c9e){const _0x5c8c61=_0x1ef70c;logger[_0x5c8c61('0x24')](util[_0x5c8c61('0x2')](_0x387c9e,{'showHidden':![],'depth':null}));});});},Migration[_0x146776('0x20')]['renameColumn']=function(_0x38d95a,_0x346c12,_0xa674c9){const _0x55c5f3=_0x146776,_0x2e7251=this;this[_0x55c5f3('0xb')][_0x55c5f3('0x1b')](function(){const _0xb5b133=_0x55c5f3;return _0x2e7251[_0xb5b133('0x8')][_0xb5b133('0xa')](_0x38d95a,_0x346c12,_0xa674c9)[_0xb5b133('0x1')](function(){const _0x110952=_0xb5b133;logger[_0x110952('0x24')](_0x110952('0x14'),_0x346c12,_0xa674c9,_0x38d95a);})[_0xb5b133('0x1f')](function(_0x25fb97){const _0x42e913=_0xb5b133;logger['info'](util[_0x42e913('0x2')](_0x25fb97,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0xf2f701){const _0x3bf56a=_0x146776;this[_0x3bf56a('0xb')][_0x3bf56a('0x1b')](function(){return _0xf2f701();});},module[_0x146776('0x1e')]={'up':function(_0x492419,_0x80b07a){return new Promise(function(_0x377c28){const _0xd7d712=a952_0xf20e,_0xb6b502=new Migration(_0x492419);_0xb6b502[_0xd7d712('0x1d')](_0xd7d712('0x29'),_0xd7d712('0x12'),{'type':_0x80b07a[_0xd7d712('0x4')]}),_0xb6b502[_0xd7d712('0x1d')]('cm_hopper_final',_0xd7d712('0x16'),{'type':_0x80b07a[_0xd7d712('0xc')]}),_0xb6b502[_0xd7d712('0x1d')](_0xd7d712('0x5'),_0xd7d712('0x26'),{'type':_0x80b07a[_0xd7d712('0xc')]}),_0xb6b502[_0xd7d712('0x1d')]('cm_hopper_history',_0xd7d712('0x16'),{'type':_0x80b07a[_0xd7d712('0xc')]}),_0xb6b502[_0xd7d712('0x1d')](_0xd7d712('0xf'),'originatecalleridname',{'type':_0x80b07a['STRING']}),_0xb6b502[_0xd7d712('0x1d')](_0xd7d712('0x25'),_0xd7d712('0x6'),{'type':_0x80b07a[_0xd7d712('0xc')]}),_0xb6b502['addColumn']('cm_contacts',_0xd7d712('0x23'),{'type':_0x80b07a[_0xd7d712('0xc')]}),_0xb6b502[_0xd7d712('0x19')](_0x377c28);});},'down':function(){}}; \ No newline at end of file +const a952_0x321a=['Removed\x20column\x20%s\x20from\x20%s','tail','sequelize','STRING','query','cm_hopper_history','exports','queryInterface','originatecalleridnum','catch','addIndex','final','addColumn','renameColumn','INTEGER','prototype','routeid','wechat','dropTable','addIndex\x20%s\x20%s\x20%s','join','sequence','cm_hopper_final','query\x20%s','removeColumn','cm_contacts','inspect','changeColumn','removeIndex','migration','Changed\x20column\x20%s\x20in\x20table\x20%s','report_call','util','then','stringify','../config/logger','enqueue','originatecalleridname','info'];(function(_0x35f66e,_0x321ae6){const _0x2d2d24=function(_0x16a7f6){while(--_0x16a7f6){_0x35f66e['push'](_0x35f66e['shift']());}};_0x2d2d24(++_0x321ae6);}(a952_0x321a,0x196));const a952_0x2d2d=function(_0x35f66e,_0x321ae6){_0x35f66e=_0x35f66e-0x0;let _0x2d2d24=a952_0x321a[_0x35f66e];return _0x2d2d24;};const _0x3e8038=a952_0x2d2d;'use strict';const util=require(_0x3e8038('0x10')),logger=require(_0x3e8038('0x13'))(_0x3e8038('0xd')),Sequence=function(){};Sequence[_0x3e8038('0x26')][_0x3e8038('0x14')]=function(_0x16a7f6){const _0x334216=_0x3e8038;this['tail']=this[_0x334216('0x18')]?this[_0x334216('0x18')]['finally'](_0x16a7f6):_0x16a7f6();};const Migration=function(_0x3fced5){const _0x36a4d0=_0x3e8038;this[_0x36a4d0('0x1e')]=_0x3fced5,this['sequence']=new Sequence();};Migration[_0x3e8038('0x26')][_0x3e8038('0xb')]=function(_0x3f5965,_0x3b1513,_0x35693e){const _0x4a8238=this;this['sequence']['enqueue'](function(){const _0x1c50b9=a952_0x2d2d;return _0x4a8238['queryInterface'][_0x1c50b9('0xb')](_0x3f5965,_0x3b1513,_0x35693e)[_0x1c50b9('0x11')](function(){const _0x111b00=_0x1c50b9;logger[_0x111b00('0x16')](_0x111b00('0xe'),_0x3b1513,_0x3f5965);})[_0x1c50b9('0x20')](function(_0x383e9e){const _0x1b6d9f=_0x1c50b9;logger[_0x1b6d9f('0x16')](JSON[_0x1b6d9f('0x12')](_0x383e9e));});});},Migration[_0x3e8038('0x26')]['addColumn']=function(_0x112f67,_0x1d222f,_0x206c25){const _0x58bc70=_0x3e8038,_0x55e6a9=this;this[_0x58bc70('0x5')][_0x58bc70('0x14')](function(){const _0xf6894=_0x58bc70;return _0x55e6a9[_0xf6894('0x1e')][_0xf6894('0x23')](_0x112f67,_0x1d222f,_0x206c25)['then'](function(){const _0x44b98e=_0xf6894;logger[_0x44b98e('0x16')]('Added\x20column\x20%s\x20to\x20%s',_0x1d222f,_0x112f67);})[_0xf6894('0x20')](function(_0x27b8d4){const _0x2b7bb9=_0xf6894;logger[_0x2b7bb9('0x16')](JSON[_0x2b7bb9('0x12')](_0x27b8d4));});});},Migration[_0x3e8038('0x26')][_0x3e8038('0x2')]=function(_0x39164c){const _0x48ecc5=_0x3e8038,_0x121393=this;this[_0x48ecc5('0x5')][_0x48ecc5('0x14')](function(){const _0x50aa10=_0x48ecc5;return _0x121393[_0x50aa10('0x1e')][_0x50aa10('0x2')](_0x39164c,{'force':!![]})[_0x50aa10('0x11')](function(){logger['info']('table\x20dropped\x20%s',_0x39164c);})['catch'](function(_0x293f5e){const _0x161fbc=_0x50aa10;logger['info'](JSON[_0x161fbc('0x12')](_0x293f5e));});});},Migration[_0x3e8038('0x26')]['addIndex']=function(_0xc82f24,_0x2675d8,_0x398bbb){const _0x15f72d=_0x3e8038,_0x30fbda=this;this[_0x15f72d('0x5')][_0x15f72d('0x14')](function(){const _0x252772=_0x15f72d;return _0x30fbda[_0x252772('0x1e')][_0x252772('0x21')](_0xc82f24,_0x2675d8,{'indexName':_0x398bbb})[_0x252772('0x11')](function(){const _0x17bf45=_0x252772;logger[_0x17bf45('0x16')](_0x17bf45('0x3'),_0xc82f24,_0x2675d8[_0x17bf45('0x4')](','),_0x398bbb);})[_0x252772('0x20')](function(_0x5735de){const _0x291285=_0x252772;logger[_0x291285('0x16')](JSON[_0x291285('0x12')](_0x5735de));});});},Migration[_0x3e8038('0x26')]['removeIndex']=function(_0x4abdc7,_0x313a55){const _0x14a805=_0x3e8038,_0x1c763e=this;this[_0x14a805('0x5')]['enqueue'](function(){const _0x20d674=_0x14a805;return _0x1c763e[_0x20d674('0x1e')][_0x20d674('0xc')](_0x4abdc7,_0x313a55)[_0x20d674('0x11')](function(){const _0x3bd1fa=_0x20d674;logger[_0x3bd1fa('0x16')]('removeIndex\x20%s\x20%s',_0x4abdc7,_0x313a55);})[_0x20d674('0x20')](function(_0x36466c){const _0x51b9cf=_0x20d674;logger['info'](JSON[_0x51b9cf('0x12')](_0x36466c));});});},Migration[_0x3e8038('0x26')][_0x3e8038('0x1b')]=function(_0x56e93a){const _0xefbe32=_0x3e8038,_0x28fe64=this;this[_0xefbe32('0x5')][_0xefbe32('0x14')](function(){const _0x2b98f4=_0xefbe32;return _0x28fe64['queryInterface'][_0x2b98f4('0x19')][_0x2b98f4('0x1b')](_0x56e93a)['then'](function(){const _0x496575=_0x2b98f4;logger['info'](_0x496575('0x7'),_0x56e93a);})['catch'](function(_0x4ed8bf){const _0x697397=_0x2b98f4;logger[_0x697397('0x16')](JSON['stringify'](_0x4ed8bf));});});},Migration[_0x3e8038('0x26')][_0x3e8038('0x8')]=function(_0x8ce096,_0x451553){const _0x437e8a=_0x3e8038,_0x486b80=this;this[_0x437e8a('0x5')]['enqueue'](function(){const _0x3d3112=_0x437e8a;return _0x486b80[_0x3d3112('0x1e')][_0x3d3112('0x8')](_0x8ce096,_0x451553)[_0x3d3112('0x11')](function(){const _0x4650a0=_0x3d3112;logger[_0x4650a0('0x16')](_0x4650a0('0x17'),_0x451553,_0x8ce096);})[_0x3d3112('0x20')](function(_0x404b2e){const _0x4ce2b4=_0x3d3112;logger[_0x4ce2b4('0x16')](util[_0x4ce2b4('0xa')](_0x404b2e,{'showHidden':![],'depth':null}));});});},Migration[_0x3e8038('0x26')][_0x3e8038('0x24')]=function(_0x14ddac,_0x410ae4,_0x386a4a){const _0x128d6b=_0x3e8038,_0x100a61=this;this[_0x128d6b('0x5')]['enqueue'](function(){const _0x28f40d=_0x128d6b;return _0x100a61[_0x28f40d('0x1e')][_0x28f40d('0x24')](_0x14ddac,_0x410ae4,_0x386a4a)['then'](function(){const _0x306d9d=_0x28f40d;logger[_0x306d9d('0x16')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x410ae4,_0x386a4a,_0x14ddac);})[_0x28f40d('0x20')](function(_0x1659a1){const _0x512481=_0x28f40d;logger['info'](util[_0x512481('0xa')](_0x1659a1,{'showHidden':![],'depth':null}));});});},Migration[_0x3e8038('0x26')][_0x3e8038('0x22')]=function(_0x28c1a0){const _0x11efa5=_0x3e8038;this[_0x11efa5('0x5')]['enqueue'](function(){return _0x28c1a0();});},module[_0x3e8038('0x1d')]={'up':function(_0x5d970a,_0x59a065){return new Promise(function(_0x13b4b9){const _0x571ea9=a952_0x2d2d,_0xfee7b9=new Migration(_0x5d970a);_0xfee7b9['addColumn'](_0x571ea9('0xf'),_0x571ea9('0x0'),{'type':_0x59a065[_0x571ea9('0x25')]}),_0xfee7b9['addColumn'](_0x571ea9('0x6'),_0x571ea9('0x1f'),{'type':_0x59a065[_0x571ea9('0x1a')]}),_0xfee7b9[_0x571ea9('0x23')](_0x571ea9('0x6'),_0x571ea9('0x15'),{'type':_0x59a065[_0x571ea9('0x1a')]}),_0xfee7b9[_0x571ea9('0x23')](_0x571ea9('0x1c'),_0x571ea9('0x1f'),{'type':_0x59a065['STRING']}),_0xfee7b9['addColumn'](_0x571ea9('0x1c'),_0x571ea9('0x15'),{'type':_0x59a065[_0x571ea9('0x1a')]}),_0xfee7b9[_0x571ea9('0x23')](_0x571ea9('0x9'),_0x571ea9('0x1'),{'type':_0x59a065['STRING']}),_0xfee7b9['addColumn'](_0x571ea9('0x9'),'fb_data',{'type':_0x59a065[_0x571ea9('0x1a')]}),_0xfee7b9[_0x571ea9('0x22')](_0x13b4b9);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.74.js b/server/migrations/2.0.74.js index 2502fac..9f2af46 100644 --- a/server/migrations/2.0.74.js +++ b/server/migrations/2.0.74.js @@ -1 +1 @@ -const a953_0x2b7a=['Removed\x20column\x20%s\x20from\x20%s','changeColumn','query','stringify','renameColumn','prototype','dropTable','info','then','query\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','enqueue','inspect','sequelize','tail','Added\x20column\x20%s\x20to\x20%s','sequence','finally','removeIndex','table\x20dropped\x20%s','removeColumn','queryInterface','join','util','final','catch','../config/logger'];(function(_0x4f9b5f,_0x2b7aa6){const _0x3553ce=function(_0x5733df){while(--_0x5733df){_0x4f9b5f['push'](_0x4f9b5f['shift']());}};_0x3553ce(++_0x2b7aa6);}(a953_0x2b7a,0x108));const a953_0x3553=function(_0x4f9b5f,_0x2b7aa6){_0x4f9b5f=_0x4f9b5f-0x0;let _0x3553ce=a953_0x2b7a[_0x4f9b5f];return _0x3553ce;};const _0x1f4708=a953_0x3553;'use strict';const util=require(_0x1f4708('0xc')),logger=require(_0x1f4708('0xf'))('migration'),Sequence=function(){};Sequence[_0x1f4708('0x15')][_0x1f4708('0x0')]=function(_0x5733df){const _0x3c5735=_0x1f4708;this['tail']=this[_0x3c5735('0x3')]?this[_0x3c5735('0x3')][_0x3c5735('0x6')](_0x5733df):_0x5733df();};const Migration=function(_0x504158){const _0x26220d=_0x1f4708;this[_0x26220d('0xa')]=_0x504158,this[_0x26220d('0x5')]=new Sequence();};Migration['prototype'][_0x1f4708('0x11')]=function(_0xcbc96d,_0x4f9887,_0x5eeee2){const _0x2e4b65=_0x1f4708,_0x44257c=this;this[_0x2e4b65('0x5')]['enqueue'](function(){const _0x2400d8=_0x2e4b65;return _0x44257c['queryInterface'][_0x2400d8('0x11')](_0xcbc96d,_0x4f9887,_0x5eeee2)[_0x2400d8('0x18')](function(){const _0x425c42=_0x2400d8;logger[_0x425c42('0x17')](_0x425c42('0x1a'),_0x4f9887,_0xcbc96d);})['catch'](function(_0x19eea1){const _0x5c1849=_0x2400d8;logger[_0x5c1849('0x17')](JSON[_0x5c1849('0x13')](_0x19eea1));});});},Migration[_0x1f4708('0x15')]['addColumn']=function(_0x2d64e1,_0x12d336,_0x22c7b0){const _0x2ca3e3=_0x1f4708,_0x32a4cd=this;this[_0x2ca3e3('0x5')][_0x2ca3e3('0x0')](function(){const _0x167d60=_0x2ca3e3;return _0x32a4cd[_0x167d60('0xa')]['addColumn'](_0x2d64e1,_0x12d336,_0x22c7b0)[_0x167d60('0x18')](function(){const _0x4938c8=_0x167d60;logger[_0x4938c8('0x17')](_0x4938c8('0x4'),_0x12d336,_0x2d64e1);})[_0x167d60('0xe')](function(_0x5f117b){const _0x1b583=_0x167d60;logger[_0x1b583('0x17')](JSON[_0x1b583('0x13')](_0x5f117b));});});},Migration['prototype'][_0x1f4708('0x16')]=function(_0x22e913){const _0xd512c9=_0x1f4708,_0x5b715c=this;this['sequence'][_0xd512c9('0x0')](function(){const _0x34c00f=_0xd512c9;return _0x5b715c[_0x34c00f('0xa')][_0x34c00f('0x16')](_0x22e913,{'force':!![]})['then'](function(){const _0x749944=_0x34c00f;logger[_0x749944('0x17')](_0x749944('0x8'),_0x22e913);})['catch'](function(_0x2f8f60){const _0x530876=_0x34c00f;logger[_0x530876('0x17')](JSON[_0x530876('0x13')](_0x2f8f60));});});},Migration[_0x1f4708('0x15')]['addIndex']=function(_0x2ed565,_0x188d5f,_0x20e3ea){const _0x1296fe=_0x1f4708,_0x2b360a=this;this[_0x1296fe('0x5')]['enqueue'](function(){const _0xb4bfe6=_0x1296fe;return _0x2b360a['queryInterface']['addIndex'](_0x2ed565,_0x188d5f,{'indexName':_0x20e3ea})[_0xb4bfe6('0x18')](function(){const _0x4ff7fc=_0xb4bfe6;logger[_0x4ff7fc('0x17')]('addIndex\x20%s\x20%s\x20%s',_0x2ed565,_0x188d5f[_0x4ff7fc('0xb')](','),_0x20e3ea);})[_0xb4bfe6('0xe')](function(_0x478c5e){const _0x14521f=_0xb4bfe6;logger[_0x14521f('0x17')](JSON[_0x14521f('0x13')](_0x478c5e));});});},Migration[_0x1f4708('0x15')][_0x1f4708('0x7')]=function(_0x527f49,_0x430c97){const _0x4dc75f=_0x1f4708,_0x95eff9=this;this[_0x4dc75f('0x5')][_0x4dc75f('0x0')](function(){const _0x24adb4=_0x4dc75f;return _0x95eff9['queryInterface'][_0x24adb4('0x7')](_0x527f49,_0x430c97)[_0x24adb4('0x18')](function(){const _0x5df53b=_0x24adb4;logger[_0x5df53b('0x17')]('removeIndex\x20%s\x20%s',_0x527f49,_0x430c97);})[_0x24adb4('0xe')](function(_0x3dba9f){const _0x59a82c=_0x24adb4;logger['info'](JSON[_0x59a82c('0x13')](_0x3dba9f));});});},Migration[_0x1f4708('0x15')][_0x1f4708('0x12')]=function(_0x555044){const _0x2b7fbf=_0x1f4708,_0x1b5efb=this;this['sequence'][_0x2b7fbf('0x0')](function(){const _0x4b2349=_0x2b7fbf;return _0x1b5efb[_0x4b2349('0xa')][_0x4b2349('0x2')][_0x4b2349('0x12')](_0x555044)[_0x4b2349('0x18')](function(){const _0x324c3b=_0x4b2349;logger[_0x324c3b('0x17')](_0x324c3b('0x19'),_0x555044);})[_0x4b2349('0xe')](function(_0x35b8f8){logger['info'](JSON['stringify'](_0x35b8f8));});});},Migration['prototype'][_0x1f4708('0x9')]=function(_0x520def,_0x30121b){const _0x2647fa=_0x1f4708,_0x3da41d=this;this[_0x2647fa('0x5')][_0x2647fa('0x0')](function(){const _0x1c7adb=_0x2647fa;return _0x3da41d[_0x1c7adb('0xa')]['removeColumn'](_0x520def,_0x30121b)['then'](function(){const _0x464bc2=_0x1c7adb;logger['info'](_0x464bc2('0x10'),_0x30121b,_0x520def);})['catch'](function(_0x3a97f4){const _0x5aa717=_0x1c7adb;logger[_0x5aa717('0x17')](util[_0x5aa717('0x1')](_0x3a97f4,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x1f4708('0x14')]=function(_0x20f4f2,_0x1da74d,_0x937c78){const _0x3ffebf=_0x1f4708,_0x442c6c=this;this[_0x3ffebf('0x5')][_0x3ffebf('0x0')](function(){const _0x3c21c9=_0x3ffebf;return _0x442c6c['queryInterface']['renameColumn'](_0x20f4f2,_0x1da74d,_0x937c78)[_0x3c21c9('0x18')](function(){const _0x34c1d3=_0x3c21c9;logger[_0x34c1d3('0x17')](_0x34c1d3('0x1b'),_0x1da74d,_0x937c78,_0x20f4f2);})[_0x3c21c9('0xe')](function(_0x42729a){const _0x2543c5=_0x3c21c9;logger[_0x2543c5('0x17')](util[_0x2543c5('0x1')](_0x42729a,{'showHidden':![],'depth':null}));});});},Migration[_0x1f4708('0x15')][_0x1f4708('0xd')]=function(_0x52bf84){const _0x180a2e=_0x1f4708;this[_0x180a2e('0x5')][_0x180a2e('0x0')](function(){return _0x52bf84();});},module['exports']={'up':function(_0x42c91b){return new Promise(function(_0x1f7b42){const _0x486eb0=new Migration(_0x42c91b);_0x486eb0['final'](_0x1f7b42);});},'down':function(){}}; \ No newline at end of file +const a953_0x2c2d=['join','Changed\x20column\x20%s\x20in\x20table\x20%s','prototype','stringify','exports','final','addIndex\x20%s\x20%s\x20%s','queryInterface','query','info','removeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','sequence','addColumn','Removed\x20column\x20%s\x20from\x20%s','addIndex','migration','table\x20dropped\x20%s','inspect','removeIndex','enqueue','changeColumn','tail','renameColumn','finally','then','catch','util'];(function(_0x42c820,_0x2c2dbd){const _0x196919=function(_0x3b237e){while(--_0x3b237e){_0x42c820['push'](_0x42c820['shift']());}};_0x196919(++_0x2c2dbd);}(a953_0x2c2d,0x102));const a953_0x1969=function(_0x42c820,_0x2c2dbd){_0x42c820=_0x42c820-0x0;let _0x196919=a953_0x2c2d[_0x42c820];return _0x196919;};const _0x21ce03=a953_0x1969;'use strict';const util=require(_0x21ce03('0x15')),logger=require('../config/logger')(_0x21ce03('0xa')),Sequence=function(){};Sequence[_0x21ce03('0x18')][_0x21ce03('0xe')]=function(_0x3b237e){const _0x2548cf=_0x21ce03;this[_0x2548cf('0x10')]=this[_0x2548cf('0x10')]?this[_0x2548cf('0x10')][_0x2548cf('0x12')](_0x3b237e):_0x3b237e();};const Migration=function(_0x3681c9){const _0x764814=_0x21ce03;this[_0x764814('0x1')]=_0x3681c9,this['sequence']=new Sequence();};Migration[_0x21ce03('0x18')][_0x21ce03('0xf')]=function(_0x59613f,_0x47fc84,_0x4a4a1c){const _0x355e39=_0x21ce03,_0x535171=this;this[_0x355e39('0x6')][_0x355e39('0xe')](function(){const _0xecfb1=_0x355e39;return _0x535171[_0xecfb1('0x1')]['changeColumn'](_0x59613f,_0x47fc84,_0x4a4a1c)['then'](function(){const _0x2c1cc6=_0xecfb1;logger[_0x2c1cc6('0x3')](_0x2c1cc6('0x17'),_0x47fc84,_0x59613f);})[_0xecfb1('0x14')](function(_0x4660db){const _0x4c2806=_0xecfb1;logger[_0x4c2806('0x3')](JSON['stringify'](_0x4660db));});});},Migration[_0x21ce03('0x18')][_0x21ce03('0x7')]=function(_0x480164,_0x3f235d,_0x452d48){const _0x2906c4=_0x21ce03,_0x44969f=this;this[_0x2906c4('0x6')][_0x2906c4('0xe')](function(){const _0x58a08b=_0x2906c4;return _0x44969f[_0x58a08b('0x1')][_0x58a08b('0x7')](_0x480164,_0x3f235d,_0x452d48)[_0x58a08b('0x13')](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x3f235d,_0x480164);})[_0x58a08b('0x14')](function(_0x5c75ae){const _0xa3b93f=_0x58a08b;logger[_0xa3b93f('0x3')](JSON[_0xa3b93f('0x19')](_0x5c75ae));});});},Migration[_0x21ce03('0x18')]['dropTable']=function(_0x58a844){const _0x49b3aa=_0x21ce03,_0x206a63=this;this['sequence'][_0x49b3aa('0xe')](function(){const _0xd26405=_0x49b3aa;return _0x206a63['queryInterface']['dropTable'](_0x58a844,{'force':!![]})['then'](function(){const _0x546539=a953_0x1969;logger[_0x546539('0x3')](_0x546539('0xb'),_0x58a844);})[_0xd26405('0x14')](function(_0x3879e9){const _0x4b5e1c=_0xd26405;logger[_0x4b5e1c('0x3')](JSON['stringify'](_0x3879e9));});});},Migration['prototype'][_0x21ce03('0x9')]=function(_0x406593,_0x3d9380,_0x2b6eb6){const _0x2c7723=_0x21ce03,_0x13db85=this;this[_0x2c7723('0x6')][_0x2c7723('0xe')](function(){const _0x24bf9a=_0x2c7723;return _0x13db85[_0x24bf9a('0x1')][_0x24bf9a('0x9')](_0x406593,_0x3d9380,{'indexName':_0x2b6eb6})[_0x24bf9a('0x13')](function(){const _0x4803f1=_0x24bf9a;logger[_0x4803f1('0x3')](_0x4803f1('0x0'),_0x406593,_0x3d9380[_0x4803f1('0x16')](','),_0x2b6eb6);})['catch'](function(_0x53cf9e){const _0x93d701=_0x24bf9a;logger[_0x93d701('0x3')](JSON[_0x93d701('0x19')](_0x53cf9e));});});},Migration[_0x21ce03('0x18')][_0x21ce03('0xd')]=function(_0x183a5d,_0x4a1c03){const _0x9a3bdd=_0x21ce03,_0x82cbca=this;this[_0x9a3bdd('0x6')][_0x9a3bdd('0xe')](function(){const _0x51e50d=_0x9a3bdd;return _0x82cbca[_0x51e50d('0x1')][_0x51e50d('0xd')](_0x183a5d,_0x4a1c03)['then'](function(){const _0xf230a3=_0x51e50d;logger[_0xf230a3('0x3')]('removeIndex\x20%s\x20%s',_0x183a5d,_0x4a1c03);})[_0x51e50d('0x14')](function(_0x26099e){const _0x11e860=_0x51e50d;logger['info'](JSON[_0x11e860('0x19')](_0x26099e));});});},Migration[_0x21ce03('0x18')]['query']=function(_0x4d5b49){const _0x124382=_0x21ce03,_0x26b74a=this;this[_0x124382('0x6')][_0x124382('0xe')](function(){const _0x458afc=_0x124382;return _0x26b74a[_0x458afc('0x1')]['sequelize'][_0x458afc('0x2')](_0x4d5b49)[_0x458afc('0x13')](function(){const _0x4d10c7=_0x458afc;logger[_0x4d10c7('0x3')]('query\x20%s',_0x4d5b49);})['catch'](function(_0x52a03b){const _0x532ba6=_0x458afc;logger[_0x532ba6('0x3')](JSON[_0x532ba6('0x19')](_0x52a03b));});});},Migration[_0x21ce03('0x18')][_0x21ce03('0x4')]=function(_0x4ffd19,_0x285b49){const _0x445fb9=_0x21ce03,_0x10f4ab=this;this[_0x445fb9('0x6')][_0x445fb9('0xe')](function(){const _0x2aa1ea=_0x445fb9;return _0x10f4ab['queryInterface'][_0x2aa1ea('0x4')](_0x4ffd19,_0x285b49)[_0x2aa1ea('0x13')](function(){const _0x3f8080=_0x2aa1ea;logger['info'](_0x3f8080('0x8'),_0x285b49,_0x4ffd19);})['catch'](function(_0x52d894){const _0x36e3ae=_0x2aa1ea;logger[_0x36e3ae('0x3')](util[_0x36e3ae('0xc')](_0x52d894,{'showHidden':![],'depth':null}));});});},Migration['prototype']['renameColumn']=function(_0x159252,_0x2c7e50,_0x34b819){const _0x44c440=_0x21ce03,_0x30dcea=this;this[_0x44c440('0x6')][_0x44c440('0xe')](function(){const _0x163cc1=_0x44c440;return _0x30dcea[_0x163cc1('0x1')][_0x163cc1('0x11')](_0x159252,_0x2c7e50,_0x34b819)[_0x163cc1('0x13')](function(){const _0x25ff46=_0x163cc1;logger[_0x25ff46('0x3')](_0x25ff46('0x5'),_0x2c7e50,_0x34b819,_0x159252);})[_0x163cc1('0x14')](function(_0x43b0ee){logger['info'](util['inspect'](_0x43b0ee,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x1c80af){const _0xeae42a=_0x21ce03;this['sequence'][_0xeae42a('0xe')](function(){return _0x1c80af();});},module[_0x21ce03('0x1a')]={'up':function(_0x211ab1){return new Promise(function(_0x5d03bc){const _0x2869ae=a953_0x1969,_0x5e375d=new Migration(_0x211ab1);_0x5e375d[_0x2869ae('0x1b')](_0x5d03bc);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.75.js b/server/migrations/2.0.75.js index 7ccae26..e3410af 100644 --- a/server/migrations/2.0.75.js +++ b/server/migrations/2.0.75.js @@ -1 +1 @@ -const a954_0x4457=['sequence','changeColumn','addIndex\x20%s\x20%s\x20%s','exports','renameColumn','enqueue','then','removeColumn','util','queryInterface','inspect','dropTable','addColumn','query\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','stringify','tail','final','query','addIndex','catch','removeIndex','removeIndex\x20%s\x20%s','migration','info','sequelize','Added\x20column\x20%s\x20to\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','../config/logger','prototype'];(function(_0x53afaa,_0x445711){const _0x461432=function(_0x3a88c2){while(--_0x3a88c2){_0x53afaa['push'](_0x53afaa['shift']());}};_0x461432(++_0x445711);}(a954_0x4457,0xf6));const a954_0x4614=function(_0x53afaa,_0x445711){_0x53afaa=_0x53afaa-0x0;let _0x461432=a954_0x4457[_0x53afaa];return _0x461432;};const _0x3111a1=a954_0x4614;'use strict';const util=require(_0x3111a1('0x2')),logger=require(_0x3111a1('0x16'))(_0x3111a1('0x11')),Sequence=function(){};Sequence[_0x3111a1('0x17')][_0x3111a1('0x1d')]=function(_0x3a88c2){const _0x27aec3=_0x3111a1;this[_0x27aec3('0xa')]=this[_0x27aec3('0xa')]?this[_0x27aec3('0xa')]['finally'](_0x3a88c2):_0x3a88c2();};const Migration=function(_0x46b7cb){const _0x580049=_0x3111a1;this[_0x580049('0x3')]=_0x46b7cb,this['sequence']=new Sequence();};Migration[_0x3111a1('0x17')][_0x3111a1('0x19')]=function(_0x17bdae,_0x366df1,_0x272e55){const _0x119342=_0x3111a1,_0x366fd8=this;this['sequence'][_0x119342('0x1d')](function(){const _0x21b2ce=_0x119342;return _0x366fd8['queryInterface'][_0x21b2ce('0x19')](_0x17bdae,_0x366df1,_0x272e55)['then'](function(){const _0x55c291=_0x21b2ce;logger[_0x55c291('0x12')](_0x55c291('0x8'),_0x366df1,_0x17bdae);})[_0x21b2ce('0xe')](function(_0x2830d2){const _0x492e46=_0x21b2ce;logger[_0x492e46('0x12')](JSON[_0x492e46('0x9')](_0x2830d2));});});},Migration[_0x3111a1('0x17')][_0x3111a1('0x6')]=function(_0x171f73,_0x588613,_0x4d0f9c){const _0x57a087=_0x3111a1,_0x3d23f5=this;this[_0x57a087('0x18')][_0x57a087('0x1d')](function(){const _0x2a6198=_0x57a087;return _0x3d23f5[_0x2a6198('0x3')][_0x2a6198('0x6')](_0x171f73,_0x588613,_0x4d0f9c)[_0x2a6198('0x0')](function(){const _0x4b6ffc=_0x2a6198;logger[_0x4b6ffc('0x12')](_0x4b6ffc('0x14'),_0x588613,_0x171f73);})['catch'](function(_0xae60f1){const _0x2744d2=_0x2a6198;logger[_0x2744d2('0x12')](JSON[_0x2744d2('0x9')](_0xae60f1));});});},Migration['prototype'][_0x3111a1('0x5')]=function(_0x3640fa){const _0x5b9ccf=_0x3111a1,_0x27996b=this;this[_0x5b9ccf('0x18')][_0x5b9ccf('0x1d')](function(){const _0x17f0b3=_0x5b9ccf;return _0x27996b[_0x17f0b3('0x3')][_0x17f0b3('0x5')](_0x3640fa,{'force':!![]})['then'](function(){const _0x4613cf=_0x17f0b3;logger[_0x4613cf('0x12')]('table\x20dropped\x20%s',_0x3640fa);})[_0x17f0b3('0xe')](function(_0x327ef3){const _0x1c9951=_0x17f0b3;logger['info'](JSON[_0x1c9951('0x9')](_0x327ef3));});});},Migration['prototype'][_0x3111a1('0xd')]=function(_0x49779f,_0x340894,_0x5d5f6c){const _0xc07513=_0x3111a1,_0x3ac9c1=this;this[_0xc07513('0x18')][_0xc07513('0x1d')](function(){const _0xcd882e=_0xc07513;return _0x3ac9c1[_0xcd882e('0x3')]['addIndex'](_0x49779f,_0x340894,{'indexName':_0x5d5f6c})['then'](function(){const _0xf1ac9b=_0xcd882e;logger[_0xf1ac9b('0x12')](_0xf1ac9b('0x1a'),_0x49779f,_0x340894['join'](','),_0x5d5f6c);})['catch'](function(_0x2b9e80){const _0x331ee8=_0xcd882e;logger[_0x331ee8('0x12')](JSON[_0x331ee8('0x9')](_0x2b9e80));});});},Migration['prototype']['removeIndex']=function(_0x3f5a3d,_0x4ae554){const _0x5a33ea=_0x3111a1,_0x691c19=this;this[_0x5a33ea('0x18')]['enqueue'](function(){const _0x328cc1=_0x5a33ea;return _0x691c19['queryInterface'][_0x328cc1('0xf')](_0x3f5a3d,_0x4ae554)[_0x328cc1('0x0')](function(){const _0x4006ad=_0x328cc1;logger[_0x4006ad('0x12')](_0x4006ad('0x10'),_0x3f5a3d,_0x4ae554);})[_0x328cc1('0xe')](function(_0x3580ed){const _0x370349=_0x328cc1;logger[_0x370349('0x12')](JSON[_0x370349('0x9')](_0x3580ed));});});},Migration[_0x3111a1('0x17')][_0x3111a1('0xc')]=function(_0x458216){const _0x736917=_0x3111a1,_0x1cf03e=this;this[_0x736917('0x18')][_0x736917('0x1d')](function(){const _0x27417d=_0x736917;return _0x1cf03e[_0x27417d('0x3')][_0x27417d('0x13')][_0x27417d('0xc')](_0x458216)[_0x27417d('0x0')](function(){const _0xbfae40=_0x27417d;logger[_0xbfae40('0x12')](_0xbfae40('0x7'),_0x458216);})['catch'](function(_0xb2ce78){const _0x5a3517=_0x27417d;logger[_0x5a3517('0x12')](JSON['stringify'](_0xb2ce78));});});},Migration['prototype'][_0x3111a1('0x1')]=function(_0x1d1bae,_0x2fb1c5){const _0x3db407=_0x3111a1,_0x397ec9=this;this[_0x3db407('0x18')][_0x3db407('0x1d')](function(){const _0x5af20d=_0x3db407;return _0x397ec9[_0x5af20d('0x3')][_0x5af20d('0x1')](_0x1d1bae,_0x2fb1c5)[_0x5af20d('0x0')](function(){const _0x5505a8=_0x5af20d;logger[_0x5505a8('0x12')]('Removed\x20column\x20%s\x20from\x20%s',_0x2fb1c5,_0x1d1bae);})[_0x5af20d('0xe')](function(_0x47f0f4){const _0x39ea87=_0x5af20d;logger[_0x39ea87('0x12')](util[_0x39ea87('0x4')](_0x47f0f4,{'showHidden':![],'depth':null}));});});},Migration[_0x3111a1('0x17')]['renameColumn']=function(_0x2572cc,_0x1eb4a0,_0xf9a6b3){const _0x88c4b1=_0x3111a1,_0x41424a=this;this[_0x88c4b1('0x18')][_0x88c4b1('0x1d')](function(){const _0x3d1e15=_0x88c4b1;return _0x41424a['queryInterface'][_0x3d1e15('0x1c')](_0x2572cc,_0x1eb4a0,_0xf9a6b3)[_0x3d1e15('0x0')](function(){const _0x1bbe26=_0x3d1e15;logger[_0x1bbe26('0x12')](_0x1bbe26('0x15'),_0x1eb4a0,_0xf9a6b3,_0x2572cc);})[_0x3d1e15('0xe')](function(_0x3e0538){const _0x5c7022=_0x3d1e15;logger[_0x5c7022('0x12')](util[_0x5c7022('0x4')](_0x3e0538,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x3111a1('0xb')]=function(_0x64f47a){const _0x17a42a=_0x3111a1;this[_0x17a42a('0x18')][_0x17a42a('0x1d')](function(){return _0x64f47a();});},module[_0x3111a1('0x1b')]={'up':function(_0x50b29c){return new Promise(function(_0x5568f1){const _0x471f74=a954_0x4614,_0xd369ed=new Migration(_0x50b29c);_0xd369ed[_0x471f74('0xb')](_0x5568f1);});},'down':function(){}}; \ No newline at end of file +const a954_0x4e18=['../config/logger','query\x20%s','sequelize','Added\x20column\x20%s\x20to\x20%s','renameColumn','table\x20dropped\x20%s','tail','changeColumn','removeIndex','migration','addColumn','sequence','removeIndex\x20%s\x20%s','query','finally','exports','removeColumn','enqueue','catch','then','addIndex','addIndex\x20%s\x20%s\x20%s','util','queryInterface','final','stringify','info','dropTable','prototype'];(function(_0x4037d3,_0x4e182e){const _0x2e9df2=function(_0x12d73b){while(--_0x12d73b){_0x4037d3['push'](_0x4037d3['shift']());}};_0x2e9df2(++_0x4e182e);}(a954_0x4e18,0x16a));const a954_0x2e9d=function(_0x4037d3,_0x4e182e){_0x4037d3=_0x4037d3-0x0;let _0x2e9df2=a954_0x4e18[_0x4037d3];return _0x2e9df2;};const _0x132b22=a954_0x2e9d;'use strict';const util=require(_0x132b22('0x8')),logger=require(_0x132b22('0xf'))(_0x132b22('0x18')),Sequence=function(){};Sequence[_0x132b22('0xe')][_0x132b22('0x3')]=function(_0x12d73b){const _0x17229e=_0x132b22;this[_0x17229e('0x15')]=this[_0x17229e('0x15')]?this[_0x17229e('0x15')][_0x17229e('0x0')](_0x12d73b):_0x12d73b();};const Migration=function(_0x5029e5){const _0x5222a6=_0x132b22;this['queryInterface']=_0x5029e5,this[_0x5222a6('0x1a')]=new Sequence();};Migration[_0x132b22('0xe')]['changeColumn']=function(_0x1c9963,_0x49fa22,_0x3d4f0d){const _0xc9e257=_0x132b22,_0x507c7c=this;this[_0xc9e257('0x1a')]['enqueue'](function(){const _0x19b324=_0xc9e257;return _0x507c7c['queryInterface'][_0x19b324('0x16')](_0x1c9963,_0x49fa22,_0x3d4f0d)[_0x19b324('0x5')](function(){const _0x1d9a7c=_0x19b324;logger[_0x1d9a7c('0xc')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x49fa22,_0x1c9963);})[_0x19b324('0x4')](function(_0x2ad134){const _0x2a1e15=_0x19b324;logger['info'](JSON[_0x2a1e15('0xb')](_0x2ad134));});});},Migration[_0x132b22('0xe')][_0x132b22('0x19')]=function(_0x52d3d9,_0x27382b,_0x515c09){const _0x375051=_0x132b22,_0x24b54d=this;this[_0x375051('0x1a')]['enqueue'](function(){const _0x2605fe=_0x375051;return _0x24b54d[_0x2605fe('0x9')][_0x2605fe('0x19')](_0x52d3d9,_0x27382b,_0x515c09)['then'](function(){const _0x33ac59=_0x2605fe;logger[_0x33ac59('0xc')](_0x33ac59('0x12'),_0x27382b,_0x52d3d9);})[_0x2605fe('0x4')](function(_0xd164b3){const _0x23379b=_0x2605fe;logger[_0x23379b('0xc')](JSON[_0x23379b('0xb')](_0xd164b3));});});},Migration[_0x132b22('0xe')]['dropTable']=function(_0x423ad0){const _0x4b1a9c=_0x132b22,_0x21755e=this;this[_0x4b1a9c('0x1a')][_0x4b1a9c('0x3')](function(){const _0x29a88d=_0x4b1a9c;return _0x21755e[_0x29a88d('0x9')][_0x29a88d('0xd')](_0x423ad0,{'force':!![]})[_0x29a88d('0x5')](function(){const _0x2d7646=_0x29a88d;logger[_0x2d7646('0xc')](_0x2d7646('0x14'),_0x423ad0);})[_0x29a88d('0x4')](function(_0x1782e6){const _0x313754=_0x29a88d;logger[_0x313754('0xc')](JSON['stringify'](_0x1782e6));});});},Migration[_0x132b22('0xe')]['addIndex']=function(_0xd484a,_0x38006e,_0x48b6ef){const _0x3b0811=_0x132b22,_0xde878=this;this[_0x3b0811('0x1a')][_0x3b0811('0x3')](function(){const _0xc95e72=_0x3b0811;return _0xde878[_0xc95e72('0x9')][_0xc95e72('0x6')](_0xd484a,_0x38006e,{'indexName':_0x48b6ef})[_0xc95e72('0x5')](function(){const _0xba83e8=_0xc95e72;logger['info'](_0xba83e8('0x7'),_0xd484a,_0x38006e['join'](','),_0x48b6ef);})[_0xc95e72('0x4')](function(_0x2d28b5){const _0x2fae6c=_0xc95e72;logger[_0x2fae6c('0xc')](JSON[_0x2fae6c('0xb')](_0x2d28b5));});});},Migration[_0x132b22('0xe')][_0x132b22('0x17')]=function(_0x40a1f2,_0x3853e4){const _0x50a4f3=_0x132b22,_0x4e2514=this;this['sequence'][_0x50a4f3('0x3')](function(){const _0x469cce=_0x50a4f3;return _0x4e2514[_0x469cce('0x9')][_0x469cce('0x17')](_0x40a1f2,_0x3853e4)[_0x469cce('0x5')](function(){const _0x3e142f=_0x469cce;logger[_0x3e142f('0xc')](_0x3e142f('0x1b'),_0x40a1f2,_0x3853e4);})[_0x469cce('0x4')](function(_0x1c19f9){const _0x43ce0c=_0x469cce;logger[_0x43ce0c('0xc')](JSON['stringify'](_0x1c19f9));});});},Migration[_0x132b22('0xe')][_0x132b22('0x1c')]=function(_0x3c298c){const _0x2dcd1a=this;this['sequence']['enqueue'](function(){const _0x38ab85=a954_0x2e9d;return _0x2dcd1a[_0x38ab85('0x9')][_0x38ab85('0x11')][_0x38ab85('0x1c')](_0x3c298c)[_0x38ab85('0x5')](function(){const _0x362cb7=_0x38ab85;logger[_0x362cb7('0xc')](_0x362cb7('0x10'),_0x3c298c);})[_0x38ab85('0x4')](function(_0x1a1d78){const _0x1b357c=_0x38ab85;logger[_0x1b357c('0xc')](JSON[_0x1b357c('0xb')](_0x1a1d78));});});},Migration[_0x132b22('0xe')][_0x132b22('0x2')]=function(_0x2849ea,_0x2b522){const _0x5383f0=_0x132b22,_0x5dc4bb=this;this[_0x5383f0('0x1a')][_0x5383f0('0x3')](function(){const _0x366867=_0x5383f0;return _0x5dc4bb[_0x366867('0x9')]['removeColumn'](_0x2849ea,_0x2b522)[_0x366867('0x5')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x2b522,_0x2849ea);})['catch'](function(_0x1ed847){const _0x4918d9=_0x366867;logger[_0x4918d9('0xc')](util['inspect'](_0x1ed847,{'showHidden':![],'depth':null}));});});},Migration[_0x132b22('0xe')][_0x132b22('0x13')]=function(_0x4f0284,_0x54a9ee,_0x2b58fd){const _0x1b0a75=_0x132b22,_0x503db9=this;this[_0x1b0a75('0x1a')][_0x1b0a75('0x3')](function(){const _0x1753ce=_0x1b0a75;return _0x503db9['queryInterface'][_0x1753ce('0x13')](_0x4f0284,_0x54a9ee,_0x2b58fd)[_0x1753ce('0x5')](function(){const _0x4a7270=_0x1753ce;logger[_0x4a7270('0xc')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x54a9ee,_0x2b58fd,_0x4f0284);})[_0x1753ce('0x4')](function(_0x12e92d){const _0x277dfe=_0x1753ce;logger[_0x277dfe('0xc')](util['inspect'](_0x12e92d,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x132b22('0xa')]=function(_0xc73354){const _0x262b95=_0x132b22;this[_0x262b95('0x1a')][_0x262b95('0x3')](function(){return _0xc73354();});},module[_0x132b22('0x1')]={'up':function(_0xd56c54){return new Promise(function(_0x28beac){const _0xde6691=a954_0x2e9d,_0x526f32=new Migration(_0xd56c54);_0x526f32[_0xde6691('0xa')](_0x28beac);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.76.js b/server/migrations/2.0.76.js index a6aa50a..6968ba9 100644 --- a/server/migrations/2.0.76.js +++ b/server/migrations/2.0.76.js @@ -1 +1 @@ -const a955_0x8614=['ALTER\x20TABLE\x20report_openchannel_transfer\x20ENCRYPTION=\x27Y\x27;','catch','Removed\x20column\x20%s\x20from\x20%s','dropTable','renameColumn','hotdesk','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','../config/logger','enqueue','query','util','queryInterface','addIndex','sequence','BOOLEAN','removeIndex','removeColumn','ALTER\x20TABLE\x20report_fax_transfer\x20ENCRYPTION=\x27Y\x27;','info','stringify','inspect','sequelize','Changed\x20column\x20%s\x20in\x20table\x20%s','prototype','ALTER\x20TABLE\x20report_sms_transfer\x20ENCRYPTION=\x27Y\x27;','ALTER\x20TABLE\x20report_chat_transfer\x20ENCRYPTION=\x27Y\x27;','migration','then','final','Added\x20column\x20%s\x20to\x20%s','addColumn','tail','finally','query\x20%s','changeColumn'];(function(_0x2cd6f6,_0x861459){const _0x513ca7=function(_0x90e7b9){while(--_0x90e7b9){_0x2cd6f6['push'](_0x2cd6f6['shift']());}};_0x513ca7(++_0x861459);}(a955_0x8614,0x90));const a955_0x513c=function(_0x2cd6f6,_0x861459){_0x2cd6f6=_0x2cd6f6-0x0;let _0x513ca7=a955_0x8614[_0x2cd6f6];return _0x513ca7;};const _0x58b5f0=a955_0x513c;'use strict';const util=require(_0x58b5f0('0x6')),logger=require(_0x58b5f0('0x3'))(_0x58b5f0('0x16')),Sequence=function(){};Sequence[_0x58b5f0('0x13')][_0x58b5f0('0x4')]=function(_0x90e7b9){const _0x251230=_0x58b5f0;this[_0x251230('0x1b')]=this[_0x251230('0x1b')]?this[_0x251230('0x1b')][_0x251230('0x1c')](_0x90e7b9):_0x90e7b9();};const Migration=function(_0x3f7053){const _0x119a50=_0x58b5f0;this[_0x119a50('0x7')]=_0x3f7053,this[_0x119a50('0x9')]=new Sequence();};Migration[_0x58b5f0('0x13')]['changeColumn']=function(_0x4cff4,_0x21c932,_0x4972d2){const _0x47bcb0=_0x58b5f0,_0x4530ec=this;this[_0x47bcb0('0x9')][_0x47bcb0('0x4')](function(){const _0xe087a2=_0x47bcb0;return _0x4530ec[_0xe087a2('0x7')][_0xe087a2('0x1e')](_0x4cff4,_0x21c932,_0x4972d2)[_0xe087a2('0x17')](function(){const _0x12d764=_0xe087a2;logger[_0x12d764('0xe')](_0x12d764('0x12'),_0x21c932,_0x4cff4);})['catch'](function(_0x26663a){const _0x4c5d6c=_0xe087a2;logger[_0x4c5d6c('0xe')](JSON[_0x4c5d6c('0xf')](_0x26663a));});});},Migration[_0x58b5f0('0x13')][_0x58b5f0('0x1a')]=function(_0x327b72,_0x264621,_0x130f94){const _0x3c47b8=_0x58b5f0,_0x42ffbf=this;this[_0x3c47b8('0x9')][_0x3c47b8('0x4')](function(){const _0x5660c8=_0x3c47b8;return _0x42ffbf[_0x5660c8('0x7')][_0x5660c8('0x1a')](_0x327b72,_0x264621,_0x130f94)[_0x5660c8('0x17')](function(){const _0x12adda=_0x5660c8;logger[_0x12adda('0xe')](_0x12adda('0x19'),_0x264621,_0x327b72);})[_0x5660c8('0x20')](function(_0x448565){logger['info'](JSON['stringify'](_0x448565));});});},Migration[_0x58b5f0('0x13')][_0x58b5f0('0x22')]=function(_0x45198d){const _0x2ae005=_0x58b5f0,_0x49bc01=this;this['sequence'][_0x2ae005('0x4')](function(){const _0x337238=_0x2ae005;return _0x49bc01['queryInterface'][_0x337238('0x22')](_0x45198d,{'force':!![]})[_0x337238('0x17')](function(){const _0x4c16cf=_0x337238;logger[_0x4c16cf('0xe')]('table\x20dropped\x20%s',_0x45198d);})[_0x337238('0x20')](function(_0x3a78aa){const _0x2bd468=_0x337238;logger[_0x2bd468('0xe')](JSON[_0x2bd468('0xf')](_0x3a78aa));});});},Migration[_0x58b5f0('0x13')][_0x58b5f0('0x8')]=function(_0x5eb686,_0x30dbb0,_0x3b4f55){const _0x199830=_0x58b5f0,_0x13536=this;this[_0x199830('0x9')]['enqueue'](function(){const _0x343b05=_0x199830;return _0x13536[_0x343b05('0x7')][_0x343b05('0x8')](_0x5eb686,_0x30dbb0,{'indexName':_0x3b4f55})[_0x343b05('0x17')](function(){logger['info']('addIndex\x20%s\x20%s\x20%s',_0x5eb686,_0x30dbb0['join'](','),_0x3b4f55);})[_0x343b05('0x20')](function(_0x5a34d3){const _0x87d88=_0x343b05;logger['info'](JSON[_0x87d88('0xf')](_0x5a34d3));});});},Migration[_0x58b5f0('0x13')][_0x58b5f0('0xb')]=function(_0x40241c,_0x2f782e){const _0x5df30c=_0x58b5f0,_0x5f13c2=this;this[_0x5df30c('0x9')][_0x5df30c('0x4')](function(){const _0x143043=_0x5df30c;return _0x5f13c2[_0x143043('0x7')][_0x143043('0xb')](_0x40241c,_0x2f782e)['then'](function(){const _0x2123a4=_0x143043;logger[_0x2123a4('0xe')]('removeIndex\x20%s\x20%s',_0x40241c,_0x2f782e);})[_0x143043('0x20')](function(_0x1049aa){const _0x4e6189=_0x143043;logger[_0x4e6189('0xe')](JSON[_0x4e6189('0xf')](_0x1049aa));});});},Migration[_0x58b5f0('0x13')][_0x58b5f0('0x5')]=function(_0x12da76){const _0x29c60f=this;this['sequence']['enqueue'](function(){const _0x373d67=a955_0x513c;return _0x29c60f[_0x373d67('0x7')][_0x373d67('0x11')]['query'](_0x12da76)[_0x373d67('0x17')](function(){const _0x7e6bb2=_0x373d67;logger[_0x7e6bb2('0xe')](_0x7e6bb2('0x1d'),_0x12da76);})[_0x373d67('0x20')](function(_0x22b179){const _0x116d5b=_0x373d67;logger[_0x116d5b('0xe')](JSON[_0x116d5b('0xf')](_0x22b179));});});},Migration['prototype'][_0x58b5f0('0xc')]=function(_0x30201c,_0x355598){const _0x462d95=_0x58b5f0,_0x182357=this;this[_0x462d95('0x9')][_0x462d95('0x4')](function(){const _0x486b79=_0x462d95;return _0x182357[_0x486b79('0x7')][_0x486b79('0xc')](_0x30201c,_0x355598)[_0x486b79('0x17')](function(){const _0x160895=_0x486b79;logger['info'](_0x160895('0x21'),_0x355598,_0x30201c);})[_0x486b79('0x20')](function(_0x419133){const _0xd2de1a=_0x486b79;logger['info'](util[_0xd2de1a('0x10')](_0x419133,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x58b5f0('0x0')]=function(_0x2fd4e7,_0xe014c4,_0x307b51){const _0x45a670=_0x58b5f0,_0x316d95=this;this['sequence'][_0x45a670('0x4')](function(){const _0x21135d=_0x45a670;return _0x316d95[_0x21135d('0x7')][_0x21135d('0x0')](_0x2fd4e7,_0xe014c4,_0x307b51)['then'](function(){const _0x39a742=_0x21135d;logger[_0x39a742('0xe')](_0x39a742('0x2'),_0xe014c4,_0x307b51,_0x2fd4e7);})[_0x21135d('0x20')](function(_0x46cd67){const _0x5dc7bf=_0x21135d;logger['info'](util[_0x5dc7bf('0x10')](_0x46cd67,{'showHidden':![],'depth':null}));});});},Migration[_0x58b5f0('0x13')][_0x58b5f0('0x18')]=function(_0x231469){const _0x206904=_0x58b5f0;this[_0x206904('0x9')][_0x206904('0x4')](function(){return _0x231469();});},module['exports']={'up':function(_0x1d1bc7,_0x8d906c){return new Promise(function(_0x563b7e){const _0x162913=a955_0x513c,_0x5f0a54=new Migration(_0x1d1bc7);_0x5f0a54[_0x162913('0x5')]('TRUNCATE\x20sessions'),_0x5f0a54['query'](_0x162913('0x15')),_0x5f0a54[_0x162913('0x5')]('ALTER\x20TABLE\x20report_mail_transfer\x20ENCRYPTION=\x27Y\x27;'),_0x5f0a54[_0x162913('0x5')](_0x162913('0xd')),_0x5f0a54[_0x162913('0x5')](_0x162913('0x1f')),_0x5f0a54['query'](_0x162913('0x14')),_0x5f0a54[_0x162913('0x1a')]('users',_0x162913('0x1'),{'type':_0x8d906c[_0x162913('0xa')],'defaultValue':![]}),_0x5f0a54['final'](_0x563b7e);});},'down':function(){}}; \ No newline at end of file +const a955_0x4d54=['migration','../config/logger','inspect','exports','table\x20dropped\x20%s','removeIndex','ALTER\x20TABLE\x20report_fax_transfer\x20ENCRYPTION=\x27Y\x27;','renameColumn','removeIndex\x20%s\x20%s','TRUNCATE\x20sessions','util','addColumn','catch','query\x20%s','sequelize','users','sequence','queryInterface','tail','ALTER\x20TABLE\x20report_sms_transfer\x20ENCRYPTION=\x27Y\x27;','ALTER\x20TABLE\x20report_chat_transfer\x20ENCRYPTION=\x27Y\x27;','prototype','removeColumn','Removed\x20column\x20%s\x20from\x20%s','hotdesk','then','final','addIndex\x20%s\x20%s\x20%s','finally','addIndex','ALTER\x20TABLE\x20report_openchannel_transfer\x20ENCRYPTION=\x27Y\x27;','info','enqueue','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','dropTable','stringify','Added\x20column\x20%s\x20to\x20%s','ALTER\x20TABLE\x20report_mail_transfer\x20ENCRYPTION=\x27Y\x27;','query','changeColumn','BOOLEAN'];(function(_0x2dc839,_0x4d5405){const _0x183c37=function(_0x327c34){while(--_0x327c34){_0x2dc839['push'](_0x2dc839['shift']());}};_0x183c37(++_0x4d5405);}(a955_0x4d54,0xcc));const a955_0x183c=function(_0x2dc839,_0x4d5405){_0x2dc839=_0x2dc839-0x0;let _0x183c37=a955_0x4d54[_0x2dc839];return _0x183c37;};const _0x5866b0=a955_0x183c;'use strict';const util=require(_0x5866b0('0xb')),logger=require(_0x5866b0('0x2'))(_0x5866b0('0x1')),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x327c34){const _0x425b3c=_0x5866b0;this['tail']=this[_0x425b3c('0x13')]?this[_0x425b3c('0x13')][_0x425b3c('0x1d')](_0x327c34):_0x327c34();};const Migration=function(_0x47dfa3){const _0x5465bc=_0x5866b0;this[_0x5465bc('0x12')]=_0x47dfa3,this[_0x5465bc('0x11')]=new Sequence();};Migration[_0x5866b0('0x16')]['changeColumn']=function(_0x43f65e,_0x2ba8f0,_0x59862a){const _0x523d98=_0x5866b0,_0x441d90=this;this[_0x523d98('0x11')][_0x523d98('0x21')](function(){const _0x406501=_0x523d98;return _0x441d90[_0x406501('0x12')][_0x406501('0x28')](_0x43f65e,_0x2ba8f0,_0x59862a)['then'](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x2ba8f0,_0x43f65e);})[_0x406501('0xd')](function(_0xf40100){const _0x246e0e=_0x406501;logger[_0x246e0e('0x20')](JSON[_0x246e0e('0x24')](_0xf40100));});});},Migration['prototype'][_0x5866b0('0xc')]=function(_0x2cd54a,_0xd5a0b7,_0x23bb69){const _0x3771c1=_0x5866b0,_0x4dc4f0=this;this['sequence'][_0x3771c1('0x21')](function(){const _0x118a46=_0x3771c1;return _0x4dc4f0[_0x118a46('0x12')][_0x118a46('0xc')](_0x2cd54a,_0xd5a0b7,_0x23bb69)[_0x118a46('0x1a')](function(){const _0x272dd5=_0x118a46;logger[_0x272dd5('0x20')](_0x272dd5('0x25'),_0xd5a0b7,_0x2cd54a);})[_0x118a46('0xd')](function(_0x3335f3){logger['info'](JSON['stringify'](_0x3335f3));});});},Migration['prototype'][_0x5866b0('0x23')]=function(_0x27c2e0){const _0xdc9f4d=_0x5866b0,_0x5933d5=this;this[_0xdc9f4d('0x11')][_0xdc9f4d('0x21')](function(){const _0x5602ac=_0xdc9f4d;return _0x5933d5[_0x5602ac('0x12')]['dropTable'](_0x27c2e0,{'force':!![]})[_0x5602ac('0x1a')](function(){const _0x3f9a59=_0x5602ac;logger[_0x3f9a59('0x20')](_0x3f9a59('0x5'),_0x27c2e0);})[_0x5602ac('0xd')](function(_0x129658){const _0x8b194c=_0x5602ac;logger[_0x8b194c('0x20')](JSON['stringify'](_0x129658));});});},Migration[_0x5866b0('0x16')][_0x5866b0('0x1e')]=function(_0x3258c6,_0x569280,_0x2dc357){const _0x529e79=_0x5866b0,_0x319908=this;this['sequence'][_0x529e79('0x21')](function(){const _0x19bee0=_0x529e79;return _0x319908[_0x19bee0('0x12')][_0x19bee0('0x1e')](_0x3258c6,_0x569280,{'indexName':_0x2dc357})[_0x19bee0('0x1a')](function(){const _0x14d5cf=_0x19bee0;logger['info'](_0x14d5cf('0x1c'),_0x3258c6,_0x569280['join'](','),_0x2dc357);})[_0x19bee0('0xd')](function(_0x33d844){const _0x4554fa=_0x19bee0;logger[_0x4554fa('0x20')](JSON['stringify'](_0x33d844));});});},Migration[_0x5866b0('0x16')][_0x5866b0('0x6')]=function(_0x3dee17,_0x40602a){const _0x2ecbf1=_0x5866b0,_0x2d1fa0=this;this[_0x2ecbf1('0x11')]['enqueue'](function(){const _0x370324=_0x2ecbf1;return _0x2d1fa0[_0x370324('0x12')]['removeIndex'](_0x3dee17,_0x40602a)[_0x370324('0x1a')](function(){const _0x2dd4d1=_0x370324;logger[_0x2dd4d1('0x20')](_0x2dd4d1('0x9'),_0x3dee17,_0x40602a);})['catch'](function(_0x513a1d){const _0x49930c=_0x370324;logger[_0x49930c('0x20')](JSON['stringify'](_0x513a1d));});});},Migration[_0x5866b0('0x16')][_0x5866b0('0x27')]=function(_0x2ffa80){const _0x5adc93=_0x5866b0,_0x3084d2=this;this[_0x5adc93('0x11')][_0x5adc93('0x21')](function(){const _0xe8f18f=_0x5adc93;return _0x3084d2['queryInterface'][_0xe8f18f('0xf')][_0xe8f18f('0x27')](_0x2ffa80)[_0xe8f18f('0x1a')](function(){const _0x16f314=_0xe8f18f;logger[_0x16f314('0x20')](_0x16f314('0xe'),_0x2ffa80);})[_0xe8f18f('0xd')](function(_0x8a613f){const _0x5b12d1=_0xe8f18f;logger[_0x5b12d1('0x20')](JSON[_0x5b12d1('0x24')](_0x8a613f));});});},Migration[_0x5866b0('0x16')]['removeColumn']=function(_0x27d281,_0x31773e){const _0x1ad1cd=_0x5866b0,_0x585dc0=this;this['sequence'][_0x1ad1cd('0x21')](function(){const _0x442e22=_0x1ad1cd;return _0x585dc0[_0x442e22('0x12')][_0x442e22('0x17')](_0x27d281,_0x31773e)[_0x442e22('0x1a')](function(){const _0x58195e=_0x442e22;logger[_0x58195e('0x20')](_0x58195e('0x18'),_0x31773e,_0x27d281);})[_0x442e22('0xd')](function(_0x1f5b94){const _0x5a1523=_0x442e22;logger[_0x5a1523('0x20')](util['inspect'](_0x1f5b94,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x5866b0('0x8')]=function(_0x183f83,_0x583d1e,_0x45c31b){const _0x262f6e=_0x5866b0,_0x5e3738=this;this[_0x262f6e('0x11')][_0x262f6e('0x21')](function(){const _0x244e41=_0x262f6e;return _0x5e3738[_0x244e41('0x12')][_0x244e41('0x8')](_0x183f83,_0x583d1e,_0x45c31b)[_0x244e41('0x1a')](function(){const _0x43be67=_0x244e41;logger[_0x43be67('0x20')](_0x43be67('0x22'),_0x583d1e,_0x45c31b,_0x183f83);})[_0x244e41('0xd')](function(_0x1fbe69){const _0x28f618=_0x244e41;logger[_0x28f618('0x20')](util[_0x28f618('0x3')](_0x1fbe69,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x9fcada){const _0x1fd8d7=_0x5866b0;this[_0x1fd8d7('0x11')]['enqueue'](function(){return _0x9fcada();});},module[_0x5866b0('0x4')]={'up':function(_0x44302b,_0x5c810d){return new Promise(function(_0x4aae33){const _0x56da55=a955_0x183c,_0x540d43=new Migration(_0x44302b);_0x540d43[_0x56da55('0x27')](_0x56da55('0xa')),_0x540d43[_0x56da55('0x27')](_0x56da55('0x15')),_0x540d43[_0x56da55('0x27')](_0x56da55('0x26')),_0x540d43['query'](_0x56da55('0x7')),_0x540d43['query'](_0x56da55('0x1f')),_0x540d43[_0x56da55('0x27')](_0x56da55('0x14')),_0x540d43[_0x56da55('0xc')](_0x56da55('0x10'),_0x56da55('0x19'),{'type':_0x5c810d[_0x56da55('0x0')],'defaultValue':![]}),_0x540d43[_0x56da55('0x1b')](_0x4aae33);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.77.js b/server/migrations/2.0.77.js index b4517ea..3971254 100644 --- a/server/migrations/2.0.77.js +++ b/server/migrations/2.0.77.js @@ -1 +1 @@ -const a956_0x1c69=['info','../config/logger','dropTable','enqueue','final','tail','Removed\x20column\x20%s\x20from\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','report_square','addIndex','inspect','then','bot','renameColumn','users','Added\x20column\x20%s\x20to\x20%s','removeColumn','interface','removeIndex','stringify','join','sequence','changeColumn','query','finally','addColumn','queryInterface','BOOLEAN','prototype','STRING','catch','table\x20dropped\x20%s'];(function(_0x33f007,_0x1c6928){const _0x2e8c25=function(_0x347a26){while(--_0x347a26){_0x33f007['push'](_0x33f007['shift']());}};_0x2e8c25(++_0x1c6928);}(a956_0x1c69,0x7c));const a956_0x2e8c=function(_0x33f007,_0x1c6928){_0x33f007=_0x33f007-0x0;let _0x2e8c25=a956_0x1c69[_0x33f007];return _0x2e8c25;};const _0x1627ab=a956_0x2e8c;'use strict';const util=require('util'),logger=require(_0x1627ab('0x5'))('migration'),Sequence=function(){};Sequence[_0x1627ab('0x0')]['enqueue']=function(_0x347a26){const _0x24b1a9=_0x1627ab;this[_0x24b1a9('0x9')]=this['tail']?this[_0x24b1a9('0x9')][_0x24b1a9('0x1c')](_0x347a26):_0x347a26();};const Migration=function(_0x2f140b){const _0x281ff6=_0x1627ab;this[_0x281ff6('0x1e')]=_0x2f140b,this['sequence']=new Sequence();};Migration[_0x1627ab('0x0')][_0x1627ab('0x1a')]=function(_0x2c0438,_0x3841d2,_0x1fbc86){const _0x516ffc=_0x1627ab,_0xf29ecd=this;this[_0x516ffc('0x19')][_0x516ffc('0x7')](function(){const _0x774e28=_0x516ffc;return _0xf29ecd[_0x774e28('0x1e')][_0x774e28('0x1a')](_0x2c0438,_0x3841d2,_0x1fbc86)[_0x774e28('0xf')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x3841d2,_0x2c0438);})[_0x774e28('0x2')](function(_0x20e454){const _0x8bcc5d=_0x774e28;logger[_0x8bcc5d('0x4')](JSON[_0x8bcc5d('0x17')](_0x20e454));});});},Migration[_0x1627ab('0x0')][_0x1627ab('0x1d')]=function(_0x30c533,_0xc3d2c6,_0x38e303){const _0xb6d11a=_0x1627ab,_0x5ed57a=this;this[_0xb6d11a('0x19')][_0xb6d11a('0x7')](function(){const _0x38a98e=_0xb6d11a;return _0x5ed57a[_0x38a98e('0x1e')]['addColumn'](_0x30c533,_0xc3d2c6,_0x38e303)[_0x38a98e('0xf')](function(){const _0x187aa3=_0x38a98e;logger[_0x187aa3('0x4')](_0x187aa3('0x13'),_0xc3d2c6,_0x30c533);})[_0x38a98e('0x2')](function(_0x522a3b){const _0xc5f10c=_0x38a98e;logger['info'](JSON[_0xc5f10c('0x17')](_0x522a3b));});});},Migration['prototype'][_0x1627ab('0x6')]=function(_0x5ed1b6){const _0x4d5f3c=_0x1627ab,_0x15f546=this;this[_0x4d5f3c('0x19')][_0x4d5f3c('0x7')](function(){const _0x22b056=_0x4d5f3c;return _0x15f546[_0x22b056('0x1e')][_0x22b056('0x6')](_0x5ed1b6,{'force':!![]})['then'](function(){const _0x3dcdbb=_0x22b056;logger[_0x3dcdbb('0x4')](_0x3dcdbb('0x3'),_0x5ed1b6);})['catch'](function(_0x1ab535){const _0x3f8b45=_0x22b056;logger['info'](JSON[_0x3f8b45('0x17')](_0x1ab535));});});},Migration[_0x1627ab('0x0')][_0x1627ab('0xd')]=function(_0x8ded17,_0x58332b,_0x53adad){const _0x3da473=_0x1627ab,_0x29ec10=this;this['sequence'][_0x3da473('0x7')](function(){const _0x2f36a4=_0x3da473;return _0x29ec10[_0x2f36a4('0x1e')][_0x2f36a4('0xd')](_0x8ded17,_0x58332b,{'indexName':_0x53adad})[_0x2f36a4('0xf')](function(){const _0x51f1dd=_0x2f36a4;logger['info']('addIndex\x20%s\x20%s\x20%s',_0x8ded17,_0x58332b[_0x51f1dd('0x18')](','),_0x53adad);})['catch'](function(_0x3def8e){const _0x16f2b4=_0x2f36a4;logger['info'](JSON[_0x16f2b4('0x17')](_0x3def8e));});});},Migration['prototype'][_0x1627ab('0x16')]=function(_0x47ff72,_0x19d79e){const _0x40b8f7=_0x1627ab,_0x3dda39=this;this[_0x40b8f7('0x19')][_0x40b8f7('0x7')](function(){const _0x32bc1b=_0x40b8f7;return _0x3dda39[_0x32bc1b('0x1e')]['removeIndex'](_0x47ff72,_0x19d79e)['then'](function(){const _0x38d0da=_0x32bc1b;logger[_0x38d0da('0x4')]('removeIndex\x20%s\x20%s',_0x47ff72,_0x19d79e);})[_0x32bc1b('0x2')](function(_0x10a36d){const _0x5a6465=_0x32bc1b;logger[_0x5a6465('0x4')](JSON[_0x5a6465('0x17')](_0x10a36d));});});},Migration[_0x1627ab('0x0')][_0x1627ab('0x1b')]=function(_0x4c8f64){const _0x2aead6=_0x1627ab,_0x2cdf72=this;this[_0x2aead6('0x19')][_0x2aead6('0x7')](function(){const _0x5427ed=_0x2aead6;return _0x2cdf72[_0x5427ed('0x1e')]['sequelize'][_0x5427ed('0x1b')](_0x4c8f64)['then'](function(){const _0x30aea6=_0x5427ed;logger[_0x30aea6('0x4')]('query\x20%s',_0x4c8f64);})['catch'](function(_0x4c2033){const _0x58be0e=_0x5427ed;logger[_0x58be0e('0x4')](JSON[_0x58be0e('0x17')](_0x4c2033));});});},Migration[_0x1627ab('0x0')]['removeColumn']=function(_0x331de7,_0x1007e5){const _0xb0c74d=_0x1627ab,_0x5724c8=this;this[_0xb0c74d('0x19')][_0xb0c74d('0x7')](function(){const _0x2c7870=_0xb0c74d;return _0x5724c8[_0x2c7870('0x1e')][_0x2c7870('0x14')](_0x331de7,_0x1007e5)[_0x2c7870('0xf')](function(){const _0x1b6420=_0x2c7870;logger[_0x1b6420('0x4')](_0x1b6420('0xa'),_0x1007e5,_0x331de7);})[_0x2c7870('0x2')](function(_0x309921){const _0x16d913=_0x2c7870;logger[_0x16d913('0x4')](util[_0x16d913('0xe')](_0x309921,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x1627ab('0x11')]=function(_0x54ac61,_0x5db899,_0x31665c){const _0x3d274f=_0x1627ab,_0x2af84c=this;this['sequence'][_0x3d274f('0x7')](function(){const _0x47a7ae=_0x3d274f;return _0x2af84c[_0x47a7ae('0x1e')]['renameColumn'](_0x54ac61,_0x5db899,_0x31665c)['then'](function(){const _0x5519f8=_0x47a7ae;logger['info'](_0x5519f8('0xb'),_0x5db899,_0x31665c,_0x54ac61);})[_0x47a7ae('0x2')](function(_0x311884){const _0x58b385=_0x47a7ae;logger['info'](util[_0x58b385('0xe')](_0x311884,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x352480){const _0x33771b=_0x1627ab;this[_0x33771b('0x19')]['enqueue'](function(){return _0x352480();});},module['exports']={'up':function(_0x385c5e,_0x4aa6f6){return new Promise(function(_0x4d4659){const _0x227a6a=a956_0x2e8c,_0x28645f=new Migration(_0x385c5e);_0x28645f[_0x227a6a('0x1d')](_0x227a6a('0xc'),_0x227a6a('0x10'),{'type':_0x4aa6f6[_0x227a6a('0x1f')],'defaultValue':![]}),_0x28645f[_0x227a6a('0x1d')](_0x227a6a('0x12'),_0x227a6a('0x15'),{'type':_0x4aa6f6[_0x227a6a('0x1')],'defaultValue':null}),_0x28645f[_0x227a6a('0x1d')](_0x227a6a('0x12'),'privacyEnabled',{'type':_0x4aa6f6[_0x227a6a('0x1f')],'defaultValue':![]}),_0x28645f[_0x227a6a('0x8')](_0x4d4659);});},'down':function(){}}; \ No newline at end of file +const a956_0x3930=['dropTable','join','Added\x20column\x20%s\x20to\x20%s','sequence','finally','renameColumn','changeColumn','table\x20dropped\x20%s','util','addIndex','tail','Removed\x20column\x20%s\x20from\x20%s','final','migration','enqueue','addIndex\x20%s\x20%s\x20%s','bot','../config/logger','query\x20%s','stringify','privacyEnabled','prototype','users','catch','interface','removeIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','exports','inspect','info','queryInterface','then','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addColumn','sequelize','report_square','query','BOOLEAN'];(function(_0x37140a,_0x393002){const _0x4e084c=function(_0x10d70e){while(--_0x10d70e){_0x37140a['push'](_0x37140a['shift']());}};_0x4e084c(++_0x393002);}(a956_0x3930,0x116));const a956_0x4e08=function(_0x37140a,_0x393002){_0x37140a=_0x37140a-0x0;let _0x4e084c=a956_0x3930[_0x37140a];return _0x4e084c;};const _0x17ba8e=a956_0x4e08;'use strict';const util=require(_0x17ba8e('0x22')),logger=require(_0x17ba8e('0x5'))(_0x17ba8e('0x1')),Sequence=function(){};Sequence[_0x17ba8e('0x9')]['enqueue']=function(_0x10d70e){const _0x136ff2=_0x17ba8e;this['tail']=this[_0x136ff2('0x24')]?this[_0x136ff2('0x24')][_0x136ff2('0x1e')](_0x10d70e):_0x10d70e();};const Migration=function(_0x2ef951){const _0x26b8cd=_0x17ba8e;this[_0x26b8cd('0x12')]=_0x2ef951,this[_0x26b8cd('0x1d')]=new Sequence();};Migration[_0x17ba8e('0x9')][_0x17ba8e('0x20')]=function(_0x222800,_0x2121fb,_0x4bbacc){const _0x11b24a=_0x17ba8e,_0x23aa2f=this;this[_0x11b24a('0x1d')][_0x11b24a('0x2')](function(){const _0xefbb03=_0x11b24a;return _0x23aa2f[_0xefbb03('0x12')][_0xefbb03('0x20')](_0x222800,_0x2121fb,_0x4bbacc)[_0xefbb03('0x13')](function(){const _0x197c7d=_0xefbb03;logger[_0x197c7d('0x11')](_0x197c7d('0xe'),_0x2121fb,_0x222800);})[_0xefbb03('0xb')](function(_0x213f3d){const _0x29ba8b=_0xefbb03;logger[_0x29ba8b('0x11')](JSON['stringify'](_0x213f3d));});});},Migration[_0x17ba8e('0x9')][_0x17ba8e('0x15')]=function(_0x5381b3,_0x5c0cec,_0x4bcd14){const _0x101170=_0x17ba8e,_0x5288c7=this;this[_0x101170('0x1d')][_0x101170('0x2')](function(){const _0x156d48=_0x101170;return _0x5288c7[_0x156d48('0x12')][_0x156d48('0x15')](_0x5381b3,_0x5c0cec,_0x4bcd14)[_0x156d48('0x13')](function(){const _0x4f1882=_0x156d48;logger[_0x4f1882('0x11')](_0x4f1882('0x1c'),_0x5c0cec,_0x5381b3);})[_0x156d48('0xb')](function(_0x17fea8){logger['info'](JSON['stringify'](_0x17fea8));});});},Migration[_0x17ba8e('0x9')][_0x17ba8e('0x1a')]=function(_0x4e6cf3){const _0x3eff76=_0x17ba8e,_0x5c152f=this;this[_0x3eff76('0x1d')][_0x3eff76('0x2')](function(){const _0x38e4e6=_0x3eff76;return _0x5c152f['queryInterface'][_0x38e4e6('0x1a')](_0x4e6cf3,{'force':!![]})[_0x38e4e6('0x13')](function(){const _0x5c4093=_0x38e4e6;logger[_0x5c4093('0x11')](_0x5c4093('0x21'),_0x4e6cf3);})[_0x38e4e6('0xb')](function(_0xd27b55){const _0x1dca44=_0x38e4e6;logger[_0x1dca44('0x11')](JSON[_0x1dca44('0x7')](_0xd27b55));});});},Migration[_0x17ba8e('0x9')][_0x17ba8e('0x23')]=function(_0x5af9b5,_0x3898fe,_0x124a89){const _0x1064ed=_0x17ba8e,_0x46c124=this;this[_0x1064ed('0x1d')][_0x1064ed('0x2')](function(){const _0x1b5385=_0x1064ed;return _0x46c124['queryInterface'][_0x1b5385('0x23')](_0x5af9b5,_0x3898fe,{'indexName':_0x124a89})[_0x1b5385('0x13')](function(){const _0x399da4=_0x1b5385;logger[_0x399da4('0x11')](_0x399da4('0x3'),_0x5af9b5,_0x3898fe[_0x399da4('0x1b')](','),_0x124a89);})[_0x1b5385('0xb')](function(_0x33dfdf){const _0x3e0eef=_0x1b5385;logger[_0x3e0eef('0x11')](JSON[_0x3e0eef('0x7')](_0x33dfdf));});});},Migration[_0x17ba8e('0x9')][_0x17ba8e('0xd')]=function(_0x7d8cae,_0x1209be){const _0x2728bb=_0x17ba8e,_0x267e70=this;this[_0x2728bb('0x1d')][_0x2728bb('0x2')](function(){const _0x45f0d8=_0x2728bb;return _0x267e70[_0x45f0d8('0x12')][_0x45f0d8('0xd')](_0x7d8cae,_0x1209be)[_0x45f0d8('0x13')](function(){const _0x580d78=_0x45f0d8;logger[_0x580d78('0x11')]('removeIndex\x20%s\x20%s',_0x7d8cae,_0x1209be);})[_0x45f0d8('0xb')](function(_0x151e96){const _0x4ccd30=_0x45f0d8;logger[_0x4ccd30('0x11')](JSON['stringify'](_0x151e96));});});},Migration[_0x17ba8e('0x9')][_0x17ba8e('0x18')]=function(_0x3fecd6){const _0x45f12a=this;this['sequence']['enqueue'](function(){const _0xa973be=a956_0x4e08;return _0x45f12a[_0xa973be('0x12')][_0xa973be('0x16')][_0xa973be('0x18')](_0x3fecd6)[_0xa973be('0x13')](function(){const _0x5e9922=_0xa973be;logger['info'](_0x5e9922('0x6'),_0x3fecd6);})[_0xa973be('0xb')](function(_0x1ad390){logger['info'](JSON['stringify'](_0x1ad390));});});},Migration[_0x17ba8e('0x9')]['removeColumn']=function(_0x4f89eb,_0x3375c2){const _0x38480a=_0x17ba8e,_0x3c2e8d=this;this[_0x38480a('0x1d')]['enqueue'](function(){const _0x2807eb=_0x38480a;return _0x3c2e8d[_0x2807eb('0x12')]['removeColumn'](_0x4f89eb,_0x3375c2)['then'](function(){const _0x4ecc69=_0x2807eb;logger[_0x4ecc69('0x11')](_0x4ecc69('0x25'),_0x3375c2,_0x4f89eb);})['catch'](function(_0x109eb4){const _0x298bd8=_0x2807eb;logger[_0x298bd8('0x11')](util['inspect'](_0x109eb4,{'showHidden':![],'depth':null}));});});},Migration[_0x17ba8e('0x9')]['renameColumn']=function(_0x1d4b4c,_0x14b4fb,_0x182f4c){const _0x45dffa=_0x17ba8e,_0x478731=this;this[_0x45dffa('0x1d')][_0x45dffa('0x2')](function(){const _0x137fca=_0x45dffa;return _0x478731[_0x137fca('0x12')][_0x137fca('0x1f')](_0x1d4b4c,_0x14b4fb,_0x182f4c)[_0x137fca('0x13')](function(){const _0x1f47f2=_0x137fca;logger[_0x1f47f2('0x11')](_0x1f47f2('0x14'),_0x14b4fb,_0x182f4c,_0x1d4b4c);})[_0x137fca('0xb')](function(_0x2a8c34){const _0x30c1a4=_0x137fca;logger[_0x30c1a4('0x11')](util[_0x30c1a4('0x10')](_0x2a8c34,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x3f320f){const _0x579046=_0x17ba8e;this['sequence'][_0x579046('0x2')](function(){return _0x3f320f();});},module[_0x17ba8e('0xf')]={'up':function(_0x46be71,_0x5aa83a){return new Promise(function(_0x1c9a4b){const _0x2574ab=a956_0x4e08,_0x1d5445=new Migration(_0x46be71);_0x1d5445[_0x2574ab('0x15')](_0x2574ab('0x17'),_0x2574ab('0x4'),{'type':_0x5aa83a[_0x2574ab('0x19')],'defaultValue':![]}),_0x1d5445[_0x2574ab('0x15')]('users',_0x2574ab('0xc'),{'type':_0x5aa83a['STRING'],'defaultValue':null}),_0x1d5445['addColumn'](_0x2574ab('0xa'),_0x2574ab('0x8'),{'type':_0x5aa83a[_0x2574ab('0x19')],'defaultValue':![]}),_0x1d5445[_0x2574ab('0x0')](_0x1c9a4b);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.78.js b/server/migrations/2.0.78.js index 3112420..72989e4 100644 --- a/server/migrations/2.0.78.js +++ b/server/migrations/2.0.78.js @@ -1 +1 @@ -const a957_0x4d6c=['Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','catch','dropTable','enqueue','Removed\x20column\x20%s\x20from\x20%s','query\x20%s','sequence','ALTER\x20TABLE\x20square_messages\x20ENCRYPTION=\x27Y\x27;','tail','removeColumn','inspect','migration','stringify','removeIndex','then','addIndex','removeIndex\x20%s\x20%s','join','info','query','final','finally','exports','renameColumn','../config/logger','changeColumn','addColumn','util','queryInterface','prototype'];(function(_0x2cf02a,_0x4d6c79){const _0x5319d=function(_0x4d75ff){while(--_0x4d75ff){_0x2cf02a['push'](_0x2cf02a['shift']());}};_0x5319d(++_0x4d6c79);}(a957_0x4d6c,0xb2));const a957_0x5319=function(_0x2cf02a,_0x4d6c79){_0x2cf02a=_0x2cf02a-0x0;let _0x5319d=a957_0x4d6c[_0x2cf02a];return _0x5319d;};const _0x2afadc=a957_0x5319;'use strict';const util=require(_0x2afadc('0x1d')),logger=require(_0x2afadc('0x1a'))(_0x2afadc('0xd')),Sequence=function(){};Sequence[_0x2afadc('0x1')][_0x2afadc('0x5')]=function(_0x4d75ff){const _0x10bde6=_0x2afadc;this['tail']=this['tail']?this[_0x10bde6('0xa')][_0x10bde6('0x17')](_0x4d75ff):_0x4d75ff();};const Migration=function(_0x4313cc){const _0x35ac3d=_0x2afadc;this['queryInterface']=_0x4313cc,this[_0x35ac3d('0x8')]=new Sequence();};Migration[_0x2afadc('0x1')][_0x2afadc('0x1b')]=function(_0x3da191,_0x18ab5d,_0x4959ce){const _0x41d07f=_0x2afadc,_0x235bab=this;this[_0x41d07f('0x8')][_0x41d07f('0x5')](function(){const _0xe25a5f=_0x41d07f;return _0x235bab[_0xe25a5f('0x0')][_0xe25a5f('0x1b')](_0x3da191,_0x18ab5d,_0x4959ce)[_0xe25a5f('0x10')](function(){const _0x3b633f=_0xe25a5f;logger[_0x3b633f('0x14')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x18ab5d,_0x3da191);})[_0xe25a5f('0x3')](function(_0x2eb6fe){const _0x160d90=_0xe25a5f;logger[_0x160d90('0x14')](JSON[_0x160d90('0xe')](_0x2eb6fe));});});},Migration[_0x2afadc('0x1')][_0x2afadc('0x1c')]=function(_0x3d2bdb,_0x344c0d,_0x2b6830){const _0x4d8c53=_0x2afadc,_0x44eab1=this;this['sequence'][_0x4d8c53('0x5')](function(){const _0x472e6d=_0x4d8c53;return _0x44eab1[_0x472e6d('0x0')]['addColumn'](_0x3d2bdb,_0x344c0d,_0x2b6830)['then'](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x344c0d,_0x3d2bdb);})[_0x472e6d('0x3')](function(_0xf07fc9){const _0xc5a33d=_0x472e6d;logger[_0xc5a33d('0x14')](JSON[_0xc5a33d('0xe')](_0xf07fc9));});});},Migration[_0x2afadc('0x1')][_0x2afadc('0x4')]=function(_0xb45e87){const _0xcdf508=this;this['sequence']['enqueue'](function(){const _0x4ce912=a957_0x5319;return _0xcdf508[_0x4ce912('0x0')][_0x4ce912('0x4')](_0xb45e87,{'force':!![]})[_0x4ce912('0x10')](function(){const _0x36b797=_0x4ce912;logger[_0x36b797('0x14')]('table\x20dropped\x20%s',_0xb45e87);})[_0x4ce912('0x3')](function(_0x4ece3c){const _0x527be0=_0x4ce912;logger[_0x527be0('0x14')](JSON[_0x527be0('0xe')](_0x4ece3c));});});},Migration[_0x2afadc('0x1')]['addIndex']=function(_0x5adb35,_0x11fca8,_0x2fe013){const _0x46da20=_0x2afadc,_0x31fb88=this;this[_0x46da20('0x8')][_0x46da20('0x5')](function(){const _0x1c4a32=_0x46da20;return _0x31fb88[_0x1c4a32('0x0')][_0x1c4a32('0x11')](_0x5adb35,_0x11fca8,{'indexName':_0x2fe013})['then'](function(){const _0x34f57e=_0x1c4a32;logger[_0x34f57e('0x14')]('addIndex\x20%s\x20%s\x20%s',_0x5adb35,_0x11fca8[_0x34f57e('0x13')](','),_0x2fe013);})['catch'](function(_0x40c192){const _0x494160=_0x1c4a32;logger['info'](JSON[_0x494160('0xe')](_0x40c192));});});},Migration['prototype'][_0x2afadc('0xf')]=function(_0x371cb9,_0x491449){const _0x160e37=_0x2afadc,_0x47ea5f=this;this[_0x160e37('0x8')][_0x160e37('0x5')](function(){const _0x571129=_0x160e37;return _0x47ea5f[_0x571129('0x0')]['removeIndex'](_0x371cb9,_0x491449)[_0x571129('0x10')](function(){const _0x724039=_0x571129;logger[_0x724039('0x14')](_0x724039('0x12'),_0x371cb9,_0x491449);})['catch'](function(_0x7dfcc7){const _0x97f510=_0x571129;logger['info'](JSON[_0x97f510('0xe')](_0x7dfcc7));});});},Migration['prototype'][_0x2afadc('0x15')]=function(_0x2db38e){const _0x34747d=_0x2afadc,_0x2c5417=this;this[_0x34747d('0x8')][_0x34747d('0x5')](function(){const _0x5008e2=_0x34747d;return _0x2c5417[_0x5008e2('0x0')]['sequelize'][_0x5008e2('0x15')](_0x2db38e)[_0x5008e2('0x10')](function(){const _0x18c8c0=_0x5008e2;logger[_0x18c8c0('0x14')](_0x18c8c0('0x7'),_0x2db38e);})['catch'](function(_0x2198c0){const _0x41b452=_0x5008e2;logger[_0x41b452('0x14')](JSON[_0x41b452('0xe')](_0x2198c0));});});},Migration['prototype'][_0x2afadc('0xb')]=function(_0x53533e,_0x56c431){const _0x4e752c=_0x2afadc,_0x1c4268=this;this['sequence'][_0x4e752c('0x5')](function(){const _0x4c25d9=_0x4e752c;return _0x1c4268[_0x4c25d9('0x0')][_0x4c25d9('0xb')](_0x53533e,_0x56c431)[_0x4c25d9('0x10')](function(){const _0x32f6c1=_0x4c25d9;logger[_0x32f6c1('0x14')](_0x32f6c1('0x6'),_0x56c431,_0x53533e);})[_0x4c25d9('0x3')](function(_0x2fe4bb){const _0x5c45b3=_0x4c25d9;logger['info'](util[_0x5c45b3('0xc')](_0x2fe4bb,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x2afadc('0x19')]=function(_0x2c5a86,_0x16bfcd,_0x57c0bc){const _0x45f158=_0x2afadc,_0x20d41b=this;this[_0x45f158('0x8')][_0x45f158('0x5')](function(){const _0x542419=_0x45f158;return _0x20d41b[_0x542419('0x0')][_0x542419('0x19')](_0x2c5a86,_0x16bfcd,_0x57c0bc)[_0x542419('0x10')](function(){const _0x1ab5ed=_0x542419;logger['info'](_0x1ab5ed('0x2'),_0x16bfcd,_0x57c0bc,_0x2c5a86);})[_0x542419('0x3')](function(_0x391bef){const _0x15d048=_0x542419;logger[_0x15d048('0x14')](util[_0x15d048('0xc')](_0x391bef,{'showHidden':![],'depth':null}));});});},Migration[_0x2afadc('0x1')]['final']=function(_0x3f3772){const _0x2379c8=_0x2afadc;this[_0x2379c8('0x8')][_0x2379c8('0x5')](function(){return _0x3f3772();});},module[_0x2afadc('0x18')]={'up':function(_0x344e43){return new Promise(function(_0x161da8){const _0x29b9d1=a957_0x5319,_0x3fc815=new Migration(_0x344e43);_0x3fc815['query'](_0x29b9d1('0x9')),_0x3fc815[_0x29b9d1('0x16')](_0x161da8);});},'down':function(){}}; \ No newline at end of file +const a957_0x599f=['finally','queryInterface','changeColumn','query','removeIndex','enqueue','prototype','migration','addIndex','inspect','sequelize','Removed\x20column\x20%s\x20from\x20%s','addColumn','dropTable','catch','info','../config/logger','join','sequence','tail','query\x20%s','table\x20dropped\x20%s','final','renameColumn','stringify','exports','then'];(function(_0x4a6d07,_0x599f5e){const _0x26c8ea=function(_0x51cd7e){while(--_0x51cd7e){_0x4a6d07['push'](_0x4a6d07['shift']());}};_0x26c8ea(++_0x599f5e);}(a957_0x599f,0x187));const a957_0x26c8=function(_0x4a6d07,_0x599f5e){_0x4a6d07=_0x4a6d07-0x0;let _0x26c8ea=a957_0x599f[_0x4a6d07];return _0x26c8ea;};const _0x50fa53=a957_0x26c8;'use strict';const util=require('util'),logger=require(_0x50fa53('0x3'))(_0x50fa53('0x15')),Sequence=function(){};Sequence['prototype'][_0x50fa53('0x13')]=function(_0x51cd7e){const _0x567ad0=_0x50fa53;this[_0x567ad0('0x6')]=this[_0x567ad0('0x6')]?this['tail'][_0x567ad0('0xe')](_0x51cd7e):_0x51cd7e();};const Migration=function(_0x1e5509){const _0x4f1771=_0x50fa53;this[_0x4f1771('0xf')]=_0x1e5509,this[_0x4f1771('0x5')]=new Sequence();};Migration[_0x50fa53('0x14')][_0x50fa53('0x10')]=function(_0x5cc35f,_0x396f3b,_0x2e421a){const _0x592d4a=_0x50fa53,_0x7d70c2=this;this[_0x592d4a('0x5')]['enqueue'](function(){const _0x13a04f=_0x592d4a;return _0x7d70c2['queryInterface'][_0x13a04f('0x10')](_0x5cc35f,_0x396f3b,_0x2e421a)['then'](function(){const _0x264740=_0x13a04f;logger[_0x264740('0x2')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x396f3b,_0x5cc35f);})[_0x13a04f('0x1')](function(_0x1d9624){const _0x151cba=_0x13a04f;logger[_0x151cba('0x2')](JSON[_0x151cba('0xb')](_0x1d9624));});});},Migration[_0x50fa53('0x14')][_0x50fa53('0x1a')]=function(_0x4eebb7,_0x57ce18,_0x115edf){const _0x2b6fd6=_0x50fa53,_0x1d52d8=this;this[_0x2b6fd6('0x5')][_0x2b6fd6('0x13')](function(){const _0x345f54=_0x2b6fd6;return _0x1d52d8[_0x345f54('0xf')][_0x345f54('0x1a')](_0x4eebb7,_0x57ce18,_0x115edf)[_0x345f54('0xd')](function(){const _0x1b7d8b=_0x345f54;logger[_0x1b7d8b('0x2')]('Added\x20column\x20%s\x20to\x20%s',_0x57ce18,_0x4eebb7);})['catch'](function(_0x3ed355){const _0x394d1c=_0x345f54;logger[_0x394d1c('0x2')](JSON['stringify'](_0x3ed355));});});},Migration[_0x50fa53('0x14')][_0x50fa53('0x0')]=function(_0x3d59e2){const _0x9398a8=_0x50fa53,_0x595dec=this;this[_0x9398a8('0x5')][_0x9398a8('0x13')](function(){const _0x33d76f=_0x9398a8;return _0x595dec[_0x33d76f('0xf')][_0x33d76f('0x0')](_0x3d59e2,{'force':!![]})[_0x33d76f('0xd')](function(){const _0x4dadd5=_0x33d76f;logger[_0x4dadd5('0x2')](_0x4dadd5('0x8'),_0x3d59e2);})[_0x33d76f('0x1')](function(_0xdf82bb){const _0x9a8ff2=_0x33d76f;logger[_0x9a8ff2('0x2')](JSON['stringify'](_0xdf82bb));});});},Migration[_0x50fa53('0x14')]['addIndex']=function(_0x50adec,_0xff42cd,_0x5573e8){const _0x4f597d=_0x50fa53,_0x4329a7=this;this[_0x4f597d('0x5')][_0x4f597d('0x13')](function(){const _0x3345f1=_0x4f597d;return _0x4329a7[_0x3345f1('0xf')][_0x3345f1('0x16')](_0x50adec,_0xff42cd,{'indexName':_0x5573e8})[_0x3345f1('0xd')](function(){const _0x55bcb7=_0x3345f1;logger[_0x55bcb7('0x2')]('addIndex\x20%s\x20%s\x20%s',_0x50adec,_0xff42cd[_0x55bcb7('0x4')](','),_0x5573e8);})[_0x3345f1('0x1')](function(_0x36c975){const _0x2ce95e=_0x3345f1;logger[_0x2ce95e('0x2')](JSON['stringify'](_0x36c975));});});},Migration[_0x50fa53('0x14')][_0x50fa53('0x12')]=function(_0x1b3f3e,_0x4d4e12){const _0x28922b=this;this['sequence']['enqueue'](function(){const _0x536f1c=a957_0x26c8;return _0x28922b['queryInterface'][_0x536f1c('0x12')](_0x1b3f3e,_0x4d4e12)[_0x536f1c('0xd')](function(){const _0x1d429f=_0x536f1c;logger[_0x1d429f('0x2')]('removeIndex\x20%s\x20%s',_0x1b3f3e,_0x4d4e12);})[_0x536f1c('0x1')](function(_0x55a4ea){logger['info'](JSON['stringify'](_0x55a4ea));});});},Migration['prototype'][_0x50fa53('0x11')]=function(_0x4a16f1){const _0x213e62=_0x50fa53,_0x4c7e89=this;this[_0x213e62('0x5')][_0x213e62('0x13')](function(){const _0xfaecdf=_0x213e62;return _0x4c7e89['queryInterface'][_0xfaecdf('0x18')][_0xfaecdf('0x11')](_0x4a16f1)[_0xfaecdf('0xd')](function(){const _0x4713ca=_0xfaecdf;logger[_0x4713ca('0x2')](_0x4713ca('0x7'),_0x4a16f1);})[_0xfaecdf('0x1')](function(_0x224a0f){const _0x1cf1b2=_0xfaecdf;logger['info'](JSON[_0x1cf1b2('0xb')](_0x224a0f));});});},Migration['prototype']['removeColumn']=function(_0x1405a6,_0x4f5c9d){const _0x400da2=_0x50fa53,_0x1a41d2=this;this[_0x400da2('0x5')][_0x400da2('0x13')](function(){const _0x3f6c3b=_0x400da2;return _0x1a41d2[_0x3f6c3b('0xf')]['removeColumn'](_0x1405a6,_0x4f5c9d)[_0x3f6c3b('0xd')](function(){const _0x3ee453=_0x3f6c3b;logger[_0x3ee453('0x2')](_0x3ee453('0x19'),_0x4f5c9d,_0x1405a6);})[_0x3f6c3b('0x1')](function(_0x1a288c){const _0x2c1eb3=_0x3f6c3b;logger[_0x2c1eb3('0x2')](util[_0x2c1eb3('0x17')](_0x1a288c,{'showHidden':![],'depth':null}));});});},Migration[_0x50fa53('0x14')][_0x50fa53('0xa')]=function(_0x5c1298,_0x46859a,_0x1a22eb){const _0x5d7294=_0x50fa53,_0x20b2dd=this;this[_0x5d7294('0x5')][_0x5d7294('0x13')](function(){const _0x1bbe92=_0x5d7294;return _0x20b2dd['queryInterface'][_0x1bbe92('0xa')](_0x5c1298,_0x46859a,_0x1a22eb)['then'](function(){const _0x2c28fd=_0x1bbe92;logger[_0x2c28fd('0x2')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x46859a,_0x1a22eb,_0x5c1298);})[_0x1bbe92('0x1')](function(_0x518335){const _0x3d91f5=_0x1bbe92;logger[_0x3d91f5('0x2')](util['inspect'](_0x518335,{'showHidden':![],'depth':null}));});});},Migration[_0x50fa53('0x14')][_0x50fa53('0x9')]=function(_0x4ed911){const _0x300da2=_0x50fa53;this[_0x300da2('0x5')][_0x300da2('0x13')](function(){return _0x4ed911();});},module[_0x50fa53('0xc')]={'up':function(_0x21eecc){return new Promise(function(_0x4100e2){const _0x495f8a=new Migration(_0x21eecc);_0x495f8a['query']('ALTER\x20TABLE\x20square_messages\x20ENCRYPTION=\x27Y\x27;'),_0x495f8a['final'](_0x4100e2);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.79.js b/server/migrations/2.0.79.js index 386fe35..25a6653 100644 --- a/server/migrations/2.0.79.js +++ b/server/migrations/2.0.79.js @@ -1 +1 @@ -const a958_0x2288=['renameColumn','catch','addIndex\x20%s\x20%s\x20%s','exports','changeColumn','table\x20dropped\x20%s','Removed\x20column\x20%s\x20from\x20%s','final','info','dropTable','removeIndex\x20%s\x20%s','stringify','prototype','../config/logger','tail','enqueue','migration','queryInterface','finally','removeIndex','Added\x20column\x20%s\x20to\x20%s','then','query','join','inspect','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','sequelize','util','UPDATE\x20dashboard_items\x20SET\x20attrs\x20=\x20REPLACE(attrs,\x27[{\x22name\x22:\x22attrReport\x22\x27,\x27[{\x22name\x22:\x22attrReport\x22,\x22type\x22:\x22custom\x22\x27)\x20WHERE\x20type\x20=\x20\x27web-report\x27\x20AND\x20attrs\x20NOT\x20LIKE\x20\x27%type%\x27','sequence'];(function(_0x434aba,_0x22880f){const _0x1cd640=function(_0x277ce9){while(--_0x277ce9){_0x434aba['push'](_0x434aba['shift']());}};_0x1cd640(++_0x22880f);}(a958_0x2288,0x110));const a958_0x1cd6=function(_0x434aba,_0x22880f){_0x434aba=_0x434aba-0x0;let _0x1cd640=a958_0x2288[_0x434aba];return _0x1cd640;};const _0x3951c2=a958_0x1cd6;'use strict';const util=require(_0x3951c2('0x19')),logger=require(_0x3951c2('0xb'))(_0x3951c2('0xe')),Sequence=function(){};Sequence[_0x3951c2('0xa')][_0x3951c2('0xd')]=function(_0x277ce9){const _0x6bb5a8=_0x3951c2;this['tail']=this[_0x6bb5a8('0xc')]?this[_0x6bb5a8('0xc')][_0x6bb5a8('0x10')](_0x277ce9):_0x277ce9();};const Migration=function(_0x4d2405){const _0x20bfcd=_0x3951c2;this[_0x20bfcd('0xf')]=_0x4d2405,this['sequence']=new Sequence();};Migration[_0x3951c2('0xa')][_0x3951c2('0x2')]=function(_0x2088f1,_0x5658e3,_0x516d67){const _0x3bea8e=_0x3951c2,_0x30f3db=this;this['sequence'][_0x3bea8e('0xd')](function(){const _0x419230=_0x3bea8e;return _0x30f3db['queryInterface'][_0x419230('0x2')](_0x2088f1,_0x5658e3,_0x516d67)[_0x419230('0x13')](function(){const _0x1e3158=_0x419230;logger[_0x1e3158('0x6')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x5658e3,_0x2088f1);})[_0x419230('0x1d')](function(_0x210bca){const _0x6dbe17=_0x419230;logger[_0x6dbe17('0x6')](JSON[_0x6dbe17('0x9')](_0x210bca));});});},Migration[_0x3951c2('0xa')]['addColumn']=function(_0x2c9d7b,_0x30f7c2,_0x1922c7){const _0x1cf569=_0x3951c2,_0x167895=this;this[_0x1cf569('0x1b')][_0x1cf569('0xd')](function(){const _0x2c5666=_0x1cf569;return _0x167895[_0x2c5666('0xf')]['addColumn'](_0x2c9d7b,_0x30f7c2,_0x1922c7)[_0x2c5666('0x13')](function(){const _0x2f7e66=_0x2c5666;logger[_0x2f7e66('0x6')](_0x2f7e66('0x12'),_0x30f7c2,_0x2c9d7b);})[_0x2c5666('0x1d')](function(_0x5aa4ef){const _0x1a4d38=_0x2c5666;logger['info'](JSON[_0x1a4d38('0x9')](_0x5aa4ef));});});},Migration[_0x3951c2('0xa')][_0x3951c2('0x7')]=function(_0x5107cd){const _0x33b766=_0x3951c2,_0x2f6478=this;this[_0x33b766('0x1b')][_0x33b766('0xd')](function(){const _0x45df30=_0x33b766;return _0x2f6478[_0x45df30('0xf')][_0x45df30('0x7')](_0x5107cd,{'force':!![]})[_0x45df30('0x13')](function(){const _0x153fd0=_0x45df30;logger['info'](_0x153fd0('0x3'),_0x5107cd);})[_0x45df30('0x1d')](function(_0x22138a){const _0x59ca7f=_0x45df30;logger[_0x59ca7f('0x6')](JSON['stringify'](_0x22138a));});});},Migration[_0x3951c2('0xa')]['addIndex']=function(_0x45831f,_0xf60523,_0x1dad5d){const _0xf9a2e=_0x3951c2,_0x9ac257=this;this[_0xf9a2e('0x1b')]['enqueue'](function(){const _0x1c4f6c=_0xf9a2e;return _0x9ac257['queryInterface']['addIndex'](_0x45831f,_0xf60523,{'indexName':_0x1dad5d})[_0x1c4f6c('0x13')](function(){const _0x14de97=_0x1c4f6c;logger['info'](_0x14de97('0x0'),_0x45831f,_0xf60523[_0x14de97('0x15')](','),_0x1dad5d);})[_0x1c4f6c('0x1d')](function(_0x6e6b83){const _0x396601=_0x1c4f6c;logger[_0x396601('0x6')](JSON[_0x396601('0x9')](_0x6e6b83));});});},Migration[_0x3951c2('0xa')][_0x3951c2('0x11')]=function(_0x30b154,_0x3e01a4){const _0x371e4d=_0x3951c2,_0x3e763f=this;this[_0x371e4d('0x1b')][_0x371e4d('0xd')](function(){const _0x14963b=_0x371e4d;return _0x3e763f[_0x14963b('0xf')][_0x14963b('0x11')](_0x30b154,_0x3e01a4)[_0x14963b('0x13')](function(){const _0x56dfd6=_0x14963b;logger[_0x56dfd6('0x6')](_0x56dfd6('0x8'),_0x30b154,_0x3e01a4);})[_0x14963b('0x1d')](function(_0x14dae9){logger['info'](JSON['stringify'](_0x14dae9));});});},Migration[_0x3951c2('0xa')][_0x3951c2('0x14')]=function(_0x3911de){const _0x2b62b8=_0x3951c2,_0x147155=this;this[_0x2b62b8('0x1b')]['enqueue'](function(){const _0xb4ae07=_0x2b62b8;return _0x147155[_0xb4ae07('0xf')][_0xb4ae07('0x18')][_0xb4ae07('0x14')](_0x3911de)[_0xb4ae07('0x13')](function(){logger['info']('query\x20%s',_0x3911de);})[_0xb4ae07('0x1d')](function(_0x1cf470){const _0x24906e=_0xb4ae07;logger[_0x24906e('0x6')](JSON[_0x24906e('0x9')](_0x1cf470));});});},Migration[_0x3951c2('0xa')]['removeColumn']=function(_0x16744f,_0x49fb43){const _0x47949d=_0x3951c2,_0x3c12a6=this;this['sequence'][_0x47949d('0xd')](function(){const _0x46a6f3=_0x47949d;return _0x3c12a6[_0x46a6f3('0xf')]['removeColumn'](_0x16744f,_0x49fb43)[_0x46a6f3('0x13')](function(){const _0x319bb3=_0x46a6f3;logger[_0x319bb3('0x6')](_0x319bb3('0x4'),_0x49fb43,_0x16744f);})['catch'](function(_0x2d709f){const _0x7559f1=_0x46a6f3;logger[_0x7559f1('0x6')](util[_0x7559f1('0x16')](_0x2d709f,{'showHidden':![],'depth':null}));});});},Migration[_0x3951c2('0xa')][_0x3951c2('0x1c')]=function(_0x1c6f83,_0x237d12,_0x273132){const _0x5ced1c=_0x3951c2,_0x30ec80=this;this[_0x5ced1c('0x1b')][_0x5ced1c('0xd')](function(){const _0x2c67c5=_0x5ced1c;return _0x30ec80[_0x2c67c5('0xf')][_0x2c67c5('0x1c')](_0x1c6f83,_0x237d12,_0x273132)[_0x2c67c5('0x13')](function(){const _0x3774b4=_0x2c67c5;logger[_0x3774b4('0x6')](_0x3774b4('0x17'),_0x237d12,_0x273132,_0x1c6f83);})[_0x2c67c5('0x1d')](function(_0x4ff2eb){const _0x4c940a=_0x2c67c5;logger[_0x4c940a('0x6')](util[_0x4c940a('0x16')](_0x4ff2eb,{'showHidden':![],'depth':null}));});});},Migration[_0x3951c2('0xa')][_0x3951c2('0x5')]=function(_0x4f1afa){const _0x15605f=_0x3951c2;this[_0x15605f('0x1b')][_0x15605f('0xd')](function(){return _0x4f1afa();});},module[_0x3951c2('0x1')]={'up':function(_0x41bc16){return new Promise(function(_0x4026cc){const _0x57d233=a958_0x1cd6,_0x1c9443=new Migration(_0x41bc16);_0x1c9443['query'](_0x57d233('0x1a')),_0x1c9443[_0x57d233('0x5')](_0x4026cc);});},'down':function(){}}; \ No newline at end of file +const a958_0x5812=['finally','renameColumn','exports','join','then','migration','Removed\x20column\x20%s\x20from\x20%s','../config/logger','inspect','removeColumn','stringify','final','changeColumn','removeIndex\x20%s\x20%s','UPDATE\x20dashboard_items\x20SET\x20attrs\x20=\x20REPLACE(attrs,\x27[{\x22name\x22:\x22attrReport\x22\x27,\x27[{\x22name\x22:\x22attrReport\x22,\x22type\x22:\x22custom\x22\x27)\x20WHERE\x20type\x20=\x20\x27web-report\x27\x20AND\x20attrs\x20NOT\x20LIKE\x20\x27%type%\x27','queryInterface','enqueue','query\x20%s','addIndex\x20%s\x20%s\x20%s','query','prototype','catch','tail','addIndex','addColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','sequence','info','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s'];(function(_0xce82d,_0x581264){const _0x4e477c=function(_0xfe479e){while(--_0xfe479e){_0xce82d['push'](_0xce82d['shift']());}};_0x4e477c(++_0x581264);}(a958_0x5812,0x157));const a958_0x4e47=function(_0xce82d,_0x581264){_0xce82d=_0xce82d-0x0;let _0x4e477c=a958_0x5812[_0xce82d];return _0x4e477c;};const _0x3a0d3c=a958_0x4e47;'use strict';const util=require('util'),logger=require(_0x3a0d3c('0xc'))(_0x3a0d3c('0xa')),Sequence=function(){};Sequence[_0x3a0d3c('0x19')][_0x3a0d3c('0x15')]=function(_0xfe479e){const _0x3e49e1=_0x3a0d3c;this['tail']=this[_0x3e49e1('0x1b')]?this['tail'][_0x3e49e1('0x5')](_0xfe479e):_0xfe479e();};const Migration=function(_0x4a7ece){const _0x43185e=_0x3a0d3c;this[_0x43185e('0x14')]=_0x4a7ece,this[_0x43185e('0x2')]=new Sequence();};Migration[_0x3a0d3c('0x19')]['changeColumn']=function(_0x5823e4,_0x1951e5,_0x34f528){const _0x439c8a=_0x3a0d3c,_0x4622c3=this;this[_0x439c8a('0x2')][_0x439c8a('0x15')](function(){const _0x447132=_0x439c8a;return _0x4622c3[_0x447132('0x14')][_0x447132('0x11')](_0x5823e4,_0x1951e5,_0x34f528)[_0x447132('0x9')](function(){const _0x398ffd=_0x447132;logger['info'](_0x398ffd('0x1'),_0x1951e5,_0x5823e4);})[_0x447132('0x1a')](function(_0x1cd4c2){const _0x48bef6=_0x447132;logger[_0x48bef6('0x3')](JSON[_0x48bef6('0xf')](_0x1cd4c2));});});},Migration[_0x3a0d3c('0x19')]['addColumn']=function(_0x3d83a1,_0x34d0c9,_0x405831){const _0x1ebc74=_0x3a0d3c,_0x45dc68=this;this[_0x1ebc74('0x2')]['enqueue'](function(){const _0x3f240c=_0x1ebc74;return _0x45dc68['queryInterface'][_0x3f240c('0x0')](_0x3d83a1,_0x34d0c9,_0x405831)[_0x3f240c('0x9')](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x34d0c9,_0x3d83a1);})['catch'](function(_0x4698ac){const _0x9e581=_0x3f240c;logger['info'](JSON[_0x9e581('0xf')](_0x4698ac));});});},Migration[_0x3a0d3c('0x19')]['dropTable']=function(_0x4edd69){const _0x175f94=_0x3a0d3c,_0x53883d=this;this[_0x175f94('0x2')][_0x175f94('0x15')](function(){const _0x12e776=_0x175f94;return _0x53883d['queryInterface']['dropTable'](_0x4edd69,{'force':!![]})[_0x12e776('0x9')](function(){const _0x1c1ef5=_0x12e776;logger[_0x1c1ef5('0x3')]('table\x20dropped\x20%s',_0x4edd69);})[_0x12e776('0x1a')](function(_0x58a064){const _0x39f140=_0x12e776;logger[_0x39f140('0x3')](JSON[_0x39f140('0xf')](_0x58a064));});});},Migration['prototype']['addIndex']=function(_0x550835,_0x2ae98e,_0x20c98e){const _0x582ce3=_0x3a0d3c,_0x59e58b=this;this[_0x582ce3('0x2')][_0x582ce3('0x15')](function(){const _0x5644e8=_0x582ce3;return _0x59e58b['queryInterface'][_0x5644e8('0x1c')](_0x550835,_0x2ae98e,{'indexName':_0x20c98e})[_0x5644e8('0x9')](function(){const _0xc04484=_0x5644e8;logger[_0xc04484('0x3')](_0xc04484('0x17'),_0x550835,_0x2ae98e[_0xc04484('0x8')](','),_0x20c98e);})[_0x5644e8('0x1a')](function(_0x28c641){const _0x5561f5=_0x5644e8;logger[_0x5561f5('0x3')](JSON[_0x5561f5('0xf')](_0x28c641));});});},Migration[_0x3a0d3c('0x19')]['removeIndex']=function(_0x44a346,_0x208595){const _0x7a8b9d=_0x3a0d3c,_0x5999a2=this;this[_0x7a8b9d('0x2')][_0x7a8b9d('0x15')](function(){const _0x2cd804=_0x7a8b9d;return _0x5999a2[_0x2cd804('0x14')]['removeIndex'](_0x44a346,_0x208595)[_0x2cd804('0x9')](function(){const _0x450168=_0x2cd804;logger['info'](_0x450168('0x12'),_0x44a346,_0x208595);})['catch'](function(_0x5c4bb9){const _0xbfd54d=_0x2cd804;logger[_0xbfd54d('0x3')](JSON[_0xbfd54d('0xf')](_0x5c4bb9));});});},Migration['prototype'][_0x3a0d3c('0x18')]=function(_0x89b1a){const _0x582f3b=this;this['sequence']['enqueue'](function(){const _0x14986f=a958_0x4e47;return _0x582f3b[_0x14986f('0x14')]['sequelize'][_0x14986f('0x18')](_0x89b1a)['then'](function(){const _0x58d7f2=_0x14986f;logger['info'](_0x58d7f2('0x16'),_0x89b1a);})['catch'](function(_0x2c2bfc){const _0x1f8c90=_0x14986f;logger[_0x1f8c90('0x3')](JSON[_0x1f8c90('0xf')](_0x2c2bfc));});});},Migration[_0x3a0d3c('0x19')][_0x3a0d3c('0xe')]=function(_0x510203,_0x1fe2fc){const _0x5240c8=_0x3a0d3c,_0x5447ef=this;this[_0x5240c8('0x2')]['enqueue'](function(){const _0x4eb660=_0x5240c8;return _0x5447ef[_0x4eb660('0x14')]['removeColumn'](_0x510203,_0x1fe2fc)[_0x4eb660('0x9')](function(){const _0x2e22a6=_0x4eb660;logger[_0x2e22a6('0x3')](_0x2e22a6('0xb'),_0x1fe2fc,_0x510203);})[_0x4eb660('0x1a')](function(_0x1d4731){const _0x5c794a=_0x4eb660;logger[_0x5c794a('0x3')](util[_0x5c794a('0xd')](_0x1d4731,{'showHidden':![],'depth':null}));});});},Migration[_0x3a0d3c('0x19')][_0x3a0d3c('0x6')]=function(_0x52247a,_0x32171b,_0x1576ff){const _0x3ed81e=_0x3a0d3c,_0x3bfa3c=this;this['sequence'][_0x3ed81e('0x15')](function(){const _0x39031e=_0x3ed81e;return _0x3bfa3c[_0x39031e('0x14')][_0x39031e('0x6')](_0x52247a,_0x32171b,_0x1576ff)[_0x39031e('0x9')](function(){const _0x315473=_0x39031e;logger[_0x315473('0x3')](_0x315473('0x4'),_0x32171b,_0x1576ff,_0x52247a);})[_0x39031e('0x1a')](function(_0x15e585){const _0x3543d1=_0x39031e;logger['info'](util[_0x3543d1('0xd')](_0x15e585,{'showHidden':![],'depth':null}));});});},Migration[_0x3a0d3c('0x19')][_0x3a0d3c('0x10')]=function(_0x4322e4){const _0x3065dc=_0x3a0d3c;this[_0x3065dc('0x2')]['enqueue'](function(){return _0x4322e4();});},module[_0x3a0d3c('0x7')]={'up':function(_0x575a71){return new Promise(function(_0x4a56aa){const _0x5221cc=a958_0x4e47,_0x2cf45a=new Migration(_0x575a71);_0x2cf45a['query'](_0x5221cc('0x13')),_0x2cf45a[_0x5221cc('0x10')](_0x4a56aa);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.80.js b/server/migrations/2.0.80.js index a4dabec..102e0ea 100644 --- a/server/migrations/2.0.80.js +++ b/server/migrations/2.0.80.js @@ -1 +1 @@ -const a959_0x2d1f=['changeColumn','settings','dropTable','finally','BOOLEAN','table\x20dropped\x20%s','enqueue','catch','stringify','tail','migration','join','exports','addColumn','Added\x20column\x20%s\x20to\x20%s','prototype','sequelize','removeColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','Removed\x20column\x20%s\x20from\x20%s','final','info','../config/logger','then','removeIndex','util','inspect','preferred','removeIndex\x20%s\x20%s','query','addIndex','addIndex\x20%s\x20%s\x20%s','STRING','queryInterface','sequence','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s'];(function(_0x37d0c6,_0x2d1f84){const _0x92e1a4=function(_0x3c2806){while(--_0x3c2806){_0x37d0c6['push'](_0x37d0c6['shift']());}};_0x92e1a4(++_0x2d1f84);}(a959_0x2d1f,0x116));const a959_0x92e1=function(_0x37d0c6,_0x2d1f84){_0x37d0c6=_0x37d0c6-0x0;let _0x92e1a4=a959_0x2d1f[_0x37d0c6];return _0x92e1a4;};const _0x435082=a959_0x92e1;'use strict';const util=require(_0x435082('0x23')),logger=require(_0x435082('0x20'))(_0x435082('0x14')),Sequence=function(){};Sequence[_0x435082('0x19')][_0x435082('0x10')]=function(_0x3c2806){const _0x1578be=_0x435082;this[_0x1578be('0x13')]=this[_0x1578be('0x13')]?this[_0x1578be('0x13')][_0x1578be('0xd')](_0x3c2806):_0x3c2806();};const Migration=function(_0x3b1477){const _0x4e1519=_0x435082;this['queryInterface']=_0x3b1477,this[_0x4e1519('0x8')]=new Sequence();};Migration[_0x435082('0x19')][_0x435082('0xa')]=function(_0x53aca7,_0x47f0a9,_0x2c5763){const _0x1509fb=_0x435082,_0x3262b4=this;this[_0x1509fb('0x8')][_0x1509fb('0x10')](function(){const _0xed13ed=_0x1509fb;return _0x3262b4['queryInterface'][_0xed13ed('0xa')](_0x53aca7,_0x47f0a9,_0x2c5763)[_0xed13ed('0x21')](function(){const _0x3efbe8=_0xed13ed;logger[_0x3efbe8('0x1f')](_0x3efbe8('0x1c'),_0x47f0a9,_0x53aca7);})['catch'](function(_0x10ca24){const _0x8ffdd3=_0xed13ed;logger[_0x8ffdd3('0x1f')](JSON[_0x8ffdd3('0x12')](_0x10ca24));});});},Migration['prototype'][_0x435082('0x17')]=function(_0x4f559d,_0x25edef,_0x5a8740){const _0x161c39=_0x435082,_0x3f2fcd=this;this[_0x161c39('0x8')]['enqueue'](function(){const _0x4b9581=_0x161c39;return _0x3f2fcd[_0x4b9581('0x7')][_0x4b9581('0x17')](_0x4f559d,_0x25edef,_0x5a8740)[_0x4b9581('0x21')](function(){const _0x101286=_0x4b9581;logger['info'](_0x101286('0x18'),_0x25edef,_0x4f559d);})[_0x4b9581('0x11')](function(_0x576a10){logger['info'](JSON['stringify'](_0x576a10));});});},Migration[_0x435082('0x19')]['dropTable']=function(_0x54c9dc){const _0x4636e7=_0x435082,_0x9d579d=this;this[_0x4636e7('0x8')][_0x4636e7('0x10')](function(){const _0x1d543c=_0x4636e7;return _0x9d579d['queryInterface'][_0x1d543c('0xc')](_0x54c9dc,{'force':!![]})[_0x1d543c('0x21')](function(){const _0x1dbb28=_0x1d543c;logger['info'](_0x1dbb28('0xf'),_0x54c9dc);})[_0x1d543c('0x11')](function(_0x1eb834){const _0x51c819=_0x1d543c;logger[_0x51c819('0x1f')](JSON[_0x51c819('0x12')](_0x1eb834));});});},Migration[_0x435082('0x19')][_0x435082('0x4')]=function(_0x4b8114,_0x2645fb,_0x4bde19){const _0x43fba6=_0x435082,_0x4008f9=this;this[_0x43fba6('0x8')]['enqueue'](function(){const _0xed3c2d=_0x43fba6;return _0x4008f9[_0xed3c2d('0x7')][_0xed3c2d('0x4')](_0x4b8114,_0x2645fb,{'indexName':_0x4bde19})['then'](function(){const _0x148a6d=_0xed3c2d;logger[_0x148a6d('0x1f')](_0x148a6d('0x5'),_0x4b8114,_0x2645fb[_0x148a6d('0x15')](','),_0x4bde19);})[_0xed3c2d('0x11')](function(_0x3db7d3){const _0x439660=_0xed3c2d;logger[_0x439660('0x1f')](JSON[_0x439660('0x12')](_0x3db7d3));});});},Migration[_0x435082('0x19')][_0x435082('0x22')]=function(_0x3cf738,_0x5318ee){const _0x163fd0=_0x435082,_0x106127=this;this[_0x163fd0('0x8')][_0x163fd0('0x10')](function(){const _0x1f9939=_0x163fd0;return _0x106127['queryInterface'][_0x1f9939('0x22')](_0x3cf738,_0x5318ee)[_0x1f9939('0x21')](function(){const _0x48c93a=_0x1f9939;logger[_0x48c93a('0x1f')](_0x48c93a('0x2'),_0x3cf738,_0x5318ee);})[_0x1f9939('0x11')](function(_0x51fe6d){const _0x2adacb=_0x1f9939;logger[_0x2adacb('0x1f')](JSON[_0x2adacb('0x12')](_0x51fe6d));});});},Migration['prototype'][_0x435082('0x3')]=function(_0x1edd34){const _0x1d45f9=_0x435082,_0x327ce7=this;this[_0x1d45f9('0x8')][_0x1d45f9('0x10')](function(){const _0x2f9a6e=_0x1d45f9;return _0x327ce7['queryInterface'][_0x2f9a6e('0x1a')][_0x2f9a6e('0x3')](_0x1edd34)[_0x2f9a6e('0x21')](function(){const _0x3f882f=_0x2f9a6e;logger[_0x3f882f('0x1f')]('query\x20%s',_0x1edd34);})[_0x2f9a6e('0x11')](function(_0x16821d){const _0x4f0c20=_0x2f9a6e;logger[_0x4f0c20('0x1f')](JSON['stringify'](_0x16821d));});});},Migration[_0x435082('0x19')][_0x435082('0x1b')]=function(_0x4232e5,_0x571a85){const _0x5d3343=_0x435082,_0x35397b=this;this[_0x5d3343('0x8')]['enqueue'](function(){const _0x17eb11=_0x5d3343;return _0x35397b[_0x17eb11('0x7')]['removeColumn'](_0x4232e5,_0x571a85)[_0x17eb11('0x21')](function(){const _0x49e3eb=_0x17eb11;logger[_0x49e3eb('0x1f')](_0x49e3eb('0x1d'),_0x571a85,_0x4232e5);})[_0x17eb11('0x11')](function(_0x596939){const _0x570592=_0x17eb11;logger[_0x570592('0x1f')](util[_0x570592('0x0')](_0x596939,{'showHidden':![],'depth':null}));});});},Migration['prototype']['renameColumn']=function(_0x54ac11,_0x44e753,_0x2df6fa){const _0x348982=_0x435082,_0x2df2ec=this;this[_0x348982('0x8')][_0x348982('0x10')](function(){const _0x51b555=_0x348982;return _0x2df2ec['queryInterface']['renameColumn'](_0x54ac11,_0x44e753,_0x2df6fa)[_0x51b555('0x21')](function(){const _0x227353=_0x51b555;logger['info'](_0x227353('0x9'),_0x44e753,_0x2df6fa,_0x54ac11);})[_0x51b555('0x11')](function(_0x53edc6){const _0x389a1c=_0x51b555;logger[_0x389a1c('0x1f')](util[_0x389a1c('0x0')](_0x53edc6,{'showHidden':![],'depth':null}));});});},Migration[_0x435082('0x19')][_0x435082('0x1e')]=function(_0x3552c8){const _0xef4b2e=_0x435082;this['sequence'][_0xef4b2e('0x10')](function(){return _0x3552c8();});},module[_0x435082('0x16')]={'up':function(_0x329635,_0x2aa5ec){return new Promise(function(_0x137fa4){const _0x102d0c=a959_0x92e1,_0x58c82c=new Migration(_0x329635);_0x58c82c[_0x102d0c('0x17')]('settings',_0x102d0c('0x1'),{'type':_0x2aa5ec[_0x102d0c('0x6')]}),_0x58c82c[_0x102d0c('0x17')](_0x102d0c('0xb'),'defaultPreferred',{'type':_0x2aa5ec[_0x102d0c('0xe')],'defaultValue':!![]}),_0x58c82c[_0x102d0c('0x1e')](_0x137fa4);});},'down':function(){}}; \ No newline at end of file +const a959_0x314f=['info','then','addColumn','finally','changeColumn','removeIndex\x20%s\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','prototype','query','removeColumn','dropTable','queryInterface','renameColumn','catch','addIndex\x20%s\x20%s\x20%s','util','final','defaultPreferred','STRING','stringify','Removed\x20column\x20%s\x20from\x20%s','sequence','sequelize','settings','removeIndex','enqueue','tail','inspect','addIndex','Added\x20column\x20%s\x20to\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','migration'];(function(_0x3a244d,_0x314f2e){const _0x19d1e3=function(_0xf5b3d0){while(--_0xf5b3d0){_0x3a244d['push'](_0x3a244d['shift']());}};_0x19d1e3(++_0x314f2e);}(a959_0x314f,0x118));const a959_0x19d1=function(_0x3a244d,_0x314f2e){_0x3a244d=_0x3a244d-0x0;let _0x19d1e3=a959_0x314f[_0x3a244d];return _0x19d1e3;};const _0x5bd2c5=a959_0x19d1;'use strict';const util=require(_0x5bd2c5('0x17')),logger=require('../config/logger')(_0x5bd2c5('0x7')),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0xf5b3d0){const _0x1f8b82=_0x5bd2c5;this['tail']=this['tail']?this[_0x1f8b82('0x2')][_0x1f8b82('0xb')](_0xf5b3d0):_0xf5b3d0();};const Migration=function(_0x35044d){const _0x3d8d9e=_0x5bd2c5;this[_0x3d8d9e('0x13')]=_0x35044d,this[_0x3d8d9e('0x1d')]=new Sequence();};Migration[_0x5bd2c5('0xf')][_0x5bd2c5('0xc')]=function(_0x2cfa19,_0x520725,_0x59ab97){const _0x5f40ed=_0x5bd2c5,_0x49970f=this;this['sequence'][_0x5f40ed('0x1')](function(){const _0x41ba9d=_0x5f40ed;return _0x49970f[_0x41ba9d('0x13')]['changeColumn'](_0x2cfa19,_0x520725,_0x59ab97)[_0x41ba9d('0x9')](function(){const _0x146783=_0x41ba9d;logger[_0x146783('0x8')](_0x146783('0x6'),_0x520725,_0x2cfa19);})[_0x41ba9d('0x15')](function(_0x32382e){const _0xbe8a8e=_0x41ba9d;logger[_0xbe8a8e('0x8')](JSON[_0xbe8a8e('0x1b')](_0x32382e));});});},Migration[_0x5bd2c5('0xf')][_0x5bd2c5('0xa')]=function(_0x1d4ae6,_0x4f87a6,_0x271542){const _0x2b1f46=_0x5bd2c5,_0x53e638=this;this[_0x2b1f46('0x1d')]['enqueue'](function(){const _0xb958c1=_0x2b1f46;return _0x53e638['queryInterface'][_0xb958c1('0xa')](_0x1d4ae6,_0x4f87a6,_0x271542)[_0xb958c1('0x9')](function(){const _0x2cdffd=_0xb958c1;logger[_0x2cdffd('0x8')](_0x2cdffd('0x5'),_0x4f87a6,_0x1d4ae6);})[_0xb958c1('0x15')](function(_0x411847){const _0x3d9472=_0xb958c1;logger[_0x3d9472('0x8')](JSON[_0x3d9472('0x1b')](_0x411847));});});},Migration[_0x5bd2c5('0xf')][_0x5bd2c5('0x12')]=function(_0xe33aad){const _0x10bd63=_0x5bd2c5,_0x4214f2=this;this['sequence'][_0x10bd63('0x1')](function(){const _0x5dd720=_0x10bd63;return _0x4214f2['queryInterface']['dropTable'](_0xe33aad,{'force':!![]})[_0x5dd720('0x9')](function(){const _0x45272a=_0x5dd720;logger[_0x45272a('0x8')]('table\x20dropped\x20%s',_0xe33aad);})[_0x5dd720('0x15')](function(_0x52b492){logger['info'](JSON['stringify'](_0x52b492));});});},Migration[_0x5bd2c5('0xf')][_0x5bd2c5('0x4')]=function(_0x34809a,_0x5a7ccf,_0x205f19){const _0x4187ca=_0x5bd2c5,_0x56b78a=this;this[_0x4187ca('0x1d')][_0x4187ca('0x1')](function(){const _0x5e2b41=_0x4187ca;return _0x56b78a[_0x5e2b41('0x13')][_0x5e2b41('0x4')](_0x34809a,_0x5a7ccf,{'indexName':_0x205f19})[_0x5e2b41('0x9')](function(){const _0x3b10d4=_0x5e2b41;logger[_0x3b10d4('0x8')](_0x3b10d4('0x16'),_0x34809a,_0x5a7ccf['join'](','),_0x205f19);})[_0x5e2b41('0x15')](function(_0x278347){const _0x4b0ea9=_0x5e2b41;logger['info'](JSON[_0x4b0ea9('0x1b')](_0x278347));});});},Migration[_0x5bd2c5('0xf')]['removeIndex']=function(_0xc11b3c,_0x14807d){const _0x4278ea=_0x5bd2c5,_0x3ad7ba=this;this[_0x4278ea('0x1d')][_0x4278ea('0x1')](function(){const _0x2e29c6=_0x4278ea;return _0x3ad7ba[_0x2e29c6('0x13')][_0x2e29c6('0x0')](_0xc11b3c,_0x14807d)['then'](function(){const _0x242151=_0x2e29c6;logger[_0x242151('0x8')](_0x242151('0xd'),_0xc11b3c,_0x14807d);})['catch'](function(_0x340eaa){const _0x1600fe=_0x2e29c6;logger[_0x1600fe('0x8')](JSON['stringify'](_0x340eaa));});});},Migration[_0x5bd2c5('0xf')]['query']=function(_0x2ab1b0){const _0x3052e6=_0x5bd2c5,_0x60d84a=this;this[_0x3052e6('0x1d')][_0x3052e6('0x1')](function(){const _0x28daa5=_0x3052e6;return _0x60d84a[_0x28daa5('0x13')][_0x28daa5('0x1e')][_0x28daa5('0x10')](_0x2ab1b0)['then'](function(){const _0x19c80f=_0x28daa5;logger[_0x19c80f('0x8')]('query\x20%s',_0x2ab1b0);})['catch'](function(_0x33a95a){const _0x554110=_0x28daa5;logger[_0x554110('0x8')](JSON['stringify'](_0x33a95a));});});},Migration[_0x5bd2c5('0xf')]['removeColumn']=function(_0x1d7396,_0x46a0ce){const _0x4ddbc6=_0x5bd2c5,_0x165b88=this;this[_0x4ddbc6('0x1d')][_0x4ddbc6('0x1')](function(){const _0x594cb6=_0x4ddbc6;return _0x165b88[_0x594cb6('0x13')][_0x594cb6('0x11')](_0x1d7396,_0x46a0ce)[_0x594cb6('0x9')](function(){const _0x56c5df=_0x594cb6;logger['info'](_0x56c5df('0x1c'),_0x46a0ce,_0x1d7396);})['catch'](function(_0x1e8c0b){const _0x343de7=_0x594cb6;logger['info'](util[_0x343de7('0x3')](_0x1e8c0b,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x5bd2c5('0x14')]=function(_0x2a780a,_0x2c84a6,_0x42c45e){const _0xaf4ac8=this;this['sequence']['enqueue'](function(){const _0x1e6695=a959_0x19d1;return _0xaf4ac8[_0x1e6695('0x13')][_0x1e6695('0x14')](_0x2a780a,_0x2c84a6,_0x42c45e)[_0x1e6695('0x9')](function(){const _0x394b6c=_0x1e6695;logger[_0x394b6c('0x8')](_0x394b6c('0xe'),_0x2c84a6,_0x42c45e,_0x2a780a);})[_0x1e6695('0x15')](function(_0x4457ae){const _0x4fda35=_0x1e6695;logger[_0x4fda35('0x8')](util[_0x4fda35('0x3')](_0x4457ae,{'showHidden':![],'depth':null}));});});},Migration[_0x5bd2c5('0xf')][_0x5bd2c5('0x18')]=function(_0x1218f9){const _0x242fe6=_0x5bd2c5;this[_0x242fe6('0x1d')][_0x242fe6('0x1')](function(){return _0x1218f9();});},module['exports']={'up':function(_0x3dbd1e,_0x37f85d){return new Promise(function(_0x42f6f9){const _0x16c50f=a959_0x19d1,_0x113209=new Migration(_0x3dbd1e);_0x113209['addColumn'](_0x16c50f('0x1f'),'preferred',{'type':_0x37f85d[_0x16c50f('0x1a')]}),_0x113209[_0x16c50f('0xa')]('settings',_0x16c50f('0x19'),{'type':_0x37f85d['BOOLEAN'],'defaultValue':!![]}),_0x113209['final'](_0x42f6f9);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.81.js b/server/migrations/2.0.81.js index 2a72f79..b5df79c 100644 --- a/server/migrations/2.0.81.js +++ b/server/migrations/2.0.81.js @@ -1 +1 @@ -const a960_0x515d=['tail','../config/logger','final','UPDATE\x20sms_accounts\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SET\x20smsMethod\x20=\x20\x27GP\x27\x20WHERE\x20smsMethod\x20=\x20\x27classic+\x27','Changed\x20column\x20%s\x20in\x20table\x20%s','classic+','enqueue','dropTable','removeIndex\x20%s\x20%s','migration','cm_contacts','addIndex\x20%s\x20%s\x20%s','stringify','inspect','query\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addColumn','telegram','queryInterface','smsMethod','UPDATE\x20sms_accounts\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SET\x20smsMethod\x20=\x20\x27SI\x27\x20WHERE\x20smsMethod\x20=\x20\x27basic\x27','basic','changeColumn','addIndex','join','ENUM','query','UPDATE\x20sms_accounts\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SET\x20smsMethod\x20=\x20\x27TI\x27\x20WHERE\x20smsMethod\x20=\x20\x27classic\x27','catch','sequelize','finally','renameColumn','classic','then','exports','sequence','removeColumn','prototype','table\x20dropped\x20%s','Added\x20column\x20%s\x20to\x20%s','sms_accounts','info'];(function(_0x290d8c,_0x515dd6){const _0x12b05d=function(_0x824e25){while(--_0x824e25){_0x290d8c['push'](_0x290d8c['shift']());}};_0x12b05d(++_0x515dd6);}(a960_0x515d,0x95));const a960_0x12b0=function(_0x290d8c,_0x515dd6){_0x290d8c=_0x290d8c-0x0;let _0x12b05d=a960_0x515d[_0x290d8c];return _0x12b05d;};const _0x5a5468=a960_0x12b0;'use strict';const util=require('util'),logger=require(_0x5a5468('0x14'))(_0x5a5468('0x1c')),Sequence=function(){};Sequence[_0x5a5468('0xe')]['enqueue']=function(_0x824e25){const _0x540a60=_0x5a5468;this['tail']=this['tail']?this[_0x540a60('0x13')][_0x540a60('0x7')](_0x824e25):_0x824e25();};const Migration=function(_0x2abb0a){const _0x9cc557=_0x5a5468;this[_0x9cc557('0x25')]=_0x2abb0a,this['sequence']=new Sequence();};Migration['prototype'][_0x5a5468('0x29')]=function(_0x17c8a1,_0x3775bf,_0x3f5c54){const _0x3c0618=_0x5a5468,_0x353c17=this;this['sequence'][_0x3c0618('0x19')](function(){const _0x15fa5b=_0x3c0618;return _0x353c17[_0x15fa5b('0x25')][_0x15fa5b('0x29')](_0x17c8a1,_0x3775bf,_0x3f5c54)[_0x15fa5b('0xa')](function(){const _0x5e1d28=_0x15fa5b;logger['info'](_0x5e1d28('0x17'),_0x3775bf,_0x17c8a1);})['catch'](function(_0x2a40ed){const _0x2de085=_0x15fa5b;logger[_0x2de085('0x12')](JSON[_0x2de085('0x1f')](_0x2a40ed));});});},Migration['prototype'][_0x5a5468('0x23')]=function(_0x504292,_0x206ac6,_0x42bf96){const _0x3c787e=_0x5a5468,_0x13f5ee=this;this[_0x3c787e('0xc')][_0x3c787e('0x19')](function(){const _0x5ca7f7=_0x3c787e;return _0x13f5ee['queryInterface'][_0x5ca7f7('0x23')](_0x504292,_0x206ac6,_0x42bf96)[_0x5ca7f7('0xa')](function(){const _0x39bd90=_0x5ca7f7;logger[_0x39bd90('0x12')](_0x39bd90('0x10'),_0x206ac6,_0x504292);})[_0x5ca7f7('0x5')](function(_0x4c0344){const _0x3232e9=_0x5ca7f7;logger[_0x3232e9('0x12')](JSON[_0x3232e9('0x1f')](_0x4c0344));});});},Migration[_0x5a5468('0xe')][_0x5a5468('0x1a')]=function(_0x36904e){const _0x5edea4=_0x5a5468,_0x5d9e4f=this;this[_0x5edea4('0xc')]['enqueue'](function(){const _0x4df243=_0x5edea4;return _0x5d9e4f['queryInterface'][_0x4df243('0x1a')](_0x36904e,{'force':!![]})[_0x4df243('0xa')](function(){const _0x475736=_0x4df243;logger[_0x475736('0x12')](_0x475736('0xf'),_0x36904e);})[_0x4df243('0x5')](function(_0x1ee0c4){const _0x28ef1a=_0x4df243;logger[_0x28ef1a('0x12')](JSON[_0x28ef1a('0x1f')](_0x1ee0c4));});});},Migration[_0x5a5468('0xe')][_0x5a5468('0x0')]=function(_0x59cf7c,_0x4d9e59,_0x1c736c){const _0x3e6294=_0x5a5468,_0x22a3b5=this;this[_0x3e6294('0xc')][_0x3e6294('0x19')](function(){const _0x1f531f=_0x3e6294;return _0x22a3b5[_0x1f531f('0x25')][_0x1f531f('0x0')](_0x59cf7c,_0x4d9e59,{'indexName':_0x1c736c})[_0x1f531f('0xa')](function(){const _0x4fb824=_0x1f531f;logger['info'](_0x4fb824('0x1e'),_0x59cf7c,_0x4d9e59[_0x4fb824('0x1')](','),_0x1c736c);})['catch'](function(_0x59b9db){const _0x156774=_0x1f531f;logger[_0x156774('0x12')](JSON[_0x156774('0x1f')](_0x59b9db));});});},Migration[_0x5a5468('0xe')]['removeIndex']=function(_0x5b8419,_0x3ae535){const _0x58e35e=_0x5a5468,_0x1c2ee0=this;this[_0x58e35e('0xc')]['enqueue'](function(){const _0x37b848=_0x58e35e;return _0x1c2ee0[_0x37b848('0x25')]['removeIndex'](_0x5b8419,_0x3ae535)[_0x37b848('0xa')](function(){const _0xe33503=_0x37b848;logger['info'](_0xe33503('0x1b'),_0x5b8419,_0x3ae535);})[_0x37b848('0x5')](function(_0x736a75){const _0xa08b72=_0x37b848;logger['info'](JSON[_0xa08b72('0x1f')](_0x736a75));});});},Migration['prototype'][_0x5a5468('0x3')]=function(_0x42cf68){const _0xc14303=_0x5a5468,_0x51da33=this;this[_0xc14303('0xc')][_0xc14303('0x19')](function(){const _0x3bede5=_0xc14303;return _0x51da33[_0x3bede5('0x25')][_0x3bede5('0x6')][_0x3bede5('0x3')](_0x42cf68)[_0x3bede5('0xa')](function(){const _0x213fd6=_0x3bede5;logger[_0x213fd6('0x12')](_0x213fd6('0x21'),_0x42cf68);})[_0x3bede5('0x5')](function(_0x1f87c3){const _0x1d57e1=_0x3bede5;logger[_0x1d57e1('0x12')](JSON['stringify'](_0x1f87c3));});});},Migration[_0x5a5468('0xe')][_0x5a5468('0xd')]=function(_0x2b05de,_0x1494c3){const _0x4b769e=_0x5a5468,_0x15dbd3=this;this[_0x4b769e('0xc')][_0x4b769e('0x19')](function(){const _0x245818=_0x4b769e;return _0x15dbd3[_0x245818('0x25')][_0x245818('0xd')](_0x2b05de,_0x1494c3)[_0x245818('0xa')](function(){const _0x2ca976=_0x245818;logger[_0x2ca976('0x12')]('Removed\x20column\x20%s\x20from\x20%s',_0x1494c3,_0x2b05de);})[_0x245818('0x5')](function(_0x4baaea){const _0x3bbef5=_0x245818;logger[_0x3bbef5('0x12')](util[_0x3bbef5('0x20')](_0x4baaea,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x5a5468('0x8')]=function(_0x3bb545,_0x3e50f8,_0x480f83){const _0x10cadb=_0x5a5468,_0x40877e=this;this[_0x10cadb('0xc')][_0x10cadb('0x19')](function(){const _0x301489=_0x10cadb;return _0x40877e[_0x301489('0x25')][_0x301489('0x8')](_0x3bb545,_0x3e50f8,_0x480f83)[_0x301489('0xa')](function(){const _0x30dd62=_0x301489;logger[_0x30dd62('0x12')](_0x30dd62('0x22'),_0x3e50f8,_0x480f83,_0x3bb545);})[_0x301489('0x5')](function(_0x2f9dbd){logger['info'](util['inspect'](_0x2f9dbd,{'showHidden':![],'depth':null}));});});},Migration[_0x5a5468('0xe')][_0x5a5468('0x15')]=function(_0x3d6f50){const _0x4c60e2=_0x5a5468;this['sequence'][_0x4c60e2('0x19')](function(){return _0x3d6f50();});},module[_0x5a5468('0xb')]={'up':function(_0x2675a8,_0x4d49dc){return new Promise(function(_0x2c1eb9){const _0x311798=a960_0x12b0,_0x39a3fa=new Migration(_0x2675a8);_0x39a3fa[_0x311798('0x29')](_0x311798('0x11'),_0x311798('0x26'),{'type':_0x4d49dc[_0x311798('0x2')](_0x311798('0x28'),_0x311798('0x9'),_0x311798('0x18'),'SI','TI','GP')}),_0x39a3fa[_0x311798('0x3')](_0x311798('0x27')),_0x39a3fa[_0x311798('0x3')](_0x311798('0x4')),_0x39a3fa[_0x311798('0x3')](_0x311798('0x16')),_0x39a3fa[_0x311798('0x29')](_0x311798('0x11'),_0x311798('0x26'),{'type':_0x4d49dc[_0x311798('0x2')]('SI','TI','GP')}),_0x39a3fa['addColumn'](_0x311798('0x1d'),_0x311798('0x24'),{'type':_0x4d49dc['STRING']}),_0x39a3fa[_0x311798('0x15')](_0x2c1eb9);});},'down':function(){}}; \ No newline at end of file +const a960_0x159a=['exports','table\x20dropped\x20%s','addIndex\x20%s\x20%s\x20%s','enqueue','final','Changed\x20column\x20%s\x20in\x20table\x20%s','removeColumn','join','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','query','renameColumn','info','catch','STRING','smsMethod','Added\x20column\x20%s\x20to\x20%s','sms_accounts','basic','sequelize','removeIndex','inspect','util','Removed\x20column\x20%s\x20from\x20%s','queryInterface','stringify','classic','changeColumn','addIndex','addColumn','dropTable','tail','../config/logger','UPDATE\x20sms_accounts\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SET\x20smsMethod\x20=\x20\x27SI\x27\x20WHERE\x20smsMethod\x20=\x20\x27basic\x27','then','migration','sequence','prototype','query\x20%s','removeIndex\x20%s\x20%s','finally','ENUM','UPDATE\x20sms_accounts\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SET\x20smsMethod\x20=\x20\x27GP\x27\x20WHERE\x20smsMethod\x20=\x20\x27classic+\x27'];(function(_0x6d508c,_0x159aed){const _0x1a6ebb=function(_0x2e05fb){while(--_0x2e05fb){_0x6d508c['push'](_0x6d508c['shift']());}};_0x1a6ebb(++_0x159aed);}(a960_0x159a,0x137));const a960_0x1a6e=function(_0x6d508c,_0x159aed){_0x6d508c=_0x6d508c-0x0;let _0x1a6ebb=a960_0x159a[_0x6d508c];return _0x1a6ebb;};const _0x5c5017=a960_0x1a6e;'use strict';const util=require(_0x5c5017('0x4')),logger=require(_0x5c5017('0xe'))(_0x5c5017('0x11')),Sequence=function(){};Sequence[_0x5c5017('0x13')]['enqueue']=function(_0x2e05fb){const _0x45fba7=_0x5c5017;this[_0x45fba7('0xd')]=this[_0x45fba7('0xd')]?this[_0x45fba7('0xd')][_0x45fba7('0x16')](_0x2e05fb):_0x2e05fb();};const Migration=function(_0x4c62ea){const _0x389530=_0x5c5017;this[_0x389530('0x6')]=_0x4c62ea,this[_0x389530('0x12')]=new Sequence();};Migration[_0x5c5017('0x13')][_0x5c5017('0x9')]=function(_0x54969a,_0x3155f9,_0x10d4e5){const _0x3d12d4=_0x5c5017,_0x251c4d=this;this['sequence'][_0x3d12d4('0x1c')](function(){const _0x4f2f26=_0x3d12d4;return _0x251c4d['queryInterface'][_0x4f2f26('0x9')](_0x54969a,_0x3155f9,_0x10d4e5)[_0x4f2f26('0x10')](function(){const _0x5a71d7=_0x4f2f26;logger['info'](_0x5a71d7('0x1e'),_0x3155f9,_0x54969a);})[_0x4f2f26('0x25')](function(_0x186a25){const _0x2f30e3=_0x4f2f26;logger[_0x2f30e3('0x24')](JSON[_0x2f30e3('0x7')](_0x186a25));});});},Migration[_0x5c5017('0x13')][_0x5c5017('0xb')]=function(_0x430358,_0x496835,_0x433f0a){const _0x2806cb=_0x5c5017,_0x44be04=this;this[_0x2806cb('0x12')][_0x2806cb('0x1c')](function(){const _0x1ebe3c=_0x2806cb;return _0x44be04['queryInterface'][_0x1ebe3c('0xb')](_0x430358,_0x496835,_0x433f0a)[_0x1ebe3c('0x10')](function(){const _0x355afd=_0x1ebe3c;logger[_0x355afd('0x24')](_0x355afd('0x28'),_0x496835,_0x430358);})[_0x1ebe3c('0x25')](function(_0x230463){const _0x40e631=_0x1ebe3c;logger[_0x40e631('0x24')](JSON['stringify'](_0x230463));});});},Migration[_0x5c5017('0x13')]['dropTable']=function(_0x832e21){const _0x242b10=_0x5c5017,_0x69e3fb=this;this[_0x242b10('0x12')][_0x242b10('0x1c')](function(){const _0x18fde4=_0x242b10;return _0x69e3fb[_0x18fde4('0x6')][_0x18fde4('0xc')](_0x832e21,{'force':!![]})[_0x18fde4('0x10')](function(){const _0x58b32f=_0x18fde4;logger['info'](_0x58b32f('0x1a'),_0x832e21);})[_0x18fde4('0x25')](function(_0x1188e0){const _0x43f7ca=_0x18fde4;logger['info'](JSON[_0x43f7ca('0x7')](_0x1188e0));});});},Migration['prototype'][_0x5c5017('0xa')]=function(_0x30c383,_0x37cb81,_0x14d93a){const _0x50df17=_0x5c5017,_0x1fced4=this;this[_0x50df17('0x12')][_0x50df17('0x1c')](function(){const _0x183583=_0x50df17;return _0x1fced4[_0x183583('0x6')][_0x183583('0xa')](_0x30c383,_0x37cb81,{'indexName':_0x14d93a})[_0x183583('0x10')](function(){const _0x3f0e2a=_0x183583;logger[_0x3f0e2a('0x24')](_0x3f0e2a('0x1b'),_0x30c383,_0x37cb81[_0x3f0e2a('0x20')](','),_0x14d93a);})[_0x183583('0x25')](function(_0x331252){const _0x1a9a2c=_0x183583;logger[_0x1a9a2c('0x24')](JSON['stringify'](_0x331252));});});},Migration[_0x5c5017('0x13')][_0x5c5017('0x2')]=function(_0x23fc29,_0x1b63a8){const _0x49fc20=_0x5c5017,_0x575af2=this;this['sequence'][_0x49fc20('0x1c')](function(){return _0x575af2['queryInterface']['removeIndex'](_0x23fc29,_0x1b63a8)['then'](function(){const _0x43313e=a960_0x1a6e;logger[_0x43313e('0x24')](_0x43313e('0x15'),_0x23fc29,_0x1b63a8);})['catch'](function(_0x33577f){const _0x285c0f=a960_0x1a6e;logger[_0x285c0f('0x24')](JSON[_0x285c0f('0x7')](_0x33577f));});});},Migration['prototype'][_0x5c5017('0x22')]=function(_0x1eee00){const _0x44879e=_0x5c5017,_0x5aa20c=this;this[_0x44879e('0x12')][_0x44879e('0x1c')](function(){const _0x5b9364=_0x44879e;return _0x5aa20c[_0x5b9364('0x6')][_0x5b9364('0x1')]['query'](_0x1eee00)[_0x5b9364('0x10')](function(){const _0x262482=_0x5b9364;logger[_0x262482('0x24')](_0x262482('0x14'),_0x1eee00);})[_0x5b9364('0x25')](function(_0x4e4ffd){const _0x2b6f76=_0x5b9364;logger[_0x2b6f76('0x24')](JSON[_0x2b6f76('0x7')](_0x4e4ffd));});});},Migration[_0x5c5017('0x13')][_0x5c5017('0x1f')]=function(_0xa40dc2,_0x240893){const _0x3bbf62=_0x5c5017,_0x4f921b=this;this[_0x3bbf62('0x12')][_0x3bbf62('0x1c')](function(){const _0x2f9f0d=_0x3bbf62;return _0x4f921b[_0x2f9f0d('0x6')][_0x2f9f0d('0x1f')](_0xa40dc2,_0x240893)[_0x2f9f0d('0x10')](function(){const _0x19ef32=_0x2f9f0d;logger[_0x19ef32('0x24')](_0x19ef32('0x5'),_0x240893,_0xa40dc2);})[_0x2f9f0d('0x25')](function(_0x554294){const _0x4d8ec7=_0x2f9f0d;logger[_0x4d8ec7('0x24')](util[_0x4d8ec7('0x3')](_0x554294,{'showHidden':![],'depth':null}));});});},Migration[_0x5c5017('0x13')][_0x5c5017('0x23')]=function(_0xe6532a,_0x181604,_0x3fd8aa){const _0x16fcaf=_0x5c5017,_0x303764=this;this[_0x16fcaf('0x12')][_0x16fcaf('0x1c')](function(){const _0x1cc2c0=_0x16fcaf;return _0x303764[_0x1cc2c0('0x6')][_0x1cc2c0('0x23')](_0xe6532a,_0x181604,_0x3fd8aa)[_0x1cc2c0('0x10')](function(){const _0x28ca31=_0x1cc2c0;logger[_0x28ca31('0x24')](_0x28ca31('0x21'),_0x181604,_0x3fd8aa,_0xe6532a);})['catch'](function(_0x153342){const _0x138a5d=_0x1cc2c0;logger[_0x138a5d('0x24')](util[_0x138a5d('0x3')](_0x153342,{'showHidden':![],'depth':null}));});});},Migration[_0x5c5017('0x13')]['final']=function(_0x4ae0a3){const _0x233c8b=_0x5c5017;this[_0x233c8b('0x12')][_0x233c8b('0x1c')](function(){return _0x4ae0a3();});},module[_0x5c5017('0x19')]={'up':function(_0x436de4,_0x58c89b){return new Promise(function(_0x37478c){const _0x4bee53=a960_0x1a6e,_0x32e034=new Migration(_0x436de4);_0x32e034[_0x4bee53('0x9')](_0x4bee53('0x29'),_0x4bee53('0x27'),{'type':_0x58c89b[_0x4bee53('0x17')](_0x4bee53('0x0'),_0x4bee53('0x8'),'classic+','SI','TI','GP')}),_0x32e034['query'](_0x4bee53('0xf')),_0x32e034[_0x4bee53('0x22')]('UPDATE\x20sms_accounts\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SET\x20smsMethod\x20=\x20\x27TI\x27\x20WHERE\x20smsMethod\x20=\x20\x27classic\x27'),_0x32e034[_0x4bee53('0x22')](_0x4bee53('0x18')),_0x32e034[_0x4bee53('0x9')]('sms_accounts',_0x4bee53('0x27'),{'type':_0x58c89b[_0x4bee53('0x17')]('SI','TI','GP')}),_0x32e034[_0x4bee53('0xb')]('cm_contacts','telegram',{'type':_0x58c89b[_0x4bee53('0x26')]}),_0x32e034[_0x4bee53('0x1d')](_0x37478c);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.82.js b/server/migrations/2.0.82.js index a8d586c..7864691 100644 --- a/server/migrations/2.0.82.js +++ b/server/migrations/2.0.82.js @@ -1 +1 @@ -const a961_0x2682=['addColumn','sms_accounts','plivo','skebby','catch','queryInterface','finally','query\x20%s','clickatell','../config/logger','then','Removed\x20column\x20%s\x20from\x20%s','removeColumn','util','STRING','migration','renameColumn','exports','enqueue','stringify','removeIndex','csc','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','dropTable','info','query','changeColumn','tail','prototype','sequence','ENUM','addIndex','clicksend','table\x20dropped\x20%s','addIndex\x20%s\x20%s\x20%s','type','join','connectel','inspect','removeIndex\x20%s\x20%s','Added\x20column\x20%s\x20to\x20%s'];(function(_0x31d915,_0x2682e0){const _0x576a72=function(_0xffe680){while(--_0xffe680){_0x31d915['push'](_0x31d915['shift']());}};_0x576a72(++_0x2682e0);}(a961_0x2682,0xed));const a961_0x576a=function(_0x31d915,_0x2682e0){_0x31d915=_0x31d915-0x0;let _0x576a72=a961_0x2682[_0x31d915];return _0x576a72;};const _0x5d7c7b=a961_0x576a;'use strict';const util=require(_0x5d7c7b('0x16')),logger=require(_0x5d7c7b('0x12'))(_0x5d7c7b('0x18')),Sequence=function(){};Sequence[_0x5d7c7b('0x25')][_0x5d7c7b('0x1b')]=function(_0xffe680){const _0x524922=_0x5d7c7b;this[_0x524922('0x24')]=this[_0x524922('0x24')]?this[_0x524922('0x24')][_0x524922('0xf')](_0xffe680):_0xffe680();};const Migration=function(_0x3a01db){const _0x186b22=_0x5d7c7b;this[_0x186b22('0xe')]=_0x3a01db,this[_0x186b22('0x26')]=new Sequence();};Migration[_0x5d7c7b('0x25')]['changeColumn']=function(_0x3744f1,_0x4275bc,_0x51d7d3){const _0x51e940=_0x5d7c7b,_0x1efd0b=this;this[_0x51e940('0x26')]['enqueue'](function(){const _0x175fdd=_0x51e940;return _0x1efd0b['queryInterface'][_0x175fdd('0x23')](_0x3744f1,_0x4275bc,_0x51d7d3)['then'](function(){const _0xf1a891=_0x175fdd;logger[_0xf1a891('0x21')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x4275bc,_0x3744f1);})[_0x175fdd('0xd')](function(_0x40d8ac){const _0x3dcb20=_0x175fdd;logger[_0x3dcb20('0x21')](JSON['stringify'](_0x40d8ac));});});},Migration[_0x5d7c7b('0x25')]['addColumn']=function(_0x2ab724,_0x528be4,_0x1ddb35){const _0x17f683=this;this['sequence']['enqueue'](function(){const _0x114579=a961_0x576a;return _0x17f683[_0x114579('0xe')][_0x114579('0x9')](_0x2ab724,_0x528be4,_0x1ddb35)[_0x114579('0x13')](function(){const _0x34f753=_0x114579;logger['info'](_0x34f753('0x8'),_0x528be4,_0x2ab724);})[_0x114579('0xd')](function(_0x5d28b0){const _0x221ff3=_0x114579;logger[_0x221ff3('0x21')](JSON[_0x221ff3('0x1c')](_0x5d28b0));});});},Migration['prototype'][_0x5d7c7b('0x20')]=function(_0x4a5858){const _0x4b1f5f=_0x5d7c7b,_0x1ae066=this;this[_0x4b1f5f('0x26')][_0x4b1f5f('0x1b')](function(){const _0x37cadd=_0x4b1f5f;return _0x1ae066[_0x37cadd('0xe')][_0x37cadd('0x20')](_0x4a5858,{'force':!![]})[_0x37cadd('0x13')](function(){const _0x24324d=_0x37cadd;logger['info'](_0x24324d('0x1'),_0x4a5858);})[_0x37cadd('0xd')](function(_0x1f2110){const _0x545c02=_0x37cadd;logger[_0x545c02('0x21')](JSON[_0x545c02('0x1c')](_0x1f2110));});});},Migration['prototype'][_0x5d7c7b('0x28')]=function(_0x11ce70,_0x315462,_0x452a5f){const _0x5b8621=_0x5d7c7b,_0x41b5d0=this;this[_0x5b8621('0x26')][_0x5b8621('0x1b')](function(){const _0x1492c7=_0x5b8621;return _0x41b5d0[_0x1492c7('0xe')]['addIndex'](_0x11ce70,_0x315462,{'indexName':_0x452a5f})[_0x1492c7('0x13')](function(){const _0x9477c8=_0x1492c7;logger[_0x9477c8('0x21')](_0x9477c8('0x2'),_0x11ce70,_0x315462[_0x9477c8('0x4')](','),_0x452a5f);})['catch'](function(_0x21c48f){const _0x3bf76b=_0x1492c7;logger[_0x3bf76b('0x21')](JSON[_0x3bf76b('0x1c')](_0x21c48f));});});},Migration['prototype'][_0x5d7c7b('0x1d')]=function(_0x547103,_0xef1562){const _0x48d0e5=this;this['sequence']['enqueue'](function(){const _0x48a72d=a961_0x576a;return _0x48d0e5[_0x48a72d('0xe')][_0x48a72d('0x1d')](_0x547103,_0xef1562)[_0x48a72d('0x13')](function(){const _0x2243fd=_0x48a72d;logger[_0x2243fd('0x21')](_0x2243fd('0x7'),_0x547103,_0xef1562);})[_0x48a72d('0xd')](function(_0x13504b){const _0x4be466=_0x48a72d;logger['info'](JSON[_0x4be466('0x1c')](_0x13504b));});});},Migration[_0x5d7c7b('0x25')][_0x5d7c7b('0x22')]=function(_0x18395b){const _0x3d02a6=_0x5d7c7b,_0x1a7754=this;this[_0x3d02a6('0x26')]['enqueue'](function(){const _0x39b54f=_0x3d02a6;return _0x1a7754['queryInterface']['sequelize'][_0x39b54f('0x22')](_0x18395b)[_0x39b54f('0x13')](function(){const _0x1d2b47=_0x39b54f;logger[_0x1d2b47('0x21')](_0x1d2b47('0x10'),_0x18395b);})[_0x39b54f('0xd')](function(_0x4e1d94){const _0x2b5f35=_0x39b54f;logger[_0x2b5f35('0x21')](JSON['stringify'](_0x4e1d94));});});},Migration[_0x5d7c7b('0x25')][_0x5d7c7b('0x15')]=function(_0x3e03aa,_0xd40067){const _0xa7754f=_0x5d7c7b,_0x33e274=this;this[_0xa7754f('0x26')][_0xa7754f('0x1b')](function(){const _0x40ab09=_0xa7754f;return _0x33e274['queryInterface'][_0x40ab09('0x15')](_0x3e03aa,_0xd40067)[_0x40ab09('0x13')](function(){const _0x713179=_0x40ab09;logger[_0x713179('0x21')](_0x713179('0x14'),_0xd40067,_0x3e03aa);})['catch'](function(_0xecaca6){const _0x3ba967=_0x40ab09;logger[_0x3ba967('0x21')](util[_0x3ba967('0x6')](_0xecaca6,{'showHidden':![],'depth':null}));});});},Migration[_0x5d7c7b('0x25')][_0x5d7c7b('0x19')]=function(_0x3e7f86,_0x49c703,_0x187e17){const _0x4a68b2=_0x5d7c7b,_0x19c24c=this;this[_0x4a68b2('0x26')][_0x4a68b2('0x1b')](function(){const _0x40947a=_0x4a68b2;return _0x19c24c[_0x40947a('0xe')]['renameColumn'](_0x3e7f86,_0x49c703,_0x187e17)[_0x40947a('0x13')](function(){const _0x1ea511=_0x40947a;logger['info'](_0x1ea511('0x1f'),_0x49c703,_0x187e17,_0x3e7f86);})[_0x40947a('0xd')](function(_0x3233c8){logger['info'](util['inspect'](_0x3233c8,{'showHidden':![],'depth':null}));});});},Migration[_0x5d7c7b('0x25')]['final']=function(_0x239c75){const _0x206033=_0x5d7c7b;this[_0x206033('0x26')]['enqueue'](function(){return _0x239c75();});},module[_0x5d7c7b('0x1a')]={'up':function(_0x2a2b7e,_0x16732c){return new Promise(function(_0x3df6b7){const _0x41c4d4=a961_0x576a,_0x41e253=new Migration(_0x2a2b7e);_0x41e253[_0x41c4d4('0x9')]('sms_accounts','apiKey',{'type':_0x16732c[_0x41c4d4('0x17')]}),_0x41e253[_0x41c4d4('0x23')](_0x41c4d4('0xa'),_0x41c4d4('0x3'),{'type':_0x16732c[_0x41c4d4('0x27')]('twilio',_0x41c4d4('0xc'),_0x41c4d4('0x5'),_0x41c4d4('0x0'),_0x41c4d4('0xb'),_0x41c4d4('0x11'),_0x41c4d4('0x1e'))}),_0x41e253['final'](_0x3df6b7);});},'down':function(){}}; \ No newline at end of file +const a961_0x1e8b=['plivo','clickatell','removeIndex\x20%s\x20%s','clicksend','info','Added\x20column\x20%s\x20to\x20%s','catch','util','tail','prototype','enqueue','final','addColumn','migration','renameColumn','query\x20%s','apiKey','inspect','removeIndex','removeColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','stringify','../config/logger','changeColumn','Removed\x20column\x20%s\x20from\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','twilio','sms_accounts','type','query','skebby','queryInterface','table\x20dropped\x20%s','exports','then','sequence','addIndex','ENUM','dropTable'];(function(_0x5504b3,_0x1e8b58){const _0x55bb56=function(_0x40610e){while(--_0x40610e){_0x5504b3['push'](_0x5504b3['shift']());}};_0x55bb56(++_0x1e8b58);}(a961_0x1e8b,0x1d6));const a961_0x55bb=function(_0x5504b3,_0x1e8b58){_0x5504b3=_0x5504b3-0x0;let _0x55bb56=a961_0x1e8b[_0x5504b3];return _0x55bb56;};const _0x12182d=a961_0x55bb;'use strict';const util=require(_0x12182d('0x5')),logger=require(_0x12182d('0x14'))(_0x12182d('0xb')),Sequence=function(){};Sequence[_0x12182d('0x7')][_0x12182d('0x8')]=function(_0x40610e){const _0x21f010=_0x12182d;this[_0x21f010('0x6')]=this['tail']?this[_0x21f010('0x6')]['finally'](_0x40610e):_0x40610e();};const Migration=function(_0x411084){const _0x1380d5=_0x12182d;this[_0x1380d5('0x1d')]=_0x411084,this['sequence']=new Sequence();};Migration[_0x12182d('0x7')][_0x12182d('0x15')]=function(_0x495dd9,_0x471be4,_0x5891a4){const _0x20f775=_0x12182d,_0x4f8134=this;this[_0x20f775('0x21')][_0x20f775('0x8')](function(){const _0x50863c=_0x20f775;return _0x4f8134[_0x50863c('0x1d')][_0x50863c('0x15')](_0x495dd9,_0x471be4,_0x5891a4)[_0x50863c('0x20')](function(){const _0x227d7d=_0x50863c;logger[_0x227d7d('0x2')](_0x227d7d('0x12'),_0x471be4,_0x495dd9);})[_0x50863c('0x4')](function(_0x2833c7){const _0x37ab5d=_0x50863c;logger[_0x37ab5d('0x2')](JSON['stringify'](_0x2833c7));});});},Migration['prototype'][_0x12182d('0xa')]=function(_0xbc6507,_0xd53294,_0x1b7550){const _0x5871d9=_0x12182d,_0x2d79e9=this;this[_0x5871d9('0x21')]['enqueue'](function(){const _0x1c7cf3=_0x5871d9;return _0x2d79e9[_0x1c7cf3('0x1d')]['addColumn'](_0xbc6507,_0xd53294,_0x1b7550)[_0x1c7cf3('0x20')](function(){const _0x7ed6fc=_0x1c7cf3;logger[_0x7ed6fc('0x2')](_0x7ed6fc('0x3'),_0xd53294,_0xbc6507);})[_0x1c7cf3('0x4')](function(_0x2d5cd1){const _0x32806b=_0x1c7cf3;logger[_0x32806b('0x2')](JSON[_0x32806b('0x13')](_0x2d5cd1));});});},Migration[_0x12182d('0x7')]['dropTable']=function(_0x3155a4){const _0x572ee9=_0x12182d,_0x5d7a2d=this;this[_0x572ee9('0x21')][_0x572ee9('0x8')](function(){const _0x170460=_0x572ee9;return _0x5d7a2d[_0x170460('0x1d')][_0x170460('0x24')](_0x3155a4,{'force':!![]})[_0x170460('0x20')](function(){const _0x475164=_0x170460;logger['info'](_0x475164('0x1e'),_0x3155a4);})[_0x170460('0x4')](function(_0x4d4369){const _0x39ec23=_0x170460;logger['info'](JSON[_0x39ec23('0x13')](_0x4d4369));});});},Migration['prototype'][_0x12182d('0x22')]=function(_0x561d75,_0x5b2b5b,_0x1b3e54){const _0x2d9c06=_0x12182d,_0x2705f3=this;this['sequence'][_0x2d9c06('0x8')](function(){const _0x56ee44=_0x2d9c06;return _0x2705f3[_0x56ee44('0x1d')][_0x56ee44('0x22')](_0x561d75,_0x5b2b5b,{'indexName':_0x1b3e54})['then'](function(){const _0x3965a6=_0x56ee44;logger[_0x3965a6('0x2')]('addIndex\x20%s\x20%s\x20%s',_0x561d75,_0x5b2b5b['join'](','),_0x1b3e54);})['catch'](function(_0x1c8260){const _0x52dfc3=_0x56ee44;logger[_0x52dfc3('0x2')](JSON[_0x52dfc3('0x13')](_0x1c8260));});});},Migration[_0x12182d('0x7')][_0x12182d('0x10')]=function(_0x36ea3b,_0x575d40){const _0x1f2a24=_0x12182d,_0xa83075=this;this[_0x1f2a24('0x21')][_0x1f2a24('0x8')](function(){const _0x8c8081=_0x1f2a24;return _0xa83075[_0x8c8081('0x1d')][_0x8c8081('0x10')](_0x36ea3b,_0x575d40)[_0x8c8081('0x20')](function(){const _0xb62e99=_0x8c8081;logger[_0xb62e99('0x2')](_0xb62e99('0x0'),_0x36ea3b,_0x575d40);})[_0x8c8081('0x4')](function(_0x1a95d7){const _0x644108=_0x8c8081;logger[_0x644108('0x2')](JSON[_0x644108('0x13')](_0x1a95d7));});});},Migration[_0x12182d('0x7')][_0x12182d('0x1b')]=function(_0x29c7c8){const _0x18ac66=this;this['sequence']['enqueue'](function(){const _0x5a8f34=a961_0x55bb;return _0x18ac66[_0x5a8f34('0x1d')]['sequelize'][_0x5a8f34('0x1b')](_0x29c7c8)[_0x5a8f34('0x20')](function(){const _0x17b69c=_0x5a8f34;logger['info'](_0x17b69c('0xd'),_0x29c7c8);})[_0x5a8f34('0x4')](function(_0x12eff4){const _0x2161f7=_0x5a8f34;logger[_0x2161f7('0x2')](JSON[_0x2161f7('0x13')](_0x12eff4));});});},Migration[_0x12182d('0x7')][_0x12182d('0x11')]=function(_0x792cc3,_0x49d132){const _0x5a6450=_0x12182d,_0x3dc6cd=this;this[_0x5a6450('0x21')][_0x5a6450('0x8')](function(){const _0x223b5a=_0x5a6450;return _0x3dc6cd[_0x223b5a('0x1d')][_0x223b5a('0x11')](_0x792cc3,_0x49d132)[_0x223b5a('0x20')](function(){const _0x157872=_0x223b5a;logger['info'](_0x157872('0x16'),_0x49d132,_0x792cc3);})[_0x223b5a('0x4')](function(_0x3a0d59){const _0xc66b7e=_0x223b5a;logger[_0xc66b7e('0x2')](util[_0xc66b7e('0xf')](_0x3a0d59,{'showHidden':![],'depth':null}));});});},Migration[_0x12182d('0x7')][_0x12182d('0xc')]=function(_0x354ca4,_0x3f749e,_0xbd500e){const _0x3f2907=_0x12182d,_0x47dd16=this;this[_0x3f2907('0x21')][_0x3f2907('0x8')](function(){const _0x503f1d=_0x3f2907;return _0x47dd16[_0x503f1d('0x1d')]['renameColumn'](_0x354ca4,_0x3f749e,_0xbd500e)[_0x503f1d('0x20')](function(){const _0x4ec8a3=_0x503f1d;logger[_0x4ec8a3('0x2')](_0x4ec8a3('0x17'),_0x3f749e,_0xbd500e,_0x354ca4);})['catch'](function(_0x351398){const _0x301500=_0x503f1d;logger[_0x301500('0x2')](util['inspect'](_0x351398,{'showHidden':![],'depth':null}));});});},Migration[_0x12182d('0x7')][_0x12182d('0x9')]=function(_0x392238){const _0x29cc7f=_0x12182d;this[_0x29cc7f('0x21')]['enqueue'](function(){return _0x392238();});},module[_0x12182d('0x1f')]={'up':function(_0x10157c,_0x504b07){return new Promise(function(_0x11a75e){const _0x4973ba=a961_0x55bb,_0x1fbbbd=new Migration(_0x10157c);_0x1fbbbd[_0x4973ba('0xa')](_0x4973ba('0x19'),_0x4973ba('0xe'),{'type':_0x504b07['STRING']}),_0x1fbbbd[_0x4973ba('0x15')]('sms_accounts',_0x4973ba('0x1a'),{'type':_0x504b07[_0x4973ba('0x23')](_0x4973ba('0x18'),_0x4973ba('0x1c'),'connectel',_0x4973ba('0x1'),_0x4973ba('0x25'),_0x4973ba('0x26'),'csc')}),_0x1fbbbd[_0x4973ba('0x9')](_0x11a75e);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.83.js b/server/migrations/2.0.83.js index ad13a13..ac04a34 100644 --- a/server/migrations/2.0.83.js +++ b/server/migrations/2.0.83.js @@ -1 +1 @@ -const a962_0x450c=['then','cm_hopper','inspect','join','STRING','ALTER\x20TABLE\x20cm_hopper\x20ADD\x20CONSTRAINT\x20cm_hopper_ibfk_6\x20FOREIGN\x20KEY\x20(OwnerId)\x20REFERENCES\x20users(id)\x20ON\x20UPDATE\x20CASCADE\x20ON\x20DELETE\x20SET\x20NULL','changeColumn','removeIndex','util','sequelize','queryInterface','sequence','stringify','prototype','query\x20%s','clicksend','baseUrl','tail','Added\x20column\x20%s\x20to\x20%s','report_queue','migration','OwnerId','INTEGER','../config/logger','dropTable','queuecallerenterreason','addIndex\x20%s\x20%s\x20%s','table\x20dropped\x20%s','sms_accounts','removeColumn','Removed\x20column\x20%s\x20from\x20%s','fb_data','addColumn','exports','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','addIndex','plivo','infobip','catch','renameColumn','twilio','csc','enqueue','skebby','removeIndex\x20%s\x20%s','connectel','query','info','final'];(function(_0x304622,_0x450ced){const _0x2edc84=function(_0x2efc69){while(--_0x2efc69){_0x304622['push'](_0x304622['shift']());}};_0x2edc84(++_0x450ced);}(a962_0x450c,0x15e));const a962_0x2edc=function(_0x304622,_0x450ced){_0x304622=_0x304622-0x0;let _0x2edc84=a962_0x450c[_0x304622];return _0x2edc84;};const _0x4c9f67=a962_0x2edc;'use strict';const util=require(_0x4c9f67('0x8')),logger=require(_0x4c9f67('0x17'))(_0x4c9f67('0x14')),Sequence=function(){};Sequence[_0x4c9f67('0xd')][_0x4c9f67('0x2b')]=function(_0x2efc69){const _0x43e88e=_0x4c9f67;this[_0x43e88e('0x11')]=this[_0x43e88e('0x11')]?this['tail']['finally'](_0x2efc69):_0x2efc69();};const Migration=function(_0x3f2743){const _0x979062=_0x4c9f67;this[_0x979062('0xa')]=_0x3f2743,this[_0x979062('0xb')]=new Sequence();};Migration[_0x4c9f67('0xd')][_0x4c9f67('0x6')]=function(_0x1affad,_0x20efed,_0x3fb15b){const _0x47830f=_0x4c9f67,_0x5101f6=this;this[_0x47830f('0xb')][_0x47830f('0x2b')](function(){const _0x49fc2c=_0x47830f;return _0x5101f6[_0x49fc2c('0xa')][_0x49fc2c('0x6')](_0x1affad,_0x20efed,_0x3fb15b)[_0x49fc2c('0x0')](function(){const _0x59194d=_0x49fc2c;logger[_0x59194d('0x30')](_0x59194d('0x23'),_0x20efed,_0x1affad);})[_0x49fc2c('0x27')](function(_0x13e621){const _0x2fd9db=_0x49fc2c;logger[_0x2fd9db('0x30')](JSON[_0x2fd9db('0xc')](_0x13e621));});});},Migration['prototype']['addColumn']=function(_0x5e8857,_0x272e14,_0x121b20){const _0x1e2bd7=_0x4c9f67,_0x6632dc=this;this[_0x1e2bd7('0xb')][_0x1e2bd7('0x2b')](function(){const _0xd1dad9=_0x1e2bd7;return _0x6632dc[_0xd1dad9('0xa')]['addColumn'](_0x5e8857,_0x272e14,_0x121b20)[_0xd1dad9('0x0')](function(){const _0x2378e7=_0xd1dad9;logger[_0x2378e7('0x30')](_0x2378e7('0x12'),_0x272e14,_0x5e8857);})[_0xd1dad9('0x27')](function(_0x521ca9){const _0x16bc7f=_0xd1dad9;logger[_0x16bc7f('0x30')](JSON[_0x16bc7f('0xc')](_0x521ca9));});});},Migration[_0x4c9f67('0xd')][_0x4c9f67('0x18')]=function(_0x272ad6){const _0x3661bd=_0x4c9f67,_0x8119ba=this;this['sequence'][_0x3661bd('0x2b')](function(){const _0x1a4169=_0x3661bd;return _0x8119ba[_0x1a4169('0xa')][_0x1a4169('0x18')](_0x272ad6,{'force':!![]})[_0x1a4169('0x0')](function(){const _0xf49fd5=_0x1a4169;logger[_0xf49fd5('0x30')](_0xf49fd5('0x1b'),_0x272ad6);})[_0x1a4169('0x27')](function(_0x4cbf23){const _0x535335=_0x1a4169;logger[_0x535335('0x30')](JSON[_0x535335('0xc')](_0x4cbf23));});});},Migration['prototype'][_0x4c9f67('0x24')]=function(_0x53d505,_0xd05574,_0x1aff36){const _0x3bd537=_0x4c9f67,_0x39ae4a=this;this[_0x3bd537('0xb')][_0x3bd537('0x2b')](function(){const _0x202e93=_0x3bd537;return _0x39ae4a['queryInterface'][_0x202e93('0x24')](_0x53d505,_0xd05574,{'indexName':_0x1aff36})[_0x202e93('0x0')](function(){const _0x15785a=_0x202e93;logger[_0x15785a('0x30')](_0x15785a('0x1a'),_0x53d505,_0xd05574[_0x15785a('0x3')](','),_0x1aff36);})[_0x202e93('0x27')](function(_0x388a0c){logger['info'](JSON['stringify'](_0x388a0c));});});},Migration[_0x4c9f67('0xd')][_0x4c9f67('0x7')]=function(_0x2cc9e8,_0x14e3b3){const _0x4fb0da=_0x4c9f67,_0x1a5f6f=this;this[_0x4fb0da('0xb')]['enqueue'](function(){const _0x1b1c68=_0x4fb0da;return _0x1a5f6f[_0x1b1c68('0xa')][_0x1b1c68('0x7')](_0x2cc9e8,_0x14e3b3)['then'](function(){const _0x7a627f=_0x1b1c68;logger[_0x7a627f('0x30')](_0x7a627f('0x2d'),_0x2cc9e8,_0x14e3b3);})[_0x1b1c68('0x27')](function(_0xce0b62){const _0x5cf203=_0x1b1c68;logger[_0x5cf203('0x30')](JSON[_0x5cf203('0xc')](_0xce0b62));});});},Migration[_0x4c9f67('0xd')][_0x4c9f67('0x2f')]=function(_0x2b63b4){const _0x1c5454=_0x4c9f67,_0x3a325a=this;this['sequence'][_0x1c5454('0x2b')](function(){const _0x3cdacd=_0x1c5454;return _0x3a325a[_0x3cdacd('0xa')][_0x3cdacd('0x9')][_0x3cdacd('0x2f')](_0x2b63b4)[_0x3cdacd('0x0')](function(){const _0x9b9c6e=_0x3cdacd;logger[_0x9b9c6e('0x30')](_0x9b9c6e('0xe'),_0x2b63b4);})[_0x3cdacd('0x27')](function(_0x53a190){const _0x551561=_0x3cdacd;logger[_0x551561('0x30')](JSON['stringify'](_0x53a190));});});},Migration[_0x4c9f67('0xd')]['removeColumn']=function(_0x3e360a,_0x31cd8d){const _0x9232d2=_0x4c9f67,_0x298c9d=this;this[_0x9232d2('0xb')][_0x9232d2('0x2b')](function(){const _0x1d5a13=_0x9232d2;return _0x298c9d[_0x1d5a13('0xa')][_0x1d5a13('0x1d')](_0x3e360a,_0x31cd8d)[_0x1d5a13('0x0')](function(){const _0x34953f=_0x1d5a13;logger[_0x34953f('0x30')](_0x34953f('0x1e'),_0x31cd8d,_0x3e360a);})[_0x1d5a13('0x27')](function(_0x2ccec2){const _0x5bfa6d=_0x1d5a13;logger[_0x5bfa6d('0x30')](util[_0x5bfa6d('0x2')](_0x2ccec2,{'showHidden':![],'depth':null}));});});},Migration[_0x4c9f67('0xd')][_0x4c9f67('0x28')]=function(_0x5ce6e9,_0x515815,_0x13533e){const _0x1fb49a=_0x4c9f67,_0x5c965c=this;this['sequence'][_0x1fb49a('0x2b')](function(){const _0x450b29=_0x1fb49a;return _0x5c965c[_0x450b29('0xa')][_0x450b29('0x28')](_0x5ce6e9,_0x515815,_0x13533e)[_0x450b29('0x0')](function(){const _0x18c12d=_0x450b29;logger[_0x18c12d('0x30')](_0x18c12d('0x22'),_0x515815,_0x13533e,_0x5ce6e9);})[_0x450b29('0x27')](function(_0x1530eb){const _0x22c022=_0x450b29;logger[_0x22c022('0x30')](util[_0x22c022('0x2')](_0x1530eb,{'showHidden':![],'depth':null}));});});},Migration[_0x4c9f67('0xd')]['final']=function(_0x5bdab7){const _0x310c30=_0x4c9f67;this[_0x310c30('0xb')][_0x310c30('0x2b')](function(){return _0x5bdab7();});},module[_0x4c9f67('0x21')]={'up':function(_0x5e5d0d,_0x996ad8){return new Promise(function(_0x1400d3){const _0x3ef4ee=a962_0x2edc,_0x5156a7=new Migration(_0x5e5d0d);_0x5156a7[_0x3ef4ee('0x20')](_0x3ef4ee('0x1'),_0x3ef4ee('0x15'),{'type':_0x996ad8[_0x3ef4ee('0x16')](0xb)}),_0x5156a7[_0x3ef4ee('0x2f')](_0x3ef4ee('0x5')),_0x5156a7['addColumn']('cm_contacts',_0x3ef4ee('0x1f'),{'type':_0x996ad8[_0x3ef4ee('0x4')]}),_0x5156a7[_0x3ef4ee('0x6')]('sms_accounts','type',{'type':_0x996ad8['ENUM'](_0x3ef4ee('0x29'),_0x3ef4ee('0x2c'),_0x3ef4ee('0x2e'),_0x3ef4ee('0xf'),_0x3ef4ee('0x25'),'clickatell',_0x3ef4ee('0x2a'),_0x3ef4ee('0x26'))}),_0x5156a7[_0x3ef4ee('0x20')](_0x3ef4ee('0x1c'),_0x3ef4ee('0x10'),{'type':_0x996ad8[_0x3ef4ee('0x4')]}),_0x5156a7[_0x3ef4ee('0x20')](_0x3ef4ee('0x13'),_0x3ef4ee('0x19'),{'type':_0x996ad8[_0x3ef4ee('0x16')],'defaultValue':0x0}),_0x5156a7[_0x3ef4ee('0x31')](_0x1400d3);});},'down':function(){}}; \ No newline at end of file +const a962_0x28de=['renameColumn','skebby','INTEGER','STRING','join','catch','util','type','removeIndex\x20%s\x20%s','baseUrl','dropTable','finally','changeColumn','cm_contacts','tail','query','ALTER\x20TABLE\x20cm_hopper\x20ADD\x20CONSTRAINT\x20cm_hopper_ibfk_6\x20FOREIGN\x20KEY\x20(OwnerId)\x20REFERENCES\x20users(id)\x20ON\x20UPDATE\x20CASCADE\x20ON\x20DELETE\x20SET\x20NULL','infobip','queryInterface','Changed\x20column\x20%s\x20in\x20table\x20%s','removeIndex','sequence','clickatell','addColumn','OwnerId','enqueue','plivo','sms_accounts','queuecallerenterreason','sequelize','removeColumn','info','inspect','then','stringify','addIndex','final','csc','prototype','report_queue','cm_hopper','addIndex\x20%s\x20%s\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','table\x20dropped\x20%s'];(function(_0x4b8606,_0x28de9b){const _0x45ddf6=function(_0x46c411){while(--_0x46c411){_0x4b8606['push'](_0x4b8606['shift']());}};_0x45ddf6(++_0x28de9b);}(a962_0x28de,0x10e));const a962_0x45dd=function(_0x4b8606,_0x28de9b){_0x4b8606=_0x4b8606-0x0;let _0x45ddf6=a962_0x28de[_0x4b8606];return _0x45ddf6;};const _0x52d647=a962_0x45dd;'use strict';const util=require(_0x52d647('0x0')),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence[_0x52d647('0x20')][_0x52d647('0x13')]=function(_0x46c411){const _0x5e2f29=_0x52d647;this[_0x5e2f29('0x8')]=this['tail']?this[_0x5e2f29('0x8')][_0x5e2f29('0x5')](_0x46c411):_0x46c411();};const Migration=function(_0x3d6029){const _0x26bdaa=_0x52d647;this['queryInterface']=_0x3d6029,this[_0x26bdaa('0xf')]=new Sequence();};Migration[_0x52d647('0x20')]['changeColumn']=function(_0x5a9e42,_0x55097f,_0x11551c){const _0x288157=_0x52d647,_0x2ecf39=this;this[_0x288157('0xf')][_0x288157('0x13')](function(){const _0xea58cb=_0x288157;return _0x2ecf39[_0xea58cb('0xc')][_0xea58cb('0x6')](_0x5a9e42,_0x55097f,_0x11551c)['then'](function(){const _0x2883ef=_0xea58cb;logger[_0x2883ef('0x19')](_0x2883ef('0xd'),_0x55097f,_0x5a9e42);})[_0xea58cb('0x2b')](function(_0x234aea){const _0x58110c=_0xea58cb;logger[_0x58110c('0x19')](JSON[_0x58110c('0x1c')](_0x234aea));});});},Migration['prototype']['addColumn']=function(_0xe0c9f9,_0x35309b,_0xcaba14){const _0x4631ff=_0x52d647,_0x5e37c7=this;this[_0x4631ff('0xf')]['enqueue'](function(){const _0x416df0=_0x4631ff;return _0x5e37c7['queryInterface'][_0x416df0('0x11')](_0xe0c9f9,_0x35309b,_0xcaba14)[_0x416df0('0x1b')](function(){const _0x20fc50=_0x416df0;logger[_0x20fc50('0x19')]('Added\x20column\x20%s\x20to\x20%s',_0x35309b,_0xe0c9f9);})[_0x416df0('0x2b')](function(_0x316c59){const _0x315f6b=_0x416df0;logger['info'](JSON[_0x315f6b('0x1c')](_0x316c59));});});},Migration[_0x52d647('0x20')][_0x52d647('0x4')]=function(_0x3e3412){const _0x39d2af=_0x52d647,_0xcf5206=this;this[_0x39d2af('0xf')][_0x39d2af('0x13')](function(){const _0x23a816=_0x39d2af;return _0xcf5206['queryInterface'][_0x23a816('0x4')](_0x3e3412,{'force':!![]})['then'](function(){const _0x41dd5f=_0x23a816;logger[_0x41dd5f('0x19')](_0x41dd5f('0x25'),_0x3e3412);})[_0x23a816('0x2b')](function(_0x36a8df){const _0xee1725=_0x23a816;logger['info'](JSON[_0xee1725('0x1c')](_0x36a8df));});});},Migration['prototype']['addIndex']=function(_0xa2876d,_0x5ad73c,_0x1cbbbd){const _0xeee04c=_0x52d647,_0x30c9dd=this;this['sequence'][_0xeee04c('0x13')](function(){const _0x189988=_0xeee04c;return _0x30c9dd['queryInterface'][_0x189988('0x1d')](_0xa2876d,_0x5ad73c,{'indexName':_0x1cbbbd})[_0x189988('0x1b')](function(){const _0x313646=_0x189988;logger[_0x313646('0x19')](_0x313646('0x23'),_0xa2876d,_0x5ad73c[_0x313646('0x2a')](','),_0x1cbbbd);})['catch'](function(_0x46750d){const _0x32ef65=_0x189988;logger[_0x32ef65('0x19')](JSON[_0x32ef65('0x1c')](_0x46750d));});});},Migration[_0x52d647('0x20')]['removeIndex']=function(_0xfeced3,_0x58a11b){const _0x4cca63=_0x52d647,_0x49d7da=this;this[_0x4cca63('0xf')][_0x4cca63('0x13')](function(){const _0x37feac=_0x4cca63;return _0x49d7da['queryInterface'][_0x37feac('0xe')](_0xfeced3,_0x58a11b)[_0x37feac('0x1b')](function(){const _0x45c261=_0x37feac;logger[_0x45c261('0x19')](_0x45c261('0x2'),_0xfeced3,_0x58a11b);})[_0x37feac('0x2b')](function(_0x351406){const _0x3fa955=_0x37feac;logger['info'](JSON[_0x3fa955('0x1c')](_0x351406));});});},Migration[_0x52d647('0x20')]['query']=function(_0x24e78c){const _0x25395e=_0x52d647,_0x561237=this;this[_0x25395e('0xf')][_0x25395e('0x13')](function(){const _0x13690d=_0x25395e;return _0x561237[_0x13690d('0xc')][_0x13690d('0x17')][_0x13690d('0x9')](_0x24e78c)[_0x13690d('0x1b')](function(){logger['info']('query\x20%s',_0x24e78c);})[_0x13690d('0x2b')](function(_0x4fed7f){const _0x5e51ae=_0x13690d;logger[_0x5e51ae('0x19')](JSON['stringify'](_0x4fed7f));});});},Migration['prototype'][_0x52d647('0x18')]=function(_0x321707,_0x202deb){const _0x3791be=this;this['sequence']['enqueue'](function(){const _0x250943=a962_0x45dd;return _0x3791be[_0x250943('0xc')][_0x250943('0x18')](_0x321707,_0x202deb)[_0x250943('0x1b')](function(){const _0xf3bef1=_0x250943;logger[_0xf3bef1('0x19')]('Removed\x20column\x20%s\x20from\x20%s',_0x202deb,_0x321707);})['catch'](function(_0x5774db){const _0x575472=_0x250943;logger['info'](util[_0x575472('0x1a')](_0x5774db,{'showHidden':![],'depth':null}));});});},Migration[_0x52d647('0x20')]['renameColumn']=function(_0x5af24d,_0x56804c,_0x56aa03){const _0x930818=_0x52d647,_0x430126=this;this[_0x930818('0xf')][_0x930818('0x13')](function(){const _0xc346d2=_0x930818;return _0x430126[_0xc346d2('0xc')][_0xc346d2('0x26')](_0x5af24d,_0x56804c,_0x56aa03)[_0xc346d2('0x1b')](function(){const _0x5d27cb=_0xc346d2;logger[_0x5d27cb('0x19')](_0x5d27cb('0x24'),_0x56804c,_0x56aa03,_0x5af24d);})['catch'](function(_0x21b6f9){const _0x133f98=_0xc346d2;logger['info'](util[_0x133f98('0x1a')](_0x21b6f9,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x52d647('0x1e')]=function(_0x4a7bb8){const _0x70b8b1=_0x52d647;this[_0x70b8b1('0xf')][_0x70b8b1('0x13')](function(){return _0x4a7bb8();});},module['exports']={'up':function(_0x5c63fe,_0x2255f5){return new Promise(function(_0x41cb31){const _0x4f8080=a962_0x45dd,_0x4c4d16=new Migration(_0x5c63fe);_0x4c4d16[_0x4f8080('0x11')](_0x4f8080('0x22'),_0x4f8080('0x12'),{'type':_0x2255f5[_0x4f8080('0x28')](0xb)}),_0x4c4d16['query'](_0x4f8080('0xa')),_0x4c4d16[_0x4f8080('0x11')](_0x4f8080('0x7'),'fb_data',{'type':_0x2255f5[_0x4f8080('0x29')]}),_0x4c4d16[_0x4f8080('0x6')](_0x4f8080('0x15'),_0x4f8080('0x1'),{'type':_0x2255f5['ENUM']('twilio',_0x4f8080('0x27'),'connectel','clicksend',_0x4f8080('0x14'),_0x4f8080('0x10'),_0x4f8080('0x1f'),_0x4f8080('0xb'))}),_0x4c4d16[_0x4f8080('0x11')](_0x4f8080('0x15'),_0x4f8080('0x3'),{'type':_0x2255f5[_0x4f8080('0x29')]}),_0x4c4d16['addColumn'](_0x4f8080('0x21'),_0x4f8080('0x16'),{'type':_0x2255f5[_0x4f8080('0x28')],'defaultValue':0x0}),_0x4c4d16[_0x4f8080('0x1e')](_0x41cb31);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.0.84.js b/server/migrations/2.0.84.js index 6fee3bc..fb85621 100644 --- a/server/migrations/2.0.84.js +++ b/server/migrations/2.0.84.js @@ -1 +1 @@ -const a963_0x14ad=['exports','Changed\x20column\x20%s\x20in\x20table\x20%s','removeIndex','tail','queryInterface','prototype','query','util','addColumn','query\x20%s','then','changeColumn','Added\x20column\x20%s\x20to\x20%s','final','addIndex','catch','info','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Removed\x20column\x20%s\x20from\x20%s','stringify','removeIndex\x20%s\x20%s','table\x20dropped\x20%s','../config/logger','removeColumn','sequence','finally','addIndex\x20%s\x20%s\x20%s','inspect','migration','dropTable','enqueue'];(function(_0x3cbac5,_0x14ad6b){const _0x47d684=function(_0x174ecb){while(--_0x174ecb){_0x3cbac5['push'](_0x3cbac5['shift']());}};_0x47d684(++_0x14ad6b);}(a963_0x14ad,0x19c));const a963_0x47d6=function(_0x3cbac5,_0x14ad6b){_0x3cbac5=_0x3cbac5-0x0;let _0x47d684=a963_0x14ad[_0x3cbac5];return _0x47d684;};const _0x4da4c5=a963_0x47d6;'use strict';const util=require(_0x4da4c5('0x1d')),logger=require(_0x4da4c5('0xd'))(_0x4da4c5('0x13')),Sequence=function(){};Sequence[_0x4da4c5('0x1b')]['enqueue']=function(_0x174ecb){const _0x5d939f=_0x4da4c5;this['tail']=this[_0x5d939f('0x19')]?this[_0x5d939f('0x19')][_0x5d939f('0x10')](_0x174ecb):_0x174ecb();};const Migration=function(_0x3302a1){const _0x3e836b=_0x4da4c5;this[_0x3e836b('0x1a')]=_0x3302a1,this[_0x3e836b('0xf')]=new Sequence();};Migration[_0x4da4c5('0x1b')][_0x4da4c5('0x2')]=function(_0x9cc64e,_0x58016f,_0x1d0f1c){const _0x355381=_0x4da4c5,_0x284d42=this;this[_0x355381('0xf')][_0x355381('0x15')](function(){const _0x590ae2=_0x355381;return _0x284d42[_0x590ae2('0x1a')][_0x590ae2('0x2')](_0x9cc64e,_0x58016f,_0x1d0f1c)[_0x590ae2('0x1')](function(){const _0x4c87dc=_0x590ae2;logger[_0x4c87dc('0x7')](_0x4c87dc('0x17'),_0x58016f,_0x9cc64e);})[_0x590ae2('0x6')](function(_0x29a049){const _0x362047=_0x590ae2;logger['info'](JSON[_0x362047('0xa')](_0x29a049));});});},Migration[_0x4da4c5('0x1b')][_0x4da4c5('0x1e')]=function(_0x59bf2b,_0xf1bafc,_0x13ab48){const _0x12a124=_0x4da4c5,_0x348b0f=this;this[_0x12a124('0xf')][_0x12a124('0x15')](function(){const _0x5219bc=_0x12a124;return _0x348b0f[_0x5219bc('0x1a')]['addColumn'](_0x59bf2b,_0xf1bafc,_0x13ab48)[_0x5219bc('0x1')](function(){const _0x518c33=_0x5219bc;logger['info'](_0x518c33('0x3'),_0xf1bafc,_0x59bf2b);})[_0x5219bc('0x6')](function(_0x4922a1){logger['info'](JSON['stringify'](_0x4922a1));});});},Migration[_0x4da4c5('0x1b')][_0x4da4c5('0x14')]=function(_0x1a51cd){const _0x42f21f=_0x4da4c5,_0x4c8b31=this;this['sequence'][_0x42f21f('0x15')](function(){const _0x349ff8=_0x42f21f;return _0x4c8b31[_0x349ff8('0x1a')]['dropTable'](_0x1a51cd,{'force':!![]})['then'](function(){const _0x14fb76=_0x349ff8;logger['info'](_0x14fb76('0xc'),_0x1a51cd);})[_0x349ff8('0x6')](function(_0x156040){const _0x40b6ef=_0x349ff8;logger[_0x40b6ef('0x7')](JSON[_0x40b6ef('0xa')](_0x156040));});});},Migration[_0x4da4c5('0x1b')][_0x4da4c5('0x5')]=function(_0x33e128,_0x3ad34e,_0x17ed2a){const _0x501ce3=_0x4da4c5,_0x43f4c8=this;this['sequence'][_0x501ce3('0x15')](function(){const _0x47fb81=_0x501ce3;return _0x43f4c8['queryInterface'][_0x47fb81('0x5')](_0x33e128,_0x3ad34e,{'indexName':_0x17ed2a})[_0x47fb81('0x1')](function(){const _0x3c4034=_0x47fb81;logger[_0x3c4034('0x7')](_0x3c4034('0x11'),_0x33e128,_0x3ad34e['join'](','),_0x17ed2a);})['catch'](function(_0x5d0adc){const _0x1fd818=_0x47fb81;logger[_0x1fd818('0x7')](JSON[_0x1fd818('0xa')](_0x5d0adc));});});},Migration[_0x4da4c5('0x1b')][_0x4da4c5('0x18')]=function(_0x49b349,_0x448a43){const _0x2be875=_0x4da4c5,_0x19860a=this;this[_0x2be875('0xf')][_0x2be875('0x15')](function(){const _0x685728=_0x2be875;return _0x19860a[_0x685728('0x1a')]['removeIndex'](_0x49b349,_0x448a43)['then'](function(){const _0x4a6cf4=_0x685728;logger[_0x4a6cf4('0x7')](_0x4a6cf4('0xb'),_0x49b349,_0x448a43);})[_0x685728('0x6')](function(_0x192618){const _0xa24be4=_0x685728;logger[_0xa24be4('0x7')](JSON[_0xa24be4('0xa')](_0x192618));});});},Migration[_0x4da4c5('0x1b')][_0x4da4c5('0x1c')]=function(_0x5e20bb){const _0x1e2f6d=_0x4da4c5,_0x30db9d=this;this[_0x1e2f6d('0xf')][_0x1e2f6d('0x15')](function(){const _0x6dedd4=_0x1e2f6d;return _0x30db9d[_0x6dedd4('0x1a')]['sequelize'][_0x6dedd4('0x1c')](_0x5e20bb)[_0x6dedd4('0x1')](function(){const _0x3f5490=_0x6dedd4;logger[_0x3f5490('0x7')](_0x3f5490('0x0'),_0x5e20bb);})['catch'](function(_0x3dc00b){const _0x4d4c46=_0x6dedd4;logger['info'](JSON[_0x4d4c46('0xa')](_0x3dc00b));});});},Migration[_0x4da4c5('0x1b')]['removeColumn']=function(_0x4859f2,_0x45d038){const _0x59d687=_0x4da4c5,_0x20ab5e=this;this[_0x59d687('0xf')][_0x59d687('0x15')](function(){const _0x1b9d36=_0x59d687;return _0x20ab5e[_0x1b9d36('0x1a')][_0x1b9d36('0xe')](_0x4859f2,_0x45d038)[_0x1b9d36('0x1')](function(){const _0x30b63c=_0x1b9d36;logger[_0x30b63c('0x7')](_0x30b63c('0x9'),_0x45d038,_0x4859f2);})[_0x1b9d36('0x6')](function(_0x5dd80b){logger['info'](util['inspect'](_0x5dd80b,{'showHidden':![],'depth':null}));});});},Migration['prototype']['renameColumn']=function(_0x3014b3,_0x31e7f0,_0xc9b096){const _0x301225=_0x4da4c5,_0x3985ef=this;this[_0x301225('0xf')][_0x301225('0x15')](function(){const _0x390832=_0x301225;return _0x3985ef[_0x390832('0x1a')]['renameColumn'](_0x3014b3,_0x31e7f0,_0xc9b096)[_0x390832('0x1')](function(){const _0x774109=_0x390832;logger[_0x774109('0x7')](_0x774109('0x8'),_0x31e7f0,_0xc9b096,_0x3014b3);})[_0x390832('0x6')](function(_0x3ad9ab){const _0x1ad363=_0x390832;logger[_0x1ad363('0x7')](util[_0x1ad363('0x12')](_0x3ad9ab,{'showHidden':![],'depth':null}));});});},Migration[_0x4da4c5('0x1b')][_0x4da4c5('0x4')]=function(_0x1e6dcb){const _0x5ae9fd=_0x4da4c5;this[_0x5ae9fd('0xf')][_0x5ae9fd('0x15')](function(){return _0x1e6dcb();});},module[_0x4da4c5('0x16')]={'up':function(_0x4f4c59){return new Promise(function(_0x387873){const _0x460d93=new Migration(_0x4f4c59);_0x460d93['final'](_0x387873);});},'down':function(){}}; \ No newline at end of file +const a963_0xb077=['removeIndex\x20%s\x20%s','finally','join','stringify','sequelize','tail','migration','enqueue','prototype','Changed\x20column\x20%s\x20in\x20table\x20%s','queryInterface','final','removeColumn','catch','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','then','sequence','Removed\x20column\x20%s\x20from\x20%s','addIndex\x20%s\x20%s\x20%s','info','removeIndex','inspect','table\x20dropped\x20%s','renameColumn','addIndex','changeColumn','query\x20%s','addColumn','exports','dropTable','query'];(function(_0x1e668c,_0xb0771b){const _0x19da6e=function(_0x32015e){while(--_0x32015e){_0x1e668c['push'](_0x1e668c['shift']());}};_0x19da6e(++_0xb0771b);}(a963_0xb077,0xcd));const a963_0x19da=function(_0x1e668c,_0xb0771b){_0x1e668c=_0x1e668c-0x0;let _0x19da6e=a963_0xb077[_0x1e668c];return _0x19da6e;};const _0x182cfd=a963_0x19da;'use strict';const util=require('util'),logger=require('../config/logger')(_0x182cfd('0x12')),Sequence=function(){};Sequence[_0x182cfd('0x14')]['enqueue']=function(_0x32015e){const _0x483997=_0x182cfd;this[_0x483997('0x11')]=this[_0x483997('0x11')]?this[_0x483997('0x11')][_0x483997('0xd')](_0x32015e):_0x32015e();};const Migration=function(_0x415ab1){const _0x3e0d44=_0x182cfd;this[_0x3e0d44('0x16')]=_0x415ab1,this[_0x3e0d44('0x1c')]=new Sequence();};Migration[_0x182cfd('0x14')]['changeColumn']=function(_0x19c77a,_0x2b887a,_0x5148a0){const _0x1452ed=_0x182cfd,_0x5cec1b=this;this[_0x1452ed('0x1c')][_0x1452ed('0x13')](function(){const _0x116a84=_0x1452ed;return _0x5cec1b[_0x116a84('0x16')][_0x116a84('0x6')](_0x19c77a,_0x2b887a,_0x5148a0)[_0x116a84('0x1b')](function(){const _0x2fb575=_0x116a84;logger[_0x2fb575('0x0')](_0x2fb575('0x15'),_0x2b887a,_0x19c77a);})[_0x116a84('0x19')](function(_0xb1dd1c){const _0x2d7e22=_0x116a84;logger[_0x2d7e22('0x0')](JSON[_0x2d7e22('0xf')](_0xb1dd1c));});});},Migration[_0x182cfd('0x14')][_0x182cfd('0x8')]=function(_0xc2730e,_0x4a55e7,_0x44bd5c){const _0x3aceb1=_0x182cfd,_0x2c284b=this;this[_0x3aceb1('0x1c')][_0x3aceb1('0x13')](function(){const _0x33a7d3=_0x3aceb1;return _0x2c284b[_0x33a7d3('0x16')]['addColumn'](_0xc2730e,_0x4a55e7,_0x44bd5c)[_0x33a7d3('0x1b')](function(){const _0x5293d7=_0x33a7d3;logger[_0x5293d7('0x0')]('Added\x20column\x20%s\x20to\x20%s',_0x4a55e7,_0xc2730e);})[_0x33a7d3('0x19')](function(_0x47ae92){const _0xb7dbb1=_0x33a7d3;logger[_0xb7dbb1('0x0')](JSON[_0xb7dbb1('0xf')](_0x47ae92));});});},Migration['prototype'][_0x182cfd('0xa')]=function(_0x7f7a5){const _0x20c895=_0x182cfd,_0x4e39b5=this;this[_0x20c895('0x1c')][_0x20c895('0x13')](function(){const _0x17efd7=_0x20c895;return _0x4e39b5[_0x17efd7('0x16')]['dropTable'](_0x7f7a5,{'force':!![]})[_0x17efd7('0x1b')](function(){const _0x51229d=_0x17efd7;logger[_0x51229d('0x0')](_0x51229d('0x3'),_0x7f7a5);})[_0x17efd7('0x19')](function(_0x1150c1){const _0x4ea6fb=_0x17efd7;logger[_0x4ea6fb('0x0')](JSON[_0x4ea6fb('0xf')](_0x1150c1));});});},Migration[_0x182cfd('0x14')][_0x182cfd('0x5')]=function(_0x36bea4,_0x429823,_0x173b92){const _0x28a40d=_0x182cfd,_0x22d3e7=this;this[_0x28a40d('0x1c')][_0x28a40d('0x13')](function(){const _0x265e1f=_0x28a40d;return _0x22d3e7[_0x265e1f('0x16')][_0x265e1f('0x5')](_0x36bea4,_0x429823,{'indexName':_0x173b92})[_0x265e1f('0x1b')](function(){const _0xb92b1b=_0x265e1f;logger[_0xb92b1b('0x0')](_0xb92b1b('0x1e'),_0x36bea4,_0x429823[_0xb92b1b('0xe')](','),_0x173b92);})[_0x265e1f('0x19')](function(_0xd10257){const _0x20e6c0=_0x265e1f;logger[_0x20e6c0('0x0')](JSON[_0x20e6c0('0xf')](_0xd10257));});});},Migration['prototype'][_0x182cfd('0x1')]=function(_0x776e6a,_0x587a84){const _0x413b80=_0x182cfd,_0x31454f=this;this[_0x413b80('0x1c')][_0x413b80('0x13')](function(){const _0x5e49ea=_0x413b80;return _0x31454f['queryInterface'][_0x5e49ea('0x1')](_0x776e6a,_0x587a84)[_0x5e49ea('0x1b')](function(){const _0x1bd9b1=_0x5e49ea;logger['info'](_0x1bd9b1('0xc'),_0x776e6a,_0x587a84);})['catch'](function(_0x56ac63){const _0x2e515a=_0x5e49ea;logger[_0x2e515a('0x0')](JSON[_0x2e515a('0xf')](_0x56ac63));});});},Migration[_0x182cfd('0x14')][_0x182cfd('0xb')]=function(_0x3415d9){const _0x2cf96=_0x182cfd,_0x42538e=this;this[_0x2cf96('0x1c')][_0x2cf96('0x13')](function(){const _0x946b69=_0x2cf96;return _0x42538e[_0x946b69('0x16')][_0x946b69('0x10')][_0x946b69('0xb')](_0x3415d9)[_0x946b69('0x1b')](function(){const _0x47fdeb=_0x946b69;logger[_0x47fdeb('0x0')](_0x47fdeb('0x7'),_0x3415d9);})[_0x946b69('0x19')](function(_0x103bca){const _0x3abd6a=_0x946b69;logger['info'](JSON[_0x3abd6a('0xf')](_0x103bca));});});},Migration[_0x182cfd('0x14')][_0x182cfd('0x18')]=function(_0x135a75,_0xb1b775){const _0x1f14dc=_0x182cfd,_0x489b47=this;this[_0x1f14dc('0x1c')][_0x1f14dc('0x13')](function(){const _0x30e641=_0x1f14dc;return _0x489b47[_0x30e641('0x16')][_0x30e641('0x18')](_0x135a75,_0xb1b775)[_0x30e641('0x1b')](function(){const _0x5f52e7=_0x30e641;logger[_0x5f52e7('0x0')](_0x5f52e7('0x1d'),_0xb1b775,_0x135a75);})[_0x30e641('0x19')](function(_0x14cd66){const _0x299135=_0x30e641;logger['info'](util[_0x299135('0x2')](_0x14cd66,{'showHidden':![],'depth':null}));});});},Migration[_0x182cfd('0x14')]['renameColumn']=function(_0x55a202,_0x574675,_0x53cb22){const _0x230438=_0x182cfd,_0x9f0beb=this;this[_0x230438('0x1c')][_0x230438('0x13')](function(){const _0x4abe91=_0x230438;return _0x9f0beb[_0x4abe91('0x16')][_0x4abe91('0x4')](_0x55a202,_0x574675,_0x53cb22)['then'](function(){const _0x1d4b1d=_0x4abe91;logger[_0x1d4b1d('0x0')](_0x1d4b1d('0x1a'),_0x574675,_0x53cb22,_0x55a202);})[_0x4abe91('0x19')](function(_0x246e17){const _0x3d6a77=_0x4abe91;logger[_0x3d6a77('0x0')](util[_0x3d6a77('0x2')](_0x246e17,{'showHidden':![],'depth':null}));});});},Migration[_0x182cfd('0x14')][_0x182cfd('0x17')]=function(_0x5c0ce0){const _0x34e479=_0x182cfd;this[_0x34e479('0x1c')][_0x34e479('0x13')](function(){return _0x5c0ce0();});},module[_0x182cfd('0x9')]={'up':function(_0x4f349f){return new Promise(function(_0x3f3f5d){const _0x2486f8=a963_0x19da,_0x48112a=new Migration(_0x4f349f);_0x48112a[_0x2486f8('0x17')](_0x3f3f5d);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.1.0.js b/server/migrations/2.1.0.js index 66bdefb..f7fb816 100644 --- a/server/migrations/2.1.0.js +++ b/server/migrations/2.1.0.js @@ -1 +1 @@ -const a964_0x4614=['\x20\x20SELECT\x20*\x20FROM\x20tmpSingleProfiles;','userProfileId','VALUES\x20(\x27Default\x27,\x20\x27red\x27,\x20NULL,\x20NOW(),\x20NOW());','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20701\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20sms_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20INNER\x20JOIN\x20user_has_openchannel_accounts\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(p.permissions,\x20\x27,\x27,\x20tally.n),\x20\x27,\x27,\x20-1)\x20permission,','\x20\x20\x20\x20\x20\x20permissions\x20text\x20not\x20null','\x20\x20CROSS\x20JOIN\x20(SELECT\x20@cnt\x20:=\x200)\x20as\x20dummy\x20LIMIT\x201)),\x20\x27red\x27,\x20now(),\x20now()','\x20\x20SELECT\x20x.sectionId,\x20u.SquareProjectId,\x20x.userId','\x20\x20\x20\x20t.permissions\x20permissions','\x20\x20ORDER\x20BY\x20id;','queryInterface','\x20\x20FROM\x20(SELECT','INSERT\x20INTO\x20tmpNormalizedSections','addIndex','\x20\x20\x20\x20insertedId\x20int(11),','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201600\x20THEN\x20\x27Help\x27','CREATE\x20TABLE\x20tmpNormalizedSections','INSERT\x20INTO\x20tmpSharedProfiles','\x20\x20userId\x20int(11)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CASE','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GROUP\x20BY\x20resourceId,\x20sectionId','UPDATE\x20tmpFinalProfiles','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201103\x20THEN\x20\x27SquareProjects\x27','\x20\x20\x20\x20sectionId\x20int(11)\x20not\x20null,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20800\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20between\x2088889\x20AND\x2099999\x20THEN\x20\x27Plugins\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20100\x20THEN\x20\x27Dashboards\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20600\x20THEN\x20\x27DELETE\x27','\x20\x20FROM\x20tally\x20INNER\x20JOIN\x20tmpPermissions\x20t\x20ON\x20CHAR_LENGTH(t.userIds)\x20-\x20CHAR_LENGTH(REPLACE(t.userIds,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20tally.n-1','CREATE\x20TABLE\x20tmpCustomResources','\x20\x20WHERE\x20x.sectionId\x20=\x20902;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20601\x20THEN\x20\x27MailQueues\x27','\x20\x20WHERE\x20name\x20in\x20(\x27Plugins\x27,\x20\x27CustomDashboards\x27);','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20902\x20THEN\x20\x27FaxAccounts\x27','CREATE\x20TABLE\x20`user_profile_has_sections`\x20(','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20700\x20THEN\x20\x27DELETE\x27','analytics_extracted_reports','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tally\x20t\x20INNER\x20JOIN\x20tmpPermissions\x20r\x20ON\x20CHAR_LENGTH(r.userIds)\x20-\x20CHAR_LENGTH(REPLACE(r.userIds,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20t.n-1','migration','\x20\x20FROM\x20tmpSections','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201302\x20THEN\x20\x27SalesforceAccounts\x27','UPDATE\x20users\x20u,\x20tmpFinalProfiles\x20f','\x20\x20FROM\x20tally\x20t\x20INNER\x20JOIN\x20tmpNormalizedSections\x20s\x20ON\x20CHAR_LENGTH(s.userId)\x20-\x20CHAR_LENGTH(REPLACE(s.userId,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20t.n-1','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tmpNormalizedUsers','ALTER\x20TABLE\x20`users`\x20','\x20\x20FROM\x20tmpFinalProfiles\x20t','CREATE\x20TABLE\x20tally\x20(','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20),','CREATE\x20TABLE\x20tmpFinalProfiles','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20(select\x20SUBSTRING_INDEX(SUBSTRING_INDEX(r.userIds,\x20\x27,\x27,\x20t.n),\x20\x27,\x27,\x20-1)\x20userId','\x20\x20WHERE\x20r.name\x20=\x20s.name\x20AND\x20r.userProfileId\x20=\x20s.userProfileId;','removeColumn','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20610\x20THEN\x20\x27Realtime\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201305\x20THEN\x20\x27SugarcrmAccounts\x27','UPDATE\x20tmpNormalizedResources\x20x','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(701,\x20702,\x20710)\x20THEN\x20\x27Sms\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201003\x20THEN\x20\x27CustomDashboards\x27','UPDATE\x20tmpCustomResources','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(601,\x20602,\x20603,\x20610)\x20THEN\x20\x27Mail\x27','query',',(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20d','\x20\x20`name`\x20varchar(255)\x20NOT\x20NULL,','INSERT\x20INTO\x20tmpPermissions','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20502\x20THEN\x20\x27ChatWebsites\x27','reportType','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201701\x20THEN\x20\x27Projects\x27','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20901\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20fax_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20FROM\x20tmpSections\x20s','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201510\x20THEN\x20\x27Realtime\x27','INSERT\x20INTO\x20tmpCustomResources','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20410\x20THEN\x20\x27VoicePrefixes\x27','\x20\x20END','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20411\x20THEN\x20\x27Realtime\x27','\x20\x20SET\x20insertedId\x20=\x20(SELECT','\x20\x20WHERE\x20x.sectionId\x20=\x20502;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201203\x20THEN\x20\x27Reports\x27','Removed\x20column\x20%s\x20from\x20%s','\x20\x20INNER\x20JOIN\x20tmpExtractedResources\x20cr\x20ON\x20cr.userId\x20=\x20s.userId\x20AND\x20cr.sectionId\x20=\x20s.sectionId\x20AND\x20cr.resourceId\x20IS\x20NOT\x20NULL;','\x20\x20ORDER\x20BY\x20userId;','name','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20710\x20THEN\x20\x27Realtime\x27','\x20\x20);','\x20\x20ORDER\x20BY\x20GROUP_CONCAT(id);','\x20\x20SELECT\x20x.sectionId,\x20u.SmsQueueId,\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20300\x20THEN\x20\x27DELETE\x27',')\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20502\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20chat_websites\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20(SELECT','SELECT\x20NULL\x20FROM','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(801,\x20802,\x20810)\x20THEN\x20\x27Openchannel\x27','REFERENCES\x20user_profiles(`id`)\x20','\x20\x20SET\x20insertedId\x20=\x20(SELECT\x20id','\x20\x20SET\x20profileId\x20=\x20(SELECT\x20(@cnt\x20:=\x20@cnt\x20+\x201)\x20AS\x20rowNumber','DELETE\x20FROM\x20tmpSections','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201200\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201004\x20THEN\x20\x27Intervals\x27','join','\x20\x20WHERE\x20x.sectionId\x20=\x20601;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20801\x20THEN\x20\x27OpenchannelQueues\x27','addIndex\x20%s\x20%s\x20%s','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20name\x20=\x20\x27CustomDashboards\x27\x20THEN\x20(sectionId\x20-\x2099999)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201301\x20THEN\x20\x27ZendeskAccounts\x27','\x20\x20\x20\x20\x20\x20\x20\x20INNER\x20JOIN\x20tmpResources\x20r\x20ON\x20CHAR_LENGTH(r.resourceId)\x20-\x20CHAR_LENGTH(REPLACE(r.resourceId,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20tally.n-1','\x20\x20\x20\x20\x20\x20profileId\x20int(11)','CREATE\x20TABLE\x20tmpExtractedResources\x20(','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpSections;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20910\x20THEN\x20\x27Realtime\x27','\x20\x20\x20\x20\x20\x20WHEN\x20x.type\x20=\x20\x27Plugins\x27\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20plugins\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20KEY\x20`userProfileId`\x20(`userProfileId`),','\x20\x20\x20\x20type\x20varchar(255)\x20not\x20null,','CREATE\x20TABLE\x20tmpSections','\x20\x20SELECT\x20x.sectionId,\x20u.ChatQueueId,\x20x.userId','then','\x20\x20SELECT\x20userId,\x20permissions,\x20null','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x201103\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20square_projects\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20INNER\x20JOIN\x20user_has_sms_accounts\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20resourceId\x20int(11),','\x20\x20SELECT\x20x.sectionId,\x20u.MailQueueId,\x20x.userId','CREATE\x20TABLE\x20`user_profile_has_resources`\x20(','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20403\x20THEN\x20\x27OutboundRoutes\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20END','dropTable','users','\x20\x20ORDER\x20BY\x20n)\x20AS\x20split;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201307\x20THEN\x20\x27ZohoAccounts\x27','\x20\x20FROM\x20tmpNormalizedUsers\x20x','removeIndex\x20%s\x20%s','\x20\x20`description`\x20varchar(255)\x20DEFAULT\x20NULL,','\x20\x20(','\x20\x20INNER\x20JOIN\x20user_has_openchannel_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20\x20\x20\x20\x20sectionId\x20int(11)','\x20\x20FROM\x20user_profiles\x20u','\x20\x20`resourceId`\x20int(11)\x20NOT\x20NULL,','\x20\x20FROM\x20users','../config/logger','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20>=\x20100000\x20THEN\x20\x27CustomDashboards\x27','\x20\x20WHERE\x20name\x20=\x20\x27DELETE_MIGRATION\x27;','\x20\x20\x20\x20\x20\x20END','INSERT\x20INTO\x20tmpResources','\x20\x20SELECT\x20\x27\x27,\x20resourceId,\x20type,\x20insertedSectionId,\x20sectionId','\x20\x20WHERE\x20userProfileId\x20is\x20null\x20AND\x20role\x20=\x20\x27user\x27;','\x20\x20SELECT\x20id,\x20permissions,\x20null','\x20\x20\x20\x20\x20\x20userId\x20text\x20not\x20null,','\x20\x20\x20\x20resourceId\x20text','\x20\x20GROUP\x20BY\x20permissions','exports','UPDATE\x20tmpSections','\x20\x20`crudPermissions`\x20varchar(255)\x20NOT\x20NULL\x20DEFAULT\x20\x27r\x27,','changeColumn','\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tally','\x20\x20\x20\x20\x20\x20resourceId\x20text,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201102\x20THEN\x20\x27SquareRecordings\x27','\x20\x20\x20\x20\x20\x20\x20\x20r.sectionId\x20sectionId','\x20\x20SELECT\x20x.sectionId,\x20u.SmsAccountId,\x20x.userId','\x20\x20WHERE\x20x.sectionId\x20=\x20802;','\x20\x20category\x20=\x20(SELECT','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ELSE\x20\x27\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201100\x20THEN\x20\x27DELETE\x27','CREATE\x20TABLE\x20tmpNormalizedUsers','addColumn','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20810\x20THEN\x20\x27Realtime\x27','table\x20dropped\x20%s','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20302\x20THEN\x20\x27Companies\x27','\x20\x20CONSTRAINT\x20`user_profile_has_resources_ibfk_1`\x20FOREIGN\x20KEY\x20(`sectionId`)\x20REFERENCES\x20`user_profile_has_sections`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE','INSERT\x20INTO\x20tmpNormalizedPermissions','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201400\x20THEN\x20\x27Settings\x27','\x20\x20\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(fp.userId,\x20\x27,\x27,\x201)\x20userId','\x20\x20INNER\x20JOIN\x20user_has_mail_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpNormalizedResources;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20510\x20THEN\x20\x27Realtime\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20n)\x20AS\x20split','INSERT\x20INTO\x20tmpNormalizedResources','renameColumn','\x20\x20\x20\x20userId\x20int(11)\x20not\x20null','\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(t.userIds,\x20\x27,\x27,\x20tally.n),\x20\x27,\x27,\x20-1)\x20userId,','\x20\x20SELECT\x20x.sectionId,\x20u.FaxQueueId,\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201306\x20THEN\x20\x27DeskAccounts\x27','\x20\x20\x20\x20category\x20varchar(255)\x20not\x20null,','\x20\x20`userProfileId`\x20int(11)\x20DEFAULT\x20NULL,','\x20\x20WHERE\x20x.sectionId\x20=\x201103;','sequence','\x20\x20\x20\x20\x20\x20permissions\x20text\x20not\x20null,','INSERT\x20INTO\x20tmpExtractedResources','\x20\x20\x20\x20sectionId\x20int(11)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tally\x20t','INTEGER','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20401\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20voice_queues\x20WHERE\x20id\x20=\x20x.resourceId\x20AND\x20type\x20=\x20\x27inbound\x27),\x27DELETE_MIGRATION\x27)','\x20\x20SELECT\x20x.sectionId,\x20u.FaxAccountId,\x20x.userId','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20602\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20mail_accounts\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpSingleProfiles;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20INNER\x20JOIN\x20tmpPermissions\x20r\x20on\x20CHAR_LENGTH(r.userIds)\x20-\x20CHAR_LENGTH(REPLACE(r.userIds,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20t.n-1','\x20\x20FROM\x20tmpCustomResources;','INSERT\x20INTO\x20tally\x20(n)','\x20\x20`enabled`\x20tinyint(1)\x20DEFAULT\x20NULL,','\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,','\x20\x20WHERE\x20split.userId\x20IN\x20(SELECT\x20*\x20FROM','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GROUP\x20BY\x20resourceId,\x20sectionId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20702\x20THEN\x20\x27SmsAccounts\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20201\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20INNER\x20JOIN\x20tmpFinalProfiles\x20fp\x20ON\x20CHAR_LENGTH(fp.permissions)\x20-\x20CHAR_LENGTH(REPLACE(fp.permissions,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20tally.n-1','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20405\x20THEN\x20\x27Contexts\x27','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20>=\x20100000\x20THEN\x20\x27Tools\x27','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1101,\x201102,\x201103)\x20THEN\x20\x27CallySquare\x27','tail','\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20POSITION(\x27,\x27\x20in\x20r.userIds)\x20>\x200','\x20\x20\x20\x20\x20\x20name\x20=\x20(SELECT','\x20\x20WHERE\x20x.sectionId\x20=\x20901;','stringify','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201008\x20THEN\x20\x27Tags\x27','CREATE\x20TABLE\x20tmpGroupedPermissions','\x20\x20SELECT\x20GROUP_CONCAT(sectionId\x20ORDER\x20BY\x20sectionId),\x20userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201700\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20END','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpNormalizedSections;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20602\x20THEN\x20\x27MailAccounts\x27','\x20\x20SELECT\x20GROUP_CONCAT(id),\x20permissions,\x20null','inspect','\x20\x20SELECT\x20*','\x20\x20INNER\x20JOIN\x20user_has_chat_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20400\x20THEN\x20\x27DELETE\x27','\x20\x20SET\x20name\x20=\x20(SELECT','\x20\x20\x20\x20\x20\x20\x20\x20r.insertedSectionId\x20insertedSectionId,','\x20\x20WHERE\x20t1.name\x20=\x20t2.name\x20AND\x20t1.userProfileId\x20=\x20t2.userProfileId\x20AND\x20t1.sectionId\x20>\x20t2.sectionId;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20);','\x20\x20UNION','\x20\x20WHERE\x20u.id\x20=\x20t.userId;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20500\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20autoAssociation\x20tinyint\x20not\x20null,','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpPermissions;','\x20\x20\x20\x20enabled\x20tinyint\x20not\x20null,','\x20\x20SET\x20sectionId\x20=\x201003\x20WHERE\x20sectionId\x20>=\x20100000;','\x20\x20n\x20INT\x20NOT\x20NULL\x20AUTO_INCREMENT\x20PRIMARY\x20KEY','\x20\x20\x20\x20resourceId\x20int(11)\x20not\x20null,','\x20\x20FROM\x20tmpGroupedPermissions','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201001\x20THEN\x20\x27CannedAnswers\x27','\x20\x20\x20\x20userProfileId\x20int(11)\x20not\x20null,','CREATE\x20TABLE\x20tmpNormalizedPermissions','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20601\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20mail_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(SELECT\x20GROUP_CONCAT(userId\x20ORDER\x20BY\x20userId\x20ASC)\x20as\x20users','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20user_profile_has_sections\x20x','catch','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1001,\x201002,\x201003,\x201004,\x201005,\x201006,\x201007,\x201008,\x201009,\x201010,\x201011,\x201012)\x20THEN\x20\x27Tools\x27','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1501,\x201502,\x201510)\x20THEN\x20\x27MotionDialer\x27','\x20\x20\x20\x20\x20\x20userIds\x20varchar(255)\x20not\x20null,','\x20\x20SELECT\x20\x27\x27,\x20insertedId,\x20name,\x20sectionId,\x20null','\x20\x20FROM\x20tmpFinalProfiles;','INSERT\x20INTO\x20user_profiles\x20(name,\x20crudPermissions,\x20createdAt,\x20updatedAt)','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(202,\x20203,\x20204)\x20THEN\x20\x27Staff\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CASE','\x20\x20SELECT\x20x.sectionId,\x20u.VoiceQueueId,\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201101\x20THEN\x20\x27ODBC\x27','\x20\x20PRIMARY\x20KEY\x20(`id`),','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201202\x20THEN\x20\x27ExtractedReports\x27','INSERT\x20INTO\x20user_profile_has_sections\x20(name,\x20category,\x20sectionId,\x20enabled,\x20autoAssociation,\x20crudPermissions,\x20createdAt,\x20updatedAt,\x20userProfileId)','sequelize','\x20\x20FROM\x20tally\x20INNER\x20JOIN\x20tmpPermissions\x20p\x20ON\x20CHAR_LENGTH(p.permissions)\x20-\x20CHAR_LENGTH(REPLACE(p.permissions,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20tally.n-1','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CASE','\x20\x20INNER\x20JOIN\x20user_has_chat_websites\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20WHERE\x20u.id\x20=\x20f.userId;','\x20\x20CROSS\x20JOIN\x20(SELECT\x20@cnt\x20:=\x201)\x20as\x20dummy\x20LIMIT\x201)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20200\x20THEN\x20\x27DELETE\x27','\x20\x20SELECT\x20\x27\x27,\x20\x27\x27,\x20permission,\x201,\x200,\x20profileId,\x20null,\x20userId','finally','prototype','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201502\x20THEN\x20\x27IvrCampaigns\x27','UPDATE\x20users\x20u,\x20tmpNormalizedPermissions\x20t','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20402\x20THEN\x20\x27InboundRoutes\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201303\x20THEN\x20\x27FreshdeskAccounts\x27','\x20\x20KEY\x20`compositeIndex`\x20(`sectionId`,`userProfileId`),','TRUNCATE\x20TABLE\x20tmpPermissions;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tmpNormalizedUsers','\x20\x20`type`\x20varchar(255)\x20NOT\x20NULL,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201308\x20THEN\x20\x27VtigerAccounts\x27','\x20\x20INNER\x20JOIN\x20voice_queues\x20q\x20ON\x20u.VoiceQueueId\x20=\x20q.id','\x20\x20SET\x20u.userProfileId\x20=\x20f.profileId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20s.userProfileId\x20=\x20x.userProfileId\x20AND\x20s.sectionId\x20=\x20x.sectionId);','INSERT\x20INTO\x20user_profile_has_resources\x20(name,\x20resourceId,\x20type,\x20createdAt,\x20updatedAt,\x20sectionId)','\x20\x20`crudPermissions`\x20varchar(255)\x20DEFAULT\x20NULL,','CREATE\x20TABLE\x20tmpNormalizedResources','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20between\x2088889\x20AND\x2099999\x20THEN\x20\x27AppZone\x27','INSERT\x20INTO\x20tmpSections','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20n)\x20as\x20split','\x20\x20KEY\x20`sectionId`\x20(`sectionId`),','(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20a','\x20\x20\x20\x20userId\x20text','\x20\x20INNER\x20JOIN\x20user_has_fax_accounts\x20u\x20ON\x20u.UserId\x20=\x20x.userId','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpFinalProfiles;','INSERT\x20INTO\x20tmpGroupedPermissions','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20users)\x20b','CREATE\x20TABLE\x20tmpPermissions','\x20\x20SET\x20u.userProfileId\x20=\x201','\x20\x20SET\x20autoAssociation\x20=\x201\x20WHERE\x20sectionId\x20=\x20100;','\x20\x20\x20\x20\x20\x20type\x20varchar(255)\x20not\x20null,','ADD\x20CONSTRAINT\x20`users_ibfk_1`\x20','UPDATE\x20users\x20u','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(301,\x20302,\x20303,\x20304)\x20THEN\x20\x27ContactManager\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20401\x20THEN\x20\x27VoiceQueues\x27','\x20\x20FROM\x20tmpSections;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(r.userIds,\x20\x27,\x27,\x20t.n),\x20\x27,\x27,\x20-1)\x20userId','\x20\x20\x20\x20\x20\x20\x20\x20r.type\x20type,','\x20DROP\x20TABLE\x20IF\x20EXISTS\x20tally;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20900\x20THEN\x20\x27DELETE\x27','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpResources;','\x20\x20\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(r.resourceId,\x20\x27,\x27,\x20tally.n),\x20\x27,\x27,\x20-1)\x20resourceId,','\x20\x20FROM\x20tmpNormalizedResources;','enqueue','\x20\x20SELECT\x20permission,\x20userId,\x200','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201300\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201501\x20THEN\x20\x27QueueCampaigns\x27','\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20n)\x20AS\x20split;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20603\x20THEN\x20\x27MailSubstatuses\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201500\x20THEN\x20\x27DELETE\x27','final','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201011\x20THEN\x20\x27Trunks\x27','\x20\x20sectionId\x20int(11)\x20not\x20null,','query\x20%s','\x20\x20WHERE\x20role\x20=\x20\x27user\x27\x20and\x20permissions\x20is\x20not\x20null\x20and\x20permissions\x20<>\x20\x27\x27','\x20\x20WHERE\x20name\x20=\x20\x27DELETE\x27;','\x20\x20SELECT\x20x.sectionId,\x20u.OpenchannelQueueId,\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20);','CREATE\x20TABLE\x20tmpResources','\x20\x20\x20\x20\x20\x20WHEN\x20name\x20=\x20\x27Plugins\x27\x20THEN\x20(sectionId\x20-\x2088888)',',(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20b','\x20\x20`sectionId`\x20int(11)\x20DEFAULT\x20NULL,','\x20\x20SELECT\x20CONCAT(\x27Profile_\x27,\x20(SELECT\x20(@cnt\x20:=\x20@cnt\x20+\x201)\x20AS\x20rowNumber','info','\x20\x20SET\x20sectionId\x20=\x201801\x20WHERE\x20sectionId\x20between\x2088889\x20AND\x2099999;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201010\x20THEN\x20\x27Triggers\x27','\x20\x20SELECT\x20x.sectionId,\x20u.MailAccountId,\x20x.userId','\x20\x20\x20\x20userId\x20text,','util','UPDATE\x20tmpSections\x20s','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20203\x20THEN\x20\x27Telephones\x27','removeIndex','\x20\x20`sectionId`\x20int(11)\x20NOT\x20NULL,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1401,\x201402,\x201403,\x201404,\x201405,\x201406,\x201407)\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x201501\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20voice_queues\x20WHERE\x20id\x20=\x20x.resourceId\x20AND\x20type\x20=\x20\x27outbound\x27),\x27DELETE_MIGRATION\x27)','\x20\x20\x20\x20\x20\x20\x20\x20fp.profileId\x20profileId,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20position(\x27,\x27\x20in\x20b.users)\x20=\x200))','\x20\x20INNER\x20JOIN\x20user_has_voice_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20407\x20THEN\x20\x27MusicOnHolds\x27','INSERT\x20INTO\x20tmpNormalizedUsers','INSERT\x20INTO\x20tmpFinalProfiles','\x20\x20\x20\x20\x20\x20\x20\x20ELSE\x20\x27\x27','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20902\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20fax_accounts\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20SELECT\x20name,\x20category,\x20sectionId,\x20enabled,\x20autoAssociation,\x20\x27red\x27,\x20now(),\x20now(),\x20userProfileId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201009\x20THEN\x20\x27Templates\x27','CREATE\x20TABLE\x20`user_profiles`\x20(','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(401,\x20402,\x20403,\x20404,\x20405,\x20406,\x20407,\x20408,\x20409,\x20410,\x20411)\x20THEN\x20\x27Voice\x27','\x20\x20s.sectionId\x20permission,','\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(s.userId,\x20\x27,\x27,\x20t.n),\x20\x27,\x27,\x20-1)\x20userId','\x20\x20INNER\x20JOIN\x20user_has_sms_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20SELECT\x20x.sectionId,\x20u.OpenchannelAccountId,\x20x.userId','\x20\x20SELECT\x20x.sectionId,\x20u.ChatWebsiteId,\x20x.userId','\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,','\x20\x20\x20\x20name\x20varchar(255)\x20not\x20null,','\x20\x20UNIQUE\x20KEY\x20`name`\x20(`name`)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201005\x20THEN\x20\x27Pauses\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201601\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20CASE','\x20\x20WHERE\x20userId\x20NOT\x20IN\x20(SELECT\x20split.userId'];(function(_0x17a008,_0x4614f5){const _0x54f5d2=function(_0x278294){while(--_0x278294){_0x17a008['push'](_0x17a008['shift']());}};_0x54f5d2(++_0x4614f5);}(a964_0x4614,0xb6));const a964_0x54f5=function(_0x17a008,_0x4614f5){_0x17a008=_0x17a008-0x0;let _0x54f5d2=a964_0x4614[_0x17a008];return _0x54f5d2;};const _0x414caf=a964_0x54f5;'use strict';const util=require(_0x414caf('0x96')),logger=require(_0x414caf('0x13c'))(_0x414caf('0xdc')),Sequence=function(){};Sequence[_0x414caf('0x53')]['enqueue']=function(_0x278294){const _0x50f46b=_0x414caf;this[_0x50f46b('0x16')]=this[_0x50f46b('0x16')]?this[_0x50f46b('0x16')][_0x50f46b('0x52')](_0x278294):_0x278294();};const Migration=function(_0x26a4c2){this['queryInterface']=_0x26a4c2,this['sequence']=new Sequence();};Migration['prototype'][_0x414caf('0x14a')]=function(_0x4c906e,_0x17faf9,_0x4c5dd5){const _0x51c8eb=_0x414caf,_0x773bf9=this;this[_0x51c8eb('0x16a')][_0x51c8eb('0x7d')](function(){const _0xe8029e=_0x51c8eb;return _0x773bf9['queryInterface'][_0xe8029e('0x14a')](_0x4c906e,_0x17faf9,_0x4c5dd5)[_0xe8029e('0x126')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x17faf9,_0x4c906e);})['catch'](function(_0x13f009){const _0x494ad7=_0xe8029e;logger[_0x494ad7('0x91')](JSON[_0x494ad7('0x1b')](_0x13f009));});});},Migration['prototype']['addColumn']=function(_0x57bebc,_0x131476,_0x4404a9){const _0x2ea84f=_0x414caf,_0x5b7ecd=this;this[_0x2ea84f('0x16a')][_0x2ea84f('0x7d')](function(){const _0x5257b6=_0x2ea84f;return _0x5b7ecd['queryInterface'][_0x5257b6('0x155')](_0x57bebc,_0x131476,_0x4404a9)[_0x5257b6('0x126')](function(){const _0x233abd=_0x5257b6;logger[_0x233abd('0x91')]('Added\x20column\x20%s\x20to\x20%s',_0x131476,_0x57bebc);})[_0x5257b6('0x3c')](function(_0x2334ea){logger['info'](JSON['stringify'](_0x2334ea));});});},Migration[_0x414caf('0x53')][_0x414caf('0x12f')]=function(_0x517802){const _0x11db5d=_0x414caf,_0x2e7b4f=this;this[_0x11db5d('0x16a')][_0x11db5d('0x7d')](function(){const _0x5b45f9=_0x11db5d;return _0x2e7b4f['queryInterface'][_0x5b45f9('0x12f')](_0x517802,{'force':!![]})[_0x5b45f9('0x126')](function(){const _0x406ba7=_0x5b45f9;logger['info'](_0x406ba7('0x157'),_0x517802);})[_0x5b45f9('0x3c')](function(_0x211fcc){const _0x3a25e6=_0x5b45f9;logger[_0x3a25e6('0x91')](JSON['stringify'](_0x211fcc));});});},Migration[_0x414caf('0x53')][_0x414caf('0xc3')]=function(_0xfa2b18,_0x742c58,_0x1085c5){const _0x556abc=_0x414caf,_0x36e749=this;this[_0x556abc('0x16a')][_0x556abc('0x7d')](function(){const _0x2ab522=_0x556abc;return _0x36e749[_0x2ab522('0xc0')][_0x2ab522('0xc3')](_0xfa2b18,_0x742c58,{'indexName':_0x1085c5})[_0x2ab522('0x126')](function(){const _0x1db5a1=_0x2ab522;logger[_0x1db5a1('0x91')](_0x1db5a1('0x119'),_0xfa2b18,_0x742c58[_0x1db5a1('0x116')](','),_0x1085c5);})['catch'](function(_0x1be948){const _0x51b285=_0x2ab522;logger[_0x51b285('0x91')](JSON[_0x51b285('0x1b')](_0x1be948));});});},Migration[_0x414caf('0x53')][_0x414caf('0x99')]=function(_0x4c480c,_0x122509){const _0x46bd65=_0x414caf,_0x2be8e5=this;this[_0x46bd65('0x16a')]['enqueue'](function(){const _0x1c732e=_0x46bd65;return _0x2be8e5[_0x1c732e('0xc0')]['removeIndex'](_0x4c480c,_0x122509)[_0x1c732e('0x126')](function(){const _0x1ef3df=_0x1c732e;logger[_0x1ef3df('0x91')](_0x1ef3df('0x134'),_0x4c480c,_0x122509);})['catch'](function(_0x3880b0){const _0x36b299=_0x1c732e;logger[_0x36b299('0x91')](JSON[_0x36b299('0x1b')](_0x3880b0));});});},Migration['prototype']['query']=function(_0x3b7cc0){const _0xccae9c=this;this['sequence']['enqueue'](function(){const _0x2ef537=a964_0x54f5;return _0xccae9c[_0x2ef537('0xc0')][_0x2ef537('0x4a')][_0x2ef537('0xf1')](_0x3b7cc0)['then'](function(){const _0x347f9e=_0x2ef537;logger[_0x347f9e('0x91')](_0x347f9e('0x87'),_0x3b7cc0);})[_0x2ef537('0x3c')](function(_0x47c316){const _0x4c0f74=_0x2ef537;logger[_0x4c0f74('0x91')](JSON[_0x4c0f74('0x1b')](_0x47c316));});});},Migration[_0x414caf('0x53')]['removeColumn']=function(_0x127710,_0x30f544){const _0x42ba9e=_0x414caf,_0x464435=this;this[_0x42ba9e('0x16a')]['enqueue'](function(){const _0x4e3471=_0x42ba9e;return _0x464435['queryInterface'][_0x4e3471('0xe9')](_0x127710,_0x30f544)['then'](function(){const _0x210c03=_0x4e3471;logger[_0x210c03('0x91')](_0x210c03('0x102'),_0x30f544,_0x127710);})[_0x4e3471('0x3c')](function(_0x1463da){const _0x902225=_0x4e3471;logger['info'](util[_0x902225('0x24')](_0x1463da,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x414caf('0x162')]=function(_0x9edaf1,_0x719cca,_0x501ecf){const _0x58c93b=_0x414caf,_0x2563eb=this;this['sequence'][_0x58c93b('0x7d')](function(){const _0x5c9933=_0x58c93b;return _0x2563eb[_0x5c9933('0xc0')][_0x5c9933('0x162')](_0x9edaf1,_0x719cca,_0x501ecf)['then'](function(){const _0x353495=_0x5c9933;logger[_0x353495('0x91')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x719cca,_0x501ecf,_0x9edaf1);})[_0x5c9933('0x3c')](function(_0x125a24){const _0x333c51=_0x5c9933;logger[_0x333c51('0x91')](util[_0x333c51('0x24')](_0x125a24,{'showHidden':![],'depth':null}));});});},Migration[_0x414caf('0x53')][_0x414caf('0x84')]=function(_0x2c3193){const _0x35cf06=_0x414caf;this[_0x35cf06('0x16a')]['enqueue'](function(){return _0x2c3193();});},module[_0x414caf('0x147')]={'up':function(_0x49f8f0,_0x285a00){return new Promise(function(_0x5e6e02){const _0x22db78=a964_0x54f5,_0x4e43a1=new Migration(_0x49f8f0);_0x4e43a1[_0x22db78('0x155')](_0x22db78('0xda'),'reportId',{'type':_0x285a00[_0x22db78('0x4')]}),_0x4e43a1['addColumn'](_0x22db78('0xda'),_0x22db78('0xf6'),{'type':_0x285a00['STRING']}),_0x4e43a1['addColumn'](_0x22db78('0x130'),_0x22db78('0xb6'),{'type':_0x285a00[_0x22db78('0x4')]}),_0x4e43a1[_0x22db78('0xe9')]('voice_voicemail',_0x22db78('0x105')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xa7')+'\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,'+_0x22db78('0xf3')+_0x22db78('0x149')+_0x22db78('0x135')+'\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,'+_0x22db78('0xd')+_0x22db78('0x47')+_0x22db78('0xb0')+_0x22db78('0x10b')),_0x4e43a1[_0x22db78('0xf1')]('INSERT\x20INTO\x20`user_profiles`\x20(`name`,\x20`crudPermissions`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)'+_0x22db78('0xb7')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xe2')+_0x22db78('0x71')+'FOREIGN\x20KEY\x20(`userProfileId`)\x20'+_0x22db78('0x110')+'ON\x20UPDATE\x20CASCADE'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xd8')+'\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,'+_0x22db78('0xf3')+'\x20\x20`category`\x20varchar(255)\x20NOT\x20NULL,'+_0x22db78('0x9a')+_0x22db78('0xc')+'\x20\x20`autoAssociation`\x20tinyint(1)\x20DEFAULT\x20NULL,'+_0x22db78('0x61')+_0x22db78('0xae')+_0x22db78('0xd')+_0x22db78('0x168')+_0x22db78('0x47')+_0x22db78('0x122')+_0x22db78('0x58')+'\x20\x20CONSTRAINT\x20`user_profile_has_sections_ibfk_1`\x20FOREIGN\x20KEY\x20(`userProfileId`)\x20REFERENCES\x20`user_profiles`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE'+_0x22db78('0x10b')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x12c')+_0x22db78('0x17')+_0x22db78('0xf3')+_0x22db78('0x13a')+_0x22db78('0x5b')+_0x22db78('0xae')+_0x22db78('0xd')+_0x22db78('0x8f')+_0x22db78('0x47')+_0x22db78('0x66')+'\x20\x20KEY\x20`compositeIndex`\x20(`resourceId`,`sectionId`),'+_0x22db78('0x159')+_0x22db78('0x10b')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xe4')+_0x22db78('0x33')+');'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xb')+_0x22db78('0x10e')+_0x22db78('0x67')+_0x22db78('0x8e')+',(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20c'+_0x22db78('0xf2')+',(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20e'+';'),_0x4e43a1['query'](_0x22db78('0x6d')+_0x22db78('0x136')+_0x22db78('0x3f')+_0x22db78('0x0')+_0x22db78('0x11d')+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xf4')+_0x22db78('0x143')+_0x22db78('0x13b')+_0x22db78('0x88')+_0x22db78('0xbf')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xc6')+_0x22db78('0x136')+'\x20\x20\x20\x20sectionId\x20int(11)\x20not\x20null,'+_0x22db78('0x95')+_0x22db78('0x145')+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xc2')+'\x20\x20SELECT\x20DISTINCT\x20permission,\x20userId,\x200'+_0x22db78('0xc1')+_0x22db78('0xba')+'\x20\x20\x20\x20p.userIds\x20userId'+_0x22db78('0x4b')+_0x22db78('0x131')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x38')+_0x22db78('0x136')+'\x20\x20\x20\x20permissions\x20text\x20not\x20null,'+_0x22db78('0x163')+'\x20\x20);'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x15a')+_0x22db78('0x1e')+'\x20\x20FROM\x20tmpNormalizedSections'+'\x20\x20GROUP\x20BY\x20userId;'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x55')+'\x20\x20SET\x20u.permissions\x20=\x20t.permissions'+_0x22db78('0x2d')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x59')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xf4')+_0x22db78('0x23')+_0x22db78('0x13b')+_0x22db78('0x88')+_0x22db78('0x146')+_0x22db78('0x108')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x154')+_0x22db78('0x136')+_0x22db78('0xcd')+_0x22db78('0x95')+_0x22db78('0x145')+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xa1')+_0x22db78('0x7e')+_0x22db78('0xc1')+_0x22db78('0xa9')+_0x22db78('0xaa')+_0x22db78('0xe0')+'\x20\x20ORDER\x20BY\x20n)\x20AS\x20split;'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x11e')+_0x22db78('0x86')+_0x22db78('0x12a')+_0x22db78('0xc8')+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x1')+_0x22db78('0x45')+'\x20\x20FROM\x20tmpNormalizedUsers\x20x'+'\x20\x20INNER\x20JOIN\x20user_has_voice_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId'+_0x22db78('0x5d')+'\x20\x20WHERE\x20x.sectionId\x20=\x20401\x20AND\x20q.type\x20=\x20\x27inbound\x27;'),_0x4e43a1[_0x22db78('0xf1')]('INSERT\x20INTO\x20tmpExtractedResources'+_0x22db78('0x125')+_0x22db78('0x133')+_0x22db78('0x26')+'\x20\x20WHERE\x20x.sectionId\x20=\x20501;'),_0x4e43a1['query'](_0x22db78('0x1')+_0x22db78('0xad')+_0x22db78('0x133')+_0x22db78('0x4d')+_0x22db78('0x100')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x1')+_0x22db78('0x12b')+_0x22db78('0x133')+_0x22db78('0x15d')+_0x22db78('0x117')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x1')+_0x22db78('0x94')+_0x22db78('0x133')+'\x20\x20INNER\x20JOIN\x20user_has_mail_accounts\x20u\x20ON\x20u.UserId\x20=\x20x.userId'+'\x20\x20WHERE\x20x.sectionId\x20=\x20602;'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x1')+_0x22db78('0x109')+_0x22db78('0x133')+_0x22db78('0xab')+'\x20\x20WHERE\x20x.sectionId\x20=\x20701;'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x1')+_0x22db78('0x14f')+_0x22db78('0x133')+_0x22db78('0x129')+'\x20\x20WHERE\x20x.sectionId\x20=\x20702;'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x1')+_0x22db78('0x8a')+_0x22db78('0x133')+_0x22db78('0x137')+'\x20\x20WHERE\x20x.sectionId\x20=\x20801;'),_0x4e43a1['query'](_0x22db78('0x1')+_0x22db78('0xac')+_0x22db78('0x133')+_0x22db78('0xb9')+_0x22db78('0x150')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x1')+_0x22db78('0x165')+'\x20\x20FROM\x20tmpNormalizedUsers\x20x'+'\x20\x20INNER\x20JOIN\x20user_has_fax_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId'+_0x22db78('0x1a')),_0x4e43a1[_0x22db78('0xf1')]('INSERT\x20INTO\x20tmpExtractedResources'+_0x22db78('0x6')+_0x22db78('0x133')+_0x22db78('0x69')+_0x22db78('0xd4')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x1')+_0x22db78('0xbd')+_0x22db78('0x133')+'\x20\x20INNER\x20JOIN\x20user_has_square_projects\x20u\x20ON\x20u.UserId\x20=\x20x.userId'+_0x22db78('0x169')),_0x4e43a1[_0x22db78('0xf1')]('INSERT\x20INTO\x20tmpExtractedResources'+'\x20\x20SELECT\x20x.sectionId,\x20u.VoiceQueueId,\x20x.userId'+_0x22db78('0x133')+_0x22db78('0x9f')+_0x22db78('0x5d')+'\x20\x20WHERE\x20x.sectionId\x20=\x201501\x20AND\x20q.type\x20=\x20\x27outbound\x27;'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x1d')+_0x22db78('0x136')+_0x22db78('0x144')+_0x22db78('0xbb')+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x6b')+'\x20\x20SELECT\x20userId,\x20permissions'+_0x22db78('0xc1')+_0x22db78('0x164')+_0x22db78('0xbe')+_0x22db78('0xd2')+_0x22db78('0x131')),_0x4e43a1[_0x22db78('0xf1')]('CREATE\x20TABLE\x20tmpSharedProfiles'+'\x20\x20('+_0x22db78('0x3f')+_0x22db78('0x0')+_0x22db78('0x11d')+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xc7')+'\x20\x20SELECT\x20GROUP_CONCAT(userId),\x20permissions,\x20null'+_0x22db78('0x35')+_0x22db78('0xb4')+_0x22db78('0x10d')+_0x22db78('0x76')+_0x22db78('0x3')+_0x22db78('0x9')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20POSITION(\x27,\x27\x20in\x20r.userIds)\x20>\x200'+_0x22db78('0x160')+'\x20\x20WHERE\x20split.userId\x20IN\x20(SELECT\x20*\x20FROM'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(SELECT\x20GROUP_CONCAT(userId\x20ORDER\x20BY\x20userId\x20ASC)\x20AS\x20users'+_0x22db78('0x5a')+_0x22db78('0xf')+_0x22db78('0x6c')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20position(\x27,\x27\x20in\x20b.users)\x20=\x200))'+_0x22db78('0x146')+'\x20\x20ORDER\x20BY\x20GROUP_CONCAT(userId);'),_0x4e43a1['query']('CREATE\x20TABLE\x20tmpSingleProfiles'+_0x22db78('0x136')+_0x22db78('0x144')+_0x22db78('0x0')+_0x22db78('0x11d')+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')]('INSERT\x20INTO\x20tmpSingleProfiles'+_0x22db78('0x127')+_0x22db78('0x35')+'\x20\x20WHERE\x20userId\x20IN\x20(SELECT\x20split.userId'+_0x22db78('0xe7')+_0x22db78('0xdb')+_0x22db78('0x18')+_0x22db78('0x65')+_0x22db78('0xe')+_0x22db78('0x3a')+_0x22db78('0xe1')+_0x22db78('0xca')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20users)\x20b'+_0x22db78('0x9e')+_0x22db78('0x104')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xe6')+_0x22db78('0x136')+'\x20\x20\x20\x20\x20\x20userId\x20text\x20not\x20null,'+_0x22db78('0x0')+_0x22db78('0x11d')+_0x22db78('0x107')),_0x4e43a1['query'](_0x22db78('0xa2')+'\x20\x20SELECT\x20*\x20FROM\x20tmpSharedProfiles'+_0x22db78('0x2c')+_0x22db78('0xb5')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x42')+_0x22db78('0x90')+_0x22db78('0xe3')+_0x22db78('0xbc')+_0x22db78('0x41')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xcb')+_0x22db78('0x112')+_0x22db78('0x139')+_0x22db78('0x4f')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x124')+_0x22db78('0x136')+_0x22db78('0xaf')+_0x22db78('0x167')+_0x22db78('0xcd')+_0x22db78('0x31')+_0x22db78('0x2f')+'\x20\x20\x20\x20userProfileId\x20int(11)\x20not\x20null,'+_0x22db78('0xc4')+'\x20\x20\x20\x20userId\x20text'+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x64')+_0x22db78('0x51')+_0x22db78('0xc1')+_0x22db78('0x9d')+'\x20\x20\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(fp.permissions,\x20\x27,\x27,\x20tally.n),\x20\x27,\x27,\x20-1)\x20permission,'+_0x22db78('0x15c')+_0x22db78('0x14b')+_0x22db78('0x12')+_0x22db78('0x81')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x148')+'\x20\x20SET'+_0x22db78('0x19')+_0x22db78('0x44')+_0x22db78('0xd0')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20101\x20THEN\x20\x27DELETE\x27'+_0x22db78('0x50')+_0x22db78('0x11')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20202\x20THEN\x20\x27Agents\x27'+_0x22db78('0x98')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20204\x20THEN\x20\x27Teams\x27'+_0x22db78('0x10a')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20301\x20THEN\x20\x27Lists\x27'+_0x22db78('0x158')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20303\x20THEN\x20\x27Contacts\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20304\x20THEN\x20\x27GlobalCustomFields\x27'+_0x22db78('0x27')+_0x22db78('0x74')+_0x22db78('0x56')+_0x22db78('0x12d')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20404\x20THEN\x20\x27InternalRoutes\x27'+_0x22db78('0x13')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20406\x20THEN\x20\x27Voicemails\x27'+_0x22db78('0xa0')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20408\x20THEN\x20\x27VoiceRecordings\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20409\x20THEN\x20\x27ChanSpies\x27'+_0x22db78('0xfc')+_0x22db78('0xfe')+_0x22db78('0x2e')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20501\x20THEN\x20\x27ChatQueues\x27'+_0x22db78('0xf5')+_0x22db78('0x15f')+_0x22db78('0xd1')+_0x22db78('0xd5')+_0x22db78('0x22')+_0x22db78('0x82')+_0x22db78('0xea')+_0x22db78('0xd9')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20701\x20THEN\x20\x27SmsQueues\x27'+_0x22db78('0x10')+_0x22db78('0x106')+_0x22db78('0xce')+_0x22db78('0x118')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20802\x20THEN\x20\x27OpenchannelAccounts\x27'+_0x22db78('0x156')+_0x22db78('0x79')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20901\x20THEN\x20\x27FaxQueues\x27'+_0x22db78('0xd7')+_0x22db78('0x120')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201000\x20THEN\x20\x27DELETE\x27'+_0x22db78('0x36')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201002\x20THEN\x20\x27Dispositions\x27'+_0x22db78('0xee')+_0x22db78('0x115')+_0x22db78('0xb1')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201006\x20THEN\x20\x27Scheduler\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201007\x20THEN\x20\x27Sounds\x27'+_0x22db78('0x1c')+_0x22db78('0xa6')+_0x22db78('0x93')+_0x22db78('0x85')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201012\x20THEN\x20\x27Variables\x27'+_0x22db78('0x153')+_0x22db78('0x46')+_0x22db78('0x14d')+_0x22db78('0xcc')+_0x22db78('0x114')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201201\x20THEN\x20\x27Metrics\x27'+_0x22db78('0x48')+_0x22db78('0x101')+_0x22db78('0x7f')+_0x22db78('0x11b')+_0x22db78('0xde')+_0x22db78('0x57')+_0x22db78('0xeb')+_0x22db78('0x166')+_0x22db78('0x132')+_0x22db78('0x5c')+_0x22db78('0x15b')+_0x22db78('0x9b')+_0x22db78('0x83')+_0x22db78('0x80')+_0x22db78('0x54')+_0x22db78('0xfa')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201600\x20THEN\x20\x27Help\x27'+_0x22db78('0xb2')+_0x22db78('0x1f')+_0x22db78('0xf7')+_0x22db78('0xcf')+_0x22db78('0x13d')+_0x22db78('0x152')+_0x22db78('0x20')+_0x22db78('0xe5')+_0x22db78('0x151')+_0x22db78('0xb3')+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20100\x20THEN\x20\x27Dashboards\x27'+_0x22db78('0x14')+_0x22db78('0x43')+_0x22db78('0x73')+_0x22db78('0xa8')+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(501,\x20502,\x20510)\x20THEN\x20\x27Chat\x27'+_0x22db78('0xf0')+_0x22db78('0xed')+_0x22db78('0x10f')+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(901,\x20902,\x20910)\x20THEN\x20\x27Fax\x27'+_0x22db78('0x3d')+_0x22db78('0x15')+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1201,\x201202,\x201203)\x20THEN\x20\x27Analytics\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1301,\x201302,\x201303,\x201305,\x201306,\x201307,\x201308)\x20THEN\x20\x27Integrations\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201400\x20THEN\x20\x27Settings\x27'+_0x22db78('0x3e')+_0x22db78('0xc5')+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201701\x20THEN\x20\x27jscripty\x27'+_0x22db78('0x63')+_0x22db78('0xa3')+_0x22db78('0x13f')+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x113')+_0x22db78('0x89')),_0x4e43a1['query'](_0x22db78('0xd3')+_0x22db78('0x136')+_0x22db78('0xaf')+_0x22db78('0x167')+'\x20\x20\x20\x20sectionId\x20int(11)\x20not\x20null,'+'\x20\x20\x20\x20enabled\x20tinyint\x20not\x20null,'+_0x22db78('0x2f')+_0x22db78('0x37')+'\x20\x20\x20\x20insertedId\x20int(11),'+_0x22db78('0x68')+_0x22db78('0x107')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xfb')+_0x22db78('0x25')+_0x22db78('0xdd')+_0x22db78('0xd6')),_0x4e43a1[_0x22db78('0xf1')]('DELETE\x20t1\x20FROM\x20tmpSections\x20t1,\x20tmpCustomResources\x20t2'+_0x22db78('0x2a')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x148')+_0x22db78('0x92')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x148')+_0x22db78('0x32')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x148')+_0x22db78('0x6f')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xef')+_0x22db78('0xff')+_0x22db78('0x4c')+_0x22db78('0x8d')+_0x22db78('0x11a')+_0x22db78('0x12e')+_0x22db78('0x8b')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x49')+_0x22db78('0xa5')+_0x22db78('0x75')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x97')+_0x22db78('0x111')+_0x22db78('0x3b')+_0x22db78('0x5f')),_0x4e43a1[_0x22db78('0xf1')]('UPDATE\x20tmpCustomResources\x20r,\x20tmpSections\x20s'+'\x20\x20SET\x20r.sectionId\x20=\x20s.insertedId'+_0x22db78('0xe8')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x8c')+'\x20\x20('+_0x22db78('0x14c')+_0x22db78('0x70')+'\x20\x20\x20\x20\x20\x20insertedSectionId\x20int(11)\x20not\x20null,'+_0x22db78('0x138')+'\x20\x20);'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x140')+'\x20\x20SELECT\x20cr.resourceId,\x20name,\x20s.insertedId,\x20s.sectionId'+_0x22db78('0xf9')+_0x22db78('0x103')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x62')+_0x22db78('0x136')+_0x22db78('0xaf')+_0x22db78('0x34')+_0x22db78('0x123')+'\x20\x20\x20\x20insertedSectionId\x20int(11)\x20not\x20null,'+_0x22db78('0x2')+_0x22db78('0x107')),_0x4e43a1['query'](_0x22db78('0x161')+_0x22db78('0x141')+_0x22db78('0xc1')+_0x22db78('0x7b')+_0x22db78('0x77')+_0x22db78('0x29')+_0x22db78('0x14e')+_0x22db78('0x14b')+_0x22db78('0x11c')+'\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20n)\x20AS\x20split;'),_0x4e43a1[_0x22db78('0xf1')]('INSERT\x20INTO\x20tmpNormalizedResources'+_0x22db78('0x40')+_0x22db78('0xa')),_0x4e43a1['query'](_0x22db78('0xec')+_0x22db78('0x28')+_0x22db78('0xc9')+_0x22db78('0x5')+'\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20501\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20chat_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+_0x22db78('0x10c')+_0x22db78('0x39')+_0x22db78('0x7')+_0x22db78('0xb8')+'\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20702\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20sms_accounts\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+'\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20801\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20openchannel_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+'\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20802\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20openchannel_accounts\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+_0x22db78('0xf8')+_0x22db78('0xa4')+_0x22db78('0x128')+_0x22db78('0x9c')+_0x22db78('0x121')+'\x20\x20\x20\x20\x20\x20WHEN\x20x.type\x20=\x20\x27CustomDashboards\x27\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20dashboards\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+_0x22db78('0xfd')+_0x22db78('0x2b')),_0x4e43a1['query']('DELETE\x20FROM\x20tmpNormalizedResources'+_0x22db78('0x13e')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x60')+'\x20\x20SELECT\x20name,\x20resourceId,\x20type,\x20now(),\x20now(),\x20insertedSectionId'+_0x22db78('0x7c')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0xdf')+_0x22db78('0x5e')+_0x22db78('0x4e')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x72')+_0x22db78('0x6e')+_0x22db78('0x142')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x78')),_0x4e43a1['query'](_0x22db78('0x30')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x21')),_0x4e43a1[_0x22db78('0xf1')]('DROP\x20TABLE\x20IF\x20EXISTS\x20tmpNormalizedUsers;'),_0x4e43a1[_0x22db78('0xf1')]('DROP\x20TABLE\x20IF\x20EXISTS\x20tmpExtractedResources;'),_0x4e43a1[_0x22db78('0xf1')]('DROP\x20TABLE\x20IF\x20EXISTS\x20tmpGroupedPermissions;'),_0x4e43a1[_0x22db78('0xf1')]('DROP\x20TABLE\x20IF\x20EXISTS\x20tmpSharedProfiles;'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x8')),_0x4e43a1['query'](_0x22db78('0x6a')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x11f')),_0x4e43a1[_0x22db78('0xf1')]('DROP\x20TABLE\x20IF\x20EXISTS\x20tmpCustomResources;'),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x7a')),_0x4e43a1[_0x22db78('0xf1')](_0x22db78('0x15e')),_0x4e43a1[_0x22db78('0x84')](_0x5e6e02);});},'down':function(){}}; \ No newline at end of file +const a964_0x2f6f=['stringify','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201601\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tally\x20t','\x20\x20WHERE\x20x.sectionId\x20=\x20502;','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1301,\x201302,\x201303,\x201305,\x201306,\x201307,\x201308)\x20THEN\x20\x27Integrations\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20),','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20410\x20THEN\x20\x27VoicePrefixes\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tmpNormalizedUsers','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20position(\x27,\x27\x20in\x20b.users)\x20=\x200))','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20408\x20THEN\x20\x27VoiceRecordings\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20END','\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(t.userIds,\x20\x27,\x27,\x20tally.n),\x20\x27,\x27,\x20-1)\x20userId,','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpSingleProfiles;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201302\x20THEN\x20\x27SalesforceAccounts\x27','info','\x20\x20INNER\x20JOIN\x20voice_queues\x20q\x20ON\x20u.VoiceQueueId\x20=\x20q.id','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20602\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20mail_accounts\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20101\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20400\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20>=\x20100000\x20THEN\x20\x27CustomDashboards\x27','\x20\x20SELECT\x20name,\x20resourceId,\x20type,\x20now(),\x20now(),\x20insertedSectionId','\x20\x20SELECT\x20x.sectionId,\x20u.FaxQueueId,\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201501\x20THEN\x20\x27QueueCampaigns\x27','\x20\x20\x20\x20userId\x20text,','\x20\x20`type`\x20varchar(255)\x20NOT\x20NULL,','\x20\x20WHERE\x20name\x20=\x20\x27DELETE_MIGRATION\x27;','ALTER\x20TABLE\x20`users`\x20','\x20\x20FROM\x20users','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20name\x20=\x20\x27CustomDashboards\x27\x20THEN\x20(sectionId\x20-\x2099999)','\x20\x20KEY\x20`compositeIndex`\x20(`resourceId`,`sectionId`),','\x20\x20sectionId\x20int(11)\x20not\x20null,','ON\x20UPDATE\x20CASCADE','\x20\x20CROSS\x20JOIN\x20(SELECT\x20@cnt\x20:=\x200)\x20as\x20dummy\x20LIMIT\x201)),\x20\x27red\x27,\x20now(),\x20now()','\x20\x20FROM\x20tmpSections\x20s','\x20\x20\x20\x20userId\x20int(11)\x20not\x20null','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20502\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20chat_websites\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20500\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20401\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20voice_queues\x20WHERE\x20id\x20=\x20x.resourceId\x20AND\x20type\x20=\x20\x27inbound\x27),\x27DELETE_MIGRATION\x27)','CREATE\x20TABLE\x20tmpExtractedResources\x20(','\x20\x20\x20\x20\x20\x20profileId\x20int(11)','\x20\x20SELECT\x20DISTINCT\x20permission,\x20userId,\x200','\x20\x20SELECT\x20CONCAT(\x27Profile_\x27,\x20(SELECT\x20(@cnt\x20:=\x20@cnt\x20+\x201)\x20AS\x20rowNumber','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(r.userIds,\x20\x27,\x27,\x20t.n),\x20\x27,\x27,\x20-1)\x20userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20810\x20THEN\x20\x27Realtime\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20n)\x20as\x20split','\x20\x20SET\x20name\x20=\x20(SELECT','\x20\x20\x20\x20\x20\x20\x20\x20ELSE\x20\x27\x27','CREATE\x20TABLE\x20tmpNormalizedPermissions','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201100\x20THEN\x20\x27DELETE\x27','\x20\x20SET\x20insertedId\x20=\x20(SELECT','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20303\x20THEN\x20\x27Contacts\x27','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20701\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20sms_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','Changed\x20column\x20%s\x20in\x20table\x20%s','then','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201007\x20THEN\x20\x27Sounds\x27','\x20\x20SELECT\x20x.sectionId,\x20u.SmsQueueId,\x20x.userId','CREATE\x20TABLE\x20tmpSharedProfiles','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20900\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20userId\x20text\x20not\x20null,','CREATE\x20TABLE\x20tmpResources','\x20\x20FROM\x20tmpNormalizedUsers\x20x','DELETE\x20t1\x20FROM\x20tmpSections\x20t1,\x20tmpCustomResources\x20t2','addColumn','prototype','\x20\x20\x20\x20\x20\x20sectionId\x20int(11)','\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20n)\x20AS\x20split;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201308\x20THEN\x20\x27VtigerAccounts\x27','util','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpNormalizedUsers;','queryInterface','\x20\x20`name`\x20varchar(255)\x20NOT\x20NULL,','Removed\x20column\x20%s\x20from\x20%s','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201006\x20THEN\x20\x27Scheduler\x27','\x20\x20`crudPermissions`\x20varchar(255)\x20NOT\x20NULL\x20DEFAULT\x20\x27r\x27,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20602\x20THEN\x20\x27MailAccounts\x27','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201600\x20THEN\x20\x27Help\x27','changeColumn','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20702\x20THEN\x20\x27SmsAccounts\x27','\x20\x20\x20\x20\x20\x20WHEN\x20x.type\x20=\x20\x27Plugins\x27\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20plugins\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20);','removeIndex','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20END',',(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20c','REFERENCES\x20user_profiles(`id`)\x20','\x20\x20FROM\x20tmpGroupedPermissions','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201510\x20THEN\x20\x27Realtime\x27','reportType','sequelize','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20INNER\x20JOIN\x20tmpPermissions\x20r\x20on\x20CHAR_LENGTH(r.userIds)\x20-\x20CHAR_LENGTH(REPLACE(r.userIds,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20t.n-1','INSERT\x20INTO\x20tmpNormalizedPermissions','migration','\x20\x20SELECT\x20permission,\x20userId,\x200','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201400\x20THEN\x20\x27Settings\x27','UPDATE\x20tmpNormalizedResources\x20x','\x20\x20CONSTRAINT\x20`user_profile_has_sections_ibfk_1`\x20FOREIGN\x20KEY\x20(`userProfileId`)\x20REFERENCES\x20`user_profiles`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE','\x20\x20WHERE\x20x.sectionId\x20=\x201501\x20AND\x20q.type\x20=\x20\x27outbound\x27;','\x20\x20KEY\x20`compositeIndex`\x20(`sectionId`,`userProfileId`),','\x20\x20\x20\x20enabled\x20tinyint\x20not\x20null,',',(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20e','addIndex\x20%s\x20%s\x20%s','\x20\x20FROM\x20tmpSections;','\x20\x20s.sectionId\x20permission,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20406\x20THEN\x20\x27Voicemails\x27','\x20\x20WHERE\x20split.userId\x20IN\x20(SELECT\x20*\x20FROM','\x20\x20\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(fp.permissions,\x20\x27,\x27,\x20tally.n),\x20\x27,\x27,\x20-1)\x20permission,','\x20\x20ORDER\x20BY\x20id;','CREATE\x20TABLE\x20tmpCustomResources','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20300\x20THEN\x20\x27DELETE\x27','\x20\x20WHERE\x20userId\x20IN\x20(SELECT\x20split.userId','\x20\x20\x20\x20\x20\x20userIds\x20varchar(255)\x20not\x20null,','\x20\x20SELECT\x20x.sectionId,\x20u.MailAccountId,\x20x.userId','name','\x20\x20SELECT\x20GROUP_CONCAT(userId),\x20permissions,\x20null','\x20\x20\x20\x20userProfileId\x20int(11)\x20not\x20null,','\x20\x20\x20\x20insertedId\x20int(11),','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(301,\x20302,\x20303,\x20304)\x20THEN\x20\x27ContactManager\x27','\x20\x20UNION','\x20\x20\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(r.resourceId,\x20\x27,\x27,\x20tally.n),\x20\x27,\x27,\x20-1)\x20resourceId,','\x20\x20FROM\x20(SELECT','\x20\x20\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(fp.userId,\x20\x27,\x27,\x201)\x20userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20603\x20THEN\x20\x27MailSubstatuses\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20401\x20THEN\x20\x27VoiceQueues\x27','INSERT\x20INTO\x20tally\x20(n)','renameColumn','\x20\x20(','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(202,\x20203,\x20204)\x20THEN\x20\x27Staff\x27','enqueue','userProfileId','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20901\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20fax_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpGroupedPermissions;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201306\x20THEN\x20\x27DeskAccounts\x27','\x20\x20`userProfileId`\x20int(11)\x20DEFAULT\x20NULL,','\x20\x20WHERE\x20name\x20=\x20\x27DELETE\x27;','voice_voicemail','\x20\x20SET','INSERT\x20INTO\x20tmpNormalizedResources','UPDATE\x20tmpSections',',(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20b','\x20\x20\x20\x20type\x20varchar(255)\x20not\x20null,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20);','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20POSITION(\x27,\x27\x20in\x20r.userIds)\x20>\x200','UPDATE\x20tmpCustomResources\x20r,\x20tmpSections\x20s','VALUES\x20(\x27Default\x27,\x20\x27red\x27,\x20NULL,\x20NOW(),\x20NOW());','INTEGER','\x20\x20SET\x20r.sectionId\x20=\x20s.insertedId','\x20\x20\x20\x20sectionId\x20int(11)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20users)\x20b','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201502\x20THEN\x20\x27IvrCampaigns\x27','\x20\x20\x20\x20resourceId\x20text','CREATE\x20TABLE\x20`user_profile_has_resources`\x20(','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20801\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20openchannel_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','addIndex','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CASE','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201300\x20THEN\x20\x27DELETE\x27','query\x20%s','\x20\x20WHERE\x20x.sectionId\x20=\x20901;','\x20\x20FROM\x20tmpSections','\x20\x20SELECT\x20\x27\x27,\x20insertedId,\x20name,\x20sectionId,\x20null','\x20\x20ORDER\x20BY\x20n)\x20AS\x20split;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20802\x20THEN\x20\x27OpenchannelAccounts\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20POSITION(\x27,\x27\x20in\x20r.userIds)\x20>\x200','\x20\x20KEY\x20`userProfileId`\x20(`userProfileId`),','\x20\x20\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(s.userId,\x20\x27,\x27,\x20t.n),\x20\x27,\x27,\x20-1)\x20userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201700\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20601\x20THEN\x20\x27MailQueues\x27','\x20\x20\x20\x20category\x20varchar(255)\x20not\x20null,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20411\x20THEN\x20\x27Realtime\x27','\x20\x20INNER\x20JOIN\x20user_has_fax_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201500\x20THEN\x20\x27DELETE\x27','\x20\x20PRIMARY\x20KEY\x20(`id`),','SELECT\x20NULL\x20FROM','catch','sequence','\x20\x20INNER\x20JOIN\x20user_has_chat_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId','CREATE\x20TABLE\x20`user_profiles`\x20(','INSERT\x20INTO\x20tmpExtractedResources','\x20\x20INNER\x20JOIN\x20user_has_sms_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId','query','UPDATE\x20tmpSections\x20s','\x20\x20\x20\x20name\x20varchar(255)\x20not\x20null,','\x20\x20userId\x20int(11)','INSERT\x20INTO\x20tmpSingleProfiles','\x20\x20GROUP\x20BY\x20userId;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20402\x20THEN\x20\x27InboundRoutes\x27','\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tally','TRUNCATE\x20TABLE\x20tmpPermissions;','\x20\x20SELECT\x20x.sectionId,\x20u.ChatWebsiteId,\x20x.userId','\x20\x20WHERE\x20u.id\x20=\x20f.userId;','\x20\x20INNER\x20JOIN\x20user_has_fax_accounts\x20u\x20ON\x20u.UserId\x20=\x20x.userId',')\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','\x20\x20SELECT\x20x.sectionId,\x20u.SquareProjectId,\x20x.userId','\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,','CREATE\x20TABLE\x20`user_profile_has_sections`\x20(','\x20\x20GROUP\x20BY\x20permissions','dropTable','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20);','\x20\x20WHERE\x20userProfileId\x20is\x20null\x20AND\x20role\x20=\x20\x27user\x27;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201005\x20THEN\x20\x27Pauses\x27','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(801,\x20802,\x20810)\x20THEN\x20\x27Openchannel\x27','\x20\x20\x20\x20\x20\x20permissions\x20text\x20not\x20null','CREATE\x20TABLE\x20tmpSections','INSERT\x20INTO\x20tmpSharedProfiles','tail','\x20\x20WHERE\x20x.sectionId\x20=\x20602;','INSERT\x20INTO\x20tmpCustomResources','\x20\x20SELECT\x20\x27\x27,\x20\x27\x27,\x20permission,\x201,\x200,\x20profileId,\x20null,\x20userId','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1501,\x201502,\x201510)\x20THEN\x20\x27MotionDialer\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20304\x20THEN\x20\x27GlobalCustomFields\x27','\x20\x20WHERE\x20t1.name\x20=\x20t2.name\x20AND\x20t1.userProfileId\x20=\x20t2.userProfileId\x20AND\x20t1.sectionId\x20>\x20t2.sectionId;','UPDATE\x20users\x20u,\x20tmpFinalProfiles\x20f','\x20\x20WHERE\x20userId\x20NOT\x20IN\x20(SELECT\x20split.userId','\x20\x20FROM\x20tmpNormalizedResources;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20(select\x20SUBSTRING_INDEX(SUBSTRING_INDEX(r.userIds,\x20\x27,\x27,\x20t.n),\x20\x27,\x27,\x20-1)\x20userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201009\x20THEN\x20\x27Templates\x27','\x20\x20\x20\x20\x20\x20insertedSectionId\x20int(11)\x20not\x20null,','inspect','\x20\x20SELECT\x20x.sectionId,\x20u.ChatQueueId,\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20201\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20710\x20THEN\x20\x27Realtime\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20902\x20THEN\x20\x27FaxAccounts\x27','\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20s.userProfileId\x20=\x20x.userProfileId\x20AND\x20s.sectionId\x20=\x20x.sectionId);','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20802\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20openchannel_accounts\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)','\x20\x20FROM\x20tmpCustomResources;','\x20\x20\x20\x20userId\x20text','CREATE\x20TABLE\x20tmpNormalizedResources','\x20\x20ORDER\x20BY\x20userId;','\x20\x20INNER\x20JOIN\x20user_has_voice_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20204\x20THEN\x20\x27Teams\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201203\x20THEN\x20\x27Reports\x27','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1201,\x201202,\x201203)\x20THEN\x20\x27Analytics\x27','\x20\x20\x20\x20\x20\x20resourceId\x20text,','\x20\x20SET\x20profileId\x20=\x20(SELECT\x20(@cnt\x20:=\x20@cnt\x20+\x201)\x20AS\x20rowNumber','\x20\x20SELECT\x20x.sectionId,\x20u.SmsAccountId,\x20x.userId','\x20\x20WHERE\x20role\x20=\x20\x27user\x27\x20and\x20permissions\x20is\x20not\x20null\x20and\x20permissions\x20<>\x20\x27\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201202\x20THEN\x20\x27ExtractedReports\x27','\x20\x20`category`\x20varchar(255)\x20NOT\x20NULL,','\x20\x20FROM\x20tally\x20INNER\x20JOIN\x20tmpPermissions\x20t\x20ON\x20CHAR_LENGTH(t.userIds)\x20-\x20CHAR_LENGTH(REPLACE(t.userIds,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20tally.n-1','CREATE\x20TABLE\x20tmpSingleProfiles','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201000\x20THEN\x20\x27DELETE\x27','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1001,\x201002,\x201003,\x201004,\x201005,\x201006,\x201007,\x201008,\x201009,\x201010,\x201011,\x201012)\x20THEN\x20\x27Tools\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201102\x20THEN\x20\x27SquareRecordings\x27','DELETE\x20FROM\x20tmpNormalizedResources','\x20\x20WHERE\x20r.name\x20=\x20s.name\x20AND\x20r.userProfileId\x20=\x20s.userProfileId;','\x20\x20CROSS\x20JOIN\x20(SELECT\x20@cnt\x20:=\x201)\x20as\x20dummy\x20LIMIT\x201)','\x20\x20FROM\x20tmpNormalizedSections','\x20\x20WHERE\x20u.id\x20=\x20t.userId;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHERE\x20position(\x27,\x27\x20in\x20b.users)\x20=\x200))','\x20\x20`sectionId`\x20int(11)\x20NOT\x20NULL,','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpNormalizedSections;','INSERT\x20INTO\x20user_profiles\x20(name,\x20crudPermissions,\x20createdAt,\x20updatedAt)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20404\x20THEN\x20\x27InternalRoutes\x27','\x20\x20INNER\x20JOIN\x20user_has_mail_accounts\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20ORDER\x20BY\x20GROUP_CONCAT(id);','UPDATE\x20users\x20u','\x20\x20SELECT\x20*\x20FROM\x20tmpSharedProfiles','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201011\x20THEN\x20\x27Trunks\x27','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpPermissions;','\x20\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201701\x20THEN\x20\x27Projects\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201400\x20THEN\x20\x27Settings\x27','\x20\x20`sectionId`\x20int(11)\x20DEFAULT\x20NULL,','\x20\x20WHERE\x20x.sectionId\x20=\x20701;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CASE','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpResources;','INSERT\x20INTO\x20tmpFinalProfiles','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20>=\x20100000\x20THEN\x20\x27Tools\x27','INSERT\x20INTO\x20`user_profiles`\x20(`name`,\x20`crudPermissions`,\x20`description`,\x20`createdAt`,\x20`updatedAt`)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201010\x20THEN\x20\x27Triggers\x27','../config/logger','\x20\x20FROM\x20user_profiles\x20u','\x20\x20`description`\x20varchar(255)\x20DEFAULT\x20NULL,','\x20\x20WHERE\x20x.sectionId\x20=\x20801;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201003\x20THEN\x20\x27CustomDashboards\x27','\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x201501\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20voice_queues\x20WHERE\x20id\x20=\x20x.resourceId\x20AND\x20type\x20=\x20\x27outbound\x27),\x27DELETE_MIGRATION\x27)','\x20\x20\x20\x20autoAssociation\x20tinyint\x20not\x20null,','INSERT\x20INTO\x20user_profile_has_sections\x20(name,\x20category,\x20sectionId,\x20enabled,\x20autoAssociation,\x20crudPermissions,\x20createdAt,\x20updatedAt,\x20userProfileId)','FOREIGN\x20KEY\x20(`userProfileId`)\x20','\x20\x20SELECT\x20name,\x20category,\x20sectionId,\x20enabled,\x20autoAssociation,\x20\x27red\x27,\x20now(),\x20now(),\x20userProfileId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201001\x20THEN\x20\x27CannedAnswers\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20701\x20THEN\x20\x27SmsQueues\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20202\x20THEN\x20\x27Agents\x27','\x20\x20SELECT\x20x.sectionId,\x20u.MailQueueId,\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20n)\x20AS\x20split','\x20\x20SET\x20sectionId\x20=\x201801\x20WHERE\x20sectionId\x20between\x2088889\x20AND\x2099999;','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpFinalProfiles;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20501\x20THEN\x20\x27ChatQueues\x27','\x20\x20SELECT\x20x.sectionId,\x20u.OpenchannelAccountId,\x20x.userId','INSERT\x20INTO\x20tmpGroupedPermissions','\x20\x20WHERE\x20x.sectionId\x20=\x20501;','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tmpNormalizedUsers','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20910\x20THEN\x20\x27Realtime\x27','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpNormalizedResources;','CREATE\x20TABLE\x20tally\x20(','\x20\x20SELECT\x20cr.resourceId,\x20name,\x20s.insertedId,\x20s.sectionId','\x20\x20n\x20INT\x20NOT\x20NULL\x20AUTO_INCREMENT\x20PRIMARY\x20KEY','\x20\x20ORDER\x20BY\x20GROUP_CONCAT(userId);','\x20\x20\x20\x20\x20\x20\x20\x20INNER\x20JOIN\x20tmpResources\x20r\x20ON\x20CHAR_LENGTH(r.resourceId)\x20-\x20CHAR_LENGTH(REPLACE(r.resourceId,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20tally.n-1','\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(701,\x20702,\x20710)\x20THEN\x20\x27Sms\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20301\x20THEN\x20\x27Lists\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ELSE\x20\x27\x27','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201305\x20THEN\x20\x27SugarcrmAccounts\x27','\x20\x20\x20\x20t.permissions\x20permissions','\x20\x20\x20\x20sectionId\x20int(11)\x20not\x20null,','\x20\x20\x20\x20\x20\x20END','CREATE\x20TABLE\x20tmpNormalizedUsers','DROP\x20TABLE\x20IF\x20EXISTS\x20tmpExtractedResources;','\x20\x20\x20\x20\x20\x20permissions\x20text\x20not\x20null,','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201303\x20THEN\x20\x27FreshdeskAccounts\x27','\x20\x20WHERE\x20name\x20in\x20(\x27Plugins\x27,\x20\x27CustomDashboards\x27);','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20users)\x20b','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201301\x20THEN\x20\x27ZendeskAccounts\x27','\x20\x20SET\x20u.userProfileId\x20=\x20f.profileId','\x20\x20`autoAssociation`\x20tinyint(1)\x20DEFAULT\x20NULL,','INSERT\x20INTO\x20tmpPermissions','(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20a',',(SELECT\x200\x20AS\x20N\x20UNION\x20ALL\x20SELECT\x201\x20UNION\x20ALL\x20SELECT\x202\x20UNION\x20ALL\x20SELECT\x203\x20UNION\x20ALL\x20SELECT\x204\x20UNION\x20ALL\x20SELECT\x205\x20UNION\x20ALL\x20SELECT\x206\x20UNION\x20ALL\x20SELECT\x207\x20UNION\x20ALL\x20SELECT\x208\x20UNION\x20ALL\x20SELECT\x209)\x20d','\x20\x20FROM\x20tmpFinalProfiles\x20t','INSERT\x20INTO\x20tmpNormalizedSections','table\x20dropped\x20%s','\x20\x20SELECT\x20*','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20901\x20THEN\x20\x27FaxQueues\x27','\x20\x20SELECT\x20GROUP_CONCAT(sectionId\x20ORDER\x20BY\x20sectionId),\x20userId','\x20\x20KEY\x20`sectionId`\x20(`sectionId`),','ADD\x20CONSTRAINT\x20`users_ibfk_1`\x20','\x20\x20INNER\x20JOIN\x20user_has_sms_accounts\x20u\x20ON\x20u.UserId\x20=\x20x.userId','\x20\x20\x20\x20\x20\x20\x20\x20r.type\x20type,','removeColumn','\x20\x20FROM\x20tally\x20t\x20INNER\x20JOIN\x20tmpNormalizedSections\x20s\x20ON\x20CHAR_LENGTH(s.userId)\x20-\x20CHAR_LENGTH(REPLACE(s.userId,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20t.n-1','\x20\x20SELECT\x20x.sectionId,\x20u.VoiceQueueId,\x20x.userId','\x20\x20SELECT\x20*\x20FROM\x20tmpSingleProfiles;','analytics_extracted_reports','\x20\x20\x20\x20\x20\x20\x20\x20r.insertedSectionId\x20insertedSectionId,','\x20\x20\x20\x20SUBSTRING_INDEX(SUBSTRING_INDEX(p.permissions,\x20\x27,\x27,\x20tally.n),\x20\x27,\x27,\x20-1)\x20permission,','\x20\x20SELECT\x20GROUP_CONCAT(id),\x20permissions,\x20null'];(function(_0x517f3d,_0x2f6f04){const _0x28840b=function(_0x61926f){while(--_0x61926f){_0x517f3d['push'](_0x517f3d['shift']());}};_0x28840b(++_0x2f6f04);}(a964_0x2f6f,0xd5));const a964_0x2884=function(_0x517f3d,_0x2f6f04){_0x517f3d=_0x517f3d-0x0;let _0x28840b=a964_0x2f6f[_0x517f3d];return _0x28840b;};const _0xf6ae3e=a964_0x2884;'use strict';const util=require(_0xf6ae3e('0xbe')),logger=require(_0xf6ae3e('0x39'))(_0xf6ae3e('0xd5')),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x61926f){const _0x57899f=_0xf6ae3e;this[_0x57899f('0x146')]=this[_0x57899f('0x146')]?this[_0x57899f('0x146')]['finally'](_0x61926f):_0x61926f();};const Migration=function(_0x19a9d5){const _0x449fce=_0xf6ae3e;this['queryInterface']=_0x19a9d5,this[_0x449fce('0x128')]=new Sequence();};Migration[_0xf6ae3e('0xba')][_0xf6ae3e('0xc7')]=function(_0xb56938,_0x874a9a,_0x397f69){const _0x4fa639=_0xf6ae3e,_0x2fada3=this;this[_0x4fa639('0x128')][_0x4fa639('0xf9')](function(){const _0x3c0378=_0x4fa639;return _0x2fada3['queryInterface']['changeColumn'](_0xb56938,_0x874a9a,_0x397f69)[_0x3c0378('0xb0')](function(){const _0x2505ab=_0x3c0378;logger[_0x2505ab('0x89')](_0x2505ab('0xaf'),_0x874a9a,_0xb56938);})[_0x3c0378('0x127')](function(_0x506ecf){const _0x5384e7=_0x3c0378;logger['info'](JSON[_0x5384e7('0x7b')](_0x506ecf));});});},Migration[_0xf6ae3e('0xba')]['addColumn']=function(_0x37b0ff,_0x58dfd1,_0x32e39e){const _0x4d7f68=_0xf6ae3e,_0x45de99=this;this[_0x4d7f68('0x128')][_0x4d7f68('0xf9')](function(){const _0x1304d3=_0x4d7f68;return _0x45de99[_0x1304d3('0xc0')][_0x1304d3('0xb9')](_0x37b0ff,_0x58dfd1,_0x32e39e)[_0x1304d3('0xb0')](function(){const _0x514d67=_0x1304d3;logger[_0x514d67('0x89')]('Added\x20column\x20%s\x20to\x20%s',_0x58dfd1,_0x37b0ff);})[_0x1304d3('0x127')](function(_0x11cc16){const _0x1875ae=_0x1304d3;logger[_0x1875ae('0x89')](JSON[_0x1875ae('0x7b')](_0x11cc16));});});},Migration[_0xf6ae3e('0xba')]['dropTable']=function(_0x8614f4){const _0x145775=_0xf6ae3e,_0x2f044b=this;this[_0x145775('0x128')]['enqueue'](function(){const _0x50f754=_0x145775;return _0x2f044b[_0x50f754('0xc0')][_0x50f754('0x13e')](_0x8614f4,{'force':!![]})[_0x50f754('0xb0')](function(){const _0x45e198=_0x50f754;logger[_0x45e198('0x89')](_0x45e198('0x6b'),_0x8614f4);})[_0x50f754('0x127')](function(_0x4f4148){const _0x40c3f7=_0x50f754;logger[_0x40c3f7('0x89')](JSON[_0x40c3f7('0x7b')](_0x4f4148));});});},Migration[_0xf6ae3e('0xba')][_0xf6ae3e('0x112')]=function(_0x2c0e92,_0x305e46,_0x11ee8a){const _0x50edc6=_0xf6ae3e,_0x3cd76a=this;this[_0x50edc6('0x128')][_0x50edc6('0xf9')](function(){const _0x4771d1=_0x50edc6;return _0x3cd76a['queryInterface'][_0x4771d1('0x112')](_0x2c0e92,_0x305e46,{'indexName':_0x11ee8a})[_0x4771d1('0xb0')](function(){const _0x3f50cf=_0x4771d1;logger[_0x3f50cf('0x89')](_0x3f50cf('0xde'),_0x2c0e92,_0x305e46['join'](','),_0x11ee8a);})['catch'](function(_0x990dab){const _0x1c0a87=_0x4771d1;logger[_0x1c0a87('0x89')](JSON[_0x1c0a87('0x7b')](_0x990dab));});});},Migration[_0xf6ae3e('0xba')][_0xf6ae3e('0xcb')]=function(_0x2d43b8,_0x5d3780){const _0x4a24f6=_0xf6ae3e,_0x482eaa=this;this[_0x4a24f6('0x128')]['enqueue'](function(){const _0x33716a=_0x4a24f6;return _0x482eaa[_0x33716a('0xc0')]['removeIndex'](_0x2d43b8,_0x5d3780)[_0x33716a('0xb0')](function(){const _0xb652a4=_0x33716a;logger[_0xb652a4('0x89')]('removeIndex\x20%s\x20%s',_0x2d43b8,_0x5d3780);})[_0x33716a('0x127')](function(_0x1f4267){const _0x91b0d1=_0x33716a;logger[_0x91b0d1('0x89')](JSON['stringify'](_0x1f4267));});});},Migration[_0xf6ae3e('0xba')]['query']=function(_0xba71d4){const _0x3fabcb=_0xf6ae3e,_0x4a3294=this;this[_0x3fabcb('0x128')][_0x3fabcb('0xf9')](function(){const _0x5ecdb9=_0x3fabcb;return _0x4a3294[_0x5ecdb9('0xc0')][_0x5ecdb9('0xd2')]['query'](_0xba71d4)[_0x5ecdb9('0xb0')](function(){const _0xfb46bd=_0x5ecdb9;logger[_0xfb46bd('0x89')](_0xfb46bd('0x115'),_0xba71d4);})['catch'](function(_0x11f290){const _0x61a502=_0x5ecdb9;logger['info'](JSON[_0x61a502('0x7b')](_0x11f290));});});},Migration['prototype'][_0xf6ae3e('0x73')]=function(_0x369851,_0x3f7033){const _0x37dacf=_0xf6ae3e,_0x2379cd=this;this[_0x37dacf('0x128')]['enqueue'](function(){const _0x36ad2d=_0x37dacf;return _0x2379cd[_0x36ad2d('0xc0')][_0x36ad2d('0x73')](_0x369851,_0x3f7033)[_0x36ad2d('0xb0')](function(){const _0x2e84d9=_0x36ad2d;logger[_0x2e84d9('0x89')](_0x2e84d9('0xc2'),_0x3f7033,_0x369851);})['catch'](function(_0x40372a){const _0x1fe61e=_0x36ad2d;logger[_0x1fe61e('0x89')](util[_0x1fe61e('0x3')](_0x40372a,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0xf6ae3e('0xf6')]=function(_0x229ae7,_0x44ee65,_0x41da3e){const _0xd6e269=_0xf6ae3e,_0x567cda=this;this[_0xd6e269('0x128')][_0xd6e269('0xf9')](function(){const _0xbfca29=_0xd6e269;return _0x567cda[_0xbfca29('0xc0')][_0xbfca29('0xf6')](_0x229ae7,_0x44ee65,_0x41da3e)['then'](function(){const _0x46f870=_0xbfca29;logger[_0x46f870('0x89')](_0x46f870('0x123'),_0x44ee65,_0x41da3e,_0x229ae7);})['catch'](function(_0x580cf5){const _0x5a92bf=_0xbfca29;logger['info'](util[_0x5a92bf('0x3')](_0x580cf5,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x1e7164){const _0x12edbc=_0xf6ae3e;this[_0x12edbc('0x128')][_0x12edbc('0xf9')](function(){return _0x1e7164();});},module['exports']={'up':function(_0x245e58,_0x6d40df){return new Promise(function(_0x52b571){const _0x310048=a964_0x2884,_0x1e58d0=new Migration(_0x245e58);_0x1e58d0['addColumn']('analytics_extracted_reports','reportId',{'type':_0x6d40df[_0x310048('0x10a')]}),_0x1e58d0[_0x310048('0xb9')](_0x310048('0x77'),_0x310048('0xd1'),{'type':_0x6d40df['STRING']}),_0x1e58d0['addColumn']('users',_0x310048('0xfa'),{'type':_0x6d40df['INTEGER']}),_0x1e58d0[_0x310048('0x73')](_0x310048('0x100'),_0x310048('0xea')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12a')+_0x310048('0x2e')+_0x310048('0xc1')+_0x310048('0xc4')+_0x310048('0x3b')+'\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,'+_0x310048('0x8')+_0x310048('0x125')+'\x20\x20UNIQUE\x20KEY\x20`name`\x20(`name`)'+_0x310048('0x139')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x37')+_0x310048('0x109')),_0x1e58d0['query'](_0x310048('0x95')+_0x310048('0x70')+_0x310048('0x41')+_0x310048('0xce')+_0x310048('0x9a')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x13c')+_0x310048('0x2e')+_0x310048('0xc1')+_0x310048('0x18')+_0x310048('0x24')+'\x20\x20`enabled`\x20tinyint(1)\x20DEFAULT\x20NULL,'+_0x310048('0x65')+'\x20\x20`crudPermissions`\x20varchar(255)\x20DEFAULT\x20NULL,'+'\x20\x20`createdAt`\x20datetime\x20NOT\x20NULL,'+'\x20\x20`updatedAt`\x20datetime\x20NOT\x20NULL,'+_0x310048('0xfe')+_0x310048('0x125')+_0x310048('0x11c')+_0x310048('0xdb')+_0x310048('0xd9')+')\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x110')+_0x310048('0x2e')+_0x310048('0xc1')+'\x20\x20`resourceId`\x20int(11)\x20NOT\x20NULL,'+_0x310048('0x93')+_0x310048('0x13b')+_0x310048('0x8')+_0x310048('0x31')+_0x310048('0x125')+_0x310048('0x6f')+_0x310048('0x98')+'\x20\x20CONSTRAINT\x20`user_profile_has_resources_ibfk_1`\x20FOREIGN\x20KEY\x20(`sectionId`)\x20REFERENCES\x20`user_profile_has_sections`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE'+')\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x51')+_0x310048('0x53')+');'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0xf5')+_0x310048('0x126')+_0x310048('0x67')+_0x310048('0x104')+_0x310048('0xcd')+_0x310048('0x68')+_0x310048('0xdd')+';'),_0x1e58d0[_0x310048('0x12d')]('CREATE\x20TABLE\x20tmpPermissions'+_0x310048('0xf7')+_0x310048('0xe8')+_0x310048('0x5f')+_0x310048('0xa2')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x66')+'\x20\x20SELECT\x20id,\x20permissions,\x20null'+_0x310048('0x96')+_0x310048('0x16')+_0x310048('0xe4')),_0x1e58d0['query']('CREATE\x20TABLE\x20tmpNormalizedSections'+_0x310048('0xf7')+_0x310048('0x5b')+_0x310048('0x92')+_0x310048('0x10f')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x6a')+_0x310048('0xa3')+_0x310048('0xf1')+_0x310048('0x79')+'\x20\x20\x20\x20p.userIds\x20userId'+'\x20\x20FROM\x20tally\x20INNER\x20JOIN\x20tmpPermissions\x20p\x20ON\x20CHAR_LENGTH(p.permissions)\x20-\x20CHAR_LENGTH(REPLACE(p.permissions,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20tally.n-1'+_0x310048('0x119')),_0x1e58d0['query'](_0x310048('0xaa')+'\x20\x20('+'\x20\x20\x20\x20permissions\x20text\x20not\x20null,'+_0x310048('0x9d')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0xd4')+_0x310048('0x6e')+_0x310048('0x21')+_0x310048('0x132')),_0x1e58d0[_0x310048('0x12d')]('UPDATE\x20users\x20u,\x20tmpNormalizedPermissions\x20t'+'\x20\x20SET\x20u.permissions\x20=\x20t.permissions'+_0x310048('0x22')),_0x1e58d0['query'](_0x310048('0x135')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x66')+_0x310048('0x7a')+_0x310048('0x96')+_0x310048('0x16')+_0x310048('0x13d')+_0x310048('0x29')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x5d')+_0x310048('0xf7')+_0x310048('0x5b')+_0x310048('0x92')+_0x310048('0x10f')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')]('INSERT\x20INTO\x20tmpNormalizedUsers'+_0x310048('0xd6')+_0x310048('0xf1')+_0x310048('0xe0')+_0x310048('0x11d')+_0x310048('0x74')+_0x310048('0x119')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0xa1')+_0x310048('0x99')+'\x20\x20resourceId\x20int(11),'+_0x310048('0x130')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12b')+'\x20\x20SELECT\x20x.sectionId,\x20u.VoiceQueueId,\x20x.userId'+_0x310048('0xb7')+_0x310048('0xf')+_0x310048('0x8a')+'\x20\x20WHERE\x20x.sectionId\x20=\x20401\x20AND\x20q.type\x20=\x20\x27inbound\x27;'),_0x1e58d0[_0x310048('0x12d')]('INSERT\x20INTO\x20tmpExtractedResources'+_0x310048('0x4')+'\x20\x20FROM\x20tmpNormalizedUsers\x20x'+_0x310048('0x129')+_0x310048('0x4d')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12b')+_0x310048('0x136')+'\x20\x20FROM\x20tmpNormalizedUsers\x20x'+'\x20\x20INNER\x20JOIN\x20user_has_chat_websites\x20u\x20ON\x20u.UserId\x20=\x20x.userId'+_0x310048('0x7e')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12b')+_0x310048('0x46')+_0x310048('0xb7')+'\x20\x20INNER\x20JOIN\x20user_has_mail_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId'+'\x20\x20WHERE\x20x.sectionId\x20=\x20601;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12b')+_0x310048('0xe9')+_0x310048('0xb7')+_0x310048('0x28')+_0x310048('0x147')),_0x1e58d0[_0x310048('0x12d')]('INSERT\x20INTO\x20tmpExtractedResources'+_0x310048('0xb2')+_0x310048('0xb7')+_0x310048('0x12c')+_0x310048('0x32')),_0x1e58d0[_0x310048('0x12d')]('INSERT\x20INTO\x20tmpExtractedResources'+_0x310048('0x15')+'\x20\x20FROM\x20tmpNormalizedUsers\x20x'+_0x310048('0x71')+'\x20\x20WHERE\x20x.sectionId\x20=\x20702;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12b')+'\x20\x20SELECT\x20x.sectionId,\x20u.OpenchannelQueueId,\x20x.userId'+_0x310048('0xb7')+'\x20\x20INNER\x20JOIN\x20user_has_openchannel_queues\x20u\x20ON\x20u.UserId\x20=\x20x.userId'+_0x310048('0x3c')),_0x1e58d0['query'](_0x310048('0x12b')+_0x310048('0x4b')+'\x20\x20FROM\x20tmpNormalizedUsers\x20x'+'\x20\x20INNER\x20JOIN\x20user_has_openchannel_accounts\x20u\x20ON\x20u.UserId\x20=\x20x.userId'+'\x20\x20WHERE\x20x.sectionId\x20=\x20802;'),_0x1e58d0['query']('INSERT\x20INTO\x20tmpExtractedResources'+_0x310048('0x90')+'\x20\x20FROM\x20tmpNormalizedUsers\x20x'+_0x310048('0x122')+_0x310048('0x116')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12b')+'\x20\x20SELECT\x20x.sectionId,\x20u.FaxAccountId,\x20x.userId'+'\x20\x20FROM\x20tmpNormalizedUsers\x20x'+_0x310048('0x138')+'\x20\x20WHERE\x20x.sectionId\x20=\x20902;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12b')+_0x310048('0x13a')+_0x310048('0xb7')+'\x20\x20INNER\x20JOIN\x20user_has_square_projects\x20u\x20ON\x20u.UserId\x20=\x20x.userId'+'\x20\x20WHERE\x20x.sectionId\x20=\x201103;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12b')+_0x310048('0x75')+_0x310048('0xb7')+_0x310048('0xf')+_0x310048('0x8a')+_0x310048('0xda')),_0x1e58d0[_0x310048('0x12d')]('CREATE\x20TABLE\x20tmpGroupedPermissions'+'\x20\x20('+'\x20\x20\x20\x20\x20\x20userId\x20text\x20not\x20null,'+_0x310048('0x143')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x4c')+'\x20\x20SELECT\x20userId,\x20permissions'+'\x20\x20FROM\x20(SELECT'+_0x310048('0x86')+_0x310048('0x5a')+_0x310048('0x19')+_0x310048('0x119')),_0x1e58d0['query'](_0x310048('0xb3')+_0x310048('0xf7')+_0x310048('0xe8')+_0x310048('0x5f')+_0x310048('0xa2')+'\x20\x20);'),_0x1e58d0['query'](_0x310048('0x145')+_0x310048('0xeb')+_0x310048('0xcf')+_0x310048('0x14e')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20(SELECT'+_0x310048('0xa5')+_0x310048('0x7d')+_0x310048('0xd3')+_0x310048('0x107')+_0x310048('0x47')+_0x310048('0xe2')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(SELECT\x20GROUP_CONCAT(userId\x20ORDER\x20BY\x20userId\x20ASC)\x20AS\x20users'+_0x310048('0x4e')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GROUP\x20BY\x20resourceId,\x20sectionId'+_0x310048('0x62')+_0x310048('0x23')+'\x20\x20GROUP\x20BY\x20permissions'+_0x310048('0x54')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x1a')+_0x310048('0xf7')+'\x20\x20\x20\x20\x20\x20userId\x20text\x20not\x20null,'+_0x310048('0x5f')+_0x310048('0xa2')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x131')+'\x20\x20SELECT\x20userId,\x20permissions,\x20null'+_0x310048('0xcf')+_0x310048('0xe7')+_0x310048('0x0')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tally\x20t\x20INNER\x20JOIN\x20tmpPermissions\x20r\x20ON\x20CHAR_LENGTH(r.userIds)\x20-\x20CHAR_LENGTH(REPLACE(r.userIds,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20t.n-1'+_0x310048('0x11b')+_0x310048('0xa7')+_0x310048('0xe2')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20(SELECT\x20GROUP_CONCAT(userId\x20ORDER\x20BY\x20userId\x20ASC)\x20as\x20users'+_0x310048('0x82')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GROUP\x20BY\x20resourceId,\x20sectionId'+_0x310048('0x10d')+_0x310048('0x83')+_0x310048('0xe')),_0x1e58d0[_0x310048('0x12d')]('CREATE\x20TABLE\x20tmpFinalProfiles'+_0x310048('0xf7')+_0x310048('0xb5')+_0x310048('0x5f')+_0x310048('0xa2')+'\x20\x20);'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x35')+_0x310048('0x2b')+_0x310048('0xef')+_0x310048('0x76')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x26')+_0x310048('0xa4')+_0x310048('0x69')+_0x310048('0x9b')+'\x20\x20FROM\x20tmpFinalProfiles;'),_0x1e58d0[_0x310048('0x12d')]('UPDATE\x20tmpFinalProfiles'+_0x310048('0x14')+_0x310048('0x3a')+_0x310048('0x20')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x144')+_0x310048('0xf7')+'\x20\x20\x20\x20name\x20varchar(255)\x20not\x20null,'+_0x310048('0x120')+_0x310048('0x5b')+_0x310048('0xdc')+_0x310048('0x3f')+_0x310048('0xec')+_0x310048('0xed')+_0x310048('0xc')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')]('INSERT\x20INTO\x20tmpSections'+_0x310048('0x149')+_0x310048('0xf1')+'\x20\x20\x20\x20\x20\x20\x20\x20fp.profileId\x20profileId,'+_0x310048('0xe3')+_0x310048('0xf2')+_0x310048('0x134')+'\x20\x20\x20\x20\x20\x20\x20\x20INNER\x20JOIN\x20tmpFinalProfiles\x20fp\x20ON\x20CHAR_LENGTH(fp.permissions)\x20-\x20CHAR_LENGTH(REPLACE(fp.permissions,\x20\x27,\x27,\x20\x27\x27))\x20>=\x20tally.n-1'+'\x20\x20\x20\x20\x20\x20\x20\x20ORDER\x20BY\x20n)\x20AS\x20split;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x103')+_0x310048('0x101')+'\x20\x20\x20\x20\x20\x20name\x20=\x20(SELECT'+_0x310048('0x33')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20100\x20THEN\x20\x27Dashboards\x27'+_0x310048('0x8c')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20200\x20THEN\x20\x27DELETE\x27'+_0x310048('0x5')+_0x310048('0x45')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20203\x20THEN\x20\x27Telephones\x27'+_0x310048('0x10')+_0x310048('0xe6')+_0x310048('0x57')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20302\x20THEN\x20\x27Companies\x27'+_0x310048('0xad')+_0x310048('0x14b')+_0x310048('0x8d')+_0x310048('0xf4')+_0x310048('0x133')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20403\x20THEN\x20\x27OutboundRoutes\x27'+_0x310048('0x27')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20405\x20THEN\x20\x27Contexts\x27'+_0x310048('0xe1')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20407\x20THEN\x20\x27MusicOnHolds\x27'+_0x310048('0x84')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20409\x20THEN\x20\x27ChanSpies\x27'+_0x310048('0x81')+_0x310048('0x121')+_0x310048('0x9f')+_0x310048('0x4a')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20502\x20THEN\x20\x27ChatWebsites\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20510\x20THEN\x20\x27Realtime\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20600\x20THEN\x20\x27DELETE\x27'+_0x310048('0x11f')+_0x310048('0xc5')+_0x310048('0xf3')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20610\x20THEN\x20\x27Realtime\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20700\x20THEN\x20\x27DELETE\x27'+_0x310048('0x44')+_0x310048('0xc8')+_0x310048('0x6')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20800\x20THEN\x20\x27DELETE\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20801\x20THEN\x20\x27OpenchannelQueues\x27'+_0x310048('0x11a')+_0x310048('0xa6')+_0x310048('0xb4')+_0x310048('0x6d')+_0x310048('0x7')+_0x310048('0x4f')+_0x310048('0x1b')+_0x310048('0x43')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201002\x20THEN\x20\x27Dispositions\x27'+_0x310048('0x3d')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201004\x20THEN\x20\x27Intervals\x27'+_0x310048('0x141')+_0x310048('0xc3')+_0x310048('0xb1')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201008\x20THEN\x20\x27Tags\x27'+_0x310048('0x1')+_0x310048('0x38')+_0x310048('0x2c')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201012\x20THEN\x20\x27Variables\x27'+_0x310048('0xab')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201101\x20THEN\x20\x27ODBC\x27'+_0x310048('0x1d')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201103\x20THEN\x20\x27SquareProjects\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201200\x20THEN\x20\x27DELETE\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201201\x20THEN\x20\x27Metrics\x27'+_0x310048('0x17')+_0x310048('0x11')+_0x310048('0x114')+_0x310048('0x63')+_0x310048('0x88')+_0x310048('0x60')+_0x310048('0x59')+_0x310048('0xfd')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201307\x20THEN\x20\x27ZohoAccounts\x27'+_0x310048('0xbd')+_0x310048('0x30')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1401,\x201402,\x201403,\x201404,\x201405,\x201406,\x201407)\x20THEN\x20\x27DELETE\x27'+_0x310048('0x124')+_0x310048('0x91')+_0x310048('0x10e')+_0x310048('0xd0')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201600\x20THEN\x20\x27Help\x27'+_0x310048('0x7c')+_0x310048('0x11e')+_0x310048('0x2f')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20between\x2088889\x20AND\x2099999\x20THEN\x20\x27Plugins\x27'+_0x310048('0x8e')+_0x310048('0x58')+_0x310048('0x85')+_0x310048('0x80')+'\x20\x20category\x20=\x20(SELECT'+'\x20\x20\x20\x20\x20\x20CASE'+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x20100\x20THEN\x20\x27Dashboards\x27'+_0x310048('0x36')+_0x310048('0xf8')+_0x310048('0xee')+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(401,\x20402,\x20403,\x20404,\x20405,\x20406,\x20407,\x20408,\x20409,\x20410,\x20411)\x20THEN\x20\x27Voice\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(501,\x20502,\x20510)\x20THEN\x20\x27Chat\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(601,\x20602,\x20603,\x20610)\x20THEN\x20\x27Mail\x27'+_0x310048('0x56')+_0x310048('0x142')+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(901,\x20902,\x20910)\x20THEN\x20\x27Fax\x27'+_0x310048('0x1c')+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20in\x20(1101,\x201102,\x201103)\x20THEN\x20\x27CallySquare\x27'+_0x310048('0x12')+_0x310048('0x7f')+_0x310048('0xd7')+_0x310048('0x14a')+_0x310048('0xc6')+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20=\x201701\x20THEN\x20\x27jscripty\x27'+'\x20\x20\x20\x20\x20\x20\x20\x20WHEN\x20sectionId\x20between\x2088889\x20AND\x2099999\x20THEN\x20\x27AppZone\x27'+_0x310048('0xa9')+_0x310048('0x5c')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')]('DELETE\x20FROM\x20tmpSections'+_0x310048('0xff')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0xe5')+'\x20\x20('+_0x310048('0x12f')+_0x310048('0x120')+_0x310048('0x5b')+'\x20\x20\x20\x20enabled\x20tinyint\x20not\x20null,'+_0x310048('0x3f')+_0x310048('0xec')+'\x20\x20\x20\x20insertedId\x20int(11),'+_0x310048('0xc')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x148')+_0x310048('0x6c')+_0x310048('0x117')+_0x310048('0x61')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0xb8')+_0x310048('0x14c')),_0x1e58d0['query']('UPDATE\x20tmpSections'+_0x310048('0x48')),_0x1e58d0[_0x310048('0x12d')]('UPDATE\x20tmpSections'+'\x20\x20SET\x20sectionId\x20=\x201003\x20WHERE\x20sectionId\x20>=\x20100000;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x103')+'\x20\x20SET\x20autoAssociation\x20=\x201\x20WHERE\x20sectionId\x20=\x20100;'),_0x1e58d0[_0x310048('0x12d')]('UPDATE\x20tmpCustomResources'+_0x310048('0xac')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20CASE'+'\x20\x20\x20\x20\x20\x20WHEN\x20name\x20=\x20\x27Plugins\x27\x20THEN\x20(sectionId\x20-\x2088888)'+_0x310048('0x97')+_0x310048('0xcc')+_0x310048('0x13f')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x40')+_0x310048('0x42')+_0x310048('0xdf')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x12e')+'\x20\x20SET\x20insertedId\x20=\x20(SELECT\x20id'+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20user_profile_has_sections\x20x'+_0x310048('0x9')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x108')+_0x310048('0x10b')+_0x310048('0x1f')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0xb6')+'\x20\x20('+_0x310048('0x13')+'\x20\x20\x20\x20\x20\x20type\x20varchar(255)\x20not\x20null,'+_0x310048('0x2')+_0x310048('0xbb')+'\x20\x20);'),_0x1e58d0[_0x310048('0x12d')]('INSERT\x20INTO\x20tmpResources'+_0x310048('0x52')+_0x310048('0x9c')+'\x20\x20INNER\x20JOIN\x20tmpExtractedResources\x20cr\x20ON\x20cr.userId\x20=\x20s.userId\x20AND\x20cr.sectionId\x20=\x20s.sectionId\x20AND\x20cr.resourceId\x20IS\x20NOT\x20NULL;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0xd')+_0x310048('0xf7')+_0x310048('0x12f')+'\x20\x20\x20\x20resourceId\x20int(11)\x20not\x20null,'+_0x310048('0x105')+'\x20\x20\x20\x20insertedSectionId\x20int(11)\x20not\x20null,'+_0x310048('0x10c')+_0x310048('0xca')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x102')+'\x20\x20SELECT\x20\x27\x27,\x20resourceId,\x20type,\x20insertedSectionId,\x20sectionId'+_0x310048('0xf1')+_0x310048('0xf0')+_0x310048('0x72')+_0x310048('0x78')+'\x20\x20\x20\x20\x20\x20\x20\x20r.sectionId\x20sectionId'+'\x20\x20\x20\x20\x20\x20\x20\x20FROM\x20tally'+_0x310048('0x55')+_0x310048('0xbc')),_0x1e58d0['query']('INSERT\x20INTO\x20tmpNormalizedResources'+_0x310048('0x118')+_0x310048('0xb')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0xd8')+_0x310048('0xa8')+_0x310048('0x113')+_0x310048('0xa0')+'\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20501\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20chat_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+_0x310048('0x9e')+'\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20601\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20mail_queues\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+_0x310048('0x8b')+_0x310048('0xae')+'\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20702\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20sms_accounts\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+_0x310048('0x111')+_0x310048('0xa')+_0x310048('0xfb')+'\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x20902\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20fax_accounts\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+'\x20\x20\x20\x20\x20\x20WHEN\x20x.sectionId\x20=\x201103\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20square_projects\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+_0x310048('0x3e')+_0x310048('0xc9')+'\x20\x20\x20\x20\x20\x20WHEN\x20x.type\x20=\x20\x27CustomDashboards\x27\x20THEN\x20COALESCE((SELECT\x20name\x20FROM\x20dashboards\x20WHERE\x20id\x20=\x20x.resourceId),\x27DELETE_MIGRATION\x27)'+'\x20\x20END'+_0x310048('0x106')),_0x1e58d0['query'](_0x310048('0x1e')+_0x310048('0x94')),_0x1e58d0[_0x310048('0x12d')]('INSERT\x20INTO\x20user_profile_has_resources\x20(name,\x20resourceId,\x20type,\x20createdAt,\x20updatedAt,\x20sectionId)'+_0x310048('0x8f')+_0x310048('0x14f')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x14d')+_0x310048('0x64')+_0x310048('0x137')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x2a')+'\x20\x20SET\x20u.userProfileId\x20=\x201'+_0x310048('0x140')),_0x1e58d0[_0x310048('0x12d')]('\x20DROP\x20TABLE\x20IF\x20EXISTS\x20tally;'),_0x1e58d0['query'](_0x310048('0x2d')),_0x1e58d0['query'](_0x310048('0x25')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0xbf')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x5e')),_0x1e58d0['query'](_0x310048('0xfc')),_0x1e58d0[_0x310048('0x12d')]('DROP\x20TABLE\x20IF\x20EXISTS\x20tmpSharedProfiles;'),_0x1e58d0['query'](_0x310048('0x87')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x49')),_0x1e58d0[_0x310048('0x12d')]('DROP\x20TABLE\x20IF\x20EXISTS\x20tmpSections;'),_0x1e58d0[_0x310048('0x12d')]('DROP\x20TABLE\x20IF\x20EXISTS\x20tmpCustomResources;'),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x34')),_0x1e58d0[_0x310048('0x12d')](_0x310048('0x50')),_0x1e58d0['final'](_0x52b571);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.2.0.js b/server/migrations/2.2.0.js index 52ed854..ddfe19c 100644 --- a/server/migrations/2.2.0.js +++ b/server/migrations/2.2.0.js @@ -1 +1 @@ -const a965_0x3c8c=['INTEGER','stringify','addIndex','addColumn','sequence','migration','catch','csc','query','skebby','removeIndex','enqueue','plivo','type','clickatell','Removed\x20column\x20%s\x20from\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','../config/logger','sequelize','sms_accounts','then','dropTable','tail','inspect','queryInterface','users','info','final','ENUM','renameColumn','connectel','exports','finally','Changed\x20column\x20%s\x20in\x20table\x20%s','table\x20dropped\x20%s','Added\x20column\x20%s\x20to\x20%s','twilio','removeColumn','removeIndex\x20%s\x20%s','intelepeer','query\x20%s','util','prototype','clicksend','join','changeColumn'];(function(_0xefa034,_0x3c8c50){const _0x19f9d9=function(_0x2a988c){while(--_0x2a988c){_0xefa034['push'](_0xefa034['shift']());}};_0x19f9d9(++_0x3c8c50);}(a965_0x3c8c,0x133));const a965_0x19f9=function(_0xefa034,_0x3c8c50){_0xefa034=_0xefa034-0x0;let _0x19f9d9=a965_0x3c8c[_0xefa034];return _0x19f9d9;};const _0x2d4064=a965_0x19f9;'use strict';const util=require(_0x2d4064('0xa')),logger=require(_0x2d4064('0x20'))(_0x2d4064('0x14')),Sequence=function(){};Sequence['prototype'][_0x2d4064('0x1a')]=function(_0x2a988c){const _0x514de2=_0x2d4064;this[_0x514de2('0x25')]=this['tail']?this['tail'][_0x514de2('0x1')](_0x2a988c):_0x2a988c();};const Migration=function(_0x2fceef){const _0x46a2f4=_0x2d4064;this[_0x46a2f4('0x27')]=_0x2fceef,this[_0x46a2f4('0x13')]=new Sequence();};Migration[_0x2d4064('0xb')]['changeColumn']=function(_0x39ad8a,_0xa2c0d3,_0x15fbb0){const _0x3f8fde=_0x2d4064,_0x59a180=this;this[_0x3f8fde('0x13')][_0x3f8fde('0x1a')](function(){const _0x429c88=_0x3f8fde;return _0x59a180[_0x429c88('0x27')][_0x429c88('0xe')](_0x39ad8a,_0xa2c0d3,_0x15fbb0)[_0x429c88('0x23')](function(){const _0x208c18=_0x429c88;logger[_0x208c18('0x29')](_0x208c18('0x2'),_0xa2c0d3,_0x39ad8a);})['catch'](function(_0x4a5ffb){const _0x5cf0bf=_0x429c88;logger[_0x5cf0bf('0x29')](JSON[_0x5cf0bf('0x10')](_0x4a5ffb));});});},Migration[_0x2d4064('0xb')]['addColumn']=function(_0x328189,_0x32b7dd,_0x3ad024){const _0xe42419=_0x2d4064,_0x33df67=this;this[_0xe42419('0x13')][_0xe42419('0x1a')](function(){const _0x3a4992=_0xe42419;return _0x33df67[_0x3a4992('0x27')][_0x3a4992('0x12')](_0x328189,_0x32b7dd,_0x3ad024)[_0x3a4992('0x23')](function(){const _0x39c71d=_0x3a4992;logger[_0x39c71d('0x29')](_0x39c71d('0x4'),_0x32b7dd,_0x328189);})[_0x3a4992('0x15')](function(_0x1b6b87){const _0x5a74f7=_0x3a4992;logger['info'](JSON[_0x5a74f7('0x10')](_0x1b6b87));});});},Migration[_0x2d4064('0xb')][_0x2d4064('0x24')]=function(_0xe6daec){const _0x214c7b=_0x2d4064,_0x2591f5=this;this[_0x214c7b('0x13')]['enqueue'](function(){const _0xc09ef0=_0x214c7b;return _0x2591f5[_0xc09ef0('0x27')][_0xc09ef0('0x24')](_0xe6daec,{'force':!![]})[_0xc09ef0('0x23')](function(){const _0x5b2f6e=_0xc09ef0;logger[_0x5b2f6e('0x29')](_0x5b2f6e('0x3'),_0xe6daec);})[_0xc09ef0('0x15')](function(_0x285a5d){const _0x5d5350=_0xc09ef0;logger[_0x5d5350('0x29')](JSON[_0x5d5350('0x10')](_0x285a5d));});});},Migration[_0x2d4064('0xb')][_0x2d4064('0x11')]=function(_0x565e08,_0x3ab10a,_0x14012b){const _0x43382a=_0x2d4064,_0x461a5c=this;this[_0x43382a('0x13')][_0x43382a('0x1a')](function(){const _0x431696=_0x43382a;return _0x461a5c[_0x431696('0x27')][_0x431696('0x11')](_0x565e08,_0x3ab10a,{'indexName':_0x14012b})[_0x431696('0x23')](function(){const _0x3f36bf=_0x431696;logger[_0x3f36bf('0x29')]('addIndex\x20%s\x20%s\x20%s',_0x565e08,_0x3ab10a[_0x3f36bf('0xd')](','),_0x14012b);})['catch'](function(_0x59a600){const _0x594b5e=_0x431696;logger[_0x594b5e('0x29')](JSON['stringify'](_0x59a600));});});},Migration['prototype']['removeIndex']=function(_0x2805bc,_0x51a0e0){const _0x13594d=_0x2d4064,_0x5e96d8=this;this['sequence'][_0x13594d('0x1a')](function(){const _0x50d956=_0x13594d;return _0x5e96d8[_0x50d956('0x27')][_0x50d956('0x19')](_0x2805bc,_0x51a0e0)[_0x50d956('0x23')](function(){const _0x3606a7=_0x50d956;logger[_0x3606a7('0x29')](_0x3606a7('0x7'),_0x2805bc,_0x51a0e0);})[_0x50d956('0x15')](function(_0x22387b){const _0xdebfe4=_0x50d956;logger['info'](JSON[_0xdebfe4('0x10')](_0x22387b));});});},Migration['prototype'][_0x2d4064('0x17')]=function(_0xbdadb1){const _0x3dd1c0=_0x2d4064,_0x56fc18=this;this[_0x3dd1c0('0x13')][_0x3dd1c0('0x1a')](function(){const _0x16ebe3=_0x3dd1c0;return _0x56fc18[_0x16ebe3('0x27')][_0x16ebe3('0x21')]['query'](_0xbdadb1)[_0x16ebe3('0x23')](function(){const _0x5dcef5=_0x16ebe3;logger[_0x5dcef5('0x29')](_0x5dcef5('0x9'),_0xbdadb1);})[_0x16ebe3('0x15')](function(_0x5b5437){const _0x79e54=_0x16ebe3;logger[_0x79e54('0x29')](JSON[_0x79e54('0x10')](_0x5b5437));});});},Migration[_0x2d4064('0xb')][_0x2d4064('0x6')]=function(_0xdf49de,_0x12e2d4){const _0x498901=_0x2d4064,_0x28fbc7=this;this[_0x498901('0x13')][_0x498901('0x1a')](function(){const _0x17d3e1=_0x498901;return _0x28fbc7['queryInterface']['removeColumn'](_0xdf49de,_0x12e2d4)[_0x17d3e1('0x23')](function(){const _0x13f4be=_0x17d3e1;logger[_0x13f4be('0x29')](_0x13f4be('0x1e'),_0x12e2d4,_0xdf49de);})['catch'](function(_0x40f87e){const _0xf2919f=_0x17d3e1;logger['info'](util[_0xf2919f('0x26')](_0x40f87e,{'showHidden':![],'depth':null}));});});},Migration[_0x2d4064('0xb')][_0x2d4064('0x2c')]=function(_0x1088c0,_0xcf9705,_0x4279fb){const _0x6811d0=_0x2d4064,_0xf19120=this;this['sequence'][_0x6811d0('0x1a')](function(){const _0x2c2275=_0x6811d0;return _0xf19120[_0x2c2275('0x27')][_0x2c2275('0x2c')](_0x1088c0,_0xcf9705,_0x4279fb)[_0x2c2275('0x23')](function(){const _0x538345=_0x2c2275;logger[_0x538345('0x29')](_0x538345('0x1f'),_0xcf9705,_0x4279fb,_0x1088c0);})[_0x2c2275('0x15')](function(_0x44dc9d){const _0x592c5a=_0x2c2275;logger[_0x592c5a('0x29')](util[_0x592c5a('0x26')](_0x44dc9d,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x2d4064('0x2a')]=function(_0xfb9cd6){const _0x1faf13=_0x2d4064;this[_0x1faf13('0x13')]['enqueue'](function(){return _0xfb9cd6();});},module[_0x2d4064('0x0')]={'up':function(_0x330da7,_0x1b9cb0){return new Promise(function(_0x3f95b){const _0x733b62=a965_0x19f9,_0x1620f8=new Migration(_0x330da7);_0x1620f8[_0x733b62('0xe')](_0x733b62('0x22'),_0x733b62('0x1c'),{'type':_0x1b9cb0[_0x733b62('0x2b')](_0x733b62('0x5'),_0x733b62('0x18'),_0x733b62('0x2d'),_0x733b62('0xc'),_0x733b62('0x1b'),_0x733b62('0x1d'),_0x733b62('0x16'),'infobip',_0x733b62('0x8'))}),_0x1620f8['changeColumn'](_0x733b62('0x28'),'phoneBarListenPort',{'type':_0x1b9cb0[_0x733b62('0xf')](0x5),'defaultValue':0x1428}),_0x1620f8[_0x733b62('0x2a')](_0x3f95b);});},'down':function(){}}; \ No newline at end of file +const a965_0x380c=['join','sequelize','phoneBarListenPort','type','renameColumn','../config/logger','table\x20dropped\x20%s','addIndex\x20%s\x20%s\x20%s','twilio','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','final','Changed\x20column\x20%s\x20in\x20table\x20%s','query\x20%s','queryInterface','addColumn','ENUM','removeColumn','then','infobip','util','prototype','query','removeIndex','addIndex','skebby','connectel','info','tail','changeColumn','enqueue','sms_accounts','catch','finally','clickatell','clicksend','INTEGER','stringify','Removed\x20column\x20%s\x20from\x20%s','sequence','inspect','dropTable'];(function(_0x2b9544,_0x380ca7){const _0x4d3f55=function(_0x46aaa1){while(--_0x46aaa1){_0x2b9544['push'](_0x2b9544['shift']());}};_0x4d3f55(++_0x380ca7);}(a965_0x380c,0x105));const a965_0x4d3f=function(_0x2b9544,_0x380ca7){_0x2b9544=_0x2b9544-0x0;let _0x4d3f55=a965_0x380c[_0x2b9544];return _0x4d3f55;};const _0x38f564=a965_0x4d3f;'use strict';const util=require(_0x38f564('0x4')),logger=require(_0x38f564('0x1f'))('migration'),Sequence=function(){};Sequence[_0x38f564('0x5')][_0x38f564('0xe')]=function(_0x46aaa1){const _0x115201=_0x38f564;this[_0x115201('0xc')]=this[_0x115201('0xc')]?this['tail'][_0x115201('0x11')](_0x46aaa1):_0x46aaa1();};const Migration=function(_0x50ddd1){const _0x44ec2d=_0x38f564;this[_0x44ec2d('0x27')]=_0x50ddd1,this['sequence']=new Sequence();};Migration['prototype'][_0x38f564('0xd')]=function(_0x539ecc,_0x4488c2,_0x567950){const _0x5e8d22=_0x38f564,_0x416fc9=this;this[_0x5e8d22('0x17')]['enqueue'](function(){const _0x41c1ee=_0x5e8d22;return _0x416fc9[_0x41c1ee('0x27')][_0x41c1ee('0xd')](_0x539ecc,_0x4488c2,_0x567950)[_0x41c1ee('0x2')](function(){const _0x1dd274=_0x41c1ee;logger['info'](_0x1dd274('0x25'),_0x4488c2,_0x539ecc);})[_0x41c1ee('0x10')](function(_0x5076f3){const _0x11ede3=_0x41c1ee;logger[_0x11ede3('0xb')](JSON[_0x11ede3('0x15')](_0x5076f3));});});},Migration[_0x38f564('0x5')][_0x38f564('0x28')]=function(_0x30cdcd,_0x477703,_0x4c4c94){const _0x578b65=_0x38f564,_0xaefc7=this;this[_0x578b65('0x17')][_0x578b65('0xe')](function(){const _0x257a6e=_0x578b65;return _0xaefc7[_0x257a6e('0x27')][_0x257a6e('0x28')](_0x30cdcd,_0x477703,_0x4c4c94)[_0x257a6e('0x2')](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x477703,_0x30cdcd);})[_0x257a6e('0x10')](function(_0x3826eb){const _0x18d691=_0x257a6e;logger[_0x18d691('0xb')](JSON['stringify'](_0x3826eb));});});},Migration[_0x38f564('0x5')][_0x38f564('0x19')]=function(_0x423347){const _0x9e096d=_0x38f564,_0x1f2ff3=this;this[_0x9e096d('0x17')]['enqueue'](function(){const _0x549590=_0x9e096d;return _0x1f2ff3['queryInterface']['dropTable'](_0x423347,{'force':!![]})[_0x549590('0x2')](function(){const _0x557003=_0x549590;logger['info'](_0x557003('0x20'),_0x423347);})[_0x549590('0x10')](function(_0x3519ce){const _0x25bfe6=_0x549590;logger[_0x25bfe6('0xb')](JSON[_0x25bfe6('0x15')](_0x3519ce));});});},Migration[_0x38f564('0x5')][_0x38f564('0x8')]=function(_0x3145a1,_0x5b7992,_0x32fb20){const _0x1e9224=_0x38f564,_0x13622e=this;this[_0x1e9224('0x17')][_0x1e9224('0xe')](function(){const _0x7fd5e1=_0x1e9224;return _0x13622e[_0x7fd5e1('0x27')][_0x7fd5e1('0x8')](_0x3145a1,_0x5b7992,{'indexName':_0x32fb20})[_0x7fd5e1('0x2')](function(){const _0x3b27bf=_0x7fd5e1;logger['info'](_0x3b27bf('0x21'),_0x3145a1,_0x5b7992[_0x3b27bf('0x1a')](','),_0x32fb20);})[_0x7fd5e1('0x10')](function(_0x5c3af0){const _0x425f38=_0x7fd5e1;logger[_0x425f38('0xb')](JSON['stringify'](_0x5c3af0));});});},Migration[_0x38f564('0x5')][_0x38f564('0x7')]=function(_0xfdf798,_0x45b541){const _0xd543df=_0x38f564,_0x1da39e=this;this[_0xd543df('0x17')][_0xd543df('0xe')](function(){const _0x58274d=_0xd543df;return _0x1da39e['queryInterface'][_0x58274d('0x7')](_0xfdf798,_0x45b541)[_0x58274d('0x2')](function(){const _0x41ece0=_0x58274d;logger[_0x41ece0('0xb')]('removeIndex\x20%s\x20%s',_0xfdf798,_0x45b541);})[_0x58274d('0x10')](function(_0xa4b7b2){const _0x453dcf=_0x58274d;logger[_0x453dcf('0xb')](JSON[_0x453dcf('0x15')](_0xa4b7b2));});});},Migration[_0x38f564('0x5')]['query']=function(_0x4791c2){const _0x5bee0d=_0x38f564,_0x65439=this;this[_0x5bee0d('0x17')][_0x5bee0d('0xe')](function(){const _0x205ecb=_0x5bee0d;return _0x65439[_0x205ecb('0x27')][_0x205ecb('0x1b')][_0x205ecb('0x6')](_0x4791c2)[_0x205ecb('0x2')](function(){const _0x3d6ac6=_0x205ecb;logger[_0x3d6ac6('0xb')](_0x3d6ac6('0x26'),_0x4791c2);})[_0x205ecb('0x10')](function(_0x41b252){const _0x20c888=_0x205ecb;logger[_0x20c888('0xb')](JSON[_0x20c888('0x15')](_0x41b252));});});},Migration[_0x38f564('0x5')][_0x38f564('0x1')]=function(_0x46a2df,_0x4ef425){const _0x4157af=_0x38f564,_0x2a26f6=this;this['sequence'][_0x4157af('0xe')](function(){const _0x2db403=_0x4157af;return _0x2a26f6['queryInterface'][_0x2db403('0x1')](_0x46a2df,_0x4ef425)['then'](function(){const _0x4b6ae7=_0x2db403;logger['info'](_0x4b6ae7('0x16'),_0x4ef425,_0x46a2df);})[_0x2db403('0x10')](function(_0xeed64e){const _0x15d904=_0x2db403;logger[_0x15d904('0xb')](util[_0x15d904('0x18')](_0xeed64e,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x38f564('0x1e')]=function(_0x492c3a,_0x338d06,_0x51a594){const _0xd9ee9a=_0x38f564,_0x6e3f67=this;this[_0xd9ee9a('0x17')][_0xd9ee9a('0xe')](function(){const _0x53ee80=_0xd9ee9a;return _0x6e3f67[_0x53ee80('0x27')][_0x53ee80('0x1e')](_0x492c3a,_0x338d06,_0x51a594)['then'](function(){const _0x11d876=_0x53ee80;logger[_0x11d876('0xb')](_0x11d876('0x23'),_0x338d06,_0x51a594,_0x492c3a);})[_0x53ee80('0x10')](function(_0x5449bc){const _0x8c9971=_0x53ee80;logger['info'](util[_0x8c9971('0x18')](_0x5449bc,{'showHidden':![],'depth':null}));});});},Migration[_0x38f564('0x5')][_0x38f564('0x24')]=function(_0x1feccd){const _0xf5408=_0x38f564;this[_0xf5408('0x17')][_0xf5408('0xe')](function(){return _0x1feccd();});},module['exports']={'up':function(_0x14faaf,_0x495522){return new Promise(function(_0x248414){const _0xd742f5=a965_0x4d3f,_0x289ae6=new Migration(_0x14faaf);_0x289ae6[_0xd742f5('0xd')](_0xd742f5('0xf'),_0xd742f5('0x1d'),{'type':_0x495522[_0xd742f5('0x0')](_0xd742f5('0x22'),_0xd742f5('0x9'),_0xd742f5('0xa'),_0xd742f5('0x13'),'plivo',_0xd742f5('0x12'),'csc',_0xd742f5('0x3'),'intelepeer')}),_0x289ae6['changeColumn']('users',_0xd742f5('0x1c'),{'type':_0x495522[_0xd742f5('0x14')](0x5),'defaultValue':0x1428}),_0x289ae6[_0xd742f5('0x24')](_0x248414);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.2.1.js b/server/migrations/2.2.1.js index 6ccca35..80271a4 100644 --- a/server/migrations/2.2.1.js +++ b/server/migrations/2.2.1.js @@ -1 +1 @@ -const a966_0x1807=['queryInterface','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','tail','Added\x20column\x20%s\x20to\x20%s','inspect','query\x20%s','final','dropTable','../config/logger','join','prototype','then','exports','util','table\x20dropped\x20%s','addColumn','removeColumn','finally','renameColumn','stringify','changeColumn','removeIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','sequence','enqueue','catch','addIndex','addIndex\x20%s\x20%s\x20%s','migration','sequelize','Removed\x20column\x20%s\x20from\x20%s','info'];(function(_0x5e58e2,_0x180773){const _0x5074b4=function(_0x6115fb){while(--_0x6115fb){_0x5e58e2['push'](_0x5e58e2['shift']());}};_0x5074b4(++_0x180773);}(a966_0x1807,0x67));const a966_0x5074=function(_0x5e58e2,_0x180773){_0x5e58e2=_0x5e58e2-0x0;let _0x5074b4=a966_0x1807[_0x5e58e2];return _0x5074b4;};const _0x295df7=a966_0x5074;'use strict';const util=require(_0x295df7('0x6')),logger=require(_0x295df7('0x1'))(_0x295df7('0x15')),Sequence=function(){};Sequence[_0x295df7('0x3')][_0x295df7('0x11')]=function(_0x6115fb){const _0x27a38c=_0x295df7;this[_0x27a38c('0x1b')]=this[_0x27a38c('0x1b')]?this[_0x27a38c('0x1b')][_0x27a38c('0xa')](_0x6115fb):_0x6115fb();};const Migration=function(_0x3f36a5){const _0x9b6a70=_0x295df7;this['queryInterface']=_0x3f36a5,this[_0x9b6a70('0x10')]=new Sequence();};Migration[_0x295df7('0x3')]['changeColumn']=function(_0x867a47,_0x5e7275,_0x3193a9){const _0x590052=_0x295df7,_0x112b1c=this;this[_0x590052('0x10')][_0x590052('0x11')](function(){const _0x403ee3=_0x590052;return _0x112b1c[_0x403ee3('0x19')][_0x403ee3('0xd')](_0x867a47,_0x5e7275,_0x3193a9)['then'](function(){const _0x4b4e10=_0x403ee3;logger[_0x4b4e10('0x18')](_0x4b4e10('0xf'),_0x5e7275,_0x867a47);})['catch'](function(_0xbdfb95){const _0x5e5a6c=_0x403ee3;logger[_0x5e5a6c('0x18')](JSON['stringify'](_0xbdfb95));});});},Migration['prototype']['addColumn']=function(_0x349b39,_0x6d1875,_0x119f76){const _0x74f921=_0x295df7,_0x5ede3c=this;this[_0x74f921('0x10')][_0x74f921('0x11')](function(){const _0x1f6593=_0x74f921;return _0x5ede3c[_0x1f6593('0x19')][_0x1f6593('0x8')](_0x349b39,_0x6d1875,_0x119f76)[_0x1f6593('0x4')](function(){const _0x3ded48=_0x1f6593;logger[_0x3ded48('0x18')](_0x3ded48('0x1c'),_0x6d1875,_0x349b39);})[_0x1f6593('0x12')](function(_0x5afdeb){const _0x3dda5e=_0x1f6593;logger[_0x3dda5e('0x18')](JSON[_0x3dda5e('0xc')](_0x5afdeb));});});},Migration[_0x295df7('0x3')][_0x295df7('0x0')]=function(_0x1bcab1){const _0x404603=_0x295df7,_0x3579ff=this;this['sequence'][_0x404603('0x11')](function(){const _0x19bf57=_0x404603;return _0x3579ff[_0x19bf57('0x19')][_0x19bf57('0x0')](_0x1bcab1,{'force':!![]})[_0x19bf57('0x4')](function(){const _0x28f19f=_0x19bf57;logger[_0x28f19f('0x18')](_0x28f19f('0x7'),_0x1bcab1);})[_0x19bf57('0x12')](function(_0x4b37cc){const _0x427508=_0x19bf57;logger[_0x427508('0x18')](JSON[_0x427508('0xc')](_0x4b37cc));});});},Migration['prototype']['addIndex']=function(_0x57161b,_0x13eca3,_0x1b2e72){const _0x547257=_0x295df7,_0x4c2aca=this;this[_0x547257('0x10')]['enqueue'](function(){const _0x4b0d8c=_0x547257;return _0x4c2aca[_0x4b0d8c('0x19')][_0x4b0d8c('0x13')](_0x57161b,_0x13eca3,{'indexName':_0x1b2e72})[_0x4b0d8c('0x4')](function(){const _0x735a2=_0x4b0d8c;logger[_0x735a2('0x18')](_0x735a2('0x14'),_0x57161b,_0x13eca3[_0x735a2('0x2')](','),_0x1b2e72);})['catch'](function(_0x20fa9c){const _0x46e9d0=_0x4b0d8c;logger[_0x46e9d0('0x18')](JSON['stringify'](_0x20fa9c));});});},Migration[_0x295df7('0x3')][_0x295df7('0xe')]=function(_0x1aebe7,_0x29254a){const _0x511614=_0x295df7,_0xcfffd7=this;this[_0x511614('0x10')][_0x511614('0x11')](function(){const _0x42f7e4=_0x511614;return _0xcfffd7[_0x42f7e4('0x19')][_0x42f7e4('0xe')](_0x1aebe7,_0x29254a)[_0x42f7e4('0x4')](function(){const _0x5b31e5=_0x42f7e4;logger[_0x5b31e5('0x18')]('removeIndex\x20%s\x20%s',_0x1aebe7,_0x29254a);})[_0x42f7e4('0x12')](function(_0x27aa13){const _0x435727=_0x42f7e4;logger['info'](JSON[_0x435727('0xc')](_0x27aa13));});});},Migration['prototype']['query']=function(_0xd3b4dd){const _0x24f30a=_0x295df7,_0xe45da8=this;this[_0x24f30a('0x10')]['enqueue'](function(){const _0x8e14aa=_0x24f30a;return _0xe45da8[_0x8e14aa('0x19')][_0x8e14aa('0x16')]['query'](_0xd3b4dd)[_0x8e14aa('0x4')](function(){const _0xd17fad=_0x8e14aa;logger['info'](_0xd17fad('0x1e'),_0xd3b4dd);})['catch'](function(_0x2b5065){const _0x46e713=_0x8e14aa;logger[_0x46e713('0x18')](JSON['stringify'](_0x2b5065));});});},Migration['prototype']['removeColumn']=function(_0x1b17fc,_0x5eecaa){const _0x19dbc4=_0x295df7,_0x2a567b=this;this[_0x19dbc4('0x10')][_0x19dbc4('0x11')](function(){const _0x1c8dd5=_0x19dbc4;return _0x2a567b[_0x1c8dd5('0x19')][_0x1c8dd5('0x9')](_0x1b17fc,_0x5eecaa)['then'](function(){const _0x41572e=_0x1c8dd5;logger[_0x41572e('0x18')](_0x41572e('0x17'),_0x5eecaa,_0x1b17fc);})[_0x1c8dd5('0x12')](function(_0xfb8a6f){const _0x304db0=_0x1c8dd5;logger['info'](util[_0x304db0('0x1d')](_0xfb8a6f,{'showHidden':![],'depth':null}));});});},Migration[_0x295df7('0x3')][_0x295df7('0xb')]=function(_0x19b5b9,_0x342b81,_0x370c49){const _0x262967=_0x295df7,_0x12d612=this;this[_0x262967('0x10')][_0x262967('0x11')](function(){const _0x2d5d9d=_0x262967;return _0x12d612['queryInterface'][_0x2d5d9d('0xb')](_0x19b5b9,_0x342b81,_0x370c49)['then'](function(){const _0xb53a9e=_0x2d5d9d;logger[_0xb53a9e('0x18')](_0xb53a9e('0x1a'),_0x342b81,_0x370c49,_0x19b5b9);})[_0x2d5d9d('0x12')](function(_0x3d0587){const _0x1cb672=_0x2d5d9d;logger[_0x1cb672('0x18')](util[_0x1cb672('0x1d')](_0x3d0587,{'showHidden':![],'depth':null}));});});},Migration[_0x295df7('0x3')][_0x295df7('0x1f')]=function(_0x53550d){const _0x3682c2=_0x295df7;this[_0x3682c2('0x10')]['enqueue'](function(){return _0x53550d();});},module[_0x295df7('0x5')]={'up':function(_0x55db51){return new Promise(function(_0x23c814){const _0xbc0836=a966_0x5074,_0x10b1cc=new Migration(_0x55db51);_0x10b1cc[_0xbc0836('0x1f')](_0x23c814);});},'down':function(){}}; \ No newline at end of file +const a966_0x2d2f=['query\x20%s','addColumn','renameColumn','removeColumn','dropTable','queryInterface','final','finally','stringify','prototype','tail','info','table\x20dropped\x20%s','util','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex','inspect','Changed\x20column\x20%s\x20in\x20table\x20%s','enqueue','then','changeColumn','exports','sequence','removeIndex','sequelize','removeIndex\x20%s\x20%s','query','Added\x20column\x20%s\x20to\x20%s','catch','migration'];(function(_0x2cb56e,_0x2d2ff8){const _0x7a77bf=function(_0x1707ef){while(--_0x1707ef){_0x2cb56e['push'](_0x2cb56e['shift']());}};_0x7a77bf(++_0x2d2ff8);}(a966_0x2d2f,0xee));const a966_0x7a77=function(_0x2cb56e,_0x2d2ff8){_0x2cb56e=_0x2cb56e-0x0;let _0x7a77bf=a966_0x2d2f[_0x2cb56e];return _0x7a77bf;};const _0x3c1663=a966_0x7a77;'use strict';const util=require(_0x3c1663('0xf')),logger=require('../config/logger')(_0x3c1663('0x1')),Sequence=function(){};Sequence[_0x3c1663('0xb')]['enqueue']=function(_0x1707ef){const _0x1601cb=_0x3c1663;this[_0x1601cb('0xc')]=this[_0x1601cb('0xc')]?this['tail'][_0x1601cb('0x9')](_0x1707ef):_0x1707ef();};const Migration=function(_0x32fe60){const _0x428428=_0x3c1663;this[_0x428428('0x7')]=_0x32fe60,this[_0x428428('0x18')]=new Sequence();};Migration['prototype'][_0x3c1663('0x16')]=function(_0x37dc42,_0x3d53ad,_0x41ea38){const _0x1f0f07=_0x3c1663,_0x5685be=this;this[_0x1f0f07('0x18')]['enqueue'](function(){const _0x484f1c=_0x1f0f07;return _0x5685be[_0x484f1c('0x7')][_0x484f1c('0x16')](_0x37dc42,_0x3d53ad,_0x41ea38)['then'](function(){const _0x4d87b9=_0x484f1c;logger[_0x4d87b9('0xd')](_0x4d87b9('0x13'),_0x3d53ad,_0x37dc42);})[_0x484f1c('0x0')](function(_0x2086e2){const _0x2f7fb4=_0x484f1c;logger['info'](JSON[_0x2f7fb4('0xa')](_0x2086e2));});});},Migration['prototype'][_0x3c1663('0x3')]=function(_0x21b842,_0xe358c5,_0x5905b6){const _0x5582b9=_0x3c1663,_0x15b1c5=this;this[_0x5582b9('0x18')][_0x5582b9('0x14')](function(){const _0x3a3149=_0x5582b9;return _0x15b1c5['queryInterface'][_0x3a3149('0x3')](_0x21b842,_0xe358c5,_0x5905b6)['then'](function(){const _0x13dcf0=_0x3a3149;logger[_0x13dcf0('0xd')](_0x13dcf0('0x1d'),_0xe358c5,_0x21b842);})[_0x3a3149('0x0')](function(_0x1b4886){const _0x27d42b=_0x3a3149;logger[_0x27d42b('0xd')](JSON[_0x27d42b('0xa')](_0x1b4886));});});},Migration['prototype'][_0x3c1663('0x6')]=function(_0x224a3e){const _0x2105a4=_0x3c1663,_0x1e701a=this;this[_0x2105a4('0x18')][_0x2105a4('0x14')](function(){const _0x15e339=_0x2105a4;return _0x1e701a[_0x15e339('0x7')][_0x15e339('0x6')](_0x224a3e,{'force':!![]})[_0x15e339('0x15')](function(){const _0x688dc8=_0x15e339;logger[_0x688dc8('0xd')](_0x688dc8('0xe'),_0x224a3e);})[_0x15e339('0x0')](function(_0x32047a){const _0x9d2c3d=_0x15e339;logger[_0x9d2c3d('0xd')](JSON[_0x9d2c3d('0xa')](_0x32047a));});});},Migration['prototype'][_0x3c1663('0x11')]=function(_0x4ba39c,_0x920768,_0x338f4c){const _0x12eabc=_0x3c1663,_0x17760c=this;this[_0x12eabc('0x18')][_0x12eabc('0x14')](function(){const _0x170709=_0x12eabc;return _0x17760c[_0x170709('0x7')][_0x170709('0x11')](_0x4ba39c,_0x920768,{'indexName':_0x338f4c})[_0x170709('0x15')](function(){logger['info']('addIndex\x20%s\x20%s\x20%s',_0x4ba39c,_0x920768['join'](','),_0x338f4c);})[_0x170709('0x0')](function(_0x896921){const _0xa4663b=_0x170709;logger[_0xa4663b('0xd')](JSON[_0xa4663b('0xa')](_0x896921));});});},Migration['prototype']['removeIndex']=function(_0x1b7b93,_0x29a180){const _0x1c3399=_0x3c1663,_0xe14c9c=this;this[_0x1c3399('0x18')][_0x1c3399('0x14')](function(){const _0x199bc7=_0x1c3399;return _0xe14c9c[_0x199bc7('0x7')][_0x199bc7('0x19')](_0x1b7b93,_0x29a180)[_0x199bc7('0x15')](function(){const _0x55fc5c=_0x199bc7;logger[_0x55fc5c('0xd')](_0x55fc5c('0x1b'),_0x1b7b93,_0x29a180);})[_0x199bc7('0x0')](function(_0x3e462f){const _0x10a6d0=_0x199bc7;logger['info'](JSON[_0x10a6d0('0xa')](_0x3e462f));});});},Migration['prototype'][_0x3c1663('0x1c')]=function(_0x34238c){const _0x38136c=_0x3c1663,_0x3b6dcd=this;this[_0x38136c('0x18')][_0x38136c('0x14')](function(){const _0x44d830=_0x38136c;return _0x3b6dcd['queryInterface'][_0x44d830('0x1a')][_0x44d830('0x1c')](_0x34238c)['then'](function(){const _0x1387fc=_0x44d830;logger[_0x1387fc('0xd')](_0x1387fc('0x2'),_0x34238c);})[_0x44d830('0x0')](function(_0x187c2f){const _0x1cdbd9=_0x44d830;logger[_0x1cdbd9('0xd')](JSON['stringify'](_0x187c2f));});});},Migration[_0x3c1663('0xb')]['removeColumn']=function(_0x255c65,_0x32c394){const _0x46a273=_0x3c1663,_0x3f4b9f=this;this[_0x46a273('0x18')][_0x46a273('0x14')](function(){const _0x446e5f=_0x46a273;return _0x3f4b9f['queryInterface'][_0x446e5f('0x5')](_0x255c65,_0x32c394)[_0x446e5f('0x15')](function(){const _0x37d9d8=_0x446e5f;logger[_0x37d9d8('0xd')]('Removed\x20column\x20%s\x20from\x20%s',_0x32c394,_0x255c65);})[_0x446e5f('0x0')](function(_0xfe060){const _0x1a73b9=_0x446e5f;logger['info'](util[_0x1a73b9('0x12')](_0xfe060,{'showHidden':![],'depth':null}));});});},Migration[_0x3c1663('0xb')][_0x3c1663('0x4')]=function(_0x1ec8b9,_0x553c30,_0x5d28f6){const _0x2bbd13=_0x3c1663,_0x46c856=this;this[_0x2bbd13('0x18')][_0x2bbd13('0x14')](function(){const _0x2ff728=_0x2bbd13;return _0x46c856[_0x2ff728('0x7')]['renameColumn'](_0x1ec8b9,_0x553c30,_0x5d28f6)[_0x2ff728('0x15')](function(){const _0x5f1599=_0x2ff728;logger[_0x5f1599('0xd')](_0x5f1599('0x10'),_0x553c30,_0x5d28f6,_0x1ec8b9);})[_0x2ff728('0x0')](function(_0x59cc39){const _0x57c64a=_0x2ff728;logger[_0x57c64a('0xd')](util[_0x57c64a('0x12')](_0x59cc39,{'showHidden':![],'depth':null}));});});},Migration[_0x3c1663('0xb')][_0x3c1663('0x8')]=function(_0x433e3c){this['sequence']['enqueue'](function(){return _0x433e3c();});},module[_0x3c1663('0x17')]={'up':function(_0x2bbc26){return new Promise(function(_0x909253){const _0x39f6a4=a966_0x7a77,_0x1ac4ba=new Migration(_0x2bbc26);_0x1ac4ba[_0x39f6a4('0x8')](_0x909253);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.2.2.js b/server/migrations/2.2.2.js index d1c0683..a01a058 100644 --- a/server/migrations/2.2.2.js +++ b/server/migrations/2.2.2.js @@ -1 +1 @@ -const a967_0x8b26=['Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','stringify','../config/logger','Changed\x20column\x20%s\x20in\x20table\x20%s','catch','then','Removed\x20column\x20%s\x20from\x20%s','info','addIndex','sequence','prototype','finally','queryInterface','tail','removeColumn','inspect','removeIndex','join','query\x20%s','renameColumn','Added\x20column\x20%s\x20to\x20%s','addColumn','enqueue','final','util','table\x20dropped\x20%s','exports','query'];(function(_0x4a20bc,_0x8b26f3){const _0x5b27af=function(_0x13f08e){while(--_0x13f08e){_0x4a20bc['push'](_0x4a20bc['shift']());}};_0x5b27af(++_0x8b26f3);}(a967_0x8b26,0xb7));const a967_0x5b27=function(_0x4a20bc,_0x8b26f3){_0x4a20bc=_0x4a20bc-0x0;let _0x5b27af=a967_0x8b26[_0x4a20bc];return _0x5b27af;};const _0x1cec38=a967_0x5b27;'use strict';const util=require(_0x1cec38('0x9')),logger=require(_0x1cec38('0xf'))('migration'),Sequence=function(){};Sequence[_0x1cec38('0x17')][_0x1cec38('0x7')]=function(_0x13f08e){const _0x2fdf51=_0x1cec38;this['tail']=this[_0x2fdf51('0x1a')]?this['tail'][_0x2fdf51('0x18')](_0x13f08e):_0x13f08e();};const Migration=function(_0x384e19){const _0x442342=_0x1cec38;this[_0x442342('0x19')]=_0x384e19,this[_0x442342('0x16')]=new Sequence();};Migration[_0x1cec38('0x17')]['changeColumn']=function(_0x2eb9c1,_0x23a9c2,_0x5357eb){const _0x3fde7e=_0x1cec38,_0x281f88=this;this[_0x3fde7e('0x16')]['enqueue'](function(){const _0x1dcb14=_0x3fde7e;return _0x281f88[_0x1dcb14('0x19')]['changeColumn'](_0x2eb9c1,_0x23a9c2,_0x5357eb)[_0x1dcb14('0x12')](function(){const _0x3365a8=_0x1dcb14;logger[_0x3365a8('0x14')](_0x3365a8('0x10'),_0x23a9c2,_0x2eb9c1);})['catch'](function(_0x14dab7){const _0x426353=_0x1dcb14;logger[_0x426353('0x14')](JSON[_0x426353('0xe')](_0x14dab7));});});},Migration[_0x1cec38('0x17')]['addColumn']=function(_0x1dfda3,_0x1d7f29,_0x4d14a3){const _0x23ae6a=_0x1cec38,_0x47c0d4=this;this[_0x23ae6a('0x16')]['enqueue'](function(){const _0x113ebb=_0x23ae6a;return _0x47c0d4[_0x113ebb('0x19')][_0x113ebb('0x6')](_0x1dfda3,_0x1d7f29,_0x4d14a3)[_0x113ebb('0x12')](function(){const _0x184804=_0x113ebb;logger['info'](_0x184804('0x5'),_0x1d7f29,_0x1dfda3);})[_0x113ebb('0x11')](function(_0x11027d){const _0x36f43f=_0x113ebb;logger[_0x36f43f('0x14')](JSON['stringify'](_0x11027d));});});},Migration['prototype']['dropTable']=function(_0x1f0729){const _0x22d785=_0x1cec38,_0x56296e=this;this[_0x22d785('0x16')][_0x22d785('0x7')](function(){const _0x6ff9c8=_0x22d785;return _0x56296e[_0x6ff9c8('0x19')]['dropTable'](_0x1f0729,{'force':!![]})[_0x6ff9c8('0x12')](function(){const _0x114ed2=_0x6ff9c8;logger[_0x114ed2('0x14')](_0x114ed2('0xa'),_0x1f0729);})['catch'](function(_0x2b2724){const _0xe72d1b=_0x6ff9c8;logger['info'](JSON[_0xe72d1b('0xe')](_0x2b2724));});});},Migration[_0x1cec38('0x17')]['addIndex']=function(_0x53dd1f,_0x2ee2ac,_0x124f0c){const _0xfe02cd=_0x1cec38,_0x1c2712=this;this[_0xfe02cd('0x16')][_0xfe02cd('0x7')](function(){const _0x305d81=_0xfe02cd;return _0x1c2712[_0x305d81('0x19')][_0x305d81('0x15')](_0x53dd1f,_0x2ee2ac,{'indexName':_0x124f0c})['then'](function(){const _0x3effc8=_0x305d81;logger['info']('addIndex\x20%s\x20%s\x20%s',_0x53dd1f,_0x2ee2ac[_0x3effc8('0x2')](','),_0x124f0c);})[_0x305d81('0x11')](function(_0x5c5761){const _0x53db87=_0x305d81;logger[_0x53db87('0x14')](JSON[_0x53db87('0xe')](_0x5c5761));});});},Migration[_0x1cec38('0x17')][_0x1cec38('0x1')]=function(_0x8ad7a2,_0x16d009){const _0x3a0547=_0x1cec38,_0x458579=this;this[_0x3a0547('0x16')][_0x3a0547('0x7')](function(){const _0xdfbbf=_0x3a0547;return _0x458579[_0xdfbbf('0x19')]['removeIndex'](_0x8ad7a2,_0x16d009)[_0xdfbbf('0x12')](function(){const _0x23320e=_0xdfbbf;logger[_0x23320e('0x14')]('removeIndex\x20%s\x20%s',_0x8ad7a2,_0x16d009);})[_0xdfbbf('0x11')](function(_0x334545){const _0x4cd752=_0xdfbbf;logger['info'](JSON[_0x4cd752('0xe')](_0x334545));});});},Migration['prototype'][_0x1cec38('0xc')]=function(_0x3ee0c0){const _0x4a139c=this;this['sequence']['enqueue'](function(){const _0x3054ae=a967_0x5b27;return _0x4a139c[_0x3054ae('0x19')]['sequelize'][_0x3054ae('0xc')](_0x3ee0c0)[_0x3054ae('0x12')](function(){const _0x80d5d2=_0x3054ae;logger[_0x80d5d2('0x14')](_0x80d5d2('0x3'),_0x3ee0c0);})[_0x3054ae('0x11')](function(_0x334be2){logger['info'](JSON['stringify'](_0x334be2));});});},Migration[_0x1cec38('0x17')][_0x1cec38('0x1b')]=function(_0x558b14,_0x54c8a5){const _0x4cd46c=_0x1cec38,_0x14ca10=this;this[_0x4cd46c('0x16')][_0x4cd46c('0x7')](function(){const _0x5c4a17=_0x4cd46c;return _0x14ca10[_0x5c4a17('0x19')][_0x5c4a17('0x1b')](_0x558b14,_0x54c8a5)[_0x5c4a17('0x12')](function(){const _0xd64b64=_0x5c4a17;logger['info'](_0xd64b64('0x13'),_0x54c8a5,_0x558b14);})[_0x5c4a17('0x11')](function(_0x33609c){const _0x5a3535=_0x5c4a17;logger[_0x5a3535('0x14')](util[_0x5a3535('0x0')](_0x33609c,{'showHidden':![],'depth':null}));});});},Migration[_0x1cec38('0x17')]['renameColumn']=function(_0x260dc5,_0xe43b6d,_0x2a2640){const _0x580ffe=_0x1cec38,_0x28ab0b=this;this[_0x580ffe('0x16')][_0x580ffe('0x7')](function(){const _0x313e0b=_0x580ffe;return _0x28ab0b['queryInterface'][_0x313e0b('0x4')](_0x260dc5,_0xe43b6d,_0x2a2640)[_0x313e0b('0x12')](function(){const _0x5c98f7=_0x313e0b;logger[_0x5c98f7('0x14')](_0x5c98f7('0xd'),_0xe43b6d,_0x2a2640,_0x260dc5);})[_0x313e0b('0x11')](function(_0x207000){const _0x3fbe91=_0x313e0b;logger['info'](util[_0x3fbe91('0x0')](_0x207000,{'showHidden':![],'depth':null}));});});},Migration[_0x1cec38('0x17')][_0x1cec38('0x8')]=function(_0x5e82ca){const _0x2ae316=_0x1cec38;this[_0x2ae316('0x16')][_0x2ae316('0x7')](function(){return _0x5e82ca();});},module[_0x1cec38('0xb')]={'up':function(_0x4fa34d){return new Promise(function(_0x4d36b2){const _0x55f866=a967_0x5b27,_0x54afee=new Migration(_0x4fa34d);_0x54afee[_0x55f866('0x8')](_0x4d36b2);});},'down':function(){}}; \ No newline at end of file +const a967_0x38fb=['queryInterface','migration','sequence','addColumn','tail','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex','inspect','sequelize','query','Removed\x20column\x20%s\x20from\x20%s','table\x20dropped\x20%s','enqueue','../config/logger','query\x20%s','join','addIndex\x20%s\x20%s\x20%s','then','dropTable','final','catch','prototype','info','stringify','Changed\x20column\x20%s\x20in\x20table\x20%s','renameColumn','removeIndex','changeColumn'];(function(_0x494778,_0x38fb57){const _0x1da532=function(_0x39ab37){while(--_0x39ab37){_0x494778['push'](_0x494778['shift']());}};_0x1da532(++_0x38fb57);}(a967_0x38fb,0x1a7));const a967_0x1da5=function(_0x494778,_0x38fb57){_0x494778=_0x494778-0x0;let _0x1da532=a967_0x38fb[_0x494778];return _0x1da532;};const _0xfc6e8=a967_0x1da5;'use strict';const util=require('util'),logger=require(_0xfc6e8('0xa'))(_0xfc6e8('0x1a')),Sequence=function(){};Sequence[_0xfc6e8('0x12')]['enqueue']=function(_0x39ab37){const _0x14fc14=_0xfc6e8;this['tail']=this[_0x14fc14('0x1')]?this['tail']['finally'](_0x39ab37):_0x39ab37();};const Migration=function(_0x3f7a13){const _0x3c5352=_0xfc6e8;this[_0x3c5352('0x19')]=_0x3f7a13,this[_0x3c5352('0x1b')]=new Sequence();};Migration[_0xfc6e8('0x12')]['changeColumn']=function(_0x4d580a,_0x19254a,_0x30fba3){const _0x17da64=_0xfc6e8,_0x50af52=this;this['sequence'][_0x17da64('0x9')](function(){const _0x461056=_0x17da64;return _0x50af52[_0x461056('0x19')][_0x461056('0x18')](_0x4d580a,_0x19254a,_0x30fba3)[_0x461056('0xe')](function(){const _0x59716e=_0x461056;logger[_0x59716e('0x13')](_0x59716e('0x15'),_0x19254a,_0x4d580a);})[_0x461056('0x11')](function(_0x1c88df){const _0x3999b0=_0x461056;logger[_0x3999b0('0x13')](JSON[_0x3999b0('0x14')](_0x1c88df));});});},Migration[_0xfc6e8('0x12')][_0xfc6e8('0x0')]=function(_0x251329,_0x227029,_0x5b07a9){const _0x28e2e0=_0xfc6e8,_0x381826=this;this[_0x28e2e0('0x1b')][_0x28e2e0('0x9')](function(){const _0x5ba514=_0x28e2e0;return _0x381826[_0x5ba514('0x19')][_0x5ba514('0x0')](_0x251329,_0x227029,_0x5b07a9)['then'](function(){const _0x48ec0a=_0x5ba514;logger[_0x48ec0a('0x13')]('Added\x20column\x20%s\x20to\x20%s',_0x227029,_0x251329);})[_0x5ba514('0x11')](function(_0x404ab2){const _0x113c93=_0x5ba514;logger['info'](JSON[_0x113c93('0x14')](_0x404ab2));});});},Migration['prototype']['dropTable']=function(_0x166a5d){const _0x7fb546=_0xfc6e8,_0x22324b=this;this[_0x7fb546('0x1b')][_0x7fb546('0x9')](function(){const _0x7610ed=_0x7fb546;return _0x22324b['queryInterface'][_0x7610ed('0xf')](_0x166a5d,{'force':!![]})[_0x7610ed('0xe')](function(){const _0x39916d=_0x7610ed;logger[_0x39916d('0x13')](_0x39916d('0x8'),_0x166a5d);})[_0x7610ed('0x11')](function(_0x344ad9){const _0x2b11c4=_0x7610ed;logger[_0x2b11c4('0x13')](JSON['stringify'](_0x344ad9));});});},Migration[_0xfc6e8('0x12')][_0xfc6e8('0x3')]=function(_0x4fcb4b,_0x42cdcc,_0x5c2500){const _0x562940=_0xfc6e8,_0x325ecd=this;this['sequence'][_0x562940('0x9')](function(){const _0x5ce207=_0x562940;return _0x325ecd[_0x5ce207('0x19')][_0x5ce207('0x3')](_0x4fcb4b,_0x42cdcc,{'indexName':_0x5c2500})['then'](function(){const _0x5da10b=_0x5ce207;logger['info'](_0x5da10b('0xd'),_0x4fcb4b,_0x42cdcc[_0x5da10b('0xc')](','),_0x5c2500);})['catch'](function(_0x3c5880){const _0x132adf=_0x5ce207;logger[_0x132adf('0x13')](JSON[_0x132adf('0x14')](_0x3c5880));});});},Migration[_0xfc6e8('0x12')][_0xfc6e8('0x17')]=function(_0x3d8379,_0x1c8bc4){const _0x2fa688=_0xfc6e8,_0x54d5b7=this;this[_0x2fa688('0x1b')]['enqueue'](function(){const _0x28f073=_0x2fa688;return _0x54d5b7[_0x28f073('0x19')][_0x28f073('0x17')](_0x3d8379,_0x1c8bc4)[_0x28f073('0xe')](function(){const _0x2fc19b=_0x28f073;logger[_0x2fc19b('0x13')]('removeIndex\x20%s\x20%s',_0x3d8379,_0x1c8bc4);})[_0x28f073('0x11')](function(_0x48f4c3){const _0xc0cf37=_0x28f073;logger[_0xc0cf37('0x13')](JSON['stringify'](_0x48f4c3));});});},Migration[_0xfc6e8('0x12')][_0xfc6e8('0x6')]=function(_0x9d234b){const _0x1b1f5b=_0xfc6e8,_0x16f53f=this;this[_0x1b1f5b('0x1b')][_0x1b1f5b('0x9')](function(){const _0x1ac0bf=_0x1b1f5b;return _0x16f53f[_0x1ac0bf('0x19')][_0x1ac0bf('0x5')]['query'](_0x9d234b)['then'](function(){const _0x4e8789=_0x1ac0bf;logger['info'](_0x4e8789('0xb'),_0x9d234b);})[_0x1ac0bf('0x11')](function(_0x415b10){const _0x261c8c=_0x1ac0bf;logger[_0x261c8c('0x13')](JSON[_0x261c8c('0x14')](_0x415b10));});});},Migration['prototype']['removeColumn']=function(_0x11528e,_0x17ba44){const _0x2eb727=_0xfc6e8,_0x4669f4=this;this[_0x2eb727('0x1b')][_0x2eb727('0x9')](function(){const _0x1911b=_0x2eb727;return _0x4669f4[_0x1911b('0x19')]['removeColumn'](_0x11528e,_0x17ba44)[_0x1911b('0xe')](function(){const _0x4c13bc=_0x1911b;logger[_0x4c13bc('0x13')](_0x4c13bc('0x7'),_0x17ba44,_0x11528e);})[_0x1911b('0x11')](function(_0x3585dd){const _0x22fb68=_0x1911b;logger[_0x22fb68('0x13')](util['inspect'](_0x3585dd,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0xfc6e8('0x16')]=function(_0x4a16bd,_0x1066be,_0x21009f){const _0x44b94f=_0xfc6e8,_0xf3287a=this;this[_0x44b94f('0x1b')]['enqueue'](function(){const _0x2bbfc5=_0x44b94f;return _0xf3287a[_0x2bbfc5('0x19')][_0x2bbfc5('0x16')](_0x4a16bd,_0x1066be,_0x21009f)['then'](function(){const _0x4122c6=_0x2bbfc5;logger[_0x4122c6('0x13')](_0x4122c6('0x2'),_0x1066be,_0x21009f,_0x4a16bd);})['catch'](function(_0x397891){const _0x25e1f4=_0x2bbfc5;logger['info'](util[_0x25e1f4('0x4')](_0x397891,{'showHidden':![],'depth':null}));});});},Migration[_0xfc6e8('0x12')]['final']=function(_0x12b9bc){const _0x188713=_0xfc6e8;this[_0x188713('0x1b')]['enqueue'](function(){return _0x12b9bc();});},module['exports']={'up':function(_0x3b418e){return new Promise(function(_0x453d17){const _0x4090f7=a967_0x1da5,_0x45cf19=new Migration(_0x3b418e);_0x45cf19[_0x4090f7('0x10')](_0x453d17);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.2.3.js b/server/migrations/2.2.3.js index 08c9c4e..059f88b 100644 --- a/server/migrations/2.2.3.js +++ b/server/migrations/2.2.3.js @@ -1 +1 @@ -const a968_0x17c4=['Added\x20column\x20%s\x20to\x20%s','removeIndex','then','stringify','addColumn','query\x20%s','renameColumn','inspect','addIndex\x20%s\x20%s\x20%s','migration','changeColumn','info','inReplyTo','removeColumn','tail','finally','catch','messageId','prototype','addIndex','mail_messages','STRING','sequence','query','table\x20dropped\x20%s','dropTable','sequelize','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','queryInterface','enqueue','Removed\x20column\x20%s\x20from\x20%s','final','join'];(function(_0x53caba,_0x17c489){const _0x31a80a=function(_0x45a187){while(--_0x45a187){_0x53caba['push'](_0x53caba['shift']());}};_0x31a80a(++_0x17c489);}(a968_0x17c4,0x154));const a968_0x31a8=function(_0x53caba,_0x17c489){_0x53caba=_0x53caba-0x0;let _0x31a80a=a968_0x17c4[_0x53caba];return _0x31a80a;};const _0xf023aa=a968_0x31a8;'use strict';const util=require('util'),logger=require('../config/logger')(_0xf023aa('0x20')),Sequence=function(){};Sequence['prototype'][_0xf023aa('0x13')]=function(_0x45a187){const _0x5a086c=_0xf023aa;this[_0x5a086c('0x4')]=this[_0x5a086c('0x4')]?this[_0x5a086c('0x4')][_0x5a086c('0x5')](_0x45a187):_0x45a187();};const Migration=function(_0x419e88){const _0x3a0d2d=_0xf023aa;this[_0x3a0d2d('0x12')]=_0x419e88,this[_0x3a0d2d('0xc')]=new Sequence();};Migration[_0xf023aa('0x8')][_0xf023aa('0x0')]=function(_0x26f4cc,_0x36dd2a,_0x1b8db1){const _0x320c1e=_0xf023aa,_0x37b8f4=this;this[_0x320c1e('0xc')]['enqueue'](function(){const _0x4adabd=_0x320c1e;return _0x37b8f4[_0x4adabd('0x12')][_0x4adabd('0x0')](_0x26f4cc,_0x36dd2a,_0x1b8db1)[_0x4adabd('0x19')](function(){const _0x2eb164=_0x4adabd;logger[_0x2eb164('0x1')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x36dd2a,_0x26f4cc);})[_0x4adabd('0x6')](function(_0x2235a0){logger['info'](JSON['stringify'](_0x2235a0));});});},Migration[_0xf023aa('0x8')]['addColumn']=function(_0x272377,_0x33efbb,_0x50bf2b){const _0x1009a8=this;this['sequence']['enqueue'](function(){const _0x19ee67=a968_0x31a8;return _0x1009a8[_0x19ee67('0x12')][_0x19ee67('0x1b')](_0x272377,_0x33efbb,_0x50bf2b)['then'](function(){const _0x4e83b3=_0x19ee67;logger[_0x4e83b3('0x1')](_0x4e83b3('0x17'),_0x33efbb,_0x272377);})[_0x19ee67('0x6')](function(_0x5612f5){const _0x2fedbe=_0x19ee67;logger['info'](JSON[_0x2fedbe('0x1a')](_0x5612f5));});});},Migration[_0xf023aa('0x8')]['dropTable']=function(_0x4d677c){const _0x3a4460=_0xf023aa,_0x5731fb=this;this[_0x3a4460('0xc')][_0x3a4460('0x13')](function(){const _0x4ccaea=_0x3a4460;return _0x5731fb[_0x4ccaea('0x12')][_0x4ccaea('0xf')](_0x4d677c,{'force':!![]})['then'](function(){const _0x2466e0=_0x4ccaea;logger[_0x2466e0('0x1')](_0x2466e0('0xe'),_0x4d677c);})['catch'](function(_0x7b2019){const _0x43d228=_0x4ccaea;logger[_0x43d228('0x1')](JSON[_0x43d228('0x1a')](_0x7b2019));});});},Migration[_0xf023aa('0x8')][_0xf023aa('0x9')]=function(_0x220bdc,_0x3dd025,_0x3862f8){const _0x2692cd=_0xf023aa,_0x4770a8=this;this['sequence'][_0x2692cd('0x13')](function(){const _0x332b11=_0x2692cd;return _0x4770a8[_0x332b11('0x12')][_0x332b11('0x9')](_0x220bdc,_0x3dd025,{'indexName':_0x3862f8})[_0x332b11('0x19')](function(){const _0x58a25c=_0x332b11;logger['info'](_0x58a25c('0x1f'),_0x220bdc,_0x3dd025[_0x58a25c('0x16')](','),_0x3862f8);})['catch'](function(_0x4f989e){const _0x580287=_0x332b11;logger['info'](JSON[_0x580287('0x1a')](_0x4f989e));});});},Migration[_0xf023aa('0x8')][_0xf023aa('0x18')]=function(_0xfc7546,_0x2d0d1b){const _0x32bc88=_0xf023aa,_0x35cb0c=this;this['sequence'][_0x32bc88('0x13')](function(){const _0xa702bb=_0x32bc88;return _0x35cb0c['queryInterface'][_0xa702bb('0x18')](_0xfc7546,_0x2d0d1b)[_0xa702bb('0x19')](function(){const _0x16c38b=_0xa702bb;logger[_0x16c38b('0x1')]('removeIndex\x20%s\x20%s',_0xfc7546,_0x2d0d1b);})[_0xa702bb('0x6')](function(_0x17f674){const _0x446fe0=_0xa702bb;logger[_0x446fe0('0x1')](JSON[_0x446fe0('0x1a')](_0x17f674));});});},Migration[_0xf023aa('0x8')][_0xf023aa('0xd')]=function(_0x44ab68){const _0x45e7c0=_0xf023aa,_0x3cdd4e=this;this['sequence'][_0x45e7c0('0x13')](function(){const _0x1ee12e=_0x45e7c0;return _0x3cdd4e[_0x1ee12e('0x12')][_0x1ee12e('0x10')][_0x1ee12e('0xd')](_0x44ab68)[_0x1ee12e('0x19')](function(){const _0x210145=_0x1ee12e;logger[_0x210145('0x1')](_0x210145('0x1c'),_0x44ab68);})[_0x1ee12e('0x6')](function(_0x3dad67){const _0x543834=_0x1ee12e;logger[_0x543834('0x1')](JSON['stringify'](_0x3dad67));});});},Migration[_0xf023aa('0x8')][_0xf023aa('0x3')]=function(_0x2fe980,_0x41c2aa){const _0x7e4d2f=_0xf023aa,_0xb72d64=this;this[_0x7e4d2f('0xc')][_0x7e4d2f('0x13')](function(){const _0x379981=_0x7e4d2f;return _0xb72d64[_0x379981('0x12')][_0x379981('0x3')](_0x2fe980,_0x41c2aa)['then'](function(){const _0x21b5c0=_0x379981;logger['info'](_0x21b5c0('0x14'),_0x41c2aa,_0x2fe980);})[_0x379981('0x6')](function(_0x1ea81c){const _0x221e62=_0x379981;logger[_0x221e62('0x1')](util[_0x221e62('0x1e')](_0x1ea81c,{'showHidden':![],'depth':null}));});});},Migration[_0xf023aa('0x8')][_0xf023aa('0x1d')]=function(_0x5256ce,_0x4b8982,_0x2aa83b){const _0x35441f=_0xf023aa,_0x9c7800=this;this[_0x35441f('0xc')][_0x35441f('0x13')](function(){const _0x469316=_0x35441f;return _0x9c7800[_0x469316('0x12')][_0x469316('0x1d')](_0x5256ce,_0x4b8982,_0x2aa83b)[_0x469316('0x19')](function(){const _0x3b53e6=_0x469316;logger[_0x3b53e6('0x1')](_0x3b53e6('0x11'),_0x4b8982,_0x2aa83b,_0x5256ce);})[_0x469316('0x6')](function(_0x25b342){const _0x2535f3=_0x469316;logger['info'](util[_0x2535f3('0x1e')](_0x25b342,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0xf023aa('0x15')]=function(_0x102d2e){const _0x3fee5b=_0xf023aa;this[_0x3fee5b('0xc')][_0x3fee5b('0x13')](function(){return _0x102d2e();});},module['exports']={'up':function(_0x547a39,_0x2e60cc){return new Promise(function(_0x32c3fa){const _0x46a6b9=a968_0x31a8,_0x31c883=new Migration(_0x547a39);_0x31c883['changeColumn']('mail_interactions',_0x46a6b9('0x2'),{'type':_0x2e60cc['STRING'](0x1fe)}),_0x31c883[_0x46a6b9('0x0')](_0x46a6b9('0xa'),_0x46a6b9('0x7'),{'type':_0x2e60cc[_0x46a6b9('0xb')](0x1fe)}),_0x31c883[_0x46a6b9('0x15')](_0x32c3fa);});},'down':function(){}}; \ No newline at end of file +const a968_0x3475=['migration','Added\x20column\x20%s\x20to\x20%s','prototype','removeIndex','../config/logger','table\x20dropped\x20%s','sequelize','info','inReplyTo','removeIndex\x20%s\x20%s','exports','enqueue','tail','addIndex\x20%s\x20%s\x20%s','queryInterface','removeColumn','query','addColumn','addIndex','catch','then','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','final','sequence','Removed\x20column\x20%s\x20from\x20%s','renameColumn','join','messageId','query\x20%s','changeColumn','util','inspect','mail_interactions','STRING','stringify'];(function(_0x37dcf1,_0x34758f){const _0x25b328=function(_0x3c4f42){while(--_0x3c4f42){_0x37dcf1['push'](_0x37dcf1['shift']());}};_0x25b328(++_0x34758f);}(a968_0x3475,0x1d7));const a968_0x25b3=function(_0x37dcf1,_0x34758f){_0x37dcf1=_0x37dcf1-0x0;let _0x25b328=a968_0x3475[_0x37dcf1];return _0x25b328;};const _0x312471=a968_0x25b3;'use strict';const util=require(_0x312471('0xe')),logger=require(_0x312471('0x17'))(_0x312471('0x13')),Sequence=function(){};Sequence[_0x312471('0x15')][_0x312471('0x1e')]=function(_0x3c4f42){const _0x664b24=_0x312471;this[_0x664b24('0x1f')]=this[_0x664b24('0x1f')]?this[_0x664b24('0x1f')]['finally'](_0x3c4f42):_0x3c4f42();};const Migration=function(_0x226cfb){const _0x2183ed=_0x312471;this[_0x2183ed('0x21')]=_0x226cfb,this['sequence']=new Sequence();};Migration['prototype'][_0x312471('0xd')]=function(_0x1b0e40,_0x5d60a3,_0x36f4c3){const _0x8a3eed=_0x312471,_0x40de27=this;this[_0x8a3eed('0x7')][_0x8a3eed('0x1e')](function(){const _0x26272c=_0x8a3eed;return _0x40de27['queryInterface'][_0x26272c('0xd')](_0x1b0e40,_0x5d60a3,_0x36f4c3)[_0x26272c('0x4')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x5d60a3,_0x1b0e40);})[_0x26272c('0x3')](function(_0x63df02){logger['info'](JSON['stringify'](_0x63df02));});});},Migration['prototype'][_0x312471('0x1')]=function(_0x566647,_0x4a3e69,_0xa09317){const _0x4cf2fd=_0x312471,_0x46aa52=this;this['sequence'][_0x4cf2fd('0x1e')](function(){const _0x238b5b=_0x4cf2fd;return _0x46aa52[_0x238b5b('0x21')][_0x238b5b('0x1')](_0x566647,_0x4a3e69,_0xa09317)[_0x238b5b('0x4')](function(){const _0x56b6a7=_0x238b5b;logger['info'](_0x56b6a7('0x14'),_0x4a3e69,_0x566647);})[_0x238b5b('0x3')](function(_0x4592f7){const _0x2fa075=_0x238b5b;logger[_0x2fa075('0x1a')](JSON['stringify'](_0x4592f7));});});},Migration[_0x312471('0x15')]['dropTable']=function(_0x5018b8){const _0x195a47=_0x312471,_0x310fd2=this;this[_0x195a47('0x7')]['enqueue'](function(){const _0x3c5062=_0x195a47;return _0x310fd2[_0x3c5062('0x21')]['dropTable'](_0x5018b8,{'force':!![]})[_0x3c5062('0x4')](function(){const _0xe130f0=_0x3c5062;logger['info'](_0xe130f0('0x18'),_0x5018b8);})[_0x3c5062('0x3')](function(_0xc55a13){const _0x556d0a=_0x3c5062;logger['info'](JSON[_0x556d0a('0x12')](_0xc55a13));});});},Migration['prototype'][_0x312471('0x2')]=function(_0x345816,_0x1ae1e3,_0x3cf187){const _0x441418=_0x312471,_0x915a24=this;this[_0x441418('0x7')][_0x441418('0x1e')](function(){const _0x2e3a38=_0x441418;return _0x915a24[_0x2e3a38('0x21')][_0x2e3a38('0x2')](_0x345816,_0x1ae1e3,{'indexName':_0x3cf187})[_0x2e3a38('0x4')](function(){const _0x3a7034=_0x2e3a38;logger[_0x3a7034('0x1a')](_0x3a7034('0x20'),_0x345816,_0x1ae1e3[_0x3a7034('0xa')](','),_0x3cf187);})['catch'](function(_0x30c114){const _0x140492=_0x2e3a38;logger[_0x140492('0x1a')](JSON['stringify'](_0x30c114));});});},Migration['prototype'][_0x312471('0x16')]=function(_0x1ce527,_0xb599b9){const _0x2e86bf=_0x312471,_0x3d4cc5=this;this['sequence'][_0x2e86bf('0x1e')](function(){const _0x2fa341=_0x2e86bf;return _0x3d4cc5[_0x2fa341('0x21')][_0x2fa341('0x16')](_0x1ce527,_0xb599b9)[_0x2fa341('0x4')](function(){const _0x12f1dc=_0x2fa341;logger['info'](_0x12f1dc('0x1c'),_0x1ce527,_0xb599b9);})[_0x2fa341('0x3')](function(_0x5a5b22){const _0x5422c4=_0x2fa341;logger[_0x5422c4('0x1a')](JSON[_0x5422c4('0x12')](_0x5a5b22));});});},Migration['prototype'][_0x312471('0x0')]=function(_0x5defc0){const _0x14c367=_0x312471,_0x5ae237=this;this[_0x14c367('0x7')][_0x14c367('0x1e')](function(){const _0x5eb89e=_0x14c367;return _0x5ae237[_0x5eb89e('0x21')][_0x5eb89e('0x19')][_0x5eb89e('0x0')](_0x5defc0)[_0x5eb89e('0x4')](function(){const _0x34a5f8=_0x5eb89e;logger['info'](_0x34a5f8('0xc'),_0x5defc0);})['catch'](function(_0x288531){const _0x513e1e=_0x5eb89e;logger[_0x513e1e('0x1a')](JSON[_0x513e1e('0x12')](_0x288531));});});},Migration['prototype'][_0x312471('0x22')]=function(_0x24a8f5,_0x10d572){const _0x1cc5af=_0x312471,_0x24d30d=this;this[_0x1cc5af('0x7')][_0x1cc5af('0x1e')](function(){const _0x3220d0=_0x1cc5af;return _0x24d30d[_0x3220d0('0x21')][_0x3220d0('0x22')](_0x24a8f5,_0x10d572)[_0x3220d0('0x4')](function(){const _0x2abee3=_0x3220d0;logger[_0x2abee3('0x1a')](_0x2abee3('0x8'),_0x10d572,_0x24a8f5);})[_0x3220d0('0x3')](function(_0x20984f){const _0x308424=_0x3220d0;logger['info'](util[_0x308424('0xf')](_0x20984f,{'showHidden':![],'depth':null}));});});},Migration[_0x312471('0x15')][_0x312471('0x9')]=function(_0x1e32af,_0x19ea16,_0x2f4a38){const _0x3163f1=_0x312471,_0x4f50e2=this;this[_0x3163f1('0x7')]['enqueue'](function(){const _0x592eb0=_0x3163f1;return _0x4f50e2[_0x592eb0('0x21')][_0x592eb0('0x9')](_0x1e32af,_0x19ea16,_0x2f4a38)[_0x592eb0('0x4')](function(){const _0x53af17=_0x592eb0;logger[_0x53af17('0x1a')](_0x53af17('0x5'),_0x19ea16,_0x2f4a38,_0x1e32af);})[_0x592eb0('0x3')](function(_0x35d24d){const _0x15e3de=_0x592eb0;logger[_0x15e3de('0x1a')](util[_0x15e3de('0xf')](_0x35d24d,{'showHidden':![],'depth':null}));});});},Migration[_0x312471('0x15')][_0x312471('0x6')]=function(_0x4b7e70){const _0x209a23=_0x312471;this[_0x209a23('0x7')][_0x209a23('0x1e')](function(){return _0x4b7e70();});},module[_0x312471('0x1d')]={'up':function(_0x2c7637,_0x322ce6){return new Promise(function(_0x3d1b3d){const _0x4c12f0=a968_0x25b3,_0x11cac1=new Migration(_0x2c7637);_0x11cac1['changeColumn'](_0x4c12f0('0x10'),_0x4c12f0('0x1b'),{'type':_0x322ce6[_0x4c12f0('0x11')](0x1fe)}),_0x11cac1[_0x4c12f0('0xd')]('mail_messages',_0x4c12f0('0xb'),{'type':_0x322ce6[_0x4c12f0('0x11')](0x1fe)}),_0x11cac1[_0x4c12f0('0x6')](_0x3d1b3d);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.2.4.js b/server/migrations/2.2.4.js index 9659e9d..f525b8a 100644 --- a/server/migrations/2.2.4.js +++ b/server/migrations/2.2.4.js @@ -1 +1 @@ -const a969_0x756c=['stringify','query','Removed\x20column\x20%s\x20from\x20%s','ALTER\x20TABLE\x20int_desk_fields\x20add\x20UNIQUE\x20INDEX\x20desk_unique_index\x20(idField,\x20FieldId)','tail','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','prototype','join','query\x20%s','addIndex','sequelize','Changed\x20column\x20%s\x20in\x20table\x20%s','ALTER\x20TABLE\x20int_zoho_fields\x20add\x20UNIQUE\x20INDEX\x20zoho_unique_index\x20(idField,\x20FieldId)','renameColumn','ALTER\x20TABLE\x20int_zendesk_fields\x20add\x20UNIQUE\x20INDEX\x20zendesk_unique_index\x20(idField,\x20FieldId)','final','enqueue','ALTER\x20TABLE\x20int_vtiger_fields\x20add\x20UNIQUE\x20INDEX\x20vtiger_unique_index\x20(idField,\x20FieldId)','dropTable','addIndex\x20%s\x20%s\x20%s','catch','addColumn','sequence','migration','removeColumn','info','util','inspect','then','queryInterface','removeIndex\x20%s\x20%s','ALTER\x20TABLE\x20int_salesforce_fields\x20add\x20UNIQUE\x20INDEX\x20salesforce_unique_index\x20(idField,\x20FieldId)','removeIndex','ALTER\x20TABLE\x20int_sugarcrm_fields\x20add\x20UNIQUE\x20INDEX\x20sugarcrm_unique_index\x20(idField,\x20FieldId)','changeColumn','ALTER\x20TABLE\x20int_freshdesk_fields\x20add\x20UNIQUE\x20INDEX\x20desk_unique_index\x20(idField,\x20FieldId)'];(function(_0xaf48fd,_0x756c71){const _0x59d8a3=function(_0x489cbb){while(--_0x489cbb){_0xaf48fd['push'](_0xaf48fd['shift']());}};_0x59d8a3(++_0x756c71);}(a969_0x756c,0x15e));const a969_0x59d8=function(_0xaf48fd,_0x756c71){_0xaf48fd=_0xaf48fd-0x0;let _0x59d8a3=a969_0x756c[_0xaf48fd];return _0x59d8a3;};const _0x15c3a3=a969_0x59d8;'use strict';const util=require(_0x15c3a3('0x0')),logger=require('../config/logger')(_0x15c3a3('0x21')),Sequence=function(){};Sequence[_0x15c3a3('0x10')][_0x15c3a3('0x1a')]=function(_0x489cbb){const _0x203b24=_0x15c3a3;this['tail']=this[_0x203b24('0xe')]?this[_0x203b24('0xe')]['finally'](_0x489cbb):_0x489cbb();};const Migration=function(_0x436c8f){const _0x42fe78=_0x15c3a3;this[_0x42fe78('0x3')]=_0x436c8f,this[_0x42fe78('0x20')]=new Sequence();};Migration[_0x15c3a3('0x10')][_0x15c3a3('0x8')]=function(_0x2a7542,_0x39c25e,_0x27c15a){const _0x530a57=this;this['sequence']['enqueue'](function(){const _0x1fdbe0=a969_0x59d8;return _0x530a57[_0x1fdbe0('0x3')][_0x1fdbe0('0x8')](_0x2a7542,_0x39c25e,_0x27c15a)[_0x1fdbe0('0x2')](function(){const _0x574161=_0x1fdbe0;logger[_0x574161('0x23')](_0x574161('0x15'),_0x39c25e,_0x2a7542);})[_0x1fdbe0('0x1e')](function(_0x334c72){const _0x1b8437=_0x1fdbe0;logger['info'](JSON[_0x1b8437('0xa')](_0x334c72));});});},Migration[_0x15c3a3('0x10')][_0x15c3a3('0x1f')]=function(_0x470da9,_0x5dd26d,_0x1de1c0){const _0x3d79cf=this;this['sequence']['enqueue'](function(){const _0x4b1f87=a969_0x59d8;return _0x3d79cf['queryInterface'][_0x4b1f87('0x1f')](_0x470da9,_0x5dd26d,_0x1de1c0)['then'](function(){const _0x3893ac=_0x4b1f87;logger[_0x3893ac('0x23')]('Added\x20column\x20%s\x20to\x20%s',_0x5dd26d,_0x470da9);})[_0x4b1f87('0x1e')](function(_0x4f921d){const _0x3626bf=_0x4b1f87;logger[_0x3626bf('0x23')](JSON[_0x3626bf('0xa')](_0x4f921d));});});},Migration[_0x15c3a3('0x10')][_0x15c3a3('0x1c')]=function(_0x528859){const _0x115f87=_0x15c3a3,_0x4e1a3c=this;this[_0x115f87('0x20')]['enqueue'](function(){const _0x2f7f55=_0x115f87;return _0x4e1a3c[_0x2f7f55('0x3')][_0x2f7f55('0x1c')](_0x528859,{'force':!![]})['then'](function(){logger['info']('table\x20dropped\x20%s',_0x528859);})[_0x2f7f55('0x1e')](function(_0x309680){const _0x14dbff=_0x2f7f55;logger['info'](JSON[_0x14dbff('0xa')](_0x309680));});});},Migration[_0x15c3a3('0x10')][_0x15c3a3('0x13')]=function(_0xc7db46,_0x3da249,_0x24aea0){const _0x51c036=_0x15c3a3,_0x139056=this;this[_0x51c036('0x20')][_0x51c036('0x1a')](function(){const _0x2fab18=_0x51c036;return _0x139056[_0x2fab18('0x3')]['addIndex'](_0xc7db46,_0x3da249,{'indexName':_0x24aea0})[_0x2fab18('0x2')](function(){const _0x3daa71=_0x2fab18;logger['info'](_0x3daa71('0x1d'),_0xc7db46,_0x3da249[_0x3daa71('0x11')](','),_0x24aea0);})[_0x2fab18('0x1e')](function(_0x1cac36){const _0x51e77b=_0x2fab18;logger[_0x51e77b('0x23')](JSON[_0x51e77b('0xa')](_0x1cac36));});});},Migration[_0x15c3a3('0x10')][_0x15c3a3('0x6')]=function(_0x4b3cd9,_0x292fbd){const _0x49477e=_0x15c3a3,_0x17fe9c=this;this[_0x49477e('0x20')]['enqueue'](function(){const _0x1b84df=_0x49477e;return _0x17fe9c[_0x1b84df('0x3')][_0x1b84df('0x6')](_0x4b3cd9,_0x292fbd)[_0x1b84df('0x2')](function(){const _0x142fa9=_0x1b84df;logger[_0x142fa9('0x23')](_0x142fa9('0x4'),_0x4b3cd9,_0x292fbd);})['catch'](function(_0x5c2337){const _0x2427a1=_0x1b84df;logger['info'](JSON[_0x2427a1('0xa')](_0x5c2337));});});},Migration[_0x15c3a3('0x10')]['query']=function(_0x1634f5){const _0x357d75=_0x15c3a3,_0x46ac25=this;this[_0x357d75('0x20')]['enqueue'](function(){const _0x106cb2=_0x357d75;return _0x46ac25[_0x106cb2('0x3')][_0x106cb2('0x14')][_0x106cb2('0xb')](_0x1634f5)['then'](function(){const _0x13df38=_0x106cb2;logger['info'](_0x13df38('0x12'),_0x1634f5);})['catch'](function(_0x24b423){const _0xdf54c5=_0x106cb2;logger[_0xdf54c5('0x23')](JSON[_0xdf54c5('0xa')](_0x24b423));});});},Migration[_0x15c3a3('0x10')]['removeColumn']=function(_0x24c297,_0x112588){const _0x445ca7=_0x15c3a3,_0x37fc17=this;this[_0x445ca7('0x20')][_0x445ca7('0x1a')](function(){const _0x230a73=_0x445ca7;return _0x37fc17['queryInterface'][_0x230a73('0x22')](_0x24c297,_0x112588)[_0x230a73('0x2')](function(){const _0x405d24=_0x230a73;logger[_0x405d24('0x23')](_0x405d24('0xc'),_0x112588,_0x24c297);})[_0x230a73('0x1e')](function(_0x386d01){const _0x34a0fd=_0x230a73;logger[_0x34a0fd('0x23')](util[_0x34a0fd('0x1')](_0x386d01,{'showHidden':![],'depth':null}));});});},Migration[_0x15c3a3('0x10')][_0x15c3a3('0x17')]=function(_0xf0d87e,_0xd3eccf,_0xf5a67d){const _0x236fe4=_0x15c3a3,_0x59241e=this;this[_0x236fe4('0x20')][_0x236fe4('0x1a')](function(){const _0xec6a3f=_0x236fe4;return _0x59241e[_0xec6a3f('0x3')][_0xec6a3f('0x17')](_0xf0d87e,_0xd3eccf,_0xf5a67d)[_0xec6a3f('0x2')](function(){const _0x3b5b11=_0xec6a3f;logger[_0x3b5b11('0x23')](_0x3b5b11('0xf'),_0xd3eccf,_0xf5a67d,_0xf0d87e);})[_0xec6a3f('0x1e')](function(_0x3eb209){const _0x5c8971=_0xec6a3f;logger['info'](util[_0x5c8971('0x1')](_0x3eb209,{'showHidden':![],'depth':null}));});});},Migration[_0x15c3a3('0x10')][_0x15c3a3('0x19')]=function(_0x3a1f9b){const _0x52ddc5=_0x15c3a3;this[_0x52ddc5('0x20')][_0x52ddc5('0x1a')](function(){return _0x3a1f9b();});},module['exports']={'up':function(_0x13619d){return new Promise(function(_0x5bec12){const _0x4a4979=a969_0x59d8,_0x2d6085=new Migration(_0x13619d);_0x2d6085[_0x4a4979('0xb')](_0x4a4979('0xd')),_0x2d6085['query'](_0x4a4979('0x9')),_0x2d6085['query'](_0x4a4979('0x5')),_0x2d6085['query'](_0x4a4979('0x7')),_0x2d6085[_0x4a4979('0xb')](_0x4a4979('0x1b')),_0x2d6085[_0x4a4979('0xb')](_0x4a4979('0x18')),_0x2d6085[_0x4a4979('0xb')](_0x4a4979('0x16')),_0x2d6085[_0x4a4979('0x19')](_0x5bec12);});},'down':function(){}}; \ No newline at end of file +const a969_0x2169=['util','ALTER\x20TABLE\x20int_freshdesk_fields\x20add\x20UNIQUE\x20INDEX\x20desk_unique_index\x20(idField,\x20FieldId)','removeIndex\x20%s\x20%s','ALTER\x20TABLE\x20int_vtiger_fields\x20add\x20UNIQUE\x20INDEX\x20vtiger_unique_index\x20(idField,\x20FieldId)','finally','addIndex','ALTER\x20TABLE\x20int_desk_fields\x20add\x20UNIQUE\x20INDEX\x20desk_unique_index\x20(idField,\x20FieldId)','join','dropTable','sequence','stringify','enqueue','final','ALTER\x20TABLE\x20int_sugarcrm_fields\x20add\x20UNIQUE\x20INDEX\x20sugarcrm_unique_index\x20(idField,\x20FieldId)','renameColumn','tail','ALTER\x20TABLE\x20int_zoho_fields\x20add\x20UNIQUE\x20INDEX\x20zoho_unique_index\x20(idField,\x20FieldId)','queryInterface','table\x20dropped\x20%s','info','catch','inspect','migration','removeIndex','exports','ALTER\x20TABLE\x20int_salesforce_fields\x20add\x20UNIQUE\x20INDEX\x20salesforce_unique_index\x20(idField,\x20FieldId)','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Removed\x20column\x20%s\x20from\x20%s','Added\x20column\x20%s\x20to\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','../config/logger','changeColumn','prototype','sequelize','query','removeColumn','addColumn','ALTER\x20TABLE\x20int_zendesk_fields\x20add\x20UNIQUE\x20INDEX\x20zendesk_unique_index\x20(idField,\x20FieldId)','addIndex\x20%s\x20%s\x20%s','then'];(function(_0x326972,_0x2169c6){const _0x1aa3b7=function(_0x623c33){while(--_0x623c33){_0x326972['push'](_0x326972['shift']());}};_0x1aa3b7(++_0x2169c6);}(a969_0x2169,0x190));const a969_0x1aa3=function(_0x326972,_0x2169c6){_0x326972=_0x326972-0x0;let _0x1aa3b7=a969_0x2169[_0x326972];return _0x1aa3b7;};const _0x3efef7=a969_0x1aa3;'use strict';const util=require(_0x3efef7('0x0')),logger=require(_0x3efef7('0x1e'))(_0x3efef7('0x16')),Sequence=function(){};Sequence[_0x3efef7('0x20')][_0x3efef7('0xb')]=function(_0x623c33){const _0x2d9325=_0x3efef7;this[_0x2d9325('0xf')]=this['tail']?this[_0x2d9325('0xf')][_0x2d9325('0x4')](_0x623c33):_0x623c33();};const Migration=function(_0x170ca5){const _0xdc1106=_0x3efef7;this[_0xdc1106('0x11')]=_0x170ca5,this[_0xdc1106('0x9')]=new Sequence();};Migration[_0x3efef7('0x20')][_0x3efef7('0x1f')]=function(_0x5ea86d,_0x47515b,_0x4ca923){const _0x4da4c3=_0x3efef7,_0x52f980=this;this[_0x4da4c3('0x9')][_0x4da4c3('0xb')](function(){const _0x48298e=_0x4da4c3;return _0x52f980[_0x48298e('0x11')][_0x48298e('0x1f')](_0x5ea86d,_0x47515b,_0x4ca923)[_0x48298e('0x27')](function(){const _0x42fa47=_0x48298e;logger[_0x42fa47('0x13')](_0x42fa47('0x1d'),_0x47515b,_0x5ea86d);})[_0x48298e('0x14')](function(_0xccab77){const _0x5432d1=_0x48298e;logger['info'](JSON[_0x5432d1('0xa')](_0xccab77));});});},Migration[_0x3efef7('0x20')][_0x3efef7('0x24')]=function(_0x5ea482,_0x5c9277,_0x5d5282){const _0x10e75c=_0x3efef7,_0x51de9f=this;this[_0x10e75c('0x9')][_0x10e75c('0xb')](function(){const _0x30712f=_0x10e75c;return _0x51de9f['queryInterface'][_0x30712f('0x24')](_0x5ea482,_0x5c9277,_0x5d5282)[_0x30712f('0x27')](function(){const _0x414d1d=_0x30712f;logger[_0x414d1d('0x13')](_0x414d1d('0x1c'),_0x5c9277,_0x5ea482);})[_0x30712f('0x14')](function(_0x8b9ae7){const _0x2b6c0d=_0x30712f;logger[_0x2b6c0d('0x13')](JSON[_0x2b6c0d('0xa')](_0x8b9ae7));});});},Migration[_0x3efef7('0x20')][_0x3efef7('0x8')]=function(_0x3765aa){const _0x173614=this;this['sequence']['enqueue'](function(){const _0xe4cc5d=a969_0x1aa3;return _0x173614['queryInterface'][_0xe4cc5d('0x8')](_0x3765aa,{'force':!![]})[_0xe4cc5d('0x27')](function(){const _0xbb08e2=_0xe4cc5d;logger['info'](_0xbb08e2('0x12'),_0x3765aa);})[_0xe4cc5d('0x14')](function(_0x291df5){const _0x995fcf=_0xe4cc5d;logger['info'](JSON[_0x995fcf('0xa')](_0x291df5));});});},Migration['prototype']['addIndex']=function(_0xc58c2e,_0x557403,_0x310168){const _0x135133=_0x3efef7,_0x190220=this;this['sequence'][_0x135133('0xb')](function(){const _0x91c559=_0x135133;return _0x190220[_0x91c559('0x11')][_0x91c559('0x5')](_0xc58c2e,_0x557403,{'indexName':_0x310168})[_0x91c559('0x27')](function(){const _0x4e8fd0=_0x91c559;logger[_0x4e8fd0('0x13')](_0x4e8fd0('0x26'),_0xc58c2e,_0x557403[_0x4e8fd0('0x7')](','),_0x310168);})[_0x91c559('0x14')](function(_0x4d9f95){const _0x5bd2ef=_0x91c559;logger[_0x5bd2ef('0x13')](JSON[_0x5bd2ef('0xa')](_0x4d9f95));});});},Migration[_0x3efef7('0x20')][_0x3efef7('0x17')]=function(_0x1fc04e,_0x4c1bed){const _0x31759a=_0x3efef7,_0x5e7e5f=this;this[_0x31759a('0x9')][_0x31759a('0xb')](function(){const _0x248eaf=_0x31759a;return _0x5e7e5f[_0x248eaf('0x11')][_0x248eaf('0x17')](_0x1fc04e,_0x4c1bed)[_0x248eaf('0x27')](function(){const _0x13da0b=_0x248eaf;logger[_0x13da0b('0x13')](_0x13da0b('0x2'),_0x1fc04e,_0x4c1bed);})[_0x248eaf('0x14')](function(_0x539916){const _0x360961=_0x248eaf;logger[_0x360961('0x13')](JSON['stringify'](_0x539916));});});},Migration[_0x3efef7('0x20')][_0x3efef7('0x22')]=function(_0x1d9148){const _0x178a12=_0x3efef7,_0x42c43e=this;this[_0x178a12('0x9')][_0x178a12('0xb')](function(){const _0x3da34d=_0x178a12;return _0x42c43e[_0x3da34d('0x11')][_0x3da34d('0x21')]['query'](_0x1d9148)['then'](function(){const _0x530d75=_0x3da34d;logger[_0x530d75('0x13')]('query\x20%s',_0x1d9148);})[_0x3da34d('0x14')](function(_0x5c1ed3){const _0x2a0e3d=_0x3da34d;logger[_0x2a0e3d('0x13')](JSON[_0x2a0e3d('0xa')](_0x5c1ed3));});});},Migration[_0x3efef7('0x20')][_0x3efef7('0x23')]=function(_0x4ce21d,_0xa085d9){const _0x1f7606=_0x3efef7,_0x3f2775=this;this[_0x1f7606('0x9')][_0x1f7606('0xb')](function(){const _0x2e5134=_0x1f7606;return _0x3f2775[_0x2e5134('0x11')]['removeColumn'](_0x4ce21d,_0xa085d9)['then'](function(){const _0x2c2552=_0x2e5134;logger[_0x2c2552('0x13')](_0x2c2552('0x1b'),_0xa085d9,_0x4ce21d);})[_0x2e5134('0x14')](function(_0x55f7d8){const _0x3ec6c8=_0x2e5134;logger[_0x3ec6c8('0x13')](util[_0x3ec6c8('0x15')](_0x55f7d8,{'showHidden':![],'depth':null}));});});},Migration[_0x3efef7('0x20')][_0x3efef7('0xe')]=function(_0xfd3f98,_0x2f139b,_0x19af29){const _0x1d7e24=_0x3efef7,_0x4edc7b=this;this[_0x1d7e24('0x9')][_0x1d7e24('0xb')](function(){const _0xd3cca4=_0x1d7e24;return _0x4edc7b['queryInterface'][_0xd3cca4('0xe')](_0xfd3f98,_0x2f139b,_0x19af29)['then'](function(){const _0x4f32e2=_0xd3cca4;logger[_0x4f32e2('0x13')](_0x4f32e2('0x1a'),_0x2f139b,_0x19af29,_0xfd3f98);})[_0xd3cca4('0x14')](function(_0x5a7d9d){const _0xd21b36=_0xd3cca4;logger[_0xd21b36('0x13')](util['inspect'](_0x5a7d9d,{'showHidden':![],'depth':null}));});});},Migration[_0x3efef7('0x20')][_0x3efef7('0xc')]=function(_0x41c3a6){const _0x213284=_0x3efef7;this[_0x213284('0x9')][_0x213284('0xb')](function(){return _0x41c3a6();});},module[_0x3efef7('0x18')]={'up':function(_0xfa057e){return new Promise(function(_0x336eaf){const _0x2e50ee=a969_0x1aa3,_0x163289=new Migration(_0xfa057e);_0x163289[_0x2e50ee('0x22')](_0x2e50ee('0x6')),_0x163289['query'](_0x2e50ee('0x1')),_0x163289[_0x2e50ee('0x22')](_0x2e50ee('0x19')),_0x163289[_0x2e50ee('0x22')](_0x2e50ee('0xd')),_0x163289[_0x2e50ee('0x22')](_0x2e50ee('0x3')),_0x163289[_0x2e50ee('0x22')](_0x2e50ee('0x25')),_0x163289['query'](_0x2e50ee('0x10')),_0x163289['final'](_0x336eaf);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.2.5.js b/server/migrations/2.2.5.js index 1daba30..4dfe758 100644 --- a/server/migrations/2.2.5.js +++ b/server/migrations/2.2.5.js @@ -1 +1 @@ -const a970_0x25a0=['Added\x20column\x20%s\x20to\x20%s','enqueue','renameColumn','addColumn','query','prototype','table\x20dropped\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','sequence','sequelize','finally','queryInterface','removeColumn','removeIndex','stringify','query\x20%s','migration','addIndex\x20%s\x20%s\x20%s','exports','inspect','tail','info','join','changeColumn','then','dropTable','final','removeIndex\x20%s\x20%s','catch','addIndex'];(function(_0x2ac614,_0x25a07a){const _0x2cb855=function(_0x3b7755){while(--_0x3b7755){_0x2ac614['push'](_0x2ac614['shift']());}};_0x2cb855(++_0x25a07a);}(a970_0x25a0,0x18c));const a970_0x2cb8=function(_0x2ac614,_0x25a07a){_0x2ac614=_0x2ac614-0x0;let _0x2cb855=a970_0x25a0[_0x2ac614];return _0x2cb855;};const _0x2c41f5=a970_0x2cb8;'use strict';const util=require('util'),logger=require('../config/logger')(_0x2c41f5('0xa')),Sequence=function(){};Sequence[_0x2c41f5('0x1d')][_0x2c41f5('0x19')]=function(_0x3b7755){const _0x5a38bb=_0x2c41f5;this[_0x5a38bb('0xe')]=this['tail']?this[_0x5a38bb('0xe')][_0x5a38bb('0x4')](_0x3b7755):_0x3b7755();};const Migration=function(_0x13caf9){const _0x19d4ea=_0x2c41f5;this[_0x19d4ea('0x5')]=_0x13caf9,this[_0x19d4ea('0x2')]=new Sequence();};Migration['prototype'][_0x2c41f5('0x11')]=function(_0x911d20,_0x32fc38,_0x2f1507){const _0x50fb2d=_0x2c41f5,_0x35f8e2=this;this[_0x50fb2d('0x2')][_0x50fb2d('0x19')](function(){const _0x2da49e=_0x50fb2d;return _0x35f8e2[_0x2da49e('0x5')][_0x2da49e('0x11')](_0x911d20,_0x32fc38,_0x2f1507)[_0x2da49e('0x12')](function(){const _0x1e38d2=_0x2da49e;logger[_0x1e38d2('0xf')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x32fc38,_0x911d20);})[_0x2da49e('0x16')](function(_0x24b5bf){logger['info'](JSON['stringify'](_0x24b5bf));});});},Migration[_0x2c41f5('0x1d')][_0x2c41f5('0x1b')]=function(_0x5a263f,_0x617e1f,_0x3e9878){const _0x3eae08=_0x2c41f5,_0x4a24a3=this;this['sequence'][_0x3eae08('0x19')](function(){const _0x3a2f78=_0x3eae08;return _0x4a24a3[_0x3a2f78('0x5')][_0x3a2f78('0x1b')](_0x5a263f,_0x617e1f,_0x3e9878)[_0x3a2f78('0x12')](function(){const _0x18f7f0=_0x3a2f78;logger[_0x18f7f0('0xf')](_0x18f7f0('0x18'),_0x617e1f,_0x5a263f);})[_0x3a2f78('0x16')](function(_0x35e1ab){const _0xec364d=_0x3a2f78;logger['info'](JSON[_0xec364d('0x8')](_0x35e1ab));});});},Migration[_0x2c41f5('0x1d')]['dropTable']=function(_0x39c83d){const _0xd52cb2=_0x2c41f5,_0x58371a=this;this['sequence'][_0xd52cb2('0x19')](function(){const _0x3137f2=_0xd52cb2;return _0x58371a[_0x3137f2('0x5')][_0x3137f2('0x13')](_0x39c83d,{'force':!![]})[_0x3137f2('0x12')](function(){const _0x5ecfbc=_0x3137f2;logger['info'](_0x5ecfbc('0x0'),_0x39c83d);})[_0x3137f2('0x16')](function(_0x1553f3){const _0x456f5c=_0x3137f2;logger['info'](JSON[_0x456f5c('0x8')](_0x1553f3));});});},Migration[_0x2c41f5('0x1d')][_0x2c41f5('0x17')]=function(_0x2bae49,_0x58b137,_0x3bd167){const _0x56c694=_0x2c41f5,_0x20f843=this;this[_0x56c694('0x2')][_0x56c694('0x19')](function(){const _0x5a87af=_0x56c694;return _0x20f843[_0x5a87af('0x5')][_0x5a87af('0x17')](_0x2bae49,_0x58b137,{'indexName':_0x3bd167})[_0x5a87af('0x12')](function(){const _0x33abc7=_0x5a87af;logger[_0x33abc7('0xf')](_0x33abc7('0xb'),_0x2bae49,_0x58b137[_0x33abc7('0x10')](','),_0x3bd167);})['catch'](function(_0x35ae7c){const _0x1da4e4=_0x5a87af;logger[_0x1da4e4('0xf')](JSON['stringify'](_0x35ae7c));});});},Migration[_0x2c41f5('0x1d')]['removeIndex']=function(_0x2fc18e,_0x4d592e){const _0x1828e1=_0x2c41f5,_0x4cf0d5=this;this[_0x1828e1('0x2')]['enqueue'](function(){const _0x50f0c2=_0x1828e1;return _0x4cf0d5[_0x50f0c2('0x5')][_0x50f0c2('0x7')](_0x2fc18e,_0x4d592e)[_0x50f0c2('0x12')](function(){const _0x5f5176=_0x50f0c2;logger[_0x5f5176('0xf')](_0x5f5176('0x15'),_0x2fc18e,_0x4d592e);})['catch'](function(_0x3d1d10){const _0x5b6d91=_0x50f0c2;logger[_0x5b6d91('0xf')](JSON[_0x5b6d91('0x8')](_0x3d1d10));});});},Migration[_0x2c41f5('0x1d')][_0x2c41f5('0x1c')]=function(_0x56c039){const _0x40157e=_0x2c41f5,_0x40911b=this;this[_0x40157e('0x2')][_0x40157e('0x19')](function(){const _0xa65369=_0x40157e;return _0x40911b[_0xa65369('0x5')][_0xa65369('0x3')][_0xa65369('0x1c')](_0x56c039)[_0xa65369('0x12')](function(){const _0x143e9a=_0xa65369;logger[_0x143e9a('0xf')](_0x143e9a('0x9'),_0x56c039);})[_0xa65369('0x16')](function(_0x32c63b){const _0x5e0cf4=_0xa65369;logger[_0x5e0cf4('0xf')](JSON['stringify'](_0x32c63b));});});},Migration['prototype'][_0x2c41f5('0x6')]=function(_0x243485,_0x4632ab){const _0xc7ea8c=_0x2c41f5,_0x361ce5=this;this['sequence'][_0xc7ea8c('0x19')](function(){const _0x49306b=_0xc7ea8c;return _0x361ce5[_0x49306b('0x5')][_0x49306b('0x6')](_0x243485,_0x4632ab)[_0x49306b('0x12')](function(){const _0x2d2e60=_0x49306b;logger[_0x2d2e60('0xf')]('Removed\x20column\x20%s\x20from\x20%s',_0x4632ab,_0x243485);})[_0x49306b('0x16')](function(_0x22603c){const _0xa98112=_0x49306b;logger['info'](util[_0xa98112('0xd')](_0x22603c,{'showHidden':![],'depth':null}));});});},Migration[_0x2c41f5('0x1d')]['renameColumn']=function(_0x26104a,_0x4d3fdb,_0x9f95f){const _0x2f4299=_0x2c41f5,_0x19d633=this;this[_0x2f4299('0x2')][_0x2f4299('0x19')](function(){const _0x15dc4f=_0x2f4299;return _0x19d633[_0x15dc4f('0x5')][_0x15dc4f('0x1a')](_0x26104a,_0x4d3fdb,_0x9f95f)[_0x15dc4f('0x12')](function(){const _0x2560cd=_0x15dc4f;logger[_0x2560cd('0xf')](_0x2560cd('0x1'),_0x4d3fdb,_0x9f95f,_0x26104a);})[_0x15dc4f('0x16')](function(_0x215d90){const _0x5a5739=_0x15dc4f;logger[_0x5a5739('0xf')](util[_0x5a5739('0xd')](_0x215d90,{'showHidden':![],'depth':null}));});});},Migration[_0x2c41f5('0x1d')][_0x2c41f5('0x14')]=function(_0x2e9de6){const _0x6d9b=_0x2c41f5;this['sequence'][_0x6d9b('0x19')](function(){return _0x2e9de6();});},module[_0x2c41f5('0xc')]={'up':function(_0x141542){return new Promise(function(_0x29e461){const _0x331406=a970_0x2cb8,_0x5c39ba=new Migration(_0x141542);_0x5c39ba[_0x331406('0x14')](_0x29e461);});},'down':function(){}}; \ No newline at end of file +const a970_0x3599=['inspect','exports','Added\x20column\x20%s\x20to\x20%s','sequelize','final','prototype','removeColumn','tail','queryInterface','removeIndex\x20%s\x20%s','Removed\x20column\x20%s\x20from\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','sequence','query','addColumn','addIndex','catch','join','../config/logger','enqueue','stringify','removeIndex','renameColumn','finally','util','info','then','addIndex\x20%s\x20%s\x20%s'];(function(_0x40b851,_0x35997b){const _0x59093d=function(_0x4a6ce9){while(--_0x4a6ce9){_0x40b851['push'](_0x40b851['shift']());}};_0x59093d(++_0x35997b);}(a970_0x3599,0xf8));const a970_0x5909=function(_0x40b851,_0x35997b){_0x40b851=_0x40b851-0x0;let _0x59093d=a970_0x3599[_0x40b851];return _0x59093d;};const _0x2492ff=a970_0x5909;'use strict';const util=require(_0x2492ff('0x0')),logger=require(_0x2492ff('0x16'))('migration'),Sequence=function(){};Sequence[_0x2492ff('0x9')][_0x2492ff('0x17')]=function(_0x4a6ce9){const _0x5818d9=_0x2492ff;this[_0x5818d9('0xb')]=this[_0x5818d9('0xb')]?this['tail'][_0x5818d9('0x1b')](_0x4a6ce9):_0x4a6ce9();};const Migration=function(_0x2598eb){const _0x41f480=_0x2492ff;this[_0x41f480('0xc')]=_0x2598eb,this[_0x41f480('0x10')]=new Sequence();};Migration[_0x2492ff('0x9')]['changeColumn']=function(_0x2108bc,_0x36e43,_0x4eced8){const _0x50c274=_0x2492ff,_0x462851=this;this[_0x50c274('0x10')][_0x50c274('0x17')](function(){const _0x7610ed=_0x50c274;return _0x462851['queryInterface']['changeColumn'](_0x2108bc,_0x36e43,_0x4eced8)[_0x7610ed('0x2')](function(){const _0x4fbc52=_0x7610ed;logger[_0x4fbc52('0x1')](_0x4fbc52('0xf'),_0x36e43,_0x2108bc);})[_0x7610ed('0x14')](function(_0x1c64e0){const _0x4bbf2a=_0x7610ed;logger[_0x4bbf2a('0x1')](JSON[_0x4bbf2a('0x18')](_0x1c64e0));});});},Migration[_0x2492ff('0x9')][_0x2492ff('0x12')]=function(_0xc9b5e9,_0x2375b9,_0xc12b5){const _0x5619d1=this;this['sequence']['enqueue'](function(){const _0x1a266f=a970_0x5909;return _0x5619d1[_0x1a266f('0xc')][_0x1a266f('0x12')](_0xc9b5e9,_0x2375b9,_0xc12b5)[_0x1a266f('0x2')](function(){const _0x19f2e2=_0x1a266f;logger[_0x19f2e2('0x1')](_0x19f2e2('0x6'),_0x2375b9,_0xc9b5e9);})['catch'](function(_0x482ac2){const _0x176bf0=_0x1a266f;logger[_0x176bf0('0x1')](JSON[_0x176bf0('0x18')](_0x482ac2));});});},Migration[_0x2492ff('0x9')]['dropTable']=function(_0x5b4549){const _0x229550=_0x2492ff,_0x190540=this;this['sequence'][_0x229550('0x17')](function(){const _0x458805=_0x229550;return _0x190540[_0x458805('0xc')]['dropTable'](_0x5b4549,{'force':!![]})['then'](function(){const _0x15a5f2=_0x458805;logger[_0x15a5f2('0x1')]('table\x20dropped\x20%s',_0x5b4549);})[_0x458805('0x14')](function(_0x135a0f){const _0x514150=_0x458805;logger[_0x514150('0x1')](JSON['stringify'](_0x135a0f));});});},Migration['prototype'][_0x2492ff('0x13')]=function(_0x68274,_0x432516,_0x9a1c99){const _0x143971=_0x2492ff,_0x28e767=this;this[_0x143971('0x10')][_0x143971('0x17')](function(){const _0x2deeef=_0x143971;return _0x28e767['queryInterface']['addIndex'](_0x68274,_0x432516,{'indexName':_0x9a1c99})[_0x2deeef('0x2')](function(){const _0x1fd360=_0x2deeef;logger[_0x1fd360('0x1')](_0x1fd360('0x3'),_0x68274,_0x432516[_0x1fd360('0x15')](','),_0x9a1c99);})[_0x2deeef('0x14')](function(_0x54d7fa){const _0x5b01e9=_0x2deeef;logger[_0x5b01e9('0x1')](JSON[_0x5b01e9('0x18')](_0x54d7fa));});});},Migration[_0x2492ff('0x9')]['removeIndex']=function(_0x18615e,_0x1f8ffd){const _0x212887=_0x2492ff,_0x55511b=this;this[_0x212887('0x10')][_0x212887('0x17')](function(){const _0x1fd723=_0x212887;return _0x55511b[_0x1fd723('0xc')][_0x1fd723('0x19')](_0x18615e,_0x1f8ffd)['then'](function(){const _0x2b6227=_0x1fd723;logger[_0x2b6227('0x1')](_0x2b6227('0xd'),_0x18615e,_0x1f8ffd);})[_0x1fd723('0x14')](function(_0x5237ee){const _0x3b8f56=_0x1fd723;logger[_0x3b8f56('0x1')](JSON[_0x3b8f56('0x18')](_0x5237ee));});});},Migration[_0x2492ff('0x9')][_0x2492ff('0x11')]=function(_0x5ea1ee){const _0x1dc61d=_0x2492ff,_0x263edf=this;this[_0x1dc61d('0x10')]['enqueue'](function(){const _0x2670c7=_0x1dc61d;return _0x263edf[_0x2670c7('0xc')][_0x2670c7('0x7')]['query'](_0x5ea1ee)[_0x2670c7('0x2')](function(){const _0x143327=_0x2670c7;logger[_0x143327('0x1')]('query\x20%s',_0x5ea1ee);})[_0x2670c7('0x14')](function(_0x3fa5be){const _0x41702e=_0x2670c7;logger['info'](JSON[_0x41702e('0x18')](_0x3fa5be));});});},Migration[_0x2492ff('0x9')][_0x2492ff('0xa')]=function(_0xbc7155,_0x17c9df){const _0x48d4d9=_0x2492ff,_0x54dbe9=this;this[_0x48d4d9('0x10')][_0x48d4d9('0x17')](function(){const _0x3f4cff=_0x48d4d9;return _0x54dbe9[_0x3f4cff('0xc')][_0x3f4cff('0xa')](_0xbc7155,_0x17c9df)[_0x3f4cff('0x2')](function(){const _0x383534=_0x3f4cff;logger[_0x383534('0x1')](_0x383534('0xe'),_0x17c9df,_0xbc7155);})[_0x3f4cff('0x14')](function(_0x3504c3){const _0x312c61=_0x3f4cff;logger[_0x312c61('0x1')](util['inspect'](_0x3504c3,{'showHidden':![],'depth':null}));});});},Migration[_0x2492ff('0x9')][_0x2492ff('0x1a')]=function(_0x55d66a,_0x35b354,_0x441fc1){const _0x5e071d=_0x2492ff,_0x1a9b87=this;this[_0x5e071d('0x10')][_0x5e071d('0x17')](function(){const _0x41852d=_0x5e071d;return _0x1a9b87[_0x41852d('0xc')]['renameColumn'](_0x55d66a,_0x35b354,_0x441fc1)['then'](function(){const _0x5baec8=_0x41852d;logger[_0x5baec8('0x1')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x35b354,_0x441fc1,_0x55d66a);})[_0x41852d('0x14')](function(_0x29f7ee){const _0x4503f6=_0x41852d;logger[_0x4503f6('0x1')](util[_0x4503f6('0x4')](_0x29f7ee,{'showHidden':![],'depth':null}));});});},Migration[_0x2492ff('0x9')][_0x2492ff('0x8')]=function(_0xf51c3e){const _0x59e9d5=_0x2492ff;this[_0x59e9d5('0x10')][_0x59e9d5('0x17')](function(){return _0xf51c3e();});},module[_0x2492ff('0x5')]={'up':function(_0x3e6f04){return new Promise(function(_0x2e1d9a){const _0x3a92f4=a970_0x5909,_0x4011d1=new Migration(_0x3e6f04);_0x4011d1[_0x3a92f4('0x8')](_0x2e1d9a);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.2.6.js b/server/migrations/2.2.6.js index 83f72cb..e15f363 100644 --- a/server/migrations/2.2.6.js +++ b/server/migrations/2.2.6.js @@ -1 +1 @@ -const a971_0x5a7f=['enqueue','query\x20%s','ALTER\x20TABLE\x20openchannel_accounts\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`openchannel_accounts_ibfk_2`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','table\x20dropped\x20%s','catch','tail','UPDATE\x20analytics_custom_reports\x20SET\x20joins\x20=\x20REPLACE(joins,\x27\x22type\x22:\x22outer_join\x22\x27,\x27\x22type\x22:\x22left_join\x22\x27)\x20WHERE\x20joins\x20LIKE\x20\x27%\x22type\x22:\x22outer_join\x22%\x27','openchannel_accounts','mail_accounts','addIndex','addIndex\x20%s\x20%s\x20%s','prototype','sequelize','removeColumn','sms_accounts','BOOLEAN','fax_accounts','then','UPDATE\x20square_projects\x20SET\x20preproduction\x20=\x20REPLACE(preproduction,\x27labelBackgroundColor=#ffffff;\x27,\x27\x27)','Added\x20column\x20%s\x20to\x20%s','ALTER\x20TABLE\x20sms_accounts\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`sms_accounts_ibfk_2`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','mandatoryDispositionPauseId','util','Removed\x20column\x20%s\x20from\x20%s','mandatoryDisposition','ALTER\x20TABLE\x20fax_accounts\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`fax_accounts_ibfk_3`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','migration','ALTER\x20TABLE\x20voice_queues\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`voice_queues_ibfk_4`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','ALTER\x20TABLE\x20mail_accounts\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`mail_accounts_ibfk_3`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','queryInterface','../config/logger','chat_websites','voice_queues','renameColumn','ALTER\x20TABLE\x20mail_interactions\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;','INTEGER','addColumn','removeIndex','dropTable','stringify','ALTER\x20TABLE\x20chat_websites\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`chat_websites_ibfk_3`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','final','join','sequence','Changed\x20column\x20%s\x20in\x20table\x20%s','UPDATE\x20square_projects\x20SET\x20production\x20=\x20REPLACE(production,\x27labelBackgroundColor=#ffffff;\x27,\x27\x27)','changeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','info','query'];(function(_0x239d34,_0x5a7f33){const _0x1716dd=function(_0x46519e){while(--_0x46519e){_0x239d34['push'](_0x239d34['shift']());}};_0x1716dd(++_0x5a7f33);}(a971_0x5a7f,0xfd));const a971_0x1716=function(_0x239d34,_0x5a7f33){_0x239d34=_0x239d34-0x0;let _0x1716dd=a971_0x5a7f[_0x239d34];return _0x1716dd;};const _0x7bc4e6=a971_0x1716;'use strict';const util=require(_0x7bc4e6('0x13')),logger=require(_0x7bc4e6('0x1b'))(_0x7bc4e6('0x17')),Sequence=function(){};Sequence[_0x7bc4e6('0x8')]['enqueue']=function(_0x46519e){const _0x5649ab=_0x7bc4e6;this[_0x5649ab('0x2')]=this[_0x5649ab('0x2')]?this[_0x5649ab('0x2')]['finally'](_0x46519e):_0x46519e();};const Migration=function(_0x58f85b){const _0x5021ad=_0x7bc4e6;this[_0x5021ad('0x1a')]=_0x58f85b,this[_0x5021ad('0x28')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0xe45313,_0x514e1f,_0xc8ec9f){const _0x1e3c4d=_0x7bc4e6,_0x28c218=this;this[_0x1e3c4d('0x28')][_0x1e3c4d('0x2f')](function(){const _0x59bdab=_0x1e3c4d;return _0x28c218[_0x59bdab('0x1a')][_0x59bdab('0x2b')](_0xe45313,_0x514e1f,_0xc8ec9f)[_0x59bdab('0xe')](function(){const _0x35ab45=_0x59bdab;logger[_0x35ab45('0x2d')](_0x35ab45('0x29'),_0x514e1f,_0xe45313);})['catch'](function(_0x5ec200){const _0x4f26c8=_0x59bdab;logger[_0x4f26c8('0x2d')](JSON[_0x4f26c8('0x24')](_0x5ec200));});});},Migration[_0x7bc4e6('0x8')][_0x7bc4e6('0x21')]=function(_0x488b85,_0x21e9c6,_0x28874e){const _0x448ec1=_0x7bc4e6,_0x536fa8=this;this[_0x448ec1('0x28')]['enqueue'](function(){const _0x259ea4=_0x448ec1;return _0x536fa8[_0x259ea4('0x1a')][_0x259ea4('0x21')](_0x488b85,_0x21e9c6,_0x28874e)[_0x259ea4('0xe')](function(){const _0x4e4c5e=_0x259ea4;logger[_0x4e4c5e('0x2d')](_0x4e4c5e('0x10'),_0x21e9c6,_0x488b85);})['catch'](function(_0x560902){const _0x3bd498=_0x259ea4;logger[_0x3bd498('0x2d')](JSON[_0x3bd498('0x24')](_0x560902));});});},Migration[_0x7bc4e6('0x8')]['dropTable']=function(_0x461dda){const _0x476ab7=_0x7bc4e6,_0xd33b1c=this;this[_0x476ab7('0x28')]['enqueue'](function(){const _0x3fda94=_0x476ab7;return _0xd33b1c[_0x3fda94('0x1a')][_0x3fda94('0x23')](_0x461dda,{'force':!![]})[_0x3fda94('0xe')](function(){const _0x201267=_0x3fda94;logger[_0x201267('0x2d')](_0x201267('0x0'),_0x461dda);})[_0x3fda94('0x1')](function(_0x47a67f){const _0x3e0fc6=_0x3fda94;logger[_0x3e0fc6('0x2d')](JSON[_0x3e0fc6('0x24')](_0x47a67f));});});},Migration[_0x7bc4e6('0x8')][_0x7bc4e6('0x6')]=function(_0x83d560,_0x2dfb0d,_0x2e8417){const _0x5262e3=_0x7bc4e6,_0xe0e333=this;this[_0x5262e3('0x28')][_0x5262e3('0x2f')](function(){const _0x4c59aa=_0x5262e3;return _0xe0e333[_0x4c59aa('0x1a')][_0x4c59aa('0x6')](_0x83d560,_0x2dfb0d,{'indexName':_0x2e8417})['then'](function(){const _0x204e54=_0x4c59aa;logger['info'](_0x204e54('0x7'),_0x83d560,_0x2dfb0d[_0x204e54('0x27')](','),_0x2e8417);})[_0x4c59aa('0x1')](function(_0x5f4584){logger['info'](JSON['stringify'](_0x5f4584));});});},Migration[_0x7bc4e6('0x8')][_0x7bc4e6('0x22')]=function(_0x3e067c,_0xf726f3){const _0x35aa69=_0x7bc4e6,_0x481ff6=this;this[_0x35aa69('0x28')][_0x35aa69('0x2f')](function(){const _0x3a3784=_0x35aa69;return _0x481ff6[_0x3a3784('0x1a')][_0x3a3784('0x22')](_0x3e067c,_0xf726f3)[_0x3a3784('0xe')](function(){const _0xad5de1=_0x3a3784;logger[_0xad5de1('0x2d')]('removeIndex\x20%s\x20%s',_0x3e067c,_0xf726f3);})['catch'](function(_0xd8add7){const _0x588d5c=_0x3a3784;logger[_0x588d5c('0x2d')](JSON[_0x588d5c('0x24')](_0xd8add7));});});},Migration[_0x7bc4e6('0x8')][_0x7bc4e6('0x2e')]=function(_0x5acaef){const _0x4b2f69=_0x7bc4e6,_0x5ee14a=this;this[_0x4b2f69('0x28')][_0x4b2f69('0x2f')](function(){const _0x238b03=_0x4b2f69;return _0x5ee14a['queryInterface'][_0x238b03('0x9')]['query'](_0x5acaef)['then'](function(){const _0x23dd51=_0x238b03;logger[_0x23dd51('0x2d')](_0x23dd51('0x30'),_0x5acaef);})[_0x238b03('0x1')](function(_0x155ee6){const _0x77b85=_0x238b03;logger[_0x77b85('0x2d')](JSON[_0x77b85('0x24')](_0x155ee6));});});},Migration[_0x7bc4e6('0x8')][_0x7bc4e6('0xa')]=function(_0x40d7ae,_0x4a50d6){const _0x8a97f7=_0x7bc4e6,_0x5dc1a1=this;this[_0x8a97f7('0x28')][_0x8a97f7('0x2f')](function(){const _0x2d17a8=_0x8a97f7;return _0x5dc1a1[_0x2d17a8('0x1a')][_0x2d17a8('0xa')](_0x40d7ae,_0x4a50d6)[_0x2d17a8('0xe')](function(){const _0xd6cbe4=_0x2d17a8;logger[_0xd6cbe4('0x2d')](_0xd6cbe4('0x14'),_0x4a50d6,_0x40d7ae);})['catch'](function(_0x4e8236){const _0x4c6879=_0x2d17a8;logger[_0x4c6879('0x2d')](util['inspect'](_0x4e8236,{'showHidden':![],'depth':null}));});});},Migration[_0x7bc4e6('0x8')][_0x7bc4e6('0x1e')]=function(_0x2ec445,_0x2dc6e3,_0x58f572){const _0x20e343=_0x7bc4e6,_0x4a933b=this;this[_0x20e343('0x28')][_0x20e343('0x2f')](function(){const _0x4263b4=_0x20e343;return _0x4a933b[_0x4263b4('0x1a')][_0x4263b4('0x1e')](_0x2ec445,_0x2dc6e3,_0x58f572)[_0x4263b4('0xe')](function(){const _0xced4ca=_0x4263b4;logger[_0xced4ca('0x2d')](_0xced4ca('0x2c'),_0x2dc6e3,_0x58f572,_0x2ec445);})[_0x4263b4('0x1')](function(_0x57b7d7){const _0x494202=_0x4263b4;logger[_0x494202('0x2d')](util['inspect'](_0x57b7d7,{'showHidden':![],'depth':null}));});});},Migration[_0x7bc4e6('0x8')]['final']=function(_0x3fd5b5){const _0x24bf80=_0x7bc4e6;this[_0x24bf80('0x28')]['enqueue'](function(){return _0x3fd5b5();});},module['exports']={'up':function(_0x4b5ac3,_0x334fde){return new Promise(function(_0x1118b9){const _0x5a240b=a971_0x1716,_0x365e1e=new Migration(_0x4b5ac3);_0x365e1e[_0x5a240b('0x2e')](_0x5a240b('0x1f')),_0x365e1e[_0x5a240b('0x2e')](_0x5a240b('0x3')),_0x365e1e[_0x5a240b('0x2e')](_0x5a240b('0xf')),_0x365e1e[_0x5a240b('0x2e')](_0x5a240b('0x2a')),_0x365e1e[_0x5a240b('0x21')](_0x5a240b('0x1d'),'mandatoryDisposition',{'type':_0x334fde[_0x5a240b('0xc')],'defaultValue':![]}),_0x365e1e[_0x5a240b('0x21')](_0x5a240b('0x1d'),_0x5a240b('0x12'),{'type':_0x334fde[_0x5a240b('0x20')]}),_0x365e1e[_0x5a240b('0x2e')](_0x5a240b('0x18')),_0x365e1e[_0x5a240b('0x21')](_0x5a240b('0x1c'),_0x5a240b('0x15'),{'type':_0x334fde[_0x5a240b('0xc')],'defaultValue':![]}),_0x365e1e[_0x5a240b('0x21')](_0x5a240b('0x1c'),_0x5a240b('0x12'),{'type':_0x334fde[_0x5a240b('0x20')]}),_0x365e1e[_0x5a240b('0x2e')](_0x5a240b('0x25')),_0x365e1e[_0x5a240b('0x21')](_0x5a240b('0xd'),_0x5a240b('0x15'),{'type':_0x334fde[_0x5a240b('0xc')],'defaultValue':![]}),_0x365e1e['addColumn'](_0x5a240b('0xd'),_0x5a240b('0x12'),{'type':_0x334fde[_0x5a240b('0x20')]}),_0x365e1e[_0x5a240b('0x2e')](_0x5a240b('0x16')),_0x365e1e[_0x5a240b('0x21')](_0x5a240b('0x5'),'mandatoryDisposition',{'type':_0x334fde[_0x5a240b('0xc')],'defaultValue':![]}),_0x365e1e[_0x5a240b('0x21')](_0x5a240b('0x5'),_0x5a240b('0x12'),{'type':_0x334fde[_0x5a240b('0x20')]}),_0x365e1e[_0x5a240b('0x2e')](_0x5a240b('0x19')),_0x365e1e['addColumn'](_0x5a240b('0x4'),_0x5a240b('0x15'),{'type':_0x334fde['BOOLEAN'],'defaultValue':![]}),_0x365e1e[_0x5a240b('0x21')]('openchannel_accounts',_0x5a240b('0x12'),{'type':_0x334fde[_0x5a240b('0x20')]}),_0x365e1e[_0x5a240b('0x2e')](_0x5a240b('0x31')),_0x365e1e[_0x5a240b('0x21')](_0x5a240b('0xb'),_0x5a240b('0x15'),{'type':_0x334fde[_0x5a240b('0xc')],'defaultValue':![]}),_0x365e1e[_0x5a240b('0x21')](_0x5a240b('0xb'),_0x5a240b('0x12'),{'type':_0x334fde[_0x5a240b('0x20')]}),_0x365e1e['query'](_0x5a240b('0x11')),_0x365e1e[_0x5a240b('0x26')](_0x1118b9);});},'down':function(){}}; \ No newline at end of file +const a971_0x1dd5=['ALTER\x20TABLE\x20fax_accounts\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`fax_accounts_ibfk_3`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','openchannel_accounts','prototype','addColumn','BOOLEAN','queryInterface','Removed\x20column\x20%s\x20from\x20%s','then','UPDATE\x20analytics_custom_reports\x20SET\x20joins\x20=\x20REPLACE(joins,\x27\x22type\x22:\x22outer_join\x22\x27,\x27\x22type\x22:\x22left_join\x22\x27)\x20WHERE\x20joins\x20LIKE\x20\x27%\x22type\x22:\x22outer_join\x22%\x27','info','removeIndex\x20%s\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','tail','enqueue','fax_accounts','migration','renameColumn','query','sequelize','voice_queues','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','sequence','ALTER\x20TABLE\x20openchannel_accounts\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`openchannel_accounts_ibfk_2`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','ALTER\x20TABLE\x20sms_accounts\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`sms_accounts_ibfk_2`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','mandatoryDisposition','INTEGER','removeColumn','final','addIndex','join','chat_websites','finally','ALTER\x20TABLE\x20voice_queues\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`voice_queues_ibfk_4`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE','sms_accounts','removeIndex','stringify','util','inspect','mandatoryDispositionPauseId','mail_accounts','changeColumn','catch','dropTable','ALTER\x20TABLE\x20mail_interactions\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;'];(function(_0x129d76,_0x1dd5ea){const _0x2c01c1=function(_0x39c071){while(--_0x39c071){_0x129d76['push'](_0x129d76['shift']());}};_0x2c01c1(++_0x1dd5ea);}(a971_0x1dd5,0xd0));const a971_0x2c01=function(_0x129d76,_0x1dd5ea){_0x129d76=_0x129d76-0x0;let _0x2c01c1=a971_0x1dd5[_0x129d76];return _0x2c01c1;};const _0x1547ca=a971_0x2c01;'use strict';const util=require(_0x1547ca('0x4')),logger=require('../config/logger')(_0x1547ca('0x1b')),Sequence=function(){};Sequence['prototype'][_0x1547ca('0x19')]=function(_0x39c071){const _0x217574=_0x1547ca;this['tail']=this['tail']?this[_0x217574('0x18')][_0x217574('0x2b')](_0x39c071):_0x39c071();};const Migration=function(_0x4a7b6a){const _0x563276=_0x1547ca;this[_0x563276('0x11')]=_0x4a7b6a,this['sequence']=new Sequence();};Migration['prototype'][_0x1547ca('0x8')]=function(_0x341e1c,_0x1beb77,_0x5b758a){const _0x631d58=_0x1547ca,_0x595f0e=this;this[_0x631d58('0x21')]['enqueue'](function(){const _0x134c7d=_0x631d58;return _0x595f0e[_0x134c7d('0x11')][_0x134c7d('0x8')](_0x341e1c,_0x1beb77,_0x5b758a)[_0x134c7d('0x13')](function(){const _0x101a1b=_0x134c7d;logger[_0x101a1b('0x15')](_0x101a1b('0x17'),_0x1beb77,_0x341e1c);})[_0x134c7d('0x9')](function(_0x2fe269){const _0x3a7bfb=_0x134c7d;logger[_0x3a7bfb('0x15')](JSON['stringify'](_0x2fe269));});});},Migration['prototype'][_0x1547ca('0xf')]=function(_0x14ab5f,_0x24ef66,_0x186817){const _0x508d73=_0x1547ca,_0x4ba675=this;this['sequence'][_0x508d73('0x19')](function(){const _0x1febd8=_0x508d73;return _0x4ba675['queryInterface'][_0x1febd8('0xf')](_0x14ab5f,_0x24ef66,_0x186817)[_0x1febd8('0x13')](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x24ef66,_0x14ab5f);})[_0x1febd8('0x9')](function(_0x914caf){const _0x202dde=_0x1febd8;logger['info'](JSON[_0x202dde('0x3')](_0x914caf));});});},Migration[_0x1547ca('0xe')]['dropTable']=function(_0x26f698){const _0x3aa45e=_0x1547ca,_0x54e6e7=this;this[_0x3aa45e('0x21')][_0x3aa45e('0x19')](function(){const _0x12fd2e=_0x3aa45e;return _0x54e6e7['queryInterface'][_0x12fd2e('0xa')](_0x26f698,{'force':!![]})[_0x12fd2e('0x13')](function(){logger['info']('table\x20dropped\x20%s',_0x26f698);})['catch'](function(_0x1765ce){const _0x5f1d73=_0x12fd2e;logger[_0x5f1d73('0x15')](JSON[_0x5f1d73('0x3')](_0x1765ce));});});},Migration['prototype'][_0x1547ca('0x28')]=function(_0x351a70,_0x14a04f,_0x51e7a5){const _0x113346=_0x1547ca,_0x4f710f=this;this[_0x113346('0x21')]['enqueue'](function(){const _0x322bac=_0x113346;return _0x4f710f[_0x322bac('0x11')][_0x322bac('0x28')](_0x351a70,_0x14a04f,{'indexName':_0x51e7a5})[_0x322bac('0x13')](function(){const _0xcd6e37=_0x322bac;logger[_0xcd6e37('0x15')]('addIndex\x20%s\x20%s\x20%s',_0x351a70,_0x14a04f[_0xcd6e37('0x29')](','),_0x51e7a5);})['catch'](function(_0x1ec373){const _0x301106=_0x322bac;logger[_0x301106('0x15')](JSON['stringify'](_0x1ec373));});});},Migration[_0x1547ca('0xe')][_0x1547ca('0x2')]=function(_0xd1feff,_0x2646fe){const _0x1f0e69=_0x1547ca,_0x494167=this;this[_0x1f0e69('0x21')]['enqueue'](function(){const _0x55336c=_0x1f0e69;return _0x494167[_0x55336c('0x11')][_0x55336c('0x2')](_0xd1feff,_0x2646fe)['then'](function(){const _0x9e5ac0=_0x55336c;logger[_0x9e5ac0('0x15')](_0x9e5ac0('0x16'),_0xd1feff,_0x2646fe);})[_0x55336c('0x9')](function(_0x63babc){const _0x4eef6c=_0x55336c;logger[_0x4eef6c('0x15')](JSON[_0x4eef6c('0x3')](_0x63babc));});});},Migration['prototype'][_0x1547ca('0x1d')]=function(_0x46d74d){const _0x44e828=this;this['sequence']['enqueue'](function(){const _0x159816=a971_0x2c01;return _0x44e828[_0x159816('0x11')][_0x159816('0x1e')][_0x159816('0x1d')](_0x46d74d)['then'](function(){const _0x34acbd=_0x159816;logger[_0x34acbd('0x15')]('query\x20%s',_0x46d74d);})['catch'](function(_0x1d007e){const _0x388d25=_0x159816;logger[_0x388d25('0x15')](JSON[_0x388d25('0x3')](_0x1d007e));});});},Migration['prototype'][_0x1547ca('0x26')]=function(_0x467398,_0x27ce09){const _0x8b1fc6=_0x1547ca,_0x4aea5e=this;this[_0x8b1fc6('0x21')][_0x8b1fc6('0x19')](function(){const _0x3de400=_0x8b1fc6;return _0x4aea5e[_0x3de400('0x11')][_0x3de400('0x26')](_0x467398,_0x27ce09)[_0x3de400('0x13')](function(){const _0x4ed53b=_0x3de400;logger['info'](_0x4ed53b('0x12'),_0x27ce09,_0x467398);})[_0x3de400('0x9')](function(_0x54082a){const _0x9b9cf2=_0x3de400;logger[_0x9b9cf2('0x15')](util[_0x9b9cf2('0x5')](_0x54082a,{'showHidden':![],'depth':null}));});});},Migration[_0x1547ca('0xe')][_0x1547ca('0x1c')]=function(_0x3d34e7,_0x15cc3f,_0x55f3a8){const _0x5cb119=_0x1547ca,_0x42f1b9=this;this[_0x5cb119('0x21')][_0x5cb119('0x19')](function(){const _0x34f320=_0x5cb119;return _0x42f1b9[_0x34f320('0x11')]['renameColumn'](_0x3d34e7,_0x15cc3f,_0x55f3a8)['then'](function(){const _0x3f94bb=_0x34f320;logger['info'](_0x3f94bb('0x20'),_0x15cc3f,_0x55f3a8,_0x3d34e7);})[_0x34f320('0x9')](function(_0x1b3a36){const _0x176c34=_0x34f320;logger['info'](util[_0x176c34('0x5')](_0x1b3a36,{'showHidden':![],'depth':null}));});});},Migration[_0x1547ca('0xe')]['final']=function(_0x3fc486){this['sequence']['enqueue'](function(){return _0x3fc486();});},module['exports']={'up':function(_0x2121c1,_0x3eb6d4){return new Promise(function(_0x18a047){const _0x4a4af6=a971_0x2c01,_0x56a573=new Migration(_0x2121c1);_0x56a573[_0x4a4af6('0x1d')](_0x4a4af6('0xb')),_0x56a573['query'](_0x4a4af6('0x14')),_0x56a573[_0x4a4af6('0x1d')]('UPDATE\x20square_projects\x20SET\x20preproduction\x20=\x20REPLACE(preproduction,\x27labelBackgroundColor=#ffffff;\x27,\x27\x27)'),_0x56a573['query']('UPDATE\x20square_projects\x20SET\x20production\x20=\x20REPLACE(production,\x27labelBackgroundColor=#ffffff;\x27,\x27\x27)'),_0x56a573[_0x4a4af6('0xf')](_0x4a4af6('0x1f'),_0x4a4af6('0x24'),{'type':_0x3eb6d4['BOOLEAN'],'defaultValue':![]}),_0x56a573[_0x4a4af6('0xf')](_0x4a4af6('0x1f'),_0x4a4af6('0x6'),{'type':_0x3eb6d4[_0x4a4af6('0x25')]}),_0x56a573['query'](_0x4a4af6('0x0')),_0x56a573[_0x4a4af6('0xf')](_0x4a4af6('0x2a'),_0x4a4af6('0x24'),{'type':_0x3eb6d4[_0x4a4af6('0x10')],'defaultValue':![]}),_0x56a573['addColumn'](_0x4a4af6('0x2a'),_0x4a4af6('0x6'),{'type':_0x3eb6d4['INTEGER']}),_0x56a573[_0x4a4af6('0x1d')]('ALTER\x20TABLE\x20chat_websites\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`chat_websites_ibfk_3`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE'),_0x56a573['addColumn']('fax_accounts',_0x4a4af6('0x24'),{'type':_0x3eb6d4[_0x4a4af6('0x10')],'defaultValue':![]}),_0x56a573[_0x4a4af6('0xf')](_0x4a4af6('0x1a'),'mandatoryDispositionPauseId',{'type':_0x3eb6d4[_0x4a4af6('0x25')]}),_0x56a573[_0x4a4af6('0x1d')](_0x4a4af6('0xc')),_0x56a573[_0x4a4af6('0xf')]('mail_accounts',_0x4a4af6('0x24'),{'type':_0x3eb6d4['BOOLEAN'],'defaultValue':![]}),_0x56a573['addColumn'](_0x4a4af6('0x7'),_0x4a4af6('0x6'),{'type':_0x3eb6d4[_0x4a4af6('0x25')]}),_0x56a573[_0x4a4af6('0x1d')]('ALTER\x20TABLE\x20mail_accounts\x20\x09\x09\x09\x09ADD\x20CONSTRAINT\x20`mail_accounts_ibfk_3`\x20\x09\x09\x09\x09FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20\x09\x09\x09\x09REFERENCES\x20tools_pauses(`id`)\x20\x09\x09\x09\x09ON\x20UPDATE\x20CASCADE\x20\x09\x09\x09\x09ON\x20DELETE\x20CASCADE'),_0x56a573[_0x4a4af6('0xf')](_0x4a4af6('0xd'),_0x4a4af6('0x24'),{'type':_0x3eb6d4['BOOLEAN'],'defaultValue':![]}),_0x56a573['addColumn'](_0x4a4af6('0xd'),'mandatoryDispositionPauseId',{'type':_0x3eb6d4[_0x4a4af6('0x25')]}),_0x56a573[_0x4a4af6('0x1d')](_0x4a4af6('0x22')),_0x56a573[_0x4a4af6('0xf')](_0x4a4af6('0x1'),_0x4a4af6('0x24'),{'type':_0x3eb6d4[_0x4a4af6('0x10')],'defaultValue':![]}),_0x56a573['addColumn'](_0x4a4af6('0x1'),_0x4a4af6('0x6'),{'type':_0x3eb6d4[_0x4a4af6('0x25')]}),_0x56a573[_0x4a4af6('0x1d')](_0x4a4af6('0x23')),_0x56a573[_0x4a4af6('0x27')](_0x18a047);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.0.js b/server/migrations/2.3.0.js index da9176e..b6d9a33 100644 --- a/server/migrations/2.3.0.js +++ b/server/migrations/2.3.0.js @@ -1 +1 @@ -const a972_0x14fe=['info','query','renameColumn','sequence','sequelize','exports','removeColumn','uniqueid','prototype','changeColumn','removeIndex\x20%s\x20%s','final','report_call','query\x20%s','dropTable','then','stringify','join','inspect','finally','tail','catch','STRING','table\x20dropped\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','addColumn','removeIndex','users','enqueue','queryInterface','addIndex'];(function(_0x4f99ad,_0x14fee2){const _0x28c20f=function(_0x3422ba){while(--_0x3422ba){_0x4f99ad['push'](_0x4f99ad['shift']());}};_0x28c20f(++_0x14fee2);}(a972_0x14fe,0x1d5));const a972_0x28c2=function(_0x4f99ad,_0x14fee2){_0x4f99ad=_0x4f99ad-0x0;let _0x28c20f=a972_0x14fe[_0x4f99ad];return _0x28c20f;};const _0x4b32dc=a972_0x28c2;'use strict';const util=require('util'),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence[_0x4b32dc('0x4')][_0x4b32dc('0x18')]=function(_0x3422ba){const _0x9f31cf=_0x4b32dc;this['tail']=this[_0x9f31cf('0x10')]?this[_0x9f31cf('0x10')][_0x9f31cf('0xf')](_0x3422ba):_0x3422ba();};const Migration=function(_0x41ab71){const _0x45930e=_0x4b32dc;this['queryInterface']=_0x41ab71,this[_0x45930e('0x1e')]=new Sequence();};Migration[_0x4b32dc('0x4')][_0x4b32dc('0x5')]=function(_0x7e7119,_0x30caad,_0x57c19d){const _0xac406c=_0x4b32dc,_0x304e6b=this;this['sequence'][_0xac406c('0x18')](function(){const _0x3a8350=_0xac406c;return _0x304e6b[_0x3a8350('0x19')]['changeColumn'](_0x7e7119,_0x30caad,_0x57c19d)[_0x3a8350('0xb')](function(){const _0x19db90=_0x3a8350;logger[_0x19db90('0x1b')](_0x19db90('0x14'),_0x30caad,_0x7e7119);})[_0x3a8350('0x11')](function(_0x1e8cb9){const _0x29174b=_0x3a8350;logger[_0x29174b('0x1b')](JSON[_0x29174b('0xc')](_0x1e8cb9));});});},Migration[_0x4b32dc('0x4')]['addColumn']=function(_0x531149,_0x55b28d,_0x392bcf){const _0xe05191=_0x4b32dc,_0x1feee1=this;this['sequence'][_0xe05191('0x18')](function(){const _0x4b817b=_0xe05191;return _0x1feee1[_0x4b817b('0x19')][_0x4b817b('0x15')](_0x531149,_0x55b28d,_0x392bcf)[_0x4b817b('0xb')](function(){const _0x4d6646=_0x4b817b;logger[_0x4d6646('0x1b')]('Added\x20column\x20%s\x20to\x20%s',_0x55b28d,_0x531149);})[_0x4b817b('0x11')](function(_0x288b80){const _0x3c43ff=_0x4b817b;logger[_0x3c43ff('0x1b')](JSON['stringify'](_0x288b80));});});},Migration[_0x4b32dc('0x4')][_0x4b32dc('0xa')]=function(_0x5942d5){const _0x5323b4=_0x4b32dc,_0x2ed2c5=this;this['sequence'][_0x5323b4('0x18')](function(){const _0xaf4cf5=_0x5323b4;return _0x2ed2c5['queryInterface'][_0xaf4cf5('0xa')](_0x5942d5,{'force':!![]})[_0xaf4cf5('0xb')](function(){const _0x2da2c7=_0xaf4cf5;logger['info'](_0x2da2c7('0x13'),_0x5942d5);})[_0xaf4cf5('0x11')](function(_0x33e24c){const _0x297e1d=_0xaf4cf5;logger[_0x297e1d('0x1b')](JSON[_0x297e1d('0xc')](_0x33e24c));});});},Migration[_0x4b32dc('0x4')][_0x4b32dc('0x1a')]=function(_0x5eec95,_0x331caa,_0x32dce0){const _0x2134eb=_0x4b32dc,_0x5412be=this;this[_0x2134eb('0x1e')][_0x2134eb('0x18')](function(){const _0x681834=_0x2134eb;return _0x5412be['queryInterface'][_0x681834('0x1a')](_0x5eec95,_0x331caa,{'indexName':_0x32dce0})[_0x681834('0xb')](function(){const _0x593f78=_0x681834;logger[_0x593f78('0x1b')]('addIndex\x20%s\x20%s\x20%s',_0x5eec95,_0x331caa[_0x593f78('0xd')](','),_0x32dce0);})['catch'](function(_0x15354d){const _0x5666bc=_0x681834;logger[_0x5666bc('0x1b')](JSON['stringify'](_0x15354d));});});},Migration[_0x4b32dc('0x4')][_0x4b32dc('0x16')]=function(_0x269ca8,_0x57f5e2){const _0x30c1ab=_0x4b32dc,_0x98f42d=this;this[_0x30c1ab('0x1e')][_0x30c1ab('0x18')](function(){const _0x1af850=_0x30c1ab;return _0x98f42d[_0x1af850('0x19')][_0x1af850('0x16')](_0x269ca8,_0x57f5e2)[_0x1af850('0xb')](function(){const _0x4508d5=_0x1af850;logger['info'](_0x4508d5('0x6'),_0x269ca8,_0x57f5e2);})['catch'](function(_0x43c2a2){const _0x209566=_0x1af850;logger[_0x209566('0x1b')](JSON['stringify'](_0x43c2a2));});});},Migration['prototype'][_0x4b32dc('0x1c')]=function(_0x5bf727){const _0x2a33b7=_0x4b32dc,_0x157358=this;this['sequence'][_0x2a33b7('0x18')](function(){const _0x59e680=_0x2a33b7;return _0x157358[_0x59e680('0x19')][_0x59e680('0x0')]['query'](_0x5bf727)[_0x59e680('0xb')](function(){const _0x10b090=_0x59e680;logger[_0x10b090('0x1b')](_0x10b090('0x9'),_0x5bf727);})[_0x59e680('0x11')](function(_0x4ddb77){const _0x1aeefe=_0x59e680;logger['info'](JSON[_0x1aeefe('0xc')](_0x4ddb77));});});},Migration[_0x4b32dc('0x4')][_0x4b32dc('0x2')]=function(_0x52fddd,_0x5b80c7){const _0x53f3d3=_0x4b32dc,_0x88a06e=this;this[_0x53f3d3('0x1e')][_0x53f3d3('0x18')](function(){const _0x1762b5=_0x53f3d3;return _0x88a06e[_0x1762b5('0x19')][_0x1762b5('0x2')](_0x52fddd,_0x5b80c7)['then'](function(){const _0x3eda52=_0x1762b5;logger[_0x3eda52('0x1b')]('Removed\x20column\x20%s\x20from\x20%s',_0x5b80c7,_0x52fddd);})[_0x1762b5('0x11')](function(_0x3a1874){logger['info'](util['inspect'](_0x3a1874,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x4b32dc('0x1d')]=function(_0x187981,_0x3f04dd,_0x400403){const _0x13ddb5=_0x4b32dc,_0x3a7de7=this;this[_0x13ddb5('0x1e')][_0x13ddb5('0x18')](function(){const _0x402fbf=_0x13ddb5;return _0x3a7de7['queryInterface'][_0x402fbf('0x1d')](_0x187981,_0x3f04dd,_0x400403)[_0x402fbf('0xb')](function(){const _0x583c00=_0x402fbf;logger[_0x583c00('0x1b')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x3f04dd,_0x400403,_0x187981);})[_0x402fbf('0x11')](function(_0x2d9510){const _0x2bb900=_0x402fbf;logger[_0x2bb900('0x1b')](util[_0x2bb900('0xe')](_0x2d9510,{'showHidden':![],'depth':null}));});});},Migration[_0x4b32dc('0x4')][_0x4b32dc('0x7')]=function(_0x4e26bc){const _0x202a9f=_0x4b32dc;this[_0x202a9f('0x1e')][_0x202a9f('0x18')](function(){return _0x4e26bc();});},module[_0x4b32dc('0x1')]={'up':function(_0x27e9b1,_0x35a71f){return new Promise(function(_0x8e5f1c){const _0x479ab7=a972_0x28c2,_0x30521c=new Migration(_0x27e9b1);_0x30521c[_0x479ab7('0x15')](_0x479ab7('0x17'),'apiKeyNonce',{'type':_0x35a71f[_0x479ab7('0x12')]}),_0x30521c['addColumn']('users','apiKeyIat',{'type':_0x35a71f['STRING']}),_0x30521c[_0x479ab7('0x1a')](_0x479ab7('0x8'),['uniqueid'],_0x479ab7('0x3')),_0x30521c[_0x479ab7('0x7')](_0x8e5f1c);});},'down':function(){}}; \ No newline at end of file +const a972_0x2d84=['info','addColumn','migration','Added\x20column\x20%s\x20to\x20%s','removeIndex','users','removeColumn','stringify','inspect','tail','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex','uniqueid','enqueue','prototype','then','STRING','Removed\x20column\x20%s\x20from\x20%s','addIndex\x20%s\x20%s\x20%s','query\x20%s','renameColumn','changeColumn','finally','exports','../config/logger','table\x20dropped\x20%s','removeIndex\x20%s\x20%s','query','report_call','join','final','apiKeyIat','sequelize','Changed\x20column\x20%s\x20in\x20table\x20%s','catch','util','queryInterface','sequence'];(function(_0x47ef3d,_0x2d84fc){const _0x51d58a=function(_0x47e755){while(--_0x47e755){_0x47ef3d['push'](_0x47ef3d['shift']());}};_0x51d58a(++_0x2d84fc);}(a972_0x2d84,0x99));const a972_0x51d5=function(_0x47ef3d,_0x2d84fc){_0x47ef3d=_0x47ef3d-0x0;let _0x51d58a=a972_0x2d84[_0x47ef3d];return _0x51d58a;};const _0x5ba386=a972_0x51d5;'use strict';const util=require(_0x5ba386('0x22')),logger=require(_0x5ba386('0x17'))(_0x5ba386('0x1')),Sequence=function(){};Sequence[_0x5ba386('0xd')]['enqueue']=function(_0x47e755){const _0x17d84e=_0x5ba386;this['tail']=this[_0x17d84e('0x8')]?this[_0x17d84e('0x8')][_0x17d84e('0x15')](_0x47e755):_0x47e755();};const Migration=function(_0x4da37f){const _0x33f03c=_0x5ba386;this[_0x33f03c('0x23')]=_0x4da37f,this[_0x33f03c('0x24')]=new Sequence();};Migration[_0x5ba386('0xd')][_0x5ba386('0x14')]=function(_0x27c9ba,_0xdd9f7d,_0x313458){const _0x274d49=_0x5ba386,_0xe66a10=this;this[_0x274d49('0x24')][_0x274d49('0xc')](function(){const _0x5689cf=_0x274d49;return _0xe66a10[_0x5689cf('0x23')][_0x5689cf('0x14')](_0x27c9ba,_0xdd9f7d,_0x313458)[_0x5689cf('0xe')](function(){const _0x570301=_0x5689cf;logger[_0x570301('0x25')](_0x570301('0x20'),_0xdd9f7d,_0x27c9ba);})['catch'](function(_0x2de7a5){const _0x775f62=_0x5689cf;logger[_0x775f62('0x25')](JSON[_0x775f62('0x6')](_0x2de7a5));});});},Migration[_0x5ba386('0xd')][_0x5ba386('0x0')]=function(_0x903e49,_0x4a5322,_0x48bf63){const _0xd542ed=_0x5ba386,_0x4b59ac=this;this['sequence'][_0xd542ed('0xc')](function(){const _0x4f9a0a=_0xd542ed;return _0x4b59ac[_0x4f9a0a('0x23')][_0x4f9a0a('0x0')](_0x903e49,_0x4a5322,_0x48bf63)['then'](function(){const _0x282c4d=_0x4f9a0a;logger[_0x282c4d('0x25')](_0x282c4d('0x2'),_0x4a5322,_0x903e49);})[_0x4f9a0a('0x21')](function(_0x12ea2f){const _0x4aebc8=_0x4f9a0a;logger[_0x4aebc8('0x25')](JSON['stringify'](_0x12ea2f));});});},Migration[_0x5ba386('0xd')]['dropTable']=function(_0x53865e){const _0x3340c6=_0x5ba386,_0x1c48a0=this;this['sequence'][_0x3340c6('0xc')](function(){const _0x9ea579=_0x3340c6;return _0x1c48a0[_0x9ea579('0x23')]['dropTable'](_0x53865e,{'force':!![]})[_0x9ea579('0xe')](function(){const _0x2ca99e=_0x9ea579;logger[_0x2ca99e('0x25')](_0x2ca99e('0x18'),_0x53865e);})[_0x9ea579('0x21')](function(_0x36ce63){const _0x337668=_0x9ea579;logger[_0x337668('0x25')](JSON[_0x337668('0x6')](_0x36ce63));});});},Migration[_0x5ba386('0xd')][_0x5ba386('0xa')]=function(_0x16a145,_0x5a0c16,_0x214ca1){const _0x20ae34=_0x5ba386,_0x3486ea=this;this[_0x20ae34('0x24')][_0x20ae34('0xc')](function(){const _0x3889a9=_0x20ae34;return _0x3486ea['queryInterface'][_0x3889a9('0xa')](_0x16a145,_0x5a0c16,{'indexName':_0x214ca1})[_0x3889a9('0xe')](function(){const _0x4b8695=_0x3889a9;logger['info'](_0x4b8695('0x11'),_0x16a145,_0x5a0c16[_0x4b8695('0x1c')](','),_0x214ca1);})[_0x3889a9('0x21')](function(_0x1fe72d){const _0x11d8e1=_0x3889a9;logger[_0x11d8e1('0x25')](JSON['stringify'](_0x1fe72d));});});},Migration['prototype'][_0x5ba386('0x3')]=function(_0x16549f,_0x15ea83){const _0x2aa76d=_0x5ba386,_0x3af170=this;this['sequence'][_0x2aa76d('0xc')](function(){const _0xa5a26d=_0x2aa76d;return _0x3af170[_0xa5a26d('0x23')][_0xa5a26d('0x3')](_0x16549f,_0x15ea83)[_0xa5a26d('0xe')](function(){const _0x496642=_0xa5a26d;logger[_0x496642('0x25')](_0x496642('0x19'),_0x16549f,_0x15ea83);})[_0xa5a26d('0x21')](function(_0x5529de){const _0x5494ff=_0xa5a26d;logger[_0x5494ff('0x25')](JSON[_0x5494ff('0x6')](_0x5529de));});});},Migration[_0x5ba386('0xd')][_0x5ba386('0x1a')]=function(_0xacd80d){const _0x11a6bb=_0x5ba386,_0x472913=this;this[_0x11a6bb('0x24')][_0x11a6bb('0xc')](function(){const _0x31c8c0=_0x11a6bb;return _0x472913[_0x31c8c0('0x23')][_0x31c8c0('0x1f')]['query'](_0xacd80d)[_0x31c8c0('0xe')](function(){const _0xff2630=_0x31c8c0;logger[_0xff2630('0x25')](_0xff2630('0x12'),_0xacd80d);})[_0x31c8c0('0x21')](function(_0x2759bd){const _0x20be49=_0x31c8c0;logger[_0x20be49('0x25')](JSON[_0x20be49('0x6')](_0x2759bd));});});},Migration[_0x5ba386('0xd')][_0x5ba386('0x5')]=function(_0x1f24e2,_0x5b0d35){const _0xf500c8=_0x5ba386,_0x50d03b=this;this[_0xf500c8('0x24')][_0xf500c8('0xc')](function(){const _0x216cf9=_0xf500c8;return _0x50d03b['queryInterface'][_0x216cf9('0x5')](_0x1f24e2,_0x5b0d35)[_0x216cf9('0xe')](function(){const _0x49c4d8=_0x216cf9;logger[_0x49c4d8('0x25')](_0x49c4d8('0x10'),_0x5b0d35,_0x1f24e2);})['catch'](function(_0x29b943){const _0x1eec3a=_0x216cf9;logger[_0x1eec3a('0x25')](util[_0x1eec3a('0x7')](_0x29b943,{'showHidden':![],'depth':null}));});});},Migration[_0x5ba386('0xd')]['renameColumn']=function(_0x26ef9d,_0x213341,_0x26797f){const _0x553840=this;this['sequence']['enqueue'](function(){const _0x452758=a972_0x51d5;return _0x553840[_0x452758('0x23')][_0x452758('0x13')](_0x26ef9d,_0x213341,_0x26797f)[_0x452758('0xe')](function(){const _0x4af5fe=_0x452758;logger[_0x4af5fe('0x25')](_0x4af5fe('0x9'),_0x213341,_0x26797f,_0x26ef9d);})[_0x452758('0x21')](function(_0x2f5da0){const _0x1b7faa=_0x452758;logger['info'](util[_0x1b7faa('0x7')](_0x2f5da0,{'showHidden':![],'depth':null}));});});},Migration[_0x5ba386('0xd')][_0x5ba386('0x1d')]=function(_0x5d45fd){const _0x56a757=_0x5ba386;this[_0x56a757('0x24')][_0x56a757('0xc')](function(){return _0x5d45fd();});},module[_0x5ba386('0x16')]={'up':function(_0x49ab7c,_0x89f337){return new Promise(function(_0x2346e6){const _0x3bbbb2=a972_0x51d5,_0x9a4e91=new Migration(_0x49ab7c);_0x9a4e91[_0x3bbbb2('0x0')](_0x3bbbb2('0x4'),'apiKeyNonce',{'type':_0x89f337[_0x3bbbb2('0xf')]}),_0x9a4e91[_0x3bbbb2('0x0')](_0x3bbbb2('0x4'),_0x3bbbb2('0x1e'),{'type':_0x89f337[_0x3bbbb2('0xf')]}),_0x9a4e91[_0x3bbbb2('0xa')](_0x3bbbb2('0x1b'),[_0x3bbbb2('0xb')],_0x3bbbb2('0xb')),_0x9a4e91['final'](_0x2346e6);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.1.js b/server/migrations/2.3.1.js index 48d1045..3c00d01 100644 --- a/server/migrations/2.3.1.js +++ b/server/migrations/2.3.1.js @@ -1 +1 @@ -const a973_0x4f1d=['sequelize','removeIndex','removeColumn','enqueue','finally','query','renameColumn','removeIndex\x20%s\x20%s','Removed\x20column\x20%s\x20from\x20%s','then','stringify','info','tail','migration','addIndex','inspect','addIndex\x20%s\x20%s\x20%s','exports','dropTable','catch','final','../config/logger','queryInterface','join','sequence','Added\x20column\x20%s\x20to\x20%s','prototype','changeColumn','addColumn'];(function(_0x1eb2e7,_0x4f1de7){const _0x426c84=function(_0xaf7a4a){while(--_0xaf7a4a){_0x1eb2e7['push'](_0x1eb2e7['shift']());}};_0x426c84(++_0x4f1de7);}(a973_0x4f1d,0x12b));const a973_0x426c=function(_0x1eb2e7,_0x4f1de7){_0x1eb2e7=_0x1eb2e7-0x0;let _0x426c84=a973_0x4f1d[_0x1eb2e7];return _0x426c84;};const _0x4e3899=a973_0x426c;'use strict';const util=require('util'),logger=require(_0x4e3899('0xc'))(_0x4e3899('0x4')),Sequence=function(){};Sequence[_0x4e3899('0x11')][_0x4e3899('0x17')]=function(_0xaf7a4a){const _0x4e3e47=_0x4e3899;this[_0x4e3e47('0x3')]=this[_0x4e3e47('0x3')]?this['tail'][_0x4e3e47('0x18')](_0xaf7a4a):_0xaf7a4a();};const Migration=function(_0x20e076){const _0x1bdae4=_0x4e3899;this[_0x1bdae4('0xd')]=_0x20e076,this[_0x1bdae4('0xf')]=new Sequence();};Migration['prototype'][_0x4e3899('0x12')]=function(_0x745906,_0x5e1fb5,_0x31059a){const _0x5bb168=_0x4e3899,_0x149f53=this;this['sequence'][_0x5bb168('0x17')](function(){const _0x3e604f=_0x5bb168;return _0x149f53[_0x3e604f('0xd')][_0x3e604f('0x12')](_0x745906,_0x5e1fb5,_0x31059a)[_0x3e604f('0x0')](function(){const _0x4a0f84=_0x3e604f;logger[_0x4a0f84('0x2')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x5e1fb5,_0x745906);})['catch'](function(_0x2f81d0){const _0x4117da=_0x3e604f;logger[_0x4117da('0x2')](JSON[_0x4117da('0x1')](_0x2f81d0));});});},Migration['prototype'][_0x4e3899('0x13')]=function(_0x5c229a,_0x397141,_0x42379b){const _0x53e895=this;this['sequence']['enqueue'](function(){const _0x129cdf=a973_0x426c;return _0x53e895['queryInterface'][_0x129cdf('0x13')](_0x5c229a,_0x397141,_0x42379b)[_0x129cdf('0x0')](function(){const _0x5c6553=_0x129cdf;logger[_0x5c6553('0x2')](_0x5c6553('0x10'),_0x397141,_0x5c229a);})['catch'](function(_0xac6226){const _0x4da0b0=_0x129cdf;logger[_0x4da0b0('0x2')](JSON[_0x4da0b0('0x1')](_0xac6226));});});},Migration[_0x4e3899('0x11')][_0x4e3899('0x9')]=function(_0x158b44){const _0x15aeda=_0x4e3899,_0x45d730=this;this[_0x15aeda('0xf')][_0x15aeda('0x17')](function(){const _0x546774=_0x15aeda;return _0x45d730[_0x546774('0xd')][_0x546774('0x9')](_0x158b44,{'force':!![]})[_0x546774('0x0')](function(){logger['info']('table\x20dropped\x20%s',_0x158b44);})['catch'](function(_0x5c1ace){const _0x2218a7=_0x546774;logger[_0x2218a7('0x2')](JSON[_0x2218a7('0x1')](_0x5c1ace));});});},Migration[_0x4e3899('0x11')]['addIndex']=function(_0x29c75c,_0x342ca7,_0x136c3f){const _0x2ff6b6=_0x4e3899,_0x1ad3ef=this;this[_0x2ff6b6('0xf')][_0x2ff6b6('0x17')](function(){const _0x24b034=_0x2ff6b6;return _0x1ad3ef[_0x24b034('0xd')][_0x24b034('0x5')](_0x29c75c,_0x342ca7,{'indexName':_0x136c3f})[_0x24b034('0x0')](function(){const _0x27a863=_0x24b034;logger[_0x27a863('0x2')](_0x27a863('0x7'),_0x29c75c,_0x342ca7[_0x27a863('0xe')](','),_0x136c3f);})['catch'](function(_0x19b21c){const _0x1b053c=_0x24b034;logger[_0x1b053c('0x2')](JSON['stringify'](_0x19b21c));});});},Migration['prototype'][_0x4e3899('0x15')]=function(_0x5055e6,_0x14e554){const _0x4da64e=_0x4e3899,_0x299736=this;this[_0x4da64e('0xf')][_0x4da64e('0x17')](function(){const _0x431aba=_0x4da64e;return _0x299736[_0x431aba('0xd')][_0x431aba('0x15')](_0x5055e6,_0x14e554)[_0x431aba('0x0')](function(){const _0x5d5fc7=_0x431aba;logger[_0x5d5fc7('0x2')](_0x5d5fc7('0x1b'),_0x5055e6,_0x14e554);})[_0x431aba('0xa')](function(_0x15196c){const _0x5acd3c=_0x431aba;logger[_0x5acd3c('0x2')](JSON[_0x5acd3c('0x1')](_0x15196c));});});},Migration[_0x4e3899('0x11')]['query']=function(_0x349608){const _0x1bcd98=_0x4e3899,_0x1eed09=this;this[_0x1bcd98('0xf')][_0x1bcd98('0x17')](function(){const _0x3cad44=_0x1bcd98;return _0x1eed09[_0x3cad44('0xd')][_0x3cad44('0x14')][_0x3cad44('0x19')](_0x349608)[_0x3cad44('0x0')](function(){const _0x464280=_0x3cad44;logger[_0x464280('0x2')]('query\x20%s',_0x349608);})[_0x3cad44('0xa')](function(_0x521cdd){const _0x4abdd4=_0x3cad44;logger[_0x4abdd4('0x2')](JSON[_0x4abdd4('0x1')](_0x521cdd));});});},Migration[_0x4e3899('0x11')][_0x4e3899('0x16')]=function(_0x14cb35,_0x3e1996){const _0xf8f83d=_0x4e3899,_0x170459=this;this['sequence'][_0xf8f83d('0x17')](function(){const _0x17b4ee=_0xf8f83d;return _0x170459[_0x17b4ee('0xd')][_0x17b4ee('0x16')](_0x14cb35,_0x3e1996)[_0x17b4ee('0x0')](function(){const _0x46b288=_0x17b4ee;logger[_0x46b288('0x2')](_0x46b288('0x1c'),_0x3e1996,_0x14cb35);})['catch'](function(_0x9f9fe8){const _0x344b50=_0x17b4ee;logger[_0x344b50('0x2')](util['inspect'](_0x9f9fe8,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x4e3899('0x1a')]=function(_0x97c949,_0x358d71,_0x23847c){const _0x5b8eeb=_0x4e3899,_0x13abda=this;this[_0x5b8eeb('0xf')][_0x5b8eeb('0x17')](function(){const _0x124d6a=_0x5b8eeb;return _0x13abda[_0x124d6a('0xd')][_0x124d6a('0x1a')](_0x97c949,_0x358d71,_0x23847c)[_0x124d6a('0x0')](function(){const _0x37ac0f=_0x124d6a;logger[_0x37ac0f('0x2')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x358d71,_0x23847c,_0x97c949);})[_0x124d6a('0xa')](function(_0x341f72){const _0x108d8e=_0x124d6a;logger[_0x108d8e('0x2')](util[_0x108d8e('0x6')](_0x341f72,{'showHidden':![],'depth':null}));});});},Migration[_0x4e3899('0x11')][_0x4e3899('0xb')]=function(_0x321eb0){const _0x34b839=_0x4e3899;this[_0x34b839('0xf')][_0x34b839('0x17')](function(){return _0x321eb0();});},module[_0x4e3899('0x8')]={'up':function(_0x14f723){return new Promise(function(_0x37e69f){const _0x5a169f=new Migration(_0x14f723);_0x5a169f['final'](_0x37e69f);});},'down':function(){}}; \ No newline at end of file +const a973_0xc6dd=['util','addIndex\x20%s\x20%s\x20%s','exports','removeColumn','query','dropTable','addColumn','sequelize','inspect','removeIndex','removeIndex\x20%s\x20%s','changeColumn','renameColumn','sequence','finally','then','table\x20dropped\x20%s','tail','queryInterface','final','enqueue','stringify','prototype','info','addIndex','catch'];(function(_0x35f5c1,_0xc6dddc){const _0x26b052=function(_0x24afa5){while(--_0x24afa5){_0x35f5c1['push'](_0x35f5c1['shift']());}};_0x26b052(++_0xc6dddc);}(a973_0xc6dd,0x1c1));const a973_0x26b0=function(_0x35f5c1,_0xc6dddc){_0x35f5c1=_0x35f5c1-0x0;let _0x26b052=a973_0xc6dd[_0x35f5c1];return _0x26b052;};const _0x4f47e5=a973_0x26b0;'use strict';const util=require(_0x4f47e5('0x13')),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence[_0x4f47e5('0xf')][_0x4f47e5('0xd')]=function(_0x24afa5){const _0x18ca9f=_0x4f47e5;this[_0x18ca9f('0xa')]=this[_0x18ca9f('0xa')]?this[_0x18ca9f('0xa')][_0x18ca9f('0x7')](_0x24afa5):_0x24afa5();};const Migration=function(_0x127f33){const _0x407f92=_0x4f47e5;this[_0x407f92('0xb')]=_0x127f33,this['sequence']=new Sequence();};Migration[_0x4f47e5('0xf')][_0x4f47e5('0x4')]=function(_0x438363,_0x380431,_0x1ec29e){const _0x3ae857=_0x4f47e5,_0x8feb3d=this;this[_0x3ae857('0x6')][_0x3ae857('0xd')](function(){const _0x2899f1=_0x3ae857;return _0x8feb3d[_0x2899f1('0xb')][_0x2899f1('0x4')](_0x438363,_0x380431,_0x1ec29e)['then'](function(){const _0x42b1d5=_0x2899f1;logger[_0x42b1d5('0x10')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x380431,_0x438363);})[_0x2899f1('0x12')](function(_0x48e99a){logger['info'](JSON['stringify'](_0x48e99a));});});},Migration['prototype'][_0x4f47e5('0x19')]=function(_0x20d781,_0x803c7c,_0x44d70c){const _0x5d342f=_0x4f47e5,_0x3b7487=this;this[_0x5d342f('0x6')][_0x5d342f('0xd')](function(){const _0x307895=_0x5d342f;return _0x3b7487['queryInterface'][_0x307895('0x19')](_0x20d781,_0x803c7c,_0x44d70c)[_0x307895('0x8')](function(){const _0x39a928=_0x307895;logger[_0x39a928('0x10')]('Added\x20column\x20%s\x20to\x20%s',_0x803c7c,_0x20d781);})[_0x307895('0x12')](function(_0x4879f4){const _0x8431b0=_0x307895;logger[_0x8431b0('0x10')](JSON[_0x8431b0('0xe')](_0x4879f4));});});},Migration['prototype'][_0x4f47e5('0x18')]=function(_0x51270e){const _0xeed188=this;this['sequence']['enqueue'](function(){const _0x396862=a973_0x26b0;return _0xeed188[_0x396862('0xb')][_0x396862('0x18')](_0x51270e,{'force':!![]})[_0x396862('0x8')](function(){const _0x56bb8c=_0x396862;logger['info'](_0x56bb8c('0x9'),_0x51270e);})[_0x396862('0x12')](function(_0x5b95e9){const _0x289307=_0x396862;logger['info'](JSON[_0x289307('0xe')](_0x5b95e9));});});},Migration['prototype'][_0x4f47e5('0x11')]=function(_0x233d23,_0x4cdff3,_0x10fda0){const _0x557a03=_0x4f47e5,_0x9c7a89=this;this['sequence'][_0x557a03('0xd')](function(){const _0x295399=_0x557a03;return _0x9c7a89[_0x295399('0xb')][_0x295399('0x11')](_0x233d23,_0x4cdff3,{'indexName':_0x10fda0})[_0x295399('0x8')](function(){const _0x3f8b84=_0x295399;logger[_0x3f8b84('0x10')](_0x3f8b84('0x14'),_0x233d23,_0x4cdff3['join'](','),_0x10fda0);})['catch'](function(_0x2f867a){const _0x2e5203=_0x295399;logger[_0x2e5203('0x10')](JSON[_0x2e5203('0xe')](_0x2f867a));});});},Migration['prototype'][_0x4f47e5('0x2')]=function(_0x22667d,_0x579ca1){const _0x557719=_0x4f47e5,_0x1ec358=this;this['sequence'][_0x557719('0xd')](function(){const _0x25eaf5=_0x557719;return _0x1ec358[_0x25eaf5('0xb')][_0x25eaf5('0x2')](_0x22667d,_0x579ca1)[_0x25eaf5('0x8')](function(){const _0xe241dd=_0x25eaf5;logger[_0xe241dd('0x10')](_0xe241dd('0x3'),_0x22667d,_0x579ca1);})['catch'](function(_0x821756){const _0x569b2f=_0x25eaf5;logger[_0x569b2f('0x10')](JSON['stringify'](_0x821756));});});},Migration[_0x4f47e5('0xf')]['query']=function(_0x26c051){const _0x138bd3=_0x4f47e5,_0xd833ee=this;this[_0x138bd3('0x6')][_0x138bd3('0xd')](function(){const _0x35895a=_0x138bd3;return _0xd833ee[_0x35895a('0xb')][_0x35895a('0x0')][_0x35895a('0x17')](_0x26c051)[_0x35895a('0x8')](function(){logger['info']('query\x20%s',_0x26c051);})[_0x35895a('0x12')](function(_0x27f23e){const _0xf5c492=_0x35895a;logger[_0xf5c492('0x10')](JSON[_0xf5c492('0xe')](_0x27f23e));});});},Migration[_0x4f47e5('0xf')][_0x4f47e5('0x16')]=function(_0x2ecda7,_0x3e531a){const _0x20a9dc=_0x4f47e5,_0x31be26=this;this[_0x20a9dc('0x6')][_0x20a9dc('0xd')](function(){const _0x98f52b=_0x20a9dc;return _0x31be26['queryInterface'][_0x98f52b('0x16')](_0x2ecda7,_0x3e531a)[_0x98f52b('0x8')](function(){const _0x4650a9=_0x98f52b;logger[_0x4650a9('0x10')]('Removed\x20column\x20%s\x20from\x20%s',_0x3e531a,_0x2ecda7);})[_0x98f52b('0x12')](function(_0x42df3c){const _0x321729=_0x98f52b;logger[_0x321729('0x10')](util[_0x321729('0x1')](_0x42df3c,{'showHidden':![],'depth':null}));});});},Migration[_0x4f47e5('0xf')]['renameColumn']=function(_0x2e9a7d,_0x5b2c99,_0x582eb9){const _0xb4d316=_0x4f47e5,_0x2cf3ba=this;this[_0xb4d316('0x6')]['enqueue'](function(){const _0x3fc758=_0xb4d316;return _0x2cf3ba[_0x3fc758('0xb')][_0x3fc758('0x5')](_0x2e9a7d,_0x5b2c99,_0x582eb9)['then'](function(){const _0x16ae6f=_0x3fc758;logger[_0x16ae6f('0x10')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x5b2c99,_0x582eb9,_0x2e9a7d);})[_0x3fc758('0x12')](function(_0x3974df){const _0x544aff=_0x3fc758;logger[_0x544aff('0x10')](util['inspect'](_0x3974df,{'showHidden':![],'depth':null}));});});},Migration[_0x4f47e5('0xf')][_0x4f47e5('0xc')]=function(_0xa793d8){const _0x24fd9c=_0x4f47e5;this[_0x24fd9c('0x6')][_0x24fd9c('0xd')](function(){return _0xa793d8();});},module[_0x4f47e5('0x15')]={'up':function(_0x152c51){return new Promise(function(_0x224c55){const _0x472512=a973_0x26b0,_0x43530e=new Migration(_0x152c51);_0x43530e[_0x472512('0xc')](_0x224c55);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.10.js b/server/migrations/2.3.10.js index c9fed03..14a3034 100644 --- a/server/migrations/2.3.10.js +++ b/server/migrations/2.3.10.js @@ -1 +1 @@ -const a974_0x86c6=['Removed\x20column\x20%s\x20from\x20%s','enqueue','renameColumn','tail','queryInterface','catch','sipcallid','query\x20%s','addIndex','dropTable','removeIndex\x20%s\x20%s','final','addIndex\x20%s\x20%s\x20%s','finally','changeColumn','Added\x20column\x20%s\x20to\x20%s','util','Changed\x20column\x20%s\x20in\x20table\x20%s','then','info','query','join','table\x20dropped\x20%s','addColumn','removeIndex','inspect','prototype','migration','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','sequence','stringify','report_call'];(function(_0x18f7eb,_0x86c695){const _0x31bb6a=function(_0x58034e){while(--_0x58034e){_0x18f7eb['push'](_0x18f7eb['shift']());}};_0x31bb6a(++_0x86c695);}(a974_0x86c6,0x19a));const a974_0x31bb=function(_0x18f7eb,_0x86c695){_0x18f7eb=_0x18f7eb-0x0;let _0x31bb6a=a974_0x86c6[_0x18f7eb];return _0x31bb6a;};const _0xd2b905=a974_0x31bb;'use strict';const util=require(_0xd2b905('0x16')),logger=require('../config/logger')(_0xd2b905('0x1')),Sequence=function(){};Sequence[_0xd2b905('0x0')][_0xd2b905('0x7')]=function(_0x58034e){const _0x45638a=_0xd2b905;this['tail']=this[_0x45638a('0x9')]?this['tail'][_0x45638a('0x13')](_0x58034e):_0x58034e();};const Migration=function(_0x16b224){const _0x11a421=_0xd2b905;this[_0x11a421('0xa')]=_0x16b224,this[_0x11a421('0x3')]=new Sequence();};Migration[_0xd2b905('0x0')][_0xd2b905('0x14')]=function(_0x184205,_0x2fa403,_0x5e0a24){const _0x4f9336=_0xd2b905,_0x27b568=this;this[_0x4f9336('0x3')][_0x4f9336('0x7')](function(){const _0x280445=_0x4f9336;return _0x27b568[_0x280445('0xa')]['changeColumn'](_0x184205,_0x2fa403,_0x5e0a24)[_0x280445('0x18')](function(){const _0x15b688=_0x280445;logger['info'](_0x15b688('0x17'),_0x2fa403,_0x184205);})[_0x280445('0xb')](function(_0x22d053){const _0x17f9bc=_0x280445;logger[_0x17f9bc('0x19')](JSON[_0x17f9bc('0x4')](_0x22d053));});});},Migration[_0xd2b905('0x0')][_0xd2b905('0x1d')]=function(_0x1433ef,_0x5746d8,_0x4334de){const _0x1d9963=_0xd2b905,_0x2fa16c=this;this[_0x1d9963('0x3')][_0x1d9963('0x7')](function(){const _0x1b4b45=_0x1d9963;return _0x2fa16c[_0x1b4b45('0xa')][_0x1b4b45('0x1d')](_0x1433ef,_0x5746d8,_0x4334de)['then'](function(){const _0x56fd68=_0x1b4b45;logger[_0x56fd68('0x19')](_0x56fd68('0x15'),_0x5746d8,_0x1433ef);})[_0x1b4b45('0xb')](function(_0x4c01dd){const _0x48496b=_0x1b4b45;logger[_0x48496b('0x19')](JSON['stringify'](_0x4c01dd));});});},Migration[_0xd2b905('0x0')][_0xd2b905('0xf')]=function(_0x4e38ab){const _0x302d80=_0xd2b905,_0x474381=this;this['sequence'][_0x302d80('0x7')](function(){const _0x309d37=_0x302d80;return _0x474381[_0x309d37('0xa')][_0x309d37('0xf')](_0x4e38ab,{'force':!![]})['then'](function(){const _0x138b6e=_0x309d37;logger['info'](_0x138b6e('0x1c'),_0x4e38ab);})[_0x309d37('0xb')](function(_0x270813){const _0x9df0a1=_0x309d37;logger[_0x9df0a1('0x19')](JSON['stringify'](_0x270813));});});},Migration[_0xd2b905('0x0')]['addIndex']=function(_0x301ca2,_0x22ee18,_0x5f57fa){const _0x37105d=_0xd2b905,_0x22fb85=this;this[_0x37105d('0x3')]['enqueue'](function(){const _0x324d36=_0x37105d;return _0x22fb85[_0x324d36('0xa')][_0x324d36('0xe')](_0x301ca2,_0x22ee18,{'indexName':_0x5f57fa})[_0x324d36('0x18')](function(){const _0x136c30=_0x324d36;logger[_0x136c30('0x19')](_0x136c30('0x12'),_0x301ca2,_0x22ee18[_0x136c30('0x1b')](','),_0x5f57fa);})[_0x324d36('0xb')](function(_0x1d0569){const _0x16dae7=_0x324d36;logger[_0x16dae7('0x19')](JSON[_0x16dae7('0x4')](_0x1d0569));});});},Migration['prototype'][_0xd2b905('0x1e')]=function(_0xf7ba37,_0x8b972b){const _0x51ab87=_0xd2b905,_0x5151d1=this;this[_0x51ab87('0x3')][_0x51ab87('0x7')](function(){const _0x40e262=_0x51ab87;return _0x5151d1[_0x40e262('0xa')][_0x40e262('0x1e')](_0xf7ba37,_0x8b972b)['then'](function(){const _0xfc6cd=_0x40e262;logger[_0xfc6cd('0x19')](_0xfc6cd('0x10'),_0xf7ba37,_0x8b972b);})[_0x40e262('0xb')](function(_0x4d4ed4){const _0x428c93=_0x40e262;logger['info'](JSON[_0x428c93('0x4')](_0x4d4ed4));});});},Migration[_0xd2b905('0x0')][_0xd2b905('0x1a')]=function(_0x3123f2){const _0x139162=_0xd2b905,_0x57bd70=this;this[_0x139162('0x3')][_0x139162('0x7')](function(){const _0x2feb6a=_0x139162;return _0x57bd70['queryInterface']['sequelize']['query'](_0x3123f2)[_0x2feb6a('0x18')](function(){const _0x26a0fd=_0x2feb6a;logger[_0x26a0fd('0x19')](_0x26a0fd('0xd'),_0x3123f2);})[_0x2feb6a('0xb')](function(_0x2d9b8f){const _0x421056=_0x2feb6a;logger[_0x421056('0x19')](JSON[_0x421056('0x4')](_0x2d9b8f));});});},Migration['prototype']['removeColumn']=function(_0x195062,_0x2ee752){const _0x499ff6=_0xd2b905,_0x162e69=this;this[_0x499ff6('0x3')]['enqueue'](function(){const _0x14ce57=_0x499ff6;return _0x162e69[_0x14ce57('0xa')]['removeColumn'](_0x195062,_0x2ee752)['then'](function(){const _0x9507fb=_0x14ce57;logger[_0x9507fb('0x19')](_0x9507fb('0x6'),_0x2ee752,_0x195062);})['catch'](function(_0x5c321b){const _0x2042b5=_0x14ce57;logger[_0x2042b5('0x19')](util[_0x2042b5('0x1f')](_0x5c321b,{'showHidden':![],'depth':null}));});});},Migration[_0xd2b905('0x0')]['renameColumn']=function(_0x9c88ad,_0x8d69db,_0x1779f5){const _0x582d6b=_0xd2b905,_0x1fa610=this;this[_0x582d6b('0x3')]['enqueue'](function(){const _0x49308b=_0x582d6b;return _0x1fa610['queryInterface'][_0x49308b('0x8')](_0x9c88ad,_0x8d69db,_0x1779f5)['then'](function(){const _0x118bbb=_0x49308b;logger[_0x118bbb('0x19')](_0x118bbb('0x2'),_0x8d69db,_0x1779f5,_0x9c88ad);})[_0x49308b('0xb')](function(_0x1efd73){const _0x5a6440=_0x49308b;logger[_0x5a6440('0x19')](util[_0x5a6440('0x1f')](_0x1efd73,{'showHidden':![],'depth':null}));});});},Migration[_0xd2b905('0x0')][_0xd2b905('0x11')]=function(_0x4dd580){const _0x1d7552=_0xd2b905;this[_0x1d7552('0x3')]['enqueue'](function(){return _0x4dd580();});},module['exports']={'up':function(_0x23e759,_0x4eaaba){return new Promise(function(_0x438e73){const _0xa1d2eb=a974_0x31bb,_0x2d3d18=new Migration(_0x23e759);_0x2d3d18[_0xa1d2eb('0x1d')](_0xa1d2eb('0x5'),_0xa1d2eb('0xc'),{'type':_0x4eaaba['STRING']}),_0x2d3d18[_0xa1d2eb('0x11')](_0x438e73);});},'down':function(){}}; \ No newline at end of file +const a974_0x5b02=['join','finally','enqueue','removeIndex\x20%s\x20%s','addIndex','removeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','renameColumn','tail','sequence','addIndex\x20%s\x20%s\x20%s','dropTable','catch','info','query\x20%s','Added\x20column\x20%s\x20to\x20%s','changeColumn','STRING','inspect','sipcallid','../config/logger','Removed\x20column\x20%s\x20from\x20%s','prototype','then','Changed\x20column\x20%s\x20in\x20table\x20%s','final','migration','addColumn','stringify','query','removeIndex','queryInterface'];(function(_0x2dd815,_0x5b029d){const _0x22e410=function(_0x53ab44){while(--_0x53ab44){_0x2dd815['push'](_0x2dd815['shift']());}};_0x22e410(++_0x5b029d);}(a974_0x5b02,0xb3));const a974_0x22e4=function(_0x2dd815,_0x5b029d){_0x2dd815=_0x2dd815-0x0;let _0x22e410=a974_0x5b02[_0x2dd815];return _0x22e410;};const _0x463342=a974_0x22e4;'use strict';const util=require('util'),logger=require(_0x463342('0x1'))(_0x463342('0x7')),Sequence=function(){};Sequence[_0x463342('0x3')][_0x463342('0xf')]=function(_0x53ab44){const _0x1d09b8=_0x463342;this[_0x1d09b8('0x15')]=this[_0x1d09b8('0x15')]?this[_0x1d09b8('0x15')][_0x1d09b8('0xe')](_0x53ab44):_0x53ab44();};const Migration=function(_0x2cb700){const _0x1e1093=_0x463342;this['queryInterface']=_0x2cb700,this[_0x1e1093('0x16')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x4943cc,_0x4e6c3d,_0x51f2a3){const _0xac8f06=_0x463342,_0x38fa5d=this;this[_0xac8f06('0x16')][_0xac8f06('0xf')](function(){const _0x3f8e2a=_0xac8f06;return _0x38fa5d[_0x3f8e2a('0xc')][_0x3f8e2a('0x1d')](_0x4943cc,_0x4e6c3d,_0x51f2a3)[_0x3f8e2a('0x4')](function(){const _0x5d7c21=_0x3f8e2a;logger[_0x5d7c21('0x1a')](_0x5d7c21('0x5'),_0x4e6c3d,_0x4943cc);})[_0x3f8e2a('0x19')](function(_0x38fb74){const _0xfa9fbf=_0x3f8e2a;logger[_0xfa9fbf('0x1a')](JSON['stringify'](_0x38fb74));});});},Migration[_0x463342('0x3')][_0x463342('0x8')]=function(_0x21d673,_0x5c292d,_0x242879){const _0x654cf3=_0x463342,_0x3d41ab=this;this[_0x654cf3('0x16')][_0x654cf3('0xf')](function(){const _0x11fa91=_0x654cf3;return _0x3d41ab[_0x11fa91('0xc')]['addColumn'](_0x21d673,_0x5c292d,_0x242879)['then'](function(){const _0x3f9562=_0x11fa91;logger['info'](_0x3f9562('0x1c'),_0x5c292d,_0x21d673);})[_0x11fa91('0x19')](function(_0x51eefa){logger['info'](JSON['stringify'](_0x51eefa));});});},Migration[_0x463342('0x3')][_0x463342('0x18')]=function(_0x6f0456){const _0xfe706f=_0x463342,_0x1b7769=this;this[_0xfe706f('0x16')]['enqueue'](function(){const _0x33bdb9=_0xfe706f;return _0x1b7769[_0x33bdb9('0xc')][_0x33bdb9('0x18')](_0x6f0456,{'force':!![]})['then'](function(){const _0x31ff59=_0x33bdb9;logger[_0x31ff59('0x1a')]('table\x20dropped\x20%s',_0x6f0456);})[_0x33bdb9('0x19')](function(_0x1ff8b3){const _0x22d1da=_0x33bdb9;logger['info'](JSON[_0x22d1da('0x9')](_0x1ff8b3));});});},Migration['prototype']['addIndex']=function(_0x2e3db8,_0x29da3c,_0x2e93c0){const _0xd4cb2c=_0x463342,_0x2c8dbd=this;this[_0xd4cb2c('0x16')][_0xd4cb2c('0xf')](function(){const _0x26cbbb=_0xd4cb2c;return _0x2c8dbd['queryInterface'][_0x26cbbb('0x11')](_0x2e3db8,_0x29da3c,{'indexName':_0x2e93c0})[_0x26cbbb('0x4')](function(){const _0xdad2cf=_0x26cbbb;logger[_0xdad2cf('0x1a')](_0xdad2cf('0x17'),_0x2e3db8,_0x29da3c[_0xdad2cf('0xd')](','),_0x2e93c0);})[_0x26cbbb('0x19')](function(_0x486df3){const _0x216f4b=_0x26cbbb;logger[_0x216f4b('0x1a')](JSON[_0x216f4b('0x9')](_0x486df3));});});},Migration['prototype'][_0x463342('0xb')]=function(_0x3b664a,_0xa2022){const _0x493fba=_0x463342,_0x341ee4=this;this[_0x493fba('0x16')][_0x493fba('0xf')](function(){const _0x4021ff=_0x493fba;return _0x341ee4[_0x4021ff('0xc')][_0x4021ff('0xb')](_0x3b664a,_0xa2022)[_0x4021ff('0x4')](function(){const _0x4f678e=_0x4021ff;logger[_0x4f678e('0x1a')](_0x4f678e('0x10'),_0x3b664a,_0xa2022);})[_0x4021ff('0x19')](function(_0x558ef0){const _0x497e3e=_0x4021ff;logger[_0x497e3e('0x1a')](JSON['stringify'](_0x558ef0));});});},Migration[_0x463342('0x3')][_0x463342('0xa')]=function(_0x91ad18){const _0x231556=_0x463342,_0x2ca5fe=this;this['sequence'][_0x231556('0xf')](function(){const _0x4f38ac=_0x231556;return _0x2ca5fe['queryInterface']['sequelize']['query'](_0x91ad18)[_0x4f38ac('0x4')](function(){const _0x30c86e=_0x4f38ac;logger['info'](_0x30c86e('0x1b'),_0x91ad18);})[_0x4f38ac('0x19')](function(_0x26d0d9){const _0x5ef896=_0x4f38ac;logger['info'](JSON[_0x5ef896('0x9')](_0x26d0d9));});});},Migration[_0x463342('0x3')][_0x463342('0x12')]=function(_0x14eaca,_0x1e7aa0){const _0x22c86a=_0x463342,_0x5221b6=this;this[_0x22c86a('0x16')]['enqueue'](function(){const _0x11b93f=_0x22c86a;return _0x5221b6[_0x11b93f('0xc')][_0x11b93f('0x12')](_0x14eaca,_0x1e7aa0)[_0x11b93f('0x4')](function(){const _0x62da7f=_0x11b93f;logger[_0x62da7f('0x1a')](_0x62da7f('0x2'),_0x1e7aa0,_0x14eaca);})['catch'](function(_0x58d169){const _0x56829a=_0x11b93f;logger['info'](util[_0x56829a('0x1f')](_0x58d169,{'showHidden':![],'depth':null}));});});},Migration['prototype']['renameColumn']=function(_0x17b28b,_0x5b26b3,_0x2a1343){const _0x3713ce=_0x463342,_0x2b341e=this;this[_0x3713ce('0x16')][_0x3713ce('0xf')](function(){const _0xf93158=_0x3713ce;return _0x2b341e[_0xf93158('0xc')][_0xf93158('0x14')](_0x17b28b,_0x5b26b3,_0x2a1343)[_0xf93158('0x4')](function(){const _0x53fcea=_0xf93158;logger[_0x53fcea('0x1a')](_0x53fcea('0x13'),_0x5b26b3,_0x2a1343,_0x17b28b);})[_0xf93158('0x19')](function(_0x17498a){const _0x2eeb86=_0xf93158;logger[_0x2eeb86('0x1a')](util[_0x2eeb86('0x1f')](_0x17498a,{'showHidden':![],'depth':null}));});});},Migration[_0x463342('0x3')][_0x463342('0x6')]=function(_0x5aae91){const _0x36afc4=_0x463342;this[_0x36afc4('0x16')][_0x36afc4('0xf')](function(){return _0x5aae91();});},module['exports']={'up':function(_0x1f8371,_0x5f1023){return new Promise(function(_0x3d0326){const _0x2887a5=a974_0x22e4,_0x25f15a=new Migration(_0x1f8371);_0x25f15a[_0x2887a5('0x8')]('report_call',_0x2887a5('0x0'),{'type':_0x5f1023[_0x2887a5('0x1e')]}),_0x25f15a['final'](_0x3d0326);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.2.js b/server/migrations/2.3.2.js index 9890195..ce57915 100644 --- a/server/migrations/2.3.2.js +++ b/server/migrations/2.3.2.js @@ -1 +1 @@ -const a975_0x4461=['table\x20dropped\x20%s','addIndex','removeIndex\x20%s\x20%s','removeColumn','migration','sequelize','dropTable','changeColumn','exports','tail','Removed\x20column\x20%s\x20from\x20%s','inspect','stringify','sequence','info','renameColumn','then','Changed\x20column\x20%s\x20in\x20table\x20%s','prototype','../config/logger','ALTER\x20TABLE\x20int_dynamics365_accounts\x20ENCRYPTION=\x27Y\x27;','enqueue','removeIndex','addIndex\x20%s\x20%s\x20%s','final','Added\x20column\x20%s\x20to\x20%s','queryInterface','BOOLEAN','addColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','query','settings','util','ALTER\x20TABLE\x20int_servicenow_accounts\x20ENCRYPTION=\x27Y\x27;','catch','query\x20%s'];(function(_0x56e6af,_0x4461cf){const _0x2b6ead=function(_0x5c0566){while(--_0x5c0566){_0x56e6af['push'](_0x56e6af['shift']());}};_0x2b6ead(++_0x4461cf);}(a975_0x4461,0x1c3));const a975_0x2b6e=function(_0x56e6af,_0x4461cf){_0x56e6af=_0x56e6af-0x0;let _0x2b6ead=a975_0x4461[_0x56e6af];return _0x2b6ead;};const _0x1054dd=a975_0x2b6e;'use strict';const util=require(_0x1054dd('0xd')),logger=require(_0x1054dd('0x0'))(_0x1054dd('0x15')),Sequence=function(){};Sequence[_0x1054dd('0x23')][_0x1054dd('0x2')]=function(_0x5c0566){const _0x574323=_0x1054dd;this[_0x574323('0x1a')]=this['tail']?this[_0x574323('0x1a')]['finally'](_0x5c0566):_0x5c0566();};const Migration=function(_0xea46a3){const _0x62e58b=_0x1054dd;this[_0x62e58b('0x7')]=_0xea46a3,this['sequence']=new Sequence();};Migration[_0x1054dd('0x23')]['changeColumn']=function(_0x4630bf,_0x3ab2e4,_0x4c6e77){const _0x58ea05=_0x1054dd,_0x5172e0=this;this[_0x58ea05('0x1e')]['enqueue'](function(){const _0x849f68=_0x58ea05;return _0x5172e0[_0x849f68('0x7')][_0x849f68('0x18')](_0x4630bf,_0x3ab2e4,_0x4c6e77)[_0x849f68('0x21')](function(){const _0x345810=_0x849f68;logger['info'](_0x345810('0x22'),_0x3ab2e4,_0x4630bf);})[_0x849f68('0xf')](function(_0x3ae0fd){const _0x8c5359=_0x849f68;logger['info'](JSON[_0x8c5359('0x1d')](_0x3ae0fd));});});},Migration['prototype'][_0x1054dd('0x9')]=function(_0x5f458d,_0x36af6b,_0xeb0ff1){const _0x396ab5=_0x1054dd,_0x545c97=this;this[_0x396ab5('0x1e')][_0x396ab5('0x2')](function(){const _0x33cb61=_0x396ab5;return _0x545c97[_0x33cb61('0x7')][_0x33cb61('0x9')](_0x5f458d,_0x36af6b,_0xeb0ff1)['then'](function(){const _0x175b70=_0x33cb61;logger[_0x175b70('0x1f')](_0x175b70('0x6'),_0x36af6b,_0x5f458d);})['catch'](function(_0x1a30f2){const _0x9e8796=_0x33cb61;logger[_0x9e8796('0x1f')](JSON['stringify'](_0x1a30f2));});});},Migration[_0x1054dd('0x23')][_0x1054dd('0x17')]=function(_0x34964f){const _0x5a930c=_0x1054dd,_0x310900=this;this[_0x5a930c('0x1e')][_0x5a930c('0x2')](function(){const _0x235677=_0x5a930c;return _0x310900[_0x235677('0x7')][_0x235677('0x17')](_0x34964f,{'force':!![]})[_0x235677('0x21')](function(){const _0x5ed955=_0x235677;logger['info'](_0x5ed955('0x11'),_0x34964f);})[_0x235677('0xf')](function(_0x4cc7e3){const _0x4e8952=_0x235677;logger[_0x4e8952('0x1f')](JSON['stringify'](_0x4cc7e3));});});},Migration['prototype'][_0x1054dd('0x12')]=function(_0x20becd,_0x27fc61,_0x28d1cc){const _0x23afc2=_0x1054dd,_0x3b7036=this;this['sequence'][_0x23afc2('0x2')](function(){const _0x5f3f55=_0x23afc2;return _0x3b7036[_0x5f3f55('0x7')][_0x5f3f55('0x12')](_0x20becd,_0x27fc61,{'indexName':_0x28d1cc})[_0x5f3f55('0x21')](function(){const _0x4fc57f=_0x5f3f55;logger[_0x4fc57f('0x1f')](_0x4fc57f('0x4'),_0x20becd,_0x27fc61['join'](','),_0x28d1cc);})[_0x5f3f55('0xf')](function(_0x4ee4b5){const _0x2e8688=_0x5f3f55;logger[_0x2e8688('0x1f')](JSON['stringify'](_0x4ee4b5));});});},Migration[_0x1054dd('0x23')][_0x1054dd('0x3')]=function(_0x55fa41,_0x50dd8c){const _0x1315d5=_0x1054dd,_0x15f9d1=this;this['sequence'][_0x1315d5('0x2')](function(){const _0x367d6c=_0x1315d5;return _0x15f9d1['queryInterface'][_0x367d6c('0x3')](_0x55fa41,_0x50dd8c)['then'](function(){const _0xd372e3=_0x367d6c;logger[_0xd372e3('0x1f')](_0xd372e3('0x13'),_0x55fa41,_0x50dd8c);})[_0x367d6c('0xf')](function(_0x2c891e){const _0x14bffd=_0x367d6c;logger['info'](JSON[_0x14bffd('0x1d')](_0x2c891e));});});},Migration['prototype'][_0x1054dd('0xb')]=function(_0x13a095){const _0x306c57=_0x1054dd,_0x437c27=this;this['sequence'][_0x306c57('0x2')](function(){const _0x3aa9f3=_0x306c57;return _0x437c27['queryInterface'][_0x3aa9f3('0x16')][_0x3aa9f3('0xb')](_0x13a095)[_0x3aa9f3('0x21')](function(){const _0x4c37c9=_0x3aa9f3;logger[_0x4c37c9('0x1f')](_0x4c37c9('0x10'),_0x13a095);})[_0x3aa9f3('0xf')](function(_0xb6cee3){const _0x5645b2=_0x3aa9f3;logger[_0x5645b2('0x1f')](JSON[_0x5645b2('0x1d')](_0xb6cee3));});});},Migration[_0x1054dd('0x23')][_0x1054dd('0x14')]=function(_0x834eb8,_0x4fa4a1){const _0x4aad65=_0x1054dd,_0x2d7e41=this;this[_0x4aad65('0x1e')][_0x4aad65('0x2')](function(){const _0x52433b=_0x4aad65;return _0x2d7e41[_0x52433b('0x7')][_0x52433b('0x14')](_0x834eb8,_0x4fa4a1)[_0x52433b('0x21')](function(){const _0x415510=_0x52433b;logger[_0x415510('0x1f')](_0x415510('0x1b'),_0x4fa4a1,_0x834eb8);})[_0x52433b('0xf')](function(_0x414431){const _0x3a3cad=_0x52433b;logger['info'](util[_0x3a3cad('0x1c')](_0x414431,{'showHidden':![],'depth':null}));});});},Migration[_0x1054dd('0x23')][_0x1054dd('0x20')]=function(_0x39e3b5,_0x3df9e8,_0x230217){const _0x335bf2=_0x1054dd,_0x541e3b=this;this['sequence'][_0x335bf2('0x2')](function(){const _0x3205da=_0x335bf2;return _0x541e3b[_0x3205da('0x7')][_0x3205da('0x20')](_0x39e3b5,_0x3df9e8,_0x230217)['then'](function(){const _0x3ec639=_0x3205da;logger[_0x3ec639('0x1f')](_0x3ec639('0xa'),_0x3df9e8,_0x230217,_0x39e3b5);})[_0x3205da('0xf')](function(_0x5e62a2){logger['info'](util['inspect'](_0x5e62a2,{'showHidden':![],'depth':null}));});});},Migration[_0x1054dd('0x23')]['final']=function(_0x373f07){const _0x1c6ff4=_0x1054dd;this[_0x1c6ff4('0x1e')][_0x1c6ff4('0x2')](function(){return _0x373f07();});},module[_0x1054dd('0x19')]={'up':function(_0x423af,_0x27ed9d){return new Promise(function(_0x2fc276){const _0x59e7dc=a975_0x2b6e,_0x4b00ad=new Migration(_0x423af);_0x4b00ad['query'](_0x59e7dc('0x1')),_0x4b00ad[_0x59e7dc('0xb')](_0x59e7dc('0xe')),_0x4b00ad[_0x59e7dc('0x9')](_0x59e7dc('0xc'),'rtlSupport',{'type':_0x27ed9d[_0x59e7dc('0x8')],'defaultValue':![]}),_0x4b00ad[_0x59e7dc('0x5')](_0x2fc276);});},'down':function(){}}; \ No newline at end of file +const a975_0x1415=['query\x20%s','removeIndex','table\x20dropped\x20%s','rtlSupport','Changed\x20column\x20%s\x20in\x20table\x20%s','then','../config/logger','stringify','Added\x20column\x20%s\x20to\x20%s','sequelize','addColumn','removeIndex\x20%s\x20%s','catch','join','changeColumn','removeColumn','info','renameColumn','sequence','query','dropTable','queryInterface','finally','ALTER\x20TABLE\x20int_dynamics365_accounts\x20ENCRYPTION=\x27Y\x27;','exports','inspect','tail','prototype','addIndex','migration','addIndex\x20%s\x20%s\x20%s','settings','BOOLEAN','enqueue','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s'];(function(_0x4aa428,_0x1415a9){const _0x2b1f92=function(_0x3f2548){while(--_0x3f2548){_0x4aa428['push'](_0x4aa428['shift']());}};_0x2b1f92(++_0x1415a9);}(a975_0x1415,0x182));const a975_0x2b1f=function(_0x4aa428,_0x1415a9){_0x4aa428=_0x4aa428-0x0;let _0x2b1f92=a975_0x1415[_0x4aa428];return _0x2b1f92;};const _0xffa9e1=a975_0x2b1f;'use strict';const util=require('util'),logger=require(_0xffa9e1('0x5'))(_0xffa9e1('0x1c')),Sequence=function(){};Sequence[_0xffa9e1('0x1a')]['enqueue']=function(_0x3f2548){const _0x2d2306=_0xffa9e1;this[_0x2d2306('0x19')]=this[_0x2d2306('0x19')]?this['tail'][_0x2d2306('0x15')](_0x3f2548):_0x3f2548();};const Migration=function(_0x4294ed){const _0x23a5f2=_0xffa9e1;this[_0x23a5f2('0x14')]=_0x4294ed,this[_0x23a5f2('0x11')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x214948,_0x9fe1eb,_0x3cd699){const _0x52a102=_0xffa9e1,_0xb86d0d=this;this['sequence'][_0x52a102('0x20')](function(){const _0x575d99=_0x52a102;return _0xb86d0d['queryInterface'][_0x575d99('0xd')](_0x214948,_0x9fe1eb,_0x3cd699)[_0x575d99('0x4')](function(){const _0x352a3e=_0x575d99;logger['info'](_0x352a3e('0x3'),_0x9fe1eb,_0x214948);})[_0x575d99('0xb')](function(_0x342a38){logger['info'](JSON['stringify'](_0x342a38));});});},Migration['prototype'][_0xffa9e1('0x9')]=function(_0x148bd3,_0x3aeaf1,_0x40510d){const _0x200370=_0xffa9e1,_0x1c7e60=this;this['sequence'][_0x200370('0x20')](function(){const _0x1fa889=_0x200370;return _0x1c7e60[_0x1fa889('0x14')][_0x1fa889('0x9')](_0x148bd3,_0x3aeaf1,_0x40510d)['then'](function(){const _0x551349=_0x1fa889;logger[_0x551349('0xf')](_0x551349('0x7'),_0x3aeaf1,_0x148bd3);})[_0x1fa889('0xb')](function(_0x593017){const _0x5bedd4=_0x1fa889;logger[_0x5bedd4('0xf')](JSON[_0x5bedd4('0x6')](_0x593017));});});},Migration[_0xffa9e1('0x1a')][_0xffa9e1('0x13')]=function(_0x176d58){const _0x17231f=_0xffa9e1,_0x36c254=this;this[_0x17231f('0x11')][_0x17231f('0x20')](function(){const _0x229f4e=_0x17231f;return _0x36c254[_0x229f4e('0x14')][_0x229f4e('0x13')](_0x176d58,{'force':!![]})[_0x229f4e('0x4')](function(){const _0x37ef66=_0x229f4e;logger[_0x37ef66('0xf')](_0x37ef66('0x1'),_0x176d58);})[_0x229f4e('0xb')](function(_0x404409){const _0x380140=_0x229f4e;logger['info'](JSON[_0x380140('0x6')](_0x404409));});});},Migration[_0xffa9e1('0x1a')][_0xffa9e1('0x1b')]=function(_0x52ab7e,_0x5207fb,_0x459672){const _0xf889b=_0xffa9e1,_0x29815a=this;this[_0xf889b('0x11')][_0xf889b('0x20')](function(){const _0x489481=_0xf889b;return _0x29815a[_0x489481('0x14')][_0x489481('0x1b')](_0x52ab7e,_0x5207fb,{'indexName':_0x459672})['then'](function(){const _0x5ed1de=_0x489481;logger[_0x5ed1de('0xf')](_0x5ed1de('0x1d'),_0x52ab7e,_0x5207fb[_0x5ed1de('0xc')](','),_0x459672);})['catch'](function(_0x1670ca){const _0x1873ba=_0x489481;logger[_0x1873ba('0xf')](JSON['stringify'](_0x1670ca));});});},Migration[_0xffa9e1('0x1a')][_0xffa9e1('0x0')]=function(_0x15d970,_0x211fb8){const _0x54a49d=_0xffa9e1,_0x598b39=this;this['sequence'][_0x54a49d('0x20')](function(){const _0x3d5605=_0x54a49d;return _0x598b39[_0x3d5605('0x14')][_0x3d5605('0x0')](_0x15d970,_0x211fb8)[_0x3d5605('0x4')](function(){const _0x3fe0ea=_0x3d5605;logger[_0x3fe0ea('0xf')](_0x3fe0ea('0xa'),_0x15d970,_0x211fb8);})[_0x3d5605('0xb')](function(_0x55e6dc){const _0xc017b9=_0x3d5605;logger[_0xc017b9('0xf')](JSON[_0xc017b9('0x6')](_0x55e6dc));});});},Migration[_0xffa9e1('0x1a')][_0xffa9e1('0x12')]=function(_0xeda148){const _0x1bb487=_0xffa9e1,_0x1b5361=this;this[_0x1bb487('0x11')]['enqueue'](function(){const _0x24b491=_0x1bb487;return _0x1b5361[_0x24b491('0x14')][_0x24b491('0x8')][_0x24b491('0x12')](_0xeda148)['then'](function(){const _0x36ae92=_0x24b491;logger['info'](_0x36ae92('0x22'),_0xeda148);})[_0x24b491('0xb')](function(_0x34139f){const _0x3b7d50=_0x24b491;logger[_0x3b7d50('0xf')](JSON[_0x3b7d50('0x6')](_0x34139f));});});},Migration['prototype'][_0xffa9e1('0xe')]=function(_0x3ff5b3,_0xb63582){const _0x16a12d=_0xffa9e1,_0x27c99e=this;this['sequence'][_0x16a12d('0x20')](function(){const _0x3bcb8a=_0x16a12d;return _0x27c99e[_0x3bcb8a('0x14')][_0x3bcb8a('0xe')](_0x3ff5b3,_0xb63582)[_0x3bcb8a('0x4')](function(){const _0x462e48=_0x3bcb8a;logger[_0x462e48('0xf')]('Removed\x20column\x20%s\x20from\x20%s',_0xb63582,_0x3ff5b3);})['catch'](function(_0x5eb015){const _0x43181f=_0x3bcb8a;logger[_0x43181f('0xf')](util[_0x43181f('0x18')](_0x5eb015,{'showHidden':![],'depth':null}));});});},Migration[_0xffa9e1('0x1a')][_0xffa9e1('0x10')]=function(_0x38be20,_0x5d9415,_0x1d1851){const _0x90bc70=_0xffa9e1,_0x14d192=this;this[_0x90bc70('0x11')]['enqueue'](function(){const _0x7a8348=_0x90bc70;return _0x14d192[_0x7a8348('0x14')][_0x7a8348('0x10')](_0x38be20,_0x5d9415,_0x1d1851)[_0x7a8348('0x4')](function(){const _0x193671=_0x7a8348;logger['info'](_0x193671('0x21'),_0x5d9415,_0x1d1851,_0x38be20);})[_0x7a8348('0xb')](function(_0x4a0114){const _0x571cd0=_0x7a8348;logger[_0x571cd0('0xf')](util[_0x571cd0('0x18')](_0x4a0114,{'showHidden':![],'depth':null}));});});},Migration[_0xffa9e1('0x1a')]['final']=function(_0x4b2ea1){const _0x475659=_0xffa9e1;this[_0x475659('0x11')][_0x475659('0x20')](function(){return _0x4b2ea1();});},module[_0xffa9e1('0x17')]={'up':function(_0x15cbd3,_0x52085b){return new Promise(function(_0x2ce2fa){const _0x1d9401=a975_0x2b1f,_0x8b5834=new Migration(_0x15cbd3);_0x8b5834['query'](_0x1d9401('0x16')),_0x8b5834['query']('ALTER\x20TABLE\x20int_servicenow_accounts\x20ENCRYPTION=\x27Y\x27;'),_0x8b5834[_0x1d9401('0x9')](_0x1d9401('0x1e'),_0x1d9401('0x2'),{'type':_0x52085b[_0x1d9401('0x1f')],'defaultValue':![]}),_0x8b5834['final'](_0x2ce2fa);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.3.js b/server/migrations/2.3.3.js index ba2ab41..922ea46 100644 --- a/server/migrations/2.3.3.js +++ b/server/migrations/2.3.3.js @@ -1 +1 @@ -const a976_0x271e=['removeIndex\x20%s\x20%s','fax_applications','queryInterface','query\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','stringify','removeColumn','ALTER\x20TABLE\x20tools_canned_answers\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;','table\x20dropped\x20%s','util','enqueue','sms_applications','join','prototype','addIndex\x20%s\x20%s\x20%s','catch','TEXT','sequence','dropTable','then','appdata','finally','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex','Added\x20column\x20%s\x20to\x20%s','renameColumn','Removed\x20column\x20%s\x20from\x20%s','inspect','query','changeColumn','sequelize','info','final','tail','chat_applications','removeIndex','addColumn','openchannel_applications'];(function(_0x252ca5,_0x271e44){const _0xdd900d=function(_0x3e1ce6){while(--_0x3e1ce6){_0x252ca5['push'](_0x252ca5['shift']());}};_0xdd900d(++_0x271e44);}(a976_0x271e,0xee));const a976_0xdd90=function(_0x252ca5,_0x271e44){_0x252ca5=_0x252ca5-0x0;let _0xdd900d=a976_0x271e[_0x252ca5];return _0xdd900d;};const _0x3d6df2=a976_0xdd90;'use strict';const util=require(_0x3d6df2('0x25')),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x3e1ce6){const _0x357bbc=_0x3d6df2;this[_0x357bbc('0x17')]=this['tail']?this[_0x357bbc('0x17')][_0x357bbc('0xb')](_0x3e1ce6):_0x3e1ce6();};const Migration=function(_0x2c4176){const _0x3fd820=_0x3d6df2;this[_0x3fd820('0x1e')]=_0x2c4176,this['sequence']=new Sequence();};Migration[_0x3d6df2('0x3')][_0x3d6df2('0x13')]=function(_0x266e63,_0x230cb8,_0x1eb55d){const _0x4103be=_0x3d6df2,_0x78a867=this;this['sequence'][_0x4103be('0x0')](function(){const _0x312182=_0x4103be;return _0x78a867[_0x312182('0x1e')][_0x312182('0x13')](_0x266e63,_0x230cb8,_0x1eb55d)[_0x312182('0x9')](function(){const _0x186c0b=_0x312182;logger[_0x186c0b('0x15')](_0x186c0b('0x20'),_0x230cb8,_0x266e63);})[_0x312182('0x5')](function(_0x53efab){const _0x2101a5=_0x312182;logger[_0x2101a5('0x15')](JSON[_0x2101a5('0x21')](_0x53efab));});});},Migration[_0x3d6df2('0x3')][_0x3d6df2('0x1a')]=function(_0x1c705b,_0x3bfe50,_0x4419ea){const _0x3a69e9=_0x3d6df2,_0x1df632=this;this['sequence'][_0x3a69e9('0x0')](function(){const _0x2bc2d3=_0x3a69e9;return _0x1df632[_0x2bc2d3('0x1e')]['addColumn'](_0x1c705b,_0x3bfe50,_0x4419ea)['then'](function(){const _0x428a7a=_0x2bc2d3;logger[_0x428a7a('0x15')](_0x428a7a('0xe'),_0x3bfe50,_0x1c705b);})['catch'](function(_0x17ec2b){const _0x587084=_0x2bc2d3;logger[_0x587084('0x15')](JSON[_0x587084('0x21')](_0x17ec2b));});});},Migration[_0x3d6df2('0x3')][_0x3d6df2('0x8')]=function(_0x3ae68a){const _0x33fcb7=_0x3d6df2,_0x36257c=this;this['sequence'][_0x33fcb7('0x0')](function(){const _0xce2813=_0x33fcb7;return _0x36257c['queryInterface'][_0xce2813('0x8')](_0x3ae68a,{'force':!![]})[_0xce2813('0x9')](function(){const _0x58001e=_0xce2813;logger[_0x58001e('0x15')](_0x58001e('0x24'),_0x3ae68a);})[_0xce2813('0x5')](function(_0x402fc9){const _0x4d13d7=_0xce2813;logger[_0x4d13d7('0x15')](JSON[_0x4d13d7('0x21')](_0x402fc9));});});},Migration['prototype'][_0x3d6df2('0xd')]=function(_0x2387f1,_0x377914,_0x54c982){const _0x406ff4=_0x3d6df2,_0x3bf943=this;this[_0x406ff4('0x7')][_0x406ff4('0x0')](function(){const _0x8fa227=_0x406ff4;return _0x3bf943[_0x8fa227('0x1e')][_0x8fa227('0xd')](_0x2387f1,_0x377914,{'indexName':_0x54c982})[_0x8fa227('0x9')](function(){const _0x959b52=_0x8fa227;logger[_0x959b52('0x15')](_0x959b52('0x4'),_0x2387f1,_0x377914[_0x959b52('0x2')](','),_0x54c982);})[_0x8fa227('0x5')](function(_0x3b62ce){const _0x16375b=_0x8fa227;logger[_0x16375b('0x15')](JSON[_0x16375b('0x21')](_0x3b62ce));});});},Migration[_0x3d6df2('0x3')][_0x3d6df2('0x19')]=function(_0x47a170,_0x4cf488){const _0xc4a39=this;this['sequence']['enqueue'](function(){const _0x16496d=a976_0xdd90;return _0xc4a39[_0x16496d('0x1e')][_0x16496d('0x19')](_0x47a170,_0x4cf488)[_0x16496d('0x9')](function(){const _0x1bbd04=_0x16496d;logger[_0x1bbd04('0x15')](_0x1bbd04('0x1c'),_0x47a170,_0x4cf488);})[_0x16496d('0x5')](function(_0x13cbe3){const _0x56f2eb=_0x16496d;logger[_0x56f2eb('0x15')](JSON['stringify'](_0x13cbe3));});});},Migration[_0x3d6df2('0x3')]['query']=function(_0x16deb3){const _0x2d6120=_0x3d6df2,_0x31de1c=this;this[_0x2d6120('0x7')][_0x2d6120('0x0')](function(){const _0x1e9a50=_0x2d6120;return _0x31de1c[_0x1e9a50('0x1e')][_0x1e9a50('0x14')][_0x1e9a50('0x12')](_0x16deb3)[_0x1e9a50('0x9')](function(){const _0x10bba9=_0x1e9a50;logger[_0x10bba9('0x15')](_0x10bba9('0x1f'),_0x16deb3);})[_0x1e9a50('0x5')](function(_0x1c3aa5){const _0x401725=_0x1e9a50;logger[_0x401725('0x15')](JSON['stringify'](_0x1c3aa5));});});},Migration[_0x3d6df2('0x3')][_0x3d6df2('0x22')]=function(_0x5b2aaf,_0x28d748){const _0x2cc69f=_0x3d6df2,_0xf574d3=this;this[_0x2cc69f('0x7')][_0x2cc69f('0x0')](function(){const _0x29f8b5=_0x2cc69f;return _0xf574d3[_0x29f8b5('0x1e')][_0x29f8b5('0x22')](_0x5b2aaf,_0x28d748)[_0x29f8b5('0x9')](function(){const _0x3d75d6=_0x29f8b5;logger[_0x3d75d6('0x15')](_0x3d75d6('0x10'),_0x28d748,_0x5b2aaf);})['catch'](function(_0x528583){const _0x4979c3=_0x29f8b5;logger[_0x4979c3('0x15')](util['inspect'](_0x528583,{'showHidden':![],'depth':null}));});});},Migration[_0x3d6df2('0x3')]['renameColumn']=function(_0x22f8eb,_0x1c6506,_0x42efbf){const _0x1ab752=_0x3d6df2,_0x369bff=this;this[_0x1ab752('0x7')][_0x1ab752('0x0')](function(){const _0x5758b0=_0x1ab752;return _0x369bff[_0x5758b0('0x1e')][_0x5758b0('0xf')](_0x22f8eb,_0x1c6506,_0x42efbf)[_0x5758b0('0x9')](function(){const _0x47c9df=_0x5758b0;logger['info'](_0x47c9df('0xc'),_0x1c6506,_0x42efbf,_0x22f8eb);})[_0x5758b0('0x5')](function(_0x2e0ae9){const _0x5ba1ac=_0x5758b0;logger[_0x5ba1ac('0x15')](util[_0x5ba1ac('0x11')](_0x2e0ae9,{'showHidden':![],'depth':null}));});});},Migration[_0x3d6df2('0x3')][_0x3d6df2('0x16')]=function(_0x32d96d){const _0x3ed9c1=_0x3d6df2;this[_0x3ed9c1('0x7')][_0x3ed9c1('0x0')](function(){return _0x32d96d();});},module['exports']={'up':function(_0x3d7f52,_0x1f8492){return new Promise(function(_0xe11ac8){const _0x8f1daf=a976_0xdd90,_0x2d0943=new Migration(_0x3d7f52);_0x2d0943[_0x8f1daf('0x12')](_0x8f1daf('0x23')),_0x2d0943['changeColumn'](_0x8f1daf('0x18'),_0x8f1daf('0xa'),{'type':_0x1f8492[_0x8f1daf('0x6')]()}),_0x2d0943['changeColumn'](_0x8f1daf('0x1d'),_0x8f1daf('0xa'),{'type':_0x1f8492[_0x8f1daf('0x6')]()}),_0x2d0943[_0x8f1daf('0x13')]('mail_applications','appdata',{'type':_0x1f8492['TEXT']()}),_0x2d0943[_0x8f1daf('0x13')](_0x8f1daf('0x1b'),'appdata',{'type':_0x1f8492['TEXT']()}),_0x2d0943[_0x8f1daf('0x13')](_0x8f1daf('0x1'),_0x8f1daf('0xa'),{'type':_0x1f8492[_0x8f1daf('0x6')]()}),_0x2d0943[_0x8f1daf('0x16')](_0xe11ac8);});},'down':function(){}}; \ No newline at end of file +const a976_0x211e=['mail_applications','prototype','sms_applications','exports','join','removeIndex','ALTER\x20TABLE\x20tools_canned_answers\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci;','inspect','dropTable','finally','query','changeColumn','Removed\x20column\x20%s\x20from\x20%s','queryInterface','addColumn','query\x20%s','openchannel_applications','appdata','table\x20dropped\x20%s','removeColumn','Added\x20column\x20%s\x20to\x20%s','enqueue','addIndex','stringify','TEXT','util','renameColumn','sequence','../config/logger','info','migration','catch','final','tail','then','removeIndex\x20%s\x20%s'];(function(_0x35e1c2,_0x211ee4){const _0x2d3516=function(_0x44a10e){while(--_0x44a10e){_0x35e1c2['push'](_0x35e1c2['shift']());}};_0x2d3516(++_0x211ee4);}(a976_0x211e,0x114));const a976_0x2d35=function(_0x35e1c2,_0x211ee4){_0x35e1c2=_0x35e1c2-0x0;let _0x2d3516=a976_0x211e[_0x35e1c2];return _0x2d3516;};const _0x559914=a976_0x2d35;'use strict';const util=require(_0x559914('0x1')),logger=require(_0x559914('0x4'))(_0x559914('0x6')),Sequence=function(){};Sequence[_0x559914('0xd')]['enqueue']=function(_0x44a10e){const _0x2b91d7=_0x559914;this['tail']=this[_0x2b91d7('0x9')]?this[_0x2b91d7('0x9')][_0x2b91d7('0x15')](_0x44a10e):_0x44a10e();};const Migration=function(_0x1601ae){const _0x265f30=_0x559914;this[_0x265f30('0x19')]=_0x1601ae,this[_0x265f30('0x3')]=new Sequence();};Migration['prototype'][_0x559914('0x17')]=function(_0x4f3cb7,_0xe081b6,_0x151bbf){const _0x165207=_0x559914,_0x3007ce=this;this[_0x165207('0x3')][_0x165207('0x21')](function(){const _0x3f96dd=_0x165207;return _0x3007ce[_0x3f96dd('0x19')][_0x3f96dd('0x17')](_0x4f3cb7,_0xe081b6,_0x151bbf)[_0x3f96dd('0xa')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0xe081b6,_0x4f3cb7);})[_0x3f96dd('0x7')](function(_0xc0c035){const _0x49d61f=_0x3f96dd;logger['info'](JSON[_0x49d61f('0x23')](_0xc0c035));});});},Migration[_0x559914('0xd')][_0x559914('0x1a')]=function(_0x451d20,_0x3db072,_0x4b17ed){const _0x3516c1=_0x559914,_0x436f30=this;this[_0x3516c1('0x3')][_0x3516c1('0x21')](function(){const _0x334f8a=_0x3516c1;return _0x436f30[_0x334f8a('0x19')][_0x334f8a('0x1a')](_0x451d20,_0x3db072,_0x4b17ed)[_0x334f8a('0xa')](function(){const _0x4fa755=_0x334f8a;logger[_0x4fa755('0x5')](_0x4fa755('0x20'),_0x3db072,_0x451d20);})['catch'](function(_0x554320){const _0x3d5f6e=_0x334f8a;logger[_0x3d5f6e('0x5')](JSON[_0x3d5f6e('0x23')](_0x554320));});});},Migration['prototype'][_0x559914('0x14')]=function(_0x1c3a8e){const _0x45548e=_0x559914,_0x2af275=this;this[_0x45548e('0x3')][_0x45548e('0x21')](function(){const _0x3e9c6b=_0x45548e;return _0x2af275[_0x3e9c6b('0x19')][_0x3e9c6b('0x14')](_0x1c3a8e,{'force':!![]})[_0x3e9c6b('0xa')](function(){const _0x4c2738=_0x3e9c6b;logger[_0x4c2738('0x5')](_0x4c2738('0x1e'),_0x1c3a8e);})[_0x3e9c6b('0x7')](function(_0x48973c){const _0x4b8c70=_0x3e9c6b;logger[_0x4b8c70('0x5')](JSON[_0x4b8c70('0x23')](_0x48973c));});});},Migration['prototype'][_0x559914('0x22')]=function(_0x4935a4,_0x32f7f5,_0x39597c){const _0x10ea1e=_0x559914,_0x16839e=this;this[_0x10ea1e('0x3')][_0x10ea1e('0x21')](function(){const _0x82a48d=_0x10ea1e;return _0x16839e[_0x82a48d('0x19')]['addIndex'](_0x4935a4,_0x32f7f5,{'indexName':_0x39597c})[_0x82a48d('0xa')](function(){const _0x5464e7=_0x82a48d;logger[_0x5464e7('0x5')]('addIndex\x20%s\x20%s\x20%s',_0x4935a4,_0x32f7f5[_0x5464e7('0x10')](','),_0x39597c);})[_0x82a48d('0x7')](function(_0x133b57){const _0x96f498=_0x82a48d;logger[_0x96f498('0x5')](JSON[_0x96f498('0x23')](_0x133b57));});});},Migration[_0x559914('0xd')]['removeIndex']=function(_0x223e5b,_0x123fba){const _0x1c59ac=_0x559914,_0x285443=this;this[_0x1c59ac('0x3')][_0x1c59ac('0x21')](function(){const _0x48890d=_0x1c59ac;return _0x285443[_0x48890d('0x19')][_0x48890d('0x11')](_0x223e5b,_0x123fba)[_0x48890d('0xa')](function(){const _0x3ec93d=_0x48890d;logger[_0x3ec93d('0x5')](_0x3ec93d('0xb'),_0x223e5b,_0x123fba);})[_0x48890d('0x7')](function(_0x38ea85){const _0x4f8050=_0x48890d;logger[_0x4f8050('0x5')](JSON[_0x4f8050('0x23')](_0x38ea85));});});},Migration[_0x559914('0xd')][_0x559914('0x16')]=function(_0x53c5e4){const _0x80c877=_0x559914,_0x2b0f2c=this;this[_0x80c877('0x3')][_0x80c877('0x21')](function(){const _0x5eff31=_0x80c877;return _0x2b0f2c['queryInterface']['sequelize'][_0x5eff31('0x16')](_0x53c5e4)[_0x5eff31('0xa')](function(){const _0xa2f0bf=_0x5eff31;logger[_0xa2f0bf('0x5')](_0xa2f0bf('0x1b'),_0x53c5e4);})[_0x5eff31('0x7')](function(_0x4f724c){const _0x2c2ef3=_0x5eff31;logger[_0x2c2ef3('0x5')](JSON[_0x2c2ef3('0x23')](_0x4f724c));});});},Migration[_0x559914('0xd')][_0x559914('0x1f')]=function(_0x47a9f9,_0x4f2043){const _0x4529b2=_0x559914,_0xb94e3=this;this[_0x4529b2('0x3')][_0x4529b2('0x21')](function(){const _0x14dc23=_0x4529b2;return _0xb94e3[_0x14dc23('0x19')][_0x14dc23('0x1f')](_0x47a9f9,_0x4f2043)[_0x14dc23('0xa')](function(){const _0x4f8a6c=_0x14dc23;logger[_0x4f8a6c('0x5')](_0x4f8a6c('0x18'),_0x4f2043,_0x47a9f9);})[_0x14dc23('0x7')](function(_0x51b711){const _0x1ff58e=_0x14dc23;logger[_0x1ff58e('0x5')](util[_0x1ff58e('0x13')](_0x51b711,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x559914('0x2')]=function(_0x6fbf18,_0x526e7f,_0x60df8){const _0x2f1a8c=_0x559914,_0x2f4fb3=this;this[_0x2f1a8c('0x3')][_0x2f1a8c('0x21')](function(){const _0x538dd8=_0x2f1a8c;return _0x2f4fb3[_0x538dd8('0x19')]['renameColumn'](_0x6fbf18,_0x526e7f,_0x60df8)[_0x538dd8('0xa')](function(){const _0x5ee753=_0x538dd8;logger[_0x5ee753('0x5')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x526e7f,_0x60df8,_0x6fbf18);})[_0x538dd8('0x7')](function(_0x38cbff){const _0x12b385=_0x538dd8;logger[_0x12b385('0x5')](util[_0x12b385('0x13')](_0x38cbff,{'showHidden':![],'depth':null}));});});},Migration[_0x559914('0xd')]['final']=function(_0x25041a){const _0x5cb288=_0x559914;this[_0x5cb288('0x3')]['enqueue'](function(){return _0x25041a();});},module[_0x559914('0xf')]={'up':function(_0x56ffd2,_0x10c026){return new Promise(function(_0x567677){const _0x5ba82e=a976_0x2d35,_0x242fd4=new Migration(_0x56ffd2);_0x242fd4[_0x5ba82e('0x16')](_0x5ba82e('0x12')),_0x242fd4[_0x5ba82e('0x17')]('chat_applications',_0x5ba82e('0x1d'),{'type':_0x10c026[_0x5ba82e('0x0')]()}),_0x242fd4[_0x5ba82e('0x17')]('fax_applications',_0x5ba82e('0x1d'),{'type':_0x10c026[_0x5ba82e('0x0')]()}),_0x242fd4['changeColumn'](_0x5ba82e('0xc'),_0x5ba82e('0x1d'),{'type':_0x10c026[_0x5ba82e('0x0')]()}),_0x242fd4[_0x5ba82e('0x17')](_0x5ba82e('0x1c'),'appdata',{'type':_0x10c026[_0x5ba82e('0x0')]()}),_0x242fd4[_0x5ba82e('0x17')](_0x5ba82e('0xe'),'appdata',{'type':_0x10c026[_0x5ba82e('0x0')]()}),_0x242fd4[_0x5ba82e('0x8')](_0x567677);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.4.js b/server/migrations/2.3.4.js index 7486662..5fb8ce9 100644 --- a/server/migrations/2.3.4.js +++ b/server/migrations/2.3.4.js @@ -1 +1 @@ -const a977_0x51df=['migration','Removed\x20column\x20%s\x20from\x20%s','queryInterface','info','addIndex','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','query\x20%s','sequence','removeIndex\x20%s\x20%s','stringify','Added\x20column\x20%s\x20to\x20%s','catch','changeColumn','dropTable','removeColumn','enqueue','final','then','addIndex\x20%s\x20%s\x20%s','query','sequelize','addColumn','tail','prototype','exports','finally','join','../config/logger','inspect','renameColumn'];(function(_0x1422cb,_0x51df0f){const _0x91f98b=function(_0xd5825f){while(--_0xd5825f){_0x1422cb['push'](_0x1422cb['shift']());}};_0x91f98b(++_0x51df0f);}(a977_0x51df,0x13f));const a977_0x91f9=function(_0x1422cb,_0x51df0f){_0x1422cb=_0x1422cb-0x0;let _0x91f98b=a977_0x51df[_0x1422cb];return _0x91f98b;};const _0x46181e=a977_0x91f9;'use strict';const util=require('util'),logger=require(_0x46181e('0x8'))(_0x46181e('0xb')),Sequence=function(){};Sequence['prototype'][_0x46181e('0x1a')]=function(_0xd5825f){const _0x23d68d=_0x46181e;this[_0x23d68d('0x3')]=this[_0x23d68d('0x3')]?this[_0x23d68d('0x3')][_0x23d68d('0x6')](_0xd5825f):_0xd5825f();};const Migration=function(_0xd43127){const _0x344182=_0x46181e;this[_0x344182('0xd')]=_0xd43127,this[_0x344182('0x12')]=new Sequence();};Migration['prototype'][_0x46181e('0x17')]=function(_0x196777,_0x2ccfcf,_0x16973f){const _0x26a67c=_0x46181e,_0x8a388c=this;this['sequence'][_0x26a67c('0x1a')](function(){const _0x7bab52=_0x26a67c;return _0x8a388c[_0x7bab52('0xd')]['changeColumn'](_0x196777,_0x2ccfcf,_0x16973f)[_0x7bab52('0x1c')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x2ccfcf,_0x196777);})[_0x7bab52('0x16')](function(_0x3a739b){const _0x2696ae=_0x7bab52;logger[_0x2696ae('0xe')](JSON[_0x2696ae('0x14')](_0x3a739b));});});},Migration[_0x46181e('0x4')][_0x46181e('0x2')]=function(_0x3f5c65,_0x346627,_0x845f51){const _0x2a9ad2=_0x46181e,_0x3ff607=this;this['sequence'][_0x2a9ad2('0x1a')](function(){const _0x4773a2=_0x2a9ad2;return _0x3ff607[_0x4773a2('0xd')][_0x4773a2('0x2')](_0x3f5c65,_0x346627,_0x845f51)[_0x4773a2('0x1c')](function(){const _0x43193b=_0x4773a2;logger[_0x43193b('0xe')](_0x43193b('0x15'),_0x346627,_0x3f5c65);})['catch'](function(_0x9bf187){const _0x271e29=_0x4773a2;logger[_0x271e29('0xe')](JSON['stringify'](_0x9bf187));});});},Migration[_0x46181e('0x4')][_0x46181e('0x18')]=function(_0x306557){const _0x3abb2c=_0x46181e,_0x21d6b9=this;this[_0x3abb2c('0x12')]['enqueue'](function(){const _0x38e92a=_0x3abb2c;return _0x21d6b9[_0x38e92a('0xd')][_0x38e92a('0x18')](_0x306557,{'force':!![]})['then'](function(){logger['info']('table\x20dropped\x20%s',_0x306557);})[_0x38e92a('0x16')](function(_0x29f996){const _0x35e13a=_0x38e92a;logger[_0x35e13a('0xe')](JSON[_0x35e13a('0x14')](_0x29f996));});});},Migration[_0x46181e('0x4')]['addIndex']=function(_0x343c94,_0x247107,_0x59721a){const _0x575243=_0x46181e,_0x18a7e8=this;this[_0x575243('0x12')]['enqueue'](function(){const _0x312c95=_0x575243;return _0x18a7e8['queryInterface'][_0x312c95('0xf')](_0x343c94,_0x247107,{'indexName':_0x59721a})['then'](function(){const _0x2f3a8e=_0x312c95;logger['info'](_0x2f3a8e('0x1d'),_0x343c94,_0x247107[_0x2f3a8e('0x7')](','),_0x59721a);})[_0x312c95('0x16')](function(_0x186fbc){const _0x2f9df0=_0x312c95;logger['info'](JSON[_0x2f9df0('0x14')](_0x186fbc));});});},Migration[_0x46181e('0x4')]['removeIndex']=function(_0x25edfe,_0x1c6458){const _0x330ba7=_0x46181e,_0x342bfe=this;this[_0x330ba7('0x12')][_0x330ba7('0x1a')](function(){const _0x2a459b=_0x330ba7;return _0x342bfe['queryInterface']['removeIndex'](_0x25edfe,_0x1c6458)['then'](function(){const _0x3f68ac=a977_0x91f9;logger['info'](_0x3f68ac('0x13'),_0x25edfe,_0x1c6458);})[_0x2a459b('0x16')](function(_0x15eb37){const _0x5af25b=_0x2a459b;logger[_0x5af25b('0xe')](JSON[_0x5af25b('0x14')](_0x15eb37));});});},Migration['prototype'][_0x46181e('0x0')]=function(_0x283be0){const _0x1624e6=_0x46181e,_0x4f3fa6=this;this[_0x1624e6('0x12')][_0x1624e6('0x1a')](function(){const _0x1aace8=_0x1624e6;return _0x4f3fa6['queryInterface'][_0x1aace8('0x1')][_0x1aace8('0x0')](_0x283be0)[_0x1aace8('0x1c')](function(){const _0x4f0384=_0x1aace8;logger[_0x4f0384('0xe')](_0x4f0384('0x11'),_0x283be0);})[_0x1aace8('0x16')](function(_0x59040a){const _0x8527e7=_0x1aace8;logger[_0x8527e7('0xe')](JSON[_0x8527e7('0x14')](_0x59040a));});});},Migration[_0x46181e('0x4')][_0x46181e('0x19')]=function(_0x1124e8,_0x299070){const _0x16ff32=_0x46181e,_0x2b230e=this;this[_0x16ff32('0x12')][_0x16ff32('0x1a')](function(){const _0x482d3b=_0x16ff32;return _0x2b230e[_0x482d3b('0xd')][_0x482d3b('0x19')](_0x1124e8,_0x299070)[_0x482d3b('0x1c')](function(){const _0x38ec6e=_0x482d3b;logger[_0x38ec6e('0xe')](_0x38ec6e('0xc'),_0x299070,_0x1124e8);})[_0x482d3b('0x16')](function(_0x4b6d75){const _0x4e0791=_0x482d3b;logger[_0x4e0791('0xe')](util[_0x4e0791('0x9')](_0x4b6d75,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x46181e('0xa')]=function(_0x436fc4,_0x54a423,_0x31e576){const _0x1c2e00=_0x46181e,_0x5d8f35=this;this[_0x1c2e00('0x12')][_0x1c2e00('0x1a')](function(){const _0x46c4df=_0x1c2e00;return _0x5d8f35[_0x46c4df('0xd')][_0x46c4df('0xa')](_0x436fc4,_0x54a423,_0x31e576)[_0x46c4df('0x1c')](function(){const _0x23e0af=_0x46c4df;logger['info'](_0x23e0af('0x10'),_0x54a423,_0x31e576,_0x436fc4);})[_0x46c4df('0x16')](function(_0x2df7c6){const _0x4be33c=_0x46c4df;logger[_0x4be33c('0xe')](util['inspect'](_0x2df7c6,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x46181e('0x1b')]=function(_0x279035){const _0x5f3540=_0x46181e;this[_0x5f3540('0x12')][_0x5f3540('0x1a')](function(){return _0x279035();});},module[_0x46181e('0x5')]={'up':function(_0x5c5334){return new Promise(function(_0x4f0d19){const _0x5d57c7=new Migration(_0x5c5334);_0x5d57c7['final'](_0x4f0d19);});},'down':function(){}}; \ No newline at end of file +const a977_0x109d=['addIndex','prototype','sequelize','addColumn','query\x20%s','info','enqueue','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','table\x20dropped\x20%s','catch','migration','changeColumn','removeIndex','exports','renameColumn','inspect','final','removeIndex\x20%s\x20%s','then','join','Added\x20column\x20%s\x20to\x20%s','stringify','removeColumn','dropTable','tail','query','finally','sequence','addIndex\x20%s\x20%s\x20%s','queryInterface'];(function(_0x4b4294,_0x109daf){const _0x3839dd=function(_0x33e46f){while(--_0x33e46f){_0x4b4294['push'](_0x4b4294['shift']());}};_0x3839dd(++_0x109daf);}(a977_0x109d,0x178));const a977_0x3839=function(_0x4b4294,_0x109daf){_0x4b4294=_0x4b4294-0x0;let _0x3839dd=a977_0x109d[_0x4b4294];return _0x3839dd;};const _0x3e5852=a977_0x3839;'use strict';const util=require('util'),logger=require('../config/logger')(_0x3e5852('0x18')),Sequence=function(){};Sequence[_0x3e5852('0xf')]['enqueue']=function(_0x33e46f){const _0x1b0260=_0x3e5852;this[_0x1b0260('0x8')]=this['tail']?this[_0x1b0260('0x8')][_0x1b0260('0xa')](_0x33e46f):_0x33e46f();};const Migration=function(_0x220b51){const _0x2ef9b7=_0x3e5852;this['queryInterface']=_0x220b51,this[_0x2ef9b7('0xb')]=new Sequence();};Migration[_0x3e5852('0xf')]['changeColumn']=function(_0x175497,_0x633dd3,_0x4f1cab){const _0x2b299d=_0x3e5852,_0x32b859=this;this['sequence'][_0x2b299d('0x14')](function(){const _0x337b08=_0x2b299d;return _0x32b859[_0x337b08('0xd')][_0x337b08('0x19')](_0x175497,_0x633dd3,_0x4f1cab)['then'](function(){const _0x1b1451=_0x337b08;logger[_0x1b1451('0x13')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x633dd3,_0x175497);})['catch'](function(_0x16f095){const _0x54e488=_0x337b08;logger[_0x54e488('0x13')](JSON[_0x54e488('0x5')](_0x16f095));});});},Migration[_0x3e5852('0xf')][_0x3e5852('0x11')]=function(_0x512e5c,_0x10ed25,_0xb8dcc8){const _0x3e4c12=_0x3e5852,_0x300ab3=this;this[_0x3e4c12('0xb')][_0x3e4c12('0x14')](function(){const _0x343870=_0x3e4c12;return _0x300ab3[_0x343870('0xd')][_0x343870('0x11')](_0x512e5c,_0x10ed25,_0xb8dcc8)['then'](function(){const _0x577a34=_0x343870;logger['info'](_0x577a34('0x4'),_0x10ed25,_0x512e5c);})[_0x343870('0x17')](function(_0x4290a7){const _0x3a9bc8=_0x343870;logger[_0x3a9bc8('0x13')](JSON[_0x3a9bc8('0x5')](_0x4290a7));});});},Migration[_0x3e5852('0xf')][_0x3e5852('0x7')]=function(_0x287af8){const _0x5f1290=_0x3e5852,_0x3cd2cd=this;this[_0x5f1290('0xb')]['enqueue'](function(){const _0x3b941d=_0x5f1290;return _0x3cd2cd[_0x3b941d('0xd')][_0x3b941d('0x7')](_0x287af8,{'force':!![]})[_0x3b941d('0x2')](function(){const _0x51f4c2=_0x3b941d;logger[_0x51f4c2('0x13')](_0x51f4c2('0x16'),_0x287af8);})[_0x3b941d('0x17')](function(_0x7e68eb){const _0x58d394=_0x3b941d;logger[_0x58d394('0x13')](JSON[_0x58d394('0x5')](_0x7e68eb));});});},Migration[_0x3e5852('0xf')][_0x3e5852('0xe')]=function(_0x22050b,_0x35f802,_0x4d6103){const _0x44f508=_0x3e5852,_0x51047f=this;this[_0x44f508('0xb')]['enqueue'](function(){const _0x58fd8b=_0x44f508;return _0x51047f[_0x58fd8b('0xd')][_0x58fd8b('0xe')](_0x22050b,_0x35f802,{'indexName':_0x4d6103})[_0x58fd8b('0x2')](function(){const _0x480682=_0x58fd8b;logger[_0x480682('0x13')](_0x480682('0xc'),_0x22050b,_0x35f802[_0x480682('0x3')](','),_0x4d6103);})[_0x58fd8b('0x17')](function(_0x3eb445){logger['info'](JSON['stringify'](_0x3eb445));});});},Migration[_0x3e5852('0xf')][_0x3e5852('0x1a')]=function(_0x282758,_0x3d355c){const _0x156614=_0x3e5852,_0x1e41a3=this;this[_0x156614('0xb')][_0x156614('0x14')](function(){const _0x4406c9=_0x156614;return _0x1e41a3[_0x4406c9('0xd')][_0x4406c9('0x1a')](_0x282758,_0x3d355c)[_0x4406c9('0x2')](function(){const _0x1d7c8e=_0x4406c9;logger[_0x1d7c8e('0x13')](_0x1d7c8e('0x1'),_0x282758,_0x3d355c);})[_0x4406c9('0x17')](function(_0x213bb9){const _0x2b1a1d=_0x4406c9;logger[_0x2b1a1d('0x13')](JSON[_0x2b1a1d('0x5')](_0x213bb9));});});},Migration['prototype'][_0x3e5852('0x9')]=function(_0x43ac7b){const _0x483e0a=_0x3e5852,_0x32a3d7=this;this[_0x483e0a('0xb')]['enqueue'](function(){const _0x5cb1c7=_0x483e0a;return _0x32a3d7[_0x5cb1c7('0xd')][_0x5cb1c7('0x10')]['query'](_0x43ac7b)['then'](function(){const _0x6d6473=_0x5cb1c7;logger['info'](_0x6d6473('0x12'),_0x43ac7b);})['catch'](function(_0x568b8b){const _0x5f533d=_0x5cb1c7;logger[_0x5f533d('0x13')](JSON['stringify'](_0x568b8b));});});},Migration[_0x3e5852('0xf')][_0x3e5852('0x6')]=function(_0x437381,_0x283380){const _0x496422=_0x3e5852,_0x8ef38c=this;this['sequence'][_0x496422('0x14')](function(){const _0x5a556e=_0x496422;return _0x8ef38c[_0x5a556e('0xd')][_0x5a556e('0x6')](_0x437381,_0x283380)[_0x5a556e('0x2')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x283380,_0x437381);})[_0x5a556e('0x17')](function(_0x39cba0){const _0x441674=_0x5a556e;logger[_0x441674('0x13')](util[_0x441674('0x1d')](_0x39cba0,{'showHidden':![],'depth':null}));});});},Migration['prototype']['renameColumn']=function(_0x17002f,_0x10918e,_0x3f1f8b){const _0x4f0464=_0x3e5852,_0xe89c20=this;this[_0x4f0464('0xb')][_0x4f0464('0x14')](function(){const _0x488f49=_0x4f0464;return _0xe89c20[_0x488f49('0xd')][_0x488f49('0x1c')](_0x17002f,_0x10918e,_0x3f1f8b)[_0x488f49('0x2')](function(){const _0xc58c5e=_0x488f49;logger[_0xc58c5e('0x13')](_0xc58c5e('0x15'),_0x10918e,_0x3f1f8b,_0x17002f);})[_0x488f49('0x17')](function(_0x3e83ba){const _0x16d0f2=_0x488f49;logger[_0x16d0f2('0x13')](util[_0x16d0f2('0x1d')](_0x3e83ba,{'showHidden':![],'depth':null}));});});},Migration[_0x3e5852('0xf')][_0x3e5852('0x0')]=function(_0x3fa305){const _0xd9353a=_0x3e5852;this[_0xd9353a('0xb')]['enqueue'](function(){return _0x3fa305();});},module[_0x3e5852('0x1b')]={'up':function(_0x11b065){return new Promise(function(_0x2ba698){const _0x56ca87=new Migration(_0x11b065);_0x56ca87['final'](_0x2ba698);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.5.js b/server/migrations/2.3.5.js index 8740b09..43a8466 100644 --- a/server/migrations/2.3.5.js +++ b/server/migrations/2.3.5.js @@ -1 +1 @@ -const a978_0x3f28=['final','removeIndex\x20%s\x20%s','addIndex','prototype','tail','exports','finally','Added\x20column\x20%s\x20to\x20%s','join','then','addColumn','indicesType','enqueue','dropTable','query\x20%s','info','table\x20dropped\x20%s','indexName','stringify','inspect','migration','query','catch','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Removed\x20column\x20%s\x20from\x20%s','removeIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','queryInterface','sequence','renameColumn','changeColumn'];(function(_0x33f906,_0x3f28cd){const _0x332dba=function(_0x1ffc4d){while(--_0x1ffc4d){_0x33f906['push'](_0x33f906['shift']());}};_0x332dba(++_0x3f28cd);}(a978_0x3f28,0xa4));const a978_0x332d=function(_0x33f906,_0x3f28cd){_0x33f906=_0x33f906-0x0;let _0x332dba=a978_0x3f28[_0x33f906];return _0x332dba;};const _0x32b72e=a978_0x332d;'use strict';const util=require('util'),logger=require('../config/logger')(_0x32b72e('0xb')),Sequence=function(){};Sequence[_0x32b72e('0x19')]['enqueue']=function(_0x1ffc4d){const _0x274a11=_0x32b72e;this[_0x274a11('0x1a')]=this[_0x274a11('0x1a')]?this[_0x274a11('0x1a')][_0x274a11('0x1c')](_0x1ffc4d):_0x1ffc4d();};const Migration=function(_0x5c69c2){const _0x40433e=_0x32b72e;this[_0x40433e('0x12')]=_0x5c69c2,this['sequence']=new Sequence();};Migration[_0x32b72e('0x19')][_0x32b72e('0x15')]=function(_0x48009b,_0xb8bc1c,_0x55bdf2){const _0x39345a=_0x32b72e,_0x183c8a=this;this[_0x39345a('0x13')][_0x39345a('0x3')](function(){const _0x23f5c0=_0x39345a;return _0x183c8a[_0x23f5c0('0x12')]['changeColumn'](_0x48009b,_0xb8bc1c,_0x55bdf2)[_0x23f5c0('0x0')](function(){const _0xebb0fc=_0x23f5c0;logger[_0xebb0fc('0x6')](_0xebb0fc('0x11'),_0xb8bc1c,_0x48009b);})[_0x23f5c0('0xd')](function(_0x27c203){const _0x5e0c5d=_0x23f5c0;logger[_0x5e0c5d('0x6')](JSON[_0x5e0c5d('0x9')](_0x27c203));});});},Migration['prototype'][_0x32b72e('0x1')]=function(_0x3d56a9,_0x4d1362,_0x5cb0b1){const _0x5ce385=_0x32b72e,_0x35d2b6=this;this['sequence'][_0x5ce385('0x3')](function(){const _0x25ab75=_0x5ce385;return _0x35d2b6['queryInterface'][_0x25ab75('0x1')](_0x3d56a9,_0x4d1362,_0x5cb0b1)['then'](function(){const _0x5b106a=_0x25ab75;logger[_0x5b106a('0x6')](_0x5b106a('0x1d'),_0x4d1362,_0x3d56a9);})[_0x25ab75('0xd')](function(_0x46314f){const _0xfb56ca=_0x25ab75;logger[_0xfb56ca('0x6')](JSON[_0xfb56ca('0x9')](_0x46314f));});});},Migration[_0x32b72e('0x19')][_0x32b72e('0x4')]=function(_0x393894){const _0x3e731a=_0x32b72e,_0x248ef5=this;this[_0x3e731a('0x13')]['enqueue'](function(){const _0x3a05fc=_0x3e731a;return _0x248ef5[_0x3a05fc('0x12')][_0x3a05fc('0x4')](_0x393894,{'force':!![]})[_0x3a05fc('0x0')](function(){const _0x54143f=_0x3a05fc;logger[_0x54143f('0x6')](_0x54143f('0x7'),_0x393894);})[_0x3a05fc('0xd')](function(_0x518a68){const _0x5a70e9=_0x3a05fc;logger['info'](JSON[_0x5a70e9('0x9')](_0x518a68));});});},Migration[_0x32b72e('0x19')][_0x32b72e('0x18')]=function(_0x2c12be,_0x373e00,_0x552bcc){const _0x426d14=_0x32b72e,_0x11f620=this;this[_0x426d14('0x13')][_0x426d14('0x3')](function(){const _0x279533=_0x426d14;return _0x11f620[_0x279533('0x12')][_0x279533('0x18')](_0x2c12be,_0x373e00,{'indexName':_0x552bcc['indexName'],'indicesType':_0x552bcc['indicesType']})[_0x279533('0x0')](function(){const _0x403e57=_0x279533;logger[_0x403e57('0x6')]('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x2c12be,_0x373e00[_0x403e57('0x1e')](','),_0x552bcc[_0x403e57('0x8')],_0x552bcc[_0x403e57('0x2')]);})[_0x279533('0xd')](function(_0x29c87f){const _0x242393=_0x279533;logger[_0x242393('0x6')](JSON[_0x242393('0x9')](_0x29c87f));});});},Migration['prototype']['removeIndex']=function(_0x478ecf,_0x4eea8e){const _0xbb1e6d=_0x32b72e,_0x5f0a46=this;this[_0xbb1e6d('0x13')][_0xbb1e6d('0x3')](function(){const _0x2255ec=_0xbb1e6d;return _0x5f0a46['queryInterface'][_0x2255ec('0x10')](_0x478ecf,_0x4eea8e)[_0x2255ec('0x0')](function(){const _0x2aa56a=_0x2255ec;logger[_0x2aa56a('0x6')](_0x2aa56a('0x17'),_0x478ecf,_0x4eea8e);})[_0x2255ec('0xd')](function(_0x558c93){const _0x2d4cf4=_0x2255ec;logger[_0x2d4cf4('0x6')](JSON[_0x2d4cf4('0x9')](_0x558c93));});});},Migration['prototype'][_0x32b72e('0xc')]=function(_0x2843ad){const _0x4bcb2e=_0x32b72e,_0x524448=this;this[_0x4bcb2e('0x13')][_0x4bcb2e('0x3')](function(){const _0x2c1ad7=_0x4bcb2e;return _0x524448[_0x2c1ad7('0x12')]['sequelize'][_0x2c1ad7('0xc')](_0x2843ad)[_0x2c1ad7('0x0')](function(){const _0x183c12=_0x2c1ad7;logger[_0x183c12('0x6')](_0x183c12('0x5'),_0x2843ad);})['catch'](function(_0x3ce26e){const _0x5e7217=_0x2c1ad7;logger[_0x5e7217('0x6')](JSON['stringify'](_0x3ce26e));});});},Migration[_0x32b72e('0x19')]['removeColumn']=function(_0x4bed32,_0x2bdf90){const _0x2fd28f=_0x32b72e,_0x56b8cf=this;this[_0x2fd28f('0x13')][_0x2fd28f('0x3')](function(){const _0x380495=_0x2fd28f;return _0x56b8cf['queryInterface']['removeColumn'](_0x4bed32,_0x2bdf90)[_0x380495('0x0')](function(){const _0x8ec964=_0x380495;logger[_0x8ec964('0x6')](_0x8ec964('0xf'),_0x2bdf90,_0x4bed32);})[_0x380495('0xd')](function(_0x586db6){const _0x249503=_0x380495;logger[_0x249503('0x6')](util[_0x249503('0xa')](_0x586db6,{'showHidden':![],'depth':null}));});});},Migration[_0x32b72e('0x19')][_0x32b72e('0x14')]=function(_0x332b01,_0x4bd95b,_0x4bc5c2){const _0x1c976c=_0x32b72e,_0x387d1=this;this[_0x1c976c('0x13')][_0x1c976c('0x3')](function(){const _0x2b2400=_0x1c976c;return _0x387d1['queryInterface'][_0x2b2400('0x14')](_0x332b01,_0x4bd95b,_0x4bc5c2)[_0x2b2400('0x0')](function(){const _0x2caaa5=_0x2b2400;logger[_0x2caaa5('0x6')](_0x2caaa5('0xe'),_0x4bd95b,_0x4bc5c2,_0x332b01);})[_0x2b2400('0xd')](function(_0x280910){const _0x35e2b3=_0x2b2400;logger[_0x35e2b3('0x6')](util[_0x35e2b3('0xa')](_0x280910,{'showHidden':![],'depth':null}));});});},Migration[_0x32b72e('0x19')]['final']=function(_0x5a76de){const _0x21447a=_0x32b72e;this[_0x21447a('0x13')]['enqueue'](function(){return _0x5a76de();});},module[_0x32b72e('0x1b')]={'up':function(_0x567a9d){return new Promise(function(_0x467c59){const _0x49be09=a978_0x332d,_0x4db425=new Migration(_0x567a9d);_0x4db425[_0x49be09('0x16')](_0x467c59);});},'down':function(){}}; \ No newline at end of file +const a978_0x25d9=['catch','indicesType','dropTable','removeIndex\x20%s\x20%s','stringify','finally','Added\x20column\x20%s\x20to\x20%s','then','addIndex\x20%s\x20%s\x20%s\x20[%s]','addIndex','addColumn','prototype','inspect','tail','util','info','sequence','table\x20dropped\x20%s','indexName','renameColumn','queryInterface','changeColumn','removeColumn','../config/logger','query\x20%s','enqueue','Changed\x20column\x20%s\x20in\x20table\x20%s','sequelize','exports','query','removeIndex','final'];(function(_0xcf3d3c,_0x25d979){const _0x8e598e=function(_0x5bfb84){while(--_0x5bfb84){_0xcf3d3c['push'](_0xcf3d3c['shift']());}};_0x8e598e(++_0x25d979);}(a978_0x25d9,0x16c));const a978_0x8e59=function(_0xcf3d3c,_0x25d979){_0xcf3d3c=_0xcf3d3c-0x0;let _0x8e598e=a978_0x25d9[_0xcf3d3c];return _0x8e598e;};const _0x3c8859=a978_0x8e59;'use strict';const util=require(_0x3c8859('0x2')),logger=require(_0x3c8859('0xb'))('migration'),Sequence=function(){};Sequence[_0x3c8859('0x1f')]['enqueue']=function(_0x5bfb84){const _0x5703b4=_0x3c8859;this[_0x5703b4('0x1')]=this[_0x5703b4('0x1')]?this[_0x5703b4('0x1')][_0x5703b4('0x19')](_0x5bfb84):_0x5bfb84();};const Migration=function(_0x203971){const _0x22d74f=_0x3c8859;this[_0x22d74f('0x8')]=_0x203971,this['sequence']=new Sequence();};Migration['prototype']['changeColumn']=function(_0x33b3f0,_0xa92e34,_0x11eb4e){const _0x2fdbad=_0x3c8859,_0x3d5637=this;this[_0x2fdbad('0x4')][_0x2fdbad('0xd')](function(){const _0x50c229=_0x2fdbad;return _0x3d5637[_0x50c229('0x8')][_0x50c229('0x9')](_0x33b3f0,_0xa92e34,_0x11eb4e)[_0x50c229('0x1b')](function(){const _0x31413c=_0x50c229;logger[_0x31413c('0x3')](_0x31413c('0xe'),_0xa92e34,_0x33b3f0);})[_0x50c229('0x14')](function(_0x1001f3){const _0x2b7637=_0x50c229;logger[_0x2b7637('0x3')](JSON['stringify'](_0x1001f3));});});},Migration[_0x3c8859('0x1f')][_0x3c8859('0x1e')]=function(_0x428741,_0x2e88fb,_0x2d25d8){const _0x4d0c81=_0x3c8859,_0x2afd21=this;this[_0x4d0c81('0x4')][_0x4d0c81('0xd')](function(){const _0x1b15d5=_0x4d0c81;return _0x2afd21[_0x1b15d5('0x8')][_0x1b15d5('0x1e')](_0x428741,_0x2e88fb,_0x2d25d8)['then'](function(){const _0x3d01b9=_0x1b15d5;logger[_0x3d01b9('0x3')](_0x3d01b9('0x1a'),_0x2e88fb,_0x428741);})[_0x1b15d5('0x14')](function(_0x5625f8){const _0x465249=_0x1b15d5;logger[_0x465249('0x3')](JSON['stringify'](_0x5625f8));});});},Migration[_0x3c8859('0x1f')]['dropTable']=function(_0x5bb257){const _0x354c73=_0x3c8859,_0xd28c2e=this;this[_0x354c73('0x4')][_0x354c73('0xd')](function(){const _0x33dd72=_0x354c73;return _0xd28c2e[_0x33dd72('0x8')][_0x33dd72('0x16')](_0x5bb257,{'force':!![]})[_0x33dd72('0x1b')](function(){const _0x2875f3=_0x33dd72;logger[_0x2875f3('0x3')](_0x2875f3('0x5'),_0x5bb257);})[_0x33dd72('0x14')](function(_0x53f769){logger['info'](JSON['stringify'](_0x53f769));});});},Migration['prototype']['addIndex']=function(_0x3cedf6,_0x1da725,_0x5ca392){const _0x4d341e=_0x3c8859,_0x209987=this;this[_0x4d341e('0x4')][_0x4d341e('0xd')](function(){const _0x457140=_0x4d341e;return _0x209987[_0x457140('0x8')][_0x457140('0x1d')](_0x3cedf6,_0x1da725,{'indexName':_0x5ca392[_0x457140('0x6')],'indicesType':_0x5ca392[_0x457140('0x15')]})[_0x457140('0x1b')](function(){const _0x447862=_0x457140;logger[_0x447862('0x3')](_0x447862('0x1c'),_0x3cedf6,_0x1da725['join'](','),_0x5ca392['indexName'],_0x5ca392[_0x447862('0x15')]);})['catch'](function(_0x178075){const _0x1dad64=_0x457140;logger['info'](JSON[_0x1dad64('0x18')](_0x178075));});});},Migration[_0x3c8859('0x1f')][_0x3c8859('0x12')]=function(_0x440309,_0x2fe56c){const _0x178229=_0x3c8859,_0x512828=this;this[_0x178229('0x4')][_0x178229('0xd')](function(){const _0x4ea5e4=_0x178229;return _0x512828['queryInterface'][_0x4ea5e4('0x12')](_0x440309,_0x2fe56c)[_0x4ea5e4('0x1b')](function(){const _0x26c0ad=_0x4ea5e4;logger[_0x26c0ad('0x3')](_0x26c0ad('0x17'),_0x440309,_0x2fe56c);})['catch'](function(_0x71523a){const _0x2bc361=_0x4ea5e4;logger[_0x2bc361('0x3')](JSON[_0x2bc361('0x18')](_0x71523a));});});},Migration['prototype'][_0x3c8859('0x11')]=function(_0x3e70f5){const _0x394c76=_0x3c8859,_0x831e04=this;this[_0x394c76('0x4')][_0x394c76('0xd')](function(){const _0x1e52b3=_0x394c76;return _0x831e04[_0x1e52b3('0x8')][_0x1e52b3('0xf')]['query'](_0x3e70f5)[_0x1e52b3('0x1b')](function(){const _0x5e9fdd=_0x1e52b3;logger[_0x5e9fdd('0x3')](_0x5e9fdd('0xc'),_0x3e70f5);})['catch'](function(_0x2e5882){logger['info'](JSON['stringify'](_0x2e5882));});});},Migration[_0x3c8859('0x1f')][_0x3c8859('0xa')]=function(_0x45e703,_0x163be9){const _0x424179=_0x3c8859,_0x1b8689=this;this[_0x424179('0x4')][_0x424179('0xd')](function(){const _0x4d6dba=_0x424179;return _0x1b8689['queryInterface'][_0x4d6dba('0xa')](_0x45e703,_0x163be9)[_0x4d6dba('0x1b')](function(){const _0x2ec8ea=_0x4d6dba;logger[_0x2ec8ea('0x3')]('Removed\x20column\x20%s\x20from\x20%s',_0x163be9,_0x45e703);})['catch'](function(_0x20ba39){const _0x29e5bd=_0x4d6dba;logger[_0x29e5bd('0x3')](util[_0x29e5bd('0x0')](_0x20ba39,{'showHidden':![],'depth':null}));});});},Migration[_0x3c8859('0x1f')][_0x3c8859('0x7')]=function(_0x34b9d7,_0x49d9f6,_0x39c324){const _0x562c47=_0x3c8859,_0x2725a3=this;this[_0x562c47('0x4')][_0x562c47('0xd')](function(){const _0x3f4101=_0x562c47;return _0x2725a3['queryInterface'][_0x3f4101('0x7')](_0x34b9d7,_0x49d9f6,_0x39c324)[_0x3f4101('0x1b')](function(){const _0x373760=_0x3f4101;logger[_0x373760('0x3')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x49d9f6,_0x39c324,_0x34b9d7);})[_0x3f4101('0x14')](function(_0x200acc){const _0x41edd9=_0x3f4101;logger[_0x41edd9('0x3')](util['inspect'](_0x200acc,{'showHidden':![],'depth':null}));});});},Migration[_0x3c8859('0x1f')][_0x3c8859('0x13')]=function(_0x2c1be5){const _0x465550=_0x3c8859;this[_0x465550('0x4')]['enqueue'](function(){return _0x2c1be5();});},module[_0x3c8859('0x10')]={'up':function(_0x5a22f1){return new Promise(function(_0x41d6c2){const _0x85369c=a978_0x8e59,_0x2a1941=new Migration(_0x5a22f1);_0x2a1941[_0x85369c('0x13')](_0x41d6c2);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.6.js b/server/migrations/2.3.6.js index a639aea..20b44a8 100644 --- a/server/migrations/2.3.6.js +++ b/server/migrations/2.3.6.js @@ -1 +1 @@ -const a979_0x26d9=['dropTable','removeColumn','enqueue','query','migration','catch','sequelize','addIndex','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex\x20%s\x20%s\x20%s\x20[%s]','addColumn','info','changeColumn','renameColumn','indexName','removeIndex','indicesType','removeIndex\x20%s\x20%s','exports','inspect','Changed\x20column\x20%s\x20in\x20table\x20%s','then','join','final','queryInterface','tail','util','Added\x20column\x20%s\x20to\x20%s','prototype','stringify','sequence'];(function(_0x308698,_0x26d988){const _0x1a6c13=function(_0x3f981d){while(--_0x3f981d){_0x308698['push'](_0x308698['shift']());}};_0x1a6c13(++_0x26d988);}(a979_0x26d9,0x17b));const a979_0x1a6c=function(_0x308698,_0x26d988){_0x308698=_0x308698-0x0;let _0x1a6c13=a979_0x26d9[_0x308698];return _0x1a6c13;};const _0x2fa779=a979_0x1a6c;'use strict';const util=require(_0x2fa779('0x13')),logger=require('../config/logger')(_0x2fa779('0x1c')),Sequence=function(){};Sequence[_0x2fa779('0x15')][_0x2fa779('0x1a')]=function(_0x3f981d){const _0x54d336=_0x2fa779;this[_0x54d336('0x12')]=this['tail']?this[_0x54d336('0x12')]['finally'](_0x3f981d):_0x3f981d();};const Migration=function(_0x3fbd4a){const _0x265dab=_0x2fa779;this[_0x265dab('0x11')]=_0x3fbd4a,this[_0x265dab('0x17')]=new Sequence();};Migration['prototype'][_0x2fa779('0x5')]=function(_0x21324e,_0x35065a,_0x18e0f4){const _0x2ec0a5=_0x2fa779,_0x508034=this;this[_0x2ec0a5('0x17')]['enqueue'](function(){const _0x42bbeb=_0x2ec0a5;return _0x508034[_0x42bbeb('0x11')][_0x42bbeb('0x5')](_0x21324e,_0x35065a,_0x18e0f4)[_0x42bbeb('0xe')](function(){const _0x2162eb=_0x42bbeb;logger[_0x2162eb('0x4')](_0x2162eb('0xd'),_0x35065a,_0x21324e);})[_0x42bbeb('0x1d')](function(_0x148d4){const _0x43cc8a=_0x42bbeb;logger['info'](JSON[_0x43cc8a('0x16')](_0x148d4));});});},Migration['prototype']['addColumn']=function(_0x217121,_0x50c7bb,_0xf877b6){const _0x109c36=_0x2fa779,_0x57629c=this;this[_0x109c36('0x17')]['enqueue'](function(){const _0x28fb13=_0x109c36;return _0x57629c[_0x28fb13('0x11')][_0x28fb13('0x3')](_0x217121,_0x50c7bb,_0xf877b6)[_0x28fb13('0xe')](function(){const _0x41d1ac=_0x28fb13;logger['info'](_0x41d1ac('0x14'),_0x50c7bb,_0x217121);})[_0x28fb13('0x1d')](function(_0x2a9bd0){const _0x2f5459=_0x28fb13;logger[_0x2f5459('0x4')](JSON['stringify'](_0x2a9bd0));});});},Migration[_0x2fa779('0x15')][_0x2fa779('0x18')]=function(_0x5c928b){const _0x5efbc4=_0x2fa779,_0x456ee2=this;this[_0x5efbc4('0x17')]['enqueue'](function(){const _0x2ccd10=_0x5efbc4;return _0x456ee2[_0x2ccd10('0x11')][_0x2ccd10('0x18')](_0x5c928b,{'force':!![]})[_0x2ccd10('0xe')](function(){const _0x3ced95=_0x2ccd10;logger[_0x3ced95('0x4')]('table\x20dropped\x20%s',_0x5c928b);})[_0x2ccd10('0x1d')](function(_0x32a314){const _0xb5fe41=_0x2ccd10;logger[_0xb5fe41('0x4')](JSON[_0xb5fe41('0x16')](_0x32a314));});});},Migration[_0x2fa779('0x15')][_0x2fa779('0x0')]=function(_0x74905d,_0x1f5f98,_0x2efa4a){const _0x5247e1=_0x2fa779,_0x3b247c=this;this['sequence'][_0x5247e1('0x1a')](function(){const _0x4eebc2=_0x5247e1;return _0x3b247c[_0x4eebc2('0x11')]['addIndex'](_0x74905d,_0x1f5f98,{'indexName':_0x2efa4a[_0x4eebc2('0x7')],'indicesType':_0x2efa4a['indicesType']})[_0x4eebc2('0xe')](function(){const _0x3e21c1=_0x4eebc2;logger['info'](_0x3e21c1('0x2'),_0x74905d,_0x1f5f98[_0x3e21c1('0xf')](','),_0x2efa4a[_0x3e21c1('0x7')],_0x2efa4a[_0x3e21c1('0x9')]);})['catch'](function(_0x8d79ce){const _0x4acc66=_0x4eebc2;logger[_0x4acc66('0x4')](JSON['stringify'](_0x8d79ce));});});},Migration['prototype'][_0x2fa779('0x8')]=function(_0x4cbf20,_0x5c1f36){const _0x253703=_0x2fa779,_0xcb22b4=this;this['sequence'][_0x253703('0x1a')](function(){const _0x4426ee=_0x253703;return _0xcb22b4[_0x4426ee('0x11')][_0x4426ee('0x8')](_0x4cbf20,_0x5c1f36)[_0x4426ee('0xe')](function(){const _0xf12967=_0x4426ee;logger['info'](_0xf12967('0xa'),_0x4cbf20,_0x5c1f36);})['catch'](function(_0x1f31e8){const _0x437c9a=_0x4426ee;logger[_0x437c9a('0x4')](JSON[_0x437c9a('0x16')](_0x1f31e8));});});},Migration[_0x2fa779('0x15')]['query']=function(_0x5d1015){const _0x106cfe=_0x2fa779,_0x4bb0ec=this;this['sequence'][_0x106cfe('0x1a')](function(){const _0x181e4e=_0x106cfe;return _0x4bb0ec['queryInterface'][_0x181e4e('0x1e')][_0x181e4e('0x1b')](_0x5d1015)[_0x181e4e('0xe')](function(){const _0x44cbe8=_0x181e4e;logger[_0x44cbe8('0x4')]('query\x20%s',_0x5d1015);})[_0x181e4e('0x1d')](function(_0x480e2c){const _0x7f4b1a=_0x181e4e;logger['info'](JSON[_0x7f4b1a('0x16')](_0x480e2c));});});},Migration[_0x2fa779('0x15')][_0x2fa779('0x19')]=function(_0x375cc7,_0x31b3af){const _0x2f09a7=_0x2fa779,_0x33ea53=this;this[_0x2f09a7('0x17')][_0x2f09a7('0x1a')](function(){const _0x4a77b2=_0x2f09a7;return _0x33ea53[_0x4a77b2('0x11')][_0x4a77b2('0x19')](_0x375cc7,_0x31b3af)['then'](function(){const _0xb2492f=_0x4a77b2;logger[_0xb2492f('0x4')]('Removed\x20column\x20%s\x20from\x20%s',_0x31b3af,_0x375cc7);})[_0x4a77b2('0x1d')](function(_0x115bc5){const _0x21c9da=_0x4a77b2;logger[_0x21c9da('0x4')](util[_0x21c9da('0xc')](_0x115bc5,{'showHidden':![],'depth':null}));});});},Migration[_0x2fa779('0x15')][_0x2fa779('0x6')]=function(_0x1e3969,_0x312b48,_0x2410fb){const _0x128a6a=_0x2fa779,_0x2bed9b=this;this[_0x128a6a('0x17')][_0x128a6a('0x1a')](function(){const _0x5309e0=_0x128a6a;return _0x2bed9b['queryInterface']['renameColumn'](_0x1e3969,_0x312b48,_0x2410fb)[_0x5309e0('0xe')](function(){const _0x5d8586=_0x5309e0;logger['info'](_0x5d8586('0x1'),_0x312b48,_0x2410fb,_0x1e3969);})[_0x5309e0('0x1d')](function(_0xf9b5b3){const _0x1af562=_0x5309e0;logger[_0x1af562('0x4')](util[_0x1af562('0xc')](_0xf9b5b3,{'showHidden':![],'depth':null}));});});},Migration[_0x2fa779('0x15')][_0x2fa779('0x10')]=function(_0x206e11){const _0x28e59b=_0x2fa779;this[_0x28e59b('0x17')][_0x28e59b('0x1a')](function(){return _0x206e11();});},module[_0x2fa779('0xb')]={'up':function(_0x164e20){return new Promise(function(_0x286414){const _0x3b2fdc=a979_0x1a6c,_0x17b273=new Migration(_0x164e20);_0x17b273[_0x3b2fdc('0x10')](_0x286414);});},'down':function(){}}; \ No newline at end of file +const a979_0x2cf7=['stringify','Removed\x20column\x20%s\x20from\x20%s','indexName','inspect','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','removeIndex\x20%s\x20%s','info','removeIndex','queryInterface','changeColumn','prototype','query\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','join','indicesType','sequence','renameColumn','sequelize','enqueue','query','../config/logger','final','catch','then','addColumn','dropTable','table\x20dropped\x20%s','removeColumn','tail','Added\x20column\x20%s\x20to\x20%s','addIndex'];(function(_0x4c6265,_0x2cf749){const _0x59b65c=function(_0x5f3cdc){while(--_0x5f3cdc){_0x4c6265['push'](_0x4c6265['shift']());}};_0x59b65c(++_0x2cf749);}(a979_0x2cf7,0x1b7));const a979_0x59b6=function(_0x4c6265,_0x2cf749){_0x4c6265=_0x4c6265-0x0;let _0x59b65c=a979_0x2cf7[_0x4c6265];return _0x59b65c;};const _0x420ede=a979_0x59b6;'use strict';const util=require('util'),logger=require(_0x420ede('0xf'))('migration'),Sequence=function(){};Sequence[_0x420ede('0x5')][_0x420ede('0xd')]=function(_0x5f3cdc){const _0x4b54a2=_0x420ede;this['tail']=this[_0x4b54a2('0x17')]?this[_0x4b54a2('0x17')]['finally'](_0x5f3cdc):_0x5f3cdc();};const Migration=function(_0x2985d5){const _0x2d1871=_0x420ede;this[_0x2d1871('0x3')]=_0x2985d5,this['sequence']=new Sequence();};Migration[_0x420ede('0x5')][_0x420ede('0x4')]=function(_0x36aa0f,_0x36c5ab,_0x567a1d){const _0x46be99=_0x420ede,_0xffaa96=this;this[_0x46be99('0xa')][_0x46be99('0xd')](function(){const _0x5dd7cb=_0x46be99;return _0xffaa96[_0x5dd7cb('0x3')][_0x5dd7cb('0x4')](_0x36aa0f,_0x36c5ab,_0x567a1d)[_0x5dd7cb('0x12')](function(){const _0xec3e16=_0x5dd7cb;logger[_0xec3e16('0x1')](_0xec3e16('0x7'),_0x36c5ab,_0x36aa0f);})[_0x5dd7cb('0x11')](function(_0x345b8b){const _0x5b8117=_0x5dd7cb;logger[_0x5b8117('0x1')](JSON['stringify'](_0x345b8b));});});},Migration[_0x420ede('0x5')][_0x420ede('0x13')]=function(_0x42fddb,_0x5c2f85,_0x5dd1ec){const _0x92f78b=_0x420ede,_0x53bc9e=this;this['sequence'][_0x92f78b('0xd')](function(){const _0x4f99d9=_0x92f78b;return _0x53bc9e[_0x4f99d9('0x3')]['addColumn'](_0x42fddb,_0x5c2f85,_0x5dd1ec)[_0x4f99d9('0x12')](function(){const _0x58056c=_0x4f99d9;logger[_0x58056c('0x1')](_0x58056c('0x18'),_0x5c2f85,_0x42fddb);})['catch'](function(_0x1c1011){const _0x2020a5=_0x4f99d9;logger[_0x2020a5('0x1')](JSON[_0x2020a5('0x1a')](_0x1c1011));});});},Migration['prototype']['dropTable']=function(_0x2203dc){const _0x4c4f9a=_0x420ede,_0x3e8525=this;this[_0x4c4f9a('0xa')][_0x4c4f9a('0xd')](function(){const _0x2d41f1=_0x4c4f9a;return _0x3e8525[_0x2d41f1('0x3')][_0x2d41f1('0x14')](_0x2203dc,{'force':!![]})[_0x2d41f1('0x12')](function(){const _0x32b444=_0x2d41f1;logger['info'](_0x32b444('0x15'),_0x2203dc);})[_0x2d41f1('0x11')](function(_0x5b4507){const _0x47558a=_0x2d41f1;logger[_0x47558a('0x1')](JSON[_0x47558a('0x1a')](_0x5b4507));});});},Migration['prototype'][_0x420ede('0x19')]=function(_0x511801,_0x2ad742,_0x1dc059){const _0x474535=_0x420ede,_0x2fc46b=this;this[_0x474535('0xa')][_0x474535('0xd')](function(){const _0x267da7=_0x474535;return _0x2fc46b['queryInterface'][_0x267da7('0x19')](_0x511801,_0x2ad742,{'indexName':_0x1dc059[_0x267da7('0x1c')],'indicesType':_0x1dc059[_0x267da7('0x9')]})[_0x267da7('0x12')](function(){const _0x30dced=_0x267da7;logger['info']('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x511801,_0x2ad742[_0x30dced('0x8')](','),_0x1dc059['indexName'],_0x1dc059[_0x30dced('0x9')]);})['catch'](function(_0x5b7d5b){const _0x1458b=_0x267da7;logger[_0x1458b('0x1')](JSON[_0x1458b('0x1a')](_0x5b7d5b));});});},Migration[_0x420ede('0x5')][_0x420ede('0x2')]=function(_0x1e476d,_0x5c8df6){const _0x47bea2=_0x420ede,_0x374521=this;this[_0x47bea2('0xa')][_0x47bea2('0xd')](function(){const _0x203a1a=_0x47bea2;return _0x374521['queryInterface'][_0x203a1a('0x2')](_0x1e476d,_0x5c8df6)[_0x203a1a('0x12')](function(){const _0x2a3265=_0x203a1a;logger[_0x2a3265('0x1')](_0x2a3265('0x0'),_0x1e476d,_0x5c8df6);})[_0x203a1a('0x11')](function(_0x1999f9){const _0x430ce8=_0x203a1a;logger[_0x430ce8('0x1')](JSON['stringify'](_0x1999f9));});});},Migration['prototype'][_0x420ede('0xe')]=function(_0x2202fc){const _0x5e3a0a=this;this['sequence']['enqueue'](function(){const _0x311b76=a979_0x59b6;return _0x5e3a0a[_0x311b76('0x3')][_0x311b76('0xc')][_0x311b76('0xe')](_0x2202fc)[_0x311b76('0x12')](function(){const _0x335689=_0x311b76;logger[_0x335689('0x1')](_0x335689('0x6'),_0x2202fc);})[_0x311b76('0x11')](function(_0x3a70a0){const _0x595f5c=_0x311b76;logger[_0x595f5c('0x1')](JSON['stringify'](_0x3a70a0));});});},Migration[_0x420ede('0x5')][_0x420ede('0x16')]=function(_0x10c61f,_0x27bca1){const _0x311ae9=_0x420ede,_0x477ceb=this;this[_0x311ae9('0xa')][_0x311ae9('0xd')](function(){const _0x45d637=_0x311ae9;return _0x477ceb[_0x45d637('0x3')][_0x45d637('0x16')](_0x10c61f,_0x27bca1)['then'](function(){const _0x11eb24=_0x45d637;logger[_0x11eb24('0x1')](_0x11eb24('0x1b'),_0x27bca1,_0x10c61f);})['catch'](function(_0x17d779){const _0x1cd873=_0x45d637;logger[_0x1cd873('0x1')](util[_0x1cd873('0x1d')](_0x17d779,{'showHidden':![],'depth':null}));});});},Migration[_0x420ede('0x5')][_0x420ede('0xb')]=function(_0x24ed63,_0x42b353,_0x3f5ccb){const _0xe7fe4c=this;this['sequence']['enqueue'](function(){const _0x582462=a979_0x59b6;return _0xe7fe4c[_0x582462('0x3')]['renameColumn'](_0x24ed63,_0x42b353,_0x3f5ccb)[_0x582462('0x12')](function(){const _0x56ee52=_0x582462;logger[_0x56ee52('0x1')](_0x56ee52('0x1e'),_0x42b353,_0x3f5ccb,_0x24ed63);})[_0x582462('0x11')](function(_0x26ea17){const _0x59c1f9=_0x582462;logger[_0x59c1f9('0x1')](util[_0x59c1f9('0x1d')](_0x26ea17,{'showHidden':![],'depth':null}));});});},Migration[_0x420ede('0x5')][_0x420ede('0x10')]=function(_0x184017){const _0xcf5dc9=_0x420ede;this[_0xcf5dc9('0xa')][_0xcf5dc9('0xd')](function(){return _0x184017();});},module['exports']={'up':function(_0x537339){return new Promise(function(_0x47c0bd){const _0x1c1d93=a979_0x59b6,_0x1a87e4=new Migration(_0x537339);_0x1a87e4[_0x1c1d93('0x10')](_0x47c0bd);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.7.js b/server/migrations/2.3.7.js index bcc7e66..6b34c10 100644 --- a/server/migrations/2.3.7.js +++ b/server/migrations/2.3.7.js @@ -1 +1 @@ -const a980_0x24b8=['dropTable','sequence','info','Case','transfer','transferuniqueid','DATE','addIndex','stringify','join','transfertype','queryInterface','changeColumn','query','report_call','query\x20%s','../config/logger','sequelize','final','Removed\x20column\x20%s\x20from\x20%s','report_agent','catch','ticketType','enqueue','addIndex\x20%s\x20%s\x20%s','table\x20dropped\x20%s','then','exports','BOOLEAN','addColumn','removeIndex\x20%s\x20%s','STRING','migration','tail','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','renameColumn','Task','prototype','util','INTEGER','inspect','removeIndex','agententerreason','FORWARD,\x20BLIND,\x20ATTENDED'];(function(_0x484bcb,_0x24b899){const _0xaefb9=function(_0x57ff2f){while(--_0x57ff2f){_0x484bcb['push'](_0x484bcb['shift']());}};_0xaefb9(++_0x24b899);}(a980_0x24b8,0xc5));const a980_0xaefb=function(_0x484bcb,_0x24b899){_0x484bcb=_0x484bcb-0x0;let _0xaefb9=a980_0x24b8[_0x484bcb];return _0xaefb9;};const _0xa728b2=a980_0xaefb;'use strict';const util=require(_0xa728b2('0x11')),logger=require(_0xa728b2('0x27'))(_0xa728b2('0xb')),Sequence=function(){};Sequence[_0xa728b2('0x10')][_0xa728b2('0x2')]=function(_0x57ff2f){const _0xd97b4=_0xa728b2;this['tail']=this[_0xd97b4('0xc')]?this['tail']['finally'](_0x57ff2f):_0x57ff2f();};const Migration=function(_0x124731){const _0xd91f91=_0xa728b2;this[_0xd91f91('0x22')]=_0x124731,this[_0xd91f91('0x18')]=new Sequence();};Migration[_0xa728b2('0x10')][_0xa728b2('0x23')]=function(_0x363e03,_0x284632,_0x81ca84){const _0x5def54=_0xa728b2,_0x21aeb3=this;this[_0x5def54('0x18')][_0x5def54('0x2')](function(){const _0x368647=_0x5def54;return _0x21aeb3[_0x368647('0x22')][_0x368647('0x23')](_0x363e03,_0x284632,_0x81ca84)[_0x368647('0x5')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x284632,_0x363e03);})[_0x368647('0x0')](function(_0x4ce5d7){const _0x142b36=_0x368647;logger[_0x142b36('0x19')](JSON[_0x142b36('0x1f')](_0x4ce5d7));});});},Migration[_0xa728b2('0x10')][_0xa728b2('0x8')]=function(_0x3a2300,_0x5c5538,_0x51baf6){const _0x349091=_0xa728b2,_0x30f900=this;this['sequence'][_0x349091('0x2')](function(){const _0x24239e=_0x349091;return _0x30f900['queryInterface'][_0x24239e('0x8')](_0x3a2300,_0x5c5538,_0x51baf6)[_0x24239e('0x5')](function(){const _0x50ce06=_0x24239e;logger[_0x50ce06('0x19')]('Added\x20column\x20%s\x20to\x20%s',_0x5c5538,_0x3a2300);})[_0x24239e('0x0')](function(_0x3f991d){const _0x3712c4=_0x24239e;logger[_0x3712c4('0x19')](JSON['stringify'](_0x3f991d));});});},Migration[_0xa728b2('0x10')]['dropTable']=function(_0x47771a){const _0x33a2fa=_0xa728b2,_0x47584f=this;this[_0x33a2fa('0x18')][_0x33a2fa('0x2')](function(){const _0x4751f8=_0x33a2fa;return _0x47584f[_0x4751f8('0x22')][_0x4751f8('0x17')](_0x47771a,{'force':!![]})[_0x4751f8('0x5')](function(){const _0x46d30e=_0x4751f8;logger[_0x46d30e('0x19')](_0x46d30e('0x4'),_0x47771a);})[_0x4751f8('0x0')](function(_0x4342d1){const _0x5985d4=_0x4751f8;logger[_0x5985d4('0x19')](JSON[_0x5985d4('0x1f')](_0x4342d1));});});},Migration[_0xa728b2('0x10')]['addIndex']=function(_0x799b15,_0x1fb9d7,_0x1e823c){const _0x2e9cfd=_0xa728b2,_0x494d7a=this;this['sequence'][_0x2e9cfd('0x2')](function(){const _0x105011=_0x2e9cfd;return _0x494d7a['queryInterface'][_0x105011('0x1e')](_0x799b15,_0x1fb9d7,{'indexName':_0x1e823c})['then'](function(){const _0x2f13ac=_0x105011;logger[_0x2f13ac('0x19')](_0x2f13ac('0x3'),_0x799b15,_0x1fb9d7[_0x2f13ac('0x20')](','),_0x1e823c);})[_0x105011('0x0')](function(_0x2d620c){const _0x1d992d=_0x105011;logger[_0x1d992d('0x19')](JSON['stringify'](_0x2d620c));});});},Migration['prototype'][_0xa728b2('0x14')]=function(_0x52457c,_0x586aba){const _0x41b96c=_0xa728b2,_0x2ff22c=this;this[_0x41b96c('0x18')][_0x41b96c('0x2')](function(){const _0x2834f9=_0x41b96c;return _0x2ff22c[_0x2834f9('0x22')]['removeIndex'](_0x52457c,_0x586aba)['then'](function(){const _0x271019=_0x2834f9;logger[_0x271019('0x19')](_0x271019('0x9'),_0x52457c,_0x586aba);})[_0x2834f9('0x0')](function(_0x855a5d){const _0x3a173e=_0x2834f9;logger[_0x3a173e('0x19')](JSON[_0x3a173e('0x1f')](_0x855a5d));});});},Migration['prototype']['query']=function(_0x38b1ea){const _0x2b9c33=_0xa728b2,_0x568bcc=this;this[_0x2b9c33('0x18')][_0x2b9c33('0x2')](function(){const _0x29df4c=_0x2b9c33;return _0x568bcc[_0x29df4c('0x22')][_0x29df4c('0x28')][_0x29df4c('0x24')](_0x38b1ea)[_0x29df4c('0x5')](function(){const _0x5ccb5e=_0x29df4c;logger['info'](_0x5ccb5e('0x26'),_0x38b1ea);})[_0x29df4c('0x0')](function(_0x4172c7){const _0x3b51c2=_0x29df4c;logger[_0x3b51c2('0x19')](JSON['stringify'](_0x4172c7));});});},Migration[_0xa728b2('0x10')]['removeColumn']=function(_0x16bbcd,_0x5186ea){const _0x448c7b=_0xa728b2,_0x1e29b7=this;this[_0x448c7b('0x18')][_0x448c7b('0x2')](function(){const _0x9948e3=_0x448c7b;return _0x1e29b7[_0x9948e3('0x22')]['removeColumn'](_0x16bbcd,_0x5186ea)[_0x9948e3('0x5')](function(){const _0xd85cbc=_0x9948e3;logger[_0xd85cbc('0x19')](_0xd85cbc('0x2a'),_0x5186ea,_0x16bbcd);})[_0x9948e3('0x0')](function(_0x18cbc9){const _0x3c6ffc=_0x9948e3;logger[_0x3c6ffc('0x19')](util[_0x3c6ffc('0x13')](_0x18cbc9,{'showHidden':![],'depth':null}));});});},Migration[_0xa728b2('0x10')][_0xa728b2('0xe')]=function(_0x58a458,_0x2d6cb5,_0x1940d8){const _0x3a79cf=_0xa728b2,_0x4a46f2=this;this[_0x3a79cf('0x18')][_0x3a79cf('0x2')](function(){const _0x4c74b1=_0x3a79cf;return _0x4a46f2[_0x4c74b1('0x22')][_0x4c74b1('0xe')](_0x58a458,_0x2d6cb5,_0x1940d8)[_0x4c74b1('0x5')](function(){const _0x6e494d=_0x4c74b1;logger['info'](_0x6e494d('0xd'),_0x2d6cb5,_0x1940d8,_0x58a458);})[_0x4c74b1('0x0')](function(_0x1c29b7){const _0x3c8f36=_0x4c74b1;logger[_0x3c8f36('0x19')](util[_0x3c8f36('0x13')](_0x1c29b7,{'showHidden':![],'depth':null}));});});},Migration[_0xa728b2('0x10')][_0xa728b2('0x29')]=function(_0x28189b){const _0x5b5239=_0xa728b2;this[_0x5b5239('0x18')]['enqueue'](function(){return _0x28189b();});},module[_0xa728b2('0x6')]={'up':function(_0x434e87,_0xfcf5ff){return new Promise(function(_0xf1dd75){const _0x48737f=a980_0xaefb,_0x2d7eca=new Migration(_0x434e87);_0x2d7eca['addColumn'](_0x48737f('0x2b'),_0x48737f('0x1b'),{'type':_0xfcf5ff[_0x48737f('0x7')],'defaultValue':![]}),_0x2d7eca[_0x48737f('0x8')]('report_agent',_0x48737f('0x21'),{'type':_0xfcf5ff[_0x48737f('0xa')],'comment':_0x48737f('0x16')}),_0x2d7eca[_0x48737f('0x8')](_0x48737f('0x2b'),'transferexten',{'type':_0xfcf5ff[_0x48737f('0xa')]}),_0x2d7eca['addColumn'](_0x48737f('0x2b'),_0x48737f('0x1c'),{'type':_0xfcf5ff[_0x48737f('0xa')]}),_0x2d7eca[_0x48737f('0x8')](_0x48737f('0x2b'),_0x48737f('0x15'),{'type':_0xfcf5ff[_0x48737f('0x12')],'defaultValue':0x0}),_0x2d7eca[_0x48737f('0x8')](_0x48737f('0x25'),'systemanswertime',{'type':_0xfcf5ff[_0x48737f('0x1d')]}),_0x2d7eca[_0x48737f('0x8')]('int_salesforce_configurations',_0x48737f('0x1'),{'type':_0xfcf5ff['ENUM']('Task',_0x48737f('0x1a')),'defaultValue':_0x48737f('0xf')}),_0x2d7eca['final'](_0xf1dd75);});},'down':function(){}}; \ No newline at end of file +const a980_0x5a24=['queryInterface','catch','Changed\x20column\x20%s\x20in\x20table\x20%s','addColumn','info','then','Added\x20column\x20%s\x20to\x20%s','removeIndex\x20%s\x20%s','ticketType','INTEGER','table\x20dropped\x20%s','exports','enqueue','addIndex\x20%s\x20%s\x20%s','sequence','prototype','query\x20%s','report_agent','finally','transferuniqueid','stringify','migration','Removed\x20column\x20%s\x20from\x20%s','agententerreason','Task','query','dropTable','renameColumn','STRING','removeIndex','changeColumn','final','transferexten','inspect','addIndex','DATE','report_call','transfer','util'];(function(_0x1dc13b,_0x5a2418){const _0x314140=function(_0x48e210){while(--_0x48e210){_0x1dc13b['push'](_0x1dc13b['shift']());}};_0x314140(++_0x5a2418);}(a980_0x5a24,0xac));const a980_0x3141=function(_0x1dc13b,_0x5a2418){_0x1dc13b=_0x1dc13b-0x0;let _0x314140=a980_0x5a24[_0x1dc13b];return _0x314140;};const _0x400ca9=a980_0x3141;'use strict';const util=require(_0x400ca9('0x16')),logger=require('../config/logger')(_0x400ca9('0x5')),Sequence=function(){};Sequence[_0x400ca9('0x26')][_0x400ca9('0x23')]=function(_0x48e210){const _0xc6ea99=_0x400ca9;this['tail']=this['tail']?this['tail'][_0xc6ea99('0x2')](_0x48e210):_0x48e210();};const Migration=function(_0x360fe2){this['queryInterface']=_0x360fe2,this['sequence']=new Sequence();};Migration[_0x400ca9('0x26')][_0x400ca9('0xe')]=function(_0xeeaa40,_0x1cff78,_0x1dc994){const _0x4a08dd=_0x400ca9,_0x12fff7=this;this[_0x4a08dd('0x25')][_0x4a08dd('0x23')](function(){const _0x1b4794=_0x4a08dd;return _0x12fff7[_0x1b4794('0x17')][_0x1b4794('0xe')](_0xeeaa40,_0x1cff78,_0x1dc994)[_0x1b4794('0x1c')](function(){const _0xf5cabc=_0x1b4794;logger[_0xf5cabc('0x1b')](_0xf5cabc('0x19'),_0x1cff78,_0xeeaa40);})['catch'](function(_0x224f4a){const _0x5e2411=_0x1b4794;logger[_0x5e2411('0x1b')](JSON[_0x5e2411('0x4')](_0x224f4a));});});},Migration[_0x400ca9('0x26')]['addColumn']=function(_0x250120,_0x81a7cc,_0x551806){const _0x3ce3c0=_0x400ca9,_0xee5416=this;this[_0x3ce3c0('0x25')][_0x3ce3c0('0x23')](function(){const _0x4338fb=_0x3ce3c0;return _0xee5416[_0x4338fb('0x17')][_0x4338fb('0x1a')](_0x250120,_0x81a7cc,_0x551806)[_0x4338fb('0x1c')](function(){const _0x407339=_0x4338fb;logger['info'](_0x407339('0x1d'),_0x81a7cc,_0x250120);})[_0x4338fb('0x18')](function(_0x3b0379){const _0x1098e6=_0x4338fb;logger[_0x1098e6('0x1b')](JSON['stringify'](_0x3b0379));});});},Migration['prototype'][_0x400ca9('0xa')]=function(_0x5e0874){const _0x531793=_0x400ca9,_0x3ce277=this;this[_0x531793('0x25')][_0x531793('0x23')](function(){const _0x1abbba=_0x531793;return _0x3ce277[_0x1abbba('0x17')][_0x1abbba('0xa')](_0x5e0874,{'force':!![]})[_0x1abbba('0x1c')](function(){const _0x58c313=_0x1abbba;logger['info'](_0x58c313('0x21'),_0x5e0874);})[_0x1abbba('0x18')](function(_0x11a0df){const _0x385cab=_0x1abbba;logger[_0x385cab('0x1b')](JSON[_0x385cab('0x4')](_0x11a0df));});});},Migration['prototype'][_0x400ca9('0x12')]=function(_0x59f480,_0x565d16,_0x236129){const _0x2197eb=_0x400ca9,_0x55f216=this;this[_0x2197eb('0x25')][_0x2197eb('0x23')](function(){const _0x5612b4=_0x2197eb;return _0x55f216[_0x5612b4('0x17')][_0x5612b4('0x12')](_0x59f480,_0x565d16,{'indexName':_0x236129})[_0x5612b4('0x1c')](function(){const _0x10bf1c=_0x5612b4;logger['info'](_0x10bf1c('0x24'),_0x59f480,_0x565d16['join'](','),_0x236129);})[_0x5612b4('0x18')](function(_0x2ee5d8){const _0x127c33=_0x5612b4;logger[_0x127c33('0x1b')](JSON[_0x127c33('0x4')](_0x2ee5d8));});});},Migration[_0x400ca9('0x26')][_0x400ca9('0xd')]=function(_0x1362c0,_0x2a8a98){const _0x2fdda9=_0x400ca9,_0x3f4db4=this;this[_0x2fdda9('0x25')]['enqueue'](function(){const _0x13a1ed=_0x2fdda9;return _0x3f4db4[_0x13a1ed('0x17')][_0x13a1ed('0xd')](_0x1362c0,_0x2a8a98)['then'](function(){const _0x209aa9=_0x13a1ed;logger[_0x209aa9('0x1b')](_0x209aa9('0x1e'),_0x1362c0,_0x2a8a98);})[_0x13a1ed('0x18')](function(_0x3b481e){const _0x3e4760=_0x13a1ed;logger[_0x3e4760('0x1b')](JSON['stringify'](_0x3b481e));});});},Migration[_0x400ca9('0x26')][_0x400ca9('0x9')]=function(_0xcf4029){const _0x14d660=_0x400ca9,_0x53cc4a=this;this[_0x14d660('0x25')][_0x14d660('0x23')](function(){const _0x280edc=_0x14d660;return _0x53cc4a[_0x280edc('0x17')]['sequelize'][_0x280edc('0x9')](_0xcf4029)[_0x280edc('0x1c')](function(){const _0x30b2df=_0x280edc;logger[_0x30b2df('0x1b')](_0x30b2df('0x0'),_0xcf4029);})[_0x280edc('0x18')](function(_0x4862a2){const _0x18220b=_0x280edc;logger[_0x18220b('0x1b')](JSON[_0x18220b('0x4')](_0x4862a2));});});},Migration[_0x400ca9('0x26')]['removeColumn']=function(_0x1aecf6,_0xb65496){const _0xaf288b=_0x400ca9,_0x13f114=this;this['sequence'][_0xaf288b('0x23')](function(){const _0x5a256b=_0xaf288b;return _0x13f114[_0x5a256b('0x17')]['removeColumn'](_0x1aecf6,_0xb65496)['then'](function(){const _0x46a7ab=_0x5a256b;logger[_0x46a7ab('0x1b')](_0x46a7ab('0x6'),_0xb65496,_0x1aecf6);})[_0x5a256b('0x18')](function(_0xc9107a){const _0x396d0a=_0x5a256b;logger['info'](util[_0x396d0a('0x11')](_0xc9107a,{'showHidden':![],'depth':null}));});});},Migration[_0x400ca9('0x26')][_0x400ca9('0xb')]=function(_0x54f5c6,_0x2b5a4d,_0x45120e){const _0x4ecb03=_0x400ca9,_0x4747a1=this;this[_0x4ecb03('0x25')][_0x4ecb03('0x23')](function(){const _0x55f4cb=_0x4ecb03;return _0x4747a1['queryInterface'][_0x55f4cb('0xb')](_0x54f5c6,_0x2b5a4d,_0x45120e)[_0x55f4cb('0x1c')](function(){const _0x5871ad=_0x55f4cb;logger[_0x5871ad('0x1b')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x2b5a4d,_0x45120e,_0x54f5c6);})[_0x55f4cb('0x18')](function(_0x416f0a){logger['info'](util['inspect'](_0x416f0a,{'showHidden':![],'depth':null}));});});},Migration[_0x400ca9('0x26')][_0x400ca9('0xf')]=function(_0x1e7a19){const _0x5b7c65=_0x400ca9;this[_0x5b7c65('0x25')]['enqueue'](function(){return _0x1e7a19();});},module[_0x400ca9('0x22')]={'up':function(_0x323ebd,_0x57d45b){return new Promise(function(_0x2ba5dc){const _0x32294f=a980_0x3141,_0x20da8d=new Migration(_0x323ebd);_0x20da8d['addColumn'](_0x32294f('0x1'),_0x32294f('0x15'),{'type':_0x57d45b['BOOLEAN'],'defaultValue':![]}),_0x20da8d['addColumn'](_0x32294f('0x1'),'transfertype',{'type':_0x57d45b[_0x32294f('0xc')],'comment':'FORWARD,\x20BLIND,\x20ATTENDED'}),_0x20da8d[_0x32294f('0x1a')]('report_agent',_0x32294f('0x10'),{'type':_0x57d45b[_0x32294f('0xc')]}),_0x20da8d['addColumn'](_0x32294f('0x1'),_0x32294f('0x3'),{'type':_0x57d45b[_0x32294f('0xc')]}),_0x20da8d[_0x32294f('0x1a')](_0x32294f('0x1'),_0x32294f('0x7'),{'type':_0x57d45b[_0x32294f('0x20')],'defaultValue':0x0}),_0x20da8d['addColumn'](_0x32294f('0x14'),'systemanswertime',{'type':_0x57d45b[_0x32294f('0x13')]}),_0x20da8d[_0x32294f('0x1a')]('int_salesforce_configurations',_0x32294f('0x1f'),{'type':_0x57d45b['ENUM'](_0x32294f('0x8'),'Case'),'defaultValue':_0x32294f('0x8')}),_0x20da8d[_0x32294f('0xf')](_0x2ba5dc);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.8.js b/server/migrations/2.3.8.js index c034d7e..f127a27 100644 --- a/server/migrations/2.3.8.js +++ b/server/migrations/2.3.8.js @@ -1 +1 @@ -const a981_0x3238=['query','addIndex','prototype','info','Added\x20column\x20%s\x20to\x20%s','addIndex\x20%s\x20%s\x20%s','changeColumn','sequence','enqueue','addColumn','util','exports','stringify','queryInterface','tail','inspect','final','removeColumn','table\x20dropped\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','then','catch','dropTable','removeIndex','renameColumn','../config/logger'];(function(_0x54c273,_0x323827){const _0x3bad33=function(_0x21c28c){while(--_0x21c28c){_0x54c273['push'](_0x54c273['shift']());}};_0x3bad33(++_0x323827);}(a981_0x3238,0x91));const a981_0x3bad=function(_0x54c273,_0x323827){_0x54c273=_0x54c273-0x0;let _0x3bad33=a981_0x3238[_0x54c273];return _0x3bad33;};const _0x353fc4=a981_0x3bad;'use strict';const util=require(_0x353fc4('0x15')),logger=require(_0x353fc4('0xa'))('migration'),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x21c28c){const _0x3fa4f1=_0x353fc4;this[_0x3fa4f1('0x19')]=this[_0x3fa4f1('0x19')]?this[_0x3fa4f1('0x19')]['finally'](_0x21c28c):_0x21c28c();};const Migration=function(_0x30b3e9){const _0x5551e2=_0x353fc4;this[_0x5551e2('0x18')]=_0x30b3e9,this[_0x5551e2('0x12')]=new Sequence();};Migration['prototype'][_0x353fc4('0x11')]=function(_0x5a68f3,_0x4f2d00,_0x44cb3c){const _0x45b8a2=_0x353fc4,_0x8e14ec=this;this[_0x45b8a2('0x12')][_0x45b8a2('0x13')](function(){const _0x9e9b21=_0x45b8a2;return _0x8e14ec[_0x9e9b21('0x18')]['changeColumn'](_0x5a68f3,_0x4f2d00,_0x44cb3c)[_0x9e9b21('0x5')](function(){const _0xbf507a=_0x9e9b21;logger[_0xbf507a('0xe')](_0xbf507a('0x4'),_0x4f2d00,_0x5a68f3);})['catch'](function(_0x5961ac){const _0x25d4e8=_0x9e9b21;logger[_0x25d4e8('0xe')](JSON[_0x25d4e8('0x17')](_0x5961ac));});});},Migration[_0x353fc4('0xd')][_0x353fc4('0x14')]=function(_0x1a8be8,_0x16937d,_0x2e024b){const _0x281d3a=_0x353fc4,_0x553f3d=this;this[_0x281d3a('0x12')]['enqueue'](function(){const _0x400f1f=_0x281d3a;return _0x553f3d[_0x400f1f('0x18')][_0x400f1f('0x14')](_0x1a8be8,_0x16937d,_0x2e024b)['then'](function(){const _0x2ee351=_0x400f1f;logger['info'](_0x2ee351('0xf'),_0x16937d,_0x1a8be8);})[_0x400f1f('0x6')](function(_0x3dfdd0){const _0x696e9=_0x400f1f;logger['info'](JSON[_0x696e9('0x17')](_0x3dfdd0));});});},Migration[_0x353fc4('0xd')][_0x353fc4('0x7')]=function(_0x4ded99){const _0x45c1c2=_0x353fc4,_0x24507b=this;this['sequence'][_0x45c1c2('0x13')](function(){const _0x438273=_0x45c1c2;return _0x24507b[_0x438273('0x18')][_0x438273('0x7')](_0x4ded99,{'force':!![]})[_0x438273('0x5')](function(){const _0x39b829=_0x438273;logger['info'](_0x39b829('0x3'),_0x4ded99);})[_0x438273('0x6')](function(_0x2258bd){const _0x3e338b=_0x438273;logger[_0x3e338b('0xe')](JSON['stringify'](_0x2258bd));});});},Migration[_0x353fc4('0xd')][_0x353fc4('0xc')]=function(_0x1e3dfc,_0x1ff786,_0x3f20a0){const _0x2dcbce=_0x353fc4,_0xb8d001=this;this[_0x2dcbce('0x12')][_0x2dcbce('0x13')](function(){const _0x2cc78c=_0x2dcbce;return _0xb8d001[_0x2cc78c('0x18')][_0x2cc78c('0xc')](_0x1e3dfc,_0x1ff786,{'indexName':_0x3f20a0})['then'](function(){const _0x48fdce=_0x2cc78c;logger[_0x48fdce('0xe')](_0x48fdce('0x10'),_0x1e3dfc,_0x1ff786['join'](','),_0x3f20a0);})['catch'](function(_0x18dbf6){const _0x6d589d=_0x2cc78c;logger[_0x6d589d('0xe')](JSON['stringify'](_0x18dbf6));});});},Migration['prototype'][_0x353fc4('0x8')]=function(_0x25cacf,_0x160c5b){const _0x54faa9=_0x353fc4,_0x1e3f28=this;this[_0x54faa9('0x12')][_0x54faa9('0x13')](function(){const _0x7ce4d8=_0x54faa9;return _0x1e3f28['queryInterface'][_0x7ce4d8('0x8')](_0x25cacf,_0x160c5b)[_0x7ce4d8('0x5')](function(){const _0x5bf787=_0x7ce4d8;logger[_0x5bf787('0xe')]('removeIndex\x20%s\x20%s',_0x25cacf,_0x160c5b);})[_0x7ce4d8('0x6')](function(_0xf31b1e){const _0x4986d2=_0x7ce4d8;logger[_0x4986d2('0xe')](JSON[_0x4986d2('0x17')](_0xf31b1e));});});},Migration[_0x353fc4('0xd')][_0x353fc4('0xb')]=function(_0x431d4f){const _0x4c0ba6=_0x353fc4,_0x4e2c00=this;this[_0x4c0ba6('0x12')][_0x4c0ba6('0x13')](function(){const _0x33900b=_0x4c0ba6;return _0x4e2c00['queryInterface']['sequelize'][_0x33900b('0xb')](_0x431d4f)[_0x33900b('0x5')](function(){const _0x5f3ae8=_0x33900b;logger[_0x5f3ae8('0xe')]('query\x20%s',_0x431d4f);})[_0x33900b('0x6')](function(_0x777dd2){const _0x3922e6=_0x33900b;logger[_0x3922e6('0xe')](JSON[_0x3922e6('0x17')](_0x777dd2));});});},Migration[_0x353fc4('0xd')][_0x353fc4('0x2')]=function(_0x1c793b,_0x5d150a){const _0x58a57=_0x353fc4,_0x23a740=this;this[_0x58a57('0x12')]['enqueue'](function(){const _0xa7ef7f=_0x58a57;return _0x23a740['queryInterface'][_0xa7ef7f('0x2')](_0x1c793b,_0x5d150a)[_0xa7ef7f('0x5')](function(){const _0x4a6ada=_0xa7ef7f;logger[_0x4a6ada('0xe')]('Removed\x20column\x20%s\x20from\x20%s',_0x5d150a,_0x1c793b);})['catch'](function(_0x2ad6f2){const _0x37d41=_0xa7ef7f;logger[_0x37d41('0xe')](util[_0x37d41('0x0')](_0x2ad6f2,{'showHidden':![],'depth':null}));});});},Migration[_0x353fc4('0xd')]['renameColumn']=function(_0x4ac6f0,_0x95e165,_0x140d79){const _0x11b460=_0x353fc4,_0x1bb101=this;this[_0x11b460('0x12')]['enqueue'](function(){const _0x11201b=_0x11b460;return _0x1bb101[_0x11201b('0x18')][_0x11201b('0x9')](_0x4ac6f0,_0x95e165,_0x140d79)[_0x11201b('0x5')](function(){const _0x1fe369=_0x11201b;logger[_0x1fe369('0xe')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x95e165,_0x140d79,_0x4ac6f0);})[_0x11201b('0x6')](function(_0x2a2035){const _0x509259=_0x11201b;logger['info'](util[_0x509259('0x0')](_0x2a2035,{'showHidden':![],'depth':null}));});});},Migration[_0x353fc4('0xd')]['final']=function(_0x20ede6){const _0x212eb0=_0x353fc4;this['sequence'][_0x212eb0('0x13')](function(){return _0x20ede6();});},module[_0x353fc4('0x16')]={'up':function(_0x42c4dc){return new Promise(function(_0x27aa81){const _0x2fd994=a981_0x3bad,_0x2ceced=new Migration(_0x42c4dc);_0x2ceced[_0x2fd994('0x1')](_0x27aa81);});},'down':function(){}}; \ No newline at end of file +const a981_0x30dc=['then','removeIndex\x20%s\x20%s','removeColumn','stringify','changeColumn','info','addColumn','dropTable','removeIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','prototype','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','query\x20%s','join','migration','renameColumn','queryInterface','table\x20dropped\x20%s','exports','Removed\x20column\x20%s\x20from\x20%s','sequence','query','sequelize','tail','enqueue','addIndex','final','catch','util','inspect','finally'];(function(_0xdde39b,_0x30dcb6){const _0x3cdbde=function(_0x34350d){while(--_0x34350d){_0xdde39b['push'](_0xdde39b['shift']());}};_0x3cdbde(++_0x30dcb6);}(a981_0x30dc,0x187));const a981_0x3cdb=function(_0xdde39b,_0x30dcb6){_0xdde39b=_0xdde39b-0x0;let _0x3cdbde=a981_0x30dc[_0xdde39b];return _0x3cdbde;};const _0x50f12d=a981_0x3cdb;'use strict';const util=require(_0x50f12d('0x9')),logger=require('../config/logger')(_0x50f12d('0x1a')),Sequence=function(){};Sequence[_0x50f12d('0x16')][_0x50f12d('0x5')]=function(_0x34350d){const _0x576ac2=_0x50f12d;this[_0x576ac2('0x4')]=this['tail']?this[_0x576ac2('0x4')][_0x576ac2('0xb')](_0x34350d):_0x34350d();};const Migration=function(_0x4373da){const _0x5e1bc3=_0x50f12d;this[_0x5e1bc3('0x1c')]=_0x4373da,this[_0x5e1bc3('0x1')]=new Sequence();};Migration[_0x50f12d('0x16')]['changeColumn']=function(_0x45dcd2,_0x3eb203,_0x1d9411){const _0x44b8fc=_0x50f12d,_0x2e361a=this;this['sequence'][_0x44b8fc('0x5')](function(){const _0xadb302=_0x44b8fc;return _0x2e361a[_0xadb302('0x1c')][_0xadb302('0x10')](_0x45dcd2,_0x3eb203,_0x1d9411)[_0xadb302('0xc')](function(){const _0x180e4e=_0xadb302;logger[_0x180e4e('0x11')](_0x180e4e('0x15'),_0x3eb203,_0x45dcd2);})[_0xadb302('0x8')](function(_0x3e042a){logger['info'](JSON['stringify'](_0x3e042a));});});},Migration[_0x50f12d('0x16')]['addColumn']=function(_0xf6e310,_0x3869a1,_0x4b5524){const _0x7e7306=_0x50f12d,_0x52ab57=this;this[_0x7e7306('0x1')][_0x7e7306('0x5')](function(){const _0x30f1b8=_0x7e7306;return _0x52ab57[_0x30f1b8('0x1c')][_0x30f1b8('0x12')](_0xf6e310,_0x3869a1,_0x4b5524)[_0x30f1b8('0xc')](function(){const _0xeb9cff=_0x30f1b8;logger[_0xeb9cff('0x11')]('Added\x20column\x20%s\x20to\x20%s',_0x3869a1,_0xf6e310);})['catch'](function(_0x1c8723){const _0x20a474=_0x30f1b8;logger[_0x20a474('0x11')](JSON[_0x20a474('0xf')](_0x1c8723));});});},Migration[_0x50f12d('0x16')]['dropTable']=function(_0x325518){const _0x3e8897=_0x50f12d,_0x5a0dac=this;this[_0x3e8897('0x1')][_0x3e8897('0x5')](function(){const _0x69e8e8=_0x3e8897;return _0x5a0dac[_0x69e8e8('0x1c')][_0x69e8e8('0x13')](_0x325518,{'force':!![]})[_0x69e8e8('0xc')](function(){const _0x5d5b0f=_0x69e8e8;logger[_0x5d5b0f('0x11')](_0x5d5b0f('0x1d'),_0x325518);})[_0x69e8e8('0x8')](function(_0x299d23){const _0x1431e8=_0x69e8e8;logger[_0x1431e8('0x11')](JSON[_0x1431e8('0xf')](_0x299d23));});});},Migration[_0x50f12d('0x16')][_0x50f12d('0x6')]=function(_0xd4154f,_0x4ec573,_0xae974f){const _0x38859b=_0x50f12d,_0x237e63=this;this[_0x38859b('0x1')][_0x38859b('0x5')](function(){const _0x52c589=_0x38859b;return _0x237e63[_0x52c589('0x1c')][_0x52c589('0x6')](_0xd4154f,_0x4ec573,{'indexName':_0xae974f})[_0x52c589('0xc')](function(){const _0x388793=_0x52c589;logger[_0x388793('0x11')]('addIndex\x20%s\x20%s\x20%s',_0xd4154f,_0x4ec573[_0x388793('0x19')](','),_0xae974f);})[_0x52c589('0x8')](function(_0x1cca69){const _0x13573d=_0x52c589;logger[_0x13573d('0x11')](JSON[_0x13573d('0xf')](_0x1cca69));});});},Migration[_0x50f12d('0x16')][_0x50f12d('0x14')]=function(_0x62c69b,_0x5b87bb){const _0x393063=_0x50f12d,_0x3dd3bc=this;this[_0x393063('0x1')][_0x393063('0x5')](function(){const _0x3d4334=_0x393063;return _0x3dd3bc[_0x3d4334('0x1c')][_0x3d4334('0x14')](_0x62c69b,_0x5b87bb)['then'](function(){const _0x34da1a=_0x3d4334;logger[_0x34da1a('0x11')](_0x34da1a('0xd'),_0x62c69b,_0x5b87bb);})[_0x3d4334('0x8')](function(_0xb3062c){const _0x4953b5=_0x3d4334;logger[_0x4953b5('0x11')](JSON['stringify'](_0xb3062c));});});},Migration[_0x50f12d('0x16')]['query']=function(_0x248bd6){const _0x81b31=_0x50f12d,_0x1084e7=this;this[_0x81b31('0x1')][_0x81b31('0x5')](function(){const _0x49368e=_0x81b31;return _0x1084e7['queryInterface'][_0x49368e('0x3')][_0x49368e('0x2')](_0x248bd6)[_0x49368e('0xc')](function(){const _0x14a8fb=_0x49368e;logger['info'](_0x14a8fb('0x18'),_0x248bd6);})[_0x49368e('0x8')](function(_0x1644d8){const _0x3bf6d4=_0x49368e;logger[_0x3bf6d4('0x11')](JSON['stringify'](_0x1644d8));});});},Migration[_0x50f12d('0x16')][_0x50f12d('0xe')]=function(_0x32c27a,_0x458d98){const _0x14eaf1=_0x50f12d,_0x22cfd9=this;this['sequence'][_0x14eaf1('0x5')](function(){const _0x106d4a=_0x14eaf1;return _0x22cfd9[_0x106d4a('0x1c')]['removeColumn'](_0x32c27a,_0x458d98)['then'](function(){const _0x163c97=_0x106d4a;logger['info'](_0x163c97('0x0'),_0x458d98,_0x32c27a);})['catch'](function(_0x31a1c){const _0x17832b=_0x106d4a;logger[_0x17832b('0x11')](util[_0x17832b('0xa')](_0x31a1c,{'showHidden':![],'depth':null}));});});},Migration['prototype']['renameColumn']=function(_0x3117f1,_0x32ae21,_0x531d95){const _0x214e18=_0x50f12d,_0x222622=this;this[_0x214e18('0x1')][_0x214e18('0x5')](function(){const _0x265c2c=_0x214e18;return _0x222622[_0x265c2c('0x1c')][_0x265c2c('0x1b')](_0x3117f1,_0x32ae21,_0x531d95)['then'](function(){const _0x13c41b=_0x265c2c;logger['info'](_0x13c41b('0x17'),_0x32ae21,_0x531d95,_0x3117f1);})[_0x265c2c('0x8')](function(_0x1fc1df){const _0xd25259=_0x265c2c;logger[_0xd25259('0x11')](util[_0xd25259('0xa')](_0x1fc1df,{'showHidden':![],'depth':null}));});});},Migration[_0x50f12d('0x16')]['final']=function(_0x4c3e4b){const _0x3e0805=_0x50f12d;this[_0x3e0805('0x1')]['enqueue'](function(){return _0x4c3e4b();});},module[_0x50f12d('0x1e')]={'up':function(_0x270d5c){return new Promise(function(_0x2f2286){const _0x2df5cf=a981_0x3cdb,_0x231a90=new Migration(_0x270d5c);_0x231a90[_0x2df5cf('0x7')](_0x2f2286);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.9.js b/server/migrations/2.3.9.js index 5093005..1f173a1 100644 --- a/server/migrations/2.3.9.js +++ b/server/migrations/2.3.9.js @@ -1 +1 @@ -const a982_0x4f77=['addColumn','dropTable','then','finally','prototype','removeIndex','addIndex\x20%s\x20%s\x20%s\x20[%s]','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','final','tail','Added\x20column\x20%s\x20to\x20%s','sequence','indicesType','removeColumn','../config/logger','changeColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','renameColumn','sequelize','query','enqueue','indexName','queryInterface','stringify','util','exports','Removed\x20column\x20%s\x20from\x20%s','info','table\x20dropped\x20%s','catch'];(function(_0x37baae,_0x4f773d){const _0x3378b6=function(_0x385efe){while(--_0x385efe){_0x37baae['push'](_0x37baae['shift']());}};_0x3378b6(++_0x4f773d);}(a982_0x4f77,0xf6));const a982_0x3378=function(_0x37baae,_0x4f773d){_0x37baae=_0x37baae-0x0;let _0x3378b6=a982_0x4f77[_0x37baae];return _0x3378b6;};const _0x3ba369=a982_0x3378;'use strict';const util=require(_0x3ba369('0x12')),logger=require(_0x3ba369('0x8'))('migration'),Sequence=function(){};Sequence[_0x3ba369('0x1c')][_0x3ba369('0xe')]=function(_0x385efe){const _0x105832=_0x3ba369;this[_0x105832('0x3')]=this[_0x105832('0x3')]?this['tail'][_0x105832('0x1b')](_0x385efe):_0x385efe();};const Migration=function(_0x37bd71){const _0x46086e=_0x3ba369;this[_0x46086e('0x10')]=_0x37bd71,this['sequence']=new Sequence();};Migration[_0x3ba369('0x1c')][_0x3ba369('0x9')]=function(_0x2caf6f,_0x4c8a28,_0x4fd02c){const _0x2e7f6a=_0x3ba369,_0x247d1a=this;this[_0x2e7f6a('0x5')][_0x2e7f6a('0xe')](function(){const _0x310021=_0x2e7f6a;return _0x247d1a[_0x310021('0x10')][_0x310021('0x9')](_0x2caf6f,_0x4c8a28,_0x4fd02c)['then'](function(){const _0x16b6de=_0x310021;logger['info'](_0x16b6de('0xa'),_0x4c8a28,_0x2caf6f);})['catch'](function(_0x2baf81){const _0x54cc47=_0x310021;logger[_0x54cc47('0x15')](JSON[_0x54cc47('0x11')](_0x2baf81));});});},Migration[_0x3ba369('0x1c')][_0x3ba369('0x18')]=function(_0x20ef8c,_0x154fb5,_0x1c98ae){const _0xaeb8c=_0x3ba369,_0x13b7e6=this;this[_0xaeb8c('0x5')][_0xaeb8c('0xe')](function(){const _0x587430=_0xaeb8c;return _0x13b7e6[_0x587430('0x10')][_0x587430('0x18')](_0x20ef8c,_0x154fb5,_0x1c98ae)[_0x587430('0x1a')](function(){const _0x1271ea=_0x587430;logger[_0x1271ea('0x15')](_0x1271ea('0x4'),_0x154fb5,_0x20ef8c);})[_0x587430('0x17')](function(_0xe52e64){const _0x2fbb32=_0x587430;logger[_0x2fbb32('0x15')](JSON['stringify'](_0xe52e64));});});},Migration[_0x3ba369('0x1c')]['dropTable']=function(_0x1f9abd){const _0x2cc92c=_0x3ba369,_0x1ae0de=this;this[_0x2cc92c('0x5')]['enqueue'](function(){const _0x143475=_0x2cc92c;return _0x1ae0de['queryInterface'][_0x143475('0x19')](_0x1f9abd,{'force':!![]})['then'](function(){const _0x80b560=_0x143475;logger['info'](_0x80b560('0x16'),_0x1f9abd);})[_0x143475('0x17')](function(_0x25c061){const _0x577127=_0x143475;logger[_0x577127('0x15')](JSON[_0x577127('0x11')](_0x25c061));});});},Migration[_0x3ba369('0x1c')]['addIndex']=function(_0x4e563d,_0x4d0dd9,_0x1e85e1){const _0x9b7a84=_0x3ba369,_0x243b99=this;this[_0x9b7a84('0x5')]['enqueue'](function(){const _0xb54c4e=_0x9b7a84;return _0x243b99[_0xb54c4e('0x10')]['addIndex'](_0x4e563d,_0x4d0dd9,{'indexName':_0x1e85e1['indexName'],'indicesType':_0x1e85e1['indicesType']})[_0xb54c4e('0x1a')](function(){const _0x1e1a52=_0xb54c4e;logger[_0x1e1a52('0x15')](_0x1e1a52('0x0'),_0x4e563d,_0x4d0dd9['join'](','),_0x1e85e1[_0x1e1a52('0xf')],_0x1e85e1[_0x1e1a52('0x6')]);})[_0xb54c4e('0x17')](function(_0x1b6096){const _0x251373=_0xb54c4e;logger[_0x251373('0x15')](JSON[_0x251373('0x11')](_0x1b6096));});});},Migration[_0x3ba369('0x1c')][_0x3ba369('0x1d')]=function(_0x54e815,_0x2486c9){const _0x388b8c=_0x3ba369,_0x2a40c=this;this[_0x388b8c('0x5')][_0x388b8c('0xe')](function(){const _0x433d28=_0x388b8c;return _0x2a40c[_0x433d28('0x10')][_0x433d28('0x1d')](_0x54e815,_0x2486c9)[_0x433d28('0x1a')](function(){const _0x43f964=_0x433d28;logger[_0x43f964('0x15')]('removeIndex\x20%s\x20%s',_0x54e815,_0x2486c9);})[_0x433d28('0x17')](function(_0x2fa131){logger['info'](JSON['stringify'](_0x2fa131));});});},Migration[_0x3ba369('0x1c')][_0x3ba369('0xd')]=function(_0x331373){const _0x29f7e1=_0x3ba369,_0x16fe2b=this;this[_0x29f7e1('0x5')]['enqueue'](function(){const _0x10e538=_0x29f7e1;return _0x16fe2b[_0x10e538('0x10')][_0x10e538('0xc')][_0x10e538('0xd')](_0x331373)[_0x10e538('0x1a')](function(){const _0x5726a6=_0x10e538;logger[_0x5726a6('0x15')]('query\x20%s',_0x331373);})[_0x10e538('0x17')](function(_0x26966f){const _0x1086cd=_0x10e538;logger['info'](JSON[_0x1086cd('0x11')](_0x26966f));});});},Migration[_0x3ba369('0x1c')][_0x3ba369('0x7')]=function(_0x4f1c9b,_0x46da46){const _0x5f5651=_0x3ba369,_0x3c5034=this;this[_0x5f5651('0x5')]['enqueue'](function(){const _0x22c777=_0x5f5651;return _0x3c5034['queryInterface']['removeColumn'](_0x4f1c9b,_0x46da46)['then'](function(){const _0x2152f7=a982_0x3378;logger[_0x2152f7('0x15')](_0x2152f7('0x14'),_0x46da46,_0x4f1c9b);})[_0x22c777('0x17')](function(_0x29798b){const _0xcdd703=_0x22c777;logger[_0xcdd703('0x15')](util['inspect'](_0x29798b,{'showHidden':![],'depth':null}));});});},Migration[_0x3ba369('0x1c')][_0x3ba369('0xb')]=function(_0x47444f,_0x138412,_0x356a33){const _0x58c595=_0x3ba369,_0x2c82be=this;this[_0x58c595('0x5')]['enqueue'](function(){const _0x137e1a=_0x58c595;return _0x2c82be['queryInterface'][_0x137e1a('0xb')](_0x47444f,_0x138412,_0x356a33)[_0x137e1a('0x1a')](function(){const _0x23e7d8=_0x137e1a;logger['info'](_0x23e7d8('0x1'),_0x138412,_0x356a33,_0x47444f);})[_0x137e1a('0x17')](function(_0x114916){logger['info'](util['inspect'](_0x114916,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x2ce798){const _0x10c613=_0x3ba369;this[_0x10c613('0x5')][_0x10c613('0xe')](function(){return _0x2ce798();});},module[_0x3ba369('0x13')]={'up':function(_0x3f2dbe){return new Promise(function(_0x170339){const _0x402400=a982_0x3378,_0x466eaf=new Migration(_0x3f2dbe);_0x466eaf[_0x402400('0x2')](_0x170339);});},'down':function(){}}; \ No newline at end of file +const a982_0x5ee6=['util','Added\x20column\x20%s\x20to\x20%s','info','renameColumn','then','indexName','indicesType','query\x20%s','sequelize','final','enqueue','query','catch','sequence','removeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','tail','addColumn','addIndex','finally','changeColumn','inspect','Changed\x20column\x20%s\x20in\x20table\x20%s','migration','prototype','addIndex\x20%s\x20%s\x20%s\x20[%s]','exports','removeIndex','join','queryInterface','../config/logger','removeIndex\x20%s\x20%s','stringify'];(function(_0x557dca,_0x5ee622){const _0x12518a=function(_0x539e2c){while(--_0x539e2c){_0x557dca['push'](_0x557dca['shift']());}};_0x12518a(++_0x5ee622);}(a982_0x5ee6,0x71));const a982_0x1251=function(_0x557dca,_0x5ee622){_0x557dca=_0x557dca-0x0;let _0x12518a=a982_0x5ee6[_0x557dca];return _0x12518a;};const _0x16d804=a982_0x1251;'use strict';const util=require(_0x16d804('0x13')),logger=require(_0x16d804('0x10'))(_0x16d804('0x9')),Sequence=function(){};Sequence[_0x16d804('0xa')][_0x16d804('0x1d')]=function(_0x539e2c){const _0x6e547e=_0x16d804;this['tail']=this['tail']?this[_0x6e547e('0x2')][_0x6e547e('0x5')](_0x539e2c):_0x539e2c();};const Migration=function(_0x12f537){const _0x30f334=_0x16d804;this[_0x30f334('0xf')]=_0x12f537,this[_0x30f334('0x20')]=new Sequence();};Migration[_0x16d804('0xa')][_0x16d804('0x6')]=function(_0x42aa00,_0x58c166,_0x76cf9a){const _0x1e28dd=_0x16d804,_0x3b63bf=this;this['sequence'][_0x1e28dd('0x1d')](function(){const _0x50aa84=_0x1e28dd;return _0x3b63bf['queryInterface'][_0x50aa84('0x6')](_0x42aa00,_0x58c166,_0x76cf9a)[_0x50aa84('0x17')](function(){const _0x551ad1=_0x50aa84;logger[_0x551ad1('0x15')](_0x551ad1('0x8'),_0x58c166,_0x42aa00);})[_0x50aa84('0x1f')](function(_0x563974){const _0x18162d=_0x50aa84;logger['info'](JSON[_0x18162d('0x12')](_0x563974));});});},Migration[_0x16d804('0xa')][_0x16d804('0x3')]=function(_0x2bb9c1,_0x59d848,_0x354340){const _0x561c1e=_0x16d804,_0x25292f=this;this[_0x561c1e('0x20')][_0x561c1e('0x1d')](function(){const _0x569bfb=_0x561c1e;return _0x25292f[_0x569bfb('0xf')]['addColumn'](_0x2bb9c1,_0x59d848,_0x354340)[_0x569bfb('0x17')](function(){const _0x233b2d=_0x569bfb;logger[_0x233b2d('0x15')](_0x233b2d('0x14'),_0x59d848,_0x2bb9c1);})[_0x569bfb('0x1f')](function(_0x1ea17c){logger['info'](JSON['stringify'](_0x1ea17c));});});},Migration['prototype']['dropTable']=function(_0x2b7f02){const _0x1d39d8=_0x16d804,_0x435fd6=this;this[_0x1d39d8('0x20')][_0x1d39d8('0x1d')](function(){const _0x2bfc26=_0x1d39d8;return _0x435fd6[_0x2bfc26('0xf')]['dropTable'](_0x2b7f02,{'force':!![]})['then'](function(){logger['info']('table\x20dropped\x20%s',_0x2b7f02);})[_0x2bfc26('0x1f')](function(_0x5f49f1){const _0x459e16=_0x2bfc26;logger[_0x459e16('0x15')](JSON[_0x459e16('0x12')](_0x5f49f1));});});},Migration[_0x16d804('0xa')][_0x16d804('0x4')]=function(_0xc9ea5e,_0x232c0b,_0x59573c){const _0x13ca1f=_0x16d804,_0x3ef317=this;this[_0x13ca1f('0x20')][_0x13ca1f('0x1d')](function(){const _0x2380ab=_0x13ca1f;return _0x3ef317['queryInterface'][_0x2380ab('0x4')](_0xc9ea5e,_0x232c0b,{'indexName':_0x59573c[_0x2380ab('0x18')],'indicesType':_0x59573c[_0x2380ab('0x19')]})[_0x2380ab('0x17')](function(){const _0x187fd4=_0x2380ab;logger[_0x187fd4('0x15')](_0x187fd4('0xb'),_0xc9ea5e,_0x232c0b[_0x187fd4('0xe')](','),_0x59573c[_0x187fd4('0x18')],_0x59573c[_0x187fd4('0x19')]);})['catch'](function(_0x4dcb26){logger['info'](JSON['stringify'](_0x4dcb26));});});},Migration['prototype'][_0x16d804('0xd')]=function(_0x277bb4,_0x5ac3a3){const _0x4b9264=_0x16d804,_0x2fd81e=this;this[_0x4b9264('0x20')][_0x4b9264('0x1d')](function(){const _0x3b1aa5=_0x4b9264;return _0x2fd81e[_0x3b1aa5('0xf')]['removeIndex'](_0x277bb4,_0x5ac3a3)[_0x3b1aa5('0x17')](function(){const _0x500a18=_0x3b1aa5;logger[_0x500a18('0x15')](_0x500a18('0x11'),_0x277bb4,_0x5ac3a3);})[_0x3b1aa5('0x1f')](function(_0x363c7c){const _0x290e97=_0x3b1aa5;logger[_0x290e97('0x15')](JSON['stringify'](_0x363c7c));});});},Migration[_0x16d804('0xa')][_0x16d804('0x1e')]=function(_0x2b0220){const _0x1905a3=this;this['sequence']['enqueue'](function(){const _0xae6441=a982_0x1251;return _0x1905a3[_0xae6441('0xf')][_0xae6441('0x1b')]['query'](_0x2b0220)[_0xae6441('0x17')](function(){const _0x42c0d2=_0xae6441;logger[_0x42c0d2('0x15')](_0x42c0d2('0x1a'),_0x2b0220);})[_0xae6441('0x1f')](function(_0x476032){const _0x1736d7=_0xae6441;logger[_0x1736d7('0x15')](JSON[_0x1736d7('0x12')](_0x476032));});});},Migration[_0x16d804('0xa')]['removeColumn']=function(_0x2662f4,_0x5a62aa){const _0x28a209=_0x16d804,_0x550200=this;this[_0x28a209('0x20')][_0x28a209('0x1d')](function(){const _0x45180a=_0x28a209;return _0x550200[_0x45180a('0xf')][_0x45180a('0x0')](_0x2662f4,_0x5a62aa)[_0x45180a('0x17')](function(){const _0xe96d4a=_0x45180a;logger[_0xe96d4a('0x15')]('Removed\x20column\x20%s\x20from\x20%s',_0x5a62aa,_0x2662f4);})[_0x45180a('0x1f')](function(_0x4b1a52){const _0x339b97=_0x45180a;logger[_0x339b97('0x15')](util[_0x339b97('0x7')](_0x4b1a52,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x16d804('0x16')]=function(_0x28fd8a,_0x10c654,_0x1d63cb){const _0x47e0bb=this;this['sequence']['enqueue'](function(){const _0x41642d=a982_0x1251;return _0x47e0bb[_0x41642d('0xf')][_0x41642d('0x16')](_0x28fd8a,_0x10c654,_0x1d63cb)['then'](function(){const _0xbd719d=_0x41642d;logger[_0xbd719d('0x15')](_0xbd719d('0x1'),_0x10c654,_0x1d63cb,_0x28fd8a);})['catch'](function(_0x323658){const _0x47f7a2=_0x41642d;logger[_0x47f7a2('0x15')](util[_0x47f7a2('0x7')](_0x323658,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x16d804('0x1c')]=function(_0xaf54){const _0x52f454=_0x16d804;this[_0x52f454('0x20')][_0x52f454('0x1d')](function(){return _0xaf54();});},module[_0x16d804('0xc')]={'up':function(_0x4fbde2){return new Promise(function(_0x52da2d){const _0x54e069=new Migration(_0x4fbde2);_0x54e069['final'](_0x52da2d);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.91.js b/server/migrations/2.3.91.js index 8358dea..18f168b 100644 --- a/server/migrations/2.3.91.js +++ b/server/migrations/2.3.91.js @@ -1 +1 @@ -const a983_0x3cc3=['Added\x20column\x20%s\x20to\x20%s','inspect','join','sequence','removeColumn','sipcallid','info','report_call','query','tail','Removed\x20column\x20%s\x20from\x20%s','prototype','finally','final','query\x20%s','enqueue','migration','removeIndex\x20%s\x20%s','exports','util','queryInterface','changeColumn','then','../config/logger','catch','renameColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','addColumn','stringify','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','table\x20dropped\x20%s','addIndex','addIndex\x20%s\x20%s\x20%s'];(function(_0x491957,_0x3cc32b){const _0x447add=function(_0x35a987){while(--_0x35a987){_0x491957['push'](_0x491957['shift']());}};_0x447add(++_0x3cc32b);}(a983_0x3cc3,0x79));const a983_0x447a=function(_0x491957,_0x3cc32b){_0x491957=_0x491957-0x0;let _0x447add=a983_0x3cc3[_0x491957];return _0x447add;};const _0x5d63db=a983_0x447a;'use strict';const util=require(_0x5d63db('0x1e')),logger=require(_0x5d63db('0x1'))(_0x5d63db('0x1b')),Sequence=function(){};Sequence[_0x5d63db('0x16')][_0x5d63db('0x1a')]=function(_0x35a987){const _0x579276=_0x5d63db;this[_0x579276('0x14')]=this[_0x579276('0x14')]?this[_0x579276('0x14')][_0x579276('0x17')](_0x35a987):_0x35a987();};const Migration=function(_0x9e0af3){const _0xf5c092=_0x5d63db;this[_0xf5c092('0x1f')]=_0x9e0af3,this[_0xf5c092('0xe')]=new Sequence();};Migration[_0x5d63db('0x16')][_0x5d63db('0x20')]=function(_0x5212d0,_0x4e36b2,_0x361597){const _0x3362c9=this;this['sequence']['enqueue'](function(){const _0x4a5a68=a983_0x447a;return _0x3362c9['queryInterface'][_0x4a5a68('0x20')](_0x5212d0,_0x4e36b2,_0x361597)[_0x4a5a68('0x0')](function(){const _0x112968=_0x4a5a68;logger[_0x112968('0x11')](_0x112968('0x4'),_0x4e36b2,_0x5212d0);})[_0x4a5a68('0x2')](function(_0x1eaabd){const _0x2587cc=_0x4a5a68;logger[_0x2587cc('0x11')](JSON[_0x2587cc('0x6')](_0x1eaabd));});});},Migration[_0x5d63db('0x16')][_0x5d63db('0x5')]=function(_0x5a5253,_0x8b2d14,_0x528833){const _0x24ab73=_0x5d63db,_0x41236a=this;this[_0x24ab73('0xe')]['enqueue'](function(){const _0x52d8b8=_0x24ab73;return _0x41236a[_0x52d8b8('0x1f')][_0x52d8b8('0x5')](_0x5a5253,_0x8b2d14,_0x528833)['then'](function(){const _0x31055c=_0x52d8b8;logger[_0x31055c('0x11')](_0x31055c('0xb'),_0x8b2d14,_0x5a5253);})[_0x52d8b8('0x2')](function(_0x42e036){const _0xab6269=_0x52d8b8;logger[_0xab6269('0x11')](JSON[_0xab6269('0x6')](_0x42e036));});});},Migration['prototype']['dropTable']=function(_0x3cd781){const _0x3e0cac=_0x5d63db,_0x2380be=this;this[_0x3e0cac('0xe')][_0x3e0cac('0x1a')](function(){const _0x57b7c0=_0x3e0cac;return _0x2380be[_0x57b7c0('0x1f')]['dropTable'](_0x3cd781,{'force':!![]})[_0x57b7c0('0x0')](function(){const _0xe064bb=_0x57b7c0;logger['info'](_0xe064bb('0x8'),_0x3cd781);})[_0x57b7c0('0x2')](function(_0x519e94){const _0x52ec80=_0x57b7c0;logger[_0x52ec80('0x11')](JSON['stringify'](_0x519e94));});});},Migration['prototype']['addIndex']=function(_0x5d04fa,_0x3b4f41,_0x5b1679){const _0x329a49=_0x5d63db,_0x28e564=this;this[_0x329a49('0xe')][_0x329a49('0x1a')](function(){const _0x2e472c=_0x329a49;return _0x28e564[_0x2e472c('0x1f')][_0x2e472c('0x9')](_0x5d04fa,_0x3b4f41,{'indexName':_0x5b1679})[_0x2e472c('0x0')](function(){const _0x56a1ab=_0x2e472c;logger['info'](_0x56a1ab('0xa'),_0x5d04fa,_0x3b4f41[_0x56a1ab('0xd')](','),_0x5b1679);})[_0x2e472c('0x2')](function(_0x83e891){const _0x36f211=_0x2e472c;logger[_0x36f211('0x11')](JSON[_0x36f211('0x6')](_0x83e891));});});},Migration['prototype']['removeIndex']=function(_0x28d875,_0x4679ae){const _0x3d1efd=_0x5d63db,_0xa707cf=this;this[_0x3d1efd('0xe')][_0x3d1efd('0x1a')](function(){const _0x383f80=_0x3d1efd;return _0xa707cf[_0x383f80('0x1f')]['removeIndex'](_0x28d875,_0x4679ae)[_0x383f80('0x0')](function(){const _0x28b3a2=_0x383f80;logger[_0x28b3a2('0x11')](_0x28b3a2('0x1c'),_0x28d875,_0x4679ae);})[_0x383f80('0x2')](function(_0x343db1){const _0x5acc25=_0x383f80;logger[_0x5acc25('0x11')](JSON[_0x5acc25('0x6')](_0x343db1));});});},Migration[_0x5d63db('0x16')][_0x5d63db('0x13')]=function(_0x29c3c4){const _0xcda097=_0x5d63db,_0x24d205=this;this[_0xcda097('0xe')][_0xcda097('0x1a')](function(){const _0x550d63=_0xcda097;return _0x24d205[_0x550d63('0x1f')]['sequelize'][_0x550d63('0x13')](_0x29c3c4)['then'](function(){const _0x2dc4bd=_0x550d63;logger[_0x2dc4bd('0x11')](_0x2dc4bd('0x19'),_0x29c3c4);})[_0x550d63('0x2')](function(_0x47b461){logger['info'](JSON['stringify'](_0x47b461));});});},Migration['prototype'][_0x5d63db('0xf')]=function(_0x5573c3,_0x3dd2a0){const _0x314932=_0x5d63db,_0x17ee94=this;this['sequence'][_0x314932('0x1a')](function(){const _0x495006=_0x314932;return _0x17ee94['queryInterface']['removeColumn'](_0x5573c3,_0x3dd2a0)['then'](function(){const _0x40738f=a983_0x447a;logger[_0x40738f('0x11')](_0x40738f('0x15'),_0x3dd2a0,_0x5573c3);})[_0x495006('0x2')](function(_0x75ab42){const _0x23df1e=_0x495006;logger[_0x23df1e('0x11')](util['inspect'](_0x75ab42,{'showHidden':![],'depth':null}));});});},Migration[_0x5d63db('0x16')][_0x5d63db('0x3')]=function(_0x197aae,_0x28ee69,_0x50bad0){const _0x542e2b=this;this['sequence']['enqueue'](function(){const _0x41afde=a983_0x447a;return _0x542e2b['queryInterface'][_0x41afde('0x3')](_0x197aae,_0x28ee69,_0x50bad0)[_0x41afde('0x0')](function(){const _0x2c5169=_0x41afde;logger[_0x2c5169('0x11')](_0x2c5169('0x7'),_0x28ee69,_0x50bad0,_0x197aae);})[_0x41afde('0x2')](function(_0x1d904e){const _0x58ce69=_0x41afde;logger[_0x58ce69('0x11')](util[_0x58ce69('0xc')](_0x1d904e,{'showHidden':![],'depth':null}));});});},Migration[_0x5d63db('0x16')][_0x5d63db('0x18')]=function(_0x455757){const _0x46e59a=_0x5d63db;this[_0x46e59a('0xe')][_0x46e59a('0x1a')](function(){return _0x455757();});},module[_0x5d63db('0x1d')]={'up':function(_0x13dc4b,_0xda1840){return new Promise(function(_0x1e2a6b){const _0x23a4ca=a983_0x447a,_0x3b953d=new Migration(_0x13dc4b);_0x3b953d[_0x23a4ca('0x5')](_0x23a4ca('0x12'),_0x23a4ca('0x10'),{'type':_0xda1840['STRING']}),_0x3b953d[_0x23a4ca('0x18')](_0x1e2a6b);});},'down':function(){}}; \ No newline at end of file +const a983_0x2323=['table\x20dropped\x20%s','enqueue','join','sipcallid','queryInterface','util','STRING','Removed\x20column\x20%s\x20from\x20%s','tail','sequelize','then','dropTable','query','finally','Changed\x20column\x20%s\x20in\x20table\x20%s','inspect','removeColumn','removeIndex\x20%s\x20%s','catch','addColumn','migration','query\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','stringify','info','final','sequence','prototype','report_call','Added\x20column\x20%s\x20to\x20%s','removeIndex','changeColumn','renameColumn'];(function(_0x2548fe,_0x2323b7){const _0x223327=function(_0x5eaec8){while(--_0x5eaec8){_0x2548fe['push'](_0x2548fe['shift']());}};_0x223327(++_0x2323b7);}(a983_0x2323,0x1d2));const a983_0x2233=function(_0x2548fe,_0x2323b7){_0x2548fe=_0x2548fe-0x0;let _0x223327=a983_0x2323[_0x2548fe];return _0x223327;};const _0x40de55=a983_0x2233;'use strict';const util=require(_0x40de55('0x1')),logger=require('../config/logger')(_0x40de55('0x10')),Sequence=function(){};Sequence[_0x40de55('0x17')]['enqueue']=function(_0x5eaec8){const _0x225f5a=_0x40de55;this[_0x225f5a('0x4')]=this['tail']?this['tail'][_0x225f5a('0x9')](_0x5eaec8):_0x5eaec8();};const Migration=function(_0x56e7df){const _0x3ef296=_0x40de55;this[_0x3ef296('0x0')]=_0x56e7df,this[_0x3ef296('0x16')]=new Sequence();};Migration[_0x40de55('0x17')][_0x40de55('0x1b')]=function(_0x11ef4e,_0x271534,_0x106658){const _0x1e952e=_0x40de55,_0x1d74d5=this;this['sequence'][_0x1e952e('0x1e')](function(){const _0x43a0b5=_0x1e952e;return _0x1d74d5[_0x43a0b5('0x0')][_0x43a0b5('0x1b')](_0x11ef4e,_0x271534,_0x106658)[_0x43a0b5('0x6')](function(){const _0x454bab=_0x43a0b5;logger[_0x454bab('0x14')](_0x454bab('0xa'),_0x271534,_0x11ef4e);})['catch'](function(_0x2803fd){const _0x1cb6fb=_0x43a0b5;logger[_0x1cb6fb('0x14')](JSON[_0x1cb6fb('0x13')](_0x2803fd));});});},Migration[_0x40de55('0x17')][_0x40de55('0xf')]=function(_0x56f654,_0x2a492d,_0x671421){const _0x442aca=_0x40de55,_0x277776=this;this[_0x442aca('0x16')][_0x442aca('0x1e')](function(){const _0xa453c9=_0x442aca;return _0x277776[_0xa453c9('0x0')][_0xa453c9('0xf')](_0x56f654,_0x2a492d,_0x671421)['then'](function(){const _0xd0fb59=_0xa453c9;logger[_0xd0fb59('0x14')](_0xd0fb59('0x19'),_0x2a492d,_0x56f654);})[_0xa453c9('0xe')](function(_0x5bf659){const _0x28172f=_0xa453c9;logger[_0x28172f('0x14')](JSON['stringify'](_0x5bf659));});});},Migration[_0x40de55('0x17')]['dropTable']=function(_0xbbb0ad){const _0x5c7578=_0x40de55,_0x293a73=this;this[_0x5c7578('0x16')][_0x5c7578('0x1e')](function(){const _0x11edd1=_0x5c7578;return _0x293a73[_0x11edd1('0x0')][_0x11edd1('0x7')](_0xbbb0ad,{'force':!![]})['then'](function(){const _0x2633dd=_0x11edd1;logger[_0x2633dd('0x14')](_0x2633dd('0x1d'),_0xbbb0ad);})[_0x11edd1('0xe')](function(_0x107e6f){const _0x409078=_0x11edd1;logger['info'](JSON[_0x409078('0x13')](_0x107e6f));});});},Migration[_0x40de55('0x17')]['addIndex']=function(_0x2455a4,_0x4a02bc,_0x18a6d7){const _0x4c9eea=_0x40de55,_0x5ead8b=this;this[_0x4c9eea('0x16')][_0x4c9eea('0x1e')](function(){const _0x530f29=_0x4c9eea;return _0x5ead8b['queryInterface']['addIndex'](_0x2455a4,_0x4a02bc,{'indexName':_0x18a6d7})[_0x530f29('0x6')](function(){const _0x4a4654=_0x530f29;logger[_0x4a4654('0x14')]('addIndex\x20%s\x20%s\x20%s',_0x2455a4,_0x4a02bc[_0x4a4654('0x1f')](','),_0x18a6d7);})[_0x530f29('0xe')](function(_0x59fb75){const _0x44edcc=_0x530f29;logger[_0x44edcc('0x14')](JSON['stringify'](_0x59fb75));});});},Migration[_0x40de55('0x17')]['removeIndex']=function(_0x442ae7,_0x32c326){const _0x363f2c=_0x40de55,_0x5d49eb=this;this[_0x363f2c('0x16')][_0x363f2c('0x1e')](function(){const _0x50bad3=_0x363f2c;return _0x5d49eb[_0x50bad3('0x0')][_0x50bad3('0x1a')](_0x442ae7,_0x32c326)[_0x50bad3('0x6')](function(){const _0x7c5bad=_0x50bad3;logger[_0x7c5bad('0x14')](_0x7c5bad('0xd'),_0x442ae7,_0x32c326);})[_0x50bad3('0xe')](function(_0x5741f4){logger['info'](JSON['stringify'](_0x5741f4));});});},Migration[_0x40de55('0x17')][_0x40de55('0x8')]=function(_0x936e67){const _0x367938=_0x40de55,_0x57c8cc=this;this[_0x367938('0x16')][_0x367938('0x1e')](function(){const _0xe01312=_0x367938;return _0x57c8cc[_0xe01312('0x0')][_0xe01312('0x5')][_0xe01312('0x8')](_0x936e67)[_0xe01312('0x6')](function(){const _0x48570a=_0xe01312;logger[_0x48570a('0x14')](_0x48570a('0x11'),_0x936e67);})[_0xe01312('0xe')](function(_0x315a6e){const _0x8341d=_0xe01312;logger['info'](JSON[_0x8341d('0x13')](_0x315a6e));});});},Migration['prototype'][_0x40de55('0xc')]=function(_0x381481,_0xba2e7){const _0x351c23=_0x40de55,_0x2e51eb=this;this[_0x351c23('0x16')][_0x351c23('0x1e')](function(){const _0x427f0c=_0x351c23;return _0x2e51eb[_0x427f0c('0x0')][_0x427f0c('0xc')](_0x381481,_0xba2e7)[_0x427f0c('0x6')](function(){const _0x4fec07=_0x427f0c;logger['info'](_0x4fec07('0x3'),_0xba2e7,_0x381481);})[_0x427f0c('0xe')](function(_0x10671c){const _0x2c0b15=_0x427f0c;logger[_0x2c0b15('0x14')](util['inspect'](_0x10671c,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x40de55('0x1c')]=function(_0x38d7ae,_0xbe72bd,_0x3c6ec7){const _0x208cea=_0x40de55,_0x36b69e=this;this[_0x208cea('0x16')][_0x208cea('0x1e')](function(){const _0x4c0227=_0x208cea;return _0x36b69e[_0x4c0227('0x0')][_0x4c0227('0x1c')](_0x38d7ae,_0xbe72bd,_0x3c6ec7)[_0x4c0227('0x6')](function(){const _0x609ab3=_0x4c0227;logger[_0x609ab3('0x14')](_0x609ab3('0x12'),_0xbe72bd,_0x3c6ec7,_0x38d7ae);})[_0x4c0227('0xe')](function(_0x1b8146){const _0xd85d96=_0x4c0227;logger[_0xd85d96('0x14')](util[_0xd85d96('0xb')](_0x1b8146,{'showHidden':![],'depth':null}));});});},Migration[_0x40de55('0x17')][_0x40de55('0x15')]=function(_0x47fa1b){const _0x7ed438=_0x40de55;this['sequence'][_0x7ed438('0x1e')](function(){return _0x47fa1b();});},module['exports']={'up':function(_0x1fa670,_0x327e02){return new Promise(function(_0x4d605b){const _0x18eeed=a983_0x2233,_0x277658=new Migration(_0x1fa670);_0x277658['addColumn'](_0x18eeed('0x18'),_0x18eeed('0x20'),{'type':_0x327e02[_0x18eeed('0x2')]}),_0x277658[_0x18eeed('0x15')](_0x4d605b);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.92.js b/server/migrations/2.3.92.js index 334baf8..a319379 100644 --- a/server/migrations/2.3.92.js +++ b/server/migrations/2.3.92.js @@ -1 +1 @@ -const a984_0x4ed3=['renameColumn','removeColumn','addIndex\x20%s\x20%s\x20%s','finally','stringify','enqueue','migration','dropTable','then','removeIndex\x20%s\x20%s','sequence','addIndex','Added\x20column\x20%s\x20to\x20%s','util','join','queryInterface','final','query','changeColumn','removeIndex','exports','query\x20%s','prototype','addColumn','catch','info','tail'];(function(_0x771664,_0x4ed32a){const _0x273409=function(_0x22819e){while(--_0x22819e){_0x771664['push'](_0x771664['shift']());}};_0x273409(++_0x4ed32a);}(a984_0x4ed3,0x1ca));const a984_0x2734=function(_0x771664,_0x4ed32a){_0x771664=_0x771664-0x0;let _0x273409=a984_0x4ed3[_0x771664];return _0x273409;};const _0x5b40ff=a984_0x2734;'use strict';const util=require(_0x5b40ff('0xe')),logger=require('../config/logger')(_0x5b40ff('0x7')),Sequence=function(){};Sequence[_0x5b40ff('0x17')][_0x5b40ff('0x6')]=function(_0x22819e){const _0x3732d4=_0x5b40ff;this[_0x3732d4('0x0')]=this[_0x3732d4('0x0')]?this[_0x3732d4('0x0')][_0x3732d4('0x4')](_0x22819e):_0x22819e();};const Migration=function(_0x13163c){const _0x58b4a8=_0x5b40ff;this[_0x58b4a8('0x10')]=_0x13163c,this['sequence']=new Sequence();};Migration[_0x5b40ff('0x17')][_0x5b40ff('0x13')]=function(_0x14fe86,_0x4b6451,_0x583851){const _0xe9de3f=_0x5b40ff,_0x5f0617=this;this[_0xe9de3f('0xb')]['enqueue'](function(){const _0x5e62f7=_0xe9de3f;return _0x5f0617[_0x5e62f7('0x10')][_0x5e62f7('0x13')](_0x14fe86,_0x4b6451,_0x583851)[_0x5e62f7('0x9')](function(){const _0x17bd0e=_0x5e62f7;logger[_0x17bd0e('0x1a')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x4b6451,_0x14fe86);})[_0x5e62f7('0x19')](function(_0xb6b2e2){const _0x5d4879=_0x5e62f7;logger['info'](JSON[_0x5d4879('0x5')](_0xb6b2e2));});});},Migration[_0x5b40ff('0x17')][_0x5b40ff('0x18')]=function(_0x492802,_0x22200d,_0x242e39){const _0x1f8ab7=this;this['sequence']['enqueue'](function(){const _0x147821=a984_0x2734;return _0x1f8ab7[_0x147821('0x10')][_0x147821('0x18')](_0x492802,_0x22200d,_0x242e39)[_0x147821('0x9')](function(){const _0x576ccf=_0x147821;logger[_0x576ccf('0x1a')](_0x576ccf('0xd'),_0x22200d,_0x492802);})[_0x147821('0x19')](function(_0x229967){const _0x45429e=_0x147821;logger[_0x45429e('0x1a')](JSON[_0x45429e('0x5')](_0x229967));});});},Migration[_0x5b40ff('0x17')][_0x5b40ff('0x8')]=function(_0x545f93){const _0x254a18=this;this['sequence']['enqueue'](function(){const _0x2da7d1=a984_0x2734;return _0x254a18[_0x2da7d1('0x10')][_0x2da7d1('0x8')](_0x545f93,{'force':!![]})[_0x2da7d1('0x9')](function(){const _0x460f02=_0x2da7d1;logger[_0x460f02('0x1a')]('table\x20dropped\x20%s',_0x545f93);})['catch'](function(_0x55e056){const _0x5f5120=_0x2da7d1;logger[_0x5f5120('0x1a')](JSON['stringify'](_0x55e056));});});},Migration[_0x5b40ff('0x17')][_0x5b40ff('0xc')]=function(_0x3bd882,_0x25c9b2,_0x384a8c){const _0x1e57a2=_0x5b40ff,_0x42e176=this;this['sequence'][_0x1e57a2('0x6')](function(){const _0x463b33=_0x1e57a2;return _0x42e176['queryInterface'][_0x463b33('0xc')](_0x3bd882,_0x25c9b2,{'indexName':_0x384a8c})[_0x463b33('0x9')](function(){const _0x3955ae=_0x463b33;logger[_0x3955ae('0x1a')](_0x3955ae('0x3'),_0x3bd882,_0x25c9b2[_0x3955ae('0xf')](','),_0x384a8c);})['catch'](function(_0x121ad0){const _0x15ba22=_0x463b33;logger[_0x15ba22('0x1a')](JSON[_0x15ba22('0x5')](_0x121ad0));});});},Migration[_0x5b40ff('0x17')][_0x5b40ff('0x14')]=function(_0x253d36,_0x147144){const _0x326159=_0x5b40ff,_0x35ce76=this;this[_0x326159('0xb')]['enqueue'](function(){const _0x44999f=_0x326159;return _0x35ce76[_0x44999f('0x10')]['removeIndex'](_0x253d36,_0x147144)['then'](function(){const _0x49300c=_0x44999f;logger[_0x49300c('0x1a')](_0x49300c('0xa'),_0x253d36,_0x147144);})[_0x44999f('0x19')](function(_0x24c740){const _0x3d9ff4=_0x44999f;logger[_0x3d9ff4('0x1a')](JSON['stringify'](_0x24c740));});});},Migration[_0x5b40ff('0x17')][_0x5b40ff('0x12')]=function(_0x30e670){const _0x36a103=_0x5b40ff,_0x5b588c=this;this[_0x36a103('0xb')][_0x36a103('0x6')](function(){const _0x25d636=_0x36a103;return _0x5b588c[_0x25d636('0x10')]['sequelize'][_0x25d636('0x12')](_0x30e670)[_0x25d636('0x9')](function(){const _0x453935=_0x25d636;logger[_0x453935('0x1a')](_0x453935('0x16'),_0x30e670);})[_0x25d636('0x19')](function(_0x11983d){logger['info'](JSON['stringify'](_0x11983d));});});},Migration[_0x5b40ff('0x17')]['removeColumn']=function(_0x591a86,_0x2d3b58){const _0x10b9ff=_0x5b40ff,_0x1f0b7f=this;this[_0x10b9ff('0xb')][_0x10b9ff('0x6')](function(){const _0x157b14=_0x10b9ff;return _0x1f0b7f[_0x157b14('0x10')][_0x157b14('0x2')](_0x591a86,_0x2d3b58)['then'](function(){const _0x4f4929=_0x157b14;logger[_0x4f4929('0x1a')]('Removed\x20column\x20%s\x20from\x20%s',_0x2d3b58,_0x591a86);})['catch'](function(_0x52bdfa){const _0x218506=_0x157b14;logger[_0x218506('0x1a')](util['inspect'](_0x52bdfa,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x5b40ff('0x1')]=function(_0x2ab5b8,_0x952d7c,_0x512808){const _0x7d7df6=_0x5b40ff,_0x15112e=this;this[_0x7d7df6('0xb')][_0x7d7df6('0x6')](function(){const _0x287ca3=_0x7d7df6;return _0x15112e[_0x287ca3('0x10')][_0x287ca3('0x1')](_0x2ab5b8,_0x952d7c,_0x512808)[_0x287ca3('0x9')](function(){const _0x29fc6d=_0x287ca3;logger[_0x29fc6d('0x1a')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x952d7c,_0x512808,_0x2ab5b8);})[_0x287ca3('0x19')](function(_0x115777){logger['info'](util['inspect'](_0x115777,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x5b40ff('0x11')]=function(_0x36d67d){const _0x1403ef=_0x5b40ff;this[_0x1403ef('0xb')]['enqueue'](function(){return _0x36d67d();});},module[_0x5b40ff('0x15')]={'up':function(_0x218b24){return new Promise(function(_0x573c8e){const _0x5185a3=a984_0x2734,_0x21df5d=new Migration(_0x218b24);_0x21df5d[_0x5185a3('0x11')](_0x573c8e);});},'down':function(){}}; \ No newline at end of file +const a984_0x4a81=['stringify','util','enqueue','query','join','tail','exports','finally','Changed\x20column\x20%s\x20in\x20table\x20%s','renameColumn','query\x20%s','addColumn','queryInterface','addIndex\x20%s\x20%s\x20%s','addIndex','prototype','catch','final','dropTable','info','Added\x20column\x20%s\x20to\x20%s','sequence','then','removeColumn','removeIndex','migration','sequelize','changeColumn','../config/logger','inspect'];(function(_0x2f3371,_0x4a814c){const _0x1a7719=function(_0x9164dc){while(--_0x9164dc){_0x2f3371['push'](_0x2f3371['shift']());}};_0x1a7719(++_0x4a814c);}(a984_0x4a81,0x1b7));const a984_0x1a77=function(_0x2f3371,_0x4a814c){_0x2f3371=_0x2f3371-0x0;let _0x1a7719=a984_0x4a81[_0x2f3371];return _0x1a7719;};const _0x4e6a6f=a984_0x1a77;'use strict';const util=require(_0x4e6a6f('0xc')),logger=require(_0x4e6a6f('0x9'))(_0x4e6a6f('0x6')),Sequence=function(){};Sequence['prototype'][_0x4e6a6f('0xd')]=function(_0x9164dc){const _0x283b93=_0x4e6a6f;this['tail']=this[_0x283b93('0x10')]?this[_0x283b93('0x10')][_0x283b93('0x12')](_0x9164dc):_0x9164dc();};const Migration=function(_0x5d6ff6){const _0x2f077d=_0x4e6a6f;this[_0x2f077d('0x17')]=_0x5d6ff6,this['sequence']=new Sequence();};Migration[_0x4e6a6f('0x1a')][_0x4e6a6f('0x8')]=function(_0xeb09bc,_0x1cb654,_0x27dbf0){const _0x4b6388=_0x4e6a6f,_0x1a2f70=this;this[_0x4b6388('0x2')]['enqueue'](function(){const _0x59d175=_0x4b6388;return _0x1a2f70[_0x59d175('0x17')][_0x59d175('0x8')](_0xeb09bc,_0x1cb654,_0x27dbf0)[_0x59d175('0x3')](function(){const _0x52dc8e=_0x59d175;logger['info'](_0x52dc8e('0x13'),_0x1cb654,_0xeb09bc);})[_0x59d175('0x1b')](function(_0x25e597){const _0x361c62=_0x59d175;logger[_0x361c62('0x0')](JSON['stringify'](_0x25e597));});});},Migration[_0x4e6a6f('0x1a')][_0x4e6a6f('0x16')]=function(_0xe627c3,_0x56e8ca,_0x5553fd){const _0x3a8d27=_0x4e6a6f,_0x48b2b2=this;this[_0x3a8d27('0x2')][_0x3a8d27('0xd')](function(){const _0x2ae1bf=_0x3a8d27;return _0x48b2b2[_0x2ae1bf('0x17')][_0x2ae1bf('0x16')](_0xe627c3,_0x56e8ca,_0x5553fd)[_0x2ae1bf('0x3')](function(){const _0x4e4c06=_0x2ae1bf;logger[_0x4e4c06('0x0')](_0x4e4c06('0x1'),_0x56e8ca,_0xe627c3);})[_0x2ae1bf('0x1b')](function(_0x2c9479){const _0x44b6f3=_0x2ae1bf;logger[_0x44b6f3('0x0')](JSON[_0x44b6f3('0xb')](_0x2c9479));});});},Migration[_0x4e6a6f('0x1a')][_0x4e6a6f('0x1d')]=function(_0x591156){const _0x47c65d=_0x4e6a6f,_0x10dba8=this;this[_0x47c65d('0x2')][_0x47c65d('0xd')](function(){const _0x1ac354=_0x47c65d;return _0x10dba8[_0x1ac354('0x17')]['dropTable'](_0x591156,{'force':!![]})[_0x1ac354('0x3')](function(){const _0x8319ed=_0x1ac354;logger[_0x8319ed('0x0')]('table\x20dropped\x20%s',_0x591156);})[_0x1ac354('0x1b')](function(_0x5e53b5){const _0x255a4a=_0x1ac354;logger[_0x255a4a('0x0')](JSON[_0x255a4a('0xb')](_0x5e53b5));});});},Migration[_0x4e6a6f('0x1a')]['addIndex']=function(_0x3181f0,_0x274f9b,_0x1917be){const _0x493cf4=_0x4e6a6f,_0x2f97b8=this;this[_0x493cf4('0x2')][_0x493cf4('0xd')](function(){const _0x13d631=_0x493cf4;return _0x2f97b8[_0x13d631('0x17')][_0x13d631('0x19')](_0x3181f0,_0x274f9b,{'indexName':_0x1917be})['then'](function(){const _0x3b0137=_0x13d631;logger[_0x3b0137('0x0')](_0x3b0137('0x18'),_0x3181f0,_0x274f9b[_0x3b0137('0xf')](','),_0x1917be);})[_0x13d631('0x1b')](function(_0x5aa5fa){const _0x21692f=_0x13d631;logger[_0x21692f('0x0')](JSON[_0x21692f('0xb')](_0x5aa5fa));});});},Migration[_0x4e6a6f('0x1a')][_0x4e6a6f('0x5')]=function(_0x31f16f,_0xd2b7e1){const _0x4d3090=_0x4e6a6f,_0x15295c=this;this[_0x4d3090('0x2')][_0x4d3090('0xd')](function(){const _0x13b05b=_0x4d3090;return _0x15295c[_0x13b05b('0x17')][_0x13b05b('0x5')](_0x31f16f,_0xd2b7e1)['then'](function(){const _0x50a71e=_0x13b05b;logger[_0x50a71e('0x0')]('removeIndex\x20%s\x20%s',_0x31f16f,_0xd2b7e1);})[_0x13b05b('0x1b')](function(_0x2e82de){const _0xe02fa6=_0x13b05b;logger['info'](JSON[_0xe02fa6('0xb')](_0x2e82de));});});},Migration[_0x4e6a6f('0x1a')][_0x4e6a6f('0xe')]=function(_0x5fe59){const _0x286f6b=_0x4e6a6f,_0x191b71=this;this[_0x286f6b('0x2')]['enqueue'](function(){const _0x18635a=_0x286f6b;return _0x191b71[_0x18635a('0x17')][_0x18635a('0x7')][_0x18635a('0xe')](_0x5fe59)[_0x18635a('0x3')](function(){const _0x3270ed=_0x18635a;logger[_0x3270ed('0x0')](_0x3270ed('0x15'),_0x5fe59);})[_0x18635a('0x1b')](function(_0x59edc2){const _0x1a6602=_0x18635a;logger[_0x1a6602('0x0')](JSON[_0x1a6602('0xb')](_0x59edc2));});});},Migration[_0x4e6a6f('0x1a')]['removeColumn']=function(_0x59c591,_0x1d50a8){const _0x52db86=_0x4e6a6f,_0x2f6ab0=this;this[_0x52db86('0x2')][_0x52db86('0xd')](function(){const _0x2a6442=_0x52db86;return _0x2f6ab0[_0x2a6442('0x17')][_0x2a6442('0x4')](_0x59c591,_0x1d50a8)[_0x2a6442('0x3')](function(){const _0x3296b5=_0x2a6442;logger[_0x3296b5('0x0')]('Removed\x20column\x20%s\x20from\x20%s',_0x1d50a8,_0x59c591);})[_0x2a6442('0x1b')](function(_0x53df55){const _0x211d93=_0x2a6442;logger[_0x211d93('0x0')](util[_0x211d93('0xa')](_0x53df55,{'showHidden':![],'depth':null}));});});},Migration[_0x4e6a6f('0x1a')][_0x4e6a6f('0x14')]=function(_0x51115f,_0x1f8f4f,_0x59a5a7){const _0x191305=this;this['sequence']['enqueue'](function(){const _0x501784=a984_0x1a77;return _0x191305[_0x501784('0x17')][_0x501784('0x14')](_0x51115f,_0x1f8f4f,_0x59a5a7)[_0x501784('0x3')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x1f8f4f,_0x59a5a7,_0x51115f);})[_0x501784('0x1b')](function(_0x3b1dd0){const _0xc0ff36=_0x501784;logger['info'](util[_0xc0ff36('0xa')](_0x3b1dd0,{'showHidden':![],'depth':null}));});});},Migration[_0x4e6a6f('0x1a')]['final']=function(_0x57eac7){const _0x26a1e8=_0x4e6a6f;this[_0x26a1e8('0x2')]['enqueue'](function(){return _0x57eac7();});},module[_0x4e6a6f('0x11')]={'up':function(_0x436496){return new Promise(function(_0x3aeb7d){const _0x205d15=a984_0x1a77,_0x53073c=new Migration(_0x436496);_0x53073c[_0x205d15('0x1c')](_0x3aeb7d);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.93.js b/server/migrations/2.3.93.js index 77935e9..9d6069b 100644 --- a/server/migrations/2.3.93.js +++ b/server/migrations/2.3.93.js @@ -1 +1 @@ -const a985_0x51ce=['addIndex','enqueue','sequence','info','removeColumn','queryInterface','prototype','renameColumn','final','removeIndex\x20%s\x20%s','table\x20dropped\x20%s','addIndex\x20%s\x20%s\x20%s','dropTable','removeIndex','inspect','sequelize','then','exports','catch','Removed\x20column\x20%s\x20from\x20%s','query','changeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','tail','stringify'];(function(_0x521a0c,_0x51ce64){const _0x41b43e=function(_0x125394){while(--_0x125394){_0x521a0c['push'](_0x521a0c['shift']());}};_0x41b43e(++_0x51ce64);}(a985_0x51ce,0x6e));const a985_0x41b4=function(_0x521a0c,_0x51ce64){_0x521a0c=_0x521a0c-0x0;let _0x41b43e=a985_0x51ce[_0x521a0c];return _0x41b43e;};const _0xadc834=a985_0x41b4;'use strict';const util=require('util'),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence[_0xadc834('0x15')]['enqueue']=function(_0x125394){const _0x417e64=_0xadc834;this[_0x417e64('0xd')]=this[_0x417e64('0xd')]?this[_0x417e64('0xd')]['finally'](_0x125394):_0x125394();};const Migration=function(_0xbedc8){const _0xe854ee=_0xadc834;this[_0xe854ee('0x14')]=_0xbedc8,this[_0xe854ee('0x11')]=new Sequence();};Migration[_0xadc834('0x15')][_0xadc834('0xb')]=function(_0x5a5e8f,_0x32f991,_0x192c85){const _0x33162f=_0xadc834,_0x2d8c16=this;this[_0x33162f('0x11')][_0x33162f('0x10')](function(){const _0x4f9794=_0x33162f;return _0x2d8c16[_0x4f9794('0x14')][_0x4f9794('0xb')](_0x5a5e8f,_0x32f991,_0x192c85)['then'](function(){const _0x26c5d8=_0x4f9794;logger[_0x26c5d8('0x12')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x32f991,_0x5a5e8f);})[_0x4f9794('0x8')](function(_0x2bd50b){const _0x1dd277=_0x4f9794;logger['info'](JSON[_0x1dd277('0xe')](_0x2bd50b));});});},Migration['prototype']['addColumn']=function(_0xbd4069,_0x3d90f7,_0x119a08){const _0x314535=_0xadc834,_0x53de78=this;this[_0x314535('0x11')][_0x314535('0x10')](function(){const _0x54e5ff=_0x314535;return _0x53de78[_0x54e5ff('0x14')]['addColumn'](_0xbd4069,_0x3d90f7,_0x119a08)[_0x54e5ff('0x6')](function(){const _0x3f0963=_0x54e5ff;logger[_0x3f0963('0x12')]('Added\x20column\x20%s\x20to\x20%s',_0x3d90f7,_0xbd4069);})[_0x54e5ff('0x8')](function(_0x281078){const _0x4beb95=_0x54e5ff;logger[_0x4beb95('0x12')](JSON[_0x4beb95('0xe')](_0x281078));});});},Migration['prototype']['dropTable']=function(_0x315c87){const _0x902ef7=_0xadc834,_0x978b60=this;this[_0x902ef7('0x11')][_0x902ef7('0x10')](function(){const _0xf4471d=_0x902ef7;return _0x978b60[_0xf4471d('0x14')][_0xf4471d('0x2')](_0x315c87,{'force':!![]})[_0xf4471d('0x6')](function(){const _0xb4257c=_0xf4471d;logger[_0xb4257c('0x12')](_0xb4257c('0x0'),_0x315c87);})[_0xf4471d('0x8')](function(_0x4721a6){logger['info'](JSON['stringify'](_0x4721a6));});});},Migration[_0xadc834('0x15')]['addIndex']=function(_0x49fc6c,_0x22fbf9,_0x3792f8){const _0x20e36f=_0xadc834,_0x536ee9=this;this[_0x20e36f('0x11')][_0x20e36f('0x10')](function(){const _0x299296=_0x20e36f;return _0x536ee9[_0x299296('0x14')][_0x299296('0xf')](_0x49fc6c,_0x22fbf9,{'indexName':_0x3792f8})[_0x299296('0x6')](function(){const _0x54e464=_0x299296;logger[_0x54e464('0x12')](_0x54e464('0x1'),_0x49fc6c,_0x22fbf9['join'](','),_0x3792f8);})[_0x299296('0x8')](function(_0x51840b){const _0x2fec3a=_0x299296;logger[_0x2fec3a('0x12')](JSON['stringify'](_0x51840b));});});},Migration[_0xadc834('0x15')][_0xadc834('0x3')]=function(_0x29c0ef,_0x2a09dd){const _0x13010b=_0xadc834,_0x27cb49=this;this[_0x13010b('0x11')]['enqueue'](function(){const _0x43d514=_0x13010b;return _0x27cb49[_0x43d514('0x14')][_0x43d514('0x3')](_0x29c0ef,_0x2a09dd)['then'](function(){const _0x2d60cc=_0x43d514;logger[_0x2d60cc('0x12')](_0x2d60cc('0x18'),_0x29c0ef,_0x2a09dd);})['catch'](function(_0x15621d){const _0x4ee023=_0x43d514;logger[_0x4ee023('0x12')](JSON['stringify'](_0x15621d));});});},Migration['prototype'][_0xadc834('0xa')]=function(_0x295b54){const _0x1c600f=_0xadc834,_0x56df30=this;this[_0x1c600f('0x11')]['enqueue'](function(){const _0x2a6193=_0x1c600f;return _0x56df30[_0x2a6193('0x14')][_0x2a6193('0x5')][_0x2a6193('0xa')](_0x295b54)[_0x2a6193('0x6')](function(){logger['info']('query\x20%s',_0x295b54);})[_0x2a6193('0x8')](function(_0xe30e69){const _0x24500e=_0x2a6193;logger[_0x24500e('0x12')](JSON[_0x24500e('0xe')](_0xe30e69));});});},Migration[_0xadc834('0x15')]['removeColumn']=function(_0x16acde,_0x41ab8d){const _0x561da7=this;this['sequence']['enqueue'](function(){const _0x4d4d30=a985_0x41b4;return _0x561da7[_0x4d4d30('0x14')][_0x4d4d30('0x13')](_0x16acde,_0x41ab8d)[_0x4d4d30('0x6')](function(){const _0x46b20f=_0x4d4d30;logger['info'](_0x46b20f('0x9'),_0x41ab8d,_0x16acde);})[_0x4d4d30('0x8')](function(_0x549b5b){const _0x2d70f8=_0x4d4d30;logger['info'](util[_0x2d70f8('0x4')](_0x549b5b,{'showHidden':![],'depth':null}));});});},Migration[_0xadc834('0x15')][_0xadc834('0x16')]=function(_0x197472,_0x42c27a,_0x4581be){const _0xca2f0b=_0xadc834,_0x3994dc=this;this[_0xca2f0b('0x11')][_0xca2f0b('0x10')](function(){const _0x77b551=_0xca2f0b;return _0x3994dc[_0x77b551('0x14')][_0x77b551('0x16')](_0x197472,_0x42c27a,_0x4581be)[_0x77b551('0x6')](function(){const _0x598136=_0x77b551;logger[_0x598136('0x12')](_0x598136('0xc'),_0x42c27a,_0x4581be,_0x197472);})[_0x77b551('0x8')](function(_0x27d951){const _0x4f59de=_0x77b551;logger[_0x4f59de('0x12')](util[_0x4f59de('0x4')](_0x27d951,{'showHidden':![],'depth':null}));});});},Migration[_0xadc834('0x15')][_0xadc834('0x17')]=function(_0x472e56){const _0x1ac8b3=_0xadc834;this['sequence'][_0x1ac8b3('0x10')](function(){return _0x472e56();});},module[_0xadc834('0x7')]={'up':function(_0x1ac255){return new Promise(function(_0x479c76){const _0x5e8492=new Migration(_0x1ac255);_0x5e8492['final'](_0x479c76);});},'down':function(){}}; \ No newline at end of file +const a985_0x1c8f=['removeIndex\x20%s\x20%s','catch','sequence','addIndex\x20%s\x20%s\x20%s','query','renameColumn','addColumn','prototype','info','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','enqueue','exports','addIndex','inspect','stringify','changeColumn','final','tail','then','dropTable','removeIndex','../config/logger','Removed\x20column\x20%s\x20from\x20%s','sequelize','util','Added\x20column\x20%s\x20to\x20%s','removeColumn','finally','queryInterface','join'];(function(_0x44b420,_0x1c8f42){const _0x1adf30=function(_0x5cffe1){while(--_0x5cffe1){_0x44b420['push'](_0x44b420['shift']());}};_0x1adf30(++_0x1c8f42);}(a985_0x1c8f,0x109));const a985_0x1adf=function(_0x44b420,_0x1c8f42){_0x44b420=_0x44b420-0x0;let _0x1adf30=a985_0x1c8f[_0x44b420];return _0x1adf30;};const _0x419cf9=a985_0x1adf;'use strict';const util=require(_0x419cf9('0x1d')),logger=require(_0x419cf9('0x1a'))('migration'),Sequence=function(){};Sequence[_0x419cf9('0xc')][_0x419cf9('0xf')]=function(_0x5cffe1){const _0x441f2b=_0x419cf9;this[_0x441f2b('0x16')]=this[_0x441f2b('0x16')]?this[_0x441f2b('0x16')][_0x441f2b('0x2')](_0x5cffe1):_0x5cffe1();};const Migration=function(_0x3b448b){const _0x5d1485=_0x419cf9;this[_0x5d1485('0x3')]=_0x3b448b,this[_0x5d1485('0x7')]=new Sequence();};Migration[_0x419cf9('0xc')][_0x419cf9('0x14')]=function(_0x2a55d6,_0x3d43f9,_0x596b41){const _0xb81fcf=this;this['sequence']['enqueue'](function(){const _0x3fa236=a985_0x1adf;return _0xb81fcf[_0x3fa236('0x3')][_0x3fa236('0x14')](_0x2a55d6,_0x3d43f9,_0x596b41)['then'](function(){const _0x348f7d=_0x3fa236;logger[_0x348f7d('0xd')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x3d43f9,_0x2a55d6);})[_0x3fa236('0x6')](function(_0x241ef6){const _0x17c565=_0x3fa236;logger[_0x17c565('0xd')](JSON[_0x17c565('0x13')](_0x241ef6));});});},Migration[_0x419cf9('0xc')][_0x419cf9('0xb')]=function(_0x22a112,_0x4939e9,_0x229d05){const _0x27d835=_0x419cf9,_0x3a57b1=this;this[_0x27d835('0x7')][_0x27d835('0xf')](function(){const _0x3c3844=_0x27d835;return _0x3a57b1[_0x3c3844('0x3')][_0x3c3844('0xb')](_0x22a112,_0x4939e9,_0x229d05)[_0x3c3844('0x17')](function(){const _0x45d23b=_0x3c3844;logger[_0x45d23b('0xd')](_0x45d23b('0x0'),_0x4939e9,_0x22a112);})['catch'](function(_0x4a751a){const _0x395c32=_0x3c3844;logger[_0x395c32('0xd')](JSON['stringify'](_0x4a751a));});});},Migration[_0x419cf9('0xc')][_0x419cf9('0x18')]=function(_0x331058){const _0x53f735=_0x419cf9,_0xf7c897=this;this[_0x53f735('0x7')][_0x53f735('0xf')](function(){const _0x40f7ad=_0x53f735;return _0xf7c897[_0x40f7ad('0x3')][_0x40f7ad('0x18')](_0x331058,{'force':!![]})[_0x40f7ad('0x17')](function(){logger['info']('table\x20dropped\x20%s',_0x331058);})[_0x40f7ad('0x6')](function(_0x55c20d){const _0x394592=_0x40f7ad;logger[_0x394592('0xd')](JSON[_0x394592('0x13')](_0x55c20d));});});},Migration[_0x419cf9('0xc')][_0x419cf9('0x11')]=function(_0xa9bbfb,_0x47f106,_0x3b08fe){const _0x413b6d=_0x419cf9,_0x3c9d3e=this;this[_0x413b6d('0x7')][_0x413b6d('0xf')](function(){const _0x161233=_0x413b6d;return _0x3c9d3e[_0x161233('0x3')][_0x161233('0x11')](_0xa9bbfb,_0x47f106,{'indexName':_0x3b08fe})[_0x161233('0x17')](function(){const _0x44b972=_0x161233;logger[_0x44b972('0xd')](_0x44b972('0x8'),_0xa9bbfb,_0x47f106[_0x44b972('0x4')](','),_0x3b08fe);})[_0x161233('0x6')](function(_0x46b562){const _0x1e4376=_0x161233;logger[_0x1e4376('0xd')](JSON[_0x1e4376('0x13')](_0x46b562));});});},Migration[_0x419cf9('0xc')][_0x419cf9('0x19')]=function(_0x5382b9,_0x13702d){const _0x37c6ec=_0x419cf9,_0x55e1f4=this;this[_0x37c6ec('0x7')][_0x37c6ec('0xf')](function(){const _0x4e0960=_0x37c6ec;return _0x55e1f4[_0x4e0960('0x3')][_0x4e0960('0x19')](_0x5382b9,_0x13702d)[_0x4e0960('0x17')](function(){const _0x37b2fa=_0x4e0960;logger[_0x37b2fa('0xd')](_0x37b2fa('0x5'),_0x5382b9,_0x13702d);})[_0x4e0960('0x6')](function(_0x12d77c){const _0x443ef2=_0x4e0960;logger[_0x443ef2('0xd')](JSON['stringify'](_0x12d77c));});});},Migration[_0x419cf9('0xc')]['query']=function(_0x138e4d){const _0x492cca=this;this['sequence']['enqueue'](function(){const _0x3fd1f8=a985_0x1adf;return _0x492cca['queryInterface'][_0x3fd1f8('0x1c')][_0x3fd1f8('0x9')](_0x138e4d)['then'](function(){logger['info']('query\x20%s',_0x138e4d);})[_0x3fd1f8('0x6')](function(_0x3ed178){const _0x258187=_0x3fd1f8;logger[_0x258187('0xd')](JSON[_0x258187('0x13')](_0x3ed178));});});},Migration[_0x419cf9('0xc')][_0x419cf9('0x1')]=function(_0x1541a2,_0x14e696){const _0x18f382=_0x419cf9,_0x448c73=this;this[_0x18f382('0x7')]['enqueue'](function(){const _0x3acd97=_0x18f382;return _0x448c73['queryInterface'][_0x3acd97('0x1')](_0x1541a2,_0x14e696)[_0x3acd97('0x17')](function(){const _0x1f1090=_0x3acd97;logger[_0x1f1090('0xd')](_0x1f1090('0x1b'),_0x14e696,_0x1541a2);})[_0x3acd97('0x6')](function(_0x38b729){const _0x35f1ec=_0x3acd97;logger['info'](util[_0x35f1ec('0x12')](_0x38b729,{'showHidden':![],'depth':null}));});});},Migration[_0x419cf9('0xc')]['renameColumn']=function(_0x1ee9aa,_0x371850,_0x41cafe){const _0x53ebba=_0x419cf9,_0x5188a8=this;this['sequence'][_0x53ebba('0xf')](function(){const _0xfa9078=_0x53ebba;return _0x5188a8[_0xfa9078('0x3')][_0xfa9078('0xa')](_0x1ee9aa,_0x371850,_0x41cafe)['then'](function(){const _0x3ddc6d=_0xfa9078;logger[_0x3ddc6d('0xd')](_0x3ddc6d('0xe'),_0x371850,_0x41cafe,_0x1ee9aa);})[_0xfa9078('0x6')](function(_0x36b268){const _0x2a4ae7=_0xfa9078;logger[_0x2a4ae7('0xd')](util[_0x2a4ae7('0x12')](_0x36b268,{'showHidden':![],'depth':null}));});});},Migration[_0x419cf9('0xc')]['final']=function(_0x48ff65){const _0x36e273=_0x419cf9;this[_0x36e273('0x7')][_0x36e273('0xf')](function(){return _0x48ff65();});},module[_0x419cf9('0x10')]={'up':function(_0x554762){return new Promise(function(_0x300d3e){const _0x3aa43b=a985_0x1adf,_0x32b9e3=new Migration(_0x554762);_0x32b9e3[_0x3aa43b('0x15')](_0x300d3e);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.94.js b/server/migrations/2.3.94.js index 6a642f5..d271897 100644 --- a/server/migrations/2.3.94.js +++ b/server/migrations/2.3.94.js @@ -1 +1 @@ -const a986_0x49d1=['dropTable','removeIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','queryInterface','inspect','migration','final','sequelize','prototype','query','enqueue','removeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','info','tail','changeColumn','../config/logger','then','table\x20dropped\x20%s','join','addIndex\x20%s\x20%s\x20%s','addIndex','sequence','Removed\x20column\x20%s\x20from\x20%s','query\x20%s','exports','finally','catch','stringify','addColumn','renameColumn','removeIndex\x20%s\x20%s'];(function(_0x30b429,_0x49d1cc){const _0x5b3fe7=function(_0x329a21){while(--_0x329a21){_0x30b429['push'](_0x30b429['shift']());}};_0x5b3fe7(++_0x49d1cc);}(a986_0x49d1,0xab));const a986_0x5b3f=function(_0x30b429,_0x49d1cc){_0x30b429=_0x30b429-0x0;let _0x5b3fe7=a986_0x49d1[_0x30b429];return _0x5b3fe7;};const _0x513016=a986_0x5b3f;'use strict';const util=require('util'),logger=require(_0x513016('0x5'))(_0x513016('0x1a')),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x329a21){const _0x111a40=_0x513016;this[_0x111a40('0x3')]=this['tail']?this[_0x111a40('0x3')][_0x111a40('0xf')](_0x329a21):_0x329a21();};const Migration=function(_0x444445){const _0x5ee2f6=_0x513016;this[_0x5ee2f6('0x18')]=_0x444445,this[_0x5ee2f6('0xb')]=new Sequence();};Migration[_0x513016('0x1d')][_0x513016('0x4')]=function(_0x5daa74,_0x28be7d,_0x2506f2){const _0x547b73=_0x513016,_0x3a4a42=this;this[_0x547b73('0xb')][_0x547b73('0x1f')](function(){const _0x451962=_0x547b73;return _0x3a4a42[_0x451962('0x18')][_0x451962('0x4')](_0x5daa74,_0x28be7d,_0x2506f2)[_0x451962('0x6')](function(){const _0xe815b5=_0x451962;logger[_0xe815b5('0x2')](_0xe815b5('0x17'),_0x28be7d,_0x5daa74);})[_0x451962('0x10')](function(_0x20883c){const _0x3fb73e=_0x451962;logger[_0x3fb73e('0x2')](JSON['stringify'](_0x20883c));});});},Migration[_0x513016('0x1d')][_0x513016('0x12')]=function(_0x1f2ca1,_0x5d5ee2,_0x219043){const _0x2ceb72=this;this['sequence']['enqueue'](function(){const _0x2c21cb=a986_0x5b3f;return _0x2ceb72[_0x2c21cb('0x18')][_0x2c21cb('0x12')](_0x1f2ca1,_0x5d5ee2,_0x219043)[_0x2c21cb('0x6')](function(){const _0x38ac54=_0x2c21cb;logger[_0x38ac54('0x2')]('Added\x20column\x20%s\x20to\x20%s',_0x5d5ee2,_0x1f2ca1);})[_0x2c21cb('0x10')](function(_0x1e77b3){const _0x5057d4=_0x2c21cb;logger[_0x5057d4('0x2')](JSON['stringify'](_0x1e77b3));});});},Migration[_0x513016('0x1d')][_0x513016('0x15')]=function(_0x447be4){const _0x5ee288=_0x513016,_0x5bb5d5=this;this[_0x5ee288('0xb')][_0x5ee288('0x1f')](function(){const _0x539d5a=_0x5ee288;return _0x5bb5d5[_0x539d5a('0x18')][_0x539d5a('0x15')](_0x447be4,{'force':!![]})[_0x539d5a('0x6')](function(){const _0x317f70=_0x539d5a;logger['info'](_0x317f70('0x7'),_0x447be4);})[_0x539d5a('0x10')](function(_0x3b44a0){const _0x5b975f=_0x539d5a;logger[_0x5b975f('0x2')](JSON[_0x5b975f('0x11')](_0x3b44a0));});});},Migration['prototype'][_0x513016('0xa')]=function(_0x19c987,_0x40c0f2,_0x3c8b3d){const _0x110226=_0x513016,_0x45ecae=this;this[_0x110226('0xb')][_0x110226('0x1f')](function(){const _0x30aaad=_0x110226;return _0x45ecae[_0x30aaad('0x18')][_0x30aaad('0xa')](_0x19c987,_0x40c0f2,{'indexName':_0x3c8b3d})[_0x30aaad('0x6')](function(){const _0x1c20c3=_0x30aaad;logger[_0x1c20c3('0x2')](_0x1c20c3('0x9'),_0x19c987,_0x40c0f2[_0x1c20c3('0x8')](','),_0x3c8b3d);})['catch'](function(_0x4ea873){const _0x2ff7e8=_0x30aaad;logger[_0x2ff7e8('0x2')](JSON[_0x2ff7e8('0x11')](_0x4ea873));});});},Migration['prototype'][_0x513016('0x16')]=function(_0xfe20a7,_0x5432a2){const _0xcf2079=_0x513016,_0x2ce631=this;this[_0xcf2079('0xb')][_0xcf2079('0x1f')](function(){const _0x21131e=_0xcf2079;return _0x2ce631['queryInterface'][_0x21131e('0x16')](_0xfe20a7,_0x5432a2)[_0x21131e('0x6')](function(){const _0x167ef0=_0x21131e;logger[_0x167ef0('0x2')](_0x167ef0('0x14'),_0xfe20a7,_0x5432a2);})['catch'](function(_0x1cb155){const _0x5eaad0=_0x21131e;logger[_0x5eaad0('0x2')](JSON[_0x5eaad0('0x11')](_0x1cb155));});});},Migration['prototype'][_0x513016('0x1e')]=function(_0x48b2a7){const _0x295400=_0x513016,_0x40dce3=this;this[_0x295400('0xb')][_0x295400('0x1f')](function(){const _0x102065=_0x295400;return _0x40dce3['queryInterface'][_0x102065('0x1c')]['query'](_0x48b2a7)[_0x102065('0x6')](function(){const _0x312bdf=_0x102065;logger[_0x312bdf('0x2')](_0x312bdf('0xd'),_0x48b2a7);})['catch'](function(_0x3e638b){const _0x412b25=_0x102065;logger['info'](JSON[_0x412b25('0x11')](_0x3e638b));});});},Migration[_0x513016('0x1d')][_0x513016('0x0')]=function(_0x1aa348,_0x117bcb){const _0x4d66fe=_0x513016,_0x537c3d=this;this[_0x4d66fe('0xb')]['enqueue'](function(){const _0x1cd763=_0x4d66fe;return _0x537c3d[_0x1cd763('0x18')]['removeColumn'](_0x1aa348,_0x117bcb)['then'](function(){const _0x1a4bfc=_0x1cd763;logger['info'](_0x1a4bfc('0xc'),_0x117bcb,_0x1aa348);})[_0x1cd763('0x10')](function(_0x1c7d70){const _0x267cdd=_0x1cd763;logger[_0x267cdd('0x2')](util['inspect'](_0x1c7d70,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x513016('0x13')]=function(_0x58f4ff,_0x12bff6,_0x1d1dcd){const _0x4f9219=_0x513016,_0x56e0d0=this;this[_0x4f9219('0xb')]['enqueue'](function(){const _0x499852=_0x4f9219;return _0x56e0d0[_0x499852('0x18')]['renameColumn'](_0x58f4ff,_0x12bff6,_0x1d1dcd)['then'](function(){const _0x200b55=_0x499852;logger[_0x200b55('0x2')](_0x200b55('0x1'),_0x12bff6,_0x1d1dcd,_0x58f4ff);})[_0x499852('0x10')](function(_0x3a2386){const _0x239eaf=_0x499852;logger['info'](util[_0x239eaf('0x19')](_0x3a2386,{'showHidden':![],'depth':null}));});});},Migration[_0x513016('0x1d')][_0x513016('0x1b')]=function(_0x5012b4){const _0x4920f6=_0x513016;this[_0x4920f6('0xb')]['enqueue'](function(){return _0x5012b4();});},module[_0x513016('0xe')]={'up':function(_0x2e1189){return new Promise(function(_0x41218f){const _0x301be0=a986_0x5b3f,_0x54f27a=new Migration(_0x2e1189);_0x54f27a[_0x301be0('0x1b')](_0x41218f);});},'down':function(){}}; \ No newline at end of file +const a986_0x246f=['prototype','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex','stringify','join','addIndex\x20%s\x20%s\x20%s','addColumn','tail','renameColumn','enqueue','exports','migration','changeColumn','../config/logger','final','info','sequelize','Removed\x20column\x20%s\x20from\x20%s','catch','inspect','removeIndex','sequence','queryInterface','removeIndex\x20%s\x20%s','removeColumn','dropTable','util','table\x20dropped\x20%s','then'];(function(_0x3c8b6d,_0x246f9f){const _0x536c2d=function(_0x33522e){while(--_0x33522e){_0x3c8b6d['push'](_0x3c8b6d['shift']());}};_0x536c2d(++_0x246f9f);}(a986_0x246f,0x18f));const a986_0x536c=function(_0x3c8b6d,_0x246f9f){_0x3c8b6d=_0x3c8b6d-0x0;let _0x536c2d=a986_0x246f[_0x3c8b6d];return _0x536c2d;};const _0xfb2e62=a986_0x536c;'use strict';const util=require(_0xfb2e62('0x4')),logger=require(_0xfb2e62('0x14'))(_0xfb2e62('0x12')),Sequence=function(){};Sequence[_0xfb2e62('0x7')][_0xfb2e62('0x10')]=function(_0x33522e){const _0x237c0b=_0xfb2e62;this['tail']=this[_0x237c0b('0xe')]?this[_0x237c0b('0xe')]['finally'](_0x33522e):_0x33522e();};const Migration=function(_0x1b0b82){const _0x1faf7a=_0xfb2e62;this['queryInterface']=_0x1b0b82,this[_0x1faf7a('0x1c')]=new Sequence();};Migration['prototype'][_0xfb2e62('0x13')]=function(_0x358d59,_0x137f09,_0x59c353){const _0x105c7b=_0xfb2e62,_0x1e7575=this;this[_0x105c7b('0x1c')][_0x105c7b('0x10')](function(){const _0x4b0e04=_0x105c7b;return _0x1e7575[_0x4b0e04('0x0')][_0x4b0e04('0x13')](_0x358d59,_0x137f09,_0x59c353)[_0x4b0e04('0x6')](function(){const _0x27fb63=_0x4b0e04;logger[_0x27fb63('0x16')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x137f09,_0x358d59);})[_0x4b0e04('0x19')](function(_0x3d42dd){const _0x5f52c7=_0x4b0e04;logger[_0x5f52c7('0x16')](JSON['stringify'](_0x3d42dd));});});},Migration[_0xfb2e62('0x7')]['addColumn']=function(_0x377e6b,_0x375bcd,_0x37b90b){const _0x50d101=_0xfb2e62,_0x5045a=this;this[_0x50d101('0x1c')]['enqueue'](function(){const _0x2a81eb=_0x50d101;return _0x5045a[_0x2a81eb('0x0')][_0x2a81eb('0xd')](_0x377e6b,_0x375bcd,_0x37b90b)[_0x2a81eb('0x6')](function(){const _0x27f16a=_0x2a81eb;logger[_0x27f16a('0x16')]('Added\x20column\x20%s\x20to\x20%s',_0x375bcd,_0x377e6b);})[_0x2a81eb('0x19')](function(_0x5f100c){const _0xc2cf32=_0x2a81eb;logger[_0xc2cf32('0x16')](JSON[_0xc2cf32('0xa')](_0x5f100c));});});},Migration[_0xfb2e62('0x7')]['dropTable']=function(_0x50189c){const _0x53e609=this;this['sequence']['enqueue'](function(){const _0x4eade8=a986_0x536c;return _0x53e609['queryInterface'][_0x4eade8('0x3')](_0x50189c,{'force':!![]})[_0x4eade8('0x6')](function(){const _0x59039b=_0x4eade8;logger[_0x59039b('0x16')](_0x59039b('0x5'),_0x50189c);})[_0x4eade8('0x19')](function(_0x558290){const _0x482b7d=_0x4eade8;logger[_0x482b7d('0x16')](JSON['stringify'](_0x558290));});});},Migration['prototype'][_0xfb2e62('0x9')]=function(_0x16ccc7,_0x177086,_0x6beedb){const _0x5d04bb=_0xfb2e62,_0x39df56=this;this[_0x5d04bb('0x1c')]['enqueue'](function(){const _0xcb5841=_0x5d04bb;return _0x39df56[_0xcb5841('0x0')][_0xcb5841('0x9')](_0x16ccc7,_0x177086,{'indexName':_0x6beedb})['then'](function(){const _0x24f130=_0xcb5841;logger['info'](_0x24f130('0xc'),_0x16ccc7,_0x177086[_0x24f130('0xb')](','),_0x6beedb);})[_0xcb5841('0x19')](function(_0x337b76){const _0xdc3183=_0xcb5841;logger[_0xdc3183('0x16')](JSON[_0xdc3183('0xa')](_0x337b76));});});},Migration[_0xfb2e62('0x7')][_0xfb2e62('0x1b')]=function(_0x4ed584,_0x2e27ad){const _0x33f6a6=_0xfb2e62,_0x1f27d3=this;this['sequence'][_0x33f6a6('0x10')](function(){const _0x4873ff=_0x33f6a6;return _0x1f27d3[_0x4873ff('0x0')][_0x4873ff('0x1b')](_0x4ed584,_0x2e27ad)[_0x4873ff('0x6')](function(){const _0x5f2bb8=_0x4873ff;logger[_0x5f2bb8('0x16')](_0x5f2bb8('0x1'),_0x4ed584,_0x2e27ad);})['catch'](function(_0x56c149){const _0x21542f=_0x4873ff;logger[_0x21542f('0x16')](JSON['stringify'](_0x56c149));});});},Migration['prototype']['query']=function(_0xf1036e){const _0xc40e67=_0xfb2e62,_0x47a9c1=this;this['sequence'][_0xc40e67('0x10')](function(){const _0x5e3971=_0xc40e67;return _0x47a9c1[_0x5e3971('0x0')][_0x5e3971('0x17')]['query'](_0xf1036e)['then'](function(){const _0x52b7e9=_0x5e3971;logger[_0x52b7e9('0x16')]('query\x20%s',_0xf1036e);})[_0x5e3971('0x19')](function(_0x3ed130){const _0xca95b=_0x5e3971;logger[_0xca95b('0x16')](JSON[_0xca95b('0xa')](_0x3ed130));});});},Migration[_0xfb2e62('0x7')][_0xfb2e62('0x2')]=function(_0x35225a,_0x11b451){const _0x554a20=_0xfb2e62,_0x4fc188=this;this[_0x554a20('0x1c')][_0x554a20('0x10')](function(){const _0x2f31c6=_0x554a20;return _0x4fc188[_0x2f31c6('0x0')][_0x2f31c6('0x2')](_0x35225a,_0x11b451)[_0x2f31c6('0x6')](function(){const _0x4eb261=_0x2f31c6;logger[_0x4eb261('0x16')](_0x4eb261('0x18'),_0x11b451,_0x35225a);})['catch'](function(_0xabb686){const _0x45306d=_0x2f31c6;logger[_0x45306d('0x16')](util[_0x45306d('0x1a')](_0xabb686,{'showHidden':![],'depth':null}));});});},Migration[_0xfb2e62('0x7')][_0xfb2e62('0xf')]=function(_0x5bd343,_0x93ea4b,_0x269a40){const _0x4cd07b=_0xfb2e62,_0x29db69=this;this[_0x4cd07b('0x1c')][_0x4cd07b('0x10')](function(){const _0x2f06a5=_0x4cd07b;return _0x29db69[_0x2f06a5('0x0')]['renameColumn'](_0x5bd343,_0x93ea4b,_0x269a40)[_0x2f06a5('0x6')](function(){const _0x20d5ed=_0x2f06a5;logger['info'](_0x20d5ed('0x8'),_0x93ea4b,_0x269a40,_0x5bd343);})[_0x2f06a5('0x19')](function(_0xe687be){const _0x4129b6=_0x2f06a5;logger['info'](util[_0x4129b6('0x1a')](_0xe687be,{'showHidden':![],'depth':null}));});});},Migration[_0xfb2e62('0x7')][_0xfb2e62('0x15')]=function(_0x35b54d){const _0x534448=_0xfb2e62;this[_0x534448('0x1c')][_0x534448('0x10')](function(){return _0x35b54d();});},module[_0xfb2e62('0x11')]={'up':function(_0x442bcc){return new Promise(function(_0x373f98){const _0x24f59d=a986_0x536c,_0x281d9a=new Migration(_0x442bcc);_0x281d9a[_0x24f59d('0x15')](_0x373f98);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.95.js b/server/migrations/2.3.95.js index be20b4b..299867f 100644 --- a/server/migrations/2.3.95.js +++ b/server/migrations/2.3.95.js @@ -1 +1 @@ -const a987_0x1d5a=['enqueue','dropTable','sequence','addIndex\x20%s\x20%s\x20%s','catch','join','stringify','then','removeIndex\x20%s\x20%s','info','renameColumn','exports','prototype','changeColumn','addIndex','removeColumn','../config/logger','addColumn','finally','sequelize','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','final','Removed\x20column\x20%s\x20from\x20%s','table\x20dropped\x20%s','tail','queryInterface','inspect','migration','query\x20%s','removeIndex','query'];(function(_0x3be98c,_0x1d5a23){const _0x38ee5f=function(_0x41598c){while(--_0x41598c){_0x3be98c['push'](_0x3be98c['shift']());}};_0x38ee5f(++_0x1d5a23);}(a987_0x1d5a,0x1ef));const a987_0x38ee=function(_0x3be98c,_0x1d5a23){_0x3be98c=_0x3be98c-0x0;let _0x38ee5f=a987_0x1d5a[_0x3be98c];return _0x38ee5f;};const _0x2766b3=a987_0x38ee;'use strict';const util=require('util'),logger=require(_0x2766b3('0x11'))(_0x2766b3('0x1c')),Sequence=function(){};Sequence[_0x2766b3('0xd')][_0x2766b3('0x1')]=function(_0x41598c){const _0x18c458=_0x2766b3;this[_0x18c458('0x19')]=this['tail']?this[_0x18c458('0x19')][_0x18c458('0x13')](_0x41598c):_0x41598c();};const Migration=function(_0x13d695){const _0x34f808=_0x2766b3;this[_0x34f808('0x1a')]=_0x13d695,this[_0x34f808('0x3')]=new Sequence();};Migration[_0x2766b3('0xd')][_0x2766b3('0xe')]=function(_0x5a8fc8,_0x1cf4d9,_0x6cae33){const _0x3b6892=_0x2766b3,_0x121878=this;this[_0x3b6892('0x3')]['enqueue'](function(){const _0x380bd4=_0x3b6892;return _0x121878[_0x380bd4('0x1a')]['changeColumn'](_0x5a8fc8,_0x1cf4d9,_0x6cae33)[_0x380bd4('0x8')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x1cf4d9,_0x5a8fc8);})[_0x380bd4('0x5')](function(_0x3d4c9c){const _0x4a6f18=_0x380bd4;logger[_0x4a6f18('0xa')](JSON['stringify'](_0x3d4c9c));});});},Migration['prototype']['addColumn']=function(_0x16c9e8,_0x128f1e,_0x5c4c1e){const _0x44b50e=_0x2766b3,_0x4733dd=this;this[_0x44b50e('0x3')][_0x44b50e('0x1')](function(){const _0x5c4c12=_0x44b50e;return _0x4733dd['queryInterface'][_0x5c4c12('0x12')](_0x16c9e8,_0x128f1e,_0x5c4c1e)[_0x5c4c12('0x8')](function(){const _0x36f709=_0x5c4c12;logger[_0x36f709('0xa')]('Added\x20column\x20%s\x20to\x20%s',_0x128f1e,_0x16c9e8);})[_0x5c4c12('0x5')](function(_0x33025a){const _0x782579=_0x5c4c12;logger[_0x782579('0xa')](JSON[_0x782579('0x7')](_0x33025a));});});},Migration[_0x2766b3('0xd')][_0x2766b3('0x2')]=function(_0x2b00fd){const _0x42b86f=_0x2766b3,_0x166d9b=this;this[_0x42b86f('0x3')]['enqueue'](function(){const _0x207c87=_0x42b86f;return _0x166d9b['queryInterface'][_0x207c87('0x2')](_0x2b00fd,{'force':!![]})[_0x207c87('0x8')](function(){const _0x158cf=_0x207c87;logger[_0x158cf('0xa')](_0x158cf('0x18'),_0x2b00fd);})[_0x207c87('0x5')](function(_0x3acc56){const _0x40234b=_0x207c87;logger[_0x40234b('0xa')](JSON[_0x40234b('0x7')](_0x3acc56));});});},Migration[_0x2766b3('0xd')][_0x2766b3('0xf')]=function(_0x44891f,_0x5d3e38,_0xf96447){const _0x2a7058=_0x2766b3,_0x1e5832=this;this[_0x2a7058('0x3')][_0x2a7058('0x1')](function(){const _0x2369ba=_0x2a7058;return _0x1e5832[_0x2369ba('0x1a')]['addIndex'](_0x44891f,_0x5d3e38,{'indexName':_0xf96447})[_0x2369ba('0x8')](function(){const _0x5adb61=_0x2369ba;logger[_0x5adb61('0xa')](_0x5adb61('0x4'),_0x44891f,_0x5d3e38[_0x5adb61('0x6')](','),_0xf96447);})[_0x2369ba('0x5')](function(_0x4efc51){const _0x2dbf61=_0x2369ba;logger[_0x2dbf61('0xa')](JSON[_0x2dbf61('0x7')](_0x4efc51));});});},Migration[_0x2766b3('0xd')][_0x2766b3('0x1e')]=function(_0x5332f5,_0x44bc7b){const _0x334579=this;this['sequence']['enqueue'](function(){const _0x2e5566=a987_0x38ee;return _0x334579['queryInterface'][_0x2e5566('0x1e')](_0x5332f5,_0x44bc7b)[_0x2e5566('0x8')](function(){const _0x1cccd0=_0x2e5566;logger['info'](_0x1cccd0('0x9'),_0x5332f5,_0x44bc7b);})[_0x2e5566('0x5')](function(_0x14a50c){const _0x35cef3=_0x2e5566;logger[_0x35cef3('0xa')](JSON[_0x35cef3('0x7')](_0x14a50c));});});},Migration[_0x2766b3('0xd')][_0x2766b3('0x0')]=function(_0x558741){const _0x519374=this;this['sequence']['enqueue'](function(){const _0x1d92a3=a987_0x38ee;return _0x519374['queryInterface'][_0x1d92a3('0x14')][_0x1d92a3('0x0')](_0x558741)[_0x1d92a3('0x8')](function(){const _0x2da3e3=_0x1d92a3;logger[_0x2da3e3('0xa')](_0x2da3e3('0x1d'),_0x558741);})[_0x1d92a3('0x5')](function(_0x5b22e7){const _0x33f6fe=_0x1d92a3;logger[_0x33f6fe('0xa')](JSON[_0x33f6fe('0x7')](_0x5b22e7));});});},Migration[_0x2766b3('0xd')][_0x2766b3('0x10')]=function(_0x59a1a5,_0x191d02){const _0x1c9519=_0x2766b3,_0x40cd36=this;this[_0x1c9519('0x3')]['enqueue'](function(){const _0x147730=_0x1c9519;return _0x40cd36['queryInterface'][_0x147730('0x10')](_0x59a1a5,_0x191d02)['then'](function(){const _0x4217dc=_0x147730;logger[_0x4217dc('0xa')](_0x4217dc('0x17'),_0x191d02,_0x59a1a5);})[_0x147730('0x5')](function(_0x6f345c){const _0x4c1e2a=_0x147730;logger['info'](util[_0x4c1e2a('0x1b')](_0x6f345c,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x2766b3('0xb')]=function(_0x276f38,_0x48815b,_0xc87d49){const _0x1a4bdc=_0x2766b3,_0x8e327d=this;this['sequence'][_0x1a4bdc('0x1')](function(){const _0x465d88=_0x1a4bdc;return _0x8e327d[_0x465d88('0x1a')]['renameColumn'](_0x276f38,_0x48815b,_0xc87d49)[_0x465d88('0x8')](function(){const _0x36c800=_0x465d88;logger[_0x36c800('0xa')](_0x36c800('0x15'),_0x48815b,_0xc87d49,_0x276f38);})[_0x465d88('0x5')](function(_0x5af5a1){logger['info'](util['inspect'](_0x5af5a1,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x2766b3('0x16')]=function(_0x1d997e){const _0x1d6602=_0x2766b3;this[_0x1d6602('0x3')][_0x1d6602('0x1')](function(){return _0x1d997e();});},module[_0x2766b3('0xc')]={'up':function(_0x1bb303){return new Promise(function(_0x3a79aa){const _0x22ef4a=a987_0x38ee,_0x3c9532=new Migration(_0x1bb303);_0x3c9532[_0x22ef4a('0x16')](_0x3a79aa);});},'down':function(){}}; \ No newline at end of file +const a987_0x3078=['migration','../config/logger','queryInterface','tail','Removed\x20column\x20%s\x20from\x20%s','exports','Changed\x20column\x20%s\x20in\x20table\x20%s','then','removeIndex\x20%s\x20%s','removeIndex','sequence','query\x20%s','addIndex','query','addColumn','final','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','stringify','inspect','prototype','Added\x20column\x20%s\x20to\x20%s','dropTable','changeColumn','info','catch','enqueue','removeColumn','renameColumn','addIndex\x20%s\x20%s\x20%s'];(function(_0x29d0db,_0x307868){const _0xd6ca86=function(_0x4b7bec){while(--_0x4b7bec){_0x29d0db['push'](_0x29d0db['shift']());}};_0xd6ca86(++_0x307868);}(a987_0x3078,0x8f));const a987_0xd6ca=function(_0x29d0db,_0x307868){_0x29d0db=_0x29d0db-0x0;let _0xd6ca86=a987_0x3078[_0x29d0db];return _0xd6ca86;};const _0x1ea4d8=a987_0xd6ca;'use strict';const util=require('util'),logger=require(_0x1ea4d8('0x3'))(_0x1ea4d8('0x2')),Sequence=function(){};Sequence[_0x1ea4d8('0x15')][_0x1ea4d8('0x1b')]=function(_0x4b7bec){const _0x37b8b6=_0x1ea4d8;this[_0x37b8b6('0x5')]=this[_0x37b8b6('0x5')]?this[_0x37b8b6('0x5')]['finally'](_0x4b7bec):_0x4b7bec();};const Migration=function(_0xd2b8d1){const _0x1ce9fc=_0x1ea4d8;this['queryInterface']=_0xd2b8d1,this[_0x1ce9fc('0xc')]=new Sequence();};Migration[_0x1ea4d8('0x15')][_0x1ea4d8('0x18')]=function(_0x32b130,_0xaafed1,_0x229724){const _0x37b024=_0x1ea4d8,_0x1adf0c=this;this[_0x37b024('0xc')][_0x37b024('0x1b')](function(){const _0x2d5e76=_0x37b024;return _0x1adf0c[_0x2d5e76('0x4')][_0x2d5e76('0x18')](_0x32b130,_0xaafed1,_0x229724)[_0x2d5e76('0x9')](function(){const _0x2c539c=_0x2d5e76;logger[_0x2c539c('0x19')](_0x2c539c('0x8'),_0xaafed1,_0x32b130);})[_0x2d5e76('0x1a')](function(_0x3c7d54){const _0x5baee3=_0x2d5e76;logger[_0x5baee3('0x19')](JSON[_0x5baee3('0x13')](_0x3c7d54));});});},Migration[_0x1ea4d8('0x15')][_0x1ea4d8('0x10')]=function(_0x463484,_0x4b70ae,_0x444c6b){const _0x1c0c09=_0x1ea4d8,_0x4c0a6d=this;this[_0x1c0c09('0xc')][_0x1c0c09('0x1b')](function(){const _0x11c01d=_0x1c0c09;return _0x4c0a6d[_0x11c01d('0x4')][_0x11c01d('0x10')](_0x463484,_0x4b70ae,_0x444c6b)[_0x11c01d('0x9')](function(){const _0x2807a1=_0x11c01d;logger[_0x2807a1('0x19')](_0x2807a1('0x16'),_0x4b70ae,_0x463484);})[_0x11c01d('0x1a')](function(_0x21e836){logger['info'](JSON['stringify'](_0x21e836));});});},Migration[_0x1ea4d8('0x15')][_0x1ea4d8('0x17')]=function(_0x252f74){const _0x5125b4=_0x1ea4d8,_0x240509=this;this[_0x5125b4('0xc')][_0x5125b4('0x1b')](function(){const _0x6db605=_0x5125b4;return _0x240509[_0x6db605('0x4')][_0x6db605('0x17')](_0x252f74,{'force':!![]})[_0x6db605('0x9')](function(){const _0x2832cf=_0x6db605;logger[_0x2832cf('0x19')]('table\x20dropped\x20%s',_0x252f74);})[_0x6db605('0x1a')](function(_0x3c5efa){const _0x18e61a=_0x6db605;logger[_0x18e61a('0x19')](JSON[_0x18e61a('0x13')](_0x3c5efa));});});},Migration[_0x1ea4d8('0x15')][_0x1ea4d8('0xe')]=function(_0x55486a,_0xd021b1,_0x5ac54c){const _0x803743=_0x1ea4d8,_0x39fbcb=this;this['sequence'][_0x803743('0x1b')](function(){const _0x19b6ff=_0x803743;return _0x39fbcb[_0x19b6ff('0x4')][_0x19b6ff('0xe')](_0x55486a,_0xd021b1,{'indexName':_0x5ac54c})[_0x19b6ff('0x9')](function(){const _0x5357ae=_0x19b6ff;logger[_0x5357ae('0x19')](_0x5357ae('0x1'),_0x55486a,_0xd021b1['join'](','),_0x5ac54c);})['catch'](function(_0x85e573){const _0x170a93=_0x19b6ff;logger[_0x170a93('0x19')](JSON['stringify'](_0x85e573));});});},Migration[_0x1ea4d8('0x15')][_0x1ea4d8('0xb')]=function(_0x317dba,_0x56d153){const _0x21e2dd=_0x1ea4d8,_0x4bb942=this;this[_0x21e2dd('0xc')][_0x21e2dd('0x1b')](function(){const _0x425e1c=_0x21e2dd;return _0x4bb942[_0x425e1c('0x4')]['removeIndex'](_0x317dba,_0x56d153)[_0x425e1c('0x9')](function(){const _0x1de91d=_0x425e1c;logger[_0x1de91d('0x19')](_0x1de91d('0xa'),_0x317dba,_0x56d153);})[_0x425e1c('0x1a')](function(_0x3cfb70){const _0x919b97=_0x425e1c;logger[_0x919b97('0x19')](JSON[_0x919b97('0x13')](_0x3cfb70));});});},Migration[_0x1ea4d8('0x15')]['query']=function(_0x448288){const _0x43165a=_0x1ea4d8,_0x16a2e4=this;this[_0x43165a('0xc')][_0x43165a('0x1b')](function(){const _0x53bc51=_0x43165a;return _0x16a2e4[_0x53bc51('0x4')]['sequelize'][_0x53bc51('0xf')](_0x448288)[_0x53bc51('0x9')](function(){const _0x1dff1e=_0x53bc51;logger[_0x1dff1e('0x19')](_0x1dff1e('0xd'),_0x448288);})['catch'](function(_0x42869e){const _0x432116=_0x53bc51;logger[_0x432116('0x19')](JSON[_0x432116('0x13')](_0x42869e));});});},Migration['prototype']['removeColumn']=function(_0x2072dc,_0x2417f4){const _0x5a13de=_0x1ea4d8,_0x1d1b34=this;this['sequence'][_0x5a13de('0x1b')](function(){const _0xcdd218=_0x5a13de;return _0x1d1b34[_0xcdd218('0x4')][_0xcdd218('0x1c')](_0x2072dc,_0x2417f4)[_0xcdd218('0x9')](function(){const _0x360aa7=_0xcdd218;logger['info'](_0x360aa7('0x6'),_0x2417f4,_0x2072dc);})['catch'](function(_0x1842d5){const _0x51124c=_0xcdd218;logger[_0x51124c('0x19')](util[_0x51124c('0x14')](_0x1842d5,{'showHidden':![],'depth':null}));});});},Migration[_0x1ea4d8('0x15')][_0x1ea4d8('0x0')]=function(_0x4e527e,_0x11c514,_0x38c911){const _0x337358=_0x1ea4d8,_0x49ce24=this;this[_0x337358('0xc')]['enqueue'](function(){const _0x26c50c=_0x337358;return _0x49ce24[_0x26c50c('0x4')][_0x26c50c('0x0')](_0x4e527e,_0x11c514,_0x38c911)[_0x26c50c('0x9')](function(){const _0x59cba6=_0x26c50c;logger[_0x59cba6('0x19')](_0x59cba6('0x12'),_0x11c514,_0x38c911,_0x4e527e);})['catch'](function(_0x45cbd5){const _0x13764a=_0x26c50c;logger[_0x13764a('0x19')](util[_0x13764a('0x14')](_0x45cbd5,{'showHidden':![],'depth':null}));});});},Migration[_0x1ea4d8('0x15')][_0x1ea4d8('0x11')]=function(_0x381724){const _0x27b74b=_0x1ea4d8;this['sequence'][_0x27b74b('0x1b')](function(){return _0x381724();});},module[_0x1ea4d8('0x7')]={'up':function(_0x3a0864){return new Promise(function(_0x49c0cc){const _0x281612=a987_0xd6ca,_0x1bc194=new Migration(_0x3a0864);_0x1bc194[_0x281612('0x11')](_0x49c0cc);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.96.js b/server/migrations/2.3.96.js index 54deb01..9163c6a 100644 --- a/server/migrations/2.3.96.js +++ b/server/migrations/2.3.96.js @@ -1 +1 @@ -const a988_0x33bc=['catch','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','exports','renameColumn','migration','enqueue','removeIndex','finally','then','info','addColumn','stringify','util','addIndex','Added\x20column\x20%s\x20to\x20%s','Removed\x20column\x20%s\x20from\x20%s','queryInterface','inspect','final','settings','dropTable','sequence','table\x20dropped\x20%s','sequelize','addIndex\x20%s\x20%s\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','STRING','query','prototype','join','changeColumn','tail'];(function(_0x5cbbc7,_0x33bc61){const _0x1e7b09=function(_0x4e0173){while(--_0x4e0173){_0x5cbbc7['push'](_0x5cbbc7['shift']());}};_0x1e7b09(++_0x33bc61);}(a988_0x33bc,0x1a6));const a988_0x1e7b=function(_0x5cbbc7,_0x33bc61){_0x5cbbc7=_0x5cbbc7-0x0;let _0x1e7b09=a988_0x33bc[_0x5cbbc7];return _0x1e7b09;};const _0x48b4b4=a988_0x1e7b;'use strict';const util=require(_0x48b4b4('0x6')),logger=require('../config/logger')(_0x48b4b4('0x1e')),Sequence=function(){};Sequence[_0x48b4b4('0x16')][_0x48b4b4('0x1f')]=function(_0x4e0173){const _0x1fee5e=_0x48b4b4;this[_0x1fee5e('0x19')]=this[_0x1fee5e('0x19')]?this['tail'][_0x1fee5e('0x1')](_0x4e0173):_0x4e0173();};const Migration=function(_0x4f85cc){const _0x54491f=_0x48b4b4;this[_0x54491f('0xa')]=_0x4f85cc,this[_0x54491f('0xf')]=new Sequence();};Migration['prototype'][_0x48b4b4('0x18')]=function(_0x1a2c61,_0x5e4176,_0x241c97){const _0x1362de=_0x48b4b4,_0xa67a6a=this;this[_0x1362de('0xf')]['enqueue'](function(){const _0x22487c=_0x1362de;return _0xa67a6a[_0x22487c('0xa')][_0x22487c('0x18')](_0x1a2c61,_0x5e4176,_0x241c97)[_0x22487c('0x2')](function(){const _0x4fc203=_0x22487c;logger['info'](_0x4fc203('0x13'),_0x5e4176,_0x1a2c61);})[_0x22487c('0x1a')](function(_0x5a7a30){const _0x508f49=_0x22487c;logger[_0x508f49('0x3')](JSON[_0x508f49('0x5')](_0x5a7a30));});});},Migration['prototype']['addColumn']=function(_0x24066b,_0x3b7ed8,_0x4e9009){const _0x14f73b=_0x48b4b4,_0x5e4538=this;this[_0x14f73b('0xf')][_0x14f73b('0x1f')](function(){const _0x2e0d0d=_0x14f73b;return _0x5e4538[_0x2e0d0d('0xa')][_0x2e0d0d('0x4')](_0x24066b,_0x3b7ed8,_0x4e9009)[_0x2e0d0d('0x2')](function(){const _0x1e9f9a=_0x2e0d0d;logger['info'](_0x1e9f9a('0x8'),_0x3b7ed8,_0x24066b);})[_0x2e0d0d('0x1a')](function(_0x157e30){const _0x49b691=_0x2e0d0d;logger[_0x49b691('0x3')](JSON[_0x49b691('0x5')](_0x157e30));});});},Migration[_0x48b4b4('0x16')][_0x48b4b4('0xe')]=function(_0x1d483c){const _0x4cfe56=_0x48b4b4,_0x39e1dc=this;this[_0x4cfe56('0xf')][_0x4cfe56('0x1f')](function(){const _0x1cb552=_0x4cfe56;return _0x39e1dc[_0x1cb552('0xa')][_0x1cb552('0xe')](_0x1d483c,{'force':!![]})[_0x1cb552('0x2')](function(){const _0x4ab1db=_0x1cb552;logger['info'](_0x4ab1db('0x10'),_0x1d483c);})['catch'](function(_0x3e3bb5){const _0x110b62=_0x1cb552;logger[_0x110b62('0x3')](JSON['stringify'](_0x3e3bb5));});});},Migration[_0x48b4b4('0x16')][_0x48b4b4('0x7')]=function(_0x2bfc00,_0x14e487,_0x349892){const _0x1e5d07=this;this['sequence']['enqueue'](function(){const _0x3faa5c=a988_0x1e7b;return _0x1e5d07[_0x3faa5c('0xa')][_0x3faa5c('0x7')](_0x2bfc00,_0x14e487,{'indexName':_0x349892})[_0x3faa5c('0x2')](function(){const _0x1832c4=_0x3faa5c;logger[_0x1832c4('0x3')](_0x1832c4('0x12'),_0x2bfc00,_0x14e487[_0x1832c4('0x17')](','),_0x349892);})[_0x3faa5c('0x1a')](function(_0x41e084){const _0x37dd01=_0x3faa5c;logger[_0x37dd01('0x3')](JSON[_0x37dd01('0x5')](_0x41e084));});});},Migration[_0x48b4b4('0x16')][_0x48b4b4('0x0')]=function(_0x79958d,_0x361072){const _0x2d25b4=_0x48b4b4,_0x356f94=this;this[_0x2d25b4('0xf')]['enqueue'](function(){const _0x2ff81a=_0x2d25b4;return _0x356f94[_0x2ff81a('0xa')][_0x2ff81a('0x0')](_0x79958d,_0x361072)['then'](function(){const _0x189214=_0x2ff81a;logger[_0x189214('0x3')]('removeIndex\x20%s\x20%s',_0x79958d,_0x361072);})[_0x2ff81a('0x1a')](function(_0x41272f){const _0x40e20e=_0x2ff81a;logger[_0x40e20e('0x3')](JSON[_0x40e20e('0x5')](_0x41272f));});});},Migration[_0x48b4b4('0x16')][_0x48b4b4('0x15')]=function(_0x2ce3a7){const _0x238960=_0x48b4b4,_0xb6c048=this;this[_0x238960('0xf')][_0x238960('0x1f')](function(){const _0x5810ff=_0x238960;return _0xb6c048[_0x5810ff('0xa')][_0x5810ff('0x11')][_0x5810ff('0x15')](_0x2ce3a7)['then'](function(){logger['info']('query\x20%s',_0x2ce3a7);})[_0x5810ff('0x1a')](function(_0x4e85a2){const _0x3150fc=_0x5810ff;logger[_0x3150fc('0x3')](JSON[_0x3150fc('0x5')](_0x4e85a2));});});},Migration['prototype']['removeColumn']=function(_0x295fcd,_0x544611){const _0x2cfeae=_0x48b4b4,_0xbc8bcc=this;this[_0x2cfeae('0xf')][_0x2cfeae('0x1f')](function(){const _0xcf73d5=_0x2cfeae;return _0xbc8bcc['queryInterface']['removeColumn'](_0x295fcd,_0x544611)[_0xcf73d5('0x2')](function(){const _0xea286=_0xcf73d5;logger[_0xea286('0x3')](_0xea286('0x9'),_0x544611,_0x295fcd);})[_0xcf73d5('0x1a')](function(_0x2969c7){const _0x223d81=_0xcf73d5;logger[_0x223d81('0x3')](util[_0x223d81('0xb')](_0x2969c7,{'showHidden':![],'depth':null}));});});},Migration[_0x48b4b4('0x16')][_0x48b4b4('0x1d')]=function(_0x4f8c54,_0xb36f55,_0x51e8a1){const _0x417c38=_0x48b4b4,_0x5aad4d=this;this[_0x417c38('0xf')]['enqueue'](function(){const _0x23facf=_0x417c38;return _0x5aad4d['queryInterface'][_0x23facf('0x1d')](_0x4f8c54,_0xb36f55,_0x51e8a1)[_0x23facf('0x2')](function(){const _0x3fa1cf=_0x23facf;logger[_0x3fa1cf('0x3')](_0x3fa1cf('0x1b'),_0xb36f55,_0x51e8a1,_0x4f8c54);})[_0x23facf('0x1a')](function(_0x4032cf){const _0x46ed50=_0x23facf;logger[_0x46ed50('0x3')](util[_0x46ed50('0xb')](_0x4032cf,{'showHidden':![],'depth':null}));});});},Migration[_0x48b4b4('0x16')][_0x48b4b4('0xc')]=function(_0x3f9ba2){const _0x2a449c=_0x48b4b4;this[_0x2a449c('0xf')]['enqueue'](function(){return _0x3f9ba2();});},module[_0x48b4b4('0x1c')]={'up':function(_0x217798,_0x2f1194){return new Promise(function(_0x186682){const _0xda9941=a988_0x1e7b,_0x3c4eb0=new Migration(_0x217798);_0x3c4eb0[_0xda9941('0x4')](_0xda9941('0xd'),'defaultScreenRecordingPath',{'type':_0x2f1194[_0xda9941('0x14')]}),_0x3c4eb0['final'](_0x186682);});},'down':function(){}}; \ No newline at end of file +const a988_0x12d9=['catch','addIndex','renameColumn','defaultScreenRecordingPath','removeIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','tail','changeColumn','addColumn','util','inspect','prototype','dropTable','table\x20dropped\x20%s','info','stringify','addIndex\x20%s\x20%s\x20%s','query\x20%s','STRING','finally','then','exports','enqueue','migration','sequence','queryInterface'];(function(_0x291454,_0x12d988){const _0x5b1002=function(_0x6957a4){while(--_0x6957a4){_0x291454['push'](_0x291454['shift']());}};_0x5b1002(++_0x12d988);}(a988_0x12d9,0x105));const a988_0x5b10=function(_0x291454,_0x12d988){_0x291454=_0x291454-0x0;let _0x5b1002=a988_0x12d9[_0x291454];return _0x5b1002;};const _0x3d6225=a988_0x5b10;'use strict';const util=require(_0x3d6225('0x8')),logger=require('../config/logger')(_0x3d6225('0x16')),Sequence=function(){};Sequence[_0x3d6225('0xa')]['enqueue']=function(_0x6957a4){const _0x503abe=_0x3d6225;this[_0x503abe('0x5')]=this[_0x503abe('0x5')]?this[_0x503abe('0x5')][_0x503abe('0x12')](_0x6957a4):_0x6957a4();};const Migration=function(_0x1b1f15){const _0x1fb855=_0x3d6225;this[_0x1fb855('0x18')]=_0x1b1f15,this[_0x1fb855('0x17')]=new Sequence();};Migration[_0x3d6225('0xa')][_0x3d6225('0x6')]=function(_0x278e81,_0x2d4502,_0x68eb73){const _0x5957cf=_0x3d6225,_0x3c5b2c=this;this[_0x5957cf('0x17')]['enqueue'](function(){const _0x8463a3=_0x5957cf;return _0x3c5b2c[_0x8463a3('0x18')][_0x8463a3('0x6')](_0x278e81,_0x2d4502,_0x68eb73)[_0x8463a3('0x13')](function(){const _0x4c2ca0=_0x8463a3;logger['info'](_0x4c2ca0('0x4'),_0x2d4502,_0x278e81);})[_0x8463a3('0x19')](function(_0x34683d){const _0x44ebdb=_0x8463a3;logger['info'](JSON[_0x44ebdb('0xe')](_0x34683d));});});},Migration['prototype'][_0x3d6225('0x7')]=function(_0x40bac0,_0x3b6bde,_0x4f3576){const _0x492dca=_0x3d6225,_0x16fa87=this;this[_0x492dca('0x17')][_0x492dca('0x15')](function(){const _0x1b3917=_0x492dca;return _0x16fa87[_0x1b3917('0x18')][_0x1b3917('0x7')](_0x40bac0,_0x3b6bde,_0x4f3576)[_0x1b3917('0x13')](function(){const _0x5dc699=_0x1b3917;logger[_0x5dc699('0xd')]('Added\x20column\x20%s\x20to\x20%s',_0x3b6bde,_0x40bac0);})[_0x1b3917('0x19')](function(_0x36b8d8){const _0x5f7a3a=_0x1b3917;logger[_0x5f7a3a('0xd')](JSON['stringify'](_0x36b8d8));});});},Migration[_0x3d6225('0xa')][_0x3d6225('0xb')]=function(_0x52bd7e){const _0x4984e9=_0x3d6225,_0x107e35=this;this['sequence'][_0x4984e9('0x15')](function(){const _0x2e39e0=_0x4984e9;return _0x107e35[_0x2e39e0('0x18')][_0x2e39e0('0xb')](_0x52bd7e,{'force':!![]})[_0x2e39e0('0x13')](function(){const _0x9de9a3=_0x2e39e0;logger[_0x9de9a3('0xd')](_0x9de9a3('0xc'),_0x52bd7e);})[_0x2e39e0('0x19')](function(_0x11ea15){const _0x331481=_0x2e39e0;logger[_0x331481('0xd')](JSON['stringify'](_0x11ea15));});});},Migration['prototype'][_0x3d6225('0x0')]=function(_0x3cc760,_0x454e4d,_0xac2231){const _0x545892=this;this['sequence']['enqueue'](function(){const _0x2c0af1=a988_0x5b10;return _0x545892[_0x2c0af1('0x18')][_0x2c0af1('0x0')](_0x3cc760,_0x454e4d,{'indexName':_0xac2231})[_0x2c0af1('0x13')](function(){const _0x59dc1b=_0x2c0af1;logger[_0x59dc1b('0xd')](_0x59dc1b('0xf'),_0x3cc760,_0x454e4d['join'](','),_0xac2231);})[_0x2c0af1('0x19')](function(_0x49d54a){const _0x14c866=_0x2c0af1;logger[_0x14c866('0xd')](JSON[_0x14c866('0xe')](_0x49d54a));});});},Migration['prototype'][_0x3d6225('0x3')]=function(_0x3389b2,_0x19265d){const _0x569d1c=_0x3d6225,_0x3a46be=this;this[_0x569d1c('0x17')][_0x569d1c('0x15')](function(){const _0x4d81ad=_0x569d1c;return _0x3a46be[_0x4d81ad('0x18')][_0x4d81ad('0x3')](_0x3389b2,_0x19265d)[_0x4d81ad('0x13')](function(){const _0x5528a4=_0x4d81ad;logger[_0x5528a4('0xd')]('removeIndex\x20%s\x20%s',_0x3389b2,_0x19265d);})[_0x4d81ad('0x19')](function(_0x50f5ec){const _0x3398fe=_0x4d81ad;logger[_0x3398fe('0xd')](JSON[_0x3398fe('0xe')](_0x50f5ec));});});},Migration['prototype']['query']=function(_0x21762f){const _0x440301=_0x3d6225,_0x5470d6=this;this[_0x440301('0x17')][_0x440301('0x15')](function(){const _0x5a5ee1=_0x440301;return _0x5470d6['queryInterface']['sequelize']['query'](_0x21762f)[_0x5a5ee1('0x13')](function(){const _0xff1a7d=_0x5a5ee1;logger[_0xff1a7d('0xd')](_0xff1a7d('0x10'),_0x21762f);})[_0x5a5ee1('0x19')](function(_0xe213e8){const _0x2345b0=_0x5a5ee1;logger['info'](JSON[_0x2345b0('0xe')](_0xe213e8));});});},Migration[_0x3d6225('0xa')]['removeColumn']=function(_0x19a6cd,_0x34baf5){const _0xaf7a4f=_0x3d6225,_0x45c060=this;this['sequence'][_0xaf7a4f('0x15')](function(){const _0x4707f8=_0xaf7a4f;return _0x45c060['queryInterface']['removeColumn'](_0x19a6cd,_0x34baf5)[_0x4707f8('0x13')](function(){const _0x3d1ec3=_0x4707f8;logger[_0x3d1ec3('0xd')]('Removed\x20column\x20%s\x20from\x20%s',_0x34baf5,_0x19a6cd);})[_0x4707f8('0x19')](function(_0x3e2405){const _0x1b5082=_0x4707f8;logger['info'](util[_0x1b5082('0x9')](_0x3e2405,{'showHidden':![],'depth':null}));});});},Migration[_0x3d6225('0xa')][_0x3d6225('0x1')]=function(_0x367f62,_0x3ac7c2,_0x19c004){const _0x47349b=_0x3d6225,_0x3968e4=this;this[_0x47349b('0x17')][_0x47349b('0x15')](function(){const _0x41ce54=_0x47349b;return _0x3968e4[_0x41ce54('0x18')][_0x41ce54('0x1')](_0x367f62,_0x3ac7c2,_0x19c004)[_0x41ce54('0x13')](function(){const _0x2d9f50=_0x41ce54;logger[_0x2d9f50('0xd')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x3ac7c2,_0x19c004,_0x367f62);})[_0x41ce54('0x19')](function(_0x2759d2){const _0x4008f9=_0x41ce54;logger[_0x4008f9('0xd')](util[_0x4008f9('0x9')](_0x2759d2,{'showHidden':![],'depth':null}));});});},Migration[_0x3d6225('0xa')]['final']=function(_0x42266d){const _0x2471dc=_0x3d6225;this[_0x2471dc('0x17')][_0x2471dc('0x15')](function(){return _0x42266d();});},module[_0x3d6225('0x14')]={'up':function(_0x308746,_0x3a2de6){return new Promise(function(_0x108561){const _0x22c82c=a988_0x5b10,_0x2acd75=new Migration(_0x308746);_0x2acd75[_0x22c82c('0x7')]('settings',_0x22c82c('0x2'),{'type':_0x3a2de6[_0x22c82c('0x11')]}),_0x2acd75['final'](_0x108561);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.97.js b/server/migrations/2.3.97.js index eafaae6..83e255e 100644 --- a/server/migrations/2.3.97.js +++ b/server/migrations/2.3.97.js @@ -1 +1 @@ -const a989_0x3535=['dialPredictiveIntervalMaxThreshold','addIndex\x20%s\x20%s\x20%s','tail','prototype','query','query\x20%s','removeIndex','queryInterface','enqueue','addIndex','catch','migration','inspect','dialPredictiveIntervalMinThreshold','addColumn','final','Added\x20column\x20%s\x20to\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','table\x20dropped\x20%s','sequence','then','ALTER\x20TABLE\x20migrations\x20ADD\x20COLUMN\x20updatedAt\x20datetime\x20NOT\x20NULL\x20DEFAULT\x20CURRENT_TIMESTAMP\x20AFTER\x20createdAt','renameColumn','removeIndex\x20%s\x20%s','ALTER\x20TABLE\x20migrations\x20MODIFY\x20COLUMN\x20version\x20varchar(255)\x20NOT\x20NULL\x20UNIQUE','Removed\x20column\x20%s\x20from\x20%s','ALTER\x20TABLE\x20migrations\x20ADD\x20COLUMN\x20id\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT\x20PRIMARY\x20KEY\x20FIRST','stringify','sequelize','join','UNSIGNED','voice_queues','util','dropTable','removeColumn','info','changeColumn','INTEGER'];(function(_0x2f33a2,_0x35355a){const _0x40e441=function(_0x4ef0d2){while(--_0x4ef0d2){_0x2f33a2['push'](_0x2f33a2['shift']());}};_0x40e441(++_0x35355a);}(a989_0x3535,0x126));const a989_0x40e4=function(_0x2f33a2,_0x35355a){_0x2f33a2=_0x2f33a2-0x0;let _0x40e441=a989_0x3535[_0x2f33a2];return _0x40e441;};const _0x4ecb5f=a989_0x40e4;'use strict';const util=require(_0x4ecb5f('0x4')),logger=require('../config/logger')(_0x4ecb5f('0x15')),Sequence=function(){};Sequence[_0x4ecb5f('0xd')][_0x4ecb5f('0x12')]=function(_0x4ef0d2){const _0x1c75d1=_0x4ecb5f;this[_0x1c75d1('0xc')]=this[_0x1c75d1('0xc')]?this['tail']['finally'](_0x4ef0d2):_0x4ef0d2();};const Migration=function(_0x36e6ca){const _0x49567b=_0x4ecb5f;this[_0x49567b('0x11')]=_0x36e6ca,this['sequence']=new Sequence();};Migration[_0x4ecb5f('0xd')][_0x4ecb5f('0x8')]=function(_0xfc2d2e,_0x1b5f5a,_0x3ea070){const _0xe3e958=this;this['sequence']['enqueue'](function(){const _0x4e9ec2=a989_0x40e4;return _0xe3e958[_0x4e9ec2('0x11')][_0x4e9ec2('0x8')](_0xfc2d2e,_0x1b5f5a,_0x3ea070)[_0x4e9ec2('0x1e')](function(){const _0x2eb9c7=_0x4e9ec2;logger[_0x2eb9c7('0x7')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x1b5f5a,_0xfc2d2e);})[_0x4e9ec2('0x14')](function(_0x2a0558){const _0x1ec6f3=_0x4e9ec2;logger[_0x1ec6f3('0x7')](JSON[_0x1ec6f3('0x25')](_0x2a0558));});});},Migration[_0x4ecb5f('0xd')][_0x4ecb5f('0x18')]=function(_0x3e5e1b,_0x488324,_0x226817){const _0x34de0d=_0x4ecb5f,_0x4989f1=this;this[_0x34de0d('0x1d')]['enqueue'](function(){const _0x2aaac4=_0x34de0d;return _0x4989f1['queryInterface'][_0x2aaac4('0x18')](_0x3e5e1b,_0x488324,_0x226817)[_0x2aaac4('0x1e')](function(){const _0x3e75a8=_0x2aaac4;logger[_0x3e75a8('0x7')](_0x3e75a8('0x1a'),_0x488324,_0x3e5e1b);})['catch'](function(_0x376c62){const _0x45a69c=_0x2aaac4;logger['info'](JSON[_0x45a69c('0x25')](_0x376c62));});});},Migration[_0x4ecb5f('0xd')]['dropTable']=function(_0x5012dc){const _0x139a6e=_0x4ecb5f,_0x125d10=this;this[_0x139a6e('0x1d')]['enqueue'](function(){const _0xcd2317=_0x139a6e;return _0x125d10['queryInterface'][_0xcd2317('0x5')](_0x5012dc,{'force':!![]})['then'](function(){const _0x4a90dd=_0xcd2317;logger['info'](_0x4a90dd('0x1c'),_0x5012dc);})[_0xcd2317('0x14')](function(_0x56887a){logger['info'](JSON['stringify'](_0x56887a));});});},Migration['prototype'][_0x4ecb5f('0x13')]=function(_0x3df9b2,_0xe0a953,_0xed19fb){const _0x419082=_0x4ecb5f,_0x4624ef=this;this[_0x419082('0x1d')][_0x419082('0x12')](function(){const _0x51584c=_0x419082;return _0x4624ef['queryInterface'][_0x51584c('0x13')](_0x3df9b2,_0xe0a953,{'indexName':_0xed19fb})[_0x51584c('0x1e')](function(){const _0x3d1535=_0x51584c;logger[_0x3d1535('0x7')](_0x3d1535('0xb'),_0x3df9b2,_0xe0a953[_0x3d1535('0x1')](','),_0xed19fb);})['catch'](function(_0x2ec38f){const _0x49e43e=_0x51584c;logger['info'](JSON[_0x49e43e('0x25')](_0x2ec38f));});});},Migration['prototype'][_0x4ecb5f('0x10')]=function(_0x2736e0,_0x453f3c){const _0xadfbee=_0x4ecb5f,_0x21507d=this;this[_0xadfbee('0x1d')][_0xadfbee('0x12')](function(){const _0x20a116=_0xadfbee;return _0x21507d[_0x20a116('0x11')]['removeIndex'](_0x2736e0,_0x453f3c)[_0x20a116('0x1e')](function(){const _0x4c514c=_0x20a116;logger[_0x4c514c('0x7')](_0x4c514c('0x21'),_0x2736e0,_0x453f3c);})[_0x20a116('0x14')](function(_0xdc3405){const _0x416390=_0x20a116;logger[_0x416390('0x7')](JSON['stringify'](_0xdc3405));});});},Migration[_0x4ecb5f('0xd')][_0x4ecb5f('0xe')]=function(_0x3c4566){const _0x11c24f=_0x4ecb5f,_0x5dba93=this;this[_0x11c24f('0x1d')][_0x11c24f('0x12')](function(){const _0x58348f=_0x11c24f;return _0x5dba93[_0x58348f('0x11')][_0x58348f('0x0')]['query'](_0x3c4566)[_0x58348f('0x1e')](function(){const _0x429058=_0x58348f;logger[_0x429058('0x7')](_0x429058('0xf'),_0x3c4566);})['catch'](function(_0x240ad5){const _0x17d55b=_0x58348f;logger[_0x17d55b('0x7')](JSON[_0x17d55b('0x25')](_0x240ad5));});});},Migration[_0x4ecb5f('0xd')][_0x4ecb5f('0x6')]=function(_0x5ee671,_0x38de54){const _0x21346d=_0x4ecb5f,_0x202bc6=this;this[_0x21346d('0x1d')][_0x21346d('0x12')](function(){const _0xd8e811=_0x21346d;return _0x202bc6[_0xd8e811('0x11')][_0xd8e811('0x6')](_0x5ee671,_0x38de54)[_0xd8e811('0x1e')](function(){const _0x5574e8=_0xd8e811;logger[_0x5574e8('0x7')](_0x5574e8('0x23'),_0x38de54,_0x5ee671);})[_0xd8e811('0x14')](function(_0x56ecd8){const _0x364281=_0xd8e811;logger[_0x364281('0x7')](util[_0x364281('0x16')](_0x56ecd8,{'showHidden':![],'depth':null}));});});},Migration[_0x4ecb5f('0xd')][_0x4ecb5f('0x20')]=function(_0x3da424,_0x5b7e94,_0x44d435){const _0x5193df=_0x4ecb5f,_0x106115=this;this[_0x5193df('0x1d')][_0x5193df('0x12')](function(){const _0x3105c3=_0x5193df;return _0x106115[_0x3105c3('0x11')][_0x3105c3('0x20')](_0x3da424,_0x5b7e94,_0x44d435)[_0x3105c3('0x1e')](function(){const _0x5c45aa=_0x3105c3;logger[_0x5c45aa('0x7')](_0x5c45aa('0x1b'),_0x5b7e94,_0x44d435,_0x3da424);})[_0x3105c3('0x14')](function(_0x33325f){const _0x271c63=_0x3105c3;logger[_0x271c63('0x7')](util['inspect'](_0x33325f,{'showHidden':![],'depth':null}));});});},Migration[_0x4ecb5f('0xd')][_0x4ecb5f('0x19')]=function(_0x549f3b){const _0x1e8bfd=_0x4ecb5f;this[_0x1e8bfd('0x1d')]['enqueue'](function(){return _0x549f3b();});},module['exports']={'up':function(_0xfec043,_0x1977ad){return new Promise(function(_0x1928cc){const _0x4524a9=a989_0x40e4,_0x4c858f=new Migration(_0xfec043);_0x4c858f['addColumn'](_0x4524a9('0x3'),_0x4524a9('0xa'),{'type':_0x1977ad[_0x4524a9('0x9')](0x3)['UNSIGNED'],'defaultValue':0x14}),_0x4c858f[_0x4524a9('0x18')](_0x4524a9('0x3'),_0x4524a9('0x17'),{'type':_0x1977ad[_0x4524a9('0x9')](0x3)[_0x4524a9('0x2')],'defaultValue':0xa}),_0x4c858f[_0x4524a9('0xe')]('ALTER\x20TABLE\x20migrations\x20DROP\x20PRIMARY\x20KEY'),_0x4c858f[_0x4524a9('0xe')](_0x4524a9('0x22')),_0x4c858f['query'](_0x4524a9('0x24')),_0x4c858f[_0x4524a9('0xe')]('ALTER\x20TABLE\x20migrations\x20ADD\x20COLUMN\x20createdAt\x20datetime\x20NOT\x20NULL\x20DEFAULT\x20CURRENT_TIMESTAMP\x20AFTER\x20version'),_0x4c858f[_0x4524a9('0xe')](_0x4524a9('0x1f')),_0x4c858f[_0x4524a9('0x19')](_0x1928cc);});},'down':function(){}}; \ No newline at end of file +const a989_0x1e2c=['removeIndex','voice_queues','ALTER\x20TABLE\x20migrations\x20MODIFY\x20COLUMN\x20version\x20varchar(255)\x20NOT\x20NULL\x20UNIQUE','prototype','dialPredictiveIntervalMaxThreshold','addIndex\x20%s\x20%s\x20%s','then','query\x20%s','removeColumn','sequelize','ALTER\x20TABLE\x20migrations\x20ADD\x20COLUMN\x20updatedAt\x20datetime\x20NOT\x20NULL\x20DEFAULT\x20CURRENT_TIMESTAMP\x20AFTER\x20createdAt','changeColumn','finally','table\x20dropped\x20%s','query','sequence','info','INTEGER','queryInterface','tail','inspect','migration','ALTER\x20TABLE\x20migrations\x20ADD\x20COLUMN\x20id\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT\x20PRIMARY\x20KEY\x20FIRST','UNSIGNED','enqueue','exports','join','dialPredictiveIntervalMinThreshold','final','removeIndex\x20%s\x20%s','util','ALTER\x20TABLE\x20migrations\x20ADD\x20COLUMN\x20createdAt\x20datetime\x20NOT\x20NULL\x20DEFAULT\x20CURRENT_TIMESTAMP\x20AFTER\x20version','catch','stringify','renameColumn','addColumn','addIndex','dropTable','ALTER\x20TABLE\x20migrations\x20DROP\x20PRIMARY\x20KEY','Removed\x20column\x20%s\x20from\x20%s'];(function(_0x278c69,_0x1e2c69){const _0x5d27fb=function(_0x1ea658){while(--_0x1ea658){_0x278c69['push'](_0x278c69['shift']());}};_0x5d27fb(++_0x1e2c69);}(a989_0x1e2c,0x130));const a989_0x5d27=function(_0x278c69,_0x1e2c69){_0x278c69=_0x278c69-0x0;let _0x5d27fb=a989_0x1e2c[_0x278c69];return _0x5d27fb;};const _0x4a057b=a989_0x5d27;'use strict';const util=require(_0x4a057b('0x6')),logger=require('../config/logger')(_0x4a057b('0x25')),Sequence=function(){};Sequence[_0x4a057b('0x13')]['enqueue']=function(_0x1ea658){const _0xc7d500=_0x4a057b;this['tail']=this['tail']?this[_0xc7d500('0x23')][_0xc7d500('0x1c')](_0x1ea658):_0x1ea658();};const Migration=function(_0x538d31){this['queryInterface']=_0x538d31,this['sequence']=new Sequence();};Migration[_0x4a057b('0x13')][_0x4a057b('0x1b')]=function(_0x293ae8,_0x36c75b,_0x52e531){const _0x2cf7b6=this;this['sequence']['enqueue'](function(){const _0x563a1a=a989_0x5d27;return _0x2cf7b6['queryInterface'][_0x563a1a('0x1b')](_0x293ae8,_0x36c75b,_0x52e531)['then'](function(){const _0x48d239=_0x563a1a;logger[_0x48d239('0x20')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x36c75b,_0x293ae8);})[_0x563a1a('0x8')](function(_0x1680b1){const _0x36b759=_0x563a1a;logger[_0x36b759('0x20')](JSON['stringify'](_0x1680b1));});});},Migration[_0x4a057b('0x13')][_0x4a057b('0xb')]=function(_0x4171ab,_0x17af4e,_0x4e289b){const _0x56d8e8=_0x4a057b,_0x3c0048=this;this['sequence'][_0x56d8e8('0x0')](function(){const _0x299d6c=_0x56d8e8;return _0x3c0048[_0x299d6c('0x22')][_0x299d6c('0xb')](_0x4171ab,_0x17af4e,_0x4e289b)[_0x299d6c('0x16')](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x17af4e,_0x4171ab);})['catch'](function(_0x364678){const _0x52f15f=_0x299d6c;logger[_0x52f15f('0x20')](JSON[_0x52f15f('0x9')](_0x364678));});});},Migration['prototype'][_0x4a057b('0xd')]=function(_0x575d90){const _0x1ee317=_0x4a057b,_0xefbcdb=this;this[_0x1ee317('0x1f')][_0x1ee317('0x0')](function(){const _0x531ad7=_0x1ee317;return _0xefbcdb[_0x531ad7('0x22')][_0x531ad7('0xd')](_0x575d90,{'force':!![]})[_0x531ad7('0x16')](function(){const _0x15c925=_0x531ad7;logger[_0x15c925('0x20')](_0x15c925('0x1d'),_0x575d90);})[_0x531ad7('0x8')](function(_0x9baaf3){const _0x227027=_0x531ad7;logger['info'](JSON[_0x227027('0x9')](_0x9baaf3));});});},Migration[_0x4a057b('0x13')][_0x4a057b('0xc')]=function(_0x42655d,_0x1621d0,_0x3d90d5){const _0x48ca96=_0x4a057b,_0x3bfafb=this;this[_0x48ca96('0x1f')][_0x48ca96('0x0')](function(){const _0x2a1e5e=_0x48ca96;return _0x3bfafb[_0x2a1e5e('0x22')][_0x2a1e5e('0xc')](_0x42655d,_0x1621d0,{'indexName':_0x3d90d5})[_0x2a1e5e('0x16')](function(){const _0x2bea34=_0x2a1e5e;logger[_0x2bea34('0x20')](_0x2bea34('0x15'),_0x42655d,_0x1621d0[_0x2bea34('0x2')](','),_0x3d90d5);})[_0x2a1e5e('0x8')](function(_0x224b71){const _0x276e37=_0x2a1e5e;logger[_0x276e37('0x20')](JSON['stringify'](_0x224b71));});});},Migration[_0x4a057b('0x13')][_0x4a057b('0x10')]=function(_0x42c56c,_0x27f3c5){const _0x4bb3b4=_0x4a057b,_0x173540=this;this['sequence'][_0x4bb3b4('0x0')](function(){const _0x431757=_0x4bb3b4;return _0x173540[_0x431757('0x22')]['removeIndex'](_0x42c56c,_0x27f3c5)[_0x431757('0x16')](function(){const _0x181252=_0x431757;logger['info'](_0x181252('0x5'),_0x42c56c,_0x27f3c5);})[_0x431757('0x8')](function(_0x1b9489){const _0x2e0b26=_0x431757;logger[_0x2e0b26('0x20')](JSON[_0x2e0b26('0x9')](_0x1b9489));});});},Migration['prototype'][_0x4a057b('0x1e')]=function(_0x1240be){const _0x1087c5=_0x4a057b,_0x50628b=this;this['sequence'][_0x1087c5('0x0')](function(){const _0x3fc830=_0x1087c5;return _0x50628b['queryInterface'][_0x3fc830('0x19')][_0x3fc830('0x1e')](_0x1240be)[_0x3fc830('0x16')](function(){const _0x23af82=_0x3fc830;logger['info'](_0x23af82('0x17'),_0x1240be);})[_0x3fc830('0x8')](function(_0x1f7168){logger['info'](JSON['stringify'](_0x1f7168));});});},Migration[_0x4a057b('0x13')][_0x4a057b('0x18')]=function(_0x4a8a16,_0x168bc1){const _0xe1f6c5=_0x4a057b,_0x197fd0=this;this[_0xe1f6c5('0x1f')]['enqueue'](function(){const _0xc646e8=_0xe1f6c5;return _0x197fd0['queryInterface'][_0xc646e8('0x18')](_0x4a8a16,_0x168bc1)[_0xc646e8('0x16')](function(){const _0x1d5bc6=_0xc646e8;logger[_0x1d5bc6('0x20')](_0x1d5bc6('0xf'),_0x168bc1,_0x4a8a16);})[_0xc646e8('0x8')](function(_0xd44c4){const _0x59e8bb=_0xc646e8;logger[_0x59e8bb('0x20')](util[_0x59e8bb('0x24')](_0xd44c4,{'showHidden':![],'depth':null}));});});},Migration[_0x4a057b('0x13')][_0x4a057b('0xa')]=function(_0x334162,_0x2a642b,_0x363d7e){const _0x5fea02=_0x4a057b,_0x594f85=this;this['sequence'][_0x5fea02('0x0')](function(){const _0x4016a4=_0x5fea02;return _0x594f85[_0x4016a4('0x22')][_0x4016a4('0xa')](_0x334162,_0x2a642b,_0x363d7e)[_0x4016a4('0x16')](function(){const _0x3d70d1=_0x4016a4;logger[_0x3d70d1('0x20')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x2a642b,_0x363d7e,_0x334162);})['catch'](function(_0x47af7f){const _0x57bd0e=_0x4016a4;logger['info'](util[_0x57bd0e('0x24')](_0x47af7f,{'showHidden':![],'depth':null}));});});},Migration[_0x4a057b('0x13')][_0x4a057b('0x4')]=function(_0xae455a){const _0x409607=_0x4a057b;this[_0x409607('0x1f')]['enqueue'](function(){return _0xae455a();});},module[_0x4a057b('0x1')]={'up':function(_0x26c973,_0x33ebb0){return new Promise(function(_0x342923){const _0x11547d=a989_0x5d27,_0x3ff088=new Migration(_0x26c973);_0x3ff088[_0x11547d('0xb')](_0x11547d('0x11'),_0x11547d('0x14'),{'type':_0x33ebb0[_0x11547d('0x21')](0x3)[_0x11547d('0x27')],'defaultValue':0x14}),_0x3ff088['addColumn']('voice_queues',_0x11547d('0x3'),{'type':_0x33ebb0[_0x11547d('0x21')](0x3)[_0x11547d('0x27')],'defaultValue':0xa}),_0x3ff088[_0x11547d('0x1e')](_0x11547d('0xe')),_0x3ff088[_0x11547d('0x1e')](_0x11547d('0x12')),_0x3ff088[_0x11547d('0x1e')](_0x11547d('0x26')),_0x3ff088[_0x11547d('0x1e')](_0x11547d('0x7')),_0x3ff088[_0x11547d('0x1e')](_0x11547d('0x1a')),_0x3ff088[_0x11547d('0x4')](_0x342923);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.3.98.js b/server/migrations/2.3.98.js index 126df9d..e8bfa5d 100644 --- a/server/migrations/2.3.98.js +++ b/server/migrations/2.3.98.js @@ -1 +1 @@ -const a990_0x3688=['../config/logger','addIndex\x20%s\x20%s\x20%s','removeColumn','table\x20dropped\x20%s','removeIndex','tail','query','Removed\x20column\x20%s\x20from\x20%s','sequence','stringify','catch','util','addColumn','sequelize','info','inspect','renameColumn','changeColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','query\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','enqueue','addIndex','removeIndex\x20%s\x20%s','then','dropTable','final','join','finally','migration','prototype','queryInterface'];(function(_0x18f445,_0x368885){const _0x2cc6c4=function(_0x338f97){while(--_0x338f97){_0x18f445['push'](_0x18f445['shift']());}};_0x2cc6c4(++_0x368885);}(a990_0x3688,0x142));const a990_0x2cc6=function(_0x18f445,_0x368885){_0x18f445=_0x18f445-0x0;let _0x2cc6c4=a990_0x3688[_0x18f445];return _0x2cc6c4;};const _0x264a40=a990_0x2cc6;'use strict';const util=require(_0x264a40('0x9')),logger=require(_0x264a40('0x1e'))(_0x264a40('0x1b')),Sequence=function(){};Sequence[_0x264a40('0x1c')][_0x264a40('0x13')]=function(_0x338f97){const _0x2b4492=_0x264a40;this[_0x2b4492('0x3')]=this[_0x2b4492('0x3')]?this[_0x2b4492('0x3')][_0x2b4492('0x1a')](_0x338f97):_0x338f97();};const Migration=function(_0x245110){const _0x161247=_0x264a40;this['queryInterface']=_0x245110,this[_0x161247('0x6')]=new Sequence();};Migration[_0x264a40('0x1c')]['changeColumn']=function(_0x37a8de,_0x49696d,_0x4ff04c){const _0x1a37cd=_0x264a40,_0x43fc8c=this;this[_0x1a37cd('0x6')][_0x1a37cd('0x13')](function(){const _0x334b3b=_0x1a37cd;return _0x43fc8c[_0x334b3b('0x1d')][_0x334b3b('0xf')](_0x37a8de,_0x49696d,_0x4ff04c)[_0x334b3b('0x16')](function(){const _0xe040a0=_0x334b3b;logger['info'](_0xe040a0('0x10'),_0x49696d,_0x37a8de);})[_0x334b3b('0x8')](function(_0x5f0cb7){const _0x14c4d5=_0x334b3b;logger[_0x14c4d5('0xc')](JSON[_0x14c4d5('0x7')](_0x5f0cb7));});});},Migration[_0x264a40('0x1c')][_0x264a40('0xa')]=function(_0x179624,_0x4241e9,_0x20146f){const _0x437c40=_0x264a40,_0x4f8702=this;this[_0x437c40('0x6')]['enqueue'](function(){const _0x57ec3d=_0x437c40;return _0x4f8702[_0x57ec3d('0x1d')][_0x57ec3d('0xa')](_0x179624,_0x4241e9,_0x20146f)[_0x57ec3d('0x16')](function(){const _0xcad771=_0x57ec3d;logger[_0xcad771('0xc')]('Added\x20column\x20%s\x20to\x20%s',_0x4241e9,_0x179624);})[_0x57ec3d('0x8')](function(_0x5286c0){const _0x54a83c=_0x57ec3d;logger[_0x54a83c('0xc')](JSON['stringify'](_0x5286c0));});});},Migration[_0x264a40('0x1c')][_0x264a40('0x17')]=function(_0x22f9d1){const _0x5c058b=_0x264a40,_0x58b54c=this;this[_0x5c058b('0x6')]['enqueue'](function(){const _0x1031bc=_0x5c058b;return _0x58b54c[_0x1031bc('0x1d')][_0x1031bc('0x17')](_0x22f9d1,{'force':!![]})[_0x1031bc('0x16')](function(){const _0x1963d3=_0x1031bc;logger['info'](_0x1963d3('0x1'),_0x22f9d1);})[_0x1031bc('0x8')](function(_0x364d61){const _0x4468b5=_0x1031bc;logger[_0x4468b5('0xc')](JSON[_0x4468b5('0x7')](_0x364d61));});});},Migration['prototype'][_0x264a40('0x14')]=function(_0x8cabcd,_0x40cfe5,_0x48a2b4){const _0x5550cf=_0x264a40,_0x203765=this;this[_0x5550cf('0x6')]['enqueue'](function(){const _0x45822e=_0x5550cf;return _0x203765['queryInterface'][_0x45822e('0x14')](_0x8cabcd,_0x40cfe5,{'indexName':_0x48a2b4})['then'](function(){const _0x480d67=_0x45822e;logger['info'](_0x480d67('0x1f'),_0x8cabcd,_0x40cfe5[_0x480d67('0x19')](','),_0x48a2b4);})[_0x45822e('0x8')](function(_0x486e5e){const _0x4690bd=_0x45822e;logger['info'](JSON[_0x4690bd('0x7')](_0x486e5e));});});},Migration[_0x264a40('0x1c')][_0x264a40('0x2')]=function(_0x2b81ad,_0x1a9fd8){const _0x2eaed3=_0x264a40,_0x539350=this;this[_0x2eaed3('0x6')]['enqueue'](function(){const _0x5bd203=_0x2eaed3;return _0x539350[_0x5bd203('0x1d')][_0x5bd203('0x2')](_0x2b81ad,_0x1a9fd8)['then'](function(){const _0x3186e9=_0x5bd203;logger['info'](_0x3186e9('0x15'),_0x2b81ad,_0x1a9fd8);})[_0x5bd203('0x8')](function(_0xc7346e){const _0xff679=_0x5bd203;logger[_0xff679('0xc')](JSON['stringify'](_0xc7346e));});});},Migration[_0x264a40('0x1c')][_0x264a40('0x4')]=function(_0x35e74c){const _0x142f1c=_0x264a40,_0x407945=this;this[_0x142f1c('0x6')][_0x142f1c('0x13')](function(){const _0x57627b=_0x142f1c;return _0x407945[_0x57627b('0x1d')][_0x57627b('0xb')][_0x57627b('0x4')](_0x35e74c)['then'](function(){const _0x56902f=_0x57627b;logger[_0x56902f('0xc')](_0x56902f('0x11'),_0x35e74c);})['catch'](function(_0x566530){const _0x4001c9=_0x57627b;logger[_0x4001c9('0xc')](JSON['stringify'](_0x566530));});});},Migration[_0x264a40('0x1c')][_0x264a40('0x0')]=function(_0x16384c,_0x2a0e20){const _0x4b0cb1=_0x264a40,_0x273300=this;this[_0x4b0cb1('0x6')][_0x4b0cb1('0x13')](function(){const _0x195ae8=_0x4b0cb1;return _0x273300[_0x195ae8('0x1d')][_0x195ae8('0x0')](_0x16384c,_0x2a0e20)[_0x195ae8('0x16')](function(){const _0x2edb25=_0x195ae8;logger[_0x2edb25('0xc')](_0x2edb25('0x5'),_0x2a0e20,_0x16384c);})[_0x195ae8('0x8')](function(_0x2aaebf){const _0x4cc25f=_0x195ae8;logger[_0x4cc25f('0xc')](util[_0x4cc25f('0xd')](_0x2aaebf,{'showHidden':![],'depth':null}));});});},Migration[_0x264a40('0x1c')][_0x264a40('0xe')]=function(_0x12d7c5,_0x162ba9,_0x1c2a05){const _0x4b0da6=_0x264a40,_0x385422=this;this[_0x4b0da6('0x6')][_0x4b0da6('0x13')](function(){const _0x2832b7=_0x4b0da6;return _0x385422[_0x2832b7('0x1d')][_0x2832b7('0xe')](_0x12d7c5,_0x162ba9,_0x1c2a05)[_0x2832b7('0x16')](function(){const _0x4dec29=_0x2832b7;logger['info'](_0x4dec29('0x12'),_0x162ba9,_0x1c2a05,_0x12d7c5);})[_0x2832b7('0x8')](function(_0x3ba5d5){const _0xeb178e=_0x2832b7;logger[_0xeb178e('0xc')](util['inspect'](_0x3ba5d5,{'showHidden':![],'depth':null}));});});},Migration[_0x264a40('0x1c')][_0x264a40('0x18')]=function(_0x6a44bf){const _0x1201d5=_0x264a40;this[_0x1201d5('0x6')][_0x1201d5('0x13')](function(){return _0x6a44bf();});},module['exports']={'up':function(_0x20fd71){return new Promise(function(_0x16adce){const _0x1c22ca=a990_0x2cc6,_0x5964b8=new Migration(_0x20fd71);_0x5964b8[_0x1c22ca('0x18')](_0x16adce);});},'down':function(){}}; \ No newline at end of file +const a990_0x29e5=['util','addIndex\x20%s\x20%s\x20%s','inspect','query','Added\x20column\x20%s\x20to\x20%s','final','stringify','Changed\x20column\x20%s\x20in\x20table\x20%s','queryInterface','sequence','sequelize','enqueue','then','renameColumn','removeIndex','info','removeIndex\x20%s\x20%s','catch','prototype','addColumn','finally','dropTable','Removed\x20column\x20%s\x20from\x20%s','tail','exports','changeColumn','join','table\x20dropped\x20%s'];(function(_0x788c82,_0x29e53f){const _0x10fec4=function(_0x33b640){while(--_0x33b640){_0x788c82['push'](_0x788c82['shift']());}};_0x10fec4(++_0x29e53f);}(a990_0x29e5,0x1e1));const a990_0x10fe=function(_0x788c82,_0x29e53f){_0x788c82=_0x788c82-0x0;let _0x10fec4=a990_0x29e5[_0x788c82];return _0x10fec4;};const _0x55d3bf=a990_0x10fe;'use strict';const util=require(_0x55d3bf('0x17')),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence[_0x55d3bf('0xd')][_0x55d3bf('0x6')]=function(_0x33b640){const _0x16236a=_0x55d3bf;this[_0x16236a('0x12')]=this[_0x16236a('0x12')]?this[_0x16236a('0x12')][_0x16236a('0xf')](_0x33b640):_0x33b640();};const Migration=function(_0x25a794){const _0x408d32=_0x55d3bf;this[_0x408d32('0x3')]=_0x25a794,this[_0x408d32('0x4')]=new Sequence();};Migration[_0x55d3bf('0xd')][_0x55d3bf('0x14')]=function(_0xdbd197,_0x8679a,_0x434222){const _0x4cf31f=_0x55d3bf,_0x1e7195=this;this[_0x4cf31f('0x4')][_0x4cf31f('0x6')](function(){const _0x1c27fb=_0x4cf31f;return _0x1e7195[_0x1c27fb('0x3')][_0x1c27fb('0x14')](_0xdbd197,_0x8679a,_0x434222)[_0x1c27fb('0x7')](function(){const _0x65e469=_0x1c27fb;logger[_0x65e469('0xa')](_0x65e469('0x2'),_0x8679a,_0xdbd197);})[_0x1c27fb('0xc')](function(_0x2c9c9b){const _0x13e9c0=_0x1c27fb;logger[_0x13e9c0('0xa')](JSON['stringify'](_0x2c9c9b));});});},Migration[_0x55d3bf('0xd')]['addColumn']=function(_0x3406d0,_0x3b7d8e,_0xd5296c){const _0x666df2=_0x55d3bf,_0x3c3005=this;this[_0x666df2('0x4')][_0x666df2('0x6')](function(){const _0x50ab0c=_0x666df2;return _0x3c3005[_0x50ab0c('0x3')][_0x50ab0c('0xe')](_0x3406d0,_0x3b7d8e,_0xd5296c)[_0x50ab0c('0x7')](function(){const _0x24fe90=_0x50ab0c;logger[_0x24fe90('0xa')](_0x24fe90('0x1b'),_0x3b7d8e,_0x3406d0);})[_0x50ab0c('0xc')](function(_0x31cf56){const _0x4bdf06=_0x50ab0c;logger[_0x4bdf06('0xa')](JSON[_0x4bdf06('0x1')](_0x31cf56));});});},Migration[_0x55d3bf('0xd')][_0x55d3bf('0x10')]=function(_0x548202){const _0x4af397=_0x55d3bf,_0x1e26bb=this;this[_0x4af397('0x4')][_0x4af397('0x6')](function(){const _0x4cf9d7=_0x4af397;return _0x1e26bb[_0x4cf9d7('0x3')][_0x4cf9d7('0x10')](_0x548202,{'force':!![]})[_0x4cf9d7('0x7')](function(){const _0x37adf5=_0x4cf9d7;logger[_0x37adf5('0xa')](_0x37adf5('0x16'),_0x548202);})[_0x4cf9d7('0xc')](function(_0x585cc2){const _0x446ed7=_0x4cf9d7;logger['info'](JSON[_0x446ed7('0x1')](_0x585cc2));});});},Migration[_0x55d3bf('0xd')]['addIndex']=function(_0x6a0863,_0x28784f,_0x57ff93){const _0x289af8=this;this['sequence']['enqueue'](function(){const _0x31b040=a990_0x10fe;return _0x289af8[_0x31b040('0x3')]['addIndex'](_0x6a0863,_0x28784f,{'indexName':_0x57ff93})[_0x31b040('0x7')](function(){const _0x2b13b5=_0x31b040;logger['info'](_0x2b13b5('0x18'),_0x6a0863,_0x28784f[_0x2b13b5('0x15')](','),_0x57ff93);})[_0x31b040('0xc')](function(_0x28b99f){const _0x3c5108=_0x31b040;logger['info'](JSON[_0x3c5108('0x1')](_0x28b99f));});});},Migration[_0x55d3bf('0xd')][_0x55d3bf('0x9')]=function(_0x41a62f,_0x3bb618){const _0x189baf=_0x55d3bf,_0x5cb117=this;this[_0x189baf('0x4')][_0x189baf('0x6')](function(){const _0x57e63f=_0x189baf;return _0x5cb117[_0x57e63f('0x3')][_0x57e63f('0x9')](_0x41a62f,_0x3bb618)[_0x57e63f('0x7')](function(){const _0x2bc701=_0x57e63f;logger['info'](_0x2bc701('0xb'),_0x41a62f,_0x3bb618);})[_0x57e63f('0xc')](function(_0x1f410c){const _0x3920e6=_0x57e63f;logger[_0x3920e6('0xa')](JSON[_0x3920e6('0x1')](_0x1f410c));});});},Migration[_0x55d3bf('0xd')]['query']=function(_0x1d62ab){const _0x52478e=_0x55d3bf,_0x374727=this;this[_0x52478e('0x4')][_0x52478e('0x6')](function(){const _0x3d88da=_0x52478e;return _0x374727[_0x3d88da('0x3')][_0x3d88da('0x5')][_0x3d88da('0x1a')](_0x1d62ab)[_0x3d88da('0x7')](function(){const _0x1e0fa3=_0x3d88da;logger[_0x1e0fa3('0xa')]('query\x20%s',_0x1d62ab);})[_0x3d88da('0xc')](function(_0xc8492c){const _0x3c73e9=_0x3d88da;logger[_0x3c73e9('0xa')](JSON[_0x3c73e9('0x1')](_0xc8492c));});});},Migration[_0x55d3bf('0xd')]['removeColumn']=function(_0x3f95e8,_0x228622){const _0x3f6eec=_0x55d3bf,_0x494310=this;this[_0x3f6eec('0x4')][_0x3f6eec('0x6')](function(){const _0x306c9f=_0x3f6eec;return _0x494310[_0x306c9f('0x3')]['removeColumn'](_0x3f95e8,_0x228622)[_0x306c9f('0x7')](function(){const _0xf85ce1=_0x306c9f;logger['info'](_0xf85ce1('0x11'),_0x228622,_0x3f95e8);})[_0x306c9f('0xc')](function(_0x1ae553){const _0x2d6fb6=_0x306c9f;logger[_0x2d6fb6('0xa')](util[_0x2d6fb6('0x19')](_0x1ae553,{'showHidden':![],'depth':null}));});});},Migration[_0x55d3bf('0xd')][_0x55d3bf('0x8')]=function(_0x3a69e4,_0x118978,_0x126b44){const _0x6a0490=_0x55d3bf,_0x4765d7=this;this[_0x6a0490('0x4')][_0x6a0490('0x6')](function(){const _0x9ff861=_0x6a0490;return _0x4765d7[_0x9ff861('0x3')][_0x9ff861('0x8')](_0x3a69e4,_0x118978,_0x126b44)[_0x9ff861('0x7')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x118978,_0x126b44,_0x3a69e4);})['catch'](function(_0x58efaa){const _0x36cb4f=_0x9ff861;logger[_0x36cb4f('0xa')](util[_0x36cb4f('0x19')](_0x58efaa,{'showHidden':![],'depth':null}));});});},Migration[_0x55d3bf('0xd')][_0x55d3bf('0x0')]=function(_0xfeb220){const _0x339bd0=_0x55d3bf;this[_0x339bd0('0x4')][_0x339bd0('0x6')](function(){return _0xfeb220();});},module[_0x55d3bf('0x13')]={'up':function(_0x198512){return new Promise(function(_0x43344e){const _0x20e249=a990_0x10fe,_0x2225e3=new Migration(_0x198512);_0x2225e3[_0x20e249('0x0')](_0x43344e);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.0.js b/server/migrations/2.4.0.js index f0ed4d4..be74a60 100644 --- a/server/migrations/2.4.0.js +++ b/server/migrations/2.4.0.js @@ -1 +1 @@ -const a991_0x1606=['phoneBarEnableVideoRecording','finally','renameColumn','lastMsgText','addIndex\x20%s\x20%s\x20%s\x20[%s]','users','tail','query','sequelize','indicesType','catch','addIndex','prototype','mail_interactions','BOOLEAN','plainBody','final','FULLTEXT','util','body','query\x20%s','table\x20dropped\x20%s','stringify','queryInterface','lastMsgBody','tiny','fti_mail_messages','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','changeColumn','mail_messages','dropTable','enqueue','fti_openchannel_messages','indexName','TEXT','screenrecording','sequence','fti_sms_messages','Added\x20column\x20%s\x20to\x20%s','../config/logger','removeIndex','medium','openchannel_messages','subject','addColumn','then','inspect','ALTER\x20TABLE\x20mail_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci','ALTER\x20TABLE\x20chat_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci','Removed\x20column\x20%s\x20from\x20%s','chat_messages','sms_messages','removeColumn','ALTER\x20TABLE\x20fax_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci','join','removeIndex\x20%s\x20%s','fti_chat_messages','info'];(function(_0x34cc27,_0x160686){const _0x237bb6=function(_0x56063d){while(--_0x56063d){_0x34cc27['push'](_0x34cc27['shift']());}};_0x237bb6(++_0x160686);}(a991_0x1606,0x15e));const a991_0x237b=function(_0x34cc27,_0x160686){_0x34cc27=_0x34cc27-0x0;let _0x237bb6=a991_0x1606[_0x34cc27];return _0x237bb6;};const _0x235b4e=a991_0x237b;'use strict';const util=require(_0x235b4e('0x10')),logger=require(_0x235b4e('0x25'))('migration'),Sequence=function(){};Sequence['prototype'][_0x235b4e('0x1d')]=function(_0x56063d){const _0x59fa8d=_0x235b4e;this[_0x59fa8d('0x4')]=this[_0x59fa8d('0x4')]?this[_0x59fa8d('0x4')][_0x59fa8d('0x39')](_0x56063d):_0x56063d();};const Migration=function(_0x1fc721){const _0x1adb6f=_0x235b4e;this[_0x1adb6f('0x15')]=_0x1fc721,this[_0x1adb6f('0x22')]=new Sequence();};Migration[_0x235b4e('0xa')][_0x235b4e('0x1a')]=function(_0x1727ad,_0x585702,_0x5528ce){const _0x187309=_0x235b4e,_0x286ea4=this;this[_0x187309('0x22')][_0x187309('0x1d')](function(){const _0x302cdc=_0x187309;return _0x286ea4[_0x302cdc('0x15')][_0x302cdc('0x1a')](_0x1727ad,_0x585702,_0x5528ce)[_0x302cdc('0x2b')](function(){const _0x15b702=_0x302cdc;logger[_0x15b702('0x37')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x585702,_0x1727ad);})['catch'](function(_0x30de1e){const _0x242716=_0x302cdc;logger[_0x242716('0x37')](JSON[_0x242716('0x14')](_0x30de1e));});});},Migration['prototype']['addColumn']=function(_0x17e3df,_0x575f41,_0x90df14){const _0x30c59a=_0x235b4e,_0x387246=this;this[_0x30c59a('0x22')][_0x30c59a('0x1d')](function(){const _0x55433a=_0x30c59a;return _0x387246[_0x55433a('0x15')][_0x55433a('0x2a')](_0x17e3df,_0x575f41,_0x90df14)[_0x55433a('0x2b')](function(){const _0x5ed4e5=_0x55433a;logger['info'](_0x5ed4e5('0x24'),_0x575f41,_0x17e3df);})[_0x55433a('0x8')](function(_0x50d320){const _0x21a515=_0x55433a;logger[_0x21a515('0x37')](JSON[_0x21a515('0x14')](_0x50d320));});});},Migration[_0x235b4e('0xa')]['dropTable']=function(_0x5b8135){const _0x15ba09=_0x235b4e,_0x39031c=this;this[_0x15ba09('0x22')][_0x15ba09('0x1d')](function(){const _0x32fa8a=_0x15ba09;return _0x39031c[_0x32fa8a('0x15')][_0x32fa8a('0x1c')](_0x5b8135,{'force':!![]})[_0x32fa8a('0x2b')](function(){const _0x5710cd=_0x32fa8a;logger[_0x5710cd('0x37')](_0x5710cd('0x13'),_0x5b8135);})[_0x32fa8a('0x8')](function(_0x1255e8){logger['info'](JSON['stringify'](_0x1255e8));});});},Migration[_0x235b4e('0xa')][_0x235b4e('0x9')]=function(_0x229111,_0x48356a,_0x4844cc){const _0x3b3db2=_0x235b4e,_0x490e4a=this;this[_0x3b3db2('0x22')][_0x3b3db2('0x1d')](function(){const _0x196387=_0x3b3db2;return _0x490e4a[_0x196387('0x15')][_0x196387('0x9')](_0x229111,_0x48356a,{'indexName':_0x4844cc[_0x196387('0x1f')],'indicesType':_0x4844cc[_0x196387('0x7')]})[_0x196387('0x2b')](function(){const _0x3279e4=_0x196387;logger[_0x3279e4('0x37')](_0x3279e4('0x2'),_0x229111,_0x48356a[_0x3279e4('0x34')](','),_0x4844cc['indexName'],_0x4844cc[_0x3279e4('0x7')]);})['catch'](function(_0x19f374){const _0x1541bb=_0x196387;logger[_0x1541bb('0x37')](JSON[_0x1541bb('0x14')](_0x19f374));});});},Migration[_0x235b4e('0xa')][_0x235b4e('0x26')]=function(_0x293fe5,_0xf47e72){const _0x57f825=_0x235b4e,_0x4df43d=this;this[_0x57f825('0x22')]['enqueue'](function(){const _0x263276=_0x57f825;return _0x4df43d['queryInterface'][_0x263276('0x26')](_0x293fe5,_0xf47e72)[_0x263276('0x2b')](function(){const _0x3815f3=_0x263276;logger['info'](_0x3815f3('0x35'),_0x293fe5,_0xf47e72);})[_0x263276('0x8')](function(_0x4f888b){const _0x11a156=_0x263276;logger[_0x11a156('0x37')](JSON['stringify'](_0x4f888b));});});},Migration['prototype'][_0x235b4e('0x5')]=function(_0x43f28e){const _0x1ca819=_0x235b4e,_0x40c7ec=this;this['sequence'][_0x1ca819('0x1d')](function(){const _0x28d48c=_0x1ca819;return _0x40c7ec[_0x28d48c('0x15')][_0x28d48c('0x6')][_0x28d48c('0x5')](_0x43f28e)['then'](function(){const _0x244c4f=_0x28d48c;logger[_0x244c4f('0x37')](_0x244c4f('0x12'),_0x43f28e);})[_0x28d48c('0x8')](function(_0x215ace){const _0x1b05ea=_0x28d48c;logger[_0x1b05ea('0x37')](JSON[_0x1b05ea('0x14')](_0x215ace));});});},Migration[_0x235b4e('0xa')][_0x235b4e('0x32')]=function(_0x3db963,_0x2fc913){const _0x4b1532=_0x235b4e,_0xb9bfd0=this;this[_0x4b1532('0x22')]['enqueue'](function(){const _0xbd1d6a=_0x4b1532;return _0xb9bfd0[_0xbd1d6a('0x15')][_0xbd1d6a('0x32')](_0x3db963,_0x2fc913)[_0xbd1d6a('0x2b')](function(){const _0x2de404=_0xbd1d6a;logger[_0x2de404('0x37')](_0x2de404('0x2f'),_0x2fc913,_0x3db963);})[_0xbd1d6a('0x8')](function(_0x53c6bb){const _0x22ce66=_0xbd1d6a;logger[_0x22ce66('0x37')](util['inspect'](_0x53c6bb,{'showHidden':![],'depth':null}));});});},Migration[_0x235b4e('0xa')][_0x235b4e('0x0')]=function(_0x499122,_0x4138c7,_0x55f1af){const _0x588aa8=_0x235b4e,_0x5a663b=this;this[_0x588aa8('0x22')][_0x588aa8('0x1d')](function(){const _0x539370=_0x588aa8;return _0x5a663b['queryInterface'][_0x539370('0x0')](_0x499122,_0x4138c7,_0x55f1af)[_0x539370('0x2b')](function(){const _0x16765d=_0x539370;logger[_0x16765d('0x37')](_0x16765d('0x19'),_0x4138c7,_0x55f1af,_0x499122);})['catch'](function(_0x49f2ba){const _0x579c75=_0x539370;logger['info'](util[_0x579c75('0x2c')](_0x49f2ba,{'showHidden':![],'depth':null}));});});},Migration[_0x235b4e('0xa')][_0x235b4e('0xe')]=function(_0x20d6bc){const _0x2d7b5b=_0x235b4e;this[_0x2d7b5b('0x22')][_0x2d7b5b('0x1d')](function(){return _0x20d6bc();});},module['exports']={'up':function(_0x20aff0,_0x51c614){return new Promise(function(_0x52e4aa){const _0x4fe31b=a991_0x237b,_0x5e9604=new Migration(_0x20aff0);_0x5e9604[_0x4fe31b('0x0')](_0x4fe31b('0x3'),_0x4fe31b('0x38'),'phoneBarEnableScreenRecordingByAgent'),_0x5e9604[_0x4fe31b('0x2a')](_0x4fe31b('0x3'),'phoneBarEnableAutomaticScreenRecording',{'type':_0x51c614[_0x4fe31b('0xc')],'defaultValue':![]}),_0x5e9604[_0x4fe31b('0x2a')]('users',_0x4fe31b('0x21'),{'type':_0x51c614[_0x4fe31b('0xc')],'defaultValue':![]}),_0x5e9604[_0x4fe31b('0x9')](_0x4fe31b('0x30'),[_0x4fe31b('0x11')],{'indexName':_0x4fe31b('0x36'),'indicesType':_0x4fe31b('0xf')}),_0x5e9604[_0x4fe31b('0x9')](_0x4fe31b('0xb'),[_0x4fe31b('0x29'),'to'],{'indexName':'fti_mail_interactions','indicesType':_0x4fe31b('0xf')}),_0x5e9604[_0x4fe31b('0x2a')](_0x4fe31b('0xb'),_0x4fe31b('0x1'),{'type':_0x51c614[_0x4fe31b('0x20')](_0x4fe31b('0x17')),'after':_0x4fe31b('0x16')}),_0x5e9604[_0x4fe31b('0x2a')](_0x4fe31b('0x1b'),_0x4fe31b('0xd'),{'type':_0x51c614[_0x4fe31b('0x20')](_0x4fe31b('0x27')),'after':_0x4fe31b('0x11')}),_0x5e9604[_0x4fe31b('0x9')]('mail_messages',[_0x4fe31b('0xd'),_0x4fe31b('0x29')],{'indexName':_0x4fe31b('0x18'),'indicesType':_0x4fe31b('0xf')}),_0x5e9604[_0x4fe31b('0x9')](_0x4fe31b('0x28'),['body'],{'indexName':_0x4fe31b('0x1e'),'indicesType':_0x4fe31b('0xf')}),_0x5e9604[_0x4fe31b('0x9')](_0x4fe31b('0x31'),[_0x4fe31b('0x11')],{'indexName':_0x4fe31b('0x23'),'indicesType':_0x4fe31b('0xf')}),_0x5e9604[_0x4fe31b('0x5')](_0x4fe31b('0x2e')),_0x5e9604[_0x4fe31b('0x5')](_0x4fe31b('0x33')),_0x5e9604[_0x4fe31b('0x5')](_0x4fe31b('0x2d')),_0x5e9604[_0x4fe31b('0x5')]('ALTER\x20TABLE\x20openchannel_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci'),_0x5e9604[_0x4fe31b('0x5')]('ALTER\x20TABLE\x20sms_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci'),_0x5e9604[_0x4fe31b('0xe')](_0x52e4aa);});},'down':function(){}}; \ No newline at end of file +const a991_0x12bf=['info','fti_openchannel_messages','ALTER\x20TABLE\x20chat_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci','then','phoneBarEnableVideoRecording','sms_messages','tiny','BOOLEAN','screenrecording','sequence','final','ALTER\x20TABLE\x20fax_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci','catch','removeIndex\x20%s\x20%s','migration','table\x20dropped\x20%s','lastMsgBody','lastMsgText','changeColumn','ALTER\x20TABLE\x20mail_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci','query\x20%s','join','exports','fti_mail_messages','Removed\x20column\x20%s\x20from\x20%s','indexName','prototype','stringify','FULLTEXT','addIndex\x20%s\x20%s\x20%s\x20[%s]','query','finally','users','mail_messages','fti_chat_messages','dropTable','fti_mail_interactions','removeColumn','renameColumn','body','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addColumn','queryInterface','openchannel_messages','phoneBarEnableScreenRecordingByAgent','inspect','phoneBarEnableAutomaticScreenRecording','subject','addIndex','plainBody','mail_interactions','Changed\x20column\x20%s\x20in\x20table\x20%s','TEXT','tail','ALTER\x20TABLE\x20sms_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci','enqueue'];(function(_0x313331,_0x12bfb0){const _0x59cac0=function(_0x599c95){while(--_0x599c95){_0x313331['push'](_0x313331['shift']());}};_0x59cac0(++_0x12bfb0);}(a991_0x12bf,0x11e));const a991_0x59ca=function(_0x313331,_0x12bfb0){_0x313331=_0x313331-0x0;let _0x59cac0=a991_0x12bf[_0x313331];return _0x59cac0;};const _0x30242a=a991_0x59ca;'use strict';const util=require('util'),logger=require('../config/logger')(_0x30242a('0x8')),Sequence=function(){};Sequence[_0x30242a('0x14')][_0x30242a('0x31')]=function(_0x599c95){const _0x20580e=_0x30242a;this[_0x20580e('0x2f')]=this[_0x20580e('0x2f')]?this[_0x20580e('0x2f')][_0x20580e('0x19')](_0x599c95):_0x599c95();};const Migration=function(_0x5015bc){const _0x160701=_0x30242a;this[_0x160701('0x24')]=_0x5015bc,this[_0x160701('0x3')]=new Sequence();};Migration[_0x30242a('0x14')]['changeColumn']=function(_0x2da5cd,_0x1b7b0a,_0x44f233){const _0x3018eb=_0x30242a,_0xb9a684=this;this[_0x3018eb('0x3')][_0x3018eb('0x31')](function(){const _0x675380=_0x3018eb;return _0xb9a684['queryInterface'][_0x675380('0xc')](_0x2da5cd,_0x1b7b0a,_0x44f233)[_0x675380('0x35')](function(){const _0x7a741c=_0x675380;logger[_0x7a741c('0x32')](_0x7a741c('0x2d'),_0x1b7b0a,_0x2da5cd);})[_0x675380('0x6')](function(_0x53b723){const _0x5a5bb0=_0x675380;logger[_0x5a5bb0('0x32')](JSON[_0x5a5bb0('0x15')](_0x53b723));});});},Migration['prototype'][_0x30242a('0x23')]=function(_0x5514f4,_0x2e51c2,_0x5c2562){const _0x19f6ad=_0x30242a,_0x3bbc6b=this;this[_0x19f6ad('0x3')]['enqueue'](function(){const _0x4f3b63=_0x19f6ad;return _0x3bbc6b['queryInterface'][_0x4f3b63('0x23')](_0x5514f4,_0x2e51c2,_0x5c2562)[_0x4f3b63('0x35')](function(){const _0x41f56f=_0x4f3b63;logger[_0x41f56f('0x32')]('Added\x20column\x20%s\x20to\x20%s',_0x2e51c2,_0x5514f4);})[_0x4f3b63('0x6')](function(_0x3447d4){const _0x227aad=_0x4f3b63;logger[_0x227aad('0x32')](JSON[_0x227aad('0x15')](_0x3447d4));});});},Migration[_0x30242a('0x14')]['dropTable']=function(_0x2ef51a){const _0x393974=_0x30242a,_0xf56a2a=this;this[_0x393974('0x3')][_0x393974('0x31')](function(){const _0x101783=_0x393974;return _0xf56a2a[_0x101783('0x24')][_0x101783('0x1d')](_0x2ef51a,{'force':!![]})['then'](function(){const _0x42456d=_0x101783;logger[_0x42456d('0x32')](_0x42456d('0x9'),_0x2ef51a);})[_0x101783('0x6')](function(_0x4f3044){const _0x5e6287=_0x101783;logger['info'](JSON[_0x5e6287('0x15')](_0x4f3044));});});},Migration['prototype'][_0x30242a('0x2a')]=function(_0x27692d,_0x3f9836,_0x448cea){const _0x4d0ecb=_0x30242a,_0x254621=this;this[_0x4d0ecb('0x3')][_0x4d0ecb('0x31')](function(){const _0x203ed0=_0x4d0ecb;return _0x254621[_0x203ed0('0x24')][_0x203ed0('0x2a')](_0x27692d,_0x3f9836,{'indexName':_0x448cea[_0x203ed0('0x13')],'indicesType':_0x448cea['indicesType']})['then'](function(){const _0x58c4a2=_0x203ed0;logger[_0x58c4a2('0x32')](_0x58c4a2('0x17'),_0x27692d,_0x3f9836[_0x58c4a2('0xf')](','),_0x448cea[_0x58c4a2('0x13')],_0x448cea['indicesType']);})[_0x203ed0('0x6')](function(_0x12f15b){const _0x11994e=_0x203ed0;logger[_0x11994e('0x32')](JSON[_0x11994e('0x15')](_0x12f15b));});});},Migration[_0x30242a('0x14')]['removeIndex']=function(_0x544b78,_0x5d8479){const _0x13ee3b=_0x30242a,_0x18c470=this;this['sequence'][_0x13ee3b('0x31')](function(){const _0x147a69=_0x13ee3b;return _0x18c470['queryInterface']['removeIndex'](_0x544b78,_0x5d8479)['then'](function(){const _0xb97992=a991_0x59ca;logger['info'](_0xb97992('0x7'),_0x544b78,_0x5d8479);})[_0x147a69('0x6')](function(_0x5e069a){const _0x42ce82=_0x147a69;logger[_0x42ce82('0x32')](JSON[_0x42ce82('0x15')](_0x5e069a));});});},Migration[_0x30242a('0x14')][_0x30242a('0x18')]=function(_0x2a8318){const _0x10ef62=_0x30242a,_0x924fe3=this;this['sequence'][_0x10ef62('0x31')](function(){const _0x2a1efb=_0x10ef62;return _0x924fe3[_0x2a1efb('0x24')]['sequelize']['query'](_0x2a8318)['then'](function(){const _0x15c0f9=_0x2a1efb;logger[_0x15c0f9('0x32')](_0x15c0f9('0xe'),_0x2a8318);})[_0x2a1efb('0x6')](function(_0x1df30f){const _0x4f375f=_0x2a1efb;logger[_0x4f375f('0x32')](JSON[_0x4f375f('0x15')](_0x1df30f));});});},Migration[_0x30242a('0x14')]['removeColumn']=function(_0x204a6c,_0x255973){const _0x8cc4c2=_0x30242a,_0x30dc2c=this;this[_0x8cc4c2('0x3')][_0x8cc4c2('0x31')](function(){const _0x4207fe=_0x8cc4c2;return _0x30dc2c[_0x4207fe('0x24')][_0x4207fe('0x1f')](_0x204a6c,_0x255973)[_0x4207fe('0x35')](function(){const _0x527ea3=_0x4207fe;logger[_0x527ea3('0x32')](_0x527ea3('0x12'),_0x255973,_0x204a6c);})['catch'](function(_0xba8503){const _0xda7cde=_0x4207fe;logger[_0xda7cde('0x32')](util[_0xda7cde('0x27')](_0xba8503,{'showHidden':![],'depth':null}));});});},Migration[_0x30242a('0x14')][_0x30242a('0x20')]=function(_0x19bc13,_0x34d445,_0x178f71){const _0x646a56=_0x30242a,_0x14ec8b=this;this['sequence'][_0x646a56('0x31')](function(){const _0x30c8d3=_0x646a56;return _0x14ec8b['queryInterface'][_0x30c8d3('0x20')](_0x19bc13,_0x34d445,_0x178f71)[_0x30c8d3('0x35')](function(){const _0x52dc2f=_0x30c8d3;logger[_0x52dc2f('0x32')](_0x52dc2f('0x22'),_0x34d445,_0x178f71,_0x19bc13);})['catch'](function(_0x342486){const _0x5771da=_0x30c8d3;logger[_0x5771da('0x32')](util[_0x5771da('0x27')](_0x342486,{'showHidden':![],'depth':null}));});});},Migration[_0x30242a('0x14')]['final']=function(_0x32040e){this['sequence']['enqueue'](function(){return _0x32040e();});},module[_0x30242a('0x10')]={'up':function(_0x220e0d,_0x4a506d){return new Promise(function(_0x43c9ab){const _0x1d5525=a991_0x59ca,_0x3e7ae3=new Migration(_0x220e0d);_0x3e7ae3[_0x1d5525('0x20')]('users',_0x1d5525('0x36'),_0x1d5525('0x26')),_0x3e7ae3['addColumn'](_0x1d5525('0x1a'),_0x1d5525('0x28'),{'type':_0x4a506d[_0x1d5525('0x1')],'defaultValue':![]}),_0x3e7ae3['addColumn']('users',_0x1d5525('0x2'),{'type':_0x4a506d[_0x1d5525('0x1')],'defaultValue':![]}),_0x3e7ae3[_0x1d5525('0x2a')]('chat_messages',[_0x1d5525('0x21')],{'indexName':_0x1d5525('0x1c'),'indicesType':_0x1d5525('0x16')}),_0x3e7ae3[_0x1d5525('0x2a')]('mail_interactions',[_0x1d5525('0x29'),'to'],{'indexName':_0x1d5525('0x1e'),'indicesType':'FULLTEXT'}),_0x3e7ae3[_0x1d5525('0x23')](_0x1d5525('0x2c'),_0x1d5525('0xb'),{'type':_0x4a506d[_0x1d5525('0x2e')](_0x1d5525('0x0')),'after':_0x1d5525('0xa')}),_0x3e7ae3[_0x1d5525('0x23')](_0x1d5525('0x1b'),'plainBody',{'type':_0x4a506d['TEXT']('medium'),'after':'body'}),_0x3e7ae3[_0x1d5525('0x2a')](_0x1d5525('0x1b'),[_0x1d5525('0x2b'),'subject'],{'indexName':_0x1d5525('0x11'),'indicesType':'FULLTEXT'}),_0x3e7ae3[_0x1d5525('0x2a')](_0x1d5525('0x25'),[_0x1d5525('0x21')],{'indexName':_0x1d5525('0x33'),'indicesType':_0x1d5525('0x16')}),_0x3e7ae3['addIndex'](_0x1d5525('0x37'),[_0x1d5525('0x21')],{'indexName':'fti_sms_messages','indicesType':_0x1d5525('0x16')}),_0x3e7ae3[_0x1d5525('0x18')](_0x1d5525('0x34')),_0x3e7ae3['query'](_0x1d5525('0x5')),_0x3e7ae3[_0x1d5525('0x18')](_0x1d5525('0xd')),_0x3e7ae3['query']('ALTER\x20TABLE\x20openchannel_applications\x20CONVERT\x20TO\x20CHARACTER\x20SET\x20utf8mb4\x20COLLATE\x20utf8mb4_unicode_ci'),_0x3e7ae3[_0x1d5525('0x18')](_0x1d5525('0x30')),_0x3e7ae3[_0x1d5525('0x4')](_0x43c9ab);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.1.js b/server/migrations/2.4.1.js index b07d577..7e167a9 100644 --- a/server/migrations/2.4.1.js +++ b/server/migrations/2.4.1.js @@ -1 +1 @@ -const a992_0x23b3=['final','query\x20%s','removeColumn','removeIndex\x20%s\x20%s','enqueue','util','inspect','tail','query','info','addIndex','join','removeIndex','queryInterface','changeColumn','addIndex\x20%s\x20%s\x20%s\x20[%s]','sequence','Removed\x20column\x20%s\x20from\x20%s','sequelize','exports','indicesType','migration','catch','indexName','../config/logger','prototype','addColumn','finally','renameColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','then','stringify'];(function(_0x44d225,_0x23b305){const _0x3ad212=function(_0x343cf2){while(--_0x343cf2){_0x44d225['push'](_0x44d225['shift']());}};_0x3ad212(++_0x23b305);}(a992_0x23b3,0x155));const a992_0x3ad2=function(_0x44d225,_0x23b305){_0x44d225=_0x44d225-0x0;let _0x3ad212=a992_0x23b3[_0x44d225];return _0x3ad212;};const _0x5abca8=a992_0x3ad2;'use strict';const util=require(_0x5abca8('0x10')),logger=require(_0x5abca8('0x3'))(_0x5abca8('0x0')),Sequence=function(){};Sequence[_0x5abca8('0x4')][_0x5abca8('0xf')]=function(_0x343cf2){const _0x2b95ed=_0x5abca8;this[_0x2b95ed('0x12')]=this[_0x2b95ed('0x12')]?this['tail'][_0x2b95ed('0x6')](_0x343cf2):_0x343cf2();};const Migration=function(_0x162112){const _0x2b9e0d=_0x5abca8;this[_0x2b9e0d('0x18')]=_0x162112,this[_0x2b9e0d('0x1b')]=new Sequence();};Migration[_0x5abca8('0x4')][_0x5abca8('0x19')]=function(_0x5e4571,_0x4c4a1a,_0x40f038){const _0x15da55=_0x5abca8,_0x5154fa=this;this[_0x15da55('0x1b')]['enqueue'](function(){const _0x4cff86=_0x15da55;return _0x5154fa[_0x4cff86('0x18')][_0x4cff86('0x19')](_0x5e4571,_0x4c4a1a,_0x40f038)['then'](function(){const _0x53ec92=_0x4cff86;logger[_0x53ec92('0x14')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x4c4a1a,_0x5e4571);})['catch'](function(_0x34955e){const _0x1f7a98=_0x4cff86;logger[_0x1f7a98('0x14')](JSON['stringify'](_0x34955e));});});},Migration['prototype'][_0x5abca8('0x5')]=function(_0x5826e3,_0x2fa1c8,_0x55ac96){const _0x1c17bd=_0x5abca8,_0x362bbe=this;this['sequence'][_0x1c17bd('0xf')](function(){const _0x2fa2af=_0x1c17bd;return _0x362bbe[_0x2fa2af('0x18')][_0x2fa2af('0x5')](_0x5826e3,_0x2fa1c8,_0x55ac96)[_0x2fa2af('0x9')](function(){const _0x380a14=_0x2fa2af;logger[_0x380a14('0x14')]('Added\x20column\x20%s\x20to\x20%s',_0x2fa1c8,_0x5826e3);})[_0x2fa2af('0x1')](function(_0x4e82bc){const _0x5ed48d=_0x2fa2af;logger[_0x5ed48d('0x14')](JSON[_0x5ed48d('0xa')](_0x4e82bc));});});},Migration[_0x5abca8('0x4')]['dropTable']=function(_0x27d0c6){const _0x48f432=_0x5abca8,_0x2ba6e8=this;this[_0x48f432('0x1b')][_0x48f432('0xf')](function(){const _0x1769e1=_0x48f432;return _0x2ba6e8[_0x1769e1('0x18')]['dropTable'](_0x27d0c6,{'force':!![]})[_0x1769e1('0x9')](function(){const _0x5ca7f9=_0x1769e1;logger[_0x5ca7f9('0x14')]('table\x20dropped\x20%s',_0x27d0c6);})[_0x1769e1('0x1')](function(_0x4ded5d){const _0x4c08e1=_0x1769e1;logger[_0x4c08e1('0x14')](JSON[_0x4c08e1('0xa')](_0x4ded5d));});});},Migration[_0x5abca8('0x4')][_0x5abca8('0x15')]=function(_0x4226f9,_0x35947d,_0x213981){const _0x1f7ed1=_0x5abca8,_0x217f40=this;this[_0x1f7ed1('0x1b')]['enqueue'](function(){const _0x2e2c03=_0x1f7ed1;return _0x217f40[_0x2e2c03('0x18')]['addIndex'](_0x4226f9,_0x35947d,{'indexName':_0x213981[_0x2e2c03('0x2')],'indicesType':_0x213981['indicesType']})[_0x2e2c03('0x9')](function(){const _0x7be7ef=_0x2e2c03;logger[_0x7be7ef('0x14')](_0x7be7ef('0x1a'),_0x4226f9,_0x35947d[_0x7be7ef('0x16')](','),_0x213981[_0x7be7ef('0x2')],_0x213981[_0x7be7ef('0x1f')]);})[_0x2e2c03('0x1')](function(_0x490440){const _0x4efc52=_0x2e2c03;logger['info'](JSON[_0x4efc52('0xa')](_0x490440));});});},Migration['prototype'][_0x5abca8('0x17')]=function(_0x14fe61,_0x2d0af8){const _0x53579c=_0x5abca8,_0x565f5b=this;this[_0x53579c('0x1b')][_0x53579c('0xf')](function(){const _0x39179d=_0x53579c;return _0x565f5b[_0x39179d('0x18')][_0x39179d('0x17')](_0x14fe61,_0x2d0af8)[_0x39179d('0x9')](function(){const _0x4b5c40=_0x39179d;logger[_0x4b5c40('0x14')](_0x4b5c40('0xe'),_0x14fe61,_0x2d0af8);})[_0x39179d('0x1')](function(_0x24ec48){const _0x1ef165=_0x39179d;logger['info'](JSON[_0x1ef165('0xa')](_0x24ec48));});});},Migration[_0x5abca8('0x4')]['query']=function(_0x4b28e3){const _0x596ad4=_0x5abca8,_0x54179d=this;this[_0x596ad4('0x1b')][_0x596ad4('0xf')](function(){const _0xb6f7cb=_0x596ad4;return _0x54179d['queryInterface'][_0xb6f7cb('0x1d')][_0xb6f7cb('0x13')](_0x4b28e3)['then'](function(){const _0xfa94db=_0xb6f7cb;logger[_0xfa94db('0x14')](_0xfa94db('0xc'),_0x4b28e3);})['catch'](function(_0x1f661f){const _0x2d9f7c=_0xb6f7cb;logger['info'](JSON[_0x2d9f7c('0xa')](_0x1f661f));});});},Migration[_0x5abca8('0x4')]['removeColumn']=function(_0x3e1969,_0x55ec49){const _0x216454=_0x5abca8,_0x1c197a=this;this[_0x216454('0x1b')][_0x216454('0xf')](function(){const _0x4fa636=_0x216454;return _0x1c197a[_0x4fa636('0x18')][_0x4fa636('0xd')](_0x3e1969,_0x55ec49)[_0x4fa636('0x9')](function(){const _0x49b62c=_0x4fa636;logger[_0x49b62c('0x14')](_0x49b62c('0x1c'),_0x55ec49,_0x3e1969);})[_0x4fa636('0x1')](function(_0x189679){const _0x15e2c6=_0x4fa636;logger[_0x15e2c6('0x14')](util[_0x15e2c6('0x11')](_0x189679,{'showHidden':![],'depth':null}));});});},Migration[_0x5abca8('0x4')][_0x5abca8('0x7')]=function(_0x1d7502,_0x54bfbf,_0x172a31){const _0x5352b2=_0x5abca8,_0x403a9d=this;this[_0x5352b2('0x1b')][_0x5352b2('0xf')](function(){const _0x214e83=_0x5352b2;return _0x403a9d[_0x214e83('0x18')][_0x214e83('0x7')](_0x1d7502,_0x54bfbf,_0x172a31)[_0x214e83('0x9')](function(){const _0xcfabfb=_0x214e83;logger[_0xcfabfb('0x14')](_0xcfabfb('0x8'),_0x54bfbf,_0x172a31,_0x1d7502);})[_0x214e83('0x1')](function(_0x36870){const _0x37423a=_0x214e83;logger[_0x37423a('0x14')](util[_0x37423a('0x11')](_0x36870,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0xbc2034){const _0x10ba72=_0x5abca8;this[_0x10ba72('0x1b')]['enqueue'](function(){return _0xbc2034();});},module[_0x5abca8('0x1e')]={'up':function(_0x3ae90c){return new Promise(function(_0x3c573c){const _0x385f99=a992_0x3ad2,_0x2213ce=new Migration(_0x3ae90c);_0x2213ce[_0x385f99('0xb')](_0x3c573c);});},'down':function(){}}; \ No newline at end of file +const a992_0x5a05=['util','final','indexName','renameColumn','finally','sequence','prototype','table\x20dropped\x20%s','addColumn','query','tail','enqueue','removeIndex\x20%s\x20%s','Removed\x20column\x20%s\x20from\x20%s','removeColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','info','exports','migration','stringify','changeColumn','queryInterface','addIndex\x20%s\x20%s\x20%s\x20[%s]','Added\x20column\x20%s\x20to\x20%s','then','catch','indicesType','addIndex','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','removeIndex','inspect','../config/logger'];(function(_0x1e60cb,_0x5a050f){const _0x63d649=function(_0x5117f4){while(--_0x5117f4){_0x1e60cb['push'](_0x1e60cb['shift']());}};_0x63d649(++_0x5a050f);}(a992_0x5a05,0x184));const a992_0x63d6=function(_0x1e60cb,_0x5a050f){_0x1e60cb=_0x1e60cb-0x0;let _0x63d649=a992_0x5a05[_0x1e60cb];return _0x63d649;};const _0x2de8ba=a992_0x63d6;'use strict';const util=require(_0x2de8ba('0x1c')),logger=require(_0x2de8ba('0x1b'))(_0x2de8ba('0xe')),Sequence=function(){};Sequence[_0x2de8ba('0x2')][_0x2de8ba('0x7')]=function(_0x5117f4){const _0x1e4ece=_0x2de8ba;this[_0x1e4ece('0x6')]=this[_0x1e4ece('0x6')]?this['tail'][_0x1e4ece('0x0')](_0x5117f4):_0x5117f4();};const Migration=function(_0x4752d9){const _0x142f57=_0x2de8ba;this[_0x142f57('0x11')]=_0x4752d9,this[_0x142f57('0x1')]=new Sequence();};Migration['prototype'][_0x2de8ba('0x10')]=function(_0x2e22e4,_0xa3aafd,_0x1f3b8a){const _0x4a89d4=_0x2de8ba,_0xcaf543=this;this[_0x4a89d4('0x1')][_0x4a89d4('0x7')](function(){const _0x57a71d=_0x4a89d4;return _0xcaf543[_0x57a71d('0x11')][_0x57a71d('0x10')](_0x2e22e4,_0xa3aafd,_0x1f3b8a)[_0x57a71d('0x14')](function(){const _0x2deb4b=_0x57a71d;logger[_0x2deb4b('0xc')](_0x2deb4b('0xb'),_0xa3aafd,_0x2e22e4);})['catch'](function(_0x246cd6){const _0x2ce750=_0x57a71d;logger[_0x2ce750('0xc')](JSON['stringify'](_0x246cd6));});});},Migration[_0x2de8ba('0x2')][_0x2de8ba('0x4')]=function(_0x573f1f,_0x4a1439,_0x7482dc){const _0x4228eb=_0x2de8ba,_0x219cf0=this;this['sequence'][_0x4228eb('0x7')](function(){const _0x1d828d=_0x4228eb;return _0x219cf0[_0x1d828d('0x11')][_0x1d828d('0x4')](_0x573f1f,_0x4a1439,_0x7482dc)[_0x1d828d('0x14')](function(){const _0x339628=_0x1d828d;logger[_0x339628('0xc')](_0x339628('0x13'),_0x4a1439,_0x573f1f);})[_0x1d828d('0x15')](function(_0x1847cf){const _0x1e6a5a=_0x1d828d;logger[_0x1e6a5a('0xc')](JSON[_0x1e6a5a('0xf')](_0x1847cf));});});},Migration['prototype']['dropTable']=function(_0xb4099f){const _0x452d3f=_0x2de8ba,_0x452e87=this;this[_0x452d3f('0x1')][_0x452d3f('0x7')](function(){const _0x41631b=_0x452d3f;return _0x452e87[_0x41631b('0x11')]['dropTable'](_0xb4099f,{'force':!![]})['then'](function(){const _0x1e0fd7=_0x41631b;logger[_0x1e0fd7('0xc')](_0x1e0fd7('0x3'),_0xb4099f);})[_0x41631b('0x15')](function(_0x4d60e3){const _0x29d8c1=_0x41631b;logger[_0x29d8c1('0xc')](JSON['stringify'](_0x4d60e3));});});},Migration[_0x2de8ba('0x2')]['addIndex']=function(_0x422985,_0xf75348,_0x141ef3){const _0x5746bd=_0x2de8ba,_0xb055fc=this;this[_0x5746bd('0x1')][_0x5746bd('0x7')](function(){const _0x50864e=_0x5746bd;return _0xb055fc['queryInterface'][_0x50864e('0x17')](_0x422985,_0xf75348,{'indexName':_0x141ef3[_0x50864e('0x1e')],'indicesType':_0x141ef3[_0x50864e('0x16')]})[_0x50864e('0x14')](function(){const _0x624f91=_0x50864e;logger[_0x624f91('0xc')](_0x624f91('0x12'),_0x422985,_0xf75348['join'](','),_0x141ef3[_0x624f91('0x1e')],_0x141ef3[_0x624f91('0x16')]);})[_0x50864e('0x15')](function(_0x285857){const _0x4ccbbf=_0x50864e;logger[_0x4ccbbf('0xc')](JSON[_0x4ccbbf('0xf')](_0x285857));});});},Migration['prototype'][_0x2de8ba('0x19')]=function(_0x4c12cf,_0x48db95){const _0x4b64ac=this;this['sequence']['enqueue'](function(){const _0x36d379=a992_0x63d6;return _0x4b64ac[_0x36d379('0x11')][_0x36d379('0x19')](_0x4c12cf,_0x48db95)[_0x36d379('0x14')](function(){const _0x50a8b8=_0x36d379;logger['info'](_0x50a8b8('0x8'),_0x4c12cf,_0x48db95);})['catch'](function(_0x5e9e05){const _0x345fa3=_0x36d379;logger[_0x345fa3('0xc')](JSON[_0x345fa3('0xf')](_0x5e9e05));});});},Migration[_0x2de8ba('0x2')][_0x2de8ba('0x5')]=function(_0xd10f22){const _0x4ba4cb=_0x2de8ba,_0x47ccfe=this;this['sequence'][_0x4ba4cb('0x7')](function(){const _0x271896=_0x4ba4cb;return _0x47ccfe['queryInterface']['sequelize'][_0x271896('0x5')](_0xd10f22)['then'](function(){const _0x545a3f=_0x271896;logger[_0x545a3f('0xc')]('query\x20%s',_0xd10f22);})['catch'](function(_0x234970){const _0x3f9adf=_0x271896;logger['info'](JSON[_0x3f9adf('0xf')](_0x234970));});});},Migration[_0x2de8ba('0x2')][_0x2de8ba('0xa')]=function(_0x5395bd,_0x3e5535){const _0x2f5db9=_0x2de8ba,_0xb57293=this;this[_0x2f5db9('0x1')][_0x2f5db9('0x7')](function(){const _0x26a571=_0x2f5db9;return _0xb57293['queryInterface']['removeColumn'](_0x5395bd,_0x3e5535)['then'](function(){const _0x539201=a992_0x63d6;logger['info'](_0x539201('0x9'),_0x3e5535,_0x5395bd);})[_0x26a571('0x15')](function(_0x9530a3){const _0x4728b4=_0x26a571;logger[_0x4728b4('0xc')](util[_0x4728b4('0x1a')](_0x9530a3,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x2de8ba('0x1f')]=function(_0x403fab,_0x2ffee9,_0x39410b){const _0x219d1d=_0x2de8ba,_0x38264a=this;this[_0x219d1d('0x1')][_0x219d1d('0x7')](function(){const _0xf2e4d1=_0x219d1d;return _0x38264a[_0xf2e4d1('0x11')][_0xf2e4d1('0x1f')](_0x403fab,_0x2ffee9,_0x39410b)[_0xf2e4d1('0x14')](function(){const _0x1182b5=_0xf2e4d1;logger['info'](_0x1182b5('0x18'),_0x2ffee9,_0x39410b,_0x403fab);})['catch'](function(_0xcfb4e9){const _0x15455b=_0xf2e4d1;logger[_0x15455b('0xc')](util['inspect'](_0xcfb4e9,{'showHidden':![],'depth':null}));});});},Migration[_0x2de8ba('0x2')]['final']=function(_0x303ef5){const _0x2f4c14=_0x2de8ba;this[_0x2f4c14('0x1')][_0x2f4c14('0x7')](function(){return _0x303ef5();});},module[_0x2de8ba('0xd')]={'up':function(_0x55fdc3){return new Promise(function(_0x3cac66){const _0x187f91=a992_0x63d6,_0x16eed2=new Migration(_0x55fdc3);_0x16eed2[_0x187f91('0x1d')](_0x3cac66);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.10.js b/server/migrations/2.4.10.js index 7f5b32b..89d4253 100644 --- a/server/migrations/2.4.10.js +++ b/server/migrations/2.4.10.js @@ -1 +1 @@ -const a993_0x26c9=['renameColumn','sequence','indicesType','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','join','TEXT','enqueue','removeIndex','info','inspect','finally','removeIndex\x20%s\x20%s','queryInterface','../config/logger','settings','catch','addIndex','removeColumn','indexName','STRING','util','table\x20dropped\x20%s','then','final','exports','dropTable','favicon','prototype','changeColumn','query\x20%s','query','addColumn','migration','sequelize','tail','chat_interactions','stringify','Changed\x20column\x20%s\x20in\x20table\x20%s'];(function(_0x2c58e3,_0x26c99c){const _0x44779a=function(_0x3b5c98){while(--_0x3b5c98){_0x2c58e3['push'](_0x2c58e3['shift']());}};_0x44779a(++_0x26c99c);}(a993_0x26c9,0x18a));const a993_0x4477=function(_0x2c58e3,_0x26c99c){_0x2c58e3=_0x2c58e3-0x0;let _0x44779a=a993_0x26c9[_0x2c58e3];return _0x44779a;};const _0x3d9a9=a993_0x4477;'use strict';const util=require(_0x3d9a9('0x6')),logger=require(_0x3d9a9('0x25'))(_0x3d9a9('0x12')),Sequence=function(){};Sequence[_0x3d9a9('0xd')]['enqueue']=function(_0x3b5c98){const _0x54e002=_0x3d9a9;this[_0x54e002('0x14')]=this[_0x54e002('0x14')]?this['tail'][_0x54e002('0x22')](_0x3b5c98):_0x3b5c98();};const Migration=function(_0x591aca){const _0x14088e=_0x3d9a9;this[_0x14088e('0x24')]=_0x591aca,this[_0x14088e('0x19')]=new Sequence();};Migration[_0x3d9a9('0xd')]['changeColumn']=function(_0x5e0c8e,_0x18d927,_0x4c2342){const _0x5cdbb9=_0x3d9a9,_0xe61e4a=this;this[_0x5cdbb9('0x19')]['enqueue'](function(){const _0x40f903=_0x5cdbb9;return _0xe61e4a[_0x40f903('0x24')][_0x40f903('0xe')](_0x5e0c8e,_0x18d927,_0x4c2342)['then'](function(){const _0x1835d8=_0x40f903;logger[_0x1835d8('0x20')](_0x1835d8('0x17'),_0x18d927,_0x5e0c8e);})[_0x40f903('0x1')](function(_0x4ec5b6){const _0x5560b9=_0x40f903;logger[_0x5560b9('0x20')](JSON[_0x5560b9('0x16')](_0x4ec5b6));});});},Migration[_0x3d9a9('0xd')]['addColumn']=function(_0x33612d,_0x1cd983,_0x306322){const _0x54fed9=_0x3d9a9,_0x5ab6f0=this;this[_0x54fed9('0x19')][_0x54fed9('0x1e')](function(){const _0x4fae89=_0x54fed9;return _0x5ab6f0['queryInterface'][_0x4fae89('0x11')](_0x33612d,_0x1cd983,_0x306322)[_0x4fae89('0x8')](function(){const _0x33e9ff=_0x4fae89;logger[_0x33e9ff('0x20')]('Added\x20column\x20%s\x20to\x20%s',_0x1cd983,_0x33612d);})[_0x4fae89('0x1')](function(_0x1e92bf){const _0x31c829=_0x4fae89;logger[_0x31c829('0x20')](JSON['stringify'](_0x1e92bf));});});},Migration[_0x3d9a9('0xd')][_0x3d9a9('0xb')]=function(_0x35cefa){const _0x2c24b0=_0x3d9a9,_0x5997e3=this;this[_0x2c24b0('0x19')][_0x2c24b0('0x1e')](function(){const _0x396d31=_0x2c24b0;return _0x5997e3[_0x396d31('0x24')][_0x396d31('0xb')](_0x35cefa,{'force':!![]})[_0x396d31('0x8')](function(){const _0x50203a=_0x396d31;logger[_0x50203a('0x20')](_0x50203a('0x7'),_0x35cefa);})[_0x396d31('0x1')](function(_0x3e8051){const _0x2c617e=_0x396d31;logger['info'](JSON[_0x2c617e('0x16')](_0x3e8051));});});},Migration[_0x3d9a9('0xd')][_0x3d9a9('0x2')]=function(_0x3b7b49,_0x52bb18,_0x4594f5){const _0x139eed=_0x3d9a9,_0x9a0926=this;this[_0x139eed('0x19')]['enqueue'](function(){const _0x39d50e=_0x139eed;return _0x9a0926[_0x39d50e('0x24')][_0x39d50e('0x2')](_0x3b7b49,_0x52bb18,{'indexName':_0x4594f5[_0x39d50e('0x4')],'indicesType':_0x4594f5[_0x39d50e('0x1a')]})[_0x39d50e('0x8')](function(){const _0x2d4702=_0x39d50e;logger[_0x2d4702('0x20')]('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x3b7b49,_0x52bb18[_0x2d4702('0x1c')](','),_0x4594f5[_0x2d4702('0x4')],_0x4594f5['indicesType']);})['catch'](function(_0xc15f4e){const _0x5ebb08=_0x39d50e;logger['info'](JSON[_0x5ebb08('0x16')](_0xc15f4e));});});},Migration[_0x3d9a9('0xd')][_0x3d9a9('0x1f')]=function(_0xda35ad,_0x285a5a){const _0x1664dd=this;this['sequence']['enqueue'](function(){const _0x2304ea=a993_0x4477;return _0x1664dd[_0x2304ea('0x24')]['removeIndex'](_0xda35ad,_0x285a5a)[_0x2304ea('0x8')](function(){const _0x901388=_0x2304ea;logger['info'](_0x901388('0x23'),_0xda35ad,_0x285a5a);})[_0x2304ea('0x1')](function(_0x5c01b9){logger['info'](JSON['stringify'](_0x5c01b9));});});},Migration[_0x3d9a9('0xd')][_0x3d9a9('0x10')]=function(_0x335b26){const _0x4e8ced=_0x3d9a9,_0x5f3dc0=this;this[_0x4e8ced('0x19')]['enqueue'](function(){const _0x11cc3a=_0x4e8ced;return _0x5f3dc0[_0x11cc3a('0x24')][_0x11cc3a('0x13')][_0x11cc3a('0x10')](_0x335b26)[_0x11cc3a('0x8')](function(){const _0x1a3c0f=_0x11cc3a;logger['info'](_0x1a3c0f('0xf'),_0x335b26);})[_0x11cc3a('0x1')](function(_0x33f3a9){logger['info'](JSON['stringify'](_0x33f3a9));});});},Migration[_0x3d9a9('0xd')][_0x3d9a9('0x3')]=function(_0xc50ea7,_0x3da1d5){const _0x322945=_0x3d9a9,_0x1a5086=this;this[_0x322945('0x19')][_0x322945('0x1e')](function(){const _0x497c14=_0x322945;return _0x1a5086[_0x497c14('0x24')][_0x497c14('0x3')](_0xc50ea7,_0x3da1d5)[_0x497c14('0x8')](function(){const _0x1adc29=_0x497c14;logger[_0x1adc29('0x20')]('Removed\x20column\x20%s\x20from\x20%s',_0x3da1d5,_0xc50ea7);})[_0x497c14('0x1')](function(_0x4cb118){const _0x1bca53=_0x497c14;logger[_0x1bca53('0x20')](util[_0x1bca53('0x21')](_0x4cb118,{'showHidden':![],'depth':null}));});});},Migration[_0x3d9a9('0xd')][_0x3d9a9('0x18')]=function(_0x27972a,_0x266ebc,_0x2adecd){const _0x1443aa=_0x3d9a9,_0x1c2b9f=this;this['sequence'][_0x1443aa('0x1e')](function(){const _0x4ab759=_0x1443aa;return _0x1c2b9f['queryInterface'][_0x4ab759('0x18')](_0x27972a,_0x266ebc,_0x2adecd)['then'](function(){const _0x44c012=_0x4ab759;logger[_0x44c012('0x20')](_0x44c012('0x1b'),_0x266ebc,_0x2adecd,_0x27972a);})[_0x4ab759('0x1')](function(_0x242fc7){const _0x56f18b=_0x4ab759;logger[_0x56f18b('0x20')](util[_0x56f18b('0x21')](_0x242fc7,{'showHidden':![],'depth':null}));});});},Migration[_0x3d9a9('0xd')][_0x3d9a9('0x9')]=function(_0x51343e){const _0x58a351=_0x3d9a9;this[_0x58a351('0x19')]['enqueue'](function(){return _0x51343e();});},module[_0x3d9a9('0xa')]={'up':function(_0x19c943,_0x4f6c8b){return new Promise(function(_0x402cc3){const _0x5e7c72=a993_0x4477,_0x21cc4c=new Migration(_0x19c943);_0x21cc4c[_0x5e7c72('0xe')](_0x5e7c72('0x15'),'referer',{'type':_0x4f6c8b[_0x5e7c72('0x1d')]}),_0x21cc4c['addColumn']('settings',_0x5e7c72('0xc'),{'type':_0x4f6c8b[_0x5e7c72('0x5')]}),_0x21cc4c[_0x5e7c72('0x11')](_0x5e7c72('0x0'),'defaultFavicon',{'type':_0x4f6c8b['BOOLEAN'],'defaultValue':!![]}),_0x21cc4c[_0x5e7c72('0x9')](_0x402cc3);});},'down':function(){}}; \ No newline at end of file +const a993_0x3e74=['indicesType','addIndex\x20%s\x20%s\x20%s\x20[%s]','changeColumn','prototype','renameColumn','removeColumn','defaultFavicon','TEXT','removeIndex','../config/logger','migration','removeIndex\x20%s\x20%s','sequelize','Changed\x20column\x20%s\x20in\x20table\x20%s','join','then','stringify','enqueue','table\x20dropped\x20%s','finally','sequence','indexName','query','inspect','addIndex','favicon','catch','addColumn','info','queryInterface','tail','Removed\x20column\x20%s\x20from\x20%s','referer','dropTable','STRING','final','BOOLEAN','util'];(function(_0x2b2113,_0x3e743f){const _0x3730be=function(_0x51c081){while(--_0x51c081){_0x2b2113['push'](_0x2b2113['shift']());}};_0x3730be(++_0x3e743f);}(a993_0x3e74,0x9a));const a993_0x3730=function(_0x2b2113,_0x3e743f){_0x2b2113=_0x2b2113-0x0;let _0x3730be=a993_0x3e74[_0x2b2113];return _0x3730be;};const _0x264464=a993_0x3730;'use strict';const util=require(_0x264464('0x23')),logger=require(_0x264464('0x7'))(_0x264464('0x8')),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x51c081){const _0x217fdd=_0x264464;this[_0x217fdd('0x1c')]=this['tail']?this[_0x217fdd('0x1c')][_0x217fdd('0x11')](_0x51c081):_0x51c081();};const Migration=function(_0x30abbf){const _0x4fcd47=_0x264464;this[_0x4fcd47('0x1b')]=_0x30abbf,this[_0x4fcd47('0x12')]=new Sequence();};Migration['prototype'][_0x264464('0x0')]=function(_0x1e5377,_0x1abfea,_0x4ef5f2){const _0x328408=_0x264464,_0x50e8ee=this;this[_0x328408('0x12')][_0x328408('0xf')](function(){const _0x2d6fc4=_0x328408;return _0x50e8ee[_0x2d6fc4('0x1b')][_0x2d6fc4('0x0')](_0x1e5377,_0x1abfea,_0x4ef5f2)[_0x2d6fc4('0xd')](function(){const _0x1e6a7b=_0x2d6fc4;logger[_0x1e6a7b('0x1a')](_0x1e6a7b('0xb'),_0x1abfea,_0x1e5377);})['catch'](function(_0x1d3dc0){const _0x3c91bf=_0x2d6fc4;logger[_0x3c91bf('0x1a')](JSON[_0x3c91bf('0xe')](_0x1d3dc0));});});},Migration[_0x264464('0x1')][_0x264464('0x19')]=function(_0x156fd8,_0x283eba,_0x3278e1){const _0x23663b=_0x264464,_0x52cca5=this;this['sequence'][_0x23663b('0xf')](function(){const _0x282f4c=_0x23663b;return _0x52cca5[_0x282f4c('0x1b')]['addColumn'](_0x156fd8,_0x283eba,_0x3278e1)[_0x282f4c('0xd')](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x283eba,_0x156fd8);})[_0x282f4c('0x18')](function(_0x548763){const _0x21d228=_0x282f4c;logger[_0x21d228('0x1a')](JSON['stringify'](_0x548763));});});},Migration[_0x264464('0x1')]['dropTable']=function(_0x4341d4){const _0x58ba6a=_0x264464,_0x5cbb08=this;this['sequence'][_0x58ba6a('0xf')](function(){const _0x1446d5=_0x58ba6a;return _0x5cbb08['queryInterface'][_0x1446d5('0x1f')](_0x4341d4,{'force':!![]})[_0x1446d5('0xd')](function(){const _0x1521cd=_0x1446d5;logger[_0x1521cd('0x1a')](_0x1521cd('0x10'),_0x4341d4);})[_0x1446d5('0x18')](function(_0x27ef36){const _0x1e3f5e=_0x1446d5;logger[_0x1e3f5e('0x1a')](JSON[_0x1e3f5e('0xe')](_0x27ef36));});});},Migration[_0x264464('0x1')]['addIndex']=function(_0x571aa5,_0x5edb37,_0x211ac1){const _0x2fde16=_0x264464,_0x1036f6=this;this[_0x2fde16('0x12')][_0x2fde16('0xf')](function(){const _0x4b93c6=_0x2fde16;return _0x1036f6[_0x4b93c6('0x1b')][_0x4b93c6('0x16')](_0x571aa5,_0x5edb37,{'indexName':_0x211ac1[_0x4b93c6('0x13')],'indicesType':_0x211ac1[_0x4b93c6('0x24')]})[_0x4b93c6('0xd')](function(){const _0x1885e6=_0x4b93c6;logger[_0x1885e6('0x1a')](_0x1885e6('0x25'),_0x571aa5,_0x5edb37[_0x1885e6('0xc')](','),_0x211ac1['indexName'],_0x211ac1[_0x1885e6('0x24')]);})['catch'](function(_0x4be4c6){const _0x324f9f=_0x4b93c6;logger['info'](JSON[_0x324f9f('0xe')](_0x4be4c6));});});},Migration[_0x264464('0x1')]['removeIndex']=function(_0x463912,_0x350c80){const _0x42423c=_0x264464,_0x344777=this;this[_0x42423c('0x12')][_0x42423c('0xf')](function(){const _0x54bbb9=_0x42423c;return _0x344777[_0x54bbb9('0x1b')][_0x54bbb9('0x6')](_0x463912,_0x350c80)[_0x54bbb9('0xd')](function(){const _0x3571d0=_0x54bbb9;logger['info'](_0x3571d0('0x9'),_0x463912,_0x350c80);})[_0x54bbb9('0x18')](function(_0x271cd0){const _0x2083a9=_0x54bbb9;logger[_0x2083a9('0x1a')](JSON['stringify'](_0x271cd0));});});},Migration['prototype']['query']=function(_0x2cb7ef){const _0x17d841=_0x264464,_0x482ccb=this;this[_0x17d841('0x12')][_0x17d841('0xf')](function(){const _0x241d7d=_0x17d841;return _0x482ccb['queryInterface'][_0x241d7d('0xa')][_0x241d7d('0x14')](_0x2cb7ef)[_0x241d7d('0xd')](function(){const _0x8e8508=_0x241d7d;logger[_0x8e8508('0x1a')]('query\x20%s',_0x2cb7ef);})[_0x241d7d('0x18')](function(_0x3b6ac4){logger['info'](JSON['stringify'](_0x3b6ac4));});});},Migration[_0x264464('0x1')]['removeColumn']=function(_0x4085d6,_0x152420){const _0x2c2913=_0x264464,_0x5dc703=this;this[_0x2c2913('0x12')][_0x2c2913('0xf')](function(){const _0x1ac6ee=_0x2c2913;return _0x5dc703[_0x1ac6ee('0x1b')][_0x1ac6ee('0x3')](_0x4085d6,_0x152420)[_0x1ac6ee('0xd')](function(){const _0x54a177=_0x1ac6ee;logger[_0x54a177('0x1a')](_0x54a177('0x1d'),_0x152420,_0x4085d6);})[_0x1ac6ee('0x18')](function(_0x25cf69){const _0x428dea=_0x1ac6ee;logger[_0x428dea('0x1a')](util[_0x428dea('0x15')](_0x25cf69,{'showHidden':![],'depth':null}));});});},Migration[_0x264464('0x1')][_0x264464('0x2')]=function(_0x5222ab,_0x528a7b,_0x416caf){const _0x55f16f=this;this['sequence']['enqueue'](function(){const _0x5c9587=a993_0x3730;return _0x55f16f[_0x5c9587('0x1b')][_0x5c9587('0x2')](_0x5222ab,_0x528a7b,_0x416caf)[_0x5c9587('0xd')](function(){const _0x5e97d6=_0x5c9587;logger[_0x5e97d6('0x1a')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x528a7b,_0x416caf,_0x5222ab);})[_0x5c9587('0x18')](function(_0x317d72){const _0x3262c3=_0x5c9587;logger[_0x3262c3('0x1a')](util[_0x3262c3('0x15')](_0x317d72,{'showHidden':![],'depth':null}));});});},Migration[_0x264464('0x1')][_0x264464('0x21')]=function(_0x3f8126){const _0x29a20e=_0x264464;this['sequence'][_0x29a20e('0xf')](function(){return _0x3f8126();});},module['exports']={'up':function(_0x1b6b24,_0x54d7f4){return new Promise(function(_0x55e8b2){const _0x16a5ba=a993_0x3730,_0x35f692=new Migration(_0x1b6b24);_0x35f692['changeColumn']('chat_interactions',_0x16a5ba('0x1e'),{'type':_0x54d7f4[_0x16a5ba('0x5')]}),_0x35f692['addColumn']('settings',_0x16a5ba('0x17'),{'type':_0x54d7f4[_0x16a5ba('0x20')]}),_0x35f692[_0x16a5ba('0x19')]('settings',_0x16a5ba('0x4'),{'type':_0x54d7f4[_0x16a5ba('0x22')],'defaultValue':!![]}),_0x35f692['final'](_0x55e8b2);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.11.js b/server/migrations/2.4.11.js index 75ca6e2..4a15f10 100644 --- a/server/migrations/2.4.11.js +++ b/server/migrations/2.4.11.js @@ -1 +1 @@ -const a994_0x4dd2=['addIndex','final','catch','enqueue','tail','stringify','Added\x20column\x20%s\x20to\x20%s','queryInterface','info','prototype','indexName','renameColumn','addIndex\x20%s\x20%s\x20%s\x20[%s]','Changed\x20column\x20%s\x20in\x20table\x20%s','inspect','sequence','removeIndex','changeColumn','table\x20dropped\x20%s','migration','dropTable','then','sequelize','removeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','exports','query','Removed\x20column\x20%s\x20from\x20%s','addColumn','../config/logger'];(function(_0x18c41e,_0x4dd2a5){const _0x37d042=function(_0x15ea29){while(--_0x15ea29){_0x18c41e['push'](_0x18c41e['shift']());}};_0x37d042(++_0x4dd2a5);}(a994_0x4dd2,0x7f));const a994_0x37d0=function(_0x18c41e,_0x4dd2a5){_0x18c41e=_0x18c41e-0x0;let _0x37d042=a994_0x4dd2[_0x18c41e];return _0x37d042;};const _0x36003a=a994_0x37d0;'use strict';const util=require('util'),logger=require(_0x36003a('0x16'))(_0x36003a('0xc')),Sequence=function(){};Sequence[_0x36003a('0x2')][_0x36003a('0x1a')]=function(_0x15ea29){const _0x2cb94e=_0x36003a;this[_0x2cb94e('0x1b')]=this[_0x2cb94e('0x1b')]?this['tail']['finally'](_0x15ea29):_0x15ea29();};const Migration=function(_0x264557){const _0x3bdf17=_0x36003a;this[_0x3bdf17('0x0')]=_0x264557,this[_0x3bdf17('0x8')]=new Sequence();};Migration['prototype'][_0x36003a('0xa')]=function(_0x33173b,_0x405bdc,_0x57aa82){const _0xcc658a=_0x36003a,_0x7c7e86=this;this[_0xcc658a('0x8')]['enqueue'](function(){const _0x160387=_0xcc658a;return _0x7c7e86[_0x160387('0x0')][_0x160387('0xa')](_0x33173b,_0x405bdc,_0x57aa82)[_0x160387('0xe')](function(){const _0x27a28b=_0x160387;logger[_0x27a28b('0x1')](_0x27a28b('0x6'),_0x405bdc,_0x33173b);})[_0x160387('0x19')](function(_0x2a62e5){const _0x37b08e=_0x160387;logger[_0x37b08e('0x1')](JSON[_0x37b08e('0x1c')](_0x2a62e5));});});},Migration[_0x36003a('0x2')]['addColumn']=function(_0x1ff62a,_0x48480a,_0x212ea9){const _0x275352=_0x36003a,_0x18cafb=this;this[_0x275352('0x8')][_0x275352('0x1a')](function(){const _0x34ebe8=_0x275352;return _0x18cafb[_0x34ebe8('0x0')][_0x34ebe8('0x15')](_0x1ff62a,_0x48480a,_0x212ea9)[_0x34ebe8('0xe')](function(){const _0x22c69e=_0x34ebe8;logger[_0x22c69e('0x1')](_0x22c69e('0x1d'),_0x48480a,_0x1ff62a);})[_0x34ebe8('0x19')](function(_0x10f5a9){logger['info'](JSON['stringify'](_0x10f5a9));});});},Migration['prototype'][_0x36003a('0xd')]=function(_0x858607){const _0x3dfbbe=_0x36003a,_0x17a6da=this;this['sequence'][_0x3dfbbe('0x1a')](function(){const _0x140cb7=_0x3dfbbe;return _0x17a6da[_0x140cb7('0x0')][_0x140cb7('0xd')](_0x858607,{'force':!![]})[_0x140cb7('0xe')](function(){const _0x340769=_0x140cb7;logger['info'](_0x340769('0xb'),_0x858607);})[_0x140cb7('0x19')](function(_0x6431f){const _0x15b7bf=_0x140cb7;logger[_0x15b7bf('0x1')](JSON[_0x15b7bf('0x1c')](_0x6431f));});});},Migration['prototype'][_0x36003a('0x17')]=function(_0x50f278,_0x13473e,_0x4ccbf8){const _0x15f322=_0x36003a,_0x31719e=this;this[_0x15f322('0x8')][_0x15f322('0x1a')](function(){const _0x419b9f=_0x15f322;return _0x31719e[_0x419b9f('0x0')][_0x419b9f('0x17')](_0x50f278,_0x13473e,{'indexName':_0x4ccbf8[_0x419b9f('0x3')],'indicesType':_0x4ccbf8['indicesType']})[_0x419b9f('0xe')](function(){const _0x3f8803=_0x419b9f;logger['info'](_0x3f8803('0x5'),_0x50f278,_0x13473e['join'](','),_0x4ccbf8['indexName'],_0x4ccbf8['indicesType']);})[_0x419b9f('0x19')](function(_0x24fa59){const _0x11b6b6=_0x419b9f;logger[_0x11b6b6('0x1')](JSON['stringify'](_0x24fa59));});});},Migration['prototype'][_0x36003a('0x9')]=function(_0x332bf6,_0x49e448){const _0xe03750=_0x36003a,_0x23d12a=this;this['sequence'][_0xe03750('0x1a')](function(){const _0x2b0c11=_0xe03750;return _0x23d12a[_0x2b0c11('0x0')]['removeIndex'](_0x332bf6,_0x49e448)[_0x2b0c11('0xe')](function(){const _0x23d669=_0x2b0c11;logger[_0x23d669('0x1')]('removeIndex\x20%s\x20%s',_0x332bf6,_0x49e448);})[_0x2b0c11('0x19')](function(_0x3d2ce4){const _0x3cfe31=_0x2b0c11;logger[_0x3cfe31('0x1')](JSON[_0x3cfe31('0x1c')](_0x3d2ce4));});});},Migration['prototype'][_0x36003a('0x13')]=function(_0x52f706){const _0x427dbc=this;this['sequence']['enqueue'](function(){const _0x39aaf8=a994_0x37d0;return _0x427dbc[_0x39aaf8('0x0')][_0x39aaf8('0xf')][_0x39aaf8('0x13')](_0x52f706)[_0x39aaf8('0xe')](function(){logger['info']('query\x20%s',_0x52f706);})[_0x39aaf8('0x19')](function(_0x3879d7){const _0xbb7c5f=_0x39aaf8;logger[_0xbb7c5f('0x1')](JSON[_0xbb7c5f('0x1c')](_0x3879d7));});});},Migration[_0x36003a('0x2')][_0x36003a('0x10')]=function(_0x3dc70b,_0xd7cd51){const _0x402cd7=_0x36003a,_0x5d5626=this;this['sequence'][_0x402cd7('0x1a')](function(){const _0x6779a2=_0x402cd7;return _0x5d5626[_0x6779a2('0x0')][_0x6779a2('0x10')](_0x3dc70b,_0xd7cd51)[_0x6779a2('0xe')](function(){const _0x523c25=_0x6779a2;logger['info'](_0x523c25('0x14'),_0xd7cd51,_0x3dc70b);})[_0x6779a2('0x19')](function(_0x1444d5){const _0x3ac025=_0x6779a2;logger[_0x3ac025('0x1')](util[_0x3ac025('0x7')](_0x1444d5,{'showHidden':![],'depth':null}));});});},Migration[_0x36003a('0x2')][_0x36003a('0x4')]=function(_0x15951f,_0x242005,_0x489f67){const _0x3e5218=_0x36003a,_0xec0a20=this;this[_0x3e5218('0x8')][_0x3e5218('0x1a')](function(){const _0x42ce87=_0x3e5218;return _0xec0a20[_0x42ce87('0x0')][_0x42ce87('0x4')](_0x15951f,_0x242005,_0x489f67)[_0x42ce87('0xe')](function(){const _0x3b52a9=_0x42ce87;logger['info'](_0x3b52a9('0x11'),_0x242005,_0x489f67,_0x15951f);})[_0x42ce87('0x19')](function(_0x47d8e4){const _0x319e48=_0x42ce87;logger[_0x319e48('0x1')](util[_0x319e48('0x7')](_0x47d8e4,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x14accc){const _0xc05961=_0x36003a;this[_0xc05961('0x8')][_0xc05961('0x1a')](function(){return _0x14accc();});},module[_0x36003a('0x12')]={'up':function(_0x2b0fc7){return new Promise(function(_0x16bbcb){const _0x528ec1=a994_0x37d0,_0xed9eaa=new Migration(_0x2b0fc7);_0xed9eaa[_0x528ec1('0x18')](_0x16bbcb);});},'down':function(){}}; \ No newline at end of file +const a994_0x33f2=['migration','removeIndex','prototype','stringify','catch','changeColumn','queryInterface','exports','../config/logger','removeColumn','Removed\x20column\x20%s\x20from\x20%s','then','addIndex','sequelize','addIndex\x20%s\x20%s\x20%s\x20[%s]','query','query\x20%s','renameColumn','dropTable','indexName','table\x20dropped\x20%s','addColumn','Added\x20column\x20%s\x20to\x20%s','tail','removeIndex\x20%s\x20%s','join','enqueue','sequence','inspect','info'];(function(_0xde1df6,_0x33f2c0){const _0xaf6a00=function(_0x43f64f){while(--_0x43f64f){_0xde1df6['push'](_0xde1df6['shift']());}};_0xaf6a00(++_0x33f2c0);}(a994_0x33f2,0xff));const a994_0xaf6a=function(_0xde1df6,_0x33f2c0){_0xde1df6=_0xde1df6-0x0;let _0xaf6a00=a994_0x33f2[_0xde1df6];return _0xaf6a00;};const _0x4140a1=a994_0xaf6a;'use strict';const util=require('util'),logger=require(_0x4140a1('0x17'))(_0x4140a1('0xf')),Sequence=function(){};Sequence[_0x4140a1('0x11')][_0x4140a1('0xb')]=function(_0x43f64f){const _0x504c01=_0x4140a1;this[_0x504c01('0x8')]=this[_0x504c01('0x8')]?this[_0x504c01('0x8')]['finally'](_0x43f64f):_0x43f64f();};const Migration=function(_0x40f874){const _0x420276=_0x4140a1;this[_0x420276('0x15')]=_0x40f874,this[_0x420276('0xc')]=new Sequence();};Migration['prototype'][_0x4140a1('0x14')]=function(_0x1427f8,_0xcefb7d,_0x5d696d){const _0x216272=_0x4140a1,_0x598745=this;this[_0x216272('0xc')][_0x216272('0xb')](function(){const _0x3315cf=_0x216272;return _0x598745[_0x3315cf('0x15')]['changeColumn'](_0x1427f8,_0xcefb7d,_0x5d696d)[_0x3315cf('0x1a')](function(){const _0x2007e9=_0x3315cf;logger[_0x2007e9('0xe')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0xcefb7d,_0x1427f8);})['catch'](function(_0x2d52b8){const _0x1f8f1d=_0x3315cf;logger[_0x1f8f1d('0xe')](JSON[_0x1f8f1d('0x12')](_0x2d52b8));});});},Migration[_0x4140a1('0x11')]['addColumn']=function(_0x5d5ed9,_0x2f2acd,_0x39529a){const _0x16e1f4=this;this['sequence']['enqueue'](function(){const _0x4a6f62=a994_0xaf6a;return _0x16e1f4[_0x4a6f62('0x15')][_0x4a6f62('0x6')](_0x5d5ed9,_0x2f2acd,_0x39529a)[_0x4a6f62('0x1a')](function(){const _0x17a325=_0x4a6f62;logger[_0x17a325('0xe')](_0x17a325('0x7'),_0x2f2acd,_0x5d5ed9);})[_0x4a6f62('0x13')](function(_0x10bf5d){const _0x315795=_0x4a6f62;logger[_0x315795('0xe')](JSON[_0x315795('0x12')](_0x10bf5d));});});},Migration[_0x4140a1('0x11')][_0x4140a1('0x3')]=function(_0x3abad1){const _0x3de601=_0x4140a1,_0x1c4a24=this;this[_0x3de601('0xc')][_0x3de601('0xb')](function(){const _0x22a1b3=_0x3de601;return _0x1c4a24['queryInterface']['dropTable'](_0x3abad1,{'force':!![]})[_0x22a1b3('0x1a')](function(){const _0x265d66=_0x22a1b3;logger[_0x265d66('0xe')](_0x265d66('0x5'),_0x3abad1);})[_0x22a1b3('0x13')](function(_0x18d02e){const _0x311b30=_0x22a1b3;logger['info'](JSON[_0x311b30('0x12')](_0x18d02e));});});},Migration['prototype'][_0x4140a1('0x1b')]=function(_0x349432,_0x589824,_0x45208a){const _0x31c95b=_0x4140a1,_0x15cb5e=this;this['sequence'][_0x31c95b('0xb')](function(){const _0x549412=_0x31c95b;return _0x15cb5e[_0x549412('0x15')]['addIndex'](_0x349432,_0x589824,{'indexName':_0x45208a[_0x549412('0x4')],'indicesType':_0x45208a['indicesType']})[_0x549412('0x1a')](function(){const _0x482cf2=_0x549412;logger[_0x482cf2('0xe')](_0x482cf2('0x1d'),_0x349432,_0x589824[_0x482cf2('0xa')](','),_0x45208a[_0x482cf2('0x4')],_0x45208a['indicesType']);})['catch'](function(_0x581e2e){const _0x2bfd6a=_0x549412;logger[_0x2bfd6a('0xe')](JSON['stringify'](_0x581e2e));});});},Migration[_0x4140a1('0x11')][_0x4140a1('0x10')]=function(_0x55d7ae,_0x316130){const _0x415d01=_0x4140a1,_0x28a202=this;this[_0x415d01('0xc')][_0x415d01('0xb')](function(){const _0x170f91=_0x415d01;return _0x28a202['queryInterface'][_0x170f91('0x10')](_0x55d7ae,_0x316130)['then'](function(){const _0x544edb=_0x170f91;logger['info'](_0x544edb('0x9'),_0x55d7ae,_0x316130);})[_0x170f91('0x13')](function(_0x44b12a){const _0x47d081=_0x170f91;logger[_0x47d081('0xe')](JSON[_0x47d081('0x12')](_0x44b12a));});});},Migration[_0x4140a1('0x11')][_0x4140a1('0x0')]=function(_0x49609b){const _0x5ea006=_0x4140a1,_0x21857a=this;this[_0x5ea006('0xc')]['enqueue'](function(){const _0x61b741=_0x5ea006;return _0x21857a[_0x61b741('0x15')][_0x61b741('0x1c')][_0x61b741('0x0')](_0x49609b)[_0x61b741('0x1a')](function(){const _0x5b2a81=_0x61b741;logger[_0x5b2a81('0xe')](_0x5b2a81('0x1'),_0x49609b);})[_0x61b741('0x13')](function(_0xaa28b){const _0x1f4279=_0x61b741;logger[_0x1f4279('0xe')](JSON[_0x1f4279('0x12')](_0xaa28b));});});},Migration[_0x4140a1('0x11')][_0x4140a1('0x18')]=function(_0x30d220,_0x230784){const _0x3de897=_0x4140a1,_0x590a40=this;this[_0x3de897('0xc')][_0x3de897('0xb')](function(){const _0xb1c73=_0x3de897;return _0x590a40[_0xb1c73('0x15')][_0xb1c73('0x18')](_0x30d220,_0x230784)[_0xb1c73('0x1a')](function(){const _0x3970ef=_0xb1c73;logger[_0x3970ef('0xe')](_0x3970ef('0x19'),_0x230784,_0x30d220);})[_0xb1c73('0x13')](function(_0x562c6a){const _0xf2ff4b=_0xb1c73;logger[_0xf2ff4b('0xe')](util[_0xf2ff4b('0xd')](_0x562c6a,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x4140a1('0x2')]=function(_0x1f34de,_0x162ff3,_0x1e6aac){const _0x14be9d=_0x4140a1,_0x18dfda=this;this[_0x14be9d('0xc')][_0x14be9d('0xb')](function(){const _0x31dc68=_0x14be9d;return _0x18dfda[_0x31dc68('0x15')]['renameColumn'](_0x1f34de,_0x162ff3,_0x1e6aac)[_0x31dc68('0x1a')](function(){const _0x19ac01=_0x31dc68;logger[_0x19ac01('0xe')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x162ff3,_0x1e6aac,_0x1f34de);})['catch'](function(_0x1207d0){const _0x1df7eb=_0x31dc68;logger[_0x1df7eb('0xe')](util[_0x1df7eb('0xd')](_0x1207d0,{'showHidden':![],'depth':null}));});});},Migration[_0x4140a1('0x11')]['final']=function(_0x10e717){const _0xee5e5f=_0x4140a1;this['sequence'][_0xee5e5f('0xb')](function(){return _0x10e717();});},module[_0x4140a1('0x16')]={'up':function(_0x79e6fd){return new Promise(function(_0x1287bb){const _0x3d3584=new Migration(_0x79e6fd);_0x3d3584['final'](_0x1287bb);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.12.js b/server/migrations/2.4.12.js index 444b9be..fbcac90 100644 --- a/server/migrations/2.4.12.js +++ b/server/migrations/2.4.12.js @@ -1 +1 @@ -const a995_0x5179=['stringify','tail','INTEGER','settings','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','../config/logger','changeColumn','then','util','exports','loginMailFrequency','removeIndex','addIndex','dropTable','prototype','query','Changed\x20column\x20%s\x20in\x20table\x20%s','info','renameColumn','sequence','Added\x20column\x20%s\x20to\x20%s','addColumn','queryInterface','enqueue','finally','UPDATE\x20tools_actions\x20SET\x20tools_actions.data5\x20=\x20\x225\x22\x20WHERE\x20tools_actions.action\x20=\x20\x22urlForward\x22','sequelize','indexName','final','catch','removeColumn','table\x20dropped\x20%s','indicesType'];(function(_0x1284c7,_0x51790f){const _0x4dcaa3=function(_0x548b61){while(--_0x548b61){_0x1284c7['push'](_0x1284c7['shift']());}};_0x4dcaa3(++_0x51790f);}(a995_0x5179,0x64));const a995_0x4dca=function(_0x1284c7,_0x51790f){_0x1284c7=_0x1284c7-0x0;let _0x4dcaa3=a995_0x5179[_0x1284c7];return _0x4dcaa3;};const _0x32d693=a995_0x4dca;'use strict';const util=require(_0x32d693('0x7')),logger=require(_0x32d693('0x4'))('migration'),Sequence=function(){};Sequence[_0x32d693('0xd')][_0x32d693('0x16')]=function(_0x548b61){const _0x203120=_0x32d693;this[_0x203120('0x0')]=this[_0x203120('0x0')]?this[_0x203120('0x0')][_0x203120('0x17')](_0x548b61):_0x548b61();};const Migration=function(_0xedc8f0){const _0x9cae3b=_0x32d693;this[_0x9cae3b('0x15')]=_0xedc8f0,this[_0x9cae3b('0x12')]=new Sequence();};Migration['prototype'][_0x32d693('0x5')]=function(_0x754d6b,_0x1cc554,_0x2c395a){const _0x3a150d=_0x32d693,_0x3683dc=this;this[_0x3a150d('0x12')][_0x3a150d('0x16')](function(){const _0xcf98bf=_0x3a150d;return _0x3683dc[_0xcf98bf('0x15')]['changeColumn'](_0x754d6b,_0x1cc554,_0x2c395a)[_0xcf98bf('0x6')](function(){const _0x24414a=_0xcf98bf;logger[_0x24414a('0x10')](_0x24414a('0xf'),_0x1cc554,_0x754d6b);})[_0xcf98bf('0x1c')](function(_0x1b8cdd){const _0x2c5b83=_0xcf98bf;logger[_0x2c5b83('0x10')](JSON[_0x2c5b83('0x20')](_0x1b8cdd));});});},Migration[_0x32d693('0xd')][_0x32d693('0x14')]=function(_0x2d3fb0,_0x19b15d,_0x5aaab2){const _0x5ff52e=_0x32d693,_0x2b770c=this;this[_0x5ff52e('0x12')][_0x5ff52e('0x16')](function(){const _0x3b04bb=_0x5ff52e;return _0x2b770c['queryInterface'][_0x3b04bb('0x14')](_0x2d3fb0,_0x19b15d,_0x5aaab2)['then'](function(){const _0x44cad7=_0x3b04bb;logger[_0x44cad7('0x10')](_0x44cad7('0x13'),_0x19b15d,_0x2d3fb0);})['catch'](function(_0x2e3927){const _0x27cd08=_0x3b04bb;logger[_0x27cd08('0x10')](JSON[_0x27cd08('0x20')](_0x2e3927));});});},Migration[_0x32d693('0xd')][_0x32d693('0xc')]=function(_0x1d9cb4){const _0x3570f4=_0x32d693,_0x3e838a=this;this[_0x3570f4('0x12')]['enqueue'](function(){const _0x1973cf=_0x3570f4;return _0x3e838a[_0x1973cf('0x15')][_0x1973cf('0xc')](_0x1d9cb4,{'force':!![]})[_0x1973cf('0x6')](function(){const _0x3b87e7=_0x1973cf;logger['info'](_0x3b87e7('0x1e'),_0x1d9cb4);})[_0x1973cf('0x1c')](function(_0xde664){const _0x1da5e8=_0x1973cf;logger[_0x1da5e8('0x10')](JSON[_0x1da5e8('0x20')](_0xde664));});});},Migration[_0x32d693('0xd')][_0x32d693('0xb')]=function(_0x2b93d7,_0x168525,_0x3d8e70){const _0x33d02c=_0x32d693,_0x248e93=this;this[_0x33d02c('0x12')]['enqueue'](function(){const _0x1ffac4=_0x33d02c;return _0x248e93[_0x1ffac4('0x15')][_0x1ffac4('0xb')](_0x2b93d7,_0x168525,{'indexName':_0x3d8e70['indexName'],'indicesType':_0x3d8e70[_0x1ffac4('0x1f')]})[_0x1ffac4('0x6')](function(){const _0x19c0dd=_0x1ffac4;logger['info']('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x2b93d7,_0x168525['join'](','),_0x3d8e70[_0x19c0dd('0x1a')],_0x3d8e70[_0x19c0dd('0x1f')]);})[_0x1ffac4('0x1c')](function(_0x55fd45){const _0x46c2b5=_0x1ffac4;logger[_0x46c2b5('0x10')](JSON[_0x46c2b5('0x20')](_0x55fd45));});});},Migration[_0x32d693('0xd')]['removeIndex']=function(_0x4736ae,_0x3e3065){const _0x3df048=_0x32d693,_0xe3f29c=this;this['sequence'][_0x3df048('0x16')](function(){const _0x36f21f=_0x3df048;return _0xe3f29c[_0x36f21f('0x15')][_0x36f21f('0xa')](_0x4736ae,_0x3e3065)[_0x36f21f('0x6')](function(){const _0x2ba237=_0x36f21f;logger[_0x2ba237('0x10')]('removeIndex\x20%s\x20%s',_0x4736ae,_0x3e3065);})['catch'](function(_0x59a028){const _0x45b91c=_0x36f21f;logger[_0x45b91c('0x10')](JSON[_0x45b91c('0x20')](_0x59a028));});});},Migration[_0x32d693('0xd')][_0x32d693('0xe')]=function(_0x5a2250){const _0xe03dda=_0x32d693,_0x24b405=this;this[_0xe03dda('0x12')]['enqueue'](function(){const _0x5f360a=_0xe03dda;return _0x24b405['queryInterface'][_0x5f360a('0x19')]['query'](_0x5a2250)['then'](function(){logger['info']('query\x20%s',_0x5a2250);})[_0x5f360a('0x1c')](function(_0x3d6e79){const _0x10558c=_0x5f360a;logger['info'](JSON[_0x10558c('0x20')](_0x3d6e79));});});},Migration[_0x32d693('0xd')][_0x32d693('0x1d')]=function(_0x14fb39,_0xb153b){const _0x1bca46=_0x32d693,_0x4639c9=this;this[_0x1bca46('0x12')][_0x1bca46('0x16')](function(){const _0x1ff76e=_0x1bca46;return _0x4639c9[_0x1ff76e('0x15')][_0x1ff76e('0x1d')](_0x14fb39,_0xb153b)[_0x1ff76e('0x6')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0xb153b,_0x14fb39);})[_0x1ff76e('0x1c')](function(_0x25dfe4){logger['info'](util['inspect'](_0x25dfe4,{'showHidden':![],'depth':null}));});});},Migration[_0x32d693('0xd')]['renameColumn']=function(_0x7fce27,_0x54d626,_0x423130){const _0x503c1e=_0x32d693,_0x27f2d2=this;this[_0x503c1e('0x12')][_0x503c1e('0x16')](function(){const _0x2cf54f=_0x503c1e;return _0x27f2d2[_0x2cf54f('0x15')][_0x2cf54f('0x11')](_0x7fce27,_0x54d626,_0x423130)[_0x2cf54f('0x6')](function(){const _0x3c9e3b=_0x2cf54f;logger['info'](_0x3c9e3b('0x3'),_0x54d626,_0x423130,_0x7fce27);})[_0x2cf54f('0x1c')](function(_0x26597a){const _0x21dee0=_0x2cf54f;logger[_0x21dee0('0x10')](util['inspect'](_0x26597a,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x32d693('0x1b')]=function(_0x10a0bb){const _0x32768f=_0x32d693;this['sequence'][_0x32768f('0x16')](function(){return _0x10a0bb();});},module[_0x32d693('0x8')]={'up':function(_0x24d5f1,_0x107bbe){return new Promise(function(_0x51e70b){const _0x1f3168=a995_0x4dca,_0x16b363=new Migration(_0x24d5f1);_0x16b363[_0x1f3168('0x14')](_0x1f3168('0x2'),_0x1f3168('0x9'),{'type':_0x107bbe[_0x1f3168('0x1')],'defaultValue':0xa}),_0x16b363[_0x1f3168('0xe')](_0x1f3168('0x18')),_0x16b363[_0x1f3168('0x1b')](_0x51e70b);});},'down':function(){}}; \ No newline at end of file +const a995_0x300e=['INTEGER','addIndex\x20%s\x20%s\x20%s\x20[%s]','util','queryInterface','changeColumn','removeIndex','migration','enqueue','renameColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','tail','dropTable','indicesType','../config/logger','info','addColumn','settings','Added\x20column\x20%s\x20to\x20%s','then','query\x20%s','Removed\x20column\x20%s\x20from\x20%s','table\x20dropped\x20%s','stringify','join','query','prototype','catch','removeIndex\x20%s\x20%s','sequence','indexName'];(function(_0xb02045,_0x300ee5){const _0x370093=function(_0x1cacd4){while(--_0x1cacd4){_0xb02045['push'](_0xb02045['shift']());}};_0x370093(++_0x300ee5);}(a995_0x300e,0xcf));const a995_0x3700=function(_0xb02045,_0x300ee5){_0xb02045=_0xb02045-0x0;let _0x370093=a995_0x300e[_0xb02045];return _0x370093;};const _0x3df2ae=a995_0x3700;'use strict';const util=require(_0x3df2ae('0x5')),logger=require(_0x3df2ae('0x10'))(_0x3df2ae('0x9')),Sequence=function(){};Sequence['prototype'][_0x3df2ae('0xa')]=function(_0x1cacd4){const _0x43b758=_0x3df2ae;this[_0x43b758('0xd')]=this[_0x43b758('0xd')]?this[_0x43b758('0xd')]['finally'](_0x1cacd4):_0x1cacd4();};const Migration=function(_0x3840d3){const _0x1ca212=_0x3df2ae;this[_0x1ca212('0x6')]=_0x3840d3,this[_0x1ca212('0x1')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x1f3c21,_0x2f0b5c,_0x2dcc1f){const _0x4ec428=_0x3df2ae,_0x57eda1=this;this[_0x4ec428('0x1')][_0x4ec428('0xa')](function(){const _0x50b3b2=_0x4ec428;return _0x57eda1[_0x50b3b2('0x6')][_0x50b3b2('0x7')](_0x1f3c21,_0x2f0b5c,_0x2dcc1f)[_0x50b3b2('0x15')](function(){const _0x120967=_0x50b3b2;logger[_0x120967('0x11')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x2f0b5c,_0x1f3c21);})[_0x50b3b2('0x1d')](function(_0x12dcff){const _0x180cb9=_0x50b3b2;logger[_0x180cb9('0x11')](JSON[_0x180cb9('0x19')](_0x12dcff));});});},Migration[_0x3df2ae('0x1c')][_0x3df2ae('0x12')]=function(_0x51e41d,_0x5a2d45,_0x48f21e){const _0x39bb3a=_0x3df2ae,_0x4a3fba=this;this[_0x39bb3a('0x1')]['enqueue'](function(){const _0x2e624b=_0x39bb3a;return _0x4a3fba[_0x2e624b('0x6')]['addColumn'](_0x51e41d,_0x5a2d45,_0x48f21e)[_0x2e624b('0x15')](function(){const _0x1a2140=_0x2e624b;logger[_0x1a2140('0x11')](_0x1a2140('0x14'),_0x5a2d45,_0x51e41d);})[_0x2e624b('0x1d')](function(_0x5b37ef){const _0x32c2e2=_0x2e624b;logger[_0x32c2e2('0x11')](JSON[_0x32c2e2('0x19')](_0x5b37ef));});});},Migration[_0x3df2ae('0x1c')][_0x3df2ae('0xe')]=function(_0x49bfb9){const _0x3134d2=_0x3df2ae,_0x54876a=this;this[_0x3134d2('0x1')][_0x3134d2('0xa')](function(){const _0x4bc20b=_0x3134d2;return _0x54876a[_0x4bc20b('0x6')][_0x4bc20b('0xe')](_0x49bfb9,{'force':!![]})[_0x4bc20b('0x15')](function(){const _0x147060=_0x4bc20b;logger['info'](_0x147060('0x18'),_0x49bfb9);})[_0x4bc20b('0x1d')](function(_0x259942){const _0x505083=_0x4bc20b;logger[_0x505083('0x11')](JSON[_0x505083('0x19')](_0x259942));});});},Migration[_0x3df2ae('0x1c')]['addIndex']=function(_0x1eb58c,_0x1464ca,_0x1d38ec){const _0x489d2b=this;this['sequence']['enqueue'](function(){const _0x132b20=a995_0x3700;return _0x489d2b[_0x132b20('0x6')]['addIndex'](_0x1eb58c,_0x1464ca,{'indexName':_0x1d38ec[_0x132b20('0x2')],'indicesType':_0x1d38ec['indicesType']})[_0x132b20('0x15')](function(){const _0x3f2cd4=_0x132b20;logger[_0x3f2cd4('0x11')](_0x3f2cd4('0x4'),_0x1eb58c,_0x1464ca[_0x3f2cd4('0x1a')](','),_0x1d38ec[_0x3f2cd4('0x2')],_0x1d38ec[_0x3f2cd4('0xf')]);})['catch'](function(_0x31b593){const _0xff8208=_0x132b20;logger[_0xff8208('0x11')](JSON[_0xff8208('0x19')](_0x31b593));});});},Migration['prototype'][_0x3df2ae('0x8')]=function(_0x3dbf4c,_0x140804){const _0x310051=_0x3df2ae,_0x3f9054=this;this[_0x310051('0x1')][_0x310051('0xa')](function(){const _0x1ee586=_0x310051;return _0x3f9054[_0x1ee586('0x6')][_0x1ee586('0x8')](_0x3dbf4c,_0x140804)[_0x1ee586('0x15')](function(){const _0x4e243f=_0x1ee586;logger['info'](_0x4e243f('0x0'),_0x3dbf4c,_0x140804);})['catch'](function(_0x31e993){const _0x52bbcb=_0x1ee586;logger[_0x52bbcb('0x11')](JSON[_0x52bbcb('0x19')](_0x31e993));});});},Migration[_0x3df2ae('0x1c')][_0x3df2ae('0x1b')]=function(_0x439c52){const _0x3f6d41=_0x3df2ae,_0x45f73f=this;this[_0x3f6d41('0x1')][_0x3f6d41('0xa')](function(){const _0x3876a2=_0x3f6d41;return _0x45f73f['queryInterface']['sequelize'][_0x3876a2('0x1b')](_0x439c52)[_0x3876a2('0x15')](function(){const _0x181306=_0x3876a2;logger[_0x181306('0x11')](_0x181306('0x16'),_0x439c52);})[_0x3876a2('0x1d')](function(_0x595041){const _0x563b9f=_0x3876a2;logger['info'](JSON[_0x563b9f('0x19')](_0x595041));});});},Migration[_0x3df2ae('0x1c')]['removeColumn']=function(_0x45f246,_0x24d78b){const _0x3b2177=_0x3df2ae,_0xaadb20=this;this[_0x3b2177('0x1')]['enqueue'](function(){const _0x5a064e=_0x3b2177;return _0xaadb20[_0x5a064e('0x6')]['removeColumn'](_0x45f246,_0x24d78b)[_0x5a064e('0x15')](function(){const _0x23799c=_0x5a064e;logger[_0x23799c('0x11')](_0x23799c('0x17'),_0x24d78b,_0x45f246);})[_0x5a064e('0x1d')](function(_0x25435c){const _0x3b03da=_0x5a064e;logger[_0x3b03da('0x11')](util['inspect'](_0x25435c,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x3df2ae('0xb')]=function(_0x12c1d9,_0x147495,_0x570623){const _0x5008e6=_0x3df2ae,_0x3c4469=this;this[_0x5008e6('0x1')]['enqueue'](function(){const _0x56c8df=_0x5008e6;return _0x3c4469[_0x56c8df('0x6')]['renameColumn'](_0x12c1d9,_0x147495,_0x570623)['then'](function(){const _0x1225da=_0x56c8df;logger['info'](_0x1225da('0xc'),_0x147495,_0x570623,_0x12c1d9);})['catch'](function(_0x6707f4){const _0x41aff2=_0x56c8df;logger[_0x41aff2('0x11')](util['inspect'](_0x6707f4,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0xef5541){const _0x22bfe0=_0x3df2ae;this[_0x22bfe0('0x1')][_0x22bfe0('0xa')](function(){return _0xef5541();});},module['exports']={'up':function(_0x1b8b1f,_0x219b6a){return new Promise(function(_0x271c9d){const _0x45b370=a995_0x3700,_0x48d20a=new Migration(_0x1b8b1f);_0x48d20a[_0x45b370('0x12')](_0x45b370('0x13'),'loginMailFrequency',{'type':_0x219b6a[_0x45b370('0x3')],'defaultValue':0xa}),_0x48d20a[_0x45b370('0x1b')]('UPDATE\x20tools_actions\x20SET\x20tools_actions.data5\x20=\x20\x225\x22\x20WHERE\x20tools_actions.action\x20=\x20\x22urlForward\x22'),_0x48d20a['final'](_0x271c9d);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.13.js b/server/migrations/2.4.13.js index 751fbdc..a3da549 100644 --- a/server/migrations/2.4.13.js +++ b/server/migrations/2.4.13.js @@ -1 +1 @@ -const a996_0x194e=['prototype','dropTable','indicesType','renameColumn','queryInterface','info','stringify','addIndex','sequence','addColumn','enqueue','then','exports','removeColumn','migration','tail','table\x20dropped\x20%s','final','catch','removeIndex\x20%s\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','changeColumn','query\x20%s','util','BOOLEAN','inspect','removeIndex','Removed\x20column\x20%s\x20from\x20%s','query','Added\x20column\x20%s\x20to\x20%s','indexName'];(function(_0x11f322,_0x194e04){const _0x1be5e3=function(_0x21c80c){while(--_0x21c80c){_0x11f322['push'](_0x11f322['shift']());}};_0x1be5e3(++_0x194e04);}(a996_0x194e,0xd4));const a996_0x1be5=function(_0x11f322,_0x194e04){_0x11f322=_0x11f322-0x0;let _0x1be5e3=a996_0x194e[_0x11f322];return _0x1be5e3;};const _0x21bdef=a996_0x1be5;'use strict';const util=require(_0x21bdef('0x1c')),logger=require('../config/logger')(_0x21bdef('0x13')),Sequence=function(){};Sequence[_0x21bdef('0x5')]['enqueue']=function(_0x21c80c){const _0x4d474d=_0x21bdef;this[_0x4d474d('0x14')]=this[_0x4d474d('0x14')]?this[_0x4d474d('0x14')]['finally'](_0x21c80c):_0x21c80c();};const Migration=function(_0x5239ef){const _0x1edcd8=_0x21bdef;this[_0x1edcd8('0x9')]=_0x5239ef,this[_0x1edcd8('0xd')]=new Sequence();};Migration[_0x21bdef('0x5')][_0x21bdef('0x1a')]=function(_0x31bca1,_0x180a72,_0x55940d){const _0x29ad5b=_0x21bdef,_0x1a5496=this;this[_0x29ad5b('0xd')][_0x29ad5b('0xf')](function(){const _0x5646a0=_0x29ad5b;return _0x1a5496['queryInterface']['changeColumn'](_0x31bca1,_0x180a72,_0x55940d)[_0x5646a0('0x10')](function(){const _0x415c06=_0x5646a0;logger[_0x415c06('0xa')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x180a72,_0x31bca1);})[_0x5646a0('0x17')](function(_0x5919be){const _0x36830b=_0x5646a0;logger[_0x36830b('0xa')](JSON['stringify'](_0x5919be));});});},Migration[_0x21bdef('0x5')][_0x21bdef('0xe')]=function(_0x1249b8,_0x55cc61,_0x514f76){const _0x16df76=_0x21bdef,_0x5701ec=this;this[_0x16df76('0xd')]['enqueue'](function(){const _0x370a70=_0x16df76;return _0x5701ec[_0x370a70('0x9')][_0x370a70('0xe')](_0x1249b8,_0x55cc61,_0x514f76)['then'](function(){const _0x56c538=_0x370a70;logger['info'](_0x56c538('0x3'),_0x55cc61,_0x1249b8);})['catch'](function(_0x35868f){const _0xab18d4=_0x370a70;logger[_0xab18d4('0xa')](JSON[_0xab18d4('0xb')](_0x35868f));});});},Migration[_0x21bdef('0x5')]['dropTable']=function(_0x54aec2){const _0x3bfced=_0x21bdef,_0x335a49=this;this[_0x3bfced('0xd')]['enqueue'](function(){const _0x29df52=_0x3bfced;return _0x335a49[_0x29df52('0x9')][_0x29df52('0x6')](_0x54aec2,{'force':!![]})['then'](function(){const _0x2a02d9=_0x29df52;logger[_0x2a02d9('0xa')](_0x2a02d9('0x15'),_0x54aec2);})[_0x29df52('0x17')](function(_0x42b0e7){const _0x522f12=_0x29df52;logger['info'](JSON[_0x522f12('0xb')](_0x42b0e7));});});},Migration[_0x21bdef('0x5')][_0x21bdef('0xc')]=function(_0x16d374,_0x1034ac,_0xe1802){const _0x506f8d=_0x21bdef,_0x87fbf9=this;this[_0x506f8d('0xd')][_0x506f8d('0xf')](function(){const _0x32aa9b=_0x506f8d;return _0x87fbf9[_0x32aa9b('0x9')][_0x32aa9b('0xc')](_0x16d374,_0x1034ac,{'indexName':_0xe1802[_0x32aa9b('0x4')],'indicesType':_0xe1802[_0x32aa9b('0x7')]})[_0x32aa9b('0x10')](function(){const _0x11e4f9=_0x32aa9b;logger[_0x11e4f9('0xa')]('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x16d374,_0x1034ac['join'](','),_0xe1802['indexName'],_0xe1802[_0x11e4f9('0x7')]);})[_0x32aa9b('0x17')](function(_0x1748a1){const _0x30b06f=_0x32aa9b;logger[_0x30b06f('0xa')](JSON[_0x30b06f('0xb')](_0x1748a1));});});},Migration[_0x21bdef('0x5')]['removeIndex']=function(_0x24ce81,_0x490cd7){const _0x453c7d=_0x21bdef,_0x178f8f=this;this[_0x453c7d('0xd')][_0x453c7d('0xf')](function(){const _0x4bd811=_0x453c7d;return _0x178f8f[_0x4bd811('0x9')][_0x4bd811('0x0')](_0x24ce81,_0x490cd7)[_0x4bd811('0x10')](function(){const _0x42e5b4=_0x4bd811;logger[_0x42e5b4('0xa')](_0x42e5b4('0x18'),_0x24ce81,_0x490cd7);})[_0x4bd811('0x17')](function(_0x5442ab){const _0x287259=_0x4bd811;logger[_0x287259('0xa')](JSON[_0x287259('0xb')](_0x5442ab));});});},Migration['prototype'][_0x21bdef('0x2')]=function(_0x29f4a4){const _0x34b341=_0x21bdef,_0x40d31e=this;this['sequence'][_0x34b341('0xf')](function(){const _0x2d7a19=_0x34b341;return _0x40d31e['queryInterface']['sequelize'][_0x2d7a19('0x2')](_0x29f4a4)['then'](function(){const _0x4bd048=_0x2d7a19;logger[_0x4bd048('0xa')](_0x4bd048('0x1b'),_0x29f4a4);})[_0x2d7a19('0x17')](function(_0x208658){const _0x2cb59e=_0x2d7a19;logger['info'](JSON[_0x2cb59e('0xb')](_0x208658));});});},Migration[_0x21bdef('0x5')][_0x21bdef('0x12')]=function(_0x4129ad,_0x178c31){const _0x3ce242=this;this['sequence']['enqueue'](function(){const _0x1c5b96=a996_0x1be5;return _0x3ce242['queryInterface']['removeColumn'](_0x4129ad,_0x178c31)[_0x1c5b96('0x10')](function(){const _0x2b9351=_0x1c5b96;logger[_0x2b9351('0xa')](_0x2b9351('0x1'),_0x178c31,_0x4129ad);})[_0x1c5b96('0x17')](function(_0x3fda9f){const _0x43b7ed=_0x1c5b96;logger[_0x43b7ed('0xa')](util[_0x43b7ed('0x1e')](_0x3fda9f,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x21bdef('0x8')]=function(_0x2c1535,_0x28065d,_0x557a3e){const _0x357138=_0x21bdef,_0x293ebf=this;this[_0x357138('0xd')][_0x357138('0xf')](function(){const _0x4f4031=_0x357138;return _0x293ebf[_0x4f4031('0x9')][_0x4f4031('0x8')](_0x2c1535,_0x28065d,_0x557a3e)['then'](function(){const _0x4bc38d=_0x4f4031;logger[_0x4bc38d('0xa')](_0x4bc38d('0x19'),_0x28065d,_0x557a3e,_0x2c1535);})[_0x4f4031('0x17')](function(_0x2c80e5){const _0x1acea6=_0x4f4031;logger[_0x1acea6('0xa')](util[_0x1acea6('0x1e')](_0x2c80e5,{'showHidden':![],'depth':null}));});});},Migration[_0x21bdef('0x5')][_0x21bdef('0x16')]=function(_0x1a86de){const _0x573724=_0x21bdef;this[_0x573724('0xd')][_0x573724('0xf')](function(){return _0x1a86de();});},module[_0x21bdef('0x11')]={'up':function(_0x97941d,_0x1a5263){return new Promise(function(_0x20d171){const _0x12c59e=a996_0x1be5,_0x590235=new Migration(_0x97941d);_0x590235[_0x12c59e('0xe')]('jscripty_projects','sendUnpauseOnSubmit',{'type':_0x1a5263[_0x12c59e('0x1d')],'defaultValue':![]}),_0x590235[_0x12c59e('0x16')](_0x20d171);});},'down':function(){}}; \ No newline at end of file +const a996_0x34d8=['jscripty_projects','enqueue','removeIndex\x20%s\x20%s','join','addIndex','queryInterface','migration','query\x20%s','exports','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','sequelize','then','indexName','table\x20dropped\x20%s','changeColumn','dropTable','sendUnpauseOnSubmit','addIndex\x20%s\x20%s\x20%s\x20[%s]','catch','renameColumn','final','Removed\x20column\x20%s\x20from\x20%s','info','query','finally','util','addColumn','stringify','indicesType','tail','prototype','removeIndex','removeColumn','sequence'];(function(_0x5d7361,_0x34d8fe){const _0x15a4ea=function(_0x42dd80){while(--_0x42dd80){_0x5d7361['push'](_0x5d7361['shift']());}};_0x15a4ea(++_0x34d8fe);}(a996_0x34d8,0xe2));const a996_0x15a4=function(_0x5d7361,_0x34d8fe){_0x5d7361=_0x5d7361-0x0;let _0x15a4ea=a996_0x34d8[_0x5d7361];return _0x15a4ea;};const _0x4f213d=a996_0x15a4;'use strict';const util=require(_0x4f213d('0x3')),logger=require('../config/logger')(_0x4f213d('0x12')),Sequence=function(){};Sequence['prototype'][_0x4f213d('0xd')]=function(_0x42dd80){const _0x54d040=_0x4f213d;this[_0x54d040('0x7')]=this[_0x54d040('0x7')]?this[_0x54d040('0x7')][_0x54d040('0x2')](_0x42dd80):_0x42dd80();};const Migration=function(_0x5ae5c2){const _0x563454=_0x4f213d;this[_0x563454('0x11')]=_0x5ae5c2,this[_0x563454('0xb')]=new Sequence();};Migration[_0x4f213d('0x8')][_0x4f213d('0x1a')]=function(_0xf7f587,_0x3b1af2,_0x4b22c4){const _0x28912b=_0x4f213d,_0x48be03=this;this[_0x28912b('0xb')][_0x28912b('0xd')](function(){const _0x179df3=_0x28912b;return _0x48be03[_0x179df3('0x11')][_0x179df3('0x1a')](_0xf7f587,_0x3b1af2,_0x4b22c4)[_0x179df3('0x17')](function(){const _0x4f7fdc=_0x179df3;logger[_0x4f7fdc('0x0')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x3b1af2,_0xf7f587);})[_0x179df3('0x1e')](function(_0x29d72a){const _0x226f81=_0x179df3;logger['info'](JSON[_0x226f81('0x5')](_0x29d72a));});});},Migration[_0x4f213d('0x8')]['addColumn']=function(_0x2f0c55,_0xe9fd66,_0x451513){const _0x3288ee=_0x4f213d,_0xf3622b=this;this['sequence'][_0x3288ee('0xd')](function(){const _0x3a3c8b=_0x3288ee;return _0xf3622b[_0x3a3c8b('0x11')][_0x3a3c8b('0x4')](_0x2f0c55,_0xe9fd66,_0x451513)[_0x3a3c8b('0x17')](function(){const _0x1ce8ab=_0x3a3c8b;logger[_0x1ce8ab('0x0')]('Added\x20column\x20%s\x20to\x20%s',_0xe9fd66,_0x2f0c55);})[_0x3a3c8b('0x1e')](function(_0x18838e){const _0x310f52=_0x3a3c8b;logger[_0x310f52('0x0')](JSON[_0x310f52('0x5')](_0x18838e));});});},Migration[_0x4f213d('0x8')]['dropTable']=function(_0x5caac0){const _0x444b83=_0x4f213d,_0x322806=this;this[_0x444b83('0xb')][_0x444b83('0xd')](function(){const _0x4de377=_0x444b83;return _0x322806[_0x4de377('0x11')][_0x4de377('0x1b')](_0x5caac0,{'force':!![]})[_0x4de377('0x17')](function(){const _0x264aef=_0x4de377;logger[_0x264aef('0x0')](_0x264aef('0x19'),_0x5caac0);})[_0x4de377('0x1e')](function(_0x20abeb){const _0x52d833=_0x4de377;logger[_0x52d833('0x0')](JSON['stringify'](_0x20abeb));});});},Migration[_0x4f213d('0x8')][_0x4f213d('0x10')]=function(_0x1b9cd1,_0x1ce88d,_0x3a71a5){const _0x47cd6a=_0x4f213d,_0x30b767=this;this[_0x47cd6a('0xb')][_0x47cd6a('0xd')](function(){const _0x355506=_0x47cd6a;return _0x30b767['queryInterface'][_0x355506('0x10')](_0x1b9cd1,_0x1ce88d,{'indexName':_0x3a71a5[_0x355506('0x18')],'indicesType':_0x3a71a5[_0x355506('0x6')]})['then'](function(){const _0x297189=_0x355506;logger['info'](_0x297189('0x1d'),_0x1b9cd1,_0x1ce88d[_0x297189('0xf')](','),_0x3a71a5[_0x297189('0x18')],_0x3a71a5[_0x297189('0x6')]);})['catch'](function(_0x378142){const _0x1153c2=_0x355506;logger[_0x1153c2('0x0')](JSON[_0x1153c2('0x5')](_0x378142));});});},Migration[_0x4f213d('0x8')][_0x4f213d('0x9')]=function(_0x2ac999,_0x1524a0){const _0x1b42b8=_0x4f213d,_0x22ecf9=this;this[_0x1b42b8('0xb')][_0x1b42b8('0xd')](function(){const _0x3a8cf8=_0x1b42b8;return _0x22ecf9[_0x3a8cf8('0x11')][_0x3a8cf8('0x9')](_0x2ac999,_0x1524a0)[_0x3a8cf8('0x17')](function(){const _0x397d57=_0x3a8cf8;logger[_0x397d57('0x0')](_0x397d57('0xe'),_0x2ac999,_0x1524a0);})[_0x3a8cf8('0x1e')](function(_0x122444){const _0x32c5c7=_0x3a8cf8;logger[_0x32c5c7('0x0')](JSON[_0x32c5c7('0x5')](_0x122444));});});},Migration['prototype']['query']=function(_0x3786d9){const _0x4aac0f=_0x4f213d,_0x54527f=this;this[_0x4aac0f('0xb')][_0x4aac0f('0xd')](function(){const _0x223581=_0x4aac0f;return _0x54527f[_0x223581('0x11')][_0x223581('0x16')][_0x223581('0x1')](_0x3786d9)[_0x223581('0x17')](function(){const _0x1e8e06=_0x223581;logger['info'](_0x1e8e06('0x13'),_0x3786d9);})[_0x223581('0x1e')](function(_0x48af88){const _0x1d6149=_0x223581;logger[_0x1d6149('0x0')](JSON[_0x1d6149('0x5')](_0x48af88));});});},Migration['prototype'][_0x4f213d('0xa')]=function(_0x6b3983,_0x49e27e){const _0x222c17=_0x4f213d,_0x2836dd=this;this[_0x222c17('0xb')][_0x222c17('0xd')](function(){const _0x4d9e59=_0x222c17;return _0x2836dd[_0x4d9e59('0x11')][_0x4d9e59('0xa')](_0x6b3983,_0x49e27e)[_0x4d9e59('0x17')](function(){const _0x26499f=_0x4d9e59;logger[_0x26499f('0x0')](_0x26499f('0x21'),_0x49e27e,_0x6b3983);})[_0x4d9e59('0x1e')](function(_0x59efac){const _0x5c473a=_0x4d9e59;logger[_0x5c473a('0x0')](util['inspect'](_0x59efac,{'showHidden':![],'depth':null}));});});},Migration[_0x4f213d('0x8')][_0x4f213d('0x1f')]=function(_0x531fae,_0x2272f6,_0x3a67df){const _0x397ad0=_0x4f213d,_0x25d64a=this;this[_0x397ad0('0xb')][_0x397ad0('0xd')](function(){const _0xf39915=_0x397ad0;return _0x25d64a[_0xf39915('0x11')][_0xf39915('0x1f')](_0x531fae,_0x2272f6,_0x3a67df)[_0xf39915('0x17')](function(){const _0x545c3a=_0xf39915;logger[_0x545c3a('0x0')](_0x545c3a('0x15'),_0x2272f6,_0x3a67df,_0x531fae);})['catch'](function(_0x184cd4){logger['info'](util['inspect'](_0x184cd4,{'showHidden':![],'depth':null}));});});},Migration[_0x4f213d('0x8')]['final']=function(_0x2ac95d){const _0x43c792=_0x4f213d;this[_0x43c792('0xb')][_0x43c792('0xd')](function(){return _0x2ac95d();});},module[_0x4f213d('0x14')]={'up':function(_0x1fb31d,_0x209ed5){return new Promise(function(_0x5a8db5){const _0x207086=a996_0x15a4,_0x30f199=new Migration(_0x1fb31d);_0x30f199['addColumn'](_0x207086('0xc'),_0x207086('0x1c'),{'type':_0x209ed5['BOOLEAN'],'defaultValue':![]}),_0x30f199[_0x207086('0x20')](_0x5a8db5);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.14.js b/server/migrations/2.4.14.js index 629ba6f..76ee3ff 100644 --- a/server/migrations/2.4.14.js +++ b/server/migrations/2.4.14.js @@ -1 +1 @@ -const a997_0x4572=['addIndex','finally','catch','query\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','join','changeColumn','queryInterface','removeIndex','sequelize','info','util','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','migration','prototype','query','addIndex\x20%s\x20%s\x20%s\x20[%s]','indicesType','inspect','removeIndex\x20%s\x20%s','addColumn','stringify','dropTable','../config/logger','indexName','Added\x20column\x20%s\x20to\x20%s','then','renameColumn','sequence','removeColumn','enqueue','final'];(function(_0x44f713,_0x4572cb){const _0x134af1=function(_0x1dd42c){while(--_0x1dd42c){_0x44f713['push'](_0x44f713['shift']());}};_0x134af1(++_0x4572cb);}(a997_0x4572,0xd1));const a997_0x134a=function(_0x44f713,_0x4572cb){_0x44f713=_0x44f713-0x0;let _0x134af1=a997_0x4572[_0x44f713];return _0x134af1;};const _0x4f99bf=a997_0x134a;'use strict';const util=require(_0x4f99bf('0x1a')),logger=require(_0x4f99bf('0x6'))(_0x4f99bf('0x1c')),Sequence=function(){};Sequence[_0x4f99bf('0x1d')][_0x4f99bf('0xd')]=function(_0x1dd42c){const _0x1778dc=_0x4f99bf;this['tail']=this['tail']?this['tail'][_0x1778dc('0x10')](_0x1dd42c):_0x1dd42c();};const Migration=function(_0x2b5e1a){const _0x5c315a=_0x4f99bf;this[_0x5c315a('0x16')]=_0x2b5e1a,this[_0x5c315a('0xb')]=new Sequence();};Migration[_0x4f99bf('0x1d')][_0x4f99bf('0x15')]=function(_0x3c5d8e,_0x521151,_0x56f6e9){const _0x284015=_0x4f99bf,_0x29ad56=this;this[_0x284015('0xb')][_0x284015('0xd')](function(){const _0x107150=_0x284015;return _0x29ad56[_0x107150('0x16')][_0x107150('0x15')](_0x3c5d8e,_0x521151,_0x56f6e9)[_0x107150('0x9')](function(){const _0x5e5549=_0x107150;logger['info'](_0x5e5549('0x13'),_0x521151,_0x3c5d8e);})['catch'](function(_0x2ab265){const _0x33231c=_0x107150;logger[_0x33231c('0x19')](JSON[_0x33231c('0x4')](_0x2ab265));});});},Migration[_0x4f99bf('0x1d')][_0x4f99bf('0x3')]=function(_0x38226e,_0x517be2,_0x63f13a){const _0x408320=_0x4f99bf,_0x564454=this;this[_0x408320('0xb')][_0x408320('0xd')](function(){const _0x2f3f3d=_0x408320;return _0x564454[_0x2f3f3d('0x16')]['addColumn'](_0x38226e,_0x517be2,_0x63f13a)[_0x2f3f3d('0x9')](function(){const _0x1067bb=_0x2f3f3d;logger[_0x1067bb('0x19')](_0x1067bb('0x8'),_0x517be2,_0x38226e);})[_0x2f3f3d('0x11')](function(_0x497db1){const _0x19dfce=_0x2f3f3d;logger[_0x19dfce('0x19')](JSON[_0x19dfce('0x4')](_0x497db1));});});},Migration[_0x4f99bf('0x1d')][_0x4f99bf('0x5')]=function(_0x2c4fce){const _0x10b9a6=_0x4f99bf,_0x316603=this;this[_0x10b9a6('0xb')][_0x10b9a6('0xd')](function(){const _0x1ee661=_0x10b9a6;return _0x316603[_0x1ee661('0x16')][_0x1ee661('0x5')](_0x2c4fce,{'force':!![]})['then'](function(){const _0x2fe2a9=_0x1ee661;logger[_0x2fe2a9('0x19')]('table\x20dropped\x20%s',_0x2c4fce);})[_0x1ee661('0x11')](function(_0x5793c5){const _0x590792=_0x1ee661;logger[_0x590792('0x19')](JSON[_0x590792('0x4')](_0x5793c5));});});},Migration[_0x4f99bf('0x1d')][_0x4f99bf('0xf')]=function(_0x369615,_0x95df6c,_0x5ebb0b){const _0x1bfacd=this;this['sequence']['enqueue'](function(){const _0x3826fd=a997_0x134a;return _0x1bfacd['queryInterface'][_0x3826fd('0xf')](_0x369615,_0x95df6c,{'indexName':_0x5ebb0b[_0x3826fd('0x7')],'indicesType':_0x5ebb0b[_0x3826fd('0x0')]})[_0x3826fd('0x9')](function(){const _0x4a14e4=_0x3826fd;logger[_0x4a14e4('0x19')](_0x4a14e4('0x1f'),_0x369615,_0x95df6c[_0x4a14e4('0x14')](','),_0x5ebb0b[_0x4a14e4('0x7')],_0x5ebb0b[_0x4a14e4('0x0')]);})[_0x3826fd('0x11')](function(_0x49a418){const _0x54546f=_0x3826fd;logger[_0x54546f('0x19')](JSON[_0x54546f('0x4')](_0x49a418));});});},Migration[_0x4f99bf('0x1d')][_0x4f99bf('0x17')]=function(_0x1afd6f,_0x34ebf7){const _0x3edfc5=_0x4f99bf,_0x31f1a6=this;this[_0x3edfc5('0xb')]['enqueue'](function(){const _0x1556fb=_0x3edfc5;return _0x31f1a6['queryInterface'][_0x1556fb('0x17')](_0x1afd6f,_0x34ebf7)[_0x1556fb('0x9')](function(){const _0x82e7d7=_0x1556fb;logger[_0x82e7d7('0x19')](_0x82e7d7('0x2'),_0x1afd6f,_0x34ebf7);})['catch'](function(_0x1e4b24){const _0x37953e=_0x1556fb;logger[_0x37953e('0x19')](JSON['stringify'](_0x1e4b24));});});},Migration['prototype'][_0x4f99bf('0x1e')]=function(_0x547908){const _0x221e9d=_0x4f99bf,_0x46517a=this;this[_0x221e9d('0xb')][_0x221e9d('0xd')](function(){const _0x562611=_0x221e9d;return _0x46517a['queryInterface'][_0x562611('0x18')][_0x562611('0x1e')](_0x547908)['then'](function(){const _0x211b96=_0x562611;logger[_0x211b96('0x19')](_0x211b96('0x12'),_0x547908);})[_0x562611('0x11')](function(_0x2f2c71){const _0x14349e=_0x562611;logger[_0x14349e('0x19')](JSON[_0x14349e('0x4')](_0x2f2c71));});});},Migration[_0x4f99bf('0x1d')][_0x4f99bf('0xc')]=function(_0xb38ddb,_0x52524c){const _0x5c621f=_0x4f99bf,_0x41e8fe=this;this[_0x5c621f('0xb')][_0x5c621f('0xd')](function(){const _0x489dae=_0x5c621f;return _0x41e8fe[_0x489dae('0x16')]['removeColumn'](_0xb38ddb,_0x52524c)[_0x489dae('0x9')](function(){const _0x26e518=_0x489dae;logger[_0x26e518('0x19')]('Removed\x20column\x20%s\x20from\x20%s',_0x52524c,_0xb38ddb);})[_0x489dae('0x11')](function(_0x49cfbe){const _0x402a9a=_0x489dae;logger[_0x402a9a('0x19')](util[_0x402a9a('0x1')](_0x49cfbe,{'showHidden':![],'depth':null}));});});},Migration[_0x4f99bf('0x1d')][_0x4f99bf('0xa')]=function(_0x1a3e1f,_0x57c98d,_0x322c69){const _0x6a34f4=_0x4f99bf,_0x31159a=this;this[_0x6a34f4('0xb')][_0x6a34f4('0xd')](function(){const _0x2913ec=_0x6a34f4;return _0x31159a[_0x2913ec('0x16')]['renameColumn'](_0x1a3e1f,_0x57c98d,_0x322c69)[_0x2913ec('0x9')](function(){const _0xe4b8be=_0x2913ec;logger['info'](_0xe4b8be('0x1b'),_0x57c98d,_0x322c69,_0x1a3e1f);})[_0x2913ec('0x11')](function(_0x37b664){const _0x1e9390=_0x2913ec;logger[_0x1e9390('0x19')](util[_0x1e9390('0x1')](_0x37b664,{'showHidden':![],'depth':null}));});});},Migration[_0x4f99bf('0x1d')]['final']=function(_0x401d1b){const _0x3aa5dc=_0x4f99bf;this[_0x3aa5dc('0xb')][_0x3aa5dc('0xd')](function(){return _0x401d1b();});},module['exports']={'up':function(_0x2a1fee){return new Promise(function(_0x30e04a){const _0x16a402=a997_0x134a,_0x43e94c=new Migration(_0x2a1fee);_0x43e94c[_0x16a402('0xe')](_0x30e04a);});},'down':function(){}}; \ No newline at end of file +const a997_0x5b44=['enqueue','Changed\x20column\x20%s\x20in\x20table\x20%s','addColumn','final','indicesType','removeIndex\x20%s\x20%s','../config/logger','query','Added\x20column\x20%s\x20to\x20%s','queryInterface','migration','exports','stringify','then','join','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','tail','info','removeIndex','removeColumn','catch','util','finally','indexName','renameColumn','dropTable','changeColumn','prototype','sequence','Removed\x20column\x20%s\x20from\x20%s','inspect','addIndex\x20%s\x20%s\x20%s\x20[%s]'];(function(_0x38c05c,_0x5b4410){const _0x582085=function(_0x234386){while(--_0x234386){_0x38c05c['push'](_0x38c05c['shift']());}};_0x582085(++_0x5b4410);}(a997_0x5b44,0x91));const a997_0x5820=function(_0x38c05c,_0x5b4410){_0x38c05c=_0x38c05c-0x0;let _0x582085=a997_0x5b44[_0x38c05c];return _0x582085;};const _0x286e76=a997_0x5820;'use strict';const util=require(_0x286e76('0x4')),logger=require(_0x286e76('0x15'))(_0x286e76('0x19')),Sequence=function(){};Sequence[_0x286e76('0xa')]['enqueue']=function(_0x234386){const _0xcb992e=_0x286e76;this['tail']=this['tail']?this[_0xcb992e('0x1f')][_0xcb992e('0x5')](_0x234386):_0x234386();};const Migration=function(_0x4007bf){const _0x36a2c2=_0x286e76;this[_0x36a2c2('0x18')]=_0x4007bf,this[_0x36a2c2('0xb')]=new Sequence();};Migration['prototype'][_0x286e76('0x9')]=function(_0x123586,_0x5dc9e9,_0x437354){const _0x104b6a=_0x286e76,_0x154a00=this;this[_0x104b6a('0xb')][_0x104b6a('0xf')](function(){const _0x8cbec2=_0x104b6a;return _0x154a00[_0x8cbec2('0x18')][_0x8cbec2('0x9')](_0x123586,_0x5dc9e9,_0x437354)[_0x8cbec2('0x1c')](function(){const _0x9265a2=_0x8cbec2;logger[_0x9265a2('0x0')](_0x9265a2('0x10'),_0x5dc9e9,_0x123586);})[_0x8cbec2('0x3')](function(_0x2c63d2){const _0x4cf5c3=_0x8cbec2;logger['info'](JSON[_0x4cf5c3('0x1b')](_0x2c63d2));});});},Migration[_0x286e76('0xa')][_0x286e76('0x11')]=function(_0x996201,_0x1591c7,_0x52baa3){const _0x315cfc=_0x286e76,_0x5c7596=this;this['sequence'][_0x315cfc('0xf')](function(){const _0x3e7253=_0x315cfc;return _0x5c7596['queryInterface'][_0x3e7253('0x11')](_0x996201,_0x1591c7,_0x52baa3)[_0x3e7253('0x1c')](function(){const _0x32e52d=_0x3e7253;logger[_0x32e52d('0x0')](_0x32e52d('0x17'),_0x1591c7,_0x996201);})[_0x3e7253('0x3')](function(_0x3d7e38){const _0x4f0e54=_0x3e7253;logger[_0x4f0e54('0x0')](JSON[_0x4f0e54('0x1b')](_0x3d7e38));});});},Migration['prototype'][_0x286e76('0x8')]=function(_0x259f24){const _0x20d8a2=_0x286e76,_0x4abacc=this;this[_0x20d8a2('0xb')]['enqueue'](function(){const _0xf36444=_0x20d8a2;return _0x4abacc[_0xf36444('0x18')][_0xf36444('0x8')](_0x259f24,{'force':!![]})[_0xf36444('0x1c')](function(){const _0x2fe8dd=_0xf36444;logger[_0x2fe8dd('0x0')]('table\x20dropped\x20%s',_0x259f24);})[_0xf36444('0x3')](function(_0x5586f0){const _0x139cd5=_0xf36444;logger[_0x139cd5('0x0')](JSON['stringify'](_0x5586f0));});});},Migration[_0x286e76('0xa')]['addIndex']=function(_0x591fb5,_0x402f9d,_0x419a8d){const _0x1329d7=_0x286e76,_0x37ea49=this;this[_0x1329d7('0xb')][_0x1329d7('0xf')](function(){const _0x1dec35=_0x1329d7;return _0x37ea49[_0x1dec35('0x18')]['addIndex'](_0x591fb5,_0x402f9d,{'indexName':_0x419a8d[_0x1dec35('0x6')],'indicesType':_0x419a8d[_0x1dec35('0x13')]})['then'](function(){const _0x471f1a=_0x1dec35;logger[_0x471f1a('0x0')](_0x471f1a('0xe'),_0x591fb5,_0x402f9d[_0x471f1a('0x1d')](','),_0x419a8d[_0x471f1a('0x6')],_0x419a8d['indicesType']);})[_0x1dec35('0x3')](function(_0x859d3c){const _0x2f4b4a=_0x1dec35;logger[_0x2f4b4a('0x0')](JSON[_0x2f4b4a('0x1b')](_0x859d3c));});});},Migration['prototype'][_0x286e76('0x1')]=function(_0x525271,_0x5f035d){const _0x495d08=_0x286e76,_0x2b9b13=this;this[_0x495d08('0xb')][_0x495d08('0xf')](function(){const _0x399d7f=_0x495d08;return _0x2b9b13[_0x399d7f('0x18')][_0x399d7f('0x1')](_0x525271,_0x5f035d)[_0x399d7f('0x1c')](function(){const _0x58900f=_0x399d7f;logger[_0x58900f('0x0')](_0x58900f('0x14'),_0x525271,_0x5f035d);})[_0x399d7f('0x3')](function(_0x535b8d){const _0x1c963a=_0x399d7f;logger[_0x1c963a('0x0')](JSON[_0x1c963a('0x1b')](_0x535b8d));});});},Migration[_0x286e76('0xa')]['query']=function(_0x1cf2de){const _0x291910=_0x286e76,_0x5ad52f=this;this[_0x291910('0xb')][_0x291910('0xf')](function(){const _0x1ecb30=_0x291910;return _0x5ad52f['queryInterface']['sequelize'][_0x1ecb30('0x16')](_0x1cf2de)[_0x1ecb30('0x1c')](function(){const _0x3cdd3b=_0x1ecb30;logger[_0x3cdd3b('0x0')]('query\x20%s',_0x1cf2de);})[_0x1ecb30('0x3')](function(_0x213022){const _0x1f8804=_0x1ecb30;logger[_0x1f8804('0x0')](JSON[_0x1f8804('0x1b')](_0x213022));});});},Migration[_0x286e76('0xa')]['removeColumn']=function(_0x5d3e32,_0x17cccf){const _0x177d92=_0x286e76,_0x4a5474=this;this[_0x177d92('0xb')][_0x177d92('0xf')](function(){const _0x2e0295=_0x177d92;return _0x4a5474[_0x2e0295('0x18')][_0x2e0295('0x2')](_0x5d3e32,_0x17cccf)['then'](function(){const _0x45ad8d=_0x2e0295;logger[_0x45ad8d('0x0')](_0x45ad8d('0xc'),_0x17cccf,_0x5d3e32);})[_0x2e0295('0x3')](function(_0x2755f2){logger['info'](util['inspect'](_0x2755f2,{'showHidden':![],'depth':null}));});});},Migration[_0x286e76('0xa')][_0x286e76('0x7')]=function(_0x1651c7,_0x18b7ef,_0x3b0548){const _0x1a49c6=_0x286e76,_0x24da9f=this;this[_0x1a49c6('0xb')][_0x1a49c6('0xf')](function(){const _0x25d645=_0x1a49c6;return _0x24da9f[_0x25d645('0x18')][_0x25d645('0x7')](_0x1651c7,_0x18b7ef,_0x3b0548)['then'](function(){const _0x563f9b=_0x25d645;logger['info'](_0x563f9b('0x1e'),_0x18b7ef,_0x3b0548,_0x1651c7);})[_0x25d645('0x3')](function(_0x153066){const _0x10e92c=_0x25d645;logger['info'](util[_0x10e92c('0xd')](_0x153066,{'showHidden':![],'depth':null}));});});},Migration[_0x286e76('0xa')][_0x286e76('0x12')]=function(_0x1ad542){const _0x55f974=_0x286e76;this['sequence'][_0x55f974('0xf')](function(){return _0x1ad542();});},module[_0x286e76('0x1a')]={'up':function(_0x256ac6){return new Promise(function(_0x4a0543){const _0x363b63=new Migration(_0x256ac6);_0x363b63['final'](_0x4a0543);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.15.js b/server/migrations/2.4.15.js index 5733b5e..c203912 100644 --- a/server/migrations/2.4.15.js +++ b/server/migrations/2.4.15.js @@ -1 +1 @@ -const a998_0x325d=['removeIndex','removeColumn','queryInterface','Changed\x20column\x20%s\x20in\x20table\x20%s','renameColumn','then','addIndex','UPDATE\x20sms_accounts\x20SET\x20baseUrl\x20=\x20\x22https://sms.csc.lv\x22\x20WHERE\x20type\x20=\x20\x22csc\x22','addColumn','tail','changeColumn','final','enqueue','table\x20dropped\x20%s','Added\x20column\x20%s\x20to\x20%s','exports','migration','prototype','join','query\x20%s','util','indexName','sequelize','stringify','catch','addIndex\x20%s\x20%s\x20%s\x20[%s]','inspect','query','sequence','Removed\x20column\x20%s\x20from\x20%s','info','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s'];(function(_0x37b728,_0x325d12){const _0x5ad1ba=function(_0x211393){while(--_0x211393){_0x37b728['push'](_0x37b728['shift']());}};_0x5ad1ba(++_0x325d12);}(a998_0x325d,0x143));const a998_0x5ad1=function(_0x37b728,_0x325d12){_0x37b728=_0x37b728-0x0;let _0x5ad1ba=a998_0x325d[_0x37b728];return _0x5ad1ba;};const _0x259186=a998_0x5ad1;'use strict';const util=require(_0x259186('0x11')),logger=require('../config/logger')(_0x259186('0xd')),Sequence=function(){};Sequence[_0x259186('0xe')]['enqueue']=function(_0x211393){const _0x2b747d=_0x259186;this[_0x2b747d('0x6')]=this['tail']?this[_0x2b747d('0x6')]['finally'](_0x211393):_0x211393();};const Migration=function(_0x5bfd51){const _0x3b275d=_0x259186;this['queryInterface']=_0x5bfd51,this[_0x3b275d('0x19')]=new Sequence();};Migration['prototype'][_0x259186('0x7')]=function(_0x2fea95,_0x3a2ddd,_0x18b4c8){const _0x252a4f=_0x259186,_0x37f8b0=this;this[_0x252a4f('0x19')][_0x252a4f('0x9')](function(){const _0x855b82=_0x252a4f;return _0x37f8b0[_0x855b82('0x1f')]['changeColumn'](_0x2fea95,_0x3a2ddd,_0x18b4c8)[_0x855b82('0x2')](function(){const _0x4dc9d1=_0x855b82;logger[_0x4dc9d1('0x1b')](_0x4dc9d1('0x0'),_0x3a2ddd,_0x2fea95);})['catch'](function(_0x1a1b6a){const _0xd61f4f=_0x855b82;logger['info'](JSON[_0xd61f4f('0x14')](_0x1a1b6a));});});},Migration[_0x259186('0xe')][_0x259186('0x5')]=function(_0x4a217c,_0x12c8cf,_0x5819b4){const _0x1c32f6=_0x259186,_0x457bc8=this;this[_0x1c32f6('0x19')][_0x1c32f6('0x9')](function(){const _0x274d60=_0x1c32f6;return _0x457bc8[_0x274d60('0x1f')][_0x274d60('0x5')](_0x4a217c,_0x12c8cf,_0x5819b4)[_0x274d60('0x2')](function(){const _0x38101c=_0x274d60;logger['info'](_0x38101c('0xb'),_0x12c8cf,_0x4a217c);})['catch'](function(_0x301961){const _0x153446=_0x274d60;logger[_0x153446('0x1b')](JSON[_0x153446('0x14')](_0x301961));});});},Migration[_0x259186('0xe')]['dropTable']=function(_0x59b732){const _0x1cafa8=this;this['sequence']['enqueue'](function(){const _0x1166ae=a998_0x5ad1;return _0x1cafa8[_0x1166ae('0x1f')]['dropTable'](_0x59b732,{'force':!![]})[_0x1166ae('0x2')](function(){const _0x56fe4c=_0x1166ae;logger[_0x56fe4c('0x1b')](_0x56fe4c('0xa'),_0x59b732);})[_0x1166ae('0x15')](function(_0xeb3695){const _0x1c1fae=_0x1166ae;logger[_0x1c1fae('0x1b')](JSON[_0x1c1fae('0x14')](_0xeb3695));});});},Migration[_0x259186('0xe')][_0x259186('0x3')]=function(_0x5b4308,_0x218138,_0x8e84c5){const _0x301f7a=_0x259186,_0x1562c2=this;this[_0x301f7a('0x19')][_0x301f7a('0x9')](function(){const _0x32a1a5=_0x301f7a;return _0x1562c2[_0x32a1a5('0x1f')][_0x32a1a5('0x3')](_0x5b4308,_0x218138,{'indexName':_0x8e84c5[_0x32a1a5('0x12')],'indicesType':_0x8e84c5['indicesType']})[_0x32a1a5('0x2')](function(){const _0x276d8f=_0x32a1a5;logger[_0x276d8f('0x1b')](_0x276d8f('0x16'),_0x5b4308,_0x218138[_0x276d8f('0xf')](','),_0x8e84c5['indexName'],_0x8e84c5['indicesType']);})['catch'](function(_0x108de7){const _0x485a26=_0x32a1a5;logger[_0x485a26('0x1b')](JSON[_0x485a26('0x14')](_0x108de7));});});},Migration[_0x259186('0xe')][_0x259186('0x1d')]=function(_0x40c92f,_0x2f9dfb){const _0x19f283=_0x259186,_0x4ce24a=this;this[_0x19f283('0x19')]['enqueue'](function(){const _0x6d33f0=_0x19f283;return _0x4ce24a[_0x6d33f0('0x1f')][_0x6d33f0('0x1d')](_0x40c92f,_0x2f9dfb)[_0x6d33f0('0x2')](function(){const _0x3ffc61=_0x6d33f0;logger[_0x3ffc61('0x1b')]('removeIndex\x20%s\x20%s',_0x40c92f,_0x2f9dfb);})[_0x6d33f0('0x15')](function(_0x68cac6){const _0x33734c=_0x6d33f0;logger[_0x33734c('0x1b')](JSON[_0x33734c('0x14')](_0x68cac6));});});},Migration[_0x259186('0xe')][_0x259186('0x18')]=function(_0x380468){const _0x558ab6=this;this['sequence']['enqueue'](function(){const _0x41dc67=a998_0x5ad1;return _0x558ab6[_0x41dc67('0x1f')][_0x41dc67('0x13')][_0x41dc67('0x18')](_0x380468)[_0x41dc67('0x2')](function(){const _0x1568b3=_0x41dc67;logger[_0x1568b3('0x1b')](_0x1568b3('0x10'),_0x380468);})[_0x41dc67('0x15')](function(_0x329664){logger['info'](JSON['stringify'](_0x329664));});});},Migration['prototype']['removeColumn']=function(_0x561f27,_0x8377b8){const _0x4af6c6=_0x259186,_0x14fb49=this;this[_0x4af6c6('0x19')][_0x4af6c6('0x9')](function(){const _0x496c20=_0x4af6c6;return _0x14fb49[_0x496c20('0x1f')][_0x496c20('0x1e')](_0x561f27,_0x8377b8)[_0x496c20('0x2')](function(){const _0x2f18db=_0x496c20;logger[_0x2f18db('0x1b')](_0x2f18db('0x1a'),_0x8377b8,_0x561f27);})['catch'](function(_0x201dec){const _0x239acb=_0x496c20;logger[_0x239acb('0x1b')](util[_0x239acb('0x17')](_0x201dec,{'showHidden':![],'depth':null}));});});},Migration[_0x259186('0xe')][_0x259186('0x1')]=function(_0xf7f1b5,_0x4c6895,_0x58de38){const _0x14e949=_0x259186,_0x29def2=this;this[_0x14e949('0x19')][_0x14e949('0x9')](function(){const _0x448343=_0x14e949;return _0x29def2['queryInterface'][_0x448343('0x1')](_0xf7f1b5,_0x4c6895,_0x58de38)[_0x448343('0x2')](function(){const _0x2d2a8b=_0x448343;logger[_0x2d2a8b('0x1b')](_0x2d2a8b('0x1c'),_0x4c6895,_0x58de38,_0xf7f1b5);})[_0x448343('0x15')](function(_0x5abd57){const _0x26b667=_0x448343;logger[_0x26b667('0x1b')](util[_0x26b667('0x17')](_0x5abd57,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x259186('0x8')]=function(_0xec3071){const _0x14b39f=_0x259186;this['sequence'][_0x14b39f('0x9')](function(){return _0xec3071();});},module[_0x259186('0xc')]={'up':function(_0x4a43ed){return new Promise(function(_0x5e1977){const _0x56d59e=a998_0x5ad1,_0x467deb=new Migration(_0x4a43ed);_0x467deb[_0x56d59e('0x18')](_0x56d59e('0x4')),_0x467deb[_0x56d59e('0x8')](_0x5e1977);});},'down':function(){}}; \ No newline at end of file +const a998_0x37e4=['addIndex\x20%s\x20%s\x20%s\x20[%s]','finally','info','inspect','Added\x20column\x20%s\x20to\x20%s','removeIndex\x20%s\x20%s','catch','enqueue','query','queryInterface','addIndex','migration','changeColumn','sequence','removeColumn','exports','renameColumn','stringify','indexName','join','util','removeIndex','dropTable','indicesType','then','addColumn','prototype','tail'];(function(_0x59e4dc,_0x37e4ba){const _0x148bcc=function(_0x489e63){while(--_0x489e63){_0x59e4dc['push'](_0x59e4dc['shift']());}};_0x148bcc(++_0x37e4ba);}(a998_0x37e4,0xb8));const a998_0x148b=function(_0x59e4dc,_0x37e4ba){_0x59e4dc=_0x59e4dc-0x0;let _0x148bcc=a998_0x37e4[_0x59e4dc];return _0x148bcc;};const _0x52f6fd=a998_0x148b;'use strict';const util=require(_0x52f6fd('0x4')),logger=require('../config/logger')(_0x52f6fd('0x17')),Sequence=function(){};Sequence[_0x52f6fd('0xa')][_0x52f6fd('0x13')]=function(_0x489e63){const _0x194d73=_0x52f6fd;this[_0x194d73('0xb')]=this[_0x194d73('0xb')]?this[_0x194d73('0xb')][_0x194d73('0xd')](_0x489e63):_0x489e63();};const Migration=function(_0x1adc2b){this['queryInterface']=_0x1adc2b,this['sequence']=new Sequence();};Migration[_0x52f6fd('0xa')][_0x52f6fd('0x18')]=function(_0x10f050,_0x86231c,_0x2cf6ed){const _0x597389=_0x52f6fd,_0x5849a9=this;this[_0x597389('0x19')][_0x597389('0x13')](function(){const _0x1ed5ed=_0x597389;return _0x5849a9[_0x1ed5ed('0x15')][_0x1ed5ed('0x18')](_0x10f050,_0x86231c,_0x2cf6ed)[_0x1ed5ed('0x8')](function(){const _0x2e2c04=_0x1ed5ed;logger[_0x2e2c04('0xe')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x86231c,_0x10f050);})[_0x1ed5ed('0x12')](function(_0x5366f7){logger['info'](JSON['stringify'](_0x5366f7));});});},Migration[_0x52f6fd('0xa')]['addColumn']=function(_0x34a014,_0x56e9e6,_0x37bc2e){const _0x27f1da=_0x52f6fd,_0x5c65b2=this;this[_0x27f1da('0x19')][_0x27f1da('0x13')](function(){const _0x5d382e=_0x27f1da;return _0x5c65b2[_0x5d382e('0x15')][_0x5d382e('0x9')](_0x34a014,_0x56e9e6,_0x37bc2e)[_0x5d382e('0x8')](function(){const _0x5bb1bd=_0x5d382e;logger[_0x5bb1bd('0xe')](_0x5bb1bd('0x10'),_0x56e9e6,_0x34a014);})['catch'](function(_0xf32823){logger['info'](JSON['stringify'](_0xf32823));});});},Migration['prototype']['dropTable']=function(_0x5ccbe7){const _0x54c8d1=_0x52f6fd,_0x49a43b=this;this[_0x54c8d1('0x19')][_0x54c8d1('0x13')](function(){const _0x3338b6=_0x54c8d1;return _0x49a43b[_0x3338b6('0x15')][_0x3338b6('0x6')](_0x5ccbe7,{'force':!![]})[_0x3338b6('0x8')](function(){const _0x5f3408=_0x3338b6;logger[_0x5f3408('0xe')]('table\x20dropped\x20%s',_0x5ccbe7);})['catch'](function(_0x20210a){const _0x23e163=_0x3338b6;logger[_0x23e163('0xe')](JSON[_0x23e163('0x1')](_0x20210a));});});},Migration[_0x52f6fd('0xa')][_0x52f6fd('0x16')]=function(_0x23d991,_0x453a7c,_0x152a0f){const _0x553399=_0x52f6fd,_0x1366bc=this;this[_0x553399('0x19')][_0x553399('0x13')](function(){const _0x1245f9=_0x553399;return _0x1366bc[_0x1245f9('0x15')]['addIndex'](_0x23d991,_0x453a7c,{'indexName':_0x152a0f[_0x1245f9('0x2')],'indicesType':_0x152a0f[_0x1245f9('0x7')]})[_0x1245f9('0x8')](function(){const _0x53df24=_0x1245f9;logger[_0x53df24('0xe')](_0x53df24('0xc'),_0x23d991,_0x453a7c[_0x53df24('0x3')](','),_0x152a0f['indexName'],_0x152a0f[_0x53df24('0x7')]);})['catch'](function(_0x327206){const _0x3235ef=_0x1245f9;logger[_0x3235ef('0xe')](JSON['stringify'](_0x327206));});});},Migration[_0x52f6fd('0xa')]['removeIndex']=function(_0x2f7dc9,_0x2a1d92){const _0x11acf1=_0x52f6fd,_0x44338f=this;this['sequence'][_0x11acf1('0x13')](function(){const _0x23c69d=_0x11acf1;return _0x44338f[_0x23c69d('0x15')][_0x23c69d('0x5')](_0x2f7dc9,_0x2a1d92)[_0x23c69d('0x8')](function(){const _0x111391=_0x23c69d;logger['info'](_0x111391('0x11'),_0x2f7dc9,_0x2a1d92);})['catch'](function(_0x165504){const _0x372e73=_0x23c69d;logger[_0x372e73('0xe')](JSON['stringify'](_0x165504));});});},Migration[_0x52f6fd('0xa')]['query']=function(_0x100a0f){const _0x33db98=_0x52f6fd,_0x2b29a6=this;this[_0x33db98('0x19')][_0x33db98('0x13')](function(){const _0x59e132=_0x33db98;return _0x2b29a6['queryInterface']['sequelize'][_0x59e132('0x14')](_0x100a0f)[_0x59e132('0x8')](function(){const _0x13ddf1=_0x59e132;logger[_0x13ddf1('0xe')]('query\x20%s',_0x100a0f);})['catch'](function(_0x26c227){const _0x18c4bd=_0x59e132;logger[_0x18c4bd('0xe')](JSON[_0x18c4bd('0x1')](_0x26c227));});});},Migration[_0x52f6fd('0xa')][_0x52f6fd('0x1a')]=function(_0x5363c2,_0x50da66){const _0x2e427d=_0x52f6fd,_0x1161b1=this;this['sequence'][_0x2e427d('0x13')](function(){const _0x325a59=_0x2e427d;return _0x1161b1['queryInterface'][_0x325a59('0x1a')](_0x5363c2,_0x50da66)[_0x325a59('0x8')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x50da66,_0x5363c2);})[_0x325a59('0x12')](function(_0x144c66){const _0x212863=_0x325a59;logger[_0x212863('0xe')](util[_0x212863('0xf')](_0x144c66,{'showHidden':![],'depth':null}));});});},Migration['prototype']['renameColumn']=function(_0x102248,_0x2cdd63,_0x2e9c5a){const _0x4e8071=_0x52f6fd,_0x4e2a37=this;this[_0x4e8071('0x19')]['enqueue'](function(){const _0x4a2934=_0x4e8071;return _0x4e2a37[_0x4a2934('0x15')][_0x4a2934('0x0')](_0x102248,_0x2cdd63,_0x2e9c5a)[_0x4a2934('0x8')](function(){const _0x210c09=_0x4a2934;logger[_0x210c09('0xe')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x2cdd63,_0x2e9c5a,_0x102248);})[_0x4a2934('0x12')](function(_0x5a3c3f){const _0x5a9748=_0x4a2934;logger[_0x5a9748('0xe')](util[_0x5a9748('0xf')](_0x5a3c3f,{'showHidden':![],'depth':null}));});});},Migration[_0x52f6fd('0xa')]['final']=function(_0x47922b){const _0x1f8035=_0x52f6fd;this[_0x1f8035('0x19')]['enqueue'](function(){return _0x47922b();});},module[_0x52f6fd('0x1b')]={'up':function(_0x3ee99c){return new Promise(function(_0x28dc41){const _0x333a1e=a998_0x148b,_0x592db5=new Migration(_0x3ee99c);_0x592db5[_0x333a1e('0x14')]('UPDATE\x20sms_accounts\x20SET\x20baseUrl\x20=\x20\x22https://sms.csc.lv\x22\x20WHERE\x20type\x20=\x20\x22csc\x22'),_0x592db5['final'](_0x28dc41);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.16.js b/server/migrations/2.4.16.js index b49181a..baa526c 100644 --- a/server/migrations/2.4.16.js +++ b/server/migrations/2.4.16.js @@ -1 +1 @@ -const a999_0x21f2=['FULLTEXT','info','phone','../config/logger','enqueue','util','lastName','indicesType','dropTable','indexName','changeColumn','addColumn','mobile','sequence','catch','Removed\x20column\x20%s\x20from\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','table\x20dropped\x20%s','final','removeIndex','addIndex\x20%s\x20%s\x20%s\x20[%s]','query\x20%s','then','inspect','removeColumn','removeIndex\x20%s\x20%s','exports','stringify','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex','queryInterface','tail','renameColumn','prototype','query','finally','cm_contacts','email','fti_cm_contacts'];(function(_0x4585be,_0x21f226){const _0x1b0547=function(_0x167091){while(--_0x167091){_0x4585be['push'](_0x4585be['shift']());}};_0x1b0547(++_0x21f226);}(a999_0x21f2,0x137));const a999_0x1b05=function(_0x4585be,_0x21f226){_0x4585be=_0x4585be-0x0;let _0x1b0547=a999_0x21f2[_0x4585be];return _0x1b0547;};const _0x52d966=a999_0x1b05;'use strict';const util=require(_0x52d966('0x6')),logger=require(_0x52d966('0x4'))('migration'),Sequence=function(){};Sequence[_0x52d966('0x22')][_0x52d966('0x5')]=function(_0x167091){const _0x3d63fe=_0x52d966;this[_0x3d63fe('0x20')]=this[_0x3d63fe('0x20')]?this['tail'][_0x3d63fe('0x24')](_0x167091):_0x167091();};const Migration=function(_0x3a7c6e){const _0x42ea40=_0x52d966;this[_0x42ea40('0x1f')]=_0x3a7c6e,this['sequence']=new Sequence();};Migration['prototype'][_0x52d966('0xb')]=function(_0x480bb2,_0x3e4aca,_0x59a05f){const _0x322619=_0x52d966,_0x3dfabc=this;this[_0x322619('0xe')][_0x322619('0x5')](function(){const _0x2e2a86=_0x322619;return _0x3dfabc[_0x2e2a86('0x1f')][_0x2e2a86('0xb')](_0x480bb2,_0x3e4aca,_0x59a05f)['then'](function(){const _0x564c4d=_0x2e2a86;logger['info'](_0x564c4d('0x11'),_0x3e4aca,_0x480bb2);})['catch'](function(_0x2032c4){logger['info'](JSON['stringify'](_0x2032c4));});});},Migration[_0x52d966('0x22')][_0x52d966('0xc')]=function(_0x1dcadd,_0x4fb306,_0x1105a5){const _0x3feaa4=_0x52d966,_0x4dd67e=this;this[_0x3feaa4('0xe')][_0x3feaa4('0x5')](function(){const _0x6a83e=_0x3feaa4;return _0x4dd67e['queryInterface'][_0x6a83e('0xc')](_0x1dcadd,_0x4fb306,_0x1105a5)[_0x6a83e('0x17')](function(){const _0x44d9d1=_0x6a83e;logger[_0x44d9d1('0x2')]('Added\x20column\x20%s\x20to\x20%s',_0x4fb306,_0x1dcadd);})['catch'](function(_0x538274){const _0x45468d=_0x6a83e;logger[_0x45468d('0x2')](JSON[_0x45468d('0x1c')](_0x538274));});});},Migration[_0x52d966('0x22')][_0x52d966('0x9')]=function(_0x5d74ee){const _0x5749fb=_0x52d966,_0x24cfe1=this;this[_0x5749fb('0xe')][_0x5749fb('0x5')](function(){const _0x45be04=_0x5749fb;return _0x24cfe1[_0x45be04('0x1f')][_0x45be04('0x9')](_0x5d74ee,{'force':!![]})['then'](function(){const _0x2945cd=_0x45be04;logger[_0x2945cd('0x2')](_0x2945cd('0x12'),_0x5d74ee);})[_0x45be04('0xf')](function(_0x1bae4c){const _0x3a831e=_0x45be04;logger['info'](JSON[_0x3a831e('0x1c')](_0x1bae4c));});});},Migration[_0x52d966('0x22')]['addIndex']=function(_0x4e39da,_0xd0f7ba,_0x148dfa){const _0x26254f=_0x52d966,_0xc016f3=this;this[_0x26254f('0xe')][_0x26254f('0x5')](function(){const _0x22d4a0=_0x26254f;return _0xc016f3[_0x22d4a0('0x1f')][_0x22d4a0('0x1e')](_0x4e39da,_0xd0f7ba,{'indexName':_0x148dfa[_0x22d4a0('0xa')],'indicesType':_0x148dfa[_0x22d4a0('0x8')]})['then'](function(){const _0x16b37d=_0x22d4a0;logger[_0x16b37d('0x2')](_0x16b37d('0x15'),_0x4e39da,_0xd0f7ba['join'](','),_0x148dfa['indexName'],_0x148dfa[_0x16b37d('0x8')]);})[_0x22d4a0('0xf')](function(_0x1608d1){const _0x2c9baf=_0x22d4a0;logger[_0x2c9baf('0x2')](JSON[_0x2c9baf('0x1c')](_0x1608d1));});});},Migration[_0x52d966('0x22')][_0x52d966('0x14')]=function(_0x22ea7e,_0x1aff81){const _0x447c43=_0x52d966,_0x5f46d9=this;this[_0x447c43('0xe')][_0x447c43('0x5')](function(){const _0x1ecce5=_0x447c43;return _0x5f46d9[_0x1ecce5('0x1f')]['removeIndex'](_0x22ea7e,_0x1aff81)[_0x1ecce5('0x17')](function(){const _0x2dcdc9=_0x1ecce5;logger['info'](_0x2dcdc9('0x1a'),_0x22ea7e,_0x1aff81);})['catch'](function(_0x598618){const _0x41cb66=_0x1ecce5;logger[_0x41cb66('0x2')](JSON['stringify'](_0x598618));});});},Migration[_0x52d966('0x22')][_0x52d966('0x23')]=function(_0x412f8c){const _0x25b075=_0x52d966,_0x420c7c=this;this[_0x25b075('0xe')][_0x25b075('0x5')](function(){const _0x1ab774=_0x25b075;return _0x420c7c[_0x1ab774('0x1f')]['sequelize'][_0x1ab774('0x23')](_0x412f8c)['then'](function(){const _0x53d987=_0x1ab774;logger[_0x53d987('0x2')](_0x53d987('0x16'),_0x412f8c);})[_0x1ab774('0xf')](function(_0x204b43){logger['info'](JSON['stringify'](_0x204b43));});});},Migration[_0x52d966('0x22')][_0x52d966('0x19')]=function(_0x44fe87,_0x3a3c44){const _0x52179e=_0x52d966,_0x36c799=this;this[_0x52179e('0xe')][_0x52179e('0x5')](function(){const _0x158ac8=_0x52179e;return _0x36c799[_0x158ac8('0x1f')]['removeColumn'](_0x44fe87,_0x3a3c44)[_0x158ac8('0x17')](function(){const _0x37b032=_0x158ac8;logger['info'](_0x37b032('0x10'),_0x3a3c44,_0x44fe87);})[_0x158ac8('0xf')](function(_0xba8d18){const _0x3b5fdd=_0x158ac8;logger[_0x3b5fdd('0x2')](util[_0x3b5fdd('0x18')](_0xba8d18,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x52d966('0x21')]=function(_0x12aff2,_0x3b01e1,_0x508a67){const _0x26fd7c=_0x52d966,_0x291c50=this;this[_0x26fd7c('0xe')]['enqueue'](function(){const _0x324f68=_0x26fd7c;return _0x291c50[_0x324f68('0x1f')][_0x324f68('0x21')](_0x12aff2,_0x3b01e1,_0x508a67)[_0x324f68('0x17')](function(){const _0x5bc4da=_0x324f68;logger[_0x5bc4da('0x2')](_0x5bc4da('0x1d'),_0x3b01e1,_0x508a67,_0x12aff2);})[_0x324f68('0xf')](function(_0x312774){const _0x38a4bf=_0x324f68;logger[_0x38a4bf('0x2')](util['inspect'](_0x312774,{'showHidden':![],'depth':null}));});});},Migration[_0x52d966('0x22')]['final']=function(_0x2c627e){const _0xd31ac0=_0x52d966;this['sequence'][_0xd31ac0('0x5')](function(){return _0x2c627e();});},module[_0x52d966('0x1b')]={'up':function(_0x3f8b27){return new Promise(function(_0x406df9){const _0x2aed72=a999_0x1b05,_0x56cd4c=new Migration(_0x3f8b27);_0x56cd4c[_0x2aed72('0x1e')](_0x2aed72('0x25'),['firstName',_0x2aed72('0x7'),_0x2aed72('0x3'),_0x2aed72('0xd'),'fax',_0x2aed72('0x26')],{'indexName':_0x2aed72('0x0'),'indicesType':_0x2aed72('0x1')}),_0x56cd4c[_0x2aed72('0x13')](_0x406df9);});},'down':function(){}}; \ No newline at end of file +const a999_0x1fa3=['enqueue','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','exports','tail','stringify','fax','addColumn','query\x20%s','removeColumn','then','table\x20dropped\x20%s','queryInterface','../config/logger','mobile','renameColumn','finally','migration','inspect','removeIndex\x20%s\x20%s','email','fti_cm_contacts','phone','addIndex\x20%s\x20%s\x20%s\x20[%s]','catch','cm_contacts','removeIndex','Added\x20column\x20%s\x20to\x20%s','firstName','addIndex','changeColumn','info','FULLTEXT','query','sequence','prototype','indexName','final'];(function(_0x2fc039,_0x1fa385){const _0xf46071=function(_0x30f153){while(--_0x30f153){_0x2fc039['push'](_0x2fc039['shift']());}};_0xf46071(++_0x1fa385);}(a999_0x1fa3,0xd4));const a999_0xf460=function(_0x2fc039,_0x1fa385){_0x2fc039=_0x2fc039-0x0;let _0xf46071=a999_0x1fa3[_0x2fc039];return _0xf46071;};const _0x6c797b=a999_0xf460;'use strict';const util=require('util'),logger=require(_0x6c797b('0x16'))(_0x6c797b('0x1a')),Sequence=function(){};Sequence[_0x6c797b('0x7')][_0x6c797b('0xa')]=function(_0x30f153){const _0x4f401b=_0x6c797b;this[_0x4f401b('0xd')]=this['tail']?this[_0x4f401b('0xd')][_0x4f401b('0x19')](_0x30f153):_0x30f153();};const Migration=function(_0x5d98ee){const _0x2c099e=_0x6c797b;this[_0x2c099e('0x15')]=_0x5d98ee,this['sequence']=new Sequence();};Migration[_0x6c797b('0x7')][_0x6c797b('0x2')]=function(_0x104f2a,_0x41d274,_0x425fa8){const _0x3b5ecb=this;this['sequence']['enqueue'](function(){const _0x3bd28a=a999_0xf460;return _0x3b5ecb[_0x3bd28a('0x15')]['changeColumn'](_0x104f2a,_0x41d274,_0x425fa8)[_0x3bd28a('0x13')](function(){const _0xa06135=_0x3bd28a;logger[_0xa06135('0x3')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x41d274,_0x104f2a);})['catch'](function(_0x58006b){const _0x51b952=_0x3bd28a;logger[_0x51b952('0x3')](JSON[_0x51b952('0xe')](_0x58006b));});});},Migration['prototype']['addColumn']=function(_0x23eba3,_0x18cb4a,_0x47fff5){const _0x141e19=this;this['sequence']['enqueue'](function(){const _0x5dca4c=a999_0xf460;return _0x141e19[_0x5dca4c('0x15')][_0x5dca4c('0x10')](_0x23eba3,_0x18cb4a,_0x47fff5)['then'](function(){const _0x22869d=_0x5dca4c;logger['info'](_0x22869d('0x24'),_0x18cb4a,_0x23eba3);})[_0x5dca4c('0x21')](function(_0x570a1d){const _0x3a59ec=_0x5dca4c;logger[_0x3a59ec('0x3')](JSON[_0x3a59ec('0xe')](_0x570a1d));});});},Migration[_0x6c797b('0x7')]['dropTable']=function(_0x4b7cad){const _0x245f4c=_0x6c797b,_0x55a490=this;this[_0x245f4c('0x6')][_0x245f4c('0xa')](function(){const _0x1b475d=_0x245f4c;return _0x55a490['queryInterface']['dropTable'](_0x4b7cad,{'force':!![]})[_0x1b475d('0x13')](function(){const _0x407a19=_0x1b475d;logger[_0x407a19('0x3')](_0x407a19('0x14'),_0x4b7cad);})['catch'](function(_0x42488d){const _0x4dcef3=_0x1b475d;logger[_0x4dcef3('0x3')](JSON['stringify'](_0x42488d));});});},Migration[_0x6c797b('0x7')][_0x6c797b('0x1')]=function(_0x3c78df,_0xb3a1c9,_0x307b26){const _0x3647cf=_0x6c797b,_0x55a76b=this;this[_0x3647cf('0x6')][_0x3647cf('0xa')](function(){const _0x159da3=_0x3647cf;return _0x55a76b['queryInterface'][_0x159da3('0x1')](_0x3c78df,_0xb3a1c9,{'indexName':_0x307b26['indexName'],'indicesType':_0x307b26['indicesType']})[_0x159da3('0x13')](function(){const _0x22c317=_0x159da3;logger[_0x22c317('0x3')](_0x22c317('0x20'),_0x3c78df,_0xb3a1c9['join'](','),_0x307b26[_0x22c317('0x8')],_0x307b26['indicesType']);})[_0x159da3('0x21')](function(_0x304db7){const _0x5a0600=_0x159da3;logger[_0x5a0600('0x3')](JSON['stringify'](_0x304db7));});});},Migration[_0x6c797b('0x7')][_0x6c797b('0x23')]=function(_0x3ee072,_0x510d7a){const _0x5cd14d=_0x6c797b,_0x482fba=this;this['sequence'][_0x5cd14d('0xa')](function(){const _0x1272f9=_0x5cd14d;return _0x482fba[_0x1272f9('0x15')][_0x1272f9('0x23')](_0x3ee072,_0x510d7a)['then'](function(){const _0x5a445b=_0x1272f9;logger[_0x5a445b('0x3')](_0x5a445b('0x1c'),_0x3ee072,_0x510d7a);})['catch'](function(_0x2311ed){logger['info'](JSON['stringify'](_0x2311ed));});});},Migration[_0x6c797b('0x7')]['query']=function(_0x39a05d){const _0x42c0f0=_0x6c797b,_0x2c25ca=this;this['sequence'][_0x42c0f0('0xa')](function(){const _0x53a33d=_0x42c0f0;return _0x2c25ca[_0x53a33d('0x15')]['sequelize'][_0x53a33d('0x5')](_0x39a05d)[_0x53a33d('0x13')](function(){const _0x579eee=_0x53a33d;logger[_0x579eee('0x3')](_0x579eee('0x11'),_0x39a05d);})[_0x53a33d('0x21')](function(_0x39a117){const _0x5d4d38=_0x53a33d;logger[_0x5d4d38('0x3')](JSON[_0x5d4d38('0xe')](_0x39a117));});});},Migration[_0x6c797b('0x7')][_0x6c797b('0x12')]=function(_0x28221a,_0x45819f){const _0x5e89f4=_0x6c797b,_0x2de0e6=this;this[_0x5e89f4('0x6')][_0x5e89f4('0xa')](function(){const _0x34ec00=_0x5e89f4;return _0x2de0e6[_0x34ec00('0x15')]['removeColumn'](_0x28221a,_0x45819f)[_0x34ec00('0x13')](function(){const _0x481dd2=_0x34ec00;logger[_0x481dd2('0x3')]('Removed\x20column\x20%s\x20from\x20%s',_0x45819f,_0x28221a);})[_0x34ec00('0x21')](function(_0x19872d){const _0x1ca68b=_0x34ec00;logger[_0x1ca68b('0x3')](util[_0x1ca68b('0x1b')](_0x19872d,{'showHidden':![],'depth':null}));});});},Migration[_0x6c797b('0x7')][_0x6c797b('0x18')]=function(_0x563891,_0x390350,_0x4850c4){const _0x488d69=_0x6c797b,_0x2eb61c=this;this[_0x488d69('0x6')]['enqueue'](function(){const _0x557dbe=_0x488d69;return _0x2eb61c[_0x557dbe('0x15')][_0x557dbe('0x18')](_0x563891,_0x390350,_0x4850c4)[_0x557dbe('0x13')](function(){const _0x5d5868=_0x557dbe;logger[_0x5d5868('0x3')](_0x5d5868('0xb'),_0x390350,_0x4850c4,_0x563891);})['catch'](function(_0x3501d7){const _0x2758f8=_0x557dbe;logger[_0x2758f8('0x3')](util[_0x2758f8('0x1b')](_0x3501d7,{'showHidden':![],'depth':null}));});});},Migration[_0x6c797b('0x7')][_0x6c797b('0x9')]=function(_0x4b4e1f){const _0x43a2b4=_0x6c797b;this[_0x43a2b4('0x6')]['enqueue'](function(){return _0x4b4e1f();});},module[_0x6c797b('0xc')]={'up':function(_0x3bbe2f){return new Promise(function(_0x2d1eaf){const _0x3b106b=a999_0xf460,_0x2e265e=new Migration(_0x3bbe2f);_0x2e265e['addIndex'](_0x3b106b('0x22'),[_0x3b106b('0x0'),'lastName',_0x3b106b('0x1f'),_0x3b106b('0x17'),_0x3b106b('0xf'),_0x3b106b('0x1d')],{'indexName':_0x3b106b('0x1e'),'indicesType':_0x3b106b('0x4')}),_0x2e265e[_0x3b106b('0x9')](_0x2d1eaf);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.17.js b/server/migrations/2.4.17.js index 5c5aeda..d7831a5 100644 --- a/server/migrations/2.4.17.js +++ b/server/migrations/2.4.17.js @@ -1 +1 @@ -const a1000_0x592a=['Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','removeIndex','enqueue','table\x20dropped\x20%s','query\x20%s','changeColumn','finally','addIndex','Added\x20column\x20%s\x20to\x20%s','query','indicesType','sequence','migration','Removed\x20column\x20%s\x20from\x20%s','indexName','stringify','renameColumn','tail','queryInterface','addIndex\x20%s\x20%s\x20%s\x20[%s]','final','prototype','exports','Changed\x20column\x20%s\x20in\x20table\x20%s','catch','then','info','removeIndex\x20%s\x20%s','join','dropTable','removeColumn','addColumn','inspect'];(function(_0x1ed4bb,_0x592a7c){const _0x58aeb8=function(_0x1de089){while(--_0x1de089){_0x1ed4bb['push'](_0x1ed4bb['shift']());}};_0x58aeb8(++_0x592a7c);}(a1000_0x592a,0x6a));const a1000_0x58ae=function(_0x1ed4bb,_0x592a7c){_0x1ed4bb=_0x1ed4bb-0x0;let _0x58aeb8=a1000_0x592a[_0x1ed4bb];return _0x58aeb8;};const _0x44e5a1=a1000_0x58ae;'use strict';const util=require('util'),logger=require('../config/logger')(_0x44e5a1('0x5')),Sequence=function(){};Sequence[_0x44e5a1('0xe')][_0x44e5a1('0x1c')]=function(_0x1de089){const _0x51bd38=_0x44e5a1;this[_0x51bd38('0xa')]=this[_0x51bd38('0xa')]?this[_0x51bd38('0xa')][_0x51bd38('0x20')](_0x1de089):_0x1de089();};const Migration=function(_0x46e147){const _0x57b4b5=_0x44e5a1;this[_0x57b4b5('0xb')]=_0x46e147,this[_0x57b4b5('0x4')]=new Sequence();};Migration[_0x44e5a1('0xe')]['changeColumn']=function(_0x1fb866,_0x52829a,_0x5eb167){const _0x418d7b=_0x44e5a1,_0x9d2c43=this;this[_0x418d7b('0x4')][_0x418d7b('0x1c')](function(){const _0x299138=_0x418d7b;return _0x9d2c43[_0x299138('0xb')][_0x299138('0x1f')](_0x1fb866,_0x52829a,_0x5eb167)['then'](function(){const _0x4afdac=_0x299138;logger[_0x4afdac('0x13')](_0x4afdac('0x10'),_0x52829a,_0x1fb866);})[_0x299138('0x11')](function(_0x20daf9){const _0x4d1b6=_0x299138;logger[_0x4d1b6('0x13')](JSON[_0x4d1b6('0x8')](_0x20daf9));});});},Migration[_0x44e5a1('0xe')][_0x44e5a1('0x18')]=function(_0x3ae1ca,_0x21ec49,_0x404be8){const _0x146285=_0x44e5a1,_0x591443=this;this[_0x146285('0x4')]['enqueue'](function(){const _0x18f0e7=_0x146285;return _0x591443['queryInterface'][_0x18f0e7('0x18')](_0x3ae1ca,_0x21ec49,_0x404be8)['then'](function(){const _0x566a90=_0x18f0e7;logger[_0x566a90('0x13')](_0x566a90('0x1'),_0x21ec49,_0x3ae1ca);})[_0x18f0e7('0x11')](function(_0x2172b9){const _0x3932f2=_0x18f0e7;logger['info'](JSON[_0x3932f2('0x8')](_0x2172b9));});});},Migration[_0x44e5a1('0xe')][_0x44e5a1('0x16')]=function(_0x621816){const _0x4f88bd=_0x44e5a1,_0x46cc20=this;this[_0x4f88bd('0x4')][_0x4f88bd('0x1c')](function(){const _0x1edc66=_0x4f88bd;return _0x46cc20[_0x1edc66('0xb')][_0x1edc66('0x16')](_0x621816,{'force':!![]})[_0x1edc66('0x12')](function(){const _0x215a9e=_0x1edc66;logger['info'](_0x215a9e('0x1d'),_0x621816);})[_0x1edc66('0x11')](function(_0x2f718b){const _0x4d9a31=_0x1edc66;logger['info'](JSON[_0x4d9a31('0x8')](_0x2f718b));});});},Migration['prototype'][_0x44e5a1('0x0')]=function(_0x4951fd,_0x116cd5,_0x459e81){const _0x362ef5=_0x44e5a1,_0xb55e90=this;this[_0x362ef5('0x4')][_0x362ef5('0x1c')](function(){const _0x52e839=_0x362ef5;return _0xb55e90[_0x52e839('0xb')][_0x52e839('0x0')](_0x4951fd,_0x116cd5,{'indexName':_0x459e81['indexName'],'indicesType':_0x459e81[_0x52e839('0x3')]})[_0x52e839('0x12')](function(){const _0x2416fb=_0x52e839;logger[_0x2416fb('0x13')](_0x2416fb('0xc'),_0x4951fd,_0x116cd5[_0x2416fb('0x15')](','),_0x459e81[_0x2416fb('0x7')],_0x459e81['indicesType']);})[_0x52e839('0x11')](function(_0x162d53){const _0x595084=_0x52e839;logger[_0x595084('0x13')](JSON[_0x595084('0x8')](_0x162d53));});});},Migration[_0x44e5a1('0xe')][_0x44e5a1('0x1b')]=function(_0x1168f6,_0x439673){const _0x1549a8=_0x44e5a1,_0xf2fcd=this;this[_0x1549a8('0x4')][_0x1549a8('0x1c')](function(){const _0x44f008=_0x1549a8;return _0xf2fcd['queryInterface'][_0x44f008('0x1b')](_0x1168f6,_0x439673)[_0x44f008('0x12')](function(){const _0x3c7ead=_0x44f008;logger[_0x3c7ead('0x13')](_0x3c7ead('0x14'),_0x1168f6,_0x439673);})[_0x44f008('0x11')](function(_0x280db3){const _0x5733f0=_0x44f008;logger['info'](JSON[_0x5733f0('0x8')](_0x280db3));});});},Migration[_0x44e5a1('0xe')][_0x44e5a1('0x2')]=function(_0xa3c9fd){const _0xbdb14e=_0x44e5a1,_0x511c2e=this;this[_0xbdb14e('0x4')][_0xbdb14e('0x1c')](function(){const _0x3b35da=_0xbdb14e;return _0x511c2e[_0x3b35da('0xb')]['sequelize']['query'](_0xa3c9fd)['then'](function(){const _0x4b1168=_0x3b35da;logger[_0x4b1168('0x13')](_0x4b1168('0x1e'),_0xa3c9fd);})[_0x3b35da('0x11')](function(_0x5e1049){const _0x13e057=_0x3b35da;logger[_0x13e057('0x13')](JSON[_0x13e057('0x8')](_0x5e1049));});});},Migration['prototype'][_0x44e5a1('0x17')]=function(_0x292016,_0x3d8991){const _0x1e40f7=_0x44e5a1,_0x135c10=this;this[_0x1e40f7('0x4')][_0x1e40f7('0x1c')](function(){const _0x13c111=_0x1e40f7;return _0x135c10[_0x13c111('0xb')][_0x13c111('0x17')](_0x292016,_0x3d8991)[_0x13c111('0x12')](function(){const _0x11a10b=_0x13c111;logger[_0x11a10b('0x13')](_0x11a10b('0x6'),_0x3d8991,_0x292016);})['catch'](function(_0x437d9b){const _0x60d813=_0x13c111;logger[_0x60d813('0x13')](util[_0x60d813('0x19')](_0x437d9b,{'showHidden':![],'depth':null}));});});},Migration[_0x44e5a1('0xe')][_0x44e5a1('0x9')]=function(_0xa1100a,_0x1b57b5,_0x1665c2){const _0x304a5b=_0x44e5a1,_0x5aef60=this;this['sequence'][_0x304a5b('0x1c')](function(){const _0x5c27d5=_0x304a5b;return _0x5aef60['queryInterface'][_0x5c27d5('0x9')](_0xa1100a,_0x1b57b5,_0x1665c2)[_0x5c27d5('0x12')](function(){const _0x31b076=_0x5c27d5;logger[_0x31b076('0x13')](_0x31b076('0x1a'),_0x1b57b5,_0x1665c2,_0xa1100a);})['catch'](function(_0x5c4df7){const _0x3f58ec=_0x5c27d5;logger[_0x3f58ec('0x13')](util[_0x3f58ec('0x19')](_0x5c4df7,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x44e5a1('0xd')]=function(_0x108253){const _0x467a40=_0x44e5a1;this[_0x467a40('0x4')][_0x467a40('0x1c')](function(){return _0x108253();});},module[_0x44e5a1('0xf')]={'up':function(_0x1a99d7){return new Promise(function(_0x2bc567){const _0x48164f=a1000_0x58ae,_0x36be2a=new Migration(_0x1a99d7);_0x36be2a[_0x48164f('0xd')](_0x2bc567);});},'down':function(){}}; \ No newline at end of file +const a1000_0x40c3=['query\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','addIndex','stringify','indicesType','exports','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','inspect','join','tail','changeColumn','addColumn','renameColumn','Added\x20column\x20%s\x20to\x20%s','addIndex\x20%s\x20%s\x20%s\x20[%s]','sequence','removeIndex\x20%s\x20%s','removeColumn','../config/logger','catch','prototype','util','enqueue','table\x20dropped\x20%s','dropTable','info','queryInterface','Removed\x20column\x20%s\x20from\x20%s','then','final','query','indexName'];(function(_0x4244cd,_0x40c358){const _0x3936a7=function(_0x3e02c8){while(--_0x3e02c8){_0x4244cd['push'](_0x4244cd['shift']());}};_0x3936a7(++_0x40c358);}(a1000_0x40c3,0xf9));const a1000_0x3936=function(_0x4244cd,_0x40c358){_0x4244cd=_0x4244cd-0x0;let _0x3936a7=a1000_0x40c3[_0x4244cd];return _0x3936a7;};const _0xb92b06=a1000_0x3936;'use strict';const util=require(_0xb92b06('0x1c')),logger=require(_0xb92b06('0x19'))('migration'),Sequence=function(){};Sequence['prototype'][_0xb92b06('0x1d')]=function(_0x3e02c8){const _0x44e8f2=_0xb92b06;this[_0x44e8f2('0x10')]=this[_0x44e8f2('0x10')]?this[_0x44e8f2('0x10')]['finally'](_0x3e02c8):_0x3e02c8();};const Migration=function(_0x4b2561){const _0x41d271=_0xb92b06;this[_0x41d271('0x1')]=_0x4b2561,this[_0x41d271('0x16')]=new Sequence();};Migration[_0xb92b06('0x1b')]['changeColumn']=function(_0xb33cc0,_0x4cef6d,_0x5c53d7){const _0x55520e=_0xb92b06,_0x26dd82=this;this[_0x55520e('0x16')][_0x55520e('0x1d')](function(){const _0x1adb0b=_0x55520e;return _0x26dd82[_0x1adb0b('0x1')][_0x1adb0b('0x11')](_0xb33cc0,_0x4cef6d,_0x5c53d7)['then'](function(){const _0x47e06a=_0x1adb0b;logger[_0x47e06a('0x0')](_0x47e06a('0x8'),_0x4cef6d,_0xb33cc0);})['catch'](function(_0x3e4262){const _0x2133ba=_0x1adb0b;logger[_0x2133ba('0x0')](JSON[_0x2133ba('0xa')](_0x3e4262));});});},Migration['prototype']['addColumn']=function(_0x3bb415,_0x432657,_0x381f8a){const _0x46a485=_0xb92b06,_0x431bc1=this;this['sequence'][_0x46a485('0x1d')](function(){const _0x39e75c=_0x46a485;return _0x431bc1[_0x39e75c('0x1')][_0x39e75c('0x12')](_0x3bb415,_0x432657,_0x381f8a)[_0x39e75c('0x3')](function(){const _0x3d7e15=_0x39e75c;logger[_0x3d7e15('0x0')](_0x3d7e15('0x14'),_0x432657,_0x3bb415);})['catch'](function(_0x1c2379){const _0x4c71c3=_0x39e75c;logger[_0x4c71c3('0x0')](JSON[_0x4c71c3('0xa')](_0x1c2379));});});},Migration[_0xb92b06('0x1b')][_0xb92b06('0x1f')]=function(_0x2eda3f){const _0x28609f=_0xb92b06,_0x4e1352=this;this[_0x28609f('0x16')]['enqueue'](function(){const _0x5bf194=_0x28609f;return _0x4e1352[_0x5bf194('0x1')]['dropTable'](_0x2eda3f,{'force':!![]})[_0x5bf194('0x3')](function(){const _0x192672=_0x5bf194;logger['info'](_0x192672('0x1e'),_0x2eda3f);})[_0x5bf194('0x1a')](function(_0x74ef5b){const _0x5365ca=_0x5bf194;logger[_0x5365ca('0x0')](JSON['stringify'](_0x74ef5b));});});},Migration[_0xb92b06('0x1b')][_0xb92b06('0x9')]=function(_0x278d2d,_0x48f85b,_0x52611d){const _0x36c470=_0xb92b06,_0x292a6d=this;this[_0x36c470('0x16')][_0x36c470('0x1d')](function(){const _0x1105fe=_0x36c470;return _0x292a6d[_0x1105fe('0x1')][_0x1105fe('0x9')](_0x278d2d,_0x48f85b,{'indexName':_0x52611d[_0x1105fe('0x6')],'indicesType':_0x52611d[_0x1105fe('0xb')]})[_0x1105fe('0x3')](function(){const _0x64d0ea=_0x1105fe;logger[_0x64d0ea('0x0')](_0x64d0ea('0x15'),_0x278d2d,_0x48f85b[_0x64d0ea('0xf')](','),_0x52611d[_0x64d0ea('0x6')],_0x52611d['indicesType']);})[_0x1105fe('0x1a')](function(_0xf89d53){const _0x51228a=_0x1105fe;logger[_0x51228a('0x0')](JSON[_0x51228a('0xa')](_0xf89d53));});});},Migration[_0xb92b06('0x1b')]['removeIndex']=function(_0x57bc94,_0x1e9c11){const _0xc49e15=_0xb92b06,_0x2645b5=this;this['sequence'][_0xc49e15('0x1d')](function(){const _0x4ff3cc=_0xc49e15;return _0x2645b5[_0x4ff3cc('0x1')]['removeIndex'](_0x57bc94,_0x1e9c11)['then'](function(){const _0x211d73=_0x4ff3cc;logger[_0x211d73('0x0')](_0x211d73('0x17'),_0x57bc94,_0x1e9c11);})[_0x4ff3cc('0x1a')](function(_0x11e91d){const _0x5284c2=_0x4ff3cc;logger[_0x5284c2('0x0')](JSON[_0x5284c2('0xa')](_0x11e91d));});});},Migration[_0xb92b06('0x1b')][_0xb92b06('0x5')]=function(_0x2ccfc1){const _0x3a7ae4=_0xb92b06,_0x262a5d=this;this[_0x3a7ae4('0x16')][_0x3a7ae4('0x1d')](function(){const _0x2161b9=_0x3a7ae4;return _0x262a5d[_0x2161b9('0x1')]['sequelize'][_0x2161b9('0x5')](_0x2ccfc1)['then'](function(){const _0x19472b=_0x2161b9;logger['info'](_0x19472b('0x7'),_0x2ccfc1);})['catch'](function(_0x10994d){logger['info'](JSON['stringify'](_0x10994d));});});},Migration[_0xb92b06('0x1b')][_0xb92b06('0x18')]=function(_0xdbcb8a,_0x1b5084){const _0x925e36=_0xb92b06,_0x463fa3=this;this[_0x925e36('0x16')][_0x925e36('0x1d')](function(){const _0x46ef6e=_0x925e36;return _0x463fa3['queryInterface']['removeColumn'](_0xdbcb8a,_0x1b5084)[_0x46ef6e('0x3')](function(){const _0x5f02b5=_0x46ef6e;logger[_0x5f02b5('0x0')](_0x5f02b5('0x2'),_0x1b5084,_0xdbcb8a);})['catch'](function(_0x20c143){const _0x49c5d9=_0x46ef6e;logger['info'](util[_0x49c5d9('0xe')](_0x20c143,{'showHidden':![],'depth':null}));});});},Migration[_0xb92b06('0x1b')][_0xb92b06('0x13')]=function(_0x5dd73d,_0x49171d,_0x2c7695){const _0x94b1bc=_0xb92b06,_0x1e1a6e=this;this['sequence'][_0x94b1bc('0x1d')](function(){const _0x4364ff=_0x94b1bc;return _0x1e1a6e[_0x4364ff('0x1')]['renameColumn'](_0x5dd73d,_0x49171d,_0x2c7695)[_0x4364ff('0x3')](function(){const _0x1055f4=_0x4364ff;logger[_0x1055f4('0x0')](_0x1055f4('0xd'),_0x49171d,_0x2c7695,_0x5dd73d);})[_0x4364ff('0x1a')](function(_0x224f41){const _0x1c0c53=_0x4364ff;logger['info'](util[_0x1c0c53('0xe')](_0x224f41,{'showHidden':![],'depth':null}));});});},Migration[_0xb92b06('0x1b')][_0xb92b06('0x4')]=function(_0x579c0d){const _0x1ca24d=_0xb92b06;this[_0x1ca24d('0x16')][_0x1ca24d('0x1d')](function(){return _0x579c0d();});},module[_0xb92b06('0xc')]={'up':function(_0x49fea9){return new Promise(function(_0x578e98){const _0x58f419=a1000_0x3936,_0x25a512=new Migration(_0x49fea9);_0x25a512[_0x58f419('0x4')](_0x578e98);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.18.js b/server/migrations/2.4.18.js index b0d7718..b1c57e9 100644 --- a/server/migrations/2.4.18.js +++ b/server/migrations/2.4.18.js @@ -1 +1 @@ -const a1001_0x1dea=['inspect','table\x20dropped\x20%s','addIndex\x20%s\x20%s\x20%s\x20[%s]','addColumn','stringify','catch','query\x20%s','then','UPDATE\x20voice_queues\x20SET\x20leavewhenempty\x20=\x20\x22no\x22\x20WHERE\x20leavewhenempty\x20=\x20\x27\x27\x20or\x20leavewhenempty\x20IS\x20NULL','removeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Removed\x20column\x20%s\x20from\x20%s','dropTable','indexName','renameColumn','info','sequelize','enqueue','query','queryInterface','removeIndex','Added\x20column\x20%s\x20to\x20%s','changeColumn','addIndex','sequence','Changed\x20column\x20%s\x20in\x20table\x20%s','indicesType','migration','final','removeIndex\x20%s\x20%s','tail','prototype','finally','join'];(function(_0x595c54,_0x1dea36){const _0x528ff9=function(_0x2cf135){while(--_0x2cf135){_0x595c54['push'](_0x595c54['shift']());}};_0x528ff9(++_0x1dea36);}(a1001_0x1dea,0x127));const a1001_0x528f=function(_0x595c54,_0x1dea36){_0x595c54=_0x595c54-0x0;let _0x528ff9=a1001_0x1dea[_0x595c54];return _0x528ff9;};const _0x21bc28=a1001_0x528f;'use strict';const util=require('util'),logger=require('../config/logger')(_0x21bc28('0x4')),Sequence=function(){};Sequence['prototype'][_0x21bc28('0x1c')]=function(_0x2cf135){const _0x1a13f8=_0x21bc28;this['tail']=this[_0x1a13f8('0x7')]?this[_0x1a13f8('0x7')][_0x1a13f8('0x9')](_0x2cf135):_0x2cf135();};const Migration=function(_0x51de85){this['queryInterface']=_0x51de85,this['sequence']=new Sequence();};Migration[_0x21bc28('0x8')][_0x21bc28('0x21')]=function(_0x2a9931,_0x2e7068,_0x21e62e){const _0x53cd1f=_0x21bc28,_0x3eb49=this;this['sequence'][_0x53cd1f('0x1c')](function(){const _0x528f4a=_0x53cd1f;return _0x3eb49[_0x528f4a('0x1e')]['changeColumn'](_0x2a9931,_0x2e7068,_0x21e62e)[_0x528f4a('0x12')](function(){const _0x37751f=_0x528f4a;logger['info'](_0x37751f('0x2'),_0x2e7068,_0x2a9931);})[_0x528f4a('0x10')](function(_0x10ec5f){const _0x355831=_0x528f4a;logger[_0x355831('0x1a')](JSON[_0x355831('0xf')](_0x10ec5f));});});},Migration[_0x21bc28('0x8')][_0x21bc28('0xe')]=function(_0x3a6055,_0x41fcd3,_0x2297e6){const _0x9d9015=_0x21bc28,_0x1e60cb=this;this[_0x9d9015('0x1')][_0x9d9015('0x1c')](function(){const _0x1ee403=_0x9d9015;return _0x1e60cb[_0x1ee403('0x1e')][_0x1ee403('0xe')](_0x3a6055,_0x41fcd3,_0x2297e6)['then'](function(){const _0x229014=_0x1ee403;logger[_0x229014('0x1a')](_0x229014('0x20'),_0x41fcd3,_0x3a6055);})['catch'](function(_0x12e514){logger['info'](JSON['stringify'](_0x12e514));});});},Migration[_0x21bc28('0x8')][_0x21bc28('0x17')]=function(_0x5d8133){const _0x1b6d7c=_0x21bc28,_0x29c5ec=this;this[_0x1b6d7c('0x1')][_0x1b6d7c('0x1c')](function(){const _0x2fbd4a=_0x1b6d7c;return _0x29c5ec[_0x2fbd4a('0x1e')][_0x2fbd4a('0x17')](_0x5d8133,{'force':!![]})['then'](function(){const _0x4c79aa=_0x2fbd4a;logger[_0x4c79aa('0x1a')](_0x4c79aa('0xc'),_0x5d8133);})[_0x2fbd4a('0x10')](function(_0x490cab){const _0x48094e=_0x2fbd4a;logger[_0x48094e('0x1a')](JSON[_0x48094e('0xf')](_0x490cab));});});},Migration[_0x21bc28('0x8')]['addIndex']=function(_0x277d9a,_0x47735d,_0x404374){const _0x299177=_0x21bc28,_0x2c7715=this;this[_0x299177('0x1')][_0x299177('0x1c')](function(){const _0x2022d7=_0x299177;return _0x2c7715['queryInterface'][_0x2022d7('0x0')](_0x277d9a,_0x47735d,{'indexName':_0x404374[_0x2022d7('0x18')],'indicesType':_0x404374[_0x2022d7('0x3')]})[_0x2022d7('0x12')](function(){const _0x4b42c1=_0x2022d7;logger[_0x4b42c1('0x1a')](_0x4b42c1('0xd'),_0x277d9a,_0x47735d[_0x4b42c1('0xa')](','),_0x404374['indexName'],_0x404374[_0x4b42c1('0x3')]);})['catch'](function(_0x533d10){const _0x1247ea=_0x2022d7;logger[_0x1247ea('0x1a')](JSON['stringify'](_0x533d10));});});},Migration[_0x21bc28('0x8')][_0x21bc28('0x1f')]=function(_0x228c2e,_0x5e2327){const _0x2e1f12=_0x21bc28,_0x337100=this;this[_0x2e1f12('0x1')][_0x2e1f12('0x1c')](function(){const _0x54db6d=_0x2e1f12;return _0x337100[_0x54db6d('0x1e')][_0x54db6d('0x1f')](_0x228c2e,_0x5e2327)[_0x54db6d('0x12')](function(){const _0x23a91d=_0x54db6d;logger[_0x23a91d('0x1a')](_0x23a91d('0x6'),_0x228c2e,_0x5e2327);})[_0x54db6d('0x10')](function(_0x48e5c3){const _0x1847a5=_0x54db6d;logger[_0x1847a5('0x1a')](JSON[_0x1847a5('0xf')](_0x48e5c3));});});},Migration[_0x21bc28('0x8')]['query']=function(_0x143b17){const _0x1ede65=_0x21bc28,_0x2d2624=this;this['sequence'][_0x1ede65('0x1c')](function(){const _0xecfb66=_0x1ede65;return _0x2d2624['queryInterface'][_0xecfb66('0x1b')][_0xecfb66('0x1d')](_0x143b17)[_0xecfb66('0x12')](function(){const _0xb7e5c9=_0xecfb66;logger[_0xb7e5c9('0x1a')](_0xb7e5c9('0x11'),_0x143b17);})['catch'](function(_0xa14f74){const _0x3e9617=_0xecfb66;logger['info'](JSON[_0x3e9617('0xf')](_0xa14f74));});});},Migration[_0x21bc28('0x8')][_0x21bc28('0x14')]=function(_0x34de1,_0x343af9){const _0x1f44a9=_0x21bc28,_0x41c65e=this;this[_0x1f44a9('0x1')][_0x1f44a9('0x1c')](function(){const _0xbd3eea=_0x1f44a9;return _0x41c65e['queryInterface'][_0xbd3eea('0x14')](_0x34de1,_0x343af9)[_0xbd3eea('0x12')](function(){const _0x1822ef=_0xbd3eea;logger[_0x1822ef('0x1a')](_0x1822ef('0x16'),_0x343af9,_0x34de1);})[_0xbd3eea('0x10')](function(_0x40255f){const _0x36bde5=_0xbd3eea;logger[_0x36bde5('0x1a')](util['inspect'](_0x40255f,{'showHidden':![],'depth':null}));});});},Migration[_0x21bc28('0x8')][_0x21bc28('0x19')]=function(_0x248f2c,_0x2bc333,_0x1c06cf){const _0xce823f=this;this['sequence']['enqueue'](function(){const _0x3ea793=a1001_0x528f;return _0xce823f[_0x3ea793('0x1e')]['renameColumn'](_0x248f2c,_0x2bc333,_0x1c06cf)[_0x3ea793('0x12')](function(){const _0x4db4ec=_0x3ea793;logger[_0x4db4ec('0x1a')](_0x4db4ec('0x15'),_0x2bc333,_0x1c06cf,_0x248f2c);})[_0x3ea793('0x10')](function(_0x156c36){const _0x1e340e=_0x3ea793;logger[_0x1e340e('0x1a')](util[_0x1e340e('0xb')](_0x156c36,{'showHidden':![],'depth':null}));});});},Migration[_0x21bc28('0x8')]['final']=function(_0x4964c9){const _0x59109e=_0x21bc28;this[_0x59109e('0x1')][_0x59109e('0x1c')](function(){return _0x4964c9();});},module['exports']={'up':function(_0x1bb724){return new Promise(function(_0x18b7a2){const _0x35c4a4=a1001_0x528f,_0x3a0f6f=new Migration(_0x1bb724);_0x3a0f6f['query']('UPDATE\x20voice_queues\x20SET\x20joinempty\x20=\x20\x22yes\x22\x20WHERE\x20joinempty\x20=\x20\x27\x27\x20or\x20joinempty\x20IS\x20NULL'),_0x3a0f6f[_0x35c4a4('0x1d')](_0x35c4a4('0x13')),_0x3a0f6f[_0x35c4a4('0x5')](_0x18b7a2);});},'down':function(){}}; \ No newline at end of file +const a1001_0x59ea=['../config/logger','queryInterface','join','changeColumn','enqueue','query\x20%s','table\x20dropped\x20%s','final','addIndex','addColumn','catch','inspect','query','indicesType','finally','indexName','then','Changed\x20column\x20%s\x20in\x20table\x20%s','removeIndex','UPDATE\x20voice_queues\x20SET\x20leavewhenempty\x20=\x20\x22no\x22\x20WHERE\x20leavewhenempty\x20=\x20\x27\x27\x20or\x20leavewhenempty\x20IS\x20NULL','migration','stringify','UPDATE\x20voice_queues\x20SET\x20joinempty\x20=\x20\x22yes\x22\x20WHERE\x20joinempty\x20=\x20\x27\x27\x20or\x20joinempty\x20IS\x20NULL','sequelize','prototype','dropTable','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','util','sequence','addIndex\x20%s\x20%s\x20%s\x20[%s]','tail','removeIndex\x20%s\x20%s','info','removeColumn','renameColumn'];(function(_0x3a18c7,_0x59ea1d){const _0x1635c2=function(_0x2a1b18){while(--_0x2a1b18){_0x3a18c7['push'](_0x3a18c7['shift']());}};_0x1635c2(++_0x59ea1d);}(a1001_0x59ea,0x1e8));const a1001_0x1635=function(_0x3a18c7,_0x59ea1d){_0x3a18c7=_0x3a18c7-0x0;let _0x1635c2=a1001_0x59ea[_0x3a18c7];return _0x1635c2;};const _0x49b52c=a1001_0x1635;'use strict';const util=require(_0x49b52c('0x1d')),logger=require(_0x49b52c('0x2'))(_0x49b52c('0x16')),Sequence=function(){};Sequence[_0x49b52c('0x1a')][_0x49b52c('0x6')]=function(_0x2a1b18){const _0x1422ae=_0x49b52c;this['tail']=this[_0x1422ae('0x20')]?this[_0x1422ae('0x20')][_0x1422ae('0x10')](_0x2a1b18):_0x2a1b18();};const Migration=function(_0x4765b5){const _0x28d447=_0x49b52c;this[_0x28d447('0x3')]=_0x4765b5,this[_0x28d447('0x1e')]=new Sequence();};Migration[_0x49b52c('0x1a')]['changeColumn']=function(_0x540436,_0x432e72,_0x37121e){const _0xb1babe=_0x49b52c,_0x3d23b8=this;this[_0xb1babe('0x1e')][_0xb1babe('0x6')](function(){const _0x393ec1=_0xb1babe;return _0x3d23b8[_0x393ec1('0x3')][_0x393ec1('0x5')](_0x540436,_0x432e72,_0x37121e)[_0x393ec1('0x12')](function(){const _0x2102bb=_0x393ec1;logger[_0x2102bb('0x22')](_0x2102bb('0x13'),_0x432e72,_0x540436);})['catch'](function(_0x32e1c5){const _0x33d196=_0x393ec1;logger[_0x33d196('0x22')](JSON[_0x33d196('0x17')](_0x32e1c5));});});},Migration[_0x49b52c('0x1a')][_0x49b52c('0xb')]=function(_0x49ddd4,_0x92bfaf,_0x40324c){const _0x2d3f09=_0x49b52c,_0x4a2b8f=this;this['sequence'][_0x2d3f09('0x6')](function(){const _0x24b34c=_0x2d3f09;return _0x4a2b8f[_0x24b34c('0x3')]['addColumn'](_0x49ddd4,_0x92bfaf,_0x40324c)[_0x24b34c('0x12')](function(){const _0x54252c=_0x24b34c;logger[_0x54252c('0x22')]('Added\x20column\x20%s\x20to\x20%s',_0x92bfaf,_0x49ddd4);})[_0x24b34c('0xc')](function(_0x58e61e){const _0x4851c2=_0x24b34c;logger[_0x4851c2('0x22')](JSON['stringify'](_0x58e61e));});});},Migration['prototype'][_0x49b52c('0x1b')]=function(_0x3cb3d8){const _0xd5fa68=_0x49b52c,_0x50e3d1=this;this[_0xd5fa68('0x1e')][_0xd5fa68('0x6')](function(){const _0x3a9049=_0xd5fa68;return _0x50e3d1['queryInterface'][_0x3a9049('0x1b')](_0x3cb3d8,{'force':!![]})[_0x3a9049('0x12')](function(){const _0x177ae5=_0x3a9049;logger['info'](_0x177ae5('0x8'),_0x3cb3d8);})[_0x3a9049('0xc')](function(_0x5102aa){logger['info'](JSON['stringify'](_0x5102aa));});});},Migration[_0x49b52c('0x1a')][_0x49b52c('0xa')]=function(_0x3cdfef,_0x3d44e1,_0x3ee3f2){const _0x56c8d2=_0x49b52c,_0x4e7e16=this;this[_0x56c8d2('0x1e')][_0x56c8d2('0x6')](function(){const _0x6ae841=_0x56c8d2;return _0x4e7e16[_0x6ae841('0x3')][_0x6ae841('0xa')](_0x3cdfef,_0x3d44e1,{'indexName':_0x3ee3f2[_0x6ae841('0x11')],'indicesType':_0x3ee3f2[_0x6ae841('0xf')]})[_0x6ae841('0x12')](function(){const _0x5f3cd0=_0x6ae841;logger[_0x5f3cd0('0x22')](_0x5f3cd0('0x1f'),_0x3cdfef,_0x3d44e1[_0x5f3cd0('0x4')](','),_0x3ee3f2['indexName'],_0x3ee3f2[_0x5f3cd0('0xf')]);})[_0x6ae841('0xc')](function(_0x3197a6){const _0x1fa16e=_0x6ae841;logger['info'](JSON[_0x1fa16e('0x17')](_0x3197a6));});});},Migration['prototype'][_0x49b52c('0x14')]=function(_0x4cbb03,_0xaebae0){const _0x57db7e=_0x49b52c,_0x567fb3=this;this[_0x57db7e('0x1e')][_0x57db7e('0x6')](function(){const _0x44bea7=_0x57db7e;return _0x567fb3[_0x44bea7('0x3')][_0x44bea7('0x14')](_0x4cbb03,_0xaebae0)[_0x44bea7('0x12')](function(){const _0x4d5055=_0x44bea7;logger['info'](_0x4d5055('0x21'),_0x4cbb03,_0xaebae0);})['catch'](function(_0x24c379){const _0x1302ec=_0x44bea7;logger[_0x1302ec('0x22')](JSON[_0x1302ec('0x17')](_0x24c379));});});},Migration[_0x49b52c('0x1a')][_0x49b52c('0xe')]=function(_0x2a815a){const _0x246147=_0x49b52c,_0xdd9bda=this;this[_0x246147('0x1e')]['enqueue'](function(){const _0x1e8245=_0x246147;return _0xdd9bda[_0x1e8245('0x3')][_0x1e8245('0x19')][_0x1e8245('0xe')](_0x2a815a)[_0x1e8245('0x12')](function(){const _0x519dd7=_0x1e8245;logger['info'](_0x519dd7('0x7'),_0x2a815a);})[_0x1e8245('0xc')](function(_0x3053ce){const _0x3d550a=_0x1e8245;logger['info'](JSON[_0x3d550a('0x17')](_0x3053ce));});});},Migration[_0x49b52c('0x1a')][_0x49b52c('0x0')]=function(_0x1f4eed,_0x246ce0){const _0x30db8b=_0x49b52c,_0x27290b=this;this[_0x30db8b('0x1e')]['enqueue'](function(){const _0x599e8d=_0x30db8b;return _0x27290b[_0x599e8d('0x3')][_0x599e8d('0x0')](_0x1f4eed,_0x246ce0)[_0x599e8d('0x12')](function(){const _0x257b24=_0x599e8d;logger[_0x257b24('0x22')]('Removed\x20column\x20%s\x20from\x20%s',_0x246ce0,_0x1f4eed);})['catch'](function(_0x28e747){logger['info'](util['inspect'](_0x28e747,{'showHidden':![],'depth':null}));});});},Migration[_0x49b52c('0x1a')]['renameColumn']=function(_0x3b7097,_0x3816db,_0x5a0d0e){const _0x1c121c=_0x49b52c,_0x2d9a10=this;this[_0x1c121c('0x1e')]['enqueue'](function(){const _0x8c9523=_0x1c121c;return _0x2d9a10[_0x8c9523('0x3')][_0x8c9523('0x1')](_0x3b7097,_0x3816db,_0x5a0d0e)[_0x8c9523('0x12')](function(){const _0xe7482d=_0x8c9523;logger[_0xe7482d('0x22')](_0xe7482d('0x1c'),_0x3816db,_0x5a0d0e,_0x3b7097);})[_0x8c9523('0xc')](function(_0x4fe237){const _0x14ce53=_0x8c9523;logger[_0x14ce53('0x22')](util[_0x14ce53('0xd')](_0x4fe237,{'showHidden':![],'depth':null}));});});},Migration[_0x49b52c('0x1a')][_0x49b52c('0x9')]=function(_0x3b7deb){const _0x4344e8=_0x49b52c;this[_0x4344e8('0x1e')][_0x4344e8('0x6')](function(){return _0x3b7deb();});},module['exports']={'up':function(_0x42a371){return new Promise(function(_0x35ecb7){const _0x44ed70=a1001_0x1635,_0x505601=new Migration(_0x42a371);_0x505601[_0x44ed70('0xe')](_0x44ed70('0x18')),_0x505601['query'](_0x44ed70('0x15')),_0x505601[_0x44ed70('0x9')](_0x35ecb7);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.19.js b/server/migrations/2.4.19.js index ea7ce8e..21ae2af 100644 --- a/server/migrations/2.4.19.js +++ b/server/migrations/2.4.19.js @@ -1 +1 @@ -const a1002_0x5a8f=['../config/logger','sequelize','join','STRING','externip','enqueue','dropTable','localnet','username','final','Removed\x20column\x20%s\x20from\x20%s','indicesType','password','type','addColumn','turn','query','exports','queryInterface','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','removeColumn','prototype','table\x20dropped\x20%s','finally','contact','renameColumn','stun','indexName','sequence','Contacts','inspect','changeColumn','tail','int_zoho_configurations','Changed\x20column\x20%s\x20in\x20table\x20%s','lead','addIndex\x20%s\x20%s\x20%s\x20[%s]','removeIndex','query\x20%s','catch','UPDATE\x20int_zoho_configurations\x20SET\x20moduleCreate\x20=\x20\x27contact\x27\x20WHERE\x20moduleCreate\x20=\x20\x27Contacts\x27','addIndex','info','nothing','network','then','Leads','stringify','removeIndex\x20%s\x20%s','ENUM'];(function(_0x558f8d,_0x5a8f5f){const _0x56f431=function(_0x593a51){while(--_0x593a51){_0x558f8d['push'](_0x558f8d['shift']());}};_0x56f431(++_0x5a8f5f);}(a1002_0x5a8f,0x1a6));const a1002_0x56f4=function(_0x558f8d,_0x5a8f5f){_0x558f8d=_0x558f8d-0x0;let _0x56f431=a1002_0x5a8f[_0x558f8d];return _0x56f431;};const _0x394fb4=a1002_0x56f4;'use strict';const util=require('util'),logger=require(_0x394fb4('0x1c'))('migration'),Sequence=function(){};Sequence['prototype'][_0x394fb4('0x21')]=function(_0x593a51){const _0x2c6331=_0x394fb4;this[_0x2c6331('0xa')]=this[_0x2c6331('0xa')]?this[_0x2c6331('0xa')][_0x2c6331('0x1')](_0x593a51):_0x593a51();};const Migration=function(_0x17beea){const _0x5a5da4=_0x394fb4;this['queryInterface']=_0x17beea,this[_0x5a5da4('0x6')]=new Sequence();};Migration[_0x394fb4('0x31')][_0x394fb4('0x9')]=function(_0x44a311,_0x4507cb,_0x212f93){const _0x28cc72=_0x394fb4,_0x59703f=this;this['sequence'][_0x28cc72('0x21')](function(){const _0x32ba61=_0x28cc72;return _0x59703f[_0x32ba61('0x2e')][_0x32ba61('0x9')](_0x44a311,_0x4507cb,_0x212f93)[_0x32ba61('0x17')](function(){const _0x33acab=_0x32ba61;logger[_0x33acab('0x14')](_0x33acab('0xc'),_0x4507cb,_0x44a311);})['catch'](function(_0x3f5628){const _0x224451=_0x32ba61;logger['info'](JSON[_0x224451('0x19')](_0x3f5628));});});},Migration[_0x394fb4('0x31')][_0x394fb4('0x2a')]=function(_0x159bf5,_0x23c93b,_0x31f708){const _0x823310=this;this['sequence']['enqueue'](function(){const _0x5a1d9c=a1002_0x56f4;return _0x823310['queryInterface']['addColumn'](_0x159bf5,_0x23c93b,_0x31f708)[_0x5a1d9c('0x17')](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x23c93b,_0x159bf5);})['catch'](function(_0x5cf1d3){const _0x165701=_0x5a1d9c;logger[_0x165701('0x14')](JSON[_0x165701('0x19')](_0x5cf1d3));});});},Migration[_0x394fb4('0x31')][_0x394fb4('0x22')]=function(_0xa6110){const _0x34ad31=_0x394fb4,_0x50aff5=this;this[_0x34ad31('0x6')][_0x34ad31('0x21')](function(){const _0x3a2e3f=_0x34ad31;return _0x50aff5[_0x3a2e3f('0x2e')][_0x3a2e3f('0x22')](_0xa6110,{'force':!![]})[_0x3a2e3f('0x17')](function(){const _0x2ea5ae=_0x3a2e3f;logger[_0x2ea5ae('0x14')](_0x2ea5ae('0x0'),_0xa6110);})[_0x3a2e3f('0x11')](function(_0xc702e){const _0x345573=_0x3a2e3f;logger['info'](JSON[_0x345573('0x19')](_0xc702e));});});},Migration['prototype']['addIndex']=function(_0x2c2a9a,_0x411796,_0x1828ce){const _0x247a04=_0x394fb4,_0x1affa8=this;this[_0x247a04('0x6')][_0x247a04('0x21')](function(){const _0x485646=_0x247a04;return _0x1affa8[_0x485646('0x2e')][_0x485646('0x13')](_0x2c2a9a,_0x411796,{'indexName':_0x1828ce['indexName'],'indicesType':_0x1828ce['indicesType']})[_0x485646('0x17')](function(){const _0x535aa9=_0x485646;logger[_0x535aa9('0x14')](_0x535aa9('0xe'),_0x2c2a9a,_0x411796[_0x535aa9('0x1e')](','),_0x1828ce[_0x535aa9('0x5')],_0x1828ce[_0x535aa9('0x27')]);})['catch'](function(_0x5971dd){const _0x524809=_0x485646;logger[_0x524809('0x14')](JSON[_0x524809('0x19')](_0x5971dd));});});},Migration[_0x394fb4('0x31')]['removeIndex']=function(_0x592440,_0x52b931){const _0x1c6e07=_0x394fb4,_0x5a53cb=this;this[_0x1c6e07('0x6')][_0x1c6e07('0x21')](function(){const _0x27bb94=_0x1c6e07;return _0x5a53cb[_0x27bb94('0x2e')][_0x27bb94('0xf')](_0x592440,_0x52b931)[_0x27bb94('0x17')](function(){const _0xf03d=_0x27bb94;logger[_0xf03d('0x14')](_0xf03d('0x1a'),_0x592440,_0x52b931);})[_0x27bb94('0x11')](function(_0x3f4072){const _0x4ed8c1=_0x27bb94;logger[_0x4ed8c1('0x14')](JSON[_0x4ed8c1('0x19')](_0x3f4072));});});},Migration['prototype'][_0x394fb4('0x2c')]=function(_0x18c484){const _0x3d15bb=this;this['sequence']['enqueue'](function(){const _0x38e92f=a1002_0x56f4;return _0x3d15bb[_0x38e92f('0x2e')][_0x38e92f('0x1d')][_0x38e92f('0x2c')](_0x18c484)[_0x38e92f('0x17')](function(){const _0x316bf6=_0x38e92f;logger[_0x316bf6('0x14')](_0x316bf6('0x10'),_0x18c484);})[_0x38e92f('0x11')](function(_0x577899){const _0x40fe78=_0x38e92f;logger['info'](JSON[_0x40fe78('0x19')](_0x577899));});});},Migration[_0x394fb4('0x31')][_0x394fb4('0x30')]=function(_0x2cb4f3,_0x529e3b){const _0x5e7e29=_0x394fb4,_0x1dd4e9=this;this['sequence'][_0x5e7e29('0x21')](function(){const _0x4eac69=_0x5e7e29;return _0x1dd4e9[_0x4eac69('0x2e')][_0x4eac69('0x30')](_0x2cb4f3,_0x529e3b)[_0x4eac69('0x17')](function(){const _0x36cc8b=_0x4eac69;logger['info'](_0x36cc8b('0x26'),_0x529e3b,_0x2cb4f3);})[_0x4eac69('0x11')](function(_0xcca00f){const _0x4e5cb1=_0x4eac69;logger[_0x4e5cb1('0x14')](util[_0x4e5cb1('0x8')](_0xcca00f,{'showHidden':![],'depth':null}));});});},Migration[_0x394fb4('0x31')][_0x394fb4('0x3')]=function(_0x599ac7,_0x491931,_0x3e5d64){const _0x32a1d8=_0x394fb4,_0x3a1042=this;this[_0x32a1d8('0x6')][_0x32a1d8('0x21')](function(){const _0x2deb79=_0x32a1d8;return _0x3a1042['queryInterface']['renameColumn'](_0x599ac7,_0x491931,_0x3e5d64)['then'](function(){const _0x201a66=a1002_0x56f4;logger['info'](_0x201a66('0x2f'),_0x491931,_0x3e5d64,_0x599ac7);})[_0x2deb79('0x11')](function(_0x19cc85){const _0x2b54d6=_0x2deb79;logger[_0x2b54d6('0x14')](util[_0x2b54d6('0x8')](_0x19cc85,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x394fb4('0x25')]=function(_0x862bc3){this['sequence']['enqueue'](function(){return _0x862bc3();});},module[_0x394fb4('0x2d')]={'up':function(_0x2d94c5,_0x5bcbab){return new Promise(function(_0x38931f){const _0x1cd49d=a1002_0x56f4,_0x91f380=new Migration(_0x2d94c5);_0x91f380[_0x1cd49d('0x2a')](_0x1cd49d('0xb'),'moduleSearch',{'type':_0x5bcbab[_0x1cd49d('0x1b')]('contact_lead',_0x1cd49d('0x2'),'lead'),'defaultValue':'contact_lead'}),_0x91f380[_0x1cd49d('0x9')](_0x1cd49d('0xb'),'moduleCreate',{'type':_0x5bcbab[_0x1cd49d('0x1b')](_0x1cd49d('0x18'),_0x1cd49d('0x7'),_0x1cd49d('0x15'),_0x1cd49d('0x2'),_0x1cd49d('0xd'))}),_0x91f380[_0x1cd49d('0x2c')](_0x1cd49d('0x12')),_0x91f380['query']('UPDATE\x20int_zoho_configurations\x20SET\x20moduleCreate\x20=\x20\x27lead\x27\x20WHERE\x20moduleCreate\x20=\x20\x27Leads\x27'),_0x91f380[_0x1cd49d('0x9')](_0x1cd49d('0xb'),'moduleCreate',{'type':_0x5bcbab[_0x1cd49d('0x1b')](_0x1cd49d('0x15'),_0x1cd49d('0x2'),'lead'),'defaultValue':'lead'}),_0x91f380['addColumn'](_0x1cd49d('0x16'),_0x1cd49d('0x24'),{'type':_0x5bcbab['STRING']}),_0x91f380[_0x1cd49d('0x2a')](_0x1cd49d('0x16'),_0x1cd49d('0x28'),{'type':_0x5bcbab[_0x1cd49d('0x1f')]}),_0x91f380[_0x1cd49d('0x9')](_0x1cd49d('0x16'),_0x1cd49d('0x29'),{'type':_0x5bcbab['ENUM'](_0x1cd49d('0x23'),_0x1cd49d('0x20'),_0x1cd49d('0x4'),_0x1cd49d('0x2b'))}),_0x91f380['query']('INSERT\x20INTO\x20network\x20(type,value,\x20createdAt,\x20updatedAt)\x20SELECT\x20\x27stun\x27,\x20stunaddr,\x20current_timestamp(),\x20current_timestamp()\x20from\x20settings\x20WHERE\x20stunaddr<>\x27\x27'),_0x91f380[_0x1cd49d('0x2c')]('INSERT\x20INTO\x20network\x20(type,value,username,password,\x20createdAt,\x20updatedAt)\x20SELECT\x20\x27turn\x27,\x20turnaddr,\x20turnusername,\x20turnpassword,\x20current_timestamp(),\x20current_timestamp()\x20from\x20settings\x20WHERE\x20turnaddr<>\x27\x27'),_0x91f380[_0x1cd49d('0x25')](_0x38931f);});},'down':function(){}}; \ No newline at end of file +const a1002_0x13f9=['../config/logger','INSERT\x20INTO\x20network\x20(type,value,username,password,\x20createdAt,\x20updatedAt)\x20SELECT\x20\x27turn\x27,\x20turnaddr,\x20turnusername,\x20turnpassword,\x20current_timestamp(),\x20current_timestamp()\x20from\x20settings\x20WHERE\x20turnaddr<>\x27\x27','Removed\x20column\x20%s\x20from\x20%s','stun','turn','final','addIndex','migration','Leads','int_zoho_configurations','renameColumn','Added\x20column\x20%s\x20to\x20%s','exports','moduleCreate','removeIndex\x20%s\x20%s','info','password','tail','query','indicesType','network','UPDATE\x20int_zoho_configurations\x20SET\x20moduleCreate\x20=\x20\x27lead\x27\x20WHERE\x20moduleCreate\x20=\x20\x27Leads\x27','username','enqueue','sequelize','join','lead','query\x20%s','then','finally','nothing','moduleSearch','externip','prototype','UPDATE\x20int_zoho_configurations\x20SET\x20moduleCreate\x20=\x20\x27contact\x27\x20WHERE\x20moduleCreate\x20=\x20\x27Contacts\x27','stringify','contact_lead','queryInterface','type','contact','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','table\x20dropped\x20%s','inspect','indexName','util','changeColumn','INSERT\x20INTO\x20network\x20(type,value,\x20createdAt,\x20updatedAt)\x20SELECT\x20\x27stun\x27,\x20stunaddr,\x20current_timestamp(),\x20current_timestamp()\x20from\x20settings\x20WHERE\x20stunaddr<>\x27\x27','addColumn','catch','sequence','dropTable','ENUM','removeColumn','STRING'];(function(_0x31f44c,_0x13f9c6){const _0x3409f3=function(_0x230f41){while(--_0x230f41){_0x31f44c['push'](_0x31f44c['shift']());}};_0x3409f3(++_0x13f9c6);}(a1002_0x13f9,0x1ce));const a1002_0x3409=function(_0x31f44c,_0x13f9c6){_0x31f44c=_0x31f44c-0x0;let _0x3409f3=a1002_0x13f9[_0x31f44c];return _0x3409f3;};const _0x338966=a1002_0x3409;'use strict';const util=require(_0x338966('0xe')),logger=require(_0x338966('0x18'))(_0x338966('0x1f')),Sequence=function(){};Sequence[_0x338966('0x3')][_0x338966('0x2f')]=function(_0x230f41){const _0x27487b=_0x338966;this[_0x27487b('0x29')]=this[_0x27487b('0x29')]?this[_0x27487b('0x29')][_0x27487b('0x35')](_0x230f41):_0x230f41();};const Migration=function(_0x3b9ca5){const _0x379189=_0x338966;this[_0x379189('0x7')]=_0x3b9ca5,this[_0x379189('0x13')]=new Sequence();};Migration[_0x338966('0x3')]['changeColumn']=function(_0x4ad7a7,_0x3d5149,_0x483d1a){const _0x35467a=_0x338966,_0x4328fc=this;this[_0x35467a('0x13')][_0x35467a('0x2f')](function(){const _0x397276=_0x35467a;return _0x4328fc['queryInterface'][_0x397276('0xf')](_0x4ad7a7,_0x3d5149,_0x483d1a)['then'](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x3d5149,_0x4ad7a7);})[_0x397276('0x12')](function(_0x43cae3){const _0x1ee90c=_0x397276;logger['info'](JSON[_0x1ee90c('0x5')](_0x43cae3));});});},Migration[_0x338966('0x3')][_0x338966('0x11')]=function(_0x1ad1f5,_0x2d412c,_0x4bf8cc){const _0x3d0877=_0x338966,_0x5f5a8f=this;this[_0x3d0877('0x13')][_0x3d0877('0x2f')](function(){const _0x5224be=_0x3d0877;return _0x5f5a8f['queryInterface'][_0x5224be('0x11')](_0x1ad1f5,_0x2d412c,_0x4bf8cc)[_0x5224be('0x34')](function(){const _0x41b441=_0x5224be;logger[_0x41b441('0x27')](_0x41b441('0x23'),_0x2d412c,_0x1ad1f5);})['catch'](function(_0x5599da){logger['info'](JSON['stringify'](_0x5599da));});});},Migration[_0x338966('0x3')][_0x338966('0x14')]=function(_0x5486d8){const _0x28e418=_0x338966,_0x26e903=this;this[_0x28e418('0x13')][_0x28e418('0x2f')](function(){const _0xa8fb33=_0x28e418;return _0x26e903[_0xa8fb33('0x7')][_0xa8fb33('0x14')](_0x5486d8,{'force':!![]})[_0xa8fb33('0x34')](function(){const _0x8f1c3c=_0xa8fb33;logger[_0x8f1c3c('0x27')](_0x8f1c3c('0xb'),_0x5486d8);})[_0xa8fb33('0x12')](function(_0x35992a){const _0xe73daa=_0xa8fb33;logger[_0xe73daa('0x27')](JSON[_0xe73daa('0x5')](_0x35992a));});});},Migration[_0x338966('0x3')][_0x338966('0x1e')]=function(_0x2e8041,_0xc08364,_0x27e832){const _0x1517fc=_0x338966,_0x327b6f=this;this['sequence'][_0x1517fc('0x2f')](function(){const _0x10820d=_0x1517fc;return _0x327b6f['queryInterface']['addIndex'](_0x2e8041,_0xc08364,{'indexName':_0x27e832[_0x10820d('0xd')],'indicesType':_0x27e832[_0x10820d('0x2b')]})[_0x10820d('0x34')](function(){const _0x2d5c08=_0x10820d;logger['info']('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x2e8041,_0xc08364[_0x2d5c08('0x31')](','),_0x27e832[_0x2d5c08('0xd')],_0x27e832[_0x2d5c08('0x2b')]);})[_0x10820d('0x12')](function(_0x2d6b92){const _0x5cfd66=_0x10820d;logger[_0x5cfd66('0x27')](JSON[_0x5cfd66('0x5')](_0x2d6b92));});});},Migration[_0x338966('0x3')]['removeIndex']=function(_0x2290fd,_0x588a94){const _0x153bf4=_0x338966,_0x70bbff=this;this[_0x153bf4('0x13')]['enqueue'](function(){const _0x55aa46=_0x153bf4;return _0x70bbff[_0x55aa46('0x7')]['removeIndex'](_0x2290fd,_0x588a94)['then'](function(){const _0x1478fe=_0x55aa46;logger['info'](_0x1478fe('0x26'),_0x2290fd,_0x588a94);})[_0x55aa46('0x12')](function(_0x59ffcf){const _0x2e95b0=_0x55aa46;logger[_0x2e95b0('0x27')](JSON[_0x2e95b0('0x5')](_0x59ffcf));});});},Migration['prototype'][_0x338966('0x2a')]=function(_0x2c6bfe){const _0x224166=_0x338966,_0x6908f=this;this[_0x224166('0x13')][_0x224166('0x2f')](function(){const _0x2b27a0=_0x224166;return _0x6908f[_0x2b27a0('0x7')][_0x2b27a0('0x30')][_0x2b27a0('0x2a')](_0x2c6bfe)[_0x2b27a0('0x34')](function(){const _0x319ac0=_0x2b27a0;logger[_0x319ac0('0x27')](_0x319ac0('0x33'),_0x2c6bfe);})[_0x2b27a0('0x12')](function(_0xfb957a){const _0xf552c7=_0x2b27a0;logger[_0xf552c7('0x27')](JSON[_0xf552c7('0x5')](_0xfb957a));});});},Migration['prototype'][_0x338966('0x16')]=function(_0x226b92,_0x1d5d7b){const _0x14b01a=_0x338966,_0x266694=this;this[_0x14b01a('0x13')][_0x14b01a('0x2f')](function(){const _0x34edb1=_0x14b01a;return _0x266694[_0x34edb1('0x7')][_0x34edb1('0x16')](_0x226b92,_0x1d5d7b)[_0x34edb1('0x34')](function(){const _0x52c608=_0x34edb1;logger[_0x52c608('0x27')](_0x52c608('0x1a'),_0x1d5d7b,_0x226b92);})[_0x34edb1('0x12')](function(_0x3bee9e){const _0x12ba4b=_0x34edb1;logger[_0x12ba4b('0x27')](util[_0x12ba4b('0xc')](_0x3bee9e,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x338966('0x22')]=function(_0x10b4e7,_0x4b43a4,_0x3ea528){const _0x27fa6b=_0x338966,_0xaa0d9c=this;this[_0x27fa6b('0x13')][_0x27fa6b('0x2f')](function(){const _0x3824ac=_0x27fa6b;return _0xaa0d9c[_0x3824ac('0x7')][_0x3824ac('0x22')](_0x10b4e7,_0x4b43a4,_0x3ea528)[_0x3824ac('0x34')](function(){const _0x22a241=_0x3824ac;logger[_0x22a241('0x27')](_0x22a241('0xa'),_0x4b43a4,_0x3ea528,_0x10b4e7);})['catch'](function(_0xe18976){const _0xbbe421=_0x3824ac;logger['info'](util[_0xbbe421('0xc')](_0xe18976,{'showHidden':![],'depth':null}));});});},Migration[_0x338966('0x3')][_0x338966('0x1d')]=function(_0x5750aa){const _0x1d33ec=_0x338966;this[_0x1d33ec('0x13')][_0x1d33ec('0x2f')](function(){return _0x5750aa();});},module[_0x338966('0x24')]={'up':function(_0x50aab1,_0x2c12f4){return new Promise(function(_0x2b5b0d){const _0x3053d0=a1002_0x3409,_0x5d32a4=new Migration(_0x50aab1);_0x5d32a4[_0x3053d0('0x11')](_0x3053d0('0x21'),_0x3053d0('0x1'),{'type':_0x2c12f4[_0x3053d0('0x15')](_0x3053d0('0x6'),_0x3053d0('0x9'),'lead'),'defaultValue':'contact_lead'}),_0x5d32a4[_0x3053d0('0xf')]('int_zoho_configurations',_0x3053d0('0x25'),{'type':_0x2c12f4[_0x3053d0('0x15')](_0x3053d0('0x20'),'Contacts',_0x3053d0('0x0'),_0x3053d0('0x9'),_0x3053d0('0x32'))}),_0x5d32a4[_0x3053d0('0x2a')](_0x3053d0('0x4')),_0x5d32a4[_0x3053d0('0x2a')](_0x3053d0('0x2d')),_0x5d32a4[_0x3053d0('0xf')](_0x3053d0('0x21'),_0x3053d0('0x25'),{'type':_0x2c12f4['ENUM']('nothing',_0x3053d0('0x9'),_0x3053d0('0x32')),'defaultValue':_0x3053d0('0x32')}),_0x5d32a4[_0x3053d0('0x11')](_0x3053d0('0x2c'),_0x3053d0('0x2e'),{'type':_0x2c12f4[_0x3053d0('0x17')]}),_0x5d32a4[_0x3053d0('0x11')](_0x3053d0('0x2c'),_0x3053d0('0x28'),{'type':_0x2c12f4[_0x3053d0('0x17')]}),_0x5d32a4[_0x3053d0('0xf')]('network',_0x3053d0('0x8'),{'type':_0x2c12f4[_0x3053d0('0x15')]('localnet',_0x3053d0('0x2'),_0x3053d0('0x1b'),_0x3053d0('0x1c'))}),_0x5d32a4[_0x3053d0('0x2a')](_0x3053d0('0x10')),_0x5d32a4['query'](_0x3053d0('0x19')),_0x5d32a4['final'](_0x2b5b0d);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.2.js b/server/migrations/2.4.2.js index 12fe27b..07af545 100644 --- a/server/migrations/2.4.2.js +++ b/server/migrations/2.4.2.js @@ -1 +1 @@ -const a1003_0x1f2b=['DATE','indexName','enqueue','stringify','indicesType','info','prototype','blockDuration','users','inspect','changeColumn','UPDATE\x20settings\x20SET\x20allowedLoginAttempts\x20=\x200,\x20blockDuration\x20=\x200;','migration','BOOLEAN','then','addIndex','allowedLoginAttempts','disabled','exports','query\x20%s','util','removeIndex\x20%s\x20%s','removeColumn','addColumn','dropTable','query','Removed\x20column\x20%s\x20from\x20%s','renameColumn','final','../config/logger','removeIndex','tail','addIndex\x20%s\x20%s\x20%s\x20[%s]','sequelize','sequence','queryInterface','join','INTEGER','Added\x20column\x20%s\x20to\x20%s','settings','catch','ALTER\x20TABLE\x20screen_recordings\x20ENCRYPTION=\x27Y\x27;','blocked'];(function(_0x3b91a9,_0x1f2b4f){const _0x32c198=function(_0x4f93d0){while(--_0x4f93d0){_0x3b91a9['push'](_0x3b91a9['shift']());}};_0x32c198(++_0x1f2b4f);}(a1003_0x1f2b,0xfb));const a1003_0x32c1=function(_0x3b91a9,_0x1f2b4f){_0x3b91a9=_0x3b91a9-0x0;let _0x32c198=a1003_0x1f2b[_0x3b91a9];return _0x32c198;};const _0x43ace7=a1003_0x32c1;'use strict';const util=require(_0x43ace7('0x1b')),logger=require(_0x43ace7('0x24'))(_0x43ace7('0x13')),Sequence=function(){};Sequence['prototype'][_0x43ace7('0x9')]=function(_0x4f93d0){const _0x12cb43=_0x43ace7;this[_0x12cb43('0x26')]=this['tail']?this[_0x12cb43('0x26')]['finally'](_0x4f93d0):_0x4f93d0();};const Migration=function(_0x181ad4){const _0x170fee=_0x43ace7;this['queryInterface']=_0x181ad4,this[_0x170fee('0x29')]=new Sequence();};Migration[_0x43ace7('0xd')]['changeColumn']=function(_0x46ebeb,_0x1404ae,_0x242938){const _0x479a3b=_0x43ace7,_0x369ece=this;this['sequence'][_0x479a3b('0x9')](function(){const _0x4e8f4b=_0x479a3b;return _0x369ece[_0x4e8f4b('0x2a')][_0x4e8f4b('0x11')](_0x46ebeb,_0x1404ae,_0x242938)[_0x4e8f4b('0x15')](function(){const _0x4fdab4=_0x4e8f4b;logger[_0x4fdab4('0xc')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x1404ae,_0x46ebeb);})['catch'](function(_0x4ba372){const _0x4c3bea=_0x4e8f4b;logger[_0x4c3bea('0xc')](JSON[_0x4c3bea('0xa')](_0x4ba372));});});},Migration['prototype'][_0x43ace7('0x1e')]=function(_0x3a2839,_0x30480c,_0x2d6022){const _0x9b980b=_0x43ace7,_0x3dbf21=this;this['sequence'][_0x9b980b('0x9')](function(){const _0x487b2f=_0x9b980b;return _0x3dbf21['queryInterface'][_0x487b2f('0x1e')](_0x3a2839,_0x30480c,_0x2d6022)['then'](function(){const _0xbbe186=_0x487b2f;logger[_0xbbe186('0xc')](_0xbbe186('0x2'),_0x30480c,_0x3a2839);})[_0x487b2f('0x4')](function(_0x11c4b8){const _0xeb4521=_0x487b2f;logger[_0xeb4521('0xc')](JSON[_0xeb4521('0xa')](_0x11c4b8));});});},Migration['prototype']['dropTable']=function(_0xc8736c){const _0x57f03e=_0x43ace7,_0x2e45fa=this;this[_0x57f03e('0x29')][_0x57f03e('0x9')](function(){const _0x50db30=_0x57f03e;return _0x2e45fa['queryInterface'][_0x50db30('0x1f')](_0xc8736c,{'force':!![]})[_0x50db30('0x15')](function(){const _0x11a28a=_0x50db30;logger[_0x11a28a('0xc')]('table\x20dropped\x20%s',_0xc8736c);})[_0x50db30('0x4')](function(_0x273efc){const _0x3544b4=_0x50db30;logger[_0x3544b4('0xc')](JSON[_0x3544b4('0xa')](_0x273efc));});});},Migration[_0x43ace7('0xd')][_0x43ace7('0x16')]=function(_0x2ed604,_0x30d994,_0x202b2b){const _0x484484=_0x43ace7,_0x3a5b5e=this;this['sequence'][_0x484484('0x9')](function(){const _0x3481a2=_0x484484;return _0x3a5b5e[_0x3481a2('0x2a')][_0x3481a2('0x16')](_0x2ed604,_0x30d994,{'indexName':_0x202b2b['indexName'],'indicesType':_0x202b2b[_0x3481a2('0xb')]})[_0x3481a2('0x15')](function(){const _0xa34a4d=_0x3481a2;logger[_0xa34a4d('0xc')](_0xa34a4d('0x27'),_0x2ed604,_0x30d994[_0xa34a4d('0x0')](','),_0x202b2b[_0xa34a4d('0x8')],_0x202b2b[_0xa34a4d('0xb')]);})['catch'](function(_0x24bc28){const _0x269602=_0x3481a2;logger[_0x269602('0xc')](JSON[_0x269602('0xa')](_0x24bc28));});});},Migration[_0x43ace7('0xd')]['removeIndex']=function(_0x36f84b,_0x2ec9f5){const _0x1b5b95=_0x43ace7,_0x5b16b3=this;this['sequence'][_0x1b5b95('0x9')](function(){const _0x16bad1=_0x1b5b95;return _0x5b16b3['queryInterface'][_0x16bad1('0x25')](_0x36f84b,_0x2ec9f5)['then'](function(){const _0x2b7d98=_0x16bad1;logger[_0x2b7d98('0xc')](_0x2b7d98('0x1c'),_0x36f84b,_0x2ec9f5);})[_0x16bad1('0x4')](function(_0x4df28b){const _0x31ff40=_0x16bad1;logger['info'](JSON[_0x31ff40('0xa')](_0x4df28b));});});},Migration[_0x43ace7('0xd')]['query']=function(_0x55bb2d){const _0x18e049=_0x43ace7,_0x354661=this;this[_0x18e049('0x29')]['enqueue'](function(){const _0x1a631c=_0x18e049;return _0x354661['queryInterface'][_0x1a631c('0x28')][_0x1a631c('0x20')](_0x55bb2d)[_0x1a631c('0x15')](function(){const _0x41083c=_0x1a631c;logger[_0x41083c('0xc')](_0x41083c('0x1a'),_0x55bb2d);})['catch'](function(_0x2ee816){const _0x258f45=_0x1a631c;logger[_0x258f45('0xc')](JSON[_0x258f45('0xa')](_0x2ee816));});});},Migration['prototype'][_0x43ace7('0x1d')]=function(_0xcced7d,_0x2a3121){const _0x284044=_0x43ace7,_0x1019db=this;this[_0x284044('0x29')]['enqueue'](function(){const _0x39107d=_0x284044;return _0x1019db[_0x39107d('0x2a')][_0x39107d('0x1d')](_0xcced7d,_0x2a3121)['then'](function(){const _0x47582c=_0x39107d;logger[_0x47582c('0xc')](_0x47582c('0x21'),_0x2a3121,_0xcced7d);})['catch'](function(_0xb7db7e){const _0x2434ea=_0x39107d;logger[_0x2434ea('0xc')](util[_0x2434ea('0x10')](_0xb7db7e,{'showHidden':![],'depth':null}));});});},Migration[_0x43ace7('0xd')][_0x43ace7('0x22')]=function(_0x47067e,_0x2ef0a3,_0x35a25b){const _0x5d2d24=_0x43ace7,_0x13ae42=this;this[_0x5d2d24('0x29')][_0x5d2d24('0x9')](function(){const _0x426cc3=_0x5d2d24;return _0x13ae42['queryInterface'][_0x426cc3('0x22')](_0x47067e,_0x2ef0a3,_0x35a25b)[_0x426cc3('0x15')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x2ef0a3,_0x35a25b,_0x47067e);})['catch'](function(_0x9a96b2){const _0x5bc338=_0x426cc3;logger[_0x5bc338('0xc')](util['inspect'](_0x9a96b2,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x1a30f2){this['sequence']['enqueue'](function(){return _0x1a30f2();});},module[_0x43ace7('0x19')]={'up':function(_0x2dd58e,_0x465c18){return new Promise(function(_0x1dc7a0){const _0x457551=a1003_0x32c1,_0x740502=new Migration(_0x2dd58e);_0x740502[_0x457551('0x1e')](_0x457551('0x3'),_0x457551('0x17'),{'type':_0x465c18[_0x457551('0x1')],'defaultValue':0x5}),_0x740502[_0x457551('0x1e')]('settings',_0x457551('0xe'),{'type':_0x465c18[_0x457551('0x1')],'defaultValue':0xa}),_0x740502[_0x457551('0x20')](_0x457551('0x12')),_0x740502[_0x457551('0x1e')](_0x457551('0xf'),_0x457551('0x6'),{'type':_0x465c18[_0x457551('0x14')],'defaultValue':![]}),_0x740502[_0x457551('0x1e')](_0x457551('0xf'),'loginAttempts',{'type':_0x465c18[_0x457551('0x1')],'defaultValue':0x0}),_0x740502[_0x457551('0x1e')](_0x457551('0xf'),'blockedAt',{'type':_0x465c18[_0x457551('0x7')],'defaultValue':null}),_0x740502['addColumn'](_0x457551('0xf'),_0x457551('0x18'),{'type':_0x465c18['BOOLEAN'],'defaultValue':![]}),_0x740502['query'](_0x457551('0x5')),_0x740502[_0x457551('0x23')](_0x1dc7a0);});},'down':function(){}}; \ No newline at end of file +const a1003_0x2a8b=['changeColumn','settings','catch','addColumn','../config/logger','addIndex','indicesType','INTEGER','tail','query\x20%s','migration','UPDATE\x20settings\x20SET\x20allowedLoginAttempts\x20=\x200,\x20blockDuration\x20=\x200;','ALTER\x20TABLE\x20screen_recordings\x20ENCRYPTION=\x27Y\x27;','users','finally','dropTable','removeIndex\x20%s\x20%s','DATE','BOOLEAN','addIndex\x20%s\x20%s\x20%s\x20[%s]','exports','removeIndex','Added\x20column\x20%s\x20to\x20%s','util','info','enqueue','then','sequelize','indexName','Removed\x20column\x20%s\x20from\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Changed\x20column\x20%s\x20in\x20table\x20%s','renameColumn','query','inspect','final','blockDuration','removeColumn','blocked','prototype','queryInterface','stringify','sequence'];(function(_0x14f856,_0x2a8ba4){const _0x43ac05=function(_0xd404c4){while(--_0xd404c4){_0x14f856['push'](_0x14f856['shift']());}};_0x43ac05(++_0x2a8ba4);}(a1003_0x2a8b,0x185));const a1003_0x43ac=function(_0x14f856,_0x2a8ba4){_0x14f856=_0x14f856-0x0;let _0x43ac05=a1003_0x2a8b[_0x14f856];return _0x43ac05;};const _0x418a5f=a1003_0x43ac;'use strict';const util=require(_0x418a5f('0x15')),logger=require(_0x418a5f('0x2'))(_0x418a5f('0x8')),Sequence=function(){};Sequence[_0x418a5f('0x25')][_0x418a5f('0x17')]=function(_0xd404c4){const _0x5c2441=_0x418a5f;this[_0x5c2441('0x6')]=this[_0x5c2441('0x6')]?this[_0x5c2441('0x6')][_0x5c2441('0xc')](_0xd404c4):_0xd404c4();};const Migration=function(_0x2bf311){const _0x439106=_0x418a5f;this['queryInterface']=_0x2bf311,this[_0x439106('0x28')]=new Sequence();};Migration[_0x418a5f('0x25')][_0x418a5f('0x29')]=function(_0x5a0f77,_0x8705c5,_0x390e3b){const _0x4819c1=_0x418a5f,_0x39aab9=this;this[_0x4819c1('0x28')][_0x4819c1('0x17')](function(){const _0x83800a=_0x4819c1;return _0x39aab9[_0x83800a('0x26')][_0x83800a('0x29')](_0x5a0f77,_0x8705c5,_0x390e3b)['then'](function(){const _0x2f1f3a=_0x83800a;logger[_0x2f1f3a('0x16')](_0x2f1f3a('0x1d'),_0x8705c5,_0x5a0f77);})[_0x83800a('0x0')](function(_0x37832f){logger['info'](JSON['stringify'](_0x37832f));});});},Migration[_0x418a5f('0x25')][_0x418a5f('0x1')]=function(_0x3c8777,_0x2eb749,_0x5a4e6c){const _0x91230d=_0x418a5f,_0x185425=this;this[_0x91230d('0x28')][_0x91230d('0x17')](function(){const _0x3f8fef=_0x91230d;return _0x185425['queryInterface'][_0x3f8fef('0x1')](_0x3c8777,_0x2eb749,_0x5a4e6c)[_0x3f8fef('0x18')](function(){const _0x2e8c9e=_0x3f8fef;logger[_0x2e8c9e('0x16')](_0x2e8c9e('0x14'),_0x2eb749,_0x3c8777);})[_0x3f8fef('0x0')](function(_0x260ad4){const _0x3517e5=_0x3f8fef;logger[_0x3517e5('0x16')](JSON[_0x3517e5('0x27')](_0x260ad4));});});},Migration[_0x418a5f('0x25')][_0x418a5f('0xd')]=function(_0x298f02){const _0xb6c283=_0x418a5f,_0x47b60b=this;this[_0xb6c283('0x28')][_0xb6c283('0x17')](function(){const _0x52aabc=_0xb6c283;return _0x47b60b[_0x52aabc('0x26')][_0x52aabc('0xd')](_0x298f02,{'force':!![]})[_0x52aabc('0x18')](function(){logger['info']('table\x20dropped\x20%s',_0x298f02);})['catch'](function(_0x3fb145){const _0x12897a=_0x52aabc;logger[_0x12897a('0x16')](JSON[_0x12897a('0x27')](_0x3fb145));});});},Migration['prototype'][_0x418a5f('0x3')]=function(_0x59accb,_0x385f42,_0x19f6aa){const _0x11c407=_0x418a5f,_0x115d10=this;this[_0x11c407('0x28')][_0x11c407('0x17')](function(){const _0x1de8af=_0x11c407;return _0x115d10['queryInterface'][_0x1de8af('0x3')](_0x59accb,_0x385f42,{'indexName':_0x19f6aa[_0x1de8af('0x1a')],'indicesType':_0x19f6aa[_0x1de8af('0x4')]})['then'](function(){const _0xc42051=_0x1de8af;logger[_0xc42051('0x16')](_0xc42051('0x11'),_0x59accb,_0x385f42['join'](','),_0x19f6aa['indexName'],_0x19f6aa[_0xc42051('0x4')]);})[_0x1de8af('0x0')](function(_0x454289){const _0xc83874=_0x1de8af;logger[_0xc83874('0x16')](JSON[_0xc83874('0x27')](_0x454289));});});},Migration[_0x418a5f('0x25')][_0x418a5f('0x13')]=function(_0x386c68,_0x4427fa){const _0x8b3acd=_0x418a5f,_0x16367d=this;this[_0x8b3acd('0x28')]['enqueue'](function(){const _0x30fc48=_0x8b3acd;return _0x16367d[_0x30fc48('0x26')][_0x30fc48('0x13')](_0x386c68,_0x4427fa)['then'](function(){const _0x2ba6d4=_0x30fc48;logger[_0x2ba6d4('0x16')](_0x2ba6d4('0xe'),_0x386c68,_0x4427fa);})[_0x30fc48('0x0')](function(_0x466c17){const _0x2181bb=_0x30fc48;logger[_0x2181bb('0x16')](JSON[_0x2181bb('0x27')](_0x466c17));});});},Migration[_0x418a5f('0x25')][_0x418a5f('0x1f')]=function(_0x1ce28c){const _0x233d8e=_0x418a5f,_0x45ecf9=this;this[_0x233d8e('0x28')][_0x233d8e('0x17')](function(){const _0x2b9d7a=_0x233d8e;return _0x45ecf9['queryInterface'][_0x2b9d7a('0x19')][_0x2b9d7a('0x1f')](_0x1ce28c)['then'](function(){const _0x2b3b0e=_0x2b9d7a;logger[_0x2b3b0e('0x16')](_0x2b3b0e('0x7'),_0x1ce28c);})[_0x2b9d7a('0x0')](function(_0xa18486){const _0x134329=_0x2b9d7a;logger[_0x134329('0x16')](JSON[_0x134329('0x27')](_0xa18486));});});},Migration[_0x418a5f('0x25')][_0x418a5f('0x23')]=function(_0x1a2f3a,_0x5506d5){const _0x4259a7=_0x418a5f,_0x5de2c7=this;this[_0x4259a7('0x28')][_0x4259a7('0x17')](function(){const _0x36b4b8=_0x4259a7;return _0x5de2c7[_0x36b4b8('0x26')][_0x36b4b8('0x23')](_0x1a2f3a,_0x5506d5)[_0x36b4b8('0x18')](function(){const _0xb87499=_0x36b4b8;logger[_0xb87499('0x16')](_0xb87499('0x1b'),_0x5506d5,_0x1a2f3a);})[_0x36b4b8('0x0')](function(_0x1bdbc4){const _0xad1f1a=_0x36b4b8;logger[_0xad1f1a('0x16')](util[_0xad1f1a('0x20')](_0x1bdbc4,{'showHidden':![],'depth':null}));});});},Migration[_0x418a5f('0x25')]['renameColumn']=function(_0x2d77d5,_0x37e640,_0x18fd7b){const _0x21b3d8=_0x418a5f,_0x4eaa4c=this;this[_0x21b3d8('0x28')][_0x21b3d8('0x17')](function(){const _0x25b626=_0x21b3d8;return _0x4eaa4c['queryInterface'][_0x25b626('0x1e')](_0x2d77d5,_0x37e640,_0x18fd7b)['then'](function(){const _0x17448f=_0x25b626;logger[_0x17448f('0x16')](_0x17448f('0x1c'),_0x37e640,_0x18fd7b,_0x2d77d5);})['catch'](function(_0xba519e){const _0x43ef75=_0x25b626;logger[_0x43ef75('0x16')](util[_0x43ef75('0x20')](_0xba519e,{'showHidden':![],'depth':null}));});});},Migration[_0x418a5f('0x25')][_0x418a5f('0x21')]=function(_0x75942c){this['sequence']['enqueue'](function(){return _0x75942c();});},module[_0x418a5f('0x12')]={'up':function(_0xd6f7f2,_0x46179e){return new Promise(function(_0x24ca17){const _0x4c5ecc=a1003_0x43ac,_0x3d0252=new Migration(_0xd6f7f2);_0x3d0252[_0x4c5ecc('0x1')](_0x4c5ecc('0x2a'),'allowedLoginAttempts',{'type':_0x46179e[_0x4c5ecc('0x5')],'defaultValue':0x5}),_0x3d0252['addColumn']('settings',_0x4c5ecc('0x22'),{'type':_0x46179e['INTEGER'],'defaultValue':0xa}),_0x3d0252['query'](_0x4c5ecc('0x9')),_0x3d0252[_0x4c5ecc('0x1')](_0x4c5ecc('0xb'),_0x4c5ecc('0x24'),{'type':_0x46179e[_0x4c5ecc('0x10')],'defaultValue':![]}),_0x3d0252[_0x4c5ecc('0x1')](_0x4c5ecc('0xb'),'loginAttempts',{'type':_0x46179e[_0x4c5ecc('0x5')],'defaultValue':0x0}),_0x3d0252[_0x4c5ecc('0x1')](_0x4c5ecc('0xb'),'blockedAt',{'type':_0x46179e[_0x4c5ecc('0xf')],'defaultValue':null}),_0x3d0252[_0x4c5ecc('0x1')](_0x4c5ecc('0xb'),'disabled',{'type':_0x46179e['BOOLEAN'],'defaultValue':![]}),_0x3d0252[_0x4c5ecc('0x1f')](_0x4c5ecc('0xa')),_0x3d0252[_0x4c5ecc('0x21')](_0x24ca17);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.20.js b/server/migrations/2.4.20.js index ff05e99..86996a9 100644 --- a/server/migrations/2.4.20.js +++ b/server/migrations/2.4.20.js @@ -1 +1 @@ -const a1004_0x3461=['addIndex\x20%s\x20%s\x20%s\x20[%s]','Removed\x20column\x20%s\x20from\x20%s','inspect','migration','UPDATE\x20settings\x20SET\x20googleSsoEnabled\x20=\x201','Changed\x20column\x20%s\x20in\x20table\x20%s','googleSsoEnabled','sequelize','info','removeIndex','settings','enqueue','dropTable','queryInterface','prototype','catch','sequence','then','final','removeColumn','stringify','renameColumn','query','changeColumn','../config/logger','addColumn','table\x20dropped\x20%s','indexName','BOOLEAN','addIndex','join','removeIndex\x20%s\x20%s','indicesType','tail'];(function(_0x56368c,_0x34611b){const _0x1b956a=function(_0x4b56da){while(--_0x4b56da){_0x56368c['push'](_0x56368c['shift']());}};_0x1b956a(++_0x34611b);}(a1004_0x3461,0x16a));const a1004_0x1b95=function(_0x56368c,_0x34611b){_0x56368c=_0x56368c-0x0;let _0x1b956a=a1004_0x3461[_0x56368c];return _0x1b956a;};const _0x1bca14=a1004_0x1b95;'use strict';const util=require('util'),logger=require(_0x1bca14('0x2'))(_0x1bca14('0xf')),Sequence=function(){};Sequence[_0x1bca14('0x1a')][_0x1bca14('0x17')]=function(_0x4b56da){const _0x34a959=_0x1bca14;this[_0x34a959('0xb')]=this[_0x34a959('0xb')]?this[_0x34a959('0xb')]['finally'](_0x4b56da):_0x4b56da();};const Migration=function(_0x3c7856){const _0x278ff4=_0x1bca14;this['queryInterface']=_0x3c7856,this[_0x278ff4('0x1c')]=new Sequence();};Migration['prototype'][_0x1bca14('0x1')]=function(_0x39f8bc,_0x5ca31b,_0x403a69){const _0x4c9091=_0x1bca14,_0x4699e3=this;this[_0x4c9091('0x1c')]['enqueue'](function(){const _0x72235e=_0x4c9091;return _0x4699e3['queryInterface']['changeColumn'](_0x39f8bc,_0x5ca31b,_0x403a69)[_0x72235e('0x1d')](function(){const _0x5e9c49=_0x72235e;logger[_0x5e9c49('0x14')](_0x5e9c49('0x11'),_0x5ca31b,_0x39f8bc);})[_0x72235e('0x1b')](function(_0x4a853e){const _0x1ccc85=_0x72235e;logger['info'](JSON[_0x1ccc85('0x20')](_0x4a853e));});});},Migration[_0x1bca14('0x1a')]['addColumn']=function(_0x5f24a3,_0x407868,_0x4c5c15){const _0x25b346=_0x1bca14,_0x4e278c=this;this['sequence'][_0x25b346('0x17')](function(){const _0xfca3f4=_0x25b346;return _0x4e278c[_0xfca3f4('0x19')][_0xfca3f4('0x3')](_0x5f24a3,_0x407868,_0x4c5c15)[_0xfca3f4('0x1d')](function(){const _0x38fe94=_0xfca3f4;logger[_0x38fe94('0x14')]('Added\x20column\x20%s\x20to\x20%s',_0x407868,_0x5f24a3);})['catch'](function(_0x672398){const _0x47c182=_0xfca3f4;logger[_0x47c182('0x14')](JSON[_0x47c182('0x20')](_0x672398));});});},Migration[_0x1bca14('0x1a')][_0x1bca14('0x18')]=function(_0x518e1f){const _0x4a4461=_0x1bca14,_0x187d88=this;this['sequence'][_0x4a4461('0x17')](function(){const _0x2197eb=_0x4a4461;return _0x187d88[_0x2197eb('0x19')]['dropTable'](_0x518e1f,{'force':!![]})[_0x2197eb('0x1d')](function(){const _0x5217ed=_0x2197eb;logger['info'](_0x5217ed('0x4'),_0x518e1f);})[_0x2197eb('0x1b')](function(_0x10876d){const _0x2b4820=_0x2197eb;logger[_0x2b4820('0x14')](JSON[_0x2b4820('0x20')](_0x10876d));});});},Migration[_0x1bca14('0x1a')][_0x1bca14('0x7')]=function(_0x37757a,_0x22723c,_0xadf9d7){const _0x12f8fc=_0x1bca14,_0x1481e8=this;this[_0x12f8fc('0x1c')][_0x12f8fc('0x17')](function(){const _0x42e0d3=_0x12f8fc;return _0x1481e8['queryInterface'][_0x42e0d3('0x7')](_0x37757a,_0x22723c,{'indexName':_0xadf9d7[_0x42e0d3('0x5')],'indicesType':_0xadf9d7['indicesType']})['then'](function(){const _0x2e8c31=_0x42e0d3;logger[_0x2e8c31('0x14')](_0x2e8c31('0xc'),_0x37757a,_0x22723c[_0x2e8c31('0x8')](','),_0xadf9d7['indexName'],_0xadf9d7[_0x2e8c31('0xa')]);})[_0x42e0d3('0x1b')](function(_0x37777b){const _0x144c05=_0x42e0d3;logger['info'](JSON[_0x144c05('0x20')](_0x37777b));});});},Migration[_0x1bca14('0x1a')][_0x1bca14('0x15')]=function(_0x5143be,_0x50515a){const _0x515055=_0x1bca14,_0x4ab7f5=this;this['sequence'][_0x515055('0x17')](function(){const _0x3b29fa=_0x515055;return _0x4ab7f5[_0x3b29fa('0x19')][_0x3b29fa('0x15')](_0x5143be,_0x50515a)[_0x3b29fa('0x1d')](function(){const _0x5ae372=_0x3b29fa;logger[_0x5ae372('0x14')](_0x5ae372('0x9'),_0x5143be,_0x50515a);})[_0x3b29fa('0x1b')](function(_0x38d0db){const _0x23ddf5=_0x3b29fa;logger[_0x23ddf5('0x14')](JSON['stringify'](_0x38d0db));});});},Migration[_0x1bca14('0x1a')][_0x1bca14('0x0')]=function(_0x4f2093){const _0x20b202=_0x1bca14,_0x37c4b2=this;this[_0x20b202('0x1c')][_0x20b202('0x17')](function(){const _0x35e58e=_0x20b202;return _0x37c4b2[_0x35e58e('0x19')][_0x35e58e('0x13')][_0x35e58e('0x0')](_0x4f2093)[_0x35e58e('0x1d')](function(){const _0x19ba7f=_0x35e58e;logger[_0x19ba7f('0x14')]('query\x20%s',_0x4f2093);})[_0x35e58e('0x1b')](function(_0x5d7a68){const _0x18a4ab=_0x35e58e;logger[_0x18a4ab('0x14')](JSON[_0x18a4ab('0x20')](_0x5d7a68));});});},Migration[_0x1bca14('0x1a')][_0x1bca14('0x1f')]=function(_0x481ec5,_0xe81c6f){const _0x1b2da1=_0x1bca14,_0x536957=this;this[_0x1b2da1('0x1c')][_0x1b2da1('0x17')](function(){const _0x29205b=_0x1b2da1;return _0x536957[_0x29205b('0x19')][_0x29205b('0x1f')](_0x481ec5,_0xe81c6f)[_0x29205b('0x1d')](function(){const _0x2a5e88=_0x29205b;logger['info'](_0x2a5e88('0xd'),_0xe81c6f,_0x481ec5);})[_0x29205b('0x1b')](function(_0x7490ea){const _0x7da6ea=_0x29205b;logger[_0x7da6ea('0x14')](util[_0x7da6ea('0xe')](_0x7490ea,{'showHidden':![],'depth':null}));});});},Migration[_0x1bca14('0x1a')][_0x1bca14('0x21')]=function(_0x14a301,_0x2af8e1,_0x1e82e4){const _0x4f452b=_0x1bca14,_0x28d11b=this;this[_0x4f452b('0x1c')][_0x4f452b('0x17')](function(){const _0x9c8842=_0x4f452b;return _0x28d11b[_0x9c8842('0x19')]['renameColumn'](_0x14a301,_0x2af8e1,_0x1e82e4)[_0x9c8842('0x1d')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x2af8e1,_0x1e82e4,_0x14a301);})[_0x9c8842('0x1b')](function(_0x56b423){const _0x207fc9=_0x9c8842;logger[_0x207fc9('0x14')](util['inspect'](_0x56b423,{'showHidden':![],'depth':null}));});});},Migration[_0x1bca14('0x1a')]['final']=function(_0x42712e){this['sequence']['enqueue'](function(){return _0x42712e();});},module['exports']={'up':function(_0x5216e6,_0x29308b){return new Promise(function(_0x2454d5){const _0x2f8c0b=a1004_0x1b95,_0x26fda2=new Migration(_0x5216e6);_0x26fda2[_0x2f8c0b('0x3')](_0x2f8c0b('0x16'),_0x2f8c0b('0x12'),{'type':_0x29308b[_0x2f8c0b('0x6')],'defaultValue':![]}),_0x26fda2['query'](_0x2f8c0b('0x10')),_0x26fda2[_0x2f8c0b('0x1e')](_0x2454d5);});},'down':function(){}}; \ No newline at end of file +const a1004_0xc2b0=['addIndex\x20%s\x20%s\x20%s\x20[%s]','query','indicesType','dropTable','catch','inspect','../config/logger','BOOLEAN','Added\x20column\x20%s\x20to\x20%s','then','removeIndex','removeIndex\x20%s\x20%s','Removed\x20column\x20%s\x20from\x20%s','addIndex','stringify','renameColumn','removeColumn','enqueue','googleSsoEnabled','query\x20%s','settings','queryInterface','migration','info','Changed\x20column\x20%s\x20in\x20table\x20%s','changeColumn','tail','sequelize','final','indexName','UPDATE\x20settings\x20SET\x20googleSsoEnabled\x20=\x201','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','sequence','prototype','addColumn'];(function(_0x6d27c4,_0xc2b09d){const _0x371c55=function(_0x47de24){while(--_0x47de24){_0x6d27c4['push'](_0x6d27c4['shift']());}};_0x371c55(++_0xc2b09d);}(a1004_0xc2b0,0x131));const a1004_0x371c=function(_0x6d27c4,_0xc2b09d){_0x6d27c4=_0x6d27c4-0x0;let _0x371c55=a1004_0xc2b0[_0x6d27c4];return _0x371c55;};const _0x1d7d05=a1004_0x371c;'use strict';const util=require('util'),logger=require(_0x1d7d05('0x10'))(_0x1d7d05('0x20')),Sequence=function(){};Sequence[_0x1d7d05('0x8')][_0x1d7d05('0x1b')]=function(_0x47de24){const _0x5ad2bc=_0x1d7d05;this[_0x5ad2bc('0x1')]=this[_0x5ad2bc('0x1')]?this['tail']['finally'](_0x47de24):_0x47de24();};const Migration=function(_0x5aad08){const _0x428540=_0x1d7d05;this[_0x428540('0x1f')]=_0x5aad08,this['sequence']=new Sequence();};Migration[_0x1d7d05('0x8')][_0x1d7d05('0x0')]=function(_0x2d0ba4,_0x368d44,_0x47ab8c){const _0x24a7e5=_0x1d7d05,_0x445207=this;this[_0x24a7e5('0x7')][_0x24a7e5('0x1b')](function(){const _0x440162=_0x24a7e5;return _0x445207['queryInterface'][_0x440162('0x0')](_0x2d0ba4,_0x368d44,_0x47ab8c)[_0x440162('0x13')](function(){const _0x171082=_0x440162;logger[_0x171082('0x21')](_0x171082('0x22'),_0x368d44,_0x2d0ba4);})[_0x440162('0xe')](function(_0x4b56e1){const _0x8313d8=_0x440162;logger[_0x8313d8('0x21')](JSON[_0x8313d8('0x18')](_0x4b56e1));});});},Migration['prototype'][_0x1d7d05('0x9')]=function(_0x201754,_0x1bed67,_0x437e6f){const _0x3dbde2=_0x1d7d05,_0x374483=this;this[_0x3dbde2('0x7')][_0x3dbde2('0x1b')](function(){const _0x48fff0=_0x3dbde2;return _0x374483[_0x48fff0('0x1f')]['addColumn'](_0x201754,_0x1bed67,_0x437e6f)[_0x48fff0('0x13')](function(){const _0x2646a5=_0x48fff0;logger[_0x2646a5('0x21')](_0x2646a5('0x12'),_0x1bed67,_0x201754);})[_0x48fff0('0xe')](function(_0x417a0b){const _0x25b502=_0x48fff0;logger[_0x25b502('0x21')](JSON['stringify'](_0x417a0b));});});},Migration[_0x1d7d05('0x8')]['dropTable']=function(_0x268a2a){const _0x40e43b=_0x1d7d05,_0x51c154=this;this[_0x40e43b('0x7')]['enqueue'](function(){const _0x4a0626=_0x40e43b;return _0x51c154[_0x4a0626('0x1f')][_0x4a0626('0xd')](_0x268a2a,{'force':!![]})[_0x4a0626('0x13')](function(){logger['info']('table\x20dropped\x20%s',_0x268a2a);})[_0x4a0626('0xe')](function(_0xcc0467){const _0x443fcf=_0x4a0626;logger[_0x443fcf('0x21')](JSON['stringify'](_0xcc0467));});});},Migration[_0x1d7d05('0x8')][_0x1d7d05('0x17')]=function(_0x1f32fa,_0x11c937,_0x44d162){const _0x3dbd4b=_0x1d7d05,_0x22b8ad=this;this[_0x3dbd4b('0x7')][_0x3dbd4b('0x1b')](function(){const _0xfac431=_0x3dbd4b;return _0x22b8ad['queryInterface']['addIndex'](_0x1f32fa,_0x11c937,{'indexName':_0x44d162[_0xfac431('0x4')],'indicesType':_0x44d162[_0xfac431('0xc')]})[_0xfac431('0x13')](function(){const _0x4bbe2e=_0xfac431;logger[_0x4bbe2e('0x21')](_0x4bbe2e('0xa'),_0x1f32fa,_0x11c937['join'](','),_0x44d162['indexName'],_0x44d162[_0x4bbe2e('0xc')]);})[_0xfac431('0xe')](function(_0x1ca49f){const _0x108d0b=_0xfac431;logger[_0x108d0b('0x21')](JSON[_0x108d0b('0x18')](_0x1ca49f));});});},Migration[_0x1d7d05('0x8')][_0x1d7d05('0x14')]=function(_0x57ca2d,_0x4b6a){const _0x275959=_0x1d7d05,_0x3aea94=this;this[_0x275959('0x7')][_0x275959('0x1b')](function(){const _0x4c8ff2=_0x275959;return _0x3aea94['queryInterface'][_0x4c8ff2('0x14')](_0x57ca2d,_0x4b6a)[_0x4c8ff2('0x13')](function(){const _0x5d7f53=_0x4c8ff2;logger[_0x5d7f53('0x21')](_0x5d7f53('0x15'),_0x57ca2d,_0x4b6a);})[_0x4c8ff2('0xe')](function(_0x305f03){const _0x29a6b3=_0x4c8ff2;logger['info'](JSON[_0x29a6b3('0x18')](_0x305f03));});});},Migration[_0x1d7d05('0x8')][_0x1d7d05('0xb')]=function(_0x2f530c){const _0x144bae=_0x1d7d05,_0x104927=this;this[_0x144bae('0x7')][_0x144bae('0x1b')](function(){const _0x42bc75=_0x144bae;return _0x104927[_0x42bc75('0x1f')][_0x42bc75('0x2')][_0x42bc75('0xb')](_0x2f530c)[_0x42bc75('0x13')](function(){const _0x3bcbd2=_0x42bc75;logger[_0x3bcbd2('0x21')](_0x3bcbd2('0x1d'),_0x2f530c);})[_0x42bc75('0xe')](function(_0x284287){const _0x3ba762=_0x42bc75;logger[_0x3ba762('0x21')](JSON[_0x3ba762('0x18')](_0x284287));});});},Migration[_0x1d7d05('0x8')][_0x1d7d05('0x1a')]=function(_0x1de20c,_0x39e762){const _0x21f45e=_0x1d7d05,_0x37b662=this;this[_0x21f45e('0x7')]['enqueue'](function(){const _0x59d8e2=_0x21f45e;return _0x37b662[_0x59d8e2('0x1f')]['removeColumn'](_0x1de20c,_0x39e762)[_0x59d8e2('0x13')](function(){const _0x548b5b=_0x59d8e2;logger[_0x548b5b('0x21')](_0x548b5b('0x16'),_0x39e762,_0x1de20c);})[_0x59d8e2('0xe')](function(_0x11d8e1){const _0x6c0ced=_0x59d8e2;logger[_0x6c0ced('0x21')](util[_0x6c0ced('0xf')](_0x11d8e1,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x1d7d05('0x19')]=function(_0x1ec756,_0x10d734,_0x521bcc){const _0x3e87fc=this;this['sequence']['enqueue'](function(){const _0x23f641=a1004_0x371c;return _0x3e87fc[_0x23f641('0x1f')][_0x23f641('0x19')](_0x1ec756,_0x10d734,_0x521bcc)['then'](function(){const _0x496094=_0x23f641;logger[_0x496094('0x21')](_0x496094('0x6'),_0x10d734,_0x521bcc,_0x1ec756);})['catch'](function(_0x16acff){const _0x35ab94=_0x23f641;logger['info'](util[_0x35ab94('0xf')](_0x16acff,{'showHidden':![],'depth':null}));});});},Migration[_0x1d7d05('0x8')]['final']=function(_0x5b801d){this['sequence']['enqueue'](function(){return _0x5b801d();});},module['exports']={'up':function(_0x402ac8,_0x387e76){return new Promise(function(_0x3fad93){const _0xb76c39=a1004_0x371c,_0x16b73e=new Migration(_0x402ac8);_0x16b73e['addColumn'](_0xb76c39('0x1e'),_0xb76c39('0x1c'),{'type':_0x387e76[_0xb76c39('0x11')],'defaultValue':![]}),_0x16b73e[_0xb76c39('0xb')](_0xb76c39('0x5')),_0x16b73e[_0xb76c39('0x3')](_0x3fad93);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.21.js b/server/migrations/2.4.21.js index 44f5b31..c0aebba 100644 --- a/server/migrations/2.4.21.js +++ b/server/migrations/2.4.21.js @@ -1 +1 @@ -const a1005_0x298f=['indexName','finally','addIndex\x20%s\x20%s\x20%s\x20[%s]','final','stringify','inspect','sequelize','prototype','removeIndex','sequence','queryInterface','removeIndex\x20%s\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','then','util','addColumn','renameColumn','join','query','catch','changeColumn','exports','info','removeColumn','indicesType','enqueue','Added\x20column\x20%s\x20to\x20%s','dropTable','query\x20%s','addIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','../config/logger','tail'];(function(_0x1b1769,_0x298f4d){const _0x216669=function(_0x3ffcff){while(--_0x3ffcff){_0x1b1769['push'](_0x1b1769['shift']());}};_0x216669(++_0x298f4d);}(a1005_0x298f,0x117));const a1005_0x2166=function(_0x1b1769,_0x298f4d){_0x1b1769=_0x1b1769-0x0;let _0x216669=a1005_0x298f[_0x1b1769];return _0x216669;};const _0x4210b9=a1005_0x2166;'use strict';const util=require(_0x4210b9('0x20')),logger=require(_0x4210b9('0x10'))('migration'),Sequence=function(){};Sequence[_0x4210b9('0x19')][_0x4210b9('0xa')]=function(_0x3ffcff){const _0x29fb11=_0x4210b9;this[_0x29fb11('0x11')]=this['tail']?this[_0x29fb11('0x11')][_0x29fb11('0x13')](_0x3ffcff):_0x3ffcff();};const Migration=function(_0x1886ec){const _0x5c9c34=_0x4210b9;this[_0x5c9c34('0x1c')]=_0x1886ec,this['sequence']=new Sequence();};Migration[_0x4210b9('0x19')][_0x4210b9('0x5')]=function(_0x5a0fda,_0x4ca41a,_0x57048e){const _0x4497de=_0x4210b9,_0x59f4c5=this;this['sequence'][_0x4497de('0xa')](function(){const _0x43cf51=_0x4497de;return _0x59f4c5[_0x43cf51('0x1c')][_0x43cf51('0x5')](_0x5a0fda,_0x4ca41a,_0x57048e)[_0x43cf51('0x1f')](function(){const _0x359dc6=_0x43cf51;logger[_0x359dc6('0x7')](_0x359dc6('0xf'),_0x4ca41a,_0x5a0fda);})[_0x43cf51('0x4')](function(_0x1e9d80){const _0x24b959=_0x43cf51;logger[_0x24b959('0x7')](JSON[_0x24b959('0x16')](_0x1e9d80));});});},Migration['prototype']['addColumn']=function(_0x591ede,_0x4c5593,_0x1a6c4c){const _0xdf9cce=_0x4210b9,_0x336bf1=this;this['sequence'][_0xdf9cce('0xa')](function(){const _0xb4a379=_0xdf9cce;return _0x336bf1['queryInterface'][_0xb4a379('0x0')](_0x591ede,_0x4c5593,_0x1a6c4c)[_0xb4a379('0x1f')](function(){const _0xcc417c=_0xb4a379;logger[_0xcc417c('0x7')](_0xcc417c('0xb'),_0x4c5593,_0x591ede);})[_0xb4a379('0x4')](function(_0x3e1e7e){const _0x5d8326=_0xb4a379;logger[_0x5d8326('0x7')](JSON[_0x5d8326('0x16')](_0x3e1e7e));});});},Migration[_0x4210b9('0x19')]['dropTable']=function(_0x4aa45a){const _0x240f7c=_0x4210b9,_0x3de1bf=this;this[_0x240f7c('0x1b')][_0x240f7c('0xa')](function(){const _0x806e4f=_0x240f7c;return _0x3de1bf[_0x806e4f('0x1c')][_0x806e4f('0xc')](_0x4aa45a,{'force':!![]})[_0x806e4f('0x1f')](function(){const _0x34562d=_0x806e4f;logger[_0x34562d('0x7')]('table\x20dropped\x20%s',_0x4aa45a);})[_0x806e4f('0x4')](function(_0x1bb3a7){const _0x2e2c83=_0x806e4f;logger[_0x2e2c83('0x7')](JSON['stringify'](_0x1bb3a7));});});},Migration[_0x4210b9('0x19')][_0x4210b9('0xe')]=function(_0x1e6232,_0x55def8,_0x456878){const _0x24eac8=_0x4210b9,_0xa0e429=this;this[_0x24eac8('0x1b')][_0x24eac8('0xa')](function(){const _0x1844cc=_0x24eac8;return _0xa0e429[_0x1844cc('0x1c')][_0x1844cc('0xe')](_0x1e6232,_0x55def8,{'indexName':_0x456878['indexName'],'indicesType':_0x456878[_0x1844cc('0x9')]})[_0x1844cc('0x1f')](function(){const _0x29f13e=_0x1844cc;logger[_0x29f13e('0x7')](_0x29f13e('0x14'),_0x1e6232,_0x55def8[_0x29f13e('0x2')](','),_0x456878[_0x29f13e('0x12')],_0x456878[_0x29f13e('0x9')]);})[_0x1844cc('0x4')](function(_0x44c7ca){logger['info'](JSON['stringify'](_0x44c7ca));});});},Migration[_0x4210b9('0x19')][_0x4210b9('0x1a')]=function(_0x2ed4ed,_0x38414e){const _0xf6233d=_0x4210b9,_0x12442e=this;this[_0xf6233d('0x1b')]['enqueue'](function(){const _0x230283=_0xf6233d;return _0x12442e[_0x230283('0x1c')][_0x230283('0x1a')](_0x2ed4ed,_0x38414e)['then'](function(){const _0x225542=_0x230283;logger[_0x225542('0x7')](_0x225542('0x1d'),_0x2ed4ed,_0x38414e);})['catch'](function(_0x582960){const _0x1647a7=_0x230283;logger[_0x1647a7('0x7')](JSON['stringify'](_0x582960));});});},Migration['prototype'][_0x4210b9('0x3')]=function(_0x4d5e3c){const _0x529074=_0x4210b9,_0x46aca9=this;this[_0x529074('0x1b')][_0x529074('0xa')](function(){const _0x35bd72=_0x529074;return _0x46aca9['queryInterface'][_0x35bd72('0x18')][_0x35bd72('0x3')](_0x4d5e3c)[_0x35bd72('0x1f')](function(){const _0x42b01f=_0x35bd72;logger[_0x42b01f('0x7')](_0x42b01f('0xd'),_0x4d5e3c);})[_0x35bd72('0x4')](function(_0x54a58b){const _0x43292e=_0x35bd72;logger[_0x43292e('0x7')](JSON[_0x43292e('0x16')](_0x54a58b));});});},Migration[_0x4210b9('0x19')]['removeColumn']=function(_0x3298a1,_0x3de6e1){const _0x396b85=_0x4210b9,_0x2f3432=this;this[_0x396b85('0x1b')]['enqueue'](function(){const _0x1ce57d=_0x396b85;return _0x2f3432[_0x1ce57d('0x1c')][_0x1ce57d('0x8')](_0x3298a1,_0x3de6e1)['then'](function(){const _0x532a7e=_0x1ce57d;logger[_0x532a7e('0x7')]('Removed\x20column\x20%s\x20from\x20%s',_0x3de6e1,_0x3298a1);})[_0x1ce57d('0x4')](function(_0x5b0d7b){const _0x281cfa=_0x1ce57d;logger[_0x281cfa('0x7')](util[_0x281cfa('0x17')](_0x5b0d7b,{'showHidden':![],'depth':null}));});});},Migration[_0x4210b9('0x19')][_0x4210b9('0x1')]=function(_0x11140b,_0x4d7a1c,_0x33687e){const _0x5360eb=_0x4210b9,_0x339cbc=this;this[_0x5360eb('0x1b')][_0x5360eb('0xa')](function(){const _0x188b6a=_0x5360eb;return _0x339cbc['queryInterface']['renameColumn'](_0x11140b,_0x4d7a1c,_0x33687e)[_0x188b6a('0x1f')](function(){const _0xeeea94=_0x188b6a;logger[_0xeeea94('0x7')](_0xeeea94('0x1e'),_0x4d7a1c,_0x33687e,_0x11140b);})[_0x188b6a('0x4')](function(_0x59951f){logger['info'](util['inspect'](_0x59951f,{'showHidden':![],'depth':null}));});});},Migration[_0x4210b9('0x19')]['final']=function(_0x53f718){const _0x5608f8=_0x4210b9;this[_0x5608f8('0x1b')][_0x5608f8('0xa')](function(){return _0x53f718();});},module[_0x4210b9('0x6')]={'up':function(_0x1a8646){return new Promise(function(_0x39887f){const _0x4da681=a1005_0x2166,_0x5771e5=new Migration(_0x1a8646);_0x5771e5[_0x4da681('0x15')](_0x39887f);});},'down':function(){}}; \ No newline at end of file +const a1005_0x10f7=['catch','then','Removed\x20column\x20%s\x20from\x20%s','indexName','finally','query\x20%s','query','join','changeColumn','sequelize','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex\x20%s\x20%s\x20%s\x20[%s]','final','util','dropTable','info','Added\x20column\x20%s\x20to\x20%s','removeIndex','queryInterface','addColumn','renameColumn','enqueue','tail','../config/logger','exports','addIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','stringify','inspect','sequence','prototype','removeIndex\x20%s\x20%s','indicesType'];(function(_0x31fef7,_0x10f71d){const _0x8db9bb=function(_0x40435e){while(--_0x40435e){_0x31fef7['push'](_0x31fef7['shift']());}};_0x8db9bb(++_0x10f71d);}(a1005_0x10f7,0x1ec));const a1005_0x8db9=function(_0x31fef7,_0x10f71d){_0x31fef7=_0x31fef7-0x0;let _0x8db9bb=a1005_0x10f7[_0x31fef7];return _0x8db9bb;};const _0x3aa422=a1005_0x8db9;'use strict';const util=require(_0x3aa422('0x10')),logger=require(_0x3aa422('0x1a'))('migration'),Sequence=function(){};Sequence['prototype'][_0x3aa422('0x18')]=function(_0x40435e){const _0x228380=_0x3aa422;this['tail']=this[_0x228380('0x19')]?this[_0x228380('0x19')][_0x228380('0x7')](_0x40435e):_0x40435e();};const Migration=function(_0x27f433){const _0x1b4901=_0x3aa422;this[_0x1b4901('0x15')]=_0x27f433,this[_0x1b4901('0x20')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x5509c4,_0x5d3048,_0x547bed){const _0x47bcc1=_0x3aa422,_0x33ea1e=this;this[_0x47bcc1('0x20')][_0x47bcc1('0x18')](function(){const _0x5eb7d6=_0x47bcc1;return _0x33ea1e[_0x5eb7d6('0x15')][_0x5eb7d6('0xb')](_0x5509c4,_0x5d3048,_0x547bed)[_0x5eb7d6('0x4')](function(){const _0x231679=_0x5eb7d6;logger[_0x231679('0x12')](_0x231679('0x1d'),_0x5d3048,_0x5509c4);})[_0x5eb7d6('0x3')](function(_0x358d42){const _0xb62c34=_0x5eb7d6;logger[_0xb62c34('0x12')](JSON[_0xb62c34('0x1e')](_0x358d42));});});},Migration[_0x3aa422('0x0')][_0x3aa422('0x16')]=function(_0x3598e3,_0x2fba75,_0x5d8a04){const _0x3d014c=_0x3aa422,_0x5197e5=this;this[_0x3d014c('0x20')][_0x3d014c('0x18')](function(){const _0x52d29a=_0x3d014c;return _0x5197e5[_0x52d29a('0x15')][_0x52d29a('0x16')](_0x3598e3,_0x2fba75,_0x5d8a04)[_0x52d29a('0x4')](function(){const _0x230f58=_0x52d29a;logger[_0x230f58('0x12')](_0x230f58('0x13'),_0x2fba75,_0x3598e3);})[_0x52d29a('0x3')](function(_0x3a7038){const _0x5101c7=_0x52d29a;logger['info'](JSON[_0x5101c7('0x1e')](_0x3a7038));});});},Migration[_0x3aa422('0x0')][_0x3aa422('0x11')]=function(_0x342c12){const _0x213ea9=_0x3aa422,_0x29be5f=this;this['sequence'][_0x213ea9('0x18')](function(){const _0x492e83=_0x213ea9;return _0x29be5f[_0x492e83('0x15')][_0x492e83('0x11')](_0x342c12,{'force':!![]})[_0x492e83('0x4')](function(){const _0x1ec16e=_0x492e83;logger[_0x1ec16e('0x12')]('table\x20dropped\x20%s',_0x342c12);})[_0x492e83('0x3')](function(_0x4e0cf6){const _0x13291d=_0x492e83;logger[_0x13291d('0x12')](JSON[_0x13291d('0x1e')](_0x4e0cf6));});});},Migration[_0x3aa422('0x0')][_0x3aa422('0x1c')]=function(_0x50b5bb,_0x4f9b6d,_0x110b37){const _0x27d355=_0x3aa422,_0x18424f=this;this[_0x27d355('0x20')][_0x27d355('0x18')](function(){const _0x5b7dee=_0x27d355;return _0x18424f[_0x5b7dee('0x15')][_0x5b7dee('0x1c')](_0x50b5bb,_0x4f9b6d,{'indexName':_0x110b37['indexName'],'indicesType':_0x110b37[_0x5b7dee('0x2')]})[_0x5b7dee('0x4')](function(){const _0x11a180=_0x5b7dee;logger[_0x11a180('0x12')](_0x11a180('0xe'),_0x50b5bb,_0x4f9b6d[_0x11a180('0xa')](','),_0x110b37[_0x11a180('0x6')],_0x110b37['indicesType']);})[_0x5b7dee('0x3')](function(_0x5b6840){const _0x52c51a=_0x5b7dee;logger[_0x52c51a('0x12')](JSON[_0x52c51a('0x1e')](_0x5b6840));});});},Migration['prototype'][_0x3aa422('0x14')]=function(_0x4c0c75,_0x2ea57a){const _0x49fa7f=_0x3aa422,_0x2520be=this;this[_0x49fa7f('0x20')][_0x49fa7f('0x18')](function(){const _0x319a23=_0x49fa7f;return _0x2520be[_0x319a23('0x15')][_0x319a23('0x14')](_0x4c0c75,_0x2ea57a)[_0x319a23('0x4')](function(){const _0x2ac7d7=_0x319a23;logger[_0x2ac7d7('0x12')](_0x2ac7d7('0x1'),_0x4c0c75,_0x2ea57a);})[_0x319a23('0x3')](function(_0x212f37){const _0x3d3c95=_0x319a23;logger[_0x3d3c95('0x12')](JSON['stringify'](_0x212f37));});});},Migration[_0x3aa422('0x0')][_0x3aa422('0x9')]=function(_0x296ff8){const _0x5657ca=_0x3aa422,_0xbc1666=this;this[_0x5657ca('0x20')]['enqueue'](function(){const _0x2ac5b3=_0x5657ca;return _0xbc1666[_0x2ac5b3('0x15')][_0x2ac5b3('0xc')][_0x2ac5b3('0x9')](_0x296ff8)[_0x2ac5b3('0x4')](function(){const _0x11df93=_0x2ac5b3;logger[_0x11df93('0x12')](_0x11df93('0x8'),_0x296ff8);})[_0x2ac5b3('0x3')](function(_0x14cfab){const _0x1b8512=_0x2ac5b3;logger[_0x1b8512('0x12')](JSON[_0x1b8512('0x1e')](_0x14cfab));});});},Migration['prototype']['removeColumn']=function(_0x3dca7d,_0x19cd49){const _0x12f7bd=_0x3aa422,_0x25cb8d=this;this[_0x12f7bd('0x20')][_0x12f7bd('0x18')](function(){const _0x1fad33=_0x12f7bd;return _0x25cb8d['queryInterface']['removeColumn'](_0x3dca7d,_0x19cd49)[_0x1fad33('0x4')](function(){const _0x1d585b=_0x1fad33;logger['info'](_0x1d585b('0x5'),_0x19cd49,_0x3dca7d);})[_0x1fad33('0x3')](function(_0x472e16){const _0x3b9778=_0x1fad33;logger[_0x3b9778('0x12')](util[_0x3b9778('0x1f')](_0x472e16,{'showHidden':![],'depth':null}));});});},Migration[_0x3aa422('0x0')][_0x3aa422('0x17')]=function(_0x3722bd,_0x54dbe0,_0x353ceb){const _0x227294=_0x3aa422,_0x54f924=this;this['sequence'][_0x227294('0x18')](function(){const _0x4e9efa=_0x227294;return _0x54f924[_0x4e9efa('0x15')]['renameColumn'](_0x3722bd,_0x54dbe0,_0x353ceb)[_0x4e9efa('0x4')](function(){const _0x45f0c3=_0x4e9efa;logger['info'](_0x45f0c3('0xd'),_0x54dbe0,_0x353ceb,_0x3722bd);})[_0x4e9efa('0x3')](function(_0x5f29fd){const _0x11be66=_0x4e9efa;logger[_0x11be66('0x12')](util[_0x11be66('0x1f')](_0x5f29fd,{'showHidden':![],'depth':null}));});});},Migration[_0x3aa422('0x0')][_0x3aa422('0xf')]=function(_0x410201){const _0x356088=_0x3aa422;this[_0x356088('0x20')][_0x356088('0x18')](function(){return _0x410201();});},module[_0x3aa422('0x1b')]={'up':function(_0x34c52e){return new Promise(function(_0x80869b){const _0x33175f=new Migration(_0x34c52e);_0x33175f['final'](_0x80869b);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.3.js b/server/migrations/2.4.3.js index 52ddf7e..3abfde9 100644 --- a/server/migrations/2.4.3.js +++ b/server/migrations/2.4.3.js @@ -1 +1 @@ -const a1006_0x1ab7=['final','enqueue','tail','util','prototype','indexName','removeIndex\x20%s\x20%s','then','Removed\x20column\x20%s\x20from\x20%s','join','exports','sequence','renameColumn','catch','table\x20dropped\x20%s','inspect','query','info','Changed\x20column\x20%s\x20in\x20table\x20%s','dropTable','removeColumn','queryInterface','finally','../config/logger','Added\x20column\x20%s\x20to\x20%s','migration','indicesType','addIndex','addIndex\x20%s\x20%s\x20%s\x20[%s]','query\x20%s','stringify','changeColumn','removeIndex'];(function(_0x308060,_0x1ab760){const _0x34fcef=function(_0x2c7118){while(--_0x2c7118){_0x308060['push'](_0x308060['shift']());}};_0x34fcef(++_0x1ab760);}(a1006_0x1ab7,0xc4));const a1006_0x34fc=function(_0x308060,_0x1ab760){_0x308060=_0x308060-0x0;let _0x34fcef=a1006_0x1ab7[_0x308060];return _0x34fcef;};const _0x2b06f8=a1006_0x34fc;'use strict';const util=require(_0x2b06f8('0x5')),logger=require(_0x2b06f8('0x19'))(_0x2b06f8('0x1b')),Sequence=function(){};Sequence[_0x2b06f8('0x6')]['enqueue']=function(_0x2c7118){const _0x51c6d2=_0x2b06f8;this[_0x51c6d2('0x4')]=this['tail']?this[_0x51c6d2('0x4')][_0x51c6d2('0x18')](_0x2c7118):_0x2c7118();};const Migration=function(_0x450f0f){const _0x154f1e=_0x2b06f8;this[_0x154f1e('0x17')]=_0x450f0f,this[_0x154f1e('0xd')]=new Sequence();};Migration[_0x2b06f8('0x6')][_0x2b06f8('0x0')]=function(_0x184919,_0x54c5bf,_0x7a52c2){const _0x1e9e26=_0x2b06f8,_0x523611=this;this['sequence'][_0x1e9e26('0x3')](function(){const _0x50203d=_0x1e9e26;return _0x523611[_0x50203d('0x17')][_0x50203d('0x0')](_0x184919,_0x54c5bf,_0x7a52c2)['then'](function(){const _0x5645e2=_0x50203d;logger['info'](_0x5645e2('0x14'),_0x54c5bf,_0x184919);})[_0x50203d('0xf')](function(_0x145fef){const _0x376bdb=_0x50203d;logger[_0x376bdb('0x13')](JSON[_0x376bdb('0x20')](_0x145fef));});});},Migration[_0x2b06f8('0x6')]['addColumn']=function(_0x23aabe,_0x9d85fe,_0x15e142){const _0x336000=_0x2b06f8,_0x11d4a5=this;this[_0x336000('0xd')][_0x336000('0x3')](function(){const _0x20e415=_0x336000;return _0x11d4a5[_0x20e415('0x17')]['addColumn'](_0x23aabe,_0x9d85fe,_0x15e142)[_0x20e415('0x9')](function(){const _0x18777a=_0x20e415;logger[_0x18777a('0x13')](_0x18777a('0x1a'),_0x9d85fe,_0x23aabe);})[_0x20e415('0xf')](function(_0x4fd59a){const _0x577944=_0x20e415;logger[_0x577944('0x13')](JSON[_0x577944('0x20')](_0x4fd59a));});});},Migration['prototype'][_0x2b06f8('0x15')]=function(_0x37b042){const _0x2b910f=_0x2b06f8,_0x54c855=this;this[_0x2b910f('0xd')][_0x2b910f('0x3')](function(){const _0xa2b871=_0x2b910f;return _0x54c855[_0xa2b871('0x17')]['dropTable'](_0x37b042,{'force':!![]})[_0xa2b871('0x9')](function(){const _0x845965=_0xa2b871;logger['info'](_0x845965('0x10'),_0x37b042);})[_0xa2b871('0xf')](function(_0x452098){const _0x3d8a0f=_0xa2b871;logger[_0x3d8a0f('0x13')](JSON[_0x3d8a0f('0x20')](_0x452098));});});},Migration[_0x2b06f8('0x6')][_0x2b06f8('0x1d')]=function(_0x53146d,_0x4aee6f,_0x286de9){const _0x3a02b1=_0x2b06f8,_0x5bc55a=this;this[_0x3a02b1('0xd')]['enqueue'](function(){const _0xb8902=_0x3a02b1;return _0x5bc55a[_0xb8902('0x17')]['addIndex'](_0x53146d,_0x4aee6f,{'indexName':_0x286de9[_0xb8902('0x7')],'indicesType':_0x286de9['indicesType']})[_0xb8902('0x9')](function(){const _0x6fc69f=_0xb8902;logger['info'](_0x6fc69f('0x1e'),_0x53146d,_0x4aee6f[_0x6fc69f('0xb')](','),_0x286de9[_0x6fc69f('0x7')],_0x286de9[_0x6fc69f('0x1c')]);})[_0xb8902('0xf')](function(_0x1dbe8a){logger['info'](JSON['stringify'](_0x1dbe8a));});});},Migration['prototype']['removeIndex']=function(_0x57b10c,_0x564a00){const _0x26e3b5=_0x2b06f8,_0x103521=this;this[_0x26e3b5('0xd')][_0x26e3b5('0x3')](function(){const _0x5a04a3=_0x26e3b5;return _0x103521[_0x5a04a3('0x17')][_0x5a04a3('0x1')](_0x57b10c,_0x564a00)['then'](function(){const _0x4de6b1=_0x5a04a3;logger['info'](_0x4de6b1('0x8'),_0x57b10c,_0x564a00);})[_0x5a04a3('0xf')](function(_0x18a861){const _0x3e9fc4=_0x5a04a3;logger[_0x3e9fc4('0x13')](JSON[_0x3e9fc4('0x20')](_0x18a861));});});},Migration[_0x2b06f8('0x6')][_0x2b06f8('0x12')]=function(_0x1bf9d3){const _0x4a4ef6=_0x2b06f8,_0x5633a1=this;this[_0x4a4ef6('0xd')]['enqueue'](function(){const _0x49b910=_0x4a4ef6;return _0x5633a1['queryInterface']['sequelize'][_0x49b910('0x12')](_0x1bf9d3)[_0x49b910('0x9')](function(){const _0x5c91e8=_0x49b910;logger[_0x5c91e8('0x13')](_0x5c91e8('0x1f'),_0x1bf9d3);})['catch'](function(_0x3cf2f5){const _0x1b6288=_0x49b910;logger[_0x1b6288('0x13')](JSON[_0x1b6288('0x20')](_0x3cf2f5));});});},Migration[_0x2b06f8('0x6')]['removeColumn']=function(_0x4676f,_0x4cac02){const _0x4d7bee=_0x2b06f8,_0x268dcb=this;this[_0x4d7bee('0xd')][_0x4d7bee('0x3')](function(){const _0x253139=_0x4d7bee;return _0x268dcb[_0x253139('0x17')][_0x253139('0x16')](_0x4676f,_0x4cac02)[_0x253139('0x9')](function(){const _0x3388b1=_0x253139;logger[_0x3388b1('0x13')](_0x3388b1('0xa'),_0x4cac02,_0x4676f);})[_0x253139('0xf')](function(_0x7a4b9b){const _0x33f639=_0x253139;logger[_0x33f639('0x13')](util[_0x33f639('0x11')](_0x7a4b9b,{'showHidden':![],'depth':null}));});});},Migration[_0x2b06f8('0x6')][_0x2b06f8('0xe')]=function(_0x42fbc7,_0x589e07,_0xed2d12){const _0x53b277=_0x2b06f8,_0x2365d8=this;this[_0x53b277('0xd')]['enqueue'](function(){const _0x543740=_0x53b277;return _0x2365d8[_0x543740('0x17')][_0x543740('0xe')](_0x42fbc7,_0x589e07,_0xed2d12)[_0x543740('0x9')](function(){const _0x23dc2c=_0x543740;logger[_0x23dc2c('0x13')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x589e07,_0xed2d12,_0x42fbc7);})[_0x543740('0xf')](function(_0x5f0d7b){const _0xc9ad9=_0x543740;logger[_0xc9ad9('0x13')](util['inspect'](_0x5f0d7b,{'showHidden':![],'depth':null}));});});},Migration[_0x2b06f8('0x6')][_0x2b06f8('0x2')]=function(_0x3e8925){const _0x2bf96a=_0x2b06f8;this[_0x2bf96a('0xd')][_0x2bf96a('0x3')](function(){return _0x3e8925();});},module[_0x2b06f8('0xc')]={'up':function(_0x19189c){return new Promise(function(_0x2524be){const _0x3d83ff=new Migration(_0x19189c);_0x3d83ff['final'](_0x2524be);});},'down':function(){}}; \ No newline at end of file +const a1006_0x1bff=['finally','inspect','query\x20%s','../config/logger','sequelize','removeIndex','tail','util','queryInterface','dropTable','info','addIndex','stringify','Added\x20column\x20%s\x20to\x20%s','table\x20dropped\x20%s','then','Changed\x20column\x20%s\x20in\x20table\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','final','catch','Removed\x20column\x20%s\x20from\x20%s','prototype','renameColumn','addColumn','enqueue','sequence','addIndex\x20%s\x20%s\x20%s\x20[%s]','indicesType','query','indexName'];(function(_0x1b7c27,_0x1bff9b){const _0x4d3b83=function(_0x11b751){while(--_0x11b751){_0x1b7c27['push'](_0x1b7c27['shift']());}};_0x4d3b83(++_0x1bff9b);}(a1006_0x1bff,0xfe));const a1006_0x4d3b=function(_0x1b7c27,_0x1bff9b){_0x1b7c27=_0x1b7c27-0x0;let _0x4d3b83=a1006_0x1bff[_0x1b7c27];return _0x4d3b83;};const _0x1c44b1=a1006_0x4d3b;'use strict';const util=require(_0x1c44b1('0x17')),logger=require(_0x1c44b1('0x13'))('migration'),Sequence=function(){};Sequence[_0x1c44b1('0x7')][_0x1c44b1('0xa')]=function(_0x11b751){const _0x48a58a=_0x1c44b1;this['tail']=this['tail']?this[_0x48a58a('0x16')][_0x48a58a('0x10')](_0x11b751):_0x11b751();};const Migration=function(_0xc48181){const _0x55b95f=_0x1c44b1;this[_0x55b95f('0x18')]=_0xc48181,this[_0x55b95f('0xb')]=new Sequence();};Migration[_0x1c44b1('0x7')]['changeColumn']=function(_0x44f6ad,_0x17991e,_0x1d03f5){const _0x3d33bd=_0x1c44b1,_0x1200bd=this;this[_0x3d33bd('0xb')]['enqueue'](function(){const _0x20a304=_0x3d33bd;return _0x1200bd[_0x20a304('0x18')]['changeColumn'](_0x44f6ad,_0x17991e,_0x1d03f5)[_0x20a304('0x1')](function(){const _0x231a89=_0x20a304;logger[_0x231a89('0x1a')](_0x231a89('0x2'),_0x17991e,_0x44f6ad);})[_0x20a304('0x5')](function(_0x535c3){const _0x29448d=_0x20a304;logger[_0x29448d('0x1a')](JSON['stringify'](_0x535c3));});});},Migration['prototype']['addColumn']=function(_0xfedb04,_0x297c55,_0x4b72c9){const _0x4455a4=_0x1c44b1,_0x22d263=this;this['sequence'][_0x4455a4('0xa')](function(){const _0x2cc793=_0x4455a4;return _0x22d263[_0x2cc793('0x18')][_0x2cc793('0x9')](_0xfedb04,_0x297c55,_0x4b72c9)[_0x2cc793('0x1')](function(){const _0x1ea0ba=_0x2cc793;logger[_0x1ea0ba('0x1a')](_0x1ea0ba('0x1d'),_0x297c55,_0xfedb04);})[_0x2cc793('0x5')](function(_0x34a29d){const _0xc51372=_0x2cc793;logger[_0xc51372('0x1a')](JSON['stringify'](_0x34a29d));});});},Migration[_0x1c44b1('0x7')][_0x1c44b1('0x19')]=function(_0x372638){const _0x2af0be=_0x1c44b1,_0x5765cc=this;this[_0x2af0be('0xb')][_0x2af0be('0xa')](function(){const _0x4f1fdb=_0x2af0be;return _0x5765cc[_0x4f1fdb('0x18')][_0x4f1fdb('0x19')](_0x372638,{'force':!![]})['then'](function(){const _0x1a8b72=_0x4f1fdb;logger['info'](_0x1a8b72('0x0'),_0x372638);})[_0x4f1fdb('0x5')](function(_0x45c43a){const _0x31aa34=_0x4f1fdb;logger[_0x31aa34('0x1a')](JSON[_0x31aa34('0x1c')](_0x45c43a));});});},Migration[_0x1c44b1('0x7')][_0x1c44b1('0x1b')]=function(_0x5492a9,_0x3fae2f,_0x4a7193){const _0xb67a00=_0x1c44b1,_0x8502b6=this;this[_0xb67a00('0xb')][_0xb67a00('0xa')](function(){const _0x113da5=_0xb67a00;return _0x8502b6[_0x113da5('0x18')][_0x113da5('0x1b')](_0x5492a9,_0x3fae2f,{'indexName':_0x4a7193[_0x113da5('0xf')],'indicesType':_0x4a7193['indicesType']})[_0x113da5('0x1')](function(){const _0xd074ee=_0x113da5;logger[_0xd074ee('0x1a')](_0xd074ee('0xc'),_0x5492a9,_0x3fae2f['join'](','),_0x4a7193['indexName'],_0x4a7193[_0xd074ee('0xd')]);})[_0x113da5('0x5')](function(_0x2578cb){const _0xd1ece9=_0x113da5;logger['info'](JSON[_0xd1ece9('0x1c')](_0x2578cb));});});},Migration['prototype']['removeIndex']=function(_0x41cc22,_0x158a72){const _0x3727be=_0x1c44b1,_0x33d6d2=this;this[_0x3727be('0xb')][_0x3727be('0xa')](function(){const _0x2ff777=_0x3727be;return _0x33d6d2[_0x2ff777('0x18')][_0x2ff777('0x15')](_0x41cc22,_0x158a72)[_0x2ff777('0x1')](function(){const _0x580b36=_0x2ff777;logger[_0x580b36('0x1a')]('removeIndex\x20%s\x20%s',_0x41cc22,_0x158a72);})['catch'](function(_0x4407ca){const _0x32df27=_0x2ff777;logger[_0x32df27('0x1a')](JSON[_0x32df27('0x1c')](_0x4407ca));});});},Migration[_0x1c44b1('0x7')]['query']=function(_0x5569dc){const _0x5e7ab2=_0x1c44b1,_0xc640d1=this;this[_0x5e7ab2('0xb')][_0x5e7ab2('0xa')](function(){const _0x511b4c=_0x5e7ab2;return _0xc640d1['queryInterface'][_0x511b4c('0x14')][_0x511b4c('0xe')](_0x5569dc)[_0x511b4c('0x1')](function(){const _0x1d6026=_0x511b4c;logger[_0x1d6026('0x1a')](_0x1d6026('0x12'),_0x5569dc);})['catch'](function(_0x521278){const _0x1bd4a5=_0x511b4c;logger[_0x1bd4a5('0x1a')](JSON[_0x1bd4a5('0x1c')](_0x521278));});});},Migration[_0x1c44b1('0x7')]['removeColumn']=function(_0x3f855d,_0x969186){const _0xdd1d20=_0x1c44b1,_0x57222b=this;this['sequence'][_0xdd1d20('0xa')](function(){const _0x572a95=_0xdd1d20;return _0x57222b[_0x572a95('0x18')]['removeColumn'](_0x3f855d,_0x969186)[_0x572a95('0x1')](function(){const _0x415bf9=_0x572a95;logger['info'](_0x415bf9('0x6'),_0x969186,_0x3f855d);})[_0x572a95('0x5')](function(_0x127a28){const _0x8e4882=_0x572a95;logger[_0x8e4882('0x1a')](util[_0x8e4882('0x11')](_0x127a28,{'showHidden':![],'depth':null}));});});},Migration[_0x1c44b1('0x7')][_0x1c44b1('0x8')]=function(_0x472e8d,_0x179b77,_0x5a513e){const _0x1bfe83=_0x1c44b1,_0x257b64=this;this[_0x1bfe83('0xb')][_0x1bfe83('0xa')](function(){const _0x1d12f5=_0x1bfe83;return _0x257b64[_0x1d12f5('0x18')][_0x1d12f5('0x8')](_0x472e8d,_0x179b77,_0x5a513e)['then'](function(){const _0x552529=_0x1d12f5;logger[_0x552529('0x1a')](_0x552529('0x3'),_0x179b77,_0x5a513e,_0x472e8d);})[_0x1d12f5('0x5')](function(_0x4bd182){const _0x5b2378=_0x1d12f5;logger[_0x5b2378('0x1a')](util[_0x5b2378('0x11')](_0x4bd182,{'showHidden':![],'depth':null}));});});},Migration[_0x1c44b1('0x7')][_0x1c44b1('0x4')]=function(_0x344a89){const _0x5b7bcc=_0x1c44b1;this[_0x5b7bcc('0xb')][_0x5b7bcc('0xa')](function(){return _0x344a89();});},module['exports']={'up':function(_0x528c06){return new Promise(function(_0x379677){const _0x4ba045=a1006_0x4d3b,_0x358ba3=new Migration(_0x528c06);_0x358ba3[_0x4ba045('0x4')](_0x379677);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.4.js b/server/migrations/2.4.4.js index 43b88de..8f40507 100644 --- a/server/migrations/2.4.4.js +++ b/server/migrations/2.4.4.js @@ -1 +1 @@ -const a1007_0x3ae5=['Added\x20column\x20%s\x20to\x20%s','refreshToken','then','Removed\x20column\x20%s\x20from\x20%s','info','zone','addIndex\x20%s\x20%s\x20%s\x20[%s]','catch','sequence','STRING','query\x20%s','addIndex','enqueue','final','stringify','queryInterface','query','clientId','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','table\x20dropped\x20%s','indexName','changeColumn','authToken','renameColumn','removeIndex','removeIndex\x20%s\x20%s','addColumn','exports','indicesType','dropTable','prototype','Changed\x20column\x20%s\x20in\x20table\x20%s','inspect','finally','../config/logger','util','int_zoho_accounts','removeColumn','tail'];(function(_0x288b83,_0x3ae595){const _0xb070c1=function(_0x2f812f){while(--_0x2f812f){_0x288b83['push'](_0x288b83['shift']());}};_0xb070c1(++_0x3ae595);}(a1007_0x3ae5,0x68));const a1007_0xb070=function(_0x288b83,_0x3ae595){_0x288b83=_0x288b83-0x0;let _0xb070c1=a1007_0x3ae5[_0x288b83];return _0xb070c1;};const _0x16293b=a1007_0xb070;'use strict';const util=require(_0x16293b('0x9')),logger=require(_0x16293b('0x8'))('migration'),Sequence=function(){};Sequence[_0x16293b('0x4')][_0x16293b('0x19')]=function(_0x2f812f){const _0x10be0b=_0x16293b;this['tail']=this[_0x10be0b('0xc')]?this[_0x10be0b('0xc')][_0x10be0b('0x7')](_0x2f812f):_0x2f812f();};const Migration=function(_0xe1391f){const _0x541bec=_0x16293b;this[_0x541bec('0x1c')]=_0xe1391f,this[_0x541bec('0x15')]=new Sequence();};Migration[_0x16293b('0x4')][_0x16293b('0x22')]=function(_0x589a5d,_0x2682ba,_0x4a2ede){const _0x547b65=_0x16293b,_0x4ed6de=this;this['sequence'][_0x547b65('0x19')](function(){const _0x538123=_0x547b65;return _0x4ed6de[_0x538123('0x1c')][_0x538123('0x22')](_0x589a5d,_0x2682ba,_0x4a2ede)[_0x538123('0xf')](function(){const _0x29c691=_0x538123;logger['info'](_0x29c691('0x5'),_0x2682ba,_0x589a5d);})[_0x538123('0x14')](function(_0x10061d){const _0x703c9d=_0x538123;logger[_0x703c9d('0x11')](JSON['stringify'](_0x10061d));});});},Migration[_0x16293b('0x4')][_0x16293b('0x0')]=function(_0x1d184d,_0xd26241,_0x2a0439){const _0x168450=_0x16293b,_0x5aa257=this;this[_0x168450('0x15')]['enqueue'](function(){const _0x78a178=_0x168450;return _0x5aa257[_0x78a178('0x1c')]['addColumn'](_0x1d184d,_0xd26241,_0x2a0439)[_0x78a178('0xf')](function(){const _0x1fc2d3=_0x78a178;logger['info'](_0x1fc2d3('0xd'),_0xd26241,_0x1d184d);})[_0x78a178('0x14')](function(_0x480a80){const _0x27f94c=_0x78a178;logger[_0x27f94c('0x11')](JSON['stringify'](_0x480a80));});});},Migration[_0x16293b('0x4')][_0x16293b('0x3')]=function(_0x1392cd){const _0x630c17=_0x16293b,_0x1bb7af=this;this[_0x630c17('0x15')]['enqueue'](function(){const _0x4672ec=_0x630c17;return _0x1bb7af['queryInterface'][_0x4672ec('0x3')](_0x1392cd,{'force':!![]})[_0x4672ec('0xf')](function(){const _0x290fd0=_0x4672ec;logger[_0x290fd0('0x11')](_0x290fd0('0x20'),_0x1392cd);})[_0x4672ec('0x14')](function(_0x59502a){const _0x5374d1=_0x4672ec;logger[_0x5374d1('0x11')](JSON[_0x5374d1('0x1b')](_0x59502a));});});},Migration[_0x16293b('0x4')][_0x16293b('0x18')]=function(_0x31d75e,_0x11166a,_0xca3c94){const _0x19a59d=_0x16293b,_0x4269ee=this;this[_0x19a59d('0x15')][_0x19a59d('0x19')](function(){const _0x4de43b=_0x19a59d;return _0x4269ee['queryInterface']['addIndex'](_0x31d75e,_0x11166a,{'indexName':_0xca3c94[_0x4de43b('0x21')],'indicesType':_0xca3c94[_0x4de43b('0x2')]})['then'](function(){const _0x41ac09=_0x4de43b;logger[_0x41ac09('0x11')](_0x41ac09('0x13'),_0x31d75e,_0x11166a['join'](','),_0xca3c94[_0x41ac09('0x21')],_0xca3c94[_0x41ac09('0x2')]);})[_0x4de43b('0x14')](function(_0x438ac5){const _0x16b8e7=_0x4de43b;logger[_0x16b8e7('0x11')](JSON[_0x16b8e7('0x1b')](_0x438ac5));});});},Migration['prototype'][_0x16293b('0x25')]=function(_0x3d3eb2,_0x1f0942){const _0x589040=_0x16293b,_0x365c7b=this;this[_0x589040('0x15')][_0x589040('0x19')](function(){const _0x413fc1=_0x589040;return _0x365c7b['queryInterface'][_0x413fc1('0x25')](_0x3d3eb2,_0x1f0942)[_0x413fc1('0xf')](function(){const _0x110da7=_0x413fc1;logger[_0x110da7('0x11')](_0x110da7('0x26'),_0x3d3eb2,_0x1f0942);})[_0x413fc1('0x14')](function(_0x3fe062){const _0x55dc2a=_0x413fc1;logger[_0x55dc2a('0x11')](JSON[_0x55dc2a('0x1b')](_0x3fe062));});});},Migration['prototype'][_0x16293b('0x1d')]=function(_0x1c625c){const _0x1daecf=_0x16293b,_0x3cb3b6=this;this['sequence'][_0x1daecf('0x19')](function(){const _0x2f0d70=_0x1daecf;return _0x3cb3b6[_0x2f0d70('0x1c')]['sequelize'][_0x2f0d70('0x1d')](_0x1c625c)[_0x2f0d70('0xf')](function(){const _0x32058e=_0x2f0d70;logger['info'](_0x32058e('0x17'),_0x1c625c);})[_0x2f0d70('0x14')](function(_0x58a8e8){const _0x243bdf=_0x2f0d70;logger[_0x243bdf('0x11')](JSON[_0x243bdf('0x1b')](_0x58a8e8));});});},Migration[_0x16293b('0x4')][_0x16293b('0xb')]=function(_0xabb3f3,_0xc184e8){const _0x3de1bb=_0x16293b,_0x5b5eba=this;this[_0x3de1bb('0x15')][_0x3de1bb('0x19')](function(){const _0x133eec=_0x3de1bb;return _0x5b5eba[_0x133eec('0x1c')][_0x133eec('0xb')](_0xabb3f3,_0xc184e8)[_0x133eec('0xf')](function(){const _0x23858d=_0x133eec;logger['info'](_0x23858d('0x10'),_0xc184e8,_0xabb3f3);})[_0x133eec('0x14')](function(_0x34489f){logger['info'](util['inspect'](_0x34489f,{'showHidden':![],'depth':null}));});});},Migration[_0x16293b('0x4')][_0x16293b('0x24')]=function(_0x2f5023,_0x5c52ab,_0x1bfe54){const _0x90339c=_0x16293b,_0x4c755d=this;this['sequence'][_0x90339c('0x19')](function(){const _0x2ef497=_0x90339c;return _0x4c755d['queryInterface'][_0x2ef497('0x24')](_0x2f5023,_0x5c52ab,_0x1bfe54)[_0x2ef497('0xf')](function(){const _0x1c0995=_0x2ef497;logger['info'](_0x1c0995('0x1f'),_0x5c52ab,_0x1bfe54,_0x2f5023);})[_0x2ef497('0x14')](function(_0x5f1239){const _0x2971f1=_0x2ef497;logger['info'](util[_0x2971f1('0x6')](_0x5f1239,{'showHidden':![],'depth':null}));});});},Migration[_0x16293b('0x4')][_0x16293b('0x1a')]=function(_0x57f9e8){const _0x2324c8=_0x16293b;this[_0x2324c8('0x15')][_0x2324c8('0x19')](function(){return _0x57f9e8();});},module[_0x16293b('0x1')]={'up':function(_0x3908a4,_0x2ccbe5){return new Promise(function(_0x722bef){const _0x4a8310=a1007_0xb070,_0x412548=new Migration(_0x3908a4);_0x412548[_0x4a8310('0xb')](_0x4a8310('0xa'),_0x4a8310('0x23')),_0x412548[_0x4a8310('0x0')]('int_zoho_accounts',_0x4a8310('0x12'),{'type':_0x2ccbe5[_0x4a8310('0x16')],'defaultValue':'EU'}),_0x412548['addColumn'](_0x4a8310('0xa'),_0x4a8310('0x1e'),{'type':_0x2ccbe5[_0x4a8310('0x16')]}),_0x412548[_0x4a8310('0x0')](_0x4a8310('0xa'),'clientSecret',{'type':_0x2ccbe5[_0x4a8310('0x16')]}),_0x412548[_0x4a8310('0x0')](_0x4a8310('0xa'),'code',{'type':_0x2ccbe5[_0x4a8310('0x16')]}),_0x412548[_0x4a8310('0x0')](_0x4a8310('0xa'),_0x4a8310('0xe'),{'type':_0x2ccbe5[_0x4a8310('0x16')]}),_0x412548[_0x4a8310('0x1a')](_0x722bef);});},'down':function(){}}; \ No newline at end of file +const a1007_0x4aed=['prototype','stringify','info','util','then','tail','Removed\x20column\x20%s\x20from\x20%s','indexName','table\x20dropped\x20%s','removeIndex\x20%s\x20%s','indicesType','removeIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','clientId','migration','queryInterface','int_zoho_accounts','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','renameColumn','join','enqueue','../config/logger','query\x20%s','changeColumn','addColumn','dropTable','sequelize','catch','addIndex','sequence','exports','STRING','Added\x20column\x20%s\x20to\x20%s','removeColumn','authToken','final'];(function(_0x32f3bf,_0x4aedd4){const _0x548cf9=function(_0x19c6a8){while(--_0x19c6a8){_0x32f3bf['push'](_0x32f3bf['shift']());}};_0x548cf9(++_0x4aedd4);}(a1007_0x4aed,0x184));const a1007_0x548c=function(_0x32f3bf,_0x4aedd4){_0x32f3bf=_0x32f3bf-0x0;let _0x548cf9=a1007_0x4aed[_0x32f3bf];return _0x548cf9;};const _0x567b78=a1007_0x548c;'use strict';const util=require(_0x567b78('0xb')),logger=require(_0x567b78('0x1d'))(_0x567b78('0x16')),Sequence=function(){};Sequence[_0x567b78('0x8')][_0x567b78('0x1c')]=function(_0x19c6a8){const _0xc6884=_0x567b78;this[_0xc6884('0xd')]=this[_0xc6884('0xd')]?this[_0xc6884('0xd')]['finally'](_0x19c6a8):_0x19c6a8();};const Migration=function(_0xa78d75){const _0x489b28=_0x567b78;this['queryInterface']=_0xa78d75,this[_0x489b28('0x1')]=new Sequence();};Migration[_0x567b78('0x8')]['changeColumn']=function(_0x2098b3,_0x2cd414,_0xcd38c0){const _0x57ee2d=_0x567b78,_0x2e39e8=this;this['sequence'][_0x57ee2d('0x1c')](function(){const _0x369617=_0x57ee2d;return _0x2e39e8['queryInterface'][_0x369617('0x1f')](_0x2098b3,_0x2cd414,_0xcd38c0)[_0x369617('0xc')](function(){const _0x17387a=_0x369617;logger[_0x17387a('0xa')](_0x17387a('0x14'),_0x2cd414,_0x2098b3);})[_0x369617('0x23')](function(_0x2b7210){const _0x3aa9ee=_0x369617;logger[_0x3aa9ee('0xa')](JSON['stringify'](_0x2b7210));});});},Migration['prototype'][_0x567b78('0x20')]=function(_0x267f3a,_0x1f0b74,_0x7636bb){const _0x3cecc2=_0x567b78,_0x1b014f=this;this['sequence'][_0x3cecc2('0x1c')](function(){const _0x513027=_0x3cecc2;return _0x1b014f[_0x513027('0x17')][_0x513027('0x20')](_0x267f3a,_0x1f0b74,_0x7636bb)[_0x513027('0xc')](function(){const _0x227aa2=_0x513027;logger[_0x227aa2('0xa')](_0x227aa2('0x4'),_0x1f0b74,_0x267f3a);})[_0x513027('0x23')](function(_0x3c08dc){const _0xa6f634=_0x513027;logger[_0xa6f634('0xa')](JSON[_0xa6f634('0x9')](_0x3c08dc));});});},Migration[_0x567b78('0x8')][_0x567b78('0x21')]=function(_0x42977e){const _0x14540d=_0x567b78,_0x269ff9=this;this[_0x14540d('0x1')][_0x14540d('0x1c')](function(){const _0x52bc8a=_0x14540d;return _0x269ff9[_0x52bc8a('0x17')][_0x52bc8a('0x21')](_0x42977e,{'force':!![]})[_0x52bc8a('0xc')](function(){const _0x15c3b2=_0x52bc8a;logger[_0x15c3b2('0xa')](_0x15c3b2('0x10'),_0x42977e);})[_0x52bc8a('0x23')](function(_0x2c0d40){logger['info'](JSON['stringify'](_0x2c0d40));});});},Migration[_0x567b78('0x8')][_0x567b78('0x0')]=function(_0x2696d8,_0x47bed3,_0x71d499){const _0x107adc=_0x567b78,_0x438a5a=this;this[_0x107adc('0x1')][_0x107adc('0x1c')](function(){const _0x4f8d8b=_0x107adc;return _0x438a5a[_0x4f8d8b('0x17')][_0x4f8d8b('0x0')](_0x2696d8,_0x47bed3,{'indexName':_0x71d499[_0x4f8d8b('0xf')],'indicesType':_0x71d499['indicesType']})['then'](function(){const _0x3599dc=_0x4f8d8b;logger[_0x3599dc('0xa')]('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x2696d8,_0x47bed3[_0x3599dc('0x1b')](','),_0x71d499['indexName'],_0x71d499[_0x3599dc('0x12')]);})[_0x4f8d8b('0x23')](function(_0x93fec6){const _0x32b6fb=_0x4f8d8b;logger[_0x32b6fb('0xa')](JSON[_0x32b6fb('0x9')](_0x93fec6));});});},Migration[_0x567b78('0x8')]['removeIndex']=function(_0x1bd84b,_0x5cd99d){const _0x1a9031=_0x567b78,_0x178644=this;this['sequence'][_0x1a9031('0x1c')](function(){const _0x1158c3=_0x1a9031;return _0x178644[_0x1158c3('0x17')][_0x1158c3('0x13')](_0x1bd84b,_0x5cd99d)[_0x1158c3('0xc')](function(){const _0x1a15a1=_0x1158c3;logger['info'](_0x1a15a1('0x11'),_0x1bd84b,_0x5cd99d);})['catch'](function(_0x4b0e63){const _0x13f7a1=_0x1158c3;logger[_0x13f7a1('0xa')](JSON['stringify'](_0x4b0e63));});});},Migration[_0x567b78('0x8')]['query']=function(_0x504f0a){const _0x3b6dc9=_0x567b78,_0x55d064=this;this[_0x3b6dc9('0x1')][_0x3b6dc9('0x1c')](function(){const _0x50e641=_0x3b6dc9;return _0x55d064[_0x50e641('0x17')][_0x50e641('0x22')]['query'](_0x504f0a)[_0x50e641('0xc')](function(){const _0x2352ce=_0x50e641;logger[_0x2352ce('0xa')](_0x2352ce('0x1e'),_0x504f0a);})[_0x50e641('0x23')](function(_0x59163b){const _0x27bd48=_0x50e641;logger[_0x27bd48('0xa')](JSON[_0x27bd48('0x9')](_0x59163b));});});},Migration[_0x567b78('0x8')][_0x567b78('0x5')]=function(_0x33b139,_0xa18122){const _0x49cbe1=_0x567b78,_0x5f5c4f=this;this[_0x49cbe1('0x1')][_0x49cbe1('0x1c')](function(){const _0x2bb5bc=_0x49cbe1;return _0x5f5c4f['queryInterface'][_0x2bb5bc('0x5')](_0x33b139,_0xa18122)[_0x2bb5bc('0xc')](function(){const _0xae98a2=_0x2bb5bc;logger[_0xae98a2('0xa')](_0xae98a2('0xe'),_0xa18122,_0x33b139);})[_0x2bb5bc('0x23')](function(_0x35f62b){const _0x227210=_0x2bb5bc;logger[_0x227210('0xa')](util['inspect'](_0x35f62b,{'showHidden':![],'depth':null}));});});},Migration[_0x567b78('0x8')][_0x567b78('0x1a')]=function(_0x25624e,_0x8fac55,_0x5d0596){const _0x7e62c2=_0x567b78,_0x7c2984=this;this[_0x7e62c2('0x1')]['enqueue'](function(){const _0x32f4d8=_0x7e62c2;return _0x7c2984[_0x32f4d8('0x17')][_0x32f4d8('0x1a')](_0x25624e,_0x8fac55,_0x5d0596)[_0x32f4d8('0xc')](function(){const _0x21da1b=_0x32f4d8;logger[_0x21da1b('0xa')](_0x21da1b('0x19'),_0x8fac55,_0x5d0596,_0x25624e);})[_0x32f4d8('0x23')](function(_0x49603f){const _0x2d1fa4=_0x32f4d8;logger[_0x2d1fa4('0xa')](util['inspect'](_0x49603f,{'showHidden':![],'depth':null}));});});},Migration[_0x567b78('0x8')][_0x567b78('0x7')]=function(_0x77e8eb){const _0x46fecd=_0x567b78;this['sequence'][_0x46fecd('0x1c')](function(){return _0x77e8eb();});},module[_0x567b78('0x2')]={'up':function(_0xfa3b3e,_0x4e9912){return new Promise(function(_0x1ddc61){const _0x130b2b=a1007_0x548c,_0x1c755d=new Migration(_0xfa3b3e);_0x1c755d[_0x130b2b('0x5')](_0x130b2b('0x18'),_0x130b2b('0x6')),_0x1c755d['addColumn'](_0x130b2b('0x18'),'zone',{'type':_0x4e9912['STRING'],'defaultValue':'EU'}),_0x1c755d['addColumn']('int_zoho_accounts',_0x130b2b('0x15'),{'type':_0x4e9912['STRING']}),_0x1c755d[_0x130b2b('0x20')]('int_zoho_accounts','clientSecret',{'type':_0x4e9912['STRING']}),_0x1c755d['addColumn']('int_zoho_accounts','code',{'type':_0x4e9912[_0x130b2b('0x3')]}),_0x1c755d['addColumn']('int_zoho_accounts','refreshToken',{'type':_0x4e9912[_0x130b2b('0x3')]}),_0x1c755d[_0x130b2b('0x7')](_0x1ddc61);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.5.js b/server/migrations/2.4.5.js index 6196a75..e236085 100644 --- a/server/migrations/2.4.5.js +++ b/server/migrations/2.4.5.js @@ -1 +1 @@ -const a1008_0x52b5=['tail','dropTable','addColumn','finally','Added\x20column\x20%s\x20to\x20%s','catch','util','query\x20%s','sequence','table\x20dropped\x20%s','sequelize','then','removeIndex','stringify','Changed\x20column\x20%s\x20in\x20table\x20%s','inspect','addIndex','indexName','removeIndex\x20%s\x20%s','changeColumn','addIndex\x20%s\x20%s\x20%s\x20[%s]','renameColumn','indicesType','prototype','exports','enqueue','Removed\x20column\x20%s\x20from\x20%s','queryInterface','migration','final','removeColumn','info'];(function(_0x4e9fec,_0x52b51e){const _0x5a7504=function(_0x2c4781){while(--_0x2c4781){_0x4e9fec['push'](_0x4e9fec['shift']());}};_0x5a7504(++_0x52b51e);}(a1008_0x52b5,0x13d));const a1008_0x5a75=function(_0x4e9fec,_0x52b51e){_0x4e9fec=_0x4e9fec-0x0;let _0x5a7504=a1008_0x52b5[_0x4e9fec];return _0x5a7504;};const _0x11cf54=a1008_0x5a75;'use strict';const util=require(_0x11cf54('0x9')),logger=require('../config/logger')(_0x11cf54('0x1f')),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x2c4781){const _0x1966ba=_0x11cf54;this[_0x1966ba('0x3')]=this[_0x1966ba('0x3')]?this[_0x1966ba('0x3')][_0x1966ba('0x6')](_0x2c4781):_0x2c4781();};const Migration=function(_0x117007){const _0x5d80f6=_0x11cf54;this[_0x5d80f6('0x1e')]=_0x117007,this['sequence']=new Sequence();};Migration[_0x11cf54('0x1a')][_0x11cf54('0x16')]=function(_0x293bcf,_0xbd1142,_0xf0d86c){const _0x444ccf=_0x11cf54,_0x2821b7=this;this[_0x444ccf('0xb')][_0x444ccf('0x1c')](function(){const _0x156b48=_0x444ccf;return _0x2821b7[_0x156b48('0x1e')][_0x156b48('0x16')](_0x293bcf,_0xbd1142,_0xf0d86c)[_0x156b48('0xe')](function(){const _0x123b47=_0x156b48;logger[_0x123b47('0x2')](_0x123b47('0x11'),_0xbd1142,_0x293bcf);})[_0x156b48('0x8')](function(_0x2e4fe8){const _0x1e88c0=_0x156b48;logger[_0x1e88c0('0x2')](JSON[_0x1e88c0('0x10')](_0x2e4fe8));});});},Migration[_0x11cf54('0x1a')][_0x11cf54('0x5')]=function(_0x1038f9,_0x436769,_0x327333){const _0x3869ce=_0x11cf54,_0x3dc44a=this;this[_0x3869ce('0xb')][_0x3869ce('0x1c')](function(){const _0x275115=_0x3869ce;return _0x3dc44a[_0x275115('0x1e')][_0x275115('0x5')](_0x1038f9,_0x436769,_0x327333)[_0x275115('0xe')](function(){const _0x27d50b=_0x275115;logger['info'](_0x27d50b('0x7'),_0x436769,_0x1038f9);})[_0x275115('0x8')](function(_0x583889){const _0xcf85b7=_0x275115;logger[_0xcf85b7('0x2')](JSON['stringify'](_0x583889));});});},Migration[_0x11cf54('0x1a')][_0x11cf54('0x4')]=function(_0x3735a3){const _0x450a4e=_0x11cf54,_0x2a6c7f=this;this['sequence'][_0x450a4e('0x1c')](function(){const _0x9492a0=_0x450a4e;return _0x2a6c7f['queryInterface'][_0x9492a0('0x4')](_0x3735a3,{'force':!![]})[_0x9492a0('0xe')](function(){const _0x4c81c1=_0x9492a0;logger[_0x4c81c1('0x2')](_0x4c81c1('0xc'),_0x3735a3);})[_0x9492a0('0x8')](function(_0x40b9c6){const _0x594cf1=_0x9492a0;logger['info'](JSON[_0x594cf1('0x10')](_0x40b9c6));});});},Migration[_0x11cf54('0x1a')][_0x11cf54('0x13')]=function(_0x30205a,_0x31085d,_0xabf16d){const _0x3eeffb=_0x11cf54,_0x3e852b=this;this[_0x3eeffb('0xb')][_0x3eeffb('0x1c')](function(){const _0x1e410d=_0x3eeffb;return _0x3e852b['queryInterface'][_0x1e410d('0x13')](_0x30205a,_0x31085d,{'indexName':_0xabf16d[_0x1e410d('0x14')],'indicesType':_0xabf16d[_0x1e410d('0x19')]})['then'](function(){const _0x151307=_0x1e410d;logger[_0x151307('0x2')](_0x151307('0x17'),_0x30205a,_0x31085d['join'](','),_0xabf16d['indexName'],_0xabf16d[_0x151307('0x19')]);})[_0x1e410d('0x8')](function(_0x57a970){const _0x377855=_0x1e410d;logger[_0x377855('0x2')](JSON[_0x377855('0x10')](_0x57a970));});});},Migration['prototype']['removeIndex']=function(_0x49778c,_0x52d6a8){const _0x191527=_0x11cf54,_0x220f6b=this;this['sequence'][_0x191527('0x1c')](function(){const _0x296a1b=_0x191527;return _0x220f6b[_0x296a1b('0x1e')][_0x296a1b('0xf')](_0x49778c,_0x52d6a8)[_0x296a1b('0xe')](function(){const _0x3461fe=_0x296a1b;logger[_0x3461fe('0x2')](_0x3461fe('0x15'),_0x49778c,_0x52d6a8);})[_0x296a1b('0x8')](function(_0x4bbfcb){const _0x2d0703=_0x296a1b;logger['info'](JSON[_0x2d0703('0x10')](_0x4bbfcb));});});},Migration['prototype']['query']=function(_0x1d3ff3){const _0x57856e=_0x11cf54,_0x257144=this;this[_0x57856e('0xb')][_0x57856e('0x1c')](function(){const _0x3487bf=_0x57856e;return _0x257144[_0x3487bf('0x1e')][_0x3487bf('0xd')]['query'](_0x1d3ff3)[_0x3487bf('0xe')](function(){const _0x54d813=_0x3487bf;logger['info'](_0x54d813('0xa'),_0x1d3ff3);})['catch'](function(_0x15c93d){const _0x34a591=_0x3487bf;logger[_0x34a591('0x2')](JSON[_0x34a591('0x10')](_0x15c93d));});});},Migration[_0x11cf54('0x1a')][_0x11cf54('0x1')]=function(_0x1947c2,_0x574934){const _0x4c52ba=_0x11cf54,_0x1f2bbb=this;this[_0x4c52ba('0xb')][_0x4c52ba('0x1c')](function(){const _0x75cb9b=_0x4c52ba;return _0x1f2bbb[_0x75cb9b('0x1e')][_0x75cb9b('0x1')](_0x1947c2,_0x574934)[_0x75cb9b('0xe')](function(){const _0x183900=_0x75cb9b;logger[_0x183900('0x2')](_0x183900('0x1d'),_0x574934,_0x1947c2);})[_0x75cb9b('0x8')](function(_0x5279ec){const _0x48853b=_0x75cb9b;logger['info'](util[_0x48853b('0x12')](_0x5279ec,{'showHidden':![],'depth':null}));});});},Migration[_0x11cf54('0x1a')]['renameColumn']=function(_0x1b3b62,_0x35e2e5,_0x48383f){const _0x2190eb=_0x11cf54,_0x50327c=this;this[_0x2190eb('0xb')][_0x2190eb('0x1c')](function(){const _0x59df53=_0x2190eb;return _0x50327c[_0x59df53('0x1e')][_0x59df53('0x18')](_0x1b3b62,_0x35e2e5,_0x48383f)[_0x59df53('0xe')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x35e2e5,_0x48383f,_0x1b3b62);})[_0x59df53('0x8')](function(_0x5515af){const _0x58a7e0=_0x59df53;logger[_0x58a7e0('0x2')](util[_0x58a7e0('0x12')](_0x5515af,{'showHidden':![],'depth':null}));});});},Migration[_0x11cf54('0x1a')][_0x11cf54('0x0')]=function(_0x5b3f0a){this['sequence']['enqueue'](function(){return _0x5b3f0a();});},module[_0x11cf54('0x1b')]={'up':function(_0x3209b1){return new Promise(function(_0x43fc07){const _0x130ce3=a1008_0x5a75,_0x43e42c=new Migration(_0x3209b1);_0x43e42c[_0x130ce3('0x0')](_0x43fc07);});},'down':function(){}}; \ No newline at end of file +const a1008_0x5eef=['stringify','finally','prototype','final','changeColumn','tail','indicesType','then','exports','Changed\x20column\x20%s\x20in\x20table\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','dropTable','query','queryInterface','sequence','addColumn','table\x20dropped\x20%s','removeColumn','renameColumn','indexName','catch','migration','info','enqueue','query\x20%s'];(function(_0x214f87,_0x5eefbd){const _0x5adc87=function(_0x1317d4){while(--_0x1317d4){_0x214f87['push'](_0x214f87['shift']());}};_0x5adc87(++_0x5eefbd);}(a1008_0x5eef,0x86));const a1008_0x5adc=function(_0x214f87,_0x5eefbd){_0x214f87=_0x214f87-0x0;let _0x5adc87=a1008_0x5eef[_0x214f87];return _0x5adc87;};const _0x529857=a1008_0x5adc;'use strict';const util=require('util'),logger=require('../config/logger')(_0x529857('0xc')),Sequence=function(){};Sequence[_0x529857('0x12')][_0x529857('0xe')]=function(_0x1317d4){const _0x406d26=_0x529857;this[_0x406d26('0x15')]=this[_0x406d26('0x15')]?this[_0x406d26('0x15')][_0x406d26('0x11')](_0x1317d4):_0x1317d4();};const Migration=function(_0x115662){const _0x15e9aa=_0x529857;this[_0x15e9aa('0x4')]=_0x115662,this[_0x15e9aa('0x5')]=new Sequence();};Migration['prototype'][_0x529857('0x14')]=function(_0x4ebfc4,_0x647175,_0xfef6f9){const _0xd7232e=_0x529857,_0x2465a2=this;this[_0xd7232e('0x5')]['enqueue'](function(){const _0x5d1d46=_0xd7232e;return _0x2465a2[_0x5d1d46('0x4')][_0x5d1d46('0x14')](_0x4ebfc4,_0x647175,_0xfef6f9)[_0x5d1d46('0x17')](function(){const _0xb9ebb0=_0x5d1d46;logger[_0xb9ebb0('0xd')](_0xb9ebb0('0x0'),_0x647175,_0x4ebfc4);})['catch'](function(_0xdfdebe){const _0x1d69b8=_0x5d1d46;logger['info'](JSON[_0x1d69b8('0x10')](_0xdfdebe));});});},Migration['prototype'][_0x529857('0x6')]=function(_0x5e1a22,_0x25ddbe,_0x1c1017){const _0x27d7a3=_0x529857,_0x5a3dd5=this;this[_0x27d7a3('0x5')][_0x27d7a3('0xe')](function(){const _0x1a5e70=_0x27d7a3;return _0x5a3dd5[_0x1a5e70('0x4')]['addColumn'](_0x5e1a22,_0x25ddbe,_0x1c1017)[_0x1a5e70('0x17')](function(){const _0x35be58=_0x1a5e70;logger[_0x35be58('0xd')]('Added\x20column\x20%s\x20to\x20%s',_0x25ddbe,_0x5e1a22);})['catch'](function(_0x3fdb5e){const _0x5a1fbc=_0x1a5e70;logger[_0x5a1fbc('0xd')](JSON['stringify'](_0x3fdb5e));});});},Migration[_0x529857('0x12')][_0x529857('0x2')]=function(_0x51ee18){const _0x216e26=_0x529857,_0x53582b=this;this[_0x216e26('0x5')][_0x216e26('0xe')](function(){const _0x1aa2cf=_0x216e26;return _0x53582b[_0x1aa2cf('0x4')]['dropTable'](_0x51ee18,{'force':!![]})['then'](function(){const _0x13a6c0=_0x1aa2cf;logger[_0x13a6c0('0xd')](_0x13a6c0('0x7'),_0x51ee18);})[_0x1aa2cf('0xb')](function(_0x32e966){const _0x322d2b=_0x1aa2cf;logger[_0x322d2b('0xd')](JSON['stringify'](_0x32e966));});});},Migration[_0x529857('0x12')]['addIndex']=function(_0x4f208b,_0x31dc7f,_0x13e2ee){const _0x592da3=_0x529857,_0x82e0af=this;this[_0x592da3('0x5')][_0x592da3('0xe')](function(){const _0x2c241b=_0x592da3;return _0x82e0af[_0x2c241b('0x4')]['addIndex'](_0x4f208b,_0x31dc7f,{'indexName':_0x13e2ee[_0x2c241b('0xa')],'indicesType':_0x13e2ee[_0x2c241b('0x16')]})[_0x2c241b('0x17')](function(){const _0xea1c66=_0x2c241b;logger[_0xea1c66('0xd')]('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x4f208b,_0x31dc7f['join'](','),_0x13e2ee['indexName'],_0x13e2ee[_0xea1c66('0x16')]);})['catch'](function(_0x54f868){const _0x2a447b=_0x2c241b;logger[_0x2a447b('0xd')](JSON[_0x2a447b('0x10')](_0x54f868));});});},Migration[_0x529857('0x12')]['removeIndex']=function(_0x10cc24,_0x5f4bc8){const _0x37c1e4=_0x529857,_0x4f63d3=this;this[_0x37c1e4('0x5')]['enqueue'](function(){const _0x5e5245=_0x37c1e4;return _0x4f63d3['queryInterface']['removeIndex'](_0x10cc24,_0x5f4bc8)[_0x5e5245('0x17')](function(){logger['info']('removeIndex\x20%s\x20%s',_0x10cc24,_0x5f4bc8);})[_0x5e5245('0xb')](function(_0x3c425c){const _0x268927=_0x5e5245;logger[_0x268927('0xd')](JSON[_0x268927('0x10')](_0x3c425c));});});},Migration[_0x529857('0x12')][_0x529857('0x3')]=function(_0xcf9c1f){const _0x44d77f=_0x529857,_0x37b739=this;this['sequence'][_0x44d77f('0xe')](function(){const _0x11ca53=_0x44d77f;return _0x37b739[_0x11ca53('0x4')]['sequelize'][_0x11ca53('0x3')](_0xcf9c1f)['then'](function(){const _0x4d1d1f=_0x11ca53;logger[_0x4d1d1f('0xd')](_0x4d1d1f('0xf'),_0xcf9c1f);})[_0x11ca53('0xb')](function(_0x281bf5){const _0x1bc8dc=_0x11ca53;logger['info'](JSON[_0x1bc8dc('0x10')](_0x281bf5));});});},Migration['prototype'][_0x529857('0x8')]=function(_0x25fbcd,_0x3d5069){const _0x2d9845=_0x529857,_0x4bae0a=this;this[_0x2d9845('0x5')][_0x2d9845('0xe')](function(){const _0x25da33=_0x2d9845;return _0x4bae0a[_0x25da33('0x4')][_0x25da33('0x8')](_0x25fbcd,_0x3d5069)[_0x25da33('0x17')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x3d5069,_0x25fbcd);})['catch'](function(_0xed9768){const _0x2b185e=_0x25da33;logger[_0x2b185e('0xd')](util['inspect'](_0xed9768,{'showHidden':![],'depth':null}));});});},Migration[_0x529857('0x12')][_0x529857('0x9')]=function(_0x45cd5d,_0x53e273,_0x432e63){const _0x573c10=_0x529857,_0x277406=this;this[_0x573c10('0x5')][_0x573c10('0xe')](function(){const _0x3f9b26=_0x573c10;return _0x277406[_0x3f9b26('0x4')]['renameColumn'](_0x45cd5d,_0x53e273,_0x432e63)[_0x3f9b26('0x17')](function(){const _0x17bcbb=_0x3f9b26;logger[_0x17bcbb('0xd')](_0x17bcbb('0x1'),_0x53e273,_0x432e63,_0x45cd5d);})[_0x3f9b26('0xb')](function(_0x4f702a){const _0x278fd5=_0x3f9b26;logger[_0x278fd5('0xd')](util['inspect'](_0x4f702a,{'showHidden':![],'depth':null}));});});},Migration[_0x529857('0x12')][_0x529857('0x13')]=function(_0x2b1086){const _0x3742d0=_0x529857;this[_0x3742d0('0x5')][_0x3742d0('0xe')](function(){return _0x2b1086();});},module[_0x529857('0x18')]={'up':function(_0x94cd6c){return new Promise(function(_0x59c407){const _0x1d709b=new Migration(_0x94cd6c);_0x1d709b['final'](_0x59c407);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.6.js b/server/migrations/2.4.6.js index 4abbc66..fc86535 100644 --- a/server/migrations/2.4.6.js +++ b/server/migrations/2.4.6.js @@ -1 +1 @@ -const a1009_0x268b=['query','queryInterface','stringify','util','renameColumn','addIndex','prototype','indicesType','table\x20dropped\x20%s','indexName','changeColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','Removed\x20column\x20%s\x20from\x20%s','sequence','info','../config/logger','catch','removeIndex\x20%s\x20%s','sequelize','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','join','enqueue','finally','dropTable','removeIndex','addColumn','tail','migration','exports','removeColumn','then'];(function(_0x52fa5b,_0x268b22){const _0x4c69c6=function(_0x730a0c){while(--_0x730a0c){_0x52fa5b['push'](_0x52fa5b['shift']());}};_0x4c69c6(++_0x268b22);}(a1009_0x268b,0xd5));const a1009_0x4c69=function(_0x52fa5b,_0x268b22){_0x52fa5b=_0x52fa5b-0x0;let _0x4c69c6=a1009_0x268b[_0x52fa5b];return _0x4c69c6;};const _0x2d196b=a1009_0x4c69;'use strict';const util=require(_0x2d196b('0x7')),logger=require(_0x2d196b('0x13'))(_0x2d196b('0x0')),Sequence=function(){};Sequence[_0x2d196b('0xa')][_0x2d196b('0x19')]=function(_0x730a0c){const _0x1bb0c9=_0x2d196b;this[_0x1bb0c9('0x1e')]=this[_0x1bb0c9('0x1e')]?this[_0x1bb0c9('0x1e')][_0x1bb0c9('0x1a')](_0x730a0c):_0x730a0c();};const Migration=function(_0x48f156){const _0x42db1a=_0x2d196b;this['queryInterface']=_0x48f156,this[_0x42db1a('0x11')]=new Sequence();};Migration['prototype'][_0x2d196b('0xe')]=function(_0x541430,_0x1b2f7d,_0x38d53e){const _0x58904b=_0x2d196b,_0x215a0e=this;this[_0x58904b('0x11')][_0x58904b('0x19')](function(){const _0x54a1ba=_0x58904b;return _0x215a0e[_0x54a1ba('0x5')][_0x54a1ba('0xe')](_0x541430,_0x1b2f7d,_0x38d53e)[_0x54a1ba('0x3')](function(){const _0x155e8f=_0x54a1ba;logger[_0x155e8f('0x12')](_0x155e8f('0xf'),_0x1b2f7d,_0x541430);})[_0x54a1ba('0x14')](function(_0x28fabb){logger['info'](JSON['stringify'](_0x28fabb));});});},Migration[_0x2d196b('0xa')]['addColumn']=function(_0x5cf4ba,_0x4f679e,_0x15d040){const _0x1a9fad=_0x2d196b,_0x4ec69d=this;this[_0x1a9fad('0x11')][_0x1a9fad('0x19')](function(){const _0x3dceff=_0x1a9fad;return _0x4ec69d[_0x3dceff('0x5')][_0x3dceff('0x1d')](_0x5cf4ba,_0x4f679e,_0x15d040)[_0x3dceff('0x3')](function(){const _0x14a530=_0x3dceff;logger[_0x14a530('0x12')]('Added\x20column\x20%s\x20to\x20%s',_0x4f679e,_0x5cf4ba);})['catch'](function(_0x5367eb){const _0x3b7090=_0x3dceff;logger[_0x3b7090('0x12')](JSON[_0x3b7090('0x6')](_0x5367eb));});});},Migration[_0x2d196b('0xa')][_0x2d196b('0x1b')]=function(_0x1911b2){const _0xdd4137=_0x2d196b,_0x47223=this;this[_0xdd4137('0x11')][_0xdd4137('0x19')](function(){const _0x521964=_0xdd4137;return _0x47223[_0x521964('0x5')]['dropTable'](_0x1911b2,{'force':!![]})[_0x521964('0x3')](function(){const _0x23e739=_0x521964;logger[_0x23e739('0x12')](_0x23e739('0xc'),_0x1911b2);})['catch'](function(_0x19b96c){const _0x2199d5=_0x521964;logger['info'](JSON[_0x2199d5('0x6')](_0x19b96c));});});},Migration[_0x2d196b('0xa')]['addIndex']=function(_0x42e450,_0x4fd9be,_0x3a3c29){const _0x5def92=_0x2d196b,_0x31933a=this;this[_0x5def92('0x11')]['enqueue'](function(){const _0x5d45f2=_0x5def92;return _0x31933a[_0x5d45f2('0x5')][_0x5d45f2('0x9')](_0x42e450,_0x4fd9be,{'indexName':_0x3a3c29[_0x5d45f2('0xd')],'indicesType':_0x3a3c29[_0x5d45f2('0xb')]})[_0x5d45f2('0x3')](function(){const _0x43037c=_0x5d45f2;logger[_0x43037c('0x12')]('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x42e450,_0x4fd9be[_0x43037c('0x18')](','),_0x3a3c29[_0x43037c('0xd')],_0x3a3c29['indicesType']);})['catch'](function(_0x2a638f){const _0x2623ef=_0x5d45f2;logger[_0x2623ef('0x12')](JSON['stringify'](_0x2a638f));});});},Migration[_0x2d196b('0xa')][_0x2d196b('0x1c')]=function(_0x4bd691,_0x1b9264){const _0x850589=_0x2d196b,_0x11e95f=this;this[_0x850589('0x11')][_0x850589('0x19')](function(){const _0x238df4=_0x850589;return _0x11e95f[_0x238df4('0x5')][_0x238df4('0x1c')](_0x4bd691,_0x1b9264)[_0x238df4('0x3')](function(){const _0x117e34=_0x238df4;logger[_0x117e34('0x12')](_0x117e34('0x15'),_0x4bd691,_0x1b9264);})['catch'](function(_0x5a4ec2){const _0x5a11f8=_0x238df4;logger[_0x5a11f8('0x12')](JSON['stringify'](_0x5a4ec2));});});},Migration[_0x2d196b('0xa')][_0x2d196b('0x4')]=function(_0x50f219){const _0x2a1b7c=_0x2d196b,_0x1eee75=this;this[_0x2a1b7c('0x11')][_0x2a1b7c('0x19')](function(){const _0x31f63f=_0x2a1b7c;return _0x1eee75[_0x31f63f('0x5')][_0x31f63f('0x16')][_0x31f63f('0x4')](_0x50f219)['then'](function(){const _0x10e4d3=_0x31f63f;logger[_0x10e4d3('0x12')]('query\x20%s',_0x50f219);})['catch'](function(_0x479d7f){const _0x21042a=_0x31f63f;logger[_0x21042a('0x12')](JSON[_0x21042a('0x6')](_0x479d7f));});});},Migration[_0x2d196b('0xa')][_0x2d196b('0x2')]=function(_0x24975d,_0x38c6e4){const _0x138cc4=_0x2d196b,_0x51c7d3=this;this[_0x138cc4('0x11')][_0x138cc4('0x19')](function(){const _0x3bf75f=_0x138cc4;return _0x51c7d3[_0x3bf75f('0x5')]['removeColumn'](_0x24975d,_0x38c6e4)[_0x3bf75f('0x3')](function(){const _0x19b9bb=_0x3bf75f;logger[_0x19b9bb('0x12')](_0x19b9bb('0x10'),_0x38c6e4,_0x24975d);})[_0x3bf75f('0x14')](function(_0x2b07eb){logger['info'](util['inspect'](_0x2b07eb,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x2d196b('0x8')]=function(_0x17b16e,_0x44fca1,_0x359ab0){const _0x4a0e63=_0x2d196b,_0x256d0a=this;this[_0x4a0e63('0x11')][_0x4a0e63('0x19')](function(){const _0x43545a=_0x4a0e63;return _0x256d0a[_0x43545a('0x5')][_0x43545a('0x8')](_0x17b16e,_0x44fca1,_0x359ab0)[_0x43545a('0x3')](function(){const _0x568d80=_0x43545a;logger[_0x568d80('0x12')](_0x568d80('0x17'),_0x44fca1,_0x359ab0,_0x17b16e);})[_0x43545a('0x14')](function(_0x428c3c){const _0x187f7d=_0x43545a;logger[_0x187f7d('0x12')](util['inspect'](_0x428c3c,{'showHidden':![],'depth':null}));});});},Migration[_0x2d196b('0xa')]['final']=function(_0x4c8d9b){const _0x214a94=_0x2d196b;this[_0x214a94('0x11')]['enqueue'](function(){return _0x4c8d9b();});},module[_0x2d196b('0x1')]={'up':function(_0x1bc5df){return new Promise(function(_0x15ac1e){const _0x12c2ac=new Migration(_0x1bc5df);_0x12c2ac['final'](_0x15ac1e);});},'down':function(){}}; \ No newline at end of file +const a1009_0x419a=['indexName','addIndex','indicesType','queryInterface','removeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','dropTable','catch','stringify','tail','migration','removeIndex\x20%s\x20%s','exports','sequelize','join','final','info','table\x20dropped\x20%s','query\x20%s','renameColumn','inspect','Changed\x20column\x20%s\x20in\x20table\x20%s','sequence','then','query','addIndex\x20%s\x20%s\x20%s\x20[%s]','Added\x20column\x20%s\x20to\x20%s','../config/logger','enqueue','changeColumn','prototype','removeIndex','addColumn'];(function(_0x52f0b0,_0x419aca){const _0x165c71=function(_0x18454a){while(--_0x18454a){_0x52f0b0['push'](_0x52f0b0['shift']());}};_0x165c71(++_0x419aca);}(a1009_0x419a,0x177));const a1009_0x165c=function(_0x52f0b0,_0x419aca){_0x52f0b0=_0x52f0b0-0x0;let _0x165c71=a1009_0x419a[_0x52f0b0];return _0x165c71;};const _0x5c398d=a1009_0x165c;'use strict';const util=require('util'),logger=require(_0x5c398d('0xf'))(_0x5c398d('0x1f')),Sequence=function(){};Sequence[_0x5c398d('0x12')][_0x5c398d('0x10')]=function(_0x18454a){const _0x53700e=_0x5c398d;this[_0x53700e('0x1e')]=this[_0x53700e('0x1e')]?this['tail']['finally'](_0x18454a):_0x18454a();};const Migration=function(_0x2e0ed3){const _0x16508f=_0x5c398d;this[_0x16508f('0x18')]=_0x2e0ed3,this['sequence']=new Sequence();};Migration[_0x5c398d('0x12')][_0x5c398d('0x11')]=function(_0xb0a23,_0x5d6af3,_0xc054e0){const _0x51b62b=_0x5c398d,_0x297574=this;this[_0x51b62b('0xa')][_0x51b62b('0x10')](function(){const _0x3e4e9f=_0x51b62b;return _0x297574[_0x3e4e9f('0x18')]['changeColumn'](_0xb0a23,_0x5d6af3,_0xc054e0)[_0x3e4e9f('0xb')](function(){const _0x4012c9=_0x3e4e9f;logger[_0x4012c9('0x4')](_0x4012c9('0x9'),_0x5d6af3,_0xb0a23);})['catch'](function(_0x1caa7e){const _0xabd2ef=_0x3e4e9f;logger[_0xabd2ef('0x4')](JSON[_0xabd2ef('0x1d')](_0x1caa7e));});});},Migration[_0x5c398d('0x12')][_0x5c398d('0x14')]=function(_0x3e1a78,_0xa5f18,_0x221459){const _0x3c6db8=_0x5c398d,_0x47505d=this;this[_0x3c6db8('0xa')]['enqueue'](function(){const _0x3e4579=_0x3c6db8;return _0x47505d[_0x3e4579('0x18')][_0x3e4579('0x14')](_0x3e1a78,_0xa5f18,_0x221459)['then'](function(){const _0x48052d=_0x3e4579;logger['info'](_0x48052d('0xe'),_0xa5f18,_0x3e1a78);})[_0x3e4579('0x1c')](function(_0x3bb1b2){const _0x5118ce=_0x3e4579;logger[_0x5118ce('0x4')](JSON[_0x5118ce('0x1d')](_0x3bb1b2));});});},Migration[_0x5c398d('0x12')][_0x5c398d('0x1b')]=function(_0x57d0ea){const _0x5dc86f=_0x5c398d,_0x4e5d21=this;this[_0x5dc86f('0xa')][_0x5dc86f('0x10')](function(){const _0x122c59=_0x5dc86f;return _0x4e5d21['queryInterface'][_0x122c59('0x1b')](_0x57d0ea,{'force':!![]})['then'](function(){const _0x1bbf8a=_0x122c59;logger[_0x1bbf8a('0x4')](_0x1bbf8a('0x5'),_0x57d0ea);})['catch'](function(_0xb7261e){const _0x208e60=_0x122c59;logger[_0x208e60('0x4')](JSON[_0x208e60('0x1d')](_0xb7261e));});});},Migration['prototype'][_0x5c398d('0x16')]=function(_0x570eb6,_0x32bc48,_0x35a317){const _0x34b6de=_0x5c398d,_0xc30b2f=this;this[_0x34b6de('0xa')][_0x34b6de('0x10')](function(){const _0x463a9c=_0x34b6de;return _0xc30b2f[_0x463a9c('0x18')][_0x463a9c('0x16')](_0x570eb6,_0x32bc48,{'indexName':_0x35a317['indexName'],'indicesType':_0x35a317[_0x463a9c('0x17')]})[_0x463a9c('0xb')](function(){const _0x2d06ce=_0x463a9c;logger[_0x2d06ce('0x4')](_0x2d06ce('0xd'),_0x570eb6,_0x32bc48[_0x2d06ce('0x2')](','),_0x35a317[_0x2d06ce('0x15')],_0x35a317[_0x2d06ce('0x17')]);})[_0x463a9c('0x1c')](function(_0x584674){const _0x30e579=_0x463a9c;logger[_0x30e579('0x4')](JSON[_0x30e579('0x1d')](_0x584674));});});},Migration[_0x5c398d('0x12')]['removeIndex']=function(_0x4fa95a,_0x58dc3e){const _0x4b52bb=_0x5c398d,_0x273ba7=this;this[_0x4b52bb('0xa')][_0x4b52bb('0x10')](function(){const _0x5430ef=_0x4b52bb;return _0x273ba7[_0x5430ef('0x18')][_0x5430ef('0x13')](_0x4fa95a,_0x58dc3e)[_0x5430ef('0xb')](function(){const _0x712ad8=_0x5430ef;logger[_0x712ad8('0x4')](_0x712ad8('0x20'),_0x4fa95a,_0x58dc3e);})['catch'](function(_0x36fa29){const _0x42987a=_0x5430ef;logger[_0x42987a('0x4')](JSON[_0x42987a('0x1d')](_0x36fa29));});});},Migration[_0x5c398d('0x12')][_0x5c398d('0xc')]=function(_0x5a1f28){const _0xed1a37=_0x5c398d,_0x31dd35=this;this[_0xed1a37('0xa')]['enqueue'](function(){const _0x313bbb=_0xed1a37;return _0x31dd35['queryInterface'][_0x313bbb('0x1')][_0x313bbb('0xc')](_0x5a1f28)[_0x313bbb('0xb')](function(){const _0x1455ea=_0x313bbb;logger[_0x1455ea('0x4')](_0x1455ea('0x6'),_0x5a1f28);})[_0x313bbb('0x1c')](function(_0xc81285){const _0x571b8a=_0x313bbb;logger[_0x571b8a('0x4')](JSON[_0x571b8a('0x1d')](_0xc81285));});});},Migration['prototype'][_0x5c398d('0x19')]=function(_0x38b2b3,_0x5964af){const _0x2cc51b=this;this['sequence']['enqueue'](function(){const _0x572378=a1009_0x165c;return _0x2cc51b['queryInterface'][_0x572378('0x19')](_0x38b2b3,_0x5964af)[_0x572378('0xb')](function(){const _0x350df9=_0x572378;logger[_0x350df9('0x4')]('Removed\x20column\x20%s\x20from\x20%s',_0x5964af,_0x38b2b3);})[_0x572378('0x1c')](function(_0xffeca4){const _0x199c02=_0x572378;logger[_0x199c02('0x4')](util[_0x199c02('0x8')](_0xffeca4,{'showHidden':![],'depth':null}));});});},Migration[_0x5c398d('0x12')]['renameColumn']=function(_0x392e7d,_0x34b7f1,_0x4aaa87){const _0x5830ed=_0x5c398d,_0x3f30d9=this;this[_0x5830ed('0xa')][_0x5830ed('0x10')](function(){const _0x20e8ec=_0x5830ed;return _0x3f30d9[_0x20e8ec('0x18')][_0x20e8ec('0x7')](_0x392e7d,_0x34b7f1,_0x4aaa87)[_0x20e8ec('0xb')](function(){const _0x2b06c7=_0x20e8ec;logger[_0x2b06c7('0x4')](_0x2b06c7('0x1a'),_0x34b7f1,_0x4aaa87,_0x392e7d);})[_0x20e8ec('0x1c')](function(_0x464a8c){const _0x504ed0=_0x20e8ec;logger[_0x504ed0('0x4')](util[_0x504ed0('0x8')](_0x464a8c,{'showHidden':![],'depth':null}));});});},Migration[_0x5c398d('0x12')][_0x5c398d('0x3')]=function(_0x2a5f1b){const _0x3f0b80=_0x5c398d;this[_0x3f0b80('0xa')][_0x3f0b80('0x10')](function(){return _0x2a5f1b();});},module[_0x5c398d('0x0')]={'up':function(_0x7528ce){return new Promise(function(_0x497db2){const _0x4c532e=a1009_0x165c,_0x4dd0f8=new Migration(_0x7528ce);_0x4dd0f8[_0x4c532e('0x3')](_0x497db2);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.7.js b/server/migrations/2.4.7.js index 69b9493..f2b05d6 100644 --- a/server/migrations/2.4.7.js +++ b/server/migrations/2.4.7.js @@ -1 +1 @@ -const a1010_0x8e08=['Added\x20column\x20%s\x20to\x20%s','stringify','query\x20%s','removeColumn','chat_websites','addIndex','join','inspect','indexName','util','table\x20dropped\x20%s','info','migration','removeIndex\x20%s\x20%s','query','sequence','BOOLEAN','moduleCreate','exports','../config/logger','addIndex\x20%s\x20%s\x20%s\x20[%s]','finally','Changed\x20column\x20%s\x20in\x20table\x20%s','addColumn','sequelize','then','queryInterface','chat_interactions','prototype','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','catch','Leads','final','removeIndex','ENUM','customerPort','tail','enqueue','changeColumn','Feedback','dropTable','renameColumn','indicesType','Contacts','STRING'];(function(_0x4e8201,_0x8e08eb){const _0x2f2075=function(_0x598f46){while(--_0x598f46){_0x4e8201['push'](_0x4e8201['shift']());}};_0x2f2075(++_0x8e08eb);}(a1010_0x8e08,0x173));const a1010_0x2f20=function(_0x4e8201,_0x8e08eb){_0x4e8201=_0x4e8201-0x0;let _0x2f2075=a1010_0x8e08[_0x4e8201];return _0x2f2075;};const _0xabe1fd=a1010_0x2f20;'use strict';const util=require(_0xabe1fd('0x2b')),logger=require(_0xabe1fd('0x8'))(_0xabe1fd('0x1')),Sequence=function(){};Sequence[_0xabe1fd('0x11')]['enqueue']=function(_0x598f46){const _0x2255b1=_0xabe1fd;this[_0x2255b1('0x19')]=this['tail']?this['tail'][_0x2255b1('0xa')](_0x598f46):_0x598f46();};const Migration=function(_0x35db27){const _0x685b54=_0xabe1fd;this['queryInterface']=_0x35db27,this[_0x685b54('0x4')]=new Sequence();};Migration[_0xabe1fd('0x11')][_0xabe1fd('0x1b')]=function(_0x6cdfe3,_0x5d916b,_0x219712){const _0x5c13e6=_0xabe1fd,_0xb62208=this;this[_0x5c13e6('0x4')][_0x5c13e6('0x1a')](function(){const _0x15c0f2=_0x5c13e6;return _0xb62208[_0x15c0f2('0xf')]['changeColumn'](_0x6cdfe3,_0x5d916b,_0x219712)['then'](function(){const _0xb2c87b=_0x15c0f2;logger[_0xb2c87b('0x0')](_0xb2c87b('0xb'),_0x5d916b,_0x6cdfe3);})[_0x15c0f2('0x13')](function(_0x47955e){const _0x4ee5c4=_0x15c0f2;logger[_0x4ee5c4('0x0')](JSON[_0x4ee5c4('0x23')](_0x47955e));});});},Migration['prototype'][_0xabe1fd('0xc')]=function(_0x55df06,_0x2843d6,_0x210b48){const _0x4acecb=_0xabe1fd,_0x1a578a=this;this[_0x4acecb('0x4')][_0x4acecb('0x1a')](function(){const _0x2b5585=_0x4acecb;return _0x1a578a[_0x2b5585('0xf')]['addColumn'](_0x55df06,_0x2843d6,_0x210b48)[_0x2b5585('0xe')](function(){const _0x130189=_0x2b5585;logger[_0x130189('0x0')](_0x130189('0x22'),_0x2843d6,_0x55df06);})[_0x2b5585('0x13')](function(_0x30a0fa){const _0xed8529=_0x2b5585;logger[_0xed8529('0x0')](JSON['stringify'](_0x30a0fa));});});},Migration['prototype']['dropTable']=function(_0x4ac481){const _0x5c193c=_0xabe1fd,_0x3a1e3f=this;this[_0x5c193c('0x4')]['enqueue'](function(){const _0x55a218=_0x5c193c;return _0x3a1e3f[_0x55a218('0xf')][_0x55a218('0x1d')](_0x4ac481,{'force':!![]})[_0x55a218('0xe')](function(){const _0x56878f=_0x55a218;logger[_0x56878f('0x0')](_0x56878f('0x2c'),_0x4ac481);})['catch'](function(_0x86818a){const _0x30de1b=_0x55a218;logger[_0x30de1b('0x0')](JSON['stringify'](_0x86818a));});});},Migration[_0xabe1fd('0x11')][_0xabe1fd('0x27')]=function(_0x2d4243,_0x1e2644,_0x4e91e3){const _0x3af202=this;this['sequence']['enqueue'](function(){const _0x180303=a1010_0x2f20;return _0x3af202[_0x180303('0xf')][_0x180303('0x27')](_0x2d4243,_0x1e2644,{'indexName':_0x4e91e3['indexName'],'indicesType':_0x4e91e3['indicesType']})[_0x180303('0xe')](function(){const _0x276168=_0x180303;logger[_0x276168('0x0')](_0x276168('0x9'),_0x2d4243,_0x1e2644[_0x276168('0x28')](','),_0x4e91e3[_0x276168('0x2a')],_0x4e91e3[_0x276168('0x1f')]);})[_0x180303('0x13')](function(_0x24f924){const _0x4c61a8=_0x180303;logger[_0x4c61a8('0x0')](JSON[_0x4c61a8('0x23')](_0x24f924));});});},Migration[_0xabe1fd('0x11')][_0xabe1fd('0x16')]=function(_0x3d9553,_0x46626a){const _0x496521=_0xabe1fd,_0x3222f2=this;this[_0x496521('0x4')]['enqueue'](function(){const _0x26447e=_0x496521;return _0x3222f2[_0x26447e('0xf')][_0x26447e('0x16')](_0x3d9553,_0x46626a)[_0x26447e('0xe')](function(){const _0x29e438=_0x26447e;logger[_0x29e438('0x0')](_0x29e438('0x2'),_0x3d9553,_0x46626a);})[_0x26447e('0x13')](function(_0x1c1376){const _0x125ae6=_0x26447e;logger[_0x125ae6('0x0')](JSON[_0x125ae6('0x23')](_0x1c1376));});});},Migration['prototype'][_0xabe1fd('0x3')]=function(_0x3e7fe4){const _0x4b19bc=_0xabe1fd,_0x320d50=this;this[_0x4b19bc('0x4')]['enqueue'](function(){const _0x420931=_0x4b19bc;return _0x320d50[_0x420931('0xf')][_0x420931('0xd')][_0x420931('0x3')](_0x3e7fe4)['then'](function(){const _0x24d74f=_0x420931;logger['info'](_0x24d74f('0x24'),_0x3e7fe4);})[_0x420931('0x13')](function(_0x99c987){logger['info'](JSON['stringify'](_0x99c987));});});},Migration[_0xabe1fd('0x11')][_0xabe1fd('0x25')]=function(_0x1ac29b,_0x4cedeb){const _0x4cdcb9=_0xabe1fd,_0x355b4d=this;this[_0x4cdcb9('0x4')][_0x4cdcb9('0x1a')](function(){const _0x49287b=_0x4cdcb9;return _0x355b4d[_0x49287b('0xf')][_0x49287b('0x25')](_0x1ac29b,_0x4cedeb)[_0x49287b('0xe')](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x4cedeb,_0x1ac29b);})['catch'](function(_0x5ef479){logger['info'](util['inspect'](_0x5ef479,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0xabe1fd('0x1e')]=function(_0xe6f2aa,_0x492140,_0x290655){const _0x36557a=_0xabe1fd,_0x533686=this;this[_0x36557a('0x4')][_0x36557a('0x1a')](function(){const _0x56f447=_0x36557a;return _0x533686['queryInterface'][_0x56f447('0x1e')](_0xe6f2aa,_0x492140,_0x290655)[_0x56f447('0xe')](function(){const _0x8defee=_0x56f447;logger[_0x8defee('0x0')](_0x8defee('0x12'),_0x492140,_0x290655,_0xe6f2aa);})[_0x56f447('0x13')](function(_0x35f3f2){const _0x7e3770=_0x56f447;logger[_0x7e3770('0x0')](util[_0x7e3770('0x29')](_0x35f3f2,{'showHidden':![],'depth':null}));});});},Migration[_0xabe1fd('0x11')][_0xabe1fd('0x15')]=function(_0x3f0678){const _0x469e85=_0xabe1fd;this[_0x469e85('0x4')][_0x469e85('0x1a')](function(){return _0x3f0678();});},module[_0xabe1fd('0x7')]={'up':function(_0x196f04,_0x25f0ca){return new Promise(function(_0x490107){const _0x3b8fa7=a1010_0x2f20,_0x4fa592=new Migration(_0x196f04);_0x4fa592[_0x3b8fa7('0xc')]('int_zoho_configurations',_0x3b8fa7('0x6'),{'type':_0x25f0ca[_0x3b8fa7('0x17')]('Leads',_0x3b8fa7('0x20')),'defaultValue':_0x3b8fa7('0x14')}),_0x4fa592['addColumn'](_0x3b8fa7('0x10'),_0x3b8fa7('0x18'),{'type':_0x25f0ca[_0x3b8fa7('0x21')]}),_0x4fa592[_0x3b8fa7('0xc')](_0x3b8fa7('0x26'),'enableSendButton',{'type':_0x25f0ca[_0x3b8fa7('0x5')],'defaultValue':![]}),_0x4fa592[_0x3b8fa7('0xc')](_0x3b8fa7('0x26'),'feedbackTitle',{'type':_0x25f0ca[_0x3b8fa7('0x21')],'defaultValue':_0x3b8fa7('0x1c')}),_0x4fa592[_0x3b8fa7('0x15')](_0x490107);});},'down':function(){}}; \ No newline at end of file +const a1010_0x5431=['inspect','enableSendButton','util','Removed\x20column\x20%s\x20from\x20%s','Feedback','removeIndex','STRING','prototype','Contacts','info','addIndex','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','BOOLEAN','chat_websites','indicesType','sequelize','Leads','migration','moduleCreate','feedbackTitle','removeColumn','queryInterface','ENUM','enqueue','query','removeIndex\x20%s\x20%s','stringify','final','dropTable','renameColumn','addColumn','sequence','then','Changed\x20column\x20%s\x20in\x20table\x20%s','chat_interactions','addIndex\x20%s\x20%s\x20%s\x20[%s]','tail','query\x20%s','indexName','catch','join','table\x20dropped\x20%s','changeColumn'];(function(_0x10d19f,_0x54310e){const _0x1f2122=function(_0x15d4db){while(--_0x15d4db){_0x10d19f['push'](_0x10d19f['shift']());}};_0x1f2122(++_0x54310e);}(a1010_0x5431,0x11d));const a1010_0x1f21=function(_0x10d19f,_0x54310e){_0x10d19f=_0x10d19f-0x0;let _0x1f2122=a1010_0x5431[_0x10d19f];return _0x1f2122;};const _0x46cb20=a1010_0x1f21;'use strict';const util=require(_0x46cb20('0x12')),logger=require('../config/logger')(_0x46cb20('0x21')),Sequence=function(){};Sequence[_0x46cb20('0x17')][_0x46cb20('0x27')]=function(_0x15d4db){const _0x2c05b5=_0x46cb20;this[_0x2c05b5('0x9')]=this[_0x2c05b5('0x9')]?this[_0x2c05b5('0x9')]['finally'](_0x15d4db):_0x15d4db();};const Migration=function(_0x374aaa){const _0x40890c=_0x46cb20;this[_0x40890c('0x25')]=_0x374aaa,this['sequence']=new Sequence();};Migration[_0x46cb20('0x17')][_0x46cb20('0xf')]=function(_0x37e8a8,_0x3887d1,_0x1292e4){const _0x1aef7d=_0x46cb20,_0x516147=this;this[_0x1aef7d('0x4')][_0x1aef7d('0x27')](function(){const _0x3644ad=_0x1aef7d;return _0x516147[_0x3644ad('0x25')][_0x3644ad('0xf')](_0x37e8a8,_0x3887d1,_0x1292e4)['then'](function(){const _0x5f2403=_0x3644ad;logger['info'](_0x5f2403('0x6'),_0x3887d1,_0x37e8a8);})[_0x3644ad('0xc')](function(_0x2df156){const _0x5b8d6a=_0x3644ad;logger[_0x5b8d6a('0x19')](JSON['stringify'](_0x2df156));});});},Migration[_0x46cb20('0x17')][_0x46cb20('0x3')]=function(_0x500cfa,_0x36b0f5,_0x1e39a2){const _0x54cc29=_0x46cb20,_0xe4554b=this;this[_0x54cc29('0x4')][_0x54cc29('0x27')](function(){const _0x49a72c=_0x54cc29;return _0xe4554b[_0x49a72c('0x25')][_0x49a72c('0x3')](_0x500cfa,_0x36b0f5,_0x1e39a2)['then'](function(){logger['info']('Added\x20column\x20%s\x20to\x20%s',_0x36b0f5,_0x500cfa);})[_0x49a72c('0xc')](function(_0x52f50a){const _0x181314=_0x49a72c;logger['info'](JSON[_0x181314('0x2a')](_0x52f50a));});});},Migration[_0x46cb20('0x17')][_0x46cb20('0x1')]=function(_0x5a20c2){const _0x2ca350=_0x46cb20,_0x3f5d53=this;this['sequence'][_0x2ca350('0x27')](function(){const _0x4b5aac=_0x2ca350;return _0x3f5d53[_0x4b5aac('0x25')][_0x4b5aac('0x1')](_0x5a20c2,{'force':!![]})['then'](function(){const _0x93e254=_0x4b5aac;logger[_0x93e254('0x19')](_0x93e254('0xe'),_0x5a20c2);})[_0x4b5aac('0xc')](function(_0x5e4a08){const _0x483aaa=_0x4b5aac;logger[_0x483aaa('0x19')](JSON[_0x483aaa('0x2a')](_0x5e4a08));});});},Migration[_0x46cb20('0x17')][_0x46cb20('0x1a')]=function(_0x723d6,_0x2cf735,_0xc6a74d){const _0x505ae3=_0x46cb20,_0x306242=this;this[_0x505ae3('0x4')][_0x505ae3('0x27')](function(){const _0x5f2ee1=_0x505ae3;return _0x306242[_0x5f2ee1('0x25')][_0x5f2ee1('0x1a')](_0x723d6,_0x2cf735,{'indexName':_0xc6a74d['indexName'],'indicesType':_0xc6a74d[_0x5f2ee1('0x1e')]})[_0x5f2ee1('0x5')](function(){const _0x58a294=_0x5f2ee1;logger[_0x58a294('0x19')](_0x58a294('0x8'),_0x723d6,_0x2cf735[_0x58a294('0xd')](','),_0xc6a74d[_0x58a294('0xb')],_0xc6a74d[_0x58a294('0x1e')]);})[_0x5f2ee1('0xc')](function(_0xe9c713){const _0x5daac3=_0x5f2ee1;logger[_0x5daac3('0x19')](JSON[_0x5daac3('0x2a')](_0xe9c713));});});},Migration[_0x46cb20('0x17')][_0x46cb20('0x15')]=function(_0x42bb52,_0x4113fc){const _0xfc5e18=_0x46cb20,_0x5af175=this;this[_0xfc5e18('0x4')][_0xfc5e18('0x27')](function(){const _0x4db42e=_0xfc5e18;return _0x5af175[_0x4db42e('0x25')][_0x4db42e('0x15')](_0x42bb52,_0x4113fc)[_0x4db42e('0x5')](function(){const _0x4f0483=_0x4db42e;logger[_0x4f0483('0x19')](_0x4f0483('0x29'),_0x42bb52,_0x4113fc);})[_0x4db42e('0xc')](function(_0x3a224a){const _0x381ec5=_0x4db42e;logger[_0x381ec5('0x19')](JSON[_0x381ec5('0x2a')](_0x3a224a));});});},Migration[_0x46cb20('0x17')][_0x46cb20('0x28')]=function(_0x4af73f){const _0x573d4a=_0x46cb20,_0x224f69=this;this[_0x573d4a('0x4')][_0x573d4a('0x27')](function(){const _0x490c30=_0x573d4a;return _0x224f69[_0x490c30('0x25')][_0x490c30('0x1f')][_0x490c30('0x28')](_0x4af73f)['then'](function(){const _0x1961fc=_0x490c30;logger[_0x1961fc('0x19')](_0x1961fc('0xa'),_0x4af73f);})['catch'](function(_0xa1e8d8){const _0x516419=_0x490c30;logger[_0x516419('0x19')](JSON[_0x516419('0x2a')](_0xa1e8d8));});});},Migration[_0x46cb20('0x17')][_0x46cb20('0x24')]=function(_0x17f38b,_0x1bd6a6){const _0x4d6318=_0x46cb20,_0x21cd1c=this;this[_0x4d6318('0x4')][_0x4d6318('0x27')](function(){const _0x443d49=_0x4d6318;return _0x21cd1c[_0x443d49('0x25')][_0x443d49('0x24')](_0x17f38b,_0x1bd6a6)['then'](function(){const _0x364954=_0x443d49;logger[_0x364954('0x19')](_0x364954('0x13'),_0x1bd6a6,_0x17f38b);})[_0x443d49('0xc')](function(_0x12c8d1){const _0x864f21=_0x443d49;logger[_0x864f21('0x19')](util[_0x864f21('0x10')](_0x12c8d1,{'showHidden':![],'depth':null}));});});},Migration[_0x46cb20('0x17')][_0x46cb20('0x2')]=function(_0x353ad2,_0x4078cd,_0x39b296){const _0x3e0614=_0x46cb20,_0x546188=this;this[_0x3e0614('0x4')]['enqueue'](function(){const _0x34af61=_0x3e0614;return _0x546188[_0x34af61('0x25')][_0x34af61('0x2')](_0x353ad2,_0x4078cd,_0x39b296)['then'](function(){const _0x4d4d0a=_0x34af61;logger[_0x4d4d0a('0x19')](_0x4d4d0a('0x1b'),_0x4078cd,_0x39b296,_0x353ad2);})[_0x34af61('0xc')](function(_0x474f28){logger['info'](util['inspect'](_0x474f28,{'showHidden':![],'depth':null}));});});},Migration[_0x46cb20('0x17')][_0x46cb20('0x0')]=function(_0x135536){const _0x4bf3e3=_0x46cb20;this[_0x4bf3e3('0x4')]['enqueue'](function(){return _0x135536();});},module['exports']={'up':function(_0xf43a58,_0x326733){return new Promise(function(_0x19948f){const _0x18d75e=a1010_0x1f21,_0x5c230c=new Migration(_0xf43a58);_0x5c230c[_0x18d75e('0x3')]('int_zoho_configurations',_0x18d75e('0x22'),{'type':_0x326733[_0x18d75e('0x26')](_0x18d75e('0x20'),_0x18d75e('0x18')),'defaultValue':_0x18d75e('0x20')}),_0x5c230c[_0x18d75e('0x3')](_0x18d75e('0x7'),'customerPort',{'type':_0x326733[_0x18d75e('0x16')]}),_0x5c230c[_0x18d75e('0x3')]('chat_websites',_0x18d75e('0x11'),{'type':_0x326733[_0x18d75e('0x1c')],'defaultValue':![]}),_0x5c230c[_0x18d75e('0x3')](_0x18d75e('0x1d'),_0x18d75e('0x23'),{'type':_0x326733[_0x18d75e('0x16')],'defaultValue':_0x18d75e('0x14')}),_0x5c230c['final'](_0x19948f);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.8.js b/server/migrations/2.4.8.js index 759fa9b..fcbdb1f 100644 --- a/server/migrations/2.4.8.js +++ b/server/migrations/2.4.8.js @@ -1 +1 @@ -const a1011_0x22f6=['enqueue','then','final','indicesType','queryInterface','query\x20%s','query','finally','addColumn','info','../config/logger','inspect','removeIndex\x20%s\x20%s','Removed\x20column\x20%s\x20from\x20%s','removeColumn','exports','tail','addIndex\x20%s\x20%s\x20%s\x20[%s]','stringify','changeColumn','sequence','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','removeIndex','catch','addIndex','prototype','dropTable','Changed\x20column\x20%s\x20in\x20table\x20%s','renameColumn','indexName'];(function(_0x3a035d,_0x22f616){const _0x4903b6=function(_0x1d10ac){while(--_0x1d10ac){_0x3a035d['push'](_0x3a035d['shift']());}};_0x4903b6(++_0x22f616);}(a1011_0x22f6,0xa4));const a1011_0x4903=function(_0x3a035d,_0x22f616){_0x3a035d=_0x3a035d-0x0;let _0x4903b6=a1011_0x22f6[_0x3a035d];return _0x4903b6;};const _0x4edaac=a1011_0x4903;'use strict';const util=require('util'),logger=require(_0x4edaac('0x1a'))('migration'),Sequence=function(){};Sequence[_0x4edaac('0xb')][_0x4edaac('0x10')]=function(_0x1d10ac){const _0x588ae3=_0x4edaac;this['tail']=this['tail']?this[_0x588ae3('0x2')][_0x588ae3('0x17')](_0x1d10ac):_0x1d10ac();};const Migration=function(_0x5824d6){const _0x4f80b6=_0x4edaac;this[_0x4f80b6('0x14')]=_0x5824d6,this[_0x4f80b6('0x6')]=new Sequence();};Migration[_0x4edaac('0xb')][_0x4edaac('0x5')]=function(_0x328bdc,_0x46e8f2,_0x13d542){const _0x45d0a8=this;this['sequence']['enqueue'](function(){const _0x4540ec=a1011_0x4903;return _0x45d0a8[_0x4540ec('0x14')][_0x4540ec('0x5')](_0x328bdc,_0x46e8f2,_0x13d542)[_0x4540ec('0x11')](function(){const _0x266489=_0x4540ec;logger[_0x266489('0x19')](_0x266489('0xd'),_0x46e8f2,_0x328bdc);})[_0x4540ec('0x9')](function(_0x56ff72){const _0x126957=_0x4540ec;logger[_0x126957('0x19')](JSON[_0x126957('0x4')](_0x56ff72));});});},Migration[_0x4edaac('0xb')][_0x4edaac('0x18')]=function(_0xe791eb,_0x17324d,_0x1cf95a){const _0x4062a3=_0x4edaac,_0x22297d=this;this[_0x4062a3('0x6')]['enqueue'](function(){const _0x37f15e=_0x4062a3;return _0x22297d[_0x37f15e('0x14')][_0x37f15e('0x18')](_0xe791eb,_0x17324d,_0x1cf95a)[_0x37f15e('0x11')](function(){const _0x39b10b=_0x37f15e;logger[_0x39b10b('0x19')]('Added\x20column\x20%s\x20to\x20%s',_0x17324d,_0xe791eb);})[_0x37f15e('0x9')](function(_0x1d0ce5){const _0x1d46d0=_0x37f15e;logger[_0x1d46d0('0x19')](JSON[_0x1d46d0('0x4')](_0x1d0ce5));});});},Migration[_0x4edaac('0xb')][_0x4edaac('0xc')]=function(_0x3768fd){const _0x329ed1=_0x4edaac,_0x1c0622=this;this[_0x329ed1('0x6')][_0x329ed1('0x10')](function(){const _0x14d157=_0x329ed1;return _0x1c0622[_0x14d157('0x14')]['dropTable'](_0x3768fd,{'force':!![]})['then'](function(){const _0x3a3edb=_0x14d157;logger[_0x3a3edb('0x19')]('table\x20dropped\x20%s',_0x3768fd);})['catch'](function(_0x2551a4){const _0x5c0a04=_0x14d157;logger[_0x5c0a04('0x19')](JSON['stringify'](_0x2551a4));});});},Migration[_0x4edaac('0xb')]['addIndex']=function(_0x3f437e,_0x4c803d,_0x119b61){const _0x33bcc0=_0x4edaac,_0x2c8b41=this;this[_0x33bcc0('0x6')]['enqueue'](function(){const _0x514d28=_0x33bcc0;return _0x2c8b41[_0x514d28('0x14')][_0x514d28('0xa')](_0x3f437e,_0x4c803d,{'indexName':_0x119b61[_0x514d28('0xf')],'indicesType':_0x119b61[_0x514d28('0x13')]})[_0x514d28('0x11')](function(){const _0x12cba9=_0x514d28;logger[_0x12cba9('0x19')](_0x12cba9('0x3'),_0x3f437e,_0x4c803d['join'](','),_0x119b61[_0x12cba9('0xf')],_0x119b61[_0x12cba9('0x13')]);})[_0x514d28('0x9')](function(_0xb4c1ad){const _0x411884=_0x514d28;logger['info'](JSON[_0x411884('0x4')](_0xb4c1ad));});});},Migration[_0x4edaac('0xb')][_0x4edaac('0x8')]=function(_0x3021e2,_0x2c967f){const _0x3aac0a=_0x4edaac,_0x1a79ae=this;this[_0x3aac0a('0x6')][_0x3aac0a('0x10')](function(){const _0xbf9f65=_0x3aac0a;return _0x1a79ae[_0xbf9f65('0x14')]['removeIndex'](_0x3021e2,_0x2c967f)[_0xbf9f65('0x11')](function(){const _0x3fc41e=_0xbf9f65;logger[_0x3fc41e('0x19')](_0x3fc41e('0x1c'),_0x3021e2,_0x2c967f);})[_0xbf9f65('0x9')](function(_0x4859e1){const _0x279bf2=_0xbf9f65;logger[_0x279bf2('0x19')](JSON[_0x279bf2('0x4')](_0x4859e1));});});},Migration[_0x4edaac('0xb')][_0x4edaac('0x16')]=function(_0x3bb975){const _0x41e672=_0x4edaac,_0x23e2cc=this;this[_0x41e672('0x6')][_0x41e672('0x10')](function(){const _0x3872a3=_0x41e672;return _0x23e2cc['queryInterface']['sequelize']['query'](_0x3bb975)['then'](function(){const _0x40d0f7=a1011_0x4903;logger[_0x40d0f7('0x19')](_0x40d0f7('0x15'),_0x3bb975);})[_0x3872a3('0x9')](function(_0x5387e4){const _0x33306e=_0x3872a3;logger[_0x33306e('0x19')](JSON[_0x33306e('0x4')](_0x5387e4));});});},Migration['prototype'][_0x4edaac('0x0')]=function(_0x59fad4,_0x1dad6b){const _0xc32025=_0x4edaac,_0x186b83=this;this[_0xc32025('0x6')][_0xc32025('0x10')](function(){const _0x583e05=_0xc32025;return _0x186b83['queryInterface'][_0x583e05('0x0')](_0x59fad4,_0x1dad6b)['then'](function(){const _0x5dba5b=_0x583e05;logger['info'](_0x5dba5b('0x1d'),_0x1dad6b,_0x59fad4);})[_0x583e05('0x9')](function(_0x21d7b7){const _0x591479=_0x583e05;logger[_0x591479('0x19')](util['inspect'](_0x21d7b7,{'showHidden':![],'depth':null}));});});},Migration[_0x4edaac('0xb')][_0x4edaac('0xe')]=function(_0x2fef53,_0x364cde,_0x489bee){const _0x38b46e=_0x4edaac,_0x551144=this;this[_0x38b46e('0x6')]['enqueue'](function(){const _0x3e912d=_0x38b46e;return _0x551144[_0x3e912d('0x14')][_0x3e912d('0xe')](_0x2fef53,_0x364cde,_0x489bee)[_0x3e912d('0x11')](function(){const _0x5d4a90=_0x3e912d;logger['info'](_0x5d4a90('0x7'),_0x364cde,_0x489bee,_0x2fef53);})[_0x3e912d('0x9')](function(_0x162b6d){const _0x30bc93=_0x3e912d;logger['info'](util[_0x30bc93('0x1b')](_0x162b6d,{'showHidden':![],'depth':null}));});});},Migration[_0x4edaac('0xb')][_0x4edaac('0x12')]=function(_0x5e7e32){const _0x3fe284=_0x4edaac;this[_0x3fe284('0x6')][_0x3fe284('0x10')](function(){return _0x5e7e32();});},module[_0x4edaac('0x1')]={'up':function(_0x4cbece){return new Promise(function(_0x4d2e66){const _0x466753=new Migration(_0x4cbece);_0x466753['final'](_0x4d2e66);});},'down':function(){}}; \ No newline at end of file +const a1011_0x43ba=['then','query','addColumn','migration','addIndex','catch','sequence','info','sequelize','Added\x20column\x20%s\x20to\x20%s','enqueue','join','dropTable','removeIndex','changeColumn','indexName','inspect','renameColumn','queryInterface','removeIndex\x20%s\x20%s','prototype','query\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex\x20%s\x20%s\x20%s\x20[%s]','indicesType','stringify','Removed\x20column\x20%s\x20from\x20%s','../config/logger','removeColumn','finally','tail'];(function(_0x1a6284,_0x43baa8){const _0x143598=function(_0xee636f){while(--_0xee636f){_0x1a6284['push'](_0x1a6284['shift']());}};_0x143598(++_0x43baa8);}(a1011_0x43ba,0x1d3));const a1011_0x1435=function(_0x1a6284,_0x43baa8){_0x1a6284=_0x1a6284-0x0;let _0x143598=a1011_0x43ba[_0x1a6284];return _0x143598;};const _0x4bb87f=a1011_0x1435;'use strict';const util=require('util'),logger=require(_0x4bb87f('0x19'))(_0x4bb87f('0x1')),Sequence=function(){};Sequence[_0x4bb87f('0x12')]['enqueue']=function(_0xee636f){const _0x4b978b=_0x4bb87f;this[_0x4b978b('0x1c')]=this[_0x4b978b('0x1c')]?this['tail'][_0x4b978b('0x1b')](_0xee636f):_0xee636f();};const Migration=function(_0x24e02c){const _0x40c88b=_0x4bb87f;this[_0x40c88b('0x10')]=_0x24e02c,this[_0x40c88b('0x4')]=new Sequence();};Migration['prototype'][_0x4bb87f('0xc')]=function(_0x2b4b81,_0x119a5f,_0x385d00){const _0x2376fd=_0x4bb87f,_0x453e5d=this;this['sequence'][_0x2376fd('0x8')](function(){const _0x5c59ec=_0x2376fd;return _0x453e5d[_0x5c59ec('0x10')][_0x5c59ec('0xc')](_0x2b4b81,_0x119a5f,_0x385d00)[_0x5c59ec('0x1d')](function(){const _0x54b7a0=_0x5c59ec;logger[_0x54b7a0('0x5')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x119a5f,_0x2b4b81);})['catch'](function(_0x251df0){const _0x7b2cb7=_0x5c59ec;logger['info'](JSON[_0x7b2cb7('0x17')](_0x251df0));});});},Migration[_0x4bb87f('0x12')]['addColumn']=function(_0x38050e,_0x26c465,_0x18969a){const _0x3cf1c1=_0x4bb87f,_0x37950c=this;this[_0x3cf1c1('0x4')][_0x3cf1c1('0x8')](function(){const _0x47ccea=_0x3cf1c1;return _0x37950c[_0x47ccea('0x10')][_0x47ccea('0x0')](_0x38050e,_0x26c465,_0x18969a)['then'](function(){const _0x12dd17=_0x47ccea;logger[_0x12dd17('0x5')](_0x12dd17('0x7'),_0x26c465,_0x38050e);})['catch'](function(_0x3a2b27){const _0x160e0f=_0x47ccea;logger[_0x160e0f('0x5')](JSON[_0x160e0f('0x17')](_0x3a2b27));});});},Migration['prototype'][_0x4bb87f('0xa')]=function(_0x91f08f){const _0x4af8ae=_0x4bb87f,_0x319420=this;this[_0x4af8ae('0x4')][_0x4af8ae('0x8')](function(){const _0x4db3bb=_0x4af8ae;return _0x319420[_0x4db3bb('0x10')][_0x4db3bb('0xa')](_0x91f08f,{'force':!![]})['then'](function(){const _0x26dc42=_0x4db3bb;logger[_0x26dc42('0x5')]('table\x20dropped\x20%s',_0x91f08f);})['catch'](function(_0x10a9cc){const _0x49912e=_0x4db3bb;logger[_0x49912e('0x5')](JSON[_0x49912e('0x17')](_0x10a9cc));});});},Migration[_0x4bb87f('0x12')][_0x4bb87f('0x2')]=function(_0x2296d6,_0x10cf4b,_0x27fdc9){const _0x3431de=_0x4bb87f,_0x45d8be=this;this[_0x3431de('0x4')][_0x3431de('0x8')](function(){const _0x36940a=_0x3431de;return _0x45d8be[_0x36940a('0x10')]['addIndex'](_0x2296d6,_0x10cf4b,{'indexName':_0x27fdc9[_0x36940a('0xd')],'indicesType':_0x27fdc9[_0x36940a('0x16')]})['then'](function(){const _0x2d1c73=_0x36940a;logger['info'](_0x2d1c73('0x15'),_0x2296d6,_0x10cf4b[_0x2d1c73('0x9')](','),_0x27fdc9[_0x2d1c73('0xd')],_0x27fdc9[_0x2d1c73('0x16')]);})[_0x36940a('0x3')](function(_0x333ffd){const _0x26e2b8=_0x36940a;logger[_0x26e2b8('0x5')](JSON[_0x26e2b8('0x17')](_0x333ffd));});});},Migration[_0x4bb87f('0x12')][_0x4bb87f('0xb')]=function(_0x2c42d0,_0x408900){const _0x2ef9ac=_0x4bb87f,_0x461334=this;this['sequence'][_0x2ef9ac('0x8')](function(){const _0x31fd8f=_0x2ef9ac;return _0x461334[_0x31fd8f('0x10')][_0x31fd8f('0xb')](_0x2c42d0,_0x408900)[_0x31fd8f('0x1d')](function(){const _0x57bd3f=_0x31fd8f;logger['info'](_0x57bd3f('0x11'),_0x2c42d0,_0x408900);})[_0x31fd8f('0x3')](function(_0x15903d){const _0x2377e9=_0x31fd8f;logger[_0x2377e9('0x5')](JSON[_0x2377e9('0x17')](_0x15903d));});});},Migration[_0x4bb87f('0x12')][_0x4bb87f('0x1e')]=function(_0x24449c){const _0x16ce16=_0x4bb87f,_0x30a862=this;this[_0x16ce16('0x4')][_0x16ce16('0x8')](function(){const _0x51c5c1=_0x16ce16;return _0x30a862['queryInterface'][_0x51c5c1('0x6')][_0x51c5c1('0x1e')](_0x24449c)[_0x51c5c1('0x1d')](function(){const _0x2cffa8=_0x51c5c1;logger[_0x2cffa8('0x5')](_0x2cffa8('0x13'),_0x24449c);})[_0x51c5c1('0x3')](function(_0x58c414){const _0x2a7d99=_0x51c5c1;logger[_0x2a7d99('0x5')](JSON[_0x2a7d99('0x17')](_0x58c414));});});},Migration[_0x4bb87f('0x12')][_0x4bb87f('0x1a')]=function(_0x21e7e4,_0x4f8353){const _0x21a464=_0x4bb87f,_0x593f5c=this;this['sequence'][_0x21a464('0x8')](function(){const _0x1e2812=_0x21a464;return _0x593f5c[_0x1e2812('0x10')][_0x1e2812('0x1a')](_0x21e7e4,_0x4f8353)[_0x1e2812('0x1d')](function(){const _0x4cfb9f=_0x1e2812;logger['info'](_0x4cfb9f('0x18'),_0x4f8353,_0x21e7e4);})[_0x1e2812('0x3')](function(_0x34331b){const _0x300941=_0x1e2812;logger[_0x300941('0x5')](util[_0x300941('0xe')](_0x34331b,{'showHidden':![],'depth':null}));});});},Migration[_0x4bb87f('0x12')][_0x4bb87f('0xf')]=function(_0x1115d8,_0x16af52,_0x3f890b){const _0x82399e=_0x4bb87f,_0x2d4ccc=this;this[_0x82399e('0x4')][_0x82399e('0x8')](function(){const _0x135b4b=_0x82399e;return _0x2d4ccc['queryInterface']['renameColumn'](_0x1115d8,_0x16af52,_0x3f890b)[_0x135b4b('0x1d')](function(){const _0x38081c=_0x135b4b;logger['info'](_0x38081c('0x14'),_0x16af52,_0x3f890b,_0x1115d8);})['catch'](function(_0xa30312){const _0x38451c=_0x135b4b;logger[_0x38451c('0x5')](util[_0x38451c('0xe')](_0xa30312,{'showHidden':![],'depth':null}));});});},Migration[_0x4bb87f('0x12')]['final']=function(_0x88aa88){const _0x2921f6=_0x4bb87f;this[_0x2921f6('0x4')]['enqueue'](function(){return _0x88aa88();});},module['exports']={'up':function(_0x1a99e2){return new Promise(function(_0xb23478){const _0x39503f=new Migration(_0x1a99e2);_0x39503f['final'](_0xb23478);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.4.9.js b/server/migrations/2.4.9.js index dfde3f9..ecbf993 100644 --- a/server/migrations/2.4.9.js +++ b/server/migrations/2.4.9.js @@ -1 +1 @@ -const a1012_0x5403=['changeColumn','sequelize','stringify','Added\x20column\x20%s\x20to\x20%s','indexName','catch','query','../config/logger','Changed\x20column\x20%s\x20in\x20table\x20%s','queryInterface','exports','dropTable','prototype','tail','util','renameColumn','addIndex\x20%s\x20%s\x20%s\x20[%s]','addColumn','inspect','migration','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex','indicesType','then','removeIndex\x20%s\x20%s','table\x20dropped\x20%s','removeColumn','removeIndex','sequence','Removed\x20column\x20%s\x20from\x20%s','final','info','enqueue'];(function(_0x2298c2,_0x5403ca){const _0x132e58=function(_0x27cfcf){while(--_0x27cfcf){_0x2298c2['push'](_0x2298c2['shift']());}};_0x132e58(++_0x5403ca);}(a1012_0x5403,0x6d));const a1012_0x132e=function(_0x2298c2,_0x5403ca){_0x2298c2=_0x2298c2-0x0;let _0x132e58=a1012_0x5403[_0x2298c2];return _0x132e58;};const _0x3a177e=a1012_0x132e;'use strict';const util=require(_0x3a177e('0x4')),logger=require(_0x3a177e('0x1e'))(_0x3a177e('0x9')),Sequence=function(){};Sequence[_0x3a177e('0x2')][_0x3a177e('0x16')]=function(_0x27cfcf){const _0x25b0da=_0x3a177e;this[_0x25b0da('0x3')]=this['tail']?this[_0x25b0da('0x3')]['finally'](_0x27cfcf):_0x27cfcf();};const Migration=function(_0x16a554){this['queryInterface']=_0x16a554,this['sequence']=new Sequence();};Migration[_0x3a177e('0x2')][_0x3a177e('0x17')]=function(_0x944bd8,_0x1144a0,_0x2195eb){const _0x3df582=_0x3a177e,_0x3e114b=this;this[_0x3df582('0x12')]['enqueue'](function(){const _0x210109=_0x3df582;return _0x3e114b[_0x210109('0x20')][_0x210109('0x17')](_0x944bd8,_0x1144a0,_0x2195eb)['then'](function(){const _0x59250d=_0x210109;logger[_0x59250d('0x15')](_0x59250d('0x1f'),_0x1144a0,_0x944bd8);})[_0x210109('0x1c')](function(_0x54212c){const _0x322175=_0x210109;logger[_0x322175('0x15')](JSON[_0x322175('0x19')](_0x54212c));});});},Migration[_0x3a177e('0x2')]['addColumn']=function(_0x3dfc14,_0x43a0d1,_0x115223){const _0x12e36b=_0x3a177e,_0x57f692=this;this['sequence'][_0x12e36b('0x16')](function(){const _0x5d3b60=_0x12e36b;return _0x57f692[_0x5d3b60('0x20')][_0x5d3b60('0x7')](_0x3dfc14,_0x43a0d1,_0x115223)[_0x5d3b60('0xd')](function(){const _0xc94a04=_0x5d3b60;logger[_0xc94a04('0x15')](_0xc94a04('0x1a'),_0x43a0d1,_0x3dfc14);})['catch'](function(_0x4e946c){const _0x3a430b=_0x5d3b60;logger[_0x3a430b('0x15')](JSON[_0x3a430b('0x19')](_0x4e946c));});});},Migration[_0x3a177e('0x2')][_0x3a177e('0x1')]=function(_0x293953){const _0x59d708=_0x3a177e,_0x4884d3=this;this[_0x59d708('0x12')]['enqueue'](function(){const _0x127824=_0x59d708;return _0x4884d3['queryInterface'][_0x127824('0x1')](_0x293953,{'force':!![]})[_0x127824('0xd')](function(){const _0x1cdfb0=_0x127824;logger[_0x1cdfb0('0x15')](_0x1cdfb0('0xf'),_0x293953);})[_0x127824('0x1c')](function(_0x70c5e8){const _0x571c1c=_0x127824;logger[_0x571c1c('0x15')](JSON[_0x571c1c('0x19')](_0x70c5e8));});});},Migration[_0x3a177e('0x2')][_0x3a177e('0xb')]=function(_0x4fa882,_0x224af9,_0x322141){const _0x479109=_0x3a177e,_0x5e8a91=this;this[_0x479109('0x12')][_0x479109('0x16')](function(){const _0x323a1a=_0x479109;return _0x5e8a91['queryInterface'][_0x323a1a('0xb')](_0x4fa882,_0x224af9,{'indexName':_0x322141[_0x323a1a('0x1b')],'indicesType':_0x322141[_0x323a1a('0xc')]})[_0x323a1a('0xd')](function(){const _0x711f2f=_0x323a1a;logger[_0x711f2f('0x15')](_0x711f2f('0x6'),_0x4fa882,_0x224af9['join'](','),_0x322141[_0x711f2f('0x1b')],_0x322141[_0x711f2f('0xc')]);})[_0x323a1a('0x1c')](function(_0x263355){const _0x6fc215=_0x323a1a;logger[_0x6fc215('0x15')](JSON[_0x6fc215('0x19')](_0x263355));});});},Migration['prototype'][_0x3a177e('0x11')]=function(_0x5bce94,_0xe289b1){const _0x18b3af=this;this['sequence']['enqueue'](function(){const _0x2c1c8a=a1012_0x132e;return _0x18b3af[_0x2c1c8a('0x20')][_0x2c1c8a('0x11')](_0x5bce94,_0xe289b1)[_0x2c1c8a('0xd')](function(){const _0x284f6a=_0x2c1c8a;logger[_0x284f6a('0x15')](_0x284f6a('0xe'),_0x5bce94,_0xe289b1);})['catch'](function(_0x55c507){const _0x373c66=_0x2c1c8a;logger[_0x373c66('0x15')](JSON[_0x373c66('0x19')](_0x55c507));});});},Migration['prototype'][_0x3a177e('0x1d')]=function(_0x40bb70){const _0x1c1e77=_0x3a177e,_0x35a00c=this;this[_0x1c1e77('0x12')]['enqueue'](function(){const _0xda7ed8=_0x1c1e77;return _0x35a00c[_0xda7ed8('0x20')][_0xda7ed8('0x18')]['query'](_0x40bb70)[_0xda7ed8('0xd')](function(){const _0x5664e7=_0xda7ed8;logger[_0x5664e7('0x15')]('query\x20%s',_0x40bb70);})[_0xda7ed8('0x1c')](function(_0x28f19c){const _0x384ce1=_0xda7ed8;logger[_0x384ce1('0x15')](JSON[_0x384ce1('0x19')](_0x28f19c));});});},Migration['prototype']['removeColumn']=function(_0x11ae76,_0x3db815){const _0x3f2008=_0x3a177e,_0x4c12b1=this;this[_0x3f2008('0x12')][_0x3f2008('0x16')](function(){const _0x3afdbb=_0x3f2008;return _0x4c12b1[_0x3afdbb('0x20')][_0x3afdbb('0x10')](_0x11ae76,_0x3db815)['then'](function(){const _0x2c0d8f=_0x3afdbb;logger['info'](_0x2c0d8f('0x13'),_0x3db815,_0x11ae76);})[_0x3afdbb('0x1c')](function(_0x455a09){const _0x55c1a6=_0x3afdbb;logger[_0x55c1a6('0x15')](util['inspect'](_0x455a09,{'showHidden':![],'depth':null}));});});},Migration[_0x3a177e('0x2')][_0x3a177e('0x5')]=function(_0x312797,_0x44ce95,_0x465a5c){const _0x4a07d1=_0x3a177e,_0x41f135=this;this[_0x4a07d1('0x12')][_0x4a07d1('0x16')](function(){const _0x2d7404=_0x4a07d1;return _0x41f135[_0x2d7404('0x20')][_0x2d7404('0x5')](_0x312797,_0x44ce95,_0x465a5c)['then'](function(){const _0x3e6227=_0x2d7404;logger['info'](_0x3e6227('0xa'),_0x44ce95,_0x465a5c,_0x312797);})[_0x2d7404('0x1c')](function(_0x303929){const _0x47a63e=_0x2d7404;logger['info'](util[_0x47a63e('0x8')](_0x303929,{'showHidden':![],'depth':null}));});});},Migration[_0x3a177e('0x2')][_0x3a177e('0x14')]=function(_0x4ca50c){const _0x19d487=_0x3a177e;this['sequence'][_0x19d487('0x16')](function(){return _0x4ca50c();});},module[_0x3a177e('0x0')]={'up':function(_0x27dd8c){return new Promise(function(_0x3af370){const _0x3b0917=a1012_0x132e,_0x1810ef=new Migration(_0x27dd8c);_0x1810ef[_0x3b0917('0x14')](_0x3af370);});},'down':function(){}}; \ No newline at end of file +const a1012_0x577d=['query','renameColumn','Removed\x20column\x20%s\x20from\x20%s','inspect','indicesType','indexName','queryInterface','dropTable','then','Changed\x20column\x20%s\x20in\x20table\x20%s','join','table\x20dropped\x20%s','info','enqueue','util','../config/logger','tail','addColumn','removeColumn','addIndex\x20%s\x20%s\x20%s\x20[%s]','final','addIndex','stringify','prototype','catch','sequelize','changeColumn','removeIndex','removeIndex\x20%s\x20%s','exports','sequence','query\x20%s'];(function(_0x200291,_0x577d98){const _0x28d109=function(_0x3eb481){while(--_0x3eb481){_0x200291['push'](_0x200291['shift']());}};_0x28d109(++_0x577d98);}(a1012_0x577d,0xdf));const a1012_0x28d1=function(_0x200291,_0x577d98){_0x200291=_0x200291-0x0;let _0x28d109=a1012_0x577d[_0x200291];return _0x28d109;};const _0x10f734=a1012_0x28d1;'use strict';const util=require(_0x10f734('0xf')),logger=require(_0x10f734('0x10'))('migration'),Sequence=function(){};Sequence[_0x10f734('0x18')]['enqueue']=function(_0x3eb481){const _0x49e4dd=_0x10f734;this[_0x49e4dd('0x11')]=this[_0x49e4dd('0x11')]?this[_0x49e4dd('0x11')]['finally'](_0x3eb481):_0x3eb481();};const Migration=function(_0xf164fd){const _0x376cd1=_0x10f734;this[_0x376cd1('0x7')]=_0xf164fd,this['sequence']=new Sequence();};Migration[_0x10f734('0x18')][_0x10f734('0x1b')]=function(_0x28965d,_0x3cada9,_0x43b4ca){const _0x1f01e2=_0x10f734,_0x38e404=this;this[_0x1f01e2('0x1f')][_0x1f01e2('0xe')](function(){const _0x38c2c0=_0x1f01e2;return _0x38e404[_0x38c2c0('0x7')][_0x38c2c0('0x1b')](_0x28965d,_0x3cada9,_0x43b4ca)[_0x38c2c0('0x9')](function(){const _0x280ad3=_0x38c2c0;logger[_0x280ad3('0xd')](_0x280ad3('0xa'),_0x3cada9,_0x28965d);})[_0x38c2c0('0x19')](function(_0x3da1f9){const _0x444243=_0x38c2c0;logger['info'](JSON[_0x444243('0x17')](_0x3da1f9));});});},Migration[_0x10f734('0x18')][_0x10f734('0x12')]=function(_0x60e59c,_0x3f041d,_0x14055a){const _0x3ba5c1=_0x10f734,_0x269fd5=this;this[_0x3ba5c1('0x1f')][_0x3ba5c1('0xe')](function(){const _0x4310fa=_0x3ba5c1;return _0x269fd5[_0x4310fa('0x7')]['addColumn'](_0x60e59c,_0x3f041d,_0x14055a)['then'](function(){const _0x4304e8=_0x4310fa;logger[_0x4304e8('0xd')]('Added\x20column\x20%s\x20to\x20%s',_0x3f041d,_0x60e59c);})[_0x4310fa('0x19')](function(_0xa1feef){const _0x22d0a9=_0x4310fa;logger[_0x22d0a9('0xd')](JSON[_0x22d0a9('0x17')](_0xa1feef));});});},Migration[_0x10f734('0x18')][_0x10f734('0x8')]=function(_0x3f1451){const _0x15823e=_0x10f734,_0x32e207=this;this['sequence'][_0x15823e('0xe')](function(){const _0x4c0e7c=_0x15823e;return _0x32e207[_0x4c0e7c('0x7')][_0x4c0e7c('0x8')](_0x3f1451,{'force':!![]})[_0x4c0e7c('0x9')](function(){const _0x54e687=_0x4c0e7c;logger[_0x54e687('0xd')](_0x54e687('0xc'),_0x3f1451);})[_0x4c0e7c('0x19')](function(_0x8d05c){const _0x177697=_0x4c0e7c;logger[_0x177697('0xd')](JSON[_0x177697('0x17')](_0x8d05c));});});},Migration[_0x10f734('0x18')][_0x10f734('0x16')]=function(_0x394480,_0x2596d2,_0x9fd7e7){const _0x3ded1a=_0x10f734,_0x46bcb0=this;this[_0x3ded1a('0x1f')][_0x3ded1a('0xe')](function(){const _0x52537a=_0x3ded1a;return _0x46bcb0[_0x52537a('0x7')]['addIndex'](_0x394480,_0x2596d2,{'indexName':_0x9fd7e7[_0x52537a('0x6')],'indicesType':_0x9fd7e7[_0x52537a('0x5')]})[_0x52537a('0x9')](function(){const _0x44e395=_0x52537a;logger[_0x44e395('0xd')](_0x44e395('0x14'),_0x394480,_0x2596d2[_0x44e395('0xb')](','),_0x9fd7e7['indexName'],_0x9fd7e7[_0x44e395('0x5')]);})[_0x52537a('0x19')](function(_0x18d4d8){const _0x357a05=_0x52537a;logger[_0x357a05('0xd')](JSON[_0x357a05('0x17')](_0x18d4d8));});});},Migration[_0x10f734('0x18')][_0x10f734('0x1c')]=function(_0x239458,_0x3e7f8d){const _0x303459=_0x10f734,_0x50fe1b=this;this[_0x303459('0x1f')][_0x303459('0xe')](function(){const _0x22285d=_0x303459;return _0x50fe1b['queryInterface'][_0x22285d('0x1c')](_0x239458,_0x3e7f8d)[_0x22285d('0x9')](function(){const _0x51e552=_0x22285d;logger[_0x51e552('0xd')](_0x51e552('0x1d'),_0x239458,_0x3e7f8d);})[_0x22285d('0x19')](function(_0x2bb8e7){const _0x4045e7=_0x22285d;logger['info'](JSON[_0x4045e7('0x17')](_0x2bb8e7));});});},Migration[_0x10f734('0x18')][_0x10f734('0x1')]=function(_0x2083cf){const _0x231ad4=_0x10f734,_0x92e397=this;this[_0x231ad4('0x1f')][_0x231ad4('0xe')](function(){const _0x4a0161=_0x231ad4;return _0x92e397['queryInterface'][_0x4a0161('0x1a')][_0x4a0161('0x1')](_0x2083cf)[_0x4a0161('0x9')](function(){const _0x4bbf2d=_0x4a0161;logger['info'](_0x4bbf2d('0x0'),_0x2083cf);})[_0x4a0161('0x19')](function(_0x4cbec1){const _0x474d59=_0x4a0161;logger[_0x474d59('0xd')](JSON[_0x474d59('0x17')](_0x4cbec1));});});},Migration[_0x10f734('0x18')]['removeColumn']=function(_0x1bc8c1,_0x25cfb1){const _0x5bf681=_0x10f734,_0x59d96f=this;this[_0x5bf681('0x1f')]['enqueue'](function(){const _0x1fae4a=_0x5bf681;return _0x59d96f[_0x1fae4a('0x7')][_0x1fae4a('0x13')](_0x1bc8c1,_0x25cfb1)[_0x1fae4a('0x9')](function(){const _0x3213e9=_0x1fae4a;logger[_0x3213e9('0xd')](_0x3213e9('0x3'),_0x25cfb1,_0x1bc8c1);})['catch'](function(_0x54f27f){const _0x4dc42e=_0x1fae4a;logger['info'](util[_0x4dc42e('0x4')](_0x54f27f,{'showHidden':![],'depth':null}));});});},Migration[_0x10f734('0x18')][_0x10f734('0x2')]=function(_0x25e495,_0x419207,_0x2f3d7a){const _0x2f8cb0=_0x10f734,_0x11b275=this;this[_0x2f8cb0('0x1f')][_0x2f8cb0('0xe')](function(){const _0x37f6cb=_0x2f8cb0;return _0x11b275[_0x37f6cb('0x7')][_0x37f6cb('0x2')](_0x25e495,_0x419207,_0x2f3d7a)[_0x37f6cb('0x9')](function(){const _0x15f8fe=_0x37f6cb;logger[_0x15f8fe('0xd')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x419207,_0x2f3d7a,_0x25e495);})[_0x37f6cb('0x19')](function(_0x3afc66){const _0x21348e=_0x37f6cb;logger[_0x21348e('0xd')](util['inspect'](_0x3afc66,{'showHidden':![],'depth':null}));});});},Migration[_0x10f734('0x18')][_0x10f734('0x15')]=function(_0x8adcd0){const _0x537a62=_0x10f734;this[_0x537a62('0x1f')][_0x537a62('0xe')](function(){return _0x8adcd0();});},module[_0x10f734('0x1e')]={'up':function(_0x127fd6){return new Promise(function(_0x1c7e2a){const _0x455078=a1012_0x28d1,_0x479438=new Migration(_0x127fd6);_0x479438[_0x455078('0x15')](_0x1c7e2a);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.5.0.js b/server/migrations/2.5.0.js index 692a13f..fdec436 100644 --- a/server/migrations/2.5.0.js +++ b/server/migrations/2.5.0.js @@ -1 +1 @@ -const a1013_0x4198=['NEW','Changed\x20column\x20%s\x20in\x20table\x20%s','\x20CONSTRAINT\x20`whatsapp_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`ListId`)\x20REFERENCES\x20`cm_lists`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE','\x20`agentTransfer`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,','WhatsappAccountId','tempSentiment','\x20`key`\x20varchar(255)\x20NOT\x20NULL,','sMixed','../config/logger','addColumn','tools_canned_answers','location','renameColumn','language','Removed\x20column\x20%s\x20from\x20%s','chat_interactions','bucket','sNegative','\x20UNIQUE\x20KEY\x20`name`\x20(`name`),','\x20`updatedAt`\x20datetime\x20NOT\x20NULL,','inspect','voice_recordings','final','stringify','\x20PRIMARY\x20KEY\x20(`id`),','sentimentAccountId','\x20`agentTransferTimeout`\x20int(11)\x20DEFAULT\x20\x27300\x27,','dropTable','\x20`createdAt`\x20datetime\x20NOT\x20NULL,','finally','\x20`waitForTheAssignedAgent`\x20int(11)\x20DEFAULT\x20\x2710\x27,','users','FLOAT','\x20`mandatoryDisposition`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,','removeColumn','ALTER\x20TABLE\x20tools_dispositions\x20ADD\x20CONSTRAINT\x20`name_whatsapp`\x20UNIQUE\x20KEY\x20(`name`,`WhatsappAccountId`)','Added\x20column\x20%s\x20to\x20%s','exports','automaticSentiment','then','addIndex','\x20CONSTRAINT\x20`whatsapp_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20REFERENCES\x20`tools_pauses`\x20(`id`)\x20ON\x20DELETE\x20NO\x20ACTION\x20ON\x20UPDATE\x20CASCADE,','vidaooSessionId','util','vidaooApiKey','indexName','settings','removeIndex','automaticTranscribe','table\x20dropped\x20%s',')\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','TEXT','\x20`type`\x20enum(\x27twilio\x27)\x20DEFAULT\x20NULL,','sentimentRegion','transcribe','INTEGER','transcribeRegion','sNeutral','\x20`phone`\x20varchar(255)\x20DEFAULT\x20NULL,','\x20`token`\x20varchar(255)\x20DEFAULT\x20NULL,','queryInterface','ALTER\x20TABLE\x20tools_canned_answers\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_6`\x20FOREIGN\x20KEY\x20(`WhatsappAccountId`)\x20REFERENCES\x20`whatsapp_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE','catch','failureReason','BOOLEAN','enqueue','removeIndex\x20%s\x20%s','tail','transcribeName','STRING','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','whatsappCapacity','\x20`authToken`\x20varchar(255)\x20DEFAULT\x20NULL,','fileText','\x20`name`\x20varchar(255)\x20NOT\x20NULL,','info','indicesType','\x20`notificationShake`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,','query','\x20`accountSid`\x20varchar(255)\x20DEFAULT\x20NULL,','chat_websites','sentiment','vidaooEscalation','changeColumn','sequence','prototype','CREATE\x20TABLE\x20`whatsapp_accounts`\x20(','\x20`queueTransfer`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,'];(function(_0x1e43f8,_0x4198a9){const _0x1c3c3f=function(_0x30d3df){while(--_0x30d3df){_0x1e43f8['push'](_0x1e43f8['shift']());}};_0x1c3c3f(++_0x4198a9);}(a1013_0x4198,0x10b));const a1013_0x1c3c=function(_0x1e43f8,_0x4198a9){_0x1e43f8=_0x1e43f8-0x0;let _0x1c3c3f=a1013_0x4198[_0x1e43f8];return _0x1c3c3f;};const _0x4c5882=a1013_0x1c3c;'use strict';const util=require(_0x4c5882('0x28')),logger=require(_0x4c5882('0x5'))('migration'),Sequence=function(){};Sequence[_0x4c5882('0x52')][_0x4c5882('0x3e')]=function(_0x30d3df){const _0x48e4a0=_0x4c5882;this['tail']=this[_0x48e4a0('0x40')]?this[_0x48e4a0('0x40')][_0x48e4a0('0x1a')](_0x30d3df):_0x30d3df();};const Migration=function(_0x28a664){const _0x3f4616=_0x4c5882;this[_0x3f4616('0x39')]=_0x28a664,this['sequence']=new Sequence();};Migration[_0x4c5882('0x52')]['changeColumn']=function(_0x38ac26,_0x722d2e,_0x2af4c7){const _0x4003a3=_0x4c5882,_0x4fccf7=this;this['sequence'][_0x4003a3('0x3e')](function(){const _0x5cd7a5=_0x4003a3;return _0x4fccf7[_0x5cd7a5('0x39')][_0x5cd7a5('0x50')](_0x38ac26,_0x722d2e,_0x2af4c7)[_0x5cd7a5('0x24')](function(){const _0x51116e=_0x5cd7a5;logger[_0x51116e('0x48')](_0x51116e('0x56'),_0x722d2e,_0x38ac26);})[_0x5cd7a5('0x3b')](function(_0x73c65f){const _0x1307de=_0x5cd7a5;logger[_0x1307de('0x48')](JSON['stringify'](_0x73c65f));});});},Migration['prototype']['addColumn']=function(_0x22c393,_0x5c7362,_0x5102bd){const _0x4e715b=_0x4c5882,_0x356776=this;this[_0x4e715b('0x51')][_0x4e715b('0x3e')](function(){const _0x5c8fe9=_0x4e715b;return _0x356776[_0x5c8fe9('0x39')][_0x5c8fe9('0x6')](_0x22c393,_0x5c7362,_0x5102bd)[_0x5c8fe9('0x24')](function(){const _0x5545d3=_0x5c8fe9;logger[_0x5545d3('0x48')](_0x5545d3('0x21'),_0x5c7362,_0x22c393);})[_0x5c8fe9('0x3b')](function(_0x2860ab){const _0x55629c=_0x5c8fe9;logger[_0x55629c('0x48')](JSON[_0x55629c('0x14')](_0x2860ab));});});},Migration['prototype'][_0x4c5882('0x18')]=function(_0x5a6bbb){const _0x35b195=_0x4c5882,_0x59871d=this;this[_0x35b195('0x51')]['enqueue'](function(){const _0x37be27=_0x35b195;return _0x59871d[_0x37be27('0x39')][_0x37be27('0x18')](_0x5a6bbb,{'force':!![]})[_0x37be27('0x24')](function(){const _0x24f598=_0x37be27;logger[_0x24f598('0x48')](_0x24f598('0x2e'),_0x5a6bbb);})[_0x37be27('0x3b')](function(_0x34b246){const _0x1e9226=_0x37be27;logger[_0x1e9226('0x48')](JSON[_0x1e9226('0x14')](_0x34b246));});});},Migration['prototype'][_0x4c5882('0x25')]=function(_0x1bbea7,_0x2fd1d6,_0x5c20ce){const _0x510554=_0x4c5882,_0x3fc2ec=this;this[_0x510554('0x51')][_0x510554('0x3e')](function(){const _0x1c5985=_0x510554;return _0x3fc2ec[_0x1c5985('0x39')]['addIndex'](_0x1bbea7,_0x2fd1d6,{'indexName':_0x5c20ce[_0x1c5985('0x2a')],'indicesType':_0x5c20ce[_0x1c5985('0x49')]})[_0x1c5985('0x24')](function(){const _0x5d1f05=_0x1c5985;logger[_0x5d1f05('0x48')]('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x1bbea7,_0x2fd1d6['join'](','),_0x5c20ce['indexName'],_0x5c20ce[_0x5d1f05('0x49')]);})[_0x1c5985('0x3b')](function(_0x5cadb4){const _0x291c44=_0x1c5985;logger[_0x291c44('0x48')](JSON[_0x291c44('0x14')](_0x5cadb4));});});},Migration[_0x4c5882('0x52')]['removeIndex']=function(_0x91a831,_0x3f8489){const _0x109bf9=_0x4c5882,_0xdcfa90=this;this[_0x109bf9('0x51')][_0x109bf9('0x3e')](function(){const _0x4269dc=_0x109bf9;return _0xdcfa90['queryInterface'][_0x4269dc('0x2c')](_0x91a831,_0x3f8489)[_0x4269dc('0x24')](function(){const _0xfdd277=_0x4269dc;logger['info'](_0xfdd277('0x3f'),_0x91a831,_0x3f8489);})[_0x4269dc('0x3b')](function(_0xf31eba){const _0x1a34d7=_0x4269dc;logger[_0x1a34d7('0x48')](JSON[_0x1a34d7('0x14')](_0xf31eba));});});},Migration[_0x4c5882('0x52')][_0x4c5882('0x4b')]=function(_0x578ce0){const _0x5e7d64=_0x4c5882,_0x1772be=this;this[_0x5e7d64('0x51')][_0x5e7d64('0x3e')](function(){const _0x5021ba=_0x5e7d64;return _0x1772be[_0x5021ba('0x39')]['sequelize'][_0x5021ba('0x4b')](_0x578ce0)[_0x5021ba('0x24')](function(){const _0x1cc92f=_0x5021ba;logger[_0x1cc92f('0x48')]('query\x20%s',_0x578ce0);})[_0x5021ba('0x3b')](function(_0x471865){const _0x3d59be=_0x5021ba;logger['info'](JSON[_0x3d59be('0x14')](_0x471865));});});},Migration[_0x4c5882('0x52')][_0x4c5882('0x1f')]=function(_0x112215,_0x2ac432){const _0x4ae2f2=_0x4c5882,_0x23df4b=this;this[_0x4ae2f2('0x51')][_0x4ae2f2('0x3e')](function(){const _0x10d5ae=_0x4ae2f2;return _0x23df4b['queryInterface'][_0x10d5ae('0x1f')](_0x112215,_0x2ac432)[_0x10d5ae('0x24')](function(){const _0x426434=_0x10d5ae;logger['info'](_0x426434('0xb'),_0x2ac432,_0x112215);})[_0x10d5ae('0x3b')](function(_0x13d318){const _0x3e3c32=_0x10d5ae;logger[_0x3e3c32('0x48')](util[_0x3e3c32('0x11')](_0x13d318,{'showHidden':![],'depth':null}));});});},Migration[_0x4c5882('0x52')][_0x4c5882('0x9')]=function(_0x4a65c8,_0x14eed1,_0x3954e4){const _0x606739=_0x4c5882,_0x80440f=this;this['sequence'][_0x606739('0x3e')](function(){const _0x1804ba=_0x606739;return _0x80440f['queryInterface'][_0x1804ba('0x9')](_0x4a65c8,_0x14eed1,_0x3954e4)[_0x1804ba('0x24')](function(){const _0x4962ee=_0x1804ba;logger['info'](_0x4962ee('0x43'),_0x14eed1,_0x3954e4,_0x4a65c8);})[_0x1804ba('0x3b')](function(_0x291171){const _0x1a8d0e=_0x1804ba;logger[_0x1a8d0e('0x48')](util[_0x1a8d0e('0x11')](_0x291171,{'showHidden':![],'depth':null}));});});},Migration[_0x4c5882('0x52')]['final']=function(_0x44721d){this['sequence']['enqueue'](function(){return _0x44721d();});},module[_0x4c5882('0x22')]={'up':function(_0x56b7ec,_0x501b65){return new Promise(function(_0xe712be){const _0x4683ff=a1013_0x1c3c,_0x5356d0=new Migration(_0x56b7ec);_0x5356d0[_0x4683ff('0x4b')](_0x4683ff('0x53')+'\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,'+_0x4683ff('0x47')+_0x4683ff('0x3')+'\x20`remote`\x20varchar(255)\x20NOT\x20NULL,'+_0x4683ff('0x38')+_0x4683ff('0x37')+_0x4683ff('0x31')+_0x4683ff('0x4c')+_0x4683ff('0x45')+'\x20`notificationTemplate`\x20text,'+'\x20`notificationSound`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,'+_0x4683ff('0x4a')+_0x4683ff('0x1b')+_0x4683ff('0x54')+'\x20`queueTransferTimeout`\x20int(11)\x20DEFAULT\x20\x27300\x27,'+_0x4683ff('0x0')+_0x4683ff('0x17')+'\x20`mandatoryDispositionPauseId`\x20int(11)\x20DEFAULT\x20NULL,'+_0x4683ff('0x1e')+'\x20`description`\x20varchar(255)\x20DEFAULT\x20NULL,'+_0x4683ff('0x19')+_0x4683ff('0x10')+'\x20`ListId`\x20int(11)\x20DEFAULT\x20NULL,'+_0x4683ff('0x15')+_0x4683ff('0xf')+'\x20KEY\x20`mandatoryDispositionPauseId`\x20(`mandatoryDispositionPauseId`),'+'\x20KEY\x20`ListId`\x20(`ListId`),'+_0x4683ff('0x26')+_0x4683ff('0x57')+_0x4683ff('0x2f')),_0x5356d0['addColumn']('tools_dispositions',_0x4683ff('0x1'),{'type':_0x501b65[_0x4683ff('0x34')]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x7'),_0x4683ff('0x1'),{'type':_0x501b65['INTEGER']}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x1c'),'whatsappPause',{'type':_0x501b65[_0x4683ff('0x3d')],'defaultValue':![]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x1c'),_0x4683ff('0x44'),{'type':_0x501b65['BOOLEAN'],'defaultValue':![]}),_0x5356d0[_0x4683ff('0x4b')]('ALTER\x20TABLE\x20tools_dispositions\x20ADD\x20CONSTRAINT\x20`tools_dispositions_ibfk_7`\x20FOREIGN\x20KEY\x20(`WhatsappAccountId`)\x20REFERENCES\x20`whatsapp_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE'),_0x5356d0['query'](_0x4683ff('0x20')),_0x5356d0[_0x4683ff('0x4b')](_0x4683ff('0x3a')),_0x5356d0[_0x4683ff('0x4b')]('UPDATE\x20users\x20SET\x20permissions=\x27101,102,103,113,110,104,105,106,107,108,109,100,111,114\x27\x20WHERE\x20role=\x27agent\x27\x20AND\x20permissions=\x27101,102,103,110,104,105,106,107,108,109,100,111\x27'),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0xc'),_0x4683ff('0x27'),{'type':_0x501b65[_0x4683ff('0x30')]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x4d'),_0x4683ff('0x4f'),{'type':_0x501b65[_0x4683ff('0x3d')],'defaultValue':![]}),_0x5356d0[_0x4683ff('0x6')]('chat_websites',_0x4683ff('0x29'),{'type':_0x501b65[_0x4683ff('0x42')]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x12'),_0x4683ff('0x8'),{'type':_0x501b65['TEXT']}),_0x5356d0['addColumn'](_0x4683ff('0x12'),_0x4683ff('0x41'),{'type':_0x501b65[_0x4683ff('0x42')]}),_0x5356d0['addColumn']('voice_recordings','transcribeStatus',{'type':_0x501b65[_0x4683ff('0x42')],'defaultValue':_0x4683ff('0x55')}),_0x5356d0['addColumn'](_0x4683ff('0x12'),'fileUri',{'type':_0x501b65[_0x4683ff('0x30')]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x12'),_0x4683ff('0x46'),{'type':_0x501b65[_0x4683ff('0x30')]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x12'),_0x4683ff('0x3c'),{'type':_0x501b65[_0x4683ff('0x30')]}),_0x5356d0[_0x4683ff('0x6')]('voice_recordings','sentiment',{'type':_0x501b65[_0x4683ff('0x42')]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x12'),'sPositive',{'type':_0x501b65['FLOAT']}),_0x5356d0['addColumn'](_0x4683ff('0x12'),_0x4683ff('0xe'),{'type':_0x501b65['FLOAT']}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x12'),_0x4683ff('0x36'),{'type':_0x501b65[_0x4683ff('0x1d')]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x12'),_0x4683ff('0x4'),{'type':_0x501b65['FLOAT']}),_0x5356d0[_0x4683ff('0x6')]('voice_recordings',_0x4683ff('0x2'),{'type':_0x501b65['BOOLEAN']}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x2b'),_0x4683ff('0x33'),{'type':_0x501b65[_0x4683ff('0x3d')]}),_0x5356d0['addColumn']('settings',_0x4683ff('0x2d'),{'type':_0x501b65['BOOLEAN']}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x2b'),'transcribeAccountId',{'type':_0x501b65[_0x4683ff('0x34')]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x2b'),_0x4683ff('0x35'),{'type':_0x501b65[_0x4683ff('0x42')]}),_0x5356d0['addColumn']('settings',_0x4683ff('0x4e'),{'type':_0x501b65['BOOLEAN']}),_0x5356d0[_0x4683ff('0x6')]('settings',_0x4683ff('0x23'),{'type':_0x501b65[_0x4683ff('0x3d')]}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x2b'),_0x4683ff('0x16'),{'type':_0x501b65[_0x4683ff('0x34')]}),_0x5356d0[_0x4683ff('0x6')]('settings',_0x4683ff('0x32'),{'type':_0x501b65['STRING']}),_0x5356d0[_0x4683ff('0x6')](_0x4683ff('0x2b'),_0x4683ff('0xa'),{'type':_0x501b65[_0x4683ff('0x42')]}),_0x5356d0['addColumn'](_0x4683ff('0x2b'),_0x4683ff('0xd'),{'type':_0x501b65['STRING']}),_0x5356d0[_0x4683ff('0x13')](_0xe712be);});},'down':function(){}}; \ No newline at end of file +const a1013_0x3c70=['transcribe','bucket','changeColumn','sNegative','users','util','language','\x20`description`\x20varchar(255)\x20DEFAULT\x20NULL,','query','TEXT','transcribeRegion','\x20PRIMARY\x20KEY\x20(`id`),','chat_interactions','fileUri',')\x20ENGINE=InnoDB\x20DEFAULT\x20CHARSET=utf8;','\x20`type`\x20enum(\x27twilio\x27)\x20DEFAULT\x20NULL,','migration','STRING','\x20`accountSid`\x20varchar(255)\x20DEFAULT\x20NULL,','\x20`ListId`\x20int(11)\x20DEFAULT\x20NULL,','sentimentRegion','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','fileText','stringify','voice_recordings','sequelize','finally','removeIndex','\x20`queueTransferTimeout`\x20int(11)\x20DEFAULT\x20\x27300\x27,','failureReason','\x20`mandatoryDisposition`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,','\x20`remote`\x20varchar(255)\x20NOT\x20NULL,','\x20KEY\x20`ListId`\x20(`ListId`),','\x20`createdAt`\x20datetime\x20NOT\x20NULL,','indicesType','addIndex\x20%s\x20%s\x20%s\x20[%s]','automaticTranscribe','WhatsappAccountId','query\x20%s','\x20`notificationShake`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,','ALTER\x20TABLE\x20tools_dispositions\x20ADD\x20CONSTRAINT\x20`name_whatsapp`\x20UNIQUE\x20KEY\x20(`name`,`WhatsappAccountId`)','tools_dispositions','tempSentiment','\x20`phone`\x20varchar(255)\x20DEFAULT\x20NULL,','tail','Added\x20column\x20%s\x20to\x20%s','\x20CONSTRAINT\x20`whatsapp_accounts_ibfk_1`\x20FOREIGN\x20KEY\x20(`mandatoryDispositionPauseId`)\x20REFERENCES\x20`tools_pauses`\x20(`id`)\x20ON\x20DELETE\x20NO\x20ACTION\x20ON\x20UPDATE\x20CASCADE,','then','NEW','catch','info','ALTER\x20TABLE\x20tools_dispositions\x20ADD\x20CONSTRAINT\x20`tools_dispositions_ibfk_7`\x20FOREIGN\x20KEY\x20(`WhatsappAccountId`)\x20REFERENCES\x20`whatsapp_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE','CREATE\x20TABLE\x20`whatsapp_accounts`\x20(','automaticSentiment','addColumn','dropTable','removeColumn','tools_canned_answers','inspect','../config/logger','\x20`id`\x20int(11)\x20NOT\x20NULL\x20AUTO_INCREMENT,','vidaooApiKey','transcribeName','queryInterface','\x20UNIQUE\x20KEY\x20`name`\x20(`name`),','sentimentAccountId','\x20`agentTransferTimeout`\x20int(11)\x20DEFAULT\x20\x27300\x27,','\x20`updatedAt`\x20datetime\x20NOT\x20NULL,','sentiment','prototype','vidaooEscalation','sPositive','whatsappPause','sequence','renameColumn','enqueue','INTEGER','vidaooSessionId','sNeutral','FLOAT','\x20`key`\x20varchar(255)\x20NOT\x20NULL,','\x20`agentTransfer`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,','settings','addIndex','BOOLEAN','UPDATE\x20users\x20SET\x20permissions=\x27101,102,103,113,110,104,105,106,107,108,109,100,111,114\x27\x20WHERE\x20role=\x27agent\x27\x20AND\x20permissions=\x27101,102,103,110,104,105,106,107,108,109,100,111\x27','final'];(function(_0x324499,_0x3c70fe){const _0x5d3d1d=function(_0x3db15c){while(--_0x3db15c){_0x324499['push'](_0x324499['shift']());}};_0x5d3d1d(++_0x3c70fe);}(a1013_0x3c70,0x87));const a1013_0x5d3d=function(_0x324499,_0x3c70fe){_0x324499=_0x324499-0x0;let _0x5d3d1d=a1013_0x3c70[_0x324499];return _0x5d3d1d;};const _0x3051b6=a1013_0x5d3d;'use strict';const util=require(_0x3051b6('0x2c')),logger=require(_0x3051b6('0xb'))(_0x3051b6('0x37')),Sequence=function(){};Sequence[_0x3051b6('0x15')]['enqueue']=function(_0x3db15c){const _0x1e1e29=_0x3051b6;this[_0x1e1e29('0x53')]=this[_0x1e1e29('0x53')]?this['tail'][_0x1e1e29('0x41')](_0x3db15c):_0x3db15c();};const Migration=function(_0x1524c1){const _0x197d76=_0x3051b6;this[_0x197d76('0xf')]=_0x1524c1,this[_0x197d76('0x19')]=new Sequence();};Migration[_0x3051b6('0x15')][_0x3051b6('0x29')]=function(_0xf7b460,_0x3e51a0,_0x293f13){const _0x4fb97f=_0x3051b6,_0x55e097=this;this['sequence'][_0x4fb97f('0x1b')](function(){const _0x5631f9=_0x4fb97f;return _0x55e097[_0x5631f9('0xf')][_0x5631f9('0x29')](_0xf7b460,_0x3e51a0,_0x293f13)[_0x5631f9('0x56')](function(){const _0x5f4c9d=_0x5631f9;logger[_0x5f4c9d('0x2')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x3e51a0,_0xf7b460);})[_0x5631f9('0x1')](function(_0x245c49){const _0x418015=_0x5631f9;logger[_0x418015('0x2')](JSON[_0x418015('0x3e')](_0x245c49));});});},Migration[_0x3051b6('0x15')][_0x3051b6('0x6')]=function(_0x5bba24,_0x922e3a,_0xeb8719){const _0x864416=_0x3051b6,_0x55ef6f=this;this[_0x864416('0x19')][_0x864416('0x1b')](function(){const _0xa1610=_0x864416;return _0x55ef6f[_0xa1610('0xf')][_0xa1610('0x6')](_0x5bba24,_0x922e3a,_0xeb8719)['then'](function(){const _0x481eed=_0xa1610;logger[_0x481eed('0x2')](_0x481eed('0x54'),_0x922e3a,_0x5bba24);})[_0xa1610('0x1')](function(_0x3aa060){const _0x3f409e=_0xa1610;logger['info'](JSON[_0x3f409e('0x3e')](_0x3aa060));});});},Migration[_0x3051b6('0x15')][_0x3051b6('0x7')]=function(_0x4a0d3a){const _0x2bb2a4=_0x3051b6,_0x1b5f5b=this;this['sequence'][_0x2bb2a4('0x1b')](function(){const _0x425c0b=_0x2bb2a4;return _0x1b5f5b['queryInterface']['dropTable'](_0x4a0d3a,{'force':!![]})[_0x425c0b('0x56')](function(){const _0x1fc34c=_0x425c0b;logger[_0x1fc34c('0x2')]('table\x20dropped\x20%s',_0x4a0d3a);})[_0x425c0b('0x1')](function(_0x39bf5d){const _0x28b273=_0x425c0b;logger[_0x28b273('0x2')](JSON[_0x28b273('0x3e')](_0x39bf5d));});});},Migration['prototype'][_0x3051b6('0x23')]=function(_0x168c7a,_0xb49679,_0x16f766){const _0x404c79=_0x3051b6,_0x3e3705=this;this[_0x404c79('0x19')][_0x404c79('0x1b')](function(){const _0x34ad6d=_0x404c79;return _0x3e3705[_0x34ad6d('0xf')][_0x34ad6d('0x23')](_0x168c7a,_0xb49679,{'indexName':_0x16f766['indexName'],'indicesType':_0x16f766[_0x34ad6d('0x49')]})['then'](function(){const _0xca31e2=_0x34ad6d;logger[_0xca31e2('0x2')](_0xca31e2('0x4a'),_0x168c7a,_0xb49679['join'](','),_0x16f766['indexName'],_0x16f766[_0xca31e2('0x49')]);})[_0x34ad6d('0x1')](function(_0x4a6450){const _0x10c648=_0x34ad6d;logger[_0x10c648('0x2')](JSON['stringify'](_0x4a6450));});});},Migration['prototype'][_0x3051b6('0x42')]=function(_0x379163,_0x329c0c){const _0x1e4304=_0x3051b6,_0x230e7b=this;this[_0x1e4304('0x19')][_0x1e4304('0x1b')](function(){const _0x64ea9a=_0x1e4304;return _0x230e7b[_0x64ea9a('0xf')]['removeIndex'](_0x379163,_0x329c0c)[_0x64ea9a('0x56')](function(){logger['info']('removeIndex\x20%s\x20%s',_0x379163,_0x329c0c);})['catch'](function(_0x2f0c54){const _0x2db1de=_0x64ea9a;logger[_0x2db1de('0x2')](JSON[_0x2db1de('0x3e')](_0x2f0c54));});});},Migration['prototype'][_0x3051b6('0x2f')]=function(_0x4fd239){const _0x4543fc=_0x3051b6,_0xd1598e=this;this[_0x4543fc('0x19')][_0x4543fc('0x1b')](function(){const _0x1bfeb1=_0x4543fc;return _0xd1598e[_0x1bfeb1('0xf')][_0x1bfeb1('0x40')][_0x1bfeb1('0x2f')](_0x4fd239)['then'](function(){const _0x5ae6de=_0x1bfeb1;logger[_0x5ae6de('0x2')](_0x5ae6de('0x4d'),_0x4fd239);})[_0x1bfeb1('0x1')](function(_0x57522a){const _0x3e6159=_0x1bfeb1;logger['info'](JSON[_0x3e6159('0x3e')](_0x57522a));});});},Migration[_0x3051b6('0x15')][_0x3051b6('0x8')]=function(_0x100bb5,_0x29694c){const _0xa95f63=this;this['sequence']['enqueue'](function(){const _0x5ab2d3=a1013_0x5d3d;return _0xa95f63[_0x5ab2d3('0xf')][_0x5ab2d3('0x8')](_0x100bb5,_0x29694c)['then'](function(){const _0x22334b=_0x5ab2d3;logger[_0x22334b('0x2')]('Removed\x20column\x20%s\x20from\x20%s',_0x29694c,_0x100bb5);})[_0x5ab2d3('0x1')](function(_0x2d6c14){const _0x5a0bdd=_0x5ab2d3;logger[_0x5a0bdd('0x2')](util[_0x5a0bdd('0xa')](_0x2d6c14,{'showHidden':![],'depth':null}));});});},Migration[_0x3051b6('0x15')][_0x3051b6('0x1a')]=function(_0x2a553d,_0x6b128d,_0x1cb698){const _0x7c2713=_0x3051b6,_0x1647a8=this;this[_0x7c2713('0x19')][_0x7c2713('0x1b')](function(){const _0x3bf969=_0x7c2713;return _0x1647a8[_0x3bf969('0xf')][_0x3bf969('0x1a')](_0x2a553d,_0x6b128d,_0x1cb698)['then'](function(){const _0x5807f9=_0x3bf969;logger[_0x5807f9('0x2')](_0x5807f9('0x3c'),_0x6b128d,_0x1cb698,_0x2a553d);})[_0x3bf969('0x1')](function(_0x5eedd8){const _0x5c18c2=_0x3bf969;logger[_0x5c18c2('0x2')](util[_0x5c18c2('0xa')](_0x5eedd8,{'showHidden':![],'depth':null}));});});},Migration[_0x3051b6('0x15')][_0x3051b6('0x26')]=function(_0x341e03){const _0x41cb8a=_0x3051b6;this['sequence'][_0x41cb8a('0x1b')](function(){return _0x341e03();});},module['exports']={'up':function(_0x3b9f4d,_0x2d5f85){return new Promise(function(_0x228e3d){const _0x3c1a18=a1013_0x5d3d,_0x2604b6=new Migration(_0x3b9f4d);_0x2604b6[_0x3c1a18('0x2f')](_0x3c1a18('0x4')+_0x3c1a18('0xc')+'\x20`name`\x20varchar(255)\x20NOT\x20NULL,'+_0x3c1a18('0x20')+_0x3c1a18('0x46')+'\x20`token`\x20varchar(255)\x20DEFAULT\x20NULL,'+_0x3c1a18('0x52')+_0x3c1a18('0x36')+_0x3c1a18('0x39')+'\x20`authToken`\x20varchar(255)\x20DEFAULT\x20NULL,'+'\x20`notificationTemplate`\x20text,'+'\x20`notificationSound`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,'+_0x3c1a18('0x4e')+'\x20`waitForTheAssignedAgent`\x20int(11)\x20DEFAULT\x20\x2710\x27,'+'\x20`queueTransfer`\x20tinyint(1)\x20DEFAULT\x20\x270\x27,'+_0x3c1a18('0x43')+_0x3c1a18('0x21')+_0x3c1a18('0x12')+'\x20`mandatoryDispositionPauseId`\x20int(11)\x20DEFAULT\x20NULL,'+_0x3c1a18('0x45')+_0x3c1a18('0x2e')+_0x3c1a18('0x48')+_0x3c1a18('0x13')+_0x3c1a18('0x3a')+_0x3c1a18('0x32')+_0x3c1a18('0x10')+'\x20KEY\x20`mandatoryDispositionPauseId`\x20(`mandatoryDispositionPauseId`),'+_0x3c1a18('0x47')+_0x3c1a18('0x55')+'\x20CONSTRAINT\x20`whatsapp_accounts_ibfk_2`\x20FOREIGN\x20KEY\x20(`ListId`)\x20REFERENCES\x20`cm_lists`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE'+_0x3c1a18('0x35')),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x50'),_0x3c1a18('0x4c'),{'type':_0x2d5f85[_0x3c1a18('0x1c')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x9'),'WhatsappAccountId',{'type':_0x2d5f85[_0x3c1a18('0x1c')]}),_0x2604b6[_0x3c1a18('0x6')]('users',_0x3c1a18('0x18'),{'type':_0x2d5f85['BOOLEAN'],'defaultValue':![]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x2b'),'whatsappCapacity',{'type':_0x2d5f85[_0x3c1a18('0x24')],'defaultValue':![]}),_0x2604b6[_0x3c1a18('0x2f')](_0x3c1a18('0x3')),_0x2604b6[_0x3c1a18('0x2f')](_0x3c1a18('0x4f')),_0x2604b6[_0x3c1a18('0x2f')]('ALTER\x20TABLE\x20tools_canned_answers\x20ADD\x20CONSTRAINT\x20`tools_canned_answers_ibfk_6`\x20FOREIGN\x20KEY\x20(`WhatsappAccountId`)\x20REFERENCES\x20`whatsapp_accounts`\x20(`id`)\x20ON\x20DELETE\x20SET\x20NULL\x20ON\x20UPDATE\x20CASCADE'),_0x2604b6[_0x3c1a18('0x2f')](_0x3c1a18('0x25')),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x33'),_0x3c1a18('0x1d'),{'type':_0x2d5f85[_0x3c1a18('0x30')]}),_0x2604b6['addColumn']('chat_websites',_0x3c1a18('0x16'),{'type':_0x2d5f85[_0x3c1a18('0x24')],'defaultValue':![]}),_0x2604b6[_0x3c1a18('0x6')]('chat_websites',_0x3c1a18('0xd'),{'type':_0x2d5f85[_0x3c1a18('0x38')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x3f'),'location',{'type':_0x2d5f85[_0x3c1a18('0x30')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x3f'),_0x3c1a18('0xe'),{'type':_0x2d5f85['STRING']}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x3f'),'transcribeStatus',{'type':_0x2d5f85[_0x3c1a18('0x38')],'defaultValue':_0x3c1a18('0x0')}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x3f'),_0x3c1a18('0x34'),{'type':_0x2d5f85[_0x3c1a18('0x30')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x3f'),_0x3c1a18('0x3d'),{'type':_0x2d5f85['TEXT']}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x3f'),_0x3c1a18('0x44'),{'type':_0x2d5f85['TEXT']}),_0x2604b6['addColumn'](_0x3c1a18('0x3f'),_0x3c1a18('0x14'),{'type':_0x2d5f85[_0x3c1a18('0x38')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x3f'),_0x3c1a18('0x17'),{'type':_0x2d5f85[_0x3c1a18('0x1f')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x3f'),_0x3c1a18('0x2a'),{'type':_0x2d5f85[_0x3c1a18('0x1f')]}),_0x2604b6['addColumn'](_0x3c1a18('0x3f'),_0x3c1a18('0x1e'),{'type':_0x2d5f85[_0x3c1a18('0x1f')]}),_0x2604b6['addColumn'](_0x3c1a18('0x3f'),'sMixed',{'type':_0x2d5f85[_0x3c1a18('0x1f')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x3f'),_0x3c1a18('0x51'),{'type':_0x2d5f85['BOOLEAN']}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x22'),_0x3c1a18('0x27'),{'type':_0x2d5f85[_0x3c1a18('0x24')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x22'),_0x3c1a18('0x4b'),{'type':_0x2d5f85[_0x3c1a18('0x24')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x22'),'transcribeAccountId',{'type':_0x2d5f85['INTEGER']}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x22'),_0x3c1a18('0x31'),{'type':_0x2d5f85[_0x3c1a18('0x38')]}),_0x2604b6[_0x3c1a18('0x6')](_0x3c1a18('0x22'),_0x3c1a18('0x14'),{'type':_0x2d5f85['BOOLEAN']}),_0x2604b6[_0x3c1a18('0x6')]('settings',_0x3c1a18('0x5'),{'type':_0x2d5f85[_0x3c1a18('0x24')]}),_0x2604b6[_0x3c1a18('0x6')]('settings',_0x3c1a18('0x11'),{'type':_0x2d5f85[_0x3c1a18('0x1c')]}),_0x2604b6[_0x3c1a18('0x6')]('settings',_0x3c1a18('0x3b'),{'type':_0x2d5f85['STRING']}),_0x2604b6[_0x3c1a18('0x6')]('settings',_0x3c1a18('0x2d'),{'type':_0x2d5f85[_0x3c1a18('0x38')]}),_0x2604b6['addColumn']('settings',_0x3c1a18('0x28'),{'type':_0x2d5f85[_0x3c1a18('0x38')]}),_0x2604b6[_0x3c1a18('0x26')](_0x228e3d);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.5.1.js b/server/migrations/2.5.1.js index e9740cd..e3c0806 100644 --- a/server/migrations/2.5.1.js +++ b/server/migrations/2.5.1.js @@ -1 +1 @@ -const a1014_0x55ee=['final','indexName','Changed\x20column\x20%s\x20in\x20table\x20%s','renameColumn','../config/logger','addIndex','util','removeIndex\x20%s\x20%s','table\x20dropped\x20%s','sequence','tail','catch','enqueue','dropTable','info','addColumn','stringify','then','indicesType','addIndex\x20%s\x20%s\x20%s\x20[%s]','join','finally','migration','sequelize','inspect','Removed\x20column\x20%s\x20from\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','query','removeColumn','prototype','changeColumn','exports','removeIndex','queryInterface'];(function(_0x138b80,_0x55ee7f){const _0x4867a7=function(_0x4a8fcc){while(--_0x4a8fcc){_0x138b80['push'](_0x138b80['shift']());}};_0x4867a7(++_0x55ee7f);}(a1014_0x55ee,0x131));const a1014_0x4867=function(_0x138b80,_0x55ee7f){_0x138b80=_0x138b80-0x0;let _0x4867a7=a1014_0x55ee[_0x138b80];return _0x4867a7;};const _0x1b0def=a1014_0x4867;'use strict';const util=require(_0x1b0def('0x7')),logger=require(_0x1b0def('0x5'))(_0x1b0def('0x17')),Sequence=function(){};Sequence['prototype'][_0x1b0def('0xd')]=function(_0x4a8fcc){const _0x1fa195=_0x1b0def;this[_0x1fa195('0xb')]=this['tail']?this[_0x1fa195('0xb')][_0x1fa195('0x16')](_0x4a8fcc):_0x4a8fcc();};const Migration=function(_0x3ffe2f){const _0xf5c1d0=_0x1b0def;this[_0xf5c1d0('0x0')]=_0x3ffe2f,this[_0xf5c1d0('0xa')]=new Sequence();};Migration[_0x1b0def('0x1e')][_0x1b0def('0x1f')]=function(_0x4128ff,_0x403618,_0x2a9415){const _0x3b60df=_0x1b0def,_0x2a3bfa=this;this[_0x3b60df('0xa')][_0x3b60df('0xd')](function(){const _0x5d042a=_0x3b60df;return _0x2a3bfa[_0x5d042a('0x0')][_0x5d042a('0x1f')](_0x4128ff,_0x403618,_0x2a9415)[_0x5d042a('0x12')](function(){const _0x58c6b8=_0x5d042a;logger[_0x58c6b8('0xf')](_0x58c6b8('0x3'),_0x403618,_0x4128ff);})[_0x5d042a('0xc')](function(_0x341cb0){const _0x5e733a=_0x5d042a;logger[_0x5e733a('0xf')](JSON[_0x5e733a('0x11')](_0x341cb0));});});},Migration[_0x1b0def('0x1e')][_0x1b0def('0x10')]=function(_0x135e31,_0x5e5af8,_0x590596){const _0x28184c=_0x1b0def,_0xa8b3e8=this;this[_0x28184c('0xa')][_0x28184c('0xd')](function(){const _0x462549=_0x28184c;return _0xa8b3e8[_0x462549('0x0')]['addColumn'](_0x135e31,_0x5e5af8,_0x590596)[_0x462549('0x12')](function(){const _0x343ceb=_0x462549;logger[_0x343ceb('0xf')]('Added\x20column\x20%s\x20to\x20%s',_0x5e5af8,_0x135e31);})['catch'](function(_0xd7260){const _0x1f1b60=_0x462549;logger['info'](JSON[_0x1f1b60('0x11')](_0xd7260));});});},Migration['prototype'][_0x1b0def('0xe')]=function(_0x2848d8){const _0x95b337=_0x1b0def,_0x48be0f=this;this[_0x95b337('0xa')][_0x95b337('0xd')](function(){const _0x2ed591=_0x95b337;return _0x48be0f[_0x2ed591('0x0')][_0x2ed591('0xe')](_0x2848d8,{'force':!![]})[_0x2ed591('0x12')](function(){const _0x159318=_0x2ed591;logger[_0x159318('0xf')](_0x159318('0x9'),_0x2848d8);})['catch'](function(_0x4457a2){const _0x14b49c=_0x2ed591;logger['info'](JSON[_0x14b49c('0x11')](_0x4457a2));});});},Migration[_0x1b0def('0x1e')]['addIndex']=function(_0x22773d,_0x4814da,_0x5bc739){const _0x589c11=_0x1b0def,_0x36e2f5=this;this[_0x589c11('0xa')][_0x589c11('0xd')](function(){const _0xe8092e=_0x589c11;return _0x36e2f5[_0xe8092e('0x0')][_0xe8092e('0x6')](_0x22773d,_0x4814da,{'indexName':_0x5bc739[_0xe8092e('0x2')],'indicesType':_0x5bc739['indicesType']})[_0xe8092e('0x12')](function(){const _0x5116c4=_0xe8092e;logger[_0x5116c4('0xf')](_0x5116c4('0x14'),_0x22773d,_0x4814da[_0x5116c4('0x15')](','),_0x5bc739[_0x5116c4('0x2')],_0x5bc739[_0x5116c4('0x13')]);})['catch'](function(_0x3826c6){const _0x2dc4fa=_0xe8092e;logger[_0x2dc4fa('0xf')](JSON['stringify'](_0x3826c6));});});},Migration[_0x1b0def('0x1e')][_0x1b0def('0x21')]=function(_0x52be5e,_0x1413ee){const _0x4415cc=_0x1b0def,_0x224c26=this;this[_0x4415cc('0xa')]['enqueue'](function(){const _0x36d364=_0x4415cc;return _0x224c26[_0x36d364('0x0')]['removeIndex'](_0x52be5e,_0x1413ee)['then'](function(){const _0x4355f2=_0x36d364;logger[_0x4355f2('0xf')](_0x4355f2('0x8'),_0x52be5e,_0x1413ee);})[_0x36d364('0xc')](function(_0x524817){const _0x354d7a=_0x36d364;logger[_0x354d7a('0xf')](JSON[_0x354d7a('0x11')](_0x524817));});});},Migration[_0x1b0def('0x1e')]['query']=function(_0x336d57){const _0x58fa14=_0x1b0def,_0x1bcdf0=this;this[_0x58fa14('0xa')][_0x58fa14('0xd')](function(){const _0xde1815=_0x58fa14;return _0x1bcdf0[_0xde1815('0x0')][_0xde1815('0x18')][_0xde1815('0x1c')](_0x336d57)[_0xde1815('0x12')](function(){const _0x183de0=_0xde1815;logger[_0x183de0('0xf')]('query\x20%s',_0x336d57);})[_0xde1815('0xc')](function(_0x151ff8){const _0x5eaa60=_0xde1815;logger[_0x5eaa60('0xf')](JSON[_0x5eaa60('0x11')](_0x151ff8));});});},Migration[_0x1b0def('0x1e')][_0x1b0def('0x1d')]=function(_0x597db1,_0x37aee3){const _0x11a4c3=_0x1b0def,_0x2b8eba=this;this[_0x11a4c3('0xa')][_0x11a4c3('0xd')](function(){const _0x30962f=_0x11a4c3;return _0x2b8eba['queryInterface'][_0x30962f('0x1d')](_0x597db1,_0x37aee3)['then'](function(){const _0x332d2f=_0x30962f;logger['info'](_0x332d2f('0x1a'),_0x37aee3,_0x597db1);})[_0x30962f('0xc')](function(_0x345cd2){const _0x3fcf52=_0x30962f;logger[_0x3fcf52('0xf')](util[_0x3fcf52('0x19')](_0x345cd2,{'showHidden':![],'depth':null}));});});},Migration[_0x1b0def('0x1e')][_0x1b0def('0x4')]=function(_0x280500,_0x9106e,_0x56c765){const _0x4c2648=_0x1b0def,_0x5b2301=this;this[_0x4c2648('0xa')][_0x4c2648('0xd')](function(){const _0x3562eb=_0x4c2648;return _0x5b2301['queryInterface'][_0x3562eb('0x4')](_0x280500,_0x9106e,_0x56c765)[_0x3562eb('0x12')](function(){const _0x5cf34c=_0x3562eb;logger['info'](_0x5cf34c('0x1b'),_0x9106e,_0x56c765,_0x280500);})[_0x3562eb('0xc')](function(_0x19f848){const _0x12334e=_0x3562eb;logger[_0x12334e('0xf')](util[_0x12334e('0x19')](_0x19f848,{'showHidden':![],'depth':null}));});});},Migration[_0x1b0def('0x1e')][_0x1b0def('0x1')]=function(_0x36ba9d){const _0x2d2f59=_0x1b0def;this[_0x2d2f59('0xa')][_0x2d2f59('0xd')](function(){return _0x36ba9d();});},module[_0x1b0def('0x20')]={'up':function(_0x1419df){return new Promise(function(_0x2e0fdb){const _0x23f487=a1014_0x4867,_0x34ef1d=new Migration(_0x1419df);_0x34ef1d[_0x23f487('0x1')](_0x2e0fdb);});},'down':function(){}}; \ No newline at end of file +const a1014_0x99fd=['inspect','removeColumn','removeIndex','dropTable','addIndex','addColumn','util','then','catch','tail','query\x20%s','enqueue','indexName','prototype','addIndex\x20%s\x20%s\x20%s\x20[%s]','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','final','Changed\x20column\x20%s\x20in\x20table\x20%s','queryInterface','removeIndex\x20%s\x20%s','sequelize','finally','sequence','query','Added\x20column\x20%s\x20to\x20%s','indicesType','exports','stringify','renameColumn','changeColumn','info'];(function(_0x578f5d,_0x99fdd5){const _0x4e2526=function(_0x3c4464){while(--_0x3c4464){_0x578f5d['push'](_0x578f5d['shift']());}};_0x4e2526(++_0x99fdd5);}(a1014_0x99fd,0xa3));const a1014_0x4e25=function(_0x578f5d,_0x99fdd5){_0x578f5d=_0x578f5d-0x0;let _0x4e2526=a1014_0x99fd[_0x578f5d];return _0x4e2526;};const _0x580c87=a1014_0x4e25;'use strict';const util=require(_0x580c87('0x1d')),logger=require('../config/logger')('migration'),Sequence=function(){};Sequence[_0x580c87('0x5')][_0x580c87('0x3')]=function(_0x3c4464){const _0x28a98f=_0x580c87;this[_0x28a98f('0x1')]=this[_0x28a98f('0x1')]?this[_0x28a98f('0x1')][_0x28a98f('0xd')](_0x3c4464):_0x3c4464();};const Migration=function(_0x716da4){const _0x5628bd=_0x580c87;this['queryInterface']=_0x716da4,this[_0x5628bd('0xe')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x3c6959,_0x46453a,_0x315ffb){const _0x4424e2=_0x580c87,_0x5d36cc=this;this[_0x4424e2('0xe')][_0x4424e2('0x3')](function(){const _0x5be21e=_0x4424e2;return _0x5d36cc[_0x5be21e('0xa')][_0x5be21e('0x15')](_0x3c6959,_0x46453a,_0x315ffb)[_0x5be21e('0x1e')](function(){const _0x39c506=_0x5be21e;logger[_0x39c506('0x16')](_0x39c506('0x9'),_0x46453a,_0x3c6959);})[_0x5be21e('0x0')](function(_0x1e36e2){const _0x5e9313=_0x5be21e;logger[_0x5e9313('0x16')](JSON['stringify'](_0x1e36e2));});});},Migration[_0x580c87('0x5')]['addColumn']=function(_0x2d16b2,_0x17a9c0,_0xfdfb8b){const _0x1b3cc2=_0x580c87,_0x128ced=this;this[_0x1b3cc2('0xe')]['enqueue'](function(){const _0x498c7b=_0x1b3cc2;return _0x128ced[_0x498c7b('0xa')][_0x498c7b('0x1c')](_0x2d16b2,_0x17a9c0,_0xfdfb8b)[_0x498c7b('0x1e')](function(){const _0x579cd6=_0x498c7b;logger['info'](_0x579cd6('0x10'),_0x17a9c0,_0x2d16b2);})[_0x498c7b('0x0')](function(_0x3e4a2b){const _0x447c28=_0x498c7b;logger['info'](JSON[_0x447c28('0x13')](_0x3e4a2b));});});},Migration['prototype'][_0x580c87('0x1a')]=function(_0x16c962){const _0x48a5e9=_0x580c87,_0x1da00b=this;this[_0x48a5e9('0xe')][_0x48a5e9('0x3')](function(){const _0x11f255=_0x48a5e9;return _0x1da00b[_0x11f255('0xa')][_0x11f255('0x1a')](_0x16c962,{'force':!![]})['then'](function(){logger['info']('table\x20dropped\x20%s',_0x16c962);})[_0x11f255('0x0')](function(_0x2ed858){const _0x556240=_0x11f255;logger[_0x556240('0x16')](JSON[_0x556240('0x13')](_0x2ed858));});});},Migration[_0x580c87('0x5')][_0x580c87('0x1b')]=function(_0x4a3fe4,_0x26cbc7,_0x350b11){const _0x31b260=_0x580c87,_0x1a4f1b=this;this[_0x31b260('0xe')][_0x31b260('0x3')](function(){const _0x1547ef=_0x31b260;return _0x1a4f1b[_0x1547ef('0xa')][_0x1547ef('0x1b')](_0x4a3fe4,_0x26cbc7,{'indexName':_0x350b11[_0x1547ef('0x4')],'indicesType':_0x350b11[_0x1547ef('0x11')]})[_0x1547ef('0x1e')](function(){const _0x51b857=_0x1547ef;logger[_0x51b857('0x16')](_0x51b857('0x6'),_0x4a3fe4,_0x26cbc7['join'](','),_0x350b11[_0x51b857('0x4')],_0x350b11[_0x51b857('0x11')]);})[_0x1547ef('0x0')](function(_0x1501ed){const _0x2314b6=_0x1547ef;logger[_0x2314b6('0x16')](JSON[_0x2314b6('0x13')](_0x1501ed));});});},Migration[_0x580c87('0x5')][_0x580c87('0x19')]=function(_0x5cb0e3,_0x21efcd){const _0x4df53a=_0x580c87,_0x3bae57=this;this[_0x4df53a('0xe')]['enqueue'](function(){const _0x37733b=_0x4df53a;return _0x3bae57[_0x37733b('0xa')]['removeIndex'](_0x5cb0e3,_0x21efcd)[_0x37733b('0x1e')](function(){const _0x181c03=_0x37733b;logger[_0x181c03('0x16')](_0x181c03('0xb'),_0x5cb0e3,_0x21efcd);})[_0x37733b('0x0')](function(_0x179e06){const _0x5df756=_0x37733b;logger[_0x5df756('0x16')](JSON['stringify'](_0x179e06));});});},Migration['prototype'][_0x580c87('0xf')]=function(_0x4081d6){const _0x5d4bea=_0x580c87,_0x2452e2=this;this[_0x5d4bea('0xe')][_0x5d4bea('0x3')](function(){const _0x3fb701=_0x5d4bea;return _0x2452e2[_0x3fb701('0xa')][_0x3fb701('0xc')][_0x3fb701('0xf')](_0x4081d6)[_0x3fb701('0x1e')](function(){const _0x47e7d8=_0x3fb701;logger['info'](_0x47e7d8('0x2'),_0x4081d6);})[_0x3fb701('0x0')](function(_0x442f37){const _0x4d7a1e=_0x3fb701;logger[_0x4d7a1e('0x16')](JSON[_0x4d7a1e('0x13')](_0x442f37));});});},Migration['prototype'][_0x580c87('0x18')]=function(_0x37143d,_0x3c7e04){const _0x489c49=_0x580c87,_0x1a1e35=this;this['sequence'][_0x489c49('0x3')](function(){const _0x4f07b4=_0x489c49;return _0x1a1e35[_0x4f07b4('0xa')][_0x4f07b4('0x18')](_0x37143d,_0x3c7e04)[_0x4f07b4('0x1e')](function(){const _0x43e33c=_0x4f07b4;logger[_0x43e33c('0x16')]('Removed\x20column\x20%s\x20from\x20%s',_0x3c7e04,_0x37143d);})[_0x4f07b4('0x0')](function(_0x47d61d){const _0x2e22a4=_0x4f07b4;logger['info'](util[_0x2e22a4('0x17')](_0x47d61d,{'showHidden':![],'depth':null}));});});},Migration[_0x580c87('0x5')][_0x580c87('0x14')]=function(_0x26c8ef,_0x581d3a,_0x4e4390){const _0xa97d65=_0x580c87,_0x1b8271=this;this[_0xa97d65('0xe')]['enqueue'](function(){const _0x509f28=_0xa97d65;return _0x1b8271[_0x509f28('0xa')][_0x509f28('0x14')](_0x26c8ef,_0x581d3a,_0x4e4390)[_0x509f28('0x1e')](function(){const _0x8f9b49=_0x509f28;logger[_0x8f9b49('0x16')](_0x8f9b49('0x7'),_0x581d3a,_0x4e4390,_0x26c8ef);})[_0x509f28('0x0')](function(_0x2a27bb){const _0x3d294b=_0x509f28;logger['info'](util[_0x3d294b('0x17')](_0x2a27bb,{'showHidden':![],'depth':null}));});});},Migration[_0x580c87('0x5')]['final']=function(_0x3ed8b7){const _0x1d7c89=_0x580c87;this[_0x1d7c89('0xe')][_0x1d7c89('0x3')](function(){return _0x3ed8b7();});},module[_0x580c87('0x12')]={'up':function(_0x159c7e){return new Promise(function(_0x4b3a16){const _0x4f837f=a1014_0x4e25,_0x54a321=new Migration(_0x159c7e);_0x54a321[_0x4f837f('0x8')](_0x4b3a16);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.5.2.js b/server/migrations/2.5.2.js index 53626b3..0d9ede8 100644 --- a/server/migrations/2.5.2.js +++ b/server/migrations/2.5.2.js @@ -1 +1 @@ -const a1015_0x18d8=['exports','final','voice_queues','info','dialAgentRejectRetryFrequency','indexName','catch','tail','cm_hopper_history','countdropretry','cm_hopper','query\x20%s','then','changeColumn','../config/logger','addColumn','cm_hopper_final','renameColumn','removeColumn','addIndex\x20%s\x20%s\x20%s\x20[%s]','ALTER\x20TABLE\x20cloud_providers\x20ENCRYPTION=\x27Y\x27;','indicesType','queryInterface','countnosuchnumberretry','dialAbandonedMaxRetry','dialMachineRetryFrequency','addIndex','table\x20dropped\x20%s','Added\x20column\x20%s\x20to\x20%s','dialDropRetryFrequency','dialNoSuchNumberMaxRetry','ALTER\x20TABLE\x20whatsapp_messages\x20ENCRYPTION=\x27Y\x27;','countabandonedretry','countagentrejectretry','removeIndex','INTEGER','dialMachineMaxRetry','dialDropMaxRetry','dialAgentRejectMaxRetry','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','stringify','enqueue','countmachineretry','inspect','prototype','dropTable','ALTER\x20TABLE\x20report_whatsapp_queue\x20ENCRYPTION=\x27Y\x27;','query','ALTER\x20TABLE\x20voice_extensions\x20DROP\x20FOREIGN\x20KEY\x20voice_extensions_ibfk_7','sequence','campaigns','dialNoSuchNumberRetryFrequency'];(function(_0x530844,_0x18d862){const _0x32925d=function(_0xb4550){while(--_0xb4550){_0x530844['push'](_0x530844['shift']());}};_0x32925d(++_0x18d862);}(a1015_0x18d8,0x65));const a1015_0x3292=function(_0x530844,_0x18d862){_0x530844=_0x530844-0x0;let _0x32925d=a1015_0x18d8[_0x530844];return _0x32925d;};const _0xafe427=a1015_0x3292;'use strict';const util=require('util'),logger=require(_0xafe427('0x11'))('migration'),Sequence=function(){};Sequence['prototype'][_0xafe427('0x2c')]=function(_0xb4550){const _0x30e620=_0xafe427;this['tail']=this[_0x30e620('0xa')]?this[_0x30e620('0xa')]['finally'](_0xb4550):_0xb4550();};const Migration=function(_0x50eab7){const _0x50b7d6=_0xafe427;this[_0x50b7d6('0x19')]=_0x50eab7,this['sequence']=new Sequence();};Migration['prototype'][_0xafe427('0x10')]=function(_0x33a790,_0x4b48f1,_0x55b1d3){const _0x330854=_0xafe427,_0x59811f=this;this[_0x330854('0x0')][_0x330854('0x2c')](function(){const _0x2c7ee0=_0x330854;return _0x59811f[_0x2c7ee0('0x19')][_0x2c7ee0('0x10')](_0x33a790,_0x4b48f1,_0x55b1d3)[_0x2c7ee0('0xf')](function(){logger['info']('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x4b48f1,_0x33a790);})[_0x2c7ee0('0x9')](function(_0x49c6a2){const _0x1e8185=_0x2c7ee0;logger[_0x1e8185('0x6')](JSON['stringify'](_0x49c6a2));});});},Migration[_0xafe427('0x2f')]['addColumn']=function(_0x565aae,_0x3a03f3,_0x32697e){const _0x416389=_0xafe427,_0x4198d1=this;this[_0x416389('0x0')][_0x416389('0x2c')](function(){const _0x540d10=_0x416389;return _0x4198d1[_0x540d10('0x19')][_0x540d10('0x12')](_0x565aae,_0x3a03f3,_0x32697e)[_0x540d10('0xf')](function(){const _0x2d3a42=_0x540d10;logger[_0x2d3a42('0x6')](_0x2d3a42('0x1f'),_0x3a03f3,_0x565aae);})[_0x540d10('0x9')](function(_0x447061){const _0x1a146c=_0x540d10;logger['info'](JSON[_0x1a146c('0x2b')](_0x447061));});});},Migration[_0xafe427('0x2f')][_0xafe427('0x30')]=function(_0x37e425){const _0x14a752=this;this['sequence']['enqueue'](function(){const _0x41a382=a1015_0x3292;return _0x14a752[_0x41a382('0x19')][_0x41a382('0x30')](_0x37e425,{'force':!![]})['then'](function(){const _0x356998=_0x41a382;logger[_0x356998('0x6')](_0x356998('0x1e'),_0x37e425);})[_0x41a382('0x9')](function(_0x1b91c8){const _0x4e0f61=_0x41a382;logger[_0x4e0f61('0x6')](JSON[_0x4e0f61('0x2b')](_0x1b91c8));});});},Migration[_0xafe427('0x2f')][_0xafe427('0x1d')]=function(_0x4909c6,_0x104991,_0x545083){const _0x42fdd2=_0xafe427,_0x4805e2=this;this[_0x42fdd2('0x0')][_0x42fdd2('0x2c')](function(){const _0x1b42a4=_0x42fdd2;return _0x4805e2['queryInterface'][_0x1b42a4('0x1d')](_0x4909c6,_0x104991,{'indexName':_0x545083[_0x1b42a4('0x8')],'indicesType':_0x545083[_0x1b42a4('0x18')]})[_0x1b42a4('0xf')](function(){const _0x295b0a=_0x1b42a4;logger[_0x295b0a('0x6')](_0x295b0a('0x16'),_0x4909c6,_0x104991['join'](','),_0x545083[_0x295b0a('0x8')],_0x545083[_0x295b0a('0x18')]);})[_0x1b42a4('0x9')](function(_0x4b5f36){const _0x1176cd=_0x1b42a4;logger[_0x1176cd('0x6')](JSON['stringify'](_0x4b5f36));});});},Migration['prototype'][_0xafe427('0x25')]=function(_0x3f29b,_0x275fff){const _0x2634e8=_0xafe427,_0x220fb3=this;this[_0x2634e8('0x0')][_0x2634e8('0x2c')](function(){const _0x451a82=_0x2634e8;return _0x220fb3[_0x451a82('0x19')][_0x451a82('0x25')](_0x3f29b,_0x275fff)[_0x451a82('0xf')](function(){logger['info']('removeIndex\x20%s\x20%s',_0x3f29b,_0x275fff);})[_0x451a82('0x9')](function(_0x53064b){const _0x461b7a=_0x451a82;logger['info'](JSON[_0x461b7a('0x2b')](_0x53064b));});});},Migration['prototype'][_0xafe427('0x32')]=function(_0x2a8112){const _0x448d99=_0xafe427,_0x9f014f=this;this[_0x448d99('0x0')]['enqueue'](function(){const _0xd93e53=_0x448d99;return _0x9f014f[_0xd93e53('0x19')]['sequelize'][_0xd93e53('0x32')](_0x2a8112)[_0xd93e53('0xf')](function(){const _0x1c24ba=_0xd93e53;logger['info'](_0x1c24ba('0xe'),_0x2a8112);})[_0xd93e53('0x9')](function(_0x2a2685){const _0x440013=_0xd93e53;logger[_0x440013('0x6')](JSON[_0x440013('0x2b')](_0x2a2685));});});},Migration[_0xafe427('0x2f')][_0xafe427('0x15')]=function(_0x27bff8,_0x2afc9b){const _0x8034db=_0xafe427,_0x42219a=this;this[_0x8034db('0x0')][_0x8034db('0x2c')](function(){const _0x4db492=_0x8034db;return _0x42219a['queryInterface'][_0x4db492('0x15')](_0x27bff8,_0x2afc9b)['then'](function(){logger['info']('Removed\x20column\x20%s\x20from\x20%s',_0x2afc9b,_0x27bff8);})[_0x4db492('0x9')](function(_0x28e87e){const _0x4697b8=_0x4db492;logger['info'](util[_0x4697b8('0x2e')](_0x28e87e,{'showHidden':![],'depth':null}));});});},Migration[_0xafe427('0x2f')]['renameColumn']=function(_0x212cb8,_0x4e7ca4,_0x274c4d){const _0x4f0577=_0xafe427,_0x1d0521=this;this[_0x4f0577('0x0')]['enqueue'](function(){const _0x2d5c67=_0x4f0577;return _0x1d0521['queryInterface'][_0x2d5c67('0x14')](_0x212cb8,_0x4e7ca4,_0x274c4d)['then'](function(){const _0x351fd4=_0x2d5c67;logger[_0x351fd4('0x6')](_0x351fd4('0x2a'),_0x4e7ca4,_0x274c4d,_0x212cb8);})['catch'](function(_0x232c3d){const _0x1a604f=_0x2d5c67;logger[_0x1a604f('0x6')](util[_0x1a604f('0x2e')](_0x232c3d,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0xafe427('0x4')]=function(_0x5525c2){const _0x50779f=_0xafe427;this[_0x50779f('0x0')][_0x50779f('0x2c')](function(){return _0x5525c2();});},module[_0xafe427('0x3')]={'up':function(_0x13a46f,_0x102007){return new Promise(function(_0xf9f432){const _0x593466=a1015_0x3292,_0x4007a2=new Migration(_0x13a46f);_0x4007a2[_0x593466('0x32')]('ALTER\x20TABLE\x20whatsapp_accounts\x20ENCRYPTION=\x27Y\x27;'),_0x4007a2[_0x593466('0x32')]('ALTER\x20TABLE\x20whatsapp_interactions\x20ENCRYPTION=\x27Y\x27;'),_0x4007a2[_0x593466('0x32')](_0x593466('0x22')),_0x4007a2['query'](_0x593466('0x31')),_0x4007a2[_0x593466('0x32')](_0x593466('0x17')),_0x4007a2['query'](_0x593466('0x33')),_0x4007a2[_0x593466('0x32')]('ALTER\x20TABLE\x20voice_extensions\x20DROP\x20INDEX\x20voice_extensions_ibfk_7'),_0x4007a2[_0x593466('0x32')]('ALTER\x20TABLE\x20voice_extensions\x20ADD\x20CONSTRAINT\x20voice_extensions_ibfk_7\x20FOREIGN\x20KEY\x20(VoicePrefixId)\x20REFERENCES\x20voice_prefixes(id)\x20ON\x20UPDATE\x20CASCADE\x20ON\x20DELETE\x20CASCADE'),_0x4007a2[_0x593466('0x12')]('voice_queues',_0x593466('0x21'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2[_0x593466('0x12')]('voice_queues',_0x593466('0x2'),{'type':_0x102007['INTEGER'],'defaultValue':0x96}),_0x4007a2[_0x593466('0x12')](_0x593466('0x5'),_0x593466('0x28'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2['addColumn'](_0x593466('0x5'),_0x593466('0x20'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x96}),_0x4007a2[_0x593466('0x12')](_0x593466('0x5'),_0x593466('0x1b'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2['addColumn'](_0x593466('0x5'),'dialAbandonedRetryFrequency',{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x96}),_0x4007a2['addColumn']('voice_queues','dialMachineMaxRetry',{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2['addColumn'](_0x593466('0x5'),_0x593466('0x1c'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x96}),_0x4007a2[_0x593466('0x12')](_0x593466('0x5'),_0x593466('0x29'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2[_0x593466('0x12')]('voice_queues',_0x593466('0x7'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x96}),_0x4007a2[_0x593466('0x12')](_0x593466('0x1'),'dialNoSuchNumberMaxRetry',{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2['addColumn'](_0x593466('0x1'),'dialNoSuchNumberRetryFrequency',{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x96}),_0x4007a2[_0x593466('0x12')](_0x593466('0x1'),_0x593466('0x28'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2[_0x593466('0x12')](_0x593466('0x1'),'dialDropRetryFrequency',{'type':_0x102007['INTEGER'],'defaultValue':0x96}),_0x4007a2[_0x593466('0x12')](_0x593466('0x1'),_0x593466('0x1b'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2[_0x593466('0x12')]('campaigns','dialAbandonedRetryFrequency',{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x96}),_0x4007a2[_0x593466('0x12')](_0x593466('0x1'),_0x593466('0x27'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2['addColumn'](_0x593466('0x1'),_0x593466('0x1c'),{'type':_0x102007['INTEGER'],'defaultValue':0x96}),_0x4007a2[_0x593466('0x12')](_0x593466('0x1'),'dialAgentRejectMaxRetry',{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x3}),_0x4007a2[_0x593466('0x12')]('campaigns',_0x593466('0x7'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x96}),_0x4007a2[_0x593466('0x12')](_0x593466('0xd'),'countnosuchnumberretry',{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2['addColumn']('cm_hopper',_0x593466('0xc'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2[_0x593466('0x12')](_0x593466('0xd'),'countabandonedretry',{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2['addColumn'](_0x593466('0xd'),_0x593466('0x2d'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2[_0x593466('0x12')]('cm_hopper',_0x593466('0x24'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2['addColumn']('cm_hopper_final',_0x593466('0x1a'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2[_0x593466('0x12')]('cm_hopper_final',_0x593466('0xc'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2['addColumn']('cm_hopper_final',_0x593466('0x23'),{'type':_0x102007['INTEGER'],'defaultValue':0x0}),_0x4007a2['addColumn'](_0x593466('0x13'),_0x593466('0x2d'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2['addColumn'](_0x593466('0x13'),'countagentrejectretry',{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2[_0x593466('0x12')]('cm_hopper_history',_0x593466('0x1a'),{'type':_0x102007['INTEGER'],'defaultValue':0x0}),_0x4007a2['addColumn'](_0x593466('0xb'),_0x593466('0xc'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2[_0x593466('0x12')]('cm_hopper_history',_0x593466('0x23'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2[_0x593466('0x12')](_0x593466('0xb'),_0x593466('0x2d'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2[_0x593466('0x12')]('cm_hopper_history',_0x593466('0x24'),{'type':_0x102007[_0x593466('0x26')],'defaultValue':0x0}),_0x4007a2[_0x593466('0x4')](_0xf9f432);});},'down':function(){}}; \ No newline at end of file +const a1015_0x3b0e=['countagentrejectretry','dialDropRetryFrequency','query','info','finally','countnosuchnumberretry','dialAbandonedRetryFrequency','join','addIndex','dialDropMaxRetry','dialAgentRejectMaxRetry','addIndex\x20%s\x20%s\x20%s\x20[%s]','exports','removeIndex\x20%s\x20%s','Removed\x20column\x20%s\x20from\x20%s','voice_queues','dropTable','countabandonedretry','then','dialAbandonedMaxRetry','stringify','ALTER\x20TABLE\x20cloud_providers\x20ENCRYPTION=\x27Y\x27;','ALTER\x20TABLE\x20report_whatsapp_queue\x20ENCRYPTION=\x27Y\x27;','campaigns','countmachineretry','cm_hopper_history','Changed\x20column\x20%s\x20in\x20table\x20%s','table\x20dropped\x20%s','sequelize','changeColumn','indexName','dialMachineMaxRetry','dialNoSuchNumberRetryFrequency','cm_hopper','INTEGER','enqueue','countdropretry','addColumn','catch','dialNoSuchNumberMaxRetry','migration','tail','queryInterface','ALTER\x20TABLE\x20voice_extensions\x20DROP\x20FOREIGN\x20KEY\x20voice_extensions_ibfk_7','cm_hopper_final','final','prototype','util','ALTER\x20TABLE\x20whatsapp_messages\x20ENCRYPTION=\x27Y\x27;','removeColumn','Added\x20column\x20%s\x20to\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','ALTER\x20TABLE\x20voice_extensions\x20ADD\x20CONSTRAINT\x20voice_extensions_ibfk_7\x20FOREIGN\x20KEY\x20(VoicePrefixId)\x20REFERENCES\x20voice_prefixes(id)\x20ON\x20UPDATE\x20CASCADE\x20ON\x20DELETE\x20CASCADE','indicesType','dialAgentRejectRetryFrequency','sequence','ALTER\x20TABLE\x20voice_extensions\x20DROP\x20INDEX\x20voice_extensions_ibfk_7','ALTER\x20TABLE\x20whatsapp_accounts\x20ENCRYPTION=\x27Y\x27;','dialMachineRetryFrequency'];(function(_0x5a6e0f,_0x3b0e62){const _0x2547b0=function(_0x4e1dba){while(--_0x4e1dba){_0x5a6e0f['push'](_0x5a6e0f['shift']());}};_0x2547b0(++_0x3b0e62);}(a1015_0x3b0e,0xd6));const a1015_0x2547=function(_0x5a6e0f,_0x3b0e62){_0x5a6e0f=_0x5a6e0f-0x0;let _0x2547b0=a1015_0x3b0e[_0x5a6e0f];return _0x2547b0;};const _0x14aa2e=a1015_0x2547;'use strict';const util=require(_0x14aa2e('0xa')),logger=require('../config/logger')(_0x14aa2e('0x3')),Sequence=function(){};Sequence[_0x14aa2e('0x9')][_0x14aa2e('0x39')]=function(_0x4e1dba){const _0x30c2d6=_0x14aa2e;this[_0x30c2d6('0x4')]=this[_0x30c2d6('0x4')]?this[_0x30c2d6('0x4')][_0x30c2d6('0x1a')](_0x4e1dba):_0x4e1dba();};const Migration=function(_0x451cbc){this['queryInterface']=_0x451cbc,this['sequence']=new Sequence();};Migration[_0x14aa2e('0x9')]['changeColumn']=function(_0x5ca9ad,_0x2cf5c,_0x594ed5){const _0xaff530=this;this['sequence']['enqueue'](function(){const _0x227b50=a1015_0x2547;return _0xaff530[_0x227b50('0x5')][_0x227b50('0x33')](_0x5ca9ad,_0x2cf5c,_0x594ed5)[_0x227b50('0x28')](function(){const _0x52b239=_0x227b50;logger['info'](_0x52b239('0x30'),_0x2cf5c,_0x5ca9ad);})[_0x227b50('0x1')](function(_0x3b10f2){const _0xbd3a22=_0x227b50;logger[_0xbd3a22('0x19')](JSON[_0xbd3a22('0x2a')](_0x3b10f2));});});},Migration[_0x14aa2e('0x9')]['addColumn']=function(_0x1be8cd,_0x4feeeb,_0x3e23c5){const _0xce75c2=_0x14aa2e,_0x4211cb=this;this[_0xce75c2('0x12')]['enqueue'](function(){const _0x5b9129=_0xce75c2;return _0x4211cb[_0x5b9129('0x5')][_0x5b9129('0x0')](_0x1be8cd,_0x4feeeb,_0x3e23c5)['then'](function(){const _0x157ca7=_0x5b9129;logger[_0x157ca7('0x19')](_0x157ca7('0xd'),_0x4feeeb,_0x1be8cd);})[_0x5b9129('0x1')](function(_0x3b7d42){const _0x428d4f=_0x5b9129;logger[_0x428d4f('0x19')](JSON[_0x428d4f('0x2a')](_0x3b7d42));});});},Migration['prototype']['dropTable']=function(_0x3f451c){const _0x1393c5=_0x14aa2e,_0x5068b5=this;this[_0x1393c5('0x12')][_0x1393c5('0x39')](function(){const _0x19c393=_0x1393c5;return _0x5068b5[_0x19c393('0x5')][_0x19c393('0x26')](_0x3f451c,{'force':!![]})[_0x19c393('0x28')](function(){const _0x1bd226=_0x19c393;logger[_0x1bd226('0x19')](_0x1bd226('0x31'),_0x3f451c);})['catch'](function(_0x142e76){logger['info'](JSON['stringify'](_0x142e76));});});},Migration[_0x14aa2e('0x9')]['addIndex']=function(_0x24114a,_0x2ac358,_0x14dfba){const _0x11e7d6=_0x14aa2e,_0x14ef39=this;this[_0x11e7d6('0x12')][_0x11e7d6('0x39')](function(){const _0x37b9b9=_0x11e7d6;return _0x14ef39[_0x37b9b9('0x5')][_0x37b9b9('0x1e')](_0x24114a,_0x2ac358,{'indexName':_0x14dfba[_0x37b9b9('0x34')],'indicesType':_0x14dfba['indicesType']})['then'](function(){const _0x19dd07=_0x37b9b9;logger['info'](_0x19dd07('0x21'),_0x24114a,_0x2ac358[_0x19dd07('0x1d')](','),_0x14dfba['indexName'],_0x14dfba[_0x19dd07('0x10')]);})[_0x37b9b9('0x1')](function(_0x22f4ad){const _0x397959=_0x37b9b9;logger[_0x397959('0x19')](JSON['stringify'](_0x22f4ad));});});},Migration[_0x14aa2e('0x9')]['removeIndex']=function(_0x547675,_0x3719c7){const _0x314ce2=_0x14aa2e,_0x2a03d7=this;this['sequence'][_0x314ce2('0x39')](function(){const _0x5a6068=_0x314ce2;return _0x2a03d7[_0x5a6068('0x5')]['removeIndex'](_0x547675,_0x3719c7)[_0x5a6068('0x28')](function(){const _0x38c5c0=_0x5a6068;logger[_0x38c5c0('0x19')](_0x38c5c0('0x23'),_0x547675,_0x3719c7);})[_0x5a6068('0x1')](function(_0x3c9a22){logger['info'](JSON['stringify'](_0x3c9a22));});});},Migration[_0x14aa2e('0x9')][_0x14aa2e('0x18')]=function(_0x5bd574){const _0x104c9f=_0x14aa2e,_0x587342=this;this[_0x104c9f('0x12')]['enqueue'](function(){const _0x59868f=_0x104c9f;return _0x587342[_0x59868f('0x5')][_0x59868f('0x32')]['query'](_0x5bd574)[_0x59868f('0x28')](function(){logger['info']('query\x20%s',_0x5bd574);})[_0x59868f('0x1')](function(_0x1f109d){const _0xff0d2e=_0x59868f;logger[_0xff0d2e('0x19')](JSON[_0xff0d2e('0x2a')](_0x1f109d));});});},Migration[_0x14aa2e('0x9')][_0x14aa2e('0xc')]=function(_0x5d38db,_0x4457b4){const _0x3b56d1=_0x14aa2e,_0x30e1f5=this;this[_0x3b56d1('0x12')]['enqueue'](function(){const _0x47fbfa=_0x3b56d1;return _0x30e1f5[_0x47fbfa('0x5')][_0x47fbfa('0xc')](_0x5d38db,_0x4457b4)[_0x47fbfa('0x28')](function(){const _0x59f40b=_0x47fbfa;logger[_0x59f40b('0x19')](_0x59f40b('0x24'),_0x4457b4,_0x5d38db);})[_0x47fbfa('0x1')](function(_0x483f81){logger['info'](util['inspect'](_0x483f81,{'showHidden':![],'depth':null}));});});},Migration[_0x14aa2e('0x9')]['renameColumn']=function(_0x1d7493,_0x255323,_0x1abc99){const _0xee6f43=_0x14aa2e,_0x41cb5f=this;this[_0xee6f43('0x12')]['enqueue'](function(){const _0x1ce1f5=_0xee6f43;return _0x41cb5f[_0x1ce1f5('0x5')]['renameColumn'](_0x1d7493,_0x255323,_0x1abc99)[_0x1ce1f5('0x28')](function(){const _0x2c8eb5=_0x1ce1f5;logger['info'](_0x2c8eb5('0xe'),_0x255323,_0x1abc99,_0x1d7493);})[_0x1ce1f5('0x1')](function(_0xa01bc4){const _0x57f867=_0x1ce1f5;logger[_0x57f867('0x19')](util['inspect'](_0xa01bc4,{'showHidden':![],'depth':null}));});});},Migration[_0x14aa2e('0x9')][_0x14aa2e('0x8')]=function(_0x1c0a73){const _0x480719=_0x14aa2e;this[_0x480719('0x12')][_0x480719('0x39')](function(){return _0x1c0a73();});},module[_0x14aa2e('0x22')]={'up':function(_0xbfb7d9,_0x29c2ed){return new Promise(function(_0xfec7eb){const _0x383948=a1015_0x2547,_0x23cf63=new Migration(_0xbfb7d9);_0x23cf63[_0x383948('0x18')](_0x383948('0x14')),_0x23cf63[_0x383948('0x18')]('ALTER\x20TABLE\x20whatsapp_interactions\x20ENCRYPTION=\x27Y\x27;'),_0x23cf63[_0x383948('0x18')](_0x383948('0xb')),_0x23cf63[_0x383948('0x18')](_0x383948('0x2c')),_0x23cf63[_0x383948('0x18')](_0x383948('0x2b')),_0x23cf63[_0x383948('0x18')](_0x383948('0x6')),_0x23cf63[_0x383948('0x18')](_0x383948('0x13')),_0x23cf63['query'](_0x383948('0xf')),_0x23cf63[_0x383948('0x0')]('voice_queues',_0x383948('0x2'),{'type':_0x29c2ed['INTEGER'],'defaultValue':0x3}),_0x23cf63[_0x383948('0x0')](_0x383948('0x25'),_0x383948('0x36'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x96}),_0x23cf63[_0x383948('0x0')]('voice_queues',_0x383948('0x1f'),{'type':_0x29c2ed['INTEGER'],'defaultValue':0x3}),_0x23cf63['addColumn'](_0x383948('0x25'),_0x383948('0x17'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x96}),_0x23cf63[_0x383948('0x0')](_0x383948('0x25'),_0x383948('0x29'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x3}),_0x23cf63['addColumn'](_0x383948('0x25'),_0x383948('0x1c'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x96}),_0x23cf63[_0x383948('0x0')](_0x383948('0x25'),_0x383948('0x35'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x3}),_0x23cf63[_0x383948('0x0')](_0x383948('0x25'),_0x383948('0x15'),{'type':_0x29c2ed['INTEGER'],'defaultValue':0x96}),_0x23cf63[_0x383948('0x0')](_0x383948('0x25'),'dialAgentRejectMaxRetry',{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x3}),_0x23cf63[_0x383948('0x0')](_0x383948('0x25'),_0x383948('0x11'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x96}),_0x23cf63['addColumn'](_0x383948('0x2d'),_0x383948('0x2'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x3}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2d'),'dialNoSuchNumberRetryFrequency',{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x96}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2d'),_0x383948('0x1f'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x3}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2d'),_0x383948('0x17'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x96}),_0x23cf63['addColumn']('campaigns',_0x383948('0x29'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x3}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2d'),_0x383948('0x1c'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x96}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2d'),_0x383948('0x35'),{'type':_0x29c2ed['INTEGER'],'defaultValue':0x3}),_0x23cf63[_0x383948('0x0')]('campaigns',_0x383948('0x15'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x96}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2d'),_0x383948('0x20'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x3}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2d'),_0x383948('0x11'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x96}),_0x23cf63[_0x383948('0x0')]('cm_hopper',_0x383948('0x1b'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x37'),'countdropretry',{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x37'),_0x383948('0x27'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')]('cm_hopper',_0x383948('0x2e'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x37'),_0x383948('0x16'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x7'),_0x383948('0x1b'),{'type':_0x29c2ed['INTEGER'],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x7'),_0x383948('0x3a'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x7'),_0x383948('0x27'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x7'),_0x383948('0x2e'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x7'),_0x383948('0x16'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')]('cm_hopper_history',_0x383948('0x1b'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63['addColumn'](_0x383948('0x2f'),_0x383948('0x3a'),{'type':_0x29c2ed['INTEGER'],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2f'),_0x383948('0x27'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2f'),'countmachineretry',{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63[_0x383948('0x0')](_0x383948('0x2f'),_0x383948('0x16'),{'type':_0x29c2ed[_0x383948('0x38')],'defaultValue':0x0}),_0x23cf63['final'](_0xfec7eb);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.5.3.js b/server/migrations/2.5.3.js index 9c78ca9..daf925f 100644 --- a/server/migrations/2.5.3.js +++ b/server/migrations/2.5.3.js @@ -1 +1 @@ -const a1016_0x30ec=['sequence','query\x20%s','util','queryInterface','dropTable','addColumn','renameColumn','prototype','stringify','removeColumn','finally','addIndex\x20%s\x20%s\x20%s\x20[%s]','removeIndex','query','Changed\x20column\x20%s\x20in\x20table\x20%s','STRING','migration','changeColumn','then','tail','join','enqueue','#011F6A','chat_websites','inspect','indexName','catch','indicesType','final','addIndex','info','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s'];(function(_0x484844,_0x30ec7b){const _0x565736=function(_0x20f528){while(--_0x20f528){_0x484844['push'](_0x484844['shift']());}};_0x565736(++_0x30ec7b);}(a1016_0x30ec,0x123));const a1016_0x5657=function(_0x484844,_0x30ec7b){_0x484844=_0x484844-0x0;let _0x565736=a1016_0x30ec[_0x484844];return _0x565736;};const _0x191f68=a1016_0x5657;'use strict';const util=require(_0x191f68('0x1f')),logger=require('../config/logger')(_0x191f68('0xd')),Sequence=function(){};Sequence['prototype'][_0x191f68('0x12')]=function(_0x20f528){const _0x1ae23a=_0x191f68;this['tail']=this['tail']?this[_0x1ae23a('0x10')][_0x1ae23a('0x7')](_0x20f528):_0x20f528();};const Migration=function(_0x3b72fd){const _0x51a594=_0x191f68;this['queryInterface']=_0x3b72fd,this[_0x51a594('0x1d')]=new Sequence();};Migration[_0x191f68('0x4')][_0x191f68('0xe')]=function(_0x47ce20,_0x98a8c6,_0x38d77a){const _0x55a4b1=_0x191f68,_0x414007=this;this[_0x55a4b1('0x1d')]['enqueue'](function(){const _0x5c7ca6=_0x55a4b1;return _0x414007[_0x5c7ca6('0x0')][_0x5c7ca6('0xe')](_0x47ce20,_0x98a8c6,_0x38d77a)['then'](function(){const _0x5b5b20=_0x5c7ca6;logger['info'](_0x5b5b20('0xb'),_0x98a8c6,_0x47ce20);})[_0x5c7ca6('0x17')](function(_0x486390){const _0x15c0e3=_0x5c7ca6;logger[_0x15c0e3('0x1b')](JSON['stringify'](_0x486390));});});},Migration['prototype']['addColumn']=function(_0x2a35b5,_0x5cd38d,_0x25eb32){const _0x18e8b8=_0x191f68,_0x3000bb=this;this['sequence'][_0x18e8b8('0x12')](function(){const _0x3a7be7=_0x18e8b8;return _0x3000bb[_0x3a7be7('0x0')][_0x3a7be7('0x2')](_0x2a35b5,_0x5cd38d,_0x25eb32)[_0x3a7be7('0xf')](function(){const _0x329066=_0x3a7be7;logger[_0x329066('0x1b')]('Added\x20column\x20%s\x20to\x20%s',_0x5cd38d,_0x2a35b5);})[_0x3a7be7('0x17')](function(_0x258b17){const _0x23d680=_0x3a7be7;logger[_0x23d680('0x1b')](JSON[_0x23d680('0x5')](_0x258b17));});});},Migration[_0x191f68('0x4')][_0x191f68('0x1')]=function(_0x1012e5){const _0x57f36b=_0x191f68,_0x26dad=this;this['sequence'][_0x57f36b('0x12')](function(){const _0x3fdf9e=_0x57f36b;return _0x26dad[_0x3fdf9e('0x0')]['dropTable'](_0x1012e5,{'force':!![]})[_0x3fdf9e('0xf')](function(){logger['info']('table\x20dropped\x20%s',_0x1012e5);})[_0x3fdf9e('0x17')](function(_0x43a418){const _0x127c91=_0x3fdf9e;logger[_0x127c91('0x1b')](JSON[_0x127c91('0x5')](_0x43a418));});});},Migration['prototype'][_0x191f68('0x1a')]=function(_0x356500,_0xb14138,_0x2e41c4){const _0x3f9a60=_0x191f68,_0x4b2133=this;this[_0x3f9a60('0x1d')][_0x3f9a60('0x12')](function(){const _0x2865fd=_0x3f9a60;return _0x4b2133[_0x2865fd('0x0')]['addIndex'](_0x356500,_0xb14138,{'indexName':_0x2e41c4[_0x2865fd('0x16')],'indicesType':_0x2e41c4[_0x2865fd('0x18')]})[_0x2865fd('0xf')](function(){const _0x37b619=_0x2865fd;logger[_0x37b619('0x1b')](_0x37b619('0x8'),_0x356500,_0xb14138[_0x37b619('0x11')](','),_0x2e41c4[_0x37b619('0x16')],_0x2e41c4['indicesType']);})[_0x2865fd('0x17')](function(_0x339c5b){const _0x409657=_0x2865fd;logger[_0x409657('0x1b')](JSON['stringify'](_0x339c5b));});});},Migration[_0x191f68('0x4')][_0x191f68('0x9')]=function(_0x5cebb8,_0x23704b){const _0x59a9cc=_0x191f68,_0x5e11d1=this;this['sequence'][_0x59a9cc('0x12')](function(){const _0x40ea30=_0x59a9cc;return _0x5e11d1['queryInterface'][_0x40ea30('0x9')](_0x5cebb8,_0x23704b)[_0x40ea30('0xf')](function(){const _0x4ed6b4=_0x40ea30;logger[_0x4ed6b4('0x1b')]('removeIndex\x20%s\x20%s',_0x5cebb8,_0x23704b);})[_0x40ea30('0x17')](function(_0x2f8617){const _0x57a1ad=_0x40ea30;logger['info'](JSON[_0x57a1ad('0x5')](_0x2f8617));});});},Migration[_0x191f68('0x4')][_0x191f68('0xa')]=function(_0x2c9c21){const _0x237be4=_0x191f68,_0x11e858=this;this['sequence'][_0x237be4('0x12')](function(){const _0x28debd=_0x237be4;return _0x11e858['queryInterface']['sequelize'][_0x28debd('0xa')](_0x2c9c21)[_0x28debd('0xf')](function(){const _0x593d61=_0x28debd;logger[_0x593d61('0x1b')](_0x593d61('0x1e'),_0x2c9c21);})['catch'](function(_0x108234){const _0x373b7f=_0x28debd;logger[_0x373b7f('0x1b')](JSON['stringify'](_0x108234));});});},Migration[_0x191f68('0x4')]['removeColumn']=function(_0x2bd7a7,_0x2ccaa6){const _0x394aff=this;this['sequence']['enqueue'](function(){const _0x58f3c8=a1016_0x5657;return _0x394aff[_0x58f3c8('0x0')][_0x58f3c8('0x6')](_0x2bd7a7,_0x2ccaa6)[_0x58f3c8('0xf')](function(){const _0x21750f=_0x58f3c8;logger[_0x21750f('0x1b')]('Removed\x20column\x20%s\x20from\x20%s',_0x2ccaa6,_0x2bd7a7);})[_0x58f3c8('0x17')](function(_0x5748f6){const _0x1c0749=_0x58f3c8;logger['info'](util[_0x1c0749('0x15')](_0x5748f6,{'showHidden':![],'depth':null}));});});},Migration[_0x191f68('0x4')][_0x191f68('0x3')]=function(_0x50f99b,_0x5fca24,_0x3fbd41){const _0x4accb9=_0x191f68,_0x1e3fbb=this;this[_0x4accb9('0x1d')][_0x4accb9('0x12')](function(){const _0x43aee0=_0x4accb9;return _0x1e3fbb[_0x43aee0('0x0')][_0x43aee0('0x3')](_0x50f99b,_0x5fca24,_0x3fbd41)['then'](function(){const _0x4d0cf6=_0x43aee0;logger['info'](_0x4d0cf6('0x1c'),_0x5fca24,_0x3fbd41,_0x50f99b);})['catch'](function(_0x23dbee){const _0x56c9c1=_0x43aee0;logger[_0x56c9c1('0x1b')](util['inspect'](_0x23dbee,{'showHidden':![],'depth':null}));});});},Migration[_0x191f68('0x4')][_0x191f68('0x19')]=function(_0x43be0a){const _0x4a9697=_0x191f68;this[_0x4a9697('0x1d')]['enqueue'](function(){return _0x43be0a();});},module['exports']={'up':function(_0x26fd3b,_0x453113){return new Promise(function(_0x2ea2b6){const _0x44ce80=a1016_0x5657,_0xa493ba=new Migration(_0x26fd3b);_0xa493ba[_0x44ce80('0xe')](_0x44ce80('0x14'),'color',{'type':_0x453113[_0x44ce80('0xc')],'allowNull':![],'defaultValue':'#011F6A','validate':{'notEmpty':!![]}}),_0xa493ba['changeColumn'](_0x44ce80('0x14'),'color_button',{'type':_0x453113[_0x44ce80('0xc')],'allowNull':![],'defaultValue':_0x44ce80('0x13'),'validate':{'notEmpty':!![]}}),_0xa493ba[_0x44ce80('0x19')](_0x2ea2b6);});},'down':function(){}}; \ No newline at end of file +const a1016_0x1bf3=['Changed\x20column\x20%s\x20in\x20table\x20%s','Removed\x20column\x20%s\x20from\x20%s','table\x20dropped\x20%s','STRING','color','migration','addIndex','renameColumn','stringify','info','dropTable','color_button','query','indexName','catch','join','final','removeIndex','inspect','prototype','exports','chat_websites','removeColumn','removeIndex\x20%s\x20%s','#011F6A','finally','changeColumn','addIndex\x20%s\x20%s\x20%s\x20[%s]','util','then','tail','../config/logger','queryInterface','query\x20%s','sequence','indicesType','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addColumn','enqueue'];(function(_0x2eeb5f,_0x1bf3bb){const _0x1ac4af=function(_0x267f97){while(--_0x267f97){_0x2eeb5f['push'](_0x2eeb5f['shift']());}};_0x1ac4af(++_0x1bf3bb);}(a1016_0x1bf3,0x100));const a1016_0x1ac4=function(_0x2eeb5f,_0x1bf3bb){_0x2eeb5f=_0x2eeb5f-0x0;let _0x1ac4af=a1016_0x1bf3[_0x2eeb5f];return _0x1ac4af;};const _0x3d2ab7=a1016_0x1ac4;'use strict';const util=require(_0x3d2ab7('0x6')),logger=require(_0x3d2ab7('0x9'))(_0x3d2ab7('0x16')),Sequence=function(){};Sequence[_0x3d2ab7('0x24')]['enqueue']=function(_0x267f97){const _0x13134c=_0x3d2ab7;this[_0x13134c('0x8')]=this[_0x13134c('0x8')]?this[_0x13134c('0x8')][_0x13134c('0x3')](_0x267f97):_0x267f97();};const Migration=function(_0x5761b5){const _0x37b35f=_0x3d2ab7;this[_0x37b35f('0xa')]=_0x5761b5,this[_0x37b35f('0xc')]=new Sequence();};Migration[_0x3d2ab7('0x24')]['changeColumn']=function(_0x266f7e,_0x255967,_0x463100){const _0x422849=_0x3d2ab7,_0x5a444c=this;this['sequence'][_0x422849('0x10')](function(){const _0x9618be=_0x422849;return _0x5a444c['queryInterface'][_0x9618be('0x4')](_0x266f7e,_0x255967,_0x463100)[_0x9618be('0x7')](function(){const _0x2b6c4e=_0x9618be;logger[_0x2b6c4e('0x1a')](_0x2b6c4e('0x11'),_0x255967,_0x266f7e);})[_0x9618be('0x1f')](function(_0x1201c2){logger['info'](JSON['stringify'](_0x1201c2));});});},Migration[_0x3d2ab7('0x24')][_0x3d2ab7('0xf')]=function(_0x14568f,_0x595320,_0x2c40aa){const _0x36944a=_0x3d2ab7,_0x2555f2=this;this[_0x36944a('0xc')][_0x36944a('0x10')](function(){const _0x20bae4=_0x36944a;return _0x2555f2['queryInterface'][_0x20bae4('0xf')](_0x14568f,_0x595320,_0x2c40aa)[_0x20bae4('0x7')](function(){const _0x57596b=_0x20bae4;logger[_0x57596b('0x1a')]('Added\x20column\x20%s\x20to\x20%s',_0x595320,_0x14568f);})[_0x20bae4('0x1f')](function(_0x11d874){const _0x585154=_0x20bae4;logger[_0x585154('0x1a')](JSON[_0x585154('0x19')](_0x11d874));});});},Migration['prototype']['dropTable']=function(_0x5cec4c){const _0x4e2fb8=_0x3d2ab7,_0x6cd171=this;this[_0x4e2fb8('0xc')][_0x4e2fb8('0x10')](function(){const _0x5ec202=_0x4e2fb8;return _0x6cd171[_0x5ec202('0xa')][_0x5ec202('0x1b')](_0x5cec4c,{'force':!![]})[_0x5ec202('0x7')](function(){const _0x5f08d4=_0x5ec202;logger['info'](_0x5f08d4('0x13'),_0x5cec4c);})['catch'](function(_0x2dfc45){const _0x1c2346=_0x5ec202;logger[_0x1c2346('0x1a')](JSON[_0x1c2346('0x19')](_0x2dfc45));});});},Migration['prototype'][_0x3d2ab7('0x17')]=function(_0x1f234b,_0x3dfbd2,_0x5d8414){const _0x3e6584=_0x3d2ab7,_0x11e765=this;this[_0x3e6584('0xc')][_0x3e6584('0x10')](function(){const _0x4e4efb=_0x3e6584;return _0x11e765[_0x4e4efb('0xa')][_0x4e4efb('0x17')](_0x1f234b,_0x3dfbd2,{'indexName':_0x5d8414['indexName'],'indicesType':_0x5d8414[_0x4e4efb('0xd')]})[_0x4e4efb('0x7')](function(){const _0x56fa36=_0x4e4efb;logger[_0x56fa36('0x1a')](_0x56fa36('0x5'),_0x1f234b,_0x3dfbd2[_0x56fa36('0x20')](','),_0x5d8414[_0x56fa36('0x1e')],_0x5d8414['indicesType']);})[_0x4e4efb('0x1f')](function(_0x45230d){const _0x20d64d=_0x4e4efb;logger[_0x20d64d('0x1a')](JSON['stringify'](_0x45230d));});});},Migration[_0x3d2ab7('0x24')][_0x3d2ab7('0x22')]=function(_0x41ef69,_0x48a406){const _0x4c6906=_0x3d2ab7,_0x51b5dc=this;this[_0x4c6906('0xc')][_0x4c6906('0x10')](function(){const _0x1d30c3=_0x4c6906;return _0x51b5dc[_0x1d30c3('0xa')]['removeIndex'](_0x41ef69,_0x48a406)[_0x1d30c3('0x7')](function(){const _0x362840=_0x1d30c3;logger[_0x362840('0x1a')](_0x362840('0x1'),_0x41ef69,_0x48a406);})[_0x1d30c3('0x1f')](function(_0x15f7fe){const _0x1a69ee=_0x1d30c3;logger[_0x1a69ee('0x1a')](JSON[_0x1a69ee('0x19')](_0x15f7fe));});});},Migration['prototype'][_0x3d2ab7('0x1d')]=function(_0x50d511){const _0x20f623=_0x3d2ab7,_0x240054=this;this[_0x20f623('0xc')]['enqueue'](function(){const _0xe788ac=_0x20f623;return _0x240054[_0xe788ac('0xa')]['sequelize'][_0xe788ac('0x1d')](_0x50d511)['then'](function(){const _0x4de4f6=_0xe788ac;logger['info'](_0x4de4f6('0xb'),_0x50d511);})[_0xe788ac('0x1f')](function(_0x44663a){const _0xc0107e=_0xe788ac;logger['info'](JSON[_0xc0107e('0x19')](_0x44663a));});});},Migration[_0x3d2ab7('0x24')][_0x3d2ab7('0x0')]=function(_0x2e8a77,_0x5767f9){const _0x33b969=_0x3d2ab7,_0x5be73a=this;this[_0x33b969('0xc')]['enqueue'](function(){const _0x45bea9=_0x33b969;return _0x5be73a['queryInterface']['removeColumn'](_0x2e8a77,_0x5767f9)[_0x45bea9('0x7')](function(){const _0x410d7b=_0x45bea9;logger[_0x410d7b('0x1a')](_0x410d7b('0x12'),_0x5767f9,_0x2e8a77);})[_0x45bea9('0x1f')](function(_0x191158){const _0x466455=_0x45bea9;logger['info'](util[_0x466455('0x23')](_0x191158,{'showHidden':![],'depth':null}));});});},Migration[_0x3d2ab7('0x24')][_0x3d2ab7('0x18')]=function(_0x3ead33,_0x455697,_0x3e67c7){const _0x40d897=_0x3d2ab7,_0x5c4c1a=this;this[_0x40d897('0xc')][_0x40d897('0x10')](function(){const _0x5eddaa=_0x40d897;return _0x5c4c1a[_0x5eddaa('0xa')][_0x5eddaa('0x18')](_0x3ead33,_0x455697,_0x3e67c7)[_0x5eddaa('0x7')](function(){const _0x3f61cb=_0x5eddaa;logger[_0x3f61cb('0x1a')](_0x3f61cb('0xe'),_0x455697,_0x3e67c7,_0x3ead33);})[_0x5eddaa('0x1f')](function(_0x51b09c){const _0x1ef542=_0x5eddaa;logger[_0x1ef542('0x1a')](util[_0x1ef542('0x23')](_0x51b09c,{'showHidden':![],'depth':null}));});});},Migration[_0x3d2ab7('0x24')]['final']=function(_0x516176){const _0x258272=_0x3d2ab7;this[_0x258272('0xc')][_0x258272('0x10')](function(){return _0x516176();});},module[_0x3d2ab7('0x25')]={'up':function(_0x44f094,_0x2291fd){return new Promise(function(_0x1c5987){const _0x3fe386=a1016_0x1ac4,_0x257d95=new Migration(_0x44f094);_0x257d95[_0x3fe386('0x4')](_0x3fe386('0x26'),_0x3fe386('0x15'),{'type':_0x2291fd[_0x3fe386('0x14')],'allowNull':![],'defaultValue':_0x3fe386('0x2'),'validate':{'notEmpty':!![]}}),_0x257d95[_0x3fe386('0x4')](_0x3fe386('0x26'),_0x3fe386('0x1c'),{'type':_0x2291fd[_0x3fe386('0x14')],'allowNull':![],'defaultValue':_0x3fe386('0x2'),'validate':{'notEmpty':!![]}}),_0x257d95[_0x3fe386('0x21')](_0x1c5987);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.5.4.js b/server/migrations/2.5.4.js index 59a894a..3060d73 100644 --- a/server/migrations/2.5.4.js +++ b/server/migrations/2.5.4.js @@ -1 +1 @@ -const a1017_0xa443=['inspect','sequelize','indicesType','queryInterface','query','query\x20%s','renameColumn','stringify','addIndex','info','prototype','removeIndex','indexName','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','sequence','util','changeColumn','join','migration','addColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','table\x20dropped\x20%s','Added\x20column\x20%s\x20to\x20%s','tail','../config/logger','then','Removed\x20column\x20%s\x20from\x20%s','final','catch','removeColumn','dropTable','enqueue'];(function(_0x201767,_0xa4434d){const _0x109654=function(_0x1b7a5d){while(--_0x1b7a5d){_0x201767['push'](_0x201767['shift']());}};_0x109654(++_0xa4434d);}(a1017_0xa443,0x142));const a1017_0x1096=function(_0x201767,_0xa4434d){_0x201767=_0x201767-0x0;let _0x109654=a1017_0xa443[_0x201767];return _0x109654;};const _0x54618b=a1017_0x1096;'use strict';const util=require(_0x54618b('0xd')),logger=require(_0x54618b('0x16'))(_0x54618b('0x10')),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x1b7a5d){const _0x4da870=_0x54618b;this[_0x4da870('0x15')]=this[_0x4da870('0x15')]?this['tail']['finally'](_0x1b7a5d):_0x1b7a5d();};const Migration=function(_0x2879b7){this['queryInterface']=_0x2879b7,this['sequence']=new Sequence();};Migration[_0x54618b('0x8')][_0x54618b('0xe')]=function(_0x13624f,_0xf1667d,_0x39c3b6){const _0x4093e6=_0x54618b,_0x5b7c92=this;this[_0x4093e6('0xc')][_0x4093e6('0x1d')](function(){const _0xc49b2b=_0x4093e6;return _0x5b7c92['queryInterface'][_0xc49b2b('0xe')](_0x13624f,_0xf1667d,_0x39c3b6)[_0xc49b2b('0x17')](function(){const _0x3eabb1=_0xc49b2b;logger[_0x3eabb1('0x7')](_0x3eabb1('0x12'),_0xf1667d,_0x13624f);})['catch'](function(_0x91bab4){const _0x50eca6=_0xc49b2b;logger[_0x50eca6('0x7')](JSON[_0x50eca6('0x5')](_0x91bab4));});});},Migration[_0x54618b('0x8')][_0x54618b('0x11')]=function(_0x3b3a24,_0x2b66b9,_0x1e3064){const _0x2ae184=_0x54618b,_0x5669bc=this;this['sequence'][_0x2ae184('0x1d')](function(){const _0x35e3a0=_0x2ae184;return _0x5669bc['queryInterface']['addColumn'](_0x3b3a24,_0x2b66b9,_0x1e3064)[_0x35e3a0('0x17')](function(){const _0x241efe=_0x35e3a0;logger[_0x241efe('0x7')](_0x241efe('0x14'),_0x2b66b9,_0x3b3a24);})[_0x35e3a0('0x1a')](function(_0x13f7fe){logger['info'](JSON['stringify'](_0x13f7fe));});});},Migration[_0x54618b('0x8')][_0x54618b('0x1c')]=function(_0x1703da){const _0x591c86=_0x54618b,_0x27491d=this;this['sequence'][_0x591c86('0x1d')](function(){const _0x26f9ec=_0x591c86;return _0x27491d['queryInterface'][_0x26f9ec('0x1c')](_0x1703da,{'force':!![]})[_0x26f9ec('0x17')](function(){const _0x3a4e08=_0x26f9ec;logger[_0x3a4e08('0x7')](_0x3a4e08('0x13'),_0x1703da);})['catch'](function(_0x45ee65){logger['info'](JSON['stringify'](_0x45ee65));});});},Migration[_0x54618b('0x8')][_0x54618b('0x6')]=function(_0x430f27,_0x300ada,_0x51e726){const _0x12450f=_0x54618b,_0xf9c188=this;this['sequence'][_0x12450f('0x1d')](function(){const _0x3b1078=_0x12450f;return _0xf9c188[_0x3b1078('0x1')][_0x3b1078('0x6')](_0x430f27,_0x300ada,{'indexName':_0x51e726[_0x3b1078('0xa')],'indicesType':_0x51e726['indicesType']})[_0x3b1078('0x17')](function(){const _0x5e5960=_0x3b1078;logger['info']('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x430f27,_0x300ada[_0x5e5960('0xf')](','),_0x51e726[_0x5e5960('0xa')],_0x51e726[_0x5e5960('0x0')]);})['catch'](function(_0x3b3a18){const _0xd3655c=_0x3b1078;logger[_0xd3655c('0x7')](JSON[_0xd3655c('0x5')](_0x3b3a18));});});},Migration['prototype'][_0x54618b('0x9')]=function(_0x5a57f9,_0x5c01bd){const _0x46e4da=_0x54618b,_0x12c085=this;this[_0x46e4da('0xc')]['enqueue'](function(){const _0x17a070=_0x46e4da;return _0x12c085['queryInterface']['removeIndex'](_0x5a57f9,_0x5c01bd)[_0x17a070('0x17')](function(){logger['info']('removeIndex\x20%s\x20%s',_0x5a57f9,_0x5c01bd);})[_0x17a070('0x1a')](function(_0x4270e4){const _0x4c914e=_0x17a070;logger[_0x4c914e('0x7')](JSON['stringify'](_0x4270e4));});});},Migration[_0x54618b('0x8')][_0x54618b('0x2')]=function(_0xcdfd3){const _0x212891=_0x54618b,_0x585b9f=this;this[_0x212891('0xc')]['enqueue'](function(){const _0x448f43=_0x212891;return _0x585b9f[_0x448f43('0x1')][_0x448f43('0x1f')][_0x448f43('0x2')](_0xcdfd3)[_0x448f43('0x17')](function(){const _0x24c261=_0x448f43;logger[_0x24c261('0x7')](_0x24c261('0x3'),_0xcdfd3);})[_0x448f43('0x1a')](function(_0x5810f2){const _0x46da7=_0x448f43;logger[_0x46da7('0x7')](JSON[_0x46da7('0x5')](_0x5810f2));});});},Migration['prototype']['removeColumn']=function(_0x3bdf8c,_0x5270e0){const _0x859d8f=_0x54618b,_0x5488dd=this;this[_0x859d8f('0xc')]['enqueue'](function(){const _0x1c6471=_0x859d8f;return _0x5488dd[_0x1c6471('0x1')][_0x1c6471('0x1b')](_0x3bdf8c,_0x5270e0)[_0x1c6471('0x17')](function(){const _0x4cdd82=_0x1c6471;logger[_0x4cdd82('0x7')](_0x4cdd82('0x18'),_0x5270e0,_0x3bdf8c);})['catch'](function(_0x1c5561){const _0x14c23c=_0x1c6471;logger[_0x14c23c('0x7')](util['inspect'](_0x1c5561,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x54618b('0x4')]=function(_0x197b3d,_0x301ccb,_0x47c19c){const _0x449142=_0x54618b,_0x2f1a31=this;this[_0x449142('0xc')]['enqueue'](function(){const _0x4c72fe=_0x449142;return _0x2f1a31[_0x4c72fe('0x1')]['renameColumn'](_0x197b3d,_0x301ccb,_0x47c19c)[_0x4c72fe('0x17')](function(){const _0x20cf1e=_0x4c72fe;logger[_0x20cf1e('0x7')](_0x20cf1e('0xb'),_0x301ccb,_0x47c19c,_0x197b3d);})[_0x4c72fe('0x1a')](function(_0x48256f){const _0x20dd8d=_0x4c72fe;logger[_0x20dd8d('0x7')](util[_0x20dd8d('0x1e')](_0x48256f,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x54618b('0x19')]=function(_0xfa0fb){const _0x5f317d=_0x54618b;this[_0x5f317d('0xc')][_0x5f317d('0x1d')](function(){return _0xfa0fb();});},module['exports']={'up':function(_0x555ceb){return new Promise(function(_0x4cba13){const _0x511aeb=a1017_0x1096,_0x243389=new Migration(_0x555ceb);_0x243389[_0x511aeb('0x19')](_0x4cba13);});},'down':function(){}}; \ No newline at end of file +const a1017_0x5ce9=['removeIndex','renameColumn','removeColumn','Changed\x20column\x20%s\x20in\x20table\x20%s','Added\x20column\x20%s\x20to\x20%s','addIndex','changeColumn','queryInterface','inspect','tail','stringify','catch','info','dropTable','then','util','migration','../config/logger','final','query','join','sequence','prototype','enqueue','addColumn','table\x20dropped\x20%s','indexName','indicesType','finally','addIndex\x20%s\x20%s\x20%s\x20[%s]','query\x20%s'];(function(_0x16f55b,_0x5ce955){const _0x120203=function(_0x19e930){while(--_0x19e930){_0x16f55b['push'](_0x16f55b['shift']());}};_0x120203(++_0x5ce955);}(a1017_0x5ce9,0x1a0));const a1017_0x1202=function(_0x16f55b,_0x5ce955){_0x16f55b=_0x16f55b-0x0;let _0x120203=a1017_0x5ce9[_0x16f55b];return _0x120203;};const _0x39a664=a1017_0x1202;'use strict';const util=require(_0x39a664('0x2')),logger=require(_0x39a664('0x4'))(_0x39a664('0x3')),Sequence=function(){};Sequence['prototype'][_0x39a664('0xa')]=function(_0x19e930){const _0x1a7334=_0x39a664;this[_0x1a7334('0x1b')]=this['tail']?this['tail'][_0x1a7334('0xf')](_0x19e930):_0x19e930();};const Migration=function(_0x384280){this['queryInterface']=_0x384280,this['sequence']=new Sequence();};Migration['prototype']['changeColumn']=function(_0x16e216,_0x5dd62a,_0x5e35e8){const _0x1913d2=_0x39a664,_0x29ccda=this;this['sequence'][_0x1913d2('0xa')](function(){const _0x530000=_0x1913d2;return _0x29ccda[_0x530000('0x19')][_0x530000('0x18')](_0x16e216,_0x5dd62a,_0x5e35e8)[_0x530000('0x1')](function(){const _0x274d2f=_0x530000;logger[_0x274d2f('0x1e')](_0x274d2f('0x15'),_0x5dd62a,_0x16e216);})[_0x530000('0x1d')](function(_0x27520a){const _0x1432b4=_0x530000;logger[_0x1432b4('0x1e')](JSON[_0x1432b4('0x1c')](_0x27520a));});});},Migration[_0x39a664('0x9')][_0x39a664('0xb')]=function(_0x2636d,_0x53fd33,_0xe30939){const _0x18ae4d=_0x39a664,_0x3198f3=this;this[_0x18ae4d('0x8')]['enqueue'](function(){const _0x19c972=_0x18ae4d;return _0x3198f3['queryInterface'][_0x19c972('0xb')](_0x2636d,_0x53fd33,_0xe30939)[_0x19c972('0x1')](function(){const _0x1ec73a=_0x19c972;logger[_0x1ec73a('0x1e')](_0x1ec73a('0x16'),_0x53fd33,_0x2636d);})[_0x19c972('0x1d')](function(_0x14d27b){const _0x89c3d9=_0x19c972;logger[_0x89c3d9('0x1e')](JSON[_0x89c3d9('0x1c')](_0x14d27b));});});},Migration[_0x39a664('0x9')][_0x39a664('0x0')]=function(_0xa614bf){const _0x1c0830=_0x39a664,_0x4040f5=this;this[_0x1c0830('0x8')][_0x1c0830('0xa')](function(){const _0x5a44f9=_0x1c0830;return _0x4040f5[_0x5a44f9('0x19')]['dropTable'](_0xa614bf,{'force':!![]})[_0x5a44f9('0x1')](function(){const _0x25070a=_0x5a44f9;logger[_0x25070a('0x1e')](_0x25070a('0xc'),_0xa614bf);})[_0x5a44f9('0x1d')](function(_0x4fcff0){const _0x2bde31=_0x5a44f9;logger['info'](JSON[_0x2bde31('0x1c')](_0x4fcff0));});});},Migration[_0x39a664('0x9')][_0x39a664('0x17')]=function(_0x14585c,_0x22575c,_0x1c059d){const _0x229609=_0x39a664,_0x5269a5=this;this[_0x229609('0x8')][_0x229609('0xa')](function(){const _0x3ffcc8=_0x229609;return _0x5269a5['queryInterface'][_0x3ffcc8('0x17')](_0x14585c,_0x22575c,{'indexName':_0x1c059d[_0x3ffcc8('0xd')],'indicesType':_0x1c059d['indicesType']})[_0x3ffcc8('0x1')](function(){const _0x34c21f=_0x3ffcc8;logger[_0x34c21f('0x1e')](_0x34c21f('0x10'),_0x14585c,_0x22575c[_0x34c21f('0x7')](','),_0x1c059d['indexName'],_0x1c059d[_0x34c21f('0xe')]);})[_0x3ffcc8('0x1d')](function(_0x5ed88e){const _0x3770a0=_0x3ffcc8;logger[_0x3770a0('0x1e')](JSON[_0x3770a0('0x1c')](_0x5ed88e));});});},Migration[_0x39a664('0x9')][_0x39a664('0x12')]=function(_0x1a07e4,_0x4f99ac){const _0x29bece=_0x39a664,_0x10baae=this;this[_0x29bece('0x8')][_0x29bece('0xa')](function(){const _0x3db0c4=_0x29bece;return _0x10baae['queryInterface'][_0x3db0c4('0x12')](_0x1a07e4,_0x4f99ac)['then'](function(){const _0xb9ea39=_0x3db0c4;logger[_0xb9ea39('0x1e')]('removeIndex\x20%s\x20%s',_0x1a07e4,_0x4f99ac);})[_0x3db0c4('0x1d')](function(_0x2ba4e1){const _0x23cbce=_0x3db0c4;logger['info'](JSON[_0x23cbce('0x1c')](_0x2ba4e1));});});},Migration[_0x39a664('0x9')][_0x39a664('0x6')]=function(_0x53e32d){const _0x4c3c88=_0x39a664,_0x2982e1=this;this[_0x4c3c88('0x8')][_0x4c3c88('0xa')](function(){const _0x5f5336=_0x4c3c88;return _0x2982e1['queryInterface']['sequelize']['query'](_0x53e32d)['then'](function(){const _0x1febd0=a1017_0x1202;logger[_0x1febd0('0x1e')](_0x1febd0('0x11'),_0x53e32d);})[_0x5f5336('0x1d')](function(_0x468107){const _0x128795=_0x5f5336;logger['info'](JSON[_0x128795('0x1c')](_0x468107));});});},Migration[_0x39a664('0x9')]['removeColumn']=function(_0x10b449,_0x1e20fb){const _0x33eb0c=_0x39a664,_0x529a8b=this;this[_0x33eb0c('0x8')]['enqueue'](function(){const _0x2bc295=_0x33eb0c;return _0x529a8b[_0x2bc295('0x19')][_0x2bc295('0x14')](_0x10b449,_0x1e20fb)[_0x2bc295('0x1')](function(){const _0x28c41d=_0x2bc295;logger[_0x28c41d('0x1e')]('Removed\x20column\x20%s\x20from\x20%s',_0x1e20fb,_0x10b449);})[_0x2bc295('0x1d')](function(_0x75731e){const _0x3ecdf1=_0x2bc295;logger['info'](util[_0x3ecdf1('0x1a')](_0x75731e,{'showHidden':![],'depth':null}));});});},Migration[_0x39a664('0x9')]['renameColumn']=function(_0x585f3a,_0x21a4f4,_0x57f66a){const _0x5617e7=_0x39a664,_0x2ccfac=this;this[_0x5617e7('0x8')][_0x5617e7('0xa')](function(){const _0x26d086=_0x5617e7;return _0x2ccfac[_0x26d086('0x19')][_0x26d086('0x13')](_0x585f3a,_0x21a4f4,_0x57f66a)[_0x26d086('0x1')](function(){const _0x1c5ad5=_0x26d086;logger[_0x1c5ad5('0x1e')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x21a4f4,_0x57f66a,_0x585f3a);})[_0x26d086('0x1d')](function(_0x3c030d){const _0xe6c7eb=_0x26d086;logger['info'](util[_0xe6c7eb('0x1a')](_0x3c030d,{'showHidden':![],'depth':null}));});});},Migration[_0x39a664('0x9')][_0x39a664('0x5')]=function(_0x296966){const _0x56e23e=_0x39a664;this['sequence'][_0x56e23e('0xa')](function(){return _0x296966();});},module['exports']={'up':function(_0x358d8b){return new Promise(function(_0x346462){const _0x3362d8=a1017_0x1202,_0x4127bb=new Migration(_0x358d8b);_0x4127bb[_0x3362d8('0x5')](_0x346462);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.5.5.js b/server/migrations/2.5.5.js index 0b38d48..ffdaf6f 100644 --- a/server/migrations/2.5.5.js +++ b/server/migrations/2.5.5.js @@ -1 +1 @@ -const a1018_0x1dce=['table\x20dropped\x20%s','secondDisposition','cm_custom_fields','passwordResetAt','addColumn','tools_dispositions','chat_interactions','fax_interactions','description','disposition','query','final','report_call','catch','passwordHistoryLimit','tail','enqueue','finally','actionType','../config/logger','whatsapp_interactions','clickToAction','removeIndex','report_queue','voice','inspect','queryInterface','settings','ALTER\x20TABLE\x20tools_dispositions\x20ADD\x20CONSTRAINT\x20`tools_dispositions_ibfk_8`\x20FOREIGN\x20KEY\x20(`ParentId`)\x20REFERENCES\x20`tools_dispositions`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE','UPDATE\x20tools_actions\x20SET\x20data3\x20=\x20\x27phone\x27\x20WHERE\x20action\x20=\x20\x27contactManager\x27\x20AND\x20data3\x20=\x20\x270\x27','util','sequence','STRING','userSecondDisposition','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','BOOLEAN','info','previousPasswords','query\x20%s','first','indexName','indicesType','then','voice_recordings','ENUM','userDisposition','Removed\x20column\x20%s\x20from\x20%s','changeColumn','userThirdDisposition','addIndex\x20%s\x20%s\x20%s\x20[%s]','enforcePasswordHistory','stringify','Changed\x20column\x20%s\x20in\x20table\x20%s','thirdDisposition','mail_interactions','UPDATE\x20tools_actions\x20SET\x20data4\x20=\x20\x27phone\x27\x20WHERE\x20action\x20=\x20\x27contactManager\x27\x20AND\x20data4\x20=\x20\x270\x27','second','sms_interactions','removeColumn','INTEGER','renameColumn','updatedAt','sequelize','Added\x20column\x20%s\x20to\x20%s','addIndex','dropTable','ParentId','cm_hopper_final','openchannel_interactions','name','users','level','removeIndex\x20%s\x20%s','prototype'];(function(_0x306d88,_0x1dce75){const _0x357bbc=function(_0x543f64){while(--_0x543f64){_0x306d88['push'](_0x306d88['shift']());}};_0x357bbc(++_0x1dce75);}(a1018_0x1dce,0xed));const a1018_0x357b=function(_0x306d88,_0x1dce75){_0x306d88=_0x306d88-0x0;let _0x357bbc=a1018_0x1dce[_0x306d88];return _0x357bbc;};const _0x1ed4a6=a1018_0x357b;'use strict';const util=require(_0x1ed4a6('0xf')),logger=require(_0x1ed4a6('0x4'))('migration'),Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x543f64){const _0x27e5d0=_0x1ed4a6;this[_0x27e5d0('0x0')]=this['tail']?this['tail'][_0x27e5d0('0x2')](_0x543f64):_0x543f64();};const Migration=function(_0x45984c){const _0x2dddfa=_0x1ed4a6;this['queryInterface']=_0x45984c,this[_0x2dddfa('0x10')]=new Sequence();};Migration[_0x1ed4a6('0x3a')][_0x1ed4a6('0x20')]=function(_0x4e129c,_0x3ecdaf,_0x128db5){const _0xae9839=_0x1ed4a6,_0x43dbcd=this;this[_0xae9839('0x10')][_0xae9839('0x1')](function(){const _0x31c204=_0xae9839;return _0x43dbcd[_0x31c204('0xb')][_0x31c204('0x20')](_0x4e129c,_0x3ecdaf,_0x128db5)['then'](function(){const _0xa840be=_0x31c204;logger[_0xa840be('0x15')](_0xa840be('0x25'),_0x3ecdaf,_0x4e129c);})[_0x31c204('0x48')](function(_0x31d41e){const _0x37c5d6=_0x31c204;logger[_0x37c5d6('0x15')](JSON['stringify'](_0x31d41e));});});},Migration[_0x1ed4a6('0x3a')][_0x1ed4a6('0x3f')]=function(_0x354505,_0x1923d4,_0xf4b708){const _0x5c1b93=_0x1ed4a6,_0x3cc804=this;this[_0x5c1b93('0x10')][_0x5c1b93('0x1')](function(){const _0x3b7413=_0x5c1b93;return _0x3cc804[_0x3b7413('0xb')]['addColumn'](_0x354505,_0x1923d4,_0xf4b708)[_0x3b7413('0x1b')](function(){const _0xa45c21=_0x3b7413;logger[_0xa45c21('0x15')](_0xa45c21('0x30'),_0x1923d4,_0x354505);})[_0x3b7413('0x48')](function(_0x376a47){const _0x1a77a3=_0x3b7413;logger['info'](JSON[_0x1a77a3('0x24')](_0x376a47));});});},Migration[_0x1ed4a6('0x3a')][_0x1ed4a6('0x32')]=function(_0x188b20){const _0x57659f=_0x1ed4a6,_0x3c4214=this;this[_0x57659f('0x10')][_0x57659f('0x1')](function(){const _0x62d4fc=_0x57659f;return _0x3c4214['queryInterface'][_0x62d4fc('0x32')](_0x188b20,{'force':!![]})[_0x62d4fc('0x1b')](function(){const _0x4ee60f=_0x62d4fc;logger['info'](_0x4ee60f('0x3b'),_0x188b20);})['catch'](function(_0x9cdaeb){const _0x556e89=_0x62d4fc;logger[_0x556e89('0x15')](JSON[_0x556e89('0x24')](_0x9cdaeb));});});},Migration[_0x1ed4a6('0x3a')][_0x1ed4a6('0x31')]=function(_0x55d6a0,_0x2947c7,_0x307efd){const _0x2f1e99=_0x1ed4a6,_0x22bfbe=this;this[_0x2f1e99('0x10')]['enqueue'](function(){const _0x1609eb=_0x2f1e99;return _0x22bfbe[_0x1609eb('0xb')][_0x1609eb('0x31')](_0x55d6a0,_0x2947c7,{'indexName':_0x307efd[_0x1609eb('0x19')],'indicesType':_0x307efd[_0x1609eb('0x1a')]})[_0x1609eb('0x1b')](function(){const _0x4118f9=_0x1609eb;logger[_0x4118f9('0x15')](_0x4118f9('0x22'),_0x55d6a0,_0x2947c7['join'](','),_0x307efd['indexName'],_0x307efd[_0x4118f9('0x1a')]);})[_0x1609eb('0x48')](function(_0xb1d9e2){const _0x3162da=_0x1609eb;logger[_0x3162da('0x15')](JSON[_0x3162da('0x24')](_0xb1d9e2));});});},Migration[_0x1ed4a6('0x3a')][_0x1ed4a6('0x7')]=function(_0x498d21,_0x84afe5){const _0x1d2a86=_0x1ed4a6,_0x5a79cf=this;this[_0x1d2a86('0x10')]['enqueue'](function(){const _0x56409f=_0x1d2a86;return _0x5a79cf[_0x56409f('0xb')][_0x56409f('0x7')](_0x498d21,_0x84afe5)[_0x56409f('0x1b')](function(){const _0x8c9558=_0x56409f;logger[_0x8c9558('0x15')](_0x8c9558('0x39'),_0x498d21,_0x84afe5);})[_0x56409f('0x48')](function(_0x3e6e3f){const _0x3d20ce=_0x56409f;logger[_0x3d20ce('0x15')](JSON[_0x3d20ce('0x24')](_0x3e6e3f));});});},Migration[_0x1ed4a6('0x3a')]['query']=function(_0x485cc4){const _0x4061e3=_0x1ed4a6,_0x2fb0ea=this;this[_0x4061e3('0x10')][_0x4061e3('0x1')](function(){const _0x1541b7=_0x4061e3;return _0x2fb0ea[_0x1541b7('0xb')][_0x1541b7('0x2f')][_0x1541b7('0x45')](_0x485cc4)[_0x1541b7('0x1b')](function(){const _0x30406a=_0x1541b7;logger[_0x30406a('0x15')](_0x30406a('0x17'),_0x485cc4);})[_0x1541b7('0x48')](function(_0x1a5178){const _0xca9c61=_0x1541b7;logger[_0xca9c61('0x15')](JSON[_0xca9c61('0x24')](_0x1a5178));});});},Migration[_0x1ed4a6('0x3a')][_0x1ed4a6('0x2b')]=function(_0xd83531,_0x36c2dc){const _0x1df28c=_0x1ed4a6,_0x1ef125=this;this[_0x1df28c('0x10')]['enqueue'](function(){const _0x5baa7b=_0x1df28c;return _0x1ef125[_0x5baa7b('0xb')][_0x5baa7b('0x2b')](_0xd83531,_0x36c2dc)[_0x5baa7b('0x1b')](function(){const _0x38aa61=_0x5baa7b;logger[_0x38aa61('0x15')](_0x38aa61('0x1f'),_0x36c2dc,_0xd83531);})[_0x5baa7b('0x48')](function(_0x52ecb9){logger['info'](util['inspect'](_0x52ecb9,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x1ed4a6('0x2d')]=function(_0x5ff7b5,_0x5ef4cb,_0x1b83b9){const _0x42d188=_0x1ed4a6,_0x5062ca=this;this[_0x42d188('0x10')][_0x42d188('0x1')](function(){const _0xe08d0b=_0x42d188;return _0x5062ca['queryInterface'][_0xe08d0b('0x2d')](_0x5ff7b5,_0x5ef4cb,_0x1b83b9)[_0xe08d0b('0x1b')](function(){const _0x4a1da2=_0xe08d0b;logger[_0x4a1da2('0x15')](_0x4a1da2('0x13'),_0x5ef4cb,_0x1b83b9,_0x5ff7b5);})[_0xe08d0b('0x48')](function(_0x5d1eb5){const _0x11c08c=_0xe08d0b;logger['info'](util[_0x11c08c('0xa')](_0x5d1eb5,{'showHidden':![],'depth':null}));});});},Migration[_0x1ed4a6('0x3a')][_0x1ed4a6('0x46')]=function(_0x10fc52){const _0x36a8da=_0x1ed4a6;this[_0x36a8da('0x10')][_0x36a8da('0x1')](function(){return _0x10fc52();});},module['exports']={'up':function(_0x388c0b,_0x36ab8e){return new Promise(function(_0x160f42){const _0x564045=a1018_0x357b,_0xfb59ea=new Migration(_0x388c0b);_0xfb59ea[_0x564045('0x45')](_0x564045('0xe')),_0xfb59ea[_0x564045('0x45')]('UPDATE\x20tools_actions\x20SET\x20data4\x20=\x20NULL\x20WHERE\x20action\x20=\x20\x27contactManager\x27\x20AND\x20data2\x20=\x20\x270\x27\x20AND\x20data4\x20=\x20\x270\x27'),_0xfb59ea[_0x564045('0x45')](_0x564045('0x28')),_0xfb59ea[_0x564045('0x3f')]('settings',_0x564045('0x23'),{'type':_0x36ab8e[_0x564045('0x14')],'defaultValue':!![]}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0xc'),_0x564045('0x49'),{'type':_0x36ab8e[_0x564045('0x2c')](0x2)['UNSIGNED'],'defaultValue':0x3,'validate':{'min':0x1,'max':0x5}}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x37'),_0x564045('0x16'),{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x3e')}),_0xfb59ea[_0x564045('0x3f')]('users','settingsEnabled',{'type':_0x36ab8e[_0x564045('0x14')],'defaultValue':!![]}),_0xfb59ea['addColumn'](_0x564045('0x3d'),_0x564045('0x6'),{'type':_0x36ab8e[_0x564045('0x14')],'defaultValue':![]}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x3d'),_0x564045('0x3'),{'type':_0x36ab8e['ENUM']('voice'),'allowNull':![],'defaultValue':_0x564045('0x9')}),_0xfb59ea['addColumn']('tools_dispositions',_0x564045('0x38'),{'type':_0x36ab8e[_0x564045('0x1d')](_0x564045('0x18'),_0x564045('0x29'),'third'),'allowNull':![],'defaultValue':_0x564045('0x18'),'after':_0x564045('0x36')}),_0xfb59ea['addColumn'](_0x564045('0x40'),_0x564045('0x43'),{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x38')}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x40'),_0x564045('0x33'),{'type':_0x36ab8e[_0x564045('0x2c')],'after':_0x564045('0x2e')}),_0xfb59ea[_0x564045('0x45')](_0x564045('0xd')),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x47'),'userSecondDisposition',{'type':_0x36ab8e['STRING'],'after':_0x564045('0x1e')}),_0xfb59ea[_0x564045('0x3f')]('report_call',_0x564045('0x21'),{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x12')}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x8'),_0x564045('0x3c'),{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x44')}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x8'),'thirdDisposition',{'type':_0x36ab8e[_0x564045('0x11')],'after':'secondDisposition'}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x1c'),_0x564045('0x12'),{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x1e')}),_0xfb59ea['addColumn']('voice_recordings',_0x564045('0x21'),{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x12')}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x41'),'secondDisposition',{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x44')}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x41'),_0x564045('0x26'),{'type':_0x36ab8e[_0x564045('0x11')],'after':'secondDisposition'}),_0xfb59ea['addColumn'](_0x564045('0x42'),'secondDisposition',{'type':_0x36ab8e[_0x564045('0x11')],'after':'disposition'}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x42'),_0x564045('0x26'),{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x3c')}),_0xfb59ea[_0x564045('0x3f')]('mail_interactions','secondDisposition',{'type':_0x36ab8e['STRING'],'after':_0x564045('0x44')}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x27'),_0x564045('0x26'),{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x3c')}),_0xfb59ea[_0x564045('0x3f')]('openchannel_interactions','secondDisposition',{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x44')}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x35'),_0x564045('0x26'),{'type':_0x36ab8e['STRING'],'after':'secondDisposition'}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x2a'),_0x564045('0x3c'),{'type':_0x36ab8e[_0x564045('0x11')],'after':'disposition'}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x2a'),'thirdDisposition',{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x3c')}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x5'),_0x564045('0x3c'),{'type':_0x36ab8e[_0x564045('0x11')],'after':'disposition'}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x5'),_0x564045('0x26'),{'type':_0x36ab8e[_0x564045('0x11')],'after':_0x564045('0x3c')}),_0xfb59ea['addColumn'](_0x564045('0x34'),_0x564045('0x3c'),{'type':_0x36ab8e['STRING'],'after':'disposition'}),_0xfb59ea[_0x564045('0x3f')](_0x564045('0x34'),_0x564045('0x26'),{'type':_0x36ab8e['STRING'],'after':'secondDisposition'}),_0xfb59ea['final'](_0x160f42);});},'down':function(){}}; \ No newline at end of file +const a1018_0x1a65=['indicesType','passwordHistoryLimit','removeIndex','INTEGER','chat_interactions','ALTER\x20TABLE\x20tools_dispositions\x20ADD\x20CONSTRAINT\x20`tools_dispositions_ibfk_8`\x20FOREIGN\x20KEY\x20(`ParentId`)\x20REFERENCES\x20`tools_dispositions`\x20(`id`)\x20ON\x20DELETE\x20CASCADE\x20ON\x20UPDATE\x20CASCADE','join','voice','migration','query\x20%s','cm_hopper_final','dropTable','exports','third','changeColumn','settings','second','whatsapp_interactions','inspect','tail','removeIndex\x20%s\x20%s','userThirdDisposition','UNSIGNED','prototype','openchannel_interactions','disposition','Added\x20column\x20%s\x20to\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','thirdDisposition','tools_dispositions','Changed\x20column\x20%s\x20in\x20table\x20%s','BOOLEAN','renameColumn','users','mail_interactions','report_call','table\x20dropped\x20%s','first','sms_interactions','fax_interactions','stringify','voice_recordings','finally','ENUM','queryInterface','report_queue','removeColumn','info','settingsEnabled','cm_custom_fields','then','addIndex\x20%s\x20%s\x20%s\x20[%s]','name','indexName','addColumn','actionType','addIndex','catch','../config/logger','secondDisposition','UPDATE\x20tools_actions\x20SET\x20data4\x20=\x20NULL\x20WHERE\x20action\x20=\x20\x27contactManager\x27\x20AND\x20data2\x20=\x20\x270\x27\x20AND\x20data4\x20=\x20\x270\x27','userDisposition','enqueue','level','query','STRING','userSecondDisposition','sequence'];(function(_0x35aeab,_0x1a6560){const _0x5ca5cf=function(_0x5199e9){while(--_0x5199e9){_0x35aeab['push'](_0x35aeab['shift']());}};_0x5ca5cf(++_0x1a6560);}(a1018_0x1a65,0x10c));const a1018_0x5ca5=function(_0x35aeab,_0x1a6560){_0x35aeab=_0x35aeab-0x0;let _0x5ca5cf=a1018_0x1a65[_0x35aeab];return _0x5ca5cf;};const _0x35176e=a1018_0x5ca5;'use strict';const util=require('util'),logger=require(_0x35176e('0x3e'))(_0x35176e('0xc')),Sequence=function(){};Sequence[_0x35176e('0x1b')][_0x35176e('0x42')]=function(_0x5199e9){const _0x3ab1dd=_0x35176e;this[_0x3ab1dd('0x17')]=this[_0x3ab1dd('0x17')]?this['tail'][_0x3ab1dd('0x2e')](_0x5199e9):_0x5199e9();};const Migration=function(_0x4bd78b){const _0x3fdb15=_0x35176e;this[_0x3fdb15('0x30')]=_0x4bd78b,this[_0x3fdb15('0x3')]=new Sequence();};Migration[_0x35176e('0x1b')][_0x35176e('0x12')]=function(_0x229989,_0x1d5c9e,_0x195856){const _0x5b6959=_0x35176e,_0x577862=this;this['sequence'][_0x5b6959('0x42')](function(){const _0x5f073a=_0x5b6959;return _0x577862['queryInterface'][_0x5f073a('0x12')](_0x229989,_0x1d5c9e,_0x195856)['then'](function(){const _0x340e95=_0x5f073a;logger['info'](_0x340e95('0x22'),_0x1d5c9e,_0x229989);})['catch'](function(_0x320ba6){const _0x23683f=_0x5f073a;logger['info'](JSON[_0x23683f('0x2c')](_0x320ba6));});});},Migration[_0x35176e('0x1b')][_0x35176e('0x3a')]=function(_0x7aa84f,_0x4d9eb8,_0x14e13f){const _0x3b9d8b=_0x35176e,_0x555ebe=this;this[_0x3b9d8b('0x3')][_0x3b9d8b('0x42')](function(){const _0x1fc2b5=_0x3b9d8b;return _0x555ebe['queryInterface'][_0x1fc2b5('0x3a')](_0x7aa84f,_0x4d9eb8,_0x14e13f)[_0x1fc2b5('0x36')](function(){const _0x2bdb70=_0x1fc2b5;logger[_0x2bdb70('0x33')](_0x2bdb70('0x1e'),_0x4d9eb8,_0x7aa84f);})['catch'](function(_0x4acb6c){const _0x4ec613=_0x1fc2b5;logger[_0x4ec613('0x33')](JSON[_0x4ec613('0x2c')](_0x4acb6c));});});},Migration[_0x35176e('0x1b')]['dropTable']=function(_0x35088c){const _0x4dc8df=_0x35176e,_0x393af7=this;this[_0x4dc8df('0x3')][_0x4dc8df('0x42')](function(){const _0x4f8c97=_0x4dc8df;return _0x393af7[_0x4f8c97('0x30')][_0x4f8c97('0xf')](_0x35088c,{'force':!![]})['then'](function(){const _0x4e6756=_0x4f8c97;logger[_0x4e6756('0x33')](_0x4e6756('0x28'),_0x35088c);})[_0x4f8c97('0x3d')](function(_0x2de83c){const _0x4c963d=_0x4f8c97;logger[_0x4c963d('0x33')](JSON[_0x4c963d('0x2c')](_0x2de83c));});});},Migration[_0x35176e('0x1b')][_0x35176e('0x3c')]=function(_0x4234e3,_0x73a225,_0x2570c4){const _0x18d02d=_0x35176e,_0x23d2b6=this;this[_0x18d02d('0x3')]['enqueue'](function(){const _0x38a464=_0x18d02d;return _0x23d2b6[_0x38a464('0x30')]['addIndex'](_0x4234e3,_0x73a225,{'indexName':_0x2570c4[_0x38a464('0x39')],'indicesType':_0x2570c4[_0x38a464('0x4')]})[_0x38a464('0x36')](function(){const _0x116c06=_0x38a464;logger[_0x116c06('0x33')](_0x116c06('0x37'),_0x4234e3,_0x73a225[_0x116c06('0xa')](','),_0x2570c4[_0x116c06('0x39')],_0x2570c4['indicesType']);})[_0x38a464('0x3d')](function(_0x574a64){const _0x409f71=_0x38a464;logger[_0x409f71('0x33')](JSON[_0x409f71('0x2c')](_0x574a64));});});},Migration[_0x35176e('0x1b')]['removeIndex']=function(_0x131ba7,_0x293d9c){const _0x567a5b=_0x35176e,_0x41861b=this;this[_0x567a5b('0x3')][_0x567a5b('0x42')](function(){const _0x31685a=_0x567a5b;return _0x41861b[_0x31685a('0x30')][_0x31685a('0x6')](_0x131ba7,_0x293d9c)[_0x31685a('0x36')](function(){const _0x3a2f8a=_0x31685a;logger[_0x3a2f8a('0x33')](_0x3a2f8a('0x18'),_0x131ba7,_0x293d9c);})[_0x31685a('0x3d')](function(_0x126c30){const _0x440a09=_0x31685a;logger[_0x440a09('0x33')](JSON[_0x440a09('0x2c')](_0x126c30));});});},Migration[_0x35176e('0x1b')][_0x35176e('0x0')]=function(_0x4d4d4c){const _0x39de8c=_0x35176e,_0x1299e4=this;this[_0x39de8c('0x3')]['enqueue'](function(){const _0x130daa=_0x39de8c;return _0x1299e4[_0x130daa('0x30')]['sequelize'][_0x130daa('0x0')](_0x4d4d4c)[_0x130daa('0x36')](function(){const _0x3f1d44=_0x130daa;logger[_0x3f1d44('0x33')](_0x3f1d44('0xd'),_0x4d4d4c);})['catch'](function(_0xaf0277){logger['info'](JSON['stringify'](_0xaf0277));});});},Migration[_0x35176e('0x1b')][_0x35176e('0x32')]=function(_0x3b1664,_0x12ba94){const _0x28a06c=_0x35176e,_0x46eed9=this;this[_0x28a06c('0x3')][_0x28a06c('0x42')](function(){const _0x55cc48=_0x28a06c;return _0x46eed9[_0x55cc48('0x30')][_0x55cc48('0x32')](_0x3b1664,_0x12ba94)['then'](function(){const _0x3aa96d=_0x55cc48;logger[_0x3aa96d('0x33')]('Removed\x20column\x20%s\x20from\x20%s',_0x12ba94,_0x3b1664);})[_0x55cc48('0x3d')](function(_0x23dd20){const _0xa85911=_0x55cc48;logger[_0xa85911('0x33')](util[_0xa85911('0x16')](_0x23dd20,{'showHidden':![],'depth':null}));});});},Migration[_0x35176e('0x1b')][_0x35176e('0x24')]=function(_0x59024c,_0x427f48,_0x4c4398){const _0x1b2562=_0x35176e,_0x32fcbb=this;this['sequence'][_0x1b2562('0x42')](function(){const _0x211534=_0x1b2562;return _0x32fcbb[_0x211534('0x30')][_0x211534('0x24')](_0x59024c,_0x427f48,_0x4c4398)[_0x211534('0x36')](function(){const _0x5acec0=_0x211534;logger[_0x5acec0('0x33')](_0x5acec0('0x1f'),_0x427f48,_0x4c4398,_0x59024c);})[_0x211534('0x3d')](function(_0x234c98){const _0x55c656=_0x211534;logger['info'](util[_0x55c656('0x16')](_0x234c98,{'showHidden':![],'depth':null}));});});},Migration[_0x35176e('0x1b')]['final']=function(_0x450698){const _0x3d7128=_0x35176e;this['sequence'][_0x3d7128('0x42')](function(){return _0x450698();});},module[_0x35176e('0x10')]={'up':function(_0x41f7db,_0x1b9246){return new Promise(function(_0x38515a){const _0x331ed2=a1018_0x5ca5,_0x4f498d=new Migration(_0x41f7db);_0x4f498d[_0x331ed2('0x0')]('UPDATE\x20tools_actions\x20SET\x20data3\x20=\x20\x27phone\x27\x20WHERE\x20action\x20=\x20\x27contactManager\x27\x20AND\x20data3\x20=\x20\x270\x27'),_0x4f498d[_0x331ed2('0x0')](_0x331ed2('0x40')),_0x4f498d[_0x331ed2('0x0')]('UPDATE\x20tools_actions\x20SET\x20data4\x20=\x20\x27phone\x27\x20WHERE\x20action\x20=\x20\x27contactManager\x27\x20AND\x20data4\x20=\x20\x270\x27'),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x13'),'enforcePasswordHistory',{'type':_0x1b9246[_0x331ed2('0x23')],'defaultValue':!![]}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x13'),_0x331ed2('0x5'),{'type':_0x1b9246[_0x331ed2('0x7')](0x2)[_0x331ed2('0x1a')],'defaultValue':0x3,'validate':{'min':0x1,'max':0x5}}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x25'),'previousPasswords',{'type':_0x1b9246['STRING'],'after':'passwordResetAt'}),_0x4f498d['addColumn'](_0x331ed2('0x25'),_0x331ed2('0x34'),{'type':_0x1b9246[_0x331ed2('0x23')],'defaultValue':!![]}),_0x4f498d[_0x331ed2('0x3a')]('cm_custom_fields','clickToAction',{'type':_0x1b9246[_0x331ed2('0x23')],'defaultValue':![]}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x35'),_0x331ed2('0x3b'),{'type':_0x1b9246[_0x331ed2('0x2f')](_0x331ed2('0xb')),'allowNull':![],'defaultValue':'voice'}),_0x4f498d['addColumn'](_0x331ed2('0x21'),'level',{'type':_0x1b9246[_0x331ed2('0x2f')](_0x331ed2('0x29'),_0x331ed2('0x14'),_0x331ed2('0x11')),'allowNull':![],'defaultValue':_0x331ed2('0x29'),'after':_0x331ed2('0x38')}),_0x4f498d[_0x331ed2('0x3a')]('tools_dispositions','description',{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x43')}),_0x4f498d['addColumn']('tools_dispositions','ParentId',{'type':_0x1b9246[_0x331ed2('0x7')],'after':'updatedAt'}),_0x4f498d[_0x331ed2('0x0')](_0x331ed2('0x9')),_0x4f498d['addColumn'](_0x331ed2('0x27'),_0x331ed2('0x2'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x41')}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x27'),_0x331ed2('0x19'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x2')}),_0x4f498d[_0x331ed2('0x3a')]('report_queue',_0x331ed2('0x3f'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':'disposition'}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x31'),_0x331ed2('0x20'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x3f')}),_0x4f498d['addColumn'](_0x331ed2('0x2d'),_0x331ed2('0x2'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x41')}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x2d'),_0x331ed2('0x19'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x2')}),_0x4f498d[_0x331ed2('0x3a')]('chat_interactions',_0x331ed2('0x3f'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x1d')}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x8'),'thirdDisposition',{'type':_0x1b9246[_0x331ed2('0x1')],'after':'secondDisposition'}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x2b'),_0x331ed2('0x3f'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':'disposition'}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x2b'),_0x331ed2('0x20'),{'type':_0x1b9246['STRING'],'after':'secondDisposition'}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x26'),_0x331ed2('0x3f'),{'type':_0x1b9246['STRING'],'after':_0x331ed2('0x1d')}),_0x4f498d['addColumn'](_0x331ed2('0x26'),_0x331ed2('0x20'),{'type':_0x1b9246['STRING'],'after':_0x331ed2('0x3f')}),_0x4f498d['addColumn']('openchannel_interactions','secondDisposition',{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x1d')}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x1c'),_0x331ed2('0x20'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x3f')}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x2a'),_0x331ed2('0x3f'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x1d')}),_0x4f498d['addColumn'](_0x331ed2('0x2a'),_0x331ed2('0x20'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':'secondDisposition'}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x15'),_0x331ed2('0x3f'),{'type':_0x1b9246['STRING'],'after':_0x331ed2('0x1d')}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0x15'),_0x331ed2('0x20'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x3f')}),_0x4f498d[_0x331ed2('0x3a')](_0x331ed2('0xe'),_0x331ed2('0x3f'),{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x1d')}),_0x4f498d[_0x331ed2('0x3a')]('cm_hopper_final','thirdDisposition',{'type':_0x1b9246[_0x331ed2('0x1')],'after':_0x331ed2('0x3f')}),_0x4f498d['final'](_0x38515a);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.5.6.js b/server/migrations/2.5.6.js index a626db9..194eb58 100644 --- a/server/migrations/2.5.6.js +++ b/server/migrations/2.5.6.js @@ -1 +1 @@ -const a1019_0x1413=['sequence','mobile','inspect','removeIndex','prototype','indicesType','util','addIndex\x20%s\x20%s\x20%s\x20[%s]','migration','renameColumn','exports','addColumn','removeColumn','changeColumn','lastName','info','email','phone','FULLTEXT','cm_contacts','queryInterface','then','query','stringify','table\x20dropped\x20%s','final','dropTable','join','addIndex','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','finally','enqueue','indexName','catch','firstName','query\x20%s','fax','Added\x20column\x20%s\x20to\x20%s','tail','sequelize'];(function(_0x159a07,_0x1413f8){const _0x457018=function(_0x1b5324){while(--_0x1b5324){_0x159a07['push'](_0x159a07['shift']());}};_0x457018(++_0x1413f8);}(a1019_0x1413,0x96));const a1019_0x4570=function(_0x159a07,_0x1413f8){_0x159a07=_0x159a07-0x0;let _0x457018=a1019_0x1413[_0x159a07];return _0x457018;};const _0x182991=a1019_0x4570;'use strict';const util=require(_0x182991('0x10')),logger=require('../config/logger')(_0x182991('0x12')),Sequence=function(){};Sequence['prototype'][_0x182991('0x1')]=function(_0x1b5324){const _0x595576=_0x182991;this[_0x595576('0x8')]=this['tail']?this[_0x595576('0x8')][_0x595576('0x0')](_0x1b5324):_0x1b5324();};const Migration=function(_0x23ac77){const _0x1f9285=_0x182991;this[_0x1f9285('0x1e')]=_0x23ac77,this[_0x1f9285('0xa')]=new Sequence();};Migration[_0x182991('0xe')][_0x182991('0x17')]=function(_0x31cba9,_0x26761e,_0x2a2075){const _0x277c2c=_0x182991,_0x146d9a=this;this[_0x277c2c('0xa')][_0x277c2c('0x1')](function(){const _0xdef1cd=_0x277c2c;return _0x146d9a['queryInterface'][_0xdef1cd('0x17')](_0x31cba9,_0x26761e,_0x2a2075)[_0xdef1cd('0x1f')](function(){const _0x149db8=_0xdef1cd;logger[_0x149db8('0x19')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x26761e,_0x31cba9);})[_0xdef1cd('0x3')](function(_0x5f4e5e){const _0x526879=_0xdef1cd;logger[_0x526879('0x19')](JSON[_0x526879('0x21')](_0x5f4e5e));});});},Migration[_0x182991('0xe')]['addColumn']=function(_0xe6057a,_0x2fa029,_0x3c4c28){const _0x238c15=_0x182991,_0x5d1ab9=this;this[_0x238c15('0xa')][_0x238c15('0x1')](function(){const _0x89606c=_0x238c15;return _0x5d1ab9['queryInterface'][_0x89606c('0x15')](_0xe6057a,_0x2fa029,_0x3c4c28)[_0x89606c('0x1f')](function(){const _0x266be3=_0x89606c;logger[_0x266be3('0x19')](_0x266be3('0x7'),_0x2fa029,_0xe6057a);})[_0x89606c('0x3')](function(_0x4dfa4e){const _0x115498=_0x89606c;logger[_0x115498('0x19')](JSON[_0x115498('0x21')](_0x4dfa4e));});});},Migration[_0x182991('0xe')][_0x182991('0x24')]=function(_0x2a4425){const _0x55c03c=_0x182991,_0x34392b=this;this['sequence'][_0x55c03c('0x1')](function(){const _0x54237e=_0x55c03c;return _0x34392b['queryInterface'][_0x54237e('0x24')](_0x2a4425,{'force':!![]})[_0x54237e('0x1f')](function(){const _0x25ebc6=_0x54237e;logger[_0x25ebc6('0x19')](_0x25ebc6('0x22'),_0x2a4425);})[_0x54237e('0x3')](function(_0x494b93){const _0x3f7817=_0x54237e;logger[_0x3f7817('0x19')](JSON[_0x3f7817('0x21')](_0x494b93));});});},Migration[_0x182991('0xe')]['addIndex']=function(_0x431895,_0x3c084a,_0x45e5b6){const _0x4f88cc=_0x182991,_0x3cd675=this;this[_0x4f88cc('0xa')][_0x4f88cc('0x1')](function(){const _0x2ba660=_0x4f88cc;return _0x3cd675[_0x2ba660('0x1e')][_0x2ba660('0x26')](_0x431895,_0x3c084a,{'indexName':_0x45e5b6[_0x2ba660('0x2')],'indicesType':_0x45e5b6[_0x2ba660('0xf')]})['then'](function(){const _0x2301a5=_0x2ba660;logger[_0x2301a5('0x19')](_0x2301a5('0x11'),_0x431895,_0x3c084a[_0x2301a5('0x25')](','),_0x45e5b6[_0x2301a5('0x2')],_0x45e5b6[_0x2301a5('0xf')]);})[_0x2ba660('0x3')](function(_0x382cb8){const _0x5b1ee3=_0x2ba660;logger[_0x5b1ee3('0x19')](JSON['stringify'](_0x382cb8));});});},Migration[_0x182991('0xe')][_0x182991('0xd')]=function(_0x45f5c6,_0x537e7f){const _0xfc47d9=_0x182991,_0x1dde04=this;this[_0xfc47d9('0xa')]['enqueue'](function(){const _0x33d93b=_0xfc47d9;return _0x1dde04['queryInterface']['removeIndex'](_0x45f5c6,_0x537e7f)[_0x33d93b('0x1f')](function(){const _0x26d03d=_0x33d93b;logger[_0x26d03d('0x19')]('removeIndex\x20%s\x20%s',_0x45f5c6,_0x537e7f);})[_0x33d93b('0x3')](function(_0x337e33){const _0x29ed36=_0x33d93b;logger[_0x29ed36('0x19')](JSON[_0x29ed36('0x21')](_0x337e33));});});},Migration[_0x182991('0xe')][_0x182991('0x20')]=function(_0x44b713){const _0xa3db0b=_0x182991,_0x16f2f5=this;this['sequence'][_0xa3db0b('0x1')](function(){const _0x27ea0d=_0xa3db0b;return _0x16f2f5[_0x27ea0d('0x1e')][_0x27ea0d('0x9')][_0x27ea0d('0x20')](_0x44b713)[_0x27ea0d('0x1f')](function(){const _0x199e7c=_0x27ea0d;logger['info'](_0x199e7c('0x5'),_0x44b713);})[_0x27ea0d('0x3')](function(_0x43b18f){const _0x182045=_0x27ea0d;logger[_0x182045('0x19')](JSON[_0x182045('0x21')](_0x43b18f));});});},Migration['prototype'][_0x182991('0x16')]=function(_0x4ed632,_0x14e8c2){const _0x5746ea=_0x182991,_0x5ddb35=this;this[_0x5746ea('0xa')][_0x5746ea('0x1')](function(){const _0x22e44d=_0x5746ea;return _0x5ddb35[_0x22e44d('0x1e')][_0x22e44d('0x16')](_0x4ed632,_0x14e8c2)[_0x22e44d('0x1f')](function(){const _0x271206=_0x22e44d;logger[_0x271206('0x19')]('Removed\x20column\x20%s\x20from\x20%s',_0x14e8c2,_0x4ed632);})['catch'](function(_0x50aa43){const _0x427de2=_0x22e44d;logger[_0x427de2('0x19')](util[_0x427de2('0xc')](_0x50aa43,{'showHidden':![],'depth':null}));});});},Migration[_0x182991('0xe')]['renameColumn']=function(_0x4729f1,_0x3fc838,_0x20550d){const _0x1dfd2=_0x182991,_0x326ecb=this;this['sequence'][_0x1dfd2('0x1')](function(){const _0x587f70=_0x1dfd2;return _0x326ecb['queryInterface'][_0x587f70('0x13')](_0x4729f1,_0x3fc838,_0x20550d)[_0x587f70('0x1f')](function(){const _0x1c016c=_0x587f70;logger[_0x1c016c('0x19')](_0x1c016c('0x27'),_0x3fc838,_0x20550d,_0x4729f1);})['catch'](function(_0x460369){const _0x4eb01d=_0x587f70;logger[_0x4eb01d('0x19')](util[_0x4eb01d('0xc')](_0x460369,{'showHidden':![],'depth':null}));});});},Migration[_0x182991('0xe')][_0x182991('0x23')]=function(_0x2c998d){const _0x2a6b67=_0x182991;this[_0x2a6b67('0xa')]['enqueue'](function(){return _0x2c998d();});},module[_0x182991('0x14')]={'up':function(_0x23f8b0){return new Promise(function(_0xb38fcf){const _0x4cf8c7=a1019_0x4570,_0x48c78e=new Migration(_0x23f8b0);_0x48c78e[_0x4cf8c7('0x26')](_0x4cf8c7('0x1d'),[_0x4cf8c7('0x4'),_0x4cf8c7('0x18'),_0x4cf8c7('0x1b'),_0x4cf8c7('0xb'),_0x4cf8c7('0x6'),_0x4cf8c7('0x1a')],{'indexName':'fti_cm_contacts','indicesType':_0x4cf8c7('0x1c')}),_0x48c78e[_0x4cf8c7('0x23')](_0xb38fcf);});},'down':function(){}}; \ No newline at end of file +const a1019_0x3ee3=['enqueue','sequelize','prototype','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','info','finally','queryInterface','FULLTEXT','exports','indicesType','join','addIndex\x20%s\x20%s\x20%s\x20[%s]','renameColumn','stringify','removeColumn','catch','changeColumn','util','phone','migration','sequence','Added\x20column\x20%s\x20to\x20%s','inspect','addColumn','addIndex','table\x20dropped\x20%s','removeIndex','tail','Removed\x20column\x20%s\x20from\x20%s','firstName','fax','final','indexName','query','then','../config/logger','dropTable'];(function(_0x56b9ef,_0x3ee317){const _0x3f49f2=function(_0x485b83){while(--_0x485b83){_0x56b9ef['push'](_0x56b9ef['shift']());}};_0x3f49f2(++_0x3ee317);}(a1019_0x3ee3,0x11e));const a1019_0x3f49=function(_0x56b9ef,_0x3ee317){_0x56b9ef=_0x56b9ef-0x0;let _0x3f49f2=a1019_0x3ee3[_0x56b9ef];return _0x3f49f2;};const _0x45f23e=a1019_0x3f49;'use strict';const util=require(_0x45f23e('0x1b')),logger=require(_0x45f23e('0x8'))(_0x45f23e('0x1d')),Sequence=function(){};Sequence[_0x45f23e('0xc')][_0x45f23e('0xa')]=function(_0x485b83){const _0x368489=_0x45f23e;this['tail']=this[_0x368489('0x0')]?this[_0x368489('0x0')][_0x368489('0xf')](_0x485b83):_0x485b83();};const Migration=function(_0x30e76d){const _0x55e15e=_0x45f23e;this[_0x55e15e('0x10')]=_0x30e76d,this[_0x55e15e('0x1e')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x40afea,_0x5acd07,_0x52a580){const _0x1218f8=_0x45f23e,_0x1e21cd=this;this[_0x1218f8('0x1e')]['enqueue'](function(){const _0x5ee603=_0x1218f8;return _0x1e21cd[_0x5ee603('0x10')][_0x5ee603('0x1a')](_0x40afea,_0x5acd07,_0x52a580)[_0x5ee603('0x7')](function(){const _0x36bc9f=_0x5ee603;logger[_0x36bc9f('0xe')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0x5acd07,_0x40afea);})['catch'](function(_0x1063f0){const _0x2a3bcd=_0x5ee603;logger[_0x2a3bcd('0xe')](JSON[_0x2a3bcd('0x17')](_0x1063f0));});});},Migration[_0x45f23e('0xc')][_0x45f23e('0x21')]=function(_0x397839,_0x5f42a0,_0x529eb6){const _0x203ba3=_0x45f23e,_0x8dbf6e=this;this[_0x203ba3('0x1e')][_0x203ba3('0xa')](function(){const _0x416142=_0x203ba3;return _0x8dbf6e[_0x416142('0x10')]['addColumn'](_0x397839,_0x5f42a0,_0x529eb6)[_0x416142('0x7')](function(){const _0x131613=_0x416142;logger[_0x131613('0xe')](_0x131613('0x1f'),_0x5f42a0,_0x397839);})[_0x416142('0x19')](function(_0x33445e){const _0x8c5b3=_0x416142;logger[_0x8c5b3('0xe')](JSON[_0x8c5b3('0x17')](_0x33445e));});});},Migration[_0x45f23e('0xc')][_0x45f23e('0x9')]=function(_0x306bf1){const _0x4c5f16=_0x45f23e,_0x1eed19=this;this[_0x4c5f16('0x1e')][_0x4c5f16('0xa')](function(){const _0x4f283e=_0x4c5f16;return _0x1eed19[_0x4f283e('0x10')]['dropTable'](_0x306bf1,{'force':!![]})[_0x4f283e('0x7')](function(){const _0x2160f5=_0x4f283e;logger[_0x2160f5('0xe')](_0x2160f5('0x23'),_0x306bf1);})['catch'](function(_0x581f53){const _0x33f690=_0x4f283e;logger[_0x33f690('0xe')](JSON[_0x33f690('0x17')](_0x581f53));});});},Migration['prototype']['addIndex']=function(_0x246763,_0x1684af,_0x5b836a){const _0x3983b5=_0x45f23e,_0x133698=this;this['sequence'][_0x3983b5('0xa')](function(){const _0x117615=_0x3983b5;return _0x133698[_0x117615('0x10')]['addIndex'](_0x246763,_0x1684af,{'indexName':_0x5b836a[_0x117615('0x5')],'indicesType':_0x5b836a['indicesType']})['then'](function(){const _0x335761=_0x117615;logger[_0x335761('0xe')](_0x335761('0x15'),_0x246763,_0x1684af[_0x335761('0x14')](','),_0x5b836a['indexName'],_0x5b836a[_0x335761('0x13')]);})['catch'](function(_0x428b6a){const _0x56b512=_0x117615;logger[_0x56b512('0xe')](JSON[_0x56b512('0x17')](_0x428b6a));});});},Migration[_0x45f23e('0xc')][_0x45f23e('0x24')]=function(_0x149215,_0x295d23){const _0x26edb0=_0x45f23e,_0x3fe18c=this;this[_0x26edb0('0x1e')][_0x26edb0('0xa')](function(){const _0x3f32e3=_0x26edb0;return _0x3fe18c['queryInterface'][_0x3f32e3('0x24')](_0x149215,_0x295d23)['then'](function(){logger['info']('removeIndex\x20%s\x20%s',_0x149215,_0x295d23);})[_0x3f32e3('0x19')](function(_0x2ce146){logger['info'](JSON['stringify'](_0x2ce146));});});},Migration['prototype']['query']=function(_0x5d7b54){const _0x2cbe6a=_0x45f23e,_0xadfdc=this;this[_0x2cbe6a('0x1e')][_0x2cbe6a('0xa')](function(){const _0x245f04=_0x2cbe6a;return _0xadfdc['queryInterface'][_0x245f04('0xb')][_0x245f04('0x6')](_0x5d7b54)['then'](function(){const _0x160101=_0x245f04;logger[_0x160101('0xe')]('query\x20%s',_0x5d7b54);})[_0x245f04('0x19')](function(_0x4aab5f){const _0x382046=_0x245f04;logger['info'](JSON[_0x382046('0x17')](_0x4aab5f));});});},Migration['prototype']['removeColumn']=function(_0x1add59,_0x3d118c){const _0x2b6d52=_0x45f23e,_0x43fac7=this;this[_0x2b6d52('0x1e')][_0x2b6d52('0xa')](function(){const _0x501406=_0x2b6d52;return _0x43fac7[_0x501406('0x10')][_0x501406('0x18')](_0x1add59,_0x3d118c)['then'](function(){const _0x5d0e44=_0x501406;logger[_0x5d0e44('0xe')](_0x5d0e44('0x1'),_0x3d118c,_0x1add59);})[_0x501406('0x19')](function(_0x83b2b6){const _0xda28ae=_0x501406;logger[_0xda28ae('0xe')](util[_0xda28ae('0x20')](_0x83b2b6,{'showHidden':![],'depth':null}));});});},Migration[_0x45f23e('0xc')][_0x45f23e('0x16')]=function(_0xb97ac8,_0x3c75d2,_0xf2dea2){const _0x511c29=_0x45f23e,_0x1aa8db=this;this[_0x511c29('0x1e')][_0x511c29('0xa')](function(){const _0x118aef=_0x511c29;return _0x1aa8db['queryInterface'][_0x118aef('0x16')](_0xb97ac8,_0x3c75d2,_0xf2dea2)[_0x118aef('0x7')](function(){const _0x20765e=_0x118aef;logger['info'](_0x20765e('0xd'),_0x3c75d2,_0xf2dea2,_0xb97ac8);})['catch'](function(_0x85a096){const _0x56d9de=_0x118aef;logger[_0x56d9de('0xe')](util[_0x56d9de('0x20')](_0x85a096,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x380e36){const _0x3e341b=_0x45f23e;this[_0x3e341b('0x1e')][_0x3e341b('0xa')](function(){return _0x380e36();});},module[_0x45f23e('0x12')]={'up':function(_0x1bf4ea){return new Promise(function(_0x1bb6f7){const _0x15764f=a1019_0x3f49,_0x55d27f=new Migration(_0x1bf4ea);_0x55d27f[_0x15764f('0x22')]('cm_contacts',[_0x15764f('0x2'),'lastName',_0x15764f('0x1c'),'mobile',_0x15764f('0x3'),'email'],{'indexName':'fti_cm_contacts','indicesType':_0x15764f('0x11')}),_0x55d27f[_0x15764f('0x4')](_0x1bb6f7);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/2.5.7.js b/server/migrations/2.5.7.js index 53a34fb..bb57b66 100644 --- a/server/migrations/2.5.7.js +++ b/server/migrations/2.5.7.js @@ -1 +1 @@ -const a1020_0x13ec=['openchannel_messages','sequelize','addColumn','Added\x20column\x20%s\x20to\x20%s','../config/logger','removeIndex','renameColumn','providerName','indexName','removeColumn','TEXT','addIndex\x20%s\x20%s\x20%s\x20[%s]','whatsapp_messages','tail','indicesType','square_messages','finally','STRING','migration','inspect','chat_messages','catch','enqueue','removeIndex\x20%s\x20%s','prototype','Changed\x20column\x20%s\x20in\x20table\x20%s','stringify','addIndex','dropTable','then','util','exports','join','sequence','info','queryInterface','changeColumn','table\x20dropped\x20%s','query','providerResponse'];(function(_0x126ec0,_0x13ec23){const _0x15286b=function(_0x4afe3d){while(--_0x4afe3d){_0x126ec0['push'](_0x126ec0['shift']());}};_0x15286b(++_0x13ec23);}(a1020_0x13ec,0x1c3));const a1020_0x1528=function(_0x126ec0,_0x13ec23){_0x126ec0=_0x126ec0-0x0;let _0x15286b=a1020_0x13ec[_0x126ec0];return _0x15286b;};const _0x246e2d=a1020_0x1528;'use strict';const util=require(_0x246e2d('0x13')),logger=require(_0x246e2d('0x21'))(_0x246e2d('0x7')),Sequence=function(){};Sequence[_0x246e2d('0xd')][_0x246e2d('0xb')]=function(_0x4afe3d){const _0x18509d=_0x246e2d;this[_0x18509d('0x2')]=this['tail']?this[_0x18509d('0x2')][_0x18509d('0x5')](_0x4afe3d):_0x4afe3d();};const Migration=function(_0x311838){const _0x34a0ae=_0x246e2d;this[_0x34a0ae('0x18')]=_0x311838,this[_0x34a0ae('0x16')]=new Sequence();};Migration['prototype']['changeColumn']=function(_0x1c0d7f,_0x13ae05,_0xca0b30){const _0x27e8b8=_0x246e2d,_0x141aa1=this;this[_0x27e8b8('0x16')][_0x27e8b8('0xb')](function(){const _0x22be96=_0x27e8b8;return _0x141aa1['queryInterface'][_0x22be96('0x19')](_0x1c0d7f,_0x13ae05,_0xca0b30)[_0x22be96('0x12')](function(){const _0x5cdb90=_0x22be96;logger[_0x5cdb90('0x17')](_0x5cdb90('0xe'),_0x13ae05,_0x1c0d7f);})[_0x22be96('0xa')](function(_0x181517){const _0x48c15e=_0x22be96;logger[_0x48c15e('0x17')](JSON[_0x48c15e('0xf')](_0x181517));});});},Migration['prototype'][_0x246e2d('0x1f')]=function(_0x3d29d6,_0x261a48,_0x36e233){const _0x53f468=_0x246e2d,_0x428241=this;this[_0x53f468('0x16')]['enqueue'](function(){const _0x452cea=_0x53f468;return _0x428241[_0x452cea('0x18')][_0x452cea('0x1f')](_0x3d29d6,_0x261a48,_0x36e233)[_0x452cea('0x12')](function(){const _0x4e926e=_0x452cea;logger[_0x4e926e('0x17')](_0x4e926e('0x20'),_0x261a48,_0x3d29d6);})[_0x452cea('0xa')](function(_0x4df58c){const _0x57fbb7=_0x452cea;logger['info'](JSON[_0x57fbb7('0xf')](_0x4df58c));});});},Migration[_0x246e2d('0xd')][_0x246e2d('0x11')]=function(_0x38cbde){const _0xf5d196=_0x246e2d,_0x14fd86=this;this['sequence'][_0xf5d196('0xb')](function(){const _0x525147=_0xf5d196;return _0x14fd86[_0x525147('0x18')]['dropTable'](_0x38cbde,{'force':!![]})['then'](function(){const _0xeb6b8b=_0x525147;logger[_0xeb6b8b('0x17')](_0xeb6b8b('0x1a'),_0x38cbde);})['catch'](function(_0x3b1564){const _0x3c0b6e=_0x525147;logger[_0x3c0b6e('0x17')](JSON[_0x3c0b6e('0xf')](_0x3b1564));});});},Migration[_0x246e2d('0xd')][_0x246e2d('0x10')]=function(_0x10c840,_0x54d3ce,_0x21e66e){const _0x423ef1=_0x246e2d,_0x19664e=this;this['sequence'][_0x423ef1('0xb')](function(){const _0x4b2b96=_0x423ef1;return _0x19664e[_0x4b2b96('0x18')][_0x4b2b96('0x10')](_0x10c840,_0x54d3ce,{'indexName':_0x21e66e[_0x4b2b96('0x25')],'indicesType':_0x21e66e[_0x4b2b96('0x3')]})[_0x4b2b96('0x12')](function(){const _0x33ab24=_0x4b2b96;logger[_0x33ab24('0x17')](_0x33ab24('0x0'),_0x10c840,_0x54d3ce[_0x33ab24('0x15')](','),_0x21e66e[_0x33ab24('0x25')],_0x21e66e[_0x33ab24('0x3')]);})[_0x4b2b96('0xa')](function(_0xe0db6d){const _0x3344bf=_0x4b2b96;logger[_0x3344bf('0x17')](JSON[_0x3344bf('0xf')](_0xe0db6d));});});},Migration[_0x246e2d('0xd')][_0x246e2d('0x22')]=function(_0xc4861e,_0x4e7cf8){const _0x255cd1=_0x246e2d,_0x459139=this;this['sequence'][_0x255cd1('0xb')](function(){const _0x158847=_0x255cd1;return _0x459139['queryInterface'][_0x158847('0x22')](_0xc4861e,_0x4e7cf8)[_0x158847('0x12')](function(){const _0x41e590=_0x158847;logger[_0x41e590('0x17')](_0x41e590('0xc'),_0xc4861e,_0x4e7cf8);})[_0x158847('0xa')](function(_0x163c3f){const _0x5ceeff=_0x158847;logger[_0x5ceeff('0x17')](JSON[_0x5ceeff('0xf')](_0x163c3f));});});},Migration[_0x246e2d('0xd')][_0x246e2d('0x1b')]=function(_0x59d8e2){const _0x43b842=_0x246e2d,_0xcd316f=this;this['sequence'][_0x43b842('0xb')](function(){const _0x1777fc=_0x43b842;return _0xcd316f[_0x1777fc('0x18')][_0x1777fc('0x1e')][_0x1777fc('0x1b')](_0x59d8e2)[_0x1777fc('0x12')](function(){const _0xfd25f2=_0x1777fc;logger[_0xfd25f2('0x17')]('query\x20%s',_0x59d8e2);})['catch'](function(_0x44350b){const _0x4356c8=_0x1777fc;logger[_0x4356c8('0x17')](JSON['stringify'](_0x44350b));});});},Migration[_0x246e2d('0xd')]['removeColumn']=function(_0x4f3858,_0x1e159d){const _0x493b31=_0x246e2d,_0x101398=this;this[_0x493b31('0x16')][_0x493b31('0xb')](function(){const _0x4ce429=_0x493b31;return _0x101398[_0x4ce429('0x18')][_0x4ce429('0x26')](_0x4f3858,_0x1e159d)[_0x4ce429('0x12')](function(){const _0x5732c5=_0x4ce429;logger[_0x5732c5('0x17')]('Removed\x20column\x20%s\x20from\x20%s',_0x1e159d,_0x4f3858);})[_0x4ce429('0xa')](function(_0x5d0dda){const _0x378b68=_0x4ce429;logger[_0x378b68('0x17')](util[_0x378b68('0x8')](_0x5d0dda,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x246e2d('0x23')]=function(_0x10ff77,_0x34c500,_0x5ebff0){const _0x105985=_0x246e2d,_0x25e7eb=this;this[_0x105985('0x16')]['enqueue'](function(){const _0x4f1ab0=_0x105985;return _0x25e7eb[_0x4f1ab0('0x18')][_0x4f1ab0('0x23')](_0x10ff77,_0x34c500,_0x5ebff0)[_0x4f1ab0('0x12')](function(){logger['info']('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x34c500,_0x5ebff0,_0x10ff77);})[_0x4f1ab0('0xa')](function(_0x94c21){const _0x4ea9d1=_0x4f1ab0;logger['info'](util[_0x4ea9d1('0x8')](_0x94c21,{'showHidden':![],'depth':null}));});});},Migration[_0x246e2d('0xd')]['final']=function(_0xb1eb53){const _0x29f7dd=_0x246e2d;this[_0x29f7dd('0x16')][_0x29f7dd('0xb')](function(){return _0xb1eb53();});},module[_0x246e2d('0x14')]={'up':function(_0x49413,_0x3540a0){return new Promise(function(_0x47c463){const _0x5583d9=a1020_0x1528,_0x244636=new Migration(_0x49413);_0x244636[_0x5583d9('0x1f')](_0x5583d9('0x9'),_0x5583d9('0x24'),{'type':_0x3540a0[_0x5583d9('0x6')]}),_0x244636[_0x5583d9('0x1f')](_0x5583d9('0x9'),_0x5583d9('0x1c'),{'type':_0x3540a0['TEXT']}),_0x244636[_0x5583d9('0x1f')](_0x5583d9('0x1d'),'providerName',{'type':_0x3540a0[_0x5583d9('0x6')]}),_0x244636[_0x5583d9('0x1f')](_0x5583d9('0x1d'),_0x5583d9('0x1c'),{'type':_0x3540a0[_0x5583d9('0x27')]}),_0x244636[_0x5583d9('0x1f')]('sms_messages',_0x5583d9('0x24'),{'type':_0x3540a0[_0x5583d9('0x6')]}),_0x244636['addColumn']('sms_messages',_0x5583d9('0x1c'),{'type':_0x3540a0[_0x5583d9('0x27')]}),_0x244636['addColumn'](_0x5583d9('0x1'),_0x5583d9('0x24'),{'type':_0x3540a0[_0x5583d9('0x6')]}),_0x244636[_0x5583d9('0x1f')](_0x5583d9('0x1'),_0x5583d9('0x1c'),{'type':_0x3540a0[_0x5583d9('0x27')]}),_0x244636['addColumn'](_0x5583d9('0x4'),_0x5583d9('0x24'),{'type':_0x3540a0['STRING']}),_0x244636[_0x5583d9('0x1f')]('square_messages','providerResponse',{'type':_0x3540a0[_0x5583d9('0x27')]}),_0x244636['final'](_0x47c463);});},'down':function(){}}; \ No newline at end of file +const a1020_0x3ce0=['dropTable','chat_messages','enqueue','sequelize','Changed\x20column\x20%s\x20in\x20table\x20%s','final','queryInterface','TEXT','removeColumn','addIndex\x20%s\x20%s\x20%s\x20[%s]','sms_messages','prototype','then','addIndex','sequence','Added\x20column\x20%s\x20to\x20%s','exports','query','removeIndex','query\x20%s','info','addColumn','removeIndex\x20%s\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Removed\x20column\x20%s\x20from\x20%s','catch','migration','renameColumn','indexName','square_messages','join','providerResponse','openchannel_messages','changeColumn','indicesType','STRING','stringify','tail','finally','providerName','whatsapp_messages'];(function(_0x55ac05,_0x3ce0fd){const _0x3ff6f6=function(_0x13c493){while(--_0x13c493){_0x55ac05['push'](_0x55ac05['shift']());}};_0x3ff6f6(++_0x3ce0fd);}(a1020_0x3ce0,0x1f4));const a1020_0x3ff6=function(_0x55ac05,_0x3ce0fd){_0x55ac05=_0x55ac05-0x0;let _0x3ff6f6=a1020_0x3ce0[_0x55ac05];return _0x3ff6f6;};const _0x493408=a1020_0x3ff6;'use strict';const util=require('util'),logger=require('../config/logger')(_0x493408('0x12')),Sequence=function(){};Sequence[_0x493408('0x3')][_0x493408('0x23')]=function(_0x13c493){const _0x579c27=_0x493408;this[_0x579c27('0x1d')]=this['tail']?this['tail'][_0x579c27('0x1e')](_0x13c493):_0x13c493();};const Migration=function(_0x1c6417){const _0x151431=_0x493408;this[_0x151431('0x27')]=_0x1c6417,this[_0x151431('0x6')]=new Sequence();};Migration['prototype'][_0x493408('0x19')]=function(_0x1ca08c,_0x1ef90a,_0x2ccd57){const _0x172fe6=_0x493408,_0x3b14bd=this;this['sequence'][_0x172fe6('0x23')](function(){const _0x260bf9=_0x172fe6;return _0x3b14bd[_0x260bf9('0x27')][_0x260bf9('0x19')](_0x1ca08c,_0x1ef90a,_0x2ccd57)[_0x260bf9('0x4')](function(){const _0x6f2186=_0x260bf9;logger['info'](_0x6f2186('0x25'),_0x1ef90a,_0x1ca08c);})[_0x260bf9('0x11')](function(_0x27277f){const _0x45a04b=_0x260bf9;logger['info'](JSON[_0x45a04b('0x1c')](_0x27277f));});});},Migration['prototype'][_0x493408('0xd')]=function(_0x1c2e4d,_0xabe284,_0x2d503){const _0x524aa4=_0x493408,_0x3ed562=this;this[_0x524aa4('0x6')][_0x524aa4('0x23')](function(){const _0x22344e=_0x524aa4;return _0x3ed562[_0x22344e('0x27')]['addColumn'](_0x1c2e4d,_0xabe284,_0x2d503)['then'](function(){const _0x3d0afa=_0x22344e;logger['info'](_0x3d0afa('0x7'),_0xabe284,_0x1c2e4d);})['catch'](function(_0x5835a9){const _0xb43193=_0x22344e;logger[_0xb43193('0xc')](JSON[_0xb43193('0x1c')](_0x5835a9));});});},Migration['prototype'][_0x493408('0x21')]=function(_0x3f77fb){const _0x4730a6=_0x493408,_0x503760=this;this['sequence'][_0x4730a6('0x23')](function(){const _0x42c648=_0x4730a6;return _0x503760['queryInterface'][_0x42c648('0x21')](_0x3f77fb,{'force':!![]})[_0x42c648('0x4')](function(){logger['info']('table\x20dropped\x20%s',_0x3f77fb);})[_0x42c648('0x11')](function(_0x2bfd43){const _0x14f47b=_0x42c648;logger[_0x14f47b('0xc')](JSON['stringify'](_0x2bfd43));});});},Migration['prototype'][_0x493408('0x5')]=function(_0x478fd1,_0x510344,_0x10947f){const _0x57a1f8=_0x493408,_0x1c3cf2=this;this[_0x57a1f8('0x6')]['enqueue'](function(){const _0x475784=_0x57a1f8;return _0x1c3cf2['queryInterface']['addIndex'](_0x478fd1,_0x510344,{'indexName':_0x10947f[_0x475784('0x14')],'indicesType':_0x10947f[_0x475784('0x1a')]})[_0x475784('0x4')](function(){const _0x2a3ef1=_0x475784;logger['info'](_0x2a3ef1('0x1'),_0x478fd1,_0x510344[_0x2a3ef1('0x16')](','),_0x10947f[_0x2a3ef1('0x14')],_0x10947f['indicesType']);})['catch'](function(_0x3c21da){logger['info'](JSON['stringify'](_0x3c21da));});});},Migration[_0x493408('0x3')]['removeIndex']=function(_0x17f583,_0x7a4309){const _0xedb216=_0x493408,_0x103fd7=this;this[_0xedb216('0x6')][_0xedb216('0x23')](function(){const _0x473332=_0xedb216;return _0x103fd7['queryInterface'][_0x473332('0xa')](_0x17f583,_0x7a4309)['then'](function(){const _0x36fbdd=_0x473332;logger[_0x36fbdd('0xc')](_0x36fbdd('0xe'),_0x17f583,_0x7a4309);})[_0x473332('0x11')](function(_0x95ba9a){const _0x29962c=_0x473332;logger['info'](JSON[_0x29962c('0x1c')](_0x95ba9a));});});},Migration[_0x493408('0x3')][_0x493408('0x9')]=function(_0x1696fb){const _0x4ea554=_0x493408,_0xb495dc=this;this[_0x4ea554('0x6')][_0x4ea554('0x23')](function(){const _0x185bb0=_0x4ea554;return _0xb495dc[_0x185bb0('0x27')][_0x185bb0('0x24')][_0x185bb0('0x9')](_0x1696fb)[_0x185bb0('0x4')](function(){const _0x1336f5=_0x185bb0;logger[_0x1336f5('0xc')](_0x1336f5('0xb'),_0x1696fb);})[_0x185bb0('0x11')](function(_0x1c409f){const _0x3c9c78=_0x185bb0;logger[_0x3c9c78('0xc')](JSON[_0x3c9c78('0x1c')](_0x1c409f));});});},Migration['prototype'][_0x493408('0x0')]=function(_0x14c919,_0x23efc0){const _0x58aefa=_0x493408,_0xb04d52=this;this[_0x58aefa('0x6')][_0x58aefa('0x23')](function(){const _0x2aa75c=_0x58aefa;return _0xb04d52['queryInterface'][_0x2aa75c('0x0')](_0x14c919,_0x23efc0)[_0x2aa75c('0x4')](function(){const _0x3412b7=_0x2aa75c;logger[_0x3412b7('0xc')](_0x3412b7('0x10'),_0x23efc0,_0x14c919);})[_0x2aa75c('0x11')](function(_0x34dbc5){logger['info'](util['inspect'](_0x34dbc5,{'showHidden':![],'depth':null}));});});},Migration[_0x493408('0x3')][_0x493408('0x13')]=function(_0x221088,_0x13083d,_0x442fb5){const _0x372e75=_0x493408,_0x4a46d4=this;this[_0x372e75('0x6')][_0x372e75('0x23')](function(){const _0x2f6f72=_0x372e75;return _0x4a46d4[_0x2f6f72('0x27')][_0x2f6f72('0x13')](_0x221088,_0x13083d,_0x442fb5)[_0x2f6f72('0x4')](function(){const _0x3e0b61=_0x2f6f72;logger[_0x3e0b61('0xc')](_0x3e0b61('0xf'),_0x13083d,_0x442fb5,_0x221088);})['catch'](function(_0x591bbe){const _0x60bcae=_0x2f6f72;logger[_0x60bcae('0xc')](util['inspect'](_0x591bbe,{'showHidden':![],'depth':null}));});});},Migration[_0x493408('0x3')][_0x493408('0x26')]=function(_0x306f91){const _0x2a2225=_0x493408;this[_0x2a2225('0x6')]['enqueue'](function(){return _0x306f91();});},module[_0x493408('0x8')]={'up':function(_0x415812,_0x5009b8){return new Promise(function(_0xc8293f){const _0x27c07b=a1020_0x3ff6,_0x1b0937=new Migration(_0x415812);_0x1b0937[_0x27c07b('0xd')](_0x27c07b('0x22'),_0x27c07b('0x1f'),{'type':_0x5009b8[_0x27c07b('0x1b')]}),_0x1b0937[_0x27c07b('0xd')](_0x27c07b('0x22'),_0x27c07b('0x17'),{'type':_0x5009b8['TEXT']}),_0x1b0937[_0x27c07b('0xd')]('openchannel_messages','providerName',{'type':_0x5009b8[_0x27c07b('0x1b')]}),_0x1b0937[_0x27c07b('0xd')](_0x27c07b('0x18'),_0x27c07b('0x17'),{'type':_0x5009b8[_0x27c07b('0x28')]}),_0x1b0937['addColumn'](_0x27c07b('0x2'),_0x27c07b('0x1f'),{'type':_0x5009b8[_0x27c07b('0x1b')]}),_0x1b0937[_0x27c07b('0xd')]('sms_messages',_0x27c07b('0x17'),{'type':_0x5009b8[_0x27c07b('0x28')]}),_0x1b0937[_0x27c07b('0xd')](_0x27c07b('0x20'),_0x27c07b('0x1f'),{'type':_0x5009b8[_0x27c07b('0x1b')]}),_0x1b0937['addColumn']('whatsapp_messages',_0x27c07b('0x17'),{'type':_0x5009b8[_0x27c07b('0x28')]}),_0x1b0937[_0x27c07b('0xd')](_0x27c07b('0x15'),'providerName',{'type':_0x5009b8[_0x27c07b('0x1b')]}),_0x1b0937[_0x27c07b('0xd')](_0x27c07b('0x15'),'providerResponse',{'type':_0x5009b8[_0x27c07b('0x28')]}),_0x1b0937[_0x27c07b('0x26')](_0xc8293f);});},'down':function(){}}; \ No newline at end of file diff --git a/server/migrations/3.0.0-alpha.js b/server/migrations/3.0.0-alpha.js index 0d98e80..cf880cb 100644 --- a/server/migrations/3.0.0-alpha.js +++ b/server/migrations/3.0.0-alpha.js @@ -1 +1 @@ -const a1021_0x32de=['sequelize','then','indicesType','queryInterface','Changed\x20column\x20%s\x20in\x20table\x20%s','table\x20dropped\x20%s','addIndex\x20%s\x20%s\x20%s\x20[%s]','stringify','catch','removeIndex','changeColumn','DROP\x20INDEX\x20`users_ibfk_1`\x20ON\x20users','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','../config/logger','addColumn','tail','query','migration','inspect','util','prototype','info','query\x20%s','sequence','addIndex','ALTER\x20TABLE\x20users\x20ADD\x20CONSTRAINT\x20`users_ibfk_1`\x20FOREIGN\x20KEY\x20(userProfileId)\x20REFERENCES\x20user_profiles(id)\x20ON\x20DELETE\x20RESTRICT','removeColumn','Added\x20column\x20%s\x20to\x20%s','finally','ALTER\x20TABLE\x20users\x20DROP\x20FOREIGN\x20KEY\x20`users_ibfk_1`','indexName','dropTable','renameColumn','Removed\x20column\x20%s\x20from\x20%s','removeIndex\x20%s\x20%s','enqueue','join','final'];(function(_0x1b56a8,_0x32de49){const _0x38a604=function(_0x44d6e5){while(--_0x44d6e5){_0x1b56a8['push'](_0x1b56a8['shift']());}};_0x38a604(++_0x32de49);}(a1021_0x32de,0xbd));const a1021_0x38a6=function(_0x1b56a8,_0x32de49){_0x1b56a8=_0x1b56a8-0x0;let _0x38a604=a1021_0x32de[_0x1b56a8];return _0x38a604;};const _0x1f28f9=a1021_0x38a6;'use strict';const util=require(_0x1f28f9('0x14')),logger=require(_0x1f28f9('0xe'))(_0x1f28f9('0x12')),Sequence=function(){};Sequence[_0x1f28f9('0x15')]['enqueue']=function(_0x44d6e5){const _0x2c7467=_0x1f28f9;this[_0x2c7467('0x10')]=this[_0x2c7467('0x10')]?this['tail'][_0x2c7467('0x1d')](_0x44d6e5):_0x44d6e5();};const Migration=function(_0x26193b){const _0x3e0e1e=_0x1f28f9;this[_0x3e0e1e('0x4')]=_0x26193b,this['sequence']=new Sequence();};Migration[_0x1f28f9('0x15')][_0x1f28f9('0xb')]=function(_0x119b8b,_0x4f1cf6,_0x3a4935){const _0x5d2c46=_0x1f28f9,_0x33cd80=this;this[_0x5d2c46('0x18')][_0x5d2c46('0x24')](function(){const _0x2728c5=_0x5d2c46;return _0x33cd80[_0x2728c5('0x4')][_0x2728c5('0xb')](_0x119b8b,_0x4f1cf6,_0x3a4935)[_0x2728c5('0x2')](function(){const _0x57f94b=_0x2728c5;logger[_0x57f94b('0x16')](_0x57f94b('0x5'),_0x4f1cf6,_0x119b8b);})[_0x2728c5('0x9')](function(_0x5e6b19){const _0x33069c=_0x2728c5;logger[_0x33069c('0x16')](JSON[_0x33069c('0x8')](_0x5e6b19));});});},Migration[_0x1f28f9('0x15')][_0x1f28f9('0xf')]=function(_0x2b663c,_0xf44d78,_0x5d0dcb){const _0x45ddf1=_0x1f28f9,_0xd9a698=this;this[_0x45ddf1('0x18')][_0x45ddf1('0x24')](function(){const _0x50a7ec=_0x45ddf1;return _0xd9a698[_0x50a7ec('0x4')]['addColumn'](_0x2b663c,_0xf44d78,_0x5d0dcb)[_0x50a7ec('0x2')](function(){const _0x49578e=_0x50a7ec;logger[_0x49578e('0x16')](_0x49578e('0x1c'),_0xf44d78,_0x2b663c);})[_0x50a7ec('0x9')](function(_0x4a4ea4){const _0x36bb83=_0x50a7ec;logger['info'](JSON[_0x36bb83('0x8')](_0x4a4ea4));});});},Migration[_0x1f28f9('0x15')][_0x1f28f9('0x20')]=function(_0x508a93){const _0x118659=_0x1f28f9,_0x435d39=this;this[_0x118659('0x18')]['enqueue'](function(){const _0x3ed1bc=_0x118659;return _0x435d39['queryInterface']['dropTable'](_0x508a93,{'force':!![]})[_0x3ed1bc('0x2')](function(){const _0x5642c2=_0x3ed1bc;logger[_0x5642c2('0x16')](_0x5642c2('0x6'),_0x508a93);})['catch'](function(_0x171ae2){const _0x26f73e=_0x3ed1bc;logger[_0x26f73e('0x16')](JSON[_0x26f73e('0x8')](_0x171ae2));});});},Migration[_0x1f28f9('0x15')][_0x1f28f9('0x19')]=function(_0x1f5da9,_0x320491,_0x367bab){const _0x547cdf=_0x1f28f9,_0x26858b=this;this['sequence'][_0x547cdf('0x24')](function(){const _0x2202c8=_0x547cdf;return _0x26858b['queryInterface'][_0x2202c8('0x19')](_0x1f5da9,_0x320491,{'indexName':_0x367bab['indexName'],'indicesType':_0x367bab[_0x2202c8('0x3')]})[_0x2202c8('0x2')](function(){const _0x202f07=_0x2202c8;logger[_0x202f07('0x16')](_0x202f07('0x7'),_0x1f5da9,_0x320491[_0x202f07('0x25')](','),_0x367bab[_0x202f07('0x1f')],_0x367bab[_0x202f07('0x3')]);})[_0x2202c8('0x9')](function(_0x126541){const _0x25068=_0x2202c8;logger[_0x25068('0x16')](JSON[_0x25068('0x8')](_0x126541));});});},Migration[_0x1f28f9('0x15')][_0x1f28f9('0xa')]=function(_0xfa0dd4,_0x43eb8c){const _0x2ca186=_0x1f28f9,_0x1bd1e4=this;this[_0x2ca186('0x18')][_0x2ca186('0x24')](function(){const _0x595fcd=_0x2ca186;return _0x1bd1e4[_0x595fcd('0x4')][_0x595fcd('0xa')](_0xfa0dd4,_0x43eb8c)[_0x595fcd('0x2')](function(){const _0xef8963=_0x595fcd;logger[_0xef8963('0x16')](_0xef8963('0x23'),_0xfa0dd4,_0x43eb8c);})[_0x595fcd('0x9')](function(_0xa43072){const _0x52a8fe=_0x595fcd;logger[_0x52a8fe('0x16')](JSON[_0x52a8fe('0x8')](_0xa43072));});});},Migration['prototype'][_0x1f28f9('0x11')]=function(_0x306c5a){const _0x59e76c=_0x1f28f9,_0x2ca3a5=this;this['sequence'][_0x59e76c('0x24')](function(){const _0x257535=_0x59e76c;return _0x2ca3a5[_0x257535('0x4')][_0x257535('0x1')]['query'](_0x306c5a)['then'](function(){const _0x5ac44f=_0x257535;logger['info'](_0x5ac44f('0x17'),_0x306c5a);})['catch'](function(_0x359c7f){const _0x378ab4=_0x257535;logger[_0x378ab4('0x16')](JSON[_0x378ab4('0x8')](_0x359c7f));});});},Migration[_0x1f28f9('0x15')][_0x1f28f9('0x1b')]=function(_0x3e9dad,_0x340b86){const _0x22c2eb=_0x1f28f9,_0x235412=this;this[_0x22c2eb('0x18')]['enqueue'](function(){const _0x4a495f=_0x22c2eb;return _0x235412['queryInterface'][_0x4a495f('0x1b')](_0x3e9dad,_0x340b86)['then'](function(){const _0x739693=_0x4a495f;logger['info'](_0x739693('0x22'),_0x340b86,_0x3e9dad);})[_0x4a495f('0x9')](function(_0x43ef65){const _0x37fa42=_0x4a495f;logger[_0x37fa42('0x16')](util[_0x37fa42('0x13')](_0x43ef65,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0x1f28f9('0x21')]=function(_0x3ca732,_0x48262f,_0x2299c3){const _0x3a5e07=_0x1f28f9,_0x1996a4=this;this[_0x3a5e07('0x18')][_0x3a5e07('0x24')](function(){const _0x31e1cb=_0x3a5e07;return _0x1996a4[_0x31e1cb('0x4')][_0x31e1cb('0x21')](_0x3ca732,_0x48262f,_0x2299c3)[_0x31e1cb('0x2')](function(){const _0x53fa2a=_0x31e1cb;logger[_0x53fa2a('0x16')](_0x53fa2a('0xd'),_0x48262f,_0x2299c3,_0x3ca732);})['catch'](function(_0x2bcea5){const _0x2ae69=_0x31e1cb;logger[_0x2ae69('0x16')](util[_0x2ae69('0x13')](_0x2bcea5,{'showHidden':![],'depth':null}));});});},Migration[_0x1f28f9('0x15')][_0x1f28f9('0x0')]=function(_0xc9dd09){const _0x5d9470=_0x1f28f9;this['sequence'][_0x5d9470('0x24')](function(){return _0xc9dd09();});},module['exports']={'up':function(_0x30f782){return new Promise(function(_0x5bf7e8){const _0xf88244=a1021_0x38a6,_0x291cf6=new Migration(_0x30f782);_0x291cf6[_0xf88244('0x11')](_0xf88244('0x1e')),_0x291cf6[_0xf88244('0x11')](_0xf88244('0xc')),_0x291cf6[_0xf88244('0x11')](_0xf88244('0x1a')),_0x291cf6['final'](_0x5bf7e8);});},'down':function(){}}; \ No newline at end of file +const a1021_0x91fd=['sequelize','dropTable','util','info','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','ALTER\x20TABLE\x20users\x20ADD\x20CONSTRAINT\x20`users_ibfk_1`\x20FOREIGN\x20KEY\x20(userProfileId)\x20REFERENCES\x20user_profiles(id)\x20ON\x20DELETE\x20RESTRICT','query','enqueue','migration','addColumn','DROP\x20INDEX\x20`users_ibfk_1`\x20ON\x20users','addIndex\x20%s\x20%s\x20%s\x20[%s]','changeColumn','catch','removeIndex\x20%s\x20%s','indexName','../config/logger','Changed\x20column\x20%s\x20in\x20table\x20%s','then','sequence','addIndex','tail','removeColumn','final','ALTER\x20TABLE\x20users\x20DROP\x20FOREIGN\x20KEY\x20`users_ibfk_1`','Added\x20column\x20%s\x20to\x20%s','queryInterface','Removed\x20column\x20%s\x20from\x20%s','stringify','indicesType','renameColumn','join','inspect','removeIndex','prototype'];(function(_0x303560,_0x91fd43){const _0x337845=function(_0x30ea61){while(--_0x30ea61){_0x303560['push'](_0x303560['shift']());}};_0x337845(++_0x91fd43);}(a1021_0x91fd,0xad));const a1021_0x3378=function(_0x303560,_0x91fd43){_0x303560=_0x303560-0x0;let _0x337845=a1021_0x91fd[_0x303560];return _0x337845;};const _0x340447=a1021_0x3378;'use strict';const util=require(_0x340447('0x4')),logger=require(_0x340447('0x12'))(_0x340447('0xa')),Sequence=function(){};Sequence[_0x340447('0x1')][_0x340447('0x9')]=function(_0x30ea61){const _0x14edec=_0x340447;this[_0x14edec('0x17')]=this['tail']?this[_0x14edec('0x17')]['finally'](_0x30ea61):_0x30ea61();};const Migration=function(_0x246239){this['queryInterface']=_0x246239,this['sequence']=new Sequence();};Migration[_0x340447('0x1')][_0x340447('0xe')]=function(_0x2efd13,_0x1d812e,_0x541bd4){const _0xf726a1=_0x340447,_0x87a6b2=this;this[_0xf726a1('0x15')][_0xf726a1('0x9')](function(){const _0x346920=_0xf726a1;return _0x87a6b2[_0x346920('0x1c')]['changeColumn'](_0x2efd13,_0x1d812e,_0x541bd4)[_0x346920('0x14')](function(){const _0x27809c=_0x346920;logger[_0x27809c('0x5')](_0x27809c('0x13'),_0x1d812e,_0x2efd13);})[_0x346920('0xf')](function(_0x3f7f0f){const _0x243cac=_0x346920;logger[_0x243cac('0x5')](JSON[_0x243cac('0x1e')](_0x3f7f0f));});});},Migration[_0x340447('0x1')][_0x340447('0xb')]=function(_0x4e992d,_0x51543f,_0x38a53c){const _0x4bb62b=_0x340447,_0x4b64e4=this;this[_0x4bb62b('0x15')][_0x4bb62b('0x9')](function(){const _0x3e281f=_0x4bb62b;return _0x4b64e4[_0x3e281f('0x1c')][_0x3e281f('0xb')](_0x4e992d,_0x51543f,_0x38a53c)[_0x3e281f('0x14')](function(){const _0x3876cf=_0x3e281f;logger[_0x3876cf('0x5')](_0x3876cf('0x1b'),_0x51543f,_0x4e992d);})[_0x3e281f('0xf')](function(_0x1b4b50){const _0x41a030=_0x3e281f;logger[_0x41a030('0x5')](JSON[_0x41a030('0x1e')](_0x1b4b50));});});},Migration[_0x340447('0x1')][_0x340447('0x3')]=function(_0x52736f){const _0x222cf3=_0x340447,_0x2e12d6=this;this[_0x222cf3('0x15')][_0x222cf3('0x9')](function(){const _0x5ea120=_0x222cf3;return _0x2e12d6[_0x5ea120('0x1c')][_0x5ea120('0x3')](_0x52736f,{'force':!![]})[_0x5ea120('0x14')](function(){const _0x2a14ea=_0x5ea120;logger[_0x2a14ea('0x5')]('table\x20dropped\x20%s',_0x52736f);})['catch'](function(_0x440984){const _0xd40738=_0x5ea120;logger[_0xd40738('0x5')](JSON[_0xd40738('0x1e')](_0x440984));});});},Migration[_0x340447('0x1')][_0x340447('0x16')]=function(_0x2e8513,_0x12eb3a,_0x109761){const _0x4270af=_0x340447,_0x63b883=this;this[_0x4270af('0x15')][_0x4270af('0x9')](function(){const _0x4124d1=_0x4270af;return _0x63b883[_0x4124d1('0x1c')][_0x4124d1('0x16')](_0x2e8513,_0x12eb3a,{'indexName':_0x109761[_0x4124d1('0x11')],'indicesType':_0x109761['indicesType']})[_0x4124d1('0x14')](function(){const _0x392551=_0x4124d1;logger[_0x392551('0x5')](_0x392551('0xd'),_0x2e8513,_0x12eb3a[_0x392551('0x21')](','),_0x109761[_0x392551('0x11')],_0x109761[_0x392551('0x1f')]);})[_0x4124d1('0xf')](function(_0x3e9133){const _0x4deb7d=_0x4124d1;logger[_0x4deb7d('0x5')](JSON['stringify'](_0x3e9133));});});},Migration['prototype']['removeIndex']=function(_0x23bbab,_0x2749d4){const _0xcbecd6=_0x340447,_0x585004=this;this[_0xcbecd6('0x15')][_0xcbecd6('0x9')](function(){const _0x45afea=_0xcbecd6;return _0x585004[_0x45afea('0x1c')][_0x45afea('0x0')](_0x23bbab,_0x2749d4)[_0x45afea('0x14')](function(){const _0x443d05=_0x45afea;logger['info'](_0x443d05('0x10'),_0x23bbab,_0x2749d4);})[_0x45afea('0xf')](function(_0x59ff70){const _0x550f9b=_0x45afea;logger['info'](JSON[_0x550f9b('0x1e')](_0x59ff70));});});},Migration['prototype'][_0x340447('0x8')]=function(_0x343561){const _0x1a205c=_0x340447,_0xa02ab6=this;this[_0x1a205c('0x15')][_0x1a205c('0x9')](function(){const _0x249e7b=_0x1a205c;return _0xa02ab6[_0x249e7b('0x1c')][_0x249e7b('0x2')]['query'](_0x343561)['then'](function(){const _0xc9fea5=_0x249e7b;logger[_0xc9fea5('0x5')]('query\x20%s',_0x343561);})[_0x249e7b('0xf')](function(_0x3e50a7){const _0x4a5e11=_0x249e7b;logger[_0x4a5e11('0x5')](JSON['stringify'](_0x3e50a7));});});},Migration['prototype']['removeColumn']=function(_0x1e28bd,_0x2bf941){const _0x3dc933=_0x340447,_0x454412=this;this[_0x3dc933('0x15')][_0x3dc933('0x9')](function(){const _0x40f697=_0x3dc933;return _0x454412[_0x40f697('0x1c')][_0x40f697('0x18')](_0x1e28bd,_0x2bf941)[_0x40f697('0x14')](function(){const _0x24f8e9=_0x40f697;logger[_0x24f8e9('0x5')](_0x24f8e9('0x1d'),_0x2bf941,_0x1e28bd);})[_0x40f697('0xf')](function(_0x30c481){const _0x51d9d6=_0x40f697;logger[_0x51d9d6('0x5')](util[_0x51d9d6('0x22')](_0x30c481,{'showHidden':![],'depth':null}));});});},Migration[_0x340447('0x1')][_0x340447('0x20')]=function(_0x470837,_0x51de16,_0x2b2f50){const _0xc037e=_0x340447,_0x19ff21=this;this[_0xc037e('0x15')]['enqueue'](function(){const _0x586755=_0xc037e;return _0x19ff21[_0x586755('0x1c')][_0x586755('0x20')](_0x470837,_0x51de16,_0x2b2f50)[_0x586755('0x14')](function(){const _0x502bea=_0x586755;logger[_0x502bea('0x5')](_0x502bea('0x6'),_0x51de16,_0x2b2f50,_0x470837);})[_0x586755('0xf')](function(_0xf83aca){const _0x3667a3=_0x586755;logger[_0x3667a3('0x5')](util[_0x3667a3('0x22')](_0xf83aca,{'showHidden':![],'depth':null}));});});},Migration[_0x340447('0x1')]['final']=function(_0x25f0be){const _0xfa2240=_0x340447;this['sequence'][_0xfa2240('0x9')](function(){return _0x25f0be();});},module['exports']={'up':function(_0x417106){return new Promise(function(_0x1acd11){const _0x29f865=a1021_0x3378,_0xadbfb8=new Migration(_0x417106);_0xadbfb8[_0x29f865('0x8')](_0x29f865('0x1a')),_0xadbfb8[_0x29f865('0x8')](_0x29f865('0xc')),_0xadbfb8[_0x29f865('0x8')](_0x29f865('0x7')),_0xadbfb8[_0x29f865('0x19')](_0x1acd11);});},'down':function(){}}; \ No newline at end of file diff --git a/server/mysqldb/index.js b/server/mysqldb/index.js index 688e896..1664554 100644 --- a/server/mysqldb/index.js +++ b/server/mysqldb/index.js @@ -1 +1 @@ -const a1022_0x4bdd=['Migration','Contact','Tag','../api/openchannelQueue/openchannelQueue.model','User','CmHopperFinal','SmsInteractionId','user_has_openchannel_accounts','UserMailInteractions','voice_queues_has_cm_lists','../api/intZohoConfiguration/intZohoConfiguration.model','UserProfileSections','SugarcrmConfiguration','cm_user_has_contacts','../api/analyticDefaultReport/analyticDefaultReport.model','../api/squareReport/squareReport.model','SmsQueueReport','ChatQueue','ChatGroup','voice_queues_has_cm_blacklists','ParentId','FaxInteractions','TrunkId','../api/intZohoField/intZohoField.model','SenderId','AnyCondition','campaigns_has_cm_blacklists','UserSmsQueue','AllCondition','Intervals','ChatInteraction','ToChatQueueId','user_has_sms_interactions','../api/smsQueue/smsQueue.model','options','../config/config.service','VoiceChanSpy','../api/squareRecording/squareRecording.model','../api/analyticExtractedReport/analyticExtractedReport.model','../api/voiceTransferReport/voiceTransferReport.model','ZendeskField','Action','FromMailAccountId','Fields','SquareProjectId','uniqueid','Trigger','HopperFinals','ToOpenchannelAccountId','AllConditions','MailServerIn','../api/intFreshdeskField/intFreshdeskField.model','Subjects','utf8_general_ci','../api/condition/condition.model','Applications','ReportAgentPreview','SubjectId','VoiceAgentReport','../api/integration/integration.model','Dynamics365Field','SmsQueues','team_has_whatsapp_queues','VtigerAccount','SpiedAgents','../api/intServicenowConfiguration/intServicenowConfiguration.model','CampaignId','SugarcrmField','../api/intDeskConfiguration/intDeskConfiguration.model','JscriptySessionReport','VoiceTransferReport','sectionId','Template','FaxInteractionId','ListId','OwnerId','AnalyticDefaultReport','UserOpenchannelQueue','../api/userOpenchannelQueue/userOpenchannelQueue.model','../api/voiceQueuesLog/voiceQueuesLog.model','SquareOdbc','TriggerAnyId','AnalyticFieldReport','ChatTransferReport','user_has_fax_interactions','ServicenowAccount','WhatsappQueueId','MemberReport','../api/jscriptyAnswerReport/jscriptyAnswerReport.model','FreshdeskField','../api/template/template.model','Description','HopperBlacks','ChatMessage','hasMany','OpenchannelApplication','ToMailQueueId','Field','UserVoiceQueue','WhatsappQueues','OpenchannelInteractionId','team_has_mail_queues','ChatInteractionId','MailQueueReport','VoiceQueue','UserFaxQueue','VoiceQueueId','FaxTransferReport','Configurations','SmsInteraction','db-query','MailQueue','TagId','../api/userProfile/userProfile.model','ToChatWebsiteId','FromSmsAccountId','../api/chatQueue/chatQueue.model','IntervalId','ZohoAccount','Answers','FromChatWebsiteId','name','user_has_openchannel_interactions','mail_interaction_has_tags','Extensions','Website','SmsApplication','SmsMessage','WhatsappInteractionId','../api/chatGroup/chatGroup.model','UserId','SmsQueueId','SmsAccounts','FromOpenchannelAccountId','Descriptions','AccountId','ChatApplication','MailAccountId','ZohoConfiguration','Dynamics365Configuration','All','../api/intZohoAccount/intZohoAccount.model','user_has_mail_interactions','Any','Interval','../api/plugin/plugin.model','Variable','team_has_openchannel_queues','username','password','../api/faxMessage/faxMessage.model','../api/intSalesforceConfiguration/intSalesforceConfiguration.model','VoiceQueuesLog','user_has_mail_accounts','../api/whatsappAccount/whatsappAccount.model','JscriptyAnswerReport','FreshsalesConfiguration','Smtp','../api/intZendeskField/intZendeskField.model','../api/variable/variable.model','ProjectId','ChatQueueReport','CustomReportId','../api/voiceMailMessage/voiceMailMessage.model','Dashboard','MailServerOut','lodash','Agents','../api/intServicenowField/intServicenowField.model','OpenchannelTransferReport','user_has_teams','FromAgent','Disposition','../api/attachment/attachment.model','dbPort','../api/chatProactiveAction/chatProactiveAction.model','../api/userProfileSection/userProfileSection.model','cm_user_has_lists','WhatsappMessage','../api/analyticMetric/analyticMetric.model','DeskConfiguration','../api/chatQueueReport/chatQueueReport.model','../api/openchannelMessage/openchannelMessage.model','UserWhatsappInteractions','JscriptyProject','Condition','info','mailbox','ZendeskConfiguration','../api/userVoiceQueueRt/userVoiceQueueRt.model','Contacts','SmsAccountId','SugarcrmAccount','../api/cmHopper/cmHopper.model','VoicePrefix','restrict','Interaction','user_has_whatsapp_accounts','OpenchannelInteraction','../api/whatsappQueue/whatsappQueue.model','sequelizeHistory','WhatsappTransferReport','mysqlDatabase','../api/cmList/cmList.model','../api/chatApplication/chatApplication.model','CmHopper','../api/voicePrefix/voicePrefix.model','../api/userVoiceQueue/userVoiceQueue.model','../api/chatTransferReport/chatTransferReport.model','FromWhatsappAccountId','FaxMessage','Attachment','WhatsappInteraction','Items','MailMessage','VariableId','../api/team/team.model','SquareProjects','ZohoField','Integration','Account','AgentReports','sms_interaction_has_tags','mandatoryDispositionPause','../api/intVtigerAccount/intVtigerAccount.model','JscriptySessions','Dispositions','Agent','belongsTo','UserProfileSection','SquareReport','ProactiveActions','../api/voiceDialReport/voiceDialReport.model','../api/intVtigerConfiguration/intVtigerConfiguration.model','../api/userSmsQueue/userSmsQueue.model','mysqlPassword','ToQueueId','FaxQueueReport','OpenchannelQueue','openchannel_interaction_has_tags','DeskField','../api/squareProject/squareProject.model','MetricId','ToQueue','AnyConditions','Recordings','../api/sound/sound.model','FreshdeskConfiguration','ChatOfflineMessage','../api/mailQueueReport/mailQueueReport.model','FaxQueues','DescriptionId','AnalyticTreeReport','JscriptyQuestionReport','MailInteraction','../api/openchannelInteraction/openchannelInteraction.model','VoiceQueueReport','CmHopperHistory','License','UserSmsInteractions','OpenchannelQueueId','defaultsDeep','../api/userChatQueue/userChatQueue.model','FaxAccounts','../api/voiceExtension/voiceExtension.model','../api/user/user.model','ChatInternalMessage','Members','../api/cannedAnswer/cannedAnswer.model','Dynamics365Account','VoiceMailMessage','VoiceMusicOnHold','ChatInteractions','user_has_fax_accounts','OpenchannelInteractions','UserWhatsappQueue','sequelize','FromAccount','../api/whatsappInteraction/whatsappInteraction.model','ChatApplications','UserOpenchannelInteractions','../api/cloudProvider/cloudProvider.model','VoiceContext','Queue','Trunk','MailApplications','team_has_chat_queues','FaxAccountId','QueueCalls','Automation','../api/intSalesforceAccount/intSalesforceAccount.model','../api/trigger/trigger.model','ContactId','../api/intDeskAccount/intDeskAccount.model','determine','Interactions','../api/intDynamics365Configuration/intDynamics365Configuration.model','DeskAccount','../api/faxQueue/faxQueue.model','CmList','../api/cmCustomField/cmCustomField.model','../api/cmHopperHistory/cmHopperHistory.model','FaxInteraction','cm_contact_has_tags','../api/mailApplication/mailApplication.model','Notification','user_has_whatsapp_interactions','SalesforceAccount','int_zendesk_configuration_has_tags','HopperHistory','VoiceDialReport','CompanyId','Attachments','ServicenowConfiguration','ToSmsAccountId','ThroughTags','chat_group_has_users','VoiceMail','../api/smsQueueReport/smsQueueReport.model','VoiceCallReport','TrunkBackupId','VtigerField','AnalyticMetric','ServicenowField','../api/smsMessage/smsMessage.model','campaigns_has_cm_lists','UserChatInteractions','CmCustomField','utf8mb4','DataTypes','ChatGroupId','Messages','ToSmsQueueId','../api/smsTransferReport/smsTransferReport.model','../api/interval/interval.model','mailboxuser','OneAny','../api/intDeskField/intDeskField.model','Subject','OpenchannelMessage','ToUserId','OpenchannelQueues','userProfileId','../api/voiceCallReport/voiceCallReport.model','MailAccount','FromUserId','ToAgent','../api/intDynamics365Account/intDynamics365Account.model','BlackLists','../api/voiceQueueReport/voiceQueueReport.model','FaxAccount','../api/license/license.model','WhatsappQueueReport','ChatWebsite','cascade','Actions','../api/cmHopperFinal/cmHopperFinal.model','WhatsappAccountId','DefaultReportId','FaxApplications','user_has_sms_accounts','Hoppers','WhatsappInteractions','ChatWebsiteId','whatsapp_interaction_has_tags','../api/reportAgentPreview/reportAgentPreview.model','OpenchannelQueueReport','fax_interaction_has_tags','CustomFields','../api/disposition/disposition.model','AutomationAllId','../api/cmHopperBlack/cmHopperBlack.model','Teams','SquareRecording','../api/intSugarcrmAccount/intSugarcrmAccount.model','../api/analyticTreeReport/analyticTreeReport.model','ToId','user_has_voice_prefixes','../api/whatsappQueueReport/whatsappQueueReport.model','Owner','../api/whatsappApplication/whatsappApplication.model','AutomationAnyId','FreshsalesAccount','../api/dashboard/dashboard.model','hasOne','TriggerId','SquareMessage','OpenchannelAccounts','../api/intSugarcrmConfiguration/intSugarcrmConfiguration.model','UserVoiceQueueRt','DashboardItem','FreshdeskAccount','SalesforceConfiguration','../api/dashboardItem/dashboardItem.model','Tags','SquareProject','../api/userWhatsappQueue/userWhatsappQueue.model','mysqlUser','../api/faxInteraction/faxInteraction.model','VoiceExtension','Pause','../api/pause/pause.model','exports','../api/automation/automation.model','UserFaxInteractions','MailInteractionId','MailInteractions','utf8','CloudProvider','SmsInteractions','VoiceQueues','../api/voiceMusicOnHold/voiceMusicOnHold.model','../api/setting/setting.model','SmsQueue','ToWhatsappAccountId','SmsTransferReport','Company','chat_interaction_has_tags','FaxApplication','../api/squareMessage/squareMessage.model','../api/mailInteraction/mailInteraction.model','../api/openchannelTransferReport/openchannelTransferReport.model','UserProfile','team_has_voice_queues','UserMailQueue','../api/notification/notification.model','ChatProactiveAction','CmCompany','WhatsappAccount','VtigerConfiguration','AnalyticCustomReport','../api/whatsappMessage/whatsappMessage.model','belongsToMany','UserChatQueue','mandatoryDispositionPauseId','VoiceRecording','WhatsappQueue','../api/smsInteraction/smsInteraction.model','team_has_sms_queues','MailQueues','FreshsalesField','../api/analyticFieldReport/analyticFieldReport.model','MailTransferReport','../api/userProfileResource/userProfileResource.model','../api/screenRecording/screenRecording.model','int_desk_configuration_has_tags','OpenchannelAccount','../api/intServicenowAccount/intServicenowAccount.model','HopperHistories','../api/trunk/trunk.model','FieldId','user_has_chat_interactions','user_has_square_projects','getConfigService','SalesforceField','../api/userFaxQueue/userFaxQueue.model','CmHopperBlack','SmsAccount','SessionId','user_has_chat_websites','Campaign','MailApplication','Users','WhatsappApplication','List','FaxQueue','../api/chatOfflineMessage/chatOfflineMessage.model','../api/mailMessage/mailMessage.model','CannedAnswer','ToOpenchannelQueueId','Sound','TriggerAllId','../api/smsApplication/smsApplication.model','ToAccount','Network','../config/logger','../api/openchannelApplication/openchannelApplication.model','CmContact','../api/intVtigerField/intVtigerField.model','Schedule','../api/faxApplication/faxApplication.model','AttachmentId','OpenchannelAccountId','Setting','ChatQueues','../api/chatInteraction/chatInteraction.model','ZendeskAccount','../api/mailSubstatus/mailSubstatus.model','IntegrationReport','../api/cdr/cdr.model','team_has_fax_queues','../api/integrationReport/integrationReport.model','Lists','Team','AnalyticExtractedReport'];(function(_0x132a6b,_0x4bddd6){const _0x320de2=function(_0x56fbcf){while(--_0x56fbcf){_0x132a6b['push'](_0x132a6b['shift']());}};_0x320de2(++_0x4bddd6);}(a1022_0x4bdd,0x15f));const a1022_0x320d=function(_0x132a6b,_0x4bddd6){_0x132a6b=_0x132a6b-0x0;let _0x320de2=a1022_0x4bdd[_0x132a6b];return _0x320de2;};const _0x309545=a1022_0x320d;'use strict';const config=require('../config/environment'),cs=require(_0x309545('0xb3'))[_0x309545('0x66')](),Sequelize=require(_0x309545('0x1a4')),logger=require(_0x309545('0x7c')),_=require(_0x309545('0x136')),jstz=require('jstz'),timezone=jstz[_0x309545('0x1b6')](),queryLogger=logger(_0x309545('0xfe')),DEFAULTS={'database':cs[_0x309545('0x15a')],'username':cs[_0x309545('0x2e')],'password':cs[_0x309545('0x17b')],'options':{'host':cs['dbHost'],'port':cs[_0x309545('0x13e')],'dialect':'mysql','dialectOptions':{'charset':_0x309545('0x1d8')},'logging':cs['isProduction']?![]:_0x56fbcf=>queryLogger[_0x309545('0x14a')](_0x56fbcf),'timezone':timezone[_0x309545('0x109')](),'define':{'charset':_0x309545('0x38'),'collate':_0x309545('0xc5')}}};config[_0x309545('0x1a4')]=_[_0x309545('0x195')](config[_0x309545('0x1a4')],DEFAULTS),config[_0x309545('0x158')]=_[_0x309545('0x195')](config[_0x309545('0x158')],DEFAULTS);const db={'Sequelize':Sequelize,'sequelize':new Sequelize(config['sequelize']['database'],config['sequelize']['username'],config[_0x309545('0x1a4')][_0x309545('0x125')],config[_0x309545('0x1a4')]['options'])},dbH={'Sequelize':Sequelize,'sequelize':new Sequelize(config[_0x309545('0x158')]['database'],config[_0x309545('0x158')][_0x309545('0x124')],config['sequelizeHistory'][_0x309545('0x125')],config['sequelizeHistory'][_0x309545('0xb2')])};db[_0x309545('0x94')]=require(_0x309545('0x199'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xb4')]=require('../api/voiceChanSpy/voiceChanSpy.model')(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['VoiceContext']=require('../api/voiceContext/voiceContext.model')(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['VoiceExtension']=require(_0x309545('0x198'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x19f')]=require(_0x309545('0x3c'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0xf8')]=require('../api/voiceQueue/voiceQueue.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['VoiceRecording']=require('../api/voiceRecording/voiceRecording.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['ScreenRecording']=require(_0x309545('0x5d'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1cd')]=require('../api/voiceMail/voiceMail.model')(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x19e')]=require(_0x309545('0x133'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1cf')]=require(_0x309545('0x1e7'))(db['sequelize'],Sequelize['DataTypes']),db[_0x309545('0x1c6')]=require(_0x309545('0x178'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xca')]=require('../api/voiceAgentReport/voiceAgentReport.model')(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['VoiceQueueReport']=require(_0x309545('0x1ed'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xe7')]=require('../api/memberReport/memberReport.model')(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1ac')]=require(_0x309545('0x62'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xd6')]=require(_0x309545('0xb7'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['UserVoiceQueueRt']=require(_0x309545('0x14d'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0xf2')]=require(_0x309545('0x15f'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x52')]=require(_0x309545('0x196'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x49')]=require('../api/userMailQueue/userMailQueue.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xf9')]=require(_0x309545('0x68'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xab')]=require(_0x309545('0x17a'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['UserOpenchannelQueue']=require(_0x309545('0xde'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['UserWhatsappQueue']=require(_0x309545('0x2d'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['MailServerIn']=require('../api/mailServerIn/mailServerIn.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x135')]=require('../api/mailServerOut/mailServerOut.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['MailAccount']=require('../api/mailAccount/mailAccount.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['MailQueue']=require('../api/mailQueue/mailQueue.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['MailSubstatus']=require(_0x309545('0x88'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['MailInteraction']=require(_0x309545('0x45'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x166')]=require(_0x309545('0x74'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x6e')]=require(_0x309545('0x1c0'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xf7')]=require(_0x309545('0x189'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x134')]=require(_0x309545('0x20'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['DashboardItem']=require(_0x309545('0x2a'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1ee')]=require('../api/faxAccount/faxAccount.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x43')]=require(_0x309545('0x81'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1be')]=require(_0x309545('0x2f'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['FaxMessage']=require(_0x309545('0x126'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x72')]=require(_0x309545('0x1ba'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['FaxQueueReport']=require('../api/faxQueueReport/faxQueueReport.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['SmsAccount']=require('../api/smsAccount/smsAccount.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['SmsApplication']=require(_0x309545('0x79'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['SmsInteraction']=require(_0x309545('0x56'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x10f')]=require(_0x309545('0x1d4'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x3e')]=require(_0x309545('0xb1'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x5f')]=require('../api/openchannelAccount/openchannelAccount.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xef')]=require(_0x309545('0x7d'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x156')]=require(_0x309545('0x18f'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1e3')]=require(_0x309545('0x146'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['OpenchannelQueue']=require(_0x309545('0x93'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x2')]=require('../api/chatWebsite/chatWebsite.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['OpenchannelQueueReport']=require('../api/openchannelQueueReport/openchannelQueueReport.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x118')]=require(_0x309545('0x15c'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0xae')]=require(_0x309545('0x86'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xed')]=require('../api/chatMessage/chatMessage.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x188')]=require(_0x309545('0x73'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0xa1')]=require(_0x309545('0x104'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['ChatGroup']=require(_0x309545('0x111'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x4b')]=require(_0x309545('0x13f'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x4c')]=require('../api/cmCompany/cmCompany.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['CmContact']=require('../api/cmContact/cmContact.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x15d')]=require(_0x309545('0x151'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x69')]=require(_0x309545('0x14'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x95')]=require(_0x309545('0x5'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['CmHopperHistory']=require(_0x309545('0x1bd'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0xc8')]=require(_0x309545('0xe'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1d7')]=require(_0x309545('0x1bc'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xb9')]=require('../api/action/action.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1b1')]=require(_0x309545('0x34'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['CannedAnswer']=require(_0x309545('0x19c'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x13c')]=require(_0x309545('0x12'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x149')]=require(_0x309545('0xc6'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['Interval']=require(_0x309545('0x1de'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['Pause']=require(_0x309545('0x32'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['Cdr']=require(_0x309545('0x8a'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x128')]=require(_0x309545('0xdf'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x80')]=require('../api/schedule/schedule.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['Sound']=require(_0x309545('0x186'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['Tag']=require('../api/tag/tag.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xd8')]=require(_0x309545('0xea'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xbe')]=require(_0x309545('0x1b3'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x122')]=require(_0x309545('0x12f'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x16b')]=require(_0x309545('0xcb'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x89')]=require(_0x309545('0x8c'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['AnalyticCustomReport']=require('../api/analyticCustomReport/analyticCustomReport.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xdc')]=require(_0x309545('0x9e'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x8f')]=require(_0x309545('0xb6'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x1d2')]=require(_0x309545('0x143'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xe2')]=require(_0x309545('0x5a'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x18c')]=require(_0x309545('0x18'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['SalesforceAccount']=require(_0x309545('0x1b2'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['SalesforceConfiguration']=require(_0x309545('0x127'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x67')]=require('../api/intSalesforceField/intSalesforceField.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x150')]=require(_0x309545('0x17'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x9c')]=require(_0x309545('0x25'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xd3')]=require('../api/intSugarcrmField/intSugarcrmField.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1b9')]=require(_0x309545('0x1b5'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x144')]=require(_0x309545('0xd4'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x180')]=require(_0x309545('0x1e1'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['ZohoAccount']=require(_0x309545('0x11d'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x11a')]=require(_0x309545('0x9a'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x16a')]=require(_0x309545('0xa7'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x87')]=require('../api/intZendeskAccount/intZendeskAccount.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['ZendeskConfiguration']=require('../api/intZendeskConfiguration/intZendeskConfiguration.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['ZendeskField']=require(_0x309545('0x12e'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x28')]=require('../api/intFreshdeskAccount/intFreshdeskAccount.model')(db['sequelize'],Sequelize['DataTypes']),db[_0x309545('0x187')]=require('../api/intFreshdeskConfiguration/intFreshdeskConfiguration.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xe9')]=require(_0x309545('0xc3'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xcf')]=require(_0x309545('0x170'))(db['sequelize'],Sequelize['DataTypes']),db[_0x309545('0x4e')]=require(_0x309545('0x179'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['VtigerField']=require(_0x309545('0x7f'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['ServicenowAccount']=require(_0x309545('0x60'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1c9')]=require(_0x309545('0xd1'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['ServicenowField']=require(_0x309545('0x138'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x19d')]=require(_0x309545('0x1eb'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x11b')]=require(_0x309545('0x1b8'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xcc')]=require('../api/intDynamics365Field/intDynamics365Field.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1f')]=require('../api/intFreshsalesAccount/intFreshsalesAccount.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['FreshsalesConfiguration']=require('../api/intFreshsalesConfiguration/intFreshsalesConfiguration.model')(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['FreshsalesField']=require('../api/intFreshsalesField/intFreshsalesField.model')(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x16b')]=require('../api/integration/integration.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x7b')]=require('../api/network/network.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['ChatQueueReport']=require(_0x309545('0x145'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x19a')]=require('../api/chatInternalMessage/chatInternalMessage.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x12b')]=require(_0x309545('0xe8'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['JscriptyQuestionReport']=require('../api/jscriptyQuestionReport/jscriptyQuestionReport.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0xd5')]=require('../api/jscriptySessionReport/jscriptySessionReport.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0xa0')]=require(_0x309545('0x1ce'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x176')]=require(_0x309545('0x9f'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['SquareDetailsReport']=require('../api/squareReportDetail/squareReportDetail.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x148')]=require('../api/jscriptyProject/jscriptyProject.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x84')]=require(_0x309545('0x3d'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0xe0')]=require('../api/squareOdbc/squareOdbc.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x2c')]=require(_0x309545('0x181'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x16')]=require(_0x309545('0xb5'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x23')]=require(_0x309545('0x44'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x8e')]=require(_0x309545('0x168'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x192')]=require(_0x309545('0x0'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x6d')]=require('../api/campaign/campaign.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x90')]=require('../api/migration/migration.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0x163')]=require(_0x309545('0x13d'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['Plugin']=require(_0x309545('0x121'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['MailTransferReport']=require('../api/mailTransferReport/mailTransferReport.model')(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db[_0x309545('0xe3')]=require(_0x309545('0x160'))(db['sequelize'],Sequelize['DataTypes']),db[_0x309545('0xfb')]=require('../api/faxTransferReport/faxTransferReport.model')(db['sequelize'],Sequelize['DataTypes']),db[_0x309545('0x139')]=require(_0x309545('0x46'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x40')]=require(_0x309545('0x1dd'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1bb')]=require(_0x309545('0x15b'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['VoicePrefix']=require(_0x309545('0x15e'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x47')]=require(_0x309545('0x101'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db['UserProfileSection']=require(_0x309545('0x140'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db['UserProfileResource']=require(_0x309545('0x5c'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['Notification']=require(_0x309545('0x4a'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x4d')]=require(_0x309545('0x12a'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x70')]=require(_0x309545('0x1d'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x164')]=require(_0x309545('0x1a6'))(db[_0x309545('0x1a4')],Sequelize['DataTypes']),db['WhatsappMessage']=require(_0x309545('0x50'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x1')]=require(_0x309545('0x1b'))(db['sequelize'],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x159')]=require('../api/whatsappTransferReport/whatsappTransferReport.model')(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x55')]=require(_0x309545('0x157'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x39')]=require(_0x309545('0x1a9'))(db[_0x309545('0x1a4')],Sequelize[_0x309545('0x1d9')]),db[_0x309545('0x94')][_0x309545('0x21')](db[_0x309545('0x1cd')],{'as':'VoiceMail','onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x112')}),db[_0x309545('0x94')][_0x309545('0xee')](db[_0x309545('0x54')],{'as':_0x309545('0x185'),'foreignKey':_0x309545('0x112')}),db[_0x309545('0x94')]['hasMany'](db['UserVoiceQueueRt'],{'as':'VoiceQueuesRt','foreignKey':_0x309545('0x112')}),db[_0x309545('0x94')]['hasMany'](db[_0x309545('0x30')],{'as':_0x309545('0x10c'),'onDelete':_0x309545('0x3'),'hooks':!![]}),db[_0x309545('0x94')][_0x309545('0xee')](db[_0x309545('0x95')],{'as':'HopperFinals','foreignKey':_0x309545('0x112')}),db[_0x309545('0x94')][_0x309545('0xee')](db[_0x309545('0x191')],{'as':_0x309545('0x1c5'),'foreignKey':'UserId'}),db[_0x309545('0x94')]['hasMany'](db['ReportAgentPreview'],{'as':_0x309545('0xc8'),'foreignKey':_0x309545('0x112')}),db['User'][_0x309545('0xee')](db['OpenchannelInteraction'],{'as':_0x309545('0x1a2'),'foreignKey':_0x309545('0x112')}),db['User'][_0x309545('0xee')](db[_0x309545('0xae')],{'as':_0x309545('0x1a0'),'foreignKey':_0x309545('0x112')}),db[_0x309545('0x94')][_0x309545('0xee')](db[_0x309545('0xfd')],{'as':_0x309545('0x3a'),'foreignKey':_0x309545('0x112')}),db[_0x309545('0x94')][_0x309545('0xee')](db[_0x309545('0x1be')],{'as':'FaxInteractions','foreignKey':_0x309545('0x112')}),db[_0x309545('0x94')][_0x309545('0xee')](db[_0x309545('0x18e')],{'as':_0x309545('0x37'),'foreignKey':_0x309545('0x112')}),db['User'][_0x309545('0xee')](db[_0x309545('0x164')],{'as':_0x309545('0xb'),'foreignKey':'UserId'}),db['User'][_0x309545('0xee')](db[_0x309545('0x1c1')],{'as':'Notifications','foreignKey':_0x309545('0xa8')}),db[_0x309545('0x94')]['belongsTo'](db[_0x309545('0x47')],{'as':_0x309545('0x47'),'foreignKey':_0x309545('0x1e6'),'onDelete':_0x309545('0x153')}),db[_0x309545('0x94')][_0x309545('0x51')](db[_0x309545('0xa2')],{'as':'Groups','through':'chat_group_has_users'}),db[_0x309545('0x94')][_0x309545('0x51')](db['CmContact'],{'as':_0x309545('0x14e'),'through':_0x309545('0x9d')}),db[_0x309545('0x94')][_0x309545('0x51')](db[_0x309545('0x1bb')],{'as':_0x309545('0x8d'),'through':_0x309545('0x141')}),db[_0x309545('0x94')][_0x309545('0x51')](db['Team'],{'through':'user_has_teams'}),db['User'][_0x309545('0x51')](db[_0x309545('0x18e')],{'as':_0x309545('0x98'),'through':'user_has_mail_interactions'}),db['User'][_0x309545('0x51')](db[_0x309545('0xae')],{'as':_0x309545('0x1d6'),'through':_0x309545('0x64')}),db['User'][_0x309545('0x51')](db[_0x309545('0x1be')],{'as':_0x309545('0x35'),'through':_0x309545('0xe4')}),db['User'][_0x309545('0x51')](db[_0x309545('0xfd')],{'as':_0x309545('0x193'),'through':_0x309545('0xb0')}),db[_0x309545('0x94')]['belongsToMany'](db[_0x309545('0x156')],{'as':_0x309545('0x1a8'),'through':_0x309545('0x10a')}),db['User'][_0x309545('0x51')](db[_0x309545('0x164')],{'as':_0x309545('0x147'),'through':_0x309545('0x1c2')}),db['User'][_0x309545('0x51')](db[_0x309545('0xf8')],{'as':_0x309545('0x3b'),'through':_0x309545('0xf2'),'required':![]}),db[_0x309545('0x94')][_0x309545('0x51')](db[_0x309545('0xff')],{'as':'MailQueues','through':'UserMailQueue','required':![]}),db['User'][_0x309545('0x51')](db[_0x309545('0xa1')],{'as':_0x309545('0x85'),'through':_0x309545('0x52'),'required':![],'hooks':!![]}),db[_0x309545('0x94')][_0x309545('0x51')](db[_0x309545('0x72')],{'as':_0x309545('0x18a'),'through':_0x309545('0xf9'),'required':![]}),db[_0x309545('0x94')][_0x309545('0x51')](db['SmsQueue'],{'as':_0x309545('0xcd'),'through':_0x309545('0xab'),'required':![]}),db[_0x309545('0x94')]['belongsToMany'](db['OpenchannelQueue'],{'as':'OpenchannelQueues','through':'UserOpenchannelQueue','required':![]}),db[_0x309545('0x94')][_0x309545('0x51')](db[_0x309545('0x55')],{'as':'WhatsappQueues','through':_0x309545('0x1a3'),'required':![]}),db[_0x309545('0x94')][_0x309545('0x51')](db[_0x309545('0x1bb')],{'through':_0x309545('0x141')}),db['User']['belongsToMany'](db[_0x309545('0x152')],{'as':'VoicePrefixes','through':_0x309545('0x1a'),'required':![]}),db[_0x309545('0x94')][_0x309545('0x51')](db[_0x309545('0x2')],{'as':'ChatWebsites','through':_0x309545('0x6c')}),db[_0x309545('0x94')][_0x309545('0x51')](db[_0x309545('0x1ee')],{'as':_0x309545('0x197'),'through':_0x309545('0x1a1')}),db['User'][_0x309545('0x51')](db[_0x309545('0x1e8')],{'as':'MailAccounts','through':'user_has_mail_accounts'}),db[_0x309545('0x94')][_0x309545('0x51')](db['OpenchannelAccount'],{'as':_0x309545('0x24'),'through':'user_has_openchannel_accounts'}),db[_0x309545('0x94')]['belongsToMany'](db[_0x309545('0x6a')],{'as':_0x309545('0x114'),'through':'user_has_sms_accounts'}),db['User'][_0x309545('0x51')](db[_0x309545('0x4d')],{'as':'WhatsappAccounts','through':_0x309545('0x155')}),db[_0x309545('0x94')][_0x309545('0x51')](db[_0x309545('0x2c')],{'as':_0x309545('0x169'),'through':_0x309545('0x65')}),db[_0x309545('0xb4')]['hasMany'](db[_0x309545('0x30')],{'as':_0x309545('0xd0'),'onDelete':_0x309545('0x3'),'foreignKey':'ChanSpyId'}),db[_0x309545('0x1aa')][_0x309545('0xee')](db[_0x309545('0x30')],{'onDelete':_0x309545('0x3')}),db[_0x309545('0x30')][_0x309545('0xee')](db[_0x309545('0x30')],{'as':_0x309545('0xc7'),'onDelete':_0x309545('0x3')}),db[_0x309545('0x19f')][_0x309545('0x51')](db[_0x309545('0x77')],{'as':'Sounds','through':'moh_has_sounds'}),db[_0x309545('0xf8')][_0x309545('0xee')](db[_0x309545('0x26')],{'as':_0x309545('0x19b'),'foreignKey':_0x309545('0xfa')}),db[_0x309545('0xf8')]['hasMany'](db[_0x309545('0x15d')],{'as':_0x309545('0xa'),'foreignKey':_0x309545('0xfa')}),db[_0x309545('0xf8')]['hasMany'](db['CmHopperFinal'],{'as':_0x309545('0xbf'),'foreignKey':_0x309545('0xfa')}),db['VoiceQueue'][_0x309545('0xee')](db[_0x309545('0x191')],{'as':_0x309545('0x61'),'foreignKey':'VoiceQueueId'}),db[_0x309545('0xf8')][_0x309545('0xee')](db[_0x309545('0xc8')],{'as':_0x309545('0xc8'),'foreignKey':_0x309545('0xfa')}),db[_0x309545('0xf8')][_0x309545('0xee')](db[_0x309545('0x69')],{'as':_0x309545('0xec'),'foreignKey':_0x309545('0xfa')}),db[_0x309545('0xf8')][_0x309545('0xee')](db[_0x309545('0xd5')],{'as':_0x309545('0x171'),'foreignKey':'VoiceQueueId'}),db[_0x309545('0xf8')]['belongsTo'](db[_0x309545('0x1ac')],{'as':'Trunk','foreignKey':_0x309545('0xa6')}),db['VoiceQueue']['belongsTo'](db['Trunk'],{'as':'TrunkBackup','foreignKey':_0x309545('0x1d0')}),db[_0x309545('0xf8')][_0x309545('0x174')](db['Interval'],{'as':'Interval','foreignKey':'IntervalId'}),db[_0x309545('0xf8')]['belongsTo'](db[_0x309545('0x31')],{'as':_0x309545('0x16f'),'foreignKey':_0x309545('0x53')}),db[_0x309545('0xf8')][_0x309545('0x51')](db[_0x309545('0x1bb')],{'as':_0x309545('0x8d'),'through':_0x309545('0x99')}),db[_0x309545('0xf8')][_0x309545('0x51')](db['User'],{'as':_0x309545('0x137'),'through':_0x309545('0xf2')}),db[_0x309545('0xf8')][_0x309545('0x51')](db[_0x309545('0x8e')],{'as':_0x309545('0x15'),'through':'team_has_voice_queues'}),db[_0x309545('0xf8')][_0x309545('0x51')](db[_0x309545('0x1bb')],{'as':_0x309545('0x1ec'),'through':_0x309545('0xa3')}),db[_0x309545('0x54')][_0x309545('0x174')](db[_0x309545('0x94')],{'as':_0x309545('0x94'),'foreignKey':_0x309545('0x112')}),db['ScreenRecording'][_0x309545('0x174')](db[_0x309545('0x94')],{'as':_0x309545('0x94'),'foreignKey':_0x309545('0x112')}),db[_0x309545('0x1cd')][_0x309545('0xee')](db[_0x309545('0x19e')],{'as':'Messages','onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x1df'),'sourceKey':_0x309545('0x14b')}),db['VoiceMailMessage'][_0x309545('0x174')](db[_0x309545('0x1cd')],{'foreignKey':'mailboxuser','targetKey':_0x309545('0x14b')}),db[_0x309545('0x1cf')][_0x309545('0xee')](db[_0x309545('0x190')],{'as':_0x309545('0x1b0'),'foreignKey':_0x309545('0xbd'),'constraints':![]}),db[_0x309545('0x1cf')]['hasMany'](db[_0x309545('0xca')],{'as':_0x309545('0x16d'),'foreignKey':_0x309545('0xbd'),'constraints':![]}),db[_0x309545('0x1cf')]['belongsTo'](db['User'],{'as':_0x309545('0x94'),'foreignKey':_0x309545('0x112')}),db[_0x309545('0x1cf')]['belongsTo'](db[_0x309545('0x7e')],{'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4')}),db['MailAccount']['hasOne'](db[_0x309545('0xc2')],{'as':'Imap','foreignKey':'MailAccountId','onDelete':_0x309545('0x3')}),db['MailAccount']['hasOne'](db[_0x309545('0x135')],{'as':_0x309545('0x12d'),'foreignKey':_0x309545('0x119'),'onDelete':_0x309545('0x3')}),db[_0x309545('0x1e8')][_0x309545('0xee')](db[_0x309545('0x13c')],{'as':'Dispositions','foreignKey':_0x309545('0x119')}),db['MailAccount'][_0x309545('0xee')](db['CannedAnswer'],{'as':_0x309545('0x107'),'foreignKey':'MailAccountId'}),db[_0x309545('0x1e8')][_0x309545('0xee')](db['MailMessage'],{'as':_0x309545('0x1db'),'foreignKey':_0x309545('0x119')}),db[_0x309545('0x1e8')][_0x309545('0xee')](db['MailInteraction'],{'as':_0x309545('0x1b7')}),db[_0x309545('0x1e8')][_0x309545('0xee')](db[_0x309545('0x6e')],{'as':_0x309545('0xc7')}),db[_0x309545('0x1e8')][_0x309545('0x174')](db['CmList'],{'as':_0x309545('0x71'),'foreignKey':'ListId'}),db[_0x309545('0x1e8')][_0x309545('0x174')](db['Template'],{'as':_0x309545('0xd8'),'foreignKey':'TemplateId'}),db[_0x309545('0x1e8')]['belongsTo'](db[_0x309545('0x31')],{'as':_0x309545('0x16f'),'foreignKey':_0x309545('0x53')}),db[_0x309545('0x1e8')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':_0x309545('0x129')}),db[_0x309545('0xff')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':_0x309545('0x49')}),db[_0x309545('0xff')][_0x309545('0x51')](db['Team'],{'through':_0x309545('0xf5'),'as':'Teams'}),db['MailInteraction'][_0x309545('0xee')](db[_0x309545('0x166')],{'as':_0x309545('0x1db'),'onDelete':'cascade','foreignKey':_0x309545('0x36')}),db[_0x309545('0x18e')][_0x309545('0x174')](db['MailAccount'],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x119')}),db[_0x309545('0x18e')][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4')}),db[_0x309545('0x18e')]['belongsTo'](db[_0x309545('0x94')],{'as':_0x309545('0x1c'),'foreignKey':'UserId'}),db[_0x309545('0x18e')][_0x309545('0x51')](db['Tag'],{'through':_0x309545('0x10b'),'as':'Tags'}),db[_0x309545('0x18e')][_0x309545('0x51')](db['Tag'],{'through':_0x309545('0x10b'),'as':_0x309545('0x1cb')}),db[_0x309545('0x18e')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':'Users','through':_0x309545('0x11e'),'foreignKey':'MailInteractionId'}),db[_0x309545('0x166')][_0x309545('0xee')](db[_0x309545('0x163')],{'as':_0x309545('0x1c8'),'onDelete':'cascade'}),db[_0x309545('0x166')][_0x309545('0x174')](db[_0x309545('0x94')],{'as':_0x309545('0x94')}),db[_0x309545('0x166')][_0x309545('0x174')](db[_0x309545('0x7e')],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x91')}),db[_0x309545('0x166')]['belongsTo'](db[_0x309545('0x18e')],{'as':_0x309545('0x154'),'foreignKey':_0x309545('0x36')}),db['MailMessage'][_0x309545('0x174')](db['MailAccount'],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x119')}),db[_0x309545('0x6e')][_0x309545('0x174')](db[_0x309545('0x94')],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x6e')]['belongsTo'](db['MailQueue'],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x6e')][_0x309545('0x174')](db[_0x309545('0x1e8')],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x6e')][_0x309545('0x174')](db[_0x309545('0x120')],{'onDelete':'restrict','foreignKey':'IntervalId'}),db[_0x309545('0x6e')][_0x309545('0x174')](db[_0x309545('0x92')],{'onDelete':_0x309545('0x153'),'foreignKey':'TagId'}),db[_0x309545('0xf7')][_0x309545('0x174')](db[_0x309545('0x1e8')],{}),db[_0x309545('0xf7')][_0x309545('0x174')](db[_0x309545('0x1bb')],{'as':_0x309545('0x71'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0xf7')][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4')}),db[_0x309545('0xf7')][_0x309545('0x174')](db[_0x309545('0x18e')],{}),db['MailQueueReport'][_0x309545('0x174')](db[_0x309545('0x166')],{}),db['MailQueueReport'][_0x309545('0x174')](db[_0x309545('0x94')],{}),db['MailQueueReport']['belongsTo'](db['MailQueue'],{}),db['Dashboard'][_0x309545('0xee')](db[_0x309545('0x27')],{'as':_0x309545('0x165'),'onDelete':_0x309545('0x3')}),db['FaxAccount'][_0x309545('0xee')](db['Disposition'],{'as':_0x309545('0x172'),'foreignKey':_0x309545('0x1af')}),db['FaxAccount']['hasMany'](db[_0x309545('0x75')],{'as':'Answers','foreignKey':_0x309545('0x1af')}),db[_0x309545('0x1ee')]['hasMany'](db[_0x309545('0x1be')],{'as':_0x309545('0x1b7')}),db[_0x309545('0x1ee')][_0x309545('0xee')](db[_0x309545('0x43')],{'as':_0x309545('0xc7')}),db['FaxAccount']['hasMany'](db[_0x309545('0x30')],{'as':'Exntensions','onDelete':_0x309545('0x3')}),db[_0x309545('0x1ee')][_0x309545('0xee')](db[_0x309545('0x162')],{'as':'Messages'}),db[_0x309545('0x1ee')][_0x309545('0x174')](db['Trunk'],{'as':'Trunk'}),db[_0x309545('0x1ee')]['belongsTo'](db[_0x309545('0x1bb')],{'as':_0x309545('0x71'),'foreignKey':'ListId'}),db[_0x309545('0x1ee')]['belongsTo'](db[_0x309545('0x31')],{'as':_0x309545('0x16f'),'foreignKey':_0x309545('0x53')}),db[_0x309545('0x1ee')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':'Agents','through':_0x309545('0x1a1')}),db[_0x309545('0x43')][_0x309545('0x174')](db[_0x309545('0x94')],{'onDelete':_0x309545('0x153')}),db['FaxApplication'][_0x309545('0x174')](db['FaxQueue'],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x43')][_0x309545('0x174')](db[_0x309545('0x1ee')],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x43')]['belongsTo'](db['Tag'],{'onDelete':'restrict','foreignKey':_0x309545('0x100')}),db['FaxInteraction'][_0x309545('0xee')](db['FaxMessage'],{'as':_0x309545('0x1db'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0xd9')}),db[_0x309545('0x1be')][_0x309545('0x174')](db[_0x309545('0x1ee')],{'as':'Account','foreignKey':_0x309545('0x1af')}),db[_0x309545('0x1be')]['belongsTo'](db['CmContact'],{'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4')}),db[_0x309545('0x1be')][_0x309545('0x174')](db[_0x309545('0x94')],{'as':_0x309545('0x1c'),'foreignKey':_0x309545('0x112')}),db[_0x309545('0x1be')][_0x309545('0x51')](db[_0x309545('0x92')],{'through':'fax_interaction_has_tags','as':_0x309545('0x2b')}),db[_0x309545('0x1be')][_0x309545('0x51')](db[_0x309545('0x92')],{'through':_0x309545('0x10'),'as':'ThroughTags'}),db[_0x309545('0x1be')][_0x309545('0x51')](db['User'],{'as':'Users','through':_0x309545('0xe4'),'foreignKey':'FaxInteractionId'}),db['FaxMessage']['belongsTo'](db[_0x309545('0x94')],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x94')}),db[_0x309545('0x162')][_0x309545('0x174')](db['FaxInteraction'],{'as':'Interaction','foreignKey':_0x309545('0xd9')}),db[_0x309545('0x162')]['belongsTo'](db[_0x309545('0x7e')],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x91')}),db[_0x309545('0x162')][_0x309545('0x174')](db[_0x309545('0x163')],{'as':_0x309545('0x163'),'foreignKey':_0x309545('0x82')}),db[_0x309545('0x162')][_0x309545('0x174')](db['FaxAccount'],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x1af')}),db[_0x309545('0x72')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':'Agents','through':_0x309545('0xf9')}),db[_0x309545('0x72')]['belongsToMany'](db['Team'],{'through':_0x309545('0x8b'),'as':_0x309545('0x15')}),db[_0x309545('0x17d')][_0x309545('0x174')](db[_0x309545('0x1ee')],{}),db[_0x309545('0x17d')][_0x309545('0x174')](db[_0x309545('0x1bb')],{'as':_0x309545('0x71'),'foreignKey':'ListId'}),db[_0x309545('0x17d')][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':'Contact','foreignKey':_0x309545('0x1b4')}),db[_0x309545('0x17d')][_0x309545('0x174')](db[_0x309545('0x1be')],{}),db[_0x309545('0x17d')][_0x309545('0x174')](db[_0x309545('0x162')],{}),db[_0x309545('0x17d')][_0x309545('0x174')](db['User'],{}),db[_0x309545('0x17d')]['belongsTo'](db['FaxQueue'],{}),db['SmsAccount'][_0x309545('0xee')](db[_0x309545('0x13c')],{'as':'Dispositions','foreignKey':_0x309545('0x14f')}),db[_0x309545('0x6a')][_0x309545('0xee')](db[_0x309545('0x75')],{'as':_0x309545('0x107'),'foreignKey':'SmsAccountId'}),db[_0x309545('0x6a')][_0x309545('0xee')](db['SmsMessage'],{'as':_0x309545('0x1db'),'foreignKey':_0x309545('0x14f')}),db[_0x309545('0x6a')][_0x309545('0xee')](db[_0x309545('0xfd')],{'as':_0x309545('0x1b7')}),db[_0x309545('0x6a')]['hasMany'](db[_0x309545('0x10e')],{'as':_0x309545('0xc7')}),db[_0x309545('0x6a')][_0x309545('0x174')](db[_0x309545('0x1bb')],{'as':_0x309545('0x71'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0x6a')][_0x309545('0x174')](db[_0x309545('0x31')],{'as':_0x309545('0x16f'),'foreignKey':_0x309545('0x53')}),db[_0x309545('0x6a')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':_0x309545('0x9')}),db[_0x309545('0x10e')][_0x309545('0x174')](db[_0x309545('0x94')],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x10e')]['belongsTo'](db[_0x309545('0x3e')],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x10e')]['belongsTo'](db[_0x309545('0x6a')],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x10e')][_0x309545('0x174')](db[_0x309545('0x120')],{'onDelete':'restrict','foreignKey':_0x309545('0x105')}),db[_0x309545('0x10e')]['belongsTo'](db['Tag'],{'onDelete':_0x309545('0x153'),'foreignKey':'TagId'}),db[_0x309545('0xfd')][_0x309545('0xee')](db[_0x309545('0x10f')],{'as':_0x309545('0x1db'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x96')}),db[_0x309545('0xfd')][_0x309545('0x174')](db[_0x309545('0x6a')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x14f')}),db[_0x309545('0xfd')][_0x309545('0x174')](db['CmContact'],{'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4')}),db['SmsInteraction']['belongsTo'](db[_0x309545('0x94')],{'as':_0x309545('0x1c'),'foreignKey':_0x309545('0x112')}),db['SmsInteraction'][_0x309545('0x51')](db[_0x309545('0x92')],{'through':_0x309545('0x16e'),'as':_0x309545('0x2b')}),db[_0x309545('0xfd')]['belongsToMany'](db[_0x309545('0x92')],{'through':'sms_interaction_has_tags','as':'ThroughTags'}),db[_0x309545('0xfd')]['belongsToMany'](db['User'],{'as':'Users','through':_0x309545('0xb0'),'foreignKey':_0x309545('0x96')}),db[_0x309545('0x10f')][_0x309545('0x174')](db[_0x309545('0x94')],{'as':_0x309545('0x94')}),db[_0x309545('0x10f')][_0x309545('0x174')](db[_0x309545('0x7e')],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x91')}),db[_0x309545('0x10f')][_0x309545('0x174')](db[_0x309545('0xfd')],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x154'),'foreignKey':_0x309545('0x96')}),db[_0x309545('0x10f')][_0x309545('0x174')](db[_0x309545('0x6a')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x14f')}),db[_0x309545('0x3e')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':'UserSmsQueue','foreignKey':_0x309545('0x113')}),db[_0x309545('0x3e')][_0x309545('0x51')](db[_0x309545('0x8e')],{'through':_0x309545('0x57'),'as':'Teams'}),db['OpenchannelAccount'][_0x309545('0xee')](db[_0x309545('0x13c')],{'as':_0x309545('0x172'),'foreignKey':'OpenchannelAccountId'}),db[_0x309545('0x5f')][_0x309545('0xee')](db[_0x309545('0x75')],{'as':'Answers','foreignKey':'OpenchannelAccountId'}),db[_0x309545('0x5f')]['hasMany'](db['OpenchannelInteraction'],{'as':'Interactions','foreignKey':_0x309545('0x83')}),db['OpenchannelAccount'][_0x309545('0xee')](db[_0x309545('0x1e3')],{'as':_0x309545('0x1db'),'foreignKey':_0x309545('0x83')}),db[_0x309545('0x5f')][_0x309545('0xee')](db[_0x309545('0xef')],{'as':'Applications','foreignKey':_0x309545('0x83')}),db['OpenchannelAccount'][_0x309545('0x174')](db[_0x309545('0x1bb')],{'as':_0x309545('0x71'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0x5f')][_0x309545('0x174')](db[_0x309545('0x31')],{'as':_0x309545('0x16f'),'foreignKey':_0x309545('0x53')}),db[_0x309545('0x5f')]['belongsToMany'](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':_0x309545('0x97')}),db[_0x309545('0xef')][_0x309545('0x174')](db[_0x309545('0x94')],{'onDelete':_0x309545('0x153')}),db[_0x309545('0xef')][_0x309545('0x174')](db[_0x309545('0x17e')],{'onDelete':_0x309545('0x153'),'foreignKey':_0x309545('0x194')}),db[_0x309545('0xef')]['belongsTo'](db['OpenchannelAccount'],{'onDelete':_0x309545('0x153'),'foreignKey':'OpenchannelAccountId'}),db['OpenchannelApplication'][_0x309545('0x174')](db[_0x309545('0x120')],{'onDelete':'restrict','foreignKey':_0x309545('0x105')}),db[_0x309545('0xef')]['belongsTo'](db[_0x309545('0x92')],{'onDelete':_0x309545('0x153'),'foreignKey':_0x309545('0x100')}),db[_0x309545('0x156')]['hasMany'](db[_0x309545('0x1e3')],{'as':_0x309545('0x1db'),'onDelete':_0x309545('0x3'),'foreignKey':'OpenchannelInteractionId'}),db[_0x309545('0x156')][_0x309545('0x174')](db[_0x309545('0x5f')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x83')}),db[_0x309545('0x156')][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4')}),db[_0x309545('0x156')][_0x309545('0x174')](db[_0x309545('0x94')],{'as':_0x309545('0x1c'),'foreignKey':_0x309545('0x112')}),db['OpenchannelInteraction'][_0x309545('0x51')](db[_0x309545('0x92')],{'through':_0x309545('0x17f'),'as':_0x309545('0x2b')}),db[_0x309545('0x156')][_0x309545('0x51')](db[_0x309545('0x92')],{'through':'openchannel_interaction_has_tags','as':_0x309545('0x1cb')}),db['OpenchannelInteraction'][_0x309545('0x51')](db[_0x309545('0x94')],{'as':'Users','through':'user_has_openchannel_interactions','foreignKey':_0x309545('0xf4')}),db['OpenchannelMessage']['belongsTo'](db[_0x309545('0x94')],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x94')}),db[_0x309545('0x1e3')][_0x309545('0x174')](db[_0x309545('0x7e')],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x91')}),db[_0x309545('0x1e3')][_0x309545('0x174')](db['OpenchannelInteraction'],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x154'),'foreignKey':_0x309545('0xf4')}),db[_0x309545('0x1e3')]['belongsTo'](db['Attachment'],{'as':_0x309545('0x163'),'foreignKey':_0x309545('0x82')}),db[_0x309545('0x1e3')][_0x309545('0x174')](db['OpenchannelAccount'],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x83')}),db[_0x309545('0x17e')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':_0x309545('0xdd'),'foreignKey':_0x309545('0x194')}),db[_0x309545('0x17e')][_0x309545('0x51')](db[_0x309545('0x8e')],{'through':_0x309545('0x123'),'as':_0x309545('0x15')}),db[_0x309545('0x2')][_0x309545('0xee')](db['Disposition'],{'as':_0x309545('0x172'),'foreignKey':_0x309545('0xc')}),db[_0x309545('0x2')][_0x309545('0xee')](db[_0x309545('0x75')],{'as':'Answers','foreignKey':'ChatWebsiteId'}),db[_0x309545('0x2')]['hasMany'](db[_0x309545('0x4b')],{'as':_0x309545('0x177')}),db[_0x309545('0x2')]['hasMany'](db['ChatInteraction'],{'as':_0x309545('0x1b7')}),db[_0x309545('0x2')][_0x309545('0xee')](db['ChatApplication'],{'as':_0x309545('0xc7')}),db[_0x309545('0x2')][_0x309545('0xee')](db[_0x309545('0xed')],{'as':_0x309545('0x1db')}),db[_0x309545('0x2')]['belongsTo'](db['CmList'],{'as':_0x309545('0x71'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0x2')]['belongsTo'](db['Interval'],{'as':_0x309545('0x120'),'foreignKey':_0x309545('0x105')}),db[_0x309545('0x2')][_0x309545('0x174')](db['Pause'],{'as':_0x309545('0x16f'),'foreignKey':_0x309545('0x53')}),db['ChatWebsite'][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':'user_has_chat_websites'}),db[_0x309545('0xf')][_0x309545('0x174')](db['OpenchannelAccount'],{}),db[_0x309545('0xf')]['belongsTo'](db[_0x309545('0x1bb')],{'as':_0x309545('0x71'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0xf')][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':'Contact','foreignKey':_0x309545('0x1b4')}),db[_0x309545('0xf')][_0x309545('0x174')](db[_0x309545('0x156')],{}),db[_0x309545('0xf')][_0x309545('0x174')](db[_0x309545('0x1e3')],{}),db[_0x309545('0xf')][_0x309545('0x174')](db['User'],{}),db[_0x309545('0xf')][_0x309545('0x174')](db['OpenchannelQueue'],{}),db[_0x309545('0x118')][_0x309545('0x174')](db[_0x309545('0x94')],{'as':_0x309545('0x173'),'foreignKey':_0x309545('0x112'),'onDelete':_0x309545('0x153')}),db[_0x309545('0x118')][_0x309545('0x174')](db[_0x309545('0xa1')],{'as':_0x309545('0x1ab'),'foreignKey':'ChatQueueId','onDelete':_0x309545('0x153')}),db['ChatApplication'][_0x309545('0x174')](db[_0x309545('0x2')],{'as':_0x309545('0x10d'),'foreignKey':'ChatWebsiteId','onDelete':'restrict'}),db['ChatApplication'][_0x309545('0x174')](db[_0x309545('0x92')],{'onDelete':_0x309545('0x153'),'foreignKey':_0x309545('0x100')}),db[_0x309545('0xae')]['hasMany'](db[_0x309545('0xed')],{'as':_0x309545('0x1db'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0xf6')}),db[_0x309545('0xae')][_0x309545('0x174')](db[_0x309545('0x2')],{'as':_0x309545('0x16c'),'foreignKey':'ChatWebsiteId'}),db[_0x309545('0xae')][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':_0x309545('0x91'),'foreignKey':'ContactId'}),db[_0x309545('0xae')][_0x309545('0x174')](db[_0x309545('0x94')],{'as':_0x309545('0x1c'),'foreignKey':'UserId'}),db[_0x309545('0xae')][_0x309545('0x51')](db[_0x309545('0x92')],{'through':'chat_interaction_has_tags','as':_0x309545('0x2b')}),db[_0x309545('0xae')][_0x309545('0x51')](db[_0x309545('0x92')],{'through':_0x309545('0x42'),'as':_0x309545('0x1cb')}),db[_0x309545('0xae')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x6f'),'through':_0x309545('0x64'),'foreignKey':_0x309545('0xf6')}),db[_0x309545('0xed')][_0x309545('0x174')](db[_0x309545('0x94')],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x94')}),db[_0x309545('0xed')][_0x309545('0x174')](db[_0x309545('0x7e')],{'onDelete':_0x309545('0x3'),'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4')}),db[_0x309545('0xed')][_0x309545('0x174')](db[_0x309545('0xae')],{'onDelete':'cascade','as':'Interaction','foreignKey':_0x309545('0xf6')}),db['ChatMessage']['belongsTo'](db[_0x309545('0x163')],{'as':_0x309545('0x163'),'foreignKey':_0x309545('0x82')}),db['ChatMessage'][_0x309545('0x174')](db[_0x309545('0x2')],{'as':'Account','foreignKey':_0x309545('0xc')}),db[_0x309545('0x188')]['belongsTo'](db[_0x309545('0x7e')],{'onDelete':_0x309545('0x3'),'as':'Contact','foreignKey':_0x309545('0x1b4')}),db[_0x309545('0x188')][_0x309545('0x174')](db[_0x309545('0x2')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0xc')}),db['ChatQueue'][_0x309545('0x51')](db[_0x309545('0x94')],{'as':'Agents','through':'UserChatQueue','hooks':!![]}),db[_0x309545('0xa1')][_0x309545('0x51')](db[_0x309545('0x8e')],{'through':_0x309545('0x1ae'),'as':'Teams'}),db[_0x309545('0xa2')]['hasMany'](db[_0x309545('0x19a')],{'as':_0x309545('0x1db'),'foreignKey':_0x309545('0x1da'),'onDelete':_0x309545('0x3')}),db[_0x309545('0xa2')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':'Members','through':_0x309545('0x1cc')}),db[_0x309545('0x4b')][_0x309545('0x174')](db[_0x309545('0x2')],{'as':_0x309545('0x10d'),'foreignKey':_0x309545('0xc')}),db[_0x309545('0x4c')]['hasMany'](db[_0x309545('0x7e')],{'as':_0x309545('0x14e'),'foreignKey':'CompanyId'}),db['CmContact'][_0x309545('0xee')](db[_0x309545('0x15d')],{'as':'Hoppers','foreignKey':'ContactId'}),db[_0x309545('0x7e')][_0x309545('0xee')](db['CmHopperFinal'],{'as':_0x309545('0xbf'),'foreignKey':'ContactId'}),db[_0x309545('0x7e')][_0x309545('0xee')](db[_0x309545('0x191')],{'as':_0x309545('0x61'),'foreignKey':'ContactId'}),db[_0x309545('0x7e')]['hasMany'](db[_0x309545('0xc8')],{'as':'ReportAgentPreview','foreignKey':'ContactId'}),db[_0x309545('0x7e')]['hasMany'](db[_0x309545('0xd5')],{'as':_0x309545('0x171'),'foreignKey':_0x309545('0x1b4')}),db[_0x309545('0x7e')][_0x309545('0xee')](db[_0x309545('0x156')],{'as':_0x309545('0x1a2'),'foreignKey':_0x309545('0x1b4'),'onDelete':_0x309545('0x153')}),db[_0x309545('0x7e')][_0x309545('0xee')](db[_0x309545('0xae')],{'as':_0x309545('0x1a0'),'foreignKey':_0x309545('0x1b4'),'onDelete':_0x309545('0x153')}),db['CmContact']['hasMany'](db[_0x309545('0xfd')],{'as':_0x309545('0x3a'),'foreignKey':_0x309545('0x1b4'),'onDelete':'restrict'}),db[_0x309545('0x7e')][_0x309545('0xee')](db['FaxInteraction'],{'as':_0x309545('0xa5'),'foreignKey':_0x309545('0x1b4'),'onDelete':_0x309545('0x153')}),db['CmContact'][_0x309545('0xee')](db[_0x309545('0x18e')],{'as':'MailInteractions','foreignKey':_0x309545('0x1b4'),'onDelete':'restrict'}),db['CmContact'][_0x309545('0x174')](db['CmCompany'],{'as':_0x309545('0x41'),'foreignKey':_0x309545('0x1c7')}),db[_0x309545('0x7e')]['belongsTo'](db['CmList'],{'as':_0x309545('0x71'),'foreignKey':_0x309545('0xda'),'onDelete':_0x309545('0x3')}),db[_0x309545('0x7e')]['belongsToMany'](db[_0x309545('0x94')],{'as':'Users','through':_0x309545('0x9d')}),db[_0x309545('0x7e')][_0x309545('0x51')](db['Tag'],{'as':'Tags','through':'cm_contact_has_tags'}),db[_0x309545('0x7e')][_0x309545('0x51')](db['Tag'],{'through':'cm_contact_has_tags','as':_0x309545('0x1cb')}),db[_0x309545('0x15d')]['belongsTo'](db[_0x309545('0x7e')],{'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4'),'onDelete':_0x309545('0x3')}),db[_0x309545('0x15d')][_0x309545('0x174')](db[_0x309545('0x1bb')],{'as':_0x309545('0x71'),'foreignKey':_0x309545('0xda'),'onDelete':'cascade'}),db[_0x309545('0x15d')]['belongsTo'](db[_0x309545('0x94')],{'as':_0x309545('0x173'),'foreignKey':_0x309545('0x112')}),db[_0x309545('0x15d')][_0x309545('0x174')](db[_0x309545('0xf8')],{'as':_0x309545('0x1ab'),'foreignKey':_0x309545('0xfa'),'onDelete':_0x309545('0x3')}),db[_0x309545('0x15d')][_0x309545('0x174')](db[_0x309545('0x6d')],{'as':_0x309545('0x6d'),'foreignKey':_0x309545('0xd2'),'onDelete':_0x309545('0x3')}),db['CmHopper']['belongsTo'](db[_0x309545('0x94')],{'as':_0x309545('0x1c'),'foreignKey':_0x309545('0xdb')}),db[_0x309545('0x69')][_0x309545('0x174')](db['CmContact'],{'as':'Contact','foreignKey':_0x309545('0x1b4'),'onDelete':'cascade'}),db[_0x309545('0x69')]['belongsTo'](db['CmList'],{'as':'List','foreignKey':'ListId','onDelete':_0x309545('0x3')}),db['CmHopperBlack'][_0x309545('0x174')](db['VoiceQueue'],{'as':_0x309545('0x1ab'),'foreignKey':_0x309545('0xfa'),'onDelete':'cascade'}),db[_0x309545('0x69')]['belongsTo'](db['Campaign'],{'as':_0x309545('0x6d'),'foreignKey':_0x309545('0xd2'),'onDelete':_0x309545('0x3')}),db[_0x309545('0x1b1')][_0x309545('0xee')](db[_0x309545('0x149')],{'as':{'plural':_0x309545('0x11c'),'singular':'OneAll'},'foreignKey':_0x309545('0x13'),'onDelete':'cascade','hooks':!![]}),db[_0x309545('0x1b1')]['hasMany'](db[_0x309545('0x149')],{'as':{'plural':_0x309545('0x11f'),'singular':_0x309545('0x1e0')},'foreignKey':_0x309545('0x1e'),'onDelete':'cascade','hooks':!![]}),db[_0x309545('0x1b1')]['hasMany'](db[_0x309545('0xb9')],{'as':_0x309545('0x4'),'foreignKey':'AutomationId','onDelete':_0x309545('0x3'),'hooks':!![]}),db[_0x309545('0x13c')][_0x309545('0xee')](db['Disposition'],{'as':_0x309545('0x172'),'foreignKey':_0x309545('0xa4'),'onDelete':'cascade'}),db[_0x309545('0x120')][_0x309545('0xee')](db[_0x309545('0x120')],{'as':_0x309545('0xad'),'foreignKey':'IntervalId','onDelete':_0x309545('0x3'),'hooks':!![],'required':![]}),db[_0x309545('0x120')]['hasMany'](db[_0x309545('0x30')],{'as':_0x309545('0x10c'),'foreignKey':'IntervalId','onDelete':_0x309545('0x153')}),db[_0x309545('0x120')]['hasMany'](db[_0x309545('0x6e')],{'as':_0x309545('0x1ad'),'foreignKey':_0x309545('0x105')}),db['Interval']['hasMany'](db[_0x309545('0x118')],{'as':_0x309545('0x1a7'),'foreignKey':_0x309545('0x105')}),db[_0x309545('0x120')]['hasMany'](db[_0x309545('0x43')],{'as':_0x309545('0x8'),'foreignKey':_0x309545('0x105')}),db[_0x309545('0x120')][_0x309545('0xee')](db[_0x309545('0x10e')],{'as':'SmsApplications','foreignKey':_0x309545('0x105')}),db['Schedule'][_0x309545('0x174')](db[_0x309545('0x1e8')],{}),db[_0x309545('0x80')][_0x309545('0x174')](db[_0x309545('0xdc')],{'foreignKey':'DefaultReportId'}),db[_0x309545('0x80')][_0x309545('0x174')](db[_0x309545('0x4f')],{'foreignKey':_0x309545('0x132')}),db[_0x309545('0x77')][_0x309545('0x51')](db[_0x309545('0x19f')],{'as':'Mohs','through':'moh_has_sounds','onDelete':_0x309545('0x153')}),db[_0x309545('0x92')]['belongsToMany'](db['CmContact'],{'through':_0x309545('0x1bf')}),db[_0x309545('0x92')][_0x309545('0x51')](db[_0x309545('0xae')],{'through':_0x309545('0x42')}),db[_0x309545('0x92')][_0x309545('0x51')](db[_0x309545('0x18e')],{'through':_0x309545('0x10b')}),db[_0x309545('0x92')][_0x309545('0x51')](db[_0x309545('0xfd')],{'through':_0x309545('0x16e')}),db['Tag'][_0x309545('0x51')](db[_0x309545('0x1be')],{'through':_0x309545('0x10')}),db['Tag'][_0x309545('0x51')](db[_0x309545('0x156')],{'through':_0x309545('0x17f')}),db[_0x309545('0x92')][_0x309545('0x51')](db[_0x309545('0x164')],{'through':_0x309545('0xd')}),db['Trigger']['hasMany'](db[_0x309545('0x149')],{'as':{'plural':_0x309545('0xc1'),'singular':_0x309545('0xac')},'foreignKey':_0x309545('0x78'),'onDelete':'cascade','hooks':!![]}),db[_0x309545('0xbe')][_0x309545('0xee')](db[_0x309545('0x149')],{'as':{'plural':_0x309545('0x184'),'singular':_0x309545('0xa9')},'foreignKey':_0x309545('0xe1'),'onDelete':_0x309545('0x3'),'hooks':!![]}),db[_0x309545('0xbe')]['hasMany'](db[_0x309545('0xb9')],{'as':_0x309545('0x4'),'foreignKey':_0x309545('0x22'),'onDelete':_0x309545('0x3'),'hooks':!![]}),db[_0x309545('0x4f')]['hasMany'](db[_0x309545('0xe2')],{'as':_0x309545('0xbb'),'onDelete':'cascade','foreignKey':_0x309545('0x132'),'hooks':!![]}),db[_0x309545('0xdc')][_0x309545('0xee')](db[_0x309545('0xe2')],{'as':_0x309545('0xbb'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x7')}),db[_0x309545('0x1d2')][_0x309545('0xee')](db[_0x309545('0xe2')],{'as':_0x309545('0xbb'),'onDelete':'cascade','foreignKey':'MetricId'}),db[_0x309545('0xe2')][_0x309545('0x174')](db[_0x309545('0x1d2')],{'foreignKey':_0x309545('0x182')}),db[_0x309545('0x1c3')][_0x309545('0xee')](db[_0x309545('0x29')],{'as':_0x309545('0xfc'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x117')}),db['SalesforceConfiguration'][_0x309545('0xee')](db[_0x309545('0x67')],{'as':_0x309545('0xc4'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0x29')]['hasMany'](db['SalesforceField'],{'as':_0x309545('0x116'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0x29')][_0x309545('0xee')](db[_0x309545('0x67')],{'as':'Fields','onDelete':'cascade','foreignKey':'FieldId'}),db[_0x309545('0x29')][_0x309545('0x174')](db[_0x309545('0x1c3')],{'as':'Account','foreignKey':_0x309545('0x117')}),db[_0x309545('0x67')]['hasMany'](db[_0x309545('0x67')],{'as':_0x309545('0x1e2'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0x67')]['hasMany'](db[_0x309545('0x67')],{'as':'Description','foreignKey':_0x309545('0x18b')}),db[_0x309545('0x67')][_0x309545('0xee')](db[_0x309545('0x67')],{'as':_0x309545('0xf1'),'foreignKey':_0x309545('0x63')}),db[_0x309545('0x67')][_0x309545('0x174')](db[_0x309545('0x122')],{'as':_0x309545('0x122'),'foreignKey':_0x309545('0x167')}),db[_0x309545('0x150')][_0x309545('0xee')](db[_0x309545('0x9c')],{'as':_0x309545('0xfc'),'onDelete':'cascade','foreignKey':_0x309545('0x117')}),db[_0x309545('0x9c')][_0x309545('0xee')](db[_0x309545('0xd3')],{'as':_0x309545('0xc4'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0xc9')}),db['SugarcrmConfiguration'][_0x309545('0xee')](db[_0x309545('0xd3')],{'as':_0x309545('0x116'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0x9c')][_0x309545('0xee')](db[_0x309545('0xd3')],{'as':_0x309545('0xbb'),'onDelete':'cascade','foreignKey':'FieldId'}),db[_0x309545('0x9c')][_0x309545('0x174')](db[_0x309545('0x150')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x117')}),db[_0x309545('0xd3')]['hasMany'](db['SugarcrmField'],{'as':'Subject','foreignKey':_0x309545('0xc9')}),db[_0x309545('0xd3')]['hasMany'](db['SugarcrmField'],{'as':'Description','foreignKey':'DescriptionId'}),db[_0x309545('0xd3')][_0x309545('0xee')](db[_0x309545('0xd3')],{'as':_0x309545('0xf1'),'foreignKey':_0x309545('0x63')}),db[_0x309545('0xd3')]['belongsTo'](db['Variable'],{'as':_0x309545('0x122'),'foreignKey':_0x309545('0x167')}),db['DeskAccount']['hasMany'](db[_0x309545('0x144')],{'as':_0x309545('0xfc'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x117')}),db['DeskConfiguration'][_0x309545('0xee')](db['DeskField'],{'as':_0x309545('0xc4'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0x144')][_0x309545('0xee')](db[_0x309545('0x180')],{'as':_0x309545('0x116'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0x144')][_0x309545('0xee')](db[_0x309545('0x180')],{'as':'Fields','onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x63')}),db[_0x309545('0x144')]['belongsTo'](db[_0x309545('0x1b9')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x117')}),db[_0x309545('0x144')]['belongsToMany'](db[_0x309545('0x92')],{'through':_0x309545('0x5e')}),db[_0x309545('0x180')][_0x309545('0xee')](db[_0x309545('0x180')],{'as':_0x309545('0x1e2'),'foreignKey':'SubjectId'}),db[_0x309545('0x180')][_0x309545('0xee')](db['DeskField'],{'as':_0x309545('0xeb'),'foreignKey':'DescriptionId'}),db[_0x309545('0x180')][_0x309545('0xee')](db[_0x309545('0x180')],{'as':'Field','foreignKey':_0x309545('0x63')}),db[_0x309545('0x180')][_0x309545('0x174')](db[_0x309545('0x122')],{'as':_0x309545('0x122'),'foreignKey':_0x309545('0x167')}),db[_0x309545('0x106')]['hasMany'](db[_0x309545('0x11a')],{'as':'Configurations','onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x117')}),db[_0x309545('0x11a')][_0x309545('0xee')](db[_0x309545('0x16a')],{'as':_0x309545('0xc4'),'onDelete':'cascade','foreignKey':'SubjectId'}),db[_0x309545('0x11a')][_0x309545('0xee')](db[_0x309545('0x16a')],{'as':_0x309545('0x116'),'onDelete':'cascade','foreignKey':_0x309545('0x18b')}),db[_0x309545('0x11a')][_0x309545('0xee')](db[_0x309545('0x16a')],{'as':_0x309545('0xbb'),'onDelete':'cascade','foreignKey':_0x309545('0x63')}),db[_0x309545('0x11a')][_0x309545('0x174')](db[_0x309545('0x106')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x117')}),db[_0x309545('0x16a')][_0x309545('0xee')](db[_0x309545('0x16a')],{'as':'Subject','foreignKey':_0x309545('0xc9')}),db[_0x309545('0x16a')][_0x309545('0xee')](db[_0x309545('0x16a')],{'as':'Description','foreignKey':_0x309545('0x18b')}),db[_0x309545('0x16a')][_0x309545('0xee')](db[_0x309545('0x16a')],{'as':'Field','foreignKey':'FieldId'}),db[_0x309545('0x16a')][_0x309545('0x174')](db[_0x309545('0x122')],{'as':'Variable','foreignKey':_0x309545('0x167')}),db[_0x309545('0x87')][_0x309545('0xee')](db[_0x309545('0x14c')],{'as':_0x309545('0xfc'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x117')}),db[_0x309545('0x14c')][_0x309545('0xee')](db[_0x309545('0xb8')],{'as':_0x309545('0xc4'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0x14c')][_0x309545('0xee')](db['ZendeskField'],{'as':_0x309545('0x116'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0x14c')][_0x309545('0xee')](db['ZendeskField'],{'as':_0x309545('0xbb'),'foreignKey':_0x309545('0x63')}),db[_0x309545('0x14c')][_0x309545('0x174')](db[_0x309545('0x87')],{'as':'Account','foreignKey':_0x309545('0x117')}),db[_0x309545('0x14c')][_0x309545('0x51')](db[_0x309545('0x92')],{'through':_0x309545('0x1c4')}),db['ZendeskField'][_0x309545('0xee')](db[_0x309545('0xb8')],{'as':_0x309545('0x1e2'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0xb8')]['hasMany'](db[_0x309545('0xb8')],{'as':_0x309545('0xeb'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0xb8')][_0x309545('0xee')](db[_0x309545('0xb8')],{'as':_0x309545('0xf1'),'foreignKey':'FieldId'}),db[_0x309545('0xb8')][_0x309545('0x174')](db['Variable'],{'as':'Variable','foreignKey':_0x309545('0x167')}),db['FreshdeskAccount'][_0x309545('0xee')](db[_0x309545('0x187')],{'as':_0x309545('0xfc'),'onDelete':_0x309545('0x3'),'foreignKey':'AccountId'}),db[_0x309545('0x187')][_0x309545('0xee')](db[_0x309545('0xe9')],{'as':_0x309545('0xc4'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0x187')][_0x309545('0xee')](db[_0x309545('0xe9')],{'as':_0x309545('0x116'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x18b')}),db['FreshdeskConfiguration'][_0x309545('0xee')](db[_0x309545('0xe9')],{'as':_0x309545('0xbb'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x63')}),db[_0x309545('0x187')][_0x309545('0x174')](db[_0x309545('0x28')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x117')}),db['FreshdeskConfiguration']['belongsToMany'](db[_0x309545('0x92')],{'through':'int_freshdesk_configuration_has_tags'}),db[_0x309545('0xe9')][_0x309545('0xee')](db[_0x309545('0xe9')],{'as':_0x309545('0x1e2'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0xe9')]['hasMany'](db[_0x309545('0xe9')],{'as':_0x309545('0xeb'),'foreignKey':_0x309545('0x18b')}),db['FreshdeskField']['hasMany'](db[_0x309545('0xe9')],{'as':_0x309545('0xf1'),'foreignKey':'FieldId'}),db[_0x309545('0xe9')][_0x309545('0x174')](db[_0x309545('0x122')],{'as':_0x309545('0x122'),'foreignKey':_0x309545('0x167')}),db[_0x309545('0xcf')][_0x309545('0xee')](db[_0x309545('0x4e')],{'as':_0x309545('0xfc'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x117')}),db[_0x309545('0x4e')][_0x309545('0xee')](db[_0x309545('0x1d1')],{'as':_0x309545('0xc4'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0x4e')][_0x309545('0xee')](db['VtigerField'],{'as':_0x309545('0x116'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0x4e')][_0x309545('0xee')](db[_0x309545('0x1d1')],{'as':_0x309545('0xbb'),'foreignKey':_0x309545('0x63')}),db['VtigerConfiguration']['belongsTo'](db[_0x309545('0xcf')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x117')}),db[_0x309545('0x1d1')][_0x309545('0xee')](db[_0x309545('0x1d1')],{'as':'Subject','foreignKey':_0x309545('0xc9')}),db[_0x309545('0x1d1')][_0x309545('0xee')](db[_0x309545('0x1d1')],{'as':'Description','foreignKey':'DescriptionId'}),db[_0x309545('0x1d1')][_0x309545('0xee')](db[_0x309545('0x1d1')],{'as':_0x309545('0xf1'),'foreignKey':'FieldId'}),db[_0x309545('0x1d1')]['belongsTo'](db['Variable'],{'as':_0x309545('0x122'),'foreignKey':_0x309545('0x167')}),db[_0x309545('0xe5')]['hasMany'](db[_0x309545('0x1c9')],{'as':_0x309545('0xfc'),'onDelete':'cascade','foreignKey':_0x309545('0x117')}),db['ServicenowConfiguration'][_0x309545('0xee')](db[_0x309545('0x1d3')],{'as':_0x309545('0xc4'),'foreignKey':'SubjectId'}),db[_0x309545('0x1c9')]['hasMany'](db[_0x309545('0x1d3')],{'as':_0x309545('0x116'),'foreignKey':_0x309545('0x18b')}),db['ServicenowConfiguration'][_0x309545('0xee')](db[_0x309545('0x1d3')],{'as':_0x309545('0xbb'),'foreignKey':'FieldId'}),db['ServicenowConfiguration'][_0x309545('0x174')](db[_0x309545('0xe5')],{'as':'Account','foreignKey':_0x309545('0x117')}),db[_0x309545('0x1d3')][_0x309545('0xee')](db['ServicenowField'],{'as':_0x309545('0x1e2'),'foreignKey':_0x309545('0xc9')}),db['ServicenowField'][_0x309545('0xee')](db[_0x309545('0x1d3')],{'as':'Description','foreignKey':'DescriptionId'}),db[_0x309545('0x1d3')][_0x309545('0xee')](db['ServicenowField'],{'as':'Field','foreignKey':_0x309545('0x63')}),db[_0x309545('0x1d3')][_0x309545('0x174')](db[_0x309545('0x122')],{'as':_0x309545('0x122'),'foreignKey':'VariableId'}),db[_0x309545('0x19d')][_0x309545('0xee')](db[_0x309545('0x11b')],{'as':_0x309545('0xfc'),'onDelete':_0x309545('0x3'),'foreignKey':'AccountId'}),db['Dynamics365Configuration'][_0x309545('0xee')](db[_0x309545('0xcc')],{'as':'Subjects','onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0x11b')][_0x309545('0xee')](db[_0x309545('0xcc')],{'as':_0x309545('0x116'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0x11b')]['hasMany'](db[_0x309545('0xcc')],{'as':_0x309545('0xbb'),'onDelete':'cascade','foreignKey':_0x309545('0x63')}),db['Dynamics365Configuration'][_0x309545('0x174')](db[_0x309545('0x19d')],{'as':'Account','foreignKey':_0x309545('0x117')}),db[_0x309545('0xcc')][_0x309545('0xee')](db[_0x309545('0xcc')],{'as':_0x309545('0x1e2'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0xcc')]['hasMany'](db[_0x309545('0xcc')],{'as':_0x309545('0xeb'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0xcc')][_0x309545('0xee')](db[_0x309545('0xcc')],{'as':_0x309545('0xf1'),'foreignKey':_0x309545('0x63')}),db[_0x309545('0xcc')][_0x309545('0x174')](db[_0x309545('0x122')],{'as':_0x309545('0x122'),'foreignKey':'VariableId'}),db['FreshsalesAccount']['hasMany'](db[_0x309545('0x12c')],{'as':_0x309545('0xfc'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x117')}),db[_0x309545('0x12c')][_0x309545('0xee')](db[_0x309545('0x59')],{'as':_0x309545('0xc4'),'foreignKey':'SubjectId'}),db[_0x309545('0x12c')][_0x309545('0xee')](db[_0x309545('0x59')],{'as':_0x309545('0x116'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0x12c')][_0x309545('0xee')](db[_0x309545('0x59')],{'as':'Fields','foreignKey':_0x309545('0x63')}),db[_0x309545('0x12c')][_0x309545('0x174')](db[_0x309545('0x1f')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x117')}),db[_0x309545('0x59')][_0x309545('0xee')](db[_0x309545('0x59')],{'as':_0x309545('0x1e2'),'foreignKey':_0x309545('0xc9')}),db[_0x309545('0x59')][_0x309545('0xee')](db[_0x309545('0x59')],{'as':_0x309545('0xeb'),'foreignKey':_0x309545('0x18b')}),db[_0x309545('0x59')]['hasMany'](db[_0x309545('0x59')],{'as':'Field','foreignKey':_0x309545('0x63')}),db[_0x309545('0x59')][_0x309545('0x174')](db[_0x309545('0x122')],{'as':'Variable','foreignKey':_0x309545('0x167')}),db['ChatQueueReport'][_0x309545('0x174')](db[_0x309545('0x2')],{}),db['ChatQueueReport'][_0x309545('0x174')](db[_0x309545('0x1bb')],{'as':_0x309545('0x71'),'foreignKey':_0x309545('0xda')}),db['ChatQueueReport'][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4')}),db[_0x309545('0x131')]['belongsTo'](db[_0x309545('0xae')],{}),db[_0x309545('0x131')]['belongsTo'](db['ChatMessage'],{}),db[_0x309545('0x131')][_0x309545('0x174')](db[_0x309545('0x94')],{}),db['ChatQueueReport'][_0x309545('0x174')](db[_0x309545('0xa1')],{}),db[_0x309545('0x19a')][_0x309545('0x174')](db[_0x309545('0x94')],{'onDelete':_0x309545('0x3'),'foreignKey':'FromId'}),db[_0x309545('0x19a')]['belongsTo'](db[_0x309545('0x94')],{'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0x19')}),db[_0x309545('0xd5')]['hasMany'](db[_0x309545('0x18d')],{'foreignKey':_0x309545('0x6b'),'onDelete':_0x309545('0x3')}),db['JscriptySessionReport'][_0x309545('0xee')](db[_0x309545('0x12b')],{'foreignKey':_0x309545('0x6b'),'onDelete':_0x309545('0x3')}),db[_0x309545('0xa0')][_0x309545('0x174')](db[_0x309545('0x6a')],{}),db[_0x309545('0xa0')][_0x309545('0x174')](db['CmList'],{'as':_0x309545('0x71'),'foreignKey':'ListId'}),db[_0x309545('0xa0')][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':_0x309545('0x91'),'foreignKey':'ContactId'}),db['SmsQueueReport'][_0x309545('0x174')](db[_0x309545('0xfd')],{}),db[_0x309545('0xa0')][_0x309545('0x174')](db[_0x309545('0x10f')],{}),db[_0x309545('0xa0')][_0x309545('0x174')](db[_0x309545('0x94')],{}),db[_0x309545('0xa0')][_0x309545('0x174')](db[_0x309545('0x3e')],{}),db[_0x309545('0x148')][_0x309545('0xee')](db[_0x309545('0xd5')],{'foreignKey':'ProjectId'}),db['JscriptyProject'][_0x309545('0xee')](db[_0x309545('0x18d')],{'foreignKey':_0x309545('0x130')}),db[_0x309545('0x148')][_0x309545('0xee')](db['JscriptyAnswerReport'],{'foreignKey':'ProjectId'}),db[_0x309545('0x2c')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x6f'),'through':_0x309545('0x65')}),db['Team'][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':_0x309545('0x13a')}),db['Team'][_0x309545('0x51')](db[_0x309545('0xf8')],{'through':_0x309545('0x48'),'as':_0x309545('0x3b')}),db[_0x309545('0x8e')]['belongsToMany'](db[_0x309545('0xff')],{'through':_0x309545('0xf5'),'as':_0x309545('0x58')}),db['Team'][_0x309545('0x51')](db[_0x309545('0xa1')],{'through':'team_has_chat_queues','as':_0x309545('0x85')}),db[_0x309545('0x8e')]['belongsToMany'](db[_0x309545('0x72')],{'through':'team_has_fax_queues','as':'FaxQueues'}),db[_0x309545('0x8e')][_0x309545('0x51')](db[_0x309545('0x3e')],{'through':_0x309545('0x57'),'as':_0x309545('0xcd')}),db[_0x309545('0x8e')]['belongsToMany'](db['OpenchannelQueue'],{'through':_0x309545('0x123'),'as':_0x309545('0x1e5')}),db[_0x309545('0x8e')][_0x309545('0x51')](db['WhatsappQueue'],{'through':_0x309545('0xce'),'as':_0x309545('0xf3')}),db[_0x309545('0x6d')][_0x309545('0xee')](db['CmHopper'],{'as':_0x309545('0xa'),'foreignKey':'CampaignId'}),db[_0x309545('0x6d')][_0x309545('0xee')](db[_0x309545('0x95')],{'as':_0x309545('0xbf'),'foreignKey':_0x309545('0xd2')}),db[_0x309545('0x6d')][_0x309545('0xee')](db['CmHopperHistory'],{'as':_0x309545('0x61'),'foreignKey':'CampaignId'}),db[_0x309545('0x6d')][_0x309545('0xee')](db[_0x309545('0x69')],{'as':'HopperBlacks','foreignKey':_0x309545('0xd2')}),db[_0x309545('0x6d')][_0x309545('0x174')](db[_0x309545('0x1ac')],{'as':_0x309545('0x1ac'),'foreignKey':_0x309545('0xa6')}),db[_0x309545('0x6d')]['belongsTo'](db[_0x309545('0x1ac')],{'as':'TrunkBackup','foreignKey':'TrunkBackupId'}),db[_0x309545('0x6d')][_0x309545('0x174')](db[_0x309545('0x120')],{'as':'Interval','foreignKey':_0x309545('0x105')}),db[_0x309545('0x6d')]['belongsTo'](db['SquareProject'],{'as':_0x309545('0x2c'),'foreignKey':_0x309545('0xbc')}),db['Campaign']['belongsToMany'](db['CmList'],{'as':_0x309545('0x8d'),'through':_0x309545('0x1d5')}),db['Campaign'][_0x309545('0x51')](db[_0x309545('0x1bb')],{'as':_0x309545('0x1ec'),'through':_0x309545('0xaa')}),db[_0x309545('0x5b')][_0x309545('0x174')](db[_0x309545('0x166')],{}),db[_0x309545('0x5b')]['belongsTo'](db[_0x309545('0x18e')],{}),db[_0x309545('0x5b')][_0x309545('0x174')](db[_0x309545('0x1e8')],{'foreignKey':_0x309545('0xba'),'as':'FromAccount'}),db[_0x309545('0x5b')][_0x309545('0x174')](db['User'],{'foreignKey':_0x309545('0x1e9'),'as':_0x309545('0x13b')}),db[_0x309545('0x5b')]['belongsTo'](db['User'],{'foreignKey':_0x309545('0x1e4'),'as':_0x309545('0x1ea')}),db[_0x309545('0x5b')]['belongsTo'](db['MailQueue'],{'foreignKey':_0x309545('0xf0'),'as':'ToQueue'}),db[_0x309545('0x5b')]['belongsTo'](db[_0x309545('0x1e8')],{'foreignKey':'ToMailAccountId','as':'ToAccount'}),db[_0x309545('0xe3')][_0x309545('0x174')](db['ChatMessage'],{}),db[_0x309545('0xe3')][_0x309545('0x174')](db[_0x309545('0xae')],{}),db[_0x309545('0xe3')][_0x309545('0x174')](db[_0x309545('0x2')],{'foreignKey':_0x309545('0x108'),'as':_0x309545('0x1a5')}),db[_0x309545('0xe3')][_0x309545('0x174')](db[_0x309545('0x94')],{'foreignKey':'FromUserId','as':_0x309545('0x13b')}),db['ChatTransferReport'][_0x309545('0x174')](db['User'],{'foreignKey':_0x309545('0x1e4'),'as':_0x309545('0x1ea')}),db[_0x309545('0xe3')]['belongsTo'](db[_0x309545('0xa1')],{'foreignKey':_0x309545('0xaf'),'as':_0x309545('0x183')}),db[_0x309545('0xe3')][_0x309545('0x174')](db[_0x309545('0x2')],{'foreignKey':_0x309545('0x102'),'as':_0x309545('0x7a')}),db[_0x309545('0xfb')][_0x309545('0x174')](db[_0x309545('0x162')],{}),db['FaxTransferReport'][_0x309545('0x174')](db[_0x309545('0x1be')],{}),db[_0x309545('0xfb')][_0x309545('0x174')](db[_0x309545('0x1ee')],{'foreignKey':'FromFaxAccountId','as':_0x309545('0x1a5')}),db[_0x309545('0xfb')][_0x309545('0x174')](db[_0x309545('0x94')],{'foreignKey':_0x309545('0x1e9'),'as':_0x309545('0x13b')}),db[_0x309545('0xfb')]['belongsTo'](db[_0x309545('0x94')],{'foreignKey':_0x309545('0x1e4'),'as':_0x309545('0x1ea')}),db[_0x309545('0xfb')][_0x309545('0x174')](db['FaxQueue'],{'foreignKey':'ToFaxQueueId','as':_0x309545('0x183')}),db[_0x309545('0xfb')][_0x309545('0x174')](db[_0x309545('0x1ee')],{'foreignKey':'ToFaxAccountId','as':'ToAccount'}),db['OpenchannelTransferReport'][_0x309545('0x174')](db[_0x309545('0x1e3')],{}),db[_0x309545('0x139')]['belongsTo'](db[_0x309545('0x156')],{}),db[_0x309545('0x139')][_0x309545('0x174')](db[_0x309545('0x5f')],{'foreignKey':_0x309545('0x115'),'as':'FromAccount'}),db[_0x309545('0x139')]['belongsTo'](db['User'],{'foreignKey':_0x309545('0x1e9'),'as':_0x309545('0x13b')}),db[_0x309545('0x139')][_0x309545('0x174')](db[_0x309545('0x94')],{'foreignKey':_0x309545('0x1e4'),'as':_0x309545('0x1ea')}),db[_0x309545('0x139')][_0x309545('0x174')](db[_0x309545('0x17e')],{'foreignKey':_0x309545('0x76'),'as':_0x309545('0x183')}),db[_0x309545('0x139')][_0x309545('0x174')](db[_0x309545('0x5f')],{'foreignKey':_0x309545('0xc0'),'as':_0x309545('0x7a')}),db[_0x309545('0x40')]['belongsTo'](db[_0x309545('0x10f')],{}),db['SmsTransferReport']['belongsTo'](db[_0x309545('0xfd')],{}),db[_0x309545('0x40')][_0x309545('0x174')](db[_0x309545('0x6a')],{'foreignKey':_0x309545('0x103'),'as':_0x309545('0x1a5')}),db[_0x309545('0x40')][_0x309545('0x174')](db[_0x309545('0x94')],{'foreignKey':_0x309545('0x1e9'),'as':'FromAgent'}),db['SmsTransferReport'][_0x309545('0x174')](db[_0x309545('0x94')],{'foreignKey':_0x309545('0x1e4'),'as':'ToAgent'}),db['SmsTransferReport'][_0x309545('0x174')](db['SmsQueue'],{'foreignKey':_0x309545('0x1dc'),'as':_0x309545('0x183')}),db[_0x309545('0x40')][_0x309545('0x174')](db[_0x309545('0x6a')],{'foreignKey':_0x309545('0x1ca'),'as':_0x309545('0x7a')}),db[_0x309545('0x1bb')][_0x309545('0xee')](db['Disposition'],{'as':_0x309545('0x172'),'foreignKey':'ListId'}),db[_0x309545('0x1bb')][_0x309545('0xee')](db[_0x309545('0x1d7')],{'as':_0x309545('0x11'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0x1bb')][_0x309545('0xee')](db[_0x309545('0x7e')],{'as':_0x309545('0x14e'),'onDelete':_0x309545('0x3'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0x1bb')][_0x309545('0xee')](db[_0x309545('0x95')],{'as':_0x309545('0xbf'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0x1bb')][_0x309545('0xee')](db['CmHopperHistory'],{'as':_0x309545('0x1c5'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0x1bb')][_0x309545('0xee')](db[_0x309545('0xc8')],{'as':'ReportAgentPreview','foreignKey':_0x309545('0xda')}),db[_0x309545('0x1bb')][_0x309545('0x51')](db[_0x309545('0xf8')],{'as':'Queues','through':_0x309545('0x99')}),db['CmList'][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':'cm_user_has_lists'}),db[_0x309545('0x152')]['hasMany'](db[_0x309545('0x30')],{'as':_0x309545('0x10c'),'onDelete':_0x309545('0x3')}),db[_0x309545('0x152')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':_0x309545('0x1a')}),db['UserProfile'][_0x309545('0xee')](db[_0x309545('0x94')],{'as':_0x309545('0x6f'),'foreignKey':'userProfileId','onDelete':_0x309545('0x153')}),db[_0x309545('0x47')]['hasMany'](db['UserProfileSection'],{'as':_0x309545('0x9b'),'foreignKey':_0x309545('0x1e6'),'onDelete':'cascade'}),db[_0x309545('0x175')][_0x309545('0xee')](db['UserProfileResource'],{'as':'Resources','foreignKey':_0x309545('0xd7'),'onDelete':_0x309545('0x3')}),db[_0x309545('0x4d')][_0x309545('0xee')](db[_0x309545('0x13c')],{'as':_0x309545('0x172'),'foreignKey':'WhatsappAccountId'}),db[_0x309545('0x4d')]['hasMany'](db[_0x309545('0x75')],{'as':_0x309545('0x107'),'foreignKey':_0x309545('0x6')}),db['WhatsappAccount'][_0x309545('0xee')](db['WhatsappMessage'],{'as':_0x309545('0x1db'),'foreignKey':_0x309545('0x6')}),db['WhatsappAccount']['hasMany'](db[_0x309545('0x164')],{'as':'Interactions'}),db[_0x309545('0x4d')][_0x309545('0xee')](db[_0x309545('0x70')],{'as':_0x309545('0xc7')}),db[_0x309545('0x4d')][_0x309545('0x174')](db[_0x309545('0x1bb')],{'as':_0x309545('0x71'),'foreignKey':_0x309545('0xda')}),db[_0x309545('0x4d')][_0x309545('0x174')](db['Pause'],{'as':_0x309545('0x16f'),'foreignKey':_0x309545('0x53')}),db[_0x309545('0x4d')][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':_0x309545('0x155')}),db['WhatsappApplication'][_0x309545('0x174')](db[_0x309545('0x94')],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x70')]['belongsTo'](db[_0x309545('0x55')],{'onDelete':_0x309545('0x153')}),db[_0x309545('0x70')][_0x309545('0x174')](db[_0x309545('0x4d')],{'onDelete':_0x309545('0x153')}),db['WhatsappApplication']['belongsTo'](db['Interval'],{'onDelete':_0x309545('0x153'),'foreignKey':_0x309545('0x105')}),db[_0x309545('0x70')][_0x309545('0x174')](db['Tag'],{'onDelete':_0x309545('0x153'),'foreignKey':_0x309545('0x100')}),db[_0x309545('0x164')][_0x309545('0xee')](db['WhatsappMessage'],{'as':_0x309545('0x1db'),'onDelete':'cascade','foreignKey':_0x309545('0x110')}),db[_0x309545('0x164')][_0x309545('0x174')](db[_0x309545('0x4d')],{'as':_0x309545('0x16c'),'foreignKey':_0x309545('0x6')}),db['WhatsappInteraction'][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':_0x309545('0x91'),'foreignKey':_0x309545('0x1b4')}),db[_0x309545('0x164')][_0x309545('0x174')](db[_0x309545('0x94')],{'as':_0x309545('0x1c'),'foreignKey':_0x309545('0x112')}),db[_0x309545('0x164')][_0x309545('0x51')](db[_0x309545('0x92')],{'through':_0x309545('0xd'),'as':_0x309545('0x2b')}),db[_0x309545('0x164')][_0x309545('0x51')](db[_0x309545('0x92')],{'through':_0x309545('0xd'),'as':_0x309545('0x1cb')}),db[_0x309545('0x164')][_0x309545('0x51')](db['User'],{'as':_0x309545('0x6f'),'through':_0x309545('0x1c2'),'foreignKey':'WhatsappInteractionId'}),db['WhatsappMessage'][_0x309545('0x174')](db['User'],{'as':_0x309545('0x94')}),db[_0x309545('0x142')][_0x309545('0x174')](db[_0x309545('0x7e')],{'onDelete':'cascade','as':'Contact'}),db[_0x309545('0x142')][_0x309545('0x174')](db[_0x309545('0x164')],{'onDelete':_0x309545('0x3'),'as':'Interaction','foreignKey':_0x309545('0x110')}),db[_0x309545('0x142')]['belongsTo'](db[_0x309545('0x4d')],{'as':'Account','foreignKey':_0x309545('0x6')}),db['WhatsappQueueReport']['belongsTo'](db[_0x309545('0x4d')],{}),db[_0x309545('0x1')][_0x309545('0x174')](db['CmList'],{'as':'List','foreignKey':_0x309545('0xda')}),db[_0x309545('0x1')][_0x309545('0x174')](db[_0x309545('0x7e')],{'as':'Contact','foreignKey':_0x309545('0x1b4')}),db['WhatsappQueueReport'][_0x309545('0x174')](db['WhatsappInteraction'],{}),db[_0x309545('0x1')][_0x309545('0x174')](db[_0x309545('0x55')],{}),db[_0x309545('0x1')]['belongsTo'](db[_0x309545('0x142')],{}),db[_0x309545('0x1')][_0x309545('0x174')](db['User'],{}),db[_0x309545('0x159')][_0x309545('0x174')](db['WhatsappMessage'],{}),db[_0x309545('0x159')][_0x309545('0x174')](db['WhatsappInteraction'],{}),db[_0x309545('0x159')]['belongsTo'](db['WhatsappAccount'],{'foreignKey':_0x309545('0x161'),'as':'FromAccount'}),db['WhatsappTransferReport']['belongsTo'](db[_0x309545('0x4d')],{'foreignKey':_0x309545('0x3f'),'as':_0x309545('0x7a')}),db[_0x309545('0x159')][_0x309545('0x174')](db[_0x309545('0x55')],{'foreignKey':_0x309545('0x17c'),'as':_0x309545('0x183')}),db[_0x309545('0x159')][_0x309545('0x174')](db[_0x309545('0x94')],{'foreignKey':_0x309545('0x1e9'),'as':'FromAgent'}),db[_0x309545('0x159')][_0x309545('0x174')](db[_0x309545('0x94')],{'foreignKey':'ToUserId','as':_0x309545('0x1ea')}),db['WhatsappQueue'][_0x309545('0x51')](db[_0x309545('0x94')],{'as':_0x309545('0x137'),'through':'UserWhatsappQueue','foreignKey':_0x309545('0xe6')}),db[_0x309545('0x55')][_0x309545('0x51')](db[_0x309545('0x8e')],{'through':'team_has_whatsapp_queues','as':'Teams'}),module[_0x309545('0x33')]={'db':db,'dbH':dbH}; \ No newline at end of file +const a1022_0x58da=['OpenchannelMessage','Attachments','OpenchannelTransferReport','../api/intFreshsalesField/intFreshsalesField.model','Dynamics365Account','DeskField','FromId','../api/trigger/trigger.model','campaigns_has_cm_blacklists','../api/intDeskField/intDeskField.model','UserWhatsappQueue','SquareProject','user_has_fax_interactions','team_has_chat_queues','Notification','AnalyticExtractedReport','Imap','../api/openchannelInteraction/openchannelInteraction.model','SmsTransferReport','Queues','MailSubstatus','OpenchannelApplication','FaxQueues','user_has_voice_prefixes','AttachmentId','mysqlUser','user_has_teams','UserFaxQueue','../config/config.service','VoiceQueuesLog','FaxMessage','uniqueid','openchannel_interaction_has_tags','team_has_voice_queues','Tag','TagId','QueueCalls','UserMailQueue','DeskConfiguration','../api/team/team.model','../api/intFreshdeskConfiguration/intFreshdeskConfiguration.model','CannedAnswer','../api/intSugarcrmField/intSugarcrmField.model','MailQueue','SpiedAgents','user_has_sms_interactions','ChatQueue','password','SugarcrmField','HopperFinals','Applications','ToFaxQueueId','Interval','user_has_whatsapp_interactions','WhatsappQueues','MailAccount','FromChatWebsiteId','name','ChatGroupId','Interaction','VoiceMailMessage','mandatoryDispositionPause','../api/variable/variable.model','belongsToMany','Users','Schedule','MailAccountId','../api/cloudProvider/cloudProvider.model','../api/cmList/cmList.model','FreshsalesConfiguration','../api/chatTransferReport/chatTransferReport.model','TemplateId','FaxQueue','../api/mailQueueReport/mailQueueReport.model','FaxInteractionId','SmsMessage','Agents','OpenchannelInteractions','../api/voiceDialReport/voiceDialReport.model','../api/intZohoField/intZohoField.model','OneAll','DefaultReportId','WhatsappAccountId','mail_interaction_has_tags','Attachment','../api/disposition/disposition.model','team_has_mail_queues','ToQueueId','whatsapp_interaction_has_tags','FreshsalesField','ContactId','ChatMessage','AutomationId','../api/network/network.model','SquareProjectId','../api/intFreshdeskAccount/intFreshdeskAccount.model','List','UserWhatsappInteractions','CmHopperBlack','CmList','AutomationAllId','../api/cmCompany/cmCompany.model','userProfileId','../api/cmContact/cmContact.model','../api/userChatQueue/userChatQueue.model','../api/cmHopperHistory/cmHopperHistory.model','../api/smsTransferReport/smsTransferReport.model','../api/userWhatsappQueue/userWhatsappQueue.model','../api/openchannelQueueReport/openchannelQueueReport.model','VtigerAccount','MailMessage','Description','WhatsappInteraction','FreshdeskAccount','Any','FromAgent','UserChatQueue','Items','ZendeskConfiguration','../api/smsInteraction/smsInteraction.model','Variable','int_zendesk_configuration_has_tags','../api/chatInteraction/chatInteraction.model','../api/attachment/attachment.model','../api/userVoiceQueue/userVoiceQueue.model','DescriptionId','ChatTransferReport','../api/mailServerIn/mailServerIn.model','../api/integrationReport/integrationReport.model','../api/whatsappQueue/whatsappQueue.model','ReportAgentPreview','ChatInternalMessage','../api/analyticCustomReport/analyticCustomReport.model','Mohs','../api/cmHopper/cmHopper.model','../api/intVtigerField/intVtigerField.model','Action','../api/intDynamics365Account/intDynamics365Account.model','SmsAccount','Account','VoiceDialReport','ChatInteraction','team_has_sms_queues','mysqlPassword','SmsAccounts','OpenchannelInteraction','VoiceQueueReport','VoiceCallReport','Teams','Contact','../api/chatMessage/chatMessage.model','../api/voiceQueueReport/voiceQueueReport.model','voice_queues_has_cm_lists','options','User','VoiceQueuesRt','fax_interaction_has_tags','FromFaxAccountId','FaxApplication','voice_queues_has_cm_blacklists','Owner','../api/voicePrefix/voicePrefix.model','../api/faxApplication/faxApplication.model','WhatsappInteractions','../api/cannedAnswer/cannedAnswer.model','VoiceQueue','FromMailAccountId','SquareReport','Campaign','dbHost','ToChatWebsiteId','ParentId','AnalyticDefaultReport','Subjects','WhatsappAccounts','../config/environment','TrunkBackup','FaxApplications','../api/openchannelApplication/openchannelApplication.model','CmHopperFinal','../api/license/license.model','sequelize','../api/smsApplication/smsApplication.model','License','UserProfileSections','MailQueues','jstz','ZohoField','belongsTo','HopperHistory','MailAccounts','SugarcrmAccount','IntegrationReport','Sound','../api/voiceMailMessage/voiceMailMessage.model','../api/whatsappMessage/whatsappMessage.model','CustomReportId','../api/intSalesforceAccount/intSalesforceAccount.model','JscriptyProject','utf8','ToUserId','../api/plugin/plugin.model','../api/squareMessage/squareMessage.model','cm_contact_has_tags','../api/cmHopperFinal/cmHopperFinal.model','moh_has_sounds','ToOpenchannelQueueId','Agent','OpenchannelQueueReport','ServicenowField','Queue','ToAccount','SmsInteractions','../api/intServicenowField/intServicenowField.model','../api/automation/automation.model','../api/intZendeskField/intZendeskField.model','mandatoryDispositionPauseId','../api/dashboard/dashboard.model','MailApplication','ListId','FaxInteraction','../api/action/action.model','MailInteractions','SmsAccountId','../api/memberReport/memberReport.model','determine','Contacts','JscriptyAnswerReport','database','sequelizeHistory','SalesforceConfiguration','utf8_general_ci','Dashboard','CompanyId','VtigerField','../api/whatsappApplication/whatsappApplication.model','int_desk_configuration_has_tags','../api/analyticDefaultReport/analyticDefaultReport.model','OpenchannelAccount','VoiceMusicOnHold','VoicePrefixes','db-query','restrict','ChatGroup','../api/reportAgentPreview/reportAgentPreview.model','../api/intServicenowConfiguration/intServicenowConfiguration.model','Answers','MailQueueReport','VoiceQueueId','Cdr','user_has_fax_accounts','../api/pause/pause.model','OwnerId','../api/openchannelQueue/openchannelQueue.model','VoiceExtension','WhatsappTransferReport','../api/voiceAgentReport/voiceAgentReport.model','WhatsappAccount','../api/userProfile/userProfile.model','ChatOfflineMessage','IntervalId','team_has_fax_queues','../api/faxMessage/faxMessage.model','Disposition','CloudProvider','CmHopperHistory','ServicenowConfiguration','user_has_whatsapp_accounts','SalesforceField','UserProfileResource','cascade','../api/faxInteraction/faxInteraction.model','SmsApplication','JscriptySessions','AnalyticTreeReport','SubjectId','user_has_openchannel_interactions','ToOpenchannelAccountId','DashboardItem','ToFaxAccountId','ChatQueueReport','AnalyticFieldReport','VoicePrefix','OneAny','../api/setting/setting.model','Network','../api/mailMessage/mailMessage.model','FaxInteractions','OpenchannelAccounts','FreshdeskConfiguration','../api/intDeskConfiguration/intDeskConfiguration.model','SugarcrmConfiguration','UserProfileSection','UserFaxInteractions','MailServerOut','Pause','ChatInteractionId','../api/openchannelMessage/openchannelMessage.model','../api/userProfileSection/userProfileSection.model','../api/integration/integration.model','TrunkId','../api/screenRecording/screenRecording.model','../api/whatsappInteraction/whatsappInteraction.model','UserProfile','VtigerConfiguration','../api/trunk/trunk.model','Hoppers','WhatsappQueue','sms_interaction_has_tags','../api/faxTransferReport/faxTransferReport.model','../api/intFreshdeskField/intFreshdeskField.model','../api/mailSubstatus/mailSubstatus.model','Extensions','FaxAccount','UserSmsInteractions','FromUserId','SmsApplications','../api/chatWebsite/chatWebsite.model','../api/voiceChanSpy/voiceChanSpy.model','CmHopper','ChatProactiveAction','hasOne','sectionId','mailboxuser','../api/mailAccount/mailAccount.model','ZendeskAccount','ToChatQueueId','../api/cdr/cdr.model','Intervals','VoiceQueues','Website','UserOpenchannelQueue','FromAccount','UserId','../api/jscriptySessionReport/jscriptySessionReport.model','TrunkBackupId','FromOpenchannelAccountId','../api/faxQueue/faxQueue.model','SmsQueue','ZohoConfiguration','FromSmsAccountId','CmCompany','AgentReports','Descriptions','../api/squareRecording/squareRecording.model','../api/analyticExtractedReport/analyticExtractedReport.model','Condition','user_has_sms_accounts','JscriptySessionReport','MailInteractionId','TriggerId','user_has_chat_websites','Setting','../api/squareOdbc/squareOdbc.model','ProjectId','BlackLists','SmsQueueReport','MailServerIn','MailApplications','SquareOdbc','../api/smsMessage/smsMessage.model','DataTypes','mysqlDatabase','SmsInteraction','../api/intServicenowAccount/intServicenowAccount.model','Company','cm_user_has_contacts','Messages','MetricId','UserChatInteractions','ZendeskField','FieldId','../api/userProfileResource/userProfileResource.model','WhatsappApplication','ToMailAccountId','HopperHistories','AccountId','UserSmsQueue','../api/intDynamics365Configuration/intDynamics365Configuration.model','../api/intDeskAccount/intDeskAccount.model','Recordings','cm_user_has_lists','Team','user_has_square_projects','../api/intSalesforceField/intSalesforceField.model','Fields','user_has_chat_interactions','../api/jscriptyProject/jscriptyProject.model','../api/voiceContext/voiceContext.model','SquareProjects','WhatsappQueueReport','Dynamics365Configuration','SalesforceAccount','Interactions','VoiceContext','FaxQueueReport','FaxTransferReport','MailTransferReport','ToMailQueueId','username','Dynamics365Field','Members','DeskAccount','../api/chatQueueReport/chatQueueReport.model','defaultsDeep','user_has_openchannel_accounts','../api/userMailQueue/userMailQueue.model','Subject','AnalyticCustomReport','ServicenowAccount','Configurations','OpenchannelAccountId','VariableId','UserOpenchannelInteractions','OpenchannelQueues','FaxAccounts','../api/intZendeskConfiguration/intZendeskConfiguration.model','FreshdeskField','exports','ToQueue','FreshsalesAccount','WhatsappMessage','SmsQueues','ChatInteractions','team_has_whatsapp_queues','../api/voiceMail/voiceMail.model','Trunk','CampaignId','SquareDetailsReport','Integration','campaigns_has_cm_lists','Trigger','AnyCondition','../api/intSalesforceConfiguration/intSalesforceConfiguration.model','chat_group_has_users','lodash','SquareMessage','Field','hasMany','VoiceRecording','team_has_openchannel_queues','ScreenRecording','../api/chatQueue/chatQueue.model','Automation','Tags','AnalyticMetric','VoiceAgentReport','SmsInteractionId','FromWhatsappAccountId','../api/mailInteraction/mailInteraction.model','../api/squareProject/squareProject.model','../api/whatsappQueueReport/whatsappQueueReport.model','ChatApplication','ChatWebsiteId','Notifications','SquareRecording','WhatsappInteractionId','../api/openchannelAccount/openchannelAccount.model','ToSmsAccountId','../api/voiceExtension/voiceExtension.model','Template','OpenchannelQueue','../api/whatsappTransferReport/whatsappTransferReport.model','../api/mailQueue/mailQueue.model','VoiceChanSpy','CmCustomField','UserVoiceQueueRt','Resources','VoiceMail','../api/analyticFieldReport/analyticFieldReport.model','Smtp','../api/template/template.model','TriggerAllId','chat_interaction_has_tags','user_has_mail_interactions','../api/dashboardItem/dashboardItem.model','Dispositions','ChatWebsite','OpenchannelInteractionId','CmContact','../api/analyticTreeReport/analyticTreeReport.model','ToWhatsappAccountId','../api/faxQueueReport/faxQueueReport.model','FaxAccountId','user_has_mail_accounts','ThroughTags','UserVoiceQueue','ToAgent','ToId','mailbox','SessionId','../api/intSugarcrmAccount/intSugarcrmAccount.model','MailInteraction','JscriptyQuestionReport','Lists','CustomFields','../api/intZohoAccount/intZohoAccount.model','../api/smsQueueReport/smsQueueReport.model'];(function(_0x245e86,_0x58da95){const _0x30c5d6=function(_0x2002ba){while(--_0x2002ba){_0x245e86['push'](_0x245e86['shift']());}};_0x30c5d6(++_0x58da95);}(a1022_0x58da,0x19a));const a1022_0x30c5=function(_0x245e86,_0x58da95){_0x245e86=_0x245e86-0x0;let _0x30c5d6=a1022_0x58da[_0x245e86];return _0x30c5d6;};const _0x41cf05=a1022_0x30c5;'use strict';const config=require(_0x41cf05('0x107')),cs=require(_0x41cf05('0x74'))['getConfigService'](),Sequelize=require(_0x41cf05('0x10d')),logger=require('../config/logger'),_=require(_0x41cf05('0x19')),jstz=require(_0x41cf05('0x112')),timezone=jstz[_0x41cf05('0x139')](),queryLogger=logger(_0x41cf05('0x149')),DEFAULTS={'database':cs[_0x41cf05('0x1c2')],'username':cs[_0x41cf05('0x71')],'password':cs[_0x41cf05('0xe7')],'options':{'host':cs[_0x41cf05('0x101')],'port':cs['dbPort'],'dialect':'mysql','dialectOptions':{'charset':'utf8mb4'},'logging':cs['isProduction']?![]:_0x2002ba=>queryLogger['info'](_0x2002ba),'timezone':timezone[_0x41cf05('0x91')](),'define':{'charset':_0x41cf05('0x11f'),'collate':_0x41cf05('0x13f')}}};config[_0x41cf05('0x10d')]=_[_0x41cf05('0x1ec')](config[_0x41cf05('0x10d')],DEFAULTS),config['sequelizeHistory']=_[_0x41cf05('0x1ec')](config[_0x41cf05('0x13d')],DEFAULTS);const db={'Sequelize':Sequelize,'sequelize':new Sequelize(config[_0x41cf05('0x10d')][_0x41cf05('0x13c')],config[_0x41cf05('0x10d')][_0x41cf05('0x1e7')],config[_0x41cf05('0x10d')]['password'],config[_0x41cf05('0x10d')][_0x41cf05('0xf1')])},dbH={'Sequelize':Sequelize,'sequelize':new Sequelize(config[_0x41cf05('0x13d')]['database'],config['sequelizeHistory']['username'],config[_0x41cf05('0x13d')][_0x41cf05('0x87')],config[_0x41cf05('0x13d')][_0x41cf05('0xf1')])};db[_0x41cf05('0xf2')]=require('../api/user/user.model')(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0x36')]=require(_0x41cf05('0x196'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1e2')]=require(_0x41cf05('0x1dc'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db['VoiceExtension']=require(_0x41cf05('0x31'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x147')]=require('../api/voiceMusicOnHold/voiceMusicOnHold.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xfd')]=require('../api/voiceQueue/voiceQueue.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['VoiceRecording']=require('../api/voiceRecording/voiceRecording.model')(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x1f')]=require(_0x41cf05('0x185'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x3a')]=require(_0x41cf05('0xf'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db['VoiceMailMessage']=require(_0x41cf05('0x11a'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xeb')]=require('../api/voiceCallReport/voiceCallReport.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xe4')]=require(_0x41cf05('0xa6'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x24')]=require(_0x41cf05('0x158'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xea')]=require(_0x41cf05('0xef'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['MemberReport']=require(_0x41cf05('0x138'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['Trunk']=require(_0x41cf05('0x189'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['VoiceTransferReport']=require('../api/voiceTransferReport/voiceTransferReport.model')(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x38')]=require('../api/userVoiceQueueRt/userVoiceQueueRt.model')(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x4c')]=require(_0x41cf05('0xd4'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0xcc')]=require(_0x41cf05('0xc0'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db['UserMailQueue']=require(_0x41cf05('0x1ee'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db['UserFaxQueue']=require('../api/userFaxQueue/userFaxQueue.model')(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1d1')]=require('../api/userSmsQueue/userSmsQueue.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1a3')]=require('../api/userOpenchannelQueue/userOpenchannelQueue.model')(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x62')]=require(_0x41cf05('0xc3'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1bd')]=require(_0x41cf05('0xd7'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x17e')]=require('../api/mailServerOut/mailServerOut.model')(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db['MailAccount']=require(_0x41cf05('0x19c'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x83')]=require(_0x41cf05('0x35'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x6c')]=require(_0x41cf05('0x18f'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x52')]=require(_0x41cf05('0x27'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xc6')]=require(_0x41cf05('0x176'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x132')]=require('../api/mailApplication/mailApplication.model')(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x14f')]=require(_0x41cf05('0xa1'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x140')]=require(_0x41cf05('0x131'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x16e')]=require(_0x41cf05('0x41'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x191')]=require('../api/faxAccount/faxAccount.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xf6')]=require(_0x41cf05('0xfa'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['FaxInteraction']=require(_0x41cf05('0x167'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x76')]=require(_0x41cf05('0x15e'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xa0')]=require(_0x41cf05('0x1a9'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x1e3')]=require(_0x41cf05('0x48'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xe2')]=require('../api/smsAccount/smsAccount.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['SmsApplication']=require(_0x41cf05('0x10e'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1c3')]=require(_0x41cf05('0xcf'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0xa3')]=require(_0x41cf05('0x1c0'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1aa')]=require('../api/smsQueue/smsQueue.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['OpenchannelAccount']=require(_0x41cf05('0x2f'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x6d')]=require(_0x41cf05('0x10a'))(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0xe9')]=require(_0x41cf05('0x69'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x58')]=require(_0x41cf05('0x181'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x33')]=require(_0x41cf05('0x155'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x43')]=require(_0x41cf05('0x195'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x128')]=require(_0x41cf05('0xc4'))(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0x2a')]=require('../api/chatApplication/chatApplication.model')(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0xe5')]=require(_0x41cf05('0xd2'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xb3')]=require(_0x41cf05('0xee'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x15b')]=require('../api/chatOfflineMessage/chatOfflineMessage.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x86')]=require(_0x41cf05('0x20'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x14b')]=require('../api/chatGroup/chatGroup.model')(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db['ChatProactiveAction']=require('../api/chatProactiveAction/chatProactiveAction.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1ad')]=require(_0x41cf05('0xbd'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x45')]=require(_0x41cf05('0xbf'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['CmHopper']=require(_0x41cf05('0xde'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xba')]=require('../api/cmHopperBlack/cmHopperBlack.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x10b')]=require(_0x41cf05('0x124'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x161')]=require(_0x41cf05('0xc1'))(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0xda')]=require(_0x41cf05('0x14c'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x37')]=require('../api/cmCustomField/cmCustomField.model')(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xe0')]=require(_0x41cf05('0x135'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x21')]=require(_0x41cf05('0x12e'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x81')]=require(_0x41cf05('0xfc'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['Disposition']=require(_0x41cf05('0xad'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1b2')]=require('../api/condition/condition.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['Interval']=require('../api/interval/interval.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x17f')]=require(_0x41cf05('0x153'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x151')]=require(_0x41cf05('0x19f'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x75')]=require('../api/voiceQueuesLog/voiceQueuesLog.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x99')]=require('../api/schedule/schedule.model')(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x119')]=require('../api/sound/sound.model')(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db['Tag']=require('../api/tag/tag.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x32')]=require(_0x41cf05('0x3d'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x15')]=require(_0x41cf05('0x5f'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xd0')]=require(_0x41cf05('0x96'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x13')]=require(_0x41cf05('0x183'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x118')]=require(_0x41cf05('0xd8'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['AnalyticCustomReport']=require(_0x41cf05('0xdc'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x104')]=require(_0x41cf05('0x145'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x67')]=require(_0x41cf05('0x1b1'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['AnalyticMetric']=require('../api/analyticMetric/analyticMetric.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['AnalyticFieldReport']=require(_0x41cf05('0x3b'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x16a')]=require(_0x41cf05('0x46'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1e0')]=require(_0x41cf05('0x11d'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x13e')]=require(_0x41cf05('0x17'))(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0x164')]=require(_0x41cf05('0x1d8'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x117')]=require(_0x41cf05('0x51'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x17b')]=require('../api/intSugarcrmConfiguration/intSugarcrmConfiguration.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x88')]=require(_0x41cf05('0x82'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['DeskAccount']=require(_0x41cf05('0x1d3'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db['DeskConfiguration']=require(_0x41cf05('0x17a'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x5d')]=require(_0x41cf05('0x61'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['ZohoAccount']=require(_0x41cf05('0x56'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['ZohoConfiguration']=require('../api/intZohoConfiguration/intZohoConfiguration.model')(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x113')]=require(_0x41cf05('0xa7'))(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0x19d')]=require('../api/intZendeskAccount/intZendeskAccount.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['ZendeskConfiguration']=require(_0x41cf05('0x6'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['ZendeskField']=require(_0x41cf05('0x12f'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['FreshdeskAccount']=require(_0x41cf05('0xb7'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x179')]=require(_0x41cf05('0x80'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x7')]=require(_0x41cf05('0x18e'))(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0xc5')]=require('../api/intVtigerAccount/intVtigerAccount.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x188')]=require('../api/intVtigerConfiguration/intVtigerConfiguration.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x142')]=require(_0x41cf05('0xdf'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1f1')]=require(_0x41cf05('0x1c4'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x162')]=require(_0x41cf05('0x14d'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x129')]=require(_0x41cf05('0x12d'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x5c')]=require(_0x41cf05('0xe1'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['Dynamics365Configuration']=require(_0x41cf05('0x1d2'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x1e8')]=require('../api/intDynamics365Field/intDynamics365Field.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xa')]=require('../api/intFreshsalesAccount/intFreshsalesAccount.model')(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x9d')]=require('../api/intFreshsalesConfiguration/intFreshsalesConfiguration.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xb1')]=require(_0x41cf05('0x5b'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x13')]=require('../api/integration/integration.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x175')]=require(_0x41cf05('0xb5'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x170')]=require(_0x41cf05('0x1eb'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xdb')]=require('../api/chatInternalMessage/chatInternalMessage.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['JscriptyAnswerReport']=require('../api/jscriptyAnswerReport/jscriptyAnswerReport.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['JscriptyQuestionReport']=require('../api/jscriptyQuestionReport/jscriptyQuestionReport.model')(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x1b4')]=require(_0x41cf05('0x1a6'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['SmsQueueReport']=require(_0x41cf05('0x57'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xff')]=require('../api/squareReport/squareReport.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x12')]=require('../api/squareReportDetail/squareReportDetail.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x11e')]=require(_0x41cf05('0x1db'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x1b8')]=require(_0x41cf05('0x174'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1bf')]=require(_0x41cf05('0x1b9'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['SquareProject']=require(_0x41cf05('0x28'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x2d')]=require(_0x41cf05('0x1b0'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1a')]=require(_0x41cf05('0x122'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db['Team']=require(_0x41cf05('0x7f'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x10f')]=require(_0x41cf05('0x10c'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['Campaign']=require('../api/campaign/campaign.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['Migration']=require('../api/migration/migration.model')(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db['Attachment']=require(_0x41cf05('0xd3'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db['Plugin']=require(_0x41cf05('0x121'))(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0x1e5')]=require('../api/mailTransferReport/mailTransferReport.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['ChatTransferReport']=require(_0x41cf05('0x9e'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['FaxTransferReport']=require(_0x41cf05('0x18d'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x5a')]=require('../api/openchannelTransferReport/openchannelTransferReport.model')(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x6a')]=require(_0x41cf05('0xc2'))(db['sequelize'],Sequelize['DataTypes']),db[_0x41cf05('0xbb')]=require(_0x41cf05('0x9c'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x172')]=require(_0x41cf05('0xf9'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x187')]=require(_0x41cf05('0x15a'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['UserProfileSection']=require(_0x41cf05('0x182'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x165')]=require(_0x41cf05('0x1cc'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x66')]=require('../api/notification/notification.model')(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x159')]=require('../api/whatsappAccount/whatsappAccount.model')(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x1cd')]=require(_0x41cf05('0x143'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db['WhatsappInteraction']=require(_0x41cf05('0x186'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0xb')]=require(_0x41cf05('0x11b'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x1de')]=require(_0x41cf05('0x29'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x157')]=require(_0x41cf05('0x34'))(db['sequelize'],Sequelize[_0x41cf05('0x1c1')]),db[_0x41cf05('0x18b')]=require(_0x41cf05('0xd9'))(db[_0x41cf05('0x10d')],Sequelize['DataTypes']),db[_0x41cf05('0x160')]=require(_0x41cf05('0x9b'))(db[_0x41cf05('0x10d')],Sequelize[_0x41cf05('0x1c1')]),db['User'][_0x41cf05('0x199')](db[_0x41cf05('0x3a')],{'as':_0x41cf05('0x3a'),'onDelete':'cascade','foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0xf2')]['hasMany'](db[_0x41cf05('0x1d')],{'as':_0x41cf05('0x1d4'),'foreignKey':'UserId'}),db[_0x41cf05('0xf2')][_0x41cf05('0x1c')](db['UserVoiceQueueRt'],{'as':_0x41cf05('0xf3'),'foreignKey':'UserId'}),db['User'][_0x41cf05('0x1c')](db['VoiceExtension'],{'as':_0x41cf05('0x190'),'onDelete':_0x41cf05('0x166'),'hooks':!![]}),db[_0x41cf05('0xf2')][_0x41cf05('0x1c')](db[_0x41cf05('0x10b')],{'as':_0x41cf05('0x89'),'foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0xf2')][_0x41cf05('0x1c')](db[_0x41cf05('0x161')],{'as':_0x41cf05('0x115'),'foreignKey':_0x41cf05('0x1a5')}),db['User'][_0x41cf05('0x1c')](db['ReportAgentPreview'],{'as':_0x41cf05('0xda'),'foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0xf2')][_0x41cf05('0x1c')](db[_0x41cf05('0xe9')],{'as':'OpenchannelInteractions','foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0xf2')]['hasMany'](db[_0x41cf05('0xe5')],{'as':_0x41cf05('0xd'),'foreignKey':_0x41cf05('0x1a5')}),db['User'][_0x41cf05('0x1c')](db[_0x41cf05('0x1c3')],{'as':_0x41cf05('0x12c'),'foreignKey':_0x41cf05('0x1a5')}),db['User'][_0x41cf05('0x1c')](db[_0x41cf05('0x134')],{'as':_0x41cf05('0x177'),'foreignKey':'UserId'}),db['User']['hasMany'](db['MailInteraction'],{'as':'MailInteractions','foreignKey':_0x41cf05('0x1a5')}),db['User']['hasMany'](db[_0x41cf05('0xc8')],{'as':_0x41cf05('0xfb'),'foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0xf2')]['hasMany'](db[_0x41cf05('0x66')],{'as':_0x41cf05('0x2c'),'foreignKey':'SenderId'}),db['User'][_0x41cf05('0x114')](db[_0x41cf05('0x187')],{'as':_0x41cf05('0x187'),'foreignKey':'userProfileId','onDelete':_0x41cf05('0x14a')}),db['User']['belongsToMany'](db[_0x41cf05('0x14b')],{'as':'Groups','through':_0x41cf05('0x18')}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db['CmContact'],{'as':_0x41cf05('0x13a'),'through':_0x41cf05('0x1c6')}),db[_0x41cf05('0xf2')]['belongsToMany'](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0x54'),'through':_0x41cf05('0x1d5')}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0x1d6')],{'through':_0x41cf05('0x72')}),db['User'][_0x41cf05('0x97')](db[_0x41cf05('0x52')],{'as':'UserMailInteractions','through':'user_has_mail_interactions'}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0xe5')],{'as':_0x41cf05('0x1c9'),'through':_0x41cf05('0x1da')}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0x134')],{'as':_0x41cf05('0x17d'),'through':_0x41cf05('0x64')}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0x1c3')],{'as':_0x41cf05('0x192'),'through':_0x41cf05('0x85')}),db['User']['belongsToMany'](db[_0x41cf05('0xe9')],{'as':_0x41cf05('0x3'),'through':_0x41cf05('0x16c')}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0xc8')],{'as':_0x41cf05('0xb9'),'through':_0x41cf05('0x8d')}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0xfd')],{'as':_0x41cf05('0x1a1'),'through':_0x41cf05('0x4c'),'required':![]}),db['User'][_0x41cf05('0x97')](db[_0x41cf05('0x83')],{'as':_0x41cf05('0x111'),'through':_0x41cf05('0x7d'),'required':![]}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0x86')],{'as':'ChatQueues','through':_0x41cf05('0xcc'),'required':![],'hooks':!![]}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0xa0')],{'as':_0x41cf05('0x6e'),'through':_0x41cf05('0x73'),'required':![]}),db[_0x41cf05('0xf2')]['belongsToMany'](db[_0x41cf05('0x1aa')],{'as':_0x41cf05('0xc'),'through':'UserSmsQueue','required':![]}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0x33')],{'as':_0x41cf05('0x4'),'through':_0x41cf05('0x1a3'),'required':![]}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0x18b')],{'as':_0x41cf05('0x8e'),'through':_0x41cf05('0x62'),'required':![]}),db['User'][_0x41cf05('0x97')](db['CmList'],{'through':_0x41cf05('0x1d5')}),db['User'][_0x41cf05('0x97')](db['VoicePrefix'],{'as':_0x41cf05('0x148'),'through':_0x41cf05('0x6f'),'required':![]}),db[_0x41cf05('0xf2')]['belongsToMany'](db[_0x41cf05('0x43')],{'as':'ChatWebsites','through':_0x41cf05('0x1b7')}),db['User']['belongsToMany'](db[_0x41cf05('0x191')],{'as':_0x41cf05('0x5'),'through':'user_has_fax_accounts'}),db[_0x41cf05('0xf2')]['belongsToMany'](db[_0x41cf05('0x8f')],{'as':_0x41cf05('0x116'),'through':_0x41cf05('0x4a')}),db['User']['belongsToMany'](db[_0x41cf05('0x146')],{'as':_0x41cf05('0x178'),'through':'user_has_openchannel_accounts'}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db['SmsAccount'],{'as':_0x41cf05('0xe8'),'through':_0x41cf05('0x1b3')}),db[_0x41cf05('0xf2')]['belongsToMany'](db[_0x41cf05('0x159')],{'as':_0x41cf05('0x106'),'through':_0x41cf05('0x163')}),db[_0x41cf05('0xf2')][_0x41cf05('0x97')](db[_0x41cf05('0x63')],{'as':_0x41cf05('0x1dd'),'through':_0x41cf05('0x1d7')}),db[_0x41cf05('0x36')][_0x41cf05('0x1c')](db[_0x41cf05('0x156')],{'as':_0x41cf05('0x84'),'onDelete':_0x41cf05('0x166'),'foreignKey':'ChanSpyId'}),db['VoiceContext'][_0x41cf05('0x1c')](db[_0x41cf05('0x156')],{'onDelete':_0x41cf05('0x166')}),db['VoiceExtension'][_0x41cf05('0x1c')](db[_0x41cf05('0x156')],{'as':_0x41cf05('0x8a'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x147')][_0x41cf05('0x97')](db[_0x41cf05('0x119')],{'as':'Sounds','through':_0x41cf05('0x125')}),db[_0x41cf05('0xfd')][_0x41cf05('0x1c')](db[_0x41cf05('0x38')],{'as':_0x41cf05('0x1e9'),'foreignKey':_0x41cf05('0x150')}),db['VoiceQueue'][_0x41cf05('0x1c')](db['CmHopper'],{'as':_0x41cf05('0x18a'),'foreignKey':'VoiceQueueId'}),db['VoiceQueue'][_0x41cf05('0x1c')](db['CmHopperFinal'],{'as':_0x41cf05('0x89'),'foreignKey':_0x41cf05('0x150')}),db[_0x41cf05('0xfd')][_0x41cf05('0x1c')](db[_0x41cf05('0x161')],{'as':_0x41cf05('0x1cf'),'foreignKey':'VoiceQueueId'}),db[_0x41cf05('0xfd')][_0x41cf05('0x1c')](db[_0x41cf05('0xda')],{'as':_0x41cf05('0xda'),'foreignKey':_0x41cf05('0x150')}),db[_0x41cf05('0xfd')][_0x41cf05('0x1c')](db[_0x41cf05('0xba')],{'as':'HopperBlacks','foreignKey':_0x41cf05('0x150')}),db['VoiceQueue'][_0x41cf05('0x1c')](db[_0x41cf05('0x1b4')],{'as':_0x41cf05('0x169'),'foreignKey':_0x41cf05('0x150')}),db[_0x41cf05('0xfd')]['belongsTo'](db[_0x41cf05('0x10')],{'as':_0x41cf05('0x10'),'foreignKey':_0x41cf05('0x184')}),db[_0x41cf05('0xfd')][_0x41cf05('0x114')](db[_0x41cf05('0x10')],{'as':_0x41cf05('0x108'),'foreignKey':_0x41cf05('0x1a7')}),db[_0x41cf05('0xfd')][_0x41cf05('0x114')](db[_0x41cf05('0x8c')],{'as':_0x41cf05('0x8c'),'foreignKey':_0x41cf05('0x15c')}),db[_0x41cf05('0xfd')][_0x41cf05('0x114')](db[_0x41cf05('0x17f')],{'as':'mandatoryDispositionPause','foreignKey':_0x41cf05('0x130')}),db[_0x41cf05('0xfd')]['belongsToMany'](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0x54'),'through':'voice_queues_has_cm_lists'}),db[_0x41cf05('0xfd')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':'Agents','through':_0x41cf05('0x4c')}),db['VoiceQueue'][_0x41cf05('0x97')](db['Team'],{'as':'Teams','through':_0x41cf05('0x79')}),db[_0x41cf05('0xfd')][_0x41cf05('0x97')](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0x1bb'),'through':_0x41cf05('0xf7')}),db['VoiceRecording'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xf2'),'foreignKey':_0x41cf05('0x1a5')}),db['ScreenRecording'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':'User','foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0x3a')][_0x41cf05('0x1c')](db[_0x41cf05('0x94')],{'as':_0x41cf05('0x1c7'),'onDelete':_0x41cf05('0x166'),'foreignKey':'mailboxuser','sourceKey':_0x41cf05('0x4f')}),db[_0x41cf05('0x94')]['belongsTo'](db[_0x41cf05('0x3a')],{'foreignKey':_0x41cf05('0x19b'),'targetKey':_0x41cf05('0x4f')}),db['VoiceCallReport']['hasMany'](db[_0x41cf05('0xea')],{'as':_0x41cf05('0x7c'),'foreignKey':_0x41cf05('0x77'),'constraints':![]}),db[_0x41cf05('0xeb')]['hasMany'](db[_0x41cf05('0x24')],{'as':_0x41cf05('0x1ae'),'foreignKey':_0x41cf05('0x77'),'constraints':![]}),db[_0x41cf05('0xeb')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xf2'),'foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0xeb')]['belongsTo'](db[_0x41cf05('0x45')],{'as':'Contact','foreignKey':_0x41cf05('0xb2')}),db[_0x41cf05('0x8f')]['hasOne'](db[_0x41cf05('0x1bd')],{'as':_0x41cf05('0x68'),'foreignKey':_0x41cf05('0x9a'),'onDelete':_0x41cf05('0x166')}),db['MailAccount'][_0x41cf05('0x199')](db[_0x41cf05('0x17e')],{'as':_0x41cf05('0x3c'),'foreignKey':'MailAccountId','onDelete':_0x41cf05('0x166')}),db['MailAccount'][_0x41cf05('0x1c')](db[_0x41cf05('0x15f')],{'as':_0x41cf05('0x42'),'foreignKey':_0x41cf05('0x9a')}),db[_0x41cf05('0x8f')][_0x41cf05('0x1c')](db[_0x41cf05('0x81')],{'as':_0x41cf05('0x14e'),'foreignKey':_0x41cf05('0x9a')}),db[_0x41cf05('0x8f')][_0x41cf05('0x1c')](db[_0x41cf05('0xc6')],{'as':_0x41cf05('0x1c7'),'foreignKey':'MailAccountId'}),db[_0x41cf05('0x8f')]['hasMany'](db[_0x41cf05('0x52')],{'as':_0x41cf05('0x1e1')}),db[_0x41cf05('0x8f')][_0x41cf05('0x1c')](db['MailApplication'],{'as':_0x41cf05('0x8a')}),db[_0x41cf05('0x8f')][_0x41cf05('0x114')](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0xb8'),'foreignKey':_0x41cf05('0x133')}),db[_0x41cf05('0x8f')][_0x41cf05('0x114')](db['Template'],{'as':_0x41cf05('0x32'),'foreignKey':_0x41cf05('0x9f')}),db['MailAccount'][_0x41cf05('0x114')](db[_0x41cf05('0x17f')],{'as':'mandatoryDispositionPause','foreignKey':_0x41cf05('0x130')}),db['MailAccount'][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xa4'),'through':_0x41cf05('0x4a')}),db[_0x41cf05('0x83')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xa4'),'through':_0x41cf05('0x7d')}),db['MailQueue'][_0x41cf05('0x97')](db[_0x41cf05('0x1d6')],{'through':_0x41cf05('0xae'),'as':_0x41cf05('0xec')}),db[_0x41cf05('0x52')][_0x41cf05('0x1c')](db[_0x41cf05('0xc6')],{'as':_0x41cf05('0x1c7'),'onDelete':_0x41cf05('0x166'),'foreignKey':'MailInteractionId'}),db[_0x41cf05('0x52')][_0x41cf05('0x114')](db['MailAccount'],{'as':_0x41cf05('0xe3'),'foreignKey':'MailAccountId'}),db[_0x41cf05('0x52')]['belongsTo'](db[_0x41cf05('0x45')],{'as':'Contact','foreignKey':_0x41cf05('0xb2')}),db['MailInteraction'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xf8'),'foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0x52')][_0x41cf05('0x97')](db[_0x41cf05('0x7a')],{'through':_0x41cf05('0xab'),'as':'Tags'}),db[_0x41cf05('0x52')][_0x41cf05('0x97')](db['Tag'],{'through':_0x41cf05('0xab'),'as':_0x41cf05('0x4b')}),db['MailInteraction']['belongsToMany'](db['User'],{'as':_0x41cf05('0x98'),'through':_0x41cf05('0x40'),'foreignKey':_0x41cf05('0x1b5')}),db[_0x41cf05('0xc6')]['hasMany'](db[_0x41cf05('0xac')],{'as':_0x41cf05('0x59'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0xc6')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':'User'}),db[_0x41cf05('0xc6')]['belongsTo'](db['CmContact'],{'onDelete':_0x41cf05('0x166'),'as':'Contact'}),db[_0x41cf05('0xc6')][_0x41cf05('0x114')](db['MailInteraction'],{'as':_0x41cf05('0x93'),'foreignKey':'MailInteractionId'}),db[_0x41cf05('0xc6')]['belongsTo'](db[_0x41cf05('0x8f')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x9a')}),db[_0x41cf05('0x132')]['belongsTo'](db['User'],{'onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0x132')][_0x41cf05('0x114')](db['MailQueue'],{'onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0x132')][_0x41cf05('0x114')](db[_0x41cf05('0x8f')],{'onDelete':'restrict'}),db['MailApplication']['belongsTo'](db['Interval'],{'onDelete':'restrict','foreignKey':'IntervalId'}),db['MailApplication'][_0x41cf05('0x114')](db['Tag'],{'onDelete':'restrict','foreignKey':'TagId'}),db[_0x41cf05('0x14f')][_0x41cf05('0x114')](db['MailAccount'],{}),db['MailQueueReport'][_0x41cf05('0x114')](db[_0x41cf05('0xbb')],{'as':'List','foreignKey':_0x41cf05('0x133')}),db['MailQueueReport'][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'as':'Contact','foreignKey':_0x41cf05('0xb2')}),db[_0x41cf05('0x14f')][_0x41cf05('0x114')](db[_0x41cf05('0x52')],{}),db[_0x41cf05('0x14f')][_0x41cf05('0x114')](db[_0x41cf05('0xc6')],{}),db[_0x41cf05('0x14f')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{}),db['MailQueueReport'][_0x41cf05('0x114')](db[_0x41cf05('0x83')],{}),db[_0x41cf05('0x140')]['hasMany'](db[_0x41cf05('0x16e')],{'as':_0x41cf05('0xcd'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x191')][_0x41cf05('0x1c')](db[_0x41cf05('0x15f')],{'as':_0x41cf05('0x42'),'foreignKey':'FaxAccountId'}),db[_0x41cf05('0x191')][_0x41cf05('0x1c')](db[_0x41cf05('0x81')],{'as':'Answers','foreignKey':'FaxAccountId'}),db['FaxAccount'][_0x41cf05('0x1c')](db['FaxInteraction'],{'as':'Interactions'}),db[_0x41cf05('0x191')][_0x41cf05('0x1c')](db['FaxApplication'],{'as':_0x41cf05('0x8a')}),db[_0x41cf05('0x191')][_0x41cf05('0x1c')](db[_0x41cf05('0x156')],{'as':'Exntensions','onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x191')][_0x41cf05('0x1c')](db[_0x41cf05('0x76')],{'as':'Messages'}),db['FaxAccount']['belongsTo'](db[_0x41cf05('0x10')],{'as':_0x41cf05('0x10')}),db[_0x41cf05('0x191')][_0x41cf05('0x114')](db['CmList'],{'as':'List','foreignKey':_0x41cf05('0x133')}),db[_0x41cf05('0x191')]['belongsTo'](db[_0x41cf05('0x17f')],{'as':_0x41cf05('0x95'),'foreignKey':_0x41cf05('0x130')}),db[_0x41cf05('0x191')][_0x41cf05('0x97')](db['User'],{'as':'Agents','through':_0x41cf05('0x152')}),db['FaxApplication'][_0x41cf05('0x114')](db['User'],{'onDelete':'restrict'}),db[_0x41cf05('0xf6')][_0x41cf05('0x114')](db[_0x41cf05('0xa0')],{'onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0xf6')][_0x41cf05('0x114')](db[_0x41cf05('0x191')],{'onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0xf6')][_0x41cf05('0x114')](db[_0x41cf05('0x7a')],{'onDelete':_0x41cf05('0x14a'),'foreignKey':'TagId'}),db[_0x41cf05('0x134')]['hasMany'](db['FaxMessage'],{'as':_0x41cf05('0x1c7'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0xa2')}),db[_0x41cf05('0x134')][_0x41cf05('0x114')](db[_0x41cf05('0x191')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x49')}),db[_0x41cf05('0x134')][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'as':_0x41cf05('0xed'),'foreignKey':_0x41cf05('0xb2')}),db['FaxInteraction'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xf8'),'foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0x134')][_0x41cf05('0x97')](db[_0x41cf05('0x7a')],{'through':'fax_interaction_has_tags','as':_0x41cf05('0x22')}),db[_0x41cf05('0x134')]['belongsToMany'](db[_0x41cf05('0x7a')],{'through':_0x41cf05('0xf4'),'as':_0x41cf05('0x4b')}),db[_0x41cf05('0x134')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x98'),'through':_0x41cf05('0x64'),'foreignKey':_0x41cf05('0xa2')}),db[_0x41cf05('0x76')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'onDelete':'cascade','as':_0x41cf05('0xf2')}),db[_0x41cf05('0x76')][_0x41cf05('0x114')](db[_0x41cf05('0x134')],{'as':_0x41cf05('0x93'),'foreignKey':_0x41cf05('0xa2')}),db['FaxMessage'][_0x41cf05('0x114')](db['CmContact'],{'onDelete':_0x41cf05('0x166'),'as':'Contact'}),db[_0x41cf05('0x76')][_0x41cf05('0x114')](db[_0x41cf05('0xac')],{'as':_0x41cf05('0xac'),'foreignKey':_0x41cf05('0x70')}),db[_0x41cf05('0x76')]['belongsTo'](db[_0x41cf05('0x191')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x49')}),db['FaxQueue'][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xa4'),'through':_0x41cf05('0x73')}),db[_0x41cf05('0xa0')][_0x41cf05('0x97')](db['Team'],{'through':_0x41cf05('0x15d'),'as':_0x41cf05('0xec')}),db[_0x41cf05('0x1e3')][_0x41cf05('0x114')](db[_0x41cf05('0x191')],{}),db[_0x41cf05('0x1e3')][_0x41cf05('0x114')](db['CmList'],{'as':_0x41cf05('0xb8'),'foreignKey':'ListId'}),db[_0x41cf05('0x1e3')][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'as':_0x41cf05('0xed'),'foreignKey':_0x41cf05('0xb2')}),db[_0x41cf05('0x1e3')]['belongsTo'](db['FaxInteraction'],{}),db['FaxQueueReport'][_0x41cf05('0x114')](db[_0x41cf05('0x76')],{}),db[_0x41cf05('0x1e3')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{}),db[_0x41cf05('0x1e3')][_0x41cf05('0x114')](db[_0x41cf05('0xa0')],{}),db[_0x41cf05('0xe2')][_0x41cf05('0x1c')](db[_0x41cf05('0x15f')],{'as':_0x41cf05('0x42'),'foreignKey':_0x41cf05('0x137')}),db[_0x41cf05('0xe2')]['hasMany'](db[_0x41cf05('0x81')],{'as':_0x41cf05('0x14e'),'foreignKey':'SmsAccountId'}),db[_0x41cf05('0xe2')][_0x41cf05('0x1c')](db[_0x41cf05('0xa3')],{'as':_0x41cf05('0x1c7'),'foreignKey':_0x41cf05('0x137')}),db[_0x41cf05('0xe2')][_0x41cf05('0x1c')](db[_0x41cf05('0x1c3')],{'as':_0x41cf05('0x1e1')}),db[_0x41cf05('0xe2')][_0x41cf05('0x1c')](db[_0x41cf05('0x168')],{'as':_0x41cf05('0x8a')}),db['SmsAccount'][_0x41cf05('0x114')](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0xb8'),'foreignKey':_0x41cf05('0x133')}),db[_0x41cf05('0xe2')][_0x41cf05('0x114')](db[_0x41cf05('0x17f')],{'as':_0x41cf05('0x95'),'foreignKey':_0x41cf05('0x130')}),db[_0x41cf05('0xe2')]['belongsToMany'](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xa4'),'through':_0x41cf05('0x1b3')}),db[_0x41cf05('0x168')][_0x41cf05('0x114')](db['User'],{'onDelete':_0x41cf05('0x14a')}),db['SmsApplication']['belongsTo'](db[_0x41cf05('0x1aa')],{'onDelete':'restrict'}),db[_0x41cf05('0x168')][_0x41cf05('0x114')](db[_0x41cf05('0xe2')],{'onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0x168')][_0x41cf05('0x114')](db[_0x41cf05('0x8c')],{'onDelete':_0x41cf05('0x14a'),'foreignKey':_0x41cf05('0x15c')}),db['SmsApplication'][_0x41cf05('0x114')](db[_0x41cf05('0x7a')],{'onDelete':_0x41cf05('0x14a'),'foreignKey':_0x41cf05('0x7b')}),db[_0x41cf05('0x1c3')][_0x41cf05('0x1c')](db[_0x41cf05('0xa3')],{'as':_0x41cf05('0x1c7'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x25')}),db[_0x41cf05('0x1c3')][_0x41cf05('0x114')](db['SmsAccount'],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x137')}),db[_0x41cf05('0x1c3')][_0x41cf05('0x114')](db['CmContact'],{'as':_0x41cf05('0xed'),'foreignKey':_0x41cf05('0xb2')}),db['SmsInteraction'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xf8'),'foreignKey':'UserId'}),db['SmsInteraction'][_0x41cf05('0x97')](db[_0x41cf05('0x7a')],{'through':_0x41cf05('0x18c'),'as':_0x41cf05('0x22')}),db[_0x41cf05('0x1c3')][_0x41cf05('0x97')](db[_0x41cf05('0x7a')],{'through':_0x41cf05('0x18c'),'as':_0x41cf05('0x4b')}),db['SmsInteraction'][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x98'),'through':'user_has_sms_interactions','foreignKey':'SmsInteractionId'}),db[_0x41cf05('0xa3')][_0x41cf05('0x114')](db['User'],{'as':_0x41cf05('0xf2')}),db[_0x41cf05('0xa3')][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'onDelete':'cascade','as':_0x41cf05('0xed')}),db[_0x41cf05('0xa3')][_0x41cf05('0x114')](db[_0x41cf05('0x1c3')],{'onDelete':'cascade','as':_0x41cf05('0x93'),'foreignKey':_0x41cf05('0x25')}),db[_0x41cf05('0xa3')]['belongsTo'](db[_0x41cf05('0xe2')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x137')}),db[_0x41cf05('0x1aa')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':'Agents','through':_0x41cf05('0x1d1'),'foreignKey':'SmsQueueId'}),db[_0x41cf05('0x1aa')]['belongsToMany'](db[_0x41cf05('0x1d6')],{'through':_0x41cf05('0xe6'),'as':'Teams'}),db[_0x41cf05('0x146')]['hasMany'](db[_0x41cf05('0x15f')],{'as':_0x41cf05('0x42'),'foreignKey':_0x41cf05('0x1')}),db['OpenchannelAccount'][_0x41cf05('0x1c')](db[_0x41cf05('0x81')],{'as':_0x41cf05('0x14e'),'foreignKey':_0x41cf05('0x1')}),db[_0x41cf05('0x146')][_0x41cf05('0x1c')](db['OpenchannelInteraction'],{'as':'Interactions','foreignKey':_0x41cf05('0x1')}),db[_0x41cf05('0x146')][_0x41cf05('0x1c')](db[_0x41cf05('0x58')],{'as':_0x41cf05('0x1c7'),'foreignKey':_0x41cf05('0x1')}),db[_0x41cf05('0x146')]['hasMany'](db['OpenchannelApplication'],{'as':_0x41cf05('0x8a'),'foreignKey':'OpenchannelAccountId'}),db[_0x41cf05('0x146')]['belongsTo'](db['CmList'],{'as':_0x41cf05('0xb8'),'foreignKey':_0x41cf05('0x133')}),db[_0x41cf05('0x146')][_0x41cf05('0x114')](db[_0x41cf05('0x17f')],{'as':_0x41cf05('0x95'),'foreignKey':_0x41cf05('0x130')}),db['OpenchannelAccount'][_0x41cf05('0x97')](db['User'],{'as':_0x41cf05('0xa4'),'through':_0x41cf05('0x1ed')}),db[_0x41cf05('0x6d')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0x6d')][_0x41cf05('0x114')](db[_0x41cf05('0x33')],{'onDelete':'restrict','foreignKey':'OpenchannelQueueId'}),db[_0x41cf05('0x6d')][_0x41cf05('0x114')](db[_0x41cf05('0x146')],{'onDelete':'restrict','foreignKey':'OpenchannelAccountId'}),db[_0x41cf05('0x6d')][_0x41cf05('0x114')](db[_0x41cf05('0x8c')],{'onDelete':'restrict','foreignKey':'IntervalId'}),db['OpenchannelApplication'][_0x41cf05('0x114')](db[_0x41cf05('0x7a')],{'onDelete':'restrict','foreignKey':_0x41cf05('0x7b')}),db[_0x41cf05('0xe9')][_0x41cf05('0x1c')](db[_0x41cf05('0x58')],{'as':'Messages','onDelete':'cascade','foreignKey':_0x41cf05('0x44')}),db[_0x41cf05('0xe9')][_0x41cf05('0x114')](db[_0x41cf05('0x146')],{'as':'Account','foreignKey':_0x41cf05('0x1')}),db[_0x41cf05('0xe9')]['belongsTo'](db[_0x41cf05('0x45')],{'as':_0x41cf05('0xed'),'foreignKey':_0x41cf05('0xb2')}),db[_0x41cf05('0xe9')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':'Owner','foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0xe9')][_0x41cf05('0x97')](db[_0x41cf05('0x7a')],{'through':'openchannel_interaction_has_tags','as':_0x41cf05('0x22')}),db[_0x41cf05('0xe9')]['belongsToMany'](db['Tag'],{'through':_0x41cf05('0x78'),'as':'ThroughTags'}),db[_0x41cf05('0xe9')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x98'),'through':'user_has_openchannel_interactions','foreignKey':'OpenchannelInteractionId'}),db[_0x41cf05('0x58')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'onDelete':_0x41cf05('0x166'),'as':_0x41cf05('0xf2')}),db[_0x41cf05('0x58')][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'onDelete':_0x41cf05('0x166'),'as':_0x41cf05('0xed')}),db[_0x41cf05('0x58')]['belongsTo'](db[_0x41cf05('0xe9')],{'onDelete':_0x41cf05('0x166'),'as':_0x41cf05('0x93'),'foreignKey':_0x41cf05('0x44')}),db[_0x41cf05('0x58')][_0x41cf05('0x114')](db['Attachment'],{'as':_0x41cf05('0xac'),'foreignKey':_0x41cf05('0x70')}),db['OpenchannelMessage'][_0x41cf05('0x114')](db[_0x41cf05('0x146')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x1')}),db[_0x41cf05('0x33')]['belongsToMany'](db['User'],{'as':'Agents','through':_0x41cf05('0x1a3'),'foreignKey':'OpenchannelQueueId'}),db[_0x41cf05('0x33')][_0x41cf05('0x97')](db[_0x41cf05('0x1d6')],{'through':_0x41cf05('0x1e'),'as':'Teams'}),db[_0x41cf05('0x43')]['hasMany'](db[_0x41cf05('0x15f')],{'as':_0x41cf05('0x42'),'foreignKey':_0x41cf05('0x2b')}),db['ChatWebsite']['hasMany'](db['CannedAnswer'],{'as':_0x41cf05('0x14e'),'foreignKey':_0x41cf05('0x2b')}),db['ChatWebsite'][_0x41cf05('0x1c')](db[_0x41cf05('0x198')],{'as':'ProactiveActions'}),db[_0x41cf05('0x43')][_0x41cf05('0x1c')](db[_0x41cf05('0xe5')],{'as':_0x41cf05('0x1e1')}),db[_0x41cf05('0x43')][_0x41cf05('0x1c')](db[_0x41cf05('0x2a')],{'as':_0x41cf05('0x8a')}),db[_0x41cf05('0x43')]['hasMany'](db[_0x41cf05('0xb3')],{'as':_0x41cf05('0x1c7')}),db[_0x41cf05('0x43')][_0x41cf05('0x114')](db['CmList'],{'as':_0x41cf05('0xb8'),'foreignKey':'ListId'}),db['ChatWebsite'][_0x41cf05('0x114')](db['Interval'],{'as':'Interval','foreignKey':_0x41cf05('0x15c')}),db[_0x41cf05('0x43')]['belongsTo'](db[_0x41cf05('0x17f')],{'as':'mandatoryDispositionPause','foreignKey':_0x41cf05('0x130')}),db[_0x41cf05('0x43')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xa4'),'through':_0x41cf05('0x1b7')}),db['OpenchannelQueueReport']['belongsTo'](db[_0x41cf05('0x146')],{}),db[_0x41cf05('0x128')][_0x41cf05('0x114')](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0xb8'),'foreignKey':_0x41cf05('0x133')}),db[_0x41cf05('0x128')][_0x41cf05('0x114')](db['CmContact'],{'as':_0x41cf05('0xed'),'foreignKey':'ContactId'}),db[_0x41cf05('0x128')][_0x41cf05('0x114')](db[_0x41cf05('0xe9')],{}),db[_0x41cf05('0x128')][_0x41cf05('0x114')](db[_0x41cf05('0x58')],{}),db['OpenchannelQueueReport']['belongsTo'](db[_0x41cf05('0xf2')],{}),db[_0x41cf05('0x128')][_0x41cf05('0x114')](db[_0x41cf05('0x33')],{}),db[_0x41cf05('0x2a')]['belongsTo'](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x127'),'foreignKey':_0x41cf05('0x1a5'),'onDelete':'restrict'}),db[_0x41cf05('0x2a')][_0x41cf05('0x114')](db[_0x41cf05('0x86')],{'as':_0x41cf05('0x12a'),'foreignKey':'ChatQueueId','onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0x2a')][_0x41cf05('0x114')](db[_0x41cf05('0x43')],{'as':_0x41cf05('0x1a2'),'foreignKey':_0x41cf05('0x2b'),'onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0x2a')][_0x41cf05('0x114')](db[_0x41cf05('0x7a')],{'onDelete':_0x41cf05('0x14a'),'foreignKey':'TagId'}),db[_0x41cf05('0xe5')][_0x41cf05('0x1c')](db[_0x41cf05('0xb3')],{'as':_0x41cf05('0x1c7'),'onDelete':'cascade','foreignKey':_0x41cf05('0x180')}),db[_0x41cf05('0xe5')][_0x41cf05('0x114')](db['ChatWebsite'],{'as':'Account','foreignKey':_0x41cf05('0x2b')}),db[_0x41cf05('0xe5')][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'as':_0x41cf05('0xed'),'foreignKey':_0x41cf05('0xb2')}),db[_0x41cf05('0xe5')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xf8'),'foreignKey':'UserId'}),db[_0x41cf05('0xe5')]['belongsToMany'](db['Tag'],{'through':_0x41cf05('0x3f'),'as':'Tags'}),db[_0x41cf05('0xe5')][_0x41cf05('0x97')](db['Tag'],{'through':_0x41cf05('0x3f'),'as':_0x41cf05('0x4b')}),db[_0x41cf05('0xe5')][_0x41cf05('0x97')](db['User'],{'as':'Users','through':_0x41cf05('0x1da'),'foreignKey':_0x41cf05('0x180')}),db['ChatMessage']['belongsTo'](db['User'],{'onDelete':_0x41cf05('0x166'),'as':_0x41cf05('0xf2')}),db[_0x41cf05('0xb3')][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'onDelete':'cascade','as':_0x41cf05('0xed'),'foreignKey':'ContactId'}),db[_0x41cf05('0xb3')][_0x41cf05('0x114')](db[_0x41cf05('0xe5')],{'onDelete':_0x41cf05('0x166'),'as':'Interaction','foreignKey':_0x41cf05('0x180')}),db['ChatMessage'][_0x41cf05('0x114')](db[_0x41cf05('0xac')],{'as':_0x41cf05('0xac'),'foreignKey':'AttachmentId'}),db['ChatMessage'][_0x41cf05('0x114')](db[_0x41cf05('0x43')],{'as':_0x41cf05('0xe3'),'foreignKey':'ChatWebsiteId'}),db[_0x41cf05('0x15b')][_0x41cf05('0x114')](db['CmContact'],{'onDelete':_0x41cf05('0x166'),'as':_0x41cf05('0xed'),'foreignKey':_0x41cf05('0xb2')}),db[_0x41cf05('0x15b')][_0x41cf05('0x114')](db['ChatWebsite'],{'as':'Account','foreignKey':'ChatWebsiteId'}),db['ChatQueue'][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xa4'),'through':_0x41cf05('0xcc'),'hooks':!![]}),db[_0x41cf05('0x86')][_0x41cf05('0x97')](db[_0x41cf05('0x1d6')],{'through':_0x41cf05('0x65'),'as':_0x41cf05('0xec')}),db['ChatGroup'][_0x41cf05('0x1c')](db[_0x41cf05('0xdb')],{'as':_0x41cf05('0x1c7'),'foreignKey':_0x41cf05('0x92'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x14b')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x1e9'),'through':_0x41cf05('0x18')}),db['ChatProactiveAction']['belongsTo'](db['ChatWebsite'],{'as':_0x41cf05('0x1a2'),'foreignKey':_0x41cf05('0x2b')}),db[_0x41cf05('0x1ad')]['hasMany'](db[_0x41cf05('0x45')],{'as':_0x41cf05('0x13a'),'foreignKey':_0x41cf05('0x141')}),db['CmContact'][_0x41cf05('0x1c')](db[_0x41cf05('0x197')],{'as':_0x41cf05('0x18a'),'foreignKey':_0x41cf05('0xb2')}),db['CmContact'][_0x41cf05('0x1c')](db[_0x41cf05('0x10b')],{'as':'HopperFinals','foreignKey':_0x41cf05('0xb2')}),db[_0x41cf05('0x45')][_0x41cf05('0x1c')](db[_0x41cf05('0x161')],{'as':'HopperHistories','foreignKey':_0x41cf05('0xb2')}),db['CmContact'][_0x41cf05('0x1c')](db[_0x41cf05('0xda')],{'as':_0x41cf05('0xda'),'foreignKey':'ContactId'}),db[_0x41cf05('0x45')][_0x41cf05('0x1c')](db['JscriptySessionReport'],{'as':_0x41cf05('0x169'),'foreignKey':_0x41cf05('0xb2')}),db[_0x41cf05('0x45')][_0x41cf05('0x1c')](db[_0x41cf05('0xe9')],{'as':_0x41cf05('0xa5'),'foreignKey':_0x41cf05('0xb2'),'onDelete':_0x41cf05('0x14a')}),db['CmContact']['hasMany'](db['ChatInteraction'],{'as':_0x41cf05('0xd'),'foreignKey':_0x41cf05('0xb2'),'onDelete':'restrict'}),db[_0x41cf05('0x45')][_0x41cf05('0x1c')](db[_0x41cf05('0x1c3')],{'as':'SmsInteractions','foreignKey':_0x41cf05('0xb2'),'onDelete':_0x41cf05('0x14a')}),db['CmContact']['hasMany'](db[_0x41cf05('0x134')],{'as':'FaxInteractions','foreignKey':_0x41cf05('0xb2'),'onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0x45')][_0x41cf05('0x1c')](db[_0x41cf05('0x52')],{'as':_0x41cf05('0x136'),'foreignKey':_0x41cf05('0xb2'),'onDelete':'restrict'}),db['CmContact'][_0x41cf05('0x114')](db[_0x41cf05('0x1ad')],{'as':_0x41cf05('0x1c5'),'foreignKey':_0x41cf05('0x141')}),db['CmContact'][_0x41cf05('0x114')](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0xb8'),'foreignKey':'ListId','onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x45')]['belongsToMany'](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x98'),'through':'cm_user_has_contacts'}),db[_0x41cf05('0x45')][_0x41cf05('0x97')](db[_0x41cf05('0x7a')],{'as':_0x41cf05('0x22'),'through':_0x41cf05('0x123')}),db[_0x41cf05('0x45')][_0x41cf05('0x97')](db[_0x41cf05('0x7a')],{'through':_0x41cf05('0x123'),'as':_0x41cf05('0x4b')}),db[_0x41cf05('0x197')][_0x41cf05('0x114')](db['CmContact'],{'as':_0x41cf05('0xed'),'foreignKey':'ContactId','onDelete':_0x41cf05('0x166')}),db['CmHopper']['belongsTo'](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0xb8'),'foreignKey':_0x41cf05('0x133'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x197')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x127'),'foreignKey':_0x41cf05('0x1a5')}),db[_0x41cf05('0x197')][_0x41cf05('0x114')](db[_0x41cf05('0xfd')],{'as':_0x41cf05('0x12a'),'foreignKey':_0x41cf05('0x150'),'onDelete':'cascade'}),db[_0x41cf05('0x197')][_0x41cf05('0x114')](db[_0x41cf05('0x100')],{'as':_0x41cf05('0x100'),'foreignKey':_0x41cf05('0x11'),'onDelete':'cascade'}),db['CmHopper'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xf8'),'foreignKey':_0x41cf05('0x154')}),db[_0x41cf05('0xba')]['belongsTo'](db['CmContact'],{'as':_0x41cf05('0xed'),'foreignKey':'ContactId','onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0xba')]['belongsTo'](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0xb8'),'foreignKey':_0x41cf05('0x133'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0xba')][_0x41cf05('0x114')](db['VoiceQueue'],{'as':_0x41cf05('0x12a'),'foreignKey':'VoiceQueueId','onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0xba')]['belongsTo'](db[_0x41cf05('0x100')],{'as':'Campaign','foreignKey':_0x41cf05('0x11'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x21')][_0x41cf05('0x1c')](db['Condition'],{'as':{'plural':'All','singular':_0x41cf05('0xa8')},'foreignKey':_0x41cf05('0xbc'),'onDelete':_0x41cf05('0x166'),'hooks':!![]}),db['Automation']['hasMany'](db[_0x41cf05('0x1b2')],{'as':{'plural':_0x41cf05('0xca'),'singular':_0x41cf05('0x173')},'foreignKey':'AutomationAnyId','onDelete':'cascade','hooks':!![]}),db['Automation'][_0x41cf05('0x1c')](db[_0x41cf05('0xe0')],{'as':'Actions','foreignKey':_0x41cf05('0xb4'),'onDelete':_0x41cf05('0x166'),'hooks':!![]}),db[_0x41cf05('0x15f')][_0x41cf05('0x1c')](db[_0x41cf05('0x15f')],{'as':_0x41cf05('0x42'),'foreignKey':_0x41cf05('0x103'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x8c')]['hasMany'](db[_0x41cf05('0x8c')],{'as':_0x41cf05('0x1a0'),'foreignKey':'IntervalId','onDelete':_0x41cf05('0x166'),'hooks':!![],'required':![]}),db[_0x41cf05('0x8c')][_0x41cf05('0x1c')](db[_0x41cf05('0x156')],{'as':_0x41cf05('0x190'),'foreignKey':_0x41cf05('0x15c'),'onDelete':'restrict'}),db['Interval'][_0x41cf05('0x1c')](db[_0x41cf05('0x132')],{'as':_0x41cf05('0x1be'),'foreignKey':_0x41cf05('0x15c')}),db[_0x41cf05('0x8c')]['hasMany'](db['ChatApplication'],{'as':'ChatApplications','foreignKey':'IntervalId'}),db[_0x41cf05('0x8c')]['hasMany'](db['FaxApplication'],{'as':_0x41cf05('0x109'),'foreignKey':'IntervalId'}),db[_0x41cf05('0x8c')][_0x41cf05('0x1c')](db[_0x41cf05('0x168')],{'as':_0x41cf05('0x194'),'foreignKey':'IntervalId'}),db[_0x41cf05('0x99')][_0x41cf05('0x114')](db['MailAccount'],{}),db['Schedule'][_0x41cf05('0x114')](db[_0x41cf05('0x104')],{'foreignKey':_0x41cf05('0xa9')}),db['Schedule'][_0x41cf05('0x114')](db[_0x41cf05('0x1f0')],{'foreignKey':_0x41cf05('0x11c')}),db[_0x41cf05('0x119')][_0x41cf05('0x97')](db[_0x41cf05('0x147')],{'as':_0x41cf05('0xdd'),'through':'moh_has_sounds','onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0x7a')]['belongsToMany'](db[_0x41cf05('0x45')],{'through':_0x41cf05('0x123')}),db['Tag']['belongsToMany'](db[_0x41cf05('0xe5')],{'through':_0x41cf05('0x3f')}),db[_0x41cf05('0x7a')][_0x41cf05('0x97')](db[_0x41cf05('0x52')],{'through':_0x41cf05('0xab')}),db[_0x41cf05('0x7a')][_0x41cf05('0x97')](db[_0x41cf05('0x1c3')],{'through':'sms_interaction_has_tags'}),db[_0x41cf05('0x7a')][_0x41cf05('0x97')](db[_0x41cf05('0x134')],{'through':'fax_interaction_has_tags'}),db[_0x41cf05('0x7a')][_0x41cf05('0x97')](db[_0x41cf05('0xe9')],{'through':'openchannel_interaction_has_tags'}),db['Tag']['belongsToMany'](db[_0x41cf05('0xc8')],{'through':'whatsapp_interaction_has_tags'}),db[_0x41cf05('0x15')]['hasMany'](db['Condition'],{'as':{'plural':'AllConditions','singular':'AllCondition'},'foreignKey':_0x41cf05('0x3e'),'onDelete':'cascade','hooks':!![]}),db[_0x41cf05('0x15')][_0x41cf05('0x1c')](db[_0x41cf05('0x1b2')],{'as':{'plural':'AnyConditions','singular':_0x41cf05('0x16')},'foreignKey':'TriggerAnyId','onDelete':'cascade','hooks':!![]}),db['Trigger'][_0x41cf05('0x1c')](db[_0x41cf05('0xe0')],{'as':'Actions','foreignKey':_0x41cf05('0x1b6'),'onDelete':'cascade','hooks':!![]}),db['AnalyticCustomReport'][_0x41cf05('0x1c')](db['AnalyticFieldReport'],{'as':_0x41cf05('0x1d9'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x11c'),'hooks':!![]}),db[_0x41cf05('0x104')][_0x41cf05('0x1c')](db[_0x41cf05('0x171')],{'as':_0x41cf05('0x1d9'),'onDelete':'cascade','foreignKey':_0x41cf05('0xa9')}),db[_0x41cf05('0x23')][_0x41cf05('0x1c')](db[_0x41cf05('0x171')],{'as':_0x41cf05('0x1d9'),'onDelete':_0x41cf05('0x166'),'foreignKey':'MetricId'}),db[_0x41cf05('0x171')][_0x41cf05('0x114')](db['AnalyticMetric'],{'foreignKey':_0x41cf05('0x1c8')}),db[_0x41cf05('0x1e0')]['hasMany'](db['SalesforceConfiguration'],{'as':_0x41cf05('0x0'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x13e')][_0x41cf05('0x1c')](db['SalesforceField'],{'as':_0x41cf05('0x105'),'onDelete':'cascade','foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x13e')]['hasMany'](db[_0x41cf05('0x164')],{'as':_0x41cf05('0x1af'),'onDelete':_0x41cf05('0x166'),'foreignKey':'DescriptionId'}),db[_0x41cf05('0x13e')][_0x41cf05('0x1c')](db['SalesforceField'],{'as':'Fields','onDelete':'cascade','foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x13e')][_0x41cf05('0x114')](db['SalesforceAccount'],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x164')][_0x41cf05('0x1c')](db[_0x41cf05('0x164')],{'as':_0x41cf05('0x1ef'),'foreignKey':_0x41cf05('0x16b')}),db['SalesforceField'][_0x41cf05('0x1c')](db[_0x41cf05('0x164')],{'as':'Description','foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x164')]['hasMany'](db[_0x41cf05('0x164')],{'as':_0x41cf05('0x1b'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x164')][_0x41cf05('0x114')](db['Variable'],{'as':_0x41cf05('0xd0'),'foreignKey':'VariableId'}),db[_0x41cf05('0x117')][_0x41cf05('0x1c')](db['SugarcrmConfiguration'],{'as':_0x41cf05('0x0'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x17b')]['hasMany'](db['SugarcrmField'],{'as':'Subjects','onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x17b')][_0x41cf05('0x1c')](db[_0x41cf05('0x88')],{'as':_0x41cf05('0x1af'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x17b')][_0x41cf05('0x1c')](db[_0x41cf05('0x88')],{'as':_0x41cf05('0x1d9'),'onDelete':'cascade','foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x17b')][_0x41cf05('0x114')](db[_0x41cf05('0x117')],{'as':'Account','foreignKey':_0x41cf05('0x1d0')}),db['SugarcrmField']['hasMany'](db[_0x41cf05('0x88')],{'as':_0x41cf05('0x1ef'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x88')][_0x41cf05('0x1c')](db['SugarcrmField'],{'as':_0x41cf05('0xc7'),'foreignKey':'DescriptionId'}),db[_0x41cf05('0x88')]['hasMany'](db[_0x41cf05('0x88')],{'as':_0x41cf05('0x1b'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x88')][_0x41cf05('0x114')](db[_0x41cf05('0xd0')],{'as':_0x41cf05('0xd0'),'foreignKey':'VariableId'}),db[_0x41cf05('0x1ea')][_0x41cf05('0x1c')](db[_0x41cf05('0x7e')],{'as':_0x41cf05('0x0'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x7e')]['hasMany'](db[_0x41cf05('0x5d')],{'as':'Subjects','onDelete':'cascade','foreignKey':'SubjectId'}),db[_0x41cf05('0x7e')][_0x41cf05('0x1c')](db[_0x41cf05('0x5d')],{'as':_0x41cf05('0x1af'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x7e')][_0x41cf05('0x1c')](db[_0x41cf05('0x5d')],{'as':_0x41cf05('0x1d9'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x7e')]['belongsTo'](db[_0x41cf05('0x1ea')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x7e')]['belongsToMany'](db['Tag'],{'through':_0x41cf05('0x144')}),db['DeskField']['hasMany'](db[_0x41cf05('0x5d')],{'as':_0x41cf05('0x1ef'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x5d')]['hasMany'](db[_0x41cf05('0x5d')],{'as':_0x41cf05('0xc7'),'foreignKey':'DescriptionId'}),db[_0x41cf05('0x5d')][_0x41cf05('0x1c')](db['DeskField'],{'as':_0x41cf05('0x1b'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x5d')][_0x41cf05('0x114')](db['Variable'],{'as':'Variable','foreignKey':'VariableId'}),db['ZohoAccount'][_0x41cf05('0x1c')](db['ZohoConfiguration'],{'as':_0x41cf05('0x0'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x1ab')][_0x41cf05('0x1c')](db[_0x41cf05('0x113')],{'as':'Subjects','onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x1ab')][_0x41cf05('0x1c')](db[_0x41cf05('0x113')],{'as':_0x41cf05('0x1af'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x1ab')][_0x41cf05('0x1c')](db[_0x41cf05('0x113')],{'as':'Fields','onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1cb')}),db['ZohoConfiguration'][_0x41cf05('0x114')](db['ZohoAccount'],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x113')][_0x41cf05('0x1c')](db[_0x41cf05('0x113')],{'as':_0x41cf05('0x1ef'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x113')][_0x41cf05('0x1c')](db[_0x41cf05('0x113')],{'as':_0x41cf05('0xc7'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x113')][_0x41cf05('0x1c')](db[_0x41cf05('0x113')],{'as':'Field','foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x113')][_0x41cf05('0x114')](db['Variable'],{'as':_0x41cf05('0xd0'),'foreignKey':_0x41cf05('0x2')}),db[_0x41cf05('0x19d')][_0x41cf05('0x1c')](db[_0x41cf05('0xce')],{'as':'Configurations','onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1d0')}),db['ZendeskConfiguration'][_0x41cf05('0x1c')](db[_0x41cf05('0x1ca')],{'as':_0x41cf05('0x105'),'foreignKey':'SubjectId'}),db[_0x41cf05('0xce')][_0x41cf05('0x1c')](db[_0x41cf05('0x1ca')],{'as':'Descriptions','foreignKey':'DescriptionId'}),db[_0x41cf05('0xce')][_0x41cf05('0x1c')](db[_0x41cf05('0x1ca')],{'as':_0x41cf05('0x1d9'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0xce')]['belongsTo'](db[_0x41cf05('0x19d')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x1d0')}),db['ZendeskConfiguration'][_0x41cf05('0x97')](db[_0x41cf05('0x7a')],{'through':_0x41cf05('0xd1')}),db[_0x41cf05('0x1ca')]['hasMany'](db['ZendeskField'],{'as':_0x41cf05('0x1ef'),'foreignKey':'SubjectId'}),db['ZendeskField'][_0x41cf05('0x1c')](db[_0x41cf05('0x1ca')],{'as':_0x41cf05('0xc7'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x1ca')][_0x41cf05('0x1c')](db[_0x41cf05('0x1ca')],{'as':_0x41cf05('0x1b'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x1ca')][_0x41cf05('0x114')](db[_0x41cf05('0xd0')],{'as':'Variable','foreignKey':_0x41cf05('0x2')}),db[_0x41cf05('0xc9')][_0x41cf05('0x1c')](db[_0x41cf05('0x179')],{'as':'Configurations','onDelete':'cascade','foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x179')][_0x41cf05('0x1c')](db[_0x41cf05('0x7')],{'as':_0x41cf05('0x105'),'onDelete':'cascade','foreignKey':'SubjectId'}),db['FreshdeskConfiguration'][_0x41cf05('0x1c')](db[_0x41cf05('0x7')],{'as':_0x41cf05('0x1af'),'onDelete':_0x41cf05('0x166'),'foreignKey':'DescriptionId'}),db[_0x41cf05('0x179')]['hasMany'](db['FreshdeskField'],{'as':_0x41cf05('0x1d9'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x179')][_0x41cf05('0x114')](db[_0x41cf05('0xc9')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x1d0')}),db['FreshdeskConfiguration'][_0x41cf05('0x97')](db['Tag'],{'through':'int_freshdesk_configuration_has_tags'}),db[_0x41cf05('0x7')][_0x41cf05('0x1c')](db[_0x41cf05('0x7')],{'as':_0x41cf05('0x1ef'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x7')][_0x41cf05('0x1c')](db[_0x41cf05('0x7')],{'as':_0x41cf05('0xc7'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x7')]['hasMany'](db[_0x41cf05('0x7')],{'as':_0x41cf05('0x1b'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x7')][_0x41cf05('0x114')](db[_0x41cf05('0xd0')],{'as':_0x41cf05('0xd0'),'foreignKey':'VariableId'}),db[_0x41cf05('0xc5')][_0x41cf05('0x1c')](db[_0x41cf05('0x188')],{'as':_0x41cf05('0x0'),'onDelete':'cascade','foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x188')][_0x41cf05('0x1c')](db[_0x41cf05('0x142')],{'as':_0x41cf05('0x105'),'foreignKey':_0x41cf05('0x16b')}),db['VtigerConfiguration'][_0x41cf05('0x1c')](db[_0x41cf05('0x142')],{'as':_0x41cf05('0x1af'),'foreignKey':_0x41cf05('0xd5')}),db['VtigerConfiguration'][_0x41cf05('0x1c')](db[_0x41cf05('0x142')],{'as':'Fields','foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x188')][_0x41cf05('0x114')](db['VtigerAccount'],{'as':_0x41cf05('0xe3'),'foreignKey':'AccountId'}),db[_0x41cf05('0x142')][_0x41cf05('0x1c')](db[_0x41cf05('0x142')],{'as':'Subject','foreignKey':'SubjectId'}),db[_0x41cf05('0x142')][_0x41cf05('0x1c')](db[_0x41cf05('0x142')],{'as':_0x41cf05('0xc7'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x142')][_0x41cf05('0x1c')](db['VtigerField'],{'as':_0x41cf05('0x1b'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x142')][_0x41cf05('0x114')](db['Variable'],{'as':'Variable','foreignKey':'VariableId'}),db['ServicenowAccount'][_0x41cf05('0x1c')](db[_0x41cf05('0x162')],{'as':_0x41cf05('0x0'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x162')]['hasMany'](db[_0x41cf05('0x129')],{'as':_0x41cf05('0x105'),'foreignKey':_0x41cf05('0x16b')}),db['ServicenowConfiguration'][_0x41cf05('0x1c')](db[_0x41cf05('0x129')],{'as':_0x41cf05('0x1af'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x162')][_0x41cf05('0x1c')](db['ServicenowField'],{'as':_0x41cf05('0x1d9'),'foreignKey':_0x41cf05('0x1cb')}),db['ServicenowConfiguration'][_0x41cf05('0x114')](db[_0x41cf05('0x1f1')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x129')][_0x41cf05('0x1c')](db['ServicenowField'],{'as':_0x41cf05('0x1ef'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x129')][_0x41cf05('0x1c')](db['ServicenowField'],{'as':_0x41cf05('0xc7'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x129')][_0x41cf05('0x1c')](db[_0x41cf05('0x129')],{'as':_0x41cf05('0x1b'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x129')][_0x41cf05('0x114')](db[_0x41cf05('0xd0')],{'as':_0x41cf05('0xd0'),'foreignKey':_0x41cf05('0x2')}),db['Dynamics365Account'][_0x41cf05('0x1c')](db[_0x41cf05('0x1df')],{'as':_0x41cf05('0x0'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1d0')}),db['Dynamics365Configuration'][_0x41cf05('0x1c')](db['Dynamics365Field'],{'as':_0x41cf05('0x105'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x1df')][_0x41cf05('0x1c')](db[_0x41cf05('0x1e8')],{'as':_0x41cf05('0x1af'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x1df')]['hasMany'](db[_0x41cf05('0x1e8')],{'as':_0x41cf05('0x1d9'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x1cb')}),db['Dynamics365Configuration'][_0x41cf05('0x114')](db[_0x41cf05('0x5c')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0x1e8')][_0x41cf05('0x1c')](db[_0x41cf05('0x1e8')],{'as':'Subject','foreignKey':_0x41cf05('0x16b')}),db['Dynamics365Field']['hasMany'](db[_0x41cf05('0x1e8')],{'as':_0x41cf05('0xc7'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x1e8')][_0x41cf05('0x1c')](db['Dynamics365Field'],{'as':_0x41cf05('0x1b'),'foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x1e8')][_0x41cf05('0x114')](db[_0x41cf05('0xd0')],{'as':'Variable','foreignKey':_0x41cf05('0x2')}),db[_0x41cf05('0xa')][_0x41cf05('0x1c')](db[_0x41cf05('0x9d')],{'as':_0x41cf05('0x0'),'onDelete':_0x41cf05('0x166'),'foreignKey':'AccountId'}),db[_0x41cf05('0x9d')][_0x41cf05('0x1c')](db[_0x41cf05('0xb1')],{'as':_0x41cf05('0x105'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0x9d')][_0x41cf05('0x1c')](db[_0x41cf05('0xb1')],{'as':_0x41cf05('0x1af'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0x9d')]['hasMany'](db[_0x41cf05('0xb1')],{'as':'Fields','foreignKey':_0x41cf05('0x1cb')}),db[_0x41cf05('0x9d')]['belongsTo'](db[_0x41cf05('0xa')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0x1d0')}),db[_0x41cf05('0xb1')]['hasMany'](db[_0x41cf05('0xb1')],{'as':_0x41cf05('0x1ef'),'foreignKey':_0x41cf05('0x16b')}),db[_0x41cf05('0xb1')][_0x41cf05('0x1c')](db[_0x41cf05('0xb1')],{'as':_0x41cf05('0xc7'),'foreignKey':_0x41cf05('0xd5')}),db[_0x41cf05('0xb1')][_0x41cf05('0x1c')](db[_0x41cf05('0xb1')],{'as':_0x41cf05('0x1b'),'foreignKey':_0x41cf05('0x1cb')}),db['FreshsalesField'][_0x41cf05('0x114')](db[_0x41cf05('0xd0')],{'as':_0x41cf05('0xd0'),'foreignKey':_0x41cf05('0x2')}),db[_0x41cf05('0x170')]['belongsTo'](db['ChatWebsite'],{}),db[_0x41cf05('0x170')][_0x41cf05('0x114')](db[_0x41cf05('0xbb')],{'as':'List','foreignKey':_0x41cf05('0x133')}),db['ChatQueueReport'][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'as':_0x41cf05('0xed'),'foreignKey':'ContactId'}),db[_0x41cf05('0x170')][_0x41cf05('0x114')](db['ChatInteraction'],{}),db[_0x41cf05('0x170')][_0x41cf05('0x114')](db[_0x41cf05('0xb3')],{}),db[_0x41cf05('0x170')][_0x41cf05('0x114')](db['User'],{}),db[_0x41cf05('0x170')][_0x41cf05('0x114')](db[_0x41cf05('0x86')],{}),db[_0x41cf05('0xdb')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'onDelete':'cascade','foreignKey':_0x41cf05('0x5e')}),db[_0x41cf05('0xdb')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x4e')}),db['JscriptySessionReport'][_0x41cf05('0x1c')](db[_0x41cf05('0x53')],{'foreignKey':_0x41cf05('0x50'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x1b4')][_0x41cf05('0x1c')](db[_0x41cf05('0x13b')],{'foreignKey':'SessionId','onDelete':'cascade'}),db['SmsQueueReport'][_0x41cf05('0x114')](db[_0x41cf05('0xe2')],{}),db['SmsQueueReport']['belongsTo'](db[_0x41cf05('0xbb')],{'as':'List','foreignKey':_0x41cf05('0x133')}),db[_0x41cf05('0x1bc')][_0x41cf05('0x114')](db['CmContact'],{'as':_0x41cf05('0xed'),'foreignKey':_0x41cf05('0xb2')}),db[_0x41cf05('0x1bc')][_0x41cf05('0x114')](db[_0x41cf05('0x1c3')],{}),db['SmsQueueReport']['belongsTo'](db[_0x41cf05('0xa3')],{}),db[_0x41cf05('0x1bc')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{}),db[_0x41cf05('0x1bc')][_0x41cf05('0x114')](db[_0x41cf05('0x1aa')],{}),db[_0x41cf05('0x11e')][_0x41cf05('0x1c')](db['JscriptySessionReport'],{'foreignKey':_0x41cf05('0x1ba')}),db['JscriptyProject'][_0x41cf05('0x1c')](db[_0x41cf05('0x53')],{'foreignKey':'ProjectId'}),db[_0x41cf05('0x11e')]['hasMany'](db[_0x41cf05('0x13b')],{'foreignKey':_0x41cf05('0x1ba')}),db['SquareProject'][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x98'),'through':_0x41cf05('0x1d7')}),db['Team']['belongsToMany'](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xa4'),'through':'user_has_teams'}),db[_0x41cf05('0x1d6')][_0x41cf05('0x97')](db['VoiceQueue'],{'through':_0x41cf05('0x79'),'as':'VoiceQueues'}),db[_0x41cf05('0x1d6')]['belongsToMany'](db[_0x41cf05('0x83')],{'through':'team_has_mail_queues','as':_0x41cf05('0x111')}),db['Team'][_0x41cf05('0x97')](db['ChatQueue'],{'through':_0x41cf05('0x65'),'as':'ChatQueues'}),db[_0x41cf05('0x1d6')][_0x41cf05('0x97')](db[_0x41cf05('0xa0')],{'through':_0x41cf05('0x15d'),'as':'FaxQueues'}),db[_0x41cf05('0x1d6')][_0x41cf05('0x97')](db[_0x41cf05('0x1aa')],{'through':_0x41cf05('0xe6'),'as':'SmsQueues'}),db[_0x41cf05('0x1d6')][_0x41cf05('0x97')](db['OpenchannelQueue'],{'through':_0x41cf05('0x1e'),'as':_0x41cf05('0x4')}),db[_0x41cf05('0x1d6')][_0x41cf05('0x97')](db[_0x41cf05('0x18b')],{'through':_0x41cf05('0xe'),'as':'WhatsappQueues'}),db[_0x41cf05('0x100')][_0x41cf05('0x1c')](db[_0x41cf05('0x197')],{'as':_0x41cf05('0x18a'),'foreignKey':'CampaignId'}),db[_0x41cf05('0x100')][_0x41cf05('0x1c')](db[_0x41cf05('0x10b')],{'as':'HopperFinals','foreignKey':_0x41cf05('0x11')}),db['Campaign'][_0x41cf05('0x1c')](db[_0x41cf05('0x161')],{'as':_0x41cf05('0x1cf'),'foreignKey':_0x41cf05('0x11')}),db['Campaign'][_0x41cf05('0x1c')](db[_0x41cf05('0xba')],{'as':'HopperBlacks','foreignKey':_0x41cf05('0x11')}),db[_0x41cf05('0x100')][_0x41cf05('0x114')](db[_0x41cf05('0x10')],{'as':'Trunk','foreignKey':_0x41cf05('0x184')}),db[_0x41cf05('0x100')][_0x41cf05('0x114')](db[_0x41cf05('0x10')],{'as':_0x41cf05('0x108'),'foreignKey':'TrunkBackupId'}),db[_0x41cf05('0x100')][_0x41cf05('0x114')](db[_0x41cf05('0x8c')],{'as':_0x41cf05('0x8c'),'foreignKey':_0x41cf05('0x15c')}),db[_0x41cf05('0x100')][_0x41cf05('0x114')](db[_0x41cf05('0x63')],{'as':_0x41cf05('0x63'),'foreignKey':_0x41cf05('0xb6')}),db[_0x41cf05('0x100')][_0x41cf05('0x97')](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0x54'),'through':_0x41cf05('0x14')}),db[_0x41cf05('0x100')][_0x41cf05('0x97')](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0x1bb'),'through':_0x41cf05('0x60')}),db[_0x41cf05('0x1e5')]['belongsTo'](db[_0x41cf05('0xc6')],{}),db[_0x41cf05('0x1e5')][_0x41cf05('0x114')](db['MailInteraction'],{}),db[_0x41cf05('0x1e5')]['belongsTo'](db[_0x41cf05('0x8f')],{'foreignKey':_0x41cf05('0xfe'),'as':'FromAccount'}),db[_0x41cf05('0x1e5')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'foreignKey':'FromUserId','as':_0x41cf05('0xcb')}),db[_0x41cf05('0x1e5')][_0x41cf05('0x114')](db['User'],{'foreignKey':_0x41cf05('0x120'),'as':'ToAgent'}),db[_0x41cf05('0x1e5')][_0x41cf05('0x114')](db[_0x41cf05('0x83')],{'foreignKey':_0x41cf05('0x1e6'),'as':_0x41cf05('0x9')}),db[_0x41cf05('0x1e5')][_0x41cf05('0x114')](db[_0x41cf05('0x8f')],{'foreignKey':_0x41cf05('0x1ce'),'as':_0x41cf05('0x12b')}),db[_0x41cf05('0xd6')]['belongsTo'](db['ChatMessage'],{}),db[_0x41cf05('0xd6')][_0x41cf05('0x114')](db[_0x41cf05('0xe5')],{}),db[_0x41cf05('0xd6')][_0x41cf05('0x114')](db['ChatWebsite'],{'foreignKey':_0x41cf05('0x90'),'as':'FromAccount'}),db['ChatTransferReport'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'foreignKey':'FromUserId','as':_0x41cf05('0xcb')}),db[_0x41cf05('0xd6')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'foreignKey':_0x41cf05('0x120'),'as':_0x41cf05('0x4d')}),db[_0x41cf05('0xd6')][_0x41cf05('0x114')](db[_0x41cf05('0x86')],{'foreignKey':_0x41cf05('0x19e'),'as':'ToQueue'}),db[_0x41cf05('0xd6')][_0x41cf05('0x114')](db['ChatWebsite'],{'foreignKey':_0x41cf05('0x102'),'as':_0x41cf05('0x12b')}),db[_0x41cf05('0x1e4')]['belongsTo'](db[_0x41cf05('0x76')],{}),db['FaxTransferReport']['belongsTo'](db[_0x41cf05('0x134')],{}),db[_0x41cf05('0x1e4')]['belongsTo'](db[_0x41cf05('0x191')],{'foreignKey':_0x41cf05('0xf5'),'as':'FromAccount'}),db['FaxTransferReport'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'foreignKey':_0x41cf05('0x193'),'as':_0x41cf05('0xcb')}),db[_0x41cf05('0x1e4')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'foreignKey':'ToUserId','as':_0x41cf05('0x4d')}),db['FaxTransferReport'][_0x41cf05('0x114')](db[_0x41cf05('0xa0')],{'foreignKey':_0x41cf05('0x8b'),'as':_0x41cf05('0x9')}),db[_0x41cf05('0x1e4')][_0x41cf05('0x114')](db[_0x41cf05('0x191')],{'foreignKey':_0x41cf05('0x16f'),'as':_0x41cf05('0x12b')}),db[_0x41cf05('0x5a')][_0x41cf05('0x114')](db[_0x41cf05('0x58')],{}),db[_0x41cf05('0x5a')][_0x41cf05('0x114')](db[_0x41cf05('0xe9')],{}),db[_0x41cf05('0x5a')][_0x41cf05('0x114')](db[_0x41cf05('0x146')],{'foreignKey':_0x41cf05('0x1a8'),'as':'FromAccount'}),db['OpenchannelTransferReport'][_0x41cf05('0x114')](db['User'],{'foreignKey':'FromUserId','as':_0x41cf05('0xcb')}),db[_0x41cf05('0x5a')][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'foreignKey':_0x41cf05('0x120'),'as':'ToAgent'}),db['OpenchannelTransferReport'][_0x41cf05('0x114')](db[_0x41cf05('0x33')],{'foreignKey':_0x41cf05('0x126'),'as':_0x41cf05('0x9')}),db[_0x41cf05('0x5a')][_0x41cf05('0x114')](db[_0x41cf05('0x146')],{'foreignKey':_0x41cf05('0x16d'),'as':_0x41cf05('0x12b')}),db[_0x41cf05('0x6a')][_0x41cf05('0x114')](db[_0x41cf05('0xa3')],{}),db[_0x41cf05('0x6a')]['belongsTo'](db['SmsInteraction'],{}),db[_0x41cf05('0x6a')]['belongsTo'](db['SmsAccount'],{'foreignKey':_0x41cf05('0x1ac'),'as':_0x41cf05('0x1a4')}),db[_0x41cf05('0x6a')]['belongsTo'](db[_0x41cf05('0xf2')],{'foreignKey':'FromUserId','as':_0x41cf05('0xcb')}),db['SmsTransferReport'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'foreignKey':_0x41cf05('0x120'),'as':_0x41cf05('0x4d')}),db['SmsTransferReport']['belongsTo'](db[_0x41cf05('0x1aa')],{'foreignKey':'ToSmsQueueId','as':_0x41cf05('0x9')}),db[_0x41cf05('0x6a')][_0x41cf05('0x114')](db[_0x41cf05('0xe2')],{'foreignKey':_0x41cf05('0x30'),'as':_0x41cf05('0x12b')}),db[_0x41cf05('0xbb')][_0x41cf05('0x1c')](db[_0x41cf05('0x15f')],{'as':_0x41cf05('0x42'),'foreignKey':'ListId'}),db[_0x41cf05('0xbb')][_0x41cf05('0x1c')](db[_0x41cf05('0x37')],{'as':_0x41cf05('0x55'),'foreignKey':'ListId'}),db[_0x41cf05('0xbb')][_0x41cf05('0x1c')](db[_0x41cf05('0x45')],{'as':_0x41cf05('0x13a'),'onDelete':_0x41cf05('0x166'),'foreignKey':_0x41cf05('0x133')}),db['CmList'][_0x41cf05('0x1c')](db['CmHopperFinal'],{'as':_0x41cf05('0x89'),'foreignKey':_0x41cf05('0x133')}),db['CmList'][_0x41cf05('0x1c')](db[_0x41cf05('0x161')],{'as':'HopperHistory','foreignKey':'ListId'}),db['CmList'][_0x41cf05('0x1c')](db['ReportAgentPreview'],{'as':_0x41cf05('0xda'),'foreignKey':_0x41cf05('0x133')}),db['CmList'][_0x41cf05('0x97')](db[_0x41cf05('0xfd')],{'as':_0x41cf05('0x6b'),'through':_0x41cf05('0xf0')}),db[_0x41cf05('0xbb')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xa4'),'through':_0x41cf05('0x1d5')}),db['VoicePrefix'][_0x41cf05('0x1c')](db[_0x41cf05('0x156')],{'as':_0x41cf05('0x190'),'onDelete':_0x41cf05('0x166')}),db[_0x41cf05('0x172')]['belongsToMany'](db[_0x41cf05('0xf2')],{'as':'Agents','through':_0x41cf05('0x6f')}),db[_0x41cf05('0x187')][_0x41cf05('0x1c')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x98'),'foreignKey':'userProfileId','onDelete':'restrict'}),db[_0x41cf05('0x187')][_0x41cf05('0x1c')](db[_0x41cf05('0x17c')],{'as':_0x41cf05('0x110'),'foreignKey':_0x41cf05('0xbe'),'onDelete':'cascade'}),db['UserProfileSection'][_0x41cf05('0x1c')](db[_0x41cf05('0x165')],{'as':_0x41cf05('0x39'),'foreignKey':_0x41cf05('0x19a'),'onDelete':'cascade'}),db[_0x41cf05('0x159')][_0x41cf05('0x1c')](db[_0x41cf05('0x15f')],{'as':_0x41cf05('0x42'),'foreignKey':_0x41cf05('0xaa')}),db['WhatsappAccount'][_0x41cf05('0x1c')](db[_0x41cf05('0x81')],{'as':_0x41cf05('0x14e'),'foreignKey':_0x41cf05('0xaa')}),db['WhatsappAccount'][_0x41cf05('0x1c')](db[_0x41cf05('0xb')],{'as':'Messages','foreignKey':_0x41cf05('0xaa')}),db[_0x41cf05('0x159')][_0x41cf05('0x1c')](db[_0x41cf05('0xc8')],{'as':'Interactions'}),db[_0x41cf05('0x159')]['hasMany'](db[_0x41cf05('0x1cd')],{'as':'Applications'}),db[_0x41cf05('0x159')][_0x41cf05('0x114')](db[_0x41cf05('0xbb')],{'as':_0x41cf05('0xb8'),'foreignKey':_0x41cf05('0x133')}),db['WhatsappAccount'][_0x41cf05('0x114')](db[_0x41cf05('0x17f')],{'as':_0x41cf05('0x95'),'foreignKey':_0x41cf05('0x130')}),db[_0x41cf05('0x159')]['belongsToMany'](db[_0x41cf05('0xf2')],{'as':'Agents','through':_0x41cf05('0x163')}),db['WhatsappApplication']['belongsTo'](db[_0x41cf05('0xf2')],{'onDelete':'restrict'}),db[_0x41cf05('0x1cd')][_0x41cf05('0x114')](db[_0x41cf05('0x18b')],{'onDelete':_0x41cf05('0x14a')}),db[_0x41cf05('0x1cd')][_0x41cf05('0x114')](db['WhatsappAccount'],{'onDelete':'restrict'}),db[_0x41cf05('0x1cd')][_0x41cf05('0x114')](db[_0x41cf05('0x8c')],{'onDelete':'restrict','foreignKey':'IntervalId'}),db[_0x41cf05('0x1cd')][_0x41cf05('0x114')](db[_0x41cf05('0x7a')],{'onDelete':_0x41cf05('0x14a'),'foreignKey':_0x41cf05('0x7b')}),db[_0x41cf05('0xc8')][_0x41cf05('0x1c')](db['WhatsappMessage'],{'as':_0x41cf05('0x1c7'),'onDelete':'cascade','foreignKey':_0x41cf05('0x2e')}),db[_0x41cf05('0xc8')][_0x41cf05('0x114')](db['WhatsappAccount'],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0xaa')}),db[_0x41cf05('0xc8')]['belongsTo'](db[_0x41cf05('0x45')],{'as':_0x41cf05('0xed'),'foreignKey':_0x41cf05('0xb2')}),db['WhatsappInteraction'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xf8'),'foreignKey':'UserId'}),db[_0x41cf05('0xc8')][_0x41cf05('0x97')](db[_0x41cf05('0x7a')],{'through':'whatsapp_interaction_has_tags','as':_0x41cf05('0x22')}),db[_0x41cf05('0xc8')][_0x41cf05('0x97')](db['Tag'],{'through':_0x41cf05('0xb0'),'as':_0x41cf05('0x4b')}),db[_0x41cf05('0xc8')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0x98'),'through':_0x41cf05('0x8d'),'foreignKey':_0x41cf05('0x2e')}),db[_0x41cf05('0xb')]['belongsTo'](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xf2')}),db[_0x41cf05('0xb')][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'onDelete':_0x41cf05('0x166'),'as':_0x41cf05('0xed')}),db[_0x41cf05('0xb')]['belongsTo'](db[_0x41cf05('0xc8')],{'onDelete':'cascade','as':'Interaction','foreignKey':_0x41cf05('0x2e')}),db[_0x41cf05('0xb')]['belongsTo'](db[_0x41cf05('0x159')],{'as':_0x41cf05('0xe3'),'foreignKey':_0x41cf05('0xaa')}),db[_0x41cf05('0x1de')][_0x41cf05('0x114')](db['WhatsappAccount'],{}),db['WhatsappQueueReport'][_0x41cf05('0x114')](db[_0x41cf05('0xbb')],{'as':'List','foreignKey':_0x41cf05('0x133')}),db[_0x41cf05('0x1de')][_0x41cf05('0x114')](db[_0x41cf05('0x45')],{'as':_0x41cf05('0xed'),'foreignKey':'ContactId'}),db[_0x41cf05('0x1de')]['belongsTo'](db[_0x41cf05('0xc8')],{}),db[_0x41cf05('0x1de')][_0x41cf05('0x114')](db[_0x41cf05('0x18b')],{}),db['WhatsappQueueReport'][_0x41cf05('0x114')](db[_0x41cf05('0xb')],{}),db[_0x41cf05('0x1de')]['belongsTo'](db[_0x41cf05('0xf2')],{}),db[_0x41cf05('0x157')][_0x41cf05('0x114')](db[_0x41cf05('0xb')],{}),db[_0x41cf05('0x157')][_0x41cf05('0x114')](db[_0x41cf05('0xc8')],{}),db['WhatsappTransferReport']['belongsTo'](db[_0x41cf05('0x159')],{'foreignKey':_0x41cf05('0x26'),'as':'FromAccount'}),db[_0x41cf05('0x157')][_0x41cf05('0x114')](db[_0x41cf05('0x159')],{'foreignKey':_0x41cf05('0x47'),'as':_0x41cf05('0x12b')}),db['WhatsappTransferReport']['belongsTo'](db[_0x41cf05('0x18b')],{'foreignKey':_0x41cf05('0xaf'),'as':_0x41cf05('0x9')}),db['WhatsappTransferReport'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'foreignKey':_0x41cf05('0x193'),'as':'FromAgent'}),db['WhatsappTransferReport'][_0x41cf05('0x114')](db[_0x41cf05('0xf2')],{'foreignKey':_0x41cf05('0x120'),'as':'ToAgent'}),db[_0x41cf05('0x18b')][_0x41cf05('0x97')](db[_0x41cf05('0xf2')],{'as':_0x41cf05('0xa4'),'through':_0x41cf05('0x62'),'foreignKey':'WhatsappQueueId'}),db[_0x41cf05('0x18b')][_0x41cf05('0x97')](db[_0x41cf05('0x1d6')],{'through':'team_has_whatsapp_queues','as':_0x41cf05('0xec')}),module[_0x41cf05('0x8')]={'db':db,'dbH':dbH}; \ No newline at end of file diff --git a/server/rediscache/index.js b/server/rediscache/index.js index 089f246..5daaa03 100644 --- a/server/rediscache/index.js +++ b/server/rediscache/index.js @@ -1 +1 @@ -const a1023_0x1c0d=['redis','redisPort','ioredis','../config/config.service'];(function(_0x4f9f68,_0x1c0d2d){const _0x14d92e=function(_0x1ddca3){while(--_0x1ddca3){_0x4f9f68['push'](_0x4f9f68['shift']());}};_0x14d92e(++_0x1c0d2d);}(a1023_0x1c0d,0x9a));const a1023_0x14d9=function(_0x4f9f68,_0x1c0d2d){_0x4f9f68=_0x4f9f68-0x0;let _0x14d92e=a1023_0x1c0d[_0x4f9f68];return _0x14d92e;};const _0x172ed2=a1023_0x14d9,Redis=require(_0x172ed2('0x0')),socketEmitter=require('socket.io-emitter'),config=require('../config/environment'),cs=require(_0x172ed2('0x1'))['getConfigService'](),MAX_RETRIES=0xa,REDIS_CONFIG={'host':cs['redisHost'],'port':cs[_0x172ed2('0x3')],'retryStrategy':function(_0x1ddca3){if(_0x1ddca3_0x401e40[_0x477049('0x56')](/^chat_v/,''))[_0x477049('0x6b')](compareVersions)[_0x477049('0xca')]();_0x168e14=_0x87c418[0x0],_0x30af62=path[_0x477049('0x119')](_0x2563e8,_0x477049('0x2b')+_0x168e14);}}catch(_0xe6eb3){console[_0x477049('0x88')](_0x477049('0x65'),_0xe6eb3);}return{'chatVersion':_0x168e14,'chatPath':_0x30af62};}async function routes(_0x3c682d){const _0x392980=_0x27e548;_0x3c682d[_0x392980('0x95')](ewinston[_0x392980('0x99')]({'winstonInstance':logger,'meta':![],'statusLevels':!![],'msg':function(_0x41d6b4,_0x3c69a6){const _0x39a882=_0x392980;return util['format'](_0x39a882('0x132'),_0x41d6b4[_0x39a882('0xd9')],_0x41d6b4[_0x39a882('0x128')][_0x39a882('0xd')]?_0x41d6b4['headers']['x-forwarded-for']:_0x41d6b4[_0x39a882('0x133')][_0x39a882('0x51')]||_0x41d6b4['ip'],_0x41d6b4['url'],_0x3c69a6[_0x39a882('0x12')],_0x3c69a6[_0x39a882('0x8c')],_0x41d6b4[_0x39a882('0x16')]?_0x41d6b4[_0x39a882('0x16')]['id']:null,_0x41d6b4[_0x39a882('0x16')]?_0x41d6b4[_0x39a882('0x16')][_0x39a882('0x123')]:null,_0x41d6b4[_0x39a882('0x16')]?_0x41d6b4[_0x39a882('0x16')]['role']:null);}})),_0x3c682d['use'](ewinston[_0x392980('0x99')]({'winstonInstance':authLogger,'meta':![],'statusLevels':!![],'msg':function(_0x5caadd,_0x2809dd){const _0x12ff9f=_0x392980;let _0x29e97f=_0x12ff9f('0xf6');return _0x5caadd[_0x12ff9f('0x8e')]&&_0x5caadd[_0x12ff9f('0x8e')][_0x12ff9f('0xcc')]&&_0x5caadd[_0x12ff9f('0x8e')]['agent_id']&&(_0x29e97f=_0x12ff9f('0x7e')),util['format'](_0x29e97f,_0x5caadd[_0x12ff9f('0xd9')],_0x5caadd[_0x12ff9f('0x128')][_0x12ff9f('0xd')]?_0x5caadd[_0x12ff9f('0x128')][_0x12ff9f('0xd')]:_0x5caadd[_0x12ff9f('0x133')][_0x12ff9f('0x51')]||_0x5caadd['ip'],_0x5caadd[_0x12ff9f('0x13')],_0x2809dd[_0x12ff9f('0x12')],_0x2809dd[_0x12ff9f('0x8c')],_0x5caadd[_0x12ff9f('0x16')]?_0x5caadd[_0x12ff9f('0x16')]['id']:null,_0x5caadd[_0x12ff9f('0x16')]?_0x5caadd[_0x12ff9f('0x16')][_0x12ff9f('0x123')]:null,_0x5caadd[_0x12ff9f('0x16')]?_0x5caadd[_0x12ff9f('0x16')][_0x12ff9f('0x25')]:null,_0x5caadd['body']&&_0x5caadd[_0x12ff9f('0x8e')]['device']?_0x5caadd[_0x12ff9f('0x8e')][_0x12ff9f('0xcc')]:_0x12ff9f('0x135'),_0x5caadd[_0x12ff9f('0x8e')]&&_0x5caadd['body'][_0x12ff9f('0x5d')]?_0x5caadd[_0x12ff9f('0x8e')]['agent_id']:'',_0x5caadd[_0x12ff9f('0x8e')]&&_0x5caadd['body'][_0x12ff9f('0x91')]?_0x5caadd[_0x12ff9f('0x8e')][_0x12ff9f('0x91')]:'');},'ignoreRoute':function(_0x50fa04){const _0x26edc3=_0x392980,_0x4b07b9=/\/api\/users\/[0-9]+\/(login|logout)/gi;return!_0x4b07b9[_0x26edc3('0xa3')](_0x50fa04[_0x26edc3('0x13')]);}})),_0x3c682d['use'](_0x392980('0x5e'),require('./api/user')),_0x3c682d[_0x392980('0x95')](_0x392980('0x12d'),require(_0x392980('0xa'))),_0x3c682d[_0x392980('0x95')]('/api/voice/contexts',require('./api/voiceContext')),_0x3c682d[_0x392980('0x95')](_0x392980('0x114'),require('./api/voiceExtension')),_0x3c682d[_0x392980('0x95')](_0x392980('0xb5'),require('./api/voiceMusicOnHold')),_0x3c682d[_0x392980('0x95')]('/api/voice/queues',require(_0x392980('0xe9'))),_0x3c682d[_0x392980('0x95')]('/api/voice/recordings',require(_0x392980('0x137'))),_0x3c682d['use'](_0x392980('0x37'),require(_0x392980('0x30'))),_0x3c682d['use'](_0x392980('0x11f'),require(_0x392980('0x6d'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x111'),require(_0x392980('0x139'))),_0x3c682d[_0x392980('0x95')]('/api/voice/calls/reports',require(_0x392980('0x92'))),_0x3c682d[_0x392980('0x95')]('/api/voice/dials/reports',require(_0x392980('0x85'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x6'),require('./api/voiceAgentReport')),_0x3c682d['use'](_0x392980('0x102'),require(_0x392980('0xfe'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xef'),require(_0x392980('0x54'))),_0x3c682d['use'](_0x392980('0x9'),require('./api/trunk')),_0x3c682d[_0x392980('0x95')]('/api/voice/transfers/reports',require(_0x392980('0x38'))),_0x3c682d['use'](_0x392980('0x94'),require(_0x392980('0x104'))),_0x3c682d[_0x392980('0x95')]('/api/mail/accounts',require('./api/mailAccount')),_0x3c682d[_0x392980('0x95')](_0x392980('0xbd'),require(_0x392980('0x24'))),_0x3c682d['use']('/api/mail/substatuses',require(_0x392980('0xad'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x98'),require(_0x392980('0x89'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x7'),require(_0x392980('0x39'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xaf'),require(_0x392980('0xb3'))),_0x3c682d['use'](_0x392980('0x58'),require(_0x392980('0x100'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x101'),require(_0x392980('0x78'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xf2'),require(_0x392980('0x112'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xe0'),require(_0x392980('0xda'))),_0x3c682d['use'](_0x392980('0x5a'),require(_0x392980('0xc7'))),_0x3c682d['use'](_0x392980('0x9d'),require('./api/faxInteraction')),_0x3c682d[_0x392980('0x95')](_0x392980('0x1d'),require(_0x392980('0x86'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x2f'),require('./api/faxQueue')),_0x3c682d[_0x392980('0x95')](_0x392980('0x50'),require(_0x392980('0xc6'))),_0x3c682d['use']('/api/sms/accounts',require('./api/smsAccount')),_0x3c682d[_0x392980('0x95')](_0x392980('0x1b'),require(_0x392980('0xe1'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x11a'),require(_0x392980('0x29'))),_0x3c682d['use'](_0x392980('0x96'),require(_0x392980('0x34'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xc8'),require('./api/smsQueue')),_0x3c682d[_0x392980('0x95')](_0x392980('0xcf'),require(_0x392980('0x9a'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xeb'),require(_0x392980('0x14'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x1'),require(_0x392980('0x3c'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xb7'),require(_0x392980('0x4d'))),_0x3c682d['use'](_0x392980('0xfa'),require(_0x392980('0xd5'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x118'),require(_0x392980('0x74'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x83'),require(_0x392980('0x125'))),_0x3c682d['use'](_0x392980('0x0'),require(_0x392980('0x60'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x9f'),require(_0x392980('0x10b'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x12f'),require(_0x392980('0xcb'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xe3'),require('./api/chatOfflineMessage')),_0x3c682d['use'](_0x392980('0xdb'),require('./api/chatQueue')),_0x3c682d['use'](_0x392980('0xc5'),require(_0x392980('0xdd'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xa4'),require(_0x392980('0x42'))),_0x3c682d['use'](_0x392980('0x3d'),require('./api/cmCompany')),_0x3c682d[_0x392980('0x95')](_0x392980('0x68'),require(_0x392980('0x63'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xed'),require(_0x392980('0x7d'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xa5'),require(_0x392980('0xf8'))),_0x3c682d['use'](_0x392980('0xe6'),require(_0x392980('0xc4'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x4a'),require(_0x392980('0x52'))),_0x3c682d['use'](_0x392980('0x77'),require(_0x392980('0x59'))),_0x3c682d['use'](_0x392980('0xd8'),require(_0x392980('0x79'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xf4'),require(_0x392980('0xa2'))),_0x3c682d['use'](_0x392980('0x82'),require(_0x392980('0x12a'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x61'),require('./api/disposition')),_0x3c682d['use'](_0x392980('0x2'),require('./api/condition')),_0x3c682d[_0x392980('0x95')](_0x392980('0x45'),require(_0x392980('0x8d'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x4f'),require(_0x392980('0x110'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x5b'),require('./api/cdr')),_0x3c682d[_0x392980('0x95')](_0x392980('0x22'),require(_0x392980('0x97'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xab'),require(_0x392980('0x5'))),_0x3c682d['use'](_0x392980('0xac'),require(_0x392980('0xb'))),_0x3c682d['use'](_0x392980('0xe4'),require(_0x392980('0x10e'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xc0'),require(_0x392980('0xd3'))),_0x3c682d['use']('/api/triggers',require(_0x392980('0xce'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x11e'),require(_0x392980('0x115'))),_0x3c682d[_0x392980('0x95')]('/api/integrations',require(_0x392980('0xa1'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xd2'),require(_0x392980('0x103'))),_0x3c682d['use'](_0x392980('0x2d'),require(_0x392980('0x3a'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x8f'),require(_0x392980('0x44'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xf0'),require(_0x392980('0xdc'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xc2'),require('./api/analyticMetric')),_0x3c682d[_0x392980('0x95')](_0x392980('0x1f'),require(_0x392980('0x12c'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x106'),require('./api/analyticTreeReport')),_0x3c682d[_0x392980('0x95')](_0x392980('0x69'),require(_0x392980('0xc1'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xb2'),require(_0x392980('0x62'))),_0x3c682d['use'](_0x392980('0x2a'),require('./api/intSalesforceField')),_0x3c682d[_0x392980('0x95')]('/api/integrations/sugarcrm/accounts',require(_0x392980('0x13b'))),_0x3c682d['use'](_0x392980('0xa8'),require(_0x392980('0x26'))),_0x3c682d['use'](_0x392980('0xff'),require(_0x392980('0x6c'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x46'),require('./api/intDeskAccount')),_0x3c682d['use']('/api/integrations/desk/configurations',require(_0x392980('0x40'))),_0x3c682d['use'](_0x392980('0x28'),require(_0x392980('0x11c'))),_0x3c682d['use'](_0x392980('0x10c'),require('./api/intZohoAccount')),_0x3c682d[_0x392980('0x95')](_0x392980('0x138'),require(_0x392980('0xfd'))),_0x3c682d['use']('/api/integrations/zoho/fields',require(_0x392980('0xfb'))),_0x3c682d[_0x392980('0x95')]('/api/integrations/zendesk/accounts',require(_0x392980('0x3f'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xcd'),require(_0x392980('0x120'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x122'),require(_0x392980('0x93'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xc'),require('./api/intFreshdeskAccount')),_0x3c682d[_0x392980('0x95')]('/api/integrations/freshdesk/configurations',require(_0x392980('0x9c'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xb4'),require(_0x392980('0xec'))),_0x3c682d['use']('/api/integrations/vtiger/accounts',require(_0x392980('0x18'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x105'),require(_0x392980('0x3'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x32'),require(_0x392980('0x8'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xd0'),require(_0x392980('0x75'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xa6'),require(_0x392980('0x67'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x10f'),require(_0x392980('0xbb'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xd4'),require('./api/intDynamics365Account')),_0x3c682d[_0x392980('0x95')](_0x392980('0xf7'),require(_0x392980('0x35'))),_0x3c682d[_0x392980('0x95')]('/api/integrations/dynamics365/fields',require(_0x392980('0x1a'))),_0x3c682d[_0x392980('0x95')]('/api/integrations/freshsales/accounts',require(_0x392980('0x134'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xb8'),require('./api/intFreshsalesConfiguration')),_0x3c682d[_0x392980('0x95')](_0x392980('0x41'),require('./api/intFreshsalesField')),_0x3c682d[_0x392980('0x95')](_0x392980('0xb1'),require('./api/network')),_0x3c682d['use'](_0x392980('0x4e'),require(_0x392980('0x7f'))),_0x3c682d['use'](_0x392980('0xf9'),require(_0x392980('0x13c'))),_0x3c682d[_0x392980('0x95')]('/api/jscripty/answers/reports',require('./api/jscriptyAnswerReport')),_0x3c682d['use']('/api/jscripty/questions/reports',require(_0x392980('0x109'))),_0x3c682d[_0x392980('0x95')]('/api/jscripty/sessions/reports',require(_0x392980('0x23'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x6a'),require(_0x392980('0x130'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x10'),require('./api/squareReport')),_0x3c682d[_0x392980('0x95')](_0x392980('0x4b'),require(_0x392980('0x53'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xea'),require(_0x392980('0x66'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x21'),require(_0x392980('0x3b'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x84'),require('./api/squareOdbc')),_0x3c682d[_0x392980('0x95')](_0x392980('0x3e'),require(_0x392980('0xbf'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x12b'),require(_0x392980('0xee'))),_0x3c682d[_0x392980('0x95')]('/api/square/messages',require(_0x392980('0x10d'))),_0x3c682d['use'](_0x392980('0x31'),require('./api/team')),_0x3c682d['use'](_0x392980('0xf1'),require(_0x392980('0xf'))),_0x3c682d['use'](_0x392980('0x6f'),require(_0x392980('0xa0'))),_0x3c682d[_0x392980('0x95')]('/api/migrations',require('./api/migration')),_0x3c682d[_0x392980('0x95')](_0x392980('0xde'),require(_0x392980('0xe5'))),_0x3c682d['use'](_0x392980('0xe2'),require(_0x392980('0x126'))),_0x3c682d[_0x392980('0x95')]('/api/mail/reports/transfer',require(_0x392980('0x124'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x9e'),require(_0x392980('0xaa'))),_0x3c682d['use'](_0x392980('0x70'),require(_0x392980('0x1e'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xd7'),require('./api/openchannelTransferReport')),_0x3c682d['use']('/api/sms/reports/transfer',require(_0x392980('0x76'))),_0x3c682d['use'](_0x392980('0x2e'),require('./api/cmList')),_0x3c682d['use'](_0x392980('0xc9'),require(_0x392980('0x5f'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x108'),require(_0x392980('0x71'))),_0x3c682d[_0x392980('0x95')]('/api/userProfile/sections',require(_0x392980('0xa9'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x129'),require(_0x392980('0x7b'))),_0x3c682d[_0x392980('0x95')]('/api/notifications',require('./api/notification')),_0x3c682d[_0x392980('0x95')](_0x392980('0x47'),require(_0x392980('0xae'))),_0x3c682d[_0x392980('0x95')]('/api/whatsapp/applications',require(_0x392980('0xb0'))),_0x3c682d[_0x392980('0x95')](_0x392980('0xd1'),require('./api/whatsappInteraction')),_0x3c682d[_0x392980('0x95')]('/api/whatsapp/messages',require(_0x392980('0xc3'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x131'),require(_0x392980('0xbe'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x9b'),require('./api/whatsappTransferReport')),_0x3c682d['use'](_0x392980('0xa7'),require('./api/whatsappQueue')),_0x3c682d[_0x392980('0x95')](_0x392980('0x55'),require(_0x392980('0x10a'))),_0x3c682d[_0x392980('0x95')]('/api/auth/local',require(_0x392980('0xbc'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x2c'),require(_0x392980('0x13a'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x6e'),require('./api/jira')),_0x3c682d['use'](_0x392980('0x36'),require(_0x392980('0x20'))),_0x3c682d[_0x392980('0x95')]('/api/version',require(_0x392980('0xe7'))),_0x3c682d['use'](_0x392980('0x80'),require(_0x392980('0x121'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x7c'),require(_0x392980('0x113'))),_0x3c682d['use']('/api/webbar',require(_0x392980('0x90'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x8a'),express[_0x392980('0x107')](path[_0x392980('0x33')](config[_0x392980('0x127')],'..',_0x392980('0x64')))),_0x3c682d['use'](_0x392980('0x57'),express['static'](path[_0x392980('0x33')](config[_0x392980('0x127')],'..',_0x392980('0x15')))),_0x3c682d['use'](_0x392980('0x19'),express[_0x392980('0x107')](path[_0x392980('0x33')](config[_0x392980('0x127')],'..','demo'))),_0x3c682d[_0x392980('0x95')](_0x392980('0x116'),express[_0x392980('0x107')](path['resolve'](config[_0x392980('0x127')],_0x392980('0xb9'))));const {chatPath:_0x573c1b,chatVersion:_0x2e82cd}=await getInstalledChatVersion(),_0x56ef6e=getConfigService();!(_0x56ef6e[_0x392980('0x27')]||_0x56ef6e['isTest'])&&console['log'](_0x392980('0x136'),_0x573c1b,_0x2e82cd),_0x573c1b&&_0x2e82cd&&(_0x3c682d[_0x392980('0x17')](_0x392980('0x5c'),_0x2e82cd),_0x3c682d[_0x392980('0x95')](_0x392980('0x11b'),express[_0x392980('0x107')](_0x573c1b))),_0x3c682d[_0x392980('0x81')]('/:url(api|auth|components|app|bower_components|assets)/*')[_0x392980('0xdf')](errors[0x194]),_0x3c682d[_0x392980('0xdf')]('*',function(_0x309abb,_0xb98d40){const _0x1fdcfa=_0x392980;_0xb98d40[_0x1fdcfa('0x12e')](path[_0x1fdcfa('0x33')](_0x3c682d['get'](_0x1fdcfa('0x7a'))+_0x1fdcfa('0xe')));});}exports[_0x27e548('0xba')]=routes; \ No newline at end of file +const a1024_0x41ca=['./api/cloudProvider','/snippet','./api/version','/api/square/projects','static','set','/apidoc','/api/integrations/reports','./api/cdr','map','/api/openchannel/messages','./api/variable','./api/authLocal','chatPath,\x20chatVersion','/api/openchannel/reports/queue','./api/openchannelMessage','/api/integrations/sugarcrm/configurations','/api/sounds','/api/whatsapp/interactions','responseTime','/api/chat/reports/transfer','/api/variables','./api/mailAccount','/api/integrations/salesforce/accounts','/api/integrations/freshdesk/accounts','/api/voice/dials/reports','./api/intFreshdeskField','/api/square/recordings','dist','./api/automation','./api/openchannelQueueReport','./api/intZohoField','./api/whatsappInteraction','./api/intZohoAccount','./api/intFreshsalesField','./api/whatsappMessage','/api/analytics/extracted_reports','/api/fax/applications','/api/sms/interactions','./api/chatInternalMessage','/api/mail/reports/queue','./api/faxQueueReport','./api/jira','./api/userProfileResource','./api/intZendeskField','util','./api/faxApplication','/api/sms/reports/transfer','./api/voiceRecording','./api/mailQueueReport','./api/screenRecording','./api/trunk','./api/voiceAgentReport','./api/disposition','./api/analyticFieldReport','./api/integration','/api/voice/contexts','/api/voice/queues','path','/api/mail/accounts','/api/mail/reports/transfer','./config/logger','auth','/api/integrations/sugarcrm/accounts','express','/api/teams','/api/settings','user','url','/api/analytics/default_reports','/api/openchannel/applications','chatVersion','./api/whatsappApplication','./api/intSugarcrmAccount','./api/voicePrefix','/api/cm/hopper','./api/openchannelTransferReport','/api/integrations/freshsales/configurations','./api/rpc','./api/intServicenowConfiguration','./api/chatMessage','./api/migration','name','device','./api/intFreshdeskConfiguration','/api/whatsapp/applications','./api/action','./api/openchannelApplication','/api/square/messages','./api/intDeskField','/api/whatsapp/reports/transfer','/api/system','environment','/api/chat/interactions','./api/whatsappQueueReport','version','./api/mailMessage','./api/authGoogle','./api/analyticMetric','package.json','./api/mailApplication','No\x20chat\x20module\x20found\x20at\x20','/api/cm/hopper_final','/api/sms/queues','/www','/api/cdr','./api/mailTransferReport','agent_id','./api/sound','%s\x20%s\x20%s\x20%s\x20%sms\x20id=%s\x20name=%s\x20role=%s','./api/openchannelQueue','/api/conditions','./api/squareReport','remoteAddress','./api/user','connection','/api/dashboards/items','./api/jscriptySessionReport','/api/jscripty/sessions/reports','./api/intZendeskConfiguration','./api/jscriptyQuestionReport','x-forwarded-for','join','/api/mail/substatuses','./api/voiceChanSpy','./api/webbar','warn','./api/intVtigerAccount','headers','./api/userProfile','/api/voice/queues/reports','/api/integrations/freshdesk/configurations','/api/cloudProviders','./api/voiceExtension','./api/voiceMusicOnHold','./api/intSalesforceConfiguration','/api/voice/mohs','includes','/api/analytics/metrics','/api/voice/chanspy','./api/mailInteraction','method','./api/cmList','/api/networks','/api/integrations/freshsales/accounts','./api/faxTransferReport','./api/notification','/api/chat/proactive_actions','./api/interval','/api/whatsapp/queues','getInstalledChatVersion','./api/intZohoConfiguration','./api/condition','./api/intDynamics365Configuration','/api/cm/contacts','/api/automations','readdir','appPath','./api/cmCustomField','./api/smsAccount','./api/intDeskConfiguration','/api/cm/hopper_history','./api/pause','./config/config.service','sendFile','%s\x20%s\x20%s\x20%s\x20%sms\x20id=%s\x20name=%s\x20role=%s\x20device=%s\x20(id=%s\x20name=%s)','./api/whatsappAccount','./api/chatTransferReport','./api/intVtigerConfiguration','/api/openchannel/queues','./api/jscriptyProject','./api/intServicenowAccount','./api/template','/api/jscripty/projects','./api/chatApplication','./api/voiceQueue','./api/cmHopperHistory','./api/memberReport','./api/mailSubstatus','./api/intFreshsalesAccount','/api/integrations/zendesk/accounts','sort','./api/intFreshsalesConfiguration','./api/userProfileSection','./api/voiceQueuesLog','/api/canned_answers','/api/templates','/api/voice/recordings','/api/triggers','./api/analyticTreeReport','/:url(api|auth|components|app|bower_components|assets)/*','/api/fax/interactions','/api/userProfiles','/api/notifications','/api/integrations/desk/configurations','/api/chat/groups','/api/chat/applications','/api/integrations/salesforce/configurations','/api/chat/reports/queue','./api/intDynamics365Account','/api/integrations/salesforce/fields','isProduction','./api/intFreshdeskAccount','/api/integrations/zendesk/fields','/api/schedules','files/plugins','Unable\x20to\x20solve\x20chat\x20version','/api/intervals','./api/voiceDialReport','error','/plugins','/api/chat/internal/messages','/api/analytics/field_reports','./api/intVtigerField','/api/integrations/vtiger/fields','resolve','/api/pm2','format','/api/mail/interactions','demo','/api/whatsapp/messages','/api/screen/recordings','/api/openchannel/interactions','./api/intSugarcrmField','/api/rpc','/api/square/details/reports','parse','/api/mail/applications','agent_name','snippets','./api/intDeskAccount','./api/trigger','/api/pauses','/api/jscripty/answers/reports','./api/integrationReport','%s\x20%s\x20%s\x20%s\x20%sms\x20id=%s\x20name=%s\x20role=%s\x20device=%s','/api/version','/api/square/odbc','root','/api/fax/reports/transfer','/api/integrations/servicenow/configurations','/index.html','/api/openchannel/reports/transfer','express-winston','/api/whatsapp/accounts','/api/voice/transfers/reports','./api/chatInteraction','/api/voice/agents/reports','get','/api/voice/prefixes','replace','./api/cannedAnswer','/api/integrations/servicenow/accounts','body','./api/faxMessage','./api/voiceTransferReport','./api/intSalesforceField','./api/chatWebsite','/api/voice/extensions','/api/integrations/dynamics365/configurations','/api/integrations/dynamics365/fields','statusCode','./api/intZendeskAccount','./api/openchannelInteraction','logger','/api/integrations','/api/userProfile/resources','./api/intSugarcrmConfiguration','/api/cm/companies','/api/migrations','/api/trunks','./api/mailServerOut','./api/voiceMail','/api/integrations/zoho/fields','/api/chat/websites','./api/squareReportDetail','./api/campaign','/api/license','use','./api/chatProactiveAction','/api/users','/api/mail/out_servers','./api/jscriptyAnswerReport','/api/fax/reports/queue','promises','/api/sms/reports/queue','/api/actions','./api/faxQueue','./api/chatGroup','./api/cmCompany','./config/environment','./api/tag','role','./api/smsQueue','./api/chatQueueReport','/api/mail/messages','./api/dashboardItem','/api/userProfile/sections','./api/setting','./api/cmHopperFinal','/api/cm/lists','./api/analyticExtractedReport','/api/analytics/custom_reports','/api/voice/mails/messages','./api/chatOfflineMessage','/api/voice/calls/reports','apidoc','./api/schedule','www','/demo','/api/mail/queues','/api/whatsapp/reports/queue','/api/chat/queues','/api/plugins','./api/network','reverse','./api/system','./api/smsQueueReport','/api/integrations/freshsales/fields'];(function(_0x4e693d,_0x41ca07){const _0x26f5eb=function(_0xa93aeb){while(--_0xa93aeb){_0x4e693d['push'](_0x4e693d['shift']());}};_0x26f5eb(++_0x41ca07);}(a1024_0x41ca,0xe3));const a1024_0x26f5=function(_0x4e693d,_0x41ca07){_0x4e693d=_0x4e693d-0x0;let _0x26f5eb=a1024_0x41ca[_0x4e693d];return _0x26f5eb;};const _0x31c4fc=a1024_0x26f5;'use strict';const path=require(_0x31c4fc('0x96')),fs=require('fs'),express=require(_0x31c4fc('0x9c')),ewinston=require(_0x31c4fc('0x10')),util=require(_0x31c4fc('0x89')),errors=require('./errors'),config=require(_0x31c4fc('0x3f')),logger=require(_0x31c4fc('0x99'))('api'),authLogger=require('./config/logger')(_0x31c4fc('0x9a')),{getConfigService}=require(_0x31c4fc('0xff')),compareVersions=require('compare-versions');async function getInstalledChatVersion(){const _0x5d64cb=_0x31c4fc,_0xa93aeb=getConfigService();let _0x1b4a20='',_0x14b5c8='';try{if(!['production','build'][_0x5d64cb('0xe5')](_0xa93aeb[_0x5d64cb('0xb8')])){const _0x488316=path[_0x5d64cb('0x133')](config[_0x5d64cb('0xb')],'..','motion-chat'),_0x2827b3=fs['existsSync'](_0x488316);if(_0x2827b3)try{const _0xcfdf86=await fs[_0x5d64cb('0x39')]['readFile'](path[_0x5d64cb('0xd6')](_0x488316,_0x5d64cb('0xbf')),'utf-8'),_0x8f8db=JSON[_0x5d64cb('0x13e')](_0xcfdf86);_0x1b4a20=_0x8f8db[_0x5d64cb('0xbb')],_0x14b5c8=path[_0x5d64cb('0xd6')](_0x488316,_0x5d64cb('0x78'));}catch(_0x1ca500){console[_0x5d64cb('0x12d')](_0x5d64cb('0xf2'),_0x1ca500);}else console[_0x5d64cb('0xda')](_0x5d64cb('0xc1')+_0x488316);}else{const _0x37d187=path[_0x5d64cb('0xd6')](config['root'],'..',_0x5d64cb('0x2')),_0x2bab9c=await fs[_0x5d64cb('0x39')][_0x5d64cb('0xf8')](_0x37d187),_0x59af1c=_0x2bab9c[_0x5d64cb('0x65')](_0x343e66=>_0x343e66[_0x5d64cb('0x17')](/^chat_v/,''))[_0x5d64cb('0x111')](compareVersions)[_0x5d64cb('0x58')]();_0x1b4a20=_0x59af1c[0x0],_0x14b5c8=path[_0x5d64cb('0xd6')](_0x37d187,'chat_v'+_0x1b4a20);}}catch(_0x5871b2){console[_0x5d64cb('0x12d')](_0x5d64cb('0x12a'),_0x5871b2);}return{'chatVersion':_0x1b4a20,'chatPath':_0x14b5c8};}async function routes(_0x24ceb3){const _0x35c4d6=_0x31c4fc;_0x24ceb3[_0x35c4d6('0x33')](ewinston[_0x35c4d6('0x25')]({'winstonInstance':logger,'meta':![],'statusLevels':!![],'msg':function(_0x328f24,_0x40dec0){const _0x592145=_0x35c4d6;return util[_0x592145('0x135')](_0x592145('0xc9'),_0x328f24['method'],_0x328f24[_0x592145('0xdc')]['x-forwarded-for']?_0x328f24['headers'][_0x592145('0xd5')]:_0x328f24[_0x592145('0xcf')][_0x592145('0xcd')]||_0x328f24['ip'],_0x328f24[_0x592145('0xa0')],_0x40dec0[_0x592145('0x22')],_0x40dec0[_0x592145('0x6f')],_0x328f24[_0x592145('0x9f')]?_0x328f24[_0x592145('0x9f')]['id']:null,_0x328f24[_0x592145('0x9f')]?_0x328f24[_0x592145('0x9f')][_0x592145('0xae')]:null,_0x328f24[_0x592145('0x9f')]?_0x328f24['user']['role']:null);}})),_0x24ceb3[_0x35c4d6('0x33')](ewinston[_0x35c4d6('0x25')]({'winstonInstance':authLogger,'meta':![],'statusLevels':!![],'msg':function(_0x46f140,_0x5a9d2c){const _0x4b90ea=_0x35c4d6;let _0x18dfe0=_0x4b90ea('0x8');return _0x46f140[_0x4b90ea('0x1a')]&&_0x46f140['body'][_0x4b90ea('0xaf')]&&_0x46f140[_0x4b90ea('0x1a')]['agent_id']&&(_0x18dfe0=_0x4b90ea('0x101')),util[_0x4b90ea('0x135')](_0x18dfe0,_0x46f140[_0x4b90ea('0xe9')],_0x46f140[_0x4b90ea('0xdc')][_0x4b90ea('0xd5')]?_0x46f140[_0x4b90ea('0xdc')][_0x4b90ea('0xd5')]:_0x46f140[_0x4b90ea('0xcf')][_0x4b90ea('0xcd')]||_0x46f140['ip'],_0x46f140['url'],_0x5a9d2c[_0x4b90ea('0x22')],_0x5a9d2c['responseTime'],_0x46f140[_0x4b90ea('0x9f')]?_0x46f140[_0x4b90ea('0x9f')]['id']:null,_0x46f140[_0x4b90ea('0x9f')]?_0x46f140['user'][_0x4b90ea('0xae')]:null,_0x46f140[_0x4b90ea('0x9f')]?_0x46f140[_0x4b90ea('0x9f')][_0x4b90ea('0x41')]:null,_0x46f140[_0x4b90ea('0x1a')]&&_0x46f140[_0x4b90ea('0x1a')][_0x4b90ea('0xaf')]?_0x46f140['body'][_0x4b90ea('0xaf')]:'other',_0x46f140[_0x4b90ea('0x1a')]&&_0x46f140[_0x4b90ea('0x1a')][_0x4b90ea('0xc7')]?_0x46f140[_0x4b90ea('0x1a')][_0x4b90ea('0xc7')]:'',_0x46f140[_0x4b90ea('0x1a')]&&_0x46f140[_0x4b90ea('0x1a')]['agent_name']?_0x46f140[_0x4b90ea('0x1a')][_0x4b90ea('0x1')]:'');},'ignoreRoute':function(_0x13519a){const _0x4e6b84=/\/api\/users\/[0-9]+\/(login|logout)/gi;return!_0x4e6b84['test'](_0x13519a['url']);}})),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x35'),require(_0x35c4d6('0xce'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xe7'),require(_0x35c4d6('0xd8'))),_0x24ceb3['use'](_0x35c4d6('0x94'),require('./api/voiceContext')),_0x24ceb3['use'](_0x35c4d6('0x1f'),require(_0x35c4d6('0xe1'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xe4'),require(_0x35c4d6('0xe2'))),_0x24ceb3['use'](_0x35c4d6('0x95'),require(_0x35c4d6('0x10b'))),_0x24ceb3['use'](_0x35c4d6('0x117'),require(_0x35c4d6('0x8c'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x139'),require(_0x35c4d6('0x8e'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/voice/mails',require(_0x35c4d6('0x2d'))),_0x24ceb3['use'](_0x35c4d6('0x4c'),require('./api/voiceMailMessage')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x4e'),require('./api/voiceCallReport')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x75'),require(_0x35c4d6('0x12c'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x14'),require(_0x35c4d6('0x90'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xde'),require('./api/voiceQueueReport')),_0x24ceb3[_0x35c4d6('0x33')]('/api/members/reports',require(_0x35c4d6('0x10d'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x2b'),require(_0x35c4d6('0x8f'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x12'),require(_0x35c4d6('0x1c'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x36'),require(_0x35c4d6('0x2c'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x97'),require(_0x35c4d6('0x72'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x53'),require('./api/mailQueue')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xd7'),require(_0x35c4d6('0x10e'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x136'),require(_0x35c4d6('0xe8'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x44'),require(_0x35c4d6('0xbc'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x0'),require(_0x35c4d6('0xc0'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x84'),require(_0x35c4d6('0x8d'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/dashboards',require('./api/dashboard')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xd0'),require(_0x35c4d6('0x45'))),_0x24ceb3['use']('/api/fax/accounts',require('./api/faxAccount')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x81'),require(_0x35c4d6('0x8a'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x11b'),require('./api/faxInteraction')),_0x24ceb3[_0x35c4d6('0x33')]('/api/fax/messages',require(_0x35c4d6('0x1b'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/fax/queues',require(_0x35c4d6('0x3c'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x38'),require(_0x35c4d6('0x85'))),_0x24ceb3['use']('/api/sms/accounts',require(_0x35c4d6('0xfb'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/sms/applications',require('./api/smsApplication')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x82'),require('./api/smsInteraction')),_0x24ceb3[_0x35c4d6('0x33')]('/api/sms/messages',require('./api/smsMessage')),_0x24ceb3['use'](_0x35c4d6('0xc3'),require(_0x35c4d6('0x42'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/openchannel/accounts',require('./api/openchannelAccount')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xa2'),require(_0x35c4d6('0xb3'))),_0x24ceb3['use'](_0x35c4d6('0x13a'),require(_0x35c4d6('0x24'))),_0x24ceb3['use'](_0x35c4d6('0x66'),require(_0x35c4d6('0x6b'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x105'),require(_0x35c4d6('0xca'))),_0x24ceb3['use'](_0x35c4d6('0x2f'),require(_0x35c4d6('0x1e'))),_0x24ceb3['use'](_0x35c4d6('0x6a'),require(_0x35c4d6('0x7a'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x120'),require(_0x35c4d6('0x10a'))),_0x24ceb3['use'](_0x35c4d6('0xb9'),require(_0x35c4d6('0x13'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/chat/messages',require(_0x35c4d6('0xac'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/chat/offline_messages',require(_0x35c4d6('0x4d'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x55'),require('./api/chatQueue')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x11f'),require(_0x35c4d6('0x3d'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xef'),require(_0x35c4d6('0x34'))),_0x24ceb3['use'](_0x35c4d6('0x29'),require(_0x35c4d6('0x3e'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xf6'),require('./api/cmContact')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xa7'),require('./api/cmHopper')),_0x24ceb3[_0x35c4d6('0x33')]('/api/cm/hopper_black',require('./api/cmHopperBlack')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xc2'),require(_0x35c4d6('0x48'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xfd'),require(_0x35c4d6('0x10c'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/cm/custom_fields',require(_0x35c4d6('0xfa'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x3b'),require(_0x35c4d6('0xb2'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xf7'),require(_0x35c4d6('0x79'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x115'),require(_0x35c4d6('0x18'))),_0x24ceb3['use']('/api/dispositions',require(_0x35c4d6('0x91'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xcb'),require(_0x35c4d6('0xf4'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x12b'),require(_0x35c4d6('0xf0'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x5'),require(_0x35c4d6('0xfe'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xc5'),require(_0x35c4d6('0x64'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/voiceQueuesLog',require(_0x35c4d6('0x114'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x128'),require(_0x35c4d6('0x50'))),_0x24ceb3['use'](_0x35c4d6('0x6d'),require(_0x35c4d6('0xc8'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/tags',require(_0x35c4d6('0x40'))),_0x24ceb3['use'](_0x35c4d6('0x116'),require(_0x35c4d6('0x108'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x118'),require(_0x35c4d6('0x4'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x71'),require(_0x35c4d6('0x67'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x26'),require(_0x35c4d6('0x93'))),_0x24ceb3['use'](_0x35c4d6('0x63'),require(_0x35c4d6('0x7'))),_0x24ceb3['use'](_0x35c4d6('0x4b'),require('./api/analyticCustomReport')),_0x24ceb3['use'](_0x35c4d6('0xa1'),require('./api/analyticDefaultReport')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x80'),require(_0x35c4d6('0x4a'))),_0x24ceb3['use'](_0x35c4d6('0xe6'),require(_0x35c4d6('0xbe'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x130'),require(_0x35c4d6('0x92'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/analytics/tree_reports',require(_0x35c4d6('0x119'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x73'),require('./api/intSalesforceAccount')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x121'),require(_0x35c4d6('0xe3'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x124'),require(_0x35c4d6('0x1d'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x9b'),require(_0x35c4d6('0xa5'))),_0x24ceb3['use'](_0x35c4d6('0x6c'),require(_0x35c4d6('0x28'))),_0x24ceb3['use']('/api/integrations/sugarcrm/fields',require(_0x35c4d6('0x13b'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/desk/accounts',require(_0x35c4d6('0x3'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x11e'),require(_0x35c4d6('0xfc'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/desk/fields',require(_0x35c4d6('0xb5'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/zoho/accounts',require(_0x35c4d6('0x7d'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/zoho/configurations',require(_0x35c4d6('0xf3'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x2e'),require(_0x35c4d6('0x7b'))),_0x24ceb3['use'](_0x35c4d6('0x110'),require(_0x35c4d6('0x23'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/zendesk/configurations',require(_0x35c4d6('0xd3'))),_0x24ceb3['use'](_0x35c4d6('0x127'),require(_0x35c4d6('0x88'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x74'),require(_0x35c4d6('0x126'))),_0x24ceb3['use'](_0x35c4d6('0xdf'),require(_0x35c4d6('0xb0'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/freshdesk/fields',require(_0x35c4d6('0x76'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/vtiger/accounts',require(_0x35c4d6('0xdb'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/vtiger/configurations',require(_0x35c4d6('0x104'))),_0x24ceb3['use'](_0x35c4d6('0x132'),require(_0x35c4d6('0x131'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x19'),require(_0x35c4d6('0x107'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xd'),require(_0x35c4d6('0xab'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/servicenow/fields',require('./api/intServicenowField')),_0x24ceb3[_0x35c4d6('0x33')]('/api/integrations/dynamics365/accounts',require(_0x35c4d6('0x123'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x20'),require(_0x35c4d6('0xf5'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x21'),require('./api/intDynamics365Field')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xec'),require(_0x35c4d6('0x10f'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xa9'),require(_0x35c4d6('0x112'))),_0x24ceb3['use'](_0x35c4d6('0x5b'),require(_0x35c4d6('0x7e'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xeb'),require(_0x35c4d6('0x57'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x122'),require(_0x35c4d6('0x43'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x12f'),require(_0x35c4d6('0x83'))),_0x24ceb3['use'](_0x35c4d6('0x6'),require(_0x35c4d6('0x37'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/jscripty/questions/reports',require(_0x35c4d6('0xd4'))),_0x24ceb3['use'](_0x35c4d6('0xd2'),require(_0x35c4d6('0xd1'))),_0x24ceb3['use'](_0x35c4d6('0x3a'),require(_0x35c4d6('0x5a'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/square/reports',require(_0x35c4d6('0xcc'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x13d'),require(_0x35c4d6('0x30'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x109'),require(_0x35c4d6('0x106'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x9e'),require(_0x35c4d6('0x47'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xa'),require('./api/squareOdbc')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x5f'),require('./api/squareProject')),_0x24ceb3['use'](_0x35c4d6('0x77'),require('./api/squareRecording')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xb4'),require('./api/squareMessage')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x9d'),require('./api/team')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x32'),require('./api/license')),_0x24ceb3[_0x35c4d6('0x33')]('/api/campaigns',require(_0x35c4d6('0x31'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x2a'),require(_0x35c4d6('0xad'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/attachments',require('./api/attachment')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x56'),require('./api/plugin')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x98'),require(_0x35c4d6('0xc6'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x70'),require(_0x35c4d6('0x103'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xc'),require(_0x35c4d6('0xed'))),_0x24ceb3['use'](_0x35c4d6('0xf'),require(_0x35c4d6('0xa8'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x8b'),require('./api/smsTransferReport')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x49'),require(_0x35c4d6('0xea'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x16'),require(_0x35c4d6('0xa6'))),_0x24ceb3['use'](_0x35c4d6('0x11c'),require(_0x35c4d6('0xdd'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x46'),require(_0x35c4d6('0x113'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x27'),require(_0x35c4d6('0x87'))),_0x24ceb3['use'](_0x35c4d6('0x11d'),require(_0x35c4d6('0xee'))),_0x24ceb3['use'](_0x35c4d6('0x11'),require(_0x35c4d6('0x102'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xb1'),require(_0x35c4d6('0xa4'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x6e'),require(_0x35c4d6('0x7c'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x138'),require(_0x35c4d6('0x7f'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x54'),require(_0x35c4d6('0xba'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xb6'),require('./api/whatsappTransferReport')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xf1'),require('./api/whatsappQueue')),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xe0'),require(_0x35c4d6('0x5c'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/auth/local',require(_0x35c4d6('0x68'))),_0x24ceb3[_0x35c4d6('0x33')]('/api/auth/google',require(_0x35c4d6('0xbd'))),_0x24ceb3['use']('/api/jira',require(_0x35c4d6('0x86'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x13c'),require(_0x35c4d6('0xaa'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x9'),require(_0x35c4d6('0x5e'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xb7'),require(_0x35c4d6('0x59'))),_0x24ceb3['use'](_0x35c4d6('0x134'),require('./api/pm2')),_0x24ceb3['use']('/api/webbar',require(_0x35c4d6('0xd9'))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x62'),express[_0x35c4d6('0x60')](path[_0x35c4d6('0x133')](config[_0x35c4d6('0xb')],'..',_0x35c4d6('0x4f')))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0xc4'),express[_0x35c4d6('0x60')](path[_0x35c4d6('0x133')](config[_0x35c4d6('0xb')],'..',_0x35c4d6('0x51')))),_0x24ceb3['use'](_0x35c4d6('0x52'),express[_0x35c4d6('0x60')](path['resolve'](config[_0x35c4d6('0xb')],'..',_0x35c4d6('0x137')))),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x12e'),express['static'](path[_0x35c4d6('0x133')](config[_0x35c4d6('0xb')],_0x35c4d6('0x129'))));const {chatPath:_0x4bc276,chatVersion:_0x455041}=await getInstalledChatVersion(),_0x5bc233=getConfigService();!(_0x5bc233[_0x35c4d6('0x125')]||_0x5bc233['isTest'])&&console['log'](_0x35c4d6('0x69'),_0x4bc276,_0x455041),_0x4bc276&&_0x455041&&(_0x24ceb3[_0x35c4d6('0x61')](_0x35c4d6('0xa3'),_0x455041),_0x24ceb3[_0x35c4d6('0x33')](_0x35c4d6('0x5d'),express['static'](_0x4bc276))),_0x24ceb3['route'](_0x35c4d6('0x11a'))['get'](errors[0x194]),_0x24ceb3[_0x35c4d6('0x15')]('*',function(_0x3a7fe5,_0x460b0e){const _0x4ff522=_0x35c4d6;_0x460b0e[_0x4ff522('0x100')](path['resolve'](_0x24ceb3['get'](_0x4ff522('0xf9'))+_0x4ff522('0xe')));});}exports['default']=routes; \ No newline at end of file diff --git a/server/rpc/index.js b/server/rpc/index.js index 8efd76f..68524b6 100644 --- a/server/rpc/index.js +++ b/server/rpc/index.js @@ -1 +1 @@ -const a1025_0x50e9=['Express\x20RPC\x20server\x20closed','default','rpc','listen','../api/openchannelQueueReport/openchannelQueueReport.rpc','../api/intZendeskAccount/intZendeskAccount.rpc','function','../api/intFreshdeskAccount/intFreshdeskAccount.rpc','../api/user/user.rpc','../api/intVtigerAccount/intVtigerAccount.rpc','../api/cmHopperFinal/cmHopperFinal.rpc','../api/plugin/plugin.rpc','../api/chatQueue/chatQueue.rpc','../api/intFreshsalesAccount/intFreshsalesAccount.rpc','../api/chatMessage/chatMessage.rpc','http','../api/template/template.rpc','../api/intZohoAccount/intZohoAccount.rpc','../api/variable/variable.rpc','../api/smsQueue/smsQueue.rpc','log','../api/faxQueueReport/faxQueueReport.rpc','../api/intDynamics365Account/intDynamics365Account.rpc','../api/attachment/attachment.rpc','../api/pause/pause.rpc','../api/whatsappQueue/whatsappQueue.rpc','../api/interval/interval.rpc','../api/smsMessage/smsMessage.rpc','../api/mailInteraction/mailInteraction.rpc','../api/openchannelQueue/openchannelQueue.rpc','../api/squareReport/squareReport.rpc','../api/mailApplication/mailApplication.rpc','../api/smsInteraction/smsInteraction.rpc','../api/whatsappAccount/whatsappAccount.rpc','../api/faxQueue/faxQueue.rpc','server','../api/mailAccount/mailAccount.rpc','RPC\x20listening\x20on\x20','../api/trigger/trigger.rpc','../api/voiceQueueReport/voiceQueueReport.rpc','../api/voiceCallReport/voiceCallReport.rpc','../api/squareOdbc/squareOdbc.rpc','../api/faxAccount/faxAccount.rpc','../api/faxApplication/faxApplication.rpc','../api/mailQueue/mailQueue.rpc','../api/squareProject/squareProject.rpc','port','../api/openchannelInteraction/openchannelInteraction.rpc','../api/chatInteraction/chatInteraction.rpc','../api/voiceDialReport/voiceDialReport.rpc','merge','../api/cmHopper/cmHopper.rpc','../api/squareRecording/squareRecording.rpc','../api/openchannelApplication/openchannelApplication.rpc','../api/voiceExtension/voiceExtension.rpc','../api/whatsappMessage/whatsappMessage.rpc','../api/cmContact/cmContact.rpc','../api/memberReport/memberReport.rpc','localhost','../api/openchannelMessage/openchannelMessage.rpc','../api/cmHopperBlack/cmHopperBlack.rpc','../api/intServicenowAccount/intServicenowAccount.rpc','jayson/promise','../config/environment','../api/trunk/trunk.rpc','../api/mailServerIn/mailServerIn.rpc','../config/triggers','../api/intDeskAccount/intDeskAccount.rpc','error','close','../api/squareReportDetail/squareReportDetail.rpc','../api/userVoiceQueueRt/userVoiceQueueRt.rpc','../api/mailQueueReport/mailQueueReport.rpc','../api/sound/sound.rpc','../api/smsQueueReport/smsQueueReport.rpc'];(function(_0x1f1d88,_0x50e99d){const _0x40beb2=function(_0x53f513){while(--_0x53f513){_0x1f1d88['push'](_0x1f1d88['shift']());}};_0x40beb2(++_0x50e99d);}(a1025_0x50e9,0x163));const a1025_0x40be=function(_0x1f1d88,_0x50e99d){_0x1f1d88=_0x1f1d88-0x0;let _0x40beb2=a1025_0x50e9[_0x1f1d88];return _0x40beb2;};const _0x3603b7=a1025_0x40be;'use strict';const jayson=require(_0x3603b7('0x7')),_=require('lodash'),config=require(_0x3603b7('0x8'));function init(){const _0x54eb99=_0x3603b7;let _0x53f513={};return _0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x1c'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x4a'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/voiceQueue/voiceQueue.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/voiceRecording/voiceRecording.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x3c'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x45'))),_0x53f513=_['merge'](_0x53f513,require('../api/voiceAgentReport/voiceAgentReport.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x3b'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x2'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x9'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/voiceTransferReport/voiceTransferReport.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x10'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0xa'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x38'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x40'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x30'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/mailMessage/mailMessage.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x33'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x11'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x3e'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x3f'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/faxInteraction/faxInteraction.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/faxMessage/faxMessage.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x36'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x29'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/smsAccount/smsAccount.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x34'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x2f'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x27'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x49'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x43'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x4'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x31'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x18'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x44'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x22'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x20'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x1'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x47'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x5'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x1e'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/cmHopperHistory/cmHopperHistory.rpc')),_0x53f513=_['merge'](_0x53f513,require('../api/reportAgentPreview/reportAgentPreview.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x2e'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x2c'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x12'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x24'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x3a'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x26'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/intSalesforceAccount/intSalesforceAccount.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/intSugarcrmAccount/intSugarcrmAccount.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0xc'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x25'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x19'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x1b'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x1d'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x6'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x2a'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x21'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/chatQueueReport/chatQueueReport.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x13'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x32'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0xf'))),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x3d'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x41'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x48'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/squareMessage/squareMessage.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/campaign/campaign.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x2b'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x1f'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x35'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/whatsappInteraction/whatsappInteraction.rpc')),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require(_0x54eb99('0x0'))),_0x53f513=_[_0x54eb99('0x46')](_0x53f513,require('../api/whatsappQueueReport/whatsappQueueReport.rpc')),_0x53f513=_['merge'](_0x53f513,require(_0x54eb99('0x2d'))),_0x53f513;}class RPC{constructor(_0x9060e5){const _0x738907=_0x3603b7;this[_0x738907('0x42')]=config[_0x738907('0x16')]['port']||config[_0x738907('0x42')]+0x1,this['host']=config[_0x738907('0x16')]['ip']||_0x738907('0x3');const _0x42dad5=init();this['server']=jayson['server'](_0x42dad5)[_0x738907('0x23')](),typeof _0x9060e5===_0x738907('0x1a')&&this[_0x738907('0x37')]['on'](_0x738907('0xd'),_0x9060e5);}[_0x3603b7('0x17')](){const {port:_0x27db05,host:_0x163ca1}=this;return new Promise(_0x188997=>{const _0x34e0b1=a1025_0x40be;this[_0x34e0b1('0x37')]['listen'](_0x27db05,_0x163ca1,function(){const _0x401cd2=_0x34e0b1;console['log']('Express\x20RPC\x20server\x20listening\x20on\x20%s:%d!',_0x163ca1,_0x27db05),require(_0x401cd2('0xb'))[_0x401cd2('0x15')](),_0x188997(_0x401cd2('0x39')+_0x163ca1+':'+_0x27db05);});});}['close'](){return new Promise(_0x13622d=>{const _0x360a6c=a1025_0x40be;this['server'][_0x360a6c('0xe')](()=>{const _0x11246d=_0x360a6c;console[_0x11246d('0x28')](_0x11246d('0x14')),_0x13622d();});});}}module['exports']={'RPC':RPC}; \ No newline at end of file +const a1025_0x1e77=['../api/intVtigerAccount/intVtigerAccount.rpc','../api/intDeskAccount/intDeskAccount.rpc','exports','jayson/promise','../api/mailApplication/mailApplication.rpc','../api/intDynamics365Account/intDynamics365Account.rpc','../api/mailQueueReport/mailQueueReport.rpc','port','../api/intSugarcrmAccount/intSugarcrmAccount.rpc','../api/cmHopperHistory/cmHopperHistory.rpc','function','../api/intFreshsalesAccount/intFreshsalesAccount.rpc','../api/smsQueueReport/smsQueueReport.rpc','../api/plugin/plugin.rpc','../api/cmHopperFinal/cmHopperFinal.rpc','../api/voiceExtension/voiceExtension.rpc','lodash','../api/openchannelApplication/openchannelApplication.rpc','http','host','../api/mailQueue/mailQueue.rpc','../api/cmContact/cmContact.rpc','../api/voiceQueue/voiceQueue.rpc','../api/faxAccount/faxAccount.rpc','../api/intServicenowAccount/intServicenowAccount.rpc','RPC\x20listening\x20on\x20','../api/voiceTransferReport/voiceTransferReport.rpc','../api/chatQueueReport/chatQueueReport.rpc','../api/openchannelMessage/openchannelMessage.rpc','localhost','../api/voiceCallReport/voiceCallReport.rpc','../config/environment','default','../api/whatsappQueue/whatsappQueue.rpc','../api/interval/interval.rpc','../api/smsAccount/smsAccount.rpc','../api/cmHopper/cmHopper.rpc','../api/variable/variable.rpc','error','../api/whatsappInteraction/whatsappInteraction.rpc','../api/reportAgentPreview/reportAgentPreview.rpc','log','../api/openchannelInteraction/openchannelInteraction.rpc','../api/openchannelQueueReport/openchannelQueueReport.rpc','../api/sound/sound.rpc','listen','../api/voiceDialReport/voiceDialReport.rpc','../api/voiceAgentReport/voiceAgentReport.rpc','../api/intZendeskAccount/intZendeskAccount.rpc','../api/voiceRecording/voiceRecording.rpc','../config/triggers','../api/chatInteraction/chatInteraction.rpc','../api/trigger/trigger.rpc','../api/whatsappMessage/whatsappMessage.rpc','Express\x20RPC\x20server\x20closed','close','../api/faxMessage/faxMessage.rpc','../api/campaign/campaign.rpc','../api/voiceQueueReport/voiceQueueReport.rpc','../api/trunk/trunk.rpc','server','../api/faxApplication/faxApplication.rpc','rpc','../api/userVoiceQueueRt/userVoiceQueueRt.rpc','merge','../api/whatsappAccount/whatsappAccount.rpc','../api/intFreshdeskAccount/intFreshdeskAccount.rpc','../api/mailAccount/mailAccount.rpc','Express\x20RPC\x20server\x20listening\x20on\x20%s:%d!','../api/attachment/attachment.rpc','../api/whatsappQueueReport/whatsappQueueReport.rpc','../api/mailServerIn/mailServerIn.rpc','../api/chatQueue/chatQueue.rpc','../api/squareReportDetail/squareReportDetail.rpc','../api/mailMessage/mailMessage.rpc'];(function(_0x211331,_0x1e7761){const _0x38dc83=function(_0x4d996b){while(--_0x4d996b){_0x211331['push'](_0x211331['shift']());}};_0x38dc83(++_0x1e7761);}(a1025_0x1e77,0x118));const a1025_0x38dc=function(_0x211331,_0x1e7761){_0x211331=_0x211331-0x0;let _0x38dc83=a1025_0x1e77[_0x211331];return _0x38dc83;};const _0xa96ce7=a1025_0x38dc;'use strict';const jayson=require(_0xa96ce7('0x17')),_=require(_0xa96ce7('0x24')),config=require(_0xa96ce7('0x33'));function init(){const _0x38f9fb=_0xa96ce7;let _0x4d996b={};return _0x4d996b=_['merge'](_0x4d996b,require('../api/user/user.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x23'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x2a'))),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x45'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x32'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x42'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x43'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x3'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/memberReport/memberReport.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x4'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x2e'))),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x8'))),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x10'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0xc'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x28'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/mailInteraction/mailInteraction.rpc')),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x13'))),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x18'))),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x1a'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x2b'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x6'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/faxInteraction/faxInteraction.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x1'))),_0x4d996b=_['merge'](_0x4d996b,require('../api/faxQueue/faxQueue.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/faxQueueReport/faxQueueReport.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x37'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/smsInteraction/smsInteraction.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/smsMessage/smsMessage.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/smsQueue/smsQueue.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x25'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x3e'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x30'))),_0x4d996b=_['merge'](_0x4d996b,require('../api/openchannelQueue/openchannelQueue.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x3f'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x47'))),_0x4d996b=_['merge'](_0x4d996b,require('../api/chatMessage/chatMessage.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x11'))),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x29'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x38'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/cmHopperBlack/cmHopperBlack.rpc')),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x22'))),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x1d'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x3c'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x36'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/pause/pause.rpc')),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x40'))),_0x4d996b=_['merge'](_0x4d996b,require('../api/template/template.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x48'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x39'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/intSalesforceAccount/intSalesforceAccount.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x1c'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x15'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/intZohoAccount/intZohoAccount.rpc')),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x44'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0xb'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x14'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x2c'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x19'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x1f'))),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x2f'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x20'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/squareReport/squareReport.rpc')),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x12'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/squareOdbc/squareOdbc.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/squareProject/squareProject.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require('../api/squareRecording/squareRecording.rpc')),_0x4d996b=_['merge'](_0x4d996b,require('../api/squareMessage/squareMessage.rpc')),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x2'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0xe'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x21'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0xa'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x3b'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0x49'))),_0x4d996b=_[_0x38f9fb('0x9')](_0x4d996b,require(_0x38f9fb('0xf'))),_0x4d996b=_['merge'](_0x4d996b,require(_0x38f9fb('0x35'))),_0x4d996b;}class RPC{constructor(_0x16ab3d){const _0x8e10fd=_0xa96ce7;this[_0x8e10fd('0x1b')]=config['rpc'][_0x8e10fd('0x1b')]||config[_0x8e10fd('0x1b')]+0x1,this[_0x8e10fd('0x27')]=config[_0x8e10fd('0x7')]['ip']||_0x8e10fd('0x31');const _0x4c1be4=init();this[_0x8e10fd('0x5')]=jayson[_0x8e10fd('0x5')](_0x4c1be4)[_0x8e10fd('0x26')](),typeof _0x16ab3d===_0x8e10fd('0x1e')&&this[_0x8e10fd('0x5')]['on'](_0x8e10fd('0x3a'),_0x16ab3d);}[_0xa96ce7('0x41')](){const {port:_0x54cd02,host:_0xb85eb1}=this;return new Promise(_0x3ba97c=>{const _0xb8fb2e=a1025_0x38dc;this['server'][_0xb8fb2e('0x41')](_0x54cd02,_0xb85eb1,function(){const _0x3b26fd=_0xb8fb2e;console[_0x3b26fd('0x3d')](_0x3b26fd('0xd'),_0xb85eb1,_0x54cd02),require(_0x3b26fd('0x46'))[_0x3b26fd('0x34')](),_0x3ba97c(_0x3b26fd('0x2d')+_0xb85eb1+':'+_0x54cd02);});});}[_0xa96ce7('0x0')](){return new Promise(_0x5f2390=>{const _0x536608=a1025_0x38dc;this[_0x536608('0x5')]['close'](()=>{const _0x1aeee3=_0x536608;console['log'](_0x1aeee3('0x4a')),_0x5f2390();});});}}module[_0xa96ce7('0x16')]={'RPC':RPC}; \ No newline at end of file diff --git a/server/services/agi/channel.js b/server/services/agi/channel.js index 1e6853e..986c49d 100644 --- a/server/services/agi/channel.js +++ b/server/services/agi/channel.js @@ -1 +1 @@ -const a1026_0x4063=['noop','split','WAIT','events','match','ID:%s\x20-\x20LABEL:\x20%s\x20-\x20MSG:\x20%s','result=','setVariable','timeout','label','function','isNumber','E_AGI_SOCKET_TIMEOUT','wait','AGI','ANSWER','SAY\x20DIGITS\x20%s\x20%s','sync','520-Invalid','SAY\x20PHONETIC\x20\x22%s\x22\x20%s','replace','indexOf','length','SET\x20VARIABLE\x20%s\x20\x22%s\x22','wav','setTimeout','util','continueAt','E_AGI_SOCKET_ERROR','sendRequest','recordFile','VERBOSE\x20\x22%s\x22','join','pipe','SET\x20PRIORITY\x20%s','getVariable','search','sayDigits','520\x20End\x20of\x20proper','GET\x20DATA\x20\x22%s\x22\x20%s\x20%s','isArray','destroy','startsWith','emit','utf8','getData','isBoolean','format','toLowerCase','error','substr','line','RECORD\x20FILE\x20\x22%s\x22\x20\x22%s\x22\x20\x22%s\x22\x20%s\x20%s\x20%s','beep','command','EXEC\x20%s\x20%s','hangup','setExtension','substring','inherits','setPriority','close','SAY\x20NUMBER\x20%s\x20%s','GET\x20VARIABLE\x20\x22%s\x22','./error','prototype','toString','EventEmitter','write','exec','answer'];(function(_0x216d7f,_0x40638b){const _0x584445=function(_0x5f40d4){while(--_0x5f40d4){_0x216d7f['push'](_0x216d7f['shift']());}};_0x584445(++_0x40638b);}(a1026_0x4063,0x124));const a1026_0x5844=function(_0x216d7f,_0x40638b){_0x216d7f=_0x216d7f-0x0;let _0x584445=a1026_0x4063[_0x216d7f];return _0x584445;};const _0x4e107b=a1026_0x5844;'use strict';const util=require(_0x4e107b('0x12')),_=require('lodash'),EventEmitter=require(_0x4e107b('0x42'))[_0x4e107b('0x3b')],AGIReply=require('./reply'),AGIError=require(_0x4e107b('0x38'));function AGIChannel(_0x5f40d4){const _0x1c3248=_0x4e107b,_0x440516=this,_0xf4f77=new AGIReply();let _0x3cc4c6=![],_0x2be629={};EventEmitter['call'](_0x440516),_0x5f40d4['setEncoding'](_0x1c3248('0x24')),_0x5f40d4[_0x1c3248('0x11')](0x8*0x3c*0x3c*0x3e8),_0xf4f77['setEncoding'](_0x1c3248('0x24')),_0xf4f77['on']('headers',function(_0x35e654){const _0x48cda0=_0x1c3248;for(const _0x64d8d1 in _0x35e654){_0x440516[_0x64d8d1]=_0x35e654[_0x64d8d1];}_0x440516[_0x48cda0('0x23')]('ready');}),_0xf4f77['on'](_0x1c3248('0x2b'),function(_0x3886a7){const _0x31be31=_0x1c3248;if(_0x3886a7[_0x31be31('0x28')]()==_0x31be31('0x30')){_0x440516[_0x31be31('0x23')](_0x31be31('0x30'));return;}_0x3886a7[_0x31be31('0x32')](0x0,0xb)==_0x31be31('0xa')&&(_0x3cc4c6=!![]);_0x3cc4c6?(_0x2be629['rx']+=_0x3886a7+'\x0a',_0x3886a7[_0x31be31('0x1c')](_0x31be31('0x1e'))!=-0x1&&(_0x3cc4c6=![])):_0x2be629['rx']=_0x3886a7;if(_0x3cc4c6)return;if(typeof _0x2be629['cb']==_0x31be31('0x2')){let _0x4d8302=_0x2be629['rx'][_0x31be31('0x32')](0x0,0x3),_0x39e8fc=null,_0x516b28=null;_0x4d8302=parseInt(_0x4d8302);if(isNaN(_0x4d8302)){_0x2be629['cb'](null,{'code':0x1f4,'result':-0x1,'extra':'no\x20code'});return;}if(_0x4d8302!=0xc8){_0x2be629['cb'](null,{'code':_0x4d8302,'result':-0x1,'extra':'KO'});return;}_0x39e8fc=_0x2be629['rx'][_0x31be31('0x32')](0x4)[_0x31be31('0xc')](_0x31be31('0x45'),'');_0x39e8fc[_0x31be31('0xd')]('\x20')!=-0x1&&(_0x39e8fc=_0x39e8fc[_0x31be31('0x2a')](0x0,_0x39e8fc['indexOf']('\x20')));_[_0x31be31('0x22')](_0x39e8fc,'-1')&&(_0x39e8fc=parseInt(_0x39e8fc));_0x516b28=_0x2be629['rx'][_0x31be31('0x40')]('\x20');if(_0x516b28[_0x31be31('0xe')]==0x3)_0x516b28=_0x516b28[0x2][_0x31be31('0x32')](0x1,_0x516b28[0x2]['length']-0x1);else{if(_0x516b28[_0x31be31('0xe')]>0x3){const _0xa90ace=/\((.+)\)/,_0x36bab5=_0x2be629['rx'][_0x31be31('0x43')](_0xa90ace);_0x36bab5?_0x516b28=_0x36bab5[0x1]:_0x516b28=null;}else _0x516b28=null;}_0x2be629['cb'](null,{'code':_0x4d8302,'result':_0x39e8fc,'extra':_0x516b28});}}),_0x5f40d4['on'](_0x1c3248('0x29'),function(_0x25f05d){const _0x3f2c2a=_0x1c3248;_0x440516['emit'](_0x3f2c2a('0x29'),new AGIError(_0x3f2c2a('0x14'),_0x25f05d['code']));}),_0x5f40d4['on'](_0x1c3248('0x35'),function(){const _0x34996f=_0x1c3248;_0x440516['emit'](_0x34996f('0x35'),new AGIError('E_AGI_SOCKET_CLOSE'));}),_0x5f40d4['on'](_0x1c3248('0x0'),function(){const _0x572b82=_0x1c3248;_0x440516[_0x572b82('0x23')](_0x572b82('0x0'),new AGIError(_0x572b82('0x4'))),_0x5f40d4[_0x572b82('0x21')]();}),_0x5f40d4[_0x1c3248('0x19')](_0xf4f77),(this['command']=function(_0x2cdf30,_0x554688){const _0x5caf5d=_0x1c3248;_0x2cdf30=_0x2cdf30||'',_0x554688=typeof _0x554688==_0x5caf5d('0x2')?_0x554688:new Function(),_0x2be629={'tx':_0x2cdf30,'rx':'','cb':_0x554688},_0x5f40d4[_0x5caf5d('0x3c')](_0x2cdf30+'\x0a');},this[_0x1c3248('0x35')]=function(){const _0x509b5e=_0x1c3248;_0x5f40d4[_0x509b5e('0x21')]();});}util[_0x4e107b('0x33')](AGIChannel,EventEmitter),AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x15')]=function(_0x59c2f2){const _0x5ecfb=_0x4e107b;return this[_0x5ecfb('0x2e')][_0x5ecfb('0x9')](this,_0x59c2f2);},AGIChannel['prototype'][_0x4e107b('0x3e')]=function(){const _0x5b0b84=_0x4e107b;return this['sendRequest'](_0x5b0b84('0x7'));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x25')]=function(_0x3c6de9,_0x1ef514,_0x102c5b){const _0x4a930d=_0x4e107b;return _0x3c6de9=_0x3c6de9===undefined?_0x4a930d('0x2d'):_0x3c6de9,_0x1ef514=_0x1ef514===undefined?'5':_0x1ef514,_0x102c5b=_0x102c5b===undefined?'1':_0x102c5b,this[_0x4a930d('0x15')](util[_0x4a930d('0x27')](_0x4a930d('0x1f'),_0x3c6de9,_0x1ef514*0x3e8,_0x102c5b));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x3f')]=function(_0x54730b){const _0xdadd3a=_0x4e107b;return _0x54730b=_0x54730b||'NO\x20MESSAGE',this[_0xdadd3a('0x15')](util[_0xdadd3a('0x27')](_0xdadd3a('0x17'),_0x54730b));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x3d')]=function(_0x170ca9,_0x57f34c){const _0xc69702=_0x4e107b;if(_[_0xc69702('0x20')](_0x57f34c))return this[_0xc69702('0x15')](util[_0xc69702('0x27')](_0xc69702('0x2f'),_0x170ca9,_0x57f34c[_0xc69702('0x18')](',')));return this['sendRequest'](util[_0xc69702('0x27')]('EXEC\x20%s\x20%s',_0x170ca9,_0x57f34c));},AGIChannel[_0x4e107b('0x39')]['setContext']=function(_0x5b4057){const _0x4ae677=_0x4e107b;return this[_0x4ae677('0x15')](util[_0x4ae677('0x27')]('SET\x20CONTEXT\x20%s',_0x5b4057));},AGIChannel[_0x4e107b('0x39')]['setExtension']=function(_0xb0f61a){const _0x36a748=_0x4e107b;return this[_0x36a748('0x15')](util['format']('SET\x20EXTENSION\x20%s',_0xb0f61a));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x34')]=function(_0x4e070c){const _0x4eaa38=_0x4e107b;return this[_0x4eaa38('0x15')](util[_0x4eaa38('0x27')](_0x4eaa38('0x1a'),_0x4e070c));},AGIChannel[_0x4e107b('0x39')]['hangup']=function(){const _0x34891e=_0x4e107b;return this[_0x34891e('0x15')]('HANGUP');},AGIChannel['prototype'][_0x4e107b('0x46')]=function(_0x398373,_0x389c85){const _0x427378=_0x4e107b,_0x1b7b19=_[_0x427378('0x26')](_0x389c85)||_[_0x427378('0x3')](_0x389c85)?_0x389c85['toString']():_0x389c85;return this[_0x427378('0x15')](util[_0x427378('0x27')](_0x427378('0xf'),_0x398373,_0x1b7b19?_0x1b7b19[_0x427378('0x3a')]()['replace'](/(\r\n|\n|\r)/gm,'\x20'):''));},AGIChannel[_0x4e107b('0x39')]['sayNumber']=function(_0x42fff,_0x13daec){const _0x542eef=_0x4e107b;return this['sendRequest'](util[_0x542eef('0x27')](_0x542eef('0x36'),_0x42fff,_0x13daec));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x1d')]=function(_0x2dc97c,_0x41d06b){const _0x3c448b=_0x4e107b;return this[_0x3c448b('0x15')](util[_0x3c448b('0x27')](_0x3c448b('0x8'),_0x2dc97c,_0x41d06b));},AGIChannel[_0x4e107b('0x39')]['sayPhonetic']=function(_0x557885,_0x205f8a){const _0x2e843b=_0x4e107b;return this[_0x2e843b('0x15')](util[_0x2e843b('0x27')](_0x2e843b('0xb'),_0x557885,_0x205f8a));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x13')]=function(_0x57b88c,_0x50e808,_0x55ab53){const _0x216856=_0x4e107b;return _0x50e808=_0x50e808||this['extension'],_0x55ab53=_0x55ab53||0x1,this['setContext'](_0x57b88c),this[_0x216856('0x31')](_0x50e808),this[_0x216856('0x34')](_0x55ab53),this[_0x216856('0x3f')](util[_0x216856('0x27')]('GOTO\x20%s\x20%s\x20%s',_0x57b88c,_0x50e808,_0x55ab53));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x1b')]=function(_0x112a19){const _0x39536f=_0x4e107b;return this[_0x39536f('0x15')](util['format'](_0x39536f('0x37'),_0x112a19));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x16')]=function(_0x238476,_0x509877,_0x477443,_0x25c5ef,_0x890676,_0x3a29ea){const _0x5b70b5=_0x4e107b;return _0x509877=_0x509877||_0x5b70b5('0x10'),_0x477443=_0x477443||'',_0x25c5ef=_0x25c5ef===undefined?-0x1:_0x25c5ef==='-1'?-0x1:_0x25c5ef*0x3e8,_0x890676=_0x890676===undefined?'':'s='+_0x890676,_0x3a29ea=_0x3a29ea?'BEEP':'',this['sendRequest'](util[_0x5b70b5('0x27')](_0x5b70b5('0x2c'),_0x238476,_0x509877,_0x477443,_0x25c5ef,_0x3a29ea,_0x890676));},AGIChannel[_0x4e107b('0x39')]['streamFile']=function(_0x6e5db4,_0x1aaefd){const _0x3b3064=_0x4e107b;return _0x1aaefd=_0x1aaefd||'',this[_0x3b3064('0x15')](util[_0x3b3064('0x27')]('STREAM\x20FILE\x20\x22%s\x22\x20\x22%s\x22',_0x6e5db4,_0x1aaefd));},AGIChannel[_0x4e107b('0x39')]['agi']=function(_0x240d99){const _0x56316d=_0x4e107b;return this[_0x56316d('0x3d')](_0x56316d('0x6'),_0x240d99);},AGIChannel['prototype'][_0x4e107b('0x5')]=function(_0x7fc2f3){const _0x5adba8=_0x4e107b;return this['exec'](_0x5adba8('0x41'),_0x7fc2f3);},AGIChannel['prototype'][_0x4e107b('0x29')]=function(_0x3f2155,_0x4afc22){const _0x444bab=_0x4e107b;return this['noop'](util[_0x444bab('0x27')](_0x444bab('0x44'),_0x3f2155['id'],_0x3f2155[_0x444bab('0x1')],_0x4afc22)),{'code':0x1f4,'result':'-1','extra':''};},module['exports']=AGIChannel; \ No newline at end of file +const a1026_0x3a21=['GET\x20DATA\x20\x22%s\x22\x20%s\x20%s','SET\x20PRIORITY\x20%s','sendRequest','search','NO\x20MESSAGE','STREAM\x20FILE\x20\x22%s\x22\x20\x22%s\x22','result=','indexOf','replace','setTimeout','close','isArray','HANGUP','pipe','EXEC\x20%s\x20%s','label','setVariable','line','prototype','ANSWER','setContext','SET\x20CONTEXT\x20%s','SET\x20EXTENSION\x20%s','headers','WAIT','recordFile','ID:%s\x20-\x20LABEL:\x20%s\x20-\x20MSG:\x20%s','emit','SAY\x20NUMBER\x20%s\x20%s','length','wav','SAY\x20PHONETIC\x20\x22%s\x22\x20%s','setExtension','E_AGI_SOCKET_TIMEOUT','E_AGI_SOCKET_ERROR','utf8','lodash','format','520\x20End\x20of\x20proper','function','join','sync','extension','util','sayNumber','./error','wait','agi','E_AGI_SOCKET_CLOSE','code','SET\x20VARIABLE\x20%s\x20\x22%s\x22','toLowerCase','setEncoding','hangup','answer','GET\x20VARIABLE\x20\x22%s\x22','sayDigits','toString','substring','getVariable','error','call','destroy','noop','inherits','VERBOSE\x20\x22%s\x22','command','timeout','no\x20code','exports','exec','substr','continueAt','startsWith'];(function(_0x281520,_0x3a2147){const _0x39ff15=function(_0xc114ab){while(--_0xc114ab){_0x281520['push'](_0x281520['shift']());}};_0x39ff15(++_0x3a2147);}(a1026_0x3a21,0xed));const a1026_0x39ff=function(_0x281520,_0x3a2147){_0x281520=_0x281520-0x0;let _0x39ff15=a1026_0x3a21[_0x281520];return _0x39ff15;};const _0xf0d966=a1026_0x39ff;'use strict';const util=require(_0xf0d966('0x1c')),_=require(_0xf0d966('0x15')),EventEmitter=require('events')['EventEmitter'],AGIReply=require('./reply'),AGIError=require(_0xf0d966('0x1e'));function AGIChannel(_0xc114ab){const _0x38507c=_0xf0d966,_0x4f2e33=this,_0x4bf724=new AGIReply();let _0x5c26ca=![],_0x265cdb={};EventEmitter[_0x38507c('0x2e')](_0x4f2e33),_0xc114ab[_0x38507c('0x25')](_0x38507c('0x14')),_0xc114ab[_0x38507c('0x44')](0x8*0x3c*0x3c*0x3e8),_0x4bf724['setEncoding'](_0x38507c('0x14')),_0x4bf724['on'](_0x38507c('0x8'),function(_0x5f4794){for(const _0x4b2439 in _0x5f4794){_0x4f2e33[_0x4b2439]=_0x5f4794[_0x4b2439];}_0x4f2e33['emit']('ready');}),_0x4bf724['on'](_0x38507c('0x2'),function(_0x230f0a){const _0x2e4b41=_0x38507c;if(_0x230f0a[_0x2e4b41('0x24')]()==_0x2e4b41('0x26')){_0x4f2e33['emit'](_0x2e4b41('0x26'));return;}_0x230f0a[_0x2e4b41('0x2b')](0x0,0xb)=='520-Invalid'&&(_0x5c26ca=!![]);_0x5c26ca?(_0x265cdb['rx']+=_0x230f0a+'\x0a',_0x230f0a[_0x2e4b41('0x3e')](_0x2e4b41('0x17'))!=-0x1&&(_0x5c26ca=![])):_0x265cdb['rx']=_0x230f0a;if(_0x5c26ca)return;if(typeof _0x265cdb['cb']=='function'){let _0x2affa5=_0x265cdb['rx'][_0x2e4b41('0x2b')](0x0,0x3),_0x44408b=null,_0x504a90=null;_0x2affa5=parseInt(_0x2affa5);if(isNaN(_0x2affa5)){_0x265cdb['cb'](null,{'code':0x1f4,'result':-0x1,'extra':_0x2e4b41('0x35')});return;}if(_0x2affa5!=0xc8){_0x265cdb['cb'](null,{'code':_0x2affa5,'result':-0x1,'extra':'KO'});return;}_0x44408b=_0x265cdb['rx'][_0x2e4b41('0x2b')](0x4)['replace'](_0x2e4b41('0x41'),'');_0x44408b[_0x2e4b41('0x42')]('\x20')!=-0x1&&(_0x44408b=_0x44408b[_0x2e4b41('0x38')](0x0,_0x44408b[_0x2e4b41('0x42')]('\x20')));_[_0x2e4b41('0x3a')](_0x44408b,'-1')&&(_0x44408b=parseInt(_0x44408b));_0x504a90=_0x265cdb['rx']['split']('\x20');if(_0x504a90[_0x2e4b41('0xe')]==0x3)_0x504a90=_0x504a90[0x2]['substring'](0x1,_0x504a90[0x2][_0x2e4b41('0xe')]-0x1);else{if(_0x504a90[_0x2e4b41('0xe')]>0x3){const _0x18daaf=/\((.+)\)/,_0x41c9b9=_0x265cdb['rx']['match'](_0x18daaf);_0x41c9b9?_0x504a90=_0x41c9b9[0x1]:_0x504a90=null;}else _0x504a90=null;}_0x265cdb['cb'](null,{'code':_0x2affa5,'result':_0x44408b,'extra':_0x504a90});}}),_0xc114ab['on'](_0x38507c('0x2d'),function(_0x54da16){const _0x289599=_0x38507c;_0x4f2e33[_0x289599('0xc')](_0x289599('0x2d'),new AGIError(_0x289599('0x13'),_0x54da16[_0x289599('0x22')]));}),_0xc114ab['on'](_0x38507c('0x45'),function(){const _0x2b9185=_0x38507c;_0x4f2e33[_0x2b9185('0xc')](_0x2b9185('0x45'),new AGIError(_0x2b9185('0x21')));}),_0xc114ab['on']('timeout',function(){const _0x43e948=_0x38507c;_0x4f2e33['emit'](_0x43e948('0x34'),new AGIError(_0x43e948('0x12'))),_0xc114ab[_0x43e948('0x2f')]();}),_0xc114ab[_0x38507c('0x48')](_0x4bf724),(this[_0x38507c('0x33')]=function(_0x2b5a97,_0x402f77){const _0x4dc84d=_0x38507c;_0x2b5a97=_0x2b5a97||'',_0x402f77=typeof _0x402f77==_0x4dc84d('0x18')?_0x402f77:new Function(),_0x265cdb={'tx':_0x2b5a97,'rx':'','cb':_0x402f77},_0xc114ab['write'](_0x2b5a97+'\x0a');},this[_0x38507c('0x45')]=function(){const _0x158166=_0x38507c;_0xc114ab[_0x158166('0x2f')]();});}util[_0xf0d966('0x31')](AGIChannel,EventEmitter),AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x3d')]=function(_0x51e857){const _0x446fd0=_0xf0d966;return this[_0x446fd0('0x33')][_0x446fd0('0x1a')](this,_0x51e857);},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x27')]=function(){const _0x63759e=_0xf0d966;return this['sendRequest'](_0x63759e('0x4'));},AGIChannel['prototype']['getData']=function(_0x1329fb,_0x5b4f58,_0x2365a6){const _0x2478eb=_0xf0d966;return _0x1329fb=_0x1329fb===undefined?'beep':_0x1329fb,_0x5b4f58=_0x5b4f58===undefined?'5':_0x5b4f58,_0x2365a6=_0x2365a6===undefined?'1':_0x2365a6,this[_0x2478eb('0x3d')](util[_0x2478eb('0x16')](_0x2478eb('0x3b'),_0x1329fb,_0x5b4f58*0x3e8,_0x2365a6));},AGIChannel['prototype'][_0xf0d966('0x30')]=function(_0x27f197){const _0x7d5c8=_0xf0d966;return _0x27f197=_0x27f197||_0x7d5c8('0x3f'),this[_0x7d5c8('0x3d')](util['format'](_0x7d5c8('0x32'),_0x27f197));},AGIChannel['prototype'][_0xf0d966('0x37')]=function(_0x54350f,_0x5f31a1){const _0x58228f=_0xf0d966;if(_[_0x58228f('0x46')](_0x5f31a1))return this[_0x58228f('0x3d')](util[_0x58228f('0x16')](_0x58228f('0x49'),_0x54350f,_0x5f31a1[_0x58228f('0x19')](',')));return this[_0x58228f('0x3d')](util['format'](_0x58228f('0x49'),_0x54350f,_0x5f31a1));},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x5')]=function(_0x264fcf){const _0x536ea4=_0xf0d966;return this[_0x536ea4('0x3d')](util[_0x536ea4('0x16')](_0x536ea4('0x6'),_0x264fcf));},AGIChannel[_0xf0d966('0x3')]['setExtension']=function(_0x104df3){const _0x1e0c2a=_0xf0d966;return this[_0x1e0c2a('0x3d')](util[_0x1e0c2a('0x16')](_0x1e0c2a('0x7'),_0x104df3));},AGIChannel['prototype']['setPriority']=function(_0x1a9b0b){const _0x30d4ff=_0xf0d966;return this['sendRequest'](util[_0x30d4ff('0x16')](_0x30d4ff('0x3c'),_0x1a9b0b));},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x26')]=function(){const _0x56cdc8=_0xf0d966;return this[_0x56cdc8('0x3d')](_0x56cdc8('0x47'));},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x1')]=function(_0x2dfea0,_0x3a8400){const _0x24fdc0=_0xf0d966,_0x45019d=_['isBoolean'](_0x3a8400)||_['isNumber'](_0x3a8400)?_0x3a8400[_0x24fdc0('0x2a')]():_0x3a8400;return this[_0x24fdc0('0x3d')](util['format'](_0x24fdc0('0x23'),_0x2dfea0,_0x45019d?_0x45019d[_0x24fdc0('0x2a')]()[_0x24fdc0('0x43')](/(\r\n|\n|\r)/gm,'\x20'):''));},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x1d')]=function(_0x3c8023,_0x36df8e){const _0x4b50a1=_0xf0d966;return this[_0x4b50a1('0x3d')](util[_0x4b50a1('0x16')](_0x4b50a1('0xd'),_0x3c8023,_0x36df8e));},AGIChannel['prototype'][_0xf0d966('0x29')]=function(_0x3cd5c4,_0x99a610){const _0x5cadb5=_0xf0d966;return this[_0x5cadb5('0x3d')](util[_0x5cadb5('0x16')]('SAY\x20DIGITS\x20%s\x20%s',_0x3cd5c4,_0x99a610));},AGIChannel[_0xf0d966('0x3')]['sayPhonetic']=function(_0x3d17d5,_0x466f3d){const _0x5400f2=_0xf0d966;return this[_0x5400f2('0x3d')](util[_0x5400f2('0x16')](_0x5400f2('0x10'),_0x3d17d5,_0x466f3d));},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x39')]=function(_0xa157a2,_0x55edbf,_0x24bdde){const _0x5e3aa9=_0xf0d966;return _0x55edbf=_0x55edbf||this[_0x5e3aa9('0x1b')],_0x24bdde=_0x24bdde||0x1,this[_0x5e3aa9('0x5')](_0xa157a2),this[_0x5e3aa9('0x11')](_0x55edbf),this['setPriority'](_0x24bdde),this[_0x5e3aa9('0x30')](util[_0x5e3aa9('0x16')]('GOTO\x20%s\x20%s\x20%s',_0xa157a2,_0x55edbf,_0x24bdde));},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x2c')]=function(_0x17a19c){const _0x103a09=_0xf0d966;return this[_0x103a09('0x3d')](util[_0x103a09('0x16')](_0x103a09('0x28'),_0x17a19c));},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0xa')]=function(_0x3fb667,_0x44c347,_0x37d14f,_0x562d1e,_0x38e587,_0x36686c){const _0x5808de=_0xf0d966;return _0x44c347=_0x44c347||_0x5808de('0xf'),_0x37d14f=_0x37d14f||'',_0x562d1e=_0x562d1e===undefined?-0x1:_0x562d1e==='-1'?-0x1:_0x562d1e*0x3e8,_0x38e587=_0x38e587===undefined?'':'s='+_0x38e587,_0x36686c=_0x36686c?'BEEP':'',this[_0x5808de('0x3d')](util[_0x5808de('0x16')]('RECORD\x20FILE\x20\x22%s\x22\x20\x22%s\x22\x20\x22%s\x22\x20%s\x20%s\x20%s',_0x3fb667,_0x44c347,_0x37d14f,_0x562d1e,_0x36686c,_0x38e587));},AGIChannel[_0xf0d966('0x3')]['streamFile']=function(_0x1dec72,_0x57d1e5){const _0x3ac5e4=_0xf0d966;return _0x57d1e5=_0x57d1e5||'',this[_0x3ac5e4('0x3d')](util[_0x3ac5e4('0x16')](_0x3ac5e4('0x40'),_0x1dec72,_0x57d1e5));},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x20')]=function(_0x304d62){const _0x3900a8=_0xf0d966;return this[_0x3900a8('0x37')]('AGI',_0x304d62);},AGIChannel[_0xf0d966('0x3')][_0xf0d966('0x1f')]=function(_0xdd4776){const _0xc70af=_0xf0d966;return this[_0xc70af('0x37')](_0xc70af('0x9'),_0xdd4776);},AGIChannel['prototype'][_0xf0d966('0x2d')]=function(_0x360ae3,_0x2eb576){const _0x34411c=_0xf0d966;return this[_0x34411c('0x30')](util['format'](_0x34411c('0xb'),_0x360ae3['id'],_0x360ae3[_0x34411c('0x0')],_0x2eb576)),{'code':0x1f4,'result':'-1','extra':''};},module[_0xf0d966('0x36')]=AGIChannel; \ No newline at end of file diff --git a/server/services/agi/error.js b/server/services/agi/error.js index 4afc2e3..5057467 100644 --- a/server/services/agi/error.js +++ b/server/services/agi/error.js @@ -1 +1 @@ -const a1027_0x1cda=['util','Argument\x20\x27port\x27\x20missing\x20in\x20function\x20call.','Socket\x20error.\x20Code:\x20%s.','Server\x20closed.','Socket\x20closed.','Missing\x20\x27ivr.entry\x27\x20menu.','format','apply','[LICENSE\x20VOICE]\x20Server\x20license\x20voice\x20disabled.','name','[LICENSE]\x20Server\x20max\x20connection.\x20Count:\x20%s.','push','Missing\x20\x27ivr.agi_network_script\x27.','exports','Server\x20error.\x20Code:\x20%s.','E_AGI_UNDEFINED','Empty\x20command.'];(function(_0x2ea395,_0x1cda34){const _0x4b7d3e=function(_0x38cc20){while(--_0x38cc20){_0x2ea395['push'](_0x2ea395['shift']());}};_0x4b7d3e(++_0x1cda34);}(a1027_0x1cda,0x115));const a1027_0x4b7d=function(_0x2ea395,_0x1cda34){_0x2ea395=_0x2ea395-0x0;let _0x4b7d3e=a1027_0x1cda[_0x2ea395];return _0x4b7d3e;};const _0x1b9f31=a1027_0x4b7d;'use strict';const util=require(_0x1b9f31('0xc')),error={'E_AGI_UNDEFINED':'Undefined\x20error.','E_AGI_ARGUMENT_PORT':_0x1b9f31('0xd'),'E_AGI_SERVER_ERROR':_0x1b9f31('0x9'),'E_AGI_SERVER_CLOSE':_0x1b9f31('0xf'),'E_AGI_SERVER_MAXCONNECTION':_0x1b9f31('0x5'),'E_AGI_SERVER_VOICE_DISABLED':_0x1b9f31('0x3'),'E_AGI_SOCKET_ERROR':_0x1b9f31('0xe'),'E_AGI_SOCKET_CLOSE':_0x1b9f31('0x10'),'E_AGI_SOCKET_TIMEOUT':'Socket\x20timeout.','E_AGI_COMMAND_EMPTY':_0x1b9f31('0xb'),'E_AGI_IVR_AGI_NETWORK_SCRIPT':_0x1b9f31('0x7'),'E_AGI_IVR_ENTRY':_0x1b9f31('0x0')};function AGIError(_0x38cc20){const _0x55bce9=_0x1b9f31;_0x38cc20=_0x38cc20||null;const _0x338655=_0x338655||[];let _0xc91bfd=0x1,_0x152525='';!error[_0x38cc20]&&(_0x38cc20=_0x55bce9('0xa'));_0x338655[_0x55bce9('0x6')](error[_0x38cc20]);while(arguments[_0xc91bfd]){_0x338655[_0x55bce9('0x6')](arguments[_0xc91bfd]),_0xc91bfd++;}_0x152525=util[_0x55bce9('0x1')][_0x55bce9('0x2')](util,_0x338655),this['message']=_0x152525,this[_0x55bce9('0x4')]=_0x38cc20;}module[_0x1b9f31('0x8')]=AGIError; \ No newline at end of file +const a1027_0x22b6=['message','Server\x20closed.','Socket\x20timeout.','Socket\x20error.\x20Code:\x20%s.','name','Undefined\x20error.','util','Server\x20error.\x20Code:\x20%s.','Missing\x20\x27ivr.agi_network_script\x27.','Argument\x20\x27port\x27\x20missing\x20in\x20function\x20call.','Empty\x20command.','format','E_AGI_UNDEFINED','push','[LICENSE\x20VOICE]\x20Server\x20license\x20voice\x20disabled.'];(function(_0x3e4ec2,_0x22b6a4){const _0xfd4dc5=function(_0x20ebf2){while(--_0x20ebf2){_0x3e4ec2['push'](_0x3e4ec2['shift']());}};_0xfd4dc5(++_0x22b6a4);}(a1027_0x22b6,0x14f));const a1027_0xfd4d=function(_0x3e4ec2,_0x22b6a4){_0x3e4ec2=_0x3e4ec2-0x0;let _0xfd4dc5=a1027_0x22b6[_0x3e4ec2];return _0xfd4dc5;};const _0x1f9c6f=a1027_0xfd4d;'use strict';const util=require(_0x1f9c6f('0x1')),error={'E_AGI_UNDEFINED':_0x1f9c6f('0x0'),'E_AGI_ARGUMENT_PORT':_0x1f9c6f('0x4'),'E_AGI_SERVER_ERROR':_0x1f9c6f('0x2'),'E_AGI_SERVER_CLOSE':_0x1f9c6f('0xb'),'E_AGI_SERVER_MAXCONNECTION':'[LICENSE]\x20Server\x20max\x20connection.\x20Count:\x20%s.','E_AGI_SERVER_VOICE_DISABLED':_0x1f9c6f('0x9'),'E_AGI_SOCKET_ERROR':_0x1f9c6f('0xd'),'E_AGI_SOCKET_CLOSE':'Socket\x20closed.','E_AGI_SOCKET_TIMEOUT':_0x1f9c6f('0xc'),'E_AGI_COMMAND_EMPTY':_0x1f9c6f('0x5'),'E_AGI_IVR_AGI_NETWORK_SCRIPT':_0x1f9c6f('0x3'),'E_AGI_IVR_ENTRY':'Missing\x20\x27ivr.entry\x27\x20menu.'};function AGIError(_0x20ebf2){const _0x350ff3=_0x1f9c6f;_0x20ebf2=_0x20ebf2||null;const _0x169c72=_0x169c72||[];let _0x5dbe5a=0x1,_0x4ff307='';!error[_0x20ebf2]&&(_0x20ebf2=_0x350ff3('0x7'));_0x169c72['push'](error[_0x20ebf2]);while(arguments[_0x5dbe5a]){_0x169c72[_0x350ff3('0x8')](arguments[_0x5dbe5a]),_0x5dbe5a++;}_0x4ff307=util[_0x350ff3('0x6')]['apply'](util,_0x169c72),this[_0x350ff3('0xa')]=_0x4ff307,this[_0x350ff3('0xe')]=_0x20ebf2;}module['exports']=AGIError; \ No newline at end of file diff --git a/server/services/agi/graph/index.js b/server/services/agi/graph/index.js index 8107090..ea6eb8c 100644 --- a/server/services/agi/graph/index.js +++ b/server/services/agi/graph/index.js @@ -1 +1 @@ -const a1028_0x268d=['no\x20edge/s\x20available','edges','default\x20on\x20switch\x20not\x20found','agi','condition\x20not\x20found','condition','vswitch','split','addEdge','size','info','getVertex','../../../config/logger','vertices','numberOfEdges','target','agicommand','length','relations','traverseBFS','max\x20retry\x20reach','invalid','addVertex','prototype','menu','no\x20vertex\x20found','stop\x20traverse'];(function(_0x311b83,_0x268d17){const _0x1f769f=function(_0x47b961){while(--_0x47b961){_0x311b83['push'](_0x311b83['shift']());}};_0x1f769f(++_0x268d17);}(a1028_0x268d,0x15e));const a1028_0x1f76=function(_0x311b83,_0x268d17){_0x311b83=_0x311b83-0x0;let _0x1f769f=a1028_0x268d[_0x311b83];return _0x1f769f;};const _0x528f69=a1028_0x1f76;'use strict';const _=require('lodash'),logger=require(_0x528f69('0xd'))(_0x528f69('0x4')),verticesWithRetry=[_0x528f69('0x19'),'getdigits','getsecretdigits'],Graph=function(){const _0x55ec8f=_0x528f69;this[_0x55ec8f('0xe')]={},this[_0x55ec8f('0x2')]={},this['numberOfEdges']=0x0;};Graph['prototype'][_0x528f69('0x17')]=function(_0x47b961){const _0x49b753=_0x528f69;this['vertices'][_0x47b961['id']]=_0x47b961,this[_0x49b753('0x2')][_0x47b961['id']]=[];},Graph[_0x528f69('0x18')][_0x528f69('0x9')]=function(_0x897a1,_0x396d92,_0x5584cd){const _0x6a7403=_0x528f69;this[_0x6a7403('0x2')][_0x897a1]['push']({'target':_0x396d92,'condition':_0x5584cd}),this['numberOfEdges']+=0x1;},Graph[_0x528f69('0x18')][_0x528f69('0xa')]=function(){const _0x41cd2a=_0x528f69;return _[_0x41cd2a('0xa')](this[_0x41cd2a('0xe')]);},Graph[_0x528f69('0x18')][_0x528f69('0x13')]=function(){const _0xabb0fd=_0x528f69;return this[_0xabb0fd('0xf')];},Graph[_0x528f69('0x18')][_0x528f69('0xc')]=function(_0x3f0bdb){const _0x1d68ae=_0x528f69;return this[_0x1d68ae('0xe')][_0x3f0bdb];},Graph[_0x528f69('0x18')][_0x528f69('0x14')]=function(_0x88943,_0xe23aea){const _0x22cf0d=_0x528f69;if(!this[_0x22cf0d('0xe')][_0x88943])return logger[_0x22cf0d('0xb')](_0x22cf0d('0x1a'));const _0x3123a3=_0xe23aea(this[_0x22cf0d('0xe')][_0x88943]);if(!_0x3123a3)return logger['info'](_0x22cf0d('0x0'));if(this[_0x22cf0d('0x2')][_0x88943][_0x22cf0d('0x12')]===0x0)return logger[_0x22cf0d('0xb')](_0x22cf0d('0x1'));const _0x265930=![],_0x283160=[];for(let _0x24ff79=0x0,_0x5705a0=[],_0x271ce5=![];_0x24ff79\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','lodash','Cally\x20Square\x20server\x20listening\x20on\x20port\x20%d!','[LISTENING]\x20Cally\x20Square\x20listening\x20%s:%d','target','[LICENSE]\x20CHANNELS:\x20%s','root','dnid','[GOTO]\x20context:\x20%s\x20extension:\x20%s\x20priority:\x20%s','stringify','stack','agicommand\x20not\x20found','then','agi_','./rpc','hangup','variables','omit','xml2json','mxCell','resolve','extension','substring','evtHangup','vertex','message','callysquare','[LICENSE]\x20CHANNELS:\x20UNLIMITED','finally','mxGraphModel','undefined','[LICENSE]','callerid','./vertices','../../config/logger','agicommand','start','isArray','source','toString','traverseBFS','code','uniqueid','addVertex','length','retry','sync','[START]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','[CLOSE]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','response','[LICENSE]\x20VOICE\x20IS\x20DISABLED','production','inspect','joinAt','[START\x20TRAVERSE]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','../../globals','maxRetry','continueAt','agi','[HANGUP]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','./server','name','addEdge','debug','info','context','getLicense','indexOf','127.0.0.1','createSquareReport','Project\x20%s\x20not\x20found','value','clear','YYYY-MM-DD\x20HH:mm:ss','priority','catch','gotoc'];(function(_0xe13b4e,_0x37e8f7){const _0x57750e=function(_0x60f612){while(--_0x60f612){_0xe13b4e['push'](_0xe13b4e['shift']());}};_0x57750e(++_0x37e8f7);}(a1029_0x37e8,0x73));const a1029_0x5775=function(_0xe13b4e,_0x37e8f7){_0xe13b4e=_0xe13b4e-0x0;let _0x57750e=a1029_0x37e8[_0xe13b4e];return _0x57750e;};const _0x2d83a2=a1029_0x5775;'use strict';require(_0x2d83a2('0x2d'));const parser=require(_0x2d83a2('0x8')),_=require(_0x2d83a2('0x52')),util=require(_0x2d83a2('0x4e')),moment=require('moment'),config=require(_0x2d83a2('0x4a')),logger=require(_0x2d83a2('0x18'))(_0x2d83a2('0x30')),utilLicense=require('../../config/license/util'),rpc=require(_0x2d83a2('0x4')),mailRpc=require('./mailRpc'),Graph=require(_0x2d83a2('0x49')),Vertices=require(_0x2d83a2('0x17')),AGI_CODE_SUCCESS=0xc8,AGI_RESULT_ERROR=-0x1;config['agi']=_['defaults'](config[_0x2d83a2('0x30')],{'ip':_0x2d83a2('0x3a'),'port':0x11dd});async function connectionHandler(_0x60f612){const _0x2f77f7=_0x2d83a2;try{await setChannelVariables(_0x60f612),await agiHandler(_0x60f612);}catch(_0x59ae5c){logger[_0x2f77f7('0x4b')](_0x59ae5c[_0x2f77f7('0x0')]);}}function listeningHandler(){const _0x74553f=_0x2d83a2;console[_0x74553f('0x50')](_0x74553f('0x53'),config[_0x74553f('0x30')]['port']),logger['info'](util[_0x74553f('0x44')](_0x74553f('0x54'),config[_0x74553f('0x30')]['ip'],config['agi']['port']));}function errorHandler(_0x3aca4b){const _0x341480=_0x2d83a2;_0x3aca4b&&_0x3aca4b[_0x341480('0x33')]&&_0x3aca4b[_0x341480('0xf')]?logger[_0x341480('0x4b')](util[_0x341480('0x44')]('[%s]\x20%s',_0x3aca4b[_0x341480('0x33')],_0x3aca4b[_0x341480('0xf')])):logger['error'](util[_0x341480('0x44')]('[ERROR]\x20%s',_0x3aca4b[_0x341480('0x0')]));}function closeHandler(){const _0x31eac9=_0x2d83a2;logger[_0x31eac9('0x36')](util[_0x31eac9('0x44')](_0x31eac9('0x26'),this[_0x31eac9('0x46')],this['calleridname'],this['callerid'],this[_0x31eac9('0x58')],this['uniqueid']));try{createSquareReport(this);}catch(_0x272e3a){logger[_0x31eac9('0x4b')](_0x272e3a[_0x31eac9('0x0')]);}}function timeoutHandler(){const _0x5f2de9=_0x2d83a2;logger[_0x5f2de9('0x36')](util['format']('[TIMEOUT]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s',this['arg_1'],this['calleridname'],this[_0x5f2de9('0x16')],this['dnid'],this[_0x5f2de9('0x20')]));}function hangupHandler(){const _0x56f2d8=_0x2d83a2;logger[_0x56f2d8('0x36')](util[_0x56f2d8('0x44')](_0x56f2d8('0x31'),this[_0x56f2d8('0x46')],this[_0x56f2d8('0x43')],this['callerid'],this['dnid'],this[_0x56f2d8('0x20')])),this['evtHangup']=!![];}function getRoot(_0x3f279d){const _0x3df077=_0x2d83a2;return parser['toJson'](_0x3f279d,{'object':!![]})[_0x3df077('0x13')]['root'];}function addVertex(_0x5d2dfc,_0x42bf35,_0x5cf32e){const _0x5069a3=_0x2d83a2;_0x42bf35[_0x5069a3('0x19')]=_0x5cf32e,typeof _0x42bf35[_0x5069a3('0x23')]!==_0x5069a3('0x14')&&(_0x42bf35[_0x5069a3('0x2e')]=parseInt(_0x42bf35[_0x5069a3('0x23')],0xa)),_0x5d2dfc[_0x5069a3('0x21')](_[_0x5069a3('0x7')](_0x42bf35,_0x5069a3('0x9')));}function initGraph(_0x3ddd88,_0xd7e312){const _0xa8db1b=_0x2d83a2,_0x2a01fc=new Graph();for(const _0x2916be in _0x3ddd88){if(typeof _0x3ddd88[_0x2916be]!==_0xa8db1b('0x14')){if(_[_0xa8db1b('0x1b')](_0x3ddd88[_0x2916be]))for(let _0x3d22e0=0x0;_0x3d22e0<_0x3ddd88[_0x2916be][_0xa8db1b('0x22')];_0x3d22e0+=0x1){addVertex(_0x2a01fc,_0x3ddd88[_0x2916be][_0x3d22e0],_0x2916be);}else addVertex(_0x2a01fc,_0x3ddd88[_0x2916be],_0x2916be);}}for(let _0x5e5a9e=0x0;_0x5e5a9e<_0xd7e312[_0xa8db1b('0x22')];_0x5e5a9e+=0x1){_0xd7e312[_0x5e5a9e][_0xa8db1b('0x1c')]&&_0xd7e312[_0x5e5a9e]['target']&&_0x2a01fc[_0xa8db1b('0x34')](_0xd7e312[_0x5e5a9e]['source'],_0xd7e312[_0x5e5a9e][_0xa8db1b('0x55')],_0xd7e312[_0x5e5a9e][_0xa8db1b('0x3d')]);}return _0x2a01fc;}function getSquareProject(_0x27c14d,_0x3411fe){const _0x1a2694=_0x2d83a2;rpc[_0x1a2694('0x48')](_0x27c14d)[_0x1a2694('0x2')](function(_0x15a042){_0x3411fe(null,_0x15a042);})[_0x1a2694('0x41')](function(_0xdacc94){_0x3411fe(null,_0xdacc94);});}function createSquareReport(_0x2cd4e7,_0x552830){const _0x1caeda=_0x2d83a2;rpc[_0x1caeda('0x3b')](_0x2cd4e7)[_0x1caeda('0x2')](function(_0x1416fa){_0x552830&&_0x552830(null,_0x1416fa);})[_0x1caeda('0x41')](function(_0x5567a1){_0x552830&&_0x552830(null,_0x5567a1);});}async function setChannelVariables(_0x4377bc){const _0x54be34=_0x2d83a2;for(const _0x23d832 in _0x4377bc){typeof _0x4377bc[_0x23d832]!==_0x54be34('0x14')&&(_0x23d832[_0x54be34('0x39')](_0x54be34('0x3'))===0x0&&(_0x4377bc[_0x23d832[_0x54be34('0xc')](0x4)]=_0x4377bc[_0x23d832],delete _0x4377bc[_0x23d832]));}return Promise[_0x54be34('0xa')](_0x4377bc);}function getLogFromObject(_0xc84850){const _0x56a8f1=_0x2d83a2;return util[_0x56a8f1('0x2a')](_0xc84850,{'showHidden':![],'depth':null});}async function agiHandler(_0x5a5d35){const _0x1b05e7=_0x2d83a2;let _0xc52ec0,_0x45224c,_0x5b4e9c,_0x1e4de3;logger['debug'](_0x1b05e7('0x6'),JSON['stringify'](_0x5a5d35,null,0x2)),logger[_0x1b05e7('0x36')](util['format'](_0x1b05e7('0x25'),_0x5a5d35[_0x1b05e7('0x46')],_0x5a5d35[_0x1b05e7('0x43')],_0x5a5d35[_0x1b05e7('0x16')],_0x5a5d35[_0x1b05e7('0x58')],_0x5a5d35[_0x1b05e7('0x20')])),_0x5a5d35['on'](_0x1b05e7('0x4b'),errorHandler),_0x5a5d35['on'](_0x1b05e7('0x4d'),closeHandler),_0x5a5d35['on'](_0x1b05e7('0x47'),timeoutHandler),_0x5a5d35[_0x1b05e7('0xd')]=![],_0x5a5d35['on'](_0x1b05e7('0x5'),hangupHandler);const _0x3d7811=getSquareProject[_0x1b05e7('0x24')](null,_0x5a5d35[_0x1b05e7('0x46')]);return _0x3d7811?_0x3d7811[_0x1b05e7('0x29')]?(_0xc52ec0=getRoot(_0x3d7811[_0x1b05e7('0x29')]),_0xc52ec0&&_0xc52ec0['start']&&(logger[_0x1b05e7('0x35')](_0x1b05e7('0x57'),JSON[_0x1b05e7('0x5a')](_0xc52ec0,null,0x2)),_0x5a5d35[_0x1b05e7('0x2b')]=moment()[_0x1b05e7('0x44')](_0x1b05e7('0x3f')),_0x45224c=initGraph(_[_0x1b05e7('0x7')](_0xc52ec0,_0x1b05e7('0x9')),_0xc52ec0[_0x1b05e7('0x9')]),_0x5b4e9c=new Vertices(_0x5a5d35,rpc,mailRpc),logger[_0x1b05e7('0x36')](util['format'](_0x1b05e7('0x2c'),_0x5a5d35[_0x1b05e7('0x46')],_0x5a5d35[_0x1b05e7('0x43')],_0x5a5d35[_0x1b05e7('0x16')],_0x5a5d35[_0x1b05e7('0x58')],_0x5a5d35['uniqueid'])),_0x45224c[_0x1b05e7('0x1e')](_0xc52ec0[_0x1b05e7('0x1a')]['id'],function(_0x586b35){const _0x437be9=_0x1b05e7;try{_0x586b35=_0x5b4e9c[_0x437be9('0x3e')](_0x586b35),logger[_0x437be9('0x35')](_0x437be9('0xe'),JSON[_0x437be9('0x5a')](_0x586b35,null,0x2));if(_0x586b35[_0x437be9('0x19')]===_0x437be9('0x42'))return logger[_0x437be9('0x36')]('gotoc\x20block\x20stop\x20traverse\x20BFS'),_0x5a5d35[_0x437be9('0x37')]=_0x586b35[_0x437be9('0x37')]||_0x5a5d35['context'],_0x5a5d35[_0x437be9('0xb')]=_0x586b35[_0x437be9('0xb')],_0x5a5d35[_0x437be9('0x40')]=_0x586b35[_0x437be9('0x40')]?_0x586b35[_0x437be9('0x40')]-0x1:0x1,null;else return _0x586b35&&_0x5b4e9c[_0x586b35['agicommand']]?(_0x1e4de3=_0x5b4e9c[_0x586b35[_0x437be9('0x19')]](_0x586b35),logger[_0x437be9('0x36')]('response',JSON[_0x437be9('0x5a')](_0x1e4de3,null,0x2)),_0x1e4de3&&_0x1e4de3[_0x437be9('0x1f')]===AGI_CODE_SUCCESS&&_0x1e4de3['result']!==AGI_RESULT_ERROR&&!_0x5a5d35[_0x437be9('0xd')]?(logger[_0x437be9('0x35')]('response',getLogFromObject(_0x1e4de3)),_['isUndefined'](_0x1e4de3[_0x437be9('0x45')])?null:_0x1e4de3[_0x437be9('0x45')]['toString']()):(logger[_0x437be9('0x4b')]('response',getLogFromObject(_0x1e4de3)),null)):(logger[_0x437be9('0x4b')](_0x437be9('0x1')),null);}catch(_0x5948b6){return logger['error'](_0x5948b6[_0x437be9('0x0')]),null;}}),_0xc52ec0[_0x1b05e7('0x12')]&&(logger[_0x1b05e7('0x36')](util['format'](_0x1b05e7('0x51'),_0x5a5d35[_0x1b05e7('0x46')],_0x5a5d35[_0x1b05e7('0x43')],_0x5a5d35[_0x1b05e7('0x16')],_0x5a5d35[_0x1b05e7('0x58')],_0x5a5d35[_0x1b05e7('0x20')])),_0x45224c['traverseBFS'](_0xc52ec0['finally']['id'],function(_0x333540){const _0x107ef2=_0x1b05e7;try{return _0x333540=_0x5b4e9c[_0x107ef2('0x3e')](_0x333540),logger[_0x107ef2('0x35')](_0x107ef2('0xe'),JSON[_0x107ef2('0x5a')](_0x333540,null,0x2)),_0x333540&&_0x5b4e9c[_0x333540[_0x107ef2('0x19')]]?(_0x1e4de3=_0x5b4e9c[_0x333540[_0x107ef2('0x19')]](_0x333540),_0x1e4de3?(logger['debug']('response',getLogFromObject(_0x1e4de3)),_[_0x107ef2('0x4c')](_0x1e4de3[_0x107ef2('0x45')])?null:_0x1e4de3[_0x107ef2('0x45')][_0x107ef2('0x1d')]()):(logger[_0x107ef2('0x4b')](_0x107ef2('0x27'),getLogFromObject(_0x1e4de3)),null)):(logger[_0x107ef2('0x4b')](_0x107ef2('0x1')),null);}catch(_0x421270){return logger[_0x107ef2('0x4b')](_0x421270[_0x107ef2('0x0')]),null;}})),logger[_0x1b05e7('0x36')](util[_0x1b05e7('0x44')]('[END]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s',_0x5a5d35['arg_1'],_0x5a5d35['calleridname'],_0x5a5d35['callerid'],_0x5a5d35['dnid'],_0x5a5d35[_0x1b05e7('0x20')])),logger[_0x1b05e7('0x36')](util[_0x1b05e7('0x44')](_0x1b05e7('0x59'),_0x5a5d35['context'],_0x5a5d35['extension'],parseInt(_0x5a5d35['priority'],0xa)+0x1)),_0x5a5d35[_0x1b05e7('0x2f')](_0x5a5d35[_0x1b05e7('0x37')],_0x5a5d35[_0x1b05e7('0xb')],parseInt(_0x5a5d35[_0x1b05e7('0x40')],0xa)+0x1),_0x5a5d35[_0x1b05e7('0x4d')]())):(logger[_0x1b05e7('0x4b')](util[_0x1b05e7('0x44')](_0x1b05e7('0x4f'),_0x5a5d35[_0x1b05e7('0x46')])),_0x5a5d35['continueAt'](_0x5a5d35[_0x1b05e7('0x37')],_0x5a5d35[_0x1b05e7('0xb')],parseInt(_0x5a5d35['priority'],0xa)+0x1),_0x5a5d35[_0x1b05e7('0x4d')]()):(logger[_0x1b05e7('0x4b')](util[_0x1b05e7('0x44')](_0x1b05e7('0x3c'),_0x5a5d35[_0x1b05e7('0x46')])),_0x5a5d35[_0x1b05e7('0x2f')](_0x5a5d35['context'],_0x5a5d35[_0x1b05e7('0xb')],parseInt(_0x5a5d35[_0x1b05e7('0x40')],0xa)+0x1),_0x5a5d35[_0x1b05e7('0x4d')]()),Promise[_0x1b05e7('0xa')]();}function main(){const _0x168be6=_0x2d83a2;let _0x8f945;return utilLicense[_0x168be6('0x38')]()[_0x168be6('0x2')](function(_0x203666){const _0x309807=_0x168be6;_0x203666&&(_0x203666['voice']?_0x203666['callysquare']&&_0x203666[_0x309807('0x10')]>0x0?(logger[_0x309807('0x36')](util[_0x309807('0x44')](_0x309807('0x56'),_0x203666[_0x309807('0x10')])),_0x8f945=_0x203666[_0x309807('0x10')]):logger['info'](_0x309807('0x11')):(logger[_0x309807('0x36')](_0x309807('0x28')),_0x8f945=-0x1));})[_0x168be6('0x41')](function(_0x168681){const _0x4e1b15=_0x168be6;logger[_0x4e1b15('0x4b')](_0x4e1b15('0x15'),_0x168681[_0x4e1b15('0x0')]);})[_0x168be6('0x12')](function(){const _0x4daa2a=_0x168be6,_0x379f74=require(_0x4daa2a('0x32'))(config[_0x4daa2a('0x30')]['port'],config[_0x4daa2a('0x30')]['ip'],_0x8f945);_0x379f74['on']('error',errorHandler),_0x379f74['on']('listening',listeningHandler),_0x379f74['on']('connection',connectionHandler),_0x379f74['on'](_0x4daa2a('0x4d'),closeHandler);});}main(); \ No newline at end of file +const a1029_0x3403=['Cally\x20Square\x20server\x20listening\x20on\x20port\x20%d!','callerid','format','debug','[CLOSE]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','substring','name','finally','evtHangup','[TIMEOUT]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','createSquareReport','port','127.0.0.1','callysquare','uniqueid','source','length','isUndefined','./mailRpc','start','../../config/license/util','../../config/logger','resolve','message','[FINALLY\x20TRAVERSE]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','YYYY-MM-DD\x20HH:mm:ss','gotoc','[START\x20TRAVERSE]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','isArray','[GOTO]\x20context:\x20%s\x20extension:\x20%s\x20priority:\x20%s','../../config/environment','catch','[HANGUP]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s','arg_1','toString','[LICENSE]','traverseBFS','inspect','dnid','connection','agicommand\x20not\x20found','info','[LICENSE]\x20CHANNELS:\x20%s','lodash','[%s]\x20%s','production','./vertices','agicommand','agi','./rpc','vertex','then','sync','joinAt','hangup','addEdge','undefined','[ERROR]\x20%s','moment','[LICENSE]\x20CHANNELS:\x20UNLIMITED','target','maxRetry','priority','mxCell','defaults','variables','Project\x20%s\x20not\x20found','omit','voice','value','stringify','response','mxGraphModel','context','root','log','calleridname','extension','./graph','retry','close','continueAt','toJson','[LISTENING]\x20Cally\x20Square\x20listening\x20%s:%d','result','getLicense','addVertex','error','stack'];(function(_0x35da60,_0x3403f7){const _0x45cabb=function(_0x151124){while(--_0x151124){_0x35da60['push'](_0x35da60['shift']());}};_0x45cabb(++_0x3403f7);}(a1029_0x3403,0x19b));const a1029_0x45ca=function(_0x35da60,_0x3403f7){_0x35da60=_0x35da60-0x0;let _0x45cabb=a1029_0x3403[_0x35da60];return _0x45cabb;};const _0x4aac99=a1029_0x45ca;'use strict';require('../../globals');const parser=require('xml2json'),_=require(_0x4aac99('0x4d')),util=require('util'),moment=require(_0x4aac99('0x3')),config=require(_0x4aac99('0x40')),logger=require(_0x4aac99('0x37'))(_0x4aac99('0x52')),utilLicense=require(_0x4aac99('0x36')),rpc=require(_0x4aac99('0x53')),mailRpc=require(_0x4aac99('0x34')),Graph=require(_0x4aac99('0x17')),Vertices=require(_0x4aac99('0x50')),AGI_CODE_SUCCESS=0xc8,AGI_RESULT_ERROR=-0x1;config['agi']=_[_0x4aac99('0x9')](config[_0x4aac99('0x52')],{'ip':_0x4aac99('0x2e'),'port':0x11dd});async function connectionHandler(_0x151124){const _0x55bd41=_0x4aac99;try{await setChannelVariables(_0x151124),await agiHandler(_0x151124);}catch(_0x207e9a){logger['error'](_0x207e9a[_0x55bd41('0x21')]);}}function listeningHandler(){const _0x130630=_0x4aac99;console[_0x130630('0x14')](_0x130630('0x22'),config[_0x130630('0x52')][_0x130630('0x2d')]),logger[_0x130630('0x4b')](util[_0x130630('0x24')](_0x130630('0x1c'),config[_0x130630('0x52')]['ip'],config[_0x130630('0x52')][_0x130630('0x2d')]));}function errorHandler(_0x1abd84){const _0x1a08e1=_0x4aac99;_0x1abd84&&_0x1abd84[_0x1a08e1('0x28')]&&_0x1abd84[_0x1a08e1('0x39')]?logger[_0x1a08e1('0x20')](util[_0x1a08e1('0x24')](_0x1a08e1('0x4e'),_0x1abd84[_0x1a08e1('0x28')],_0x1abd84[_0x1a08e1('0x39')])):logger['error'](util[_0x1a08e1('0x24')](_0x1a08e1('0x2'),_0x1abd84['stack']));}function closeHandler(){const _0x162380=_0x4aac99;logger[_0x162380('0x4b')](util[_0x162380('0x24')](_0x162380('0x26'),this[_0x162380('0x43')],this[_0x162380('0x15')],this[_0x162380('0x23')],this['dnid'],this[_0x162380('0x30')]));try{createSquareReport(this);}catch(_0x882c43){logger[_0x162380('0x20')](_0x882c43[_0x162380('0x21')]);}}function timeoutHandler(){const _0xf45875=_0x4aac99;logger[_0xf45875('0x4b')](util['format'](_0xf45875('0x2b'),this[_0xf45875('0x43')],this[_0xf45875('0x15')],this[_0xf45875('0x23')],this[_0xf45875('0x48')],this[_0xf45875('0x30')]));}function hangupHandler(){const _0xd20eea=_0x4aac99;logger[_0xd20eea('0x4b')](util['format'](_0xd20eea('0x42'),this[_0xd20eea('0x43')],this['calleridname'],this['callerid'],this[_0xd20eea('0x48')],this[_0xd20eea('0x30')])),this[_0xd20eea('0x2a')]=!![];}function getRoot(_0x37a999){const _0x2ff07b=_0x4aac99;return parser[_0x2ff07b('0x1b')](_0x37a999,{'object':!![]})[_0x2ff07b('0x11')][_0x2ff07b('0x13')];}function addVertex(_0x18023d,_0x231b34,_0x797fbb){const _0x315931=_0x4aac99;_0x231b34['agicommand']=_0x797fbb,typeof _0x231b34[_0x315931('0x18')]!==_0x315931('0x1')&&(_0x231b34[_0x315931('0x6')]=parseInt(_0x231b34[_0x315931('0x18')],0xa)),_0x18023d[_0x315931('0x1f')](_['omit'](_0x231b34,_0x315931('0x8')));}function initGraph(_0x506759,_0x27fd2e){const _0x73e77a=_0x4aac99,_0x11b069=new Graph();for(const _0x2e1c4b in _0x506759){if(typeof _0x506759[_0x2e1c4b]!==_0x73e77a('0x1')){if(_[_0x73e77a('0x3e')](_0x506759[_0x2e1c4b]))for(let _0x28b5c8=0x0;_0x28b5c8<_0x506759[_0x2e1c4b][_0x73e77a('0x32')];_0x28b5c8+=0x1){addVertex(_0x11b069,_0x506759[_0x2e1c4b][_0x28b5c8],_0x2e1c4b);}else addVertex(_0x11b069,_0x506759[_0x2e1c4b],_0x2e1c4b);}}for(let _0x24f3de=0x0;_0x24f3de<_0x27fd2e[_0x73e77a('0x32')];_0x24f3de+=0x1){_0x27fd2e[_0x24f3de][_0x73e77a('0x31')]&&_0x27fd2e[_0x24f3de]['target']&&_0x11b069[_0x73e77a('0x0')](_0x27fd2e[_0x24f3de]['source'],_0x27fd2e[_0x24f3de][_0x73e77a('0x5')],_0x27fd2e[_0x24f3de][_0x73e77a('0xe')]);}return _0x11b069;}function getSquareProject(_0x1bf851,_0x575e1d){const _0x50d628=_0x4aac99;rpc['getSquareProject'](_0x1bf851)[_0x50d628('0x55')](function(_0x15f3ce){_0x575e1d(null,_0x15f3ce);})[_0x50d628('0x41')](function(_0x11ed14){_0x575e1d(null,_0x11ed14);});}function createSquareReport(_0x15a226,_0x5ab1f7){const _0x1114cd=_0x4aac99;rpc[_0x1114cd('0x2c')](_0x15a226)['then'](function(_0x29367f){_0x5ab1f7&&_0x5ab1f7(null,_0x29367f);})['catch'](function(_0x6673b7){_0x5ab1f7&&_0x5ab1f7(null,_0x6673b7);});}async function setChannelVariables(_0x164dcb){const _0x43d791=_0x4aac99;for(const _0x240b3d in _0x164dcb){typeof _0x164dcb[_0x240b3d]!==_0x43d791('0x1')&&(_0x240b3d['indexOf']('agi_')===0x0&&(_0x164dcb[_0x240b3d[_0x43d791('0x27')](0x4)]=_0x164dcb[_0x240b3d],delete _0x164dcb[_0x240b3d]));}return Promise[_0x43d791('0x38')](_0x164dcb);}function getLogFromObject(_0x6b1b1d){const _0x56c5fb=_0x4aac99;return util[_0x56c5fb('0x47')](_0x6b1b1d,{'showHidden':![],'depth':null});}async function agiHandler(_0xfff34a){const _0xf233b9=_0x4aac99;let _0x3e70a,_0x5bffd8,_0x2789e2,_0x5c6bae;logger['debug'](_0xf233b9('0xa'),JSON[_0xf233b9('0xf')](_0xfff34a,null,0x2)),logger['info'](util[_0xf233b9('0x24')]('[START]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s',_0xfff34a[_0xf233b9('0x43')],_0xfff34a[_0xf233b9('0x15')],_0xfff34a['callerid'],_0xfff34a[_0xf233b9('0x48')],_0xfff34a[_0xf233b9('0x30')])),_0xfff34a['on'](_0xf233b9('0x20'),errorHandler),_0xfff34a['on'](_0xf233b9('0x19'),closeHandler),_0xfff34a['on']('timeout',timeoutHandler),_0xfff34a[_0xf233b9('0x2a')]=![],_0xfff34a['on'](_0xf233b9('0x58'),hangupHandler);const _0x2e4eb9=getSquareProject[_0xf233b9('0x56')](null,_0xfff34a[_0xf233b9('0x43')]);return _0x2e4eb9?_0x2e4eb9[_0xf233b9('0x4f')]?(_0x3e70a=getRoot(_0x2e4eb9[_0xf233b9('0x4f')]),_0x3e70a&&_0x3e70a[_0xf233b9('0x35')]&&(logger[_0xf233b9('0x25')](_0xf233b9('0x13'),JSON[_0xf233b9('0xf')](_0x3e70a,null,0x2)),_0xfff34a[_0xf233b9('0x57')]=moment()[_0xf233b9('0x24')](_0xf233b9('0x3b')),_0x5bffd8=initGraph(_[_0xf233b9('0xc')](_0x3e70a,'mxCell'),_0x3e70a[_0xf233b9('0x8')]),_0x2789e2=new Vertices(_0xfff34a,rpc,mailRpc),logger[_0xf233b9('0x4b')](util['format'](_0xf233b9('0x3d'),_0xfff34a[_0xf233b9('0x43')],_0xfff34a['calleridname'],_0xfff34a[_0xf233b9('0x23')],_0xfff34a['dnid'],_0xfff34a[_0xf233b9('0x30')])),_0x5bffd8['traverseBFS'](_0x3e70a[_0xf233b9('0x35')]['id'],function(_0x2c0add){const _0x5a9d75=_0xf233b9;try{_0x2c0add=_0x2789e2['clear'](_0x2c0add),logger[_0x5a9d75('0x25')](_0x5a9d75('0x54'),JSON[_0x5a9d75('0xf')](_0x2c0add,null,0x2));if(_0x2c0add[_0x5a9d75('0x51')]===_0x5a9d75('0x3c'))return logger[_0x5a9d75('0x4b')]('gotoc\x20block\x20stop\x20traverse\x20BFS'),_0xfff34a[_0x5a9d75('0x12')]=_0x2c0add[_0x5a9d75('0x12')]||_0xfff34a[_0x5a9d75('0x12')],_0xfff34a[_0x5a9d75('0x16')]=_0x2c0add[_0x5a9d75('0x16')],_0xfff34a['priority']=_0x2c0add[_0x5a9d75('0x7')]?_0x2c0add[_0x5a9d75('0x7')]-0x1:0x1,null;else return _0x2c0add&&_0x2789e2[_0x2c0add[_0x5a9d75('0x51')]]?(_0x5c6bae=_0x2789e2[_0x2c0add['agicommand']](_0x2c0add),logger[_0x5a9d75('0x4b')](_0x5a9d75('0x10'),JSON[_0x5a9d75('0xf')](_0x5c6bae,null,0x2)),_0x5c6bae&&_0x5c6bae['code']===AGI_CODE_SUCCESS&&_0x5c6bae[_0x5a9d75('0x1d')]!==AGI_RESULT_ERROR&&!_0xfff34a[_0x5a9d75('0x2a')]?(logger[_0x5a9d75('0x25')](_0x5a9d75('0x10'),getLogFromObject(_0x5c6bae)),_[_0x5a9d75('0x33')](_0x5c6bae[_0x5a9d75('0x1d')])?null:_0x5c6bae[_0x5a9d75('0x1d')][_0x5a9d75('0x44')]()):(logger[_0x5a9d75('0x20')](_0x5a9d75('0x10'),getLogFromObject(_0x5c6bae)),null)):(logger[_0x5a9d75('0x20')](_0x5a9d75('0x4a')),null);}catch(_0x19e650){return logger['error'](_0x19e650[_0x5a9d75('0x21')]),null;}}),_0x3e70a[_0xf233b9('0x29')]&&(logger[_0xf233b9('0x4b')](util['format'](_0xf233b9('0x3a'),_0xfff34a['arg_1'],_0xfff34a['calleridname'],_0xfff34a[_0xf233b9('0x23')],_0xfff34a[_0xf233b9('0x48')],_0xfff34a[_0xf233b9('0x30')])),_0x5bffd8[_0xf233b9('0x46')](_0x3e70a['finally']['id'],function(_0x98a7bb){const _0x3afa0c=_0xf233b9;try{return _0x98a7bb=_0x2789e2['clear'](_0x98a7bb),logger['debug'](_0x3afa0c('0x54'),JSON[_0x3afa0c('0xf')](_0x98a7bb,null,0x2)),_0x98a7bb&&_0x2789e2[_0x98a7bb[_0x3afa0c('0x51')]]?(_0x5c6bae=_0x2789e2[_0x98a7bb[_0x3afa0c('0x51')]](_0x98a7bb),_0x5c6bae?(logger[_0x3afa0c('0x25')](_0x3afa0c('0x10'),getLogFromObject(_0x5c6bae)),_[_0x3afa0c('0x33')](_0x5c6bae['result'])?null:_0x5c6bae[_0x3afa0c('0x1d')][_0x3afa0c('0x44')]()):(logger[_0x3afa0c('0x20')](_0x3afa0c('0x10'),getLogFromObject(_0x5c6bae)),null)):(logger['error']('agicommand\x20not\x20found'),null);}catch(_0xf8e2bb){return logger['error'](_0xf8e2bb[_0x3afa0c('0x21')]),null;}})),logger[_0xf233b9('0x4b')](util[_0xf233b9('0x24')]('[END]\x20%s\x20project:\x20from\x20\x22%s\x22\x20<%s>\x20to\x20extension\x20%s\x20with\x20uniqueid\x20%s',_0xfff34a[_0xf233b9('0x43')],_0xfff34a['calleridname'],_0xfff34a[_0xf233b9('0x23')],_0xfff34a[_0xf233b9('0x48')],_0xfff34a[_0xf233b9('0x30')])),logger[_0xf233b9('0x4b')](util[_0xf233b9('0x24')](_0xf233b9('0x3f'),_0xfff34a[_0xf233b9('0x12')],_0xfff34a[_0xf233b9('0x16')],parseInt(_0xfff34a['priority'],0xa)+0x1)),_0xfff34a[_0xf233b9('0x1a')](_0xfff34a['context'],_0xfff34a[_0xf233b9('0x16')],parseInt(_0xfff34a['priority'],0xa)+0x1),_0xfff34a[_0xf233b9('0x19')]())):(logger[_0xf233b9('0x20')](util[_0xf233b9('0x24')]('Project\x20%s\x20not\x20published',_0xfff34a[_0xf233b9('0x43')])),_0xfff34a[_0xf233b9('0x1a')](_0xfff34a['context'],_0xfff34a[_0xf233b9('0x16')],parseInt(_0xfff34a[_0xf233b9('0x7')],0xa)+0x1),_0xfff34a['close']()):(logger[_0xf233b9('0x20')](util['format'](_0xf233b9('0xb'),_0xfff34a[_0xf233b9('0x43')])),_0xfff34a[_0xf233b9('0x1a')](_0xfff34a[_0xf233b9('0x12')],_0xfff34a[_0xf233b9('0x16')],parseInt(_0xfff34a[_0xf233b9('0x7')],0xa)+0x1),_0xfff34a[_0xf233b9('0x19')]()),Promise['resolve']();}function main(){const _0x164c16=_0x4aac99;let _0x3605fe;return utilLicense[_0x164c16('0x1e')]()[_0x164c16('0x55')](function(_0x35eee9){const _0x114b49=_0x164c16;_0x35eee9&&(_0x35eee9[_0x114b49('0xd')]?_0x35eee9['callysquare']&&_0x35eee9['callysquare']>0x0?(logger['info'](util[_0x114b49('0x24')](_0x114b49('0x4c'),_0x35eee9['callysquare'])),_0x3605fe=_0x35eee9[_0x114b49('0x2f')]):logger[_0x114b49('0x4b')](_0x114b49('0x4')):(logger[_0x114b49('0x4b')]('[LICENSE]\x20VOICE\x20IS\x20DISABLED'),_0x3605fe=-0x1));})[_0x164c16('0x41')](function(_0x3fd769){const _0x5b47b3=_0x164c16;logger[_0x5b47b3('0x20')](_0x5b47b3('0x45'),_0x3fd769[_0x5b47b3('0x21')]);})[_0x164c16('0x29')](function(){const _0x5201dc=_0x164c16,_0x2ca8ea=require('./server')(config[_0x5201dc('0x52')][_0x5201dc('0x2d')],config[_0x5201dc('0x52')]['ip'],_0x3605fe);_0x2ca8ea['on']('error',errorHandler),_0x2ca8ea['on']('listening',listeningHandler),_0x2ca8ea['on'](_0x5201dc('0x49'),connectionHandler),_0x2ca8ea['on']('close',closeHandler);});}main(); \ No newline at end of file diff --git a/server/services/agi/mailRpc/index.js b/server/services/agi/mailRpc/index.js index a39e005..c992231 100644 --- a/server/services/agi/mailRpc/index.js +++ b/server/services/agi/mailRpc/index.js @@ -1 +1 @@ -const a1030_0x1883=['client','result','message','jayson/promise','catch','request','error'];(function(_0x27db0f,_0x1883f5){const _0x8cbc50=function(_0x5d7337){while(--_0x5d7337){_0x27db0f['push'](_0x27db0f['shift']());}};_0x8cbc50(++_0x1883f5);}(a1030_0x1883,0x67));const a1030_0x8cbc=function(_0x27db0f,_0x1883f5){_0x27db0f=_0x27db0f-0x0;let _0x8cbc50=a1030_0x1883[_0x27db0f];return _0x8cbc50;};const _0x14ea5b=a1030_0x8cbc;'use strict';const jayson=require(_0x14ea5b('0x5')),client=jayson[_0x14ea5b('0x2')]['http']({'port':0x232b});function request(_0x5d7337,_0x180c89){return new Promise(function(_0x56ee3d,_0x57eb65){const _0xdac393=a1030_0x8cbc;return client[_0xdac393('0x0')](_0x5d7337,_0x180c89)['then'](function(_0x4082e8){const _0xc7db0f=_0xdac393;return _0x4082e8[_0xc7db0f('0x1')]?_0x57eb65(_0x4082e8[_0xc7db0f('0x1')][_0xc7db0f('0x4')]):_0x56ee3d(_0x4082e8[_0xc7db0f('0x3')]);})[_0xdac393('0x6')](function(_0x1ae3f6){return _0x57eb65(_0x1ae3f6);});});}exports['sendMailMessage']=function(_0x22b679,_0x3f63ab){return request('SendMail',{'account':_0x22b679,'message':_0x3f63ab});}; \ No newline at end of file +const a1030_0x4366=['SendMail','catch','sendMailMessage','message','then','jayson/promise','error','request','client','result'];(function(_0xb4a4e2,_0x43661a){const _0x4d92ef=function(_0x312cee){while(--_0x312cee){_0xb4a4e2['push'](_0xb4a4e2['shift']());}};_0x4d92ef(++_0x43661a);}(a1030_0x4366,0xfe));const a1030_0x4d92=function(_0xb4a4e2,_0x43661a){_0xb4a4e2=_0xb4a4e2-0x0;let _0x4d92ef=a1030_0x4366[_0xb4a4e2];return _0x4d92ef;};const _0x57c68f=a1030_0x4d92;'use strict';const jayson=require(_0x57c68f('0x1')),client=jayson[_0x57c68f('0x4')]['http']({'port':0x232b});function request(_0x312cee,_0x26ddbd){return new Promise(function(_0x54a5f9,_0x4f1b6e){const _0x337235=a1030_0x4d92;return client[_0x337235('0x3')](_0x312cee,_0x26ddbd)[_0x337235('0x0')](function(_0x30ea04){const _0x4de42a=_0x337235;return _0x30ea04['error']?_0x4f1b6e(_0x30ea04[_0x4de42a('0x2')][_0x4de42a('0x9')]):_0x54a5f9(_0x30ea04[_0x4de42a('0x5')]);})[_0x337235('0x7')](function(_0x56bcb8){return _0x4f1b6e(_0x56bcb8);});});}exports[_0x57c68f('0x8')]=function(_0x4b1b32,_0x2fad52){const _0x39b167=_0x57c68f;return request(_0x39b167('0x6'),{'account':_0x4b1b32,'message':_0x2fad52});}; \ No newline at end of file diff --git a/server/services/agi/reply.js b/server/services/agi/reply.js index 29be0f4..0d3408e 100644 --- a/server/services/agi/reply.js +++ b/server/services/agi/reply.js @@ -1 +1 @@ -const a1031_0x50b2=['line','util','\x0d\x0a\x0d\x0a','_transform','exports','emit','_localBuffer','substring','slice','trim','length','toString','headers','_inBody','indexOf','stream','inherits'];(function(_0x5ef4dd,_0x50b2c7){const _0x3e88bd=function(_0x9b6d04){while(--_0x9b6d04){_0x5ef4dd['push'](_0x5ef4dd['shift']());}};_0x3e88bd(++_0x50b2c7);}(a1031_0x50b2,0xf1));const a1031_0x3e88=function(_0x5ef4dd,_0x50b2c7){_0x5ef4dd=_0x5ef4dd-0x0;let _0x3e88bd=a1031_0x50b2[_0x5ef4dd];return _0x3e88bd;};const _0x24ab52=a1031_0x3e88;'use strict';const util=require(_0x24ab52('0xf')),Transform=require(_0x24ab52('0xc'))['Transform'];function AGIReply(_0x9b6d04){const _0x5110c0=_0x24ab52;Transform['call'](this,_0x9b6d04),this[_0x5110c0('0x3')]='',this[_0x5110c0('0xa')]=![];}util[_0x24ab52('0xd')](AGIReply,Transform),AGIReply['prototype'][_0x24ab52('0x0')]=function(_0x3552a6,_0x251339,_0x28eb1a){const _0x46d64f=_0x24ab52,_0x3ee22f='\x0a',_0x8f0107=['\x0a\x0a',_0x46d64f('0x10')];let _0x2aa7c4=-0x1,_0x124f30=-0x1,_0x551f4b='',_0xe8ba5c=0x0,_0x4088d3='',_0x170434='';this[_0x46d64f('0x3')]+=_0x3552a6[_0x46d64f('0x8')](),_0x4088d3=this[_0x46d64f('0x3')];if(!this[_0x46d64f('0xa')]){_0xe8ba5c=0x0;while(_0x8f0107[_0xe8ba5c]){while((_0x124f30=_0x4088d3[_0x46d64f('0xb')](_0x8f0107[_0xe8ba5c]))!=-0x1){_0x551f4b=_0x8f0107[_0xe8ba5c],_0x170434=_0x4088d3['substring'](0x0,_0x124f30),_0x4088d3=_0x4088d3[_0x46d64f('0x4')](_0x124f30+_0x551f4b[_0x46d64f('0x7')]);const _0x56af03=_0x170434['split'](_0x3ee22f);let _0x5015fe=0x0;const _0x5ef361={};let _0x3745f2='',_0x3c71b6='',_0x313ecf=-0x1;while(_0x56af03[_0x5015fe]){_0x313ecf=_0x56af03[_0x5015fe]['indexOf'](':');if(_0x313ecf!=-0x1)_0x3745f2=_0x56af03[_0x5015fe][_0x46d64f('0x5')](0x0,_0x313ecf)['trim'](),_0x3c71b6=_0x56af03[_0x5015fe]['slice'](_0x313ecf+0x1)[_0x46d64f('0x6')](),_0x3745f2[_0x46d64f('0x7')]>0x0&&(_0x5ef361[_0x3745f2]=_0x3c71b6);else{}_0x5015fe++;}this[_0x46d64f('0x2')](_0x46d64f('0x9'),_0x5ef361),this[_0x46d64f('0xa')]=!![];}_0xe8ba5c++;}this[_0x46d64f('0x3')]=_0x4088d3;}else{while((_0x2aa7c4=_0x4088d3[_0x46d64f('0xb')](_0x3ee22f))!=-0x1){_0x170434=_0x4088d3['substring'](0x0,_0x2aa7c4),this[_0x46d64f('0x2')](_0x46d64f('0xe'),_0x170434),_0x4088d3=_0x4088d3[_0x46d64f('0x4')](_0x2aa7c4+_0x3ee22f[_0x46d64f('0x7')]);}this['_localBuffer']=_0x4088d3;}_0x28eb1a();},module[_0x24ab52('0x1')]=AGIReply; \ No newline at end of file +const a1031_0x45f2=['prototype','exports','stream','\x0d\x0a\x0d\x0a','substring','indexOf','headers','length','call','_localBuffer','toString','inherits','emit','util','_inBody','trim','_transform','slice'];(function(_0x4f42cd,_0x45f22c){const _0x29067d=function(_0x79a4a0){while(--_0x79a4a0){_0x4f42cd['push'](_0x4f42cd['shift']());}};_0x29067d(++_0x45f22c);}(a1031_0x45f2,0x1c3));const a1031_0x2906=function(_0x4f42cd,_0x45f22c){_0x4f42cd=_0x4f42cd-0x0;let _0x29067d=a1031_0x45f2[_0x4f42cd];return _0x29067d;};const _0x450157=a1031_0x2906;'use strict';const util=require(_0x450157('0xc')),Transform=require(_0x450157('0x1'))['Transform'];function AGIReply(_0x79a4a0){const _0x5bdaf8=_0x450157;Transform[_0x5bdaf8('0x7')](this,_0x79a4a0),this[_0x5bdaf8('0x8')]='',this['_inBody']=![];}util[_0x450157('0xa')](AGIReply,Transform),AGIReply[_0x450157('0x11')][_0x450157('0xf')]=function(_0x45bab1,_0x45c5e0,_0x264a1a){const _0x4c5ddf=_0x450157,_0x2f8985='\x0a',_0xf64fd7=['\x0a\x0a',_0x4c5ddf('0x2')];let _0x3da969=-0x1,_0x31bbeb=-0x1,_0xf05742='',_0x5076d2=0x0,_0x7f6280='',_0x63e72b='';this[_0x4c5ddf('0x8')]+=_0x45bab1[_0x4c5ddf('0x9')](),_0x7f6280=this[_0x4c5ddf('0x8')];if(!this[_0x4c5ddf('0xd')]){_0x5076d2=0x0;while(_0xf64fd7[_0x5076d2]){while((_0x31bbeb=_0x7f6280['indexOf'](_0xf64fd7[_0x5076d2]))!=-0x1){_0xf05742=_0xf64fd7[_0x5076d2],_0x63e72b=_0x7f6280[_0x4c5ddf('0x3')](0x0,_0x31bbeb),_0x7f6280=_0x7f6280['substring'](_0x31bbeb+_0xf05742[_0x4c5ddf('0x6')]);const _0x1ed006=_0x63e72b['split'](_0x2f8985);let _0x324d2b=0x0;const _0x4b479f={};let _0x4febfa='',_0x13111a='',_0x450ae6=-0x1;while(_0x1ed006[_0x324d2b]){_0x450ae6=_0x1ed006[_0x324d2b][_0x4c5ddf('0x4')](':');if(_0x450ae6!=-0x1)_0x4febfa=_0x1ed006[_0x324d2b][_0x4c5ddf('0x10')](0x0,_0x450ae6)[_0x4c5ddf('0xe')](),_0x13111a=_0x1ed006[_0x324d2b][_0x4c5ddf('0x10')](_0x450ae6+0x1)[_0x4c5ddf('0xe')](),_0x4febfa['length']>0x0&&(_0x4b479f[_0x4febfa]=_0x13111a);else{}_0x324d2b++;}this[_0x4c5ddf('0xb')](_0x4c5ddf('0x5'),_0x4b479f),this['_inBody']=!![];}_0x5076d2++;}this[_0x4c5ddf('0x8')]=_0x7f6280;}else{while((_0x3da969=_0x7f6280[_0x4c5ddf('0x4')](_0x2f8985))!=-0x1){_0x63e72b=_0x7f6280[_0x4c5ddf('0x3')](0x0,_0x3da969),this[_0x4c5ddf('0xb')]('line',_0x63e72b),_0x7f6280=_0x7f6280[_0x4c5ddf('0x3')](_0x3da969+_0x2f8985['length']);}this['_localBuffer']=_0x7f6280;}_0x264a1a();},module[_0x450157('0x0')]=AGIReply; \ No newline at end of file diff --git a/server/services/agi/rpc/index.js b/server/services/agi/rpc/index.js index f662d11..8aeb083 100644 --- a/server/services/agi/rpc/index.js +++ b/server/services/agi/rpc/index.js @@ -1 +1 @@ -const a1032_0x5382=['CreateSquareRecording','createSquareReport','createSquareDetailsReport','result','getSoundById','ShowUser','getSmsAccountById','getSquareProjectById','createSquareMessage','format','getIntervalById','ListId','lodash','moment','getPauseById','getMailAccountById','merge','ShowTrunk','catch','createCmContact','UnpauseUser','CreateSmsMessage','CreateSquareDetailsReport','getUserById','Intervals','agentLogout','http','getVoiceQueueById','CreateCmContact','Interval','arg_2','client','agentLogin','then','jayson/promise','YYYY-MM-DD\x20HH:mm:ss','PauseUser','ShowInterval','ShowVoiceQueue','error','agentPause','CreateSquareReport','message','LoginUser','phone','MailServerOut','name','Smtp','ShowSquareProject','CreateSquareMessage','getSquareOdbcById'];(function(_0x18416b,_0x5382b1){const _0x1dbeb4=function(_0x36aed8){while(--_0x36aed8){_0x18416b['push'](_0x18416b['shift']());}};_0x1dbeb4(++_0x5382b1);}(a1032_0x5382,0x69));const a1032_0x1dbe=function(_0x18416b,_0x5382b1){_0x18416b=_0x18416b-0x0;let _0x1dbeb4=a1032_0x5382[_0x18416b];return _0x1dbeb4;};const _0x5356b0=a1032_0x1dbe;'use strict';const moment=require(_0x5356b0('0xa')),_=require(_0x5356b0('0x9')),jayson=require(_0x5356b0('0x1f')),client=jayson[_0x5356b0('0x1c')][_0x5356b0('0x17')]({'port':0x2329});function request(_0x36aed8,_0x35584f){return new Promise(function(_0x3e5bbc,_0x5b6f58){const _0xb6bc1=a1032_0x1dbe;return client['request'](_0x36aed8,_0x35584f)['then'](function(_0x9e515d){const _0x3b3c90=a1032_0x1dbe;return _0x9e515d[_0x3b3c90('0x24')]?_0x5b6f58(_0x9e515d[_0x3b3c90('0x24')][_0x3b3c90('0x27')]):_0x3e5bbc(_0x9e515d[_0x3b3c90('0x0')]);})[_0xb6bc1('0xf')](function(_0x474a65){return _0x5b6f58(_0x474a65);});});}exports['getSquareProject']=function(_0x2af78d){const _0x3dfb19=_0x5356b0;return request(_0x3dfb19('0x2d'),{'options':{'raw':![],'where':{'name':_0x2af78d},'attributes':['production']}});},exports[_0x5356b0('0xc')]=function(_0x17f4cd){const _0xc739a1=_0x5356b0;return request('ShowMailAccount',{'options':{'raw':![],'where':{'id':_0x17f4cd},'include':[{'model':_0xc739a1('0x2a'),'as':_0xc739a1('0x2c')}],'attributes':['id',_0xc739a1('0x2b'),'email']}});},exports[_0x5356b0('0x4')]=function(_0x3b7be1){const _0x1c1429=_0x5356b0;return request(_0x1c1429('0x2d'),{'options':{'where':{'id':_0x3b7be1},'attributes':[_0x1c1429('0x2b')]}});},exports[_0x5356b0('0x18')]=function(_0x1062ea){const _0x251f6f=_0x5356b0;return request(_0x251f6f('0x23'),{'options':{'where':{'id':_0x1062ea},'attributes':[_0x251f6f('0x2b')]}});},exports['getVariableById']=function(_0x25a029){const _0x256112=_0x5356b0;return request('ShowVariable',{'options':{'where':{'id':_0x25a029},'attributes':[_0x256112('0x2b')]}});},exports[_0x5356b0('0x2f')]=function(_0x57a851){return request('ShowSquareOdbc',{'options':{'where':{'id':_0x57a851},'attributes':['dsn']}});},exports[_0x5356b0('0x14')]=function(_0x394c8d){const _0x579da2=_0x5356b0;return request(_0x579da2('0x2'),{'options':{'where':{'id':_0x394c8d},'attributes':[_0x579da2('0x2b')]}});},exports['getTrunkById']=function(_0x12f453){const _0x40af4b=_0x5356b0;return request(_0x40af4b('0xe'),{'options':{'where':{'id':_0x12f453},'attributes':[_0x40af4b('0x2b')]}});},exports[_0x5356b0('0x1')]=function(_0x289f49){return request('ShowSound',{'options':{'where':{'id':_0x289f49},'attributes':['save_name']}});},exports[_0x5356b0('0x7')]=function(_0x519a20){const _0x36cacc=_0x5356b0;return request(_0x36cacc('0x22'),{'options':{'raw':![],'where':{'id':_0x519a20},'include':[{'model':_0x36cacc('0x1a'),'as':_0x36cacc('0x15')}]}});},exports[_0x5356b0('0x3')]=function(_0x3e1f6c){const _0x9f7b8e=_0x5356b0;return request('ShowSmsAccount',{'options':{'where':{'id':_0x3e1f6c},'attributes':['id',_0x9f7b8e('0x2b')]}});},exports['createSmsMessage']=function(_0x42362b){const _0x375b7b=_0x5356b0;return request(_0x375b7b('0x12'),{'body':_0x42362b});},exports[_0x5356b0('0x32')]=function(_0x54dbf3){const _0xcfa158=_0x5356b0;return request(_0xcfa158('0x13'),{'body':_0x54dbf3});},exports[_0x5356b0('0x31')]=function(_0x39d7c0){const _0x382563=_0x5356b0;return request(_0x382563('0x26'),{'body':_[_0x382563('0xd')](_0x39d7c0,{'project_name':_0x39d7c0['arg_1'],'prev_project_name':_0x39d7c0['arg_2']||'','is_subproject':_0x39d7c0[_0x382563('0x1b')]?!![]:![],'leaveAt':moment()[_0x382563('0x6')](_0x382563('0x20'))})});},exports['createSquareRecording']=function(_0x282658){const _0x4ef3fa=_0x5356b0;return request(_0x4ef3fa('0x30'),{'body':_0x282658});},exports[_0x5356b0('0x5')]=function(_0x149953){const _0x2221d1=_0x5356b0;return request(_0x2221d1('0x2e'),{'body':_0x149953});},exports[_0x5356b0('0x10')]=function(_0x30afb1){const _0xfb54d2=_0x5356b0;return request('ShowCmHopper',{'options':{'raw':![],'where':{'phone':_0x30afb1[_0xfb54d2('0x29')],'ListId':_0x30afb1[_0xfb54d2('0x8')]}}})[_0xfb54d2('0x1e')](function(_0x29673c){const _0x2c0e2f=_0xfb54d2;if(_0x29673c)return _0x29673c;return request(_0x2c0e2f('0x19'),{'body':_0x30afb1});});},exports[_0x5356b0('0xb')]=function(_0x57c978){const _0x5c1e49=_0x5356b0;return request('ShowPause',{'options':{'where':{'id':_0x57c978},'attributes':[_0x5c1e49('0x2b')]}});},exports[_0x5356b0('0x1d')]=function(_0x2d11eb,_0x115323){const _0x3b945c=_0x5356b0;return request(_0x3b945c('0x28'),{'body':{'interface':_0x115323},'options':{'where':_0x2d11eb}});},exports[_0x5356b0('0x25')]=function(_0x4fa82c,_0x1af1b2,_0x312e5e){const _0x2f6f5e=_0x5356b0;return request(_0x2f6f5e('0x21'),{'body':{'type':_0x1af1b2,'uniqueid':_0x312e5e},'options':{'where':_0x4fa82c}});},exports['agentUnpause']=function(_0x58ae79){const _0x25ac0c=_0x5356b0;return request(_0x25ac0c('0x11'),{'body':{},'options':{'where':_0x58ae79}});},exports[_0x5356b0('0x16')]=function(_0x344205){return request('LogoutUser',{'body':{},'options':{'where':_0x344205}});}; \ No newline at end of file +const a1032_0x262c=['CreateSquareMessage','createSquareDetailsReport','createSquareReport','getSquareProjectById','ShowSmsAccount','ShowCmHopper','CreateSquareReport','agentLogin','dsn','CreateSquareDetailsReport','jayson/promise','createSquareMessage','ShowUser','createCmContact','ShowVariable','moment','email','lodash','getSquareProject','catch','agentLogout','ShowPause','arg_1','agentUnpause','ListId','CreateSquareRecording','getTrunkById','production','name','getPauseById','CreateSmsMessage','message','ShowInterval','PauseUser','getVariableById','getSoundById','ShowVoiceQueue','YYYY-MM-DD\x20HH:mm:ss','getIntervalById','save_name','ShowSound','ShowSquareProject','format','error','arg_2','ShowSquareOdbc','MailServerOut','getVoiceQueueById','getUserById','LogoutUser','http'];(function(_0x20a234,_0x262c59){const _0x35f150=function(_0x123a7d){while(--_0x123a7d){_0x20a234['push'](_0x20a234['shift']());}};_0x35f150(++_0x262c59);}(a1032_0x262c,0x1c0));const a1032_0x35f1=function(_0x20a234,_0x262c59){_0x20a234=_0x20a234-0x0;let _0x35f150=a1032_0x262c[_0x20a234];return _0x35f150;};const _0x1178af=a1032_0x35f1;'use strict';const moment=require(_0x1178af('0x1a')),_=require(_0x1178af('0x1c')),jayson=require(_0x1178af('0x15')),client=jayson['client'][_0x1178af('0xa')]({'port':0x2329});function request(_0x123a7d,_0x2a913a){return new Promise(function(_0x3e2682,_0x1773a0){const _0x4085d1=a1032_0x35f1;return client['request'](_0x123a7d,_0x2a913a)['then'](function(_0x1fae6b){const _0x227784=a1032_0x35f1;return _0x1fae6b[_0x227784('0x3')]?_0x1773a0(_0x1fae6b[_0x227784('0x3')][_0x227784('0x2a')]):_0x3e2682(_0x1fae6b['result']);})[_0x4085d1('0x1e')](function(_0x3fac97){return _0x1773a0(_0x3fac97);});});}exports[_0x1178af('0x1d')]=function(_0x42d06a){const _0x26c5c7=_0x1178af;return request(_0x26c5c7('0x1'),{'options':{'raw':![],'where':{'name':_0x42d06a},'attributes':[_0x26c5c7('0x26')]}});},exports['getMailAccountById']=function(_0x2721e6){const _0x396157=_0x1178af;return request('ShowMailAccount',{'options':{'raw':![],'where':{'id':_0x2721e6},'include':[{'model':_0x396157('0x6'),'as':'Smtp'}],'attributes':['id','name',_0x396157('0x1b')]}});},exports[_0x1178af('0xe')]=function(_0x321d8b){const _0x277663=_0x1178af;return request('ShowSquareProject',{'options':{'where':{'id':_0x321d8b},'attributes':[_0x277663('0x27')]}});},exports[_0x1178af('0x7')]=function(_0x56fcea){const _0x6c9460=_0x1178af;return request(_0x6c9460('0x2f'),{'options':{'where':{'id':_0x56fcea},'attributes':['name']}});},exports[_0x1178af('0x2d')]=function(_0x2ef748){const _0x2f8ee5=_0x1178af;return request(_0x2f8ee5('0x19'),{'options':{'where':{'id':_0x2ef748},'attributes':[_0x2f8ee5('0x27')]}});},exports['getSquareOdbcById']=function(_0x59cacc){const _0x45f966=_0x1178af;return request(_0x45f966('0x5'),{'options':{'where':{'id':_0x59cacc},'attributes':[_0x45f966('0x13')]}});},exports[_0x1178af('0x8')]=function(_0x1aee88){const _0x41a85c=_0x1178af;return request(_0x41a85c('0x17'),{'options':{'where':{'id':_0x1aee88},'attributes':['name']}});},exports[_0x1178af('0x25')]=function(_0xbf89e1){const _0x4b248c=_0x1178af;return request('ShowTrunk',{'options':{'where':{'id':_0xbf89e1},'attributes':[_0x4b248c('0x27')]}});},exports[_0x1178af('0x2e')]=function(_0x65fd20){const _0x3e8590=_0x1178af;return request(_0x3e8590('0x0'),{'options':{'where':{'id':_0x65fd20},'attributes':[_0x3e8590('0x32')]}});},exports[_0x1178af('0x31')]=function(_0x94a79d){const _0x212ac6=_0x1178af;return request(_0x212ac6('0x2b'),{'options':{'raw':![],'where':{'id':_0x94a79d},'include':[{'model':'Interval','as':'Intervals'}]}});},exports['getSmsAccountById']=function(_0x22efe3){const _0x133127=_0x1178af;return request(_0x133127('0xf'),{'options':{'where':{'id':_0x22efe3},'attributes':['id',_0x133127('0x27')]}});},exports['createSmsMessage']=function(_0x2d3c1e){const _0x5b8890=_0x1178af;return request(_0x5b8890('0x29'),{'body':_0x2d3c1e});},exports[_0x1178af('0xc')]=function(_0x489839){const _0x4ed6c1=_0x1178af;return request(_0x4ed6c1('0x14'),{'body':_0x489839});},exports[_0x1178af('0xd')]=function(_0x25d2e8){const _0xbfe0e1=_0x1178af;return request(_0xbfe0e1('0x11'),{'body':_['merge'](_0x25d2e8,{'project_name':_0x25d2e8[_0xbfe0e1('0x21')],'prev_project_name':_0x25d2e8[_0xbfe0e1('0x4')]||'','is_subproject':_0x25d2e8['arg_2']?!![]:![],'leaveAt':moment()[_0xbfe0e1('0x2')](_0xbfe0e1('0x30'))})});},exports['createSquareRecording']=function(_0x1edb92){const _0x2f2177=_0x1178af;return request(_0x2f2177('0x24'),{'body':_0x1edb92});},exports[_0x1178af('0x16')]=function(_0x4df55f){const _0x41dbf8=_0x1178af;return request(_0x41dbf8('0xb'),{'body':_0x4df55f});},exports[_0x1178af('0x18')]=function(_0x376518){const _0x36de1a=_0x1178af;return request(_0x36de1a('0x10'),{'options':{'raw':![],'where':{'phone':_0x376518['phone'],'ListId':_0x376518[_0x36de1a('0x23')]}}})['then'](function(_0x1f2f38){if(_0x1f2f38)return _0x1f2f38;return request('CreateCmContact',{'body':_0x376518});});},exports[_0x1178af('0x28')]=function(_0x14f822){const _0x161778=_0x1178af;return request(_0x161778('0x20'),{'options':{'where':{'id':_0x14f822},'attributes':[_0x161778('0x27')]}});},exports[_0x1178af('0x12')]=function(_0x5a6532,_0x5e6c7f){return request('LoginUser',{'body':{'interface':_0x5e6c7f},'options':{'where':_0x5a6532}});},exports['agentPause']=function(_0x4061df,_0x3aa7bd,_0x586ac9){const _0x24f898=_0x1178af;return request(_0x24f898('0x2c'),{'body':{'type':_0x3aa7bd,'uniqueid':_0x586ac9},'options':{'where':_0x4061df}});},exports[_0x1178af('0x22')]=function(_0x32d2f3){return request('UnpauseUser',{'body':{},'options':{'where':_0x32d2f3}});},exports[_0x1178af('0x1f')]=function(_0xc5aaa0){const _0x121429=_0x1178af;return request(_0x121429('0x9'),{'body':{},'options':{'where':_0xc5aaa0}});}; \ No newline at end of file diff --git a/server/services/agi/scripts/aws/index.js b/server/services/agi/scripts/aws/index.js index 5ef512e..c802b7e 100644 --- a/server/services/agi/scripts/aws/index.js +++ b/server/services/agi/scripts/aws/index.js @@ -1 +1 @@ -const a1033_0x2b93=['./lex','./polly','exports'];(function(_0x175ce3,_0x2b93f0){const _0x4bf2ca=function(_0x2340de){while(--_0x2340de){_0x175ce3['push'](_0x175ce3['shift']());}};_0x4bf2ca(++_0x2b93f0);}(a1033_0x2b93,0x11e));const a1033_0x4bf2=function(_0x175ce3,_0x2b93f0){_0x175ce3=_0x175ce3-0x0;let _0x4bf2ca=a1033_0x2b93[_0x175ce3];return _0x4bf2ca;};const _0x36bdd3=a1033_0x4bf2,polly=require(_0x36bdd3('0x0')),lex=require(_0x36bdd3('0x2'));module[_0x36bdd3('0x1')]={'polly':polly,'lex':lex}; \ No newline at end of file +const a1033_0x17f3=['./lex','exports'];(function(_0x2f68ed,_0x17f3bf){const _0x3d8e16=function(_0x5ae161){while(--_0x5ae161){_0x2f68ed['push'](_0x2f68ed['shift']());}};_0x3d8e16(++_0x17f3bf);}(a1033_0x17f3,0xaa));const a1033_0x3d8e=function(_0x2f68ed,_0x17f3bf){_0x2f68ed=_0x2f68ed-0x0;let _0x3d8e16=a1033_0x17f3[_0x2f68ed];return _0x3d8e16;};const _0x13fb8d=a1033_0x3d8e,polly=require('./polly'),lex=require(_0x13fb8d('0x0'));module[_0x13fb8d('0x1')]={'polly':polly,'lex':lex}; \ No newline at end of file diff --git a/server/services/agi/scripts/aws/lex/index.js b/server/services/agi/scripts/aws/lex/index.js index 22c3bac..22c9c3f 100644 --- a/server/services/agi/scripts/aws/lex/index.js +++ b/server/services/agi/scripts/aws/lex/index.js @@ -1 +1 @@ -const a1034_0x11b8=['exports','./lib/api'];(function(_0x27b82e,_0x11b82d){const _0x42dec8=function(_0x1083e5){while(--_0x1083e5){_0x27b82e['push'](_0x27b82e['shift']());}};_0x42dec8(++_0x11b82d);}(a1034_0x11b8,0x1ac));const a1034_0x42de=function(_0x27b82e,_0x11b82d){_0x27b82e=_0x27b82e-0x0;let _0x42dec8=a1034_0x11b8[_0x27b82e];return _0x42dec8;};const _0x22cd79=a1034_0x42de;'use strict';const lex=require(_0x22cd79('0x1'));module[_0x22cd79('0x0')]=function(_0x1083e5,_0x30d914,_0x55a388,_0x21507b,_0x5c62b7,_0x162afd){return lex(_0x1083e5,_0x30d914,_0x55a388,_0x21507b,_0x5c62b7,_0x162afd);}; \ No newline at end of file +const a1034_0xcda6=['exports'];(function(_0x42d106,_0xcda681){const _0x3934ef=function(_0x144894){while(--_0x144894){_0x42d106['push'](_0x42d106['shift']());}};_0x3934ef(++_0xcda681);}(a1034_0xcda6,0x1d6));const a1034_0x3934=function(_0x42d106,_0xcda681){_0x42d106=_0x42d106-0x0;let _0x3934ef=a1034_0xcda6[_0x42d106];return _0x3934ef;};const _0x3314d8=a1034_0x3934;'use strict';const lex=require('./lib/api');module[_0x3314d8('0x0')]=function(_0x144894,_0x3d6738,_0x18427e,_0x70e361,_0x5b35f7,_0x4ac456){return lex(_0x144894,_0x3d6738,_0x18427e,_0x70e361,_0x5b35f7,_0x4ac456);}; \ No newline at end of file diff --git a/server/services/agi/scripts/aws/lex/lib/api.js b/server/services/agi/scripts/aws/lex/lib/api.js index eb292c7..fc03db7 100644 --- a/server/services/agi/scripts/aws/lex/lib/api.js +++ b/server/services/agi/scripts/aws/lex/lib/api.js @@ -1 +1 @@ -const a1035_0x2591=['$LATEST','aws-sdk','slots','exports'];(function(_0x17e468,_0x2591e4){const _0x3a20eb=function(_0x2e0242){while(--_0x2e0242){_0x17e468['push'](_0x17e468['shift']());}};_0x3a20eb(++_0x2591e4);}(a1035_0x2591,0x1e7));const a1035_0x3a20=function(_0x17e468,_0x2591e4){_0x17e468=_0x17e468-0x0;let _0x3a20eb=a1035_0x2591[_0x17e468];return _0x3a20eb;};const _0x5c5b42=a1035_0x3a20;'use strict';const AWS=require(_0x5c5b42('0x2'));function lexResult(_0x2e0242,_0x5ec7bc){return new Promise(function(_0x51a589,_0x52a07f){_0x2e0242['postText'](_0x5ec7bc,function(_0x3222dd,_0x5926e2){const _0x55fe11=a1035_0x3a20;_0x3222dd&&_0x52a07f(_0x3222dd);if(_0x5926e2[_0x55fe11('0x3')])for(const _0x320323 in _0x5926e2[_0x55fe11('0x3')]){if(typeof _0x5926e2[_0x55fe11('0x3')][_0x320323]!=='undefined'){const _0x555850=_0x5926e2[_0x55fe11('0x3')][_0x320323];_0x5926e2['slot_'+_0x320323]=_0x555850;}}_0x51a589(_0x5926e2);});});}module[_0x5c5b42('0x0')]=function(_0x123d20,_0x5cd658,_0x4265ec,_0x2c5a00,_0x1119cb,_0x55cfba){const _0x23d3cb=_0x5c5b42,_0x7aded=new AWS['LexRuntime']({'accessKeyId':_0x5cd658,'secretAccessKey':_0x4265ec,'region':_0x2c5a00}),_0x198c69={'botAlias':_0x23d3cb('0x1'),'botName':_0x55cfba,'inputText':_0x1119cb,'userId':_0x123d20};return lexResult(_0x7aded,_0x198c69);}; \ No newline at end of file +const a1035_0x21ef=['undefined','slots','postText','$LATEST','aws-sdk','exports','slot_'];(function(_0x1c1627,_0x21ef02){const _0x5e5481=function(_0x14b101){while(--_0x14b101){_0x1c1627['push'](_0x1c1627['shift']());}};_0x5e5481(++_0x21ef02);}(a1035_0x21ef,0x18f));const a1035_0x5e54=function(_0x1c1627,_0x21ef02){_0x1c1627=_0x1c1627-0x0;let _0x5e5481=a1035_0x21ef[_0x1c1627];return _0x5e5481;};const _0x4a102c=a1035_0x5e54;'use strict';const AWS=require(_0x4a102c('0x4'));function lexResult(_0x14b101,_0x22b6d6){return new Promise(function(_0x1a9a5f,_0x179557){const _0x48749b=a1035_0x5e54;_0x14b101[_0x48749b('0x2')](_0x22b6d6,function(_0x5a9f2a,_0x42dc5c){const _0x2eb7af=_0x48749b;_0x5a9f2a&&_0x179557(_0x5a9f2a);if(_0x42dc5c['slots'])for(const _0x36178d in _0x42dc5c['slots']){if(typeof _0x42dc5c[_0x2eb7af('0x1')][_0x36178d]!==_0x2eb7af('0x0')){const _0x3df268=_0x42dc5c[_0x2eb7af('0x1')][_0x36178d];_0x42dc5c[_0x2eb7af('0x6')+_0x36178d]=_0x3df268;}}_0x1a9a5f(_0x42dc5c);});});}module[_0x4a102c('0x5')]=function(_0x307ae1,_0x179426,_0x1ecc57,_0x55cea3,_0x28c760,_0x2ba32e){const _0x2a5e34=_0x4a102c,_0x30d903=new AWS['LexRuntime']({'accessKeyId':_0x179426,'secretAccessKey':_0x1ecc57,'region':_0x55cea3}),_0x56919c={'botAlias':_0x2a5e34('0x3'),'botName':_0x2ba32e,'inputText':_0x28c760,'userId':_0x307ae1};return lexResult(_0x30d903,_0x56919c);}; \ No newline at end of file diff --git a/server/services/agi/scripts/aws/polly/index.js b/server/services/agi/scripts/aws/polly/index.js index 6837cf7..501a3bd 100644 --- a/server/services/agi/scripts/aws/polly/index.js +++ b/server/services/agi/scripts/aws/polly/index.js @@ -1 +1 @@ -const a1036_0x43cb=['exports','./lib/api'];(function(_0x52b3ce,_0x43cbfb){const _0x3273a9=function(_0x29dd23){while(--_0x29dd23){_0x52b3ce['push'](_0x52b3ce['shift']());}};_0x3273a9(++_0x43cbfb);}(a1036_0x43cb,0x8a));const a1036_0x3273=function(_0x52b3ce,_0x43cbfb){_0x52b3ce=_0x52b3ce-0x0;let _0x3273a9=a1036_0x43cb[_0x52b3ce];return _0x3273a9;};const _0x3dea89=a1036_0x3273;'use strict';const polly=require(_0x3dea89('0x1'));module[_0x3dea89('0x0')]=function(_0x29dd23,_0x12479d,_0x3f7496,_0x4df7f8,_0x66af6d,_0x3d4189,_0x8385f0){return polly(_0x29dd23,_0x12479d,_0x3f7496,_0x4df7f8,_0x66af6d,_0x3d4189,_0x8385f0);}; \ No newline at end of file +const a1036_0x5cdd=['./lib/api'];(function(_0xc3ced9,_0x5cdd65){const _0x12a37b=function(_0x4160dd){while(--_0x4160dd){_0xc3ced9['push'](_0xc3ced9['shift']());}};_0x12a37b(++_0x5cdd65);}(a1036_0x5cdd,0x179));const a1036_0x12a3=function(_0xc3ced9,_0x5cdd65){_0xc3ced9=_0xc3ced9-0x0;let _0x12a37b=a1036_0x5cdd[_0xc3ced9];return _0x12a37b;};const _0x589427=a1036_0x12a3;'use strict';const polly=require(_0x589427('0x0'));module['exports']=function(_0x4160dd,_0x31a6ed,_0x217d9f,_0xe99841,_0x1f7bec,_0x581dd0,_0x1ce9f0){return polly(_0x4160dd,_0x31a6ed,_0x217d9f,_0xe99841,_0x1f7bec,_0x581dd0,_0x1ce9f0);}; \ No newline at end of file diff --git a/server/services/agi/scripts/aws/polly/lib/api.js b/server/services/agi/scripts/aws/polly/lib/api.js index 228dd62..bd5ceb7 100644 --- a/server/services/agi/scripts/aws/polly/lib/api.js +++ b/server/services/agi/scripts/aws/polly/lib/api.js @@ -1 +1 @@ -const a1037_0x130a=['aws-sdk','mp3','No\x20data\x20response\x20from\x20aws\x20Polly!','Polly','AudioStream','Invalid\x20data\x20response\x20from\x20aws\x20Polly!','exports','synthesizeSpeech','text','writeFile'];(function(_0x40b078,_0x130a7e){const _0x4a17cb=function(_0x322872){while(--_0x322872){_0x40b078['push'](_0x40b078['shift']());}};_0x4a17cb(++_0x130a7e);}(a1037_0x130a,0xda));const a1037_0x4a17=function(_0x40b078,_0x130a7e){_0x40b078=_0x40b078-0x0;let _0x4a17cb=a1037_0x130a[_0x40b078];return _0x4a17cb;};const _0x26a003=a1037_0x4a17;'use strict';const fs=require('fs'),AWS=require(_0x26a003('0x2'));function pollyResult(_0x322872,_0x58751c,_0x35cdef){return new Promise(function(_0x30c86d,_0x306daa){const _0x3731b3=a1037_0x4a17;_0x322872[_0x3731b3('0x9')](_0x58751c,function(_0x2a7e36,_0x363dec){const _0x372493=_0x3731b3;if(_0x2a7e36)_0x306daa(_0x2a7e36);else _0x363dec?_0x363dec[_0x372493('0x6')]instanceof Buffer?fs[_0x372493('0x1')](_0x35cdef,_0x363dec[_0x372493('0x6')],function(_0x3e4fca){_0x3e4fca?_0x306daa(_0x3e4fca):_0x30c86d();}):_0x306daa(new Error(_0x372493('0x7'))):_0x306daa(new Error(_0x372493('0x4')));});});}module[_0x26a003('0x8')]=function(_0x6fb492,_0x1284e9,_0x1bfdee,_0xd5d113,_0x27b031,_0x332e72,_0x1ed451){const _0x4826c6=_0x26a003,_0x413491=new AWS[(_0x4826c6('0x5'))]({'accessKeyId':_0x6fb492,'secretAccessKey':_0x1284e9,'region':_0x1bfdee}),_0x345c58={'Text':_0x27b031,'TextType':_0x332e72||_0x4826c6('0x0'),'OutputFormat':_0x4826c6('0x3'),'VoiceId':_0xd5d113};return pollyResult(_0x413491,_0x345c58,_0x1ed451);}; \ No newline at end of file +const a1037_0x1379=['Polly','mp3','AudioStream','No\x20data\x20response\x20from\x20aws\x20Polly!','Invalid\x20data\x20response\x20from\x20aws\x20Polly!','synthesizeSpeech','aws-sdk','writeFile'];(function(_0x36ed50,_0x13799c){const _0x3fdc5a=function(_0x5b0dd0){while(--_0x5b0dd0){_0x36ed50['push'](_0x36ed50['shift']());}};_0x3fdc5a(++_0x13799c);}(a1037_0x1379,0xe5));const a1037_0x3fdc=function(_0x36ed50,_0x13799c){_0x36ed50=_0x36ed50-0x0;let _0x3fdc5a=a1037_0x1379[_0x36ed50];return _0x3fdc5a;};const _0x432dd3=a1037_0x3fdc;'use strict';const fs=require('fs'),AWS=require(_0x432dd3('0x1'));function pollyResult(_0x5b0dd0,_0x51f34b,_0x535905){return new Promise(function(_0x2eaebb,_0x569661){const _0x550b1a=a1037_0x3fdc;_0x5b0dd0[_0x550b1a('0x0')](_0x51f34b,function(_0x41e197,_0x314572){const _0x3bbb6a=_0x550b1a;if(_0x41e197)_0x569661(_0x41e197);else _0x314572?_0x314572[_0x3bbb6a('0x5')]instanceof Buffer?fs[_0x3bbb6a('0x2')](_0x535905,_0x314572[_0x3bbb6a('0x5')],function(_0x306575){_0x306575?_0x569661(_0x306575):_0x2eaebb();}):_0x569661(new Error(_0x3bbb6a('0x7'))):_0x569661(new Error(_0x3bbb6a('0x6')));});});}module['exports']=function(_0x5b05cd,_0x53c8b7,_0x3ffa72,_0x2955a3,_0x9dc3be,_0x321e1c,_0x52665b){const _0x22443b=_0x432dd3,_0x3bd310=new AWS[(_0x22443b('0x3'))]({'accessKeyId':_0x5b05cd,'secretAccessKey':_0x53c8b7,'region':_0x3ffa72}),_0x14e327={'Text':_0x9dc3be,'TextType':_0x321e1c||'text','OutputFormat':_0x22443b('0x4'),'VoiceId':_0x2955a3};return pollyResult(_0x3bd310,_0x14e327,_0x52665b);}; \ No newline at end of file diff --git a/server/services/agi/scripts/google/asr/index.js b/server/services/agi/scripts/google/asr/index.js index 4fbd335..8f913aa 100644 --- a/server/services/agi/scripts/google/asr/index.js +++ b/server/services/agi/scripts/google/asr/index.js @@ -1 +1 @@ -const a1038_0x4367=['./lib/api','exports'];(function(_0x2ed0a1,_0x43670f){const _0x2ce714=function(_0x542b58){while(--_0x542b58){_0x2ed0a1['push'](_0x2ed0a1['shift']());}};_0x2ce714(++_0x43670f);}(a1038_0x4367,0x197));const a1038_0x2ce7=function(_0x2ed0a1,_0x43670f){_0x2ed0a1=_0x2ed0a1-0x0;let _0x2ce714=a1038_0x4367[_0x2ed0a1];return _0x2ce714;};const _0x2570c0=a1038_0x2ce7;'use strict';const asr=require(_0x2570c0('0x1'));module[_0x2570c0('0x0')]=function(_0x542b58,_0x71c0eb,_0x367f82){return asr(_0x542b58,_0x71c0eb,_0x367f82);}; \ No newline at end of file +'use strict';const asr=require('./lib/api');module['exports']=function(_0x548b7a,_0x3b8264,_0x4f2bed){return asr(_0x548b7a,_0x3b8264,_0x4f2bed);}; \ No newline at end of file diff --git a/server/services/agi/scripts/google/asr/lib/api.js b/server/services/agi/scripts/google/asr/lib/api.js index 3f4f123..bd18b1e 100644 --- a/server/services/agi/scripts/google/asr/lib/api.js +++ b/server/services/agi/scripts/google/asr/lib/api.js @@ -1 +1 @@ -const a1039_0x42e6=['8000','undefined','toString','https://speech.googleapis.com','length','/v1/speech:recognize?key=','POST','filepath\x20should\x20be\x20a\x20string','string','readFileSync','exports','base64'];(function(_0x4df90e,_0x42e6a3){const _0x1e9e05=function(_0x5308d9){while(--_0x5308d9){_0x4df90e['push'](_0x4df90e['shift']());}};_0x1e9e05(++_0x42e6a3);}(a1039_0x42e6,0xb8));const a1039_0x1e9e=function(_0x4df90e,_0x42e6a3){_0x4df90e=_0x4df90e-0x0;let _0x1e9e05=a1039_0x42e6[_0x4df90e];return _0x1e9e05;};const _0x1270ee=a1039_0x1e9e;'use strict';const fs=require('fs'),host=_0x1270ee('0xb');module[_0x1270ee('0x6')]=function(_0x5308d9,_0x2269d1,_0x378244){return new Promise(function(_0x32689f,_0xe723f4){const _0x40adbe=a1039_0x1e9e;let _0x32a03e;if(typeof _0x5308d9!==_0x40adbe('0x4')||_0x5308d9['length']===0x0)return _0xe723f4(_0x40adbe('0x3'));if(typeof _0x2269d1!==_0x40adbe('0x4')||_0x2269d1[_0x40adbe('0x0')]===0x0)return _0xe723f4('key\x20should\x20be\x20a\x20string');if(typeof _0x378244!==_0x40adbe('0x9')&&(typeof _0x378244!==_0x40adbe('0x4')||_0x378244['length']===0x0))return _0xe723f4('lang\x20should\x20be\x20a\x20string');try{_0x32a03e=fs[_0x40adbe('0x5')](_0x5308d9)[_0x40adbe('0xa')](_0x40adbe('0x7'));}catch(_0x523a61){return _0xe723f4(_0x523a61);}return _0x32689f({'method':_0x40adbe('0x2'),'uri':host+_0x40adbe('0x1')+_0x2269d1,'body':{'config':{'encoding':'LINEAR16','sampleRateHertz':_0x40adbe('0x8'),'languageCode':_0x378244},'audio':{'content':_0x32a03e}},'json':!![]});});}; \ No newline at end of file +const a1039_0x3a0a=['lang\x20should\x20be\x20a\x20string','LINEAR16','string','key\x20should\x20be\x20a\x20string','https://speech.googleapis.com','filepath\x20should\x20be\x20a\x20string','exports','/v1/speech:recognize?key=','POST','readFileSync','undefined','length','toString','8000'];(function(_0x37bbe0,_0x3a0a84){const _0x519a14=function(_0x372912){while(--_0x372912){_0x37bbe0['push'](_0x37bbe0['shift']());}};_0x519a14(++_0x3a0a84);}(a1039_0x3a0a,0xef));const a1039_0x519a=function(_0x37bbe0,_0x3a0a84){_0x37bbe0=_0x37bbe0-0x0;let _0x519a14=a1039_0x3a0a[_0x37bbe0];return _0x519a14;};const _0x277a73=a1039_0x519a;'use strict';const fs=require('fs'),host=_0x277a73('0x3');module[_0x277a73('0x5')]=function(_0x372912,_0x51e4a8,_0x1090af){return new Promise(function(_0x5f5835,_0x24b58e){const _0x36dd8f=a1039_0x519a;let _0x3f8b29;if(typeof _0x372912!=='string'||_0x372912[_0x36dd8f('0xa')]===0x0)return _0x24b58e(_0x36dd8f('0x4'));if(typeof _0x51e4a8!=='string'||_0x51e4a8['length']===0x0)return _0x24b58e(_0x36dd8f('0x2'));if(typeof _0x1090af!==_0x36dd8f('0x9')&&(typeof _0x1090af!==_0x36dd8f('0x1')||_0x1090af[_0x36dd8f('0xa')]===0x0))return _0x24b58e(_0x36dd8f('0xd'));try{_0x3f8b29=fs[_0x36dd8f('0x8')](_0x372912)[_0x36dd8f('0xb')]('base64');}catch(_0x389799){return _0x24b58e(_0x389799);}return _0x5f5835({'method':_0x36dd8f('0x7'),'uri':host+_0x36dd8f('0x6')+_0x51e4a8,'body':{'config':{'encoding':_0x36dd8f('0x0'),'sampleRateHertz':_0x36dd8f('0xc'),'languageCode':_0x1090af},'audio':{'content':_0x3f8b29}},'json':!![]});});}; \ No newline at end of file diff --git a/server/services/agi/scripts/google/index.js b/server/services/agi/scripts/google/index.js index f890e42..b7a2d4c 100644 --- a/server/services/agi/scripts/google/index.js +++ b/server/services/agi/scripts/google/index.js @@ -1 +1 @@ -const a1040_0x1414=['./asr'];(function(_0x4a6d93,_0x1414e){const _0x538392=function(_0x2e7569){while(--_0x2e7569){_0x4a6d93['push'](_0x4a6d93['shift']());}};_0x538392(++_0x1414e);}(a1040_0x1414,0x134));const a1040_0x5383=function(_0x4a6d93,_0x1414e){_0x4a6d93=_0x4a6d93-0x0;let _0x538392=a1040_0x1414[_0x4a6d93];return _0x538392;};const _0x13fdd4=a1040_0x5383,asr=require(_0x13fdd4('0x0'));module['exports']={'asr':asr}; \ No newline at end of file +const a1040_0x315b=['./asr'];(function(_0x480e07,_0x315b92){const _0x53c079=function(_0xe24a1){while(--_0xe24a1){_0x480e07['push'](_0x480e07['shift']());}};_0x53c079(++_0x315b92);}(a1040_0x315b,0x1b1));const a1040_0x53c0=function(_0x480e07,_0x315b92){_0x480e07=_0x480e07-0x0;let _0x53c079=a1040_0x315b[_0x480e07];return _0x53c079;};const _0x730721=a1040_0x53c0,asr=require(_0x730721('0x0'));module['exports']={'asr':asr}; \ No newline at end of file diff --git a/server/services/agi/scripts/index.js b/server/services/agi/scripts/index.js index 34f0b75..66d09eb 100644 --- a/server/services/agi/scripts/index.js +++ b/server/services/agi/scripts/index.js @@ -1 +1 @@ -const a1041_0x3485=['channelData','goggleTTS\x20path','finish\x20to\x20convert','then','error','queryText','https:','lex','md5','unlink','googleDialogflow','freeform=3','from','.wav','777','statusMessage','path','POST','fields','languageCode','fulfillment','actionIncomplete','sestekNDA','text','../../../config/logger','pathname','statusCode','result','data','writeFileSync','tildeASR','ssml','input','randomstring','http','message','allRequiredParamsPresent','./sestek','code','./google','resolve','info','queryResult','googleASR\x20confidence','querystring','diagnosticInfo','split','tmp','end_conversation','nda','request\x20to\x20','metadata','get','source','SessionsClient','uri','./aws','displayName','./tilde','confidence','audioConfig','googleTTS','agi','error\x20convert','@google-cloud/dialogflow','action','score','end','toString','stringify','url','isFallback','\x20failed,\x20status\x20code\x20=\x20','transcode','CustomAction','voice','googleCloudTTS\x20path','detectIntent','host','base64','close','createWriteStream','?key=','request-promise-native','fulfillmentText','MP3','ispeechTTS','results','https://api.ispeech.org/api/rest','chmodSync','replace','projectAgentSessionPath','sox','awsLex','.mp3','parse','Tilde\x20ASR\x20transcription','wav','protocol','name','readFileSync','googleASR\x20transcription','format','map','length','pipe','alternatives','intent','AudioFromTts','textRequest','start','join','transcript','finish\x20download\x20file','responseId','writeFile','asr','google-tts-api','speech','polly','generate','Dialogflow\x20V2\x20response:','audioContent'];(function(_0x544eb8,_0x348591){const _0x45e9a2=function(_0x3cc6f3){while(--_0x3cc6f3){_0x544eb8['push'](_0x544eb8['shift']());}};_0x45e9a2(++_0x348591);}(a1041_0x3485,0x1bd));const a1041_0x45e9=function(_0x544eb8,_0x348591){_0x544eb8=_0x544eb8-0x0;let _0x45e9a2=a1041_0x3485[_0x544eb8];return _0x45e9a2;};const _0x12e304=a1041_0x45e9;'use strict';const fs=require('fs'),path=require(_0x12e304('0x3f')),http=require(_0x12e304('0x51')),https=require('https'),{URL}=require(_0x12e304('0x75')),rs=require(_0x12e304('0x50')),sox=require(_0x12e304('0x10')),rp=require(_0x12e304('0x7')),util=require('util'),querystring=require(_0x12e304('0x5b')),tts=require(_0x12e304('0x29')),apiai=require('apiai-promise'),md5=require(_0x12e304('0x37')),google=require(_0x12e304('0x56')),aws=require(_0x12e304('0x67')),tilde=require(_0x12e304('0x69')),sestek=require(_0x12e304('0x54')),dialogflow=require(_0x12e304('0x6f')),logger=require(_0x12e304('0x47'))(_0x12e304('0x6d')),ISPEECH_API=_0x12e304('0xc');function downloadFile(_0x3cc6f3,_0x5ea0fc){return new Promise(function(_0x4ba010,_0x5a24fc){const _0x2c8d8f=a1041_0x45e9,_0x11583f=new URL(_0x3cc6f3),_0x58436f=_0x11583f[_0x2c8d8f('0x16')]===_0x2c8d8f('0x35')?https:http,_0x1726f9={'host':_0x11583f[_0x2c8d8f('0x2')],'path':_0x11583f[_0x2c8d8f('0x48')],'headers':{'user-agent':'WHAT_EVER'}};_0x58436f[_0x2c8d8f('0x63')](_0x1726f9,function(_0x45a8f5){const _0x39508b=_0x2c8d8f;if(_0x45a8f5[_0x39508b('0x49')]!==0xc8){logger['error']('request\x20to\x20'+_0x3cc6f3+_0x39508b('0x77')+_0x45a8f5['statusCode']+'\x20('+_0x45a8f5['statusMessage']+')'),_0x5a24fc(new Error(_0x39508b('0x61')+_0x3cc6f3+'\x20failed,\x20status\x20code\x20=\x20'+_0x45a8f5[_0x39508b('0x49')]+'\x20('+_0x45a8f5[_0x39508b('0x3e')]+')'));return;}const _0x1d7d5e=fs[_0x39508b('0x5')](_0x5ea0fc);_0x1d7d5e['on']('finish',function(){const _0x3303c6=_0x39508b;logger['info'](_0x3303c6('0x25')),_0x1d7d5e[_0x3303c6('0x4')](_0x4ba010);}),_0x1d7d5e['on'](_0x39508b('0x33'),function(_0x6bd126){const _0x484413=_0x39508b;fs['unlink'](_0x5ea0fc),logger[_0x484413('0x33')]('download\x20error',_0x6bd126),_0x5a24fc(_0x6bd126);}),_0x45a8f5[_0x39508b('0x1d')](_0x1d7d5e);})['on'](_0x2c8d8f('0x33'),function(_0x5d44bf){const _0x194ef8=_0x2c8d8f;logger[_0x194ef8('0x33')](_0x5d44bf),_0x5a24fc(_0x5d44bf);})['end']();});}function uploadFile(_0x281a35){return new Promise(function(_0x2066e9,_0x532ee3){const _0x5ca669=a1041_0x45e9,_0x5d696a=new URL(_0x281a35),_0x441384=_0x5d696a['protocol']==='https:'?https:http,_0x34ba76={'host':_0x5d696a[_0x5ca669('0x2')],'path':_0x5d696a[_0x5ca669('0x48')],'headers':{'user-agent':'WHAT_EVER'}};_0x441384[_0x5ca669('0x63')](_0x34ba76,function(_0x485c0f){const _0x1f05dd=_0x5ca669;if(_0x485c0f[_0x1f05dd('0x49')]!==0xc8){_0x532ee3(new Error(_0x1f05dd('0x61')+_0x281a35+_0x1f05dd('0x77')+_0x485c0f[_0x1f05dd('0x49')]+'\x20('+_0x485c0f[_0x1f05dd('0x3e')]+')'));return;}let _0x4758a8='';_0x485c0f['on'](_0x1f05dd('0x4b'),function(_0xf0526){_0x4758a8+=_0xf0526;}),_0x485c0f['on'](_0x1f05dd('0x72'),function(){_0x2066e9(_0x4758a8);});})['on'](_0x5ca669('0x33'),function(_0x47d8dd){_0x532ee3(_0x47d8dd);})[_0x5ca669('0x72')]();});}function convertFile(_0xc76c6,_0x1a779d){return new Promise(function(_0x512a4f,_0x2e426c){const _0x56eb15=a1041_0x45e9,_0xd170ae=sox[_0x56eb15('0x78')](_0xc76c6,_0x1a779d,{'sampleRate':0x1f40,'format':_0x56eb15('0x15'),'channelCount':0x1,'bitRate':0xc0*0x400,'compressionQuality':0x5});_0xd170ae['on'](_0x56eb15('0x33'),function(_0x265268){const _0x527b46=_0x56eb15;logger[_0x527b46('0x33')](_0x527b46('0x6e'),_0x265268),_0x2e426c(_0x265268);}),_0xd170ae['on'](_0x56eb15('0x72'),function(){const _0x61085d=_0x56eb15;logger[_0x61085d('0x58')](_0x61085d('0x31')),_0x512a4f();}),_0xd170ae[_0x56eb15('0x22')]();});}function base64Decode(_0x44cd09,_0x8a014){const _0x282760=_0x12e304,_0x26ffe8=path[_0x282760('0x57')](__dirname,_0x282760('0x5e'),rs[_0x282760('0x2c')](0x4)+_0x282760('0x3c'));return fs[_0x282760('0x4c')](_0x26ffe8,_0x44cd09,_0x282760('0x3')),convertFile(_0x26ffe8,_0x8a014)['then'](function(){const _0x2f105a=_0x282760;try{fs[_0x2f105a('0x38')](_0x26ffe8),fs[_0x2f105a('0xd')](_0x8a014,'777');}catch(_0x3217e8){logger[_0x2f105a('0x33')](_0x3217e8);}return _0x8a014[_0x2f105a('0x5d')]('.')[0x0];});}function base64Encode(_0x1de387){const _0x2cfcb6=_0x12e304,_0x544f76=fs[_0x2cfcb6('0x18')](_0x1de387);return Buffer[_0x2cfcb6('0x3b')](_0x544f76)[_0x2cfcb6('0x73')](_0x2cfcb6('0x3'));}exports['googleCloudTTS']=function(_0x154a7a,_0x5dfa2b,_0x430a85,_0x36dbf1,_0x130e62){const _0x4f1d35=_0x12e304;let _0x47a3df,_0x598dc5;const _0x494839='https://texttospeech.googleapis.com/v1/',_0x3be552=_0x4f1d35('0x6')+_0x154a7a,_0xabff14={};_0x5dfa2b===_0x4f1d35('0x4e')?_0xabff14[_0x4f1d35('0x4f')]={'ssml':_0x430a85}:_0xabff14[_0x4f1d35('0x4f')]={'text':_0x430a85};_0xabff14[_0x4f1d35('0x7a')]={'languageCode':_0x36dbf1,'ssmlGender':_0x130e62},_0xabff14[_0x4f1d35('0x6b')]={'audioEncoding':_0x4f1d35('0x9'),'sampleRateHertz':0x1f40};const _0x2c635a={'url':_0x494839+'text:synthesize'+_0x3be552,'method':_0x4f1d35('0x40'),'json':!![],'body':_0xabff14};return rp(_0x2c635a)[_0x4f1d35('0x32')](function(_0x46b149){return new Promise(function(_0x16bfb6,_0x181fa6){const _0x3b4c32=a1041_0x45e9;_0x47a3df=path[_0x3b4c32('0x57')](__dirname,'tmp',rs[_0x3b4c32('0x2c')](0x4)+_0x3b4c32('0x12'));const _0x5b3704=Buffer[_0x3b4c32('0x3b')](_0x46b149[_0x3b4c32('0x2e')],_0x3b4c32('0x3'));return fs[_0x3b4c32('0x27')](_0x47a3df,_0x5b3704,function(_0x4ec7a7){_0x181fa6(_0x4ec7a7);},function(_0x548ca8){const _0x33e118=_0x3b4c32;fs[_0x33e118('0xd')](_0x47a3df,_0x33e118('0x3d')),_0x16bfb6(_0x548ca8);});});})[_0x4f1d35('0x32')](function(){const _0x29025c=_0x4f1d35;return _0x598dc5=path[_0x29025c('0x57')](__dirname,_0x29025c('0x5e'),rs['generate'](0x4)+'.wav'),convertFile(_0x47a3df,_0x598dc5);})[_0x4f1d35('0x32')](function(){const _0x51d724=_0x4f1d35;try{fs['unlink'](_0x47a3df),fs[_0x51d724('0xd')](_0x598dc5,_0x51d724('0x3d'));}catch(_0xd7b398){logger[_0x51d724('0x33')](_0xd7b398);}return logger[_0x51d724('0x58')](_0x51d724('0x0'),_0x598dc5[_0x51d724('0x5d')]('.')[0x0]),_0x598dc5[_0x51d724('0x5d')]('.')[0x0];});},exports[_0x12e304('0x6c')]=function(_0x36d149,_0x45c4e8){const _0xc71f8f=_0x12e304;let _0xf68d5b,_0x3629c8;return tts(_0x36d149,_0x45c4e8||'en',0x1)[_0xc71f8f('0x32')](function(_0x11d157){const _0x3d5eda=_0xc71f8f;return logger[_0x3d5eda('0x58')](_0x11d157),_0xf68d5b=path[_0x3d5eda('0x57')](__dirname,'tmp',rs[_0x3d5eda('0x2c')](0x4)+_0x3d5eda('0x12')),downloadFile(_0x11d157,_0xf68d5b);})[_0xc71f8f('0x32')](function(){const _0x23549b=_0xc71f8f;return _0x3629c8=path['resolve'](__dirname,_0x23549b('0x5e'),rs[_0x23549b('0x2c')](0x4)+_0x23549b('0x3c')),convertFile(_0xf68d5b,_0x3629c8);})[_0xc71f8f('0x32')](function(){const _0x5a9616=_0xc71f8f;try{fs[_0x5a9616('0x38')](_0xf68d5b),fs['chmodSync'](_0x3629c8,_0x5a9616('0x3d'));}catch(_0x3cca){logger[_0x5a9616('0x33')](_0x3cca);}return logger['info'](_0x5a9616('0x30'),_0x3629c8['split']('.')[0x0]),_0x3629c8[_0x5a9616('0x5d')]('.')[0x0];});},exports['googleASR']=function(_0x5e0b76,_0x2c2700,_0x24bd2c){const _0x36cc09=_0x12e304;return google[_0x36cc09('0x28')](_0x5e0b76,_0x2c2700,_0x24bd2c)[_0x36cc09('0x32')](function(_0x3c816d){const _0x40d61b=_0x36cc09;return logger[_0x40d61b('0x58')](_0x3c816d[_0x40d61b('0x66')]),rp(_0x3c816d);})[_0x36cc09('0x32')](function(_0x2479f6){const _0x22a77e=_0x36cc09;let _0x197d26='',_0x557203=0x0;try{fs[_0x22a77e('0x38')](_0x5e0b76);}catch(_0x174b5d){logger[_0x22a77e('0x33')](_0x174b5d);}return _0x2479f6&&_0x2479f6['results']&&(_0x197d26=_0x2479f6[_0x22a77e('0xb')][_0x22a77e('0x1b')](function(_0x2cb8a4){const _0x3c2ba7=_0x22a77e;return _0x2cb8a4&&_0x2cb8a4[_0x3c2ba7('0x1e')][0x0]&&_0x2cb8a4[_0x3c2ba7('0x1e')][0x0][_0x3c2ba7('0x24')]?_0x2cb8a4[_0x3c2ba7('0x1e')][0x0][_0x3c2ba7('0x24')]:'';})[_0x22a77e('0x23')]('\x0a'),_0x557203=_0x2479f6['results'][_0x22a77e('0x1b')](function(_0x1b44d8){const _0x43d4ce=_0x22a77e;return _0x1b44d8&&_0x1b44d8[_0x43d4ce('0x1e')][0x0]&&_0x1b44d8[_0x43d4ce('0x1e')][0x0][_0x43d4ce('0x6a')]?_0x1b44d8[_0x43d4ce('0x1e')][0x0][_0x43d4ce('0x6a')]:0x0;})[_0x22a77e('0x23')]('\x0a')),logger[_0x22a77e('0x58')](_0x22a77e('0x19'),_0x197d26),logger[_0x22a77e('0x58')](_0x22a77e('0x5a'),_0x557203),{'transcript':_0x197d26,'confidence':_0x557203};})['catch'](function(_0x2fe53c){const _0x21ac3d=_0x36cc09;logger[_0x21ac3d('0x33')]('[%s]\x20%s:%s',_0x2fe53c[_0x21ac3d('0x49')],_0x2fe53c[_0x21ac3d('0x17')],_0x2fe53c[_0x21ac3d('0x52')]);});},exports[_0x12e304('0x39')]=function(_0x410c2e,_0x510517,_0x2896a3,_0x2c1fba){const _0x5207e1=_0x12e304,_0x339ca0=apiai(_0x510517,{'language':_0x2c1fba||'en'});return _0x339ca0[_0x5207e1('0x21')](_0x2896a3,{'sessionId':md5(_0x410c2e)})[_0x5207e1('0x32')](function(_0x15c79d){const _0x58c44e=_0x5207e1;return logger[_0x58c44e('0x58')](JSON[_0x58c44e('0x74')](_0x15c79d)),{'source':_0x15c79d['result'][_0x58c44e('0x64')],'resolvedQuery':_0x15c79d['result']['resolvedQuery'],'action':_0x15c79d['result'][_0x58c44e('0x70')],'actionIncomplete':_0x15c79d[_0x58c44e('0x4a')][_0x58c44e('0x44')],'speech':_0x15c79d[_0x58c44e('0x4a')][_0x58c44e('0x43')][_0x58c44e('0x2a')],'score':_0x15c79d[_0x58c44e('0x4a')][_0x58c44e('0x71')],'statusCode':_0x15c79d['status'][_0x58c44e('0x55')],'endConversation':_0x15c79d[_0x58c44e('0x4a')][_0x58c44e('0x62')]['endConversation']||![],'isFallbackIntent':_0x15c79d[_0x58c44e('0x4a')]['metadata']['isFallbackIntent']};});},exports['googleDialogflowV2']=async function(_0x33838d,_0xd8536c,_0x3af8d1,_0x45ec8a,_0x3dec4d,_0xa4e9bb){const _0x2d53ef=_0x12e304,_0x147ef9=_0x45ec8a[_0x2d53ef('0xe')](/\\n/g,'\x0a'),_0x5a0d7d={'credentials':{'private_key':_0x147ef9,'client_email':_0x3af8d1}},_0x2afc3c=new dialogflow[(_0x2d53ef('0x65'))](_0x5a0d7d),_0x361a92=_0x2afc3c[_0x2d53ef('0xf')](_0xd8536c,md5(_0x33838d)),_0x3604fb={'session':_0x361a92,'queryInput':{'text':{'text':_0x3dec4d,'languageCode':_0xa4e9bb}}};try{const _0x156011=await _0x2afc3c[_0x2d53ef('0x1')](_0x3604fb);if(_0x156011&&_0x156011[_0x2d53ef('0x1c')]){logger['info'](_0x2d53ef('0x2d'),JSON[_0x2d53ef('0x74')](_0x156011));const _0x26892d=_0x156011[0x0];let _0x429516;return _0x26892d&&(_0x429516={'action':_0x26892d[_0x2d53ef('0x59')][_0x2d53ef('0x70')],'allRequiredParamsPresent':_0x26892d[_0x2d53ef('0x59')][_0x2d53ef('0x53')],'endConversation':_0x26892d[_0x2d53ef('0x59')][_0x2d53ef('0x5c')]&&_0x26892d['queryResult']['diagnosticInfo']['fields']?_0x26892d[_0x2d53ef('0x59')][_0x2d53ef('0x5c')][_0x2d53ef('0x41')][_0x2d53ef('0x5f')]['boolValue']:![],'fulfillmentText':_0x26892d[_0x2d53ef('0x59')][_0x2d53ef('0x8')],'intentName':_0x26892d[_0x2d53ef('0x59')]['intent'][_0x2d53ef('0x17')],'intentDisplayName':_0x26892d[_0x2d53ef('0x59')]['intent'][_0x2d53ef('0x68')],'isFallbackIntent':_0x26892d[_0x2d53ef('0x59')][_0x2d53ef('0x1f')][_0x2d53ef('0x76')],'languageCode':_0x26892d[_0x2d53ef('0x59')][_0x2d53ef('0x42')],'queryText':_0x26892d[_0x2d53ef('0x59')][_0x2d53ef('0x34')],'responseId':_0x26892d[_0x2d53ef('0x26')],'score':_0x26892d[_0x2d53ef('0x59')]['intentDetectionConfidence'],'speech':_0x26892d['queryResult'][_0x2d53ef('0x8')],'providerResponse':JSON[_0x2d53ef('0x74')](_0x156011)}),_0x429516;}}catch(_0x2b85cc){logger[_0x2d53ef('0x33')]('Dialogflow\x20V2\x20response\x20error:',_0x2b85cc);throw _0x2b85cc;}},exports[_0x12e304('0x4d')]=function(_0x2cd298,_0x255dad,_0x209e65,_0x5b32b3){const _0x2f7cdb=_0x12e304;return tilde[_0x2f7cdb('0x28')](_0x2cd298,_0x255dad,_0x209e65,_0x5b32b3)[_0x2f7cdb('0x32')](function(_0xe34d89){const _0x4f5853=_0x2f7cdb;try{fs[_0x4f5853('0x38')](_0x2cd298);}catch(_0x629bef){logger[_0x4f5853('0x33')](_0x629bef);}return logger[_0x4f5853('0x58')](_0x4f5853('0x14'),_0xe34d89['transcript']),logger[_0x4f5853('0x58')]('Tilde\x20ASR\x20confidence',_0xe34d89['confidence']),_0xe34d89;});},exports['awsPolly']=function(_0x12c6bd,_0x3d2e0d,_0x395f9f,_0x3f8c43,_0x48d274,_0x58f9db){const _0x52d14a=_0x12e304,_0x5f8083=path[_0x52d14a('0x57')](__dirname,_0x52d14a('0x5e'),rs[_0x52d14a('0x2c')](0x4)+_0x52d14a('0x12'));let _0x54b238;return aws[_0x52d14a('0x2b')](_0x12c6bd,_0x3d2e0d,_0x395f9f,_0x3f8c43,_0x48d274,_0x58f9db,_0x5f8083)[_0x52d14a('0x32')](function(){const _0x24ccae=_0x52d14a;return _0x54b238=path[_0x24ccae('0x57')](__dirname,'tmp',rs['generate'](0x4)+_0x24ccae('0x3c')),convertFile(_0x5f8083,_0x54b238);})[_0x52d14a('0x32')](function(){const _0x5e639b=_0x52d14a;try{fs[_0x5e639b('0x38')](_0x5f8083),fs['chmodSync'](_0x54b238,_0x5e639b('0x3d'));}catch(_0x4d2708){logger['error'](_0x4d2708);}return _0x54b238[_0x5e639b('0x5d')]('.')[0x0];});},exports[_0x12e304('0x11')]=function(_0x539730,_0x4917d6,_0xbb53c3,_0x53fcb2,_0x131a1b,_0x548a62){const _0x49b569=_0x12e304;return aws[_0x49b569('0x36')](_0x539730,_0x4917d6,_0xbb53c3,_0x53fcb2,_0x131a1b,_0x548a62)[_0x49b569('0x32')](function(_0x2d022d){const _0x3ba9c8=_0x49b569;return logger[_0x3ba9c8('0x58')](JSON[_0x3ba9c8('0x74')](_0x2d022d)),_0x2d022d;});},exports[_0x12e304('0xa')]=function(_0x11b4e5,_0xa6c7b7,_0x4b5aed,_0x191ce5){const _0x4020a5=_0x12e304,_0x9a2d2=util[_0x4020a5('0x1a')]('%s?apikey=%s&action=convert&text=%s&voice=%s&speed=%s&format=mp3',ISPEECH_API,_0x11b4e5,encodeURIComponent(_0xa6c7b7),_0x4b5aed,_0x191ce5),_0x1aae81=path[_0x4020a5('0x57')](__dirname,_0x4020a5('0x5e'),rs['generate'](0x4)+_0x4020a5('0x12'));let _0x3f45b2;return downloadFile(_0x9a2d2,_0x1aae81)[_0x4020a5('0x32')](function(){const _0x1512f4=_0x4020a5;return _0x3f45b2=path[_0x1512f4('0x57')](__dirname,'tmp',rs[_0x1512f4('0x2c')](0x4)+'.wav'),convertFile(_0x1aae81,_0x3f45b2);})[_0x4020a5('0x32')](function(){const _0x58cd25=_0x4020a5;try{fs[_0x58cd25('0x38')](_0x1aae81),fs[_0x58cd25('0xd')](_0x3f45b2,_0x58cd25('0x3d'));}catch(_0x3592bb){logger[_0x58cd25('0x33')](_0x3592bb);}return _0x3f45b2[_0x58cd25('0x5d')]('.')[0x0];});},exports['ispeechASR']=function(_0x1c16ff,_0x2f8404,_0x3b8037,_0x599fb3){const _0x12a63c=_0x12e304,_0xc35306=util[_0x12a63c('0x1a')]('%s?apikey=%s&action=recognize&locale=%s&content-type=audio/x-wav&audio=%s&%s',ISPEECH_API,_0x2f8404,_0x3b8037,base64Encode(_0x1c16ff),_0x599fb3?util['format']('model=%s',encodeURIComponent(_0x599fb3)):_0x12a63c('0x3a'));return uploadFile(_0xc35306)[_0x12a63c('0x32')](function(_0x1daf83){const _0x1db372=_0x12a63c;return querystring[_0x1db372('0x13')](_0x1daf83);});},exports[_0x12e304('0x45')]=function(_0x446dcb,_0x5ef866){const _0x1d56e8=_0x12e304;return sestek[_0x1d56e8('0x60')](_0x446dcb,_0x5ef866)[_0x1d56e8('0x32')](function(_0x30448f){const _0x1934b1=_0x1d56e8;logger['info'](JSON[_0x1934b1('0x74')](_0x30448f));const _0x39609b={'speech':_0x30448f[_0x1934b1('0x46')],'action':_0x30448f[_0x1934b1('0x2f')]?_0x30448f[_0x1934b1('0x2f')][_0x1934b1('0x79')]:undefined,'actiondata':_0x30448f['channelData']?_0x30448f[_0x1934b1('0x2f')]['CustomActionData']:undefined};if(_0x30448f[_0x1934b1('0x2f')]&&_0x30448f[_0x1934b1('0x2f')][_0x1934b1('0x20')])return base64Decode(_0x30448f[_0x1934b1('0x2f')][_0x1934b1('0x20')]['Data'],path[_0x1934b1('0x57')](__dirname,_0x1934b1('0x5e'),rs[_0x1934b1('0x2c')](0x4)+'.wav'))['then'](function(_0xa218aa){return _0x39609b['audiofile']=_0xa218aa,_0x39609b;});return _0x39609b;});},exports['dirName']=function(){return __dirname;}; \ No newline at end of file +const a1041_0x4e8b=['polly','google-tts-api','host','isFallback','audiofile','unlink','request\x20to\x20','MP3','resolve','speech','endConversation','confidence','./google','statusMessage','Tilde\x20ASR\x20confidence','join','allRequiredParamsPresent','%s?apikey=%s&action=convert&text=%s&voice=%s&speed=%s&format=mp3','resolvedQuery','SessionsClient','pathname','%s?apikey=%s&action=recognize&locale=%s&content-type=audio/x-wav&audio=%s&%s','generate','querystring','https://texttospeech.googleapis.com/v1/','tmp','nda','from','AudioFromTts','text:synthesize','diagnosticInfo','tildeASR','text','intentDetectionConfidence','model=%s','intent','action','queryResult','awsLex','name','ispeechASR','split','Dialogflow\x20V2\x20response:','http','lex','end_conversation','./tilde','\x20failed,\x20status\x20code\x20=\x20','util','close','boolValue','googleTTS','statusCode','fields','.mp3','@google-cloud/dialogflow','asr','writeFileSync','?key=','textRequest','https://api.ispeech.org/api/rest','https:','finish\x20to\x20convert','readFileSync','input','Tilde\x20ASR\x20transcription','goggleTTS\x20path','source','googleASR\x20confidence','createWriteStream','message','request-promise-native','apiai-promise','./sestek','chmodSync','stringify','awsPolly','projectAgentSessionPath','../../../config/logger','status','code','then','format','displayName','WHAT_EVER','wav','audioContent','queryText','parse','CustomActionData','randomstring','result','ispeechTTS','writeFile','agi','./aws','[%s]\x20%s:%s','metadata','fulfillment','map','fulfillmentText','channelData','CustomAction','protocol','catch','detectIntent','googleCloudTTS','length','googleDialogflowV2','base64','results','dirName','toString','googleASR\x20transcription','.wav','get','transcript','end','isFallbackIntent','Data','googleASR','info','error','777','alternatives','pipe'];(function(_0x19eb34,_0x4e8bbb){const _0x20145b=function(_0x45c651){while(--_0x45c651){_0x19eb34['push'](_0x19eb34['shift']());}};_0x20145b(++_0x4e8bbb);}(a1041_0x4e8b,0xb7));const a1041_0x2014=function(_0x19eb34,_0x4e8bbb){_0x19eb34=_0x19eb34-0x0;let _0x20145b=a1041_0x4e8b[_0x19eb34];return _0x20145b;};const _0x3d2f35=a1041_0x2014;'use strict';const fs=require('fs'),path=require('path'),http=require(_0x3d2f35('0x70')),https=require('https'),{URL}=require('url'),rs=require(_0x3d2f35('0x21')),sox=require('sox'),rp=require(_0x3d2f35('0xe')),util=require(_0x3d2f35('0x75')),querystring=require(_0x3d2f35('0x5c')),tts=require(_0x3d2f35('0x46')),apiai=require(_0x3d2f35('0xf')),md5=require('md5'),google=require(_0x3d2f35('0x51')),aws=require(_0x3d2f35('0x26')),tilde=require(_0x3d2f35('0x73')),sestek=require(_0x3d2f35('0x10')),dialogflow=require(_0x3d2f35('0x7c')),logger=require(_0x3d2f35('0x15'))(_0x3d2f35('0x25')),ISPEECH_API=_0x3d2f35('0x3');function downloadFile(_0x45c651,_0x7c1a49){return new Promise(function(_0x4b510e,_0x44ebb1){const _0x3aca4a=a1041_0x2014,_0x158359=new URL(_0x45c651),_0x109566=_0x158359['protocol']===_0x3aca4a('0x4')?https:http,_0x16796a={'host':_0x158359[_0x3aca4a('0x47')],'path':_0x158359[_0x3aca4a('0x59')],'headers':{'user-agent':_0x3aca4a('0x1b')}};_0x109566[_0x3aca4a('0x3a')](_0x16796a,function(_0x2bbd77){const _0x265224=_0x3aca4a;if(_0x2bbd77[_0x265224('0x79')]!==0xc8){logger[_0x265224('0x41')](_0x265224('0x4b')+_0x45c651+_0x265224('0x74')+_0x2bbd77['statusCode']+'\x20('+_0x2bbd77[_0x265224('0x52')]+')'),_0x44ebb1(new Error(_0x265224('0x4b')+_0x45c651+_0x265224('0x74')+_0x2bbd77[_0x265224('0x79')]+'\x20('+_0x2bbd77[_0x265224('0x52')]+')'));return;}const _0x55036e=fs[_0x265224('0xc')](_0x7c1a49);_0x55036e['on']('finish',function(){const _0x5da3f5=_0x265224;logger['info']('finish\x20download\x20file'),_0x55036e[_0x5da3f5('0x76')](_0x4b510e);}),_0x55036e['on'](_0x265224('0x41'),function(_0x2c6d25){const _0x17318b=_0x265224;fs[_0x17318b('0x4a')](_0x7c1a49),logger[_0x17318b('0x41')]('download\x20error',_0x2c6d25),_0x44ebb1(_0x2c6d25);}),_0x2bbd77[_0x265224('0x44')](_0x55036e);})['on']('error',function(_0x28399e){const _0x22ca48=_0x3aca4a;logger[_0x22ca48('0x41')](_0x28399e),_0x44ebb1(_0x28399e);})[_0x3aca4a('0x3c')]();});}function uploadFile(_0x297bbd){return new Promise(function(_0xd7dbae,_0xe7b3b){const _0x490614=a1041_0x2014,_0x18700a=new URL(_0x297bbd),_0x1e5033=_0x18700a[_0x490614('0x2e')]===_0x490614('0x4')?https:http,_0x3ac2a9={'host':_0x18700a[_0x490614('0x47')],'path':_0x18700a[_0x490614('0x59')],'headers':{'user-agent':_0x490614('0x1b')}};_0x1e5033[_0x490614('0x3a')](_0x3ac2a9,function(_0x304cf9){const _0x5e2513=_0x490614;if(_0x304cf9[_0x5e2513('0x79')]!==0xc8){_0xe7b3b(new Error('request\x20to\x20'+_0x297bbd+_0x5e2513('0x74')+_0x304cf9['statusCode']+'\x20('+_0x304cf9[_0x5e2513('0x52')]+')'));return;}let _0x12342d='';_0x304cf9['on']('data',function(_0x409e31){_0x12342d+=_0x409e31;}),_0x304cf9['on'](_0x5e2513('0x3c'),function(){_0xd7dbae(_0x12342d);});})['on'](_0x490614('0x41'),function(_0x59dc45){_0xe7b3b(_0x59dc45);})[_0x490614('0x3c')]();});}function convertFile(_0xb26750,_0x1ccde3){return new Promise(function(_0x1b6dbe,_0x3c65f2){const _0x55f9c8=a1041_0x2014,_0x8bdc49=sox['transcode'](_0xb26750,_0x1ccde3,{'sampleRate':0x1f40,'format':_0x55f9c8('0x1c'),'channelCount':0x1,'bitRate':0xc0*0x400,'compressionQuality':0x5});_0x8bdc49['on'](_0x55f9c8('0x41'),function(_0xa26849){const _0x4e9ea5=_0x55f9c8;logger[_0x4e9ea5('0x41')]('error\x20convert',_0xa26849),_0x3c65f2(_0xa26849);}),_0x8bdc49['on']('end',function(){const _0x10f5e6=_0x55f9c8;logger['info'](_0x10f5e6('0x5')),_0x1b6dbe();}),_0x8bdc49['start']();});}function base64Decode(_0x34357c,_0x5cd5dc){const _0x451a5d=_0x3d2f35,_0x539310=path[_0x451a5d('0x4d')](__dirname,_0x451a5d('0x5e'),rs[_0x451a5d('0x5b')](0x4)+_0x451a5d('0x39'));return fs[_0x451a5d('0x0')](_0x539310,_0x34357c,'base64'),convertFile(_0x539310,_0x5cd5dc)[_0x451a5d('0x18')](function(){const _0x38b7b8=_0x451a5d;try{fs['unlink'](_0x539310),fs[_0x38b7b8('0x11')](_0x5cd5dc,'777');}catch(_0x5bb367){logger[_0x38b7b8('0x41')](_0x5bb367);}return _0x5cd5dc[_0x38b7b8('0x6e')]('.')[0x0];});}function base64Encode(_0x145d01){const _0x3b8fb7=_0x3d2f35,_0xcd92da=fs[_0x3b8fb7('0x6')](_0x145d01);return Buffer[_0x3b8fb7('0x60')](_0xcd92da)[_0x3b8fb7('0x37')](_0x3b8fb7('0x34'));}exports[_0x3d2f35('0x31')]=function(_0x55b12a,_0x5a4e34,_0x4bc707,_0x21dd6d,_0x34d815){const _0x236af2=_0x3d2f35;let _0x174989,_0x20b9e1;const _0x1e5527=_0x236af2('0x5d'),_0x4bbba7=_0x236af2('0x1')+_0x55b12a,_0x577f78={};_0x5a4e34==='ssml'?_0x577f78[_0x236af2('0x7')]={'ssml':_0x4bc707}:_0x577f78[_0x236af2('0x7')]={'text':_0x4bc707};_0x577f78['voice']={'languageCode':_0x21dd6d,'ssmlGender':_0x34d815},_0x577f78['audioConfig']={'audioEncoding':_0x236af2('0x4c'),'sampleRateHertz':0x1f40};const _0xe0e4bd={'url':_0x1e5527+_0x236af2('0x62')+_0x4bbba7,'method':'POST','json':!![],'body':_0x577f78};return rp(_0xe0e4bd)[_0x236af2('0x18')](function(_0x3208ca){return new Promise(function(_0x44db3a,_0x20f319){const _0x85ec26=a1041_0x2014;_0x174989=path[_0x85ec26('0x4d')](__dirname,_0x85ec26('0x5e'),rs[_0x85ec26('0x5b')](0x4)+_0x85ec26('0x7b'));const _0x152923=Buffer[_0x85ec26('0x60')](_0x3208ca[_0x85ec26('0x1d')],_0x85ec26('0x34'));return fs[_0x85ec26('0x24')](_0x174989,_0x152923,function(_0x16bf6e){_0x20f319(_0x16bf6e);},function(_0x5edfe4){const _0x4d50be=_0x85ec26;fs['chmodSync'](_0x174989,_0x4d50be('0x42')),_0x44db3a(_0x5edfe4);});});})[_0x236af2('0x18')](function(){const _0x5d8fd=_0x236af2;return _0x20b9e1=path[_0x5d8fd('0x4d')](__dirname,'tmp',rs[_0x5d8fd('0x5b')](0x4)+_0x5d8fd('0x39')),convertFile(_0x174989,_0x20b9e1);})['then'](function(){const _0x5bd908=_0x236af2;try{fs['unlink'](_0x174989),fs[_0x5bd908('0x11')](_0x20b9e1,_0x5bd908('0x42'));}catch(_0x12e851){logger['error'](_0x12e851);}return logger['info']('googleCloudTTS\x20path',_0x20b9e1[_0x5bd908('0x6e')]('.')[0x0]),_0x20b9e1['split']('.')[0x0];});},exports[_0x3d2f35('0x78')]=function(_0x362ee3,_0xfd97f0){const _0xc0f4de=_0x3d2f35;let _0x41c80a,_0x5568ca;return tts(_0x362ee3,_0xfd97f0||'en',0x1)[_0xc0f4de('0x18')](function(_0x15112f){const _0x244b1a=_0xc0f4de;return logger[_0x244b1a('0x40')](_0x15112f),_0x41c80a=path['resolve'](__dirname,_0x244b1a('0x5e'),rs[_0x244b1a('0x5b')](0x4)+'.mp3'),downloadFile(_0x15112f,_0x41c80a);})[_0xc0f4de('0x18')](function(){const _0x5b9772=_0xc0f4de;return _0x5568ca=path[_0x5b9772('0x4d')](__dirname,'tmp',rs[_0x5b9772('0x5b')](0x4)+_0x5b9772('0x39')),convertFile(_0x41c80a,_0x5568ca);})[_0xc0f4de('0x18')](function(){const _0x27633c=_0xc0f4de;try{fs[_0x27633c('0x4a')](_0x41c80a),fs[_0x27633c('0x11')](_0x5568ca,_0x27633c('0x42'));}catch(_0x4408fb){logger[_0x27633c('0x41')](_0x4408fb);}return logger[_0x27633c('0x40')](_0x27633c('0x9'),_0x5568ca[_0x27633c('0x6e')]('.')[0x0]),_0x5568ca[_0x27633c('0x6e')]('.')[0x0];});},exports[_0x3d2f35('0x3f')]=function(_0x10b537,_0x18d95d,_0x18fb7f){const _0x5c3d7f=_0x3d2f35;return google['asr'](_0x10b537,_0x18d95d,_0x18fb7f)[_0x5c3d7f('0x18')](function(_0x588f50){return logger['info'](_0x588f50['uri']),rp(_0x588f50);})[_0x5c3d7f('0x18')](function(_0x5d480a){const _0x37eb87=_0x5c3d7f;let _0x50695c='',_0x38aad6=0x0;try{fs[_0x37eb87('0x4a')](_0x10b537);}catch(_0x34d213){logger[_0x37eb87('0x41')](_0x34d213);}return _0x5d480a&&_0x5d480a['results']&&(_0x50695c=_0x5d480a[_0x37eb87('0x35')][_0x37eb87('0x2a')](function(_0x57cc52){const _0x57b150=_0x37eb87;return _0x57cc52&&_0x57cc52['alternatives'][0x0]&&_0x57cc52['alternatives'][0x0]['transcript']?_0x57cc52[_0x57b150('0x43')][0x0][_0x57b150('0x3b')]:'';})[_0x37eb87('0x54')]('\x0a'),_0x38aad6=_0x5d480a[_0x37eb87('0x35')][_0x37eb87('0x2a')](function(_0x2a8885){const _0x1be5ca=_0x37eb87;return _0x2a8885&&_0x2a8885[_0x1be5ca('0x43')][0x0]&&_0x2a8885[_0x1be5ca('0x43')][0x0][_0x1be5ca('0x50')]?_0x2a8885[_0x1be5ca('0x43')][0x0][_0x1be5ca('0x50')]:0x0;})['join']('\x0a')),logger[_0x37eb87('0x40')](_0x37eb87('0x38'),_0x50695c),logger[_0x37eb87('0x40')](_0x37eb87('0xb'),_0x38aad6),{'transcript':_0x50695c,'confidence':_0x38aad6};})[_0x5c3d7f('0x2f')](function(_0x5155f1){const _0x17c2aa=_0x5c3d7f;logger[_0x17c2aa('0x41')](_0x17c2aa('0x27'),_0x5155f1[_0x17c2aa('0x79')],_0x5155f1['name'],_0x5155f1[_0x17c2aa('0xd')]);});},exports['googleDialogflow']=function(_0x4ea5bb,_0x5c3968,_0x868299,_0x4e2e0b){const _0x147572=_0x3d2f35,_0x5e41f8=apiai(_0x5c3968,{'language':_0x4e2e0b||'en'});return _0x5e41f8[_0x147572('0x2')](_0x868299,{'sessionId':md5(_0x4ea5bb)})[_0x147572('0x18')](function(_0x43f936){const _0x2691ad=_0x147572;return logger[_0x2691ad('0x40')](JSON[_0x2691ad('0x12')](_0x43f936)),{'source':_0x43f936[_0x2691ad('0x22')][_0x2691ad('0xa')],'resolvedQuery':_0x43f936['result'][_0x2691ad('0x57')],'action':_0x43f936[_0x2691ad('0x22')][_0x2691ad('0x69')],'actionIncomplete':_0x43f936[_0x2691ad('0x22')]['actionIncomplete'],'speech':_0x43f936[_0x2691ad('0x22')][_0x2691ad('0x29')][_0x2691ad('0x4e')],'score':_0x43f936[_0x2691ad('0x22')]['score'],'statusCode':_0x43f936[_0x2691ad('0x16')][_0x2691ad('0x17')],'endConversation':_0x43f936['result'][_0x2691ad('0x28')][_0x2691ad('0x4f')]||![],'isFallbackIntent':_0x43f936[_0x2691ad('0x22')][_0x2691ad('0x28')][_0x2691ad('0x3d')]};});},exports[_0x3d2f35('0x33')]=async function(_0x17fba0,_0xa89def,_0x177d7f,_0xd6e941,_0x69a978,_0x4de5b3){const _0x46a16f=_0x3d2f35,_0x15a6fb=_0xd6e941['replace'](/\\n/g,'\x0a'),_0x115d21={'credentials':{'private_key':_0x15a6fb,'client_email':_0x177d7f}},_0x4d20df=new dialogflow[(_0x46a16f('0x58'))](_0x115d21),_0x39a86e=_0x4d20df[_0x46a16f('0x14')](_0xa89def,md5(_0x17fba0)),_0x1e46a7={'session':_0x39a86e,'queryInput':{'text':{'text':_0x69a978,'languageCode':_0x4de5b3}}};try{const _0x4f3c87=await _0x4d20df[_0x46a16f('0x30')](_0x1e46a7);if(_0x4f3c87&&_0x4f3c87[_0x46a16f('0x32')]){logger[_0x46a16f('0x40')](_0x46a16f('0x6f'),JSON[_0x46a16f('0x12')](_0x4f3c87));const _0x538ee0=_0x4f3c87[0x0];let _0x3cdcd9;return _0x538ee0&&(_0x3cdcd9={'action':_0x538ee0[_0x46a16f('0x6a')][_0x46a16f('0x69')],'allRequiredParamsPresent':_0x538ee0[_0x46a16f('0x6a')][_0x46a16f('0x55')],'endConversation':_0x538ee0['queryResult'][_0x46a16f('0x63')]&&_0x538ee0[_0x46a16f('0x6a')][_0x46a16f('0x63')][_0x46a16f('0x7a')]?_0x538ee0[_0x46a16f('0x6a')][_0x46a16f('0x63')][_0x46a16f('0x7a')][_0x46a16f('0x72')][_0x46a16f('0x77')]:![],'fulfillmentText':_0x538ee0[_0x46a16f('0x6a')][_0x46a16f('0x2b')],'intentName':_0x538ee0['queryResult'][_0x46a16f('0x68')][_0x46a16f('0x6c')],'intentDisplayName':_0x538ee0['queryResult'][_0x46a16f('0x68')][_0x46a16f('0x1a')],'isFallbackIntent':_0x538ee0[_0x46a16f('0x6a')][_0x46a16f('0x68')][_0x46a16f('0x48')],'languageCode':_0x538ee0['queryResult']['languageCode'],'queryText':_0x538ee0[_0x46a16f('0x6a')][_0x46a16f('0x1e')],'responseId':_0x538ee0['responseId'],'score':_0x538ee0[_0x46a16f('0x6a')][_0x46a16f('0x66')],'speech':_0x538ee0['queryResult'][_0x46a16f('0x2b')],'providerResponse':JSON[_0x46a16f('0x12')](_0x4f3c87)}),_0x3cdcd9;}}catch(_0x4b33ae){logger[_0x46a16f('0x41')]('Dialogflow\x20V2\x20response\x20error:',_0x4b33ae);throw _0x4b33ae;}},exports[_0x3d2f35('0x64')]=function(_0x28c367,_0x53e09e,_0x3e317d,_0x3d4638){const _0x5ce371=_0x3d2f35;return tilde[_0x5ce371('0x7d')](_0x28c367,_0x53e09e,_0x3e317d,_0x3d4638)[_0x5ce371('0x18')](function(_0x520be7){const _0x216e7a=_0x5ce371;try{fs[_0x216e7a('0x4a')](_0x28c367);}catch(_0x404816){logger[_0x216e7a('0x41')](_0x404816);}return logger[_0x216e7a('0x40')](_0x216e7a('0x8'),_0x520be7[_0x216e7a('0x3b')]),logger[_0x216e7a('0x40')](_0x216e7a('0x53'),_0x520be7['confidence']),_0x520be7;});},exports[_0x3d2f35('0x13')]=function(_0x53a381,_0x3f6f5d,_0x1959ae,_0x36fde4,_0x1f2c9b,_0x4bb60a){const _0x38ecdb=_0x3d2f35,_0x3d13eb=path['resolve'](__dirname,_0x38ecdb('0x5e'),rs[_0x38ecdb('0x5b')](0x4)+_0x38ecdb('0x7b'));let _0x15a7e2;return aws[_0x38ecdb('0x45')](_0x53a381,_0x3f6f5d,_0x1959ae,_0x36fde4,_0x1f2c9b,_0x4bb60a,_0x3d13eb)['then'](function(){const _0x53c9df=_0x38ecdb;return _0x15a7e2=path['resolve'](__dirname,'tmp',rs['generate'](0x4)+_0x53c9df('0x39')),convertFile(_0x3d13eb,_0x15a7e2);})[_0x38ecdb('0x18')](function(){const _0x52acfb=_0x38ecdb;try{fs[_0x52acfb('0x4a')](_0x3d13eb),fs['chmodSync'](_0x15a7e2,'777');}catch(_0x4580ec){logger[_0x52acfb('0x41')](_0x4580ec);}return _0x15a7e2[_0x52acfb('0x6e')]('.')[0x0];});},exports[_0x3d2f35('0x6b')]=function(_0x22be1a,_0x2b971b,_0x5550da,_0x56dfbd,_0x25de32,_0x3ca066){const _0x12255e=_0x3d2f35;return aws[_0x12255e('0x71')](_0x22be1a,_0x2b971b,_0x5550da,_0x56dfbd,_0x25de32,_0x3ca066)['then'](function(_0x216f05){const _0x599705=_0x12255e;return logger[_0x599705('0x40')](JSON[_0x599705('0x12')](_0x216f05)),_0x216f05;});},exports[_0x3d2f35('0x23')]=function(_0x5f4169,_0x44debe,_0x3ed12d,_0x11d023){const _0x11ec37=_0x3d2f35,_0x419d88=util[_0x11ec37('0x19')](_0x11ec37('0x56'),ISPEECH_API,_0x5f4169,encodeURIComponent(_0x44debe),_0x3ed12d,_0x11d023),_0x1e4436=path[_0x11ec37('0x4d')](__dirname,_0x11ec37('0x5e'),rs[_0x11ec37('0x5b')](0x4)+_0x11ec37('0x7b'));let _0x43c5e2;return downloadFile(_0x419d88,_0x1e4436)['then'](function(){const _0xfb0871=_0x11ec37;return _0x43c5e2=path[_0xfb0871('0x4d')](__dirname,_0xfb0871('0x5e'),rs[_0xfb0871('0x5b')](0x4)+_0xfb0871('0x39')),convertFile(_0x1e4436,_0x43c5e2);})['then'](function(){const _0x144bb9=_0x11ec37;try{fs['unlink'](_0x1e4436),fs[_0x144bb9('0x11')](_0x43c5e2,_0x144bb9('0x42'));}catch(_0xe45a47){logger[_0x144bb9('0x41')](_0xe45a47);}return _0x43c5e2[_0x144bb9('0x6e')]('.')[0x0];});},exports[_0x3d2f35('0x6d')]=function(_0x29c828,_0x3c23bd,_0x359e89,_0x55ec5d){const _0x2699ee=_0x3d2f35,_0x4898e9=util[_0x2699ee('0x19')](_0x2699ee('0x5a'),ISPEECH_API,_0x3c23bd,_0x359e89,base64Encode(_0x29c828),_0x55ec5d?util['format'](_0x2699ee('0x67'),encodeURIComponent(_0x55ec5d)):'freeform=3');return uploadFile(_0x4898e9)[_0x2699ee('0x18')](function(_0x4b4187){const _0x22f6c4=_0x2699ee;return querystring[_0x22f6c4('0x1f')](_0x4b4187);});},exports['sestekNDA']=function(_0x11de17,_0x4abeca){const _0x4c8558=_0x3d2f35;return sestek[_0x4c8558('0x5f')](_0x11de17,_0x4abeca)['then'](function(_0x386f4e){const _0x21ae23=_0x4c8558;logger['info'](JSON[_0x21ae23('0x12')](_0x386f4e));const _0x43994c={'speech':_0x386f4e[_0x21ae23('0x65')],'action':_0x386f4e[_0x21ae23('0x2c')]?_0x386f4e[_0x21ae23('0x2c')][_0x21ae23('0x2d')]:undefined,'actiondata':_0x386f4e['channelData']?_0x386f4e[_0x21ae23('0x2c')][_0x21ae23('0x20')]:undefined};if(_0x386f4e['channelData']&&_0x386f4e['channelData'][_0x21ae23('0x61')])return base64Decode(_0x386f4e['channelData']['AudioFromTts'][_0x21ae23('0x3e')],path[_0x21ae23('0x4d')](__dirname,_0x21ae23('0x5e'),rs[_0x21ae23('0x5b')](0x4)+_0x21ae23('0x39')))['then'](function(_0x1dbe73){const _0xbfa8cc=_0x21ae23;return _0x43994c[_0xbfa8cc('0x49')]=_0x1dbe73,_0x43994c;});return _0x43994c;});},exports[_0x3d2f35('0x36')]=function(){return __dirname;}; \ No newline at end of file diff --git a/server/services/agi/scripts/sestek/index.js b/server/services/agi/scripts/sestek/index.js index 6b5e2a9..660aae0 100644 --- a/server/services/agi/scripts/sestek/index.js +++ b/server/services/agi/scripts/sestek/index.js @@ -1 +1 @@ -const a1042_0x6fcc=['exports'];(function(_0x5f17d0,_0x6fccf7){const _0x8857c5=function(_0x499b65){while(--_0x499b65){_0x5f17d0['push'](_0x5f17d0['shift']());}};_0x8857c5(++_0x6fccf7);}(a1042_0x6fcc,0x113));const a1042_0x8857=function(_0x5f17d0,_0x6fccf7){_0x5f17d0=_0x5f17d0-0x0;let _0x8857c5=a1042_0x6fcc[_0x5f17d0];return _0x8857c5;};const _0x464d3d=a1042_0x8857,nda=require('./nda');module[_0x464d3d('0x0')]={'nda':nda}; \ No newline at end of file +const a1042_0x45cb=['./nda','exports'];(function(_0xba101d,_0x45cb47){const _0x451ceb=function(_0x2f157e){while(--_0x2f157e){_0xba101d['push'](_0xba101d['shift']());}};_0x451ceb(++_0x45cb47);}(a1042_0x45cb,0x7f));const a1042_0x451c=function(_0xba101d,_0x45cb47){_0xba101d=_0xba101d-0x0;let _0x451ceb=a1042_0x45cb[_0xba101d];return _0x451ceb;};const _0x4a39e2=a1042_0x451c,nda=require(_0x4a39e2('0x1'));module[_0x4a39e2('0x0')]={'nda':nda}; \ No newline at end of file diff --git a/server/services/agi/scripts/sestek/nda/index.js b/server/services/agi/scripts/sestek/nda/index.js index 619b8c8..873d8de 100644 --- a/server/services/agi/scripts/sestek/nda/index.js +++ b/server/services/agi/scripts/sestek/nda/index.js @@ -1 +1 @@ -const a1043_0x3fc0=['then','uniqueid','AudioOutputSettings','ProjectName','text','URL','ndaactivity_type','POST','message','ndauth_url','CustomAction','custom_action','stringify','exports','../../../../../config/logger','CustomActionData','ndagenerate_audio','channelData','project','agi','url','info','password','custom_action_data','access_token','calleridname','body','dnid','ndassistant_url','/token','toString'];(function(_0x31d0d7,_0x3fc058){const _0x25b989=function(_0x3a871f){while(--_0x3a871f){_0x31d0d7['push'](_0x31d0d7['shift']());}};_0x25b989(++_0x3fc058);}(a1043_0x3fc0,0x76));const a1043_0x25b9=function(_0x31d0d7,_0x3fc058){_0x31d0d7=_0x31d0d7-0x0;let _0x25b989=a1043_0x3fc0[_0x31d0d7];return _0x25b989;};const _0x41a89d=a1043_0x25b9;'use strict';const rp=require('request-promise-native'),url=require(_0x41a89d('0x1a')),logger=require(_0x41a89d('0x14'))(_0x41a89d('0x19'));module[_0x41a89d('0x13')]=function(_0x3a871f,_0x426185){const _0x378db0=_0x41a89d,_0x315739=new url[(_0x378db0('0xb'))](_0x378db0('0x4'),_0x426185[_0x378db0('0xf')])[_0x378db0('0x5')](),_0x15f77e={'method':_0x378db0('0xd'),'uri':_0x315739,'form':{'grant_type':_0x378db0('0x1c'),'username':_0x426185['username'],'password':_0x426185[_0x378db0('0x1c')]},'json':!![]};return rp(_0x15f77e)[_0x378db0('0x6')](function(_0x31349f){const _0x162a77=_0x378db0,_0x5ebed8=new url[(_0x162a77('0xb'))]('/api/NaturalDialogAssistant/v1/Run',_0x426185[_0x162a77('0x3')])[_0x162a77('0x5')](),_0x4cde8e={'method':_0x162a77('0xd'),'uri':_0x5ebed8,'body':{'type':_0x426185[_0x162a77('0xc')]||_0x162a77('0xe'),'channelId':'Nda','conversation':{'id':_0x3a871f[_0x162a77('0x7')]},'from':{'id':_0x3a871f['callerid'],'name':_0x3a871f[_0x162a77('0x0')]},'recipient':{'id':_0x3a871f[_0x162a77('0x2')],'name':_0x3a871f['extension']},'text':_0x426185[_0x162a77('0xa')],'channelData':{}},'headers':{'Authorization':'Bearer\x20'+_0x31349f[_0x162a77('0x1e')]},'json':!![]};return _0x426185[_0x162a77('0x18')]&&(_0x4cde8e['body'][_0x162a77('0x17')][_0x162a77('0x9')]=_0x426185[_0x162a77('0x18')]),_0x426185[_0x162a77('0x16')]=='1'&&(_0x4cde8e[_0x162a77('0x1')][_0x162a77('0x17')][_0x162a77('0x8')]={'Generate':!![],'PutInStructuredPart':![],'ExpectedFormat':'audio/wav'}),_0x426185[_0x162a77('0x11')]&&(_0x4cde8e[_0x162a77('0x1')][_0x162a77('0x17')][_0x162a77('0x10')]=_0x426185[_0x162a77('0x11')],_0x426185[_0x162a77('0x1d')]&&(_0x4cde8e[_0x162a77('0x1')][_0x162a77('0x17')][_0x162a77('0x15')]=_0x426185[_0x162a77('0x1d')])),logger[_0x162a77('0x1b')](JSON[_0x162a77('0x12')](_0x4cde8e)),rp(_0x4cde8e);});}; \ No newline at end of file +const a1043_0x5196=['../../../../../config/logger','/token','extension','url','custom_action','/api/NaturalDialogAssistant/v1/Run','toString','custom_action_data','message','exports','ndaactivity_type','CustomActionData','project','request-promise-native','callerid','agi','AudioOutputSettings','body','ndauth_url','calleridname','password','ProjectName','username','uniqueid','POST','Nda','channelData','then'];(function(_0x4974e8,_0x5196f1){const _0x417fc5=function(_0x30662b){while(--_0x30662b){_0x4974e8['push'](_0x4974e8['shift']());}};_0x417fc5(++_0x5196f1);}(a1043_0x5196,0x1cc));const a1043_0x417f=function(_0x4974e8,_0x5196f1){_0x4974e8=_0x4974e8-0x0;let _0x417fc5=a1043_0x5196[_0x4974e8];return _0x417fc5;};const _0x51972a=a1043_0x417f;'use strict';const rp=require(_0x51972a('0x1')),url=require(_0x51972a('0x13')),logger=require(_0x51972a('0x10'))(_0x51972a('0x3'));module[_0x51972a('0x19')]=function(_0x30662b,_0x4d55e2){const _0xc1460=_0x51972a,_0x429954=new url['URL'](_0xc1460('0x11'),_0x4d55e2[_0xc1460('0x6')])[_0xc1460('0x16')](),_0x573e58={'method':_0xc1460('0xc'),'uri':_0x429954,'form':{'grant_type':_0xc1460('0x8'),'username':_0x4d55e2[_0xc1460('0xa')],'password':_0x4d55e2[_0xc1460('0x8')]},'json':!![]};return rp(_0x573e58)[_0xc1460('0xf')](function(_0x40ca67){const _0x58962e=_0xc1460,_0x41ce72=new url['URL'](_0x58962e('0x15'),_0x4d55e2['ndassistant_url'])['toString'](),_0x12212f={'method':'POST','uri':_0x41ce72,'body':{'type':_0x4d55e2[_0x58962e('0x1a')]||_0x58962e('0x18'),'channelId':_0x58962e('0xd'),'conversation':{'id':_0x30662b[_0x58962e('0xb')]},'from':{'id':_0x30662b[_0x58962e('0x2')],'name':_0x30662b[_0x58962e('0x7')]},'recipient':{'id':_0x30662b['dnid'],'name':_0x30662b[_0x58962e('0x12')]},'text':_0x4d55e2['text'],'channelData':{}},'headers':{'Authorization':'Bearer\x20'+_0x40ca67['access_token']},'json':!![]};return _0x4d55e2[_0x58962e('0x0')]&&(_0x12212f['body'][_0x58962e('0xe')][_0x58962e('0x9')]=_0x4d55e2[_0x58962e('0x0')]),_0x4d55e2['ndagenerate_audio']=='1'&&(_0x12212f[_0x58962e('0x5')][_0x58962e('0xe')][_0x58962e('0x4')]={'Generate':!![],'PutInStructuredPart':![],'ExpectedFormat':'audio/wav'}),_0x4d55e2['custom_action']&&(_0x12212f[_0x58962e('0x5')][_0x58962e('0xe')]['CustomAction']=_0x4d55e2[_0x58962e('0x14')],_0x4d55e2[_0x58962e('0x17')]&&(_0x12212f[_0x58962e('0x5')][_0x58962e('0xe')][_0x58962e('0x1b')]=_0x4d55e2[_0x58962e('0x17')])),logger['info'](JSON['stringify'](_0x12212f)),rp(_0x12212f);});}; \ No newline at end of file diff --git a/server/services/agi/scripts/tilde/asr/index.js b/server/services/agi/scripts/tilde/asr/index.js index bb0e291..b73a22f 100644 --- a/server/services/agi/scripts/tilde/asr/index.js +++ b/server/services/agi/scripts/tilde/asr/index.js @@ -1 +1 @@ -const a1044_0x56bb=['./lib/api','exports'];(function(_0x16cf0b,_0x56bbc3){const _0x40f195=function(_0x4109e5){while(--_0x4109e5){_0x16cf0b['push'](_0x16cf0b['shift']());}};_0x40f195(++_0x56bbc3);}(a1044_0x56bb,0x151));const a1044_0x40f1=function(_0x16cf0b,_0x56bbc3){_0x16cf0b=_0x16cf0b-0x0;let _0x40f195=a1044_0x56bb[_0x16cf0b];return _0x40f195;};const _0x2733ca=a1044_0x40f1;'use strict';const asr=require(_0x2733ca('0x1'));module[_0x2733ca('0x0')]=function(_0x4109e5,_0x47c55a,_0x57ae61,_0x560652){return asr(_0x4109e5,_0x47c55a,_0x57ae61,_0x560652);}; \ No newline at end of file +const a1044_0x2843=['./lib/api'];(function(_0x290fab,_0x284303){const _0x5d7fa3=function(_0x135f37){while(--_0x135f37){_0x290fab['push'](_0x290fab['shift']());}};_0x5d7fa3(++_0x284303);}(a1044_0x2843,0x136));const a1044_0x5d7f=function(_0x290fab,_0x284303){_0x290fab=_0x290fab-0x0;let _0x5d7fa3=a1044_0x2843[_0x290fab];return _0x5d7fa3;};const _0x7012a0=a1044_0x5d7f;'use strict';const asr=require(_0x7012a0('0x0'));module['exports']=function(_0x135f37,_0x78acdb,_0x5b7bf2,_0x4d3364){return asr(_0x135f37,_0x78acdb,_0x5b7bf2,_0x4d3364);}; \ No newline at end of file diff --git a/server/services/agi/scripts/tilde/asr/lib/api.js b/server/services/agi/scripts/tilde/asr/lib/api.js index 67fda41..ef7606a 100644 --- a/server/services/agi/scripts/tilde/asr/lib/api.js +++ b/server/services/agi/scripts/tilde/asr/lib/api.js @@ -1 +1 @@ -const a1045_0x1029=['Authentication\x20failed.','No\x20speech.\x20Sent\x20when\x20the\x20incoming\x20audio\x20contains\x20a\x20large\x20portion\x20of\x20silence\x20or\x20non-speech','Tilde\x20ASR\x20hypoteses','result','transcript','Tilde\x20URI','isObject','terminate','final','info','open','sha1','Success.','stringify','agi','isNil','hex','Not\x20available.\x20Max\x20load\x20limit\x20reached.','error','Tilde\x20ASR\x20send\x20error','hypotheses','close','Aborted.\x20Recognition\x20was\x20aborted\x20for\x20some\x20reason.','data','Tilde\x20ASR\x20parse\x20error','Close\x20Tilde\x20ASR\x20socket','digest','crypto','lodash','moment','send','Open\x20Tilde\x20ASR\x20socket','createReadStream','parse','All\x20recognition\x20workers\x20are\x20currently\x20in\x20use\x20and\x20real-time\x20recognition\x20is\x20not\x20possible.','wss://runa.tilde.lv/client/ws/speech/LVASR-ONLINE','likelihood','unix','Error\x20Tilde\x20ASR\x20socket','status'];(function(_0x22554e,_0x1029f5){const _0x3ccb53=function(_0x2fd18a){while(--_0x2fd18a){_0x22554e['push'](_0x22554e['shift']());}};_0x3ccb53(++_0x1029f5);}(a1045_0x1029,0x14c));const a1045_0x3ccb=function(_0x22554e,_0x1029f5){_0x22554e=_0x22554e-0x0;let _0x3ccb53=a1045_0x1029[_0x22554e];return _0x3ccb53;};const _0x9b6e06=a1045_0x3ccb;'use strict';const _=require(_0x9b6e06('0x10')),fs=require('fs'),WebSocket=require('ws'),moment=require(_0x9b6e06('0x11')),crypto=require(_0x9b6e06('0xf')),logger=require('../../../../../../config/logger')(_0x9b6e06('0x2'));module['exports']=function(_0x2fd18a,_0x93422a,_0x219115,_0x34edf6){return new Promise(function(_0xd167c0){const _0x4c0701=a1045_0x3ccb;logger[_0x4c0701('0x25')](_0x4c0701('0x21'),_0x34edf6||'wss://runa.tilde.lv/client/ws/speech/LVASR-ONLINE');const _0x1e8123=new WebSocket(_0x34edf6||_0x4c0701('0x17'),{'perMessageDeflate':![]});let _0x17caea='',_0x27cb2b='0',_0x2c121a='1',_0x11fb72='No\x20speech.\x20Sent\x20when\x20the\x20incoming\x20audio\x20contains\x20a\x20large\x20portion\x20of\x20silence\x20or\x20non-speech';function _0x4f3f80(_0x87ae14){const _0x4b6b13=_0x4c0701,_0x32af37=crypto['createHash'](_0x4b6b13('0x27'));return _0x32af37['update'](_0x87ae14),_0x32af37[_0x4b6b13('0xe')](_0x4b6b13('0x4'));}function _0x51d60d(){const _0xfd9ebe=_0x4c0701;try{logger[_0xfd9ebe('0x25')](_0xfd9ebe('0x13'));const _0x596043=moment()[_0xfd9ebe('0x19')](),_0x445f75=_0x4f3f80(_0x596043+_0x93422a+_0x219115);_0x1e8123['send'](JSON[_0xfd9ebe('0x1')]({'appID':_0x93422a,'timestamp':_0x596043,'appKey':_0x445f75}));const _0x402e1b=fs[_0xfd9ebe('0x14')](_0x2fd18a);_0x402e1b['on'](_0xfd9ebe('0xb'),function(_0x2c1cd0){_0x1e8123['send'](_0x2c1cd0);}),_0x402e1b['on'](_0xfd9ebe('0x9'),function(){const _0x1135ea=_0xfd9ebe;_0x1e8123[_0x1135ea('0x12')]('EOS');});}catch(_0x497190){logger[_0xfd9ebe('0x6')](_0xfd9ebe('0x7'),JSON[_0xfd9ebe('0x1')](_0x497190)),_0x1e8123[_0xfd9ebe('0x23')]();}}function _0x224f60(_0x394aea){const _0x406961=_0x4c0701;try{if(_0x394aea){const _0x113826=JSON[_0x406961('0x15')](_0x394aea);switch(_0x113826[_0x406961('0x1b')]){case 0x0:_0x113826[_0x406961('0x1f')]&&(_0x113826[_0x406961('0x1f')][_0x406961('0x24')]&&(logger['info'](_0x406961('0x1e'),JSON[_0x406961('0x1')](_0x113826[_0x406961('0x1f')][_0x406961('0x8')])),_0x17caea=_0x113826[_0x406961('0x1f')]['hypotheses'][0x0][_0x406961('0x20')],_0x27cb2b=_0x113826[_0x406961('0x1f')]['hypotheses'][0x0][_0x406961('0x18')],_0x2c121a='0',_0x11fb72=_0x406961('0x0'),_0x1e8123[_0x406961('0x23')]()));break;case 0x1:logger[_0x406961('0x25')](_0x406961('0x1d')),_0x2c121a='1',_0x11fb72='No\x20speech.\x20Sent\x20when\x20the\x20incoming\x20audio\x20contains\x20a\x20large\x20portion\x20of\x20silence\x20or\x20non-speech';break;case 0x2:logger[_0x406961('0x25')](_0x406961('0xa')),_0x2c121a='2',_0x11fb72=_0x406961('0xa');break;case 0x9:logger[_0x406961('0x25')](_0x406961('0x5')),_0x2c121a='9',_0x11fb72=_0x406961('0x5');break;case 0xa:logger['info']('Authentication\x20failed.'),_0x2c121a='10',_0x11fb72=_0x406961('0x1c');break;case 0xb:logger['info'](_0x406961('0x16')),_0x2c121a='11',_0x11fb72=_0x406961('0x16');}}}catch(_0x36d87b){logger[_0x406961('0x6')](_0x406961('0xc'),JSON[_0x406961('0x1')](_0x36d87b)),_0x1e8123[_0x406961('0x23')]();}}function _0x226755(){const _0x4cfe3d=_0x4c0701;logger[_0x4cfe3d('0x25')](_0x4cfe3d('0xd')),_0xd167c0({'transcript':_0x17caea,'confidence':_0x27cb2b,'status':_0x2c121a,'status_message':_0x11fb72});}function _0x19d265(_0x35bdbe){const _0x2cbbdd=_0x4c0701;logger[_0x2cbbdd('0x6')](_0x2cbbdd('0x1a')),!_[_0x2cbbdd('0x3')](_0x35bdbe)&&logger[_0x2cbbdd('0x6')](_[_0x2cbbdd('0x22')](_0x35bdbe)?JSON[_0x2cbbdd('0x1')](_0x35bdbe):_0x35bdbe);}_0x1e8123['on'](_0x4c0701('0x26'),_0x51d60d),_0x1e8123['on']('message',_0x224f60),_0x1e8123['on'](_0x4c0701('0x9'),_0x226755),_0x1e8123['on'](_0x4c0701('0x6'),_0x19d265);});}; \ No newline at end of file +const a1045_0x2e46=['createReadStream','No\x20speech.\x20Sent\x20when\x20the\x20incoming\x20audio\x20contains\x20a\x20large\x20portion\x20of\x20silence\x20or\x20non-speech','message','transcript','Open\x20Tilde\x20ASR\x20socket','send','status','parse','Not\x20available.\x20Max\x20load\x20limit\x20reached.','stringify','data','likelihood','moment','update','Tilde\x20ASR\x20hypoteses','unix','info','terminate','crypto','isObject','isNil','Success.','error','exports','wss://runa.tilde.lv/client/ws/speech/LVASR-ONLINE','sha1','All\x20recognition\x20workers\x20are\x20currently\x20in\x20use\x20and\x20real-time\x20recognition\x20is\x20not\x20possible.','../../../../../../config/logger','EOS','Tilde\x20ASR\x20send\x20error','Authentication\x20failed.','createHash','digest','hypotheses','Tilde\x20URI','Aborted.\x20Recognition\x20was\x20aborted\x20for\x20some\x20reason.','open','close','lodash','result'];(function(_0x358451,_0x2e465a){const _0x2efef7=function(_0x5962f1){while(--_0x5962f1){_0x358451['push'](_0x358451['shift']());}};_0x2efef7(++_0x2e465a);}(a1045_0x2e46,0x16f));const a1045_0x2efe=function(_0x358451,_0x2e465a){_0x358451=_0x358451-0x0;let _0x2efef7=a1045_0x2e46[_0x358451];return _0x2efef7;};const _0x1c4b41=a1045_0x2efe;'use strict';const _=require(_0x1c4b41('0x1f')),fs=require('fs'),WebSocket=require('ws'),moment=require(_0x1c4b41('0x5')),crypto=require(_0x1c4b41('0xb')),logger=require(_0x1c4b41('0x14'))('agi');module[_0x1c4b41('0x10')]=function(_0x5962f1,_0x343f2f,_0x389992,_0x6a871c){return new Promise(function(_0x123604){const _0xc19afd=a1045_0x2efe;logger[_0xc19afd('0x9')](_0xc19afd('0x1b'),_0x6a871c||_0xc19afd('0x11'));const _0x1c3fbe=new WebSocket(_0x6a871c||'wss://runa.tilde.lv/client/ws/speech/LVASR-ONLINE',{'perMessageDeflate':![]});let _0x5d5679='',_0x227b8e='0',_0xa32e9c='1',_0x3357b8=_0xc19afd('0x22');function _0x1c8735(_0x5426a5){const _0x32ff15=_0xc19afd,_0x4423a7=crypto[_0x32ff15('0x18')](_0x32ff15('0x12'));return _0x4423a7[_0x32ff15('0x6')](_0x5426a5),_0x4423a7[_0x32ff15('0x19')]('hex');}function _0x4a1f35(){const _0x25bf71=_0xc19afd;try{logger['info'](_0x25bf71('0x25'));const _0x315db1=moment()[_0x25bf71('0x8')](),_0x2667f9=_0x1c8735(_0x315db1+_0x343f2f+_0x389992);_0x1c3fbe['send'](JSON['stringify']({'appID':_0x343f2f,'timestamp':_0x315db1,'appKey':_0x2667f9}));const _0x5bf1f2=fs[_0x25bf71('0x21')](_0x5962f1);_0x5bf1f2['on'](_0x25bf71('0x3'),function(_0x2a731e){const _0x5ace5a=_0x25bf71;_0x1c3fbe[_0x5ace5a('0x26')](_0x2a731e);}),_0x5bf1f2['on'](_0x25bf71('0x1e'),function(){const _0x449606=_0x25bf71;_0x1c3fbe[_0x449606('0x26')](_0x449606('0x15'));});}catch(_0x69283e){logger[_0x25bf71('0xf')](_0x25bf71('0x16'),JSON[_0x25bf71('0x2')](_0x69283e)),_0x1c3fbe[_0x25bf71('0xa')]();}}function _0x1d5341(_0x21d6ea){const _0x222486=_0xc19afd;try{if(_0x21d6ea){const _0x354d56=JSON[_0x222486('0x0')](_0x21d6ea);switch(_0x354d56[_0x222486('0x27')]){case 0x0:_0x354d56[_0x222486('0x20')]&&(_0x354d56[_0x222486('0x20')]['final']&&(logger['info'](_0x222486('0x7'),JSON['stringify'](_0x354d56['result'][_0x222486('0x1a')])),_0x5d5679=_0x354d56[_0x222486('0x20')][_0x222486('0x1a')][0x0][_0x222486('0x24')],_0x227b8e=_0x354d56[_0x222486('0x20')]['hypotheses'][0x0][_0x222486('0x4')],_0xa32e9c='0',_0x3357b8=_0x222486('0xe'),_0x1c3fbe[_0x222486('0xa')]()));break;case 0x1:logger[_0x222486('0x9')](_0x222486('0x22')),_0xa32e9c='1',_0x3357b8='No\x20speech.\x20Sent\x20when\x20the\x20incoming\x20audio\x20contains\x20a\x20large\x20portion\x20of\x20silence\x20or\x20non-speech';break;case 0x2:logger[_0x222486('0x9')](_0x222486('0x1c')),_0xa32e9c='2',_0x3357b8=_0x222486('0x1c');break;case 0x9:logger[_0x222486('0x9')](_0x222486('0x1')),_0xa32e9c='9',_0x3357b8=_0x222486('0x1');break;case 0xa:logger[_0x222486('0x9')](_0x222486('0x17')),_0xa32e9c='10',_0x3357b8=_0x222486('0x17');break;case 0xb:logger[_0x222486('0x9')](_0x222486('0x13')),_0xa32e9c='11',_0x3357b8='All\x20recognition\x20workers\x20are\x20currently\x20in\x20use\x20and\x20real-time\x20recognition\x20is\x20not\x20possible.';}}}catch(_0x47c01a){logger[_0x222486('0xf')]('Tilde\x20ASR\x20parse\x20error',JSON[_0x222486('0x2')](_0x47c01a)),_0x1c3fbe['terminate']();}}function _0xea9efe(){logger['info']('Close\x20Tilde\x20ASR\x20socket'),_0x123604({'transcript':_0x5d5679,'confidence':_0x227b8e,'status':_0xa32e9c,'status_message':_0x3357b8});}function _0x24b336(_0x8176bd){const _0x1e9fc8=_0xc19afd;logger['error']('Error\x20Tilde\x20ASR\x20socket'),!_[_0x1e9fc8('0xd')](_0x8176bd)&&logger['error'](_[_0x1e9fc8('0xc')](_0x8176bd)?JSON[_0x1e9fc8('0x2')](_0x8176bd):_0x8176bd);}_0x1c3fbe['on'](_0xc19afd('0x1d'),_0x4a1f35),_0x1c3fbe['on'](_0xc19afd('0x23'),_0x1d5341),_0x1c3fbe['on'](_0xc19afd('0x1e'),_0xea9efe),_0x1c3fbe['on'](_0xc19afd('0xf'),_0x24b336);});}; \ No newline at end of file diff --git a/server/services/agi/scripts/tilde/index.js b/server/services/agi/scripts/tilde/index.js index dd5eeab..38e63cf 100644 --- a/server/services/agi/scripts/tilde/index.js +++ b/server/services/agi/scripts/tilde/index.js @@ -1 +1 @@ -const a1046_0x4393=['exports','./asr'];(function(_0x57286e,_0x439331){const _0x5b6835=function(_0x1c09ce){while(--_0x1c09ce){_0x57286e['push'](_0x57286e['shift']());}};_0x5b6835(++_0x439331);}(a1046_0x4393,0xe5));const a1046_0x5b68=function(_0x57286e,_0x439331){_0x57286e=_0x57286e-0x0;let _0x5b6835=a1046_0x4393[_0x57286e];return _0x5b6835;};const _0x109f8d=a1046_0x5b68,asr=require(_0x109f8d('0x0'));module[_0x109f8d('0x1')]={'asr':asr}; \ No newline at end of file +const a1046_0x3354=['./asr','exports'];(function(_0x312e2d,_0x335473){const _0x915ab2=function(_0x9f84a7){while(--_0x9f84a7){_0x312e2d['push'](_0x312e2d['shift']());}};_0x915ab2(++_0x335473);}(a1046_0x3354,0xb6));const a1046_0x915a=function(_0x312e2d,_0x335473){_0x312e2d=_0x312e2d-0x0;let _0x915ab2=a1046_0x3354[_0x312e2d];return _0x915ab2;};const _0x5df824=a1046_0x915a,asr=require(_0x5df824('0x0'));module[_0x5df824('0x1')]={'asr':asr}; \ No newline at end of file diff --git a/server/services/agi/server.js b/server/services/agi/server.js index 82ec01b..169e44b 100644 --- a/server/services/agi/server.js +++ b/server/services/agi/server.js @@ -1 +1 @@ -const a1047_0x2c4e=['call','getConnections','createServer','close','error','E_AGI_SERVER_CLOSE','E_AGI_SERVER_ERROR','./error','listening','connection','destroy','E_AGI_SERVER_VOICE_DISABLED','nextTick','emit','E_AGI_SERVER_MAXCONNECTION','E_AGI_ARGUMENT_PORT','./channel','events','ready','listen','127.0.0.1'];(function(_0x1035ae,_0x2c4e66){const _0x1dd3d6=function(_0x552e05){while(--_0x552e05){_0x1035ae['push'](_0x1035ae['shift']());}};_0x1dd3d6(++_0x2c4e66);}(a1047_0x2c4e,0xb6));const a1047_0x1dd3=function(_0x1035ae,_0x2c4e66){_0x1035ae=_0x1035ae-0x0;let _0x1dd3d6=a1047_0x2c4e[_0x1035ae];return _0x1dd3d6;};const _0x362260=a1047_0x1dd3;'use strict';const util=require('util'),net=require('net'),EventEmitter=require(_0x362260('0x3'))['EventEmitter'],AGIError=require(_0x362260('0xe')),AGIChannel=require(_0x362260('0x2')),AGIServer=function(_0x552e05,_0x22e765,_0x155ddf){const _0x4ee6a8=_0x362260,_0x36499d=this;_0x552e05=_0x552e05||0x11dd,_0x22e765=_0x22e765||_0x4ee6a8('0x6');let _0x2169b6=null,_0x3b4cd0=0x0;EventEmitter[_0x4ee6a8('0x7')](_0x36499d);function _0x21e07b(){const _0x516709=_0x4ee6a8;if(!_0x552e05)return _0x36499d[_0x516709('0x14')](_0x516709('0xb'),new AGIError(_0x516709('0x1'))),![];_0x2169b6=net[_0x516709('0x9')](),_0x2169b6[_0x516709('0x5')](_0x552e05,_0x22e765),_0x2169b6['on'](_0x516709('0xf'),function(){const _0x500370=_0x516709;_0x36499d[_0x500370('0x14')](_0x500370('0xf'));}),_0x2169b6['on'](_0x516709('0x10'),function(_0x4595e5){const _0x296ecc=_0x516709;_0x2169b6[_0x296ecc('0x8')](function(_0x3ef4d9,_0x210401){const _0x559a22=_0x296ecc;if(_0x3ef4d9)_0x36499d[_0x559a22('0x14')](_0x559a22('0xb'),new AGIError(_0x559a22('0xd'),_0x3ef4d9));else{if(_0x155ddf&&_0x155ddf<0x0)_0x36499d['emit'](_0x559a22('0xb'),new AGIError(_0x559a22('0x12'))),_0x4595e5[_0x559a22('0x11')]();else{if(_0x155ddf&&_0x155ddf>0x0&&_0x155ddf<_0x210401)_0x3b4cd0+=0x1,_0x36499d['emit'](_0x559a22('0xb'),new AGIError(_0x559a22('0x0'),_0x3b4cd0)),_0x4595e5[_0x559a22('0x11')]();else{const _0x2a3eb2=new AGIChannel(_0x4595e5);_0x2a3eb2['on'](_0x559a22('0x4'),function(){const _0x53d1ae=_0x559a22;_0x36499d['emit'](_0x53d1ae('0x10'),_0x2a3eb2);});}}}});}),_0x2169b6['on'](_0x516709('0xb'),function(_0xe70ec5){const _0x539bf0=_0x516709;_0x36499d[_0x539bf0('0x14')](_0x539bf0('0xb'),new AGIError('E_AGI_SERVER_ERROR',_0xe70ec5['code']));}),_0x2169b6['on'](_0x516709('0xa'),function(){const _0x243d5a=_0x516709;_0x36499d[_0x243d5a('0x14')]('close',new AGIError(_0x243d5a('0xc')));});}process[_0x4ee6a8('0x13')](function(){_0x21e07b();});};util['inherits'](AGIServer,EventEmitter),module['exports']=function(_0x4ced8a,_0x4df241,_0x3ebe15){return new AGIServer(_0x4ced8a,_0x4df241,_0x3ebe15);}; \ No newline at end of file +const a1047_0x14ed=['destroy','E_AGI_ARGUMENT_PORT','call','E_AGI_SERVER_MAXCONNECTION','exports','listening','./error','close','emit','E_AGI_SERVER_VOICE_DISABLED','./channel','127.0.0.1','createServer','error','util','code','ready','nextTick','connection','E_AGI_SERVER_ERROR','events','inherits'];(function(_0x5068e3,_0x14edca){const _0x20fde4=function(_0x1f22b3){while(--_0x1f22b3){_0x5068e3['push'](_0x5068e3['shift']());}};_0x20fde4(++_0x14edca);}(a1047_0x14ed,0x139));const a1047_0x20fd=function(_0x5068e3,_0x14edca){_0x5068e3=_0x5068e3-0x0;let _0x20fde4=a1047_0x14ed[_0x5068e3];return _0x20fde4;};const _0x4686f1=a1047_0x20fd;'use strict';const util=require(_0x4686f1('0x9')),net=require('net'),EventEmitter=require(_0x4686f1('0xf'))['EventEmitter'],AGIError=require(_0x4686f1('0x1')),AGIChannel=require(_0x4686f1('0x5')),AGIServer=function(_0x1f22b3,_0x33fb29,_0xb11228){const _0x4965ca=_0x4686f1,_0x1dde33=this;_0x1f22b3=_0x1f22b3||0x11dd,_0x33fb29=_0x33fb29||_0x4965ca('0x6');let _0x12bd86=null,_0x1e6ac2=0x0;EventEmitter[_0x4965ca('0x13')](_0x1dde33);function _0x517d1b(){const _0x55d8e8=_0x4965ca;if(!_0x1f22b3)return _0x1dde33[_0x55d8e8('0x3')]('error',new AGIError(_0x55d8e8('0x12'))),![];_0x12bd86=net[_0x55d8e8('0x7')](),_0x12bd86['listen'](_0x1f22b3,_0x33fb29),_0x12bd86['on'](_0x55d8e8('0x0'),function(){const _0x44062a=_0x55d8e8;_0x1dde33['emit'](_0x44062a('0x0'));}),_0x12bd86['on'](_0x55d8e8('0xd'),function(_0x52cc0d){_0x12bd86['getConnections'](function(_0x1d7d55,_0x476f71){const _0x4049b9=a1047_0x20fd;if(_0x1d7d55)_0x1dde33[_0x4049b9('0x3')](_0x4049b9('0x8'),new AGIError(_0x4049b9('0xe'),_0x1d7d55));else{if(_0xb11228&&_0xb11228<0x0)_0x1dde33['emit']('error',new AGIError(_0x4049b9('0x4'))),_0x52cc0d[_0x4049b9('0x11')]();else{if(_0xb11228&&_0xb11228>0x0&&_0xb11228<_0x476f71)_0x1e6ac2+=0x1,_0x1dde33[_0x4049b9('0x3')](_0x4049b9('0x8'),new AGIError(_0x4049b9('0x14'),_0x1e6ac2)),_0x52cc0d['destroy']();else{const _0x529dfb=new AGIChannel(_0x52cc0d);_0x529dfb['on'](_0x4049b9('0xb'),function(){const _0x1b8aa0=_0x4049b9;_0x1dde33[_0x1b8aa0('0x3')](_0x1b8aa0('0xd'),_0x529dfb);});}}}});}),_0x12bd86['on'](_0x55d8e8('0x8'),function(_0x15b6c0){const _0x1e2ee6=_0x55d8e8;_0x1dde33['emit']('error',new AGIError(_0x1e2ee6('0xe'),_0x15b6c0[_0x1e2ee6('0xa')]));}),_0x12bd86['on'](_0x55d8e8('0x2'),function(){const _0xf02ced=_0x55d8e8;_0x1dde33[_0xf02ced('0x3')](_0xf02ced('0x2'),new AGIError('E_AGI_SERVER_CLOSE'));});}process[_0x4965ca('0xc')](function(){_0x517d1b();});};util[_0x4686f1('0x10')](AGIServer,EventEmitter),module[_0x4686f1('0x15')]=function(_0x21c68e,_0x5dc455,_0xbfe5f6){return new AGIServer(_0x21c68e,_0x5dc455,_0xbfe5f6);}; \ No newline at end of file diff --git a/server/services/agi/vertices.js b/server/services/agi/vertices.js index 72d27c1..5e8d904 100644 --- a/server/services/agi/vertices.js +++ b/server/services/agi/vertices.js @@ -1 +1 @@ -const a1048_0x2ed0=['dialogflow_language','odbc_id','getSquareOdbc','Executed\x20command\x20MRCPRecog\x20%s','password','sh\x20command:\x20%s\x20result\x20on\x20variable:\x20%s','test','getVariable','no\x20sms\x20account\x20found','ext_dial','agentLogin','sestekNDA','format','tildeasr','no\x20appsecret\x20configured','createSquareMessage','answer','no\x20mail\x20account\x20found','GOAL\x20%s','catch','SESTEK_ASR_INSTANCE','%s[%s]','queue','debug','DIALOGFLOW_%s','providerResponse','Enter\x20in\x20GOOGLEASR\x20(%s)\x20block\x20%s','start','variable\x20%s\x20set','setVariable','operation','Enter\x20in\x20CUSTOM\x20APP\x20(%s)\x20block','saynumber','Google\x20Cloud\x20TTS\x20%s\x20file\x20created','phone','IntervalId','bcc','vswitch','maxRetry','getMailAccountById','200','noop','%s/recordings/%s.%s','agi://%s/square,\x22%s\x22,\x22%s\x22','Enter\x20in\x20MRCPSynth\x20(%s)\x20block','sendSMS\x20message','util','IspeechASR\x20Result\x20%s','extra','sendMailMessage','exports','sestektts','no\x20mail\x20account\x20configured','Enter\x20in\x20SENDSMS\x20(%s)\x20block','googleDialogflowV2','username','Dialogflow\x20Result\x20%s','Enter\x20in\x20FINALLY\x20(%s)\x20block','AGI','aws_secret_access_key','isEmpty','awsLex','project_id','getData','macro','aws_lex_region','TildeASR\x20Result\x20%s','saydigits','intKey','An\x20incorrect\x20formatted\x20json\x20body\x20has\x20been\x20passed\x20to\x20the\x20function','toUpperCase','system','unpause','undefined','Enter\x20in\x20SESTEKASR\x20(%s)\x20block','no\x20file\x20audio\x20found','findBy','createSquareRecording','isArray','Enter\x20in\x20CALLBACK\x20(%s)\x20block','agent','Enter\x20in\x20PAUSE\x20(%s)\x20block','Enter\x20in\x20MRCPRecog\x20(%s)\x20block','Intervals','Skipped\x20Answer','isNil','goalname','logout','getVoiceQueue','ndauth_url','google\x20%s\x20file\x20created','awsPolly','sms_text','lumenvoxtts','no\x20password\x20configured','%s/recordings/%s','computedVariables','no\x20interval\x20configured','pause_id','%s[%s][%s]','Enter\x20in\x20SET\x20(%s)\x20block','Enter\x20in\x20SWITCH\x20(%s)\x20block','lumenvoxasr','Error\x20getting\x20ODBC\x20connection\x20%s','Smtp','MRCPRecog','getPauseById','substr','ispeechASR','query','SestekNDA\x20is\x20unreachable','aws_bot_name','Enter\x20in\x20SAYDIGITS\x20(%s)\x20block','no\x20query\x20configured','includes','getVariableById','Mail\x20message\x20added\x20to\x20outgoing\x20process','Enter\x20in\x20GOTO\x20(%s)\x20block','arg_1','Enter\x20in\x20DIAL\x20(%s)\x20block','sendSMS','no\x20database\x20selected','sendMail\x20message','model','no\x20condition\x20configured','Executed\x20command\x20MRCPSynth\x20%s','escape_digits','getSoundPath','callerid','condition','TILDE_ASR_%s','text','no\x20find\x20by\x20configured','hiddendigitsnum','Enter\x20in\x20TILDEASR\x20(%s)\x20block','inspect','no\x20key\x20configured','true','no\x20apiKey\x20configured','no\x20intervals\x20found','interval','no\x20variable\x20found','aws_polly_region','LOCAL','subproject','audiofile','IFTIME(%s?true:false)','127.0.0.1','Google\x20TTS\x20is\x20unreachable','mailbox','speech','playback','retry','no\x20text\x20configured','mindigit','Enter\x20in\x20SAYPHONETIC\x20(%s)\x20block','channel','no\x20queue\x20found','command','Enter\x20in\x20SUBPROJECT\x20(%s)\x20block','no\x20user\x20selected','Query\x20executed\x20correctly\x20%s','port','method','createSmsMessage','getsecretdigits','MALE','getAndSetVariable','isPlainObject','Trying\x20Dialogflow:\x20%s','RECOG_INSTANCE()','SENDFAX\x20block\x20not\x20implemented','message','Enter\x20in\x20EXTERNAL\x20DIAL\x20(%s)\x20block','Response:','getSquareProject','PUT','tilde\x20%s\x20file\x20created','delay','Recording\x20%s\x20%s\x20%s\x20%s','Enter\x20in\x20AGI\x20(%s)\x20block','sendFax','getTrunk','stringify','googleASR','DIAL','forEach','gotoc','exec','appsecret','google_tts_language','recursiveNodeIndex','close','opts','FIND\x20AGENT\x20%s\x20BY\x20%s','MRCP_RECOG_TRANSCRIPT','getPause','toLowerCase','minutes','getSound','map','Enter\x20in\x20ISPEECHTTS\x20(%s)\x20block','Dialogflow\x20is\x20unreachable','Error\x20executing\x20query\x20%s','Executed\x20command\x20%s','callback_','gosub','replaceObjectAllVariables','Enter\x20in\x20GETSECRETDIGITS\x20(%s)\x20block','application','render','getQueryOdbc','Enter\x20in\x20SENDMAIL\x20(%s)\x20block','SESTEK_ASR_CONFIDENCE','sip_id','auth','../../config/logger','lastName','ispeech_asr_language','.wav','no\x20grammar\x20configured','rawHeaders','bot','url','IFTIME\x20%s\x20%s','Enter\x20in\x20SESTEKNDA\x20(%s)\x20block','length','account_id','Enter\x20in\x20UNPAUSE\x20(%s)\x20block','recordFile','Enter\x20in\x20MENU\x20(%s)\x20block','SestekNDA\x20Result\x20%s','Enter\x20in\x20HANGUP\x20(%s)\x20block','getSmsAccountById','body','maxdigit','no\x20ndauth\x20url\x20configured','agentUnpause','no\x20project_id\x20configured','lodash','callback','An\x20incorrect\x20formatted\x20json\x20has\x20been\x20passed\x20to\x20the\x20function','\x22%s\x22\x20<%s>','dialogflowV2_project_id','Trying\x20aws\x20Polly\x20%s','rpc','agentPause','tildeASR','Google\x20TTS\x20%s\x20file\x20created','then','parse','getIntervals','EVAL\x20CONDITION\x20%s\x20%s','failure','no\x20variable\x20selected\x20for\x20the\x20result','headers','AGENT\x20%s\x20NOT\x20FOUND\x20BY','callback_priority','Enter\x20in\x20SYSTEM\x20(%s)\x20block','response','custom_app','clone','restapi','%s_STATUS_MESSAGE','Enter\x20in\x20GOTOIF\x20(%s)\x20block','Trying\x20DialogflowV2:\x20%s','MRCP_RECOG_INSTANCE','subject','error','getVoiceQueueById','MRCPSynth','XMCS-QUEUE','RECOG_CONFIDENCE()','email','getIntervalById','QUEUE','indexOf','set','VOICEMAIL','ispeechTTS','toString','../../config/environment','no\x20valid\x20credentials\x20configured','googleTTS','Enter\x20in\x20SAYNUMBER\x20(%s)\x20block','no\x20private_key\x20configured','An\x20incorrect\x20formatted\x20json\x20headers\x20has\x20been\x20passed\x20to\x20the\x20function','accountcode','Enter\x20in\x20Google\x20Cloud\x20TTS\x20(%s)\x20block','uri','statusMessage','Amazon\x20Lex\x20ready\x20for\x20fulfillment','POST','getSquareProjectById','googleDialogflow','Enter\x20in\x20DATABASE\x20(%s)\x20block','no\x20user\x20found','LUMENVOX_ASR_INSTANCE','request-promise-native','createSquareDetailsReport','languageCode','Sestek\x20NDA\x20%s\x20file\x20created','Enter\x20in\x20LUMENVOXASR\x20(%s)\x20block','join','streamFile','user','no\x20anguage\x20configured','key','variable_id','ODBC\x20connection\x20successfully','host','Trying\x20SendSMS\x20with\x20account\x20%s','priority','getMailAccount','odbc','Sms\x20message\x20added\x20to\x20outgoing\x20process','randomstring','Unable\x20to\x20set\x20result\x20in\x20variable\x20%s','label','GoogleASR\x20Result\x20%s','no\x20appid\x20configured','result','NOBEEP','awspolly','isString','unlink','AWS_LEX_%s','variable\x20%s[key]\x20set','agi','Enter\x20in\x20PLAYBACK\x20(%s)\x20block','uniqueid','file','replaceAllVariables','./scripts','grammar','START\x20CALLY\x20SQUARE','getSmsAccount','voicemail','[AGI]\x20Enter\x20in\x20AWSPOLLY\x20(%s)\x20block','secure','file_id','finally','dialogflow','ssmlGender','ISPEECH_ASR_%s','%s_ROWS_COUNT','Amazon\x20Lex\x20Result\x20%s','first','ispeech\x20TTS\x20is\x20unreachable','calleridname','private_key','database','interval_id','LUMENVOX_ASR_CONFIDENCE','digit','name','amazonlex','no\x20trunk\x20selected','statusCode','tts','info','trunk_name','getUser','prototype','no\x20username\x20configured','extension','Enter\x20in\x20QUEUE\x20(%s)\x20block','hangup','Enter\x20in\x20GETDIGITS\x20(%s)\x20block','menu','Enter\x20in\x20GOOGLETTS\x20(%s)\x20block','no\x20file\x20audio\x20selected','sayPhonetic','no\x20url\x20configured','Callback\x20scheduled\x20at\x20','agentLogout','no\x20subproject\x20selected','en-US','restAPI','dsn','no\x20subproject\x20found\x20with\x20id\x20%d','RECOG_INPUT()','rawBody','Enter\x20in\x20RECORD\x20(%s)\x20block','getSquareOdbcById','false','Wait\x20%s\x20seconds\x20before\x20answer','Enter\x20in\x20LOGIN\x20(%s)\x20block','login','dialogflowV2','context','Amazon\x20Lex\x20is\x20unreachable','Executed\x20command\x20%s\x20%s','generate','createCmContact','success','googleCloudTTS','trunk_id','recordingFormat','getdigits','number','timeout','yes','trim','beep','no\x20trunk\x20found','Enter\x20in\x20DIALOGFLOW\x20(%s)\x20block','open','no\x20variable\x20selected','Enter\x20in\x20SESTEKTTS\x20(%s)\x20block','isConfigured','end','sayphonetic','no\x20odbc\x20database\x20found','options','wav','speed','replaceAll','google_asr_language','Enter\x20in\x20VOICEMAIL\x20(%s)\x20block','DialogflowV2\x20is\x20unreachable','queue_id','PLAYBACK','continueAt','Enter\x20in\x20ANSWER\x20(%s)\x20block','RECORDING_SAVENAME','sayNumber','apiKey','shellCommand','out','list_id','%s_%s','saveRestApiResult','google_cloud_tts_text_type','SESTEK_ASR_TRANSCRIPT','/var/opt/motion2/server/files','replace','Enter\x20in\x20LUMENVOXTTS\x20(%s)\x20block','Trying\x20SendMail\x20with\x20account\x20%s','%s_STATUS_CODE','scheduledAt','variable_value','sh\x20command:\x20%s\x20result\x20no\x20stored','no\x20client_email\x20configured','aws_access_key_id','args','%s.%s','client_email','%s/sounds/converted/%s','sms_account_id','query:\x20%s','Amy','Enter\x20in\x20Amazon\x20Lex\x20(%s)\x20block','SESTEK_NDA_%s','CALLBACK\x20added\x20phone:\x20%s\x20on\x20list:\x20%s\x20at\x20%s','sayDigits','Enter\x20in\x20NOOP\x20(%s)\x20block','MRCP_RECOG_CONFIDENCE','Trying\x20ispeech\x20TTS\x20%s','getTrunkById','sync','ispeechtts','dialogflowV2_language','Enter\x20in\x20GOAL\x20(%s)\x20block','Enter\x20in\x20ISPEECHASR\x20(%s)\x20block','sesteknda','split','AGENT\x20%s\x20FOUND\x20BY'];(function(_0x225ccc,_0x2ed0ef){const _0x39ef9a=function(_0x4ff956){while(--_0x4ff956){_0x225ccc['push'](_0x225ccc['shift']());}};_0x39ef9a(++_0x2ed0ef);}(a1048_0x2ed0,0x90));const a1048_0x39ef=function(_0x225ccc,_0x2ed0ef){_0x225ccc=_0x225ccc-0x0;let _0x39ef9a=a1048_0x2ed0[_0x225ccc];return _0x39ef9a;};const _0x1e747f=a1048_0x39ef;'use strict';const fs=require('fs'),util=require(_0x1e747f('0x172')),_=require(_0x1e747f('0x5f')),sh=require('shelljs'),odbc=require(_0x1e747f('0xaa')),rs=require(_0x1e747f('0xac')),moment=require('moment'),Mustache=require('mustache'),rp=require(_0x1e747f('0x9a')),logger=require(_0x1e747f('0x48'))(_0x1e747f('0xb8')),config=require(_0x1e747f('0x89')),scripts=require(_0x1e747f('0xbd')),FILES_PATH=_0x1e747f('0x123'),recursiveMapAttributes=[_0x1e747f('0x4d'),_0x1e747f('0xee')],verticesWithRetry=['menu','getdigits',_0x1e747f('0x15')],AGIVertices=function(_0x4ff956,_0x551e9d,_0x375827){const _0x24d83c=_0x1e747f;this[_0x24d83c('0xc')]=_0x4ff956,this[_0x24d83c('0x65')]=_0x551e9d,this['mailRpc']=_0x375827;};AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x14b')]=function(_0x138231,_0x28abb9){const _0xae152a=_0x1e747f;this[_0xae152a('0x65')][_0xae152a('0x1b7')](_0x138231)['then'](function(_0x5c0fc8){const _0xdba587=_0xae152a;_0x28abb9(null,_0x5c0fc8?_0x5c0fc8[_0xdba587('0xd3')]:![]);})[_0xae152a('0x157')](function(_0x9c854a){_0x28abb9(_0x9c854a);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x19c')]=function(_0x5b38b0,_0x3791af){const _0x20dd41=_0x1e747f;this[_0x20dd41('0x65')][_0x20dd41('0x7d')](_0x5b38b0)[_0x20dd41('0x69')](function(_0x485f10){const _0xd5865b=_0x20dd41;_0x3791af(null,_0x485f10?_0x485f10[_0xd5865b('0xd3')]:![]);})[_0x20dd41('0x157')](function(_0x3753f3){_0x3791af(_0x3753f3);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x1f')]=function(_0x2014b2,_0x50dd5e){const _0x1a6140=_0x1e747f;this[_0x1a6140('0x65')][_0x1a6140('0x95')](_0x2014b2)['then'](function(_0xda62fd){const _0x463424=_0x1a6140;_0x50dd5e(null,_0xda62fd?_0xda62fd[_0x463424('0xd3')]:![]);})[_0x1a6140('0x157')](function(_0x3dc3db){_0x50dd5e(_0x3dc3db);});},AGIVertices[_0x1e747f('0xdb')]['getSquareOdbc']=function(_0x4e011a,_0x473eb1){const _0x39d0d3=_0x1e747f;this[_0x39d0d3('0x65')][_0x39d0d3('0xf0')](_0x4e011a)[_0x39d0d3('0x69')](function(_0x505020){const _0x19cf5b=_0x39d0d3;_0x473eb1(null,_0x505020?_0x505020[_0x19cf5b('0xeb')]:![]);})[_0x39d0d3('0x157')](function(_0x564018){_0x473eb1(_0x564018);});},AGIVertices['prototype']['getUser']=function(_0x413824,_0x44a527){const _0x175bac=_0x1e747f;this[_0x175bac('0x65')]['getUserById'](_0x413824)[_0x175bac('0x69')](function(_0x11c363){_0x44a527(null,_0x11c363?_0x11c363['name']:![]);})[_0x175bac('0x157')](function(_0xb79f6a){_0x44a527(_0xb79f6a);});},AGIVertices['prototype'][_0x1e747f('0x26')]=function(_0x209788,_0x53bf48){const _0xea73f8=_0x1e747f;this[_0xea73f8('0x65')][_0xea73f8('0x13b')](_0x209788)[_0xea73f8('0x69')](function(_0x286b80){const _0x2ff2ea=_0xea73f8;_0x53bf48(null,_0x286b80?_0x286b80[_0x2ff2ea('0xd3')]:![]);})[_0xea73f8('0x157')](function(_0x56718f){_0x53bf48(_0x56718f);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x37')]=function(_0x558e6a,_0x458b23){const _0x23385f=this;this['rpc']['getSoundById'](_0x558e6a)['then'](function(_0x58194c){const _0x1b7ce5=a1048_0x39ef;_0x458b23(null,_0x58194c?_0x23385f[_0x1b7ce5('0x1c3')](_0x58194c['save_name']):![]);})['catch'](function(_0x491bf1){_0x458b23(_0x491bf1);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xa9')]=function(_0x44c5c0,_0x23fbc3){const _0x15cdd7=_0x1e747f;this['rpc'][_0x15cdd7('0x16b')](_0x44c5c0)['then'](function(_0x187c7c){_0x23fbc3(null,_0x187c7c?_0x187c7c:![]);})[_0x15cdd7('0x157')](function(_0x3680e6){_0x23fbc3(_0x3680e6);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x175')]=function(_0x496da2,_0x5e6ff0,_0x2a3687){const _0x3d7355=_0x1e747f;this['mailRpc']['sendMailMessage'](_0x496da2,_0x5e6ff0)['then'](function(){_0x2a3687(null);})[_0x3d7355('0x157')](function(_0x422e69){_0x2a3687(_0x422e69);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x6b')]=function(_0x8dc605,_0x2ac7df){const _0x5925ea=_0x1e747f;this[_0x5925ea('0x65')][_0x5925ea('0x82')](_0x8dc605)[_0x5925ea('0x69')](function(_0x36d9ca){const _0x23fe06=_0x5925ea;_0x36d9ca?_0x36d9ca[_0x23fe06('0x167')]?_0x2ac7df(null,[_0x36d9ca[_0x23fe06('0x1d0')]]):_0x2ac7df(null,_[_0x23fe06('0x38')](_0x36d9ca[_0x23fe06('0x197')],_0x23fe06('0x1d0'))):_0x2ac7df(null,![]);})[_0x5925ea('0x157')](function(_0x483f46){_0x2ac7df(_0x483f46);});},AGIVertices[_0x1e747f('0xdb')]['getSoundPath']=function(_0x396199){const _0x40ad4d=_0x1e747f;return util['format'](_0x40ad4d('0x130'),FILES_PATH,_0x396199);},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x43')]=function(_0x9b325e,_0x5c6500,_0x37e5c6){const _0x4d162a=_0x1e747f;odbc[_0x4d162a('0x107')](_0x9b325e,function(_0x2e0b84){const _0x250c12=_0x4d162a;_0x2e0b84?(logger[_0x250c12('0x7c')](_0x250c12('0x1ab'),_0x2e0b84),_0x37e5c6(_0x2e0b84)):(logger[_0x250c12('0xd8')](_0x250c12('0xa5')),odbc[_0x250c12('0x1b1')](_0x5c6500,function(_0x2f4c75,_0x4a5417){const _0xcf9457=_0x250c12;_0x2f4c75?(logger['info'](_0xcf9457('0x3b'),_0x5c6500),_0x37e5c6(_0x2f4c75)):(logger['info'](_0xcf9457('0x11'),_0x5c6500),odbc[_0xcf9457('0x30')](function(_0x1bb093){const _0x584287=_0xcf9457;_0x1bb093&&logger[_0x584287('0x7c')]('Error\x20closing\x20connection\x20to\x20odbc\x20%s',_0x1bb093),_0x37e5c6(null,_0x4a5417);}));}));});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xc0')]=function(_0x563260,_0x1c9ff8){const _0x4083a8=_0x1e747f;this[_0x4083a8('0x65')][_0x4083a8('0x59')](_0x563260)[_0x4083a8('0x69')](function(_0x14aeae){_0x1c9ff8(null,_0x14aeae?_0x14aeae:![]);})[_0x4083a8('0x157')](function(_0x27facf){_0x1c9ff8(_0x27facf);});},AGIVertices['prototype']['createSmsMessage']=function(_0x466c46,_0x18f330){const _0x44eb65=_0x1e747f;this[_0x44eb65('0x65')][_0x44eb65('0x14')](_0x466c46)[_0x44eb65('0x69')](function(_0x2459ae){_0x18f330(null,_0x2459ae);})[_0x44eb65('0x157')](function(_0x3aa79c){_0x18f330(_0x3aa79c);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x9b')]=function(_0x3544a4,_0x26769a,_0x86b009){const _0x1397bd=_0x1e747f;this[_0x1397bd('0x65')][_0x1397bd('0x9b')]({'uniqueid':this[_0x1397bd('0xc')][_0x1397bd('0xba')],'node':_0x3544a4[_0x1397bd('0xae')],'application':_0x3544a4['agicommand'],'data':_0x26769a||null,'project_name':this['channel'][_0x1397bd('0x1ba')],'callerid':this['channel'][_0x1397bd('0x1c4')]})[_0x1397bd('0x69')](function(_0x3ff8f4){_0x86b009&&_0x86b009(null,_0x3ff8f4);})[_0x1397bd('0x157')](function(_0x3fed1e){_0x86b009&&_0x86b009(_0x3fed1e);});},AGIVertices[_0x1e747f('0xdb')]['createSquareRecording']=function(_0x2e22fc,_0x4e8cfa,_0x18a8e4,_0x44a022){const _0x2418d2=_0x1e747f;this[_0x2418d2('0x65')][_0x2418d2('0x191')]({'uniqueid':this[_0x2418d2('0xc')][_0x2418d2('0xba')],'callerid':this[_0x2418d2('0xc')]['callerid'],'calleridname':this['channel'][_0x2418d2('0xcd')],'context':this[_0x2418d2('0xc')][_0x2418d2('0xf6')],'extension':this['channel'][_0x2418d2('0xdd')],'priority':this[_0x2418d2('0xc')][_0x2418d2('0xa8')],'accountcode':this[_0x2418d2('0xc')][_0x2418d2('0x8f')],'dnid':this[_0x2418d2('0xc')]['dnid'],'projectName':this[_0x2418d2('0xc')]['arg_1'],'saveName':_0x4e8cfa,'filename':_0x2e22fc[_0x2418d2('0xbb')]||_0x4e8cfa,'savePath':_0x18a8e4})[_0x2418d2('0x69')](function(_0x11dff9){_0x44a022(null,_0x11dff9);})[_0x2418d2('0x157')](function(_0x3ef12f){_0x44a022(_0x3ef12f);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x153')]=function(_0x2b5f07,_0x49418d,_0x5c1d1c,_0x4a0bf7,_0x2efa27){const _0x2b7f24=_0x1e747f;this[_0x2b7f24('0x65')][_0x2b7f24('0x153')]({'uniqueid':this[_0x2b7f24('0xc')]['uniqueid'],'body':_0x2b5f07,'direction':_0x49418d,'providerName':_0x5c1d1c,'providerResponse':_0x4a0bf7})[_0x2b7f24('0x69')](function(_0x86f331){_0x2efa27&&_0x2efa27(null,_0x86f331);})[_0x2b7f24('0x157')](function(_0x458773){_0x2efa27&&_0x2efa27(_0x458773);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xfa')]=function(_0x579885,_0x3ff031){const _0x33f941=_0x1e747f;this[_0x33f941('0x65')]['createCmContact']({'firstName':_['isEmpty'](_0x579885[_0x33f941('0xd3')])||_[_0x33f941('0x199')](_0x579885['name'])?_0x33f941('0x3d')+Math['random']():_0x579885[_0x33f941('0xd3')],'lastName':_[_0x33f941('0x180')](_0x579885['lastName'])||_['isNil'](_0x579885[_0x33f941('0x49')])?null:_0x579885[_0x33f941('0x49')],'phone':_0x579885[_0x33f941('0x166')],'ListId':_0x579885[_0x33f941('0x11e')],'scheduledat':_0x579885['scheduledAt'],'callbackUniqueid':this[_0x33f941('0xc')]['uniqueid'],'tags':_0x33f941('0x60'),'description':_0x33f941('0xe6')+_0x579885[_0x33f941('0x128')]['toString'](),'priority':_0x579885[_0x33f941('0x71')]})['then'](function(_0x5ec6f4){_0x3ff031(null,_0x5ec6f4);})['catch'](function(_0x24da8a){_0x3ff031(_0x24da8a);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x34')]=function(_0x3bc01f,_0x5d174c){const _0x20065a=_0x1e747f;this['rpc'][_0x20065a('0x1ae')](_0x3bc01f)[_0x20065a('0x69')](function(_0x27c71d){const _0x3fcc43=_0x20065a;_0x5d174c(null,_0x27c71d?_0x27c71d[_0x3fcc43('0xd3')]:![]);})[_0x20065a('0x157')](function(_0x1408c5){_0x5d174c(_0x1408c5);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x66')]=function(_0xef3738,_0x3c3f13,_0x195443){const _0x5f22b7=_0x1e747f,_0x9152a8={'role':_0x5f22b7('0x194')};_0x9152a8[_0xef3738]=this['channel']['callerid'],this[_0x5f22b7('0x65')][_0x5f22b7('0x66')](_0x9152a8,_0x3c3f13,this[_0x5f22b7('0xc')][_0x5f22b7('0xba')])[_0x5f22b7('0x69')](function(_0x3c89ab){const _0x5e7dfd=_0x5f22b7;_0x195443(null,_[_0x5e7dfd('0x199')](_0x3c89ab)?![]:!![]);})[_0x5f22b7('0x157')](function(_0x5a0c04){logger['error'](_0x5a0c04),_0x195443(null,![]);});},AGIVertices['prototype'][_0x1e747f('0x5d')]=function(_0x3d8f38,_0x53525a){const _0x159f45=_0x1e747f,_0x5699bc={'role':_0x159f45('0x194')};_0x5699bc[_0x3d8f38]=this[_0x159f45('0xc')]['callerid'],this[_0x159f45('0x65')][_0x159f45('0x5d')](_0x5699bc)[_0x159f45('0x69')](function(_0x11d6a3){const _0x191ea1=_0x159f45;_0x53525a(null,_[_0x191ea1('0x199')](_0x11d6a3)?![]:!![]);})[_0x159f45('0x157')](function(_0x146800){logger['error'](_0x146800),_0x53525a(null,![]);});},AGIVertices['prototype'][_0x1e747f('0xe7')]=function(_0x4bd11b,_0x17bef7){const _0xcab061=_0x1e747f,_0x8f3292={'role':_0xcab061('0x194')};_0x8f3292[_0x4bd11b]=this['channel'][_0xcab061('0x1c4')],this[_0xcab061('0x65')][_0xcab061('0xe7')](_0x8f3292)[_0xcab061('0x69')](function(_0xcdf47d){const _0xc8692b=_0xcab061;_0x17bef7(null,_[_0xc8692b('0x199')](_0xcdf47d)?![]:!![]);})[_0xcab061('0x157')](function(_0x81ebbf){const _0x4f9531=_0xcab061;logger[_0x4f9531('0x7c')](_0x81ebbf),_0x17bef7(null,![]);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x14e')]=function(_0x45d8fa,_0x200a39){const _0x86b8b8=_0x1e747f,_0x33d79a={'role':'agent'};_0x33d79a[_0x45d8fa]=this[_0x86b8b8('0xc')][_0x86b8b8('0x1c4')];const _0x5927f8=_0x45d8fa!='internal'?util['format']('%s/%s@from-sip/n',_0x86b8b8('0x1d3'),this[_0x86b8b8('0xc')][_0x86b8b8('0x1c4')]):undefined;this['rpc'][_0x86b8b8('0x14e')](_0x33d79a,_0x5927f8)[_0x86b8b8('0x69')](function(_0x37f1d9){const _0x265305=_0x86b8b8;_0x200a39(null,_[_0x265305('0x199')](_0x37f1d9)?![]:!![]);})[_0x86b8b8('0x157')](function(_0x30cd87){const _0x1bd4fa=_0x86b8b8;logger[_0x1bd4fa('0x7c')](_0x30cd87),_0x200a39(null,![]);});},AGIVertices['prototype'][_0x1e747f('0x11c')]=function(_0x19424a,_0x3c224c){const _0x564d06=_0x1e747f;sh['exec'](_[_0x564d06('0x103')](_0x19424a),function(_0x70eb6a,_0xfc3391){const _0x332037=_0xfc3391['replace'](/(\r\n|\n|\r)/gm,'');_0x3c224c(null,_0x332037);});},AGIVertices['prototype'][_0x1e747f('0xfc')]=function(_0x1042bb,_0x38c49d){const _0x59cc37=_0x1e747f;scripts[_0x59cc37('0xfc')](_0x1042bb[_0x59cc37('0x11b')],_0x1042bb[_0x59cc37('0x121')]||_0x59cc37('0x1c7'),_0x1042bb[_0x59cc37('0x1c7')],_0x1042bb[_0x59cc37('0x9c')]||'en-US',_0x1042bb[_0x59cc37('0xc7')]||_0x59cc37('0x16'),_0x1042bb['audioEncoding']||'MP3')[_0x59cc37('0x69')](function(_0x2786b2){_0x38c49d(null,_0x2786b2);})['catch'](function(_0x4d13db){_0x38c49d(_0x4d13db);});},AGIVertices[_0x1e747f('0xdb')]['googleTTS']=function(_0x20544e,_0x2ab4d5){const _0x625484=_0x1e747f;scripts[_0x625484('0x8b')](_0x20544e[_0x625484('0x1c7')],_0x20544e[_0x625484('0x2e')]||'en',0x1)['then'](function(_0xbf638b){_0x2ab4d5(null,_0xbf638b);})['catch'](function(_0x2aafdf){_0x2ab4d5(_0x2aafdf);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xea')]=function(_0x36bb3f,_0x4ac8de){const _0x20f8e0=_0x1e747f,_0x2592fb={'uri':_0x36bb3f[_0x20f8e0('0x4f')],'method':_0x36bb3f[_0x20f8e0('0x13')],'json':!![],'resolveWithFullResponse':!![],'timeout':typeof parseInt(_0x36bb3f[_0x20f8e0('0x101')])===_0x20f8e0('0x100')&&parseInt(_0x36bb3f[_0x20f8e0('0x101')])>=0x1?parseInt(_0x36bb3f[_0x20f8e0('0x101')])*0x3e8:0x5*0x3e8};if(_[_0x20f8e0('0x1b6')]([_0x20f8e0('0x94'),_0x20f8e0('0x20')],_0x2592fb[_0x20f8e0('0x13')][_0x20f8e0('0x18a')]()))try{_0x2592fb[_0x20f8e0('0x5a')]=_0x36bb3f['rawBody']?JSON[_0x20f8e0('0x6a')](_0x36bb3f['rawBody']):{};}catch(_0x202a1c){logger[_0x20f8e0('0x7c')](_0x20f8e0('0x189'),_0x202a1c);}try{_0x2592fb['headers']=_0x36bb3f['rawHeaders']?JSON[_0x20f8e0('0x6a')](_0x36bb3f['rawHeaders']):{};}catch(_0x154521){logger['error'](_0x20f8e0('0x8e'),_0x154521);}if(_0x36bb3f['computedVariables'])try{const _0x3be73c=require(_0x36bb3f[_0x20f8e0('0x1a4')])[_0x20f8e0('0x13c')](this,_0x2592fb);_0x2592fb[_0x20f8e0('0x91')]=Mustache[_0x20f8e0('0x42')](_0x36bb3f[_0x20f8e0('0x4f')],_0x3be73c,{},['$$','$$']),_0x2592fb[_0x20f8e0('0x6f')]&&(_0x2592fb[_0x20f8e0('0x6f')]=JSON[_0x20f8e0('0x6a')](Mustache[_0x20f8e0('0x42')](JSON[_0x20f8e0('0x27')](_0x2592fb['headers']),_0x3be73c,{},['$$','$$']))),_0x2592fb[_0x20f8e0('0x5a')]&&(_0x2592fb[_0x20f8e0('0x5a')]=JSON['parse'](Mustache[_0x20f8e0('0x42')](JSON[_0x20f8e0('0x27')](_0x2592fb[_0x20f8e0('0x5a')]),_0x3be73c,{},['$$','$$'])));}catch(_0x16d176){logger[_0x20f8e0('0x7c')](_0x20f8e0('0x61'),_0x16d176);}rp(_0x2592fb)['then'](function(_0x5cb1d1){const _0x2d72e5=_0x20f8e0,_0x5b0b0d={'statusCode':_0x5cb1d1[_0x2d72e5('0xd6')]||0xc8,'statusMessage':_0x5cb1d1[_0x2d72e5('0x92')]||'OK','headers':_0x5cb1d1[_0x2d72e5('0x6f')]||{},'body':_0x5cb1d1[_0x2d72e5('0x5a')]||{}};_0x4ac8de(null,_0x5b0b0d);})[_0x20f8e0('0x157')](function(_0x564a94){const _0x3fd439=_0x20f8e0,_0x439d3f={'statusCode':_0x564a94['statusCode']||0x1f4,'statusMessage':_0x564a94[_0x3fd439('0x1c')]||'500\x20-\x20Internal\x20Server\x20Error','headers':_0x564a94[_0x3fd439('0x10e')][_0x3fd439('0x6f')]||{},'body':_0x564a94[_0x3fd439('0x10e')]['body']||{}};_0x4ac8de(null,_0x439d3f);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x96')]=function(_0x396ff2,_0x53ed02){const _0x5041e1=_0x1e747f;scripts[_0x5041e1('0x96')](this['channel'][_0x5041e1('0xba')],_0x396ff2[_0x5041e1('0xa3')],_0x396ff2[_0x5041e1('0x1c7')],_0x396ff2[_0x5041e1('0x144')]||'en')[_0x5041e1('0x69')](function(_0x43772a){_0x53ed02(null,_0x43772a);})[_0x5041e1('0x157')](function(_0x3751b6){_0x53ed02(_0x3751b6);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x17a')]=function(_0x2e9816,_0x37759a){const _0x16b372=_0x1e747f;scripts[_0x16b372('0x17a')](this[_0x16b372('0xc')]['uniqueid'],_0x2e9816[_0x16b372('0x63')],_0x2e9816[_0x16b372('0x12f')],_0x2e9816[_0x16b372('0xce')],_0x2e9816['text'],_0x2e9816[_0x16b372('0x13e')]||'en')['then'](function(_0x4796c9){_0x37759a(null,_0x4796c9);})['catch'](function(_0x5c273e){_0x37759a(_0x5c273e);});},AGIVertices['prototype'][_0x1e747f('0x14f')]=function(_0x7297d4,_0x2948bc){const _0x356312=_0x1e747f;scripts['sestekNDA'](this[_0x356312('0xc')],_0x7297d4)[_0x356312('0x69')](function(_0x37727f){_0x2948bc(null,_0x37727f);})[_0x356312('0x157')](function(_0x2e172f){_0x2948bc(_0x2e172f);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x87')]=function(_0x1fec75,_0x5cf74e){const _0x4f3465=_0x1e747f;scripts['ispeechTTS'](_0x1fec75[_0x4f3465('0xa3')],_0x1fec75[_0x4f3465('0x1c7')],_0x1fec75['ispeech_tts_language']||_0x4f3465('0xe9'),_0x1fec75[_0x4f3465('0x110')])[_0x4f3465('0x69')](function(_0x17fae2){_0x5cf74e(null,_0x17fae2);})[_0x4f3465('0x157')](function(_0x42327f){_0x5cf74e(_0x42327f);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x1b0')]=function(_0xcf6152,_0x58f703,_0x50a9d3){const _0x426a57=_0x1e747f;scripts[_0x426a57('0x1b0')](_0x58f703,_0xcf6152[_0x426a57('0xa3')],_0xcf6152[_0x426a57('0x4a')]||'en-US',this[_0x426a57('0x10a')](_0xcf6152[_0x426a57('0x1bf')])?_0xcf6152['model']:undefined)[_0x426a57('0x69')](function(_0x322e17){_0x50a9d3(null,_0x322e17);})['catch'](function(_0x1b13c9){_0x50a9d3(_0x1b13c9);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x19f')]=function(_0x413b78,_0x94adce){const _0x6795b9=_0x1e747f;scripts[_0x6795b9('0x19f')](_0x413b78[_0x6795b9('0x12c')],_0x413b78['aws_secret_access_key'],_0x413b78[_0x6795b9('0x1d2')],_0x413b78['aws_polly_voice']||_0x6795b9('0x133'),_0x413b78[_0x6795b9('0x1c7')],_0x413b78['aws_text_type']||'text')[_0x6795b9('0x69')](function(_0x1974a5){_0x94adce(null,_0x1974a5);})[_0x6795b9('0x157')](function(_0x557318){_0x94adce(_0x557318);});},AGIVertices['prototype'][_0x1e747f('0x181')]=function(_0x345432,_0x4d3dce){const _0x326ca2=_0x1e747f;scripts[_0x326ca2('0x181')](this[_0x326ca2('0xc')][_0x326ca2('0xba')],_0x345432[_0x326ca2('0x12c')],_0x345432[_0x326ca2('0x17f')],_0x345432[_0x326ca2('0x185')],_0x345432[_0x326ca2('0x1c7')],_0x345432[_0x326ca2('0x1b3')])[_0x326ca2('0x69')](function(_0x40d92e){_0x4d3dce(null,_0x40d92e);})['catch'](function(_0x2ae9ef){_0x4d3dce(_0x2ae9ef);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x28')]=function(_0x585cc1,_0x5cb4ca,_0x36306c){const _0x2237d4=_0x1e747f;scripts['googleASR'](_0x5cb4ca,_0x585cc1[_0x2237d4('0xa3')],_0x585cc1[_0x2237d4('0x112')]||_0x2237d4('0xe9'))[_0x2237d4('0x69')](function(_0x31c04e){_0x36306c(null,_0x31c04e);})['catch'](function(_0x507e1c){_0x36306c(_0x507e1c);});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x67')]=function(_0x5962f4,_0x463972,_0x40e88a){const _0x256b60=_0x1e747f;scripts[_0x256b60('0x67')](_0x463972,_0x5962f4['appid'],_0x5962f4[_0x256b60('0x2d')],_0x5962f4[_0x256b60('0x91')])[_0x256b60('0x69')](function(_0x2fdd8e){_0x40e88a(null,_0x2fdd8e);})[_0x256b60('0x157')](function(_0x4310b0){_0x40e88a(_0x4310b0);});},AGIVertices[_0x1e747f('0xdb')]['clear']=function(_0x2d3c18){const _0xa0f26c=_0x1e747f,_0x4900ca=_[_0xa0f26c('0x1b6')](verticesWithRetry,_0x2d3c18['agicommand'])?_0x2d3c18:_[_0xa0f26c('0x75')](_0x2d3c18);for(const _0xf25766 in _0x4900ca){typeof _0x4900ca[_0xf25766]!=='undefined'&&(_0x4900ca[_0xf25766]&&_['isString'](_0x4900ca[_0xf25766])&&(_[_0xa0f26c('0x1b6')](recursiveMapAttributes,_0xf25766)?_0x4900ca[_0xf25766]=this[_0xa0f26c('0x3f')](_0x4900ca[_0xf25766]):_0x4900ca[_0xf25766]=this[_0xa0f26c('0xbc')](_0x4900ca[_0xf25766])));}return _0x4900ca;},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x2f')]=function(_0x359da8){const _0x48c7a5=_0x1e747f;for(const _0x4d1730 in _0x359da8){if(typeof _0x359da8[_0x4d1730]!==_0x48c7a5('0x18d')){if(_[_0x48c7a5('0x18')](_0x359da8[_0x4d1730]))this['recursiveNodeIndex'](_0x359da8[_0x4d1730]);else{if(_[_0x48c7a5('0x192')](_0x359da8[_0x4d1730]))for(let _0x32c9eb=0x0;_0x32c9eb<_0x359da8[_0x4d1730]['length'];_0x32c9eb++){this[_0x48c7a5('0x2f')](_0x359da8[_0x4d1730][_0x32c9eb]);}else _['isString'](_0x359da8[_0x4d1730])&&(_0x359da8[_0x4d1730]=this[_0x48c7a5('0xbc')](_0x359da8[_0x4d1730]));}}}},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x120')]=function(_0x3a4d5f,_0x38de23){const _0x4c97d3=_0x1e747f;for(const _0x25945a in _0x3a4d5f){if(typeof _0x3a4d5f[_0x25945a]!==_0x4c97d3('0x18d')){if(_[_0x4c97d3('0x18')](_0x3a4d5f[_0x25945a]))!_[_0x4c97d3('0x180')](_0x3a4d5f[_0x25945a])&&this[_0x4c97d3('0x120')](_0x3a4d5f[_0x25945a],util['format'](_0x4c97d3('0x12e'),_0x38de23,_0x25945a));else{if(_[_0x4c97d3('0x192')](_0x3a4d5f[_0x25945a]))for(let _0x39bd3d=0x0;_0x39bd3d<_0x3a4d5f[_0x25945a]['length'];_0x39bd3d++){this[_0x4c97d3('0x120')](_0x3a4d5f[_0x25945a][_0x39bd3d],util['format'](_0x4c97d3('0x12e'),_0x38de23,_0x25945a+'['+_0x39bd3d+']'));}else!_[_0x4c97d3('0x199')](_0x3a4d5f[_0x25945a])&&this[_0x4c97d3('0xc')]['setVariable'](util['format'](_0x4c97d3('0x12e'),_0x38de23,_0x25945a),_0x3a4d5f[_0x25945a]);}}}},AGIVertices[_0x1e747f('0xdb')]['replaceObjectAllVariables']=function(_0x54803d){const _0xb0bb08=_0x1e747f;try{const _0x2a2d4e=JSON[_0xb0bb08('0x6a')](_0x54803d);return this[_0xb0bb08('0x2f')](_0x2a2d4e),JSON['stringify'](_0x2a2d4e);}catch(_0x590811){return this[_0xb0bb08('0xbc')](_0x54803d);}},AGIVertices[_0x1e747f('0xdb')]['replaceAllVariables']=function(_0x474be0){const _0x4078c9=_0x1e747f,_0x27bad5=_0x474be0['split']('{');for(let _0x27b256=0x1;_0x27b256<_0x27bad5[_0x4078c9('0x52')];_0x27b256+=0x1){const _0x67c57d=_0x27bad5[_0x27b256][_0x4078c9('0x142')]('}');_0x67c57d[_0x4078c9('0x52')]>0x1&&(_0x474be0=_0x474be0[_0x4078c9('0x111')]('{'+_0x67c57d[0x0]+'}',this['channel']['getVariable'](_0x67c57d[0x0])[_0x4078c9('0x174')]||_0x67c57d[0x0]));}if(_0x27bad5['length']===0x1)return _0x474be0[_0x4078c9('0x88')]();return this['replaceAllVariables'](_0x474be0);},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x17')]=function(_0x4ef109,_0x5d080b){const _0x4634d9=_0x1e747f,_0xcddc02=this[_0x4634d9('0xc')][_0x4634d9('0x14b')](_0x4ef109);if(_0xcddc02[_0x4634d9('0xb1')]===-0x1)return _0xcddc02;return logger[_0x4634d9('0xd8')](util['format']('The\x20\x22%s\x22\x20variable\x20value\x20is:\x20%s',_0x5d080b,_0xcddc02[_0x4634d9('0x174')])),this[_0x4634d9('0xc')][_0x4634d9('0x161')](_0x5d080b,_0xcddc02['extra']);},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x10a')]=function(_0x4adff2){return _0x4adff2&&_0x4adff2!=='0'&&_0x4adff2!=='-1'&&_0x4adff2!=='';},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x16a')]=function(_0x3ab2aa){const _0x20b1ed=_0x1e747f;return this['createSquareDetailsReport'][_0x20b1ed('0x13c')](this,_0x3ab2aa,'-'),_0x3ab2aa[_0x20b1ed('0x8')]=_0x3ab2aa[_0x20b1ed('0x16a')],{'code':0xc8,'result':'-'};},AGIVertices[_0x1e747f('0xdb')]['mrcpsynth']=function(_0x1ca7ed){const _0x599b1f=_0x1e747f;logger[_0x599b1f('0xd8')](util[_0x599b1f('0x150')](_0x599b1f('0x170'),_0x1ca7ed[_0x599b1f('0xae')]));if(!this['isConfigured'](_0x1ca7ed[_0x599b1f('0x1c7')]))return this[_0x599b1f('0xc')][_0x599b1f('0x16d')](_0x599b1f('0x9'));let _0x2f79f5='\x22'+_0x1ca7ed['text']+'\x22';this[_0x599b1f('0x10a')](_0x1ca7ed[_0x599b1f('0x10e')])&&(_0x2f79f5+=','+_0x1ca7ed['options']);const _0x5e0be9=this[_0x599b1f('0xc')][_0x599b1f('0x2c')]('MRCPSynth',_0x2f79f5);if(_0x5e0be9[_0x599b1f('0xb1')]===-0x1)return _0x5e0be9;return this['channel'][_0x599b1f('0x16d')](util[_0x599b1f('0x150')](_0x599b1f('0x1c1'),_0x2f79f5));},AGIVertices[_0x1e747f('0xdb')]['mrcprecog']=function(_0x5a4c64){const _0x327826=_0x1e747f;logger['info'](util[_0x327826('0x150')](_0x327826('0x196'),_0x5a4c64[_0x327826('0xae')]));if(!this[_0x327826('0x10a')](_0x5a4c64[_0x327826('0xbe')]))return this[_0x327826('0xc')][_0x327826('0x16d')](_0x327826('0x4c'));let _0x32d8f3=_0x5a4c64[_0x327826('0xbe')];this[_0x327826('0x10a')](_0x5a4c64['options'])&&(_0x32d8f3+=','+_0x5a4c64['options']);const _0x3e7a16=this[_0x327826('0xc')]['exec'](_0x327826('0x1ad'),_0x32d8f3);if(_0x3e7a16[_0x327826('0xb1')]===-0x1)return _0x3e7a16;const _0x48de9c=this[_0x327826('0x17')]('RECOG_CONFIDENCE()',_0x327826('0x139'));if(_0x48de9c[_0x327826('0xb1')]===-0x1)return _0x48de9c;const _0x2ff168=this[_0x327826('0x17')](_0x327826('0xed'),_0x327826('0x33'));if(_0x2ff168[_0x327826('0xb1')]===-0x1)return _0x2ff168;const _0x56f329=this['getAndSetVariable']('RECOG_INSTANCE()',_0x327826('0x7a'));if(_0x56f329[_0x327826('0xb1')]===-0x1)return _0x56f329;return this[_0x327826('0xc')]['noop'](util['format'](_0x327826('0x147'),_0x32d8f3));},AGIVertices['prototype']['agi']=function(_0x18fd40){const _0x8ba718=_0x1e747f;return logger['info'](util[_0x8ba718('0x150')](_0x8ba718('0x24'),_0x18fd40[_0x8ba718('0xae')])),this[_0x8ba718('0xc')]['agi']([_0x18fd40['command'],_0x18fd40[_0x8ba718('0x12d')]]);},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x154')]=function(_0x5e8802){const _0x271bba=_0x1e747f;logger[_0x271bba('0xd8')](util['format'](_0x271bba('0x118'),_0x5e8802[_0x271bba('0xae')]));if(this[_0x271bba('0x10a')](_0x5e8802[_0x271bba('0x101')])){logger[_0x271bba('0xd8')](util[_0x271bba('0x150')](_0x271bba('0xf2'),_0x5e8802[_0x271bba('0x101')]));const _0x324cf5=this[_0x271bba('0xc')]['wait'](_0x5e8802[_0x271bba('0x101')]);if(_0x324cf5[_0x271bba('0xb1')]===-0x1)return _0x324cf5;}return this[_0x271bba('0xc')][_0x271bba('0x154')]();},AGIVertices[_0x1e747f('0xdb')]['callback']=function(_0x1ebb41){const _0x5dca98=_0x1e747f;logger['info'](util[_0x5dca98('0x150')](_0x5dca98('0x193'),_0x1ebb41[_0x5dca98('0xae')]));if(!this[_0x5dca98('0x10a')](_0x1ebb41['list_id']))return this[_0x5dca98('0xc')][_0x5dca98('0x7c')](_0x1ebb41,'no\x20list\x20selected');return _0x1ebb41[_0x5dca98('0x128')]=moment(),this['isConfigured'](_0x1ebb41[_0x5dca98('0x22')])&&(_0x1ebb41[_0x5dca98('0x128')]=moment()['add'](_0x1ebb41[_0x5dca98('0x22')],_0x5dca98('0x36'))),!this[_0x5dca98('0x10a')](_0x1ebb41['callback_priority'])&&(_0x1ebb41[_0x5dca98('0x71')]=0x2),this[_0x5dca98('0xfa')][_0x5dca98('0x13c')](this,_0x1ebb41),this[_0x5dca98('0xc')][_0x5dca98('0x16d')](util['format'](_0x5dca98('0x136'),_0x1ebb41[_0x5dca98('0x166')],_0x1ebb41[_0x5dca98('0x11e')],_0x1ebb41[_0x5dca98('0x128')]));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x74')]=function(_0x20db05){const _0x319fd1=_0x1e747f;logger[_0x319fd1('0xd8')](util[_0x319fd1('0x150')](_0x319fd1('0x163'),_0x20db05[_0x319fd1('0xae')]));const _0x50c71a=this[_0x319fd1('0xc')]['exec'](_0x20db05[_0x319fd1('0x41')],_0x20db05[_0x319fd1('0x10e')]);if(_0x50c71a[_0x319fd1('0xb1')]===-0x1)return _0x50c71a;return this[_0x319fd1('0xc')][_0x319fd1('0x16d')](util[_0x319fd1('0x150')](_0x319fd1('0xf8'),_0x20db05[_0x319fd1('0x41')],_0x20db05['options']));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x1a1')]=function(_0x55a681){const _0x31d782=_0x1e747f;logger[_0x31d782('0xd8')](util[_0x31d782('0x150')](_0x31d782('0x125'),_0x55a681[_0x31d782('0xae')]));if(!this[_0x31d782('0x10a')](_0x55a681['text']))return this['channel']['noop']('no\x20text\x20configured');let _0x245f8b='\x22'+_0x55a681['text']+'\x22';this['isConfigured'](_0x55a681[_0x31d782('0x10e')])&&(_0x245f8b+=','+_0x55a681[_0x31d782('0x10e')]);const _0x2c03d8=this[_0x31d782('0xc')][_0x31d782('0x2c')](_0x31d782('0x7e'),_0x245f8b);if(_0x2c03d8[_0x31d782('0xb1')]===-0x1)return _0x2c03d8;return this[_0x31d782('0xc')][_0x31d782('0x16d')](util[_0x31d782('0x150')](_0x31d782('0x1c1'),_0x245f8b));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x177')]=function(_0x18bd9d){const _0x4b1a8a=_0x1e747f;logger[_0x4b1a8a('0xd8')](util[_0x4b1a8a('0x150')](_0x4b1a8a('0x109'),_0x18bd9d[_0x4b1a8a('0xae')]));if(!this[_0x4b1a8a('0x10a')](_0x18bd9d[_0x4b1a8a('0x1c7')]))return this[_0x4b1a8a('0xc')][_0x4b1a8a('0x16d')](_0x4b1a8a('0x9'));let _0x4e6478='\x22'+_0x18bd9d['text']+'\x22';this[_0x4b1a8a('0x10a')](_0x18bd9d[_0x4b1a8a('0x10e')])&&(_0x4e6478+=','+_0x18bd9d[_0x4b1a8a('0x10e')]);const _0x4c371c=this[_0x4b1a8a('0xc')]['exec']('MRCPSynth',_0x4e6478);if(_0x4c371c[_0x4b1a8a('0xb1')]===-0x1)return _0x4c371c;return this[_0x4b1a8a('0xc')][_0x4b1a8a('0x16d')](util[_0x4b1a8a('0x150')]('Executed\x20command\x20MRCPSynth\x20%s',_0x4e6478));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x1aa')]=function(_0x3a4a97){const _0x30dfa8=_0x1e747f;logger[_0x30dfa8('0xd8')](util[_0x30dfa8('0x150')](_0x30dfa8('0x9e'),_0x3a4a97[_0x30dfa8('0xae')]));if(!this[_0x30dfa8('0x10a')](_0x3a4a97[_0x30dfa8('0xbe')]))return this['channel'][_0x30dfa8('0x16d')]('no\x20grammar\x20configured');let _0x16f919=_0x3a4a97[_0x30dfa8('0xbe')];this[_0x30dfa8('0x10a')](_0x3a4a97[_0x30dfa8('0x10e')])&&(_0x16f919+=','+_0x3a4a97[_0x30dfa8('0x10e')]);const _0x1a1f1e=this[_0x30dfa8('0xc')]['exec'](_0x30dfa8('0x1ad'),_0x16f919);if(_0x1a1f1e['result']===-0x1)return _0x1a1f1e;const _0x12a4c9=this[_0x30dfa8('0x17')](_0x30dfa8('0x80'),_0x30dfa8('0xd1'));if(_0x12a4c9[_0x30dfa8('0xb1')]===-0x1)return _0x12a4c9;const _0x8d1337=this[_0x30dfa8('0x17')]('RECOG_INPUT()','LUMENVOX_ASR_TRANSCRIPT');if(_0x8d1337[_0x30dfa8('0xb1')]===-0x1)return _0x8d1337;const _0x5a8642=this[_0x30dfa8('0x17')](_0x30dfa8('0x1a'),_0x30dfa8('0x99'));if(_0x5a8642[_0x30dfa8('0xb1')]===-0x1)return _0x5a8642;return this[_0x30dfa8('0xc')][_0x30dfa8('0x16d')](util['format'](_0x30dfa8('0x147'),_0x16f919));},AGIVertices[_0x1e747f('0xdb')]['sestekasr']=function(_0x3133f1){const _0x254832=_0x1e747f;logger['info'](util[_0x254832('0x150')](_0x254832('0x18e'),_0x3133f1['label']));if(!this[_0x254832('0x10a')](_0x3133f1[_0x254832('0xbe')]))return this[_0x254832('0xc')][_0x254832('0x16d')](_0x254832('0x4c'));let _0x2f13de=_0x3133f1[_0x254832('0xbe')];this[_0x254832('0x10a')](_0x3133f1['options'])&&(_0x2f13de+=','+_0x3133f1[_0x254832('0x10e')]);const _0x1ae4d0=this['channel'][_0x254832('0x2c')](_0x254832('0x1ad'),_0x2f13de);if(_0x1ae4d0[_0x254832('0xb1')]===-0x1)return _0x1ae4d0;const _0x1960cf=this[_0x254832('0x17')](_0x254832('0x80'),_0x254832('0x45'));if(_0x1960cf[_0x254832('0xb1')]===-0x1)return _0x1960cf;const _0x185c2c=this['getAndSetVariable'](_0x254832('0xed'),_0x254832('0x122'));if(_0x185c2c[_0x254832('0xb1')]===-0x1)return _0x185c2c;const _0x283d3f=this[_0x254832('0x17')](_0x254832('0x1a'),_0x254832('0x158'));if(_0x283d3f[_0x254832('0xb1')]===-0x1)return _0x283d3f;return this[_0x254832('0xc')][_0x254832('0x16d')](util[_0x254832('0x150')](_0x254832('0x147'),_0x2f13de));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xcf')]=function(_0x4031d1){const _0x15cf1c=_0x1e747f;logger[_0x15cf1c('0xd8')](util['format'](_0x15cf1c('0x97'),_0x4031d1[_0x15cf1c('0xae')]));if(!this['isConfigured'](_0x4031d1['odbc_id']))return this[_0x15cf1c('0xc')][_0x15cf1c('0x7c')](_0x4031d1,_0x15cf1c('0x1bd'));const _0x58901b=this[_0x15cf1c('0x146')][_0x15cf1c('0x13c')](this,_0x4031d1[_0x15cf1c('0x145')]);if(!_0x58901b)return this['channel']['error'](_0x4031d1,_0x15cf1c('0x10d'));if(!this['isConfigured'](_0x4031d1['query']))return this[_0x15cf1c('0xc')]['error'](_0x4031d1,_0x15cf1c('0x1b5'));const _0x348033=_0x4031d1[_0x15cf1c('0x1b1')][_0x15cf1c('0x124')](/(\r\n|\n|\r)/gm,'\x20');this['channel']['noop'](util[_0x15cf1c('0x150')](_0x15cf1c('0x132'),_0x348033));const _0xb1723b=this['getQueryOdbc'][_0x15cf1c('0x13c')](this,_0x58901b,_0x348033);this['createSquareDetailsReport'][_0x15cf1c('0x13c')](this,_0x4031d1,_0x348033);if(!this[_0x15cf1c('0x10a')](_0x4031d1['variable_id']))return this['channel']['noop'](_0x15cf1c('0x6e'));const _0x556c7d=this[_0x15cf1c('0x14b')][_0x15cf1c('0x13c')](this,_0x4031d1[_0x15cf1c('0xa4')]);if(!_0x556c7d)return this['channel']['error'](_0x4031d1,'no\x20variable\x20found');const _0x1bca20=this;return _0xb1723b['forEach'](function(_0x40e1f1,_0x57689f){const _0x4792f7=_0x15cf1c;Object['keys'](_0x40e1f1)[_0x4792f7('0x2a')](function(_0x5c37a7){const _0x2b7357=_0x4792f7;_0x1bca20[_0x2b7357('0xc')][_0x2b7357('0x161')](util['format'](_0x2b7357('0x1a7'),_0x556c7d,_0x57689f,_0x5c37a7),_0x40e1f1[_0x5c37a7]);});}),this[_0x15cf1c('0xc')][_0x15cf1c('0x161')](util[_0x15cf1c('0x150')](_0x15cf1c('0xc9'),_0x556c7d),_0xb1723b[_0x15cf1c('0x52')]),this[_0x15cf1c('0xc')]['noop'](util['format'](_0x15cf1c('0x160'),_0x556c7d));},AGIVertices[_0x1e747f('0xdb')]['dial']=function(_0x2ad9e3){const _0x42bbb8=_0x1e747f;logger[_0x42bbb8('0x15b')](util[_0x42bbb8('0x150')](_0x42bbb8('0x1bb'),_0x2ad9e3['label']));if(!this[_0x42bbb8('0x10a')](_0x2ad9e3[_0x42bbb8('0x46')]))return this['channel'][_0x42bbb8('0x7c')](_0x2ad9e3,_0x42bbb8('0x10'));const _0x3ef57b=this[_0x42bbb8('0xda')]['sync'](this,_0x2ad9e3[_0x42bbb8('0x46')]);if(!_0x3ef57b)return this[_0x42bbb8('0xc')][_0x42bbb8('0x7c')](_0x2ad9e3,_0x42bbb8('0x98'));const _0x2db596=this[_0x42bbb8('0xc')][_0x42bbb8('0x2c')](_0x42bbb8('0x29'),[util[_0x42bbb8('0x150')]('SIP/%s',_0x3ef57b),_0x2ad9e3[_0x42bbb8('0x101')],_0x2ad9e3[_0x42bbb8('0x31')],_0x2ad9e3[_0x42bbb8('0x4f')]]);if(_0x2db596[_0x42bbb8('0xb1')]===-0x1)return _0x2db596;return this[_0x42bbb8('0xc')]['noop'](util[_0x42bbb8('0x150')](_0x42bbb8('0x3c'),_0x42bbb8('0x29')));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xc6')]=function(_0x3fca22){const _0x5d3dde=_0x1e747f;logger[_0x5d3dde('0xd8')](util[_0x5d3dde('0x150')](_0x5d3dde('0x106'),_0x3fca22[_0x5d3dde('0xae')]));if(!this[_0x5d3dde('0x10a')](_0x3fca22[_0x5d3dde('0xa3')]))return this[_0x5d3dde('0xc')][_0x5d3dde('0x16d')](_0x5d3dde('0x1cc'));if(!this['isConfigured'](_0x3fca22[_0x5d3dde('0x1c7')]))return this[_0x5d3dde('0xc')][_0x5d3dde('0x16d')](_0x5d3dde('0x9'));this['channel'][_0x5d3dde('0x4e')]=!![],this[_0x5d3dde('0x9b')](_0x3fca22),this[_0x5d3dde('0x153')](_0x3fca22[_0x5d3dde('0x1c7')],'in','',''),this['channel'][_0x5d3dde('0x16d')](util[_0x5d3dde('0x150')](_0x5d3dde('0x19'),_0x3fca22['text']));const _0x3fcd07=this[_0x5d3dde('0x96')][_0x5d3dde('0x13c')](this,_0x3fca22);if(_0x3fcd07){for(const _0x2aac43 in _0x3fcd07){typeof _0x3fcd07[_0x2aac43]!==_0x5d3dde('0x18d')&&this[_0x5d3dde('0xc')][_0x5d3dde('0x161')](util[_0x5d3dde('0x150')](_0x5d3dde('0x15c'),_0x2aac43[_0x5d3dde('0x18a')]()),_0x3fcd07[_0x2aac43]);}return this[_0x5d3dde('0x153')](_0x3fcd07[_0x5d3dde('0x6')],'out','dialogflow',''),this[_0x5d3dde('0xc')][_0x5d3dde('0x16d')](util[_0x5d3dde('0x150')](_0x5d3dde('0x17c'),_0x3fcd07[_0x5d3dde('0x6')]));}return this[_0x5d3dde('0xc')]['error'](_0x3fca22,_0x5d3dde('0x3a'));},AGIVertices['prototype']['dialogflowV2']=function(_0x487fd6){const _0x39f7b6=_0x1e747f;logger['info'](util[_0x39f7b6('0x150')]('Enter\x20in\x20DIALOGFLOW\x20V2\x20(%s)\x20block',_0x487fd6['label']));if(!this[_0x39f7b6('0x10a')](_0x487fd6['dialogflowV2_project_id']))return this['channel'][_0x39f7b6('0x16d')](_0x39f7b6('0x5e'));if(!this[_0x39f7b6('0x10a')](_0x487fd6['client_email']))return this[_0x39f7b6('0xc')]['noop'](_0x39f7b6('0x12b'));if(!this[_0x39f7b6('0x10a')](_0x487fd6[_0x39f7b6('0xce')]))return this[_0x39f7b6('0xc')][_0x39f7b6('0x16d')](_0x39f7b6('0x8d'));if(!this['isConfigured'](_0x487fd6[_0x39f7b6('0x13e')]))return this[_0x39f7b6('0xc')][_0x39f7b6('0x16d')](_0x39f7b6('0xa2'));if(!this[_0x39f7b6('0x10a')](_0x487fd6[_0x39f7b6('0x1c7')]))return this[_0x39f7b6('0xc')]['noop'](_0x39f7b6('0x9'));this[_0x39f7b6('0xc')][_0x39f7b6('0x4e')]=!![],this[_0x39f7b6('0x9b')](_0x487fd6),this[_0x39f7b6('0x153')](_0x487fd6[_0x39f7b6('0x1c7')],'in','',''),this[_0x39f7b6('0xc')]['noop'](util['format'](_0x39f7b6('0x79'),_0x487fd6[_0x39f7b6('0x1c7')]));const _0x2ee420=this[_0x39f7b6('0x17a')][_0x39f7b6('0x13c')](this,_0x487fd6);if(_0x2ee420){for(const _0x3136a9 in _0x2ee420){typeof _0x2ee420[_0x3136a9]!==_0x39f7b6('0x18d')&&(_0x3136a9!==_0x39f7b6('0x15d')&&this[_0x39f7b6('0xc')][_0x39f7b6('0x161')](util[_0x39f7b6('0x150')]('DIALOGFLOW_%s',_0x3136a9[_0x39f7b6('0x18a')]()),_0x2ee420[_0x3136a9]));}return this[_0x39f7b6('0x153')](_0x2ee420[_0x39f7b6('0x6')],_0x39f7b6('0x11d'),_0x39f7b6('0xf5'),_0x2ee420[_0x39f7b6('0x15d')]),this[_0x39f7b6('0xc')]['noop'](util[_0x39f7b6('0x150')]('DialogflowV2\x20Result\x20%s',_0x2ee420['speech']));}return this['channel'][_0x39f7b6('0x7c')](_0x487fd6,_0x39f7b6('0x114'));},AGIVertices['prototype'][_0x1e747f('0x141')]=function(_0x367074){const _0x217d60=_0x1e747f;logger[_0x217d60('0xd8')](util[_0x217d60('0x150')](_0x217d60('0x51'),_0x367074['label']));if(!this[_0x217d60('0x10a')](_0x367074[_0x217d60('0x19d')]))return this['channel'][_0x217d60('0x16d')](_0x217d60('0x5c'));if(!this[_0x217d60('0x10a')](_0x367074[_0x217d60('0x17b')]))return this['channel'][_0x217d60('0x16d')](_0x217d60('0xdc'));if(!this[_0x217d60('0x10a')](_0x367074[_0x217d60('0x148')]))return this[_0x217d60('0xc')][_0x217d60('0x16d')](_0x217d60('0x1a2'));if(!this[_0x217d60('0x10a')](_0x367074['ndassistant_url']))return this['channel'][_0x217d60('0x16d')](_0x217d60('0x9'));this['channel'][_0x217d60('0x4e')]=!![],this[_0x217d60('0x9b')](_0x367074),this[_0x217d60('0x153')](_0x367074['text'],'in','',''),this[_0x217d60('0xc')][_0x217d60('0x16d')](util[_0x217d60('0x150')]('Trying\x20SestekNDA:\x20%s',_0x367074[_0x217d60('0x1c7')]));const _0x23bd8a=this['sestekNDA'][_0x217d60('0x13c')](this,_0x367074);if(_0x23bd8a){for(const _0x98b076 in _0x23bd8a){typeof _0x23bd8a[_0x98b076]!=='undefined'&&this[_0x217d60('0xc')][_0x217d60('0x161')](util['format'](_0x217d60('0x135'),_0x98b076['toUpperCase']()),_0x23bd8a[_0x98b076]);}this[_0x217d60('0x153')](_0x23bd8a[_0x217d60('0x6')],_0x217d60('0x11d'),_0x217d60('0x141'),'');if(_0x23bd8a['audiofile']){this[_0x217d60('0xc')][_0x217d60('0x16d')](util['format'](_0x217d60('0x9d'),_0x23bd8a[_0x217d60('0x1')]));const _0x10e84b=this['channel'][_0x217d60('0xa0')](_0x23bd8a[_0x217d60('0x1')]);try{fs[_0x217d60('0xb5')](_0x23bd8a[_0x217d60('0x1')]+'.wav');}catch(_0xa80001){logger[_0x217d60('0x7c')](_0xa80001);}return _0x10e84b;}else return this['channel'][_0x217d60('0x16d')](util[_0x217d60('0x150')](_0x217d60('0x57'),_0x23bd8a['speech']));}return this[_0x217d60('0xc')][_0x217d60('0x7c')](_0x367074,_0x217d60('0x1b2'));},AGIVertices['prototype'][_0x1e747f('0x10b')]=function(_0x29bf68){const _0x4ed916=_0x1e747f;return logger[_0x4ed916('0xd8')](util['format']('Enter\x20in\x20END\x20(%s)\x20block',_0x29bf68[_0x4ed916('0xae')])),this[_0x4ed916('0xc')][_0x4ed916('0x16d')](_0x4ed916('0x10b'));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x14d')]=function(_0x235a69){const _0x10de1b=_0x1e747f;logger[_0x10de1b('0xd8')](util['format'](_0x10de1b('0x1d'),_0x235a69[_0x10de1b('0xae')]));let _0xb60539='';if(_0x235a69[_0x10de1b('0xfd')]){if(!this[_0x10de1b('0x10a')](_0x235a69[_0x10de1b('0xfd')]))return this['channel'][_0x10de1b('0x7c')](_0x235a69,_0x10de1b('0xd5'));else{const _0x3d7d0c=parseInt(_0x235a69[_0x10de1b('0xfd')],0xa);if(isNaN(_0x3d7d0c))_0xb60539=_0x235a69[_0x10de1b('0xfd')];else{_0xb60539=this[_0x10de1b('0x26')][_0x10de1b('0x13c')](this,_0x235a69[_0x10de1b('0xfd')]);if(!_0xb60539)return this[_0x10de1b('0xc')][_0x10de1b('0x7c')](_0x235a69,_0x10de1b('0x105'));}}}else{if(_0x235a69['trunk_name'])_0xb60539=_0x235a69[_0x10de1b('0xd9')];else return this[_0x10de1b('0xc')][_0x10de1b('0x7c')](_0x235a69,'no\x20trunk\x20selected');}const _0x5a8242=this[_0x10de1b('0xc')][_0x10de1b('0x2c')](_0x10de1b('0x29'),[util['format']('SIP/%s/%s',_0xb60539,_0x235a69[_0x10de1b('0x166')]),_0x235a69[_0x10de1b('0x101')],_0x235a69[_0x10de1b('0x31')],_0x235a69[_0x10de1b('0x4f')]]);if(_0x5a8242['result']===-0x1)return _0x5a8242;return this['channel'][_0x10de1b('0x16d')](util[_0x10de1b('0x150')](_0x10de1b('0x3c'),_0x10de1b('0x29')));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xc5')]=function(_0x7d1dc7){const _0x10f6dc=_0x1e747f;return logger[_0x10f6dc('0xd8')](util[_0x10f6dc('0x150')](_0x10f6dc('0x17d'),_0x7d1dc7[_0x10f6dc('0xae')])),this[_0x10f6dc('0xc')][_0x10f6dc('0x16d')](_0x10f6dc('0xc5'));},AGIVertices[_0x1e747f('0xdb')]['getdigits']=function(_0x1e690a){const _0x3e0423=_0x1e747f;logger['info'](util[_0x3e0423('0x150')](_0x3e0423('0xe0'),_0x1e690a[_0x3e0423('0xae')]));if(_0x1e690a['retry']===0x0)return this[_0x3e0423('0x16a')](_0x1e690a);_0x1e690a[_0x3e0423('0x8')]-=0x1;if(!this[_0x3e0423('0x10a')](_0x1e690a[_0x3e0423('0xc4')]))return this['channel'][_0x3e0423('0x7c')](_0x1e690a,_0x3e0423('0xe3'));const _0x5b4e50=this[_0x3e0423('0x37')]['sync'](this,_0x1e690a[_0x3e0423('0xc4')]);if(!_0x5b4e50)return this[_0x3e0423('0xc')]['error'](_0x1e690a,_0x3e0423('0x18f'));if(!this[_0x3e0423('0x10a')](_0x1e690a['variable_id']))return this[_0x3e0423('0xc')][_0x3e0423('0x7c')](_0x3e0423('0x6e'));const _0x5b0b82=this[_0x3e0423('0xc')][_0x3e0423('0x183')](_0x5b4e50,_0x1e690a['response'],_0x1e690a['maxdigit']),_0x4ffcc2=_0x5b0b82[_0x3e0423('0xb1')]?_0x5b0b82[_0x3e0423('0xb1')][_0x3e0423('0x88')]():'';logger[_0x3e0423('0xd8')](_0x3e0423('0x14a'),JSON['stringify'](_0x5b0b82));if(_0x5b0b82['result']===-0x1)return this['createSquareDetailsReport'][_0x3e0423('0x13c')](this,_0x1e690a,_0x4ffcc2),_0x5b0b82;else _0x5b0b82[_0x3e0423('0x174')]==='timeout'?_0x5b0b82[_0x3e0423('0xb1')]=_0x4ffcc2['length']>=parseInt(_0x1e690a[_0x3e0423('0xa')])?'x':'i':_0x5b0b82[_0x3e0423('0xb1')]=_0x4ffcc2[_0x3e0423('0x52')]>=parseInt(_0x1e690a[_0x3e0423('0xa')])&&_0x4ffcc2[_0x3e0423('0x52')]<=parseInt(_0x1e690a[_0x3e0423('0x5b')])?'x':'i';const _0x127010=this[_0x3e0423('0x14b')][_0x3e0423('0x13c')](this,_0x1e690a['variable_id']);if(!_0x127010)return this['channel']['error'](_0x1e690a,'no\x20variable\x20found');this[_0x3e0423('0xc')][_0x3e0423('0x161')](_0x127010,_0x4ffcc2);if(this[_0x3e0423('0x10a')](_0x1e690a[_0x3e0423('0x1c9')])){const _0x2f1cb8=parseInt(_0x1e690a['hiddendigitsnum'],0xa),_0x4c1172=rs[_0x3e0423('0xf9')]({'charset':'*','length':_0x2f1cb8}),_0xca532f=_0x4ffcc2['length'];_0xca532f>0x0?_0xca532f>_0x2f1cb8?this[_0x3e0423('0x9b')]['sync'](this,_0x1e690a,_0x1e690a['hiddendigitspos']===_0x3e0423('0xcb')?_0x4c1172+_0x4ffcc2[_0x3e0423('0x1af')](_0x2f1cb8):_0x4ffcc2[_0x3e0423('0x1af')](0x0,_0xca532f-_0x2f1cb8)+_0x4c1172):this[_0x3e0423('0x9b')]['sync'](this,_0x1e690a,rs['generate']({'charset':'*','length':_0xca532f})):this[_0x3e0423('0x9b')][_0x3e0423('0x13c')](this,_0x1e690a,'');}else this[_0x3e0423('0x9b')]['sync'](this,_0x1e690a,_0x4ffcc2);return _0x5b0b82;},AGIVertices[_0x1e747f('0xdb')]['getsecretdigits']=function(_0x30f9bb){const _0x216f1=_0x1e747f;return logger[_0x216f1('0xd8')](util[_0x216f1('0x150')](_0x216f1('0x40'),_0x30f9bb['label'])),this[_0x216f1('0xff')](_0x30f9bb);},AGIVertices[_0x1e747f('0xdb')]['goal']=function(_0x6c01ca){const _0x588831=_0x1e747f;return logger[_0x588831('0xd8')](util[_0x588831('0x150')](_0x588831('0x13f'),_0x6c01ca[_0x588831('0xae')])),this[_0x588831('0x9b')][_0x588831('0x13c')](this,_0x6c01ca,_0x6c01ca[_0x588831('0x19a')]),this['channel']['noop'](util[_0x588831('0x150')](_0x588831('0x156'),_0x6c01ca[_0x588831('0x19a')]));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xb3')]=function(_0x2ef6b8){const _0x6f6b39=_0x1e747f;logger[_0x6f6b39('0xd8')](util['format'](_0x6f6b39('0xc2'),_0x2ef6b8[_0x6f6b39('0xae')]));if(!this[_0x6f6b39('0x10a')](_0x2ef6b8[_0x6f6b39('0x12c')])||!this['isConfigured'](_0x2ef6b8[_0x6f6b39('0x17f')]))return this[_0x6f6b39('0xc')]['noop'](_0x6f6b39('0x8a'));if(!this[_0x6f6b39('0x10a')](_0x2ef6b8[_0x6f6b39('0x1c7')]))return this['channel'][_0x6f6b39('0x16d')](_0x6f6b39('0x9'));this[_0x6f6b39('0xc')][_0x6f6b39('0x16d')](util['format'](_0x6f6b39('0x64'),_0x2ef6b8[_0x6f6b39('0x1c7')]));const _0x5ef0b8=this[_0x6f6b39('0x19f')][_0x6f6b39('0x13c')](this,_0x2ef6b8);if(_0x5ef0b8){this[_0x6f6b39('0xc')][_0x6f6b39('0x16d')](util[_0x6f6b39('0x150')]('aws\x20Polly\x20%s\x20file\x20created',_0x5ef0b8));const _0x18e343=this[_0x6f6b39('0xc')]['streamFile'](_0x5ef0b8);try{fs[_0x6f6b39('0xb5')](_0x5ef0b8+'.wav');}catch(_0x1199e9){logger['error'](_0x1199e9);}return _0x18e343;}return this[_0x6f6b39('0xc')]['error'](_0x2ef6b8,'aws\x20Polly\x20is\x20unreachable');},AGIVertices[_0x1e747f('0xdb')]['awslex']=function(_0x1e0938){const _0x534553=_0x1e747f;logger['info'](util[_0x534553('0x150')](_0x534553('0x134'),_0x1e0938[_0x534553('0xae')]));if(!this[_0x534553('0x10a')](_0x1e0938[_0x534553('0x12c')])||!this[_0x534553('0x10a')](_0x1e0938[_0x534553('0x17f')]))return this['channel'][_0x534553('0x16d')](_0x534553('0x8a'));if(!this['isConfigured'](_0x1e0938[_0x534553('0x1b3')]))return this[_0x534553('0xc')][_0x534553('0x16d')]('no\x20bot\x20name\x20configured');if(!this[_0x534553('0x10a')](_0x1e0938[_0x534553('0x1c7')]))return this['channel'][_0x534553('0x16d')](_0x534553('0x9'));this['channel'][_0x534553('0x4e')]=!![],this[_0x534553('0x9b')](_0x1e0938),this[_0x534553('0x153')](_0x1e0938[_0x534553('0x1c7')],'in','',''),this[_0x534553('0xc')][_0x534553('0x16d')](util[_0x534553('0x150')]('Trying\x20Amazon\x20Lex:\x20%s',_0x1e0938[_0x534553('0x1c7')]));const _0x4d90df=this[_0x534553('0x181')][_0x534553('0x13c')](this,_0x1e0938);if(_0x4d90df){for(const _0x47bb61 in _0x4d90df){typeof _0x4d90df[_0x47bb61]!==_0x534553('0x18d')&&_[_0x534553('0xb4')](_0x4d90df[_0x47bb61])&&this[_0x534553('0xc')]['setVariable'](util[_0x534553('0x150')](_0x534553('0xb6'),_0x47bb61[_0x534553('0x18a')]()),_0x4d90df[_0x47bb61]);}return _['isNil'](_0x4d90df['message'])?this[_0x534553('0xc')][_0x534553('0x16d')](_0x534553('0x93')):(this[_0x534553('0x153')](_0x4d90df[_0x534553('0x1c')],'out',_0x534553('0xd4'),''),this[_0x534553('0xc')][_0x534553('0x16d')](util[_0x534553('0x150')](_0x534553('0xca'),_0x4d90df[_0x534553('0x1c')])));}return this[_0x534553('0xc')]['error'](_0x1e0938,_0x534553('0xf7'));},AGIVertices['prototype']['googleasr']=function(_0x55c02b){const _0x3204f9=_0x1e747f;logger[_0x3204f9('0xd8')](util[_0x3204f9('0x150')](_0x3204f9('0x15e'),_0x55c02b[_0x3204f9('0xae')],_0x55c02b[_0x3204f9('0x101')]));if(!this[_0x3204f9('0x10a')](_0x55c02b['key']))return this[_0x3204f9('0xc')][_0x3204f9('0x16d')]('no\x20key\x20configured');const _0x214961=_0x3204f9('0x10f'),_0x117001=util[_0x3204f9('0x150')](_0x3204f9('0x1a3'),FILES_PATH,rs[_0x3204f9('0xf9')](0x4)),_0x2e79c8=util[_0x3204f9('0x150')](_0x3204f9('0x12e'),_0x117001,_0x214961);let _0x2160e=!![];_0x55c02b[_0x3204f9('0x104')]===_0x3204f9('0xb2')&&(_0x2160e=![]);const _0x206ab8=this[_0x3204f9('0xc')][_0x3204f9('0x55')](_0x117001,_0x214961,_0x55c02b['intKey'],_0x55c02b[_0x3204f9('0x101')],undefined,_0x2160e);if(_0x206ab8[_0x3204f9('0xb1')]!==-0x1){this['channel'][_0x3204f9('0x16d')](util['format'](_0x3204f9('0x19e'),_0x2e79c8));const _0x17761c=this[_0x3204f9('0x28')][_0x3204f9('0x13c')](this,_0x55c02b,_0x2e79c8);if(_0x17761c){for(const _0x4eb590 in _0x17761c){typeof _0x17761c[_0x4eb590]!==_0x3204f9('0x18d')&&this[_0x3204f9('0xc')][_0x3204f9('0x161')](util[_0x3204f9('0x150')]('GOOGLE_ASR_%s',_0x4eb590[_0x3204f9('0x18a')]()),_0x17761c[_0x4eb590]);}return this[_0x3204f9('0xc')]['noop'](util[_0x3204f9('0x150')](_0x3204f9('0xaf'),JSON[_0x3204f9('0x27')](_0x17761c)));}}return _0x206ab8;},AGIVertices['prototype'][_0x1e747f('0x151')]=function(_0x1ccba9){const _0x5ea023=_0x1e747f;logger[_0x5ea023('0xd8')](util[_0x5ea023('0x150')](_0x5ea023('0x1ca'),_0x1ccba9[_0x5ea023('0xae')]));if(!this[_0x5ea023('0x10a')](_0x1ccba9['appid']))return this[_0x5ea023('0xc')][_0x5ea023('0x16d')](_0x5ea023('0xb0'));if(!this[_0x5ea023('0x10a')](_0x1ccba9['appsecret']))return this[_0x5ea023('0xc')][_0x5ea023('0x16d')](_0x5ea023('0x152'));const _0x46b7a4='wav',_0x180ac7=util[_0x5ea023('0x150')](_0x5ea023('0x1a3'),FILES_PATH,rs[_0x5ea023('0xf9')](0x4)),_0x282d81=util[_0x5ea023('0x150')]('%s.%s',_0x180ac7,_0x46b7a4);let _0x568ef7=!![];_0x1ccba9[_0x5ea023('0x104')]===_0x5ea023('0xb2')&&(_0x568ef7=![]);const _0x768dd0=this[_0x5ea023('0xc')][_0x5ea023('0x55')](_0x180ac7,_0x46b7a4,_0x1ccba9[_0x5ea023('0x188')],_0x1ccba9[_0x5ea023('0x101')],undefined,_0x568ef7);if(_0x768dd0[_0x5ea023('0xb1')]!==-0x1){this[_0x5ea023('0xc')]['noop'](util[_0x5ea023('0x150')](_0x5ea023('0x21'),_0x282d81));const _0x2a4fb5=this[_0x5ea023('0x67')]['sync'](this,_0x1ccba9,_0x282d81);if(_0x2a4fb5){for(const _0x4eb8a5 in _0x2a4fb5){typeof _0x2a4fb5[_0x4eb8a5]!=='undefined'&&this[_0x5ea023('0xc')][_0x5ea023('0x161')](util['format'](_0x5ea023('0x1c6'),_0x4eb8a5[_0x5ea023('0x18a')]()),_0x2a4fb5[_0x4eb8a5]);}return this[_0x5ea023('0xc')][_0x5ea023('0x16d')](util[_0x5ea023('0x150')](_0x5ea023('0x186'),JSON[_0x5ea023('0x27')](_0x2a4fb5)));}}return _0x768dd0;},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x2b')]=function(_0x5533cd){const _0x2d6d26=_0x1e747f;return logger['info'](util[_0x2d6d26('0x150')](_0x2d6d26('0x1b9'),_0x5533cd[_0x2d6d26('0xae')])),this['channel'][_0x2d6d26('0x117')](_0x5533cd[_0x2d6d26('0xf6')],_0x5533cd[_0x2d6d26('0xdd')],_0x5533cd['priority']);},AGIVertices[_0x1e747f('0xdb')]['gotoif']=function(_0x506016){const _0x42fc56=_0x1e747f;logger['info'](util['format'](_0x42fc56('0x78'),_0x506016[_0x42fc56('0xae')]));if(!this[_0x42fc56('0x10a')](_0x506016[_0x42fc56('0x1c5')]))return this['channel'][_0x42fc56('0x7c')](_0x506016,_0x42fc56('0x1c0'));try{const _0x46ed02=eval(_0x506016[_0x42fc56('0x1c5')])?_0x42fc56('0x1cd'):_0x42fc56('0xf1');return this[_0x42fc56('0xc')][_0x42fc56('0x16d')](util[_0x42fc56('0x150')](_0x42fc56('0x6c'),_0x506016[_0x42fc56('0x1c5')],_0x46ed02)),{'code':0xc8,'result':_0x46ed02};}catch(_0x175131){return{'code':0xc8,'result':_0x42fc56('0xf1')};}},AGIVertices[_0x1e747f('0xdb')]['gotoiftime']=function(_0x96a0cb){const _0x6193e2=_0x1e747f;logger['info'](util[_0x6193e2('0x150')]('Enter\x20in\x20GOTOIFTIME\x20(%s)\x20block',_0x96a0cb[_0x6193e2('0xae')]));if(!this['isConfigured'](_0x96a0cb[_0x6193e2('0xd0')]))return this[_0x6193e2('0xc')][_0x6193e2('0x7c')](_0x96a0cb,_0x6193e2('0x1a5'));const _0x27ae30=this[_0x6193e2('0x6b')][_0x6193e2('0x13c')](this,_0x96a0cb[_0x6193e2('0xd0')]);if(!_0x27ae30)return this['channel']['error'](_0x96a0cb,_0x6193e2('0x1cf'));for(let _0x5b81b4=0x0;_0x5b81b4<_0x27ae30['length'];_0x5b81b4+=0x1){const _0x345ae0=this[_0x6193e2('0xc')][_0x6193e2('0x14b')](util[_0x6193e2('0x150')](_0x6193e2('0x2'),_0x27ae30[_0x5b81b4]));if(_0x345ae0[_0x6193e2('0xb1')]===-0x1)return _0x345ae0;logger['info'](util[_0x6193e2('0x150')](_0x6193e2('0x50'),_0x27ae30[_0x5b81b4],_0x345ae0[_0x6193e2('0x174')]));if(_0x345ae0[_0x6193e2('0x174')]===_0x6193e2('0x1cd'))return logger[_0x6193e2('0xd8')](util['format']('IFTIME\x20%s\x20%s',_0x27ae30[_0x5b81b4],_0x6193e2('0x1cd'))),this[_0x6193e2('0xc')][_0x6193e2('0x16d')](util[_0x6193e2('0x150')](_0x6193e2('0x50'),_0x27ae30[_0x5b81b4],_0x6193e2('0x1cd'))),{'code':0xc8,'result':_0x6193e2('0x1cd')};else logger['info'](util[_0x6193e2('0x150')](_0x6193e2('0x50'),_0x27ae30[_0x5b81b4],_0x6193e2('0xf1'))),this[_0x6193e2('0xc')][_0x6193e2('0x16d')](util[_0x6193e2('0x150')](_0x6193e2('0x50'),_0x27ae30[_0x5b81b4],_0x6193e2('0xf1')));}return{'code':0xc8,'result':'false'};},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xdf')]=function(_0x115d3d){const _0x3c98f0=_0x1e747f;return logger[_0x3c98f0('0xd8')](util[_0x3c98f0('0x150')](_0x3c98f0('0x58'),_0x115d3d[_0x3c98f0('0xae')])),this['channel'][_0x3c98f0('0xdf')]();},AGIVertices[_0x1e747f('0xdb')]['ispeechasr']=function(_0x349f1b){const _0x2a9353=_0x1e747f;logger[_0x2a9353('0xd8')](util['format'](_0x2a9353('0x140'),_0x349f1b['label']));if(!this[_0x2a9353('0x10a')](_0x349f1b[_0x2a9353('0xa3')]))return this[_0x2a9353('0xc')][_0x2a9353('0x16d')](_0x2a9353('0x1cc'));const _0x3bf0d5=_0x2a9353('0x10f'),_0x15e8c8=util[_0x2a9353('0x150')](_0x2a9353('0x1a3'),FILES_PATH,rs['generate'](0x4)),_0x1076d9=util['format']('%s.%s',_0x15e8c8,_0x3bf0d5);let _0x452b30=!![];_0x349f1b['beep']===_0x2a9353('0xb2')&&(_0x452b30=![]);const _0x483d60=this[_0x2a9353('0xc')][_0x2a9353('0x55')](_0x15e8c8,_0x3bf0d5,_0x349f1b[_0x2a9353('0x188')],_0x349f1b[_0x2a9353('0x101')],undefined,_0x452b30);if(_0x483d60[_0x2a9353('0xb1')]!==-0x1){this['channel'][_0x2a9353('0x16d')](util['format']('ispeech\x20%s\x20file\x20created',_0x1076d9));const _0x14fce7=this[_0x2a9353('0x1b0')]['sync'](this,_0x349f1b,_0x1076d9);if(_0x14fce7){for(const _0x6d016e in _0x14fce7){typeof _0x14fce7[_0x6d016e]!=='undefined'&&this[_0x2a9353('0xc')][_0x2a9353('0x161')](util[_0x2a9353('0x150')](_0x2a9353('0xc8'),_0x6d016e['toUpperCase']()),_0x14fce7[_0x6d016e]);}return this[_0x2a9353('0xc')]['noop'](util['format'](_0x2a9353('0x173'),JSON[_0x2a9353('0x27')](_0x14fce7)));}}return _0x483d60;},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x13d')]=function(_0x71e44){const _0x3ba566=_0x1e747f;logger[_0x3ba566('0xd8')](util['format'](_0x3ba566('0x39'),_0x71e44[_0x3ba566('0xae')]));if(!this['isConfigured'](_0x71e44[_0x3ba566('0xa3')]))return this[_0x3ba566('0xc')][_0x3ba566('0x16d')](_0x3ba566('0x1cc'));if(!this[_0x3ba566('0x10a')](_0x71e44[_0x3ba566('0x1c7')]))return this['channel'][_0x3ba566('0x16d')](_0x3ba566('0x9'));this[_0x3ba566('0xc')]['noop'](util[_0x3ba566('0x150')](_0x3ba566('0x13a'),_0x71e44[_0x3ba566('0x1c7')]));const _0x50a7a0=this[_0x3ba566('0x87')][_0x3ba566('0x13c')](this,_0x71e44);if(_0x50a7a0){this[_0x3ba566('0xc')][_0x3ba566('0x16d')](util[_0x3ba566('0x150')]('ispeech\x20%s\x20file\x20created',_0x50a7a0));const _0x304c41=this['channel'][_0x3ba566('0xa0')](_0x50a7a0,_0x71e44[_0x3ba566('0x188')]);try{fs[_0x3ba566('0xb5')](_0x50a7a0+_0x3ba566('0x4b'));}catch(_0x31b2e6){logger[_0x3ba566('0x7c')](_0x31b2e6);}return _0x304c41;}return this[_0x3ba566('0xc')][_0x3ba566('0x7c')](_0x71e44,_0x3ba566('0xcc'));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xf4')]=function(_0x291f23){const _0x365f51=_0x1e747f;logger['info'](util[_0x365f51('0x150')](_0x365f51('0xf3'),_0x291f23['label']));if(!this[_0x365f51('0x10a')](_0x291f23[_0x365f51('0x190')]))return this[_0x365f51('0xc')][_0x365f51('0x7c')](_0x291f23,'no\x20find\x20by\x20configured');logger['info'](util[_0x365f51('0x150')]('FIND\x20AGENT\x20%s\x20BY\x20%s',this[_0x365f51('0xc')][_0x365f51('0x1c4')],_0x291f23[_0x365f51('0x190')]));const _0x3104ea=this[_0x365f51('0x14e')][_0x365f51('0x13c')](this,_0x291f23[_0x365f51('0x190')]);return _0x3104ea?(logger[_0x365f51('0xd8')](util['format'](_0x365f51('0x143'),this[_0x365f51('0xc')][_0x365f51('0x1c4')],_0x291f23[_0x365f51('0x190')])),this['channel']['noop'](util[_0x365f51('0x150')]('AGENT\x20%s\x20FOUND\x20BY',this['channel'][_0x365f51('0x1c4')],_0x291f23[_0x365f51('0x190')])),{'code':0xc8,'result':_0x365f51('0xfb')}):(logger[_0x365f51('0xd8')](util[_0x365f51('0x150')](_0x365f51('0x70'),this[_0x365f51('0xc')][_0x365f51('0x1c4')],_0x291f23['findBy'])),this[_0x365f51('0xc')][_0x365f51('0x16d')](util[_0x365f51('0x150')](_0x365f51('0x70'),this[_0x365f51('0xc')][_0x365f51('0x1c4')],_0x291f23[_0x365f51('0x190')])),{'code':0xc8,'result':_0x365f51('0x6d')});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x19b')]=function(_0x54f189){const _0x5ec64b=_0x1e747f;logger['info'](util[_0x5ec64b('0x150')]('Enter\x20in\x20LOGOUT\x20(%s)\x20block',_0x54f189['label']));if(!this['isConfigured'](_0x54f189[_0x5ec64b('0x190')]))return this[_0x5ec64b('0xc')][_0x5ec64b('0x7c')](_0x54f189,_0x5ec64b('0x1c8'));logger[_0x5ec64b('0xd8')](util[_0x5ec64b('0x150')](_0x5ec64b('0x32'),this[_0x5ec64b('0xc')][_0x5ec64b('0x1c4')],_0x54f189[_0x5ec64b('0x190')]));const _0x424050=this[_0x5ec64b('0xe7')][_0x5ec64b('0x13c')](this,_0x54f189['findBy']);return _0x424050?(logger[_0x5ec64b('0xd8')](util[_0x5ec64b('0x150')](_0x5ec64b('0x143'),this[_0x5ec64b('0xc')][_0x5ec64b('0x1c4')],_0x54f189[_0x5ec64b('0x190')])),this[_0x5ec64b('0xc')][_0x5ec64b('0x16d')](util[_0x5ec64b('0x150')](_0x5ec64b('0x143'),this[_0x5ec64b('0xc')][_0x5ec64b('0x1c4')],_0x54f189['findBy'])),{'code':0xc8,'result':_0x5ec64b('0xfb')}):(logger[_0x5ec64b('0xd8')](util[_0x5ec64b('0x150')](_0x5ec64b('0x70'),this[_0x5ec64b('0xc')]['callerid'],_0x54f189[_0x5ec64b('0x190')])),this[_0x5ec64b('0xc')]['noop'](util[_0x5ec64b('0x150')](_0x5ec64b('0x70'),this[_0x5ec64b('0xc')][_0x5ec64b('0x1c4')],_0x54f189[_0x5ec64b('0x190')])),{'code':0xc8,'result':'failure'});},AGIVertices[_0x1e747f('0xdb')]['math']=function(_0x2ac4a4){const _0x3f1fa3=_0x1e747f;logger[_0x3f1fa3('0xd8')](util[_0x3f1fa3('0x150')]('Enter\x20in\x20MATH\x20(%s)\x20block',_0x2ac4a4['label']));if(!this[_0x3f1fa3('0x10a')](_0x2ac4a4[_0x3f1fa3('0x162')]))return this[_0x3f1fa3('0xc')][_0x3f1fa3('0x7c')](_0x2ac4a4,'no\x20operation\x20configured');this[_0x3f1fa3('0xc')][_0x3f1fa3('0x16d')](util[_0x3f1fa3('0x150')]('math\x20%s',_0x2ac4a4['operation']));const _0xebd85a=eval(_0x2ac4a4[_0x3f1fa3('0x162')]);if(!this[_0x3f1fa3('0x10a')](_0x2ac4a4[_0x3f1fa3('0xa4')]))return this[_0x3f1fa3('0xc')][_0x3f1fa3('0x16d')](_0x3f1fa3('0x6e'));const _0x23457e=this[_0x3f1fa3('0x14b')][_0x3f1fa3('0x13c')](this,_0x2ac4a4['variable_id']);if(!_0x23457e)return this[_0x3f1fa3('0xc')][_0x3f1fa3('0x7c')](_0x2ac4a4,_0x3f1fa3('0x1d1'));if(_[_0x3f1fa3('0x192')](_0xebd85a)){const _0x432f73=this;return _0xebd85a[_0x3f1fa3('0x2a')](function(_0x23eea6,_0x43e717){const _0x183235=_0x3f1fa3;_0x432f73[_0x183235('0xc')][_0x183235('0x161')](util['format'](_0x183235('0x159'),_0x23457e,_0x43e717),_0x23eea6);}),this[_0x3f1fa3('0xc')][_0x3f1fa3('0x16d')](util[_0x3f1fa3('0x150')](_0x3f1fa3('0xb7'),_0x23457e));}else return this[_0x3f1fa3('0xc')][_0x3f1fa3('0x161')](_0x23457e,_0xebd85a);},AGIVertices['prototype'][_0x1e747f('0xe1')]=function(_0x13a98b){const _0x1982cc=_0x1e747f;logger[_0x1982cc('0xd8')](util[_0x1982cc('0x150')](_0x1982cc('0x56'),_0x13a98b[_0x1982cc('0xae')]));if(_0x13a98b[_0x1982cc('0x8')]===0x0)return this[_0x1982cc('0x16a')](_0x13a98b);_0x13a98b[_0x1982cc('0x8')]-=0x1;if(!this[_0x1982cc('0x10a')](_0x13a98b[_0x1982cc('0xc4')]))return this['channel'][_0x1982cc('0x7c')](_0x13a98b,_0x1982cc('0xe3'));const _0x4c2d4b=this[_0x1982cc('0x37')]['sync'](this,_0x13a98b['file_id']);if(!_0x4c2d4b)return this[_0x1982cc('0xc')]['error'](_0x13a98b,_0x1982cc('0x18f'));const _0x5e1491=this[_0x1982cc('0xc')][_0x1982cc('0x183')](_0x4c2d4b,_0x13a98b[_0x1982cc('0x73')],_0x13a98b[_0x1982cc('0xd2')]);let _0x4231be=_0x5e1491[_0x1982cc('0xb1')];if(_0x5e1491['result']===-0x1)return this[_0x1982cc('0x9b')][_0x1982cc('0x13c')](this,_0x13a98b,'-1'),_0x5e1491;else{if(_0x5e1491['extra']===_0x1982cc('0x101'))_0x5e1491['result']=_0x5e1491[_0x1982cc('0xb1')]['length']>0x0?_0x5e1491[_0x1982cc('0xb1')]:'t';else _[_0x1982cc('0x180')](_0x5e1491[_0x1982cc('0xb1')])&&(_0x5e1491[_0x1982cc('0xb1')]='#',_0x4231be='#');}if(!this[_0x1982cc('0x10a')](_0x13a98b[_0x1982cc('0xa4')]))this[_0x1982cc('0xc')][_0x1982cc('0x16d')](_0x1982cc('0x6e'));else{const _0x160cca=this[_0x1982cc('0x14b')][_0x1982cc('0x13c')](this,_0x13a98b[_0x1982cc('0xa4')]);if(!_0x160cca)return this['channel']['error'](_0x13a98b,_0x1982cc('0x1d1'));this[_0x1982cc('0xc')][_0x1982cc('0x161')](_0x160cca,_0x4231be);}return this[_0x1982cc('0x9b')]['sync'](this,_0x13a98b,_0x4231be),_0x5e1491;},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x16d')]=function(_0xc6f6e6){const _0xb4664=_0x1e747f;return logger['info'](util[_0xb4664('0x150')](_0xb4664('0x138'),_0xc6f6e6[_0xb4664('0xae')])),this['channel'][_0xb4664('0x16d')](_0xc6f6e6['output']||_0xc6f6e6[_0xb4664('0xae')]);},AGIVertices[_0x1e747f('0xdb')]['pause']=function(_0x1a83db){const _0x3dea38=_0x1e747f;logger[_0x3dea38('0xd8')](util[_0x3dea38('0x150')](_0x3dea38('0x195'),_0x1a83db['label']));if(!this[_0x3dea38('0x10a')](_0x1a83db[_0x3dea38('0x190')]))return this[_0x3dea38('0xc')][_0x3dea38('0x7c')](_0x1a83db,'no\x20find\x20by\x20configured');logger[_0x3dea38('0xd8')](util[_0x3dea38('0x150')]('FIND\x20AGENT\x20%s\x20BY\x20%s',this['channel'][_0x3dea38('0x1c4')],_0x1a83db[_0x3dea38('0x190')]));const _0x798270=this[_0x3dea38('0x34')][_0x3dea38('0x13c')](this,_0x1a83db[_0x3dea38('0x1a6')]),_0x48163f=this[_0x3dea38('0x66')][_0x3dea38('0x13c')](this,_0x1a83db[_0x3dea38('0x190')],_0x798270);return _0x48163f?(logger[_0x3dea38('0xd8')](util['format']('AGENT\x20%s\x20FOUND\x20BY',this[_0x3dea38('0xc')][_0x3dea38('0x1c4')],_0x1a83db[_0x3dea38('0x190')])),this[_0x3dea38('0xc')][_0x3dea38('0x16d')](util[_0x3dea38('0x150')]('AGENT\x20%s\x20FOUND\x20BY',this[_0x3dea38('0xc')][_0x3dea38('0x1c4')],_0x1a83db[_0x3dea38('0x190')])),{'code':0xc8,'result':_0x3dea38('0xfb')}):(logger[_0x3dea38('0xd8')](util[_0x3dea38('0x150')]('AGENT\x20%s\x20NOT\x20FOUND\x20BY',this[_0x3dea38('0xc')]['callerid'],_0x1a83db[_0x3dea38('0x190')])),this['channel']['noop'](util[_0x3dea38('0x150')](_0x3dea38('0x143'),this[_0x3dea38('0xc')][_0x3dea38('0x1c4')],_0x1a83db[_0x3dea38('0x190')])),{'code':0xc8,'result':_0x3dea38('0x6d')});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x7')]=function(_0x3518ca){const _0x5b699c=_0x1e747f;logger[_0x5b699c('0xd8')](util['format'](_0x5b699c('0xb9'),_0x3518ca[_0x5b699c('0xae')]));if(!this['isConfigured'](_0x3518ca[_0x5b699c('0xc4')]))return this[_0x5b699c('0xc')][_0x5b699c('0x7c')](_0x3518ca,_0x5b699c('0xe3'));const _0x5e2e61=this['getSound'][_0x5b699c('0x13c')](this,_0x3518ca[_0x5b699c('0xc4')]);if(!_0x5e2e61)return this[_0x5b699c('0xc')][_0x5b699c('0x7c')](_0x3518ca,'no\x20file\x20audio\x20found');const _0x4eab0b=this[_0x5b699c('0xc')][_0x5b699c('0x2c')](_0x5b699c('0x116'),[_0x5e2e61,_0x3518ca[_0x5b699c('0x31')]]);if(_0x4eab0b[_0x5b699c('0xb1')]===-0x1)return _0x4eab0b;return this[_0x5b699c('0xc')][_0x5b699c('0x16d')](util[_0x5b699c('0x150')]('Executed\x20command\x20%s\x20%s',_0x5b699c('0x116'),_0x5e2e61));},AGIVertices['prototype'][_0x1e747f('0x15a')]=function(_0x9ffa9b){const _0x4ae1a5=_0x1e747f;logger[_0x4ae1a5('0xd8')](util['format'](_0x4ae1a5('0xde'),_0x9ffa9b[_0x4ae1a5('0xae')]));if(!this[_0x4ae1a5('0x10a')](_0x9ffa9b[_0x4ae1a5('0x115')]))return this[_0x4ae1a5('0xc')]['error'](_0x9ffa9b,'no\x20queue\x20selected');let _0x254851='';const _0xadfa88=parseInt(_0x9ffa9b[_0x4ae1a5('0x115')],0xa);if(isNaN(_0xadfa88))_0x254851=_0x9ffa9b['queue_id'];else{_0x254851=this['getVoiceQueue'][_0x4ae1a5('0x13c')](this,_0x9ffa9b[_0x4ae1a5('0x115')]);if(!_0x254851)return this[_0x4ae1a5('0xc')]['error'](_0x9ffa9b,_0x4ae1a5('0xd'));}let _0x3a4c1d='';if(this[_0x4ae1a5('0x10a')](_0x9ffa9b[_0x4ae1a5('0xc4')])){const _0x1c53f7=this[_0x4ae1a5('0x37')][_0x4ae1a5('0x13c')](this,_0x9ffa9b['file_id']);_0x1c53f7&&(_0x3a4c1d=_0x1c53f7);}this[_0x4ae1a5('0x9b')][_0x4ae1a5('0x13c')](this,_0x9ffa9b,_0x254851);_0x9ffa9b[_0x4ae1a5('0x31')][_0x4ae1a5('0x84')]('x')<0x0&&(_0x9ffa9b['opts']+='x');_0x9ffa9b[_0x4ae1a5('0x31')][_0x4ae1a5('0x84')]('X')<0x0&&(_0x9ffa9b[_0x4ae1a5('0x31')]+='X');this[_0x4ae1a5('0xc')]['setVariable'](_0x4ae1a5('0x7f'),_0x254851?_0x254851[_0x4ae1a5('0x35')]():'');const _0x2dae7b=this['channel'][_0x4ae1a5('0x2c')](_0x4ae1a5('0x83'),[_0x254851,_0x9ffa9b['opts'],_0x9ffa9b[_0x4ae1a5('0x4f')],_0x3a4c1d,_0x9ffa9b[_0x4ae1a5('0x101')],_0x9ffa9b[_0x4ae1a5('0xb8')],_0x9ffa9b[_0x4ae1a5('0x184')],_0x9ffa9b[_0x4ae1a5('0x3e')],'',_0x9ffa9b['position']]);if(_0x2dae7b[_0x4ae1a5('0xb1')]===-0x1)return _0x2dae7b;return this[_0x4ae1a5('0xc')][_0x4ae1a5('0x16d')](util[_0x4ae1a5('0x150')]('Executed\x20command\x20%s\x20%s',_0x4ae1a5('0x83'),_0x254851));},AGIVertices['prototype']['record']=function(_0x473673){const _0x2dcf3f=_0x1e747f;logger['info'](util['format'](_0x2dcf3f('0xef'),_0x473673[_0x2dcf3f('0xae')]));const _0x57717e=_0x473673[_0x2dcf3f('0xfe')]||'wav',_0x482687=util[_0x2dcf3f('0x150')](_0x2dcf3f('0x11f'),this[_0x2dcf3f('0xc')][_0x2dcf3f('0xba')],rs['generate'](0x5)),_0xd5d18e=util[_0x2dcf3f('0x150')](_0x2dcf3f('0x16e'),FILES_PATH,_0x482687,_0x57717e),_0x2a518e=util[_0x2dcf3f('0x150')]('%s/recordings/%s',FILES_PATH,_0x482687);return this[_0x2dcf3f('0x191')]['sync'](this,_0x473673,_0x482687,_0xd5d18e),this['channel']['setVariable'](_0x2dcf3f('0x119'),_0x482687),logger[_0x2dcf3f('0xd8')](_0x2dcf3f('0x23'),_0x2a518e,_0x57717e,_0x473673[_0x2dcf3f('0x1c2')],_0x473673['timeout']),this[_0x2dcf3f('0xc')][_0x2dcf3f('0x55')](_0x2a518e,_0x57717e,_0x473673[_0x2dcf3f('0x1c2')],_0x473673[_0x2dcf3f('0x101')],undefined,!![]);},AGIVertices['prototype'][_0x1e747f('0x76')]=function(_0x3f3cc6){const _0x40db87=_0x1e747f;logger[_0x40db87('0xd8')](util['format']('Enter\x20in\x20RESTAPI\x20(%s)\x20block',_0x3f3cc6['label']));if(!this[_0x40db87('0x10a')](_0x3f3cc6['url']))return this['channel']['noop'](_0x40db87('0xe5'));const _0x341069=this['restAPI'][_0x40db87('0x13c')](this,_0x3f3cc6);logger['info'](util['format'](_0x40db87('0x1e'),util[_0x40db87('0x1cb')](_0x341069,{'showHidden':![],'depth':null})));if(!this[_0x40db87('0x10a')](_0x3f3cc6[_0x40db87('0xa4')]))return this[_0x40db87('0xc')][_0x40db87('0x16d')]('no\x20variable\x20selected\x20for\x20the\x20response');const _0x14d9a2=this[_0x40db87('0x14b')]['sync'](this,_0x3f3cc6[_0x40db87('0xa4')]);if(!_0x14d9a2)return this[_0x40db87('0xc')]['error'](_0x3f3cc6,'no\x20variable\x20found');this[_0x40db87('0xc')][_0x40db87('0x161')](util[_0x40db87('0x150')](_0x40db87('0x127'),_0x14d9a2),_0x341069['statusCode']?_0x341069['statusCode']:_0x40db87('0x16c')),this['channel'][_0x40db87('0x161')](util[_0x40db87('0x150')](_0x40db87('0x77'),_0x14d9a2),_0x341069[_0x40db87('0x92')]?_0x341069['statusMessage']:'OK');if(_0x341069['body'])try{this[_0x40db87('0x120')](_0x341069[_0x40db87('0x5a')],_0x14d9a2);}catch(_0x3ea91a){logger[_0x40db87('0x7c')](util[_0x40db87('0x150')](_0x40db87('0xad'),_0x14d9a2));}return this['channel'][_0x40db87('0x16d')](util[_0x40db87('0x150')](_0x40db87('0x160'),_0x14d9a2));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x187')]=function(_0x332ff1){const _0xfb152a=_0x1e747f;return logger[_0xfb152a('0xd8')](util[_0xfb152a('0x150')](_0xfb152a('0x1b4'),_0x332ff1['label'])),this['channel'][_0xfb152a('0x137')](_0x332ff1['digits'][_0xfb152a('0x124')](/\s+/g,''),_0x332ff1['escape_digits']);},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x164')]=function(_0x5d9243){const _0x3e279f=_0x1e747f;return logger[_0x3e279f('0xd8')](util[_0x3e279f('0x150')](_0x3e279f('0x8c'),_0x5d9243[_0x3e279f('0xae')])),this[_0x3e279f('0xc')][_0x3e279f('0x11a')](_0x5d9243[_0x3e279f('0x100')][_0x3e279f('0x124')](/\s+/g,''),_0x5d9243[_0x3e279f('0x1c2')]);},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x10c')]=function(_0x4934c2){const _0x575503=_0x1e747f;return logger['info'](util[_0x575503('0x150')](_0x575503('0xb'),_0x4934c2[_0x575503('0xae')])),this[_0x575503('0xc')][_0x575503('0xe4')](_0x4934c2[_0x575503('0x1c7')],_0x4934c2[_0x575503('0x1c2')]);},AGIVertices[_0x1e747f('0xdb')]['sendMail']=function(_0x2bb0f3){const _0x3385a5=_0x1e747f;logger[_0x3385a5('0xd8')](util['format'](_0x3385a5('0x44'),_0x2bb0f3[_0x3385a5('0xae')]));if(!this[_0x3385a5('0x10a')](_0x2bb0f3[_0x3385a5('0x53')]))return this[_0x3385a5('0xc')]['noop'](_0x3385a5('0x178'));const _0x1fc9ae=this[_0x3385a5('0xa9')][_0x3385a5('0x13c')](this,_0x2bb0f3[_0x3385a5('0x53')]);if(!_0x1fc9ae||!_0x1fc9ae[_0x3385a5('0x1ac')])return this[_0x3385a5('0xc')][_0x3385a5('0x7c')](_0x2bb0f3,_0x3385a5('0x155'));const _0xabe24={'from':util[_0x3385a5('0x150')](_0x3385a5('0x62'),_0x1fc9ae[_0x3385a5('0xd3')],_0x1fc9ae[_0x3385a5('0x81')]||_0x1fc9ae[_0x3385a5('0x1ac')][_0x3385a5('0xa1')]),'to':_0x2bb0f3['to']||'','cc':_0x2bb0f3['cc']||'','bcc':_0x2bb0f3[_0x3385a5('0x168')]||'','subject':_0x2bb0f3[_0x3385a5('0x7b')],'html':_0x2bb0f3['text'],'text':_0x2bb0f3[_0x3385a5('0x1c7')]},_0x25da7d={'tls':{'rejectUnauthorized':![]}};_0x1fc9ae[_0x3385a5('0x1ac')]['service']?_0x25da7d['service']=_0x1fc9ae[_0x3385a5('0x1ac')]['service']:(_0x25da7d['host']=_0x1fc9ae[_0x3385a5('0x1ac')][_0x3385a5('0xa6')],_0x25da7d[_0x3385a5('0x12')]=_0x1fc9ae[_0x3385a5('0x1ac')]['port'],_0x25da7d['secure']=_0x1fc9ae[_0x3385a5('0x1ac')][_0x3385a5('0xc3')]);_0x1fc9ae[_0x3385a5('0x1ac')]['authentication']&&(_0x25da7d[_0x3385a5('0x47')]={'user':_0x1fc9ae['Smtp']['user'],'pass':_0x1fc9ae[_0x3385a5('0x1ac')]['pass']});if(this[_0x3385a5('0x10a')](_0x2bb0f3['template_id'])){}return logger[_0x3385a5('0x15b')](_0x3385a5('0x1be'),JSON[_0x3385a5('0x27')](_0xabe24)),this[_0x3385a5('0x9b')][_0x3385a5('0x13c')](this,_0x2bb0f3,_0x2bb0f3['account_id']),this[_0x3385a5('0xc')][_0x3385a5('0x16d')](util['format'](_0x3385a5('0x126'),_0x1fc9ae[_0x3385a5('0xd3')])),this['sendMailMessage'][_0x3385a5('0x13c')](this,_0x25da7d,_0xabe24),this['channel']['noop'](_0x3385a5('0x1b8'));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x25')]=function(_0xc6a5bc){const _0x21ac4d=_0x1e747f;return logger[_0x21ac4d('0xd8')](util['format']('Enter\x20in\x20SENDFAX\x20(%s)\x20block',_0xc6a5bc['label'])),this[_0x21ac4d('0xc')][_0x21ac4d('0x16d')](_0x21ac4d('0x1b'));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x1bc')]=function(_0x3592cd){const _0x33668b=_0x1e747f;logger[_0x33668b('0xd8')](util[_0x33668b('0x150')](_0x33668b('0x179'),_0x3592cd['label']));if(!this[_0x33668b('0x10a')](_0x3592cd[_0x33668b('0x131')]))return this[_0x33668b('0xc')][_0x33668b('0x16d')]('no\x20sms\x20account\x20configured');const _0x255c1d=this[_0x33668b('0xc0')][_0x33668b('0x13c')](this,_0x3592cd[_0x33668b('0x131')]);if(!_0x255c1d)return this[_0x33668b('0xc')][_0x33668b('0x7c')](_0x3592cd,_0x33668b('0x14c'));const _0x5f3279={'body':_0x3592cd[_0x33668b('0x1a0')],'phone':_0x3592cd['to']||'','SmsAccountId':_0x255c1d['id']};return logger[_0x33668b('0x15b')](_0x33668b('0x171'),JSON[_0x33668b('0x27')](_0x5f3279)),this['createSquareDetailsReport']['sync'](this,_0x3592cd,_0x3592cd[_0x33668b('0x131')]),this[_0x33668b('0xc')][_0x33668b('0x16d')](util['format'](_0x33668b('0xa7'),_0x255c1d[_0x33668b('0xd3')])),this[_0x33668b('0x14')][_0x33668b('0x13c')](this,_0x5f3279),this['channel'][_0x33668b('0x16d')](_0x33668b('0xab'));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x85')]=function(_0x2c53ac){const _0x30efdd=_0x1e747f;logger[_0x30efdd('0xd8')](util[_0x30efdd('0x150')](_0x30efdd('0x1a8'),_0x2c53ac[_0x30efdd('0xae')]));if(!this[_0x30efdd('0x10a')](_0x2c53ac[_0x30efdd('0xa4')]))return this[_0x30efdd('0xc')]['error'](_0x2c53ac,'no\x20variable\x20selected');const _0x1a7c52=this[_0x30efdd('0x14b')][_0x30efdd('0x13c')](this,_0x2c53ac['variable_id']);if(!_0x1a7c52)return this['channel']['error'](_0x2c53ac,'no\x20variable\x20found');return this[_0x30efdd('0xc')][_0x30efdd('0x161')](_0x1a7c52,_0x2c53ac[_0x30efdd('0x129')]);},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x15f')]=function(_0x4b5192){const _0x2d6a91=_0x1e747f;logger['info'](util['format']('Enter\x20in\x20START\x20(%s)\x20block',_0x4b5192[_0x2d6a91('0xae')])),this[_0x2d6a91('0xc')][_0x2d6a91('0x16d')](_0x2d6a91('0xbf'));if(_0x4b5192[_0x2d6a91('0x154')]===_0x2d6a91('0x102'))return this['channel'][_0x2d6a91('0x16d')]('Answer'),this[_0x2d6a91('0xc')][_0x2d6a91('0x154')]();return this[_0x2d6a91('0xc')][_0x2d6a91('0x16d')](_0x2d6a91('0x198'));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x0')]=function(_0x2fc32a){const _0x3ca2f0=_0x1e747f;logger[_0x3ca2f0('0xd8')](util[_0x3ca2f0('0x150')](_0x3ca2f0('0xf'),_0x2fc32a['label']));if(!this[_0x3ca2f0('0x10a')](_0x2fc32a[_0x3ca2f0('0x182')]))return this[_0x3ca2f0('0xc')][_0x3ca2f0('0x7c')](_0x2fc32a,_0x3ca2f0('0xe8'));const _0x54f5bc=this[_0x3ca2f0('0x1f')][_0x3ca2f0('0x13c')](this,_0x2fc32a[_0x3ca2f0('0x182')]);if(!this[_0x3ca2f0('0x10a')](_0x54f5bc))return this[_0x3ca2f0('0xc')][_0x3ca2f0('0x7c')](_0x2fc32a,util['format'](_0x3ca2f0('0xec'),_0x2fc32a[_0x3ca2f0('0x182')]));if(_0x54f5bc===this['channel']['arg_1'])return this[_0x3ca2f0('0xc')]['error'](_0x2fc32a,'project\x20in\x20subproject\x20must\x20be\x20different\x20from\x20the\x20called\x20project');this[_0x3ca2f0('0x9b')]['sync'](this,_0x2fc32a,_0x54f5bc);const _0x2d48e3=this[_0x3ca2f0('0xc')][_0x3ca2f0('0x2c')](_0x3ca2f0('0x17e'),util['format'](_0x3ca2f0('0x16f'),config[_0x3ca2f0('0xb8')][_0x3ca2f0('0xa6')]||_0x3ca2f0('0x3'),_0x54f5bc,this['channel'][_0x3ca2f0('0x1ba')]));if(_0x2d48e3[_0x3ca2f0('0xb1')]===-0x1)return _0x2d48e3;return this[_0x3ca2f0('0xc')]['noop'](util['format'](_0x3ca2f0('0xf8'),_0x3ca2f0('0x17e'),_0x54f5bc));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x18b')]=function(_0x21368a){const _0x2dac20=_0x1e747f;logger[_0x2dac20('0xd8')](util[_0x2dac20('0x150')](_0x2dac20('0x72'),_0x21368a[_0x2dac20('0xae')]));const _0x24a601=this[_0x2dac20('0x11c')][_0x2dac20('0x13c')](this,_0x21368a[_0x2dac20('0xe')]);this[_0x2dac20('0x9b')][_0x2dac20('0x13c')](this,_0x21368a,_0x21368a[_0x2dac20('0xe')]);if(this[_0x2dac20('0x10a')](_0x21368a[_0x2dac20('0xa4')])){const _0x179f2c=this[_0x2dac20('0x14b')]['sync'](this,_0x21368a['variable_id']);if(_0x179f2c)return this[_0x2dac20('0xc')]['setVariable'](_0x179f2c,_0x24a601),this[_0x2dac20('0xc')]['noop'](util[_0x2dac20('0x150')](_0x2dac20('0x149'),_0x21368a[_0x2dac20('0xe')],_0x179f2c));}return this[_0x2dac20('0xc')][_0x2dac20('0x16d')](util[_0x2dac20('0x150')](_0x2dac20('0x12a'),_0x21368a[_0x2dac20('0xe')]));},AGIVertices[_0x1e747f('0xdb')]['google_cloud_tts']=function(_0x11cfa0){const _0x106ccd=_0x1e747f;logger[_0x106ccd('0xd8')](util['format'](_0x106ccd('0x90'),_0x11cfa0[_0x106ccd('0xae')])),_0x11cfa0[_0x106ccd('0x1c7')]=_0x11cfa0[_0x106ccd('0x1c7')][_0x106ccd('0x124')](/(\r\n|\n|\r)/gm,'\x20');if(!this[_0x106ccd('0x10a')](_0x11cfa0[_0x106ccd('0x11b')]))return this[_0x106ccd('0xc')][_0x106ccd('0x16d')](_0x106ccd('0x1ce'));if(!this[_0x106ccd('0x10a')](_0x11cfa0[_0x106ccd('0x1c7')]))return this[_0x106ccd('0xc')][_0x106ccd('0x16d')](_0x106ccd('0x9'));this[_0x106ccd('0xc')][_0x106ccd('0x16d')](util[_0x106ccd('0x150')]('Trying\x20Google\x20Cloud\x20TTS\x20%s',_0x11cfa0[_0x106ccd('0x1c7')]));const _0x4600d7=this[_0x106ccd('0xfc')][_0x106ccd('0x13c')](this,_0x11cfa0);if(_0x4600d7){this[_0x106ccd('0xc')][_0x106ccd('0x16d')](util[_0x106ccd('0x150')](_0x106ccd('0x165'),_0x4600d7));const _0x517976=this['channel']['streamFile'](_0x4600d7);try{fs['unlink'](_0x4600d7+_0x106ccd('0x4b'));}catch(_0x4a1619){logger[_0x106ccd('0x7c')](_0x4a1619);}return _0x517976;}return this[_0x106ccd('0xc')]['error'](_0x11cfa0,'Google\x20Cloud\x20TTS\x20is\x20unreachable');},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xd7')]=function(_0x137c90){const _0x42a376=_0x1e747f;logger['info'](util['format'](_0x42a376('0xe2'),_0x137c90[_0x42a376('0xae')])),_0x137c90[_0x42a376('0x1c7')]=_0x137c90['text'][_0x42a376('0x124')](/(\r\n|\n|\r)/gm,'\x20');if(!this[_0x42a376('0x10a')](_0x137c90['text']))return this[_0x42a376('0xc')][_0x42a376('0x16d')](_0x42a376('0x9'));this[_0x42a376('0xc')][_0x42a376('0x16d')](util['format']('Trying\x20Google\x20TTS\x20%s',_0x137c90[_0x42a376('0x1c7')]));const _0x385449=this['googleTTS']['sync'](this,_0x137c90);if(_0x385449){this[_0x42a376('0xc')]['noop'](util[_0x42a376('0x150')](_0x42a376('0x68'),_0x385449));const _0x384ba1=this[_0x42a376('0xc')][_0x42a376('0xa0')](_0x385449);try{fs['unlink'](_0x385449+_0x42a376('0x4b'));}catch(_0x9752d4){logger[_0x42a376('0x7c')](_0x9752d4);}return _0x384ba1;}return this[_0x42a376('0xc')][_0x42a376('0x7c')](_0x137c90,_0x42a376('0x4'));},AGIVertices['prototype'][_0x1e747f('0x18c')]=function(_0x58a110){const _0x309c81=_0x1e747f;logger[_0x309c81('0xd8')](util[_0x309c81('0x150')](_0x309c81('0x54'),_0x58a110[_0x309c81('0xae')]));if(!this[_0x309c81('0x10a')](_0x58a110[_0x309c81('0x190')]))return this[_0x309c81('0xc')][_0x309c81('0x7c')](_0x58a110,_0x309c81('0x1c8'));logger[_0x309c81('0xd8')](util['format'](_0x309c81('0x32'),this[_0x309c81('0xc')][_0x309c81('0x1c4')],_0x58a110['findBy']));const _0x32d820=this['agentUnpause'][_0x309c81('0x13c')](this,_0x58a110['findBy']);return _0x32d820?(logger[_0x309c81('0xd8')](util[_0x309c81('0x150')](_0x309c81('0x143'),this['channel'][_0x309c81('0x1c4')],_0x58a110['findBy'])),this[_0x309c81('0xc')][_0x309c81('0x16d')](util[_0x309c81('0x150')](_0x309c81('0x143'),this['channel'][_0x309c81('0x1c4')],_0x58a110['findBy'])),{'code':0xc8,'result':_0x309c81('0xfb')}):(logger[_0x309c81('0xd8')](util['format']('AGENT\x20%s\x20NOT\x20FOUND\x20BY',this[_0x309c81('0xc')][_0x309c81('0x1c4')],_0x58a110['findBy'])),this['channel'][_0x309c81('0x16d')](util[_0x309c81('0x150')](_0x309c81('0x70'),this['channel'][_0x309c81('0x1c4')],_0x58a110[_0x309c81('0x190')])),{'code':0xc8,'result':_0x309c81('0x6d')});},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0xc1')]=function(_0x39cde0){const _0x5acc83=_0x1e747f;logger[_0x5acc83('0xd8')](util['format'](_0x5acc83('0x113'),_0x39cde0['label']));const _0x2e17e6=this[_0x5acc83('0xc')][_0x5acc83('0x2c')](_0x5acc83('0x86'),[_0x39cde0[_0x5acc83('0x5')],_0x39cde0['options']]);if(_0x2e17e6[_0x5acc83('0xb1')]===-0x1)return _0x2e17e6;return this['channel'][_0x5acc83('0x16d')](util[_0x5acc83('0x150')](_0x5acc83('0xf8'),_0x5acc83('0x86'),_0x39cde0['mailbox']));},AGIVertices[_0x1e747f('0xdb')][_0x1e747f('0x169')]=function(_0x48154c){const _0x3a8af4=_0x1e747f;logger[_0x3a8af4('0xd8')](util['format'](_0x3a8af4('0x1a9'),_0x48154c[_0x3a8af4('0xae')]));if(!this[_0x3a8af4('0x10a')](_0x48154c[_0x3a8af4('0xa4')]))return this[_0x3a8af4('0xc')][_0x3a8af4('0x7c')](_0x48154c,_0x3a8af4('0x108'));const _0x4c253=this[_0x3a8af4('0x14b')]['sync'](this,_0x48154c[_0x3a8af4('0xa4')]);if(!_0x4c253)return this[_0x3a8af4('0xc')]['error'](_0x48154c,'no\x20variable\x20found');const _0x34ebb8=this[_0x3a8af4('0xc')][_0x3a8af4('0x14b')](_0x4c253);return{'code':0xc8,'result':_0x34ebb8[_0x3a8af4('0x174')]?_0x34ebb8['extra']:'-'};},String[_0x1e747f('0xdb')]['replaceAll']=function(_0x4c4c78,_0x21fc64){const _0x391c96=_0x1e747f;return this[_0x391c96('0x142')](_0x4c4c78)[_0x391c96('0x9f')](_0x21fc64);},module[_0x1e747f('0x176')]=AGIVertices; \ No newline at end of file +const a1048_0xab77=['googleCloudTTS','pause_id','sayNumber','googleDialogflow','keys','Google\x20TTS\x20is\x20unreachable','Smtp','login','%s/%s@from-sip/n','Sms\x20message\x20added\x20to\x20outgoing\x20process','restAPI','macro','MALE','Enter\x20in\x20QUEUE\x20(%s)\x20block','Callback\x20scheduled\x20at\x20','goal','no\x20find\x20by\x20configured','text','Enter\x20in\x20SESTEKNDA\x20(%s)\x20block','Enter\x20in\x20MRCPSynth\x20(%s)\x20block','format','aws_bot_name','sendSMS','delay','sayDigits','sync','sendSMS\x20message','getSoundPath','Enter\x20in\x20RESTAPI\x20(%s)\x20block','Enter\x20in\x20AGI\x20(%s)\x20block','restapi','file_id','odbc_id','position','calleridname','no\x20appsecret\x20configured','list_id','finally','[AGI]\x20Enter\x20in\x20AWSPOLLY\x20(%s)\x20block','SIP/%s/%s','Enter\x20in\x20MATH\x20(%s)\x20block','mustache','Enter\x20in\x20SWITCH\x20(%s)\x20block','number','authentication','maxdigit','opts','password','127.0.0.1','then','SestekNDA\x20Result\x20%s','email','no\x20sms\x20account\x20configured','no\x20apiKey\x20configured','gosub','bot','no\x20queue\x20selected','AGENT\x20%s\x20FOUND\x20BY','isEmpty','getIntervals','no\x20text\x20configured','no\x20url\x20configured','getVariable','.wav','no\x20ndauth\x20url\x20configured','getVoiceQueue','agi','findBy','port','TildeASR\x20Result\x20%s','getSmsAccountById','user','info','GoogleASR\x20Result\x20%s','agentPause','Trying\x20aws\x20Polly\x20%s','sh\x20command:\x20%s\x20result\x20no\x20stored','RECOG_CONFIDENCE()','Trying\x20SendMail\x20with\x20account\x20%s','getMailAccount','Enter\x20in\x20Amazon\x20Lex\x20(%s)\x20block','uri','SENDFAX\x20block\x20not\x20implemented','no\x20anguage\x20configured','Enter\x20in\x20GOOGLEASR\x20(%s)\x20block\x20%s','sip_id','agent','%s[%s][%s]','getAndSetVariable','no\x20trunk\x20selected','no\x20key\x20configured','Enter\x20in\x20PLAYBACK\x20(%s)\x20block','command','replaceAllVariables','getSquareProjectById','getQueryOdbc','replace','PUT','method','tildeasr','dial','variable_id','Recording\x20%s\x20%s\x20%s\x20%s','true','queue_id','getsecretdigits','Enter\x20in\x20RECORD\x20(%s)\x20block','Enter\x20in\x20GOTOIF\x20(%s)\x20block','client_email','no\x20password\x20configured','Query\x20executed\x20correctly\x20%s','grammar','secure','indexOf','Enter\x20in\x20TILDEASR\x20(%s)\x20block','googleasr','createCmContact','forEach','pause','%s_ROWS_COUNT','Wait\x20%s\x20seconds\x20before\x20answer','Enter\x20in\x20VOICEMAIL\x20(%s)\x20block','close','hiddendigitsnum','createSmsMessage','stringify','saydigits','interval_id','recursiveNodeIndex','false','first','lumenvoxtts','url','ispeechASR','Executed\x20command\x20MRCPRecog\x20%s','getPause','application','project_id','name','agentUnpause','VOICEMAIL','DIAL','condition','no\x20sms\x20account\x20found','AWS_LEX_%s','getUserById','Enter\x20in\x20GOTO\x20(%s)\x20block','phone','variable\x20%s\x20set','PLAYBACK','includes','agi://%s/square,\x22%s\x22,\x22%s\x22','render','Trying\x20SestekNDA:\x20%s','isConfigured','callback_priority','XMCS-QUEUE','Enter\x20in\x20LOGOUT\x20(%s)\x20block','answer','streamFile','retry','queue','end','no\x20user\x20selected','split','Trying\x20DialogflowV2:\x20%s','getSound','Enter\x20in\x20SET\x20(%s)\x20block','no\x20odbc\x20database\x20found','getPauseById','./scripts','extension','../../config/environment','en-US','username','clone','no\x20mail\x20account\x20configured','logout','awsPolly','no\x20operation\x20configured','inspect','args','add','timeout','Enter\x20in\x20SYSTEM\x20(%s)\x20block','EVAL\x20CONDITION\x20%s\x20%s','QUEUE','wav','/var/opt/motion2/server/files','toUpperCase','Enter\x20in\x20DATABASE\x20(%s)\x20block','getSquareProject','statusCode','odbc','tildeASR','beep','getSmsAccount','sendMailMessage','account_id','getUser','arg_1','sendMail\x20message','ndassistant_url','no\x20variable\x20selected','no\x20interval\x20configured','generate','minutes','exec','continueAt','RECOG_INSTANCE()','LUMENVOX_ASR_INSTANCE','sestekNDA','math\x20%s','failure','mrcprecog','Sestek\x20NDA\x20%s\x20file\x20created','An\x20incorrect\x20formatted\x20json\x20has\x20been\x20passed\x20to\x20the\x20function','Trying\x20Google\x20TTS\x20%s','moment','Mail\x20message\x20added\x20to\x20outgoing\x20process','no\x20variable\x20selected\x20for\x20the\x20response','mailRpc','dialogflow','sayphonetic','DIALOGFLOW_%s','callback','hangup','TILDE_ASR_%s','Enter\x20in\x20PAUSE\x20(%s)\x20block','no\x20variable\x20selected\x20for\x20the\x20result','saynumber','isNil','500\x20-\x20Internal\x20Server\x20Error','rawBody','audiofile','no\x20queue\x20found','join','isString','headers','agicommand','response','RECOG_INPUT()','ODBC\x20connection\x20successfully','Executed\x20command\x20%s','system','Enter\x20in\x20LUMENVOXASR\x20(%s)\x20block','amazonlex','operation','substr','googleASR','no\x20list\x20selected','start','random','out','Answer','project\x20in\x20subproject\x20must\x20be\x20different\x20from\x20the\x20called\x20project','no\x20file\x20audio\x20found','MRCP_RECOG_CONFIDENCE','Enter\x20in\x20ISPEECHTTS\x20(%s)\x20block','variable\x20%s[key]\x20set','replaceAll','file','digits','Google\x20Cloud\x20TTS\x20is\x20unreachable','service','ispeech_tts_language','Trying\x20SendSMS\x20with\x20account\x20%s','Dialogflow\x20Result\x20%s','apiKey','save_name','host','Enter\x20in\x20END\x20(%s)\x20block','providerResponse','sh\x20command:\x20%s\x20result\x20on\x20variable:\x20%s','Enter\x20in\x20UNPAUSE\x20(%s)\x20block','getVariableById','Amazon\x20Lex\x20Result\x20%s','menu','isArray','googleDialogflowV2','Enter\x20in\x20SAYPHONETIC\x20(%s)\x20block','gotoif','Dialogflow\x20is\x20unreachable','Enter\x20in\x20SAYNUMBER\x20(%s)\x20block','auth','unlink','google_tts_language','languageCode','LUMENVOX_ASR_CONFIDENCE','googleTTS','private_key','Intervals','getData','trunk_name','lodash','aws_secret_access_key','The\x20\x22%s\x22\x20variable\x20value\x20is:\x20%s','test','getVoiceQueueById','exports','tilde\x20%s\x20file\x20created','Enter\x20in\x20DIAL\x20(%s)\x20block','SESTEK_ASR_TRANSCRIPT','MRCPRecog','FIND\x20AGENT\x20%s\x20BY\x20%s','custom_app','set','parse','CALLBACK\x20added\x20phone:\x20%s\x20on\x20list:\x20%s\x20at\x20%s','SESTEK_ASR_INSTANCE','catch','getTrunkById','IFTIME\x20%s\x20%s','Error\x20closing\x20connection\x20to\x20odbc\x20%s','Enter\x20in\x20FINALLY\x20(%s)\x20block','yes','LUMENVOX_ASR_TRANSCRIPT','prototype','An\x20incorrect\x20formatted\x20json\x20headers\x20has\x20been\x20passed\x20to\x20the\x20function','getIntervalById','debug','Enter\x20in\x20SUBPROJECT\x20(%s)\x20block','Google\x20Cloud\x20TTS\x20%s\x20file\x20created','POST','ispeechTTS','context','speed','appsecret','toString','subject','MRCPSynth','createSquareMessage','NOBEEP','result','mrcpsynth','gotoc','createSquareRecording','speech','rpc','statusMessage','IspeechASR\x20Result\x20%s','setVariable','Enter\x20in\x20SESTEKASR\x20(%s)\x20block','Enter\x20in\x20SESTEKTTS\x20(%s)\x20block','label','LOCAL','trim','Enter\x20in\x20SENDMAIL\x20(%s)\x20block','no\x20user\x20found','lastName','mindigit','getTrunk','intKey','dialogflowV2_project_id','createSquareDetailsReport','SIP/%s','Enter\x20in\x20GOAL\x20(%s)\x20block','google_cloud_tts','Trying\x20Amazon\x20Lex:\x20%s','length','error','SESTEK_ASR_CONFIDENCE','trunk_id','google_asr_language','extra','aws_polly_voice','agentLogin','Executed\x20command\x20MRCPSynth\x20%s','isPlainObject','sesteknda','IntervalId','undefined','An\x20incorrect\x20formatted\x20json\x20body\x20has\x20been\x20passed\x20to\x20the\x20function','Trying\x20ispeech\x20TTS\x20%s','voicemail','sestekasr','dnid','output','key','sms_account_id','Skipped\x20Answer','Amazon\x20Lex\x20ready\x20for\x20fulfillment','%s[%s]','mailbox','sestektts','Enter\x20in\x20Google\x20Cloud\x20TTS\x20(%s)\x20block','vswitch','util','aws_text_type','computedVariables','maxRetry','no\x20grammar\x20configured','aws_lex_region','Enter\x20in\x20CUSTOM\x20APP\x20(%s)\x20block','pass','options','AGI','%s_%s','Enter\x20in\x20SENDSMS\x20(%s)\x20block','DialogflowV2\x20Result\x20%s','noop','goalname','body','message','no\x20variable\x20found','Trying\x20Dialogflow:\x20%s','Enter\x20in\x20GETDIGITS\x20(%s)\x20block','../../config/logger','tts','Enter\x20in\x20HANGUP\x20(%s)\x20block','math','%s_STATUS_MESSAGE','clear','google\x20%s\x20file\x20created','callerid','ispeech\x20%s\x20file\x20created','shellCommand','replaceObjectAllVariables','%s/recordings/%s','Amazon\x20Lex\x20is\x20unreachable','no\x20username\x20configured','no\x20valid\x20credentials\x20configured','scheduledAt','bcc','channel','no\x20file\x20audio\x20selected','%s.%s','getdigits','uniqueid','template_id','appid','model','AGENT\x20%s\x20NOT\x20FOUND\x20BY','recordFile','ISPEECH_ASR_%s','getSoundById','awsLex','%s/sounds/converted/%s','Enter\x20in\x20CALLBACK\x20(%s)\x20block','Enter\x20in\x20SAYDIGITS\x20(%s)\x20block','no\x20database\x20selected','Response:','query','priority','rawHeaders','no\x20client_email\x20configured','ispeech_asr_language','Executed\x20command\x20%s\x20%s','toLowerCase','aws_access_key_id','agentLogout','escape_digits','playback','ispeech\x20TTS\x20is\x20unreachable','dialogflowV2_language','Enter\x20in\x20START\x20(%s)\x20block','Enter\x20in\x20MENU\x20(%s)\x20block','randomstring','shelljs','saveRestApiResult','getMailAccountById','success','Enter\x20in\x20EXTERNAL\x20DIAL\x20(%s)\x20block','gotoiftime','Enter\x20in\x20DIALOGFLOW\x20V2\x20(%s)\x20block','digit','unpause','dialogflowV2','Enter\x20in\x20ANSWER\x20(%s)\x20block'];(function(_0x212946,_0xab7717){const _0x1aef53=function(_0x41214b){while(--_0x41214b){_0x212946['push'](_0x212946['shift']());}};_0x1aef53(++_0xab7717);}(a1048_0xab77,0x197));const a1048_0x1aef=function(_0x212946,_0xab7717){_0x212946=_0x212946-0x0;let _0x1aef53=a1048_0xab77[_0x212946];return _0x1aef53;};const _0x4d5af2=a1048_0x1aef;'use strict';const fs=require('fs'),util=require(_0x4d5af2('0x1c1')),_=require(_0x4d5af2('0x164')),sh=require(_0x4d5af2('0x33')),odbc=require(_0x4d5af2('0xff')),rs=require(_0x4d5af2('0x32')),moment=require(_0x4d5af2('0x118')),Mustache=require(_0x4d5af2('0x67')),rp=require('request-promise-native'),logger=require(_0x4d5af2('0x0'))(_0x4d5af2('0x80')),config=require(_0x4d5af2('0xea')),scripts=require(_0x4d5af2('0xe8')),FILES_PATH=_0x4d5af2('0xfa'),recursiveMapAttributes=[_0x4d5af2('0x25'),_0x4d5af2('0x127')],verticesWithRetry=[_0x4d5af2('0x153'),_0x4d5af2('0x14'),_0x4d5af2('0xa7')],AGIVertices=function(_0x41214b,_0x1af6c0,_0x1a56ad){const _0x21a9fb=_0x4d5af2;this[_0x21a9fb('0x11')]=_0x41214b,this[_0x21a9fb('0x190')]=_0x1af6c0,this[_0x21a9fb('0x11b')]=_0x1a56ad;};AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x7c')]=function(_0x52e03c,_0x2285ab){const _0x4007ad=_0x4d5af2;this[_0x4007ad('0x190')][_0x4007ad('0x151')](_0x52e03c)[_0x4007ad('0x6f')](function(_0x35d05e){const _0x3d7b26=_0x4007ad;_0x2285ab(null,_0x35d05e?_0x35d05e[_0x3d7b26('0xc8')]:![]);})[_0x4007ad('0x174')](function(_0xb72d98){_0x2285ab(_0xb72d98);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x7f')]=function(_0x291420,_0x5af553){const _0x4bf528=_0x4d5af2;this[_0x4bf528('0x190')][_0x4bf528('0x168')](_0x291420)[_0x4bf528('0x6f')](function(_0x477adb){_0x5af553(null,_0x477adb?_0x477adb['name']:![]);})[_0x4bf528('0x174')](function(_0x41de6e){_0x5af553(_0x41de6e);});},AGIVertices['prototype']['getSquareProject']=function(_0x1b21bd,_0x2005da){const _0x24245e=_0x4d5af2;this[_0x24245e('0x190')][_0x24245e('0x9c')](_0x1b21bd)[_0x24245e('0x6f')](function(_0x5b2f43){const _0x56e620=_0x24245e;_0x2005da(null,_0x5b2f43?_0x5b2f43[_0x56e620('0xc8')]:![]);})[_0x24245e('0x174')](function(_0x4230c9){_0x2005da(_0x4230c9);});},AGIVertices['prototype']['getSquareOdbc']=function(_0x3c666f,_0x101be6){const _0x3ab6b5=_0x4d5af2;this['rpc']['getSquareOdbcById'](_0x3c666f)[_0x3ab6b5('0x6f')](function(_0x3916d1){_0x101be6(null,_0x3916d1?_0x3916d1['dsn']:![]);})[_0x3ab6b5('0x174')](function(_0x171f67){_0x101be6(_0x171f67);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x105')]=function(_0x4dea49,_0x4f433e){const _0x23e456=_0x4d5af2;this[_0x23e456('0x190')][_0x23e456('0xcf')](_0x4dea49)['then'](function(_0xade9a2){const _0x586a9b=_0x23e456;_0x4f433e(null,_0xade9a2?_0xade9a2[_0x586a9b('0xc8')]:![]);})[_0x23e456('0x174')](function(_0x4911ec){_0x4f433e(_0x4911ec);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x19d')]=function(_0x13a9c9,_0xba4ab5){const _0x3eb357=_0x4d5af2;this[_0x3eb357('0x190')][_0x3eb357('0x175')](_0x13a9c9)[_0x3eb357('0x6f')](function(_0x25664e){const _0x3dbfdd=_0x3eb357;_0xba4ab5(null,_0x25664e?_0x25664e[_0x3dbfdd('0xc8')]:![]);})[_0x3eb357('0x174')](function(_0x534307){_0xba4ab5(_0x534307);});},AGIVertices['prototype']['getSound']=function(_0x46909b,_0xbecbea){const _0x322f24=_0x4d5af2,_0x5dc45e=this;this[_0x322f24('0x190')][_0x322f24('0x1c')](_0x46909b)['then'](function(_0x57e0a9){const _0x3a005d=_0x322f24;_0xbecbea(null,_0x57e0a9?_0x5dc45e[_0x3a005d('0x59')](_0x57e0a9[_0x3a005d('0x14b')]):![]);})['catch'](function(_0x33c85){_0xbecbea(_0x33c85);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x8d')]=function(_0x1d8a11,_0x31d5ec){const _0x377503=_0x4d5af2;this['rpc'][_0x377503('0x35')](_0x1d8a11)[_0x377503('0x6f')](function(_0x318c1f){_0x31d5ec(null,_0x318c1f?_0x318c1f:![]);})[_0x377503('0x174')](function(_0x2f28d8){_0x31d5ec(_0x2f28d8);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x103')]=function(_0x37eb1e,_0x5b5637,_0x288d58){const _0x5292bb=_0x4d5af2;this['mailRpc'][_0x5292bb('0x103')](_0x37eb1e,_0x5b5637)[_0x5292bb('0x6f')](function(){_0x288d58(null);})[_0x5292bb('0x174')](function(_0x261614){_0x288d58(_0x261614);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x79')]=function(_0x1632a2,_0x1399ee){const _0x5a2336=_0x4d5af2;this['rpc'][_0x5a2336('0x17d')](_0x1632a2)[_0x5a2336('0x6f')](function(_0x2be2b0){const _0x52d5ea=_0x5a2336;_0x2be2b0?_0x2be2b0[_0x52d5ea('0x1b0')]?_0x1399ee(null,[_0x2be2b0['interval']]):_0x1399ee(null,_['map'](_0x2be2b0[_0x52d5ea('0x161')],'interval')):_0x1399ee(null,![]);})[_0x5a2336('0x174')](function(_0x281ea6){_0x1399ee(_0x281ea6);});},AGIVertices['prototype'][_0x4d5af2('0x59')]=function(_0x189889){const _0x204dfe=_0x4d5af2;return util[_0x204dfe('0x52')](_0x204dfe('0x1e'),FILES_PATH,_0x189889);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x9d')]=function(_0x1fdf25,_0x19ec6f,_0x15ef7d){odbc['open'](_0x1fdf25,function(_0x5932ca){const _0xa8bbdc=a1048_0x1aef;_0x5932ca?(logger['error']('Error\x20getting\x20ODBC\x20connection\x20%s',_0x5932ca),_0x15ef7d(_0x5932ca)):(logger['info'](_0xa8bbdc('0x130')),odbc[_0xa8bbdc('0x23')](_0x19ec6f,function(_0x81d49,_0x5ad3c4){const _0x1696ee=_0xa8bbdc;_0x81d49?(logger['info']('Error\x20executing\x20query\x20%s',_0x19ec6f),_0x15ef7d(_0x81d49)):(logger['info'](_0x1696ee('0xac'),_0x19ec6f),odbc[_0x1696ee('0xb8')](function(_0x441ade){const _0xad2e7a=_0x1696ee;_0x441ade&&logger[_0xad2e7a('0x1a6')](_0xad2e7a('0x177'),_0x441ade),_0x15ef7d(null,_0x5ad3c4);}));}));});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x102')]=function(_0x2426bd,_0x1bfd94){const _0x53e96c=_0x4d5af2;this[_0x53e96c('0x190')][_0x53e96c('0x84')](_0x2426bd)[_0x53e96c('0x6f')](function(_0x3bea56){_0x1bfd94(null,_0x3bea56?_0x3bea56:![]);})[_0x53e96c('0x174')](function(_0x1b4788){_0x1bfd94(_0x1b4788);});},AGIVertices['prototype']['createSmsMessage']=function(_0x1cd259,_0x2929e6){const _0x5162ef=_0x4d5af2;this[_0x5162ef('0x190')]['createSmsMessage'](_0x1cd259)[_0x5162ef('0x6f')](function(_0x38204e){_0x2929e6(null,_0x38204e);})[_0x5162ef('0x174')](function(_0x405579){_0x2929e6(_0x405579);});},AGIVertices['prototype']['createSquareDetailsReport']=function(_0x70ee8c,_0x3e10e2,_0x273a6e){const _0x565b14=_0x4d5af2;this[_0x565b14('0x190')][_0x565b14('0x1a0')]({'uniqueid':this['channel'][_0x565b14('0x15')],'node':_0x70ee8c[_0x565b14('0x196')],'application':_0x70ee8c[_0x565b14('0x12d')],'data':_0x3e10e2||null,'project_name':this[_0x565b14('0x11')][_0x565b14('0x106')],'callerid':this['channel'][_0x565b14('0x7')]})[_0x565b14('0x6f')](function(_0x3c8a41){_0x273a6e&&_0x273a6e(null,_0x3c8a41);})[_0x565b14('0x174')](function(_0x4aaa67){_0x273a6e&&_0x273a6e(_0x4aaa67);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x18e')]=function(_0x2c1f2b,_0x2fbae0,_0x1f93da,_0x2878d1){const _0x1ac6c0=_0x4d5af2;this[_0x1ac6c0('0x190')][_0x1ac6c0('0x18e')]({'uniqueid':this[_0x1ac6c0('0x11')][_0x1ac6c0('0x15')],'callerid':this[_0x1ac6c0('0x11')]['callerid'],'calleridname':this['channel'][_0x1ac6c0('0x60')],'context':this['channel'][_0x1ac6c0('0x183')],'extension':this[_0x1ac6c0('0x11')]['extension'],'priority':this[_0x1ac6c0('0x11')][_0x1ac6c0('0x24')],'accountcode':this[_0x1ac6c0('0x11')]['accountcode'],'dnid':this['channel'][_0x1ac6c0('0x1b6')],'projectName':this['channel']['arg_1'],'saveName':_0x2fbae0,'filename':_0x2c1f2b[_0x1ac6c0('0x143')]||_0x2fbae0,'savePath':_0x1f93da})[_0x1ac6c0('0x6f')](function(_0x3f6121){_0x2878d1(null,_0x3f6121);})[_0x1ac6c0('0x174')](function(_0x3714b2){_0x2878d1(_0x3714b2);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x189')]=function(_0x26433b,_0x1327ce,_0x53eaab,_0x33538b,_0x58cd97){const _0x25a41d=_0x4d5af2;this[_0x25a41d('0x190')][_0x25a41d('0x189')]({'uniqueid':this[_0x25a41d('0x11')][_0x25a41d('0x15')],'body':_0x26433b,'direction':_0x1327ce,'providerName':_0x53eaab,'providerResponse':_0x33538b})[_0x25a41d('0x6f')](function(_0xd82b62){_0x58cd97&&_0x58cd97(null,_0xd82b62);})[_0x25a41d('0x174')](function(_0x1445d3){_0x58cd97&&_0x58cd97(_0x1445d3);});},AGIVertices['prototype']['createCmContact']=function(_0x5f41d8,_0x1782d2){const _0x2276bf=_0x4d5af2;this[_0x2276bf('0x190')]['createCmContact']({'firstName':_[_0x2276bf('0x78')](_0x5f41d8[_0x2276bf('0xc8')])||_[_0x2276bf('0x125')](_0x5f41d8[_0x2276bf('0xc8')])?'callback_'+Math[_0x2276bf('0x13a')]():_0x5f41d8[_0x2276bf('0xc8')],'lastName':_[_0x2276bf('0x78')](_0x5f41d8[_0x2276bf('0x19b')])||_['isNil'](_0x5f41d8['lastName'])?null:_0x5f41d8[_0x2276bf('0x19b')],'phone':_0x5f41d8['phone'],'ListId':_0x5f41d8['list_id'],'scheduledat':_0x5f41d8[_0x2276bf('0xf')],'callbackUniqueid':this[_0x2276bf('0x11')][_0x2276bf('0x15')],'tags':_0x2276bf('0x11f'),'description':_0x2276bf('0x4c')+_0x5f41d8['scheduledAt'][_0x2276bf('0x186')](),'priority':_0x5f41d8[_0x2276bf('0xd9')]})[_0x2276bf('0x6f')](function(_0x156001){_0x1782d2(null,_0x156001);})[_0x2276bf('0x174')](function(_0xa18d8f){_0x1782d2(_0xa18d8f);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xc5')]=function(_0x915b22,_0x3010ad){const _0xfd0c6d=_0x4d5af2;this[_0xfd0c6d('0x190')][_0xfd0c6d('0xe7')](_0x915b22)[_0xfd0c6d('0x6f')](function(_0x302fcf){const _0x229631=_0xfd0c6d;_0x3010ad(null,_0x302fcf?_0x302fcf[_0x229631('0xc8')]:![]);})[_0xfd0c6d('0x174')](function(_0x55d4e2){_0x3010ad(_0x55d4e2);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x88')]=function(_0x189818,_0x3d8848,_0x2a1f97){const _0x1ebb11=_0x4d5af2,_0xa66d44={'role':'agent'};_0xa66d44[_0x189818]=this[_0x1ebb11('0x11')]['callerid'],this[_0x1ebb11('0x190')][_0x1ebb11('0x88')](_0xa66d44,_0x3d8848,this[_0x1ebb11('0x11')][_0x1ebb11('0x15')])[_0x1ebb11('0x6f')](function(_0x1f2a98){_0x2a1f97(null,_['isNil'](_0x1f2a98)?![]:!![]);})['catch'](function(_0x421e1f){logger['error'](_0x421e1f),_0x2a1f97(null,![]);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xc9')]=function(_0x16bc41,_0x261c64){const _0x214bf2=_0x4d5af2,_0x40c6b3={'role':'agent'};_0x40c6b3[_0x16bc41]=this['channel'][_0x214bf2('0x7')],this[_0x214bf2('0x190')][_0x214bf2('0xc9')](_0x40c6b3)[_0x214bf2('0x6f')](function(_0x14b9fa){const _0xc6dbf2=_0x214bf2;_0x261c64(null,_[_0xc6dbf2('0x125')](_0x14b9fa)?![]:!![]);})[_0x214bf2('0x174')](function(_0xc0507a){logger['error'](_0xc0507a),_0x261c64(null,![]);});},AGIVertices['prototype'][_0x4d5af2('0x2b')]=function(_0x55c515,_0xcd6dc0){const _0x406324=_0x4d5af2,_0x515bcf={'role':_0x406324('0x94')};_0x515bcf[_0x55c515]=this[_0x406324('0x11')][_0x406324('0x7')],this[_0x406324('0x190')][_0x406324('0x2b')](_0x515bcf)[_0x406324('0x6f')](function(_0xd5f1ab){const _0x599229=_0x406324;_0xcd6dc0(null,_[_0x599229('0x125')](_0xd5f1ab)?![]:!![]);})['catch'](function(_0x3ae467){logger['error'](_0x3ae467),_0xcd6dc0(null,![]);});},AGIVertices[_0x4d5af2('0x17b')]['agentLogin']=function(_0x14d3a0,_0x530109){const _0x2ffc04=_0x4d5af2,_0xf0b95={'role':_0x2ffc04('0x94')};_0xf0b95[_0x14d3a0]=this['channel'][_0x2ffc04('0x7')];const _0x1ac15b=_0x14d3a0!='internal'?util[_0x2ffc04('0x52')](_0x2ffc04('0x46'),_0x2ffc04('0x197'),this[_0x2ffc04('0x11')][_0x2ffc04('0x7')]):undefined;this['rpc'][_0x2ffc04('0x1ac')](_0xf0b95,_0x1ac15b)[_0x2ffc04('0x6f')](function(_0x286a85){_0x530109(null,_['isNil'](_0x286a85)?![]:!![]);})[_0x2ffc04('0x174')](function(_0xbe1de5){const _0x3a1f5a=_0x2ffc04;logger[_0x3a1f5a('0x1a6')](_0xbe1de5),_0x530109(null,![]);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x9')]=function(_0x52ff2b,_0x2f6a71){const _0x51bc82=_0x4d5af2;sh[_0x51bc82('0x10d')](_[_0x51bc82('0x198')](_0x52ff2b),function(_0x441418,_0xdebf9b){const _0x3d700c=_0xdebf9b['replace'](/(\r\n|\n|\r)/gm,'');_0x2f6a71(null,_0x3d700c);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x3e')]=function(_0x52668e,_0x170d1c){const _0x4cd41f=_0x4d5af2;scripts['googleCloudTTS'](_0x52668e[_0x4cd41f('0x14a')],_0x52668e['google_cloud_tts_text_type']||_0x4cd41f('0x4f'),_0x52668e[_0x4cd41f('0x4f')],_0x52668e[_0x4cd41f('0x15d')]||_0x4cd41f('0xeb'),_0x52668e['ssmlGender']||_0x4cd41f('0x4a'),_0x52668e['audioEncoding']||'MP3')['then'](function(_0x4fd55e){_0x170d1c(null,_0x4fd55e);})[_0x4cd41f('0x174')](function(_0x2baad8){_0x170d1c(_0x2baad8);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x15f')]=function(_0x319435,_0x28ea60){const _0x119566=_0x4d5af2;scripts[_0x119566('0x15f')](_0x319435[_0x119566('0x4f')],_0x319435[_0x119566('0x15c')]||'en',0x1)[_0x119566('0x6f')](function(_0x492c4b){_0x28ea60(null,_0x492c4b);})[_0x119566('0x174')](function(_0x2cfcce){_0x28ea60(_0x2cfcce);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x48')]=function(_0x283741,_0x1d1a87){const _0x425607=_0x4d5af2,_0x42fe85={'uri':_0x283741[_0x425607('0xc2')],'method':_0x283741[_0x425607('0xa0')],'json':!![],'resolveWithFullResponse':!![],'timeout':typeof parseInt(_0x283741[_0x425607('0xf5')])===_0x425607('0x69')&&parseInt(_0x283741['timeout'])>=0x1?parseInt(_0x283741[_0x425607('0xf5')])*0x3e8:0x5*0x3e8};if(_[_0x425607('0xd4')]([_0x425607('0x181'),_0x425607('0x9f')],_0x42fe85[_0x425607('0xa0')][_0x425607('0xfb')]()))try{_0x42fe85[_0x425607('0x1d0')]=_0x283741[_0x425607('0x127')]?JSON['parse'](_0x283741[_0x425607('0x127')]):{};}catch(_0x4d5c21){logger[_0x425607('0x1a6')](_0x425607('0x1b2'),_0x4d5c21);}try{_0x42fe85[_0x425607('0x12c')]=_0x283741[_0x425607('0x25')]?JSON['parse'](_0x283741[_0x425607('0x25')]):{};}catch(_0x1c3778){logger[_0x425607('0x1a6')](_0x425607('0x17c'),_0x1c3778);}if(_0x283741[_0x425607('0x1c3')])try{const _0x26a683=require(_0x283741[_0x425607('0x1c3')])['sync'](this,_0x42fe85);_0x42fe85[_0x425607('0x8f')]=Mustache[_0x425607('0xd6')](_0x283741[_0x425607('0xc2')],_0x26a683,{},['$$','$$']),_0x42fe85[_0x425607('0x12c')]&&(_0x42fe85[_0x425607('0x12c')]=JSON[_0x425607('0x171')](Mustache['render'](JSON[_0x425607('0xbb')](_0x42fe85[_0x425607('0x12c')]),_0x26a683,{},['$$','$$']))),_0x42fe85[_0x425607('0x1d0')]&&(_0x42fe85['body']=JSON[_0x425607('0x171')](Mustache['render'](JSON['stringify'](_0x42fe85[_0x425607('0x1d0')]),_0x26a683,{},['$$','$$'])));}catch(_0x4c31eb){logger['error'](_0x425607('0x116'),_0x4c31eb);}rp(_0x42fe85)[_0x425607('0x6f')](function(_0x12fae2){const _0x2c95aa=_0x425607,_0x2e1ac2={'statusCode':_0x12fae2[_0x2c95aa('0xfe')]||0xc8,'statusMessage':_0x12fae2[_0x2c95aa('0x191')]||'OK','headers':_0x12fae2[_0x2c95aa('0x12c')]||{},'body':_0x12fae2[_0x2c95aa('0x1d0')]||{}};_0x1d1a87(null,_0x2e1ac2);})[_0x425607('0x174')](function(_0x3e7503){const _0x369751=_0x425607,_0x2716bd={'statusCode':_0x3e7503['statusCode']||0x1f4,'statusMessage':_0x3e7503[_0x369751('0x1d1')]||_0x369751('0x126'),'headers':_0x3e7503[_0x369751('0x1c9')][_0x369751('0x12c')]||{},'body':_0x3e7503[_0x369751('0x1c9')][_0x369751('0x1d0')]||{}};_0x1d1a87(null,_0x2716bd);});},AGIVertices[_0x4d5af2('0x17b')]['googleDialogflow']=function(_0x2f09e0,_0x37483c){const _0x2da728=_0x4d5af2;scripts[_0x2da728('0x41')](this[_0x2da728('0x11')]['uniqueid'],_0x2f09e0[_0x2da728('0x1b8')],_0x2f09e0[_0x2da728('0x4f')],_0x2f09e0['dialogflow_language']||'en')[_0x2da728('0x6f')](function(_0x39f0fa){_0x37483c(null,_0x39f0fa);})['catch'](function(_0x2b5475){_0x37483c(_0x2b5475);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x155')]=function(_0x532ae7,_0x5695a7){const _0x11ceb2=_0x4d5af2;scripts[_0x11ceb2('0x155')](this['channel']['uniqueid'],_0x532ae7['dialogflowV2_project_id'],_0x532ae7[_0x11ceb2('0xaa')],_0x532ae7[_0x11ceb2('0x160')],_0x532ae7[_0x11ceb2('0x4f')],_0x532ae7['dialogflowV2_language']||'en')[_0x11ceb2('0x6f')](function(_0x24fff9){_0x5695a7(null,_0x24fff9);})[_0x11ceb2('0x174')](function(_0x17116c){_0x5695a7(_0x17116c);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x111')]=function(_0x26d015,_0x420316){const _0x33230a=_0x4d5af2;scripts['sestekNDA'](this[_0x33230a('0x11')],_0x26d015)[_0x33230a('0x6f')](function(_0x10de5c){_0x420316(null,_0x10de5c);})[_0x33230a('0x174')](function(_0x57d5e6){_0x420316(_0x57d5e6);});},AGIVertices[_0x4d5af2('0x17b')]['ispeechTTS']=function(_0x139927,_0x5d7f9c){const _0x5848d0=_0x4d5af2;scripts['ispeechTTS'](_0x139927[_0x5848d0('0x1b8')],_0x139927[_0x5848d0('0x4f')],_0x139927[_0x5848d0('0x147')]||'en-US',_0x139927[_0x5848d0('0x184')])[_0x5848d0('0x6f')](function(_0x2ae508){_0x5d7f9c(null,_0x2ae508);})[_0x5848d0('0x174')](function(_0x3b367c){_0x5d7f9c(_0x3b367c);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xc3')]=function(_0xc5e365,_0x499623,_0x147b39){const _0x3155b5=_0x4d5af2;scripts[_0x3155b5('0xc3')](_0x499623,_0xc5e365['key'],_0xc5e365[_0x3155b5('0x27')]||_0x3155b5('0xeb'),this[_0x3155b5('0xd8')](_0xc5e365[_0x3155b5('0x18')])?_0xc5e365[_0x3155b5('0x18')]:undefined)[_0x3155b5('0x6f')](function(_0x1ba611){_0x147b39(null,_0x1ba611);})[_0x3155b5('0x174')](function(_0x4b77b1){_0x147b39(_0x4b77b1);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xf0')]=function(_0x1517e2,_0x318070){const _0x284447=_0x4d5af2;scripts[_0x284447('0xf0')](_0x1517e2[_0x284447('0x2a')],_0x1517e2[_0x284447('0x165')],_0x1517e2['aws_polly_region'],_0x1517e2[_0x284447('0x1ab')]||'Amy',_0x1517e2[_0x284447('0x4f')],_0x1517e2[_0x284447('0x1c2')]||_0x284447('0x4f'))[_0x284447('0x6f')](function(_0x527896){_0x318070(null,_0x527896);})[_0x284447('0x174')](function(_0x2d6f43){_0x318070(_0x2d6f43);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x1d')]=function(_0x67ac7e,_0x3c97a7){const _0x3e7fd9=_0x4d5af2;scripts['awsLex'](this[_0x3e7fd9('0x11')][_0x3e7fd9('0x15')],_0x67ac7e[_0x3e7fd9('0x2a')],_0x67ac7e['aws_secret_access_key'],_0x67ac7e[_0x3e7fd9('0x1c6')],_0x67ac7e[_0x3e7fd9('0x4f')],_0x67ac7e['aws_bot_name'])['then'](function(_0x2c3c69){_0x3c97a7(null,_0x2c3c69);})[_0x3e7fd9('0x174')](function(_0x170d8e){_0x3c97a7(_0x170d8e);});},AGIVertices['prototype'][_0x4d5af2('0x137')]=function(_0x5db1dc,_0x33053c,_0x504f86){const _0x3beea7=_0x4d5af2;scripts[_0x3beea7('0x137')](_0x33053c,_0x5db1dc[_0x3beea7('0x1b8')],_0x5db1dc[_0x3beea7('0x1a9')]||_0x3beea7('0xeb'))['then'](function(_0x153524){_0x504f86(null,_0x153524);})[_0x3beea7('0x174')](function(_0x2d1708){_0x504f86(_0x2d1708);});},AGIVertices['prototype'][_0x4d5af2('0x100')]=function(_0x575071,_0x3c6e1f,_0x57897c){const _0xee1acd=_0x4d5af2;scripts[_0xee1acd('0x100')](_0x3c6e1f,_0x575071[_0xee1acd('0x17')],_0x575071[_0xee1acd('0x185')],_0x575071['uri'])[_0xee1acd('0x6f')](function(_0x4538ea){_0x57897c(null,_0x4538ea);})[_0xee1acd('0x174')](function(_0x4b35ea){_0x57897c(_0x4b35ea);});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x5')]=function(_0xc88f70){const _0x2d2f08=_0x4d5af2,_0xf73313=_[_0x2d2f08('0xd4')](verticesWithRetry,_0xc88f70['agicommand'])?_0xc88f70:_[_0x2d2f08('0xed')](_0xc88f70);for(const _0x270eb3 in _0xf73313){typeof _0xf73313[_0x270eb3]!==_0x2d2f08('0x1b1')&&(_0xf73313[_0x270eb3]&&_[_0x2d2f08('0x12b')](_0xf73313[_0x270eb3])&&(_[_0x2d2f08('0xd4')](recursiveMapAttributes,_0x270eb3)?_0xf73313[_0x270eb3]=this[_0x2d2f08('0xa')](_0xf73313[_0x270eb3]):_0xf73313[_0x270eb3]=this['replaceAllVariables'](_0xf73313[_0x270eb3])));}return _0xf73313;},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xbe')]=function(_0x3e3d85){const _0xe92326=_0x4d5af2;for(const _0x2fd029 in _0x3e3d85){if(typeof _0x3e3d85[_0x2fd029]!==_0xe92326('0x1b1')){if(_['isPlainObject'](_0x3e3d85[_0x2fd029]))this[_0xe92326('0xbe')](_0x3e3d85[_0x2fd029]);else{if(_[_0xe92326('0x154')](_0x3e3d85[_0x2fd029]))for(let _0x1bd914=0x0;_0x1bd914<_0x3e3d85[_0x2fd029][_0xe92326('0x1a5')];_0x1bd914++){this[_0xe92326('0xbe')](_0x3e3d85[_0x2fd029][_0x1bd914]);}else _[_0xe92326('0x12b')](_0x3e3d85[_0x2fd029])&&(_0x3e3d85[_0x2fd029]=this[_0xe92326('0x9b')](_0x3e3d85[_0x2fd029]));}}}},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x34')]=function(_0x5f0aab,_0x41eb69){const _0x150dbc=_0x4d5af2;for(const _0x308109 in _0x5f0aab){if(typeof _0x5f0aab[_0x308109]!==_0x150dbc('0x1b1')){if(_[_0x150dbc('0x1ae')](_0x5f0aab[_0x308109]))!_[_0x150dbc('0x78')](_0x5f0aab[_0x308109])&&this[_0x150dbc('0x34')](_0x5f0aab[_0x308109],util[_0x150dbc('0x52')](_0x150dbc('0x13'),_0x41eb69,_0x308109));else{if(_['isArray'](_0x5f0aab[_0x308109]))for(let _0x46e332=0x0;_0x46e332<_0x5f0aab[_0x308109][_0x150dbc('0x1a5')];_0x46e332++){this[_0x150dbc('0x34')](_0x5f0aab[_0x308109][_0x46e332],util['format']('%s.%s',_0x41eb69,_0x308109+'['+_0x46e332+']'));}else!_[_0x150dbc('0x125')](_0x5f0aab[_0x308109])&&this[_0x150dbc('0x11')]['setVariable'](util[_0x150dbc('0x52')](_0x150dbc('0x13'),_0x41eb69,_0x308109),_0x5f0aab[_0x308109]);}}}},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xa')]=function(_0x277fea){const _0x1a6d14=_0x4d5af2;try{const _0x3e72b6=JSON[_0x1a6d14('0x171')](_0x277fea);return this[_0x1a6d14('0xbe')](_0x3e72b6),JSON[_0x1a6d14('0xbb')](_0x3e72b6);}catch(_0x213c03){return this['replaceAllVariables'](_0x277fea);}},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x9b')]=function(_0x189f6c){const _0x4e9b80=_0x4d5af2,_0x7e8ea6=_0x189f6c[_0x4e9b80('0xe2')]('{');for(let _0x2ca04c=0x1;_0x2ca04c<_0x7e8ea6[_0x4e9b80('0x1a5')];_0x2ca04c+=0x1){const _0x3f1770=_0x7e8ea6[_0x2ca04c][_0x4e9b80('0xe2')]('}');_0x3f1770[_0x4e9b80('0x1a5')]>0x1&&(_0x189f6c=_0x189f6c[_0x4e9b80('0x142')]('{'+_0x3f1770[0x0]+'}',this[_0x4e9b80('0x11')][_0x4e9b80('0x7c')](_0x3f1770[0x0])[_0x4e9b80('0x1aa')]||_0x3f1770[0x0]));}if(_0x7e8ea6[_0x4e9b80('0x1a5')]===0x1)return _0x189f6c[_0x4e9b80('0x186')]();return this[_0x4e9b80('0x9b')](_0x189f6c);},AGIVertices[_0x4d5af2('0x17b')]['getAndSetVariable']=function(_0x392cac,_0xd3081a){const _0x189446=_0x4d5af2,_0x35c09c=this[_0x189446('0x11')][_0x189446('0x7c')](_0x392cac);if(_0x35c09c[_0x189446('0x18b')]===-0x1)return _0x35c09c;return logger[_0x189446('0x86')](util[_0x189446('0x52')](_0x189446('0x166'),_0xd3081a,_0x35c09c[_0x189446('0x1aa')])),this[_0x189446('0x11')][_0x189446('0x193')](_0xd3081a,_0x35c09c[_0x189446('0x1aa')]);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xd8')]=function(_0x296d93){return _0x296d93&&_0x296d93!=='0'&&_0x296d93!=='-1'&&_0x296d93!=='';},AGIVertices['prototype'][_0x4d5af2('0x1c4')]=function(_0x5d18d3){const _0x9b2a0=_0x4d5af2;return this['createSquareDetailsReport'][_0x9b2a0('0x57')](this,_0x5d18d3,'-'),_0x5d18d3[_0x9b2a0('0xde')]=_0x5d18d3[_0x9b2a0('0x1c4')],{'code':0xc8,'result':'-'};},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x18c')]=function(_0x21da6c){const _0x42ccf7=_0x4d5af2;logger['info'](util[_0x42ccf7('0x52')](_0x42ccf7('0x51'),_0x21da6c[_0x42ccf7('0x196')]));if(!this['isConfigured'](_0x21da6c[_0x42ccf7('0x4f')]))return this[_0x42ccf7('0x11')][_0x42ccf7('0x1ce')](_0x42ccf7('0x7a'));let _0x5aa856='\x22'+_0x21da6c[_0x42ccf7('0x4f')]+'\x22';this[_0x42ccf7('0xd8')](_0x21da6c[_0x42ccf7('0x1c9')])&&(_0x5aa856+=','+_0x21da6c['options']);const _0x43b6d3=this[_0x42ccf7('0x11')][_0x42ccf7('0x10d')](_0x42ccf7('0x188'),_0x5aa856);if(_0x43b6d3[_0x42ccf7('0x18b')]===-0x1)return _0x43b6d3;return this[_0x42ccf7('0x11')][_0x42ccf7('0x1ce')](util[_0x42ccf7('0x52')](_0x42ccf7('0x1ad'),_0x5aa856));},AGIVertices['prototype'][_0x4d5af2('0x114')]=function(_0x752a84){const _0x5988dc=_0x4d5af2;logger[_0x5988dc('0x86')](util[_0x5988dc('0x52')]('Enter\x20in\x20MRCPRecog\x20(%s)\x20block',_0x752a84['label']));if(!this[_0x5988dc('0xd8')](_0x752a84[_0x5988dc('0xad')]))return this[_0x5988dc('0x11')]['noop'](_0x5988dc('0x1c5'));let _0x386715=_0x752a84['grammar'];this['isConfigured'](_0x752a84[_0x5988dc('0x1c9')])&&(_0x386715+=','+_0x752a84[_0x5988dc('0x1c9')]);const _0x23600b=this[_0x5988dc('0x11')][_0x5988dc('0x10d')]('MRCPRecog',_0x386715);if(_0x23600b[_0x5988dc('0x18b')]===-0x1)return _0x23600b;const _0x16504e=this[_0x5988dc('0x96')](_0x5988dc('0x8b'),_0x5988dc('0x13f'));if(_0x16504e[_0x5988dc('0x18b')]===-0x1)return _0x16504e;const _0x4274e4=this['getAndSetVariable'](_0x5988dc('0x12f'),'MRCP_RECOG_TRANSCRIPT');if(_0x4274e4[_0x5988dc('0x18b')]===-0x1)return _0x4274e4;const _0x4bb0ea=this[_0x5988dc('0x96')](_0x5988dc('0x10f'),'MRCP_RECOG_INSTANCE');if(_0x4bb0ea[_0x5988dc('0x18b')]===-0x1)return _0x4bb0ea;return this[_0x5988dc('0x11')][_0x5988dc('0x1ce')](util[_0x5988dc('0x52')](_0x5988dc('0xc4'),_0x386715));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x80')]=function(_0x3c52ac){const _0x3fd66f=_0x4d5af2;return logger[_0x3fd66f('0x86')](util[_0x3fd66f('0x52')](_0x3fd66f('0x5b'),_0x3c52ac[_0x3fd66f('0x196')])),this['channel'][_0x3fd66f('0x80')]([_0x3c52ac[_0x3fd66f('0x9a')],_0x3c52ac[_0x3fd66f('0xf3')]]);},AGIVertices['prototype'][_0x4d5af2('0xdc')]=function(_0x4d7d98){const _0x43ffc1=_0x4d5af2;logger[_0x43ffc1('0x86')](util[_0x43ffc1('0x52')](_0x43ffc1('0x3d'),_0x4d7d98['label']));if(this[_0x43ffc1('0xd8')](_0x4d7d98[_0x43ffc1('0xf5')])){logger[_0x43ffc1('0x86')](util[_0x43ffc1('0x52')](_0x43ffc1('0xb6'),_0x4d7d98[_0x43ffc1('0xf5')]));const _0x10b0ae=this[_0x43ffc1('0x11')]['wait'](_0x4d7d98[_0x43ffc1('0xf5')]);if(_0x10b0ae[_0x43ffc1('0x18b')]===-0x1)return _0x10b0ae;}return this['channel'][_0x43ffc1('0xdc')]();},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x11f')]=function(_0x25abba){const _0x47f91e=_0x4d5af2;logger[_0x47f91e('0x86')](util[_0x47f91e('0x52')](_0x47f91e('0x1f'),_0x25abba[_0x47f91e('0x196')]));if(!this[_0x47f91e('0xd8')](_0x25abba['list_id']))return this[_0x47f91e('0x11')][_0x47f91e('0x1a6')](_0x25abba,_0x47f91e('0x138'));return _0x25abba[_0x47f91e('0xf')]=moment(),this['isConfigured'](_0x25abba[_0x47f91e('0x55')])&&(_0x25abba[_0x47f91e('0xf')]=moment()[_0x47f91e('0xf4')](_0x25abba['delay'],_0x47f91e('0x10c'))),!this['isConfigured'](_0x25abba['callback_priority'])&&(_0x25abba[_0x47f91e('0xd9')]=0x2),this[_0x47f91e('0xb2')][_0x47f91e('0x57')](this,_0x25abba),this[_0x47f91e('0x11')][_0x47f91e('0x1ce')](util[_0x47f91e('0x52')](_0x47f91e('0x172'),_0x25abba[_0x47f91e('0xd1')],_0x25abba[_0x47f91e('0x62')],_0x25abba['scheduledAt']));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x16f')]=function(_0x45b0ac){const _0x236030=_0x4d5af2;logger['info'](util[_0x236030('0x52')](_0x236030('0x1c7'),_0x45b0ac[_0x236030('0x196')]));const _0x378aac=this['channel']['exec'](_0x45b0ac[_0x236030('0xc6')],_0x45b0ac['options']);if(_0x378aac['result']===-0x1)return _0x378aac;return this[_0x236030('0x11')][_0x236030('0x1ce')](util['format']('Executed\x20command\x20%s\x20%s',_0x45b0ac['application'],_0x45b0ac[_0x236030('0x1c9')]));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xc1')]=function(_0x23ba8a){const _0x3f7609=_0x4d5af2;logger[_0x3f7609('0x86')](util[_0x3f7609('0x52')]('Enter\x20in\x20LUMENVOXTTS\x20(%s)\x20block',_0x23ba8a[_0x3f7609('0x196')]));if(!this[_0x3f7609('0xd8')](_0x23ba8a[_0x3f7609('0x4f')]))return this[_0x3f7609('0x11')][_0x3f7609('0x1ce')]('no\x20text\x20configured');let _0x2dc05f='\x22'+_0x23ba8a['text']+'\x22';this[_0x3f7609('0xd8')](_0x23ba8a['options'])&&(_0x2dc05f+=','+_0x23ba8a['options']);const _0x53f1ec=this[_0x3f7609('0x11')][_0x3f7609('0x10d')](_0x3f7609('0x188'),_0x2dc05f);if(_0x53f1ec['result']===-0x1)return _0x53f1ec;return this[_0x3f7609('0x11')][_0x3f7609('0x1ce')](util['format']('Executed\x20command\x20MRCPSynth\x20%s',_0x2dc05f));},AGIVertices['prototype'][_0x4d5af2('0x1be')]=function(_0x324b12){const _0x2953de=_0x4d5af2;logger['info'](util['format'](_0x2953de('0x195'),_0x324b12[_0x2953de('0x196')]));if(!this[_0x2953de('0xd8')](_0x324b12[_0x2953de('0x4f')]))return this['channel'][_0x2953de('0x1ce')](_0x2953de('0x7a'));let _0xf2929='\x22'+_0x324b12[_0x2953de('0x4f')]+'\x22';this[_0x2953de('0xd8')](_0x324b12['options'])&&(_0xf2929+=','+_0x324b12[_0x2953de('0x1c9')]);const _0x2a90cd=this[_0x2953de('0x11')]['exec'](_0x2953de('0x188'),_0xf2929);if(_0x2a90cd[_0x2953de('0x18b')]===-0x1)return _0x2a90cd;return this[_0x2953de('0x11')][_0x2953de('0x1ce')](util['format'](_0x2953de('0x1ad'),_0xf2929));},AGIVertices[_0x4d5af2('0x17b')]['lumenvoxasr']=function(_0x1267f7){const _0x3d3cd8=_0x4d5af2;logger[_0x3d3cd8('0x86')](util[_0x3d3cd8('0x52')](_0x3d3cd8('0x133'),_0x1267f7[_0x3d3cd8('0x196')]));if(!this[_0x3d3cd8('0xd8')](_0x1267f7[_0x3d3cd8('0xad')]))return this[_0x3d3cd8('0x11')]['noop'](_0x3d3cd8('0x1c5'));let _0x4580df=_0x1267f7[_0x3d3cd8('0xad')];this[_0x3d3cd8('0xd8')](_0x1267f7[_0x3d3cd8('0x1c9')])&&(_0x4580df+=','+_0x1267f7['options']);const _0x47c817=this['channel'][_0x3d3cd8('0x10d')]('MRCPRecog',_0x4580df);if(_0x47c817[_0x3d3cd8('0x18b')]===-0x1)return _0x47c817;const _0x4a5ce7=this['getAndSetVariable'](_0x3d3cd8('0x8b'),_0x3d3cd8('0x15e'));if(_0x4a5ce7[_0x3d3cd8('0x18b')]===-0x1)return _0x4a5ce7;const _0x455dad=this[_0x3d3cd8('0x96')](_0x3d3cd8('0x12f'),_0x3d3cd8('0x17a'));if(_0x455dad[_0x3d3cd8('0x18b')]===-0x1)return _0x455dad;const _0x400d92=this['getAndSetVariable'](_0x3d3cd8('0x10f'),_0x3d3cd8('0x110'));if(_0x400d92[_0x3d3cd8('0x18b')]===-0x1)return _0x400d92;return this['channel'][_0x3d3cd8('0x1ce')](util['format'](_0x3d3cd8('0xc4'),_0x4580df));},AGIVertices['prototype'][_0x4d5af2('0x1b5')]=function(_0x2297b9){const _0x553e32=_0x4d5af2;logger[_0x553e32('0x86')](util[_0x553e32('0x52')](_0x553e32('0x194'),_0x2297b9[_0x553e32('0x196')]));if(!this[_0x553e32('0xd8')](_0x2297b9['grammar']))return this['channel'][_0x553e32('0x1ce')](_0x553e32('0x1c5'));let _0x504bf3=_0x2297b9[_0x553e32('0xad')];this[_0x553e32('0xd8')](_0x2297b9[_0x553e32('0x1c9')])&&(_0x504bf3+=','+_0x2297b9[_0x553e32('0x1c9')]);const _0x23f84e=this[_0x553e32('0x11')]['exec'](_0x553e32('0x16d'),_0x504bf3);if(_0x23f84e[_0x553e32('0x18b')]===-0x1)return _0x23f84e;const _0x31f038=this[_0x553e32('0x96')](_0x553e32('0x8b'),_0x553e32('0x1a7'));if(_0x31f038[_0x553e32('0x18b')]===-0x1)return _0x31f038;const _0x39f424=this['getAndSetVariable']('RECOG_INPUT()',_0x553e32('0x16c'));if(_0x39f424[_0x553e32('0x18b')]===-0x1)return _0x39f424;const _0xea8e4=this['getAndSetVariable']('RECOG_INSTANCE()',_0x553e32('0x173'));if(_0xea8e4['result']===-0x1)return _0xea8e4;return this[_0x553e32('0x11')][_0x553e32('0x1ce')](util[_0x553e32('0x52')](_0x553e32('0xc4'),_0x504bf3));},AGIVertices[_0x4d5af2('0x17b')]['database']=function(_0xdeab3d){const _0x5aefb2=_0x4d5af2;logger[_0x5aefb2('0x86')](util['format'](_0x5aefb2('0xfc'),_0xdeab3d[_0x5aefb2('0x196')]));if(!this[_0x5aefb2('0xd8')](_0xdeab3d[_0x5aefb2('0x5e')]))return this['channel']['error'](_0xdeab3d,_0x5aefb2('0x21'));const _0x6409c2=this['getSquareOdbc']['sync'](this,_0xdeab3d[_0x5aefb2('0x5e')]);if(!_0x6409c2)return this[_0x5aefb2('0x11')][_0x5aefb2('0x1a6')](_0xdeab3d,_0x5aefb2('0xe6'));if(!this['isConfigured'](_0xdeab3d[_0x5aefb2('0x23')]))return this['channel'][_0x5aefb2('0x1a6')](_0xdeab3d,'no\x20query\x20configured');const _0x2f1d78=_0xdeab3d[_0x5aefb2('0x23')][_0x5aefb2('0x9e')](/(\r\n|\n|\r)/gm,'\x20');this['channel'][_0x5aefb2('0x1ce')](util[_0x5aefb2('0x52')]('query:\x20%s',_0x2f1d78));const _0x19f7bf=this[_0x5aefb2('0x9d')][_0x5aefb2('0x57')](this,_0x6409c2,_0x2f1d78);this[_0x5aefb2('0x1a0')][_0x5aefb2('0x57')](this,_0xdeab3d,_0x2f1d78);if(!this[_0x5aefb2('0xd8')](_0xdeab3d[_0x5aefb2('0xa3')]))return this[_0x5aefb2('0x11')]['noop']('no\x20variable\x20selected\x20for\x20the\x20result');const _0x5e6d2d=this[_0x5aefb2('0x7c')][_0x5aefb2('0x57')](this,_0xdeab3d[_0x5aefb2('0xa3')]);if(!_0x5e6d2d)return this[_0x5aefb2('0x11')][_0x5aefb2('0x1a6')](_0xdeab3d,'no\x20variable\x20found');const _0x253d93=this;return _0x19f7bf['forEach'](function(_0x2d2644,_0x608f4a){const _0x26ea20=_0x5aefb2;Object[_0x26ea20('0x42')](_0x2d2644)[_0x26ea20('0xb3')](function(_0x13d6c0){const _0x2c56d3=_0x26ea20;_0x253d93[_0x2c56d3('0x11')][_0x2c56d3('0x193')](util[_0x2c56d3('0x52')](_0x2c56d3('0x95'),_0x5e6d2d,_0x608f4a,_0x13d6c0),_0x2d2644[_0x13d6c0]);});}),this[_0x5aefb2('0x11')][_0x5aefb2('0x193')](util[_0x5aefb2('0x52')](_0x5aefb2('0xb5'),_0x5e6d2d),_0x19f7bf[_0x5aefb2('0x1a5')]),this[_0x5aefb2('0x11')][_0x5aefb2('0x1ce')](util[_0x5aefb2('0x52')](_0x5aefb2('0xd2'),_0x5e6d2d));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xa2')]=function(_0x2acb0f){const _0x4e4cce=_0x4d5af2;logger[_0x4e4cce('0x17e')](util[_0x4e4cce('0x52')](_0x4e4cce('0x16b'),_0x2acb0f[_0x4e4cce('0x196')]));if(!this[_0x4e4cce('0xd8')](_0x2acb0f[_0x4e4cce('0x93')]))return this[_0x4e4cce('0x11')][_0x4e4cce('0x1a6')](_0x2acb0f,_0x4e4cce('0xe1'));const _0x245e7f=this[_0x4e4cce('0x105')]['sync'](this,_0x2acb0f[_0x4e4cce('0x93')]);if(!_0x245e7f)return this[_0x4e4cce('0x11')][_0x4e4cce('0x1a6')](_0x2acb0f,_0x4e4cce('0x19a'));const _0x4ee854=this[_0x4e4cce('0x11')][_0x4e4cce('0x10d')](_0x4e4cce('0xcb'),[util['format'](_0x4e4cce('0x1a1'),_0x245e7f),_0x2acb0f[_0x4e4cce('0xf5')],_0x2acb0f[_0x4e4cce('0x6c')],_0x2acb0f[_0x4e4cce('0xc2')]]);if(_0x4ee854[_0x4e4cce('0x18b')]===-0x1)return _0x4ee854;return this['channel'][_0x4e4cce('0x1ce')](util[_0x4e4cce('0x52')](_0x4e4cce('0x131'),_0x4e4cce('0xcb')));},AGIVertices['prototype'][_0x4d5af2('0x11c')]=function(_0x5c6571){const _0x21b35a=_0x4d5af2;logger['info'](util[_0x21b35a('0x52')]('Enter\x20in\x20DIALOGFLOW\x20(%s)\x20block',_0x5c6571[_0x21b35a('0x196')]));if(!this[_0x21b35a('0xd8')](_0x5c6571[_0x21b35a('0x1b8')]))return this['channel'][_0x21b35a('0x1ce')](_0x21b35a('0x98'));if(!this[_0x21b35a('0xd8')](_0x5c6571[_0x21b35a('0x4f')]))return this['channel'][_0x21b35a('0x1ce')]('no\x20text\x20configured');this['channel'][_0x21b35a('0x75')]=!![],this[_0x21b35a('0x1a0')](_0x5c6571),this[_0x21b35a('0x189')](_0x5c6571[_0x21b35a('0x4f')],'in','',''),this[_0x21b35a('0x11')]['noop'](util[_0x21b35a('0x52')](_0x21b35a('0x1d3'),_0x5c6571[_0x21b35a('0x4f')]));const _0x45ab88=this['googleDialogflow'][_0x21b35a('0x57')](this,_0x5c6571);if(_0x45ab88){for(const _0x3ceeb8 in _0x45ab88){typeof _0x45ab88[_0x3ceeb8]!==_0x21b35a('0x1b1')&&this[_0x21b35a('0x11')][_0x21b35a('0x193')](util[_0x21b35a('0x52')](_0x21b35a('0x11e'),_0x3ceeb8[_0x21b35a('0xfb')]()),_0x45ab88[_0x3ceeb8]);}return this[_0x21b35a('0x189')](_0x45ab88['speech'],_0x21b35a('0x13b'),_0x21b35a('0x11c'),''),this[_0x21b35a('0x11')][_0x21b35a('0x1ce')](util[_0x21b35a('0x52')](_0x21b35a('0x149'),_0x45ab88[_0x21b35a('0x18f')]));}return this['channel'][_0x21b35a('0x1a6')](_0x5c6571,_0x21b35a('0x158'));},AGIVertices[_0x4d5af2('0x17b')]['dialogflowV2']=function(_0x158641){const _0xedff44=_0x4d5af2;logger[_0xedff44('0x86')](util[_0xedff44('0x52')](_0xedff44('0x39'),_0x158641[_0xedff44('0x196')]));if(!this[_0xedff44('0xd8')](_0x158641[_0xedff44('0x19f')]))return this[_0xedff44('0x11')][_0xedff44('0x1ce')]('no\x20project_id\x20configured');if(!this['isConfigured'](_0x158641['client_email']))return this['channel'][_0xedff44('0x1ce')](_0xedff44('0x26'));if(!this[_0xedff44('0xd8')](_0x158641[_0xedff44('0x160')]))return this[_0xedff44('0x11')][_0xedff44('0x1ce')]('no\x20private_key\x20configured');if(!this[_0xedff44('0xd8')](_0x158641[_0xedff44('0x2f')]))return this[_0xedff44('0x11')][_0xedff44('0x1ce')](_0xedff44('0x91'));if(!this['isConfigured'](_0x158641[_0xedff44('0x4f')]))return this['channel'][_0xedff44('0x1ce')](_0xedff44('0x7a'));this[_0xedff44('0x11')]['bot']=!![],this[_0xedff44('0x1a0')](_0x158641),this[_0xedff44('0x189')](_0x158641[_0xedff44('0x4f')],'in','',''),this[_0xedff44('0x11')][_0xedff44('0x1ce')](util['format'](_0xedff44('0xe3'),_0x158641[_0xedff44('0x4f')]));const _0x202a6c=this[_0xedff44('0x155')]['sync'](this,_0x158641);if(_0x202a6c){for(const _0x4b2a3e in _0x202a6c){typeof _0x202a6c[_0x4b2a3e]!==_0xedff44('0x1b1')&&(_0x4b2a3e!==_0xedff44('0x14e')&&this['channel'][_0xedff44('0x193')](util[_0xedff44('0x52')]('DIALOGFLOW_%s',_0x4b2a3e['toUpperCase']()),_0x202a6c[_0x4b2a3e]));}return this[_0xedff44('0x189')](_0x202a6c[_0xedff44('0x18f')],_0xedff44('0x13b'),_0xedff44('0x3c'),_0x202a6c[_0xedff44('0x14e')]),this[_0xedff44('0x11')][_0xedff44('0x1ce')](util[_0xedff44('0x52')](_0xedff44('0x1cd'),_0x202a6c[_0xedff44('0x18f')]));}return this['channel'][_0xedff44('0x1a6')](_0x158641,'DialogflowV2\x20is\x20unreachable');},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x1af')]=function(_0x29384d){const _0x2f3415=_0x4d5af2;logger[_0x2f3415('0x86')](util[_0x2f3415('0x52')](_0x2f3415('0x50'),_0x29384d[_0x2f3415('0x196')]));if(!this[_0x2f3415('0xd8')](_0x29384d['ndauth_url']))return this['channel'][_0x2f3415('0x1ce')](_0x2f3415('0x7e'));if(!this[_0x2f3415('0xd8')](_0x29384d[_0x2f3415('0xec')]))return this[_0x2f3415('0x11')][_0x2f3415('0x1ce')](_0x2f3415('0xd'));if(!this[_0x2f3415('0xd8')](_0x29384d[_0x2f3415('0x6d')]))return this[_0x2f3415('0x11')][_0x2f3415('0x1ce')](_0x2f3415('0xab'));if(!this[_0x2f3415('0xd8')](_0x29384d[_0x2f3415('0x108')]))return this[_0x2f3415('0x11')][_0x2f3415('0x1ce')](_0x2f3415('0x7a'));this[_0x2f3415('0x11')][_0x2f3415('0x75')]=!![],this[_0x2f3415('0x1a0')](_0x29384d),this[_0x2f3415('0x189')](_0x29384d[_0x2f3415('0x4f')],'in','',''),this[_0x2f3415('0x11')][_0x2f3415('0x1ce')](util['format'](_0x2f3415('0xd7'),_0x29384d[_0x2f3415('0x4f')]));const _0x3bc3b0=this[_0x2f3415('0x111')][_0x2f3415('0x57')](this,_0x29384d);if(_0x3bc3b0){for(const _0x1cb77a in _0x3bc3b0){typeof _0x3bc3b0[_0x1cb77a]!==_0x2f3415('0x1b1')&&this[_0x2f3415('0x11')][_0x2f3415('0x193')](util['format']('SESTEK_NDA_%s',_0x1cb77a[_0x2f3415('0xfb')]()),_0x3bc3b0[_0x1cb77a]);}this['createSquareMessage'](_0x3bc3b0['speech'],_0x2f3415('0x13b'),_0x2f3415('0x1af'),'');if(_0x3bc3b0['audiofile']){this['channel']['noop'](util[_0x2f3415('0x52')](_0x2f3415('0x115'),_0x3bc3b0[_0x2f3415('0x128')]));const _0x2f83b0=this[_0x2f3415('0x11')][_0x2f3415('0xdd')](_0x3bc3b0[_0x2f3415('0x128')]);try{fs[_0x2f3415('0x15b')](_0x3bc3b0[_0x2f3415('0x128')]+_0x2f3415('0x7d'));}catch(_0x355826){logger[_0x2f3415('0x1a6')](_0x355826);}return _0x2f83b0;}else return this[_0x2f3415('0x11')][_0x2f3415('0x1ce')](util[_0x2f3415('0x52')](_0x2f3415('0x70'),_0x3bc3b0[_0x2f3415('0x18f')]));}return this[_0x2f3415('0x11')][_0x2f3415('0x1a6')](_0x29384d,'SestekNDA\x20is\x20unreachable');},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xe0')]=function(_0x55110b){const _0x1b9b48=_0x4d5af2;return logger[_0x1b9b48('0x86')](util[_0x1b9b48('0x52')](_0x1b9b48('0x14d'),_0x55110b['label'])),this[_0x1b9b48('0x11')][_0x1b9b48('0x1ce')](_0x1b9b48('0xe0'));},AGIVertices[_0x4d5af2('0x17b')]['ext_dial']=function(_0x3f7cfa){const _0x5e3d40=_0x4d5af2;logger[_0x5e3d40('0x86')](util['format'](_0x5e3d40('0x37'),_0x3f7cfa[_0x5e3d40('0x196')]));let _0x31a25c='';if(_0x3f7cfa[_0x5e3d40('0x1a8')]){if(!this[_0x5e3d40('0xd8')](_0x3f7cfa[_0x5e3d40('0x1a8')]))return this['channel']['error'](_0x3f7cfa,_0x5e3d40('0x97'));else{const _0x1103c3=parseInt(_0x3f7cfa[_0x5e3d40('0x1a8')],0xa);if(isNaN(_0x1103c3))_0x31a25c=_0x3f7cfa['trunk_id'];else{_0x31a25c=this['getTrunk'][_0x5e3d40('0x57')](this,_0x3f7cfa[_0x5e3d40('0x1a8')]);if(!_0x31a25c)return this[_0x5e3d40('0x11')][_0x5e3d40('0x1a6')](_0x3f7cfa,'no\x20trunk\x20found');}}}else{if(_0x3f7cfa[_0x5e3d40('0x163')])_0x31a25c=_0x3f7cfa[_0x5e3d40('0x163')];else return this['channel'][_0x5e3d40('0x1a6')](_0x3f7cfa,_0x5e3d40('0x97'));}const _0x2cee57=this[_0x5e3d40('0x11')][_0x5e3d40('0x10d')]('DIAL',[util[_0x5e3d40('0x52')](_0x5e3d40('0x65'),_0x31a25c,_0x3f7cfa['phone']),_0x3f7cfa[_0x5e3d40('0xf5')],_0x3f7cfa[_0x5e3d40('0x6c')],_0x3f7cfa['url']]);if(_0x2cee57['result']===-0x1)return _0x2cee57;return this['channel'][_0x5e3d40('0x1ce')](util[_0x5e3d40('0x52')](_0x5e3d40('0x131'),_0x5e3d40('0xcb')));},AGIVertices['prototype'][_0x4d5af2('0x63')]=function(_0x49ae02){const _0x5b8a07=_0x4d5af2;return logger[_0x5b8a07('0x86')](util[_0x5b8a07('0x52')](_0x5b8a07('0x178'),_0x49ae02[_0x5b8a07('0x196')])),this[_0x5b8a07('0x11')][_0x5b8a07('0x1ce')](_0x5b8a07('0x63'));},AGIVertices['prototype']['getdigits']=function(_0x13aa4e){const _0x1b679a=_0x4d5af2;logger['info'](util[_0x1b679a('0x52')](_0x1b679a('0x1d4'),_0x13aa4e[_0x1b679a('0x196')]));if(_0x13aa4e['retry']===0x0)return this['maxRetry'](_0x13aa4e);_0x13aa4e[_0x1b679a('0xde')]-=0x1;if(!this[_0x1b679a('0xd8')](_0x13aa4e[_0x1b679a('0x5d')]))return this[_0x1b679a('0x11')][_0x1b679a('0x1a6')](_0x13aa4e,_0x1b679a('0x12'));const _0x52d3e6=this[_0x1b679a('0xe4')][_0x1b679a('0x57')](this,_0x13aa4e[_0x1b679a('0x5d')]);if(!_0x52d3e6)return this[_0x1b679a('0x11')][_0x1b679a('0x1a6')](_0x13aa4e,'no\x20file\x20audio\x20found');if(!this[_0x1b679a('0xd8')](_0x13aa4e[_0x1b679a('0xa3')]))return this[_0x1b679a('0x11')][_0x1b679a('0x1a6')]('no\x20variable\x20selected\x20for\x20the\x20result');const _0x5df844=this[_0x1b679a('0x11')][_0x1b679a('0x162')](_0x52d3e6,_0x13aa4e['response'],_0x13aa4e[_0x1b679a('0x6b')]),_0x4a2181=_0x5df844[_0x1b679a('0x18b')]?_0x5df844[_0x1b679a('0x18b')][_0x1b679a('0x186')]():'';logger['info'](_0x1b679a('0x167'),JSON['stringify'](_0x5df844));if(_0x5df844[_0x1b679a('0x18b')]===-0x1)return this[_0x1b679a('0x1a0')]['sync'](this,_0x13aa4e,_0x4a2181),_0x5df844;else _0x5df844['extra']===_0x1b679a('0xf5')?_0x5df844[_0x1b679a('0x18b')]=_0x4a2181['length']>=parseInt(_0x13aa4e[_0x1b679a('0x19c')])?'x':'i':_0x5df844[_0x1b679a('0x18b')]=_0x4a2181[_0x1b679a('0x1a5')]>=parseInt(_0x13aa4e[_0x1b679a('0x19c')])&&_0x4a2181['length']<=parseInt(_0x13aa4e[_0x1b679a('0x6b')])?'x':'i';const _0xedadcd=this[_0x1b679a('0x7c')]['sync'](this,_0x13aa4e[_0x1b679a('0xa3')]);if(!_0xedadcd)return this['channel'][_0x1b679a('0x1a6')](_0x13aa4e,_0x1b679a('0x1d2'));this[_0x1b679a('0x11')]['setVariable'](_0xedadcd,_0x4a2181);if(this[_0x1b679a('0xd8')](_0x13aa4e[_0x1b679a('0xb9')])){const _0x191660=parseInt(_0x13aa4e[_0x1b679a('0xb9')],0xa),_0x4ba059=rs[_0x1b679a('0x10b')]({'charset':'*','length':_0x191660}),_0x30fb7a=_0x4a2181[_0x1b679a('0x1a5')];_0x30fb7a>0x0?_0x30fb7a>_0x191660?this[_0x1b679a('0x1a0')][_0x1b679a('0x57')](this,_0x13aa4e,_0x13aa4e['hiddendigitspos']===_0x1b679a('0xc0')?_0x4ba059+_0x4a2181[_0x1b679a('0x136')](_0x191660):_0x4a2181[_0x1b679a('0x136')](0x0,_0x30fb7a-_0x191660)+_0x4ba059):this[_0x1b679a('0x1a0')]['sync'](this,_0x13aa4e,rs[_0x1b679a('0x10b')]({'charset':'*','length':_0x30fb7a})):this[_0x1b679a('0x1a0')]['sync'](this,_0x13aa4e,'');}else this['createSquareDetailsReport'][_0x1b679a('0x57')](this,_0x13aa4e,_0x4a2181);return _0x5df844;},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xa7')]=function(_0x32be7f){const _0x6ef000=_0x4d5af2;return logger[_0x6ef000('0x86')](util['format']('Enter\x20in\x20GETSECRETDIGITS\x20(%s)\x20block',_0x32be7f[_0x6ef000('0x196')])),this[_0x6ef000('0x14')](_0x32be7f);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x4d')]=function(_0x44709e){const _0x6eae4d=_0x4d5af2;return logger[_0x6eae4d('0x86')](util[_0x6eae4d('0x52')](_0x6eae4d('0x1a2'),_0x44709e[_0x6eae4d('0x196')])),this['createSquareDetailsReport'][_0x6eae4d('0x57')](this,_0x44709e,_0x44709e['goalname']),this[_0x6eae4d('0x11')][_0x6eae4d('0x1ce')](util[_0x6eae4d('0x52')]('GOAL\x20%s',_0x44709e[_0x6eae4d('0x1cf')]));},AGIVertices[_0x4d5af2('0x17b')]['awspolly']=function(_0x1eb779){const _0x45fd78=_0x4d5af2;logger[_0x45fd78('0x86')](util[_0x45fd78('0x52')](_0x45fd78('0x64'),_0x1eb779[_0x45fd78('0x196')]));if(!this[_0x45fd78('0xd8')](_0x1eb779[_0x45fd78('0x2a')])||!this[_0x45fd78('0xd8')](_0x1eb779[_0x45fd78('0x165')]))return this[_0x45fd78('0x11')][_0x45fd78('0x1ce')](_0x45fd78('0xe'));if(!this[_0x45fd78('0xd8')](_0x1eb779[_0x45fd78('0x4f')]))return this[_0x45fd78('0x11')]['noop'](_0x45fd78('0x7a'));this[_0x45fd78('0x11')][_0x45fd78('0x1ce')](util[_0x45fd78('0x52')](_0x45fd78('0x89'),_0x1eb779[_0x45fd78('0x4f')]));const _0x44e5cd=this[_0x45fd78('0xf0')]['sync'](this,_0x1eb779);if(_0x44e5cd){this[_0x45fd78('0x11')][_0x45fd78('0x1ce')](util[_0x45fd78('0x52')]('aws\x20Polly\x20%s\x20file\x20created',_0x44e5cd));const _0x17fca4=this[_0x45fd78('0x11')][_0x45fd78('0xdd')](_0x44e5cd);try{fs['unlink'](_0x44e5cd+_0x45fd78('0x7d'));}catch(_0x2e2e86){logger[_0x45fd78('0x1a6')](_0x2e2e86);}return _0x17fca4;}return this[_0x45fd78('0x11')][_0x45fd78('0x1a6')](_0x1eb779,'aws\x20Polly\x20is\x20unreachable');},AGIVertices[_0x4d5af2('0x17b')]['awslex']=function(_0x57d2da){const _0x40b6e5=_0x4d5af2;logger['info'](util['format'](_0x40b6e5('0x8e'),_0x57d2da['label']));if(!this['isConfigured'](_0x57d2da['aws_access_key_id'])||!this['isConfigured'](_0x57d2da[_0x40b6e5('0x165')]))return this[_0x40b6e5('0x11')]['noop'](_0x40b6e5('0xe'));if(!this[_0x40b6e5('0xd8')](_0x57d2da[_0x40b6e5('0x53')]))return this['channel']['noop']('no\x20bot\x20name\x20configured');if(!this[_0x40b6e5('0xd8')](_0x57d2da['text']))return this['channel'][_0x40b6e5('0x1ce')](_0x40b6e5('0x7a'));this[_0x40b6e5('0x11')][_0x40b6e5('0x75')]=!![],this[_0x40b6e5('0x1a0')](_0x57d2da),this[_0x40b6e5('0x189')](_0x57d2da[_0x40b6e5('0x4f')],'in','',''),this[_0x40b6e5('0x11')]['noop'](util[_0x40b6e5('0x52')](_0x40b6e5('0x1a4'),_0x57d2da[_0x40b6e5('0x4f')]));const _0x2208db=this[_0x40b6e5('0x1d')][_0x40b6e5('0x57')](this,_0x57d2da);if(_0x2208db){for(const _0x392781 in _0x2208db){typeof _0x2208db[_0x392781]!=='undefined'&&_[_0x40b6e5('0x12b')](_0x2208db[_0x392781])&&this['channel']['setVariable'](util[_0x40b6e5('0x52')](_0x40b6e5('0xce'),_0x392781[_0x40b6e5('0xfb')]()),_0x2208db[_0x392781]);}return _[_0x40b6e5('0x125')](_0x2208db[_0x40b6e5('0x1d1')])?this[_0x40b6e5('0x11')][_0x40b6e5('0x1ce')](_0x40b6e5('0x1bb')):(this[_0x40b6e5('0x189')](_0x2208db[_0x40b6e5('0x1d1')],_0x40b6e5('0x13b'),_0x40b6e5('0x134'),''),this[_0x40b6e5('0x11')]['noop'](util[_0x40b6e5('0x52')](_0x40b6e5('0x152'),_0x2208db[_0x40b6e5('0x1d1')])));}return this['channel'][_0x40b6e5('0x1a6')](_0x57d2da,_0x40b6e5('0xc'));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xb1')]=function(_0x2ce276){const _0x394024=_0x4d5af2;logger[_0x394024('0x86')](util[_0x394024('0x52')](_0x394024('0x92'),_0x2ce276[_0x394024('0x196')],_0x2ce276[_0x394024('0xf5')]));if(!this[_0x394024('0xd8')](_0x2ce276[_0x394024('0x1b8')]))return this[_0x394024('0x11')][_0x394024('0x1ce')]('no\x20key\x20configured');const _0x433443=_0x394024('0xf9'),_0x1cf2a3=util[_0x394024('0x52')](_0x394024('0xb'),FILES_PATH,rs[_0x394024('0x10b')](0x4)),_0x34aebf=util[_0x394024('0x52')](_0x394024('0x13'),_0x1cf2a3,_0x433443);let _0x7d86d1=!![];_0x2ce276[_0x394024('0x101')]===_0x394024('0x18a')&&(_0x7d86d1=![]);const _0x34abc7=this[_0x394024('0x11')][_0x394024('0x1a')](_0x1cf2a3,_0x433443,_0x2ce276[_0x394024('0x19e')],_0x2ce276['timeout'],undefined,_0x7d86d1);if(_0x34abc7['result']!==-0x1){this[_0x394024('0x11')][_0x394024('0x1ce')](util[_0x394024('0x52')](_0x394024('0x6'),_0x34aebf));const _0x1ee774=this[_0x394024('0x137')]['sync'](this,_0x2ce276,_0x34aebf);if(_0x1ee774){for(const _0x450c2c in _0x1ee774){typeof _0x1ee774[_0x450c2c]!==_0x394024('0x1b1')&&this['channel']['setVariable'](util[_0x394024('0x52')]('GOOGLE_ASR_%s',_0x450c2c[_0x394024('0xfb')]()),_0x1ee774[_0x450c2c]);}return this['channel']['noop'](util[_0x394024('0x52')](_0x394024('0x87'),JSON[_0x394024('0xbb')](_0x1ee774)));}}return _0x34abc7;},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xa1')]=function(_0x1fcf83){const _0x4d7410=_0x4d5af2;logger['info'](util[_0x4d7410('0x52')](_0x4d7410('0xb0'),_0x1fcf83[_0x4d7410('0x196')]));if(!this[_0x4d7410('0xd8')](_0x1fcf83[_0x4d7410('0x17')]))return this[_0x4d7410('0x11')][_0x4d7410('0x1ce')]('no\x20appid\x20configured');if(!this['isConfigured'](_0x1fcf83['appsecret']))return this[_0x4d7410('0x11')][_0x4d7410('0x1ce')](_0x4d7410('0x61'));const _0x18e469=_0x4d7410('0xf9'),_0x41b994=util[_0x4d7410('0x52')](_0x4d7410('0xb'),FILES_PATH,rs[_0x4d7410('0x10b')](0x4)),_0x2b6279=util[_0x4d7410('0x52')](_0x4d7410('0x13'),_0x41b994,_0x18e469);let _0x12ce78=!![];_0x1fcf83['beep']==='NOBEEP'&&(_0x12ce78=![]);const _0x151e26=this['channel'][_0x4d7410('0x1a')](_0x41b994,_0x18e469,_0x1fcf83['intKey'],_0x1fcf83['timeout'],undefined,_0x12ce78);if(_0x151e26[_0x4d7410('0x18b')]!==-0x1){this['channel'][_0x4d7410('0x1ce')](util[_0x4d7410('0x52')](_0x4d7410('0x16a'),_0x2b6279));const _0x20010f=this[_0x4d7410('0x100')][_0x4d7410('0x57')](this,_0x1fcf83,_0x2b6279);if(_0x20010f){for(const _0x1efd2b in _0x20010f){typeof _0x20010f[_0x1efd2b]!==_0x4d7410('0x1b1')&&this[_0x4d7410('0x11')][_0x4d7410('0x193')](util[_0x4d7410('0x52')](_0x4d7410('0x121'),_0x1efd2b['toUpperCase']()),_0x20010f[_0x1efd2b]);}return this[_0x4d7410('0x11')][_0x4d7410('0x1ce')](util[_0x4d7410('0x52')](_0x4d7410('0x83'),JSON[_0x4d7410('0xbb')](_0x20010f)));}}return _0x151e26;},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x18d')]=function(_0x253e7a){const _0x45629f=_0x4d5af2;return logger[_0x45629f('0x86')](util[_0x45629f('0x52')](_0x45629f('0xd0'),_0x253e7a['label'])),this['channel'][_0x45629f('0x10e')](_0x253e7a['context'],_0x253e7a[_0x45629f('0xe9')],_0x253e7a[_0x45629f('0x24')]);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x157')]=function(_0x3f2649){const _0x810b19=_0x4d5af2;logger[_0x810b19('0x86')](util['format'](_0x810b19('0xa9'),_0x3f2649[_0x810b19('0x196')]));if(!this[_0x810b19('0xd8')](_0x3f2649[_0x810b19('0xcc')]))return this[_0x810b19('0x11')][_0x810b19('0x1a6')](_0x3f2649,'no\x20condition\x20configured');try{const _0x469591=eval(_0x3f2649['condition'])?_0x810b19('0xa5'):_0x810b19('0xbf');return this[_0x810b19('0x11')][_0x810b19('0x1ce')](util['format'](_0x810b19('0xf7'),_0x3f2649['condition'],_0x469591)),{'code':0xc8,'result':_0x469591};}catch(_0x3f4474){return{'code':0xc8,'result':_0x810b19('0xbf')};}},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x38')]=function(_0x3b73e2){const _0x326fee=_0x4d5af2;logger[_0x326fee('0x86')](util[_0x326fee('0x52')]('Enter\x20in\x20GOTOIFTIME\x20(%s)\x20block',_0x3b73e2[_0x326fee('0x196')]));if(!this[_0x326fee('0xd8')](_0x3b73e2[_0x326fee('0xbd')]))return this['channel']['error'](_0x3b73e2,_0x326fee('0x10a'));const _0x92d36d=this[_0x326fee('0x79')]['sync'](this,_0x3b73e2['interval_id']);if(!_0x92d36d)return this[_0x326fee('0x11')][_0x326fee('0x1a6')](_0x3b73e2,'no\x20intervals\x20found');for(let _0x555028=0x0;_0x555028<_0x92d36d['length'];_0x555028+=0x1){const _0x59595e=this[_0x326fee('0x11')][_0x326fee('0x7c')](util['format']('IFTIME(%s?true:false)',_0x92d36d[_0x555028]));if(_0x59595e['result']===-0x1)return _0x59595e;logger['info'](util[_0x326fee('0x52')](_0x326fee('0x176'),_0x92d36d[_0x555028],_0x59595e[_0x326fee('0x1aa')]));if(_0x59595e['extra']===_0x326fee('0xa5'))return logger[_0x326fee('0x86')](util[_0x326fee('0x52')](_0x326fee('0x176'),_0x92d36d[_0x555028],_0x326fee('0xa5'))),this[_0x326fee('0x11')][_0x326fee('0x1ce')](util['format'](_0x326fee('0x176'),_0x92d36d[_0x555028],_0x326fee('0xa5'))),{'code':0xc8,'result':_0x326fee('0xa5')};else logger[_0x326fee('0x86')](util[_0x326fee('0x52')](_0x326fee('0x176'),_0x92d36d[_0x555028],_0x326fee('0xbf'))),this[_0x326fee('0x11')]['noop'](util['format'](_0x326fee('0x176'),_0x92d36d[_0x555028],_0x326fee('0xbf')));}return{'code':0xc8,'result':'false'};},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x120')]=function(_0x1cf3ed){const _0x171579=_0x4d5af2;return logger[_0x171579('0x86')](util[_0x171579('0x52')](_0x171579('0x2'),_0x1cf3ed[_0x171579('0x196')])),this[_0x171579('0x11')][_0x171579('0x120')]();},AGIVertices[_0x4d5af2('0x17b')]['ispeechasr']=function(_0x40e0ba){const _0x136cee=_0x4d5af2;logger[_0x136cee('0x86')](util['format']('Enter\x20in\x20ISPEECHASR\x20(%s)\x20block',_0x40e0ba['label']));if(!this[_0x136cee('0xd8')](_0x40e0ba[_0x136cee('0x1b8')]))return this[_0x136cee('0x11')][_0x136cee('0x1ce')](_0x136cee('0x98'));const _0x178c27='wav',_0x786f45=util['format']('%s/recordings/%s',FILES_PATH,rs['generate'](0x4)),_0x503b91=util[_0x136cee('0x52')](_0x136cee('0x13'),_0x786f45,_0x178c27);let _0x3c7781=!![];_0x40e0ba[_0x136cee('0x101')]===_0x136cee('0x18a')&&(_0x3c7781=![]);const _0x4ce200=this[_0x136cee('0x11')][_0x136cee('0x1a')](_0x786f45,_0x178c27,_0x40e0ba[_0x136cee('0x19e')],_0x40e0ba[_0x136cee('0xf5')],undefined,_0x3c7781);if(_0x4ce200[_0x136cee('0x18b')]!==-0x1){this['channel'][_0x136cee('0x1ce')](util[_0x136cee('0x52')](_0x136cee('0x8'),_0x503b91));const _0x14d8a7=this[_0x136cee('0xc3')][_0x136cee('0x57')](this,_0x40e0ba,_0x503b91);if(_0x14d8a7){for(const _0x24b011 in _0x14d8a7){typeof _0x14d8a7[_0x24b011]!=='undefined'&&this[_0x136cee('0x11')]['setVariable'](util[_0x136cee('0x52')](_0x136cee('0x1b'),_0x24b011['toUpperCase']()),_0x14d8a7[_0x24b011]);}return this[_0x136cee('0x11')][_0x136cee('0x1ce')](util['format'](_0x136cee('0x192'),JSON[_0x136cee('0xbb')](_0x14d8a7)));}}return _0x4ce200;},AGIVertices[_0x4d5af2('0x17b')]['ispeechtts']=function(_0x30a8a4){const _0x4f7ffa=_0x4d5af2;logger['info'](util[_0x4f7ffa('0x52')](_0x4f7ffa('0x140'),_0x30a8a4[_0x4f7ffa('0x196')]));if(!this[_0x4f7ffa('0xd8')](_0x30a8a4[_0x4f7ffa('0x1b8')]))return this[_0x4f7ffa('0x11')][_0x4f7ffa('0x1ce')](_0x4f7ffa('0x98'));if(!this['isConfigured'](_0x30a8a4[_0x4f7ffa('0x4f')]))return this['channel'][_0x4f7ffa('0x1ce')](_0x4f7ffa('0x7a'));this[_0x4f7ffa('0x11')][_0x4f7ffa('0x1ce')](util[_0x4f7ffa('0x52')](_0x4f7ffa('0x1b3'),_0x30a8a4['text']));const _0x5336b6=this[_0x4f7ffa('0x182')][_0x4f7ffa('0x57')](this,_0x30a8a4);if(_0x5336b6){this[_0x4f7ffa('0x11')]['noop'](util['format'](_0x4f7ffa('0x8'),_0x5336b6));const _0x5843f4=this[_0x4f7ffa('0x11')]['streamFile'](_0x5336b6,_0x30a8a4[_0x4f7ffa('0x19e')]);try{fs[_0x4f7ffa('0x15b')](_0x5336b6+_0x4f7ffa('0x7d'));}catch(_0x2aec58){logger[_0x4f7ffa('0x1a6')](_0x2aec58);}return _0x5843f4;}return this[_0x4f7ffa('0x11')][_0x4f7ffa('0x1a6')](_0x30a8a4,_0x4f7ffa('0x2e'));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x45')]=function(_0x56c2e3){const _0xe38969=_0x4d5af2;logger[_0xe38969('0x86')](util[_0xe38969('0x52')]('Enter\x20in\x20LOGIN\x20(%s)\x20block',_0x56c2e3[_0xe38969('0x196')]));if(!this[_0xe38969('0xd8')](_0x56c2e3[_0xe38969('0x81')]))return this['channel'][_0xe38969('0x1a6')](_0x56c2e3,'no\x20find\x20by\x20configured');logger[_0xe38969('0x86')](util[_0xe38969('0x52')](_0xe38969('0x16e'),this[_0xe38969('0x11')][_0xe38969('0x7')],_0x56c2e3['findBy']));const _0x2c1991=this['agentLogin'][_0xe38969('0x57')](this,_0x56c2e3[_0xe38969('0x81')]);return _0x2c1991?(logger[_0xe38969('0x86')](util[_0xe38969('0x52')](_0xe38969('0x77'),this[_0xe38969('0x11')]['callerid'],_0x56c2e3['findBy'])),this[_0xe38969('0x11')][_0xe38969('0x1ce')](util[_0xe38969('0x52')]('AGENT\x20%s\x20FOUND\x20BY',this['channel'][_0xe38969('0x7')],_0x56c2e3['findBy'])),{'code':0xc8,'result':_0xe38969('0x36')}):(logger[_0xe38969('0x86')](util[_0xe38969('0x52')](_0xe38969('0x19'),this['channel'][_0xe38969('0x7')],_0x56c2e3[_0xe38969('0x81')])),this['channel'][_0xe38969('0x1ce')](util[_0xe38969('0x52')]('AGENT\x20%s\x20NOT\x20FOUND\x20BY',this['channel']['callerid'],_0x56c2e3[_0xe38969('0x81')])),{'code':0xc8,'result':_0xe38969('0x113')});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xef')]=function(_0x416b80){const _0x57c6f6=_0x4d5af2;logger[_0x57c6f6('0x86')](util[_0x57c6f6('0x52')](_0x57c6f6('0xdb'),_0x416b80[_0x57c6f6('0x196')]));if(!this['isConfigured'](_0x416b80[_0x57c6f6('0x81')]))return this['channel']['error'](_0x416b80,_0x57c6f6('0x4e'));logger[_0x57c6f6('0x86')](util[_0x57c6f6('0x52')](_0x57c6f6('0x16e'),this[_0x57c6f6('0x11')]['callerid'],_0x416b80[_0x57c6f6('0x81')]));const _0x419c8a=this[_0x57c6f6('0x2b')][_0x57c6f6('0x57')](this,_0x416b80[_0x57c6f6('0x81')]);return _0x419c8a?(logger['info'](util[_0x57c6f6('0x52')]('AGENT\x20%s\x20FOUND\x20BY',this[_0x57c6f6('0x11')][_0x57c6f6('0x7')],_0x416b80[_0x57c6f6('0x81')])),this[_0x57c6f6('0x11')][_0x57c6f6('0x1ce')](util[_0x57c6f6('0x52')](_0x57c6f6('0x77'),this[_0x57c6f6('0x11')]['callerid'],_0x416b80[_0x57c6f6('0x81')])),{'code':0xc8,'result':_0x57c6f6('0x36')}):(logger['info'](util[_0x57c6f6('0x52')](_0x57c6f6('0x19'),this[_0x57c6f6('0x11')][_0x57c6f6('0x7')],_0x416b80[_0x57c6f6('0x81')])),this[_0x57c6f6('0x11')][_0x57c6f6('0x1ce')](util[_0x57c6f6('0x52')](_0x57c6f6('0x19'),this[_0x57c6f6('0x11')]['callerid'],_0x416b80[_0x57c6f6('0x81')])),{'code':0xc8,'result':_0x57c6f6('0x113')});},AGIVertices['prototype'][_0x4d5af2('0x3')]=function(_0x519c23){const _0x52a866=_0x4d5af2;logger[_0x52a866('0x86')](util['format'](_0x52a866('0x66'),_0x519c23[_0x52a866('0x196')]));if(!this[_0x52a866('0xd8')](_0x519c23[_0x52a866('0x135')]))return this[_0x52a866('0x11')][_0x52a866('0x1a6')](_0x519c23,_0x52a866('0xf1'));this[_0x52a866('0x11')][_0x52a866('0x1ce')](util['format'](_0x52a866('0x112'),_0x519c23['operation']));const _0x59a023=eval(_0x519c23['operation']);if(!this[_0x52a866('0xd8')](_0x519c23['variable_id']))return this[_0x52a866('0x11')]['noop'](_0x52a866('0x123'));const _0x158323=this['getVariable']['sync'](this,_0x519c23[_0x52a866('0xa3')]);if(!_0x158323)return this[_0x52a866('0x11')][_0x52a866('0x1a6')](_0x519c23,_0x52a866('0x1d2'));if(_[_0x52a866('0x154')](_0x59a023)){const _0x144d1a=this;return _0x59a023[_0x52a866('0xb3')](function(_0x47b6dc,_0x3f2d1e){const _0x550307=_0x52a866;_0x144d1a[_0x550307('0x11')][_0x550307('0x193')](util[_0x550307('0x52')](_0x550307('0x1bc'),_0x158323,_0x3f2d1e),_0x47b6dc);}),this[_0x52a866('0x11')][_0x52a866('0x1ce')](util[_0x52a866('0x52')](_0x52a866('0x141'),_0x158323));}else return this[_0x52a866('0x11')][_0x52a866('0x193')](_0x158323,_0x59a023);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x153')]=function(_0x4df89a){const _0x1e332a=_0x4d5af2;logger['info'](util[_0x1e332a('0x52')](_0x1e332a('0x31'),_0x4df89a[_0x1e332a('0x196')]));if(_0x4df89a[_0x1e332a('0xde')]===0x0)return this[_0x1e332a('0x1c4')](_0x4df89a);_0x4df89a[_0x1e332a('0xde')]-=0x1;if(!this[_0x1e332a('0xd8')](_0x4df89a[_0x1e332a('0x5d')]))return this['channel'][_0x1e332a('0x1a6')](_0x4df89a,_0x1e332a('0x12'));const _0x589e3d=this[_0x1e332a('0xe4')][_0x1e332a('0x57')](this,_0x4df89a[_0x1e332a('0x5d')]);if(!_0x589e3d)return this[_0x1e332a('0x11')][_0x1e332a('0x1a6')](_0x4df89a,_0x1e332a('0x13e'));const _0x1ed451=this['channel'][_0x1e332a('0x162')](_0x589e3d,_0x4df89a[_0x1e332a('0x12e')],_0x4df89a[_0x1e332a('0x3a')]);let _0x2625e9=_0x1ed451[_0x1e332a('0x18b')];if(_0x1ed451[_0x1e332a('0x18b')]===-0x1)return this[_0x1e332a('0x1a0')][_0x1e332a('0x57')](this,_0x4df89a,'-1'),_0x1ed451;else{if(_0x1ed451[_0x1e332a('0x1aa')]===_0x1e332a('0xf5'))_0x1ed451[_0x1e332a('0x18b')]=_0x1ed451[_0x1e332a('0x18b')][_0x1e332a('0x1a5')]>0x0?_0x1ed451[_0x1e332a('0x18b')]:'t';else _[_0x1e332a('0x78')](_0x1ed451[_0x1e332a('0x18b')])&&(_0x1ed451[_0x1e332a('0x18b')]='#',_0x2625e9='#');}if(!this[_0x1e332a('0xd8')](_0x4df89a[_0x1e332a('0xa3')]))this[_0x1e332a('0x11')][_0x1e332a('0x1ce')](_0x1e332a('0x123'));else{const _0x3b501c=this[_0x1e332a('0x7c')][_0x1e332a('0x57')](this,_0x4df89a[_0x1e332a('0xa3')]);if(!_0x3b501c)return this[_0x1e332a('0x11')][_0x1e332a('0x1a6')](_0x4df89a,'no\x20variable\x20found');this[_0x1e332a('0x11')]['setVariable'](_0x3b501c,_0x2625e9);}return this[_0x1e332a('0x1a0')]['sync'](this,_0x4df89a,_0x2625e9),_0x1ed451;},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x1ce')]=function(_0xdc03ce){const _0x297025=_0x4d5af2;return logger[_0x297025('0x86')](util[_0x297025('0x52')]('Enter\x20in\x20NOOP\x20(%s)\x20block',_0xdc03ce[_0x297025('0x196')])),this[_0x297025('0x11')][_0x297025('0x1ce')](_0xdc03ce[_0x297025('0x1b7')]||_0xdc03ce[_0x297025('0x196')]);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xb4')]=function(_0x259ea9){const _0x1a6dd0=_0x4d5af2;logger['info'](util['format'](_0x1a6dd0('0x122'),_0x259ea9[_0x1a6dd0('0x196')]));if(!this['isConfigured'](_0x259ea9[_0x1a6dd0('0x81')]))return this['channel'][_0x1a6dd0('0x1a6')](_0x259ea9,_0x1a6dd0('0x4e'));logger[_0x1a6dd0('0x86')](util[_0x1a6dd0('0x52')](_0x1a6dd0('0x16e'),this[_0x1a6dd0('0x11')][_0x1a6dd0('0x7')],_0x259ea9[_0x1a6dd0('0x81')]));const _0x38de50=this[_0x1a6dd0('0xc5')][_0x1a6dd0('0x57')](this,_0x259ea9[_0x1a6dd0('0x3f')]),_0x5190f7=this[_0x1a6dd0('0x88')]['sync'](this,_0x259ea9[_0x1a6dd0('0x81')],_0x38de50);return _0x5190f7?(logger[_0x1a6dd0('0x86')](util[_0x1a6dd0('0x52')](_0x1a6dd0('0x77'),this[_0x1a6dd0('0x11')]['callerid'],_0x259ea9[_0x1a6dd0('0x81')])),this[_0x1a6dd0('0x11')][_0x1a6dd0('0x1ce')](util[_0x1a6dd0('0x52')](_0x1a6dd0('0x77'),this[_0x1a6dd0('0x11')][_0x1a6dd0('0x7')],_0x259ea9[_0x1a6dd0('0x81')])),{'code':0xc8,'result':_0x1a6dd0('0x36')}):(logger['info'](util['format'](_0x1a6dd0('0x19'),this[_0x1a6dd0('0x11')][_0x1a6dd0('0x7')],_0x259ea9['findBy'])),this[_0x1a6dd0('0x11')][_0x1a6dd0('0x1ce')](util[_0x1a6dd0('0x52')](_0x1a6dd0('0x77'),this[_0x1a6dd0('0x11')]['callerid'],_0x259ea9[_0x1a6dd0('0x81')])),{'code':0xc8,'result':_0x1a6dd0('0x113')});},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x2d')]=function(_0x1206e3){const _0x3a561c=_0x4d5af2;logger['info'](util[_0x3a561c('0x52')](_0x3a561c('0x99'),_0x1206e3[_0x3a561c('0x196')]));if(!this['isConfigured'](_0x1206e3[_0x3a561c('0x5d')]))return this[_0x3a561c('0x11')][_0x3a561c('0x1a6')](_0x1206e3,_0x3a561c('0x12'));const _0x532d7f=this[_0x3a561c('0xe4')][_0x3a561c('0x57')](this,_0x1206e3[_0x3a561c('0x5d')]);if(!_0x532d7f)return this[_0x3a561c('0x11')][_0x3a561c('0x1a6')](_0x1206e3,_0x3a561c('0x13e'));const _0x305422=this[_0x3a561c('0x11')][_0x3a561c('0x10d')](_0x3a561c('0xd3'),[_0x532d7f,_0x1206e3['opts']]);if(_0x305422[_0x3a561c('0x18b')]===-0x1)return _0x305422;return this[_0x3a561c('0x11')][_0x3a561c('0x1ce')](util[_0x3a561c('0x52')]('Executed\x20command\x20%s\x20%s',_0x3a561c('0xd3'),_0x532d7f));},AGIVertices['prototype'][_0x4d5af2('0xdf')]=function(_0x3bbbaa){const _0x496b4e=_0x4d5af2;logger[_0x496b4e('0x86')](util['format'](_0x496b4e('0x4b'),_0x3bbbaa[_0x496b4e('0x196')]));if(!this[_0x496b4e('0xd8')](_0x3bbbaa[_0x496b4e('0xa6')]))return this['channel'][_0x496b4e('0x1a6')](_0x3bbbaa,_0x496b4e('0x76'));let _0x464068='';const _0x584356=parseInt(_0x3bbbaa['queue_id'],0xa);if(isNaN(_0x584356))_0x464068=_0x3bbbaa['queue_id'];else{_0x464068=this['getVoiceQueue']['sync'](this,_0x3bbbaa[_0x496b4e('0xa6')]);if(!_0x464068)return this[_0x496b4e('0x11')][_0x496b4e('0x1a6')](_0x3bbbaa,_0x496b4e('0x129'));}let _0xf54dd7='';if(this[_0x496b4e('0xd8')](_0x3bbbaa[_0x496b4e('0x5d')])){const _0x4aead1=this[_0x496b4e('0xe4')][_0x496b4e('0x57')](this,_0x3bbbaa[_0x496b4e('0x5d')]);_0x4aead1&&(_0xf54dd7=_0x4aead1);}this[_0x496b4e('0x1a0')][_0x496b4e('0x57')](this,_0x3bbbaa,_0x464068);_0x3bbbaa[_0x496b4e('0x6c')][_0x496b4e('0xaf')]('x')<0x0&&(_0x3bbbaa[_0x496b4e('0x6c')]+='x');_0x3bbbaa[_0x496b4e('0x6c')][_0x496b4e('0xaf')]('X')<0x0&&(_0x3bbbaa[_0x496b4e('0x6c')]+='X');this[_0x496b4e('0x11')][_0x496b4e('0x193')](_0x496b4e('0xda'),_0x464068?_0x464068[_0x496b4e('0x29')]():'');const _0x244c22=this['channel']['exec']('QUEUE',[_0x464068,_0x3bbbaa[_0x496b4e('0x6c')],_0x3bbbaa['url'],_0xf54dd7,_0x3bbbaa[_0x496b4e('0xf5')],_0x3bbbaa[_0x496b4e('0x80')],_0x3bbbaa[_0x496b4e('0x49')],_0x3bbbaa[_0x496b4e('0x74')],'',_0x3bbbaa[_0x496b4e('0x5f')]]);if(_0x244c22[_0x496b4e('0x18b')]===-0x1)return _0x244c22;return this['channel'][_0x496b4e('0x1ce')](util[_0x496b4e('0x52')](_0x496b4e('0x28'),_0x496b4e('0xf8'),_0x464068));},AGIVertices['prototype']['record']=function(_0x1a8a20){const _0x5520fb=_0x4d5af2;logger[_0x5520fb('0x86')](util['format'](_0x5520fb('0xa8'),_0x1a8a20[_0x5520fb('0x196')]));const _0x2eb81e=_0x1a8a20['recordingFormat']||'wav',_0x251550=util[_0x5520fb('0x52')](_0x5520fb('0x1cb'),this['channel'][_0x5520fb('0x15')],rs[_0x5520fb('0x10b')](0x5)),_0x455e2f=util[_0x5520fb('0x52')]('%s/recordings/%s.%s',FILES_PATH,_0x251550,_0x2eb81e),_0x33fba=util[_0x5520fb('0x52')]('%s/recordings/%s',FILES_PATH,_0x251550);return this[_0x5520fb('0x18e')]['sync'](this,_0x1a8a20,_0x251550,_0x455e2f),this[_0x5520fb('0x11')]['setVariable']('RECORDING_SAVENAME',_0x251550),logger[_0x5520fb('0x86')](_0x5520fb('0xa4'),_0x33fba,_0x2eb81e,_0x1a8a20['escape_digits'],_0x1a8a20[_0x5520fb('0xf5')]),this[_0x5520fb('0x11')][_0x5520fb('0x1a')](_0x33fba,_0x2eb81e,_0x1a8a20[_0x5520fb('0x2c')],_0x1a8a20[_0x5520fb('0xf5')],undefined,!![]);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x5c')]=function(_0x5dd9fb){const _0x5c34ed=_0x4d5af2;logger[_0x5c34ed('0x86')](util['format'](_0x5c34ed('0x5a'),_0x5dd9fb[_0x5c34ed('0x196')]));if(!this[_0x5c34ed('0xd8')](_0x5dd9fb[_0x5c34ed('0xc2')]))return this[_0x5c34ed('0x11')][_0x5c34ed('0x1ce')](_0x5c34ed('0x7b'));const _0x1368d1=this[_0x5c34ed('0x48')]['sync'](this,_0x5dd9fb);logger[_0x5c34ed('0x86')](util[_0x5c34ed('0x52')](_0x5c34ed('0x22'),util[_0x5c34ed('0xf2')](_0x1368d1,{'showHidden':![],'depth':null})));if(!this[_0x5c34ed('0xd8')](_0x5dd9fb[_0x5c34ed('0xa3')]))return this[_0x5c34ed('0x11')][_0x5c34ed('0x1ce')](_0x5c34ed('0x11a'));const _0x5cf2ae=this[_0x5c34ed('0x7c')]['sync'](this,_0x5dd9fb[_0x5c34ed('0xa3')]);if(!_0x5cf2ae)return this[_0x5c34ed('0x11')][_0x5c34ed('0x1a6')](_0x5dd9fb,_0x5c34ed('0x1d2'));this[_0x5c34ed('0x11')][_0x5c34ed('0x193')](util['format']('%s_STATUS_CODE',_0x5cf2ae),_0x1368d1['statusCode']?_0x1368d1[_0x5c34ed('0xfe')]:'200'),this[_0x5c34ed('0x11')]['setVariable'](util['format'](_0x5c34ed('0x4'),_0x5cf2ae),_0x1368d1['statusMessage']?_0x1368d1[_0x5c34ed('0x191')]:'OK');if(_0x1368d1[_0x5c34ed('0x1d0')])try{this[_0x5c34ed('0x34')](_0x1368d1[_0x5c34ed('0x1d0')],_0x5cf2ae);}catch(_0x5c3094){logger['error'](util[_0x5c34ed('0x52')]('Unable\x20to\x20set\x20result\x20in\x20variable\x20%s',_0x5cf2ae));}return this['channel'][_0x5c34ed('0x1ce')](util[_0x5c34ed('0x52')](_0x5c34ed('0xd2'),_0x5cf2ae));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0xbc')]=function(_0x282398){const _0x2e6a5a=_0x4d5af2;return logger[_0x2e6a5a('0x86')](util[_0x2e6a5a('0x52')](_0x2e6a5a('0x20'),_0x282398[_0x2e6a5a('0x196')])),this[_0x2e6a5a('0x11')][_0x2e6a5a('0x56')](_0x282398[_0x2e6a5a('0x144')]['replace'](/\s+/g,''),_0x282398[_0x2e6a5a('0x2c')]);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x124')]=function(_0x2df66f){const _0x324a21=_0x4d5af2;return logger[_0x324a21('0x86')](util[_0x324a21('0x52')](_0x324a21('0x159'),_0x2df66f[_0x324a21('0x196')])),this[_0x324a21('0x11')][_0x324a21('0x40')](_0x2df66f[_0x324a21('0x69')][_0x324a21('0x9e')](/\s+/g,''),_0x2df66f[_0x324a21('0x2c')]);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x11d')]=function(_0x535be7){const _0x18b854=_0x4d5af2;return logger[_0x18b854('0x86')](util['format'](_0x18b854('0x156'),_0x535be7[_0x18b854('0x196')])),this[_0x18b854('0x11')]['sayPhonetic'](_0x535be7[_0x18b854('0x4f')],_0x535be7[_0x18b854('0x2c')]);},AGIVertices[_0x4d5af2('0x17b')]['sendMail']=function(_0x364fe1){const _0xba2947=_0x4d5af2;logger['info'](util[_0xba2947('0x52')](_0xba2947('0x199'),_0x364fe1[_0xba2947('0x196')]));if(!this['isConfigured'](_0x364fe1[_0xba2947('0x104')]))return this[_0xba2947('0x11')]['noop'](_0xba2947('0xee'));const _0x2831a1=this['getMailAccount'][_0xba2947('0x57')](this,_0x364fe1[_0xba2947('0x104')]);if(!_0x2831a1||!_0x2831a1['Smtp'])return this[_0xba2947('0x11')][_0xba2947('0x1a6')](_0x364fe1,'no\x20mail\x20account\x20found');const _0x1ec1b7={'from':util[_0xba2947('0x52')]('\x22%s\x22\x20<%s>',_0x2831a1['name'],_0x2831a1[_0xba2947('0x71')]||_0x2831a1[_0xba2947('0x44')][_0xba2947('0x85')]),'to':_0x364fe1['to']||'','cc':_0x364fe1['cc']||'','bcc':_0x364fe1[_0xba2947('0x10')]||'','subject':_0x364fe1[_0xba2947('0x187')],'html':_0x364fe1['text'],'text':_0x364fe1['text']},_0x191e8a={'tls':{'rejectUnauthorized':![]}};_0x2831a1[_0xba2947('0x44')][_0xba2947('0x146')]?_0x191e8a[_0xba2947('0x146')]=_0x2831a1[_0xba2947('0x44')][_0xba2947('0x146')]:(_0x191e8a[_0xba2947('0x14c')]=_0x2831a1[_0xba2947('0x44')][_0xba2947('0x14c')],_0x191e8a[_0xba2947('0x82')]=_0x2831a1['Smtp'][_0xba2947('0x82')],_0x191e8a[_0xba2947('0xae')]=_0x2831a1[_0xba2947('0x44')][_0xba2947('0xae')]);_0x2831a1[_0xba2947('0x44')][_0xba2947('0x6a')]&&(_0x191e8a[_0xba2947('0x15a')]={'user':_0x2831a1[_0xba2947('0x44')][_0xba2947('0x85')],'pass':_0x2831a1[_0xba2947('0x44')][_0xba2947('0x1c8')]});if(this['isConfigured'](_0x364fe1[_0xba2947('0x16')])){}return logger[_0xba2947('0x17e')](_0xba2947('0x107'),JSON[_0xba2947('0xbb')](_0x1ec1b7)),this[_0xba2947('0x1a0')][_0xba2947('0x57')](this,_0x364fe1,_0x364fe1['account_id']),this['channel'][_0xba2947('0x1ce')](util[_0xba2947('0x52')](_0xba2947('0x8c'),_0x2831a1[_0xba2947('0xc8')])),this[_0xba2947('0x103')][_0xba2947('0x57')](this,_0x191e8a,_0x1ec1b7),this['channel']['noop'](_0xba2947('0x119'));},AGIVertices[_0x4d5af2('0x17b')]['sendFax']=function(_0x2913ff){const _0x3870e9=_0x4d5af2;return logger[_0x3870e9('0x86')](util[_0x3870e9('0x52')]('Enter\x20in\x20SENDFAX\x20(%s)\x20block',_0x2913ff[_0x3870e9('0x196')])),this[_0x3870e9('0x11')][_0x3870e9('0x1ce')](_0x3870e9('0x90'));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x54')]=function(_0x3e4b74){const _0x428fb5=_0x4d5af2;logger['info'](util[_0x428fb5('0x52')](_0x428fb5('0x1cc'),_0x3e4b74['label']));if(!this[_0x428fb5('0xd8')](_0x3e4b74[_0x428fb5('0x1b9')]))return this['channel']['noop'](_0x428fb5('0x72'));const _0x359843=this[_0x428fb5('0x102')][_0x428fb5('0x57')](this,_0x3e4b74[_0x428fb5('0x1b9')]);if(!_0x359843)return this['channel'][_0x428fb5('0x1a6')](_0x3e4b74,_0x428fb5('0xcd'));const _0x56f2d8={'body':_0x3e4b74['sms_text'],'phone':_0x3e4b74['to']||'','SmsAccountId':_0x359843['id']};return logger['debug'](_0x428fb5('0x58'),JSON[_0x428fb5('0xbb')](_0x56f2d8)),this[_0x428fb5('0x1a0')][_0x428fb5('0x57')](this,_0x3e4b74,_0x3e4b74['sms_account_id']),this[_0x428fb5('0x11')]['noop'](util[_0x428fb5('0x52')](_0x428fb5('0x148'),_0x359843[_0x428fb5('0xc8')])),this[_0x428fb5('0xba')][_0x428fb5('0x57')](this,_0x56f2d8),this[_0x428fb5('0x11')][_0x428fb5('0x1ce')](_0x428fb5('0x47'));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x170')]=function(_0x649c44){const _0x3c8f4f=_0x4d5af2;logger[_0x3c8f4f('0x86')](util['format'](_0x3c8f4f('0xe5'),_0x649c44[_0x3c8f4f('0x196')]));if(!this[_0x3c8f4f('0xd8')](_0x649c44[_0x3c8f4f('0xa3')]))return this[_0x3c8f4f('0x11')][_0x3c8f4f('0x1a6')](_0x649c44,_0x3c8f4f('0x109'));const _0x202997=this[_0x3c8f4f('0x7c')]['sync'](this,_0x649c44[_0x3c8f4f('0xa3')]);if(!_0x202997)return this[_0x3c8f4f('0x11')][_0x3c8f4f('0x1a6')](_0x649c44,'no\x20variable\x20found');return this['channel'][_0x3c8f4f('0x193')](_0x202997,_0x649c44['variable_value']);},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x139')]=function(_0x49ebfa){const _0x4f8f88=_0x4d5af2;logger[_0x4f8f88('0x86')](util[_0x4f8f88('0x52')](_0x4f8f88('0x30'),_0x49ebfa['label'])),this['channel'][_0x4f8f88('0x1ce')]('START\x20CALLY\x20SQUARE');if(_0x49ebfa[_0x4f8f88('0xdc')]===_0x4f8f88('0x179'))return this[_0x4f8f88('0x11')][_0x4f8f88('0x1ce')](_0x4f8f88('0x13c')),this[_0x4f8f88('0x11')][_0x4f8f88('0xdc')]();return this[_0x4f8f88('0x11')]['noop'](_0x4f8f88('0x1ba'));},AGIVertices[_0x4d5af2('0x17b')]['subproject']=function(_0x154987){const _0x5a6864=_0x4d5af2;logger[_0x5a6864('0x86')](util[_0x5a6864('0x52')](_0x5a6864('0x17f'),_0x154987[_0x5a6864('0x196')]));if(!this[_0x5a6864('0xd8')](_0x154987['project_id']))return this[_0x5a6864('0x11')][_0x5a6864('0x1a6')](_0x154987,'no\x20subproject\x20selected');const _0x11accc=this[_0x5a6864('0xfd')]['sync'](this,_0x154987[_0x5a6864('0xc7')]);if(!this['isConfigured'](_0x11accc))return this[_0x5a6864('0x11')][_0x5a6864('0x1a6')](_0x154987,util['format']('no\x20subproject\x20found\x20with\x20id\x20%d',_0x154987[_0x5a6864('0xc7')]));if(_0x11accc===this[_0x5a6864('0x11')][_0x5a6864('0x106')])return this[_0x5a6864('0x11')]['error'](_0x154987,_0x5a6864('0x13d'));this['createSquareDetailsReport'][_0x5a6864('0x57')](this,_0x154987,_0x11accc);const _0x5de957=this[_0x5a6864('0x11')][_0x5a6864('0x10d')](_0x5a6864('0x1ca'),util[_0x5a6864('0x52')](_0x5a6864('0xd5'),config[_0x5a6864('0x80')][_0x5a6864('0x14c')]||_0x5a6864('0x6e'),_0x11accc,this[_0x5a6864('0x11')]['arg_1']));if(_0x5de957[_0x5a6864('0x18b')]===-0x1)return _0x5de957;return this[_0x5a6864('0x11')][_0x5a6864('0x1ce')](util[_0x5a6864('0x52')](_0x5a6864('0x28'),'AGI',_0x11accc));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x132')]=function(_0x952135){const _0x4a6588=_0x4d5af2;logger[_0x4a6588('0x86')](util['format'](_0x4a6588('0xf6'),_0x952135[_0x4a6588('0x196')]));const _0x51acb6=this[_0x4a6588('0x9')][_0x4a6588('0x57')](this,_0x952135[_0x4a6588('0x9a')]);this['createSquareDetailsReport'][_0x4a6588('0x57')](this,_0x952135,_0x952135[_0x4a6588('0x9a')]);if(this[_0x4a6588('0xd8')](_0x952135[_0x4a6588('0xa3')])){const _0x1c25e4=this[_0x4a6588('0x7c')][_0x4a6588('0x57')](this,_0x952135[_0x4a6588('0xa3')]);if(_0x1c25e4)return this[_0x4a6588('0x11')][_0x4a6588('0x193')](_0x1c25e4,_0x51acb6),this[_0x4a6588('0x11')]['noop'](util[_0x4a6588('0x52')](_0x4a6588('0x14f'),_0x952135['command'],_0x1c25e4));}return this[_0x4a6588('0x11')]['noop'](util[_0x4a6588('0x52')](_0x4a6588('0x8a'),_0x952135[_0x4a6588('0x9a')]));},AGIVertices['prototype'][_0x4d5af2('0x1a3')]=function(_0xcc1320){const _0xfd1fc4=_0x4d5af2;logger[_0xfd1fc4('0x86')](util['format'](_0xfd1fc4('0x1bf'),_0xcc1320[_0xfd1fc4('0x196')])),_0xcc1320[_0xfd1fc4('0x4f')]=_0xcc1320['text']['replace'](/(\r\n|\n|\r)/gm,'\x20');if(!this[_0xfd1fc4('0xd8')](_0xcc1320[_0xfd1fc4('0x14a')]))return this[_0xfd1fc4('0x11')]['noop'](_0xfd1fc4('0x73'));if(!this[_0xfd1fc4('0xd8')](_0xcc1320['text']))return this[_0xfd1fc4('0x11')]['noop'](_0xfd1fc4('0x7a'));this['channel']['noop'](util[_0xfd1fc4('0x52')]('Trying\x20Google\x20Cloud\x20TTS\x20%s',_0xcc1320[_0xfd1fc4('0x4f')]));const _0x4ad5da=this[_0xfd1fc4('0x3e')][_0xfd1fc4('0x57')](this,_0xcc1320);if(_0x4ad5da){this['channel'][_0xfd1fc4('0x1ce')](util[_0xfd1fc4('0x52')](_0xfd1fc4('0x180'),_0x4ad5da));const _0x300021=this['channel'][_0xfd1fc4('0xdd')](_0x4ad5da);try{fs[_0xfd1fc4('0x15b')](_0x4ad5da+_0xfd1fc4('0x7d'));}catch(_0x343f38){logger[_0xfd1fc4('0x1a6')](_0x343f38);}return _0x300021;}return this['channel'][_0xfd1fc4('0x1a6')](_0xcc1320,_0xfd1fc4('0x145'));},AGIVertices['prototype'][_0x4d5af2('0x1')]=function(_0x38d6bf){const _0x49ee23=_0x4d5af2;logger[_0x49ee23('0x86')](util['format']('Enter\x20in\x20GOOGLETTS\x20(%s)\x20block',_0x38d6bf[_0x49ee23('0x196')])),_0x38d6bf['text']=_0x38d6bf['text'][_0x49ee23('0x9e')](/(\r\n|\n|\r)/gm,'\x20');if(!this[_0x49ee23('0xd8')](_0x38d6bf[_0x49ee23('0x4f')]))return this[_0x49ee23('0x11')][_0x49ee23('0x1ce')]('no\x20text\x20configured');this[_0x49ee23('0x11')][_0x49ee23('0x1ce')](util[_0x49ee23('0x52')](_0x49ee23('0x117'),_0x38d6bf[_0x49ee23('0x4f')]));const _0x14aa47=this[_0x49ee23('0x15f')][_0x49ee23('0x57')](this,_0x38d6bf);if(_0x14aa47){this[_0x49ee23('0x11')][_0x49ee23('0x1ce')](util['format']('Google\x20TTS\x20%s\x20file\x20created',_0x14aa47));const _0x41aabe=this['channel']['streamFile'](_0x14aa47);try{fs['unlink'](_0x14aa47+_0x49ee23('0x7d'));}catch(_0x4591e7){logger[_0x49ee23('0x1a6')](_0x4591e7);}return _0x41aabe;}return this['channel'][_0x49ee23('0x1a6')](_0x38d6bf,_0x49ee23('0x43'));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x3b')]=function(_0x42e073){const _0x1c5a40=_0x4d5af2;logger['info'](util[_0x1c5a40('0x52')](_0x1c5a40('0x150'),_0x42e073[_0x1c5a40('0x196')]));if(!this['isConfigured'](_0x42e073[_0x1c5a40('0x81')]))return this[_0x1c5a40('0x11')][_0x1c5a40('0x1a6')](_0x42e073,_0x1c5a40('0x4e'));logger[_0x1c5a40('0x86')](util['format']('FIND\x20AGENT\x20%s\x20BY\x20%s',this[_0x1c5a40('0x11')]['callerid'],_0x42e073[_0x1c5a40('0x81')]));const _0x3d7f43=this[_0x1c5a40('0xc9')]['sync'](this,_0x42e073['findBy']);return _0x3d7f43?(logger[_0x1c5a40('0x86')](util[_0x1c5a40('0x52')](_0x1c5a40('0x77'),this[_0x1c5a40('0x11')][_0x1c5a40('0x7')],_0x42e073[_0x1c5a40('0x81')])),this['channel'][_0x1c5a40('0x1ce')](util[_0x1c5a40('0x52')](_0x1c5a40('0x77'),this[_0x1c5a40('0x11')][_0x1c5a40('0x7')],_0x42e073['findBy'])),{'code':0xc8,'result':_0x1c5a40('0x36')}):(logger[_0x1c5a40('0x86')](util['format'](_0x1c5a40('0x19'),this[_0x1c5a40('0x11')][_0x1c5a40('0x7')],_0x42e073['findBy'])),this['channel'][_0x1c5a40('0x1ce')](util[_0x1c5a40('0x52')]('AGENT\x20%s\x20NOT\x20FOUND\x20BY',this[_0x1c5a40('0x11')][_0x1c5a40('0x7')],_0x42e073['findBy'])),{'code':0xc8,'result':_0x1c5a40('0x113')});},AGIVertices['prototype'][_0x4d5af2('0x1b4')]=function(_0x5c0488){const _0x3f5b7a=_0x4d5af2;logger['info'](util['format'](_0x3f5b7a('0xb7'),_0x5c0488[_0x3f5b7a('0x196')]));const _0x4f7393=this['channel'][_0x3f5b7a('0x10d')](_0x3f5b7a('0xca'),[_0x5c0488[_0x3f5b7a('0x1bd')],_0x5c0488[_0x3f5b7a('0x1c9')]]);if(_0x4f7393['result']===-0x1)return _0x4f7393;return this[_0x3f5b7a('0x11')][_0x3f5b7a('0x1ce')](util[_0x3f5b7a('0x52')](_0x3f5b7a('0x28'),_0x3f5b7a('0xca'),_0x5c0488['mailbox']));},AGIVertices[_0x4d5af2('0x17b')][_0x4d5af2('0x1c0')]=function(_0x367b2f){const _0x10d676=_0x4d5af2;logger[_0x10d676('0x86')](util[_0x10d676('0x52')](_0x10d676('0x68'),_0x367b2f[_0x10d676('0x196')]));if(!this[_0x10d676('0xd8')](_0x367b2f[_0x10d676('0xa3')]))return this['channel'][_0x10d676('0x1a6')](_0x367b2f,_0x10d676('0x109'));const _0x176d19=this[_0x10d676('0x7c')][_0x10d676('0x57')](this,_0x367b2f[_0x10d676('0xa3')]);if(!_0x176d19)return this['channel']['error'](_0x367b2f,'no\x20variable\x20found');const _0x46d281=this['channel']['getVariable'](_0x176d19);return{'code':0xc8,'result':_0x46d281[_0x10d676('0x1aa')]?_0x46d281[_0x10d676('0x1aa')]:'-'};},String[_0x4d5af2('0x17b')]['replaceAll']=function(_0xd2e1ad,_0x5f530e){const _0x1aa30b=_0x4d5af2;return this[_0x1aa30b('0xe2')](_0xd2e1ad)[_0x1aa30b('0x12a')](_0x5f530e);},module[_0x4d5af2('0x169')]=AGIVertices; \ No newline at end of file diff --git a/server/services/ami/acw/index.js b/server/services/ami/acw/index.js index 1477264..12ab02f 100644 --- a/server/services/ami/acw/index.js +++ b/server/services/ami/acw/index.js @@ -1 +1 @@ -const a1049_0x1a43=['../rpc/voiceAgentReport','catch','hangup','then','[%s][BLINDTRANSFER:LINKEDID]','timers','update','uniqueid','stopAcw','custom:agentConnectPreview','[%s][HANGUPATTENDEDTRANSFER:UNIQUEID]','isUndefined','[%s][HANGUPATTENDEDTRANSFER:LINKEDID]','QueuePause','syncAttendedTransfer','voicePause','linkedid','[ACW][syncHangup]\x20%s','timer','queue','prototype','transfereruniqueid','attendedtransfer','[%s][UPDATE][ACWTIME:%s]','transfererlinkedid','[%s][HANGUP:LINKEDID]','syncAgentConnectPreview','isNil','bind','syncBlindTransfer','acwTimeout','syncHangup','attended','lodash','[%s][BLINDTRANSFER:UNIQUEID]','exports','syncAgentConnect','saveUnpause','transfereeuniqueid','[%s][HANGUP:UNIQUEID]','name','lastPauseAt','agents','finally','hanguprequest','agentringnoanswer','blindtransfer','[ACW][syncBlindTransfer]\x20%s','startAcw','transfertargetuniqueid','YYYY-MM-DD\x20HH:mm:ss','Auto-Pause','../ami','[ACW][syncAgentConnectPreview]\x20%s','channels','milliseconds','[%s][START][AGENT:%s][QUEUE:%s]','voiceQueues','[%s][UPDATE][ERRORS:%s]','syncHangupRequest','destlinkedid','info','[%s][INPAUSE][AGENT:%s][QUEUE:%s]','origtransfereruniqueid','message','all','Action','../rpc/user','[%s][TIMER:%s][AGENT:%s][QUEUE:%s]','secondtransfereruniqueid','error','stringify','mandatoryDisposition','interface','savePause','updateAcw','seconds','moment','diff','acw'];(function(_0x264077,_0x1a43e6){const _0x5dce97=function(_0x44b3b9){while(--_0x44b3b9){_0x264077['push'](_0x264077['shift']());}};_0x5dce97(++_0x1a43e6);}(a1049_0x1a43,0x191));const a1049_0x5dce=function(_0x264077,_0x1a43e6){_0x264077=_0x264077-0x0;let _0x5dce97=a1049_0x1a43[_0x264077];return _0x5dce97;};const _0x374152=a1049_0x5dce;'use strict';const _=require(_0x374152('0x20')),moment=require(_0x374152('0x4c')),ami=require(_0x374152('0x33')),logger=require('../../../config/logger')(_0x374152('0x4e')),RpcUser=require(_0x374152('0x42')),RpcVoiceAgentReport=require(_0x374152('0x4f'));function Acw(_0x44b3b9){const _0x2acf06=_0x374152;this[_0x2acf06('0x38')]=_0x44b3b9[_0x2acf06('0x38')],this[_0x2acf06('0x29')]=_0x44b3b9[_0x2acf06('0x29')],this[_0x2acf06('0x4')]=_0x44b3b9[_0x2acf06('0x4')],this[_0x2acf06('0x35')]={},ami['on']('agentconnect',this[_0x2acf06('0x23')][_0x2acf06('0x1b')](this)),ami['on'](_0x2acf06('0x2b'),this[_0x2acf06('0x3a')][_0x2acf06('0x1b')](this)),ami['on'](_0x2acf06('0x1'),this[_0x2acf06('0x1e')][_0x2acf06('0x1b')](this)),ami['on'](_0x2acf06('0x2c'),this['syncAgentRingNoAnswer'][_0x2acf06('0x1b')](this)),ami['on'](_0x2acf06('0x15'),this[_0x2acf06('0xd')]['bind'](this)),ami['on'](_0x2acf06('0x2d'),this[_0x2acf06('0x1c')]['bind'](this)),ami['on'](_0x2acf06('0x8'),this[_0x2acf06('0x19')][_0x2acf06('0x1b')](this));}function getDiff(_0x467211){const _0x23b988=_0x374152,_0xa2dfbd=moment()[_0x23b988('0x36')](0x0),_0x21877b=moment(_0x467211)[_0x23b988('0x36')](0x0);return _0xa2dfbd[_0x23b988('0x4d')](_0x21877b,_0x23b988('0x4b'));}Acw[_0x374152('0x13')][_0x374152('0x2f')]=function(_0x3a4ef3){const _0x2cae98=_0x374152;try{const _0x405047=this,_0x2a8933=this[_0x2cae98('0x35')][_0x3a4ef3]['interface'],_0x57a47a=this[_0x2cae98('0x35')][_0x3a4ef3]['queue'],_0x54f653=this[_0x2cae98('0x38')][_0x57a47a];let _0xc50dfc=![],_0x5f45cb='ACW';_0x54f653[_0x2cae98('0x47')]&&(_0x54f653['mandatoryDispositionPause'][_0x2cae98('0x27')]&&(_0xc50dfc=!![],_0x5f45cb=_0x54f653['mandatoryDispositionPause']['name'])),ami[_0x2cae98('0x41')]({'action':_0x2cae98('0xc'),'interface':_0x2a8933,'paused':!![],'reason':_0x5f45cb})[_0x2cae98('0x2')](function(){const _0x17fd53=_0x2cae98;if(_0x405047['agents'][_0x2a8933])return RpcUser['getAgent'](_0x405047[_0x17fd53('0x29')][_0x2a8933]['id'])['then'](function(_0x2f809d){const _0x5aa6d8=_0x17fd53;if(_0x2f809d&&!_0x2f809d[_0x5aa6d8('0xe')]){logger['info'](_0x5aa6d8('0x37'),_0x3a4ef3,_0x2a8933,_0x57a47a);const _0x498176=_0x405047[_0x5aa6d8('0x35')][_0x3a4ef3][_0x5aa6d8('0x1f')]&&_0x405047[_0x5aa6d8('0x35')][_0x3a4ef3][_0x5aa6d8('0x3b')]?_0x405047[_0x5aa6d8('0x35')][_0x3a4ef3][_0x5aa6d8('0x3b')]:_0x3a4ef3;return RpcUser[_0x5aa6d8('0x49')](_0x405047[_0x5aa6d8('0x29')][_0x2a8933],_0x5f45cb,_0x498176)[_0x5aa6d8('0x2')](function(){const _0x24309e=_0x5aa6d8;!_0xc50dfc&&(_0x405047[_0x24309e('0x4')][_0x2a8933]={},logger[_0x24309e('0x3c')](_0x24309e('0x43'),_0x3a4ef3,_0x405047[_0x24309e('0x38')][_0x57a47a]['acwTimeout'],_0x2a8933,_0x57a47a),_0x405047[_0x24309e('0x4')][_0x2a8933]['timer']=setTimeout(_0x405047[_0x24309e('0x7')][_0x24309e('0x1b')](_0x405047,_0x2a8933),_0x405047[_0x24309e('0x38')][_0x57a47a][_0x24309e('0x1d')]*0x3e8),_0x405047[_0x24309e('0x4')][_0x2a8933][_0x24309e('0x28')]=moment()['format'](_0x24309e('0x31')),_0x405047[_0x24309e('0x4')][_0x2a8933][_0x24309e('0x6')]=_0x3a4ef3,_0x405047['timers'][_0x2a8933][_0x24309e('0x12')]=_0x57a47a,_0x405047[_0x24309e('0x4')][_0x2a8933][_0x24309e('0x4a')]=function(){const _0x146903=_0x24309e,_0x3728e5=getDiff(_0x405047[_0x146903('0x4')][_0x2a8933][_0x146903('0x28')]);clearTimeout(_0x405047['timers'][_0x2a8933][_0x146903('0x11')]),_0x405047['timers'][_0x2a8933][_0x146903('0x11')]=![],RpcVoiceAgentReport[_0x146903('0x5')]({'acwtime':_0x3728e5},_0x405047[_0x146903('0x4')][_0x2a8933][_0x146903('0x6')],_0x2a8933)[_0x146903('0x2')](function(_0x3738b7){const _0x41738e=_0x146903;logger[_0x41738e('0x3c')](_0x41738e('0x16'),_0x3a4ef3,_0x3728e5,_0x3738b7);})['catch'](function(_0xecddb8){const _0x286c7e=_0x146903;logger['error'](_0x286c7e('0x39'),_0x3a4ef3,_0xecddb8);}),delete _0x405047['timers'][_0x2a8933];});});}else logger[_0x5aa6d8('0x3c')](_0x5aa6d8('0x3d'),_0x3a4ef3,_0x2a8933,_0x57a47a);});})['catch'](function(){const _0x5b0327=_0x2cae98;logger[_0x5b0327('0x45')](_0x5b0327('0x43'),_0x3a4ef3,_0x405047[_0x5b0327('0x38')][_0x57a47a][_0x5b0327('0x1d')],_0x2a8933,_0x57a47a);})[_0x2cae98('0x2a')](function(){const _0x15cb3a=_0x2cae98;delete _0x405047[_0x15cb3a('0x35')][_0x3a4ef3];});}catch(_0x41cddd){logger[_0x2cae98('0x45')]('[ACW][START]\x20%s',_0x41cddd['message']);}},Acw['prototype']['stopAcw']=function(_0x482fa0){const _0x424858=_0x374152;try{const _0x317e7b=this;if(_0x317e7b[_0x424858('0x4')][_0x482fa0]){_0x317e7b[_0x424858('0x4')][_0x482fa0][_0x424858('0x11')]=![];const _0x31d560=_0x317e7b['timers'][_0x482fa0]['uniqueid'],_0x3377c5=_0x317e7b['timers'][_0x482fa0][_0x424858('0x12')],_0x2cea2a=_0x317e7b[_0x424858('0x38')][_0x3377c5][_0x424858('0x1d')];logger[_0x424858('0x3c')]('[TIMER][STOP][AGENT:%s]',_0x482fa0),RpcUser[_0x424858('0x24')](this['agents'][_0x482fa0]),RpcVoiceAgentReport[_0x424858('0x5')]({'acwtime':_0x2cea2a,'agentacw':!![]},_0x31d560,_0x482fa0)[_0x424858('0x2')](function(_0xe19567){const _0x41c26a=_0x424858;logger[_0x41c26a('0x3c')](_0x41c26a('0x16'),_0x31d560,_0x2cea2a,_0xe19567);})[_0x424858('0x0')](function(_0x1a0a83){const _0x4d534f=_0x424858;logger[_0x4d534f('0x45')](_0x4d534f('0x39'),_0x31d560,_0x1a0a83);});}else logger[_0x424858('0x45')]('[ACW][STOP]\x20Interface\x20%s\x20doesn\x27t\x20have\x20timer',_0x482fa0),_0x317e7b['timers']&&logger[_0x424858('0x3c')]('[ACW][TIMERS]',JSON[_0x424858('0x46')](_0x317e7b[_0x424858('0x4')]));}catch(_0x358bd1){logger[_0x424858('0x45')]('[ACW][STOP]\x20%s',_0x358bd1[_0x424858('0x3f')]);}},Acw['prototype'][_0x374152('0x23')]=function(_0x461693){const _0xf6216f=_0x374152;try{this[_0xf6216f('0x38')][_0x461693['queue']]&&(this[_0xf6216f('0x38')][_0x461693[_0xf6216f('0x12')]]['acw']||this[_0xf6216f('0x38')][_0x461693[_0xf6216f('0x12')]][_0xf6216f('0x47')])&&(this[_0xf6216f('0x29')][_0x461693[_0xf6216f('0x48')]]&&(this['channels'][_0x461693['uniqueid']]={'queue':_0x461693[_0xf6216f('0x12')],'interface':_0x461693[_0xf6216f('0x48')],'destlinkedid':_0x461693[_0xf6216f('0x3b')]}));}catch(_0x49c0a9){logger['error']('[ACW][syncAgentConnect]\x20%s',_0x49c0a9[_0xf6216f('0x3f')]);}},Acw['prototype'][_0x374152('0x19')]=function(_0x1d8149){const _0x39f546=_0x374152;try{this[_0x39f546('0x38')][_0x1d8149[_0x39f546('0x12')]]&&(this['voiceQueues'][_0x1d8149[_0x39f546('0x12')]][_0x39f546('0x4e')]||this[_0x39f546('0x38')][_0x1d8149[_0x39f546('0x12')]][_0x39f546('0x47')])&&(this[_0x39f546('0x29')][_0x1d8149['interface']]&&(this[_0x39f546('0x35')][_0x1d8149[_0x39f546('0x6')]]={'queue':_0x1d8149[_0x39f546('0x12')],'interface':_0x1d8149['interface']}));}catch(_0x567e9f){logger[_0x39f546('0x45')](_0x39f546('0x34'),_0x567e9f['message']);}},Acw[_0x374152('0x13')][_0x374152('0x3a')]=function(_0x558446){const _0x29466f=_0x374152;try{if(this['channels'][_0x558446[_0x29466f('0x6')]]&&_['isUndefined'](this[_0x29466f('0x35')][_0x558446['uniqueid']][_0x29466f('0x1f')]))logger[_0x29466f('0x3c')](_0x29466f('0x26'),_0x558446[_0x29466f('0x6')]),this[_0x29466f('0x2f')](_0x558446[_0x29466f('0x6')]);else this[_0x29466f('0x35')][_0x558446[_0x29466f('0xf')]]&&_[_0x29466f('0xa')](this[_0x29466f('0x35')][_0x558446[_0x29466f('0xf')]][_0x29466f('0x1f')])&&(logger[_0x29466f('0x3c')](_0x29466f('0x18'),_0x558446['linkedid']),this['startAcw'](_0x558446[_0x29466f('0xf')]));}catch(_0x8f854a){logger['error']('[ACW][syncHangupRequest]\x20%s',_0x8f854a['message']);}},Acw[_0x374152('0x13')][_0x374152('0x1e')]=function(_0x2e2ea1){const _0x1dcde5=_0x374152;try{if(this[_0x1dcde5('0x35')][_0x2e2ea1[_0x1dcde5('0x6')]]&&this[_0x1dcde5('0x35')][_0x2e2ea1[_0x1dcde5('0x6')]]['attended'])logger['info'](_0x1dcde5('0x9'),_0x2e2ea1['uniqueid']),this[_0x1dcde5('0x2f')](_0x2e2ea1[_0x1dcde5('0x6')]);else this[_0x1dcde5('0x35')][_0x2e2ea1[_0x1dcde5('0xf')]]&&this[_0x1dcde5('0x35')][_0x2e2ea1[_0x1dcde5('0xf')]]['attended']&&(logger[_0x1dcde5('0x3c')](_0x1dcde5('0xb'),_0x2e2ea1[_0x1dcde5('0xf')]),this['startAcw'](_0x2e2ea1['linkedid']));}catch(_0x1eafc0){logger[_0x1dcde5('0x45')](_0x1dcde5('0x10'),_0x1eafc0[_0x1dcde5('0x3f')]);}},Acw['prototype'][_0x374152('0xd')]=function(_0x2ade9a){const _0x2ff998=_0x374152;try{if(!_[_0x2ff998('0x1a')](this[_0x2ff998('0x35')][_0x2ade9a['transfereeuniqueid']]))this[_0x2ff998('0x2f')](_0x2ade9a[_0x2ff998('0x25')]),this[_0x2ff998('0x35')][_0x2ade9a[_0x2ff998('0x44')]]&&(this[_0x2ff998('0x35')][_0x2ade9a['secondtransfereruniqueid']][_0x2ff998('0x1f')]=!![],this[_0x2ff998('0x35')][_0x2ade9a[_0x2ff998('0x30')]]=this[_0x2ff998('0x35')][_0x2ade9a[_0x2ff998('0x44')]],delete this[_0x2ff998('0x35')][_0x2ade9a[_0x2ff998('0x44')]]);else!_[_0x2ff998('0x1a')](this[_0x2ff998('0x35')][_0x2ade9a['transfertargetuniqueid']])&&(this['startAcw'](_0x2ade9a[_0x2ff998('0x30')]),this[_0x2ff998('0x35')][_0x2ade9a['origtransfereruniqueid']]&&(this['channels'][_0x2ade9a[_0x2ff998('0x3e')]][_0x2ff998('0x1f')]=!![],this['channels'][_0x2ade9a[_0x2ff998('0x25')]]=this['channels'][_0x2ade9a[_0x2ff998('0x3e')]],delete this[_0x2ff998('0x35')][_0x2ade9a[_0x2ff998('0x3e')]]));}catch(_0x5a62e0){logger[_0x2ff998('0x45')]('[ACW][syncAttendedTransfer]\x20%s',_0x5a62e0[_0x2ff998('0x3f')]);}},Acw[_0x374152('0x13')][_0x374152('0x1c')]=function(_0x432fb9){const _0xb88c85=_0x374152;try{if(this[_0xb88c85('0x35')][_0x432fb9[_0xb88c85('0x14')]])logger[_0xb88c85('0x3c')](_0xb88c85('0x21'),JSON['stringify'](_0x432fb9['transfereruniqueid'])),this[_0xb88c85('0x2f')](_0x432fb9[_0xb88c85('0x14')]);else this[_0xb88c85('0x35')][_0x432fb9[_0xb88c85('0x17')]]&&(logger[_0xb88c85('0x3c')](_0xb88c85('0x3'),JSON['stringify'](_0x432fb9['transfererlinkedid'])),this[_0xb88c85('0x2f')](_0x432fb9[_0xb88c85('0x17')]));}catch(_0x29c423){logger[_0xb88c85('0x45')](_0xb88c85('0x2e'),_0x29c423[_0xb88c85('0x3f')]);}},Acw[_0x374152('0x13')]['syncAgentRingNoAnswer']=function(_0x207afd){const _0x54b92e=_0x374152;try{if(this['voiceQueues'][_0x207afd['queue']]&&this[_0x54b92e('0x38')][_0x207afd[_0x54b92e('0x12')]]['autopause']===_0x54b92e('0x40')){if(this[_0x54b92e('0x29')][_0x207afd[_0x54b92e('0x48')]])return logger[_0x54b92e('0x3c')]('[%s][AUTOPAUSE][AGENT:%s][QUEUE:%]',_0x207afd[_0x54b92e('0x6')],_0x207afd[_0x54b92e('0x48')],_0x207afd[_0x54b92e('0x12')]),RpcUser[_0x54b92e('0x49')](this[_0x54b92e('0x29')][_0x207afd['interface']],_0x54b92e('0x32'),_0x207afd['uniqueid']);}}catch(_0x46266c){logger[_0x54b92e('0x45')]('[ACW][syncAgentRingNoAnswer]\x20%s',_0x46266c[_0x54b92e('0x3f')]);}},module[_0x374152('0x22')]=Acw; \ No newline at end of file +const a1049_0x4aef=['message','timer','attendedtransfer','timers','syncAgentRingNoAnswer','voiceQueues','bind','uniqueid','autopause','then','blindtransfer','[ACW][START]\x20%s','moment','name','isNil','transfertargetuniqueid','../ami','interface','../rpc/voiceAgentReport','syncAgentConnectPreview','stopAcw','updateAcw','exports','[%s][BLINDTRANSFER:LINKEDID]','[ACW][STOP]\x20%s','lastPauseAt','syncAttendedTransfer','startAcw','[%s][START][AGENT:%s][QUEUE:%s]','[%s][HANGUPATTENDEDTRANSFER:UNIQUEID]','../../../config/logger','saveUnpause','attended','all','update','[ACW][syncBlindTransfer]\x20%s','transfererlinkedid','[ACW][syncHangupRequest]\x20%s','[TIMER][STOP][AGENT:%s]','agentringnoanswer','milliseconds','mandatoryDispositionPause','[ACW][syncAgentConnect]\x20%s','transfereeuniqueid','[ACW][syncAgentRingNoAnswer]\x20%s','[%s][HANGUP:LINKEDID]','getAgent','[ACW][syncAgentConnectPreview]\x20%s','format','[%s][UPDATE][ACWTIME:%s]','syncHangupRequest','acwTimeout','[ACW][STOP]\x20Interface\x20%s\x20doesn\x27t\x20have\x20timer','queue','acw','ACW','seconds','agents','catch','[%s][TIMER:%s][AGENT:%s][QUEUE:%s]','hanguprequest','secondtransfereruniqueid','syncAgentConnect','transfereruniqueid','info','stringify','isUndefined','QueuePause','channels','../rpc/user','syncHangup','prototype','[ACW][TIMERS]','diff','mandatoryDisposition','[ACW][syncAttendedTransfer]\x20%s','lodash','voicePause','destlinkedid','[%s][UPDATE][ERRORS:%s]','[%s][INPAUSE][AGENT:%s][QUEUE:%s]','Auto-Pause','syncBlindTransfer','[ACW][syncHangup]\x20%s','[%s][HANGUP:UNIQUEID]','origtransfereruniqueid','savePause','Action','YYYY-MM-DD\x20HH:mm:ss','finally','linkedid','error'];(function(_0x1d9776,_0x4aef07){const _0x338dbc=function(_0x68c6d6){while(--_0x68c6d6){_0x1d9776['push'](_0x1d9776['shift']());}};_0x338dbc(++_0x4aef07);}(a1049_0x4aef,0x73));const a1049_0x338d=function(_0x1d9776,_0x4aef07){_0x1d9776=_0x1d9776-0x0;let _0x338dbc=a1049_0x4aef[_0x1d9776];return _0x338dbc;};const _0x3a3feb=a1049_0x338d;'use strict';const _=require(_0x3a3feb('0x35')),moment=require(_0x3a3feb('0x51')),ami=require(_0x3a3feb('0x55')),logger=require(_0x3a3feb('0x7'))(_0x3a3feb('0x1f')),RpcUser=require(_0x3a3feb('0x2e')),RpcVoiceAgentReport=require(_0x3a3feb('0x57'));function Acw(_0x68c6d6){const _0x45f927=_0x3a3feb;this[_0x45f927('0x4a')]=_0x68c6d6[_0x45f927('0x4a')],this[_0x45f927('0x22')]=_0x68c6d6[_0x45f927('0x22')],this[_0x45f927('0x48')]=_0x68c6d6['timers'],this['channels']={},ami['on']('agentconnect',this[_0x45f927('0x27')][_0x45f927('0x4b')](this)),ami['on'](_0x45f927('0x25'),this[_0x45f927('0x1b')][_0x45f927('0x4b')](this)),ami['on']('hangup',this['syncHangup'][_0x45f927('0x4b')](this)),ami['on'](_0x45f927('0x10'),this[_0x45f927('0x49')]['bind'](this)),ami['on'](_0x45f927('0x47'),this[_0x45f927('0x3')][_0x45f927('0x4b')](this)),ami['on'](_0x45f927('0x4f'),this['syncBlindTransfer'][_0x45f927('0x4b')](this)),ami['on']('custom:agentConnectPreview',this[_0x45f927('0x58')]['bind'](this));}function getDiff(_0x406f17){const _0x479328=_0x3a3feb,_0x58734f=moment()[_0x479328('0x11')](0x0),_0x5b6f57=moment(_0x406f17)[_0x479328('0x11')](0x0);return _0x58734f[_0x479328('0x32')](_0x5b6f57,_0x479328('0x21'));}Acw[_0x3a3feb('0x30')][_0x3a3feb('0x4')]=function(_0x4e6d1f){const _0x4dc9f8=_0x3a3feb;try{const _0x2a9bb8=this,_0x5926e1=this[_0x4dc9f8('0x2d')][_0x4e6d1f][_0x4dc9f8('0x56')],_0x2aaa0=this['channels'][_0x4e6d1f][_0x4dc9f8('0x1e')],_0x52aea2=this[_0x4dc9f8('0x4a')][_0x2aaa0];let _0x215c8a=![],_0x542f34=_0x4dc9f8('0x20');_0x52aea2[_0x4dc9f8('0x33')]&&(_0x52aea2[_0x4dc9f8('0x12')][_0x4dc9f8('0x52')]&&(_0x215c8a=!![],_0x542f34=_0x52aea2['mandatoryDispositionPause'][_0x4dc9f8('0x52')])),ami[_0x4dc9f8('0x40')]({'action':_0x4dc9f8('0x2c'),'interface':_0x5926e1,'paused':!![],'reason':_0x542f34})[_0x4dc9f8('0x4e')](function(){const _0x5f12e6=_0x4dc9f8;if(_0x2a9bb8['agents'][_0x5926e1])return RpcUser[_0x5f12e6('0x17')](_0x2a9bb8[_0x5f12e6('0x22')][_0x5926e1]['id'])[_0x5f12e6('0x4e')](function(_0x5ebb29){const _0x54e7f1=_0x5f12e6;if(_0x5ebb29&&!_0x5ebb29[_0x54e7f1('0x36')]){logger['info'](_0x54e7f1('0x5'),_0x4e6d1f,_0x5926e1,_0x2aaa0);const _0x3546da=_0x2a9bb8['channels'][_0x4e6d1f][_0x54e7f1('0x9')]&&_0x2a9bb8['channels'][_0x4e6d1f][_0x54e7f1('0x37')]?_0x2a9bb8[_0x54e7f1('0x2d')][_0x4e6d1f][_0x54e7f1('0x37')]:_0x4e6d1f;return RpcUser[_0x54e7f1('0x3f')](_0x2a9bb8[_0x54e7f1('0x22')][_0x5926e1],_0x542f34,_0x3546da)[_0x54e7f1('0x4e')](function(){const _0x3296b3=_0x54e7f1;!_0x215c8a&&(_0x2a9bb8[_0x3296b3('0x48')][_0x5926e1]={},logger['info'](_0x3296b3('0x24'),_0x4e6d1f,_0x2a9bb8['voiceQueues'][_0x2aaa0]['acwTimeout'],_0x5926e1,_0x2aaa0),_0x2a9bb8[_0x3296b3('0x48')][_0x5926e1][_0x3296b3('0x46')]=setTimeout(_0x2a9bb8['stopAcw'][_0x3296b3('0x4b')](_0x2a9bb8,_0x5926e1),_0x2a9bb8[_0x3296b3('0x4a')][_0x2aaa0][_0x3296b3('0x1c')]*0x3e8),_0x2a9bb8['timers'][_0x5926e1][_0x3296b3('0x2')]=moment()[_0x3296b3('0x19')](_0x3296b3('0x41')),_0x2a9bb8[_0x3296b3('0x48')][_0x5926e1][_0x3296b3('0x4c')]=_0x4e6d1f,_0x2a9bb8['timers'][_0x5926e1]['queue']=_0x2aaa0,_0x2a9bb8[_0x3296b3('0x48')][_0x5926e1][_0x3296b3('0x5a')]=function(){const _0x4a4612=_0x3296b3,_0x5cf8cd=getDiff(_0x2a9bb8[_0x4a4612('0x48')][_0x5926e1][_0x4a4612('0x2')]);clearTimeout(_0x2a9bb8['timers'][_0x5926e1][_0x4a4612('0x46')]),_0x2a9bb8['timers'][_0x5926e1][_0x4a4612('0x46')]=![],RpcVoiceAgentReport['update']({'acwtime':_0x5cf8cd},_0x2a9bb8[_0x4a4612('0x48')][_0x5926e1][_0x4a4612('0x4c')],_0x5926e1)[_0x4a4612('0x4e')](function(_0x57abfd){const _0xda3a14=_0x4a4612;logger[_0xda3a14('0x29')](_0xda3a14('0x1a'),_0x4e6d1f,_0x5cf8cd,_0x57abfd);})[_0x4a4612('0x23')](function(_0x38a8cf){const _0x59590b=_0x4a4612;logger['error'](_0x59590b('0x38'),_0x4e6d1f,_0x38a8cf);}),delete _0x2a9bb8['timers'][_0x5926e1];});});}else logger['info'](_0x54e7f1('0x39'),_0x4e6d1f,_0x5926e1,_0x2aaa0);});})[_0x4dc9f8('0x23')](function(){const _0x168967=_0x4dc9f8;logger['error'](_0x168967('0x24'),_0x4e6d1f,_0x2a9bb8[_0x168967('0x4a')][_0x2aaa0]['acwTimeout'],_0x5926e1,_0x2aaa0);})[_0x4dc9f8('0x42')](function(){delete _0x2a9bb8['channels'][_0x4e6d1f];});}catch(_0x3367f3){logger[_0x4dc9f8('0x44')](_0x4dc9f8('0x50'),_0x3367f3[_0x4dc9f8('0x45')]);}},Acw[_0x3a3feb('0x30')][_0x3a3feb('0x59')]=function(_0x14b06c){const _0x473e00=_0x3a3feb;try{const _0x5f1c4c=this;if(_0x5f1c4c[_0x473e00('0x48')][_0x14b06c]){_0x5f1c4c[_0x473e00('0x48')][_0x14b06c][_0x473e00('0x46')]=![];const _0x3442f3=_0x5f1c4c[_0x473e00('0x48')][_0x14b06c][_0x473e00('0x4c')],_0x5764d3=_0x5f1c4c[_0x473e00('0x48')][_0x14b06c][_0x473e00('0x1e')],_0x31e92d=_0x5f1c4c[_0x473e00('0x4a')][_0x5764d3][_0x473e00('0x1c')];logger[_0x473e00('0x29')](_0x473e00('0xf'),_0x14b06c),RpcUser[_0x473e00('0x8')](this[_0x473e00('0x22')][_0x14b06c]),RpcVoiceAgentReport[_0x473e00('0xb')]({'acwtime':_0x31e92d,'agentacw':!![]},_0x3442f3,_0x14b06c)[_0x473e00('0x4e')](function(_0x14d358){const _0x1e6597=_0x473e00;logger[_0x1e6597('0x29')](_0x1e6597('0x1a'),_0x3442f3,_0x31e92d,_0x14d358);})[_0x473e00('0x23')](function(_0x20c25f){const _0x701295=_0x473e00;logger[_0x701295('0x44')](_0x701295('0x38'),_0x3442f3,_0x20c25f);});}else logger[_0x473e00('0x44')](_0x473e00('0x1d'),_0x14b06c),_0x5f1c4c[_0x473e00('0x48')]&&logger[_0x473e00('0x29')](_0x473e00('0x31'),JSON['stringify'](_0x5f1c4c['timers']));}catch(_0x41ea42){logger['error'](_0x473e00('0x1'),_0x41ea42[_0x473e00('0x45')]);}},Acw[_0x3a3feb('0x30')][_0x3a3feb('0x27')]=function(_0x3173a1){const _0xadf69d=_0x3a3feb;try{this[_0xadf69d('0x4a')][_0x3173a1[_0xadf69d('0x1e')]]&&(this[_0xadf69d('0x4a')][_0x3173a1['queue']][_0xadf69d('0x1f')]||this[_0xadf69d('0x4a')][_0x3173a1[_0xadf69d('0x1e')]]['mandatoryDisposition'])&&(this[_0xadf69d('0x22')][_0x3173a1[_0xadf69d('0x56')]]&&(this[_0xadf69d('0x2d')][_0x3173a1[_0xadf69d('0x4c')]]={'queue':_0x3173a1[_0xadf69d('0x1e')],'interface':_0x3173a1[_0xadf69d('0x56')],'destlinkedid':_0x3173a1[_0xadf69d('0x37')]}));}catch(_0x486178){logger[_0xadf69d('0x44')](_0xadf69d('0x13'),_0x486178[_0xadf69d('0x45')]);}},Acw['prototype'][_0x3a3feb('0x58')]=function(_0x13646f){const _0x39af6c=_0x3a3feb;try{this[_0x39af6c('0x4a')][_0x13646f[_0x39af6c('0x1e')]]&&(this[_0x39af6c('0x4a')][_0x13646f[_0x39af6c('0x1e')]][_0x39af6c('0x1f')]||this[_0x39af6c('0x4a')][_0x13646f['queue']][_0x39af6c('0x33')])&&(this[_0x39af6c('0x22')][_0x13646f[_0x39af6c('0x56')]]&&(this[_0x39af6c('0x2d')][_0x13646f[_0x39af6c('0x4c')]]={'queue':_0x13646f[_0x39af6c('0x1e')],'interface':_0x13646f['interface']}));}catch(_0x550e52){logger['error'](_0x39af6c('0x18'),_0x550e52[_0x39af6c('0x45')]);}},Acw[_0x3a3feb('0x30')]['syncHangupRequest']=function(_0x5f27c6){const _0x33dc50=_0x3a3feb;try{if(this['channels'][_0x5f27c6[_0x33dc50('0x4c')]]&&_[_0x33dc50('0x2b')](this['channels'][_0x5f27c6['uniqueid']]['attended']))logger[_0x33dc50('0x29')](_0x33dc50('0x3d'),_0x5f27c6[_0x33dc50('0x4c')]),this[_0x33dc50('0x4')](_0x5f27c6[_0x33dc50('0x4c')]);else this[_0x33dc50('0x2d')][_0x5f27c6[_0x33dc50('0x43')]]&&_[_0x33dc50('0x2b')](this[_0x33dc50('0x2d')][_0x5f27c6[_0x33dc50('0x43')]][_0x33dc50('0x9')])&&(logger[_0x33dc50('0x29')](_0x33dc50('0x16'),_0x5f27c6[_0x33dc50('0x43')]),this['startAcw'](_0x5f27c6[_0x33dc50('0x43')]));}catch(_0x151a2a){logger['error'](_0x33dc50('0xe'),_0x151a2a['message']);}},Acw[_0x3a3feb('0x30')][_0x3a3feb('0x2f')]=function(_0x3f90e5){const _0xcfd2d=_0x3a3feb;try{if(this['channels'][_0x3f90e5[_0xcfd2d('0x4c')]]&&this['channels'][_0x3f90e5[_0xcfd2d('0x4c')]][_0xcfd2d('0x9')])logger[_0xcfd2d('0x29')](_0xcfd2d('0x6'),_0x3f90e5['uniqueid']),this[_0xcfd2d('0x4')](_0x3f90e5[_0xcfd2d('0x4c')]);else this[_0xcfd2d('0x2d')][_0x3f90e5[_0xcfd2d('0x43')]]&&this[_0xcfd2d('0x2d')][_0x3f90e5[_0xcfd2d('0x43')]][_0xcfd2d('0x9')]&&(logger[_0xcfd2d('0x29')]('[%s][HANGUPATTENDEDTRANSFER:LINKEDID]',_0x3f90e5['linkedid']),this[_0xcfd2d('0x4')](_0x3f90e5[_0xcfd2d('0x43')]));}catch(_0x2f6edd){logger[_0xcfd2d('0x44')](_0xcfd2d('0x3c'),_0x2f6edd[_0xcfd2d('0x45')]);}},Acw[_0x3a3feb('0x30')][_0x3a3feb('0x3')]=function(_0x33de41){const _0x45c7f4=_0x3a3feb;try{if(!_[_0x45c7f4('0x53')](this['channels'][_0x33de41[_0x45c7f4('0x14')]]))this[_0x45c7f4('0x4')](_0x33de41[_0x45c7f4('0x14')]),this[_0x45c7f4('0x2d')][_0x33de41[_0x45c7f4('0x26')]]&&(this[_0x45c7f4('0x2d')][_0x33de41['secondtransfereruniqueid']][_0x45c7f4('0x9')]=!![],this['channels'][_0x33de41[_0x45c7f4('0x54')]]=this['channels'][_0x33de41[_0x45c7f4('0x26')]],delete this[_0x45c7f4('0x2d')][_0x33de41[_0x45c7f4('0x26')]]);else!_['isNil'](this[_0x45c7f4('0x2d')][_0x33de41[_0x45c7f4('0x54')]])&&(this[_0x45c7f4('0x4')](_0x33de41[_0x45c7f4('0x54')]),this[_0x45c7f4('0x2d')][_0x33de41[_0x45c7f4('0x3e')]]&&(this[_0x45c7f4('0x2d')][_0x33de41[_0x45c7f4('0x3e')]][_0x45c7f4('0x9')]=!![],this['channels'][_0x33de41[_0x45c7f4('0x14')]]=this[_0x45c7f4('0x2d')][_0x33de41[_0x45c7f4('0x3e')]],delete this['channels'][_0x33de41[_0x45c7f4('0x3e')]]));}catch(_0x4200d4){logger['error'](_0x45c7f4('0x34'),_0x4200d4[_0x45c7f4('0x45')]);}},Acw[_0x3a3feb('0x30')][_0x3a3feb('0x3b')]=function(_0x5aea50){const _0x546626=_0x3a3feb;try{if(this[_0x546626('0x2d')][_0x5aea50['transfereruniqueid']])logger[_0x546626('0x29')]('[%s][BLINDTRANSFER:UNIQUEID]',JSON[_0x546626('0x2a')](_0x5aea50[_0x546626('0x28')])),this[_0x546626('0x4')](_0x5aea50[_0x546626('0x28')]);else this['channels'][_0x5aea50['transfererlinkedid']]&&(logger[_0x546626('0x29')](_0x546626('0x0'),JSON[_0x546626('0x2a')](_0x5aea50[_0x546626('0xd')])),this[_0x546626('0x4')](_0x5aea50[_0x546626('0xd')]));}catch(_0x1e208c){logger[_0x546626('0x44')](_0x546626('0xc'),_0x1e208c[_0x546626('0x45')]);}},Acw['prototype'][_0x3a3feb('0x49')]=function(_0x1fc105){const _0x1d726b=_0x3a3feb;try{if(this['voiceQueues'][_0x1fc105[_0x1d726b('0x1e')]]&&this[_0x1d726b('0x4a')][_0x1fc105[_0x1d726b('0x1e')]][_0x1d726b('0x4d')]===_0x1d726b('0xa')){if(this[_0x1d726b('0x22')][_0x1fc105[_0x1d726b('0x56')]])return logger[_0x1d726b('0x29')]('[%s][AUTOPAUSE][AGENT:%s][QUEUE:%]',_0x1fc105[_0x1d726b('0x4c')],_0x1fc105[_0x1d726b('0x56')],_0x1fc105[_0x1d726b('0x1e')]),RpcUser[_0x1d726b('0x3f')](this[_0x1d726b('0x22')][_0x1fc105['interface']],_0x1d726b('0x3a'),_0x1fc105[_0x1d726b('0x4c')]);}}catch(_0xd8b62b){logger[_0x1d726b('0x44')](_0x1d726b('0x15'),_0xd8b62b[_0x1d726b('0x45')]);}},module[_0x3a3feb('0x5b')]=Acw; \ No newline at end of file diff --git a/server/services/ami/ami.js b/server/services/ami/ami.js index a805160..ad7b84e 100644 --- a/server/services/ami/ami.js +++ b/server/services/ami/ami.js @@ -1 +1 @@ -const a1050_0x4b9e=['resolve','coreshowchannels','actionSipShowRegistry','fullybooted','../../config/environment','Manager\x20\x22%s\x22\x20closed\x20to\x20%s:%s','util','actionSipPeerStatus','username','devicestatelist','inspect','catch','exports','connect','format','Action','ami','port','action','then','asterisk','../../config/logger','info','Shutdown\x20\x22%s\x22\x20to\x20%s:%s\x20with:\x0a%s','error','close','log','actionCoreShowChannels','once','promisify','password','actionDeviceStateList','queuesummary'];(function(_0x26cbd5,_0x4b9ec7){const _0x53b616=function(_0x504c68){while(--_0x504c68){_0x26cbd5['push'](_0x26cbd5['shift']());}};_0x53b616(++_0x4b9ec7);}(a1050_0x4b9e,0x172));const a1050_0x53b6=function(_0x26cbd5,_0x4b9ec7){_0x26cbd5=_0x26cbd5-0x0;let _0x53b616=a1050_0x4b9e[_0x26cbd5];return _0x53b616;};const _0x1dc0f0=a1050_0x53b6;'use strict';const Manager=require('asterisk-manager'),util=require(_0x1dc0f0('0x20')),logger=require(_0x1dc0f0('0xe'))(_0x1dc0f0('0x9')),config=require(_0x1dc0f0('0x1e')),ami=new Manager(config[_0x1dc0f0('0xd')]['port'],config[_0x1dc0f0('0xd')]['ip'],config[_0x1dc0f0('0xd')][_0x1dc0f0('0x1')],config['asterisk'][_0x1dc0f0('0x17')],!![]);ami['keepConnected'](),ami['Action']=util[_0x1dc0f0('0x16')](ami[_0x1dc0f0('0xb')]);function error(_0x504c68){const _0x10def4=_0x1dc0f0;logger[_0x10def4('0x11')](util[_0x10def4('0x7')]('Manager\x20\x22%s\x22\x20error\x20to\x20%s:%s\x20with:\x0a%s',config[_0x10def4('0xd')][_0x10def4('0x1')],config[_0x10def4('0xd')]['ip'],config[_0x10def4('0xd')][_0x10def4('0xa')],util['inspect'](_0x504c68,![],null)));}function close(){const _0x4e4292=_0x1dc0f0;logger[_0x4e4292('0x11')](util[_0x4e4292('0x7')](_0x4e4292('0x1f'),config[_0x4e4292('0xd')][_0x4e4292('0x1')],config[_0x4e4292('0xd')]['ip'],config[_0x4e4292('0xd')][_0x4e4292('0xa')]));}ami[_0x1dc0f0('0x1c')]=function(){return function(){return ami['Action']({'action':'sipshowregistry'});};},ami['actionDeviceStateList']=function(){return function(){const _0x42e0a6=a1050_0x53b6;return ami[_0x42e0a6('0x8')]({'action':_0x42e0a6('0x2')});};},ami[_0x1dc0f0('0x0')]=function(){return function(){const _0x475f9d=a1050_0x53b6;return ami[_0x475f9d('0x8')]({'action':'sippeerstatus'});};},ami['actionQueueSummary']=function(){return function(){const _0x37f457=a1050_0x53b6;return ami[_0x37f457('0x8')]({'action':_0x37f457('0x19')});};},ami[_0x1dc0f0('0x14')]=function(){return function(){const _0x5d1b49=a1050_0x53b6;return ami[_0x5d1b49('0x8')]({'action':_0x5d1b49('0x1b')});};};function connect(){const _0x160067=_0x1dc0f0;logger[_0x160067('0xf')](util['format']('Manager\x20\x22%s\x22\x20logged\x20on\x20to\x20%s:%s',config['asterisk'][_0x160067('0x1')],config['asterisk']['ip'],config[_0x160067('0xd')][_0x160067('0xa')])),ami[_0x160067('0x15')](_0x160067('0x11'),error),ami['once'](_0x160067('0x12'),close);}ami['on'](_0x1dc0f0('0x6'),connect),ami['on']('shutdown',function(_0x4b18bb){const _0x166039=_0x1dc0f0;logger[_0x166039('0xf')](util[_0x166039('0x7')](_0x166039('0x10'),config[_0x166039('0xd')][_0x166039('0x1')],config[_0x166039('0xd')]['ip'],config[_0x166039('0xd')][_0x166039('0xa')],util[_0x166039('0x3')](_0x4b18bb,![],null)));}),ami['on'](_0x1dc0f0('0x1d'),function(){const _0x357250=_0x1dc0f0;return logger[_0x357250('0xf')](util[_0x357250('0x7')]('Fullybooted\x20\x22%s\x22\x20to\x20%s:%s',config[_0x357250('0xd')][_0x357250('0x1')],config[_0x357250('0xd')]['ip'],config[_0x357250('0xd')]['port'])),Promise[_0x357250('0x1a')]()[_0x357250('0xc')](ami[_0x357250('0x1c')]())[_0x357250('0xc')](ami[_0x357250('0x18')]())[_0x357250('0xc')](ami[_0x357250('0x0')]())['then'](ami['actionQueueSummary']())['then'](ami[_0x357250('0x14')]())[_0x357250('0x4')](function(_0x54153e){const _0x17b49f=_0x357250;console[_0x17b49f('0x13')](_0x54153e);});}),ami['once']('error',error),ami[_0x1dc0f0('0x15')](_0x1dc0f0('0x12'),close),module[_0x1dc0f0('0x5')]=ami; \ No newline at end of file +const a1050_0x3ad1=['shutdown','Action','inspect','actionSipPeerStatus','actionCoreShowChannels','actionSipShowRegistry','asterisk','sippeerstatus','info','error','action','fullybooted','password','Fullybooted\x20\x22%s\x22\x20to\x20%s:%s','format','../../config/logger','once','util','log','keepConnected','coreshowchannels','port','Shutdown\x20\x22%s\x22\x20to\x20%s:%s\x20with:\x0a%s','catch','../../config/environment','sipshowregistry','ami','promisify','then','actionQueueSummary','Manager\x20\x22%s\x22\x20error\x20to\x20%s:%s\x20with:\x0a%s','resolve','actionDeviceStateList','username','close'];(function(_0x4db3b8,_0x3ad127){const _0x49e618=function(_0x3a3352){while(--_0x3a3352){_0x4db3b8['push'](_0x4db3b8['shift']());}};_0x49e618(++_0x3ad127);}(a1050_0x3ad1,0x82));const a1050_0x49e6=function(_0x4db3b8,_0x3ad127){_0x4db3b8=_0x4db3b8-0x0;let _0x49e618=a1050_0x3ad1[_0x4db3b8];return _0x49e618;};const _0x2fe1cc=a1050_0x49e6;'use strict';const Manager=require('asterisk-manager'),util=require(_0x2fe1cc('0x1b')),logger=require(_0x2fe1cc('0x19'))(_0x2fe1cc('0x1')),config=require(_0x2fe1cc('0x22')),ami=new Manager(config['asterisk'][_0x2fe1cc('0x1f')],config['asterisk']['ip'],config[_0x2fe1cc('0x10')][_0x2fe1cc('0x8')],config[_0x2fe1cc('0x10')][_0x2fe1cc('0x16')],!![]);ami[_0x2fe1cc('0x1d')](),ami[_0x2fe1cc('0xb')]=util[_0x2fe1cc('0x2')](ami[_0x2fe1cc('0x14')]);function error(_0x3a3352){const _0x29bfe2=_0x2fe1cc;logger[_0x29bfe2('0x13')](util[_0x29bfe2('0x18')](_0x29bfe2('0x5'),config[_0x29bfe2('0x10')][_0x29bfe2('0x8')],config['asterisk']['ip'],config[_0x29bfe2('0x10')]['port'],util[_0x29bfe2('0xc')](_0x3a3352,![],null)));}function close(){const _0x325603=_0x2fe1cc;logger[_0x325603('0x13')](util[_0x325603('0x18')]('Manager\x20\x22%s\x22\x20closed\x20to\x20%s:%s',config[_0x325603('0x10')][_0x325603('0x8')],config[_0x325603('0x10')]['ip'],config['asterisk']['port']));}ami[_0x2fe1cc('0xf')]=function(){return function(){const _0x59ccfa=a1050_0x49e6;return ami[_0x59ccfa('0xb')]({'action':_0x59ccfa('0x0')});};},ami[_0x2fe1cc('0x7')]=function(){return function(){const _0x1d0124=a1050_0x49e6;return ami[_0x1d0124('0xb')]({'action':'devicestatelist'});};},ami[_0x2fe1cc('0xd')]=function(){return function(){const _0x1f5c50=a1050_0x49e6;return ami[_0x1f5c50('0xb')]({'action':_0x1f5c50('0x11')});};},ami[_0x2fe1cc('0x4')]=function(){return function(){const _0x57b897=a1050_0x49e6;return ami[_0x57b897('0xb')]({'action':'queuesummary'});};},ami[_0x2fe1cc('0xe')]=function(){return function(){const _0x217f45=a1050_0x49e6;return ami['Action']({'action':_0x217f45('0x1e')});};};function connect(){const _0x1c9f5e=_0x2fe1cc;logger[_0x1c9f5e('0x12')](util['format']('Manager\x20\x22%s\x22\x20logged\x20on\x20to\x20%s:%s',config[_0x1c9f5e('0x10')][_0x1c9f5e('0x8')],config[_0x1c9f5e('0x10')]['ip'],config[_0x1c9f5e('0x10')][_0x1c9f5e('0x1f')])),ami[_0x1c9f5e('0x1a')](_0x1c9f5e('0x13'),error),ami[_0x1c9f5e('0x1a')](_0x1c9f5e('0x9'),close);}ami['on']('connect',connect),ami['on'](_0x2fe1cc('0xa'),function(_0x22d622){const _0x1d6c92=_0x2fe1cc;logger['info'](util['format'](_0x1d6c92('0x20'),config[_0x1d6c92('0x10')][_0x1d6c92('0x8')],config['asterisk']['ip'],config[_0x1d6c92('0x10')][_0x1d6c92('0x1f')],util['inspect'](_0x22d622,![],null)));}),ami['on'](_0x2fe1cc('0x15'),function(){const _0x39d580=_0x2fe1cc;return logger[_0x39d580('0x12')](util['format'](_0x39d580('0x17'),config[_0x39d580('0x10')]['username'],config[_0x39d580('0x10')]['ip'],config['asterisk']['port'])),Promise[_0x39d580('0x6')]()[_0x39d580('0x3')](ami[_0x39d580('0xf')]())[_0x39d580('0x3')](ami[_0x39d580('0x7')]())[_0x39d580('0x3')](ami[_0x39d580('0xd')]())[_0x39d580('0x3')](ami[_0x39d580('0x4')]())[_0x39d580('0x3')](ami['actionCoreShowChannels']())[_0x39d580('0x21')](function(_0x44024e){const _0x11ad43=_0x39d580;console[_0x11ad43('0x1c')](_0x44024e);});}),ami[_0x2fe1cc('0x1a')](_0x2fe1cc('0x13'),error),ami['once'](_0x2fe1cc('0x9'),close),module['exports']=ami; \ No newline at end of file diff --git a/server/services/ami/client.js b/server/services/ami/client.js index bf31776..a919359 100644 --- a/server/services/ami/client.js +++ b/server/services/ami/client.js @@ -1 +1 @@ -const a1051_0x580f=['Request','http','then','error','memberReport','client','jayson/promise','exports','result','request','catch','../../config/logger','ami','message','debug','rpc'];(function(_0x43df01,_0x580f0b){const _0x2fa626=function(_0xbba1cc){while(--_0xbba1cc){_0x43df01['push'](_0x43df01['shift']());}};_0x2fa626(++_0x580f0b);}(a1051_0x580f,0x97));const a1051_0x2fa6=function(_0x43df01,_0x580f0b){_0x43df01=_0x43df01-0x0;let _0x2fa626=a1051_0x580f[_0x43df01];return _0x2fa626;};const _0x57c78a=a1051_0x2fa6;'use strict';const jayson=require(_0x57c78a('0xf')),logger=require(_0x57c78a('0x4'))(_0x57c78a('0x5')),client=jayson[_0x57c78a('0xe')][_0x57c78a('0xa')]({'port':0x2329});client[_0x57c78a('0x9')]=function(_0xbba1cc,_0x48d4cf){return new Promise(function(_0x6473ec,_0x198feb){const _0x408c14=a1051_0x2fa6;return client[_0x408c14('0x2')](_0xbba1cc,_0x48d4cf)[_0x408c14('0xb')](function(_0x17ddd0){const _0xeb7f68=_0x408c14;return logger[_0xeb7f68('0x7')](_0xeb7f68('0x8'),_0xeb7f68('0xd'),_0xbba1cc,_0x48d4cf,_0x17ddd0),_0x17ddd0[_0xeb7f68('0xc')]?(logger[_0xeb7f68('0xc')](_0xeb7f68('0x8'),_0xeb7f68('0xd'),_0xbba1cc,_0x17ddd0[_0xeb7f68('0xc')][_0xeb7f68('0x6')],_0x48d4cf),_0x198feb(_0x17ddd0[_0xeb7f68('0xc')]['message'])):_0x6473ec(_0x17ddd0[_0xeb7f68('0x1')]);})[_0x408c14('0x3')](function(_0x562ced){const _0xb76771=_0x408c14;return logger[_0xb76771('0xc')](_0xb76771('0x8'),'memberReport',_0xbba1cc,_0x562ced,_0x48d4cf),_0x198feb(_0x562ced);});});},module[_0x57c78a('0x0')]=client; \ No newline at end of file +const a1051_0x2313=['then','Request','../../config/logger','rpc','request','client','result','ami','error','http','debug','jayson/promise','catch','message','exports','memberReport'];(function(_0x409dee,_0x2313c6){const _0x3dc249=function(_0x3e6751){while(--_0x3e6751){_0x409dee['push'](_0x409dee['shift']());}};_0x3dc249(++_0x2313c6);}(a1051_0x2313,0x12c));const a1051_0x3dc2=function(_0x409dee,_0x2313c6){_0x409dee=_0x409dee-0x0;let _0x3dc249=a1051_0x2313[_0x409dee];return _0x3dc249;};const _0x4802cd=a1051_0x3dc2;'use strict';const jayson=require(_0x4802cd('0xf')),logger=require(_0x4802cd('0x6'))(_0x4802cd('0xb')),client=jayson[_0x4802cd('0x9')][_0x4802cd('0xd')]({'port':0x2329});client[_0x4802cd('0x5')]=function(_0x3e6751,_0x536563){return new Promise(function(_0x273d77,_0x31d3f8){const _0x2331d7=a1051_0x3dc2;return client[_0x2331d7('0x8')](_0x3e6751,_0x536563)[_0x2331d7('0x4')](function(_0x167705){const _0x19fa7a=_0x2331d7;return logger[_0x19fa7a('0xe')]('rpc',_0x19fa7a('0x3'),_0x3e6751,_0x536563,_0x167705),_0x167705[_0x19fa7a('0xc')]?(logger[_0x19fa7a('0xc')](_0x19fa7a('0x7'),_0x19fa7a('0x3'),_0x3e6751,_0x167705[_0x19fa7a('0xc')][_0x19fa7a('0x1')],_0x536563),_0x31d3f8(_0x167705[_0x19fa7a('0xc')][_0x19fa7a('0x1')])):_0x273d77(_0x167705[_0x19fa7a('0xa')]);})[_0x2331d7('0x0')](function(_0x35e6e8){const _0x190a51=_0x2331d7;return logger[_0x190a51('0xc')](_0x190a51('0x7'),_0x190a51('0x3'),_0x3e6751,_0x35e6e8,_0x536563),_0x31d3f8(_0x35e6e8);});});},module[_0x4802cd('0x2')]=client; \ No newline at end of file diff --git a/server/services/ami/dialer/action.js b/server/services/ami/dialer/action.js index cb11b9b..a51aa30 100644 --- a/server/services/ami/dialer/action.js +++ b/server/services/ami/dialer/action.js @@ -1 +1 @@ -const a1052_0x2ea3=['moment','number','countagentrejectretry','idHopper','string','firstName','originatecalleridnum','\x22%s\x22\x20<%s>','type','countdropretry','callbackuniqueid','voiceQueue','countmachineretry','ListId','starttime','isNil','ContactFirstName','phone','getQueue','active','getCaller','countbusyretry','VoiceQueueId','queue','countcongestionretry','scheduledat','Contact','lastName','util','callback','countabandonedretry','format','CampaignId','YYYY-MM-DD\x20HH:mm:ss','name','countnosuchnumberretry','originatecalleridname','recallme','uniqueid','callbackat','UserId','countnoanswerretry','ContactId','prototype','dialCutDigit'];(function(_0x3fd304,_0x2ea300){const _0x194f71=function(_0x421b15){while(--_0x421b15){_0x3fd304['push'](_0x3fd304['shift']());}};_0x194f71(++_0x2ea300);}(a1052_0x2ea3,0x7f));const a1052_0x194f=function(_0x3fd304,_0x2ea300){_0x3fd304=_0x3fd304-0x0;let _0x194f71=a1052_0x2ea3[_0x3fd304];return _0x194f71;};const _0x3da241=a1052_0x194f;'use strict';const util=require(_0x3da241('0x24')),_=require('lodash'),moment=require(_0x3da241('0x8'));function checkNameSurname(_0x421b15,_0x7846a1,_0x25c650){const _0x593c83=_0x3da241;let _0x1cec48='';!_[_0x593c83('0x17')](_0x7846a1)&&_0x593c83('0xc')===typeof _0x7846a1&&(_0x1cec48+=_0x7846a1);!_[_0x593c83('0x17')](_0x25c650)&&'string'===typeof _0x25c650&&(_0x1cec48+='\x20'+_0x25c650);if(_0x1cec48!=='')return _0x1cec48;return _0x421b15;}function Action(_0x9c39c2,_0x3b249e,_0xf7d91){const _0x38e922=_0x3da241;this[_0x38e922('0x13')]=_0x9c39c2,this[_0x38e922('0x1')]=_0xf7d91||undefined,this['name']=checkNameSurname(_0x3b249e[_0x38e922('0x22')]['phone'],_0x3b249e[_0x38e922('0x22')][_0x38e922('0xd')],_0x3b249e[_0x38e922('0x22')][_0x38e922('0x23')]),this[_0x38e922('0x9')]=_0x3b249e[_0x38e922('0x22')][_0x38e922('0x19')],this[_0x38e922('0x1f')]=_0x9c39c2[_0x38e922('0x2a')],this['active']=_0x3b249e[_0x38e922('0x1b')]||![],this[_0x38e922('0x10')]=_0x9c39c2[_0x38e922('0x10')],this['dialQueueTimeout']=_0x9c39c2['dialQueueTimeout']||0x3,this['scheduledat']=_0x3b249e[_0x38e922('0x21')],this['countbusyretry']=_0x3b249e[_0x38e922('0x1d')],this[_0x38e922('0x20')]=_0x3b249e[_0x38e922('0x20')],this['countnoanswerretry']=_0x3b249e[_0x38e922('0x4')],this[_0x38e922('0x2b')]=_0x3b249e[_0x38e922('0x2b')],this['countdropretry']=_0x3b249e[_0x38e922('0x11')],this[_0x38e922('0x26')]=_0x3b249e[_0x38e922('0x26')],this[_0x38e922('0x14')]=_0x3b249e[_0x38e922('0x14')],this[_0x38e922('0xa')]=_0x3b249e[_0x38e922('0xa')],this[_0x38e922('0x5')]=_0x3b249e[_0x38e922('0x5')],this[_0x38e922('0x15')]=_0x3b249e[_0x38e922('0x15')],this[_0x38e922('0x3')]=_0x3b249e[_0x38e922('0x3')],this['VoiceQueueId']=_0x3b249e[_0x38e922('0x1e')],this[_0x38e922('0x28')]=_0x3b249e['CampaignId'],this[_0x38e922('0xb')]=_0x3b249e['id'],this[_0x38e922('0x18')]=_0x3b249e[_0x38e922('0x22')][_0x38e922('0xd')]||'',this[_0x38e922('0x16')]=moment()[_0x38e922('0x27')](_0x38e922('0x29')),this['callback']=_0x3b249e[_0x38e922('0x25')],this[_0x38e922('0x12')]=_0x3b249e[_0x38e922('0x12')],this[_0x38e922('0x2')]=_0x3b249e[_0x38e922('0x2')],this[_0x38e922('0x0')]=_0x3b249e['recallme'],this[_0x38e922('0xe')]='',this[_0x38e922('0x2c')]='';}Action[_0x3da241('0x6')][_0x3da241('0x1c')]=function(){const _0x268398=_0x3da241;return util[_0x268398('0x27')](_0x268398('0xf'),this[_0x268398('0x2a')],this[_0x268398('0x13')][_0x268398('0x7')]>0x0?this[_0x268398('0x9')]['substring'](this[_0x268398('0x13')][_0x268398('0x7')]):this[_0x268398('0x9')]);},Action['prototype'][_0x3da241('0x1a')]=function(){return this['queue'];},module['exports']=Action; \ No newline at end of file +const a1052_0x5df1=['string','countdropretry','Contact','dialCutDigit','\x22%s\x22\x20<%s>','getQueue','callback','ListId','lastName','countbusyretry','UserId','firstName','originatecalleridname','exports','name','moment','CampaignId','active','util','countmachineretry','countagentrejectretry','VoiceQueueId','getCaller','dialQueueTimeout','ContactId','isNil','type','callbackuniqueid','queue','phone','prototype','lodash','recallme','voiceQueue','countcongestionretry','countnosuchnumberretry','idHopper','uniqueid','number','countnoanswerretry','format','YYYY-MM-DD\x20HH:mm:ss','substring','callbackat','scheduledat'];(function(_0x5d6be0,_0x5df18e){const _0x1536d5=function(_0x3a117d){while(--_0x3a117d){_0x5d6be0['push'](_0x5d6be0['shift']());}};_0x1536d5(++_0x5df18e);}(a1052_0x5df1,0x19d));const a1052_0x1536=function(_0x5d6be0,_0x5df18e){_0x5d6be0=_0x5d6be0-0x0;let _0x1536d5=a1052_0x5df1[_0x5d6be0];return _0x1536d5;};const _0x3b0125=a1052_0x1536;'use strict';const util=require(_0x3b0125('0xa')),_=require(_0x3b0125('0x17')),moment=require(_0x3b0125('0x7'));function checkNameSurname(_0x3a117d,_0x8e19d5,_0x3389ef){const _0x7c9d4d=_0x3b0125;let _0x231c6c='';!_[_0x7c9d4d('0x11')](_0x8e19d5)&&_0x7c9d4d('0x25')===typeof _0x8e19d5&&(_0x231c6c+=_0x8e19d5);!_[_0x7c9d4d('0x11')](_0x3389ef)&&_0x7c9d4d('0x25')===typeof _0x3389ef&&(_0x231c6c+='\x20'+_0x3389ef);if(_0x231c6c!=='')return _0x231c6c;return _0x3a117d;}function Action(_0x21e84f,_0x5bb2a2,_0x159999){const _0x473add=_0x3b0125;this[_0x473add('0x19')]=_0x21e84f,this[_0x473add('0x1d')]=_0x159999||undefined,this['name']=checkNameSurname(_0x5bb2a2['Contact']['phone'],_0x5bb2a2[_0x473add('0x27')][_0x473add('0x3')],_0x5bb2a2[_0x473add('0x27')][_0x473add('0x0')]),this[_0x473add('0x1e')]=_0x5bb2a2[_0x473add('0x27')][_0x473add('0x15')],this['queue']=_0x21e84f[_0x473add('0x6')],this[_0x473add('0x9')]=_0x5bb2a2[_0x473add('0x9')]||![],this[_0x473add('0x12')]=_0x21e84f[_0x473add('0x12')],this[_0x473add('0xf')]=_0x21e84f[_0x473add('0xf')]||0x3,this[_0x473add('0x24')]=_0x5bb2a2[_0x473add('0x24')],this[_0x473add('0x1')]=_0x5bb2a2[_0x473add('0x1')],this[_0x473add('0x1a')]=_0x5bb2a2[_0x473add('0x1a')],this[_0x473add('0x1f')]=_0x5bb2a2[_0x473add('0x1f')],this[_0x473add('0x1b')]=_0x5bb2a2[_0x473add('0x1b')],this[_0x473add('0x26')]=_0x5bb2a2[_0x473add('0x26')],this['countabandonedretry']=_0x5bb2a2['countabandonedretry'],this[_0x473add('0xb')]=_0x5bb2a2['countmachineretry'],this['countagentrejectretry']=_0x5bb2a2[_0x473add('0xc')],this[_0x473add('0x10')]=_0x5bb2a2[_0x473add('0x10')],this['ListId']=_0x5bb2a2[_0x473add('0x2c')],this[_0x473add('0x2')]=_0x5bb2a2[_0x473add('0x2')],this[_0x473add('0xd')]=_0x5bb2a2[_0x473add('0xd')],this[_0x473add('0x8')]=_0x5bb2a2[_0x473add('0x8')],this[_0x473add('0x1c')]=_0x5bb2a2['id'],this['ContactFirstName']=_0x5bb2a2[_0x473add('0x27')]['firstName']||'',this['starttime']=moment()[_0x473add('0x20')](_0x473add('0x21')),this[_0x473add('0x2b')]=_0x5bb2a2[_0x473add('0x2b')],this[_0x473add('0x13')]=_0x5bb2a2['callbackuniqueid'],this[_0x473add('0x23')]=_0x5bb2a2['callbackat'],this[_0x473add('0x18')]=_0x5bb2a2[_0x473add('0x18')],this['originatecalleridnum']='',this[_0x473add('0x4')]='';}Action[_0x3b0125('0x16')][_0x3b0125('0xe')]=function(){const _0x245e07=_0x3b0125;return util[_0x245e07('0x20')](_0x245e07('0x29'),this['name'],this[_0x245e07('0x19')][_0x245e07('0x28')]>0x0?this[_0x245e07('0x1e')][_0x245e07('0x22')](this[_0x245e07('0x19')][_0x245e07('0x28')]):this[_0x245e07('0x1e')]);},Action[_0x3b0125('0x16')][_0x3b0125('0x2a')]=function(){const _0x228d1a=_0x3b0125;return this[_0x228d1a('0x14')];},module[_0x3b0125('0x5')]=Action; \ No newline at end of file diff --git a/server/services/ami/dialer/agentComplete.js b/server/services/ami/dialer/agentComplete.js index c5adfec..cd9e24d 100644 --- a/server/services/ami/dialer/agentComplete.js +++ b/server/services/ami/dialer/agentComplete.js @@ -1 +1 @@ -const a1053_0x309b=['calleridnum','endtime','answertime','scheduledat','recallme','callbackuniqueid','ListId','callback','diff','callbackat','countnosuchnumberretry','campaigntype','membername','state','countcongestionretry','countnoanswerretry','number','YYYY-MM-DD\x20HH:mm:ss','ContactId','exports','UserId','countglobal','Answer','starttime','VoiceQueueId','statedesc','talktime','type','countbusyretry','countabandonedretry','queue','reason','countagentrejectretry','countmachineretry','responsetime','uniqueid','originatecalleridnum','moment','countdropretry','calleridname','CampaignId','milliseconds','outbound','originatecalleridname'];(function(_0x453824,_0x309b24){const _0x431c40=function(_0x2e754a){while(--_0x2e754a){_0x453824['push'](_0x453824['shift']());}};_0x431c40(++_0x309b24);}(a1053_0x309b,0x1c6));const a1053_0x431c=function(_0x453824,_0x309b24){_0x453824=_0x453824-0x0;let _0x431c40=a1053_0x309b[_0x453824];return _0x431c40;};const _0x279e83=a1053_0x431c;'use strict';const moment=require(_0x279e83('0x17'));function getSeconds(_0x2e754a,_0x3248c0){const _0x48a234=_0x279e83,_0x1e1763=moment(_0x2e754a)[_0x48a234('0x1b')](0x0),_0x589482=moment(_0x3248c0)[_0x48a234('0x1b')](0x0);return _0x1e1763[_0x48a234('0x26')](_0x589482,'seconds');}function AgentComplete(_0x1dfb5b,_0x7036){const _0x1f4eb8=_0x279e83;this[_0x1f4eb8('0x2b')]=0x4,this[_0x1f4eb8('0xb')]=_0x1f4eb8('0x8'),this[_0x1f4eb8('0x21')]=_0x1dfb5b[_0x1f4eb8('0x21')],this[_0x1f4eb8('0xd')]=_0x1dfb5b['type'],this[_0x1f4eb8('0x29')]=_0x1dfb5b[_0x1f4eb8('0xd')]===_0x1f4eb8('0x1c')?_0x1f4eb8('0x10'):_0x1dfb5b[_0x1f4eb8('0xd')],this[_0x1f4eb8('0xe')]=_0x1dfb5b[_0x1f4eb8('0xe')],this[_0x1f4eb8('0x0')]=_0x1dfb5b[_0x1f4eb8('0x0')],this['countnoanswerretry']=_0x1dfb5b[_0x1f4eb8('0x1')],this[_0x1f4eb8('0x7')]=_0x1dfb5b[_0x1f4eb8('0xe')]+_0x1dfb5b['countcongestionretry']+_0x1dfb5b[_0x1f4eb8('0x1')]+_0x1dfb5b[_0x1f4eb8('0x28')]+_0x1dfb5b['countdropretry']+_0x1dfb5b['countabandonedretry']+_0x1dfb5b[_0x1f4eb8('0x13')]+_0x1dfb5b[_0x1f4eb8('0x12')],this['countnosuchnumberretry']=_0x1dfb5b[_0x1f4eb8('0x28')],this[_0x1f4eb8('0x18')]=_0x1dfb5b['countdropretry'],this[_0x1f4eb8('0xf')]=_0x1dfb5b[_0x1f4eb8('0xf')],this[_0x1f4eb8('0x13')]=_0x1dfb5b['countmachineretry'],this[_0x1f4eb8('0x12')]=_0x1dfb5b[_0x1f4eb8('0x12')],this[_0x1f4eb8('0x15')]=_0x7036[_0x1f4eb8('0x15')],this[_0x1f4eb8('0x19')]=_0x1dfb5b['name'],this[_0x1f4eb8('0x1e')]=_0x1dfb5b[_0x1f4eb8('0x2')],this[_0x1f4eb8('0x9')]=_0x1dfb5b['starttime'],this[_0x1f4eb8('0x14')]=_0x1dfb5b[_0x1f4eb8('0x14')],this[_0x1f4eb8('0x20')]=_0x1dfb5b[_0x1f4eb8('0x20')],this[_0x1f4eb8('0x1f')]=moment()['format'](_0x1f4eb8('0x3')),this['ringtime']=getSeconds(_0x1dfb5b[_0x1f4eb8('0x14')],_0x1dfb5b['starttime']),this['holdtime']=getSeconds(_0x1dfb5b['answertime'],_0x1dfb5b[_0x1f4eb8('0x14')]),this[_0x1f4eb8('0xc')]=getSeconds(this[_0x1f4eb8('0x1f')],_0x1dfb5b[_0x1f4eb8('0x20')]),this[_0x1f4eb8('0x10')]=_0x7036[_0x1f4eb8('0x10')],this[_0x1f4eb8('0x2a')]=_0x7036[_0x1f4eb8('0x2a')],this['reason']=_0x7036[_0x1f4eb8('0x11')],this[_0x1f4eb8('0x25')]=_0x1dfb5b['callback'],this['callbackuniqueid']=_0x1dfb5b[_0x1f4eb8('0x23')],this[_0x1f4eb8('0x27')]=_0x1dfb5b[_0x1f4eb8('0x27')],this[_0x1f4eb8('0x22')]=_0x1dfb5b[_0x1f4eb8('0x22')],this['ContactId']=_0x1dfb5b[_0x1f4eb8('0x4')],this[_0x1f4eb8('0x24')]=_0x1dfb5b[_0x1f4eb8('0x24')],this[_0x1f4eb8('0x6')]=_0x1dfb5b[_0x1f4eb8('0x6')],this[_0x1f4eb8('0xa')]=_0x1dfb5b[_0x1f4eb8('0xa')],this['CampaignId']=_0x1dfb5b[_0x1f4eb8('0x1a')],this[_0x1f4eb8('0x16')]=_0x1dfb5b[_0x1f4eb8('0x16')]||'',this[_0x1f4eb8('0x1d')]=_0x1dfb5b[_0x1f4eb8('0x1d')]||'';}module[_0x279e83('0x5')]=AgentComplete; \ No newline at end of file +const a1053_0x4d4c=['format','responsetime','countnoanswerretry','YYYY-MM-DD\x20HH:mm:ss','countbusyretry','calleridnum','VoiceQueueId','countmachineretry','answertime','queue','membername','ContactId','callbackat','diff','endtime','calleridname','callbackuniqueid','outbound','Answer','UserId','statedesc','countagentrejectretry','countdropretry','originatecalleridname','ListId','starttime','milliseconds','countcongestionretry','countnosuchnumberretry','originatecalleridnum','ringtime','CampaignId','uniqueid','countglobal','callback','scheduledat','talktime','type','holdtime','moment','recallme','countabandonedretry'];(function(_0x4af57d,_0x4d4cf4){const _0x52c945=function(_0x42d213){while(--_0x42d213){_0x4af57d['push'](_0x4af57d['shift']());}};_0x52c945(++_0x4d4cf4);}(a1053_0x4d4c,0x12d));const a1053_0x52c9=function(_0x4af57d,_0x4d4cf4){_0x4af57d=_0x4af57d-0x0;let _0x52c945=a1053_0x4d4c[_0x4af57d];return _0x52c945;};const _0x1d9fee=a1053_0x52c9;'use strict';const moment=require(_0x1d9fee('0x20'));function getSeconds(_0x42d213,_0x35b371){const _0x157a14=_0x1d9fee,_0x3eda19=moment(_0x42d213)[_0x157a14('0x13')](0x0),_0x11ec75=moment(_0x35b371)[_0x157a14('0x13')](0x0);return _0x3eda19[_0x157a14('0x6')](_0x11ec75,'seconds');}function AgentComplete(_0x4d4853,_0x310fec){const _0x1a6a0b=_0x1d9fee;this['state']=0x4,this[_0x1a6a0b('0xd')]=_0x1a6a0b('0xb'),this[_0x1a6a0b('0x1c')]=_0x4d4853[_0x1a6a0b('0x1c')],this['type']=_0x4d4853[_0x1a6a0b('0x1e')],this['campaigntype']=_0x4d4853[_0x1a6a0b('0x1e')]===_0x1a6a0b('0xa')?_0x1a6a0b('0x2'):_0x4d4853['type'],this['countbusyretry']=_0x4d4853[_0x1a6a0b('0x27')],this[_0x1a6a0b('0x14')]=_0x4d4853[_0x1a6a0b('0x14')],this[_0x1a6a0b('0x25')]=_0x4d4853[_0x1a6a0b('0x25')],this[_0x1a6a0b('0x1a')]=_0x4d4853['countbusyretry']+_0x4d4853[_0x1a6a0b('0x14')]+_0x4d4853[_0x1a6a0b('0x25')]+_0x4d4853[_0x1a6a0b('0x15')]+_0x4d4853[_0x1a6a0b('0xf')]+_0x4d4853[_0x1a6a0b('0x22')]+_0x4d4853[_0x1a6a0b('0x0')]+_0x4d4853['countagentrejectretry'],this[_0x1a6a0b('0x15')]=_0x4d4853[_0x1a6a0b('0x15')],this[_0x1a6a0b('0xf')]=_0x4d4853[_0x1a6a0b('0xf')],this[_0x1a6a0b('0x22')]=_0x4d4853['countabandonedretry'],this['countmachineretry']=_0x4d4853[_0x1a6a0b('0x0')],this[_0x1a6a0b('0xe')]=_0x4d4853[_0x1a6a0b('0xe')],this[_0x1a6a0b('0x19')]=_0x310fec[_0x1a6a0b('0x19')],this[_0x1a6a0b('0x8')]=_0x4d4853['name'],this[_0x1a6a0b('0x28')]=_0x4d4853['number'],this['starttime']=_0x4d4853['starttime'],this[_0x1a6a0b('0x24')]=_0x4d4853['responsetime'],this['answertime']=_0x4d4853[_0x1a6a0b('0x1')],this[_0x1a6a0b('0x7')]=moment()[_0x1a6a0b('0x23')](_0x1a6a0b('0x26')),this[_0x1a6a0b('0x17')]=getSeconds(_0x4d4853[_0x1a6a0b('0x24')],_0x4d4853[_0x1a6a0b('0x12')]),this[_0x1a6a0b('0x1f')]=getSeconds(_0x4d4853['answertime'],_0x4d4853[_0x1a6a0b('0x24')]),this[_0x1a6a0b('0x1d')]=getSeconds(this[_0x1a6a0b('0x7')],_0x4d4853[_0x1a6a0b('0x1')]),this[_0x1a6a0b('0x2')]=_0x310fec['queue'],this[_0x1a6a0b('0x3')]=_0x310fec[_0x1a6a0b('0x3')],this['reason']=_0x310fec['reason'],this[_0x1a6a0b('0x1b')]=_0x4d4853[_0x1a6a0b('0x1b')],this[_0x1a6a0b('0x9')]=_0x4d4853[_0x1a6a0b('0x9')],this['callbackat']=_0x4d4853[_0x1a6a0b('0x5')],this['recallme']=_0x4d4853[_0x1a6a0b('0x21')],this[_0x1a6a0b('0x4')]=_0x4d4853[_0x1a6a0b('0x4')],this['ListId']=_0x4d4853[_0x1a6a0b('0x11')],this[_0x1a6a0b('0xc')]=_0x4d4853[_0x1a6a0b('0xc')],this[_0x1a6a0b('0x29')]=_0x4d4853['VoiceQueueId'],this[_0x1a6a0b('0x18')]=_0x4d4853[_0x1a6a0b('0x18')],this['originatecalleridnum']=_0x4d4853[_0x1a6a0b('0x16')]||'',this[_0x1a6a0b('0x10')]=_0x4d4853[_0x1a6a0b('0x10')]||'';}module['exports']=AgentComplete; \ No newline at end of file diff --git a/server/services/ami/dialer/final.js b/server/services/ami/dialer/final.js index 85b0f9e..e810caa 100644 --- a/server/services/ami/dialer/final.js +++ b/server/services/ami/dialer/final.js @@ -1 +1 @@ -var a1054_0x7be9=['countcongestionretry','starttime','talktime','originatecalleridnum','ListId','countbusyretry','countnosuchnumberretry','CampaignId','responsetime','UserId','callbackat','outbound','countglobal','countdropretry','originatecalleridname','ContactId','recallme','callback','scheduledat','endtime','calleridname','campaigntype','exports','uniqueid','ringtime','countabandonedretry','countnoanswerretry','VoiceQueueId','queue','countagentrejectretry','type','countmachineretry','calleridnum','holdtime','callbackuniqueid'];(function(_0x11e3e5,_0x7be91c){var _0x25efb8=function(_0x17713c){while(--_0x17713c){_0x11e3e5['push'](_0x11e3e5['shift']());}};_0x25efb8(++_0x7be91c);}(a1054_0x7be9,0xf8));var a1054_0x25ef=function(_0x11e3e5,_0x7be91c){_0x11e3e5=_0x11e3e5-0x0;var _0x25efb8=a1054_0x7be9[_0x11e3e5];return _0x25efb8;};var _0x2c2b4b=a1054_0x25ef;'use strict';function Final(_0x17713c){var _0x263275=a1054_0x25ef;this[_0x263275('0x14')]=_0x17713c[_0x263275('0x14')],this[_0x263275('0xf')]=_0x17713c[_0x263275('0xf')],this[_0x263275('0x1b')]=_0x17713c[_0x263275('0x1b')],this[_0x263275('0x12')]=_0x17713c[_0x263275('0x1b')]===_0x263275('0x8')?'queue':_0x17713c[_0x263275('0x1b')],this[_0x263275('0x2')]=_0x17713c[_0x263275('0x2')],this[_0x263275('0x20')]=_0x17713c[_0x263275('0x20')],this[_0x263275('0x17')]=_0x17713c[_0x263275('0x17')],this[_0x263275('0x9')]=_0x17713c[_0x263275('0x2')]+_0x17713c[_0x263275('0x20')]+_0x17713c[_0x263275('0x17')]+_0x17713c[_0x263275('0x3')]+_0x17713c[_0x263275('0xa')]+_0x17713c[_0x263275('0x16')]+_0x17713c[_0x263275('0x1c')]+_0x17713c[_0x263275('0x1a')],this['countnosuchnumberretry']=_0x17713c[_0x263275('0x3')],this[_0x263275('0xa')]=_0x17713c['countdropretry'],this[_0x263275('0x16')]=_0x17713c[_0x263275('0x16')],this['countmachineretry']=_0x17713c[_0x263275('0x1c')],this[_0x263275('0x1a')]=_0x17713c[_0x263275('0x1a')],this[_0x263275('0x19')]=_0x17713c[_0x263275('0x19')],this[_0x263275('0x11')]=_0x17713c['calleridname'],this[_0x263275('0x1d')]=_0x17713c['calleridnum'],this[_0x263275('0x21')]=_0x17713c[_0x263275('0x21')],this['responsetime']=_0x17713c[_0x263275('0x5')],this[_0x263275('0x10')]=_0x17713c[_0x263275('0x5')],this[_0x263275('0x15')]=_0x17713c['ringtime']||0x0,this[_0x263275('0x1e')]=_0x17713c[_0x263275('0x1e')]||0x0,this[_0x263275('0x22')]=_0x17713c[_0x263275('0x22')]||0x0,this[_0x263275('0xe')]=_0x17713c[_0x263275('0xe')],this[_0x263275('0x1f')]=_0x17713c['callbackuniqueid'],this[_0x263275('0x7')]=_0x17713c[_0x263275('0x7')],this['recallme']=_0x17713c[_0x263275('0xd')],this['ContactId']=_0x17713c[_0x263275('0xc')],this[_0x263275('0x1')]=_0x17713c[_0x263275('0x1')],this[_0x263275('0x6')]=_0x17713c[_0x263275('0x6')],this[_0x263275('0x18')]=_0x17713c[_0x263275('0x18')],this[_0x263275('0x4')]=_0x17713c[_0x263275('0x4')],this[_0x263275('0x0')]=_0x17713c[_0x263275('0x0')]||'',this['originatecalleridname']=_0x17713c[_0x263275('0xb')]||'';}module[_0x2c2b4b('0x13')]=Final; \ No newline at end of file +var a1054_0x37f2=['countcongestionretry','CampaignId','responsetime','recallme','countagentrejectretry','starttime','countnoanswerretry','holdtime','scheduledat','countglobal','talktime','countdropretry','originatecalleridnum','endtime','ringtime','calleridname','exports','queue','uniqueid','calleridnum','callbackuniqueid','UserId','countabandonedretry','originatecalleridname','countnosuchnumberretry','callbackat','countbusyretry','countmachineretry','outbound','VoiceQueueId','campaigntype','type'];(function(_0x47ea06,_0x37f24f){var _0x55de4e=function(_0x7f69d4){while(--_0x7f69d4){_0x47ea06['push'](_0x47ea06['shift']());}};_0x55de4e(++_0x37f24f);}(a1054_0x37f2,0x152));var a1054_0x55de=function(_0x47ea06,_0x37f24f){_0x47ea06=_0x47ea06-0x0;var _0x55de4e=a1054_0x37f2[_0x47ea06];return _0x55de4e;};var _0x20f4c1=a1054_0x55de;'use strict';function Final(_0x7f69d4){var _0x5e4ab3=a1054_0x55de;this[_0x5e4ab3('0x0')]=_0x7f69d4[_0x5e4ab3('0x0')],this[_0x5e4ab3('0x16')]=_0x7f69d4['scheduledat'],this['type']=_0x7f69d4[_0x5e4ab3('0xd')],this[_0x5e4ab3('0xc')]=_0x7f69d4[_0x5e4ab3('0xd')]===_0x5e4ab3('0xa')?_0x5e4ab3('0x1f'):_0x7f69d4[_0x5e4ab3('0xd')],this['countbusyretry']=_0x7f69d4[_0x5e4ab3('0x8')],this[_0x5e4ab3('0xe')]=_0x7f69d4[_0x5e4ab3('0xe')],this[_0x5e4ab3('0x14')]=_0x7f69d4['countnoanswerretry'],this[_0x5e4ab3('0x17')]=_0x7f69d4[_0x5e4ab3('0x8')]+_0x7f69d4[_0x5e4ab3('0xe')]+_0x7f69d4[_0x5e4ab3('0x14')]+_0x7f69d4['countnosuchnumberretry']+_0x7f69d4[_0x5e4ab3('0x19')]+_0x7f69d4[_0x5e4ab3('0x4')]+_0x7f69d4[_0x5e4ab3('0x9')]+_0x7f69d4[_0x5e4ab3('0x12')],this[_0x5e4ab3('0x6')]=_0x7f69d4['countnosuchnumberretry'],this['countdropretry']=_0x7f69d4['countdropretry'],this[_0x5e4ab3('0x4')]=_0x7f69d4[_0x5e4ab3('0x4')],this[_0x5e4ab3('0x9')]=_0x7f69d4[_0x5e4ab3('0x9')],this[_0x5e4ab3('0x12')]=_0x7f69d4[_0x5e4ab3('0x12')],this['queue']=_0x7f69d4[_0x5e4ab3('0x1f')],this[_0x5e4ab3('0x1d')]=_0x7f69d4[_0x5e4ab3('0x1d')],this[_0x5e4ab3('0x1')]=_0x7f69d4['calleridnum'],this['starttime']=_0x7f69d4[_0x5e4ab3('0x13')],this[_0x5e4ab3('0x10')]=_0x7f69d4[_0x5e4ab3('0x10')],this[_0x5e4ab3('0x1b')]=_0x7f69d4[_0x5e4ab3('0x10')],this[_0x5e4ab3('0x1c')]=_0x7f69d4[_0x5e4ab3('0x1c')]||0x0,this[_0x5e4ab3('0x15')]=_0x7f69d4[_0x5e4ab3('0x15')]||0x0,this[_0x5e4ab3('0x18')]=_0x7f69d4[_0x5e4ab3('0x18')]||0x0,this['callback']=_0x7f69d4['callback'],this['callbackuniqueid']=_0x7f69d4[_0x5e4ab3('0x2')],this[_0x5e4ab3('0x7')]=_0x7f69d4[_0x5e4ab3('0x7')],this['recallme']=_0x7f69d4[_0x5e4ab3('0x11')],this['ContactId']=_0x7f69d4['ContactId'],this['ListId']=_0x7f69d4['ListId'],this['UserId']=_0x7f69d4[_0x5e4ab3('0x3')],this[_0x5e4ab3('0xb')]=_0x7f69d4[_0x5e4ab3('0xb')],this[_0x5e4ab3('0xf')]=_0x7f69d4[_0x5e4ab3('0xf')],this[_0x5e4ab3('0x1a')]=_0x7f69d4[_0x5e4ab3('0x1a')]||'',this[_0x5e4ab3('0x5')]=_0x7f69d4['originatecalleridname']||'';}module[_0x20f4c1('0x1e')]=Final; \ No newline at end of file diff --git a/server/services/ami/dialer/hangup.js b/server/services/ami/dialer/hangup.js index 4f544e8..b119baa 100644 --- a/server/services/ami/dialer/hangup.js +++ b/server/services/ami/dialer/hangup.js @@ -1 +1 @@ -const a1055_0x3236=['queue','countabandonedretry','holdtime','number','Answer','starttime','CampaignId','callbackat','name','responsetime','endtime','callbackuniqueid','reason','countmachineretry','countnosuchnumberretry','moment','exports','state','UserId','YYYY-MM-DD\x20HH:mm:ss','scheduledat','statedesc','countglobal','seconds','calleridname','format','cause-txt','ListId','membername','talktime','milliseconds','countdropretry','recallme','countagentrejectretry','campaigntype','countcongestionretry','ringtime','countbusyretry','countnoanswerretry','type'];(function(_0x405f89,_0x3236cb){const _0x243081=function(_0x2bfac2){while(--_0x2bfac2){_0x405f89['push'](_0x405f89['shift']());}};_0x243081(++_0x3236cb);}(a1055_0x3236,0x9f));const a1055_0x2430=function(_0x405f89,_0x3236cb){_0x405f89=_0x405f89-0x0;let _0x243081=a1055_0x3236[_0x405f89];return _0x243081;};const _0x5184aa=a1055_0x2430;'use strict';const moment=require(_0x5184aa('0x10'));function getSeconds(_0x2bfac2,_0x16d0d1){const _0x45a1d2=_0x5184aa,_0xf3a559=moment(_0x2bfac2)[_0x45a1d2('0x1f')](0x0),_0x53cbd3=moment(_0x16d0d1)['milliseconds'](0x0);return _0xf3a559['diff'](_0x53cbd3,_0x45a1d2('0x18'));}function Hangup(_0x3defd3,_0x5c5787){const _0x350f02=_0x5184aa;this[_0x350f02('0x12')]=0x4,this[_0x350f02('0x16')]=_0x350f02('0x5'),this[_0x350f02('0x15')]=_0x3defd3['scheduledat'],this[_0x350f02('0x0')]=_0x3defd3[_0x350f02('0x0')],this[_0x350f02('0x23')]=_0x3defd3['type']==='outbound'?_0x350f02('0x1'):_0x3defd3['type'],this[_0x350f02('0x26')]=_0x3defd3[_0x350f02('0x26')],this['countcongestionretry']=_0x3defd3[_0x350f02('0x24')],this[_0x350f02('0x27')]=_0x3defd3[_0x350f02('0x27')],this[_0x350f02('0x17')]=_0x3defd3['countbusyretry']+_0x3defd3[_0x350f02('0x24')]+_0x3defd3[_0x350f02('0x27')]+_0x3defd3[_0x350f02('0xf')]+_0x3defd3[_0x350f02('0x20')]+_0x3defd3[_0x350f02('0x2')]+_0x3defd3[_0x350f02('0xe')]+_0x3defd3[_0x350f02('0x22')],this[_0x350f02('0xf')]=_0x3defd3[_0x350f02('0xf')],this['countdropretry']=_0x3defd3[_0x350f02('0x20')],this[_0x350f02('0x2')]=_0x3defd3[_0x350f02('0x2')],this[_0x350f02('0xe')]=_0x3defd3[_0x350f02('0xe')],this[_0x350f02('0x22')]=_0x3defd3[_0x350f02('0x22')],this['uniqueid']=_0x5c5787['uniqueid'],this[_0x350f02('0x19')]=_0x3defd3[_0x350f02('0x9')],this['calleridnum']=_0x3defd3[_0x350f02('0x4')],this[_0x350f02('0x6')]=_0x3defd3[_0x350f02('0x6')],this[_0x350f02('0xa')]=_0x3defd3[_0x350f02('0xa')],this[_0x350f02('0xb')]=moment()[_0x350f02('0x1a')](_0x350f02('0x14')),this[_0x350f02('0x25')]=getSeconds(_0x3defd3[_0x350f02('0xa')],_0x3defd3[_0x350f02('0x6')]),this[_0x350f02('0x3')]=0x0,this[_0x350f02('0x1e')]=getSeconds(this['endtime'],_0x3defd3[_0x350f02('0xa')]),this['queue']=_0x3defd3[_0x350f02('0x1')],this[_0x350f02('0x1d')]='IVR',this[_0x350f02('0xd')]=_0x5c5787[_0x350f02('0x1b')],this['callback']=_0x3defd3['callback'],this[_0x350f02('0xc')]=_0x3defd3[_0x350f02('0xc')],this[_0x350f02('0x8')]=_0x3defd3[_0x350f02('0x8')],this['recallme']=_0x3defd3[_0x350f02('0x21')],this['ContactId']=_0x3defd3['ContactId'],this[_0x350f02('0x1c')]=_0x3defd3[_0x350f02('0x1c')],this['UserId']=_0x3defd3[_0x350f02('0x13')],this['VoiceQueueId']=_0x3defd3['VoiceQueueId'],this[_0x350f02('0x7')]=_0x3defd3['CampaignId'];}module[_0x5184aa('0x11')]=Hangup; \ No newline at end of file +const a1055_0x566c=['name','calleridname','ListId','UserId','moment','type','cause-txt','scheduledat','starttime','callbackuniqueid','exports','format','countglobal','countnoanswerretry','number','talktime','countmachineretry','recallme','callback','state','responsetime','CampaignId','milliseconds','outbound','queue','VoiceQueueId','countabandonedretry','ContactId','callbackat','countbusyretry','YYYY-MM-DD\x20HH:mm:ss','countdropretry','calleridnum','countagentrejectretry','uniqueid','countnosuchnumberretry','diff','holdtime','endtime','countcongestionretry','statedesc','IVR','campaigntype','seconds'];(function(_0x1a6b26,_0x566c31){const _0x4b270c=function(_0x5af039){while(--_0x5af039){_0x1a6b26['push'](_0x1a6b26['shift']());}};_0x4b270c(++_0x566c31);}(a1055_0x566c,0x1c6));const a1055_0x4b27=function(_0x1a6b26,_0x566c31){_0x1a6b26=_0x1a6b26-0x0;let _0x4b270c=a1055_0x566c[_0x1a6b26];return _0x4b270c;};const _0x2e5149=a1055_0x4b27;'use strict';const moment=require(_0x2e5149('0x22'));function getSeconds(_0x5af039,_0x315a22){const _0x5c8829=_0x2e5149,_0x312170=moment(_0x5af039)['milliseconds'](0x0),_0x5992ef=moment(_0x315a22)[_0x5c8829('0x8')](0x0);return _0x312170[_0x5c8829('0x16')](_0x5992ef,_0x5c8829('0x1d'));}function Hangup(_0x1781fe,_0x159f8a){const _0x45be10=_0x2e5149;this[_0x45be10('0x5')]=0x4,this[_0x45be10('0x1a')]='Answer',this[_0x45be10('0x25')]=_0x1781fe[_0x45be10('0x25')],this[_0x45be10('0x23')]=_0x1781fe[_0x45be10('0x23')],this[_0x45be10('0x1c')]=_0x1781fe[_0x45be10('0x23')]===_0x45be10('0x9')?_0x45be10('0xa'):_0x1781fe['type'],this['countbusyretry']=_0x1781fe[_0x45be10('0xf')],this[_0x45be10('0x19')]=_0x1781fe[_0x45be10('0x19')],this[_0x45be10('0x2b')]=_0x1781fe[_0x45be10('0x2b')],this[_0x45be10('0x2a')]=_0x1781fe[_0x45be10('0xf')]+_0x1781fe[_0x45be10('0x19')]+_0x1781fe[_0x45be10('0x2b')]+_0x1781fe[_0x45be10('0x15')]+_0x1781fe[_0x45be10('0x11')]+_0x1781fe[_0x45be10('0xc')]+_0x1781fe[_0x45be10('0x2')]+_0x1781fe[_0x45be10('0x13')],this[_0x45be10('0x15')]=_0x1781fe['countnosuchnumberretry'],this[_0x45be10('0x11')]=_0x1781fe[_0x45be10('0x11')],this[_0x45be10('0xc')]=_0x1781fe['countabandonedretry'],this['countmachineretry']=_0x1781fe[_0x45be10('0x2')],this['countagentrejectretry']=_0x1781fe[_0x45be10('0x13')],this[_0x45be10('0x14')]=_0x159f8a[_0x45be10('0x14')],this[_0x45be10('0x1f')]=_0x1781fe[_0x45be10('0x1e')],this[_0x45be10('0x12')]=_0x1781fe[_0x45be10('0x0')],this[_0x45be10('0x26')]=_0x1781fe['starttime'],this[_0x45be10('0x6')]=_0x1781fe[_0x45be10('0x6')],this[_0x45be10('0x18')]=moment()[_0x45be10('0x29')](_0x45be10('0x10')),this['ringtime']=getSeconds(_0x1781fe[_0x45be10('0x6')],_0x1781fe['starttime']),this[_0x45be10('0x17')]=0x0,this[_0x45be10('0x1')]=getSeconds(this[_0x45be10('0x18')],_0x1781fe[_0x45be10('0x6')]),this[_0x45be10('0xa')]=_0x1781fe[_0x45be10('0xa')],this['membername']=_0x45be10('0x1b'),this['reason']=_0x159f8a[_0x45be10('0x24')],this['callback']=_0x1781fe[_0x45be10('0x4')],this[_0x45be10('0x27')]=_0x1781fe[_0x45be10('0x27')],this[_0x45be10('0xe')]=_0x1781fe[_0x45be10('0xe')],this[_0x45be10('0x3')]=_0x1781fe[_0x45be10('0x3')],this[_0x45be10('0xd')]=_0x1781fe[_0x45be10('0xd')],this[_0x45be10('0x20')]=_0x1781fe['ListId'],this[_0x45be10('0x21')]=_0x1781fe[_0x45be10('0x21')],this[_0x45be10('0xb')]=_0x1781fe[_0x45be10('0xb')],this[_0x45be10('0x7')]=_0x1781fe['CampaignId'];}module[_0x2e5149('0x28')]=Hangup; \ No newline at end of file diff --git a/server/services/ami/dialer/history.js b/server/services/ami/dialer/history.js index 04bbb39..0dbf436 100644 --- a/server/services/ami/dialer/history.js +++ b/server/services/ami/dialer/history.js @@ -1 +1 @@ -const a1056_0x4f6d=['ListId','originatecalleridnum','countmachineretry','callback','responsetime','calleridname','starttime','countdropretry','exports','ringtime','calleridnum','UserId','type','recallme','campaigntype','moment','countcongestionretry','countbusyretry','diff','countabandonedretry','scheduledat','countnosuchnumberretry','name','uniqueid','countnoanswerretry','outbound','VoiceQueueId','ContactId','endtime','holdtime','originatecalleridname','number','callbackat','milliseconds','callbackuniqueid','CampaignId','countagentrejectretry','queue','talktime'];(function(_0x40f7c2,_0x4f6d98){const _0x8f804e=function(_0x10bebe){while(--_0x10bebe){_0x40f7c2['push'](_0x40f7c2['shift']());}};_0x8f804e(++_0x4f6d98);}(a1056_0x4f6d,0x181));const a1056_0x8f80=function(_0x40f7c2,_0x4f6d98){_0x40f7c2=_0x40f7c2-0x0;let _0x8f804e=a1056_0x4f6d[_0x40f7c2];return _0x8f804e;};const _0x552549=a1056_0x8f80;'use strict';const moment=require(_0x552549('0x14'));function getSeconds(_0x10bebe,_0x4df40f){const _0x479e38=_0x552549,_0x11899c=moment(_0x10bebe)[_0x479e38('0x26')](0x0),_0x1c9a98=moment(_0x4df40f)[_0x479e38('0x26')](0x0);return _0x11899c[_0x479e38('0x17')](_0x1c9a98,'seconds');}function History(_0x5871b7){const _0x82e2bf=_0x552549;this[_0x82e2bf('0x1c')]=_0x5871b7[_0x82e2bf('0x1c')],this[_0x82e2bf('0x19')]=_0x5871b7[_0x82e2bf('0x19')]||undefined,this[_0x82e2bf('0x11')]=_0x5871b7[_0x82e2bf('0x11')],this[_0x82e2bf('0x13')]=_0x5871b7[_0x82e2bf('0x11')]===_0x82e2bf('0x1e')?_0x82e2bf('0x3'):_0x5871b7['type'],this[_0x82e2bf('0x16')]=_0x5871b7[_0x82e2bf('0x16')],this[_0x82e2bf('0x15')]=_0x5871b7['countcongestionretry'],this[_0x82e2bf('0x1d')]=_0x5871b7['countnoanswerretry'],this['countglobal']=_0x5871b7[_0x82e2bf('0x16')]+_0x5871b7[_0x82e2bf('0x15')]+_0x5871b7[_0x82e2bf('0x1d')]+_0x5871b7[_0x82e2bf('0x1a')]+_0x5871b7[_0x82e2bf('0xc')]+_0x5871b7[_0x82e2bf('0x18')]+_0x5871b7[_0x82e2bf('0x7')]+_0x5871b7['countagentrejectretry'],this[_0x82e2bf('0x1a')]=_0x5871b7[_0x82e2bf('0x1a')],this[_0x82e2bf('0xc')]=_0x5871b7['countdropretry'],this[_0x82e2bf('0x18')]=_0x5871b7[_0x82e2bf('0x18')],this[_0x82e2bf('0x7')]=_0x5871b7[_0x82e2bf('0x7')],this['countagentrejectretry']=_0x5871b7[_0x82e2bf('0x2')],this[_0x82e2bf('0x3')]=_0x5871b7[_0x82e2bf('0x3')],this[_0x82e2bf('0xa')]=_0x5871b7[_0x82e2bf('0x1b')],this[_0x82e2bf('0xf')]=_0x5871b7[_0x82e2bf('0x24')],this[_0x82e2bf('0xb')]=_0x5871b7['starttime'],this['responsetime']=_0x5871b7['responsetime'],this[_0x82e2bf('0x21')]=_0x5871b7[_0x82e2bf('0x9')],this[_0x82e2bf('0xe')]=getSeconds(_0x5871b7['responsetime'],_0x5871b7[_0x82e2bf('0xb')]),this[_0x82e2bf('0x22')]=0x0,this[_0x82e2bf('0x4')]=0x0,this[_0x82e2bf('0x8')]=_0x5871b7[_0x82e2bf('0x8')],this[_0x82e2bf('0x0')]=_0x5871b7['callbackuniqueid'],this[_0x82e2bf('0x25')]=_0x5871b7[_0x82e2bf('0x25')],this[_0x82e2bf('0x12')]=_0x5871b7['recallme'],this[_0x82e2bf('0x20')]=_0x5871b7['ContactId'],this[_0x82e2bf('0x5')]=_0x5871b7[_0x82e2bf('0x5')],this[_0x82e2bf('0x10')]=_0x5871b7[_0x82e2bf('0x10')],this[_0x82e2bf('0x1f')]=_0x5871b7[_0x82e2bf('0x1f')],this['CampaignId']=_0x5871b7[_0x82e2bf('0x1')],this[_0x82e2bf('0x6')]=_0x5871b7[_0x82e2bf('0x6')]||'',this[_0x82e2bf('0x23')]=_0x5871b7[_0x82e2bf('0x23')]||'';}module[_0x552549('0xd')]=History; \ No newline at end of file +const a1056_0x4a05=['recallme','countnoanswerretry','originatecalleridnum','endtime','callbackuniqueid','diff','countabandonedretry','milliseconds','queue','starttime','number','callback','originatecalleridname','countglobal','exports','CampaignId','callbackat','outbound','countbusyretry','countdropretry','seconds','responsetime','uniqueid','ListId','talktime','countagentrejectretry','scheduledat','holdtime','campaigntype','type','ContactId','countcongestionretry','countnosuchnumberretry','UserId','calleridnum','countmachineretry'];(function(_0x57a0ad,_0x4a05e0){const _0x30cd20=function(_0x36d474){while(--_0x36d474){_0x57a0ad['push'](_0x57a0ad['shift']());}};_0x30cd20(++_0x4a05e0);}(a1056_0x4a05,0xcb));const a1056_0x30cd=function(_0x57a0ad,_0x4a05e0){_0x57a0ad=_0x57a0ad-0x0;let _0x30cd20=a1056_0x4a05[_0x57a0ad];return _0x30cd20;};const _0x5c5659=a1056_0x30cd;'use strict';const moment=require('moment');function getSeconds(_0x36d474,_0x4d8c3b){const _0xa3e489=a1056_0x30cd,_0x5beb6a=moment(_0x36d474)['milliseconds'](0x0),_0x286ca9=moment(_0x4d8c3b)[_0xa3e489('0x14')](0x0);return _0x5beb6a[_0xa3e489('0x12')](_0x286ca9,_0xa3e489('0x21'));}function History(_0x5d5e0e){const _0x3b54e2=a1056_0x30cd;this[_0x3b54e2('0x23')]=_0x5d5e0e['uniqueid'],this[_0x3b54e2('0x3')]=_0x5d5e0e[_0x3b54e2('0x3')]||undefined,this[_0x3b54e2('0x6')]=_0x5d5e0e['type'],this[_0x3b54e2('0x5')]=_0x5d5e0e[_0x3b54e2('0x6')]===_0x3b54e2('0x1e')?_0x3b54e2('0x15'):_0x5d5e0e['type'],this[_0x3b54e2('0x1f')]=_0x5d5e0e[_0x3b54e2('0x1f')],this[_0x3b54e2('0x8')]=_0x5d5e0e[_0x3b54e2('0x8')],this[_0x3b54e2('0xe')]=_0x5d5e0e['countnoanswerretry'],this[_0x3b54e2('0x1a')]=_0x5d5e0e[_0x3b54e2('0x1f')]+_0x5d5e0e[_0x3b54e2('0x8')]+_0x5d5e0e[_0x3b54e2('0xe')]+_0x5d5e0e['countnosuchnumberretry']+_0x5d5e0e[_0x3b54e2('0x20')]+_0x5d5e0e[_0x3b54e2('0x13')]+_0x5d5e0e['countmachineretry']+_0x5d5e0e[_0x3b54e2('0x2')],this[_0x3b54e2('0x9')]=_0x5d5e0e[_0x3b54e2('0x9')],this[_0x3b54e2('0x20')]=_0x5d5e0e['countdropretry'],this[_0x3b54e2('0x13')]=_0x5d5e0e[_0x3b54e2('0x13')],this['countmachineretry']=_0x5d5e0e[_0x3b54e2('0xc')],this['countagentrejectretry']=_0x5d5e0e[_0x3b54e2('0x2')],this[_0x3b54e2('0x15')]=_0x5d5e0e[_0x3b54e2('0x15')],this['calleridname']=_0x5d5e0e['name'],this[_0x3b54e2('0xb')]=_0x5d5e0e[_0x3b54e2('0x17')],this[_0x3b54e2('0x16')]=_0x5d5e0e['starttime'],this[_0x3b54e2('0x22')]=_0x5d5e0e[_0x3b54e2('0x22')],this[_0x3b54e2('0x10')]=_0x5d5e0e[_0x3b54e2('0x22')],this['ringtime']=getSeconds(_0x5d5e0e['responsetime'],_0x5d5e0e[_0x3b54e2('0x16')]),this[_0x3b54e2('0x4')]=0x0,this[_0x3b54e2('0x1')]=0x0,this[_0x3b54e2('0x18')]=_0x5d5e0e['callback'],this[_0x3b54e2('0x11')]=_0x5d5e0e['callbackuniqueid'],this[_0x3b54e2('0x1d')]=_0x5d5e0e[_0x3b54e2('0x1d')],this[_0x3b54e2('0xd')]=_0x5d5e0e['recallme'],this['ContactId']=_0x5d5e0e[_0x3b54e2('0x7')],this[_0x3b54e2('0x0')]=_0x5d5e0e[_0x3b54e2('0x0')],this[_0x3b54e2('0xa')]=_0x5d5e0e['UserId'],this['VoiceQueueId']=_0x5d5e0e['VoiceQueueId'],this[_0x3b54e2('0x1c')]=_0x5d5e0e['CampaignId'],this['originatecalleridnum']=_0x5d5e0e[_0x3b54e2('0xf')]||'',this[_0x3b54e2('0x19')]=_0x5d5e0e[_0x3b54e2('0x19')]||'';}module[_0x5c5659('0x1b')]=History; \ No newline at end of file diff --git a/server/services/ami/dialer/index.js b/server/services/ami/dialer/index.js index 2b70647..6e91087 100644 --- a/server/services/ami/dialer/index.js +++ b/server/services/ami/dialer/index.js @@ -1 +1 @@ -const a1057_0x2af8=['syncHangup','checkIfTime','Contact\x20updated','loggedInDb','syncQueueCallerAbandon','[unlockContact]\x20','busyFactor','syncAgentComplete','busy','---------------------------','predictiveIntervalTotalCalls','queuestatuscomplete','[syncQueueSummary]','name','NONE','tags','Dropped\x20calls\x20day','inBlackList','dialAMDTotalAnalysisTime','[syncAgentComplete][createHistory]','temp','countnoanswerretry','Interval:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','dialPredictiveOptimizationPercentage','loggerHandler','createHistory','../ami','IS_DISACTIVED','endtime','abandonmentRate','queueBooked','reachable','agent','queueStatusComplete','active','../rpc/cmHopperHistory','checkIfTimeIntervals','Agent','[syncHangupInAMD]','outboundNoAnswerCallsDay','stateinterface','Ts\x20=\x20','contactAgent-idHopper:\x20','RECALLFAILEDTIMEOUT','[rescheduleContact]\x20[Busy]','[updateOriginated]\x20is\x20null\x20or\x20undefined','./final','erlangAbandonmentRate','CALLEREXIT','originate','dialDropMaxRetry','predictiveIntervalDroppedCallsTimeout','Interval','updateOriginated','dialCutDigit','launchHandleIvr','info','AgentReject','dialRecallInQueue','method\x20not\x20recognized','dialAMDActive','outboundAnswerAgiCallsDay','uniqueId','sumHoldTime','maxNumberOriginate','starttime','[startMethodPredictive][StartProgressive]','dialGlobalInterval','\x20NOT\x20Active','[abandonmentRate]','Max\x20Drop\x20','predictiveIntervalHitRate','voiceQueues','[getContactDialer2]','reason\x200\x20no\x20such\x20number....','AMD','amd','dialMachineRetryFrequency','countcongestionretry','agentconnect','custom:queuesummary','locked','SIP/%s','dialAMDMinWordLength','notFound','dialRecallMeTimeout','_rr','Dropped\x20Exit:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','getCaller','clearing\x20variable\x20start\x20progressive','outboundAbandonedCallsDay','message','unmonitored','nosuchnumber','syncNewExten','loggedIn','dialMachineMaxRetry','countnosuchnumberretry','timezones','dialDropRetryFrequency','[rescheduleContact][Machine]','queuestatus','[decremetOriginate]\x20object\x20originated\x20is\x20negative','dialAgentRejectRetryFrequency','Total\x20Calls:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','inspect','md5','createStateFinal','catch','ContactId','contact\x20not\x20moved','Umin:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20',')\x20are\x20less\x20than\x20threshold\x20(','syncQueueMember','dialGlobalMaxRetry','finally','erlangCallToSecond','contactsId',')\x20are\x20more\x20than\x20threshold\x20(','moment','XMD-AMDMINWORDLENGTH','predictiveCalls','createdAt','dialOriginateCallerIdName','membername','erlangBusyFactor','\x20Intervals\x20is\x20empty\x20','outboundUnknownCallsDay','dropreason','dialQueueOptions','merge','getContactDialer','channel','paused','check\x20failure','variable','[syncQueueSummary]\x20Campaign\x20Queue:\x20','campaign:ivr:%s','ListId','Agent:\x20','dialBusyRetryFrequency','dialOriginateCallerIdNumber','outboundOriginateFailureCallsDay','talking','predictiveIntervalAvailable','[stopMethodPredictive][ReStartProgressive][ExceededDropInterval]','[booked][RR]','\x22%s\x22\x20<%s>','dialBusyMaxRetry','responsetime','[countReScheduled]\x20','XMD-AMDMAXIMUMWORDLENGTH','milliseconds','[Originate][MoveBlacklist]','[getVoiceQueueRtPauses]\x20','Amax\x20=\x20','Machine','dialActive','stateGlobal','status','format','[unlock3][syncQueueStatusComplete]','total','amdstatus','Avg\x20Hold\x20Time\x20is\x20not\x20enough\x20for\x20predictive','Global','[syncAgentComplete][createHistory][5]','started\x20in\x20predictive\x20at','[syncAgentComplete][createHistory][0]','scheduledat','countReScheduled','string','SIP/%s/%s%s','countabandonedretry','dialLimitQueue','substring','RecallFailedTimeout','predictiveIntervalMultiplicativeFactor','XMD-CAMPAIGNID','dialPowerLevel','../rpc/cmHopper','AVG\x20Hold\x20Time:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','tryOriginatePredictive','seconds','handleIvr','queueStatusComplete:\x20','[CatchErlangB]','dialMethod','isSuccess','rrmemory','XMD-AMDMAXIMUMNUMBEROFWORDS','Scheduled\x20Calls:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','campaign:save','XMD-ORIGINATECALLERIDNUM','syncQueueStatusComplete','true','NOT_ACTIVE','add','queueBookedRR','../rpc/cmHopperBlack','outboundRejectCallsDay','dialPredictiveInterval','checkIsBlackListIvr','[syncAgentComplete][createHistory][10]','exten','calleridname','[syncAgentComplete][createHistory][20]','fail\x20to\x20scheduled\x20calls','TIMEZONE_UNKNOW','../preview/util/util','voicePause','Total\x20Calls\x20are\x20not\x20enough\x20for\x20predictive','outboundBusyCallsDay','../../../config/logger','recalculate\x20predictive\x20at','dialQueueProject','actionOriginate','INTERVAL_IS_EMPTY','clearing\x20variable\x20start\x20predictive','xcally-motion-dialer','ifTime','roundrobin','checkIsTrunkReachable','NoSuchNumber','switch\x20in\x20progressive\x20because\x20available\x20agents\x20(','agiafterat','XMD-AMDGREETING','TrunkBackup','dialCongestionMaxRetry','countbusyretry','actions','replace','[syncQueueSummary]\x20Campaign\x20Ivr:\x20','[rescheduleContact]\x20[Congestion]','push','trunks','sendMessageOneNotActive','all','[booked][RR][finaly]','MACHINE','./history','resolve','Queue','dialOrderByScheduledAt','getContactDialerIvr','[unlockOriginate][syncQueueStatusComplete]','getDataPredictive','Umin\x20=\x20','INTERVAL_IS_OVERTIME','countdropretry','moveContactManagedDialer','custom:agentnosuchnumber','XMD-AMDBETWEENWORDSSILENCE','[syncAgentComplete][createHistory][11]','trim','stack','XMD-AMDTOTALANALYSISTIME','predictiveIntervalDroppedCallsCallersExit','state','emit','undefined','bind','syncVarSet','recallme','sumDuration','strategy','uniqueid','countglobal','[Dialer][checkChannel]','m\x20=\x20','\x20Timezone\x20unknow\x20','iftime\x20%s,%s','[actionOriginatePredictive]\x20','[unlockQueueStatus][undefined]','Blacklist','pick','dialQueueTimeout','droptime','command','hangup','OriginateError','voice_queue:save','countmachineretry','syncAgentConnect','length','outboundAnswerCallsDay','agiIp','util','noanswer','outboundQueuePauses','dialAbandonedMaxRetry','isUndefined','[syncHangupIvr][createHistory]','NoAnswer','[syncHangupInAMDIvr][createHistory]','Drop\x20Rate:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','predictiveIntervalAvgHoldtime','No\x20such\x20channel','type','Failure','dialAMDBetweenWordsSilence','saveInDb','originated','power','handlePredictive','syncQueueSummary','[syncAgentComplete][createHistory][3]','outbound','interval','custom:agentcongestion','one\x20call\x20every:','RUNNING','[stopMethodPredictive][ReStartProgressive][ExceededDropDay]','round','Agent\x20Busy\x20Factor:\x20\x20\x20\x20\x20\x20\x20\x20\x20','Trunk','getVoiceQueueRtPauses','\x22%s,%s%s,,,%s\x22','[rescheduleContact][dialRecallInQueue]','progressive','checkContactBlack','is\x20disactive','countagentrejectretry','pow','[syncHangupInAMDIvr]','./queueCallerAbandon','callerid','ivrOriginated','erlangCalls','TIMEOUT','XMD-AMDAFTERGREETINGSILENCE','dialPrefix','dialNoSuchNumberMaxRetry','actionid','../rpc/voiceQueueRt','[Dialer][checkChannel][ivr]','XMD-','agentcomplete','YYYY-MM-DD\x20HH:mm:ss','XMD-VOICEQUEUEID','Busy','predictiveIntervalErlangCallsDroppedCalls','[callProgressDetecting]','random','queue','idHopper','Contact.phone','not_inuse','[Originate][HistoryRecallClose][historyCatch]','[checkIsBlackList]\x20','dialAMDInitialSilence','[emptyContact][createHistory]','[originate][error]','toUpper','queueCallerAbandonCreateState','outboundNoSuchCallsDay','answered','exports','agentreject','Contact','emptyContact','dialPredictiveOptimization','stringify','congestion','One\x20call\x20every:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','Success','run','Unknow','value','collection\x20data\x20in\x20progressive\x20at','Abandoned','unlockRR','custom:agentbusy','then','AVAILABLE_CONTACTS_FINISHED','Intervals','AnswerAGI','syncCampaigns','[rescheduleContact][NoAnswer]','[rescheduleContact][Drop]','answertime','[ifTime][Action]','Ts:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','AGENTS_NOT_LOGGED','[moveContactManagedDialer][0]','cause-txt','log','dialQueueProject2','available','match','error','Drop\x20in\x20this\x20interval','predictiveIntervalPauses','content','getQueue','TRUNK_IS_NOT_REACHABLE','enqueue','tail','[getDataPredictive]','-----\x20Stats\x20Predictive\x20---','[checkIsBlackListIvr]\x20','ACTIVE','XMD-ORIGINATECALLERIDNAME','dialNoSuchNumberRetryFrequency','P:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','checkIsBlackList','[unlock][syncQueueStatusComplete]','[getContactCampaign2]','[startMethodPredictive][StartProgressive][Loop]','[handlePredictive]','dialTimezone','outboundCongestionCallsDay','floor','avgHandleTime','handlePower','interval\x20=\x20','contactsRescheduled','predictiveIntervalAvgTalktime','pTalking','clearing\x20variable\x20handle\x20predictive','reason\x2019\x20machine....','outboundDropCallsDayACS','callProgressDetecting','[Originate][HistoryDialRecallInQueue][historyCatch]','\x22agi://%s/square,%s\x22','reason\x203\x20ringing\x20no\x20answer','object','../../../config/config.service','HANGUP','loopCampaigns','startProgressive','waiting','buildObj','is\x20not\x20active','./agentComplete','[booked][checkContactBlack][else]','campaigns','reason\x2011\x20abandoned','loopClearZombieChannels','dialer','prototype','CampaignId','dialAMDSilenceThreshold','dialAgiAfterHangupAgent','\x20Interval\x20is\x20overtime:\x20','isTrunkReachable','booked','agents','p\x20=\x20','----\x20Agent\x20Busy\x20Factor\x20----','[actionOriginate]\x20','dropRate','checkDialMethod','./hangup','clearZombieChannels','Error','dialAbandonedRetryFrequency','./action','sequence','[rescheduleContact]\x20','[syncCampaigns]','Answered\x20Calls:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','startPredictive','[getContactDialer]\x20','averageHandleTime','reason','[Originate][historyBlacklist]','outboundBlacklistCallsDay','dialRandomLastDigitCallerIdNumber','checkRetriveMax','predictiveIntervalAnsweredCalls','minutes','AGI','startMethodPredictive','predictive','phone','%s%s','Congestion','outboundDropCallsDayCallersExit','[handlePredictive][limitChannel]','custom:agentreject','contact\x20is\x20undefine','preview','[busyFactor]','outboundReCallsDay','Action','evt\x20is\x20undefine','INTERVAL_IS_NULL','AVG\x20Talk\x20Time:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','rescheduleContact','HangupInAMD','agentBusyFactor','unlockContact','ivr','---------\x20ErlangB\x20---------','Queue:\x20','calleridnum','../../../rediscache','GLOBAL_INTERVAL_IS_OVERTIME','predictiveIntervalErlangCalls','syncOriginateResponse','diff','isNil','outboundDropCallsDayTimeout','[uniqueid]','isEmpty','M:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','[syncHangupIvr]','[emptyContact]','[Originate][HistoryRecallClose]','uuid','[getContactDialerPredictive]','[booked][unlock2]','originate\x20action\x20Error','indexOf','../../../config/environment/','--------\x20Drop\x20Rate\x20--------','[actionOriginateIvr]\x20','VoiceQueueId','dialOriginateTimeout','reason\x205\x20busy','newexten','queuecallerabandon','reason\x2020\x20agentreject','contacts','statedesc','queuemember','from-sip','voiceQueue\x20is\x20undefine','originatecalleridname'];(function(_0x1c8411,_0x2af8c6){const _0x3d95d1=function(_0x207ef4){while(--_0x207ef4){_0x1c8411['push'](_0x1c8411['shift']());}};_0x3d95d1(++_0x2af8c6);}(a1057_0x2af8,0x77));const a1057_0x3d95=function(_0x1c8411,_0x2af8c6){_0x1c8411=_0x1c8411-0x0;let _0x3d95d1=a1057_0x2af8[_0x1c8411];return _0x3d95d1;};const _0x5be1a4=a1057_0x3d95;'use strict';const util=require(_0x5be1a4('0xa8')),_=require('lodash'),uuid=require(_0x5be1a4('0x187')),moment=require(_0x5be1a4('0x0')),rr=require('rr'),md5=require(_0x5be1a4('0x205')),ut=require(_0x5be1a4('0x5a')),config=require(_0x5be1a4('0x18c')),logger=require(_0x5be1a4('0x5e'))(_0x5be1a4('0x140')),loggerBooked=require(_0x5be1a4('0x5e'))('booked'),loggerPredictive=require(_0x5be1a4('0x5e'))(_0x5be1a4('0x163')),loggerPredictiveCalls=require(_0x5be1a4('0x5e'))(_0x5be1a4('0x2')),loggerSyncQueueSummary=require(_0x5be1a4('0x5e'))(_0x5be1a4('0xba')),ami=require(_0x5be1a4('0x1b5')),{getSocket}=require(_0x5be1a4('0x17a')),io=getSocket(),cmHopper=require(_0x5be1a4('0x3d')),cmHopperHistory=require(_0x5be1a4('0x1be')),cmHopperBlack=require(_0x5be1a4('0x50')),voiceQueueRt=require(_0x5be1a4('0xd7')),Action=require(_0x5be1a4('0x152')),History=require(_0x5be1a4('0x79')),Final=require(_0x5be1a4('0x1c9')),AgentComplete=require(_0x5be1a4('0x13b')),QueueCallerAbandon=require(_0x5be1a4('0xce')),Hangup=require(_0x5be1a4('0x14e')),{getConfigService}=require(_0x5be1a4('0x134')),strategy={'rrmemory':'rrmemory','roundrobin':'roundrobin'},Sequence=function(){};Sequence['prototype']['enqueue']=function(_0x207ef4){const _0x2e6455=_0x5be1a4;this[_0x2e6455('0x116')]=this[_0x2e6455('0x116')]?this[_0x2e6455('0x116')]['finally'](_0x207ef4):_0x207ef4();};function Dialer(_0x37e33c,_0x3c24e0){const _0x5661b5=_0x5be1a4;this[_0x5661b5('0x153')]=new Sequence(),this['preview']=_0x3c24e0,this[_0x5661b5('0x1e3')]=_0x37e33c['voiceQueues'],this[_0x5661b5('0x13d')]=_0x37e33c[_0x5661b5('0x13d')],this['agents']=_0x37e33c[_0x5661b5('0x148')],this[_0x5661b5('0x74')]=_0x37e33c['trunks'],this[_0x5661b5('0x1db')]=config[_0x5661b5('0x1db')]||0x2,this['channels']={},this['actions']={},this[_0x5661b5('0x210')]={},this[_0x5661b5('0x1d9')]={},this['optionPredictive']={},this['startPredictive']={},this[_0x5661b5('0x137')]={},this[_0x5661b5('0xd0')]={},this[_0x5661b5('0x1b9')]={},this['queueBookedRR']={},ami['on'](_0x5661b5('0x1ea'),this[_0x5661b5('0xa4')][_0x5661b5('0x8e')](this)),ami['on'](_0x5661b5('0x193'),this[_0x5661b5('0x19f')][_0x5661b5('0x8e')](this)),ami['on']('originateresponse',this[_0x5661b5('0x17d')][_0x5661b5('0x8e')](this)),ami['on'](_0x5661b5('0xda'),this[_0x5661b5('0x1a2')][_0x5661b5('0x8e')](this)),ami['on'](_0x5661b5('0x1eb'),this[_0x5661b5('0xba')][_0x5661b5('0x8e')](this)),ami['on'](_0x5661b5('0xa0'),this[_0x5661b5('0x19b')][_0x5661b5('0x8e')](this)),ami['on'](_0x5661b5('0x192'),this[_0x5661b5('0x1f9')][_0x5661b5('0x8e')](this)),ami['on']('varset',this['syncVarSet']['bind'](this)),ami['on'](_0x5661b5('0x197'),this[_0x5661b5('0x20c')]['bind'](this)),ami['on'](_0x5661b5('0x1a6'),this[_0x5661b5('0x4b')][_0x5661b5('0x8e')](this)),this['loopCampaigns'](),this[_0x5661b5('0x13f')]();}function isNotNull(_0x600d65){const _0x3dcca0=_0x5be1a4;return _0x600d65!==null&&!_[_0x3dcca0('0xac')](_0x600d65);}function checkIsLoggedIn(_0x5d19cc,_0x262321){return function(){const _0x29e0b8=a1057_0x3d95;if(_0x262321<=0x0){_0x5d19cc[_0x29e0b8('0x1f6')]=_0x29e0b8('0x108');throw _0x5d19cc[_0x29e0b8('0x1a8')]+'\x20AGENTS\x20NOT\x20LOGGED';}};}function isActive(_0x4ac65d){return _0x4ac65d;}function checkIsActive(_0x1ad5ba,_0x3d4722){return function(){const _0x13d73c=a1057_0x3d95;if(!isActive(_0x3d4722)){_0x1ad5ba['message']='NOT_ACTIVE';throw _0x1ad5ba[_0x13d73c('0x1a8')]+_0x13d73c('0x1df');}};}function checkInterval(_0x24350a){return function(){const _0x136a23=a1057_0x3d95;if(!isNotNull(_0x24350a[_0x136a23('0x1cf')])){_0x24350a['message']='INTERVAL_IS_NULL';throw _0x24350a['name']+'\x20INTERVAL_IS_NULL';}if(!isNotNull(_0x24350a[_0x136a23('0x1cf')]['Intervals'])){_0x24350a[_0x136a23('0x1f6')]=_0x136a23('0x170');throw _0x24350a['name']+'\x20INTERVAL_IS_NULL';}if(!isNotNull(_[_0x136a23('0x182')](_0x24350a[_0x136a23('0x1cf')][_0x136a23('0x100')]))){_0x24350a[_0x136a23('0x1f6')]='INTERVAL_IS_NULL';throw _0x24350a[_0x136a23('0x1a8')]+'\x20INTERVAL_IS_NULL';}};}function msgResponse(_0x58d71d,_0x1340e4,_0x5035fc){return{'action':_0x58d71d,'response':_0x1340e4,'message':_0x5035fc,'stack':_0x5035fc};}function myreject(_0x11f4bc){return function(_0x2fbb98){const _0x1aa87b=a1057_0x3d95;return _0x11f4bc(msgResponse(_0x1aa87b('0x106'),_0x1aa87b('0x150'),JSON[_0x1aa87b('0xf3')](_0x2fbb98)));};}function getSeconds(_0x1685e7,_0xa8656e){const _0xe960ea=_0x5be1a4,_0x339919=moment(_0x1685e7)[_0xe960ea('0x21')](0x0),_0xee3a49=moment(_0xa8656e)['milliseconds'](0x0);return _0x339919[_0xe960ea('0x17e')](_0xee3a49,_0xe960ea('0x40'));}function emit(_0x20e181,_0x56b6ac,_0x3e6548){const _0x2a59f9=_0x5be1a4;io['to'](_0x20e181)[_0x2a59f9('0x8c')](_0x56b6ac,_0x3e6548);}function emitVoiceQueueSummary(_0x2e19d8){const _0x13b99d=_0x5be1a4;if(_0x2e19d8[_0x13b99d('0xb3')]==='outbound'){const _0x193650={'id':_0x2e19d8['id'],'name':_0x2e19d8[_0x13b99d('0x1a8')],'strategy':_0x2e19d8['strategy'],'answered':_0x2e19d8[_0x13b99d('0xed')],'available':_0x2e19d8[_0x13b99d('0x10d')],'loggedIn':_0x2e19d8[_0x13b99d('0x1fa')],'pTalking':_0x2e19d8[_0x13b99d('0x12b')],'sumBillable':_0x2e19d8['sumBillable'],'sumDuration':_0x2e19d8[_0x13b99d('0x91')],'sumHoldTime':_0x2e19d8[_0x13b99d('0x1da')]||0x0,'talking':_0x2e19d8[_0x13b99d('0x18')],'total':_0x2e19d8[_0x13b99d('0x2b')],'type':_0x2e19d8['type'],'unmanaged':_0x2e19d8['unmanaged'],'abandoned':_0x2e19d8['abandoned'],'waiting':_0x2e19d8[_0x13b99d('0x138')],'loggedInDb':_0x2e19d8[_0x13b99d('0x19e')],'dialActive':_0x2e19d8['dialActive'],'dialMethod':_0x2e19d8[_0x13b99d('0x44')],'dialOriginateCallerIdName':_0x2e19d8[_0x13b99d('0x4')],'dialOriginateCallerIdNumber':_0x2e19d8[_0x13b99d('0x16')],'dialOriginateTimeout':_0x2e19d8[_0x13b99d('0x190')],'dialPrefix':_0x2e19d8[_0x13b99d('0xd4')],'outboundAnswerAgiCallsDay':_0x2e19d8[_0x13b99d('0x1d8')],'outboundAnswerCallsDay':_0x2e19d8[_0x13b99d('0xa6')],'outboundBlacklistCallsDay':_0x2e19d8[_0x13b99d('0x15c')],'outboundBusyCallsDay':_0x2e19d8['outboundBusyCallsDay'],'outboundCongestionCallsDay':_0x2e19d8[_0x13b99d('0x124')],'outboundDropCallsDayACS':_0x2e19d8[_0x13b99d('0x12e')],'outboundDropCallsDayCallersExit':_0x2e19d8['outboundDropCallsDayCallersExit'],'outboundDropCallsDayTimeout':_0x2e19d8[_0x13b99d('0x180')],'outboundNoAnswerCallsDay':_0x2e19d8[_0x13b99d('0x1c2')],'outboundNoSuchCallsDay':_0x2e19d8[_0x13b99d('0xec')],'outboundOriginateFailureCallsDay':_0x2e19d8[_0x13b99d('0x17')],'outboundReCallsDay':_0x2e19d8[_0x13b99d('0x16d')],'outboundRejectCallsDay':_0x2e19d8[_0x13b99d('0x51')],'outboundUnknownCallsDay':_0x2e19d8[_0x13b99d('0x8')],'predictiveIntervalAnsweredCalls':_0x2e19d8[_0x13b99d('0x15f')],'predictiveIntervalAvgHoldtime':_0x2e19d8['predictiveIntervalAvgHoldtime'],'predictiveIntervalAvgTalktime':_0x2e19d8[_0x13b99d('0x12a')],'predictiveIntervalDroppedCallsCallersExit':_0x2e19d8['predictiveIntervalDroppedCallsCallersExit'],'predictiveIntervalDroppedCallsTimeout':_0x2e19d8[_0x13b99d('0x1ce')],'predictiveIntervalErlangCalls':_0x2e19d8[_0x13b99d('0x17c')],'predictiveIntervalErlangCallsDroppedCalls':_0x2e19d8[_0x13b99d('0xde')],'predictiveIntervalHitRate':_0x2e19d8[_0x13b99d('0x1e2')],'predictiveIntervalMultiplicativeFactor':_0x2e19d8['predictiveIntervalMultiplicativeFactor'],'predictiveIntervalPauses':_0x2e19d8[_0x13b99d('0x111')],'predictiveIntervalAvailable':_0x2e19d8[_0x13b99d('0x19')],'predictiveIntervalTotalCalls':_0x2e19d8['predictiveIntervalTotalCalls'],'message':_0x2e19d8['message'],'originated':_0x2e19d8[_0x13b99d('0xb7')],'erlangCalls':_0x2e19d8[_0x13b99d('0xd1')],'erlangCallToSecond':_0x2e19d8['erlangCallToSecond'],'erlangAbandonmentRate':_0x2e19d8[_0x13b99d('0x1ca')],'erlangBusyFactor':_0x2e19d8['erlangBusyFactor'],'startPredictive':_0x2e19d8[_0x13b99d('0x157')],'startProgressive':_0x2e19d8[_0x13b99d('0x137')]};_0x2e19d8['Trunk']&&(_0x193650['Trunk']={'id':_0x2e19d8['Trunk']['id'],'name':_0x2e19d8['Trunk'][_0x13b99d('0x1a8')],'active':_0x2e19d8[_0x13b99d('0xc4')]['active'],'callerid':_0x2e19d8[_0x13b99d('0xc4')][_0x13b99d('0xcf')]});_0x2e19d8['Interval']&&(_0x193650[_0x13b99d('0x1cf')]={'id':_0x2e19d8[_0x13b99d('0x1cf')]['id'],'name':_0x2e19d8[_0x13b99d('0x1cf')][_0x13b99d('0x1a8')]});const _0x445dbd=md5(JSON['stringify'](_0x193650));_0x2e19d8[_0x13b99d('0x205')]!==_0x445dbd&&(_0x2e19d8[_0x13b99d('0x205')]=_0x445dbd,emit(util['format']('voice:queue:%s',_0x193650[_0x13b99d('0x1a8')]),_0x13b99d('0xa2'),_0x193650));}}function emitCampaignSummary(_0x29af43){const _0x4878d0=_0x5be1a4;_0x29af43['type']===_0x4878d0('0x176')&&emit(util[_0x4878d0('0x29')](_0x4878d0('0x12'),_0x29af43['name']),_0x4878d0('0x49'),_0x29af43);}function checkGetDataPredictive(_0xdae071){const _0x73fd21=_0x5be1a4;if(isNotNull(_0xdae071)){if(!_[_0x73fd21('0x182')](_0xdae071)){loggerPredictive[_0x73fd21('0x1d3')](_0x73fd21('0x118')),loggerPredictive['info'](_0x73fd21('0x203'),_0xdae071[_0x73fd21('0x1a5')]),loggerPredictive['info'](_0x73fd21('0x156'),_0xdae071['predictiveIntervalAnsweredCalls']),loggerPredictive[_0x73fd21('0x1d3')]('Dropped\x20Timeout:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20',_0xdae071[_0x73fd21('0x1ce')]),loggerPredictive[_0x73fd21('0x1d3')](_0x73fd21('0x1f2'),_0xdae071[_0x73fd21('0x8a')]),loggerPredictive['info'](_0x73fd21('0x3e'),_0xdae071[_0x73fd21('0xb1')]),loggerPredictive[_0x73fd21('0x1d3')](_0x73fd21('0x171'),_0xdae071[_0x73fd21('0x12a')]),loggerPredictive['info'](_0x73fd21('0x1a4'));if(_0xdae071[_0x73fd21('0x1a5')]>0x0){if(!_['isUndefined'](_0xdae071[_0x73fd21('0x12a')])&&_0xdae071[_0x73fd21('0x12a')]>0x0)return!![];else loggerPredictive['info']('Avg\x20Talk\x20Time\x20is\x20not\x20enough\x20for\x20predictive');if(!_[_0x73fd21('0xac')](_0xdae071[_0x73fd21('0xb1')])&&_0xdae071[_0x73fd21('0xb1')]>0x0)return!![];else loggerPredictive[_0x73fd21('0x1d3')](_0x73fd21('0x2d'));}else loggerPredictive[_0x73fd21('0x1d3')](_0x73fd21('0x5c'));}else loggerPredictive[_0x73fd21('0x1d3')]('History\x20information\x20are\x20empty');}else loggerPredictive['info']('History\x20information\x20are\x20empty');return![];}function mergeDataErlangB(_0x4730ce){return function(_0x3729e8){const _0x432131=a1057_0x3d95;loggerPredictive[_0x432131('0x1d3')](_0x432131('0x177')),loggerPredictive[_0x432131('0x1d3')](_0x432131('0x48'),_0x3729e8['erlangCalls']),loggerPredictive[_0x432131('0x1d3')](_0x432131('0xf5'),_0x3729e8[_0x432131('0x20f')]),loggerPredictive[_0x432131('0x1d3')](_0x432131('0xb0'),_0x3729e8[_0x432131('0x1ca')]),loggerPredictive['info'](_0x432131('0xc3'),_0x3729e8[_0x432131('0x6')]),loggerPredictive[_0x432131('0x1d3')](_0x432131('0xb0'),_0x3729e8[_0x432131('0x1ca')]),loggerPredictive[_0x432131('0x1d3')](_0x432131('0x1a4')),_[_0x432131('0xb')](_0x4730ce,_0x3729e8);};}function getDiff(_0x3a9552){const _0x10b797=_0x5be1a4,_0x9c8aab=moment()[_0x10b797('0x21')](0x0),_0xd974c5=moment(_0x3a9552)[_0x10b797('0x21')](0x0);return _0x9c8aab[_0x10b797('0x17e')](_0xd974c5,'seconds');}function ifInterval(_0x1c6ac9,_0x2b0373){const _0x40c805=_0x5be1a4;if(_[_0x40c805('0xac')](_0x2b0373))return![];return getDiff(_0x2b0373)<_0x1c6ac9*0x3c?!![]:![];}function freeVariablesPredictive(_0x119bb4){const _0x5d8cae=_0x5be1a4;isNotNull(_0x119bb4)&&(!_['isUndefined'](_0x119bb4['startProgressive'])&&(_0x119bb4[_0x5d8cae('0x137')]=undefined,loggerPredictive[_0x5d8cae('0x1d3')](_0x119bb4[_0x5d8cae('0x1a8')],_0x5d8cae('0x1f4'))),!_[_0x5d8cae('0xac')](_0x119bb4[_0x5d8cae('0x157')])&&(_0x119bb4[_0x5d8cae('0x157')]=undefined,loggerPredictive['info'](_0x119bb4[_0x5d8cae('0x1a8')],_0x5d8cae('0x63'))),!_['isUndefined'](_0x119bb4[_0x5d8cae('0xb9')])&&(clearInterval(_0x119bb4[_0x5d8cae('0xb9')]),_0x119bb4['handlePredictive']=undefined,loggerPredictive[_0x5d8cae('0x1d3')](_0x119bb4[_0x5d8cae('0x1a8')],_0x5d8cae('0x12c'))));}function erlangb(_0x566b75,_0x4fb339){if(_0x4fb339===0x0)return 0x0;let _0x3a45fe=0x1;for(let _0x1d04a1=0x1;_0x1d04a1<=_0x4fb339;_0x1d04a1+=0x1){_0x3a45fe=0x1+_0x3a45fe*_0x1d04a1/_0x566b75;}return 0x1/_0x3a45fe;}function isVoiceQueueOutbound(_0x12ae30){const _0x4e2b95=_0x5be1a4;return _0x12ae30===_0x4e2b95('0xbc');}function isNotPreview(_0x3045a2){const _0x15e91e=_0x5be1a4;return _0x3045a2!==_0x15e91e('0x16b');}function isCampaignIvr(_0x1d857d){const _0x5dd135=_0x5be1a4;return _0x1d857d===_0x5dd135('0x176');}function getCallerId(_0x5637e7,_0x5394d3,_0x25c71e){const _0x25af73=_0x5be1a4;if(!_[_0x25af73('0xac')](_0x25c71e)&&_0x25af73('0x34')===typeof _0x25c71e&&!_[_0x25af73('0x182')](_0x25c71e)){if(!_['isUndefined'](_0x5394d3)&&_0x25af73('0x34')===typeof _0x5394d3&&!_['isEmpty'](_0x5394d3))return util[_0x25af73('0x29')](_0x25af73('0x1c'),_0x5394d3,_0x25c71e);return util['format'](_0x25af73('0x1c'),_0x25c71e,_0x25c71e);}if(!_[_0x25af73('0xac')](_0x5637e7)&&'string'===typeof _0x5637e7&&!_[_0x25af73('0x182')](_0x5637e7))return _0x5637e7;return'\x22\x22\x20<>';}function loggerCatchQueueSummary(_0x3307fa,_0x1a374a){return function(_0x448125){const _0x177315=a1057_0x3d95;freeVariablesPredictive(_0x1a374a),emitVoiceQueueSummary(_0x1a374a),emitCampaignSummary(_0x1a374a),loggerSyncQueueSummary[_0x177315('0x10f')](_0x3307fa,util[_0x177315('0x204')](_0x448125,{'showHidden':![],'depth':null}));};}function loggerCatchPredictive(_0x34999c,_0x4155ba){return function(_0x39c4ed){const _0x531e39=a1057_0x3d95;loggerPredictive['error'](_0x4155ba[_0x531e39('0x1a8')],_0x34999c),loggerPredictive[_0x531e39('0x10f')](_0x39c4ed[_0x531e39('0x88')]),freeVariablesPredictive(_0x4155ba);};}function loggerCatch(_0x483106){return function(_0x194364){const _0x327ba0=a1057_0x3d95;logger[_0x327ba0('0x10f')](_0x483106,util[_0x327ba0('0x204')](_0x194364,{'showHidden':![],'depth':null}));};}function checkContactEmpty(_0x1fbfcd){const _0x24f844=_0x5be1a4;return _0x1fbfcd&&!_[_0x24f844('0xac')](_0x1fbfcd)&&_0x1fbfcd['length']>0x0;}function decremetOriginate(_0x461794){const _0x30f5fa=_0x5be1a4;!_[_0x30f5fa('0xac')](_0x461794)&&_0x461794!==null?typeof _0x461794['originated']!==_0x30f5fa('0x8d')&&(_0x461794[_0x30f5fa('0xb7')]>0x0?_0x461794['originated']-=0x1:logger[_0x30f5fa('0x10f')](_0x30f5fa('0x201'))):logger[_0x30f5fa('0x10f')]('[decremetOriginate]\x20is\x20null\x20or\x20undefined');}function checkContactLowerLimitOriginate(_0x10e2e3,_0x3d9ef8,_0x4f3cbd){if(_0x3d9ef8>_0x4f3cbd)for(let _0x22806d=0x0;_0x22806d<_0x3d9ef8-_0x4f3cbd;_0x22806d+=0x1){decremetOriginate(_0x10e2e3);}}function loggerGetContactDialer(_0x27dde9,_0xb3f2a,_0x3aa7ba){return function(_0x70a787){const _0x5ef626=a1057_0x3d95;checkContactLowerLimitOriginate(_0xb3f2a,_0x3aa7ba,0x0),logger[_0x5ef626('0x10f')](_0x27dde9,util['inspect'](_0x70a787,{'showHidden':![],'depth':null}));};}function sendMessageReschedule(_0x4f1f8c){return function(_0x279152){const _0x314dcd=a1057_0x3d95;isNotNull(_0x279152)&&isNotNull(_0x279152[0x0])&&(_0x279152[0x0][_0x314dcd('0x129')]>0x0?(_0x4f1f8c[_0x314dcd('0x1f6')]='RESCHEDULED_CONTACTS',logger[_0x314dcd('0x1d3')]('[getContactDialer2][ReScheduled]'+_0x4f1f8c[_0x314dcd('0x1a8')],_0x279152[0x0]['contactsRescheduled'],_0x314dcd('0x195'))):(_0x4f1f8c[_0x314dcd('0x1f6')]=_0x314dcd('0xff'),logger[_0x314dcd('0x1d3')]('[getContactDialer2][Empty]'+_0x4f1f8c['name'])));};}function notSendMessagesQueue(_0x35b190){const _0x3c95e2=_0x5be1a4;_0x35b190[_0x3c95e2('0x75')]&&(freeVariablesPredictive(_0x35b190),_0x35b190[_0x3c95e2('0xb7')]===0x0&&_0x35b190[_0x3c95e2('0x18')]===0x0&&_0x35b190['waiting']===0x0&&(_0x35b190[_0x3c95e2('0x12b')]||0x0)===0x0?(_0x35b190[_0x3c95e2('0x75')]=![],_0x35b190[_0x3c95e2('0x10d')]=0x0,_0x35b190[_0x3c95e2('0x1f6')]=_0x3c95e2('0x4d'),loggerSyncQueueSummary[_0x3c95e2('0x10f')]('[syncQueueSummary]\x20Campaign\x20Queue:\x20',_0x35b190[_0x3c95e2('0x1a8')],_0x3c95e2('0x13a'))):(_0x35b190['message']=_0x3c95e2('0x1b6'),loggerSyncQueueSummary[_0x3c95e2('0x10f')](_0x3c95e2('0x11'),_0x35b190[_0x3c95e2('0x1a8')],_0x3c95e2('0xca'))),emitVoiceQueueSummary(_0x35b190));}function notSendMessagesCampaign(_0x309e8d){const _0xfaa161=_0x5be1a4;_0x309e8d['sendMessageOneNotActive']&&(_0x309e8d[_0xfaa161('0xb7')]===0x0?(_0x309e8d[_0xfaa161('0x75')]=![],_0x309e8d[_0xfaa161('0x1f6')]=_0xfaa161('0x4d'),loggerSyncQueueSummary[_0xfaa161('0x10f')]('[syncQueueSummary]\x20Campaign\x20Ivr:\x20',_0x309e8d[_0xfaa161('0x1a8')],_0xfaa161('0x13a'))):(_0x309e8d[_0xfaa161('0x1f6')]=_0xfaa161('0x1b6'),loggerSyncQueueSummary['error'](_0xfaa161('0x71'),_0x309e8d[_0xfaa161('0x1a8')],_0xfaa161('0xca'))),emitCampaignSummary(_0x309e8d));}function createObjHistory(_0x1711ee,_0x36765c,_0x37382d,_0x20e1fc,_0x5d1ec8){const _0x566e9a=_0x5be1a4;_0x1711ee[_0x566e9a('0x1f6')]=_0x37382d;const _0x228c2e=new Action(_0x1711ee,_0x36765c),_0xd8a8ff=new History(_0x228c2e);return _0xd8a8ff[_0x566e9a('0x8b')]=_0x20e1fc,_0xd8a8ff[_0x566e9a('0x196')]=_0x5d1ec8,_0xd8a8ff[_0x566e9a('0x1b7')]=_0x228c2e[_0x566e9a('0x1dc')],_0xd8a8ff;}Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x13f')]=function(){const _0x23c910=this;setInterval(function(){const _0x3020b9=a1057_0x3d95;_0x23c910[_0x3020b9('0x14f')](_0x23c910[_0x3020b9('0x1d9')],_0x3020b9('0x181')),_0x23c910[_0x3020b9('0x14f')](_0x23c910[_0x3020b9('0x6f')],'[actions]');},0x32c8);},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x14f')]=function(_0x341a31,_0x5d4ccc){const _0x2bc292=_0x5be1a4,_0x5a80fb=this;for(const _0xbd8303 in _0x341a31){typeof _0x341a31[_0xbd8303]!==_0x2bc292('0x8d')&&this[_0x2bc292('0x153')][_0x2bc292('0x115')](function(){const _0x3c56df=_0x2bc292;if(!_['isNil'](_0x341a31[_0xbd8303]))return ami['Action']({'action':_0x3c56df('0x28'),'channel':_0x341a31[_0xbd8303][_0x3c56df('0xd')]})[_0x3c56df('0x207')](function(_0x3aa7bd){const _0x1de695=_0x3c56df;_0x3aa7bd[_0x1de695('0x1f6')]===_0x1de695('0xb2')&&setTimeout(function(){const _0x20de9a=_0x1de695;_0x341a31[_0xbd8303]&&_0x341a31[_0xbd8303][_0x20de9a('0xb3')]!==_0x20de9a('0x176')&&(_0x5a80fb['updateOriginated'](_0x5a80fb[_0x20de9a('0x1e3')][_0x341a31[_0xbd8303][_0x20de9a('0xe1')]]),logger['error'](_0x20de9a('0x95'),_0x5d4ccc,_0xbd8303,_0x341a31[_0xbd8303][_0x20de9a('0xe1')]),delete _0x341a31[_0xbd8303]),_0x341a31[_0xbd8303]&&_0x341a31[_0xbd8303][_0x20de9a('0xb3')]===_0x20de9a('0x176')&&(_0x5a80fb[_0x20de9a('0x1d0')](_0x5a80fb['campaigns'][_0x341a31[_0xbd8303][_0x20de9a('0xe1')]]),logger[_0x20de9a('0x10f')](_0x20de9a('0xd8'),_0x5d4ccc,_0xbd8303,_0x341a31[_0xbd8303][_0x20de9a('0xe1')]),delete _0x341a31[_0xbd8303]);},0x2328);});});}},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x33')]=function(_0xc9259f){const _0x454aef=_0x5be1a4;return Promise[_0x454aef('0x7a')]()[_0x454aef('0xfe')](cmHopper[_0x454aef('0x33')](_0xc9259f))[_0x454aef('0x207')](loggerCatch(_0x454aef('0x1f')));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x11e')]=function(_0x9ed289){const _0x51ae44=_0x5be1a4;return Promise['resolve']()[_0x51ae44('0xfe')](cmHopperBlack[_0x51ae44('0x11e')](_0x9ed289))[_0x51ae44('0x207')](loggerCatch(_0x51ae44('0xe6')));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x53')]=function(_0xd979df){const _0x57dd6a=_0x5be1a4;return Promise[_0x57dd6a('0x7a')]()[_0x57dd6a('0xfe')](cmHopperBlack[_0x57dd6a('0x53')](_0xd979df))[_0x57dd6a('0x207')](loggerCatch(_0x57dd6a('0x119')));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x159')]=function(_0x3a3007){const _0x364688=_0x5be1a4;return Promise[_0x364688('0x7a')]()['then'](cmHopperHistory[_0x364688('0x126')](_0x3a3007))[_0x364688('0x207')](loggerCatch('[averageHandleTime]\x20'));},Dialer[_0x5be1a4('0x141')]['rescheduleContact']=function(_0x44ddb9){const _0x8195a8=_0x5be1a4;return Promise[_0x8195a8('0x7a')]()[_0x8195a8('0xfe')](cmHopper['rescheduleContact'](_0x44ddb9))[_0x8195a8('0x207')](loggerCatch(_0x8195a8('0x154')));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x175')]=function(_0x4d140c,_0x4b176d,_0xab9424){const _0x445cbc=_0x5be1a4;return Promise['resolve']()['then'](cmHopper['unlockContact'](_0x4d140c,_0x4b176d,_0xab9424))[_0x445cbc('0x207')](loggerCatch(_0x445cbc('0x1a0')));},Dialer['prototype'][_0x5be1a4('0xc')]=function(_0x1cc9df,_0x3c76ca,_0x25e7c0,_0x17709b){const _0x5410bd=_0x5be1a4;return Promise[_0x5410bd('0x7a')]()['then'](cmHopper['getContactDialer'](_0x1cc9df,_0x3c76ca,_0x25e7c0,_0x17709b))[_0x5410bd('0x207')](loggerCatch('[getContactDialer]\x20'));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x7d')]=function(_0x1c9fdf,_0x50cf08,_0x8bd69a){const _0x1cb87e=_0x5be1a4;return Promise['resolve']()[_0x1cb87e('0xfe')](cmHopper['getContactDialerIvr'](_0x1c9fdf,_0x50cf08,_0x8bd69a))[_0x1cb87e('0x207')](loggerCatch(_0x1cb87e('0x158')));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0xc5')]=function(_0x12ed07){const _0x4485f9=_0x5be1a4;return Promise[_0x4485f9('0x7a')]()['then'](voiceQueueRt[_0x4485f9('0xc5')](_0x12ed07))['catch'](loggerCatch(_0x4485f9('0x23')));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x83')]=function(_0x224e7a){const _0x1cefab=_0x5be1a4;return Promise[_0x1cefab('0x7a')]()[_0x1cefab('0xfe')](cmHopper[_0x1cefab('0x83')](_0x224e7a))[_0x1cefab('0x207')](loggerCatch('[moveContactManagedDialer]\x20'));},Dialer['prototype'][_0x5be1a4('0x1b4')]=function(_0x2c4135){const _0x3cdec9=_0x5be1a4;return Promise[_0x3cdec9('0x7a')]()[_0x3cdec9('0xfe')](cmHopperHistory[_0x3cdec9('0x1b4')](_0x2c4135))['catch'](loggerCatch('[createHistory]\x20'));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x1d0')]=function(_0x8e2912){const _0x134018=_0x5be1a4;!_['isUndefined'](_0x8e2912)&&_0x8e2912!==null?typeof _0x8e2912[_0x134018('0xb7')]!==_0x134018('0x8d')&&(_0x8e2912[_0x134018('0xb7')]>0x0?_0x8e2912[_0x134018('0xb7')]-=0x1:logger[_0x134018('0x10f')]('[updateOriginated]\x20object\x20originated\x20is\x20negative')):logger['error'](_0x134018('0x1c8'));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x1b3')]=function(_0x3f2692,_0x1944b7){const _0x4282a5=this;return function(_0x1228ee){const _0x22b710=a1057_0x3d95;_0x4282a5[_0x22b710('0x1d0')](_0x1944b7),logger['error'](_0x3f2692,util['inspect'](_0x1228ee,{'showHidden':![],'depth':null}));};},Dialer[_0x5be1a4('0x141')]['emptyContact']=function(_0xc3ba6a,_0x32dc95,_0x220c1c){const _0x1a2af3=_0x5be1a4,_0x26683d={'state':0x19,'statedesc':_0x1a2af3('0x1ef')};this[_0x1a2af3('0x1d0')](_0x32dc95),this['saveInDb'](_[_0x1a2af3('0xb')](_0x26683d,_[_0x1a2af3('0x9c')](_0x220c1c,[_0x1a2af3('0x208'),_0x1a2af3('0x13'),'UserId',_0x1a2af3('0x18f'),_0x1a2af3('0x142')])),_0x1a2af3('0xe8'),_0x1a2af3('0x185')),logger[_0x1a2af3('0x10f')](_0xc3ba6a);},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x45')]=function(_0x391d36){return _0x391d36==='Success';},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x146')]=function(_0xb85d3c){const _0x51f52d=_0x5be1a4;return!_['isUndefined'](_0xb85d3c)&&_0xb85d3c&&!_[_0x51f52d('0xac')](_0xb85d3c['name'])&&!_[_0x51f52d('0xac')](_0xb85d3c[_0x51f52d('0x1bd')])&&_0xb85d3c['active']&&(this[_0x51f52d('0x74')][util[_0x51f52d('0x29')](_0x51f52d('0x1ed'),_0xb85d3c[_0x51f52d('0x1a8')])]['status']===_0x51f52d('0x1ba')||this['trunks'][util[_0x51f52d('0x29')](_0x51f52d('0x1ed'),_0xb85d3c[_0x51f52d('0x1a8')])]['status']===_0x51f52d('0x1f7'));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0xb6')]=function(_0x47e622,_0x2b4d50,_0x22814c){const _0x10a0ac=_0x5be1a4;this[_0x10a0ac('0x1b4')](_0x47e622)[_0x10a0ac('0x207')](loggerCatch(_0x2b4d50)),this[_0x10a0ac('0x83')](_0x47e622)[_0x10a0ac('0x207')](loggerCatch(_0x22814c));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x8f')]=function(_0xb1e0c7){const _0xa6e6ea=_0x5be1a4,_0x49cb65=this['uniqueId'][_0xb1e0c7[_0xa6e6ea('0x93')]];let _0x3f9034;if(!_[_0xa6e6ea('0x17f')](_0xb1e0c7)&&!_[_0xa6e6ea('0x17f')](_0xb1e0c7[_0xa6e6ea('0x10')])&&!_[_0xa6e6ea('0x17f')](_0xb1e0c7[_0xa6e6ea('0x10')][_0xa6e6ea('0x2c')])&&_0xb1e0c7[_0xa6e6ea('0x55')]===_0xa6e6ea('0x64')&&_0x49cb65){_0x49cb65[_0xa6e6ea('0xb3')]!==_0xa6e6ea('0x176')&&this['voiceQueues'][_0x49cb65['queue']][_0xa6e6ea('0x1d7')]&&_0xb1e0c7['value']===_0xa6e6ea('0x135')&&(delete this[_0xa6e6ea('0x1d9')][_0xb1e0c7['uniqueid']],this[_0xa6e6ea('0x1d0')](this[_0xa6e6ea('0x1e3')][_0x49cb65['queue']]),this['voiceQueues'][_0x49cb65[_0xa6e6ea('0xe1')]][_0xa6e6ea('0xa6')]+=0x1,this[_0xa6e6ea('0x1e3')][_0x49cb65[_0xa6e6ea('0xe1')]]['outboundAnswerAgiCallsDay']+=0x1,_0x3f9034=new Hangup(_0x49cb65,_0xb1e0c7),_0x3f9034['state']=0x12,_0x3f9034[_0xa6e6ea('0x196')]=_0xa6e6ea('0x173'),_0x3f9034[_0xa6e6ea('0x5')]=_0xa6e6ea('0x1e6'),this[_0xa6e6ea('0xb6')](_0x3f9034,'[syncHangupInAMD][createHistory]',_0xa6e6ea('0x1c1')));if(_0x49cb65[_0xa6e6ea('0xb3')]!==_0xa6e6ea('0x176')&&this[_0xa6e6ea('0x1e3')][_0x49cb65[_0xa6e6ea('0xe1')]][_0xa6e6ea('0x1d7')]&&_0xb1e0c7[_0xa6e6ea('0xf9')]===_0xa6e6ea('0x78')){const _0x28d2c2=this;return new Promise(function(_0xe6eb47,_0x50496e){const _0x1aae1a=_0xa6e6ea;delete _0x28d2c2[_0x1aae1a('0x1d9')][_0xb1e0c7[_0x1aae1a('0x93')]],_0x28d2c2[_0x1aae1a('0x1d0')](_0x28d2c2['voiceQueues'][_0x49cb65[_0x1aae1a('0xe1')]]),_0x28d2c2[_0x1aae1a('0x1e3')][_0x49cb65[_0x1aae1a('0xe1')]][_0x1aae1a('0xa6')]+=0x1,_0x28d2c2[_0x1aae1a('0x1e3')][_0x49cb65[_0x1aae1a('0xe1')]][_0x1aae1a('0x1d8')]+=0x1;const _0x268f96=_0x28d2c2[_0x1aae1a('0x1e3')][_0x49cb65[_0x1aae1a('0xe1')]],_0x12c98e=new Hangup(_0x49cb65,_0xb1e0c7);_0x12c98e[_0x1aae1a('0x8b')]=0x13,_0x12c98e['statedesc']=_0x1aae1a('0x25'),_0x12c98e[_0x1aae1a('0x5')]=_0x1aae1a('0x1e6'),_0x12c98e[_0x1aae1a('0xa3')]+=0x1,_0x12c98e[_0x1aae1a('0x94')]+=0x1,_0x12c98e[_0x1aae1a('0x1e7')]=!![],_0x28d2c2['createHistory'](_0x12c98e)['catch'](loggerCatch(_0x1aae1a('0x31'))),_0x12c98e['countbusyretry']+_0x12c98e['countcongestionretry']+_0x12c98e[_0x1aae1a('0x1b0')]+_0x12c98e[_0x1aae1a('0x1fc')]+_0x12c98e['countdropretry']+_0x12c98e[_0x1aae1a('0x36')]+_0x12c98e[_0x1aae1a('0xa3')]+_0x12c98e[_0x1aae1a('0xcb')]>=_0x268f96[_0x1aae1a('0x20d')]?_0x28d2c2[_0x1aae1a('0x27')](_0x12c98e,_0xe6eb47,_0x50496e,'reason19\x20machine....'):_0x12c98e['countmachineretry']>=_0x268f96[_0x1aae1a('0x1fb')]?_0x28d2c2[_0x1aae1a('0x206')](_0x12c98e,_0xe6eb47,_0x50496e,'reason\x2019\x20machine....'):(_0x28d2c2[_0x1aae1a('0x172')]({'active':![],'countmachineretry':_0x12c98e['countmachineretry'],'scheduledat':moment()[_0x1aae1a('0x4e')](_0x268f96[_0x1aae1a('0x1e8')],_0x1aae1a('0x160'))[_0x1aae1a('0x29')]('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x12c98e['ContactId'],'ListId':_0x12c98e[_0x1aae1a('0x13')],'VoiceQueueId':_0x12c98e[_0x1aae1a('0x18f')]||undefined,'CampaignId':_0x12c98e['CampaignId']||undefined})[_0x1aae1a('0x207')](loggerCatch(_0x1aae1a('0x1ff'))),_0xe6eb47({'reschedule':0x1}));});}_0x49cb65[_0xa6e6ea('0xb3')]==='ivr'&&this[_0xa6e6ea('0x13d')][_0x49cb65[_0xa6e6ea('0xe1')]][_0xa6e6ea('0x1d7')]&&_0xb1e0c7[_0xa6e6ea('0xf9')]==='HANGUP'&&(delete this['uniqueId'][_0xb1e0c7[_0xa6e6ea('0x93')]],this[_0xa6e6ea('0x1d0')](this['campaigns'][_0x49cb65[_0xa6e6ea('0xe1')]]),_0x3f9034=new Hangup(_0x49cb65,_0xb1e0c7),_0x3f9034[_0xa6e6ea('0x8b')]=0x12,_0x3f9034[_0xa6e6ea('0x196')]=_0xa6e6ea('0x173'),_0x3f9034[_0xa6e6ea('0x5')]=_0xa6e6ea('0x1e6'),this[_0xa6e6ea('0xb6')](_0x3f9034,_0xa6e6ea('0xaf'),_0xa6e6ea('0xcd')));if(_0x49cb65['type']==='ivr'&&this['campaigns'][_0x49cb65[_0xa6e6ea('0xe1')]][_0xa6e6ea('0x1d7')]&&_0xb1e0c7['value']===_0xa6e6ea('0x78')){const _0x87282b=this;return new Promise(function(_0x2cbb34,_0x31a890){const _0x4315ba=_0xa6e6ea;delete _0x87282b[_0x4315ba('0x1d9')][_0xb1e0c7['uniqueid']],_0x87282b[_0x4315ba('0x1d0')](_0x87282b['campaigns'][_0x49cb65['queue']]),_0x87282b[_0x4315ba('0x13d')][_0x49cb65[_0x4315ba('0xe1')]]['outboundAnswerCallsDay']+=0x1,_0x87282b[_0x4315ba('0x13d')][_0x49cb65[_0x4315ba('0xe1')]][_0x4315ba('0x1d8')]+=0x1;const _0x54f4fb=_0x87282b['campaigns'][_0x49cb65['queue']],_0x1a509b=new Hangup(_0x49cb65,_0xb1e0c7);_0x1a509b[_0x4315ba('0x8b')]=0x13,_0x1a509b['statedesc']=_0x4315ba('0x25'),_0x1a509b[_0x4315ba('0x5')]='AMD',_0x1a509b[_0x4315ba('0xa3')]+=0x1,_0x1a509b[_0x4315ba('0x94')]+=0x1,_0x1a509b[_0x4315ba('0x1e7')]=!![],_0x87282b['createHistory'](_0x1a509b)[_0x4315ba('0x207')](loggerCatch(_0x4315ba('0x31'))),_0x1a509b['countbusyretry']+_0x1a509b[_0x4315ba('0x1e9')]+_0x1a509b[_0x4315ba('0x1b0')]+_0x1a509b['countnosuchnumberretry']+_0x1a509b[_0x4315ba('0x82')]+_0x1a509b['countabandonedretry']+_0x1a509b[_0x4315ba('0xa3')]+_0x1a509b[_0x4315ba('0xcb')]>=_0x54f4fb[_0x4315ba('0x20d')]?_0x87282b[_0x4315ba('0x27')](_0x1a509b,_0x2cbb34,_0x31a890,'reason19\x20machine....'):_0x1a509b['countmachineretry']>=_0x54f4fb[_0x4315ba('0x1fb')]?_0x87282b[_0x4315ba('0x206')](_0x1a509b,_0x2cbb34,_0x31a890,_0x4315ba('0x12d')):(_0x87282b['rescheduleContact']({'active':![],'countmachineretry':_0x1a509b['countmachineretry'],'scheduledat':moment()[_0x4315ba('0x4e')](_0x54f4fb[_0x4315ba('0x1e8')],_0x4315ba('0x160'))[_0x4315ba('0x29')]('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x1a509b[_0x4315ba('0x208')],'ListId':_0x1a509b[_0x4315ba('0x13')],'VoiceQueueId':_0x1a509b['VoiceQueueId']||undefined,'CampaignId':_0x1a509b[_0x4315ba('0x142')]||undefined})[_0x4315ba('0x207')](loggerCatch('[rescheduleContact][Machine]')),_0x2cbb34({'reschedule':0x1}));});}}},Dialer[_0x5be1a4('0x141')]['syncHangup']=function(_0x192e5d){const _0x2d23f3=_0x5be1a4,_0x5c30f0=this[_0x2d23f3('0x1d9')][_0x192e5d[_0x2d23f3('0x93')]];let _0x122c65;_0x5c30f0&&_0x5c30f0[_0x2d23f3('0xb3')]===_0x2d23f3('0x176')&&(delete this[_0x2d23f3('0x1d9')][_0x192e5d['uniqueid']],this[_0x2d23f3('0x1d0')](this[_0x2d23f3('0x13d')][_0x5c30f0[_0x2d23f3('0xe1')]]),this[_0x2d23f3('0x13d')][_0x5c30f0['queue']]['ivrAnswerCallsDay']+=0x1,_0x122c65=new Hangup(_0x5c30f0,_0x192e5d),this[_0x2d23f3('0x1b4')](_0x122c65)[_0x2d23f3('0x207')](loggerCatch(_0x2d23f3('0xad'))),this[_0x2d23f3('0x83')](_0x122c65)['catch'](loggerCatch(_0x2d23f3('0x184')))),_0x5c30f0&&_0x5c30f0[_0x2d23f3('0xb3')]!==_0x2d23f3('0x176')&&isNotNull(this[_0x2d23f3('0x1e3')][_0x5c30f0['queue']][_0x2d23f3('0x60')])&&(delete this[_0x2d23f3('0x1d9')][_0x192e5d['uniqueid']],this[_0x2d23f3('0x1d0')](this[_0x2d23f3('0x1e3')][_0x5c30f0[_0x2d23f3('0xe1')]]),this[_0x2d23f3('0x1e3')][_0x5c30f0[_0x2d23f3('0xe1')]][_0x2d23f3('0xa6')]+=0x1,this[_0x2d23f3('0x1e3')][_0x5c30f0[_0x2d23f3('0xe1')]][_0x2d23f3('0x1d8')]+=0x1,_0x122c65=new Hangup(_0x5c30f0,_0x192e5d),_0x122c65['state']=0x10,_0x122c65[_0x2d23f3('0x196')]=_0x2d23f3('0x101'),_0x122c65[_0x2d23f3('0x5')]=_0x2d23f3('0x161'),this[_0x2d23f3('0x1b4')](_0x122c65)['catch'](loggerCatch(_0x2d23f3('0xad'))),this['moveContactManagedDialer'](_0x122c65)[_0x2d23f3('0x207')](loggerCatch(_0x2d23f3('0x184')))),_0x5c30f0&&_0x5c30f0[_0x2d23f3('0xb3')]!=='ivr'&&!isNotNull(this['voiceQueues'][_0x5c30f0[_0x2d23f3('0xe1')]][_0x2d23f3('0x60')])&&(delete this[_0x2d23f3('0x1d9')][_0x192e5d['uniqueid']],this[_0x2d23f3('0x1d0')](this[_0x2d23f3('0x1e3')][_0x5c30f0[_0x2d23f3('0xe1')]]),this['voiceQueues'][_0x5c30f0[_0x2d23f3('0xe1')]]['outboundUnknownCallsDay']+=0x1,_0x122c65=new Hangup(_0x5c30f0,_0x192e5d),_0x122c65[_0x2d23f3('0x8b')]=0xc,_0x122c65['statedesc']=_0x192e5d[_0x2d23f3('0x10a')],_0x122c65[_0x2d23f3('0x5')]=_0x2d23f3('0xf8'),this[_0x2d23f3('0x1b4')](_0x122c65)[_0x2d23f3('0x207')](loggerCatch(_0x2d23f3('0xad'))),this[_0x2d23f3('0x83')](_0x122c65)[_0x2d23f3('0x207')](loggerCatch(_0x2d23f3('0x184'))));},Dialer['prototype'][_0x5be1a4('0x1a2')]=function(_0x5195f1){const _0x17be3b=_0x5be1a4,_0x3d2f6f=this[_0x17be3b('0x1d9')][_0x5195f1[_0x17be3b('0x93')]];if(this[_0x17be3b('0x1e3')][_0x5195f1[_0x17be3b('0xe1')]]){if(_0x3d2f6f&&_0x3d2f6f[_0x17be3b('0xb3')]!=='ivr'){delete this[_0x17be3b('0x1d9')][_0x5195f1[_0x17be3b('0x93')]],this[_0x17be3b('0x1e3')][_0x5195f1[_0x17be3b('0xe1')]][_0x17be3b('0xa6')]+=0x1;const _0x38a1c1=new AgentComplete(_0x3d2f6f,_0x5195f1);_0x5195f1['reason']===_0x17be3b('0x1bb')&&(_0x38a1c1[_0x17be3b('0x6a')]=this[_0x17be3b('0x1e3')][_0x5195f1[_0x17be3b('0xe1')]][_0x17be3b('0x10c')]&&this['voiceQueues'][_0x5195f1['queue']][_0x17be3b('0x144')]?moment()[_0x17be3b('0x29')](_0x17be3b('0xdb')):undefined),this[_0x17be3b('0x1b4')](_0x38a1c1)['catch'](loggerCatch(_0x17be3b('0x1ae'))),this[_0x17be3b('0x83')](_0x38a1c1)[_0x17be3b('0x207')](loggerCatch('[syncAgentComplete]'));}}},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0xa4')]=function(_0x5bd02a){const _0x212a9d=_0x5be1a4;this['voiceQueues'][_0x5bd02a['queue']]&&(this[_0x212a9d('0x1d9')][_0x5bd02a[_0x212a9d('0x93')]]&&this[_0x212a9d('0x1d9')][_0x5bd02a[_0x212a9d('0x93')]]['type']!==_0x212a9d('0x176')&&(this[_0x212a9d('0x1d0')](this[_0x212a9d('0x1e3')][_0x5bd02a[_0x212a9d('0xe1')]]),this[_0x212a9d('0x1d9')][_0x5bd02a['uniqueid']][_0x212a9d('0x105')]=moment()[_0x212a9d('0x29')](_0x212a9d('0xdb'))));},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0xeb')]=function(_0x234029){const _0x3bbe23=_0x5be1a4;this[_0x3bbe23('0x1b4')](_0x234029)[_0x3bbe23('0x207')](loggerCatch(_0x3bbe23('0x1ae'))),this[_0x3bbe23('0x83')](_0x234029)[_0x3bbe23('0x207')](loggerCatch('[syncQueueCallerAbandon]\x20[Drop]'));},Dialer[_0x5be1a4('0x141')]['syncQueueCallerAbandon']=function(_0x471198){const _0xc2581=_0x5be1a4,_0x38384a=this[_0xc2581('0x1d9')][_0x471198[_0xc2581('0x93')]];if(this[_0xc2581('0x1e3')][_0x471198[_0xc2581('0xe1')]]){if(_0x38384a&&_0x38384a[_0xc2581('0xb3')]!==_0xc2581('0x176')){delete this[_0xc2581('0x1d9')][_0x471198['uniqueid']],this[_0xc2581('0x1d0')](this[_0xc2581('0x1e3')][_0x471198[_0xc2581('0xe1')]]),_0x38384a[_0xc2581('0x9e')]=moment()[_0xc2581('0x29')](_0xc2581('0xdb'));const _0xf2d1c2=new QueueCallerAbandon(_0x38384a,_0x471198);if(getSeconds(_0x38384a[_0xc2581('0x9e')],_0x38384a[_0xc2581('0x1e')])>=_0x38384a[_0xc2581('0x9d')]){this['voiceQueues'][_0x471198[_0xc2581('0xe1')]][_0xc2581('0x1ce')]+=0x1,this[_0xc2581('0x1e3')][_0x471198[_0xc2581('0xe1')]][_0xc2581('0x180')]+=0x1,this[_0xc2581('0x1e3')][_0x471198['queue']][_0xc2581('0xde')]+=0x1,_0xf2d1c2[_0xc2581('0x8b')]=0xa,_0xf2d1c2[_0xc2581('0x196')]='Drop',_0xf2d1c2[_0xc2581('0x9')]=_0xc2581('0xd2'),_0xf2d1c2[_0xc2581('0x6a')]=this['voiceQueues'][_0x471198['queue']]['dialQueueProject2']?moment()['format'](_0xc2581('0xdb')):undefined,_0xf2d1c2[_0xc2581('0x82')]+=0x1,_0xf2d1c2[_0xc2581('0x94')]+=0x1;if(_0xf2d1c2['countdropretry']>=this[_0xc2581('0x1e3')][_0x471198[_0xc2581('0xe1')]][_0xc2581('0x1cd')])this[_0xc2581('0xeb')](_0xf2d1c2);else{this[_0xc2581('0x172')]({'active':![],'countdropretry':_0xf2d1c2['countdropretry'],'scheduledat':moment()[_0xc2581('0x4e')](this[_0xc2581('0x1e3')][_0x471198[_0xc2581('0xe1')]][_0xc2581('0x1fe')],'minutes')[_0xc2581('0x29')](_0xc2581('0xdb')),'ContactId':_0x38384a[_0xc2581('0x208')],'ListId':_0x38384a[_0xc2581('0x13')],'VoiceQueueId':_0x38384a[_0xc2581('0x18f')]||undefined,'CampaignId':_0x38384a['CampaignId']||undefined})[_0xc2581('0x207')](loggerCatch(_0xc2581('0x104')));const _0x1608c3=new History(_0xf2d1c2);_0x1608c3[_0xc2581('0x8b')]=0xa,_0x1608c3[_0xc2581('0x196')]='Drop',_0x1608c3[_0xc2581('0x1dc')]=moment()[_0xc2581('0x29')](_0xc2581('0xdb')),_0x1608c3['endtime']=_0x1608c3[_0xc2581('0x1dc')],_0x1608c3['calleridname']=_0xf2d1c2[_0xc2581('0x56')],_0x1608c3[_0xc2581('0x179')]=_0xf2d1c2[_0xc2581('0x179')],this[_0xc2581('0x1b4')](_0x1608c3)['catch'](loggerCatch(_0xc2581('0x54')));}}else{this[_0xc2581('0x1e3')][_0x471198[_0xc2581('0xe1')]][_0xc2581('0x8a')]+=0x1,this[_0xc2581('0x1e3')][_0x471198[_0xc2581('0xe1')]][_0xc2581('0x167')]+=0x1,_0xf2d1c2['state']=0xb,_0xf2d1c2[_0xc2581('0x196')]='Abandoned',_0xf2d1c2['dropreason']=_0xc2581('0x1cb'),_0xf2d1c2['countabandonedretry']+=0x1,_0xf2d1c2['countglobal']+=0x1;if(_0xf2d1c2[_0xc2581('0x36')]>=this[_0xc2581('0x1e3')][_0x471198[_0xc2581('0xe1')]][_0xc2581('0xab')])this['queueCallerAbandonCreateState'](_0xf2d1c2);else{this[_0xc2581('0x172')]({'active':![],'countabandonedretry':_0xf2d1c2[_0xc2581('0x36')],'scheduledat':moment()[_0xc2581('0x4e')](this[_0xc2581('0x1e3')][_0x471198['queue']][_0xc2581('0x151')],_0xc2581('0x160'))[_0xc2581('0x29')](_0xc2581('0xdb')),'ContactId':_0x38384a[_0xc2581('0x208')],'ListId':_0x38384a['ListId'],'VoiceQueueId':_0x38384a[_0xc2581('0x18f')]||undefined,'CampaignId':_0x38384a[_0xc2581('0x142')]||undefined})[_0xc2581('0x207')](loggerCatch('[rescheduleContact][Abandoned]'));const _0x10d06b=new History(_0xf2d1c2);_0x10d06b[_0xc2581('0x8b')]=0xb,_0x10d06b[_0xc2581('0x196')]=_0xc2581('0xfb'),_0x10d06b[_0xc2581('0x1dc')]=moment()[_0xc2581('0x29')]('YYYY-MM-DD\x20HH:mm:ss'),_0x10d06b[_0xc2581('0x1b7')]=_0x10d06b['starttime'],_0x10d06b[_0xc2581('0x56')]=_0xf2d1c2[_0xc2581('0x56')],_0x10d06b[_0xc2581('0x179')]=_0xf2d1c2['calleridnum'],this[_0xc2581('0x1b4')](_0x10d06b)[_0xc2581('0x207')](loggerCatch('[syncAgentComplete][createHistory][11]'));}}}}},Dialer[_0x5be1a4('0x141')]['syncNewExten']=function(_0x16ede7){const _0x544810=_0x5be1a4;this[_0x544810('0x6f')][_0x16ede7[_0x544810('0x93')]]&&(this[_0x544810('0x6f')][_0x16ede7[_0x544810('0x93')]][_0x544810('0xd')]=_0x16ede7['channel']),this[_0x544810('0x1d9')][_0x16ede7[_0x544810('0x93')]]&&(this[_0x544810('0x1d9')][_0x16ede7['uniqueid']][_0x544810('0xd')]=_0x16ede7[_0x544810('0xd')]);},Dialer['prototype']['syncQueueMember']=function(_0x1da119){const _0x10a58e=_0x5be1a4;if(strategy[this[_0x10a58e('0x1e3')][this[_0x10a58e('0x6f')][_0x1da119[_0x10a58e('0xd6')]]['queue']][_0x10a58e('0x92')]]===_0x10a58e('0x66'))this[_0x10a58e('0x6f')][_0x1da119['actionid']]&&_[_0x10a58e('0x17f')](this[_0x10a58e('0x6f')][_0x1da119[_0x10a58e('0xd6')]]['locked'])&&_0x1da119[_0x10a58e('0x28')]==='1'&&_0x1da119[_0x10a58e('0xe')]==='0'&&(this[_0x10a58e('0x148')][_0x1da119['stateinterface']]&&(!this[_0x10a58e('0x148')][_0x1da119[_0x10a58e('0x1c3')]][_0x10a58e('0x1ec')]&&(this[_0x10a58e('0x148')][_0x1da119[_0x10a58e('0x1c3')]][_0x10a58e('0x1ec')]=!![],this[_0x10a58e('0x6f')][_0x1da119[_0x10a58e('0xd6')]][_0x10a58e('0x1ec')]=!![],this[_0x10a58e('0x6f')][_0x1da119[_0x10a58e('0xd6')]][_0x10a58e('0x1c3')]=_0x1da119[_0x10a58e('0x1c3')])));else(strategy[this['voiceQueues'][this[_0x10a58e('0x6f')][_0x1da119[_0x10a58e('0xd6')]][_0x10a58e('0xe1')]]['strategy']]||_0x10a58e('0x46'))===_0x10a58e('0x46')&&(this[_0x10a58e('0x6f')][_0x1da119[_0x10a58e('0xd6')]]&&(this[_0x10a58e('0x148')][_0x1da119[_0x10a58e('0x1c3')]]&&(this['actions'][_0x1da119[_0x10a58e('0xd6')]][_0x10a58e('0x1c3')]=_0x1da119['stateinterface'],_[_0x10a58e('0x17f')](this['queueBooked'][this[_0x10a58e('0x6f')][_0x1da119[_0x10a58e('0xd6')]][_0x10a58e('0xe1')]])&&(this['queueBooked'][this[_0x10a58e('0x6f')][_0x1da119[_0x10a58e('0xd6')]][_0x10a58e('0xe1')]]=[]),this[_0x10a58e('0x1b9')][this[_0x10a58e('0x6f')][_0x1da119['actionid']]['queue']]['push'](_['merge'](_[_0x10a58e('0x9c')](this['actions'][_0x1da119[_0x10a58e('0xd6')]],[_0x10a58e('0xe2'),'stateinterface']),{'status':_0x1da119[_0x10a58e('0x28')],'paused':_0x1da119['paused']})))));};function unlockQueueStatus(_0x3ebc90,_0x5d1fe5){setTimeout(function(){const _0x2a52a7=a1057_0x3d95;_[_0x2a52a7('0xac')](_0x3ebc90['queueStatusComplete'])&&loggerBooked[_0x2a52a7('0x10f')](_0x2a52a7('0x9a'),_0x5d1fe5),_0x3ebc90['queueStatusComplete']=!![],loggerBooked[_0x2a52a7('0x1d3')]('[booked][unlockQueueStatus]',_0x5d1fe5,JSON[_0x2a52a7('0xf3')](_[_0x2a52a7('0x9c')](_0x3ebc90,['name',_0x2a52a7('0x1bc')])));},0x1f3);}Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x4b')]=function(_0x2a6ba7){const _0x55a125=_0x5be1a4,_0x3d9ade=this,_0x1300d8=_0x3d9ade[_0x55a125('0x1e3')][_0x3d9ade[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]][_0x55a125('0xe1')]];if(strategy[this[_0x55a125('0x1e3')][this[_0x55a125('0x6f')][_0x2a6ba7['actionid']][_0x55a125('0xe1')]][_0x55a125('0x92')]]==='roundrobin')this[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]]&&this[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]][_0x55a125('0x1c3')]?this[_0x55a125('0x16b')][_0x55a125('0xf7')](this['actions'][_0x2a6ba7[_0x55a125('0xd6')]]['idHopper'],this['actions'][_0x2a6ba7[_0x55a125('0xd6')]][_0x55a125('0x1c3')])[_0x55a125('0x207')](function(_0xd883d9){const _0x5f1865=_0x55a125;logger[_0x5f1865('0x10f')]('[Catch][Preview][syncQueueStatusComplete]',util[_0x5f1865('0x204')](_0xd883d9,{'showHidden':![],'depth':null}));})[_0x55a125('0x20e')](function(){const _0xa2ec7a=_0x55a125;_0x3d9ade['updateOriginated'](_0x3d9ade['voiceQueues'][_0x3d9ade[_0xa2ec7a('0x6f')][_0x2a6ba7['actionid']][_0xa2ec7a('0xe1')]]),_0x3d9ade[_0xa2ec7a('0x148')][_0x3d9ade[_0xa2ec7a('0x6f')][_0x2a6ba7[_0xa2ec7a('0xd6')]][_0xa2ec7a('0x1c3')]]['locked']=![],delete _0x3d9ade[_0xa2ec7a('0x6f')][_0x2a6ba7[_0xa2ec7a('0xd6')]],unlockQueueStatus(_0x1300d8);}):(this[_0x55a125('0x1d0')](this[_0x55a125('0x1e3')][this['actions'][_0x2a6ba7['actionid']]['queue']]),this[_0x55a125('0x172')]({'active':![],'ContactId':this[_0x55a125('0x6f')][_0x2a6ba7['actionid']][_0x55a125('0x208')],'ListId':this['actions'][_0x2a6ba7[_0x55a125('0xd6')]][_0x55a125('0x13')],'VoiceQueueId':this['actions'][_0x2a6ba7['actionid']]['VoiceQueueId']||undefined,'CampaignId':this[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]]['CampaignId']||undefined})[_0x55a125('0x207')](loggerCatch(_0x55a125('0x11f'))),delete this[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]],unlockQueueStatus(_0x1300d8));else{if((strategy[this[_0x55a125('0x1e3')][this['actions'][_0x2a6ba7['actionid']][_0x55a125('0xe1')]][_0x55a125('0x92')]]||'rrmemory')==='rrmemory'){let _0x1a302d;if(this[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]]&&!_[_0x55a125('0x182')](this[_0x55a125('0x1b9')][this['actions'][_0x2a6ba7[_0x55a125('0xd6')]]['queue']])){this[_0x55a125('0x4f')][_0x3d9ade[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]]['queue']]&&(this[_0x55a125('0x4f')][_0x3d9ade[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]]['queue']]=this['queueBookedRR'][this['actions'][_0x2a6ba7[_0x55a125('0xd6')]][_0x55a125('0xe1')]]?this[_0x55a125('0x4f')][this[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]]['queue']]:this[_0x55a125('0x1b9')][this[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]]['queue']]?this['queueBooked'][this['actions'][_0x2a6ba7['actionid']][_0x55a125('0xe1')]][_0x55a125('0x1f1')]||0x0:0x0);this[_0x55a125('0x1b9')][this[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]][_0x55a125('0xe1')]][_0x55a125('0x1f1')]=this['queueBookedRR'][this[_0x55a125('0x6f')][_0x2a6ba7[_0x55a125('0xd6')]]['queue']];for(let _0x3ea628=0x0;_0x3ea628=0x0?!![]:![];})[_0x3b91a0('0x207')](myreject(_0x305966)));}else _0x30d200[_0x3b91a0('0x73')](ami[_0x3b91a0('0x16e')]({'action':_0x3b91a0('0x9f'),'command':util['format'](_0x3b91a0('0x98'),_0x547369,!_[_0x3b91a0('0xac')](config[_0x3b91a0('0x1fd')][_0x1fb598])?_0x1fb598:'')})[_0x3b91a0('0xfe')](function(_0x5d8505){const _0x4b44c0=_0x3b91a0;return _0x5d8505[_0x4b44c0('0x112')]['indexOf']('true')>=0x0?!![]:![];})[_0x3b91a0('0x207')](myreject(_0x305966)));Promise[_0x3b91a0('0x76')](_0x30d200)[_0x3b91a0('0xfe')](function(_0x59074c){const _0x69fcc8=_0x3b91a0,_0x575194=_['some'](_0x59074c);return _0x575194?_0x19400d(_0x575194):(_0x1ac7ca[_0x69fcc8('0x1f6')]=_0x4dfff5?_0x69fcc8('0x17b'):_0x69fcc8('0x81'),_0x305966(msgResponse('[ifTime][promiseAll]',_0x69fcc8('0xb4'),'Global:\x20'+_0x4dfff5+'\x20'+_0x583745+_0x69fcc8('0x145')+util[_0x69fcc8('0x204')](_0x547369,{'showHidden':![],'depth':null})+'Timezone:\x20'+_0x1fb598)));})[_0x3b91a0('0x207')](function(_0x485eea){const _0x2cf152=_0x3b91a0;return _0x305966(msgResponse(_0x2cf152('0x65'),_0x2cf152('0xb4'),JSON['stringify'](_0x485eea)));});});},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x14d')]=function(_0x28bd78){const _0x55bc38=this;return function(){const _0x18cb06=a1057_0x3d95;switch(_0x28bd78[_0x18cb06('0x44')]){case _0x18cb06('0xc8'):freeVariablesPredictive(_0x28bd78),_0x55bc38[_0x18cb06('0x127')](_0x28bd78,0x1);break;case _0x18cb06('0xb8'):freeVariablesPredictive(_0x28bd78),_0x55bc38[_0x18cb06('0x127')](_0x28bd78,_0x28bd78[_0x18cb06('0x3c')]);break;case _0x18cb06('0x163'):_0x55bc38[_0x18cb06('0x163')](_0x28bd78);break;case _0x18cb06('0x147'):freeVariablesPredictive(_0x28bd78),_0x55bc38[_0x18cb06('0x127')](_0x28bd78,0x1);break;default:freeVariablesPredictive(_0x28bd78),logger[_0x18cb06('0x10f')](_0x18cb06('0x7b'),_0x28bd78[_0x18cb06('0x1a8')],_0x18cb06('0x1d6'));}};},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x1d2')]=function(_0x4094aa){const _0x218bd0=this;return function(){_0x218bd0['handleIvr'](_0x4094aa);};},Dialer['prototype'][_0x5be1a4('0xba')]=function(_0x3aeb18){const _0x2e7c2b=_0x5be1a4,_0x4ec2f5=this;isNotPreview(_0x3aeb18[_0x2e7c2b('0x44')])?isVoiceQueueOutbound(_0x3aeb18[_0x2e7c2b('0xb3')])&&isActive(_0x3aeb18[_0x2e7c2b('0x26')])?(_0x3aeb18[_0x2e7c2b('0x75')]=!![],Promise[_0x2e7c2b('0x7a')]()[_0x2e7c2b('0xfe')](checkIsLoggedIn(_0x3aeb18,_0x3aeb18[_0x2e7c2b('0x1fa')]))['then'](checkIsActive(_0x3aeb18,_0x3aeb18[_0x2e7c2b('0x26')]))[_0x2e7c2b('0xfe')](checkInterval(_0x3aeb18))[_0x2e7c2b('0xfe')](_0x4ec2f5[_0x2e7c2b('0x67')](_0x3aeb18))['then'](_0x4ec2f5['checkIfTime'](_0x3aeb18[_0x2e7c2b('0x1de')],_0x3aeb18[_0x2e7c2b('0x123')],_0x3aeb18['name'],_0x3aeb18))[_0x2e7c2b('0xfe')](_0x4ec2f5['checkIfTimeIntervals'](_0x3aeb18['Interval'],_0x3aeb18[_0x2e7c2b('0x123')],_0x3aeb18[_0x2e7c2b('0x1a8')],_0x3aeb18))[_0x2e7c2b('0xfe')](_0x4ec2f5[_0x2e7c2b('0x14d')](_0x3aeb18))[_0x2e7c2b('0x207')](loggerCatchQueueSummary(_0x2e7c2b('0x1a7'),_0x3aeb18))):notSendMessagesQueue(_0x3aeb18):freeVariablesPredictive(_0x3aeb18);},Dialer['prototype'][_0x5be1a4('0x102')]=function(){const _0x1c2013=_0x5be1a4,_0x5dc3bf=this;let _0x29293c;for(const _0x282bd9 in this[_0x1c2013('0x13d')]){typeof this[_0x1c2013('0x13d')][_0x282bd9]!==_0x1c2013('0x8d')&&(_0x29293c=this[_0x1c2013('0x13d')][_0x282bd9],isCampaignIvr(_0x29293c['type'])&&isActive(_0x29293c[_0x1c2013('0x1bd')])?(_0x29293c[_0x1c2013('0x75')]=!![],Promise['resolve']()[_0x1c2013('0xfe')](checkIsActive(_0x29293c,_0x29293c['active']))['then'](checkInterval(_0x29293c))['then'](_0x5dc3bf[_0x1c2013('0x67')](_0x29293c))[_0x1c2013('0xfe')](_0x5dc3bf[_0x1c2013('0x19c')](_0x29293c[_0x1c2013('0x1de')],_0x29293c['dialTimezone'],_0x29293c[_0x1c2013('0x1a8')],_0x29293c))[_0x1c2013('0xfe')](_0x5dc3bf[_0x1c2013('0x1bf')](_0x29293c['Interval'],_0x29293c['dialTimezone'],_0x29293c['name'],_0x29293c))[_0x1c2013('0xfe')](_0x5dc3bf[_0x1c2013('0x1d2')](_0x29293c))[_0x1c2013('0x207')](loggerCatchQueueSummary(_0x1c2013('0x155'),_0x29293c))):notSendMessagesCampaign(_0x29293c));}};function getCallerIdRandom(_0x12c8d4,_0x55cd87){const _0xf6bb06=_0x5be1a4;_0x55cd87<=0x0&&(_0x55cd87=0x1);const _0x57e94d=new RegExp('\x5cw{0,'+_0x55cd87+'}$'),_0x28c64f=Math[_0xf6bb06('0xcc')](0xa,_0x55cd87-0x1),_0x34c7bb=Math[_0xf6bb06('0xcc')](0xa,_0x55cd87)-0x1;return util[_0xf6bb06('0x29')]('%s',_[_0xf6bb06('0x70')](_0x12c8d4,_0x57e94d,_[_0xf6bb06('0xe0')](_0x28c64f,_0x34c7bb)));}function extractCalleridName(_0xaaca8){const _0x4a8d13=_0x5be1a4,_0x2f2f33=_0xaaca8[_0x4a8d13('0x10e')](/"(.*?)"/);return _0x2f2f33?_0x2f2f33[0x1]:_0xaaca8;}function extractCalleridNumber(_0x4c82cd){const _0x2761a3=_0x5be1a4,_0x377e60=_0x4c82cd[_0x2761a3('0x10e')](/<(.*?)>/);return _0x377e60?_0x377e60[0x1]:_0x4c82cd;}Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x61')]=function(_0x5b1352,_0xdf929e){const _0x48baff=_0x5be1a4,_0x2684f7=getConfigService(),_0xf8b877=this,_0x1fd80c=uuid['v4']();return this[_0x48baff('0x6f')][_0x1fd80c]=new Action(_0x5b1352,_0xdf929e,_0x1fd80c),new Promise(function(_0x1af207,_0x38d632){const _0xe40f74=_0x48baff;if(_[_0xe40f74('0xac')](_0x5b1352)&&_0xe40f74('0x133')!==typeof _0x5b1352)return _0x38d632(msgResponse(_0xe40f74('0x1cc'),_0xe40f74('0xb4'),_0xe40f74('0x199')));if(_[_0xe40f74('0xac')](_0xdf929e[_0xe40f74('0xf0')][_0xe40f74('0x164')])||_0xdf929e[_0xe40f74('0xf0')][_0xe40f74('0x164')]===null)return _0x38d632(msgResponse('originate',_0xe40f74('0xb4'),_0xe40f74('0x16a')));const _0x5d4ec8={'XMD-CALLERID':_0xf8b877[_0xe40f74('0x6f')][_0x1fd80c][_0xe40f74('0x1f3')](),'XMD-AGI':_0x5b1352['dialQueueProject']?util['format'](_0xe40f74('0x131'),_0x2684f7[_0xe40f74('0xa7')],_0x5b1352[_0xe40f74('0x60')]):_0xe40f74('0x1a9'),'XMD-AGIAFTER':_0x5b1352[_0xe40f74('0x10c')]?util[_0xe40f74('0x29')](_0xe40f74('0x131'),_0x2684f7[_0xe40f74('0xa7')],_0x5b1352[_0xe40f74('0x10c')]):_0xe40f74('0x1a9'),'XMD-QUEUE':_0x5b1352['type']===_0xe40f74('0xbc')?util[_0xe40f74('0x29')](_0xe40f74('0xc6'),_0x5b1352[_0xe40f74('0x1a8')],_0x5b1352[_0xe40f74('0xa')]||'',_0x5b1352[_0xe40f74('0x144')]?'c':'',_0x5b1352['dialQueueTimeout']||0x3):_0xe40f74('0x1a9'),'XMD-CONTACTID':_0xdf929e[_0xe40f74('0x208')],'XMD-CDRTYPE':_0xe40f74('0x140'),'CALLERID(all)':_0xf8b877['actions'][_0x1fd80c]['getCaller'](),'XMD-AMD':_0x5b1352[_0xe40f74('0x1d7')]?_0xe40f74('0x11a'):_0xe40f74('0x1a9'),'XMD-DESTINATION':'xcally-motion-dialer'};_0x5b1352[_0xe40f74('0x1d7')]&&(_0x5d4ec8['XMD-AMDINITIALSILENCE']=_0x5b1352[_0xe40f74('0xe7')]||0x9c4,_0x5d4ec8[_0xe40f74('0x6b')]=_0x5b1352['dialAMDGreeting']||0x5dc,_0x5d4ec8[_0xe40f74('0xd3')]=_0x5b1352['dialAMDAfterGreetingSilence']||0x320,_0x5d4ec8[_0xe40f74('0x89')]=_0x5b1352[_0xe40f74('0x1ad')]||0x1388,_0x5d4ec8[_0xe40f74('0x1')]=_0x5b1352[_0xe40f74('0x1ee')]||0x64,_0x5d4ec8[_0xe40f74('0x85')]=_0x5b1352[_0xe40f74('0xb5')]||0x32,_0x5d4ec8[_0xe40f74('0x47')]=_0x5b1352['dialAMDMaximumNumberOfWords']||0x3,_0x5d4ec8['XMD-AMDSILENCETHRESHOLD']=_0x5b1352[_0xe40f74('0x143')]||0x100,_0x5d4ec8[_0xe40f74('0x20')]=_0x5b1352['dialAMDMaximumWordLength']||0x1388);_0x5b1352[_0xe40f74('0xb3')]===_0xe40f74('0xbc')?_0x5d4ec8[_0xe40f74('0xdc')]=_0xdf929e['VoiceQueueId']:_0x5d4ec8[_0xe40f74('0x3b')]=_0xdf929e['CampaignId'];for(const _0x4efea6 in _0xdf929e[_0xe40f74('0xf0')]){typeof _0xdf929e[_0xe40f74('0xf0')][_0x4efea6]!=='undefined'&&(isNotNull(_0xdf929e[_0xe40f74('0xf0')][_0x4efea6])&&_0x4efea6!=='id'&&_0x4efea6!==_0xe40f74('0x1aa')&&_0x4efea6!==_0xe40f74('0x3')&&_0x4efea6!=='updatedAt'&&(_0x5d4ec8[util['format'](_0xe40f74('0x165'),_0xe40f74('0xd9'),_[_0xe40f74('0xea')](_0x4efea6))]=_0xdf929e[_0xe40f74('0xf0')][_0x4efea6]));}const _0x5cb145=_0xf8b877[_0xe40f74('0x146')](_0x5b1352[_0xe40f74('0xc4')])?getCallerId(_0x5b1352['Trunk'][_0xe40f74('0xcf')],_0x5b1352[_0xe40f74('0x4')],_0x5b1352[_0xe40f74('0x15d')]>0x0?getCallerIdRandom(_0x5b1352[_0xe40f74('0x16')],_0x5b1352[_0xe40f74('0x15d')]):_0x5b1352[_0xe40f74('0x16')]):getCallerId(_[_0xe40f74('0x17f')](_0x5b1352['TrunkBackup'])?_0x5b1352['Trunk'][_0xe40f74('0xcf')]:_0x5b1352[_0xe40f74('0x6c')][_0xe40f74('0xcf')],_0x5b1352[_0xe40f74('0x4')],_0x5b1352[_0xe40f74('0x15d')]>0x0?getCallerIdRandom(_0x5b1352[_0xe40f74('0x16')],_0x5b1352['dialRandomLastDigitCallerIdNumber']):_0x5b1352['dialOriginateCallerIdNumber']);if(_0x5cb145){const _0x4aefe4=extractCalleridName(_0x5cb145);_0x5d4ec8[_0xe40f74('0x11b')]=_0x4aefe4,_0xf8b877[_0xe40f74('0x6f')][_0x1fd80c][_0xe40f74('0x19a')]=_0x4aefe4;const _0x305dfd=extractCalleridNumber(_0x5cb145);_0x5d4ec8[_0xe40f74('0x4a')]==_0x305dfd,_0xf8b877[_0xe40f74('0x6f')][_0x1fd80c]['originatecalleridnum']=_0x305dfd;}return ami['Action']({'actionid':_0x1fd80c,'action':'originate','channel':_0xf8b877['isTrunkReachable'](_0x5b1352['Trunk'])?util[_0xe40f74('0x29')](_0xe40f74('0x35'),_0x5b1352['Trunk'][_0xe40f74('0x1a8')],isNotNull(_0x5b1352['dialPrefix'])?_0x5b1352[_0xe40f74('0xd4')][_0xe40f74('0x87')]()||'':'',_0x5b1352['dialCutDigit']>0x0?_0xdf929e[_0xe40f74('0xf0')][_0xe40f74('0x164')][_0xe40f74('0x38')](_0x5b1352[_0xe40f74('0x1d1')]):_0xdf929e[_0xe40f74('0xf0')][_0xe40f74('0x164')]):util[_0xe40f74('0x29')](_0xe40f74('0x35'),_[_0xe40f74('0x17f')](_0x5b1352[_0xe40f74('0x6c')])?_0x5b1352[_0xe40f74('0xc4')][_0xe40f74('0x1a8')]:_0x5b1352['TrunkBackup'][_0xe40f74('0x1a8')],isNotNull(_0x5b1352[_0xe40f74('0xd4')])?_0x5b1352['dialPrefix'][_0xe40f74('0x87')]()||'':'',_0x5b1352[_0xe40f74('0x1d1')]>0x0?_0xdf929e[_0xe40f74('0xf0')]['phone'][_0xe40f74('0x38')](_0x5b1352[_0xe40f74('0x1d1')]):_0xdf929e[_0xe40f74('0xf0')][_0xe40f74('0x164')]),'callerid':_0x5cb145,'Exten':'xcally-motion-dialer','Context':_0xe40f74('0x198'),'Priority':'1','variable':_0x5d4ec8,'timeout':(_0x5b1352['dialOriginateTimeout']||0x1e)*0x3e8,'async':!![],'channelid':_0x1fd80c})[_0xe40f74('0xfe')](function(_0x35fcb3){return _0x1af207(_0x35fcb3);})[_0xe40f74('0x207')](function(_0x3348e7){const _0x597c1a=_0xe40f74;_0x5b1352[_0x597c1a('0x17')]+=0x1;const _0x495d51=new History(_0xf8b877[_0x597c1a('0x6f')][_0x1fd80c]);logger['error'](util[_0x597c1a('0x29')]('[originateError]:\x20%s',JSON[_0x597c1a('0xf3')](_0x3348e7))),_0x495d51['state']=0xe,_0x495d51[_0x597c1a('0x196')]=_0x597c1a('0xa1'),_0x495d51[_0x597c1a('0x1dc')]=moment()[_0x597c1a('0x29')]('YYYY-MM-DD\x20HH:mm:ss'),_0x495d51['endtime']=_0x495d51[_0x597c1a('0x1dc')],_0xf8b877[_0x597c1a('0x1b4')](_0x495d51)['catch'](loggerCatch(_0x597c1a('0xe9'))),_0xf8b877[_0x597c1a('0x83')](_0x495d51)['catch'](loggerCatch(_0x597c1a('0xe9')))['finally'](function(){const _0x5d1001=_0x597c1a;return delete _0xf8b877['actions'][_0x1fd80c],_0x38d632(msgResponse(_0x5d1001('0x1cc'),_0x5d1001('0x150'),_0x5d1001('0x18a')));});});});},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x17d')]=function(_0x4f03dd){const _0x43d4a7=_0x5be1a4,_0x3f0d08=this['actions'][_0x4f03dd[_0x43d4a7('0xd6')]];if(_0x3f0d08){delete this[_0x43d4a7('0x6f')][_0x4f03dd['actionid']],_0x3f0d08['responsetime']=moment()[_0x43d4a7('0x29')]('YYYY-MM-DD\x20HH:mm:ss');const _0x2863f1=_0x3f0d08[_0x43d4a7('0xb3')]===_0x43d4a7('0x176')?this[_0x43d4a7('0x13d')][_0x3f0d08[_0x43d4a7('0xe1')]]:this[_0x43d4a7('0x1e3')][_0x3f0d08[_0x43d4a7('0x113')]()];if(!this['isSuccess'](_0x4f03dd['response']))return this[_0x43d4a7('0x1d0')](_0x2863f1),this[_0x43d4a7('0x12f')](_0x3f0d08,_0x2863f1,_0x4f03dd)[_0x43d4a7('0xfe')](function(){})[_0x43d4a7('0x207')](loggerCatch('[callProgressDetecting]\x20'));else this[_0x43d4a7('0x1d9')][_0x4f03dd[_0x43d4a7('0x93')]]=_0x3f0d08;}},Dialer['prototype'][_0x5be1a4('0x15e')]=function(_0x4b2e3b,_0x3cb8ac,_0x2edc33){const _0xdbc81=_0x5be1a4,_0x34cfb3=new History(_0x3cb8ac);if(_0x34cfb3[_0xdbc81('0x6e')]+_0x34cfb3[_0xdbc81('0x1e9')]+_0x34cfb3[_0xdbc81('0x1b0')]+_0x34cfb3[_0xdbc81('0x1fc')]+_0x34cfb3[_0xdbc81('0x82')]+_0x34cfb3[_0xdbc81('0x36')]+_0x34cfb3['countmachineretry']+_0x34cfb3[_0xdbc81('0xcb')]>=_0x2edc33['dialGlobalMaxRetry']-0x1)return!![];switch(_0x4b2e3b){case 0x3:if(_0x34cfb3['countnoanswerretry']>=_0x2edc33['dialNoAnswerMaxRetry']-0x1)return!![];else this['rescheduleContact']({'active':![],'countnoanswerretry':_0x34cfb3['countnoanswerretry']+=0x1,'scheduledat':moment()[_0xdbc81('0x4e')](_0x2edc33['dialNoAnswerRetryFrequency'],_0xdbc81('0x160'))[_0xdbc81('0x29')]('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x34cfb3[_0xdbc81('0x208')],'ListId':_0x34cfb3['ListId'],'VoiceQueueId':_0x34cfb3[_0xdbc81('0x18f')]||undefined,'CampaignId':_0x34cfb3[_0xdbc81('0x142')]||undefined})[_0xdbc81('0x207')](loggerCatch(_0xdbc81('0x103')));break;case 0x5:if(_0x34cfb3[_0xdbc81('0x6e')]>=_0x2edc33[_0xdbc81('0x1d')]-0x1)return!![];else this['rescheduleContact']({'active':![],'countbusyretry':_0x34cfb3[_0xdbc81('0x6e')]+=0x1,'scheduledat':moment()['add'](_0x2edc33[_0xdbc81('0x15')],_0xdbc81('0x160'))[_0xdbc81('0x29')](_0xdbc81('0xdb')),'ContactId':_0x34cfb3['ContactId'],'ListId':_0x34cfb3[_0xdbc81('0x13')],'VoiceQueueId':_0x34cfb3[_0xdbc81('0x18f')]||undefined,'CampaignId':_0x34cfb3[_0xdbc81('0x142')]||undefined})[_0xdbc81('0x207')](loggerCatch(_0xdbc81('0x1c7')));break;case 0x8:if(_0x34cfb3[_0xdbc81('0x1e9')]>=_0x2edc33[_0xdbc81('0x6d')]-0x1)return!![];else this[_0xdbc81('0x172')]({'active':![],'countcongestionretry':_0x34cfb3[_0xdbc81('0x1e9')]+=0x1,'scheduledat':moment()[_0xdbc81('0x4e')](_0x2edc33['dialCongestionRetryFrequency'],_0xdbc81('0x160'))[_0xdbc81('0x29')](_0xdbc81('0xdb')),'ContactId':_0x34cfb3['ContactId'],'ListId':_0x34cfb3['ListId'],'VoiceQueueId':_0x34cfb3[_0xdbc81('0x18f')]||undefined,'CampaignId':_0x34cfb3[_0xdbc81('0x142')]||undefined})['catch'](loggerCatch(_0xdbc81('0x72')));break;case 0x0:if(_0x34cfb3[_0xdbc81('0x1fc')]>=_0x2edc33['dialNoSuchNumberMaxRetry']-0x1)return!![];else this[_0xdbc81('0x172')]({'active':![],'countnosuchnumberretry':_0x34cfb3[_0xdbc81('0x1fc')]+=0x1,'scheduledat':moment()[_0xdbc81('0x4e')](_0x2edc33[_0xdbc81('0x11c')],_0xdbc81('0x160'))['format']('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x34cfb3[_0xdbc81('0x208')],'ListId':_0x34cfb3[_0xdbc81('0x13')],'VoiceQueueId':_0x34cfb3['VoiceQueueId']||undefined,'CampaignId':_0x34cfb3[_0xdbc81('0x142')]||undefined})['catch'](loggerCatch('[rescheduleContact][NoSuchNumber]'));break;case 0xa:if(_0x34cfb3[_0xdbc81('0x82')]>=_0x2edc33[_0xdbc81('0x1cd')]-0x1)return!![];else this[_0xdbc81('0x172')]({'active':![],'countdropretry':_0x34cfb3[_0xdbc81('0x82')]+=0x1,'scheduledat':moment()[_0xdbc81('0x4e')](_0x2edc33[_0xdbc81('0x1fe')],_0xdbc81('0x160'))[_0xdbc81('0x29')](_0xdbc81('0xdb')),'ContactId':_0x34cfb3[_0xdbc81('0x208')],'ListId':_0x34cfb3[_0xdbc81('0x13')],'VoiceQueueId':_0x34cfb3['VoiceQueueId']||undefined,'CampaignId':_0x34cfb3[_0xdbc81('0x142')]||undefined})[_0xdbc81('0x207')](loggerCatch(_0xdbc81('0x104')));break;case 0xb:if(_0x34cfb3[_0xdbc81('0x36')]>=_0x2edc33['dialAbandonedMaxRetry']-0x1)return!![];else this[_0xdbc81('0x172')]({'active':![],'countabandonedretry':_0x34cfb3[_0xdbc81('0x36')]+=0x1,'scheduledat':moment()[_0xdbc81('0x4e')](_0x2edc33['dialAbandonedRetryFrequency'],'minutes')['format']('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x34cfb3['ContactId'],'ListId':_0x34cfb3[_0xdbc81('0x13')],'VoiceQueueId':_0x34cfb3[_0xdbc81('0x18f')]||undefined,'CampaignId':_0x34cfb3[_0xdbc81('0x142')]||undefined})['catch'](loggerCatch('[rescheduleContact][Abandoned]'));break;case 0x13:if(_0x34cfb3[_0xdbc81('0xa3')]>=_0x2edc33[_0xdbc81('0x1fb')]-0x1)return!![];else this[_0xdbc81('0x172')]({'active':![],'countmachineretry':_0x34cfb3[_0xdbc81('0xa3')]+=0x1,'scheduledat':moment()[_0xdbc81('0x4e')](_0x2edc33['dialMachineRetryFrequency'],'minutes')[_0xdbc81('0x29')]('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x34cfb3[_0xdbc81('0x208')],'ListId':_0x34cfb3[_0xdbc81('0x13')],'VoiceQueueId':_0x34cfb3[_0xdbc81('0x18f')]||undefined,'CampaignId':_0x34cfb3['CampaignId']||undefined})['catch'](loggerCatch(_0xdbc81('0x1ff')));break;case 0x14:if(_0x34cfb3[_0xdbc81('0xcb')]>=_0x2edc33['dialAgentRejectMaxRetry']-0x1)return!![];else this[_0xdbc81('0x172')]({'active':![],'countagentrejectretry':_0x34cfb3[_0xdbc81('0xcb')]+=0x1,'scheduledat':moment()[_0xdbc81('0x4e')](_0x2edc33[_0xdbc81('0x202')],'minutes')['format'](_0xdbc81('0xdb')),'ContactId':_0x34cfb3['ContactId'],'ListId':_0x34cfb3['ListId'],'VoiceQueueId':_0x34cfb3[_0xdbc81('0x18f')]||undefined,'CampaignId':_0x34cfb3['CampaignId']||undefined})['catch'](loggerCatch('[rescheduleContact][AgentReject]'));break;default:return!![];}},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x12f')]=function(_0x54b263,_0x4b9b5b,_0x2c8236){const _0x359081=this,_0x299430=new History(_0x54b263);return new Promise(function(_0x3b68d8,_0x3f6705){const _0x29214d=a1057_0x3d95;if(_[_0x29214d('0xac')](_0x4b9b5b)&&_0x29214d('0x133')!==typeof _0x4b9b5b)return _0x3f6705(msgResponse(_0x29214d('0xdf'),_0x29214d('0xb4'),'entity\x20is\x20undefine'));if(_[_0x29214d('0xac')](_0x2c8236)&&'object'!==typeof _0x2c8236)return _0x3f6705(msgResponse('[callProgressDetecting]',_0x29214d('0xb4'),_0x29214d('0x16f')));switch(_0x2c8236['reason']){case'0':_0x4b9b5b[_0x29214d('0xec')]+=0x1,_0x299430[_0x29214d('0x8b')]=0x0,_0x299430[_0x29214d('0x196')]=_0x29214d('0x68'),_0x299430[_0x29214d('0x1fc')]+=0x1,_0x299430[_0x29214d('0x94')]+=0x1,ami[_0x29214d('0x8c')](_0x29214d('0x84'),ut[_0x29214d('0x139')](_0x54b263,_0x29214d('0x1f8'))),_0x359081[_0x29214d('0x1b4')](_0x299430)[_0x29214d('0x207')](loggerCatch(_0x29214d('0x31')));_0x359081[_0x29214d('0x15e')](0x0,_0x54b263,_0x4b9b5b)&&(_0x299430[_0x29214d('0x1fc')]>=_0x4b9b5b[_0x29214d('0xd5')]?_0x359081[_0x29214d('0x206')](_0x299430,_0x3b68d8,_0x3f6705,'reason\x200\x20no\x20such\x20number....'):_0x359081[_0x29214d('0x27')](_0x299430,_0x3b68d8,_0x3f6705,_0x29214d('0x1e5')));break;case'3':_0x4b9b5b[_0x29214d('0x1c2')]+=0x1,_0x299430[_0x29214d('0x8b')]=0x3,_0x299430[_0x29214d('0x196')]=_0x29214d('0xae'),_0x299430['countnoanswerretry']+=0x1,_0x299430['countglobal']+=0x1,ami[_0x29214d('0x8c')]('custom:agentnoanswer',ut[_0x29214d('0x139')](_0x54b263,_0x29214d('0xa9'))),_0x359081[_0x29214d('0x1b4')](_0x299430)['catch'](loggerCatch(_0x29214d('0xbb')));_0x359081[_0x29214d('0x15e')](0x3,_0x54b263,_0x4b9b5b)&&(_0x299430[_0x29214d('0x1b0')]>=_0x4b9b5b['dialNoAnswerMaxRetry']?_0x359081['createStateFinal'](_0x299430,_0x3b68d8,_0x3f6705,'reason\x203\x20ringing\x20no\x20answer'):_0x359081['stateGlobal'](_0x299430,_0x3b68d8,_0x3f6705,_0x29214d('0x132')));break;case'5':_0x4b9b5b[_0x29214d('0x5d')]+=0x1,_0x299430[_0x29214d('0x8b')]=0x5,_0x299430[_0x29214d('0x196')]=_0x29214d('0xdd'),_0x299430[_0x29214d('0x6e')]+=0x1,_0x299430[_0x29214d('0x94')]+=0x1,ami['emit'](_0x29214d('0xfd'),ut[_0x29214d('0x139')](_0x54b263,_0x29214d('0x1a3'))),_0x359081[_0x29214d('0x1b4')](_0x299430)[_0x29214d('0x207')](loggerCatch(_0x29214d('0x2f')));_0x359081[_0x29214d('0x15e')](0x5,_0x54b263,_0x4b9b5b)&&(_0x299430[_0x29214d('0x6e')]>=_0x4b9b5b['dialBusyMaxRetry']?_0x359081[_0x29214d('0x206')](_0x299430,_0x3b68d8,_0x3f6705,_0x29214d('0x191')):_0x359081[_0x29214d('0x27')](_0x299430,_0x3b68d8,_0x3f6705,_0x29214d('0x191')));break;case'8':_0x4b9b5b[_0x29214d('0x124')]+=0x1,_0x299430['state']=0x8,_0x299430[_0x29214d('0x196')]=_0x29214d('0x166'),_0x299430[_0x29214d('0x1e9')]+=0x1,_0x299430[_0x29214d('0x94')]+=0x1,ami[_0x29214d('0x8c')](_0x29214d('0xbe'),ut[_0x29214d('0x139')](_0x54b263,_0x29214d('0xf4'))),_0x359081[_0x29214d('0x1b4')](_0x299430)[_0x29214d('0x207')](loggerCatch('[syncAgentComplete][createHistory][8]'));_0x359081[_0x29214d('0x15e')](0x8,_0x54b263,_0x4b9b5b)&&(_0x299430[_0x29214d('0x1e9')]>=_0x4b9b5b[_0x29214d('0x6d')]?_0x359081['createStateFinal'](_0x299430,_0x3b68d8,_0x3f6705,'reason\x208\x20congestion'):_0x359081[_0x29214d('0x27')](_0x299430,_0x3b68d8,_0x3f6705,'reason\x208\x20congestion'));break;case'11':_0x4b9b5b[_0x29214d('0x1f5')]+=0x1,_0x299430[_0x29214d('0x8b')]=0xb,_0x299430[_0x29214d('0x196')]='Abandoned',_0x299430[_0x29214d('0x36')]+=0x1,_0x299430['countglobal']+=0x1,_0x359081[_0x29214d('0x1b4')](_0x299430)['catch'](loggerCatch(_0x29214d('0x86')));_0x359081[_0x29214d('0x15e')](0xb,_0x54b263,_0x4b9b5b)&&(_0x299430['countabandonedretry']>=_0x4b9b5b[_0x29214d('0xab')]?_0x359081[_0x29214d('0x206')](_0x299430,_0x3b68d8,_0x3f6705,_0x29214d('0x13e')):_0x359081[_0x29214d('0x27')](_0x299430,_0x3b68d8,_0x3f6705,_0x29214d('0x13e')));break;case'20':_0x4b9b5b[_0x29214d('0x51')]+=0x1,_0x299430[_0x29214d('0x8b')]=0x14,_0x299430[_0x29214d('0x196')]=_0x29214d('0x1d4'),_0x299430[_0x29214d('0xcb')]+=0x1,_0x299430[_0x29214d('0x94')]+=0x1,ami[_0x29214d('0x8c')](_0x29214d('0x169'),ut[_0x29214d('0x139')](_0x54b263,_0x29214d('0xef'))),_0x359081[_0x29214d('0x1b4')](_0x299430)[_0x29214d('0x207')](loggerCatch(_0x29214d('0x57')));_0x359081['checkRetriveMax'](0x14,_0x54b263,_0x4b9b5b)&&(_0x299430[_0x29214d('0xcb')]>=_0x4b9b5b['dialAgentRejectMaxRetry']?_0x359081['createStateFinal'](_0x299430,_0x3b68d8,_0x3f6705,_0x29214d('0x194')):_0x359081[_0x29214d('0x27')](_0x299430,_0x3b68d8,_0x3f6705,_0x29214d('0x194')));break;default:_0x4b9b5b[_0x29214d('0x8')]+=0x1,_0x299430[_0x29214d('0x8b')]=0xc,_0x299430[_0x29214d('0x196')]=_0x2c8236[_0x29214d('0x15a')],_0x359081[_0x29214d('0x1b4')](_0x299430)[_0x29214d('0x207')](loggerCatch('[syncAgentComplete][createHistory][?]'));_0x359081[_0x29214d('0x15e')](_0x2c8236[_0x29214d('0x15a')],_0x54b263,_0x4b9b5b)&&(_0x299430[_0x29214d('0x6e')]+_0x299430[_0x29214d('0x1e9')]+_0x299430[_0x29214d('0x1b0')]+_0x299430['countnosuchnumberretry']+_0x299430[_0x29214d('0x82')]+_0x299430['countabandonedretry']+_0x299430['countmachineretry']+_0x299430[_0x29214d('0xcb')]>=_0x4b9b5b[_0x29214d('0x20d')]?_0x359081[_0x29214d('0x27')](_0x299430,_0x3b68d8,_0x3f6705,_0x2c8236[_0x29214d('0x15a')]):_0x359081[_0x29214d('0x206')](_0x299430,_0x3b68d8,_0x3f6705,_0x2c8236['reason']));}});},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x27')]=function(_0xeccd82,_0x14491a,_0xd5291a,_0x59b5c8){const _0x549762=_0x5be1a4,_0x2d1b4c=new Final(_0xeccd82);_0x2d1b4c['state']=0xf,_0x2d1b4c['statedesc']=_0x549762('0x2e'),this[_0x549762('0x206')](_0x2d1b4c,_0x14491a,_0xd5291a,_0x59b5c8);},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x206')]=function(_0x264b82,_0xda2fb3,_0x54829b,_0x1afd0f){const _0xcf1b69=_0x5be1a4;this[_0xcf1b69('0x83')](_0x264b82)[_0xcf1b69('0xfe')](function(){const _0x2ed4f2=_0xcf1b69;return _0xda2fb3(msgResponse(_0x2ed4f2('0xdf'),_0x2ed4f2('0xf6'),_0x1afd0f));})['catch'](function(){const _0x53fb7f=_0xcf1b69;return _0x54829b(msgResponse(_0x53fb7f('0x109'),_0x53fb7f('0xb4'),_0x53fb7f('0x209')));});},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x163')]=function(_0x595b48){const _0x11c7d0=_0x5be1a4,_0x23135e=_0x595b48[_0x11c7d0('0x1b2')]/0x64,_0x41bb41=_0x595b48[_0x11c7d0('0x180')]/(_0x595b48[_0x11c7d0('0x180')]+_0x595b48[_0x11c7d0('0xa6')]),_0x34f4d8=Math[_0x11c7d0('0xc2')](_0x595b48['predictiveIntervalAvailable']*(_0x595b48['predictiveIntervalMaxThreshold']/0x64)),_0x26084e=Math[_0x11c7d0('0xc2')](_0x595b48['predictiveIntervalAvailable']*(_0x595b48['predictiveIntervalMinThreshold']/0x64)),_0x3dc40c=_0x595b48[_0x11c7d0('0x10d')]+_0x595b48[_0x11c7d0('0x18')],_0x2cef4a=Math['floor'](_0x595b48['erlangCalls']*_0x595b48[_0x11c7d0('0x1ca')]*_0x595b48[_0x11c7d0('0x1e2')]*_0x595b48[_0x11c7d0('0x3a')]);if(_[_0x11c7d0('0xac')](_0x595b48[_0x11c7d0('0x137')]))!_[_0x11c7d0('0xac')](_0x595b48[_0x11c7d0('0x157')])&&(_0x595b48[_0x11c7d0('0x157')]=undefined,loggerPredictive[_0x11c7d0('0x10f')](_0x11c7d0('0x1dd'),'check\x20predictive\x20is\x20not\x20undefine')),!_[_0x11c7d0('0xac')](_0x595b48['handlePredictive'])&&(loggerPredictive[_0x11c7d0('0x10f')](_0x11c7d0('0x1dd'),'check\x20handlePredictive\x20is\x20not\x20undefine'),clearInterval(_0x595b48[_0x11c7d0('0xb9')]),_0x595b48[_0x11c7d0('0xb9')]=undefined),_0x595b48[_0x11c7d0('0x137')]=moment()['format'](_0x11c7d0('0xdb')),loggerPredictive[_0x11c7d0('0x1d3')](_0x595b48['name'],_0x11c7d0('0xfa'),_0x595b48['startProgressive']),this['handlePower'](_0x595b48,0x1);else{if(ifInterval(_0x595b48[_0x11c7d0('0x52')],_0x595b48[_0x11c7d0('0x137')]))this[_0x11c7d0('0x127')](_0x595b48,0x1),loggerPredictiveCalls['info'](_0x11c7d0('0x121'),_0x595b48[_0x11c7d0('0x137')],_0x595b48[_0x11c7d0('0x1a8')]),_0x595b48[_0x11c7d0('0xd1')]=0x0,_0x595b48['predictiveIntervalErlangCallsDroppedCalls']=0x0;else{if(_0x23135e<_0x41bb41&&_0x595b48['dialPredictiveOptimization']===_0x11c7d0('0x14c'))freeVariablesPredictive(_0x595b48),loggerPredictive['info'](_0x11c7d0('0xc1'),_0x11c7d0('0x1ab'),_0x41bb41,_0x11c7d0('0x137'),_0x595b48[_0x11c7d0('0x1a8')]);else{if(_0x2cef4a<_0x595b48['predictiveIntervalErlangCallsDroppedCalls']&&_0x595b48[_0x11c7d0('0xf2')]===_0x11c7d0('0x14c'))freeVariablesPredictive(_0x595b48),loggerPredictive['info'](_0x11c7d0('0x1a'),_0x11c7d0('0x1e1'),_0x2cef4a,_0x11c7d0('0x110'),_0x595b48[_0x11c7d0('0xde')],_0x11c7d0('0x137'),_0x595b48[_0x11c7d0('0x1a8')]);else{if(!ifInterval(_0x595b48[_0x11c7d0('0x52')],_0x595b48[_0x11c7d0('0x137')])&&_[_0x11c7d0('0xac')](_0x595b48[_0x11c7d0('0x157')])&&!_[_0x11c7d0('0xac')](_0x595b48[_0x11c7d0('0x137')]))_0x595b48[_0x11c7d0('0x157')]=moment()[_0x11c7d0('0x29')]('YYYY-MM-DD\x20HH:mm:ss'),loggerPredictive[_0x11c7d0('0x1d3')](_0x595b48[_0x11c7d0('0x1a8')],_0x11c7d0('0x30'),_0x595b48['startPredictive']),this[_0x11c7d0('0x159')](_0x595b48[_0x11c7d0('0x52')])['then'](this[_0x11c7d0('0x7f')](_0x595b48))[_0x11c7d0('0xfe')](mergeDataErlangB(_0x595b48))['then'](this[_0x11c7d0('0x162')](_0x595b48))[_0x11c7d0('0x207')](loggerCatchPredictive('Predictive\x20after\x20first\x20interval',_0x595b48));else{if(!ifInterval(_0x595b48[_0x11c7d0('0x52')],_0x595b48[_0x11c7d0('0x157')]))_0x595b48[_0x11c7d0('0xde')]=0x0,_0x595b48[_0x11c7d0('0x157')]=moment()[_0x11c7d0('0x29')](_0x11c7d0('0xdb')),loggerPredictive[_0x11c7d0('0x1d3')](_0x595b48[_0x11c7d0('0x1a8')],_0x11c7d0('0x5f'),_0x595b48[_0x11c7d0('0x157')]),clearInterval(_0x595b48['handlePredictive']),_0x595b48[_0x11c7d0('0xb9')]=undefined,this[_0x11c7d0('0x159')](_0x595b48[_0x11c7d0('0x52')])[_0x11c7d0('0xfe')](this[_0x11c7d0('0x7f')](_0x595b48))[_0x11c7d0('0xfe')](mergeDataErlangB(_0x595b48))[_0x11c7d0('0xfe')](this[_0x11c7d0('0x162')](_0x595b48))[_0x11c7d0('0x207')](loggerCatchPredictive('Predictive\x20for\x20every\x20interval',_0x595b48));else{if(_0x595b48[_0x11c7d0('0x19')]&&_0x3dc40c<_0x595b48['predictiveIntervalAvailable']-_0x26084e)freeVariablesPredictive(_0x595b48),loggerPredictive['info'](_0x595b48[_0x11c7d0('0x1a8')],_0x11c7d0('0x69'),_0x3dc40c,_0x11c7d0('0x20b'),_0x595b48['predictiveIntervalAvailable'],'-',_0x26084e,'=',_0x595b48['predictiveIntervalAvailable']-_0x26084e,')');else _0x595b48[_0x11c7d0('0x19')]&&_0x3dc40c>_0x595b48[_0x11c7d0('0x19')]+_0x34f4d8&&(freeVariablesPredictive(_0x595b48),loggerPredictive[_0x11c7d0('0x1d3')](_0x595b48[_0x11c7d0('0x1a8')],'switch\x20in\x20progressive\x20because\x20available\x20agents\x20(',_0x3dc40c,_0x11c7d0('0x211'),_0x595b48[_0x11c7d0('0x19')],'+',_0x34f4d8,'=',_0x595b48[_0x11c7d0('0x19')]+_0x34f4d8,')'));}}}}}}},Dialer['prototype'][_0x5be1a4('0x7f')]=function(_0x377eb3){const _0x5fce0a=this;return function(_0x271a92){return new Promise(function(_0x5eb79f,_0x356f73){const _0x55df3c=a1057_0x3d95;_[_0x55df3c('0xb')](_0x377eb3,_0x271a92[0x0]);if(checkGetDataPredictive(_0x271a92[0x0])){const _0x5d7951=_0x377eb3[_0x55df3c('0x18')]+_0x377eb3['available'];_0x377eb3['predictiveIntervalAvailable']=_0x5d7951;const _0x3cd4f3=_0x5d7951,_0x2d41a5=_0x377eb3['dialPredictiveInterval']*0x3c,_0x1cb098=_0x271a92[0x0]['predictiveIntervalAvgTalktime']+_0x271a92[0x0][_0x55df3c('0xb1')],_0x30f962=(_0x271a92[0x0][_0x55df3c('0x15f')]+_0x271a92[0x0][_0x55df3c('0x1ce')]+_0x271a92[0x0]['predictiveIntervalDroppedCallsCallersExit'])/_0x271a92[0x0][_0x55df3c('0x1a5')];_0x377eb3[_0x55df3c('0x1e2')]=_0x30f962>0x0?_0x30f962:0x1;switch(_0x377eb3['dialPredictiveOptimization']){case _0x55df3c('0x14c'):{const _0x235d9c=_0x377eb3[_0x55df3c('0x1b2')]/0x64;return _0x5fce0a[_0x55df3c('0x1b8')](_0x3cd4f3,_0x2d41a5,_0x1cb098,_0x30f962,_0x235d9c)[_0x55df3c('0xfe')](function(_0x3890c0){return _0x5eb79f(_0x3890c0);});}case _0x55df3c('0x174'):{const _0x2d3de5=_0x377eb3[_0x55df3c('0x1b2')]/0x64;return _0x5fce0a[_0x55df3c('0x1a1')](_0x3cd4f3,_0x2d41a5,_0x1cb098,_0x30f962,_0x2d3de5)[_0x55df3c('0xfe')](function(_0x2b9355){return _0x5eb79f(_0x2b9355);});}default:return _0x356f73(msgResponse(_0x55df3c('0x117'),'Failure','Unknown\x20Predictive'));}}else return _0x356f73(msgResponse('[getDataPredictive]',_0x55df3c('0xb4'),'check\x20failure'));});};},Dialer[_0x5be1a4('0x141')]['getDataPredictiveOld']=function(_0x5163cf){const _0xe48f4=this;return function(_0x4c1a1a){return new Promise(function(_0x1cf2c6,_0x37b496){const _0x3e005c=a1057_0x3d95;_[_0x3e005c('0xb')](_0x5163cf,_0x4c1a1a[0x0]);if(checkGetDataPredictive(_0x4c1a1a[0x0])){loggerPredictive[_0x3e005c('0x1d3')](JSON[_0x3e005c('0xf3')](_0x4c1a1a[0x0]));if(_0x5163cf[_0x3e005c('0xf2')]==='dropRate')return _0xe48f4['getVoiceQueueRtPauses'](_0x5163cf['id'])['then'](function(_0x49fe8a){const _0x36a34b=_0x3e005c,_0x2028e7=_0x5163cf['loggedIn']-_0x49fe8a[0x0][_0x36a34b('0xaa')],_0x598bee=_0x5163cf[_0x36a34b('0x52')]*0x3c,_0x35c75d=_0x4c1a1a[0x0][_0x36a34b('0x12a')]+_0x4c1a1a[0x0][_0x36a34b('0xb1')],_0x57873a=(_0x4c1a1a[0x0][_0x36a34b('0x15f')]+_0x4c1a1a[0x0][_0x36a34b('0x1ce')]+_0x4c1a1a[0x0][_0x36a34b('0x8a')])/_0x4c1a1a[0x0][_0x36a34b('0x1a5')],_0xd8595d=_0x5163cf['dialPredictiveOptimizationPercentage']/0x64;return _0x5163cf['predictiveIntervalPauses']=_0x49fe8a[0x0][_0x36a34b('0xaa')]||0x0,_0x5163cf['predictiveIntervalHitRate']=_0x57873a>0x0?_0x57873a:0x1,_0xe48f4[_0x36a34b('0x1b8')](_0x2028e7,_0x598bee,_0x35c75d,_0x57873a,_0xd8595d);})['then'](function(_0xd06b1f){return _0x1cf2c6(_0xd06b1f);})[_0x3e005c('0x207')](function(_0x145f36){const _0x5d0277=_0x3e005c;return _0x37b496(msgResponse(_0x5d0277('0x43'),_0x5d0277('0xb4'),JSON[_0x5d0277('0xf3')](_0x145f36)));});if(_0x5163cf[_0x3e005c('0xf2')]===_0x3e005c('0x174'))return _0xe48f4[_0x3e005c('0xc5')](_0x5163cf['id'])['then'](function(_0x56013e){const _0x53e0ea=_0x3e005c,_0x49eca9=_0x5163cf['loggedIn']-_0x56013e[0x0]['outboundQueuePauses'],_0x3ae968=_0x5163cf['dialPredictiveInterval']*0x3c,_0x5717b6=_0x4c1a1a[0x0]['predictiveIntervalAvgTalktime']+_0x4c1a1a[0x0][_0x53e0ea('0xb1')],_0x5e5b6f=(_0x4c1a1a[0x0][_0x53e0ea('0x15f')]+_0x4c1a1a[0x0][_0x53e0ea('0x1ce')]+_0x4c1a1a[0x0]['predictiveIntervalDroppedCallsCallersExit'])/_0x4c1a1a[0x0][_0x53e0ea('0x1a5')],_0x1bf116=_0x5163cf[_0x53e0ea('0x1b2')]/0x64;return _0x5163cf[_0x53e0ea('0x111')]=_0x56013e[0x0]['outboundQueuePauses']||0x0,_0x5163cf[_0x53e0ea('0x1e2')]=_0x5e5b6f>0x0?_0x5e5b6f:0x1,_0xe48f4[_0x53e0ea('0x1a1')](_0x49eca9,_0x3ae968,_0x5717b6,_0x5e5b6f,_0x1bf116);})[_0x3e005c('0xfe')](function(_0x4d9148){return _0x1cf2c6(_0x4d9148);})[_0x3e005c('0x207')](function(_0x27b7f8){const _0x469cde=_0x3e005c;return _0x37b496(msgResponse('[CatchErlangB]',_0x469cde('0xb4'),JSON[_0x469cde('0xf3')](_0x27b7f8)));});}else return _0x37b496(msgResponse(_0x3e005c('0x117'),_0x3e005c('0xb4'),_0x3e005c('0xf')));});};},Dialer[_0x5be1a4('0x141')]['startMethodPredictive']=function(_0x464d21){const _0x348239=this;return function(){const _0x5c3f53=a1057_0x3d95;let _0x96a7ea=0x0,_0x3eeec9=Math[_0x5c3f53('0x125')](_0x464d21[_0x5c3f53('0x20f')]*0x3e8);_0x3eeec9>0x0?(_0x3eeec9=_0x3eeec9<0x64?0x64:_0x3eeec9,loggerPredictive['info'](_0x464d21[_0x5c3f53('0x1a8')],_0x5c3f53('0xbf'),_0x3eeec9,_0x5c3f53('0x21')),_0x464d21['handlePredictive']=setInterval(function(){const _0x2b4b39=_0x5c3f53;_0x348239[_0x2b4b39('0xb9')](_0x464d21),loggerPredictiveCalls[_0x2b4b39('0x1d3')](_0x2b4b39('0x122'),_0x96a7ea+=0x1);},_0x3eeec9)):loggerPredictive[_0x5c3f53('0x1d3')](_0x464d21[_0x5c3f53('0x1a8')],_0x5c3f53('0x58'));};},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0xc9')]=function(_0x192690,_0x5af38f){const _0x5b7d5d=this;return function(_0x461b5f){const _0x323a6c=a1057_0x3d95;if(_[_0x323a6c('0x182')](_0x461b5f)){if(_[_0x323a6c('0x17f')](_0x5af38f['UserId'])||!_0x5af38f[_0x323a6c('0x90')]){if(_0x192690[_0x323a6c('0x44')]===_0x323a6c('0x147')){_0x192690[_0x323a6c('0x1bc')]=_['isUndefined'](_0x192690['queueStatusComplete'])?!![]:_0x192690['queueStatusComplete'];const _0x4bb165=uuid['v4']();_0x5b7d5d['actions'][_0x4bb165]=new Action(_0x192690,_0x5af38f,_0x4bb165),loggerBooked['info']('[booked][checkContactBlack]',_0x4bb165,_0x323a6c('0x42'),JSON['stringify'](_0x192690['queueStatusComplete']),'Queue:\x20',_0x192690[_0x323a6c('0x1a8')]),_0x192690[_0x323a6c('0x1bc')]?(_0x192690[_0x323a6c('0x1bc')]=![],_0x5b7d5d[_0x323a6c('0x1b9')][_0x5b7d5d['actions'][_0x4bb165][_0x323a6c('0xe1')]]=[],ami[_0x323a6c('0x16e')]({'actionid':_0x4bb165,'action':_0x323a6c('0x200'),'queue':_0x192690['name']})[_0x323a6c('0x207')](function(){const _0x31b9b7=_0x323a6c;_0x5b7d5d[_0x31b9b7('0x1d0')](_0x192690),_0x5b7d5d[_0x31b9b7('0x172')]({'active':![],'ContactId':_0x5b7d5d[_0x31b9b7('0x6f')][_0x4bb165][_0x31b9b7('0x208')],'ListId':_0x5b7d5d[_0x31b9b7('0x6f')][_0x4bb165][_0x31b9b7('0x13')],'VoiceQueueId':_0x5b7d5d[_0x31b9b7('0x6f')][_0x4bb165][_0x31b9b7('0x18f')]||undefined,'CampaignId':_0x5b7d5d['actions'][_0x4bb165][_0x31b9b7('0x142')]||undefined})[_0x31b9b7('0x207')](loggerCatch(_0x31b9b7('0x7e'))),delete _0x5b7d5d[_0x31b9b7('0x6f')][_0x4bb165];})):(loggerBooked[_0x323a6c('0x1d3')](_0x323a6c('0x13c'),JSON[_0x323a6c('0xf3')](_0x192690['queueStatusComplete']),_0x323a6c('0x178'),_0x192690[_0x323a6c('0x1a8')]),_0x5b7d5d[_0x323a6c('0x1d0')](_0x192690),_0x5b7d5d['rescheduleContact']({'active':![],'ContactId':_0x5b7d5d[_0x323a6c('0x6f')][_0x4bb165][_0x323a6c('0x208')],'ListId':_0x5b7d5d['actions'][_0x4bb165][_0x323a6c('0x13')],'VoiceQueueId':_0x5b7d5d[_0x323a6c('0x6f')][_0x4bb165][_0x323a6c('0x18f')]||undefined,'CampaignId':_0x5b7d5d[_0x323a6c('0x6f')][_0x4bb165][_0x323a6c('0x142')]||undefined})['catch'](loggerCatch('[unlockOriginate][syncQueueStatusComplete]')),delete _0x5b7d5d[_0x323a6c('0x6f')][_0x4bb165]);}else return _0x5b7d5d[_0x323a6c('0x61')](_0x192690,_0x5af38f);}else getDiff(_0x5af38f[_0x323a6c('0x32')])<_0x192690[_0x323a6c('0x1f0')]*0x3c?_0x5af38f[_0x323a6c('0x1c0')]&&!_0x5af38f['Agent'][_0x323a6c('0x5b')]?_0x5b7d5d['preview']['run'](_0x5af38f['id'])[_0x323a6c('0x20e')](function(){const _0x3adc52=_0x323a6c;_0x5b7d5d[_0x3adc52('0x1d0')](_0x192690);}):_0x5b7d5d[_0x323a6c('0x175')]({'active':![]},_0x5af38f['id'],0x1)[_0x323a6c('0x20e')](function(){const _0xd88b82=_0x323a6c;console[_0xd88b82('0x10b')](_0xd88b82('0x19d')),_0x5b7d5d[_0xd88b82('0x1d0')](_0x192690);}):(_0x192690[_0x323a6c('0x16d')]+=0x1,_0x5b7d5d[_0x323a6c('0x1d0')](_0x192690),_0x192690[_0x323a6c('0x1d5')]?(_0x5b7d5d[_0x323a6c('0x172')]({'active':![],'recallme':![],'UserId':null,'ContactId':_0x5af38f[_0x323a6c('0x208')],'ListId':_0x5af38f[_0x323a6c('0x13')],'VoiceQueueId':_0x5af38f[_0x323a6c('0x18f')]||undefined,'CampaignId':_0x5af38f['CampaignId']||undefined})[_0x323a6c('0x207')](loggerCatch(_0x323a6c('0xc7'))),_0x5b7d5d[_0x323a6c('0x1b4')](createObjHistory(_0x192690,_0x5af38f,'RECALLINQUEUE',0x17,'RecallInQueue'))[_0x323a6c('0x207')](loggerCatch(_0x323a6c('0x130')))):_0x5b7d5d[_0x323a6c('0xb6')](createObjHistory(_0x192690,_0x5af38f,_0x323a6c('0x1c6'),0x16,_0x323a6c('0x39')),_0x323a6c('0xe5'),_0x323a6c('0x186')));}else{_0x192690['outboundBlacklistCallsDay']+=0x1,_0x5b7d5d[_0x323a6c('0xb6')](createObjHistory(_0x192690,_0x5af38f,'BLACKLIST',0xd,_0x323a6c('0x9b')),_0x323a6c('0x15b'),_0x323a6c('0x22'));throw _0x323a6c('0x1ac');}};},Dialer['prototype'][_0x5be1a4('0x41')]=function(_0x42abd8){const _0x31beb6=_0x5be1a4,_0x4e9513=this;let _0x39cd82=_0x42abd8['limitCalls']-_0x42abd8['originated']-_0x42abd8[_0x31beb6('0x1af')];emitCampaignSummary(_0x42abd8),_0x39cd82>0x0&&(_0x39cd82>this['maxNumberOriginate']&&(_0x39cd82=this[_0x31beb6('0x1db')]),_0x42abd8[_0x31beb6('0x1af')]+=_0x39cd82,this[_0x31beb6('0x7d')](_0x42abd8['id'],_0x39cd82,_0x42abd8[_0x31beb6('0x7c')])[_0x31beb6('0xfe')](function(_0x477f61){const _0x4d688e=_0x31beb6;_0x42abd8[_0x4d688e('0x1af')]-=_0x39cd82,_0x42abd8[_0x4d688e('0x1af')]=_0x42abd8[_0x4d688e('0x1af')]>0x0?_0x42abd8[_0x4d688e('0x1af')]:0x0;if(!checkContactEmpty(_0x477f61))_0x42abd8[_0x4d688e('0x1f6')]=_0x4d688e('0xff'),logger[_0x4d688e('0x1d3')]('[getContactCampaign2][Empty]'+_0x42abd8[_0x4d688e('0x1a8')]);else{_0x42abd8[_0x4d688e('0xb7')]+=_0x477f61['length'],_0x42abd8[_0x4d688e('0x1f6')]=_0x4d688e('0xc0');for(let _0x443cf1=0x0;_0x443cf1<_0x477f61[_0x4d688e('0xa5')];_0x443cf1+=0x1){_0x42abd8['ivrTotalCallsDays']+=0x1,_['isNil'](_0x477f61[_0x443cf1])||_[_0x4d688e('0x17f')](_0x477f61[_0x443cf1][_0x4d688e('0xf0')])||_[_0x4d688e('0x17f')](_0x477f61[_0x443cf1][_0x4d688e('0xf0')][_0x4d688e('0x164')])?_0x4e9513[_0x4d688e('0xf1')](_0x4d688e('0x14b'),_0x42abd8,_0x477f61[_0x443cf1]):_0x4e9513['checkIsBlackListIvr'](_['pick'](_0x477f61[_0x443cf1],[_0x4d688e('0x142'),_0x4d688e('0xe3')]))[_0x4d688e('0xfe')](_0x4e9513['checkContactBlack'](_0x42abd8,_0x477f61[_0x443cf1]))[_0x4d688e('0x207')](_0x4e9513[_0x4d688e('0x1b3')](_0x4d688e('0x18e'),_0x42abd8));}}})[_0x31beb6('0x207')](loggerGetContactDialer(_0x31beb6('0x120'),_0x42abd8,_0x39cd82)));},Dialer[_0x5be1a4('0x141')]['handlePower']=function(_0x2baa45,_0x26e92){const _0x38df90=_0x5be1a4,_0x3d2ce7=this,_0x3894bf=[];let _0x160dfc=_0x26e92>=0x1?_0x26e92:0x1;_0x2baa45[_0x38df90('0x44')]===_0x38df90('0x147')&&(_0x160dfc=0x1);let _0x3186fc=Math[_0x38df90('0x125')](_0x2baa45[_0x38df90('0x10d')]*_0x160dfc)-_0x2baa45[_0x38df90('0xb7')]-_0x2baa45[_0x38df90('0x1af')];emitVoiceQueueSummary(_0x2baa45);if(_0x2baa45['dialLimitQueue']>0x0){const _0xbe43ba=_0x2baa45[_0x38df90('0x37')]-_0x2baa45[_0x38df90('0xb7')]-_0x2baa45[_0x38df90('0x18')]-_0x2baa45[_0x38df90('0x1af')]-_0x2baa45[_0x38df90('0x12b')];_0x3186fc>_0xbe43ba&&(_0x3186fc=_0xbe43ba);}if(_0x3186fc>0x0){_0x2baa45[_0x38df90('0x44')]===_0x38df90('0x147')&&(_0x3186fc=0x1);_0x3186fc>this[_0x38df90('0x1db')]&&(_0x3186fc=this['maxNumberOriginate']);_0x2baa45[_0x38df90('0x1af')]+=_0x3186fc;for(const _0x2665b5 in this['agents']){typeof this['agents'][_0x2665b5]!=='undefined'&&(this['agents'][_0x2665b5][_0x38df90('0x8b')]===_0x38df90('0xe4')&&this['agents'][_0x2665b5][_0x38df90('0x28')]==='reachable'&&_0x3894bf[_0x38df90('0x73')](this['agents'][_0x2665b5]['id']));}this['getContactDialer'](_0x2baa45['id'],_0x3894bf,_0x3186fc,_0x2baa45[_0x38df90('0x7c')])[_0x38df90('0xfe')](function(_0x14222d){const _0x33cf51=_0x38df90;_0x2baa45[_0x33cf51('0x1af')]-=_0x3186fc,_0x2baa45[_0x33cf51('0x1af')]=_0x2baa45[_0x33cf51('0x1af')]>0x0?_0x2baa45['temp']:0x0;if(!checkContactEmpty(_0x14222d))_0x3d2ce7[_0x33cf51('0x33')](_0x2baa45)['then'](sendMessageReschedule(_0x2baa45))[_0x33cf51('0x207')](loggerCatch(_0x33cf51('0x1f')));else{_0x2baa45[_0x33cf51('0xb7')]+=_0x14222d['length'],_0x2baa45[_0x33cf51('0x1f6')]=_0x2baa45[_0x33cf51('0x44')]===_0x33cf51('0x147')?_0x33cf51('0x11a'):'RUNNING';for(let _0x2255fa=0x0;_0x2255fa<_0x14222d[_0x33cf51('0xa5')];_0x2255fa+=0x1){_[_0x33cf51('0x17f')](_0x14222d[_0x2255fa])||_[_0x33cf51('0x17f')](_0x14222d[_0x2255fa][_0x33cf51('0xf0')])||_[_0x33cf51('0x17f')](_0x14222d[_0x2255fa][_0x33cf51('0xf0')][_0x33cf51('0x164')])?_0x3d2ce7['emptyContact']('[actionOriginate]\x20',_0x2baa45,_0x14222d[_0x2255fa]):_0x3d2ce7[_0x33cf51('0x11e')](_['pick'](_0x14222d[_0x2255fa],[_0x33cf51('0x18f'),_0x33cf51('0xe3')]))['then'](_0x3d2ce7[_0x33cf51('0xc9')](_0x2baa45,_0x14222d[_0x2255fa]))[_0x33cf51('0x207')](_0x3d2ce7[_0x33cf51('0x1b3')](_0x33cf51('0x14b'),_0x2baa45));}}})[_0x38df90('0x207')](loggerGetContactDialer(_0x38df90('0x1e4'),_0x2baa45,_0x3186fc));}},Dialer['prototype'][_0x5be1a4('0xb9')]=function(_0x4b48b2){const _0xad6ffc=_0x5be1a4;if(_0x4b48b2[_0xad6ffc('0x37')]>0x0){const _0x506cf6=_0x4b48b2[_0xad6ffc('0x37')]-_0x4b48b2['originated']-_0x4b48b2[_0xad6ffc('0x18')];_0x506cf6>0x0?this[_0xad6ffc('0x3f')](_0x4b48b2):loggerPredictiveCalls[_0xad6ffc('0x1d3')](_0xad6ffc('0x168'));}else this['tryOriginatePredictive'](_0x4b48b2);},Dialer[_0x5be1a4('0x141')]['tryOriginatePredictive']=function(_0xe0bd67){const _0x1e7bd4=_0x5be1a4,_0x577610=this,_0x5e4c1b=[];_0xe0bd67[_0x1e7bd4('0xb7')]+=0x1;for(const _0x581d8f in this[_0x1e7bd4('0x148')]){typeof this[_0x1e7bd4('0x148')][_0x581d8f]!==_0x1e7bd4('0x8d')&&(this['agents'][_0x581d8f][_0x1e7bd4('0x8b')]===_0x1e7bd4('0xe4')&&this['agents'][_0x581d8f]['status']===_0x1e7bd4('0x1ba')&&_0x5e4c1b['push'](this[_0x1e7bd4('0x148')][_0x581d8f]['id']));}this[_0x1e7bd4('0xc')](_0xe0bd67['id'],_0x5e4c1b,0x1,_0xe0bd67[_0x1e7bd4('0x7c')])[_0x1e7bd4('0xfe')](function(_0x752c0){const _0x56fcc5=_0x1e7bd4;!checkContactEmpty(_0x752c0)?(checkContactLowerLimitOriginate(_0xe0bd67,0x1,0x0),_0x577610['countReScheduled'](_0xe0bd67)[_0x56fcc5('0xfe')](sendMessageReschedule(_0xe0bd67))[_0x56fcc5('0x207')](loggerCatch(_0x56fcc5('0x1f')))):(_0xe0bd67[_0x56fcc5('0x1f6')]=_0x56fcc5('0xc0'),_[_0x56fcc5('0x17f')](_0x752c0[0x0])||_[_0x56fcc5('0x17f')](_0x752c0[0x0][_0x56fcc5('0xf0')])||_[_0x56fcc5('0x17f')](_0x752c0[0x0][_0x56fcc5('0xf0')][_0x56fcc5('0x164')])?_0x577610['emptyContact']('[actionOriginate]\x20',_0xe0bd67,_0x752c0[0x0]):_0x577610[_0x56fcc5('0x11e')](_[_0x56fcc5('0x9c')](_0x752c0[0x0],[_0x56fcc5('0x18f'),_0x56fcc5('0xe3')]))[_0x56fcc5('0xfe')](_0x577610[_0x56fcc5('0xc9')](_0xe0bd67,_0x752c0[0x0]))[_0x56fcc5('0x207')](_0x577610['loggerHandler'](_0x56fcc5('0x99'),_0xe0bd67)));})[_0x1e7bd4('0x207')](loggerGetContactDialer(_0x1e7bd4('0x188'),_0xe0bd67,0x1)),emitVoiceQueueSummary(_0xe0bd67);},Dialer[_0x5be1a4('0x141')][_0x5be1a4('0x1b8')]=function(_0xeaf77a,_0x4b860c,_0x24a1b3,_0x2a91ae,_0x35894b,_0x2aa245){const _0x468ca8=_0x5be1a4;return loggerPredictive[_0x468ca8('0x1d3')](_0x468ca8('0x18d')),loggerPredictive[_0x468ca8('0x1d3')](_0x468ca8('0x183'),_0xeaf77a),loggerPredictive[_0x468ca8('0x1d3')](_0x468ca8('0x1b1'),_0x4b860c),loggerPredictive[_0x468ca8('0x1d3')]('Ts:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20',_0x24a1b3),loggerPredictive[_0x468ca8('0x1d3')](_0x468ca8('0x11d'),_0x2a91ae),loggerPredictive[_0x468ca8('0x1d3')]('Amax:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20',_0x35894b),loggerPredictive['info'](_0x468ca8('0x1a4')),new Promise(function(_0x566f5d,_0x87fd1e){const _0x360dfe=_0x468ca8;if(_0xeaf77a<=0x0||isNaN(_0xeaf77a))return _0x87fd1e(msgResponse(_0x360dfe('0x1e0'),_0x360dfe('0x150'),_0x360dfe('0x96')+_0xeaf77a));if(_0x24a1b3<=0x0||isNaN(_0x24a1b3))return _0x87fd1e(msgResponse(_0x360dfe('0x1e0'),_0x360dfe('0x150'),_0x360dfe('0x1c4')+_0x24a1b3));if(_0x2a91ae<=0x0||isNaN(_0x2a91ae))return _0x87fd1e(msgResponse(_0x360dfe('0x1e0'),'Error',_0x360dfe('0x149')+_0x2a91ae));if(_0x4b860c<=0x0||isNaN(_0x4b860c))return _0x87fd1e(msgResponse('[abandonmentRate]',_0x360dfe('0x150'),_0x360dfe('0x128')+_0x4b860c));if(_0x35894b<=0x0||isNaN(_0x35894b))return _0x87fd1e(msgResponse(_0x360dfe('0x1e0'),'Error',_0x360dfe('0x24')+_0x35894b));_0x2aa245=_0x2aa245||0x0;const _0x2de2a1=0x1/_0x24a1b3;let _0x489884=0x0,_0x36fc1c=0x0,_0x39dfea=0x0,_0x447de7=0x0,_0x5e9f2a=0x0;for(_0x5e9f2a=0x0;_0x39dfea<_0x35894b;_0x5e9f2a+=0x1){_0x36fc1c=_0x5e9f2a/_0x4b860c,_0x489884=(_0x2a91ae*_0x36fc1c+_0x2aa245)/_0x2de2a1,_0x39dfea=erlangb(_0x489884,_0xeaf77a),_0x447de7=_0x489884/_0xeaf77a*(0x1-erlangb(_0x489884,_0xeaf77a));}return _0x566f5d({'erlangCalls':_0x5e9f2a,'erlangCallToSecond':_0x4b860c/_0x5e9f2a,'erlangAbandonmentRate':_0x39dfea,'erlangBusyFactor':_0x447de7});});},Dialer[_0x5be1a4('0x141')]['busyFactor']=function(_0xd968ea,_0x521054,_0x49a580,_0x619e8b,_0x2d3ea6,_0x49fa89){const _0x3c878b=_0x5be1a4;return loggerPredictive['info'](_0x3c878b('0x14a')),loggerPredictive[_0x3c878b('0x1d3')](_0x3c878b('0x183'),_0xd968ea),loggerPredictive[_0x3c878b('0x1d3')](_0x3c878b('0x1b1'),_0x521054),loggerPredictive[_0x3c878b('0x1d3')](_0x3c878b('0x107'),_0x49a580),loggerPredictive['info'](_0x3c878b('0x11d'),_0x619e8b),loggerPredictive[_0x3c878b('0x1d3')](_0x3c878b('0x20a'),_0x2d3ea6),loggerPredictive['info'](_0x3c878b('0x1a4')),new Promise(function(_0x42ae60,_0x2a4449){const _0x5c8df5=_0x3c878b;if(_0xd968ea<=0x0||isNaN(_0xd968ea))return _0x2a4449(msgResponse('[busyFactor]',_0x5c8df5('0x150'),_0x5c8df5('0x96')+_0xd968ea));if(_0x49a580<=0x0||isNaN(_0x49a580))return _0x2a4449(msgResponse(_0x5c8df5('0x16c'),_0x5c8df5('0x150'),_0x5c8df5('0x1c4')+_0x49a580));if(_0x619e8b<=0x0||isNaN(_0x619e8b))return _0x2a4449(msgResponse(_0x5c8df5('0x16c'),_0x5c8df5('0x150'),'p\x20=\x20'+_0x619e8b));if(_0x521054<=0x0||isNaN(_0x521054))return _0x2a4449(msgResponse(_0x5c8df5('0x16c'),_0x5c8df5('0x150'),_0x5c8df5('0x128')+_0x521054));if(_0x2d3ea6<=0x0||isNaN(_0x2d3ea6))return _0x2a4449(msgResponse(_0x5c8df5('0x16c'),_0x5c8df5('0x150'),_0x5c8df5('0x80')+_0x2d3ea6));_0x49fa89=_0x49fa89||0x0;const _0xd1c916=0x1/_0x49a580;let _0x471353=0x0,_0x400a59=0x0,_0x1aec28=0x0,_0x303560=0x0,_0x154d8f=0x0;for(_0x154d8f=0x0;_0x303560<_0x2d3ea6;_0x154d8f+=0x1){_0x400a59=_0x154d8f/_0x521054,_0x471353=(_0x619e8b*_0x400a59+_0x49fa89)/_0xd1c916,_0x1aec28=erlangb(_0x471353,_0xd968ea),_0x303560=_0x471353/_0xd968ea*(0x1-erlangb(_0x471353,_0xd968ea));}return _0x42ae60({'erlangCalls':_0x154d8f,'erlangCallToSecond':_0x521054/_0x154d8f,'erlangAbandonmentRate':_0x1aec28,'erlangBusyFactor':_0x303560});});},module[_0x5be1a4('0xee')]=Dialer; \ No newline at end of file +const a1057_0x448e=['YYYY-MM-DD\x20HH:mm:ss','getCaller','dialer','XMD-AMDAFTERGREETINGSILENCE','sequence','---------------------------','dialRandomLastDigitCallerIdNumber','uuid','createHistory','evt\x20is\x20undefine','calleridname','loopClearZombieChannels','[startMethodPredictive][StartProgressive]','predictiveIntervalErlangCallsDroppedCalls','predictiveIntervalAnsweredCalls','abandoned','ContactId','outboundDropCallsDayCallersExit','campaigns','getDataPredictive','outboundDropCallsDayTimeout','\x22agi://%s/square,%s\x22','Total\x20Calls:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','predictiveIntervalMultiplicativeFactor','length','Contact','SIP/%s','[syncHangupInAMD][createHistory]','[unlockOriginate][syncQueueStatusComplete]','ivr','AnswerAGI','active','getVoiceQueueRtPauses','stack','one\x20call\x20every:','[countReScheduled]\x20','seconds','tags','AVG\x20Talk\x20Time:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','[CatchErlangB]','\x20NOT\x20Active','[syncAgentComplete][createHistory]','XMD-','Machine','GLOBAL_INTERVAL_IS_OVERTIME','RUNNING','ListId','[getVoiceQueueRtPauses]\x20','XMD-AMDMAXIMUMWORDLENGTH','../../../config/environment/','fail\x20to\x20scheduled\x20calls','stateinterface','Drop','channel','loggedIn','Agent:\x20','Predictive\x20after\x20first\x20interval','checkIfTimeIntervals','available','[rescheduleContact]\x20','checkDialMethod','pow','launchHandleIvr','amdstatus','custom:agentnoanswer','[syncAgentComplete][createHistory][10]','XMD-AMDBETWEENWORDSSILENCE','switch\x20in\x20progressive\x20because\x20available\x20agents\x20(','abandonmentRate','\x20Timezone\x20unknow\x20','object','[unlockContact]\x20','predictiveIntervalPauses','[originate][error]','./action','emit','is\x20disactive','[actionOriginateIvr]\x20','dialMachineRetryFrequency','Total\x20Calls\x20are\x20not\x20enough\x20for\x20predictive','responsetime','rrmemory','syncQueueStatusComplete','content','error','talking','finally','originate','UserId','startMethodPredictive','countglobal','started\x20in\x20predictive\x20at','varset','predictiveIntervalErlangCalls','interval','message','pTalking','hangup','reason\x2011\x20abandoned','then','clearing\x20variable\x20handle\x20predictive','bind','uniqueid','erlangBusyFactor','countabandonedretry','contacts','dialBusyMaxRetry','Umin\x20=\x20','unlockContact','dialOrderByScheduledAt','createdAt','entity\x20is\x20undefine','[syncQueueSummary]','response','startPredictive','predictiveCalls','isUndefined','erlangCalls','dialDropRetryFrequency','[getDataPredictive]','ifTime','[booked][unlock]','----\x20Agent\x20Busy\x20Factor\x20----','[averageHandleTime]\x20','checkIsTrunkReachable','checkContactBlack','outboundQueuePauses',')\x20are\x20less\x20than\x20threshold\x20(','phone','Interval','voiceQueue\x20is\x20undefine','dialQueueTimeout','XMD-AMDMINWORDLENGTH','[booked][checkContactBlack][else]','Error','dialGlobalInterval','agiafterat','outboundNoAnswerCallsDay','dialPrefix','reason\x203\x20ringing\x20no\x20answer','random','agent','outboundAnswerCallsDay','contact\x20not\x20moved','outboundDropCallsDayACS','waiting','agiIp','outboundOriginateFailureCallsDay','outboundCongestionCallsDay','syncCampaigns','emptyContact','syncAgentComplete','predictiveIntervalTotalCalls','predictiveIntervalAvgHoldtime','Amax:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','[syncAgentComplete][createHistory][20]','-----\x20Stats\x20Predictive\x20---','countbusyretry','dialOriginateCallerIdNumber','roundrobin','dialOriginateTimeout','[uniqueid]','outbound','INTERVAL_IS_EMPTY','Predictive\x20for\x20every\x20interval','[syncHangupInAMDIvr][createHistory]','progressive','trunks','prototype','outboundNoSuchCallsDay','checkIfTime','countnosuchnumberretry','erlangAbandonmentRate','originated','rescheduleContact','agentBusyFactor','XMD-CAMPAIGNID','format','dialAMDMaximumWordLength','[syncHangupIvr][createHistory]','[createHistory]\x20','minutes','HANGUP','cause-txt','../rpc/cmHopper','voicePause','P:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','checkRetriveMax','TrunkBackup','Success','all','XMD-AMDTOTALANALYSISTIME','History\x20information\x20are\x20empty','agentconnect','XMD-AMDGREETING','dialNoSuchNumberMaxRetry','dialNoAnswerMaxRetry','dialAgiAfterHangupAgent','dialAbandonedRetryFrequency','[rescheduleContact][AgentReject]','./history','actionOriginate','Avg\x20Hold\x20Time\x20is\x20not\x20enough\x20for\x20predictive','countmachineretry','add','queue','lodash','dialNoSuchNumberRetryFrequency','[unlockQueueStatus][undefined]','handleIvr','reason\x200\x20no\x20such\x20number....','Queue:\x20','Action','Busy','replace','syncHangup','\x22%s\x22\x20<%s>','loggerHandler','../rpc/cmHopperHistory','createStateFinal','membername','clearing\x20variable\x20start\x20progressive','limitCalls','\x22%s,%s%s,,,%s\x22','AgentReject','[callProgressDetecting]\x20','timezones','voiceQueues','callProgressDetecting','dialCongestionRetryFrequency','isTrunkReachable','[booked][unlock2]','busyFactor','endtime','[syncHangupInAMD]','[syncAgentComplete][createHistory][?]','log','---------\x20ErlangB\x20---------','statedesc','Agent\x20Busy\x20Factor:\x20\x20\x20\x20\x20\x20\x20\x20\x20','tail','queueBookedRR','[originateError]:\x20%s','HangupInAMD','dialPredictiveOptimizationPercentage','syncQueueSummary','reason','[moveContactManagedDialer][0]','dialAMDTotalAnalysisTime','substring','VoiceQueueId','predictiveIntervalMinThreshold','starttime','[syncQueueCallerAbandon]\x20[Drop]','[decremetOriginate]\x20is\x20null\x20or\x20undefined','[unlock2][syncQueueStatusComplete]','XMD-AMDSILENCETHRESHOLD','Answered\x20Calls:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','NOT_ACTIVE','dialActive','Drop\x20Rate:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','RecallInQueue','[syncQueueSummary]\x20Campaign\x20Queue:\x20','command','./final','queueStatusComplete','moveContactManagedDialer','countnoanswerretry','dialDropMaxRetry','BLACKLIST','state','[busyFactor]','isNil','custom:queuesummary','countReScheduled','[syncHangupIvr]','some','Global','sumBillable','total','dialAMDAfterGreetingSilence','[unlock][syncQueueStatusComplete]','\x20INTERVAL_IS_NULL','predictiveIntervalHitRate','countdropretry','NoSuchNumber','\x20trunk\x20is\x20not\x20reachable','p\x20=\x20','syncAgentConnect','run','optionPredictive','[getContactCampaign2]','[actionOriginatePredictive]\x20','averageHandleTime','match','milliseconds','dialLimitQueue','iftime\x20%s,%s','name','[getContactDialer]\x20','dialAMDSilenceThreshold','dialAMDGreeting','dialPredictiveOptimization','dialQueueProject','dialAbandonedMaxRetry','maxNumberOriginate','outboundBlacklistCallsDay','Ts:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','dialMethod','dialCutDigit','resolve','reason\x205\x20busy','countagentrejectretry','sendMessageOneNotActive','[startMethodPredictive][StartProgressive][Loop]','Drop\x20in\x20this\x20interval','undefined','XMD-ORIGINATECALLERIDNUM','\x20Intervals\x20is\x20null\x20','not_inuse','countcongestionretry','[syncAgentComplete][createHistory][11]','agentreject','AGI','clearZombieChannels','contactsRescheduled','recalculate\x20predictive\x20at','exports','getContactDialer','preview','checkIsBlackList','predictiveIntervalAvgTalktime','outboundBusyCallsDay',')\x20are\x20more\x20than\x20threshold\x20(','voice:queue:%s','nosuchnumber','actions','No\x20such\x20channel','../../../config/logger','handlePredictive','info','originatecalleridname','dialAMDActive','channels','syncQueueMember','AMD','predictiveIntervalDroppedCallsCallersExit','outboundAbandonedCallsDay','[checkIsBlackList]\x20','dialOriginateCallerIdName','true','Interval:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','AVAILABLE_CONTACTS_FINISHED','getQueue','outboundAnswerAgiCallsDay','Abandoned','check\x20handlePredictive\x20is\x20not\x20undefine','CALLEREXIT','queueBooked','predictiveIntervalDroppedCallsTimeout','originate\x20action\x20Error','[getContactDialer2][ReScheduled]','dialBusyRetryFrequency','[Originate][HistoryRecallClose]','inBlackList','syncOriginateResponse','unlockRR','stateGlobal','uniqueId','[Catch][Preview][syncQueueStatusComplete]','CampaignId','type','avgHandleTime','string','agents','[Originate][MoveBlacklist]','XMD-AMDINITIALSILENCE','stringify','Unknown\x20Predictive','trim','[rescheduleContact][Abandoned]','NONE','exten','dialQueueProject2','[booked][unlock3]','syncVarSet','noanswer','sumHoldTime','m\x20=\x20','RecallFailedTimeout','INTERVAL_IS_NULL','round','inspect','check\x20failure','Blacklist','Failure','AGENTS_NOT_LOGGED','is\x20not\x20active','custom:agentreject','[booked][unlockQueueStatus]','handlePower','[getContactCampaign2][Empty]','TIMEZONE_UNKNOW','enqueue','One\x20call\x20every:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','[Dialer][checkChannel]','calleridnum','xcally-motion-dialer','queueCallerAbandonCreateState','outboundUnknownCallsDay','Max\x20Drop\x20','Umin:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','util','Dropped\x20calls\x20day','[getContactDialer2]','startProgressive','\x20AGENTS\x20NOT\x20LOGGED','value','amd','locked','reachable','toUpper','buildObj','merge','ivrAnswerCallsDay','[Originate][HistoryDialRecallInQueue][historyCatch]','checkIsBlackListIvr','[emptyContact]','[actionOriginate]\x20','[unlock3][syncQueueStatusComplete]','dialGlobalMaxRetry','../rpc/cmHopperBlack','Contact.phone','[rescheduleContact][NoAnswer]','newexten','booked','_rr','[updateOriginated]\x20is\x20null\x20or\x20undefined','unmanaged','dialTimezone','[actions]','paused','getDataPredictiveOld','%s%s','[abandonmentRate]','outboundRejectCallsDay','../ami','dialMachineMaxRetry','indexOf','getContactDialerIvr','reason\x208\x20congestion','syncNewExten','loopCampaigns','[getContactDialerPredictive]','[updateOriginated]\x20object\x20originated\x20is\x20negative','predictiveIntervalAvailable','XMD-AMDMAXIMUMNUMBEROFWORDS','unmonitored','sumDuration','TIMEOUT','busy','droptime','predictive','[rescheduleContact][NoSuchNumber]','isSuccess','syncQueueCallerAbandon','[handlePredictive][limitChannel]','[syncQueueSummary]\x20Campaign\x20Ivr:\x20','Ts\x20=\x20','recallme','pick','SIP/%s/%s%s','XMD-ORIGINATECALLERIDNAME','[decremetOriginate]\x20object\x20originated\x20is\x20negative','reason19\x20machine....','[rescheduleContact][Machine]','push','congestion','MACHINE','Agent','tryOriginatePredictive','[Originate][historyBlacklist]','temp','[syncAgentComplete]','idHopper','interval\x20=\x20','custom:agentbusy','strategy','dialCongestionMaxRetry','dialPredictiveInterval','dialAMDMinWordLength','Avg\x20Talk\x20Time\x20is\x20not\x20enough\x20for\x20predictive','callerid','answertime','dialRecallInQueue','[handlePredictive]','[stopMethodPredictive][ReStartProgressive][ExceededDropInterval]','erlangCallToSecond','variable','updateOriginated','[callProgressDetecting]','saveInDb','actionid','contact\x20is\x20undefine','[booked][RR][finaly]','[syncAgentComplete][createHistory][0]','TRUNK_IS_NOT_REACHABLE','../../../config/config.service','catch','[ifTime][promiseAll]','Trunk','originateresponse','updatedAt','diff','[getContactDialer2][Empty]','dropRate','floor','dropreason','M:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','IS_DISACTIVED','status','Intervals','Dropped\x20Exit:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','ACTIVE','isEmpty','OriginateError','[booked][RR]','predictiveIntervalMaxThreshold','custom:agentcongestion'];(function(_0x283fa0,_0x448e9f){const _0x23ff5b=function(_0x936aae){while(--_0x936aae){_0x283fa0['push'](_0x283fa0['shift']());}};_0x23ff5b(++_0x448e9f);}(a1057_0x448e,0xe4));const a1057_0x23ff=function(_0x283fa0,_0x448e9f){_0x283fa0=_0x283fa0-0x0;let _0x23ff5b=a1057_0x448e[_0x283fa0];return _0x23ff5b;};const _0x369fc5=a1057_0x23ff;'use strict';const util=require(_0x369fc5('0xb8')),_=require(_0x369fc5('0x1fb')),uuid=require(_0x369fc5('0x134')),moment=require('moment'),rr=require('rr'),md5=require('md5'),ut=require('../preview/util/util'),config=require(_0x369fc5('0x15e')),logger=require(_0x369fc5('0x6e'))('dialer'),loggerBooked=require('../../../config/logger')('booked'),loggerPredictive=require(_0x369fc5('0x6e'))('predictive'),loggerPredictiveCalls=require(_0x369fc5('0x6e'))(_0x369fc5('0x1a0')),loggerSyncQueueSummary=require(_0x369fc5('0x6e'))(_0x369fc5('0x11')),ami=require(_0x369fc5('0xda')),{getSocket}=require('../../../rediscache'),io=getSocket(),cmHopper=require(_0x369fc5('0x1e5')),cmHopperHistory=require(_0x369fc5('0x207')),cmHopperBlack=require(_0x369fc5('0xcb')),voiceQueueRt=require('../rpc/voiceQueueRt'),Action=require(_0x369fc5('0x177')),History=require(_0x369fc5('0x1f5')),Final=require(_0x369fc5('0x24')),AgentComplete=require('./agentComplete'),QueueCallerAbandon=require('./queueCallerAbandon'),Hangup=require('./hangup'),{getConfigService}=require(_0x369fc5('0x117')),strategy={'rrmemory':_0x369fc5('0x17e'),'roundrobin':_0x369fc5('0x1cc')},Sequence=function(){};Sequence[_0x369fc5('0x1d5')][_0x369fc5('0xaf')]=function(_0x936aae){const _0x3dc042=_0x369fc5;this[_0x3dc042('0xc')]=this['tail']?this['tail'][_0x3dc042('0x183')](_0x936aae):_0x936aae();};function Dialer(_0x12de1c,_0x332386){const _0x212553=_0x369fc5;this[_0x212553('0x131')]=new Sequence(),this[_0x212553('0x65')]=_0x332386,this[_0x212553('0x210')]=_0x12de1c[_0x212553('0x210')],this[_0x212553('0x13f')]=_0x12de1c['campaigns'],this[_0x212553('0x92')]=_0x12de1c['agents'],this[_0x212553('0x1d4')]=_0x12de1c['trunks'],this[_0x212553('0x4d')]=config[_0x212553('0x4d')]||0x2,this[_0x212553('0x73')]={},this['actions']={},this['contactsId']={},this['uniqueId']={},this[_0x212553('0x3e')]={},this['startPredictive']={},this[_0x212553('0xbb')]={},this['ivrOriginated']={},this[_0x212553('0x82')]={},this['queueBookedRR']={},ami['on'](_0x212553('0x1ee'),this[_0x212553('0x3c')][_0x212553('0x192')](this)),ami['on']('queuecallerabandon',this['syncQueueCallerAbandon'][_0x212553('0x192')](this)),ami['on'](_0x212553('0x11b'),this[_0x212553('0x89')]['bind'](this)),ami['on']('agentcomplete',this[_0x212553('0x1c4')][_0x212553('0x192')](this)),ami['on'](_0x212553('0x2d'),this[_0x212553('0x11')]['bind'](this)),ami['on'](_0x212553('0x18e'),this[_0x212553('0x204')][_0x212553('0x192')](this)),ami['on'](_0x212553('0xce'),this[_0x212553('0xdf')][_0x212553('0x192')](this)),ami['on'](_0x212553('0x189'),this['syncVarSet'][_0x212553('0x192')](this)),ami['on']('queuemember',this[_0x212553('0x74')][_0x212553('0x192')](this)),ami['on']('queuestatuscomplete',this[_0x212553('0x17f')][_0x212553('0x192')](this)),this[_0x212553('0xe0')](),this[_0x212553('0x138')]();}function isNotNull(_0x1904af){const _0x3ddd86=_0x369fc5;return _0x1904af!==null&&!_[_0x3ddd86('0x1a1')](_0x1904af);}function checkIsLoggedIn(_0x150909,_0x26e60a){return function(){const _0x5a816e=a1057_0x23ff;if(_0x26e60a<=0x0){_0x150909[_0x5a816e('0x18c')]=_0x5a816e('0xa8');throw _0x150909[_0x5a816e('0x46')]+_0x5a816e('0xbc');}};}function isActive(_0x4fa9ea){return _0x4fa9ea;}function checkIsActive(_0x19da96,_0x2c4bc2){return function(){const _0x3e1a0c=a1057_0x23ff;if(!isActive(_0x2c4bc2)){_0x19da96[_0x3e1a0c('0x18c')]='NOT_ACTIVE';throw _0x19da96[_0x3e1a0c('0x46')]+_0x3e1a0c('0x155');}};}function checkInterval(_0x4f6264){return function(){const _0xcf0817=a1057_0x23ff;if(!isNotNull(_0x4f6264[_0xcf0817('0x1ae')])){_0x4f6264[_0xcf0817('0x18c')]=_0xcf0817('0xa2');throw _0x4f6264[_0xcf0817('0x46')]+_0xcf0817('0x36');}if(!isNotNull(_0x4f6264[_0xcf0817('0x1ae')][_0xcf0817('0x125')])){_0x4f6264[_0xcf0817('0x18c')]=_0xcf0817('0xa2');throw _0x4f6264[_0xcf0817('0x46')]+_0xcf0817('0x36');}if(!isNotNull(_[_0xcf0817('0x128')](_0x4f6264['Interval'][_0xcf0817('0x125')]))){_0x4f6264[_0xcf0817('0x18c')]='INTERVAL_IS_NULL';throw _0x4f6264[_0xcf0817('0x46')]+'\x20INTERVAL_IS_NULL';}};}function msgResponse(_0x56d701,_0x24802a,_0x261590){return{'action':_0x56d701,'response':_0x24802a,'message':_0x261590,'stack':_0x261590};}function myreject(_0x50deb0){return function(_0xb9e15f){return _0x50deb0(msgResponse('[ifTime][Action]','Error',JSON['stringify'](_0xb9e15f)));};}function getSeconds(_0x2adf10,_0x42b6b3){const _0x2cadc6=_0x369fc5,_0x55b0b2=moment(_0x2adf10)[_0x2cadc6('0x43')](0x0),_0x16082b=moment(_0x42b6b3)['milliseconds'](0x0);return _0x55b0b2[_0x2cadc6('0x11d')](_0x16082b,_0x2cadc6('0x151'));}function emit(_0x26e20e,_0x409e9c,_0x2f05c2){const _0x47ca6f=_0x369fc5;io['to'](_0x26e20e)[_0x47ca6f('0x178')](_0x409e9c,_0x2f05c2);}function emitVoiceQueueSummary(_0x2e8d9f){const _0x23b3b7=_0x369fc5;if(_0x2e8d9f[_0x23b3b7('0x8f')]==='outbound'){const _0x406c3a={'id':_0x2e8d9f['id'],'name':_0x2e8d9f[_0x23b3b7('0x46')],'strategy':_0x2e8d9f[_0x23b3b7('0x103')],'answered':_0x2e8d9f['answered'],'available':_0x2e8d9f[_0x23b3b7('0x167')],'loggedIn':_0x2e8d9f[_0x23b3b7('0x163')],'pTalking':_0x2e8d9f[_0x23b3b7('0x18d')],'sumBillable':_0x2e8d9f[_0x23b3b7('0x32')],'sumDuration':_0x2e8d9f[_0x23b3b7('0xe6')],'sumHoldTime':_0x2e8d9f[_0x23b3b7('0x9f')]||0x0,'talking':_0x2e8d9f[_0x23b3b7('0x182')],'total':_0x2e8d9f[_0x23b3b7('0x33')],'type':_0x2e8d9f[_0x23b3b7('0x8f')],'unmanaged':_0x2e8d9f[_0x23b3b7('0xd2')],'abandoned':_0x2e8d9f[_0x23b3b7('0x13c')],'waiting':_0x2e8d9f[_0x23b3b7('0x1be')],'loggedInDb':_0x2e8d9f['loggedInDb'],'dialActive':_0x2e8d9f[_0x23b3b7('0x1f')],'dialMethod':_0x2e8d9f[_0x23b3b7('0x50')],'dialOriginateCallerIdName':_0x2e8d9f[_0x23b3b7('0x79')],'dialOriginateCallerIdNumber':_0x2e8d9f[_0x23b3b7('0x1cb')],'dialOriginateTimeout':_0x2e8d9f[_0x23b3b7('0x1cd')],'dialPrefix':_0x2e8d9f[_0x23b3b7('0x1b7')],'outboundAnswerAgiCallsDay':_0x2e8d9f[_0x23b3b7('0x7e')],'outboundAnswerCallsDay':_0x2e8d9f[_0x23b3b7('0x1bb')],'outboundBlacklistCallsDay':_0x2e8d9f[_0x23b3b7('0x4e')],'outboundBusyCallsDay':_0x2e8d9f['outboundBusyCallsDay'],'outboundCongestionCallsDay':_0x2e8d9f[_0x23b3b7('0x1c1')],'outboundDropCallsDayACS':_0x2e8d9f[_0x23b3b7('0x1bd')],'outboundDropCallsDayCallersExit':_0x2e8d9f['outboundDropCallsDayCallersExit'],'outboundDropCallsDayTimeout':_0x2e8d9f[_0x23b3b7('0x141')],'outboundNoAnswerCallsDay':_0x2e8d9f[_0x23b3b7('0x1b6')],'outboundNoSuchCallsDay':_0x2e8d9f[_0x23b3b7('0x1d6')],'outboundOriginateFailureCallsDay':_0x2e8d9f[_0x23b3b7('0x1c0')],'outboundReCallsDay':_0x2e8d9f['outboundReCallsDay'],'outboundRejectCallsDay':_0x2e8d9f[_0x23b3b7('0xd9')],'outboundUnknownCallsDay':_0x2e8d9f['outboundUnknownCallsDay'],'predictiveIntervalAnsweredCalls':_0x2e8d9f['predictiveIntervalAnsweredCalls'],'predictiveIntervalAvgHoldtime':_0x2e8d9f[_0x23b3b7('0x1c6')],'predictiveIntervalAvgTalktime':_0x2e8d9f['predictiveIntervalAvgTalktime'],'predictiveIntervalDroppedCallsCallersExit':_0x2e8d9f[_0x23b3b7('0x76')],'predictiveIntervalDroppedCallsTimeout':_0x2e8d9f[_0x23b3b7('0x83')],'predictiveIntervalErlangCalls':_0x2e8d9f[_0x23b3b7('0x18a')],'predictiveIntervalErlangCallsDroppedCalls':_0x2e8d9f['predictiveIntervalErlangCallsDroppedCalls'],'predictiveIntervalHitRate':_0x2e8d9f['predictiveIntervalHitRate'],'predictiveIntervalMultiplicativeFactor':_0x2e8d9f[_0x23b3b7('0x144')],'predictiveIntervalPauses':_0x2e8d9f['predictiveIntervalPauses'],'predictiveIntervalAvailable':_0x2e8d9f[_0x23b3b7('0xe3')],'predictiveIntervalTotalCalls':_0x2e8d9f[_0x23b3b7('0x1c5')],'message':_0x2e8d9f[_0x23b3b7('0x18c')],'originated':_0x2e8d9f['originated'],'erlangCalls':_0x2e8d9f[_0x23b3b7('0x1a2')],'erlangCallToSecond':_0x2e8d9f['erlangCallToSecond'],'erlangAbandonmentRate':_0x2e8d9f[_0x23b3b7('0x1d9')],'erlangBusyFactor':_0x2e8d9f[_0x23b3b7('0x194')],'startPredictive':_0x2e8d9f['startPredictive'],'startProgressive':_0x2e8d9f['startProgressive']};_0x2e8d9f[_0x23b3b7('0x11a')]&&(_0x406c3a[_0x23b3b7('0x11a')]={'id':_0x2e8d9f['Trunk']['id'],'name':_0x2e8d9f[_0x23b3b7('0x11a')]['name'],'active':_0x2e8d9f[_0x23b3b7('0x11a')][_0x23b3b7('0x14c')],'callerid':_0x2e8d9f[_0x23b3b7('0x11a')][_0x23b3b7('0x108')]});_0x2e8d9f[_0x23b3b7('0x1ae')]&&(_0x406c3a[_0x23b3b7('0x1ae')]={'id':_0x2e8d9f[_0x23b3b7('0x1ae')]['id'],'name':_0x2e8d9f[_0x23b3b7('0x1ae')]['name']});const _0x4e9909=md5(JSON['stringify'](_0x406c3a));_0x2e8d9f['md5']!==_0x4e9909&&(_0x2e8d9f['md5']=_0x4e9909,emit(util['format'](_0x23b3b7('0x6a'),_0x406c3a[_0x23b3b7('0x46')]),'voice_queue:save',_0x406c3a));}}function emitCampaignSummary(_0x200d1c){const _0x15841f=_0x369fc5;_0x200d1c[_0x15841f('0x8f')]===_0x15841f('0x14a')&&emit(util[_0x15841f('0x1de')]('campaign:ivr:%s',_0x200d1c[_0x15841f('0x46')]),'campaign:save',_0x200d1c);}function checkGetDataPredictive(_0x125722){const _0x3f8059=_0x369fc5;if(isNotNull(_0x125722)){if(!_[_0x3f8059('0x128')](_0x125722)){loggerPredictive[_0x3f8059('0x70')](_0x3f8059('0x1c9')),loggerPredictive[_0x3f8059('0x70')](_0x3f8059('0x143'),_0x125722[_0x3f8059('0x1c5')]),loggerPredictive['info'](_0x3f8059('0x1d'),_0x125722[_0x3f8059('0x13b')]),loggerPredictive[_0x3f8059('0x70')]('Dropped\x20Timeout:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20',_0x125722[_0x3f8059('0x83')]),loggerPredictive[_0x3f8059('0x70')](_0x3f8059('0x126'),_0x125722[_0x3f8059('0x76')]),loggerPredictive['info']('AVG\x20Hold\x20Time:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20',_0x125722[_0x3f8059('0x1c6')]),loggerPredictive[_0x3f8059('0x70')](_0x3f8059('0x153'),_0x125722['predictiveIntervalAvgTalktime']),loggerPredictive[_0x3f8059('0x70')]('---------------------------');if(_0x125722[_0x3f8059('0x1c5')]>0x0){if(!_['isUndefined'](_0x125722[_0x3f8059('0x67')])&&_0x125722['predictiveIntervalAvgTalktime']>0x0)return!![];else loggerPredictive[_0x3f8059('0x70')](_0x3f8059('0x107'));if(!_['isUndefined'](_0x125722[_0x3f8059('0x1c6')])&&_0x125722[_0x3f8059('0x1c6')]>0x0)return!![];else loggerPredictive[_0x3f8059('0x70')](_0x3f8059('0x1f7'));}else loggerPredictive[_0x3f8059('0x70')](_0x3f8059('0x17c'));}else loggerPredictive[_0x3f8059('0x70')](_0x3f8059('0x1ed'));}else loggerPredictive[_0x3f8059('0x70')](_0x3f8059('0x1ed'));return![];}function mergeDataErlangB(_0x58e04a){return function(_0x264d78){const _0x447f6c=a1057_0x23ff;loggerPredictive['info'](_0x447f6c('0x9')),loggerPredictive[_0x447f6c('0x70')]('Scheduled\x20Calls:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20',_0x264d78[_0x447f6c('0x1a2')]),loggerPredictive['info'](_0x447f6c('0xb0'),_0x264d78[_0x447f6c('0x10d')]),loggerPredictive[_0x447f6c('0x70')](_0x447f6c('0x20'),_0x264d78['erlangAbandonmentRate']),loggerPredictive[_0x447f6c('0x70')](_0x447f6c('0xb'),_0x264d78[_0x447f6c('0x194')]),loggerPredictive['info'](_0x447f6c('0x20'),_0x264d78['erlangAbandonmentRate']),loggerPredictive['info'](_0x447f6c('0x132')),_[_0x447f6c('0xc3')](_0x58e04a,_0x264d78);};}function getDiff(_0x1dc750){const _0x39c302=_0x369fc5,_0x230873=moment()[_0x39c302('0x43')](0x0),_0x3ced03=moment(_0x1dc750)['milliseconds'](0x0);return _0x230873['diff'](_0x3ced03,_0x39c302('0x151'));}function ifInterval(_0xa5972e,_0x46b18e){const _0x57cec8=_0x369fc5;if(_[_0x57cec8('0x1a1')](_0x46b18e))return![];return getDiff(_0x46b18e)<_0xa5972e*0x3c?!![]:![];}function freeVariablesPredictive(_0x295a30){const _0xfa6c7a=_0x369fc5;isNotNull(_0x295a30)&&(!_['isUndefined'](_0x295a30[_0xfa6c7a('0xbb')])&&(_0x295a30[_0xfa6c7a('0xbb')]=undefined,loggerPredictive[_0xfa6c7a('0x70')](_0x295a30[_0xfa6c7a('0x46')],_0xfa6c7a('0x20a'))),!_[_0xfa6c7a('0x1a1')](_0x295a30[_0xfa6c7a('0x19f')])&&(_0x295a30[_0xfa6c7a('0x19f')]=undefined,loggerPredictive[_0xfa6c7a('0x70')](_0x295a30[_0xfa6c7a('0x46')],'clearing\x20variable\x20start\x20predictive')),!_[_0xfa6c7a('0x1a1')](_0x295a30[_0xfa6c7a('0x6f')])&&(clearInterval(_0x295a30[_0xfa6c7a('0x6f')]),_0x295a30[_0xfa6c7a('0x6f')]=undefined,loggerPredictive[_0xfa6c7a('0x70')](_0x295a30[_0xfa6c7a('0x46')],_0xfa6c7a('0x191'))));}function erlangb(_0x3aad60,_0x52d0ed){if(_0x52d0ed===0x0)return 0x0;let _0x32ae16=0x1;for(let _0x2d5867=0x1;_0x2d5867<=_0x52d0ed;_0x2d5867+=0x1){_0x32ae16=0x1+_0x32ae16*_0x2d5867/_0x3aad60;}return 0x1/_0x32ae16;}function isVoiceQueueOutbound(_0x3effe8){const _0x30aae4=_0x369fc5;return _0x3effe8===_0x30aae4('0x1cf');}function isNotPreview(_0x5c53e9){const _0x5b16bf=_0x369fc5;return _0x5c53e9!==_0x5b16bf('0x65');}function isCampaignIvr(_0x10606e){return _0x10606e==='ivr';}function getCallerId(_0x54853f,_0x214af5,_0x3c8141){const _0x587a1f=_0x369fc5;if(!_[_0x587a1f('0x1a1')](_0x3c8141)&&_0x587a1f('0x91')===typeof _0x3c8141&&!_[_0x587a1f('0x128')](_0x3c8141)){if(!_[_0x587a1f('0x1a1')](_0x214af5)&&_0x587a1f('0x91')===typeof _0x214af5&&!_[_0x587a1f('0x128')](_0x214af5))return util['format']('\x22%s\x22\x20<%s>',_0x214af5,_0x3c8141);return util[_0x587a1f('0x1de')](_0x587a1f('0x205'),_0x3c8141,_0x3c8141);}if(!_[_0x587a1f('0x1a1')](_0x54853f)&&_0x587a1f('0x91')===typeof _0x54853f&&!_['isEmpty'](_0x54853f))return _0x54853f;return'\x22\x22\x20<>';}function loggerCatchQueueSummary(_0x589dd2,_0x4abdf1){return function(_0x46c1cc){const _0x58f6cc=a1057_0x23ff;freeVariablesPredictive(_0x4abdf1),emitVoiceQueueSummary(_0x4abdf1),emitCampaignSummary(_0x4abdf1),loggerSyncQueueSummary[_0x58f6cc('0x181')](_0x589dd2,util[_0x58f6cc('0xa4')](_0x46c1cc,{'showHidden':![],'depth':null}));};}function loggerCatchPredictive(_0x3b699e,_0x673d9a){return function(_0xe35fa8){const _0x7ece71=a1057_0x23ff;loggerPredictive['error'](_0x673d9a[_0x7ece71('0x46')],_0x3b699e),loggerPredictive['error'](_0xe35fa8[_0x7ece71('0x14e')]),freeVariablesPredictive(_0x673d9a);};}function loggerCatch(_0x11df7c){return function(_0x25506d){const _0x57983f=a1057_0x23ff;logger['error'](_0x11df7c,util[_0x57983f('0xa4')](_0x25506d,{'showHidden':![],'depth':null}));};}function checkContactEmpty(_0x325ed3){const _0x35ed67=_0x369fc5;return _0x325ed3&&!_[_0x35ed67('0x1a1')](_0x325ed3)&&_0x325ed3['length']>0x0;}function decremetOriginate(_0x2b6294){const _0x217949=_0x369fc5;!_[_0x217949('0x1a1')](_0x2b6294)&&_0x2b6294!==null?typeof _0x2b6294[_0x217949('0x1da')]!==_0x217949('0x58')&&(_0x2b6294[_0x217949('0x1da')]>0x0?_0x2b6294[_0x217949('0x1da')]-=0x1:logger['error'](_0x217949('0xf5'))):logger[_0x217949('0x181')](_0x217949('0x1a'));}function checkContactLowerLimitOriginate(_0x46c595,_0x4eb4b4,_0x12dd6d){if(_0x4eb4b4>_0x12dd6d)for(let _0x2f500f=0x0;_0x2f500f<_0x4eb4b4-_0x12dd6d;_0x2f500f+=0x1){decremetOriginate(_0x46c595);}}function loggerGetContactDialer(_0x34b7bf,_0x14c58c,_0x460045){return function(_0x395c40){const _0x2a13f5=a1057_0x23ff;checkContactLowerLimitOriginate(_0x14c58c,_0x460045,0x0),logger['error'](_0x34b7bf,util[_0x2a13f5('0xa4')](_0x395c40,{'showHidden':![],'depth':null}));};}function sendMessageReschedule(_0x383e5d){return function(_0xd934df){const _0x5df282=a1057_0x23ff;isNotNull(_0xd934df)&&isNotNull(_0xd934df[0x0])&&(_0xd934df[0x0]['contactsRescheduled']>0x0?(_0x383e5d['message']='RESCHEDULED_CONTACTS',logger[_0x5df282('0x70')](_0x5df282('0x85')+_0x383e5d[_0x5df282('0x46')],_0xd934df[0x0][_0x5df282('0x61')],_0x5df282('0x196'))):(_0x383e5d[_0x5df282('0x18c')]=_0x5df282('0x7c'),logger['info'](_0x5df282('0x11e')+_0x383e5d[_0x5df282('0x46')])));};}function notSendMessagesQueue(_0x2021eb){const _0x234499=_0x369fc5;_0x2021eb['sendMessageOneNotActive']&&(freeVariablesPredictive(_0x2021eb),_0x2021eb[_0x234499('0x1da')]===0x0&&_0x2021eb[_0x234499('0x182')]===0x0&&_0x2021eb[_0x234499('0x1be')]===0x0&&(_0x2021eb[_0x234499('0x18d')]||0x0)===0x0?(_0x2021eb['sendMessageOneNotActive']=![],_0x2021eb['available']=0x0,_0x2021eb['message']='NOT_ACTIVE',loggerSyncQueueSummary['error'](_0x234499('0x22'),_0x2021eb['name'],_0x234499('0xa9'))):(_0x2021eb[_0x234499('0x18c')]='IS_DISACTIVED',loggerSyncQueueSummary[_0x234499('0x181')](_0x234499('0x22'),_0x2021eb[_0x234499('0x46')],_0x234499('0x179'))),emitVoiceQueueSummary(_0x2021eb));}function notSendMessagesCampaign(_0x219b77){const _0x27d189=_0x369fc5;_0x219b77[_0x27d189('0x55')]&&(_0x219b77[_0x27d189('0x1da')]===0x0?(_0x219b77[_0x27d189('0x55')]=![],_0x219b77['message']=_0x27d189('0x1e'),loggerSyncQueueSummary[_0x27d189('0x181')]('[syncQueueSummary]\x20Campaign\x20Ivr:\x20',_0x219b77[_0x27d189('0x46')],_0x27d189('0xa9'))):(_0x219b77[_0x27d189('0x18c')]=_0x27d189('0x123'),loggerSyncQueueSummary[_0x27d189('0x181')](_0x27d189('0xef'),_0x219b77['name'],'is\x20disactive')),emitCampaignSummary(_0x219b77));}function createObjHistory(_0x5c9c19,_0x29f4ed,_0x4e1828,_0x9b5cba,_0x5b8984){const _0x42d119=_0x369fc5;_0x5c9c19['message']=_0x4e1828;const _0x58b69f=new Action(_0x5c9c19,_0x29f4ed),_0x3e21b7=new History(_0x58b69f);return _0x3e21b7[_0x42d119('0x2a')]=_0x9b5cba,_0x3e21b7[_0x42d119('0xa')]=_0x5b8984,_0x3e21b7[_0x42d119('0x5')]=_0x58b69f[_0x42d119('0x18')],_0x3e21b7;}Dialer['prototype'][_0x369fc5('0x138')]=function(){const _0x4ce424=this;setInterval(function(){const _0x37970a=a1057_0x23ff;_0x4ce424[_0x37970a('0x60')](_0x4ce424[_0x37970a('0x8c')],_0x37970a('0x1ce')),_0x4ce424['clearZombieChannels'](_0x4ce424['actions'],_0x37970a('0xd4'));},0x32c8);},Dialer[_0x369fc5('0x1d5')]['clearZombieChannels']=function(_0x782a23,_0x30a9ac){const _0x2d390e=_0x369fc5,_0x2188da=this;for(const _0x360df4 in _0x782a23){typeof _0x782a23[_0x360df4]!==_0x2d390e('0x58')&&this[_0x2d390e('0x131')][_0x2d390e('0xaf')](function(){const _0xff0418=_0x2d390e;if(!_[_0xff0418('0x2c')](_0x782a23[_0x360df4]))return ami['Action']({'action':_0xff0418('0x124'),'channel':_0x782a23[_0x360df4][_0xff0418('0x162')]})[_0xff0418('0x118')](function(_0x35dbcd){const _0x595323=_0xff0418;_0x35dbcd[_0x595323('0x18c')]===_0x595323('0x6d')&&setTimeout(function(){const _0x42e070=_0x595323;_0x782a23[_0x360df4]&&_0x782a23[_0x360df4][_0x42e070('0x8f')]!==_0x42e070('0x14a')&&(_0x2188da[_0x42e070('0x10f')](_0x2188da[_0x42e070('0x210')][_0x782a23[_0x360df4][_0x42e070('0x1fa')]]),logger[_0x42e070('0x181')](_0x42e070('0xb1'),_0x30a9ac,_0x360df4,_0x782a23[_0x360df4][_0x42e070('0x1fa')]),delete _0x782a23[_0x360df4]),_0x782a23[_0x360df4]&&_0x782a23[_0x360df4][_0x42e070('0x8f')]===_0x42e070('0x14a')&&(_0x2188da[_0x42e070('0x10f')](_0x2188da[_0x42e070('0x13f')][_0x782a23[_0x360df4][_0x42e070('0x1fa')]]),logger[_0x42e070('0x181')]('[Dialer][checkChannel][ivr]',_0x30a9ac,_0x360df4,_0x782a23[_0x360df4][_0x42e070('0x1fa')]),delete _0x782a23[_0x360df4]);},0x2328);});});}},Dialer['prototype']['countReScheduled']=function(_0x477c70){const _0x51e129=_0x369fc5;return Promise['resolve']()['then'](cmHopper[_0x51e129('0x2e')](_0x477c70))[_0x51e129('0x118')](loggerCatch(_0x51e129('0x150')));},Dialer[_0x369fc5('0x1d5')]['checkIsBlackList']=function(_0x4af3c4){const _0x304179=_0x369fc5;return Promise[_0x304179('0x52')]()[_0x304179('0x190')](cmHopperBlack[_0x304179('0x66')](_0x4af3c4))[_0x304179('0x118')](loggerCatch(_0x304179('0x78')));},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0xc6')]=function(_0x140a66){const _0x349de7=_0x369fc5;return Promise[_0x349de7('0x52')]()['then'](cmHopperBlack[_0x349de7('0xc6')](_0x140a66))[_0x349de7('0x118')](loggerCatch('[checkIsBlackListIvr]\x20'));},Dialer[_0x369fc5('0x1d5')]['averageHandleTime']=function(_0x9242cc){const _0x30e933=_0x369fc5;return Promise[_0x30e933('0x52')]()[_0x30e933('0x190')](cmHopperHistory[_0x30e933('0x90')](_0x9242cc))[_0x30e933('0x118')](loggerCatch(_0x30e933('0x1a8')));},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x1db')]=function(_0x41b7de){const _0x4e7454=_0x369fc5;return Promise['resolve']()[_0x4e7454('0x190')](cmHopper[_0x4e7454('0x1db')](_0x41b7de))[_0x4e7454('0x118')](loggerCatch(_0x4e7454('0x168')));},Dialer[_0x369fc5('0x1d5')]['unlockContact']=function(_0x25acb1,_0xcf0b25,_0x50e569){const _0x16fef3=_0x369fc5;return Promise['resolve']()['then'](cmHopper['unlockContact'](_0x25acb1,_0xcf0b25,_0x50e569))['catch'](loggerCatch(_0x16fef3('0x174')));},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x64')]=function(_0x51c6eb,_0x38eccd,_0x42ed9b,_0x189b8a){const _0x424c22=_0x369fc5;return Promise['resolve']()[_0x424c22('0x190')](cmHopper['getContactDialer'](_0x51c6eb,_0x38eccd,_0x42ed9b,_0x189b8a))[_0x424c22('0x118')](loggerCatch(_0x424c22('0x47')));},Dialer[_0x369fc5('0x1d5')]['getContactDialerIvr']=function(_0x404927,_0x5b32ae,_0x3f288d){const _0x510737=_0x369fc5;return Promise['resolve']()['then'](cmHopper[_0x510737('0xdd')](_0x404927,_0x5b32ae,_0x3f288d))[_0x510737('0x118')](loggerCatch(_0x510737('0x47')));},Dialer[_0x369fc5('0x1d5')]['getVoiceQueueRtPauses']=function(_0x148964){const _0xcc9f65=_0x369fc5;return Promise[_0xcc9f65('0x52')]()[_0xcc9f65('0x190')](voiceQueueRt[_0xcc9f65('0x14d')](_0x148964))['catch'](loggerCatch(_0xcc9f65('0x15c')));},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x26')]=function(_0x22084c){const _0x5e6b74=_0x369fc5;return Promise[_0x5e6b74('0x52')]()[_0x5e6b74('0x190')](cmHopper[_0x5e6b74('0x26')](_0x22084c))[_0x5e6b74('0x118')](loggerCatch('[moveContactManagedDialer]\x20'));},Dialer['prototype']['createHistory']=function(_0x1fb0d9){const _0x5ca738=_0x369fc5;return Promise[_0x5ca738('0x52')]()['then'](cmHopperHistory[_0x5ca738('0x135')](_0x1fb0d9))['catch'](loggerCatch(_0x5ca738('0x1e1')));},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x10f')]=function(_0x335274){const _0x2f8bb3=_0x369fc5;!_[_0x2f8bb3('0x1a1')](_0x335274)&&_0x335274!==null?typeof _0x335274['originated']!==_0x2f8bb3('0x58')&&(_0x335274[_0x2f8bb3('0x1da')]>0x0?_0x335274['originated']-=0x1:logger[_0x2f8bb3('0x181')](_0x2f8bb3('0xe2'))):logger[_0x2f8bb3('0x181')](_0x2f8bb3('0xd1'));},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x206')]=function(_0x5637e5,_0x28b555){const _0x37aea1=this;return function(_0x54d82c){const _0x342158=a1057_0x23ff;_0x37aea1['updateOriginated'](_0x28b555),logger[_0x342158('0x181')](_0x5637e5,util[_0x342158('0xa4')](_0x54d82c,{'showHidden':![],'depth':null}));};},Dialer[_0x369fc5('0x1d5')]['emptyContact']=function(_0x31d1b9,_0x5a5362,_0x586f24){const _0x36d86b=_0x369fc5,_0x55c79b={'state':0x19,'statedesc':'notFound'};this[_0x36d86b('0x10f')](_0x5a5362),this[_0x36d86b('0x111')](_[_0x36d86b('0xc3')](_0x55c79b,_[_0x36d86b('0xf2')](_0x586f24,[_0x36d86b('0x13d'),'ListId',_0x36d86b('0x185'),_0x36d86b('0x16'),'CampaignId'])),'[emptyContact][createHistory]',_0x36d86b('0xc7')),logger['error'](_0x31d1b9);},Dialer[_0x369fc5('0x1d5')]['isSuccess']=function(_0x614d65){const _0x53fc3b=_0x369fc5;return _0x614d65===_0x53fc3b('0x1ea');},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x2')]=function(_0x178861){const _0x2cc96a=_0x369fc5;return!_['isUndefined'](_0x178861)&&_0x178861&&!_['isUndefined'](_0x178861[_0x2cc96a('0x46')])&&!_[_0x2cc96a('0x1a1')](_0x178861[_0x2cc96a('0x14c')])&&_0x178861[_0x2cc96a('0x14c')]&&(this[_0x2cc96a('0x1d4')][util[_0x2cc96a('0x1de')](_0x2cc96a('0x147'),_0x178861[_0x2cc96a('0x46')])][_0x2cc96a('0x124')]===_0x2cc96a('0xc0')||this['trunks'][util[_0x2cc96a('0x1de')]('SIP/%s',_0x178861[_0x2cc96a('0x46')])][_0x2cc96a('0x124')]===_0x2cc96a('0xe5'));},Dialer['prototype'][_0x369fc5('0x111')]=function(_0x29deea,_0x3b4530,_0x4c5db8){const _0x4fc720=_0x369fc5;this[_0x4fc720('0x135')](_0x29deea)[_0x4fc720('0x118')](loggerCatch(_0x3b4530)),this[_0x4fc720('0x26')](_0x29deea)[_0x4fc720('0x118')](loggerCatch(_0x4c5db8));},Dialer['prototype'][_0x369fc5('0x9d')]=function(_0x3316dd){const _0x38862c=_0x369fc5,_0x4cc5d6=this[_0x38862c('0x8c')][_0x3316dd['uniqueid']];let _0x22b09e;if(!_[_0x38862c('0x2c')](_0x3316dd)&&!_[_0x38862c('0x2c')](_0x3316dd[_0x38862c('0x10e')])&&!_[_0x38862c('0x2c')](_0x3316dd['variable'][_0x38862c('0x16c')])&&_0x3316dd[_0x38862c('0x9a')]===_0x38862c('0xb3')&&_0x4cc5d6){_0x4cc5d6['type']!==_0x38862c('0x14a')&&this[_0x38862c('0x210')][_0x4cc5d6[_0x38862c('0x1fa')]][_0x38862c('0x72')]&&_0x3316dd[_0x38862c('0xbd')]==='HANGUP'&&(delete this['uniqueId'][_0x3316dd['uniqueid']],this[_0x38862c('0x10f')](this[_0x38862c('0x210')][_0x4cc5d6[_0x38862c('0x1fa')]]),this['voiceQueues'][_0x4cc5d6[_0x38862c('0x1fa')]]['outboundAnswerCallsDay']+=0x1,this['voiceQueues'][_0x4cc5d6[_0x38862c('0x1fa')]][_0x38862c('0x7e')]+=0x1,_0x22b09e=new Hangup(_0x4cc5d6,_0x3316dd),_0x22b09e[_0x38862c('0x2a')]=0x12,_0x22b09e['statedesc']=_0x38862c('0xf'),_0x22b09e[_0x38862c('0x209')]='AMD',this[_0x38862c('0x111')](_0x22b09e,_0x38862c('0x148'),_0x38862c('0x6')));if(_0x4cc5d6[_0x38862c('0x8f')]!==_0x38862c('0x14a')&&this[_0x38862c('0x210')][_0x4cc5d6[_0x38862c('0x1fa')]]['dialAMDActive']&&_0x3316dd[_0x38862c('0xbd')]===_0x38862c('0xfa')){const _0x54abfd=this;return new Promise(function(_0x27ba03,_0x106840){const _0x2796de=_0x38862c;delete _0x54abfd[_0x2796de('0x8c')][_0x3316dd[_0x2796de('0x193')]],_0x54abfd[_0x2796de('0x10f')](_0x54abfd[_0x2796de('0x210')][_0x4cc5d6[_0x2796de('0x1fa')]]),_0x54abfd[_0x2796de('0x210')][_0x4cc5d6[_0x2796de('0x1fa')]]['outboundAnswerCallsDay']+=0x1,_0x54abfd[_0x2796de('0x210')][_0x4cc5d6['queue']][_0x2796de('0x7e')]+=0x1;const _0x3c3f5a=_0x54abfd[_0x2796de('0x210')][_0x4cc5d6['queue']],_0x2a177f=new Hangup(_0x4cc5d6,_0x3316dd);_0x2a177f[_0x2796de('0x2a')]=0x13,_0x2a177f[_0x2796de('0xa')]=_0x2796de('0x158'),_0x2a177f[_0x2796de('0x209')]=_0x2796de('0x75'),_0x2a177f[_0x2796de('0x1f8')]+=0x1,_0x2a177f[_0x2796de('0x187')]+=0x1,_0x2a177f[_0x2796de('0xbe')]=!![],_0x54abfd[_0x2796de('0x135')](_0x2a177f)['catch'](loggerCatch(_0x2796de('0x115'))),_0x2a177f[_0x2796de('0x1ca')]+_0x2a177f[_0x2796de('0x5c')]+_0x2a177f[_0x2796de('0x27')]+_0x2a177f[_0x2796de('0x1d8')]+_0x2a177f[_0x2796de('0x38')]+_0x2a177f[_0x2796de('0x195')]+_0x2a177f[_0x2796de('0x1f8')]+_0x2a177f[_0x2796de('0x54')]>=_0x3c3f5a[_0x2796de('0xca')]?_0x54abfd[_0x2796de('0x8b')](_0x2a177f,_0x27ba03,_0x106840,_0x2796de('0xf6')):_0x2a177f['countmachineretry']>=_0x3c3f5a[_0x2796de('0xdb')]?_0x54abfd['createStateFinal'](_0x2a177f,_0x27ba03,_0x106840,'reason\x2019\x20machine....'):(_0x54abfd['rescheduleContact']({'active':![],'countmachineretry':_0x2a177f[_0x2796de('0x1f8')],'scheduledat':moment()[_0x2796de('0x1f9')](_0x3c3f5a[_0x2796de('0x17b')],_0x2796de('0x1e2'))[_0x2796de('0x1de')]('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x2a177f['ContactId'],'ListId':_0x2a177f[_0x2796de('0x15b')],'VoiceQueueId':_0x2a177f[_0x2796de('0x16')]||undefined,'CampaignId':_0x2a177f[_0x2796de('0x8e')]||undefined})[_0x2796de('0x118')](loggerCatch(_0x2796de('0xf7'))),_0x27ba03({'reschedule':0x1}));});}_0x4cc5d6[_0x38862c('0x8f')]===_0x38862c('0x14a')&&this[_0x38862c('0x13f')][_0x4cc5d6['queue']]['dialAMDActive']&&_0x3316dd[_0x38862c('0xbd')]===_0x38862c('0x1e3')&&(delete this[_0x38862c('0x8c')][_0x3316dd[_0x38862c('0x193')]],this[_0x38862c('0x10f')](this[_0x38862c('0x13f')][_0x4cc5d6[_0x38862c('0x1fa')]]),_0x22b09e=new Hangup(_0x4cc5d6,_0x3316dd),_0x22b09e[_0x38862c('0x2a')]=0x12,_0x22b09e['statedesc']=_0x38862c('0xf'),_0x22b09e[_0x38862c('0x209')]=_0x38862c('0x75'),this[_0x38862c('0x111')](_0x22b09e,_0x38862c('0x1d2'),'[syncHangupInAMDIvr]'));if(_0x4cc5d6[_0x38862c('0x8f')]==='ivr'&&this['campaigns'][_0x4cc5d6[_0x38862c('0x1fa')]][_0x38862c('0x72')]&&_0x3316dd[_0x38862c('0xbd')]==='MACHINE'){const _0x5a8e9c=this;return new Promise(function(_0x3bb4c9,_0x3959ce){const _0x3777b2=_0x38862c;delete _0x5a8e9c[_0x3777b2('0x8c')][_0x3316dd[_0x3777b2('0x193')]],_0x5a8e9c['updateOriginated'](_0x5a8e9c[_0x3777b2('0x13f')][_0x4cc5d6[_0x3777b2('0x1fa')]]),_0x5a8e9c[_0x3777b2('0x13f')][_0x4cc5d6[_0x3777b2('0x1fa')]][_0x3777b2('0x1bb')]+=0x1,_0x5a8e9c[_0x3777b2('0x13f')][_0x4cc5d6[_0x3777b2('0x1fa')]][_0x3777b2('0x7e')]+=0x1;const _0x59f32b=_0x5a8e9c[_0x3777b2('0x13f')][_0x4cc5d6[_0x3777b2('0x1fa')]],_0x5d39c8=new Hangup(_0x4cc5d6,_0x3316dd);_0x5d39c8[_0x3777b2('0x2a')]=0x13,_0x5d39c8[_0x3777b2('0xa')]='Machine',_0x5d39c8[_0x3777b2('0x209')]='AMD',_0x5d39c8[_0x3777b2('0x1f8')]+=0x1,_0x5d39c8[_0x3777b2('0x187')]+=0x1,_0x5d39c8['amd']=!![],_0x5a8e9c[_0x3777b2('0x135')](_0x5d39c8)[_0x3777b2('0x118')](loggerCatch(_0x3777b2('0x115'))),_0x5d39c8['countbusyretry']+_0x5d39c8[_0x3777b2('0x5c')]+_0x5d39c8[_0x3777b2('0x27')]+_0x5d39c8[_0x3777b2('0x1d8')]+_0x5d39c8[_0x3777b2('0x38')]+_0x5d39c8[_0x3777b2('0x195')]+_0x5d39c8[_0x3777b2('0x1f8')]+_0x5d39c8[_0x3777b2('0x54')]>=_0x59f32b[_0x3777b2('0xca')]?_0x5a8e9c[_0x3777b2('0x8b')](_0x5d39c8,_0x3bb4c9,_0x3959ce,_0x3777b2('0xf6')):_0x5d39c8[_0x3777b2('0x1f8')]>=_0x59f32b[_0x3777b2('0xdb')]?_0x5a8e9c[_0x3777b2('0x208')](_0x5d39c8,_0x3bb4c9,_0x3959ce,'reason\x2019\x20machine....'):(_0x5a8e9c[_0x3777b2('0x1db')]({'active':![],'countmachineretry':_0x5d39c8[_0x3777b2('0x1f8')],'scheduledat':moment()[_0x3777b2('0x1f9')](_0x59f32b[_0x3777b2('0x17b')],_0x3777b2('0x1e2'))[_0x3777b2('0x1de')](_0x3777b2('0x12d')),'ContactId':_0x5d39c8[_0x3777b2('0x13d')],'ListId':_0x5d39c8[_0x3777b2('0x15b')],'VoiceQueueId':_0x5d39c8[_0x3777b2('0x16')]||undefined,'CampaignId':_0x5d39c8[_0x3777b2('0x8e')]||undefined})['catch'](loggerCatch(_0x3777b2('0xf7'))),_0x3bb4c9({'reschedule':0x1}));});}}},Dialer['prototype'][_0x369fc5('0x204')]=function(_0xeb1411){const _0x4d9454=_0x369fc5,_0x184d9f=this[_0x4d9454('0x8c')][_0xeb1411['uniqueid']];let _0x4caaa8;_0x184d9f&&_0x184d9f[_0x4d9454('0x8f')]===_0x4d9454('0x14a')&&(delete this[_0x4d9454('0x8c')][_0xeb1411[_0x4d9454('0x193')]],this[_0x4d9454('0x10f')](this['campaigns'][_0x184d9f[_0x4d9454('0x1fa')]]),this[_0x4d9454('0x13f')][_0x184d9f[_0x4d9454('0x1fa')]][_0x4d9454('0xc4')]+=0x1,_0x4caaa8=new Hangup(_0x184d9f,_0xeb1411),this[_0x4d9454('0x135')](_0x4caaa8)[_0x4d9454('0x118')](loggerCatch('[syncHangupIvr][createHistory]')),this[_0x4d9454('0x26')](_0x4caaa8)['catch'](loggerCatch(_0x4d9454('0x2f')))),_0x184d9f&&_0x184d9f[_0x4d9454('0x8f')]!==_0x4d9454('0x14a')&&isNotNull(this[_0x4d9454('0x210')][_0x184d9f['queue']][_0x4d9454('0x4b')])&&(delete this[_0x4d9454('0x8c')][_0xeb1411[_0x4d9454('0x193')]],this[_0x4d9454('0x10f')](this[_0x4d9454('0x210')][_0x184d9f['queue']]),this['voiceQueues'][_0x184d9f[_0x4d9454('0x1fa')]][_0x4d9454('0x1bb')]+=0x1,this[_0x4d9454('0x210')][_0x184d9f[_0x4d9454('0x1fa')]]['outboundAnswerAgiCallsDay']+=0x1,_0x4caaa8=new Hangup(_0x184d9f,_0xeb1411),_0x4caaa8[_0x4d9454('0x2a')]=0x10,_0x4caaa8[_0x4d9454('0xa')]=_0x4d9454('0x14b'),_0x4caaa8['membername']=_0x4d9454('0x5f'),this[_0x4d9454('0x135')](_0x4caaa8)[_0x4d9454('0x118')](loggerCatch(_0x4d9454('0x1e0'))),this[_0x4d9454('0x26')](_0x4caaa8)[_0x4d9454('0x118')](loggerCatch(_0x4d9454('0x2f')))),_0x184d9f&&_0x184d9f['type']!==_0x4d9454('0x14a')&&!isNotNull(this[_0x4d9454('0x210')][_0x184d9f['queue']][_0x4d9454('0x4b')])&&(delete this[_0x4d9454('0x8c')][_0xeb1411[_0x4d9454('0x193')]],this[_0x4d9454('0x10f')](this[_0x4d9454('0x210')][_0x184d9f[_0x4d9454('0x1fa')]]),this[_0x4d9454('0x210')][_0x184d9f['queue']]['outboundUnknownCallsDay']+=0x1,_0x4caaa8=new Hangup(_0x184d9f,_0xeb1411),_0x4caaa8[_0x4d9454('0x2a')]=0xc,_0x4caaa8[_0x4d9454('0xa')]=_0xeb1411[_0x4d9454('0x1e4')],_0x4caaa8[_0x4d9454('0x209')]='Unknow',this[_0x4d9454('0x135')](_0x4caaa8)[_0x4d9454('0x118')](loggerCatch(_0x4d9454('0x1e0'))),this[_0x4d9454('0x26')](_0x4caaa8)[_0x4d9454('0x118')](loggerCatch(_0x4d9454('0x2f'))));},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x1c4')]=function(_0x2908ba){const _0x4e5a59=_0x369fc5,_0x43d06f=this[_0x4e5a59('0x8c')][_0x2908ba[_0x4e5a59('0x193')]];if(this[_0x4e5a59('0x210')][_0x2908ba[_0x4e5a59('0x1fa')]]){if(_0x43d06f&&_0x43d06f[_0x4e5a59('0x8f')]!=='ivr'){delete this[_0x4e5a59('0x8c')][_0x2908ba['uniqueid']],this[_0x4e5a59('0x210')][_0x2908ba[_0x4e5a59('0x1fa')]][_0x4e5a59('0x1bb')]+=0x1;const _0x235ee2=new AgentComplete(_0x43d06f,_0x2908ba);_0x2908ba['reason']===_0x4e5a59('0x1ba')&&(_0x235ee2[_0x4e5a59('0x1b5')]=this[_0x4e5a59('0x210')][_0x2908ba[_0x4e5a59('0x1fa')]][_0x4e5a59('0x9b')]&&this[_0x4e5a59('0x210')][_0x2908ba[_0x4e5a59('0x1fa')]][_0x4e5a59('0x1f2')]?moment()[_0x4e5a59('0x1de')](_0x4e5a59('0x12d')):undefined),this[_0x4e5a59('0x135')](_0x235ee2)[_0x4e5a59('0x118')](loggerCatch(_0x4e5a59('0x156'))),this[_0x4e5a59('0x26')](_0x235ee2)['catch'](loggerCatch(_0x4e5a59('0xff')));}}},Dialer['prototype'][_0x369fc5('0x3c')]=function(_0x4b80f2){const _0x37597f=_0x369fc5;this[_0x37597f('0x210')][_0x4b80f2[_0x37597f('0x1fa')]]&&(this[_0x37597f('0x8c')][_0x4b80f2['uniqueid']]&&this[_0x37597f('0x8c')][_0x4b80f2[_0x37597f('0x193')]][_0x37597f('0x8f')]!==_0x37597f('0x14a')&&(this[_0x37597f('0x10f')](this[_0x37597f('0x210')][_0x4b80f2['queue']]),this[_0x37597f('0x8c')][_0x4b80f2['uniqueid']][_0x37597f('0x109')]=moment()['format'](_0x37597f('0x12d'))));},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0xb4')]=function(_0x5d4369){const _0x1e2dbe=_0x369fc5;this[_0x1e2dbe('0x135')](_0x5d4369)[_0x1e2dbe('0x118')](loggerCatch('[syncAgentComplete][createHistory]')),this['moveContactManagedDialer'](_0x5d4369)[_0x1e2dbe('0x118')](loggerCatch(_0x1e2dbe('0x19')));},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0xed')]=function(_0x1f89fd){const _0x5785c8=_0x369fc5,_0x2ef200=this[_0x5785c8('0x8c')][_0x1f89fd['uniqueid']];if(this['voiceQueues'][_0x1f89fd[_0x5785c8('0x1fa')]]){if(_0x2ef200&&_0x2ef200[_0x5785c8('0x8f')]!==_0x5785c8('0x14a')){delete this[_0x5785c8('0x8c')][_0x1f89fd[_0x5785c8('0x193')]],this['updateOriginated'](this[_0x5785c8('0x210')][_0x1f89fd[_0x5785c8('0x1fa')]]),_0x2ef200['droptime']=moment()[_0x5785c8('0x1de')]('YYYY-MM-DD\x20HH:mm:ss');const _0x8b9b9f=new QueueCallerAbandon(_0x2ef200,_0x1f89fd);if(getSeconds(_0x2ef200[_0x5785c8('0xe9')],_0x2ef200[_0x5785c8('0x17d')])>=_0x2ef200[_0x5785c8('0x1b0')]){this[_0x5785c8('0x210')][_0x1f89fd[_0x5785c8('0x1fa')]]['predictiveIntervalDroppedCallsTimeout']+=0x1,this['voiceQueues'][_0x1f89fd[_0x5785c8('0x1fa')]]['outboundDropCallsDayTimeout']+=0x1,this[_0x5785c8('0x210')][_0x1f89fd[_0x5785c8('0x1fa')]][_0x5785c8('0x13a')]+=0x1,_0x8b9b9f[_0x5785c8('0x2a')]=0xa,_0x8b9b9f[_0x5785c8('0xa')]=_0x5785c8('0x161'),_0x8b9b9f[_0x5785c8('0x121')]=_0x5785c8('0xe7'),_0x8b9b9f[_0x5785c8('0x1b5')]=this[_0x5785c8('0x210')][_0x1f89fd['queue']]['dialQueueProject2']?moment()[_0x5785c8('0x1de')](_0x5785c8('0x12d')):undefined,_0x8b9b9f[_0x5785c8('0x38')]+=0x1,_0x8b9b9f[_0x5785c8('0x187')]+=0x1;if(_0x8b9b9f[_0x5785c8('0x38')]>=this['voiceQueues'][_0x1f89fd['queue']][_0x5785c8('0x28')])this[_0x5785c8('0xb4')](_0x8b9b9f);else{this[_0x5785c8('0x1db')]({'active':![],'countdropretry':_0x8b9b9f[_0x5785c8('0x38')],'scheduledat':moment()[_0x5785c8('0x1f9')](this[_0x5785c8('0x210')][_0x1f89fd[_0x5785c8('0x1fa')]][_0x5785c8('0x1a3')],'minutes')['format']('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x2ef200['ContactId'],'ListId':_0x2ef200[_0x5785c8('0x15b')],'VoiceQueueId':_0x2ef200[_0x5785c8('0x16')]||undefined,'CampaignId':_0x2ef200['CampaignId']||undefined})['catch'](loggerCatch('[rescheduleContact][Drop]'));const _0x348466=new History(_0x8b9b9f);_0x348466[_0x5785c8('0x2a')]=0xa,_0x348466[_0x5785c8('0xa')]=_0x5785c8('0x161'),_0x348466[_0x5785c8('0x18')]=moment()['format'](_0x5785c8('0x12d')),_0x348466[_0x5785c8('0x5')]=_0x348466[_0x5785c8('0x18')],_0x348466[_0x5785c8('0x137')]=_0x8b9b9f[_0x5785c8('0x137')],_0x348466[_0x5785c8('0xb2')]=_0x8b9b9f[_0x5785c8('0xb2')],this[_0x5785c8('0x135')](_0x348466)[_0x5785c8('0x118')](loggerCatch(_0x5785c8('0x16e')));}}else{this['voiceQueues'][_0x1f89fd[_0x5785c8('0x1fa')]][_0x5785c8('0x76')]+=0x1,this[_0x5785c8('0x210')][_0x1f89fd['queue']][_0x5785c8('0x13e')]+=0x1,_0x8b9b9f['state']=0xb,_0x8b9b9f[_0x5785c8('0xa')]=_0x5785c8('0x7f'),_0x8b9b9f[_0x5785c8('0x121')]=_0x5785c8('0x81'),_0x8b9b9f[_0x5785c8('0x195')]+=0x1,_0x8b9b9f['countglobal']+=0x1;if(_0x8b9b9f['countabandonedretry']>=this[_0x5785c8('0x210')][_0x1f89fd[_0x5785c8('0x1fa')]][_0x5785c8('0x4c')])this[_0x5785c8('0xb4')](_0x8b9b9f);else{this['rescheduleContact']({'active':![],'countabandonedretry':_0x8b9b9f['countabandonedretry'],'scheduledat':moment()[_0x5785c8('0x1f9')](this[_0x5785c8('0x210')][_0x1f89fd[_0x5785c8('0x1fa')]][_0x5785c8('0x1f3')],_0x5785c8('0x1e2'))[_0x5785c8('0x1de')](_0x5785c8('0x12d')),'ContactId':_0x2ef200['ContactId'],'ListId':_0x2ef200['ListId'],'VoiceQueueId':_0x2ef200['VoiceQueueId']||undefined,'CampaignId':_0x2ef200[_0x5785c8('0x8e')]||undefined})[_0x5785c8('0x118')](loggerCatch('[rescheduleContact][Abandoned]'));const _0x13d285=new History(_0x8b9b9f);_0x13d285[_0x5785c8('0x2a')]=0xb,_0x13d285['statedesc']=_0x5785c8('0x7f'),_0x13d285['starttime']=moment()[_0x5785c8('0x1de')](_0x5785c8('0x12d')),_0x13d285['endtime']=_0x13d285[_0x5785c8('0x18')],_0x13d285[_0x5785c8('0x137')]=_0x8b9b9f[_0x5785c8('0x137')],_0x13d285[_0x5785c8('0xb2')]=_0x8b9b9f[_0x5785c8('0xb2')],this[_0x5785c8('0x135')](_0x13d285)[_0x5785c8('0x118')](loggerCatch('[syncAgentComplete][createHistory][11]'));}}}}},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0xdf')]=function(_0x1f0ecd){const _0x2419af=_0x369fc5;this[_0x2419af('0x6c')][_0x1f0ecd[_0x2419af('0x193')]]&&(this[_0x2419af('0x6c')][_0x1f0ecd[_0x2419af('0x193')]]['channel']=_0x1f0ecd[_0x2419af('0x162')]),this[_0x2419af('0x8c')][_0x1f0ecd[_0x2419af('0x193')]]&&(this[_0x2419af('0x8c')][_0x1f0ecd[_0x2419af('0x193')]][_0x2419af('0x162')]=_0x1f0ecd['channel']);},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x74')]=function(_0x239315){const _0x438529=_0x369fc5;if(strategy[this[_0x438529('0x210')][this[_0x438529('0x6c')][_0x239315[_0x438529('0x112')]][_0x438529('0x1fa')]][_0x438529('0x103')]]===_0x438529('0x1cc'))this[_0x438529('0x6c')][_0x239315[_0x438529('0x112')]]&&_[_0x438529('0x2c')](this['actions'][_0x239315[_0x438529('0x112')]][_0x438529('0xbf')])&&_0x239315[_0x438529('0x124')]==='1'&&_0x239315[_0x438529('0xd5')]==='0'&&(this['agents'][_0x239315['stateinterface']]&&(!this['agents'][_0x239315[_0x438529('0x160')]][_0x438529('0xbf')]&&(this[_0x438529('0x92')][_0x239315[_0x438529('0x160')]][_0x438529('0xbf')]=!![],this[_0x438529('0x6c')][_0x239315['actionid']][_0x438529('0xbf')]=!![],this[_0x438529('0x6c')][_0x239315[_0x438529('0x112')]][_0x438529('0x160')]=_0x239315[_0x438529('0x160')])));else(strategy[this['voiceQueues'][this[_0x438529('0x6c')][_0x239315[_0x438529('0x112')]][_0x438529('0x1fa')]]['strategy']]||_0x438529('0x17e'))===_0x438529('0x17e')&&(this[_0x438529('0x6c')][_0x239315[_0x438529('0x112')]]&&(this[_0x438529('0x92')][_0x239315[_0x438529('0x160')]]&&(this[_0x438529('0x6c')][_0x239315['actionid']][_0x438529('0x160')]=_0x239315[_0x438529('0x160')],_[_0x438529('0x2c')](this['queueBooked'][this[_0x438529('0x6c')][_0x239315[_0x438529('0x112')]][_0x438529('0x1fa')]])&&(this['queueBooked'][this['actions'][_0x239315[_0x438529('0x112')]][_0x438529('0x1fa')]]=[]),this[_0x438529('0x82')][this[_0x438529('0x6c')][_0x239315['actionid']][_0x438529('0x1fa')]][_0x438529('0xf8')](_['merge'](_[_0x438529('0xf2')](this[_0x438529('0x6c')][_0x239315[_0x438529('0x112')]],[_0x438529('0x100'),_0x438529('0x160')]),{'status':_0x239315[_0x438529('0x124')],'paused':_0x239315['paused']})))));};function unlockQueueStatus(_0x2a3880,_0x372019){setTimeout(function(){const _0x2d1d2d=a1057_0x23ff;_[_0x2d1d2d('0x1a1')](_0x2a3880['queueStatusComplete'])&&loggerBooked[_0x2d1d2d('0x181')](_0x2d1d2d('0x1fd'),_0x372019),_0x2a3880[_0x2d1d2d('0x25')]=!![],loggerBooked['info'](_0x2d1d2d('0xab'),_0x372019,JSON[_0x2d1d2d('0x95')](_[_0x2d1d2d('0xf2')](_0x2a3880,[_0x2d1d2d('0x46'),'queueStatusComplete'])));},0x1f3);}Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x17f')]=function(_0x417eb9){const _0x51480c=_0x369fc5,_0x23df21=this,_0x2f2b65=_0x23df21[_0x51480c('0x210')][_0x23df21[_0x51480c('0x6c')][_0x417eb9['actionid']][_0x51480c('0x1fa')]];if(strategy[this[_0x51480c('0x210')][this[_0x51480c('0x6c')][_0x417eb9[_0x51480c('0x112')]][_0x51480c('0x1fa')]][_0x51480c('0x103')]]===_0x51480c('0x1cc'))this[_0x51480c('0x6c')][_0x417eb9['actionid']]&&this[_0x51480c('0x6c')][_0x417eb9[_0x51480c('0x112')]][_0x51480c('0x160')]?this[_0x51480c('0x65')][_0x51480c('0x3d')](this['actions'][_0x417eb9['actionid']][_0x51480c('0x100')],this[_0x51480c('0x6c')][_0x417eb9[_0x51480c('0x112')]][_0x51480c('0x160')])[_0x51480c('0x118')](function(_0x51d1f9){const _0x3e74b2=_0x51480c;logger[_0x3e74b2('0x181')](_0x3e74b2('0x8d'),util[_0x3e74b2('0xa4')](_0x51d1f9,{'showHidden':![],'depth':null}));})['finally'](function(){const _0x25a11b=_0x51480c;_0x23df21['updateOriginated'](_0x23df21[_0x25a11b('0x210')][_0x23df21[_0x25a11b('0x6c')][_0x417eb9[_0x25a11b('0x112')]]['queue']]),_0x23df21[_0x25a11b('0x92')][_0x23df21['actions'][_0x417eb9[_0x25a11b('0x112')]]['stateinterface']][_0x25a11b('0xbf')]=![],delete _0x23df21[_0x25a11b('0x6c')][_0x417eb9[_0x25a11b('0x112')]],unlockQueueStatus(_0x2f2b65);}):(this[_0x51480c('0x10f')](this[_0x51480c('0x210')][this[_0x51480c('0x6c')][_0x417eb9['actionid']][_0x51480c('0x1fa')]]),this[_0x51480c('0x1db')]({'active':![],'ContactId':this[_0x51480c('0x6c')][_0x417eb9['actionid']][_0x51480c('0x13d')],'ListId':this[_0x51480c('0x6c')][_0x417eb9['actionid']]['ListId'],'VoiceQueueId':this[_0x51480c('0x6c')][_0x417eb9['actionid']][_0x51480c('0x16')]||undefined,'CampaignId':this[_0x51480c('0x6c')][_0x417eb9[_0x51480c('0x112')]][_0x51480c('0x8e')]||undefined})[_0x51480c('0x118')](loggerCatch('[unlock][syncQueueStatusComplete]')),delete this['actions'][_0x417eb9[_0x51480c('0x112')]],unlockQueueStatus(_0x2f2b65));else{if((strategy[this[_0x51480c('0x210')][this[_0x51480c('0x6c')][_0x417eb9['actionid']][_0x51480c('0x1fa')]][_0x51480c('0x103')]]||'rrmemory')===_0x51480c('0x17e')){let _0x207a98;if(this['actions'][_0x417eb9[_0x51480c('0x112')]]&&!_[_0x51480c('0x128')](this[_0x51480c('0x82')][this[_0x51480c('0x6c')][_0x417eb9['actionid']][_0x51480c('0x1fa')]])){this[_0x51480c('0xd')][_0x23df21['actions'][_0x417eb9[_0x51480c('0x112')]][_0x51480c('0x1fa')]]&&(this[_0x51480c('0xd')][_0x23df21[_0x51480c('0x6c')][_0x417eb9[_0x51480c('0x112')]][_0x51480c('0x1fa')]]=this['queueBookedRR'][this[_0x51480c('0x6c')][_0x417eb9['actionid']]['queue']]?this['queueBookedRR'][this[_0x51480c('0x6c')][_0x417eb9[_0x51480c('0x112')]][_0x51480c('0x1fa')]]:this[_0x51480c('0x82')][this[_0x51480c('0x6c')][_0x417eb9[_0x51480c('0x112')]][_0x51480c('0x1fa')]]?this[_0x51480c('0x82')][this['actions'][_0x417eb9[_0x51480c('0x112')]]['queue']][_0x51480c('0xd0')]||0x0:0x0);this[_0x51480c('0x82')][this[_0x51480c('0x6c')][_0x417eb9[_0x51480c('0x112')]][_0x51480c('0x1fa')]][_0x51480c('0xd0')]=this[_0x51480c('0xd')][this[_0x51480c('0x6c')][_0x417eb9['actionid']]['queue']];for(let _0x44d0a2=0x0;_0x44d0a2=0x0?!![]:![];})['catch'](myreject(_0x51b166)));}else _0x4e1cd8[_0x287d0f('0xf8')](ami['Action']({'action':'command','command':util[_0x287d0f('0x1de')](_0x287d0f('0x45'),_0x3c1112,!_[_0x287d0f('0x1a1')](config[_0x287d0f('0x20f')][_0x4e7444])?_0x4e7444:'')})[_0x287d0f('0x190')](function(_0x12c705){const _0x3f01c9=_0x287d0f;return _0x12c705[_0x3f01c9('0x180')][_0x3f01c9('0xdc')](_0x3f01c9('0x7a'))>=0x0?!![]:![];})[_0x287d0f('0x118')](myreject(_0x51b166)));Promise[_0x287d0f('0x1eb')](_0x4e1cd8)[_0x287d0f('0x190')](function(_0x5f560f){const _0x13b5f7=_0x287d0f,_0x51bdc2=_[_0x13b5f7('0x30')](_0x5f560f);return _0x51bdc2?_0x1c3bab(_0x51bdc2):(_0x5743c8[_0x13b5f7('0x18c')]=_0x4ad475?_0x13b5f7('0x159'):'INTERVAL_IS_OVERTIME',_0x51b166(msgResponse(_0x13b5f7('0x119'),_0x13b5f7('0xa7'),'Global:\x20'+_0x4ad475+'\x20'+_0x4fb776+'\x20Interval\x20is\x20overtime:\x20'+util['inspect'](_0x3c1112,{'showHidden':![],'depth':null})+'Timezone:\x20'+_0x4e7444)));})['catch'](function(_0x40c504){const _0x21a949=_0x287d0f;return _0x51b166(msgResponse(_0x21a949('0x1a5'),_0x21a949('0xa7'),JSON[_0x21a949('0x95')](_0x40c504)));});});},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x169')]=function(_0x267b60){const _0x3363ca=this;return function(){const _0x1396aa=a1057_0x23ff;switch(_0x267b60['dialMethod']){case _0x1396aa('0x1d3'):freeVariablesPredictive(_0x267b60),_0x3363ca[_0x1396aa('0xac')](_0x267b60,0x1);break;case'power':freeVariablesPredictive(_0x267b60),_0x3363ca['handlePower'](_0x267b60,_0x267b60['dialPowerLevel']);break;case _0x1396aa('0xea'):_0x3363ca[_0x1396aa('0xea')](_0x267b60);break;case _0x1396aa('0xcf'):freeVariablesPredictive(_0x267b60),_0x3363ca[_0x1396aa('0xac')](_0x267b60,0x1);break;default:freeVariablesPredictive(_0x267b60),logger[_0x1396aa('0x181')]('Queue',_0x267b60[_0x1396aa('0x46')],'method\x20not\x20recognized');}};},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x16b')]=function(_0x3f6db7){const _0xdd207=this;return function(){const _0x447373=a1057_0x23ff;_0xdd207[_0x447373('0x1fe')](_0x3f6db7);};},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x11')]=function(_0x26f78a){const _0x12734c=_0x369fc5,_0x410168=this;isNotPreview(_0x26f78a['dialMethod'])?isVoiceQueueOutbound(_0x26f78a[_0x12734c('0x8f')])&&isActive(_0x26f78a[_0x12734c('0x1f')])?(_0x26f78a[_0x12734c('0x55')]=!![],Promise['resolve']()[_0x12734c('0x190')](checkIsLoggedIn(_0x26f78a,_0x26f78a[_0x12734c('0x163')]))[_0x12734c('0x190')](checkIsActive(_0x26f78a,_0x26f78a[_0x12734c('0x1f')]))[_0x12734c('0x190')](checkInterval(_0x26f78a))[_0x12734c('0x190')](_0x410168[_0x12734c('0x1a9')](_0x26f78a))[_0x12734c('0x190')](_0x410168['checkIfTime'](_0x26f78a[_0x12734c('0x1b4')],_0x26f78a[_0x12734c('0xd3')],_0x26f78a[_0x12734c('0x46')],_0x26f78a))[_0x12734c('0x190')](_0x410168[_0x12734c('0x166')](_0x26f78a[_0x12734c('0x1ae')],_0x26f78a[_0x12734c('0xd3')],_0x26f78a['name'],_0x26f78a))[_0x12734c('0x190')](_0x410168[_0x12734c('0x169')](_0x26f78a))[_0x12734c('0x118')](loggerCatchQueueSummary(_0x12734c('0x19d'),_0x26f78a))):notSendMessagesQueue(_0x26f78a):freeVariablesPredictive(_0x26f78a);},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x1c2')]=function(){const _0x26c2c3=_0x369fc5,_0x4177fd=this;let _0x4bb462;for(const _0x437176 in this['campaigns']){typeof this['campaigns'][_0x437176]!==_0x26c2c3('0x58')&&(_0x4bb462=this['campaigns'][_0x437176],isCampaignIvr(_0x4bb462['type'])&&isActive(_0x4bb462['active'])?(_0x4bb462[_0x26c2c3('0x55')]=!![],Promise['resolve']()[_0x26c2c3('0x190')](checkIsActive(_0x4bb462,_0x4bb462[_0x26c2c3('0x14c')]))[_0x26c2c3('0x190')](checkInterval(_0x4bb462))[_0x26c2c3('0x190')](_0x4177fd[_0x26c2c3('0x1a9')](_0x4bb462))[_0x26c2c3('0x190')](_0x4177fd[_0x26c2c3('0x1d7')](_0x4bb462[_0x26c2c3('0x1b4')],_0x4bb462['dialTimezone'],_0x4bb462[_0x26c2c3('0x46')],_0x4bb462))[_0x26c2c3('0x190')](_0x4177fd[_0x26c2c3('0x166')](_0x4bb462[_0x26c2c3('0x1ae')],_0x4bb462[_0x26c2c3('0xd3')],_0x4bb462[_0x26c2c3('0x46')],_0x4bb462))[_0x26c2c3('0x190')](_0x4177fd[_0x26c2c3('0x16b')](_0x4bb462))[_0x26c2c3('0x118')](loggerCatchQueueSummary('[syncCampaigns]',_0x4bb462))):notSendMessagesCampaign(_0x4bb462));}};function getCallerIdRandom(_0x3cfc38,_0x307d06){const _0x778e13=_0x369fc5;_0x307d06<=0x0&&(_0x307d06=0x1);const _0x129e4f=new RegExp('\x5cw{0,'+_0x307d06+'}$'),_0x111f84=Math[_0x778e13('0x16a')](0xa,_0x307d06-0x1),_0x44fd38=Math[_0x778e13('0x16a')](0xa,_0x307d06)-0x1;return util['format']('%s',_[_0x778e13('0x203')](_0x3cfc38,_0x129e4f,_[_0x778e13('0x1b9')](_0x111f84,_0x44fd38)));}function extractCalleridName(_0x10730d){const _0x18f694=_0x369fc5,_0xd30533=_0x10730d[_0x18f694('0x42')](/"(.*?)"/);return _0xd30533?_0xd30533[0x1]:_0x10730d;}function extractCalleridNumber(_0x3d874d){const _0x2a9227=_0x369fc5,_0x37b7d9=_0x3d874d[_0x2a9227('0x42')](/<(.*?)>/);return _0x37b7d9?_0x37b7d9[0x1]:_0x3d874d;}Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x1f6')]=function(_0x2e287a,_0x29b6b6){const _0x261265=_0x369fc5,_0x2c70d2=getConfigService(),_0x514e0d=this,_0xf1a438=uuid['v4']();return this[_0x261265('0x6c')][_0xf1a438]=new Action(_0x2e287a,_0x29b6b6,_0xf1a438),new Promise(function(_0x36980f,_0x3b85a9){const _0x4dca2b=_0x261265;if(_[_0x4dca2b('0x1a1')](_0x2e287a)&&_0x4dca2b('0x173')!==typeof _0x2e287a)return _0x3b85a9(msgResponse(_0x4dca2b('0x184'),_0x4dca2b('0xa7'),_0x4dca2b('0x1af')));if(_[_0x4dca2b('0x1a1')](_0x29b6b6['Contact'][_0x4dca2b('0x1ad')])||_0x29b6b6[_0x4dca2b('0x146')]['phone']===null)return _0x3b85a9(msgResponse(_0x4dca2b('0x184'),_0x4dca2b('0xa7'),_0x4dca2b('0x113')));const _0x13e081={'XMD-CALLERID':_0x514e0d['actions'][_0xf1a438]['getCaller'](),'XMD-AGI':_0x2e287a[_0x4dca2b('0x4b')]?util[_0x4dca2b('0x1de')](_0x4dca2b('0x142'),_0x2c70d2[_0x4dca2b('0x1bf')],_0x2e287a[_0x4dca2b('0x4b')]):'NONE','XMD-AGIAFTER':_0x2e287a[_0x4dca2b('0x9b')]?util[_0x4dca2b('0x1de')](_0x4dca2b('0x142'),_0x2c70d2[_0x4dca2b('0x1bf')],_0x2e287a['dialQueueProject2']):'NONE','XMD-QUEUE':_0x2e287a['type']==='outbound'?util[_0x4dca2b('0x1de')](_0x4dca2b('0x20c'),_0x2e287a['name'],_0x2e287a['dialQueueOptions']||'',_0x2e287a['dialAgiAfterHangupAgent']?'c':'',_0x2e287a['dialQueueTimeout']||0x3):_0x4dca2b('0x99'),'XMD-CONTACTID':_0x29b6b6[_0x4dca2b('0x13d')],'XMD-CDRTYPE':_0x4dca2b('0x12f'),'CALLERID(all)':_0x514e0d[_0x4dca2b('0x6c')][_0xf1a438][_0x4dca2b('0x12e')](),'XMD-AMD':_0x2e287a[_0x4dca2b('0x72')]?'ACTIVE':'NONE','XMD-DESTINATION':_0x4dca2b('0xb3')};_0x2e287a[_0x4dca2b('0x72')]&&(_0x13e081[_0x4dca2b('0x94')]=_0x2e287a['dialAMDInitialSilence']||0x9c4,_0x13e081[_0x4dca2b('0x1ef')]=_0x2e287a[_0x4dca2b('0x49')]||0x5dc,_0x13e081[_0x4dca2b('0x130')]=_0x2e287a[_0x4dca2b('0x34')]||0x320,_0x13e081[_0x4dca2b('0x1ec')]=_0x2e287a[_0x4dca2b('0x14')]||0x1388,_0x13e081[_0x4dca2b('0x1b1')]=_0x2e287a[_0x4dca2b('0x106')]||0x64,_0x13e081[_0x4dca2b('0x16f')]=_0x2e287a['dialAMDBetweenWordsSilence']||0x32,_0x13e081[_0x4dca2b('0xe4')]=_0x2e287a['dialAMDMaximumNumberOfWords']||0x3,_0x13e081[_0x4dca2b('0x1c')]=_0x2e287a[_0x4dca2b('0x48')]||0x100,_0x13e081[_0x4dca2b('0x15d')]=_0x2e287a[_0x4dca2b('0x1df')]||0x1388);_0x2e287a['type']===_0x4dca2b('0x1cf')?_0x13e081['XMD-VOICEQUEUEID']=_0x29b6b6[_0x4dca2b('0x16')]:_0x13e081[_0x4dca2b('0x1dd')]=_0x29b6b6[_0x4dca2b('0x8e')];for(const _0xb6207 in _0x29b6b6[_0x4dca2b('0x146')]){typeof _0x29b6b6[_0x4dca2b('0x146')][_0xb6207]!==_0x4dca2b('0x58')&&(isNotNull(_0x29b6b6[_0x4dca2b('0x146')][_0xb6207])&&_0xb6207!=='id'&&_0xb6207!==_0x4dca2b('0x152')&&_0xb6207!==_0x4dca2b('0x19b')&&_0xb6207!==_0x4dca2b('0x11c')&&(_0x13e081[util[_0x4dca2b('0x1de')](_0x4dca2b('0xd7'),_0x4dca2b('0x157'),_[_0x4dca2b('0xc1')](_0xb6207))]=_0x29b6b6[_0x4dca2b('0x146')][_0xb6207]));}const _0x22be46=_0x514e0d[_0x4dca2b('0x2')](_0x2e287a['Trunk'])?getCallerId(_0x2e287a[_0x4dca2b('0x11a')][_0x4dca2b('0x108')],_0x2e287a['dialOriginateCallerIdName'],_0x2e287a['dialRandomLastDigitCallerIdNumber']>0x0?getCallerIdRandom(_0x2e287a[_0x4dca2b('0x1cb')],_0x2e287a[_0x4dca2b('0x133')]):_0x2e287a[_0x4dca2b('0x1cb')]):getCallerId(_[_0x4dca2b('0x2c')](_0x2e287a[_0x4dca2b('0x1e9')])?_0x2e287a[_0x4dca2b('0x11a')][_0x4dca2b('0x108')]:_0x2e287a['TrunkBackup'][_0x4dca2b('0x108')],_0x2e287a[_0x4dca2b('0x79')],_0x2e287a['dialRandomLastDigitCallerIdNumber']>0x0?getCallerIdRandom(_0x2e287a['dialOriginateCallerIdNumber'],_0x2e287a[_0x4dca2b('0x133')]):_0x2e287a[_0x4dca2b('0x1cb')]);if(_0x22be46){const _0x5d603b=extractCalleridName(_0x22be46);_0x13e081[_0x4dca2b('0xf4')]=_0x5d603b,_0x514e0d[_0x4dca2b('0x6c')][_0xf1a438][_0x4dca2b('0x71')]=_0x5d603b;const _0x176078=extractCalleridNumber(_0x22be46);_0x13e081[_0x4dca2b('0x59')]==_0x176078,_0x514e0d[_0x4dca2b('0x6c')][_0xf1a438]['originatecalleridnum']=_0x176078;}return ami[_0x4dca2b('0x201')]({'actionid':_0xf1a438,'action':_0x4dca2b('0x184'),'channel':_0x514e0d[_0x4dca2b('0x2')](_0x2e287a[_0x4dca2b('0x11a')])?util['format']('SIP/%s/%s%s',_0x2e287a[_0x4dca2b('0x11a')][_0x4dca2b('0x46')],isNotNull(_0x2e287a[_0x4dca2b('0x1b7')])?_0x2e287a[_0x4dca2b('0x1b7')]['trim']()||'':'',_0x2e287a[_0x4dca2b('0x51')]>0x0?_0x29b6b6[_0x4dca2b('0x146')][_0x4dca2b('0x1ad')][_0x4dca2b('0x15')](_0x2e287a[_0x4dca2b('0x51')]):_0x29b6b6[_0x4dca2b('0x146')][_0x4dca2b('0x1ad')]):util[_0x4dca2b('0x1de')](_0x4dca2b('0xf3'),_[_0x4dca2b('0x2c')](_0x2e287a[_0x4dca2b('0x1e9')])?_0x2e287a[_0x4dca2b('0x11a')][_0x4dca2b('0x46')]:_0x2e287a['TrunkBackup'][_0x4dca2b('0x46')],isNotNull(_0x2e287a[_0x4dca2b('0x1b7')])?_0x2e287a[_0x4dca2b('0x1b7')][_0x4dca2b('0x97')]()||'':'',_0x2e287a[_0x4dca2b('0x51')]>0x0?_0x29b6b6['Contact']['phone'][_0x4dca2b('0x15')](_0x2e287a[_0x4dca2b('0x51')]):_0x29b6b6[_0x4dca2b('0x146')][_0x4dca2b('0x1ad')]),'callerid':_0x22be46,'Exten':'xcally-motion-dialer','Context':'from-sip','Priority':'1','variable':_0x13e081,'timeout':(_0x2e287a[_0x4dca2b('0x1cd')]||0x1e)*0x3e8,'async':!![],'channelid':_0xf1a438})['then'](function(_0x16e856){return _0x36980f(_0x16e856);})[_0x4dca2b('0x118')](function(_0x995929){const _0x4f4b89=_0x4dca2b;_0x2e287a[_0x4f4b89('0x1c0')]+=0x1;const _0x207a13=new History(_0x514e0d['actions'][_0xf1a438]);logger[_0x4f4b89('0x181')](util[_0x4f4b89('0x1de')](_0x4f4b89('0xe'),JSON[_0x4f4b89('0x95')](_0x995929))),_0x207a13[_0x4f4b89('0x2a')]=0xe,_0x207a13[_0x4f4b89('0xa')]=_0x4f4b89('0x129'),_0x207a13['starttime']=moment()[_0x4f4b89('0x1de')]('YYYY-MM-DD\x20HH:mm:ss'),_0x207a13[_0x4f4b89('0x5')]=_0x207a13[_0x4f4b89('0x18')],_0x514e0d['createHistory'](_0x207a13)[_0x4f4b89('0x118')](loggerCatch('[originate][error]')),_0x514e0d[_0x4f4b89('0x26')](_0x207a13)[_0x4f4b89('0x118')](loggerCatch(_0x4f4b89('0x176')))[_0x4f4b89('0x183')](function(){const _0x2fee15=_0x4f4b89;return delete _0x514e0d[_0x2fee15('0x6c')][_0xf1a438],_0x3b85a9(msgResponse(_0x2fee15('0x184'),'Error',_0x2fee15('0x84')));});});});},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x89')]=function(_0x20180f){const _0x464d1e=_0x369fc5,_0x4bff29=this[_0x464d1e('0x6c')][_0x20180f[_0x464d1e('0x112')]];if(_0x4bff29){delete this[_0x464d1e('0x6c')][_0x20180f[_0x464d1e('0x112')]],_0x4bff29[_0x464d1e('0x17d')]=moment()[_0x464d1e('0x1de')]('YYYY-MM-DD\x20HH:mm:ss');const _0x47ee78=_0x4bff29['type']===_0x464d1e('0x14a')?this[_0x464d1e('0x13f')][_0x4bff29[_0x464d1e('0x1fa')]]:this[_0x464d1e('0x210')][_0x4bff29[_0x464d1e('0x7d')]()];if(!this[_0x464d1e('0xec')](_0x20180f[_0x464d1e('0x19e')]))return this[_0x464d1e('0x10f')](_0x47ee78),this[_0x464d1e('0x0')](_0x4bff29,_0x47ee78,_0x20180f)[_0x464d1e('0x190')](function(){})[_0x464d1e('0x118')](loggerCatch(_0x464d1e('0x20e')));else this[_0x464d1e('0x8c')][_0x20180f[_0x464d1e('0x193')]]=_0x4bff29;}},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x1e8')]=function(_0x6c5a4c,_0x7c0931,_0x387691){const _0x3c2b15=_0x369fc5,_0x426b4e=new History(_0x7c0931);if(_0x426b4e['countbusyretry']+_0x426b4e[_0x3c2b15('0x5c')]+_0x426b4e[_0x3c2b15('0x27')]+_0x426b4e[_0x3c2b15('0x1d8')]+_0x426b4e[_0x3c2b15('0x38')]+_0x426b4e[_0x3c2b15('0x195')]+_0x426b4e['countmachineretry']+_0x426b4e[_0x3c2b15('0x54')]>=_0x387691['dialGlobalMaxRetry']-0x1)return!![];switch(_0x6c5a4c){case 0x3:if(_0x426b4e['countnoanswerretry']>=_0x387691[_0x3c2b15('0x1f1')]-0x1)return!![];else this[_0x3c2b15('0x1db')]({'active':![],'countnoanswerretry':_0x426b4e['countnoanswerretry']+=0x1,'scheduledat':moment()[_0x3c2b15('0x1f9')](_0x387691['dialNoAnswerRetryFrequency'],'minutes')[_0x3c2b15('0x1de')](_0x3c2b15('0x12d')),'ContactId':_0x426b4e[_0x3c2b15('0x13d')],'ListId':_0x426b4e[_0x3c2b15('0x15b')],'VoiceQueueId':_0x426b4e[_0x3c2b15('0x16')]||undefined,'CampaignId':_0x426b4e[_0x3c2b15('0x8e')]||undefined})['catch'](loggerCatch(_0x3c2b15('0xcd')));break;case 0x5:if(_0x426b4e[_0x3c2b15('0x1ca')]>=_0x387691[_0x3c2b15('0x197')]-0x1)return!![];else this[_0x3c2b15('0x1db')]({'active':![],'countbusyretry':_0x426b4e[_0x3c2b15('0x1ca')]+=0x1,'scheduledat':moment()['add'](_0x387691[_0x3c2b15('0x86')],_0x3c2b15('0x1e2'))[_0x3c2b15('0x1de')](_0x3c2b15('0x12d')),'ContactId':_0x426b4e['ContactId'],'ListId':_0x426b4e['ListId'],'VoiceQueueId':_0x426b4e[_0x3c2b15('0x16')]||undefined,'CampaignId':_0x426b4e[_0x3c2b15('0x8e')]||undefined})[_0x3c2b15('0x118')](loggerCatch('[rescheduleContact]\x20[Busy]'));break;case 0x8:if(_0x426b4e[_0x3c2b15('0x5c')]>=_0x387691['dialCongestionMaxRetry']-0x1)return!![];else this[_0x3c2b15('0x1db')]({'active':![],'countcongestionretry':_0x426b4e[_0x3c2b15('0x5c')]+=0x1,'scheduledat':moment()['add'](_0x387691[_0x3c2b15('0x1')],_0x3c2b15('0x1e2'))[_0x3c2b15('0x1de')](_0x3c2b15('0x12d')),'ContactId':_0x426b4e[_0x3c2b15('0x13d')],'ListId':_0x426b4e['ListId'],'VoiceQueueId':_0x426b4e['VoiceQueueId']||undefined,'CampaignId':_0x426b4e[_0x3c2b15('0x8e')]||undefined})['catch'](loggerCatch('[rescheduleContact]\x20[Congestion]'));break;case 0x0:if(_0x426b4e[_0x3c2b15('0x1d8')]>=_0x387691[_0x3c2b15('0x1f0')]-0x1)return!![];else this[_0x3c2b15('0x1db')]({'active':![],'countnosuchnumberretry':_0x426b4e[_0x3c2b15('0x1d8')]+=0x1,'scheduledat':moment()[_0x3c2b15('0x1f9')](_0x387691[_0x3c2b15('0x1fc')],_0x3c2b15('0x1e2'))[_0x3c2b15('0x1de')](_0x3c2b15('0x12d')),'ContactId':_0x426b4e[_0x3c2b15('0x13d')],'ListId':_0x426b4e[_0x3c2b15('0x15b')],'VoiceQueueId':_0x426b4e[_0x3c2b15('0x16')]||undefined,'CampaignId':_0x426b4e[_0x3c2b15('0x8e')]||undefined})[_0x3c2b15('0x118')](loggerCatch(_0x3c2b15('0xeb')));break;case 0xa:if(_0x426b4e['countdropretry']>=_0x387691[_0x3c2b15('0x28')]-0x1)return!![];else this['rescheduleContact']({'active':![],'countdropretry':_0x426b4e[_0x3c2b15('0x38')]+=0x1,'scheduledat':moment()[_0x3c2b15('0x1f9')](_0x387691[_0x3c2b15('0x1a3')],_0x3c2b15('0x1e2'))[_0x3c2b15('0x1de')](_0x3c2b15('0x12d')),'ContactId':_0x426b4e['ContactId'],'ListId':_0x426b4e[_0x3c2b15('0x15b')],'VoiceQueueId':_0x426b4e[_0x3c2b15('0x16')]||undefined,'CampaignId':_0x426b4e[_0x3c2b15('0x8e')]||undefined})['catch'](loggerCatch('[rescheduleContact][Drop]'));break;case 0xb:if(_0x426b4e[_0x3c2b15('0x195')]>=_0x387691[_0x3c2b15('0x4c')]-0x1)return!![];else this[_0x3c2b15('0x1db')]({'active':![],'countabandonedretry':_0x426b4e[_0x3c2b15('0x195')]+=0x1,'scheduledat':moment()['add'](_0x387691[_0x3c2b15('0x1f3')],_0x3c2b15('0x1e2'))[_0x3c2b15('0x1de')](_0x3c2b15('0x12d')),'ContactId':_0x426b4e['ContactId'],'ListId':_0x426b4e['ListId'],'VoiceQueueId':_0x426b4e[_0x3c2b15('0x16')]||undefined,'CampaignId':_0x426b4e[_0x3c2b15('0x8e')]||undefined})[_0x3c2b15('0x118')](loggerCatch(_0x3c2b15('0x98')));break;case 0x13:if(_0x426b4e[_0x3c2b15('0x1f8')]>=_0x387691[_0x3c2b15('0xdb')]-0x1)return!![];else this[_0x3c2b15('0x1db')]({'active':![],'countmachineretry':_0x426b4e[_0x3c2b15('0x1f8')]+=0x1,'scheduledat':moment()[_0x3c2b15('0x1f9')](_0x387691[_0x3c2b15('0x17b')],_0x3c2b15('0x1e2'))['format']('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x426b4e['ContactId'],'ListId':_0x426b4e[_0x3c2b15('0x15b')],'VoiceQueueId':_0x426b4e[_0x3c2b15('0x16')]||undefined,'CampaignId':_0x426b4e[_0x3c2b15('0x8e')]||undefined})[_0x3c2b15('0x118')](loggerCatch(_0x3c2b15('0xf7')));break;case 0x14:if(_0x426b4e['countagentrejectretry']>=_0x387691['dialAgentRejectMaxRetry']-0x1)return!![];else this[_0x3c2b15('0x1db')]({'active':![],'countagentrejectretry':_0x426b4e['countagentrejectretry']+=0x1,'scheduledat':moment()[_0x3c2b15('0x1f9')](_0x387691['dialAgentRejectRetryFrequency'],_0x3c2b15('0x1e2'))[_0x3c2b15('0x1de')](_0x3c2b15('0x12d')),'ContactId':_0x426b4e[_0x3c2b15('0x13d')],'ListId':_0x426b4e['ListId'],'VoiceQueueId':_0x426b4e[_0x3c2b15('0x16')]||undefined,'CampaignId':_0x426b4e[_0x3c2b15('0x8e')]||undefined})[_0x3c2b15('0x118')](loggerCatch(_0x3c2b15('0x1f4')));break;default:return!![];}},Dialer['prototype'][_0x369fc5('0x0')]=function(_0xfd1da8,_0x10b3a1,_0x1c52c9){const _0x5e0ffb=this,_0x5defea=new History(_0xfd1da8);return new Promise(function(_0x4e4e51,_0x3f8a13){const _0x41e0da=a1057_0x23ff;if(_[_0x41e0da('0x1a1')](_0x10b3a1)&&_0x41e0da('0x173')!==typeof _0x10b3a1)return _0x3f8a13(msgResponse(_0x41e0da('0x110'),_0x41e0da('0xa7'),_0x41e0da('0x19c')));if(_[_0x41e0da('0x1a1')](_0x1c52c9)&&'object'!==typeof _0x1c52c9)return _0x3f8a13(msgResponse('[callProgressDetecting]',_0x41e0da('0xa7'),_0x41e0da('0x136')));switch(_0x1c52c9[_0x41e0da('0x12')]){case'0':_0x10b3a1[_0x41e0da('0x1d6')]+=0x1,_0x5defea[_0x41e0da('0x2a')]=0x0,_0x5defea['statedesc']=_0x41e0da('0x39'),_0x5defea['countnosuchnumberretry']+=0x1,_0x5defea['countglobal']+=0x1,ami[_0x41e0da('0x178')]('custom:agentnosuchnumber',ut[_0x41e0da('0xc2')](_0xfd1da8,_0x41e0da('0x6b'))),_0x5e0ffb[_0x41e0da('0x135')](_0x5defea)['catch'](loggerCatch(_0x41e0da('0x115')));_0x5e0ffb['checkRetriveMax'](0x0,_0xfd1da8,_0x10b3a1)&&(_0x5defea['countnosuchnumberretry']>=_0x10b3a1[_0x41e0da('0x1f0')]?_0x5e0ffb[_0x41e0da('0x208')](_0x5defea,_0x4e4e51,_0x3f8a13,_0x41e0da('0x1ff')):_0x5e0ffb[_0x41e0da('0x8b')](_0x5defea,_0x4e4e51,_0x3f8a13,'reason\x200\x20no\x20such\x20number....'));break;case'3':_0x10b3a1[_0x41e0da('0x1b6')]+=0x1,_0x5defea['state']=0x3,_0x5defea[_0x41e0da('0xa')]='NoAnswer',_0x5defea[_0x41e0da('0x27')]+=0x1,_0x5defea[_0x41e0da('0x187')]+=0x1,ami[_0x41e0da('0x178')](_0x41e0da('0x16d'),ut[_0x41e0da('0xc2')](_0xfd1da8,_0x41e0da('0x9e'))),_0x5e0ffb[_0x41e0da('0x135')](_0x5defea)[_0x41e0da('0x118')](loggerCatch('[syncAgentComplete][createHistory][3]'));_0x5e0ffb[_0x41e0da('0x1e8')](0x3,_0xfd1da8,_0x10b3a1)&&(_0x5defea['countnoanswerretry']>=_0x10b3a1[_0x41e0da('0x1f1')]?_0x5e0ffb[_0x41e0da('0x208')](_0x5defea,_0x4e4e51,_0x3f8a13,_0x41e0da('0x1b8')):_0x5e0ffb[_0x41e0da('0x8b')](_0x5defea,_0x4e4e51,_0x3f8a13,'reason\x203\x20ringing\x20no\x20answer'));break;case'5':_0x10b3a1[_0x41e0da('0x68')]+=0x1,_0x5defea[_0x41e0da('0x2a')]=0x5,_0x5defea[_0x41e0da('0xa')]=_0x41e0da('0x202'),_0x5defea['countbusyretry']+=0x1,_0x5defea[_0x41e0da('0x187')]+=0x1,ami[_0x41e0da('0x178')](_0x41e0da('0x102'),ut[_0x41e0da('0xc2')](_0xfd1da8,_0x41e0da('0xe8'))),_0x5e0ffb[_0x41e0da('0x135')](_0x5defea)[_0x41e0da('0x118')](loggerCatch('[syncAgentComplete][createHistory][5]'));_0x5e0ffb[_0x41e0da('0x1e8')](0x5,_0xfd1da8,_0x10b3a1)&&(_0x5defea[_0x41e0da('0x1ca')]>=_0x10b3a1[_0x41e0da('0x197')]?_0x5e0ffb[_0x41e0da('0x208')](_0x5defea,_0x4e4e51,_0x3f8a13,_0x41e0da('0x53')):_0x5e0ffb['stateGlobal'](_0x5defea,_0x4e4e51,_0x3f8a13,_0x41e0da('0x53')));break;case'8':_0x10b3a1[_0x41e0da('0x1c1')]+=0x1,_0x5defea[_0x41e0da('0x2a')]=0x8,_0x5defea[_0x41e0da('0xa')]='Congestion',_0x5defea[_0x41e0da('0x5c')]+=0x1,_0x5defea['countglobal']+=0x1,ami[_0x41e0da('0x178')](_0x41e0da('0x12c'),ut['buildObj'](_0xfd1da8,_0x41e0da('0xf9'))),_0x5e0ffb[_0x41e0da('0x135')](_0x5defea)['catch'](loggerCatch('[syncAgentComplete][createHistory][8]'));_0x5e0ffb[_0x41e0da('0x1e8')](0x8,_0xfd1da8,_0x10b3a1)&&(_0x5defea[_0x41e0da('0x5c')]>=_0x10b3a1[_0x41e0da('0x104')]?_0x5e0ffb['createStateFinal'](_0x5defea,_0x4e4e51,_0x3f8a13,_0x41e0da('0xde')):_0x5e0ffb[_0x41e0da('0x8b')](_0x5defea,_0x4e4e51,_0x3f8a13,_0x41e0da('0xde')));break;case'11':_0x10b3a1[_0x41e0da('0x77')]+=0x1,_0x5defea[_0x41e0da('0x2a')]=0xb,_0x5defea['statedesc']=_0x41e0da('0x7f'),_0x5defea[_0x41e0da('0x195')]+=0x1,_0x5defea[_0x41e0da('0x187')]+=0x1,_0x5e0ffb[_0x41e0da('0x135')](_0x5defea)[_0x41e0da('0x118')](loggerCatch(_0x41e0da('0x5d')));_0x5e0ffb[_0x41e0da('0x1e8')](0xb,_0xfd1da8,_0x10b3a1)&&(_0x5defea[_0x41e0da('0x195')]>=_0x10b3a1[_0x41e0da('0x4c')]?_0x5e0ffb[_0x41e0da('0x208')](_0x5defea,_0x4e4e51,_0x3f8a13,_0x41e0da('0x18f')):_0x5e0ffb[_0x41e0da('0x8b')](_0x5defea,_0x4e4e51,_0x3f8a13,_0x41e0da('0x18f')));break;case'20':_0x10b3a1[_0x41e0da('0xd9')]+=0x1,_0x5defea[_0x41e0da('0x2a')]=0x14,_0x5defea[_0x41e0da('0xa')]=_0x41e0da('0x20d'),_0x5defea['countagentrejectretry']+=0x1,_0x5defea[_0x41e0da('0x187')]+=0x1,ami['emit'](_0x41e0da('0xaa'),ut['buildObj'](_0xfd1da8,_0x41e0da('0x5e'))),_0x5e0ffb[_0x41e0da('0x135')](_0x5defea)[_0x41e0da('0x118')](loggerCatch(_0x41e0da('0x1c8')));_0x5e0ffb[_0x41e0da('0x1e8')](0x14,_0xfd1da8,_0x10b3a1)&&(_0x5defea[_0x41e0da('0x54')]>=_0x10b3a1['dialAgentRejectMaxRetry']?_0x5e0ffb[_0x41e0da('0x208')](_0x5defea,_0x4e4e51,_0x3f8a13,'reason\x2020\x20agentreject'):_0x5e0ffb[_0x41e0da('0x8b')](_0x5defea,_0x4e4e51,_0x3f8a13,'reason\x2020\x20agentreject'));break;default:_0x10b3a1[_0x41e0da('0xb5')]+=0x1,_0x5defea[_0x41e0da('0x2a')]=0xc,_0x5defea[_0x41e0da('0xa')]=_0x1c52c9[_0x41e0da('0x12')],_0x5e0ffb[_0x41e0da('0x135')](_0x5defea)['catch'](loggerCatch(_0x41e0da('0x7')));_0x5e0ffb[_0x41e0da('0x1e8')](_0x1c52c9[_0x41e0da('0x12')],_0xfd1da8,_0x10b3a1)&&(_0x5defea[_0x41e0da('0x1ca')]+_0x5defea[_0x41e0da('0x5c')]+_0x5defea['countnoanswerretry']+_0x5defea[_0x41e0da('0x1d8')]+_0x5defea[_0x41e0da('0x38')]+_0x5defea[_0x41e0da('0x195')]+_0x5defea[_0x41e0da('0x1f8')]+_0x5defea[_0x41e0da('0x54')]>=_0x10b3a1[_0x41e0da('0xca')]?_0x5e0ffb[_0x41e0da('0x8b')](_0x5defea,_0x4e4e51,_0x3f8a13,_0x1c52c9[_0x41e0da('0x12')]):_0x5e0ffb[_0x41e0da('0x208')](_0x5defea,_0x4e4e51,_0x3f8a13,_0x1c52c9[_0x41e0da('0x12')]));}});},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x8b')]=function(_0x113ed1,_0x5d9a2c,_0x3af33a,_0x25d597){const _0x580bb5=_0x369fc5,_0x32028b=new Final(_0x113ed1);_0x32028b[_0x580bb5('0x2a')]=0xf,_0x32028b[_0x580bb5('0xa')]=_0x580bb5('0x31'),this[_0x580bb5('0x208')](_0x32028b,_0x5d9a2c,_0x3af33a,_0x25d597);},Dialer[_0x369fc5('0x1d5')]['createStateFinal']=function(_0x5ad81b,_0x3a8944,_0x3e863b,_0x485c2d){const _0x112087=_0x369fc5;this[_0x112087('0x26')](_0x5ad81b)[_0x112087('0x190')](function(){const _0x428fa5=_0x112087;return _0x3a8944(msgResponse(_0x428fa5('0x110'),_0x428fa5('0x1ea'),_0x485c2d));})[_0x112087('0x118')](function(){const _0x4687d9=_0x112087;return _0x3e863b(msgResponse(_0x4687d9('0x13'),'Failure',_0x4687d9('0x1bc')));});},Dialer[_0x369fc5('0x1d5')]['predictive']=function(_0xecaf58){const _0x24a8c4=_0x369fc5,_0xe0420f=_0xecaf58['dialPredictiveOptimizationPercentage']/0x64,_0x17ef23=_0xecaf58[_0x24a8c4('0x141')]/(_0xecaf58[_0x24a8c4('0x141')]+_0xecaf58[_0x24a8c4('0x1bb')]),_0x4242ab=Math[_0x24a8c4('0xa3')](_0xecaf58[_0x24a8c4('0xe3')]*(_0xecaf58[_0x24a8c4('0x12b')]/0x64)),_0x255aba=Math['round'](_0xecaf58[_0x24a8c4('0xe3')]*(_0xecaf58[_0x24a8c4('0x17')]/0x64)),_0x23b772=_0xecaf58[_0x24a8c4('0x167')]+_0xecaf58[_0x24a8c4('0x182')],_0x39bbfb=Math[_0x24a8c4('0x120')](_0xecaf58[_0x24a8c4('0x1a2')]*_0xecaf58[_0x24a8c4('0x1d9')]*_0xecaf58[_0x24a8c4('0x37')]*_0xecaf58[_0x24a8c4('0x144')]);if(_['isUndefined'](_0xecaf58[_0x24a8c4('0xbb')]))!_[_0x24a8c4('0x1a1')](_0xecaf58[_0x24a8c4('0x19f')])&&(_0xecaf58[_0x24a8c4('0x19f')]=undefined,loggerPredictive[_0x24a8c4('0x181')](_0x24a8c4('0x139'),'check\x20predictive\x20is\x20not\x20undefine')),!_['isUndefined'](_0xecaf58['handlePredictive'])&&(loggerPredictive[_0x24a8c4('0x181')](_0x24a8c4('0x139'),_0x24a8c4('0x80')),clearInterval(_0xecaf58['handlePredictive']),_0xecaf58[_0x24a8c4('0x6f')]=undefined),_0xecaf58[_0x24a8c4('0xbb')]=moment()[_0x24a8c4('0x1de')]('YYYY-MM-DD\x20HH:mm:ss'),loggerPredictive[_0x24a8c4('0x70')](_0xecaf58[_0x24a8c4('0x46')],'collection\x20data\x20in\x20progressive\x20at',_0xecaf58['startProgressive']),this[_0x24a8c4('0xac')](_0xecaf58,0x1);else{if(ifInterval(_0xecaf58[_0x24a8c4('0x105')],_0xecaf58[_0x24a8c4('0xbb')]))this['handlePower'](_0xecaf58,0x1),loggerPredictiveCalls[_0x24a8c4('0x70')](_0x24a8c4('0x56'),_0xecaf58['startProgressive'],_0xecaf58[_0x24a8c4('0x46')]),_0xecaf58['erlangCalls']=0x0,_0xecaf58[_0x24a8c4('0x13a')]=0x0;else{if(_0xe0420f<_0x17ef23&&_0xecaf58['dialPredictiveOptimization']===_0x24a8c4('0x11f'))freeVariablesPredictive(_0xecaf58),loggerPredictive[_0x24a8c4('0x70')]('[stopMethodPredictive][ReStartProgressive][ExceededDropDay]',_0x24a8c4('0xb9'),_0x17ef23,_0x24a8c4('0xbb'),_0xecaf58[_0x24a8c4('0x46')]);else{if(_0x39bbfb<_0xecaf58[_0x24a8c4('0x13a')]&&_0xecaf58[_0x24a8c4('0x4a')]===_0x24a8c4('0x11f'))freeVariablesPredictive(_0xecaf58),loggerPredictive[_0x24a8c4('0x70')](_0x24a8c4('0x10c'),_0x24a8c4('0xb6'),_0x39bbfb,_0x24a8c4('0x57'),_0xecaf58[_0x24a8c4('0x13a')],_0x24a8c4('0xbb'),_0xecaf58[_0x24a8c4('0x46')]);else{if(!ifInterval(_0xecaf58[_0x24a8c4('0x105')],_0xecaf58[_0x24a8c4('0xbb')])&&_[_0x24a8c4('0x1a1')](_0xecaf58[_0x24a8c4('0x19f')])&&!_[_0x24a8c4('0x1a1')](_0xecaf58['startProgressive']))_0xecaf58[_0x24a8c4('0x19f')]=moment()[_0x24a8c4('0x1de')]('YYYY-MM-DD\x20HH:mm:ss'),loggerPredictive['info'](_0xecaf58[_0x24a8c4('0x46')],_0x24a8c4('0x188'),_0xecaf58[_0x24a8c4('0x19f')]),this[_0x24a8c4('0x41')](_0xecaf58[_0x24a8c4('0x105')])[_0x24a8c4('0x190')](this['getDataPredictive'](_0xecaf58))['then'](mergeDataErlangB(_0xecaf58))[_0x24a8c4('0x190')](this[_0x24a8c4('0x186')](_0xecaf58))[_0x24a8c4('0x118')](loggerCatchPredictive(_0x24a8c4('0x165'),_0xecaf58));else{if(!ifInterval(_0xecaf58[_0x24a8c4('0x105')],_0xecaf58['startPredictive']))_0xecaf58[_0x24a8c4('0x13a')]=0x0,_0xecaf58['startPredictive']=moment()[_0x24a8c4('0x1de')](_0x24a8c4('0x12d')),loggerPredictive[_0x24a8c4('0x70')](_0xecaf58[_0x24a8c4('0x46')],_0x24a8c4('0x62'),_0xecaf58['startPredictive']),clearInterval(_0xecaf58[_0x24a8c4('0x6f')]),_0xecaf58[_0x24a8c4('0x6f')]=undefined,this[_0x24a8c4('0x41')](_0xecaf58[_0x24a8c4('0x105')])[_0x24a8c4('0x190')](this['getDataPredictive'](_0xecaf58))[_0x24a8c4('0x190')](mergeDataErlangB(_0xecaf58))[_0x24a8c4('0x190')](this['startMethodPredictive'](_0xecaf58))[_0x24a8c4('0x118')](loggerCatchPredictive(_0x24a8c4('0x1d1'),_0xecaf58));else{if(_0xecaf58['predictiveIntervalAvailable']&&_0x23b772<_0xecaf58['predictiveIntervalAvailable']-_0x255aba)freeVariablesPredictive(_0xecaf58),loggerPredictive['info'](_0xecaf58[_0x24a8c4('0x46')],_0x24a8c4('0x170'),_0x23b772,_0x24a8c4('0x1ac'),_0xecaf58[_0x24a8c4('0xe3')],'-',_0x255aba,'=',_0xecaf58['predictiveIntervalAvailable']-_0x255aba,')');else _0xecaf58[_0x24a8c4('0xe3')]&&_0x23b772>_0xecaf58[_0x24a8c4('0xe3')]+_0x4242ab&&(freeVariablesPredictive(_0xecaf58),loggerPredictive[_0x24a8c4('0x70')](_0xecaf58[_0x24a8c4('0x46')],_0x24a8c4('0x170'),_0x23b772,_0x24a8c4('0x69'),_0xecaf58[_0x24a8c4('0xe3')],'+',_0x4242ab,'=',_0xecaf58['predictiveIntervalAvailable']+_0x4242ab,')'));}}}}}}},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x140')]=function(_0x4cf9db){const _0x68661a=this;return function(_0x4d8532){return new Promise(function(_0x4dfcbe,_0x40d3a5){const _0x1358dc=a1057_0x23ff;_[_0x1358dc('0xc3')](_0x4cf9db,_0x4d8532[0x0]);if(checkGetDataPredictive(_0x4d8532[0x0])){const _0x39c96e=_0x4cf9db[_0x1358dc('0x182')]+_0x4cf9db[_0x1358dc('0x167')];_0x4cf9db[_0x1358dc('0xe3')]=_0x39c96e;const _0x1e6f22=_0x39c96e,_0x1d9ff7=_0x4cf9db[_0x1358dc('0x105')]*0x3c,_0x3912f8=_0x4d8532[0x0]['predictiveIntervalAvgTalktime']+_0x4d8532[0x0][_0x1358dc('0x1c6')],_0x41b997=(_0x4d8532[0x0][_0x1358dc('0x13b')]+_0x4d8532[0x0][_0x1358dc('0x83')]+_0x4d8532[0x0][_0x1358dc('0x76')])/_0x4d8532[0x0][_0x1358dc('0x1c5')];_0x4cf9db[_0x1358dc('0x37')]=_0x41b997>0x0?_0x41b997:0x1;switch(_0x4cf9db['dialPredictiveOptimization']){case _0x1358dc('0x11f'):{const _0x1debf8=_0x4cf9db[_0x1358dc('0x10')]/0x64;return _0x68661a[_0x1358dc('0x171')](_0x1e6f22,_0x1d9ff7,_0x3912f8,_0x41b997,_0x1debf8)[_0x1358dc('0x190')](function(_0x212385){return _0x4dfcbe(_0x212385);});}case _0x1358dc('0x1dc'):{const _0x55ded6=_0x4cf9db[_0x1358dc('0x10')]/0x64;return _0x68661a[_0x1358dc('0x4')](_0x1e6f22,_0x1d9ff7,_0x3912f8,_0x41b997,_0x55ded6)[_0x1358dc('0x190')](function(_0x44fdf1){return _0x4dfcbe(_0x44fdf1);});}default:return _0x40d3a5(msgResponse('[getDataPredictive]','Failure',_0x1358dc('0x96')));}}else return _0x40d3a5(msgResponse(_0x1358dc('0x1a4'),_0x1358dc('0xa7'),_0x1358dc('0xa5')));});};},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0xd6')]=function(_0xa99aa7){const _0x20f05d=this;return function(_0x401838){return new Promise(function(_0x14b2ad,_0x4fbd42){const _0x29c75e=a1057_0x23ff;_[_0x29c75e('0xc3')](_0xa99aa7,_0x401838[0x0]);if(checkGetDataPredictive(_0x401838[0x0])){loggerPredictive[_0x29c75e('0x70')](JSON[_0x29c75e('0x95')](_0x401838[0x0]));if(_0xa99aa7[_0x29c75e('0x4a')]===_0x29c75e('0x11f'))return _0x20f05d[_0x29c75e('0x14d')](_0xa99aa7['id'])['then'](function(_0x291e63){const _0x246d7b=_0x29c75e,_0x479af9=_0xa99aa7[_0x246d7b('0x163')]-_0x291e63[0x0][_0x246d7b('0x1ab')],_0x56ba76=_0xa99aa7[_0x246d7b('0x105')]*0x3c,_0x1cf3d5=_0x401838[0x0][_0x246d7b('0x67')]+_0x401838[0x0][_0x246d7b('0x1c6')],_0x45856c=(_0x401838[0x0][_0x246d7b('0x13b')]+_0x401838[0x0]['predictiveIntervalDroppedCallsTimeout']+_0x401838[0x0][_0x246d7b('0x76')])/_0x401838[0x0][_0x246d7b('0x1c5')],_0x29275f=_0xa99aa7['dialPredictiveOptimizationPercentage']/0x64;return _0xa99aa7[_0x246d7b('0x175')]=_0x291e63[0x0][_0x246d7b('0x1ab')]||0x0,_0xa99aa7[_0x246d7b('0x37')]=_0x45856c>0x0?_0x45856c:0x1,_0x20f05d[_0x246d7b('0x171')](_0x479af9,_0x56ba76,_0x1cf3d5,_0x45856c,_0x29275f);})[_0x29c75e('0x190')](function(_0x2bb2de){return _0x14b2ad(_0x2bb2de);})[_0x29c75e('0x118')](function(_0xca247b){const _0x250722=_0x29c75e;return _0x4fbd42(msgResponse(_0x250722('0x154'),_0x250722('0xa7'),JSON['stringify'](_0xca247b)));});if(_0xa99aa7[_0x29c75e('0x4a')]==='agentBusyFactor')return _0x20f05d[_0x29c75e('0x14d')](_0xa99aa7['id'])['then'](function(_0x468f10){const _0x75e424=_0x29c75e,_0x2d1f4a=_0xa99aa7[_0x75e424('0x163')]-_0x468f10[0x0][_0x75e424('0x1ab')],_0x1bba62=_0xa99aa7[_0x75e424('0x105')]*0x3c,_0x2a5741=_0x401838[0x0][_0x75e424('0x67')]+_0x401838[0x0][_0x75e424('0x1c6')],_0x442474=(_0x401838[0x0][_0x75e424('0x13b')]+_0x401838[0x0][_0x75e424('0x83')]+_0x401838[0x0][_0x75e424('0x76')])/_0x401838[0x0][_0x75e424('0x1c5')],_0x823b17=_0xa99aa7[_0x75e424('0x10')]/0x64;return _0xa99aa7['predictiveIntervalPauses']=_0x468f10[0x0][_0x75e424('0x1ab')]||0x0,_0xa99aa7[_0x75e424('0x37')]=_0x442474>0x0?_0x442474:0x1,_0x20f05d['busyFactor'](_0x2d1f4a,_0x1bba62,_0x2a5741,_0x442474,_0x823b17);})[_0x29c75e('0x190')](function(_0x164028){return _0x14b2ad(_0x164028);})[_0x29c75e('0x118')](function(_0x5004f0){const _0x3ba0f4=_0x29c75e;return _0x4fbd42(msgResponse(_0x3ba0f4('0x154'),'Failure',JSON[_0x3ba0f4('0x95')](_0x5004f0)));});}else return _0x4fbd42(msgResponse(_0x29c75e('0x1a4'),_0x29c75e('0xa7'),_0x29c75e('0xa5')));});};},Dialer['prototype'][_0x369fc5('0x186')]=function(_0x484e8b){const _0x4da629=this;return function(){const _0x562f8d=a1057_0x23ff;let _0x5b3fa0=0x0,_0x593d17=Math[_0x562f8d('0x120')](_0x484e8b['erlangCallToSecond']*0x3e8);_0x593d17>0x0?(_0x593d17=_0x593d17<0x64?0x64:_0x593d17,loggerPredictive[_0x562f8d('0x70')](_0x484e8b[_0x562f8d('0x46')],_0x562f8d('0x14f'),_0x593d17,_0x562f8d('0x43')),_0x484e8b['handlePredictive']=setInterval(function(){const _0x463637=_0x562f8d;_0x4da629[_0x463637('0x6f')](_0x484e8b),loggerPredictiveCalls[_0x463637('0x70')](_0x463637('0x10b'),_0x5b3fa0+=0x1);},_0x593d17)):loggerPredictive[_0x562f8d('0x70')](_0x484e8b[_0x562f8d('0x46')],_0x562f8d('0x15f'));};},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x1aa')]=function(_0x109246,_0x14d0bc){const _0x352bfd=this;return function(_0x1e0bab){const _0x242bc9=a1057_0x23ff;if(_[_0x242bc9('0x128')](_0x1e0bab)){if(_[_0x242bc9('0x2c')](_0x14d0bc['UserId'])||!_0x14d0bc[_0x242bc9('0xf1')]){if(_0x109246[_0x242bc9('0x50')]===_0x242bc9('0xcf')){_0x109246['queueStatusComplete']=_[_0x242bc9('0x1a1')](_0x109246[_0x242bc9('0x25')])?!![]:_0x109246[_0x242bc9('0x25')];const _0x53d275=uuid['v4']();_0x352bfd[_0x242bc9('0x6c')][_0x53d275]=new Action(_0x109246,_0x14d0bc,_0x53d275),loggerBooked[_0x242bc9('0x70')]('[booked][checkContactBlack]',_0x53d275,'queueStatusComplete:\x20',JSON['stringify'](_0x109246[_0x242bc9('0x25')]),_0x242bc9('0x200'),_0x109246[_0x242bc9('0x46')]),_0x109246[_0x242bc9('0x25')]?(_0x109246[_0x242bc9('0x25')]=![],_0x352bfd[_0x242bc9('0x82')][_0x352bfd[_0x242bc9('0x6c')][_0x53d275][_0x242bc9('0x1fa')]]=[],ami[_0x242bc9('0x201')]({'actionid':_0x53d275,'action':'queuestatus','queue':_0x109246[_0x242bc9('0x46')]})[_0x242bc9('0x118')](function(){const _0x33801b=_0x242bc9;_0x352bfd[_0x33801b('0x10f')](_0x109246),_0x352bfd[_0x33801b('0x1db')]({'active':![],'ContactId':_0x352bfd[_0x33801b('0x6c')][_0x53d275][_0x33801b('0x13d')],'ListId':_0x352bfd[_0x33801b('0x6c')][_0x53d275][_0x33801b('0x15b')],'VoiceQueueId':_0x352bfd[_0x33801b('0x6c')][_0x53d275][_0x33801b('0x16')]||undefined,'CampaignId':_0x352bfd['actions'][_0x53d275][_0x33801b('0x8e')]||undefined})[_0x33801b('0x118')](loggerCatch(_0x33801b('0x149'))),delete _0x352bfd[_0x33801b('0x6c')][_0x53d275];})):(loggerBooked['info'](_0x242bc9('0x1b2'),JSON[_0x242bc9('0x95')](_0x109246[_0x242bc9('0x25')]),'Queue:\x20',_0x109246['name']),_0x352bfd[_0x242bc9('0x10f')](_0x109246),_0x352bfd[_0x242bc9('0x1db')]({'active':![],'ContactId':_0x352bfd['actions'][_0x53d275][_0x242bc9('0x13d')],'ListId':_0x352bfd[_0x242bc9('0x6c')][_0x53d275][_0x242bc9('0x15b')],'VoiceQueueId':_0x352bfd[_0x242bc9('0x6c')][_0x53d275][_0x242bc9('0x16')]||undefined,'CampaignId':_0x352bfd['actions'][_0x53d275][_0x242bc9('0x8e')]||undefined})['catch'](loggerCatch(_0x242bc9('0x149'))),delete _0x352bfd[_0x242bc9('0x6c')][_0x53d275]);}else return _0x352bfd[_0x242bc9('0x1f6')](_0x109246,_0x14d0bc);}else getDiff(_0x14d0bc['scheduledat'])<_0x109246['dialRecallMeTimeout']*0x3c?_0x14d0bc[_0x242bc9('0xfb')]&&!_0x14d0bc[_0x242bc9('0xfb')][_0x242bc9('0x1e6')]?_0x352bfd[_0x242bc9('0x65')][_0x242bc9('0x3d')](_0x14d0bc['id'])['finally'](function(){const _0x50cee2=_0x242bc9;_0x352bfd[_0x50cee2('0x10f')](_0x109246);}):_0x352bfd[_0x242bc9('0x199')]({'active':![]},_0x14d0bc['id'],0x1)[_0x242bc9('0x183')](function(){const _0xf436bd=_0x242bc9;console[_0xf436bd('0x8')]('Contact\x20updated'),_0x352bfd[_0xf436bd('0x10f')](_0x109246);}):(_0x109246['outboundReCallsDay']+=0x1,_0x352bfd[_0x242bc9('0x10f')](_0x109246),_0x109246[_0x242bc9('0x10a')]?(_0x352bfd[_0x242bc9('0x1db')]({'active':![],'recallme':![],'UserId':null,'ContactId':_0x14d0bc[_0x242bc9('0x13d')],'ListId':_0x14d0bc[_0x242bc9('0x15b')],'VoiceQueueId':_0x14d0bc['VoiceQueueId']||undefined,'CampaignId':_0x14d0bc[_0x242bc9('0x8e')]||undefined})[_0x242bc9('0x118')](loggerCatch('[rescheduleContact][dialRecallInQueue]')),_0x352bfd[_0x242bc9('0x135')](createObjHistory(_0x109246,_0x14d0bc,'RECALLINQUEUE',0x17,_0x242bc9('0x21')))[_0x242bc9('0x118')](loggerCatch(_0x242bc9('0xc5')))):_0x352bfd[_0x242bc9('0x111')](createObjHistory(_0x109246,_0x14d0bc,'RECALLFAILEDTIMEOUT',0x16,_0x242bc9('0xa1')),'[Originate][HistoryRecallClose][historyCatch]',_0x242bc9('0x87')));}else{_0x109246[_0x242bc9('0x4e')]+=0x1,_0x352bfd[_0x242bc9('0x111')](createObjHistory(_0x109246,_0x14d0bc,_0x242bc9('0x29'),0xd,_0x242bc9('0xa6')),_0x242bc9('0xfd'),_0x242bc9('0x93'));throw _0x242bc9('0x88');}};},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x1fe')]=function(_0x55dc4b){const _0x594254=_0x369fc5,_0x528ac4=this;let _0x5b958b=_0x55dc4b[_0x594254('0x20b')]-_0x55dc4b['originated']-_0x55dc4b['temp'];emitCampaignSummary(_0x55dc4b),_0x5b958b>0x0&&(_0x5b958b>this[_0x594254('0x4d')]&&(_0x5b958b=this[_0x594254('0x4d')]),_0x55dc4b['temp']+=_0x5b958b,this[_0x594254('0xdd')](_0x55dc4b['id'],_0x5b958b,_0x55dc4b['dialOrderByScheduledAt'])[_0x594254('0x190')](function(_0x455a18){const _0xaf9ef6=_0x594254;_0x55dc4b[_0xaf9ef6('0xfe')]-=_0x5b958b,_0x55dc4b[_0xaf9ef6('0xfe')]=_0x55dc4b['temp']>0x0?_0x55dc4b[_0xaf9ef6('0xfe')]:0x0;if(!checkContactEmpty(_0x455a18))_0x55dc4b[_0xaf9ef6('0x18c')]=_0xaf9ef6('0x7c'),logger[_0xaf9ef6('0x70')](_0xaf9ef6('0xad')+_0x55dc4b[_0xaf9ef6('0x46')]);else{_0x55dc4b[_0xaf9ef6('0x1da')]+=_0x455a18['length'],_0x55dc4b[_0xaf9ef6('0x18c')]=_0xaf9ef6('0x15a');for(let _0x4ffbf7=0x0;_0x4ffbf7<_0x455a18[_0xaf9ef6('0x145')];_0x4ffbf7+=0x1){_0x55dc4b['ivrTotalCallsDays']+=0x1,_['isNil'](_0x455a18[_0x4ffbf7])||_['isNil'](_0x455a18[_0x4ffbf7][_0xaf9ef6('0x146')])||_[_0xaf9ef6('0x2c')](_0x455a18[_0x4ffbf7][_0xaf9ef6('0x146')]['phone'])?_0x528ac4[_0xaf9ef6('0x1c3')](_0xaf9ef6('0xc8'),_0x55dc4b,_0x455a18[_0x4ffbf7]):_0x528ac4[_0xaf9ef6('0xc6')](_[_0xaf9ef6('0xf2')](_0x455a18[_0x4ffbf7],['CampaignId','Contact.phone']))[_0xaf9ef6('0x190')](_0x528ac4['checkContactBlack'](_0x55dc4b,_0x455a18[_0x4ffbf7]))[_0xaf9ef6('0x118')](_0x528ac4[_0xaf9ef6('0x206')](_0xaf9ef6('0x17a'),_0x55dc4b));}}})[_0x594254('0x118')](loggerGetContactDialer(_0x594254('0x3f'),_0x55dc4b,_0x5b958b)));},Dialer['prototype'][_0x369fc5('0xac')]=function(_0x480de9,_0x1c58cc){const _0x201196=_0x369fc5,_0x23b2e7=this,_0x734cc3=[];let _0x25123a=_0x1c58cc>=0x1?_0x1c58cc:0x1;_0x480de9[_0x201196('0x50')]===_0x201196('0xcf')&&(_0x25123a=0x1);let _0x1922da=Math[_0x201196('0x120')](_0x480de9['available']*_0x25123a)-_0x480de9[_0x201196('0x1da')]-_0x480de9[_0x201196('0xfe')];emitVoiceQueueSummary(_0x480de9);if(_0x480de9[_0x201196('0x44')]>0x0){const _0x143c10=_0x480de9[_0x201196('0x44')]-_0x480de9[_0x201196('0x1da')]-_0x480de9[_0x201196('0x182')]-_0x480de9[_0x201196('0xfe')]-_0x480de9['pTalking'];_0x1922da>_0x143c10&&(_0x1922da=_0x143c10);}if(_0x1922da>0x0){_0x480de9[_0x201196('0x50')]===_0x201196('0xcf')&&(_0x1922da=0x1);_0x1922da>this[_0x201196('0x4d')]&&(_0x1922da=this[_0x201196('0x4d')]);_0x480de9['temp']+=_0x1922da;for(const _0x2b93ec in this[_0x201196('0x92')]){typeof this[_0x201196('0x92')][_0x2b93ec]!==_0x201196('0x58')&&(this[_0x201196('0x92')][_0x2b93ec][_0x201196('0x2a')]===_0x201196('0x5b')&&this[_0x201196('0x92')][_0x2b93ec][_0x201196('0x124')]===_0x201196('0xc0')&&_0x734cc3[_0x201196('0xf8')](this['agents'][_0x2b93ec]['id']));}this['getContactDialer'](_0x480de9['id'],_0x734cc3,_0x1922da,_0x480de9['dialOrderByScheduledAt'])[_0x201196('0x190')](function(_0x15f8f1){const _0x23a8ab=_0x201196;_0x480de9[_0x23a8ab('0xfe')]-=_0x1922da,_0x480de9[_0x23a8ab('0xfe')]=_0x480de9[_0x23a8ab('0xfe')]>0x0?_0x480de9[_0x23a8ab('0xfe')]:0x0;if(!checkContactEmpty(_0x15f8f1))_0x23b2e7['countReScheduled'](_0x480de9)['then'](sendMessageReschedule(_0x480de9))[_0x23a8ab('0x118')](loggerCatch('[countReScheduled]\x20'));else{_0x480de9['originated']+=_0x15f8f1[_0x23a8ab('0x145')],_0x480de9['message']=_0x480de9[_0x23a8ab('0x50')]===_0x23a8ab('0xcf')?_0x23a8ab('0x127'):_0x23a8ab('0x15a');for(let _0x32c550=0x0;_0x32c550<_0x15f8f1['length'];_0x32c550+=0x1){_['isNil'](_0x15f8f1[_0x32c550])||_['isNil'](_0x15f8f1[_0x32c550][_0x23a8ab('0x146')])||_[_0x23a8ab('0x2c')](_0x15f8f1[_0x32c550][_0x23a8ab('0x146')][_0x23a8ab('0x1ad')])?_0x23b2e7[_0x23a8ab('0x1c3')](_0x23a8ab('0xc8'),_0x480de9,_0x15f8f1[_0x32c550]):_0x23b2e7[_0x23a8ab('0x66')](_[_0x23a8ab('0xf2')](_0x15f8f1[_0x32c550],[_0x23a8ab('0x16'),_0x23a8ab('0xcc')]))[_0x23a8ab('0x190')](_0x23b2e7[_0x23a8ab('0x1aa')](_0x480de9,_0x15f8f1[_0x32c550]))['catch'](_0x23b2e7[_0x23a8ab('0x206')](_0x23a8ab('0xc8'),_0x480de9));}}})[_0x201196('0x118')](loggerGetContactDialer(_0x201196('0xba'),_0x480de9,_0x1922da));}},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x6f')]=function(_0x144859){const _0x5dc86d=_0x369fc5;if(_0x144859['dialLimitQueue']>0x0){const _0x2a7def=_0x144859[_0x5dc86d('0x44')]-_0x144859[_0x5dc86d('0x1da')]-_0x144859['talking'];_0x2a7def>0x0?this[_0x5dc86d('0xfc')](_0x144859):loggerPredictiveCalls['info'](_0x5dc86d('0xee'));}else this[_0x5dc86d('0xfc')](_0x144859);},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0xfc')]=function(_0x4c128a){const _0x407543=_0x369fc5,_0x2455c6=this,_0x66aa07=[];_0x4c128a[_0x407543('0x1da')]+=0x1;for(const _0x557a7f in this[_0x407543('0x92')]){typeof this[_0x407543('0x92')][_0x557a7f]!=='undefined'&&(this['agents'][_0x557a7f]['state']===_0x407543('0x5b')&&this[_0x407543('0x92')][_0x557a7f][_0x407543('0x124')]===_0x407543('0xc0')&&_0x66aa07[_0x407543('0xf8')](this[_0x407543('0x92')][_0x557a7f]['id']));}this[_0x407543('0x64')](_0x4c128a['id'],_0x66aa07,0x1,_0x4c128a[_0x407543('0x19a')])[_0x407543('0x190')](function(_0x35a5f4){const _0x31fac0=_0x407543;!checkContactEmpty(_0x35a5f4)?(checkContactLowerLimitOriginate(_0x4c128a,0x1,0x0),_0x2455c6['countReScheduled'](_0x4c128a)[_0x31fac0('0x190')](sendMessageReschedule(_0x4c128a))[_0x31fac0('0x118')](loggerCatch('[countReScheduled]\x20'))):(_0x4c128a[_0x31fac0('0x18c')]='RUNNING',_[_0x31fac0('0x2c')](_0x35a5f4[0x0])||_[_0x31fac0('0x2c')](_0x35a5f4[0x0][_0x31fac0('0x146')])||_['isNil'](_0x35a5f4[0x0]['Contact'][_0x31fac0('0x1ad')])?_0x2455c6[_0x31fac0('0x1c3')](_0x31fac0('0xc8'),_0x4c128a,_0x35a5f4[0x0]):_0x2455c6[_0x31fac0('0x66')](_['pick'](_0x35a5f4[0x0],[_0x31fac0('0x16'),_0x31fac0('0xcc')]))['then'](_0x2455c6['checkContactBlack'](_0x4c128a,_0x35a5f4[0x0]))[_0x31fac0('0x118')](_0x2455c6[_0x31fac0('0x206')](_0x31fac0('0x40'),_0x4c128a)));})['catch'](loggerGetContactDialer(_0x407543('0xe1'),_0x4c128a,0x1)),emitVoiceQueueSummary(_0x4c128a);},Dialer[_0x369fc5('0x1d5')][_0x369fc5('0x171')]=function(_0x408939,_0x39d3a1,_0x4c113a,_0xd66a3a,_0x5ef4ec,_0x52587d){const _0x3bd2b8=_0x369fc5;return loggerPredictive['info']('--------\x20Drop\x20Rate\x20--------'),loggerPredictive[_0x3bd2b8('0x70')](_0x3bd2b8('0x122'),_0x408939),loggerPredictive[_0x3bd2b8('0x70')](_0x3bd2b8('0x7b'),_0x39d3a1),loggerPredictive['info'](_0x3bd2b8('0x4f'),_0x4c113a),loggerPredictive['info'](_0x3bd2b8('0x1e7'),_0xd66a3a),loggerPredictive[_0x3bd2b8('0x70')](_0x3bd2b8('0x1c7'),_0x5ef4ec),loggerPredictive[_0x3bd2b8('0x70')](_0x3bd2b8('0x132')),new Promise(function(_0x8ccf17,_0x2c8cf8){const _0x21a482=_0x3bd2b8;if(_0x408939<=0x0||isNaN(_0x408939))return _0x2c8cf8(msgResponse(_0x21a482('0xd8'),_0x21a482('0x1b3'),_0x21a482('0xa0')+_0x408939));if(_0x4c113a<=0x0||isNaN(_0x4c113a))return _0x2c8cf8(msgResponse(_0x21a482('0xd8'),_0x21a482('0x1b3'),_0x21a482('0xf0')+_0x4c113a));if(_0xd66a3a<=0x0||isNaN(_0xd66a3a))return _0x2c8cf8(msgResponse(_0x21a482('0xd8'),_0x21a482('0x1b3'),_0x21a482('0x3b')+_0xd66a3a));if(_0x39d3a1<=0x0||isNaN(_0x39d3a1))return _0x2c8cf8(msgResponse(_0x21a482('0xd8'),'Error',_0x21a482('0x101')+_0x39d3a1));if(_0x5ef4ec<=0x0||isNaN(_0x5ef4ec))return _0x2c8cf8(msgResponse(_0x21a482('0xd8'),'Error','Amax\x20=\x20'+_0x5ef4ec));_0x52587d=_0x52587d||0x0;const _0x162ff4=0x1/_0x4c113a;let _0x4e5203=0x0,_0xd94728=0x0,_0x1788ce=0x0,_0x56f6c6=0x0,_0x3e7b34=0x0;for(_0x3e7b34=0x0;_0x1788ce<_0x5ef4ec;_0x3e7b34+=0x1){_0xd94728=_0x3e7b34/_0x39d3a1,_0x4e5203=(_0xd66a3a*_0xd94728+_0x52587d)/_0x162ff4,_0x1788ce=erlangb(_0x4e5203,_0x408939),_0x56f6c6=_0x4e5203/_0x408939*(0x1-erlangb(_0x4e5203,_0x408939));}return _0x8ccf17({'erlangCalls':_0x3e7b34,'erlangCallToSecond':_0x39d3a1/_0x3e7b34,'erlangAbandonmentRate':_0x1788ce,'erlangBusyFactor':_0x56f6c6});});},Dialer[_0x369fc5('0x1d5')]['busyFactor']=function(_0xe4b369,_0x185de1,_0x5ef969,_0x2b9fcf,_0x54cc1d,_0x5ef81c){const _0x3cd2ea=_0x369fc5;return loggerPredictive[_0x3cd2ea('0x70')](_0x3cd2ea('0x1a7')),loggerPredictive[_0x3cd2ea('0x70')](_0x3cd2ea('0x122'),_0xe4b369),loggerPredictive[_0x3cd2ea('0x70')](_0x3cd2ea('0x7b'),_0x185de1),loggerPredictive[_0x3cd2ea('0x70')](_0x3cd2ea('0x4f'),_0x5ef969),loggerPredictive[_0x3cd2ea('0x70')](_0x3cd2ea('0x1e7'),_0x2b9fcf),loggerPredictive['info'](_0x3cd2ea('0xb7'),_0x54cc1d),loggerPredictive['info']('---------------------------'),new Promise(function(_0x1cf646,_0x4b2645){const _0x4f42f0=_0x3cd2ea;if(_0xe4b369<=0x0||isNaN(_0xe4b369))return _0x4b2645(msgResponse(_0x4f42f0('0x2b'),_0x4f42f0('0x1b3'),_0x4f42f0('0xa0')+_0xe4b369));if(_0x5ef969<=0x0||isNaN(_0x5ef969))return _0x4b2645(msgResponse(_0x4f42f0('0x2b'),'Error',_0x4f42f0('0xf0')+_0x5ef969));if(_0x2b9fcf<=0x0||isNaN(_0x2b9fcf))return _0x4b2645(msgResponse(_0x4f42f0('0x2b'),_0x4f42f0('0x1b3'),'p\x20=\x20'+_0x2b9fcf));if(_0x185de1<=0x0||isNaN(_0x185de1))return _0x4b2645(msgResponse('[busyFactor]',_0x4f42f0('0x1b3'),_0x4f42f0('0x101')+_0x185de1));if(_0x54cc1d<=0x0||isNaN(_0x54cc1d))return _0x4b2645(msgResponse(_0x4f42f0('0x2b'),_0x4f42f0('0x1b3'),_0x4f42f0('0x198')+_0x54cc1d));_0x5ef81c=_0x5ef81c||0x0;const _0x4f34ab=0x1/_0x5ef969;let _0x5652fe=0x0,_0xb894e8=0x0,_0x5d4c26=0x0,_0x3fcd2c=0x0,_0x171418=0x0;for(_0x171418=0x0;_0x3fcd2c<_0x54cc1d;_0x171418+=0x1){_0xb894e8=_0x171418/_0x185de1,_0x5652fe=(_0x2b9fcf*_0xb894e8+_0x5ef81c)/_0x4f34ab,_0x5d4c26=erlangb(_0x5652fe,_0xe4b369),_0x3fcd2c=_0x5652fe/_0xe4b369*(0x1-erlangb(_0x5652fe,_0xe4b369));}return _0x1cf646({'erlangCalls':_0x171418,'erlangCallToSecond':_0x185de1/_0x171418,'erlangAbandonmentRate':_0x5d4c26,'erlangBusyFactor':_0x3fcd2c});});},module[_0x369fc5('0x63')]=Dialer; \ No newline at end of file diff --git a/server/services/ami/dialer/queueCallerAbandon.js b/server/services/ami/dialer/queueCallerAbandon.js index ee033e8..1cad8ec 100644 --- a/server/services/ami/dialer/queueCallerAbandon.js +++ b/server/services/ami/dialer/queueCallerAbandon.js @@ -1 +1 @@ -const a1058_0x568e=['UserId','countnoanswerretry','countagentrejectretry','callbackuniqueid','responsetime','originatecalleridnum','ListId','milliseconds','scheduledat','membername','ringtime','number','holdtime','name','outbound','droptime','exports','countmachineretry','VoiceQueueId','countglobal','calleridnum','countbusyretry','seconds','countnosuchnumberretry','countabandonedretry','callbackat','countdropretry','ContactId','uniqueid','starttime','queue','countcongestionretry','recallme','originatecalleridname','campaigntype','type','moment','connectedlinename','CampaignId'];(function(_0x4f2c9b,_0x568e98){const _0x5124a3=function(_0x466250){while(--_0x466250){_0x4f2c9b['push'](_0x4f2c9b['shift']());}};_0x5124a3(++_0x568e98);}(a1058_0x568e,0x155));const a1058_0x5124=function(_0x4f2c9b,_0x568e98){_0x4f2c9b=_0x4f2c9b-0x0;let _0x5124a3=a1058_0x568e[_0x4f2c9b];return _0x5124a3;};const _0x385af7=a1058_0x5124;'use strict';const moment=require(_0x385af7('0x7'));function getSeconds(_0x466250,_0x5ead3a){const _0x5d1ef3=_0x385af7,_0x373f3e=moment(_0x466250)[_0x5d1ef3('0x11')](0x0),_0x4f3cbe=moment(_0x5ead3a)['milliseconds'](0x0);return _0x373f3e['diff'](_0x4f3cbe,_0x5d1ef3('0x20'));}function QueueCallerAbandon(_0x4b5b13,_0x2925d0){const _0x1a9f8e=_0x385af7;this[_0x1a9f8e('0x12')]=_0x4b5b13[_0x1a9f8e('0x12')],this['type']=_0x4b5b13['type'],this[_0x1a9f8e('0x5')]=_0x4b5b13['type']===_0x1a9f8e('0x18')?'queue':_0x4b5b13[_0x1a9f8e('0x6')],this[_0x1a9f8e('0x1f')]=_0x4b5b13[_0x1a9f8e('0x1f')],this['countcongestionretry']=_0x4b5b13[_0x1a9f8e('0x2')],this[_0x1a9f8e('0xb')]=_0x4b5b13[_0x1a9f8e('0xb')],this[_0x1a9f8e('0x1d')]=_0x4b5b13[_0x1a9f8e('0x1f')]+_0x4b5b13[_0x1a9f8e('0x2')]+_0x4b5b13[_0x1a9f8e('0xb')]+_0x4b5b13['countnosuchnumberretry']+_0x4b5b13[_0x1a9f8e('0x24')]+_0x4b5b13[_0x1a9f8e('0x22')]+_0x4b5b13['countmachineretry']+_0x4b5b13[_0x1a9f8e('0xc')],this[_0x1a9f8e('0x21')]=_0x4b5b13[_0x1a9f8e('0x21')],this[_0x1a9f8e('0x24')]=_0x4b5b13['countdropretry'],this['countabandonedretry']=_0x4b5b13[_0x1a9f8e('0x22')],this[_0x1a9f8e('0x1b')]=_0x4b5b13[_0x1a9f8e('0x1b')],this[_0x1a9f8e('0xc')]=_0x4b5b13[_0x1a9f8e('0xc')],this[_0x1a9f8e('0x26')]=_0x2925d0[_0x1a9f8e('0x26')],this['calleridname']=_0x4b5b13[_0x1a9f8e('0x17')],this[_0x1a9f8e('0x1e')]=_0x4b5b13[_0x1a9f8e('0x15')],this[_0x1a9f8e('0x0')]=_0x4b5b13['starttime'],this[_0x1a9f8e('0xe')]=_0x4b5b13['responsetime'],this[_0x1a9f8e('0x19')]=_0x4b5b13[_0x1a9f8e('0x19')],this['endtime']=this[_0x1a9f8e('0x19')],this[_0x1a9f8e('0x14')]=getSeconds(_0x4b5b13[_0x1a9f8e('0xe')],_0x4b5b13[_0x1a9f8e('0x0')]),this[_0x1a9f8e('0x16')]=getSeconds(this[_0x1a9f8e('0x19')],_0x4b5b13[_0x1a9f8e('0xe')]),this['talktime']=0x0,this['queue']=_0x2925d0[_0x1a9f8e('0x1')],this[_0x1a9f8e('0x13')]=_0x2925d0[_0x1a9f8e('0x8')],this['reason']=_0x2925d0['reason'],this['callback']=_0x4b5b13['callback'],this[_0x1a9f8e('0xd')]=_0x4b5b13[_0x1a9f8e('0xd')],this[_0x1a9f8e('0x23')]=_0x4b5b13[_0x1a9f8e('0x23')],this[_0x1a9f8e('0x3')]=_0x4b5b13[_0x1a9f8e('0x3')],this[_0x1a9f8e('0x25')]=_0x4b5b13[_0x1a9f8e('0x25')],this[_0x1a9f8e('0x10')]=_0x4b5b13[_0x1a9f8e('0x10')],this[_0x1a9f8e('0xa')]=_0x4b5b13[_0x1a9f8e('0xa')],this[_0x1a9f8e('0x1c')]=_0x4b5b13[_0x1a9f8e('0x1c')],this['CampaignId']=_0x4b5b13[_0x1a9f8e('0x9')],this[_0x1a9f8e('0xf')]=_0x4b5b13[_0x1a9f8e('0xf')]||'',this[_0x1a9f8e('0x4')]=_0x4b5b13[_0x1a9f8e('0x4')]||'';}module[_0x385af7('0x1a')]=QueueCallerAbandon; \ No newline at end of file +const a1058_0x57c7=['talktime','countdropretry','number','ListId','reason','ContactId','uniqueid','CampaignId','starttime','callback','callbackat','countnoanswerretry','countbusyretry','droptime','seconds','responsetime','calleridname','recallme','countmachineretry','milliseconds','originatecalleridname','callbackuniqueid','UserId','diff','countcongestionretry','countglobal','exports','queue','originatecalleridnum','type','outbound','connectedlinename','scheduledat','countagentrejectretry','countabandonedretry','holdtime','VoiceQueueId'];(function(_0x4e4714,_0x57c706){const _0x26d7dd=function(_0x242e39){while(--_0x242e39){_0x4e4714['push'](_0x4e4714['shift']());}};_0x26d7dd(++_0x57c706);}(a1058_0x57c7,0x154));const a1058_0x26d7=function(_0x4e4714,_0x57c706){_0x4e4714=_0x4e4714-0x0;let _0x26d7dd=a1058_0x57c7[_0x4e4714];return _0x26d7dd;};const _0xf78738=a1058_0x26d7;'use strict';const moment=require('moment');function getSeconds(_0x242e39,_0x5a2b64){const _0x260c28=a1058_0x26d7,_0x51e424=moment(_0x242e39)['milliseconds'](0x0),_0x18d75d=moment(_0x5a2b64)[_0x260c28('0xc')](0x0);return _0x51e424[_0x260c28('0x10')](_0x18d75d,_0x260c28('0x7'));}function QueueCallerAbandon(_0xef52fe,_0x2abd5c){const _0x31da97=a1058_0x26d7;this[_0x31da97('0x19')]=_0xef52fe['scheduledat'],this[_0x31da97('0x16')]=_0xef52fe['type'],this['campaigntype']=_0xef52fe['type']===_0x31da97('0x17')?_0x31da97('0x14'):_0xef52fe['type'],this['countbusyretry']=_0xef52fe[_0x31da97('0x5')],this['countcongestionretry']=_0xef52fe[_0x31da97('0x11')],this[_0x31da97('0x4')]=_0xef52fe['countnoanswerretry'],this[_0x31da97('0x12')]=_0xef52fe[_0x31da97('0x5')]+_0xef52fe[_0x31da97('0x11')]+_0xef52fe[_0x31da97('0x4')]+_0xef52fe['countnosuchnumberretry']+_0xef52fe[_0x31da97('0x1f')]+_0xef52fe[_0x31da97('0x1b')]+_0xef52fe[_0x31da97('0xb')]+_0xef52fe[_0x31da97('0x1a')],this['countnosuchnumberretry']=_0xef52fe['countnosuchnumberretry'],this[_0x31da97('0x1f')]=_0xef52fe['countdropretry'],this['countabandonedretry']=_0xef52fe[_0x31da97('0x1b')],this['countmachineretry']=_0xef52fe['countmachineretry'],this[_0x31da97('0x1a')]=_0xef52fe[_0x31da97('0x1a')],this['uniqueid']=_0x2abd5c[_0x31da97('0x24')],this[_0x31da97('0x9')]=_0xef52fe['name'],this['calleridnum']=_0xef52fe[_0x31da97('0x20')],this[_0x31da97('0x1')]=_0xef52fe[_0x31da97('0x1')],this['responsetime']=_0xef52fe[_0x31da97('0x8')],this[_0x31da97('0x6')]=_0xef52fe[_0x31da97('0x6')],this['endtime']=this[_0x31da97('0x6')],this['ringtime']=getSeconds(_0xef52fe[_0x31da97('0x8')],_0xef52fe['starttime']),this[_0x31da97('0x1c')]=getSeconds(this[_0x31da97('0x6')],_0xef52fe[_0x31da97('0x8')]),this[_0x31da97('0x1e')]=0x0,this['queue']=_0x2abd5c[_0x31da97('0x14')],this['membername']=_0x2abd5c[_0x31da97('0x18')],this[_0x31da97('0x22')]=_0x2abd5c['reason'],this[_0x31da97('0x2')]=_0xef52fe[_0x31da97('0x2')],this[_0x31da97('0xe')]=_0xef52fe['callbackuniqueid'],this[_0x31da97('0x3')]=_0xef52fe['callbackat'],this['recallme']=_0xef52fe[_0x31da97('0xa')],this['ContactId']=_0xef52fe[_0x31da97('0x23')],this[_0x31da97('0x21')]=_0xef52fe['ListId'],this[_0x31da97('0xf')]=_0xef52fe[_0x31da97('0xf')],this[_0x31da97('0x1d')]=_0xef52fe[_0x31da97('0x1d')],this[_0x31da97('0x0')]=_0xef52fe[_0x31da97('0x0')],this['originatecalleridnum']=_0xef52fe[_0x31da97('0x15')]||'',this['originatecalleridname']=_0xef52fe[_0x31da97('0xd')]||'';}module[_0xf78738('0x13')]=QueueCallerAbandon; \ No newline at end of file diff --git a/server/services/ami/fax/action.js b/server/services/ami/fax/action.js index adf46f3..d7f7913 100644 --- a/server/services/ami/fax/action.js +++ b/server/services/ami/fax/action.js @@ -1 +1 @@ -const a1059_0x4631=['uniqueid','localstationid','channel','exports','headerinfo','%s/%s/%s','path','AttachmentId','format','fax','util'];(function(_0x37c358,_0x46313c){const _0x434513=function(_0x5b87d5){while(--_0x5b87d5){_0x37c358['push'](_0x37c358['shift']());}};_0x434513(++_0x46313c);}(a1059_0x4631,0xbb));const a1059_0x4345=function(_0x37c358,_0x46313c){_0x37c358=_0x37c358-0x0;let _0x434513=a1059_0x4631[_0x37c358];return _0x434513;};const _0x254825=a1059_0x4345;'use strict';const util=require(_0x254825('0xa'));function Action(_0x5b87d5,_0x31e164,_0x4d5c8c){const _0x6586f2=_0x254825;this[_0x6586f2('0x0')]=_0x5b87d5||undefined,this[_0x6586f2('0x2')]=util[_0x6586f2('0x8')](_0x6586f2('0x5'),_0x31e164['tech'],_0x31e164['Trunk']['name'],_0x4d5c8c[_0x6586f2('0x9')]),this[_0x6586f2('0x1')]=_0x31e164['localstationid'],this['headerinfo']=_0x31e164[_0x6586f2('0x4')],this[_0x6586f2('0x6')]=_0x4d5c8c['path'],this['AttachmentId']=_0x4d5c8c[_0x6586f2('0x7')];}module[_0x254825('0x3')]=Action; \ No newline at end of file +const a1059_0x20fc=['util','channel','fax','%s/%s/%s','headerinfo','tech','AttachmentId','uniqueid','path','Trunk','localstationid','name'];(function(_0x1db9bd,_0x20fc76){const _0xebffc9=function(_0x2aac81){while(--_0x2aac81){_0x1db9bd['push'](_0x1db9bd['shift']());}};_0xebffc9(++_0x20fc76);}(a1059_0x20fc,0x13e));const a1059_0xebff=function(_0x1db9bd,_0x20fc76){_0x1db9bd=_0x1db9bd-0x0;let _0xebffc9=a1059_0x20fc[_0x1db9bd];return _0xebffc9;};const _0x496d8a=a1059_0xebff;'use strict';const util=require(_0x496d8a('0x6'));function Action(_0x2aac81,_0x461dd7,_0x4cd739){const _0x227abf=_0x496d8a;this[_0x227abf('0x1')]=_0x2aac81||undefined,this[_0x227abf('0x7')]=util['format'](_0x227abf('0x9'),_0x461dd7[_0x227abf('0xb')],_0x461dd7[_0x227abf('0x3')][_0x227abf('0x5')],_0x4cd739[_0x227abf('0x8')]),this[_0x227abf('0x4')]=_0x461dd7['localstationid'],this[_0x227abf('0xa')]=_0x461dd7[_0x227abf('0xa')],this[_0x227abf('0x2')]=_0x4cd739['path'],this['AttachmentId']=_0x4cd739[_0x227abf('0x0')];}module['exports']=Action; \ No newline at end of file diff --git a/server/services/ami/fax/index.js b/server/services/ami/fax/index.js index 8d6879f..3dac3e8 100644 --- a/server/services/ami/fax/index.js +++ b/server/services/ami/fax/index.js @@ -1 +1 @@ -const a1061_0x55d5=['%s/%s.tif','/var/opt/motion2/server/files/attachments/','pagestransferred','status','SENDING\x20FAILED','Is\x20Valid','active','Trunk\x20not\x20working','../../../config/logger','faxstatusstring','execute','./util/util','FaxAccountId','\x20syncNewchannel\x20','faxpages','isNil','trunks','[Fax][checkTrunk][Trunk\x20not\x20work]','reachable','syncNewchannel','Fax\x20failed','util','error','./action','[Fax][Message][Error][Updated]','SUCCESS','../rpc/faxAccount','AttachmentId','SIP/%s','stringify','calleridnum','bind','message','syncFaxStatus','syncOriginateResponse','faxstatus','[Fax][Message][Error][NoUpdate1]','path','ext','syncVarSet','\x20syncFaxStatus\x20','SENDING\x20FAILED\x20','[Fax][checkTrunk][Empty\x20Fax]','remotestationid','channelstatedesc','\x20notify\x20','syncNewExten','lodash','[Fax][execOriginate][failure]','send','XMF-PATH','name','catch','SENDING\x20FAILED:\x20','actions','format','[Fax][Message][Error][NoUpdate2]','update','pick','hangup','prototype','varset','[Fax][execOriginate][success]','exports','filename','[Fax][Message][Updated]','syncHangup','addVariables','gs\x20-q\x20-dNOPAUSE\x20-dBATCH\x20-sDEVICE=tiffg4\x20-sPAPERSIZE=letter\x20-sOutputFile=/var/opt/motion2/server/files/attachments/%s.tif\x20\x20%s\x20-c\x20quit','syncNewState','\x20receiveFax\x20','newstate','response','info','undefined','variable','fax','updateStatus','Action','Empty\x20Fax','originateresponse','Trunk\x20Reachable','newchannel','value','channelstate','Fax\x20received','finally','transferrate','Convert\x20pdf\x20to\x20tif','parse','resolution','checkTrunk','checkAfterSend','receivefax','isTrunkReachable','variablesAction','uniqueid','../rpc/faxMessage','[Fax][Message][NoUpdate2]','from-voip-provider','\x20hangup\x20faxRiceive\x20','faxAccounts','tiff2pdf','reason','channels','execOriginate','uuid','localstationid','dir','then','application/pdf','.pdf','channel','syncReceiveFax','logger','[Fax][checkTrunk][Empty\x20path]'];(function(_0x2df126,_0x55d5c9){const _0xdbd394=function(_0x3b185f){while(--_0x3b185f){_0x2df126['push'](_0x2df126['shift']());}};_0xdbd394(++_0x55d5c9);}(a1061_0x55d5,0xeb));const a1061_0xdbd3=function(_0x2df126,_0x55d5c9){_0x2df126=_0x2df126-0x0;let _0xdbd394=a1061_0x55d5[_0x2df126];return _0xdbd394;};const _0x5347e4=a1061_0xdbd3;'use strict';const util=require(_0x5347e4('0x12')),_=require(_0x5347e4('0x2c')),uuid=require(_0x5347e4('0x67')),path=require(_0x5347e4('0x22')),tiff2pdf=require(_0x5347e4('0x63')),gs=require('./util/gs'),logger=require(_0x5347e4('0x5'))(_0x5347e4('0x49')),ami=require('../ami'),ut=require(_0x5347e4('0x8')),Action=require(_0x5347e4('0x14')),faxAccount=require(_0x5347e4('0x17')),attachment=require('../rpc/attachment'),faxMessage=require(_0x5347e4('0x5e'));function Fax(_0x3b185f){const _0x981dab=_0x5347e4;this[_0x981dab('0x65')]={},this[_0x981dab('0x62')]=_0x3b185f[_0x981dab('0x62')],this[_0x981dab('0xd')]=_0x3b185f[_0x981dab('0xd')],this[_0x981dab('0x33')]={},ami['on'](_0x981dab('0x4f'),this[_0x981dab('0x10')][_0x981dab('0x1c')](this)),ami['on'](_0x981dab('0x3a'),this[_0x981dab('0x24')][_0x981dab('0x1c')](this)),ami['on'](_0x981dab('0x44'),this[_0x981dab('0x42')][_0x981dab('0x1c')](this)),ami['on']('newexten',this['syncNewExten'][_0x981dab('0x1c')](this)),ami['on'](_0x981dab('0x20'),this[_0x981dab('0x1e')][_0x981dab('0x1c')](this)),ami['on'](_0x981dab('0x5a'),this[_0x981dab('0x6e')]['bind'](this)),ami['on'](_0x981dab('0x38'),this[_0x981dab('0x3f')][_0x981dab('0x1c')](this)),ami['on'](_0x981dab('0x4d'),this['syncOriginateResponse']['bind'](this));}Fax['prototype'][_0x5347e4('0x10')]=function(_0x3342d7){const _0x5f2568=_0x5347e4;if(_0x3342d7['context']===_0x5f2568('0x60'))for(const _0x39e18b in this[_0x5f2568('0x62')]){typeof this['faxAccounts'][_0x39e18b]!==_0x5f2568('0x47')&&(_0x3342d7['exten']===this[_0x5f2568('0x62')][_0x39e18b]['localstationid']&&(this[_0x5f2568('0x65')][_0x3342d7[_0x5f2568('0x5d')]]={},this['channels'][_0x3342d7[_0x5f2568('0x5d')]]['channel']=_0x3342d7[_0x5f2568('0x6d')],this['channels'][_0x3342d7[_0x5f2568('0x5d')]]['id']=this['faxAccounts'][_0x39e18b]['id'],this[_0x5f2568('0x65')][_0x3342d7[_0x5f2568('0x5d')]][_0x5f2568('0x30')]=this[_0x5f2568('0x62')][_0x39e18b][_0x5f2568('0x30')],logger['info'](_0x3342d7[_0x5f2568('0x5d')],_0x5f2568('0xa'))));}this['actions'][_0x3342d7[_0x5f2568('0x5d')]]&&(this['channels'][_0x3342d7[_0x5f2568('0x5d')]]={},this[_0x5f2568('0x65')][_0x3342d7['uniqueid']]['channel']=_0x3342d7[_0x5f2568('0x6d')],logger['info'](_0x3342d7['uniqueid'],_0x5f2568('0xa')));},Fax[_0x5347e4('0x39')][_0x5347e4('0x24')]=function(_0x3e03cf){const _0x5e75b3=_0x5347e4;if(this[_0x5e75b3('0x65')][_0x3e03cf[_0x5e75b3('0x5d')]])for(const _0x926f07 in _0x3e03cf[_0x5e75b3('0x48')]){typeof _0x3e03cf[_0x5e75b3('0x48')][_0x926f07]!==_0x5e75b3('0x47')&&(this[_0x5e75b3('0x65')][_0x3e03cf[_0x5e75b3('0x5d')]][_0x926f07]=_0x3e03cf[_0x5e75b3('0x50')]);}},Fax[_0x5347e4('0x39')][_0x5347e4('0x42')]=function(_0x22dd6f){const _0x2de392=_0x5347e4;this[_0x2de392('0x65')][_0x22dd6f['uniqueid']]&&(this['channels'][_0x22dd6f[_0x2de392('0x5d')]][_0x2de392('0x51')]=_0x22dd6f[_0x2de392('0x51')],this[_0x2de392('0x65')][_0x22dd6f[_0x2de392('0x5d')]][_0x2de392('0x29')]=_0x22dd6f[_0x2de392('0x29')]);},Fax['prototype'][_0x5347e4('0x2b')]=function(_0x3137ce){const _0x1c2b2d=_0x5347e4;if(this[_0x1c2b2d('0x65')][_0x3137ce[_0x1c2b2d('0x5d')]])for(const _0x231279 in _0x3137ce[_0x1c2b2d('0x48')]){typeof _0x3137ce[_0x1c2b2d('0x48')][_0x231279]!==_0x1c2b2d('0x47')&&(this[_0x1c2b2d('0x65')][_0x3137ce[_0x1c2b2d('0x5d')]][_0x231279]=_0x3137ce[_0x1c2b2d('0x50')]);}},Fax[_0x5347e4('0x39')][_0x5347e4('0x1e')]=function(_0x598857){const _0x3fb6ba=_0x5347e4;this[_0x3fb6ba('0x65')][_0x598857['uniqueid']]&&(this['channels'][_0x598857[_0x3fb6ba('0x5d')]]['operation']=_0x598857['operation'],this['channels'][_0x598857['uniqueid']]['status']=_0x598857['status'],this[_0x3fb6ba('0x65')][_0x598857[_0x3fb6ba('0x5d')]]['localstationid']=_0x598857[_0x3fb6ba('0x68')],this[_0x3fb6ba('0x65')][_0x598857[_0x3fb6ba('0x5d')]][_0x3fb6ba('0x3d')]=_0x598857[_0x3fb6ba('0x3d')],logger['info'](_0x598857[_0x3fb6ba('0x5d')],_0x3fb6ba('0x25')));},Fax[_0x5347e4('0x39')]['syncReceiveFax']=function(_0x2f60bf){const _0x7399de=_0x5347e4;if(this[_0x7399de('0x65')][_0x2f60bf[_0x7399de('0x5d')]]){const _0xd91498=this['channels'][_0x2f60bf['uniqueid']]['id'];this[_0x7399de('0x65')][_0x2f60bf[_0x7399de('0x5d')]][_0x7399de('0x28')]=_0x2f60bf['remotestationid'],this[_0x7399de('0x65')][_0x2f60bf[_0x7399de('0x5d')]][_0x7399de('0x73')]=_0x2f60bf[_0x7399de('0x73')],this[_0x7399de('0x65')][_0x2f60bf['uniqueid']][_0x7399de('0x68')]=_0x2f60bf[_0x7399de('0x68')],this[_0x7399de('0x65')][_0x2f60bf['uniqueid']][_0x7399de('0x57')]=_0x2f60bf['resolution'],this[_0x7399de('0x65')][_0x2f60bf[_0x7399de('0x5d')]][_0x7399de('0x54')]=_0x2f60bf[_0x7399de('0x54')],this[_0x7399de('0x65')][_0x2f60bf[_0x7399de('0x5d')]][_0x7399de('0x3d')]=_0x2f60bf[_0x7399de('0x3d')],this[_0x7399de('0x65')][_0x2f60bf['uniqueid']]['calleridnum']=_0x2f60bf['calleridnum'],this['channels'][_0x2f60bf[_0x7399de('0x5d')]][_0x7399de('0x73')]>0x0&&tiff2pdf(_0x2f60bf['filename'],_0x7399de('0x72'),function(_0xe2e6da){const _0x5065f0=_0x7399de;logger['info'](_0x2f60bf[_0x5065f0('0x5d')],'\x20result\x20conversion\x20file\x20',_0xe2e6da[_0x5065f0('0x1d')]),attachment['create']({'name':path[_0x5065f0('0x56')](_0x2f60bf[_0x5065f0('0x3d')])[_0x5065f0('0x30')],'basename':path['parse'](_0x2f60bf['filename'])[_0x5065f0('0x30')]+_0x5065f0('0x6c'),'type':_0x5065f0('0x6b')})[_0x5065f0('0x6a')](function(_0x3cfa36){const _0x7535b7=_0x5065f0;faxAccount['notify'](_0xd91498,{'from':_0x2f60bf[_0x7535b7('0x1b')],'mapKey':'fax','body':path['parse'](_0x2f60bf[_0x7535b7('0x3d')])[_0x7535b7('0x30')]+_0x7535b7('0x6c'),'AttachmentId':_0x3cfa36['id']})['catch'](function(_0x33f23d){const _0x348105=_0x7535b7;logger[_0x348105('0x13')](_0x2f60bf[_0x348105('0x5d')],_0x348105('0x2a'),JSON['stringify'](_0x33f23d));});})['catch'](function(_0x4bfb81){const _0x1be812=_0x5065f0;logger[_0x1be812('0x13')](_0x2f60bf[_0x1be812('0x5d')],'\x20receiveFax\x20',JSON[_0x1be812('0x1a')](_0x4bfb81));});}),logger['info'](_0x2f60bf['uniqueid'],_0x7399de('0x43'));}},Fax[_0x5347e4('0x39')][_0x5347e4('0x1f')]=function(_0x10697b){const _0x5d2cd7=_0x5347e4;this['actions'][_0x10697b[_0x5d2cd7('0x5d')]]&&_['merge'](this['channels'][_0x10697b['uniqueid']],_[_0x5d2cd7('0x37')](_0x10697b,[_0x5d2cd7('0x45'),_0x5d2cd7('0x64')]));};function updateStatus(_0x5688b6){const _0x50d426=_0x5347e4;_0x5688b6[_0x50d426('0x18')]?faxMessage[_0x50d426('0x36')](_0x5688b6[_0x50d426('0x18')],{'failMessage':_0x50d426('0x26')})[_0x50d426('0x6a')](function(_0x589f15){const _0x574dde=_0x50d426;ut[_0x574dde('0x6f')](_0x574dde('0x15'),_0x589f15);})[_0x50d426('0x31')](function(_0x227040){const _0x4bdbb2=_0x50d426;ut[_0x4bdbb2('0x6f')](_0x4bdbb2('0x21'),_0x227040);}):ut[_0x50d426('0x6f')](_0x50d426('0x35'));}Fax[_0x5347e4('0x39')]['updateStatus']=function(_0x157735,_0x8b9bde,_0x4315f3){const _0x265451=_0x5347e4,_0x4f4d4a=this;let _0x16e89e={};_0x8b9bde?_0x16e89e={'read':_0x8b9bde}:_0x16e89e={'failMessage':_0x4315f3},this[_0x265451('0x33')][_0x157735][_0x265451('0x18')]?faxMessage[_0x265451('0x36')](this['actions'][_0x157735][_0x265451('0x18')],_0x16e89e)[_0x265451('0x6a')](function(_0x4b702e){const _0x3f0e51=_0x265451;ut[_0x3f0e51('0x6f')](_0x3f0e51('0x3e'),_0x4b702e);})[_0x265451('0x31')](function(_0x2212b2){const _0x51a4db=_0x265451;ut[_0x51a4db('0x6f')]('[Fax][Message][NoUpdate1]',_0x2212b2);})[_0x265451('0x53')](function(){const _0x1fd862=_0x265451;delete _0x4f4d4a['channels'][_0x157735],delete _0x4f4d4a[_0x1fd862('0x33')][_0x157735];}):(ut[_0x265451('0x6f')](_0x265451('0x5f')),delete this[_0x265451('0x65')][_0x157735],delete this[_0x265451('0x33')][_0x157735]);},Fax['prototype'][_0x5347e4('0x3f')]=function(_0x56e15f){const _0x226b00=_0x5347e4;this[_0x226b00('0x65')][_0x56e15f[_0x226b00('0x5d')]]&&(this[_0x226b00('0x33')][_0x56e15f[_0x226b00('0x5d')]]&&(this[_0x226b00('0x65')][_0x56e15f[_0x226b00('0x5d')]]['id']=this[_0x226b00('0x33')][_0x56e15f[_0x226b00('0x5d')]]['id'],this[_0x226b00('0x65')][_0x56e15f[_0x226b00('0x5d')]]['name']=this[_0x226b00('0x33')][_0x56e15f[_0x226b00('0x5d')]][_0x226b00('0x30')]),logger[_0x226b00('0x46')](_0x56e15f['uniqueid'],this[_0x226b00('0x33')][_0x56e15f[_0x226b00('0x5d')]]?'\x20hangup\x20sendFile\x20':_0x226b00('0x61'),JSON[_0x226b00('0x1a')](this[_0x226b00('0x65')][_0x56e15f[_0x226b00('0x5d')]])),this[_0x226b00('0x33')][_0x56e15f[_0x226b00('0x5d')]]&&(this[_0x226b00('0x65')][_0x56e15f[_0x226b00('0x5d')]][_0x226b00('0xb')]>0x0&&this[_0x226b00('0x65')][_0x56e15f[_0x226b00('0x5d')]]['faxstatus']===_0x226b00('0x16')?this['updateStatus'](_0x56e15f[_0x226b00('0x5d')],!![]):this[_0x226b00('0x4a')](_0x56e15f[_0x226b00('0x5d')],![],this['channels'][_0x56e15f[_0x226b00('0x5d')]][_0x226b00('0x6')]?_0x226b00('0x32')+this[_0x226b00('0x65')][_0x56e15f[_0x226b00('0x5d')]][_0x226b00('0x6')]:_0x226b00('0x1'))));},Fax['prototype'][_0x5347e4('0x2e')]=function(_0x8c08ed){const _0x143494=this;return new Promise(function(_0x106bb1,_0x4d06df){const _0x449f95=a1061_0xdbd3;_0x143494[_0x449f95('0x66')](_0x8c08ed,_0x143494['faxAccounts'][_0x8c08ed[_0x449f95('0x9')]])['then'](function(_0x3e90c7){const _0x4ff590=_0x449f95;ut[_0x4ff590('0x6f')](_0x4ff590('0x3b'),_0x3e90c7),_0x106bb1(ut['message'](_0x4ff590('0x52')));})[_0x449f95('0x31')](function(_0x39c8b6){const _0xb043e5=_0x449f95;ut[_0xb043e5('0x6f')](_0xb043e5('0x2d'),_0x39c8b6),updateStatus(_0x8c08ed),_0x4d06df(ut['message'](_0xb043e5('0x11')));});});},Fax[_0x5347e4('0x39')][_0x5347e4('0x59')]=function(_0x1d0aec){const _0x188cee=this;return new Promise(function(_0x26e31f,_0x33fd76){const _0x3cd7a6=a1061_0xdbd3,_0x26f5f0=_0x188cee[_0x3cd7a6('0x58')](_0x188cee[_0x3cd7a6('0x62')][_0x1d0aec[_0x3cd7a6('0x9')]]['Trunk'],_0x1d0aec);_0x26f5f0['isValid']?_0x26e31f(ut[_0x3cd7a6('0x1d')](_0x3cd7a6('0x4e'))):_0x33fd76(ut[_0x3cd7a6('0x1d')](_0x26f5f0[_0x3cd7a6('0x1d')]));});};function originate(_0x21c7e4,_0xe08d5c,_0x591165){return new Promise(function(_0x4c8c39,_0x486e31){const _0x2f350e=a1061_0xdbd3;if(_0x591165){const _0x1780f6=util[_0x2f350e('0x34')](_0x2f350e('0x41'),path[_0x2f350e('0x56')](_0x21c7e4['path'])[_0x2f350e('0x30')],_0x21c7e4['path']);gs[_0x2f350e('0x7')](_0x1780f6)[_0x2f350e('0x6a')](function(){const _0xcb939e=_0x2f350e;_0x21c7e4[_0xcb939e('0x22')]=util['format'](_0xcb939e('0x71'),path['parse'](_0x21c7e4[_0xcb939e('0x22')])[_0xcb939e('0x69')],path[_0xcb939e('0x56')](_0x21c7e4[_0xcb939e('0x22')])['name']),_0xe08d5c[_0xcb939e('0x2f')]=_0x21c7e4[_0xcb939e('0x22')],ut[_0xcb939e('0x6f')](_0xcb939e('0x55'),''),ami[_0xcb939e('0x4b')](ut[_0xcb939e('0x5c')](_0x21c7e4,_0xe08d5c))['then'](function(_0x52ba1d){_0x4c8c39(_0x52ba1d);})[_0xcb939e('0x31')](function(_0x2186b4){_0x486e31(_0x2186b4);});})['catch'](function(_0x4c976c){_0x486e31(_0x4c976c);});}else ami['Action'](ut[_0x2f350e('0x5c')](_0x21c7e4,_0xe08d5c))[_0x2f350e('0x6a')](function(_0x34390c){_0x4c8c39(_0x34390c);})['catch'](function(_0x5ba211){_0x486e31(_0x5ba211);});});}Fax['prototype'][_0x5347e4('0x66')]=function(_0x6f5bed,_0x35325a){const _0x39eb5c=this;return new Promise(function(_0x319f17,_0x52de89){const _0x3c8446=a1061_0xdbd3,_0x301b97=uuid['v4'](),_0x2e191b=ut[_0x3c8446('0x40')](_0x6f5bed,_0x35325a);_0x39eb5c[_0x3c8446('0x33')][_0x301b97]=new Action(_0x301b97,_0x35325a,_0x6f5bed);const _0x3aac16=_0x39eb5c[_0x3c8446('0x33')][_0x301b97];path[_0x3c8446('0x56')](_0x6f5bed[_0x3c8446('0x22')])[_0x3c8446('0x23')]===_0x3c8446('0x6c')?originate(_0x3aac16,_0x2e191b,!![])[_0x3c8446('0x6a')](function(_0x1a4f6f){_0x319f17(_0x1a4f6f);})['catch'](function(_0x1a8b11){_0x52de89(_0x1a8b11);}):originate(_0x3aac16,_0x2e191b,![])[_0x3c8446('0x6a')](function(_0x5be017){_0x319f17(_0x5be017);})[_0x3c8446('0x31')](function(_0x23a018){_0x52de89(_0x23a018);});});},Fax[_0x5347e4('0x39')][_0x5347e4('0x5b')]=function(_0x39addd){const _0x2002e1=_0x5347e4;return!_[_0x2002e1('0xc')](_0x39addd)&&!_[_0x2002e1('0xc')](_0x39addd['name'])&&!_[_0x2002e1('0xc')](_0x39addd['active'])&&_0x39addd[_0x2002e1('0x3')]&&!_[_0x2002e1('0xc')](this[_0x2002e1('0xd')][util[_0x2002e1('0x34')](_0x2002e1('0x19'),_0x39addd[_0x2002e1('0x30')])])&&!_[_0x2002e1('0xc')](this[_0x2002e1('0xd')][util[_0x2002e1('0x34')](_0x2002e1('0x19'),_0x39addd['name'])][_0x2002e1('0x0')])&&(this[_0x2002e1('0xd')][util[_0x2002e1('0x34')](_0x2002e1('0x19'),_0x39addd[_0x2002e1('0x30')])][_0x2002e1('0x0')]===_0x2002e1('0xf')||this[_0x2002e1('0xd')][util[_0x2002e1('0x34')](_0x2002e1('0x19'),_0x39addd[_0x2002e1('0x30')])][_0x2002e1('0x0')]==='unmonitored');},Fax[_0x5347e4('0x39')][_0x5347e4('0x58')]=function(_0x58772f,_0x1d6c28){const _0x20eb58=_0x5347e4;if(!this['isTrunkReachable'](_0x58772f))return ut['logger'](_0x20eb58('0xe'),_[_0x20eb58('0xc')](_0x58772f)?'':_0x58772f['name']+'\x20Trunk\x20is\x20not\x20active'),{'isValid':![],'message':_0x20eb58('0x4')};if(_[_0x20eb58('0xc')](_0x1d6c28[_0x20eb58('0x49')]))return ut[_0x20eb58('0x6f')](_0x20eb58('0x27'),JSON[_0x20eb58('0x1a')](_0x1d6c28)),{'isValid':![],'message':_0x20eb58('0x4c')};if(_[_0x20eb58('0xc')](_0x1d6c28[_0x20eb58('0x22')]))return ut[_0x20eb58('0x6f')](_0x20eb58('0x70'),JSON[_0x20eb58('0x1a')](_0x1d6c28)),{'isValid':![],'message':'Empty\x20path'};return{'isValid':!![],'message':_0x20eb58('0x2')};},module[_0x5347e4('0x3c')]=Fax; \ No newline at end of file +const a1061_0xf3da=['stringify','format','receivefax','SENDING\x20FAILED','originateresponse','[Fax][Message][NoUpdate2]','SUCCESS','calleridnum','unmonitored','Fax\x20received','bind','execOriginate','checkTrunk','./action','notify','faxstatus','response','syncNewExten','channels','info','syncVarSet','uniqueid','logger','[Fax][checkTrunk][Empty\x20path]','channelstate','\x20receiveFax\x20','lodash','create','update','tiff2pdf','remotestationid','\x20syncNewchannel\x20','variable','updateStatus','syncFaxStatus','faxAccounts','[Fax][checkTrunk][Empty\x20Fax]','[Fax][execOriginate][failure]','../../../config/logger','faxpages','syncReceiveFax','syncHangup','\x20result\x20conversion\x20file\x20','then','parse','syncNewState','pick','exten','\x20Trunk\x20is\x20not\x20active','path','[Fax][Message][Error][NoUpdate1]','newexten','name','[Fax][checkTrunk][Trunk\x20not\x20work]','transferrate','prototype','finally','.pdf','util','SIP/%s','catch','syncOriginateResponse','fax','../rpc/attachment','active','message','[Fax][Message][Error][NoUpdate2]','faxstatusstring','Empty\x20Fax','dir','[Fax][Message][Error][Updated]','AttachmentId','syncNewchannel','XMF-PATH','FaxAccountId','channel','isTrunkReachable','SENDING\x20FAILED\x20','localstationid','actions','resolution','isNil','../rpc/faxAccount','isValid','/var/opt/motion2/server/files/attachments/','newstate','checkAfterSend','Action','Is\x20Valid','value','channelstatedesc','error','uuid','status','application/pdf','gs\x20-q\x20-dNOPAUSE\x20-dBATCH\x20-sDEVICE=tiffg4\x20-sPAPERSIZE=letter\x20-sOutputFile=/var/opt/motion2/server/files/attachments/%s.tif\x20\x20%s\x20-c\x20quit','Trunk','trunks','operation','merge','undefined','filename','varset','context','variablesAction','./util/util','[Fax][execOriginate][success]'];(function(_0x20b836,_0xf3da9a){const _0x1660e8=function(_0x34ba82){while(--_0x34ba82){_0x20b836['push'](_0x20b836['shift']());}};_0x1660e8(++_0xf3da9a);}(a1061_0xf3da,0xa6));const a1061_0x1660=function(_0x20b836,_0xf3da9a){_0x20b836=_0x20b836-0x0;let _0x1660e8=a1061_0xf3da[_0x20b836];return _0x1660e8;};const _0x58d20d=a1061_0x1660;'use strict';const util=require(_0x58d20d('0x6a')),_=require(_0x58d20d('0x4a')),uuid=require(_0x58d20d('0x21')),path=require(_0x58d20d('0x61')),tiff2pdf=require(_0x58d20d('0x4d')),gs=require('./util/gs'),logger=require(_0x58d20d('0x56'))(_0x58d20d('0x3')),ami=require('../ami'),ut=require(_0x58d20d('0x2e')),Action=require(_0x58d20d('0x3d')),faxAccount=require(_0x58d20d('0x17')),attachment=require(_0x58d20d('0x4')),faxMessage=require('../rpc/faxMessage');function Fax(_0x34ba82){const _0x5de9e6=_0x58d20d;this[_0x5de9e6('0x42')]={},this[_0x5de9e6('0x53')]=_0x34ba82[_0x5de9e6('0x53')],this[_0x5de9e6('0x26')]=_0x34ba82['trunks'],this[_0x5de9e6('0x14')]={},ami['on']('newchannel',this[_0x5de9e6('0xd')]['bind'](this)),ami['on'](_0x5de9e6('0x2b'),this[_0x5de9e6('0x44')][_0x5de9e6('0x3a')](this)),ami['on'](_0x5de9e6('0x1a'),this[_0x5de9e6('0x5d')][_0x5de9e6('0x3a')](this)),ami['on'](_0x5de9e6('0x63'),this[_0x5de9e6('0x41')][_0x5de9e6('0x3a')](this)),ami['on'](_0x5de9e6('0x3f'),this['syncFaxStatus'][_0x5de9e6('0x3a')](this)),ami['on'](_0x5de9e6('0x32'),this[_0x5de9e6('0x58')][_0x5de9e6('0x3a')](this)),ami['on']('hangup',this[_0x5de9e6('0x59')]['bind'](this)),ami['on'](_0x5de9e6('0x34'),this[_0x5de9e6('0x2')]['bind'](this));}Fax[_0x58d20d('0x67')][_0x58d20d('0xd')]=function(_0x1f3ef9){const _0x4b09a0=_0x58d20d;if(_0x1f3ef9[_0x4b09a0('0x2c')]==='from-voip-provider')for(const _0x8aab31 in this[_0x4b09a0('0x53')]){typeof this[_0x4b09a0('0x53')][_0x8aab31]!==_0x4b09a0('0x29')&&(_0x1f3ef9[_0x4b09a0('0x5f')]===this[_0x4b09a0('0x53')][_0x8aab31][_0x4b09a0('0x13')]&&(this[_0x4b09a0('0x42')][_0x1f3ef9[_0x4b09a0('0x45')]]={},this['channels'][_0x1f3ef9[_0x4b09a0('0x45')]][_0x4b09a0('0x10')]=_0x1f3ef9['channel'],this['channels'][_0x1f3ef9[_0x4b09a0('0x45')]]['id']=this[_0x4b09a0('0x53')][_0x8aab31]['id'],this[_0x4b09a0('0x42')][_0x1f3ef9[_0x4b09a0('0x45')]][_0x4b09a0('0x64')]=this[_0x4b09a0('0x53')][_0x8aab31]['name'],logger[_0x4b09a0('0x43')](_0x1f3ef9['uniqueid'],'\x20syncNewchannel\x20')));}this[_0x4b09a0('0x14')][_0x1f3ef9[_0x4b09a0('0x45')]]&&(this['channels'][_0x1f3ef9[_0x4b09a0('0x45')]]={},this['channels'][_0x1f3ef9[_0x4b09a0('0x45')]]['channel']=_0x1f3ef9[_0x4b09a0('0x10')],logger[_0x4b09a0('0x43')](_0x1f3ef9['uniqueid'],_0x4b09a0('0x4f')));},Fax[_0x58d20d('0x67')][_0x58d20d('0x44')]=function(_0x1e4810){const _0x3f7227=_0x58d20d;if(this[_0x3f7227('0x42')][_0x1e4810[_0x3f7227('0x45')]])for(const _0x1250f9 in _0x1e4810[_0x3f7227('0x50')]){typeof _0x1e4810[_0x3f7227('0x50')][_0x1250f9]!==_0x3f7227('0x29')&&(this[_0x3f7227('0x42')][_0x1e4810[_0x3f7227('0x45')]][_0x1250f9]=_0x1e4810['value']);}},Fax[_0x58d20d('0x67')]['syncNewState']=function(_0x23a8d7){const _0xf3782=_0x58d20d;this[_0xf3782('0x42')][_0x23a8d7[_0xf3782('0x45')]]&&(this[_0xf3782('0x42')][_0x23a8d7['uniqueid']][_0xf3782('0x48')]=_0x23a8d7['channelstate'],this[_0xf3782('0x42')][_0x23a8d7[_0xf3782('0x45')]]['channelstatedesc']=_0x23a8d7[_0xf3782('0x1f')]);},Fax[_0x58d20d('0x67')][_0x58d20d('0x41')]=function(_0x234428){const _0x33d520=_0x58d20d;if(this[_0x33d520('0x42')][_0x234428['uniqueid']])for(const _0x35f1d3 in _0x234428[_0x33d520('0x50')]){typeof _0x234428[_0x33d520('0x50')][_0x35f1d3]!==_0x33d520('0x29')&&(this['channels'][_0x234428[_0x33d520('0x45')]][_0x35f1d3]=_0x234428[_0x33d520('0x1e')]);}},Fax[_0x58d20d('0x67')][_0x58d20d('0x52')]=function(_0xddf252){const _0x3c55a0=_0x58d20d;this[_0x3c55a0('0x42')][_0xddf252[_0x3c55a0('0x45')]]&&(this['channels'][_0xddf252[_0x3c55a0('0x45')]][_0x3c55a0('0x27')]=_0xddf252['operation'],this['channels'][_0xddf252[_0x3c55a0('0x45')]]['status']=_0xddf252[_0x3c55a0('0x22')],this['channels'][_0xddf252[_0x3c55a0('0x45')]][_0x3c55a0('0x13')]=_0xddf252[_0x3c55a0('0x13')],this[_0x3c55a0('0x42')][_0xddf252['uniqueid']][_0x3c55a0('0x2a')]=_0xddf252['filename'],logger['info'](_0xddf252['uniqueid'],'\x20syncFaxStatus\x20'));},Fax['prototype'][_0x58d20d('0x58')]=function(_0x4a0e2f){const _0x3b9916=_0x58d20d;if(this[_0x3b9916('0x42')][_0x4a0e2f['uniqueid']]){const _0x4a8f72=this[_0x3b9916('0x42')][_0x4a0e2f[_0x3b9916('0x45')]]['id'];this[_0x3b9916('0x42')][_0x4a0e2f[_0x3b9916('0x45')]]['remotestationid']=_0x4a0e2f[_0x3b9916('0x4e')],this[_0x3b9916('0x42')][_0x4a0e2f[_0x3b9916('0x45')]]['pagestransferred']=_0x4a0e2f['pagestransferred'],this[_0x3b9916('0x42')][_0x4a0e2f['uniqueid']][_0x3b9916('0x13')]=_0x4a0e2f[_0x3b9916('0x13')],this[_0x3b9916('0x42')][_0x4a0e2f['uniqueid']][_0x3b9916('0x15')]=_0x4a0e2f[_0x3b9916('0x15')],this['channels'][_0x4a0e2f[_0x3b9916('0x45')]][_0x3b9916('0x66')]=_0x4a0e2f[_0x3b9916('0x66')],this[_0x3b9916('0x42')][_0x4a0e2f[_0x3b9916('0x45')]]['filename']=_0x4a0e2f['filename'],this['channels'][_0x4a0e2f['uniqueid']][_0x3b9916('0x37')]=_0x4a0e2f[_0x3b9916('0x37')],this[_0x3b9916('0x42')][_0x4a0e2f[_0x3b9916('0x45')]]['pagestransferred']>0x0&&tiff2pdf(_0x4a0e2f['filename'],_0x3b9916('0x19'),function(_0x241a6d){const _0x573f86=_0x3b9916;logger[_0x573f86('0x43')](_0x4a0e2f[_0x573f86('0x45')],_0x573f86('0x5a'),_0x241a6d[_0x573f86('0x6')]),attachment[_0x573f86('0x4b')]({'name':path[_0x573f86('0x5c')](_0x4a0e2f[_0x573f86('0x2a')])['name'],'basename':path[_0x573f86('0x5c')](_0x4a0e2f[_0x573f86('0x2a')])[_0x573f86('0x64')]+_0x573f86('0x69'),'type':_0x573f86('0x23')})[_0x573f86('0x5b')](function(_0x20b212){const _0x2ebb82=_0x573f86;faxAccount[_0x2ebb82('0x3e')](_0x4a8f72,{'from':_0x4a0e2f[_0x2ebb82('0x37')],'mapKey':_0x2ebb82('0x3'),'body':path[_0x2ebb82('0x5c')](_0x4a0e2f['filename'])[_0x2ebb82('0x64')]+_0x2ebb82('0x69'),'AttachmentId':_0x20b212['id']})[_0x2ebb82('0x1')](function(_0x2ccf10){logger['error'](_0x4a0e2f['uniqueid'],'\x20notify\x20',JSON['stringify'](_0x2ccf10));});})['catch'](function(_0x14093e){const _0x16f0be=_0x573f86;logger[_0x16f0be('0x20')](_0x4a0e2f['uniqueid'],_0x16f0be('0x49'),JSON[_0x16f0be('0x30')](_0x14093e));});}),logger[_0x3b9916('0x43')](_0x4a0e2f[_0x3b9916('0x45')],_0x3b9916('0x49'));}},Fax[_0x58d20d('0x67')][_0x58d20d('0x2')]=function(_0x293c9c){const _0x5b72f4=_0x58d20d;this[_0x5b72f4('0x14')][_0x293c9c[_0x5b72f4('0x45')]]&&_[_0x5b72f4('0x28')](this[_0x5b72f4('0x42')][_0x293c9c['uniqueid']],_[_0x5b72f4('0x5e')](_0x293c9c,[_0x5b72f4('0x40'),'reason']));};function updateStatus(_0x2e589e){const _0x1edf29=_0x58d20d;_0x2e589e[_0x1edf29('0xc')]?faxMessage[_0x1edf29('0x4c')](_0x2e589e['AttachmentId'],{'failMessage':_0x1edf29('0x12')})['then'](function(_0x4f289c){const _0x4cce33=_0x1edf29;ut[_0x4cce33('0x46')](_0x4cce33('0xb'),_0x4f289c);})[_0x1edf29('0x1')](function(_0x5474b9){const _0x2b8c27=_0x1edf29;ut['logger'](_0x2b8c27('0x62'),_0x5474b9);}):ut[_0x1edf29('0x46')](_0x1edf29('0x7'));}Fax[_0x58d20d('0x67')]['updateStatus']=function(_0x4f7fa2,_0x10bd9d,_0x6b58ff){const _0x496ad2=_0x58d20d,_0x48454a=this;let _0x6ed0fe={};_0x10bd9d?_0x6ed0fe={'read':_0x10bd9d}:_0x6ed0fe={'failMessage':_0x6b58ff},this[_0x496ad2('0x14')][_0x4f7fa2][_0x496ad2('0xc')]?faxMessage['update'](this[_0x496ad2('0x14')][_0x4f7fa2][_0x496ad2('0xc')],_0x6ed0fe)[_0x496ad2('0x5b')](function(_0x2c4867){const _0x2634ec=_0x496ad2;ut[_0x2634ec('0x46')]('[Fax][Message][Updated]',_0x2c4867);})['catch'](function(_0x39894e){const _0x2d57a6=_0x496ad2;ut[_0x2d57a6('0x46')]('[Fax][Message][NoUpdate1]',_0x39894e);})[_0x496ad2('0x68')](function(){const _0xf46489=_0x496ad2;delete _0x48454a[_0xf46489('0x42')][_0x4f7fa2],delete _0x48454a[_0xf46489('0x14')][_0x4f7fa2];}):(ut['logger'](_0x496ad2('0x35')),delete this[_0x496ad2('0x42')][_0x4f7fa2],delete this['actions'][_0x4f7fa2]);},Fax[_0x58d20d('0x67')]['syncHangup']=function(_0x296800){const _0x532704=_0x58d20d;this[_0x532704('0x42')][_0x296800[_0x532704('0x45')]]&&(this[_0x532704('0x14')][_0x296800['uniqueid']]&&(this['channels'][_0x296800['uniqueid']]['id']=this[_0x532704('0x14')][_0x296800[_0x532704('0x45')]]['id'],this[_0x532704('0x42')][_0x296800[_0x532704('0x45')]][_0x532704('0x64')]=this[_0x532704('0x14')][_0x296800[_0x532704('0x45')]]['name']),logger[_0x532704('0x43')](_0x296800[_0x532704('0x45')],this[_0x532704('0x14')][_0x296800[_0x532704('0x45')]]?'\x20hangup\x20sendFile\x20':'\x20hangup\x20faxRiceive\x20',JSON[_0x532704('0x30')](this['channels'][_0x296800[_0x532704('0x45')]])),this[_0x532704('0x14')][_0x296800[_0x532704('0x45')]]&&(this['channels'][_0x296800[_0x532704('0x45')]][_0x532704('0x57')]>0x0&&this[_0x532704('0x42')][_0x296800[_0x532704('0x45')]][_0x532704('0x3f')]===_0x532704('0x36')?this[_0x532704('0x51')](_0x296800[_0x532704('0x45')],!![]):this[_0x532704('0x51')](_0x296800[_0x532704('0x45')],![],this[_0x532704('0x42')][_0x296800[_0x532704('0x45')]][_0x532704('0x8')]?'SENDING\x20FAILED:\x20'+this['channels'][_0x296800['uniqueid']]['faxstatusstring']:_0x532704('0x33'))));},Fax[_0x58d20d('0x67')]['send']=function(_0x2b4e76){const _0x1568c2=this;return new Promise(function(_0x1ec46e,_0x5233eb){const _0x2b0910=a1061_0x1660;_0x1568c2[_0x2b0910('0x3b')](_0x2b4e76,_0x1568c2[_0x2b0910('0x53')][_0x2b4e76[_0x2b0910('0xf')]])[_0x2b0910('0x5b')](function(_0x2f5cd1){const _0x209d05=_0x2b0910;ut[_0x209d05('0x46')](_0x209d05('0x2f'),_0x2f5cd1),_0x1ec46e(ut[_0x209d05('0x6')](_0x209d05('0x39')));})[_0x2b0910('0x1')](function(_0x45696e){const _0x3f4108=_0x2b0910;ut[_0x3f4108('0x46')](_0x3f4108('0x55'),_0x45696e),updateStatus(_0x2b4e76),_0x5233eb(ut[_0x3f4108('0x6')]('Fax\x20failed'));});});},Fax['prototype'][_0x58d20d('0x1b')]=function(_0x288c92){const _0x146d52=this;return new Promise(function(_0x338790,_0x3fea6c){const _0x2189b3=a1061_0x1660,_0x3e9bab=_0x146d52[_0x2189b3('0x3c')](_0x146d52[_0x2189b3('0x53')][_0x288c92['FaxAccountId']][_0x2189b3('0x25')],_0x288c92);_0x3e9bab[_0x2189b3('0x18')]?_0x338790(ut[_0x2189b3('0x6')]('Trunk\x20Reachable')):_0x3fea6c(ut[_0x2189b3('0x6')](_0x3e9bab[_0x2189b3('0x6')]));});};function originate(_0x1845cc,_0x354517,_0x57b8d1){return new Promise(function(_0x5cdd62,_0x24a84){const _0x2ac8e0=a1061_0x1660;if(_0x57b8d1){const _0x4c1c9b=util[_0x2ac8e0('0x31')](_0x2ac8e0('0x24'),path[_0x2ac8e0('0x5c')](_0x1845cc['path'])[_0x2ac8e0('0x64')],_0x1845cc[_0x2ac8e0('0x61')]);gs['execute'](_0x4c1c9b)[_0x2ac8e0('0x5b')](function(){const _0x10e45d=_0x2ac8e0;_0x1845cc[_0x10e45d('0x61')]=util[_0x10e45d('0x31')]('%s/%s.tif',path[_0x10e45d('0x5c')](_0x1845cc['path'])[_0x10e45d('0xa')],path['parse'](_0x1845cc[_0x10e45d('0x61')])[_0x10e45d('0x64')]),_0x354517[_0x10e45d('0xe')]=_0x1845cc['path'],ut[_0x10e45d('0x46')]('Convert\x20pdf\x20to\x20tif',''),ami[_0x10e45d('0x1c')](ut[_0x10e45d('0x2d')](_0x1845cc,_0x354517))[_0x10e45d('0x5b')](function(_0x49e890){_0x5cdd62(_0x49e890);})[_0x10e45d('0x1')](function(_0x2c092c){_0x24a84(_0x2c092c);});})[_0x2ac8e0('0x1')](function(_0x4a144a){_0x24a84(_0x4a144a);});}else ami[_0x2ac8e0('0x1c')](ut[_0x2ac8e0('0x2d')](_0x1845cc,_0x354517))[_0x2ac8e0('0x5b')](function(_0x463637){_0x5cdd62(_0x463637);})['catch'](function(_0x3deed5){_0x24a84(_0x3deed5);});});}Fax[_0x58d20d('0x67')][_0x58d20d('0x3b')]=function(_0xdda387,_0x4311aa){const _0x321161=this;return new Promise(function(_0x555746,_0x128bbd){const _0x5013cf=a1061_0x1660,_0x4a4722=uuid['v4'](),_0x135a1b=ut['addVariables'](_0xdda387,_0x4311aa);_0x321161[_0x5013cf('0x14')][_0x4a4722]=new Action(_0x4a4722,_0x4311aa,_0xdda387);const _0x8873ea=_0x321161[_0x5013cf('0x14')][_0x4a4722];path[_0x5013cf('0x5c')](_0xdda387[_0x5013cf('0x61')])['ext']===_0x5013cf('0x69')?originate(_0x8873ea,_0x135a1b,!![])[_0x5013cf('0x5b')](function(_0x47824b){_0x555746(_0x47824b);})[_0x5013cf('0x1')](function(_0xad209b){_0x128bbd(_0xad209b);}):originate(_0x8873ea,_0x135a1b,![])['then'](function(_0x76d757){_0x555746(_0x76d757);})[_0x5013cf('0x1')](function(_0x3fd050){_0x128bbd(_0x3fd050);});});},Fax[_0x58d20d('0x67')][_0x58d20d('0x11')]=function(_0x415f51){const _0x4d000c=_0x58d20d;return!_[_0x4d000c('0x16')](_0x415f51)&&!_['isNil'](_0x415f51[_0x4d000c('0x64')])&&!_['isNil'](_0x415f51[_0x4d000c('0x5')])&&_0x415f51[_0x4d000c('0x5')]&&!_[_0x4d000c('0x16')](this[_0x4d000c('0x26')][util['format'](_0x4d000c('0x0'),_0x415f51[_0x4d000c('0x64')])])&&!_[_0x4d000c('0x16')](this[_0x4d000c('0x26')][util[_0x4d000c('0x31')](_0x4d000c('0x0'),_0x415f51['name'])]['status'])&&(this[_0x4d000c('0x26')][util[_0x4d000c('0x31')](_0x4d000c('0x0'),_0x415f51[_0x4d000c('0x64')])][_0x4d000c('0x22')]==='reachable'||this[_0x4d000c('0x26')][util[_0x4d000c('0x31')](_0x4d000c('0x0'),_0x415f51[_0x4d000c('0x64')])]['status']===_0x4d000c('0x38'));},Fax[_0x58d20d('0x67')]['checkTrunk']=function(_0x51957a,_0x35e277){const _0x597714=_0x58d20d;if(!this['isTrunkReachable'](_0x51957a))return ut[_0x597714('0x46')](_0x597714('0x65'),_['isNil'](_0x51957a)?'':_0x51957a[_0x597714('0x64')]+_0x597714('0x60')),{'isValid':![],'message':'Trunk\x20not\x20working'};if(_[_0x597714('0x16')](_0x35e277[_0x597714('0x3')]))return ut[_0x597714('0x46')](_0x597714('0x54'),JSON[_0x597714('0x30')](_0x35e277)),{'isValid':![],'message':_0x597714('0x9')};if(_['isNil'](_0x35e277[_0x597714('0x61')]))return ut[_0x597714('0x46')](_0x597714('0x47'),JSON[_0x597714('0x30')](_0x35e277)),{'isValid':![],'message':'Empty\x20path'};return{'isValid':!![],'message':_0x597714('0x1d')};},module['exports']=Fax; \ No newline at end of file diff --git a/server/services/ami/fax/rpcDb.js b/server/services/ami/fax/rpcDb.js index 7143041..b7618eb 100644 --- a/server/services/ami/fax/rpcDb.js +++ b/server/services/ami/fax/rpcDb.js @@ -1 +1 @@ -const a1062_0x3b89=['notify','[Notify]\x20','preview','../rpc/faxAccount','../../../config/logger','error','catch','then','inspect'];(function(_0x3bfc77,_0x3b89a8){const _0x2318e6=function(_0x5f3413){while(--_0x5f3413){_0x3bfc77['push'](_0x3bfc77['shift']());}};_0x2318e6(++_0x3b89a8);}(a1062_0x3b89,0x18b));const a1062_0x2318=function(_0x3bfc77,_0x3b89a8){_0x3bfc77=_0x3bfc77-0x0;let _0x2318e6=a1062_0x3b89[_0x3bfc77];return _0x2318e6;};const _0x4f9326=a1062_0x2318;'use strict';const util=require('util'),logger=require(_0x4f9326('0x5'))(_0x4f9326('0x3')),faxAccount=require(_0x4f9326('0x4'));function loggerCatch(_0x5f3413){return function(_0xc9d172){const _0x2dbe44=a1062_0x2318;logger[_0x2dbe44('0x6')](_0x5f3413,util[_0x2dbe44('0x0')](_0xc9d172,{'showHidden':![],'depth':null}));};}exports[_0x4f9326('0x1')]=function(_0x5221e6,_0x145b4c){const _0x1fdb0f=_0x4f9326;return Promise['resolve']()[_0x1fdb0f('0x8')](faxAccount['notify'](_0x5221e6,_0x145b4c))[_0x1fdb0f('0x7')](loggerCatch(_0x1fdb0f('0x2')));}; \ No newline at end of file +const a1062_0x4b3c=['catch','../../../config/logger','inspect','notify','../rpc/faxAccount','[Notify]\x20','util'];(function(_0x589a13,_0x4b3ced){const _0x98cbe1=function(_0x9ca3b){while(--_0x9ca3b){_0x589a13['push'](_0x589a13['shift']());}};_0x98cbe1(++_0x4b3ced);}(a1062_0x4b3c,0xf2));const a1062_0x98cb=function(_0x589a13,_0x4b3ced){_0x589a13=_0x589a13-0x0;let _0x98cbe1=a1062_0x4b3c[_0x589a13];return _0x98cbe1;};const _0x5b625c=a1062_0x98cb;'use strict';const util=require(_0x5b625c('0x2')),logger=require(_0x5b625c('0x4'))('preview'),faxAccount=require(_0x5b625c('0x0'));function loggerCatch(_0x9ca3b){return function(_0x5ba77b){const _0xc74091=a1062_0x98cb;logger['error'](_0x9ca3b,util[_0xc74091('0x5')](_0x5ba77b,{'showHidden':![],'depth':null}));};}exports[_0x5b625c('0x6')]=function(_0x5e1815,_0x64b3bd){const _0x548766=_0x5b625c;return Promise['resolve']()['then'](faxAccount['notify'](_0x5e1815,_0x64b3bd))[_0x548766('0x3')](loggerCatch(_0x548766('0x1')));}; \ No newline at end of file diff --git a/server/services/ami/fax/util/gs.js b/server/services/ami/fax/util/gs.js index 975f55b..44624bd 100644 --- a/server/services/ami/fax/util/gs.js +++ b/server/services/ami/fax/util/gs.js @@ -1 +1 @@ -const a1063_0x10d0=['Exec\x20gs','execute','\x20Error\x20:','util','exec','fax','info','child_process'];(function(_0x42898c,_0x10d0fb){const _0xb5914=function(_0x5a3b1b){while(--_0x5a3b1b){_0x42898c['push'](_0x42898c['shift']());}};_0xb5914(++_0x10d0fb);}(a1063_0x10d0,0x1e6));const a1063_0xb591=function(_0x42898c,_0x10d0fb){_0x42898c=_0x42898c-0x0;let _0xb5914=a1063_0x10d0[_0x42898c];return _0xb5914;};const _0x119a24=a1063_0xb591;'use strict';const util=require(_0x119a24('0x5')),logger=require('../../../../config/logger')(_0x119a24('0x7')),exec=require(_0x119a24('0x1'))[_0x119a24('0x6')];exports[_0x119a24('0x3')]=function(_0x5a3b1b){return new Promise(function(_0x5309fb,_0xb3a98){exec(_0x5a3b1b,function(_0xbd7f86,_0x261473,_0x15cbb4){const _0x15b89f=a1063_0xb591;logger[_0x15b89f('0x0')](_0x15b89f('0x2'),_0x261473),_0xbd7f86&&(logger[_0x15b89f('0x0')](_0x15b89f('0x2'),_0x15b89f('0x4'),util['inspect'](_0xbd7f86,{'showHidden':![],'depth':null}),_0x261473,_0x15cbb4),_0xb3a98(_0xbd7f86)),_0x5309fb(_0x261473);});});}; \ No newline at end of file +const a1063_0x8a82=['\x20Error\x20:','Exec\x20gs','util','execute','../../../../config/logger','exec','inspect','info'];(function(_0x148fbd,_0x8a82e7){const _0x423c71=function(_0xe8b893){while(--_0xe8b893){_0x148fbd['push'](_0x148fbd['shift']());}};_0x423c71(++_0x8a82e7);}(a1063_0x8a82,0x115));const a1063_0x423c=function(_0x148fbd,_0x8a82e7){_0x148fbd=_0x148fbd-0x0;let _0x423c71=a1063_0x8a82[_0x148fbd];return _0x423c71;};const _0x4780f9=a1063_0x423c;'use strict';const util=require(_0x4780f9('0x5')),logger=require(_0x4780f9('0x7'))('fax'),exec=require('child_process')[_0x4780f9('0x0')];exports[_0x4780f9('0x6')]=function(_0xe8b893){return new Promise(function(_0x64bf8d,_0x4601da){exec(_0xe8b893,function(_0x5732e1,_0x5bdc26,_0x590fcc){const _0x1c4560=a1063_0x423c;logger[_0x1c4560('0x2')](_0x1c4560('0x4'),_0x5bdc26),_0x5732e1&&(logger[_0x1c4560('0x2')](_0x1c4560('0x4'),_0x1c4560('0x3'),util[_0x1c4560('0x1')](_0x5732e1,{'showHidden':![],'depth':null}),_0x5bdc26,_0x590fcc),_0x4601da(_0x5732e1)),_0x64bf8d(_0x5bdc26);});});}; \ No newline at end of file diff --git a/server/services/ami/fax/util/util.js b/server/services/ami/fax/util/util.js index 56c12b9..743cde9 100644 --- a/server/services/ami/fax/util/util.js +++ b/server/services/ami/fax/util/util.js @@ -1 +1 @@ -const a1064_0x4666=['headerinfo','message','../../../../config/logger','maxrate','modem','logger','fax','addVariables','info','localstationid','path','util','t38timeout','\x22%s\x22\x20<%s>','channel','format','minrate','gateway','originate','ecm','uniqueid','inspect'];(function(_0x3dbd80,_0x466622){const _0x1fe825=function(_0x4c08b6){while(--_0x4c08b6){_0x3dbd80['push'](_0x3dbd80['shift']());}};_0x1fe825(++_0x466622);}(a1064_0x4666,0x15c));const a1064_0x1fe8=function(_0x3dbd80,_0x466622){_0x3dbd80=_0x3dbd80-0x0;let _0x1fe825=a1064_0x4666[_0x3dbd80];return _0x1fe825;};const _0x12b04e=a1064_0x1fe8;'use strict';const util=require(_0x12b04e('0xf')),logger=require(_0x12b04e('0x6'))(_0x12b04e('0xa'));exports[_0x12b04e('0x5')]=function(_0x4c08b6){return{'message':_0x4c08b6};},exports[_0x12b04e('0x9')]=function(_0x1367f3,_0x24f48a){const _0x1cabd2=_0x12b04e;logger[_0x1cabd2('0xc')](_0x1367f3,util[_0x1cabd2('0x3')](_0x24f48a,{'showHidden':![],'depth':null}));},exports[_0x12b04e('0xb')]=function(_0x236205,_0x5947c9){const _0x4d2b05=_0x12b04e,_0xa19340={'XMF-ECM':_0x5947c9[_0x4d2b05('0x1')],'XMF-HEADERINFO':_0x5947c9[_0x4d2b05('0x4')],'XMF-MINRATE':_0x5947c9[_0x4d2b05('0x14')],'XMF-MAXRATE':_0x5947c9[_0x4d2b05('0x7')],'XMF-MODEM':util[_0x4d2b05('0x13')]('\x22%s\x22',_0x5947c9[_0x4d2b05('0x8')]),'XMF-GATEWAY':_0x5947c9[_0x4d2b05('0x15')],'XMF-FAXDETECT':_0x5947c9['faxdetect'],'XMF-T38TIMEOUT':_0x5947c9[_0x4d2b05('0x10')],'XMF-LOCALSTATIONID':_0x5947c9[_0x4d2b05('0xd')],'XMF-PATH':_0x236205[_0x4d2b05('0xe')]};return _0xa19340;},exports['variablesAction']=function(_0x417173,_0x155f5b){const _0x302383=_0x12b04e;return{'actionid':_0x417173[_0x302383('0x2')],'action':_0x302383('0x0'),'channel':_0x417173[_0x302383('0x12')],'Exten':'xcally-motion-fax','Context':'from-sip','Priority':'1','callerid':util[_0x302383('0x13')](_0x302383('0x11'),_0x417173[_0x302383('0x4')]?_0x417173[_0x302383('0x4')]:'',_0x417173[_0x302383('0xd')]),'variable':_0x155f5b,'timeout':0x1e*0x3e8,'async':!![],'channelid':_0x417173[_0x302383('0x2')]};}; \ No newline at end of file +const a1064_0x4536=['maxrate','message','channel','localstationid','info','gateway','uniqueid','../../../../config/logger','fax','headerinfo','ecm','variablesAction','inspect','originate','format','\x22%s\x22','\x22%s\x22\x20<%s>','minrate','path','from-sip','modem'];(function(_0x4a31c4,_0x4536b1){const _0x4af0ce=function(_0x77cd29){while(--_0x77cd29){_0x4a31c4['push'](_0x4a31c4['shift']());}};_0x4af0ce(++_0x4536b1);}(a1064_0x4536,0x132));const a1064_0x4af0=function(_0x4a31c4,_0x4536b1){_0x4a31c4=_0x4a31c4-0x0;let _0x4af0ce=a1064_0x4536[_0x4a31c4];return _0x4af0ce;};const _0x431bd5=a1064_0x4af0;'use strict';const util=require('util'),logger=require(_0x431bd5('0x10'))(_0x431bd5('0x11'));exports[_0x431bd5('0xa')]=function(_0x77cd29){return{'message':_0x77cd29};},exports['logger']=function(_0x351fab,_0x3a9ea1){const _0x482fa5=_0x431bd5;logger[_0x482fa5('0xd')](_0x351fab,util[_0x482fa5('0x0')](_0x3a9ea1,{'showHidden':![],'depth':null}));},exports['addVariables']=function(_0x13f820,_0x1a674d){const _0x9f72a5=_0x431bd5,_0x24face={'XMF-ECM':_0x1a674d[_0x9f72a5('0x13')],'XMF-HEADERINFO':_0x1a674d[_0x9f72a5('0x12')],'XMF-MINRATE':_0x1a674d[_0x9f72a5('0x5')],'XMF-MAXRATE':_0x1a674d[_0x9f72a5('0x9')],'XMF-MODEM':util[_0x9f72a5('0x2')](_0x9f72a5('0x3'),_0x1a674d[_0x9f72a5('0x8')]),'XMF-GATEWAY':_0x1a674d[_0x9f72a5('0xe')],'XMF-FAXDETECT':_0x1a674d['faxdetect'],'XMF-T38TIMEOUT':_0x1a674d['t38timeout'],'XMF-LOCALSTATIONID':_0x1a674d[_0x9f72a5('0xc')],'XMF-PATH':_0x13f820[_0x9f72a5('0x6')]};return _0x24face;},exports[_0x431bd5('0x14')]=function(_0x391c82,_0x4dd04a){const _0x4f57a7=_0x431bd5;return{'actionid':_0x391c82[_0x4f57a7('0xf')],'action':_0x4f57a7('0x1'),'channel':_0x391c82[_0x4f57a7('0xb')],'Exten':'xcally-motion-fax','Context':_0x4f57a7('0x7'),'Priority':'1','callerid':util[_0x4f57a7('0x2')](_0x4f57a7('0x4'),_0x391c82[_0x4f57a7('0x12')]?_0x391c82[_0x4f57a7('0x12')]:'',_0x391c82[_0x4f57a7('0xc')]),'variable':_0x4dd04a,'timeout':0x1e*0x3e8,'async':!![],'channelid':_0x391c82[_0x4f57a7('0xf')]};}; \ No newline at end of file diff --git a/server/services/ami/index.js b/server/services/ami/index.js index 3d2d46c..7cb4324 100644 --- a/server/services/ami/index.js +++ b/server/services/ami/index.js @@ -1 +1 @@ -const a1065_0x53cd=['./fax','getVoiceCallReports','getVoiceQueueHopperHistory','./rpc/integrations/salesforce','getZendeskAccounts','getVoiceQueueReports','./rpc/integrations/desk','getTrunks','initVoiceQueues','./rpc/voiceExtension','then','initVoiceQueueHopperHistory','catch','./rpc/integrations/freshdesk','initVoiceExtensions','initServicenowAccounts','initZohoAccounts','initFaxAccounts','./rpc/template','initVoiceCallReports','initCampaigns','./rpc/user','getVoiceExtensions','initFreshdeskAccounts','getTemplates','initTelephones','getVtigerAccounts','./rpc/faxAccount','./realtime','initCampaignHopperHistory','getSalesforceAccounts','./rpc/trunk','get','initSugarcrmAccounts','getFreshdeskAccounts','./rpc/integrations/sugarcrm','getAgents','hour','./rpc/integrations/servicenow','getDynamics365Accounts','initVtigerAccounts','../../globals','initZendeskAccounts','./rpc/voiceQueueReport','getFreshsalesAccounts','initAgents','initTriggers','getSugarcrmAccounts','sync','./rpc/integrations/freshsales','./rpc/integrations/zoho','resolve','./rpc/voiceQueue','./preview','initFreshsalesAccounts','getServicenowAccounts','getCampaigns','getFaxAccounts','./rpc/cmHopperHistory','initDeskAccounts','./rpc/integrations/dynamics365','getVoiceQueues','./report'];(function(_0x4671fa,_0x53cd24){const _0xb017b5=function(_0x522acb){while(--_0x522acb){_0x4671fa['push'](_0x4671fa['shift']());}};_0xb017b5(++_0x53cd24);}(a1065_0x53cd,0x1b7));const a1065_0xb017=function(_0x4671fa,_0x53cd24){_0x4671fa=_0x4671fa-0x0;let _0xb017b5=a1065_0x53cd[_0x4671fa];return _0xb017b5;};const _0x4f2207=a1065_0xb017;'use strict';require(_0x4f2207('0x2b'));const moment=require('moment'),server=require('./server'),Realtime=require(_0x4f2207('0x1e')),Report=require(_0x4f2207('0x1')),Preview=require(_0x4f2207('0x37')),Fax=require(_0x4f2207('0x2')),user=require(_0x4f2207('0x17')),voiceQueue=require(_0x4f2207('0x36')),voiceQueueReport=require(_0x4f2207('0x2d')),voiceCallReport=require('./rpc/voiceCallReport'),trunk=require(_0x4f2207('0x21')),trigger=require('./rpc/trigger'),template=require(_0x4f2207('0x14')),cmHopperHistory=require(_0x4f2207('0x3c')),campaign=require('./rpc/campaign'),voiceExtension=require(_0x4f2207('0xb')),faxAccount=require(_0x4f2207('0x1d')),zendesk=require('./rpc/integrations/zendesk'),salesforce=require(_0x4f2207('0x5')),sugarcrm=require(_0x4f2207('0x25')),freshdesk=require(_0x4f2207('0xf')),desk=require(_0x4f2207('0x8')),zoho=require(_0x4f2207('0x34')),vtiger=require('./rpc/integrations/vtiger'),freshsales=require(_0x4f2207('0x33')),servicenow=require(_0x4f2207('0x28')),dynamics365=require(_0x4f2207('0x3e')),realtime=new Realtime(),report=new Report(realtime),preview=new Preview(realtime),fax=new Fax(realtime);let isTrue=!![],initP=!![];function ifMidnight(){const _0x48246c=_0x4f2207;moment()[_0x48246c('0x22')](_0x48246c('0x27'))===0x0&&initP&&(initP=![],isTrue=!![],initParams()),moment()['get'](_0x48246c('0x27'))===0x1&&isTrue&&(isTrue=![],initP=!![]);}function initRealtime(){const _0x4dc3d9=_0x4f2207;return ifMidnight(),Promise[_0x4dc3d9('0x35')]()[_0x4dc3d9('0xc')](user[_0x4dc3d9('0x26')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x2f')]())[_0x4dc3d9('0xc')](user['getTelephones']())['then'](realtime[_0x4dc3d9('0x1b')]())[_0x4dc3d9('0xc')](trunk[_0x4dc3d9('0x9')]())[_0x4dc3d9('0xc')](realtime['initTrunks']())[_0x4dc3d9('0xc')](voiceQueue[_0x4dc3d9('0x0')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0xa')]())['then'](trigger['getTriggers']())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x30')]())[_0x4dc3d9('0xc')](template[_0x4dc3d9('0x1a')]())[_0x4dc3d9('0xc')](realtime['initTemplates']())[_0x4dc3d9('0xc')](zendesk[_0x4dc3d9('0x6')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x2c')]())['then'](salesforce[_0x4dc3d9('0x20')]())[_0x4dc3d9('0xc')](realtime['initSalesforceAccounts']())['then'](sugarcrm[_0x4dc3d9('0x31')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x23')]())[_0x4dc3d9('0xc')](freshdesk[_0x4dc3d9('0x24')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x19')]())[_0x4dc3d9('0xc')](desk['getDeskAccounts']())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x3d')]())[_0x4dc3d9('0xc')](zoho['getZohoAccounts']())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x12')]())['then'](vtiger[_0x4dc3d9('0x1c')]())['then'](realtime[_0x4dc3d9('0x2a')]())[_0x4dc3d9('0xc')](freshsales[_0x4dc3d9('0x2e')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x38')]())['then'](servicenow[_0x4dc3d9('0x39')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x11')]())[_0x4dc3d9('0xc')](dynamics365[_0x4dc3d9('0x29')]())[_0x4dc3d9('0xc')](realtime['initDynamics365Accounts']())[_0x4dc3d9('0xc')](campaign[_0x4dc3d9('0x3a')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x16')]())[_0x4dc3d9('0xc')](voiceExtension[_0x4dc3d9('0x18')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x10')]())['then'](faxAccount[_0x4dc3d9('0x3b')]())[_0x4dc3d9('0xc')](realtime[_0x4dc3d9('0x13')]())[_0x4dc3d9('0xc')](function(){return realtime;});}function initParams(){const _0x46aeda=_0x4f2207;return Promise[_0x46aeda('0x35')]()['then'](voiceQueueReport[_0x46aeda('0x7')]())[_0x46aeda('0xc')](realtime['initVoiceQueueReports']())[_0x46aeda('0xc')](cmHopperHistory[_0x46aeda('0x4')]())['then'](realtime[_0x46aeda('0xd')]())[_0x46aeda('0xc')](cmHopperHistory['getCampaignHopperHistory']())[_0x46aeda('0xc')](realtime[_0x46aeda('0x1f')]())[_0x46aeda('0xc')](voiceCallReport[_0x46aeda('0x3')]())['then'](realtime[_0x46aeda('0x15')]())[_0x46aeda('0xc')](function(){})[_0x46aeda('0xe')](function(_0x522acb){console['log'](_0x522acb);});}function main(){const _0x4d36a2=_0x4f2207;return server['listen'](realtime,preview,fax)[_0x4d36a2('0xc')](function(){return initRealtime();})[_0x4d36a2('0xc')](function(){return initParams();})[_0x4d36a2('0xc')](function(){const _0x37ce1a=_0x4d36a2;report[_0x37ce1a('0x32')](),setInterval(initRealtime,0x1388);})['catch'](function(_0x42cac7){console['log'](_0x42cac7);});}main(); \ No newline at end of file +const a1065_0x34e9=['getVoiceExtensions','initCampaignHopperHistory','getZohoAccounts','./rpc/voiceQueueReport','./rpc/voiceQueue','getServicenowAccounts','initFreshsalesAccounts','resolve','getTrunks','moment','./rpc/trunk','initDeskAccounts','initZohoAccounts','./fax','./rpc/campaign','initCampaigns','initServicenowAccounts','initTriggers','getZendeskAccounts','./rpc/faxAccount','initVoiceQueues','getVtigerAccounts','./rpc/integrations/salesforce','getFreshdeskAccounts','getVoiceQueues','../../globals','initSugarcrmAccounts','then','initDynamics365Accounts','initTemplates','./rpc/voiceExtension','log','./rpc/integrations/zendesk','getCampaignHopperHistory','initFaxAccounts','getTelephones','./rpc/cmHopperHistory','./rpc/template','./rpc/integrations/servicenow','getAgents','catch','getVoiceQueueReports','./rpc/integrations/desk','getDeskAccounts','./realtime','./rpc/integrations/vtiger','getTriggers','getSugarcrmAccounts','get','initTrunks','getCampaigns','getSalesforceAccounts','initVoiceQueueReports','hour','./server','./rpc/trigger','listen','initVtigerAccounts','./rpc/voiceCallReport','./report','sync','./rpc/integrations/sugarcrm','initAgents','./rpc/integrations/freshdesk'];(function(_0x4bdf02,_0x34e9d6){const _0x1d4588=function(_0x993a92){while(--_0x993a92){_0x4bdf02['push'](_0x4bdf02['shift']());}};_0x1d4588(++_0x34e9d6);}(a1065_0x34e9,0x9d));const a1065_0x1d45=function(_0x4bdf02,_0x34e9d6){_0x4bdf02=_0x4bdf02-0x0;let _0x1d4588=a1065_0x34e9[_0x4bdf02];return _0x1d4588;};const _0x5727d1=a1065_0x1d45;'use strict';require(_0x5727d1('0x3c'));const moment=require(_0x5727d1('0x2c')),server=require(_0x5727d1('0x19')),Realtime=require(_0x5727d1('0xf')),Report=require(_0x5727d1('0x1e')),Preview=require('./preview'),Fax=require(_0x5727d1('0x30')),user=require('./rpc/user'),voiceQueue=require(_0x5727d1('0x27')),voiceQueueReport=require(_0x5727d1('0x26')),voiceCallReport=require(_0x5727d1('0x1d')),trunk=require(_0x5727d1('0x2d')),trigger=require(_0x5727d1('0x1a')),template=require(_0x5727d1('0x8')),cmHopperHistory=require(_0x5727d1('0x7')),campaign=require(_0x5727d1('0x31')),voiceExtension=require(_0x5727d1('0x1')),faxAccount=require(_0x5727d1('0x36')),zendesk=require(_0x5727d1('0x3')),salesforce=require(_0x5727d1('0x39')),sugarcrm=require(_0x5727d1('0x20')),freshdesk=require(_0x5727d1('0x22')),desk=require(_0x5727d1('0xd')),zoho=require('./rpc/integrations/zoho'),vtiger=require(_0x5727d1('0x10')),freshsales=require('./rpc/integrations/freshsales'),servicenow=require(_0x5727d1('0x9')),dynamics365=require('./rpc/integrations/dynamics365'),realtime=new Realtime(),report=new Report(realtime),preview=new Preview(realtime),fax=new Fax(realtime);let isTrue=!![],initP=!![];function ifMidnight(){const _0x21a0aa=_0x5727d1;moment()[_0x21a0aa('0x13')](_0x21a0aa('0x18'))===0x0&&initP&&(initP=![],isTrue=!![],initParams()),moment()[_0x21a0aa('0x13')](_0x21a0aa('0x18'))===0x1&&isTrue&&(isTrue=![],initP=!![]);}function initRealtime(){const _0x127ac9=_0x5727d1;return ifMidnight(),Promise[_0x127ac9('0x2a')]()['then'](user[_0x127ac9('0xa')]())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x21')]())[_0x127ac9('0x3e')](user[_0x127ac9('0x6')]())[_0x127ac9('0x3e')](realtime['initTelephones']())[_0x127ac9('0x3e')](trunk[_0x127ac9('0x2b')]())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x14')]())['then'](voiceQueue[_0x127ac9('0x3b')]())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x37')]())[_0x127ac9('0x3e')](trigger[_0x127ac9('0x11')]())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x34')]())['then'](template['getTemplates']())['then'](realtime[_0x127ac9('0x0')]())['then'](zendesk[_0x127ac9('0x35')]())[_0x127ac9('0x3e')](realtime['initZendeskAccounts']())[_0x127ac9('0x3e')](salesforce[_0x127ac9('0x16')]())[_0x127ac9('0x3e')](realtime['initSalesforceAccounts']())[_0x127ac9('0x3e')](sugarcrm[_0x127ac9('0x12')]())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x3d')]())[_0x127ac9('0x3e')](freshdesk[_0x127ac9('0x3a')]())['then'](realtime['initFreshdeskAccounts']())['then'](desk[_0x127ac9('0xe')]())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x2e')]())[_0x127ac9('0x3e')](zoho[_0x127ac9('0x25')]())['then'](realtime[_0x127ac9('0x2f')]())['then'](vtiger[_0x127ac9('0x38')]())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x1c')]())[_0x127ac9('0x3e')](freshsales['getFreshsalesAccounts']())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x29')]())['then'](servicenow[_0x127ac9('0x28')]())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x33')]())[_0x127ac9('0x3e')](dynamics365['getDynamics365Accounts']())['then'](realtime[_0x127ac9('0x3f')]())[_0x127ac9('0x3e')](campaign[_0x127ac9('0x15')]())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x32')]())[_0x127ac9('0x3e')](voiceExtension[_0x127ac9('0x23')]())[_0x127ac9('0x3e')](realtime['initVoiceExtensions']())['then'](faxAccount['getFaxAccounts']())[_0x127ac9('0x3e')](realtime[_0x127ac9('0x5')]())[_0x127ac9('0x3e')](function(){return realtime;});}function initParams(){const _0x30048e=_0x5727d1;return Promise[_0x30048e('0x2a')]()[_0x30048e('0x3e')](voiceQueueReport[_0x30048e('0xc')]())['then'](realtime[_0x30048e('0x17')]())[_0x30048e('0x3e')](cmHopperHistory['getVoiceQueueHopperHistory']())[_0x30048e('0x3e')](realtime['initVoiceQueueHopperHistory']())[_0x30048e('0x3e')](cmHopperHistory[_0x30048e('0x4')]())[_0x30048e('0x3e')](realtime[_0x30048e('0x24')]())['then'](voiceCallReport['getVoiceCallReports']())[_0x30048e('0x3e')](realtime['initVoiceCallReports']())[_0x30048e('0x3e')](function(){})[_0x30048e('0xb')](function(_0x993a92){const _0x22abf5=_0x30048e;console[_0x22abf5('0x2')](_0x993a92);});}function main(){const _0x50ee74=_0x5727d1;return server[_0x50ee74('0x1b')](realtime,preview,fax)[_0x50ee74('0x3e')](function(){return initRealtime();})[_0x50ee74('0x3e')](function(){return initParams();})[_0x50ee74('0x3e')](function(){const _0xd10ae5=_0x50ee74;report[_0xd10ae5('0x1f')](),setInterval(initRealtime,0x1388);})['catch'](function(_0x4d66b8){const _0x537c0e=_0x50ee74;console[_0x537c0e('0x2')](_0x4d66b8);});}main(); \ No newline at end of file diff --git a/server/services/ami/model/agent.js b/server/services/ami/model/agent.js index 771fa57..dedf63f 100644 --- a/server/services/ami/model/agent.js +++ b/server/services/ami/model/agent.js @@ -1 +1 @@ -const a1066_0x1252=['online','voiceStatusTime','address','status','inuse','accountcode','voiceStatusQueue','onhold','prototype','moment','interface','name','phone','statePause','unknown','user:%s','not_inuse','fullname','voiceStatus','talking','format','md5','toLowerCase','updateStatusRealtime','idle','../../../rediscache','lodash','state','email','emit','mobile'];(function(_0x544997,_0x1252a0){const _0x3d7f4b=function(_0x2276a2){while(--_0x2276a2){_0x544997['push'](_0x544997['shift']());}};_0x3d7f4b(++_0x1252a0);}(a1066_0x1252,0x19c));const a1066_0x3d7f=function(_0x544997,_0x1252a0){_0x544997=_0x544997-0x0;let _0x3d7f4b=a1066_0x1252[_0x544997];return _0x3d7f4b;};const _0x277209=a1066_0x3d7f;'use strict';const _=require(_0x277209('0x11')),util=require('util'),moment=require(_0x277209('0x0')),md5=require(_0x277209('0xc')),{getSocket}=require(_0x277209('0x10')),io=getSocket();function Agent(_0x2276a2){const _0x595be3=_0x277209;this['id']=_0x2276a2['id']||0x0,this['name']=_0x2276a2[_0x595be3('0x2')]||'',this[_0x595be3('0x13')]=_0x2276a2[_0x595be3('0x13')]||'',this[_0x595be3('0x1b')]=_0x2276a2[_0x595be3('0x1b')]||'',this['fullname']=_0x2276a2[_0x595be3('0x8')]||'',this['state']=_0x595be3('0x5'),this['stateTime']=0x0,this[_0x595be3('0x19')]=_0x595be3('0x5'),this[_0x595be3('0x18')]='',this[_0x595be3('0x3')]='',this[_0x595be3('0x15')]='',this[_0x595be3('0x1')]='',this['online']=_0x2276a2[_0x595be3('0x16')]||![],this[_0x595be3('0x9')]='unknown',this[_0x595be3('0x17')]=0x0,this['voiceStatusCallerIdNumber']='',this[_0x595be3('0x1c')]='',this[_0x595be3('0x1d')]=![],this['local']=![],this[_0x595be3('0xc')]='';}Agent[_0x277209('0x1e')][_0x277209('0xe')]=function(_0x38df44){const _0x15a569=_0x277209;let _0x25a4b1;if(_0x38df44&&_0x38df44['state']){_0x25a4b1=_0x38df44[_0x15a569('0x12')][_0x15a569('0xd')]();switch(_0x25a4b1){case _0x15a569('0x7'):_0x25a4b1=_0x15a569('0xf');break;case _0x15a569('0x1a'):_0x25a4b1=_0x15a569('0xa');break;}}(_0x25a4b1&&this[_0x15a569('0x9')]!==_0x25a4b1||_0x38df44[_0x15a569('0x4')])&&(this[_0x15a569('0x17')]=_['toNumber'](moment()['format']('x')));_0x25a4b1&&(this['voiceStatus']=_0x25a4b1);const _0xf30622={'id':this['id'],'name':this[_0x15a569('0x2')],'email':this[_0x15a569('0x13')],'accountcode':this[_0x15a569('0x1b')],'fullname':this[_0x15a569('0x8')],'state':this[_0x15a569('0x12')],'stateTime':this['stateTime'],'status':this[_0x15a569('0x19')],'address':this[_0x15a569('0x18')],'online':this[_0x15a569('0x16')],'voiceStatus':this['voiceStatus'],'voiceStatusTime':this[_0x15a569('0x17')],'voiceStatusCallerIdNumber':this['voiceStatusCallerIdNumber'],'voiceStatusQueue':this[_0x15a569('0x1c')],'interface':this[_0x15a569('0x1')],'onhold':this['onhold']},_0x52a3bd=md5(JSON['stringify'](_0xf30622));this['md5']!==_0x52a3bd&&(this[_0x15a569('0xc')]=_0x52a3bd,io['to'](util[_0x15a569('0xb')](_0x15a569('0x6'),_0xf30622[_0x15a569('0x2')]))[_0x15a569('0x14')]('user:save',_0xf30622));},module['exports']=Agent; \ No newline at end of file +const a1066_0x4541=['idle','format','name','fullname','statePause','prototype','onhold','phone','interface','email','local','online','unknown','toNumber','util','address','exports','accountcode','voiceStatusTime','state','voiceStatusCallerIdNumber','md5','user:save','voiceStatus','stringify','inuse','../../../rediscache','stateTime','voiceStatusQueue'];(function(_0x30fa33,_0x454159){const _0x207366=function(_0x1912ef){while(--_0x1912ef){_0x30fa33['push'](_0x30fa33['shift']());}};_0x207366(++_0x454159);}(a1066_0x4541,0xa1));const a1066_0x2073=function(_0x30fa33,_0x454159){_0x30fa33=_0x30fa33-0x0;let _0x207366=a1066_0x4541[_0x30fa33];return _0x207366;};const _0x53aaa6=a1066_0x2073;'use strict';const _=require('lodash'),util=require(_0x53aaa6('0x1b')),moment=require('moment'),md5=require(_0x53aaa6('0x5')),{getSocket}=require(_0x53aaa6('0xa')),io=getSocket();function Agent(_0x1912ef){const _0x3cd4ea=_0x53aaa6;this['id']=_0x1912ef['id']||0x0,this[_0x3cd4ea('0xf')]=_0x1912ef[_0x3cd4ea('0xf')]||'',this['email']=_0x1912ef[_0x3cd4ea('0x16')]||'',this[_0x3cd4ea('0x1')]=_0x1912ef[_0x3cd4ea('0x1')]||'',this[_0x3cd4ea('0x10')]=_0x1912ef[_0x3cd4ea('0x10')]||'',this[_0x3cd4ea('0x3')]=_0x3cd4ea('0x19'),this[_0x3cd4ea('0xb')]=0x0,this['status']='unknown',this['address']='',this[_0x3cd4ea('0x14')]='',this['mobile']='',this[_0x3cd4ea('0x15')]='',this[_0x3cd4ea('0x18')]=_0x1912ef[_0x3cd4ea('0x18')]||![],this['voiceStatus']=_0x3cd4ea('0x19'),this['voiceStatusTime']=0x0,this[_0x3cd4ea('0x4')]='',this['voiceStatusQueue']='',this[_0x3cd4ea('0x13')]=![],this[_0x3cd4ea('0x17')]=![],this['md5']='';}Agent[_0x53aaa6('0x12')]['updateStatusRealtime']=function(_0x4d60da){const _0x275ef2=_0x53aaa6;let _0x2f2132;if(_0x4d60da&&_0x4d60da[_0x275ef2('0x3')]){_0x2f2132=_0x4d60da[_0x275ef2('0x3')]['toLowerCase']();switch(_0x2f2132){case'not_inuse':_0x2f2132=_0x275ef2('0xd');break;case _0x275ef2('0x9'):_0x2f2132='talking';break;}}(_0x2f2132&&this['voiceStatus']!==_0x2f2132||_0x4d60da[_0x275ef2('0x11')])&&(this[_0x275ef2('0x2')]=_[_0x275ef2('0x1a')](moment()[_0x275ef2('0xe')]('x')));_0x2f2132&&(this[_0x275ef2('0x7')]=_0x2f2132);const _0x14e46b={'id':this['id'],'name':this[_0x275ef2('0xf')],'email':this['email'],'accountcode':this['accountcode'],'fullname':this[_0x275ef2('0x10')],'state':this['state'],'stateTime':this['stateTime'],'status':this['status'],'address':this[_0x275ef2('0x1c')],'online':this[_0x275ef2('0x18')],'voiceStatus':this[_0x275ef2('0x7')],'voiceStatusTime':this[_0x275ef2('0x2')],'voiceStatusCallerIdNumber':this['voiceStatusCallerIdNumber'],'voiceStatusQueue':this[_0x275ef2('0xc')],'interface':this[_0x275ef2('0x15')],'onhold':this[_0x275ef2('0x13')]},_0x432655=md5(JSON[_0x275ef2('0x8')](_0x14e46b));this[_0x275ef2('0x5')]!==_0x432655&&(this[_0x275ef2('0x5')]=_0x432655,io['to'](util['format']('user:%s',_0x14e46b[_0x275ef2('0xf')]))['emit'](_0x275ef2('0x6'),_0x14e46b));},module[_0x53aaa6('0x0')]=Agent; \ No newline at end of file diff --git a/server/services/ami/model/campaign.js b/server/services/ami/model/campaign.js index d81fa1d..271b250 100644 --- a/server/services/ami/model/campaign.js +++ b/server/services/ami/model/campaign.js @@ -1 +1 @@ -var a1067_0x18f7=['dialAMDInitialSilence','dialCutDigit','dialOrderByScheduledAt','dialCongestionRetryFrequency','dialPrefix','campaign','dialAMDGreeting','ivrAnswerCallsDay','dialNoAnswerMaxRetry','sendMessageOneNotActive','limitCalls','dialQueueProject','message','dialOriginateTimeout','TrunkBackup','dialCongestionMaxRetry','Interval','dialAgentRejectMaxRetry','dialMachineMaxRetry','dialDropMaxRetry','dialOriginateCallerIdNumber','dialAgentRejectRetryFrequency','originated','dialGlobalInterval','dialAMDBetweenWordsSilence','dialAMDTotalAnalysisTime','dialGlobalMaxRetry','DESC','dialNoSuchNumberMaxRetry','dialNoAnswerRetryFrequency','dialMachineRetryFrequency','dialAMDMaximumWordLength','Trunk','dialAMDMinWordLength','dialAbandonedRetryFrequency','dialAMDAfterGreetingSilence','dialAMDActive','active','ivrTotalCallsDays','name','dialBusyRetryFrequency','type','dialAMDSilenceThreshold','dialTimezone','dialRandomLastDigitCallerIdNumber','dialDropRetryFrequency','SquareProject','dialAMDMaximumNumberOfWords','dialBusyMaxRetry','dialNoSuchNumberRetryFrequency','dialOriginateCallerIdName'];(function(_0x55987a,_0x18f714){var _0x37771f=function(_0x5a4d3a){while(--_0x5a4d3a){_0x55987a['push'](_0x55987a['shift']());}};_0x37771f(++_0x18f714);}(a1067_0x18f7,0x132));var a1067_0x3777=function(_0x55987a,_0x18f714){_0x55987a=_0x55987a-0x0;var _0x37771f=a1067_0x18f7[_0x55987a];return _0x37771f;};'use strict';function Campaign(_0x5a4d3a){var _0x3d9ce3=a1067_0x3777;this['id']=_0x5a4d3a['id']||0x0,this[_0x3d9ce3('0x27')]=_0x5a4d3a[_0x3d9ce3('0x27')]||'',this[_0x3d9ce3('0x29')]=_0x5a4d3a[_0x3d9ce3('0x29')]||_0x3d9ce3('0x5'),this[_0x3d9ce3('0x16')]=0x0,this['temp']=0x0,this[_0x3d9ce3('0x7')]=0x0,this[_0x3d9ce3('0x26')]=0x0,this[_0x3d9ce3('0xc')]='',this[_0x3d9ce3('0x9')]=!![],this[_0x3d9ce3('0x25')]=_0x5a4d3a[_0x3d9ce3('0x25')],this[_0x3d9ce3('0xa')]=_0x5a4d3a[_0x3d9ce3('0xa')],this[_0x3d9ce3('0x2b')]=_0x5a4d3a[_0x3d9ce3('0x2b')]||null,this['dialGlobalInterval']=_0x5a4d3a[_0x3d9ce3('0x17')]?_0x5a4d3a[_0x3d9ce3('0x17')]:null,this[_0x3d9ce3('0x32')]=_0x5a4d3a[_0x3d9ce3('0x32')],this[_0x3d9ce3('0x14')]=_0x5a4d3a[_0x3d9ce3('0x14')],this[_0x3d9ce3('0xd')]=_0x5a4d3a[_0x3d9ce3('0xd')]||0x1e,this[_0x3d9ce3('0xf')]=_0x5a4d3a[_0x3d9ce3('0xf')],this['dialCongestionRetryFrequency']=_0x5a4d3a[_0x3d9ce3('0x3')],this[_0x3d9ce3('0x30')]=_0x5a4d3a[_0x3d9ce3('0x30')],this[_0x3d9ce3('0x28')]=_0x5a4d3a['dialBusyRetryFrequency'],this[_0x3d9ce3('0x8')]=_0x5a4d3a[_0x3d9ce3('0x8')],this['dialNoAnswerRetryFrequency']=_0x5a4d3a[_0x3d9ce3('0x1d')],this['dialGlobalMaxRetry']=_0x5a4d3a[_0x3d9ce3('0x1a')],this['dialNoSuchNumberMaxRetry']=_0x5a4d3a[_0x3d9ce3('0x1c')]||0x3,this[_0x3d9ce3('0x31')]=_0x5a4d3a['dialNoSuchNumberRetryFrequency']||0x96,this['dialDropMaxRetry']=_0x5a4d3a[_0x3d9ce3('0x13')]||0x3,this[_0x3d9ce3('0x2d')]=_0x5a4d3a[_0x3d9ce3('0x2d')]||0x96,this['dialAbandonedMaxRetry']=_0x5a4d3a['dialAbandonedMaxRetry']||0x3,this[_0x3d9ce3('0x22')]=_0x5a4d3a['dialAbandonedRetryFrequency']||0x96,this[_0x3d9ce3('0x12')]=_0x5a4d3a[_0x3d9ce3('0x12')]||0x3,this[_0x3d9ce3('0x1e')]=_0x5a4d3a[_0x3d9ce3('0x1e')]||0x96,this[_0x3d9ce3('0x11')]=_0x5a4d3a['dialAgentRejectMaxRetry']||0x3,this['dialAgentRejectRetryFrequency']=_0x5a4d3a[_0x3d9ce3('0x15')]||0x96,this[_0x3d9ce3('0x2')]=_0x5a4d3a['dialOrderByScheduledAt']||_0x3d9ce3('0x1b'),this[_0x3d9ce3('0x4')]=_0x5a4d3a[_0x3d9ce3('0x4')]||undefined,this[_0x3d9ce3('0x2c')]=_0x5a4d3a['dialRandomLastDigitCallerIdNumber']||undefined,this[_0x3d9ce3('0x1')]=_0x5a4d3a['dialCutDigit']||undefined,this[_0x3d9ce3('0xe')]=_0x5a4d3a[_0x3d9ce3('0xe')]?_0x5a4d3a[_0x3d9ce3('0xe')]:undefined,this[_0x3d9ce3('0x20')]=_0x5a4d3a['Trunk']?_0x5a4d3a[_0x3d9ce3('0x20')]:undefined,this[_0x3d9ce3('0x10')]=_0x5a4d3a[_0x3d9ce3('0x10')]?_0x5a4d3a[_0x3d9ce3('0x10')]:undefined,this[_0x3d9ce3('0x2e')]=_0x5a4d3a[_0x3d9ce3('0x2e')]?_0x5a4d3a[_0x3d9ce3('0x2e')]:undefined,this[_0x3d9ce3('0xb')]=_0x5a4d3a[_0x3d9ce3('0x2e')]?_0x5a4d3a[_0x3d9ce3('0x2e')][_0x3d9ce3('0x27')]:undefined,this[_0x3d9ce3('0x24')]=_0x5a4d3a[_0x3d9ce3('0x24')]||![],this['dialAMDInitialSilence']=_0x5a4d3a[_0x3d9ce3('0x0')],this['dialAMDGreeting']=_0x5a4d3a[_0x3d9ce3('0x6')],this[_0x3d9ce3('0x23')]=_0x5a4d3a[_0x3d9ce3('0x23')],this[_0x3d9ce3('0x19')]=_0x5a4d3a['dialAMDTotalAnalysisTime'],this[_0x3d9ce3('0x21')]=_0x5a4d3a[_0x3d9ce3('0x21')],this[_0x3d9ce3('0x18')]=_0x5a4d3a[_0x3d9ce3('0x18')],this[_0x3d9ce3('0x2f')]=_0x5a4d3a[_0x3d9ce3('0x2f')],this[_0x3d9ce3('0x2a')]=_0x5a4d3a[_0x3d9ce3('0x2a')],this[_0x3d9ce3('0x1f')]=_0x5a4d3a[_0x3d9ce3('0x1f')];}module['exports']=Campaign; \ No newline at end of file +var a1067_0x5fd2=['sendMessageOneNotActive','limitCalls','dialCongestionRetryFrequency','exports','dialAMDMinWordLength','dialQueueProject','Trunk','dialMachineRetryFrequency','dialAgentRejectRetryFrequency','dialAMDBetweenWordsSilence','ivrTotalCallsDays','SquareProject','dialAMDSilenceThreshold','dialAMDAfterGreetingSilence','temp','dialDropMaxRetry','DESC','dialGlobalInterval','dialAMDGreeting','dialDropRetryFrequency','dialOriginateTimeout','Interval','dialNoSuchNumberMaxRetry','dialAMDMaximumNumberOfWords','dialGlobalMaxRetry','dialCutDigit','campaign','dialTimezone','dialPrefix','ivrAnswerCallsDay','dialNoAnswerRetryFrequency','type','dialAgentRejectMaxRetry','dialOriginateCallerIdName','dialOrderByScheduledAt','dialRandomLastDigitCallerIdNumber','dialMachineMaxRetry','dialAMDInitialSilence','dialAMDActive','dialBusyRetryFrequency','TrunkBackup','dialAbandonedMaxRetry','dialCongestionMaxRetry','active','dialOriginateCallerIdNumber','dialAbandonedRetryFrequency','name'];(function(_0x516850,_0x5fd26a){var _0x31a7b5=function(_0xff097c){while(--_0xff097c){_0x516850['push'](_0x516850['shift']());}};_0x31a7b5(++_0x5fd26a);}(a1067_0x5fd2,0x64));var a1067_0x31a7=function(_0x516850,_0x5fd26a){_0x516850=_0x516850-0x0;var _0x31a7b5=a1067_0x5fd2[_0x516850];return _0x31a7b5;};var _0x1bfa14=a1067_0x31a7;'use strict';function Campaign(_0xff097c){var _0x123411=a1067_0x31a7;this['id']=_0xff097c['id']||0x0,this['name']=_0xff097c[_0x123411('0x28')]||'',this[_0x123411('0x19')]=_0xff097c[_0x123411('0x19')]||_0x123411('0x14'),this['originated']=0x0,this[_0x123411('0x8')]=0x0,this[_0x123411('0x17')]=0x0,this[_0x123411('0x4')]=0x0,this['message']='',this[_0x123411('0x29')]=!![],this['active']=_0xff097c[_0x123411('0x25')],this[_0x123411('0x2a')]=_0xff097c['limitCalls'],this[_0x123411('0x15')]=_0xff097c['dialTimezone']||null,this[_0x123411('0xb')]=_0xff097c[_0x123411('0xb')]?_0xff097c[_0x123411('0xb')]:null,this[_0x123411('0x1b')]=_0xff097c[_0x123411('0x1b')],this['dialOriginateCallerIdNumber']=_0xff097c[_0x123411('0x26')],this['dialOriginateTimeout']=_0xff097c[_0x123411('0xe')]||0x1e,this[_0x123411('0x24')]=_0xff097c[_0x123411('0x24')],this[_0x123411('0x2b')]=_0xff097c['dialCongestionRetryFrequency'],this['dialBusyMaxRetry']=_0xff097c['dialBusyMaxRetry'],this[_0x123411('0x21')]=_0xff097c['dialBusyRetryFrequency'],this['dialNoAnswerMaxRetry']=_0xff097c['dialNoAnswerMaxRetry'],this['dialNoAnswerRetryFrequency']=_0xff097c[_0x123411('0x18')],this['dialGlobalMaxRetry']=_0xff097c[_0x123411('0x12')],this[_0x123411('0x10')]=_0xff097c[_0x123411('0x10')]||0x3,this['dialNoSuchNumberRetryFrequency']=_0xff097c['dialNoSuchNumberRetryFrequency']||0x96,this[_0x123411('0x9')]=_0xff097c[_0x123411('0x9')]||0x3,this[_0x123411('0xd')]=_0xff097c[_0x123411('0xd')]||0x96,this[_0x123411('0x23')]=_0xff097c['dialAbandonedMaxRetry']||0x3,this[_0x123411('0x27')]=_0xff097c[_0x123411('0x27')]||0x96,this[_0x123411('0x1e')]=_0xff097c[_0x123411('0x1e')]||0x3,this['dialMachineRetryFrequency']=_0xff097c[_0x123411('0x1')]||0x96,this[_0x123411('0x1a')]=_0xff097c[_0x123411('0x1a')]||0x3,this[_0x123411('0x2')]=_0xff097c[_0x123411('0x2')]||0x96,this['dialOrderByScheduledAt']=_0xff097c[_0x123411('0x1c')]||_0x123411('0xa'),this[_0x123411('0x16')]=_0xff097c[_0x123411('0x16')]||undefined,this[_0x123411('0x1d')]=_0xff097c[_0x123411('0x1d')]||undefined,this[_0x123411('0x13')]=_0xff097c['dialCutDigit']||undefined,this[_0x123411('0x22')]=_0xff097c[_0x123411('0x22')]?_0xff097c[_0x123411('0x22')]:undefined,this[_0x123411('0x0')]=_0xff097c[_0x123411('0x0')]?_0xff097c[_0x123411('0x0')]:undefined,this[_0x123411('0xf')]=_0xff097c['Interval']?_0xff097c[_0x123411('0xf')]:undefined,this[_0x123411('0x5')]=_0xff097c['SquareProject']?_0xff097c[_0x123411('0x5')]:undefined,this[_0x123411('0x2e')]=_0xff097c[_0x123411('0x5')]?_0xff097c['SquareProject'][_0x123411('0x28')]:undefined,this[_0x123411('0x20')]=_0xff097c[_0x123411('0x20')]||![],this[_0x123411('0x1f')]=_0xff097c[_0x123411('0x1f')],this[_0x123411('0xc')]=_0xff097c['dialAMDGreeting'],this[_0x123411('0x7')]=_0xff097c['dialAMDAfterGreetingSilence'],this['dialAMDTotalAnalysisTime']=_0xff097c['dialAMDTotalAnalysisTime'],this['dialAMDMinWordLength']=_0xff097c[_0x123411('0x2d')],this[_0x123411('0x3')]=_0xff097c[_0x123411('0x3')],this[_0x123411('0x11')]=_0xff097c['dialAMDMaximumNumberOfWords'],this[_0x123411('0x6')]=_0xff097c['dialAMDSilenceThreshold'],this['dialAMDMaximumWordLength']=_0xff097c['dialAMDMaximumWordLength'];}module[_0x1bfa14('0x2c')]=Campaign; \ No newline at end of file diff --git a/server/services/ami/model/channel.js b/server/services/ami/model/channel.js index 9b1a63f..c1a63de 100644 --- a/server/services/ami/model/channel.js +++ b/server/services/ami/model/channel.js @@ -1 +1 @@ -var a1068_0x2e81=['exten','transferconnectedlinenum','monitors','connectedlinenum','calleridname','answered','starttime','mohtime','abandoned','exports','destinationchannel','channel','monitor','accountcode','tag','lastapplication','context','queue','billableseconds','transfercalleridnum','duration','lastdata','answertime','unmanaged'];(function(_0x316a7b,_0x2e8133){var _0x420aed=function(_0x16bf81){while(--_0x16bf81){_0x316a7b['push'](_0x316a7b['shift']());}};_0x420aed(++_0x2e8133);}(a1068_0x2e81,0x1d7));var a1068_0x420a=function(_0x316a7b,_0x2e8133){_0x316a7b=_0x316a7b-0x0;var _0x420aed=a1068_0x2e81[_0x316a7b];return _0x420aed;};var _0x49aeee=a1068_0x420a;'use strict';function Channel(){var _0x36d212=a1068_0x420a;this[_0x36d212('0xf')]=null,this[_0x36d212('0x14')]='',this[_0x36d212('0x13')]='',this['calleridnum']=0x0,this[_0x36d212('0xd')]='',this[_0x36d212('0xc')]=undefined,this['connectedlinename']=undefined,this[_0x36d212('0x16')]=0x0,this[_0x36d212('0x1')]='',this['uniqueid']=0x0,this['linkedid']=0x0,this[_0x36d212('0x9')]=0x0,this[_0x36d212('0xe')]=![],this[_0x36d212('0x7')]=null,this['endtime']=null,this[_0x36d212('0x8')]=![],this[_0x36d212('0x11')]=![],this[_0x36d212('0x0')]='',this[_0x36d212('0x6')]='',this[_0x36d212('0x5')]=0x0,this[_0x36d212('0x3')]=0x0,this['holdtime']=0x0,this['type']=null,this[_0x36d212('0x17')]=null,this['disposition']=null,this[_0x36d212('0x15')]=![],this['monitorFilename']=null,this[_0x36d212('0x2')]=null,this[_0x36d212('0xb')]=[],this[_0x36d212('0x4')]=undefined,this[_0x36d212('0xa')]=undefined,this[_0x36d212('0x10')]=0x0;}module[_0x49aeee('0x12')]=Channel; \ No newline at end of file +var a1068_0x2a89=['billableseconds','transfercalleridnum','endtime','exports','monitorFilename','context','channel','queue','disposition','type','tag','starttime','mohtime','monitor','transferconnectedlinenum','uniqueid','connectedlinename','exten','accountcode','holdtime','answertime','lastdata','connectedlinenum','linkedid','destinationchannel','lastapplication','calleridname','duration'];(function(_0x547173,_0x2a89f8){var _0xde840f=function(_0x400a80){while(--_0x400a80){_0x547173['push'](_0x547173['shift']());}};_0xde840f(++_0x2a89f8);}(a1068_0x2a89,0x8d));var a1068_0xde84=function(_0x547173,_0x2a89f8){_0x547173=_0x547173-0x0;var _0xde840f=a1068_0x2a89[_0x547173];return _0xde840f;};var _0x3cb4fe=a1068_0xde84;'use strict';function Channel(){var _0x23253e=a1068_0xde84;this[_0x23253e('0xa')]=null,this[_0x23253e('0x5')]='',this[_0x23253e('0x17')]='',this['calleridnum']=0x0,this[_0x23253e('0x19')]='',this[_0x23253e('0x15')]=undefined,this[_0x23253e('0xf')]=undefined,this[_0x23253e('0x11')]=0x0,this[_0x23253e('0x4')]='',this[_0x23253e('0xe')]=0x0,this[_0x23253e('0x16')]=0x0,this[_0x23253e('0x10')]=0x0,this['answered']=![],this[_0x23253e('0x13')]=null,this[_0x23253e('0x1')]=null,this['unmanaged']=![],this['abandoned']=![],this[_0x23253e('0x18')]='',this[_0x23253e('0x14')]='',this[_0x23253e('0x1a')]=0x0,this[_0x23253e('0x1b')]=0x0,this[_0x23253e('0x12')]=0x0,this[_0x23253e('0x8')]=null,this[_0x23253e('0x9')]=null,this[_0x23253e('0x7')]=null,this[_0x23253e('0xc')]=![],this[_0x23253e('0x3')]=null,this[_0x23253e('0x6')]=null,this['monitors']=[],this[_0x23253e('0x0')]=undefined,this[_0x23253e('0xd')]=undefined,this[_0x23253e('0xb')]=0x0;}module[_0x3cb4fe('0x2')]=Channel; \ No newline at end of file diff --git a/server/services/ami/model/deskAccount.js b/server/services/ami/model/deskAccount.js index f6859b7..8e764c9 100644 --- a/server/services/ami/model/deskAccount.js +++ b/server/services/ami/model/deskAccount.js @@ -1 +1 @@ -var a1069_0x3343=['consumerKey','serverUrl','exports','consumerSecret','token','name','Configurations','type','authType','password','tokenSecret','username'];(function(_0x2a7c69,_0x334383){var _0x27d92b=function(_0x3ee9ad){while(--_0x3ee9ad){_0x2a7c69['push'](_0x2a7c69['shift']());}};_0x27d92b(++_0x334383);}(a1069_0x3343,0xe5));var a1069_0x27d9=function(_0x2a7c69,_0x334383){_0x2a7c69=_0x2a7c69-0x0;var _0x27d92b=a1069_0x3343[_0x2a7c69];return _0x27d92b;};var _0x4a9018=a1069_0x27d9;'use strict';function DeskAccount(_0x3ee9ad){var _0x5b6c97=a1069_0x27d9;this['id']=_0x3ee9ad['id']||0x0,this['name']=_0x3ee9ad[_0x5b6c97('0x4')]||'',this[_0x5b6c97('0xa')]=_0x3ee9ad[_0x5b6c97('0xa')]||'',this['remoteUri']=_0x3ee9ad['remoteUri']||'',this[_0x5b6c97('0x7')]=_0x3ee9ad[_0x5b6c97('0x7')]||'',this[_0x5b6c97('0x8')]=_0x3ee9ad['password']||'',this[_0x5b6c97('0xb')]=_0x3ee9ad[_0x5b6c97('0xb')]||'',this[_0x5b6c97('0x2')]=_0x3ee9ad[_0x5b6c97('0x2')]||'',this[_0x5b6c97('0x3')]=_0x3ee9ad[_0x5b6c97('0x3')]||'',this[_0x5b6c97('0x9')]=_0x3ee9ad[_0x5b6c97('0x9')]||'',this['type']=_0x3ee9ad[_0x5b6c97('0x6')]||'',this[_0x5b6c97('0x0')]=_0x3ee9ad[_0x5b6c97('0x0')]||'',this[_0x5b6c97('0x5')]=_0x3ee9ad[_0x5b6c97('0x5')]||{};}module[_0x4a9018('0x1')]=DeskAccount; \ No newline at end of file +var a1069_0x425a=['token','remoteUri','tokenSecret','type','authType','consumerKey','password','name','username','Configurations','exports','serverUrl','consumerSecret'];(function(_0x3f379e,_0x425a02){var _0x17f1df=function(_0x3272c3){while(--_0x3272c3){_0x3f379e['push'](_0x3f379e['shift']());}};_0x17f1df(++_0x425a02);}(a1069_0x425a,0x164));var a1069_0x17f1=function(_0x3f379e,_0x425a02){_0x3f379e=_0x3f379e-0x0;var _0x17f1df=a1069_0x425a[_0x3f379e];return _0x17f1df;};var _0x2f33bd=a1069_0x17f1;'use strict';function DeskAccount(_0x3272c3){var _0x36bbd2=a1069_0x17f1;this['id']=_0x3272c3['id']||0x0,this[_0x36bbd2('0x2')]=_0x3272c3[_0x36bbd2('0x2')]||'',this['username']=_0x3272c3[_0x36bbd2('0x3')]||'',this[_0x36bbd2('0x9')]=_0x3272c3[_0x36bbd2('0x9')]||'',this[_0x36bbd2('0xc')]=_0x3272c3['authType']||'',this[_0x36bbd2('0x1')]=_0x3272c3[_0x36bbd2('0x1')]||'',this['consumerKey']=_0x3272c3[_0x36bbd2('0x0')]||'',this[_0x36bbd2('0x7')]=_0x3272c3[_0x36bbd2('0x7')]||'',this[_0x36bbd2('0x8')]=_0x3272c3[_0x36bbd2('0x8')]||'',this[_0x36bbd2('0xa')]=_0x3272c3['tokenSecret']||'',this[_0x36bbd2('0xb')]=_0x3272c3[_0x36bbd2('0xb')]||'',this[_0x36bbd2('0x6')]=_0x3272c3[_0x36bbd2('0x6')]||'',this[_0x36bbd2('0x4')]=_0x3272c3['Configurations']||{};}module[_0x2f33bd('0x5')]=DeskAccount; \ No newline at end of file diff --git a/server/services/ami/model/dynamics365Account.js b/server/services/ami/model/dynamics365Account.js index eb7dd8e..1c6d449 100644 --- a/server/services/ami/model/dynamics365Account.js +++ b/server/services/ami/model/dynamics365Account.js @@ -1 +1 @@ -var a1070_0x295d=['serverUrl','password','tenantId','exports','clientSecret','clientId','name','username','Configurations','remoteUri'];(function(_0x2c3fe3,_0x295d2d){var _0x11f9e4=function(_0x3d273d){while(--_0x3d273d){_0x2c3fe3['push'](_0x2c3fe3['shift']());}};_0x11f9e4(++_0x295d2d);}(a1070_0x295d,0x65));var a1070_0x11f9=function(_0x2c3fe3,_0x295d2d){_0x2c3fe3=_0x2c3fe3-0x0;var _0x11f9e4=a1070_0x295d[_0x2c3fe3];return _0x11f9e4;};var _0x20764e=a1070_0x11f9;'use strict';function Dynamics365Account(_0x3d273d){var _0x4262df=a1070_0x11f9;this['id']=_0x3d273d['id']||0x0,this[_0x4262df('0x5')]=_0x3d273d[_0x4262df('0x5')]||'',this[_0x4262df('0x6')]=_0x3d273d[_0x4262df('0x6')]||'',this[_0x4262df('0x0')]=_0x3d273d[_0x4262df('0x0')]||'',this[_0x4262df('0x8')]=_0x3d273d[_0x4262df('0x8')]||'',this[_0x4262df('0x1')]=_0x3d273d[_0x4262df('0x1')]||'',this[_0x4262df('0x4')]=_0x3d273d[_0x4262df('0x4')]||'',this[_0x4262df('0x3')]=_0x3d273d['clientSecret']||{},this['serverUrl']=_0x3d273d[_0x4262df('0x9')]||'',this[_0x4262df('0x7')]=_0x3d273d[_0x4262df('0x7')]||{};}module[_0x20764e('0x2')]=Dynamics365Account; \ No newline at end of file +var a1070_0x7334=['name','password','clientId','exports','clientSecret','Configurations','serverUrl','remoteUri','username'];(function(_0x47514b,_0x733432){var _0x34d6a0=function(_0x116da9){while(--_0x116da9){_0x47514b['push'](_0x47514b['shift']());}};_0x34d6a0(++_0x733432);}(a1070_0x7334,0x15c));var a1070_0x34d6=function(_0x47514b,_0x733432){_0x47514b=_0x47514b-0x0;var _0x34d6a0=a1070_0x7334[_0x47514b];return _0x34d6a0;};var _0x1e1460=a1070_0x34d6;'use strict';function Dynamics365Account(_0x116da9){var _0x4edbf3=a1070_0x34d6;this['id']=_0x116da9['id']||0x0,this[_0x4edbf3('0x3')]=_0x116da9[_0x4edbf3('0x3')]||'',this[_0x4edbf3('0x2')]=_0x116da9[_0x4edbf3('0x2')]||'',this['password']=_0x116da9[_0x4edbf3('0x4')]||'',this[_0x4edbf3('0x1')]=_0x116da9[_0x4edbf3('0x1')]||'',this['tenantId']=_0x116da9['tenantId']||'',this[_0x4edbf3('0x5')]=_0x116da9['clientId']||'',this[_0x4edbf3('0x7')]=_0x116da9[_0x4edbf3('0x7')]||{},this[_0x4edbf3('0x0')]=_0x116da9['serverUrl']||'',this[_0x4edbf3('0x8')]=_0x116da9['Configurations']||{};}module[_0x1e1460('0x6')]=Dynamics365Account; \ No newline at end of file diff --git a/server/services/ami/model/faxAccount.js b/server/services/ami/model/faxAccount.js index e47d52b..314b474 100644 --- a/server/services/ami/model/faxAccount.js +++ b/server/services/ami/model/faxAccount.js @@ -1 +1 @@ -var a1071_0x2dd1=['ListId','description','minrate','maxrate','tech','exports','SIP','localstationid','faxdetect','name','Trunk','key','t38timeout','gateway','ecm','headerinfo','modem','v17,v27,v29'];(function(_0xa5ba71,_0x2dd172){var _0x245589=function(_0x39cdd8){while(--_0x39cdd8){_0xa5ba71['push'](_0xa5ba71['shift']());}};_0x245589(++_0x2dd172);}(a1071_0x2dd1,0xd3));var a1071_0x2455=function(_0xa5ba71,_0x2dd172){_0xa5ba71=_0xa5ba71-0x0;var _0x245589=a1071_0x2dd1[_0xa5ba71];return _0x245589;};var _0x39823f=a1071_0x2455;'use strict';function FaxAccount(_0x39cdd8){var _0x458921=a1071_0x2455;this['id']=_0x39cdd8['id']||0x0,this[_0x458921('0xe')]=_0x39cdd8[_0x458921('0xe')]||'',this[_0x458921('0x6')]=_0x39cdd8['description'],this[_0x458921('0x1')]=_0x39cdd8[_0x458921('0x1')],this[_0x458921('0x2')]=_0x39cdd8['headerinfo'],this['localstationid']=_0x39cdd8[_0x458921('0xc')],this[_0x458921('0x7')]=_0x39cdd8[_0x458921('0x7')]||0x960,this[_0x458921('0x8')]=_0x39cdd8[_0x458921('0x8')]||0x3840,this[_0x458921('0x3')]=_0x39cdd8[_0x458921('0x3')]||_0x458921('0x4'),this['gateway']=_0x39cdd8[_0x458921('0x0')]||'no',this[_0x458921('0xd')]=_0x39cdd8[_0x458921('0xd')]||'no',this[_0x458921('0x11')]=_0x39cdd8[_0x458921('0x11')]||0x1388,this[_0x458921('0x9')]=_0x39cdd8[_0x458921('0x9')]||_0x458921('0xb'),this[_0x458921('0xf')]=_0x39cdd8[_0x458921('0xf')]?_0x39cdd8['Trunk']:undefined,this[_0x458921('0x5')]=_0x39cdd8[_0x458921('0x5')],this[_0x458921('0x10')]=_0x39cdd8[_0x458921('0x10')];}module[_0x39823f('0xa')]=FaxAccount; \ No newline at end of file +var a1071_0x2429=['headerinfo','v17,v27,v29','minrate','description','localstationid','tech','Trunk','t38timeout','name','ListId','maxrate','exports','modem','SIP','ecm','gateway'];(function(_0x9598da,_0x242992){var _0x30a353=function(_0x4d1ace){while(--_0x4d1ace){_0x9598da['push'](_0x9598da['shift']());}};_0x30a353(++_0x242992);}(a1071_0x2429,0x13a));var a1071_0x30a3=function(_0x9598da,_0x242992){_0x9598da=_0x9598da-0x0;var _0x30a353=a1071_0x2429[_0x9598da];return _0x30a353;};var _0x3bd85e=a1071_0x30a3;'use strict';function FaxAccount(_0x4d1ace){var _0x123581=a1071_0x30a3;this['id']=_0x4d1ace['id']||0x0,this[_0x123581('0xe')]=_0x4d1ace[_0x123581('0xe')]||'',this[_0x123581('0x9')]=_0x4d1ace[_0x123581('0x9')],this[_0x123581('0x4')]=_0x4d1ace[_0x123581('0x4')],this[_0x123581('0x6')]=_0x4d1ace[_0x123581('0x6')],this[_0x123581('0xa')]=_0x4d1ace[_0x123581('0xa')],this['minrate']=_0x4d1ace[_0x123581('0x8')]||0x960,this[_0x123581('0x0')]=_0x4d1ace[_0x123581('0x0')]||0x3840,this[_0x123581('0x2')]=_0x4d1ace[_0x123581('0x2')]||_0x123581('0x7'),this[_0x123581('0x5')]=_0x4d1ace['gateway']||'no',this['faxdetect']=_0x4d1ace['faxdetect']||'no',this[_0x123581('0xd')]=_0x4d1ace[_0x123581('0xd')]||0x1388,this[_0x123581('0xb')]=_0x4d1ace[_0x123581('0xb')]||_0x123581('0x3'),this['Trunk']=_0x4d1ace[_0x123581('0xc')]?_0x4d1ace[_0x123581('0xc')]:undefined,this[_0x123581('0xf')]=_0x4d1ace[_0x123581('0xf')],this['key']=_0x4d1ace['key'];}module[_0x3bd85e('0x1')]=FaxAccount; \ No newline at end of file diff --git a/server/services/ami/model/freshdeskAccount.js b/server/services/ami/model/freshdeskAccount.js index a0acf31..190c63e 100644 --- a/server/services/ami/model/freshdeskAccount.js +++ b/server/services/ami/model/freshdeskAccount.js @@ -1 +1 @@ -var a1072_0x433a=['Configurations','name','serverUrl','username','token','remoteUri','exports'];(function(_0x38b0eb,_0x433ac2){var _0x319728=function(_0x48244e){while(--_0x48244e){_0x38b0eb['push'](_0x38b0eb['shift']());}};_0x319728(++_0x433ac2);}(a1072_0x433a,0x199));var a1072_0x3197=function(_0x38b0eb,_0x433ac2){_0x38b0eb=_0x38b0eb-0x0;var _0x319728=a1072_0x433a[_0x38b0eb];return _0x319728;};var _0x2dd5d1=a1072_0x3197;'use strict';function FreshdeskAccount(_0x48244e){var _0x17a504=a1072_0x3197;this['id']=_0x48244e['id']||0x0,this[_0x17a504('0x5')]=_0x48244e[_0x17a504('0x5')]||'',this[_0x17a504('0x0')]=_0x48244e[_0x17a504('0x0')]||'',this['apiKey']=_0x48244e[_0x17a504('0x1')]||'',this[_0x17a504('0x2')]=_0x48244e[_0x17a504('0x2')]||'',this[_0x17a504('0x6')]=_0x48244e[_0x17a504('0x6')]||'',this[_0x17a504('0x4')]=_0x48244e['Configurations']||{};}module[_0x2dd5d1('0x3')]=FreshdeskAccount; \ No newline at end of file +var a1072_0x320f=['exports','username','remoteUri','apiKey','token','name','Configurations'];(function(_0x35d5b2,_0x320f03){var _0x1f741e=function(_0x6a0195){while(--_0x6a0195){_0x35d5b2['push'](_0x35d5b2['shift']());}};_0x1f741e(++_0x320f03);}(a1072_0x320f,0x85));var a1072_0x1f74=function(_0x35d5b2,_0x320f03){_0x35d5b2=_0x35d5b2-0x0;var _0x1f741e=a1072_0x320f[_0x35d5b2];return _0x1f741e;};var _0x7fbca=a1072_0x1f74;'use strict';function FreshdeskAccount(_0x6a0195){var _0x1d4f3d=a1072_0x1f74;this['id']=_0x6a0195['id']||0x0,this[_0x1d4f3d('0x5')]=_0x6a0195[_0x1d4f3d('0x5')]||'',this[_0x1d4f3d('0x1')]=_0x6a0195['username']||'',this[_0x1d4f3d('0x3')]=_0x6a0195[_0x1d4f3d('0x4')]||'',this[_0x1d4f3d('0x2')]=_0x6a0195[_0x1d4f3d('0x2')]||'',this['serverUrl']=_0x6a0195['serverUrl']||'',this[_0x1d4f3d('0x6')]=_0x6a0195[_0x1d4f3d('0x6')]||{};}module[_0x7fbca('0x0')]=FreshdeskAccount; \ No newline at end of file diff --git a/server/services/ami/model/freshsalesAccount.js b/server/services/ami/model/freshsalesAccount.js index b2c2328..974b8f4 100644 --- a/server/services/ami/model/freshsalesAccount.js +++ b/server/services/ami/model/freshsalesAccount.js @@ -1 +1 @@ -var a1073_0x156e=['remoteUri','name','serverUrl','exports','token','Configurations','apiKey','username'];(function(_0x1b745e,_0x156eb2){var _0x1388b3=function(_0x244134){while(--_0x244134){_0x1b745e['push'](_0x1b745e['shift']());}};_0x1388b3(++_0x156eb2);}(a1073_0x156e,0x173));var a1073_0x1388=function(_0x1b745e,_0x156eb2){_0x1b745e=_0x1b745e-0x0;var _0x1388b3=a1073_0x156e[_0x1b745e];return _0x1388b3;};var _0x4804ba=a1073_0x1388;'use strict';function FreshsalesAccount(_0x244134){var _0x4e7aa7=a1073_0x1388;this['id']=_0x244134['id']||0x0,this[_0x4e7aa7('0x6')]=_0x244134[_0x4e7aa7('0x6')]||'',this['username']=_0x244134[_0x4e7aa7('0x4')]||'',this[_0x4e7aa7('0x3')]=_0x244134[_0x4e7aa7('0x1')]||'',this[_0x4e7aa7('0x5')]=_0x244134[_0x4e7aa7('0x5')]||'',this[_0x4e7aa7('0x7')]=_0x244134[_0x4e7aa7('0x7')]||'',this['Configurations']=_0x244134[_0x4e7aa7('0x2')]||{};}module[_0x4804ba('0x0')]=FreshsalesAccount; \ No newline at end of file +var a1073_0x3c86=['exports','remoteUri','apiKey','username','serverUrl','Configurations','token'];(function(_0x4c359a,_0x3c86f8){var _0x595a02=function(_0x56b44e){while(--_0x56b44e){_0x4c359a['push'](_0x4c359a['shift']());}};_0x595a02(++_0x3c86f8);}(a1073_0x3c86,0x1d6));var a1073_0x595a=function(_0x4c359a,_0x3c86f8){_0x4c359a=_0x4c359a-0x0;var _0x595a02=a1073_0x3c86[_0x4c359a];return _0x595a02;};var _0x26e077=a1073_0x595a;'use strict';function FreshsalesAccount(_0x56b44e){var _0x47730e=a1073_0x595a;this['id']=_0x56b44e['id']||0x0,this['name']=_0x56b44e['name']||'',this[_0x47730e('0x2')]=_0x56b44e[_0x47730e('0x2')]||'',this[_0x47730e('0x1')]=_0x56b44e[_0x47730e('0x5')]||'',this[_0x47730e('0x0')]=_0x56b44e[_0x47730e('0x0')]||'',this[_0x47730e('0x3')]=_0x56b44e[_0x47730e('0x3')]||'',this[_0x47730e('0x4')]=_0x56b44e[_0x47730e('0x4')]||{};}module[_0x26e077('0x6')]=FreshsalesAccount; \ No newline at end of file diff --git a/server/services/ami/model/queueReport.js b/server/services/ami/model/queueReport.js index 033b6d7..a23ba53 100644 --- a/server/services/ami/model/queueReport.js +++ b/server/services/ami/model/queueReport.js @@ -1 +1 @@ -var a1074_0x15a5=['lastAssignedTo','exten','type','calleridname','holdtime','queuecallerexitAt','calleridnum','connectedlinenum','assigned','context','position','count','queuecallercomplete','originalposition','queuecallerabandon','uniqueid','queue','queuecallerleaveAt','connectedlinename','priority'];(function(_0x556ddb,_0x15a572){var _0x335ab7=function(_0x15a567){while(--_0x15a567){_0x556ddb['push'](_0x556ddb['shift']());}};_0x335ab7(++_0x15a572);}(a1074_0x15a5,0x1c6));var a1074_0x335a=function(_0x556ddb,_0x15a572){_0x556ddb=_0x556ddb-0x0;var _0x335ab7=a1074_0x15a5[_0x556ddb];return _0x335ab7;};'use strict';function QueueReport(){var _0x16cf44=a1074_0x335a;this[_0x16cf44('0x8')]='inbound',this[_0x16cf44('0x1')]='',this[_0x16cf44('0xc')]='',this[_0x16cf44('0x9')]='',this[_0x16cf44('0x2')]='',this['queuecallerjoinAt']=null,this[_0x16cf44('0x3')]=null,this[_0x16cf44('0x10')]=0x1,this[_0x16cf44('0x11')]=0x1,this[_0x16cf44('0x0')]=![],this['queuecallerabandonAt']=null,this[_0x16cf44('0x12')]=![],this['queuecallercompleteAt']=null,this['queuecallerexit']=![],this[_0x16cf44('0xb')]=null,this[_0x16cf44('0x13')]=0x1,this['channel']='',this[_0x16cf44('0xd')]='',this[_0x16cf44('0x4')]='',this['accountcode']='',this[_0x16cf44('0xf')]='',this[_0x16cf44('0x7')]='',this[_0x16cf44('0x5')]='',this[_0x16cf44('0xa')]=0x0,this[_0x16cf44('0xe')]=![],this[_0x16cf44('0x6')]='',this['mohtime']=0x0,this['variables']={};}module['exports']=QueueReport; \ No newline at end of file +var a1074_0x5abe=['lastAssignedTo','queuecallerabandonAt','context','mohtime','channel','exports','queuecallerexitAt','holdtime','queuecallercompleteAt','count','connectedlinename','queuecallercomplete','priority','calleridnum','queuecallerjoinAt','queue','accountcode','inbound','type','queuecallerabandon','queuecallerleaveAt','exten','assigned','connectedlinenum','queuecallerexit'];(function(_0x163a36,_0x5abe1f){var _0x29f684=function(_0x1a911){while(--_0x1a911){_0x163a36['push'](_0x163a36['shift']());}};_0x29f684(++_0x5abe1f);}(a1074_0x5abe,0x6b));var a1074_0x29f6=function(_0x163a36,_0x5abe1f){_0x163a36=_0x163a36-0x0;var _0x29f684=a1074_0x5abe[_0x163a36];return _0x29f684;};var _0x101384=a1074_0x29f6;'use strict';function QueueReport(){var _0x4c726a=a1074_0x29f6;this[_0x4c726a('0xb')]=_0x4c726a('0xa'),this['uniqueid']='',this[_0x4c726a('0x6')]='',this['calleridname']='',this[_0x4c726a('0x8')]='',this[_0x4c726a('0x7')]=null,this[_0x4c726a('0xd')]=null,this['position']=0x1,this[_0x4c726a('0x2')]=0x1,this[_0x4c726a('0xc')]=![],this[_0x4c726a('0x13')]=null,this[_0x4c726a('0x4')]=![],this[_0x4c726a('0x1')]=null,this[_0x4c726a('0x11')]=![],this[_0x4c726a('0x18')]=null,this['originalposition']=0x1,this[_0x4c726a('0x16')]='',this[_0x4c726a('0x10')]='',this[_0x4c726a('0x3')]='',this[_0x4c726a('0x9')]='',this[_0x4c726a('0x14')]='',this[_0x4c726a('0xe')]='',this[_0x4c726a('0x5')]='',this[_0x4c726a('0x0')]=0x0,this[_0x4c726a('0xf')]=![],this[_0x4c726a('0x12')]='',this[_0x4c726a('0x15')]=0x0,this['variables']={};}module[_0x101384('0x17')]=QueueReport; \ No newline at end of file diff --git a/server/services/ami/model/salesforceAccount.js b/server/services/ami/model/salesforceAccount.js index 0f52440..4afe2ef 100644 --- a/server/services/ami/model/salesforceAccount.js +++ b/server/services/ami/model/salesforceAccount.js @@ -1 +1 @@ -var a1075_0x4447=['Configurations','type','exports','clientSecret','clientId','serverUrl','username','securityToken','password','name','remoteUri'];(function(_0x7420f0,_0x444783){var _0x39660a=function(_0x2f2971){while(--_0x2f2971){_0x7420f0['push'](_0x7420f0['shift']());}};_0x39660a(++_0x444783);}(a1075_0x4447,0x14e));var a1075_0x3966=function(_0x7420f0,_0x444783){_0x7420f0=_0x7420f0-0x0;var _0x39660a=a1075_0x4447[_0x7420f0];return _0x39660a;};var _0x1db9bd=a1075_0x3966;'use strict';function SalesforceAccount(_0x2f2971){var _0x139291=a1075_0x3966;this['id']=_0x2f2971['id']||0x0,this[_0x139291('0x5')]=_0x2f2971[_0x139291('0x5')]||'',this['username']=_0x2f2971[_0x139291('0x2')]||'',this[_0x139291('0x6')]=_0x2f2971[_0x139291('0x6')]||'',this[_0x139291('0x4')]=_0x2f2971[_0x139291('0x4')]||'',this[_0x139291('0x0')]=_0x2f2971[_0x139291('0x0')]||'',this[_0x139291('0xa')]=_0x2f2971[_0x139291('0xa')]||'',this['securityToken']=_0x2f2971[_0x139291('0x3')]||'',this[_0x139291('0x8')]=_0x2f2971['type']||'integrationTab',this[_0x139291('0x1')]=_0x2f2971[_0x139291('0x1')]||'',this[_0x139291('0x7')]=_0x2f2971[_0x139291('0x7')]||{};}module[_0x1db9bd('0x9')]=SalesforceAccount; \ No newline at end of file +var a1075_0x5cfb=['clientId','name','exports','serverUrl','securityToken','type','remoteUri','integrationTab','Configurations','clientSecret','password'];(function(_0xa50dc,_0x5cfb87){var _0x5de3e3=function(_0x5a6fa9){while(--_0x5a6fa9){_0xa50dc['push'](_0xa50dc['shift']());}};_0x5de3e3(++_0x5cfb87);}(a1075_0x5cfb,0x1e1));var a1075_0x5de3=function(_0xa50dc,_0x5cfb87){_0xa50dc=_0xa50dc-0x0;var _0x5de3e3=a1075_0x5cfb[_0xa50dc];return _0x5de3e3;};var _0x5adde9=a1075_0x5de3;'use strict';function SalesforceAccount(_0x5a6fa9){var _0x309c3b=a1075_0x5de3;this['id']=_0x5a6fa9['id']||0x0,this[_0x309c3b('0x4')]=_0x5a6fa9[_0x309c3b('0x4')]||'',this['username']=_0x5a6fa9['username']||'',this[_0x309c3b('0x9')]=_0x5a6fa9[_0x309c3b('0x9')]||'',this[_0x309c3b('0x2')]=_0x5a6fa9[_0x309c3b('0x2')]||'',this[_0x309c3b('0x3')]=_0x5a6fa9[_0x309c3b('0x3')]||'',this['clientSecret']=_0x5a6fa9[_0x309c3b('0x1')]||'',this[_0x309c3b('0x7')]=_0x5a6fa9[_0x309c3b('0x7')]||'',this[_0x309c3b('0x8')]=_0x5a6fa9[_0x309c3b('0x8')]||_0x309c3b('0xa'),this['serverUrl']=_0x5a6fa9[_0x309c3b('0x6')]||'',this['Configurations']=_0x5a6fa9[_0x309c3b('0x0')]||{};}module[_0x5adde9('0x5')]=SalesforceAccount; \ No newline at end of file diff --git a/server/services/ami/model/servicenowAccount.js b/server/services/ami/model/servicenowAccount.js index c250083..0f4362e 100644 --- a/server/services/ami/model/servicenowAccount.js +++ b/server/services/ami/model/servicenowAccount.js @@ -1 +1 @@ -var a1076_0x41cb=['Configurations','remoteUri','password','serverUrl','username'];(function(_0x5e3068,_0x41cbe6){var _0x1ae8da=function(_0x3cd837){while(--_0x3cd837){_0x5e3068['push'](_0x5e3068['shift']());}};_0x1ae8da(++_0x41cbe6);}(a1076_0x41cb,0x8a));var a1076_0x1ae8=function(_0x5e3068,_0x41cbe6){_0x5e3068=_0x5e3068-0x0;var _0x1ae8da=a1076_0x41cb[_0x5e3068];return _0x1ae8da;};'use strict';function ServicenowAccount(_0x3cd837){var _0x58cdbd=a1076_0x1ae8;this['id']=_0x3cd837['id']||0x0,this['name']=_0x3cd837['name']||'',this[_0x58cdbd('0x1')]=_0x3cd837['username']||'',this['password']=_0x3cd837[_0x58cdbd('0x4')]||'',this[_0x58cdbd('0x3')]=_0x3cd837[_0x58cdbd('0x3')]||'',this[_0x58cdbd('0x0')]=_0x3cd837[_0x58cdbd('0x0')]||'',this[_0x58cdbd('0x2')]=_0x3cd837[_0x58cdbd('0x2')]||{};}module['exports']=ServicenowAccount; \ No newline at end of file +var a1076_0x21e0=['remoteUri','name','password','username','Configurations','serverUrl','exports'];(function(_0x3506f5,_0x21e0c0){var _0xc39ab7=function(_0x482c57){while(--_0x482c57){_0x3506f5['push'](_0x3506f5['shift']());}};_0xc39ab7(++_0x21e0c0);}(a1076_0x21e0,0x166));var a1076_0xc39a=function(_0x3506f5,_0x21e0c0){_0x3506f5=_0x3506f5-0x0;var _0xc39ab7=a1076_0x21e0[_0x3506f5];return _0xc39ab7;};var _0x542155=a1076_0xc39a;'use strict';function ServicenowAccount(_0x482c57){var _0x56981b=a1076_0xc39a;this['id']=_0x482c57['id']||0x0,this['name']=_0x482c57[_0x56981b('0x0')]||'',this[_0x56981b('0x2')]=_0x482c57[_0x56981b('0x2')]||'',this['password']=_0x482c57[_0x56981b('0x1')]||'',this[_0x56981b('0x6')]=_0x482c57[_0x56981b('0x6')]||'',this[_0x56981b('0x4')]=_0x482c57[_0x56981b('0x4')]||'',this[_0x56981b('0x3')]=_0x482c57[_0x56981b('0x3')]||{};}module[_0x542155('0x5')]=ServicenowAccount; \ No newline at end of file diff --git a/server/services/ami/model/sugarcrmAccount.js b/server/services/ami/model/sugarcrmAccount.js index 23235dc..c991fb0 100644 --- a/server/services/ami/model/sugarcrmAccount.js +++ b/server/services/ami/model/sugarcrmAccount.js @@ -1 +1 @@ -var a1077_0x5ae8=['password','serverUrl','username','Configurations','name','remoteUri'];(function(_0x2607e9,_0x5ae8de){var _0x97d81=function(_0x55c52d){while(--_0x55c52d){_0x2607e9['push'](_0x2607e9['shift']());}};_0x97d81(++_0x5ae8de);}(a1077_0x5ae8,0xc3));var a1077_0x97d8=function(_0x2607e9,_0x5ae8de){_0x2607e9=_0x2607e9-0x0;var _0x97d81=a1077_0x5ae8[_0x2607e9];return _0x97d81;};'use strict';function SugarcrmAccount(_0x55c52d){var _0x1b06b8=a1077_0x97d8;this['id']=_0x55c52d['id']||0x0,this[_0x1b06b8('0x1')]=_0x55c52d[_0x1b06b8('0x1')]||'',this[_0x1b06b8('0x5')]=_0x55c52d[_0x1b06b8('0x5')]||'',this[_0x1b06b8('0x3')]=_0x55c52d[_0x1b06b8('0x3')]||'',this[_0x1b06b8('0x2')]=_0x55c52d[_0x1b06b8('0x2')]||'',this[_0x1b06b8('0x4')]=_0x55c52d[_0x1b06b8('0x4')]||'',this[_0x1b06b8('0x0')]=_0x55c52d[_0x1b06b8('0x0')]||{};}module['exports']=SugarcrmAccount; \ No newline at end of file +var a1077_0x276a=['serverUrl','password','username','Configurations','name','remoteUri'];(function(_0x1bf8ef,_0x276ad1){var _0x321145=function(_0xf56b6e){while(--_0xf56b6e){_0x1bf8ef['push'](_0x1bf8ef['shift']());}};_0x321145(++_0x276ad1);}(a1077_0x276a,0x123));var a1077_0x3211=function(_0x1bf8ef,_0x276ad1){_0x1bf8ef=_0x1bf8ef-0x0;var _0x321145=a1077_0x276a[_0x1bf8ef];return _0x321145;};'use strict';function SugarcrmAccount(_0xf56b6e){var _0x213746=a1077_0x3211;this['id']=_0xf56b6e['id']||0x0,this['name']=_0xf56b6e[_0x213746('0x1')]||'',this['username']=_0xf56b6e[_0x213746('0x5')]||'',this['password']=_0xf56b6e[_0x213746('0x4')]||'',this[_0x213746('0x2')]=_0xf56b6e[_0x213746('0x2')]||'',this['serverUrl']=_0xf56b6e[_0x213746('0x3')]||'',this[_0x213746('0x0')]=_0xf56b6e[_0x213746('0x0')]||{};}module['exports']=SugarcrmAccount; \ No newline at end of file diff --git a/server/services/ami/model/telephone.js b/server/services/ami/model/telephone.js index 37a3a8b..233a679 100644 --- a/server/services/ami/model/telephone.js +++ b/server/services/ami/model/telephone.js @@ -1 +1 @@ -var a1078_0x35ab=['stateTime','exports','address','accountcode','status','unknown','name'];(function(_0x8e87a3,_0x35aba2){var _0x3574c6=function(_0x3c487a){while(--_0x3c487a){_0x8e87a3['push'](_0x8e87a3['shift']());}};_0x3574c6(++_0x35aba2);}(a1078_0x35ab,0xac));var a1078_0x3574=function(_0x8e87a3,_0x35aba2){_0x8e87a3=_0x8e87a3-0x0;var _0x3574c6=a1078_0x35ab[_0x8e87a3];return _0x3574c6;};var _0x36c5b0=a1078_0x3574;'use strict';function Telephone(_0x3c487a){var _0x40793f=a1078_0x3574;this['id']=_0x3c487a['id']||0x0,this[_0x40793f('0x2')]=_0x3c487a[_0x40793f('0x2')]||'',this[_0x40793f('0x6')]=_0x3c487a['accountcode']||'',this['state']=_0x40793f('0x1'),this[_0x40793f('0x3')]=0x0,this[_0x40793f('0x0')]=_0x40793f('0x1'),this[_0x40793f('0x5')]='';}module[_0x36c5b0('0x4')]=Telephone; \ No newline at end of file +var a1078_0x5d34=['unknown','accountcode','name','stateTime','status','state'];(function(_0x38c54e,_0x5d3428){var _0xfe2037=function(_0xcf4d23){while(--_0xcf4d23){_0x38c54e['push'](_0x38c54e['shift']());}};_0xfe2037(++_0x5d3428);}(a1078_0x5d34,0xba));var a1078_0xfe20=function(_0x38c54e,_0x5d3428){_0x38c54e=_0x38c54e-0x0;var _0xfe2037=a1078_0x5d34[_0x38c54e];return _0xfe2037;};'use strict';function Telephone(_0xcf4d23){var _0x4a2f52=a1078_0xfe20;this['id']=_0xcf4d23['id']||0x0,this[_0x4a2f52('0x2')]=_0xcf4d23[_0x4a2f52('0x2')]||'',this[_0x4a2f52('0x1')]=_0xcf4d23[_0x4a2f52('0x1')]||'',this[_0x4a2f52('0x5')]=_0x4a2f52('0x0'),this[_0x4a2f52('0x3')]=0x0,this[_0x4a2f52('0x4')]=_0x4a2f52('0x0'),this['address']='';}module['exports']=Telephone; \ No newline at end of file diff --git a/server/services/ami/model/template.js b/server/services/ami/model/template.js index 49a15ed..2cfbdb9 100644 --- a/server/services/ami/model/template.js +++ b/server/services/ami/model/template.js @@ -1 +1 @@ -var a1079_0x1387=['exports','html','name'];(function(_0x22add9,_0x1387b8){var _0x17f3de=function(_0x33227a){while(--_0x33227a){_0x22add9['push'](_0x22add9['shift']());}};_0x17f3de(++_0x1387b8);}(a1079_0x1387,0xff));var a1079_0x17f3=function(_0x22add9,_0x1387b8){_0x22add9=_0x22add9-0x0;var _0x17f3de=a1079_0x1387[_0x22add9];return _0x17f3de;};var _0x191c98=a1079_0x17f3;'use strict';function template(_0x33227a){var _0x56b51b=a1079_0x17f3;this['id']=_0x33227a['id']||0x0,this['name']=_0x33227a[_0x56b51b('0x2')]||'',this[_0x56b51b('0x1')]=_0x33227a[_0x56b51b('0x1')]||'';}module[_0x191c98('0x0')]=template; \ No newline at end of file +var a1079_0x3634=['html','name'];(function(_0x300975,_0x36345e){var _0x17e2f1=function(_0x12f1a1){while(--_0x12f1a1){_0x300975['push'](_0x300975['shift']());}};_0x17e2f1(++_0x36345e);}(a1079_0x3634,0x101));var a1079_0x17e2=function(_0x300975,_0x36345e){_0x300975=_0x300975-0x0;var _0x17e2f1=a1079_0x3634[_0x300975];return _0x17e2f1;};'use strict';function template(_0x12f1a1){var _0x36fa09=a1079_0x17e2;this['id']=_0x12f1a1['id']||0x0,this[_0x36fa09('0x0')]=_0x12f1a1[_0x36fa09('0x0')]||'',this[_0x36fa09('0x1')]=_0x12f1a1['html']||'';}module['exports']=template; \ No newline at end of file diff --git a/server/services/ami/model/trigger.js b/server/services/ami/model/trigger.js index f14f895..f66d3b4 100644 --- a/server/services/ami/model/trigger.js +++ b/server/services/ami/model/trigger.js @@ -1 +1 @@ -var a1080_0x277d=['AllConditions','status','AnyConditions','channel','name','voice'];(function(_0x349444,_0x277df1){var _0x1ee710=function(_0x155b02){while(--_0x155b02){_0x349444['push'](_0x349444['shift']());}};_0x1ee710(++_0x277df1);}(a1080_0x277d,0x16a));var a1080_0x1ee7=function(_0x349444,_0x277df1){_0x349444=_0x349444-0x0;var _0x1ee710=a1080_0x277d[_0x349444];return _0x1ee710;};'use strict';function Trigger(_0x155b02){var _0x5a4480=a1080_0x1ee7;this['id']=_0x155b02['id']||0x0,this[_0x5a4480('0x2')]=_0x155b02[_0x5a4480('0x2')]||'',this[_0x5a4480('0x1')]=_0x155b02[_0x5a4480('0x1')]||_0x5a4480('0x3'),this[_0x5a4480('0x5')]=_0x155b02[_0x5a4480('0x5')]||![],this[_0x5a4480('0x4')]=_0x155b02[_0x5a4480('0x4')]||[],this[_0x5a4480('0x0')]=_0x155b02[_0x5a4480('0x0')]||[],this['Actions']=_0x155b02['Actions']||[];}module['exports']=Trigger; \ No newline at end of file +var a1080_0x5f30=['AnyConditions','status','AllConditions','Actions','name','channel','exports'];(function(_0x2601ff,_0x5f304f){var _0x3c160b=function(_0xb80299){while(--_0xb80299){_0x2601ff['push'](_0x2601ff['shift']());}};_0x3c160b(++_0x5f304f);}(a1080_0x5f30,0x18e));var a1080_0x3c16=function(_0x2601ff,_0x5f304f){_0x2601ff=_0x2601ff-0x0;var _0x3c160b=a1080_0x5f30[_0x2601ff];return _0x3c160b;};var _0x358126=a1080_0x3c16;'use strict';function Trigger(_0xb80299){var _0x20addf=a1080_0x3c16;this['id']=_0xb80299['id']||0x0,this[_0x20addf('0x5')]=_0xb80299[_0x20addf('0x5')]||'',this['channel']=_0xb80299[_0x20addf('0x6')]||'voice',this[_0x20addf('0x2')]=_0xb80299[_0x20addf('0x2')]||![],this[_0x20addf('0x3')]=_0xb80299[_0x20addf('0x3')]||[],this[_0x20addf('0x1')]=_0xb80299[_0x20addf('0x1')]||[],this['Actions']=_0xb80299[_0x20addf('0x4')]||[];}module[_0x358126('0x0')]=Trigger; \ No newline at end of file diff --git a/server/services/ami/model/trunk.js b/server/services/ami/model/trunk.js index 9734e7f..6671881 100644 --- a/server/services/ami/model/trunk.js +++ b/server/services/ami/model/trunk.js @@ -1 +1 @@ -var a1081_0x8628=['stateTime','status','name','domainport','unknown','stateRegistry','registry','host','exports','active','split','port','indexOf','state','domain','registrationtime'];(function(_0x2411c8,_0x8628dc){var _0x16ef10=function(_0x4126a4){while(--_0x4126a4){_0x2411c8['push'](_0x2411c8['shift']());}};_0x16ef10(++_0x8628dc);}(a1081_0x8628,0x1a5));var a1081_0x16ef=function(_0x2411c8,_0x8628dc){_0x2411c8=_0x2411c8-0x0;var _0x16ef10=a1081_0x8628[_0x2411c8];return _0x16ef10;};var _0x4279dc=a1081_0x16ef;'use strict';function Trunk(_0x4126a4){var _0x24a73b=a1081_0x16ef;this['id']=_0x4126a4['id']||0x0,this[_0x24a73b('0x4')]=_0x4126a4['active']||![],this[_0x24a73b('0xd')]=_0x4126a4[_0x24a73b('0xd')]||'',this[_0x24a73b('0x8')]='unknown',this[_0x24a73b('0xb')]=0x0,this[_0x24a73b('0xc')]=_0x24a73b('0xf'),this['registry']=_0x4126a4[_0x24a73b('0x1')]&&_0x4126a4['registry'][_0x24a73b('0x7')](':')?_0x4126a4[_0x24a73b('0x1')][_0x24a73b('0x5')](':')[0x0]:'',this[_0x24a73b('0x2')]='',this[_0x24a73b('0x6')]='',this[_0x24a73b('0x9')]='',this[_0x24a73b('0xe')]='',this['refresh']='',this[_0x24a73b('0x0')]=_0x24a73b('0xf'),this[_0x24a73b('0xa')]='',this['address']='';}module[_0x4279dc('0x3')]=Trunk; \ No newline at end of file +var a1081_0x5647=['stateTime','name','refresh','port','indexOf','state','host','unknown','registry','registrationtime','address','domain','active'];(function(_0x292f65,_0x56470e){var _0x806131=function(_0x24efa2){while(--_0x24efa2){_0x292f65['push'](_0x292f65['shift']());}};_0x806131(++_0x56470e);}(a1081_0x5647,0xa7));var a1081_0x8061=function(_0x292f65,_0x56470e){_0x292f65=_0x292f65-0x0;var _0x806131=a1081_0x5647[_0x292f65];return _0x806131;};'use strict';function Trunk(_0x24efa2){var _0x1c0866=a1081_0x8061;this['id']=_0x24efa2['id']||0x0,this['active']=_0x24efa2[_0x1c0866('0x1')]||![],this['name']=_0x24efa2[_0x1c0866('0x3')]||'',this[_0x1c0866('0x7')]=_0x1c0866('0x9'),this[_0x1c0866('0x2')]=0x0,this['status']='unknown',this[_0x1c0866('0xa')]=_0x24efa2[_0x1c0866('0xa')]&&_0x24efa2[_0x1c0866('0xa')][_0x1c0866('0x6')](':')?_0x24efa2[_0x1c0866('0xa')]['split'](':')[0x0]:'',this[_0x1c0866('0x8')]='',this[_0x1c0866('0x5')]='',this[_0x1c0866('0x0')]='',this['domainport']='',this[_0x1c0866('0x4')]='',this['stateRegistry']='unknown',this[_0x1c0866('0xb')]='',this[_0x1c0866('0xc')]='';}module['exports']=Trunk; \ No newline at end of file diff --git a/server/services/ami/model/voiceExtension.js b/server/services/ami/model/voiceExtension.js index a4c2702..d143bae 100644 --- a/server/services/ami/model/voiceExtension.js +++ b/server/services/ami/model/voiceExtension.js @@ -1 +1 @@ -var a1082_0x2a3f=['exports','mandatoryDisposition','none','recordingFormat'];(function(_0x3e2ae4,_0x2a3f21){var _0xc55042=function(_0x5c5e63){while(--_0x5c5e63){_0x3e2ae4['push'](_0x3e2ae4['shift']());}};_0xc55042(++_0x2a3f21);}(a1082_0x2a3f,0x182));var a1082_0xc550=function(_0x3e2ae4,_0x2a3f21){_0x3e2ae4=_0x3e2ae4-0x0;var _0xc55042=a1082_0x2a3f[_0x3e2ae4];return _0xc55042;};var _0x3db54c=a1082_0xc550;'use strict';function voiceExtension(_0x5c5e63){var _0x3b48b6=a1082_0xc550;this['id']=_0x5c5e63['id']||0x0,this['exten']=_0x5c5e63['exten']||'',this[_0x3b48b6('0x1')]=_0x5c5e63[_0x3b48b6('0x1')]||_0x3b48b6('0x0'),this['mandatoryDisposition']=_0x5c5e63[_0x3b48b6('0x3')]||![];}module[_0x3db54c('0x2')]=voiceExtension; \ No newline at end of file +var a1082_0x4a5e=['recordingFormat','exten','exports','none','mandatoryDisposition'];(function(_0x347c29,_0x4a5e8b){var _0x48dd9d=function(_0x54003c){while(--_0x54003c){_0x347c29['push'](_0x347c29['shift']());}};_0x48dd9d(++_0x4a5e8b);}(a1082_0x4a5e,0x1bb));var a1082_0x48dd=function(_0x347c29,_0x4a5e8b){_0x347c29=_0x347c29-0x0;var _0x48dd9d=a1082_0x4a5e[_0x347c29];return _0x48dd9d;};var _0x372d22=a1082_0x48dd;'use strict';function voiceExtension(_0x54003c){var _0x2d1839=a1082_0x48dd;this['id']=_0x54003c['id']||0x0,this[_0x2d1839('0x3')]=_0x54003c[_0x2d1839('0x3')]||'',this['recordingFormat']=_0x54003c[_0x2d1839('0x2')]||_0x2d1839('0x0'),this[_0x2d1839('0x1')]=_0x54003c[_0x2d1839('0x1')]||![];}module[_0x372d22('0x4')]=voiceExtension; \ No newline at end of file diff --git a/server/services/ami/model/voiceQueue.js b/server/services/ami/model/voiceQueue.js index d6c925e..40cf736 100644 --- a/server/services/ami/model/voiceQueue.js +++ b/server/services/ami/model/voiceQueue.js @@ -1 +1 @@ -const a1083_0x2aad=['predictiveIntervalMinThreshold','dialAgiAfterHangupAgent','temp','dialMethod','originated','dialPrefix','queueStatusComplete','mandatoryDisposition','dialDropRetryFrequency','dialBusyRetryFrequency','dialMachineRetryFrequency','dialAMDTotalAnalysisTime','handlePredictive','dialRandomLastDigitCallerIdNumber','dialAMDMinWordLength','predictiveIntervalAvgHoldtime','dialAMDInitialSilence','dropRate','acw','dialAgiAfterHangupClient','dialAgentRejectMaxRetry','abandoned','dialNoSuchNumberRetryFrequency','dialNoAnswerRetryFrequency','predictiveIntervalMaxThreshold','startPredictive','dialAbandonedMaxRetry','dialRecallInQueue','outboundUnknownCallsDay','unmanaged','dialActive','predictiveIntervalHitRate','total','dialOrderByScheduledAt','dialBusyMaxRetry','dialLimitQueue','outboundNoAnswerCallsDay','dialDropMaxRetry','dialPredictiveOptimizationPercentage','outboundBusyCallsDay','dialAgentRejectRetryFrequency','progressive','mandatoryDispositionPause','outboundDropCallsDayACS','DESC','dialNoSuchNumberMaxRetry','predictiveIntervalAvgTalktime','startProgressive','autopause','pTalking','type','predictiveIntervalAnsweredCalls','dialOriginateCallerIdNumber','erlangCallToSecond','talking','erlangAbandonmentRate','dialQueueOptions','dialGlobalMaxRetry','roundrobin','dialTimezone','anonymous','dialPowerLevel','rrmemory','dialQueueProject','acwTimeout','dialAMDMaximumNumberOfWords','dialPredictiveInterval','dialAMDSilenceThreshold','dialAMDGreeting','dialGlobalInterval','sumDuration','dialPredictiveIntervalMaxThreshold','TrunkBackup','predictiveIntervalTotalCalls','outboundNoSuchCallsDay','monitor_format','sumHoldTime','dialCongestionMaxRetry','tTxX','dialAMDBetweenWordsSilence','dialCongestionRetryFrequency','outboundAnswerAgiCallsDay','wav','dialLimitChannel','erlangCalls','waiting','predictiveIntervalErlangCallsDroppedCalls','predictiveIntervalPauses','gsm','outboundReCallsDay','inbound','dialOriginateCallerIdName','outboundAbandonedDay','message','outboundAnswerCallsDay','strategy','dialAMDActive','Trunk','answered','outboundOriginateFailureCallsDay','wav49','erlangBusyFactor','dialAMDAfterGreetingSilence','dialCutDigit','predictiveIntervalErlangCalls','dialQueueTimeout','timeout','outboundBlacklistCallsDay','outboundDropCallsDayCallersExit','predictiveIntervalMultiplicativeFactor','dialAbandonedRetryFrequency','predictiveIntervalDroppedCallsTimeout','loggedIn','outboundDropCallsDayTimeout','dialMachineMaxRetry','predictiveIntervalDroppedCallsCallersExit','dialPredictiveOptimization','dialOriginateTimeout'];(function(_0x4e77fb,_0x2aad66){const _0x42ba84=function(_0x50db00){while(--_0x50db00){_0x4e77fb['push'](_0x4e77fb['shift']());}};_0x42ba84(++_0x2aad66);}(a1083_0x2aad,0xda));const a1083_0x42ba=function(_0x4e77fb,_0x2aad66){_0x4e77fb=_0x4e77fb-0x0;let _0x42ba84=a1083_0x2aad[_0x4e77fb];return _0x42ba84;};const _0x1ce4cd=a1083_0x42ba;'use strict';const monitorFormat={'wav':_0x1ce4cd('0x64'),'wav49':_0x1ce4cd('0x0'),'gsm':_0x1ce4cd('0x6a')},strategy={'rrmemory':'rrmemory','roundrobin':_0x1ce4cd('0x4c')};function VoiceQueue(_0x50db00){const _0x201dcd=_0x1ce4cd;this['id']=_0x50db00['id']||0x0,this['name']=_0x50db00['name']||'',this[_0x201dcd('0x5d')]=_0x50db00[_0x201dcd('0x5d')]||'',this[_0x201dcd('0x44')]=_0x50db00['type']||_0x201dcd('0x6c'),this[_0x201dcd('0x67')]=0x0,this[_0x201dcd('0x48')]=0x0,this[_0x201dcd('0x32')]=0x0,this[_0x201dcd('0x74')]=0x0,this[_0x201dcd('0x58')]=0x0,this[_0x201dcd('0x5e')]=0x0,this['sumBillable']=0x0,this[_0x201dcd('0x2f')]=0x0,this[_0x201dcd('0x27')]=0x0,this[_0x201dcd('0xc')]=0x0,this['available']=0x0,this[_0x201dcd('0x24')]=_0x50db00['acw']||![],this[_0x201dcd('0x52')]=_0x50db00[_0x201dcd('0x52')]||0xa,this[_0x201dcd('0x42')]=_0x50db00[_0x201dcd('0x42')]||'no',this['sendMessageOneNotActive']=!![],this[_0x201dcd('0x6f')]='',this[_0x201dcd('0x16')]=0x0,this[_0x201dcd('0x14')]=0x0,this[_0x201dcd('0x4d')]=_0x50db00['dialTimezone']||null,this[_0x201dcd('0x57')]=_0x50db00[_0x201dcd('0x57')]?_0x50db00['dialGlobalInterval']:null,this[_0x201dcd('0x30')]=_0x50db00[_0x201dcd('0x30')],this[_0x201dcd('0x15')]=_0x50db00['dialMethod']||_0x201dcd('0x3b'),this['dialLimitChannel']=_0x50db00[_0x201dcd('0x65')]||0x0,this[_0x201dcd('0x35')]=_0x50db00[_0x201dcd('0x35')]||0x0,this[_0x201dcd('0x4f')]=_0x50db00[_0x201dcd('0x4f')]||0x1,this[_0x201dcd('0x10')]=_0x50db00[_0x201dcd('0x10')]||_0x201dcd('0x23'),this[_0x201dcd('0x38')]=_0x50db00['dialPredictiveOptimizationPercentage']||0.03,this[_0x201dcd('0x54')]=_0x50db00[_0x201dcd('0x54')]||0x258,this[_0x201dcd('0x6d')]=_0x50db00['dialOriginateCallerIdName']||_0x201dcd('0x4e'),this[_0x201dcd('0x46')]=_0x50db00[_0x201dcd('0x46')]||_0x201dcd('0x4e'),this[_0x201dcd('0x11')]=_0x50db00[_0x201dcd('0x11')]||0x1e,this[_0x201dcd('0x4a')]=_0x50db00['dialQueueOptions']||_0x201dcd('0x60'),this[_0x201dcd('0x5')]=_0x50db00[_0x201dcd('0x5')]||0x3,this[_0x201dcd('0x51')]=_0x50db00['dialQueueProject']||undefined,this['dialCongestionMaxRetry']=_0x50db00[_0x201dcd('0x5f')]||0x3,this['dialCongestionRetryFrequency']=_0x50db00[_0x201dcd('0x62')]||0x96,this['dialBusyMaxRetry']=_0x50db00[_0x201dcd('0x34')]||0x3,this[_0x201dcd('0x1b')]=_0x50db00['dialBusyRetryFrequency']||0x96,this['dialNoAnswerMaxRetry']=_0x50db00['dialNoAnswerMaxRetry']||0x3,this[_0x201dcd('0x29')]=_0x50db00[_0x201dcd('0x29')]||0x96,this[_0x201dcd('0x3f')]=_0x50db00[_0x201dcd('0x3f')]||0x3,this[_0x201dcd('0x28')]=_0x50db00[_0x201dcd('0x28')]||0x96,this[_0x201dcd('0x37')]=_0x50db00[_0x201dcd('0x37')]||0x3,this[_0x201dcd('0x1a')]=_0x50db00[_0x201dcd('0x1a')]||0x96,this['dialAbandonedMaxRetry']=_0x50db00[_0x201dcd('0x2c')]||0x3,this[_0x201dcd('0xa')]=_0x50db00[_0x201dcd('0xa')]||0x96,this[_0x201dcd('0xe')]=_0x50db00[_0x201dcd('0xe')]||0x3,this['dialMachineRetryFrequency']=_0x50db00[_0x201dcd('0x1c')]||0x96,this[_0x201dcd('0x26')]=_0x50db00[_0x201dcd('0x26')]||0x3,this[_0x201dcd('0x3a')]=_0x50db00[_0x201dcd('0x3a')]||0x96,this['dialGlobalMaxRetry']=_0x50db00[_0x201dcd('0x4b')]||0x4,this[_0x201dcd('0x73')]=_0x50db00[_0x201dcd('0x73')]?_0x50db00[_0x201dcd('0x73')]:undefined,this['TrunkBackup']=_0x50db00['TrunkBackup']?_0x50db00[_0x201dcd('0x5a')]:undefined,this[_0x201dcd('0x17')]=_0x50db00[_0x201dcd('0x17')]||undefined,this['Interval']=_0x50db00['Interval']?_0x50db00['Interval']:undefined,this[_0x201dcd('0x33')]=_0x50db00[_0x201dcd('0x33')]||_0x201dcd('0x3e'),this[_0x201dcd('0x1f')]=_0x50db00[_0x201dcd('0x1f')]||undefined,this[_0x201dcd('0x3')]=_0x50db00[_0x201dcd('0x3')]||undefined,this[_0x201dcd('0x71')]=strategy[_0x50db00[_0x201dcd('0x71')]]||_0x201dcd('0x50'),this[_0x201dcd('0x18')]=!![],this[_0x201dcd('0x72')]=_0x50db00[_0x201dcd('0x72')]||![],this[_0x201dcd('0x22')]=_0x50db00['dialAMDInitialSilence'],this[_0x201dcd('0x56')]=_0x50db00[_0x201dcd('0x56')],this[_0x201dcd('0x2')]=_0x50db00[_0x201dcd('0x2')],this['dialAMDTotalAnalysisTime']=_0x50db00[_0x201dcd('0x1d')],this['dialAMDMinWordLength']=_0x50db00[_0x201dcd('0x20')],this[_0x201dcd('0x61')]=_0x50db00['dialAMDBetweenWordsSilence'],this[_0x201dcd('0x53')]=_0x50db00[_0x201dcd('0x53')],this[_0x201dcd('0x55')]=_0x50db00['dialAMDSilenceThreshold'],this['dialAMDMaximumWordLength']=_0x50db00['dialAMDMaximumWordLength'],this['outboundRejectCallsDay']=0x0,this[_0x201dcd('0x43')]=0x0,this[_0x201dcd('0x6')]=_0x50db00[_0x201dcd('0x6')],this[_0x201dcd('0x70')]=0x0,this[_0x201dcd('0x63')]=0x0,this[_0x201dcd('0x36')]=0x0,this[_0x201dcd('0x39')]=0x0,this['outboundCongestionCallsDay']=0x0,this[_0x201dcd('0x5c')]=0x0,this[_0x201dcd('0x2e')]=0x0,this[_0x201dcd('0x7')]=0x0,this[_0x201dcd('0x75')]=0x0,this[_0x201dcd('0x8')]=0x0,this[_0x201dcd('0xd')]=0x0,this[_0x201dcd('0x3d')]=0x0,this[_0x201dcd('0x6b')]=0x0,this[_0x201dcd('0x6e')]=0x0,this[_0x201dcd('0x41')]=undefined,this[_0x201dcd('0x2b')]=undefined,this[_0x201dcd('0x1e')]=undefined,this[_0x201dcd('0x9')]=1.05,this[_0x201dcd('0x5b')]=0x0,this[_0x201dcd('0x45')]=0x0,this[_0x201dcd('0xf')]=0x0,this[_0x201dcd('0xb')]=0x0,this[_0x201dcd('0x21')]=0x0,this[_0x201dcd('0x40')]=0x0,this[_0x201dcd('0x69')]=0x0,this['predictiveIntervalAvailable']=0x0,this[_0x201dcd('0x2a')]=_0x50db00[_0x201dcd('0x59')]||0x14,this[_0x201dcd('0x12')]=_0x50db00[_0x201dcd('0x59')]||0xa,this[_0x201dcd('0x4')]=0x0,this[_0x201dcd('0x68')]=0x0,this[_0x201dcd('0x31')]=0x1,this[_0x201dcd('0x66')]=0x0,this[_0x201dcd('0x47')]=0x0,this[_0x201dcd('0x49')]=0x0,this[_0x201dcd('0x1')]=0x0,this['dialRecallMeTimeout']=_0x50db00['dialRecallMeTimeout']||0x1e,this['dialRecallInQueue']=_0x50db00[_0x201dcd('0x2d')]||![],this['dialQueueProject2']=_0x50db00['dialQueueProject2']||undefined,this['dialAgiAfterHangupClient']=_0x50db00[_0x201dcd('0x25')]||![],this[_0x201dcd('0x13')]=_0x50db00[_0x201dcd('0x13')]||![],this[_0x201dcd('0x5d')]=monitorFormat[_0x50db00[_0x201dcd('0x5d')]]?monitorFormat[_0x50db00[_0x201dcd('0x5d')]]:undefined,this[_0x201dcd('0x19')]=_0x50db00['mandatoryDisposition']||![],this[_0x201dcd('0x3c')]=_0x50db00['mandatoryDispositionPause']?_0x50db00[_0x201dcd('0x3c')]:undefined;}module['exports']=VoiceQueue; \ No newline at end of file +const a1083_0x24df=['total','dialQueueTimeout','anonymous','dialCongestionRetryFrequency','originated','sumDuration','erlangCalls','temp','monitor_format','dialRecallInQueue','dialGlobalInterval','predictiveIntervalAvgHoldtime','dialQueueProject','startProgressive','outboundBusyCallsDay','predictiveIntervalHitRate','dialMachineMaxRetry','dialAMDMinWordLength','outboundAbandonedDay','Interval','dialAgentRejectRetryFrequency','dialAMDTotalAnalysisTime','dialAgiAfterHangupAgent','predictiveIntervalDroppedCallsCallersExit','Trunk','dialPredictiveInterval','dialAbandonedMaxRetry','dialAgentRejectMaxRetry','dialNoAnswerMaxRetry','dialAMDMaximumWordLength','dialOriginateTimeout','mandatoryDisposition','outboundRejectCallsDay','dialDropMaxRetry','roundrobin','progressive','timeout','inbound','autopause','wav49','dialLimitChannel','answered','dialAMDAfterGreetingSilence','pTalking','dialPredictiveIntervalMaxThreshold','outboundReCallsDay','dialMethod','dialNoSuchNumberMaxRetry','dialAMDMaximumNumberOfWords','dialBusyMaxRetry','outboundNoSuchCallsDay','dialCongestionMaxRetry','dialPowerLevel','dialCutDigit','outboundNoAnswerCallsDay','wav','predictiveIntervalMultiplicativeFactor','dialQueueOptions','dialTimezone','dialAMDInitialSilence','outboundDropCallsDayTimeout','dialGlobalMaxRetry','dialLimitQueue','dialOriginateCallerIdNumber','available','erlangAbandonmentRate','dialBusyRetryFrequency','predictiveIntervalPauses','dialPredictiveOptimization','acwTimeout','sumHoldTime','dialDropRetryFrequency','TrunkBackup','waiting','acw','dialAgiAfterHangupClient','name','dialAMDSilenceThreshold','erlangCallToSecond','sendMessageOneNotActive','dialNoAnswerRetryFrequency','predictiveIntervalMaxThreshold','dialOriginateCallerIdName','outboundBlacklistCallsDay','dialAMDActive','mandatoryDispositionPause','talking','predictiveIntervalErlangCallsDroppedCalls','rrmemory','unmanaged','dialAbandonedRetryFrequency','dialNoSuchNumberRetryFrequency','outboundDropCallsDayACS','dialMachineRetryFrequency','strategy','dialPrefix','predictiveIntervalAvgTalktime','startPredictive','dialRecallMeTimeout','type','dialActive','dialQueueProject2','outboundAnswerCallsDay','dialAMDGreeting','dialRandomLastDigitCallerIdNumber','dialAMDBetweenWordsSilence','dialPredictiveOptimizationPercentage'];(function(_0x401409,_0x24dffc){const _0x3a3ff0=function(_0x43151d){while(--_0x43151d){_0x401409['push'](_0x401409['shift']());}};_0x3a3ff0(++_0x24dffc);}(a1083_0x24df,0x127));const a1083_0x3a3f=function(_0x401409,_0x24dffc){_0x401409=_0x401409-0x0;let _0x3a3ff0=a1083_0x24df[_0x401409];return _0x3a3ff0;};const _0x403d41=a1083_0x3a3f;'use strict';const monitorFormat={'wav':_0x403d41('0x51'),'wav49':_0x403d41('0x41'),'gsm':'gsm'},strategy={'rrmemory':_0x403d41('0x7'),'roundrobin':_0x403d41('0x3c')};function VoiceQueue(_0x43151d){const _0x146455=_0x403d41;this['id']=_0x43151d['id']||0x0,this[_0x146455('0x66')]=_0x43151d[_0x146455('0x66')]||'',this['monitor_format']=_0x43151d['monitor_format']||'',this[_0x146455('0x12')]=_0x43151d[_0x146455('0x12')]||_0x146455('0x3f'),this[_0x146455('0x63')]=0x0,this[_0x146455('0x5')]=0x0,this[_0x146455('0x1a')]=0x0,this[_0x146455('0x43')]=0x0,this[_0x146455('0x1f')]=0x0,this[_0x146455('0x60')]=0x0,this['sumBillable']=0x0,this[_0x146455('0x8')]=0x0,this['abandoned']=0x0,this['loggedIn']=0x0,this[_0x146455('0x5a')]=0x0,this['acw']=_0x43151d[_0x146455('0x64')]||![],this[_0x146455('0x5f')]=_0x43151d['acwTimeout']||0xa,this[_0x146455('0x40')]=_0x43151d[_0x146455('0x40')]||'no',this[_0x146455('0x69')]=!![],this['message']='',this[_0x146455('0x1e')]=0x0,this[_0x146455('0x21')]=0x0,this['dialTimezone']=_0x43151d[_0x146455('0x54')]||null,this[_0x146455('0x24')]=_0x43151d[_0x146455('0x24')]?_0x43151d[_0x146455('0x24')]:null,this[_0x146455('0x13')]=_0x43151d[_0x146455('0x13')],this[_0x146455('0x48')]=_0x43151d[_0x146455('0x48')]||_0x146455('0x3d'),this[_0x146455('0x42')]=_0x43151d[_0x146455('0x42')]||0x0,this[_0x146455('0x58')]=_0x43151d[_0x146455('0x58')]||0x0,this['dialPowerLevel']=_0x43151d[_0x146455('0x4e')]||0x1,this[_0x146455('0x5e')]=_0x43151d[_0x146455('0x5e')]||'dropRate',this[_0x146455('0x19')]=_0x43151d['dialPredictiveOptimizationPercentage']||0.03,this[_0x146455('0x33')]=_0x43151d[_0x146455('0x33')]||0x258,this[_0x146455('0x1')]=_0x43151d[_0x146455('0x1')]||_0x146455('0x1c'),this[_0x146455('0x59')]=_0x43151d['dialOriginateCallerIdNumber']||_0x146455('0x1c'),this[_0x146455('0x38')]=_0x43151d[_0x146455('0x38')]||0x1e,this[_0x146455('0x53')]=_0x43151d['dialQueueOptions']||'tTxX',this[_0x146455('0x1b')]=_0x43151d[_0x146455('0x1b')]||0x3,this['dialQueueProject']=_0x43151d[_0x146455('0x26')]||undefined,this[_0x146455('0x4d')]=_0x43151d[_0x146455('0x4d')]||0x3,this[_0x146455('0x1d')]=_0x43151d['dialCongestionRetryFrequency']||0x96,this['dialBusyMaxRetry']=_0x43151d[_0x146455('0x4b')]||0x3,this[_0x146455('0x5c')]=_0x43151d[_0x146455('0x5c')]||0x96,this[_0x146455('0x36')]=_0x43151d['dialNoAnswerMaxRetry']||0x3,this[_0x146455('0x6a')]=_0x43151d[_0x146455('0x6a')]||0x96,this[_0x146455('0x49')]=_0x43151d[_0x146455('0x49')]||0x3,this[_0x146455('0xa')]=_0x43151d[_0x146455('0xa')]||0x96,this['dialDropMaxRetry']=_0x43151d[_0x146455('0x3b')]||0x3,this[_0x146455('0x61')]=_0x43151d[_0x146455('0x61')]||0x96,this[_0x146455('0x34')]=_0x43151d['dialAbandonedMaxRetry']||0x3,this[_0x146455('0x9')]=_0x43151d['dialAbandonedRetryFrequency']||0x96,this[_0x146455('0x2a')]=_0x43151d[_0x146455('0x2a')]||0x3,this['dialMachineRetryFrequency']=_0x43151d[_0x146455('0xc')]||0x96,this[_0x146455('0x35')]=_0x43151d[_0x146455('0x35')]||0x3,this[_0x146455('0x2e')]=_0x43151d['dialAgentRejectRetryFrequency']||0x96,this[_0x146455('0x57')]=_0x43151d[_0x146455('0x57')]||0x4,this['Trunk']=_0x43151d[_0x146455('0x32')]?_0x43151d[_0x146455('0x32')]:undefined,this[_0x146455('0x62')]=_0x43151d['TrunkBackup']?_0x43151d[_0x146455('0x62')]:undefined,this[_0x146455('0xe')]=_0x43151d[_0x146455('0xe')]||undefined,this['Interval']=_0x43151d[_0x146455('0x2d')]?_0x43151d[_0x146455('0x2d')]:undefined,this['dialOrderByScheduledAt']=_0x43151d['dialOrderByScheduledAt']||'DESC',this[_0x146455('0x17')]=_0x43151d[_0x146455('0x17')]||undefined,this[_0x146455('0x4f')]=_0x43151d[_0x146455('0x4f')]||undefined,this[_0x146455('0xd')]=strategy[_0x43151d[_0x146455('0xd')]]||_0x146455('0x7'),this['queueStatusComplete']=!![],this[_0x146455('0x3')]=_0x43151d[_0x146455('0x3')]||![],this[_0x146455('0x55')]=_0x43151d[_0x146455('0x55')],this[_0x146455('0x16')]=_0x43151d[_0x146455('0x16')],this['dialAMDAfterGreetingSilence']=_0x43151d[_0x146455('0x44')],this[_0x146455('0x2f')]=_0x43151d[_0x146455('0x2f')],this[_0x146455('0x2b')]=_0x43151d['dialAMDMinWordLength'],this[_0x146455('0x18')]=_0x43151d[_0x146455('0x18')],this[_0x146455('0x4a')]=_0x43151d[_0x146455('0x4a')],this[_0x146455('0x67')]=_0x43151d[_0x146455('0x67')],this[_0x146455('0x37')]=_0x43151d[_0x146455('0x37')],this[_0x146455('0x3a')]=0x0,this[_0x146455('0x45')]=0x0,this[_0x146455('0x3e')]=_0x43151d[_0x146455('0x3e')],this[_0x146455('0x15')]=0x0,this['outboundAnswerAgiCallsDay']=0x0,this[_0x146455('0x50')]=0x0,this[_0x146455('0x28')]=0x0,this['outboundCongestionCallsDay']=0x0,this[_0x146455('0x4c')]=0x0,this['outboundUnknownCallsDay']=0x0,this[_0x146455('0x2')]=0x0,this['outboundOriginateFailureCallsDay']=0x0,this['outboundDropCallsDayCallersExit']=0x0,this[_0x146455('0x56')]=0x0,this[_0x146455('0xb')]=0x0,this[_0x146455('0x47')]=0x0,this[_0x146455('0x2c')]=0x0,this[_0x146455('0x27')]=undefined,this[_0x146455('0x10')]=undefined,this['handlePredictive']=undefined,this[_0x146455('0x52')]=1.05,this['predictiveIntervalTotalCalls']=0x0,this['predictiveIntervalAnsweredCalls']=0x0,this[_0x146455('0x31')]=0x0,this['predictiveIntervalDroppedCallsTimeout']=0x0,this[_0x146455('0x25')]=0x0,this[_0x146455('0xf')]=0x0,this[_0x146455('0x5d')]=0x0,this['predictiveIntervalAvailable']=0x0,this[_0x146455('0x0')]=_0x43151d[_0x146455('0x46')]||0x14,this['predictiveIntervalMinThreshold']=_0x43151d['dialPredictiveIntervalMaxThreshold']||0xa,this['predictiveIntervalErlangCalls']=0x0,this[_0x146455('0x6')]=0x0,this[_0x146455('0x29')]=0x1,this[_0x146455('0x20')]=0x0,this[_0x146455('0x68')]=0x0,this[_0x146455('0x5b')]=0x0,this['erlangBusyFactor']=0x0,this[_0x146455('0x11')]=_0x43151d[_0x146455('0x11')]||0x1e,this[_0x146455('0x23')]=_0x43151d[_0x146455('0x23')]||![],this[_0x146455('0x14')]=_0x43151d[_0x146455('0x14')]||undefined,this[_0x146455('0x65')]=_0x43151d[_0x146455('0x65')]||![],this[_0x146455('0x30')]=_0x43151d[_0x146455('0x30')]||![],this[_0x146455('0x22')]=monitorFormat[_0x43151d[_0x146455('0x22')]]?monitorFormat[_0x43151d[_0x146455('0x22')]]:undefined,this[_0x146455('0x39')]=_0x43151d[_0x146455('0x39')]||![],this[_0x146455('0x4')]=_0x43151d['mandatoryDispositionPause']?_0x43151d[_0x146455('0x4')]:undefined;}module['exports']=VoiceQueue; \ No newline at end of file diff --git a/server/services/ami/model/vtigerAccount.js b/server/services/ami/model/vtigerAccount.js index 37df4ec..0ef4da7 100644 --- a/server/services/ami/model/vtigerAccount.js +++ b/server/services/ami/model/vtigerAccount.js @@ -1 +1 @@ -var a1084_0x2721=['name','remoteUri','username','serverUrl','accessKey','Configurations'];(function(_0x28bc04,_0x2721b1){var _0x2707d2=function(_0x1ffc10){while(--_0x1ffc10){_0x28bc04['push'](_0x28bc04['shift']());}};_0x2707d2(++_0x2721b1);}(a1084_0x2721,0x1c5));var a1084_0x2707=function(_0x28bc04,_0x2721b1){_0x28bc04=_0x28bc04-0x0;var _0x2707d2=a1084_0x2721[_0x28bc04];return _0x2707d2;};'use strict';function VtigerAccount(_0x1ffc10){var _0x262e8c=a1084_0x2707;this['id']=_0x1ffc10['id']||0x0,this[_0x262e8c('0x3')]=_0x1ffc10['name']||'',this[_0x262e8c('0x5')]=_0x1ffc10[_0x262e8c('0x5')]||'',this[_0x262e8c('0x1')]=_0x1ffc10[_0x262e8c('0x1')]||'',this[_0x262e8c('0x4')]=_0x1ffc10[_0x262e8c('0x4')]||'',this[_0x262e8c('0x0')]=_0x1ffc10[_0x262e8c('0x0')]||'',this[_0x262e8c('0x2')]=_0x1ffc10[_0x262e8c('0x2')]||{};}module['exports']=VtigerAccount; \ No newline at end of file +var a1084_0x431b=['exports','serverUrl','username','name','accessKey','remoteUri','Configurations'];(function(_0x3e28c1,_0x431b19){var _0x1e625=function(_0x46d006){while(--_0x46d006){_0x3e28c1['push'](_0x3e28c1['shift']());}};_0x1e625(++_0x431b19);}(a1084_0x431b,0x130));var a1084_0x1e62=function(_0x3e28c1,_0x431b19){_0x3e28c1=_0x3e28c1-0x0;var _0x1e625=a1084_0x431b[_0x3e28c1];return _0x1e625;};var _0x359785=a1084_0x1e62;'use strict';function VtigerAccount(_0x46d006){var _0x3a0470=a1084_0x1e62;this['id']=_0x46d006['id']||0x0,this[_0x3a0470('0x0')]=_0x46d006['name']||'',this['username']=_0x46d006[_0x3a0470('0x6')]||'',this['accessKey']=_0x46d006[_0x3a0470('0x1')]||'',this['remoteUri']=_0x46d006[_0x3a0470('0x2')]||'',this['serverUrl']=_0x46d006[_0x3a0470('0x5')]||'',this['Configurations']=_0x46d006[_0x3a0470('0x3')]||{};}module[_0x359785('0x4')]=VtigerAccount; \ No newline at end of file diff --git a/server/services/ami/model/zendeskAccount.js b/server/services/ami/model/zendeskAccount.js index a2a99fa..66fa599 100644 --- a/server/services/ami/model/zendeskAccount.js +++ b/server/services/ami/model/zendeskAccount.js @@ -1 +1 @@ -var a1085_0x5711=['type','token','username','remoteUri','name','integrationTab','authType','serverUrl','exports','password'];(function(_0x2ffe17,_0x571189){var _0x3e45c0=function(_0x231c5b){while(--_0x231c5b){_0x2ffe17['push'](_0x2ffe17['shift']());}};_0x3e45c0(++_0x571189);}(a1085_0x5711,0x155));var a1085_0x3e45=function(_0x2ffe17,_0x571189){_0x2ffe17=_0x2ffe17-0x0;var _0x3e45c0=a1085_0x5711[_0x2ffe17];return _0x3e45c0;};var _0x83a295=a1085_0x3e45;'use strict';function ZendeskAccount(_0x231c5b){var _0x53fed0=a1085_0x3e45;this['id']=_0x231c5b['id']||0x0,this[_0x53fed0('0x3')]=_0x231c5b['name']||'',this[_0x53fed0('0x1')]=_0x231c5b[_0x53fed0('0x1')]||'',this[_0x53fed0('0x8')]=_0x231c5b[_0x53fed0('0x8')]||'',this[_0x53fed0('0x0')]=_0x231c5b[_0x53fed0('0x0')]||'',this['remoteUri']=_0x231c5b[_0x53fed0('0x2')]||'',this[_0x53fed0('0x5')]=_0x231c5b[_0x53fed0('0x5')]||'',this['type']=_0x231c5b[_0x53fed0('0x9')]||_0x53fed0('0x4'),this['serverUrl']=_0x231c5b[_0x53fed0('0x6')]||'',this['Configurations']=_0x231c5b['Configurations']||{};}module[_0x83a295('0x7')]=ZendeskAccount; \ No newline at end of file +var a1085_0x805f=['token','remoteUri','integrationTab','password','authType','username','Configurations','serverUrl','type','exports'];(function(_0x4339ec,_0x805fed){var _0x15eaf7=function(_0x52908c){while(--_0x52908c){_0x4339ec['push'](_0x4339ec['shift']());}};_0x15eaf7(++_0x805fed);}(a1085_0x805f,0x102));var a1085_0x15ea=function(_0x4339ec,_0x805fed){_0x4339ec=_0x4339ec-0x0;var _0x15eaf7=a1085_0x805f[_0x4339ec];return _0x15eaf7;};var _0x53e264=a1085_0x15ea;'use strict';function ZendeskAccount(_0x52908c){var _0x431108=a1085_0x15ea;this['id']=_0x52908c['id']||0x0,this['name']=_0x52908c['name']||'',this['username']=_0x52908c[_0x431108('0x7')]||'',this['password']=_0x52908c[_0x431108('0x5')]||'',this[_0x431108('0x2')]=_0x52908c[_0x431108('0x2')]||'',this[_0x431108('0x3')]=_0x52908c[_0x431108('0x3')]||'',this[_0x431108('0x6')]=_0x52908c['authType']||'',this['type']=_0x52908c[_0x431108('0x0')]||_0x431108('0x4'),this[_0x431108('0x9')]=_0x52908c['serverUrl']||'',this[_0x431108('0x8')]=_0x52908c[_0x431108('0x8')]||{};}module[_0x53e264('0x1')]=ZendeskAccount; \ No newline at end of file diff --git a/server/services/ami/model/zohoAccount.js b/server/services/ami/model/zohoAccount.js index 3b5812d..b76b410 100644 --- a/server/services/ami/model/zohoAccount.js +++ b/server/services/ami/model/zohoAccount.js @@ -1 +1 @@ -var a1086_0x57e1=['host','clientId','Configurations','zone','description','exports','name','code','refreshToken','clientSecret'];(function(_0x20ca40,_0x57e1b1){var _0x54bc11=function(_0x5d3982){while(--_0x5d3982){_0x20ca40['push'](_0x20ca40['shift']());}};_0x54bc11(++_0x57e1b1);}(a1086_0x57e1,0x92));var a1086_0x54bc=function(_0x20ca40,_0x57e1b1){_0x20ca40=_0x20ca40-0x0;var _0x54bc11=a1086_0x57e1[_0x20ca40];return _0x54bc11;};var _0x490453=a1086_0x54bc;'use strict';function ZohoAccount(_0x5d3982){var _0x1d33f3=a1086_0x54bc;this['id']=_0x5d3982['id']||0x0,this[_0x1d33f3('0x0')]=_0x5d3982['name']||'',this[_0x1d33f3('0x8')]=_0x5d3982[_0x1d33f3('0x8')]||'',this[_0x1d33f3('0x4')]=_0x5d3982[_0x1d33f3('0x4')]||'',this[_0x1d33f3('0x7')]=_0x5d3982[_0x1d33f3('0x7')]||'',this[_0x1d33f3('0x5')]=_0x5d3982['clientId']||'',this[_0x1d33f3('0x3')]=_0x5d3982[_0x1d33f3('0x3')]||'',this['serverUrl']=_0x5d3982['serverUrl']||'',this[_0x1d33f3('0x1')]=_0x5d3982['code']||'',this[_0x1d33f3('0x2')]=_0x5d3982['refreshToken']||'',this[_0x1d33f3('0x6')]=_0x5d3982['Configurations']||{};}module[_0x490453('0x9')]=ZohoAccount; \ No newline at end of file +var a1086_0x4519=['code','description','serverUrl','host','clientId','Configurations','clientSecret','refreshToken','zone','name'];(function(_0x181817,_0x451927){var _0x3da222=function(_0xae1cdb){while(--_0xae1cdb){_0x181817['push'](_0x181817['shift']());}};_0x3da222(++_0x451927);}(a1086_0x4519,0xd6));var a1086_0x3da2=function(_0x181817,_0x451927){_0x181817=_0x181817-0x0;var _0x3da222=a1086_0x4519[_0x181817];return _0x3da222;};'use strict';function ZohoAccount(_0xae1cdb){var _0x52db5f=a1086_0x3da2;this['id']=_0xae1cdb['id']||0x0,this[_0x52db5f('0x5')]=_0xae1cdb[_0x52db5f('0x5')]||'',this[_0x52db5f('0x7')]=_0xae1cdb[_0x52db5f('0x7')]||'',this[_0x52db5f('0x9')]=_0xae1cdb[_0x52db5f('0x9')]||'',this['zone']=_0xae1cdb[_0x52db5f('0x4')]||'',this[_0x52db5f('0x0')]=_0xae1cdb[_0x52db5f('0x0')]||'',this['clientSecret']=_0xae1cdb[_0x52db5f('0x2')]||'',this[_0x52db5f('0x8')]=_0xae1cdb[_0x52db5f('0x8')]||'',this[_0x52db5f('0x6')]=_0xae1cdb[_0x52db5f('0x6')]||'',this[_0x52db5f('0x3')]=_0xae1cdb[_0x52db5f('0x3')]||'',this[_0x52db5f('0x1')]=_0xae1cdb[_0x52db5f('0x1')]||{};}module['exports']=ZohoAccount; \ No newline at end of file diff --git a/server/services/ami/preview/action.js b/server/services/ami/preview/action.js index 40e1b1f..6ad5c1e 100644 --- a/server/services/ami/preview/action.js +++ b/server/services/ami/preview/action.js @@ -1 +1 @@ -const a1087_0x118d=['Agent','countbusyretry','active','format','countcongestionretry','countabandonedretry','uniqueid','recallme','ContactId','type','callbackuniqueid','\x22%s\x22\x20<%s>','countnoanswerretry','scheduledat','originatecalleridname','isNil','exports','calleridnum','countdropretry','callbackat','membername','prototype','phone','countagentrejectretry','ListId','callback','calleridname','dialAnswer','VoiceQueueId','countmachineretry','countnosuchnumberretry','Contact','number','util','queue','lastName','string','UserId','SIP/%s'];(function(_0x22b828,_0x118d0b){const _0x4dbf4a=function(_0x44d9d5){while(--_0x44d9d5){_0x22b828['push'](_0x22b828['shift']());}};_0x4dbf4a(++_0x118d0b);}(a1087_0x118d,0x1ab));const a1087_0x4dbf=function(_0x22b828,_0x118d0b){_0x22b828=_0x22b828-0x0;let _0x4dbf4a=a1087_0x118d[_0x22b828];return _0x4dbf4a;};const _0x456d9c=a1087_0x4dbf;'use strict';const util=require(_0x456d9c('0x23')),_=require('lodash');function checkNameSurname(_0x44d9d5,_0x5d6300,_0x37435b){const _0x3e6429=_0x456d9c;let _0x54aa04='';!_['isNil'](_0x5d6300)&&_0x3e6429('0x26')===typeof _0x5d6300&&(_0x54aa04+=_0x5d6300);!_[_0x3e6429('0x11')](_0x37435b)&&_0x3e6429('0x26')===typeof _0x37435b&&(_0x54aa04+='\x20'+_0x37435b);if(_0x54aa04!=='')return _0x54aa04;return _0x44d9d5;}function Action(_0x1639dd,_0x4dcabd,_0x186647,_0x4c0412){const _0x5146cb=_0x456d9c;this[_0x5146cb('0x8')]=_0x186647||undefined,this['idContact']=_0x1639dd['id'],this[_0x5146cb('0x24')]=_0x4dcabd['name'],this[_0x5146cb('0xb')]=_0x4dcabd['type'],this['campaigntype']=_0x5146cb('0x24'),this[_0x5146cb('0x1d')]=![],this['membername']=_[_0x5146cb('0x11')](_0x1639dd[_0x5146cb('0x2')])?undefined:_0x1639dd[_0x5146cb('0x2')]['name'],this['channelAgent']=this[_0x5146cb('0x16')]?util[_0x5146cb('0x5')](_0x5146cb('0x1'),this[_0x5146cb('0x16')]):_0x4c0412||undefined,this[_0x5146cb('0x1c')]=checkNameSurname(_0x1639dd[_0x5146cb('0x21')]['phone'],_0x1639dd['Contact']['firstName'],_0x1639dd['Contact'][_0x5146cb('0x25')]),this[_0x5146cb('0x4')]=_0x1639dd['active']||![],this[_0x5146cb('0x13')]=_0x1639dd[_0x5146cb('0x21')][_0x5146cb('0x18')],this[_0x5146cb('0xf')]=_0x1639dd[_0x5146cb('0xf')],this[_0x5146cb('0x3')]=_0x1639dd[_0x5146cb('0x3')]||0x0,this[_0x5146cb('0x6')]=_0x1639dd[_0x5146cb('0x6')]||0x0,this['countnoanswerretry']=_0x1639dd['countnoanswerretry']||0x0,this['countglobal']=(_0x1639dd['countbusyretry']||0x0)+(_0x1639dd[_0x5146cb('0x6')]||0x0)+(_0x1639dd[_0x5146cb('0xe')]||0x0)+(_0x1639dd['countnosuchnumberretry']||0x0)+(_0x1639dd[_0x5146cb('0x14')]||0x0)+(_0x1639dd[_0x5146cb('0x7')]||0x0)+(_0x1639dd['countmachineretry']||0x0)+(_0x1639dd['countagentrejectretry']||0x0),this[_0x5146cb('0x20')]=_0x1639dd[_0x5146cb('0x20')]||0x0,this['countdropretry']=_0x1639dd[_0x5146cb('0x14')]||0x0,this[_0x5146cb('0x7')]=_0x1639dd[_0x5146cb('0x7')]||0x0,this[_0x5146cb('0x1f')]=_0x1639dd[_0x5146cb('0x1f')]||0x0,this[_0x5146cb('0x19')]=_0x1639dd[_0x5146cb('0x19')]||0x0,this[_0x5146cb('0x1b')]=_0x1639dd[_0x5146cb('0x1b')],this[_0x5146cb('0xc')]=_0x1639dd['callbackuniqueid'],this[_0x5146cb('0x15')]=_0x1639dd[_0x5146cb('0x15')],this[_0x5146cb('0x9')]=_0x1639dd['recallme'],this[_0x5146cb('0xa')]=_0x1639dd[_0x5146cb('0xa')],this[_0x5146cb('0x1a')]=_0x1639dd['ListId'],this[_0x5146cb('0x0')]=_[_0x5146cb('0x11')](_0x1639dd['Agent'])?_0x1639dd[_0x5146cb('0x0')]:_0x1639dd[_0x5146cb('0x2')]['id'],this[_0x5146cb('0x1e')]=_0x1639dd[_0x5146cb('0x1e')],this['originatecalleridnum']='',this[_0x5146cb('0x10')]='';}Action[_0x456d9c('0x17')]['getCaller']=function(){const _0x34f20c=_0x456d9c;return util[_0x34f20c('0x5')](_0x34f20c('0xd'),this[_0x34f20c('0x1c')],this[_0x34f20c('0x22')]);},module[_0x456d9c('0x12')]=Action; \ No newline at end of file +const a1087_0xf9e3=['countdropretry','originatecalleridnum','membername','SIP/%s','UserId','number','Agent','lastName','countagentrejectretry','originatecalleridname','string','ListId','firstName','type','exports','callback','countnosuchnumberretry','countmachineretry','countcongestionretry','uniqueid','getCaller','queue','calleridname','ContactId','VoiceQueueId','scheduledat','prototype','calleridnum','countbusyretry','Contact','countabandonedretry','callbackat','active','lodash','dialAnswer','countnoanswerretry','isNil','format','callbackuniqueid'];(function(_0x5f081e,_0xf9e31e){const _0x5e5ce3=function(_0x37ba6d){while(--_0x37ba6d){_0x5f081e['push'](_0x5f081e['shift']());}};_0x5e5ce3(++_0xf9e31e);}(a1087_0xf9e3,0x18b));const a1087_0x5e5c=function(_0x5f081e,_0xf9e31e){_0x5f081e=_0x5f081e-0x0;let _0x5e5ce3=a1087_0xf9e3[_0x5f081e];return _0x5e5ce3;};const _0x12140c=a1087_0x5e5c;'use strict';const util=require('util'),_=require(_0x12140c('0x1c'));function checkNameSurname(_0x37ba6d,_0x330cdd,_0x2f7a46){const _0x863349=_0x12140c;let _0x58fbfd='';!_[_0x863349('0x1f')](_0x330cdd)&&_0x863349('0x5')===typeof _0x330cdd&&(_0x58fbfd+=_0x330cdd);!_[_0x863349('0x1f')](_0x2f7a46)&&_0x863349('0x5')===typeof _0x2f7a46&&(_0x58fbfd+='\x20'+_0x2f7a46);if(_0x58fbfd!=='')return _0x58fbfd;return _0x37ba6d;}function Action(_0x5986f2,_0x31aca9,_0x18222b,_0x4bcf94){const _0x7dd93a=_0x12140c;this[_0x7dd93a('0xe')]=_0x18222b||undefined,this['idContact']=_0x5986f2['id'],this[_0x7dd93a('0x10')]=_0x31aca9['name'],this[_0x7dd93a('0x8')]=_0x31aca9[_0x7dd93a('0x8')],this['campaigntype']='queue',this[_0x7dd93a('0x1d')]=![],this[_0x7dd93a('0x24')]=_['isNil'](_0x5986f2[_0x7dd93a('0x1')])?undefined:_0x5986f2[_0x7dd93a('0x1')]['name'],this['channelAgent']=this[_0x7dd93a('0x24')]?util['format'](_0x7dd93a('0x25'),this['membername']):_0x4bcf94||undefined,this[_0x7dd93a('0x11')]=checkNameSurname(_0x5986f2[_0x7dd93a('0x18')]['phone'],_0x5986f2['Contact'][_0x7dd93a('0x7')],_0x5986f2[_0x7dd93a('0x18')][_0x7dd93a('0x2')]),this[_0x7dd93a('0x1b')]=_0x5986f2[_0x7dd93a('0x1b')]||![],this[_0x7dd93a('0x16')]=_0x5986f2['Contact']['phone'],this['scheduledat']=_0x5986f2[_0x7dd93a('0x14')],this[_0x7dd93a('0x17')]=_0x5986f2[_0x7dd93a('0x17')]||0x0,this['countcongestionretry']=_0x5986f2[_0x7dd93a('0xd')]||0x0,this['countnoanswerretry']=_0x5986f2[_0x7dd93a('0x1e')]||0x0,this['countglobal']=(_0x5986f2[_0x7dd93a('0x17')]||0x0)+(_0x5986f2[_0x7dd93a('0xd')]||0x0)+(_0x5986f2['countnoanswerretry']||0x0)+(_0x5986f2[_0x7dd93a('0xb')]||0x0)+(_0x5986f2[_0x7dd93a('0x22')]||0x0)+(_0x5986f2[_0x7dd93a('0x19')]||0x0)+(_0x5986f2[_0x7dd93a('0xc')]||0x0)+(_0x5986f2['countagentrejectretry']||0x0),this[_0x7dd93a('0xb')]=_0x5986f2['countnosuchnumberretry']||0x0,this['countdropretry']=_0x5986f2[_0x7dd93a('0x22')]||0x0,this[_0x7dd93a('0x19')]=_0x5986f2[_0x7dd93a('0x19')]||0x0,this[_0x7dd93a('0xc')]=_0x5986f2['countmachineretry']||0x0,this[_0x7dd93a('0x3')]=_0x5986f2[_0x7dd93a('0x3')]||0x0,this['callback']=_0x5986f2[_0x7dd93a('0xa')],this[_0x7dd93a('0x21')]=_0x5986f2[_0x7dd93a('0x21')],this[_0x7dd93a('0x1a')]=_0x5986f2[_0x7dd93a('0x1a')],this['recallme']=_0x5986f2['recallme'],this['ContactId']=_0x5986f2[_0x7dd93a('0x12')],this[_0x7dd93a('0x6')]=_0x5986f2[_0x7dd93a('0x6')],this['UserId']=_['isNil'](_0x5986f2[_0x7dd93a('0x1')])?_0x5986f2[_0x7dd93a('0x26')]:_0x5986f2[_0x7dd93a('0x1')]['id'],this['VoiceQueueId']=_0x5986f2[_0x7dd93a('0x13')],this[_0x7dd93a('0x23')]='',this[_0x7dd93a('0x4')]='';}Action[_0x12140c('0x15')][_0x12140c('0xf')]=function(){const _0x1d3ceb=_0x12140c;return util[_0x1d3ceb('0x20')]('\x22%s\x22\x20<%s>',this[_0x1d3ceb('0x11')],this[_0x1d3ceb('0x0')]);},module[_0x12140c('0x9')]=Action; \ No newline at end of file diff --git a/server/services/ami/preview/index.js b/server/services/ami/preview/index.js index 3a7db71..d0ef109 100644 --- a/server/services/ami/preview/index.js +++ b/server/services/ami/preview/index.js @@ -1 +1 @@ -const a1088_0x2b78=['rescheduleContact','agents','dialAnswer','actionPreview','Queue','talktime','dialGlobalMaxRetry','variablesAction','[Dialer][decrementTalkink][no\x20Hangup][Preview]','originateresponse','dialPrefix','dialOriginateCallerIdNumber','RecallFailedTimeout','syncCampaigns','isEmpty','NoAnswer','run','[callProgressDetectingCustomer][logAgentReject]','outboundBlacklistCallsDay','startPredictive','syncAttendedTransfer','Abandoned','[callProgressDetectingAgent][logBusy]','campaignsPreview','[callProgressDetectingCustomer][logAnswerGlobal]','phone','[syncHangupRequest][logAgentReject]','logCustomer','outboundReCallsDay','checkInBlack','checkIsBlackList','countabandonedretry','abandoned','Call\x20failed','Agent','[callProgressDetectingCustomer][logUnknownGlobal]','booked','./util/util','voiceQueues','addVariables','transfer','actionid','[16]','validateContact','[HistoryDialRecallInQueue][historyCatch]','unmonitored','dialNoSuchNumberRetryFrequency','responsetime','custom:agentnoanswer','dialAbandonedRetryFrequency','cause-txt','[callProgressDetectingAgent][logAnswer]','rescheduleContactInQueue','[callProgressDetectingCustomer][logNoSuchGlobal]','unlockAgent','trunks','util','custom:agentcongestion','sumBillable','blindtransfer','countcongestionretry','[callProgressDetectingCustomer][logNoAnswer]','./action','format','answertime','disableContact','[CampaignPreview]\x20Campaign\x20Queue:\x20','transfererlinkedid','message','size','erlangAbandonmentRate','preview','buildAcw','isTrunkReachable','trim','inspect','agentreject','destlinkedid','syncHangup','outboundAnswerCallsDay','[syncHangup][talking][transfer]','uuid','dialBusyRetryFrequency','predictiveIntervalErlangCallsDroppedCalls','countnosuchnumberretry','[Preview][validateContact][Empty\x20Contact]','Answer','[callProgressDetectingAgent][logCongestion]','outboundNoAnswerCallsDay','[RecallMe]','hangup','erlangCallToSecond','pick','Global','countabandonedetry','dialNoAnswerMaxRetry','outboundUnknownCallsDay','answered','pTalking','IsNotLoggedIn','SIP/%s/%s%s','YYYY-MM-DD\x20HH:mm:ss','countagentrejectretry','TRUNK_IS_NOT_REACHABLE','busy','dialCutDigit','isUndefined','predictiveIntervalHitRate','channel','[callProgressDetectingCustomer]','[Preview][validateContact][Trunk\x20not\x20work]','AnswerAGI','linkedid','outboundRejectCallsDay','destuniqueid','[syncHangup][talking]','[callProgressDetectingCustomer][logNoSuch]','[syncHangup][talking][increment]','createHistory','outboundAbandonedCallsDay','statedesc','getCallerId','erlangBusyFactor','addVariable','loggerError','pTalking:\x20','NOT_ACTIVE','sumDuration','total','\x20is\x20not\x20active','[syncHangup][talking][decrement]','dialRecallMeTimeout','ABANDONED','loggedIn','dialend','enqueue','[callProgressDetectingCustomer][logCongestion]','[Preview][validateContact][Empty\x20Campaign]','crateCustomerReportQueue','custom:agentnosuchnumber','\x20Queue','../../../config/logger','transfertargetlinkedid','NOANSWER','voice:queue:%s','dialActive','sequence','extractCalleridNumber','hanguprequest','strategy','unmanaged','clockClearZombieChannels','toLowerVariables','predictiveIntervalMultiplicativeFactor','custom:agentbusy','value','ACTIVE','RecallInQueue','updateOriginated','callProgressDetectingAgent','ANSWER','sendMessageOneNotActive','finally','prototype','outboundBusyCallsDay','[syncVarSet][Preview]','logger2','dialOriginateCallerIdName','Interval','[callProgressDetectingAgent][logAnswerAGI]','isNil','bind','dialstatus','callProgressDetectingCustomer','[clearZombieChannel]','starttime','syncVarSet','[Preview][validateContact][Campaign\x20Active]','nosuchnumber','syncDialEnd','merge','getContactPreview','uniqueid','outboundNoSuchCallsDay','Busy','originated','dialNoSuchNumberMaxRetry','No\x20such\x20channel','createAgentHistory','actions','Is\x20Valid','originated:\x20','filterKey','countnoanswerretry','syncHangupRequest','stringify','Empty\x20Contact','[Blacklist][error]','[Preview][execCall][success]','callerid','dialQueueProject','\x20Not\x20Active','Contact.phone','clearZombieChannel','execCall','exports','catch','dialMethod','keys','ListId','[getContactRecallMe]','[callProgressDetectingCustomer][logUnknown]','../ami','unlockContact','createCustomerFinal','object','NoSuchNumber','dialRandomLastDigitCallerIdNumber','Contact\x20is\x20undefined','[callProgressDetectingCustomer][logBusy]','AgentReject','predictiveIntervalDroppedCallsTimeout','createBody','[callProgressDetectingCustomer][logAbandoned]','outbound','isFailure','[action]','talking','countglobal','reason','buildObj','substring','[HistoryRecallClose]','syncOriginateResponse','../../../rediscache','logAgent','clearZombieChannels','TrunkBackup','logger','variables','SIP/%s','outboundDropCallsDayCallersExit','then','[syncHangup][talking][cause]','predictiveIntervalErlangCalls','predictiveIntervalAvailable','name','[Preview][getContactPreview]','Trunk','dialAgentRejectRetryFrequency','scheduledAt','OriginateError','md5','syncNewExten','Contact','Call\x20unsuccessful','[callProgressDetectingAgent][logNoSuch]','getDiff','UserId','undefined','campaign\x20Name:\x20','clone','error','available','[Preview][checkIsBlackList]','dialBusyMaxRetry','setMessage','activeContact','voice_queue:save','variable','CONGESTION','info','congestion','[originated][decrement][callProgressDetectingCustomer]','Congestion','\x20Trunk\x20is\x20not\x20active','isActive','Action','unlock','idContact','loggedInDb','totalGlobal','outboundCongestionCallsDay','outboundOriginateFailureCallsDay','[callProgressDetectingCustomer][logNoAnswerGlobal]','lookAgent','connect','type','recallMe','[originated][increment]','active','predictiveIntervalTotalCalls','cause','response','cloneAction','status','VoiceQueueId','queue','execRun','called','agentReadyId','varset','createCustomerHistory','getContactRecallMe','dialAbandonedMaxRety','getCallerIdRandom','emit','countbusyretry','loopCampaigns','outboundDropCallsDayTimeout','originatecalleridname','custom:agentConnectPreview','CANCEL'];(function(_0x39ea99,_0x2b782d){const _0x35f593=function(_0x2e7c23){while(--_0x2e7c23){_0x39ea99['push'](_0x39ea99['shift']());}};_0x35f593(++_0x2b782d);}(a1088_0x2b78,0x1ec));const a1088_0x35f5=function(_0x39ea99,_0x2b782d){_0x39ea99=_0x39ea99-0x0;let _0x35f593=a1088_0x2b78[_0x39ea99];return _0x35f593;};const _0x2bd710=a1088_0x35f5;'use strict';const util=require(_0x2bd710('0xbe')),_=require('lodash'),uuid=require(_0x2bd710('0xd7')),moment=require('moment'),md5=require(_0x2bd710('0x49')),logger=require(_0x2bd710('0x113'))(_0x2bd710('0xcd')),loggerAction=require(_0x2bd710('0x113'))(_0x2bd710('0x89')),ami=require(_0x2bd710('0x21')),rpcDb=require('./rpcDb'),Action=require(_0x2bd710('0xc4')),ut=require(_0x2bd710('0xab')),{getSocket}=require(_0x2bd710('0x37')),io=getSocket(),Sequence=function(){};Sequence[_0x2bd710('0x129')][_0x2bd710('0x10d')]=function(_0x2e7c23){const _0x12e283=_0x2bd710;this['tail']=this['tail']?this['tail'][_0x12e283('0x128')](_0x2e7c23):_0x2e7c23();};function Preview(_0x4df33c){const _0x5e68f4=_0x2bd710;this['sequence']=new Sequence(),this['campaignsPreview']=_0x4df33c[_0x5e68f4('0xac')],this[_0x5e68f4('0xbd')]=_0x4df33c[_0x5e68f4('0xbd')],this[_0x5e68f4('0xa')]={},this['agents']=_0x4df33c['agents'],this['clockClearZombieChannels']=0x0,ami['on'](_0x5e68f4('0x8f'),this[_0x5e68f4('0x36')][_0x5e68f4('0x131')](this)),ami['on'](_0x5e68f4('0xe0'),this[_0x5e68f4('0xd4')][_0x5e68f4('0x131')](this)),ami['on'](_0x5e68f4('0x11a'),this[_0x5e68f4('0xf')]['bind'](this)),ami['on'](_0x5e68f4('0x10c'),this['syncDialEnd'][_0x5e68f4('0x131')](this)),ami['on']('newexten',this['syncNewExten'][_0x5e68f4('0x131')](this)),ami['on'](_0x5e68f4('0x7a'),this[_0x5e68f4('0x136')]['bind'](this)),ami['on']('attendedtransfer',this[_0x5e68f4('0x9a')][_0x5e68f4('0x131')](this)),ami['on'](_0x5e68f4('0xc1'),this['syncBlindTransfer'][_0x5e68f4('0x131')](this)),this[_0x5e68f4('0x81')](this['campaignsPreview']);}function emit(_0x44c4c9,_0x1bad53,_0x499719){io['to'](_0x44c4c9)['emit'](_0x1bad53,_0x499719);}function emitCampaignPreview(_0x3a2ff0){const _0x13ad59=_0x2bd710;if(_0x3a2ff0[_0x13ad59('0x6c')]===_0x13ad59('0x2d')){const _0x215c40={'id':_0x3a2ff0['id'],'name':_0x3a2ff0['name'],'strategy':_0x3a2ff0[_0x13ad59('0x11b')],'answered':_0x3a2ff0['answered'],'available':_0x3a2ff0[_0x13ad59('0x54')],'loggedIn':_0x3a2ff0[_0x13ad59('0x10b')],'pTalking':_0x3a2ff0[_0x13ad59('0xe8')],'sumBillable':_0x3a2ff0[_0x13ad59('0xc0')],'sumDuration':_0x3a2ff0[_0x13ad59('0x105')],'sumHoldTime':_0x3a2ff0['sumHoldTime']||0x0,'talking':_0x3a2ff0[_0x13ad59('0x30')],'total':_0x3a2ff0['total'],'type':_0x3a2ff0['type'],'unmanaged':_0x3a2ff0[_0x13ad59('0x11c')],'abandoned':_0x3a2ff0[_0x13ad59('0xa6')],'waiting':_0x3a2ff0['waiting'],'loggedInDb':_0x3a2ff0[_0x13ad59('0x65')],'dialActive':_0x3a2ff0['dialActive'],'dialMethod':_0x3a2ff0[_0x13ad59('0x1c')],'dialOriginateCallerIdName':_0x3a2ff0[_0x13ad59('0x12d')],'dialOriginateCallerIdNumber':_0x3a2ff0[_0x13ad59('0x91')],'dialOriginateTimeout':_0x3a2ff0['dialOriginateTimeout'],'dialPrefix':_0x3a2ff0[_0x13ad59('0x90')],'outboundAnswerAgiCallsDay':_0x3a2ff0['outboundAnswerAgiCallsDay'],'outboundAnswerCallsDay':_0x3a2ff0[_0x13ad59('0xd5')],'outboundBlacklistCallsDay':_0x3a2ff0[_0x13ad59('0x98')],'outboundBusyCallsDay':_0x3a2ff0[_0x13ad59('0x12a')],'outboundCongestionCallsDay':_0x3a2ff0[_0x13ad59('0x67')],'outboundDropCallsDayACS':_0x3a2ff0['outboundDropCallsDayACS'],'outboundDropCallsDayCallersExit':_0x3a2ff0[_0x13ad59('0x3e')],'outboundDropCallsDayTimeout':_0x3a2ff0[_0x13ad59('0x82')],'outboundNoAnswerCallsDay':_0x3a2ff0[_0x13ad59('0xde')],'outboundNoSuchCallsDay':_0x3a2ff0[_0x13ad59('0x4')],'outboundOriginateFailureCallsDay':_0x3a2ff0[_0x13ad59('0x68')],'outboundReCallsDay':_0x3a2ff0[_0x13ad59('0xa2')],'outboundRejectCallsDay':_0x3a2ff0[_0x13ad59('0xf7')],'outboundUnknownCallsDay':_0x3a2ff0[_0x13ad59('0xe6')],'outboundAbandonedCallsDay':_0x3a2ff0[_0x13ad59('0xfd')],'predictiveIntervalAnsweredCalls':_0x3a2ff0['predictiveIntervalAnsweredCalls'],'predictiveIntervalAvgHoldtime':_0x3a2ff0['predictiveIntervalAvgHoldtime'],'predictiveIntervalAvgTalktime':_0x3a2ff0['predictiveIntervalAvgTalktime'],'predictiveIntervalDroppedCallsCallersExit':_0x3a2ff0['predictiveIntervalDroppedCallsCallersExit'],'predictiveIntervalDroppedCallsTimeout':_0x3a2ff0[_0x13ad59('0x2a')],'predictiveIntervalErlangCalls':_0x3a2ff0[_0x13ad59('0x41')],'predictiveIntervalErlangCallsDroppedCalls':_0x3a2ff0[_0x13ad59('0xd9')],'predictiveIntervalHitRate':_0x3a2ff0[_0x13ad59('0xf1')],'predictiveIntervalMultiplicativeFactor':_0x3a2ff0[_0x13ad59('0x11f')],'predictiveIntervalPauses':_0x3a2ff0['predictiveIntervalPauses'],'predictiveIntervalAvailable':_0x3a2ff0[_0x13ad59('0x42')],'predictiveIntervalTotalCalls':_0x3a2ff0[_0x13ad59('0x70')],'message':_0x3a2ff0[_0x13ad59('0xca')],'originated':_0x3a2ff0[_0x13ad59('0x6')],'erlangCalls':_0x3a2ff0['erlangCalls'],'erlangCallToSecond':_0x3a2ff0[_0x13ad59('0xe1')],'erlangAbandonmentRate':_0x3a2ff0[_0x13ad59('0xcc')],'erlangBusyFactor':_0x3a2ff0[_0x13ad59('0x100')],'startPredictive':_0x3a2ff0[_0x13ad59('0x99')],'startProgressive':_0x3a2ff0['startProgressive']};_0x3a2ff0['Trunk']&&(_0x215c40['Trunk']={'id':_0x3a2ff0[_0x13ad59('0x45')]['id'],'name':_0x3a2ff0[_0x13ad59('0x45')][_0x13ad59('0x43')],'active':_0x3a2ff0['Trunk'][_0x13ad59('0x6f')],'callerid':_0x3a2ff0[_0x13ad59('0x45')][_0x13ad59('0x14')]});_0x3a2ff0['Interval']&&(_0x215c40[_0x13ad59('0x12e')]={'id':_0x3a2ff0[_0x13ad59('0x12e')]['id'],'name':_0x3a2ff0[_0x13ad59('0x12e')]['name']});const _0x50c706=md5(JSON[_0x13ad59('0x10')](_0x215c40));_0x3a2ff0[_0x13ad59('0x49')]!==_0x50c706&&(_0x3a2ff0[_0x13ad59('0x49')]=_0x50c706,emit(util['format'](_0x13ad59('0x116'),_0x215c40['name']),_0x13ad59('0x59'),_0x215c40));}}function emitVoiceQueueChannelRemove(_0x26763c){const _0x4f2368=_0x2bd710;logger['info']('[DEBUG]\x20Emit\x20voice_queue_channel:remove\x20event',JSON['stringify'](_0x26763c)),emit(util['format']('voice:queue:%s',_0x26763c[_0x4f2368('0x43')]),'voice_queue_channel:remove',_0x26763c);}function notSendMessagesQueue(_0x916658){const _0xf2eb4f=_0x2bd710;_0x916658[_0xf2eb4f('0x127')]&&(_0x916658[_0xf2eb4f('0x6')]===0x0&&_0x916658[_0xf2eb4f('0xe8')]===0x0?(_0x916658[_0xf2eb4f('0x127')]=![],_0x916658['available']=0x0,_0x916658['paused']=0x0,_0x916658[_0xf2eb4f('0xca')]=_0xf2eb4f('0x104'),ut[_0xf2eb4f('0x3b')](_0xf2eb4f('0xc8'),_0x916658[_0xf2eb4f('0x43')]+_0xf2eb4f('0x107'))):(_0x916658[_0xf2eb4f('0xca')]='IS_DISACTIVED',ut['logger'](_0xf2eb4f('0xc8'),_0x916658[_0xf2eb4f('0x43')]+'\x20is\x20disactive')),emitCampaignPreview(_0x916658));}Preview[_0x2bd710('0x129')][_0x2bd710('0x81')]=function(){const _0x2e43a2=this;setInterval(function(){const _0x12950f=a1088_0x35f5;_0x2e43a2[_0x12950f('0x93')]();},0x7cf);},Preview[_0x2bd710('0x129')][_0x2bd710('0x93')]=function(){const _0x5d3d78=_0x2bd710,_0xa6288b=this[_0x5d3d78('0x9d')];this[_0x5d3d78('0x11d')]+=0x1;for(const _0x1dbc3b in _0xa6288b){typeof _0xa6288b[_0x1dbc3b]!=='undefined'&&(_0xa6288b[_0x1dbc3b][_0x5d3d78('0x1c')]==='preview'||_0xa6288b[_0x1dbc3b][_0x5d3d78('0x1c')]===_0x5d3d78('0xaa'))&&_0xa6288b[_0x1dbc3b][_0x5d3d78('0x6c')]==='outbound'&&(this[_0x5d3d78('0x11d')]>0x7&&(this['clockClearZombieChannels']=0x0,this[_0x5d3d78('0x39')]())),typeof _0xa6288b[_0x1dbc3b]!==_0x5d3d78('0x50')&&_0xa6288b[_0x1dbc3b][_0x5d3d78('0x1c')]===_0x5d3d78('0xcd')&&_0xa6288b[_0x1dbc3b][_0x5d3d78('0x6c')]===_0x5d3d78('0x2d')&&(_0xa6288b[_0x1dbc3b][_0x5d3d78('0x117')]?(this[_0x5d3d78('0x57')](_0xa6288b[_0x1dbc3b]),this['recallMe'](_0xa6288b[_0x1dbc3b])):notSendMessagesQueue(_0xa6288b[_0x1dbc3b]));}},Preview['prototype'][_0x2bd710('0x18')]=function(_0x2910f0){const _0x44331d=_0x2bd710,_0x5a746b=this;this[_0x44331d('0x118')]['enqueue'](function(){const _0x5d65c7=_0x44331d;if(!_[_0x5d65c7('0x130')](_0x5a746b['actions'][_0x2910f0]))return loggerAction[_0x5d65c7('0x5c')]('[clearZombieChannels][talking]',_0x2910f0,_0x5d65c7('0x8a'),_0x5a746b['actions'][_0x2910f0]['queue'],_0x5d65c7('0xc'),JSON[_0x5d65c7('0x10')](_0x5a746b[_0x5d65c7('0x9d')][_0x5a746b[_0x5d65c7('0xa')][_0x2910f0][_0x5d65c7('0x76')]]['originated']),_0x5d65c7('0x103'),JSON[_0x5d65c7('0x10')](_0x5a746b[_0x5d65c7('0x9d')][_0x5a746b[_0x5d65c7('0xa')][_0x2910f0][_0x5d65c7('0x76')]][_0x5d65c7('0xe8')]),JSON[_0x5d65c7('0x10')](_0x5a746b['actions'][_0x2910f0][_0x5d65c7('0x88')]),JSON[_0x5d65c7('0x10')](_[_0x5d65c7('0xe2')](_0x5a746b[_0x5d65c7('0xa')][_0x2910f0],['contactId',_0x5d65c7('0x4f'),_0x5d65c7('0x75'),_0x5d65c7('0x1e')]))),ami['Action']({'action':_0x5d65c7('0x74'),'channel':_0x5a746b[_0x5d65c7('0xa')][_0x2910f0][_0x5d65c7('0xf2')]})['catch'](function(_0xdb270){const _0x374a31=_0x5d65c7;_0xdb270[_0x374a31('0xca')]===_0x374a31('0x8')&&setTimeout(function(){const _0x4496fd=_0x374a31;_0x5a746b[_0x4496fd('0xa')][_0x2910f0]&&(ut[_0x4496fd('0x124')](_0x5a746b[_0x4496fd('0x9d')][_0x5a746b[_0x4496fd('0xa')][_0x2910f0]['queue']],_0x4496fd('0x134')),_0x5a746b['actions'][_0x2910f0][_0x4496fd('0x88')]===!![]&&(ut['decrementTalkink'](_0x5a746b['campaignsPreview'][_0x5a746b['actions'][_0x2910f0][_0x4496fd('0x76')]],'[clearZombieChannel]'),ut['loggerError']('[Dialer][checkChannel][pTalking][Preview]'+_0x2910f0,_0x5a746b[_0x4496fd('0xa')][_0x2910f0][_0x4496fd('0x76')])),ut[_0x4496fd('0x102')]('[Dialer][checkChannel][Preview]'+_0x2910f0,_0x5a746b[_0x4496fd('0xa')][_0x2910f0][_0x4496fd('0x76')]),delete _0x5a746b[_0x4496fd('0xa')][_0x2910f0]);},0x2328);});});},Preview[_0x2bd710('0x129')][_0x2bd710('0x39')]=function(){const _0x361bfd=_0x2bd710,_0x42be57=this;loggerAction['info'](_0x361bfd('0x2f'),_[_0x361bfd('0xcb')](this[_0x361bfd('0xa')]));for(const _0x39aed7 in this[_0x361bfd('0xa')]){typeof _0x42be57[_0x361bfd('0xa')][_0x39aed7]!==_0x361bfd('0x50')&&_0x42be57[_0x361bfd('0x18')](_0x39aed7);}},Preview[_0x2bd710('0x129')][_0x2bd710('0x6d')]=function(_0x206576){const _0x6c22f0=_0x2bd710,_0x3b6bee=this;rpcDb[_0x6c22f0('0x7c')](_0x206576['id'],ut[_0x6c22f0('0x79')](this['agents']))[_0x6c22f0('0x3f')](function(_0x2f9867){const _0x57d803=_0x6c22f0;if(!_[_0x57d803('0x130')](_0x2f9867))for(let _0x3bb048=0x0;_0x3bb048<_0x2f9867['length'];_0x3bb048+=0x1){if(ut[_0x57d803('0x4e')](_0x2f9867[_0x3bb048]['scheduledat'])<_0x206576[_0x57d803('0x109')]*0x3c)_0x2f9867[_0x3bb048][_0x57d803('0xa8')]&&!_0x2f9867[_0x3bb048][_0x57d803('0xa8')]['voicePause']?_0x3b6bee[_0x57d803('0x96')](_0x2f9867[_0x3bb048]['id'])['then'](ut[_0x57d803('0x12c')](_0x57d803('0xdf')))[_0x57d803('0x1b')](ut[_0x57d803('0x12c')](_0x57d803('0xdf'))):rpcDb['disableContact'](_0x2f9867[_0x3bb048]['id']);else{const _0x29696d=new Action(_0x2f9867[_0x3bb048],_0x206576);_0x29696d[_0x57d803('0x135')]=moment()[_0x57d803('0xc5')]('YYYY-MM-DD\x20HH:mm:ss'),_0x206576['outboundReCallsDay']+=0x1,ut['logCustomer'](_0x29696d,0x17,_0x57d803('0x123')),_0x206576['dialRecallInQueue']?(rpcDb[_0x57d803('0xba')](ut[_0x57d803('0x2b')](_0x2f9867[_0x3bb048])),rpcDb[_0x57d803('0x7b')](_0x29696d,_0x57d803('0xb2'))):(ut[_0x57d803('0xa1')](_0x29696d,0x16,_0x57d803('0x92')),rpcDb[_0x57d803('0x7b')](_0x29696d,_0x57d803('0x35')),rpcDb[_0x57d803('0x23')](_0x29696d,_0x57d803('0x35')));}}})[_0x6c22f0('0x1b')](ut['logger2'](_0x6c22f0('0x1f')));},Preview[_0x2bd710('0x129')]['setMessage']=function(_0x3b9d5f){const _0x70dfad=_0x2bd710;_0x3b9d5f[_0x70dfad('0x127')]=!![];if(ut[_0x70dfad('0xe9')](_0x3b9d5f['loggedIn']))_0x3b9d5f[_0x70dfad('0xca')]='AGENTS_NOT_LOGGED';else{if(!ut[_0x70dfad('0x61')](_0x3b9d5f[_0x70dfad('0x117')]))_0x3b9d5f[_0x70dfad('0xca')]=_0x70dfad('0x104');else!this[_0x70dfad('0xcf')](_0x3b9d5f[_0x70dfad('0x45')])?!this[_0x70dfad('0xcf')](_0x3b9d5f['TrunkBackup'])?_0x3b9d5f[_0x70dfad('0xca')]=_0x70dfad('0xed'):_0x3b9d5f[_0x70dfad('0xca')]=_0x70dfad('0x122'):_0x3b9d5f['message']=_0x70dfad('0x122');}emitCampaignPreview(_0x3b9d5f);},Preview[_0x2bd710('0x129')][_0x2bd710('0x133')]=function(_0xb31613,_0x3b210c,_0x578397){const _0x24a45d=_0x2bd710,_0x192747=this[_0x24a45d('0xa')][_0x3b210c],_0x1c4153=this['campaignsPreview'][_0x192747[_0x24a45d('0x76')]];let _0xf51d95;if(_0x1c4153){switch(_0x578397){case'1':_0x1c4153['outboundNoSuchCallsDay']+=0x1,_0x192747['countnosuchnumberretry']+=0x1,_0x192747[_0x24a45d('0x31')]=ut[_0x24a45d('0x66')](_0x192747),ut[_0x24a45d('0xa1')](_0x192747,0x0,_0x24a45d('0x25')),ami[_0x24a45d('0x7f')](_0x24a45d('0x111'),ut['buildObj'](_0x192747,_0x24a45d('0x138'))),rpcDb[_0x24a45d('0x7b')](_0x192747,_0x24a45d('0xfa'));ut[_0x24a45d('0x66')](_0x192747)>=_0x1c4153[_0x24a45d('0x8c')]?(_0xf51d95=ut[_0x24a45d('0x73')](_0x192747,0xf,_0x24a45d('0xe3')),rpcDb['createCustomerFinal'](_0xf51d95,_0x24a45d('0xbb'))):_0x192747['countnosuchnumberretry']>=_0x1c4153[_0x24a45d('0x7')]?rpcDb[_0x24a45d('0x23')](_0x192747,_0x24a45d('0xbb')):rpcDb[_0x24a45d('0x86')](ut[_0x24a45d('0x47')](_0x192747,_0x24a45d('0xda'),_0x1c4153[_0x24a45d('0xb4')]),_0x192747[_0x24a45d('0xbc')],_0x192747[_0x24a45d('0x58')]);delete this[_0x24a45d('0xa')][_0xb31613['linkedid']];break;case _0x24a45d('0x126'):{const _0xdf7ebf=moment()['format'](_0x24a45d('0xeb'));_0x192747['responsetime']=_0xdf7ebf,_0x192747[_0x24a45d('0xc6')]=_0xdf7ebf,_0x192747[_0x24a45d('0x88')]=!![],_0x1c4153[_0x24a45d('0xe8')]+=0x1,logger[_0x24a45d('0x5c')](_0x24a45d('0xfb'),_0x192747[_0x24a45d('0x3')],'\x20Queue',_0x1c4153[_0x24a45d('0x43')],_0x24a45d('0x103'),_0x1c4153[_0x24a45d('0xe8')]),ami[_0x24a45d('0x7f')]('custom:agentconnect',ut[_0x24a45d('0x33')](_0x192747,_0x24a45d('0x6b'))),_0x1c4153['acw']&&ami['emit'](_0x24a45d('0x84'),ut[_0x24a45d('0xce')](_0x192747));}break;case'16':ami[_0x24a45d('0x7f')]('custom:agentcomplete',ut['buildObj'](_0x192747,'complete')),emitVoiceQueueChannelRemove(ut[_0x24a45d('0x33')](_0x192747,'complete')),_0x1c4153['outboundAnswerCallsDay']+=0x1,_0x1c4153[_0x24a45d('0x106')]+=0x1,_0x1c4153[_0x24a45d('0xe7')]+=0x1,ut['decrementTalkink'](_0x1c4153,_0x24a45d('0xb0')),_0x192747['countglobal']=ut[_0x24a45d('0x66')](_0x192747),ut[_0x24a45d('0xa1')](_0x192747,0x4,'Answer'),rpcDb[_0x24a45d('0x7b')](_0x192747,'[callProgressDetectingCustomer][logAnswer]'),rpcDb['createCustomerFinal'](_0x192747,_0x24a45d('0x9e')),rpcDb[_0x24a45d('0x110')](_0x192747),_0x1c4153[_0x24a45d('0x105')]+=_0x192747[_0x24a45d('0x8b')],_0x1c4153['sumBillable']+=_0x192747[_0x24a45d('0x8b')],logger[_0x24a45d('0x5c')](_0x24a45d('0x108'),_0x192747['uniqueid'],'\x20Queue',_0x1c4153['name'],_0x24a45d('0x103'),_0x1c4153[_0x24a45d('0xe8')]),delete this[_0x24a45d('0xa')][_0xb31613['linkedid']];break;case'BUSY':_0x1c4153[_0x24a45d('0x12a')]+=0x1,_0x192747[_0x24a45d('0x80')]+=0x1,_0x192747[_0x24a45d('0x31')]=ut[_0x24a45d('0x66')](_0x192747),ut[_0x24a45d('0xa1')](_0x192747,0x5,'Busy'),ami['emit'](_0x24a45d('0x120'),ut[_0x24a45d('0x33')](_0x192747,_0x24a45d('0xee'))),rpcDb[_0x24a45d('0x7b')](_0x192747,_0x24a45d('0x28'));ut[_0x24a45d('0x66')](_0x192747)>=_0x1c4153['dialGlobalMaxRetry']?(_0xf51d95=ut[_0x24a45d('0x73')](_0x192747,0xf,_0x24a45d('0xe3')),rpcDb[_0x24a45d('0x23')](_0xf51d95,'[callProgressDetectingCustomer][logBusyGlobal]')):_0x192747[_0x24a45d('0x80')]>=_0x1c4153[_0x24a45d('0x56')]?rpcDb['createCustomerFinal'](_0x192747,_0x24a45d('0x28')):rpcDb[_0x24a45d('0x86')](ut[_0x24a45d('0x47')](_0x192747,_0x24a45d('0x80'),_0x1c4153[_0x24a45d('0xd8')]),_0x192747[_0x24a45d('0xbc')],_0x192747['activeContact']);break;case _0x24a45d('0x115'):_0x1c4153[_0x24a45d('0xde')]+=0x1,_0x192747[_0x24a45d('0xe')]+=0x1,_0x192747[_0x24a45d('0x31')]=ut['totalGlobal'](_0x192747),ut['logCustomer'](_0x192747,0x3,_0x24a45d('0x95')),ami[_0x24a45d('0x7f')](_0x24a45d('0xb6'),ut[_0x24a45d('0x33')](_0x192747,'noanswer')),rpcDb['createCustomerHistory'](_0x192747,_0x24a45d('0xc3'));ut['totalGlobal'](_0x192747)>=_0x1c4153[_0x24a45d('0x8c')]?(_0xf51d95=ut[_0x24a45d('0x73')](_0x192747,0xf,_0x24a45d('0xe3')),rpcDb[_0x24a45d('0x23')](_0xf51d95,_0x24a45d('0x69'))):_0x192747['countnoanswerretry']>=_0x1c4153[_0x24a45d('0xe5')]?rpcDb[_0x24a45d('0x23')](_0x192747,_0x24a45d('0xc3')):rpcDb[_0x24a45d('0x86')](ut[_0x24a45d('0x47')](_0x192747,_0x24a45d('0xe'),_0x1c4153['dialNoAnswerRetryFrequency']),_0x192747['unlockAgent'],_0x192747[_0x24a45d('0x58')]);break;case _0x24a45d('0x5b'):_0x1c4153[_0x24a45d('0x67')]+=0x1,_0x192747[_0x24a45d('0xc2')]+=0x1,_0x192747['countglobal']=ut[_0x24a45d('0x66')](_0x192747),ut['logCustomer'](_0x192747,0x8,_0x24a45d('0x5f')),ami[_0x24a45d('0x7f')](_0x24a45d('0xbf'),ut[_0x24a45d('0x33')](_0x192747,_0x24a45d('0x5d'))),rpcDb['createCustomerHistory'](_0x192747,_0x24a45d('0x10e'));ut[_0x24a45d('0x66')](_0x192747)>=_0x1c4153[_0x24a45d('0x8c')]?(_0xf51d95=ut[_0x24a45d('0x73')](_0x192747,0xf,_0x24a45d('0xe3')),rpcDb['createCustomerFinal'](_0xf51d95,'[callProgressDetectingCustomer][logCongestionGlobal]')):_0x192747['countcongestionretry']>=_0x1c4153['dialCongestionMaxRetry']?rpcDb['createCustomerFinal'](_0x192747,_0x24a45d('0x10e')):rpcDb[_0x24a45d('0x86')](ut[_0x24a45d('0x47')](_0x192747,_0x24a45d('0xc2'),_0x1c4153[_0x24a45d('0xd8')]),_0x192747[_0x24a45d('0xbc')],_0x192747[_0x24a45d('0x58')]);break;case _0x24a45d('0x85'):_0x1c4153[_0x24a45d('0xf7')]+=0x1,_0x192747['countagentrejectretry']+=0x1,_0x192747[_0x24a45d('0x31')]=ut[_0x24a45d('0x66')](_0x192747),ut['logCustomer'](_0x192747,0x14,_0x24a45d('0x29')),ami[_0x24a45d('0x7f')]('custom:agentreject',ut[_0x24a45d('0x33')](_0x192747,_0x24a45d('0xd2'))),rpcDb[_0x24a45d('0x7b')](_0x192747,_0x24a45d('0xa0'));ut[_0x24a45d('0x66')](_0x192747)>=_0x1c4153[_0x24a45d('0x8c')]?(_0xf51d95=ut['cloneAction'](_0x192747,0x14,'AgentReject'),rpcDb[_0x24a45d('0x23')](_0xf51d95,_0x24a45d('0x97'))):_0x192747['countagentrejectretry']>=_0x1c4153['dialAgentRejectMaxRetry']?rpcDb[_0x24a45d('0x23')](_0x192747,_0x24a45d('0x97')):rpcDb[_0x24a45d('0x86')](ut[_0x24a45d('0x47')](_0x192747,_0x24a45d('0xec'),_0x1c4153[_0x24a45d('0x46')]),_0x192747[_0x24a45d('0xbc')],_0x192747[_0x24a45d('0x58')]);break;case _0x24a45d('0x10a'):_0x1c4153[_0x24a45d('0xfd')]+=0x1,_0x192747[_0x24a45d('0xa5')]+=0x1,_0x192747[_0x24a45d('0x31')]=ut[_0x24a45d('0x66')](_0x192747),ut[_0x24a45d('0xa1')](_0x192747,0xb,_0x24a45d('0x9b')),rpcDb['createCustomerHistory'](_0x192747,_0x24a45d('0x2c'));ut['totalGlobal'](_0x192747)>=_0x1c4153[_0x24a45d('0x8c')]?(_0xf51d95=ut[_0x24a45d('0x73')](_0x192747,0xf,_0x24a45d('0xe3')),rpcDb[_0x24a45d('0x23')](_0xf51d95,_0x24a45d('0x2c'))):_0x192747[_0x24a45d('0xe4')]>=_0x1c4153[_0x24a45d('0x7d')]?rpcDb[_0x24a45d('0x23')](_0x192747,_0x24a45d('0x2c')):rpcDb['rescheduleContact'](ut[_0x24a45d('0x47')](_0x192747,_0x24a45d('0xa5'),_0x1c4153[_0x24a45d('0xb7')]),_0x192747[_0x24a45d('0xbc')],_0x192747[_0x24a45d('0x58')]);break;default:_0x192747[_0x24a45d('0x88')]&&(ut['decrementTalkink'](_0x1c4153,'[default]'),ut['loggerError'](_0x24a45d('0x8e')+_0x1c4153['name'],_0xb31613));_0x1c4153[_0x24a45d('0xe6')]+=0x1,_0x192747[_0x24a45d('0x31')]=ut[_0x24a45d('0x66')](_0x192747),ut[_0x24a45d('0xa1')](_0x192747,0xc,_0xb31613[_0x24a45d('0xb8')]||_0xb31613['dialstatus']),rpcDb[_0x24a45d('0x7b')](_0x192747,_0x24a45d('0x20'));ut['totalGlobal'](_0x192747)>=_0x1c4153[_0x24a45d('0x8c')]?(_0xf51d95=ut[_0x24a45d('0x73')](_0x192747,0xf,_0x24a45d('0xe3')),rpcDb[_0x24a45d('0x23')](_0xf51d95,_0x24a45d('0xa9'))):rpcDb[_0x24a45d('0x23')](_0x192747,_0x24a45d('0xa9'));delete this[_0x24a45d('0xa')][_0xb31613['linkedid']];}!(_0x192747[_0x24a45d('0x88')]&&_0x578397==='16')&&(ut[_0x24a45d('0x124')](_0x1c4153,_0x24a45d('0xf3')),logger['info'](_0x24a45d('0x5e'),_0x192747[_0x24a45d('0x3')],'\x20Queue',_0x1c4153[_0x24a45d('0x43')],_0x24a45d('0xc'),_0x1c4153[_0x24a45d('0x6')])),_0x578397!==_0x24a45d('0x126')&&(delete this['actions'][_0xb31613[_0x24a45d('0xf6')]],delete this[_0x24a45d('0xa')][_0xb31613[_0x24a45d('0xd3')]]);}},Preview[_0x2bd710('0x129')][_0x2bd710('0x125')]=function(_0x5807f3,_0x2206c0,_0x411dd5){const _0x4864ff=_0x2bd710;if(_[_0x4864ff('0xf0')](_0x2206c0)&&_0x4864ff('0x24')!==typeof _0x2206c0)return;if(_[_0x4864ff('0xf0')](_0x411dd5)&&_0x4864ff('0x24')!==typeof _0x411dd5)return;switch(_0x411dd5[_0x4864ff('0x32')]){case'0':ut[_0x4864ff('0x38')](_0x5807f3,0x0,'NoSuchNumber'),rpcDb['createAgentHistory'](_0x5807f3,_0x4864ff('0x4d'));break;case'3':ut['logAgent'](_0x5807f3,0x3,_0x4864ff('0x95')),rpcDb[_0x4864ff('0x9')](_0x5807f3,'[callProgressDetectingAgent][logNoAnswer]');break;case'5':ut[_0x4864ff('0x38')](_0x5807f3,0x5,_0x4864ff('0x5')),rpcDb['createAgentHistory'](_0x5807f3,_0x4864ff('0x9c'));break;case'8':ut[_0x4864ff('0x38')](_0x5807f3,0x8,_0x4864ff('0x5f')),rpcDb[_0x4864ff('0x9')](_0x5807f3,_0x4864ff('0xdd'));break;case'22':ut[_0x4864ff('0x38')](_0x5807f3,0x16,_0x4864ff('0xf5')),rpcDb[_0x4864ff('0x9')](_0x5807f3,_0x4864ff('0x12f'));break;default:ut[_0x4864ff('0x38')](_0x5807f3,0xc,_0x411dd5[_0x4864ff('0x32')]),rpcDb[_0x4864ff('0x9')](_0x5807f3,_0x4864ff('0xdd'));}ut[_0x4864ff('0x124')](_0x2206c0,'[callProgressDetectingAgent]'),logger[_0x4864ff('0x5c')]('[originated][decrement][callProgressDetectingAgent]',_0x5807f3[_0x4864ff('0x3')],'\x20Queue',_0x2206c0[_0x4864ff('0x43')],_0x4864ff('0xc'),_0x2206c0['originated']),delete this[_0x4864ff('0xa')][_0x5807f3[_0x4864ff('0x3')]];},Preview[_0x2bd710('0x129')]['checkInBlack']=function(_0x5e84c5,_0x283126,_0x45b06a,_0xa6405d,_0x265551){const _0x503a93=this;return new Promise(function(_0x533c1e,_0x398bb6){const _0x2cd6c7=a1088_0x35f5;if(_['isNil'](_0x283126)||_['isNil'](_0x283126[_0x2cd6c7('0x4b')])||_[_0x2cd6c7('0x130')](_0x283126['Contact'][_0x2cd6c7('0x9f')])||_[_0x2cd6c7('0x130')](_0x283126[_0x2cd6c7('0x75')])){_0x398bb6(ut[_0x2cd6c7('0xca')](_0x2cd6c7('0x27'),_0xa6405d,_0x265551));return;}const _0x25b40=uuid['v4'](),_0x3f23bf=_0x503a93[_0x2cd6c7('0x9d')][_0x283126[_0x2cd6c7('0x8a')]['name']],_0x5695cc=_0x45b06a?_0x503a93[_0x2cd6c7('0x87')][_0x45b06a]['id']:undefined;_0x503a93[_0x2cd6c7('0xa')][_0x25b40]=new Action(_0x283126,_0x3f23bf,_0x25b40,_0x45b06a,_0x5695cc);const _0x446f80=_0x503a93[_0x2cd6c7('0xa')][_0x25b40];_0x446f80[_0x2cd6c7('0xbc')]=_0xa6405d,_0x446f80[_0x2cd6c7('0x58')]=_0x265551,_0x446f80[_0x2cd6c7('0x6a')]=_0x45b06a,_['isEmpty'](_0x5e84c5)?_0x503a93[_0x2cd6c7('0x19')](_0x446f80,_0x3f23bf,_0x283126,_0x45b06a)[_0x2cd6c7('0x3f')](function(_0x30b337){const _0x1228c9=_0x2cd6c7;logger['info'](_0x1228c9('0x13'),'Queue:\x20'+_0x446f80[_0x1228c9('0x76')]+'\x20IdHopper:\x20'+_0x446f80[_0x1228c9('0x64')],JSON[_0x1228c9('0x10')](_0x30b337)),ami['emit']('custom:agentcalled',ut[_0x1228c9('0x33')](_0x446f80,_0x1228c9('0x78'))),_0x533c1e(ut[_0x1228c9('0xca')]('Calling'));})[_0x2cd6c7('0x1b')](function(_0x33a6aa){const _0x2fe56c=_0x2cd6c7;ut[_0x2fe56c('0x3b')]('[Preview][execCall][failure]',_0x33a6aa),_0x398bb6(ut[_0x2fe56c('0xca')](_0x2fe56c('0xa7'),_0xa6405d,_0x265551));}):(_0x3f23bf[_0x2cd6c7('0x98')]+=0x1,ut['logBlacklist'](_0x446f80),rpcDb[_0x2cd6c7('0xfc')](_0x446f80,_0x2cd6c7('0x12')),delete _0x503a93['actions'][_0x25b40],_0x398bb6(ut[_0x2cd6c7('0xca')]('Contact\x20in\x20black\x20List',_0xa6405d,_0x265551)));});},Preview['prototype'][_0x2bd710('0xcf')]=function(_0x5ab1f4){const _0xb3ff52=_0x2bd710;return!_[_0xb3ff52('0x130')](_0x5ab1f4)&&!_[_0xb3ff52('0x130')](_0x5ab1f4[_0xb3ff52('0x43')])&&!_[_0xb3ff52('0x130')](_0x5ab1f4['active'])&&_0x5ab1f4[_0xb3ff52('0x6f')]&&!_['isNil'](this[_0xb3ff52('0xbd')][util['format'](_0xb3ff52('0x3d'),_0x5ab1f4['name'])])&&!_[_0xb3ff52('0x130')](this[_0xb3ff52('0xbd')][util[_0xb3ff52('0xc5')](_0xb3ff52('0x3d'),_0x5ab1f4[_0xb3ff52('0x43')])][_0xb3ff52('0x74')])&&(this[_0xb3ff52('0xbd')][util['format']('SIP/%s',_0x5ab1f4['name'])][_0xb3ff52('0x74')]==='reachable'||this[_0xb3ff52('0xbd')][util[_0xb3ff52('0xc5')](_0xb3ff52('0x3d'),_0x5ab1f4['name'])][_0xb3ff52('0x74')]===_0xb3ff52('0xb3'));},Preview[_0x2bd710('0x129')][_0x2bd710('0x96')]=function(_0x289388,_0x254f8a){const _0x14fceb=this;return new Promise(function(_0x3b14ba,_0x53a23f){const _0x41c9db=a1088_0x35f5;_0x14fceb[_0x41c9db('0x77')](_0x289388,_0x254f8a)[_0x41c9db('0x3f')](function(_0x1e6326){const _0x44ed01=_0x41c9db;_0x3b14ba(_[_0x44ed01('0xe2')](_0x1e6326,[_0x44ed01('0xca')]));})[_0x41c9db('0x1b')](function(_0x243caf){const _0x370768=_0x41c9db;_0x243caf[_0x370768('0x63')]&&rpcDb['unlockContact'](_0x289388),_0x243caf[_0x370768('0x6f')]&&rpcDb[_0x370768('0xc7')](_0x289388),_0x53a23f(_[_0x370768('0xe2')](_0x243caf,['message']));});});},Preview[_0x2bd710('0x129')][_0x2bd710('0x77')]=function(_0x333467,_0x15ffa0){const _0x217a35=this;return new Promise(function(_0x53b628,_0x1b32a8){const _0x1050fc=a1088_0x35f5;let _0xe10ac1,_0x30f4b4;rpcDb[_0x1050fc('0x2')](_0x333467)[_0x1050fc('0x3f')](function(_0x12a934){const _0x3dd995=_0x1050fc;!_[_0x3dd995('0x130')](_0x12a934[0x0])&&(_0x30f4b4=_0x12a934[0x0]['recallme']?![]:!![],_0xe10ac1=_0x12a934[0x0]['recallme']?!![]:![],_0xe10ac1=_0x15ffa0?!![]:_0xe10ac1);const _0x247745=_0x217a35['validateContact'](_0x12a934);_0x247745['isValid']?rpcDb[_0x3dd995('0xa4')](_['pick'](_0x12a934[0x0],['VoiceQueueId',_0x3dd995('0x17')]))['then'](function(_0x1971e8){const _0x3e5d8b=_0x3dd995;_0x217a35[_0x3e5d8b('0xa3')](_0x1971e8,_0x12a934[0x0],_0x15ffa0,_0x30f4b4,_0xe10ac1)[_0x3e5d8b('0x3f')](function(_0x234ec2){_0x53b628(_0x234ec2);})['catch'](function(_0x5d2784){_0x1b32a8(_0x5d2784);});})['catch'](function(_0x13941e){const _0x365926=_0x3dd995;ut[_0x365926('0x3b')](_0x365926('0x55'),_0x13941e),_0x1b32a8(ut[_0x365926('0xca')]('Call\x20unsuccessful',_0x30f4b4,_0xe10ac1));}):_0x1b32a8(ut['message'](_0x247745['message'],_0x30f4b4,_0xe10ac1));})['catch'](function(_0x2c3413){const _0x407ec5=_0x1050fc;ut[_0x407ec5('0x3b')](_0x407ec5('0x44'),_0x2c3413),_0x1b32a8(ut[_0x407ec5('0xca')](_0x407ec5('0x4c'),![],!![]));});});},Preview[_0x2bd710('0x129')][_0x2bd710('0xb1')]=function(_0x2c501e){const _0xf74cdb=_0x2bd710;if(_[_0xf74cdb('0x130')](_0x2c501e)||_[_0xf74cdb('0x94')](_0x2c501e)||!_['isNil'](_0x2c501e[0x0][_0xf74cdb('0xa8')])&&_[_0xf74cdb('0x130')](_0x2c501e[0x0]['Agent'][_0xf74cdb('0x43')]))return ut[_0xf74cdb('0x3b')](_0xf74cdb('0xdb'),_0x2c501e),{'isValid':![],'message':_0xf74cdb('0x11')};const _0x361f47=this['campaignsPreview'][_0x2c501e[0x0][_0xf74cdb('0x8a')][_0xf74cdb('0x43')]];_0x361f47[_0xf74cdb('0xca')]='ACTIVE';if(_[_0xf74cdb('0x130')](_0x361f47))return ut['logger'](_0xf74cdb('0x10f'),_0x361f47),{'isValid':![],'message':'Empty\x20Campaign'};if(!this['isTrunkReachable'](_0x361f47[_0xf74cdb('0x45')])){ut[_0xf74cdb('0x3b')]('[Preview][validateContact][Trunk\x20not\x20work]','campaign\x20Name:\x20'+_0x361f47[_0xf74cdb('0x43')]+_0xf74cdb('0x60'));if(!this[_0xf74cdb('0xcf')](_0x361f47['TrunkBackup']))return ut[_0xf74cdb('0x3b')](_0xf74cdb('0xf4'),_0x361f47[_0xf74cdb('0x43')]+'\x20Trunk\x20Backup\x20is\x20not\x20active'),{'isValid':![],'message':'Trunk\x20not\x20work'};}if(!ut[_0xf74cdb('0x61')](_0x361f47['dialActive']))return ut[_0xf74cdb('0x3b')](_0xf74cdb('0x137'),_0x361f47[_0xf74cdb('0x43')]+_0xf74cdb('0x16')),{'isValid':![],'message':_0xf74cdb('0x51')+_0x361f47[_0xf74cdb('0x43')]+_0xf74cdb('0x16')};return{'isValid':!![],'message':_0xf74cdb('0xb')};},Preview[_0x2bd710('0x129')]['execCall']=function(_0x20af65,_0x25fb45,_0x304ee9,_0x51d4b1){const _0x3cfe7a=this;return new Promise(function(_0x225bf5,_0x23f436){const _0x784f1e=a1088_0x35f5,_0x47a581=_0x20af65['uniqueid'],_0x5ad1be=_0x3cfe7a[_0x784f1e('0xcf')](_0x25fb45[_0x784f1e('0x45')])?util[_0x784f1e('0xc5')](_0x784f1e('0xea'),_0x25fb45['Trunk'][_0x784f1e('0x43')],_[_0x784f1e('0x130')](_0x25fb45[_0x784f1e('0x90')])?'':_0x25fb45['dialPrefix']['trim']()||'',_0x25fb45[_0x784f1e('0xef')]>0x0?_0x304ee9[_0x784f1e('0x4b')]['phone'][_0x784f1e('0x34')](_0x25fb45[_0x784f1e('0xef')]):_0x304ee9[_0x784f1e('0x4b')][_0x784f1e('0x9f')]):util['format'](_0x784f1e('0xea'),_['isNil'](_0x25fb45[_0x784f1e('0x3a')])?_0x25fb45[_0x784f1e('0x45')]['name']:_0x25fb45[_0x784f1e('0x3a')]['name'],_[_0x784f1e('0x130')](_0x25fb45[_0x784f1e('0x90')])?'':_0x25fb45['dialPrefix'][_0x784f1e('0xd0')]()||'',_0x25fb45['dialCutDigit']>0x0?_0x304ee9[_0x784f1e('0x4b')]['phone'][_0x784f1e('0x34')](_0x25fb45[_0x784f1e('0xef')]):_0x304ee9[_0x784f1e('0x4b')]['phone']),_0x5283b8=_0x3cfe7a[_0x784f1e('0xcf')](_0x25fb45[_0x784f1e('0x45')])?ut[_0x784f1e('0xff')](_0x25fb45[_0x784f1e('0x45')][_0x784f1e('0x14')],_0x25fb45[_0x784f1e('0x12d')],_0x25fb45[_0x784f1e('0x26')]>0x0?ut[_0x784f1e('0x7e')](_0x25fb45[_0x784f1e('0x91')],_0x25fb45[_0x784f1e('0x26')]):_0x25fb45[_0x784f1e('0x91')]):ut[_0x784f1e('0xff')](_['isNil'](_0x25fb45[_0x784f1e('0x3a')])?_0x25fb45[_0x784f1e('0x45')][_0x784f1e('0x14')]:_0x25fb45[_0x784f1e('0x3a')][_0x784f1e('0x14')],_0x25fb45['dialOriginateCallerIdName'],_0x25fb45[_0x784f1e('0x26')]>0x0?ut[_0x784f1e('0x7e')](_0x25fb45['dialOriginateCallerIdNumber'],_0x25fb45[_0x784f1e('0x26')]):_0x25fb45[_0x784f1e('0x91')]);_0x5283b8&&(_0x20af65[_0x784f1e('0x83')]=ut['extractCalleridName'](_0x5283b8),_0x20af65['originatecalleridnum']=ut[_0x784f1e('0x119')](_0x5283b8));const _0x3826ae=ut[_0x784f1e('0xad')](_0x25fb45,_0x304ee9,_0x5ad1be,_0x5283b8,_0x47a581,_0x20af65);_[_0x784f1e('0x1')](_0x20af65,ut[_0x784f1e('0x11e')](_0x3826ae)),_0x20af65['starttime']=moment()['format'](_0x784f1e('0xeb')),ami[_0x784f1e('0x62')](ut[_0x784f1e('0x8d')](_0x20af65,_0x25fb45,_0x3826ae,_0x20af65[_0x784f1e('0x58')],_0x51d4b1))[_0x784f1e('0x3f')](function(_0x268fbf){const _0x23f18d=_0x784f1e;_0x25fb45[_0x23f18d('0x6')]+=0x1,logger['info'](_0x23f18d('0x6e'),_0x47a581,'\x20Queue',_0x25fb45[_0x23f18d('0x43')],_0x23f18d('0xc'),_0x25fb45[_0x23f18d('0x6')]),_0x225bf5(_0x268fbf);})['catch'](function(_0x5ba930){const _0x506526=_0x784f1e;ut[_0x506526('0x38')](_0x20af65,0xe,_0x506526('0x48')),rpcDb['createAgentHistory'](_0x20af65,'[originateFailure][logOriginateFailure]'),_0x23f436(_0x5ba930);});});},Preview[_0x2bd710('0x129')][_0x2bd710('0x4a')]=function(_0x343b80){const _0x39ee00=_0x2bd710;this[_0x39ee00('0xa')][_0x343b80[_0x39ee00('0xf6')]]&&(this[_0x39ee00('0xa')][_0x343b80['linkedid']][_0x39ee00('0xf2')]=_0x343b80[_0x39ee00('0xf2')]);},Preview['prototype']['syncOriginateResponse']=function(_0x36c8b1){const _0xda7ce5=_0x2bd710,_0x79701f=this,_0x4e8976=this[_0xda7ce5('0xa')][_0x36c8b1[_0xda7ce5('0xaf')]];if(_0x4e8976){_0x4e8976[_0xda7ce5('0x6a')]&&this['agents'][_0x4e8976['lookAgent']]&&ut['logLookAgent'](_0x4e8976,this[_0xda7ce5('0x87')][_0x4e8976[_0xda7ce5('0x6a')]][_0xda7ce5('0x43')],this['agents'][_0x4e8976[_0xda7ce5('0x6a')]]['id']);const _0x3fd6d1=_[_0xda7ce5('0x52')](_0x4e8976);_0x3fd6d1[_0xda7ce5('0xb5')]=moment()[_0xda7ce5('0xc5')](_0xda7ce5('0xeb'));const _0xc83abd=_0x79701f[_0xda7ce5('0x9d')][_0x4e8976[_0xda7ce5('0x76')]];ut[_0xda7ce5('0x2e')](_0x36c8b1[_0xda7ce5('0x72')])?(_0x4e8976[_0xda7ce5('0xbc')]&&rpcDb[_0xda7ce5('0x22')](_0x4e8976[_0xda7ce5('0x64')]),_0x4e8976[_0xda7ce5('0x58')]&&rpcDb[_0xda7ce5('0xc7')](_0x4e8976['idContact']),ami[_0xda7ce5('0x7f')]('custom:agentringnoanswer',ut['buildObj'](_0x4e8976,'rejected')),this[_0xda7ce5('0x125')](_0x3fd6d1,_0xc83abd,_0x36c8b1)):(_0x4e8976[_0xda7ce5('0x135')]=moment()[_0xda7ce5('0xc5')](_0xda7ce5('0xeb')),ut[_0xda7ce5('0x38')](_0x3fd6d1,0x4,_0xda7ce5('0xdc')),rpcDb[_0xda7ce5('0x9')](_0x3fd6d1,_0xda7ce5('0xb9')));}},Preview['prototype'][_0x2bd710('0xd4')]=function(_0x3cf8a5){const _0x8d5a1d=_0x2bd710,_0x35dcb8=this[_0x8d5a1d('0xa')][_0x3cf8a5['linkedid']];let _0x2cde56;_0x35dcb8&&(_0x2cde56=this[_0x8d5a1d('0x9d')][_0x35dcb8[_0x8d5a1d('0x76')]],logger[_0x8d5a1d('0x5c')](_0x8d5a1d('0xf9'),_0x3cf8a5['linkedid'],_0x8d5a1d('0x112'),_0x2cde56['name'],'pTalking:\x20',_0x2cde56['pTalking']));if(this[_0x8d5a1d('0xa')][_0x3cf8a5[_0x8d5a1d('0xf6')]]&&_0x3cf8a5[_0x8d5a1d('0xf6')]!==_0x3cf8a5[_0x8d5a1d('0x3')]){if(_0x3cf8a5[_0x8d5a1d('0x71')]==='16'&&this[_0x8d5a1d('0xa')][_0x3cf8a5[_0x8d5a1d('0xf6')]][_0x8d5a1d('0x88')])this['callProgressDetectingCustomer'](_0x3cf8a5,_0x3cf8a5[_0x8d5a1d('0xf6')],_0x3cf8a5[_0x8d5a1d('0x71')]);else this[_0x8d5a1d('0xa')][_0x3cf8a5[_0x8d5a1d('0xf6')]]['dialAnswer']&&(logger['info'](_0x8d5a1d('0x40'),_0x3cf8a5[_0x8d5a1d('0xf6')],_0x3cf8a5[_0x8d5a1d('0x71')],_0x8d5a1d('0x112'),_0x2cde56[_0x8d5a1d('0x43')],_0x8d5a1d('0x103'),_0x2cde56['pTalking']),this[_0x8d5a1d('0x133')](_0x3cf8a5,_0x3cf8a5[_0x8d5a1d('0xf6')],_0x3cf8a5[_0x8d5a1d('0x71')]));}else{if(_0x35dcb8&&_[_0x8d5a1d('0x130')](_0x35dcb8[_0x8d5a1d('0xfe')])&&_0x2cde56[_0x8d5a1d('0x15')]&&_0x3cf8a5[_0x8d5a1d('0xf6')]===_0x3cf8a5['uniqueid']&&_[_0x8d5a1d('0x130')](_0x3cf8a5[_0x8d5a1d('0x32')])&&_0x3cf8a5[_0x8d5a1d('0x71')]==='16'&&_0x3cf8a5['channelstate']==='6'&&_[_0x8d5a1d('0xf0')](_0x35dcb8[_0x8d5a1d('0xae')]))_0x35dcb8[_0x8d5a1d('0xbc')]&&rpcDb[_0x8d5a1d('0x22')](_0x35dcb8[_0x8d5a1d('0x64')]),_0x35dcb8[_0x8d5a1d('0x58')]&&rpcDb[_0x8d5a1d('0xc7')](_0x35dcb8[_0x8d5a1d('0x64')]),_0x3cf8a5[_0x8d5a1d('0x32')]='22',this[_0x8d5a1d('0x125')](_0x35dcb8,_0x2cde56,_0x3cf8a5);else{if(_0x35dcb8&&_0x35dcb8[_0x8d5a1d('0xae')]){if(_0x3cf8a5[_0x8d5a1d('0x71')]==='16'&&this[_0x8d5a1d('0xa')][_0x3cf8a5['linkedid']]['dialAnswer'])logger[_0x8d5a1d('0x5c')](_0x8d5a1d('0xd6'),_0x3cf8a5[_0x8d5a1d('0xf6')],_0x3cf8a5[_0x8d5a1d('0x71')],_0x8d5a1d('0x112'),_0x2cde56['name'],_0x8d5a1d('0x103'),_0x2cde56[_0x8d5a1d('0xe8')]),this[_0x8d5a1d('0x133')](_0x3cf8a5,_0x3cf8a5[_0x8d5a1d('0xf6')],_0x3cf8a5[_0x8d5a1d('0x71')]);else this['actions'][_0x3cf8a5[_0x8d5a1d('0xf6')]]['dialAnswer']&&(logger[_0x8d5a1d('0x5c')](_0x8d5a1d('0x40'),_0x3cf8a5['linkedid'],_0x3cf8a5[_0x8d5a1d('0x71')],_0x8d5a1d('0x112'),_0x2cde56[_0x8d5a1d('0x43')],_0x8d5a1d('0x103'),_0x2cde56[_0x8d5a1d('0xe8')]),this[_0x8d5a1d('0x133')](_0x3cf8a5,_0x3cf8a5[_0x8d5a1d('0xf6')],_0x3cf8a5[_0x8d5a1d('0x71')]));}}}},Preview['prototype'][_0x2bd710('0x0')]=function(_0x39dd19){const _0x20b319=_0x2bd710;this[_0x20b319('0xa')][_0x39dd19['destlinkedid']]&&_0x39dd19[_0x20b319('0xd3')]!==_0x39dd19[_0x20b319('0xf8')]&&this[_0x20b319('0x133')](_0x39dd19,_0x39dd19[_0x20b319('0xd3')],_0x39dd19[_0x20b319('0x132')]);},Preview[_0x2bd710('0x129')][_0x2bd710('0xf')]=function(_0x503fe5){const _0x171243=_0x2bd710;this[_0x171243('0xa')][_0x503fe5['linkedid']]&&_0x503fe5[_0x171243('0xf6')]!==_0x503fe5[_0x171243('0x3')]&&!this[_0x171243('0xa')][_0x503fe5['linkedid']]['dialAnswer']&&(_0x503fe5[_0x171243('0x71')]==='1'&&this['callProgressDetectingCustomer'](_0x503fe5,_0x503fe5['linkedid'],_0x503fe5['cause']));},Preview[_0x2bd710('0x129')][_0x2bd710('0x101')]=function(_0xc596b5,_0x4d8111,_0x1f1293){const _0x2b2db6=_0x2bd710;this[_0x2b2db6('0xa')][_0xc596b5]&&(_[_0x2b2db6('0x130')](this['actions'][_0xc596b5][_0x2b2db6('0x3c')])&&(this['actions'][_0xc596b5][_0x2b2db6('0x3c')]={}),this['actions'][_0xc596b5][_0x2b2db6('0x3c')][_0x4d8111]=_0x1f1293);},Preview[_0x2bd710('0x129')][_0x2bd710('0x136')]=function(_0x2f6c60){const _0x59c76f=_0x2bd710;try{!_['isNil'](_0x2f6c60)&&(ut[_0x59c76f('0xd')](_[_0x59c76f('0x1d')](_0x2f6c60[_0x59c76f('0x5a')])[0x0])&&this[_0x59c76f('0x101')](_0x2f6c60[_0x59c76f('0x3')],_['keys'](_0x2f6c60['variable'])[0x0],_0x2f6c60[_0x59c76f('0x121')]));}catch(_0xa5e358){logger[_0x59c76f('0x53')](_0x59c76f('0x12b'),util[_0x59c76f('0xd1')](_0xa5e358,{'showHidden':![],'depth':null}));}},Preview[_0x2bd710('0x129')][_0x2bd710('0x9a')]=function(_0x4683ed){const _0x521549=_0x2bd710;_0x4683ed&&(this['actions'][_0x4683ed[_0x521549('0x114')]]&&(this[_0x521549('0xa')][_0x4683ed[_0x521549('0x114')]]['transfer']=!![]));},Preview[_0x2bd710('0x129')]['syncBlindTransfer']=function(_0x2e170c){const _0x332d76=_0x2bd710;_0x2e170c&&(this[_0x332d76('0xa')][_0x2e170c[_0x332d76('0xc9')]]&&(this[_0x332d76('0xa')][_0x2e170c['transfererlinkedid']][_0x332d76('0xae')]=!![]));},module[_0x2bd710('0x1a')]=Preview; \ No newline at end of file +const a1088_0x2e70=['[syncHangup][talking][cause]','logCustomer','noanswer','RecallFailedTimeout','dialOriginateCallerIdNumber','[syncHangup][talking][increment]','custom:agentConnectPreview','originatecalleridname','isTrunkReachable','outboundAbandonedCallsDay','[Preview][execCall][failure]','total','syncDialEnd','dialNoAnswerRetryFrequency','dialend','[Preview][validateContact][Empty\x20Contact]','loopCampaigns','[Preview][validateContact][Trunk\x20not\x20work]','contactId','extractCalleridName','logger2','actionid','campaign\x20Name:\x20','predictiveIntervalTotalCalls','run','util','\x20Queue','outboundUnknownCallsDay','[Dialer][decrementTalkink][no\x20Hangup][Preview]','syncHangup','[callProgressDetectingCustomer][logCongestionGlobal]','agents','OriginateError','outboundBlacklistCallsDay','lodash','predictiveIntervalErlangCalls','size','unlockContact','[callProgressDetectingCustomer][logBusy]','createAgentHistory','Queue:\x20','dialMethod','sumHoldTime','No\x20such\x20channel','[default]','Empty\x20Campaign','[callProgressDetectingCustomer][logAnswerGlobal]','loggerError','syncBlindTransfer','outboundAnswerCallsDay','booked','custom:agentconnect','Interval','talktime','clone','originated','predictiveIntervalPauses','varset','loggedIn','dialOriginateTimeout','startPredictive','syncOriginateResponse','md5','voicePause','[callProgressDetectingCustomer]','checkInBlack','status','outbound','toLowerVariables','rescheduleContact','[syncVarSet][Preview]','blindtransfer','statedesc','moment','outboundNoAnswerCallsDay','recallMe','dialCutDigit','outboundRejectCallsDay','destuniqueid','then','isEmpty','SIP/%s/%s%s','logLookAgent','countcongestionretry','countagentrejectretry','dialBusyMaxRetry','setMessage','syncAttendedTransfer','UserId','[callProgressDetectingCustomer][logUnknownGlobal]','callProgressDetectingAgent','tail','name','[callProgressDetectingCustomer][logAbandoned]','sendMessageOneNotActive','custom:agentnoanswer','dialNoSuchNumberRetryFrequency','[action]','./rpcDb','stringify','[syncHangup][talking][transfer]','uniqueid','scheduledAt','attendedtransfer','dialAgentRejectRetryFrequency','outboundOriginateFailureCallsDay','cause-txt','predictiveIntervalAvgTalktime','SIP/%s','custom:agentbusy','actions','custom:agentnosuchnumber','AnswerAGI','predictiveIntervalAvailable','dialNoAnswerMaxRetry','erlangAbandonmentRate','getContactRecallMe','[Dialer][checkChannel][Preview]','isUndefined','\x20is\x20disactive','../../../config/logger','newexten','object','keys','[Preview][checkIsBlackList]','YYYY-MM-DD\x20HH:mm:ss','[Dialer][checkChannel][pTalking][Preview]','outboundAnswerAgiCallsDay','syncCampaigns','starttime','getCallerIdRandom','available','linkedid','transfererlinkedid','sumBillable','sumDuration','dialNoSuchNumberMaxRetry','decrementTalkink','NoSuchNumber','[CampaignPreview]\x20Campaign\x20Queue:\x20','startProgressive','Contact\x20is\x20undefined','countabandonedetry','[callProgressDetectingCustomer][logAnswer]','idContact','clockClearZombieChannels','bind','[clearZombieChannels][talking]','inspect','predictiveIntervalErlangCallsDroppedCalls','[callProgressDetectingCustomer][logNoAnswer]','TrunkBackup','Contact\x20in\x20black\x20List','addVariable','trunks','[callProgressDetectingCustomer][logNoSuchGlobal]','[Preview][validateContact][Campaign\x20Active]','predictiveIntervalDroppedCallsTimeout','catch','dialGlobalMaxRetry','[originated][increment]','busy','buildObj','IS_DISACTIVED','countnosuchnumberretry','Global','\x20Not\x20Active','totalGlobal','type','\x20Trunk\x20is\x20not\x20active','pTalking','hangup','variables','callerid','isActive','error','trim','ACTIVE','cause','voice_queue:save','[callProgressDetectingAgent][logAnswerAGI]','[originateFailure][logOriginateFailure]','custom:agentcongestion','agentreject','Answer','phone','createCustomerFinal','CONGESTION','campaignsPreview','[getContactRecallMe]','erlangCallToSecond','updateOriginated','dialRandomLastDigitCallerIdNumber','abandoned','Congestion','getDiff','custom:agentringnoanswer','[syncHangupRequest][logAgentReject]','[callProgressDetectingAgent]','pick','countbusyretry','Contact','originateresponse','[callProgressDetectingAgent][logNoSuch]','responsetime','createHistory','dialAbandonedMaxRety','[callProgressDetectingAgent][logCongestion]','IsNotLoggedIn','answered','dialstatus','lookAgent','filterKey','outboundBusyCallsDay','active','undefined','prototype','syncVarSet','Agent','response','outboundNoSuchCallsDay','custom:agentreject','enqueue','logAgent','countglobal','NoAnswer','callProgressDetectingCustomer','voice:queue:%s','custom:agentcalled','Queue','waiting','execRun','connect','outboundCongestionCallsDay','Call\x20unsuccessful','getContactPreview','[RecallMe]','length','predictiveIntervalAnsweredCalls','actionPreview','\x20Trunk\x20Backup\x20is\x20not\x20active','variable','hanguprequest','uuid','outboundDropCallsDayTimeout','[callProgressDetectingAgent][logNoAnswer]','Is\x20Valid','dialCongestionMaxRetry','format','Busy','acw','dialAbandonedRetryFrequency','Action','[16]','message','emit','transfertargetlinkedid','[Preview][validateContact][Empty\x20Campaign]','syncHangupRequest','preview','originatecalleridnum','countabandonedretry','finally','unmanaged','dialActive','ANSWER','[HistoryRecallClose]','syncNewExten','[callProgressDetectingCustomer][logAgentReject]','TRUNK_IS_NOT_REACHABLE','predictiveIntervalHitRate','logger','ABANDONED','unmonitored','loggedInDb','info','[callProgressDetectingAgent][logAnswer]','addVariables','[originated][decrement][callProgressDetectingCustomer]','logBlacklist','Contact.phone','predictiveIntervalMultiplicativeFactor','transfer','CANCEL','destlinkedid','cloneAction','predictiveIntervalDroppedCallsCallersExit','Call\x20failed','voice_queue_channel:remove','isValid','unlockAgent','pTalking:\x20','agentReadyId','channel','called','clearZombieChannels','[Preview][execCall][success]','reason','dialRecallInQueue','originated:\x20','\x20is\x20not\x20active','complete','Trunk\x20not\x20work','dialPrefix','dialBusyRetryFrequency','getCallerId','dialOriginateCallerIdName','checkIsBlackList','[originated][decrement][callProgressDetectingAgent]','../ami','[Preview][getContactPreview]','[callProgressDetectingCustomer][logCongestion]','outboundReCallsDay','VoiceQueueId','[syncHangup][talking]','substring','[HistoryDialRecallInQueue][historyCatch]','disableContact','isNil','activeContact','countnoanswerretry','[clearZombieChannel]','NOT_ACTIVE','[callProgressDetectingCustomer][logUnknown]','validateContact','dialAnswer','recallme','AgentReject','buildAcw','[callProgressDetectingAgent][logBusy]','createCustomerHistory','queue','Trunk'];(function(_0x4cf785,_0x2e7000){const _0x1ab134=function(_0x23c6cc){while(--_0x23c6cc){_0x4cf785['push'](_0x4cf785['shift']());}};_0x1ab134(++_0x2e7000);}(a1088_0x2e70,0x112));const a1088_0x1ab1=function(_0x4cf785,_0x2e7000){_0x4cf785=_0x4cf785-0x0;let _0x1ab134=a1088_0x2e70[_0x4cf785];return _0x1ab134;};const _0x1bdf48=a1088_0x1ab1;'use strict';const util=require(_0x1bdf48('0x54')),_=require(_0x1bdf48('0x5d')),uuid=require(_0x1bdf48('0x12e')),moment=require(_0x1bdf48('0x84')),md5=require(_0x1bdf48('0x79')),logger=require(_0x1bdf48('0xb3'))(_0x1bdf48('0x13e')),loggerAction=require(_0x1bdf48('0xb3'))(_0x1bdf48('0x12a')),ami=require(_0x1bdf48('0x23')),rpcDb=require(_0x1bdf48('0x9d')),Action=require('./action'),ut=require('./util/util'),{getSocket}=require('../../../rediscache'),io=getSocket(),Sequence=function(){};Sequence[_0x1bdf48('0x113')]['enqueue']=function(_0x23c6cc){const _0x54aa58=_0x1bdf48;this['tail']=this['tail']?this[_0x54aa58('0x96')][_0x54aa58('0x141')](_0x23c6cc):_0x23c6cc();};function Preview(_0x2c3af3){const _0x52e20a=_0x1bdf48;this['sequence']=new Sequence(),this[_0x52e20a('0xf7')]=_0x2c3af3['voiceQueues'],this[_0x52e20a('0xd5')]=_0x2c3af3[_0x52e20a('0xd5')],this['actions']={},this[_0x52e20a('0x5a')]=_0x2c3af3[_0x52e20a('0x5a')],this[_0x52e20a('0xcc')]=0x0,ami['on'](_0x52e20a('0x105'),this['syncOriginateResponse'][_0x52e20a('0xcd')](this)),ami['on'](_0x52e20a('0xe6'),this[_0x52e20a('0x58')][_0x52e20a('0xcd')](this)),ami['on'](_0x52e20a('0x12d'),this[_0x52e20a('0x13d')][_0x52e20a('0xcd')](this)),ami['on'](_0x52e20a('0x49'),this[_0x52e20a('0x47')][_0x52e20a('0xcd')](this)),ami['on'](_0x52e20a('0xb4'),this['syncNewExten'][_0x52e20a('0xcd')](this)),ami['on'](_0x52e20a('0x74'),this[_0x52e20a('0x114')][_0x52e20a('0xcd')](this)),ami['on'](_0x52e20a('0xa2'),this[_0x52e20a('0x92')]['bind'](this)),ami['on'](_0x52e20a('0x82'),this[_0x52e20a('0x6b')][_0x52e20a('0xcd')](this)),this['loopCampaigns'](this['campaignsPreview']);}function emit(_0x185b66,_0x4d86d4,_0x113ab1){io['to'](_0x185b66)['emit'](_0x4d86d4,_0x113ab1);}function emitCampaignPreview(_0x565149){const _0x56f5d2=_0x1bdf48;if(_0x565149[_0x56f5d2('0xe3')]==='outbound'){const _0xfb940a={'id':_0x565149['id'],'name':_0x565149['name'],'strategy':_0x565149['strategy'],'answered':_0x565149[_0x56f5d2('0x10c')],'available':_0x565149[_0x56f5d2('0xbe')],'loggedIn':_0x565149[_0x56f5d2('0x75')],'pTalking':_0x565149[_0x56f5d2('0xe5')],'sumBillable':_0x565149['sumBillable'],'sumDuration':_0x565149[_0x56f5d2('0xc2')],'sumHoldTime':_0x565149[_0x56f5d2('0x65')]||0x0,'talking':_0x565149['talking'],'total':_0x565149[_0x56f5d2('0x46')],'type':_0x565149[_0x56f5d2('0xe3')],'unmanaged':_0x565149[_0x56f5d2('0x142')],'abandoned':_0x565149[_0x56f5d2('0xfc')],'waiting':_0x565149[_0x56f5d2('0x121')],'loggedInDb':_0x565149[_0x56f5d2('0x0')],'dialActive':_0x565149[_0x56f5d2('0x143')],'dialMethod':_0x565149[_0x56f5d2('0x64')],'dialOriginateCallerIdName':_0x565149[_0x56f5d2('0x20')],'dialOriginateCallerIdNumber':_0x565149[_0x56f5d2('0x3f')],'dialOriginateTimeout':_0x565149[_0x56f5d2('0x76')],'dialPrefix':_0x565149[_0x56f5d2('0x1d')],'outboundAnswerAgiCallsDay':_0x565149[_0x56f5d2('0xba')],'outboundAnswerCallsDay':_0x565149[_0x56f5d2('0x6c')],'outboundBlacklistCallsDay':_0x565149[_0x56f5d2('0x5c')],'outboundBusyCallsDay':_0x565149[_0x56f5d2('0x110')],'outboundCongestionCallsDay':_0x565149[_0x56f5d2('0x124')],'outboundDropCallsDayACS':_0x565149['outboundDropCallsDayACS'],'outboundDropCallsDayCallersExit':_0x565149['outboundDropCallsDayCallersExit'],'outboundDropCallsDayTimeout':_0x565149[_0x56f5d2('0x12f')],'outboundNoAnswerCallsDay':_0x565149[_0x56f5d2('0x85')],'outboundNoSuchCallsDay':_0x565149[_0x56f5d2('0x117')],'outboundOriginateFailureCallsDay':_0x565149[_0x56f5d2('0xa4')],'outboundReCallsDay':_0x565149[_0x56f5d2('0x26')],'outboundRejectCallsDay':_0x565149[_0x56f5d2('0x88')],'outboundUnknownCallsDay':_0x565149[_0x56f5d2('0x56')],'outboundAbandonedCallsDay':_0x565149[_0x56f5d2('0x44')],'predictiveIntervalAnsweredCalls':_0x565149[_0x56f5d2('0x129')],'predictiveIntervalAvgHoldtime':_0x565149['predictiveIntervalAvgHoldtime'],'predictiveIntervalAvgTalktime':_0x565149[_0x56f5d2('0xa6')],'predictiveIntervalDroppedCallsCallersExit':_0x565149[_0x56f5d2('0xc')],'predictiveIntervalDroppedCallsTimeout':_0x565149[_0x56f5d2('0xd8')],'predictiveIntervalErlangCalls':_0x565149[_0x56f5d2('0x5e')],'predictiveIntervalErlangCallsDroppedCalls':_0x565149[_0x56f5d2('0xd0')],'predictiveIntervalHitRate':_0x565149[_0x56f5d2('0x149')],'predictiveIntervalMultiplicativeFactor':_0x565149[_0x56f5d2('0x7')],'predictiveIntervalPauses':_0x565149[_0x56f5d2('0x73')],'predictiveIntervalAvailable':_0x565149[_0x56f5d2('0xac')],'predictiveIntervalTotalCalls':_0x565149[_0x56f5d2('0x52')],'message':_0x565149[_0x56f5d2('0x139')],'originated':_0x565149['originated'],'erlangCalls':_0x565149['erlangCalls'],'erlangCallToSecond':_0x565149[_0x56f5d2('0xf9')],'erlangAbandonmentRate':_0x565149[_0x56f5d2('0xae')],'erlangBusyFactor':_0x565149['erlangBusyFactor'],'startPredictive':_0x565149[_0x56f5d2('0x77')],'startProgressive':_0x565149[_0x56f5d2('0xc7')]};_0x565149[_0x56f5d2('0x3a')]&&(_0xfb940a[_0x56f5d2('0x3a')]={'id':_0x565149['Trunk']['id'],'name':_0x565149['Trunk'][_0x56f5d2('0x97')],'active':_0x565149[_0x56f5d2('0x3a')][_0x56f5d2('0x111')],'callerid':_0x565149['Trunk']['callerid']});_0x565149['Interval']&&(_0xfb940a[_0x56f5d2('0x6f')]={'id':_0x565149[_0x56f5d2('0x6f')]['id'],'name':_0x565149[_0x56f5d2('0x6f')][_0x56f5d2('0x97')]});const _0x5c265d=md5(JSON[_0x56f5d2('0x9e')](_0xfb940a));_0x565149['md5']!==_0x5c265d&&(_0x565149[_0x56f5d2('0x79')]=_0x5c265d,emit(util[_0x56f5d2('0x133')](_0x56f5d2('0x11e'),_0xfb940a[_0x56f5d2('0x97')]),_0x56f5d2('0xee'),_0xfb940a));}}function emitVoiceQueueChannelRemove(_0x413f9a){const _0xbb9dc5=_0x1bdf48;logger[_0xbb9dc5('0x1')]('[DEBUG]\x20Emit\x20voice_queue_channel:remove\x20event',JSON[_0xbb9dc5('0x9e')](_0x413f9a)),emit(util['format'](_0xbb9dc5('0x11e'),_0x413f9a[_0xbb9dc5('0x97')]),_0xbb9dc5('0xe'),_0x413f9a);}function notSendMessagesQueue(_0x214ae6){const _0x503010=_0x1bdf48;_0x214ae6['sendMessageOneNotActive']&&(_0x214ae6[_0x503010('0x72')]===0x0&&_0x214ae6[_0x503010('0xe5')]===0x0?(_0x214ae6[_0x503010('0x99')]=![],_0x214ae6[_0x503010('0xbe')]=0x0,_0x214ae6['paused']=0x0,_0x214ae6[_0x503010('0x139')]=_0x503010('0x30'),ut[_0x503010('0x14a')](_0x503010('0xc6'),_0x214ae6['name']+_0x503010('0x1a'))):(_0x214ae6[_0x503010('0x139')]=_0x503010('0xde'),ut[_0x503010('0x14a')]('[CampaignPreview]\x20Campaign\x20Queue:\x20',_0x214ae6[_0x503010('0x97')]+_0x503010('0xb2'))),emitCampaignPreview(_0x214ae6));}Preview[_0x1bdf48('0x113')][_0x1bdf48('0x4b')]=function(){const _0x314b09=this;setInterval(function(){_0x314b09['syncCampaigns']();},0x7cf);},Preview[_0x1bdf48('0x113')][_0x1bdf48('0xbb')]=function(){const _0x4a4441=_0x1bdf48,_0x14ba2f=this[_0x4a4441('0xf7')];this[_0x4a4441('0xcc')]+=0x1;for(const _0x10b7bc in _0x14ba2f){typeof _0x14ba2f[_0x10b7bc]!==_0x4a4441('0x112')&&(_0x14ba2f[_0x10b7bc][_0x4a4441('0x64')]===_0x4a4441('0x13e')||_0x14ba2f[_0x10b7bc][_0x4a4441('0x64')]===_0x4a4441('0x6d'))&&_0x14ba2f[_0x10b7bc][_0x4a4441('0xe3')]===_0x4a4441('0x7e')&&(this[_0x4a4441('0xcc')]>0x7&&(this['clockClearZombieChannels']=0x0,this[_0x4a4441('0x15')]())),typeof _0x14ba2f[_0x10b7bc]!==_0x4a4441('0x112')&&_0x14ba2f[_0x10b7bc]['dialMethod']===_0x4a4441('0x13e')&&_0x14ba2f[_0x10b7bc][_0x4a4441('0xe3')]===_0x4a4441('0x7e')&&(_0x14ba2f[_0x10b7bc][_0x4a4441('0x143')]?(this[_0x4a4441('0x91')](_0x14ba2f[_0x10b7bc]),this[_0x4a4441('0x86')](_0x14ba2f[_0x10b7bc])):notSendMessagesQueue(_0x14ba2f[_0x10b7bc]));}},Preview['prototype']['clearZombieChannel']=function(_0x4d0fdc){const _0x312da2=_0x1bdf48,_0x2cdbac=this;this['sequence'][_0x312da2('0x119')](function(){const _0x54636b=_0x312da2;if(!_[_0x54636b('0x2c')](_0x2cdbac[_0x54636b('0xa9')][_0x4d0fdc]))return loggerAction[_0x54636b('0x1')](_0x54636b('0xce'),_0x4d0fdc,'Queue',_0x2cdbac['actions'][_0x4d0fdc]['queue'],_0x54636b('0x19'),JSON[_0x54636b('0x9e')](_0x2cdbac[_0x54636b('0xf7')][_0x2cdbac[_0x54636b('0xa9')][_0x4d0fdc][_0x54636b('0x39')]][_0x54636b('0x72')]),_0x54636b('0x11'),JSON['stringify'](_0x2cdbac[_0x54636b('0xf7')][_0x2cdbac[_0x54636b('0xa9')][_0x4d0fdc][_0x54636b('0x39')]][_0x54636b('0xe5')]),JSON[_0x54636b('0x9e')](_0x2cdbac[_0x54636b('0xa9')][_0x4d0fdc][_0x54636b('0x33')]),JSON[_0x54636b('0x9e')](_[_0x54636b('0x102')](_0x2cdbac['actions'][_0x4d0fdc],[_0x54636b('0x4d'),_0x54636b('0x93'),_0x54636b('0x27'),'ListId']))),ami[_0x54636b('0x137')]({'action':'status','channel':_0x2cdbac['actions'][_0x4d0fdc][_0x54636b('0x13')]})[_0x54636b('0xd9')](function(_0x447f7b){const _0x3c4b2e=_0x54636b;_0x447f7b[_0x3c4b2e('0x139')]===_0x3c4b2e('0x66')&&setTimeout(function(){const _0x3efd9a=_0x3c4b2e;_0x2cdbac[_0x3efd9a('0xa9')][_0x4d0fdc]&&(ut[_0x3efd9a('0xfa')](_0x2cdbac[_0x3efd9a('0xf7')][_0x2cdbac['actions'][_0x4d0fdc]['queue']],_0x3efd9a('0x2f')),_0x2cdbac[_0x3efd9a('0xa9')][_0x4d0fdc][_0x3efd9a('0x33')]===!![]&&(ut[_0x3efd9a('0xc4')](_0x2cdbac[_0x3efd9a('0xf7')][_0x2cdbac[_0x3efd9a('0xa9')][_0x4d0fdc][_0x3efd9a('0x39')]],_0x3efd9a('0x2f')),ut[_0x3efd9a('0x6a')](_0x3efd9a('0xb9')+_0x4d0fdc,_0x2cdbac[_0x3efd9a('0xa9')][_0x4d0fdc][_0x3efd9a('0x39')])),ut[_0x3efd9a('0x6a')](_0x3efd9a('0xb0')+_0x4d0fdc,_0x2cdbac[_0x3efd9a('0xa9')][_0x4d0fdc][_0x3efd9a('0x39')]),delete _0x2cdbac[_0x3efd9a('0xa9')][_0x4d0fdc]);},0x2328);});});},Preview['prototype']['clearZombieChannels']=function(){const _0x18e3ea=_0x1bdf48,_0x125494=this;loggerAction[_0x18e3ea('0x1')](_0x18e3ea('0x9c'),_[_0x18e3ea('0x5f')](this[_0x18e3ea('0xa9')]));for(const _0x2e8395 in this[_0x18e3ea('0xa9')]){typeof _0x125494[_0x18e3ea('0xa9')][_0x2e8395]!==_0x18e3ea('0x112')&&_0x125494['clearZombieChannel'](_0x2e8395);}},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x86')]=function(_0x381ad2){const _0xcbc440=_0x1bdf48,_0x483e85=this;rpcDb[_0xcbc440('0xaf')](_0x381ad2['id'],ut[_0xcbc440('0x12')](this['agents']))[_0xcbc440('0x8a')](function(_0x308b62){const _0x52cb99=_0xcbc440;if(!_[_0x52cb99('0x2c')](_0x308b62))for(let _0x2b34a6=0x0;_0x2b34a6<_0x308b62[_0x52cb99('0x128')];_0x2b34a6+=0x1){if(ut[_0x52cb99('0xfe')](_0x308b62[_0x2b34a6]['scheduledat'])<_0x381ad2['dialRecallMeTimeout']*0x3c)_0x308b62[_0x2b34a6][_0x52cb99('0x115')]&&!_0x308b62[_0x2b34a6][_0x52cb99('0x115')][_0x52cb99('0x7a')]?_0x483e85['run'](_0x308b62[_0x2b34a6]['id'])[_0x52cb99('0x8a')](ut[_0x52cb99('0x4f')](_0x52cb99('0x127')))['catch'](ut[_0x52cb99('0x4f')](_0x52cb99('0x127'))):rpcDb['disableContact'](_0x308b62[_0x2b34a6]['id']);else{const _0x379548=new Action(_0x308b62[_0x2b34a6],_0x381ad2);_0x379548[_0x52cb99('0xbc')]=moment()['format'](_0x52cb99('0xb8')),_0x381ad2[_0x52cb99('0x26')]+=0x1,ut[_0x52cb99('0x3c')](_0x379548,0x17,'RecallInQueue'),_0x381ad2[_0x52cb99('0x18')]?(rpcDb['rescheduleContactInQueue'](ut['createBody'](_0x308b62[_0x2b34a6])),rpcDb[_0x52cb99('0x38')](_0x379548,_0x52cb99('0x2a'))):(ut['logCustomer'](_0x379548,0x16,_0x52cb99('0x3e')),rpcDb[_0x52cb99('0x38')](_0x379548,_0x52cb99('0x145')),rpcDb[_0x52cb99('0xf5')](_0x379548,'[HistoryRecallClose]'));}}})[_0xcbc440('0xd9')](ut[_0xcbc440('0x4f')](_0xcbc440('0xf8')));},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x91')]=function(_0x4dcfe0){const _0x40b8d0=_0x1bdf48;_0x4dcfe0[_0x40b8d0('0x99')]=!![];if(ut[_0x40b8d0('0x10b')](_0x4dcfe0[_0x40b8d0('0x75')]))_0x4dcfe0['message']='AGENTS_NOT_LOGGED';else{if(!ut[_0x40b8d0('0xe9')](_0x4dcfe0['dialActive']))_0x4dcfe0['message']=_0x40b8d0('0x30');else!this[_0x40b8d0('0x43')](_0x4dcfe0[_0x40b8d0('0x3a')])?!this['isTrunkReachable'](_0x4dcfe0[_0x40b8d0('0xd2')])?_0x4dcfe0[_0x40b8d0('0x139')]=_0x40b8d0('0x148'):_0x4dcfe0[_0x40b8d0('0x139')]=_0x40b8d0('0xec'):_0x4dcfe0['message']=_0x40b8d0('0xec');}emitCampaignPreview(_0x4dcfe0);},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x11d')]=function(_0x75c78d,_0x5b7c1e,_0x13fe79){const _0x3cc438=_0x1bdf48,_0x119f0a=this[_0x3cc438('0xa9')][_0x5b7c1e],_0x39612c=this[_0x3cc438('0xf7')][_0x119f0a[_0x3cc438('0x39')]];let _0x14ad5a;if(_0x39612c){switch(_0x13fe79){case'1':_0x39612c[_0x3cc438('0x117')]+=0x1,_0x119f0a[_0x3cc438('0xdf')]+=0x1,_0x119f0a[_0x3cc438('0x11b')]=ut[_0x3cc438('0xe2')](_0x119f0a),ut[_0x3cc438('0x3c')](_0x119f0a,0x0,_0x3cc438('0xc5')),ami[_0x3cc438('0x13a')](_0x3cc438('0xaa'),ut['buildObj'](_0x119f0a,'nosuchnumber')),rpcDb[_0x3cc438('0x38')](_0x119f0a,'[callProgressDetectingCustomer][logNoSuch]');ut[_0x3cc438('0xe2')](_0x119f0a)>=_0x39612c[_0x3cc438('0xda')]?(_0x14ad5a=ut[_0x3cc438('0xb')](_0x119f0a,0xf,_0x3cc438('0xe0')),rpcDb['createCustomerFinal'](_0x14ad5a,_0x3cc438('0xd6'))):_0x119f0a[_0x3cc438('0xdf')]>=_0x39612c[_0x3cc438('0xc3')]?rpcDb[_0x3cc438('0xf5')](_0x119f0a,_0x3cc438('0xd6')):rpcDb[_0x3cc438('0x80')](ut[_0x3cc438('0xa1')](_0x119f0a,'countnosuchnumberretry',_0x39612c[_0x3cc438('0x9b')]),_0x119f0a['unlockAgent'],_0x119f0a[_0x3cc438('0x2d')]);delete this[_0x3cc438('0xa9')][_0x75c78d[_0x3cc438('0xbf')]];break;case'ANSWER':{const _0x1163de=moment()['format'](_0x3cc438('0xb8'));_0x119f0a[_0x3cc438('0x107')]=_0x1163de,_0x119f0a['answertime']=_0x1163de,_0x119f0a[_0x3cc438('0x33')]=!![],_0x39612c['pTalking']+=0x1,logger[_0x3cc438('0x1')](_0x3cc438('0x40'),_0x119f0a[_0x3cc438('0xa0')],_0x3cc438('0x55'),_0x39612c[_0x3cc438('0x97')],_0x3cc438('0x11'),_0x39612c[_0x3cc438('0xe5')]),ami[_0x3cc438('0x13a')](_0x3cc438('0x6e'),ut[_0x3cc438('0xdd')](_0x119f0a,_0x3cc438('0x123'))),_0x39612c[_0x3cc438('0x135')]&&ami[_0x3cc438('0x13a')](_0x3cc438('0x41'),ut[_0x3cc438('0x36')](_0x119f0a));}break;case'16':ami['emit']('custom:agentcomplete',ut[_0x3cc438('0xdd')](_0x119f0a,'complete')),emitVoiceQueueChannelRemove(ut[_0x3cc438('0xdd')](_0x119f0a,_0x3cc438('0x1b'))),_0x39612c[_0x3cc438('0x6c')]+=0x1,_0x39612c['total']+=0x1,_0x39612c['answered']+=0x1,ut['decrementTalkink'](_0x39612c,_0x3cc438('0x138')),_0x119f0a[_0x3cc438('0x11b')]=ut['totalGlobal'](_0x119f0a),ut['logCustomer'](_0x119f0a,0x4,_0x3cc438('0xf3')),rpcDb['createCustomerHistory'](_0x119f0a,_0x3cc438('0xca')),rpcDb[_0x3cc438('0xf5')](_0x119f0a,_0x3cc438('0x69')),rpcDb['crateCustomerReportQueue'](_0x119f0a),_0x39612c[_0x3cc438('0xc2')]+=_0x119f0a[_0x3cc438('0x70')],_0x39612c[_0x3cc438('0xc1')]+=_0x119f0a[_0x3cc438('0x70')],logger['info']('[syncHangup][talking][decrement]',_0x119f0a['uniqueid'],'\x20Queue',_0x39612c[_0x3cc438('0x97')],_0x3cc438('0x11'),_0x39612c[_0x3cc438('0xe5')]),delete this['actions'][_0x75c78d[_0x3cc438('0xbf')]];break;case'BUSY':_0x39612c[_0x3cc438('0x110')]+=0x1,_0x119f0a[_0x3cc438('0x103')]+=0x1,_0x119f0a[_0x3cc438('0x11b')]=ut[_0x3cc438('0xe2')](_0x119f0a),ut[_0x3cc438('0x3c')](_0x119f0a,0x5,_0x3cc438('0x134')),ami['emit'](_0x3cc438('0xa8'),ut[_0x3cc438('0xdd')](_0x119f0a,_0x3cc438('0xdc'))),rpcDb[_0x3cc438('0x38')](_0x119f0a,_0x3cc438('0x61'));ut[_0x3cc438('0xe2')](_0x119f0a)>=_0x39612c[_0x3cc438('0xda')]?(_0x14ad5a=ut['cloneAction'](_0x119f0a,0xf,_0x3cc438('0xe0')),rpcDb[_0x3cc438('0xf5')](_0x14ad5a,'[callProgressDetectingCustomer][logBusyGlobal]')):_0x119f0a[_0x3cc438('0x103')]>=_0x39612c[_0x3cc438('0x90')]?rpcDb[_0x3cc438('0xf5')](_0x119f0a,_0x3cc438('0x61')):rpcDb['rescheduleContact'](ut['scheduledAt'](_0x119f0a,_0x3cc438('0x103'),_0x39612c['dialBusyRetryFrequency']),_0x119f0a[_0x3cc438('0x10')],_0x119f0a[_0x3cc438('0x2d')]);break;case'NOANSWER':_0x39612c['outboundNoAnswerCallsDay']+=0x1,_0x119f0a['countnoanswerretry']+=0x1,_0x119f0a['countglobal']=ut[_0x3cc438('0xe2')](_0x119f0a),ut['logCustomer'](_0x119f0a,0x3,_0x3cc438('0x11c')),ami[_0x3cc438('0x13a')](_0x3cc438('0x9a'),ut[_0x3cc438('0xdd')](_0x119f0a,_0x3cc438('0x3d'))),rpcDb[_0x3cc438('0x38')](_0x119f0a,_0x3cc438('0xd1'));ut['totalGlobal'](_0x119f0a)>=_0x39612c[_0x3cc438('0xda')]?(_0x14ad5a=ut['cloneAction'](_0x119f0a,0xf,_0x3cc438('0xe0')),rpcDb[_0x3cc438('0xf5')](_0x14ad5a,'[callProgressDetectingCustomer][logNoAnswerGlobal]')):_0x119f0a[_0x3cc438('0x2e')]>=_0x39612c[_0x3cc438('0xad')]?rpcDb[_0x3cc438('0xf5')](_0x119f0a,_0x3cc438('0xd1')):rpcDb[_0x3cc438('0x80')](ut['scheduledAt'](_0x119f0a,_0x3cc438('0x2e'),_0x39612c[_0x3cc438('0x48')]),_0x119f0a['unlockAgent'],_0x119f0a[_0x3cc438('0x2d')]);break;case _0x3cc438('0xf6'):_0x39612c[_0x3cc438('0x124')]+=0x1,_0x119f0a['countcongestionretry']+=0x1,_0x119f0a[_0x3cc438('0x11b')]=ut[_0x3cc438('0xe2')](_0x119f0a),ut[_0x3cc438('0x3c')](_0x119f0a,0x8,'Congestion'),ami[_0x3cc438('0x13a')](_0x3cc438('0xf1'),ut[_0x3cc438('0xdd')](_0x119f0a,'congestion')),rpcDb[_0x3cc438('0x38')](_0x119f0a,_0x3cc438('0x25'));ut[_0x3cc438('0xe2')](_0x119f0a)>=_0x39612c[_0x3cc438('0xda')]?(_0x14ad5a=ut['cloneAction'](_0x119f0a,0xf,_0x3cc438('0xe0')),rpcDb[_0x3cc438('0xf5')](_0x14ad5a,_0x3cc438('0x59'))):_0x119f0a[_0x3cc438('0x8e')]>=_0x39612c[_0x3cc438('0x132')]?rpcDb[_0x3cc438('0xf5')](_0x119f0a,'[callProgressDetectingCustomer][logCongestion]'):rpcDb['rescheduleContact'](ut['scheduledAt'](_0x119f0a,'countcongestionretry',_0x39612c[_0x3cc438('0x1e')]),_0x119f0a[_0x3cc438('0x10')],_0x119f0a[_0x3cc438('0x2d')]);break;case _0x3cc438('0x9'):_0x39612c[_0x3cc438('0x88')]+=0x1,_0x119f0a[_0x3cc438('0x8f')]+=0x1,_0x119f0a[_0x3cc438('0x11b')]=ut['totalGlobal'](_0x119f0a),ut[_0x3cc438('0x3c')](_0x119f0a,0x14,'AgentReject'),ami[_0x3cc438('0x13a')](_0x3cc438('0x118'),ut[_0x3cc438('0xdd')](_0x119f0a,_0x3cc438('0xf2'))),rpcDb[_0x3cc438('0x38')](_0x119f0a,_0x3cc438('0x100'));ut['totalGlobal'](_0x119f0a)>=_0x39612c[_0x3cc438('0xda')]?(_0x14ad5a=ut[_0x3cc438('0xb')](_0x119f0a,0x14,_0x3cc438('0x35')),rpcDb[_0x3cc438('0xf5')](_0x14ad5a,_0x3cc438('0x147'))):_0x119f0a[_0x3cc438('0x8f')]>=_0x39612c['dialAgentRejectMaxRetry']?rpcDb[_0x3cc438('0xf5')](_0x119f0a,'[callProgressDetectingCustomer][logAgentReject]'):rpcDb[_0x3cc438('0x80')](ut[_0x3cc438('0xa1')](_0x119f0a,_0x3cc438('0x8f'),_0x39612c[_0x3cc438('0xa3')]),_0x119f0a[_0x3cc438('0x10')],_0x119f0a['activeContact']);break;case _0x3cc438('0x14b'):_0x39612c[_0x3cc438('0x44')]+=0x1,_0x119f0a[_0x3cc438('0x140')]+=0x1,_0x119f0a[_0x3cc438('0x11b')]=ut['totalGlobal'](_0x119f0a),ut['logCustomer'](_0x119f0a,0xb,'Abandoned'),rpcDb[_0x3cc438('0x38')](_0x119f0a,'[callProgressDetectingCustomer][logAbandoned]');ut[_0x3cc438('0xe2')](_0x119f0a)>=_0x39612c['dialGlobalMaxRetry']?(_0x14ad5a=ut[_0x3cc438('0xb')](_0x119f0a,0xf,'Global'),rpcDb[_0x3cc438('0xf5')](_0x14ad5a,_0x3cc438('0x98'))):_0x119f0a[_0x3cc438('0xc9')]>=_0x39612c[_0x3cc438('0x109')]?rpcDb[_0x3cc438('0xf5')](_0x119f0a,_0x3cc438('0x98')):rpcDb[_0x3cc438('0x80')](ut['scheduledAt'](_0x119f0a,_0x3cc438('0x140'),_0x39612c[_0x3cc438('0x136')]),_0x119f0a[_0x3cc438('0x10')],_0x119f0a[_0x3cc438('0x2d')]);break;default:_0x119f0a['dialAnswer']&&(ut[_0x3cc438('0xc4')](_0x39612c,_0x3cc438('0x67')),ut[_0x3cc438('0x6a')](_0x3cc438('0x57')+_0x39612c[_0x3cc438('0x97')],_0x75c78d));_0x39612c[_0x3cc438('0x56')]+=0x1,_0x119f0a[_0x3cc438('0x11b')]=ut['totalGlobal'](_0x119f0a),ut[_0x3cc438('0x3c')](_0x119f0a,0xc,_0x75c78d[_0x3cc438('0xa5')]||_0x75c78d[_0x3cc438('0x10d')]),rpcDb[_0x3cc438('0x38')](_0x119f0a,_0x3cc438('0x31'));ut[_0x3cc438('0xe2')](_0x119f0a)>=_0x39612c[_0x3cc438('0xda')]?(_0x14ad5a=ut[_0x3cc438('0xb')](_0x119f0a,0xf,_0x3cc438('0xe0')),rpcDb[_0x3cc438('0xf5')](_0x14ad5a,_0x3cc438('0x94'))):rpcDb['createCustomerFinal'](_0x119f0a,'[callProgressDetectingCustomer][logUnknownGlobal]');delete this[_0x3cc438('0xa9')][_0x75c78d[_0x3cc438('0xbf')]];}!(_0x119f0a[_0x3cc438('0x33')]&&_0x13fe79==='16')&&(ut[_0x3cc438('0xfa')](_0x39612c,_0x3cc438('0x7b')),logger[_0x3cc438('0x1')](_0x3cc438('0x4'),_0x119f0a[_0x3cc438('0xa0')],_0x3cc438('0x55'),_0x39612c[_0x3cc438('0x97')],_0x3cc438('0x19'),_0x39612c[_0x3cc438('0x72')])),_0x13fe79!==_0x3cc438('0x144')&&(delete this[_0x3cc438('0xa9')][_0x75c78d['linkedid']],delete this[_0x3cc438('0xa9')][_0x75c78d['destlinkedid']]);}},Preview['prototype'][_0x1bdf48('0x95')]=function(_0x127a1d,_0x9f9b15,_0x52195d){const _0x4dee15=_0x1bdf48;if(_[_0x4dee15('0xb1')](_0x9f9b15)&&'object'!==typeof _0x9f9b15)return;if(_[_0x4dee15('0xb1')](_0x52195d)&&_0x4dee15('0xb5')!==typeof _0x52195d)return;switch(_0x52195d['reason']){case'0':ut[_0x4dee15('0x11a')](_0x127a1d,0x0,_0x4dee15('0xc5')),rpcDb[_0x4dee15('0x62')](_0x127a1d,_0x4dee15('0x106'));break;case'3':ut[_0x4dee15('0x11a')](_0x127a1d,0x3,'NoAnswer'),rpcDb[_0x4dee15('0x62')](_0x127a1d,_0x4dee15('0x130'));break;case'5':ut[_0x4dee15('0x11a')](_0x127a1d,0x5,_0x4dee15('0x134')),rpcDb[_0x4dee15('0x62')](_0x127a1d,_0x4dee15('0x37'));break;case'8':ut['logAgent'](_0x127a1d,0x8,_0x4dee15('0xfd')),rpcDb[_0x4dee15('0x62')](_0x127a1d,'[callProgressDetectingAgent][logCongestion]');break;case'22':ut[_0x4dee15('0x11a')](_0x127a1d,0x16,_0x4dee15('0xab')),rpcDb[_0x4dee15('0x62')](_0x127a1d,_0x4dee15('0xef'));break;default:ut[_0x4dee15('0x11a')](_0x127a1d,0xc,_0x52195d[_0x4dee15('0x17')]),rpcDb[_0x4dee15('0x62')](_0x127a1d,_0x4dee15('0x10a'));}ut['updateOriginated'](_0x9f9b15,_0x4dee15('0x101')),logger[_0x4dee15('0x1')](_0x4dee15('0x22'),_0x127a1d[_0x4dee15('0xa0')],_0x4dee15('0x55'),_0x9f9b15['name'],_0x4dee15('0x19'),_0x9f9b15[_0x4dee15('0x72')]),delete this['actions'][_0x127a1d[_0x4dee15('0xa0')]];},Preview['prototype']['checkInBlack']=function(_0x2ea371,_0x5a866f,_0x1c0b89,_0x30369b,_0x42d0c6){const _0x48a239=this;return new Promise(function(_0x31f1fe,_0x56ec8e){const _0x2f3443=a1088_0x1ab1;if(_['isNil'](_0x5a866f)||_['isNil'](_0x5a866f[_0x2f3443('0x104')])||_[_0x2f3443('0x2c')](_0x5a866f[_0x2f3443('0x104')][_0x2f3443('0xf4')])||_[_0x2f3443('0x2c')](_0x5a866f[_0x2f3443('0x27')])){_0x56ec8e(ut[_0x2f3443('0x139')](_0x2f3443('0xc8'),_0x30369b,_0x42d0c6));return;}const _0x135c45=uuid['v4'](),_0x31099f=_0x48a239[_0x2f3443('0xf7')][_0x5a866f[_0x2f3443('0x120')][_0x2f3443('0x97')]],_0xb0615a=_0x1c0b89?_0x48a239['agents'][_0x1c0b89]['id']:undefined;_0x48a239[_0x2f3443('0xa9')][_0x135c45]=new Action(_0x5a866f,_0x31099f,_0x135c45,_0x1c0b89,_0xb0615a);const _0x262d9d=_0x48a239['actions'][_0x135c45];_0x262d9d['unlockAgent']=_0x30369b,_0x262d9d['activeContact']=_0x42d0c6,_0x262d9d[_0x2f3443('0x10e')]=_0x1c0b89,_[_0x2f3443('0x8b')](_0x2ea371)?_0x48a239['execCall'](_0x262d9d,_0x31099f,_0x5a866f,_0x1c0b89)['then'](function(_0x2f7f2c){const _0x3a90f9=_0x2f3443;logger['info'](_0x3a90f9('0x16'),_0x3a90f9('0x63')+_0x262d9d[_0x3a90f9('0x39')]+'\x20IdHopper:\x20'+_0x262d9d['idContact'],JSON[_0x3a90f9('0x9e')](_0x2f7f2c)),ami[_0x3a90f9('0x13a')](_0x3a90f9('0x11f'),ut[_0x3a90f9('0xdd')](_0x262d9d,_0x3a90f9('0x14'))),_0x31f1fe(ut[_0x3a90f9('0x139')]('Calling'));})[_0x2f3443('0xd9')](function(_0x3404fe){const _0x4f413e=_0x2f3443;ut[_0x4f413e('0x14a')](_0x4f413e('0x45'),_0x3404fe),_0x56ec8e(ut[_0x4f413e('0x139')](_0x4f413e('0xd'),_0x30369b,_0x42d0c6));}):(_0x31099f[_0x2f3443('0x5c')]+=0x1,ut[_0x2f3443('0x5')](_0x262d9d),rpcDb[_0x2f3443('0x108')](_0x262d9d,'[Blacklist][error]'),delete _0x48a239[_0x2f3443('0xa9')][_0x135c45],_0x56ec8e(ut[_0x2f3443('0x139')](_0x2f3443('0xd3'),_0x30369b,_0x42d0c6)));});},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x43')]=function(_0x561a9d){const _0x80bd67=_0x1bdf48;return!_[_0x80bd67('0x2c')](_0x561a9d)&&!_['isNil'](_0x561a9d[_0x80bd67('0x97')])&&!_[_0x80bd67('0x2c')](_0x561a9d['active'])&&_0x561a9d[_0x80bd67('0x111')]&&!_[_0x80bd67('0x2c')](this[_0x80bd67('0xd5')][util[_0x80bd67('0x133')](_0x80bd67('0xa7'),_0x561a9d['name'])])&&!_[_0x80bd67('0x2c')](this[_0x80bd67('0xd5')][util['format'](_0x80bd67('0xa7'),_0x561a9d[_0x80bd67('0x97')])][_0x80bd67('0x7d')])&&(this['trunks'][util['format'](_0x80bd67('0xa7'),_0x561a9d['name'])][_0x80bd67('0x7d')]==='reachable'||this[_0x80bd67('0xd5')][util[_0x80bd67('0x133')](_0x80bd67('0xa7'),_0x561a9d['name'])][_0x80bd67('0x7d')]===_0x80bd67('0x14c'));},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x53')]=function(_0x1aa596,_0x5893e5){const _0x49a0da=this;return new Promise(function(_0x18d276,_0x5c137b){const _0x269771=a1088_0x1ab1;_0x49a0da[_0x269771('0x122')](_0x1aa596,_0x5893e5)['then'](function(_0x47f71c){const _0x30d691=_0x269771;_0x18d276(_[_0x30d691('0x102')](_0x47f71c,[_0x30d691('0x139')]));})[_0x269771('0xd9')](function(_0x9f8bac){const _0xcbc941=_0x269771;_0x9f8bac['unlock']&&rpcDb[_0xcbc941('0x60')](_0x1aa596),_0x9f8bac['active']&&rpcDb[_0xcbc941('0x2b')](_0x1aa596),_0x5c137b(_['pick'](_0x9f8bac,[_0xcbc941('0x139')]));});});},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x122')]=function(_0x26d49a,_0x1dd613){const _0x531219=this;return new Promise(function(_0x4535a6,_0xe380fb){const _0x31ebb0=a1088_0x1ab1;let _0x51622f,_0x100fd2;rpcDb[_0x31ebb0('0x126')](_0x26d49a)[_0x31ebb0('0x8a')](function(_0x709620){const _0x276841=_0x31ebb0;!_[_0x276841('0x2c')](_0x709620[0x0])&&(_0x100fd2=_0x709620[0x0][_0x276841('0x34')]?![]:!![],_0x51622f=_0x709620[0x0]['recallme']?!![]:![],_0x51622f=_0x1dd613?!![]:_0x51622f);const _0x238dce=_0x531219[_0x276841('0x32')](_0x709620);_0x238dce[_0x276841('0xf')]?rpcDb[_0x276841('0x21')](_[_0x276841('0x102')](_0x709620[0x0],[_0x276841('0x27'),_0x276841('0x6')]))[_0x276841('0x8a')](function(_0x8f2277){const _0x5ab27f=_0x276841;_0x531219[_0x5ab27f('0x7c')](_0x8f2277,_0x709620[0x0],_0x1dd613,_0x100fd2,_0x51622f)[_0x5ab27f('0x8a')](function(_0x4cc096){_0x4535a6(_0x4cc096);})[_0x5ab27f('0xd9')](function(_0x3e1e20){_0xe380fb(_0x3e1e20);});})[_0x276841('0xd9')](function(_0x1311b5){const _0x254607=_0x276841;ut[_0x254607('0x14a')](_0x254607('0xb7'),_0x1311b5),_0xe380fb(ut['message'](_0x254607('0x125'),_0x100fd2,_0x51622f));}):_0xe380fb(ut['message'](_0x238dce['message'],_0x100fd2,_0x51622f));})[_0x31ebb0('0xd9')](function(_0x51536d){const _0x4b0342=_0x31ebb0;ut[_0x4b0342('0x14a')](_0x4b0342('0x24'),_0x51536d),_0xe380fb(ut[_0x4b0342('0x139')]('Call\x20unsuccessful',![],!![]));});});},Preview['prototype'][_0x1bdf48('0x32')]=function(_0x345e61){const _0x3f15cc=_0x1bdf48;if(_[_0x3f15cc('0x2c')](_0x345e61)||_['isEmpty'](_0x345e61)||!_[_0x3f15cc('0x2c')](_0x345e61[0x0][_0x3f15cc('0x115')])&&_[_0x3f15cc('0x2c')](_0x345e61[0x0][_0x3f15cc('0x115')]['name']))return ut['logger'](_0x3f15cc('0x4a'),_0x345e61),{'isValid':![],'message':'Empty\x20Contact'};const _0x16866d=this[_0x3f15cc('0xf7')][_0x345e61[0x0][_0x3f15cc('0x120')]['name']];_0x16866d['message']='ACTIVE';if(_[_0x3f15cc('0x2c')](_0x16866d))return ut['logger'](_0x3f15cc('0x13c'),_0x16866d),{'isValid':![],'message':_0x3f15cc('0x68')};if(!this[_0x3f15cc('0x43')](_0x16866d[_0x3f15cc('0x3a')])){ut[_0x3f15cc('0x14a')]('[Preview][validateContact][Trunk\x20not\x20work]','campaign\x20Name:\x20'+_0x16866d[_0x3f15cc('0x97')]+_0x3f15cc('0xe4'));if(!this['isTrunkReachable'](_0x16866d[_0x3f15cc('0xd2')]))return ut[_0x3f15cc('0x14a')](_0x3f15cc('0x4c'),_0x16866d[_0x3f15cc('0x97')]+_0x3f15cc('0x12b')),{'isValid':![],'message':_0x3f15cc('0x1c')};}if(!ut[_0x3f15cc('0xe9')](_0x16866d['dialActive']))return ut[_0x3f15cc('0x14a')](_0x3f15cc('0xd7'),_0x16866d[_0x3f15cc('0x97')]+_0x3f15cc('0xe1')),{'isValid':![],'message':_0x3f15cc('0x51')+_0x16866d[_0x3f15cc('0x97')]+'\x20Not\x20Active'};return{'isValid':!![],'message':_0x3f15cc('0x131')};},Preview[_0x1bdf48('0x113')]['execCall']=function(_0x4d446d,_0x5a4e77,_0x567d58,_0x3389cf){const _0x3f72d1=this;return new Promise(function(_0x470557,_0x506a7d){const _0x4d7393=a1088_0x1ab1,_0x1c3bec=_0x4d446d[_0x4d7393('0xa0')],_0x506b60=_0x3f72d1[_0x4d7393('0x43')](_0x5a4e77['Trunk'])?util[_0x4d7393('0x133')](_0x4d7393('0x8c'),_0x5a4e77['Trunk'][_0x4d7393('0x97')],_[_0x4d7393('0x2c')](_0x5a4e77[_0x4d7393('0x1d')])?'':_0x5a4e77[_0x4d7393('0x1d')][_0x4d7393('0xeb')]()||'',_0x5a4e77[_0x4d7393('0x87')]>0x0?_0x567d58['Contact'][_0x4d7393('0xf4')][_0x4d7393('0x29')](_0x5a4e77[_0x4d7393('0x87')]):_0x567d58['Contact']['phone']):util[_0x4d7393('0x133')](_0x4d7393('0x8c'),_[_0x4d7393('0x2c')](_0x5a4e77['TrunkBackup'])?_0x5a4e77[_0x4d7393('0x3a')][_0x4d7393('0x97')]:_0x5a4e77[_0x4d7393('0xd2')]['name'],_[_0x4d7393('0x2c')](_0x5a4e77[_0x4d7393('0x1d')])?'':_0x5a4e77[_0x4d7393('0x1d')][_0x4d7393('0xeb')]()||'',_0x5a4e77['dialCutDigit']>0x0?_0x567d58[_0x4d7393('0x104')][_0x4d7393('0xf4')][_0x4d7393('0x29')](_0x5a4e77[_0x4d7393('0x87')]):_0x567d58[_0x4d7393('0x104')][_0x4d7393('0xf4')]),_0xfff943=_0x3f72d1[_0x4d7393('0x43')](_0x5a4e77[_0x4d7393('0x3a')])?ut['getCallerId'](_0x5a4e77['Trunk']['callerid'],_0x5a4e77['dialOriginateCallerIdName'],_0x5a4e77[_0x4d7393('0xfb')]>0x0?ut['getCallerIdRandom'](_0x5a4e77[_0x4d7393('0x3f')],_0x5a4e77[_0x4d7393('0xfb')]):_0x5a4e77[_0x4d7393('0x3f')]):ut[_0x4d7393('0x1f')](_[_0x4d7393('0x2c')](_0x5a4e77['TrunkBackup'])?_0x5a4e77[_0x4d7393('0x3a')][_0x4d7393('0xe8')]:_0x5a4e77[_0x4d7393('0xd2')][_0x4d7393('0xe8')],_0x5a4e77[_0x4d7393('0x20')],_0x5a4e77[_0x4d7393('0xfb')]>0x0?ut[_0x4d7393('0xbd')](_0x5a4e77[_0x4d7393('0x3f')],_0x5a4e77['dialRandomLastDigitCallerIdNumber']):_0x5a4e77[_0x4d7393('0x3f')]);_0xfff943&&(_0x4d446d[_0x4d7393('0x42')]=ut[_0x4d7393('0x4e')](_0xfff943),_0x4d446d[_0x4d7393('0x13f')]=ut['extractCalleridNumber'](_0xfff943));const _0xb31ee7=ut[_0x4d7393('0x3')](_0x5a4e77,_0x567d58,_0x506b60,_0xfff943,_0x1c3bec,_0x4d446d);_['merge'](_0x4d446d,ut[_0x4d7393('0x7f')](_0xb31ee7)),_0x4d446d[_0x4d7393('0xbc')]=moment()[_0x4d7393('0x133')](_0x4d7393('0xb8')),ami[_0x4d7393('0x137')](ut['variablesAction'](_0x4d446d,_0x5a4e77,_0xb31ee7,_0x4d446d[_0x4d7393('0x2d')],_0x3389cf))[_0x4d7393('0x8a')](function(_0x5ab888){const _0x74fb74=_0x4d7393;_0x5a4e77[_0x74fb74('0x72')]+=0x1,logger[_0x74fb74('0x1')](_0x74fb74('0xdb'),_0x1c3bec,_0x74fb74('0x55'),_0x5a4e77[_0x74fb74('0x97')],_0x74fb74('0x19'),_0x5a4e77[_0x74fb74('0x72')]),_0x470557(_0x5ab888);})['catch'](function(_0x518ef4){const _0x531fc7=_0x4d7393;ut[_0x531fc7('0x11a')](_0x4d446d,0xe,_0x531fc7('0x5b')),rpcDb[_0x531fc7('0x62')](_0x4d446d,_0x531fc7('0xf0')),_0x506a7d(_0x518ef4);});});},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x146')]=function(_0x662e1f){const _0x119472=_0x1bdf48;this[_0x119472('0xa9')][_0x662e1f[_0x119472('0xbf')]]&&(this[_0x119472('0xa9')][_0x662e1f[_0x119472('0xbf')]]['channel']=_0x662e1f[_0x119472('0x13')]);},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x78')]=function(_0x24684e){const _0x5e383a=_0x1bdf48,_0x58d448=this,_0xecd251=this[_0x5e383a('0xa9')][_0x24684e[_0x5e383a('0x50')]];if(_0xecd251){_0xecd251['lookAgent']&&this[_0x5e383a('0x5a')][_0xecd251['lookAgent']]&&ut[_0x5e383a('0x8d')](_0xecd251,this['agents'][_0xecd251[_0x5e383a('0x10e')]][_0x5e383a('0x97')],this[_0x5e383a('0x5a')][_0xecd251[_0x5e383a('0x10e')]]['id']);const _0x4bc36a=_[_0x5e383a('0x71')](_0xecd251);_0x4bc36a['responsetime']=moment()[_0x5e383a('0x133')](_0x5e383a('0xb8'));const _0x15af7a=_0x58d448['campaignsPreview'][_0xecd251[_0x5e383a('0x39')]];ut['isFailure'](_0x24684e[_0x5e383a('0x116')])?(_0xecd251[_0x5e383a('0x10')]&&rpcDb[_0x5e383a('0x60')](_0xecd251[_0x5e383a('0xcb')]),_0xecd251[_0x5e383a('0x2d')]&&rpcDb[_0x5e383a('0x2b')](_0xecd251['idContact']),ami['emit'](_0x5e383a('0xff'),ut['buildObj'](_0xecd251,'rejected')),this[_0x5e383a('0x95')](_0x4bc36a,_0x15af7a,_0x24684e)):(_0xecd251[_0x5e383a('0xbc')]=moment()[_0x5e383a('0x133')](_0x5e383a('0xb8')),ut['logAgent'](_0x4bc36a,0x4,_0x5e383a('0xf3')),rpcDb['createAgentHistory'](_0x4bc36a,_0x5e383a('0x2')));}},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x58')]=function(_0x165ed3){const _0x42623c=_0x1bdf48,_0x55bc16=this[_0x42623c('0xa9')][_0x165ed3[_0x42623c('0xbf')]];let _0x48cc80;_0x55bc16&&(_0x48cc80=this[_0x42623c('0xf7')][_0x55bc16[_0x42623c('0x39')]],logger[_0x42623c('0x1')](_0x42623c('0x28'),_0x165ed3[_0x42623c('0xbf')],_0x42623c('0x55'),_0x48cc80['name'],'pTalking:\x20',_0x48cc80[_0x42623c('0xe5')]));if(this[_0x42623c('0xa9')][_0x165ed3[_0x42623c('0xbf')]]&&_0x165ed3[_0x42623c('0xbf')]!==_0x165ed3[_0x42623c('0xa0')]){if(_0x165ed3[_0x42623c('0xed')]==='16'&&this[_0x42623c('0xa9')][_0x165ed3['linkedid']][_0x42623c('0x33')])this[_0x42623c('0x11d')](_0x165ed3,_0x165ed3[_0x42623c('0xbf')],_0x165ed3[_0x42623c('0xed')]);else this[_0x42623c('0xa9')][_0x165ed3[_0x42623c('0xbf')]][_0x42623c('0x33')]&&(logger[_0x42623c('0x1')]('[syncHangup][talking][cause]',_0x165ed3[_0x42623c('0xbf')],_0x165ed3['cause'],'\x20Queue',_0x48cc80[_0x42623c('0x97')],_0x42623c('0x11'),_0x48cc80['pTalking']),this[_0x42623c('0x11d')](_0x165ed3,_0x165ed3[_0x42623c('0xbf')],_0x165ed3[_0x42623c('0xed')]));}else{if(_0x55bc16&&_['isNil'](_0x55bc16[_0x42623c('0x83')])&&_0x48cc80['dialQueueProject']&&_0x165ed3[_0x42623c('0xbf')]===_0x165ed3[_0x42623c('0xa0')]&&_['isNil'](_0x165ed3[_0x42623c('0x17')])&&_0x165ed3[_0x42623c('0xed')]==='16'&&_0x165ed3['channelstate']==='6'&&_[_0x42623c('0xb1')](_0x55bc16[_0x42623c('0x8')]))_0x55bc16[_0x42623c('0x10')]&&rpcDb[_0x42623c('0x60')](_0x55bc16[_0x42623c('0xcb')]),_0x55bc16[_0x42623c('0x2d')]&&rpcDb[_0x42623c('0x2b')](_0x55bc16['idContact']),_0x165ed3[_0x42623c('0x17')]='22',this[_0x42623c('0x95')](_0x55bc16,_0x48cc80,_0x165ed3);else{if(_0x55bc16&&_0x55bc16[_0x42623c('0x8')]){if(_0x165ed3[_0x42623c('0xed')]==='16'&&this[_0x42623c('0xa9')][_0x165ed3[_0x42623c('0xbf')]][_0x42623c('0x33')])logger[_0x42623c('0x1')](_0x42623c('0x9f'),_0x165ed3['linkedid'],_0x165ed3[_0x42623c('0xed')],_0x42623c('0x55'),_0x48cc80[_0x42623c('0x97')],_0x42623c('0x11'),_0x48cc80[_0x42623c('0xe5')]),this[_0x42623c('0x11d')](_0x165ed3,_0x165ed3['linkedid'],_0x165ed3[_0x42623c('0xed')]);else this[_0x42623c('0xa9')][_0x165ed3['linkedid']][_0x42623c('0x33')]&&(logger[_0x42623c('0x1')](_0x42623c('0x3b'),_0x165ed3['linkedid'],_0x165ed3[_0x42623c('0xed')],'\x20Queue',_0x48cc80[_0x42623c('0x97')],'pTalking:\x20',_0x48cc80['pTalking']),this[_0x42623c('0x11d')](_0x165ed3,_0x165ed3['linkedid'],_0x165ed3[_0x42623c('0xed')]));}}}},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x47')]=function(_0x3e093c){const _0x490a25=_0x1bdf48;this[_0x490a25('0xa9')][_0x3e093c['destlinkedid']]&&_0x3e093c[_0x490a25('0xa')]!==_0x3e093c[_0x490a25('0x89')]&&this['callProgressDetectingCustomer'](_0x3e093c,_0x3e093c[_0x490a25('0xa')],_0x3e093c[_0x490a25('0x10d')]);},Preview['prototype'][_0x1bdf48('0x13d')]=function(_0x1e525d){const _0x3f49be=_0x1bdf48;this[_0x3f49be('0xa9')][_0x1e525d['linkedid']]&&_0x1e525d[_0x3f49be('0xbf')]!==_0x1e525d[_0x3f49be('0xa0')]&&!this[_0x3f49be('0xa9')][_0x1e525d[_0x3f49be('0xbf')]]['dialAnswer']&&(_0x1e525d[_0x3f49be('0xed')]==='1'&&this[_0x3f49be('0x11d')](_0x1e525d,_0x1e525d[_0x3f49be('0xbf')],_0x1e525d[_0x3f49be('0xed')]));},Preview[_0x1bdf48('0x113')][_0x1bdf48('0xd4')]=function(_0x1be0cc,_0x59bc00,_0x5afcfb){const _0x31fba0=_0x1bdf48;this[_0x31fba0('0xa9')][_0x1be0cc]&&(_[_0x31fba0('0x2c')](this['actions'][_0x1be0cc][_0x31fba0('0xe7')])&&(this['actions'][_0x1be0cc][_0x31fba0('0xe7')]={}),this[_0x31fba0('0xa9')][_0x1be0cc][_0x31fba0('0xe7')][_0x59bc00]=_0x5afcfb);},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x114')]=function(_0x3b7e9f){const _0x3b4d9e=_0x1bdf48;try{!_[_0x3b4d9e('0x2c')](_0x3b7e9f)&&(ut[_0x3b4d9e('0x10f')](_[_0x3b4d9e('0xb6')](_0x3b7e9f[_0x3b4d9e('0x12c')])[0x0])&&this['addVariable'](_0x3b7e9f[_0x3b4d9e('0xa0')],_[_0x3b4d9e('0xb6')](_0x3b7e9f['variable'])[0x0],_0x3b7e9f['value']));}catch(_0x1cfe3e){logger[_0x3b4d9e('0xea')](_0x3b4d9e('0x81'),util[_0x3b4d9e('0xcf')](_0x1cfe3e,{'showHidden':![],'depth':null}));}},Preview[_0x1bdf48('0x113')][_0x1bdf48('0x92')]=function(_0x256c84){const _0x824fc0=_0x1bdf48;_0x256c84&&(this[_0x824fc0('0xa9')][_0x256c84['transfertargetlinkedid']]&&(this[_0x824fc0('0xa9')][_0x256c84[_0x824fc0('0x13b')]][_0x824fc0('0x8')]=!![]));},Preview[_0x1bdf48('0x113')]['syncBlindTransfer']=function(_0x41dcea){const _0xd269fb=_0x1bdf48;_0x41dcea&&(this[_0xd269fb('0xa9')][_0x41dcea['transfererlinkedid']]&&(this[_0xd269fb('0xa9')][_0x41dcea[_0xd269fb('0xc0')]][_0xd269fb('0x8')]=!![]));},module['exports']=Preview; \ No newline at end of file diff --git a/server/services/ami/preview/rpcDb.js b/server/services/ami/preview/rpcDb.js index 10e4688..cd3a715 100644 --- a/server/services/ami/preview/rpcDb.js +++ b/server/services/ami/preview/rpcDb.js @@ -1 +1 @@ -const a1089_0x3da1=['[countReScheduled]\x20','calleridname','queuecallerjoinAt','uniqueid','[moveContactManagedDialer]\x20','../../../config/logger','COMPLETED','calleridnum','[rescheduleContact]\x20','util','checkIsBlackList','connectedlinename','catch','endtime','createHistory','unlockContact','UserId','[createHistory]\x20','../rpc/cmHopperBlack','inspect','disableContact','preview','../rpc/cmHopperHistory','then','[GetContactRecallMe]\x20','../rpc/agentReportPreview','getContactPreview','createAgentHistory','queuecallercompleteAt','[unlockContact]\x20','queuecallercomplete','active','queue','membername','create','error','countReScheduled','holdtime','[checkIsBlackList]\x20','from-sip','[voiceQueueReport]\x20','../rpc/voiceQueueReport','lastAssignedTo','rescheduleContact','createCustomerFinal','rescheduleContactInQueue','createCustomerHistory','type','resolve','../rpc/cmHopper','assigned','crateCustomerReportQueue','getContactRecallMe','context','exten'];(function(_0x2f309c,_0x3da168){const _0x141f2e=function(_0x1b7a1c){while(--_0x1b7a1c){_0x2f309c['push'](_0x2f309c['shift']());}};_0x141f2e(++_0x3da168);}(a1089_0x3da1,0x1d2));const a1089_0x141f=function(_0x2f309c,_0x3da168){_0x2f309c=_0x2f309c-0x0;let _0x141f2e=a1089_0x3da1[_0x2f309c];return _0x141f2e;};const _0x7a7bed=a1089_0x141f;'use strict';const util=require(_0x7a7bed('0x26')),logger=require(_0x7a7bed('0x22'))(_0x7a7bed('0x32')),cmHopper=require(_0x7a7bed('0x17')),cmHopperHistory=require(_0x7a7bed('0x33')),cmHopperBlack=require(_0x7a7bed('0x2f')),agentReportPreview=require(_0x7a7bed('0x36')),voiceQueueReport=require(_0x7a7bed('0xf'));function loggerCatch(_0x1b7a1c){return function(_0x1d5903){const _0x5010f2=a1089_0x141f;logger[_0x5010f2('0x9')](_0x1b7a1c,util[_0x5010f2('0x30')](_0x1d5903,{'showHidden':![],'depth':null}));};}function create(_0x4c3da7){const _0x34e4bc=_0x7a7bed;return Promise[_0x34e4bc('0x16')]()['then'](cmHopperHistory['createHistory'](_0x4c3da7))[_0x34e4bc('0x29')](loggerCatch(_0x34e4bc('0x2e')));}function createAgent(_0x27dd46){const _0x33352b=_0x7a7bed;return Promise[_0x33352b('0x16')]()[_0x33352b('0x34')](agentReportPreview[_0x33352b('0x2b')](_0x27dd46))['catch'](loggerCatch(_0x33352b('0x2e')));}function moveContact(_0x22d81d){const _0x295550=_0x7a7bed;return Promise[_0x295550('0x16')]()['then'](cmHopper['moveContactManagedDialer'](_0x22d81d,!![]))[_0x295550('0x29')](loggerCatch(_0x295550('0x21')));}exports['checkIsBlackList']=function(_0x53d6b8){const _0x40925a=_0x7a7bed;return Promise[_0x40925a('0x16')]()[_0x40925a('0x34')](cmHopperBlack[_0x40925a('0x27')](_0x53d6b8))[_0x40925a('0x29')](loggerCatch(_0x40925a('0xc')));},exports[_0x7a7bed('0x0')]=function(_0x3c2e8d){const _0x4ed283=_0x7a7bed;return Promise[_0x4ed283('0x16')]()[_0x4ed283('0x34')](cmHopper[_0x4ed283('0x0')](_0x3c2e8d))['catch'](loggerCatch('[getContactPreview]\x20'));},exports['createHistory']=function(_0x2c775c,_0x1607cc){const _0x1c17c3=_0x7a7bed;create(_0x2c775c)[_0x1c17c3('0x29')](loggerCatch(_0x1607cc)),moveContact(_0x2c775c)[_0x1c17c3('0x29')](loggerCatch(_0x1607cc));},exports[_0x7a7bed('0x1')]=function(_0x2f8588,_0x913c8e){const _0x44dfd3=_0x7a7bed;createAgent(_0x2f8588)[_0x44dfd3('0x29')](loggerCatch(_0x913c8e));},exports[_0x7a7bed('0x14')]=function(_0x1a56dd,_0x4e4713){const _0x39af96=_0x7a7bed;create(_0x1a56dd)[_0x39af96('0x29')](loggerCatch(_0x4e4713));},exports[_0x7a7bed('0x12')]=function(_0x5c7350,_0x46d4ac){moveContact(_0x5c7350)['catch'](loggerCatch(_0x46d4ac));},exports['rescheduleContact']=function(_0x2074f5,_0x46ea03,_0x47a51b){const _0x16c1b0=_0x7a7bed;return _0x46ea03&&(_0x2074f5[_0x16c1b0('0x2d')]=null),_0x47a51b&&(_0x2074f5[_0x16c1b0('0x5')]=![]),Promise[_0x16c1b0('0x16')]()[_0x16c1b0('0x34')](cmHopper[_0x16c1b0('0x11')](_0x2074f5))[_0x16c1b0('0x29')](loggerCatch(_0x16c1b0('0x25')));},exports[_0x7a7bed('0xa')]=function(_0x4b1f3c){const _0x52e445=_0x7a7bed;return Promise[_0x52e445('0x16')]()['then'](cmHopper['countReScheduled'](_0x4b1f3c))[_0x52e445('0x29')](loggerCatch(_0x52e445('0x1d')));},exports[_0x7a7bed('0x2c')]=function(_0x18b51a){const _0x1e6a1d=_0x7a7bed;return Promise['resolve']()[_0x1e6a1d('0x34')](cmHopper[_0x1e6a1d('0x2c')]({'UserId':null},_0x18b51a,0x1))[_0x1e6a1d('0x29')](loggerCatch(_0x1e6a1d('0x3')));},exports[_0x7a7bed('0x31')]=function(_0x5519b1){const _0x305bef=_0x7a7bed;return Promise[_0x305bef('0x16')]()['then'](cmHopper[_0x305bef('0x2c')]({'active':![]},_0x5519b1,0x1))['catch'](loggerCatch('[activeContact]\x20'));},exports[_0x7a7bed('0x19')]=function(_0x5a2fbb){const _0x370ec0=_0x7a7bed,_0x9aff92={};return _0x9aff92[_0x370ec0('0x15')]=_0x5a2fbb[_0x370ec0('0x15')],_0x9aff92[_0x370ec0('0x20')]=_0x5a2fbb[_0x370ec0('0x20')],_0x9aff92[_0x370ec0('0x24')]=_0x5a2fbb[_0x370ec0('0x24')],_0x9aff92['calleridname']=_0x5a2fbb[_0x370ec0('0x1e')],_0x9aff92[_0x370ec0('0x6')]=_0x5a2fbb[_0x370ec0('0x6')],_0x9aff92[_0x370ec0('0x1f')]=_0x5a2fbb['answertime'],_0x9aff92['queuecallerleaveAt']=_0x5a2fbb['answertime'],_0x9aff92[_0x370ec0('0x4')]=0x1,_0x9aff92[_0x370ec0('0x2')]=_0x5a2fbb[_0x370ec0('0x2a')],_0x9aff92[_0x370ec0('0x28')]=_0x5a2fbb[_0x370ec0('0x7')],_0x9aff92[_0x370ec0('0x1b')]=_0x370ec0('0xd'),_0x9aff92[_0x370ec0('0x1c')]='xcally-motion-preview',_0x9aff92[_0x370ec0('0xb')]=0x0,_0x9aff92[_0x370ec0('0x18')]=0x1,_0x9aff92[_0x370ec0('0x10')]=_0x5a2fbb[_0x370ec0('0x7')],_0x9aff92['queuecallerexitreason']=_0x370ec0('0x23'),Promise['resolve']()[_0x370ec0('0x34')](voiceQueueReport[_0x370ec0('0x8')](_0x9aff92))['catch'](loggerCatch(_0x370ec0('0xe')));},exports[_0x7a7bed('0x1a')]=function(_0x7a1561,_0x29ab1c){const _0x13cf12=_0x7a7bed;return Promise[_0x13cf12('0x16')]()[_0x13cf12('0x34')](cmHopper[_0x13cf12('0x1a')](_0x7a1561,_0x29ab1c))['catch'](loggerCatch(_0x13cf12('0x35')));},exports[_0x7a7bed('0x13')]=function(_0x32623f){const _0xaa8920=_0x7a7bed;return Promise[_0xaa8920('0x16')]()[_0xaa8920('0x34')](cmHopper['rescheduleContact'](_0x32623f,!![],!![]))[_0xaa8920('0x29')](loggerCatch('[rescheduleContactInQueue]\x20'));}; \ No newline at end of file +const a1089_0x1cef=['endtime','calleridname','[getContactPreview]\x20','[rescheduleContact]\x20','queuecallercomplete','moveContactManagedDialer','[countReScheduled]\x20','rescheduleContactInQueue','checkIsBlackList','crateCustomerReportQueue','type','resolve','[unlockContact]\x20','unlockContact','lastAssignedTo','xcally-motion-preview','../rpc/agentReportPreview','queuecallerjoinAt','membername','context','[createHistory]\x20','[moveContactManagedDialer]\x20','countReScheduled','getContactRecallMe','../rpc/voiceQueueReport','holdtime','UserId','error','queuecallercompleteAt','createCustomerFinal','then','exten','getContactPreview','assigned','create','uniqueid','[GetContactRecallMe]\x20','active','../../../config/logger','[voiceQueueReport]\x20','../rpc/cmHopper','answertime','../rpc/cmHopperBlack','queue','[checkIsBlackList]\x20','[rescheduleContactInQueue]\x20','inspect','calleridnum','catch','createHistory','rescheduleContact','[activeContact]\x20','from-sip'];(function(_0x3ebfc9,_0x1cef6f){const _0x7407b0=function(_0x482139){while(--_0x482139){_0x3ebfc9['push'](_0x3ebfc9['shift']());}};_0x7407b0(++_0x1cef6f);}(a1089_0x1cef,0x6e));const a1089_0x7407=function(_0x3ebfc9,_0x1cef6f){_0x3ebfc9=_0x3ebfc9-0x0;let _0x7407b0=a1089_0x1cef[_0x3ebfc9];return _0x7407b0;};const _0x4b4b36=a1089_0x7407;'use strict';const util=require('util'),logger=require(_0x4b4b36('0x22'))('preview'),cmHopper=require(_0x4b4b36('0x24')),cmHopperHistory=require('../rpc/cmHopperHistory'),cmHopperBlack=require(_0x4b4b36('0x26')),agentReportPreview=require(_0x4b4b36('0xc')),voiceQueueReport=require(_0x4b4b36('0x14'));function loggerCatch(_0x482139){return function(_0x1e3c93){const _0xd2ca59=a1089_0x7407;logger[_0xd2ca59('0x17')](_0x482139,util[_0xd2ca59('0x2a')](_0x1e3c93,{'showHidden':![],'depth':null}));};}function create(_0x2c0404){const _0x5afe08=_0x4b4b36;return Promise[_0x5afe08('0x7')]()[_0x5afe08('0x1a')](cmHopperHistory[_0x5afe08('0x2d')](_0x2c0404))[_0x5afe08('0x2c')](loggerCatch('[createHistory]\x20'));}function createAgent(_0x2caa14){const _0x31238e=_0x4b4b36;return Promise['resolve']()[_0x31238e('0x1a')](agentReportPreview['createHistory'](_0x2caa14))[_0x31238e('0x2c')](loggerCatch(_0x31238e('0x10')));}function moveContact(_0x37883a){const _0x426da3=_0x4b4b36;return Promise[_0x426da3('0x7')]()[_0x426da3('0x1a')](cmHopper[_0x426da3('0x1')](_0x37883a,!![]))[_0x426da3('0x2c')](loggerCatch(_0x426da3('0x11')));}exports[_0x4b4b36('0x4')]=function(_0xd09489){const _0x4d6355=_0x4b4b36;return Promise[_0x4d6355('0x7')]()[_0x4d6355('0x1a')](cmHopperBlack[_0x4d6355('0x4')](_0xd09489))[_0x4d6355('0x2c')](loggerCatch(_0x4d6355('0x28')));},exports[_0x4b4b36('0x1c')]=function(_0x549837){const _0x32ab69=_0x4b4b36;return Promise['resolve']()['then'](cmHopper[_0x32ab69('0x1c')](_0x549837))['catch'](loggerCatch(_0x32ab69('0x33')));},exports[_0x4b4b36('0x2d')]=function(_0x227a1a,_0x292e9d){const _0x2944d3=_0x4b4b36;create(_0x227a1a)[_0x2944d3('0x2c')](loggerCatch(_0x292e9d)),moveContact(_0x227a1a)[_0x2944d3('0x2c')](loggerCatch(_0x292e9d));},exports['createAgentHistory']=function(_0x4de9b7,_0x1dccbb){createAgent(_0x4de9b7)['catch'](loggerCatch(_0x1dccbb));},exports['createCustomerHistory']=function(_0x25fb5a,_0x5a4bf4){create(_0x25fb5a)['catch'](loggerCatch(_0x5a4bf4));},exports[_0x4b4b36('0x19')]=function(_0x3535f1,_0x2f167c){const _0x1111dc=_0x4b4b36;moveContact(_0x3535f1)[_0x1111dc('0x2c')](loggerCatch(_0x2f167c));},exports[_0x4b4b36('0x2e')]=function(_0x3fad9c,_0x29ed1e,_0x7e37f5){const _0x298730=_0x4b4b36;return _0x29ed1e&&(_0x3fad9c[_0x298730('0x16')]=null),_0x7e37f5&&(_0x3fad9c[_0x298730('0x21')]=![]),Promise[_0x298730('0x7')]()[_0x298730('0x1a')](cmHopper[_0x298730('0x2e')](_0x3fad9c))[_0x298730('0x2c')](loggerCatch(_0x298730('0x34')));},exports[_0x4b4b36('0x12')]=function(_0x5d7ef8){const _0x22babc=_0x4b4b36;return Promise[_0x22babc('0x7')]()[_0x22babc('0x1a')](cmHopper[_0x22babc('0x12')](_0x5d7ef8))['catch'](loggerCatch(_0x22babc('0x2')));},exports[_0x4b4b36('0x9')]=function(_0x13aa20){const _0x1fc24f=_0x4b4b36;return Promise[_0x1fc24f('0x7')]()[_0x1fc24f('0x1a')](cmHopper[_0x1fc24f('0x9')]({'UserId':null},_0x13aa20,0x1))[_0x1fc24f('0x2c')](loggerCatch(_0x1fc24f('0x8')));},exports['disableContact']=function(_0x4acdf5){const _0x574bcf=_0x4b4b36;return Promise[_0x574bcf('0x7')]()['then'](cmHopper[_0x574bcf('0x9')]({'active':![]},_0x4acdf5,0x1))[_0x574bcf('0x2c')](loggerCatch(_0x574bcf('0x2f')));},exports[_0x4b4b36('0x5')]=function(_0x418c6d){const _0x7d2000=_0x4b4b36,_0x43275b={};return _0x43275b[_0x7d2000('0x6')]=_0x418c6d[_0x7d2000('0x6')],_0x43275b['uniqueid']=_0x418c6d[_0x7d2000('0x1f')],_0x43275b[_0x7d2000('0x2b')]=_0x418c6d[_0x7d2000('0x2b')],_0x43275b[_0x7d2000('0x32')]=_0x418c6d[_0x7d2000('0x32')],_0x43275b[_0x7d2000('0x27')]=_0x418c6d[_0x7d2000('0x27')],_0x43275b[_0x7d2000('0xd')]=_0x418c6d['answertime'],_0x43275b['queuecallerleaveAt']=_0x418c6d[_0x7d2000('0x25')],_0x43275b[_0x7d2000('0x0')]=0x1,_0x43275b[_0x7d2000('0x18')]=_0x418c6d[_0x7d2000('0x31')],_0x43275b['connectedlinename']=_0x418c6d[_0x7d2000('0xe')],_0x43275b[_0x7d2000('0xf')]=_0x7d2000('0x30'),_0x43275b[_0x7d2000('0x1b')]=_0x7d2000('0xb'),_0x43275b[_0x7d2000('0x15')]=0x0,_0x43275b[_0x7d2000('0x1d')]=0x1,_0x43275b[_0x7d2000('0xa')]=_0x418c6d[_0x7d2000('0xe')],_0x43275b['queuecallerexitreason']='COMPLETED',Promise[_0x7d2000('0x7')]()[_0x7d2000('0x1a')](voiceQueueReport[_0x7d2000('0x1e')](_0x43275b))[_0x7d2000('0x2c')](loggerCatch(_0x7d2000('0x23')));},exports[_0x4b4b36('0x13')]=function(_0x1db7ad,_0x5b3a09){const _0x402e6a=_0x4b4b36;return Promise[_0x402e6a('0x7')]()['then'](cmHopper[_0x402e6a('0x13')](_0x1db7ad,_0x5b3a09))[_0x402e6a('0x2c')](loggerCatch(_0x402e6a('0x20')));},exports[_0x4b4b36('0x3')]=function(_0x2c7a36){const _0x479304=_0x4b4b36;return Promise['resolve']()[_0x479304('0x1a')](cmHopper[_0x479304('0x2e')](_0x2c7a36,!![],!![]))[_0x479304('0x2c')](loggerCatch(_0x479304('0x29')));}; \ No newline at end of file diff --git a/server/services/ami/preview/util/util.js b/server/services/ami/preview/util/util.js index ca569bc..bfb6f8d 100644 --- a/server/services/ami/preview/util/util.js +++ b/server/services/ami/preview/util/util.js @@ -1 +1 @@ -const a1090_0x4354=['bridgepeer','../../../../config/config.service','rtpaudioqos','string','countbusyretry','countcongestionretry','xmd-dialtimeout','countagentrejectretry','match','pow','logCustomer','clone','timeout','variablesAction','isEmpty','xmd-dialoptions','filterKey','toUpper','isFailure','isActive','xmd-contactid','YYYY-MM-DD\x20HH:mm:ss','createBody','endtime','countnosuchnumberretry','\x22agi://%s/square,%s\x22','pTalking','getDiff','scheduledat','interface','xmd-dialchannel','xmd-listid','error','dialPreviewUrl','toLower','active','sipcallid','rtpaudioqosjitterbridged','IsNotLoggedIn','dialOriginateTimeout','idContact','membername','push','undefined','updateOriginated','dialQueueProject','agiIp','\x22%s\x22\x20<%s>','lastevent','rtpaudioqosrttbridged','inspect','updatedAt','loggerError','getCallerIdRandom','buildAcw','callback','getCallerId','\x5cw{0,','[updateOriginated]\x20object\x20originated\x20is\x20negative','starttime','rtpaudioqosrtt','rtpaudioqosloss','originatecalleridnum','queue','xmd-voicequeueid','ListId','Contact','countglobal','Failure','loggerCatch','RECALL','extractCalleridName','dialer','calleridnum','dialAnswer','VoiceQueueId','XMD-','../../../../config/logger','answertime','dialQueueProject2','isNil','[decrementTalkink]\x20object\x20talking\x20is\x20negative','\x22\x22\x20<>','add','info','ringtime','Queue','seconds','util','lodash','rtpaudioqoslossbridged','message','not_inuse','replace','uniqueid','logBlacklist','milliseconds','monitor_format','state','recallme','status','minutes','[updateOriginated]\x20is\x20null\x20or\x20undefined','tags','channelAgent','addVariables','xmd-callerid','calleridname','createdAt','rtpaudioqosbridged','countnoanswerretry','statedesc','CampaignId','type','isUndefined','ContactId','scheduledAt','Global','format','moment','[decrementTalkink]\x20is\x20null\x20or\x20undefined','callbackuniqueid','responsetime','campaigntype','preview','%s%s','BOOKED','originatecalleridname','logAgent','_XCALLY_MIXMONITOR_UNIQUEID','toLowerVariables','xmd-dialid','agentReadyId','totalGlobal','rtpaudioqosjitter','U(xcally-mixmonitor-context)','UserId','random'];(function(_0x2bd930,_0x4354c4){const _0x467452=function(_0x579f71){while(--_0x579f71){_0x2bd930['push'](_0x2bd930['shift']());}};_0x467452(++_0x4354c4);}(a1090_0x4354,0x81));const a1090_0x4674=function(_0x2bd930,_0x4354c4){_0x2bd930=_0x2bd930-0x0;let _0x467452=a1090_0x4354[_0x2bd930];return _0x467452;};const _0x92f61f=a1090_0x4674;'use strict';const util=require(_0x92f61f('0x61')),_=require(_0x92f61f('0x62')),moment=require(_0x92f61f('0x80')),logger=require(_0x92f61f('0x56'))(_0x92f61f('0x85')),{getConfigService}=require(_0x92f61f('0xa'));function getSeconds(_0x579f71,_0x4102d7){const _0x14e1f5=_0x92f61f,_0x5019c2=moment(_0x579f71)[_0x14e1f5('0x69')](0x0),_0x1ace0b=moment(_0x4102d7)[_0x14e1f5('0x69')](0x0);return _0x5019c2['diff'](_0x1ace0b,'seconds');}exports[_0x92f61f('0x4e')]=function(_0x1feaf3){return function(_0x4386cc){const _0x360fcd=a1090_0x4674;logger[_0x360fcd('0x29')](_0x1feaf3,util[_0x360fcd('0x3b')](_0x4386cc,{'showHidden':![],'depth':null}));};},exports['logger']=function(_0x61cb30,_0x4e80cb){const _0x108d92=_0x92f61f;logger['info'](_0x61cb30,util[_0x108d92('0x3b')](_0x4e80cb,{'showHidden':![],'depth':null}));},exports[_0x92f61f('0x3d')]=function(_0x14a4b6,_0x3772f0){const _0x1e0365=_0x92f61f;logger[_0x1e0365('0x29')](_0x14a4b6,util[_0x1e0365('0x3b')](_0x3772f0,{'showHidden':![],'depth':null}));},exports['logger2']=function(_0x4b67d1){return function(_0x585717){const _0x52d2e2=a1090_0x4674;logger[_0x52d2e2('0x5d')](_0x4b67d1,util[_0x52d2e2('0x3b')](_0x585717,{'showHidden':![],'depth':null}));};},exports[_0x92f61f('0x64')]=function(_0x145af4,_0x2a3358,_0x47ab82){return{'message':_0x145af4,'unlock':_0x2a3358,'active':_0x47ab82};},exports[_0x92f61f('0x41')]=function(_0x49f842,_0x49cf5e,_0xef6176){const _0x56d846=_0x92f61f;if(!_[_0x56d846('0x7b')](_0xef6176)&&_0x56d846('0xc')===typeof _0xef6176&&!_[_0x56d846('0x17')](_0xef6176)){if(!_[_0x56d846('0x7b')](_0x49cf5e)&&'string'===typeof _0x49cf5e&&!_[_0x56d846('0x17')](_0x49cf5e))return util[_0x56d846('0x7f')](_0x56d846('0x38'),_0x49cf5e,_0xef6176);return util[_0x56d846('0x7f')]('\x22%s\x22\x20<%s>',_0xef6176,_0xef6176);}if(!_[_0x56d846('0x7b')](_0x49f842)&&_0x56d846('0xc')===typeof _0x49f842&&!_[_0x56d846('0x17')](_0x49f842))return _0x49f842;return _0x56d846('0x5b');},exports[_0x92f61f('0x1c')]=function(_0x19a8b0){const _0x23daa7=_0x92f61f;if(_[_0x23daa7('0x59')](_0x19a8b0))return![];return _0x19a8b0;},exports[_0x92f61f('0x72')]=function(_0x4e4198,_0xec1ddb,_0x524027,_0x5b07ef,_0x56b4b4,_0x5b431f){const _0x46483b=_0x92f61f,_0x48d6f2=getConfigService(),_0x3f728d={'XMD-QUEUE':_0xec1ddb[_0x46483b('0x5f')]?_0xec1ddb[_0x46483b('0x5f')]['name']:'','XMD-CALLERID':_0x5b07ef,'XMD-CALLERID-PREVIEW':_0x5b431f?util[_0x46483b('0x7f')]('\x22%s\x22\x20<%s>',_0x5b431f[_0x46483b('0x74')],_0x5b431f[_0x46483b('0x52')]):_0x5b07ef,'XMD-DIALID':_0x56b4b4,'XMD-CONTACTID':_0xec1ddb[_0x46483b('0x7c')],'XMD-CDRTYPE':_0x46483b('0x51'),'CALLERID(all)':_0x5b07ef,'XMD-VOICEQUEUEID':_0xec1ddb[_0x46483b('0x54')],'XMD-DIALCHANNEL':_0x524027,'XMD-DIALTIMEOUT':_0x4e4198[_0x46483b('0x30')]||0x1e,'XMD-DIALOPTIONS':util['format']('\x22rtTxX%s%s\x22',_0x4e4198['dialQueueProject2']?'g':'',_['isEmpty'](_0x4e4198['monitor_format'])?'':_0x46483b('0x6')),'XMD-DIALURL':_0x4e4198[_0x46483b('0x2a')]||'','XMD-AGI':_0x4e4198['dialQueueProject']?util[_0x46483b('0x7f')](_0x46483b('0x22'),_0x48d6f2[_0x46483b('0x37')],_0x4e4198[_0x46483b('0x36')]):'NONE','XMD-AGIAFTER':_0x4e4198['dialQueueProject2']?util[_0x46483b('0x7f')]('\x22agi://%s/square,%s\x22',_0x48d6f2[_0x46483b('0x37')],_0x4e4198[_0x46483b('0x58')]):'NONE','XMD-ORIGINATECALLERIDNUM':_0x5b431f?_0x5b431f[_0x46483b('0x47')]:'','XMD-ORIGINATECALLERIDNAME':_0x5b431f?_0x5b431f[_0x46483b('0x88')]:'','XMD-DESTINATION':'xcally-motion-preview'};!_[_0x46483b('0x17')](_0x4e4198[_0x46483b('0x6a')])&&(_0x3f728d[util[_0x46483b('0x7f')]('%s','_XCALLY_MIXMONITOR_FORMAT')]=_0x4e4198[_0x46483b('0x6a')],_0x3f728d[util[_0x46483b('0x7f')]('%s',_0x46483b('0x0'))]=_0x56b4b4);if(_0xec1ddb&&_0xec1ddb[_0x46483b('0x4b')])for(const _0x36b392 in _0xec1ddb['Contact']){typeof _0xec1ddb[_0x46483b('0x4b')][_0x36b392]!==_0x46483b('0x34')&&(!_['isNil'](_0xec1ddb[_0x46483b('0x4b')][_0x36b392])&&_0x36b392!=='id'&&_0x36b392!==_0x46483b('0x70')&&_0x36b392!==_0x46483b('0x75')&&_0x36b392!==_0x46483b('0x3c')&&(_0x3f728d[util['format'](_0x46483b('0x86'),_0x46483b('0x55'),_[_0x46483b('0x1a')](_0x36b392))]=_0xec1ddb[_0x46483b('0x4b')][_0x36b392]));}return _0x3f728d;},exports[_0x92f61f('0x1')]=function(_0x2bf9b8){const _0x269270=_0x92f61f,_0x31f062={};for(const _0x24a516 in _0x2bf9b8){typeof _0x2bf9b8[_0x24a516]!==_0x269270('0x34')&&(_0x31f062[util[_0x269270('0x7f')]('%s',_[_0x269270('0x2b')](_0x24a516))]=_0x2bf9b8[_0x24a516]);}return{'variables':_0x31f062};},exports[_0x92f61f('0x35')]=function(_0x1372f5,_0xa61239){const _0x4f3fab=_0x92f61f;!_['isNil'](_0x1372f5)?typeof _0x1372f5['originated']!==_0x4f3fab('0x34')&&(_0x1372f5['originated']>0x0?_0x1372f5['originated']-=0x1:logger[_0x4f3fab('0x29')](_0x4f3fab('0x43'),_0xa61239)):logger[_0x4f3fab('0x29')](_0x4f3fab('0x6f'),_0xa61239);},exports[_0x92f61f('0x68')]=function(_0x34625c){const _0x12985f=_0x92f61f,_0x332d71=moment()['format'](_0x12985f('0x1e'));_0x34625c['state']=0xd,_0x34625c[_0x12985f('0x78')]='Blacklist',_0x34625c[_0x12985f('0x44')]=_0x332d71,_0x34625c[_0x12985f('0x83')]=_0x332d71,_0x34625c[_0x12985f('0x20')]=_0x332d71;},exports[_0x92f61f('0x89')]=function(_0x5c1bd7,_0x35b95d,_0x4a4bff){const _0x29c2b0=_0x92f61f,_0x32fa45=moment()[_0x29c2b0('0x7f')]('YYYY-MM-DD\x20HH:mm:ss');_0x5c1bd7[_0x29c2b0('0x6b')]=_0x35b95d,_0x5c1bd7['statedesc']=_0x4a4bff,_0x5c1bd7['responsetime']=_0x32fa45,_0x5c1bd7[_0x29c2b0('0x5e')]=getSeconds(_0x5c1bd7[_0x29c2b0('0x83')],_0x5c1bd7[_0x29c2b0('0x44')]);},exports['logLookAgent']=function(_0x245594,_0x3497fa,_0x278979){const _0x3082f9=_0x92f61f;_0x245594[_0x3082f9('0x32')]=_0x3497fa,_0x245594[_0x3082f9('0x7')]=_0x278979;},exports[_0x92f61f('0x13')]=function(_0x4a4502,_0x3373e4,_0x47650c){const _0x4b4e87=_0x92f61f,_0x52e72c=moment()[_0x4b4e87('0x7f')](_0x4b4e87('0x1e'));_0x4a4502[_0x4b4e87('0x6b')]=_0x3373e4,_0x4a4502[_0x4b4e87('0x78')]=_0x47650c,_0x4a4502[_0x4b4e87('0x83')]=_0x4a4502[_0x4b4e87('0x83')]?_0x4a4502[_0x4b4e87('0x83')]:_0x52e72c,_0x4a4502['endtime']=_0x4a4502[_0x4b4e87('0x20')]?_0x4a4502[_0x4b4e87('0x20')]:_0x52e72c,_0x4a4502['ringtime']=getSeconds(_0x4a4502[_0x4b4e87('0x83')]||0x0,_0x4a4502['starttime']||0x0),_0x4a4502['talktime']=_0x4a4502[_0x4b4e87('0x57')]?getSeconds(_0x4a4502[_0x4b4e87('0x20')],_0x4a4502[_0x4b4e87('0x57')]):0x0;},exports[_0x92f61f('0x1b')]=function(_0x1d76bb){const _0x57a86e=_0x92f61f;return _0x1d76bb===_0x57a86e('0x4d');},exports[_0x92f61f('0x16')]=function(_0x475190,_0x49e1ff,_0x456201,_0x5adf62,_0x113edf){const _0x19f930=_0x92f61f;let _0x422a1e=_0x5adf62?_0x19f930('0x4f'):_0x475190[_0x19f930('0x74')];return _0x422a1e=_0x113edf?_0x19f930('0x87'):_0x422a1e,{'actionid':_0x475190['uniqueid'],'action':'originate','channel':_0x475190[_0x19f930('0x71')],'callerid':util[_0x19f930('0x7f')](_0x19f930('0x38'),_0x422a1e,_0x475190['calleridnum']),'Exten':'xcally-motion-preview','Context':'from-sip','Priority':'1','variable':_0x456201,'timeout':(_0x49e1ff[_0x19f930('0x15')]||0x1e)*0x3e8,'async':!![],'channelid':_0x475190[_0x19f930('0x67')]};},exports[_0x92f61f('0x4')]=function(_0x2a4054){const _0x161906=_0x92f61f;return _0x2a4054[_0x161906('0xd')]+_0x2a4054['countcongestionretry']+_0x2a4054['countnoanswerretry']+_0x2a4054[_0x161906('0x10')]+_0x2a4054[_0x161906('0x21')];},exports['cloneAction']=function(_0x36df41){const _0x431605=_0x92f61f,_0x3a90e5=_[_0x431605('0x14')](_0x36df41);return _0x3a90e5[_0x431605('0x6b')]=0xf,_0x3a90e5[_0x431605('0x78')]=_0x431605('0x7e'),_0x3a90e5;},exports[_0x92f61f('0x7d')]=function(_0x439ebf,_0x2ae76a,_0x2c598b){const _0x156cc0=_0x92f61f,_0x1d7f16={};return _0x1d7f16[_0x2ae76a]=_0x439ebf[_0x2ae76a],_0x1d7f16[_0x156cc0('0x2c')]=![],_0x1d7f16['scheduledat']=moment()[_0x156cc0('0x5c')](_0x2c598b,_0x156cc0('0x6e'))[_0x156cc0('0x7f')](_0x156cc0('0x1e')),_0x1d7f16[_0x156cc0('0x7c')]=_0x439ebf[_0x156cc0('0x7c')],_0x1d7f16[_0x156cc0('0x4a')]=_0x439ebf[_0x156cc0('0x4a')],_0x1d7f16[_0x156cc0('0x54')]=_0x439ebf[_0x156cc0('0x54')]||undefined,_0x1d7f16;},exports['decrementTalkink']=function(_0x271c67,_0xe0429b){const _0xf31045=_0x92f61f;!_['isNil'](_0x271c67)?_0x271c67[_0xf31045('0x23')]>0x0?_0x271c67[_0xf31045('0x23')]-=0x1:logger[_0xf31045('0x29')](_0xe0429b,_0xf31045('0x5a')):logger[_0xf31045('0x29')](_0xe0429b,_0xf31045('0x81'));},exports[_0x92f61f('0x2f')]=function(_0x3e6e07){if(_0x3e6e07<=0x0)return!![];return![];},exports['buildObj']=function(_0x96bea2,_0x552132){const _0x5c72eb=_0x92f61f;return _0x96bea2[_0x5c72eb('0x39')]=_0x552132,_0x96bea2['name']=_0x96bea2[_0x5c72eb('0x48')],_0x96bea2[_0x5c72eb('0x26')]=_0x96bea2[_0x5c72eb('0x71')],_0x96bea2;},exports[_0x92f61f('0x3f')]=function(_0x22e3d0){const _0x35054a=_0x92f61f,_0xd190e6={};return _0xd190e6[_0x35054a('0x48')]=_0x22e3d0[_0x35054a('0x48')],_0xd190e6[_0x35054a('0x26')]=_0x22e3d0[_0x35054a('0x71')],_0xd190e6[_0x35054a('0x67')]=_0x22e3d0['uniqueid'],_0xd190e6;},exports[_0x92f61f('0x3')]=function(_0x3fc323){const _0x52745d=_0x92f61f,_0x4f02f4=[];for(const _0x26491f in _0x3fc323){typeof _0x3fc323[_0x26491f]!==_0x52745d('0x34')&&(!_[_0x52745d('0x59')](_0x3fc323[_0x26491f])&&_0x3fc323[_0x26491f][_0x52745d('0x6b')]===_0x52745d('0x65')&&_0x3fc323[_0x26491f][_0x52745d('0x6d')]==='reachable'&&_0x4f02f4[_0x52745d('0x33')](_0x3fc323[_0x26491f]['id']));}return _0x4f02f4;},exports[_0x92f61f('0x24')]=function(_0x10f04f){const _0x2d29a3=_0x92f61f,_0x4ba109=moment()[_0x2d29a3('0x69')](0x0),_0x27beaf=moment(_0x10f04f)['milliseconds'](0x0);return _0x4ba109['diff'](_0x27beaf,_0x2d29a3('0x60'));},exports[_0x92f61f('0x1f')]=function(_0x4270ff){const _0x24c3cb=_0x92f61f;return{'active':![],'recallme':![],'UserId':null,'ContactId':_0x4270ff['ContactId'],'ListId':_0x4270ff[_0x24c3cb('0x4a')],'VoiceQueueId':_0x4270ff[_0x24c3cb('0x54')]||undefined,'CampaignId':_0x4270ff[_0x24c3cb('0x79')]||undefined};},exports[_0x92f61f('0x19')]=function(_0x1228d2){const _0x4a9a88=_0x92f61f;if(_0x1228d2==='uniqueid'||_0x1228d2===_0x4a9a88('0x31')||_0x1228d2===_0x4a9a88('0x48')||_0x1228d2===_0x4a9a88('0x7a')||_0x1228d2===_0x4a9a88('0x84')||_0x1228d2===_0x4a9a88('0x53')||_0x1228d2===_0x4a9a88('0x32')||_0x1228d2===_0x4a9a88('0x71')||_0x1228d2==='calleridname'||_0x1228d2===_0x4a9a88('0x2c')||_0x1228d2===_0x4a9a88('0x52')||_0x1228d2===_0x4a9a88('0x25')||_0x1228d2===_0x4a9a88('0xd')||_0x1228d2===_0x4a9a88('0xe')||_0x1228d2===_0x4a9a88('0x77')||_0x1228d2===_0x4a9a88('0x4c')||_0x1228d2===_0x4a9a88('0x40')||_0x1228d2===_0x4a9a88('0x82')||_0x1228d2==='callbackat'||_0x1228d2===_0x4a9a88('0x6c')||_0x1228d2===_0x4a9a88('0x7c')||_0x1228d2===_0x4a9a88('0x4a')||_0x1228d2===_0x4a9a88('0x7')||_0x1228d2==='VoiceQueueId'||_0x1228d2===_0x4a9a88('0x2d')||_0x1228d2===_0x4a9a88('0x49')||_0x1228d2==='xmd-queue'||_0x1228d2==='xmd-phone'||_0x1228d2===_0x4a9a88('0x28')||_0x1228d2==='xmd-dialurl'||_0x1228d2===_0x4a9a88('0xf')||_0x1228d2===_0x4a9a88('0x18')||_0x1228d2===_0x4a9a88('0x2')||_0x1228d2===_0x4a9a88('0x27')||_0x1228d2===_0x4a9a88('0x1d')||_0x1228d2==='xmd-cdrtype'||_0x1228d2===_0x4a9a88('0x73')||_0x1228d2==='xmd-agiafter'||_0x1228d2==='xmd-agi'||_0x1228d2==='rtpaudioqos'||_0x1228d2===_0x4a9a88('0x76')||_0x1228d2===_0x4a9a88('0x5')||_0x1228d2===_0x4a9a88('0x2e')||_0x1228d2===_0x4a9a88('0x46')||_0x1228d2===_0x4a9a88('0x63')||_0x1228d2===_0x4a9a88('0x45')||_0x1228d2===_0x4a9a88('0x3a')||_0x1228d2===_0x4a9a88('0xb')||_0x1228d2===_0x4a9a88('0x76')||_0x1228d2==='rtpaudioqosjitter'||_0x1228d2===_0x4a9a88('0x2e')||_0x1228d2===_0x4a9a88('0x46')||_0x1228d2==='rtpaudioqoslossbridged'||_0x1228d2===_0x4a9a88('0x45')||_0x1228d2===_0x4a9a88('0x3a')||_0x1228d2===_0x4a9a88('0x9')||_0x1228d2==='bridgepvtcallid'||_0x1228d2===_0x4a9a88('0x6b')||_0x1228d2===_0x4a9a88('0x78'))return![];return!![];},exports[_0x92f61f('0x3e')]=function(_0x13551c,_0x3bb538){const _0x4948db=_0x92f61f;_0x3bb538<=0x0&&(_0x3bb538=0x1);const _0x5d5e68=new RegExp(_0x4948db('0x42')+_0x3bb538+'}$'),_0x3c02b3=Math['pow'](0xa,_0x3bb538-0x1),_0x454fcb=Math[_0x4948db('0x12')](0xa,_0x3bb538)-0x1;return util[_0x4948db('0x7f')]('%s',_[_0x4948db('0x66')](_0x13551c,_0x5d5e68,_[_0x4948db('0x8')](_0x3c02b3,_0x454fcb)));},exports[_0x92f61f('0x50')]=function(_0x392d02){const _0x2a1c3a=_0x92f61f,_0x1f1a03=_0x392d02[_0x2a1c3a('0x11')](/"(.*?)"/);return _0x1f1a03?_0x1f1a03[0x1]:_0x392d02;},exports['extractCalleridNumber']=function(_0x1c973e){const _0x502673=_0x92f61f,_0x491c67=_0x1c973e[_0x502673('0x11')](/<(.*?)>/);return _0x491c67?_0x491c67[0x1]:_0x1c973e;}; \ No newline at end of file +const a1090_0x461a=['dialer','logLookAgent','toUpper','xmd-dialchannel','lodash','calleridnum','bridgepeer','addVariables','idContact','message','xmd-listid','\x22\x22\x20<>','getCallerIdRandom','rtpaudioqosjitter','state','xmd-callerid','membername','extractCalleridNumber','callbackat','_XCALLY_MIXMONITOR_FORMAT','rtpaudioqosrtt','lastevent','getDiff','tags','\x22%s\x22\x20<%s>','isEmpty','filterKey','dialPreviewUrl','[decrementTalkink]\x20object\x20talking\x20is\x20negative','info','error','VoiceQueueId','ListId','queue','isNil','agiIp','responsetime','updatedAt','loggerCatch','toLower','createdAt','dialOriginateTimeout','add','rtpaudioqos','originatecalleridname','active','U(xcally-mixmonitor-context)','Global','seconds','[updateOriginated]\x20object\x20originated\x20is\x20negative','interface','status','xmd-dialid','\x22agi://%s/square,%s\x22','logCustomer','cloneAction','variablesAction','isUndefined','xcally-motion-preview','channelAgent','scheduledAt','decrementTalkink','undefined','countnosuchnumberretry','Queue','uniqueid','milliseconds','random','loggerError','talktime','countglobal','logger2','createBody','format','RECALL','xmd-voicequeueid','xmd-agiafter','bridgepvtcallid','starttime','Failure','monitor_format','callback','updateOriginated','dialQueueProject','YYYY-MM-DD\x20HH:mm:ss','rtpaudioqosbridged','_XCALLY_MIXMONITOR_UNIQUEID','logAgent','NONE','minutes','xmd-contactid','util','ContactId','%s%s','IsNotLoggedIn','scheduledat','../../../../config/logger','statedesc','string','match','originated','agentReadyId','countbusyretry','isFailure','buildObj','xmd-phone','rtpaudioqosjitterbridged','answertime','campaigntype','rtpaudioqoslossbridged','pTalking','xmd-dialoptions','Contact','callbackuniqueid','endtime','rtpaudioqosloss','getCallerId','ringtime','clone','from-sip','type','name','dialQueueProject2','inspect','rtpaudioqosrttbridged','xmd-dialurl','buildAcw','dialAnswer','countcongestionretry','calleridname','UserId','originatecalleridnum','originate','diff','xmd-dialtimeout','[decrementTalkink]\x20is\x20null\x20or\x20undefined','toLowerVariables','timeout'];(function(_0x1d2f5e,_0x461af6){const _0x1dcfd8=function(_0x478b52){while(--_0x478b52){_0x1d2f5e['push'](_0x1d2f5e['shift']());}};_0x1dcfd8(++_0x461af6);}(a1090_0x461a,0x9c));const a1090_0x1dcf=function(_0x1d2f5e,_0x461af6){_0x1d2f5e=_0x1d2f5e-0x0;let _0x1dcfd8=a1090_0x461a[_0x1d2f5e];return _0x1dcfd8;};const _0x438d34=a1090_0x1dcf;'use strict';const util=require(_0x438d34('0x49')),_=require(_0x438d34('0x7c')),moment=require('moment'),logger=require(_0x438d34('0x4e'))('preview'),{getConfigService}=require('../../../../config/config.service');function getSeconds(_0x478b52,_0x18b568){const _0x34d6d8=_0x438d34,_0x15d214=moment(_0x478b52)['milliseconds'](0x0),_0x1d6d05=moment(_0x18b568)[_0x34d6d8('0x30')](0x0);return _0x15d214[_0x34d6d8('0x73')](_0x1d6d05,_0x34d6d8('0x1e'));}exports[_0x438d34('0x14')]=function(_0x78d557){return function(_0x562cf1){const _0x292f7f=a1090_0x1dcf;logger[_0x292f7f('0xc')](_0x78d557,util['inspect'](_0x562cf1,{'showHidden':![],'depth':null}));};},exports['logger']=function(_0x197969,_0x30c456){const _0x206fa7=_0x438d34;logger['info'](_0x197969,util[_0x206fa7('0x69')](_0x30c456,{'showHidden':![],'depth':null}));},exports[_0x438d34('0x32')]=function(_0x3658ec,_0x53ac27){const _0x40ec0c=_0x438d34;logger[_0x40ec0c('0xc')](_0x3658ec,util[_0x40ec0c('0x69')](_0x53ac27,{'showHidden':![],'depth':null}));},exports[_0x438d34('0x35')]=function(_0x267684){return function(_0x17ea05){const _0x57e27a=a1090_0x1dcf;logger[_0x57e27a('0xb')](_0x267684,util[_0x57e27a('0x69')](_0x17ea05,{'showHidden':![],'depth':null}));};},exports[_0x438d34('0x81')]=function(_0x3673a5,_0xa51b47,_0x23e412){return{'message':_0x3673a5,'unlock':_0xa51b47,'active':_0x23e412};},exports[_0x438d34('0x62')]=function(_0x4cb7f5,_0x5df313,_0x5e2ede){const _0x1add13=_0x438d34;if(!_[_0x1add13('0x27')](_0x5e2ede)&&_0x1add13('0x50')===typeof _0x5e2ede&&!_[_0x1add13('0x7')](_0x5e2ede)){if(!_[_0x1add13('0x27')](_0x5df313)&&'string'===typeof _0x5df313&&!_[_0x1add13('0x7')](_0x5df313))return util[_0x1add13('0x37')](_0x1add13('0x6'),_0x5df313,_0x5e2ede);return util[_0x1add13('0x37')](_0x1add13('0x6'),_0x5e2ede,_0x5e2ede);}if(!_[_0x1add13('0x27')](_0x4cb7f5)&&_0x1add13('0x50')===typeof _0x4cb7f5&&!_[_0x1add13('0x7')](_0x4cb7f5))return _0x4cb7f5;return _0x1add13('0x83');},exports['isActive']=function(_0x20c4ae){const _0x2ff296=_0x438d34;if(_[_0x2ff296('0x10')](_0x20c4ae))return![];return _0x20c4ae;},exports[_0x438d34('0x7f')]=function(_0x44f0bf,_0x48042e,_0x317325,_0x43d97d,_0x2f7bac,_0x275068){const _0x4e5cf9=_0x438d34,_0x3fb48d=getConfigService(),_0x49127e={'XMD-QUEUE':_0x48042e['Queue']?_0x48042e[_0x4e5cf9('0x2e')][_0x4e5cf9('0x67')]:'','XMD-CALLERID':_0x43d97d,'XMD-CALLERID-PREVIEW':_0x275068?util[_0x4e5cf9('0x37')](_0x4e5cf9('0x6'),_0x275068[_0x4e5cf9('0x6f')],_0x275068[_0x4e5cf9('0x7d')]):_0x43d97d,'XMD-DIALID':_0x2f7bac,'XMD-CONTACTID':_0x48042e[_0x4e5cf9('0x4a')],'XMD-CDRTYPE':_0x4e5cf9('0x78'),'CALLERID(all)':_0x43d97d,'XMD-VOICEQUEUEID':_0x48042e[_0x4e5cf9('0xd')],'XMD-DIALCHANNEL':_0x317325,'XMD-DIALTIMEOUT':_0x44f0bf[_0x4e5cf9('0x17')]||0x1e,'XMD-DIALOPTIONS':util[_0x4e5cf9('0x37')]('\x22rtTxX%s%s\x22',_0x44f0bf['dialQueueProject2']?'g':'',_['isEmpty'](_0x44f0bf[_0x4e5cf9('0x3e')])?'':_0x4e5cf9('0x1c')),'XMD-DIALURL':_0x44f0bf[_0x4e5cf9('0x9')]||'','XMD-AGI':_0x44f0bf[_0x4e5cf9('0x41')]?util[_0x4e5cf9('0x37')]('\x22agi://%s/square,%s\x22',_0x3fb48d[_0x4e5cf9('0x11')],_0x44f0bf[_0x4e5cf9('0x41')]):_0x4e5cf9('0x46'),'XMD-AGIAFTER':_0x44f0bf[_0x4e5cf9('0x68')]?util[_0x4e5cf9('0x37')](_0x4e5cf9('0x23'),_0x3fb48d[_0x4e5cf9('0x11')],_0x44f0bf['dialQueueProject2']):_0x4e5cf9('0x46'),'XMD-ORIGINATECALLERIDNUM':_0x275068?_0x275068[_0x4e5cf9('0x71')]:'','XMD-ORIGINATECALLERIDNAME':_0x275068?_0x275068[_0x4e5cf9('0x1a')]:'','XMD-DESTINATION':_0x4e5cf9('0x28')};!_[_0x4e5cf9('0x7')](_0x44f0bf[_0x4e5cf9('0x3e')])&&(_0x49127e[util[_0x4e5cf9('0x37')]('%s',_0x4e5cf9('0x1'))]=_0x44f0bf['monitor_format'],_0x49127e[util[_0x4e5cf9('0x37')]('%s',_0x4e5cf9('0x44'))]=_0x2f7bac);if(_0x48042e&&_0x48042e[_0x4e5cf9('0x5e')])for(const _0xf10f1b in _0x48042e['Contact']){typeof _0x48042e[_0x4e5cf9('0x5e')][_0xf10f1b]!==_0x4e5cf9('0x2c')&&(!_[_0x4e5cf9('0x10')](_0x48042e[_0x4e5cf9('0x5e')][_0xf10f1b])&&_0xf10f1b!=='id'&&_0xf10f1b!==_0x4e5cf9('0x5')&&_0xf10f1b!==_0x4e5cf9('0x16')&&_0xf10f1b!==_0x4e5cf9('0x13')&&(_0x49127e[util[_0x4e5cf9('0x37')](_0x4e5cf9('0x4b'),'XMD-',_[_0x4e5cf9('0x7a')](_0xf10f1b))]=_0x48042e[_0x4e5cf9('0x5e')][_0xf10f1b]));}return _0x49127e;},exports[_0x438d34('0x76')]=function(_0x404eb0){const _0x47158b=_0x438d34,_0x28ef36={};for(const _0x4a2f93 in _0x404eb0){typeof _0x404eb0[_0x4a2f93]!==_0x47158b('0x2c')&&(_0x28ef36[util[_0x47158b('0x37')]('%s',_[_0x47158b('0x15')](_0x4a2f93))]=_0x404eb0[_0x4a2f93]);}return{'variables':_0x28ef36};},exports[_0x438d34('0x40')]=function(_0x41f432,_0x2754d4){const _0x1b2949=_0x438d34;!_[_0x1b2949('0x10')](_0x41f432)?typeof _0x41f432[_0x1b2949('0x52')]!==_0x1b2949('0x2c')&&(_0x41f432[_0x1b2949('0x52')]>0x0?_0x41f432['originated']-=0x1:logger[_0x1b2949('0xc')](_0x1b2949('0x1f'),_0x2754d4)):logger[_0x1b2949('0xc')]('[updateOriginated]\x20is\x20null\x20or\x20undefined',_0x2754d4);},exports['logBlacklist']=function(_0x3072af){const _0x8e5cbb=_0x438d34,_0x389751=moment()['format'](_0x8e5cbb('0x42'));_0x3072af[_0x8e5cbb('0x86')]=0xd,_0x3072af[_0x8e5cbb('0x4f')]='Blacklist',_0x3072af[_0x8e5cbb('0x3c')]=_0x389751,_0x3072af['responsetime']=_0x389751,_0x3072af[_0x8e5cbb('0x60')]=_0x389751;},exports[_0x438d34('0x45')]=function(_0x353d06,_0x1c34f4,_0xe2be8e){const _0x531b40=_0x438d34,_0xcbf0cd=moment()[_0x531b40('0x37')](_0x531b40('0x42'));_0x353d06[_0x531b40('0x86')]=_0x1c34f4,_0x353d06[_0x531b40('0x4f')]=_0xe2be8e,_0x353d06[_0x531b40('0x12')]=_0xcbf0cd,_0x353d06[_0x531b40('0x63')]=getSeconds(_0x353d06['responsetime'],_0x353d06['starttime']);},exports[_0x438d34('0x79')]=function(_0x521474,_0xa20689,_0x3bfeba){const _0x17ebb4=_0x438d34;_0x521474[_0x17ebb4('0x88')]=_0xa20689,_0x521474['UserId']=_0x3bfeba;},exports[_0x438d34('0x24')]=function(_0x4e9f7b,_0x337f9d,_0x453dce){const _0x750c8b=_0x438d34,_0xb900e7=moment()['format']('YYYY-MM-DD\x20HH:mm:ss');_0x4e9f7b['state']=_0x337f9d,_0x4e9f7b[_0x750c8b('0x4f')]=_0x453dce,_0x4e9f7b['responsetime']=_0x4e9f7b[_0x750c8b('0x12')]?_0x4e9f7b['responsetime']:_0xb900e7,_0x4e9f7b[_0x750c8b('0x60')]=_0x4e9f7b[_0x750c8b('0x60')]?_0x4e9f7b['endtime']:_0xb900e7,_0x4e9f7b[_0x750c8b('0x63')]=getSeconds(_0x4e9f7b['responsetime']||0x0,_0x4e9f7b[_0x750c8b('0x3c')]||0x0),_0x4e9f7b[_0x750c8b('0x33')]=_0x4e9f7b[_0x750c8b('0x59')]?getSeconds(_0x4e9f7b['endtime'],_0x4e9f7b[_0x750c8b('0x59')]):0x0;},exports[_0x438d34('0x55')]=function(_0x31574f){const _0x43d703=_0x438d34;return _0x31574f===_0x43d703('0x3d');},exports[_0x438d34('0x26')]=function(_0x1cf3b4,_0x602e84,_0x56434e,_0x41ef31,_0x40d922){const _0xa50727=_0x438d34;let _0x1ef506=_0x41ef31?_0xa50727('0x38'):_0x1cf3b4[_0xa50727('0x6f')];return _0x1ef506=_0x40d922?'BOOKED':_0x1ef506,{'actionid':_0x1cf3b4['uniqueid'],'action':_0xa50727('0x72'),'channel':_0x1cf3b4[_0xa50727('0x29')],'callerid':util['format']('\x22%s\x22\x20<%s>',_0x1ef506,_0x1cf3b4[_0xa50727('0x7d')]),'Exten':_0xa50727('0x28'),'Context':_0xa50727('0x65'),'Priority':'1','variable':_0x56434e,'timeout':(_0x602e84[_0xa50727('0x77')]||0x1e)*0x3e8,'async':!![],'channelid':_0x1cf3b4['uniqueid']};},exports['totalGlobal']=function(_0x4a61d7){const _0x5ee957=_0x438d34;return _0x4a61d7[_0x5ee957('0x54')]+_0x4a61d7[_0x5ee957('0x6e')]+_0x4a61d7['countnoanswerretry']+_0x4a61d7['countagentrejectretry']+_0x4a61d7[_0x5ee957('0x2d')];},exports[_0x438d34('0x25')]=function(_0x4f8ed3){const _0x5a5441=_0x438d34,_0x103e39=_[_0x5a5441('0x64')](_0x4f8ed3);return _0x103e39['state']=0xf,_0x103e39[_0x5a5441('0x4f')]=_0x5a5441('0x1d'),_0x103e39;},exports[_0x438d34('0x2a')]=function(_0x3e64ac,_0x315df0,_0x53a01d){const _0x446564=_0x438d34,_0x433ec0={};return _0x433ec0[_0x315df0]=_0x3e64ac[_0x315df0],_0x433ec0['active']=![],_0x433ec0[_0x446564('0x4d')]=moment()[_0x446564('0x18')](_0x53a01d,_0x446564('0x47'))[_0x446564('0x37')](_0x446564('0x42')),_0x433ec0[_0x446564('0x4a')]=_0x3e64ac[_0x446564('0x4a')],_0x433ec0[_0x446564('0xe')]=_0x3e64ac[_0x446564('0xe')],_0x433ec0[_0x446564('0xd')]=_0x3e64ac[_0x446564('0xd')]||undefined,_0x433ec0;},exports[_0x438d34('0x2b')]=function(_0xb45372,_0xadb346){const _0x5c1007=_0x438d34;!_['isNil'](_0xb45372)?_0xb45372[_0x5c1007('0x5c')]>0x0?_0xb45372[_0x5c1007('0x5c')]-=0x1:logger[_0x5c1007('0xc')](_0xadb346,_0x5c1007('0xa')):logger[_0x5c1007('0xc')](_0xadb346,_0x5c1007('0x75'));},exports[_0x438d34('0x4c')]=function(_0x540c51){if(_0x540c51<=0x0)return!![];return![];},exports[_0x438d34('0x56')]=function(_0x290a3b,_0x8bac27){const _0x3dfe7f=_0x438d34;return _0x290a3b[_0x3dfe7f('0x3')]=_0x8bac27,_0x290a3b[_0x3dfe7f('0x67')]=_0x290a3b[_0x3dfe7f('0xf')],_0x290a3b[_0x3dfe7f('0x20')]=_0x290a3b[_0x3dfe7f('0x29')],_0x290a3b;},exports[_0x438d34('0x6c')]=function(_0x398f46){const _0x27b747=_0x438d34,_0x237ad8={};return _0x237ad8['queue']=_0x398f46[_0x27b747('0xf')],_0x237ad8[_0x27b747('0x20')]=_0x398f46[_0x27b747('0x29')],_0x237ad8[_0x27b747('0x2f')]=_0x398f46[_0x27b747('0x2f')],_0x237ad8;},exports[_0x438d34('0x53')]=function(_0x5be2f0){const _0x337643=_0x438d34,_0x5c48fc=[];for(const _0x4d868d in _0x5be2f0){typeof _0x5be2f0[_0x4d868d]!=='undefined'&&(!_['isNil'](_0x5be2f0[_0x4d868d])&&_0x5be2f0[_0x4d868d][_0x337643('0x86')]==='not_inuse'&&_0x5be2f0[_0x4d868d][_0x337643('0x21')]==='reachable'&&_0x5c48fc['push'](_0x5be2f0[_0x4d868d]['id']));}return _0x5c48fc;},exports[_0x438d34('0x4')]=function(_0x49bd29){const _0x4c91b6=_0x438d34,_0x5db891=moment()[_0x4c91b6('0x30')](0x0),_0x47a17a=moment(_0x49bd29)[_0x4c91b6('0x30')](0x0);return _0x5db891['diff'](_0x47a17a,_0x4c91b6('0x1e'));},exports[_0x438d34('0x36')]=function(_0x5ea3d5){const _0x53aedc=_0x438d34;return{'active':![],'recallme':![],'UserId':null,'ContactId':_0x5ea3d5[_0x53aedc('0x4a')],'ListId':_0x5ea3d5[_0x53aedc('0xe')],'VoiceQueueId':_0x5ea3d5[_0x53aedc('0xd')]||undefined,'CampaignId':_0x5ea3d5['CampaignId']||undefined};},exports[_0x438d34('0x8')]=function(_0x236a2d){const _0x3e7271=_0x438d34;if(_0x236a2d===_0x3e7271('0x2f')||_0x236a2d===_0x3e7271('0x80')||_0x236a2d===_0x3e7271('0xf')||_0x236a2d===_0x3e7271('0x66')||_0x236a2d===_0x3e7271('0x5a')||_0x236a2d===_0x3e7271('0x6d')||_0x236a2d==='membername'||_0x236a2d===_0x3e7271('0x29')||_0x236a2d===_0x3e7271('0x6f')||_0x236a2d===_0x3e7271('0x1b')||_0x236a2d===_0x3e7271('0x7d')||_0x236a2d===_0x3e7271('0x4d')||_0x236a2d===_0x3e7271('0x54')||_0x236a2d===_0x3e7271('0x6e')||_0x236a2d==='countnoanswerretry'||_0x236a2d===_0x3e7271('0x34')||_0x236a2d===_0x3e7271('0x3f')||_0x236a2d===_0x3e7271('0x5f')||_0x236a2d===_0x3e7271('0x0')||_0x236a2d==='recallme'||_0x236a2d===_0x3e7271('0x4a')||_0x236a2d===_0x3e7271('0xe')||_0x236a2d===_0x3e7271('0x70')||_0x236a2d===_0x3e7271('0xd')||_0x236a2d==='sipcallid'||_0x236a2d===_0x3e7271('0x39')||_0x236a2d==='xmd-queue'||_0x236a2d===_0x3e7271('0x57')||_0x236a2d===_0x3e7271('0x82')||_0x236a2d===_0x3e7271('0x6b')||_0x236a2d===_0x3e7271('0x74')||_0x236a2d===_0x3e7271('0x5d')||_0x236a2d===_0x3e7271('0x22')||_0x236a2d===_0x3e7271('0x7b')||_0x236a2d===_0x3e7271('0x48')||_0x236a2d==='xmd-cdrtype'||_0x236a2d===_0x3e7271('0x87')||_0x236a2d===_0x3e7271('0x3a')||_0x236a2d==='xmd-agi'||_0x236a2d===_0x3e7271('0x19')||_0x236a2d===_0x3e7271('0x43')||_0x236a2d===_0x3e7271('0x85')||_0x236a2d===_0x3e7271('0x58')||_0x236a2d===_0x3e7271('0x61')||_0x236a2d==='rtpaudioqoslossbridged'||_0x236a2d===_0x3e7271('0x2')||_0x236a2d===_0x3e7271('0x6a')||_0x236a2d==='rtpaudioqos'||_0x236a2d===_0x3e7271('0x43')||_0x236a2d===_0x3e7271('0x85')||_0x236a2d===_0x3e7271('0x58')||_0x236a2d===_0x3e7271('0x61')||_0x236a2d===_0x3e7271('0x5b')||_0x236a2d===_0x3e7271('0x2')||_0x236a2d===_0x3e7271('0x6a')||_0x236a2d===_0x3e7271('0x7e')||_0x236a2d===_0x3e7271('0x3b')||_0x236a2d==='state'||_0x236a2d===_0x3e7271('0x4f'))return![];return!![];},exports[_0x438d34('0x84')]=function(_0x184999,_0x2a1941){const _0x9bf866=_0x438d34;_0x2a1941<=0x0&&(_0x2a1941=0x1);const _0x12f49d=new RegExp('\x5cw{0,'+_0x2a1941+'}$'),_0x464ada=Math['pow'](0xa,_0x2a1941-0x1),_0x47226e=Math['pow'](0xa,_0x2a1941)-0x1;return util[_0x9bf866('0x37')]('%s',_['replace'](_0x184999,_0x12f49d,_[_0x9bf866('0x31')](_0x464ada,_0x47226e)));},exports['extractCalleridName']=function(_0x2153fc){const _0x4acb1b=_0x438d34,_0x16f9b1=_0x2153fc[_0x4acb1b('0x51')](/"(.*?)"/);return _0x16f9b1?_0x16f9b1[0x1]:_0x2153fc;},exports[_0x438d34('0x89')]=function(_0x5731c5){const _0x1bc4c3=_0x438d34,_0x5bb437=_0x5731c5[_0x1bc4c3('0x51')](/<(.*?)>/);return _0x5bb437?_0x5bb437[0x1]:_0x5731c5;}; \ No newline at end of file diff --git a/server/services/ami/properties.js b/server/services/ami/properties.js index 0d6d72d..f39d26d 100644 --- a/server/services/ami/properties.js +++ b/server/services/ami/properties.js @@ -1 +1 @@ -var a1091_0x1f25=['voicequeuechannelredirect','queueadd','number','string','reload','voicequeuechannelhangup','boolean'];(function(_0x38e6cd,_0x1f2547){var _0x562156=function(_0x3df904){while(--_0x3df904){_0x38e6cd['push'](_0x38e6cd['shift']());}};_0x562156(++_0x1f2547);}(a1091_0x1f25,0x97));var a1091_0x5621=function(_0x38e6cd,_0x1f2547){_0x38e6cd=_0x38e6cd-0x0;var _0x562156=a1091_0x1f25[_0x38e6cd];return _0x562156;};var _0x4ce394=a1091_0x5621;'use strict';exports[_0x4ce394('0x4')]={'queue':{'type':_0x4ce394('0x6'),'required':!![]},'interface':{'type':_0x4ce394('0x6'),'required':!![]},'membername':{'type':_0x4ce394('0x6'),'required':!![]},'penalty':{'type':_0x4ce394('0x5'),'required':![]},'paused':{'type':_0x4ce394('0x2'),'required':![]}},exports['queueremove']={'queue':{'type':_0x4ce394('0x6'),'required':!![]},'interface':{'type':_0x4ce394('0x6'),'required':!![]}},exports['queuepause']={'interface':{'type':_0x4ce394('0x6'),'required':!![]},'paused':{'type':_0x4ce394('0x2')},'reason':{'type':'string','required':![]}},exports[_0x4ce394('0x0')]={'module':{'type':_0x4ce394('0x6'),'required':![]}},exports['voicequeuechannel']={'uniqueid':{'type':_0x4ce394('0x6'),'required':!![]}},exports['voicechannel']={'uniqueid':{'type':_0x4ce394('0x6'),'required':!![]},'filename':{'type':_0x4ce394('0x6')},'format':{'type':'string'},'mixmonitorid':{'type':'string'}},exports[_0x4ce394('0x1')]={'uniqueid':{'type':_0x4ce394('0x6'),'required':!![]}},exports[_0x4ce394('0x3')]={'uniqueid':{'type':_0x4ce394('0x6'),'required':!![]},'exten':{'type':_0x4ce394('0x6'),'required':!![]},'context':{'type':_0x4ce394('0x6')}}; \ No newline at end of file +var a1091_0x1031=['number','reload','queueremove','voicequeuechannelhangup','boolean','voicechannel','voicequeuechannelredirect','voicequeuechannel','queueadd','queuepause','string'];(function(_0x5bd8f2,_0x103153){var _0x3d6d27=function(_0x2207d4){while(--_0x2207d4){_0x5bd8f2['push'](_0x5bd8f2['shift']());}};_0x3d6d27(++_0x103153);}(a1091_0x1031,0x126));var a1091_0x3d6d=function(_0x5bd8f2,_0x103153){_0x5bd8f2=_0x5bd8f2-0x0;var _0x3d6d27=a1091_0x1031[_0x5bd8f2];return _0x3d6d27;};var _0x4271dd=a1091_0x3d6d;'use strict';exports[_0x4271dd('0x0')]={'queue':{'type':_0x4271dd('0x2'),'required':!![]},'interface':{'type':_0x4271dd('0x2'),'required':!![]},'membername':{'type':_0x4271dd('0x2'),'required':!![]},'penalty':{'type':_0x4271dd('0x3'),'required':![]},'paused':{'type':_0x4271dd('0x7'),'required':![]}},exports[_0x4271dd('0x5')]={'queue':{'type':_0x4271dd('0x2'),'required':!![]},'interface':{'type':_0x4271dd('0x2'),'required':!![]}},exports[_0x4271dd('0x1')]={'interface':{'type':'string','required':!![]},'paused':{'type':_0x4271dd('0x7')},'reason':{'type':'string','required':![]}},exports[_0x4271dd('0x4')]={'module':{'type':_0x4271dd('0x2'),'required':![]}},exports[_0x4271dd('0xa')]={'uniqueid':{'type':_0x4271dd('0x2'),'required':!![]}},exports[_0x4271dd('0x8')]={'uniqueid':{'type':'string','required':!![]},'filename':{'type':_0x4271dd('0x2')},'format':{'type':_0x4271dd('0x2')},'mixmonitorid':{'type':'string'}},exports[_0x4271dd('0x6')]={'uniqueid':{'type':_0x4271dd('0x2'),'required':!![]}},exports[_0x4271dd('0x9')]={'uniqueid':{'type':'string','required':!![]},'exten':{'type':_0x4271dd('0x2'),'required':!![]},'context':{'type':_0x4271dd('0x2')}}; \ No newline at end of file diff --git a/server/services/ami/realtime/index.js b/server/services/ami/realtime/index.js index b4b28e2..3ceba61 100644 --- a/server/services/ami/realtime/index.js +++ b/server/services/ami/realtime/index.js @@ -1 +1 @@ -const a1092_0x5705=['queuecallercompleteAt','interface','outboundRejectCallsDay','voiceQueues','outboundDropCallsDayTimeout','isNil','servicenowAccounts','sumBillable','queuecallerexit','../model/telephone','timers','queuecallerabandonAt','moment','../model/freshsalesAccount','templates','undefined','initDynamics365Accounts','initServicenowAccounts','initZendeskAccounts','queuecallercomplete','isUndefined','isEmpty','name','initTriggers','seconds','vtigerAccounts','outboundReCallsDay','outboundCongestionCallsDay','prototype','deskAccounts','initDeskAccounts','initTemplates','initZohoAccounts','faxAccounts','triggers','unmanaged','telephones','../model/salesforceAccount','freshsalesAccounts','outboundUnknownCallsDay','sumHoldTime','exports','agents','SIP/%s','mapKeys','sugarcrmAccounts','../model/trunk','campaigns','outboundBusyCallsDay','salesforceAccounts','outboundBlacklistCallsDay','queuecallerabandon','initCampaigns','../model/sugarcrmAccount','mergeFromDatabase','initVtigerAccounts','length','uniqueid','../model/freshdeskAccount','outboundChannels','initVoiceCallReports','../model/faxAccount','queueChannels','dynamics365Accounts','../model/deskAccount','trunks','../model/voiceExtension','format','outboundDropCallsDayCallersExit','zendeskAccounts','queuecallerleaveAt','merge','billableseconds','../model/trigger','../model/servicenowAccount','answered','voiceExtensions','dialQueueProject','../model/voiceQueue','initSalesforceAccounts','../model/campaign','../model/dynamics365Account','outboundAnswerAgiCallsDay','queuecallerjoinAt','total','initSugarcrmAccounts','initFreshdeskAccounts','initTelephones','../model/zohoAccount','zohoAccounts','util','diff','outboundOriginateFailureCallsDay','ivrAnswerCallsDay','initVoiceQueues','channels','initVoiceQueueHopperHistory','sumDuration','outbound','freshdeskAccounts'];(function(_0x26b315,_0x570520){const _0x3d6aa0=function(_0x18d0e5){while(--_0x18d0e5){_0x26b315['push'](_0x26b315['shift']());}};_0x3d6aa0(++_0x570520);}(a1092_0x5705,0x1dc));const a1092_0x3d6a=function(_0x26b315,_0x570520){_0x26b315=_0x26b315-0x0;let _0x3d6aa0=a1092_0x5705[_0x26b315];return _0x3d6aa0;};const _0xc498d=a1092_0x3d6a;'use strict';const util=require(_0xc498d('0xe')),_=require('lodash'),moment=require(_0xc498d('0x24')),Agent=require('../model/agent'),Telephone=require(_0xc498d('0x21')),Trunk=require(_0xc498d('0x46')),VoiceQueue=require(_0xc498d('0x2')),Trigger=require(_0xc498d('0x61')),Template=require('../model/template'),Campaign=require(_0xc498d('0x4')),VoiceExtension=require(_0xc498d('0x5a')),ZendeskAccount=require('../model/zendeskAccount'),SalesforceAccount=require(_0xc498d('0x3d')),FreshdeskAccount=require(_0xc498d('0x52')),SugarcrmAccount=require(_0xc498d('0x4d')),ZohoAccount=require(_0xc498d('0xc')),DeskAccount=require(_0xc498d('0x58')),VtigerAccount=require('../model/vtigerAccount'),ServicenowAccount=require(_0xc498d('0x62')),Dynamics365Account=require(_0xc498d('0x5')),FreshsalesAccount=require(_0xc498d('0x25')),FaxAccount=require(_0xc498d('0x55')),Realtime=function(){const _0xacc11b=_0xc498d;this[_0xacc11b('0x42')]={},this[_0xacc11b('0x3c')]={},this['trunks']={},this[_0xacc11b('0x1b')]={},this[_0xacc11b('0x3a')]={},this[_0xacc11b('0x47')]={},this[_0xacc11b('0x26')]={},this[_0xacc11b('0x16')]={'total':0x0,'answered':0x0,'sumHoldTime':0x0,'sumDuration':0x0,'sumBillable':0x0},this[_0xacc11b('0x0')]={},this[_0xacc11b('0x13')]={},this[_0xacc11b('0x56')]={},this[_0xacc11b('0x53')]={},this[_0xacc11b('0x22')]={},this[_0xacc11b('0x5d')]={},this[_0xacc11b('0x49')]={},this['sugarcrmAccounts']={},this[_0xacc11b('0x17')]={},this[_0xacc11b('0xd')]={},this[_0xacc11b('0x35')]={},this[_0xacc11b('0x31')]={},this[_0xacc11b('0x1e')]={},this['dynamics365Accounts']={},this[_0xacc11b('0x3e')]={},this[_0xacc11b('0x39')]={};};function freeIsNotKey(_0x18d0e5,_0x4703db,_0x12989e){const _0x32b186=_0xc498d,_0x420976=_[_0x32b186('0x44')](_0x18d0e5,function(_0x5a4c55){return _0x5a4c55[_0x12989e];});for(const _0x415b46 in _0x4703db){typeof _0x4703db[_0x415b46]!=='undefined'&&(!_0x420976[_0x415b46]&&delete _0x4703db[_0x415b46]);}}function freeIsNotKeySip(_0x5480d0,_0x3162e0){const _0x5a4261=_0xc498d,_0x2cf759=_[_0x5a4261('0x44')](_0x5480d0,function(_0x44310f){const _0x3d0601=_0x5a4261;return util[_0x3d0601('0x5b')](_0x3d0601('0x43'),_0x44310f[_0x3d0601('0x2e')]);});for(const _0xa4139b in _0x3162e0){typeof _0x3162e0[_0xa4139b]!==_0x5a4261('0x27')&&(!_0x2cf759[_0xa4139b]&&delete _0x3162e0[_0xa4139b]);}}function freeIsNotKeyAgent(_0x52d71f,_0x1d645a){const _0x492b16=_0xc498d,_0xb98e44=_[_0x492b16('0x44')](_0x52d71f,function(_0x6cc96e){const _0x52c189=_0x492b16,_0xc77d4c=_[_0x52c189('0x1d')](_0x6cc96e[_0x52c189('0x19')])?util[_0x52c189('0x5b')](_0x52c189('0x43'),_0x6cc96e['name']):_0x6cc96e[_0x52c189('0x19')];return _0xc77d4c;});for(const _0x539eef in _0x1d645a){typeof _0x1d645a[_0x539eef]!==_0x492b16('0x27')&&(!_0xb98e44[_0x539eef]&&delete _0x1d645a[_0x539eef]);}}function clearVoiceCallReports(_0x1bab5b){const _0x4c8b2d=_0xc498d;_0x1bab5b[_0x4c8b2d('0x8')]=0x0,_0x1bab5b[_0x4c8b2d('0x63')]=0x0,_0x1bab5b['sumHoldTime']=0x0,_0x1bab5b[_0x4c8b2d('0x15')]=0x0,_0x1bab5b[_0x4c8b2d('0x1f')]=0x0;}function clearCampaigns(_0x7f73c5){const _0x5e0291=_0xc498d;if(!_[_0x5e0291('0x2d')](_0x7f73c5))for(const _0x238bb5 in _0x7f73c5){typeof _0x7f73c5[_0x238bb5]!==_0x5e0291('0x27')&&(_0x7f73c5[_0x238bb5]['ivrTotalCallsDays']=0x0,_0x7f73c5[_0x238bb5][_0x5e0291('0x11')]=0x0);}}function clearVoiceQueues(_0x185838){const _0x132507=_0xc498d;if(!_[_0x132507('0x2d')](_0x185838))for(const _0x11f8fa in _0x185838){typeof _0x185838[_0x11f8fa]!==_0x132507('0x27')&&(_0x185838[_0x11f8fa]['total']=0x0,_0x185838[_0x11f8fa]['answered']=0x0,_0x185838[_0x11f8fa][_0x132507('0x3b')]=0x0,_0x185838[_0x11f8fa]['abandoned']=0x0,_0x185838[_0x11f8fa][_0x132507('0x40')]=0x0,_0x185838[_0x11f8fa][_0x132507('0x15')]=0x0,_0x185838[_0x11f8fa]['sumBillable']=0x0,_0x185838[_0x11f8fa][_0x132507('0x6')]=0x0,_0x185838[_0x11f8fa]['outboundNoAnswerCallsDay']=0x0,_0x185838[_0x11f8fa][_0x132507('0x48')]=0x0,_0x185838[_0x11f8fa][_0x132507('0x33')]=0x0,_0x185838[_0x11f8fa]['outboundNoSuchCallsDay']=0x0,_0x185838[_0x11f8fa][_0x132507('0x3f')]=0x0,_0x185838[_0x11f8fa][_0x132507('0x1c')]=0x0,_0x185838[_0x11f8fa][_0x132507('0x5c')]=0x0,_0x185838[_0x11f8fa][_0x132507('0x4a')]=0x0,_0x185838[_0x11f8fa][_0x132507('0x10')]=0x0,_0x185838[_0x11f8fa][_0x132507('0x1a')]=0x0,_0x185838[_0x11f8fa][_0x132507('0x32')]=0x0,_0x185838[_0x11f8fa][_0x132507('0x6')]=0x0,_0x185838[_0x11f8fa]['outboundAnswerCallsDay']=0x0,_0x185838[_0x11f8fa]['queueStatusComplete']=!![]);}}Realtime[_0xc498d('0x34')][_0xc498d('0x4e')]=function(_0x47a139,_0xbfa0f8){const _0x150049=_0xc498d;for(const _0x3a1be7 in _0xbfa0f8){typeof _0x47a139[_0x3a1be7]!==_0x150049('0x27')&&(_0x47a139[_0x3a1be7]=_0xbfa0f8[_0x3a1be7]);}},Realtime[_0xc498d('0x34')]['initAgents']=function(){const _0x15d766=this;return function(_0x2513b9){const _0xe2986=a1092_0x3d6a;if(_0x2513b9){freeIsNotKeyAgent(_0x2513b9,_0x15d766['agents']);for(let _0x1d5e37=0x0,_0x26564c={};_0x1d5e37<_0x2513b9['length'];_0x1d5e37+=0x1){_0x26564c=_0x2513b9[_0x1d5e37];const _0x2183e0=_[_0xe2986('0x1d')](_0x26564c['interface'])?util[_0xe2986('0x5b')](_0xe2986('0x43'),_0x26564c[_0xe2986('0x2e')]):_0x26564c[_0xe2986('0x19')];_[_0xe2986('0x2c')](_0x15d766['agents'][_0x2183e0])?_0x15d766[_0xe2986('0x42')][_0x2183e0]=new Agent(_0x26564c):_0x15d766[_0xe2986('0x4e')](_0x15d766[_0xe2986('0x42')][_0x2183e0],_0x26564c);}}return _0x15d766[_0xe2986('0x42')];};},Realtime[_0xc498d('0x34')][_0xc498d('0xb')]=function(){const _0xa97928=this;return function(_0x552024){const _0x41f9bf=a1092_0x3d6a;if(_0x552024){freeIsNotKeySip(_0x552024,_0xa97928[_0x41f9bf('0x3c')]);for(let _0x435706=0x0,_0x3df1f7={};_0x435706<_0x552024['length'];_0x435706+=0x1){_0x3df1f7=_0x552024[_0x435706],_['isUndefined'](_0xa97928['telephones'][util[_0x41f9bf('0x5b')]('SIP/%s',_0x3df1f7[_0x41f9bf('0x2e')])])?_0xa97928[_0x41f9bf('0x3c')][util['format']('SIP/%s',_0x3df1f7[_0x41f9bf('0x2e')])]=new Telephone(_0x3df1f7):_0xa97928[_0x41f9bf('0x4e')](_0xa97928[_0x41f9bf('0x3c')][util[_0x41f9bf('0x5b')](_0x41f9bf('0x43'),_0x3df1f7[_0x41f9bf('0x2e')])],_0x3df1f7);}}return _0xa97928[_0x41f9bf('0x3c')];};},Realtime[_0xc498d('0x34')]['initTrunks']=function(){const _0x105c80=this;return function(_0xf17f34){const _0x110dfa=a1092_0x3d6a;if(_0xf17f34){freeIsNotKeySip(_0xf17f34,_0x105c80['trunks']);for(let _0x279cd5=0x0,_0x27cc93={};_0x279cd5<_0xf17f34['length'];_0x279cd5+=0x1){_0x27cc93=_0xf17f34[_0x279cd5],_['isUndefined'](_0x105c80[_0x110dfa('0x59')][util[_0x110dfa('0x5b')](_0x110dfa('0x43'),_0x27cc93[_0x110dfa('0x2e')])])?_0x105c80[_0x110dfa('0x59')][util['format'](_0x110dfa('0x43'),_0x27cc93[_0x110dfa('0x2e')])]=new Trunk(_0x27cc93):_0x105c80['mergeFromDatabase'](_0x105c80[_0x110dfa('0x59')][util['format'](_0x110dfa('0x43'),_0x27cc93[_0x110dfa('0x2e')])],_0x27cc93);}}return _0x105c80['trunks'];};},Realtime[_0xc498d('0x34')][_0xc498d('0x12')]=function(){const _0x1c6fb4=this;return function(_0x1e8fbb){const _0x18c396=a1092_0x3d6a;if(_0x1e8fbb){freeIsNotKey(_0x1e8fbb,_0x1c6fb4[_0x18c396('0x1b')],_0x18c396('0x2e'));for(let _0x4adbe9=0x0,_0x4bf685={};_0x4adbe9<_0x1e8fbb[_0x18c396('0x50')];_0x4adbe9+=0x1){_0x4bf685=_0x1e8fbb[_0x4adbe9],_[_0x18c396('0x2c')](_0x1c6fb4['voiceQueues'][_0x4bf685[_0x18c396('0x2e')]])?_0x1c6fb4[_0x18c396('0x1b')][_0x4bf685[_0x18c396('0x2e')]]=new VoiceQueue(_0x4bf685):_0x1c6fb4[_0x18c396('0x4e')](_0x1c6fb4['voiceQueues'][_0x4bf685['name']],_0x4bf685);}}return _0x1c6fb4[_0x18c396('0x1b')];};},Realtime[_0xc498d('0x34')][_0xc498d('0x2f')]=function(){const _0x5ed8c8=this;return function(_0x3e52c3){const _0x486972=a1092_0x3d6a;if(_0x3e52c3){freeIsNotKey(_0x3e52c3,_0x5ed8c8[_0x486972('0x3a')],'id');for(let _0x52d72b=0x0,_0x1c4ad6={};_0x52d72b<_0x3e52c3['length'];_0x52d72b+=0x1){_0x1c4ad6=_0x3e52c3[_0x52d72b],_[_0x486972('0x2c')](_0x5ed8c8['triggers'][_0x1c4ad6['id']])?_0x5ed8c8[_0x486972('0x3a')][_0x1c4ad6['id']]=new Trigger(_0x1c4ad6):_0x5ed8c8[_0x486972('0x4e')](_0x5ed8c8['triggers'][_0x1c4ad6['id']],_0x1c4ad6);}}return _0x5ed8c8[_0x486972('0x3a')];};},Realtime[_0xc498d('0x34')][_0xc498d('0x37')]=function(){const _0x2863b6=this;return function(_0x478104){const _0x148bc8=a1092_0x3d6a;if(_0x478104){freeIsNotKey(_0x478104,_0x2863b6[_0x148bc8('0x26')],'id');for(let _0x25d29d=0x0,_0x5c8bea={};_0x25d29d<_0x478104[_0x148bc8('0x50')];_0x25d29d+=0x1){_0x5c8bea=_0x478104[_0x25d29d],_[_0x148bc8('0x2c')](_0x2863b6[_0x148bc8('0x26')][_0x5c8bea['id']])?_0x2863b6[_0x148bc8('0x26')][_0x5c8bea['id']]=new Template(_0x5c8bea):_0x2863b6['mergeFromDatabase'](_0x2863b6[_0x148bc8('0x26')][_0x5c8bea['id']],_0x5c8bea);}}return _0x2863b6[_0x148bc8('0x26')];};},Realtime[_0xc498d('0x34')][_0xc498d('0x2a')]=function(){const _0x1d41b8=this;return function(_0x3965c9){const _0x203f16=a1092_0x3d6a;if(_0x3965c9){freeIsNotKey(_0x3965c9,_0x1d41b8['zendeskAccounts'],'id');for(let _0x371a3d=0x0,_0x5331cc={};_0x371a3d<_0x3965c9['length'];_0x371a3d+=0x1){_0x5331cc=_0x3965c9[_0x371a3d],_[_0x203f16('0x2c')](_0x1d41b8[_0x203f16('0x5d')][_0x5331cc['id']])?_0x1d41b8[_0x203f16('0x5d')][_0x5331cc['id']]=new ZendeskAccount(_0x5331cc):_0x1d41b8[_0x203f16('0x4e')](_0x1d41b8[_0x203f16('0x5d')][_0x5331cc['id']],_0x5331cc);}}return _0x1d41b8[_0x203f16('0x5d')];};},Realtime['prototype'][_0xc498d('0x3')]=function(){const _0x22e6fc=this;return function(_0xc6c9a4){const _0x2d8a66=a1092_0x3d6a;if(_0xc6c9a4){freeIsNotKey(_0xc6c9a4,_0x22e6fc['salesforceAccounts'],'id');for(let _0x23bc1c=0x0,_0x3dedba={};_0x23bc1c<_0xc6c9a4[_0x2d8a66('0x50')];_0x23bc1c+=0x1){_0x3dedba=_0xc6c9a4[_0x23bc1c],_[_0x2d8a66('0x2c')](_0x22e6fc[_0x2d8a66('0x49')][_0x3dedba['id']])?_0x22e6fc[_0x2d8a66('0x49')][_0x3dedba['id']]=new SalesforceAccount(_0x3dedba):_0x22e6fc['mergeFromDatabase'](_0x22e6fc[_0x2d8a66('0x49')][_0x3dedba['id']],_0x3dedba);}}return _0x22e6fc[_0x2d8a66('0x49')];};},Realtime[_0xc498d('0x34')][_0xc498d('0xa')]=function(){const _0x336842=this;return function(_0xe28b1d){const _0x752b11=a1092_0x3d6a;if(_0xe28b1d){freeIsNotKey(_0xe28b1d,_0x336842[_0x752b11('0x17')],'id');for(let _0x5c9548=0x0,_0x4af6bb={};_0x5c9548<_0xe28b1d[_0x752b11('0x50')];_0x5c9548+=0x1){_0x4af6bb=_0xe28b1d[_0x5c9548],_[_0x752b11('0x2c')](_0x336842[_0x752b11('0x17')][_0x4af6bb['id']])?_0x336842[_0x752b11('0x17')][_0x4af6bb['id']]=new FreshdeskAccount(_0x4af6bb):_0x336842[_0x752b11('0x4e')](_0x336842[_0x752b11('0x17')][_0x4af6bb['id']],_0x4af6bb);}}return _0x336842['freshdeskAccounts'];};},Realtime[_0xc498d('0x34')][_0xc498d('0x38')]=function(){const _0x1bfc07=this;return function(_0x42f59e){const _0x613742=a1092_0x3d6a;if(_0x42f59e){freeIsNotKey(_0x42f59e,_0x1bfc07[_0x613742('0xd')],'id');for(let _0x384ff0=0x0,_0x321bf8={};_0x384ff0<_0x42f59e[_0x613742('0x50')];_0x384ff0+=0x1){_0x321bf8=_0x42f59e[_0x384ff0],_[_0x613742('0x2c')](_0x1bfc07['zohoAccounts'][_0x321bf8['id']])?_0x1bfc07[_0x613742('0xd')][_0x321bf8['id']]=new ZohoAccount(_0x321bf8):_0x1bfc07[_0x613742('0x4e')](_0x1bfc07[_0x613742('0xd')][_0x321bf8['id']],_0x321bf8);}}return _0x1bfc07[_0x613742('0xd')];};},Realtime['prototype'][_0xc498d('0x36')]=function(){const _0x2249b0=this;return function(_0x4872a6){const _0xe26a04=a1092_0x3d6a;if(_0x4872a6){freeIsNotKey(_0x4872a6,_0x2249b0[_0xe26a04('0x35')],'id');for(let _0xfd14b2=0x0,_0x5ee79d={};_0xfd14b2<_0x4872a6[_0xe26a04('0x50')];_0xfd14b2+=0x1){_0x5ee79d=_0x4872a6[_0xfd14b2],_[_0xe26a04('0x2c')](_0x2249b0[_0xe26a04('0x35')][_0x5ee79d['id']])?_0x2249b0[_0xe26a04('0x35')][_0x5ee79d['id']]=new DeskAccount(_0x5ee79d):_0x2249b0[_0xe26a04('0x4e')](_0x2249b0['deskAccounts'][_0x5ee79d['id']],_0x5ee79d);}}return _0x2249b0[_0xe26a04('0x35')];};},Realtime[_0xc498d('0x34')][_0xc498d('0x9')]=function(){const _0x2879ee=this;return function(_0x4992b5){const _0x5c01db=a1092_0x3d6a;if(_0x4992b5){freeIsNotKey(_0x4992b5,_0x2879ee[_0x5c01db('0x45')],'id');for(let _0x443189=0x0,_0x1a777d={};_0x443189<_0x4992b5['length'];_0x443189+=0x1){_0x1a777d=_0x4992b5[_0x443189],_[_0x5c01db('0x2c')](_0x2879ee[_0x5c01db('0x45')][_0x1a777d['id']])?_0x2879ee[_0x5c01db('0x45')][_0x1a777d['id']]=new SugarcrmAccount(_0x1a777d):_0x2879ee[_0x5c01db('0x4e')](_0x2879ee[_0x5c01db('0x45')][_0x1a777d['id']],_0x1a777d);}}return _0x2879ee[_0x5c01db('0x45')];};},Realtime[_0xc498d('0x34')][_0xc498d('0x4f')]=function(){const _0x12c15f=this;return function(_0x5198c6){const _0x22fe43=a1092_0x3d6a;if(_0x5198c6){freeIsNotKey(_0x5198c6,_0x12c15f[_0x22fe43('0x31')],'id');for(let _0x2901dc=0x0,_0x5eddc5={};_0x2901dc<_0x5198c6[_0x22fe43('0x50')];_0x2901dc+=0x1){_0x5eddc5=_0x5198c6[_0x2901dc],_['isUndefined'](_0x12c15f[_0x22fe43('0x31')][_0x5eddc5['id']])?_0x12c15f[_0x22fe43('0x31')][_0x5eddc5['id']]=new VtigerAccount(_0x5eddc5):_0x12c15f['mergeFromDatabase'](_0x12c15f[_0x22fe43('0x31')][_0x5eddc5['id']],_0x5eddc5);}}return _0x12c15f['vtigerAccounts'];};},Realtime[_0xc498d('0x34')][_0xc498d('0x29')]=function(){const _0x3f7783=this;return function(_0x1a0cad){const _0x1635f6=a1092_0x3d6a;if(_0x1a0cad){freeIsNotKey(_0x1a0cad,_0x3f7783['servicenowAccounts'],'id');for(let _0x5720e0=0x0,_0xe3a71={};_0x5720e0<_0x1a0cad[_0x1635f6('0x50')];_0x5720e0+=0x1){_0xe3a71=_0x1a0cad[_0x5720e0],_['isUndefined'](_0x3f7783[_0x1635f6('0x1e')][_0xe3a71['id']])?_0x3f7783[_0x1635f6('0x1e')][_0xe3a71['id']]=new ServicenowAccount(_0xe3a71):_0x3f7783[_0x1635f6('0x4e')](_0x3f7783[_0x1635f6('0x1e')][_0xe3a71['id']],_0xe3a71);}}return _0x3f7783[_0x1635f6('0x1e')];};},Realtime['prototype'][_0xc498d('0x28')]=function(){const _0x213bae=this;return function(_0x53370a){const _0x56bcd5=a1092_0x3d6a;if(_0x53370a){freeIsNotKey(_0x53370a,_0x213bae[_0x56bcd5('0x57')],'id');for(let _0x428fed=0x0,_0x4d20a4={};_0x428fed<_0x53370a[_0x56bcd5('0x50')];_0x428fed+=0x1){_0x4d20a4=_0x53370a[_0x428fed],_[_0x56bcd5('0x2c')](_0x213bae[_0x56bcd5('0x57')][_0x4d20a4['id']])?_0x213bae[_0x56bcd5('0x57')][_0x4d20a4['id']]=new Dynamics365Account(_0x4d20a4):_0x213bae[_0x56bcd5('0x4e')](_0x213bae[_0x56bcd5('0x57')][_0x4d20a4['id']],_0x4d20a4);}}return _0x213bae[_0x56bcd5('0x57')];};},Realtime[_0xc498d('0x34')]['initFreshsalesAccounts']=function(){const _0x1e6a22=this;return function(_0x5f00e1){const _0x579042=a1092_0x3d6a;if(_0x5f00e1){freeIsNotKey(_0x5f00e1,_0x1e6a22[_0x579042('0x3e')],'id');for(let _0x53a2d6=0x0,_0x152808={};_0x53a2d6<_0x5f00e1['length'];_0x53a2d6+=0x1){_0x152808=_0x5f00e1[_0x53a2d6],_[_0x579042('0x2c')](_0x1e6a22[_0x579042('0x3e')][_0x152808['id']])?_0x1e6a22[_0x579042('0x3e')][_0x152808['id']]=new FreshsalesAccount(_0x152808):_0x1e6a22[_0x579042('0x4e')](_0x1e6a22[_0x579042('0x3e')][_0x152808['id']],_0x152808);}}return _0x1e6a22[_0x579042('0x3e')];};},Realtime[_0xc498d('0x34')][_0xc498d('0x14')]=function(){const _0x2f4efb=this;return function(_0xecdf4b){const _0x43ca58=a1092_0x3d6a;for(let _0x522c6b=0x0;_0x522c6b<_0xecdf4b['length'];_0x522c6b+=0x1){_[_0x43ca58('0x5f')](_0x2f4efb['voiceQueues'][_0xecdf4b[_0x522c6b][_0x43ca58('0x2e')]],_0xecdf4b[_0x522c6b]);}return _0x2f4efb[_0x43ca58('0x1b')];};},Realtime['prototype']['initVoiceQueueReports']=function(){const _0x3ce29b=this;return function(_0x4c7391){const _0x135aca=a1092_0x3d6a;clearVoiceQueues(_0x3ce29b[_0x135aca('0x1b')]);if(_0x4c7391){_0x4c7391=_['groupBy'](_0x4c7391,_0x135aca('0x51'));for(const _0x29a2e2 in _0x4c7391){if(typeof _0x4c7391[_0x29a2e2]!==_0x135aca('0x27'))for(let _0x209ba8=0x0;_0x209ba8<_0x4c7391[_0x29a2e2]['length'];_0x209ba8+=0x1){const _0x190e74=_0x4c7391[_0x29a2e2][_0x209ba8]['queue'];_0x3ce29b[_0x135aca('0x1b')][_0x190e74]&&(_0x4c7391[_0x29a2e2][_0x209ba8][_0x135aca('0x20')]&&(_0x3ce29b[_0x135aca('0x1b')][_0x190e74][_0x135aca('0x3b')]+=0x1),_0x4c7391[_0x29a2e2][_0x209ba8][_0x135aca('0x4b')]&&(_0x3ce29b['voiceQueues'][_0x190e74]['abandoned']+=0x1),_0x3ce29b['voiceQueues'][_0x190e74][_0x135aca('0x40')]+=moment(_0x4c7391[_0x29a2e2][_0x209ba8][_0x135aca('0x5e')])[_0x135aca('0xf')](moment(_0x4c7391[_0x29a2e2][_0x209ba8]['queuecallerjoinAt']),_0x135aca('0x30'))||0x0,_0x209ba8===_0x4c7391[_0x29a2e2][_0x135aca('0x50')]-0x1?(_0x3ce29b[_0x135aca('0x1b')][_0x190e74][_0x135aca('0x15')]+=moment(_0x4c7391[_0x29a2e2][_0x209ba8][_0x135aca('0x18')]||_0x4c7391[_0x29a2e2][_0x209ba8][_0x135aca('0x23')]||_0x4c7391[_0x29a2e2][_0x209ba8]['queuecallerexitAt'])[_0x135aca('0xf')](moment(_0x4c7391[_0x29a2e2][_0x209ba8][_0x135aca('0x7')]),'seconds')||0x0,_0x3ce29b[_0x135aca('0x1b')][_0x190e74][_0x135aca('0x8')]+=0x1,_0x4c7391[_0x29a2e2][_0x209ba8][_0x135aca('0x2b')]&&(_0x3ce29b[_0x135aca('0x1b')][_0x190e74]['answered']+=0x1,_0x3ce29b[_0x135aca('0x1b')][_0x190e74][_0x135aca('0x1f')]+=moment(_0x4c7391[_0x29a2e2][_0x209ba8][_0x135aca('0x18')])[_0x135aca('0xf')](moment(_0x4c7391[_0x29a2e2][_0x209ba8][_0x135aca('0x5e')]),'seconds')||0x0)):_0x3ce29b[_0x135aca('0x1b')][_0x190e74][_0x135aca('0x15')]+=_0x3ce29b[_0x135aca('0x1b')][_0x190e74][_0x135aca('0x40')]||0x0);}}}return _0x3ce29b[_0x135aca('0x1b')];};},Realtime[_0xc498d('0x34')][_0xc498d('0x54')]=function(){const _0x4dd177=this;return function(_0x22934b){const _0x58e85c=a1092_0x3d6a;clearVoiceCallReports(_0x4dd177[_0x58e85c('0x16')]);if(_0x22934b)for(let _0x59c176=0x0;_0x59c176<_0x22934b[_0x58e85c('0x50')];_0x59c176+=0x1){_0x4dd177[_0x58e85c('0x16')][_0x58e85c('0x8')]+=0x1,_0x4dd177[_0x58e85c('0x16')][_0x58e85c('0x15')]+=_0x22934b[_0x59c176]['duration'],_0x22934b[_0x59c176]['disposition']==='ANSWERED'&&(_0x4dd177[_0x58e85c('0x16')]['answered']+=0x1,_0x4dd177[_0x58e85c('0x16')][_0x58e85c('0x40')]+=_0x22934b[_0x59c176]['duration']-_0x22934b[_0x59c176][_0x58e85c('0x60')]||0x0,_0x4dd177['outbound']['sumBillable']+=_0x22934b[_0x59c176][_0x58e85c('0x60')]);}return _0x4dd177[_0x58e85c('0x16')];};},Realtime[_0xc498d('0x34')][_0xc498d('0x4c')]=function(){const _0x2127f1=this;return function(_0x48f697){const _0x568392=a1092_0x3d6a;if(_0x48f697){freeIsNotKey(_0x48f697,_0x2127f1['campaigns'],_0x568392('0x2e'));for(let _0x519077=0x0,_0x111039={};_0x519077<_0x48f697[_0x568392('0x50')];_0x519077+=0x1){_0x111039=_0x48f697[_0x519077],_[_0x568392('0x2c')](_0x2127f1[_0x568392('0x47')][_0x111039[_0x568392('0x2e')]])?_0x2127f1[_0x568392('0x47')][_0x111039[_0x568392('0x2e')]]=new Campaign(_0x111039):(_0x2127f1['mergeFromDatabase'](_0x2127f1[_0x568392('0x47')][_0x111039['name']],_0x111039),_0x2127f1[_0x568392('0x47')][_0x111039[_0x568392('0x2e')]][_0x568392('0x1')]=_0x111039['SquareProject']?_0x111039['SquareProject'][_0x568392('0x2e')]:undefined);}}return _0x2127f1[_0x568392('0x47')];};},Realtime[_0xc498d('0x34')]['initVoiceExtensions']=function(){const _0x243e9d=this;return function(_0x142061){const _0x570a0e=a1092_0x3d6a;if(_0x142061){freeIsNotKey(_0x142061,_0x243e9d[_0x570a0e('0x0')],'id');for(let _0x41b45c=0x0,_0x3e7e63={};_0x41b45c<_0x142061[_0x570a0e('0x50')];_0x41b45c+=0x1){_0x3e7e63=_0x142061[_0x41b45c],_[_0x570a0e('0x2c')](_0x243e9d[_0x570a0e('0x0')][_0x3e7e63['id']])?_0x243e9d[_0x570a0e('0x0')][_0x3e7e63['id']]=new VoiceExtension(_0x3e7e63):_0x243e9d[_0x570a0e('0x4e')](_0x243e9d[_0x570a0e('0x0')][_0x3e7e63['id']],_0x3e7e63);}}return _0x243e9d['voiceExtensions'];};},Realtime[_0xc498d('0x34')]['initCampaignHopperHistory']=function(){const _0x4db257=this;return function(_0x22acb1){const _0x59151c=a1092_0x3d6a;clearCampaigns(_0x4db257['campaigns']);for(let _0x579141=0x0;_0x579141<_0x22acb1[_0x59151c('0x50')];_0x579141+=0x1){_[_0x59151c('0x5f')](_0x4db257[_0x59151c('0x47')][_0x22acb1[_0x579141][_0x59151c('0x2e')]],_0x22acb1[_0x579141]);}return _0x4db257[_0x59151c('0x47')];};},Realtime[_0xc498d('0x34')]['initFaxAccounts']=function(){const _0x54d8c1=this;return function(_0x44f673){const _0xe86680=a1092_0x3d6a;if(_0x44f673){freeIsNotKey(_0x44f673,_0x54d8c1[_0xe86680('0x39')],'id');for(let _0xdba8ab=0x0,_0x5630d5={};_0xdba8ab<_0x44f673[_0xe86680('0x50')];_0xdba8ab+=0x1){_0x5630d5=_0x44f673[_0xdba8ab],_[_0xe86680('0x2c')](_0x54d8c1[_0xe86680('0x39')][_0x5630d5['id']])?_0x54d8c1['faxAccounts'][_0x5630d5['id']]=new FaxAccount(_0x5630d5):_0x54d8c1[_0xe86680('0x4e')](_0x54d8c1[_0xe86680('0x39')][_0x5630d5['id']],_0x5630d5);}}return _0x54d8c1[_0xe86680('0x39')];};},module[_0xc498d('0x41')]=Realtime; \ No newline at end of file +const a1092_0x14ff=['groupBy','lodash','faxAccounts','unmanaged','../model/zohoAccount','initVoiceCallReports','initCampaigns','queuecallercomplete','../model/deskAccount','ivrAnswerCallsDay','../model/freshdeskAccount','../model/dynamics365Account','voiceExtensions','initSalesforceAccounts','diff','outboundUnknownCallsDay','isEmpty','outboundDropCallsDayTimeout','merge','initVtigerAccounts','queuecallerexit','initVoiceQueueHopperHistory','voiceQueues','abandoned','length','name','outboundNoAnswerCallsDay','isNil','outboundOriginateFailureCallsDay','campaigns','sumBillable','util','moment','freshsalesAccounts','ANSWERED','initVoiceExtensions','salesforceAccounts','outboundRejectCallsDay','outboundDropCallsDayCallersExit','../model/voiceQueue','../model/vtigerAccount','telephones','initTemplates','freshdeskAccounts','initServicenowAccounts','outbound','queue','SquareProject','mapKeys','outboundAnswerAgiCallsDay','initZendeskAccounts','mergeFromDatabase','total','ivrTotalCallsDays','queuecallerexitAt','zohoAccounts','timers','initZohoAccounts','SIP/%s','outboundChannels','outboundNoSuchCallsDay','trunks','../model/campaign','interface','sumDuration','seconds','prototype','servicenowAccounts','../model/freshsalesAccount','initFreshsalesAccounts','billableseconds','initVoiceQueues','../model/trigger','format','../model/sugarcrmAccount','isUndefined','exports','queuecallerabandonAt','triggers','sumHoldTime','../model/servicenowAccount','../model/voiceExtension','queuecallerjoinAt','queueStatusComplete','zendeskAccounts','duration','initCampaignHopperHistory','initFreshdeskAccounts','outboundReCallsDay','disposition','vtigerAccounts','answered','queuecallerleaveAt','uniqueid','outboundAnswerCallsDay','undefined','sugarcrmAccounts','../model/template','deskAccounts','dynamics365Accounts','initTelephones','../model/salesforceAccount','templates','initAgents'];(function(_0x36fc46,_0x14ff72){const _0x37f5be=function(_0x4743cb){while(--_0x4743cb){_0x36fc46['push'](_0x36fc46['shift']());}};_0x37f5be(++_0x14ff72);}(a1092_0x14ff,0x7b));const a1092_0x37f5=function(_0x36fc46,_0x14ff72){_0x36fc46=_0x36fc46-0x0;let _0x37f5be=a1092_0x14ff[_0x36fc46];return _0x37f5be;};const _0x5b0a20=a1092_0x37f5;'use strict';const util=require(_0x5b0a20('0xc')),_=require(_0x5b0a20('0x56')),moment=require(_0x5b0a20('0xd')),Agent=require('../model/agent'),Telephone=require('../model/telephone'),Trunk=require('../model/trunk'),VoiceQueue=require(_0x5b0a20('0x14')),Trigger=require(_0x5b0a20('0x35')),Template=require(_0x5b0a20('0x4e')),Campaign=require(_0x5b0a20('0x2b')),VoiceExtension=require(_0x5b0a20('0x3e')),ZendeskAccount=require('../model/zendeskAccount'),SalesforceAccount=require(_0x5b0a20('0x52')),FreshdeskAccount=require(_0x5b0a20('0x5f')),SugarcrmAccount=require(_0x5b0a20('0x37')),ZohoAccount=require(_0x5b0a20('0x59')),DeskAccount=require(_0x5b0a20('0x5d')),VtigerAccount=require(_0x5b0a20('0x15')),ServicenowAccount=require(_0x5b0a20('0x3d')),Dynamics365Account=require(_0x5b0a20('0x60')),FreshsalesAccount=require(_0x5b0a20('0x31')),FaxAccount=require('../model/faxAccount'),Realtime=function(){const _0x12f9aa=_0x5b0a20;this['agents']={},this['telephones']={},this['trunks']={},this[_0x12f9aa('0x3')]={},this[_0x12f9aa('0x3b')]={},this[_0x12f9aa('0xa')]={},this['templates']={},this[_0x12f9aa('0x1a')]={'total':0x0,'answered':0x0,'sumHoldTime':0x0,'sumDuration':0x0,'sumBillable':0x0},this[_0x12f9aa('0x61')]={},this['channels']={},this['queueChannels']={},this[_0x12f9aa('0x28')]={},this[_0x12f9aa('0x25')]={},this['zendeskAccounts']={},this[_0x12f9aa('0x11')]={},this[_0x12f9aa('0x4d')]={},this[_0x12f9aa('0x18')]={},this['zohoAccounts']={},this[_0x12f9aa('0x4f')]={},this['vtigerAccounts']={},this[_0x12f9aa('0x30')]={},this[_0x12f9aa('0x50')]={},this[_0x12f9aa('0xe')]={},this[_0x12f9aa('0x57')]={};};function freeIsNotKey(_0x4743cb,_0x3704f,_0x451830){const _0x1ec53d=_0x5b0a20,_0x43c6aa=_[_0x1ec53d('0x1d')](_0x4743cb,function(_0x497e5c){return _0x497e5c[_0x451830];});for(const _0xb73059 in _0x3704f){typeof _0x3704f[_0xb73059]!==_0x1ec53d('0x4c')&&(!_0x43c6aa[_0xb73059]&&delete _0x3704f[_0xb73059]);}}function freeIsNotKeySip(_0x410b14,_0x220464){const _0x29cfba=_0x5b0a20,_0x336522=_['mapKeys'](_0x410b14,function(_0x367bb4){const _0x1d67d3=a1092_0x37f5;return util[_0x1d67d3('0x36')](_0x1d67d3('0x27'),_0x367bb4[_0x1d67d3('0x6')]);});for(const _0x13d4c0 in _0x220464){typeof _0x220464[_0x13d4c0]!==_0x29cfba('0x4c')&&(!_0x336522[_0x13d4c0]&&delete _0x220464[_0x13d4c0]);}}function freeIsNotKeyAgent(_0x5e6c7a,_0x5da21d){const _0x4d5424=_0x5b0a20,_0x41bcb5=_[_0x4d5424('0x1d')](_0x5e6c7a,function(_0x432e59){const _0x1d6eff=_0x4d5424,_0x4ffa67=_[_0x1d6eff('0x8')](_0x432e59[_0x1d6eff('0x2c')])?util[_0x1d6eff('0x36')](_0x1d6eff('0x27'),_0x432e59['name']):_0x432e59[_0x1d6eff('0x2c')];return _0x4ffa67;});for(const _0x264b6c in _0x5da21d){typeof _0x5da21d[_0x264b6c]!==_0x4d5424('0x4c')&&(!_0x41bcb5[_0x264b6c]&&delete _0x5da21d[_0x264b6c]);}}function clearVoiceCallReports(_0x316393){const _0xc6450f=_0x5b0a20;_0x316393[_0xc6450f('0x21')]=0x0,_0x316393[_0xc6450f('0x48')]=0x0,_0x316393[_0xc6450f('0x3c')]=0x0,_0x316393[_0xc6450f('0x2d')]=0x0,_0x316393['sumBillable']=0x0;}function clearCampaigns(_0x2b1c40){const _0x3c1c34=_0x5b0a20;if(!_[_0x3c1c34('0x65')](_0x2b1c40))for(const _0x4b98c2 in _0x2b1c40){typeof _0x2b1c40[_0x4b98c2]!=='undefined'&&(_0x2b1c40[_0x4b98c2][_0x3c1c34('0x22')]=0x0,_0x2b1c40[_0x4b98c2][_0x3c1c34('0x5e')]=0x0);}}function clearVoiceQueues(_0x167c40){const _0x437e0e=_0x5b0a20;if(!_['isEmpty'](_0x167c40))for(const _0x5aa711 in _0x167c40){typeof _0x167c40[_0x5aa711]!==_0x437e0e('0x4c')&&(_0x167c40[_0x5aa711][_0x437e0e('0x21')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x48')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x58')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x4')]=0x0,_0x167c40[_0x5aa711]['sumHoldTime']=0x0,_0x167c40[_0x5aa711]['sumDuration']=0x0,_0x167c40[_0x5aa711][_0x437e0e('0xb')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x1e')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x7')]=0x0,_0x167c40[_0x5aa711]['outboundBusyCallsDay']=0x0,_0x167c40[_0x5aa711]['outboundCongestionCallsDay']=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x29')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x64')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x66')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x13')]=0x0,_0x167c40[_0x5aa711]['outboundBlacklistCallsDay']=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x9')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x12')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x45')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x1e')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x4b')]=0x0,_0x167c40[_0x5aa711][_0x437e0e('0x40')]=!![]);}}Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x20')]=function(_0xfe9c1d,_0x19a44a){const _0x5f9968=_0x5b0a20;for(const _0x3e4302 in _0x19a44a){typeof _0xfe9c1d[_0x3e4302]!==_0x5f9968('0x4c')&&(_0xfe9c1d[_0x3e4302]=_0x19a44a[_0x3e4302]);}},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x54')]=function(){const _0xc1786a=this;return function(_0xf80bc3){const _0x39143e=a1092_0x37f5;if(_0xf80bc3){freeIsNotKeyAgent(_0xf80bc3,_0xc1786a['agents']);for(let _0x59469e=0x0,_0x6d8f71={};_0x59469e<_0xf80bc3[_0x39143e('0x5')];_0x59469e+=0x1){_0x6d8f71=_0xf80bc3[_0x59469e];const _0x4096b6=_['isNil'](_0x6d8f71[_0x39143e('0x2c')])?util['format'](_0x39143e('0x27'),_0x6d8f71['name']):_0x6d8f71[_0x39143e('0x2c')];_[_0x39143e('0x38')](_0xc1786a['agents'][_0x4096b6])?_0xc1786a['agents'][_0x4096b6]=new Agent(_0x6d8f71):_0xc1786a[_0x39143e('0x20')](_0xc1786a['agents'][_0x4096b6],_0x6d8f71);}}return _0xc1786a['agents'];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x51')]=function(){const _0x35b0d2=this;return function(_0x5d6ecb){const _0x121437=a1092_0x37f5;if(_0x5d6ecb){freeIsNotKeySip(_0x5d6ecb,_0x35b0d2['telephones']);for(let _0x193bd5=0x0,_0x29944b={};_0x193bd5<_0x5d6ecb['length'];_0x193bd5+=0x1){_0x29944b=_0x5d6ecb[_0x193bd5],_['isUndefined'](_0x35b0d2[_0x121437('0x16')][util[_0x121437('0x36')](_0x121437('0x27'),_0x29944b[_0x121437('0x6')])])?_0x35b0d2[_0x121437('0x16')][util[_0x121437('0x36')](_0x121437('0x27'),_0x29944b[_0x121437('0x6')])]=new Telephone(_0x29944b):_0x35b0d2['mergeFromDatabase'](_0x35b0d2[_0x121437('0x16')][util[_0x121437('0x36')](_0x121437('0x27'),_0x29944b['name'])],_0x29944b);}}return _0x35b0d2['telephones'];};},Realtime[_0x5b0a20('0x2f')]['initTrunks']=function(){const _0x42f168=this;return function(_0x310d21){const _0x53cba8=a1092_0x37f5;if(_0x310d21){freeIsNotKeySip(_0x310d21,_0x42f168[_0x53cba8('0x2a')]);for(let _0x5aa3c6=0x0,_0x19297b={};_0x5aa3c6<_0x310d21['length'];_0x5aa3c6+=0x1){_0x19297b=_0x310d21[_0x5aa3c6],_[_0x53cba8('0x38')](_0x42f168['trunks'][util['format'](_0x53cba8('0x27'),_0x19297b['name'])])?_0x42f168[_0x53cba8('0x2a')][util[_0x53cba8('0x36')](_0x53cba8('0x27'),_0x19297b[_0x53cba8('0x6')])]=new Trunk(_0x19297b):_0x42f168['mergeFromDatabase'](_0x42f168['trunks'][util[_0x53cba8('0x36')]('SIP/%s',_0x19297b[_0x53cba8('0x6')])],_0x19297b);}}return _0x42f168[_0x53cba8('0x2a')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x34')]=function(){const _0x3c66d9=this;return function(_0x12dd8c){const _0x3d7a54=a1092_0x37f5;if(_0x12dd8c){freeIsNotKey(_0x12dd8c,_0x3c66d9[_0x3d7a54('0x3')],_0x3d7a54('0x6'));for(let _0x5309a2=0x0,_0x178747={};_0x5309a2<_0x12dd8c[_0x3d7a54('0x5')];_0x5309a2+=0x1){_0x178747=_0x12dd8c[_0x5309a2],_[_0x3d7a54('0x38')](_0x3c66d9[_0x3d7a54('0x3')][_0x178747['name']])?_0x3c66d9[_0x3d7a54('0x3')][_0x178747[_0x3d7a54('0x6')]]=new VoiceQueue(_0x178747):_0x3c66d9[_0x3d7a54('0x20')](_0x3c66d9[_0x3d7a54('0x3')][_0x178747[_0x3d7a54('0x6')]],_0x178747);}}return _0x3c66d9[_0x3d7a54('0x3')];};},Realtime['prototype']['initTriggers']=function(){const _0x3449ce=this;return function(_0x1fcc62){const _0x264168=a1092_0x37f5;if(_0x1fcc62){freeIsNotKey(_0x1fcc62,_0x3449ce[_0x264168('0x3b')],'id');for(let _0xf8e1b5=0x0,_0x4c1f00={};_0xf8e1b5<_0x1fcc62[_0x264168('0x5')];_0xf8e1b5+=0x1){_0x4c1f00=_0x1fcc62[_0xf8e1b5],_['isUndefined'](_0x3449ce[_0x264168('0x3b')][_0x4c1f00['id']])?_0x3449ce[_0x264168('0x3b')][_0x4c1f00['id']]=new Trigger(_0x4c1f00):_0x3449ce[_0x264168('0x20')](_0x3449ce[_0x264168('0x3b')][_0x4c1f00['id']],_0x4c1f00);}}return _0x3449ce[_0x264168('0x3b')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x17')]=function(){const _0x423c6b=this;return function(_0x1e74d0){const _0xed611f=a1092_0x37f5;if(_0x1e74d0){freeIsNotKey(_0x1e74d0,_0x423c6b[_0xed611f('0x53')],'id');for(let _0x197a33=0x0,_0x1a4558={};_0x197a33<_0x1e74d0[_0xed611f('0x5')];_0x197a33+=0x1){_0x1a4558=_0x1e74d0[_0x197a33],_[_0xed611f('0x38')](_0x423c6b[_0xed611f('0x53')][_0x1a4558['id']])?_0x423c6b['templates'][_0x1a4558['id']]=new Template(_0x1a4558):_0x423c6b[_0xed611f('0x20')](_0x423c6b[_0xed611f('0x53')][_0x1a4558['id']],_0x1a4558);}}return _0x423c6b[_0xed611f('0x53')];};},Realtime['prototype'][_0x5b0a20('0x1f')]=function(){const _0x286926=this;return function(_0x51c0bf){const _0x45c9cf=a1092_0x37f5;if(_0x51c0bf){freeIsNotKey(_0x51c0bf,_0x286926[_0x45c9cf('0x41')],'id');for(let _0x29aa1c=0x0,_0x37e27d={};_0x29aa1c<_0x51c0bf[_0x45c9cf('0x5')];_0x29aa1c+=0x1){_0x37e27d=_0x51c0bf[_0x29aa1c],_[_0x45c9cf('0x38')](_0x286926['zendeskAccounts'][_0x37e27d['id']])?_0x286926[_0x45c9cf('0x41')][_0x37e27d['id']]=new ZendeskAccount(_0x37e27d):_0x286926[_0x45c9cf('0x20')](_0x286926[_0x45c9cf('0x41')][_0x37e27d['id']],_0x37e27d);}}return _0x286926[_0x45c9cf('0x41')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x62')]=function(){const _0x892df1=this;return function(_0x29440b){const _0x2a5bcd=a1092_0x37f5;if(_0x29440b){freeIsNotKey(_0x29440b,_0x892df1[_0x2a5bcd('0x11')],'id');for(let _0x46fb82=0x0,_0x4f8d66={};_0x46fb82<_0x29440b[_0x2a5bcd('0x5')];_0x46fb82+=0x1){_0x4f8d66=_0x29440b[_0x46fb82],_[_0x2a5bcd('0x38')](_0x892df1[_0x2a5bcd('0x11')][_0x4f8d66['id']])?_0x892df1[_0x2a5bcd('0x11')][_0x4f8d66['id']]=new SalesforceAccount(_0x4f8d66):_0x892df1['mergeFromDatabase'](_0x892df1['salesforceAccounts'][_0x4f8d66['id']],_0x4f8d66);}}return _0x892df1[_0x2a5bcd('0x11')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x44')]=function(){const _0x5125ef=this;return function(_0x923f26){const _0x43d729=a1092_0x37f5;if(_0x923f26){freeIsNotKey(_0x923f26,_0x5125ef[_0x43d729('0x18')],'id');for(let _0x30e192=0x0,_0x563b2b={};_0x30e192<_0x923f26['length'];_0x30e192+=0x1){_0x563b2b=_0x923f26[_0x30e192],_[_0x43d729('0x38')](_0x5125ef[_0x43d729('0x18')][_0x563b2b['id']])?_0x5125ef[_0x43d729('0x18')][_0x563b2b['id']]=new FreshdeskAccount(_0x563b2b):_0x5125ef['mergeFromDatabase'](_0x5125ef[_0x43d729('0x18')][_0x563b2b['id']],_0x563b2b);}}return _0x5125ef[_0x43d729('0x18')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x26')]=function(){const _0x2c812a=this;return function(_0x3d7992){const _0x556b0f=a1092_0x37f5;if(_0x3d7992){freeIsNotKey(_0x3d7992,_0x2c812a[_0x556b0f('0x24')],'id');for(let _0x509d67=0x0,_0xbc05ee={};_0x509d67<_0x3d7992[_0x556b0f('0x5')];_0x509d67+=0x1){_0xbc05ee=_0x3d7992[_0x509d67],_[_0x556b0f('0x38')](_0x2c812a[_0x556b0f('0x24')][_0xbc05ee['id']])?_0x2c812a[_0x556b0f('0x24')][_0xbc05ee['id']]=new ZohoAccount(_0xbc05ee):_0x2c812a[_0x556b0f('0x20')](_0x2c812a[_0x556b0f('0x24')][_0xbc05ee['id']],_0xbc05ee);}}return _0x2c812a['zohoAccounts'];};},Realtime[_0x5b0a20('0x2f')]['initDeskAccounts']=function(){const _0x47bf66=this;return function(_0x167aaa){const _0x5ac1a4=a1092_0x37f5;if(_0x167aaa){freeIsNotKey(_0x167aaa,_0x47bf66[_0x5ac1a4('0x4f')],'id');for(let _0x12760a=0x0,_0x1bd265={};_0x12760a<_0x167aaa[_0x5ac1a4('0x5')];_0x12760a+=0x1){_0x1bd265=_0x167aaa[_0x12760a],_['isUndefined'](_0x47bf66[_0x5ac1a4('0x4f')][_0x1bd265['id']])?_0x47bf66['deskAccounts'][_0x1bd265['id']]=new DeskAccount(_0x1bd265):_0x47bf66[_0x5ac1a4('0x20')](_0x47bf66['deskAccounts'][_0x1bd265['id']],_0x1bd265);}}return _0x47bf66[_0x5ac1a4('0x4f')];};},Realtime[_0x5b0a20('0x2f')]['initSugarcrmAccounts']=function(){const _0x3f90ef=this;return function(_0x454efe){const _0x211320=a1092_0x37f5;if(_0x454efe){freeIsNotKey(_0x454efe,_0x3f90ef[_0x211320('0x4d')],'id');for(let _0x351e1a=0x0,_0x4a8e52={};_0x351e1a<_0x454efe['length'];_0x351e1a+=0x1){_0x4a8e52=_0x454efe[_0x351e1a],_[_0x211320('0x38')](_0x3f90ef['sugarcrmAccounts'][_0x4a8e52['id']])?_0x3f90ef[_0x211320('0x4d')][_0x4a8e52['id']]=new SugarcrmAccount(_0x4a8e52):_0x3f90ef[_0x211320('0x20')](_0x3f90ef[_0x211320('0x4d')][_0x4a8e52['id']],_0x4a8e52);}}return _0x3f90ef[_0x211320('0x4d')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x0')]=function(){const _0x2f4860=this;return function(_0x15f58a){const _0x4266c4=a1092_0x37f5;if(_0x15f58a){freeIsNotKey(_0x15f58a,_0x2f4860['vtigerAccounts'],'id');for(let _0x544b7d=0x0,_0x15e9ee={};_0x544b7d<_0x15f58a[_0x4266c4('0x5')];_0x544b7d+=0x1){_0x15e9ee=_0x15f58a[_0x544b7d],_[_0x4266c4('0x38')](_0x2f4860[_0x4266c4('0x47')][_0x15e9ee['id']])?_0x2f4860['vtigerAccounts'][_0x15e9ee['id']]=new VtigerAccount(_0x15e9ee):_0x2f4860[_0x4266c4('0x20')](_0x2f4860['vtigerAccounts'][_0x15e9ee['id']],_0x15e9ee);}}return _0x2f4860[_0x4266c4('0x47')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x19')]=function(){const _0x384e10=this;return function(_0x4dfce1){const _0x211dba=a1092_0x37f5;if(_0x4dfce1){freeIsNotKey(_0x4dfce1,_0x384e10[_0x211dba('0x30')],'id');for(let _0xbb64fe=0x0,_0x5801b4={};_0xbb64fe<_0x4dfce1[_0x211dba('0x5')];_0xbb64fe+=0x1){_0x5801b4=_0x4dfce1[_0xbb64fe],_[_0x211dba('0x38')](_0x384e10['servicenowAccounts'][_0x5801b4['id']])?_0x384e10['servicenowAccounts'][_0x5801b4['id']]=new ServicenowAccount(_0x5801b4):_0x384e10['mergeFromDatabase'](_0x384e10[_0x211dba('0x30')][_0x5801b4['id']],_0x5801b4);}}return _0x384e10['servicenowAccounts'];};},Realtime[_0x5b0a20('0x2f')]['initDynamics365Accounts']=function(){const _0x22a32d=this;return function(_0x1f7564){const _0x1ea5d3=a1092_0x37f5;if(_0x1f7564){freeIsNotKey(_0x1f7564,_0x22a32d[_0x1ea5d3('0x50')],'id');for(let _0x37e2a7=0x0,_0x3b7d4f={};_0x37e2a7<_0x1f7564[_0x1ea5d3('0x5')];_0x37e2a7+=0x1){_0x3b7d4f=_0x1f7564[_0x37e2a7],_[_0x1ea5d3('0x38')](_0x22a32d[_0x1ea5d3('0x50')][_0x3b7d4f['id']])?_0x22a32d['dynamics365Accounts'][_0x3b7d4f['id']]=new Dynamics365Account(_0x3b7d4f):_0x22a32d[_0x1ea5d3('0x20')](_0x22a32d[_0x1ea5d3('0x50')][_0x3b7d4f['id']],_0x3b7d4f);}}return _0x22a32d['dynamics365Accounts'];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x32')]=function(){const _0x5c0176=this;return function(_0x441c5b){const _0x1a6a40=a1092_0x37f5;if(_0x441c5b){freeIsNotKey(_0x441c5b,_0x5c0176[_0x1a6a40('0xe')],'id');for(let _0x2494c1=0x0,_0x4a318b={};_0x2494c1<_0x441c5b[_0x1a6a40('0x5')];_0x2494c1+=0x1){_0x4a318b=_0x441c5b[_0x2494c1],_['isUndefined'](_0x5c0176['freshsalesAccounts'][_0x4a318b['id']])?_0x5c0176[_0x1a6a40('0xe')][_0x4a318b['id']]=new FreshsalesAccount(_0x4a318b):_0x5c0176['mergeFromDatabase'](_0x5c0176['freshsalesAccounts'][_0x4a318b['id']],_0x4a318b);}}return _0x5c0176[_0x1a6a40('0xe')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x2')]=function(){const _0x2b871f=this;return function(_0xe3a171){const _0x3f2030=a1092_0x37f5;for(let _0x5f1ac8=0x0;_0x5f1ac8<_0xe3a171[_0x3f2030('0x5')];_0x5f1ac8+=0x1){_[_0x3f2030('0x67')](_0x2b871f[_0x3f2030('0x3')][_0xe3a171[_0x5f1ac8][_0x3f2030('0x6')]],_0xe3a171[_0x5f1ac8]);}return _0x2b871f[_0x3f2030('0x3')];};},Realtime[_0x5b0a20('0x2f')]['initVoiceQueueReports']=function(){const _0x21611a=this;return function(_0x133f41){const _0x519802=a1092_0x37f5;clearVoiceQueues(_0x21611a[_0x519802('0x3')]);if(_0x133f41){_0x133f41=_[_0x519802('0x55')](_0x133f41,_0x519802('0x4a'));for(const _0x5cbd87 in _0x133f41){if(typeof _0x133f41[_0x5cbd87]!==_0x519802('0x4c'))for(let _0x2d4a7e=0x0;_0x2d4a7e<_0x133f41[_0x5cbd87]['length'];_0x2d4a7e+=0x1){const _0x4b320e=_0x133f41[_0x5cbd87][_0x2d4a7e][_0x519802('0x1b')];_0x21611a[_0x519802('0x3')][_0x4b320e]&&(_0x133f41[_0x5cbd87][_0x2d4a7e][_0x519802('0x1')]&&(_0x21611a['voiceQueues'][_0x4b320e][_0x519802('0x58')]+=0x1),_0x133f41[_0x5cbd87][_0x2d4a7e]['queuecallerabandon']&&(_0x21611a[_0x519802('0x3')][_0x4b320e][_0x519802('0x4')]+=0x1),_0x21611a[_0x519802('0x3')][_0x4b320e][_0x519802('0x3c')]+=moment(_0x133f41[_0x5cbd87][_0x2d4a7e][_0x519802('0x49')])['diff'](moment(_0x133f41[_0x5cbd87][_0x2d4a7e][_0x519802('0x3f')]),_0x519802('0x2e'))||0x0,_0x2d4a7e===_0x133f41[_0x5cbd87][_0x519802('0x5')]-0x1?(_0x21611a[_0x519802('0x3')][_0x4b320e][_0x519802('0x2d')]+=moment(_0x133f41[_0x5cbd87][_0x2d4a7e]['queuecallercompleteAt']||_0x133f41[_0x5cbd87][_0x2d4a7e][_0x519802('0x3a')]||_0x133f41[_0x5cbd87][_0x2d4a7e][_0x519802('0x23')])[_0x519802('0x63')](moment(_0x133f41[_0x5cbd87][_0x2d4a7e][_0x519802('0x3f')]),'seconds')||0x0,_0x21611a[_0x519802('0x3')][_0x4b320e]['total']+=0x1,_0x133f41[_0x5cbd87][_0x2d4a7e][_0x519802('0x5c')]&&(_0x21611a[_0x519802('0x3')][_0x4b320e][_0x519802('0x48')]+=0x1,_0x21611a[_0x519802('0x3')][_0x4b320e][_0x519802('0xb')]+=moment(_0x133f41[_0x5cbd87][_0x2d4a7e]['queuecallercompleteAt'])['diff'](moment(_0x133f41[_0x5cbd87][_0x2d4a7e]['queuecallerleaveAt']),_0x519802('0x2e'))||0x0)):_0x21611a['voiceQueues'][_0x4b320e][_0x519802('0x2d')]+=_0x21611a[_0x519802('0x3')][_0x4b320e][_0x519802('0x3c')]||0x0);}}}return _0x21611a[_0x519802('0x3')];};},Realtime['prototype'][_0x5b0a20('0x5a')]=function(){const _0x28be50=this;return function(_0x561338){const _0x3d8df2=a1092_0x37f5;clearVoiceCallReports(_0x28be50[_0x3d8df2('0x1a')]);if(_0x561338)for(let _0x1e3a26=0x0;_0x1e3a26<_0x561338['length'];_0x1e3a26+=0x1){_0x28be50[_0x3d8df2('0x1a')]['total']+=0x1,_0x28be50[_0x3d8df2('0x1a')][_0x3d8df2('0x2d')]+=_0x561338[_0x1e3a26][_0x3d8df2('0x42')],_0x561338[_0x1e3a26][_0x3d8df2('0x46')]===_0x3d8df2('0xf')&&(_0x28be50[_0x3d8df2('0x1a')]['answered']+=0x1,_0x28be50[_0x3d8df2('0x1a')][_0x3d8df2('0x3c')]+=_0x561338[_0x1e3a26][_0x3d8df2('0x42')]-_0x561338[_0x1e3a26][_0x3d8df2('0x33')]||0x0,_0x28be50['outbound'][_0x3d8df2('0xb')]+=_0x561338[_0x1e3a26][_0x3d8df2('0x33')]);}return _0x28be50[_0x3d8df2('0x1a')];};},Realtime['prototype'][_0x5b0a20('0x5b')]=function(){const _0x5153d8=this;return function(_0x3cda1a){const _0x812d51=a1092_0x37f5;if(_0x3cda1a){freeIsNotKey(_0x3cda1a,_0x5153d8[_0x812d51('0xa')],'name');for(let _0x2e7c26=0x0,_0xfeca83={};_0x2e7c26<_0x3cda1a[_0x812d51('0x5')];_0x2e7c26+=0x1){_0xfeca83=_0x3cda1a[_0x2e7c26],_['isUndefined'](_0x5153d8[_0x812d51('0xa')][_0xfeca83['name']])?_0x5153d8[_0x812d51('0xa')][_0xfeca83[_0x812d51('0x6')]]=new Campaign(_0xfeca83):(_0x5153d8[_0x812d51('0x20')](_0x5153d8[_0x812d51('0xa')][_0xfeca83[_0x812d51('0x6')]],_0xfeca83),_0x5153d8[_0x812d51('0xa')][_0xfeca83[_0x812d51('0x6')]]['dialQueueProject']=_0xfeca83[_0x812d51('0x1c')]?_0xfeca83[_0x812d51('0x1c')][_0x812d51('0x6')]:undefined);}}return _0x5153d8[_0x812d51('0xa')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x10')]=function(){const _0x56cd76=this;return function(_0x32ca2b){const _0x43dc1a=a1092_0x37f5;if(_0x32ca2b){freeIsNotKey(_0x32ca2b,_0x56cd76[_0x43dc1a('0x61')],'id');for(let _0x59804e=0x0,_0x4fc893={};_0x59804e<_0x32ca2b[_0x43dc1a('0x5')];_0x59804e+=0x1){_0x4fc893=_0x32ca2b[_0x59804e],_[_0x43dc1a('0x38')](_0x56cd76[_0x43dc1a('0x61')][_0x4fc893['id']])?_0x56cd76[_0x43dc1a('0x61')][_0x4fc893['id']]=new VoiceExtension(_0x4fc893):_0x56cd76[_0x43dc1a('0x20')](_0x56cd76[_0x43dc1a('0x61')][_0x4fc893['id']],_0x4fc893);}}return _0x56cd76[_0x43dc1a('0x61')];};},Realtime[_0x5b0a20('0x2f')][_0x5b0a20('0x43')]=function(){const _0x88bae9=this;return function(_0x2d697b){const _0x39c157=a1092_0x37f5;clearCampaigns(_0x88bae9[_0x39c157('0xa')]);for(let _0x36265d=0x0;_0x36265d<_0x2d697b['length'];_0x36265d+=0x1){_[_0x39c157('0x67')](_0x88bae9[_0x39c157('0xa')][_0x2d697b[_0x36265d]['name']],_0x2d697b[_0x36265d]);}return _0x88bae9[_0x39c157('0xa')];};},Realtime['prototype']['initFaxAccounts']=function(){const _0x2cf1ba=this;return function(_0x2346b4){const _0x595d8f=a1092_0x37f5;if(_0x2346b4){freeIsNotKey(_0x2346b4,_0x2cf1ba[_0x595d8f('0x57')],'id');for(let _0x45a62a=0x0,_0x1f1e36={};_0x45a62a<_0x2346b4['length'];_0x45a62a+=0x1){_0x1f1e36=_0x2346b4[_0x45a62a],_[_0x595d8f('0x38')](_0x2cf1ba[_0x595d8f('0x57')][_0x1f1e36['id']])?_0x2cf1ba[_0x595d8f('0x57')][_0x1f1e36['id']]=new FaxAccount(_0x1f1e36):_0x2cf1ba[_0x595d8f('0x20')](_0x2cf1ba[_0x595d8f('0x57')][_0x1f1e36['id']],_0x1f1e36);}}return _0x2cf1ba[_0x595d8f('0x57')];};},module[_0x5b0a20('0x39')]=Realtime; \ No newline at end of file diff --git a/server/services/ami/report/index.js b/server/services/ami/report/index.js index 7d3bd6b..23ed2dc 100644 --- a/server/services/ami/report/index.js +++ b/server/services/ami/report/index.js @@ -1 +1 @@ -const a1093_0x1b4f=['length','calleridpreview','custom:voiceQueueReport','format','lastdata','calleridname','../rpc/voiceCallReport','connectedlinename','ANSWERED','queuecallercompleteAt','dialer','attendedtransfer','channel','queuecallerexitAt','substring','transfereelinkedid','../rpc/voiceDialReport','assigned','originatecalleridnum','transfererlinkedid','blindTransfer','prototype','../rpc/memberReport','isNil','agents','voiceAgentReport','monitors','destination','from-sip','exports','custom:voiceCallReport','type','telephones','accountcode','SIP/%s','voiceCallReport','lastapplication','YYYY-MM-DD\x20HH:mm:ss','attendedTransfer','name','indexOf','connectedlinenum','createdAt','transfers','../../../config/environment','destinationchannel','queue','exten','lodash','membername','custom:voiceDialReport','\x22%s\x22\x20<%s>','custom:voiceAgentReport','blindtransfer','../rpc/voiceTransferReport','bind','xdr','isArray','create','find','voiceQueueReport','linkedid','callerid','startsWith','voiceDialReport','xcally-motion-dialer','context','xcally-motion-preview','filename','mobile','../ami','uniqueid','../rpc/voiceAgentReport','interface','calleridnum','lastAssignedTo','findAgent','Local'];(function(_0x37e805,_0x1b4f8e){const _0x58f135=function(_0x275036){while(--_0x275036){_0x37e805['push'](_0x37e805['shift']());}};_0x58f135(++_0x1b4f8e);}(a1093_0x1b4f,0x1cd));const a1093_0x58f1=function(_0x37e805,_0x1b4f8e){_0x37e805=_0x37e805-0x0;let _0x58f135=a1093_0x1b4f[_0x37e805];return _0x58f135;};const _0x5424a4=a1093_0x58f1;'use strict';const _=require(_0x5424a4('0x37')),moment=require('moment'),util=require('util'),config=require(_0x5424a4('0x33')),ami=require(_0x5424a4('0x4d')),RpcVoiceAgentReport=require(_0x5424a4('0x1')),RpcVoiceCallReport=require(_0x5424a4('0xd')),RpcVoiceDialReport=require(_0x5424a4('0x17')),RpcMemberReport=require(_0x5424a4('0x1d')),RpcVoiceQueueReport=require('../rpc/voiceQueueReport'),RpcVoiceRecording=require('../rpc/voiceRecording'),RpcVoiceTransferReport=require(_0x5424a4('0x3d'));function Report(_0x275036){const _0x215ef6=_0x5424a4;this['realtime']=_0x275036,this['agents']=_0x275036['agents'],this[_0x215ef6('0x27')]=_0x275036[_0x215ef6('0x27')];}Report['prototype']['sync']=function(){const _0x4a6eec=_0x5424a4;config['xdr']&&config[_0x4a6eec('0x3f')]['disabled']&&(ami['on'](_0x4a6eec('0x9'),this[_0x4a6eec('0x43')]['bind'](this)),ami['on'](_0x4a6eec('0x25'),this[_0x4a6eec('0x2a')]['bind'](this)),ami['on'](_0x4a6eec('0x3b'),this[_0x4a6eec('0x20')]['bind'](this)),ami['on'](_0x4a6eec('0x39'),this[_0x4a6eec('0x47')][_0x4a6eec('0x3e')](this)),ami['on'](_0x4a6eec('0x3c'),this[_0x4a6eec('0x1b')][_0x4a6eec('0x3e')](this)),ami['on'](_0x4a6eec('0x12'),this[_0x4a6eec('0x2d')][_0x4a6eec('0x3e')](this)));},Report[_0x5424a4('0x1c')][_0x5424a4('0x5')]=function(_0x507559){const _0x36d5d8=_0x5424a4;let _0x22bafd=undefined;_0x22bafd=_[_0x36d5d8('0x42')](this[_0x36d5d8('0x1f')],function(_0x35c0d6){return _0x35c0d6['accountcode']==_0x507559||_0x35c0d6['name']==_0x507559;});if(_[_0x36d5d8('0x1e')](_0x22bafd)){const _0x383bd9=_[_0x36d5d8('0x42')](this[_0x36d5d8('0x27')],function(_0x4917ff){const _0xc6546f=_0x36d5d8;return _0x4917ff[_0xc6546f('0x28')]==_0x507559||_0x4917ff[_0xc6546f('0x2e')]==_0x507559;});_0x383bd9&&(_0x22bafd=_[_0x36d5d8('0x42')](this[_0x36d5d8('0x1f')],function(_0x44e816){const _0x4b01b6=_0x36d5d8;return _0x44e816[_0x4b01b6('0x2')]==util[_0x4b01b6('0xa')](_0x4b01b6('0x29'),_0x383bd9[_0x4b01b6('0x2e')]);}));}return _0x22bafd;},Report['prototype'][_0x5424a4('0x43')]=function(_0x3b43a3){const _0x51bb18=_0x5424a4;for(let _0x490ec2=0x0;_0x490ec2<_0x3b43a3[_0x51bb18('0x7')];_0x490ec2+=0x1){const _0x5282b5=this[_0x51bb18('0x5')](_0x3b43a3[_0x490ec2][_0x51bb18('0x30')]);_0x5282b5&&(_0x3b43a3[_0x490ec2][_0x51bb18('0x28')]=_0x5282b5[_0x51bb18('0x28')],_0x3b43a3[_0x490ec2][_0x51bb18('0x18')]=!![],_0x3b43a3[_0x490ec2][_0x51bb18('0x4')]=_0x5282b5['name'],_0x3b43a3[_0x490ec2]['interface']=_[_0x51bb18('0x1e')](_0x5282b5['interface'])?util['format'](_0x51bb18('0x29'),_0x5282b5[_0x51bb18('0x2e')]):_0x5282b5[_0x51bb18('0x2')],_0x3b43a3[_0x490ec2]['queuecallercomplete']&&(_0x3b43a3[_0x490ec2][_0x51bb18('0x10')]=moment()[_0x51bb18('0xa')]('YYYY-MM-DD\x20HH:mm:ss')),_0x3b43a3[_0x490ec2]['queuecallerexit']&&(_0x3b43a3[_0x490ec2][_0x51bb18('0x14')]=moment()['format'](_0x51bb18('0x2c'))),RpcMemberReport[_0x51bb18('0x43')](_0x3b43a3[_0x490ec2])),RpcVoiceQueueReport['create'](_0x3b43a3[_0x490ec2]);}};function extractCalleridNumber(_0xd04237){const _0x1276ce=_0xd04237['match'](/<(.*?)>/);return _0x1276ce?_0x1276ce[0x1]:_0xd04237;}Report['prototype'][_0x5424a4('0x2a')]=function(_0x12743d){const _0x3b2898=_0x5424a4;_0x12743d['destination']=_0x12743d[_0x3b2898('0x22')]||_0x12743d[_0x3b2898('0x36')];if(_0x12743d[_0x3b2898('0x26')]==_0x3b2898('0x11')){_0x12743d[_0x3b2898('0x2b')]=_0x3b2898('0x35'),_0x12743d[_0x3b2898('0xb')]=_0x12743d[_0x3b2898('0x35')];if(_0x12743d['context']=='from-voip-provider')_0x12743d[_0x3b2898('0x28')]='',_0x12743d[_0x3b2898('0x22')]=extractCalleridNumber(_0x12743d[_0x3b2898('0x45')]);else _0x12743d[_0x3b2898('0x49')]==_0x3b2898('0x23')&&(_0x12743d[_0x3b2898('0x22')]==_0x3b2898('0x4a')?(_0x12743d[_0x3b2898('0x22')]=extractCalleridNumber(_0x12743d[_0x3b2898('0x8')]),_0x12743d['calleridnum']=_0x12743d[_0x3b2898('0x19')],_0x12743d['destinationchannel']=[_0x12743d[_0x3b2898('0x13')],_0x12743d[_0x3b2898('0x13')]=_0x12743d[_0x3b2898('0x34')]][0x0],_0x12743d[_0x3b2898('0x45')]=_0x12743d['calleridpreview']):(_0x12743d[_0x3b2898('0x22')]=_0x12743d[_0x3b2898('0x3')],_0x12743d[_0x3b2898('0x3')]=_0x12743d[_0x3b2898('0x19')],_0x12743d['disposition']==_0x3b2898('0xf')?_0x12743d['accountcode']=_0x12743d[_0x3b2898('0x30')]:_0x12743d[_0x3b2898('0x28')]=''));}else _0x12743d[_0x3b2898('0x45')]=util['format'](_0x3b2898('0x3a'),_0x12743d['calleridname'],_0x12743d['calleridnum']);if(RpcVoiceTransferReport[_0x3b2898('0x32')][_0x12743d[_0x3b2898('0x44')]]){const _0x22c206=RpcVoiceTransferReport[_0x3b2898('0x32')][_0x12743d[_0x3b2898('0x44')]];_0x22c206[_0x3b2898('0x16')]=_0x12743d[_0x3b2898('0x0')],RpcVoiceTransferReport[_0x3b2898('0x1b')](_0x22c206),delete RpcVoiceTransferReport['transfers'][_0x12743d[_0x3b2898('0x44')]];}RpcVoiceCallReport[_0x3b2898('0x41')](_0x12743d);if(_0x12743d['monitor'])for(let _0x5b7a7f=0x0;_0x5b7a7f<_0x12743d[_0x3b2898('0x21')][_0x3b2898('0x7')];_0x5b7a7f+=0x1){_0x12743d['monitorFilename']=_0x12743d[_0x3b2898('0x21')][_0x5b7a7f][_0x3b2898('0x4b')],_0x12743d[_0x3b2898('0x31')]=_0x12743d[_0x3b2898('0x21')][_0x5b7a7f][_0x3b2898('0x31')];if(_0x12743d[_0x3b2898('0x36')]==_0x3b2898('0x4a'))_0x12743d['calleridnum']=_0x12743d[_0x3b2898('0x30')],_0x12743d[_0x3b2898('0xc')]=_0x12743d[_0x3b2898('0xe')],_0x12743d['connectedlinenum']=_0x12743d['accountcode'],_0x12743d['connectedlinename']=_0x12743d[_0x3b2898('0x38')],_0x12743d[_0x3b2898('0x36')]=_0x12743d['originatecalleridnum'];else _0x12743d[_0x3b2898('0x36')]==_0x3b2898('0x48')&&(_0x12743d[_0x3b2898('0x3')]=_0x12743d[_0x3b2898('0x22')],_0x12743d['exten']=_0x12743d[_0x3b2898('0x19')]);RpcVoiceRecording['create'](_0x12743d);}},Report['prototype'][_0x5424a4('0x20')]=function(_0x49f679){const _0x2a5a1f=_0x5424a4;_[_0x2a5a1f('0x40')](_0x49f679)?_0x49f679['forEach'](function(_0x2a0fd9){RpcVoiceAgentReport['create'](_0x2a0fd9);}):RpcVoiceAgentReport['create'](_0x49f679);},Report[_0x5424a4('0x1c')][_0x5424a4('0x47')]=function(_0x4e1315){const _0x11deba=_0x5424a4;RpcVoiceDialReport[_0x11deba('0x41')](_0x4e1315);let _0x10d927=undefined;const _0x5a7658=_0x4e1315[_0x11deba('0x13')];if(_[_0x11deba('0x46')](_0x5a7658,_0x11deba('0x6'))){const _0x293819=_0x5a7658['substring'](_0x5a7658['indexOf']('/')+0x1,_0x5a7658[_0x11deba('0x2f')]('@'));_0x10d927=_[_0x11deba('0x42')](this[_0x11deba('0x1f')],function(_0x2a51da){const _0xda2d0a=_0x11deba;return _0x2a51da[_0xda2d0a('0x4c')]==_0x293819||_0x2a51da['phone']==_0x293819||_0x2a51da[_0xda2d0a('0x28')]==_0x293819;});}else{const _0x36fa1d=_0x5a7658[_0x11deba('0x15')](_0x5a7658['indexOf']('/')+0x1,_0x5a7658['lastIndexOf']('-'));_0x10d927=this[_0x11deba('0x5')](_0x36fa1d);}_0x10d927&&(_0x4e1315[_0x11deba('0x2')]=_[_0x11deba('0x1e')](_0x10d927[_0x11deba('0x2')])?util['format'](_0x11deba('0x29'),_0x10d927[_0x11deba('0x2e')]):_0x10d927[_0x11deba('0x2')],_0x4e1315[_0x11deba('0x38')]=_0x10d927[_0x11deba('0x2e')],_0x4e1315[_0x11deba('0x28')]=_0x10d927[_0x11deba('0x28')],RpcMemberReport[_0x11deba('0x47')](_0x4e1315));},Report['prototype'][_0x5424a4('0x1b')]=function(_0x25b536){const _0x5e1a96=_0x5424a4;RpcVoiceTransferReport[_0x5e1a96('0x32')][_0x25b536[_0x5e1a96('0x1a')]]=_0x25b536;},Report['prototype'][_0x5424a4('0x2d')]=function(_0x2ee377){RpcVoiceTransferReport['attendedTransfer'](_0x2ee377);},module[_0x5424a4('0x24')]=Report; \ No newline at end of file +const a1093_0x4a99=['forEach','length','match','transfers','from-sip','sync','blindtransfer','moment','prototype','uniqueid','voiceAgentReport','create','realtime','../rpc/voiceDialReport','agents','blindTransfer','connectedlinenum','queuecallerexit','xdr','Local','linkedid','disabled','startsWith','callerid','telephones','lastAssignedTo','../rpc/memberReport','voiceCallReport','filename','calleridnum','lastIndexOf','connectedlinename','accountcode','custom:voiceAgentReport','../rpc/voiceCallReport','phone','ANSWERED','queue','voiceDialReport','substring','membername','transfererlinkedid','originatecalleridnum','queuecallerexitAt','calleridname','name','../rpc/voiceQueueReport','voiceQueueReport','lastdata','exports','context','monitors','destination','type','xcally-motion-preview','destinationchannel','custom:voiceQueueReport','transfereelinkedid','indexOf','queuecallercompleteAt','disposition','find','lodash','isNil','\x22%s\x22\x20<%s>','lastapplication','dialer','exten','../rpc/voiceTransferReport','format','xcally-motion-dialer','createdAt','findAgent','YYYY-MM-DD\x20HH:mm:ss','channel','interface','SIP/%s','bind','monitorFilename','attendedTransfer','../../../config/environment'];(function(_0x464e58,_0x4a9966){const _0x23e54a=function(_0x1c18e8){while(--_0x1c18e8){_0x464e58['push'](_0x464e58['shift']());}};_0x23e54a(++_0x4a9966);}(a1093_0x4a99,0x1c3));const a1093_0x23e5=function(_0x464e58,_0x4a9966){_0x464e58=_0x464e58-0x0;let _0x23e54a=a1093_0x4a99[_0x464e58];return _0x23e54a;};const _0x1492a7=a1093_0x23e5;'use strict';const _=require(_0x1492a7('0x10')),moment=require(_0x1492a7('0x2a')),util=require('util'),config=require(_0x1492a7('0x22')),ami=require('../ami'),RpcVoiceAgentReport=require('../rpc/voiceAgentReport'),RpcVoiceCallReport=require(_0x1492a7('0x45')),RpcVoiceDialReport=require(_0x1492a7('0x30')),RpcMemberReport=require(_0x1492a7('0x3d')),RpcVoiceQueueReport=require(_0x1492a7('0x0')),RpcVoiceRecording=require('../rpc/voiceRecording'),RpcVoiceTransferReport=require(_0x1492a7('0x16'));function Report(_0x1c18e8){const _0x27a570=_0x1492a7;this[_0x27a570('0x2f')]=_0x1c18e8,this[_0x27a570('0x31')]=_0x1c18e8[_0x27a570('0x31')],this[_0x27a570('0x3b')]=_0x1c18e8[_0x27a570('0x3b')];}Report[_0x1492a7('0x2b')][_0x1492a7('0x28')]=function(){const _0x49abbb=_0x1492a7;config[_0x49abbb('0x35')]&&config[_0x49abbb('0x35')][_0x49abbb('0x38')]&&(ami['on'](_0x49abbb('0xa'),this[_0x49abbb('0x1')][_0x49abbb('0x1f')](this)),ami['on']('custom:voiceCallReport',this[_0x49abbb('0x3e')][_0x49abbb('0x1f')](this)),ami['on'](_0x49abbb('0x44'),this[_0x49abbb('0x2d')][_0x49abbb('0x1f')](this)),ami['on']('custom:voiceDialReport',this['voiceDialReport'][_0x49abbb('0x1f')](this)),ami['on'](_0x49abbb('0x29'),this[_0x49abbb('0x32')][_0x49abbb('0x1f')](this)),ami['on']('attendedtransfer',this[_0x49abbb('0x21')][_0x49abbb('0x1f')](this)));},Report[_0x1492a7('0x2b')]['findAgent']=function(_0x1cea02){const _0x1de289=_0x1492a7;let _0x5b795e=undefined;_0x5b795e=_[_0x1de289('0xf')](this['agents'],function(_0x1bb428){const _0x21ee9c=_0x1de289;return _0x1bb428[_0x21ee9c('0x43')]==_0x1cea02||_0x1bb428['name']==_0x1cea02;});if(_[_0x1de289('0x11')](_0x5b795e)){const _0x485dcf=_[_0x1de289('0xf')](this[_0x1de289('0x3b')],function(_0x3cfb65){const _0x4c4a50=_0x1de289;return _0x3cfb65[_0x4c4a50('0x43')]==_0x1cea02||_0x3cfb65[_0x4c4a50('0x50')]==_0x1cea02;});_0x485dcf&&(_0x5b795e=_[_0x1de289('0xf')](this[_0x1de289('0x31')],function(_0x3d71db){const _0xabfbbb=_0x1de289;return _0x3d71db[_0xabfbbb('0x1d')]==util[_0xabfbbb('0x17')](_0xabfbbb('0x1e'),_0x485dcf[_0xabfbbb('0x50')]);}));}return _0x5b795e;},Report[_0x1492a7('0x2b')][_0x1492a7('0x1')]=function(_0x3f90cf){const _0xdf33d1=_0x1492a7;for(let _0x2f7308=0x0;_0x2f7308<_0x3f90cf[_0xdf33d1('0x24')];_0x2f7308+=0x1){const _0x3f5965=this['findAgent'](_0x3f90cf[_0x2f7308][_0xdf33d1('0x33')]);_0x3f5965&&(_0x3f90cf[_0x2f7308][_0xdf33d1('0x43')]=_0x3f5965[_0xdf33d1('0x43')],_0x3f90cf[_0x2f7308]['assigned']=!![],_0x3f90cf[_0x2f7308][_0xdf33d1('0x3c')]=_0x3f5965[_0xdf33d1('0x50')],_0x3f90cf[_0x2f7308][_0xdf33d1('0x1d')]=_[_0xdf33d1('0x11')](_0x3f5965[_0xdf33d1('0x1d')])?util[_0xdf33d1('0x17')]('SIP/%s',_0x3f5965[_0xdf33d1('0x50')]):_0x3f5965[_0xdf33d1('0x1d')],_0x3f90cf[_0x2f7308]['queuecallercomplete']&&(_0x3f90cf[_0x2f7308][_0xdf33d1('0xd')]=moment()[_0xdf33d1('0x17')](_0xdf33d1('0x1b'))),_0x3f90cf[_0x2f7308][_0xdf33d1('0x34')]&&(_0x3f90cf[_0x2f7308][_0xdf33d1('0x4e')]=moment()[_0xdf33d1('0x17')](_0xdf33d1('0x1b'))),RpcMemberReport[_0xdf33d1('0x1')](_0x3f90cf[_0x2f7308])),RpcVoiceQueueReport[_0xdf33d1('0x2e')](_0x3f90cf[_0x2f7308]);}};function extractCalleridNumber(_0x420db6){const _0x5e5db6=_0x1492a7,_0x70ce2b=_0x420db6[_0x5e5db6('0x25')](/<(.*?)>/);return _0x70ce2b?_0x70ce2b[0x1]:_0x420db6;}Report[_0x1492a7('0x2b')][_0x1492a7('0x3e')]=function(_0xf729b3){const _0x18dc6c=_0x1492a7;_0xf729b3['destination']=_0xf729b3[_0x18dc6c('0x6')]||_0xf729b3['exten'];if(_0xf729b3[_0x18dc6c('0x7')]==_0x18dc6c('0x14')){_0xf729b3[_0x18dc6c('0x13')]='queue',_0xf729b3[_0x18dc6c('0x2')]=_0xf729b3[_0x18dc6c('0x48')];if(_0xf729b3[_0x18dc6c('0x4')]=='from-voip-provider')_0xf729b3[_0x18dc6c('0x43')]='',_0xf729b3[_0x18dc6c('0x6')]=extractCalleridNumber(_0xf729b3['callerid']);else _0xf729b3[_0x18dc6c('0x4')]==_0x18dc6c('0x27')&&(_0xf729b3['destination']==_0x18dc6c('0x8')?(_0xf729b3['destination']=extractCalleridNumber(_0xf729b3['calleridpreview']),_0xf729b3[_0x18dc6c('0x40')]=_0xf729b3[_0x18dc6c('0x4d')],_0xf729b3[_0x18dc6c('0x9')]=[_0xf729b3[_0x18dc6c('0x1c')],_0xf729b3['channel']=_0xf729b3[_0x18dc6c('0x9')]][0x0],_0xf729b3[_0x18dc6c('0x3a')]=_0xf729b3['calleridpreview']):(_0xf729b3['destination']=_0xf729b3['calleridnum'],_0xf729b3[_0x18dc6c('0x40')]=_0xf729b3[_0x18dc6c('0x4d')],_0xf729b3[_0x18dc6c('0xe')]==_0x18dc6c('0x47')?_0xf729b3[_0x18dc6c('0x43')]=_0xf729b3[_0x18dc6c('0x33')]:_0xf729b3[_0x18dc6c('0x43')]=''));}else _0xf729b3[_0x18dc6c('0x3a')]=util[_0x18dc6c('0x17')](_0x18dc6c('0x12'),_0xf729b3[_0x18dc6c('0x4f')],_0xf729b3[_0x18dc6c('0x40')]);if(RpcVoiceTransferReport[_0x18dc6c('0x26')][_0xf729b3[_0x18dc6c('0x37')]]){const _0x32e821=RpcVoiceTransferReport[_0x18dc6c('0x26')][_0xf729b3['linkedid']];_0x32e821[_0x18dc6c('0xb')]=_0xf729b3[_0x18dc6c('0x2c')],RpcVoiceTransferReport[_0x18dc6c('0x32')](_0x32e821),delete RpcVoiceTransferReport['transfers'][_0xf729b3[_0x18dc6c('0x37')]];}RpcVoiceCallReport['create'](_0xf729b3);if(_0xf729b3['monitor'])for(let _0x4d8493=0x0;_0x4d8493<_0xf729b3[_0x18dc6c('0x5')][_0x18dc6c('0x24')];_0x4d8493+=0x1){_0xf729b3[_0x18dc6c('0x20')]=_0xf729b3[_0x18dc6c('0x5')][_0x4d8493][_0x18dc6c('0x3f')],_0xf729b3[_0x18dc6c('0x19')]=_0xf729b3['monitors'][_0x4d8493][_0x18dc6c('0x19')];if(_0xf729b3[_0x18dc6c('0x15')]==_0x18dc6c('0x8'))_0xf729b3[_0x18dc6c('0x40')]=_0xf729b3[_0x18dc6c('0x33')],_0xf729b3['calleridname']=_0xf729b3[_0x18dc6c('0x42')],_0xf729b3[_0x18dc6c('0x33')]=_0xf729b3[_0x18dc6c('0x43')],_0xf729b3[_0x18dc6c('0x42')]=_0xf729b3[_0x18dc6c('0x4b')],_0xf729b3['exten']=_0xf729b3[_0x18dc6c('0x4d')];else _0xf729b3[_0x18dc6c('0x15')]==_0x18dc6c('0x18')&&(_0xf729b3[_0x18dc6c('0x40')]=_0xf729b3[_0x18dc6c('0x6')],_0xf729b3[_0x18dc6c('0x15')]=_0xf729b3['originatecalleridnum']);RpcVoiceRecording['create'](_0xf729b3);}},Report[_0x1492a7('0x2b')][_0x1492a7('0x2d')]=function(_0x2cc417){const _0x4e9ec7=_0x1492a7;_['isArray'](_0x2cc417)?_0x2cc417[_0x4e9ec7('0x23')](function(_0x559b42){const _0x1ba1d5=_0x4e9ec7;RpcVoiceAgentReport[_0x1ba1d5('0x2e')](_0x559b42);}):RpcVoiceAgentReport[_0x4e9ec7('0x2e')](_0x2cc417);},Report['prototype'][_0x1492a7('0x49')]=function(_0x338c9c){const _0x5b508f=_0x1492a7;RpcVoiceDialReport[_0x5b508f('0x2e')](_0x338c9c);let _0xd146d1=undefined;const _0x1b5da5=_0x338c9c[_0x5b508f('0x1c')];if(_[_0x5b508f('0x39')](_0x1b5da5,_0x5b508f('0x36'))){const _0x3cb9c2=_0x1b5da5[_0x5b508f('0x4a')](_0x1b5da5[_0x5b508f('0xc')]('/')+0x1,_0x1b5da5[_0x5b508f('0xc')]('@'));_0xd146d1=_[_0x5b508f('0xf')](this[_0x5b508f('0x31')],function(_0x20c277){const _0x599c2d=_0x5b508f;return _0x20c277['mobile']==_0x3cb9c2||_0x20c277[_0x599c2d('0x46')]==_0x3cb9c2||_0x20c277[_0x599c2d('0x43')]==_0x3cb9c2;});}else{const _0x2a4eb8=_0x1b5da5['substring'](_0x1b5da5[_0x5b508f('0xc')]('/')+0x1,_0x1b5da5[_0x5b508f('0x41')]('-'));_0xd146d1=this[_0x5b508f('0x1a')](_0x2a4eb8);}_0xd146d1&&(_0x338c9c['interface']=_[_0x5b508f('0x11')](_0xd146d1['interface'])?util['format']('SIP/%s',_0xd146d1[_0x5b508f('0x50')]):_0xd146d1[_0x5b508f('0x1d')],_0x338c9c[_0x5b508f('0x4b')]=_0xd146d1[_0x5b508f('0x50')],_0x338c9c[_0x5b508f('0x43')]=_0xd146d1[_0x5b508f('0x43')],RpcMemberReport[_0x5b508f('0x49')](_0x338c9c));},Report[_0x1492a7('0x2b')]['blindTransfer']=function(_0xff43a4){const _0x5923d0=_0x1492a7;RpcVoiceTransferReport['transfers'][_0xff43a4[_0x5923d0('0x4c')]]=_0xff43a4;},Report[_0x1492a7('0x2b')][_0x1492a7('0x21')]=function(_0x31b7ae){const _0x31ee77=_0x1492a7;RpcVoiceTransferReport[_0x31ee77('0x21')](_0x31b7ae);},module[_0x1492a7('0x3')]=Report; \ No newline at end of file diff --git a/server/services/ami/report/userReport.js b/server/services/ami/report/userReport.js index e461b92..d7b23c8 100644 --- a/server/services/ami/report/userReport.js +++ b/server/services/ami/report/userReport.js @@ -1 +1 @@ -const a1094_0x831e=['catch','state','moment','actionSipShowRegistry','merge','bind','[syncRegistry][UserReport]','name','device','accountcode','../../../config/logger','syncRegistry','toLowerCase','peerstatus','trunk:save','Queue','trunk:%s','syncPeerStatus','telephone:%s','registryentry','exports','updateStatusRealtime','actionDeviceStateList','local','inuse','then','telephones','event','isNotNull','[loopSyncRealTimeShow]','prototype','address','actionSipPeerStatus','actionid','stateRegistry','util','registry','username','isUndefined','trunks','telephone:save','indexOf','resolve','[syncPeerStatus][UserReport]','emit','Local','../../../rediscache','error','loopSyncRealTimeShow','syncDeviceState','status','stateTime','omit','devicestatechange','find','agents','format','substring','peer','toNumber','inspect'];(function(_0x85eb06,_0x831e71){const _0x102545=function(_0x28a7c8){while(--_0x28a7c8){_0x85eb06['push'](_0x85eb06['shift']());}};_0x102545(++_0x831e71);}(a1094_0x831e,0x82));const a1094_0x1025=function(_0x85eb06,_0x831e71){_0x85eb06=_0x85eb06-0x0;let _0x102545=a1094_0x831e[_0x85eb06];return _0x102545;};const _0x463f20=a1094_0x1025;'use strict';const _=require('lodash'),moment=require(_0x463f20('0x37')),util=require(_0x463f20('0x1b')),logger=require(_0x463f20('0x2'))('ami'),ami=require('../ami'),{getSocket}=require(_0x463f20('0x26')),io=getSocket();function UserReport(_0x28a7c8){const _0x9c2890=_0x463f20;return this[_0x9c2890('0x1f')]=_0x28a7c8[_0x9c2890('0x1f')],this[_0x9c2890('0x2f')]=_0x28a7c8[_0x9c2890('0x2f')],this[_0x9c2890('0x12')]=_0x28a7c8[_0x9c2890('0x12')],ami['on'](_0x9c2890('0xb'),this[_0x9c2890('0x3')]['bind'](this)),ami['on'](_0x9c2890('0x1c'),this[_0x9c2890('0x3')][_0x9c2890('0x3a')](this)),ami['on'](_0x9c2890('0x2d'),this[_0x9c2890('0x29')]['bind'](this)),ami['on'](_0x9c2890('0x5'),this[_0x9c2890('0x9')][_0x9c2890('0x3a')](this)),this[_0x9c2890('0x28')](),Promise[_0x9c2890('0x22')]()[_0x9c2890('0x11')](ami[_0x9c2890('0x38')]())[_0x9c2890('0x11')](ami[_0x9c2890('0xe')]())[_0x9c2890('0x11')](ami[_0x9c2890('0x18')]())[_0x9c2890('0x35')](loggerCatch(_0x9c2890('0x15')));}function loggerCatch(_0x1375ce){return function(_0xfd1c2d){const _0x15aaca=a1094_0x1025;logger[_0x15aaca('0x27')](_0x1375ce,util[_0x15aaca('0x34')](_0xfd1c2d,{'showHidden':![],'depth':null}));};}UserReport[_0x463f20('0x16')]['loopSyncRealTimeShow']=function(){setInterval(function(){const _0x30d293=a1094_0x1025;Promise[_0x30d293('0x22')]()[_0x30d293('0x11')](ami[_0x30d293('0x38')]())[_0x30d293('0x11')](ami[_0x30d293('0xe')]())[_0x30d293('0x11')](ami[_0x30d293('0x18')]())['catch'](loggerCatch(_0x30d293('0x15')));},0x32c8);},UserReport[_0x463f20('0x16')][_0x463f20('0x14')]=function(_0x3fafa2){const _0x76de45=_0x463f20;return _0x3fafa2!==null&&!_[_0x76de45('0x1e')](_0x3fafa2);},UserReport[_0x463f20('0x16')][_0x463f20('0x24')]=function(_0x18224f,_0x13e6e9,_0xe1b271){const _0x3a0561=_0x463f20;io['to'](_0x18224f)[_0x3a0561('0x24')](_0x13e6e9,_0xe1b271);},UserReport[_0x463f20('0x16')][_0x463f20('0x3')]=function(_0x57fbb0){const _0x2567d6=_0x463f20;try{if(this[_0x2567d6('0x14')](_0x57fbb0)){const _0x4b574b=_['find'](this[_0x2567d6('0x1f')],{'registry':_0x57fbb0['username']});_0x4b574b&&(_0x57fbb0[_0x2567d6('0x1a')]=_0x57fbb0[_0x2567d6('0x36')],_[_0x2567d6('0x39')](_0x4b574b,_[_0x2567d6('0x2c')](_0x57fbb0,[_0x2567d6('0x13'),_0x2567d6('0x19'),_0x2567d6('0x1d'),_0x2567d6('0x36')])),this[_0x2567d6('0x24')](util[_0x2567d6('0x30')]('trunk:%s',_0x4b574b[_0x2567d6('0x3c')]),_0x2567d6('0x6'),_0x4b574b));}}catch(_0x3a480e){logger[_0x2567d6('0x27')](_0x2567d6('0x3b'),util[_0x2567d6('0x34')](_0x3a480e,{'showHidden':![],'depth':null}));}},UserReport[_0x463f20('0x16')]['syncDeviceState']=function(_0x397722){const _0x10d718=_0x463f20;try{if(this[_0x10d718('0x14')](_0x397722)){if(this[_0x10d718('0x2f')][_0x397722[_0x10d718('0x0')]])(!this['agents'][_0x397722[_0x10d718('0x0')]][_0x10d718('0xf')]||_0x397722['state'][_0x10d718('0x4')]()==_0x10d718('0x10'))&&(this['agents'][_0x397722[_0x10d718('0x0')]][_0x10d718('0xf')]=![],this['agents'][_0x397722[_0x10d718('0x0')]][_0x10d718('0x36')]!==_0x397722['state'][_0x10d718('0x4')]()&&(this[_0x10d718('0x2f')][_0x397722['device']][_0x10d718('0x2b')]=_[_0x10d718('0x33')](moment()[_0x10d718('0x30')]('x'))),this['agents'][_0x397722[_0x10d718('0x0')]]['state']=_0x397722[_0x10d718('0x36')]['toLowerCase'](),this[_0x10d718('0x2f')][_0x397722[_0x10d718('0x0')]]['updateStatusRealtime'](_0x397722));else{if(this['telephones'][_0x397722[_0x10d718('0x0')]])this['telephones'][_0x397722[_0x10d718('0x0')]][_0x10d718('0x36')]!==_0x397722[_0x10d718('0x36')][_0x10d718('0x4')]()&&(this['telephones'][_0x397722['device']]['stateTime']=_[_0x10d718('0x33')](moment()[_0x10d718('0x30')]('x'))),this[_0x10d718('0x12')][_0x397722[_0x10d718('0x0')]]['state']=_0x397722[_0x10d718('0x36')][_0x10d718('0x4')](),this[_0x10d718('0x24')](util[_0x10d718('0x30')](_0x10d718('0xa'),this[_0x10d718('0x12')][_0x397722[_0x10d718('0x0')]][_0x10d718('0x3c')]),_0x10d718('0x20'),this[_0x10d718('0x12')][_0x397722['device']]);else{if(this[_0x10d718('0x1f')][_0x397722['device']])this[_0x10d718('0x1f')][_0x397722[_0x10d718('0x0')]][_0x10d718('0x36')]!==_0x397722[_0x10d718('0x36')][_0x10d718('0x4')]()&&(this[_0x10d718('0x1f')][_0x397722[_0x10d718('0x0')]]['stateTime']=_[_0x10d718('0x33')](moment()[_0x10d718('0x30')]('x'))),this[_0x10d718('0x1f')][_0x397722['device']][_0x10d718('0x36')]=_0x397722[_0x10d718('0x36')][_0x10d718('0x4')](),this[_0x10d718('0x24')](util['format'](_0x10d718('0x8'),this[_0x10d718('0x1f')][_0x397722['device']][_0x10d718('0x3c')]),_0x10d718('0x6'),this[_0x10d718('0x1f')][_0x397722[_0x10d718('0x0')]]);else{if(_['startsWith'](_0x397722[_0x10d718('0x0')],_0x10d718('0x7'))){}else{if(_['startsWith'](_0x397722[_0x10d718('0x0')],_0x10d718('0x25'))){const _0x590da3=_0x397722[_0x10d718('0x0')],_0x51a2ec=_0x590da3[_0x10d718('0x31')](_0x590da3[_0x10d718('0x21')]('/')+0x1,_0x590da3['indexOf']('@')),_0x158138=_[_0x10d718('0x2e')](this['agents'],function(_0x182461){const _0x4d6966=_0x10d718;return _0x182461['mobile']==_0x51a2ec||_0x182461['phone']==_0x51a2ec||_0x182461[_0x4d6966('0x1')]==_0x51a2ec;});_0x158138&&(_0x158138[_0x10d718('0x36')]!==_0x397722[_0x10d718('0x36')][_0x10d718('0x4')]()&&(_0x158138[_0x10d718('0x2b')]=_[_0x10d718('0x33')](moment()[_0x10d718('0x30')]('x'))),_0x158138['state']=_0x397722[_0x10d718('0x36')][_0x10d718('0x4')](),_0x158138['local']=!![],_0x158138['updateStatusRealtime'](_0x397722));}else{}}}}}}}catch(_0x24815e){logger['error']('[syncDeviceState][UserReport]',util[_0x10d718('0x34')](_0x24815e,{'showHidden':![],'depth':null}));}},UserReport['prototype'][_0x463f20('0x9')]=function(_0x49954e){const _0xa7a96e=_0x463f20;try{if(this[_0xa7a96e('0x14')](_0x49954e)&&this['isNotNull'](_0x49954e[_0xa7a96e('0x5')])){if(this[_0xa7a96e('0x2f')][_0x49954e[_0xa7a96e('0x32')]])(!this[_0xa7a96e('0x2f')][_0x49954e['peer']][_0xa7a96e('0xf')]||_0x49954e[_0xa7a96e('0x5')][_0xa7a96e('0x4')]()=='registered')&&(this['agents'][_0x49954e[_0xa7a96e('0x32')]]['local']=![],this[_0xa7a96e('0x2f')][_0x49954e['peer']][_0xa7a96e('0x2a')]=_0x49954e[_0xa7a96e('0x5')][_0xa7a96e('0x4')](),this[_0xa7a96e('0x2f')][_0x49954e[_0xa7a96e('0x32')]][_0xa7a96e('0x17')]=_0x49954e[_0xa7a96e('0x17')],this['agents'][_0x49954e[_0xa7a96e('0x32')]][_0xa7a96e('0xd')](_0x49954e));else{if(this[_0xa7a96e('0x12')][_0x49954e[_0xa7a96e('0x32')]])this[_0xa7a96e('0x12')][_0x49954e['peer']][_0xa7a96e('0x2a')]=_0x49954e[_0xa7a96e('0x5')][_0xa7a96e('0x4')](),this[_0xa7a96e('0x12')][_0x49954e[_0xa7a96e('0x32')]]['address']=_0x49954e[_0xa7a96e('0x17')],this['emit'](util[_0xa7a96e('0x30')](_0xa7a96e('0xa'),this[_0xa7a96e('0x12')][_0x49954e[_0xa7a96e('0x32')]]['name']),_0xa7a96e('0x20'),this['telephones'][_0x49954e['peer']]);else{if(this['trunks'][_0x49954e[_0xa7a96e('0x32')]])this[_0xa7a96e('0x1f')][_0x49954e['peer']][_0xa7a96e('0x2a')]=_0x49954e[_0xa7a96e('0x5')][_0xa7a96e('0x4')](),this[_0xa7a96e('0x1f')][_0x49954e[_0xa7a96e('0x32')]]['address']=_0x49954e['address'],this[_0xa7a96e('0x24')](util[_0xa7a96e('0x30')]('trunk:%s',this[_0xa7a96e('0x1f')][_0x49954e[_0xa7a96e('0x32')]][_0xa7a96e('0x3c')]),_0xa7a96e('0x6'),this[_0xa7a96e('0x1f')][_0x49954e['peer']]);else{}}}}}catch(_0x2da65d){logger['error'](_0xa7a96e('0x23'),util['inspect'](_0x2da65d,{'showHidden':![],'depth':null}));}},module[_0x463f20('0xc')]=UserReport; \ No newline at end of file +const a1094_0x5e8e=['lodash','toLowerCase','find','ami','emit','name','resolve','merge','Local','registry','exports','syncDeviceState','../ami','bind','error','accountcode','omit','telephone:save','actionSipShowRegistry','username','agents','util','prototype','indexOf','../../../rediscache','trunk:%s','phone','actionSipPeerStatus','toNumber','peerstatus','[loopSyncRealTimeShow]','telephones','local','format','[syncRegistry][UserReport]','state','stateTime','stateRegistry','syncRegistry','address','status','../../../config/logger','inspect','device','startsWith','telephone:%s','substring','catch','trunk:save','actionid','inuse','event','peer','updateStatusRealtime','then','actionDeviceStateList','isNotNull','trunks','[syncDeviceState][UserReport]'];(function(_0x1666b4,_0x5e8e01){const _0x140211=function(_0x389f18){while(--_0x389f18){_0x1666b4['push'](_0x1666b4['shift']());}};_0x140211(++_0x5e8e01);}(a1094_0x5e8e,0xe5));const a1094_0x1402=function(_0x1666b4,_0x5e8e01){_0x1666b4=_0x1666b4-0x0;let _0x140211=a1094_0x5e8e[_0x1666b4];return _0x140211;};const _0x416ac4=a1094_0x1402;'use strict';const _=require(_0x416ac4('0x7')),moment=require('moment'),util=require(_0x416ac4('0x1c')),logger=require(_0x416ac4('0x30'))(_0x416ac4('0xa')),ami=require(_0x416ac4('0x13')),{getSocket}=require(_0x416ac4('0x1f')),io=getSocket();function UserReport(_0x389f18){const _0x5ddbaa=_0x416ac4;return this[_0x5ddbaa('0x5')]=_0x389f18[_0x5ddbaa('0x5')],this['agents']=_0x389f18[_0x5ddbaa('0x1b')],this[_0x5ddbaa('0x26')]=_0x389f18[_0x5ddbaa('0x26')],ami['on']('registryentry',this[_0x5ddbaa('0x2d')]['bind'](this)),ami['on'](_0x5ddbaa('0x10'),this[_0x5ddbaa('0x2d')][_0x5ddbaa('0x14')](this)),ami['on']('devicestatechange',this[_0x5ddbaa('0x12')][_0x5ddbaa('0x14')](this)),ami['on']('peerstatus',this['syncPeerStatus'][_0x5ddbaa('0x14')](this)),this['loopSyncRealTimeShow'](),Promise['resolve']()[_0x5ddbaa('0x2')](ami['actionSipShowRegistry']())[_0x5ddbaa('0x2')](ami[_0x5ddbaa('0x3')]())[_0x5ddbaa('0x2')](ami[_0x5ddbaa('0x22')]())[_0x5ddbaa('0x36')](loggerCatch(_0x5ddbaa('0x25')));}function loggerCatch(_0x24f969){return function(_0x7a483f){const _0x28473c=a1094_0x1402;logger[_0x28473c('0x15')](_0x24f969,util[_0x28473c('0x31')](_0x7a483f,{'showHidden':![],'depth':null}));};}UserReport[_0x416ac4('0x1d')]['loopSyncRealTimeShow']=function(){setInterval(function(){const _0x37b7ad=a1094_0x1402;Promise[_0x37b7ad('0xd')]()[_0x37b7ad('0x2')](ami[_0x37b7ad('0x19')]())[_0x37b7ad('0x2')](ami[_0x37b7ad('0x3')]())[_0x37b7ad('0x2')](ami[_0x37b7ad('0x22')]())['catch'](loggerCatch(_0x37b7ad('0x25')));},0x32c8);},UserReport[_0x416ac4('0x1d')][_0x416ac4('0x4')]=function(_0x26cf4b){return _0x26cf4b!==null&&!_['isUndefined'](_0x26cf4b);},UserReport[_0x416ac4('0x1d')][_0x416ac4('0xb')]=function(_0x3a7371,_0x299817,_0x3fb519){const _0x3527b2=_0x416ac4;io['to'](_0x3a7371)[_0x3527b2('0xb')](_0x299817,_0x3fb519);},UserReport['prototype'][_0x416ac4('0x2d')]=function(_0x258211){const _0x165c3e=_0x416ac4;try{if(this[_0x165c3e('0x4')](_0x258211)){const _0x14fa15=_[_0x165c3e('0x9')](this[_0x165c3e('0x5')],{'registry':_0x258211['username']});_0x14fa15&&(_0x258211[_0x165c3e('0x2c')]=_0x258211['state'],_[_0x165c3e('0xe')](_0x14fa15,_[_0x165c3e('0x17')](_0x258211,[_0x165c3e('0x3a'),_0x165c3e('0x38'),_0x165c3e('0x1a'),_0x165c3e('0x2a')])),this[_0x165c3e('0xb')](util['format'](_0x165c3e('0x20'),_0x14fa15['name']),_0x165c3e('0x37'),_0x14fa15));}}catch(_0x3c3a20){logger['error'](_0x165c3e('0x29'),util[_0x165c3e('0x31')](_0x3c3a20,{'showHidden':![],'depth':null}));}},UserReport['prototype'][_0x416ac4('0x12')]=function(_0x51045f){const _0x289d38=_0x416ac4;try{if(this['isNotNull'](_0x51045f)){if(this[_0x289d38('0x1b')][_0x51045f[_0x289d38('0x32')]])(!this[_0x289d38('0x1b')][_0x51045f[_0x289d38('0x32')]][_0x289d38('0x27')]||_0x51045f['state'][_0x289d38('0x8')]()==_0x289d38('0x39'))&&(this['agents'][_0x51045f[_0x289d38('0x32')]][_0x289d38('0x27')]=![],this[_0x289d38('0x1b')][_0x51045f[_0x289d38('0x32')]][_0x289d38('0x2a')]!==_0x51045f[_0x289d38('0x2a')][_0x289d38('0x8')]()&&(this[_0x289d38('0x1b')][_0x51045f['device']][_0x289d38('0x2b')]=_[_0x289d38('0x23')](moment()[_0x289d38('0x28')]('x'))),this['agents'][_0x51045f['device']][_0x289d38('0x2a')]=_0x51045f[_0x289d38('0x2a')][_0x289d38('0x8')](),this[_0x289d38('0x1b')][_0x51045f[_0x289d38('0x32')]]['updateStatusRealtime'](_0x51045f));else{if(this[_0x289d38('0x26')][_0x51045f[_0x289d38('0x32')]])this[_0x289d38('0x26')][_0x51045f['device']][_0x289d38('0x2a')]!==_0x51045f['state'][_0x289d38('0x8')]()&&(this[_0x289d38('0x26')][_0x51045f[_0x289d38('0x32')]][_0x289d38('0x2b')]=_[_0x289d38('0x23')](moment()[_0x289d38('0x28')]('x'))),this[_0x289d38('0x26')][_0x51045f['device']][_0x289d38('0x2a')]=_0x51045f[_0x289d38('0x2a')][_0x289d38('0x8')](),this[_0x289d38('0xb')](util[_0x289d38('0x28')]('telephone:%s',this['telephones'][_0x51045f[_0x289d38('0x32')]][_0x289d38('0xc')]),_0x289d38('0x18'),this[_0x289d38('0x26')][_0x51045f[_0x289d38('0x32')]]);else{if(this[_0x289d38('0x5')][_0x51045f[_0x289d38('0x32')]])this['trunks'][_0x51045f[_0x289d38('0x32')]]['state']!==_0x51045f[_0x289d38('0x2a')][_0x289d38('0x8')]()&&(this[_0x289d38('0x5')][_0x51045f['device']]['stateTime']=_['toNumber'](moment()[_0x289d38('0x28')]('x'))),this[_0x289d38('0x5')][_0x51045f[_0x289d38('0x32')]][_0x289d38('0x2a')]=_0x51045f[_0x289d38('0x2a')][_0x289d38('0x8')](),this[_0x289d38('0xb')](util[_0x289d38('0x28')](_0x289d38('0x20'),this['trunks'][_0x51045f['device']]['name']),'trunk:save',this['trunks'][_0x51045f['device']]);else{if(_[_0x289d38('0x33')](_0x51045f['device'],'Queue')){}else{if(_[_0x289d38('0x33')](_0x51045f[_0x289d38('0x32')],_0x289d38('0xf'))){const _0x589de6=_0x51045f[_0x289d38('0x32')],_0x549e53=_0x589de6[_0x289d38('0x35')](_0x589de6[_0x289d38('0x1e')]('/')+0x1,_0x589de6['indexOf']('@')),_0x110422=_[_0x289d38('0x9')](this[_0x289d38('0x1b')],function(_0x12f325){const _0x5bdaa0=_0x289d38;return _0x12f325['mobile']==_0x549e53||_0x12f325[_0x5bdaa0('0x21')]==_0x549e53||_0x12f325[_0x5bdaa0('0x16')]==_0x549e53;});_0x110422&&(_0x110422[_0x289d38('0x2a')]!==_0x51045f[_0x289d38('0x2a')][_0x289d38('0x8')]()&&(_0x110422[_0x289d38('0x2b')]=_[_0x289d38('0x23')](moment()[_0x289d38('0x28')]('x'))),_0x110422[_0x289d38('0x2a')]=_0x51045f[_0x289d38('0x2a')][_0x289d38('0x8')](),_0x110422['local']=!![],_0x110422[_0x289d38('0x1')](_0x51045f));}else{}}}}}}}catch(_0x1eaeac){logger['error'](_0x289d38('0x6'),util[_0x289d38('0x31')](_0x1eaeac,{'showHidden':![],'depth':null}));}},UserReport[_0x416ac4('0x1d')]['syncPeerStatus']=function(_0x590844){const _0x5b4157=_0x416ac4;try{if(this[_0x5b4157('0x4')](_0x590844)&&this[_0x5b4157('0x4')](_0x590844['peerstatus'])){if(this[_0x5b4157('0x1b')][_0x590844[_0x5b4157('0x0')]])(!this[_0x5b4157('0x1b')][_0x590844['peer']][_0x5b4157('0x27')]||_0x590844[_0x5b4157('0x24')][_0x5b4157('0x8')]()=='registered')&&(this['agents'][_0x590844[_0x5b4157('0x0')]][_0x5b4157('0x27')]=![],this[_0x5b4157('0x1b')][_0x590844['peer']][_0x5b4157('0x2f')]=_0x590844['peerstatus'][_0x5b4157('0x8')](),this[_0x5b4157('0x1b')][_0x590844[_0x5b4157('0x0')]][_0x5b4157('0x2e')]=_0x590844[_0x5b4157('0x2e')],this[_0x5b4157('0x1b')][_0x590844['peer']][_0x5b4157('0x1')](_0x590844));else{if(this[_0x5b4157('0x26')][_0x590844[_0x5b4157('0x0')]])this['telephones'][_0x590844[_0x5b4157('0x0')]][_0x5b4157('0x2f')]=_0x590844[_0x5b4157('0x24')][_0x5b4157('0x8')](),this[_0x5b4157('0x26')][_0x590844[_0x5b4157('0x0')]][_0x5b4157('0x2e')]=_0x590844[_0x5b4157('0x2e')],this[_0x5b4157('0xb')](util['format'](_0x5b4157('0x34'),this[_0x5b4157('0x26')][_0x590844['peer']]['name']),_0x5b4157('0x18'),this[_0x5b4157('0x26')][_0x590844[_0x5b4157('0x0')]]);else{if(this[_0x5b4157('0x5')][_0x590844[_0x5b4157('0x0')]])this[_0x5b4157('0x5')][_0x590844[_0x5b4157('0x0')]]['status']=_0x590844[_0x5b4157('0x24')][_0x5b4157('0x8')](),this[_0x5b4157('0x5')][_0x590844[_0x5b4157('0x0')]]['address']=_0x590844[_0x5b4157('0x2e')],this[_0x5b4157('0xb')](util[_0x5b4157('0x28')](_0x5b4157('0x20'),this[_0x5b4157('0x5')][_0x590844['peer']]['name']),_0x5b4157('0x37'),this[_0x5b4157('0x5')][_0x590844[_0x5b4157('0x0')]]);else{}}}}}catch(_0xe85c37){logger[_0x5b4157('0x15')]('[syncPeerStatus][UserReport]',util[_0x5b4157('0x31')](_0xe85c37,{'showHidden':![],'depth':null}));}},module[_0x416ac4('0x11')]=UserReport; \ No newline at end of file diff --git a/server/services/ami/report/voiceAgentReport.js b/server/services/ami/report/voiceAgentReport.js index a288f82..9001340 100644 --- a/server/services/ami/report/voiceAgentReport.js +++ b/server/services/ami/report/voiceAgentReport.js @@ -1 +1 @@ -const a1095_0x559f=['bridgepvtcallid','transfer','answeredelsewheremembername','attendedtransfer','transfereeuniqueid','channels','merge','moment','destuniqueid','answeredelsewheredestinationuniqueid','acw','substring','queuecallerabandon','connectedlinename','rtpaudioqosrttbridged','rtpaudioqoslossbridged','[syncAgentConnect][VoiceAgentReport]','called','syncQueueCallerAbandon','isUndefined','../ami','YYYY-MM-DD\x20HH:mm:ss','syncBlindTransfer','privilege','[syncQueueCallerAbandon][VoiceAgentReport]','[syncVarSet][VoiceAgentReport]','complete','membercalls','custom:agentansweredelsewhere','[syncMusicOnHoldStop][VoiceAgentReport]','syncMusicOnHoldStop','syncAgentRingNoAnswer','variables','syncAgentComplete','musiconholdstop','user:%s','origtransfereruniqueid','sipcallid','memberpenalty','syncVarSet','isNil','agentcompleteAt','[syncMusicOnHoldStart][VoiceAgentReport]','holdtime','undefined','agentringnoanswerAt','memberdynamic','addVariable','error','omit','agentconnectAt','connectedlinenum','emit','memberinterface','[syncAgentRingNoAnswer][VoiceAgentReport]','interface','destconnectedlinenum','rtpaudioqosjitter','rtpaudioqosjitterbridged','rtpaudioqos','custom:voiceAgentReport','membername','abandoned','queue','lodash','channel','acwtime','rtpaudioqosrtt','memberlastcall','[syncHangup][VoiceAgentReport]','destchannelstate','prototype','custom:agentcalled','inspect','secondtransfereruniqueid','syncAttendedTransfer','util','custom:agentconnect','agent','agentcomplete','inbound','sipuri','pick','../../../rediscache','[syncAttendedTransfer][VoiceAgentReport]','[syncAgentCalled][VoiceAgentReport]','event','custom:agentqueuecallerabandon','bind','format','agentacw','variable','seconds','uniqueid','exports','lastIndexOf','isNotNull','reason','agents','agentringnoanswer','voiceQueues','syncMusicOnHoldStart','varset','includes','rtpaudioqosbridged','lastevent','answered_elsewhere','connect','value','onhold','custom:agentcomplete','syncAgentCalled','syncHangup','diff','talktime','musiconholdstart'];(function(_0x1fbcdc,_0x559f68){const _0x4c68c3=function(_0x3b0f85){while(--_0x3b0f85){_0x1fbcdc['push'](_0x1fbcdc['shift']());}};_0x4c68c3(++_0x559f68);}(a1095_0x559f,0x1e5));const a1095_0x4c68=function(_0x1fbcdc,_0x559f68){_0x1fbcdc=_0x1fbcdc-0x0;let _0x4c68c3=a1095_0x559f[_0x1fbcdc];return _0x4c68c3;};const _0x30d83b=a1095_0x4c68;'use strict';const _=require(_0x30d83b('0x2b')),moment=require(_0x30d83b('0x66')),util=require(_0x30d83b('0x37')),logger=require('../../../config/logger')('ami'),ami=require(_0x30d83b('0x73')),{getSocket}=require(_0x30d83b('0x3e')),io=getSocket();function VoiceAgentReport(_0x3b0f85){const _0x1b2935=_0x30d83b;this[_0x1b2935('0x64')]={},this[_0x1b2935('0x4f')]=_0x3b0f85[_0x1b2935('0x4f')],this[_0x1b2935('0x4d')]=_0x3b0f85[_0x1b2935('0x4d')],this['variables']={},ami['on']('agentcalled',this[_0x1b2935('0x5a')]['bind'](this)),ami['on']('agentconnect',this['syncAgentConnect'][_0x1b2935('0x43')](this)),ami['on'](_0x1b2935('0x4e'),this['syncAgentRingNoAnswer'][_0x1b2935('0x43')](this)),ami['on'](_0x1b2935('0x6b'),this[_0x1b2935('0x71')][_0x1b2935('0x43')](this)),ami['on'](_0x1b2935('0x3a'),this['syncAgentComplete'][_0x1b2935('0x43')](this)),ami['on'](_0x1b2935('0x51'),this[_0x1b2935('0x12')][_0x1b2935('0x43')](this)),ami['on']('hangup',this[_0x1b2935('0x5b')][_0x1b2935('0x43')](this)),ami['on'](_0x1b2935('0x5e'),this[_0x1b2935('0x50')][_0x1b2935('0x43')](this)),ami['on'](_0x1b2935('0xd'),this[_0x1b2935('0x9')][_0x1b2935('0x43')](this)),ami['on'](_0x1b2935('0x62'),this[_0x1b2935('0x36')][_0x1b2935('0x43')](this)),ami['on']('blindtransfer',this[_0x1b2935('0x1')][_0x1b2935('0x43')](this));}VoiceAgentReport['prototype'][_0x30d83b('0x1f')]=function(_0x40d1f1,_0x1c6828,_0x481058){const _0x5cbdb0=_0x30d83b;io['to'](_0x40d1f1)[_0x5cbdb0('0x1f')](_0x1c6828,_0x481058);},VoiceAgentReport[_0x30d83b('0x32')][_0x30d83b('0x4b')]=function(_0x42d1d7){return _0x42d1d7!==null&&!_['isUndefined'](_0x42d1d7);},VoiceAgentReport[_0x30d83b('0x32')][_0x30d83b('0x5a')]=function(_0x44e8e9){const _0x24ed86=_0x30d83b;try{this[_0x24ed86('0x4b')](_0x44e8e9)&&(_[_0x24ed86('0x72')](this[_0x24ed86('0x64')][_0x44e8e9[_0x24ed86('0x48')]])&&(this[_0x24ed86('0x64')][_0x44e8e9[_0x24ed86('0x48')]]={}),_[_0x24ed86('0x72')](this[_0x24ed86('0x64')][_0x44e8e9[_0x24ed86('0x48')]][_0x44e8e9[_0x24ed86('0x67')]])&&(this[_0x24ed86('0x64')][_0x44e8e9[_0x24ed86('0x48')]][_0x44e8e9['destuniqueid']]={'agentcalledAt':moment()[_0x24ed86('0x44')](_0x24ed86('0x0')),'lastevent':_0x24ed86('0x70'),'variables':this['variables'][_0x44e8e9[_0x24ed86('0x48')]],'type':this[_0x24ed86('0x4f')][_0x44e8e9[_0x24ed86('0x2a')]]?this[_0x24ed86('0x4f')][_0x44e8e9[_0x24ed86('0x2a')]]['type']||_0x24ed86('0x3b'):_0x24ed86('0x3b')}),_[_0x24ed86('0x65')](this[_0x24ed86('0x64')][_0x44e8e9['uniqueid']][_0x44e8e9[_0x24ed86('0x67')]],_[_0x24ed86('0x1c')](_0x44e8e9,[_0x24ed86('0x41'),_0x24ed86('0x2')])),ami[_0x24ed86('0x1f')](_0x24ed86('0x33'),this[_0x24ed86('0x64')][_0x44e8e9['uniqueid']][_0x44e8e9[_0x24ed86('0x67')]]),this[_0x24ed86('0x1f')](util[_0x24ed86('0x44')]('user:%s',_0x44e8e9['membername']),'user:called',this[_0x24ed86('0x64')][_0x44e8e9[_0x24ed86('0x48')]][_0x44e8e9[_0x24ed86('0x67')]]));}catch(_0x8b3b39){logger[_0x24ed86('0x1b')](_0x24ed86('0x40'),util[_0x24ed86('0x34')](_0x8b3b39,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x30d83b('0x32')]['syncAgentConnect']=function(_0x23789a){const _0xabee0a=_0x30d83b;try{if(this[_0xabee0a('0x4b')](_0x23789a)){if(this['channels'][_0x23789a['uniqueid']])for(const _0x903d57 in this[_0xabee0a('0x64')][_0x23789a['uniqueid']]){if(typeof this[_0xabee0a('0x64')][_0x23789a['uniqueid']][_0x903d57]!==_0xabee0a('0x17')){if(_0x23789a['destuniqueid']===_0x903d57)this[_0xabee0a('0x64')][_0x23789a[_0xabee0a('0x48')]][_0x903d57][_0xabee0a('0x1d')]=moment()[_0xabee0a('0x44')](_0xabee0a('0x0')),this[_0xabee0a('0x64')][_0x23789a[_0xabee0a('0x48')]][_0x903d57][_0xabee0a('0x54')]=_0xabee0a('0x56'),this[_0xabee0a('0x64')][_0x23789a['uniqueid']][_0x903d57][_0xabee0a('0x16')]=_0x23789a[_0xabee0a('0x16')],this[_0xabee0a('0x64')][_0x23789a[_0xabee0a('0x48')]][_0x903d57][_0xabee0a('0x1e')]=_0x23789a[_0xabee0a('0x1e')],this['channels'][_0x23789a['uniqueid']][_0x903d57][_0xabee0a('0x6c')]=_0x23789a[_0xabee0a('0x6c')],this[_0xabee0a('0x64')][_0x23789a[_0xabee0a('0x48')]][_0x903d57]['destchannelstate']=_0x23789a[_0xabee0a('0x31')],this['channels'][_0x23789a[_0xabee0a('0x48')]][_0x903d57]['destchannelstatedesc']=_0x23789a['destchannelstatedesc'],_[_0xabee0a('0x65')](this['agents'][_0x23789a[_0xabee0a('0x22')]],_[_0xabee0a('0x3d')](_0x23789a,[_0xabee0a('0x2a'),_0xabee0a('0x23')])),this[_0xabee0a('0x1f')](util[_0xabee0a('0x44')](_0xabee0a('0xe'),_0x23789a['membername']),'user:agentconnect',this['channels'][_0x23789a[_0xabee0a('0x48')]][_0x23789a['destuniqueid']]),ami[_0xabee0a('0x1f')](_0xabee0a('0x38'),this['channels'][_0x23789a[_0xabee0a('0x48')]][_0x903d57]);else!this['channels'][_0x23789a[_0xabee0a('0x48')]][_0x903d57][_0xabee0a('0x4e')]&&!this[_0xabee0a('0x64')][_0x23789a[_0xabee0a('0x48')]][_0x903d57][_0xabee0a('0x3a')]&&(this[_0xabee0a('0x64')][_0x23789a['uniqueid']][_0x903d57][_0xabee0a('0x4e')]=!![],this[_0xabee0a('0x64')][_0x23789a['uniqueid']][_0x903d57][_0xabee0a('0x18')]=moment()[_0xabee0a('0x44')]('YYYY-MM-DD\x20HH:mm:ss'),this['channels'][_0x23789a[_0xabee0a('0x48')]][_0x903d57][_0xabee0a('0x4c')]=_0xabee0a('0x55'),this['channels'][_0x23789a[_0xabee0a('0x48')]][_0x903d57][_0xabee0a('0x54')]=_0xabee0a('0x55'),this['channels'][_0x23789a[_0xabee0a('0x48')]][_0x903d57][_0xabee0a('0x68')]=_0x23789a['destuniqueid'],this[_0xabee0a('0x64')][_0x23789a[_0xabee0a('0x48')]][_0x903d57][_0xabee0a('0x61')]=_0x23789a[_0xabee0a('0x28')],ami['emit'](_0xabee0a('0x7'),this[_0xabee0a('0x64')][_0x23789a[_0xabee0a('0x48')]][_0x903d57]));}}}}catch(_0x2f774d){logger[_0xabee0a('0x1b')](_0xabee0a('0x6f'),util[_0xabee0a('0x34')](_0x2f774d,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x30d83b('0x32')][_0x30d83b('0xa')]=function(_0x25892d){const _0x47ce90=_0x30d83b;try{this[_0x47ce90('0x4b')](_0x25892d)&&(this[_0x47ce90('0x64')][_0x25892d[_0x47ce90('0x48')]]&&this['channels'][_0x25892d[_0x47ce90('0x48')]][_0x25892d['destuniqueid']]&&(this['channels'][_0x25892d[_0x47ce90('0x48')]][_0x25892d[_0x47ce90('0x67')]][_0x47ce90('0x4e')]=!![],this[_0x47ce90('0x64')][_0x25892d['uniqueid']][_0x25892d[_0x47ce90('0x67')]][_0x47ce90('0x18')]=moment()[_0x47ce90('0x44')](_0x47ce90('0x0')),this[_0x47ce90('0x64')][_0x25892d[_0x47ce90('0x48')]][_0x25892d[_0x47ce90('0x67')]]['reason']='rejected',this[_0x47ce90('0x64')][_0x25892d[_0x47ce90('0x48')]][_0x25892d['destuniqueid']][_0x47ce90('0x54')]='rejected',ami[_0x47ce90('0x1f')]('custom:agentringnoanswer',this[_0x47ce90('0x64')][_0x25892d[_0x47ce90('0x48')]][_0x25892d[_0x47ce90('0x67')]])));}catch(_0xe42e4b){logger[_0x47ce90('0x1b')](_0x47ce90('0x21'),util[_0x47ce90('0x34')](_0xe42e4b,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x30d83b('0x32')][_0x30d83b('0x71')]=function(_0x1a7ae9){const _0x2a843e=_0x30d83b;try{if(this[_0x2a843e('0x4b')](_0x1a7ae9)){if(this[_0x2a843e('0x64')][_0x1a7ae9['uniqueid']])for(const _0x3f1868 in this[_0x2a843e('0x64')][_0x1a7ae9[_0x2a843e('0x48')]]){typeof this['channels'][_0x1a7ae9[_0x2a843e('0x48')]][_0x3f1868]!=='undefined'&&!this[_0x2a843e('0x64')][_0x1a7ae9[_0x2a843e('0x48')]][_0x3f1868][_0x2a843e('0x4e')]&&!this['channels'][_0x1a7ae9[_0x2a843e('0x48')]][_0x3f1868][_0x2a843e('0x3a')]&&(this[_0x2a843e('0x64')][_0x1a7ae9[_0x2a843e('0x48')]][_0x3f1868][_0x2a843e('0x4e')]=!![],this['channels'][_0x1a7ae9[_0x2a843e('0x48')]][_0x3f1868]['agentringnoanswerAt']=moment()[_0x2a843e('0x44')](_0x2a843e('0x0')),this[_0x2a843e('0x64')][_0x1a7ae9[_0x2a843e('0x48')]][_0x3f1868]['reason']=_0x2a843e('0x29'),this[_0x2a843e('0x64')][_0x1a7ae9[_0x2a843e('0x48')]][_0x3f1868][_0x2a843e('0x54')]=_0x2a843e('0x29'),ami[_0x2a843e('0x1f')](_0x2a843e('0x42'),this['channels'][_0x1a7ae9[_0x2a843e('0x48')]][_0x3f1868]));}}}catch(_0x1b7438){logger[_0x2a843e('0x1b')](_0x2a843e('0x3'),util[_0x2a843e('0x34')](_0x1b7438,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x30d83b('0x32')][_0x30d83b('0xc')]=function(_0xfabc8a){const _0x73f520=_0x30d83b;try{if(this[_0x73f520('0x4b')](_0xfabc8a)){if(this[_0x73f520('0x64')][_0xfabc8a[_0x73f520('0x48')]])for(const _0x2d668c in this[_0x73f520('0x64')][_0xfabc8a[_0x73f520('0x48')]]){typeof this['channels'][_0xfabc8a[_0x73f520('0x48')]][_0x2d668c]!==_0x73f520('0x17')&&(this[_0x73f520('0x64')][_0xfabc8a[_0x73f520('0x48')]][_0x2d668c][_0x73f520('0x1d')]&&!this[_0x73f520('0x64')][_0xfabc8a[_0x73f520('0x48')]][_0x2d668c][_0x73f520('0x3a')]&&(this[_0x73f520('0x64')][_0xfabc8a['uniqueid']][_0x2d668c]['agentcomplete']=!![],this[_0x73f520('0x64')][_0xfabc8a[_0x73f520('0x48')]][_0x2d668c][_0x73f520('0x14')]=moment()[_0x73f520('0x44')]('YYYY-MM-DD\x20HH:mm:ss'),this[_0x73f520('0x64')][_0xfabc8a['uniqueid']][_0x2d668c][_0x73f520('0x54')]=_0x73f520('0x5'),this[_0x73f520('0x64')][_0xfabc8a[_0x73f520('0x48')]][_0x2d668c][_0x73f520('0x5d')]=_0xfabc8a['talktime'],this['channels'][_0xfabc8a['uniqueid']][_0x2d668c]['reason']=_0xfabc8a[_0x73f520('0x4c')]=='transfer'?_0x73f520('0x39'):_0xfabc8a[_0x73f520('0x4c')],this[_0x73f520('0x4f')][_0xfabc8a[_0x73f520('0x2a')]]&&this['voiceQueues'][_0xfabc8a[_0x73f520('0x2a')]][_0x73f520('0x69')]&&(this['channels'][_0xfabc8a['uniqueid']][_0x2d668c][_0x73f520('0x45')]=!![],this[_0x73f520('0x64')][_0xfabc8a['uniqueid']][_0x2d668c][_0x73f520('0x2d')]=this[_0x73f520('0x4f')][_0xfabc8a[_0x73f520('0x2a')]]['acwTimeout']),this['agents'][_0xfabc8a[_0x73f520('0x22')]]=_[_0x73f520('0x1c')](this[_0x73f520('0x4d')][_0xfabc8a[_0x73f520('0x22')]],[_0x73f520('0x2a'),_0x73f520('0x23')]),this[_0x73f520('0x1f')](util[_0x73f520('0x44')]('user:%s',_0xfabc8a[_0x73f520('0x28')]),'user:agentcomplete',this[_0x73f520('0x64')][_0xfabc8a[_0x73f520('0x48')]][_0x2d668c]),ami[_0x73f520('0x1f')](_0x73f520('0x59'),this['channels'][_0xfabc8a[_0x73f520('0x48')]][_0x2d668c])));}}}catch(_0x356710){logger['error']('[syncAgentComplete][VoiceAgentReport]',util[_0x73f520('0x34')](_0x356710,{'showHidden':![],'depth':null}));}},VoiceAgentReport['prototype'][_0x30d83b('0x12')]=function(_0x52bfd6){const _0x2e7a19=_0x30d83b;try{if(this[_0x2e7a19('0x4b')](_0x52bfd6)){this['addVariable'](_0x52bfd6[_0x2e7a19('0x48')],_['keys'](_0x52bfd6[_0x2e7a19('0x46')])[0x0],_0x52bfd6[_0x2e7a19('0x57')]);if(this[_0x2e7a19('0x64')][_0x52bfd6[_0x2e7a19('0x48')]])for(const _0xbfa743 in this[_0x2e7a19('0x64')][_0x52bfd6['uniqueid']]){typeof this[_0x2e7a19('0x64')][_0x52bfd6[_0x2e7a19('0x48')]][_0xbfa743]!==_0x2e7a19('0x17')&&(_[_0x2e7a19('0x72')](this['channels'][_0x52bfd6[_0x2e7a19('0x48')]][_0xbfa743]['variables'])&&(this[_0x2e7a19('0x64')][_0x52bfd6['uniqueid']][_0xbfa743][_0x2e7a19('0xb')]={}),this[_0x2e7a19('0x64')][_0x52bfd6[_0x2e7a19('0x48')]][_0xbfa743][_0x2e7a19('0xb')]=this[_0x2e7a19('0xb')][_0x52bfd6[_0x2e7a19('0x48')]]);}}}catch(_0x435e14){logger[_0x2e7a19('0x1b')](_0x2e7a19('0x4'),util[_0x2e7a19('0x34')](_0x435e14,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x30d83b('0x32')][_0x30d83b('0x1a')]=function(_0x6fdfde,_0x1c54cb,_0x263800){const _0x3f6ea0=_0x30d83b,_0x2f4ebd=[_0x3f6ea0('0x26'),_0x3f6ea0('0x53'),_0x3f6ea0('0x24'),_0x3f6ea0('0x25'),'rtpaudioqosloss',_0x3f6ea0('0x6e'),_0x3f6ea0('0x2e'),_0x3f6ea0('0x6d'),_0x3f6ea0('0x10'),_0x3f6ea0('0x3c'),'bridgepeer',_0x3f6ea0('0x5f'),_0x3f6ea0('0x6'),_0x3f6ea0('0x19'),_0x3f6ea0('0x20'),_0x3f6ea0('0x2f'),'membername',_0x3f6ea0('0x11'),'memberrealtime'];!_[_0x3f6ea0('0x13')](_0x1c54cb)&&!_[_0x3f6ea0('0x52')](_0x2f4ebd,_0x1c54cb)&&(_[_0x3f6ea0('0x72')](this[_0x3f6ea0('0xb')][_0x6fdfde])&&(this[_0x3f6ea0('0xb')][_0x6fdfde]={}),this[_0x3f6ea0('0xb')][_0x6fdfde][_0x1c54cb]=_0x263800);},VoiceAgentReport[_0x30d83b('0x32')][_0x30d83b('0x5b')]=function(_0x394dd2){const _0x1b9c91=_0x30d83b;try{if(this[_0x1b9c91('0x4b')](_0x394dd2)){if(this[_0x1b9c91('0x64')][_0x394dd2[_0x1b9c91('0x48')]]){for(const _0x1455ec in this[_0x1b9c91('0x64')][_0x394dd2[_0x1b9c91('0x48')]]){typeof this[_0x1b9c91('0x64')][_0x394dd2[_0x1b9c91('0x48')]][_0x1455ec]!==_0x1b9c91('0x17')&&(this[_0x1b9c91('0x64')][_0x394dd2[_0x1b9c91('0x48')]][_0x1455ec]['reason']==_0x1b9c91('0x60')&&this[_0x1b9c91('0x64')][_0x394dd2[_0x1b9c91('0x48')]][_0x1455ec]['agentcomplete']&&(this['channels'][_0x394dd2['uniqueid']][_0x1455ec]['agentcompleteAt']=moment()[_0x1b9c91('0x44')](_0x1b9c91('0x0'))));}ami[_0x1b9c91('0x1f')](_0x1b9c91('0x27'),_['values'](this[_0x1b9c91('0x64')][_0x394dd2[_0x1b9c91('0x48')]])),delete this['channels'][_0x394dd2[_0x1b9c91('0x48')]];}this[_0x1b9c91('0xb')][_0x394dd2[_0x1b9c91('0x48')]]&&delete this[_0x1b9c91('0xb')][_0x394dd2['uniqueid']];}}catch(_0x432ec8){logger[_0x1b9c91('0x1b')](_0x1b9c91('0x30'),util[_0x1b9c91('0x34')](_0x432ec8,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x30d83b('0x32')][_0x30d83b('0x36')]=function(_0x3bc177){const _0x400de2=_0x30d83b;try{if(this[_0x400de2('0x4b')](_0x3bc177)){if(this[_0x400de2('0x64')][_0x3bc177[_0x400de2('0x63')]])for(const _0x11118a in this[_0x400de2('0x64')][_0x3bc177[_0x400de2('0x63')]]){if(typeof this['channels'][_0x3bc177[_0x400de2('0x63')]][_0x11118a]!==_0x400de2('0x17')){if(_0x3bc177[_0x400de2('0xf')]===_0x11118a){const _0x272fa8=moment();this['channels'][_0x3bc177[_0x400de2('0x63')]][_0x11118a]['agentcomplete']=!![],this[_0x400de2('0x64')][_0x3bc177[_0x400de2('0x63')]][_0x11118a][_0x400de2('0x14')]=moment()[_0x400de2('0x44')](_0x400de2('0x0')),this['channels'][_0x3bc177['transfereeuniqueid']][_0x11118a][_0x400de2('0x4c')]=_0x400de2('0x60'),this[_0x400de2('0x64')][_0x3bc177[_0x400de2('0x63')]][_0x11118a][_0x400de2('0x54')]='complete',this['channels'][_0x3bc177[_0x400de2('0x63')]][_0x11118a]['talktime']=_0x272fa8[_0x400de2('0x5c')](this[_0x400de2('0x64')][_0x3bc177[_0x400de2('0x63')]][_0x11118a][_0x400de2('0x1d')],_0x400de2('0x47'));}}}if(this[_0x400de2('0x64')][_0x3bc177[_0x400de2('0x35')]]){const _0x472b0c=this[_0x400de2('0x64')][_0x3bc177[_0x400de2('0x35')]];this[_0x400de2('0x64')][_0x3bc177[_0x400de2('0x35')]]=this['channels'][_0x3bc177[_0x400de2('0x63')]],this['channels'][_0x3bc177[_0x400de2('0x63')]]=_0x472b0c;}}}catch(_0x555069){logger[_0x400de2('0x1b')](_0x400de2('0x3f'),util[_0x400de2('0x34')](_0x555069,{'showHidden':![],'depth':null}));}},VoiceAgentReport['prototype'][_0x30d83b('0x1')]=function(_0x2ef7fc){const _0x116167=_0x30d83b;try{if(this[_0x116167('0x4b')](_0x2ef7fc)){if(this[_0x116167('0x64')][_0x2ef7fc['transfereeuniqueid']])for(const _0x18e2c1 in this[_0x116167('0x64')][_0x2ef7fc['transfereeuniqueid']]){if(typeof this['channels'][_0x2ef7fc['transfereeuniqueid']][_0x18e2c1]!=='undefined'){if(_0x2ef7fc['transfereruniqueid']===_0x18e2c1){const _0x176548=moment();this[_0x116167('0x64')][_0x2ef7fc[_0x116167('0x63')]][_0x18e2c1][_0x116167('0x3a')]=!![],this[_0x116167('0x64')][_0x2ef7fc[_0x116167('0x63')]][_0x18e2c1]['agentcompleteAt']=_0x176548,this[_0x116167('0x64')][_0x2ef7fc['transfereeuniqueid']][_0x18e2c1][_0x116167('0x4c')]=_0x116167('0x60'),this[_0x116167('0x64')][_0x2ef7fc[_0x116167('0x63')]][_0x18e2c1][_0x116167('0x54')]=_0x116167('0x5'),this[_0x116167('0x64')][_0x2ef7fc['transfereeuniqueid']][_0x18e2c1][_0x116167('0x5d')]=_0x176548[_0x116167('0x5c')](this['channels'][_0x2ef7fc['transfereeuniqueid']][_0x18e2c1]['agentconnectAt'],'seconds');}}}}}catch(_0x1a61a4){logger['error']('[syncBlindTransfer][VoiceAgentReport]',util[_0x116167('0x34')](_0x1a61a4,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x30d83b('0x32')][_0x30d83b('0x50')]=function(_0xd1ec7e){const _0x2cf2a8=_0x30d83b;let _0x41077d='';try{this['isNotNull'](_0xd1ec7e)&&(_0xd1ec7e[_0x2cf2a8('0x2c')]&&(_0x41077d=_0xd1ec7e[_0x2cf2a8('0x2c')]['substring'](0x0,_0xd1ec7e['channel'][_0x2cf2a8('0x4a')]('-')),this['agents'][_0x41077d]&&(this['agents'][_0x41077d][_0x2cf2a8('0x58')]=!![])));}catch(_0x2673db){logger['error'](_0x2cf2a8('0x15'),util[_0x2cf2a8('0x34')](_0x2673db,{'showHidden':![],'depth':null}));}},VoiceAgentReport['prototype'][_0x30d83b('0x9')]=function(_0x3cfa68){const _0x129172=_0x30d83b;let _0x4497e9='';try{this[_0x129172('0x4b')](_0x3cfa68)&&(_0x3cfa68['channel']&&(_0x4497e9=_0x3cfa68['channel'][_0x129172('0x6a')](0x0,_0x3cfa68['channel']['lastIndexOf']('-')),this[_0x129172('0x4d')][_0x4497e9]&&(this[_0x129172('0x4d')][_0x4497e9]['onhold']=![])));}catch(_0x46d6a9){logger[_0x129172('0x1b')](_0x129172('0x8'),util[_0x129172('0x34')](_0x46d6a9,{'showHidden':![],'depth':null}));}},module[_0x30d83b('0x49')]=VoiceAgentReport; \ No newline at end of file +const a1095_0x5240=['channels','sipuri','origtransfereruniqueid','undefined','uniqueid','user:agentconnect','event','seconds','rtpaudioqoslossbridged','agents','acwtime','rtpaudioqosjitterbridged','value','../../../config/logger','destchannelstatedesc','user:%s','answeredelsewheredestinationuniqueid','syncAgentRingNoAnswer','agentcomplete','called','sipcallid','queue','agentconnect','bridgepeer','agentcalled','reason','holdtime','talktime','syncAgentCalled','destconnectedlinenum','util','musiconholdstart','[syncHangup][VoiceAgentReport]','memberrealtime','destuniqueid','[syncAgentConnect][VoiceAgentReport]','rtpaudioqos','isNil','[syncBlindTransfer][VoiceAgentReport]','answered_elsewhere','rejected','channel','syncAgentConnect','blindtransfer','transfer','user:agentcomplete','pick','bind','addVariable','isUndefined','memberpenalty','syncAttendedTransfer','YYYY-MM-DD\x20HH:mm:ss','complete','secondtransfereruniqueid','agentacw','[syncAgentRingNoAnswer][VoiceAgentReport]','[syncAttendedTransfer][VoiceAgentReport]','agentcompleteAt','syncMusicOnHoldStart','destchannelstate','transfereeuniqueid','includes','[syncMusicOnHoldStart][VoiceAgentReport]','membername','lastevent','agentringnoanswerAt','omit','../ami','memberinterface','connectedlinename','onhold','rtpaudioqosrtt','voiceQueues','attendedtransfer','inspect','error','membercalls','emit','agentconnectAt','lastIndexOf','custom:agentringnoanswer','[syncMusicOnHoldStop][VoiceAgentReport]','diff','variable','isNotNull','acw','[syncVarSet][VoiceAgentReport]','queuecallerabandon','inbound','syncQueueCallerAbandon','custom:agentconnect','rtpaudioqosloss','substring','custom:agentcomplete','varset','exports','ami','syncVarSet','agentringnoanswer','custom:agentcalled','syncBlindTransfer','syncMusicOnHoldStop','musiconholdstop','user:called','prototype','merge','syncHangup','syncAgentComplete','connectedlinenum','lodash','memberdynamic','variables','interface','[syncAgentCalled][VoiceAgentReport]','[syncAgentComplete][VoiceAgentReport]','acwTimeout','format','keys','moment','rtpaudioqosrttbridged','custom:voiceAgentReport'];(function(_0x19c391,_0x524069){const _0x2f5304=function(_0x311fde){while(--_0x311fde){_0x19c391['push'](_0x19c391['shift']());}};_0x2f5304(++_0x524069);}(a1095_0x5240,0xad));const a1095_0x2f53=function(_0x19c391,_0x524069){_0x19c391=_0x19c391-0x0;let _0x2f5304=a1095_0x5240[_0x19c391];return _0x2f5304;};const _0x21f8e3=a1095_0x2f53;'use strict';const _=require(_0x21f8e3('0x3b')),moment=require(_0x21f8e3('0x44')),util=require(_0x21f8e3('0x65')),logger=require(_0x21f8e3('0x54'))(_0x21f8e3('0x2e')),ami=require(_0x21f8e3('0x11')),{getSocket}=require('../../../rediscache'),io=getSocket();function VoiceAgentReport(_0x311fde){const _0xac93d5=_0x21f8e3;this[_0xac93d5('0x47')]={},this[_0xac93d5('0x16')]=_0x311fde[_0xac93d5('0x16')],this['agents']=_0x311fde[_0xac93d5('0x50')],this[_0xac93d5('0x3d')]={},ami['on'](_0xac93d5('0x5f'),this[_0xac93d5('0x63')][_0xac93d5('0x76')](this)),ami['on'](_0xac93d5('0x5d'),this['syncAgentConnect'][_0xac93d5('0x76')](this)),ami['on'](_0xac93d5('0x30'),this[_0xac93d5('0x58')]['bind'](this)),ami['on'](_0xac93d5('0x25'),this[_0xac93d5('0x27')][_0xac93d5('0x76')](this)),ami['on']('agentcomplete',this['syncAgentComplete']['bind'](this)),ami['on'](_0xac93d5('0x2c'),this[_0xac93d5('0x2f')]['bind'](this)),ami['on']('hangup',this['syncHangup'][_0xac93d5('0x76')](this)),ami['on'](_0xac93d5('0x66'),this[_0xac93d5('0x8')]['bind'](this)),ami['on'](_0xac93d5('0x34'),this[_0xac93d5('0x33')]['bind'](this)),ami['on'](_0xac93d5('0x17'),this[_0xac93d5('0x0')][_0xac93d5('0x76')](this)),ami['on'](_0xac93d5('0x72'),this[_0xac93d5('0x32')][_0xac93d5('0x76')](this));}VoiceAgentReport[_0x21f8e3('0x36')]['emit']=function(_0x5d5ea8,_0x1b60a5,_0x345fa5){io['to'](_0x5d5ea8)['emit'](_0x1b60a5,_0x345fa5);},VoiceAgentReport[_0x21f8e3('0x36')]['isNotNull']=function(_0x42c8d7){const _0x5c150a=_0x21f8e3;return _0x42c8d7!==null&&!_[_0x5c150a('0x78')](_0x42c8d7);},VoiceAgentReport[_0x21f8e3('0x36')][_0x21f8e3('0x63')]=function(_0x1f6012){const _0x363380=_0x21f8e3;try{this[_0x363380('0x22')](_0x1f6012)&&(_[_0x363380('0x78')](this['channels'][_0x1f6012['uniqueid']])&&(this['channels'][_0x1f6012[_0x363380('0x4b')]]={}),_[_0x363380('0x78')](this[_0x363380('0x47')][_0x1f6012[_0x363380('0x4b')]][_0x1f6012[_0x363380('0x69')]])&&(this[_0x363380('0x47')][_0x1f6012[_0x363380('0x4b')]][_0x1f6012[_0x363380('0x69')]]={'agentcalledAt':moment()[_0x363380('0x42')](_0x363380('0x1')),'lastevent':_0x363380('0x5a'),'variables':this[_0x363380('0x3d')][_0x1f6012[_0x363380('0x4b')]],'type':this['voiceQueues'][_0x1f6012[_0x363380('0x5c')]]?this['voiceQueues'][_0x1f6012[_0x363380('0x5c')]]['type']||_0x363380('0x26'):_0x363380('0x26')}),_[_0x363380('0x37')](this[_0x363380('0x47')][_0x1f6012['uniqueid']][_0x1f6012[_0x363380('0x69')]],_['omit'](_0x1f6012,[_0x363380('0x4d'),'privilege'])),ami[_0x363380('0x1b')](_0x363380('0x31'),this['channels'][_0x1f6012['uniqueid']][_0x1f6012['destuniqueid']]),this[_0x363380('0x1b')](util[_0x363380('0x42')]('user:%s',_0x1f6012[_0x363380('0xd')]),_0x363380('0x35'),this[_0x363380('0x47')][_0x1f6012[_0x363380('0x4b')]][_0x1f6012[_0x363380('0x69')]]));}catch(_0x2bfcd3){logger[_0x363380('0x19')](_0x363380('0x3f'),util[_0x363380('0x18')](_0x2bfcd3,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x21f8e3('0x36')][_0x21f8e3('0x71')]=function(_0x1dd7d6){const _0x3f6c51=_0x21f8e3;try{if(this[_0x3f6c51('0x22')](_0x1dd7d6)){if(this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]])for(const _0x5938b in this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]]){if(typeof this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b]!==_0x3f6c51('0x4a')){if(_0x1dd7d6[_0x3f6c51('0x69')]===_0x5938b)this[_0x3f6c51('0x47')][_0x1dd7d6['uniqueid']][_0x5938b][_0x3f6c51('0x1c')]=moment()[_0x3f6c51('0x42')](_0x3f6c51('0x1')),this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b][_0x3f6c51('0xe')]='connect',this['channels'][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b]['holdtime']=_0x1dd7d6[_0x3f6c51('0x61')],this['channels'][_0x1dd7d6['uniqueid']][_0x5938b][_0x3f6c51('0x3a')]=_0x1dd7d6[_0x3f6c51('0x3a')],this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b][_0x3f6c51('0x13')]=_0x1dd7d6['connectedlinename'],this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b][_0x3f6c51('0x9')]=_0x1dd7d6['destchannelstate'],this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b][_0x3f6c51('0x55')]=_0x1dd7d6[_0x3f6c51('0x55')],_[_0x3f6c51('0x37')](this[_0x3f6c51('0x50')][_0x1dd7d6['interface']],_[_0x3f6c51('0x75')](_0x1dd7d6,[_0x3f6c51('0x5c'),'destconnectedlinenum'])),this['emit'](util[_0x3f6c51('0x42')](_0x3f6c51('0x56'),_0x1dd7d6['membername']),_0x3f6c51('0x4c'),this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x1dd7d6[_0x3f6c51('0x69')]]),ami[_0x3f6c51('0x1b')](_0x3f6c51('0x28'),this['channels'][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b]);else!this['channels'][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b][_0x3f6c51('0x30')]&&!this['channels'][_0x1dd7d6['uniqueid']][_0x5938b][_0x3f6c51('0x59')]&&(this['channels'][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b][_0x3f6c51('0x30')]=!![],this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b]['agentringnoanswerAt']=moment()[_0x3f6c51('0x42')]('YYYY-MM-DD\x20HH:mm:ss'),this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b][_0x3f6c51('0x60')]=_0x3f6c51('0x6e'),this['channels'][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b][_0x3f6c51('0xe')]=_0x3f6c51('0x6e'),this[_0x3f6c51('0x47')][_0x1dd7d6[_0x3f6c51('0x4b')]][_0x5938b][_0x3f6c51('0x57')]=_0x1dd7d6[_0x3f6c51('0x69')],this[_0x3f6c51('0x47')][_0x1dd7d6['uniqueid']][_0x5938b]['answeredelsewheremembername']=_0x1dd7d6['membername'],ami[_0x3f6c51('0x1b')]('custom:agentansweredelsewhere',this[_0x3f6c51('0x47')][_0x1dd7d6['uniqueid']][_0x5938b]));}}}}catch(_0x2fc034){logger['error'](_0x3f6c51('0x6a'),util[_0x3f6c51('0x18')](_0x2fc034,{'showHidden':![],'depth':null}));}},VoiceAgentReport['prototype'][_0x21f8e3('0x58')]=function(_0x565301){const _0x468f0f=_0x21f8e3;try{this['isNotNull'](_0x565301)&&(this[_0x468f0f('0x47')][_0x565301['uniqueid']]&&this[_0x468f0f('0x47')][_0x565301['uniqueid']][_0x565301[_0x468f0f('0x69')]]&&(this['channels'][_0x565301[_0x468f0f('0x4b')]][_0x565301['destuniqueid']]['agentringnoanswer']=!![],this[_0x468f0f('0x47')][_0x565301[_0x468f0f('0x4b')]][_0x565301[_0x468f0f('0x69')]][_0x468f0f('0xf')]=moment()[_0x468f0f('0x42')](_0x468f0f('0x1')),this[_0x468f0f('0x47')][_0x565301[_0x468f0f('0x4b')]][_0x565301[_0x468f0f('0x69')]][_0x468f0f('0x60')]='rejected',this[_0x468f0f('0x47')][_0x565301['uniqueid']][_0x565301['destuniqueid']]['lastevent']=_0x468f0f('0x6f'),ami['emit'](_0x468f0f('0x1e'),this[_0x468f0f('0x47')][_0x565301[_0x468f0f('0x4b')]][_0x565301[_0x468f0f('0x69')]])));}catch(_0x32747a){logger[_0x468f0f('0x19')](_0x468f0f('0x5'),util[_0x468f0f('0x18')](_0x32747a,{'showHidden':![],'depth':null}));}},VoiceAgentReport['prototype'][_0x21f8e3('0x27')]=function(_0x178486){const _0x4ed36e=_0x21f8e3;try{if(this[_0x4ed36e('0x22')](_0x178486)){if(this['channels'][_0x178486[_0x4ed36e('0x4b')]])for(const _0x2c0137 in this[_0x4ed36e('0x47')][_0x178486['uniqueid']]){typeof this[_0x4ed36e('0x47')][_0x178486['uniqueid']][_0x2c0137]!=='undefined'&&!this['channels'][_0x178486[_0x4ed36e('0x4b')]][_0x2c0137]['agentringnoanswer']&&!this[_0x4ed36e('0x47')][_0x178486[_0x4ed36e('0x4b')]][_0x2c0137][_0x4ed36e('0x59')]&&(this['channels'][_0x178486['uniqueid']][_0x2c0137][_0x4ed36e('0x30')]=!![],this[_0x4ed36e('0x47')][_0x178486['uniqueid']][_0x2c0137][_0x4ed36e('0xf')]=moment()[_0x4ed36e('0x42')](_0x4ed36e('0x1')),this[_0x4ed36e('0x47')][_0x178486['uniqueid']][_0x2c0137][_0x4ed36e('0x60')]='abandoned',this[_0x4ed36e('0x47')][_0x178486['uniqueid']][_0x2c0137][_0x4ed36e('0xe')]='abandoned',ami[_0x4ed36e('0x1b')]('custom:agentqueuecallerabandon',this['channels'][_0x178486[_0x4ed36e('0x4b')]][_0x2c0137]));}}}catch(_0x23f478){logger[_0x4ed36e('0x19')]('[syncQueueCallerAbandon][VoiceAgentReport]',util['inspect'](_0x23f478,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x21f8e3('0x36')][_0x21f8e3('0x39')]=function(_0x1d74cf){const _0x4778ad=_0x21f8e3;try{if(this[_0x4778ad('0x22')](_0x1d74cf)){if(this[_0x4778ad('0x47')][_0x1d74cf[_0x4778ad('0x4b')]])for(const _0x19f61b in this['channels'][_0x1d74cf[_0x4778ad('0x4b')]]){typeof this['channels'][_0x1d74cf[_0x4778ad('0x4b')]][_0x19f61b]!=='undefined'&&(this[_0x4778ad('0x47')][_0x1d74cf[_0x4778ad('0x4b')]][_0x19f61b][_0x4778ad('0x1c')]&&!this[_0x4778ad('0x47')][_0x1d74cf['uniqueid']][_0x19f61b][_0x4778ad('0x59')]&&(this['channels'][_0x1d74cf[_0x4778ad('0x4b')]][_0x19f61b]['agentcomplete']=!![],this[_0x4778ad('0x47')][_0x1d74cf[_0x4778ad('0x4b')]][_0x19f61b]['agentcompleteAt']=moment()[_0x4778ad('0x42')](_0x4778ad('0x1')),this[_0x4778ad('0x47')][_0x1d74cf[_0x4778ad('0x4b')]][_0x19f61b][_0x4778ad('0xe')]=_0x4778ad('0x2'),this['channels'][_0x1d74cf['uniqueid']][_0x19f61b][_0x4778ad('0x62')]=_0x1d74cf[_0x4778ad('0x62')],this['channels'][_0x1d74cf['uniqueid']][_0x19f61b][_0x4778ad('0x60')]=_0x1d74cf[_0x4778ad('0x60')]==_0x4778ad('0x73')?'agent':_0x1d74cf[_0x4778ad('0x60')],this['voiceQueues'][_0x1d74cf['queue']]&&this[_0x4778ad('0x16')][_0x1d74cf[_0x4778ad('0x5c')]][_0x4778ad('0x23')]&&(this['channels'][_0x1d74cf['uniqueid']][_0x19f61b][_0x4778ad('0x4')]=!![],this[_0x4778ad('0x47')][_0x1d74cf[_0x4778ad('0x4b')]][_0x19f61b][_0x4778ad('0x51')]=this[_0x4778ad('0x16')][_0x1d74cf['queue']][_0x4778ad('0x41')]),this[_0x4778ad('0x50')][_0x1d74cf[_0x4778ad('0x3e')]]=_[_0x4778ad('0x10')](this[_0x4778ad('0x50')][_0x1d74cf[_0x4778ad('0x3e')]],[_0x4778ad('0x5c'),_0x4778ad('0x64')]),this[_0x4778ad('0x1b')](util['format']('user:%s',_0x1d74cf[_0x4778ad('0xd')]),_0x4778ad('0x74'),this[_0x4778ad('0x47')][_0x1d74cf[_0x4778ad('0x4b')]][_0x19f61b]),ami['emit'](_0x4778ad('0x2b'),this['channels'][_0x1d74cf[_0x4778ad('0x4b')]][_0x19f61b])));}}}catch(_0x19bc23){logger[_0x4778ad('0x19')](_0x4778ad('0x40'),util[_0x4778ad('0x18')](_0x19bc23,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x21f8e3('0x36')]['syncVarSet']=function(_0x5e5380){const _0x3cdad7=_0x21f8e3;try{if(this[_0x3cdad7('0x22')](_0x5e5380)){this[_0x3cdad7('0x77')](_0x5e5380[_0x3cdad7('0x4b')],_[_0x3cdad7('0x43')](_0x5e5380[_0x3cdad7('0x21')])[0x0],_0x5e5380[_0x3cdad7('0x53')]);if(this['channels'][_0x5e5380[_0x3cdad7('0x4b')]])for(const _0x2b8074 in this[_0x3cdad7('0x47')][_0x5e5380['uniqueid']]){typeof this[_0x3cdad7('0x47')][_0x5e5380[_0x3cdad7('0x4b')]][_0x2b8074]!==_0x3cdad7('0x4a')&&(_[_0x3cdad7('0x78')](this['channels'][_0x5e5380[_0x3cdad7('0x4b')]][_0x2b8074][_0x3cdad7('0x3d')])&&(this[_0x3cdad7('0x47')][_0x5e5380[_0x3cdad7('0x4b')]][_0x2b8074][_0x3cdad7('0x3d')]={}),this[_0x3cdad7('0x47')][_0x5e5380[_0x3cdad7('0x4b')]][_0x2b8074][_0x3cdad7('0x3d')]=this['variables'][_0x5e5380[_0x3cdad7('0x4b')]]);}}}catch(_0x8e0b8a){logger[_0x3cdad7('0x19')](_0x3cdad7('0x24'),util['inspect'](_0x8e0b8a,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x21f8e3('0x36')]['addVariable']=function(_0x29b5cc,_0x1f7fc,_0x3f1a47){const _0x2f10c6=_0x21f8e3,_0x2eb4c9=[_0x2f10c6('0x6b'),'rtpaudioqosbridged','rtpaudioqosjitter',_0x2f10c6('0x52'),_0x2f10c6('0x29'),_0x2f10c6('0x4f'),_0x2f10c6('0x15'),_0x2f10c6('0x45'),_0x2f10c6('0x5b'),_0x2f10c6('0x48'),_0x2f10c6('0x5e'),'bridgepvtcallid',_0x2f10c6('0x1a'),_0x2f10c6('0x3c'),_0x2f10c6('0x12'),'memberlastcall','membername',_0x2f10c6('0x79'),_0x2f10c6('0x68')];!_[_0x2f10c6('0x6c')](_0x1f7fc)&&!_[_0x2f10c6('0xb')](_0x2eb4c9,_0x1f7fc)&&(_['isUndefined'](this[_0x2f10c6('0x3d')][_0x29b5cc])&&(this['variables'][_0x29b5cc]={}),this[_0x2f10c6('0x3d')][_0x29b5cc][_0x1f7fc]=_0x3f1a47);},VoiceAgentReport[_0x21f8e3('0x36')][_0x21f8e3('0x38')]=function(_0x57164d){const _0x32f6f9=_0x21f8e3;try{if(this[_0x32f6f9('0x22')](_0x57164d)){if(this['channels'][_0x57164d['uniqueid']]){for(const _0x15bfc9 in this[_0x32f6f9('0x47')][_0x57164d[_0x32f6f9('0x4b')]]){typeof this[_0x32f6f9('0x47')][_0x57164d['uniqueid']][_0x15bfc9]!=='undefined'&&(this['channels'][_0x57164d[_0x32f6f9('0x4b')]][_0x15bfc9][_0x32f6f9('0x60')]==_0x32f6f9('0x73')&&this[_0x32f6f9('0x47')][_0x57164d['uniqueid']][_0x15bfc9]['agentcomplete']&&(this[_0x32f6f9('0x47')][_0x57164d[_0x32f6f9('0x4b')]][_0x15bfc9][_0x32f6f9('0x7')]=moment()[_0x32f6f9('0x42')](_0x32f6f9('0x1'))));}ami[_0x32f6f9('0x1b')](_0x32f6f9('0x46'),_['values'](this[_0x32f6f9('0x47')][_0x57164d[_0x32f6f9('0x4b')]])),delete this[_0x32f6f9('0x47')][_0x57164d['uniqueid']];}this[_0x32f6f9('0x3d')][_0x57164d[_0x32f6f9('0x4b')]]&&delete this[_0x32f6f9('0x3d')][_0x57164d[_0x32f6f9('0x4b')]];}}catch(_0x31cd89){logger[_0x32f6f9('0x19')](_0x32f6f9('0x67'),util[_0x32f6f9('0x18')](_0x31cd89,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x21f8e3('0x36')][_0x21f8e3('0x0')]=function(_0x293c8d){const _0x485cc0=_0x21f8e3;try{if(this[_0x485cc0('0x22')](_0x293c8d)){if(this[_0x485cc0('0x47')][_0x293c8d[_0x485cc0('0xa')]])for(const _0x93842a in this[_0x485cc0('0x47')][_0x293c8d[_0x485cc0('0xa')]]){if(typeof this[_0x485cc0('0x47')][_0x293c8d[_0x485cc0('0xa')]][_0x93842a]!=='undefined'){if(_0x293c8d[_0x485cc0('0x49')]===_0x93842a){const _0x567e0c=moment();this[_0x485cc0('0x47')][_0x293c8d['transfereeuniqueid']][_0x93842a]['agentcomplete']=!![],this[_0x485cc0('0x47')][_0x293c8d[_0x485cc0('0xa')]][_0x93842a]['agentcompleteAt']=moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),this[_0x485cc0('0x47')][_0x293c8d['transfereeuniqueid']][_0x93842a]['reason']=_0x485cc0('0x73'),this['channels'][_0x293c8d[_0x485cc0('0xa')]][_0x93842a][_0x485cc0('0xe')]='complete',this['channels'][_0x293c8d[_0x485cc0('0xa')]][_0x93842a]['talktime']=_0x567e0c['diff'](this[_0x485cc0('0x47')][_0x293c8d[_0x485cc0('0xa')]][_0x93842a]['agentconnectAt'],_0x485cc0('0x4e'));}}}if(this[_0x485cc0('0x47')][_0x293c8d['secondtransfereruniqueid']]){const _0x340a01=this[_0x485cc0('0x47')][_0x293c8d[_0x485cc0('0x3')]];this[_0x485cc0('0x47')][_0x293c8d['secondtransfereruniqueid']]=this[_0x485cc0('0x47')][_0x293c8d[_0x485cc0('0xa')]],this['channels'][_0x293c8d[_0x485cc0('0xa')]]=_0x340a01;}}}catch(_0x16e187){logger[_0x485cc0('0x19')](_0x485cc0('0x6'),util[_0x485cc0('0x18')](_0x16e187,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x21f8e3('0x36')][_0x21f8e3('0x32')]=function(_0x3babec){const _0x3405ac=_0x21f8e3;try{if(this['isNotNull'](_0x3babec)){if(this[_0x3405ac('0x47')][_0x3babec[_0x3405ac('0xa')]])for(const _0x329784 in this[_0x3405ac('0x47')][_0x3babec[_0x3405ac('0xa')]]){if(typeof this['channels'][_0x3babec['transfereeuniqueid']][_0x329784]!==_0x3405ac('0x4a')){if(_0x3babec['transfereruniqueid']===_0x329784){const _0x108bb3=moment();this[_0x3405ac('0x47')][_0x3babec['transfereeuniqueid']][_0x329784][_0x3405ac('0x59')]=!![],this[_0x3405ac('0x47')][_0x3babec[_0x3405ac('0xa')]][_0x329784][_0x3405ac('0x7')]=_0x108bb3,this[_0x3405ac('0x47')][_0x3babec[_0x3405ac('0xa')]][_0x329784]['reason']='transfer',this[_0x3405ac('0x47')][_0x3babec[_0x3405ac('0xa')]][_0x329784][_0x3405ac('0xe')]='complete',this[_0x3405ac('0x47')][_0x3babec[_0x3405ac('0xa')]][_0x329784][_0x3405ac('0x62')]=_0x108bb3[_0x3405ac('0x20')](this['channels'][_0x3babec[_0x3405ac('0xa')]][_0x329784]['agentconnectAt'],_0x3405ac('0x4e'));}}}}}catch(_0x3b0364){logger[_0x3405ac('0x19')](_0x3405ac('0x6d'),util[_0x3405ac('0x18')](_0x3b0364,{'showHidden':![],'depth':null}));}},VoiceAgentReport['prototype'][_0x21f8e3('0x8')]=function(_0x504ded){const _0xd126d9=_0x21f8e3;let _0xa39a15='';try{this[_0xd126d9('0x22')](_0x504ded)&&(_0x504ded[_0xd126d9('0x70')]&&(_0xa39a15=_0x504ded[_0xd126d9('0x70')][_0xd126d9('0x2a')](0x0,_0x504ded[_0xd126d9('0x70')][_0xd126d9('0x1d')]('-')),this['agents'][_0xa39a15]&&(this[_0xd126d9('0x50')][_0xa39a15][_0xd126d9('0x14')]=!![])));}catch(_0x3e5b6a){logger[_0xd126d9('0x19')](_0xd126d9('0xc'),util[_0xd126d9('0x18')](_0x3e5b6a,{'showHidden':![],'depth':null}));}},VoiceAgentReport[_0x21f8e3('0x36')]['syncMusicOnHoldStop']=function(_0x151adf){const _0x3e2073=_0x21f8e3;let _0x1a7f5a='';try{this[_0x3e2073('0x22')](_0x151adf)&&(_0x151adf[_0x3e2073('0x70')]&&(_0x1a7f5a=_0x151adf[_0x3e2073('0x70')]['substring'](0x0,_0x151adf[_0x3e2073('0x70')][_0x3e2073('0x1d')]('-')),this[_0x3e2073('0x50')][_0x1a7f5a]&&(this['agents'][_0x1a7f5a]['onhold']=![])));}catch(_0x1c3204){logger[_0x3e2073('0x19')](_0x3e2073('0x1f'),util['inspect'](_0x1c3204,{'showHidden':![],'depth':null}));}},module[_0x21f8e3('0x2d')]=VoiceAgentReport; \ No newline at end of file diff --git a/server/services/ami/report/voiceCallReport.js b/server/services/ami/report/voiceCallReport.js index 5db2d03..f1dbecd 100644 --- a/server/services/ami/report/voiceCallReport.js +++ b/server/services/ami/report/voiceCallReport.js @@ -1 +1 @@ -const a1096_0xc299=['[syncMusicOnHoldStart][VoiceCallReport]','bind','ami','.WAV','YYYY-MM-DD\x20HH:mm:ss','pick','calleridname','blindtransfer','mohstarttime','newexten','blindTransfers','extension','destconnectedlinenum','calleridpreview','duration','type','ANSWERED','channel','accountcode','connectedlinenum','secondtransfereruniqueid','newstate','diff','billableseconds','inspect','application','isNil','OutgoingSpoolFailed','xmd-originatecalleridnum','exports','toNumber','calleridnum','transfereeuniqueid','monitorFilename','name','disposition','error','then','syncAttendedTransfer','endsWith','transfereecalleridnum','[syncNewExten][VoiceCallReport]','transferconnectedlinenum','omit','user:agentcomplete','agi','syncNewCallerId','log','linkedid','uniqueid','transfererchannel','keys','lastapplication','prototype','syncNewExten','newcallerid','monitors','find','sipcalllinkedid','endtime','playback','exten','syncVarSet','[syncNewState][VoiceCallReport]','agents','../../../rediscache','[syncNewCallerId][VoiceCallReport]','syncBlindTransfer','dial','starttime','push','UserId','user:agentconnect','answered','.wav49','variable','FAILED','path','match','toLowerCase','syncNewChannel','musiconholdstop','mohtime','newchannel','actionCoreShowChannels','mixmonitor_filename','isNotNull','lastdata','value','parse','transfertargetcalleridnum','transfertargetuniqueid','includes','catch','xmd-queue','syncMusicOnHoldStart','custom:voiceCallReport','channels','sipcalluniqueid','syncHangup','attendedtransfer','startsWith','originatecalleridnum','xmd-cdrtype','[syncNewChannel][VoiceCallReport]','transfercalleridnum','queue','cdr(','[syncVarSet][VoiceCallReport]','NO\x20ANSWER','hangup','user:%s','musiconholdstart','seconds','emit','varset','membername','replace','context','origtransfereruniqueid','sipcallid','from-sip','format','set','xmd-phone','syncNewState','destination','answertime','../ami','isUndefined','xmcs-queue','connectedlinename','syncMusicOnHoldStop','split','merge','../../../config/logger','lodash','BlindTransfer','syncMixMonitorFilename','channelstate','applicationdata','rec','[syncMusicOnHoldStop][VoiceCallReport]'];(function(_0x5732d3,_0xc29940){const _0x52352a=function(_0x180181){while(--_0x180181){_0x5732d3['push'](_0x5732d3['shift']());}};_0x52352a(++_0xc29940);}(a1096_0xc299,0x126));const a1096_0x5235=function(_0x5732d3,_0xc29940){_0x5732d3=_0x5732d3-0x0;let _0x52352a=a1096_0xc299[_0x5732d3];return _0x52352a;};const _0x5714ad=a1096_0x5235;'use strict';const _=require(_0x5714ad('0x80')),moment=require('moment'),util=require('util'),path=require(_0x5714ad('0x45')),logger=require(_0x5714ad('0x7f'))(_0x5714ad('0x89')),ami=require(_0x5714ad('0x78')),Channel=require('../model/channel'),applications=[_0x5714ad('0x73'),_0x5714ad('0x62'),_0x5714ad('0x25'),_0x5714ad('0x3c'),_0x5714ad('0x34'),'voicemail'],dispositions=[_0x5714ad('0x65'),'FAILED',_0x5714ad('0x44'),_0x5714ad('0x65'),_0x5714ad('0x65'),'NO\x20ANSWER',_0x5714ad('0x8'),'BUSY',_0x5714ad('0x44'),'FAILED',_0x5714ad('0x44')],{getSocket}=require(_0x5714ad('0x39')),io=getSocket();function VoiceCallReport(_0x180181){const _0xe101ad=_0x5714ad;return this[_0xe101ad('0x59')]=_0x180181['channels'],this['agents']=_0x180181[_0xe101ad('0x38')],this[_0xe101ad('0x2')]={},ami['on']('coreshowchannel',this[_0xe101ad('0x2e')]['bind'](this)),ami['on'](_0xe101ad('0x1'),this['syncNewExten']['bind'](this)),ami['on'](_0xe101ad('0x4b'),this[_0xe101ad('0x48')][_0xe101ad('0x88')](this)),ami['on'](_0xe101ad('0xd'),this[_0xe101ad('0x75')]['bind'](this)),ami['on'](_0xe101ad('0x6b'),this[_0xe101ad('0x36')][_0xe101ad('0x88')](this)),ami['on'](_0xe101ad('0x66'),this['syncHangup'][_0xe101ad('0x88')](this)),ami['on'](_0xe101ad('0x2f'),this[_0xe101ad('0x26')]['bind'](this)),ami['on'](_0xe101ad('0x5c'),this[_0xe101ad('0x1e')][_0xe101ad('0x88')](this)),ami['on'](_0xe101ad('0x8e'),this['syncBlindTransfer'][_0xe101ad('0x88')](this)),ami['on'](_0xe101ad('0x68'),this[_0xe101ad('0x57')][_0xe101ad('0x88')](this)),ami['on'](_0xe101ad('0x49'),this[_0xe101ad('0x7c')][_0xe101ad('0x88')](this)),Promise['resolve']()[_0xe101ad('0x1d')](ami[_0xe101ad('0x4c')]())[_0xe101ad('0x55')](function(_0x38d05a){const _0x519987=_0xe101ad;console[_0x519987('0x27')](_0x38d05a);});}VoiceCallReport[_0x5714ad('0x2d')][_0x5714ad('0x4e')]=function(_0x1823de){const _0x447309=_0x5714ad;return _0x1823de!==null&&!_[_0x447309('0x79')](_0x1823de);},VoiceCallReport[_0x5714ad('0x2d')][_0x5714ad('0x6a')]=function(_0x1f4f45,_0x3553e5,_0x6bedd6){const _0x516e91=_0x5714ad;io['to'](_0x1f4f45)[_0x516e91('0x6a')](_0x3553e5,_0x6bedd6);},VoiceCallReport['prototype'][_0x5714ad('0x26')]=function(_0x1559e4){const _0x4bc439=_0x5714ad;try{this['isNotNull'](_0x1559e4)&&(_0x1559e4['uniqueid']===_0x1559e4[_0x4bc439('0x28')]&&(!_['isUndefined'](this[_0x4bc439('0x59')][_0x1559e4['uniqueid']])&&_['merge'](this[_0x4bc439('0x59')][_0x1559e4[_0x4bc439('0x29')]],_['pick'](_0x1559e4,_[_0x4bc439('0x2b')](this[_0x4bc439('0x59')][_0x1559e4[_0x4bc439('0x29')]])))));}catch(_0x1523ae){logger[_0x4bc439('0x1c')](_0x4bc439('0x3a'),util['inspect'](_0x1523ae,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5714ad('0x2d')][_0x5714ad('0x48')]=function(_0x203a1a){const _0x1bf05b=_0x5714ad;try{this[_0x1bf05b('0x4e')](_0x203a1a)&&(_0x203a1a[_0x1bf05b('0x29')]===_0x203a1a[_0x1bf05b('0x28')]&&_0x203a1a[_0x1bf05b('0x9')]!='OutgoingSpoolFailed'&&(_[_0x1bf05b('0x79')](this[_0x1bf05b('0x59')][_0x203a1a[_0x1bf05b('0x29')]])&&(this[_0x1bf05b('0x59')][_0x203a1a['uniqueid']]=new Channel(),this['channels'][_0x203a1a[_0x1bf05b('0x29')]][_0x1bf05b('0x3d')]=moment()[_0x1bf05b('0x72')](_0x1bf05b('0x8b')),this[_0x1bf05b('0x59')][_0x203a1a[_0x1bf05b('0x29')]][_0x1bf05b('0x1b')]=dispositions[_['toNumber'](_0x203a1a[_0x1bf05b('0x83')])],_['merge'](this[_0x1bf05b('0x59')][_0x203a1a['uniqueid']],_[_0x1bf05b('0x8c')](_0x203a1a,_[_0x1bf05b('0x2b')](this[_0x1bf05b('0x59')][_0x203a1a[_0x1bf05b('0x29')]]))),_0x203a1a[_0x1bf05b('0x6e')]==='from-sip'&&(this[_0x1bf05b('0x38')][_0x203a1a['channel']['split']('-')[0x0]]&&(this[_0x1bf05b('0x38')][_0x203a1a[_0x1bf05b('0x9')][_0x1bf05b('0x7d')]('-')[0x0]][_0x1bf05b('0x4')]=_0x203a1a[_0x1bf05b('0x35')],this[_0x1bf05b('0x6a')](util[_0x1bf05b('0x72')](_0x1bf05b('0x67'),this[_0x1bf05b('0x38')][_0x203a1a[_0x1bf05b('0x9')][_0x1bf05b('0x7d')]('-')[0x0]]['name']),_0x1bf05b('0x40'),{'destaccountcode':this[_0x1bf05b('0x38')][_0x203a1a[_0x1bf05b('0x9')][_0x1bf05b('0x7d')]('-')[0x0]][_0x1bf05b('0xa')],'destconnectedlinenum':_0x203a1a[_0x1bf05b('0x35')]}))))));}catch(_0x15c972){logger[_0x1bf05b('0x1c')](_0x1bf05b('0x60'),util['inspect'](_0x15c972,{'showHidden':![],'depth':null}));}},VoiceCallReport['prototype'][_0x5714ad('0x2e')]=function(_0x48f9cb){const _0x21b52f=_0x5714ad;try{if(this[_0x21b52f('0x4e')](_0x48f9cb)){if(_0x48f9cb[_0x21b52f('0x29')]===_0x48f9cb['linkedid']&&_0x48f9cb[_0x21b52f('0x35')]!='h'&&_0x48f9cb[_0x21b52f('0x9')]!=_0x21b52f('0x13')){_0x48f9cb[_0x21b52f('0x11')]=_0x48f9cb['application'][_0x21b52f('0x47')](),_0x48f9cb[_0x21b52f('0x84')]=(_0x48f9cb['appdata']||_0x48f9cb[_0x21b52f('0x84')])[_0x21b52f('0x47')]();_[_0x21b52f('0x79')](this[_0x21b52f('0x59')][_0x48f9cb[_0x21b52f('0x29')]])&&(this['channels'][_0x48f9cb[_0x21b52f('0x29')]]=new Channel(),this[_0x21b52f('0x59')][_0x48f9cb['uniqueid']]['starttime']=_0x48f9cb['duration']?moment()['subtract'](moment[_0x21b52f('0x6')](_0x48f9cb['duration'])[_0x21b52f('0x69')](),_0x21b52f('0x69'))[_0x21b52f('0x72')](_0x21b52f('0x8b')):moment()[_0x21b52f('0x72')](_0x21b52f('0x8b')),this[_0x21b52f('0x59')][_0x48f9cb[_0x21b52f('0x29')]][_0x21b52f('0x1b')]='NO\x20ANSWER');_[_0x21b52f('0x7e')](this['channels'][_0x48f9cb[_0x21b52f('0x29')]],_[_0x21b52f('0x8c')](_0x48f9cb,_[_0x21b52f('0x2b')](this[_0x21b52f('0x59')][_0x48f9cb[_0x21b52f('0x29')]])));if(_[_0x21b52f('0x54')](applications,_0x48f9cb[_0x21b52f('0x11')])){this[_0x21b52f('0x59')][_0x48f9cb[_0x21b52f('0x29')]][_0x21b52f('0x2c')]=_0x48f9cb[_0x21b52f('0x11')],this[_0x21b52f('0x59')][_0x48f9cb['uniqueid']][_0x21b52f('0x4f')]=_0x48f9cb[_0x21b52f('0x84')];if(_0x48f9cb['application']==='set'&&_[_0x21b52f('0x5d')](_0x48f9cb['applicationdata'],_0x21b52f('0x63'))){const _0x1440c4=_0x48f9cb[_0x21b52f('0x84')][_0x21b52f('0x7d')]('='),_0x5204f9=_0x1440c4[0x0][_0x21b52f('0x46')](/cdr\((.*)\)/);_0x5204f9&&(this['channels'][_0x48f9cb[_0x21b52f('0x29')]][_0x5204f9[0x1]]=_0x1440c4[0x1]);}else _0x48f9cb[_0x21b52f('0x11')]===_0x21b52f('0x62')&&(this[_0x21b52f('0x59')][_0x48f9cb[_0x21b52f('0x29')]][_0x21b52f('0x62')]=_0x48f9cb[_0x21b52f('0x84')][_0x21b52f('0x7d')](',')[0x0]);}}}}catch(_0x52a924){logger[_0x21b52f('0x1c')](_0x21b52f('0x21'),util[_0x21b52f('0x10')](_0x52a924,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5714ad('0x2d')][_0x5714ad('0x75')]=function(_0x4745eb){const _0x1e596c=_0x5714ad;try{if(this[_0x1e596c('0x4e')](_0x4745eb)){if(_0x4745eb['uniqueid']!==_0x4745eb[_0x1e596c('0x28')]){if(this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x28')]]){if(_0x4745eb[_0x1e596c('0x83')]==='6'){if(!this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x28')]][_0x1e596c('0x41')]){const _0x26b92d=moment();this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x28')]]['answered']=!![],this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x28')]][_0x1e596c('0x77')]=_0x26b92d[_0x1e596c('0x72')](_0x1e596c('0x8b')),this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x28')]][_0x1e596c('0x3d')]&&(this[_0x1e596c('0x59')][_0x4745eb['linkedid']]['holdtime']=_0x26b92d[_0x1e596c('0xe')](this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x28')]][_0x1e596c('0x3d')],_0x1e596c('0x69')));}this['channels'][_0x4745eb[_0x1e596c('0x28')]][_0x1e596c('0x28')]=_0x4745eb['uniqueid'],_0x4745eb[_0x1e596c('0x17')]!=='xcally-motion-preview'&&(this['channels'][_0x4745eb[_0x1e596c('0x28')]][_0x1e596c('0xb')]=_0x4745eb[_0x1e596c('0x17')]),this['channels'][_0x4745eb[_0x1e596c('0x28')]][_0x1e596c('0x7b')]=_0x4745eb[_0x1e596c('0x8d')],this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x28')]]['destinationchannel']=_0x4745eb[_0x1e596c('0x9')],this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x28')]]['disposition']=dispositions[_[_0x1e596c('0x16')](_0x4745eb[_0x1e596c('0x83')])],this[_0x1e596c('0x38')][_0x4745eb['channel'][_0x1e596c('0x7d')]('-')[0x0]]&&(this['channels'][_0x4745eb[_0x1e596c('0x28')]][_0x1e596c('0x3f')]=this[_0x1e596c('0x38')][_0x4745eb[_0x1e596c('0x9')]['split']('-')[0x0]]['id'],this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x28')]][_0x1e596c('0x6c')]=this[_0x1e596c('0x38')][_0x4745eb['channel'][_0x1e596c('0x7d')]('-')[0x0]][_0x1e596c('0x1a')]);}}}else this[_0x1e596c('0x59')][_0x4745eb[_0x1e596c('0x29')]]&&(_0x4745eb['channelstate']==='6'&&(this[_0x1e596c('0x38')][_0x4745eb['channel'][_0x1e596c('0x7d')]('-')[0x0]]&&(this['channels'][_0x4745eb['uniqueid']][_0x1e596c('0x3f')]=this[_0x1e596c('0x38')][_0x4745eb[_0x1e596c('0x9')][_0x1e596c('0x7d')]('-')[0x0]]['id'],this[_0x1e596c('0x59')][_0x4745eb['uniqueid']][_0x1e596c('0x6c')]=this[_0x1e596c('0x38')][_0x4745eb[_0x1e596c('0x9')]['split']('-')[0x0]][_0x1e596c('0x1a')])));}}catch(_0x216a85){logger[_0x1e596c('0x1c')](_0x1e596c('0x37'),util[_0x1e596c('0x10')](_0x216a85,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5714ad('0x2d')][_0x5714ad('0x82')]=function(_0x274aa1,_0xf65e4e){const _0x5a8e83=_0x5714ad;if(this[_0x5a8e83('0x59')][_0x274aa1]){this[_0x5a8e83('0x59')][_0x274aa1]['monitor']=!![];_[_0x5a8e83('0x1f')](_0xf65e4e,_0x5a8e83('0x42'))&&(_0xf65e4e=_0xf65e4e[_0x5a8e83('0x6d')]('.wav49',_0x5a8e83('0x8a')));this[_0x5a8e83('0x59')][_0x274aa1][_0x5a8e83('0x19')]=_0xf65e4e;const _0x5d76f8=_[_0x5a8e83('0x31')](this['channels'][_0x274aa1]['monitors'],{'filename':_0xf65e4e});_[_0x5a8e83('0x12')](_0x5d76f8)&&this[_0x5a8e83('0x59')][_0x274aa1][_0x5a8e83('0x30')][_0x5a8e83('0x3e')]({'filename':_0xf65e4e,'createdAt':moment()['format'](_0x5a8e83('0x8b')),'mixmonitorid':'','status':_0x5a8e83('0x85')});}},VoiceCallReport[_0x5714ad('0x2d')][_0x5714ad('0x36')]=function(_0x488b44){const _0x429177=_0x5714ad;try{if(this[_0x429177('0x4e')](_0x488b44)){if(this[_0x429177('0x59')][_0x488b44[_0x429177('0x29')]]&&_0x488b44[_0x429177('0x9')]!=_0x429177('0x13')){if(this[_0x429177('0x4e')](_0x488b44[_0x429177('0x43')])){if(this[_0x429177('0x4e')](_0x488b44['variable'][_0x429177('0x4d')]))this[_0x429177('0x82')](_0x488b44['uniqueid'],_0x488b44[_0x429177('0x50')]);else{if(this['isNotNull'](_0x488b44[_0x429177('0x43')][_0x429177('0x74')]))this[_0x429177('0x59')][_0x488b44[_0x429177('0x29')]][_0x429177('0x17')]=_0x488b44[_0x429177('0x50')];else{if(this[_0x429177('0x4e')](_0x488b44['variable']['xmd-callerid']))this['channels'][_0x488b44[_0x429177('0x29')]]['callerid']=_0x488b44['value'];else{if(this[_0x429177('0x4e')](_0x488b44[_0x429177('0x43')][_0x429177('0x5f')]))this['channels'][_0x488b44[_0x429177('0x29')]][_0x429177('0x7')]=_0x488b44[_0x429177('0x50')];else{if(this[_0x429177('0x4e')](_0x488b44['variable'][_0x429177('0x56')]))this[_0x429177('0x59')][_0x488b44[_0x429177('0x29')]]['queue']=_0x488b44[_0x429177('0x50')][_0x429177('0x7d')](',')[0x0];else{if(this['isNotNull'](_0x488b44['variable'][_0x429177('0x14')]))this[_0x429177('0x59')][_0x488b44[_0x429177('0x29')]][_0x429177('0x5e')]=_0x488b44[_0x429177('0x50')];else{if(this['isNotNull'](_0x488b44[_0x429177('0x43')]['xmd-destination']))this[_0x429177('0x59')][_0x488b44[_0x429177('0x29')]][_0x429177('0x76')]=_0x488b44[_0x429177('0x50')];else{if(this[_0x429177('0x4e')](_0x488b44[_0x429177('0x43')]['xmd-callerid-preview']))this['channels'][_0x488b44[_0x429177('0x29')]][_0x429177('0x5')]=_0x488b44[_0x429177('0x50')];else{if(this[_0x429177('0x4e')](_0x488b44[_0x429177('0x43')][_0x429177('0x7a')]))this[_0x429177('0x59')][_0x488b44[_0x429177('0x29')]][_0x429177('0x62')]=_0x488b44[_0x429177('0x50')];else this[_0x429177('0x4e')](_0x488b44['variable'][_0x429177('0x70')])&&(this[_0x429177('0x59')][_0x488b44[_0x429177('0x29')]][_0x429177('0x5a')]=_0x488b44[_0x429177('0x50')]);}}}}}}}}}}else{if(this[_0x429177('0x4e')](_0x488b44['variable'][_0x429177('0x4d')])){if(_0x488b44[_0x429177('0x50')]){const _0x3c43b7=path[_0x429177('0x51')](_0x488b44[_0x429177('0x50')])['name'];this[_0x429177('0x82')](_0x3c43b7,_0x488b44[_0x429177('0x50')]);}}else this[_0x429177('0x59')][_0x488b44[_0x429177('0x28')]]&&(this[_0x429177('0x4e')](_0x488b44[_0x429177('0x43')])&&(this[_0x429177('0x4e')](_0x488b44[_0x429177('0x43')][_0x429177('0x70')])&&(this[_0x429177('0x59')][_0x488b44[_0x429177('0x28')]][_0x429177('0x32')]=_0x488b44['value'])));}}}catch(_0x5f13bf){logger[_0x429177('0x1c')](_0x429177('0x64'),util[_0x429177('0x10')](_0x5f13bf,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5714ad('0x2d')]['syncHangup']=function(_0x4437c6){const _0x2e8a76=_0x5714ad;try{if(this[_0x2e8a76('0x4e')](_0x4437c6)){if(this[_0x2e8a76('0x59')][_0x4437c6[_0x2e8a76('0x29')]]){const _0x37001a=moment();this[_0x2e8a76('0x59')][_0x4437c6[_0x2e8a76('0x29')]][_0x2e8a76('0x33')]=_0x37001a[_0x2e8a76('0x72')](_0x2e8a76('0x8b')),this[_0x2e8a76('0x59')][_0x4437c6[_0x2e8a76('0x29')]][_0x2e8a76('0x6')]=_0x37001a[_0x2e8a76('0xe')](this[_0x2e8a76('0x59')][_0x4437c6[_0x2e8a76('0x29')]]['starttime'],_0x2e8a76('0x69')),this[_0x2e8a76('0x59')][_0x4437c6['uniqueid']]['answered']&&(this[_0x2e8a76('0x59')][_0x4437c6[_0x2e8a76('0x29')]][_0x2e8a76('0xf')]=_0x37001a['diff'](this[_0x2e8a76('0x59')][_0x4437c6[_0x2e8a76('0x29')]][_0x2e8a76('0x77')],_0x2e8a76('0x69')),this[_0x2e8a76('0x59')][_0x4437c6[_0x2e8a76('0x29')]]['holdtime']=this['channels'][_0x4437c6[_0x2e8a76('0x29')]]['duration']-this[_0x2e8a76('0x59')][_0x4437c6['uniqueid']][_0x2e8a76('0xf')]),_0x4437c6[_0x2e8a76('0x6e')]===_0x2e8a76('0x71')&&(this[_0x2e8a76('0x38')][_0x4437c6['channel']['split']('-')[0x0]]&&(this[_0x2e8a76('0x38')][_0x4437c6[_0x2e8a76('0x9')]['split']('-')[0x0]]=_[_0x2e8a76('0x23')](this[_0x2e8a76('0x38')][_0x4437c6[_0x2e8a76('0x9')]['split']('-')[0x0]],[_0x2e8a76('0x4')]),this[_0x2e8a76('0x6a')](util[_0x2e8a76('0x72')]('user:%s',this[_0x2e8a76('0x38')][_0x4437c6[_0x2e8a76('0x9')][_0x2e8a76('0x7d')]('-')[0x0]][_0x2e8a76('0x1a')]),_0x2e8a76('0x24'),{'destaccountcode':this[_0x2e8a76('0x38')][_0x4437c6[_0x2e8a76('0x9')][_0x2e8a76('0x7d')]('-')[0x0]][_0x2e8a76('0xa')]}))),_0x4437c6['event']===_0x2e8a76('0x81')?this[_0x2e8a76('0x2')][_0x4437c6[_0x2e8a76('0x29')]]=this['channels'][_0x4437c6[_0x2e8a76('0x29')]]:this[_0x2e8a76('0x59')][_0x4437c6[_0x2e8a76('0x29')]][_0x2e8a76('0x7')]==='outbound'&&this[_0x2e8a76('0x2')][_0x4437c6['uniqueid']]&&(this[_0x2e8a76('0x59')][_0x4437c6['uniqueid']][_0x2e8a76('0x29')]=[this['channels'][_0x4437c6[_0x2e8a76('0x29')]][_0x2e8a76('0x28')],this[_0x2e8a76('0x59')][_0x4437c6[_0x2e8a76('0x29')]][_0x2e8a76('0x28')]=this[_0x2e8a76('0x59')][_0x4437c6['uniqueid']][_0x2e8a76('0x29')]][0x0],delete this[_0x2e8a76('0x2')][_0x4437c6[_0x2e8a76('0x29')]]),ami[_0x2e8a76('0x6a')](_0x2e8a76('0x58'),this['channels'][_0x4437c6[_0x2e8a76('0x29')]]),delete this['channels'][_0x4437c6[_0x2e8a76('0x29')]];}}}catch(_0x47bcab){logger['error']('[syncHangup][VoiceCallReport]',util['inspect'](_0x47bcab,{'showHidden':![],'depth':null}));}},VoiceCallReport['prototype']['syncAttendedTransfer']=function(_0x42a305){const _0x28adce=_0x5714ad;try{if(this[_0x28adce('0x4e')](_0x42a305)){if(this[_0x28adce('0x59')][_0x42a305[_0x28adce('0x18')]]){this['channels'][_0x42a305[_0x28adce('0x18')]]['transfercalleridnum']=_0x42a305['origtransferercalleridnum'],this[_0x28adce('0x59')][_0x42a305[_0x28adce('0x18')]][_0x28adce('0x22')]=_0x42a305['transfertargetcalleridnum'];if(this[_0x28adce('0x59')][_0x42a305[_0x28adce('0xc')]]){const _0x1a9be9=this[_0x28adce('0x59')][_0x42a305[_0x28adce('0xc')]];this[_0x28adce('0x59')][_0x42a305[_0x28adce('0xc')]]=this['channels'][_0x42a305[_0x28adce('0x18')]],this[_0x28adce('0x59')][_0x42a305['transfereeuniqueid']]=_0x1a9be9;}}else{if(this[_0x28adce('0x59')][_0x42a305[_0x28adce('0x53')]]){this['channels'][_0x42a305[_0x28adce('0x53')]][_0x28adce('0x61')]=_0x42a305['origtransferercalleridnum'],this[_0x28adce('0x59')][_0x42a305[_0x28adce('0x53')]][_0x28adce('0x22')]=_0x42a305[_0x28adce('0x52')];if(this[_0x28adce('0x59')][_0x42a305[_0x28adce('0x6f')]]){const _0x37b7b7=this['channels'][_0x42a305['origtransfereruniqueid']];this['channels'][_0x42a305[_0x28adce('0x6f')]]=this[_0x28adce('0x59')][_0x42a305[_0x28adce('0x53')]],this[_0x28adce('0x59')][_0x42a305[_0x28adce('0x53')]]=_0x37b7b7;}}}}}catch(_0x441941){logger[_0x28adce('0x1c')]('[syncAttendedTransfer][VoiceCallReport]',util['inspect'](_0x441941,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5714ad('0x2d')][_0x5714ad('0x3b')]=function(_0x1ef4e8){const _0x27896a=_0x5714ad;try{this[_0x27896a('0x4e')](_0x1ef4e8)&&(this[_0x27896a('0x59')][_0x1ef4e8[_0x27896a('0x18')]]&&(this[_0x27896a('0x59')][_0x1ef4e8[_0x27896a('0x18')]][_0x27896a('0x61')]=_0x1ef4e8[_0x27896a('0x20')],this['channels'][_0x1ef4e8[_0x27896a('0x18')]][_0x27896a('0x22')]=_0x1ef4e8[_0x27896a('0x3')],this[_0x27896a('0x5b')]({'event':'BlindTransfer','uniqueid':_0x1ef4e8[_0x27896a('0x18')],'context':_0x1ef4e8['context'],'channel':_0x1ef4e8[_0x27896a('0x2a')]})));}catch(_0x551aaa){logger['error']('[syncBlindTransfer][VoiceCallReport]',util[_0x27896a('0x10')](_0x551aaa,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5714ad('0x2d')][_0x5714ad('0x57')]=function(_0xa45567){const _0x200dc8=_0x5714ad;try{this[_0x200dc8('0x4e')](_0xa45567)&&(this['channels'][_0xa45567[_0x200dc8('0x29')]]&&(!_[_0x200dc8('0x12')](this[_0x200dc8('0x59')][_0xa45567[_0x200dc8('0x29')]]['answertime'])&&(this['channels'][_0xa45567[_0x200dc8('0x29')]][_0x200dc8('0x0')]=moment()[_0x200dc8('0x72')]('YYYY-MM-DD\x20HH:mm:ss'))));}catch(_0x54c936){logger[_0x200dc8('0x1c')](_0x200dc8('0x87'),util[_0x200dc8('0x10')](_0x54c936,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5714ad('0x2d')][_0x5714ad('0x7c')]=function(_0xf9b9c0){const _0x3a50bd=_0x5714ad;try{this[_0x3a50bd('0x4e')](_0xf9b9c0)&&(this[_0x3a50bd('0x59')][_0xf9b9c0['uniqueid']]&&(!_[_0x3a50bd('0x12')](this[_0x3a50bd('0x59')][_0xf9b9c0[_0x3a50bd('0x29')]]['mohstarttime'])&&(this['channels'][_0xf9b9c0[_0x3a50bd('0x29')]][_0x3a50bd('0x4a')]+=moment()['milliseconds'](0x0)[_0x3a50bd('0xe')](this[_0x3a50bd('0x59')][_0xf9b9c0[_0x3a50bd('0x29')]][_0x3a50bd('0x0')],_0x3a50bd('0x69')),delete this[_0x3a50bd('0x59')][_0xf9b9c0['uniqueid']][_0x3a50bd('0x0')])));}catch(_0x308c75){logger['error'](_0x3a50bd('0x86'),util[_0x3a50bd('0x10')](_0x308c75,{'showHidden':![],'depth':null}));}},module[_0x5714ad('0x15')]=VoiceCallReport; \ No newline at end of file +const a1096_0x1c80=['calleridname','bind','agents','[syncNewCallerId][VoiceCallReport]','syncNewCallerId','[syncMusicOnHoldStop][VoiceCallReport]','syncNewExten','error','match','path','from-sip','[syncMusicOnHoldStart][VoiceCallReport]','../../../config/logger','holdtime','newchannel','split','outbound','UserId','.WAV','toLowerCase','sipcalllinkedid','channels','../../../rediscache','starttime','[syncNewExten][VoiceCallReport]','application','includes','set','prototype','../ami','omit','applicationdata','mohtime','../model/channel','mohstarttime','xmd-callerid','[syncVarSet][VoiceCallReport]','transfertargetcalleridnum','destconnectedlinenum','actionCoreShowChannels','syncMusicOnHoldStart','extension','playback','syncHangup','calleridnum','billableseconds','syncMixMonitorFilename','user:agentconnect','format','syncNewChannel','disposition','resolve','lodash','exports','destinationchannel','[syncNewState][VoiceCallReport]','dial','value','connectedlinename','linkedid','coreshowchannel','isUndefined','callerid','.wav49','xmd-cdrtype','NO\x20ANSWER','seconds','user:%s','newcallerid','lastdata','origtransfereruniqueid','membername','xmcs-queue','duration','startsWith','transferconnectedlinenum','YYYY-MM-DD\x20HH:mm:ss','isNil','replace','transfercalleridnum','then','agi','voicemail','transfereecalleridnum','blindTransfers','mixmonitor_filename','ANSWERED','diff','syncVarSet','calleridpreview','channel','context','accountcode','answered','endtime','blindtransfer','varset','syncMusicOnHoldStop','merge','uniqueid','appdata','endsWith','emit','variable','transfereeuniqueid','find','BlindTransfer','syncAttendedTransfer','[syncNewChannel][VoiceCallReport]','type','isNotNull','origtransferercalleridnum','transfertargetuniqueid','push','name','pick','xmd-callerid-preview','custom:voiceCallReport','xmd-destination','newstate','hangup','log','answertime','newexten','[syncBlindTransfer][VoiceCallReport]','keys','OutgoingSpoolFailed','syncNewState','musiconholdstart','monitorFilename','inspect','monitors','exten','syncBlindTransfer','FAILED','milliseconds','channelstate','queue','event','secondtransfereruniqueid'];(function(_0x28012b,_0x1c8024){const _0x22c66e=function(_0x303808){while(--_0x303808){_0x28012b['push'](_0x28012b['shift']());}};_0x22c66e(++_0x1c8024);}(a1096_0x1c80,0x171));const a1096_0x22c6=function(_0x28012b,_0x1c8024){_0x28012b=_0x28012b-0x0;let _0x22c66e=a1096_0x1c80[_0x28012b];return _0x22c66e;};const _0x5e5ddb=a1096_0x22c6;'use strict';const _=require(_0x5e5ddb('0x67')),moment=require('moment'),util=require('util'),path=require(_0x5e5ddb('0x3c')),logger=require(_0x5e5ddb('0x3f'))('ami'),ami=require(_0x5e5ddb('0x50')),Channel=require(_0x5e5ddb('0x54')),applications=[_0x5e5ddb('0x4e'),_0x5e5ddb('0x30'),_0x5e5ddb('0x84'),_0x5e5ddb('0x6b'),_0x5e5ddb('0x5d'),_0x5e5ddb('0x85')],dispositions=['NO\x20ANSWER',_0x5e5ddb('0x2d'),_0x5e5ddb('0x2d'),_0x5e5ddb('0x74'),_0x5e5ddb('0x74'),_0x5e5ddb('0x74'),_0x5e5ddb('0x89'),'BUSY',_0x5e5ddb('0x2d'),_0x5e5ddb('0x2d'),'FAILED'],{getSocket}=require(_0x5e5ddb('0x49')),io=getSocket();function VoiceCallReport(_0x303808){const _0xb00ba5=_0x5e5ddb;return this['channels']=_0x303808[_0xb00ba5('0x48')],this['agents']=_0x303808[_0xb00ba5('0x35')],this['blindTransfers']={},ami['on'](_0xb00ba5('0x6f'),this['syncNewExten'][_0xb00ba5('0x34')](this)),ami['on'](_0xb00ba5('0x22'),this[_0xb00ba5('0x39')][_0xb00ba5('0x34')](this)),ami['on'](_0xb00ba5('0x41'),this[_0xb00ba5('0x64')]['bind'](this)),ami['on'](_0xb00ba5('0x1e'),this[_0xb00ba5('0x26')][_0xb00ba5('0x34')](this)),ami['on'](_0xb00ba5('0x7'),this[_0xb00ba5('0x8b')][_0xb00ba5('0x34')](this)),ami['on'](_0xb00ba5('0x1f'),this[_0xb00ba5('0x5e')]['bind'](this)),ami['on'](_0xb00ba5('0x77'),this[_0xb00ba5('0x37')]['bind'](this)),ami['on']('attendedtransfer',this[_0xb00ba5('0x12')][_0xb00ba5('0x34')](this)),ami['on'](_0xb00ba5('0x6'),this['syncBlindTransfer'][_0xb00ba5('0x34')](this)),ami['on'](_0xb00ba5('0x27'),this[_0xb00ba5('0x5b')][_0xb00ba5('0x34')](this)),ami['on']('musiconholdstop',this[_0xb00ba5('0x8')]['bind'](this)),Promise[_0xb00ba5('0x66')]()[_0xb00ba5('0x83')](ami[_0xb00ba5('0x5a')]())['catch'](function(_0x2e1ac8){const _0x16979d=_0xb00ba5;console[_0x16979d('0x20')](_0x2e1ac8);});}VoiceCallReport['prototype']['isNotNull']=function(_0x39d6da){const _0x8d3b19=_0x5e5ddb;return _0x39d6da!==null&&!_[_0x8d3b19('0x70')](_0x39d6da);},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0xd')]=function(_0x5cfd0b,_0x5823d4,_0x5e380c){const _0x2b160d=_0x5e5ddb;io['to'](_0x5cfd0b)[_0x2b160d('0xd')](_0x5823d4,_0x5e380c);},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0x37')]=function(_0x14a912){const _0x459460=_0x5e5ddb;try{this[_0x459460('0x15')](_0x14a912)&&(_0x14a912[_0x459460('0xa')]===_0x14a912[_0x459460('0x6e')]&&(!_[_0x459460('0x70')](this['channels'][_0x14a912[_0x459460('0xa')]])&&_[_0x459460('0x9')](this['channels'][_0x14a912[_0x459460('0xa')]],_[_0x459460('0x1a')](_0x14a912,_['keys'](this[_0x459460('0x48')][_0x14a912[_0x459460('0xa')]])))));}catch(_0xe6ca4e){logger[_0x459460('0x3a')](_0x459460('0x36'),util[_0x459460('0x29')](_0xe6ca4e,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0x64')]=function(_0x1f9efc){const _0x295389=_0x5e5ddb;try{this[_0x295389('0x15')](_0x1f9efc)&&(_0x1f9efc[_0x295389('0xa')]===_0x1f9efc[_0x295389('0x6e')]&&_0x1f9efc[_0x295389('0x1')]!=_0x295389('0x25')&&(_[_0x295389('0x70')](this[_0x295389('0x48')][_0x1f9efc[_0x295389('0xa')]])&&(this[_0x295389('0x48')][_0x1f9efc[_0x295389('0xa')]]=new Channel(),this[_0x295389('0x48')][_0x1f9efc['uniqueid']]['starttime']=moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),this[_0x295389('0x48')][_0x1f9efc[_0x295389('0xa')]][_0x295389('0x65')]=dispositions[_['toNumber'](_0x1f9efc[_0x295389('0x2f')])],_[_0x295389('0x9')](this[_0x295389('0x48')][_0x1f9efc['uniqueid']],_[_0x295389('0x1a')](_0x1f9efc,_[_0x295389('0x24')](this[_0x295389('0x48')][_0x1f9efc[_0x295389('0xa')]]))),_0x1f9efc[_0x295389('0x2')]===_0x295389('0x3d')&&(this[_0x295389('0x35')][_0x1f9efc[_0x295389('0x1')]['split']('-')[0x0]]&&(this[_0x295389('0x35')][_0x1f9efc[_0x295389('0x1')][_0x295389('0x42')]('-')[0x0]][_0x295389('0x59')]=_0x1f9efc[_0x295389('0x2b')],this['emit'](util[_0x295389('0x63')](_0x295389('0x76'),this[_0x295389('0x35')][_0x1f9efc[_0x295389('0x1')][_0x295389('0x42')]('-')[0x0]][_0x295389('0x19')]),_0x295389('0x62'),{'destaccountcode':this[_0x295389('0x35')][_0x1f9efc[_0x295389('0x1')][_0x295389('0x42')]('-')[0x0]][_0x295389('0x3')],'destconnectedlinenum':_0x1f9efc['exten']}))))));}catch(_0x5630aa){logger[_0x295389('0x3a')](_0x295389('0x13'),util[_0x295389('0x29')](_0x5630aa,{'showHidden':![],'depth':null}));}},VoiceCallReport['prototype'][_0x5e5ddb('0x39')]=function(_0x1ceaad){const _0x593cc0=_0x5e5ddb;try{if(this[_0x593cc0('0x15')](_0x1ceaad)){if(_0x1ceaad[_0x593cc0('0xa')]===_0x1ceaad['linkedid']&&_0x1ceaad[_0x593cc0('0x2b')]!='h'&&_0x1ceaad[_0x593cc0('0x1')]!=_0x593cc0('0x25')){_0x1ceaad[_0x593cc0('0x4c')]=_0x1ceaad['application'][_0x593cc0('0x46')](),_0x1ceaad['applicationdata']=(_0x1ceaad[_0x593cc0('0xb')]||_0x1ceaad[_0x593cc0('0x52')])[_0x593cc0('0x46')]();_[_0x593cc0('0x70')](this[_0x593cc0('0x48')][_0x1ceaad['uniqueid']])&&(this[_0x593cc0('0x48')][_0x1ceaad[_0x593cc0('0xa')]]=new Channel(),this['channels'][_0x1ceaad[_0x593cc0('0xa')]][_0x593cc0('0x4a')]=_0x1ceaad[_0x593cc0('0x7c')]?moment()['subtract'](moment['duration'](_0x1ceaad['duration'])[_0x593cc0('0x75')](),_0x593cc0('0x75'))['format'](_0x593cc0('0x7f')):moment()[_0x593cc0('0x63')](_0x593cc0('0x7f')),this[_0x593cc0('0x48')][_0x1ceaad[_0x593cc0('0xa')]][_0x593cc0('0x65')]='NO\x20ANSWER');_[_0x593cc0('0x9')](this[_0x593cc0('0x48')][_0x1ceaad[_0x593cc0('0xa')]],_[_0x593cc0('0x1a')](_0x1ceaad,_[_0x593cc0('0x24')](this['channels'][_0x1ceaad[_0x593cc0('0xa')]])));if(_[_0x593cc0('0x4d')](applications,_0x1ceaad[_0x593cc0('0x4c')])){this[_0x593cc0('0x48')][_0x1ceaad[_0x593cc0('0xa')]]['lastapplication']=_0x1ceaad[_0x593cc0('0x4c')],this['channels'][_0x1ceaad[_0x593cc0('0xa')]][_0x593cc0('0x78')]=_0x1ceaad[_0x593cc0('0x52')];if(_0x1ceaad[_0x593cc0('0x4c')]==='set'&&_[_0x593cc0('0x7d')](_0x1ceaad[_0x593cc0('0x52')],'cdr(')){const _0x5b8188=_0x1ceaad[_0x593cc0('0x52')][_0x593cc0('0x42')]('='),_0x5c0032=_0x5b8188[0x0][_0x593cc0('0x3b')](/cdr\((.*)\)/);_0x5c0032&&(this['channels'][_0x1ceaad['uniqueid']][_0x5c0032[0x1]]=_0x5b8188[0x1]);}else _0x1ceaad[_0x593cc0('0x4c')]==='queue'&&(this[_0x593cc0('0x48')][_0x1ceaad[_0x593cc0('0xa')]]['queue']=_0x1ceaad['applicationdata']['split'](',')[0x0]);}}}}catch(_0x3d3b7b){logger['error'](_0x593cc0('0x4b'),util['inspect'](_0x3d3b7b,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0x26')]=function(_0x3ea76d){const _0x443ea1=_0x5e5ddb;try{if(this[_0x443ea1('0x15')](_0x3ea76d)){if(_0x3ea76d[_0x443ea1('0xa')]!==_0x3ea76d[_0x443ea1('0x6e')]){if(this['channels'][_0x3ea76d[_0x443ea1('0x6e')]]){if(_0x3ea76d[_0x443ea1('0x2f')]==='6'){if(!this['channels'][_0x3ea76d[_0x443ea1('0x6e')]][_0x443ea1('0x4')]){const _0x151ff5=moment();this[_0x443ea1('0x48')][_0x3ea76d['linkedid']][_0x443ea1('0x4')]=!![],this['channels'][_0x3ea76d[_0x443ea1('0x6e')]]['answertime']=_0x151ff5['format'](_0x443ea1('0x7f')),this['channels'][_0x3ea76d[_0x443ea1('0x6e')]][_0x443ea1('0x4a')]&&(this[_0x443ea1('0x48')][_0x3ea76d[_0x443ea1('0x6e')]][_0x443ea1('0x40')]=_0x151ff5[_0x443ea1('0x8a')](this[_0x443ea1('0x48')][_0x3ea76d['linkedid']][_0x443ea1('0x4a')],_0x443ea1('0x75')));}this[_0x443ea1('0x48')][_0x3ea76d[_0x443ea1('0x6e')]]['linkedid']=_0x3ea76d['uniqueid'],_0x3ea76d['calleridnum']!=='xcally-motion-preview'&&(this[_0x443ea1('0x48')][_0x3ea76d['linkedid']]['connectedlinenum']=_0x3ea76d[_0x443ea1('0x5f')]),this[_0x443ea1('0x48')][_0x3ea76d[_0x443ea1('0x6e')]][_0x443ea1('0x6d')]=_0x3ea76d[_0x443ea1('0x33')],this[_0x443ea1('0x48')][_0x3ea76d[_0x443ea1('0x6e')]][_0x443ea1('0x69')]=_0x3ea76d['channel'],this[_0x443ea1('0x48')][_0x3ea76d['linkedid']][_0x443ea1('0x65')]=dispositions[_['toNumber'](_0x3ea76d[_0x443ea1('0x2f')])],this[_0x443ea1('0x35')][_0x3ea76d[_0x443ea1('0x1')][_0x443ea1('0x42')]('-')[0x0]]&&(this[_0x443ea1('0x48')][_0x3ea76d[_0x443ea1('0x6e')]][_0x443ea1('0x44')]=this['agents'][_0x3ea76d[_0x443ea1('0x1')][_0x443ea1('0x42')]('-')[0x0]]['id'],this[_0x443ea1('0x48')][_0x3ea76d['linkedid']][_0x443ea1('0x7a')]=this[_0x443ea1('0x35')][_0x3ea76d[_0x443ea1('0x1')]['split']('-')[0x0]][_0x443ea1('0x19')]);}}}else this[_0x443ea1('0x48')][_0x3ea76d[_0x443ea1('0xa')]]&&(_0x3ea76d[_0x443ea1('0x2f')]==='6'&&(this[_0x443ea1('0x35')][_0x3ea76d[_0x443ea1('0x1')][_0x443ea1('0x42')]('-')[0x0]]&&(this[_0x443ea1('0x48')][_0x3ea76d[_0x443ea1('0xa')]][_0x443ea1('0x44')]=this[_0x443ea1('0x35')][_0x3ea76d[_0x443ea1('0x1')][_0x443ea1('0x42')]('-')[0x0]]['id'],this[_0x443ea1('0x48')][_0x3ea76d[_0x443ea1('0xa')]][_0x443ea1('0x7a')]=this['agents'][_0x3ea76d[_0x443ea1('0x1')][_0x443ea1('0x42')]('-')[0x0]][_0x443ea1('0x19')])));}}catch(_0x154b63){logger[_0x443ea1('0x3a')](_0x443ea1('0x6a'),util['inspect'](_0x154b63,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0x61')]=function(_0x3b10c0,_0xe39c){const _0x21f284=_0x5e5ddb;if(this[_0x21f284('0x48')][_0x3b10c0]){this[_0x21f284('0x48')][_0x3b10c0]['monitor']=!![];_[_0x21f284('0xc')](_0xe39c,_0x21f284('0x72'))&&(_0xe39c=_0xe39c[_0x21f284('0x81')]('.wav49',_0x21f284('0x45')));this[_0x21f284('0x48')][_0x3b10c0][_0x21f284('0x28')]=_0xe39c;const _0x518847=_[_0x21f284('0x10')](this['channels'][_0x3b10c0][_0x21f284('0x2a')],{'filename':_0xe39c});_[_0x21f284('0x80')](_0x518847)&&this[_0x21f284('0x48')][_0x3b10c0]['monitors'][_0x21f284('0x18')]({'filename':_0xe39c,'createdAt':moment()['format'](_0x21f284('0x7f')),'mixmonitorid':'','status':'rec'});}},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0x8b')]=function(_0x5895cc){const _0x10ecf=_0x5e5ddb;try{if(this['isNotNull'](_0x5895cc)){if(this[_0x10ecf('0x48')][_0x5895cc['uniqueid']]&&_0x5895cc[_0x10ecf('0x1')]!=_0x10ecf('0x25')){if(this['isNotNull'](_0x5895cc['variable'])){if(this[_0x10ecf('0x15')](_0x5895cc['variable']['mixmonitor_filename']))this[_0x10ecf('0x61')](_0x5895cc[_0x10ecf('0xa')],_0x5895cc['value']);else{if(this[_0x10ecf('0x15')](_0x5895cc[_0x10ecf('0xe')]['xmd-phone']))this[_0x10ecf('0x48')][_0x5895cc[_0x10ecf('0xa')]]['calleridnum']=_0x5895cc['value'];else{if(this['isNotNull'](_0x5895cc[_0x10ecf('0xe')][_0x10ecf('0x56')]))this[_0x10ecf('0x48')][_0x5895cc[_0x10ecf('0xa')]][_0x10ecf('0x71')]=_0x5895cc[_0x10ecf('0x6c')];else{if(this['isNotNull'](_0x5895cc[_0x10ecf('0xe')][_0x10ecf('0x73')]))this[_0x10ecf('0x48')][_0x5895cc['uniqueid']][_0x10ecf('0x14')]=_0x5895cc[_0x10ecf('0x6c')];else{if(this['isNotNull'](_0x5895cc['variable']['xmd-queue']))this['channels'][_0x5895cc['uniqueid']][_0x10ecf('0x30')]=_0x5895cc['value'][_0x10ecf('0x42')](',')[0x0];else{if(this['isNotNull'](_0x5895cc['variable']['xmd-originatecalleridnum']))this[_0x10ecf('0x48')][_0x5895cc['uniqueid']]['originatecalleridnum']=_0x5895cc[_0x10ecf('0x6c')];else{if(this['isNotNull'](_0x5895cc['variable'][_0x10ecf('0x1d')]))this[_0x10ecf('0x48')][_0x5895cc['uniqueid']]['destination']=_0x5895cc['value'];else{if(this[_0x10ecf('0x15')](_0x5895cc[_0x10ecf('0xe')][_0x10ecf('0x1b')]))this[_0x10ecf('0x48')][_0x5895cc['uniqueid']][_0x10ecf('0x0')]=_0x5895cc['value'];else{if(this[_0x10ecf('0x15')](_0x5895cc[_0x10ecf('0xe')][_0x10ecf('0x7b')]))this[_0x10ecf('0x48')][_0x5895cc[_0x10ecf('0xa')]][_0x10ecf('0x30')]=_0x5895cc['value'];else this[_0x10ecf('0x15')](_0x5895cc[_0x10ecf('0xe')]['sipcallid'])&&(this[_0x10ecf('0x48')][_0x5895cc[_0x10ecf('0xa')]]['sipcalluniqueid']=_0x5895cc['value']);}}}}}}}}}}else{if(this[_0x10ecf('0x15')](_0x5895cc[_0x10ecf('0xe')][_0x10ecf('0x88')])){if(_0x5895cc['value']){const _0x1cc173=path['parse'](_0x5895cc['value'])[_0x10ecf('0x19')];this[_0x10ecf('0x61')](_0x1cc173,_0x5895cc[_0x10ecf('0x6c')]);}}else this[_0x10ecf('0x48')][_0x5895cc[_0x10ecf('0x6e')]]&&(this[_0x10ecf('0x15')](_0x5895cc['variable'])&&(this[_0x10ecf('0x15')](_0x5895cc[_0x10ecf('0xe')]['sipcallid'])&&(this[_0x10ecf('0x48')][_0x5895cc['linkedid']][_0x10ecf('0x47')]=_0x5895cc[_0x10ecf('0x6c')])));}}}catch(_0x154fdf){logger[_0x10ecf('0x3a')](_0x10ecf('0x57'),util[_0x10ecf('0x29')](_0x154fdf,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0x5e')]=function(_0x49060f){const _0x428940=_0x5e5ddb;try{if(this[_0x428940('0x15')](_0x49060f)){if(this['channels'][_0x49060f[_0x428940('0xa')]]){const _0x3056d5=moment();this[_0x428940('0x48')][_0x49060f['uniqueid']][_0x428940('0x5')]=_0x3056d5['format'](_0x428940('0x7f')),this[_0x428940('0x48')][_0x49060f['uniqueid']][_0x428940('0x7c')]=_0x3056d5[_0x428940('0x8a')](this[_0x428940('0x48')][_0x49060f[_0x428940('0xa')]][_0x428940('0x4a')],_0x428940('0x75')),this[_0x428940('0x48')][_0x49060f[_0x428940('0xa')]][_0x428940('0x4')]&&(this['channels'][_0x49060f[_0x428940('0xa')]][_0x428940('0x60')]=_0x3056d5[_0x428940('0x8a')](this[_0x428940('0x48')][_0x49060f[_0x428940('0xa')]][_0x428940('0x21')],_0x428940('0x75')),this['channels'][_0x49060f[_0x428940('0xa')]][_0x428940('0x40')]=this['channels'][_0x49060f['uniqueid']][_0x428940('0x7c')]-this['channels'][_0x49060f[_0x428940('0xa')]]['billableseconds']),_0x49060f[_0x428940('0x2')]===_0x428940('0x3d')&&(this['agents'][_0x49060f[_0x428940('0x1')]['split']('-')[0x0]]&&(this[_0x428940('0x35')][_0x49060f[_0x428940('0x1')][_0x428940('0x42')]('-')[0x0]]=_[_0x428940('0x51')](this['agents'][_0x49060f[_0x428940('0x1')]['split']('-')[0x0]],[_0x428940('0x59')]),this[_0x428940('0xd')](util['format']('user:%s',this[_0x428940('0x35')][_0x49060f[_0x428940('0x1')][_0x428940('0x42')]('-')[0x0]][_0x428940('0x19')]),'user:agentcomplete',{'destaccountcode':this['agents'][_0x49060f[_0x428940('0x1')][_0x428940('0x42')]('-')[0x0]][_0x428940('0x3')]}))),_0x49060f[_0x428940('0x31')]===_0x428940('0x11')?this[_0x428940('0x87')][_0x49060f['uniqueid']]=this[_0x428940('0x48')][_0x49060f[_0x428940('0xa')]]:this[_0x428940('0x48')][_0x49060f['uniqueid']][_0x428940('0x14')]===_0x428940('0x43')&&this[_0x428940('0x87')][_0x49060f[_0x428940('0xa')]]&&(this[_0x428940('0x48')][_0x49060f['uniqueid']][_0x428940('0xa')]=[this[_0x428940('0x48')][_0x49060f[_0x428940('0xa')]]['linkedid'],this['channels'][_0x49060f[_0x428940('0xa')]][_0x428940('0x6e')]=this[_0x428940('0x48')][_0x49060f['uniqueid']]['uniqueid']][0x0],delete this[_0x428940('0x87')][_0x49060f['uniqueid']]),ami['emit'](_0x428940('0x1c'),this[_0x428940('0x48')][_0x49060f[_0x428940('0xa')]]),delete this[_0x428940('0x48')][_0x49060f[_0x428940('0xa')]];}}}catch(_0x29f495){logger['error']('[syncHangup][VoiceCallReport]',util[_0x428940('0x29')](_0x29f495,{'showHidden':![],'depth':null}));}},VoiceCallReport['prototype'][_0x5e5ddb('0x12')]=function(_0x2a557d){const _0x436b45=_0x5e5ddb;try{if(this['isNotNull'](_0x2a557d)){if(this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0xf')]]){this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0xf')]][_0x436b45('0x82')]=_0x2a557d[_0x436b45('0x16')],this[_0x436b45('0x48')][_0x2a557d['transfereeuniqueid']][_0x436b45('0x7e')]=_0x2a557d[_0x436b45('0x58')];if(this[_0x436b45('0x48')][_0x2a557d['secondtransfereruniqueid']]){const _0x352a3e=this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0x32')]];this[_0x436b45('0x48')][_0x2a557d['secondtransfereruniqueid']]=this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0xf')]],this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0xf')]]=_0x352a3e;}}else{if(this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0x17')]]){this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0x17')]][_0x436b45('0x82')]=_0x2a557d[_0x436b45('0x16')],this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0x17')]][_0x436b45('0x7e')]=_0x2a557d[_0x436b45('0x58')];if(this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0x79')]]){const _0x4e531e=this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0x79')]];this[_0x436b45('0x48')][_0x2a557d['origtransfereruniqueid']]=this[_0x436b45('0x48')][_0x2a557d[_0x436b45('0x17')]],this['channels'][_0x2a557d['transfertargetuniqueid']]=_0x4e531e;}}}}}catch(_0xaaee76){logger[_0x436b45('0x3a')]('[syncAttendedTransfer][VoiceCallReport]',util['inspect'](_0xaaee76,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0x2c')]=function(_0x116ae5){const _0x39c9cb=_0x5e5ddb;try{this[_0x39c9cb('0x15')](_0x116ae5)&&(this['channels'][_0x116ae5[_0x39c9cb('0xf')]]&&(this['channels'][_0x116ae5[_0x39c9cb('0xf')]][_0x39c9cb('0x82')]=_0x116ae5[_0x39c9cb('0x86')],this[_0x39c9cb('0x48')][_0x116ae5[_0x39c9cb('0xf')]][_0x39c9cb('0x7e')]=_0x116ae5[_0x39c9cb('0x5c')],this[_0x39c9cb('0x5e')]({'event':_0x39c9cb('0x11'),'uniqueid':_0x116ae5['transfereeuniqueid'],'context':_0x116ae5[_0x39c9cb('0x2')],'channel':_0x116ae5['transfererchannel']})));}catch(_0x32313a){logger[_0x39c9cb('0x3a')](_0x39c9cb('0x23'),util[_0x39c9cb('0x29')](_0x32313a,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0x5b')]=function(_0x478858){const _0x44ec3e=_0x5e5ddb;try{this['isNotNull'](_0x478858)&&(this[_0x44ec3e('0x48')][_0x478858['uniqueid']]&&(!_[_0x44ec3e('0x80')](this[_0x44ec3e('0x48')][_0x478858[_0x44ec3e('0xa')]]['answertime'])&&(this['channels'][_0x478858[_0x44ec3e('0xa')]]['mohstarttime']=moment()[_0x44ec3e('0x63')](_0x44ec3e('0x7f')))));}catch(_0x225aab){logger['error'](_0x44ec3e('0x3e'),util['inspect'](_0x225aab,{'showHidden':![],'depth':null}));}},VoiceCallReport[_0x5e5ddb('0x4f')][_0x5e5ddb('0x8')]=function(_0x3dbd89){const _0x20c0b6=_0x5e5ddb;try{this[_0x20c0b6('0x15')](_0x3dbd89)&&(this[_0x20c0b6('0x48')][_0x3dbd89['uniqueid']]&&(!_[_0x20c0b6('0x80')](this[_0x20c0b6('0x48')][_0x3dbd89[_0x20c0b6('0xa')]][_0x20c0b6('0x55')])&&(this[_0x20c0b6('0x48')][_0x3dbd89[_0x20c0b6('0xa')]][_0x20c0b6('0x53')]+=moment()[_0x20c0b6('0x2e')](0x0)[_0x20c0b6('0x8a')](this['channels'][_0x3dbd89[_0x20c0b6('0xa')]][_0x20c0b6('0x55')],_0x20c0b6('0x75')),delete this['channels'][_0x3dbd89['uniqueid']][_0x20c0b6('0x55')])));}catch(_0x5a01be){logger[_0x20c0b6('0x3a')](_0x20c0b6('0x38'),util[_0x20c0b6('0x29')](_0x5a01be,{'showHidden':![],'depth':null}));}},module[_0x5e5ddb('0x68')]=VoiceCallReport; \ No newline at end of file diff --git a/server/services/ami/report/voiceDialReport.js b/server/services/ami/report/voiceDialReport.js index 4b79c49..d0d10d5 100644 --- a/server/services/ami/report/voiceDialReport.js +++ b/server/services/ami/report/voiceDialReport.js @@ -1 +1 @@ -const a1097_0x439f=['diff','custom:dialbegin','sipcallid','dialstatus','prototype','keys','rtpaudioqosrttbridged','syncVarSet','../ami','hangup','channels','answertime','moment','outboundrouteid','substring','addVariable','total','uniqueid','endtime','syncDialEnd','[syncDialEnd][VoiceDialReport]','[syncVarSet][VoiceDialReport]','connectedlinename','ami','voice:outbound','custom:dialconnect','voice_outbound:save','memberpenalty','membername','event','../../../rediscache','voice_outbound_channel:save','memberrealtime','starttime','voice_outbound_channel:remove','duration','bridgepvtcallid','seconds','linkedid','syncHangup','rtpaudioqoslossbridged','billableseconds','channel','memberinterface','isNil','[syncHangup][VoiceDialReport]','[DEBUG]\x20Emit\x20voice_outbound_channel:remove\x20event','isNotNull','custom:voiceDialReport','lastIndexOf','lastevent','bind','rtpaudioqosjitter','privilege','rtpaudioqos','connectedlinenum','complete','syncDialBegin','emit','variable','rtpaudioqosjitterbridged','variables','rtpaudioqosbridged','[syncDialBegin][VoiceDialReport]','outbound','inspect','value','varset','called','YYYY-MM-DD\x20HH:mm:ss','isUndefined','dialend','holdtime','dialbegin','memberdynamic','ANSWER','rtpaudioqosloss','sumHoldTime','exports','destuniqueid','omit','info','util','includes','format','../../../config/logger','error'];(function(_0x213e4c,_0x439f72){const _0x8647ac=function(_0x5c853f){while(--_0x5c853f){_0x213e4c['push'](_0x213e4c['shift']());}};_0x8647ac(++_0x439f72);}(a1097_0x439f,0x186));const a1097_0x8647=function(_0x213e4c,_0x439f72){_0x213e4c=_0x213e4c-0x0;let _0x8647ac=a1097_0x439f[_0x213e4c];return _0x8647ac;};const _0x5e916e=a1097_0x8647;'use strict';const _=require('lodash'),moment=require(_0x5e916e('0x39')),util=require(_0x5e916e('0x28')),logger=require(_0x5e916e('0x2b'))(_0x5e916e('0x44')),ami=require(_0x5e916e('0x35')),{getSocket}=require(_0x5e916e('0x4b')),io=getSocket();function VoiceDialReport(_0x5c853f){const _0x47c2aa=_0x5e916e;this[_0x47c2aa('0x37')]=_0x5c853f['outboundChannels'],this[_0x47c2aa('0x16')]=_0x5c853f['outbound'],this[_0x47c2aa('0x13')]={},ami['on'](_0x47c2aa('0x1f'),this['syncDialBegin']['bind'](this)),ami['on'](_0x47c2aa('0x1d'),this[_0x47c2aa('0x40')][_0x47c2aa('0x9')](this)),ami['on'](_0x47c2aa('0x19'),this[_0x47c2aa('0x34')]['bind'](this)),ami['on'](_0x47c2aa('0x36'),this[_0x47c2aa('0x54')][_0x47c2aa('0x9')](this));}VoiceDialReport[_0x5e916e('0x31')][_0x5e916e('0x5')]=function(_0x562865){const _0x7c9913=_0x5e916e;return _0x562865!==null&&!_[_0x7c9913('0x1c')](_0x562865);},VoiceDialReport[_0x5e916e('0x31')]['emit']=function(_0x236bda,_0xff68b4,_0x55388d){const _0x2c6ad7=_0x5e916e;io['to'](_0x236bda)[_0x2c6ad7('0x10')](_0xff68b4,_0x55388d);},VoiceDialReport['prototype'][_0x5e916e('0xf')]=function(_0x16ba38){const _0x27da0e=_0x5e916e;try{this[_0x27da0e('0x5')](_0x16ba38)&&(this[_0x27da0e('0x37')][_0x16ba38[_0x27da0e('0x3e')]]&&(_['merge'](this[_0x27da0e('0x37')][_0x16ba38[_0x27da0e('0x3e')]],{'starttime':moment()[_0x27da0e('0x2a')](_0x27da0e('0x1b')),'lastevent':_0x27da0e('0x1a'),'interface':_0x16ba38[_0x27da0e('0x0')][_0x27da0e('0x3b')](0x0,_0x16ba38[_0x27da0e('0x0')]['lastIndexOf']('-')),'membername':_0x16ba38[_0x27da0e('0x0')][_0x27da0e('0x3b')](_0x16ba38[_0x27da0e('0x0')]['lastIndexOf']('/')+0x1,_0x16ba38['channel'][_0x27da0e('0x7')]('-'))},_[_0x27da0e('0x26')](_0x16ba38,[_0x27da0e('0x4a'),_0x27da0e('0xb')])),this['emit'](_0x27da0e('0x45'),'voice_outbound_channel:save',this[_0x27da0e('0x37')][_0x16ba38['uniqueid']]),ami[_0x27da0e('0x10')](_0x27da0e('0x2e'),this[_0x27da0e('0x37')][_0x16ba38[_0x27da0e('0x3e')]])));}catch(_0x195fe6){logger[_0x27da0e('0x2c')](_0x27da0e('0x15'),util[_0x27da0e('0x17')](_0x195fe6,{'showHidden':![],'depth':null}));}},VoiceDialReport[_0x5e916e('0x31')][_0x5e916e('0x40')]=function(_0x291e87){const _0x143e2c=_0x5e916e;try{this[_0x143e2c('0x5')](_0x291e87)&&(this['channels'][_0x291e87[_0x143e2c('0x3e')]]&&(this[_0x143e2c('0x37')][_0x291e87[_0x143e2c('0x3e')]][_0x143e2c('0x30')]=_0x291e87[_0x143e2c('0x30')],_0x291e87[_0x143e2c('0x30')]===_0x143e2c('0x21')&&(this['channels'][_0x291e87['uniqueid']][_0x143e2c('0xd')]=_0x291e87[_0x143e2c('0xd')],this['channels'][_0x291e87['uniqueid']][_0x143e2c('0x43')]=_0x291e87[_0x143e2c('0x43')],this[_0x143e2c('0x37')][_0x291e87[_0x143e2c('0x3e')]][_0x143e2c('0x38')]=moment()[_0x143e2c('0x2a')](_0x143e2c('0x1b')),this[_0x143e2c('0x37')][_0x291e87[_0x143e2c('0x3e')]][_0x143e2c('0x8')]='connect',ami[_0x143e2c('0x10')](_0x143e2c('0x46'),this[_0x143e2c('0x37')][_0x291e87[_0x143e2c('0x3e')]])),this['emit'](_0x143e2c('0x45'),_0x143e2c('0x4c'),this[_0x143e2c('0x37')][_0x291e87[_0x143e2c('0x3e')]])));}catch(_0x57aa9a){logger['error'](_0x143e2c('0x41'),util[_0x143e2c('0x17')](_0x57aa9a,{'showHidden':![],'depth':null}));}},VoiceDialReport[_0x5e916e('0x31')][_0x5e916e('0x34')]=function(_0x5cb391){const _0x6679=_0x5e916e;try{this[_0x6679('0x5')](_0x5cb391)&&(this[_0x6679('0x3c')](_0x5cb391[_0x6679('0x3e')],_[_0x6679('0x32')](_0x5cb391['variable'])[0x0],_0x5cb391[_0x6679('0x18')]),this[_0x6679('0x5')](_0x5cb391[_0x6679('0x11')])&&this[_0x6679('0x5')](_0x5cb391['variable'][_0x6679('0x3a')])&&(_[_0x6679('0x1c')](this[_0x6679('0x37')][_0x5cb391[_0x6679('0x3e')]])&&(this[_0x6679('0x37')][_0x5cb391[_0x6679('0x3e')]]={'routeId':_0x5cb391[_0x6679('0x18')],'variables':this[_0x6679('0x13')][_0x5cb391['uniqueid']]},this[_0x6679('0x10')](_0x6679('0x45'),'voice_outbound_channel:save',this[_0x6679('0x37')][_0x5cb391[_0x6679('0x3e')]]))));}catch(_0x148b80){logger['error'](_0x6679('0x42'),util['inspect'](_0x148b80,{'showHidden':![],'depth':null}));}},VoiceDialReport[_0x5e916e('0x31')][_0x5e916e('0x3c')]=function(_0x5561c7,_0x56b12b,_0x3e704c){const _0x3909f3=_0x5e916e,_0x1398dd=[_0x3909f3('0xc'),_0x3909f3('0x14'),_0x3909f3('0xa'),_0x3909f3('0x12'),_0x3909f3('0x22'),_0x3909f3('0x55'),'rtpaudioqosrtt',_0x3909f3('0x33'),_0x3909f3('0x2f'),'sipuri','bridgepeer',_0x3909f3('0x51'),'membercalls',_0x3909f3('0x20'),_0x3909f3('0x1'),'memberlastcall',_0x3909f3('0x49'),_0x3909f3('0x48'),_0x3909f3('0x4d')];!_[_0x3909f3('0x2')](_0x56b12b)&&!_[_0x3909f3('0x29')](_0x1398dd,_0x56b12b)&&(_['isUndefined'](this[_0x3909f3('0x13')][_0x5561c7])&&(this[_0x3909f3('0x13')][_0x5561c7]={}),this[_0x3909f3('0x13')][_0x5561c7][_0x56b12b]=_0x3e704c);},VoiceDialReport[_0x5e916e('0x31')][_0x5e916e('0x54')]=function(_0x433526){const _0x435360=_0x5e916e;try{if(this[_0x435360('0x5')](_0x433526)){if(this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]])this[_0x435360('0x37')][_0x433526['uniqueid']][_0x435360('0x3f')]=moment()['format'](_0x435360('0x1b')),this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]]['duration']=moment(this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]]['endtime'])[_0x435360('0x2d')](this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]][_0x435360('0x4e')],_0x435360('0x52')),this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]][_0x435360('0x8')]=_0x435360('0xe'),this['outbound'][_0x435360('0x3d')]+=0x1,this['channels'][_0x433526['uniqueid']][_0x435360('0x38')]&&(this[_0x435360('0x16')]['answered']+=0x1,this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]][_0x435360('0x1e')]=moment(this['channels'][_0x433526['uniqueid']][_0x435360('0x38')])[_0x435360('0x2d')](this['channels'][_0x433526[_0x435360('0x3e')]]['starttime'],_0x435360('0x52')),this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]][_0x435360('0x56')]=moment(this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]][_0x435360('0x3f')])['diff'](this['channels'][_0x433526[_0x435360('0x3e')]][_0x435360('0x38')],_0x435360('0x52')),this['outbound'][_0x435360('0x23')]+=this[_0x435360('0x37')][_0x433526['uniqueid']][_0x435360('0x1e')]||0x0,this[_0x435360('0x16')]['sumBillable']+=this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]]['billableseconds']),this['outbound']['sumDuration']+=this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]][_0x435360('0x50')],ami[_0x435360('0x10')](_0x435360('0x6'),this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]]),ami['emit']('custom:dialend',this['channels'][_0x433526[_0x435360('0x3e')]]),this[_0x435360('0x10')](_0x435360('0x45'),_0x435360('0x47'),this[_0x435360('0x16')]),logger[_0x435360('0x27')](_0x435360('0x4'),JSON['stringify'](this[_0x435360('0x37')][_0x433526[_0x435360('0x3e')]])),this['emit'](_0x435360('0x45'),_0x435360('0x4f'),this[_0x435360('0x37')][_0x433526['uniqueid']]),delete this['channels'][_0x433526['uniqueid']];else this[_0x435360('0x37')][_0x433526[_0x435360('0x53')]]&&(this['channels'][_0x433526[_0x435360('0x53')]][_0x435360('0x3e')]=this['channels'][_0x433526['linkedid']][_0x435360('0x25')]);this[_0x435360('0x13')][_0x433526['uniqueid']]&&delete this[_0x435360('0x13')][_0x433526['uniqueid']];}}catch(_0x5e35fd){logger[_0x435360('0x2c')](_0x435360('0x3'),util[_0x435360('0x17')](_0x5e35fd,{'showHidden':![],'depth':null}));}},module[_0x5e916e('0x24')]=VoiceDialReport; \ No newline at end of file +const a1097_0x5b84=['memberdynamic','sumDuration','exports','voice_outbound:save','[syncDialBegin][VoiceDialReport]','membercalls','[syncVarSet][VoiceDialReport]','../../../config/logger','sumHoldTime','endtime','isNotNull','membername','custom:dialbegin','duration','rtpaudioqosjitter','starttime','holdtime','syncVarSet','varset','syncHangup','bridgepeer','rtpaudioqosloss','seconds','ami','complete','called','addVariable','voice:outbound','includes','rtpaudioqos','outbound','info','lastIndexOf','diff','format','sipuri','voice_outbound_channel:save','[syncDialEnd][VoiceDialReport]','YYYY-MM-DD\x20HH:mm:ss','util','connectedlinename','channels','isNil','[DEBUG]\x20Emit\x20voice_outbound_channel:remove\x20event','privilege','substring','keys','destuniqueid','bind','variables','syncDialEnd','stringify','answered','linkedid','isUndefined','rtpaudioqoslossbridged','rtpaudioqosrttbridged','hangup','emit','connectedlinenum','../ami','variable','memberlastcall','rtpaudioqosrtt','lastevent','dialbegin','memberrealtime','bridgepvtcallid','prototype','uniqueid','syncDialBegin','rtpaudioqosjitterbridged','error','inspect','answertime','total','ANSWER','merge','billableseconds','omit','channel','dialstatus','custom:dialconnect','connect','value','sipcallid'];(function(_0x20c54b,_0x5b848e){const _0x3c7a44=function(_0x25be63){while(--_0x25be63){_0x20c54b['push'](_0x20c54b['shift']());}};_0x3c7a44(++_0x5b848e);}(a1097_0x5b84,0x1dc));const a1097_0x3c7a=function(_0x20c54b,_0x5b848e){_0x20c54b=_0x20c54b-0x0;let _0x3c7a44=a1097_0x5b84[_0x20c54b];return _0x3c7a44;};const _0x3b1f0d=a1097_0x3c7a;'use strict';const _=require('lodash'),moment=require('moment'),util=require(_0x3b1f0d('0x4f')),logger=require(_0x3b1f0d('0x2f'))(_0x3b1f0d('0x3f')),ami=require(_0x3b1f0d('0xe')),{getSocket}=require('../../../rediscache'),io=getSocket();function VoiceDialReport(_0x25be63){const _0x161587=_0x3b1f0d;this['channels']=_0x25be63['outboundChannels'],this[_0x161587('0x46')]=_0x25be63['outbound'],this[_0x161587('0x3')]={},ami['on'](_0x161587('0x13'),this[_0x161587('0x18')]['bind'](this)),ami['on']('dialend',this[_0x161587('0x4')][_0x161587('0x2')](this)),ami['on'](_0x161587('0x3a'),this[_0x161587('0x39')][_0x161587('0x2')](this)),ami['on'](_0x161587('0xb'),this[_0x161587('0x3b')][_0x161587('0x2')](this));}VoiceDialReport[_0x3b1f0d('0x16')][_0x3b1f0d('0x32')]=function(_0x7234b0){const _0x1235c1=_0x3b1f0d;return _0x7234b0!==null&&!_[_0x1235c1('0x8')](_0x7234b0);},VoiceDialReport[_0x3b1f0d('0x16')][_0x3b1f0d('0xc')]=function(_0xc508ec,_0x28dc82,_0x3415b5){io['to'](_0xc508ec)['emit'](_0x28dc82,_0x3415b5);},VoiceDialReport['prototype']['syncDialBegin']=function(_0x430d47){const _0x4cae55=_0x3b1f0d;try{this[_0x4cae55('0x32')](_0x430d47)&&(this[_0x4cae55('0x51')][_0x430d47[_0x4cae55('0x17')]]&&(_[_0x4cae55('0x1f')](this[_0x4cae55('0x51')][_0x430d47[_0x4cae55('0x17')]],{'starttime':moment()[_0x4cae55('0x4a')](_0x4cae55('0x4e')),'lastevent':_0x4cae55('0x41'),'interface':_0x430d47[_0x4cae55('0x22')][_0x4cae55('0x55')](0x0,_0x430d47[_0x4cae55('0x22')]['lastIndexOf']('-')),'membername':_0x430d47[_0x4cae55('0x22')][_0x4cae55('0x55')](_0x430d47[_0x4cae55('0x22')][_0x4cae55('0x48')]('/')+0x1,_0x430d47[_0x4cae55('0x22')][_0x4cae55('0x48')]('-'))},_[_0x4cae55('0x21')](_0x430d47,['event',_0x4cae55('0x54')])),this[_0x4cae55('0xc')]('voice:outbound',_0x4cae55('0x4c'),this[_0x4cae55('0x51')][_0x430d47[_0x4cae55('0x17')]]),ami[_0x4cae55('0xc')](_0x4cae55('0x34'),this[_0x4cae55('0x51')][_0x430d47[_0x4cae55('0x17')]])));}catch(_0x26e7dd){logger[_0x4cae55('0x1a')](_0x4cae55('0x2c'),util[_0x4cae55('0x1b')](_0x26e7dd,{'showHidden':![],'depth':null}));}},VoiceDialReport[_0x3b1f0d('0x16')][_0x3b1f0d('0x4')]=function(_0x24bdcf){const _0x2d23b6=_0x3b1f0d;try{this[_0x2d23b6('0x32')](_0x24bdcf)&&(this[_0x2d23b6('0x51')][_0x24bdcf[_0x2d23b6('0x17')]]&&(this['channels'][_0x24bdcf[_0x2d23b6('0x17')]][_0x2d23b6('0x23')]=_0x24bdcf[_0x2d23b6('0x23')],_0x24bdcf[_0x2d23b6('0x23')]===_0x2d23b6('0x1e')&&(this[_0x2d23b6('0x51')][_0x24bdcf[_0x2d23b6('0x17')]][_0x2d23b6('0xd')]=_0x24bdcf[_0x2d23b6('0xd')],this[_0x2d23b6('0x51')][_0x24bdcf[_0x2d23b6('0x17')]][_0x2d23b6('0x50')]=_0x24bdcf[_0x2d23b6('0x50')],this[_0x2d23b6('0x51')][_0x24bdcf[_0x2d23b6('0x17')]][_0x2d23b6('0x1c')]=moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),this[_0x2d23b6('0x51')][_0x24bdcf[_0x2d23b6('0x17')]]['lastevent']=_0x2d23b6('0x25'),ami['emit'](_0x2d23b6('0x24'),this[_0x2d23b6('0x51')][_0x24bdcf[_0x2d23b6('0x17')]])),this[_0x2d23b6('0xc')](_0x2d23b6('0x43'),_0x2d23b6('0x4c'),this[_0x2d23b6('0x51')][_0x24bdcf[_0x2d23b6('0x17')]])));}catch(_0x537243){logger['error'](_0x2d23b6('0x4d'),util[_0x2d23b6('0x1b')](_0x537243,{'showHidden':![],'depth':null}));}},VoiceDialReport[_0x3b1f0d('0x16')][_0x3b1f0d('0x39')]=function(_0x1789f3){const _0x1aabd7=_0x3b1f0d;try{this['isNotNull'](_0x1789f3)&&(this[_0x1aabd7('0x42')](_0x1789f3[_0x1aabd7('0x17')],_[_0x1aabd7('0x0')](_0x1789f3[_0x1aabd7('0xf')])[0x0],_0x1789f3[_0x1aabd7('0x26')]),this['isNotNull'](_0x1789f3[_0x1aabd7('0xf')])&&this[_0x1aabd7('0x32')](_0x1789f3[_0x1aabd7('0xf')]['outboundrouteid'])&&(_['isUndefined'](this['channels'][_0x1789f3[_0x1aabd7('0x17')]])&&(this[_0x1aabd7('0x51')][_0x1789f3['uniqueid']]={'routeId':_0x1789f3['value'],'variables':this['variables'][_0x1789f3['uniqueid']]},this[_0x1aabd7('0xc')]('voice:outbound',_0x1aabd7('0x4c'),this[_0x1aabd7('0x51')][_0x1789f3[_0x1aabd7('0x17')]]))));}catch(_0x448c70){logger['error'](_0x1aabd7('0x2e'),util[_0x1aabd7('0x1b')](_0x448c70,{'showHidden':![],'depth':null}));}},VoiceDialReport[_0x3b1f0d('0x16')][_0x3b1f0d('0x42')]=function(_0x477f18,_0x51064a,_0x18d086){const _0x305de8=_0x3b1f0d,_0x3f8c45=[_0x305de8('0x45'),'rtpaudioqosbridged',_0x305de8('0x36'),_0x305de8('0x19'),_0x305de8('0x3d'),_0x305de8('0x9'),_0x305de8('0x11'),_0x305de8('0xa'),_0x305de8('0x27'),_0x305de8('0x4b'),_0x305de8('0x3c'),_0x305de8('0x15'),_0x305de8('0x2d'),_0x305de8('0x28'),'memberinterface',_0x305de8('0x10'),_0x305de8('0x33'),'memberpenalty',_0x305de8('0x14')];!_[_0x305de8('0x52')](_0x51064a)&&!_[_0x305de8('0x44')](_0x3f8c45,_0x51064a)&&(_[_0x305de8('0x8')](this[_0x305de8('0x3')][_0x477f18])&&(this['variables'][_0x477f18]={}),this['variables'][_0x477f18][_0x51064a]=_0x18d086);},VoiceDialReport['prototype'][_0x3b1f0d('0x3b')]=function(_0x30b28d){const _0x22f60d=_0x3b1f0d;try{if(this[_0x22f60d('0x32')](_0x30b28d)){if(this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]])this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]]['endtime']=moment()[_0x22f60d('0x4a')]('YYYY-MM-DD\x20HH:mm:ss'),this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]][_0x22f60d('0x35')]=moment(this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]][_0x22f60d('0x31')])['diff'](this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]][_0x22f60d('0x37')],_0x22f60d('0x3e')),this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]][_0x22f60d('0x12')]=_0x22f60d('0x40'),this[_0x22f60d('0x46')][_0x22f60d('0x1d')]+=0x1,this[_0x22f60d('0x51')][_0x30b28d['uniqueid']][_0x22f60d('0x1c')]&&(this[_0x22f60d('0x46')][_0x22f60d('0x6')]+=0x1,this['channels'][_0x30b28d[_0x22f60d('0x17')]][_0x22f60d('0x38')]=moment(this['channels'][_0x30b28d['uniqueid']]['answertime'])[_0x22f60d('0x49')](this[_0x22f60d('0x51')][_0x30b28d['uniqueid']][_0x22f60d('0x37')],_0x22f60d('0x3e')),this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]][_0x22f60d('0x20')]=moment(this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]]['endtime'])[_0x22f60d('0x49')](this['channels'][_0x30b28d[_0x22f60d('0x17')]]['answertime'],_0x22f60d('0x3e')),this[_0x22f60d('0x46')][_0x22f60d('0x30')]+=this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]][_0x22f60d('0x38')]||0x0,this[_0x22f60d('0x46')]['sumBillable']+=this[_0x22f60d('0x51')][_0x30b28d['uniqueid']][_0x22f60d('0x20')]),this[_0x22f60d('0x46')][_0x22f60d('0x29')]+=this['channels'][_0x30b28d[_0x22f60d('0x17')]][_0x22f60d('0x35')],ami[_0x22f60d('0xc')]('custom:voiceDialReport',this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]]),ami[_0x22f60d('0xc')]('custom:dialend',this[_0x22f60d('0x51')][_0x30b28d['uniqueid']]),this['emit'](_0x22f60d('0x43'),_0x22f60d('0x2b'),this[_0x22f60d('0x46')]),logger[_0x22f60d('0x47')](_0x22f60d('0x53'),JSON[_0x22f60d('0x5')](this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]])),this['emit']('voice:outbound','voice_outbound_channel:remove',this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]]),delete this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x17')]];else this[_0x22f60d('0x51')][_0x30b28d['linkedid']]&&(this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x7')]][_0x22f60d('0x17')]=this[_0x22f60d('0x51')][_0x30b28d[_0x22f60d('0x7')]][_0x22f60d('0x1')]);this[_0x22f60d('0x3')][_0x30b28d[_0x22f60d('0x17')]]&&delete this['variables'][_0x30b28d[_0x22f60d('0x17')]];}}catch(_0xbbb65b){logger[_0x22f60d('0x1a')]('[syncHangup][VoiceDialReport]',util[_0x22f60d('0x1b')](_0xbbb65b,{'showHidden':![],'depth':null}));}},module[_0x3b1f0d('0x2a')]=VoiceDialReport; \ No newline at end of file diff --git a/server/services/ami/report/voiceQueueReport.js b/server/services/ami/report/voiceQueueReport.js index 187c978..cc09d57 100644 --- a/server/services/ami/report/voiceQueueReport.js +++ b/server/services/ami/report/voiceQueueReport.js @@ -1 +1 @@ -const a1098_0x5112=['Action','custom:voiceQueueReport','syncAttendedTransfer','flagQueueSummary','[FullyBooted]\x20clear\x20realtime','voice_queue_channel:remove','emitVoiceQueueSummary','isEmpty','reason','prototype','origtransfereruniqueid','isNotNull','queuecallerabandon','sipcallid','available','bridgepvtcallid','count','enqueue','syncQueueSummary','../model/queueReport','queuecallerexitreason','bridgepeer','error','countBy','exports','Trunk','loggedin','queueReports','[syncMusicOnHoldStop][VoiceQueueReport]','callers','syncQueueSummaryComplete','uniqueid','rtpaudioqoslossbridged','voiceQueues','queueposition','isNil','sequence','[syncMusicOnHoldStart][VoiceQueueReport]','addVariable','unlockRR','clearQueueReport','queuestatus','rtpaudioqos','queuecallercompleteAt','[syncBlindTransfer][VoiceQueueReport]','[syncAgentComplete][VoiceQueueReport]','agentcomplete','destexten','catch','emitVoiceQueueChannelRemove','queuesummarycomplete','sipuri','custom:timeout','syncQueueCallerAbandon','custom:queuecallerabandon','[syncVarSet][VoiceQueueReport]','md5','COMPLETEDBYAGENT','clearZombieChannels','connectedlinenum','undefined','pick','loggedIn','merge','BlindTransfer','syncFullyBooted','syncVarSet','rtpaudioqosrtt','format','callerid','transfertype','queue','secondtransfererexten','BLINDTRANSFER','transferuniqueid','pTalking','COMPLETED','musiconholdstart','ami','active','queueStatusComplete','syncHangup','abandoned','agentconnect','lodash','agents','waiting','transfertargetuniqueid','BLIND','[syncQueueSummary][VoiceQueueReport]','[voiceQueueReport][checkVariables]','memberpenalty','context','loopQueueShow','isUndefined','queuecallercomplete','value','emitVoiceQueueChannelSave','campaigns','attendedtransfer','memberdynamic','EXITWITHKEY','queuecallerleaveAt','rtpaudioqosloss','Interval','unmanaged','../../../config/logger','lastAssignedTo','memberlastcall','queuecallerabandonAt','strategy','../ami','voice_queue_channel:save','[syncQueueCallerAbandon][VoiceQueueReport]','secondtransfereruniqueid','inspect','transfer','length','queuecallerjoin','assigned','queuecallerexitAt','queuesummary','originated','syncMusicOnHoldStop','loopQueueSummary','channels','connectedlinename','milliseconds','linkedid','add','finally','variables','[voiceQueueReport][checkChannel]','[queues]','[DEBUG]\x20Emit\x20voice_queue_channel:remove\x20event','talking','ATTENDED','queuecallerexit','position','toUpperCase','syncAgentConnect','FORWARD','mohstarttime','lastevent','emit','[voiceQueueReport][checkQueueReport]','startsWith','queuecallerjoinAt','sumHoldTime','name','bind','membername','holdtime','diff','last','syncAgentComplete','includes','keys','YYYY-MM-DD\x20HH:mm:ss','extension','transferexten','transfereeuniqueid','answered','ABANDONED','inbound','syncQueueCallerJoin','variable','transfererchannel','type','origtransfererexten','queuecallerleave','switch','mohtime','originalposition','seconds','then','push','sumBillable','[syncAgentConnect][VoiceQueueReport]','voice_queue:save','channel','membercalls','info','../../../rediscache','voice:queue:%s','toNumber','FORWARDTRANSFER','total','syncQueueCallerLeave','custom:queuecallerunmanaged','sumDuration','tail','musiconholdstop'];(function(_0x535747,_0x5112d7){const _0x119482=function(_0x1d4299){while(--_0x1d4299){_0x535747['push'](_0x535747['shift']());}};_0x119482(++_0x5112d7);}(a1098_0x5112,0x101));const a1098_0x1194=function(_0x535747,_0x5112d7){_0x535747=_0x535747-0x0;let _0x119482=a1098_0x5112[_0x535747];return _0x119482;};const _0x45991c=a1098_0x1194;'use strict';const _=require(_0x45991c('0x14')),moment=require('moment'),util=require('util'),md5=require(_0x45991c('0xb9')),logger=require(_0x45991c('0x2a'))(_0x45991c('0xe')),ami=require(_0x45991c('0x2f')),QueueReport=require(_0x45991c('0x94')),{getSocket}=require(_0x45991c('0x77')),io=getSocket(),Sequence=function(){};Sequence[_0x45991c('0x8a')]['enqueue']=function(_0x1d4299){const _0x5799ef=_0x45991c;this[_0x5799ef('0x7f')]=this[_0x5799ef('0x7f')]?this['tail'][_0x5799ef('0x42')](_0x1d4299):_0x1d4299();};function VoiceQueueReport(_0x1dbd92){const _0x10216c=_0x45991c;this[_0x10216c('0xa5')]=new Sequence(),this[_0x10216c('0x9c')]={},this['agents']=_0x1dbd92[_0x10216c('0x15')],this[_0x10216c('0x3d')]=_0x1dbd92['queueChannels'],this[_0x10216c('0xa2')]=_0x1dbd92[_0x10216c('0xa2')],this[_0x10216c('0x84')]=!![],this[_0x10216c('0x22')]=_0x1dbd92[_0x10216c('0x22')],this[_0x10216c('0x43')]={},ami['on'](_0x10216c('0x39'),this[_0x10216c('0x93')]['bind'](this)),ami['on'](_0x10216c('0xb3'),this[_0x10216c('0x9f')]['bind'](this)),ami['on'](_0x10216c('0x36'),this[_0x10216c('0x65')]['bind'](this)),ami['on'](_0x10216c('0x8d'),this[_0x10216c('0xb6')][_0x10216c('0x56')](this)),ami['on'](_0x10216c('0x6a'),this[_0x10216c('0x7c')][_0x10216c('0x56')](this)),ami['on'](_0x10216c('0xaf'),this['syncAgentComplete'][_0x10216c('0x56')](this)),ami['on'](_0x10216c('0x13'),this[_0x10216c('0x4c')]['bind'](this)),ami['on']('varset',this[_0x10216c('0x2')][_0x10216c('0x56')](this)),ami['on']('hangup',this[_0x10216c('0x11')][_0x10216c('0x56')](this)),ami['on']('fullybooted',this['syncFullyBooted'][_0x10216c('0x56')](this)),ami['on'](_0x10216c('0xd'),this['syncMusicOnHoldStart'][_0x10216c('0x56')](this)),ami['on'](_0x10216c('0x80'),this[_0x10216c('0x3b')]['bind'](this)),ami['on'](_0x10216c('0x23'),this[_0x10216c('0x83')][_0x10216c('0x56')](this)),ami['on']('blindtransfer',this['syncBlindTransfer']['bind'](this)),this[_0x10216c('0x3c')](),this['loopQueueShow']();}function clearChannels(_0x4fdcef){const _0x50d3bc=_0x45991c;if(!_['isEmpty'](_0x4fdcef))for(const _0x59b9d1 in _0x4fdcef){typeof _0x4fdcef[_0x59b9d1]!==_0x50d3bc('0xbd')&&delete _0x4fdcef[_0x59b9d1];}}function clearCampaigns(_0xab6502){const _0x9aa485=_0x45991c;if(!_[_0x9aa485('0x88')](_0xab6502))for(const _0x555de6 in _0xab6502){typeof _0xab6502[_0x555de6]!=='undefined'&&(_0xab6502[_0x555de6]['originated']=0x0);}}function clearVoiceQueues(_0x18c97b){const _0x552008=_0x45991c;if(!_['isEmpty'](_0x18c97b))for(const _0xfda741 in _0x18c97b){typeof _0x18c97b[_0xfda741]!==_0x552008('0xbd')&&(_0x18c97b[_0xfda741][_0x552008('0x3a')]=0x0,_0x18c97b[_0xfda741][_0x552008('0x47')]=0x0,_0x18c97b[_0xfda741]['pTalking']=0x0,_0x18c97b[_0xfda741][_0x552008('0x16')]=0x0,_0x18c97b[_0xfda741][_0x552008('0x10')]=!![]);}}function clearAgentBooked(_0x2cf460){const _0x344e94=_0x45991c;if(!_[_0x344e94('0x88')](_0x2cf460))for(const _0x1fe074 in _0x2cf460){typeof _0x2cf460[_0x1fe074]!==_0x344e94('0xbd')&&(_0x2cf460[_0x1fe074][_0x344e94('0xa8')]=!![]);}}VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0xbb')]=function(){const _0x49a874=_0x45991c,_0x3a4d2d=this;for(const _0x285b2e in this[_0x49a874('0x3d')]){typeof this[_0x49a874('0x3d')][_0x285b2e]!==_0x49a874('0xbd')&&!this['channels'][_0x285b2e][_0x49a874('0x6b')]&&this[_0x49a874('0xa5')][_0x49a874('0x92')](function(){const _0x23138d=_0x49a874;if(!_['isNil'](_0x3a4d2d[_0x23138d('0x3d')][_0x285b2e]))return ami[_0x23138d('0x81')]({'action':'status','channel':_0x3a4d2d[_0x23138d('0x3d')][_0x285b2e][_0x23138d('0x74')]})[_0x23138d('0xb1')](function(_0x825e32){_0x825e32['message']==='No\x20such\x20channel'&&setTimeout(function(){const _0x5ee84b=a1098_0x1194;_0x3a4d2d['channels'][_0x285b2e]&&(delete _0x3a4d2d[_0x5ee84b('0x3d')][_0x285b2e],logger['error'](_0x5ee84b('0x44'),_0x285b2e)),_0x3a4d2d[_0x5ee84b('0x9c')][_0x285b2e]&&(delete _0x3a4d2d[_0x5ee84b('0x9c')][_0x285b2e],logger[_0x5ee84b('0x97')](_0x5ee84b('0x51'),_0x285b2e)),_0x3a4d2d[_0x5ee84b('0x43')][_0x285b2e]&&(delete _0x3a4d2d[_0x5ee84b('0x43')][_0x285b2e],logger[_0x5ee84b('0x97')](_0x5ee84b('0x1a'),_0x285b2e));},0x1f40);});});}},VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0x1')]=function(){const _0x313327=_0x45991c;logger[_0x313327('0x97')](_0x313327('0x85')),clearChannels(this[_0x313327('0x3d')]),this[_0x313327('0xa9')](this['queueReports']),clearAgentBooked(this[_0x313327('0x15')]),clearVoiceQueues(this[_0x313327('0xa2')]),clearCampaigns(this[_0x313327('0x22')]);},VoiceQueueReport['prototype'][_0x45991c('0xa9')]=function(_0x4d0a8a){const _0x4f8a5f=_0x45991c,_0x376a0c=this;if(!_['isEmpty'](_0x4d0a8a))for(const _0x5d9a4b in _0x4d0a8a){typeof _0x4d0a8a[_0x5d9a4b]!==_0x4f8a5f('0xbd')&&(_0x376a0c[_0x4f8a5f('0xb2')](_0x4d0a8a[_0x5d9a4b]),delete _0x4d0a8a[_0x5d9a4b]);}};function loggerCatch(_0x9d605f){return function(_0x53a6dc){const _0xd0131d=a1098_0x1194;logger[_0xd0131d('0x97')](_0x9d605f,util[_0xd0131d('0x33')](_0x53a6dc,{'showHidden':![],'depth':null}));};}VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0x50')]=function(_0x1f1031,_0x56d0de,_0x524265){const _0x2f08b7=_0x45991c;io['to'](_0x1f1031)[_0x2f08b7('0x50')](_0x56d0de,_0x524265);},VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0x21')]=function(_0x2a39a3){const _0x520652=_0x45991c;this[_0x520652('0x50')](util[_0x520652('0x4')](_0x520652('0x78'),_0x2a39a3[_0x520652('0x55')]),_0x520652('0x30'),_0x2a39a3);},VoiceQueueReport['prototype']['emitVoiceQueueChannelRemove']=function(_0x25ed02){const _0x5088d7=_0x45991c;logger[_0x5088d7('0x76')](_0x5088d7('0x46'),JSON['stringify'](_0x25ed02)),this[_0x5088d7('0x50')](util[_0x5088d7('0x4')](_0x5088d7('0x78'),_0x25ed02[_0x5088d7('0x55')]),_0x5088d7('0x86'),_0x25ed02);},VoiceQueueReport[_0x45991c('0x8a')]['emitVoiceQueueSummary']=function(_0x893ebf){const _0x4ceee3=_0x45991c;if(_0x893ebf[_0x4ceee3('0x68')]===_0x4ceee3('0x64')){const _0x5637f2={'id':_0x893ebf['id'],'name':_0x893ebf[_0x4ceee3('0x55')],'strategy':_0x893ebf[_0x4ceee3('0x2e')],'answered':_0x893ebf[_0x4ceee3('0x62')],'available':_0x893ebf[_0x4ceee3('0x8f')],'loggedIn':_0x893ebf['loggedIn'],'pTalking':_0x893ebf[_0x4ceee3('0xb')],'sumBillable':_0x893ebf['sumBillable'],'sumDuration':_0x893ebf[_0x4ceee3('0x7e')],'sumHoldTime':_0x893ebf[_0x4ceee3('0x54')]||0x0,'talking':_0x893ebf[_0x4ceee3('0x47')],'total':_0x893ebf['total'],'type':_0x893ebf[_0x4ceee3('0x68')],'unmanaged':_0x893ebf['unmanaged'],'abandoned':_0x893ebf[_0x4ceee3('0x12')],'waiting':_0x893ebf[_0x4ceee3('0x16')]};_0x893ebf['Trunk']&&(_0x5637f2[_0x4ceee3('0x9a')]={'id':_0x893ebf['Trunk']['id'],'name':_0x893ebf[_0x4ceee3('0x9a')]['name'],'active':_0x893ebf['Trunk'][_0x4ceee3('0xf')],'callerid':_0x893ebf[_0x4ceee3('0x9a')][_0x4ceee3('0x5')]});_0x893ebf['Interval']&&(_0x5637f2['Interval']={'id':_0x893ebf[_0x4ceee3('0x28')]['id'],'name':_0x893ebf['Interval']['name']});const _0x5c6358=md5(JSON['stringify'](_0x5637f2));_0x893ebf[_0x4ceee3('0xb9')]!==_0x5c6358&&(_0x893ebf[_0x4ceee3('0xb9')]=_0x5c6358,this['emit'](util['format'](_0x4ceee3('0x78'),_0x5637f2[_0x4ceee3('0x55')]),_0x4ceee3('0x73'),_0x5637f2));}},VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0x8c')]=function(_0x3bd4ef){return _0x3bd4ef!==null&&!_['isUndefined'](_0x3bd4ef);},VoiceQueueReport['prototype'][_0x45991c('0x1d')]=function(){const _0x3f958a=this;setInterval(function(){const _0x545886=a1098_0x1194;_0x3f958a[_0x545886('0xbb')](),ami[_0x545886('0x81')]({'action':'queues'})['catch'](loggerCatch(_0x545886('0x45')));},0x2710);},VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0x3c')]=function(){const _0x576c35=this;setInterval(function(){const _0x518205=a1098_0x1194;if(_0x576c35[_0x518205('0x84')])return ami[_0x518205('0x81')]({'action':_0x518205('0x39')})[_0x518205('0x6f')](function(){const _0x4cf6a1=_0x518205;_0x576c35[_0x4cf6a1('0x84')]=![];})[_0x518205('0xb1')](loggerCatch('[queuesummary]'));},0x3e8);},VoiceQueueReport['prototype']['syncQueueSummary']=function(_0x2e8fdd){const _0x120ce6=_0x45991c;try{if(this[_0x120ce6('0x8c')](_0x2e8fdd)&&this['isNotNull'](_0x2e8fdd[_0x120ce6('0x7')])){if(this[_0x120ce6('0xa2')][_0x2e8fdd['queue']]){const _0x3dc01e=_[_0x120ce6('0x98')](this['channels'],'queue')[_0x2e8fdd[_0x120ce6('0x7')]]||0x0,_0x43cc3b=_0x3dc01e-_0x2e8fdd[_0x120ce6('0x9e')];(this[_0x120ce6('0xa2')][_0x2e8fdd[_0x120ce6('0x7')]][_0x120ce6('0x16')]!==_[_0x120ce6('0x79')](_0x2e8fdd[_0x120ce6('0x9e')])||this[_0x120ce6('0xa2')][_0x2e8fdd[_0x120ce6('0x7')]][_0x120ce6('0xbf')]!==_[_0x120ce6('0x79')](_0x2e8fdd[_0x120ce6('0x9b')])||this[_0x120ce6('0xa2')][_0x2e8fdd[_0x120ce6('0x7')]][_0x120ce6('0x8f')]!==_[_0x120ce6('0x79')](_0x2e8fdd[_0x120ce6('0x8f')])||this[_0x120ce6('0xa2')][_0x2e8fdd['queue']][_0x120ce6('0x47')]!==_0x43cc3b)&&(this[_0x120ce6('0xa2')][_0x2e8fdd[_0x120ce6('0x7')]][_0x120ce6('0x16')]=_[_0x120ce6('0x79')](_0x2e8fdd[_0x120ce6('0x9e')]),this[_0x120ce6('0xa2')][_0x2e8fdd[_0x120ce6('0x7')]]['loggedIn']=_[_0x120ce6('0x79')](_0x2e8fdd['loggedin']),this['voiceQueues'][_0x2e8fdd[_0x120ce6('0x7')]]['available']=_[_0x120ce6('0x79')](_0x2e8fdd[_0x120ce6('0x8f')]),this[_0x120ce6('0xa2')][_0x2e8fdd[_0x120ce6('0x7')]][_0x120ce6('0x47')]=_0x43cc3b>0x0?_0x43cc3b:0x0,this[_0x120ce6('0xa2')][_0x2e8fdd[_0x120ce6('0x7')]][_0x120ce6('0x47')]=this[_0x120ce6('0xa2')][_0x2e8fdd['queue']][_0x120ce6('0x47')]>_[_0x120ce6('0x79')](_0x2e8fdd['loggedin'])?_['toNumber'](_0x2e8fdd['loggedin']):this[_0x120ce6('0xa2')][_0x2e8fdd[_0x120ce6('0x7')]]['talking'],this['emitVoiceQueueSummary'](this['voiceQueues'][_0x2e8fdd[_0x120ce6('0x7')]])),ami[_0x120ce6('0x50')]('custom:queuesummary',this['voiceQueues'][_0x2e8fdd[_0x120ce6('0x7')]]);}}}catch(_0xcff28c){logger['error'](_0x120ce6('0x19'),util[_0x120ce6('0x33')](_0xcff28c,{'showHidden':![],'depth':null}));}},VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0x9f')]=function(){this['flagQueueSummary']=!![];},VoiceQueueReport[_0x45991c('0x8a')]['syncNewExten']=function(){},VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0x65')]=function(_0x12e856){const _0x4c54c9=_0x45991c;try{if(this[_0x4c54c9('0x8c')](_0x12e856)){_[_0x4c54c9('0x1e')](this[_0x4c54c9('0x9c')][_0x12e856[_0x4c54c9('0xa0')]])&&(this[_0x4c54c9('0x9c')][_0x12e856[_0x4c54c9('0xa0')]]=[],this[_0x4c54c9('0x3d')][_0x12e856[_0x4c54c9('0xa0')]]={});const _0x429421=new QueueReport();_0x429421['name']=_0x12e856['queue'],_0x429421[_0x4c54c9('0x68')]=this[_0x4c54c9('0xa2')][_0x429421[_0x4c54c9('0x55')]]&&this[_0x4c54c9('0xa2')][_0x429421[_0x4c54c9('0x55')]][_0x4c54c9('0x68')]?this['voiceQueues'][_0x429421['name']][_0x4c54c9('0x68')]||'inbound':_0x4c54c9('0x64'),_0x429421[_0x4c54c9('0x7')]=_0x12e856[_0x4c54c9('0x7')],_0x429421[_0x4c54c9('0x53')]=moment()[_0x4c54c9('0x4')]('YYYY-MM-DD\x20HH:mm:ss'),_0x429421['position']=_0x12e856[_0x4c54c9('0x4a')],_0x429421[_0x4c54c9('0x91')]=_0x12e856[_0x4c54c9('0x91')],_[_0x4c54c9('0xc0')](_0x429421,_[_0x4c54c9('0xbe')](_0x12e856,_['keys'](_0x429421))),this['queueReports'][_0x12e856[_0x4c54c9('0xa0')]][_0x4c54c9('0x70')](_0x429421),this[_0x4c54c9('0x3d')][_0x12e856[_0x4c54c9('0xa0')]]=_0x429421,this[_0x4c54c9('0x21')](_0x429421);}}catch(_0x32705d){logger[_0x4c54c9('0x97')]('[syncQueueCallerJoin][VoiceQueueReport]',util[_0x4c54c9('0x33')](_0x32705d,{'showHidden':![],'depth':null}));}},VoiceQueueReport['prototype'][_0x45991c('0xb6')]=function(_0x30c82a){const _0x45666d=_0x45991c;try{if(this[_0x45666d('0x8c')](_0x30c82a)){if(this[_0x45666d('0x9c')][_0x30c82a[_0x45666d('0xa0')]]){const _0x1c4cec=_[_0x45666d('0x5a')](this[_0x45666d('0x9c')][_0x30c82a[_0x45666d('0xa0')]]);_0x1c4cec['queuecallercomplete']=![],_0x1c4cec[_0x45666d('0xac')]=null,_0x1c4cec[_0x45666d('0x58')]=_0x30c82a['holdtime'],_0x1c4cec['originalposition']=_0x30c82a[_0x45666d('0x6d')],_0x1c4cec['queuecallerabandon']=!![],_0x1c4cec[_0x45666d('0x2d')]=moment()[_0x45666d('0x4')](_0x45666d('0x5e')),_0x1c4cec['queuecallerexitreason']=_0x45666d('0x63'),_0x1c4cec[_0x45666d('0x2b')]=null,this[_0x45666d('0x3d')][_0x30c82a[_0x45666d('0xa0')]]=_0x1c4cec,this[_0x45666d('0xb2')](_0x1c4cec);}}}catch(_0x1f520b){logger[_0x45666d('0x97')](_0x45666d('0x31'),util[_0x45666d('0x33')](_0x1f520b,{'showHidden':![],'depth':null}));}},VoiceQueueReport['prototype']['syncQueueCallerLeave']=function(_0x307c16){const _0x317806=_0x45991c;try{if(this[_0x317806('0x8c')](_0x307c16)){if(this[_0x317806('0x9c')][_0x307c16[_0x317806('0xa0')]]){const _0x5d2f09=_['last'](this[_0x317806('0x9c')][_0x307c16['uniqueid']]);_0x5d2f09[_0x317806('0x26')]=moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),_0x5d2f09[_0x317806('0xbc')]=_0x307c16['connectedlinenum'],_0x5d2f09[_0x317806('0x3e')]=_0x307c16[_0x317806('0x3e')],this[_0x317806('0x3d')][_0x307c16['uniqueid']]=_0x5d2f09,this[_0x317806('0x21')](_0x5d2f09);}}}catch(_0x5611be){logger[_0x317806('0x97')]('[syncQueueCallerLeave][VoiceQueueReport]',util[_0x317806('0x33')](_0x5611be,{'showHidden':![],'depth':null}));}},VoiceQueueReport['prototype'][_0x45991c('0x4c')]=function(_0x31de42){const _0x576004=_0x45991c;try{if(this['isNotNull'](_0x31de42)){if(this[_0x576004('0x9c')][_0x31de42['uniqueid']]){const _0x535bca=_[_0x576004('0x5a')](this[_0x576004('0x9c')][_0x31de42['uniqueid']]);_0x535bca['queuecallercomplete']=!![],_0x535bca[_0x576004('0x95')]=_0x576004('0xba');}}}catch(_0x4cb4d1){logger['error'](_0x576004('0x72'),util[_0x576004('0x33')](_0x4cb4d1,{'showHidden':![],'depth':null}));}},VoiceQueueReport['prototype'][_0x45991c('0x5b')]=function(_0xe75a48){const _0x24e4f2=_0x45991c;try{if(this[_0x24e4f2('0x8c')](_0xe75a48)){if(this[_0x24e4f2('0x9c')][_0xe75a48[_0x24e4f2('0xa0')]]){const _0x26af01=_['last'](this[_0x24e4f2('0x9c')][_0xe75a48['uniqueid']]);_0x26af01['queuecallerabandon']=![],_0x26af01['queuecallerabandonAt']=null,_0x26af01[_0x24e4f2('0x37')]=!![],_0x26af01[_0x24e4f2('0x2b')]=_0xe75a48['membername'],_0x26af01[_0x24e4f2('0x58')]=_0xe75a48[_0x24e4f2('0x58')],_0x26af01[_0x24e4f2('0x1f')]=!![],_0x26af01['queuecallerexit']=![],_0x26af01['queuecallerexitAt']=null;if(!_0x26af01[_0x24e4f2('0x34')]){if(_0xe75a48[_0x24e4f2('0x89')]==_0x24e4f2('0x34'))_0x26af01[_0x24e4f2('0x95')]=_0x24e4f2('0xc');else{if(_[_0x24e4f2('0x52')](_0xe75a48['channel']['toLowerCase'](),'local/')){if(this[_0x24e4f2('0x9c')][_0xe75a48['linkedid']]){const _0x536943=_[_0x24e4f2('0x5a')](this[_0x24e4f2('0x9c')][_0xe75a48[_0x24e4f2('0x40')]]);_0x536943[_0x24e4f2('0x1f')]=![],_0x536943[_0x24e4f2('0x49')]=!![],_0x536943[_0x24e4f2('0x38')]=moment(_0x26af01[_0x24e4f2('0x53')])[_0x24e4f2('0x41')](_0xe75a48[_0x24e4f2('0x58')],'seconds')['format'](_0x24e4f2('0x5e')),_0x536943['queuecallerexitreason']=_0x24e4f2('0x7a'),_0x536943[_0x24e4f2('0x34')]=!![],_0x536943[_0x24e4f2('0x6')]=_0x24e4f2('0x4d'),_0x536943[_0x24e4f2('0x60')]=_0xe75a48[_0x24e4f2('0xb0')],_0x536943[_0x24e4f2('0xa')]=_0xe75a48[_0x24e4f2('0xa0')];const _0x1a5e34=this[_0x24e4f2('0x9c')][_0xe75a48[_0x24e4f2('0x40')]];this[_0x24e4f2('0x9c')][_0xe75a48[_0x24e4f2('0x40')]]=this[_0x24e4f2('0x9c')][_0xe75a48[_0x24e4f2('0xa0')]],this['queueReports'][_0xe75a48[_0x24e4f2('0xa0')]]=_0x1a5e34;}}else _0x26af01['queuecallerexitreason']='COMPLETEDBY'+_0xe75a48[_0x24e4f2('0x89')][_0x24e4f2('0x4b')]();}}this['channels'][_0xe75a48[_0x24e4f2('0xa0')]]=_0x26af01,this[_0x24e4f2('0xb2')](_0x26af01);}}}catch(_0xcfe0b6){logger[_0x24e4f2('0x97')](_0x24e4f2('0xae'),util[_0x24e4f2('0x33')](_0xcfe0b6,{'showHidden':![],'depth':null}));}},VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0x2')]=function(_0x4522f5){const _0x301714=_0x45991c;try{if(this['isNotNull'](_0x4522f5)){this['addVariable'](_0x4522f5[_0x301714('0xa0')],_[_0x301714('0x5d')](_0x4522f5[_0x301714('0x66')])[0x0],_0x4522f5[_0x301714('0x20')]);if(this[_0x301714('0x9c')][_0x4522f5[_0x301714('0xa0')]]){const _0x506fcd=_[_0x301714('0x5a')](this['queueReports'][_0x4522f5[_0x301714('0xa0')]]);if(_0x506fcd){if(this['isNotNull'](_0x4522f5['variable'])&&this['isNotNull'](_0x4522f5[_0x301714('0x66')][_0x301714('0xaa')])){switch(_0x4522f5['value']){case'CONTINUE':_0x506fcd[_0x301714('0x49')]=![],_0x506fcd['queuecallerexitAt']=null;break;case'TIMEOUT':_0x506fcd[_0x301714('0x4f')]='timeout',ami['emit'](_0x301714('0xb5'),_0x506fcd);break;default:_0x506fcd[_0x301714('0x49')]=!![],_0x506fcd[_0x301714('0x38')]=moment()[_0x301714('0x4')]('YYYY-MM-DD\x20HH:mm:ss'),_0x506fcd[_0x301714('0x26')]=moment()[_0x301714('0x4')]('YYYY-MM-DD\x20HH:mm:ss');}_0x506fcd[_0x301714('0x8d')]=![],_0x506fcd[_0x301714('0x2d')]=null,_0x506fcd[_0x301714('0x95')]=_0x4522f5[_0x301714('0x20')],this[_0x301714('0x3d')][_0x4522f5[_0x301714('0xa0')]]=_0x506fcd,this[_0x301714('0xb2')](_0x506fcd);}else this[_0x301714('0x8c')](_0x4522f5[_0x301714('0x66')])&&this[_0x301714('0x8c')](_0x4522f5[_0x301714('0x66')][_0x301714('0xa3')])&&(!_0x506fcd['queuecallerabandon']&&(_0x506fcd[_0x301714('0x49')]=!![],_0x506fcd['queuecallerexitAt']=moment()[_0x301714('0x4')](_0x301714('0x5e')),_0x506fcd['queuecallerexitreason']=_0x301714('0x25'),_0x506fcd[_0x301714('0x26')]=moment()[_0x301714('0x4')](_0x301714('0x5e')),this['channels'][_0x4522f5[_0x301714('0xa0')]]=_0x506fcd));_0x506fcd[_0x301714('0x43')]=this[_0x301714('0x43')][_0x4522f5[_0x301714('0xa0')]];}}}}catch(_0x25bdea){logger[_0x301714('0x97')](_0x301714('0xb8'),util[_0x301714('0x33')](_0x25bdea,{'showHidden':![],'depth':null}));}},VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0xa7')]=function(_0x38766d,_0x1b5b0a,_0x53788c){const _0x1dedc1=_0x45991c,_0x431a89=[_0x1dedc1('0xab'),'rtpaudioqosbridged','rtpaudioqosjitter','rtpaudioqosjitterbridged',_0x1dedc1('0x27'),_0x1dedc1('0xa1'),_0x1dedc1('0x3'),'rtpaudioqosrttbridged',_0x1dedc1('0x8e'),_0x1dedc1('0xb4'),_0x1dedc1('0x96'),_0x1dedc1('0x90'),_0x1dedc1('0x75'),_0x1dedc1('0x24'),'memberinterface',_0x1dedc1('0x2c'),_0x1dedc1('0x57'),_0x1dedc1('0x1b'),'memberrealtime'];!_[_0x1dedc1('0xa4')](_0x1b5b0a)&&!_[_0x1dedc1('0x5c')](_0x431a89,_0x1b5b0a)&&(_[_0x1dedc1('0x1e')](this[_0x1dedc1('0x43')][_0x38766d])&&(this[_0x1dedc1('0x43')][_0x38766d]={}),this[_0x1dedc1('0x43')][_0x38766d][_0x1b5b0a]=_0x53788c);},VoiceQueueReport[_0x45991c('0x8a')][_0x45991c('0x11')]=function(_0x404556){const _0x495f72=_0x45991c;try{if(this[_0x495f72('0x8c')](_0x404556)){if(this[_0x495f72('0x9c')][_0x404556[_0x495f72('0xa0')]]){for(let _0x35b2d5=0x0,_0x5ad573={};_0x35b2d50x0?_0x1e2f23:0x0,this[_0x2f719e('0x0')][_0xe02074[_0x2f719e('0xae')]]['talking']=this['voiceQueues'][_0xe02074[_0x2f719e('0xae')]][_0x2f719e('0x50')]>_[_0x2f719e('0xa1')](_0xe02074[_0x2f719e('0xb4')])?_[_0x2f719e('0xa1')](_0xe02074[_0x2f719e('0xb4')]):this[_0x2f719e('0x0')][_0xe02074[_0x2f719e('0xae')]][_0x2f719e('0x50')],this[_0x2f719e('0x4b')](this['voiceQueues'][_0xe02074['queue']])),ami[_0x2f719e('0x9b')]('custom:queuesummary',this[_0x2f719e('0x0')][_0xe02074[_0x2f719e('0xae')]]);}}}catch(_0x2caf05){logger[_0x2f719e('0x7c')]('[syncQueueSummary][VoiceQueueReport]',util[_0x2f719e('0x5e')](_0x2caf05,{'showHidden':![],'depth':null}));}},VoiceQueueReport[_0x1ad16d('0x44')][_0x1ad16d('0xa5')]=function(){this['flagQueueSummary']=!![];},VoiceQueueReport[_0x1ad16d('0x44')][_0x1ad16d('0x43')]=function(){},VoiceQueueReport[_0x1ad16d('0x44')][_0x1ad16d('0x3')]=function(_0x85501){const _0x41a339=_0x1ad16d;try{if(this[_0x41a339('0x10')](_0x85501)){_[_0x41a339('0x80')](this[_0x41a339('0x74')][_0x85501['uniqueid']])&&(this['queueReports'][_0x85501[_0x41a339('0x23')]]=[],this[_0x41a339('0x7a')][_0x85501[_0x41a339('0x23')]]={});const _0x2e9a43=new QueueReport();_0x2e9a43[_0x41a339('0x73')]=_0x85501[_0x41a339('0xae')],_0x2e9a43[_0x41a339('0xc3')]=this[_0x41a339('0x0')][_0x2e9a43[_0x41a339('0x73')]]&&this[_0x41a339('0x0')][_0x2e9a43['name']][_0x41a339('0xc3')]?this[_0x41a339('0x0')][_0x2e9a43[_0x41a339('0x73')]]['type']||_0x41a339('0x3c'):_0x41a339('0x3c'),_0x2e9a43[_0x41a339('0xae')]=_0x85501[_0x41a339('0xae')],_0x2e9a43['queuecallerjoinAt']=moment()['format'](_0x41a339('0x15')),_0x2e9a43['position']=_0x85501[_0x41a339('0x4c')],_0x2e9a43[_0x41a339('0x14')]=_0x85501[_0x41a339('0x14')],_[_0x41a339('0x9d')](_0x2e9a43,_[_0x41a339('0xa9')](_0x85501,_[_0x41a339('0x11')](_0x2e9a43))),this[_0x41a339('0x74')][_0x85501[_0x41a339('0x23')]][_0x41a339('0xb')](_0x2e9a43),this[_0x41a339('0x7a')][_0x85501[_0x41a339('0x23')]]=_0x2e9a43,this[_0x41a339('0xd')](_0x2e9a43);}}catch(_0x380004){logger[_0x41a339('0x7c')](_0x41a339('0x8a'),util['inspect'](_0x380004,{'showHidden':![],'depth':null}));}},VoiceQueueReport[_0x1ad16d('0x44')]['syncQueueCallerAbandon']=function(_0x4edede){const _0x2e8e36=_0x1ad16d;try{if(this[_0x2e8e36('0x10')](_0x4edede)){if(this['queueReports'][_0x4edede[_0x2e8e36('0x23')]]){const _0x9758b7=_[_0x2e8e36('0x8e')](this['queueReports'][_0x4edede[_0x2e8e36('0x23')]]);_0x9758b7[_0x2e8e36('0x96')]=![],_0x9758b7[_0x2e8e36('0x59')]=null,_0x9758b7[_0x2e8e36('0x2f')]=_0x4edede[_0x2e8e36('0x2f')],_0x9758b7[_0x2e8e36('0x40')]=_0x4edede[_0x2e8e36('0x40')],_0x9758b7[_0x2e8e36('0xb8')]=!![],_0x9758b7['queuecallerabandonAt']=moment()[_0x2e8e36('0x92')]('YYYY-MM-DD\x20HH:mm:ss'),_0x9758b7['queuecallerexitreason']='ABANDONED',_0x9758b7[_0x2e8e36('0x5a')]=null,this['channels'][_0x4edede[_0x2e8e36('0x23')]]=_0x9758b7,this[_0x2e8e36('0x53')](_0x9758b7);}}}catch(_0x3f1763){logger[_0x2e8e36('0x7c')]('[syncQueueCallerAbandon][VoiceQueueReport]',util['inspect'](_0x3f1763,{'showHidden':![],'depth':null}));}},VoiceQueueReport[_0x1ad16d('0x44')][_0x1ad16d('0x55')]=function(_0x3efed6){const _0x242ce9=_0x1ad16d;try{if(this[_0x242ce9('0x10')](_0x3efed6)){if(this['queueReports'][_0x3efed6[_0x242ce9('0x23')]]){const _0x9bafa9=_[_0x242ce9('0x8e')](this[_0x242ce9('0x74')][_0x3efed6[_0x242ce9('0x23')]]);_0x9bafa9[_0x242ce9('0x90')]=moment()[_0x242ce9('0x92')](_0x242ce9('0x15')),_0x9bafa9[_0x242ce9('0x88')]=_0x3efed6['connectedlinenum'],_0x9bafa9[_0x242ce9('0x5')]=_0x3efed6[_0x242ce9('0x5')],this[_0x242ce9('0x7a')][_0x3efed6[_0x242ce9('0x23')]]=_0x9bafa9,this[_0x242ce9('0xd')](_0x9bafa9);}}}catch(_0x19e479){logger[_0x242ce9('0x7c')](_0x242ce9('0xa4'),util[_0x242ce9('0x5e')](_0x19e479,{'showHidden':![],'depth':null}));}},VoiceQueueReport['prototype'][_0x1ad16d('0x6c')]=function(_0x4d372d){const _0x26e51b=_0x1ad16d;try{if(this['isNotNull'](_0x4d372d)){if(this[_0x26e51b('0x74')][_0x4d372d[_0x26e51b('0x23')]]){const _0x559fb1=_[_0x26e51b('0x8e')](this[_0x26e51b('0x74')][_0x4d372d['uniqueid']]);_0x559fb1[_0x26e51b('0x96')]=!![],_0x559fb1[_0x26e51b('0x98')]=_0x26e51b('0x29');}}}catch(_0x3f58da){logger[_0x26e51b('0x7c')](_0x26e51b('0x34'),util[_0x26e51b('0x5e')](_0x3f58da,{'showHidden':![],'depth':null}));}},VoiceQueueReport['prototype'][_0x1ad16d('0x33')]=function(_0x375df1){const _0x442cdd=_0x1ad16d;try{if(this[_0x442cdd('0x10')](_0x375df1)){if(this['queueReports'][_0x375df1['uniqueid']]){const _0x566d71=_['last'](this[_0x442cdd('0x74')][_0x375df1[_0x442cdd('0x23')]]);_0x566d71[_0x442cdd('0xb8')]=![],_0x566d71[_0x442cdd('0x3a')]=null,_0x566d71[_0x442cdd('0x58')]=!![],_0x566d71[_0x442cdd('0x5a')]=_0x375df1[_0x442cdd('0x47')],_0x566d71[_0x442cdd('0x2f')]=_0x375df1[_0x442cdd('0x2f')],_0x566d71['queuecallercomplete']=!![],_0x566d71[_0x442cdd('0x65')]=![],_0x566d71[_0x442cdd('0xa')]=null;if(!_0x566d71['transfer']){if(_0x375df1[_0x442cdd('0xa8')]==_0x442cdd('0x86'))_0x566d71['queuecallerexitreason']=_0x442cdd('0x8d');else{if(_[_0x442cdd('0x82')](_0x375df1[_0x442cdd('0xbf')][_0x442cdd('0x3f')](),_0x442cdd('0x4d'))){if(this['queueReports'][_0x375df1[_0x442cdd('0x21')]]){const _0x464c04=_[_0x442cdd('0x8e')](this['queueReports'][_0x375df1[_0x442cdd('0x21')]]);_0x464c04[_0x442cdd('0x96')]=![],_0x464c04['queuecallerexit']=!![],_0x464c04[_0x442cdd('0xa')]=moment(_0x566d71[_0x442cdd('0x94')])[_0x442cdd('0x20')](_0x375df1['holdtime'],_0x442cdd('0xe'))['format']('YYYY-MM-DD\x20HH:mm:ss'),_0x464c04['queuecallerexitreason']=_0x442cdd('0x5f'),_0x464c04[_0x442cdd('0x86')]=!![],_0x464c04['transfertype']=_0x442cdd('0x31'),_0x464c04['transferexten']=_0x375df1['destexten'],_0x464c04['transferuniqueid']=_0x375df1[_0x442cdd('0x23')];const _0xbf8bfe=this[_0x442cdd('0x74')][_0x375df1[_0x442cdd('0x21')]];this['queueReports'][_0x375df1[_0x442cdd('0x21')]]=this[_0x442cdd('0x74')][_0x375df1['uniqueid']],this[_0x442cdd('0x74')][_0x375df1[_0x442cdd('0x23')]]=_0xbf8bfe;}}else _0x566d71[_0x442cdd('0x98')]='COMPLETEDBY'+_0x375df1[_0x442cdd('0xa8')]['toUpperCase']();}}this['channels'][_0x375df1['uniqueid']]=_0x566d71,this[_0x442cdd('0x53')](_0x566d71);}}}catch(_0x5b18e3){logger[_0x442cdd('0x7c')](_0x442cdd('0xb6'),util['inspect'](_0x5b18e3,{'showHidden':![],'depth':null}));}},VoiceQueueReport[_0x1ad16d('0x44')][_0x1ad16d('0xba')]=function(_0xd0ed69){const _0x122b5e=_0x1ad16d;try{if(this[_0x122b5e('0x10')](_0xd0ed69)){this[_0x122b5e('0xac')](_0xd0ed69['uniqueid'],_[_0x122b5e('0x11')](_0xd0ed69['variable'])[0x0],_0xd0ed69[_0x122b5e('0x9e')]);if(this[_0x122b5e('0x74')][_0xd0ed69[_0x122b5e('0x23')]]){const _0xd0daff=_['last'](this[_0x122b5e('0x74')][_0xd0ed69[_0x122b5e('0x23')]]);if(_0xd0daff){if(this[_0x122b5e('0x10')](_0xd0ed69[_0x122b5e('0x2b')])&&this['isNotNull'](_0xd0ed69[_0x122b5e('0x2b')][_0x122b5e('0x1a')])){switch(_0xd0ed69[_0x122b5e('0x9e')]){case _0x122b5e('0xaf'):_0xd0daff[_0x122b5e('0x65')]=![],_0xd0daff[_0x122b5e('0xa')]=null;break;case'TIMEOUT':_0xd0daff['lastevent']=_0x122b5e('0xbe'),ami[_0x122b5e('0x9b')](_0x122b5e('0x8c'),_0xd0daff);break;default:_0xd0daff[_0x122b5e('0x65')]=!![],_0xd0daff[_0x122b5e('0xa')]=moment()[_0x122b5e('0x92')](_0x122b5e('0x15')),_0xd0daff[_0x122b5e('0x90')]=moment()['format']('YYYY-MM-DD\x20HH:mm:ss');}_0xd0daff['queuecallerabandon']=![],_0xd0daff[_0x122b5e('0x3a')]=null,_0xd0daff[_0x122b5e('0x98')]=_0xd0ed69[_0x122b5e('0x9e')],this[_0x122b5e('0x7a')][_0xd0ed69[_0x122b5e('0x23')]]=_0xd0daff,this[_0x122b5e('0x53')](_0xd0daff);}else this[_0x122b5e('0x10')](_0xd0ed69[_0x122b5e('0x2b')])&&this[_0x122b5e('0x10')](_0xd0ed69[_0x122b5e('0x2b')]['queueposition'])&&(!_0xd0daff[_0x122b5e('0xb8')]&&(_0xd0daff['queuecallerexit']=!![],_0xd0daff['queuecallerexitAt']=moment()['format'](_0x122b5e('0x15')),_0xd0daff[_0x122b5e('0x98')]='EXITWITHKEY',_0xd0daff['queuecallerleaveAt']=moment()[_0x122b5e('0x92')]('YYYY-MM-DD\x20HH:mm:ss'),this[_0x122b5e('0x7a')][_0xd0ed69[_0x122b5e('0x23')]]=_0xd0daff));_0xd0daff['variables']=this[_0x122b5e('0xa3')][_0xd0ed69[_0x122b5e('0x23')]];}}}}catch(_0x28d5f3){logger[_0x122b5e('0x7c')]('[syncVarSet][VoiceQueueReport]',util[_0x122b5e('0x5e')](_0x28d5f3,{'showHidden':![],'depth':null}));}},VoiceQueueReport[_0x1ad16d('0x44')][_0x1ad16d('0xac')]=function(_0x28dfd8,_0x556659,_0x37d897){const _0xe5ba9a=_0x1ad16d,_0x1c518c=[_0xe5ba9a('0x6e'),_0xe5ba9a('0xaa'),_0xe5ba9a('0x3d'),_0xe5ba9a('0xa6'),_0xe5ba9a('0x97'),_0xe5ba9a('0x75'),_0xe5ba9a('0x62'),_0xe5ba9a('0x99'),_0xe5ba9a('0x51'),_0xe5ba9a('0x45'),_0xe5ba9a('0x2a'),_0xe5ba9a('0x67'),_0xe5ba9a('0x71'),'memberdynamic',_0xe5ba9a('0x9a'),_0xe5ba9a('0x85'),'membername',_0xe5ba9a('0xbb'),'memberrealtime'];!_[_0xe5ba9a('0xb5')](_0x556659)&&!_[_0xe5ba9a('0x77')](_0x1c518c,_0x556659)&&(_[_0xe5ba9a('0x80')](this[_0xe5ba9a('0xa3')][_0x28dfd8])&&(this[_0xe5ba9a('0xa3')][_0x28dfd8]={}),this[_0xe5ba9a('0xa3')][_0x28dfd8][_0x556659]=_0x37d897);},VoiceQueueReport['prototype'][_0x1ad16d('0x1e')]=function(_0x3bd238){const _0x419948=_0x1ad16d;try{if(this[_0x419948('0x10')](_0x3bd238)){if(this[_0x419948('0x74')][_0x3bd238[_0x419948('0x23')]]){for(let _0x4c52c1=0x0,_0x28e6b8={};_0x4c52c1=0x0?moment(_0x4e85ad[_0x1333d0('0x3')])['diff'](_0x4e85ad[_0x1333d0('0x1')],'seconds'):null,'data1':_0x1333d0('0x2'),'data2':_0x4e85ad[_0x1333d0('0x14')],'data3':_0x4e85ad[_0x1333d0('0xd')],'data4':_0x4e85ad[_0x1333d0('0x11')]||null,'role':_0x1333d0('0x1d'),'internal':_0x4e85ad['accountcode']?_['toNumber'](_0x4e85ad[_0x1333d0('0x14')]):undefined,'uniqueid':_0x4e85ad[_0x1333d0('0x5')]},'log':_0x1333d0('0x1b')});}; \ No newline at end of file +const a1119_0x2622=['format','CreateMemberReport','queuecallerleaveAt','toNumber','diff','queuecallercompleteAt','membername','voice','util','TALKING','lodash','accountcode','lastAssignedTo','uniqueid','starttime','endtime','interface','isNil','voiceDialReport','voiceQueueReport','moment','seconds','dialstring','../client'];(function(_0x10de9e,_0x262242){const _0x252047=function(_0x2d5cab){while(--_0x2d5cab){_0x10de9e['push'](_0x10de9e['shift']());}};_0x252047(++_0x262242);}(a1119_0x2622,0xa9));const a1119_0x2520=function(_0x10de9e,_0x262242){_0x10de9e=_0x10de9e-0x0;let _0x252047=a1119_0x2622[_0x10de9e];return _0x252047;};const _0x5502b9=a1119_0x2520;'use strict';const moment=require(_0x5502b9('0x13')),_=require(_0x5502b9('0x9')),util=require(_0x5502b9('0x7')),client=require(_0x5502b9('0x16'));exports[_0x5502b9('0x12')]=function(_0x2d5cab){const _0x5e9bb6=_0x5502b9,_0x558694=_0x2d5cab[_0x5e9bb6('0x4')]||_0x2d5cab['queuecallerexitAt'];return client['Request'](_0x5e9bb6('0x0'),{'body':{'channel':_0x5e9bb6('0x6'),'membername':_0x2d5cab[_0x5e9bb6('0xb')],'interface':_[_0x5e9bb6('0x10')](_0x2d5cab[_0x5e9bb6('0xf')])?util[_0x5e9bb6('0x17')]('SIP/%s',_0x2d5cab['lastAssignedTo']):_0x2d5cab[_0x5e9bb6('0xf')],'type':_0x5e9bb6('0x8'),'enterAt':_0x2d5cab[_0x5e9bb6('0x1')],'exitAt':_0x558694,'duration':moment(_0x558694)[_0x5e9bb6('0x3')](_0x2d5cab[_0x5e9bb6('0x1')],_0x5e9bb6('0x14')),'data1':'inbound','data2':_0x2d5cab['calleridnum'],'data3':_0x2d5cab['exten'],'data4':null,'data5':_0x2d5cab['queue'],'role':'agent','internal':_0x2d5cab[_0x5e9bb6('0xa')]?_[_0x5e9bb6('0x2')](_0x2d5cab[_0x5e9bb6('0xa')]):undefined,'uniqueid':_0x2d5cab[_0x5e9bb6('0xc')]},'log':_0x5e9bb6('0x0')});},exports[_0x5502b9('0x11')]=function(_0x27131a){const _0x231ed3=_0x5502b9;return client['Request']('CreateMemberReport',{'body':{'channel':_0x231ed3('0x6'),'membername':_0x27131a[_0x231ed3('0x5')],'interface':_0x27131a[_0x231ed3('0xf')],'type':'TALKING','enterAt':_0x27131a[_0x231ed3('0xd')],'exitAt':_0x27131a[_0x231ed3('0xe')],'duration':moment(_0x27131a[_0x231ed3('0xe')])[_0x231ed3('0x3')](_0x27131a[_0x231ed3('0xd')],_0x231ed3('0x14'))>=0x0?moment(_0x27131a[_0x231ed3('0xe')])['diff'](_0x27131a[_0x231ed3('0xd')],_0x231ed3('0x14')):null,'data1':'outbound','data2':_0x27131a[_0x231ed3('0xa')],'data3':_0x27131a['exten'],'data4':_0x27131a[_0x231ed3('0x15')]||null,'role':'agent','internal':_0x27131a[_0x231ed3('0xa')]?_[_0x231ed3('0x2')](_0x27131a[_0x231ed3('0xa')]):undefined,'uniqueid':_0x27131a[_0x231ed3('0xc')]},'log':_0x231ed3('0x0')});}; \ No newline at end of file diff --git a/server/services/ami/rpc/template.js b/server/services/ami/rpc/template.js index cb54c93..cb22e53 100644 --- a/server/services/ami/rpc/template.js +++ b/server/services/ami/rpc/template.js @@ -1 +1 @@ -const a1120_0xe2fd=['name','html','../client','GetTemplate','getTemplates','Request'];(function(_0x384edc,_0xe2fd54){const _0x586ace=function(_0x167563){while(--_0x167563){_0x384edc['push'](_0x384edc['shift']());}};_0x586ace(++_0xe2fd54);}(a1120_0xe2fd,0xc5));const a1120_0x586a=function(_0x384edc,_0xe2fd54){_0x384edc=_0x384edc-0x0;let _0x586ace=a1120_0xe2fd[_0x384edc];return _0x586ace;};const _0x49c332=a1120_0x586a;'use strict';const client=require(_0x49c332('0x3'));exports[_0x49c332('0x5')]=function(){return function(){const _0x16dea7=a1120_0x586a;return client[_0x16dea7('0x0')](_0x16dea7('0x4'),{'options':{'raw':!![],'attributes':['id',_0x16dea7('0x1'),_0x16dea7('0x2')]},'log':_0x16dea7('0x4')});};}; \ No newline at end of file +const a1120_0x40f5=['name','Request','GetTemplate','html','../client'];(function(_0x5cbcb0,_0x40f5bf){const _0x32607f=function(_0x11b15b){while(--_0x11b15b){_0x5cbcb0['push'](_0x5cbcb0['shift']());}};_0x32607f(++_0x40f5bf);}(a1120_0x40f5,0x100));const a1120_0x3260=function(_0x5cbcb0,_0x40f5bf){_0x5cbcb0=_0x5cbcb0-0x0;let _0x32607f=a1120_0x40f5[_0x5cbcb0];return _0x32607f;};const _0x5a75aa=a1120_0x3260;'use strict';const client=require(_0x5a75aa('0x3'));exports['getTemplates']=function(){return function(){const _0x15f1c5=a1120_0x3260;return client[_0x15f1c5('0x0')](_0x15f1c5('0x1'),{'options':{'raw':!![],'attributes':['id',_0x15f1c5('0x4'),_0x15f1c5('0x2')]},'log':'GetTemplate'});};}; \ No newline at end of file diff --git a/server/services/ami/rpc/trigger.js b/server/services/ami/rpc/trigger.js index b806ba4..1596069 100644 --- a/server/services/ami/rpc/trigger.js +++ b/server/services/ami/rpc/trigger.js @@ -1 +1 @@ -const a1121_0x3c2a=['action','channel','field','operator','GetTrigger','data1','value','name','data4','AllConditions','data5','getTriggers','Condition','AnyConditions','data2','../client'];(function(_0x19571d,_0x3c2ad1){const _0x26e99e=function(_0x3666cf){while(--_0x3666cf){_0x19571d['push'](_0x19571d['shift']());}};_0x26e99e(++_0x3c2ad1);}(a1121_0x3c2a,0x18d));const a1121_0x26e9=function(_0x19571d,_0x3c2ad1){_0x19571d=_0x19571d-0x0;let _0x26e99e=a1121_0x3c2a[_0x19571d];return _0x26e99e;};const _0x1e7e26=a1121_0x26e9;'use strict';const client=require(_0x1e7e26('0x2'));exports[_0x1e7e26('0xe')]=function(){return function(){const _0x3ee2f6=a1121_0x26e9;return client['Request'](_0x3ee2f6('0x7'),{'options':{'raw':![],'attributes':['id',_0x3ee2f6('0xa'),_0x3ee2f6('0x4'),'status'],'include':[{'model':_0x3ee2f6('0xf'),'as':_0x3ee2f6('0xc'),'attributes':['id',_0x3ee2f6('0x5'),_0x3ee2f6('0x6'),_0x3ee2f6('0x9')]},{'model':_0x3ee2f6('0xf'),'as':_0x3ee2f6('0x0'),'attributes':['id',_0x3ee2f6('0x5'),'operator',_0x3ee2f6('0x9')]},{'model':'Action','as':'Actions','attributes':['id',_0x3ee2f6('0x3'),_0x3ee2f6('0x8'),_0x3ee2f6('0x1'),'data3',_0x3ee2f6('0xb'),_0x3ee2f6('0xd'),'data6','data7']}]},'log':_0x3ee2f6('0x7')});};}; \ No newline at end of file +const a1121_0x2ab3=['data5','name','data2','Actions','data3','operator','data7','status','AnyConditions','data4','field','Request','Condition','data6','value','Action','channel','GetTrigger','getTriggers','action'];(function(_0x11495f,_0x2ab335){const _0x39670c=function(_0x51c9ee){while(--_0x51c9ee){_0x11495f['push'](_0x11495f['shift']());}};_0x39670c(++_0x2ab335);}(a1121_0x2ab3,0x171));const a1121_0x3967=function(_0x11495f,_0x2ab335){_0x11495f=_0x11495f-0x0;let _0x39670c=a1121_0x2ab3[_0x11495f];return _0x39670c;};const _0x8f78bc=a1121_0x3967;'use strict';const client=require('../client');exports[_0x8f78bc('0x9')]=function(){return function(){const _0x345000=a1121_0x3967;return client[_0x345000('0x2')](_0x345000('0x8'),{'options':{'raw':![],'attributes':['id',_0x345000('0xc'),_0x345000('0x7'),_0x345000('0x12')],'include':[{'model':_0x345000('0x3'),'as':'AllConditions','attributes':['id',_0x345000('0x1'),'operator','value']},{'model':_0x345000('0x3'),'as':_0x345000('0x13'),'attributes':['id','field',_0x345000('0x10'),_0x345000('0x5')]},{'model':_0x345000('0x6'),'as':_0x345000('0xe'),'attributes':['id',_0x345000('0xa'),'data1',_0x345000('0xd'),_0x345000('0xf'),_0x345000('0x0'),_0x345000('0xb'),_0x345000('0x4'),_0x345000('0x11')]}]},'log':_0x345000('0x8')});};}; \ No newline at end of file diff --git a/server/services/ami/rpc/trunk.js b/server/services/ami/rpc/trunk.js index 09bcaa6..5ec0069 100644 --- a/server/services/ami/rpc/trunk.js +++ b/server/services/ami/rpc/trunk.js @@ -1 +1 @@ -const a1122_0x1ce9=['GetTrunk','Request','name','../client','registry'];(function(_0x50d637,_0x1ce985){const _0x40ca0f=function(_0x6b5a8c){while(--_0x6b5a8c){_0x50d637['push'](_0x50d637['shift']());}};_0x40ca0f(++_0x1ce985);}(a1122_0x1ce9,0xf6));const a1122_0x40ca=function(_0x50d637,_0x1ce985){_0x50d637=_0x50d637-0x0;let _0x40ca0f=a1122_0x1ce9[_0x50d637];return _0x40ca0f;};const _0x2177e4=a1122_0x40ca;'use strict';const client=require(_0x2177e4('0x2'));exports['getTrunks']=function(){return function(){const _0x32242d=a1122_0x40ca;return client[_0x32242d('0x0')](_0x32242d('0x4'),{'options':{'raw':!![],'where':{'active':0x1},'attributes':['id',_0x32242d('0x1'),_0x32242d('0x3')]},'log':_0x32242d('0x4')});};}; \ No newline at end of file +const a1122_0x4d5e=['../client','GetTrunk','registry'];(function(_0x508dbc,_0x4d5e13){const _0x4e013e=function(_0x14680d){while(--_0x14680d){_0x508dbc['push'](_0x508dbc['shift']());}};_0x4e013e(++_0x4d5e13);}(a1122_0x4d5e,0x148));const a1122_0x4e01=function(_0x508dbc,_0x4d5e13){_0x508dbc=_0x508dbc-0x0;let _0x4e013e=a1122_0x4d5e[_0x508dbc];return _0x4e013e;};const _0x1b08a5=a1122_0x4e01;'use strict';const client=require(_0x1b08a5('0x2'));exports['getTrunks']=function(){return function(){const _0x1a715a=a1122_0x4e01;return client['Request'](_0x1a715a('0x0'),{'options':{'raw':!![],'where':{'active':0x1},'attributes':['id','name',_0x1a715a('0x1')]},'log':_0x1a715a('0x0')});};}; \ No newline at end of file diff --git a/server/services/ami/rpc/user.js b/server/services/ami/rpc/user.js index db8b0e0..0fdbdf1 100644 --- a/server/services/ami/rpc/user.js +++ b/server/services/ami/rpc/user.js @@ -1 +1 @@ -const a1123_0x1381=['fullname','getTelephones','name','internal','getAgents','Request','PauseUser','pauseType','telephone','interface','mobile','ShowUser','lastPauseAt','lastLoginAt','getAgent','saveUnpause','voicePause','accountcode','GetUser','savePause','../client','phone','online','UnpauseUser'];(function(_0x2cffab,_0x1381c0){const _0x30b8ce=function(_0x6bac10){while(--_0x6bac10){_0x2cffab['push'](_0x2cffab['shift']());}};_0x30b8ce(++_0x1381c0);}(a1123_0x1381,0xbe));const a1123_0x30b8=function(_0x2cffab,_0x1381c0){_0x2cffab=_0x2cffab-0x0;let _0x30b8ce=a1123_0x1381[_0x2cffab];return _0x30b8ce;};const _0x5f0b68=a1123_0x30b8;'use strict';const client=require(_0x5f0b68('0x16'));exports[_0x5f0b68('0x6')]=function(){return function(){const _0x480904=a1123_0x30b8;return client['Request'](_0x480904('0x14'),{'options':{'raw':![],'where':{'role':'agent'},'attributes':['id',_0x480904('0x4'),'email',_0x480904('0x13'),_0x480904('0x2'),_0x480904('0x0'),'lastLoginAt',_0x480904('0x9'),_0x480904('0xe'),_0x480904('0x12'),_0x480904('0x17'),_0x480904('0xc'),_0x480904('0xb')]},'log':'getAgents'});};},exports[_0x5f0b68('0x3')]=function(){return function(){const _0x1ad448=a1123_0x30b8;return client[_0x1ad448('0x7')](_0x1ad448('0x14'),{'options':{'raw':!![],'where':{'role':_0x1ad448('0xa')},'attributes':['id','name',_0x1ad448('0x13'),_0x1ad448('0x5')]},'log':'getTelephones'});};},exports[_0x5f0b68('0x15')]=function(_0x6bac10,_0x25dbc3,_0x39eb70){const _0x5503a1=_0x5f0b68;return client[_0x5503a1('0x7')](_0x5503a1('0x8'),{'body':{'type':_0x25dbc3,'uniqueid':_0x39eb70},'options':{'where':{'id':_0x6bac10['id']}},'log':_0x5503a1('0x15')});},exports[_0x5f0b68('0x11')]=function(_0xea52a2){const _0x4e0a3a=_0x5f0b68;return client[_0x4e0a3a('0x7')](_0x4e0a3a('0x1'),{'body':{},'options':{'where':{'id':_0xea52a2['id']}},'log':_0x4e0a3a('0x15')});},exports[_0x5f0b68('0x10')]=function(_0x9e3da9){const _0x5c3175=_0x5f0b68;return client[_0x5c3175('0x7')](_0x5c3175('0xd'),{'options':{'raw':![],'where':{'role':'agent','id':_0x9e3da9},'attributes':['id',_0x5c3175('0x4'),'email',_0x5c3175('0x13'),_0x5c3175('0x2'),_0x5c3175('0x0'),_0x5c3175('0xf'),'pauseType','lastPauseAt',_0x5c3175('0x12'),_0x5c3175('0xb')]},'log':_0x5c3175('0x10')});}; \ No newline at end of file +const a1123_0x1ff7=['getAgent','phone','savePause','name','UnpauseUser','internal','lastLoginAt','getAgents','fullname','interface','ShowUser','email','accountcode','GetUser','voicePause','Request','PauseUser','getTelephones','online','agent','telephone','lastPauseAt','pauseType'];(function(_0xf372be,_0x1ff7c9){const _0x53be8a=function(_0x16900a){while(--_0x16900a){_0xf372be['push'](_0xf372be['shift']());}};_0x53be8a(++_0x1ff7c9);}(a1123_0x1ff7,0xe9));const a1123_0x53be=function(_0xf372be,_0x1ff7c9){_0xf372be=_0xf372be-0x0;let _0x53be8a=a1123_0x1ff7[_0xf372be];return _0x53be8a;};const _0x51eaf6=a1123_0x53be;'use strict';const client=require('../client');exports[_0x51eaf6('0x4')]=function(){return function(){const _0xfe3205=a1123_0x53be;return client[_0xfe3205('0xc')](_0xfe3205('0xa'),{'options':{'raw':![],'where':{'role':_0xfe3205('0x10')},'attributes':['id',_0xfe3205('0x0'),_0xfe3205('0x8'),_0xfe3205('0x9'),_0xfe3205('0x5'),'online',_0xfe3205('0x3'),_0xfe3205('0x13'),_0xfe3205('0x12'),_0xfe3205('0xb'),_0xfe3205('0x15'),'mobile',_0xfe3205('0x6')]},'log':_0xfe3205('0x4')});};},exports[_0x51eaf6('0xe')]=function(){return function(){const _0x508bf4=a1123_0x53be;return client[_0x508bf4('0xc')](_0x508bf4('0xa'),{'options':{'raw':!![],'where':{'role':_0x508bf4('0x11')},'attributes':['id','name',_0x508bf4('0x9'),_0x508bf4('0x2')]},'log':_0x508bf4('0xe')});};},exports[_0x51eaf6('0x16')]=function(_0x16900a,_0xc863e3,_0x488ef9){const _0xe67838=_0x51eaf6;return client['Request'](_0xe67838('0xd'),{'body':{'type':_0xc863e3,'uniqueid':_0x488ef9},'options':{'where':{'id':_0x16900a['id']}},'log':'savePause'});},exports['saveUnpause']=function(_0x761fd1){const _0x53e18d=_0x51eaf6;return client[_0x53e18d('0xc')](_0x53e18d('0x1'),{'body':{},'options':{'where':{'id':_0x761fd1['id']}},'log':_0x53e18d('0x16')});},exports[_0x51eaf6('0x14')]=function(_0x1a4fe3){const _0x66b01f=_0x51eaf6;return client['Request'](_0x66b01f('0x7'),{'options':{'raw':![],'where':{'role':'agent','id':_0x1a4fe3},'attributes':['id',_0x66b01f('0x0'),_0x66b01f('0x8'),'accountcode','fullname',_0x66b01f('0xf'),_0x66b01f('0x3'),_0x66b01f('0x13'),_0x66b01f('0x12'),_0x66b01f('0xb'),_0x66b01f('0x6')]},'log':_0x66b01f('0x14')});}; \ No newline at end of file diff --git a/server/services/ami/rpc/voiceAgentReport.js b/server/services/ami/rpc/voiceAgentReport.js index fa600a6..064ebdc 100644 --- a/server/services/ami/rpc/voiceAgentReport.js +++ b/server/services/ami/rpc/voiceAgentReport.js @@ -1 +1 @@ -const a1124_0x2b25=['create','UpdateVoiceAgentReport','Request','update','../client','CreateVoiceAgentReport'];(function(_0x590f82,_0x2b252b){const _0x30153e=function(_0x80b175){while(--_0x80b175){_0x590f82['push'](_0x590f82['shift']());}};_0x30153e(++_0x2b252b);}(a1124_0x2b25,0x1d4));const a1124_0x3015=function(_0x590f82,_0x2b252b){_0x590f82=_0x590f82-0x0;let _0x30153e=a1124_0x2b25[_0x590f82];return _0x30153e;};const _0x35de14=a1124_0x3015;'use strict';const client=require(_0x35de14('0x4'));exports[_0x35de14('0x0')]=function(_0x80b175){const _0x45537d=_0x35de14;return client[_0x45537d('0x2')](_0x45537d('0x5'),{'body':_0x80b175,'log':_0x45537d('0x5')});},exports[_0x35de14('0x3')]=function(_0x299595,_0x363b77,_0x52d54c){const _0x3ae46a=_0x35de14;return client[_0x3ae46a('0x2')](_0x3ae46a('0x1'),{'body':_0x299595,'options':{'where':{'uniqueid':_0x363b77,'interface':_0x52d54c,'agentcomplete':!![]}},'log':_0x3ae46a('0x1')});}; \ No newline at end of file +const a1124_0x289c=['create','CreateVoiceAgentReport','Request','UpdateVoiceAgentReport','../client'];(function(_0x2c0ccb,_0x289c5c){const _0x20f958=function(_0x322928){while(--_0x322928){_0x2c0ccb['push'](_0x2c0ccb['shift']());}};_0x20f958(++_0x289c5c);}(a1124_0x289c,0x7c));const a1124_0x20f9=function(_0x2c0ccb,_0x289c5c){_0x2c0ccb=_0x2c0ccb-0x0;let _0x20f958=a1124_0x289c[_0x2c0ccb];return _0x20f958;};const _0x3f4d06=a1124_0x20f9;'use strict';const client=require(_0x3f4d06('0x0'));exports[_0x3f4d06('0x1')]=function(_0x322928){const _0x51a50f=_0x3f4d06;return client[_0x51a50f('0x3')]('CreateVoiceAgentReport',{'body':_0x322928,'log':_0x51a50f('0x2')});},exports['update']=function(_0x9b115f,_0x41b5a1,_0x5b5adc){const _0xbee1da=_0x3f4d06;return client[_0xbee1da('0x3')](_0xbee1da('0x4'),{'body':_0x9b115f,'options':{'where':{'uniqueid':_0x41b5a1,'interface':_0x5b5adc,'agentcomplete':!![]}},'log':'UpdateVoiceAgentReport'});}; \ No newline at end of file diff --git a/server/services/ami/rpc/voiceCallReport.js b/server/services/ami/rpc/voiceCallReport.js index bf9378b..670e277 100644 --- a/server/services/ami/rpc/voiceCallReport.js +++ b/server/services/ami/rpc/voiceCallReport.js @@ -1 +1 @@ -const a1125_0x157c=['create','format','endOf','merge','disposition','Request','moment','CreateVoiceCallReport','day','DOCUMENTATION','outbound','calleridnum','YYYY-MM-DD\x20HH:mm:ss'];(function(_0x58cc45,_0x157cda){const _0x4c2d05=function(_0x3c0bd0){while(--_0x3c0bd0){_0x58cc45['push'](_0x58cc45['shift']());}};_0x4c2d05(++_0x157cda);}(a1125_0x157c,0xe5));const a1125_0x4c2d=function(_0x58cc45,_0x157cda){_0x58cc45=_0x58cc45-0x0;let _0x4c2d05=a1125_0x157c[_0x58cc45];return _0x4c2d05;};const _0x3a3271=a1125_0x4c2d;'use strict';const moment=require(_0x3a3271('0xb')),_=require('lodash'),client=require('../client');exports[_0x3a3271('0x5')]=function(_0x3c0bd0){const _0x17ac06=_0x3a3271;return client['Request'](_0x17ac06('0xc'),{'body':_[_0x17ac06('0x8')](_0x3c0bd0,{'source':_0x3c0bd0[_0x17ac06('0x3')],'destinationcontext':_0x3c0bd0['context'],'callerid':_0x3c0bd0['callerid'],'amaflags':_0x17ac06('0x1')}),'log':_0x17ac06('0xc')});},exports['getVoiceCallReports']=function(){return function(){const _0x1f8cd2=a1125_0x4c2d;return client[_0x1f8cd2('0xa')]('GetVoiceCallReport',{'options':{'where':{'type':[_0x1f8cd2('0x2')],'createdAt':{'$between':[moment()['startOf'](_0x1f8cd2('0x0'))[_0x1f8cd2('0x6')]('YYYY-MM-DD\x20HH:mm:ss'),moment()[_0x1f8cd2('0x7')]('day')[_0x1f8cd2('0x6')](_0x1f8cd2('0x4'))]}},'attributes':['type',_0x1f8cd2('0x9'),'duration','billableseconds']},'log':'GetVoiceCallReports'});};}; \ No newline at end of file +const a1125_0x540f=['lodash','Request','getVoiceCallReports','moment','../client','create','duration','type','billableseconds','GetVoiceCallReport','day','format','disposition','DOCUMENTATION','calleridnum','CreateVoiceCallReport','startOf','outbound','callerid','GetVoiceCallReports'];(function(_0x51d31e,_0x540fa5){const _0x14455a=function(_0x57af63){while(--_0x57af63){_0x51d31e['push'](_0x51d31e['shift']());}};_0x14455a(++_0x540fa5);}(a1125_0x540f,0x1c2));const a1125_0x1445=function(_0x51d31e,_0x540fa5){_0x51d31e=_0x51d31e-0x0;let _0x14455a=a1125_0x540f[_0x51d31e];return _0x14455a;};const _0x278941=a1125_0x1445;'use strict';const moment=require(_0x278941('0xd')),_=require(_0x278941('0xa')),client=require(_0x278941('0xe'));exports[_0x278941('0xf')]=function(_0x57af63){const _0x161062=_0x278941;return client[_0x161062('0xb')](_0x161062('0x5'),{'body':_['merge'](_0x57af63,{'source':_0x57af63[_0x161062('0x4')],'destinationcontext':_0x57af63['context'],'callerid':_0x57af63[_0x161062('0x8')],'amaflags':_0x161062('0x3')}),'log':'CreateVoiceCallReport'});},exports[_0x278941('0xc')]=function(){return function(){const _0x2c81c9=a1125_0x1445;return client[_0x2c81c9('0xb')](_0x2c81c9('0x13'),{'options':{'where':{'type':[_0x2c81c9('0x7')],'createdAt':{'$between':[moment()[_0x2c81c9('0x6')](_0x2c81c9('0x0'))[_0x2c81c9('0x1')]('YYYY-MM-DD\x20HH:mm:ss'),moment()['endOf'](_0x2c81c9('0x0'))['format']('YYYY-MM-DD\x20HH:mm:ss')]}},'attributes':[_0x2c81c9('0x11'),_0x2c81c9('0x2'),_0x2c81c9('0x10'),_0x2c81c9('0x12')]},'log':_0x2c81c9('0x9')});};}; \ No newline at end of file diff --git a/server/services/ami/rpc/voiceDialReport.js b/server/services/ami/rpc/voiceDialReport.js index ba7d724..0e6f490 100644 --- a/server/services/ami/rpc/voiceDialReport.js +++ b/server/services/ami/rpc/voiceDialReport.js @@ -1 +1 @@ -const a1126_0x1165=['CreateVoiceDialReport','create','../client'];(function(_0x332220,_0x116568){const _0x263acc=function(_0x2b124a){while(--_0x2b124a){_0x332220['push'](_0x332220['shift']());}};_0x263acc(++_0x116568);}(a1126_0x1165,0x19a));const a1126_0x263a=function(_0x332220,_0x116568){_0x332220=_0x332220-0x0;let _0x263acc=a1126_0x1165[_0x332220];return _0x263acc;};const _0xfbfcfa=a1126_0x263a;'use strict';const client=require(_0xfbfcfa('0x0'));exports[_0xfbfcfa('0x2')]=function(_0x2b124a){const _0x463a8d=_0xfbfcfa;return client['Request'](_0x463a8d('0x1'),{'body':_0x2b124a,'log':_0x463a8d('0x1')});}; \ No newline at end of file +const a1126_0x57a3=['CreateVoiceDialReport','Request'];(function(_0x11a13a,_0x57a386){const _0xdc23f3=function(_0x22f9cc){while(--_0x22f9cc){_0x11a13a['push'](_0x11a13a['shift']());}};_0xdc23f3(++_0x57a386);}(a1126_0x57a3,0x7f));const a1126_0xdc23=function(_0x11a13a,_0x57a386){_0x11a13a=_0x11a13a-0x0;let _0xdc23f3=a1126_0x57a3[_0x11a13a];return _0xdc23f3;};'use strict';const client=require('../client');exports['create']=function(_0x22f9cc){const _0x1833fc=a1126_0xdc23;return client[_0x1833fc('0x0')](_0x1833fc('0x1'),{'body':_0x22f9cc,'log':'CreateVoiceDialReport'});}; \ No newline at end of file diff --git a/server/services/ami/rpc/voiceExtension.js b/server/services/ami/rpc/voiceExtension.js index 4038d0f..21230b4 100644 --- a/server/services/ami/rpc/voiceExtension.js +++ b/server/services/ami/rpc/voiceExtension.js @@ -1 +1 @@ -const a1127_0x547a=['Request','exten','recordingFormat','getVoiceExtensions','GetVoiceExtension'];(function(_0x149b45,_0x547a9b){const _0x2edfd1=function(_0x548847){while(--_0x548847){_0x149b45['push'](_0x149b45['shift']());}};_0x2edfd1(++_0x547a9b);}(a1127_0x547a,0x1c2));const a1127_0x2edf=function(_0x149b45,_0x547a9b){_0x149b45=_0x149b45-0x0;let _0x2edfd1=a1127_0x547a[_0x149b45];return _0x2edfd1;};const _0x38f4c9=a1127_0x2edf;'use strict';const client=require('../client');exports[_0x38f4c9('0x3')]=function(){return function(){const _0x2793a9=a1127_0x2edf;return client[_0x2793a9('0x0')](_0x2793a9('0x4'),{'options':{'raw':!![],'attributes':['id',_0x2793a9('0x1'),_0x2793a9('0x2')],'where':{'VoiceExtensionId':null}},'log':_0x2793a9('0x3')});};}; \ No newline at end of file +const a1127_0x4de4=['getVoiceExtensions','recordingFormat','Request','../client','GetVoiceExtension'];(function(_0x4cfc1b,_0x4de456){const _0x40c7f6=function(_0x42b9f7){while(--_0x42b9f7){_0x4cfc1b['push'](_0x4cfc1b['shift']());}};_0x40c7f6(++_0x4de456);}(a1127_0x4de4,0x1be));const a1127_0x40c7=function(_0x4cfc1b,_0x4de456){_0x4cfc1b=_0x4cfc1b-0x0;let _0x40c7f6=a1127_0x4de4[_0x4cfc1b];return _0x40c7f6;};const _0x5f17af=a1127_0x40c7;'use strict';const client=require(_0x5f17af('0x2'));exports[_0x5f17af('0x4')]=function(){return function(){const _0x4151ce=a1127_0x40c7;return client[_0x4151ce('0x1')](_0x4151ce('0x3'),{'options':{'raw':!![],'attributes':['id','exten',_0x4151ce('0x0')],'where':{'VoiceExtensionId':null}},'log':_0x4151ce('0x4')});};}; \ No newline at end of file diff --git a/server/services/ami/rpc/voiceQueue.js b/server/services/ami/rpc/voiceQueue.js index e7c276e..ab86120 100644 --- a/server/services/ami/rpc/voiceQueue.js +++ b/server/services/ami/rpc/voiceQueue.js @@ -1 +1 @@ -const a1128_0x26f7=['dialNoSuchNumberRetryFrequency','mandatoryDispositionPause','strategy','dialAbandonedMaxRetry','dialPredictiveInterval','dialPrefix','../client','dialTimezone','dialMethod','dialGlobalInterval','active','dialLimitChannel','monitor_format','dialOriginateCallerIdName','GetVoiceQueue','interval','Request','dialBusyRetryFrequency','dialNoSuchNumberMaxRetry','dialRecallInQueue','dialQueueTimeout','dialQueueProject2','dialQueueProject','dialOriginateTimeout','dialMachineRetryFrequency','dialAMDBetweenWordsSilence','dialMachineMaxRetry','dialGlobalMaxRetry','dialBusyMaxRetry','dialAMDActive','dialPredictiveOptimizationPercentage','Interval','dialAMDMaximumNumberOfWords','dialAgentRejectRetryFrequency','dialPredictiveOptimization','mandatoryDisposition','dialAgentRejectMaxRetry','dialDropRetryFrequency','dialCongestionMaxRetry','Intervals','acw','dialAMDTotalAnalysisTime','dialPowerLevel','timeout','dialPredictiveIntervalMaxThreshold','name','dialRandomLastDigitCallerIdNumber','dialQueueOptions','dialOrderByScheduledAt','dialCongestionRetryFrequency','Trunk','dialCutDigit','dialLimitQueue','dialAMDAfterGreetingSilence','TrunkBackup','callerid','dialAMDInitialSilence'];(function(_0x391854,_0x26f75e){const _0x1afd53=function(_0x2c38d5){while(--_0x2c38d5){_0x391854['push'](_0x391854['shift']());}};_0x1afd53(++_0x26f75e);}(a1128_0x26f7,0x13f));const a1128_0x1afd=function(_0x391854,_0x26f75e){_0x391854=_0x391854-0x0;let _0x1afd53=a1128_0x26f7[_0x391854];return _0x1afd53;};const _0x30805e=a1128_0x1afd;'use strict';const client=require(_0x30805e('0x1d'));exports['getVoiceQueues']=function(){return function(){const _0x21c5e3=a1128_0x1afd;return client[_0x21c5e3('0x27')](_0x21c5e3('0x25'),{'options':{'raw':![],'attributes':['id',_0x21c5e3('0xb'),_0x21c5e3('0x6'),'acwTimeout','autopause',_0x21c5e3('0x23'),'type','dialActive',_0x21c5e3('0x1f'),_0x21c5e3('0x22'),_0x21c5e3('0x12'),_0x21c5e3('0x8'),_0x21c5e3('0x0'),_0x21c5e3('0x35'),_0x21c5e3('0x1b'),_0x21c5e3('0x24'),'dialOriginateCallerIdNumber',_0x21c5e3('0x2e'),_0x21c5e3('0xd'),_0x21c5e3('0x2b'),_0x21c5e3('0x2d'),_0x21c5e3('0x4'),_0x21c5e3('0xf'),_0x21c5e3('0x33'),_0x21c5e3('0x28'),'dialNoAnswerMaxRetry','dialNoAnswerRetryFrequency',_0x21c5e3('0x32'),_0x21c5e3('0x1e'),_0x21c5e3('0x20'),_0x21c5e3('0x1c'),'dialCheckDuplicateType',_0x21c5e3('0x34'),_0x21c5e3('0x16'),'dialAMDGreeting',_0x21c5e3('0x13'),_0x21c5e3('0x7'),'dialAMDMinWordLength',_0x21c5e3('0x30'),_0x21c5e3('0x37'),'dialAMDSilenceThreshold','dialAMDMaximumWordLength',_0x21c5e3('0x9'),'dialRecallMeTimeout',_0x21c5e3('0x2a'),_0x21c5e3('0xe'),'dialAgiAfterHangupAgent','dialAgiAfterHangupClient',_0x21c5e3('0x2c'),_0x21c5e3('0x23'),_0x21c5e3('0x19'),_0x21c5e3('0xc'),_0x21c5e3('0x11'),_0x21c5e3('0x29'),_0x21c5e3('0x17'),'dialDropMaxRetry',_0x21c5e3('0x3'),_0x21c5e3('0x1a'),'dialAbandonedRetryFrequency',_0x21c5e3('0x31'),_0x21c5e3('0x2f'),_0x21c5e3('0x2'),_0x21c5e3('0x38'),_0x21c5e3('0x1'),_0x21c5e3('0xa'),'dialPredictiveIntervalMinThreshold'],'include':[{'model':_0x21c5e3('0x10'),'as':_0x21c5e3('0x10'),'attributes':['id',_0x21c5e3('0xb'),_0x21c5e3('0x15'),_0x21c5e3('0x21')]},{'model':'Pause','as':_0x21c5e3('0x18'),'attributes':['id',_0x21c5e3('0xb')]},{'model':_0x21c5e3('0x10'),'as':_0x21c5e3('0x14'),'attributes':['id',_0x21c5e3('0xb'),_0x21c5e3('0x15'),'active']},{'model':_0x21c5e3('0x36'),'as':_0x21c5e3('0x36'),'attributes':['id',_0x21c5e3('0xb')],'include':[{'model':_0x21c5e3('0x36'),'as':_0x21c5e3('0x5'),'attributes':['id','name',_0x21c5e3('0x26')]}]}]},'log':'getVoiceQueues'});};}; \ No newline at end of file +const a1128_0x2046=['dialOrderByScheduledAt','callerid','autopause','Pause','getVoiceQueues','dialCongestionMaxRetry','dialAbandonedMaxRetry','dialQueueOptions','dialAMDInitialSilence','dialAMDGreeting','dialRecallInQueue','dialMachineRetryFrequency','Interval','name','strategy','dialAMDMaximumNumberOfWords','dialGlobalMaxRetry','Request','dialNoSuchNumberRetryFrequency','dialAMDMaximumWordLength','dialLimitQueue','timeout','acw','dialRecallMeTimeout','dialTimezone','dialMethod','../client','dialAMDActive','active','dialAbandonedRetryFrequency','mandatoryDisposition','dialDropRetryFrequency','dialNoAnswerMaxRetry','dialPredictiveIntervalMinThreshold','dialAgiAfterHangupAgent','dialPrefix','dialPredictiveOptimizationPercentage','dialAMDMinWordLength','dialQueueProject','dialCheckDuplicateType','dialAMDSilenceThreshold','dialOriginateTimeout','dialGlobalInterval','dialPredictiveIntervalMaxThreshold','dialPredictiveInterval','dialActive','dialPredictiveOptimization','dialCongestionRetryFrequency','dialPowerLevel','dialAgentRejectMaxRetry','dialMachineMaxRetry','dialLimitChannel','dialDropMaxRetry','dialNoAnswerRetryFrequency','monitor_format','acwTimeout','Trunk','TrunkBackup','dialQueueProject2','dialAMDBetweenWordsSilence','mandatoryDispositionPause'];(function(_0x8f6552,_0x204654){const _0x13e1a1=function(_0x215172){while(--_0x215172){_0x8f6552['push'](_0x8f6552['shift']());}};_0x13e1a1(++_0x204654);}(a1128_0x2046,0x172));const a1128_0x13e1=function(_0x8f6552,_0x204654){_0x8f6552=_0x8f6552-0x0;let _0x13e1a1=a1128_0x2046[_0x8f6552];return _0x13e1a1;};const _0x425a5b=a1128_0x13e1;'use strict';const client=require(_0x425a5b('0x16'));exports[_0x425a5b('0x0')]=function(){return function(){const _0x5087d7=a1128_0x13e1;return client[_0x5087d7('0xd')]('GetVoiceQueue',{'options':{'raw':![],'attributes':['id',_0x5087d7('0x9'),_0x5087d7('0x12'),_0x5087d7('0x33'),_0x5087d7('0x3b'),'monitor_format','type',_0x5087d7('0x29'),_0x5087d7('0x15'),_0x5087d7('0x2f'),_0x5087d7('0x10'),_0x5087d7('0x2c'),_0x5087d7('0x2a'),_0x5087d7('0x20'),_0x5087d7('0x28'),'dialOriginateCallerIdName','dialOriginateCallerIdNumber',_0x5087d7('0x25'),_0x5087d7('0x3'),'dialQueueTimeout',_0x5087d7('0x22'),_0x5087d7('0x1'),_0x5087d7('0x2b'),'dialBusyMaxRetry','dialBusyRetryFrequency',_0x5087d7('0x1c'),_0x5087d7('0x31'),_0x5087d7('0xc'),_0x5087d7('0x14'),_0x5087d7('0x26'),_0x5087d7('0x1f'),_0x5087d7('0x23'),_0x5087d7('0x17'),_0x5087d7('0x4'),_0x5087d7('0x5'),'dialAMDAfterGreetingSilence','dialAMDTotalAnalysisTime',_0x5087d7('0x21'),_0x5087d7('0x37'),_0x5087d7('0xb'),_0x5087d7('0x24'),_0x5087d7('0xf'),_0x5087d7('0x11'),_0x5087d7('0x13'),_0x5087d7('0x6'),_0x5087d7('0x39'),_0x5087d7('0x1e'),'dialAgiAfterHangupClient',_0x5087d7('0x36'),_0x5087d7('0x32'),_0x5087d7('0xa'),'dialRandomLastDigitCallerIdNumber','dialCutDigit','dialNoSuchNumberMaxRetry',_0x5087d7('0xe'),_0x5087d7('0x30'),_0x5087d7('0x1b'),_0x5087d7('0x2'),_0x5087d7('0x19'),_0x5087d7('0x2e'),_0x5087d7('0x7'),_0x5087d7('0x2d'),'dialAgentRejectRetryFrequency',_0x5087d7('0x1a'),_0x5087d7('0x27'),_0x5087d7('0x1d')],'include':[{'model':'Trunk','as':'Trunk','attributes':['id',_0x5087d7('0x9'),_0x5087d7('0x3a'),_0x5087d7('0x18')]},{'model':_0x5087d7('0x3c'),'as':_0x5087d7('0x38'),'attributes':['id',_0x5087d7('0x9')]},{'model':_0x5087d7('0x34'),'as':_0x5087d7('0x35'),'attributes':['id',_0x5087d7('0x9'),_0x5087d7('0x3a'),_0x5087d7('0x18')]},{'model':_0x5087d7('0x8'),'as':'Interval','attributes':['id',_0x5087d7('0x9')],'include':[{'model':_0x5087d7('0x8'),'as':'Intervals','attributes':['id',_0x5087d7('0x9'),'interval']}]}]},'log':_0x5087d7('0x0')});};}; \ No newline at end of file diff --git a/server/services/ami/rpc/voiceQueueReport.js b/server/services/ami/rpc/voiceQueueReport.js index c160627..70f96c7 100644 --- a/server/services/ami/rpc/voiceQueueReport.js +++ b/server/services/ami/rpc/voiceQueueReport.js @@ -1 +1 @@ -const a1129_0x435c=['YYYY-MM-DD\x20HH:mm:ss','queuecallerabandon','queuecallerabandonAt','queuecallerleaveAt','format','Request','startOf','day','queuecallercomplete','GetVoiceQueueReport','CreateVoiceQueueReport','uniqueid','GetVoiceQueueReports','create','queuecallerexit','queuecallerjoinAt','getVoiceQueueReports','queuecallercompleteAt'];(function(_0x6c69bf,_0x435ca5){const _0x261d5f=function(_0x4b3dd9){while(--_0x4b3dd9){_0x6c69bf['push'](_0x6c69bf['shift']());}};_0x261d5f(++_0x435ca5);}(a1129_0x435c,0xcf));const a1129_0x261d=function(_0x6c69bf,_0x435ca5){_0x6c69bf=_0x6c69bf-0x0;let _0x261d5f=a1129_0x435c[_0x6c69bf];return _0x261d5f;};const _0x501713=a1129_0x261d;'use strict';const moment=require('moment'),client=require('../client');exports[_0x501713('0x4')]=function(_0x4b3dd9){const _0x2037e4=_0x501713;return client[_0x2037e4('0xe')]('CreateVoiceQueueReport',{'body':_0x4b3dd9,'log':_0x2037e4('0x1')});},exports[_0x501713('0x7')]=function(){return function(){const _0xb07f04=a1129_0x261d;return client[_0xb07f04('0xe')](_0xb07f04('0x0'),{'options':{'where':{'createdAt':{'$between':[moment()[_0xb07f04('0xf')](_0xb07f04('0x10'))[_0xb07f04('0xd')](_0xb07f04('0x9')),moment()['endOf'](_0xb07f04('0x10'))[_0xb07f04('0xd')]('YYYY-MM-DD\x20HH:mm:ss')]}},'attributes':[_0xb07f04('0x2'),'queue',_0xb07f04('0x6'),_0xb07f04('0xc'),_0xb07f04('0x11'),_0xb07f04('0x8'),_0xb07f04('0x5'),'queuecallerexitAt',_0xb07f04('0xa'),_0xb07f04('0xb')]},'log':_0xb07f04('0x3')});};}; \ No newline at end of file +const a1129_0x2d28=['CreateVoiceQueueReport','queuecallerabandonAt','endOf','startOf','format','day','queuecallercomplete','queuecallerexit','Request','queue','queuecallerexitAt','moment','YYYY-MM-DD\x20HH:mm:ss','queuecallerjoinAt','queuecallercompleteAt','getVoiceQueueReports','uniqueid','GetVoiceQueueReports','queuecallerabandon'];(function(_0x14d5c1,_0x2d2816){const _0x4b14a6=function(_0x546fab){while(--_0x546fab){_0x14d5c1['push'](_0x14d5c1['shift']());}};_0x4b14a6(++_0x2d2816);}(a1129_0x2d28,0x1bf));const a1129_0x4b14=function(_0x14d5c1,_0x2d2816){_0x14d5c1=_0x14d5c1-0x0;let _0x4b14a6=a1129_0x2d28[_0x14d5c1];return _0x4b14a6;};const _0x5c79eb=a1129_0x4b14;'use strict';const moment=require(_0x5c79eb('0x1')),client=require('../client');exports['create']=function(_0x546fab){const _0x930d62=_0x5c79eb;return client[_0x930d62('0x11')](_0x930d62('0x9'),{'body':_0x546fab,'log':'CreateVoiceQueueReport'});},exports[_0x5c79eb('0x5')]=function(){return function(){const _0x2f9513=a1129_0x4b14;return client[_0x2f9513('0x11')]('GetVoiceQueueReport',{'options':{'where':{'createdAt':{'$between':[moment()[_0x2f9513('0xc')](_0x2f9513('0xe'))['format'](_0x2f9513('0x2')),moment()[_0x2f9513('0xb')](_0x2f9513('0xe'))[_0x2f9513('0xd')]('YYYY-MM-DD\x20HH:mm:ss')]}},'attributes':[_0x2f9513('0x6'),_0x2f9513('0x12'),_0x2f9513('0x3'),'queuecallerleaveAt',_0x2f9513('0xf'),_0x2f9513('0x4'),_0x2f9513('0x10'),_0x2f9513('0x0'),_0x2f9513('0x8'),_0x2f9513('0xa')]},'log':_0x2f9513('0x7')});};}; \ No newline at end of file diff --git a/server/services/ami/rpc/voiceQueueRt.js b/server/services/ami/rpc/voiceQueueRt.js index ed13296..bc07bfc 100644 --- a/server/services/ami/rpc/voiceQueueRt.js +++ b/server/services/ami/rpc/voiceQueueRt.js @@ -1 +1 @@ -const a1130_0x2df0=['Request','../client','getVoiceQueueRtPauses'];(function(_0x32f231,_0x2df031){const _0x5092b0=function(_0x2197b8){while(--_0x2197b8){_0x32f231['push'](_0x32f231['shift']());}};_0x5092b0(++_0x2df031);}(a1130_0x2df0,0x12e));const a1130_0x5092=function(_0x32f231,_0x2df031){_0x32f231=_0x32f231-0x0;let _0x5092b0=a1130_0x2df0[_0x32f231];return _0x5092b0;};const _0x5b7ea6=a1130_0x5092;'use strict';const client=require(_0x5b7ea6('0x2'));exports[_0x5b7ea6('0x0')]=function(_0x2197b8){return function(){const _0x1694cd=a1130_0x5092;return client[_0x1694cd('0x1')]('GetVoiceQueueRtPauses',{'options':{'where':{'VoiceQueueId':_0x2197b8,'paused':!![]},'raw':!![]},'log':'getVoiceQueueRtPauses'});};}; \ No newline at end of file +const a1130_0x2f6f=['GetVoiceQueueRtPauses','getVoiceQueueRtPauses','Request'];(function(_0x1276c2,_0x2f6f87){const _0xa49a07=function(_0x4af2c4){while(--_0x4af2c4){_0x1276c2['push'](_0x1276c2['shift']());}};_0xa49a07(++_0x2f6f87);}(a1130_0x2f6f,0x132));const a1130_0xa49a=function(_0x1276c2,_0x2f6f87){_0x1276c2=_0x1276c2-0x0;let _0xa49a07=a1130_0x2f6f[_0x1276c2];return _0xa49a07;};const _0x519dc8=a1130_0xa49a;'use strict';const client=require('../client');exports[_0x519dc8('0x1')]=function(_0x4af2c4){return function(){const _0xeb68d=a1130_0xa49a;return client[_0xeb68d('0x2')](_0xeb68d('0x0'),{'options':{'where':{'VoiceQueueId':_0x4af2c4,'paused':!![]},'raw':!![]},'log':_0xeb68d('0x1')});};}; \ No newline at end of file diff --git a/server/services/ami/rpc/voiceRecording.js b/server/services/ami/rpc/voiceRecording.js index 517a56c..d0ebb95 100644 --- a/server/services/ami/rpc/voiceRecording.js +++ b/server/services/ami/rpc/voiceRecording.js @@ -1 +1 @@ -const a1131_0x4a3e=['lodash','../client','CreateVoiceRecording','create','Request'];(function(_0x524c69,_0x4a3e44){const _0x269cd5=function(_0x59b6b1){while(--_0x59b6b1){_0x524c69['push'](_0x524c69['shift']());}};_0x269cd5(++_0x4a3e44);}(a1131_0x4a3e,0x18f));const a1131_0x269c=function(_0x524c69,_0x4a3e44){_0x524c69=_0x524c69-0x0;let _0x269cd5=a1131_0x4a3e[_0x524c69];return _0x269cd5;};const _0x4d609f=a1131_0x269c;'use strict';const _=require(_0x4d609f('0x1')),client=require(_0x4d609f('0x2'));exports[_0x4d609f('0x4')]=function(_0x59b6b1){const _0x1447de=_0x4d609f;return client[_0x1447de('0x0')](_0x1447de('0x3'),{'body':_['merge'](_0x59b6b1,{'value':_0x59b6b1['monitorFilename']}),'log':_0x1447de('0x3')});}; \ No newline at end of file +const a1131_0x2859=['merge','monitorFilename','CreateVoiceRecording','create'];(function(_0x1f2e8b,_0x285959){const _0x3a7785=function(_0x38fba7){while(--_0x38fba7){_0x1f2e8b['push'](_0x1f2e8b['shift']());}};_0x3a7785(++_0x285959);}(a1131_0x2859,0xba));const a1131_0x3a77=function(_0x1f2e8b,_0x285959){_0x1f2e8b=_0x1f2e8b-0x0;let _0x3a7785=a1131_0x2859[_0x1f2e8b];return _0x3a7785;};const _0x25fac9=a1131_0x3a77;'use strict';const _=require('lodash'),client=require('../client');exports[_0x25fac9('0x1')]=function(_0x38fba7){const _0x2b6464=_0x25fac9;return client['Request'](_0x2b6464('0x0'),{'body':_[_0x2b6464('0x2')](_0x38fba7,{'value':_0x38fba7[_0x2b6464('0x3')]}),'log':'CreateVoiceRecording'});}; \ No newline at end of file diff --git a/server/services/ami/rpc/voiceTransferReport.js b/server/services/ami/rpc/voiceTransferReport.js index 3530df7..e7aeeb2 100644 --- a/server/services/ami/rpc/voiceTransferReport.js +++ b/server/services/ami/rpc/voiceTransferReport.js @@ -1 +1 @@ -const a1132_0x2978=['blindTransfer','transfereecalleridname','transfereeconnectedlinenum','transfertargetconnectedlinenum','transfertargetcalleridnum','transfertargetchannel','transfereeexten','origtransferercalleridnum','isexternal','transfertargetaccountcode','result','origtransferercalleridname','transfertargetconnectedlinename','origtransfererlinkedid','secondtransfererexten','transfererconnectedlinename','transfereelinkedid','blind','transfereraccountcode','transfertargetcalleridname','transfererconnectedlinenum','transfererlinkedid','Request','transfererexten','origtransfererchannel','transfereechannel','transferercalleridname','transfertargetcontext','transfertargetexten','transfertargetlinkedid','context','attended','secondtransfererconnectedlinename','origtransfererexten','extension','transfereeconnectedlinename','attendedTransfer','transferercontext','secondtransferercontext','transfereeaccountcode','CreateVoiceTransferReport','secondtransfererconnectedlinenum'];(function(_0x23bf87,_0x297861){const _0xe7c2b5=function(_0x4db133){while(--_0x4db133){_0x23bf87['push'](_0x23bf87['shift']());}};_0xe7c2b5(++_0x297861);}(a1132_0x2978,0xee));const a1132_0xe7c2=function(_0x23bf87,_0x297861){_0x23bf87=_0x23bf87-0x0;let _0xe7c2b5=a1132_0x2978[_0x23bf87];return _0xe7c2b5;};const _0x582b66=a1132_0xe7c2;'use strict';const client=require('../client');exports['transfers']={},exports[_0x582b66('0xe')]=function(_0x4db133){const _0x4531c2=_0x582b66;return client['Request'](_0x4531c2('0xc'),{'body':{'result':_0x4db133[_0x4531c2('0x18')],'transfererchannel':_0x4db133['transfererchannel'],'transferercalleridnum':_0x4db133['transferercalleridnum'],'transferercalleridname':_0x4db133[_0x4531c2('0x28')],'transfererconnectedlinenum':_0x4db133[_0x4531c2('0x22')],'transfererconnectedlinename':_0x4db133[_0x4531c2('0x1d')],'transfereraccountcode':_0x4db133[_0x4531c2('0x20')],'transferercontext':_0x4db133[_0x4531c2('0x9')],'transfererexten':_0x4db133[_0x4531c2('0x25')],'transfererlinkedid':_0x4db133[_0x4531c2('0x23')],'transfereechannel':_0x4db133[_0x4531c2('0x27')],'transfereecalleridnum':_0x4db133['transfereecalleridnum'],'transfereecalleridname':_0x4db133[_0x4531c2('0xf')],'transfereeconnectedlinenum':_0x4db133[_0x4531c2('0x10')],'transfereeconnectedlinename':_0x4db133[_0x4531c2('0x7')],'transfereeaccountcode':_0x4db133[_0x4531c2('0xb')],'transfereecontext':_0x4db133['transfereecontext'],'transfereeexten':_0x4db133[_0x4531c2('0x14')],'transfereelinkedid':_0x4db133[_0x4531c2('0x1e')],'isexternal':_0x4db133[_0x4531c2('0x16')],'context':_0x4db133[_0x4531c2('0x2')],'extension':_0x4db133[_0x4531c2('0x6')],'type':_0x4531c2('0x1f')},'log':_0x4531c2('0xc')});},exports[_0x582b66('0x8')]=function(_0x318bbb){const _0xa2e208=_0x582b66;return client[_0xa2e208('0x24')](_0xa2e208('0xc'),{'body':{'result':_0x318bbb[_0xa2e208('0x18')],'transfererchannel':_0x318bbb[_0xa2e208('0x26')],'transferercalleridnum':_0x318bbb[_0xa2e208('0x15')],'transferercalleridname':_0x318bbb[_0xa2e208('0x19')],'transfererconnectedlinenum':_0x318bbb[_0xa2e208('0xd')],'transfererconnectedlinename':_0x318bbb[_0xa2e208('0x4')],'transfereraccountcode':_0x318bbb['origtransfereraccountcode'],'transferercontext':_0x318bbb[_0xa2e208('0xa')],'transfererexten':_0x318bbb[_0xa2e208('0x1c')],'transfererlinkedid':_0x318bbb[_0xa2e208('0x1b')],'transfereechannel':_0x318bbb[_0xa2e208('0x13')],'transfereecalleridnum':_0x318bbb[_0xa2e208('0x12')],'transfereecalleridname':_0x318bbb[_0xa2e208('0x21')],'transfereeconnectedlinenum':_0x318bbb[_0xa2e208('0x11')],'transfereeconnectedlinename':_0x318bbb[_0xa2e208('0x1a')],'transfereeaccountcode':_0x318bbb[_0xa2e208('0x17')],'transfereecontext':_0x318bbb[_0xa2e208('0x29')],'transfereeexten':_0x318bbb[_0xa2e208('0x0')],'transfereelinkedid':_0x318bbb[_0xa2e208('0x1')],'isexternal':_0x318bbb[_0xa2e208('0x16')],'context':_0x318bbb['origtransferercontext'],'extension':_0x318bbb[_0xa2e208('0x5')],'type':_0xa2e208('0x3')},'log':_0xa2e208('0xc')});}; \ No newline at end of file +const a1132_0x1e3f=['origtransferercalleridname','origtransfereraccountcode','transfereeaccountcode','secondtransfererconnectedlinenum','transfertargetcontext','transferercalleridname','extension','origtransfererlinkedid','result','secondtransferercontext','transfererlinkedid','transferercalleridnum','transfererconnectedlinenum','context','../client','transfereraccountcode','origtransferercalleridnum','transfereeexten','transfereecalleridnum','secondtransfererconnectedlinename','transfereechannel','transfertargetlinkedid','transfereelinkedid','CreateVoiceTransferReport','transfererexten','transferercontext','isexternal','Request','origtransferercontext','transfererconnectedlinename','transfereecalleridname','transfertargetconnectedlinenum','transfertargetcalleridnum','blindTransfer','transfereeconnectedlinenum','transfereeconnectedlinename','transfers'];(function(_0x2015d4,_0x1e3fdc){const _0x24ce33=function(_0x36eb46){while(--_0x36eb46){_0x2015d4['push'](_0x2015d4['shift']());}};_0x24ce33(++_0x1e3fdc);}(a1132_0x1e3f,0x19b));const a1132_0x24ce=function(_0x2015d4,_0x1e3fdc){_0x2015d4=_0x2015d4-0x0;let _0x24ce33=a1132_0x1e3f[_0x2015d4];return _0x24ce33;};const _0x98d249=a1132_0x24ce;'use strict';const client=require(_0x98d249('0xa'));exports[_0x98d249('0x20')]={},exports[_0x98d249('0x1d')]=function(_0x36eb46){const _0x6e4c82=_0x98d249;return client[_0x6e4c82('0x17')](_0x6e4c82('0x13'),{'body':{'result':_0x36eb46[_0x6e4c82('0x4')],'transfererchannel':_0x36eb46['transfererchannel'],'transferercalleridnum':_0x36eb46[_0x6e4c82('0x7')],'transferercalleridname':_0x36eb46[_0x6e4c82('0x1')],'transfererconnectedlinenum':_0x36eb46[_0x6e4c82('0x8')],'transfererconnectedlinename':_0x36eb46[_0x6e4c82('0x19')],'transfereraccountcode':_0x36eb46[_0x6e4c82('0xb')],'transferercontext':_0x36eb46[_0x6e4c82('0x15')],'transfererexten':_0x36eb46[_0x6e4c82('0x14')],'transfererlinkedid':_0x36eb46[_0x6e4c82('0x6')],'transfereechannel':_0x36eb46[_0x6e4c82('0x10')],'transfereecalleridnum':_0x36eb46[_0x6e4c82('0xe')],'transfereecalleridname':_0x36eb46[_0x6e4c82('0x1a')],'transfereeconnectedlinenum':_0x36eb46[_0x6e4c82('0x1e')],'transfereeconnectedlinename':_0x36eb46[_0x6e4c82('0x1f')],'transfereeaccountcode':_0x36eb46[_0x6e4c82('0x23')],'transfereecontext':_0x36eb46['transfereecontext'],'transfereeexten':_0x36eb46[_0x6e4c82('0xd')],'transfereelinkedid':_0x36eb46[_0x6e4c82('0x12')],'isexternal':_0x36eb46[_0x6e4c82('0x16')],'context':_0x36eb46[_0x6e4c82('0x9')],'extension':_0x36eb46[_0x6e4c82('0x2')],'type':'blind'},'log':_0x6e4c82('0x13')});},exports['attendedTransfer']=function(_0x3dfbfb){const _0x46f0f2=_0x98d249;return client['Request'](_0x46f0f2('0x13'),{'body':{'result':_0x3dfbfb[_0x46f0f2('0x4')],'transfererchannel':_0x3dfbfb['origtransfererchannel'],'transferercalleridnum':_0x3dfbfb[_0x46f0f2('0xc')],'transferercalleridname':_0x3dfbfb[_0x46f0f2('0x21')],'transfererconnectedlinenum':_0x3dfbfb[_0x46f0f2('0x24')],'transfererconnectedlinename':_0x3dfbfb[_0x46f0f2('0xf')],'transfereraccountcode':_0x3dfbfb[_0x46f0f2('0x22')],'transferercontext':_0x3dfbfb[_0x46f0f2('0x5')],'transfererexten':_0x3dfbfb['secondtransfererexten'],'transfererlinkedid':_0x3dfbfb[_0x46f0f2('0x3')],'transfereechannel':_0x3dfbfb['transfertargetchannel'],'transfereecalleridnum':_0x3dfbfb[_0x46f0f2('0x1c')],'transfereecalleridname':_0x3dfbfb['transfertargetcalleridname'],'transfereeconnectedlinenum':_0x3dfbfb[_0x46f0f2('0x1b')],'transfereeconnectedlinename':_0x3dfbfb['transfertargetconnectedlinename'],'transfereeaccountcode':_0x3dfbfb['transfertargetaccountcode'],'transfereecontext':_0x3dfbfb[_0x46f0f2('0x0')],'transfereeexten':_0x3dfbfb['transfertargetexten'],'transfereelinkedid':_0x3dfbfb[_0x46f0f2('0x11')],'isexternal':_0x3dfbfb[_0x46f0f2('0x16')],'context':_0x3dfbfb[_0x46f0f2('0x18')],'extension':_0x3dfbfb['origtransfererexten'],'type':'attended'},'log':_0x46f0f2('0x13')});}; \ No newline at end of file diff --git a/server/services/ami/server/index.js b/server/services/ami/server/index.js index f15ce2a..9065dc5 100644 --- a/server/services/ami/server/index.js +++ b/server/services/ami/server/index.js @@ -1 +1 @@ -const a1133_0x2ea6=['../properties','event','message','predictiveIntervalTotalCalls','predictiveIntervalAnsweredCalls','channels','voicequeuechannelhangup','length','answered','outbound','predictiveIntervalAvailable','timer','../../../config/environment','outboundChannels','validate','voiceQueues','available','username','erlangAbandonmentRate','module','outboundCongestionCallsDay','outboundBusyCallsDay','server','uniqueid','Interval','jayson/promise','talking','type','pTalking','voicequeuechannel','values','command','startProgressive','predictiveIntervalDroppedCallsCallersExit','predictiveIntervalPauses','rec','voicechannel','timers','MixMonitor\x20Success','outboundDropCallsDayACS','sumHoldTime','catch','keys','outboundRejectCallsDay','predictiveIntervalDroppedCallsTimeout','sumBillable','originated','StopMixMonitor\x20Success','outboundNoAnswerCallsDay','emit','agents','dialOriginateCallerIdNumber','name','erlangCalls','destinationchannel','find','outboundAnswerCallsDay','predictiveIntervalErlangCallsDroppedCalls','map','dialPrefix','ami\x20disconnected','Redirect','predictiveIntervalAvgHoldtime','%s.%s','asterisk','wav','dialOriginateTimeout','Trunk','format','then','isNil','context','Command','callerid','join','telephones','ai(mixmonitorid)','queueChannels','StopMixMonitor','QueuePause','status','outboundBlacklistCallsDay','../ami','Channel\x20doesn\x27t\x20exist','strategy','dialActive','run','predictiveIntervalMultiplicativeFactor','sumDuration','trunks','action','outboundReCallsDay','outboundOriginateFailureCallsDay','isConnected','http','channel','/var/spool/asterisk/monitor/','dialOriginateCallerIdName','content','Reload','waiting','mixmonitorid','pick','toLowerCase','predictiveIntervalHitRate','abandoned','push','erlangBusyFactor','outboundAnswerAgiCallsDay','Action','dialMethod','checkAfterSend','monitors','127.0.0.1','YYYY-MM-DD\x20HH:mm:ss','voicequeuechannelredirect','erlangCallToSecond','lodash','stop','listen','Event\x20name\x20mandatory','outboundNoSuchCallsDay','filename','predictiveIntervalAvgTalktime','unmanaged','active','predictiveIntervalErlangCalls','exten','error','loggedIn','total'];(function(_0x136f85,_0x2ea604){const _0x5a677b=function(_0x23dcca){while(--_0x23dcca){_0x136f85['push'](_0x136f85['shift']());}};_0x5a677b(++_0x2ea604);}(a1133_0x2ea6,0xe2));const a1133_0x5a67=function(_0x136f85,_0x2ea604){_0x136f85=_0x136f85-0x0;let _0x5a677b=a1133_0x2ea6[_0x136f85];return _0x5a677b;};const _0x63a85c=a1133_0x5a67;'use strict';const _=require(_0x63a85c('0x16')),util=require('util'),jayson=require(_0x63a85c('0x3d')),schema=require('validate'),moment=require('moment'),config=require(_0x63a85c('0x30')),properties=require(_0x63a85c('0x24')),ami=require(_0x63a85c('0x76'));exports[_0x63a85c('0x18')]=function(_0x23dcca,_0x1ae173,_0x43aaf5){return new Promise(function(_0xff15fd,_0x449b79){const _0x433c50=a1133_0x5a67,_0x3f57ae={'QueuePause':function(_0xd9cad0){return new Promise(function(_0x1f7d6d){const _0x232479=a1133_0x5a67,_0x39a2a0=util[_0x232479('0x68')]('%s/%s','SIP',_0xd9cad0[_0x232479('0x58')]);_0x23dcca[_0x232479('0x49')]&&_0x23dcca['timers'][_0x39a2a0]&&_0x23dcca[_0x232479('0x49')][_0x39a2a0][_0x232479('0x2f')]&&_0x23dcca['timers'][_0x39a2a0]['updateAcw'](),_0x23dcca[_0x232479('0x56')][_0x39a2a0]&&_0x23dcca['agents'][_0x39a2a0]['updateStatusRealtime']({'statePause':_0xd9cad0['pause']?!![]:![]}),_0x1f7d6d({'code':0xc8,'message':_0x232479('0x73')});});},'Reload':function(_0x13f25f){const _0x14cf8d=this;return new Promise(function(_0x56622b,_0x454499){const _0x2f4d4d=a1133_0x5a67;if(ami['isConnected']()==![])return _0x454499(_0x14cf8d['error'](0x1f4,[config[_0x2f4d4d('0x64')]['ip'],config[_0x2f4d4d('0x64')][_0x2f4d4d('0x35')],_0x2f4d4d('0x60')]['join']('\x20')));return _0x13f25f=_[_0x2f4d4d('0x7')](_0x13f25f,_[_0x2f4d4d('0x4e')](properties[_0x2f4d4d('0x37')])),_0x13f25f[_0x2f4d4d('0x7e')]=_0x2f4d4d('0x4'),ami[_0x2f4d4d('0xe')](_0x13f25f)[_0x2f4d4d('0x69')](function(_0x21e7b8){const _0x37c94c=_0x2f4d4d;_0x56622b({'code':0xc8,'message':_0x21e7b8[_0x37c94c('0x26')]});})[_0x2f4d4d('0x4d')](function(_0x261936){const _0x48b3d5=_0x2f4d4d;_0x454499(_0x14cf8d[_0x48b3d5('0x21')](0x1f5,_0x261936[_0x48b3d5('0x26')]));});});},'Command':function(_0x1d03d7){const _0x1049e1=this;return new Promise(function(_0x184738,_0x1d364c){const _0x3646e3=a1133_0x5a67;if(ami[_0x3646e3('0x81')]()==![])return _0x1d364c(_0x1049e1['error'](0x1f4,[config['asterisk']['ip'],config[_0x3646e3('0x64')][_0x3646e3('0x35')],'ami\x20disconnected'][_0x3646e3('0x6e')]('\x20')));return _0x1d03d7=_[_0x3646e3('0x7')](_0x1d03d7,_0x3646e3('0x43')),_0x1d03d7[_0x3646e3('0x7e')]=_0x3646e3('0x6c'),ami[_0x3646e3('0xe')](_0x1d03d7)[_0x3646e3('0x69')](function(_0x3f4e65){const _0x5d7c3e=_0x3646e3;_0x184738({'code':0xc8,'message':_0x3f4e65[_0x5d7c3e('0x3')]});})[_0x3646e3('0x4d')](function(_0x1c8a1b){const _0x31398d=_0x3646e3;_0x1d364c(_0x1049e1[_0x31398d('0x21')](0x1f5,_0x1c8a1b['message']));});});},'VoiceQueues':function(){return new Promise(function(_0x542240){const _0x2078c4=a1133_0x5a67,_0x3b1e1f=[];for(const _0x1bd43a in _0x23dcca[_0x2078c4('0x33')]){if(typeof _0x23dcca[_0x2078c4('0x33')][_0x1bd43a]!=='undefined'){const _0x43a591=_0x23dcca[_0x2078c4('0x33')][_0x1bd43a],_0x518ad3={'id':_0x43a591['id'],'name':_0x43a591[_0x2078c4('0x58')],'strategy':_0x43a591[_0x2078c4('0x78')],'answered':_0x43a591[_0x2078c4('0x2c')],'available':_0x43a591[_0x2078c4('0x34')],'loggedIn':_0x43a591[_0x2078c4('0x22')],'pTalking':_0x43a591[_0x2078c4('0x40')],'sumBillable':_0x43a591[_0x2078c4('0x51')],'sumDuration':_0x43a591[_0x2078c4('0x7c')],'sumHoldTime':_0x43a591[_0x2078c4('0x4c')]||0x0,'talking':_0x43a591[_0x2078c4('0x3e')],'total':_0x43a591[_0x2078c4('0x23')],'type':_0x43a591['type'],'unmanaged':_0x43a591[_0x2078c4('0x1d')],'abandoned':_0x43a591[_0x2078c4('0xa')],'waiting':_0x43a591[_0x2078c4('0x5')],'loggedInDb':_0x43a591['loggedInDb']};_0x43a591[_0x2078c4('0x3f')]===_0x2078c4('0x2d')&&(_0x518ad3[_0x2078c4('0x79')]=_0x43a591['dialActive'],_0x518ad3[_0x2078c4('0xf')]=_0x43a591[_0x2078c4('0xf')],_0x518ad3[_0x2078c4('0x2')]=_0x43a591[_0x2078c4('0x2')],_0x518ad3['dialOriginateCallerIdNumber']=_0x43a591[_0x2078c4('0x57')],_0x518ad3[_0x2078c4('0x66')]=_0x43a591[_0x2078c4('0x66')],_0x518ad3[_0x2078c4('0x5f')]=_0x43a591[_0x2078c4('0x5f')],_0x518ad3[_0x2078c4('0xd')]=_0x43a591['outboundAnswerAgiCallsDay'],_0x518ad3[_0x2078c4('0x5c')]=_0x43a591[_0x2078c4('0x5c')],_0x518ad3[_0x2078c4('0x75')]=_0x43a591[_0x2078c4('0x75')],_0x518ad3[_0x2078c4('0x39')]=_0x43a591[_0x2078c4('0x39')],_0x518ad3[_0x2078c4('0x38')]=_0x43a591[_0x2078c4('0x38')],_0x518ad3[_0x2078c4('0x4b')]=_0x43a591[_0x2078c4('0x4b')],_0x518ad3['outboundDropCallsDayCallersExit']=_0x43a591['outboundDropCallsDayCallersExit'],_0x518ad3['outboundDropCallsDayTimeout']=_0x43a591['outboundDropCallsDayTimeout'],_0x518ad3[_0x2078c4('0x54')]=_0x43a591[_0x2078c4('0x54')],_0x518ad3[_0x2078c4('0x1a')]=_0x43a591[_0x2078c4('0x1a')],_0x518ad3['outboundOriginateFailureCallsDay']=_0x43a591[_0x2078c4('0x80')],_0x518ad3[_0x2078c4('0x7f')]=_0x43a591['outboundReCallsDay'],_0x518ad3[_0x2078c4('0x4f')]=_0x43a591['outboundRejectCallsDay'],_0x518ad3['outboundUnknownCallsDay']=_0x43a591['outboundUnknownCallsDay'],_0x518ad3['predictiveIntervalAnsweredCalls']=_0x43a591[_0x2078c4('0x28')],_0x518ad3[_0x2078c4('0x62')]=_0x43a591['predictiveIntervalAvgHoldtime'],_0x518ad3[_0x2078c4('0x1c')]=_0x43a591[_0x2078c4('0x1c')],_0x518ad3[_0x2078c4('0x45')]=_0x43a591[_0x2078c4('0x45')],_0x518ad3[_0x2078c4('0x50')]=_0x43a591[_0x2078c4('0x50')],_0x518ad3['predictiveIntervalErlangCalls']=_0x43a591[_0x2078c4('0x1f')],_0x518ad3[_0x2078c4('0x5d')]=_0x43a591[_0x2078c4('0x5d')],_0x518ad3[_0x2078c4('0x9')]=_0x43a591[_0x2078c4('0x9')],_0x518ad3[_0x2078c4('0x7b')]=_0x43a591[_0x2078c4('0x7b')],_0x518ad3['predictiveIntervalPauses']=_0x43a591[_0x2078c4('0x46')],_0x518ad3[_0x2078c4('0x2e')]=_0x43a591[_0x2078c4('0x2e')],_0x518ad3['predictiveIntervalTotalCalls']=_0x43a591[_0x2078c4('0x27')],_0x518ad3[_0x2078c4('0x26')]=_0x43a591[_0x2078c4('0x26')],_0x518ad3[_0x2078c4('0x52')]=_0x43a591[_0x2078c4('0x52')],_0x518ad3[_0x2078c4('0x59')]=_0x43a591[_0x2078c4('0x59')],_0x518ad3['erlangCallToSecond']=_0x43a591[_0x2078c4('0x15')],_0x518ad3[_0x2078c4('0x36')]=_0x43a591[_0x2078c4('0x36')],_0x518ad3[_0x2078c4('0xc')]=_0x43a591[_0x2078c4('0xc')],_0x518ad3['startPredictive']=_0x43a591['startPredictive'],_0x518ad3[_0x2078c4('0x44')]=_0x43a591[_0x2078c4('0x44')]),_0x43a591[_0x2078c4('0x67')]&&(_0x518ad3[_0x2078c4('0x67')]={'id':_0x43a591[_0x2078c4('0x67')]['id'],'name':_0x43a591['Trunk'][_0x2078c4('0x58')],'active':_0x43a591['Trunk'][_0x2078c4('0x1e')],'callerid':_0x43a591[_0x2078c4('0x67')][_0x2078c4('0x6d')]}),_0x43a591[_0x2078c4('0x3c')]&&(_0x518ad3[_0x2078c4('0x3c')]={'id':_0x43a591[_0x2078c4('0x3c')]['id'],'name':_0x43a591[_0x2078c4('0x3c')][_0x2078c4('0x58')]}),_0x3b1e1f['push'](_0x518ad3);}}_0x542240({'count':_0x3b1e1f[_0x2078c4('0x2b')],'rows':_0x3b1e1f});});},'VoiceChannels':function(){return new Promise(function(_0x361313){const _0x5bc85a=a1133_0x5a67,_0x356aa0=_['values'](_0x23dcca[_0x5bc85a('0x29')]);_0x361313({'count':_0x356aa0['length'],'rows':_0x356aa0});});},'VoiceChannelMixMonitor':function(_0x47bd8a){const _0x998e94=this;return new Promise(function(_0x42bb2b,_0x1fe717){const _0xe49cd6=a1133_0x5a67;if(ami[_0xe49cd6('0x81')]()==![])return _0x1fe717(_0x998e94[_0xe49cd6('0x21')](0x1f4,[config[_0xe49cd6('0x64')]['ip'],config[_0xe49cd6('0x64')][_0xe49cd6('0x35')],_0xe49cd6('0x60')][_0xe49cd6('0x6e')]('\x20')));const _0x4d3ba2=schema(properties[_0xe49cd6('0x48')])[_0xe49cd6('0x32')](_0x47bd8a);if(_0x4d3ba2[_0xe49cd6('0x2b')]>0x0)return _0x1fe717(_0x998e94['error'](0x1f4,_[_0xe49cd6('0x5e')](_0x4d3ba2,_0xe49cd6('0x26'))[_0xe49cd6('0x6e')](',\x20')));const _0x235484=_[_0xe49cd6('0x5b')](_0x23dcca['channels'],{'uniqueid':_0x47bd8a['uniqueid']});if(_0x235484&&_0x235484[_0xe49cd6('0x0')]){const _0x4019c6=util['format'](_0xe49cd6('0x63'),_0x47bd8a[_0xe49cd6('0x1b')]||_0x47bd8a[_0xe49cd6('0x3b')],_0x47bd8a[_0xe49cd6('0x68')]||_0xe49cd6('0x65'));return ami[_0xe49cd6('0xe')]({'action':'MixMonitor','channel':_0x235484[_0xe49cd6('0x0')],'file':_0x4019c6,'options':_0xe49cd6('0x70')})[_0xe49cd6('0x69')](function(_0x54049b){const _0x204c3b=_0xe49cd6,_0x428489=_['find'](_0x235484['monitors'],{'filename':_0x204c3b('0x1')+_0x4019c6['toLowerCase']()});_[_0x204c3b('0x6a')](_0x428489)?_0x235484['monitors'][_0x204c3b('0xb')]({'filename':_0x204c3b('0x1')+_0x4019c6[_0x204c3b('0x8')](),'createdAt':moment()[_0x204c3b('0x68')](_0x204c3b('0x13')),'mixmonitorid':_0x54049b[_0x204c3b('0x6')],'status':_0x204c3b('0x47')}):(_0x428489[_0x204c3b('0x6')]=_0x54049b['mixmonitorid'],_0x428489[_0x204c3b('0x74')]=_0x204c3b('0x47')),_0x42bb2b({'code':0xc8,'message':[_0x47bd8a[_0x204c3b('0x3b')],_0x204c3b('0x4a'),_0x54049b[_0x204c3b('0x6')]][_0x204c3b('0x6e')]('\x20'),'mixmonitorid':_0x54049b['mixmonitorid']});})[_0xe49cd6('0x4d')](function(_0x5eada8){const _0x1e8b7f=_0xe49cd6;_0x1fe717(_0x998e94[_0x1e8b7f('0x21')](0x1f5,[_0x47bd8a[_0x1e8b7f('0x3b')],_0x5eada8[_0x1e8b7f('0x26')][_0x1e8b7f('0x8')]()][_0x1e8b7f('0x6e')]('\x20')));});}else return _0x1fe717(_0x998e94['error'](0x1f5,'Channel\x20doesn\x27t\x20exist'));});},'VoiceChannelStopMixMonitor':function(_0x11c968){const _0x177088=this;return new Promise(function(_0x402b27,_0x884601){const _0x225d04=a1133_0x5a67;if(ami['isConnected']()==![])return _0x884601(_0x177088['error'](0x1f4,[config[_0x225d04('0x64')]['ip'],config[_0x225d04('0x64')][_0x225d04('0x35')],_0x225d04('0x60')][_0x225d04('0x6e')]('\x20')));const _0x3288db=schema(properties[_0x225d04('0x48')])['validate'](_0x11c968);if(_0x3288db['length']>0x0)return _0x884601(_0x177088[_0x225d04('0x21')](0x1f4,_[_0x225d04('0x5e')](_0x3288db,_0x225d04('0x26'))['join'](',\x20')));const _0x445c05=_[_0x225d04('0x5b')](_0x23dcca[_0x225d04('0x29')],{'uniqueid':_0x11c968[_0x225d04('0x3b')]});return _0x445c05?Promise['resolve']()[_0x225d04('0x69')](function(){const _0x2a1a2d=_0x225d04;if(_0x445c05['channel'])return ami['Action']({'action':_0x2a1a2d('0x72'),'channel':_0x445c05['channel'],'mixmonitorid':_0x11c968[_0x2a1a2d('0x6')]})[_0x2a1a2d('0x4d')](function(){});})['then'](function(){const _0x181b00=_0x225d04;if(_0x445c05['destinationchannel'])return ami[_0x181b00('0xe')]({'action':_0x181b00('0x72'),'channel':_0x445c05[_0x181b00('0x5a')],'mixmonitorid':_0x11c968[_0x181b00('0x6')]})[_0x181b00('0x4d')](function(){});})[_0x225d04('0x69')](function(){const _0x42da93=_0x225d04,_0x2c1917=_[_0x42da93('0x5b')](_0x445c05[_0x42da93('0x11')],{'mixmonitorid':_0x11c968['mixmonitorid']});_0x2c1917&&(_0x2c1917[_0x42da93('0x74')]='stop');})['then'](function(){const _0x242133=_0x225d04,_0x27cd70=util['format'](_0x242133('0x63'),_0x11c968[_0x242133('0x1b')]||_0x11c968['uniqueid'],_0x11c968[_0x242133('0x68')]||_0x242133('0x65')),_0x4ea25a=_[_0x242133('0x5b')](_0x445c05[_0x242133('0x11')],{'filename':_0x242133('0x1')+_0x27cd70[_0x242133('0x8')]()});_0x4ea25a&&(_0x4ea25a[_0x242133('0x74')]=_0x242133('0x17'));})[_0x225d04('0x69')](function(){const _0xde467e=_0x225d04;_0x402b27({'code':0xc8,'message':[_0x11c968[_0xde467e('0x3b')],_0xde467e('0x53')]['join']('\x20')});})[_0x225d04('0x4d')](function(_0xd3f7){const _0x423e38=_0x225d04;_0x884601(_0x177088[_0x423e38('0x21')](0x1f5,[_0x11c968[_0x423e38('0x3b')],_0xd3f7[_0x423e38('0x26')]['toLowerCase']()][_0x423e38('0x6e')]('\x20')));}):_0x884601(_0x177088[_0x225d04('0x21')](0x1f5,_0x225d04('0x77')));});},'VoiceQueuesChannels':function(){return new Promise(function(_0x77b162){const _0x5384ea=a1133_0x5a67,_0x37047c=_['values'](_0x23dcca[_0x5384ea('0x71')]);_0x77b162({'count':_0x37047c[_0x5384ea('0x2b')],'rows':_0x37047c});});},'VoiceQueuesChannel':function(_0x32a778){const _0x265b30=this;return new Promise(function(_0x45ccd9,_0x2f9604){const _0x3ae846=a1133_0x5a67,_0x1fa41a=schema(properties[_0x3ae846('0x41')])[_0x3ae846('0x32')](_0x32a778);if(_0x1fa41a['length']>0x0)return _0x2f9604(_0x265b30['error'](0x1f4,_[_0x3ae846('0x5e')](_0x1fa41a,_0x3ae846('0x26'))[_0x3ae846('0x6e')](',\x20')));const _0x4d9216=_['find'](_0x23dcca['queueChannels'],{'uniqueid':_0x32a778['uniqueid']});if(_0x4d9216)_0x45ccd9(_0x4d9216);else return _0x2f9604(_0x265b30[_0x3ae846('0x21')](0x1f5,_0x3ae846('0x77')));});},'VoiceQueuesChannelHangup':function(_0xf12687){const _0x3deb03=this;return new Promise(function(_0x44aec1,_0x577df3){const _0x22a6de=a1133_0x5a67;if(ami[_0x22a6de('0x81')]()==![])return _0x577df3(_0x3deb03[_0x22a6de('0x21')](0x1f4,[config[_0x22a6de('0x64')]['ip'],config[_0x22a6de('0x64')][_0x22a6de('0x35')],_0x22a6de('0x60')][_0x22a6de('0x6e')]('\x20')));const _0x69a145=schema(properties[_0x22a6de('0x2a')])['validate'](_0xf12687);if(_0x69a145[_0x22a6de('0x2b')]>0x0)return _0x577df3(_0x3deb03['error'](0x1f4,_[_0x22a6de('0x5e')](_0x69a145,_0x22a6de('0x26'))[_0x22a6de('0x6e')](',\x20')));const _0x3c5edd=_[_0x22a6de('0x5b')](_0x23dcca['queueChannels'],{'uniqueid':_0xf12687[_0x22a6de('0x3b')]});return _0x3c5edd&&_0x3c5edd[_0x22a6de('0x0')]?ami[_0x22a6de('0xe')]({'action':'Hangup','channel':_0x3c5edd['channel']})[_0x22a6de('0x69')](function(_0x3fd50a){const _0x1d25e4=_0x22a6de;_0x44aec1({'code':0xc8,'message':[_0xf12687[_0x1d25e4('0x3b')],_0x3fd50a['message']['toLowerCase']()][_0x1d25e4('0x6e')]('\x20')});})[_0x22a6de('0x4d')](function(_0x475b49){const _0x459396=_0x22a6de;_0x577df3(_0x3deb03['error'](0x1f5,[_0xf12687[_0x459396('0x3b')],_0x475b49['message'][_0x459396('0x8')]()][_0x459396('0x6e')]('\x20')));}):_0x577df3(_0x3deb03[_0x22a6de('0x21')](0x1f5,'Channel\x20doesn\x27t\x20exist'));});},'VoiceQueuesChannelRedirect':function(_0x54074d){const _0x519ad4=this;return new Promise(function(_0x466306,_0x42a3b0){const _0x3bd354=a1133_0x5a67;if(ami[_0x3bd354('0x81')]()==![])return _0x42a3b0(_0x519ad4[_0x3bd354('0x21')](0x1f4,[config[_0x3bd354('0x64')]['ip'],config[_0x3bd354('0x64')]['username'],_0x3bd354('0x60')][_0x3bd354('0x6e')]('\x20')));const _0x1699cf=schema(properties[_0x3bd354('0x14')])[_0x3bd354('0x32')](_0x54074d);if(_0x1699cf['length']>0x0)return _0x42a3b0(_0x519ad4[_0x3bd354('0x21')](0x1f4,_[_0x3bd354('0x5e')](_0x1699cf,_0x3bd354('0x26'))[_0x3bd354('0x6e')](',\x20')));const _0x50c096=_[_0x3bd354('0x5b')](_0x23dcca[_0x3bd354('0x71')],{'uniqueid':_0x54074d['uniqueid']});return _0x50c096&&_0x50c096[_0x3bd354('0x0')]?ami[_0x3bd354('0xe')]({'action':_0x3bd354('0x61'),'channel':_0x50c096[_0x3bd354('0x0')],'exten':_0x54074d[_0x3bd354('0x20')],'context':_0x54074d['context']||_0x50c096[_0x3bd354('0x6b')],'priority':0x1})[_0x3bd354('0x69')](function(_0x2e48ca){const _0xbc64d0=_0x3bd354;_0x466306({'code':0xc8,'message':[_0x54074d['uniqueid'],_0x2e48ca[_0xbc64d0('0x26')][_0xbc64d0('0x8')]()][_0xbc64d0('0x6e')]('\x20')});})[_0x3bd354('0x4d')](function(_0xec4748){const _0x54ce30=_0x3bd354;_0x42a3b0(_0x519ad4[_0x54ce30('0x21')](0x1f5,[_0x54074d['uniqueid'],_0xec4748[_0x54ce30('0x26')][_0x54ce30('0x8')]()][_0x54ce30('0x6e')]('\x20')));}):_0x42a3b0(_0x519ad4[_0x3bd354('0x21')](0x1f5,_0x3bd354('0x77')));});},'Agents':function(){return new Promise(function(_0x48b5c2){const _0x1ce5c=a1133_0x5a67,_0x493f85=_[_0x1ce5c('0x42')](_0x23dcca[_0x1ce5c('0x56')]);_0x48b5c2({'count':_0x493f85[_0x1ce5c('0x2b')],'rows':_0x493f85});});},'Telephones':function(){return new Promise(function(_0x459aba){const _0x2a0243=a1133_0x5a67,_0x5271ec=_[_0x2a0243('0x42')](_0x23dcca[_0x2a0243('0x6f')]);_0x459aba({'count':_0x5271ec[_0x2a0243('0x2b')],'rows':_0x5271ec});});},'Trunks':function(){return new Promise(function(_0x240574){const _0x2d8ee4=a1133_0x5a67,_0x23d995=_[_0x2d8ee4('0x42')](_0x23dcca[_0x2d8ee4('0x7d')]);_0x240574({'count':_0x23d995[_0x2d8ee4('0x2b')],'rows':_0x23d995});});},'OutboundChannels':function(){return new Promise(function(_0x10eafd){const _0x413abf=a1133_0x5a67,_0x161505=_[_0x413abf('0x42')](_0x23dcca[_0x413abf('0x31')]);_0x10eafd({'count':_0x161505[_0x413abf('0x2b')],'rows':_0x161505});});},'Outbound':function(){return new Promise(function(_0xc9add7){_0xc9add7(_0x23dcca['outbound']);});},'Campaigns':function(){return new Promise(function(_0x4c68c6){const _0x36bcec=a1133_0x5a67,_0xd9a817=_[_0x36bcec('0x42')](_0x23dcca['campaigns']);_0x4c68c6({'count':_0xd9a817[_0x36bcec('0x2b')],'rows':_0xd9a817});});},'VoiceQueuesPreview':function(_0x434f4d){const _0x473b4c=this;return new Promise(function(_0x3ad6bd,_0x4b3249){const _0x30c46a=a1133_0x5a67;_0x1ae173[_0x30c46a('0x7a')](_0x434f4d['id'])[_0x30c46a('0x69')](function(_0x3331f6){const _0x4ee2c0=_0x30c46a;_0x3ad6bd({'code':0xc8,'message':_0x3331f6[_0x4ee2c0('0x26')]});})[_0x30c46a('0x4d')](function(_0x1096a1){const _0x584327=_0x30c46a;_0x4b3249(_0x473b4c[_0x584327('0x21')](0x1f4,_0x1096a1['message']));});});},'EventManager':function(_0x41920b){const _0x2bfbe3=this;return new Promise(function(_0x50e883,_0x5852f2){const _0x284de8=a1133_0x5a67;if(!_0x41920b[_0x284de8('0x25')])return _0x5852f2(_0x2bfbe3[_0x284de8('0x21')](0x1f4,_0x284de8('0x19')));ami[_0x284de8('0x55')]('custom:'+_0x41920b[_0x284de8('0x25')],_0x41920b[_0x284de8('0x26')]),_0x50e883({'code':0xc8,'message':_0x41920b});});},'FaxAccounts':function(){return new Promise(function(_0x12d6b6){const _0x38db7a=_['values'](_0x23dcca['faxAccounts']);_0x12d6b6({'count':_0x38db7a['length'],'rows':_0x38db7a});});},'SendFax':function(_0x4cecba){const _0x4db185=this;return new Promise(function(_0x18f6e1,_0xc8bdb){_0x43aaf5['send'](_0x4cecba)['then'](function(_0x15a33a){const _0x4e68a5=a1133_0x5a67;_0x18f6e1({'code':0xc8,'message':_0x15a33a[_0x4e68a5('0x26')]});})['catch'](function(_0x65ce11){const _0x21853b=a1133_0x5a67;_0xc8bdb(_0x4db185[_0x21853b('0x21')](0x1f4,_0x65ce11[_0x21853b('0x26')]));});});},'CheckAfterSend':function(_0x1d016f){const _0x197ee6=this;return new Promise(function(_0x444e53,_0x354524){const _0x2df199=a1133_0x5a67;_0x43aaf5[_0x2df199('0x10')](_0x1d016f)[_0x2df199('0x69')](function(_0x1f711d){_0x444e53({'code':0xc8,'message':_0x1f711d['message']});})[_0x2df199('0x4d')](function(_0x51a839){const _0x3989ff=_0x2df199;_0x354524(_0x197ee6[_0x3989ff('0x21')](0x1f4,_0x51a839[_0x3989ff('0x26')]));});});}},_0x2f8dfa=jayson[_0x433c50('0x3a')](_0x3f57ae)[_0x433c50('0x82')]();_0x2f8dfa['on'](_0x433c50('0x21'),function(_0x3f396a){return _0x449b79(_0x3f396a);}),_0x2f8dfa[_0x433c50('0x18')](0x232a,_0x433c50('0x12'),function(){return console['log']('AMI\x20RPC\x20server\x20listening\x20on\x20127.0.0.1:%d!',0x232a),_0xff15fd('RPC\x20listening\x20on\x20port:'+0x232a);});});}; \ No newline at end of file +const a1133_0xae69=['MixMonitor','send','content','Action','/var/spool/asterisk/monitor/','QueuePause','outboundNoAnswerCallsDay','Trunk','channels','destinationchannel','dialActive','exten','timer','Hangup','active','predictiveIntervalDroppedCallsTimeout','voicequeuechannelredirect','outboundDropCallsDayTimeout','total','agents','event','queueChannels','action','../properties','campaigns','push','predictiveIntervalAvgTalktime','isConnected','rec','StopMixMonitor\x20Success','abandoned','%s.%s','ami\x20disconnected','resolve','predictiveIntervalAnsweredCalls','outbound','outboundAnswerAgiCallsDay','predictiveIntervalErlangCalls','updateAcw','lodash','channel','YYYY-MM-DD\x20HH:mm:ss','format','server','sumHoldTime','pause','../ami','predictiveIntervalPauses','status','faxAccounts','127.0.0.1','outboundNoSuchCallsDay','name','dialOriginateCallerIdName','outboundRejectCallsDay','timers','../../../config/environment','run','predictiveIntervalAvgHoldtime','dialPrefix','asterisk','originated','outboundCongestionCallsDay','erlangCallToSecond','AMI\x20RPC\x20server\x20listening\x20on\x20127.0.0.1:%d!','erlangCalls','jayson/promise','voicequeuechannelhangup','predictiveIntervalMultiplicativeFactor','dialOriginateTimeout','validate','Interval','voiceQueues','loggedIn','talking','log','toLowerCase','join','unmanaged','outboundBlacklistCallsDay','module','values','predictiveIntervalDroppedCallsCallersExit','type','catch','Event\x20name\x20mandatory','outboundBusyCallsDay','loggedInDb','erlangBusyFactor','length','outboundDropCallsDayACS','predictiveIntervalAvailable','answered','RPC\x20listening\x20on\x20port:','Redirect','dialMethod','emit','wav','checkAfterSend','startProgressive','message','undefined','outboundDropCallsDayCallersExit','outboundUnknownCallsDay','dialOriginateCallerIdNumber','sumDuration','Channel\x20doesn\x27t\x20exist','outboundReCallsDay','username','voicequeuechannel','erlangAbandonmentRate','telephones','voicechannel','strategy','http','isNil','custom:','outboundAnswerCallsDay','outboundOriginateFailureCallsDay','startPredictive','then','filename','outboundChannels','SIP','listen','waiting','mixmonitorid','uniqueid','context','pTalking','predictiveIntervalHitRate','callerid','stop','available','map','util','Command','monitors','error','find','trunks'];(function(_0xd98426,_0xae6922){const _0x15e7de=function(_0x171bb4){while(--_0x171bb4){_0xd98426['push'](_0xd98426['shift']());}};_0x15e7de(++_0xae6922);}(a1133_0xae69,0x83));const a1133_0x15e7=function(_0xd98426,_0xae6922){_0xd98426=_0xd98426-0x0;let _0x15e7de=a1133_0xae69[_0xd98426];return _0x15e7de;};const _0x1f0399=a1133_0x15e7;'use strict';const _=require(_0x1f0399('0x31')),util=require(_0x1f0399('0x4')),jayson=require(_0x1f0399('0x4c')),schema=require(_0x1f0399('0x50')),moment=require('moment'),config=require(_0x1f0399('0x42')),properties=require(_0x1f0399('0x21')),ami=require(_0x1f0399('0x38'));exports[_0x1f0399('0x86')]=function(_0x171bb4,_0x1ddef6,_0x5761a1){return new Promise(function(_0x45eda6,_0x17bcc3){const _0x4c3e0e=a1133_0x15e7,_0x12f72c={'QueuePause':function(_0x5518ed){return new Promise(function(_0x1c1a9b){const _0x4dd753=a1133_0x15e7,_0x12520b=util[_0x4dd753('0x34')]('%s/%s',_0x4dd753('0x85'),_0x5518ed['name']);_0x171bb4[_0x4dd753('0x41')]&&_0x171bb4[_0x4dd753('0x41')][_0x12520b]&&_0x171bb4[_0x4dd753('0x41')][_0x12520b][_0x4dd753('0x16')]&&_0x171bb4['timers'][_0x12520b][_0x4dd753('0x30')](),_0x171bb4[_0x4dd753('0x1d')][_0x12520b]&&_0x171bb4['agents'][_0x12520b]['updateStatusRealtime']({'statePause':_0x5518ed[_0x4dd753('0x37')]?!![]:![]}),_0x1c1a9b({'code':0xc8,'message':_0x4dd753('0xf')});});},'Reload':function(_0x24210a){const _0x2a601e=this;return new Promise(function(_0x144e3a,_0x5f664e){const _0x16493e=a1133_0x15e7;if(ami[_0x16493e('0x25')]()==![])return _0x5f664e(_0x2a601e['error'](0x1f4,[config[_0x16493e('0x46')]['ip'],config[_0x16493e('0x46')][_0x16493e('0x76')],'ami\x20disconnected'][_0x16493e('0x57')]('\x20')));return _0x24210a=_['pick'](_0x24210a,_['keys'](properties[_0x16493e('0x5a')])),_0x24210a[_0x16493e('0x20')]='Reload',ami[_0x16493e('0xd')](_0x24210a)[_0x16493e('0x82')](function(_0x373899){const _0x3cc524=_0x16493e;_0x144e3a({'code':0xc8,'message':_0x373899[_0x3cc524('0x6e')]});})[_0x16493e('0x5e')](function(_0x4c8427){const _0x476ca9=_0x16493e;_0x5f664e(_0x2a601e[_0x476ca9('0x7')](0x1f5,_0x4c8427[_0x476ca9('0x6e')]));});});},'Command':function(_0x2191fd){const _0x59b146=this;return new Promise(function(_0x321a4c,_0x536515){const _0x13a628=a1133_0x15e7;if(ami[_0x13a628('0x25')]()==![])return _0x536515(_0x59b146[_0x13a628('0x7')](0x1f4,[config[_0x13a628('0x46')]['ip'],config[_0x13a628('0x46')][_0x13a628('0x76')],_0x13a628('0x2a')][_0x13a628('0x57')]('\x20')));return _0x2191fd=_['pick'](_0x2191fd,'command'),_0x2191fd[_0x13a628('0x20')]=_0x13a628('0x5'),ami['Action'](_0x2191fd)[_0x13a628('0x82')](function(_0x25acc6){const _0x13521a=_0x13a628;_0x321a4c({'code':0xc8,'message':_0x25acc6[_0x13521a('0xc')]});})['catch'](function(_0x15efc8){const _0x571c38=_0x13a628;_0x536515(_0x59b146[_0x571c38('0x7')](0x1f5,_0x15efc8[_0x571c38('0x6e')]));});});},'VoiceQueues':function(){return new Promise(function(_0x660ac){const _0x174cde=a1133_0x15e7,_0x3e3682=[];for(const _0x2057d5 in _0x171bb4[_0x174cde('0x52')]){if(typeof _0x171bb4['voiceQueues'][_0x2057d5]!==_0x174cde('0x6f')){const _0x2e9f3e=_0x171bb4['voiceQueues'][_0x2057d5],_0x4bcb45={'id':_0x2e9f3e['id'],'name':_0x2e9f3e[_0x174cde('0x3e')],'strategy':_0x2e9f3e[_0x174cde('0x7b')],'answered':_0x2e9f3e[_0x174cde('0x66')],'available':_0x2e9f3e[_0x174cde('0x2')],'loggedIn':_0x2e9f3e[_0x174cde('0x53')],'pTalking':_0x2e9f3e[_0x174cde('0x8b')],'sumBillable':_0x2e9f3e['sumBillable'],'sumDuration':_0x2e9f3e[_0x174cde('0x73')],'sumHoldTime':_0x2e9f3e[_0x174cde('0x36')]||0x0,'talking':_0x2e9f3e[_0x174cde('0x54')],'total':_0x2e9f3e[_0x174cde('0x1c')],'type':_0x2e9f3e[_0x174cde('0x5d')],'unmanaged':_0x2e9f3e[_0x174cde('0x58')],'abandoned':_0x2e9f3e[_0x174cde('0x28')],'waiting':_0x2e9f3e[_0x174cde('0x87')],'loggedInDb':_0x2e9f3e[_0x174cde('0x61')]};_0x2e9f3e[_0x174cde('0x5d')]===_0x174cde('0x2d')&&(_0x4bcb45['dialActive']=_0x2e9f3e[_0x174cde('0x14')],_0x4bcb45[_0x174cde('0x69')]=_0x2e9f3e[_0x174cde('0x69')],_0x4bcb45[_0x174cde('0x3f')]=_0x2e9f3e[_0x174cde('0x3f')],_0x4bcb45[_0x174cde('0x72')]=_0x2e9f3e[_0x174cde('0x72')],_0x4bcb45['dialOriginateTimeout']=_0x2e9f3e[_0x174cde('0x4f')],_0x4bcb45[_0x174cde('0x45')]=_0x2e9f3e[_0x174cde('0x45')],_0x4bcb45[_0x174cde('0x2e')]=_0x2e9f3e[_0x174cde('0x2e')],_0x4bcb45[_0x174cde('0x7f')]=_0x2e9f3e[_0x174cde('0x7f')],_0x4bcb45[_0x174cde('0x59')]=_0x2e9f3e[_0x174cde('0x59')],_0x4bcb45[_0x174cde('0x60')]=_0x2e9f3e['outboundBusyCallsDay'],_0x4bcb45[_0x174cde('0x48')]=_0x2e9f3e[_0x174cde('0x48')],_0x4bcb45[_0x174cde('0x64')]=_0x2e9f3e[_0x174cde('0x64')],_0x4bcb45['outboundDropCallsDayCallersExit']=_0x2e9f3e[_0x174cde('0x70')],_0x4bcb45[_0x174cde('0x1b')]=_0x2e9f3e['outboundDropCallsDayTimeout'],_0x4bcb45[_0x174cde('0x10')]=_0x2e9f3e[_0x174cde('0x10')],_0x4bcb45['outboundNoSuchCallsDay']=_0x2e9f3e[_0x174cde('0x3d')],_0x4bcb45[_0x174cde('0x80')]=_0x2e9f3e[_0x174cde('0x80')],_0x4bcb45[_0x174cde('0x75')]=_0x2e9f3e['outboundReCallsDay'],_0x4bcb45['outboundRejectCallsDay']=_0x2e9f3e[_0x174cde('0x40')],_0x4bcb45[_0x174cde('0x71')]=_0x2e9f3e[_0x174cde('0x71')],_0x4bcb45[_0x174cde('0x2c')]=_0x2e9f3e[_0x174cde('0x2c')],_0x4bcb45[_0x174cde('0x44')]=_0x2e9f3e['predictiveIntervalAvgHoldtime'],_0x4bcb45['predictiveIntervalAvgTalktime']=_0x2e9f3e[_0x174cde('0x24')],_0x4bcb45[_0x174cde('0x5c')]=_0x2e9f3e[_0x174cde('0x5c')],_0x4bcb45['predictiveIntervalDroppedCallsTimeout']=_0x2e9f3e[_0x174cde('0x19')],_0x4bcb45['predictiveIntervalErlangCalls']=_0x2e9f3e[_0x174cde('0x2f')],_0x4bcb45['predictiveIntervalErlangCallsDroppedCalls']=_0x2e9f3e['predictiveIntervalErlangCallsDroppedCalls'],_0x4bcb45['predictiveIntervalHitRate']=_0x2e9f3e[_0x174cde('0x8c')],_0x4bcb45[_0x174cde('0x4e')]=_0x2e9f3e[_0x174cde('0x4e')],_0x4bcb45['predictiveIntervalPauses']=_0x2e9f3e[_0x174cde('0x39')],_0x4bcb45[_0x174cde('0x65')]=_0x2e9f3e['predictiveIntervalAvailable'],_0x4bcb45['predictiveIntervalTotalCalls']=_0x2e9f3e['predictiveIntervalTotalCalls'],_0x4bcb45['message']=_0x2e9f3e['message'],_0x4bcb45['originated']=_0x2e9f3e[_0x174cde('0x47')],_0x4bcb45[_0x174cde('0x4b')]=_0x2e9f3e[_0x174cde('0x4b')],_0x4bcb45['erlangCallToSecond']=_0x2e9f3e[_0x174cde('0x49')],_0x4bcb45['erlangAbandonmentRate']=_0x2e9f3e[_0x174cde('0x78')],_0x4bcb45[_0x174cde('0x62')]=_0x2e9f3e[_0x174cde('0x62')],_0x4bcb45[_0x174cde('0x81')]=_0x2e9f3e[_0x174cde('0x81')],_0x4bcb45[_0x174cde('0x6d')]=_0x2e9f3e[_0x174cde('0x6d')]),_0x2e9f3e[_0x174cde('0x11')]&&(_0x4bcb45['Trunk']={'id':_0x2e9f3e[_0x174cde('0x11')]['id'],'name':_0x2e9f3e['Trunk'][_0x174cde('0x3e')],'active':_0x2e9f3e[_0x174cde('0x11')][_0x174cde('0x18')],'callerid':_0x2e9f3e[_0x174cde('0x11')][_0x174cde('0x0')]}),_0x2e9f3e[_0x174cde('0x51')]&&(_0x4bcb45[_0x174cde('0x51')]={'id':_0x2e9f3e[_0x174cde('0x51')]['id'],'name':_0x2e9f3e['Interval'][_0x174cde('0x3e')]}),_0x3e3682[_0x174cde('0x23')](_0x4bcb45);}}_0x660ac({'count':_0x3e3682['length'],'rows':_0x3e3682});});},'VoiceChannels':function(){return new Promise(function(_0x2ef9a3){const _0x338241=a1133_0x15e7,_0x4cc379=_['values'](_0x171bb4[_0x338241('0x12')]);_0x2ef9a3({'count':_0x4cc379[_0x338241('0x63')],'rows':_0x4cc379});});},'VoiceChannelMixMonitor':function(_0x2a2037){const _0x5b90c7=this;return new Promise(function(_0x492745,_0x4e760a){const _0x3f35fc=a1133_0x15e7;if(ami[_0x3f35fc('0x25')]()==![])return _0x4e760a(_0x5b90c7[_0x3f35fc('0x7')](0x1f4,[config[_0x3f35fc('0x46')]['ip'],config[_0x3f35fc('0x46')]['username'],_0x3f35fc('0x2a')][_0x3f35fc('0x57')]('\x20')));const _0x46ea17=schema(properties['voicechannel'])[_0x3f35fc('0x50')](_0x2a2037);if(_0x46ea17['length']>0x0)return _0x4e760a(_0x5b90c7['error'](0x1f4,_[_0x3f35fc('0x3')](_0x46ea17,'message')[_0x3f35fc('0x57')](',\x20')));const _0x54bbb5=_[_0x3f35fc('0x8')](_0x171bb4['channels'],{'uniqueid':_0x2a2037['uniqueid']});if(_0x54bbb5&&_0x54bbb5['channel']){const _0x137ac8=util[_0x3f35fc('0x34')]('%s.%s',_0x2a2037[_0x3f35fc('0x83')]||_0x2a2037['uniqueid'],_0x2a2037[_0x3f35fc('0x34')]||_0x3f35fc('0x6b'));return ami['Action']({'action':_0x3f35fc('0xa'),'channel':_0x54bbb5['channel'],'file':_0x137ac8,'options':'ai(mixmonitorid)'})[_0x3f35fc('0x82')](function(_0x56475b){const _0x2d2c24=_0x3f35fc,_0xb8b1a4=_[_0x2d2c24('0x8')](_0x54bbb5[_0x2d2c24('0x6')],{'filename':'/var/spool/asterisk/monitor/'+_0x137ac8[_0x2d2c24('0x56')]()});_[_0x2d2c24('0x7d')](_0xb8b1a4)?_0x54bbb5[_0x2d2c24('0x6')][_0x2d2c24('0x23')]({'filename':'/var/spool/asterisk/monitor/'+_0x137ac8[_0x2d2c24('0x56')](),'createdAt':moment()[_0x2d2c24('0x34')](_0x2d2c24('0x33')),'mixmonitorid':_0x56475b[_0x2d2c24('0x88')],'status':_0x2d2c24('0x26')}):(_0xb8b1a4['mixmonitorid']=_0x56475b[_0x2d2c24('0x88')],_0xb8b1a4['status']=_0x2d2c24('0x26')),_0x492745({'code':0xc8,'message':[_0x2a2037[_0x2d2c24('0x89')],'MixMonitor\x20Success',_0x56475b[_0x2d2c24('0x88')]]['join']('\x20'),'mixmonitorid':_0x56475b[_0x2d2c24('0x88')]});})[_0x3f35fc('0x5e')](function(_0x36ad3c){const _0x48ede9=_0x3f35fc;_0x4e760a(_0x5b90c7['error'](0x1f5,[_0x2a2037[_0x48ede9('0x89')],_0x36ad3c[_0x48ede9('0x6e')]['toLowerCase']()]['join']('\x20')));});}else return _0x4e760a(_0x5b90c7['error'](0x1f5,'Channel\x20doesn\x27t\x20exist'));});},'VoiceChannelStopMixMonitor':function(_0x49014e){const _0x4f4f77=this;return new Promise(function(_0x50d5e7,_0x328566){const _0x39126a=a1133_0x15e7;if(ami[_0x39126a('0x25')]()==![])return _0x328566(_0x4f4f77[_0x39126a('0x7')](0x1f4,[config[_0x39126a('0x46')]['ip'],config['asterisk'][_0x39126a('0x76')],_0x39126a('0x2a')][_0x39126a('0x57')]('\x20')));const _0x417688=schema(properties[_0x39126a('0x7a')])[_0x39126a('0x50')](_0x49014e);if(_0x417688[_0x39126a('0x63')]>0x0)return _0x328566(_0x4f4f77[_0x39126a('0x7')](0x1f4,_[_0x39126a('0x3')](_0x417688,_0x39126a('0x6e'))[_0x39126a('0x57')](',\x20')));const _0xbc5304=_[_0x39126a('0x8')](_0x171bb4[_0x39126a('0x12')],{'uniqueid':_0x49014e['uniqueid']});return _0xbc5304?Promise[_0x39126a('0x2b')]()[_0x39126a('0x82')](function(){const _0x334eea=_0x39126a;if(_0xbc5304[_0x334eea('0x32')])return ami[_0x334eea('0xd')]({'action':'StopMixMonitor','channel':_0xbc5304[_0x334eea('0x32')],'mixmonitorid':_0x49014e[_0x334eea('0x88')]})[_0x334eea('0x5e')](function(){});})[_0x39126a('0x82')](function(){const _0x334a72=_0x39126a;if(_0xbc5304[_0x334a72('0x13')])return ami[_0x334a72('0xd')]({'action':'StopMixMonitor','channel':_0xbc5304[_0x334a72('0x13')],'mixmonitorid':_0x49014e['mixmonitorid']})[_0x334a72('0x5e')](function(){});})['then'](function(){const _0x5e8aba=_0x39126a,_0x3f96e7=_[_0x5e8aba('0x8')](_0xbc5304[_0x5e8aba('0x6')],{'mixmonitorid':_0x49014e[_0x5e8aba('0x88')]});_0x3f96e7&&(_0x3f96e7['status']=_0x5e8aba('0x1'));})[_0x39126a('0x82')](function(){const _0x47af06=_0x39126a,_0x1ba523=util['format'](_0x47af06('0x29'),_0x49014e[_0x47af06('0x83')]||_0x49014e['uniqueid'],_0x49014e[_0x47af06('0x34')]||_0x47af06('0x6b')),_0x550678=_['find'](_0xbc5304[_0x47af06('0x6')],{'filename':_0x47af06('0xe')+_0x1ba523[_0x47af06('0x56')]()});_0x550678&&(_0x550678[_0x47af06('0x3a')]=_0x47af06('0x1'));})[_0x39126a('0x82')](function(){const _0x4b7850=_0x39126a;_0x50d5e7({'code':0xc8,'message':[_0x49014e[_0x4b7850('0x89')],_0x4b7850('0x27')][_0x4b7850('0x57')]('\x20')});})[_0x39126a('0x5e')](function(_0x1d7bdc){const _0x11e234=_0x39126a;_0x328566(_0x4f4f77[_0x11e234('0x7')](0x1f5,[_0x49014e['uniqueid'],_0x1d7bdc[_0x11e234('0x6e')][_0x11e234('0x56')]()][_0x11e234('0x57')]('\x20')));}):_0x328566(_0x4f4f77[_0x39126a('0x7')](0x1f5,_0x39126a('0x74')));});},'VoiceQueuesChannels':function(){return new Promise(function(_0x511522){const _0x3ca7a7=a1133_0x15e7,_0x4d5707=_[_0x3ca7a7('0x5b')](_0x171bb4[_0x3ca7a7('0x1f')]);_0x511522({'count':_0x4d5707['length'],'rows':_0x4d5707});});},'VoiceQueuesChannel':function(_0x5cd71b){const _0xe47d57=this;return new Promise(function(_0x3be38f,_0x4b04b8){const _0x23a093=a1133_0x15e7,_0x42643f=schema(properties[_0x23a093('0x77')])[_0x23a093('0x50')](_0x5cd71b);if(_0x42643f['length']>0x0)return _0x4b04b8(_0xe47d57['error'](0x1f4,_[_0x23a093('0x3')](_0x42643f,_0x23a093('0x6e'))[_0x23a093('0x57')](',\x20')));const _0x2ba844=_[_0x23a093('0x8')](_0x171bb4[_0x23a093('0x1f')],{'uniqueid':_0x5cd71b[_0x23a093('0x89')]});if(_0x2ba844)_0x3be38f(_0x2ba844);else return _0x4b04b8(_0xe47d57['error'](0x1f5,_0x23a093('0x74')));});},'VoiceQueuesChannelHangup':function(_0x4a3354){const _0x40f4cf=this;return new Promise(function(_0x4d3e74,_0x163c0e){const _0x1615b4=a1133_0x15e7;if(ami[_0x1615b4('0x25')]()==![])return _0x163c0e(_0x40f4cf[_0x1615b4('0x7')](0x1f4,[config[_0x1615b4('0x46')]['ip'],config[_0x1615b4('0x46')]['username'],_0x1615b4('0x2a')][_0x1615b4('0x57')]('\x20')));const _0x487d8f=schema(properties[_0x1615b4('0x4d')])[_0x1615b4('0x50')](_0x4a3354);if(_0x487d8f[_0x1615b4('0x63')]>0x0)return _0x163c0e(_0x40f4cf['error'](0x1f4,_[_0x1615b4('0x3')](_0x487d8f,_0x1615b4('0x6e'))['join'](',\x20')));const _0x55bd2e=_[_0x1615b4('0x8')](_0x171bb4['queueChannels'],{'uniqueid':_0x4a3354[_0x1615b4('0x89')]});return _0x55bd2e&&_0x55bd2e[_0x1615b4('0x32')]?ami[_0x1615b4('0xd')]({'action':_0x1615b4('0x17'),'channel':_0x55bd2e['channel']})[_0x1615b4('0x82')](function(_0x56d66d){const _0x2cb247=_0x1615b4;_0x4d3e74({'code':0xc8,'message':[_0x4a3354[_0x2cb247('0x89')],_0x56d66d['message'][_0x2cb247('0x56')]()][_0x2cb247('0x57')]('\x20')});})['catch'](function(_0x2c4d3c){const _0x32080b=_0x1615b4;_0x163c0e(_0x40f4cf[_0x32080b('0x7')](0x1f5,[_0x4a3354[_0x32080b('0x89')],_0x2c4d3c[_0x32080b('0x6e')][_0x32080b('0x56')]()]['join']('\x20')));}):_0x163c0e(_0x40f4cf[_0x1615b4('0x7')](0x1f5,_0x1615b4('0x74')));});},'VoiceQueuesChannelRedirect':function(_0x1c0aec){const _0x4d39fe=this;return new Promise(function(_0x328aa4,_0x3ba3d3){const _0x590875=a1133_0x15e7;if(ami[_0x590875('0x25')]()==![])return _0x3ba3d3(_0x4d39fe[_0x590875('0x7')](0x1f4,[config[_0x590875('0x46')]['ip'],config[_0x590875('0x46')][_0x590875('0x76')],_0x590875('0x2a')][_0x590875('0x57')]('\x20')));const _0x6c97a7=schema(properties[_0x590875('0x1a')])['validate'](_0x1c0aec);if(_0x6c97a7[_0x590875('0x63')]>0x0)return _0x3ba3d3(_0x4d39fe[_0x590875('0x7')](0x1f4,_[_0x590875('0x3')](_0x6c97a7,'message')[_0x590875('0x57')](',\x20')));const _0x19ccf5=_[_0x590875('0x8')](_0x171bb4[_0x590875('0x1f')],{'uniqueid':_0x1c0aec[_0x590875('0x89')]});return _0x19ccf5&&_0x19ccf5[_0x590875('0x32')]?ami['Action']({'action':_0x590875('0x68'),'channel':_0x19ccf5['channel'],'exten':_0x1c0aec[_0x590875('0x15')],'context':_0x1c0aec[_0x590875('0x8a')]||_0x19ccf5[_0x590875('0x8a')],'priority':0x1})[_0x590875('0x82')](function(_0xb71173){const _0x564e7b=_0x590875;_0x328aa4({'code':0xc8,'message':[_0x1c0aec[_0x564e7b('0x89')],_0xb71173[_0x564e7b('0x6e')][_0x564e7b('0x56')]()][_0x564e7b('0x57')]('\x20')});})[_0x590875('0x5e')](function(_0x3bafe1){const _0x564b96=_0x590875;_0x3ba3d3(_0x4d39fe['error'](0x1f5,[_0x1c0aec[_0x564b96('0x89')],_0x3bafe1[_0x564b96('0x6e')][_0x564b96('0x56')]()]['join']('\x20')));}):_0x3ba3d3(_0x4d39fe[_0x590875('0x7')](0x1f5,'Channel\x20doesn\x27t\x20exist'));});},'Agents':function(){return new Promise(function(_0x3e3634){const _0x20b196=a1133_0x15e7,_0xb1fa6b=_[_0x20b196('0x5b')](_0x171bb4[_0x20b196('0x1d')]);_0x3e3634({'count':_0xb1fa6b[_0x20b196('0x63')],'rows':_0xb1fa6b});});},'Telephones':function(){return new Promise(function(_0x40e90b){const _0x9689f0=a1133_0x15e7,_0x4722ed=_[_0x9689f0('0x5b')](_0x171bb4[_0x9689f0('0x79')]);_0x40e90b({'count':_0x4722ed['length'],'rows':_0x4722ed});});},'Trunks':function(){return new Promise(function(_0x22384f){const _0x1a4d43=a1133_0x15e7,_0x24529b=_[_0x1a4d43('0x5b')](_0x171bb4[_0x1a4d43('0x9')]);_0x22384f({'count':_0x24529b['length'],'rows':_0x24529b});});},'OutboundChannels':function(){return new Promise(function(_0x3dfafa){const _0x5de934=a1133_0x15e7,_0x55f6c6=_[_0x5de934('0x5b')](_0x171bb4[_0x5de934('0x84')]);_0x3dfafa({'count':_0x55f6c6['length'],'rows':_0x55f6c6});});},'Outbound':function(){return new Promise(function(_0x4f776a){_0x4f776a(_0x171bb4['outbound']);});},'Campaigns':function(){return new Promise(function(_0x298030){const _0xc3a935=a1133_0x15e7,_0x7eee7c=_['values'](_0x171bb4[_0xc3a935('0x22')]);_0x298030({'count':_0x7eee7c[_0xc3a935('0x63')],'rows':_0x7eee7c});});},'VoiceQueuesPreview':function(_0xd72e03){const _0xd239cf=this;return new Promise(function(_0x48d15a,_0xb3b1e1){const _0x50be11=a1133_0x15e7;_0x1ddef6[_0x50be11('0x43')](_0xd72e03['id'])['then'](function(_0x46fabd){_0x48d15a({'code':0xc8,'message':_0x46fabd['message']});})[_0x50be11('0x5e')](function(_0x4a19a3){const _0x3c413f=_0x50be11;_0xb3b1e1(_0xd239cf[_0x3c413f('0x7')](0x1f4,_0x4a19a3[_0x3c413f('0x6e')]));});});},'EventManager':function(_0x2e22b1){const _0x3ac03d=this;return new Promise(function(_0x5ca99b,_0x27cab0){const _0x22f68b=a1133_0x15e7;if(!_0x2e22b1['event'])return _0x27cab0(_0x3ac03d[_0x22f68b('0x7')](0x1f4,_0x22f68b('0x5f')));ami[_0x22f68b('0x6a')](_0x22f68b('0x7e')+_0x2e22b1[_0x22f68b('0x1e')],_0x2e22b1[_0x22f68b('0x6e')]),_0x5ca99b({'code':0xc8,'message':_0x2e22b1});});},'FaxAccounts':function(){return new Promise(function(_0x2c4c07){const _0x3aafae=a1133_0x15e7,_0x16c096=_[_0x3aafae('0x5b')](_0x171bb4[_0x3aafae('0x3b')]);_0x2c4c07({'count':_0x16c096[_0x3aafae('0x63')],'rows':_0x16c096});});},'SendFax':function(_0x26863a){const _0x56310f=this;return new Promise(function(_0x3fcdc6,_0x156770){const _0x5e1910=a1133_0x15e7;_0x5761a1[_0x5e1910('0xb')](_0x26863a)[_0x5e1910('0x82')](function(_0x3ed623){const _0xf33c75=_0x5e1910;_0x3fcdc6({'code':0xc8,'message':_0x3ed623[_0xf33c75('0x6e')]});})[_0x5e1910('0x5e')](function(_0x3d87df){const _0x2f628e=_0x5e1910;_0x156770(_0x56310f[_0x2f628e('0x7')](0x1f4,_0x3d87df[_0x2f628e('0x6e')]));});});},'CheckAfterSend':function(_0x3817a8){const _0x4be9e9=this;return new Promise(function(_0x3e42e4,_0x507b47){const _0x32dab6=a1133_0x15e7;_0x5761a1[_0x32dab6('0x6c')](_0x3817a8)['then'](function(_0x23eb29){const _0x5581ce=_0x32dab6;_0x3e42e4({'code':0xc8,'message':_0x23eb29[_0x5581ce('0x6e')]});})['catch'](function(_0xa55251){const _0x1531aa=_0x32dab6;_0x507b47(_0x4be9e9[_0x1531aa('0x7')](0x1f4,_0xa55251[_0x1531aa('0x6e')]));});});}},_0xc012d8=jayson[_0x4c3e0e('0x35')](_0x12f72c)[_0x4c3e0e('0x7c')]();_0xc012d8['on'](_0x4c3e0e('0x7'),function(_0x50021d){return _0x17bcc3(_0x50021d);}),_0xc012d8['listen'](0x232a,_0x4c3e0e('0x3c'),function(){const _0x598bfd=_0x4c3e0e;return console[_0x598bfd('0x55')](_0x598bfd('0x4a'),0x232a),_0x45eda6(_0x598bfd('0x67')+0x232a);});});}; \ No newline at end of file diff --git a/server/services/ami/trigger/cmContact/index.js b/server/services/ami/trigger/cmContact/index.js index f45f642..82e39d8 100644 --- a/server/services/ami/trigger/cmContact/index.js +++ b/server/services/ami/trigger/cmContact/index.js @@ -1 +1 @@ -const a1134_0x54c8=['isNil','createdAt','Unknown','phone','merge','info','format','mobile','name','updatedAt','calleridnum','map','[CM][%s][%s]\x20Contact\x20created:%s','createContact','data4','stringify','then','[CM][%s][%s]\x20Contact\x20not\x20found','lastName','lodash','toLowerCase','../../../../rediscache','ListId','join','routeId','data2','','../../rpc/cmContact','action','getContacts','trigger','fax','resolve','isEmpty','uniqueid','[CM][%s][%s]\x20Multiple\x20contacts\x20found:[%s]','calleridname','xmd-contactid2','firstName','destcalleridnum','../../../../config/logger','data3','destcalleridname'];(function(_0x7b7a7a,_0x54c880){const _0x4c3bde=function(_0x325963){while(--_0x325963){_0x7b7a7a['push'](_0x7b7a7a['shift']());}};_0x4c3bde(++_0x54c880);}(a1134_0x54c8,0xc0));const a1134_0x4c3b=function(_0x7b7a7a,_0x54c880){_0x7b7a7a=_0x7b7a7a-0x0;let _0x4c3bde=a1134_0x54c8[_0x7b7a7a];return _0x4c3bde;};const _0x3da4a5=a1134_0x4c3b;'use strict';const util=require('util'),_=require(_0x3da4a5('0x2a')),logger=require(_0x3da4a5('0x14'))(_0x3da4a5('0xa')),cmContactRpc=require(_0x3da4a5('0x7')),{Op}=require('sequelize'),{getSocket}=require(_0x3da4a5('0x1')),io=getSocket();function emit(_0x325963,_0x14e096,_0x48f224,_0x4cf218,_0x512a27){const _0x4d67d1=_0x3da4a5;logger[_0x4d67d1('0x1c')]('[CM][%s][%s]',_0x325963,_0x14e096['id'],_0x48f224,_0x4cf218,JSON[_0x4d67d1('0x26')](_0x512a27)),io['to'](_0x48f224)['emit'](_0x4cf218,_0x512a27);}exports['exec']=function(_0x5a489e,_0xb00542,_0x35b94e,_0x4d4534){const _0x2756a6=_0x3da4a5;let _0x1f82bc,_0x572bed;const _0x1fc415={},_0x21aebf=Number(_0x35b94e['data1']),_0x38f52b=_0x35b94e[_0x2756a6('0x5')]?Boolean(Number(_0x35b94e[_0x2756a6('0x5')])):![];let _0x42e543=[];if(_0x4d4534[_0x2756a6('0x11')]&&!_['isEmpty'](_0x4d4534[_0x2756a6('0x11')]))_0x1fc415['id']=_0x4d4534[_0x2756a6('0x11')];!_0x1fc415['id']&&(_0x1fc415[_0x2756a6('0x2')]=_0x21aebf,_0x42e543=_0x35b94e[_0x2756a6('0x15')]&&_0x35b94e[_0x2756a6('0x15')]!=='0'?_0x35b94e[_0x2756a6('0x15')]['split'](','):['phone'],_0x1fc415[Op['or']]=_[_0x2756a6('0x22')](_0x42e543,function(_0x2cf477){const _0x1626e1=_0x2756a6,_0x4af50c={};return _0x4af50c[_0x2cf477]=_0x4d4534[_0x1626e1('0x4')]?_0x4d4534[_0x1626e1('0x13')]:_0x4d4534[_0x1626e1('0x21')],_0x4af50c;}));const _0x4471eb=['id',_0x2756a6('0x12'),_0x2756a6('0x29'),_0x2756a6('0x1a'),_0x2756a6('0x1e'),_0x2756a6('0xb'),_0x2756a6('0x2'),_0x2756a6('0x18'),'scheduledAt',_0x2756a6('0x20')],_0x5647f1=_['union'](_0x4471eb,_0x42e543);Promise[_0x2756a6('0xc')]()[_0x2756a6('0x27')](cmContactRpc[_0x2756a6('0x9')]({'attributes':_0x5647f1,'where':_0x1fc415}))[_0x2756a6('0x27')](function(_0x56874c){const _0xa46001=_0x2756a6;_0x572bed=_0x56874c;if(!_[_0xa46001('0xd')](_0x572bed)){_0x572bed['length']===0x1?(_0x1f82bc=_0x572bed[0x0],logger[_0xa46001('0x1c')]('[CM][%s][%s]\x20Contact\x20found:%s',_0x4d4534[_0xa46001('0xe')],_0xb00542['id'],_0x1f82bc['id'])):logger[_0xa46001('0x1c')](_0xa46001('0xf'),_0x4d4534['uniqueid'],_0xb00542['id'],_[_0xa46001('0x22')](_0x572bed,'id')[_0xa46001('0x3')](','));return;}else{logger['info'](_0xa46001('0x28'),_0x4d4534[_0xa46001('0xe')],_0xb00542['id']);if(_0x38f52b){logger[_0xa46001('0x1c')]('[CM][%s][%s]\x20Autocreate\x20enabled',_0x4d4534[_0xa46001('0xe')],_0xb00542['id']);const _0x437e02=_0x35b94e[_0xa46001('0x25')]&&_0x35b94e['data4']!=='0'?_0x35b94e[_0xa46001('0x25')]:'phone',_0x12bffc={'ListId':_0x21aebf};return _0x12bffc[_0x437e02]=_[_0xa46001('0x17')](_0x4d4534[_0xa46001('0x4')])?_0x4d4534[_0xa46001('0x21')]:_0x4d4534['destcalleridnum'],_[_0xa46001('0x17')](_0x4d4534[_0xa46001('0x4')])?_0x12bffc[_0xa46001('0x12')]=_0x4d4534[_0xa46001('0x10')]&&_0x4d4534['calleridname']!==_0xa46001('0x6')?_0x4d4534[_0xa46001('0x10')]:_0xa46001('0x19'):_0x12bffc['firstName']=_0x4d4534[_0xa46001('0x16')]&&_0x4d4534[_0xa46001('0x16')]!==_0xa46001('0x6')?_0x4d4534['destcalleridname']:'Unknown',Promise[_0xa46001('0xc')]()[_0xa46001('0x27')](cmContactRpc[_0xa46001('0x24')](_0x12bffc))[_0xa46001('0x27')](function(_0xf4445d){const _0x1533fb=_0xa46001;_0x1f82bc=_0xf4445d;_0x1f82bc&&logger[_0x1533fb('0x1c')](_0x1533fb('0x23'),_0x4d4534[_0x1533fb('0xe')],_0xb00542['id'],_0x1f82bc['id']);return;});}else{logger[_0xa46001('0x1c')]('[CM][%s][%s]\x20Autocreate\x20disabled',_0x4d4534['uniqueid'],_0xb00542['id']);return;}}})[_0x2756a6('0x27')](function(){const _0x12f992=_0x2756a6;_0x5a489e&&emit(_0x4d4534[_0x12f992('0xe')],_0xb00542,util[_0x12f992('0x1d')]('user:%s',_0x5a489e[_0x12f992('0x1f')]),util['format']('trigger:%s',_0x35b94e[_0x12f992('0x8')][_0x12f992('0x0')]()),{'evt':_[_0x12f992('0x1b')](_0x4d4534,{'autoCreate':_0x38f52b}),'contact':_0x1f82bc,'contacts':!_0x1f82bc?_0x572bed:undefined});});}; \ No newline at end of file +const a1134_0x3853=['name','[CM][%s][%s]\x20Multiple\x20contacts\x20found:[%s]','firstName','format','length','[CM][%s][%s]','resolve','isEmpty','data1','toLowerCase','getContacts','calleridname','info','uniqueid','routeId','join','destcalleridnum','[CM][%s][%s]\x20Contact\x20not\x20found','trigger','Unknown','../../../../rediscache','action','trigger:%s','mobile','then','ListId','xmd-contactid2','data3','fax','updatedAt','isNil','calleridnum','../../../../config/logger','destcalleridname','[CM][%s][%s]\x20Contact\x20found:%s','map','data2','union','[CM][%s][%s]\x20Contact\x20created:%s','exec','[CM][%s][%s]\x20Autocreate\x20enabled','phone','lastName','createdAt','[CM][%s][%s]\x20Autocreate\x20disabled','../../rpc/cmContact','','emit','createContact','util'];(function(_0x20365d,_0x3853d){const _0x4ebbd4=function(_0x511f16){while(--_0x511f16){_0x20365d['push'](_0x20365d['shift']());}};_0x4ebbd4(++_0x3853d);}(a1134_0x3853,0x14b));const a1134_0x4ebb=function(_0x20365d,_0x3853d){_0x20365d=_0x20365d-0x0;let _0x4ebbd4=a1134_0x3853[_0x20365d];return _0x4ebbd4;};const _0x1ea21d=a1134_0x4ebb;'use strict';const util=require(_0x1ea21d('0x12')),_=require('lodash'),logger=require(_0x1ea21d('0x1'))(_0x1ea21d('0x25')),cmContactRpc=require(_0x1ea21d('0xe')),{Op}=require('sequelize'),{getSocket}=require(_0x1ea21d('0x27')),io=getSocket();function emit(_0x511f16,_0xd1f943,_0x4c7c19,_0x5c02b9,_0x33ebbc){const _0x1cf64d=_0x1ea21d;logger[_0x1cf64d('0x1f')](_0x1cf64d('0x18'),_0x511f16,_0xd1f943['id'],_0x4c7c19,_0x5c02b9,JSON['stringify'](_0x33ebbc)),io['to'](_0x4c7c19)[_0x1cf64d('0x10')](_0x5c02b9,_0x33ebbc);}exports[_0x1ea21d('0x8')]=function(_0x24f786,_0x623661,_0x39f56d,_0x17fc21){const _0x52d006=_0x1ea21d;let _0xba0953,_0x59ddb0;const _0x386619={},_0x4b7b8a=Number(_0x39f56d[_0x52d006('0x1b')]),_0x5d871b=_0x39f56d['data2']?Boolean(Number(_0x39f56d[_0x52d006('0x5')])):![];let _0x389fa9=[];if(_0x17fc21[_0x52d006('0x2d')]&&!_[_0x52d006('0x1a')](_0x17fc21[_0x52d006('0x2d')]))_0x386619['id']=_0x17fc21[_0x52d006('0x2d')];!_0x386619['id']&&(_0x386619['ListId']=_0x4b7b8a,_0x389fa9=_0x39f56d['data3']&&_0x39f56d[_0x52d006('0x2e')]!=='0'?_0x39f56d['data3']['split'](','):['phone'],_0x386619[Op['or']]=_[_0x52d006('0x4')](_0x389fa9,function(_0xf37e5e){const _0x3c4962=_0x52d006,_0xbc1122={};return _0xbc1122[_0xf37e5e]=_0x17fc21['routeId']?_0x17fc21[_0x3c4962('0x23')]:_0x17fc21[_0x3c4962('0x0')],_0xbc1122;}));const _0x25cf61=['id',_0x52d006('0x15'),_0x52d006('0xb'),_0x52d006('0xa'),_0x52d006('0x2a'),_0x52d006('0x2f'),_0x52d006('0x2c'),_0x52d006('0xc'),'scheduledAt',_0x52d006('0x30')],_0x42eda0=_[_0x52d006('0x6')](_0x25cf61,_0x389fa9);Promise[_0x52d006('0x19')]()[_0x52d006('0x2b')](cmContactRpc[_0x52d006('0x1d')]({'attributes':_0x42eda0,'where':_0x386619}))['then'](function(_0x2bced6){const _0x96b0bf=_0x52d006;_0x59ddb0=_0x2bced6;if(!_[_0x96b0bf('0x1a')](_0x59ddb0)){_0x59ddb0[_0x96b0bf('0x17')]===0x1?(_0xba0953=_0x59ddb0[0x0],logger[_0x96b0bf('0x1f')](_0x96b0bf('0x3'),_0x17fc21[_0x96b0bf('0x20')],_0x623661['id'],_0xba0953['id'])):logger[_0x96b0bf('0x1f')](_0x96b0bf('0x14'),_0x17fc21[_0x96b0bf('0x20')],_0x623661['id'],_[_0x96b0bf('0x4')](_0x59ddb0,'id')[_0x96b0bf('0x22')](','));return;}else{logger[_0x96b0bf('0x1f')](_0x96b0bf('0x24'),_0x17fc21[_0x96b0bf('0x20')],_0x623661['id']);if(_0x5d871b){logger[_0x96b0bf('0x1f')](_0x96b0bf('0x9'),_0x17fc21[_0x96b0bf('0x20')],_0x623661['id']);const _0x5eb889=_0x39f56d['data4']&&_0x39f56d['data4']!=='0'?_0x39f56d['data4']:'phone',_0xadff78={'ListId':_0x4b7b8a};return _0xadff78[_0x5eb889]=_[_0x96b0bf('0x31')](_0x17fc21[_0x96b0bf('0x21')])?_0x17fc21[_0x96b0bf('0x0')]:_0x17fc21[_0x96b0bf('0x23')],_[_0x96b0bf('0x31')](_0x17fc21[_0x96b0bf('0x21')])?_0xadff78[_0x96b0bf('0x15')]=_0x17fc21[_0x96b0bf('0x1e')]&&_0x17fc21[_0x96b0bf('0x1e')]!==''?_0x17fc21[_0x96b0bf('0x1e')]:_0x96b0bf('0x26'):_0xadff78[_0x96b0bf('0x15')]=_0x17fc21[_0x96b0bf('0x2')]&&_0x17fc21[_0x96b0bf('0x2')]!==_0x96b0bf('0xf')?_0x17fc21[_0x96b0bf('0x2')]:'Unknown',Promise[_0x96b0bf('0x19')]()[_0x96b0bf('0x2b')](cmContactRpc[_0x96b0bf('0x11')](_0xadff78))['then'](function(_0x2e229f){const _0x4e17a9=_0x96b0bf;_0xba0953=_0x2e229f;_0xba0953&&logger[_0x4e17a9('0x1f')](_0x4e17a9('0x7'),_0x17fc21[_0x4e17a9('0x20')],_0x623661['id'],_0xba0953['id']);return;});}else{logger[_0x96b0bf('0x1f')](_0x96b0bf('0xd'),_0x17fc21['uniqueid'],_0x623661['id']);return;}}})[_0x52d006('0x2b')](function(){const _0x26e853=_0x52d006;_0x24f786&&emit(_0x17fc21[_0x26e853('0x20')],_0x623661,util[_0x26e853('0x16')]('user:%s',_0x24f786[_0x26e853('0x13')]),util[_0x26e853('0x16')](_0x26e853('0x29'),_0x39f56d[_0x26e853('0x28')][_0x26e853('0x1c')]()),{'evt':_['merge'](_0x17fc21,{'autoCreate':_0x5d871b}),'contact':_0xba0953,'contacts':!_0xba0953?_0x59ddb0:undefined});});}; \ No newline at end of file diff --git a/server/services/ami/trigger/index.js b/server/services/ami/trigger/index.js index 799bc59..c4b865b 100644 --- a/server/services/ami/trigger/index.js +++ b/server/services/ami/trigger/index.js @@ -1 +1 @@ -const a1135_0x33a1=['custom:rejectmessage','contactmanager','AnyConditions','undefined','winapp','data4','custom:newinteraction','query','data6','custom:outgoingmessage','winArguments','jscripty','Actions','./cmContact','freshsalesAccounts','routeId','custom:queuecallerabandon','ChatWebsiteId','checkConditions','interface','isNil','prototype','custom:agentbusy','../../../rediscache','replace','sugarcrmAccounts','./integration','agents','template\x20not\x20found','salesforceAccounts','membername','custom:agentcomplete','account','parse','util','winApplication','toLowerCase','templates','windowHeight','voiceExtensions','custom:timeout','uri','data3','emit','name','format','zendeskAccounts','data1','clone','custom:incomingmessage','custom:agentconnect','accounts','data2','custom:acceptmessage','servicenowAccounts','triggers','custom:agentreject','custom:agentringnoanswer','interaction','custom:dialend','trigger:%s:%s','value','event','buildUri','zohoAccounts','location','stringify','length','message','voiceQueues','../ami','custom:agentnoanswer','channel','field','every','lastevent','../../../config/logger','upperFirst','some','vtigerAccounts','render','bind','custom:dialconnect','data5','800','browser','html','info','deskAccounts','url','trigger:%s','600','custom:closedinteraction','merge','action','queue','search','custom:agentnosuchnumber','AllConditions','user:%s','dynamics365Accounts','syncAgentDial','custom:agentcalled','syncCustomEvent','operator','AccountId','urlforward','trigger','freshdeskAccounts','popup','exec','checkTriggers','variables'];(function(_0x21a341,_0x33a135){const _0x17cbf5=function(_0x5a4f57){while(--_0x5a4f57){_0x21a341['push'](_0x21a341['shift']());}};_0x17cbf5(++_0x33a135);}(a1135_0x33a1,0xd8));const a1135_0x17cb=function(_0x21a341,_0x33a135){_0x21a341=_0x21a341-0x0;let _0x17cbf5=a1135_0x33a1[_0x21a341];return _0x17cbf5;};const _0x2e0d82=a1135_0x17cb;'use strict';const util=require(_0x2e0d82('0x2c')),_=require('lodash'),url=require(_0x2e0d82('0x63')),Mustache=require('mustache'),urlforward=require('./urlforward'),integration=require(_0x2e0d82('0x24')),cmContact=require(_0x2e0d82('0x17')),script=require('./script'),logger=require(_0x2e0d82('0x56'))(_0x2e0d82('0x4')),ami=require(_0x2e0d82('0x50')),{getSocket}=require(_0x2e0d82('0x21')),io=getSocket(),operators={'equals':function(_0x5a4f57,_0x874d13){return _0x5a4f57==_0x874d13;},'not_equals':function(_0x5191fd,_0xea5997){return _0x5191fd!=_0xea5997;}},barAndWebActions=[_0x2e0d82('0x6'),'url',_0x2e0d82('0xe')];function Trigger(_0x58e7f8){const _0x4ff485=_0x2e0d82;this['triggers']=_0x58e7f8['triggers'],this[_0x4ff485('0x25')]=_0x58e7f8[_0x4ff485('0x25')],this[_0x4ff485('0x4f')]=_0x58e7f8[_0x4ff485('0x4f')],this[_0x4ff485('0x2f')]=_0x58e7f8[_0x4ff485('0x2f')],this[_0x4ff485('0x31')]=_0x58e7f8[_0x4ff485('0x31')],this[_0x4ff485('0x38')]=_0x58e7f8[_0x4ff485('0x38')],this[_0x4ff485('0x5')]=_0x58e7f8[_0x4ff485('0x5')],this[_0x4ff485('0x27')]=_0x58e7f8[_0x4ff485('0x27')],this[_0x4ff485('0x23')]=_0x58e7f8[_0x4ff485('0x23')],this['zohoAccounts']=_0x58e7f8[_0x4ff485('0x4a')],this[_0x4ff485('0x62')]=_0x58e7f8[_0x4ff485('0x62')],this[_0x4ff485('0x59')]=_0x58e7f8[_0x4ff485('0x59')],this[_0x4ff485('0x40')]=_0x58e7f8[_0x4ff485('0x40')],this['dynamics365Accounts']=_0x58e7f8[_0x4ff485('0x6e')],this['freshsalesAccounts']=_0x58e7f8['freshsalesAccounts'],this[_0x4ff485('0x3d')]={'zendesk':this[_0x4ff485('0x38')],'salesforce':this[_0x4ff485('0x27')],'freshdesk':this['freshdeskAccounts'],'sugarcrm':this[_0x4ff485('0x23')],'zoho':this[_0x4ff485('0x4a')],'desk':this['deskAccounts'],'vtiger':this[_0x4ff485('0x59')],'dynamics365':this[_0x4ff485('0x6e')],'freshsales':this[_0x4ff485('0x18')],'servicenow':this[_0x4ff485('0x40')]},ami['on'](_0x4ff485('0x70'),this['syncCustomEvent']['bind'](this)),ami['on'](_0x4ff485('0x3c'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x43'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x29'),this[_0x4ff485('0x0')]['bind'](this)),ami['on'](_0x4ff485('0x6b'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x51'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x20'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on']('custom:agentcongestion',this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x42'),this['syncCustomEvent']['bind'](this)),ami['on'](_0x4ff485('0x1a'),this['syncCustomEvent'][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x32'),this['syncCustomEvent']['bind'](this)),ami['on']('custom:dialbegin',this[_0x4ff485('0x6f')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x5c'),this[_0x4ff485('0x6f')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x45'),this[_0x4ff485('0x6f')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x10'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x66'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x3b'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x13'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0x3f'),this['syncCustomEvent'][_0x4ff485('0x5b')](this)),ami['on'](_0x4ff485('0xa'),this[_0x4ff485('0x0')][_0x4ff485('0x5b')](this));}Trigger[_0x2e0d82('0x1f')][_0x2e0d82('0x35')]=function(_0x48e01f,_0x687500,_0x146ab9){const _0x3c8fe8=_0x2e0d82;logger[_0x3c8fe8('0x61')](_0x48e01f,_0x687500,JSON[_0x3c8fe8('0x4c')](_0x146ab9)),io['to'](_0x48e01f)['emit'](_0x687500,_0x146ab9);},Trigger[_0x2e0d82('0x1f')][_0x2e0d82('0x0')]=function(_0x282143){const _0x4d7acf=_0x2e0d82,_0x337a01=_[_0x4d7acf('0x3a')](_0x282143);this['checkTriggers'](_0x337a01);},Trigger[_0x2e0d82('0x1f')][_0x2e0d82('0x6f')]=function(_0x29ddfb){const _0x1aa51d=_0x2e0d82;this[_0x1aa51d('0x25')][_0x29ddfb[_0x1aa51d('0x1d')]]&&this[_0x1aa51d('0x0')](_0x29ddfb);},Trigger[_0x2e0d82('0x1f')][_0x2e0d82('0x8')]=function(_0x313c9e){const _0x21e9b1=_0x2e0d82;let _0x1441b9;for(const _0x1150c9 in this[_0x21e9b1('0x41')]){if(typeof this[_0x21e9b1('0x41')][_0x1150c9]!==_0x21e9b1('0xd')){if(this['triggers'][_0x1150c9]['status']){_0x1441b9=this['checkTrigger'](this[_0x21e9b1('0x41')][_0x1150c9],_0x313c9e);if(_0x1441b9){_[_0x21e9b1('0x67')](_0x313c9e,_0x313c9e[_0x21e9b1('0x9')]);for(let _0x4e3baf=0x0,_0x48ab51;_0x4e3baf0x0&&(_0x4b1e44=_['map'](_0x1edca3,_0x36977e)),_0x4b1e44;}function getCustomFields(_0x519e9b,_0xfbbcce){const _0x16bbdd=_0x5d7228,_0x859e5e={'custom_fields':{}};return _0x519e9b['length']>0x0&&_[_0x16bbdd('0x29')](_0x519e9b,function(_0x3fa7d1){const _0x23484e=_0x16bbdd;if(_0x3fa7d1[_0x23484e('0x26')]===_0x23484e('0x2d')&&_0x3fa7d1['nameField']&&!_0x3fa7d1[_0x23484e('0x21')])_0x859e5e[_0x3fa7d1[_0x23484e('0x42')][_0x23484e('0x43')]()]=_0x3fa7d1[_0x23484e('0xc')][_0x23484e('0x5e')]();else{if(_0x3fa7d1[_0x23484e('0x26')]===_0x23484e('0x2d')&&_0x3fa7d1[_0x23484e('0xb')]&&_0x3fa7d1[_0x23484e('0x21')])_0x859e5e[_0x23484e('0x40')][_0x3fa7d1['idField']]=_0x3fa7d1[_0x23484e('0xc')]['toString']();else{if(_0x3fa7d1[_0x23484e('0x26')]===_0x23484e('0x19')&&_0x3fa7d1[_0x23484e('0x3f')]&&_0x3fa7d1['idField']&&_0x3fa7d1[_0x23484e('0x21')])_0xfbbcce[_0x3fa7d1['variableName']]&&(_0x859e5e[_0x23484e('0x40')][_0x3fa7d1[_0x23484e('0xb')]]=_0xfbbcce[_0x3fa7d1[_0x23484e('0x3f')]][_0x23484e('0x5e')]());else _0x3fa7d1[_0x23484e('0x26')]===_0x23484e('0x5f')&&_0x3fa7d1['Variable']&&_0x3fa7d1[_0x23484e('0x33')][_0x23484e('0x4c')]&&_0x3fa7d1[_0x23484e('0xb')]&&_0x3fa7d1['customField']&&(_0xfbbcce[_0x3fa7d1['Variable'][_0x23484e('0x4c')]['toLowerCase']()]&&(_0x859e5e[_0x23484e('0x40')][_0x3fa7d1['idField']]=_0xfbbcce[_0x3fa7d1['Variable'][_0x23484e('0x4c')][_0x23484e('0x43')]()][_0x23484e('0x5e')]()));}}}),_0x859e5e['priority']&&(_0x859e5e['priority']=Number(_0x859e5e[_0x16bbdd('0x50')])),_0x859e5e;}function getTicket(_0x2f33e4,_0x532939,_0x3982ac,_0x378fc3,_0x1fc6fd){const _0x3a8fdb=_0x5d7228;logger[_0x3a8fdb('0x1')]('Creating\x20new\x20ticket...');const _0x54d2f8=_[_0x3a8fdb('0x57')]({'subject':intUtil[_0x3a8fdb('0x23')](_0x378fc3[_0x3a8fdb('0x4d')],_0x1fc6fd,'\x20'),'type':_0x3a8fdb('0x0'),'status':_0x3a8fdb('0x2b'),'labels':[_0x3a8fdb('0x24'),'Motion',_0x3a8fdb('0x3d')][_0x3a8fdb('0x52')](getTags(_0x378fc3[_0x3a8fdb('0x30')],'name')),'description':intUtil[_0x3a8fdb('0x23')](_0x378fc3[_0x3a8fdb('0x2f')],_0x1fc6fd,'\x0a'),'_links':{'assigned_user':{'href':util[_0x3a8fdb('0x15')]('/api/v2/users/%d',_0x532939['id']),'class':_0x3a8fdb('0x5d')}},'message':{'direction':'in','body':intUtil[_0x3a8fdb('0x23')](_0x378fc3[_0x3a8fdb('0x2f')],_0x1fc6fd,'\x0a')}},getCustomFields(_0x378fc3['Fields'],_0x1fc6fd));return request({'uri':util[_0x3a8fdb('0x15')]('%s/customers/%d/cases',_0x2f33e4[_0x3a8fdb('0x46')],_0x3982ac['id']),'method':'POST','body':_0x54d2f8});}exports[_0x5d7228('0x18')]=function(_0x5651a6,_0x3c9867,_0x38d076,_0x461e11,_0x37e747,_0x20a112){const _0x4c354e=_0x5d7228;let _0x33d8a5,_0x2f0be8;return _0x20a112[_0x4c354e('0x46')]=intUtil[_0x4c354e('0x22')](_0x20a112[_0x4c354e('0x46')]),_0x20a112[_0x4c354e('0x2e')]=intUtil[_0x4c354e('0x22')](_0x20a112[_0x4c354e('0x2e')]),_0x37e747&&_0x37e747['monitor_format']?(logger[_0x4c354e('0x1')](_0x4c354e('0x6'),_0x4c354e('0x5a')),_0x3c9867[_0x4c354e('0x39')]=util[_0x4c354e('0x15')](_0x4c354e('0x7'),_0x20a112['serverUrl'],_0x3c9867[_0x4c354e('0x2')],md5(_0x3c9867[_0x4c354e('0x2')]))):_0x3c9867[_0x4c354e('0x39')]='',headers[_0x4c354e('0x3')]=getAuth(_0x20a112),getUser(_0x20a112,_0x461e11['email'])[_0x4c354e('0xa')](function(_0x46941b){const _0xa95633=_0x4c354e;return _0x33d8a5=_0x46941b,logger[_0xa95633('0x1')](_0xa95633('0x1c'),_0x33d8a5['id']),getEndUser(_0x20a112,_0x3c9867['calleridname'],_0x3c9867[_0xa95633('0x53')]);})[_0x4c354e('0xa')](function(_0x306f45){const _0x3d9d93=_0x4c354e;return _0x2f0be8=_0x306f45,logger[_0x3d9d93('0x1')](_0x3d9d93('0x3b'),_0x2f0be8['id']),getTicket(_0x20a112,_0x33d8a5,_0x2f0be8,_0x38d076,_0x3c9867);})[_0x4c354e('0xa')](function(_0x516a4a){const _0x5475de=_0x4c354e;if(_0x516a4a){logger['info'](_0x5475de('0x2c')),logger[_0x5475de('0x1')](_0x5475de('0x3c'),_0x516a4a['id']);switch(_0x20a112[_0x5475de('0x26')]){case _0x5475de('0x13'):logger[_0x5475de('0x1')](_0x5475de('0x6'),_0x5475de('0x35')),emit(util['format'](_0x5475de('0x56'),_0x461e11['name']),_0x5475de('0x20'),{'recordId':_0x516a4a['id']});break;case _0x5475de('0xe'):logger[_0x5475de('0x1')]('[QUEUE]',_0x5475de('0x4')),emit(util['format'](_0x5475de('0x56'),_0x461e11[_0x5475de('0x4c')]),_0x5475de('0x12'),{'uri':util[_0x5475de('0x15')]('https://xcally.desk.com/web/agent/case/%d',_0x516a4a['id'])});break;default:logger[_0x5475de('0x25')](_0x5475de('0x6'),'Desk\x20account\x20type\x20not\x20recognized');}}})['catch'](function(_0x4cb860){const _0x1df098=_0x4c354e;console['error'](_0x4cb860),logger[_0x1df098('0x25')](_0x1df098('0x6'),JSON['stringify'](_0x4cb860));});},exports[_0x5d7228('0x59')]=function(_0x50a67c,_0x4c38e8,_0x4ee9a0,_0x4fa584,_0x584b7e,_0x2056bf,_0x37f0c7){const _0x1155e8=_0x5d7228;let _0x3df9f3,_0x5bb532;return _0x2056bf['remoteUri']=intUtil['stripTrailingSlash'](_0x2056bf[_0x1155e8('0x46')]),_0x2056bf[_0x1155e8('0x2e')]=intUtil[_0x1155e8('0x22')](_0x2056bf['serverUrl']),_0x37f0c7&&_0x37f0c7[_0x1155e8('0x3a')]&&_0x37f0c7[_0x1155e8('0x3a')]!==_0x1155e8('0x28')&&(logger[_0x1155e8('0x1')](_0x1155e8('0x36'),_0x1155e8('0x5a')),_0x4c38e8[_0x1155e8('0x39')]=util[_0x1155e8('0x15')](_0x1155e8('0x7'),_0x2056bf[_0x1155e8('0x2e')],_0x4c38e8[_0x1155e8('0x2')],md5(_0x4c38e8[_0x1155e8('0x2')]))),headers['Authorization']=getAuth(_0x2056bf),getUser(_0x2056bf,_0x4fa584[_0x1155e8('0xd')])[_0x1155e8('0xa')](function(_0x228dcf){const _0x264fe1=_0x1155e8;return _0x3df9f3=_0x228dcf,logger['info'](_0x264fe1('0x1c'),_0x3df9f3['id']),getEndUser(_0x2056bf,_0x4c38e8[_0x264fe1('0x44')],_0x4c38e8[_0x264fe1('0x51')]);})['then'](function(_0x1080e9){const _0x3e12b7=_0x1155e8;return _0x5bb532=_0x1080e9,logger['info'](_0x3e12b7('0x3b'),_0x5bb532['id']),getTicket(_0x2056bf,_0x3df9f3,_0x5bb532,_0x4ee9a0,_0x4c38e8);})[_0x1155e8('0xa')](function(_0xd5f3bc){const _0x58d9c6=_0x1155e8;if(_0xd5f3bc){logger[_0x58d9c6('0x1')](_0x58d9c6('0x2c')),logger[_0x58d9c6('0x1')]('The\x20Ticket\x20ID\x20is:',_0xd5f3bc['id']);switch(_0x2056bf[_0x58d9c6('0x26')]){case _0x58d9c6('0x13'):logger[_0x58d9c6('0x1')](_0x58d9c6('0x6'),_0x58d9c6('0x35')),emit(util[_0x58d9c6('0x15')](_0x58d9c6('0x56'),_0x4fa584[_0x58d9c6('0x4c')]),'trigger:desk:display',{'recordId':_0xd5f3bc['id']});break;case'newTab':logger['info'](_0x58d9c6('0x6'),_0x58d9c6('0x4')),emit(util[_0x58d9c6('0x15')](_0x58d9c6('0x56'),_0x4fa584[_0x58d9c6('0x4c')]),_0x58d9c6('0x12'),{'uri':util['format'](_0x58d9c6('0x4f'),_0x2056bf[_0x58d9c6('0x46')],_0xd5f3bc['id'])});break;default:logger[_0x58d9c6('0x25')]('[OUTBOUND]','Desk\x20account\x20type\x20not\x20recognized');}}})[_0x1155e8('0x1f')](function(_0x171f26){const _0x131543=_0x1155e8;logger[_0x131543('0x25')](_0x131543('0x36'),JSON[_0x131543('0xf')](_0x171f26));});},exports[_0x5d7228('0x1d')]=function(_0x10c09b,_0x39f895,_0x2445a8,_0x20301c,_0x48b1d8,_0x536a25){const _0x1efb52=_0x5d7228;let _0x261934,_0x29e877;return _0x536a25['remoteUri']=intUtil['stripTrailingSlash'](_0x536a25[_0x1efb52('0x46')]),_0x536a25[_0x1efb52('0x2e')]=intUtil['stripTrailingSlash'](_0x536a25[_0x1efb52('0x2e')]),_0x48b1d8&&_0x48b1d8[_0x1efb52('0x8')]?(logger[_0x1efb52('0x1')]('['+_0x39f895[_0x1efb52('0x55')][_0x1efb52('0x41')]()+']','Recording\x20is\x20enabled!'),_0x39f895[_0x1efb52('0x39')]=util[_0x1efb52('0x15')](_0x1efb52('0x7'),_0x536a25['serverUrl'],_0x39f895['uniqueid'],md5(_0x39f895[_0x1efb52('0x2')]))):_0x39f895[_0x1efb52('0x39')]='',headers[_0x1efb52('0x3')]=getAuth(_0x536a25),getUser(_0x536a25)[_0x1efb52('0xa')](function(_0x48189a){const _0x57dfa3=_0x1efb52;return _0x261934=_0x48189a,logger[_0x57dfa3('0x1')](_0x57dfa3('0x1c'),_0x261934['id']),getEndUser(_0x536a25,_0x39f895[_0x57dfa3('0x9')],_0x39f895[_0x57dfa3('0x53')]);})['then'](function(_0x5877d9){const _0x130014=_0x1efb52;return _0x29e877=_0x5877d9,logger[_0x130014('0x1')](_0x130014('0x3b'),_0x29e877['id']),getTicket(_0x536a25,_0x261934,_0x29e877,_0x2445a8,_0x39f895);})[_0x1efb52('0xa')](function(_0x4defd8){const _0x48dee3=_0x1efb52;_0x4defd8&&(logger[_0x48dee3('0x1')](_0x48dee3('0x2c')),logger[_0x48dee3('0x1')](_0x48dee3('0x3c'),_0x4defd8['id']));})[_0x1efb52('0x1f')](function(_0x5efe7c){const _0x3c62cd=_0x1efb52;logger[_0x3c62cd('0x25')]('['+_0x39f895[_0x3c62cd('0x55')][_0x3c62cd('0x41')]()+']',JSON[_0x3c62cd('0xf')](_0x5efe7c));});}; \ No newline at end of file +const a1136_0x11ec=['/api/v2/users/%d','trigger:desk:display','destcalleridnum','defaults','https://xcally.desk.com/web/agent/case/%d','entries','info','Recording\x20is\x20enabled!','priority','Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...','debug','forEach','monitor_format','idField','Invalid\x20email\x20format,\x20using\x20the\x20admin\x20account!','The\x20Ticket\x20ID\x20is:','Basic\x20%s','The\x20Enduser\x20ID\x20is:','Motion','variableName','lastevent','serverUrl','[QUEUE]','variable','[HTTP]','name','type','stripTrailingSlash','Variable','customField','Creating\x20new\x20ticket...','Enduser\x20not\x20found,\x20creating\x20a\x20new\x20enduser!','Fields','[OUTBOUND]','Agent\x20found!','integrationTab','desk','merge','validateEmail','concat','%s/users','Tags','unmanaged','newTab','string','catch','Displaying\x20ticket\x20to\x20agent...','then','CTI','format','toLowerCase','token','_embedded','none','calleridnum','user:%s','password','from','new','../../../../rediscache','%s/users/me','The\x20User\x20ID\x20is:','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','email','Searching\x20enduser\x20with\x20phone','Getting\x20agent\x20with\x20email','recordingURL','total_entries','application/json','%s/customers/search','../../../../config/logger','Descriptions','POST','emit','recordingFormat','GET','user','Authorization','util','uniqueid','remoteUri','%s/customers','calleridname','toString','length','authType','trigger:browser:url','content','custom_fields','nameField','Ticket\x20created!','base64','stringify','error','username','Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!','lodash','basic','Desk\x20account\x20type\x20not\x20recognized','toUpperCase','getString','find'];(function(_0x370c89,_0x11ecaa){const _0x42a38b=function(_0x28733f){while(--_0x28733f){_0x370c89['push'](_0x370c89['shift']());}};_0x42a38b(++_0x11ecaa);}(a1136_0x11ec,0xc8));const a1136_0x42a3=function(_0x370c89,_0x11ecaa){_0x370c89=_0x370c89-0x0;let _0x42a38b=a1136_0x11ec[_0x370c89];return _0x42a38b;};const _0x37098b=a1136_0x42a3;'use strict';const _=require(_0x37098b('0x64')),rp=require('request-promise-native'),md5=require('md5'),util=require(_0x37098b('0x52')),intUtil=require('./util'),logger=require(_0x37098b('0x4a'))(_0x37098b('0x28')),{getSocket}=require(_0x37098b('0x3f')),io=getSocket();function emit(_0x28733f,_0x1c31a8,_0x1ef9a1){const _0x14209a=_0x37098b;io['to'](_0x28733f)[_0x14209a('0x4d')](_0x1c31a8,_0x1ef9a1);}const headers={'Content-Type':'application/json','Accept':_0x37098b('0x48')};function getUser(_0x30018a,_0x4d1adf){const _0x29df12=_0x37098b;return intUtil[_0x29df12('0x2a')](_0x4d1adf)===!![]?(logger['info'](_0x29df12('0x45'),_0x4d1adf),request({'uri':util[_0x29df12('0x35')](_0x29df12('0x2c'),_0x30018a[_0x29df12('0x54')])})['then'](function(_0x1f2ffd){const _0x5069bb=_0x29df12;if(_0x1f2ffd['total_entries'])return _[_0x5069bb('0x3')](_0x1f2ffd['_embedded'][_0x5069bb('0x9')],{'email':_0x4d1adf});})[_0x29df12('0x33')](function(_0x4a5978){const _0x5701a=_0x29df12;return _0x4a5978?(logger[_0x5701a('0xa')](_0x5701a('0x26')),_0x4a5978):(logger['info'](_0x5701a('0x63')),request({'uri':util[_0x5701a('0x35')](_0x5701a('0x40'),_0x30018a[_0x5701a('0x54')])}));})):(logger[_0x29df12('0xa')](_0x29df12('0x12')),request({'uri':util['format'](_0x29df12('0x40'),_0x30018a[_0x29df12('0x54')])}));}function request(_0x45a67b){const _0x212b75=_0x37098b;return logger[_0x212b75('0xe')](_0x212b75('0x1c'),JSON[_0x212b75('0x60')](_0x45a67b)),rp(_[_0x212b75('0x7')](_0x45a67b,{'method':_0x212b75('0x4f'),'headers':headers,'json':!![]}));}function getAuth(_0x3a0bf7){const _0x47b30d=_0x37098b;let _0x595906;if(_0x3a0bf7[_0x47b30d('0x59')]===_0x47b30d('0x65'))_0x595906=util[_0x47b30d('0x35')]('%s:%s',_0x3a0bf7[_0x47b30d('0x62')],_0x3a0bf7[_0x47b30d('0x3c')]);else _0x3a0bf7[_0x47b30d('0x59')]===_0x47b30d('0x37')&&(_0x595906=util[_0x47b30d('0x35')]('%s/token:%s',_0x3a0bf7[_0x47b30d('0x62')],_0x3a0bf7[_0x47b30d('0x37')]));return util[_0x47b30d('0x35')](_0x47b30d('0x14'),Buffer[_0x47b30d('0x3d')](_0x595906)[_0x47b30d('0x57')](_0x47b30d('0x5f')));}function getEndUser(_0x4edfdd,_0x2dc11e,_0xad209f){const _0x1c591f=_0x37098b;return logger[_0x1c591f('0xa')](_0x1c591f('0x44'),_0xad209f),request({'uri':util[_0x1c591f('0x35')](_0x1c591f('0x49'),_0x4edfdd[_0x1c591f('0x54')]),'qs':{'phone':_0xad209f}})[_0x1c591f('0x33')](function(_0x5eab48){const _0x55bdd8=_0x1c591f;return _0x5eab48[_0x55bdd8('0x47')]?(logger[_0x55bdd8('0xa')]('Enduser\x20found!'),_0x5eab48[_0x55bdd8('0x38')]['entries'][0x0]):(logger[_0x55bdd8('0xa')](_0x55bdd8('0x23')),request({'uri':util[_0x55bdd8('0x35')](_0x55bdd8('0x55'),_0x4edfdd[_0x55bdd8('0x54')]),'method':_0x55bdd8('0x4c'),'body':{'first_name':_0x2dc11e,'title':_0x2dc11e,'phone_numbers':[{'type':'work','value':_0xad209f}]}}));});}function getTags(_0x343b5c,_0x4f1fd2){const _0x382cfc=_0x37098b;let _0xafb5e0=[];return _0x343b5c&&_0x343b5c[_0x382cfc('0x58')]>0x0&&(_0xafb5e0=_['map'](_0x343b5c,_0x4f1fd2)),_0xafb5e0;}function getCustomFields(_0x5bca54,_0x33998c){const _0x3d0ee3=_0x37098b,_0x1f27f0={'custom_fields':{}};return _0x5bca54[_0x3d0ee3('0x58')]>0x0&&_[_0x3d0ee3('0xf')](_0x5bca54,function(_0x3e6268){const _0x17d37b=_0x3d0ee3;if(_0x3e6268[_0x17d37b('0x1e')]===_0x17d37b('0x30')&&_0x3e6268['nameField']&&!_0x3e6268['customField'])_0x1f27f0[_0x3e6268[_0x17d37b('0x5d')][_0x17d37b('0x36')]()]=_0x3e6268[_0x17d37b('0x5b')][_0x17d37b('0x57')]();else{if(_0x3e6268[_0x17d37b('0x1e')]===_0x17d37b('0x30')&&_0x3e6268[_0x17d37b('0x11')]&&_0x3e6268['customField'])_0x1f27f0[_0x17d37b('0x5c')][_0x3e6268[_0x17d37b('0x11')]]=_0x3e6268['content'][_0x17d37b('0x57')]();else{if(_0x3e6268[_0x17d37b('0x1e')]===_0x17d37b('0x1b')&&_0x3e6268[_0x17d37b('0x17')]&&_0x3e6268[_0x17d37b('0x11')]&&_0x3e6268[_0x17d37b('0x21')])_0x33998c[_0x3e6268[_0x17d37b('0x17')]]&&(_0x1f27f0['custom_fields'][_0x3e6268[_0x17d37b('0x11')]]=_0x33998c[_0x3e6268['variableName']][_0x17d37b('0x57')]());else _0x3e6268[_0x17d37b('0x1e')]==='customVariable'&&_0x3e6268['Variable']&&_0x3e6268[_0x17d37b('0x20')][_0x17d37b('0x1d')]&&_0x3e6268[_0x17d37b('0x11')]&&_0x3e6268['customField']&&(_0x33998c[_0x3e6268['Variable'][_0x17d37b('0x1d')][_0x17d37b('0x36')]()]&&(_0x1f27f0[_0x17d37b('0x5c')][_0x3e6268['idField']]=_0x33998c[_0x3e6268[_0x17d37b('0x20')][_0x17d37b('0x1d')][_0x17d37b('0x36')]()][_0x17d37b('0x57')]()));}}}),_0x1f27f0[_0x3d0ee3('0xc')]&&(_0x1f27f0['priority']=Number(_0x1f27f0[_0x3d0ee3('0xc')])),_0x1f27f0;}function getTicket(_0x78a7f9,_0x26a39c,_0x2f6d61,_0x140a67,_0x375882){const _0x11e0ab=_0x37098b;logger[_0x11e0ab('0xa')](_0x11e0ab('0x22'));const _0x21af9f=_[_0x11e0ab('0x29')]({'subject':intUtil[_0x11e0ab('0x2')](_0x140a67['Subjects'],_0x375882,'\x20'),'type':'phone','status':_0x11e0ab('0x3e'),'labels':['xCALLY',_0x11e0ab('0x16'),_0x11e0ab('0x34')][_0x11e0ab('0x2b')](getTags(_0x140a67[_0x11e0ab('0x2d')],_0x11e0ab('0x1d'))),'description':intUtil[_0x11e0ab('0x2')](_0x140a67[_0x11e0ab('0x4b')],_0x375882,'\x0a'),'_links':{'assigned_user':{'href':util[_0x11e0ab('0x35')](_0x11e0ab('0x4'),_0x26a39c['id']),'class':_0x11e0ab('0x50')}},'message':{'direction':'in','body':intUtil[_0x11e0ab('0x2')](_0x140a67[_0x11e0ab('0x4b')],_0x375882,'\x0a')}},getCustomFields(_0x140a67[_0x11e0ab('0x24')],_0x375882));return request({'uri':util[_0x11e0ab('0x35')]('%s/customers/%d/cases',_0x78a7f9['remoteUri'],_0x2f6d61['id']),'method':'POST','body':_0x21af9f});}exports['queue']=function(_0x4d672f,_0x27d441,_0x3f59ab,_0x1ba664,_0x15c357,_0x47fca9){const _0x1e4836=_0x37098b;let _0x196e74,_0x14bea5;return _0x47fca9[_0x1e4836('0x54')]=intUtil[_0x1e4836('0x1f')](_0x47fca9[_0x1e4836('0x54')]),_0x47fca9[_0x1e4836('0x19')]=intUtil['stripTrailingSlash'](_0x47fca9[_0x1e4836('0x19')]),_0x15c357&&_0x15c357[_0x1e4836('0x10')]?(logger['info'](_0x1e4836('0x1a'),'Recording\x20is\x20enabled!'),_0x27d441[_0x1e4836('0x46')]=util[_0x1e4836('0x35')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x47fca9['serverUrl'],_0x27d441['uniqueid'],md5(_0x27d441[_0x1e4836('0x53')]))):_0x27d441[_0x1e4836('0x46')]='',headers['Authorization']=getAuth(_0x47fca9),getUser(_0x47fca9,_0x1ba664[_0x1e4836('0x43')])[_0x1e4836('0x33')](function(_0x222f61){const _0xa89226=_0x1e4836;return _0x196e74=_0x222f61,logger[_0xa89226('0xa')]('The\x20User\x20ID\x20is:',_0x196e74['id']),getEndUser(_0x47fca9,_0x27d441['calleridname'],_0x27d441[_0xa89226('0x3a')]);})[_0x1e4836('0x33')](function(_0x554f50){const _0x23fa2a=_0x1e4836;return _0x14bea5=_0x554f50,logger['info'](_0x23fa2a('0x15'),_0x14bea5['id']),getTicket(_0x47fca9,_0x196e74,_0x14bea5,_0x3f59ab,_0x27d441);})['then'](function(_0x540051){const _0x2cf0cd=_0x1e4836;if(_0x540051){logger[_0x2cf0cd('0xa')](_0x2cf0cd('0x5e')),logger['info']('The\x20Ticket\x20ID\x20is:',_0x540051['id']);switch(_0x47fca9[_0x2cf0cd('0x1e')]){case _0x2cf0cd('0x27'):logger[_0x2cf0cd('0xa')](_0x2cf0cd('0x1a'),'Displaying\x20ticket\x20to\x20agent...'),emit(util[_0x2cf0cd('0x35')](_0x2cf0cd('0x3b'),_0x1ba664[_0x2cf0cd('0x1d')]),_0x2cf0cd('0x5'),{'recordId':_0x540051['id']});break;case'newTab':logger[_0x2cf0cd('0xa')](_0x2cf0cd('0x1a'),'Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...'),emit(util[_0x2cf0cd('0x35')](_0x2cf0cd('0x3b'),_0x1ba664['name']),_0x2cf0cd('0x5a'),{'uri':util['format'](_0x2cf0cd('0x8'),_0x540051['id'])});break;default:logger[_0x2cf0cd('0x61')](_0x2cf0cd('0x1a'),_0x2cf0cd('0x0'));}}})[_0x1e4836('0x31')](function(_0x14d401){const _0xb2ad1=_0x1e4836;console[_0xb2ad1('0x61')](_0x14d401),logger[_0xb2ad1('0x61')](_0xb2ad1('0x1a'),JSON[_0xb2ad1('0x60')](_0x14d401));});},exports['outbound']=function(_0x41d8dd,_0x47fc0d,_0x1dc1fa,_0x21ce06,_0x1c06a6,_0x456d44,_0x68fd8e){const _0x414274=_0x37098b;let _0x374e3d,_0x304ffc;return _0x456d44[_0x414274('0x54')]=intUtil['stripTrailingSlash'](_0x456d44['remoteUri']),_0x456d44[_0x414274('0x19')]=intUtil[_0x414274('0x1f')](_0x456d44[_0x414274('0x19')]),_0x68fd8e&&_0x68fd8e['recordingFormat']&&_0x68fd8e[_0x414274('0x4e')]!==_0x414274('0x39')&&(logger[_0x414274('0xa')](_0x414274('0x25'),_0x414274('0xb')),_0x47fc0d['recordingURL']=util['format'](_0x414274('0x42'),_0x456d44[_0x414274('0x19')],_0x47fc0d['uniqueid'],md5(_0x47fc0d[_0x414274('0x53')]))),headers[_0x414274('0x51')]=getAuth(_0x456d44),getUser(_0x456d44,_0x21ce06['email'])[_0x414274('0x33')](function(_0x455874){const _0x32a6f9=_0x414274;return _0x374e3d=_0x455874,logger[_0x32a6f9('0xa')](_0x32a6f9('0x41'),_0x374e3d['id']),getEndUser(_0x456d44,_0x47fc0d['destcalleridname'],_0x47fc0d[_0x32a6f9('0x6')]);})[_0x414274('0x33')](function(_0x12223d){const _0x43e165=_0x414274;return _0x304ffc=_0x12223d,logger[_0x43e165('0xa')](_0x43e165('0x15'),_0x304ffc['id']),getTicket(_0x456d44,_0x374e3d,_0x304ffc,_0x1dc1fa,_0x47fc0d);})[_0x414274('0x33')](function(_0x2cc91f){const _0x404e66=_0x414274;if(_0x2cc91f){logger[_0x404e66('0xa')](_0x404e66('0x5e')),logger[_0x404e66('0xa')]('The\x20Ticket\x20ID\x20is:',_0x2cc91f['id']);switch(_0x456d44['type']){case'integrationTab':logger[_0x404e66('0xa')](_0x404e66('0x1a'),_0x404e66('0x32')),emit(util[_0x404e66('0x35')](_0x404e66('0x3b'),_0x21ce06[_0x404e66('0x1d')]),_0x404e66('0x5'),{'recordId':_0x2cc91f['id']});break;case _0x404e66('0x2f'):logger[_0x404e66('0xa')](_0x404e66('0x1a'),_0x404e66('0xd')),emit(util['format'](_0x404e66('0x3b'),_0x21ce06['name']),_0x404e66('0x5a'),{'uri':util['format']('%s/agent/tickets/%s',_0x456d44[_0x404e66('0x54')],_0x2cc91f['id'])});break;default:logger['error'](_0x404e66('0x25'),'Desk\x20account\x20type\x20not\x20recognized');}}})['catch'](function(_0x36a0db){const _0x2a097b=_0x414274;logger[_0x2a097b('0x61')](_0x2a097b('0x25'),JSON['stringify'](_0x36a0db));});},exports[_0x37098b('0x2e')]=function(_0x5f59da,_0x428736,_0x1b75af,_0x5d397d,_0x358f10,_0x5a9b8d){const _0x48e51b=_0x37098b;let _0x3e9667,_0x4275b2;return _0x5a9b8d[_0x48e51b('0x54')]=intUtil['stripTrailingSlash'](_0x5a9b8d[_0x48e51b('0x54')]),_0x5a9b8d[_0x48e51b('0x19')]=intUtil[_0x48e51b('0x1f')](_0x5a9b8d[_0x48e51b('0x19')]),_0x358f10&&_0x358f10[_0x48e51b('0x10')]?(logger[_0x48e51b('0xa')]('['+_0x428736[_0x48e51b('0x18')]['toUpperCase']()+']',_0x48e51b('0xb')),_0x428736[_0x48e51b('0x46')]=util[_0x48e51b('0x35')](_0x48e51b('0x42'),_0x5a9b8d[_0x48e51b('0x19')],_0x428736[_0x48e51b('0x53')],md5(_0x428736[_0x48e51b('0x53')]))):_0x428736[_0x48e51b('0x46')]='',headers[_0x48e51b('0x51')]=getAuth(_0x5a9b8d),getUser(_0x5a9b8d)['then'](function(_0x565406){const _0x3a3918=_0x48e51b;return _0x3e9667=_0x565406,logger[_0x3a3918('0xa')]('The\x20User\x20ID\x20is:',_0x3e9667['id']),getEndUser(_0x5a9b8d,_0x428736[_0x3a3918('0x56')],_0x428736[_0x3a3918('0x3a')]);})[_0x48e51b('0x33')](function(_0xbb3a9c){const _0x479b74=_0x48e51b;return _0x4275b2=_0xbb3a9c,logger[_0x479b74('0xa')]('The\x20Enduser\x20ID\x20is:',_0x4275b2['id']),getTicket(_0x5a9b8d,_0x3e9667,_0x4275b2,_0x1b75af,_0x428736);})[_0x48e51b('0x33')](function(_0x1b0ee9){const _0x388fb9=_0x48e51b;_0x1b0ee9&&(logger[_0x388fb9('0xa')](_0x388fb9('0x5e')),logger['info'](_0x388fb9('0x13'),_0x1b0ee9['id']));})[_0x48e51b('0x31')](function(_0x560ec0){const _0x17a11a=_0x48e51b;logger[_0x17a11a('0x61')]('['+_0x428736[_0x17a11a('0x18')][_0x17a11a('0x1')]()+']',JSON[_0x17a11a('0x60')](_0x560ec0));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/dynamics365.js b/server/services/ami/trigger/integration/dynamics365.js index f5f8464..a22326e 100644 --- a/server/services/ami/trigger/integration/dynamics365.js +++ b/server/services/ami/trigger/integration/dynamics365.js @@ -1 +1 @@ -const a1137_0x4481=['recordingURL','serverUrl','ticketType','outbound','/contacts(',']\x20Agent\x20found\x20',']\x20The\x20Enduser\x20phone\x20is:','queue',']\x20The\x20User\x20email\x20is:','type','%s/api/data/v9.0/','contacts?$select=telephone1','customField','format','systemusers?$select=internalemailaddress,isdisabled,systemuserid','phonecalls','enduserId','nameField','catch','user:%s','lastIndexOf','Displaying\x20call\x20in\x20a\x20new\x20tab...','unmanaged','recordingFormat','contacts','substring','Descriptions','length','Bearer\x20','destcalleridnum','request-promise-native',']\x20The\x20User\x20ID\x20is:','[OUTBOUND]',']\x20Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!','incident',']\x20The\x20%s\x20ID\x20is:\x20%s','phonecall','toUpperCase','then','validateEmail','password','POST','./util','ticketId','getString','isdisabled','headers','clientId','/systemusers(','access_token','calleridnum','inspect','email','monitor_format','none',']\x20Wrong\x20credentials!','string','remoteUri','message','internalemailaddress','userEmail','odata-entityid','callDirection','%s/main.aspx?pagetype=entityrecord&etn=%s&id=%s','value','GET','tenantId','indexOf','[QUEUE]','../../../../config/logger','Subjects','assign',']\x20Error\x20running\x20Dynamics365\x20integration','emit',']\x20The\x20Enduser\x20ID\x20is:','info','systemuserid','4.0','md5','util','stripTrailingSlash','error','username','userId','isNil','toLowerCase'];(function(_0x5071c3,_0x448116){const _0x3fcc65=function(_0x17d6e1){while(--_0x17d6e1){_0x5071c3['push'](_0x5071c3['shift']());}};_0x3fcc65(++_0x448116);}(a1137_0x4481,0x145));const a1137_0x3fcc=function(_0x5071c3,_0x448116){_0x5071c3=_0x5071c3-0x0;let _0x3fcc65=a1137_0x4481[_0x5071c3];return _0x3fcc65;};const _0x4d917d=a1137_0x3fcc;'use strict';const _=require('lodash'),rp=require(_0x4d917d('0x31')),util=require(_0x4d917d('0xc')),intUtil=require(_0x4d917d('0x3d')),md5=require(_0x4d917d('0xb')),logger=require(_0x4d917d('0x2'))('dynamics365'),{getSocket}=require('../../../../rediscache'),io=getSocket();function getAuthToken(_0x17d6e1,_0x36efeb,_0x45ecd7){const _0x56891e=_0x4d917d,_0x3fc73c={'method':_0x56891e('0x3c'),'uri':_0x36efeb,'form':{'client_id':_0x17d6e1[_0x56891e('0x42')],'resource':_0x17d6e1[_0x56891e('0x4c')],'username':_0x17d6e1[_0x56891e('0xf')],'password':_0x17d6e1[_0x56891e('0x3b')],'grant_type':_0x56891e('0x3b'),'client_secret':_0x17d6e1['clientSecret']},'json':!![]};return rp(_0x3fc73c)['then'](function(_0x45e4ee){const _0x288ca0=_0x56891e;return _0x45e4ee[_0x288ca0('0x44')];})['catch'](function(_0x10bcb5){const _0x30b239=_0x56891e;return logger[_0x30b239('0xe')]('['+[_0x45ecd7[_0x30b239('0x38')]()]+_0x30b239('0x4a')),_0x10bcb5[_0x30b239('0x4d')];});}function getUser(_0x162336,_0x25ca52,_0xdf593f,_0x2f2554,_0x6a886c,_0x5a9665){return new Promise(function(_0x4b5942,_0x595b61){const _0x5f5500=a1137_0x3fcc;return getAuthToken(_0x25ca52,_0x2f2554,_0x5a9665)['then'](function(_0x99c792){const _0x27c352=a1137_0x3fcc,_0x19a4ff={'method':_0x27c352('0x54'),'uri':_0x6a886c+_0x27c352('0x21'),'headers':{'Authorization':'Bearer\x20'+_0x99c792,'OData-Version':'4.0'},'json':!![]};return rp(_0x19a4ff);})[_0x5f5500('0x39')](function(_0x4800e0){const _0x3399e3=_0x5f5500,_0x2cde71=_0x4800e0[_0x3399e3('0x53')];let _0xe196a9=![],_0x217ec4=null;if(!_[_0x3399e3('0x11')](_0xdf593f)){if(intUtil[_0x3399e3('0x3a')](_0xdf593f['email'])){_0x162336[_0x3399e3('0x4f')]=_0xdf593f[_0x3399e3('0x47')];for(_0x217ec4=0x0;_0x217ec4<_0x2cde71[_0x3399e3('0x2e')];_0x217ec4++){_0x2cde71[_0x217ec4]['internalemailaddress']===_0xdf593f['email']&&!_0x2cde71[_0x217ec4][_0x3399e3('0x40')]&&(_0xe196a9=!![],logger[_0x3399e3('0x8')]('['+[_0x5a9665[_0x3399e3('0x38')]()]+_0x3399e3('0x18')+_0x2cde71[_0x217ec4][_0x3399e3('0x9')]+'!'),_0x162336[_0x3399e3('0x10')]=_0x2cde71[_0x217ec4]['systemuserid']);}}}if(!_0xe196a9){logger[_0x3399e3('0x8')]('['+[_0x5a9665['toUpperCase']()]+_0x3399e3('0x34')),_0x162336[_0x3399e3('0x4f')]=_0x25ca52[_0x3399e3('0xf')];for(_0x217ec4=0x0;_0x217ec4<_0x2cde71[_0x3399e3('0x2e')];_0x217ec4++){_0x2cde71[_0x217ec4][_0x3399e3('0x4e')]===_0x25ca52[_0x3399e3('0xf')]&&(_0x162336[_0x3399e3('0x10')]=_0x2cde71[_0x217ec4][_0x3399e3('0x9')]);}}_0x4b5942(_0x162336);})[_0x5f5500('0x25')](function(_0x104a82){const _0x2d0047=_0x5f5500;_0x595b61(_0x104a82[_0x2d0047('0x4d')]);});});}function createEndUser(_0x45406d,_0x18f197,_0xa1f98e,_0x46fba9,_0x56fca9,_0x146a47){return new Promise(function(_0x49ef50,_0x888662){const _0x3c9669=a1137_0x3fcc;return getAuthToken(_0x18f197,_0xa1f98e,_0x146a47)[_0x3c9669('0x39')](function(_0x5bbda1){const _0x2d96d5=_0x3c9669,_0x1f4707=_0x146a47[_0x2d96d5('0x12')]()===_0x2d96d5('0x16')?_0x56fca9[_0x2d96d5('0x30')]:_0x56fca9['calleridnum'],_0xabed41={'method':'POST','uri':_0x46fba9+_0x2d96d5('0x2b'),'body':{'telephone1':_0x1f4707,'fullname':_0x1f4707,'firstname':_0x1f4707,'lastname':'_','mobilephone':null,'address1_telephone1':null,'ownerid@odata.bind':_0x2d96d5('0x43')+_0x45406d[_0x2d96d5('0x10')]+')'},'headers':{'Authorization':_0x2d96d5('0x2f')+_0x5bbda1,'OData-Version':_0x2d96d5('0xa')},'json':!![],'resolveWithFullResponse':!![]};return rp(_0xabed41);})[_0x3c9669('0x39')](function(_0x53af9b){const _0x103f77=_0x3c9669,_0x56e455=_0x53af9b[_0x103f77('0x41')][_0x103f77('0x50')],_0x5cfddc=_0x56e455[_0x103f77('0x2c')](_0x56e455[_0x103f77('0x27')]('(')+0x1,_0x56e455['lastIndexOf'](')'));_0x45406d[_0x103f77('0x23')]=_0x5cfddc,_0x49ef50(_0x45406d);})['catch'](function(_0x2c5ad3){const _0x238f84=_0x3c9669;_0x888662(_0x2c5ad3[_0x238f84('0x4d')]);});});}function getEndUser(_0xf488f,_0x1ce76e,_0x22783a,_0x548053,_0x15b2ec,_0x309d92){return new Promise(function(_0x516b8a){const _0x319725=a1137_0x3fcc;return getAuthToken(_0x1ce76e,_0x22783a,_0x309d92)[_0x319725('0x39')](function(_0x4f1c1f){const _0x3ca94c=_0x319725,_0x3cb0b3={'method':'GET','uri':_0x548053+_0x3ca94c('0x1e'),'headers':{'Authorization':_0x3ca94c('0x2f')+_0x4f1c1f,'If-None-Match':null,'OData-Version':'4.0'},'json':!![]};return rp(_0x3cb0b3);})['then'](function(_0x594d49){const _0x54d87c=_0x319725;let _0x322232=null;if(_0x594d49){const _0x2a455c=_0x594d49[_0x54d87c('0x53')];let _0x25a990=![];for(_0x322232=0x0;_0x322232<_0x2a455c[_0x54d87c('0x2e')];_0x322232++){const _0x1f883f=_0x309d92[_0x54d87c('0x12')]()===_0x54d87c('0x16')?_0x15b2ec[_0x54d87c('0x30')]:_0x15b2ec[_0x54d87c('0x45')];_0x2a455c[_0x322232]['telephone1']===_0x1f883f&&(_0x25a990=!![],_0xf488f[_0x54d87c('0x23')]=_0x2a455c[_0x322232]['contactid']);}if(_0x25a990)_0x516b8a(_0xf488f);else return createEndUser(_0xf488f,_0x1ce76e,_0x22783a,_0x548053,_0x15b2ec,_0x309d92)[_0x54d87c('0x39')](function(_0x916527){const _0x2ba3c4=_0x54d87c;logger[_0x2ba3c4('0x8')]('['+[_0x309d92['toUpperCase']()]+']\x20Enduser\x20created!',_0x916527[_0x2ba3c4('0x23')]),_0x516b8a(_0x916527);});}else return createEndUser(_0xf488f,_0x1ce76e,_0x22783a,_0x548053,_0x15b2ec,_0x309d92)[_0x54d87c('0x39')](function(_0x305895){const _0x7123dc=_0x54d87c;logger[_0x7123dc('0x8')]('['+[_0x309d92[_0x7123dc('0x38')]()]+']\x20Enduser\x20Created!',_0x305895[_0x7123dc('0x23')]),_0x516b8a(_0x305895);});});});}function getCustomFields(_0x97da7d,_0x89950a,_0x448e2a){const _0x2fab10=_0x4d917d,_0x2a17bc={};return _0x97da7d[_0x2fab10('0x2e')]>0x0&&_['forEach'](_0x97da7d,function(_0x397afd){const _0x2512e6=_0x2fab10;if(_0x397afd[_0x2512e6('0x1c')]===_0x2512e6('0x4b')&&_0x397afd[_0x2512e6('0x24')]&&!_0x397afd[_0x2512e6('0x1f')]){const _0x1a5cea=_0x397afd['idField'][_0x2512e6('0x12')](),_0x52dc58=_0x1a5cea[_0x2512e6('0x2c')](0x0,_0x1a5cea[_0x2512e6('0x0')]('_')),_0x173a29=_0x1a5cea[_0x2512e6('0x2c')](_0x1a5cea[_0x2512e6('0x0')]('_')+0x1);_0x52dc58===_0x448e2a&&(_0x2a17bc[_0x173a29]=_0x397afd['content']);}}),_0x2a17bc;}function getTicket(_0x3be755,_0x360bdb,_0x184384,_0x3a3de7,_0x1711f3,_0x1b3fcc,_0x48b38c){return new Promise(function(_0x20a191,_0x330b1b){const _0x25188f=a1137_0x3fcc;let _0x397543;return getAuthToken(_0x360bdb,_0x184384,_0x48b38c)['then'](function(_0x246bfc){const _0x772f9e=a1137_0x3fcc;return _0x1b3fcc['ticketType']===_0x772f9e('0x35')&&(_0x397543={'method':_0x772f9e('0x3c'),'uri':_0x3a3de7+'incidents','body':Object['assign']({},{'title':intUtil[_0x772f9e('0x3f')](_0x1b3fcc[_0x772f9e('0x3')],_0x1711f3,'\x20'),'description':intUtil['getString'](_0x1b3fcc[_0x772f9e('0x2d')],_0x1711f3,'\x0a'),'customerid_contact@odata.bind':_0x772f9e('0x17')+_0x3be755[_0x772f9e('0x23')]+')','ownerid@odata.bind':_0x772f9e('0x43')+_0x3be755['userId']+')','caseorigincode':'1'},getCustomFields(_0x1b3fcc['Fields'],_0x1711f3,_0x1b3fcc[_0x772f9e('0x15')])),'headers':{'Authorization':_0x772f9e('0x2f')+_0x246bfc,'OData-Version':_0x772f9e('0xa')},'json':!![],'resolveWithFullResponse':!![]}),_0x1b3fcc[_0x772f9e('0x15')]===_0x772f9e('0x37')&&(_0x397543={'method':_0x772f9e('0x3c'),'uri':_0x3a3de7+_0x772f9e('0x22'),'body':Object[_0x772f9e('0x4')]({},{'subject':intUtil[_0x772f9e('0x3f')](_0x1b3fcc[_0x772f9e('0x3')],_0x1711f3,'\x20'),'phonenumber':String(_0x1711f3[_0x772f9e('0x45')]),'description':intUtil[_0x772f9e('0x3f')](_0x1b3fcc[_0x772f9e('0x2d')],_0x1711f3,'\x0a'),'regardingobjectid_contact@odata.bind':'/contacts('+_0x3be755['enduserId']+')','ownerid@odata.bind':'/systemusers('+_0x3be755[_0x772f9e('0x10')]+')','directioncode':_0x3be755[_0x772f9e('0x51')]==='queue'?![]:!![],'phonecall_activity_parties':[{'partyid_systemuser@odata.bind':_0x772f9e('0x43')+_0x3be755[_0x772f9e('0x10')]+')','participationtypemask':_0x3be755[_0x772f9e('0x51')]===_0x772f9e('0x1a')?0x2:0x1},{'partyid_contact@odata.bind':_0x772f9e('0x17')+_0x3be755[_0x772f9e('0x23')]+')','participationtypemask':_0x3be755[_0x772f9e('0x51')]==='queue'?0x1:0x2}]},getCustomFields(_0x1b3fcc['Fields'],_0x1711f3,_0x1b3fcc['ticketType'])),'headers':{'Authorization':_0x772f9e('0x2f')+_0x246bfc,'OData-Version':_0x772f9e('0xa')},'json':!![],'resolveWithFullResponse':!![]}),rp(_0x397543);})[_0x25188f('0x39')](function(_0x3cb404){const _0x2c1b84=_0x25188f,_0xe56393=_0x3cb404['headers'][_0x2c1b84('0x50')],_0x587806=_0xe56393[_0x2c1b84('0x2c')](_0xe56393[_0x2c1b84('0x27')]('(')+0x1,_0xe56393[_0x2c1b84('0x27')](')'));_0x3be755[_0x2c1b84('0x3e')]=_0x587806,_0x20a191(_0x3be755);})[_0x25188f('0x25')](function(_0x20e409){const _0x2500ae=_0x25188f;_0x330b1b(_0x20e409[_0x2500ae('0x4d')]);});});}function emit(_0x542aab,_0x10e99a,_0x54e975,_0x1fa7a9){const _0x55776b=_0x4d917d,_0x50c387={'uri':util[_0x55776b('0x20')](_0x55776b('0x52'),_0x542aab,_0x54e975,_0x1fa7a9)};io['to'](util['format'](_0x55776b('0x26'),_0x10e99a))[_0x55776b('0x6')]('trigger:browser:url',_0x50c387);}exports['cs']=function(_0x23fe6d,_0x2ba25f,_0x3aae32,_0x33a024,_0x1ddbc2,_0x390005,_0x3b1141,_0x1d7cba){const _0x35100e=_0x4d917d,_0x54c757={};_0x390005[_0x35100e('0x4c')]=intUtil[_0x35100e('0xd')](_0x390005[_0x35100e('0x4c')]),_0x390005[_0x35100e('0x14')]=intUtil[_0x35100e('0xd')](_0x390005[_0x35100e('0x14')]),_0x54c757[_0x35100e('0x51')]=_0x1d7cba===_0x35100e('0x1a')||_0x1d7cba===_0x35100e('0x29')?_0x35100e('0x1a'):'outbound';const _0x155294=util[_0x35100e('0x20')](_0x35100e('0x1d'),_0x390005[_0x35100e('0x4c')]),_0x1b951d=util[_0x35100e('0x20')]('https://login.microsoftonline.com/%s/oauth2/token',_0x390005[_0x35100e('0x55')]),_0x59dc1a=util[_0x35100e('0x20')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x390005[_0x35100e('0x14')],_0x2ba25f['uniqueid'],md5(_0x2ba25f['uniqueid']));if(_0x1ddbc2&&_0x1ddbc2[_0x35100e('0x48')])logger[_0x35100e('0x8')](_0x35100e('0x1'),'Recording\x20is\x20enabled!'),_0x2ba25f['recordingURL']=_0x59dc1a;else _0x3b1141&&_0x3b1141['recordingFormat']&&_0x3b1141[_0x35100e('0x2a')]!==_0x35100e('0x49')?(logger['info'](_0x35100e('0x33'),'Recording\x20is\x20enabled!'),_0x2ba25f[_0x35100e('0x13')]=_0x59dc1a):_0x2ba25f[_0x35100e('0x13')]='';return getUser(_0x54c757,_0x390005,_0x33a024,_0x1b951d,_0x155294,_0x1d7cba)['then'](function(_0x2288f4){const _0x55faf5=_0x35100e;return logger[_0x55faf5('0x8')]('['+_0x1d7cba['toUpperCase']()+_0x55faf5('0x32'),_0x2288f4['userId']),logger['info']('['+_0x1d7cba['toUpperCase']()+_0x55faf5('0x1b'),_0x2288f4[_0x55faf5('0x4f')]),getEndUser(_0x2288f4,_0x390005,_0x1b951d,_0x155294,_0x2ba25f,_0x1d7cba);})[_0x35100e('0x39')](function(_0x3427c8){const _0xbd71af=_0x35100e;return logger[_0xbd71af('0x8')]('['+_0x1d7cba[_0xbd71af('0x38')]()+_0xbd71af('0x7'),_0x3427c8[_0xbd71af('0x23')]),logger[_0xbd71af('0x8')]('['+_0x1d7cba[_0xbd71af('0x38')]()+_0xbd71af('0x19'),_0x2ba25f[_0xbd71af('0x45')]),getTicket(_0x3427c8,_0x390005,_0x1b951d,_0x155294,_0x2ba25f,_0x3aae32,_0x1d7cba);})[_0x35100e('0x39')](function(_0x42239d){const _0x1f09ec=_0x35100e;logger[_0x1f09ec('0x8')](util['format']('['+_0x1d7cba['toUpperCase']()+_0x1f09ec('0x36'),_0x3aae32[_0x1f09ec('0x15')],_0x42239d[_0x1f09ec('0x3e')])),logger[_0x1f09ec('0x8')](util[_0x1f09ec('0x20')]('['+_0x1d7cba[_0x1f09ec('0x38')]()+']\x20Call\x20direction:\x20%s',_0x1d7cba)),_0x1d7cba!==_0x1f09ec('0x29')&&(logger[_0x1f09ec('0x8')]('['+_0x1d7cba['toUpperCase']()+']',_0x1f09ec('0x28')),emit(_0x390005[_0x1f09ec('0x4c')],_0x33a024['name'],_0x3aae32['ticketType'],_0x42239d[_0x1f09ec('0x3e')]));})[_0x35100e('0x25')](function(_0x1c2717){const _0x4a8b2f=_0x35100e;logger[_0x4a8b2f('0xe')]('['+_0x1d7cba['toUpperCase']()+_0x4a8b2f('0x5'),util[_0x4a8b2f('0x46')](_0x1c2717,{'showHidden':!![],'depth':null}));});}; \ No newline at end of file +const a1137_0x3fe0=['idField','substring','lodash','[OUTBOUND]','recordingURL','isdisabled','contacts','Descriptions','dynamics365',']\x20Enduser\x20created!','ticketId','%s/api/data/v9.0/',']\x20The\x20%s\x20ID\x20is:\x20%s','/contacts(','message','indexOf','Fields','toLowerCase','systemuserid',']\x20Agent\x20found\x20','assign','lastIndexOf',']\x20The\x20Enduser\x20ID\x20is:','tenantId','unmanaged','GET',']\x20The\x20User\x20email\x20is:','remoteUri','phonecall','email','isNil','info','calleridnum','stripTrailingSlash','incident','ticketType','error','../../../../config/logger','validateEmail','customField','odata-entityid','emit','inspect','content','internalemailaddress',']\x20Error\x20running\x20Dynamics365\x20integration','userId','password',']\x20Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!','Bearer\x20','username','util','Subjects','telephone1','value','getString','nameField','length','then','recordingFormat','systemusers?$select=internalemailaddress,isdisabled,systemuserid','headers','request-promise-native','contacts?$select=telephone1','outbound','forEach','https://login.microsoftonline.com/%s/oauth2/token','name',']\x20Call\x20direction:\x20%s','enduserId','type','serverUrl','Displaying\x20call\x20in\x20a\x20new\x20tab...','format','POST','4.0','md5','toUpperCase','/systemusers(','phonecalls','catch','queue','userEmail','callDirection','uniqueid','user:%s','Recording\x20is\x20enabled!','clientId'];(function(_0xd168f5,_0x3fe08a){const _0x152ede=function(_0x1207bc){while(--_0x1207bc){_0xd168f5['push'](_0xd168f5['shift']());}};_0x152ede(++_0x3fe08a);}(a1137_0x3fe0,0xd6));const a1137_0x152e=function(_0xd168f5,_0x3fe08a){_0xd168f5=_0xd168f5-0x0;let _0x152ede=a1137_0x3fe0[_0xd168f5];return _0x152ede;};const _0x461d94=a1137_0x152e;'use strict';const _=require(_0x461d94('0x34')),rp=require(_0x461d94('0x18')),util=require(_0x461d94('0xd')),intUtil=require('./util'),md5=require(_0x461d94('0x26')),logger=require(_0x461d94('0x57'))(_0x461d94('0x3a')),{getSocket}=require('../../../../rediscache'),io=getSocket();function getAuthToken(_0x1207bc,_0xb0aed6,_0x2f606f){const _0x14bf23=_0x461d94,_0x52fc26={'method':_0x14bf23('0x24'),'uri':_0xb0aed6,'form':{'client_id':_0x1207bc[_0x14bf23('0x31')],'resource':_0x1207bc[_0x14bf23('0x4d')],'username':_0x1207bc[_0x14bf23('0xc')],'password':_0x1207bc[_0x14bf23('0x9')],'grant_type':'password','client_secret':_0x1207bc['clientSecret']},'json':!![]};return rp(_0x52fc26)[_0x14bf23('0x14')](function(_0x23c882){return _0x23c882['access_token'];})[_0x14bf23('0x2a')](function(_0x105575){const _0x2d7bf0=_0x14bf23;return logger[_0x2d7bf0('0x56')]('['+[_0x2f606f['toUpperCase']()]+']\x20Wrong\x20credentials!'),_0x105575[_0x2d7bf0('0x40')];});}function getUser(_0xfa6fe3,_0x175c2d,_0xc89a81,_0x487dd3,_0x145ee9,_0x4b77ac){return new Promise(function(_0x16d8e0,_0x5a1e97){const _0x8ee770=a1137_0x152e;return getAuthToken(_0x175c2d,_0x487dd3,_0x4b77ac)[_0x8ee770('0x14')](function(_0x5324cb){const _0x2fb15c=_0x8ee770,_0xb15045={'method':'GET','uri':_0x145ee9+_0x2fb15c('0x16'),'headers':{'Authorization':'Bearer\x20'+_0x5324cb,'OData-Version':_0x2fb15c('0x25')},'json':!![]};return rp(_0xb15045);})[_0x8ee770('0x14')](function(_0x5e7d0e){const _0x8727ca=_0x8ee770,_0x3eefb0=_0x5e7d0e[_0x8727ca('0x10')];let _0xece1fa=![],_0x3dfe29=null;if(!_[_0x8727ca('0x50')](_0xc89a81)){if(intUtil[_0x8727ca('0x0')](_0xc89a81[_0x8727ca('0x4f')])){_0xfa6fe3[_0x8727ca('0x2c')]=_0xc89a81[_0x8727ca('0x4f')];for(_0x3dfe29=0x0;_0x3dfe29<_0x3eefb0[_0x8727ca('0x13')];_0x3dfe29++){_0x3eefb0[_0x3dfe29][_0x8727ca('0x6')]===_0xc89a81[_0x8727ca('0x4f')]&&!_0x3eefb0[_0x3dfe29][_0x8727ca('0x37')]&&(_0xece1fa=!![],logger['info']('['+[_0x4b77ac[_0x8727ca('0x27')]()]+_0x8727ca('0x45')+_0x3eefb0[_0x3dfe29][_0x8727ca('0x44')]+'!'),_0xfa6fe3[_0x8727ca('0x8')]=_0x3eefb0[_0x3dfe29][_0x8727ca('0x44')]);}}}if(!_0xece1fa){logger['info']('['+[_0x4b77ac['toUpperCase']()]+_0x8727ca('0xa')),_0xfa6fe3[_0x8727ca('0x2c')]=_0x175c2d['username'];for(_0x3dfe29=0x0;_0x3dfe29<_0x3eefb0['length'];_0x3dfe29++){_0x3eefb0[_0x3dfe29][_0x8727ca('0x6')]===_0x175c2d['username']&&(_0xfa6fe3[_0x8727ca('0x8')]=_0x3eefb0[_0x3dfe29][_0x8727ca('0x44')]);}}_0x16d8e0(_0xfa6fe3);})[_0x8ee770('0x2a')](function(_0x3bcf7e){const _0x3c5a6a=_0x8ee770;_0x5a1e97(_0x3bcf7e[_0x3c5a6a('0x40')]);});});}function createEndUser(_0x43df35,_0xe80d52,_0x179879,_0x568242,_0x508c6c,_0x3fb812){return new Promise(function(_0xe628a3,_0x130295){const _0x3a764d=a1137_0x152e;return getAuthToken(_0xe80d52,_0x179879,_0x3fb812)['then'](function(_0x2ff5e8){const _0x21ecaa=a1137_0x152e,_0x3a68c1=_0x3fb812['toLowerCase']()===_0x21ecaa('0x1a')?_0x508c6c['destcalleridnum']:_0x508c6c[_0x21ecaa('0x52')],_0x5c3344={'method':_0x21ecaa('0x24'),'uri':_0x568242+_0x21ecaa('0x38'),'body':{'telephone1':_0x3a68c1,'fullname':_0x3a68c1,'firstname':_0x3a68c1,'lastname':'_','mobilephone':null,'address1_telephone1':null,'ownerid@odata.bind':_0x21ecaa('0x28')+_0x43df35[_0x21ecaa('0x8')]+')'},'headers':{'Authorization':'Bearer\x20'+_0x2ff5e8,'OData-Version':_0x21ecaa('0x25')},'json':!![],'resolveWithFullResponse':!![]};return rp(_0x5c3344);})[_0x3a764d('0x14')](function(_0x5a8a42){const _0x1d23e1=_0x3a764d,_0x2aafa1=_0x5a8a42[_0x1d23e1('0x17')][_0x1d23e1('0x2')],_0x10f2ea=_0x2aafa1[_0x1d23e1('0x33')](_0x2aafa1['lastIndexOf']('(')+0x1,_0x2aafa1['lastIndexOf'](')'));_0x43df35[_0x1d23e1('0x1f')]=_0x10f2ea,_0xe628a3(_0x43df35);})['catch'](function(_0x111f39){const _0x181081=_0x3a764d;_0x130295(_0x111f39[_0x181081('0x40')]);});});}function getEndUser(_0x45af3c,_0x43bc0c,_0x215260,_0x323bd6,_0x57ddb9,_0x1525ca){return new Promise(function(_0x2284ae){const _0x169180=a1137_0x152e;return getAuthToken(_0x43bc0c,_0x215260,_0x1525ca)[_0x169180('0x14')](function(_0xa9aa3e){const _0x14fce2=_0x169180,_0xbfdba8={'method':_0x14fce2('0x4b'),'uri':_0x323bd6+_0x14fce2('0x19'),'headers':{'Authorization':_0x14fce2('0xb')+_0xa9aa3e,'If-None-Match':null,'OData-Version':_0x14fce2('0x25')},'json':!![]};return rp(_0xbfdba8);})['then'](function(_0x269ee7){const _0x365864=_0x169180;let _0x2f44c1=null;if(_0x269ee7){const _0x1a1fec=_0x269ee7[_0x365864('0x10')];let _0x26a58c=![];for(_0x2f44c1=0x0;_0x2f44c1<_0x1a1fec[_0x365864('0x13')];_0x2f44c1++){const _0x541c3b=_0x1525ca[_0x365864('0x43')]()===_0x365864('0x1a')?_0x57ddb9['destcalleridnum']:_0x57ddb9[_0x365864('0x52')];_0x1a1fec[_0x2f44c1][_0x365864('0xf')]===_0x541c3b&&(_0x26a58c=!![],_0x45af3c[_0x365864('0x1f')]=_0x1a1fec[_0x2f44c1]['contactid']);}if(_0x26a58c)_0x2284ae(_0x45af3c);else return createEndUser(_0x45af3c,_0x43bc0c,_0x215260,_0x323bd6,_0x57ddb9,_0x1525ca)[_0x365864('0x14')](function(_0x128f0b){const _0x2531d3=_0x365864;logger['info']('['+[_0x1525ca[_0x2531d3('0x27')]()]+_0x2531d3('0x3b'),_0x128f0b[_0x2531d3('0x1f')]),_0x2284ae(_0x128f0b);});}else return createEndUser(_0x45af3c,_0x43bc0c,_0x215260,_0x323bd6,_0x57ddb9,_0x1525ca)[_0x365864('0x14')](function(_0x933f97){const _0x236301=_0x365864;logger[_0x236301('0x51')]('['+[_0x1525ca[_0x236301('0x27')]()]+']\x20Enduser\x20Created!',_0x933f97[_0x236301('0x1f')]),_0x2284ae(_0x933f97);});});});}function getCustomFields(_0x4bade1,_0x41e6b8,_0x32d7d0){const _0x25fd08=_0x461d94,_0xc92b41={};return _0x4bade1[_0x25fd08('0x13')]>0x0&&_[_0x25fd08('0x1b')](_0x4bade1,function(_0x130fa7){const _0x5247f1=_0x25fd08;if(_0x130fa7[_0x5247f1('0x20')]==='string'&&_0x130fa7[_0x5247f1('0x12')]&&!_0x130fa7[_0x5247f1('0x1')]){const _0x53bcb3=_0x130fa7[_0x5247f1('0x32')][_0x5247f1('0x43')](),_0x25180b=_0x53bcb3[_0x5247f1('0x33')](0x0,_0x53bcb3[_0x5247f1('0x41')]('_')),_0x1aae20=_0x53bcb3[_0x5247f1('0x33')](_0x53bcb3[_0x5247f1('0x41')]('_')+0x1);_0x25180b===_0x32d7d0&&(_0xc92b41[_0x1aae20]=_0x130fa7[_0x5247f1('0x5')]);}}),_0xc92b41;}function getTicket(_0x37ffef,_0x2a6f5d,_0x1c8bc6,_0x1a4a7c,_0x2b0d4c,_0x1dbc5e,_0x1f666c){return new Promise(function(_0x54dbd0,_0x71eb6f){const _0x2ec7e3=a1137_0x152e;let _0x170aee;return getAuthToken(_0x2a6f5d,_0x1c8bc6,_0x1f666c)[_0x2ec7e3('0x14')](function(_0x88647){const _0x15ebcc=_0x2ec7e3;return _0x1dbc5e['ticketType']===_0x15ebcc('0x54')&&(_0x170aee={'method':_0x15ebcc('0x24'),'uri':_0x1a4a7c+'incidents','body':Object[_0x15ebcc('0x46')]({},{'title':intUtil[_0x15ebcc('0x11')](_0x1dbc5e[_0x15ebcc('0xe')],_0x2b0d4c,'\x20'),'description':intUtil['getString'](_0x1dbc5e[_0x15ebcc('0x39')],_0x2b0d4c,'\x0a'),'customerid_contact@odata.bind':_0x15ebcc('0x3f')+_0x37ffef[_0x15ebcc('0x1f')]+')','ownerid@odata.bind':_0x15ebcc('0x28')+_0x37ffef[_0x15ebcc('0x8')]+')','caseorigincode':'1'},getCustomFields(_0x1dbc5e[_0x15ebcc('0x42')],_0x2b0d4c,_0x1dbc5e[_0x15ebcc('0x55')])),'headers':{'Authorization':_0x15ebcc('0xb')+_0x88647,'OData-Version':'4.0'},'json':!![],'resolveWithFullResponse':!![]}),_0x1dbc5e[_0x15ebcc('0x55')]===_0x15ebcc('0x4e')&&(_0x170aee={'method':_0x15ebcc('0x24'),'uri':_0x1a4a7c+_0x15ebcc('0x29'),'body':Object[_0x15ebcc('0x46')]({},{'subject':intUtil[_0x15ebcc('0x11')](_0x1dbc5e['Subjects'],_0x2b0d4c,'\x20'),'phonenumber':String(_0x2b0d4c['calleridnum']),'description':intUtil['getString'](_0x1dbc5e[_0x15ebcc('0x39')],_0x2b0d4c,'\x0a'),'regardingobjectid_contact@odata.bind':_0x15ebcc('0x3f')+_0x37ffef['enduserId']+')','ownerid@odata.bind':_0x15ebcc('0x28')+_0x37ffef[_0x15ebcc('0x8')]+')','directioncode':_0x37ffef['callDirection']===_0x15ebcc('0x2b')?![]:!![],'phonecall_activity_parties':[{'partyid_systemuser@odata.bind':_0x15ebcc('0x28')+_0x37ffef[_0x15ebcc('0x8')]+')','participationtypemask':_0x37ffef[_0x15ebcc('0x2d')]===_0x15ebcc('0x2b')?0x2:0x1},{'partyid_contact@odata.bind':_0x15ebcc('0x3f')+_0x37ffef[_0x15ebcc('0x1f')]+')','participationtypemask':_0x37ffef[_0x15ebcc('0x2d')]==='queue'?0x1:0x2}]},getCustomFields(_0x1dbc5e[_0x15ebcc('0x42')],_0x2b0d4c,_0x1dbc5e[_0x15ebcc('0x55')])),'headers':{'Authorization':'Bearer\x20'+_0x88647,'OData-Version':_0x15ebcc('0x25')},'json':!![],'resolveWithFullResponse':!![]}),rp(_0x170aee);})[_0x2ec7e3('0x14')](function(_0x138190){const _0x47c46e=_0x2ec7e3,_0x3ef518=_0x138190['headers'][_0x47c46e('0x2')],_0x3afea6=_0x3ef518[_0x47c46e('0x33')](_0x3ef518[_0x47c46e('0x47')]('(')+0x1,_0x3ef518['lastIndexOf'](')'));_0x37ffef[_0x47c46e('0x3c')]=_0x3afea6,_0x54dbd0(_0x37ffef);})[_0x2ec7e3('0x2a')](function(_0x26df29){const _0x58db59=_0x2ec7e3;_0x71eb6f(_0x26df29[_0x58db59('0x40')]);});});}function emit(_0x266b16,_0x1d1cb7,_0x4bccab,_0x1537a3){const _0x1c1e1b=_0x461d94,_0x4d9221={'uri':util[_0x1c1e1b('0x23')]('%s/main.aspx?pagetype=entityrecord&etn=%s&id=%s',_0x266b16,_0x4bccab,_0x1537a3)};io['to'](util[_0x1c1e1b('0x23')](_0x1c1e1b('0x2f'),_0x1d1cb7))[_0x1c1e1b('0x3')]('trigger:browser:url',_0x4d9221);}exports['cs']=function(_0x303a51,_0x22aa08,_0x2c8f61,_0x51b789,_0x3a2f94,_0x43413f,_0x94b103,_0x1487d9){const _0x5ae3e4=_0x461d94,_0x10f763={};_0x43413f[_0x5ae3e4('0x4d')]=intUtil[_0x5ae3e4('0x53')](_0x43413f[_0x5ae3e4('0x4d')]),_0x43413f[_0x5ae3e4('0x21')]=intUtil['stripTrailingSlash'](_0x43413f[_0x5ae3e4('0x21')]),_0x10f763[_0x5ae3e4('0x2d')]=_0x1487d9===_0x5ae3e4('0x2b')||_0x1487d9===_0x5ae3e4('0x4a')?'queue':_0x5ae3e4('0x1a');const _0x2a1cf6=util[_0x5ae3e4('0x23')](_0x5ae3e4('0x3d'),_0x43413f[_0x5ae3e4('0x4d')]),_0x291289=util[_0x5ae3e4('0x23')](_0x5ae3e4('0x1c'),_0x43413f[_0x5ae3e4('0x49')]),_0x328e5d=util[_0x5ae3e4('0x23')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x43413f[_0x5ae3e4('0x21')],_0x22aa08['uniqueid'],md5(_0x22aa08[_0x5ae3e4('0x2e')]));if(_0x3a2f94&&_0x3a2f94['monitor_format'])logger[_0x5ae3e4('0x51')]('[QUEUE]',_0x5ae3e4('0x30')),_0x22aa08[_0x5ae3e4('0x36')]=_0x328e5d;else _0x94b103&&_0x94b103['recordingFormat']&&_0x94b103[_0x5ae3e4('0x15')]!=='none'?(logger[_0x5ae3e4('0x51')](_0x5ae3e4('0x35'),_0x5ae3e4('0x30')),_0x22aa08[_0x5ae3e4('0x36')]=_0x328e5d):_0x22aa08[_0x5ae3e4('0x36')]='';return getUser(_0x10f763,_0x43413f,_0x51b789,_0x291289,_0x2a1cf6,_0x1487d9)[_0x5ae3e4('0x14')](function(_0x2f297d){const _0x32a02e=_0x5ae3e4;return logger[_0x32a02e('0x51')]('['+_0x1487d9[_0x32a02e('0x27')]()+']\x20The\x20User\x20ID\x20is:',_0x2f297d[_0x32a02e('0x8')]),logger[_0x32a02e('0x51')]('['+_0x1487d9[_0x32a02e('0x27')]()+_0x32a02e('0x4c'),_0x2f297d[_0x32a02e('0x2c')]),getEndUser(_0x2f297d,_0x43413f,_0x291289,_0x2a1cf6,_0x22aa08,_0x1487d9);})[_0x5ae3e4('0x14')](function(_0x580133){const _0x600f74=_0x5ae3e4;return logger[_0x600f74('0x51')]('['+_0x1487d9[_0x600f74('0x27')]()+_0x600f74('0x48'),_0x580133[_0x600f74('0x1f')]),logger['info']('['+_0x1487d9['toUpperCase']()+']\x20The\x20Enduser\x20phone\x20is:',_0x22aa08['calleridnum']),getTicket(_0x580133,_0x43413f,_0x291289,_0x2a1cf6,_0x22aa08,_0x2c8f61,_0x1487d9);})[_0x5ae3e4('0x14')](function(_0x277cc3){const _0xadb728=_0x5ae3e4;logger['info'](util['format']('['+_0x1487d9[_0xadb728('0x27')]()+_0xadb728('0x3e'),_0x2c8f61[_0xadb728('0x55')],_0x277cc3[_0xadb728('0x3c')])),logger[_0xadb728('0x51')](util[_0xadb728('0x23')]('['+_0x1487d9['toUpperCase']()+_0xadb728('0x1e'),_0x1487d9)),_0x1487d9!==_0xadb728('0x4a')&&(logger['info']('['+_0x1487d9['toUpperCase']()+']',_0xadb728('0x22')),emit(_0x43413f['remoteUri'],_0x51b789[_0xadb728('0x1d')],_0x2c8f61['ticketType'],_0x277cc3[_0xadb728('0x3c')]));})[_0x5ae3e4('0x2a')](function(_0x1a9a4c){const _0x470f63=_0x5ae3e4;logger['error']('['+_0x1487d9[_0x470f63('0x27')]()+_0x470f63('0x7'),util[_0x470f63('0x4')](_0x1a9a4c,{'showHidden':!![],'depth':null}));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/freshdesk.js b/server/services/ami/trigger/integration/freshdesk.js index 3ca45f1..17d8e7d 100644 --- a/server/services/ami/trigger/integration/freshdesk.js +++ b/server/services/ami/trigger/integration/freshdesk.js @@ -1 +1 @@ -const a1138_0x2803=['Basic\x20%s','Agent\x20found!','
','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','%s/api/v2/agents','catch','GET','lodash','The\x20Ticket\x20ID\x20is:','nameField','keyBy','Admin\x20account\x20selected.','defaults','util','find','Creating\x20new\x20ticket...','map','variableName','forEach','[OUTBOUND]','Searching\x20enduser\x20with\x20phone','Variable','%s/helpdesk/tickets/%d','recordingFormat','Descriptions','Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...','string','%s/api/v2/contacts','toString','email','mapValues','Caller\x20-\x20%s','[QUEUE]','push','uniqueid','then','destcalleridnum','content','calleridname','./util','Ticket\x20created!','md5','Recording\x20is\x20enabled!','lastevent','queue','The\x20Enduser\x20ID\x20is:','type','%s/api/v2/agents/me','[HTTP]','stripTrailingSlash','base64','recordingURL','Tags','%s/api/v2/tickets','Subjects','monitor_format','request-promise-native','length','error','name','none','emit','getString','toLowerCase','destcalleridname','format','toUpperCase','stringify','calleridnum','validateEmail','application/json','custom_fields','user:%s','idField','trigger:browser:url','customField','The\x20User\x20ID\x20is:','serverUrl','remoteUri','Enduser\x20not\x20found,\x20creating\x20a\x20new\x20enduser!','Authorization','value','info'];(function(_0x2ed571,_0x280391){const _0x599efd=function(_0x2db429){while(--_0x2db429){_0x2ed571['push'](_0x2ed571['shift']());}};_0x599efd(++_0x280391);}(a1138_0x2803,0x122));const a1138_0x599e=function(_0x2ed571,_0x280391){_0x2ed571=_0x2ed571-0x0;let _0x599efd=a1138_0x2803[_0x2ed571];return _0x599efd;};const _0x147c97=a1138_0x599e;'use strict';const _=require(_0x147c97('0x31')),rp=require(_0x147c97('0xf')),md5=require(_0x147c97('0x0')),util=require(_0x147c97('0x37')),intUtil=require(_0x147c97('0x51')),logger=require('../../../../config/logger')('freshdesk'),{getSocket}=require('../../../../rediscache'),io=getSocket(),headers={'Content-Type':'application/json','Accept':_0x147c97('0x1d')};function emit(_0x2db429,_0x24dc61,_0x11b2b7){const _0x27278c=_0x147c97;io['to'](_0x2db429)[_0x27278c('0x14')](_0x24dc61,_0x11b2b7);}function getTicket(_0x414192,_0x53bd37,_0x404da5,_0x35be82,_0x30d803){const _0x3636aa=_0x147c97;logger[_0x3636aa('0x29')](_0x3636aa('0x39'));const _0x2141b1=_['merge']({'responder_id':_0x53bd37['id'],'requester_id':_0x404da5['id'],'name':util[_0x3636aa('0x18')](_0x3636aa('0x49'),_0x30d803['calleridname']),'phone':_0x30d803['calleridnum'],'source':0x3,'priority':0x1,'status':0x2,'subject':intUtil[_0x3636aa('0x15')](_0x35be82[_0x3636aa('0xd')],_0x30d803,'\x20'),'description':intUtil[_0x3636aa('0x15')](_0x35be82[_0x3636aa('0x42')],_0x30d803,_0x3636aa('0x2c')),'tags':getTags(_0x35be82[_0x3636aa('0xb')],'name')},getCustomFields(_0x35be82['Fields'],_0x30d803));return _0x2141b1['custom_fields']=_[_0x3636aa('0x48')](_[_0x3636aa('0x34')](_0x2141b1[_0x3636aa('0x1e')],'id'),_0x3636aa('0x28')),request({'uri':util[_0x3636aa('0x18')](_0x3636aa('0xc'),_0x414192[_0x3636aa('0x25')]),'method':'POST','body':_0x2141b1})[_0x3636aa('0x4d')](function(_0x17dca2){const _0x596544=_0x3636aa;return logger[_0x596544('0x29')]('Ticket\x20created!'),_0x17dca2;});}function getUser(_0x1f7d32,_0x35595d){const _0x47b5f0=_0x147c97;return intUtil[_0x47b5f0('0x1c')](_0x35595d)?request({'uri':util[_0x47b5f0('0x18')](_0x47b5f0('0x2e'),_0x1f7d32[_0x47b5f0('0x25')]),'qs':{'email':_0x35595d}})[_0x47b5f0('0x4d')](function(_0x3e8394){const _0x33181f=_0x47b5f0;return _0x3e8394[_0x33181f('0x10')]?(logger[_0x33181f('0x29')](_0x33181f('0x2b')),_[_0x33181f('0x38')](_0x3e8394,function(_0x4b66f9){const _0x26a830=_0x33181f;return _0x4b66f9['contact'][_0x26a830('0x47')]===_0x35595d;})):(logger[_0x33181f('0x29')]('Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!'),request({'uri':util[_0x33181f('0x18')](_0x33181f('0x6'),_0x1f7d32[_0x33181f('0x25')])})[_0x33181f('0x4d')](function(_0x51b2e8){const _0x5978c6=_0x33181f;return logger['info'](_0x5978c6('0x35')),_0x51b2e8;}));}):(logger[_0x47b5f0('0x29')]('Invalid\x20email\x20format,\x20using\x20the\x20admin\x20account!'),request({'uri':util[_0x47b5f0('0x18')](_0x47b5f0('0x6'),_0x1f7d32[_0x47b5f0('0x25')])})[_0x47b5f0('0x4d')](function(_0x5065cb){const _0x4e8138=_0x47b5f0;return logger['info'](_0x4e8138('0x35')),_0x5065cb;}));}function getEndUser(_0x1038e9,_0x84b864,_0x12df5b){const _0x589c45=_0x147c97;return logger[_0x589c45('0x29')](_0x589c45('0x3e'),_0x12df5b),request({'uri':util[_0x589c45('0x18')]('%s/api/v2/contacts',_0x1038e9['remoteUri']),'qs':{'phone':_0x12df5b}})[_0x589c45('0x4d')](function(_0x13de93){const _0x5b639c=_0x589c45;return _0x13de93[_0x5b639c('0x10')]?(logger[_0x5b639c('0x29')]('Enduser\x20found!'),_[_0x5b639c('0x38')](_0x13de93,{'phone':_0x12df5b})):(logger[_0x5b639c('0x29')](_0x5b639c('0x26')),request({'uri':util[_0x5b639c('0x18')](_0x5b639c('0x45'),_0x1038e9[_0x5b639c('0x25')]),'method':'POST','body':{'name':_0x84b864,'phone':_0x12df5b}})[_0x5b639c('0x4d')](function(_0x327c28){const _0x1772f5=_0x5b639c;return logger[_0x1772f5('0x29')]('Enduser\x20created.'),_0x327c28;}));});}function getAuth(_0x159e8a){const _0x36fd9f=_0x147c97;return util['format'](_0x36fd9f('0x2a'),Buffer['from'](_0x159e8a['apiKey']+':X')['toString'](_0x36fd9f('0x9')));}function request(_0x4c945d){const _0x1ab886=_0x147c97;return logger['debug'](_0x1ab886('0x7'),JSON[_0x1ab886('0x1a')](_0x4c945d)),rp(_[_0x1ab886('0x36')](_0x4c945d,{'method':_0x1ab886('0x30'),'headers':headers,'json':!![]}));}function getTags(_0x2bcd59,_0x27a36d){const _0x330c5e=_0x147c97;let _0x1ae0f9=[];return _0x2bcd59&&_0x2bcd59['length']>0x0&&(_0x1ae0f9=_[_0x330c5e('0x3a')](_0x2bcd59,_0x27a36d)),_0x1ae0f9;}function getCustomFields(_0x3fc399,_0x38b4e9){const _0xf429f0=_0x147c97,_0x4dfd8d={'custom_fields':[]};return _0x3fc399[_0xf429f0('0x10')]>0x0&&_[_0xf429f0('0x3c')](_0x3fc399,function(_0x5061a0){const _0x18d780=_0xf429f0;if(_0x5061a0[_0x18d780('0x5')]===_0x18d780('0x44')&&_0x5061a0[_0x18d780('0x33')]&&!_0x5061a0[_0x18d780('0x22')])_0x4dfd8d[_0x5061a0[_0x18d780('0x33')][_0x18d780('0x16')]()]=_0x5061a0[_0x18d780('0x4f')][_0x18d780('0x46')]();else{if(_0x5061a0[_0x18d780('0x5')]==='string'&&_0x5061a0['idField']&&_0x5061a0[_0x18d780('0x22')])_0x4dfd8d[_0x18d780('0x1e')]['push']({'id':_0x5061a0[_0x18d780('0x20')],'value':_0x5061a0[_0x18d780('0x4f')][_0x18d780('0x46')]()});else{if(_0x5061a0[_0x18d780('0x5')]==='variable'&&_0x5061a0[_0x18d780('0x3b')]&&_0x5061a0[_0x18d780('0x20')]&&_0x5061a0[_0x18d780('0x22')])_0x38b4e9[_0x5061a0[_0x18d780('0x3b')]]&&_0x4dfd8d[_0x18d780('0x1e')][_0x18d780('0x4b')]({'id':_0x5061a0[_0x18d780('0x20')],'value':_0x38b4e9[_0x5061a0['variableName']][_0x18d780('0x46')]()});else _0x5061a0[_0x18d780('0x5')]==='customVariable'&&_0x5061a0[_0x18d780('0x3f')]&&_0x5061a0['Variable'][_0x18d780('0x12')]&&_0x5061a0['idField']&&_0x5061a0[_0x18d780('0x22')]&&(_0x38b4e9[_0x5061a0[_0x18d780('0x3f')]['name'][_0x18d780('0x16')]()]&&_0x4dfd8d[_0x18d780('0x1e')][_0x18d780('0x4b')]({'id':_0x5061a0[_0x18d780('0x20')],'value':_0x38b4e9[_0x5061a0[_0x18d780('0x3f')][_0x18d780('0x12')][_0x18d780('0x16')]()][_0x18d780('0x46')]()}));}}}),_0x4dfd8d;}exports[_0x147c97('0x3')]=function(_0x2e7958,_0x480b99,_0x37932b,_0x22578a,_0x4ebc4d,_0x30c8c4){const _0x1f907b=_0x147c97;let _0x570697,_0xda8ae2;return _0x30c8c4[_0x1f907b('0x25')]=intUtil['stripTrailingSlash'](_0x30c8c4[_0x1f907b('0x25')]),_0x30c8c4[_0x1f907b('0x24')]=intUtil[_0x1f907b('0x8')](_0x30c8c4['serverUrl']),_0x4ebc4d&&_0x4ebc4d[_0x1f907b('0xe')]?(logger[_0x1f907b('0x29')](_0x1f907b('0x4a'),_0x1f907b('0x1')),_0x480b99[_0x1f907b('0xa')]=util[_0x1f907b('0x18')](_0x1f907b('0x2d'),_0x30c8c4[_0x1f907b('0x24')],_0x480b99[_0x1f907b('0x4c')],md5(_0x480b99[_0x1f907b('0x4c')]))):_0x480b99[_0x1f907b('0xa')]='',headers[_0x1f907b('0x27')]=getAuth(_0x30c8c4),getUser(_0x30c8c4,_0x22578a[_0x1f907b('0x47')])['then'](function(_0x3f1f22){const _0x1c52eb=_0x1f907b;return _0x570697=_0x3f1f22,logger[_0x1c52eb('0x29')]('The\x20User\x20ID\x20is:',_0x570697['id']),getEndUser(_0x30c8c4,_0x480b99[_0x1c52eb('0x50')],_0x480b99[_0x1c52eb('0x1b')]);})[_0x1f907b('0x4d')](function(_0x4fa7b8){const _0x5dfe40=_0x1f907b;return _0xda8ae2=_0x4fa7b8,logger[_0x5dfe40('0x29')](_0x5dfe40('0x4'),_0xda8ae2['id']),getTicket(_0x30c8c4,_0x570697,_0xda8ae2,_0x37932b,_0x480b99);})[_0x1f907b('0x4d')](function(_0x3c18ed){const _0x222382=_0x1f907b;_0x3c18ed&&_0x3c18ed['id']&&(logger[_0x222382('0x29')](_0x222382('0x52')),logger['info'](_0x222382('0x32'),_0x3c18ed['id']),logger[_0x222382('0x29')](_0x222382('0x4a'),_0x222382('0x43')),emit(util[_0x222382('0x18')](_0x222382('0x1f'),_0x22578a[_0x222382('0x12')]),'trigger:browser:url',{'uri':util['format'](_0x222382('0x40'),_0x30c8c4[_0x222382('0x25')],_0x3c18ed['id'])}));})[_0x1f907b('0x2f')](function(_0x15aaee){const _0xc9943=_0x1f907b;logger['error'](_0xc9943('0x4a'),JSON[_0xc9943('0x1a')](_0x15aaee));});},exports['outbound']=function(_0x4b54b7,_0xd1c855,_0x41cb72,_0x50609b,_0x101a45,_0x58fa86,_0x349e0f){const _0x29de59=_0x147c97;let _0xf5563f,_0x550cda;return _0x58fa86[_0x29de59('0x25')]=intUtil['stripTrailingSlash'](_0x58fa86[_0x29de59('0x25')]),_0x58fa86['serverUrl']=intUtil[_0x29de59('0x8')](_0x58fa86[_0x29de59('0x24')]),_0x349e0f&&_0x349e0f[_0x29de59('0x41')]&&_0x349e0f[_0x29de59('0x41')]!==_0x29de59('0x13')&&(logger[_0x29de59('0x29')]('[OUTBOUND]',_0x29de59('0x1')),_0xd1c855[_0x29de59('0xa')]=util[_0x29de59('0x18')](_0x29de59('0x2d'),_0x58fa86[_0x29de59('0x24')],_0xd1c855[_0x29de59('0x4c')],md5(_0xd1c855['uniqueid']))),headers[_0x29de59('0x27')]=getAuth(_0x58fa86),getUser(_0x58fa86,_0x50609b[_0x29de59('0x47')])[_0x29de59('0x4d')](function(_0x3a6ff5){const _0x4f6905=_0x29de59;return _0xf5563f=_0x3a6ff5,logger[_0x4f6905('0x29')](_0x4f6905('0x23'),_0xf5563f['id']),getEndUser(_0x58fa86,_0xd1c855[_0x4f6905('0x17')],_0xd1c855[_0x4f6905('0x4e')]);})[_0x29de59('0x4d')](function(_0x14d7ab){const _0x51210d=_0x29de59;return _0x550cda=_0x14d7ab,logger[_0x51210d('0x29')](_0x51210d('0x4'),_0x550cda['id']),getTicket(_0x58fa86,_0xf5563f,_0x550cda,_0x41cb72,_0xd1c855);})['then'](function(_0x23d5f3){const _0x5e2236=_0x29de59;_0x23d5f3&&_0x23d5f3['id']&&(logger[_0x5e2236('0x29')](_0x5e2236('0x52')),logger['info']('The\x20Ticket\x20ID\x20is:',_0x23d5f3['id']),logger[_0x5e2236('0x29')](_0x5e2236('0x3d'),_0x5e2236('0x43')),emit(util[_0x5e2236('0x18')]('user:%s',_0x50609b[_0x5e2236('0x12')]),_0x5e2236('0x21'),{'uri':util[_0x5e2236('0x18')](_0x5e2236('0x40'),_0x58fa86[_0x5e2236('0x25')],_0x23d5f3['id'])}));})[_0x29de59('0x2f')](function(_0x1f06fa){const _0x27cc6c=_0x29de59;logger[_0x27cc6c('0x11')](_0x27cc6c('0x3d'),JSON[_0x27cc6c('0x1a')](_0x1f06fa));});},exports['unmanaged']=function(_0x387cb2,_0x2f46b3,_0x2416e5,_0x49114e,_0x327bdd,_0x1a0a54){const _0x5659b9=_0x147c97;let _0x29943e,_0x4131c3;return _0x1a0a54[_0x5659b9('0x25')]=intUtil[_0x5659b9('0x8')](_0x1a0a54[_0x5659b9('0x25')]),_0x1a0a54[_0x5659b9('0x24')]=intUtil[_0x5659b9('0x8')](_0x1a0a54[_0x5659b9('0x24')]),_0x327bdd&&_0x327bdd['monitor_format']?(logger['info']('['+_0x2f46b3[_0x5659b9('0x2')]['toUpperCase']()+']',_0x5659b9('0x1')),_0x2f46b3[_0x5659b9('0xa')]=util[_0x5659b9('0x18')](_0x5659b9('0x2d'),_0x1a0a54[_0x5659b9('0x24')],_0x2f46b3[_0x5659b9('0x4c')],md5(_0x2f46b3[_0x5659b9('0x4c')]))):_0x2f46b3[_0x5659b9('0xa')]='',headers[_0x5659b9('0x27')]=getAuth(_0x1a0a54),getUser(_0x1a0a54,'')[_0x5659b9('0x4d')](function(_0x4c99bb){const _0x4f26d1=_0x5659b9;return _0x29943e=_0x4c99bb,logger[_0x4f26d1('0x29')](_0x4f26d1('0x23'),_0x29943e['id']),getEndUser(_0x1a0a54,_0x2f46b3['calleridname'],_0x2f46b3[_0x4f26d1('0x1b')]);})[_0x5659b9('0x4d')](function(_0x4c00bf){const _0x1bef50=_0x5659b9;return _0x4131c3=_0x4c00bf,logger[_0x1bef50('0x29')](_0x1bef50('0x4'),_0x4131c3['id']),getTicket(_0x1a0a54,_0x29943e,_0x4131c3,_0x2416e5,_0x2f46b3);})['then'](function(_0xd9507f){const _0x3d8ce3=_0x5659b9;_0xd9507f&&(logger[_0x3d8ce3('0x29')](_0x3d8ce3('0x52')),logger['info'](_0x3d8ce3('0x32'),_0xd9507f['id']));})[_0x5659b9('0x2f')](function(_0x141ac2){const _0x9c481a=_0x5659b9;logger['error']('['+_0x2f46b3[_0x9c481a('0x2')][_0x9c481a('0x19')]()+']',JSON[_0x9c481a('0x1a')](_0x141ac2));});}; \ No newline at end of file +const a1138_0xa27c=['%s/helpdesk/tickets/%d','The\x20User\x20ID\x20is:','Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!','string','Searching\x20enduser\x20with\x20phone','Enduser\x20not\x20found,\x20creating\x20a\x20new\x20enduser!','info','idField','../../../../rediscache','format','monitor_format','Admin\x20account\x20selected.','util','debug','recordingFormat','uniqueid','Variable','forEach','stripTrailingSlash','POST','Descriptions','push','Authorization','type','variableName','queue','length','defaults','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','freshdesk','customVariable','GET','destcalleridname','variable','[OUTBOUND]','Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...','Basic\x20%s','content','%s/api/v2/contacts','lodash','Enduser\x20created.','none','value','calleridnum','stringify','then','custom_fields','../../../../config/logger','Creating\x20new\x20ticket...','The\x20Ticket\x20ID\x20is:','calleridname','getString','base64','from','The\x20Enduser\x20ID\x20is:','toUpperCase','Agent\x20found!','application/json','trigger:browser:url','Tags','catch','[QUEUE]','merge','Caller\x20-\x20%s','mapValues','keyBy','request-promise-native','toString','find','%s/api/v2/tickets','customField','[HTTP]','emit','remoteUri','md5','email','unmanaged','toLowerCase','./util','nameField','Fields','serverUrl','error','
','recordingURL','Invalid\x20email\x20format,\x20using\x20the\x20admin\x20account!','name','outbound','lastevent','%s/api/v2/agents/me','Ticket\x20created!'];(function(_0x9d6f85,_0xa27ce){const _0x383837=function(_0x16a1fd){while(--_0x16a1fd){_0x9d6f85['push'](_0x9d6f85['shift']());}};_0x383837(++_0xa27ce);}(a1138_0xa27c,0x1aa));const a1138_0x3838=function(_0x9d6f85,_0xa27ce){_0x9d6f85=_0x9d6f85-0x0;let _0x383837=a1138_0xa27c[_0x9d6f85];return _0x383837;};const _0x2f0325=a1138_0x3838;'use strict';const _=require(_0x2f0325('0x44')),rp=require(_0x2f0325('0x4')),md5=require(_0x2f0325('0xc')),util=require(_0x2f0325('0x29')),intUtil=require(_0x2f0325('0x10')),logger=require(_0x2f0325('0x4c'))(_0x2f0325('0x3a')),{getSocket}=require(_0x2f0325('0x25')),io=getSocket(),headers={'Content-Type':_0x2f0325('0x56'),'Accept':_0x2f0325('0x56')};function emit(_0x16a1fd,_0x119239,_0x85dd3e){const _0x92d7ce=_0x2f0325;io['to'](_0x16a1fd)[_0x92d7ce('0xa')](_0x119239,_0x85dd3e);}function getTicket(_0x379445,_0x3fe433,_0x2d58d6,_0x4e6f1e,_0x27fc39){const _0x21cf8b=_0x2f0325;logger[_0x21cf8b('0x23')](_0x21cf8b('0x4d'));const _0x408750=_[_0x21cf8b('0x0')]({'responder_id':_0x3fe433['id'],'requester_id':_0x2d58d6['id'],'name':util['format'](_0x21cf8b('0x1'),_0x27fc39[_0x21cf8b('0x4f')]),'phone':_0x27fc39[_0x21cf8b('0x48')],'source':0x3,'priority':0x1,'status':0x2,'subject':intUtil[_0x21cf8b('0x50')](_0x4e6f1e['Subjects'],_0x27fc39,'\x20'),'description':intUtil[_0x21cf8b('0x50')](_0x4e6f1e[_0x21cf8b('0x31')],_0x27fc39,_0x21cf8b('0x15')),'tags':getTags(_0x4e6f1e[_0x21cf8b('0x58')],_0x21cf8b('0x18'))},getCustomFields(_0x4e6f1e[_0x21cf8b('0x12')],_0x27fc39));return _0x408750['custom_fields']=_[_0x21cf8b('0x2')](_[_0x21cf8b('0x3')](_0x408750[_0x21cf8b('0x4b')],'id'),_0x21cf8b('0x47')),request({'uri':util[_0x21cf8b('0x26')](_0x21cf8b('0x7'),_0x379445[_0x21cf8b('0xb')]),'method':'POST','body':_0x408750})[_0x21cf8b('0x4a')](function(_0x26e0b6){const _0x4a0053=_0x21cf8b;return logger['info'](_0x4a0053('0x1c')),_0x26e0b6;});}function getUser(_0x277cb7,_0x362e11){const _0x25afb2=_0x2f0325;return intUtil['validateEmail'](_0x362e11)?request({'uri':util[_0x25afb2('0x26')]('%s/api/v2/agents',_0x277cb7['remoteUri']),'qs':{'email':_0x362e11}})[_0x25afb2('0x4a')](function(_0x461a8d){const _0x16182c=_0x25afb2;return _0x461a8d['length']?(logger[_0x16182c('0x23')](_0x16182c('0x55')),_[_0x16182c('0x6')](_0x461a8d,function(_0x1ba6e){const _0x27233f=_0x16182c;return _0x1ba6e['contact'][_0x27233f('0xd')]===_0x362e11;})):(logger['info'](_0x16182c('0x1f')),request({'uri':util['format'](_0x16182c('0x1b'),_0x277cb7['remoteUri'])})['then'](function(_0x55b69d){const _0x1c204b=_0x16182c;return logger['info'](_0x1c204b('0x28')),_0x55b69d;}));}):(logger['info'](_0x25afb2('0x17')),request({'uri':util[_0x25afb2('0x26')](_0x25afb2('0x1b'),_0x277cb7[_0x25afb2('0xb')])})['then'](function(_0x266178){const _0x27e501=_0x25afb2;return logger[_0x27e501('0x23')]('Admin\x20account\x20selected.'),_0x266178;}));}function getEndUser(_0x39b2d3,_0x286945,_0x11a34a){const _0xdc3ba0=_0x2f0325;return logger['info'](_0xdc3ba0('0x21'),_0x11a34a),request({'uri':util[_0xdc3ba0('0x26')](_0xdc3ba0('0x43'),_0x39b2d3[_0xdc3ba0('0xb')]),'qs':{'phone':_0x11a34a}})['then'](function(_0x4cf90c){const _0x139360=_0xdc3ba0;return _0x4cf90c['length']?(logger['info']('Enduser\x20found!'),_[_0x139360('0x6')](_0x4cf90c,{'phone':_0x11a34a})):(logger['info'](_0x139360('0x22')),request({'uri':util[_0x139360('0x26')](_0x139360('0x43'),_0x39b2d3[_0x139360('0xb')]),'method':_0x139360('0x30'),'body':{'name':_0x286945,'phone':_0x11a34a}})[_0x139360('0x4a')](function(_0x26f75c){const _0x357848=_0x139360;return logger[_0x357848('0x23')](_0x357848('0x45')),_0x26f75c;}));});}function getAuth(_0x43e162){const _0x1b7632=_0x2f0325;return util['format'](_0x1b7632('0x41'),Buffer[_0x1b7632('0x52')](_0x43e162['apiKey']+':X')['toString'](_0x1b7632('0x51')));}function request(_0x47d47d){const _0x56aa07=_0x2f0325;return logger[_0x56aa07('0x2a')](_0x56aa07('0x9'),JSON[_0x56aa07('0x49')](_0x47d47d)),rp(_[_0x56aa07('0x38')](_0x47d47d,{'method':_0x56aa07('0x3c'),'headers':headers,'json':!![]}));}function getTags(_0x4c5ba5,_0x225d5b){let _0x445c0d=[];return _0x4c5ba5&&_0x4c5ba5['length']>0x0&&(_0x445c0d=_['map'](_0x4c5ba5,_0x225d5b)),_0x445c0d;}function getCustomFields(_0x590fd2,_0x191593){const _0x2fb36b=_0x2f0325,_0x113e35={'custom_fields':[]};return _0x590fd2[_0x2fb36b('0x37')]>0x0&&_[_0x2fb36b('0x2e')](_0x590fd2,function(_0x5aa679){const _0x1ff8fe=_0x2fb36b;if(_0x5aa679[_0x1ff8fe('0x34')]===_0x1ff8fe('0x20')&&_0x5aa679[_0x1ff8fe('0x11')]&&!_0x5aa679[_0x1ff8fe('0x8')])_0x113e35[_0x5aa679[_0x1ff8fe('0x11')][_0x1ff8fe('0xf')]()]=_0x5aa679[_0x1ff8fe('0x42')]['toString']();else{if(_0x5aa679[_0x1ff8fe('0x34')]===_0x1ff8fe('0x20')&&_0x5aa679['idField']&&_0x5aa679[_0x1ff8fe('0x8')])_0x113e35[_0x1ff8fe('0x4b')][_0x1ff8fe('0x32')]({'id':_0x5aa679[_0x1ff8fe('0x24')],'value':_0x5aa679['content'][_0x1ff8fe('0x5')]()});else{if(_0x5aa679[_0x1ff8fe('0x34')]===_0x1ff8fe('0x3e')&&_0x5aa679[_0x1ff8fe('0x35')]&&_0x5aa679[_0x1ff8fe('0x24')]&&_0x5aa679[_0x1ff8fe('0x8')])_0x191593[_0x5aa679['variableName']]&&_0x113e35[_0x1ff8fe('0x4b')]['push']({'id':_0x5aa679[_0x1ff8fe('0x24')],'value':_0x191593[_0x5aa679[_0x1ff8fe('0x35')]][_0x1ff8fe('0x5')]()});else _0x5aa679[_0x1ff8fe('0x34')]===_0x1ff8fe('0x3b')&&_0x5aa679[_0x1ff8fe('0x2d')]&&_0x5aa679[_0x1ff8fe('0x2d')][_0x1ff8fe('0x18')]&&_0x5aa679[_0x1ff8fe('0x24')]&&_0x5aa679[_0x1ff8fe('0x8')]&&(_0x191593[_0x5aa679[_0x1ff8fe('0x2d')][_0x1ff8fe('0x18')][_0x1ff8fe('0xf')]()]&&_0x113e35[_0x1ff8fe('0x4b')][_0x1ff8fe('0x32')]({'id':_0x5aa679[_0x1ff8fe('0x24')],'value':_0x191593[_0x5aa679[_0x1ff8fe('0x2d')][_0x1ff8fe('0x18')]['toLowerCase']()]['toString']()}));}}}),_0x113e35;}exports[_0x2f0325('0x36')]=function(_0x2cf095,_0x560b6d,_0x136dfe,_0x4ee7db,_0x4eeb58,_0x4da53a){const _0x2aaedf=_0x2f0325;let _0x33e7bd,_0x389306;return _0x4da53a[_0x2aaedf('0xb')]=intUtil[_0x2aaedf('0x2f')](_0x4da53a[_0x2aaedf('0xb')]),_0x4da53a['serverUrl']=intUtil[_0x2aaedf('0x2f')](_0x4da53a[_0x2aaedf('0x13')]),_0x4eeb58&&_0x4eeb58[_0x2aaedf('0x27')]?(logger[_0x2aaedf('0x23')](_0x2aaedf('0x5a'),'Recording\x20is\x20enabled!'),_0x560b6d[_0x2aaedf('0x16')]=util[_0x2aaedf('0x26')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x4da53a[_0x2aaedf('0x13')],_0x560b6d[_0x2aaedf('0x2c')],md5(_0x560b6d[_0x2aaedf('0x2c')]))):_0x560b6d[_0x2aaedf('0x16')]='',headers[_0x2aaedf('0x33')]=getAuth(_0x4da53a),getUser(_0x4da53a,_0x4ee7db[_0x2aaedf('0xd')])['then'](function(_0x22cc6b){const _0x451edc=_0x2aaedf;return _0x33e7bd=_0x22cc6b,logger[_0x451edc('0x23')]('The\x20User\x20ID\x20is:',_0x33e7bd['id']),getEndUser(_0x4da53a,_0x560b6d[_0x451edc('0x4f')],_0x560b6d['calleridnum']);})['then'](function(_0x595817){const _0x59ab59=_0x2aaedf;return _0x389306=_0x595817,logger['info'](_0x59ab59('0x53'),_0x389306['id']),getTicket(_0x4da53a,_0x33e7bd,_0x389306,_0x136dfe,_0x560b6d);})[_0x2aaedf('0x4a')](function(_0x37c0fd){const _0x303731=_0x2aaedf;_0x37c0fd&&_0x37c0fd['id']&&(logger['info']('Ticket\x20created!'),logger[_0x303731('0x23')](_0x303731('0x4e'),_0x37c0fd['id']),logger[_0x303731('0x23')](_0x303731('0x5a'),_0x303731('0x40')),emit(util[_0x303731('0x26')]('user:%s',_0x4ee7db[_0x303731('0x18')]),'trigger:browser:url',{'uri':util[_0x303731('0x26')](_0x303731('0x1d'),_0x4da53a[_0x303731('0xb')],_0x37c0fd['id'])}));})[_0x2aaedf('0x59')](function(_0x44bf4a){const _0xa266b6=_0x2aaedf;logger[_0xa266b6('0x14')](_0xa266b6('0x5a'),JSON[_0xa266b6('0x49')](_0x44bf4a));});},exports[_0x2f0325('0x19')]=function(_0xe24cac,_0x3400fe,_0x12c11a,_0x5206a0,_0x249608,_0x47b33c,_0x24679e){const _0xe83069=_0x2f0325;let _0x6ba660,_0x3512d8;return _0x47b33c[_0xe83069('0xb')]=intUtil[_0xe83069('0x2f')](_0x47b33c['remoteUri']),_0x47b33c[_0xe83069('0x13')]=intUtil['stripTrailingSlash'](_0x47b33c[_0xe83069('0x13')]),_0x24679e&&_0x24679e[_0xe83069('0x2b')]&&_0x24679e[_0xe83069('0x2b')]!==_0xe83069('0x46')&&(logger[_0xe83069('0x23')]('[OUTBOUND]','Recording\x20is\x20enabled!'),_0x3400fe[_0xe83069('0x16')]=util[_0xe83069('0x26')](_0xe83069('0x39'),_0x47b33c[_0xe83069('0x13')],_0x3400fe['uniqueid'],md5(_0x3400fe['uniqueid']))),headers[_0xe83069('0x33')]=getAuth(_0x47b33c),getUser(_0x47b33c,_0x5206a0[_0xe83069('0xd')])[_0xe83069('0x4a')](function(_0x330caf){const _0xf63105=_0xe83069;return _0x6ba660=_0x330caf,logger[_0xf63105('0x23')]('The\x20User\x20ID\x20is:',_0x6ba660['id']),getEndUser(_0x47b33c,_0x3400fe[_0xf63105('0x3d')],_0x3400fe['destcalleridnum']);})[_0xe83069('0x4a')](function(_0x31dd24){const _0x47d69c=_0xe83069;return _0x3512d8=_0x31dd24,logger['info'](_0x47d69c('0x53'),_0x3512d8['id']),getTicket(_0x47b33c,_0x6ba660,_0x3512d8,_0x12c11a,_0x3400fe);})[_0xe83069('0x4a')](function(_0x248225){const _0x4283a0=_0xe83069;_0x248225&&_0x248225['id']&&(logger[_0x4283a0('0x23')](_0x4283a0('0x1c')),logger[_0x4283a0('0x23')]('The\x20Ticket\x20ID\x20is:',_0x248225['id']),logger[_0x4283a0('0x23')](_0x4283a0('0x3f'),'Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...'),emit(util[_0x4283a0('0x26')]('user:%s',_0x5206a0[_0x4283a0('0x18')]),_0x4283a0('0x57'),{'uri':util[_0x4283a0('0x26')](_0x4283a0('0x1d'),_0x47b33c[_0x4283a0('0xb')],_0x248225['id'])}));})[_0xe83069('0x59')](function(_0x3652ea){const _0x580bcd=_0xe83069;logger[_0x580bcd('0x14')](_0x580bcd('0x3f'),JSON[_0x580bcd('0x49')](_0x3652ea));});},exports[_0x2f0325('0xe')]=function(_0x4ed378,_0x39cab9,_0x2100bf,_0x1416f8,_0x5e3511,_0x36c49e){const _0x5e654d=_0x2f0325;let _0x1f4baf,_0x1a8883;return _0x36c49e[_0x5e654d('0xb')]=intUtil[_0x5e654d('0x2f')](_0x36c49e['remoteUri']),_0x36c49e[_0x5e654d('0x13')]=intUtil[_0x5e654d('0x2f')](_0x36c49e['serverUrl']),_0x5e3511&&_0x5e3511[_0x5e654d('0x27')]?(logger[_0x5e654d('0x23')]('['+_0x39cab9['lastevent'][_0x5e654d('0x54')]()+']','Recording\x20is\x20enabled!'),_0x39cab9['recordingURL']=util[_0x5e654d('0x26')](_0x5e654d('0x39'),_0x36c49e[_0x5e654d('0x13')],_0x39cab9['uniqueid'],md5(_0x39cab9[_0x5e654d('0x2c')]))):_0x39cab9[_0x5e654d('0x16')]='',headers[_0x5e654d('0x33')]=getAuth(_0x36c49e),getUser(_0x36c49e,'')['then'](function(_0x34b162){const _0x30731b=_0x5e654d;return _0x1f4baf=_0x34b162,logger[_0x30731b('0x23')](_0x30731b('0x1e'),_0x1f4baf['id']),getEndUser(_0x36c49e,_0x39cab9[_0x30731b('0x4f')],_0x39cab9[_0x30731b('0x48')]);})[_0x5e654d('0x4a')](function(_0x25525c){const _0x550d0b=_0x5e654d;return _0x1a8883=_0x25525c,logger[_0x550d0b('0x23')](_0x550d0b('0x53'),_0x1a8883['id']),getTicket(_0x36c49e,_0x1f4baf,_0x1a8883,_0x2100bf,_0x39cab9);})['then'](function(_0x152bf7){const _0x22014a=_0x5e654d;_0x152bf7&&(logger[_0x22014a('0x23')](_0x22014a('0x1c')),logger[_0x22014a('0x23')](_0x22014a('0x4e'),_0x152bf7['id']));})[_0x5e654d('0x59')](function(_0x18cd80){const _0x39b727=_0x5e654d;logger[_0x39b727('0x14')]('['+_0x39cab9[_0x39b727('0x1a')][_0x39b727('0x54')]()+']',JSON[_0x39b727('0x49')](_0x18cd80));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/freshsales.js b/server/services/ami/trigger/integration/freshsales.js index e9200b6..ed439b5 100644 --- a/server/services/ami/trigger/integration/freshsales.js +++ b/server/services/ami/trigger/integration/freshsales.js @@ -1 +1 @@ -const a1139_0xe898=['%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','monitor_format','Getting\x20contact\x20list','freshsales','uniqueid','Admin\x20found:','[QUEUE]',']\x20Error\x20running\x20Freshsales\x20integration','Searching\x20contact\x20with\x20phone','Creating\x20new\x20task','agentEmail','format','length','Displaying\x20task\x20in\x20a\x20new\x20tab...','request-promise-native','toUpperCase','Contact','Getting\x20user\x20list','calleridnum','remoteUri','emit','username','/api/tasks','queue','moment','Recording\x20is\x20enabled!','getString','/api/contacts/filters','outbound','Getting\x20admin\x20information','recordingFormat','adminEmail','mobile_number','md5','GET','POST','Subjects','YYYY-MM-DDTHH:mm:ss','ticketId','filters','/api/contacts/view/','../../../../config/logger','users','endUserId','contact','Getting\x20contacts\x20filter','name','userEmail','message','Descriptions','error','contactNumber','then','contacts','../../../../rediscache','info','catch','add','User\x20found:','lodash','userId','task','apiKey','toLowerCase','[OUTBOUND]','adminId','Contact\x20created:','serverUrl','Requested\x20Resource\x20not\x20Found','recordingURL','/api/contacts','forEach','Contact\x20not\x20found,\x20creating\x20a\x20new\x20contact','inspect','none','work_number','Contact\x20found:','unmanaged','Token\x20token=','/api/selector/owners','email','Getting\x20user\x20with\x20email','headers','util'];(function(_0x1b01ed,_0xe89867){const _0x1d3f11=function(_0x538104){while(--_0x538104){_0x1b01ed['push'](_0x1b01ed['shift']());}};_0x1d3f11(++_0xe89867);}(a1139_0xe898,0x1e2));const a1139_0x1d3f=function(_0x1b01ed,_0xe89867){_0x1b01ed=_0x1b01ed-0x0;let _0x1d3f11=a1139_0xe898[_0x1b01ed];return _0x1d3f11;};const _0x30ed2c=a1139_0x1d3f;'use strict';const _=require(_0x30ed2c('0x51')),rp=require(_0x30ed2c('0x24')),md5=require(_0x30ed2c('0x37')),util=require(_0x30ed2c('0x15')),moment=require(_0x30ed2c('0x2e')),intUtil=require('./util'),logger=require(_0x30ed2c('0x3f'))(_0x30ed2c('0x19')),{getSocket}=require(_0x30ed2c('0x4c')),io=getSocket();function getAdminId(_0x538104,_0x54947b,_0x3c601d,_0x36fb4e){return new Promise(function(_0x4044f1,_0x3c65dc){const _0x5bafe4=a1139_0x1d3f;let _0x34745e=![];const _0x408404={'method':_0x5bafe4('0x38'),'uri':_0x36fb4e+_0x5bafe4('0x11'),'json':!![]};return _0x408404[_0x5bafe4('0x14')]=_0x3c601d,logger[_0x5bafe4('0x4d')](_0x5bafe4('0x33')),rp(_0x408404)[_0x5bafe4('0x4a')](function(_0x4ec1b5){const _0x430409=_0x5bafe4;if(_0x4ec1b5){const _0x504b74=_0x4ec1b5[_0x430409('0x40')];let _0x275582=null;for(_0x275582=0x0;_0x275582<_0x504b74[_0x430409('0x22')];_0x275582++){_0x504b74[_0x275582][_0x430409('0x12')]===_0x538104['adminEmail']&&(_0x538104[_0x430409('0x3')]=_0x504b74[_0x275582]['id'],_0x34745e=!![]);}_0x34745e?(logger['info'](_0x430409('0x1b'),_0x538104[_0x430409('0x3')]),_0x4044f1(_0x538104)):_0x3c65dc({'statusCode':0x194,'message':'Requested\x20Resource\x20not\x20Found'});}else _0x3c65dc({'statusCode':0x194,'message':_0x430409('0x6')});})['catch'](function(_0x9a917d){const _0x84c033=_0x5bafe4;logger[_0x84c033('0x48')]('['+[_0x54947b[_0x84c033('0x25')]()]+']',_0x9a917d[_0x84c033('0x46')]),_0x3c65dc(_0x9a917d);});});}function getUser(_0x47e2ec,_0x21a828,_0x4013a9){return function(_0x539d81){return new Promise(function(_0xf32af0,_0x27fa51){const _0x4b8a21=a1139_0x1d3f,_0x2063fa={'method':_0x4b8a21('0x38'),'uri':_0x4013a9+_0x4b8a21('0x11'),'json':!![]};return _0x2063fa[_0x4b8a21('0x14')]=_0x21a828,logger[_0x4b8a21('0x4d')](_0x4b8a21('0x27')),rp(_0x2063fa)[_0x4b8a21('0x4a')](function(_0x365ca9){const _0x3f3230=_0x4b8a21;if(_0x365ca9){const _0x5e49f3=_0x365ca9[_0x3f3230('0x40')];let _0x469c4e=![],_0x489788=null;if(_0x539d81[_0x3f3230('0x20')]!==null){logger[_0x3f3230('0x4d')](_0x3f3230('0x13'),_0x539d81['agentEmail']),_0x539d81['userEmail']=_0x539d81['agentEmail'];for(_0x489788=0x0;_0x489788<_0x5e49f3['length'];_0x489788++){_0x5e49f3[_0x489788][_0x3f3230('0x12')]===_0x539d81['agentEmail']&&(_0x469c4e=!![],_0x539d81[_0x3f3230('0x52')]=_0x5e49f3[_0x489788]['id'],logger[_0x3f3230('0x4d')](_0x3f3230('0x50'),_0x539d81['userId']));}}!_0x469c4e&&(logger[_0x3f3230('0x4d')]('Admin\x20selected'),_0x539d81[_0x3f3230('0x45')]=_0x539d81[_0x3f3230('0x35')],_0x539d81[_0x3f3230('0x52')]=_0x539d81[_0x3f3230('0x3')],_0x469c4e=!![]),_0x469c4e?_0xf32af0(_0x539d81):_0x27fa51({'statusCode':0x194,'message':_0x3f3230('0x6')});}else _0x27fa51({'statusCode':0x194,'message':'Requested\x20Resource\x20not\x20Found'});})[_0x4b8a21('0x4e')](function(_0x591cb1){const _0x5542b0=_0x4b8a21;logger[_0x5542b0('0x48')]('['+[_0x47e2ec['toUpperCase']()]+']',_0x591cb1['message']),_0x27fa51(_0x591cb1);});});};}function getEndUser(_0x5d754d,_0x28b690,_0x18d362){return function(_0x44520e){return new Promise(function(_0x19aeb2){const _0x1827a0=a1139_0x1d3f;let _0x5a15d4=0x0;const _0x106942={'method':_0x1827a0('0x38'),'uri':_0x18d362+_0x1827a0('0x31'),'json':!![]};return _0x106942[_0x1827a0('0x14')]=_0x28b690,logger[_0x1827a0('0x4d')](_0x1827a0('0x43')),rp(_0x106942)[_0x1827a0('0x4a')](function(_0x571df5){const _0x42bcb5=_0x1827a0;_0x571df5[_0x42bcb5('0x3d')][_0x42bcb5('0x9')](function(_0x5768ec){const _0x1c19b9=_0x42bcb5;_0x5768ec[_0x1c19b9('0x44')]==='All\x20Contacts'&&(_0x5a15d4=_0x5768ec['id']);});})[_0x1827a0('0x4a')](function(){const _0x223ff0=_0x1827a0;logger[_0x223ff0('0x4d')](_0x223ff0('0x18'));const _0x3abf2b={'method':_0x223ff0('0x38'),'uri':_0x18d362+_0x223ff0('0x3e')+_0x5a15d4,'json':!![]};return _0x3abf2b[_0x223ff0('0x14')]=_0x28b690,rp(_0x3abf2b);})[_0x1827a0('0x4a')](function(_0x47ed5a){const _0x45faa3=_0x1827a0;logger['info'](_0x45faa3('0x1e'),_0x44520e[_0x45faa3('0x49')]);if(_0x47ed5a[_0x45faa3('0x4b')][_0x45faa3('0x22')]>0x0){const _0x512029=_['find'](_0x47ed5a[_0x45faa3('0x4b')],function(_0x9e447a){const _0x48ba60=_0x45faa3;if(_0x9e447a[_0x48ba60('0xd')]===_0x44520e['contactNumber']||_0x9e447a[_0x48ba60('0x36')]===_0x44520e[_0x48ba60('0x49')])return _0x9e447a;});if(_0x512029)_0x44520e[_0x45faa3('0x41')]=_0x512029['id'],logger['info'](_0x45faa3('0xe'),_0x44520e[_0x45faa3('0x41')]),_0x19aeb2(_0x44520e);else return createEndUser(_0x44520e,_0x5d754d,_0x28b690,_0x18d362)[_0x45faa3('0x4a')](function(_0x21c095){const _0x35e830=_0x45faa3;logger[_0x35e830('0x4d')](_0x35e830('0x4'),_0x44520e['endUserId']),_0x19aeb2(_0x21c095);});}else return createEndUser(_0x44520e,_0x5d754d,_0x28b690,_0x18d362)[_0x45faa3('0x4a')](function(_0x3f6168){const _0x20ca35=_0x45faa3;logger[_0x20ca35('0x4d')]('Contact\x20created:',_0x44520e['endUserId']),_0x19aeb2(_0x3f6168);});})['catch'](function(_0x338d9f){const _0x3889db=_0x1827a0;throw new Error(_0x338d9f[_0x3889db('0x46')]);});});};}function createEndUser(_0x28abed,_0x1615d4,_0x2ea1b1,_0x1515d4){return new Promise(function(_0x208ca3,_0xa2bfb2){const _0x442452=a1139_0x1d3f,_0x5475d7=moment(),_0x2f1dc1={'method':_0x442452('0x39'),'uri':_0x1515d4+_0x442452('0x8'),'body':{'contact':{'last_name':_0x28abed[_0x442452('0x49')],'work_number':_0x28abed['contactNumber'],'mobile_number':_0x28abed['contactNumber'],'owner_id':_0x28abed[_0x442452('0x52')],'created_at':_0x5475d7[_0x442452('0x21')]('YYYY-MM-DDTHH:mm:ss')}},'json':!![]};return _0x2f1dc1['headers']=_0x2ea1b1,logger[_0x442452('0x4d')](_0x442452('0xa')),rp(_0x2f1dc1)[_0x442452('0x4a')](function(_0xe73e7b){const _0x2e90d2=_0x442452;_0x28abed['endUserId']=_0xe73e7b[_0x2e90d2('0x42')]['id'],_0x208ca3(_0x28abed);})['catch'](function(_0x34928a){const _0x354c92=_0x442452;logger[_0x354c92('0x48')]('['+[_0x1615d4[_0x354c92('0x25')]()]+']',_0x34928a[_0x354c92('0x46')]),_0xa2bfb2(_0x34928a[_0x354c92('0x46')]);});});}function getTicket(_0x4f673b,_0x35ed36,_0x5f4303,_0x62dcd5,_0x4469f3){return function(_0x55503c){const _0x1a5db4=a1139_0x1d3f;return logger[_0x1a5db4('0x4d')](_0x1a5db4('0x1f')),new Promise(function(_0x50080b,_0x5e0424){const _0x19a520=_0x1a5db4,_0x47aa76=moment(),_0x592cd3={'method':_0x19a520('0x39'),'uri':_0x5f4303+_0x19a520('0x2c'),'body':{'title':intUtil[_0x19a520('0x30')](_0x62dcd5[_0x19a520('0x3a')],_0x4469f3,'\x20'),'description':intUtil[_0x19a520('0x30')](_0x62dcd5[_0x19a520('0x47')],_0x4469f3,'\x0a'),'owner_id':_0x55503c['userId'],'creater_id':_0x55503c[_0x19a520('0x3')],'targetable_id':_0x55503c[_0x19a520('0x41')],'targetable_type':_0x19a520('0x26'),'created_at':_0x47aa76['format'](_0x19a520('0x3b')),'due_date':_0x47aa76[_0x19a520('0x4f')](0x1e,'m')['format'](_0x19a520('0x3b'))},'json':!![]};return _0x592cd3[_0x19a520('0x14')]=_0x35ed36,rp(_0x592cd3)['then'](function(_0x4de0b2){const _0x20c795=_0x19a520;_0x55503c[_0x20c795('0x3c')]=_0x4de0b2[_0x20c795('0x53')]['id'],logger[_0x20c795('0x4d')]('Task\x20created:',_0x55503c[_0x20c795('0x3c')]),_0x50080b(_0x55503c);})[_0x19a520('0x4e')](function(_0x40dd9c){const _0x2b6ba8=_0x19a520;logger[_0x2b6ba8('0x48')]('['+[_0x4f673b[_0x2b6ba8('0x25')]()]+']',_0x40dd9c['message']),_0x5e0424(_0x40dd9c['message']);});});};}function emit(_0x53032b,_0x46e784,_0x3008cc){const _0x3b0703=_0x30ed2c,_0x2f115b={'uri':_0x53032b+'/contacts/'+_0x3008cc};io['to'](util[_0x3b0703('0x21')]('user:%s',_0x46e784))[_0x3b0703('0x2a')]('trigger:browser:url',_0x2f115b);}exports['cs']=function(_0x509948,_0x46e5ac,_0xe98462,_0x683bc2,_0x46e867,_0x14e5f7,_0x3c1891,_0x1a69a9){const _0x3317d2=_0x30ed2c,_0x33d7c1={},_0x2a6842={'Authorization':_0x3317d2('0x10')+_0x14e5f7[_0x3317d2('0x0')]};_0x14e5f7['remoteUri']=intUtil['stripTrailingSlash'](_0x14e5f7[_0x3317d2('0x29')]),_0x14e5f7['serverUrl']=intUtil['stripTrailingSlash'](_0x14e5f7['serverUrl']);const _0x2bb3c9=_0x14e5f7['remoteUri'];_0x33d7c1[_0x3317d2('0x35')]=_0x14e5f7[_0x3317d2('0x2b')],_0x33d7c1[_0x3317d2('0x49')]=_0x1a69a9[_0x3317d2('0x1')]()===_0x3317d2('0x32')?_0x46e5ac['destcalleridnum']:_0x46e5ac[_0x3317d2('0x28')],_0x33d7c1['callDirection']=_0x1a69a9===_0x3317d2('0x2d')||_0x1a69a9===_0x3317d2('0xf')?_0x3317d2('0x2d'):_0x3317d2('0x32');_0x683bc2&&(_0x33d7c1[_0x3317d2('0x20')]=_0x683bc2[_0x3317d2('0x12')]);const _0x17cf8c=util[_0x3317d2('0x21')](_0x3317d2('0x16'),_0x14e5f7[_0x3317d2('0x5')],_0x46e5ac['uniqueid'],md5(_0x46e5ac[_0x3317d2('0x1a')]));if(_0x46e867&&_0x46e867[_0x3317d2('0x17')])logger[_0x3317d2('0x4d')](_0x3317d2('0x1c'),_0x3317d2('0x2f')),_0x46e5ac['recordingURL']=_0x17cf8c;else _0x3c1891&&_0x3c1891[_0x3317d2('0x34')]&&_0x3c1891[_0x3317d2('0x34')]!==_0x3317d2('0xc')?(logger[_0x3317d2('0x4d')](_0x3317d2('0x2'),'Recording\x20is\x20enabled!'),_0x46e5ac[_0x3317d2('0x7')]=_0x17cf8c):_0x46e5ac[_0x3317d2('0x7')]='';return getAdminId(_0x33d7c1,_0x1a69a9,_0x2a6842,_0x2bb3c9)[_0x3317d2('0x4a')](getUser(_0x1a69a9,_0x2a6842,_0x2bb3c9))[_0x3317d2('0x4a')](getEndUser(_0x1a69a9,_0x2a6842,_0x2bb3c9))['then'](getTicket(_0x1a69a9,_0x2a6842,_0x2bb3c9,_0xe98462,_0x46e5ac))[_0x3317d2('0x4a')](function(_0x2c8bda){const _0x3f92c5=_0x3317d2;logger[_0x3f92c5('0x4d')](util['format']('The\x20ticket\x20ID\x20is:\x20%s',_0x2c8bda[_0x3f92c5('0x3c')])),_0x1a69a9!==_0x3f92c5('0xf')&&(logger[_0x3f92c5('0x4d')]('['+[_0x1a69a9[_0x3f92c5('0x25')]()]+']',_0x3f92c5('0x23')),emit(_0x2bb3c9,_0x683bc2['name'],_0x2c8bda[_0x3f92c5('0x41')]));})[_0x3317d2('0x4e')](function(_0x249bf4){const _0xcab5c1=_0x3317d2;logger[_0xcab5c1('0x48')]('['+[_0x1a69a9[_0xcab5c1('0x25')]()]+_0xcab5c1('0x1d'),util[_0xcab5c1('0xb')](_0x249bf4,{'showHidden':!![],'depth':null}));});}; \ No newline at end of file +const a1139_0x5652=['Searching\x20contact\x20with\x20phone','Contact\x20found:','error','Token\x20token=','Creating\x20new\x20task','message','YYYY-MM-DDTHH:mm:ss','destcalleridnum','Contact','filters','agentEmail','Getting\x20contacts\x20filter','Displaying\x20task\x20in\x20a\x20new\x20tab...','Recording\x20is\x20enabled!','contact','apiKey','ticketId','remoteUri','Descriptions','name','freshsales','Task\x20created:','The\x20ticket\x20ID\x20is:\x20%s','/api/tasks','none','User\x20found:','find','Getting\x20admin\x20information','unmanaged','Admin\x20found:','Subjects','adminId','task','../../../../rediscache','getString','util','serverUrl','info','Requested\x20Resource\x20not\x20Found','[QUEUE]','userId','headers','forEach','catch','user:%s','[OUTBOUND]','Contact\x20not\x20found,\x20creating\x20a\x20new\x20contact','work_number','contacts','mobile_number','uniqueid','inspect','length','/contacts/',']\x20Error\x20running\x20Freshsales\x20integration','contactNumber','Contact\x20created:','userEmail','outbound','POST','endUserId','add','username','trigger:browser:url','recordingFormat','/api/selector/owners','Admin\x20selected','queue','Getting\x20contact\x20list','format','then','callDirection','toUpperCase','adminEmail','Getting\x20user\x20list','GET','/api/contacts/filters','email','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','recordingURL','stripTrailingSlash'];(function(_0x40a702,_0x565237){const _0x45ec74=function(_0x2187aa){while(--_0x2187aa){_0x40a702['push'](_0x40a702['shift']());}};_0x45ec74(++_0x565237);}(a1139_0x5652,0x66));const a1139_0x45ec=function(_0x40a702,_0x565237){_0x40a702=_0x40a702-0x0;let _0x45ec74=a1139_0x5652[_0x40a702];return _0x45ec74;};const _0x2ab7ee=a1139_0x45ec;'use strict';const _=require('lodash'),rp=require('request-promise-native'),md5=require('md5'),util=require(_0x2ab7ee('0xe')),moment=require('moment'),intUtil=require('./util'),logger=require('../../../../config/logger')(_0x2ab7ee('0x50')),{getSocket}=require(_0x2ab7ee('0xc')),io=getSocket();function getAdminId(_0x2187aa,_0x38e9b3,_0x406e05,_0x1e55e6){return new Promise(function(_0x498348,_0x266be7){const _0x28b251=a1139_0x45ec;let _0x96f954=![];const _0x482905={'method':_0x28b251('0x36'),'uri':_0x1e55e6+_0x28b251('0x2c'),'json':!![]};return _0x482905[_0x28b251('0x14')]=_0x406e05,logger[_0x28b251('0x10')](_0x28b251('0x6')),rp(_0x482905)[_0x28b251('0x31')](function(_0x2b6020){const _0x467659=_0x28b251;if(_0x2b6020){const _0x312084=_0x2b6020['users'];let _0x449477=null;for(_0x449477=0x0;_0x449477<_0x312084[_0x467659('0x1f')];_0x449477++){_0x312084[_0x449477][_0x467659('0x38')]===_0x2187aa[_0x467659('0x34')]&&(_0x2187aa[_0x467659('0xa')]=_0x312084[_0x449477]['id'],_0x96f954=!![]);}_0x96f954?(logger[_0x467659('0x10')](_0x467659('0x8'),_0x2187aa[_0x467659('0xa')]),_0x498348(_0x2187aa)):_0x266be7({'statusCode':0x194,'message':_0x467659('0x11')});}else _0x266be7({'statusCode':0x194,'message':_0x467659('0x11')});})[_0x28b251('0x16')](function(_0x163027){const _0x35cce1=_0x28b251;logger['error']('['+[_0x38e9b3[_0x35cce1('0x33')]()]+']',_0x163027['message']),_0x266be7(_0x163027);});});}function getUser(_0x340fdd,_0x34bd0d,_0x5ab6ab){return function(_0x59ccd0){return new Promise(function(_0x3ed89e,_0x139412){const _0x229225=a1139_0x45ec,_0xf62fe5={'method':'GET','uri':_0x5ab6ab+_0x229225('0x2c'),'json':!![]};return _0xf62fe5[_0x229225('0x14')]=_0x34bd0d,logger[_0x229225('0x10')](_0x229225('0x35')),rp(_0xf62fe5)[_0x229225('0x31')](function(_0x3703af){const _0x242d36=_0x229225;if(_0x3703af){const _0x4a6ad4=_0x3703af['users'];let _0x543940=![],_0x3f3b74=null;if(_0x59ccd0[_0x242d36('0x46')]!==null){logger[_0x242d36('0x10')]('Getting\x20user\x20with\x20email',_0x59ccd0[_0x242d36('0x46')]),_0x59ccd0[_0x242d36('0x24')]=_0x59ccd0[_0x242d36('0x46')];for(_0x3f3b74=0x0;_0x3f3b74<_0x4a6ad4[_0x242d36('0x1f')];_0x3f3b74++){_0x4a6ad4[_0x3f3b74]['email']===_0x59ccd0[_0x242d36('0x46')]&&(_0x543940=!![],_0x59ccd0[_0x242d36('0x13')]=_0x4a6ad4[_0x3f3b74]['id'],logger[_0x242d36('0x10')](_0x242d36('0x4'),_0x59ccd0[_0x242d36('0x13')]));}}!_0x543940&&(logger[_0x242d36('0x10')](_0x242d36('0x2d')),_0x59ccd0[_0x242d36('0x24')]=_0x59ccd0[_0x242d36('0x34')],_0x59ccd0[_0x242d36('0x13')]=_0x59ccd0[_0x242d36('0xa')],_0x543940=!![]),_0x543940?_0x3ed89e(_0x59ccd0):_0x139412({'statusCode':0x194,'message':_0x242d36('0x11')});}else _0x139412({'statusCode':0x194,'message':_0x242d36('0x11')});})['catch'](function(_0x3d5007){const _0x15efb8=_0x229225;logger[_0x15efb8('0x3e')]('['+[_0x340fdd[_0x15efb8('0x33')]()]+']',_0x3d5007[_0x15efb8('0x41')]),_0x139412(_0x3d5007);});});};}function getEndUser(_0x14bcf7,_0x57cd07,_0x4e71a6){return function(_0x330058){return new Promise(function(_0x2cce67){const _0x38b01f=a1139_0x45ec;let _0x52c662=0x0;const _0x48a6cc={'method':_0x38b01f('0x36'),'uri':_0x4e71a6+_0x38b01f('0x37'),'json':!![]};return _0x48a6cc['headers']=_0x57cd07,logger[_0x38b01f('0x10')](_0x38b01f('0x47')),rp(_0x48a6cc)[_0x38b01f('0x31')](function(_0x5b39d3){const _0x2eb97e=_0x38b01f;_0x5b39d3[_0x2eb97e('0x45')][_0x2eb97e('0x15')](function(_0x424254){const _0x54cec8=_0x2eb97e;_0x424254[_0x54cec8('0x4f')]==='All\x20Contacts'&&(_0x52c662=_0x424254['id']);});})['then'](function(){const _0x258716=_0x38b01f;logger[_0x258716('0x10')](_0x258716('0x2f'));const _0x372227={'method':_0x258716('0x36'),'uri':_0x4e71a6+'/api/contacts/view/'+_0x52c662,'json':!![]};return _0x372227[_0x258716('0x14')]=_0x57cd07,rp(_0x372227);})[_0x38b01f('0x31')](function(_0xe916e4){const _0x1ff3ef=_0x38b01f;logger['info'](_0x1ff3ef('0x3c'),_0x330058[_0x1ff3ef('0x22')]);if(_0xe916e4[_0x1ff3ef('0x1b')][_0x1ff3ef('0x1f')]>0x0){const _0x3a1df6=_[_0x1ff3ef('0x5')](_0xe916e4[_0x1ff3ef('0x1b')],function(_0x3daf00){const _0x3a3e94=_0x1ff3ef;if(_0x3daf00[_0x3a3e94('0x1a')]===_0x330058['contactNumber']||_0x3daf00[_0x3a3e94('0x1c')]===_0x330058[_0x3a3e94('0x22')])return _0x3daf00;});if(_0x3a1df6)_0x330058[_0x1ff3ef('0x27')]=_0x3a1df6['id'],logger[_0x1ff3ef('0x10')](_0x1ff3ef('0x3d'),_0x330058['endUserId']),_0x2cce67(_0x330058);else return createEndUser(_0x330058,_0x14bcf7,_0x57cd07,_0x4e71a6)['then'](function(_0x3d7d2b){const _0x557cd6=_0x1ff3ef;logger['info'](_0x557cd6('0x23'),_0x330058['endUserId']),_0x2cce67(_0x3d7d2b);});}else return createEndUser(_0x330058,_0x14bcf7,_0x57cd07,_0x4e71a6)['then'](function(_0x481353){const _0x18db65=_0x1ff3ef;logger['info'](_0x18db65('0x23'),_0x330058['endUserId']),_0x2cce67(_0x481353);});})[_0x38b01f('0x16')](function(_0x4cd4b4){const _0x3cf54a=_0x38b01f;throw new Error(_0x4cd4b4[_0x3cf54a('0x41')]);});});};}function createEndUser(_0x24e9e5,_0x40a7e7,_0x11c477,_0x548d10){return new Promise(function(_0x70189,_0x426b7e){const _0x501d90=a1139_0x45ec,_0x18ca35=moment(),_0x4cb7a8={'method':_0x501d90('0x26'),'uri':_0x548d10+'/api/contacts','body':{'contact':{'last_name':_0x24e9e5['contactNumber'],'work_number':_0x24e9e5[_0x501d90('0x22')],'mobile_number':_0x24e9e5[_0x501d90('0x22')],'owner_id':_0x24e9e5[_0x501d90('0x13')],'created_at':_0x18ca35[_0x501d90('0x30')](_0x501d90('0x42'))}},'json':!![]};return _0x4cb7a8[_0x501d90('0x14')]=_0x11c477,logger[_0x501d90('0x10')](_0x501d90('0x19')),rp(_0x4cb7a8)['then'](function(_0x1e24a3){const _0x5a9762=_0x501d90;_0x24e9e5[_0x5a9762('0x27')]=_0x1e24a3[_0x5a9762('0x4a')]['id'],_0x70189(_0x24e9e5);})[_0x501d90('0x16')](function(_0x31c55d){const _0x143f01=_0x501d90;logger[_0x143f01('0x3e')]('['+[_0x40a7e7[_0x143f01('0x33')]()]+']',_0x31c55d[_0x143f01('0x41')]),_0x426b7e(_0x31c55d[_0x143f01('0x41')]);});});}function getTicket(_0x37b51e,_0x2a30b4,_0x30778e,_0x3ccef4,_0x29a0c3){return function(_0x590828){const _0x1a9326=a1139_0x45ec;return logger[_0x1a9326('0x10')](_0x1a9326('0x40')),new Promise(function(_0x27ac6d,_0x3005c5){const _0x555e66=_0x1a9326,_0x36c83b=moment(),_0xe6571={'method':_0x555e66('0x26'),'uri':_0x30778e+_0x555e66('0x2'),'body':{'title':intUtil[_0x555e66('0xd')](_0x3ccef4[_0x555e66('0x9')],_0x29a0c3,'\x20'),'description':intUtil[_0x555e66('0xd')](_0x3ccef4[_0x555e66('0x4e')],_0x29a0c3,'\x0a'),'owner_id':_0x590828['userId'],'creater_id':_0x590828[_0x555e66('0xa')],'targetable_id':_0x590828['endUserId'],'targetable_type':_0x555e66('0x44'),'created_at':_0x36c83b[_0x555e66('0x30')](_0x555e66('0x42')),'due_date':_0x36c83b[_0x555e66('0x28')](0x1e,'m')[_0x555e66('0x30')](_0x555e66('0x42'))},'json':!![]};return _0xe6571[_0x555e66('0x14')]=_0x2a30b4,rp(_0xe6571)[_0x555e66('0x31')](function(_0xc5ceec){const _0x4ea742=_0x555e66;_0x590828[_0x4ea742('0x4c')]=_0xc5ceec[_0x4ea742('0xb')]['id'],logger[_0x4ea742('0x10')](_0x4ea742('0x0'),_0x590828[_0x4ea742('0x4c')]),_0x27ac6d(_0x590828);})[_0x555e66('0x16')](function(_0x203b2e){const _0x2237f4=_0x555e66;logger[_0x2237f4('0x3e')]('['+[_0x37b51e[_0x2237f4('0x33')]()]+']',_0x203b2e[_0x2237f4('0x41')]),_0x3005c5(_0x203b2e[_0x2237f4('0x41')]);});});};}function emit(_0x5d2a7c,_0x378ae4,_0x3377b6){const _0x271554=_0x2ab7ee,_0x1e2f45={'uri':_0x5d2a7c+_0x271554('0x20')+_0x3377b6};io['to'](util['format'](_0x271554('0x17'),_0x378ae4))['emit'](_0x271554('0x2a'),_0x1e2f45);}exports['cs']=function(_0x21ae86,_0x4a7e57,_0x27b6f8,_0x549d9c,_0x49fedc,_0x101ebc,_0x12ed3b,_0x28b40c){const _0x2a12f2=_0x2ab7ee,_0xf1d36e={},_0x3fe38a={'Authorization':_0x2a12f2('0x3f')+_0x101ebc[_0x2a12f2('0x4b')]};_0x101ebc[_0x2a12f2('0x4d')]=intUtil[_0x2a12f2('0x3b')](_0x101ebc[_0x2a12f2('0x4d')]),_0x101ebc[_0x2a12f2('0xf')]=intUtil[_0x2a12f2('0x3b')](_0x101ebc['serverUrl']);const _0x106cda=_0x101ebc[_0x2a12f2('0x4d')];_0xf1d36e['adminEmail']=_0x101ebc[_0x2a12f2('0x29')],_0xf1d36e[_0x2a12f2('0x22')]=_0x28b40c['toLowerCase']()===_0x2a12f2('0x25')?_0x4a7e57[_0x2a12f2('0x43')]:_0x4a7e57['calleridnum'],_0xf1d36e[_0x2a12f2('0x32')]=_0x28b40c===_0x2a12f2('0x2e')||_0x28b40c===_0x2a12f2('0x7')?_0x2a12f2('0x2e'):_0x2a12f2('0x25');_0x549d9c&&(_0xf1d36e[_0x2a12f2('0x46')]=_0x549d9c[_0x2a12f2('0x38')]);const _0x5c0e91=util[_0x2a12f2('0x30')](_0x2a12f2('0x39'),_0x101ebc[_0x2a12f2('0xf')],_0x4a7e57[_0x2a12f2('0x1d')],md5(_0x4a7e57[_0x2a12f2('0x1d')]));if(_0x49fedc&&_0x49fedc['monitor_format'])logger[_0x2a12f2('0x10')](_0x2a12f2('0x12'),'Recording\x20is\x20enabled!'),_0x4a7e57[_0x2a12f2('0x3a')]=_0x5c0e91;else _0x12ed3b&&_0x12ed3b[_0x2a12f2('0x2b')]&&_0x12ed3b['recordingFormat']!==_0x2a12f2('0x3')?(logger[_0x2a12f2('0x10')](_0x2a12f2('0x18'),_0x2a12f2('0x49')),_0x4a7e57[_0x2a12f2('0x3a')]=_0x5c0e91):_0x4a7e57['recordingURL']='';return getAdminId(_0xf1d36e,_0x28b40c,_0x3fe38a,_0x106cda)['then'](getUser(_0x28b40c,_0x3fe38a,_0x106cda))[_0x2a12f2('0x31')](getEndUser(_0x28b40c,_0x3fe38a,_0x106cda))[_0x2a12f2('0x31')](getTicket(_0x28b40c,_0x3fe38a,_0x106cda,_0x27b6f8,_0x4a7e57))['then'](function(_0x311640){const _0x2b495c=_0x2a12f2;logger[_0x2b495c('0x10')](util[_0x2b495c('0x30')](_0x2b495c('0x1'),_0x311640[_0x2b495c('0x4c')])),_0x28b40c!==_0x2b495c('0x7')&&(logger[_0x2b495c('0x10')]('['+[_0x28b40c[_0x2b495c('0x33')]()]+']',_0x2b495c('0x48')),emit(_0x106cda,_0x549d9c[_0x2b495c('0x4f')],_0x311640[_0x2b495c('0x27')]));})[_0x2a12f2('0x16')](function(_0x447d1c){const _0xc26b8b=_0x2a12f2;logger[_0xc26b8b('0x3e')]('['+[_0x28b40c[_0xc26b8b('0x33')]()]+_0xc26b8b('0x21'),util[_0xc26b8b('0x1e')](_0x447d1c,{'showHidden':!![],'depth':null}));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/index.js b/server/services/ami/trigger/integration/index.js index fe1da95..a244838 100644 --- a/server/services/ami/trigger/integration/index.js +++ b/server/services/ami/trigger/integration/index.js @@ -1 +1 @@ -const a1140_0xfa3e=['freshsales','vtiger','sugarcrm','toLowerCase','unmanaged','includes','./dynamics365','freshdesk','%s\x20configuration\x20#%s\x20not\x20found','salesforce','data1','./servicenow','./zoho','format','../../../../config/logger','Configurations','./vtiger','./desk','data2','[EXEC]','%s\x20account\x20#%s\x20not\x20found','./freshdesk','log','./zendesk','dynamics365','error','find','./sugarcrm','lodash','outbound','./salesforce','unknown\x20integration','queue','data3','zendesk','exec'];(function(_0x453436,_0xfa3e1e){const _0x30b112=function(_0x5030fd){while(--_0x5030fd){_0x453436['push'](_0x453436['shift']());}};_0x30b112(++_0xfa3e1e);}(a1140_0xfa3e,0x8d));const a1140_0x30b1=function(_0x453436,_0xfa3e1e){_0x453436=_0x453436-0x0;let _0x30b112=a1140_0xfa3e[_0x453436];return _0x30b112;};const _0x1b636f=a1140_0x30b1;'use strict';const _=require(_0x1b636f('0x1f')),util=require('util'),zendesk=require(_0x1b636f('0x1a')),salesforce=require(_0x1b636f('0x21')),sugarcrm=require(_0x1b636f('0x1e')),freshdesk=require(_0x1b636f('0x18')),zoho=require(_0x1b636f('0xf')),desk=require(_0x1b636f('0x14')),vtiger=require(_0x1b636f('0x13')),servicenow=require(_0x1b636f('0xe')),dynamics365=require(_0x1b636f('0x9')),freshsales=require('./freshsales'),integrations=[_0x1b636f('0x1'),_0x1b636f('0xc'),_0x1b636f('0x5'),_0x1b636f('0xa'),'zoho','desk',_0x1b636f('0x4'),_0x1b636f('0x1b'),_0x1b636f('0x3'),'servicenow'];exports[_0x1b636f('0x2')]=function(_0x5030fd,_0x5c577a,_0x3faae8,_0x5e3af9,_0x305340,_0x47c1ca){const _0x2617f3=_0x1b636f;if(_0x3faae8){if(_[_0x2617f3('0x8')](integrations,_0x5030fd['data1'][_0x2617f3('0x6')]()))try{let _0x1c9cca=null,_0x3bd2e9='';const _0x3ed5cd=_0x3faae8[_0x5030fd[_0x2617f3('0xd')][_0x2617f3('0x6')]()];if(_0x3ed5cd){const _0x257df0=_0x3ed5cd[_0x5030fd['data2']];if(_0x257df0){const _0x2606a0=_[_0x2617f3('0x1d')](_0x257df0[_0x2617f3('0x12')],{'id':parseInt(_0x5030fd[_0x2617f3('0x0')],0xa)});if(_0x2606a0){if(_0x5e3af9){if(_0x305340&&_0x5c577a[_0x2617f3('0x23')])_0x3bd2e9='queue';else _0x5c577a['routeId']?_0x3bd2e9=_0x2617f3('0x20'):console[_0x2617f3('0x19')]('EVENT\x20UNKNOWN',_0x5c577a);}else _0x3bd2e9=_0x2617f3('0x7');switch(_0x5030fd[_0x2617f3('0xd')][_0x2617f3('0x6')]()){case _0x2617f3('0x1'):zendesk[_0x3bd2e9](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca);break;case _0x2617f3('0xc'):salesforce[_0x3bd2e9](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca);break;case _0x2617f3('0x5'):sugarcrm[_0x3bd2e9](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca);break;case'freshdesk':freshdesk[_0x3bd2e9](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca);break;case'zoho':zoho[_0x3bd2e9](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca);break;case'desk':desk[_0x3bd2e9](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca);break;case _0x2617f3('0x4'):vtiger[_0x3bd2e9](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca);break;case _0x2617f3('0x3'):freshsales['cs'](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca,_0x3bd2e9);break;case'servicenow':servicenow['cs'](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca,_0x3bd2e9);break;case _0x2617f3('0x1b'):dynamics365['cs'](_0x5030fd,_0x5c577a,_0x2606a0,_0x5e3af9,_0x305340,_0x257df0,_0x47c1ca,_0x3bd2e9);break;default:console[_0x2617f3('0x19')](_0x2617f3('0x22'));}}else _0x1c9cca=require('../../../../config/logger')(_0x5030fd[_0x2617f3('0xd')]['toLowerCase']()),_0x1c9cca[_0x2617f3('0x1c')]('[EXEC]',util[_0x2617f3('0x10')](_0x2617f3('0xb'),_0x5030fd[_0x2617f3('0xd')][_0x2617f3('0x6')](),_0x5030fd['data3']));}else _0x1c9cca=require(_0x2617f3('0x11'))(_0x5030fd[_0x2617f3('0xd')][_0x2617f3('0x6')]()),_0x1c9cca[_0x2617f3('0x1c')](_0x2617f3('0x16'),util[_0x2617f3('0x10')](_0x2617f3('0x17'),_0x5030fd[_0x2617f3('0xd')][_0x2617f3('0x6')](),_0x5030fd[_0x2617f3('0x15')]));}else{}}catch(_0x22bc63){console[_0x2617f3('0x1c')](_0x22bc63);}}}; \ No newline at end of file +const a1140_0x1cc4=['log','./freshsales','vtiger','salesforce','error','includes','EVENT\x20UNKNOWN','./zendesk','data2','unmanaged','queue','zendesk','freshsales','./desk','servicenow','./sugarcrm','freshdesk','desk','dynamics365','Configurations','zoho','util','./vtiger','../../../../config/logger','[EXEC]','outbound','./dynamics365','./servicenow','lodash','data3','toLowerCase','data1'];(function(_0x5a5008,_0x1cc45f){const _0x533259=function(_0xe08fbe){while(--_0xe08fbe){_0x5a5008['push'](_0x5a5008['shift']());}};_0x533259(++_0x1cc45f);}(a1140_0x1cc4,0x14f));const a1140_0x5332=function(_0x5a5008,_0x1cc45f){_0x5a5008=_0x5a5008-0x0;let _0x533259=a1140_0x1cc4[_0x5a5008];return _0x533259;};const _0x42aaf4=a1140_0x5332;'use strict';const _=require(_0x42aaf4('0xd')),util=require(_0x42aaf4('0x6')),zendesk=require(_0x42aaf4('0x18')),salesforce=require('./salesforce'),sugarcrm=require(_0x42aaf4('0x0')),freshdesk=require('./freshdesk'),zoho=require('./zoho'),desk=require(_0x42aaf4('0x1e')),vtiger=require(_0x42aaf4('0x7')),servicenow=require(_0x42aaf4('0xc')),dynamics365=require(_0x42aaf4('0xb')),freshsales=require(_0x42aaf4('0x12')),integrations=[_0x42aaf4('0x1c'),_0x42aaf4('0x14'),'sugarcrm','freshdesk',_0x42aaf4('0x5'),_0x42aaf4('0x2'),_0x42aaf4('0x13'),_0x42aaf4('0x3'),'freshsales','servicenow'];exports['exec']=function(_0xe08fbe,_0x289d2b,_0x1d778c,_0xa5f13b,_0x43592e,_0x501b69){const _0xbcf291=_0x42aaf4;if(_0x1d778c){if(_[_0xbcf291('0x16')](integrations,_0xe08fbe[_0xbcf291('0x10')][_0xbcf291('0xf')]()))try{let _0x36fdfe=null,_0x3fc20f='';const _0x3717d4=_0x1d778c[_0xe08fbe[_0xbcf291('0x10')][_0xbcf291('0xf')]()];if(_0x3717d4){const _0x2c2cd8=_0x3717d4[_0xe08fbe['data2']];if(_0x2c2cd8){const _0x22a494=_['find'](_0x2c2cd8[_0xbcf291('0x4')],{'id':parseInt(_0xe08fbe['data3'],0xa)});if(_0x22a494){if(_0xa5f13b){if(_0x43592e&&_0x289d2b[_0xbcf291('0x1b')])_0x3fc20f=_0xbcf291('0x1b');else _0x289d2b['routeId']?_0x3fc20f=_0xbcf291('0xa'):console[_0xbcf291('0x11')](_0xbcf291('0x17'),_0x289d2b);}else _0x3fc20f=_0xbcf291('0x1a');switch(_0xe08fbe['data1'][_0xbcf291('0xf')]()){case _0xbcf291('0x1c'):zendesk[_0x3fc20f](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69);break;case _0xbcf291('0x14'):salesforce[_0x3fc20f](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69);break;case'sugarcrm':sugarcrm[_0x3fc20f](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69);break;case _0xbcf291('0x1'):freshdesk[_0x3fc20f](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69);break;case'zoho':zoho[_0x3fc20f](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69);break;case _0xbcf291('0x2'):desk[_0x3fc20f](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69);break;case _0xbcf291('0x13'):vtiger[_0x3fc20f](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69);break;case _0xbcf291('0x1d'):freshsales['cs'](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69,_0x3fc20f);break;case _0xbcf291('0x1f'):servicenow['cs'](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69,_0x3fc20f);break;case _0xbcf291('0x3'):dynamics365['cs'](_0xe08fbe,_0x289d2b,_0x22a494,_0xa5f13b,_0x43592e,_0x2c2cd8,_0x501b69,_0x3fc20f);break;default:console[_0xbcf291('0x11')]('unknown\x20integration');}}else _0x36fdfe=require('../../../../config/logger')(_0xe08fbe[_0xbcf291('0x10')][_0xbcf291('0xf')]()),_0x36fdfe[_0xbcf291('0x15')](_0xbcf291('0x9'),util['format']('%s\x20configuration\x20#%s\x20not\x20found',_0xe08fbe['data1']['toLowerCase'](),_0xe08fbe[_0xbcf291('0xe')]));}else _0x36fdfe=require(_0xbcf291('0x8'))(_0xe08fbe[_0xbcf291('0x10')][_0xbcf291('0xf')]()),_0x36fdfe['error'](_0xbcf291('0x9'),util['format']('%s\x20account\x20#%s\x20not\x20found',_0xe08fbe[_0xbcf291('0x10')]['toLowerCase'](),_0xe08fbe[_0xbcf291('0x19')]));}else{}}catch(_0x488d74){console['error'](_0x488d74);}}}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/salesforce.js b/server/services/ami/trigger/integration/salesforce.js index d6bd36a..9a997c7 100644 --- a/server/services/ami/trigger/integration/salesforce.js +++ b/server/services/ami/trigger/integration/salesforce.js @@ -1 +1 @@ -const a1141_0x49cd=['contact','Case','getString','variable','Company','error','none',']\x20Ticket\x20%s\x20created.','Caller\x20-\x20%s','calleridnum','[OUTBOUND]','Salesforce\x20account\x20type\x20not\x20recognized','stripTrailingSlash','catch','Fields','integrationTab','unmanaged','email','find','Descriptions','Name','toLowerCase','user_id','username','upperFirst','recordingFormat','Enduser\x20with\x20phone\x20%s\x20found.','contact_lead','utc','idField','util','lodash','stringify','Searching\x20enduser\x20with\x20phone\x20%s.\x20Serching\x20method\x20used\x20%s.','Phone','Connection','destcalleridname','format','uniqueid','No\x20Company','variableName','display_name','execute','Connection\x20established.','queue','../../../../rediscache','Enduser\x20with\x20phone\x20%s.\x20Creating\x20method\x20used\x20%s.','md5','type','lead','salesforce','outbound','forEach','info','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','newTab','[QUEUE]\x20Displaying\x20ticket\x20%s\x20to\x20agent\x20%s.\x20Integration\x20account\x20type\x20%s.','Subjects','length','Agent\x20%s\x20not\x20found.\x20Switch\x20to\x20the\x20admin\x20account.','remoteUri','%s/%s/e','concat','create','recordingURL','[OUTBOUND]\x20Displaying\x20ticket\x20%s\x20to\x20agent\x20%s.\x20Integration\x20account\x20type\x20%s.','toUpperCase','user:%s','lastevent','./util','customVariable',']\x20Integration\x20account\x20type\x20%s.','Enduser\x20with\x20phone\x20%s\x20not\x20found.','clientId','toString','trigger:salesforce:display','Task','instanceUrl','trigger:browser:url','ticketType','Agent\x20%s\x20found.','resolve','ContactId','emit','WhoId','serverUrl','Contact','clientSecret','[QUEUE]','[OUTBOUND]\x20Ticket\x20%s\x20created.','monitor_format','destcalleridnum','moduleCreate','Variable','identity','Lead','then','sobject','isNil','Recording\x20is\x20enabled!','name','calleridname','jsforce'];(function(_0x1730df,_0x49cdad){const _0x54e3c4=function(_0xe8fe59){while(--_0xe8fe59){_0x1730df['push'](_0x1730df['shift']());}};_0x54e3c4(++_0x49cdad);}(a1141_0x49cd,0xb8));const a1141_0x54e3=function(_0x1730df,_0x49cdad){_0x1730df=_0x1730df-0x0;let _0x54e3c4=a1141_0x49cd[_0x1730df];return _0x54e3c4;};const _0x44fee0=a1141_0x54e3;'use strict';const _=require(_0x44fee0('0x35')),moment=require('moment'),md5=require(_0x44fee0('0x45')),jsforce=require(_0x44fee0('0x15')),util=require(_0x44fee0('0x34')),intUtil=require(_0x44fee0('0x5b')),logger=require('../../../../config/logger')(_0x44fee0('0x48')),{getSocket}=require(_0x44fee0('0x43')),io=getSocket();function emit(_0xe8fe59,_0x4b82d3,_0x1abdf2){const _0x4931a2=_0x44fee0;io['to'](_0xe8fe59)[_0x4931a2('0x2')](_0x4b82d3,_0x1abdf2);}function getTicket(_0x5df954,_0x32d6ea,_0xe6fcc1,_0x5ca6fe,_0x5c4ffc,_0x373842,_0x2e459c){const _0x1f3df8=_0x44fee0;let _0x4010f6={};if(_0x5ca6fe[_0x1f3df8('0x65')]===_0x1f3df8('0x62'))_0x4010f6=Object['assign']({},{'OwnerId':_0x32d6ea['id'],'ActivityDate':moment[_0x1f3df8('0x32')](),'IsReminderSet':![],'IsRecurrence':![],'Subject':intUtil[_0x1f3df8('0x18')](_0x5ca6fe[_0x1f3df8('0x4f')],_0x5c4ffc,'\x20'),'Description':intUtil[_0x1f3df8('0x18')](_0x5ca6fe['Descriptions'],_0x5c4ffc,'\x0a')},getCustomFields(_0x373842,_0x5c4ffc)),_0xe6fcc1&&(_0x4010f6[_0x1f3df8('0x3')]=_0xe6fcc1['id']);else _0x5ca6fe['ticketType']===_0x1f3df8('0x17')&&(_0x4010f6=Object['assign']({},{'OwnerId':_0x32d6ea['id'],'Subject':intUtil[_0x1f3df8('0x18')](_0x5ca6fe[_0x1f3df8('0x4f')],_0x5c4ffc,'\x20'),'Description':intUtil[_0x1f3df8('0x18')](_0x5ca6fe[_0x1f3df8('0x29')],_0x5c4ffc,'\x0a')},getCustomFields(_0x373842,_0x5c4ffc)),_0xe6fcc1&&(_0x4010f6[_0x1f3df8('0x1')]=_0xe6fcc1['id']));return _0x2e459c[_0x1f3df8('0x10')](_0x5ca6fe['ticketType'])[_0x1f3df8('0x55')](_0x4010f6);}function getUser(_0x319f09,_0xc8d9d6,_0x43f49b){const _0x26151a=_0x44fee0;if(!_[_0x26151a('0x11')](_0xc8d9d6)&&intUtil['validateEmail'](_0xc8d9d6)){const _0x740a5d={'Email':_0xc8d9d6},_0x50d02e={'Id':!![],'Username':!![],'Name':!![],'Email':!![]};return _0x43f49b[_0x26151a('0x10')]('User')[_0x26151a('0x28')](_0x740a5d,_0x50d02e)[_0x26151a('0x40')]()[_0x26151a('0xf')](function(_0x4feabf){const _0x805d6=_0x26151a;if(_0x4feabf[_0x805d6('0x50')]){const _0x18c707=_[_0x805d6('0x28')](_0x4feabf,function(_0xc21469){return _0xc21469['Email']===_0xc8d9d6;});if(_0x18c707)return logger['info'](_0x805d6('0x66'),_0xc8d9d6),Promise[_0x805d6('0x0')]({'id':_0x18c707['Id'],'name':_0x18c707[_0x805d6('0x2a')]});}else return logger[_0x805d6('0x4b')](_0x805d6('0x51'),_0xc8d9d6),_0x43f49b[_0x805d6('0xd')]()[_0x805d6('0xf')](function(_0x4b9679){const _0x4b31b4=_0x805d6;return Promise[_0x4b31b4('0x0')]({'id':_0x4b9679[_0x4b31b4('0x2c')],'name':_0x4b9679[_0x4b31b4('0x3f')]});});});}else return logger[_0x26151a('0x4b')](_0x26151a('0x51'),_0xc8d9d6),_0x43f49b[_0x26151a('0xd')]()[_0x26151a('0xf')](function(_0x5365b3){const _0x53de75=_0x26151a;return Promise[_0x53de75('0x0')]({'id':_0x5365b3[_0x53de75('0x2c')],'name':_0x5365b3[_0x53de75('0x3f')]});});}function getEndUser(_0x21e61c,_0xa85607,_0xa5c4ec,_0x52ecb4,_0x2d7df6){const _0x4fa806=_0x44fee0,_0x213281={'Phone':_0x52ecb4},_0x43102e={'Id':!![],'Name':!![],'Phone':!![]};return Promise[_0x4fa806('0x0')]()[_0x4fa806('0xf')](function(){const _0x3c8170=_0x4fa806;if(_0xa85607[_0x3c8170('0x65')]==='Task'){logger[_0x3c8170('0x4b')](_0x3c8170('0x37'),_0x52ecb4,_0xa85607['moduleSearch']);switch(_0xa85607['moduleSearch']){case _0x3c8170('0x31'):return _0x2d7df6[_0x3c8170('0x10')](_0x3c8170('0x5'))['find'](_0x213281,_0x43102e)[_0x3c8170('0x40')]()[_0x3c8170('0xf')](function(_0x4e0970){const _0x10211a=_0x3c8170;return _0x4e0970&&_0x4e0970[_0x10211a('0x50')]?_0x4e0970:_0x2d7df6[_0x10211a('0x10')](_0x10211a('0xe'))['find'](_0x213281,_0x43102e);});case _0x3c8170('0x16'):return _0x2d7df6[_0x3c8170('0x10')](_0x3c8170('0x5'))[_0x3c8170('0x28')](_0x213281,_0x43102e)[_0x3c8170('0x40')]();case'lead':return _0x2d7df6['sobject'](_0x3c8170('0xe'))['find'](_0x213281,_0x43102e);default:return null;}}else{if(_0xa85607[_0x3c8170('0x65')]===_0x3c8170('0x17'))return logger['info'](_0x3c8170('0x37'),_0x52ecb4,_0x3c8170('0x16')),_0x2d7df6[_0x3c8170('0x10')](_0x3c8170('0x5'))[_0x3c8170('0x28')](_0x213281,_0x43102e)[_0x3c8170('0x40')]();}})['then'](function(_0x5d1726){const _0x27cb4e=_0x4fa806;if(_0x5d1726&&_0x5d1726[_0x27cb4e('0x50')]){const _0x191a0a=_['find'](_0x5d1726,function(_0x36cfa4){const _0x2933e4=_0x27cb4e;return _0x36cfa4[_0x2933e4('0x38')]===_0x52ecb4;});if(_0x191a0a)return Promise[_0x27cb4e('0x0')]({'id':_0x191a0a['Id'],'name':_0x191a0a[_0x27cb4e('0x2a')],'phone':_0x191a0a[_0x27cb4e('0x38')]});}})[_0x4fa806('0xf')](function(_0x2973f0){const _0xa59073=_0x4fa806;if(_0x2973f0)return logger[_0xa59073('0x4b')](_0xa59073('0x30'),_0x52ecb4),Promise[_0xa59073('0x0')](_0x2973f0);else{logger[_0xa59073('0x4b')](_0xa59073('0x5e'),_0x52ecb4);const _0x4d0585={'LastName':_0xa5c4ec!==''?_0xa5c4ec:util['format'](_0xa59073('0x1e'),_0x52ecb4),'Phone':_0x52ecb4};if(_0xa85607['moduleCreate']){if(_0xa85607['moduleCreate']===_0xa59073('0x16'))logger[_0xa59073('0x4b')](_0xa59073('0x44'),_0x52ecb4,_0xa85607[_0xa59073('0xb')]);else{if(_0xa85607['moduleCreate']===_0xa59073('0x47')&&_0xa85607[_0xa59073('0x65')]===_0xa59073('0x62'))logger[_0xa59073('0x4b')]('Enduser\x20with\x20phone\x20%s.\x20Creating\x20method\x20used\x20%s.',_0x52ecb4,_0xa85607[_0xa59073('0xb')]),_0x4d0585[_0xa59073('0x1a')]=_0xa59073('0x3d');else return null;}}return _0x2d7df6[_0xa59073('0x10')](_[_0xa59073('0x2e')](_0xa85607[_0xa59073('0xb')]))[_0xa59073('0x55')](_0x4d0585);}});}function getCustomFields(_0x3564fe,_0x4c1505){const _0x41820f=_0x44fee0,_0x5d6142={};return _0x3564fe[_0x41820f('0x50')]>0x0&&_[_0x41820f('0x4a')](_0x3564fe,function(_0x17c0cb){const _0x5ad2b3=_0x41820f;if(_0x17c0cb[_0x5ad2b3('0x46')]==='string'&&_0x17c0cb[_0x5ad2b3('0x33')])_0x5d6142[_0x17c0cb[_0x5ad2b3('0x33')]]=_0x17c0cb['content']['toString']();else{if(_0x17c0cb[_0x5ad2b3('0x46')]===_0x5ad2b3('0x19')&&_0x17c0cb['variableName']&&_0x17c0cb[_0x5ad2b3('0x33')])_0x4c1505[_0x17c0cb[_0x5ad2b3('0x3e')]]&&(_0x5d6142[_0x17c0cb[_0x5ad2b3('0x33')]]=_0x4c1505[_0x17c0cb[_0x5ad2b3('0x3e')]][_0x5ad2b3('0x60')]());else _0x17c0cb[_0x5ad2b3('0x46')]===_0x5ad2b3('0x5c')&&_0x17c0cb[_0x5ad2b3('0xc')]&&_0x17c0cb[_0x5ad2b3('0xc')][_0x5ad2b3('0x13')]&&_0x17c0cb[_0x5ad2b3('0x33')]&&(_0x4c1505[_0x17c0cb[_0x5ad2b3('0xc')]['name'][_0x5ad2b3('0x2b')]()]&&(_0x5d6142[_0x17c0cb[_0x5ad2b3('0x33')]]=_0x4c1505[_0x17c0cb[_0x5ad2b3('0xc')]['name'][_0x5ad2b3('0x2b')]()][_0x5ad2b3('0x60')]()));}}),_0x5d6142;}function getConnection(_0x429a17){const _0x5d402f=_0x44fee0,_0x411ef6=_0x429a17['password'][_0x5d402f('0x54')](_0x429a17['securityToken']),_0x19af45=new jsforce[(_0x5d402f('0x39'))]({'oauth2':{'loginUrl':_0x429a17['remoteUri']||'https://login.salesforce.com','clientId':_0x429a17[_0x5d402f('0x5f')],'clientSecret':_0x429a17[_0x5d402f('0x6')]}});return _0x19af45['login'](_0x429a17[_0x5d402f('0x2d')],_0x411ef6)[_0x5d402f('0xf')](function(){const _0x2ca286=_0x5d402f;return logger['info'](_0x2ca286('0x41')),_0x19af45;});}exports['queue']=function(_0x110a42,_0x15271f,_0x36ef1f,_0x20c8e1,_0x1986cc,_0x3c00f3){const _0x4b9a6c=_0x44fee0;let _0xcefc35,_0x96f7e1,_0x2acc06,_0x4874cd;return _0x3c00f3['serverUrl']=intUtil[_0x4b9a6c('0x22')](_0x3c00f3[_0x4b9a6c('0x4')]),_0x3c00f3['remoteUri']=intUtil[_0x4b9a6c('0x22')](_0x3c00f3[_0x4b9a6c('0x52')]),_0x1986cc&&_0x1986cc[_0x4b9a6c('0x9')]?(logger[_0x4b9a6c('0x4b')](_0x4b9a6c('0x7'),_0x4b9a6c('0x12')),_0x15271f['recordingURL']=util[_0x4b9a6c('0x3b')](_0x4b9a6c('0x4c'),_0x3c00f3[_0x4b9a6c('0x4')],_0x15271f[_0x4b9a6c('0x3c')],md5(_0x15271f['uniqueid']))):_0x15271f[_0x4b9a6c('0x56')]='',getConnection(_0x3c00f3)[_0x4b9a6c('0xf')](function(_0x1cfcd6){const _0x30a9f1=_0x4b9a6c;return _0x4874cd=_0x1cfcd6,getUser(_0x3c00f3,_0x20c8e1[_0x30a9f1('0x27')],_0x4874cd);})[_0x4b9a6c('0xf')](function(_0x2b9f09){const _0xf07cb7=_0x4b9a6c;return _0xcefc35=_0x2b9f09,getEndUser(_0x3c00f3,_0x36ef1f,_0x15271f[_0xf07cb7('0x14')],_0x15271f[_0xf07cb7('0x1f')],_0x4874cd);})[_0x4b9a6c('0xf')](function(_0x1e48e4){const _0x3d590b=_0x4b9a6c;return _0x96f7e1=_0x1e48e4,getTicket(_0x3c00f3,_0xcefc35,_0x96f7e1,_0x36ef1f,_0x15271f,_0x36ef1f[_0x3d590b('0x24')],_0x4874cd,_0x3d590b('0x42'));})[_0x4b9a6c('0xf')](function(_0x2f1076){const _0x5ca29c=_0x4b9a6c;_0x2acc06=_0x2f1076,logger[_0x5ca29c('0x4b')]('[QUEUE]\x20Ticket\x20%s\x20created',_0x2acc06['id']),logger['info'](_0x5ca29c('0x4e'),_0x2acc06['id'],_0x20c8e1[_0x5ca29c('0x13')],_0x3c00f3[_0x5ca29c('0x46')]);switch(_0x3c00f3[_0x5ca29c('0x46')]){case _0x5ca29c('0x25'):emit(util[_0x5ca29c('0x3b')](_0x5ca29c('0x59'),_0x20c8e1[_0x5ca29c('0x13')]),'trigger:salesforce:display',{'recordId':_0x2acc06['id']});break;case _0x5ca29c('0x4d'):emit(util['format'](_0x5ca29c('0x59'),_0x20c8e1[_0x5ca29c('0x13')]),_0x5ca29c('0x64'),{'uri':util[_0x5ca29c('0x3b')](_0x5ca29c('0x53'),_0x4874cd[_0x5ca29c('0x63')],_0x2acc06['id'])});break;default:logger['error']('[QUEUE]\x20Salesforce\x20account\x20type\x20not\x20recognized.');}})[_0x4b9a6c('0x23')](function(_0x5f28ef){const _0x6e385a=_0x4b9a6c;logger[_0x6e385a('0x1b')]('[QUEUE]',JSON[_0x6e385a('0x36')](_0x5f28ef));});},exports[_0x44fee0('0x49')]=function(_0x2e9be1,_0x20a392,_0x5d14a7,_0x24c99a,_0x459871,_0x4ec775,_0x4b7fea){const _0x28490f=_0x44fee0;let _0x569b47,_0x567b48,_0x12bb02,_0x28be81;return _0x4ec775[_0x28490f('0x4')]=intUtil[_0x28490f('0x22')](_0x4ec775[_0x28490f('0x4')]),_0x4ec775[_0x28490f('0x52')]=intUtil[_0x28490f('0x22')](_0x4ec775[_0x28490f('0x52')]),_0x4b7fea&&_0x4b7fea[_0x28490f('0x2f')]&&_0x4b7fea[_0x28490f('0x2f')]!==_0x28490f('0x1c')&&(logger['info'](_0x28490f('0x20'),'Recording\x20is\x20enabled!'),_0x20a392[_0x28490f('0x56')]=util[_0x28490f('0x3b')](_0x28490f('0x4c'),_0x4ec775[_0x28490f('0x4')],_0x20a392[_0x28490f('0x3c')],md5(_0x20a392['uniqueid']))),getConnection(_0x4ec775)[_0x28490f('0xf')](function(_0x3a8ddd){const _0x4e4897=_0x28490f;return _0x28be81=_0x3a8ddd,getUser(_0x4ec775,_0x24c99a[_0x4e4897('0x27')],_0x28be81);})[_0x28490f('0xf')](function(_0x37f9bb){const _0x409580=_0x28490f;return _0x569b47=_0x37f9bb,getEndUser(_0x4ec775,_0x5d14a7,_0x20a392[_0x409580('0x3a')],_0x20a392[_0x409580('0xa')],_0x28be81);})[_0x28490f('0xf')](function(_0x26f18a){const _0x5d91f1=_0x28490f;return _0x567b48=_0x26f18a,getTicket(_0x4ec775,_0x569b47,_0x567b48,_0x5d14a7,_0x20a392,_0x5d14a7[_0x5d91f1('0x24')],_0x28be81,_0x5d91f1('0x49'));})['then'](function(_0x34dff0){const _0x544811=_0x28490f;_0x12bb02=_0x34dff0,logger[_0x544811('0x4b')](_0x544811('0x8'),_0x12bb02['id']),logger['info'](_0x544811('0x57'),_0x12bb02['id'],_0x24c99a[_0x544811('0x13')],_0x4ec775[_0x544811('0x46')]);switch(_0x4ec775['type']){case'integrationTab':emit(util[_0x544811('0x3b')](_0x544811('0x59'),_0x24c99a[_0x544811('0x13')]),_0x544811('0x61'),{'recordId':_0x12bb02['id']});break;case _0x544811('0x4d'):emit(util['format'](_0x544811('0x59'),_0x24c99a[_0x544811('0x13')]),_0x544811('0x64'),{'uri':util[_0x544811('0x3b')](_0x544811('0x53'),_0x28be81['instanceUrl'],_0x12bb02['id'])});break;default:logger[_0x544811('0x1b')](_0x544811('0x20'),_0x544811('0x21'));}})[_0x28490f('0x23')](function(_0x27c464){const _0x2b783c=_0x28490f;logger[_0x2b783c('0x1b')]('[OUTBOUND]',JSON[_0x2b783c('0x36')](_0x27c464));});},exports[_0x44fee0('0x26')]=function(_0x1ca63b,_0x41f1c4,_0x6716f5,_0x301f92,_0x331bc0,_0x105522){const _0x3ce40b=_0x44fee0;let _0x1848f9,_0xaafab7,_0x3f811d,_0x5bd153;return _0x105522[_0x3ce40b('0x4')]=intUtil[_0x3ce40b('0x22')](_0x105522[_0x3ce40b('0x4')]),_0x105522['remoteUri']=intUtil[_0x3ce40b('0x22')](_0x105522['remoteUri']),_0x331bc0&&_0x331bc0[_0x3ce40b('0x9')]?(logger[_0x3ce40b('0x4b')]('['+_0x41f1c4['lastevent'][_0x3ce40b('0x58')]()+']',_0x3ce40b('0x12')),_0x41f1c4[_0x3ce40b('0x56')]=util['format'](_0x3ce40b('0x4c'),_0x105522[_0x3ce40b('0x4')],_0x41f1c4[_0x3ce40b('0x3c')],md5(_0x41f1c4[_0x3ce40b('0x3c')]))):_0x41f1c4[_0x3ce40b('0x56')]='',getConnection(_0x105522)[_0x3ce40b('0xf')](function(_0x3e1b0b){const _0x2bcdb3=_0x3ce40b;return _0x5bd153=_0x3e1b0b,!_['isNil'](_0x301f92)?getUser(_0x105522,_0x301f92[_0x2bcdb3('0x13')],_0x5bd153):getUser(_0x105522,null,_0x5bd153);})['then'](function(_0x27d503){const _0x1e1d77=_0x3ce40b;return _0x1848f9=_0x27d503,getEndUser(_0x105522,_0x6716f5,_0x41f1c4[_0x1e1d77('0x14')],_0x41f1c4['calleridnum'],_0x5bd153);})[_0x3ce40b('0xf')](function(_0x35ef1){return _0xaafab7=_0x35ef1,getTicket(_0x105522,_0x1848f9,_0xaafab7,_0x6716f5,_0x41f1c4,_0x6716f5['Fields'],_0x5bd153);})[_0x3ce40b('0xf')](function(_0x5313f2){const _0x57d17a=_0x3ce40b;_0x3f811d=_0x5313f2,logger[_0x57d17a('0x4b')]('['+_0x41f1c4[_0x57d17a('0x5a')]['toUpperCase']()+_0x57d17a('0x1d'),_0x3f811d['id']),logger[_0x57d17a('0x4b')]('['+_0x41f1c4[_0x57d17a('0x5a')][_0x57d17a('0x58')]()+_0x57d17a('0x5d'),_0x105522[_0x57d17a('0x46')]);})[_0x3ce40b('0x23')](function(_0xefe4e3){const _0x18df71=_0x3ce40b;logger['error']('['+_0x41f1c4['lastevent'][_0x18df71('0x58')]()+']',JSON[_0x18df71('0x36')](_0xefe4e3));});}; \ No newline at end of file +const a1141_0xa206=['name','Company','variableName','Name','Variable','Caller\x20-\x20%s','clientId','Fields','moduleSearch','emit','Lead','[OUTBOUND]\x20Displaying\x20ticket\x20%s\x20to\x20agent\x20%s.\x20Integration\x20account\x20type\x20%s.','No\x20Company','[OUTBOUND]\x20Ticket\x20%s\x20created.','trigger:salesforce:display','lastevent','Enduser\x20with\x20phone\x20%s\x20found.','[QUEUE]','Email','toUpperCase','trigger:browser:url','contact_lead','lodash','[QUEUE]\x20Ticket\x20%s\x20created','Agent\x20%s\x20not\x20found.\x20Switch\x20to\x20the\x20admin\x20account.','format','Searching\x20enduser\x20with\x20phone\x20%s.\x20Serching\x20method\x20used\x20%s.','jsforce','then','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','display_name','util','','[QUEUE]\x20Salesforce\x20account\x20type\x20not\x20recognized.','destcalleridname','toLowerCase',']\x20Ticket\x20%s\x20created.','contact','create','moment','Enduser\x20with\x20phone\x20%s.\x20Creating\x20method\x20used\x20%s.','unmanaged','%s/%s/e','moduleCreate','outbound','resolve','remoteUri','salesforce','Enduser\x20with\x20phone\x20%s\x20not\x20found.','catch','assign','queue','customVariable','getString','utc','idField','integrationTab','string','username','newTab','none','toString','destcalleridnum','WhoId','calleridname','stringify','../../../../rediscache','concat','Phone','instanceUrl','forEach','info','User','uniqueid','Recording\x20is\x20enabled!','Case','Salesforce\x20account\x20type\x20not\x20recognized','type','Task','variable','user:%s','password','Connection\x20established.','sobject','Connection','execute','stripTrailingSlash','ContactId','Contact','email','recordingURL','clientSecret','monitor_format','ticketType','upperFirst','user_id','lead','serverUrl','content','isNil','md5','securityToken','find','Subjects','identity','length','error','[OUTBOUND]','../../../../config/logger'];(function(_0xd354e2,_0xa2061c){const _0x5a9e70=function(_0x9ed146){while(--_0x9ed146){_0xd354e2['push'](_0xd354e2['shift']());}};_0x5a9e70(++_0xa2061c);}(a1141_0xa206,0xc5));const a1141_0x5a9e=function(_0xd354e2,_0xa2061c){_0xd354e2=_0xd354e2-0x0;let _0x5a9e70=a1141_0xa206[_0xd354e2];return _0x5a9e70;};const _0x21398a=a1141_0x5a9e;'use strict';const _=require(_0x21398a('0x2b')),moment=require(_0x21398a('0x3c')),md5=require(_0x21398a('0xc')),jsforce=require(_0x21398a('0x30')),util=require(_0x21398a('0x34')),intUtil=require('./util'),logger=require(_0x21398a('0x14'))(_0x21398a('0x44')),{getSocket}=require(_0x21398a('0x57')),io=getSocket();function emit(_0x9ed146,_0x5b7d38,_0x13ba86){const _0x22af2b=_0x21398a;io['to'](_0x9ed146)[_0x22af2b('0x1e')](_0x5b7d38,_0x13ba86);}function getTicket(_0x62d23,_0x356d3a,_0x675190,_0x495e78,_0x5a8d02,_0x11f0ac,_0x3a9dae){const _0x339ba9=_0x21398a;let _0x3c2a92={};if(_0x495e78[_0x339ba9('0x5')]===_0x339ba9('0x63'))_0x3c2a92=Object['assign']({},{'OwnerId':_0x356d3a['id'],'ActivityDate':moment[_0x339ba9('0x4b')](),'IsReminderSet':![],'IsRecurrence':![],'Subject':intUtil[_0x339ba9('0x4a')](_0x495e78['Subjects'],_0x5a8d02,'\x20'),'Description':intUtil[_0x339ba9('0x4a')](_0x495e78['Descriptions'],_0x5a8d02,'\x0a')},getCustomFields(_0x11f0ac,_0x5a8d02)),_0x675190&&(_0x3c2a92[_0x339ba9('0x54')]=_0x675190['id']);else _0x495e78[_0x339ba9('0x5')]===_0x339ba9('0x60')&&(_0x3c2a92=Object[_0x339ba9('0x47')]({},{'OwnerId':_0x356d3a['id'],'Subject':intUtil[_0x339ba9('0x4a')](_0x495e78[_0x339ba9('0xf')],_0x5a8d02,'\x20'),'Description':intUtil[_0x339ba9('0x4a')](_0x495e78['Descriptions'],_0x5a8d02,'\x0a')},getCustomFields(_0x11f0ac,_0x5a8d02)),_0x675190&&(_0x3c2a92[_0x339ba9('0x6c')]=_0x675190['id']));return _0x3a9dae['sobject'](_0x495e78[_0x339ba9('0x5')])[_0x339ba9('0x3b')](_0x3c2a92);}function getUser(_0x4d8c5b,_0x266872,_0x5c6b77){const _0x2963a3=_0x21398a;if(!_[_0x2963a3('0xb')](_0x266872)&&intUtil['validateEmail'](_0x266872)){const _0xa9fb06={'Email':_0x266872},_0xf0d49e={'Id':!![],'Username':!![],'Name':!![],'Email':!![]};return _0x5c6b77[_0x2963a3('0x68')](_0x2963a3('0x5d'))[_0x2963a3('0xe')](_0xa9fb06,_0xf0d49e)['execute']()[_0x2963a3('0x31')](function(_0x31ef1a){const _0x5b5b8a=_0x2963a3;if(_0x31ef1a['length']){const _0x27fc3e=_['find'](_0x31ef1a,function(_0x26a0a3){const _0x2dada3=a1141_0x5a9e;return _0x26a0a3[_0x2dada3('0x27')]===_0x266872;});if(_0x27fc3e)return logger[_0x5b5b8a('0x5c')]('Agent\x20%s\x20found.',_0x266872),Promise[_0x5b5b8a('0x42')]({'id':_0x27fc3e['Id'],'name':_0x27fc3e['Name']});}else return logger[_0x5b5b8a('0x5c')]('Agent\x20%s\x20not\x20found.\x20Switch\x20to\x20the\x20admin\x20account.',_0x266872),_0x5c6b77[_0x5b5b8a('0x10')]()[_0x5b5b8a('0x31')](function(_0x4d9563){const _0x325090=_0x5b5b8a;return Promise[_0x325090('0x42')]({'id':_0x4d9563['user_id'],'name':_0x4d9563[_0x325090('0x33')]});});});}else return logger['info'](_0x2963a3('0x2d'),_0x266872),_0x5c6b77['identity']()[_0x2963a3('0x31')](function(_0x242de7){const _0x2433e6=_0x2963a3;return Promise[_0x2433e6('0x42')]({'id':_0x242de7[_0x2433e6('0x7')],'name':_0x242de7['display_name']});});}function getEndUser(_0x234b17,_0x23df9b,_0x464ed9,_0x2f9ad2,_0x3c1d94){const _0x57a4a=_0x21398a,_0x36f922={'Phone':_0x2f9ad2},_0x3b89e0={'Id':!![],'Name':!![],'Phone':!![]};return Promise[_0x57a4a('0x42')]()[_0x57a4a('0x31')](function(){const _0x3ba3e9=_0x57a4a;if(_0x23df9b['ticketType']===_0x3ba3e9('0x63')){logger[_0x3ba3e9('0x5c')](_0x3ba3e9('0x2f'),_0x2f9ad2,_0x23df9b[_0x3ba3e9('0x1d')]);switch(_0x23df9b[_0x3ba3e9('0x1d')]){case _0x3ba3e9('0x2a'):return _0x3c1d94[_0x3ba3e9('0x68')]('Contact')[_0x3ba3e9('0xe')](_0x36f922,_0x3b89e0)[_0x3ba3e9('0x6a')]()['then'](function(_0x2b9522){const _0x403518=_0x3ba3e9;return _0x2b9522&&_0x2b9522[_0x403518('0x11')]?_0x2b9522:_0x3c1d94['sobject'](_0x403518('0x1f'))['find'](_0x36f922,_0x3b89e0);});case'contact':return _0x3c1d94[_0x3ba3e9('0x68')](_0x3ba3e9('0x0'))[_0x3ba3e9('0xe')](_0x36f922,_0x3b89e0)['execute']();case _0x3ba3e9('0x8'):return _0x3c1d94['sobject'](_0x3ba3e9('0x1f'))[_0x3ba3e9('0xe')](_0x36f922,_0x3b89e0);default:return null;}}else{if(_0x23df9b['ticketType']==='Case')return logger[_0x3ba3e9('0x5c')]('Searching\x20enduser\x20with\x20phone\x20%s.\x20Serching\x20method\x20used\x20%s.',_0x2f9ad2,_0x3ba3e9('0x3a')),_0x3c1d94[_0x3ba3e9('0x68')](_0x3ba3e9('0x0'))['find'](_0x36f922,_0x3b89e0)[_0x3ba3e9('0x6a')]();}})[_0x57a4a('0x31')](function(_0xedd18e){const _0xcab860=_0x57a4a;if(_0xedd18e&&_0xedd18e[_0xcab860('0x11')]){const _0x297c78=_[_0xcab860('0xe')](_0xedd18e,function(_0x59beb3){const _0x2dd0d3=_0xcab860;return _0x59beb3[_0x2dd0d3('0x59')]===_0x2f9ad2;});if(_0x297c78)return Promise['resolve']({'id':_0x297c78['Id'],'name':_0x297c78[_0xcab860('0x18')],'phone':_0x297c78[_0xcab860('0x59')]});}})[_0x57a4a('0x31')](function(_0xb33b74){const _0x486663=_0x57a4a;if(_0xb33b74)return logger['info'](_0x486663('0x25'),_0x2f9ad2),Promise['resolve'](_0xb33b74);else{logger[_0x486663('0x5c')](_0x486663('0x45'),_0x2f9ad2);const _0x4b8c88={'LastName':_0x464ed9!==_0x486663('0x35')?_0x464ed9:util[_0x486663('0x2e')](_0x486663('0x1a'),_0x2f9ad2),'Phone':_0x2f9ad2};if(_0x23df9b['moduleCreate']){if(_0x23df9b['moduleCreate']===_0x486663('0x3a'))logger[_0x486663('0x5c')](_0x486663('0x3d'),_0x2f9ad2,_0x23df9b[_0x486663('0x40')]);else{if(_0x23df9b[_0x486663('0x40')]===_0x486663('0x8')&&_0x23df9b[_0x486663('0x5')]==='Task')logger[_0x486663('0x5c')](_0x486663('0x3d'),_0x2f9ad2,_0x23df9b[_0x486663('0x40')]),_0x4b8c88[_0x486663('0x16')]=_0x486663('0x21');else return null;}}return _0x3c1d94['sobject'](_[_0x486663('0x6')](_0x23df9b[_0x486663('0x40')]))['create'](_0x4b8c88);}});}function getCustomFields(_0xf08132,_0x24cbc7){const _0x28647c=_0x21398a,_0x2da4f8={};return _0xf08132['length']>0x0&&_[_0x28647c('0x5b')](_0xf08132,function(_0x84e92d){const _0x560f0c=_0x28647c;if(_0x84e92d[_0x560f0c('0x62')]===_0x560f0c('0x4e')&&_0x84e92d['idField'])_0x2da4f8[_0x84e92d[_0x560f0c('0x4c')]]=_0x84e92d[_0x560f0c('0xa')][_0x560f0c('0x52')]();else{if(_0x84e92d[_0x560f0c('0x62')]===_0x560f0c('0x64')&&_0x84e92d[_0x560f0c('0x17')]&&_0x84e92d[_0x560f0c('0x4c')])_0x24cbc7[_0x84e92d['variableName']]&&(_0x2da4f8[_0x84e92d['idField']]=_0x24cbc7[_0x84e92d[_0x560f0c('0x17')]][_0x560f0c('0x52')]());else _0x84e92d['type']===_0x560f0c('0x49')&&_0x84e92d[_0x560f0c('0x19')]&&_0x84e92d[_0x560f0c('0x19')][_0x560f0c('0x15')]&&_0x84e92d['idField']&&(_0x24cbc7[_0x84e92d['Variable'][_0x560f0c('0x15')][_0x560f0c('0x38')]()]&&(_0x2da4f8[_0x84e92d['idField']]=_0x24cbc7[_0x84e92d[_0x560f0c('0x19')][_0x560f0c('0x15')][_0x560f0c('0x38')]()][_0x560f0c('0x52')]()));}}),_0x2da4f8;}function getConnection(_0x3757f8){const _0x2fe1d8=_0x21398a,_0x57bcb0=_0x3757f8[_0x2fe1d8('0x66')][_0x2fe1d8('0x58')](_0x3757f8[_0x2fe1d8('0xd')]),_0x38b6cf=new jsforce[(_0x2fe1d8('0x69'))]({'oauth2':{'loginUrl':_0x3757f8[_0x2fe1d8('0x43')]||'https://login.salesforce.com','clientId':_0x3757f8[_0x2fe1d8('0x1b')],'clientSecret':_0x3757f8[_0x2fe1d8('0x3')]}});return _0x38b6cf['login'](_0x3757f8[_0x2fe1d8('0x4f')],_0x57bcb0)[_0x2fe1d8('0x31')](function(){const _0x4de240=_0x2fe1d8;return logger[_0x4de240('0x5c')](_0x4de240('0x67')),_0x38b6cf;});}exports['queue']=function(_0x4f00ea,_0x2c586d,_0x825197,_0x5b17e0,_0x300312,_0x5399a9){const _0x1ef258=_0x21398a;let _0x1e92e5,_0xcde5a8,_0x3583f2,_0x46d654;return _0x5399a9[_0x1ef258('0x9')]=intUtil[_0x1ef258('0x6b')](_0x5399a9['serverUrl']),_0x5399a9['remoteUri']=intUtil[_0x1ef258('0x6b')](_0x5399a9[_0x1ef258('0x43')]),_0x300312&&_0x300312[_0x1ef258('0x4')]?(logger['info']('[QUEUE]',_0x1ef258('0x5f')),_0x2c586d[_0x1ef258('0x2')]=util['format'](_0x1ef258('0x32'),_0x5399a9['serverUrl'],_0x2c586d[_0x1ef258('0x5e')],md5(_0x2c586d[_0x1ef258('0x5e')]))):_0x2c586d[_0x1ef258('0x2')]='',getConnection(_0x5399a9)[_0x1ef258('0x31')](function(_0x5bfb09){const _0x56faf2=_0x1ef258;return _0x46d654=_0x5bfb09,getUser(_0x5399a9,_0x5b17e0[_0x56faf2('0x1')],_0x46d654);})[_0x1ef258('0x31')](function(_0x9d72e){const _0xbb5a48=_0x1ef258;return _0x1e92e5=_0x9d72e,getEndUser(_0x5399a9,_0x825197,_0x2c586d[_0xbb5a48('0x55')],_0x2c586d['calleridnum'],_0x46d654);})['then'](function(_0x269511){const _0x2784dc=_0x1ef258;return _0xcde5a8=_0x269511,getTicket(_0x5399a9,_0x1e92e5,_0xcde5a8,_0x825197,_0x2c586d,_0x825197[_0x2784dc('0x1c')],_0x46d654,_0x2784dc('0x48'));})[_0x1ef258('0x31')](function(_0x4e9ae2){const _0x4aba16=_0x1ef258;_0x3583f2=_0x4e9ae2,logger[_0x4aba16('0x5c')](_0x4aba16('0x2c'),_0x3583f2['id']),logger[_0x4aba16('0x5c')]('[QUEUE]\x20Displaying\x20ticket\x20%s\x20to\x20agent\x20%s.\x20Integration\x20account\x20type\x20%s.',_0x3583f2['id'],_0x5b17e0[_0x4aba16('0x15')],_0x5399a9[_0x4aba16('0x62')]);switch(_0x5399a9[_0x4aba16('0x62')]){case _0x4aba16('0x4d'):emit(util[_0x4aba16('0x2e')](_0x4aba16('0x65'),_0x5b17e0[_0x4aba16('0x15')]),_0x4aba16('0x23'),{'recordId':_0x3583f2['id']});break;case _0x4aba16('0x50'):emit(util[_0x4aba16('0x2e')](_0x4aba16('0x65'),_0x5b17e0[_0x4aba16('0x15')]),_0x4aba16('0x29'),{'uri':util[_0x4aba16('0x2e')](_0x4aba16('0x3f'),_0x46d654[_0x4aba16('0x5a')],_0x3583f2['id'])});break;default:logger['error'](_0x4aba16('0x36'));}})[_0x1ef258('0x46')](function(_0x49e4f9){const _0x444eea=_0x1ef258;logger[_0x444eea('0x12')](_0x444eea('0x26'),JSON[_0x444eea('0x56')](_0x49e4f9));});},exports[_0x21398a('0x41')]=function(_0x1ddbd1,_0x4a2942,_0x243a43,_0x197248,_0x410a9b,_0x16f2e0,_0xccf294){const _0x4842dd=_0x21398a;let _0x57ba38,_0x39ab40,_0x431251,_0x7755dd;return _0x16f2e0['serverUrl']=intUtil[_0x4842dd('0x6b')](_0x16f2e0[_0x4842dd('0x9')]),_0x16f2e0[_0x4842dd('0x43')]=intUtil[_0x4842dd('0x6b')](_0x16f2e0[_0x4842dd('0x43')]),_0xccf294&&_0xccf294['recordingFormat']&&_0xccf294['recordingFormat']!==_0x4842dd('0x51')&&(logger[_0x4842dd('0x5c')](_0x4842dd('0x13'),_0x4842dd('0x5f')),_0x4a2942[_0x4842dd('0x2')]=util[_0x4842dd('0x2e')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x16f2e0[_0x4842dd('0x9')],_0x4a2942[_0x4842dd('0x5e')],md5(_0x4a2942[_0x4842dd('0x5e')]))),getConnection(_0x16f2e0)[_0x4842dd('0x31')](function(_0x29f4d0){const _0x490247=_0x4842dd;return _0x7755dd=_0x29f4d0,getUser(_0x16f2e0,_0x197248[_0x490247('0x1')],_0x7755dd);})[_0x4842dd('0x31')](function(_0x560440){const _0x35aed5=_0x4842dd;return _0x57ba38=_0x560440,getEndUser(_0x16f2e0,_0x243a43,_0x4a2942[_0x35aed5('0x37')],_0x4a2942[_0x35aed5('0x53')],_0x7755dd);})[_0x4842dd('0x31')](function(_0x14051e){const _0x235225=_0x4842dd;return _0x39ab40=_0x14051e,getTicket(_0x16f2e0,_0x57ba38,_0x39ab40,_0x243a43,_0x4a2942,_0x243a43[_0x235225('0x1c')],_0x7755dd,'outbound');})[_0x4842dd('0x31')](function(_0x1d17c7){const _0x4940c5=_0x4842dd;_0x431251=_0x1d17c7,logger['info'](_0x4940c5('0x22'),_0x431251['id']),logger[_0x4940c5('0x5c')](_0x4940c5('0x20'),_0x431251['id'],_0x197248['name'],_0x16f2e0[_0x4940c5('0x62')]);switch(_0x16f2e0[_0x4940c5('0x62')]){case _0x4940c5('0x4d'):emit(util['format'](_0x4940c5('0x65'),_0x197248['name']),_0x4940c5('0x23'),{'recordId':_0x431251['id']});break;case _0x4940c5('0x50'):emit(util[_0x4940c5('0x2e')](_0x4940c5('0x65'),_0x197248[_0x4940c5('0x15')]),_0x4940c5('0x29'),{'uri':util[_0x4940c5('0x2e')](_0x4940c5('0x3f'),_0x7755dd[_0x4940c5('0x5a')],_0x431251['id'])});break;default:logger[_0x4940c5('0x12')]('[OUTBOUND]',_0x4940c5('0x61'));}})['catch'](function(_0x54755d){const _0x812815=_0x4842dd;logger[_0x812815('0x12')](_0x812815('0x13'),JSON[_0x812815('0x56')](_0x54755d));});},exports[_0x21398a('0x3e')]=function(_0x1573dc,_0x2e9eb4,_0x51b654,_0x56a360,_0x25c9f4,_0x1cc941){const _0x473805=_0x21398a;let _0x2fe237,_0x563710,_0x34ddc9,_0x370886;return _0x1cc941['serverUrl']=intUtil['stripTrailingSlash'](_0x1cc941[_0x473805('0x9')]),_0x1cc941[_0x473805('0x43')]=intUtil[_0x473805('0x6b')](_0x1cc941[_0x473805('0x43')]),_0x25c9f4&&_0x25c9f4[_0x473805('0x4')]?(logger['info']('['+_0x2e9eb4[_0x473805('0x24')][_0x473805('0x28')]()+']',_0x473805('0x5f')),_0x2e9eb4[_0x473805('0x2')]=util[_0x473805('0x2e')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x1cc941[_0x473805('0x9')],_0x2e9eb4['uniqueid'],md5(_0x2e9eb4[_0x473805('0x5e')]))):_0x2e9eb4['recordingURL']='',getConnection(_0x1cc941)[_0x473805('0x31')](function(_0x2e44b9){const _0xbcf1f7=_0x473805;return _0x370886=_0x2e44b9,!_[_0xbcf1f7('0xb')](_0x56a360)?getUser(_0x1cc941,_0x56a360[_0xbcf1f7('0x15')],_0x370886):getUser(_0x1cc941,null,_0x370886);})[_0x473805('0x31')](function(_0x3e819e){const _0x5a1a7a=_0x473805;return _0x2fe237=_0x3e819e,getEndUser(_0x1cc941,_0x51b654,_0x2e9eb4[_0x5a1a7a('0x55')],_0x2e9eb4['calleridnum'],_0x370886);})[_0x473805('0x31')](function(_0x517a00){return _0x563710=_0x517a00,getTicket(_0x1cc941,_0x2fe237,_0x563710,_0x51b654,_0x2e9eb4,_0x51b654['Fields'],_0x370886);})[_0x473805('0x31')](function(_0x1a8fa0){const _0x538e66=_0x473805;_0x34ddc9=_0x1a8fa0,logger[_0x538e66('0x5c')]('['+_0x2e9eb4[_0x538e66('0x24')][_0x538e66('0x28')]()+_0x538e66('0x39'),_0x34ddc9['id']),logger[_0x538e66('0x5c')]('['+_0x2e9eb4['lastevent'][_0x538e66('0x28')]()+']\x20Integration\x20account\x20type\x20%s.',_0x1cc941['type']);})[_0x473805('0x46')](function(_0x106e08){const _0x8f4f43=_0x473805;logger[_0x8f4f43('0x12')]('['+_0x2e9eb4[_0x8f4f43('0x24')][_0x8f4f43('0x28')]()+']',JSON[_0x8f4f43('0x56')](_0x106e08));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/servicenow.js b/server/services/ami/trigger/integration/servicenow.js index 5a3716b..5464dd8 100644 --- a/server/services/ami/trigger/integration/servicenow.js +++ b/server/services/ami/trigger/integration/servicenow.js @@ -1 +1 @@ -const a1142_0x1257=['email','error','The\x20ticket\x20ID\x20is:\x20%s','ticketNumber','true','active','none','catch','recordingFormat','sys_user?','length','calleridnum',']\x20getTicket\x20input\x20crm','content','./util','string','message','customVariable','endUserNumber','%26sysparm_record_target%3Dincident','util','Variable','queue','],\x20getUser\x20entity','%26sysparm_record_list%3Dactive%253Dtrue','idField','sysparm_display_value=true','Recording\x20is\x20enabled!','],\x20createEndUser\x20crm','],\x20getUser\x20rp\x20obj','recordingURL','GET','outbound','%26sysparm_record_row%3D1%26sysparm_record_rows%3D39','userId','sys_user?sysparm_query=phone%3D','forEach','password','Subjects','%s/api/now/table/','[OUTBOUND]','endUserId','monitor_format','sysparm_limit=1','],\x20createEndUser\x20input\x20crm','nameField','],\x20getUser\x20crm','variableName','[QUEUE]','stripTrailingSlash','%255EORDERBYDESCnumber','isNil','sys_id','],\x20EndUser\x20schema','],\x20getEndUser\x20input\x20crm','sys_user?sysparm_query=user_name%3Dadmin','],\x20getEndUser\x20crm','type','then','adminEmail','unmanaged','ticketId',']\x20Error\x20running\x20ServiceNow\x20integration','Fields','remoteUri','request-promise-native','toUpperCase','serverUrl','info','],\x20getUser\x20input\x20crm','emit','call\x20direction:\x20%s','System','format','getString','destcalleridnum','POST',']\x20POST\x20incident\x20entity\x20schema','toLowerCase','customField','toString','Descriptions','validateEmail','trigger:browser:url','adminId','uniqueid','],\x20getAdminUser\x20crm','userEmail',']\x20using\x20admin\x20profile','name','sys_user?sysparm_query=email%3D','incident','variable','result'];(function(_0x5a7b25,_0x1257d2){const _0x513c03=function(_0x2982d7){while(--_0x2982d7){_0x5a7b25['push'](_0x5a7b25['shift']());}};_0x513c03(++_0x1257d2);}(a1142_0x1257,0x127));const a1142_0x513c=function(_0x5a7b25,_0x1257d2){_0x5a7b25=_0x5a7b25-0x0;let _0x513c03=a1142_0x1257[_0x5a7b25];return _0x513c03;};const _0x4a996d=a1142_0x513c;'use strict';const _=require('lodash'),rp=require(_0x4a996d('0x34')),util=require(_0x4a996d('0x7')),md5=require('md5'),intUtil=require(_0x4a996d('0x1')),logger=require('../../../../config/logger')('servicenow'),{getSocket}=require('../../../../rediscache'),io=getSocket();function getAdminUser(_0x2982d7,_0x20d0b8,_0x2f676e,_0x30e680,_0x4f2662,_0x662294){return new Promise(function(_0x587317,_0xcb764b){const _0xb17f71=a1142_0x513c,_0x228cdd={'method':'GET','uri':_0x30e680+_0xb17f71('0x2a')+'&'+_0x4f2662+'&'+_0x662294,'auth':_0x20d0b8,'json':!![]};return rp(_0x228cdd)['then'](function(_0x5e194a){const _0x432819=_0xb17f71;_0x5e194a[_0x432819('0x50')][_0x432819('0x5b')]>0x0&&(_0x2f676e[_0x432819('0x47')]=_0x5e194a['result'][0x0][_0x432819('0x27')]),logger[_0x432819('0x37')]('['+[_0x2982d7['toUpperCase']()]+_0x432819('0x49'),_0x2f676e),_0x587317(_0x2f676e);})[_0xb17f71('0x58')](function(_0x6005e9){const _0x1cc0ba=_0xb17f71;logger[_0x1cc0ba('0x52')]('['+[_0x2982d7[_0x1cc0ba('0x35')]()]+']',_0x6005e9['message']),_0xcb764b(_0x6005e9[_0x1cc0ba('0x3')]);});});}function getUser(_0x14dc76,_0x154030,_0x298a69,_0x320669,_0x3c44c2){return function(_0x508c2f){const _0x9c8ec3=a1142_0x513c;return logger['info']('['+[_0x14dc76[_0x9c8ec3('0x35')]()]+_0x9c8ec3('0x38'),_0x508c2f),new Promise(function(_0x5d9b14,_0x4ae421){const _0x1d991b=_0x9c8ec3;if(intUtil[_0x1d991b('0x45')](_0x508c2f[_0x1d991b('0x4a')])){const _0x59fd91={'method':_0x1d991b('0x12'),'uri':_0x298a69+_0x1d991b('0x4d')+_0x508c2f[_0x1d991b('0x4a')]+'&'+_0x320669+'&'+_0x3c44c2,'auth':_0x154030,'json':!![]};return logger[_0x1d991b('0x37')]('['+[_0x14dc76[_0x1d991b('0x35')]()]+_0x1d991b('0x10'),_0x59fd91),rp(_0x59fd91)['then'](function(_0x2c1354){const _0x50495e=_0x1d991b;logger['info']('['+[_0x14dc76[_0x50495e('0x35')]()]+_0x50495e('0xa'),_0x2c1354),_0x2c1354['result'][_0x50495e('0x5b')]>0x0&&String(_0x2c1354[_0x50495e('0x50')][0x0][_0x50495e('0x56')])===_0x50495e('0x55')?_0x508c2f['userId']=_0x2c1354[_0x50495e('0x50')][0x0][_0x50495e('0x27')]:(_0x508c2f['userId']=_0x508c2f[_0x50495e('0x47')],_0x508c2f[_0x50495e('0x4a')]=_0x508c2f[_0x50495e('0x2e')]),logger['info']('['+[_0x14dc76['toUpperCase']()]+_0x50495e('0x21'),_0x508c2f),_0x5d9b14(_0x508c2f);})[_0x1d991b('0x58')](function(_0x16af11){const _0x29c2da=_0x1d991b;logger['error']('['+[_0x14dc76[_0x29c2da('0x35')]()]+']',_0x16af11[_0x29c2da('0x3')]),_0x4ae421(_0x16af11[_0x29c2da('0x3')]);});}else logger[_0x1d991b('0x37')]('['+[_0x14dc76[_0x1d991b('0x35')]()]+_0x1d991b('0x4b')),_0x508c2f[_0x1d991b('0x15')]=_0x508c2f[_0x1d991b('0x47')],_0x508c2f[_0x1d991b('0x4a')]=_0x508c2f[_0x1d991b('0x2e')],_0x5d9b14(_0x508c2f);});};}function createEndUser(_0x375145,_0x382e5b,_0x1d1414,_0x32f520,_0x596a23){const _0x2274b4=_0x4a996d;return logger[_0x2274b4('0x37')]('['+[_0x375145[_0x2274b4('0x35')]()]+_0x2274b4('0x1f'),_0x1d1414),new Promise(function(_0x598d42,_0x4b8254){const _0xccbce=_0x2274b4,_0x2163ad={'method':'POST','uri':_0x32f520+_0xccbce('0x5a')+_0x596a23,'body':{'user_name':_0x1d1414['endUserNumber'],'roles':'user','first_name':_0x1d1414['endUserNumber'],'active':'true','date_format':_0xccbce('0x3b'),'phone':_0x1d1414[_0xccbce('0x5')]},'auth':_0x382e5b,'json':!![]};return rp(_0x2163ad)[_0xccbce('0x2d')](function(_0x32a3c3){const _0x569200=_0xccbce;logger[_0x569200('0x37')]('['+[_0x375145[_0x569200('0x35')]()]+_0x569200('0x28'),_0x32a3c3[_0x569200('0x50')]),_0x1d1414[_0x569200('0x1c')]=_0x32a3c3[_0x569200('0x50')][_0x569200('0x27')],_0x598d42(_0x1d1414);})['catch'](function(_0xcd891f){const _0x499b48=_0xccbce;logger[_0x499b48('0x52')]('['+[_0x375145['toUpperCase']()]+']',_0xcd891f[_0x499b48('0x3')]),_0x4b8254(_0xcd891f[_0x499b48('0x3')]);});});}function getEndUser(_0x4d2724,_0x1a1ab9,_0x4f521a,_0x5530b7,_0x50fb1c){return function(_0x536d62){const _0x21bc02=a1142_0x513c;return logger[_0x21bc02('0x37')]('['+[_0x4d2724[_0x21bc02('0x35')]()]+_0x21bc02('0x29'),_0x536d62),new Promise(function(_0x53d684,_0x655200){const _0x5b4506=_0x21bc02,_0x1126ea={'method':_0x5b4506('0x12'),'uri':_0x4f521a+_0x5b4506('0x16')+_0x536d62['endUserNumber']+'&'+_0x5530b7+'&'+_0x50fb1c,'auth':_0x1a1ab9,'json':!![]};return rp(_0x1126ea)[_0x5b4506('0x2d')](function(_0x2b4935){const _0x15135a=_0x5b4506;if(_0x2b4935[_0x15135a('0x50')][_0x15135a('0x5b')]>0x0)_0x536d62[_0x15135a('0x1c')]=_0x2b4935[_0x15135a('0x50')][0x0][_0x15135a('0x27')],logger[_0x15135a('0x37')]('['+[_0x4d2724['toUpperCase']()]+_0x15135a('0x2b'),_0x536d62),_0x53d684(_0x536d62);else return createEndUser(_0x4d2724,_0x1a1ab9,_0x536d62,_0x4f521a,_0x5530b7)[_0x15135a('0x2d')](function(_0x1e4dac){const _0x49f79d=_0x15135a;logger[_0x49f79d('0x37')]('['+[_0x4d2724[_0x49f79d('0x35')]()]+_0x49f79d('0xf'),_0x1e4dac),_0x53d684(_0x1e4dac);});})['catch'](function(_0x552cb7){const _0x43b3aa=_0x5b4506;logger[_0x43b3aa('0x52')]('['+[_0x4d2724['toUpperCase']()]+']',_0x552cb7[_0x43b3aa('0x3')]),_0x655200(_0x552cb7[_0x43b3aa('0x3')]);});});};}function getCustomFields(_0x5ea010,_0x18da17){const _0x21ac6a=_0x4a996d,_0x509937={};return _0x5ea010[_0x21ac6a('0x5b')]>0x0&&_[_0x21ac6a('0x17')](_0x5ea010,function(_0x56bb9a){const _0x23041d=_0x21ac6a;if(_0x56bb9a[_0x23041d('0x2c')]===_0x23041d('0x2')&&_0x56bb9a[_0x23041d('0x20')]&&!_0x56bb9a[_0x23041d('0x42')])_0x509937[_0x56bb9a[_0x23041d('0xc')][_0x23041d('0x41')]()]=_0x56bb9a['content'][_0x23041d('0x43')]();else{if(_0x56bb9a[_0x23041d('0x2c')]===_0x23041d('0x2')&&_0x56bb9a[_0x23041d('0xc')]&&_0x56bb9a[_0x23041d('0x42')])_0x509937[_0x56bb9a[_0x23041d('0xc')][_0x23041d('0x41')]()]=_0x56bb9a[_0x23041d('0x0')][_0x23041d('0x43')]();else{if(_0x56bb9a['type']===_0x23041d('0x4f')&&_0x56bb9a[_0x23041d('0x22')]&&_0x56bb9a[_0x23041d('0xc')]&&_0x56bb9a[_0x23041d('0x42')])_0x509937[_0x56bb9a[_0x23041d('0xc')][_0x23041d('0x41')]()]=_0x18da17[_0x56bb9a[_0x23041d('0x22')]]['toString']();else _0x56bb9a[_0x23041d('0x2c')]===_0x23041d('0x4')&&_0x56bb9a[_0x23041d('0x8')]&&_0x56bb9a[_0x23041d('0x8')]['name']&&_0x56bb9a[_0x23041d('0xc')]&&_0x56bb9a['customField']&&(_0x509937[_0x56bb9a[_0x23041d('0xc')][_0x23041d('0x41')]()]=_0x18da17[_0x56bb9a[_0x23041d('0x8')][_0x23041d('0x4c')][_0x23041d('0x41')]()][_0x23041d('0x43')]());}}}),_0x509937;}function getTicket(_0x4f8d65,_0x5b8ce9,_0x164467,_0x2eae14,_0x459379,_0x1ba41c){return function(_0x4ee652){const _0x463966=a1142_0x513c;return logger[_0x463966('0x37')]('['+[_0x4f8d65[_0x463966('0x35')]()]+_0x463966('0x5d'),_0x4ee652),new Promise(function(_0x1069ac,_0x34ddfd){const _0x1fe8c1=_0x463966,_0xd2149d=_0x4f8d65['toLowerCase']()===_0x1fe8c1('0x13')?_0x4ee652[_0x1fe8c1('0x15')]:_0x4ee652[_0x1fe8c1('0x1c')],_0x28eff4={'method':_0x1fe8c1('0x3f'),'uri':_0x164467+_0x1fe8c1('0x4e')+'?'+_0x1ba41c,'body':Object['assign']({},{'active':'true','caller_id':_0xd2149d,'assigned_to':_0x4ee652[_0x1fe8c1('0x15')],'short_description':intUtil[_0x1fe8c1('0x3d')](_0x2eae14[_0x1fe8c1('0x19')],_0x459379,'\x20'),'description':intUtil[_0x1fe8c1('0x3d')](_0x2eae14[_0x1fe8c1('0x44')],_0x459379,'\x0a')},getCustomFields(_0x2eae14[_0x1fe8c1('0x32')],_0x459379)),'auth':_0x5b8ce9,'json':!![]};return rp(_0x28eff4)[_0x1fe8c1('0x2d')](function(_0x389997){const _0x501dcd=_0x1fe8c1;logger[_0x501dcd('0x37')]('['+[_0x4f8d65[_0x501dcd('0x35')]()]+_0x501dcd('0x40'),_0x389997[_0x501dcd('0x50')]),_0x4ee652[_0x501dcd('0x30')]=_0x389997[_0x501dcd('0x50')][_0x501dcd('0x27')],_0x4ee652[_0x501dcd('0x54')]=_0x389997[_0x501dcd('0x50')]['number'],logger['info']('['+[_0x4f8d65[_0x501dcd('0x35')]()]+']\x20getTicket\x20crm',_0x4ee652),_0x1069ac(_0x4ee652);})['catch'](function(_0x296c8f){const _0x3a3c66=_0x1fe8c1;logger[_0x3a3c66('0x52')]('['+[_0x4f8d65[_0x3a3c66('0x35')]()]+']',_0x296c8f[_0x3a3c66('0x3')]),_0x34ddfd(_0x296c8f['message']);});});};}function emit(_0x2552c3,_0x216211,_0x306edd){const _0x197ae4=_0x4a996d,_0x31de6e=_0x197ae4('0x6')+_0x197ae4('0x14')+_0x197ae4('0xb')+_0x197ae4('0x25'),_0x4f2713={'uri':_0x2552c3+'/nav_to.do?uri=incident.do?sys_id%3D'+_0x306edd+_0x31de6e};io['to'](util[_0x197ae4('0x3c')]('user:%s',_0x216211))[_0x197ae4('0x39')](_0x197ae4('0x46'),_0x4f2713);}exports['cs']=function(_0x38fe2e,_0x1253d2,_0x2d06a7,_0x1f49d9,_0x17965d,_0x51da5f,_0x48d0c4,_0x36d446){const _0x59df4d=_0x4a996d,_0x52ee97={},_0x26e047={'user':_0x51da5f['username'],'pass':_0x51da5f[_0x59df4d('0x18')]},_0x34408a=_0x59df4d('0x1e'),_0x5ae3e6=_0x59df4d('0xd');_0x51da5f[_0x59df4d('0x33')]=intUtil[_0x59df4d('0x24')](_0x51da5f[_0x59df4d('0x33')]),_0x51da5f[_0x59df4d('0x36')]=intUtil['stripTrailingSlash'](_0x51da5f[_0x59df4d('0x36')]);const _0x534c71=util[_0x59df4d('0x3c')](_0x59df4d('0x1a'),_0x51da5f['remoteUri']);_0x52ee97[_0x59df4d('0x4a')]=!_[_0x59df4d('0x26')](_0x1f49d9)?_0x1f49d9[_0x59df4d('0x51')]:null,_0x52ee97[_0x59df4d('0x2e')]=_0x51da5f['email'],_0x52ee97[_0x59df4d('0x5')]=_0x36d446['toLowerCase']()===_0x59df4d('0x13')?_0x1253d2[_0x59df4d('0x3e')]:_0x1253d2[_0x59df4d('0x5c')],_0x52ee97['callDirection']=_0x36d446==='queue'||_0x36d446===_0x59df4d('0x2f')?_0x59df4d('0x9'):_0x59df4d('0x13');const _0x449c2c=util['format']('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x51da5f[_0x59df4d('0x36')],_0x1253d2[_0x59df4d('0x48')],md5(_0x1253d2[_0x59df4d('0x48')]));if(_0x17965d&&_0x17965d[_0x59df4d('0x1d')])logger[_0x59df4d('0x37')](_0x59df4d('0x23'),_0x59df4d('0xe')),_0x1253d2[_0x59df4d('0x11')]=_0x449c2c;else _0x48d0c4&&_0x48d0c4[_0x59df4d('0x59')]&&_0x48d0c4[_0x59df4d('0x59')]!==_0x59df4d('0x57')?(logger['info'](_0x59df4d('0x1b'),'Recording\x20is\x20enabled!'),_0x1253d2[_0x59df4d('0x11')]=_0x449c2c):_0x1253d2['recordingURL']='';return getAdminUser(_0x36d446,_0x26e047,_0x52ee97,_0x534c71,_0x5ae3e6,_0x34408a)[_0x59df4d('0x2d')](getUser(_0x36d446,_0x26e047,_0x534c71,_0x5ae3e6,_0x34408a))['then'](getEndUser(_0x36d446,_0x26e047,_0x534c71,_0x5ae3e6,_0x34408a))['then'](getTicket(_0x36d446,_0x26e047,_0x534c71,_0x2d06a7,_0x1253d2,_0x5ae3e6))[_0x59df4d('0x2d')](function(_0x29d6a5){const _0x194523=_0x59df4d;logger[_0x194523('0x37')](util['format'](_0x194523('0x53'),_0x29d6a5['ticketId'])),logger[_0x194523('0x37')](util[_0x194523('0x3c')](_0x194523('0x3a'),_0x36d446)),_0x36d446!=='unmanaged'&&(logger[_0x194523('0x37')]('['+[_0x36d446[_0x194523('0x35')]()]+']','Displaying\x20call\x20in\x20a\x20new\x20tab...'),emit(_0x51da5f[_0x194523('0x33')],_0x1f49d9[_0x194523('0x4c')],_0x29d6a5['ticketId']));})[_0x59df4d('0x58')](function(_0x186e7c){const _0x5a079a=_0x59df4d;logger['error']('['+[_0x36d446[_0x5a079a('0x35')]()]+_0x5a079a('0x31'),util['inspect'](_0x186e7c,{'showHidden':!![],'depth':null}));});}; \ No newline at end of file +const a1142_0x4dcb=['%26sysparm_record_row%3D1%26sysparm_record_rows%3D39','The\x20ticket\x20ID\x20is:\x20%s','trigger:browser:url','recordingURL','number','customField','catch',']\x20Error\x20running\x20ServiceNow\x20integration','[QUEUE]','],\x20getUser\x20input\x20crm','Descriptions','md5','../../../../config/logger','format','stripTrailingSlash','length','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','queue','sys_id','error','variable','%s/api/now/table/','unmanaged','lodash','toString','uniqueid','outbound','endUserNumber','recordingFormat','POST','result','call\x20direction:\x20%s','variableName','toUpperCase','info','],\x20getUser\x20rp\x20obj','password','userId','endUserId','emit','sys_user?sysparm_query=email%3D','ticketId','content','Variable','idField','then','user:%s','active','email',']\x20getTicket\x20input\x20crm',']\x20POST\x20incident\x20entity\x20schema','Displaying\x20call\x20in\x20a\x20new\x20tab...','username','monitor_format','adminEmail','name','customVariable','string','sysparm_limit=1','nameField','./util','],\x20createEndUser\x20input\x20crm','type','validateEmail','request-promise-native','],\x20getUser\x20entity','true','Subjects','adminId',']\x20using\x20admin\x20profile','toLowerCase','incident','],\x20getUser\x20crm','getString','Recording\x20is\x20enabled!','ticketNumber','destcalleridnum','message','callDirection','assign','isNil','serverUrl','[OUTBOUND]','userEmail','remoteUri','GET','],\x20EndUser\x20schema','],\x20getEndUser\x20crm','inspect','System','none','../../../../rediscache'];(function(_0x598406,_0x4dcb3b){const _0x317bb9=function(_0x1b29d6){while(--_0x1b29d6){_0x598406['push'](_0x598406['shift']());}};_0x317bb9(++_0x4dcb3b);}(a1142_0x4dcb,0xa0));const a1142_0x317b=function(_0x598406,_0x4dcb3b){_0x598406=_0x598406-0x0;let _0x317bb9=a1142_0x4dcb[_0x598406];return _0x317bb9;};const _0x2ff1a7=a1142_0x317b;'use strict';const _=require(_0x2ff1a7('0x2f')),rp=require(_0x2ff1a7('0x58')),util=require('util'),md5=require(_0x2ff1a7('0x23')),intUtil=require(_0x2ff1a7('0x54')),logger=require(_0x2ff1a7('0x24'))('servicenow'),{getSocket}=require(_0x2ff1a7('0x17')),io=getSocket();function getAdminUser(_0x1b29d6,_0x4ffe6e,_0x288acf,_0x49769b,_0x5a62fa,_0xbfcb1c){return new Promise(function(_0x3ff406,_0x26dd4f){const _0x172f2e=a1142_0x317b,_0x4924cb={'method':'GET','uri':_0x49769b+'sys_user?sysparm_query=user_name%3Dadmin'+'&'+_0x5a62fa+'&'+_0xbfcb1c,'auth':_0x4ffe6e,'json':!![]};return rp(_0x4924cb)[_0x172f2e('0x45')](function(_0x45f0f5){const _0x3459ac=_0x172f2e;_0x45f0f5[_0x3459ac('0x36')][_0x3459ac('0x27')]>0x0&&(_0x288acf['adminId']=_0x45f0f5[_0x3459ac('0x36')][0x0][_0x3459ac('0x2a')]),logger[_0x3459ac('0x3a')]('['+[_0x1b29d6[_0x3459ac('0x39')]()]+'],\x20getAdminUser\x20crm',_0x288acf),_0x3ff406(_0x288acf);})[_0x172f2e('0x1e')](function(_0x52cc7f){const _0x427c8c=_0x172f2e;logger[_0x427c8c('0x2b')]('['+[_0x1b29d6[_0x427c8c('0x39')]()]+']',_0x52cc7f['message']),_0x26dd4f(_0x52cc7f[_0x427c8c('0x9')]);});});}function getUser(_0x4964a4,_0x5cc925,_0x58663e,_0x532420,_0x28a2db){return function(_0x9814e7){const _0x463327=a1142_0x317b;return logger[_0x463327('0x3a')]('['+[_0x4964a4[_0x463327('0x39')]()]+_0x463327('0x21'),_0x9814e7),new Promise(function(_0xefea6b,_0x1419cb){const _0x42f008=_0x463327;if(intUtil[_0x42f008('0x57')](_0x9814e7['userEmail'])){const _0x3294c3={'method':_0x42f008('0x11'),'uri':_0x58663e+_0x42f008('0x40')+_0x9814e7[_0x42f008('0xf')]+'&'+_0x532420+'&'+_0x28a2db,'auth':_0x5cc925,'json':!![]};return logger['info']('['+[_0x4964a4[_0x42f008('0x39')]()]+_0x42f008('0x3b'),_0x3294c3),rp(_0x3294c3)[_0x42f008('0x45')](function(_0x2a9216){const _0x5740a8=_0x42f008;logger[_0x5740a8('0x3a')]('['+[_0x4964a4[_0x5740a8('0x39')]()]+_0x5740a8('0x59'),_0x2a9216),_0x2a9216[_0x5740a8('0x36')][_0x5740a8('0x27')]>0x0&&String(_0x2a9216[_0x5740a8('0x36')][0x0][_0x5740a8('0x47')])===_0x5740a8('0x5a')?_0x9814e7[_0x5740a8('0x3d')]=_0x2a9216['result'][0x0][_0x5740a8('0x2a')]:(_0x9814e7['userId']=_0x9814e7[_0x5740a8('0x0')],_0x9814e7[_0x5740a8('0xf')]=_0x9814e7[_0x5740a8('0x4e')]),logger[_0x5740a8('0x3a')]('['+[_0x4964a4[_0x5740a8('0x39')]()]+_0x5740a8('0x4'),_0x9814e7),_0xefea6b(_0x9814e7);})[_0x42f008('0x1e')](function(_0x33e0c1){const _0x22ccd4=_0x42f008;logger[_0x22ccd4('0x2b')]('['+[_0x4964a4[_0x22ccd4('0x39')]()]+']',_0x33e0c1[_0x22ccd4('0x9')]),_0x1419cb(_0x33e0c1['message']);});}else logger['info']('['+[_0x4964a4[_0x42f008('0x39')]()]+_0x42f008('0x1')),_0x9814e7[_0x42f008('0x3d')]=_0x9814e7[_0x42f008('0x0')],_0x9814e7[_0x42f008('0xf')]=_0x9814e7['adminEmail'],_0xefea6b(_0x9814e7);});};}function createEndUser(_0x2ec169,_0xba8fd2,_0x308f6f,_0xf4fac6,_0x22f5e8){const _0x443914=_0x2ff1a7;return logger[_0x443914('0x3a')]('['+[_0x2ec169['toUpperCase']()]+_0x443914('0x55'),_0x308f6f),new Promise(function(_0x573b0d,_0x43e413){const _0x2c6c18=_0x443914,_0x46f598={'method':_0x2c6c18('0x35'),'uri':_0xf4fac6+'sys_user?'+_0x22f5e8,'body':{'user_name':_0x308f6f[_0x2c6c18('0x33')],'roles':'user','first_name':_0x308f6f[_0x2c6c18('0x33')],'active':_0x2c6c18('0x5a'),'date_format':_0x2c6c18('0x15'),'phone':_0x308f6f[_0x2c6c18('0x33')]},'auth':_0xba8fd2,'json':!![]};return rp(_0x46f598)['then'](function(_0x386d94){const _0x3e0590=_0x2c6c18;logger['info']('['+[_0x2ec169[_0x3e0590('0x39')]()]+_0x3e0590('0x12'),_0x386d94[_0x3e0590('0x36')]),_0x308f6f[_0x3e0590('0x3e')]=_0x386d94['result']['sys_id'],_0x573b0d(_0x308f6f);})[_0x2c6c18('0x1e')](function(_0x40d389){const _0x4b4fcf=_0x2c6c18;logger[_0x4b4fcf('0x2b')]('['+[_0x2ec169[_0x4b4fcf('0x39')]()]+']',_0x40d389[_0x4b4fcf('0x9')]),_0x43e413(_0x40d389[_0x4b4fcf('0x9')]);});});}function getEndUser(_0x5a8ffc,_0x3ded15,_0x2c4de7,_0x56a2b5,_0x629b){return function(_0x9e9f10){const _0x15a9a1=a1142_0x317b;return logger[_0x15a9a1('0x3a')]('['+[_0x5a8ffc[_0x15a9a1('0x39')]()]+'],\x20getEndUser\x20input\x20crm',_0x9e9f10),new Promise(function(_0x3c0c06,_0x15a575){const _0x2f228e=_0x15a9a1,_0x50342c={'method':_0x2f228e('0x11'),'uri':_0x2c4de7+'sys_user?sysparm_query=phone%3D'+_0x9e9f10['endUserNumber']+'&'+_0x56a2b5+'&'+_0x629b,'auth':_0x3ded15,'json':!![]};return rp(_0x50342c)[_0x2f228e('0x45')](function(_0x12bdee){const _0x2ab9d8=_0x2f228e;if(_0x12bdee[_0x2ab9d8('0x36')]['length']>0x0)_0x9e9f10[_0x2ab9d8('0x3e')]=_0x12bdee[_0x2ab9d8('0x36')][0x0][_0x2ab9d8('0x2a')],logger['info']('['+[_0x5a8ffc[_0x2ab9d8('0x39')]()]+_0x2ab9d8('0x13'),_0x9e9f10),_0x3c0c06(_0x9e9f10);else return createEndUser(_0x5a8ffc,_0x3ded15,_0x9e9f10,_0x2c4de7,_0x56a2b5)[_0x2ab9d8('0x45')](function(_0x21adba){const _0x9ebfe2=_0x2ab9d8;logger[_0x9ebfe2('0x3a')]('['+[_0x5a8ffc[_0x9ebfe2('0x39')]()]+'],\x20createEndUser\x20crm',_0x21adba),_0x3c0c06(_0x21adba);});})[_0x2f228e('0x1e')](function(_0x38fe12){const _0x333ee6=_0x2f228e;logger[_0x333ee6('0x2b')]('['+[_0x5a8ffc['toUpperCase']()]+']',_0x38fe12[_0x333ee6('0x9')]),_0x15a575(_0x38fe12[_0x333ee6('0x9')]);});});};}function getCustomFields(_0xa04cec,_0x589b51){const _0x4d2081=_0x2ff1a7,_0x55d5fd={};return _0xa04cec[_0x4d2081('0x27')]>0x0&&_['forEach'](_0xa04cec,function(_0x269fe8){const _0x155320=_0x4d2081;if(_0x269fe8[_0x155320('0x56')]==='string'&&_0x269fe8[_0x155320('0x53')]&&!_0x269fe8['customField'])_0x55d5fd[_0x269fe8[_0x155320('0x44')][_0x155320('0x2')]()]=_0x269fe8[_0x155320('0x42')][_0x155320('0x30')]();else{if(_0x269fe8[_0x155320('0x56')]===_0x155320('0x51')&&_0x269fe8[_0x155320('0x44')]&&_0x269fe8[_0x155320('0x1d')])_0x55d5fd[_0x269fe8['idField'][_0x155320('0x2')]()]=_0x269fe8['content'][_0x155320('0x30')]();else{if(_0x269fe8[_0x155320('0x56')]===_0x155320('0x2c')&&_0x269fe8[_0x155320('0x38')]&&_0x269fe8['idField']&&_0x269fe8[_0x155320('0x1d')])_0x55d5fd[_0x269fe8[_0x155320('0x44')][_0x155320('0x2')]()]=_0x589b51[_0x269fe8['variableName']]['toString']();else _0x269fe8[_0x155320('0x56')]===_0x155320('0x50')&&_0x269fe8[_0x155320('0x43')]&&_0x269fe8['Variable'][_0x155320('0x4f')]&&_0x269fe8[_0x155320('0x44')]&&_0x269fe8['customField']&&(_0x55d5fd[_0x269fe8[_0x155320('0x44')][_0x155320('0x2')]()]=_0x589b51[_0x269fe8[_0x155320('0x43')][_0x155320('0x4f')][_0x155320('0x2')]()][_0x155320('0x30')]());}}}),_0x55d5fd;}function getTicket(_0x2b2782,_0x3ebd29,_0x3015b2,_0xe8d70,_0x55304b,_0x26c820){return function(_0x24027f){const _0x3271db=a1142_0x317b;return logger[_0x3271db('0x3a')]('['+[_0x2b2782[_0x3271db('0x39')]()]+_0x3271db('0x49'),_0x24027f),new Promise(function(_0x56f6dd,_0x51dec2){const _0xd86102=_0x3271db,_0x25cc65=_0x2b2782[_0xd86102('0x2')]()===_0xd86102('0x32')?_0x24027f[_0xd86102('0x3d')]:_0x24027f[_0xd86102('0x3e')],_0x3382d1={'method':'POST','uri':_0x3015b2+_0xd86102('0x3')+'?'+_0x26c820,'body':Object[_0xd86102('0xb')]({},{'active':'true','caller_id':_0x25cc65,'assigned_to':_0x24027f[_0xd86102('0x3d')],'short_description':intUtil[_0xd86102('0x5')](_0xe8d70[_0xd86102('0x5b')],_0x55304b,'\x20'),'description':intUtil['getString'](_0xe8d70[_0xd86102('0x22')],_0x55304b,'\x0a')},getCustomFields(_0xe8d70['Fields'],_0x55304b)),'auth':_0x3ebd29,'json':!![]};return rp(_0x3382d1)['then'](function(_0x10ab82){const _0x4cb717=_0xd86102;logger['info']('['+[_0x2b2782['toUpperCase']()]+_0x4cb717('0x4a'),_0x10ab82[_0x4cb717('0x36')]),_0x24027f[_0x4cb717('0x41')]=_0x10ab82['result'][_0x4cb717('0x2a')],_0x24027f[_0x4cb717('0x7')]=_0x10ab82[_0x4cb717('0x36')][_0x4cb717('0x1c')],logger[_0x4cb717('0x3a')]('['+[_0x2b2782[_0x4cb717('0x39')]()]+']\x20getTicket\x20crm',_0x24027f),_0x56f6dd(_0x24027f);})[_0xd86102('0x1e')](function(_0x25404b){const _0x2933e7=_0xd86102;logger[_0x2933e7('0x2b')]('['+[_0x2b2782[_0x2933e7('0x39')]()]+']',_0x25404b[_0x2933e7('0x9')]),_0x51dec2(_0x25404b[_0x2933e7('0x9')]);});});};}function emit(_0x50dc6a,_0x4d47a9,_0x1672ac){const _0x3612f0=_0x2ff1a7,_0x220cad='%26sysparm_record_target%3Dincident'+_0x3612f0('0x18')+'%26sysparm_record_list%3Dactive%253Dtrue'+'%255EORDERBYDESCnumber',_0x4ff5d2={'uri':_0x50dc6a+'/nav_to.do?uri=incident.do?sys_id%3D'+_0x1672ac+_0x220cad};io['to'](util[_0x3612f0('0x25')](_0x3612f0('0x46'),_0x4d47a9))[_0x3612f0('0x3f')](_0x3612f0('0x1a'),_0x4ff5d2);}exports['cs']=function(_0x4e0c2b,_0x4649c5,_0x2e2211,_0x26c2fb,_0x5c84ab,_0x1622a7,_0x2f6118,_0x5d3c11){const _0x5632cf=_0x2ff1a7,_0x15b19e={},_0x412af1={'user':_0x1622a7[_0x5632cf('0x4c')],'pass':_0x1622a7[_0x5632cf('0x3c')]},_0x231779=_0x5632cf('0x52'),_0x23be8d='sysparm_display_value=true';_0x1622a7[_0x5632cf('0x10')]=intUtil[_0x5632cf('0x26')](_0x1622a7[_0x5632cf('0x10')]),_0x1622a7[_0x5632cf('0xd')]=intUtil[_0x5632cf('0x26')](_0x1622a7[_0x5632cf('0xd')]);const _0x235d66=util[_0x5632cf('0x25')](_0x5632cf('0x2d'),_0x1622a7[_0x5632cf('0x10')]);_0x15b19e[_0x5632cf('0xf')]=!_[_0x5632cf('0xc')](_0x26c2fb)?_0x26c2fb[_0x5632cf('0x48')]:null,_0x15b19e[_0x5632cf('0x4e')]=_0x1622a7[_0x5632cf('0x48')],_0x15b19e[_0x5632cf('0x33')]=_0x5d3c11['toLowerCase']()==='outbound'?_0x4649c5[_0x5632cf('0x8')]:_0x4649c5['calleridnum'],_0x15b19e[_0x5632cf('0xa')]=_0x5d3c11===_0x5632cf('0x29')||_0x5d3c11===_0x5632cf('0x2e')?_0x5632cf('0x29'):_0x5632cf('0x32');const _0x4959f1=util[_0x5632cf('0x25')](_0x5632cf('0x28'),_0x1622a7['serverUrl'],_0x4649c5[_0x5632cf('0x31')],md5(_0x4649c5['uniqueid']));if(_0x5c84ab&&_0x5c84ab[_0x5632cf('0x4d')])logger[_0x5632cf('0x3a')](_0x5632cf('0x20'),_0x5632cf('0x6')),_0x4649c5[_0x5632cf('0x1b')]=_0x4959f1;else _0x2f6118&&_0x2f6118[_0x5632cf('0x34')]&&_0x2f6118[_0x5632cf('0x34')]!==_0x5632cf('0x16')?(logger['info'](_0x5632cf('0xe'),'Recording\x20is\x20enabled!'),_0x4649c5[_0x5632cf('0x1b')]=_0x4959f1):_0x4649c5[_0x5632cf('0x1b')]='';return getAdminUser(_0x5d3c11,_0x412af1,_0x15b19e,_0x235d66,_0x23be8d,_0x231779)[_0x5632cf('0x45')](getUser(_0x5d3c11,_0x412af1,_0x235d66,_0x23be8d,_0x231779))[_0x5632cf('0x45')](getEndUser(_0x5d3c11,_0x412af1,_0x235d66,_0x23be8d,_0x231779))[_0x5632cf('0x45')](getTicket(_0x5d3c11,_0x412af1,_0x235d66,_0x2e2211,_0x4649c5,_0x23be8d))[_0x5632cf('0x45')](function(_0x4e3545){const _0x3342a0=_0x5632cf;logger[_0x3342a0('0x3a')](util[_0x3342a0('0x25')](_0x3342a0('0x19'),_0x4e3545['ticketId'])),logger[_0x3342a0('0x3a')](util[_0x3342a0('0x25')](_0x3342a0('0x37'),_0x5d3c11)),_0x5d3c11!==_0x3342a0('0x2e')&&(logger[_0x3342a0('0x3a')]('['+[_0x5d3c11[_0x3342a0('0x39')]()]+']',_0x3342a0('0x4b')),emit(_0x1622a7[_0x3342a0('0x10')],_0x26c2fb[_0x3342a0('0x4f')],_0x4e3545['ticketId']));})[_0x5632cf('0x1e')](function(_0x510604){const _0x203913=_0x5632cf;logger[_0x203913('0x2b')]('['+[_0x5d3c11['toUpperCase']()]+_0x203913('0x1f'),util[_0x203913('0x14')](_0x510604,{'showHidden':!![],'depth':null}));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/sugarcrm.js b/server/services/ami/trigger/integration/sugarcrm.js index 2d565a3..06120b8 100644 --- a/server/services/ami/trigger/integration/sugarcrm.js +++ b/server/services/ami/trigger/integration/sugarcrm.js @@ -1 +1 @@ -const a1143_0x1704=['serverUrl','push','none','created_by','recordingFormat','first_name','Outbound','destcalleridname','password','value','../../../../rediscache','trigger:browser:url','','catch','find','set_entry','Creating\x20new\x20ticket...','sessionID','user_id','Enduser\x20found!','get_server_info','lastevent','info','../../../../config/logger','%s/index.php?action=ajaxui#ajaxUILoc=index.php%3Fmodule%3DCalls%26action%3DEditView%26record%3D%s','getString','INSTR\x20(\x20users.user_name,\x20\x22%s\x22)\x20>\x200','uniqueid','Caller\x20-\x20%s','[OUTBOUND]','[QUEUE]','parent_id','emit','monitor_format','charAt','stringify','slice','POST','Subjects','length','%s/#bwc/index.php?module=Calls&action=EditView&record=%s','forEach','user_name','remoteUri','The\x20Ticket\x20ID\x20is:','description','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','version','Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!','direction','uri','Employees','entry_list','Inbound','Account\x20%d\x20is\x20not\x20valid','user:%s','calleridname','Contacts','%s/service/v4_1/rest.php','recordingURL','variableName','sugarcrm','set_relationship','name_value_list','date_start','JSON','debug','Ticket\x20created!','resolve','users','login','util','contacts.phone_home\x20=\x20\x22%s\x22','calleridnum','Agent\x20found!','name','contacts','Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...','idField','parent_type','Recording\x20is\x20enabled!','Getting\x20agent\x20with\x20name','phone_home','Enduser\x20not\x20found,\x20creating\x20a\x20new\x20enduser!','format','then','unmanaged','queue','destcalleridnum','toUpperCase','The\x20User\x20ID\x20is:','Fields','The\x20Enduser\x20ID\x20is:','Searching\x20enduser\x20with\x20phone','Calls','stripTrailingSlash','outbound','get_entry_list'];(function(_0x157045,_0x170427){const _0x305f07=function(_0x4b7752){while(--_0x4b7752){_0x157045['push'](_0x157045['shift']());}};_0x305f07(++_0x170427);}(a1143_0x1704,0x18d));const a1143_0x305f=function(_0x157045,_0x170427){_0x157045=_0x157045-0x0;let _0x305f07=a1143_0x1704[_0x157045];return _0x305f07;};const _0x46cf24=a1143_0x305f;'use strict';const _=require('lodash'),rp=require('request-promise-native'),md5=require('md5'),util=require(_0x46cf24('0x42')),intUtil=require('./util'),logger=require(_0x46cf24('0x12'))(_0x46cf24('0x38')),{getSocket}=require(_0x46cf24('0x5')),io=getSocket(),def={'method':_0x46cf24('0x20'),'json':!![]};function emit(_0x4b7752,_0x91cf59,_0x28b31f){const _0x5dba49=_0x46cf24;io['to'](_0x4b7752)[_0x5dba49('0x1b')](_0x91cf59,_0x28b31f);}function getTicket(_0x1ff3ca,_0x12ea3b,_0xec00c8,_0x4b4664,_0x1c0e0e,_0x4787b2,_0x27d83b,_0x410d55){const _0x124309=_0x46cf24;logger[_0x124309('0x11')](_0x124309('0xb'));const _0xf28f66=new Date(),_0x511aae=[{'name':'name','value':intUtil['getString'](_0x4b4664[_0x124309('0x21')],_0x1c0e0e,'\x20')},{'name':'assigned_user_id','value':_0x12ea3b['id']},{'name':_0x124309('0x60'),'value':_0x12ea3b['id']},{'name':_0x124309('0x28'),'value':intUtil[_0x124309('0x14')](_0x4b4664['Descriptions'],_0x1c0e0e,'\x0a')},{'name':_0x124309('0x3b'),'value':_0xf28f66['toISOString']()[_0x124309('0x1f')](0x0,0x13)['replace']('T','\x20')},{'name':'duration_hours','value':'0'},{'name':'duration_minutes','value':'15'},{'name':_0x124309('0x1a'),'value':_0xec00c8['id']},{'name':_0x124309('0x4a'),'value':_0x124309('0x34')},{'name':'parent_name','value':_0xec00c8[_0x124309('0x46')]},{'name':_0x124309('0x2c'),'value':_0x410d55}];return _0x4787b2['length']&&_[_0x124309('0x24')](_0x4787b2,function(_0x4a4b8d){const _0x5151f1=_0x124309;_0x1c0e0e[_0x4a4b8d['variableName']]&&_0x511aae[_0x5151f1('0x5e')]({'name':_0x4a4b8d[_0x5151f1('0x49')],'value':_0x1c0e0e[_0x4a4b8d[_0x5151f1('0x37')]]});}),request({'form':{'method':_0x124309('0xa'),'input_type':_0x124309('0x3c'),'response_type':_0x124309('0x3c'),'rest_data':JSON[_0x124309('0x1e')]({'session':_0x27d83b['id'],'module_name':_0x124309('0x59'),'name_value_list':_0x511aae})}});}function getServerInfo(_0x4fa18c){const _0x505eba=_0x46cf24;return request({'form':{'method':_0x505eba('0xf'),'input_type':'JSON','response_type':_0x505eba('0x3c'),'rest_data':JSON['stringify']({'session':_0x4fa18c['id']})}});}function getUser(_0x257070,_0x1a9f26,_0x14aabd){const _0x5c4ea2=_0x46cf24;return!_['isNil'](_0x1a9f26)?(logger[_0x5c4ea2('0x11')](_0x5c4ea2('0x4c'),_0x1a9f26),request({'form':{'method':_0x5c4ea2('0x5c'),'input_type':_0x5c4ea2('0x3c'),'response_type':'JSON','rest_data':JSON['stringify']({'session':_0x14aabd['id'],'module_name':_0x5c4ea2('0x2e'),'query':util['format'](_0x5c4ea2('0x15'),_0x1a9f26),'order_by':'','offset':'0','select_fields':['id',_0x5c4ea2('0x46'),_0x5c4ea2('0x25')],'link_name_to_fields_array':[],'max_results':-0x1,'deleted':'0'})}})['then'](function(_0x491b52){const _0x1eaa23=_0x5c4ea2;if(_0x491b52[_0x1eaa23('0x2f')][_0x1eaa23('0x22')]){const _0x28a52c=_['find'](_0x491b52[_0x1eaa23('0x2f')],function(_0x380e5b){const _0x4203c5=_0x1eaa23;return _0x380e5b[_0x4203c5('0x3a')][_0x4203c5('0x25')]['value']===_0x1a9f26;});if(_0x28a52c)return logger[_0x1eaa23('0x11')](_0x1eaa23('0x45')),Promise[_0x1eaa23('0x3f')]({'id':_0x28a52c[_0x1eaa23('0x3a')]['id'][_0x1eaa23('0x4')],'name':_0x28a52c[_0x1eaa23('0x3a')]['name'][_0x1eaa23('0x4')]});}return logger[_0x1eaa23('0x11')](_0x1eaa23('0x2b')),Promise['resolve']({'id':_0x14aabd[_0x1eaa23('0x3a')][_0x1eaa23('0xd')][_0x1eaa23('0x4')],'name':_0x14aabd[_0x1eaa23('0x3a')][_0x1eaa23('0x25')][_0x1eaa23('0x4')]});})):(logger[_0x5c4ea2('0x11')]('Agent\x20not\x20available,\x20using\x20the\x20admin\x20account!'),Promise[_0x5c4ea2('0x3f')]({'id':_0x14aabd[_0x5c4ea2('0x3a')][_0x5c4ea2('0xd')][_0x5c4ea2('0x4')],'name':_0x14aabd[_0x5c4ea2('0x3a')]['user_name'][_0x5c4ea2('0x4')]}));}function getEndUser(_0x2cc7e2,_0x510eda,_0x195ac1,_0x4340cc){const _0x4db155=_0x46cf24;return logger['info'](_0x4db155('0x58'),_0x195ac1),request({'form':{'method':'get_entry_list','input_type':'JSON','response_type':_0x4db155('0x3c'),'rest_data':JSON[_0x4db155('0x1e')]({'session':_0x4340cc['id'],'module_name':'Contacts','query':util[_0x4db155('0x4f')](_0x4db155('0x43'),_0x195ac1),'order_by':'','offset':'0','select_fields':['id','name',_0x4db155('0x4d')],'link_name_to_fields_array':[],'max_results':-0x1,'deleted':'0'})}})[_0x4db155('0x50')](function(_0xfc1ad1){const _0x4dcb92=_0x4db155;if(_0xfc1ad1['entry_list'][_0x4dcb92('0x22')]){const _0x5116ff=_[_0x4dcb92('0x9')](_0xfc1ad1[_0x4dcb92('0x2f')],function(_0x562a42){const _0x2f5832=_0x4dcb92;return _0x562a42[_0x2f5832('0x3a')][_0x2f5832('0x4d')][_0x2f5832('0x4')]===_0x195ac1;});if(_0x5116ff)return logger[_0x4dcb92('0x11')](_0x4dcb92('0xe')),Promise['resolve']({'id':_0x5116ff['name_value_list']['id'][_0x4dcb92('0x4')],'name':_0x5116ff['name_value_list'][_0x4dcb92('0x46')][_0x4dcb92('0x4')],'phone':_0x5116ff[_0x4dcb92('0x3a')][_0x4dcb92('0x4d')][_0x4dcb92('0x4')]});}else return logger[_0x4dcb92('0x11')](_0x4dcb92('0x4e')),request({'form':{'method':_0x4dcb92('0xa'),'input_type':_0x4dcb92('0x3c'),'response_type':'JSON','rest_data':JSON[_0x4dcb92('0x1e')]({'session':_0x4340cc['id'],'module_name':_0x4dcb92('0x34'),'name_value_list':[{'name':_0x4dcb92('0x0'),'value':_0x510eda!==_0x4dcb92('0x7')?_0x510eda:util[_0x4dcb92('0x4f')](_0x4dcb92('0x17'),_0x195ac1)},{'name':_0x4dcb92('0x4d'),'value':_0x195ac1}]})}})[_0x4dcb92('0x50')](function(_0x2fbb35){const _0x134ed2=_0x4dcb92;return logger['info']('Enduser\x20created.'),Promise['resolve']({'id':_0x2fbb35['id'],'name':_0x2fbb35[_0x134ed2('0x2f')][_0x134ed2('0x0')][_0x134ed2('0x4')],'phone':_0x2fbb35[_0x134ed2('0x2f')][_0x134ed2('0x4d')]['value']});});});}function request(_0x291251){const _0x3fe25e=_0x46cf24;return logger[_0x3fe25e('0x3d')]('[HTTP]',JSON[_0x3fe25e('0x1e')](_0x291251)),rp(_['merge'](def,_0x291251));}function getConnection(_0x35a26f){const _0x1fc345=_0x46cf24;return request({'method':'POST','form':{'method':_0x1fc345('0x41'),'input_type':_0x1fc345('0x3c'),'response_type':_0x1fc345('0x3c'),'rest_data':JSON[_0x1fc345('0x1e')]({'user_auth':{'user_name':_0x35a26f['username'],'password':_0x35a26f[_0x1fc345('0x3')],'encryption':'PLAIN'},'application':'xCALLY\x20Motion\x20integration'})}})[_0x1fc345('0x50')](function(_0xd00318){const _0x15e2f9=_0x1fc345,_0x2e3410=_0xd00318;if(_0x2e3410['id'])return def[_0x15e2f9('0xc')]=_0x2e3410['id'],Promise['resolve'](_0x2e3410);else throw new Error(util[_0x15e2f9('0x4f')](_0x15e2f9('0x31'),_0x35a26f['id']));});}function setRelationship(_0x9b64d6,_0xfcac9f,_0x78cffc,_0x336adb){const _0x1f765e=_0x46cf24;return request({'form':{'method':_0x1f765e('0x39'),'input_type':_0x1f765e('0x3c'),'response_type':'JSON','rest_data':JSON[_0x1f765e('0x1e')]({'session':_0x9b64d6['id'],'module_name':_0x1f765e('0x59'),'module_id':_0x78cffc['id'],'link_field_name':_0x336adb,'related_ids':[_0xfcac9f['id']]})}});}exports[_0x46cf24('0x52')]=function(_0x4454d1,_0x371968,_0x4dc3e4,_0x555b5d,_0x205adc,_0x44c3fe){const _0x3e0471=_0x46cf24;let _0x2a4a7d,_0x11b4a1,_0x567324,_0x5249d8;return _0x44c3fe[_0x3e0471('0x26')]=intUtil[_0x3e0471('0x5a')](_0x44c3fe['remoteUri']),_0x44c3fe[_0x3e0471('0x5d')]=intUtil[_0x3e0471('0x5a')](_0x44c3fe[_0x3e0471('0x5d')]),def[_0x3e0471('0x2d')]=util[_0x3e0471('0x4f')](_0x3e0471('0x35'),_0x44c3fe['remoteUri']),_0x205adc&&_0x205adc['monitor_format']?(logger[_0x3e0471('0x11')](_0x3e0471('0x19'),_0x3e0471('0x4b')),_0x371968['recordingURL']=util[_0x3e0471('0x4f')](_0x3e0471('0x29'),_0x44c3fe[_0x3e0471('0x5d')],_0x371968[_0x3e0471('0x16')],md5(_0x371968[_0x3e0471('0x16')]))):_0x371968[_0x3e0471('0x36')]='',getConnection(_0x44c3fe)[_0x3e0471('0x50')](function(_0x37bdff){const _0x2e985b=_0x3e0471;return _0x5249d8=_0x37bdff,getUser(_0x44c3fe,_0x555b5d[_0x2e985b('0x46')],_0x5249d8);})[_0x3e0471('0x50')](function(_0x37d666){const _0x28b88c=_0x3e0471;return _0x2a4a7d=_0x37d666,logger['info']('The\x20User\x20ID\x20is:',_0x2a4a7d['id']),getEndUser(_0x44c3fe,_0x371968[_0x28b88c('0x33')],_0x371968['calleridnum'],_0x5249d8);})[_0x3e0471('0x50')](function(_0x15dacd){const _0x41d5c1=_0x3e0471;return _0x11b4a1=_0x15dacd,logger[_0x41d5c1('0x11')]('The\x20Enduser\x20ID\x20is:',_0x11b4a1['id']),getTicket(_0x44c3fe,_0x2a4a7d,_0x11b4a1,_0x4dc3e4,_0x371968,_0x4dc3e4[_0x41d5c1('0x56')],_0x5249d8,_0x41d5c1('0x30'));})[_0x3e0471('0x50')](function(_0x5a786e){const _0x252a36=_0x3e0471;return _0x567324=_0x5a786e,logger[_0x252a36('0x11')]('Ticket\x20created!'),logger[_0x252a36('0x11')](_0x252a36('0x27'),_0x567324['id']),setRelationship(_0x5249d8,_0x2a4a7d,_0x567324,_0x252a36('0x40'));})[_0x3e0471('0x50')](function(){const _0x351f4f=_0x3e0471;return setRelationship(_0x5249d8,_0x11b4a1,_0x567324,_0x351f4f('0x47'));})[_0x3e0471('0x50')](function(){return getServerInfo(_0x5249d8);})[_0x3e0471('0x50')](function(_0x1c177a){const _0x4749f3=_0x3e0471,_0x1d3f28=parseInt(_0x1c177a[_0x4749f3('0x2a')][_0x4749f3('0x1d')](0x0));let _0x41f50f=util[_0x4749f3('0x4f')](_0x4749f3('0x13'),_0x44c3fe[_0x4749f3('0x26')],_0x567324['id']);_0x1d3f28>0x6&&(_0x41f50f=util[_0x4749f3('0x4f')](_0x4749f3('0x23'),_0x44c3fe['remoteUri'],_0x567324['id'])),logger[_0x4749f3('0x11')]('[QUEUE]',_0x4749f3('0x48')),emit(util[_0x4749f3('0x4f')](_0x4749f3('0x32'),_0x555b5d['name']),_0x4749f3('0x6'),{'uri':_0x41f50f});})[_0x3e0471('0x8')](function(_0x49bad8){const _0x435318=_0x3e0471;logger['error'](_0x435318('0x19'),JSON['stringify'](_0x49bad8));});},exports[_0x46cf24('0x5b')]=function(_0x2b37e8,_0x595a5d,_0x585ee2,_0x535c01,_0x4194d1,_0xc7e5f8,_0x2f5517){const _0x559e02=_0x46cf24;let _0x42576f,_0x11bc92,_0xfcf3e1,_0x2b248f;return _0xc7e5f8[_0x559e02('0x26')]=intUtil[_0x559e02('0x5a')](_0xc7e5f8['remoteUri']),_0xc7e5f8[_0x559e02('0x5d')]=intUtil['stripTrailingSlash'](_0xc7e5f8['serverUrl']),def['uri']=util['format'](_0x559e02('0x35'),_0xc7e5f8[_0x559e02('0x26')]),_0x2f5517&&_0x2f5517[_0x559e02('0x61')]&&_0x2f5517[_0x559e02('0x61')]!==_0x559e02('0x5f')&&(logger[_0x559e02('0x11')](_0x559e02('0x18'),_0x559e02('0x4b')),_0x595a5d[_0x559e02('0x36')]=util[_0x559e02('0x4f')](_0x559e02('0x29'),_0xc7e5f8[_0x559e02('0x5d')],_0x595a5d[_0x559e02('0x16')],md5(_0x595a5d[_0x559e02('0x16')]))),getConnection(_0xc7e5f8)[_0x559e02('0x50')](function(_0x1c4646){const _0x10a228=_0x559e02;return _0x2b248f=_0x1c4646,getUser(_0xc7e5f8,_0x535c01[_0x10a228('0x46')],_0x2b248f);})['then'](function(_0x64b880){const _0x2b2ef0=_0x559e02;return _0x42576f=_0x64b880,logger[_0x2b2ef0('0x11')](_0x2b2ef0('0x55'),_0x42576f['id']),getEndUser(_0xc7e5f8,_0x595a5d[_0x2b2ef0('0x2')],_0x595a5d[_0x2b2ef0('0x53')],_0x2b248f);})[_0x559e02('0x50')](function(_0x30c36a){const _0x57c849=_0x559e02;return _0x11bc92=_0x30c36a,logger[_0x57c849('0x11')](_0x57c849('0x57'),_0x11bc92['id']),getTicket(_0xc7e5f8,_0x42576f,_0x11bc92,_0x585ee2,_0x595a5d,_0x585ee2[_0x57c849('0x56')],_0x2b248f,_0x57c849('0x1'));})[_0x559e02('0x50')](function(_0x5a5f06){const _0x39736e=_0x559e02;return _0xfcf3e1=_0x5a5f06,logger[_0x39736e('0x11')](_0x39736e('0x3e')),logger[_0x39736e('0x11')]('The\x20Ticket\x20ID\x20is:',_0xfcf3e1['id']),setRelationship(_0x2b248f,_0x42576f,_0xfcf3e1,'users');})['then'](function(){const _0x16372e=_0x559e02;return setRelationship(_0x2b248f,_0x11bc92,_0xfcf3e1,_0x16372e('0x47'));})['then'](function(){return getServerInfo(_0x2b248f);})[_0x559e02('0x50')](function(_0x1201d4){const _0x214d48=_0x559e02,_0x322b06=parseInt(_0x1201d4[_0x214d48('0x2a')][_0x214d48('0x1d')](0x0));let _0x179de3=util[_0x214d48('0x4f')]('%s/index.php?action=ajaxui#ajaxUILoc=index.php%3Fmodule%3DCalls%26action%3DEditView%26record%3D%s',_0xc7e5f8['remoteUri'],_0xfcf3e1['id']);_0x322b06>0x6&&(_0x179de3=util['format'](_0x214d48('0x23'),_0xc7e5f8[_0x214d48('0x26')],_0xfcf3e1['id'])),logger[_0x214d48('0x11')]('[OUTBOUND]',_0x214d48('0x48')),emit(util[_0x214d48('0x4f')](_0x214d48('0x32'),_0x535c01[_0x214d48('0x46')]),'trigger:browser:url',{'uri':_0x179de3});})['catch'](function(_0x4687c1){const _0x2e9962=_0x559e02;logger['error']('[OUTBOUND]',JSON[_0x2e9962('0x1e')](_0x4687c1));});},exports[_0x46cf24('0x51')]=function(_0x435c3c,_0x8ba9be,_0xc04a96,_0x32ee22,_0x5428bd,_0x25d6d9){const _0x515c11=_0x46cf24;let _0x50a591,_0x368fbb,_0x10914e,_0x53190f;return _0x25d6d9[_0x515c11('0x26')]=intUtil[_0x515c11('0x5a')](_0x25d6d9['remoteUri']),_0x25d6d9['serverUrl']=intUtil[_0x515c11('0x5a')](_0x25d6d9[_0x515c11('0x5d')]),def[_0x515c11('0x2d')]=util[_0x515c11('0x4f')]('%s/service/v4_1/rest.php',_0x25d6d9[_0x515c11('0x26')]),_0x5428bd&&_0x5428bd[_0x515c11('0x1c')]?(logger[_0x515c11('0x11')]('['+_0x8ba9be['lastevent']['toUpperCase']()+']',_0x515c11('0x4b')),_0x8ba9be['recordingURL']=util['format']('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x25d6d9[_0x515c11('0x5d')],_0x8ba9be['uniqueid'],md5(_0x8ba9be['uniqueid']))):_0x8ba9be[_0x515c11('0x36')]='',getConnection(_0x25d6d9)['then'](function(_0x3b67a9){const _0x1c3ebe=_0x515c11;return _0x53190f=_0x3b67a9,!_['isNil'](_0x32ee22)?getUser(_0x25d6d9,_0x32ee22[_0x1c3ebe('0x46')],_0x53190f):getUser(_0x25d6d9,null,_0x53190f);})[_0x515c11('0x50')](function(_0x4ac6ed){const _0x44ca1f=_0x515c11;return _0x50a591=_0x4ac6ed,logger[_0x44ca1f('0x11')]('The\x20User\x20ID\x20is:',_0x50a591['id']),getEndUser(_0x25d6d9,_0x8ba9be['calleridname'],_0x8ba9be[_0x44ca1f('0x44')],_0x53190f);})['then'](function(_0x1a9d0a){const _0x5b3162=_0x515c11;return _0x368fbb=_0x1a9d0a,logger['info'](_0x5b3162('0x57'),_0x368fbb['id']),getTicket(_0x25d6d9,_0x50a591,_0x368fbb,_0xc04a96,_0x8ba9be,_0xc04a96[_0x5b3162('0x56')],_0x53190f,_0x5b3162('0x30'));})[_0x515c11('0x50')](function(_0x1e7b76){const _0x34d341=_0x515c11;return _0x10914e=_0x1e7b76,logger[_0x34d341('0x11')](_0x34d341('0x3e')),logger[_0x34d341('0x11')](_0x34d341('0x27'),_0x10914e['id']),setRelationship(_0x53190f,_0x50a591,_0x10914e,_0x34d341('0x40'));})['then'](function(){const _0x4681ff=_0x515c11;return setRelationship(_0x53190f,_0x368fbb,_0x10914e,_0x4681ff('0x47'));})[_0x515c11('0x50')](function(){return getServerInfo(_0x53190f);})[_0x515c11('0x8')](function(_0x1d8443){const _0x24f729=_0x515c11;logger['error']('['+_0x8ba9be[_0x24f729('0x10')][_0x24f729('0x54')]()+']',JSON[_0x24f729('0x1e')](_0x1d8443));});}; \ No newline at end of file +const a1143_0x35cd=['variableName','util','username','../../../../config/logger','first_name','trigger:browser:url','JSON','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','../../../../rediscache','[HTTP]','outbound','phone_home','users','[QUEUE]','%s/#bwc/index.php?module=Calls&action=EditView&record=%s','debug','unmanaged','catch','resolve','The\x20Enduser\x20ID\x20is:','calleridnum','','Enduser\x20not\x20found,\x20creating\x20a\x20new\x20enduser!','Searching\x20enduser\x20with\x20phone','push','Contacts','Fields','name','lodash','Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!','Recording\x20is\x20enabled!','slice','queue','emit','%s/service/v4_1/rest.php','info','toUpperCase','lastevent','Employees','./util','calleridname','serverUrl','version','Outbound','POST','remoteUri','uniqueid','recordingFormat','sessionID','stripTrailingSlash','name_value_list','PLAIN','replace','sugarcrm','parent_type','uri','Calls','duration_minutes','user:%s','Enduser\x20created.','created_by','toISOString','xCALLY\x20Motion\x20integration','Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...','Enduser\x20found!','parent_id','date_start','none','direction','parent_name','contacts','entry_list','format','Subjects','monitor_format','Ticket\x20created!','set_relationship','recordingURL','contacts.phone_home\x20=\x20\x22%s\x22','find','Getting\x20agent\x20with\x20name','get_server_info','get_entry_list','Creating\x20new\x20ticket...','idField','user_name','stringify','duration_hours','charAt','then','Caller\x20-\x20%s','[OUTBOUND]','forEach','INSTR\x20(\x20users.user_name,\x20\x22%s\x22)\x20>\x200','length','md5','%s/index.php?action=ajaxui#ajaxUILoc=index.php%3Fmodule%3DCalls%26action%3DEditView%26record%3D%s','The\x20User\x20ID\x20is:','Agent\x20found!','value','isNil','Inbound','description'];(function(_0x52777d,_0x35cd8c){const _0x2f7397=function(_0x222c96){while(--_0x222c96){_0x52777d['push'](_0x52777d['shift']());}};_0x2f7397(++_0x35cd8c);}(a1143_0x35cd,0x130));const a1143_0x2f73=function(_0x52777d,_0x35cd8c){_0x52777d=_0x52777d-0x0;let _0x2f7397=a1143_0x35cd[_0x52777d];return _0x2f7397;};const _0x331b5f=a1143_0x2f73;'use strict';const _=require(_0x331b5f('0x21')),rp=require('request-promise-native'),md5=require(_0x331b5f('0x64')),util=require(_0x331b5f('0x6')),intUtil=require(_0x331b5f('0x2c')),logger=require(_0x331b5f('0x8'))(_0x331b5f('0x3a')),{getSocket}=require(_0x331b5f('0xd')),io=getSocket(),def={'method':_0x331b5f('0x31'),'json':!![]};function emit(_0x222c96,_0x118e61,_0x88010e){const _0x49233e=_0x331b5f;io['to'](_0x222c96)[_0x49233e('0x26')](_0x118e61,_0x88010e);}function getTicket(_0x4c9693,_0x564f52,_0x5d5e21,_0x348219,_0x307435,_0x4ceb59,_0x27b598,_0x270062){const _0x1859be=_0x331b5f;logger[_0x1859be('0x28')](_0x1859be('0x58'));const _0x120d4e=new Date(),_0x3efdd4=[{'name':_0x1859be('0x20'),'value':intUtil['getString'](_0x348219[_0x1859be('0x4e')],_0x307435,'\x20')},{'name':'assigned_user_id','value':_0x564f52['id']},{'name':_0x1859be('0x41'),'value':_0x564f52['id']},{'name':_0x1859be('0x4'),'value':intUtil['getString'](_0x348219['Descriptions'],_0x307435,'\x0a')},{'name':_0x1859be('0x47'),'value':_0x120d4e[_0x1859be('0x42')]()[_0x1859be('0x24')](0x0,0x13)[_0x1859be('0x39')]('T','\x20')},{'name':_0x1859be('0x5c'),'value':'0'},{'name':_0x1859be('0x3e'),'value':'15'},{'name':_0x1859be('0x46'),'value':_0x5d5e21['id']},{'name':_0x1859be('0x3b'),'value':_0x1859be('0x1e')},{'name':_0x1859be('0x4a'),'value':_0x5d5e21['name']},{'name':_0x1859be('0x49'),'value':_0x270062}];return _0x4ceb59['length']&&_[_0x1859be('0x61')](_0x4ceb59,function(_0x95b88b){const _0x261aa3=_0x1859be;_0x307435[_0x95b88b[_0x261aa3('0x5')]]&&_0x3efdd4[_0x261aa3('0x1d')]({'name':_0x95b88b[_0x261aa3('0x59')],'value':_0x307435[_0x95b88b[_0x261aa3('0x5')]]});}),request({'form':{'method':'set_entry','input_type':_0x1859be('0xb'),'response_type':'JSON','rest_data':JSON[_0x1859be('0x5b')]({'session':_0x27b598['id'],'module_name':_0x1859be('0x3d'),'name_value_list':_0x3efdd4})}});}function getServerInfo(_0x33ec2f){const _0xf25256=_0x331b5f;return request({'form':{'method':_0xf25256('0x56'),'input_type':_0xf25256('0xb'),'response_type':_0xf25256('0xb'),'rest_data':JSON[_0xf25256('0x5b')]({'session':_0x33ec2f['id']})}});}function getUser(_0x8ab648,_0x30f77d,_0x1bc8b0){const _0x43fb3d=_0x331b5f;return!_['isNil'](_0x30f77d)?(logger[_0x43fb3d('0x28')](_0x43fb3d('0x55'),_0x30f77d),request({'form':{'method':_0x43fb3d('0x57'),'input_type':_0x43fb3d('0xb'),'response_type':_0x43fb3d('0xb'),'rest_data':JSON[_0x43fb3d('0x5b')]({'session':_0x1bc8b0['id'],'module_name':_0x43fb3d('0x2b'),'query':util[_0x43fb3d('0x4d')](_0x43fb3d('0x62'),_0x30f77d),'order_by':'','offset':'0','select_fields':['id',_0x43fb3d('0x20'),_0x43fb3d('0x5a')],'link_name_to_fields_array':[],'max_results':-0x1,'deleted':'0'})}})[_0x43fb3d('0x5e')](function(_0xe89905){const _0xd0af28=_0x43fb3d;if(_0xe89905['entry_list'][_0xd0af28('0x63')]){const _0x378245=_[_0xd0af28('0x54')](_0xe89905[_0xd0af28('0x4c')],function(_0x4bfecb){const _0x3bc9e2=_0xd0af28;return _0x4bfecb[_0x3bc9e2('0x37')][_0x3bc9e2('0x5a')][_0x3bc9e2('0x1')]===_0x30f77d;});if(_0x378245)return logger[_0xd0af28('0x28')](_0xd0af28('0x0')),Promise[_0xd0af28('0x17')]({'id':_0x378245[_0xd0af28('0x37')]['id'][_0xd0af28('0x1')],'name':_0x378245[_0xd0af28('0x37')][_0xd0af28('0x20')][_0xd0af28('0x1')]});}return logger[_0xd0af28('0x28')](_0xd0af28('0x22')),Promise['resolve']({'id':_0x1bc8b0[_0xd0af28('0x37')]['user_id']['value'],'name':_0x1bc8b0['name_value_list'][_0xd0af28('0x5a')][_0xd0af28('0x1')]});})):(logger['info']('Agent\x20not\x20available,\x20using\x20the\x20admin\x20account!'),Promise[_0x43fb3d('0x17')]({'id':_0x1bc8b0['name_value_list']['user_id']['value'],'name':_0x1bc8b0[_0x43fb3d('0x37')][_0x43fb3d('0x5a')][_0x43fb3d('0x1')]}));}function getEndUser(_0x27a999,_0x2f7284,_0x78924c,_0x22f12c){const _0x107702=_0x331b5f;return logger[_0x107702('0x28')](_0x107702('0x1c'),_0x78924c),request({'form':{'method':'get_entry_list','input_type':'JSON','response_type':_0x107702('0xb'),'rest_data':JSON[_0x107702('0x5b')]({'session':_0x22f12c['id'],'module_name':_0x107702('0x1e'),'query':util[_0x107702('0x4d')](_0x107702('0x53'),_0x78924c),'order_by':'','offset':'0','select_fields':['id','name',_0x107702('0x10')],'link_name_to_fields_array':[],'max_results':-0x1,'deleted':'0'})}})[_0x107702('0x5e')](function(_0x59d546){const _0x4faf14=_0x107702;if(_0x59d546[_0x4faf14('0x4c')][_0x4faf14('0x63')]){const _0x28cae9=_[_0x4faf14('0x54')](_0x59d546[_0x4faf14('0x4c')],function(_0xcd53e3){const _0x13a311=_0x4faf14;return _0xcd53e3['name_value_list'][_0x13a311('0x10')]['value']===_0x78924c;});if(_0x28cae9)return logger[_0x4faf14('0x28')](_0x4faf14('0x45')),Promise[_0x4faf14('0x17')]({'id':_0x28cae9[_0x4faf14('0x37')]['id'][_0x4faf14('0x1')],'name':_0x28cae9[_0x4faf14('0x37')][_0x4faf14('0x20')]['value'],'phone':_0x28cae9[_0x4faf14('0x37')][_0x4faf14('0x10')][_0x4faf14('0x1')]});}else return logger[_0x4faf14('0x28')](_0x4faf14('0x1b')),request({'form':{'method':'set_entry','input_type':_0x4faf14('0xb'),'response_type':'JSON','rest_data':JSON[_0x4faf14('0x5b')]({'session':_0x22f12c['id'],'module_name':_0x4faf14('0x1e'),'name_value_list':[{'name':_0x4faf14('0x9'),'value':_0x2f7284!==_0x4faf14('0x1a')?_0x2f7284:util[_0x4faf14('0x4d')](_0x4faf14('0x5f'),_0x78924c)},{'name':_0x4faf14('0x10'),'value':_0x78924c}]})}})[_0x4faf14('0x5e')](function(_0x421374){const _0x1b0719=_0x4faf14;return logger[_0x1b0719('0x28')](_0x1b0719('0x40')),Promise['resolve']({'id':_0x421374['id'],'name':_0x421374['entry_list'][_0x1b0719('0x9')][_0x1b0719('0x1')],'phone':_0x421374['entry_list'][_0x1b0719('0x10')]['value']});});});}function request(_0x288831){const _0x37d51b=_0x331b5f;return logger[_0x37d51b('0x14')](_0x37d51b('0xe'),JSON['stringify'](_0x288831)),rp(_['merge'](def,_0x288831));}function getConnection(_0x5becbe){const _0x5c69ac=_0x331b5f;return request({'method':_0x5c69ac('0x31'),'form':{'method':'login','input_type':_0x5c69ac('0xb'),'response_type':_0x5c69ac('0xb'),'rest_data':JSON[_0x5c69ac('0x5b')]({'user_auth':{'user_name':_0x5becbe[_0x5c69ac('0x7')],'password':_0x5becbe['password'],'encryption':_0x5c69ac('0x38')},'application':_0x5c69ac('0x43')})}})[_0x5c69ac('0x5e')](function(_0x33aa1e){const _0x5b99ef=_0x5c69ac,_0x1f8e52=_0x33aa1e;if(_0x1f8e52['id'])return def[_0x5b99ef('0x35')]=_0x1f8e52['id'],Promise[_0x5b99ef('0x17')](_0x1f8e52);else throw new Error(util[_0x5b99ef('0x4d')]('Account\x20%d\x20is\x20not\x20valid',_0x5becbe['id']));});}function setRelationship(_0x5af175,_0x1e20ac,_0x16fd34,_0x3d8ba1){const _0x5ed7a7=_0x331b5f;return request({'form':{'method':_0x5ed7a7('0x51'),'input_type':_0x5ed7a7('0xb'),'response_type':'JSON','rest_data':JSON[_0x5ed7a7('0x5b')]({'session':_0x5af175['id'],'module_name':_0x5ed7a7('0x3d'),'module_id':_0x16fd34['id'],'link_field_name':_0x3d8ba1,'related_ids':[_0x1e20ac['id']]})}});}exports[_0x331b5f('0x25')]=function(_0x3ec4dd,_0x2ee777,_0x34c015,_0x23ae50,_0x274ccf,_0x1a385e){const _0xfd5390=_0x331b5f;let _0x418808,_0x48b051,_0x38f139,_0x21bcd8;return _0x1a385e['remoteUri']=intUtil['stripTrailingSlash'](_0x1a385e[_0xfd5390('0x32')]),_0x1a385e[_0xfd5390('0x2e')]=intUtil[_0xfd5390('0x36')](_0x1a385e[_0xfd5390('0x2e')]),def[_0xfd5390('0x3c')]=util[_0xfd5390('0x4d')](_0xfd5390('0x27'),_0x1a385e[_0xfd5390('0x32')]),_0x274ccf&&_0x274ccf[_0xfd5390('0x4f')]?(logger[_0xfd5390('0x28')](_0xfd5390('0x12'),_0xfd5390('0x23')),_0x2ee777[_0xfd5390('0x52')]=util['format']('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x1a385e['serverUrl'],_0x2ee777['uniqueid'],md5(_0x2ee777['uniqueid']))):_0x2ee777[_0xfd5390('0x52')]='',getConnection(_0x1a385e)['then'](function(_0x11f8de){const _0x96b351=_0xfd5390;return _0x21bcd8=_0x11f8de,getUser(_0x1a385e,_0x23ae50[_0x96b351('0x20')],_0x21bcd8);})['then'](function(_0x1775c9){const _0x128fab=_0xfd5390;return _0x418808=_0x1775c9,logger['info']('The\x20User\x20ID\x20is:',_0x418808['id']),getEndUser(_0x1a385e,_0x2ee777[_0x128fab('0x2d')],_0x2ee777['calleridnum'],_0x21bcd8);})['then'](function(_0x541f6f){const _0x4c466f=_0xfd5390;return _0x48b051=_0x541f6f,logger['info'](_0x4c466f('0x18'),_0x48b051['id']),getTicket(_0x1a385e,_0x418808,_0x48b051,_0x34c015,_0x2ee777,_0x34c015[_0x4c466f('0x1f')],_0x21bcd8,_0x4c466f('0x3'));})[_0xfd5390('0x5e')](function(_0xc5e4cc){const _0x4a9798=_0xfd5390;return _0x38f139=_0xc5e4cc,logger[_0x4a9798('0x28')](_0x4a9798('0x50')),logger[_0x4a9798('0x28')]('The\x20Ticket\x20ID\x20is:',_0x38f139['id']),setRelationship(_0x21bcd8,_0x418808,_0x38f139,_0x4a9798('0x11'));})[_0xfd5390('0x5e')](function(){const _0x3b1d7a=_0xfd5390;return setRelationship(_0x21bcd8,_0x48b051,_0x38f139,_0x3b1d7a('0x4b'));})['then'](function(){return getServerInfo(_0x21bcd8);})[_0xfd5390('0x5e')](function(_0xb588e2){const _0x18dc27=_0xfd5390,_0x276d1b=parseInt(_0xb588e2[_0x18dc27('0x2f')][_0x18dc27('0x5d')](0x0));let _0x134af8=util['format'](_0x18dc27('0x65'),_0x1a385e['remoteUri'],_0x38f139['id']);_0x276d1b>0x6&&(_0x134af8=util[_0x18dc27('0x4d')]('%s/#bwc/index.php?module=Calls&action=EditView&record=%s',_0x1a385e[_0x18dc27('0x32')],_0x38f139['id'])),logger['info'](_0x18dc27('0x12'),_0x18dc27('0x44')),emit(util['format'](_0x18dc27('0x3f'),_0x23ae50['name']),_0x18dc27('0xa'),{'uri':_0x134af8});})[_0xfd5390('0x16')](function(_0x2fa35e){const _0x29d794=_0xfd5390;logger['error']('[QUEUE]',JSON[_0x29d794('0x5b')](_0x2fa35e));});},exports[_0x331b5f('0xf')]=function(_0x3ef892,_0x1545b0,_0x57994f,_0x5c1a4e,_0x3c43c3,_0x3c7a23,_0x228933){const _0x812289=_0x331b5f;let _0x3bd28d,_0x19c5c9,_0x494fb0,_0x3ccbc4;return _0x3c7a23['remoteUri']=intUtil[_0x812289('0x36')](_0x3c7a23[_0x812289('0x32')]),_0x3c7a23[_0x812289('0x2e')]=intUtil[_0x812289('0x36')](_0x3c7a23[_0x812289('0x2e')]),def[_0x812289('0x3c')]=util['format'](_0x812289('0x27'),_0x3c7a23[_0x812289('0x32')]),_0x228933&&_0x228933[_0x812289('0x34')]&&_0x228933['recordingFormat']!==_0x812289('0x48')&&(logger[_0x812289('0x28')](_0x812289('0x60'),_0x812289('0x23')),_0x1545b0[_0x812289('0x52')]=util[_0x812289('0x4d')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x3c7a23[_0x812289('0x2e')],_0x1545b0[_0x812289('0x33')],md5(_0x1545b0['uniqueid']))),getConnection(_0x3c7a23)[_0x812289('0x5e')](function(_0x1c2110){const _0x1a9484=_0x812289;return _0x3ccbc4=_0x1c2110,getUser(_0x3c7a23,_0x5c1a4e[_0x1a9484('0x20')],_0x3ccbc4);})[_0x812289('0x5e')](function(_0x55e598){const _0x560065=_0x812289;return _0x3bd28d=_0x55e598,logger[_0x560065('0x28')](_0x560065('0x66'),_0x3bd28d['id']),getEndUser(_0x3c7a23,_0x1545b0['destcalleridname'],_0x1545b0['destcalleridnum'],_0x3ccbc4);})[_0x812289('0x5e')](function(_0x5ae333){const _0x403d8b=_0x812289;return _0x19c5c9=_0x5ae333,logger[_0x403d8b('0x28')]('The\x20Enduser\x20ID\x20is:',_0x19c5c9['id']),getTicket(_0x3c7a23,_0x3bd28d,_0x19c5c9,_0x57994f,_0x1545b0,_0x57994f[_0x403d8b('0x1f')],_0x3ccbc4,_0x403d8b('0x30'));})[_0x812289('0x5e')](function(_0x6472e2){const _0x1b1676=_0x812289;return _0x494fb0=_0x6472e2,logger[_0x1b1676('0x28')](_0x1b1676('0x50')),logger[_0x1b1676('0x28')]('The\x20Ticket\x20ID\x20is:',_0x494fb0['id']),setRelationship(_0x3ccbc4,_0x3bd28d,_0x494fb0,_0x1b1676('0x11'));})[_0x812289('0x5e')](function(){const _0x50ce0e=_0x812289;return setRelationship(_0x3ccbc4,_0x19c5c9,_0x494fb0,_0x50ce0e('0x4b'));})[_0x812289('0x5e')](function(){return getServerInfo(_0x3ccbc4);})[_0x812289('0x5e')](function(_0x5ca3b1){const _0x318048=_0x812289,_0x1a8d15=parseInt(_0x5ca3b1[_0x318048('0x2f')]['charAt'](0x0));let _0x1cd7d3=util['format'](_0x318048('0x65'),_0x3c7a23[_0x318048('0x32')],_0x494fb0['id']);_0x1a8d15>0x6&&(_0x1cd7d3=util[_0x318048('0x4d')](_0x318048('0x13'),_0x3c7a23['remoteUri'],_0x494fb0['id'])),logger[_0x318048('0x28')](_0x318048('0x60'),_0x318048('0x44')),emit(util[_0x318048('0x4d')](_0x318048('0x3f'),_0x5c1a4e[_0x318048('0x20')]),_0x318048('0xa'),{'uri':_0x1cd7d3});})[_0x812289('0x16')](function(_0x3869d6){const _0x2e277e=_0x812289;logger['error']('[OUTBOUND]',JSON[_0x2e277e('0x5b')](_0x3869d6));});},exports[_0x331b5f('0x15')]=function(_0x2256ba,_0xd6b1a2,_0x5839d7,_0x32e419,_0x1776a7,_0x14cb4d){const _0x34e335=_0x331b5f;let _0xda3d73,_0x53b6d3,_0x5e35f3,_0x3f67ac;return _0x14cb4d[_0x34e335('0x32')]=intUtil[_0x34e335('0x36')](_0x14cb4d['remoteUri']),_0x14cb4d[_0x34e335('0x2e')]=intUtil[_0x34e335('0x36')](_0x14cb4d['serverUrl']),def[_0x34e335('0x3c')]=util[_0x34e335('0x4d')](_0x34e335('0x27'),_0x14cb4d[_0x34e335('0x32')]),_0x1776a7&&_0x1776a7['monitor_format']?(logger['info']('['+_0xd6b1a2[_0x34e335('0x2a')][_0x34e335('0x29')]()+']',_0x34e335('0x23')),_0xd6b1a2[_0x34e335('0x52')]=util[_0x34e335('0x4d')](_0x34e335('0xc'),_0x14cb4d['serverUrl'],_0xd6b1a2[_0x34e335('0x33')],md5(_0xd6b1a2[_0x34e335('0x33')]))):_0xd6b1a2[_0x34e335('0x52')]='',getConnection(_0x14cb4d)['then'](function(_0xf08dcb){const _0x3d978b=_0x34e335;return _0x3f67ac=_0xf08dcb,!_[_0x3d978b('0x2')](_0x32e419)?getUser(_0x14cb4d,_0x32e419[_0x3d978b('0x20')],_0x3f67ac):getUser(_0x14cb4d,null,_0x3f67ac);})[_0x34e335('0x5e')](function(_0x56d649){const _0x43d22b=_0x34e335;return _0xda3d73=_0x56d649,logger['info'](_0x43d22b('0x66'),_0xda3d73['id']),getEndUser(_0x14cb4d,_0xd6b1a2['calleridname'],_0xd6b1a2[_0x43d22b('0x19')],_0x3f67ac);})[_0x34e335('0x5e')](function(_0x12ba5e){const _0xdf215=_0x34e335;return _0x53b6d3=_0x12ba5e,logger[_0xdf215('0x28')]('The\x20Enduser\x20ID\x20is:',_0x53b6d3['id']),getTicket(_0x14cb4d,_0xda3d73,_0x53b6d3,_0x5839d7,_0xd6b1a2,_0x5839d7[_0xdf215('0x1f')],_0x3f67ac,_0xdf215('0x3'));})[_0x34e335('0x5e')](function(_0x29157d){const _0x230a63=_0x34e335;return _0x5e35f3=_0x29157d,logger[_0x230a63('0x28')](_0x230a63('0x50')),logger['info']('The\x20Ticket\x20ID\x20is:',_0x5e35f3['id']),setRelationship(_0x3f67ac,_0xda3d73,_0x5e35f3,_0x230a63('0x11'));})[_0x34e335('0x5e')](function(){const _0x5705e9=_0x34e335;return setRelationship(_0x3f67ac,_0x53b6d3,_0x5e35f3,_0x5705e9('0x4b'));})[_0x34e335('0x5e')](function(){return getServerInfo(_0x3f67ac);})[_0x34e335('0x16')](function(_0x3b15e4){const _0x5d9548=_0x34e335;logger['error']('['+_0xd6b1a2[_0x5d9548('0x2a')][_0x5d9548('0x29')]()+']',JSON['stringify'](_0x3b15e4));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/util.js b/server/services/ami/trigger/integration/util.js index 3847852..e8cdba9 100644 --- a/server/services/ami/trigger/integration/util.js +++ b/server/services/ami/trigger/integration/util.js @@ -1 +1 @@ -const a1144_0x5084=['util','string','length','%s:\x20%s','validateEmail','keyContent','lastIndexOf','customVariable','toString','getString','format','variableName','content','toLowerCase','stripTrailingSlash','isNil','Variable','type','name','variable','keyType','push','key','lodash','keyValue','substring','join'];(function(_0x6da047,_0x508409){const _0xff9127=function(_0x2e5376){while(--_0x2e5376){_0x6da047['push'](_0x6da047['shift']());}};_0xff9127(++_0x508409);}(a1144_0x5084,0x6c));const a1144_0xff91=function(_0x6da047,_0x508409){_0x6da047=_0x6da047-0x0;let _0xff9127=a1144_0x5084[_0x6da047];return _0xff9127;};const _0x36d94a=a1144_0xff91;'use strict';const _=require(_0x36d94a('0x17')),util=require(_0x36d94a('0x0'));exports[_0x36d94a('0x9')]=function(_0x2e5376,_0x3a439b,_0x3c6c9a){const _0x1dab70=_0x36d94a,_0x45b4cc=[];if(_0x2e5376[_0x1dab70('0x2')]>0x0){const _0x424051=_['sortBy'](_0x2e5376,['id']);for(let _0x1fc816=0x0;_0x1fc816<_0x424051[_0x1dab70('0x2')];_0x1fc816++){const _0x400cbb=_0x424051[_0x1fc816];if(_0x400cbb['type']===_0x1dab70('0x1'))_0x45b4cc[_0x1dab70('0x15')](_0x400cbb[_0x1dab70('0xc')]);else{if(_0x400cbb[_0x1dab70('0x11')]==='variable'&&_0x400cbb[_0x1dab70('0xb')])_0x3a439b[_0x400cbb[_0x1dab70('0xb')]]&&_0x45b4cc['push'](_0x3a439b[_0x400cbb['variableName']]['toString']());else{if(_0x400cbb[_0x1dab70('0x11')]===_0x1dab70('0x7')&&_0x400cbb['Variable']&&_0x400cbb[_0x1dab70('0x10')][_0x1dab70('0x12')])_0x3a439b[_0x400cbb['Variable'][_0x1dab70('0x12')]['toLowerCase']()]&&_0x45b4cc['push'](_0x3a439b[_0x400cbb[_0x1dab70('0x10')][_0x1dab70('0x12')][_0x1dab70('0xd')]()][_0x1dab70('0x8')]());else{if(_0x400cbb[_0x1dab70('0x11')]===_0x1dab70('0x18')){if(_0x400cbb[_0x1dab70('0x14')]===_0x1dab70('0x1')&&_0x400cbb[_0x1dab70('0x16')])_0x45b4cc['push'](util[_0x1dab70('0xa')](_0x1dab70('0x3'),_0x400cbb['key'],_0x400cbb[_0x1dab70('0x5')]));else{if(_0x400cbb[_0x1dab70('0x14')]===_0x1dab70('0x13')&&_0x400cbb[_0x1dab70('0xb')]&&_0x400cbb[_0x1dab70('0x16')])_0x3a439b[_0x400cbb[_0x1dab70('0xb')]]&&_0x45b4cc[_0x1dab70('0x15')](util[_0x1dab70('0xa')]('%s:\x20%s',_0x400cbb[_0x1dab70('0x16')],_0x3a439b[_0x400cbb[_0x1dab70('0xb')]]));else _0x400cbb[_0x1dab70('0x14')]===_0x1dab70('0x7')&&_0x400cbb[_0x1dab70('0x10')]&&_0x400cbb[_0x1dab70('0x10')]['name']&&_0x400cbb[_0x1dab70('0x16')]&&(_0x3a439b[_0x400cbb[_0x1dab70('0x10')][_0x1dab70('0x12')]['toLowerCase']()]&&_0x45b4cc[_0x1dab70('0x15')](util['format']('%s:\x20%s',_0x400cbb['key'],_0x3a439b[_0x400cbb[_0x1dab70('0x10')][_0x1dab70('0x12')][_0x1dab70('0xd')]()])));}}}}}}}return _0x45b4cc[_0x1dab70('0x1a')](_0x3c6c9a);},exports[_0x36d94a('0xe')]=function(_0x1d37b3){const _0x399bef=_0x36d94a,_0x387617=_0x1d37b3['slice'](-0x1);return _0x387617==='/'&&(_0x1d37b3=_0x1d37b3[_0x399bef('0x19')](0x0,_0x1d37b3[_0x399bef('0x6')](_0x387617))),_0x1d37b3;},exports[_0x36d94a('0x4')]=function(_0x3c153e){const _0x1704c7=_0x36d94a;if(!_[_0x1704c7('0xf')](_0x3c153e)&&_0x3c153e!==''){const _0x30e631=/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;return _0x30e631['test'](String(_0x3c153e)[_0x1704c7('0xd')]());}else return![];}; \ No newline at end of file +const a1144_0xf723=['lodash','format','variableName','name','%s:\x20%s','util','variable','customVariable','isNil','slice','stripTrailingSlash','length','keyType','toString','keyValue','test','substring','type','string','sortBy','Variable','key','toLowerCase','push','join','keyContent'];(function(_0x168df9,_0xf723b8){const _0x4334df=function(_0x3607e6){while(--_0x3607e6){_0x168df9['push'](_0x168df9['shift']());}};_0x4334df(++_0xf723b8);}(a1144_0xf723,0x6b));const a1144_0x4334=function(_0x168df9,_0xf723b8){_0x168df9=_0x168df9-0x0;let _0x4334df=a1144_0xf723[_0x168df9];return _0x4334df;};const _0x3b5fd4=a1144_0x4334;'use strict';const _=require(_0x3b5fd4('0x17')),util=require(_0x3b5fd4('0x2'));exports['getString']=function(_0x3607e6,_0x4ba8fa,_0x35570e){const _0x3b4c3e=_0x3b5fd4,_0x332e76=[];if(_0x3607e6[_0x3b4c3e('0x8')]>0x0){const _0xc71118=_[_0x3b4c3e('0x10')](_0x3607e6,['id']);for(let _0x1190f4=0x0;_0x1190f4<_0xc71118[_0x3b4c3e('0x8')];_0x1190f4++){const _0x225a0d=_0xc71118[_0x1190f4];if(_0x225a0d[_0x3b4c3e('0xe')]===_0x3b4c3e('0xf'))_0x332e76[_0x3b4c3e('0x14')](_0x225a0d['content']);else{if(_0x225a0d['type']===_0x3b4c3e('0x3')&&_0x225a0d['variableName'])_0x4ba8fa[_0x225a0d[_0x3b4c3e('0x19')]]&&_0x332e76[_0x3b4c3e('0x14')](_0x4ba8fa[_0x225a0d['variableName']][_0x3b4c3e('0xa')]());else{if(_0x225a0d[_0x3b4c3e('0xe')]===_0x3b4c3e('0x4')&&_0x225a0d[_0x3b4c3e('0x11')]&&_0x225a0d[_0x3b4c3e('0x11')][_0x3b4c3e('0x0')])_0x4ba8fa[_0x225a0d[_0x3b4c3e('0x11')][_0x3b4c3e('0x0')]['toLowerCase']()]&&_0x332e76[_0x3b4c3e('0x14')](_0x4ba8fa[_0x225a0d['Variable'][_0x3b4c3e('0x0')][_0x3b4c3e('0x13')]()][_0x3b4c3e('0xa')]());else{if(_0x225a0d[_0x3b4c3e('0xe')]===_0x3b4c3e('0xb')){if(_0x225a0d[_0x3b4c3e('0x9')]===_0x3b4c3e('0xf')&&_0x225a0d[_0x3b4c3e('0x12')])_0x332e76['push'](util[_0x3b4c3e('0x18')](_0x3b4c3e('0x1'),_0x225a0d[_0x3b4c3e('0x12')],_0x225a0d[_0x3b4c3e('0x16')]));else{if(_0x225a0d['keyType']===_0x3b4c3e('0x3')&&_0x225a0d[_0x3b4c3e('0x19')]&&_0x225a0d['key'])_0x4ba8fa[_0x225a0d[_0x3b4c3e('0x19')]]&&_0x332e76[_0x3b4c3e('0x14')](util[_0x3b4c3e('0x18')](_0x3b4c3e('0x1'),_0x225a0d[_0x3b4c3e('0x12')],_0x4ba8fa[_0x225a0d[_0x3b4c3e('0x19')]]));else _0x225a0d[_0x3b4c3e('0x9')]===_0x3b4c3e('0x4')&&_0x225a0d[_0x3b4c3e('0x11')]&&_0x225a0d[_0x3b4c3e('0x11')][_0x3b4c3e('0x0')]&&_0x225a0d[_0x3b4c3e('0x12')]&&(_0x4ba8fa[_0x225a0d[_0x3b4c3e('0x11')]['name'][_0x3b4c3e('0x13')]()]&&_0x332e76[_0x3b4c3e('0x14')](util[_0x3b4c3e('0x18')](_0x3b4c3e('0x1'),_0x225a0d[_0x3b4c3e('0x12')],_0x4ba8fa[_0x225a0d[_0x3b4c3e('0x11')][_0x3b4c3e('0x0')][_0x3b4c3e('0x13')]()])));}}}}}}}return _0x332e76[_0x3b4c3e('0x15')](_0x35570e);},exports[_0x3b5fd4('0x7')]=function(_0x3b0401){const _0x1bcd4f=_0x3b5fd4,_0x253067=_0x3b0401[_0x1bcd4f('0x6')](-0x1);return _0x253067==='/'&&(_0x3b0401=_0x3b0401[_0x1bcd4f('0xd')](0x0,_0x3b0401['lastIndexOf'](_0x253067))),_0x3b0401;},exports['validateEmail']=function(_0x3818de){const _0x4fe690=_0x3b5fd4;if(!_[_0x4fe690('0x5')](_0x3818de)&&_0x3818de!==''){const _0x2d3a43=/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;return _0x2d3a43[_0x4fe690('0xc')](String(_0x3818de)[_0x4fe690('0x13')]());}else return![];}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/vtiger.js b/server/services/ami/trigger/integration/vtiger.js index c74b513..e48a5c9 100644 --- a/server/services/ami/trigger/integration/vtiger.js +++ b/server/services/ami/trigger/integration/vtiger.js @@ -1 +1 @@ -const a1145_0xfff6=['calleridnum','[vTiger],\x20%s,\x20%s,\x20%s','queue','recordingURL','Searching\x20end\x20user\x20with\x20phone','serverUrl','login','Agent\x20found!','validateEmail','uniqueid','[OUTBOUND]','admin','split','trigger:browser:url','accessKey','SELECT\x20first_name,\x20last_name,\x20email1\x20FROM\x20Users\x20WHERE\x20email1=\x27%s\x27;','[HTTP]','Enduser\x20not\x20found,\x20creating\x20a\x20new\x20enduser!','query','Ticket\x20could\x20not\x20be\x20created\x20due\x20to:\x20%s','username','stringify','getchallenge','forEach','customVariable','info','%s/webservice.php','./util','createTicket','recordingFormat','last_name','The\x20Ticket\x20ID\x20is:','Getting\x20agent\x20with\x20email','getUser','POST','lastname','result','statusCode','string','userId','remoteUri','toLowerCase','Descriptions','Recording\x20is\x20enabled!','success','destcalleridname','Ticket\x20created!','Normal','format','Fields','calleridname','sessionName','catch','vTiger','name','getConnection','idField','email','../../../../rediscache','Open','content','create','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','error','email1','%s/index.php?module=HelpDesk&view=Detail&record=%s&app=SUPPORT','Variable','user:%s','util','then','stripTrailingSlash','request-promise-native','Contacts','lastevent','Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...','type','The\x20Enduser\x20ID\x20is:','[QUEUE]','monitor_format','none','GET','toUpperCase','The\x20User\x20ID\x20is:','token','resolve','getString','variableName','SELECT\x20id,\x20firstname,\x20lastname,\x20email,\x20phone,\x20mobile,\x20homephone,\x20otherphone,\x20assistantphone\x20FROM\x20Contacts\x20WHERE\x20phone\x20=\x20\x27%s\x27\x20OR\x20mobile\x20=\x27%s\x27\x20OR\x20homephone\x20=\x27%s\x27\x20OR\x20otherphone\x20=\x27%s\x27\x20OR\x20assistantphone\x20=\x27%s\x27;','firstname','outbound','toString','length','Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!','Enduser\x20found!','Subjects','destcalleridnum'];(function(_0x2e30a1,_0xfff6bc){const _0x26b6e8=function(_0x3797bf){while(--_0x3797bf){_0x2e30a1['push'](_0x2e30a1['shift']());}};_0x26b6e8(++_0xfff6bc);}(a1145_0xfff6,0x17f));const a1145_0x26b6=function(_0x2e30a1,_0xfff6bc){_0x2e30a1=_0x2e30a1-0x0;let _0x26b6e8=a1145_0xfff6[_0x2e30a1];return _0x26b6e8;};const _0x348023=a1145_0x26b6;'use strict';const _=require('lodash'),rp=require(_0x348023('0x48')),md5=require('md5'),util=require(_0x348023('0x45')),intUtil=require(_0x348023('0x1c')),logger=require('../../../../config/logger')(_0x348023('0x36')),{getSocket}=require(_0x348023('0x3b')),io=getSocket();function emit(_0x3797bf,_0x40ed38,_0x802acc){io['to'](_0x3797bf)['emit'](_0x40ed38,_0x802acc);}function getCustomFields(_0x303638,_0x931fa7){const _0x36d22e=_0x348023,_0x40d3f0={};return _0x303638[_0x36d22e('0x5c')]>0x0&&_[_0x36d22e('0x18')](_0x303638,function(_0x4ab0eb){const _0x59c401=_0x36d22e;if(_0x4ab0eb[_0x59c401('0x4c')]===_0x59c401('0x27')&&_0x4ab0eb[_0x59c401('0x39')])_0x40d3f0[_0x4ab0eb[_0x59c401('0x39')]]=_0x4ab0eb[_0x59c401('0x3d')][_0x59c401('0x5b')]();else{if(_0x4ab0eb[_0x59c401('0x4c')]==='variable'&&_0x4ab0eb[_0x59c401('0x57')]&&_0x4ab0eb[_0x59c401('0x39')]&&_0x931fa7[_0x4ab0eb[_0x59c401('0x57')]])_0x40d3f0[_0x4ab0eb['idField']]=_0x931fa7[_0x4ab0eb[_0x59c401('0x57')]][_0x59c401('0x5b')]();else _0x4ab0eb[_0x59c401('0x4c')]===_0x59c401('0x19')&&_0x4ab0eb[_0x59c401('0x43')]&&_0x4ab0eb[_0x59c401('0x43')]['name']&&_0x4ab0eb['idField']&&_0x931fa7[_0x4ab0eb['Variable'][_0x59c401('0x37')][_0x59c401('0x2a')]()]&&(_0x40d3f0[_0x4ab0eb[_0x59c401('0x39')]]=_0x931fa7[_0x4ab0eb[_0x59c401('0x43')][_0x59c401('0x37')][_0x59c401('0x2a')]()][_0x59c401('0x5b')]());}}),_0x40d3f0;}function createTicket(_0x41b318,_0x54896f,_0x27c1e8,_0x453359,_0x227d20,_0x54f67d,_0x32a310){const _0x4161b4=_0x348023;logger[_0x4161b4('0x1a')]('Creating\x20new\x20ticket...');const _0x46c4c6=_['merge']({'parent_id':'','assigned_user_id':_0x54896f['id'],'ticketpriorities':_0x4161b4('0x30'),'ticketstatus':_0x4161b4('0x3c'),'ticket_title':intUtil[_0x4161b4('0x56')](_0x453359[_0x4161b4('0x5f')],_0x227d20,'\x20'),'description':intUtil[_0x4161b4('0x56')](_0x453359[_0x4161b4('0x2b')],_0x227d20,'\x0a'),'contact_id':_0x27c1e8['id']},getCustomFields(_0x54f67d,_0x227d20)),_0xaaaf19={'method':_0x4161b4('0x23'),'uri':util['format'](_0x4161b4('0x1b'),_0x41b318[_0x4161b4('0x29')]),'form':{'operation':'create','username':_0x41b318[_0x4161b4('0x15')],'sessionName':_0x32a310[_0x4161b4('0x34')],'elementType':'HelpDesk','element':JSON[_0x4161b4('0x16')](_0x46c4c6)},'json':!![]};return request(_0xaaaf19)[_0x4161b4('0x46')](function(_0x2c4aa1){const _0x55fa4d=_0x4161b4;if(_0x2c4aa1['success'])return Promise['resolve']({'id':_0x2c4aa1['result']['id']});else throw new Error(util[_0x55fa4d('0x31')](_0x55fa4d('0x14'),JSON[_0x55fa4d('0x16')](_0x2c4aa1[_0x55fa4d('0x40')])));})[_0x4161b4('0x35')](function(_0x327d33){const _0x5cacef=_0x4161b4,_0x49dff1=_0x327d33['statusCode']||0x1f4;logger[_0x5cacef('0x40')](_0x5cacef('0x2'),_0x5cacef('0x1d'),_0x49dff1,JSON[_0x5cacef('0x16')](_0x327d33));});}function getUser(_0x3c6678,_0x28149d,_0x6be596){const _0x1f915c=_0x348023;return intUtil[_0x1f915c('0x9')](_0x28149d)?(logger['info'](_0x1f915c('0x21'),_0x28149d),request({'method':_0x1f915c('0x51'),'uri':util[_0x1f915c('0x31')](_0x1f915c('0x1b'),_0x3c6678[_0x1f915c('0x29')]),'qs':{'operation':'query','username':_0x3c6678[_0x1f915c('0x15')],'sessionName':_0x6be596[_0x1f915c('0x34')],'query':util[_0x1f915c('0x31')](_0x1f915c('0x10'),_0x28149d)},'json':!![]})[_0x1f915c('0x46')](function(_0x1f72f9){const _0x12f9d1=_0x1f915c;return _0x1f72f9['success']&&_0x1f72f9[_0x12f9d1('0x25')][_0x12f9d1('0x5c')]?(logger[_0x12f9d1('0x1a')](_0x12f9d1('0x8')),Promise[_0x12f9d1('0x55')]({'id':_0x1f72f9['result'][0x0]['id'],'email':_0x1f72f9[_0x12f9d1('0x25')][0x0][_0x12f9d1('0x41')],'name':_0x1f72f9[_0x12f9d1('0x25')][0x0]['first_name']+'\x20'+_0x1f72f9[_0x12f9d1('0x25')][_0x12f9d1('0x1f')]})):(logger[_0x12f9d1('0x1a')](_0x12f9d1('0x5d')),Promise[_0x12f9d1('0x55')]({'id':_0x6be596['userId'],'email':_0x3c6678['username'],'name':_0x12f9d1('0xc')}));})[_0x1f915c('0x35')](function(_0x13d0f5){const _0x444bd9=_0x1f915c,_0x17a289=_0x13d0f5[_0x444bd9('0x26')]||0x1f4;logger['error'](_0x444bd9('0x2'),_0x444bd9('0x22'),_0x17a289,JSON['stringify'](_0x13d0f5));})):(logger['info'](_0x1f915c('0x5d')),Promise[_0x1f915c('0x55')]({'id':_0x6be596[_0x1f915c('0x28')],'email':_0x3c6678[_0x1f915c('0x15')],'name':_0x1f915c('0xc')})[_0x1f915c('0x35')](function(_0x12e74d){const _0x51a3f7=_0x1f915c,_0xbd1aa0=_0x12e74d['statusCode']||0x1f4;logger[_0x51a3f7('0x40')](_0x51a3f7('0x2'),_0x51a3f7('0x22'),_0xbd1aa0,JSON[_0x51a3f7('0x16')](_0x12e74d));}));}function getEndUser(_0x45b63d,_0xd5b8d2,_0x36f7b3,_0x1fc12f){const _0x5ea3a6=_0x348023;return logger[_0x5ea3a6('0x1a')](_0x5ea3a6('0x5'),_0x36f7b3),request({'method':'GET','uri':util[_0x5ea3a6('0x31')](_0x5ea3a6('0x1b'),_0x45b63d[_0x5ea3a6('0x29')]),'qs':{'operation':_0x5ea3a6('0x13'),'username':_0x45b63d[_0x5ea3a6('0x15')],'sessionName':_0x1fc12f['sessionName'],'query':util['format'](_0x5ea3a6('0x58'),_0x36f7b3,_0x36f7b3,_0x36f7b3,_0x36f7b3,_0x36f7b3)},'json':!![]})[_0x5ea3a6('0x46')](function(_0x2189a8){const _0xbf8783=_0x5ea3a6;return _0x2189a8['success']&&_0x2189a8[_0xbf8783('0x25')]['length']?(logger[_0xbf8783('0x1a')](_0xbf8783('0x5e')),Promise[_0xbf8783('0x55')]({'id':_0x2189a8[_0xbf8783('0x25')][0x0]['id'],'name':_0x2189a8['result'][0x0][_0xbf8783('0x59')]+'\x20'+_0x2189a8['result'][0x0][_0xbf8783('0x24')],'phone':_0x36f7b3})):(logger[_0xbf8783('0x1a')](_0xbf8783('0x12')),request({'method':_0xbf8783('0x23'),'uri':util[_0xbf8783('0x31')](_0xbf8783('0x1b'),_0x45b63d['remoteUri']),'form':{'operation':_0xbf8783('0x3e'),'sessionName':_0x1fc12f[_0xbf8783('0x34')],'elementType':_0xbf8783('0x49'),'element':JSON['stringify']({'lastname':_0xd5b8d2,'phone':_0x36f7b3,'assigned_user_id':'\x20'})},'json':!![]})['then'](function(_0x5e3e10){const _0x21ba8e=_0xbf8783;return logger[_0x21ba8e('0x1a')]('Enduser\x20created.'),Promise[_0x21ba8e('0x55')]({'id':_0x5e3e10['result']['id'],'name':_0x5e3e10[_0x21ba8e('0x25')][_0x21ba8e('0x24')],'phone':_0x5e3e10[_0x21ba8e('0x25')]['phone']});})[_0xbf8783('0x35')](function(_0x4ad7e6){const _0x448115=_0xbf8783,_0x20ace7=_0x4ad7e6['statusCode']||0x1f4;logger[_0x448115('0x40')](_0x448115('0x2'),'getEndUser',_0x20ace7,JSON['stringify'](_0x4ad7e6));}));});}function getConnection(_0x5688f8){const _0x4443e1=_0x348023,_0x1e59ac=_0x5688f8[_0x4443e1('0x15')],_0x4bf901=_0x5688f8[_0x4443e1('0xf')];return request({'method':'GET','uri':util['format'](_0x4443e1('0x1b'),_0x5688f8[_0x4443e1('0x29')]),'qs':{'operation':_0x4443e1('0x17'),'username':_0x1e59ac},'json':!![]})[_0x4443e1('0x46')](function(_0x31b9a9){const _0xb55192=_0x4443e1;if(_0x31b9a9[_0xb55192('0x2d')])return request({'method':_0xb55192('0x23'),'uri':util[_0xb55192('0x31')](_0xb55192('0x1b'),_0x5688f8[_0xb55192('0x29')]),'form':{'operation':_0xb55192('0x7'),'username':_0x1e59ac,'accessKey':md5(_0x31b9a9[_0xb55192('0x25')][_0xb55192('0x54')]+_0x4bf901)},'json':!![]});})[_0x4443e1('0x46')](function(_0x2c4c9c){const _0x89044a=_0x4443e1;if(_0x2c4c9c[_0x89044a('0x2d')])return Promise[_0x89044a('0x55')](_0x2c4c9c[_0x89044a('0x25')]);else throw new Error(util[_0x89044a('0x31')]('Account\x20%d\x20is\x20not\x20valid',_0x5688f8['id']));})['catch'](function(_0x5c2ff){const _0x5a664a=_0x4443e1,_0x1646e5=_0x5c2ff['statusCode']||0x1f4;logger[_0x5a664a('0x40')](_0x5a664a('0x2'),_0x5a664a('0x38'),_0x1646e5,JSON[_0x5a664a('0x16')](_0x5c2ff));});}function request(_0x5db3c9){const _0x7fb95=_0x348023;return logger[_0x7fb95('0x1a')](_0x7fb95('0x11'),JSON[_0x7fb95('0x16')](_0x5db3c9)),rp(_0x5db3c9);}exports[_0x348023('0x3')]=function(_0x29823d,_0x638390,_0x15ca1c,_0x88014d,_0x4396a5,_0x48cbb8){const _0x2d12d=_0x348023;let _0x42abc,_0x221237,_0x19ecba,_0x1f6d7c;return _0x48cbb8['remoteUri']=intUtil[_0x2d12d('0x47')](_0x48cbb8['remoteUri']),_0x4396a5&&_0x4396a5[_0x2d12d('0x4f')]?(logger['info'](_0x2d12d('0x4e'),_0x2d12d('0x2c')),_0x638390[_0x2d12d('0x4')]=util['format'](_0x2d12d('0x3f'),_0x48cbb8[_0x2d12d('0x6')],_0x638390[_0x2d12d('0xa')],md5(_0x638390[_0x2d12d('0xa')]))):_0x638390[_0x2d12d('0x4')]='',getConnection(_0x48cbb8)['then'](function(_0x392fc4){const _0x316712=_0x2d12d;return _0x1f6d7c=_0x392fc4,getUser(_0x48cbb8,_0x88014d[_0x316712('0x3a')],_0x1f6d7c);})[_0x2d12d('0x46')](function(_0x23b2e3){const _0x2f37af=_0x2d12d;return _0x42abc=_0x23b2e3,logger['info'](_0x2f37af('0x53'),_0x42abc['id']),getEndUser(_0x48cbb8,_0x638390[_0x2f37af('0x33')],_0x638390[_0x2f37af('0x1')],_0x1f6d7c);})[_0x2d12d('0x46')](function(_0x42aa2f){const _0x41bf4c=_0x2d12d;return _0x221237=_0x42aa2f,logger[_0x41bf4c('0x1a')](_0x41bf4c('0x4d'),_0x221237['id']),createTicket(_0x48cbb8,_0x42abc,_0x221237,_0x15ca1c,_0x638390,_0x15ca1c[_0x41bf4c('0x32')],_0x1f6d7c);})[_0x2d12d('0x46')](function(_0x2e4cf8){const _0x82654b=_0x2d12d;_0x19ecba=_0x2e4cf8,logger[_0x82654b('0x1a')](_0x82654b('0x2f')),logger[_0x82654b('0x1a')](_0x82654b('0x20'),_0x19ecba['id']);const _0x59dd8f=util[_0x82654b('0x31')](_0x82654b('0x42'),_0x48cbb8[_0x82654b('0x29')],_[_0x82654b('0xd')](_0x19ecba['id'],'x')[0x1]);logger['info']('[QUEUE]',_0x82654b('0x4b')),emit(util['format'](_0x82654b('0x44'),_0x88014d['name']),_0x82654b('0xe'),{'uri':_0x59dd8f});})[_0x2d12d('0x35')](function(_0x4b951a){const _0x44df82=_0x2d12d;logger['error']('[QUEUE]',JSON[_0x44df82('0x16')](_0x4b951a));});},exports[_0x348023('0x5a')]=function(_0x5c90a6,_0x2a9a60,_0x130f1c,_0x3f3e3b,_0x45a05c,_0x2abf5b,_0x10b2b2){const _0x569157=_0x348023;let _0x1689fd,_0x236b5f,_0x12aca6,_0x18cb45;return _0x2abf5b[_0x569157('0x29')]=intUtil['stripTrailingSlash'](_0x2abf5b[_0x569157('0x29')]),_0x2abf5b[_0x569157('0x6')]=intUtil[_0x569157('0x47')](_0x2abf5b[_0x569157('0x6')]),_0x10b2b2&&_0x10b2b2['recordingFormat']&&_0x10b2b2[_0x569157('0x1e')]!==_0x569157('0x50')&&(logger[_0x569157('0x1a')](_0x569157('0xb'),_0x569157('0x2c')),_0x2a9a60[_0x569157('0x4')]=util[_0x569157('0x31')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x2abf5b[_0x569157('0x6')],_0x2a9a60[_0x569157('0xa')],md5(_0x2a9a60[_0x569157('0xa')]))),getConnection(_0x2abf5b)['then'](function(_0xf01316){const _0x12a60c=_0x569157;return _0x18cb45=_0xf01316,getUser(_0x2abf5b,_0x3f3e3b[_0x12a60c('0x3a')],_0x18cb45);})[_0x569157('0x46')](function(_0x5e851c){const _0xb0093a=_0x569157;return _0x1689fd=_0x5e851c,logger['info'](_0xb0093a('0x53'),_0x1689fd['id']),getEndUser(_0x2abf5b,_0x2a9a60[_0xb0093a('0x2e')],_0x2a9a60[_0xb0093a('0x0')],_0x18cb45);})[_0x569157('0x46')](function(_0x581b77){const _0x331ec4=_0x569157;return _0x236b5f=_0x581b77,logger[_0x331ec4('0x1a')]('The\x20Enduser\x20ID\x20is:',_0x236b5f['id']),createTicket(_0x2abf5b,_0x1689fd,_0x236b5f,_0x130f1c,_0x2a9a60,_0x130f1c[_0x331ec4('0x32')],_0x18cb45);})[_0x569157('0x46')](function(_0x238481){const _0x45c0af=_0x569157;_0x12aca6=_0x238481,logger[_0x45c0af('0x1a')](_0x45c0af('0x2f')),logger[_0x45c0af('0x1a')](_0x45c0af('0x20'),_0x12aca6['id']);const _0x11e86a=util[_0x45c0af('0x31')](_0x45c0af('0x42'),_0x2abf5b[_0x45c0af('0x29')],_[_0x45c0af('0xd')](_0x12aca6['id'],'x')[0x1]);logger[_0x45c0af('0x1a')](_0x45c0af('0xb'),_0x45c0af('0x4b')),emit(util[_0x45c0af('0x31')](_0x45c0af('0x44'),_0x3f3e3b[_0x45c0af('0x37')]),'trigger:browser:url',{'uri':_0x11e86a});})[_0x569157('0x35')](function(_0x241cfb){const _0x189c4c=_0x569157;logger[_0x189c4c('0x40')](_0x189c4c('0xb'),JSON[_0x189c4c('0x16')](_0x241cfb));});},exports['unmanaged']=function(_0x22f191,_0x5990db,_0x744631,_0x4c60ad,_0x2a45fa,_0x154155){const _0x371bde=_0x348023;let _0x3205da,_0x2edf25,_0x40a20b,_0x517b79;return _0x154155[_0x371bde('0x29')]=intUtil[_0x371bde('0x47')](_0x154155['remoteUri']),_0x154155['serverUrl']=intUtil[_0x371bde('0x47')](_0x154155[_0x371bde('0x6')]),_0x2a45fa&&_0x2a45fa['monitor_format']?(logger[_0x371bde('0x1a')]('['+_0x5990db[_0x371bde('0x4a')][_0x371bde('0x52')]()+']',_0x371bde('0x2c')),_0x5990db[_0x371bde('0x4')]=util[_0x371bde('0x31')](_0x371bde('0x3f'),_0x154155[_0x371bde('0x6')],_0x5990db['uniqueid'],md5(_0x5990db[_0x371bde('0xa')]))):_0x5990db[_0x371bde('0x4')]='',getConnection(_0x154155)[_0x371bde('0x46')](function(_0x58a91e){return _0x517b79=_0x58a91e,getUser(_0x154155,'',_0x517b79);})[_0x371bde('0x46')](function(_0x59cde2){const _0x4a4d43=_0x371bde;return _0x3205da=_0x59cde2,logger['info']('The\x20User\x20ID\x20is:',_0x3205da['id']),getEndUser(_0x154155,_0x5990db[_0x4a4d43('0x33')],_0x5990db[_0x4a4d43('0x1')],_0x517b79);})['then'](function(_0x47a9b2){const _0x73a092=_0x371bde;return _0x2edf25=_0x47a9b2,logger[_0x73a092('0x1a')]('The\x20Enduser\x20ID\x20is:',_0x2edf25['id']),createTicket(_0x154155,_0x3205da,_0x2edf25,_0x744631,_0x5990db,_0x744631['Fields'],_0x517b79);})[_0x371bde('0x46')](function(_0x408793){const _0x2c203b=_0x371bde;_0x40a20b=_0x408793,logger[_0x2c203b('0x1a')]('Ticket\x20created!'),logger[_0x2c203b('0x1a')](_0x2c203b('0x20'),_0x40a20b['id']);})[_0x371bde('0x35')](function(_0x493624){const _0x29e712=_0x371bde;logger['error']('['+_0x5990db[_0x29e712('0x4a')][_0x29e712('0x52')]()+']',JSON[_0x29e712('0x16')](_0x493624));});}; \ No newline at end of file +const a1145_0x1d3c=['length','%s/index.php?module=HelpDesk&view=Detail&record=%s&app=SUPPORT','name','lodash','recordingURL','stringify','%s/webservice.php','destcalleridname','monitor_format','Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!','customVariable','error','username','../../../../rediscache','statusCode','The\x20User\x20ID\x20is:','create','phone','destcalleridnum','info','login','Normal','userId','idField','then','none','vTiger','The\x20Ticket\x20ID\x20is:','firstname','success','remoteUri','token','variableName','format','toString','uniqueid','Enduser\x20found!','string','sessionName','toUpperCase','recordingFormat','md5','[HTTP]','forEach','calleridnum','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','resolve','Open','[QUEUE]','util','SELECT\x20id,\x20firstname,\x20lastname,\x20email,\x20phone,\x20mobile,\x20homephone,\x20otherphone,\x20assistantphone\x20FROM\x20Contacts\x20WHERE\x20phone\x20=\x20\x27%s\x27\x20OR\x20mobile\x20=\x27%s\x27\x20OR\x20homephone\x20=\x27%s\x27\x20OR\x20otherphone\x20=\x27%s\x27\x20OR\x20assistantphone\x20=\x27%s\x27;','catch','Enduser\x20not\x20found,\x20creating\x20a\x20new\x20enduser!','query','Searching\x20end\x20user\x20with\x20phone','Ticket\x20created!','Ticket\x20could\x20not\x20be\x20created\x20due\x20to:\x20%s','calleridname','trigger:browser:url','serverUrl','Getting\x20agent\x20with\x20email','result','Fields','Variable','The\x20Enduser\x20ID\x20is:','HelpDesk','getchallenge','getUser','Account\x20%d\x20is\x20not\x20valid','type','validateEmail','Creating\x20new\x20ticket...','emit','last_name','stripTrailingSlash','accessKey','getEndUser','[vTiger],\x20%s,\x20%s,\x20%s','email1','getString','[OUTBOUND]','lastname','Contacts','../../../../config/logger','POST','variable','Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...','toLowerCase','split','Recording\x20is\x20enabled!','request-promise-native','admin','lastevent','GET','email','user:%s'];(function(_0x459642,_0x1d3c5a){const _0x1a7645=function(_0x4a3184){while(--_0x4a3184){_0x459642['push'](_0x459642['shift']());}};_0x1a7645(++_0x1d3c5a);}(a1145_0x1d3c,0x7d));const a1145_0x1a76=function(_0x459642,_0x1d3c5a){_0x459642=_0x459642-0x0;let _0x1a7645=a1145_0x1d3c[_0x459642];return _0x1a7645;};const _0x16eb5b=a1145_0x1a76;'use strict';const _=require(_0x16eb5b('0x46')),rp=require(_0x16eb5b('0x3d')),md5=require(_0x16eb5b('0xc')),util=require(_0x16eb5b('0x14')),intUtil=require('./util'),logger=require(_0x16eb5b('0x36'))(_0x16eb5b('0x5d')),{getSocket}=require(_0x16eb5b('0x50')),io=getSocket();function emit(_0x4a3184,_0x1699b6,_0x24a75b){const _0x3fc24b=_0x16eb5b;io['to'](_0x4a3184)[_0x3fc24b('0x2b')](_0x1699b6,_0x24a75b);}function getCustomFields(_0x5df59f,_0x3084ff){const _0x3c8797=_0x16eb5b,_0x449565={};return _0x5df59f['length']>0x0&&_[_0x3c8797('0xe')](_0x5df59f,function(_0x1efbd2){const _0x1c10c6=_0x3c8797;if(_0x1efbd2['type']===_0x1c10c6('0x8')&&_0x1efbd2[_0x1c10c6('0x5a')])_0x449565[_0x1efbd2[_0x1c10c6('0x5a')]]=_0x1efbd2['content'][_0x1c10c6('0x5')]();else{if(_0x1efbd2[_0x1c10c6('0x28')]===_0x1c10c6('0x38')&&_0x1efbd2[_0x1c10c6('0x3')]&&_0x1efbd2[_0x1c10c6('0x5a')]&&_0x3084ff[_0x1efbd2['variableName']])_0x449565[_0x1efbd2[_0x1c10c6('0x5a')]]=_0x3084ff[_0x1efbd2['variableName']]['toString']();else _0x1efbd2[_0x1c10c6('0x28')]===_0x1c10c6('0x4d')&&_0x1efbd2[_0x1c10c6('0x22')]&&_0x1efbd2[_0x1c10c6('0x22')][_0x1c10c6('0x45')]&&_0x1efbd2[_0x1c10c6('0x5a')]&&_0x3084ff[_0x1efbd2[_0x1c10c6('0x22')][_0x1c10c6('0x45')][_0x1c10c6('0x3a')]()]&&(_0x449565[_0x1efbd2[_0x1c10c6('0x5a')]]=_0x3084ff[_0x1efbd2[_0x1c10c6('0x22')][_0x1c10c6('0x45')]['toLowerCase']()][_0x1c10c6('0x5')]());}}),_0x449565;}function createTicket(_0x19ebfd,_0x14e8ff,_0x358906,_0x2f06a9,_0x528008,_0xae476,_0x4253ea){const _0x369c25=_0x16eb5b;logger[_0x369c25('0x56')](_0x369c25('0x2a'));const _0x2278b1=_['merge']({'parent_id':'','assigned_user_id':_0x14e8ff['id'],'ticketpriorities':_0x369c25('0x58'),'ticketstatus':_0x369c25('0x12'),'ticket_title':intUtil[_0x369c25('0x32')](_0x2f06a9['Subjects'],_0x528008,'\x20'),'description':intUtil['getString'](_0x2f06a9['Descriptions'],_0x528008,'\x0a'),'contact_id':_0x358906['id']},getCustomFields(_0xae476,_0x528008)),_0x239187={'method':'POST','uri':util[_0x369c25('0x4')](_0x369c25('0x49'),_0x19ebfd[_0x369c25('0x1')]),'form':{'operation':_0x369c25('0x53'),'username':_0x19ebfd[_0x369c25('0x4f')],'sessionName':_0x4253ea[_0x369c25('0x9')],'elementType':_0x369c25('0x24'),'element':JSON[_0x369c25('0x48')](_0x2278b1)},'json':!![]};return request(_0x239187)[_0x369c25('0x5b')](function(_0x138f7f){const _0x21cb13=_0x369c25;if(_0x138f7f[_0x21cb13('0x0')])return Promise['resolve']({'id':_0x138f7f[_0x21cb13('0x20')]['id']});else throw new Error(util[_0x21cb13('0x4')](_0x21cb13('0x1b'),JSON[_0x21cb13('0x48')](_0x138f7f[_0x21cb13('0x4e')])));})[_0x369c25('0x16')](function(_0x2c50c3){const _0x58c809=_0x369c25,_0x59f7d5=_0x2c50c3['statusCode']||0x1f4;logger[_0x58c809('0x4e')](_0x58c809('0x30'),'createTicket',_0x59f7d5,JSON[_0x58c809('0x48')](_0x2c50c3));});}function getUser(_0x1f1c7a,_0x304bbb,_0x1f4263){const _0x3b7208=_0x16eb5b;return intUtil[_0x3b7208('0x29')](_0x304bbb)?(logger[_0x3b7208('0x56')](_0x3b7208('0x1f'),_0x304bbb),request({'method':_0x3b7208('0x40'),'uri':util[_0x3b7208('0x4')]('%s/webservice.php',_0x1f1c7a[_0x3b7208('0x1')]),'qs':{'operation':_0x3b7208('0x18'),'username':_0x1f1c7a[_0x3b7208('0x4f')],'sessionName':_0x1f4263[_0x3b7208('0x9')],'query':util[_0x3b7208('0x4')]('SELECT\x20first_name,\x20last_name,\x20email1\x20FROM\x20Users\x20WHERE\x20email1=\x27%s\x27;',_0x304bbb)},'json':!![]})[_0x3b7208('0x5b')](function(_0x48459a){const _0x439c4c=_0x3b7208;return _0x48459a['success']&&_0x48459a[_0x439c4c('0x20')][_0x439c4c('0x43')]?(logger[_0x439c4c('0x56')]('Agent\x20found!'),Promise[_0x439c4c('0x11')]({'id':_0x48459a[_0x439c4c('0x20')][0x0]['id'],'email':_0x48459a['result'][0x0][_0x439c4c('0x31')],'name':_0x48459a[_0x439c4c('0x20')][0x0]['first_name']+'\x20'+_0x48459a[_0x439c4c('0x20')][_0x439c4c('0x2c')]})):(logger[_0x439c4c('0x56')](_0x439c4c('0x4c')),Promise[_0x439c4c('0x11')]({'id':_0x1f4263[_0x439c4c('0x59')],'email':_0x1f1c7a[_0x439c4c('0x4f')],'name':_0x439c4c('0x3e')}));})[_0x3b7208('0x16')](function(_0x5b7bc4){const _0x1994ea=_0x3b7208,_0x3c9333=_0x5b7bc4[_0x1994ea('0x51')]||0x1f4;logger['error'](_0x1994ea('0x30'),_0x1994ea('0x26'),_0x3c9333,JSON[_0x1994ea('0x48')](_0x5b7bc4));})):(logger['info'](_0x3b7208('0x4c')),Promise[_0x3b7208('0x11')]({'id':_0x1f4263[_0x3b7208('0x59')],'email':_0x1f1c7a[_0x3b7208('0x4f')],'name':_0x3b7208('0x3e')})[_0x3b7208('0x16')](function(_0x203bf6){const _0x510dd8=_0x3b7208,_0x6160a2=_0x203bf6[_0x510dd8('0x51')]||0x1f4;logger[_0x510dd8('0x4e')]('[vTiger],\x20%s,\x20%s,\x20%s',_0x510dd8('0x26'),_0x6160a2,JSON[_0x510dd8('0x48')](_0x203bf6));}));}function getEndUser(_0x56d12f,_0x422fd7,_0x59713e,_0x17c684){const _0x581896=_0x16eb5b;return logger[_0x581896('0x56')](_0x581896('0x19'),_0x59713e),request({'method':'GET','uri':util['format'](_0x581896('0x49'),_0x56d12f['remoteUri']),'qs':{'operation':_0x581896('0x18'),'username':_0x56d12f[_0x581896('0x4f')],'sessionName':_0x17c684[_0x581896('0x9')],'query':util[_0x581896('0x4')](_0x581896('0x15'),_0x59713e,_0x59713e,_0x59713e,_0x59713e,_0x59713e)},'json':!![]})[_0x581896('0x5b')](function(_0x2b1bd5){const _0x403740=_0x581896;return _0x2b1bd5[_0x403740('0x0')]&&_0x2b1bd5[_0x403740('0x20')][_0x403740('0x43')]?(logger[_0x403740('0x56')](_0x403740('0x7')),Promise[_0x403740('0x11')]({'id':_0x2b1bd5[_0x403740('0x20')][0x0]['id'],'name':_0x2b1bd5[_0x403740('0x20')][0x0][_0x403740('0x5f')]+'\x20'+_0x2b1bd5['result'][0x0][_0x403740('0x34')],'phone':_0x59713e})):(logger[_0x403740('0x56')](_0x403740('0x17')),request({'method':_0x403740('0x37'),'uri':util[_0x403740('0x4')](_0x403740('0x49'),_0x56d12f['remoteUri']),'form':{'operation':_0x403740('0x53'),'sessionName':_0x17c684['sessionName'],'elementType':_0x403740('0x35'),'element':JSON[_0x403740('0x48')]({'lastname':_0x422fd7,'phone':_0x59713e,'assigned_user_id':'\x20'})},'json':!![]})[_0x403740('0x5b')](function(_0x518b8f){const _0x34ad3f=_0x403740;return logger[_0x34ad3f('0x56')]('Enduser\x20created.'),Promise[_0x34ad3f('0x11')]({'id':_0x518b8f[_0x34ad3f('0x20')]['id'],'name':_0x518b8f[_0x34ad3f('0x20')]['lastname'],'phone':_0x518b8f[_0x34ad3f('0x20')][_0x34ad3f('0x54')]});})[_0x403740('0x16')](function(_0x5cb136){const _0xddc6b3=_0x403740,_0xb4fcec=_0x5cb136[_0xddc6b3('0x51')]||0x1f4;logger[_0xddc6b3('0x4e')](_0xddc6b3('0x30'),_0xddc6b3('0x2f'),_0xb4fcec,JSON[_0xddc6b3('0x48')](_0x5cb136));}));});}function getConnection(_0x600e52){const _0x42897c=_0x16eb5b,_0x4f5bb1=_0x600e52[_0x42897c('0x4f')],_0x2d19f0=_0x600e52[_0x42897c('0x2e')];return request({'method':_0x42897c('0x40'),'uri':util['format'](_0x42897c('0x49'),_0x600e52[_0x42897c('0x1')]),'qs':{'operation':_0x42897c('0x25'),'username':_0x4f5bb1},'json':!![]})[_0x42897c('0x5b')](function(_0x2cf053){const _0x209a32=_0x42897c;if(_0x2cf053[_0x209a32('0x0')])return request({'method':_0x209a32('0x37'),'uri':util['format'](_0x209a32('0x49'),_0x600e52['remoteUri']),'form':{'operation':_0x209a32('0x57'),'username':_0x4f5bb1,'accessKey':md5(_0x2cf053[_0x209a32('0x20')][_0x209a32('0x2')]+_0x2d19f0)},'json':!![]});})['then'](function(_0x2ab718){const _0x1f0274=_0x42897c;if(_0x2ab718[_0x1f0274('0x0')])return Promise[_0x1f0274('0x11')](_0x2ab718[_0x1f0274('0x20')]);else throw new Error(util[_0x1f0274('0x4')](_0x1f0274('0x27'),_0x600e52['id']));})[_0x42897c('0x16')](function(_0x5e3da2){const _0x1797e0=_0x42897c,_0x2ac724=_0x5e3da2[_0x1797e0('0x51')]||0x1f4;logger[_0x1797e0('0x4e')](_0x1797e0('0x30'),'getConnection',_0x2ac724,JSON['stringify'](_0x5e3da2));});}function request(_0x25a6af){const _0x4d9305=_0x16eb5b;return logger[_0x4d9305('0x56')](_0x4d9305('0xd'),JSON[_0x4d9305('0x48')](_0x25a6af)),rp(_0x25a6af);}exports['queue']=function(_0x426a13,_0x480c20,_0x269cad,_0x3cffb4,_0x5df505,_0x4e2cc7){const _0xd66d39=_0x16eb5b;let _0x595e17,_0x26743e,_0x5afb54,_0x921054;return _0x4e2cc7[_0xd66d39('0x1')]=intUtil[_0xd66d39('0x2d')](_0x4e2cc7[_0xd66d39('0x1')]),_0x5df505&&_0x5df505[_0xd66d39('0x4b')]?(logger[_0xd66d39('0x56')]('[QUEUE]','Recording\x20is\x20enabled!'),_0x480c20[_0xd66d39('0x47')]=util[_0xd66d39('0x4')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x4e2cc7[_0xd66d39('0x1e')],_0x480c20[_0xd66d39('0x6')],md5(_0x480c20['uniqueid']))):_0x480c20[_0xd66d39('0x47')]='',getConnection(_0x4e2cc7)[_0xd66d39('0x5b')](function(_0x2ab4f9){const _0x3c59ef=_0xd66d39;return _0x921054=_0x2ab4f9,getUser(_0x4e2cc7,_0x3cffb4[_0x3c59ef('0x41')],_0x921054);})[_0xd66d39('0x5b')](function(_0x54488a){const _0x248466=_0xd66d39;return _0x595e17=_0x54488a,logger[_0x248466('0x56')](_0x248466('0x52'),_0x595e17['id']),getEndUser(_0x4e2cc7,_0x480c20[_0x248466('0x1c')],_0x480c20['calleridnum'],_0x921054);})[_0xd66d39('0x5b')](function(_0x480b3b){const _0x39368b=_0xd66d39;return _0x26743e=_0x480b3b,logger[_0x39368b('0x56')](_0x39368b('0x23'),_0x26743e['id']),createTicket(_0x4e2cc7,_0x595e17,_0x26743e,_0x269cad,_0x480c20,_0x269cad['Fields'],_0x921054);})[_0xd66d39('0x5b')](function(_0x9061ce){const _0x30556c=_0xd66d39;_0x5afb54=_0x9061ce,logger[_0x30556c('0x56')](_0x30556c('0x1a')),logger[_0x30556c('0x56')](_0x30556c('0x5e'),_0x5afb54['id']);const _0x55ae65=util[_0x30556c('0x4')]('%s/index.php?module=HelpDesk&view=Detail&record=%s&app=SUPPORT',_0x4e2cc7[_0x30556c('0x1')],_['split'](_0x5afb54['id'],'x')[0x1]);logger[_0x30556c('0x56')](_0x30556c('0x13'),_0x30556c('0x39')),emit(util[_0x30556c('0x4')](_0x30556c('0x42'),_0x3cffb4[_0x30556c('0x45')]),_0x30556c('0x1d'),{'uri':_0x55ae65});})['catch'](function(_0x246b71){const _0x3b0462=_0xd66d39;logger[_0x3b0462('0x4e')](_0x3b0462('0x13'),JSON[_0x3b0462('0x48')](_0x246b71));});},exports['outbound']=function(_0x49d090,_0x51e193,_0x1e2508,_0x30d4e7,_0x1439d3,_0x2c241d,_0x19c19b){const _0x4fe789=_0x16eb5b;let _0x514b37,_0x1b04b4,_0x4d1058,_0x4eab87;return _0x2c241d['remoteUri']=intUtil[_0x4fe789('0x2d')](_0x2c241d['remoteUri']),_0x2c241d[_0x4fe789('0x1e')]=intUtil[_0x4fe789('0x2d')](_0x2c241d[_0x4fe789('0x1e')]),_0x19c19b&&_0x19c19b[_0x4fe789('0xb')]&&_0x19c19b[_0x4fe789('0xb')]!==_0x4fe789('0x5c')&&(logger['info'](_0x4fe789('0x33'),_0x4fe789('0x3c')),_0x51e193[_0x4fe789('0x47')]=util['format'](_0x4fe789('0x10'),_0x2c241d[_0x4fe789('0x1e')],_0x51e193[_0x4fe789('0x6')],md5(_0x51e193['uniqueid']))),getConnection(_0x2c241d)['then'](function(_0x4844ad){return _0x4eab87=_0x4844ad,getUser(_0x2c241d,_0x30d4e7['email'],_0x4eab87);})[_0x4fe789('0x5b')](function(_0x417f0a){const _0x23f2a1=_0x4fe789;return _0x514b37=_0x417f0a,logger[_0x23f2a1('0x56')]('The\x20User\x20ID\x20is:',_0x514b37['id']),getEndUser(_0x2c241d,_0x51e193[_0x23f2a1('0x4a')],_0x51e193[_0x23f2a1('0x55')],_0x4eab87);})[_0x4fe789('0x5b')](function(_0x4cb27b){const _0x5e4acd=_0x4fe789;return _0x1b04b4=_0x4cb27b,logger[_0x5e4acd('0x56')](_0x5e4acd('0x23'),_0x1b04b4['id']),createTicket(_0x2c241d,_0x514b37,_0x1b04b4,_0x1e2508,_0x51e193,_0x1e2508[_0x5e4acd('0x21')],_0x4eab87);})[_0x4fe789('0x5b')](function(_0x5a93d4){const _0x71a588=_0x4fe789;_0x4d1058=_0x5a93d4,logger[_0x71a588('0x56')](_0x71a588('0x1a')),logger[_0x71a588('0x56')]('The\x20Ticket\x20ID\x20is:',_0x4d1058['id']);const _0x5614ee=util[_0x71a588('0x4')](_0x71a588('0x44'),_0x2c241d['remoteUri'],_[_0x71a588('0x3b')](_0x4d1058['id'],'x')[0x1]);logger['info'](_0x71a588('0x33'),_0x71a588('0x39')),emit(util[_0x71a588('0x4')](_0x71a588('0x42'),_0x30d4e7[_0x71a588('0x45')]),'trigger:browser:url',{'uri':_0x5614ee});})[_0x4fe789('0x16')](function(_0xb11db8){const _0x5b13f3=_0x4fe789;logger['error'](_0x5b13f3('0x33'),JSON['stringify'](_0xb11db8));});},exports['unmanaged']=function(_0xa8f9a7,_0x289f4d,_0x5bc173,_0x19eeba,_0x172c6c,_0x1e8a41){const _0x22b034=_0x16eb5b;let _0x4b3b92,_0x52d00b,_0x14f564,_0x3af8cd;return _0x1e8a41[_0x22b034('0x1')]=intUtil[_0x22b034('0x2d')](_0x1e8a41[_0x22b034('0x1')]),_0x1e8a41[_0x22b034('0x1e')]=intUtil[_0x22b034('0x2d')](_0x1e8a41[_0x22b034('0x1e')]),_0x172c6c&&_0x172c6c[_0x22b034('0x4b')]?(logger[_0x22b034('0x56')]('['+_0x289f4d[_0x22b034('0x3f')]['toUpperCase']()+']',_0x22b034('0x3c')),_0x289f4d['recordingURL']=util[_0x22b034('0x4')](_0x22b034('0x10'),_0x1e8a41[_0x22b034('0x1e')],_0x289f4d[_0x22b034('0x6')],md5(_0x289f4d[_0x22b034('0x6')]))):_0x289f4d['recordingURL']='',getConnection(_0x1e8a41)[_0x22b034('0x5b')](function(_0x1ab53d){return _0x3af8cd=_0x1ab53d,getUser(_0x1e8a41,'',_0x3af8cd);})['then'](function(_0x1f544d){const _0x5a12ad=_0x22b034;return _0x4b3b92=_0x1f544d,logger[_0x5a12ad('0x56')]('The\x20User\x20ID\x20is:',_0x4b3b92['id']),getEndUser(_0x1e8a41,_0x289f4d[_0x5a12ad('0x1c')],_0x289f4d[_0x5a12ad('0xf')],_0x3af8cd);})['then'](function(_0x26fb42){const _0x3f4666=_0x22b034;return _0x52d00b=_0x26fb42,logger['info'](_0x3f4666('0x23'),_0x52d00b['id']),createTicket(_0x1e8a41,_0x4b3b92,_0x52d00b,_0x5bc173,_0x289f4d,_0x5bc173['Fields'],_0x3af8cd);})[_0x22b034('0x5b')](function(_0xd7511e){const _0x55c3e7=_0x22b034;_0x14f564=_0xd7511e,logger['info'](_0x55c3e7('0x1a')),logger[_0x55c3e7('0x56')](_0x55c3e7('0x5e'),_0x14f564['id']);})[_0x22b034('0x16')](function(_0x58a1a4){const _0x4400e2=_0x22b034;logger[_0x4400e2('0x4e')]('['+_0x289f4d[_0x4400e2('0x3f')][_0x4400e2('0xa')]()+']',JSON['stringify'](_0x58a1a4));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/zendesk.js b/server/services/ami/trigger/integration/zendesk.js index 9ad979d..02a9285 100644 --- a/server/services/ami/trigger/integration/zendesk.js +++ b/server/services/ami/trigger/integration/zendesk.js @@ -1 +1 @@ -const a1146_0x25ef=['integrationTab','getString','%s/users/me.json','toUpperCase','%s/channels/voice/agents/%d/tickets/%d/display.json','[QUEUE]','Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!','util','Tags','destcalleridnum','nameField','Subjects','calleridnum','trigger:browser:url','%s/agent/tickets/%s','error','Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...','calleridname','remoteUri','password','agent','Variable','validateEmail','from','push','Getting\x20agent\x20with\x20email','base64','defaults','then','Admin\x20account\x20selected.','Fields','Recording\x20is\x20enabled!','token','catch','stripTrailingSlash','recordingFormat','content','results','zendesk','lastevent','debug','count','recordingURL','info','[OUTBOUND]\x20Error\x20running\x20Zendesk\x20integration','outbound','string','unmanaged','none','monitor_format','queue','The\x20User\x20ID\x20is:','emit','length','application/json','filter','%s/users.json','user','Authorization','[QUEUE]\x20Error\x20running\x20Zendesk\x20integration','Zendesk\x20account\x20type\x20not\x20recognized','uniqueid','idField','The\x20Enduser\x20ID\x20is:','../../../../config/logger','custom_fields','serverUrl','\x20Error\x20running\x20Zendesk\x20integration','merge','inspect','variable','ticket','GET','newTab','Descriptions','Creating\x20new\x20ticket...','variableName','user:%s','toString','The\x20Ticket\x20ID\x20is:','/api/v2','authType','customField','username','%s/search.json','Displaying\x20ticket\x20to\x20agent...','end-user','Enduser\x20found!','POST','Agent\x20found!','first','Searching\x20enduser\x20with\x20phone','md5','[HTTP]','Basic\x20%s','[OUTBOUND]','type','format','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','replace','email','toLowerCase','request-promise-native','name','find'];(function(_0x2c14d3,_0x25ef51){const _0x295085=function(_0xbe8da8){while(--_0xbe8da8){_0x2c14d3['push'](_0x2c14d3['shift']());}};_0x295085(++_0x25ef51);}(a1146_0x25ef,0xcc));const a1146_0x2950=function(_0x2c14d3,_0x25ef51){_0x2c14d3=_0x2c14d3-0x0;let _0x295085=a1146_0x25ef[_0x2c14d3];return _0x295085;};const _0x5afe55=a1146_0x2950;'use strict';const _=require('lodash'),rp=require(_0x5afe55('0x3')),md5=require(_0x5afe55('0x62')),util=require(_0x5afe55('0xd')),intUtil=require('./util'),logger=require(_0x5afe55('0x46'))(_0x5afe55('0x2c')),{getSocket}=require('../../../../rediscache'),io=getSocket();function emit(_0xbe8da8,_0x34bf02,_0xe35936){const _0x27e3fa=_0x5afe55;io['to'](_0xbe8da8)[_0x27e3fa('0x3a')](_0x34bf02,_0xe35936);}const headers={'Content-Type':_0x5afe55('0x3c'),'Accept':_0x5afe55('0x3c')};function getTicket(_0x237fc8,_0x154d0e,_0x329c59,_0x382204,_0x5de871){const _0x5302a1=_0x5afe55;return logger[_0x5302a1('0x31')](_0x5302a1('0x51')),request({'uri':util[_0x5302a1('0x67')]('%s/tickets.json',_0x237fc8[_0x5302a1('0x18')]),'method':'POST','body':{'ticket':_[_0x5302a1('0x4a')]({'requester_id':_0x329c59['id'],'submitter_id':_0x154d0e?_0x154d0e['id']:undefined,'assignee_id':_0x154d0e?_0x154d0e['id']:undefined,'tags':getTags(_0x382204[_0x5302a1('0xe')],_0x5302a1('0x4')),'subject':intUtil[_0x5302a1('0x7')](_0x382204[_0x5302a1('0x11')],_0x5de871,'\x20'),'description':intUtil[_0x5302a1('0x7')](_0x382204['Descriptions'],_0x5de871,'\x0a'),'comment':{'public':![],'body':intUtil['getString'](_0x382204[_0x5302a1('0x50')],_0x5de871,'\x0a')}},getCustomFields(_0x382204[_0x5302a1('0x24')],_0x5de871))}})['then'](function(_0x4c158a){const _0x369e8c=_0x5302a1;return logger[_0x369e8c('0x31')]('Ticket\x20created!'),_0x4c158a[_0x369e8c('0x4d')];});}function getUser(_0x125354,_0x2050a9){const _0x5c81bf=_0x5afe55;return intUtil[_0x5c81bf('0x1c')](_0x2050a9)?(logger['info'](_0x5c81bf('0x1f'),_0x2050a9),request({'uri':util[_0x5c81bf('0x67')]('%s/search.json',_0x125354['remoteUri']),'qs':{'query':util[_0x5c81bf('0x67')]('type:user\x20role:agent\x20email:%s',_0x2050a9)}})['then'](function(_0x5d1fe8){const _0x117295=_0x5c81bf;return _0x5d1fe8[_0x117295('0x2f')]?(logger[_0x117295('0x31')](_0x117295('0x5f')),_[_0x117295('0x5')](_0x5d1fe8[_0x117295('0x2b')],{'email':_0x2050a9,'role':_0x117295('0x1a')})):(logger['info'](_0x117295('0xc')),request({'uri':util['format'](_0x117295('0x8'),_0x125354[_0x117295('0x18')])})[_0x117295('0x22')](function(_0x27fc7e){const _0x3f6ca5=_0x117295;return logger[_0x3f6ca5('0x31')](_0x3f6ca5('0x23')),_0x27fc7e['user'];}));})):(logger[_0x5c81bf('0x31')]('Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!'),request({'uri':util[_0x5c81bf('0x67')](_0x5c81bf('0x8'),_0x125354[_0x5c81bf('0x18')])})[_0x5c81bf('0x22')](function(_0x1ff94a){const _0x219f5c=_0x5c81bf;return logger[_0x219f5c('0x31')](_0x219f5c('0x23')),_0x1ff94a[_0x219f5c('0x3f')];}));}function getEndUser(_0xca5dae,_0x35bfac,_0x47d0aa){const _0x48fb4c=_0x5afe55;return logger[_0x48fb4c('0x31')](_0x48fb4c('0x61'),_0x47d0aa),request({'uri':util['format'](_0x48fb4c('0x5a'),_0xca5dae[_0x48fb4c('0x18')]),'qs':{'query':util[_0x48fb4c('0x67')]('type:user\x20role:end-user\x20phone:%s',_0x47d0aa)}})[_0x48fb4c('0x22')](function(_0x3f974d){const _0x4a7113=_0x48fb4c;let _0x549f74;return _0x3f974d[_0x4a7113('0x2b')][_0x4a7113('0x3b')]&&(_0x3f974d['results']=_[_0x4a7113('0x3d')](_0x3f974d[_0x4a7113('0x2b')],{'suspended':![],'role':_0x4a7113('0x5c')}),_0x3f974d[_0x4a7113('0x2b')][_0x4a7113('0x3b')]&&(_0x549f74=_[_0x4a7113('0x60')](_0x3f974d[_0x4a7113('0x2b')]))),_0x549f74?(logger[_0x4a7113('0x31')](_0x4a7113('0x5d')),_0x549f74):(logger[_0x4a7113('0x31')]('Enduser\x20not\x20found,\x20creating\x20a\x20new\x20enduser!'),request({'uri':util['format'](_0x4a7113('0x3e'),_0xca5dae['remoteUri']),'method':_0x4a7113('0x5e'),'body':{'user':{'role':_0x4a7113('0x5c'),'name':util[_0x4a7113('0x67')]('Caller\x20-\x20%s',_0x35bfac||_0x47d0aa),'phone':_0x47d0aa}}})[_0x4a7113('0x22')](function(_0x4628e6){const _0x239a45=_0x4a7113;return logger[_0x239a45('0x31')]('Enduser\x20created.'),_0x4628e6[_0x239a45('0x3f')];}));});}function getAuth(_0x44d427){const _0x143d7c=_0x5afe55;let _0x49a1e8;if(_0x44d427[_0x143d7c('0x57')]===_0x143d7c('0x19'))_0x49a1e8=util[_0x143d7c('0x67')]('%s:%s',_0x44d427['username'],_0x44d427[_0x143d7c('0x19')]);else _0x44d427[_0x143d7c('0x57')]==='token'&&(_0x49a1e8=util[_0x143d7c('0x67')]('%s/token:%s',_0x44d427[_0x143d7c('0x59')],_0x44d427[_0x143d7c('0x26')]));return util['format'](_0x143d7c('0x64'),Buffer[_0x143d7c('0x1d')](_0x49a1e8)[_0x143d7c('0x54')](_0x143d7c('0x20')));}function request(_0x35c3f9){const _0x2d26a8=_0x5afe55;return logger[_0x2d26a8('0x2e')](_0x2d26a8('0x63'),JSON['stringify'](_0x35c3f9)),rp(_[_0x2d26a8('0x21')](_0x35c3f9,{'method':_0x2d26a8('0x4e'),'headers':headers,'json':!![]}));}function getTags(_0x19957c,_0x3fe580){const _0x1f0ea7=_0x5afe55;let _0x23a58b=[];return _0x19957c&&_0x19957c[_0x1f0ea7('0x3b')]>0x0&&(_0x23a58b=_['map'](_0x19957c,_0x3fe580)),_0x23a58b;}function getCustomFields(_0x9ee298,_0x3245fe){const _0x147bb3=_0x5afe55,_0x38efcc={'custom_fields':[]};return _0x9ee298[_0x147bb3('0x3b')]>0x0&&_['forEach'](_0x9ee298,function(_0x1672d4){const _0x4830dd=_0x147bb3;if(_0x1672d4[_0x4830dd('0x66')]===_0x4830dd('0x34')&&_0x1672d4[_0x4830dd('0x10')]&&!_0x1672d4['customField'])_0x38efcc[_0x1672d4['nameField'][_0x4830dd('0x2')]()]=_0x1672d4['content'][_0x4830dd('0x54')]();else{if(_0x1672d4[_0x4830dd('0x66')]==='string'&&_0x1672d4['idField']&&_0x1672d4[_0x4830dd('0x58')])_0x38efcc['custom_fields'][_0x4830dd('0x1e')]({'id':_0x1672d4[_0x4830dd('0x44')],'value':_0x1672d4[_0x4830dd('0x2a')][_0x4830dd('0x54')]()});else{if(_0x1672d4[_0x4830dd('0x66')]===_0x4830dd('0x4c')&&_0x1672d4[_0x4830dd('0x52')]&&_0x1672d4['idField']&&_0x1672d4[_0x4830dd('0x58')])_0x3245fe[_0x1672d4['variableName']]&&_0x38efcc[_0x4830dd('0x47')][_0x4830dd('0x1e')]({'id':_0x1672d4[_0x4830dd('0x44')],'value':_0x3245fe[_0x1672d4[_0x4830dd('0x52')]][_0x4830dd('0x54')]()});else _0x1672d4[_0x4830dd('0x66')]==='customVariable'&&_0x1672d4[_0x4830dd('0x1b')]&&_0x1672d4['Variable']['name']&&_0x1672d4[_0x4830dd('0x44')]&&_0x1672d4[_0x4830dd('0x58')]&&(_0x3245fe[_0x1672d4[_0x4830dd('0x1b')][_0x4830dd('0x4')][_0x4830dd('0x2')]()]&&_0x38efcc[_0x4830dd('0x47')][_0x4830dd('0x1e')]({'id':_0x1672d4[_0x4830dd('0x44')],'value':_0x3245fe[_0x1672d4['Variable'][_0x4830dd('0x4')][_0x4830dd('0x2')]()][_0x4830dd('0x54')]()}));}}}),_0x38efcc;}exports[_0x5afe55('0x38')]=function(_0x5a2837,_0x42f6d8,_0x584fee,_0x4ec274,_0x55265d,_0x1990cc){const _0x1d3fd6=_0x5afe55;let _0x261ad2,_0x4565e9;return _0x1990cc[_0x1d3fd6('0x18')]=intUtil[_0x1d3fd6('0x28')](_0x1990cc[_0x1d3fd6('0x18')]),_0x1990cc[_0x1d3fd6('0x48')]=intUtil[_0x1d3fd6('0x28')](_0x1990cc[_0x1d3fd6('0x48')]),_0x55265d&&_0x55265d[_0x1d3fd6('0x37')]?(logger[_0x1d3fd6('0x31')](_0x1d3fd6('0xb'),_0x1d3fd6('0x25')),_0x42f6d8['recordingURL']=util[_0x1d3fd6('0x67')](_0x1d3fd6('0x68'),_0x1990cc[_0x1d3fd6('0x48')],_0x42f6d8[_0x1d3fd6('0x43')],md5(_0x42f6d8[_0x1d3fd6('0x43')]))):_0x42f6d8[_0x1d3fd6('0x30')]='',headers['Authorization']=getAuth(_0x1990cc),getUser(_0x1990cc,_0x4ec274['email'])[_0x1d3fd6('0x22')](function(_0x2b36ff){const _0x5e9645=_0x1d3fd6;return _0x261ad2=_0x2b36ff,logger[_0x5e9645('0x31')]('The\x20User\x20ID\x20is:',_0x261ad2['id']),getEndUser(_0x1990cc,_0x42f6d8[_0x5e9645('0x17')],_0x42f6d8[_0x5e9645('0x12')]);})[_0x1d3fd6('0x22')](function(_0x3461b3){const _0x515d3f=_0x1d3fd6;return _0x4565e9=_0x3461b3,logger[_0x515d3f('0x31')]('The\x20Enduser\x20ID\x20is:',_0x4565e9['id']),getTicket(_0x1990cc,_0x261ad2,_0x4565e9,_0x584fee,_0x42f6d8);})[_0x1d3fd6('0x22')](function(_0x4e76a0){const _0x2ed99e=_0x1d3fd6;if(_0x4e76a0){logger[_0x2ed99e('0x31')](_0x2ed99e('0x55'),_0x4e76a0['id']);switch(_0x1990cc[_0x2ed99e('0x66')]){case _0x2ed99e('0x6'):logger[_0x2ed99e('0x31')](_0x2ed99e('0xb'),_0x2ed99e('0x5b'));return request({'uri':util['format'](_0x2ed99e('0xa'),_0x1990cc[_0x2ed99e('0x18')],_0x261ad2['id'],_0x4e76a0['id']),'method':'POST'});case _0x2ed99e('0x4f'):logger['info'](_0x2ed99e('0xb'),_0x2ed99e('0x16')),emit(util['format'](_0x2ed99e('0x53'),_0x4ec274[_0x2ed99e('0x4')]),_0x2ed99e('0x13'),{'uri':util[_0x2ed99e('0x67')](_0x2ed99e('0x14'),_0x1990cc[_0x2ed99e('0x18')]['replace'](_0x2ed99e('0x56')),_0x4e76a0['id'])});break;default:logger[_0x2ed99e('0x15')](_0x2ed99e('0xb'),_0x2ed99e('0x42'));}}})['catch'](function(_0x59751c){const _0x595a0b=_0x1d3fd6;logger[_0x595a0b('0x15')](_0x595a0b('0x41'),util[_0x595a0b('0x4b')](_0x59751c,{'showHidden':!![],'depth':null}));});},exports[_0x5afe55('0x33')]=function(_0x5d69d9,_0x3cbf0f,_0x4f97c5,_0x13177b,_0x5b3e2c,_0x1c435a,_0x55a1da){const _0x1143df=_0x5afe55;let _0x3ab8d3,_0x320db8;return _0x1c435a[_0x1143df('0x18')]=intUtil[_0x1143df('0x28')](_0x1c435a[_0x1143df('0x18')]),_0x1c435a[_0x1143df('0x48')]=intUtil[_0x1143df('0x28')](_0x1c435a[_0x1143df('0x48')]),_0x55a1da&&_0x55a1da[_0x1143df('0x29')]&&_0x55a1da[_0x1143df('0x29')]!==_0x1143df('0x36')&&(logger[_0x1143df('0x31')]('[OUTBOUND]',_0x1143df('0x25')),_0x3cbf0f[_0x1143df('0x30')]=util[_0x1143df('0x67')](_0x1143df('0x68'),_0x1c435a['serverUrl'],_0x3cbf0f[_0x1143df('0x43')],md5(_0x3cbf0f[_0x1143df('0x43')]))),headers[_0x1143df('0x40')]=getAuth(_0x1c435a),getUser(_0x1c435a,_0x13177b[_0x1143df('0x1')])[_0x1143df('0x22')](function(_0x310f29){const _0x327625=_0x1143df;return _0x3ab8d3=_0x310f29,logger[_0x327625('0x31')](_0x327625('0x39'),_0x3ab8d3['id']),getEndUser(_0x1c435a,_0x3cbf0f['destcalleridname'],_0x3cbf0f[_0x327625('0xf')]);})[_0x1143df('0x22')](function(_0x35619f){const _0x5108aa=_0x1143df;return _0x320db8=_0x35619f,logger[_0x5108aa('0x31')](_0x5108aa('0x45'),_0x320db8['id']),getTicket(_0x1c435a,_0x3ab8d3,_0x320db8,_0x4f97c5,_0x3cbf0f);})[_0x1143df('0x22')](function(_0x47baf9){const _0x5008f1=_0x1143df;if(_0x47baf9){logger['info'](_0x5008f1('0x55'),_0x47baf9['id']);switch(_0x1c435a[_0x5008f1('0x66')]){case _0x5008f1('0x6'):logger[_0x5008f1('0x31')](_0x5008f1('0x65'),_0x5008f1('0x5b'));return request({'uri':util['format'](_0x5008f1('0xa'),_0x1c435a[_0x5008f1('0x18')],_0x3ab8d3['id'],_0x47baf9['id']),'method':_0x5008f1('0x5e')});case _0x5008f1('0x4f'):logger[_0x5008f1('0x31')](_0x5008f1('0x65'),_0x5008f1('0x16')),emit(util[_0x5008f1('0x67')](_0x5008f1('0x53'),_0x13177b['name']),_0x5008f1('0x13'),{'uri':util[_0x5008f1('0x67')]('%s/agent/tickets/%s',_0x1c435a[_0x5008f1('0x18')][_0x5008f1('0x0')](_0x5008f1('0x56')),_0x47baf9['id'])});break;default:logger[_0x5008f1('0x15')](_0x5008f1('0x65'),_0x5008f1('0x42'));}}})['catch'](function(_0x25245f){const _0x403a4a=_0x1143df;logger[_0x403a4a('0x15')](_0x403a4a('0x32'),util[_0x403a4a('0x4b')](_0x25245f,{'showHidden':!![],'depth':null}));});},exports[_0x5afe55('0x35')]=function(_0x59b169,_0x138871,_0x41f936,_0x3abe5a,_0x42868e,_0x5f58f2){const _0x4f0be8=_0x5afe55;let _0x1a4742,_0x2ca0de;return _0x5f58f2[_0x4f0be8('0x18')]=intUtil[_0x4f0be8('0x28')](_0x5f58f2[_0x4f0be8('0x18')]),_0x5f58f2[_0x4f0be8('0x48')]=intUtil['stripTrailingSlash'](_0x5f58f2['serverUrl']),_0x42868e&&_0x42868e[_0x4f0be8('0x37')]?(logger[_0x4f0be8('0x31')]('['+_0x138871[_0x4f0be8('0x2d')][_0x4f0be8('0x9')]()+']',_0x4f0be8('0x25')),_0x138871[_0x4f0be8('0x30')]=util[_0x4f0be8('0x67')](_0x4f0be8('0x68'),_0x5f58f2[_0x4f0be8('0x48')],_0x138871[_0x4f0be8('0x43')],md5(_0x138871[_0x4f0be8('0x43')]))):_0x138871[_0x4f0be8('0x30')]='',headers[_0x4f0be8('0x40')]=getAuth(_0x5f58f2),getUser(_0x5f58f2)[_0x4f0be8('0x22')](function(_0x43d603){const _0x131bdd=_0x4f0be8;return _0x1a4742=_0x43d603,logger[_0x131bdd('0x31')](_0x131bdd('0x39'),_0x1a4742['id']),getEndUser(_0x5f58f2,_0x138871[_0x131bdd('0x17')],_0x138871[_0x131bdd('0x12')]);})['then'](function(_0x26ac31){const _0x4b0e5c=_0x4f0be8;return _0x2ca0de=_0x26ac31,logger['info'](_0x4b0e5c('0x45'),_0x2ca0de['id']),getTicket(_0x5f58f2,_0x1a4742,_0x2ca0de,_0x41f936,_0x138871);})[_0x4f0be8('0x22')](function(_0x11c090){const _0x52df14=_0x4f0be8;_0x11c090&&logger[_0x52df14('0x31')](_0x52df14('0x55'),_0x11c090['id']);})[_0x4f0be8('0x27')](function(_0x16fe5e){const _0x1fb363=_0x4f0be8;logger[_0x1fb363('0x15')]('['+_0x138871['lastevent'][_0x1fb363('0x9')]()+']'+_0x1fb363('0x49'),util[_0x1fb363('0x4b')](_0x16fe5e,{'showHidden':!![],'depth':null}));});}; \ No newline at end of file +const a1146_0x3ced=['Ticket\x20created!','filter','unmanaged','toString','format','Authorization','type','content','newTab','Fields','authType','POST','from','Basic\x20%s','application/json','[QUEUE]\x20Error\x20running\x20Zendesk\x20integration','emit','Enduser\x20not\x20found,\x20creating\x20a\x20new\x20enduser!','%s/channels/voice/agents/%d/tickets/%d/display.json','lastevent','Variable','The\x20User\x20ID\x20is:','recordingURL','Subjects','queue','end-user','Agent\x20found!','forEach','ticket','first','count','Zendesk\x20account\x20type\x20not\x20recognized','./util','error','user:%s','username','push','validateEmail','%s/token:%s','find','token','%s/search.json','uniqueid','%s:%s','stripTrailingSlash','Getting\x20agent\x20with\x20email','[QUEUE]','\x20Error\x20running\x20Zendesk\x20integration','outbound','base64','Caller\x20-\x20%s','Descriptions','agent','%s/tickets.json','Enduser\x20found!','destcalleridname','results','name','/api/v2','integrationTab','idField','inspect','replace','Recording\x20is\x20enabled!','customVariable','trigger:browser:url','custom_fields','%s/users.json','monitor_format','string','zendesk','catch','recordingFormat','nameField','none','[OUTBOUND]','user','email','toLowerCase','%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s','calleridname','[HTTP]','%s/users/me.json','The\x20Ticket\x20ID\x20is:','request-promise-native','serverUrl','then','password','info','getString','length','The\x20Enduser\x20ID\x20is:','../../../../rediscache','calleridnum','remoteUri','toUpperCase','customField','%s/agent/tickets/%s','Admin\x20account\x20selected.','lodash','Enduser\x20created.','variableName'];(function(_0x5b1041,_0x3ced71){const _0x563343=function(_0x10a5b0){while(--_0x10a5b0){_0x5b1041['push'](_0x5b1041['shift']());}};_0x563343(++_0x3ced71);}(a1146_0x3ced,0x7e));const a1146_0x5633=function(_0x5b1041,_0x3ced71){_0x5b1041=_0x5b1041-0x0;let _0x563343=a1146_0x3ced[_0x5b1041];return _0x563343;};const _0x12522d=a1146_0x5633;'use strict';const _=require(_0x12522d('0x4b')),rp=require(_0x12522d('0x3c')),md5=require('md5'),util=require('util'),intUtil=require(_0x12522d('0x8')),logger=require('../../../../config/logger')(_0x12522d('0x2e')),{getSocket}=require(_0x12522d('0x44')),io=getSocket();function emit(_0x10a5b0,_0x3ffd14,_0x792144){const _0x212a27=_0x12522d;io['to'](_0x10a5b0)[_0x212a27('0x5e')](_0x3ffd14,_0x792144);}const headers={'Content-Type':_0x12522d('0x5c'),'Accept':'application/json'};function getTicket(_0x346a58,_0x10b147,_0xa96ec1,_0x17760d,_0x29bd78){const _0x4721db=_0x12522d;return logger['info']('Creating\x20new\x20ticket...'),request({'uri':util['format'](_0x4721db('0x1d'),_0x346a58[_0x4721db('0x46')]),'method':_0x4721db('0x59'),'body':{'ticket':_['merge']({'requester_id':_0xa96ec1['id'],'submitter_id':_0x10b147?_0x10b147['id']:undefined,'assignee_id':_0x10b147?_0x10b147['id']:undefined,'tags':getTags(_0x17760d['Tags'],_0x4721db('0x21')),'subject':intUtil[_0x4721db('0x41')](_0x17760d[_0x4721db('0x65')],_0x29bd78,'\x20'),'description':intUtil[_0x4721db('0x41')](_0x17760d['Descriptions'],_0x29bd78,'\x0a'),'comment':{'public':![],'body':intUtil[_0x4721db('0x41')](_0x17760d[_0x4721db('0x1b')],_0x29bd78,'\x0a')}},getCustomFields(_0x17760d[_0x4721db('0x57')],_0x29bd78))}})[_0x4721db('0x3e')](function(_0xc52d7c){const _0x4edd80=_0x4721db;return logger['info'](_0x4edd80('0x4e')),_0xc52d7c[_0x4edd80('0x4')];});}function getUser(_0x4dcdcb,_0x400647){const _0x39a3fc=_0x12522d;return intUtil[_0x39a3fc('0xd')](_0x400647)?(logger['info'](_0x39a3fc('0x15'),_0x400647),request({'uri':util[_0x39a3fc('0x52')](_0x39a3fc('0x11'),_0x4dcdcb[_0x39a3fc('0x46')]),'qs':{'query':util[_0x39a3fc('0x52')]('type:user\x20role:agent\x20email:%s',_0x400647)}})[_0x39a3fc('0x3e')](function(_0x264b0c){const _0x5a3950=_0x39a3fc;return _0x264b0c[_0x5a3950('0x6')]?(logger[_0x5a3950('0x40')](_0x5a3950('0x2')),_[_0x5a3950('0xf')](_0x264b0c[_0x5a3950('0x20')],{'email':_0x400647,'role':_0x5a3950('0x1c')})):(logger[_0x5a3950('0x40')]('Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!'),request({'uri':util[_0x5a3950('0x52')](_0x5a3950('0x3a'),_0x4dcdcb[_0x5a3950('0x46')])})['then'](function(_0x1d73ac){const _0x5e3213=_0x5a3950;return logger[_0x5e3213('0x40')](_0x5e3213('0x4a')),_0x1d73ac[_0x5e3213('0x34')];}));})):(logger['info']('Agent\x20not\x20found,\x20using\x20the\x20admin\x20account!'),request({'uri':util[_0x39a3fc('0x52')](_0x39a3fc('0x3a'),_0x4dcdcb['remoteUri'])})[_0x39a3fc('0x3e')](function(_0x485713){const _0x205149=_0x39a3fc;return logger[_0x205149('0x40')](_0x205149('0x4a')),_0x485713[_0x205149('0x34')];}));}function getEndUser(_0x378bcf,_0x30127a,_0x35942f){const _0x3d81a6=_0x12522d;return logger[_0x3d81a6('0x40')]('Searching\x20enduser\x20with\x20phone',_0x35942f),request({'uri':util['format'](_0x3d81a6('0x11'),_0x378bcf[_0x3d81a6('0x46')]),'qs':{'query':util[_0x3d81a6('0x52')]('type:user\x20role:end-user\x20phone:%s',_0x35942f)}})[_0x3d81a6('0x3e')](function(_0x4573a8){const _0x5d5cb0=_0x3d81a6;let _0x473643;return _0x4573a8['results'][_0x5d5cb0('0x42')]&&(_0x4573a8['results']=_[_0x5d5cb0('0x4f')](_0x4573a8['results'],{'suspended':![],'role':_0x5d5cb0('0x1')}),_0x4573a8[_0x5d5cb0('0x20')][_0x5d5cb0('0x42')]&&(_0x473643=_[_0x5d5cb0('0x5')](_0x4573a8[_0x5d5cb0('0x20')]))),_0x473643?(logger[_0x5d5cb0('0x40')](_0x5d5cb0('0x1e')),_0x473643):(logger[_0x5d5cb0('0x40')](_0x5d5cb0('0x5f')),request({'uri':util[_0x5d5cb0('0x52')](_0x5d5cb0('0x2b'),_0x378bcf[_0x5d5cb0('0x46')]),'method':'POST','body':{'user':{'role':_0x5d5cb0('0x1'),'name':util[_0x5d5cb0('0x52')](_0x5d5cb0('0x1a'),_0x30127a||_0x35942f),'phone':_0x35942f}}})[_0x5d5cb0('0x3e')](function(_0x46f355){const _0x3425f4=_0x5d5cb0;return logger['info'](_0x3425f4('0x4c')),_0x46f355['user'];}));});}function getAuth(_0x285fe3){const _0x45f998=_0x12522d;let _0x2066a4;if(_0x285fe3['authType']===_0x45f998('0x3f'))_0x2066a4=util[_0x45f998('0x52')](_0x45f998('0x13'),_0x285fe3[_0x45f998('0xb')],_0x285fe3['password']);else _0x285fe3[_0x45f998('0x58')]===_0x45f998('0x10')&&(_0x2066a4=util[_0x45f998('0x52')](_0x45f998('0xe'),_0x285fe3[_0x45f998('0xb')],_0x285fe3['token']));return util[_0x45f998('0x52')](_0x45f998('0x5b'),Buffer[_0x45f998('0x5a')](_0x2066a4)[_0x45f998('0x51')](_0x45f998('0x19')));}function request(_0x5cbdf6){const _0x4e334f=_0x12522d;return logger['debug'](_0x4e334f('0x39'),JSON['stringify'](_0x5cbdf6)),rp(_['defaults'](_0x5cbdf6,{'method':'GET','headers':headers,'json':!![]}));}function getTags(_0x4a9af2,_0x1d3340){const _0xe28427=_0x12522d;let _0x32a414=[];return _0x4a9af2&&_0x4a9af2[_0xe28427('0x42')]>0x0&&(_0x32a414=_['map'](_0x4a9af2,_0x1d3340)),_0x32a414;}function getCustomFields(_0x4eda51,_0x1b2153){const _0x25759c=_0x12522d,_0x20b743={'custom_fields':[]};return _0x4eda51[_0x25759c('0x42')]>0x0&&_[_0x25759c('0x3')](_0x4eda51,function(_0x5c1509){const _0x548665=_0x25759c;if(_0x5c1509[_0x548665('0x54')]===_0x548665('0x2d')&&_0x5c1509[_0x548665('0x31')]&&!_0x5c1509[_0x548665('0x48')])_0x20b743[_0x5c1509[_0x548665('0x31')]['toLowerCase']()]=_0x5c1509[_0x548665('0x55')][_0x548665('0x51')]();else{if(_0x5c1509[_0x548665('0x54')]===_0x548665('0x2d')&&_0x5c1509[_0x548665('0x24')]&&_0x5c1509[_0x548665('0x48')])_0x20b743[_0x548665('0x2a')]['push']({'id':_0x5c1509[_0x548665('0x24')],'value':_0x5c1509['content'][_0x548665('0x51')]()});else{if(_0x5c1509['type']==='variable'&&_0x5c1509['variableName']&&_0x5c1509[_0x548665('0x24')]&&_0x5c1509['customField'])_0x1b2153[_0x5c1509[_0x548665('0x4d')]]&&_0x20b743[_0x548665('0x2a')][_0x548665('0xc')]({'id':_0x5c1509[_0x548665('0x24')],'value':_0x1b2153[_0x5c1509['variableName']][_0x548665('0x51')]()});else _0x5c1509[_0x548665('0x54')]===_0x548665('0x28')&&_0x5c1509[_0x548665('0x62')]&&_0x5c1509['Variable']['name']&&_0x5c1509[_0x548665('0x24')]&&_0x5c1509['customField']&&(_0x1b2153[_0x5c1509['Variable'][_0x548665('0x21')]['toLowerCase']()]&&_0x20b743[_0x548665('0x2a')][_0x548665('0xc')]({'id':_0x5c1509[_0x548665('0x24')],'value':_0x1b2153[_0x5c1509[_0x548665('0x62')][_0x548665('0x21')][_0x548665('0x36')]()][_0x548665('0x51')]()}));}}}),_0x20b743;}exports[_0x12522d('0x0')]=function(_0x360108,_0x48320c,_0xf63d91,_0x548926,_0x377356,_0x43a9ba){const _0x3d3b45=_0x12522d;let _0x5b7517,_0xf9c62b;return _0x43a9ba[_0x3d3b45('0x46')]=intUtil[_0x3d3b45('0x14')](_0x43a9ba[_0x3d3b45('0x46')]),_0x43a9ba[_0x3d3b45('0x3d')]=intUtil['stripTrailingSlash'](_0x43a9ba[_0x3d3b45('0x3d')]),_0x377356&&_0x377356[_0x3d3b45('0x2c')]?(logger[_0x3d3b45('0x40')]('[QUEUE]',_0x3d3b45('0x27')),_0x48320c[_0x3d3b45('0x64')]=util[_0x3d3b45('0x52')]('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0x43a9ba['serverUrl'],_0x48320c[_0x3d3b45('0x12')],md5(_0x48320c['uniqueid']))):_0x48320c[_0x3d3b45('0x64')]='',headers[_0x3d3b45('0x53')]=getAuth(_0x43a9ba),getUser(_0x43a9ba,_0x548926[_0x3d3b45('0x35')])[_0x3d3b45('0x3e')](function(_0x3daffa){const _0x432e8d=_0x3d3b45;return _0x5b7517=_0x3daffa,logger[_0x432e8d('0x40')](_0x432e8d('0x63'),_0x5b7517['id']),getEndUser(_0x43a9ba,_0x48320c[_0x432e8d('0x38')],_0x48320c[_0x432e8d('0x45')]);})[_0x3d3b45('0x3e')](function(_0x142946){const _0x1e5e88=_0x3d3b45;return _0xf9c62b=_0x142946,logger[_0x1e5e88('0x40')](_0x1e5e88('0x43'),_0xf9c62b['id']),getTicket(_0x43a9ba,_0x5b7517,_0xf9c62b,_0xf63d91,_0x48320c);})[_0x3d3b45('0x3e')](function(_0x2f7140){const _0x152d2f=_0x3d3b45;if(_0x2f7140){logger[_0x152d2f('0x40')](_0x152d2f('0x3b'),_0x2f7140['id']);switch(_0x43a9ba[_0x152d2f('0x54')]){case _0x152d2f('0x23'):logger[_0x152d2f('0x40')]('[QUEUE]','Displaying\x20ticket\x20to\x20agent...');return request({'uri':util[_0x152d2f('0x52')](_0x152d2f('0x60'),_0x43a9ba[_0x152d2f('0x46')],_0x5b7517['id'],_0x2f7140['id']),'method':'POST'});case _0x152d2f('0x56'):logger[_0x152d2f('0x40')](_0x152d2f('0x16'),'Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...'),emit(util[_0x152d2f('0x52')](_0x152d2f('0xa'),_0x548926[_0x152d2f('0x21')]),_0x152d2f('0x29'),{'uri':util[_0x152d2f('0x52')](_0x152d2f('0x49'),_0x43a9ba['remoteUri'][_0x152d2f('0x26')]('/api/v2'),_0x2f7140['id'])});break;default:logger['error']('[QUEUE]',_0x152d2f('0x7'));}}})['catch'](function(_0x19ae20){const _0x31edda=_0x3d3b45;logger[_0x31edda('0x9')](_0x31edda('0x5d'),util[_0x31edda('0x25')](_0x19ae20,{'showHidden':!![],'depth':null}));});},exports[_0x12522d('0x18')]=function(_0x2ebb72,_0x14ea71,_0x1abf90,_0x3619e9,_0x2bcd1e,_0xda5661,_0x38f049){const _0x5f5323=_0x12522d;let _0x106ee8,_0x2906ea;return _0xda5661[_0x5f5323('0x46')]=intUtil[_0x5f5323('0x14')](_0xda5661[_0x5f5323('0x46')]),_0xda5661[_0x5f5323('0x3d')]=intUtil['stripTrailingSlash'](_0xda5661['serverUrl']),_0x38f049&&_0x38f049[_0x5f5323('0x30')]&&_0x38f049['recordingFormat']!==_0x5f5323('0x32')&&(logger[_0x5f5323('0x40')](_0x5f5323('0x33'),_0x5f5323('0x27')),_0x14ea71[_0x5f5323('0x64')]=util['format']('%s/api/voice/recordings/%s/downloads?type=uniqueid&token=%s',_0xda5661[_0x5f5323('0x3d')],_0x14ea71[_0x5f5323('0x12')],md5(_0x14ea71['uniqueid']))),headers[_0x5f5323('0x53')]=getAuth(_0xda5661),getUser(_0xda5661,_0x3619e9[_0x5f5323('0x35')])[_0x5f5323('0x3e')](function(_0x3f6ddb){const _0x47edfa=_0x5f5323;return _0x106ee8=_0x3f6ddb,logger[_0x47edfa('0x40')](_0x47edfa('0x63'),_0x106ee8['id']),getEndUser(_0xda5661,_0x14ea71[_0x47edfa('0x1f')],_0x14ea71['destcalleridnum']);})[_0x5f5323('0x3e')](function(_0x4dfac2){const _0x27d398=_0x5f5323;return _0x2906ea=_0x4dfac2,logger['info'](_0x27d398('0x43'),_0x2906ea['id']),getTicket(_0xda5661,_0x106ee8,_0x2906ea,_0x1abf90,_0x14ea71);})['then'](function(_0x127107){const _0x170b74=_0x5f5323;if(_0x127107){logger[_0x170b74('0x40')](_0x170b74('0x3b'),_0x127107['id']);switch(_0xda5661[_0x170b74('0x54')]){case _0x170b74('0x23'):logger[_0x170b74('0x40')]('[OUTBOUND]','Displaying\x20ticket\x20to\x20agent...');return request({'uri':util[_0x170b74('0x52')](_0x170b74('0x60'),_0xda5661[_0x170b74('0x46')],_0x106ee8['id'],_0x127107['id']),'method':_0x170b74('0x59')});case _0x170b74('0x56'):logger['info']('[OUTBOUND]','Displaying\x20ticket\x20to\x20agent\x20in\x20a\x20new\x20tab...'),emit(util[_0x170b74('0x52')]('user:%s',_0x3619e9[_0x170b74('0x21')]),'trigger:browser:url',{'uri':util['format'](_0x170b74('0x49'),_0xda5661[_0x170b74('0x46')]['replace'](_0x170b74('0x22')),_0x127107['id'])});break;default:logger['error'](_0x170b74('0x33'),'Zendesk\x20account\x20type\x20not\x20recognized');}}})[_0x5f5323('0x2f')](function(_0x90cdc0){const _0x387d8c=_0x5f5323;logger['error']('[OUTBOUND]\x20Error\x20running\x20Zendesk\x20integration',util[_0x387d8c('0x25')](_0x90cdc0,{'showHidden':!![],'depth':null}));});},exports[_0x12522d('0x50')]=function(_0x41fa94,_0x58c9a2,_0x1c6271,_0xe31f73,_0x37022b,_0x3e6db7){const _0x2a2560=_0x12522d;let _0x1a69a9,_0x4753fc;return _0x3e6db7[_0x2a2560('0x46')]=intUtil['stripTrailingSlash'](_0x3e6db7[_0x2a2560('0x46')]),_0x3e6db7['serverUrl']=intUtil['stripTrailingSlash'](_0x3e6db7['serverUrl']),_0x37022b&&_0x37022b[_0x2a2560('0x2c')]?(logger['info']('['+_0x58c9a2[_0x2a2560('0x61')][_0x2a2560('0x47')]()+']',_0x2a2560('0x27')),_0x58c9a2[_0x2a2560('0x64')]=util[_0x2a2560('0x52')](_0x2a2560('0x37'),_0x3e6db7['serverUrl'],_0x58c9a2[_0x2a2560('0x12')],md5(_0x58c9a2[_0x2a2560('0x12')]))):_0x58c9a2[_0x2a2560('0x64')]='',headers[_0x2a2560('0x53')]=getAuth(_0x3e6db7),getUser(_0x3e6db7)['then'](function(_0x14b4a5){const _0xf29983=_0x2a2560;return _0x1a69a9=_0x14b4a5,logger[_0xf29983('0x40')]('The\x20User\x20ID\x20is:',_0x1a69a9['id']),getEndUser(_0x3e6db7,_0x58c9a2[_0xf29983('0x38')],_0x58c9a2[_0xf29983('0x45')]);})[_0x2a2560('0x3e')](function(_0x7e309d){const _0x2c3df1=_0x2a2560;return _0x4753fc=_0x7e309d,logger['info'](_0x2c3df1('0x43'),_0x4753fc['id']),getTicket(_0x3e6db7,_0x1a69a9,_0x4753fc,_0x1c6271,_0x58c9a2);})[_0x2a2560('0x3e')](function(_0x4a9344){const _0xd5dd84=_0x2a2560;_0x4a9344&&logger[_0xd5dd84('0x40')](_0xd5dd84('0x3b'),_0x4a9344['id']);})[_0x2a2560('0x2f')](function(_0x34127e){const _0x2959c4=_0x2a2560;logger[_0x2959c4('0x9')]('['+_0x58c9a2['lastevent'][_0x2959c4('0x47')]()+']'+_0x2959c4('0x17'),util['inspect'](_0x34127e,{'showHidden':!![],'depth':null}));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/integration/zoho.js b/server/services/ami/trigger/integration/zoho.js index e6b69f9..ed01b16 100644 --- a/server/services/ami/trigger/integration/zoho.js +++ b/server/services/ami/trigger/integration/zoho.js @@ -1 +1 @@ -const a1147_0x3fd1=['last_name','complete','monitor_format','clientSecret','log','request-promise-native','lastevent','lodash','https://accounts.zoho.eu','type','util','uri','Administrator','Call_Result','[OUTBOUND]','Descriptions','../../../../config/logger','Error:\x20','split','https://accounts.zoho.com.cn','Failing\x20creating\x20the\x20access_token','Recording\x20is\x20enabled!','moment','Creating\x20new\x20call...','idField','serverUrl','Rejected','calleridnum','[HTTP]','Full_Name','zoho.eu','isNil','starttime','variable','https://accounts.zoho.in','recordingFormat','indexOf','Contacts','/crm/v2/Calls','Last_Name','host','enduserType','contact_lead','access_token','endtime','SUCCESS','calleridname','err','length','What_Id','catch','Displaying\x20call\x20to\x20agent\x20in\x20a\x20new\x20tab...','Leads','Inbound','abandoned','Call_Type','profile','then','details','toString','zoho','role','destcalleridnum','data','/downloads?type=uniqueid&token=','nothing','Zoho-oauthtoken\x20','info','expires_in','refreshToken','talktime','destcalleridname','mm:ss','rejected','unmanaged','isBefore','startCase','First_Name','https://www.zohoapis.%s/crm/v2/users','The\x20Call\x20ID\x20is:','md5','Agent\x20found!','refresh_token','uniqueid','recordingURL','customVariable','format','user:%s','Owner','The\x20failing\x20result\x20is','Who_Id','called','answertime','diff','Called','code','trigger:browser:url','https://accounts.zoho.com.au','Description','name','/crm/v2/','stripTrailingSlash','outbound','/crm/v2/Leads/search?criteria=((Phone:equals:','moduleSearch','/crm/v2/Contacts/search?criteria=((Phone:equals:','POST','toLowerCase','https://www.zohoapis.','stringify','https://crm.','../../../../rediscache','$se_module','administrator','Unable\x20to\x20retrieve\x20zoho\x20account\x20users:\x20','com','variableName','[QUEUE]','Using\x20the\x20admin\x20account!','/api/voice/recordings/','first_name','email','error','lead','./util','Answered','/oauth/v2/token','toUpperCase','Subjects','/crm/EntityInfo.do?module=Calls&id=','Call_Start_Time','Search\x20user','CREATE\x20ERROR','ActiveUsers','The\x20User\x20ID\x20is:','user','GET','YYYY-MM-DDTHH:mm:ss','Abandoned','stack','users','Call_Duration','moduleCreate','connect'];(function(_0x2b4838,_0x3fd101){const _0x522d2d=function(_0x284337){while(--_0x284337){_0x2b4838['push'](_0x2b4838['shift']());}};_0x522d2d(++_0x3fd101);}(a1147_0x3fd1,0x160));const a1147_0x522d=function(_0x2b4838,_0x3fd101){_0x2b4838=_0x2b4838-0x0;let _0x522d2d=a1147_0x3fd1[_0x2b4838];return _0x522d2d;};const _0x18e329=a1147_0x522d;'use strict';const _=require(_0x18e329('0x57')),rp=require(_0x18e329('0x55')),md5=require(_0x18e329('0x10')),util=require(_0x18e329('0x5a')),intUtil=require(_0x18e329('0x3c')),moment=require(_0x18e329('0x66')),logger=require(_0x18e329('0x60'))(_0x18e329('0x8c')),{getSocket}=require(_0x18e329('0x2f')),io=getSocket();function emit(_0x284337,_0x585c10,_0x375929){io['to'](_0x284337)['emit'](_0x585c10,_0x375929);}function request(_0x3ea4ca){const _0x157454=_0x18e329;return logger['debug'](_0x157454('0x6c'),JSON['stringify'](_0x3ea4ca)),rp(_0x3ea4ca);}function getCustomFields(_0x1cc8cb,_0x1423de){const _0x931e2e=_0x18e329,_0x264739={};return _0x1cc8cb[_0x931e2e('0x80')]>0x0&&_['forEach'](_0x1cc8cb,function(_0x82aa5d){const _0x2891ee=_0x931e2e;if(_0x82aa5d[_0x2891ee('0x59')]==='string'&&_0x82aa5d[_0x2891ee('0x68')])_0x264739[_0x82aa5d[_0x2891ee('0x68')]]=_0x82aa5d['content'][_0x2891ee('0x8b')]();else{if(_0x82aa5d[_0x2891ee('0x59')]===_0x2891ee('0x71')&&_0x82aa5d[_0x2891ee('0x34')]&&_0x82aa5d[_0x2891ee('0x68')]&&_0x1423de[_0x82aa5d[_0x2891ee('0x34')]])_0x264739[_0x82aa5d[_0x2891ee('0x68')]]=_0x1423de[_0x82aa5d[_0x2891ee('0x34')]][_0x2891ee('0x8b')]();else _0x82aa5d['type']===_0x2891ee('0x15')&&_0x82aa5d['Variable']&&_0x82aa5d['Variable'][_0x2891ee('0x23')]&&_0x82aa5d[_0x2891ee('0x68')]&&_0x1423de[_0x82aa5d['Variable'][_0x2891ee('0x23')][_0x2891ee('0x2b')]()]&&(_0x264739[_0x82aa5d['idField']]=_0x1423de[_0x82aa5d['Variable'][_0x2891ee('0x23')][_0x2891ee('0x2b')]()]['toString']());}}),_0x264739;}function getName(_0x3215f9){const _0x319eaa=_0x18e329;if(_0x3215f9[_0x319eaa('0x74')]('\x20')>0x0){const _0x3984bb=_0x3215f9[_0x319eaa('0x62')](/ (.+)/);if(_0x3984bb[0x1])return _0x3984bb;}return[_0x3215f9,_0x3215f9];}const accountsTokens={};function getAccessToken(_0x2b032e){return new Promise(function(_0x58a86f,_0x53d320){const _0x57733e=a1147_0x522d;!_[_0x57733e('0x6f')](accountsTokens[_0x2b032e['id']])&&!_[_0x57733e('0x6f')](accountsTokens[_0x2b032e['id']]['access_token'])&&(moment()[_0x57733e('0xb')](accountsTokens[_0x2b032e['id']][_0x57733e('0x4')])&&_0x58a86f(accountsTokens[_0x2b032e['id']][_0x57733e('0x7b')]));let _0x538fa1;switch(_0x2b032e['zone']){case'US':_0x538fa1='https://accounts.zoho.com';break;case'AU':_0x538fa1=_0x57733e('0x21');break;case'EU':_0x538fa1=_0x57733e('0x58');break;case'IN':_0x538fa1=_0x57733e('0x72');break;case'CN':_0x538fa1=_0x57733e('0x63');break;default:_0x538fa1=_0x57733e('0x58');break;}const _0x61c9a2={'method':'POST','uri':_0x538fa1+_0x57733e('0x3e'),'qs':{'refresh_token':_0x2b032e[_0x57733e('0x5')],'client_id':_0x2b032e['clientId'],'client_secret':_0x2b032e[_0x57733e('0x53')],'grant_type':_0x57733e('0x12')},'json':!![]};return rp(_0x61c9a2)['then'](function(_0x1151a5){const _0x3f47cf=_0x57733e;accountsTokens[_0x2b032e['id']]={'access_token':_0x1151a5[_0x3f47cf('0x7b')],'expires_in':moment()['add'](_0x1151a5['expires_in'],'seconds')},_0x58a86f(_0x1151a5[_0x3f47cf('0x7b')]);})[_0x57733e('0x82')](function(_0x214280){const _0x44a256=_0x57733e;logger[_0x44a256('0x3a')](_0x44a256('0x64'),_0x214280['stack']),_0x53d320(_0x214280);});});}function getUser(_0x49f62c,_0x221f1d,_0x3a2d5b,_0x36ba47){const _0x5efcd8=_0x18e329;return logger[_0x5efcd8('0x3')](_0x5efcd8('0x43')),request({'method':_0x5efcd8('0x48'),'uri':util['format'](_0x5efcd8('0xe'),_0x221f1d),'qs':{'type':_0x5efcd8('0x45')},'headers':{'Authorization':'Zoho-oauthtoken\x20'+_0x49f62c},'json':!![]})[_0x5efcd8('0x89')](function(_0x597828){const _0x23cd0a=_0x5efcd8;if(_0x597828['users']){let _0x3a9cf1=-0x1;if(_['isArrayLikeObject'](_0x597828['users']))return!_[_0x23cd0a('0x6f')](_0x36ba47)&&(_0x3a9cf1=_['findIndex'](_0x597828[_0x23cd0a('0x4c')],function(_0x21fb77){const _0x49d76e=_0x23cd0a;return _0x21fb77[_0x49d76e('0x39')]===_0x36ba47;})),_0x3a9cf1>=0x0?logger[_0x23cd0a('0x3')](_0x23cd0a('0x11')):(logger[_0x23cd0a('0x3')](_0x23cd0a('0x36')),_0x3a9cf1=_['findIndex'](_0x597828[_0x23cd0a('0x4c')],function(_0x295642){const _0x5bb59d=_0x23cd0a;return _0x295642[_0x5bb59d('0x88')][_0x5bb59d('0x23')]===_0x5bb59d('0x5c');})),_0x597828[_0x23cd0a('0x4c')][_0x3a9cf1];else{if(_0x597828[_0x23cd0a('0x47')][_0x23cd0a('0x88')][_0x23cd0a('0x23')]==='Administrator'){logger['info'](_0x23cd0a('0x36'));const _0x57c228=_0x597828[_0x23cd0a('0x47')];return _0x57c228;}else{logger['error'](_0x23cd0a('0x19'),JSON[_0x23cd0a('0x2d')](_0x597828));throw new Error(_0x23cd0a('0x32')+JSON[_0x23cd0a('0x2d')](_0x597828));}}}else{logger['error']('The\x20failing\x20result\x20is',JSON['stringify'](_0x597828));throw new Error(_0x23cd0a('0x32')+JSON[_0x23cd0a('0x2d')](_0x597828));}})[_0x5efcd8('0x82')](function(_0xf3ae4f){const _0x2654b0=_0x5efcd8;console[_0x2654b0('0x3a')](_0xf3ae4f);});}function getZohoUser(_0x163ae7,_0x1117fa){return new Promise(function(_0x121460,_0x1d1c01){const _0x1e5a6b=a1147_0x522d;request(_0x163ae7)[_0x1e5a6b('0x89')](function(_0x4c3c36){const _0x3ddb4f=_0x1e5a6b;let _0x53fd7d=null;_0x4c3c36&&(_0x53fd7d=_0x4c3c36[_0x3ddb4f('0x8f')][0x0],_0x53fd7d[_0x3ddb4f('0x79')]=_0x1117fa),_0x121460(_0x53fd7d);})['catch'](function(_0x54f46a){_0x1d1c01(_0x54f46a);});});}function createEndUser(_0x5ff6b1,_0x366cf2,_0xeb7f3d,_0x35b51a,_0x36ea6a,_0x3b5dfe){const _0x44f2cd=_0x18e329;return _0xeb7f3d=getName(_0xeb7f3d),request({'method':_0x44f2cd('0x2a'),'uri':'https://www.zohoapis.'+_0x366cf2+_0x44f2cd('0x24')+_['startCase'](_0x3b5dfe[_0x44f2cd('0x4e')])+'s','body':{'data':[{'Last_Name':_0xeb7f3d[0x1],'First_Name':_0xeb7f3d[0x0],'Phone':_0x35b51a,'Owner':{'name':!_[_0x44f2cd('0x6f')](_0x36ea6a[_0x44f2cd('0x8d')][_0x44f2cd('0x23')])?_0x36ea6a[_0x44f2cd('0x8d')][_0x44f2cd('0x23')]:!_[_0x44f2cd('0x6f')](_0x36ea6a[_0x44f2cd('0x38')])?_0x36ea6a[_0x44f2cd('0x38')]+'\x20'+_0x36ea6a[_0x44f2cd('0x50')]:_0x36ea6a[_0x44f2cd('0x50')],'id':_0x36ea6a['id']}}]},'headers':{'Authorization':_0x44f2cd('0x2')+_0x5ff6b1},'json':!![]})[_0x44f2cd('0x89')](function(_0x42b2da){const _0x1380f4=_0x44f2cd;if(_0x42b2da&&_0x42b2da[_0x1380f4('0x8f')][0x0][_0x1380f4('0x1f')]===_0x1380f4('0x7d')){const _0x1d0a0c=_0x42b2da['data'][0x0][_0x1380f4('0x8a')];return _0x1d0a0c['enduserType']=_[_0x1380f4('0xc')](_0x3b5dfe[_0x1380f4('0x4e')])+'s',_0x1d0a0c;}const _0x1c2055=_0x42b2da[_0x1380f4('0x8f')];logger[_0x1380f4('0x3a')](_0x1380f4('0x19'),JSON[_0x1380f4('0x2d')](_0x1c2055));throw new Error(_0x1380f4('0x61')+JSON[_0x1380f4('0x2d')](_0x1c2055));})[_0x44f2cd('0x82')](function(_0x4e2f78){const _0x506e3b=_0x44f2cd;console[_0x506e3b('0x54')](_0x506e3b('0x44'),_0x4e2f78);});}function getEndUser(_0x57bf03,_0x292128,_0xe0fd9a,_0x4da359,_0x58555c,_0x2577f5,_0x5e81a3){const _0x26b2cd=_0x18e329,_0x2c8d94={'method':'GET','uri':'','headers':{'Authorization':_0x26b2cd('0x2')+_0x57bf03},'json':!![]};switch(_0x5e81a3[_0x26b2cd('0x28')]){case _0x26b2cd('0x7a'):_0x2c8d94[_0x26b2cd('0x5b')]=_0x26b2cd('0x2c')+_0x292128+_0x26b2cd('0x29')+_0x58555c+'))';return getZohoUser(_0x2c8d94,_0x26b2cd('0x75'))[_0x26b2cd('0x89')](function(_0x48edfc){const _0x1fcdb6=_0x26b2cd;if(_0x48edfc)return _0x48edfc;return _0x2c8d94[_0x1fcdb6('0x5b')]=_0x1fcdb6('0x2c')+_0x292128+'/crm/v2/Leads/search?criteria=((Phone:equals:'+_0x58555c+'))',getZohoUser(_0x2c8d94,_0x1fcdb6('0x84'))['then'](function(_0x5e3ccf){const _0x2be4a0=_0x1fcdb6;if(_0x5e3ccf)return _0x5e3ccf;return _0x5e81a3[_0x2be4a0('0x4e')]!='nothing'?createEndUser(_0x57bf03,_0x292128,_0x4da359,_0x58555c,_0x2577f5,_0x5e81a3):{};});});case'contact':_0x2c8d94['uri']='https://www.zohoapis.'+_0x292128+_0x26b2cd('0x29')+_0x58555c+'))';return getZohoUser(_0x2c8d94,'Contacts')[_0x26b2cd('0x89')](function(_0x390228){const _0x2b57a0=_0x26b2cd;if(_0x390228)return _0x390228;return _0x5e81a3[_0x2b57a0('0x4e')]!=_0x2b57a0('0x1')?createEndUser(_0x57bf03,_0x292128,_0x4da359,_0x58555c,_0x2577f5,_0x5e81a3):{};});case _0x26b2cd('0x3b'):_0x2c8d94[_0x26b2cd('0x5b')]=_0x26b2cd('0x2c')+_0x292128+_0x26b2cd('0x27')+_0x58555c+'))';return getZohoUser(_0x2c8d94,_0x26b2cd('0x84'))[_0x26b2cd('0x89')](function(_0x4bfa37){const _0x20b293=_0x26b2cd;if(_0x4bfa37)return _0x4bfa37;return _0x5e81a3[_0x20b293('0x4e')]!='nothing'?createEndUser(_0x57bf03,_0x292128,_0x4da359,_0x58555c,_0x2577f5,_0x5e81a3):{};});}}function getCall(_0x52c085,_0x580cfc,_0x2c1f94,_0x26a4d7,_0x5416c3,_0x5328ce,_0x302d88,_0x453280){const _0x3d2b7f=_0x18e329;logger[_0x3d2b7f('0x3')](_0x3d2b7f('0x67'));let _0x149b10={};_0x149b10[_0x3d2b7f('0x18')]={'name':!_['isNil'](_0x26a4d7[_0x3d2b7f('0x8d')][_0x3d2b7f('0x23')])&&!_[_0x3d2b7f('0x6f')](_0x26a4d7[_0x3d2b7f('0x88')]['name'])&&_0x26a4d7['profile'][_0x3d2b7f('0x23')]===_0x3d2b7f('0x31')?_0x26a4d7[_0x3d2b7f('0x8d')]['name']:!_[_0x3d2b7f('0x6f')](_0x26a4d7[_0x3d2b7f('0x38')])?_0x26a4d7[_0x3d2b7f('0x38')]+'\x20'+_0x26a4d7[_0x3d2b7f('0x50')]:_0x26a4d7[_0x3d2b7f('0x50')],'id':_0x26a4d7['id']},_0x149b10['Subject']=intUtil['getString'](_0x5328ce[_0x3d2b7f('0x40')],_0x302d88,'\x20'),_0x149b10[_0x3d2b7f('0x22')]=intUtil['getString'](_0x5328ce[_0x3d2b7f('0x5f')],_0x302d88,'\x0a');_0x5416c3[_0x3d2b7f('0x79')]===_0x3d2b7f('0x75')&&(_0x149b10[_0x3d2b7f('0x1a')]={'name':!_[_0x3d2b7f('0x6f')](_0x5416c3[_0x3d2b7f('0x6d')])?_0x5416c3[_0x3d2b7f('0x6d')]:!_[_0x3d2b7f('0x6f')](_0x5416c3[_0x3d2b7f('0xd')])?_0x5416c3[_0x3d2b7f('0xd')]+'\x20'+_0x5416c3[_0x3d2b7f('0x77')]:_0x5416c3['Last_Name'],'id':_0x5416c3['id']});_0x5416c3[_0x3d2b7f('0x79')]===_0x3d2b7f('0x84')&&(_0x149b10[_0x3d2b7f('0x81')]={'name':!_[_0x3d2b7f('0x6f')](_0x5416c3[_0x3d2b7f('0x6d')])?_0x5416c3[_0x3d2b7f('0x6d')]:!_[_0x3d2b7f('0x6f')](_0x5416c3[_0x3d2b7f('0xd')])?_0x5416c3[_0x3d2b7f('0xd')]+'\x20'+_0x5416c3[_0x3d2b7f('0x77')]:_0x5416c3[_0x3d2b7f('0x77')],'id':_0x5416c3['id']},_0x149b10[_0x3d2b7f('0x30')]=_[_0x3d2b7f('0xc')](_0x5416c3[_0x3d2b7f('0x79')]));if(_0x302d88[_0x3d2b7f('0x6')])_0x149b10[_0x3d2b7f('0x4d')]=moment['utc'](parseInt(_0x302d88['talktime'])*0x3e8)[_0x3d2b7f('0x16')](_0x3d2b7f('0x8'));else _0x302d88[_0x3d2b7f('0x1c')]&&_0x302d88['endtime']&&(_0x149b10['Call_Duration']=moment['utc'](moment(_0x302d88[_0x3d2b7f('0x7c')],_0x3d2b7f('0x49'))[_0x3d2b7f('0x1d')](moment(_0x302d88['starttime'],_0x3d2b7f('0x49'))))[_0x3d2b7f('0x16')]('mm:ss'));switch(_0x302d88['lastevent']){case _0x3d2b7f('0x1b'):_0x149b10[_0x3d2b7f('0x5d')]=_0x3d2b7f('0x1e');break;case _0x3d2b7f('0x51'):case _0x3d2b7f('0x4f'):_0x149b10[_0x3d2b7f('0x5d')]=_0x3d2b7f('0x3d');break;case _0x3d2b7f('0x9'):_0x149b10[_0x3d2b7f('0x5d')]=_0x3d2b7f('0x6a');break;case _0x3d2b7f('0x86'):_0x149b10[_0x3d2b7f('0x5d')]=_0x3d2b7f('0x4a');break;case'timeout':_0x149b10[_0x3d2b7f('0x5d')]='Timeout';break;default:break;}return _0x149b10[_0x3d2b7f('0x42')]=(_0x453280===_0x3d2b7f('0x26')?moment(_0x302d88[_0x3d2b7f('0x70')])[_0x3d2b7f('0x16')](_0x3d2b7f('0x49')):moment(_0x302d88['agentcalledAt'])['format'](_0x3d2b7f('0x49')))||moment()['format']('YYYY-MM-DDTHH:mm:ss'),_0x149b10[_0x3d2b7f('0x87')]=_0x453280||'Inbound',_0x149b10=_['merge'](_0x149b10,getCustomFields(_0x5328ce['Fields'],_0x302d88)),request({'method':_0x3d2b7f('0x2a'),'uri':'https://www.zohoapis.'+_0x580cfc+_0x3d2b7f('0x76'),'headers':{'Authorization':_0x3d2b7f('0x2')+_0x52c085},'body':{'data':[_0x149b10]},'json':!![]})[_0x3d2b7f('0x89')](function(_0x32820f){const _0x3954d5=_0x3d2b7f;if(_0x32820f&&_0x32820f['data'][0x0]['code']===_0x3954d5('0x7d'))return logger['info']('Call\x20created!'),{'id':_0x32820f[_0x3954d5('0x8f')][0x0][_0x3954d5('0x8a')]['id']};})[_0x3d2b7f('0x82')](function(_0x17c389){const _0x3f50fe=_0x3d2b7f;logger[_0x3f50fe('0x3')](_0x3f50fe('0x7f'),_0x17c389[_0x3f50fe('0x4b')]),console[_0x3f50fe('0x54')](_0x3f50fe('0x7f'),_0x17c389);});}exports['queue']=function(_0x2f9e7d,_0x588141,_0x38ee4b,_0x50780e,_0x1f4328,_0x186d2f){const _0x549362=_0x18e329;let _0x536cc4,_0x36a4ad,_0x2245bc;_0x186d2f[_0x549362('0x78')]=intUtil[_0x549362('0x25')](_0x186d2f[_0x549362('0x78')]),_0x186d2f[_0x549362('0x69')]=intUtil[_0x549362('0x25')](_0x186d2f[_0x549362('0x69')]);_0x1f4328&&_0x1f4328[_0x549362('0x52')]?(logger[_0x549362('0x3')](_0x549362('0x35'),_0x549362('0x65')),_0x588141[_0x549362('0x14')]=_0x186d2f[_0x549362('0x69')]+_0x549362('0x37')+_0x588141['uniqueid']+_0x549362('0x0')+md5(_0x588141[_0x549362('0x13')])):_0x588141[_0x549362('0x14')]='';const _0x54dd49=_0x186d2f['host']==='zoho.eu'?'eu':_0x549362('0x33');return getAccessToken(_0x186d2f)[_0x549362('0x89')](function(_0x5cfcad){const _0x179a6c=_0x549362;return _0x2245bc=_0x5cfcad,getUser(_0x2245bc,_0x54dd49,_0x186d2f,_0x50780e[_0x179a6c('0x39')]);})[_0x549362('0x89')](function(_0x300652){const _0x4db8b8=_0x549362;return _0x536cc4=_0x300652,logger[_0x4db8b8('0x3')](_0x4db8b8('0x46'),_0x536cc4['id']),getEndUser(_0x2245bc,_0x54dd49,_0x186d2f,_0x588141[_0x4db8b8('0x7e')],_0x588141[_0x4db8b8('0x6b')],_0x536cc4,_0x38ee4b);})[_0x549362('0x89')](function(_0x5c967b){const _0x4eb77d=_0x549362;return _0x36a4ad=_0x5c967b,getCall(_0x2245bc,_0x54dd49,_0x186d2f,_0x536cc4,_0x36a4ad,_0x38ee4b,_0x588141,_0x4eb77d('0x85'));})[_0x549362('0x89')](function(_0x24523f){const _0x766890=_0x549362;_0x24523f&&(logger['info'](_0x766890('0xf'),_0x24523f['id']),logger['info'](_0x766890('0x35'),_0x766890('0x83')),emit(util['format'](_0x766890('0x17'),_0x50780e[_0x766890('0x23')]),'trigger:browser:url',{'uri':'https://crm.'+_0x186d2f[_0x766890('0x78')]+'/crm/EntityInfo.do?module=Calls&id='+_0x24523f['id']}));})[_0x549362('0x82')](function(_0x4c9190){const _0x1f6699=_0x549362;logger[_0x1f6699('0x3a')](_0x1f6699('0x35'),JSON[_0x1f6699('0x2d')](_0x4c9190));});},exports[_0x18e329('0x26')]=function(_0x3f2a9f,_0x11e891,_0x28ef60,_0x5587ac,_0x1e1e72,_0x1b3740,_0x1ae578){const _0x476735=_0x18e329;let _0x18e4e7,_0x3b8616,_0x5a2c8c;_0x1b3740[_0x476735('0x78')]=intUtil['stripTrailingSlash'](_0x1b3740[_0x476735('0x78')]),_0x1b3740[_0x476735('0x69')]=intUtil[_0x476735('0x25')](_0x1b3740[_0x476735('0x69')]);_0x1ae578&&_0x1ae578[_0x476735('0x73')]&&_0x1ae578[_0x476735('0x73')]!=='none'&&(logger[_0x476735('0x3')](_0x476735('0x5e'),_0x476735('0x65')),_0x11e891[_0x476735('0x14')]=_0x1b3740[_0x476735('0x69')]+'/api/voice/recordings/'+_0x11e891[_0x476735('0x13')]+_0x476735('0x0')+md5(_0x11e891['uniqueid']));const _0x1dbdb2=_0x1b3740[_0x476735('0x78')]===_0x476735('0x6e')?'eu':_0x476735('0x33');return getAccessToken(_0x1b3740)[_0x476735('0x89')](function(_0x28e77e){const _0x3bd23c=_0x476735;return _0x5a2c8c=_0x28e77e,getUser(_0x5a2c8c,_0x1dbdb2,_0x1b3740,_0x5587ac[_0x3bd23c('0x39')]);})[_0x476735('0x89')](function(_0x228a48){const _0x5a23a4=_0x476735;return _0x18e4e7=_0x228a48,logger[_0x5a23a4('0x3')](_0x5a23a4('0x46'),_0x18e4e7['id']),getEndUser(_0x5a2c8c,_0x1dbdb2,_0x1b3740,_0x11e891[_0x5a23a4('0x7')],_0x11e891[_0x5a23a4('0x8e')],_0x18e4e7,_0x28ef60);})[_0x476735('0x89')](function(_0x4ff12c){return _0x3b8616=_0x4ff12c,getCall(_0x5a2c8c,_0x1dbdb2,_0x1b3740,_0x18e4e7,_0x3b8616,_0x28ef60,_0x11e891,'Outbound');})[_0x476735('0x89')](function(_0x24f99b){const _0x27d1e4=_0x476735;_0x24f99b&&(logger['info'](_0x27d1e4('0xf'),_0x24f99b['id']),logger[_0x27d1e4('0x3')]('[OUTBOUND]',_0x27d1e4('0x83')),emit(util[_0x27d1e4('0x16')](_0x27d1e4('0x17'),_0x5587ac[_0x27d1e4('0x23')]),_0x27d1e4('0x20'),{'uri':_0x27d1e4('0x2e')+_0x1b3740[_0x27d1e4('0x78')]+_0x27d1e4('0x41')+_0x24f99b['id']}));})[_0x476735('0x82')](function(_0x365cf3){const _0x1df807=_0x476735;logger[_0x1df807('0x3a')](_0x1df807('0x5e'),JSON[_0x1df807('0x2d')](_0x365cf3));});},exports[_0x18e329('0xa')]=function(_0x4c5e70,_0x2d15e8,_0x53ba10,_0x42422,_0x14c216,_0x16862f){const _0x51d4ec=_0x18e329;let _0x21aa7c,_0x5978d4,_0x159398;_0x16862f[_0x51d4ec('0x78')]=intUtil[_0x51d4ec('0x25')](_0x16862f[_0x51d4ec('0x78')]),_0x16862f['serverUrl']=intUtil['stripTrailingSlash'](_0x16862f[_0x51d4ec('0x69')]);_0x14c216&&_0x14c216['monitor_format']?(logger[_0x51d4ec('0x3')]('['+_0x2d15e8[_0x51d4ec('0x56')][_0x51d4ec('0x3f')]()+']',_0x51d4ec('0x65')),_0x2d15e8['recordingURL']=_0x16862f[_0x51d4ec('0x69')]+_0x51d4ec('0x37')+_0x2d15e8[_0x51d4ec('0x13')]+'/downloads?type=uniqueid&token='+md5(_0x2d15e8[_0x51d4ec('0x13')])):_0x2d15e8[_0x51d4ec('0x14')]='';const _0x22b55e=_0x16862f[_0x51d4ec('0x78')]===_0x51d4ec('0x6e')?'eu':_0x51d4ec('0x33');return getAccessToken(_0x16862f)[_0x51d4ec('0x89')](function(_0x389eb1){return _0x159398=_0x389eb1,getUser(_0x159398,_0x22b55e,_0x16862f);})['then'](function(_0x290633){const _0x23c314=_0x51d4ec;return _0x21aa7c=_0x290633,logger[_0x23c314('0x3')](_0x23c314('0x46'),_0x21aa7c['id']),getEndUser(_0x159398,_0x22b55e,_0x16862f,_0x2d15e8[_0x23c314('0x7e')],_0x2d15e8['calleridnum'],_0x21aa7c,_0x53ba10);})[_0x51d4ec('0x89')](function(_0xb90d56){return _0x5978d4=_0xb90d56,getCall(_0x159398,_0x22b55e,_0x16862f,_0x21aa7c,_0x5978d4,_0x53ba10,_0x2d15e8,'Inbound');})[_0x51d4ec('0x89')](function(_0x5e79bd){const _0x30f4d8=_0x51d4ec;_0x5e79bd&&logger[_0x30f4d8('0x3')]('The\x20Call\x20ID\x20is:',_0x5e79bd['id']);})[_0x51d4ec('0x82')](function(_0x35abaf){const _0x28ed38=_0x51d4ec;logger[_0x28ed38('0x3a')]('['+_0x2d15e8[_0x28ed38('0x56')][_0x28ed38('0x3f')]()+']',JSON['stringify'](_0x35abaf));});}; \ No newline at end of file +const a1147_0x469b=['role','request-promise-native','profile','info','calleridnum','https://crm.','enduserType','idField','The\x20failing\x20result\x20is','uri','zoho','agentcalledAt','name','Unable\x20to\x20retrieve\x20zoho\x20account\x20users:\x20','refreshToken','md5','err','Creating\x20new\x20call...','Called','https://www.zohoapis.%s/crm/v2/users','Who_Id','recordingURL','[OUTBOUND]','Failing\x20creating\x20the\x20access_token','First_Name','mm:ss','administrator','debug','serverUrl','refresh_token','Agent\x20found!','toUpperCase','/crm/v2/','[HTTP]','Call_Duration','startCase','called','starttime','https://accounts.zoho.eu','Last_Name','https://www.zohoapis.','complete','merge','The\x20User\x20ID\x20is:','Answered','timeout','Administrator','Timeout','stringify','ActiveUsers','./util','Displaying\x20call\x20to\x20agent\x20in\x20a\x20new\x20tab...','Error:\x20','variableName','../../../../config/logger','queue','variable','clientSecret','/api/voice/recordings/','destcalleridnum','Using\x20the\x20admin\x20account!','Subject','/crm/v2/Leads/search?criteria=((Phone:equals:','details','unmanaged','Call_Start_Time','Full_Name','then','user','calleridname','user:%s','split','toString','catch','isNil','first_name','The\x20Call\x20ID\x20is:','https://accounts.zoho.com.au','YYYY-MM-DDTHH:mm:ss','stack','rejected','https://accounts.zoho.in','Recording\x20is\x20enabled!','last_name','seconds','outbound','expires_in','nothing','diff','Call_Result','format','uniqueid','none','contact','users','GET','forEach','monitor_format','https://accounts.zoho.com','Variable','Leads','contact_lead','type','Call_Type','talktime','data','lastevent','moduleCreate','../../../../rediscache','isBefore','Contacts','/oauth/v2/token','add','[QUEUE]','utc','/downloads?type=uniqueid&token=','lodash','error','endtime','toLowerCase','host','Owner','content','https://accounts.zoho.com.cn','code','log','abandoned','SUCCESS','Zoho-oauthtoken\x20','indexOf','email','getString','trigger:browser:url','zoho.eu','length','/crm/v2/Contacts/search?criteria=((Phone:equals:','Abandoned','com','zone','moment','lead','clientId','/crm/v2/Calls','access_token','Outbound','emit','findIndex','POST','stripTrailingSlash','connect','Inbound','Fields'];(function(_0x4476eb,_0x469b9b){const _0x54c7fb=function(_0xb17cdc){while(--_0xb17cdc){_0x4476eb['push'](_0x4476eb['shift']());}};_0x54c7fb(++_0x469b9b);}(a1147_0x469b,0x79));const a1147_0x54c7=function(_0x4476eb,_0x469b9b){_0x4476eb=_0x4476eb-0x0;let _0x54c7fb=a1147_0x469b[_0x4476eb];return _0x54c7fb;};const _0x3b78f4=a1147_0x54c7;'use strict';const _=require(_0x3b78f4('0x93')),rp=require(_0x3b78f4('0x20')),md5=require(_0x3b78f4('0x2e')),util=require('util'),intUtil=require(_0x3b78f4('0x51')),moment=require(_0x3b78f4('0x12')),logger=require(_0x3b78f4('0x55'))(_0x3b78f4('0x29')),{getSocket}=require(_0x3b78f4('0x8b')),io=getSocket();function emit(_0xb17cdc,_0x48e141,_0x4466ec){const _0x60014a=_0x3b78f4;io['to'](_0xb17cdc)[_0x60014a('0x18')](_0x48e141,_0x4466ec);}function request(_0x4cec95){const _0x44699f=_0x3b78f4;return logger[_0x44699f('0x3a')](_0x44699f('0x40'),JSON['stringify'](_0x4cec95)),rp(_0x4cec95);}function getCustomFields(_0x18f3e4,_0x4556c4){const _0x1f20d7=_0x3b78f4,_0x430a2c={};return _0x18f3e4[_0x1f20d7('0xd')]>0x0&&_[_0x1f20d7('0x7f')](_0x18f3e4,function(_0x2536bc){const _0x2b65e3=_0x1f20d7;if(_0x2536bc[_0x2b65e3('0x85')]==='string'&&_0x2536bc[_0x2b65e3('0x26')])_0x430a2c[_0x2536bc[_0x2b65e3('0x26')]]=_0x2536bc[_0x2b65e3('0x1')][_0x2b65e3('0x67')]();else{if(_0x2536bc[_0x2b65e3('0x85')]===_0x2b65e3('0x57')&&_0x2536bc[_0x2b65e3('0x54')]&&_0x2536bc[_0x2b65e3('0x26')]&&_0x4556c4[_0x2536bc[_0x2b65e3('0x54')]])_0x430a2c[_0x2536bc['idField']]=_0x4556c4[_0x2536bc[_0x2b65e3('0x54')]][_0x2b65e3('0x67')]();else _0x2536bc[_0x2b65e3('0x85')]==='customVariable'&&_0x2536bc[_0x2b65e3('0x82')]&&_0x2536bc[_0x2b65e3('0x82')][_0x2b65e3('0x2b')]&&_0x2536bc[_0x2b65e3('0x26')]&&_0x4556c4[_0x2536bc[_0x2b65e3('0x82')][_0x2b65e3('0x2b')][_0x2b65e3('0x96')]()]&&(_0x430a2c[_0x2536bc[_0x2b65e3('0x26')]]=_0x4556c4[_0x2536bc[_0x2b65e3('0x82')][_0x2b65e3('0x2b')][_0x2b65e3('0x96')]()][_0x2b65e3('0x67')]());}}),_0x430a2c;}function getName(_0xb9026d){const _0x53198b=_0x3b78f4;if(_0xb9026d[_0x53198b('0x8')]('\x20')>0x0){const _0x282655=_0xb9026d[_0x53198b('0x66')](/ (.+)/);if(_0x282655[0x1])return _0x282655;}return[_0xb9026d,_0xb9026d];}const accountsTokens={};function getAccessToken(_0x1ba9d5){return new Promise(function(_0x58c982,_0x5b3224){const _0x431403=a1147_0x54c7;!_[_0x431403('0x69')](accountsTokens[_0x1ba9d5['id']])&&!_[_0x431403('0x69')](accountsTokens[_0x1ba9d5['id']][_0x431403('0x16')])&&(moment()[_0x431403('0x8c')](accountsTokens[_0x1ba9d5['id']][_0x431403('0x75')])&&_0x58c982(accountsTokens[_0x1ba9d5['id']][_0x431403('0x16')]));let _0x21107c;switch(_0x1ba9d5[_0x431403('0x11')]){case'US':_0x21107c=_0x431403('0x81');break;case'AU':_0x21107c=_0x431403('0x6c');break;case'EU':_0x21107c=_0x431403('0x45');break;case'IN':_0x21107c=_0x431403('0x70');break;case'CN':_0x21107c=_0x431403('0x2');break;default:_0x21107c='https://accounts.zoho.eu';break;}const _0x47b3b3={'method':'POST','uri':_0x21107c+_0x431403('0x8e'),'qs':{'refresh_token':_0x1ba9d5[_0x431403('0x2d')],'client_id':_0x1ba9d5[_0x431403('0x14')],'client_secret':_0x1ba9d5[_0x431403('0x58')],'grant_type':_0x431403('0x3c')},'json':!![]};return rp(_0x47b3b3)[_0x431403('0x62')](function(_0x503b94){const _0x476e12=_0x431403;accountsTokens[_0x1ba9d5['id']]={'access_token':_0x503b94[_0x476e12('0x16')],'expires_in':moment()[_0x476e12('0x8f')](_0x503b94[_0x476e12('0x75')],_0x476e12('0x73'))},_0x58c982(_0x503b94[_0x476e12('0x16')]);})[_0x431403('0x68')](function(_0x29c92d){const _0x551760=_0x431403;logger[_0x551760('0x94')](_0x551760('0x36'),_0x29c92d[_0x551760('0x6e')]),_0x5b3224(_0x29c92d);});});}function getUser(_0x66b12d,_0x58e9a3,_0x2775f3,_0x200a46){const _0xa28704=_0x3b78f4;return logger[_0xa28704('0x22')]('Search\x20user'),request({'method':_0xa28704('0x7e'),'uri':util[_0xa28704('0x79')](_0xa28704('0x32'),_0x58e9a3),'qs':{'type':_0xa28704('0x50')},'headers':{'Authorization':_0xa28704('0x7')+_0x66b12d},'json':!![]})['then'](function(_0x15aa18){const _0x56f660=_0xa28704;if(_0x15aa18[_0x56f660('0x7d')]){let _0x56774d=-0x1;if(_['isArrayLikeObject'](_0x15aa18[_0x56f660('0x7d')]))return!_[_0x56f660('0x69')](_0x200a46)&&(_0x56774d=_[_0x56f660('0x19')](_0x15aa18['users'],function(_0xf56953){const _0x2f41a=_0x56f660;return _0xf56953[_0x2f41a('0x9')]===_0x200a46;})),_0x56774d>=0x0?logger[_0x56f660('0x22')](_0x56f660('0x3d')):(logger[_0x56f660('0x22')]('Using\x20the\x20admin\x20account!'),_0x56774d=_[_0x56f660('0x19')](_0x15aa18[_0x56f660('0x7d')],function(_0x4ca263){const _0x7ffe98=_0x56f660;return _0x4ca263[_0x7ffe98('0x21')][_0x7ffe98('0x2b')]===_0x7ffe98('0x4d');})),_0x15aa18[_0x56f660('0x7d')][_0x56774d];else{if(_0x15aa18[_0x56f660('0x63')][_0x56f660('0x21')][_0x56f660('0x2b')]===_0x56f660('0x4d')){logger['info'](_0x56f660('0x5b'));const _0x5722de=_0x15aa18['user'];return _0x5722de;}else{logger['error'](_0x56f660('0x27'),JSON[_0x56f660('0x4f')](_0x15aa18));throw new Error(_0x56f660('0x2c')+JSON[_0x56f660('0x4f')](_0x15aa18));}}}else{logger['error'](_0x56f660('0x27'),JSON['stringify'](_0x15aa18));throw new Error(_0x56f660('0x2c')+JSON[_0x56f660('0x4f')](_0x15aa18));}})[_0xa28704('0x68')](function(_0x55096f){console['error'](_0x55096f);});}function getZohoUser(_0x84a68c,_0x717c20){return new Promise(function(_0x1a5e4b,_0x33099c){const _0x1ca509=a1147_0x54c7;request(_0x84a68c)[_0x1ca509('0x62')](function(_0x2dd97d){const _0x331aae=_0x1ca509;let _0x28a92f=null;_0x2dd97d&&(_0x28a92f=_0x2dd97d[_0x331aae('0x88')][0x0],_0x28a92f[_0x331aae('0x25')]=_0x717c20),_0x1a5e4b(_0x28a92f);})['catch'](function(_0x38c25f){_0x33099c(_0x38c25f);});});}function createEndUser(_0x21055f,_0x4209df,_0x3c74b5,_0x313566,_0x329581,_0x136c9a){const _0x291ffe=_0x3b78f4;return _0x3c74b5=getName(_0x3c74b5),request({'method':_0x291ffe('0x1a'),'uri':_0x291ffe('0x47')+_0x4209df+_0x291ffe('0x3f')+_[_0x291ffe('0x42')](_0x136c9a[_0x291ffe('0x8a')])+'s','body':{'data':[{'Last_Name':_0x3c74b5[0x1],'First_Name':_0x3c74b5[0x0],'Phone':_0x313566,'Owner':{'name':!_[_0x291ffe('0x69')](_0x329581[_0x291ffe('0x1f')][_0x291ffe('0x2b')])?_0x329581[_0x291ffe('0x1f')]['name']:!_['isNil'](_0x329581[_0x291ffe('0x6a')])?_0x329581['first_name']+'\x20'+_0x329581[_0x291ffe('0x72')]:_0x329581[_0x291ffe('0x72')],'id':_0x329581['id']}}]},'headers':{'Authorization':_0x291ffe('0x7')+_0x21055f},'json':!![]})['then'](function(_0x4812cd){const _0x469690=_0x291ffe;if(_0x4812cd&&_0x4812cd[_0x469690('0x88')][0x0][_0x469690('0x3')]==='SUCCESS'){const _0x3c4158=_0x4812cd[_0x469690('0x88')][0x0][_0x469690('0x5e')];return _0x3c4158['enduserType']=_[_0x469690('0x42')](_0x136c9a[_0x469690('0x8a')])+'s',_0x3c4158;}const _0x53e1d2=_0x4812cd[_0x469690('0x88')];logger[_0x469690('0x94')](_0x469690('0x27'),JSON[_0x469690('0x4f')](_0x53e1d2));throw new Error(_0x469690('0x53')+JSON[_0x469690('0x4f')](_0x53e1d2));})[_0x291ffe('0x68')](function(_0x56a66c){console['log']('CREATE\x20ERROR',_0x56a66c);});}function getEndUser(_0x598f88,_0x541d00,_0x343ebb,_0x4ed941,_0x1f44e9,_0xd0d6ff,_0x4dc070){const _0x59046f=_0x3b78f4,_0x740bf8={'method':_0x59046f('0x7e'),'uri':'','headers':{'Authorization':'Zoho-oauthtoken\x20'+_0x598f88},'json':!![]};switch(_0x4dc070['moduleSearch']){case _0x59046f('0x84'):_0x740bf8[_0x59046f('0x28')]=_0x59046f('0x47')+_0x541d00+_0x59046f('0xe')+_0x1f44e9+'))';return getZohoUser(_0x740bf8,'Contacts')[_0x59046f('0x62')](function(_0x4f6aed){const _0x1e3628=_0x59046f;if(_0x4f6aed)return _0x4f6aed;return _0x740bf8[_0x1e3628('0x28')]=_0x1e3628('0x47')+_0x541d00+_0x1e3628('0x5d')+_0x1f44e9+'))',getZohoUser(_0x740bf8,_0x1e3628('0x83'))['then'](function(_0x4588cb){const _0x101d94=_0x1e3628;if(_0x4588cb)return _0x4588cb;return _0x4dc070[_0x101d94('0x8a')]!=_0x101d94('0x76')?createEndUser(_0x598f88,_0x541d00,_0x4ed941,_0x1f44e9,_0xd0d6ff,_0x4dc070):{};});});case _0x59046f('0x7c'):_0x740bf8[_0x59046f('0x28')]=_0x59046f('0x47')+_0x541d00+_0x59046f('0xe')+_0x1f44e9+'))';return getZohoUser(_0x740bf8,_0x59046f('0x8d'))['then'](function(_0x489c75){const _0x3454b0=_0x59046f;if(_0x489c75)return _0x489c75;return _0x4dc070[_0x3454b0('0x8a')]!='nothing'?createEndUser(_0x598f88,_0x541d00,_0x4ed941,_0x1f44e9,_0xd0d6ff,_0x4dc070):{};});case _0x59046f('0x13'):_0x740bf8[_0x59046f('0x28')]='https://www.zohoapis.'+_0x541d00+_0x59046f('0x5d')+_0x1f44e9+'))';return getZohoUser(_0x740bf8,_0x59046f('0x83'))[_0x59046f('0x62')](function(_0x1c9c3a){const _0x26723d=_0x59046f;if(_0x1c9c3a)return _0x1c9c3a;return _0x4dc070[_0x26723d('0x8a')]!='nothing'?createEndUser(_0x598f88,_0x541d00,_0x4ed941,_0x1f44e9,_0xd0d6ff,_0x4dc070):{};});}}function getCall(_0x476d33,_0xc0955f,_0x28f281,_0x4e492e,_0x24001f,_0x5de606,_0x597acc,_0x518858){const _0x522ae7=_0x3b78f4;logger[_0x522ae7('0x22')](_0x522ae7('0x30'));let _0x1f0895={};_0x1f0895[_0x522ae7('0x0')]={'name':!_[_0x522ae7('0x69')](_0x4e492e[_0x522ae7('0x1f')][_0x522ae7('0x2b')])&&!_[_0x522ae7('0x69')](_0x4e492e[_0x522ae7('0x21')][_0x522ae7('0x2b')])&&_0x4e492e[_0x522ae7('0x21')][_0x522ae7('0x2b')]===_0x522ae7('0x39')?_0x4e492e[_0x522ae7('0x1f')]['name']:!_[_0x522ae7('0x69')](_0x4e492e['first_name'])?_0x4e492e[_0x522ae7('0x6a')]+'\x20'+_0x4e492e[_0x522ae7('0x72')]:_0x4e492e[_0x522ae7('0x72')],'id':_0x4e492e['id']},_0x1f0895[_0x522ae7('0x5c')]=intUtil['getString'](_0x5de606['Subjects'],_0x597acc,'\x20'),_0x1f0895['Description']=intUtil[_0x522ae7('0xa')](_0x5de606['Descriptions'],_0x597acc,'\x0a');_0x24001f['enduserType']===_0x522ae7('0x8d')&&(_0x1f0895[_0x522ae7('0x33')]={'name':!_['isNil'](_0x24001f[_0x522ae7('0x61')])?_0x24001f[_0x522ae7('0x61')]:!_[_0x522ae7('0x69')](_0x24001f[_0x522ae7('0x37')])?_0x24001f[_0x522ae7('0x37')]+'\x20'+_0x24001f[_0x522ae7('0x46')]:_0x24001f[_0x522ae7('0x46')],'id':_0x24001f['id']});_0x24001f[_0x522ae7('0x25')]===_0x522ae7('0x83')&&(_0x1f0895['What_Id']={'name':!_[_0x522ae7('0x69')](_0x24001f[_0x522ae7('0x61')])?_0x24001f[_0x522ae7('0x61')]:!_[_0x522ae7('0x69')](_0x24001f[_0x522ae7('0x37')])?_0x24001f[_0x522ae7('0x37')]+'\x20'+_0x24001f[_0x522ae7('0x46')]:_0x24001f[_0x522ae7('0x46')],'id':_0x24001f['id']},_0x1f0895['$se_module']=_[_0x522ae7('0x42')](_0x24001f[_0x522ae7('0x25')]));if(_0x597acc[_0x522ae7('0x87')])_0x1f0895[_0x522ae7('0x41')]=moment[_0x522ae7('0x91')](parseInt(_0x597acc[_0x522ae7('0x87')])*0x3e8)['format'](_0x522ae7('0x38'));else _0x597acc['answertime']&&_0x597acc[_0x522ae7('0x95')]&&(_0x1f0895['Call_Duration']=moment[_0x522ae7('0x91')](moment(_0x597acc[_0x522ae7('0x95')],_0x522ae7('0x6d'))[_0x522ae7('0x77')](moment(_0x597acc[_0x522ae7('0x44')],'YYYY-MM-DDTHH:mm:ss')))['format'](_0x522ae7('0x38')));switch(_0x597acc['lastevent']){case _0x522ae7('0x43'):_0x1f0895[_0x522ae7('0x78')]=_0x522ae7('0x31');break;case _0x522ae7('0x48'):case _0x522ae7('0x1c'):_0x1f0895[_0x522ae7('0x78')]=_0x522ae7('0x4b');break;case _0x522ae7('0x6f'):_0x1f0895[_0x522ae7('0x78')]='Rejected';break;case _0x522ae7('0x5'):_0x1f0895[_0x522ae7('0x78')]=_0x522ae7('0xf');break;case _0x522ae7('0x4c'):_0x1f0895[_0x522ae7('0x78')]=_0x522ae7('0x4e');break;default:break;}return _0x1f0895[_0x522ae7('0x60')]=(_0x518858===_0x522ae7('0x74')?moment(_0x597acc[_0x522ae7('0x44')])['format']('YYYY-MM-DDTHH:mm:ss'):moment(_0x597acc[_0x522ae7('0x2a')])['format'](_0x522ae7('0x6d')))||moment()[_0x522ae7('0x79')](_0x522ae7('0x6d')),_0x1f0895[_0x522ae7('0x86')]=_0x518858||_0x522ae7('0x1d'),_0x1f0895=_[_0x522ae7('0x49')](_0x1f0895,getCustomFields(_0x5de606[_0x522ae7('0x1e')],_0x597acc)),request({'method':_0x522ae7('0x1a'),'uri':_0x522ae7('0x47')+_0xc0955f+_0x522ae7('0x15'),'headers':{'Authorization':_0x522ae7('0x7')+_0x476d33},'body':{'data':[_0x1f0895]},'json':!![]})['then'](function(_0x33fa87){const _0x4bb997=_0x522ae7;if(_0x33fa87&&_0x33fa87[_0x4bb997('0x88')][0x0][_0x4bb997('0x3')]===_0x4bb997('0x6'))return logger[_0x4bb997('0x22')]('Call\x20created!'),{'id':_0x33fa87[_0x4bb997('0x88')][0x0][_0x4bb997('0x5e')]['id']};})[_0x522ae7('0x68')](function(_0x3aa61c){const _0x4a3009=_0x522ae7;logger[_0x4a3009('0x22')](_0x4a3009('0x2f'),_0x3aa61c[_0x4a3009('0x6e')]),console[_0x4a3009('0x4')]('err',_0x3aa61c);});}exports[_0x3b78f4('0x56')]=function(_0xa6c8b8,_0x1dc7b7,_0x1c1d08,_0x453910,_0x489209,_0x38064e){const _0x37ac3c=_0x3b78f4;let _0x27345b,_0x5e9588,_0x3a67ac;_0x38064e['host']=intUtil[_0x37ac3c('0x1b')](_0x38064e['host']),_0x38064e[_0x37ac3c('0x3b')]=intUtil[_0x37ac3c('0x1b')](_0x38064e[_0x37ac3c('0x3b')]);_0x489209&&_0x489209[_0x37ac3c('0x80')]?(logger[_0x37ac3c('0x22')]('[QUEUE]',_0x37ac3c('0x71')),_0x1dc7b7[_0x37ac3c('0x34')]=_0x38064e[_0x37ac3c('0x3b')]+_0x37ac3c('0x59')+_0x1dc7b7['uniqueid']+_0x37ac3c('0x92')+md5(_0x1dc7b7[_0x37ac3c('0x7a')])):_0x1dc7b7[_0x37ac3c('0x34')]='';const _0x167709=_0x38064e[_0x37ac3c('0x97')]==='zoho.eu'?'eu':_0x37ac3c('0x10');return getAccessToken(_0x38064e)[_0x37ac3c('0x62')](function(_0x4baf5b){const _0x1e5b5f=_0x37ac3c;return _0x3a67ac=_0x4baf5b,getUser(_0x3a67ac,_0x167709,_0x38064e,_0x453910[_0x1e5b5f('0x9')]);})['then'](function(_0x3dd0c0){const _0x5b9c31=_0x37ac3c;return _0x27345b=_0x3dd0c0,logger[_0x5b9c31('0x22')](_0x5b9c31('0x4a'),_0x27345b['id']),getEndUser(_0x3a67ac,_0x167709,_0x38064e,_0x1dc7b7[_0x5b9c31('0x64')],_0x1dc7b7[_0x5b9c31('0x23')],_0x27345b,_0x1c1d08);})[_0x37ac3c('0x62')](function(_0x5b9e6d){const _0x261d4c=_0x37ac3c;return _0x5e9588=_0x5b9e6d,getCall(_0x3a67ac,_0x167709,_0x38064e,_0x27345b,_0x5e9588,_0x1c1d08,_0x1dc7b7,_0x261d4c('0x1d'));})[_0x37ac3c('0x62')](function(_0x19bd1d){const _0x3d1feb=_0x37ac3c;_0x19bd1d&&(logger[_0x3d1feb('0x22')]('The\x20Call\x20ID\x20is:',_0x19bd1d['id']),logger[_0x3d1feb('0x22')](_0x3d1feb('0x90'),'Displaying\x20call\x20to\x20agent\x20in\x20a\x20new\x20tab...'),emit(util[_0x3d1feb('0x79')](_0x3d1feb('0x65'),_0x453910['name']),_0x3d1feb('0xb'),{'uri':_0x3d1feb('0x24')+_0x38064e[_0x3d1feb('0x97')]+'/crm/EntityInfo.do?module=Calls&id='+_0x19bd1d['id']}));})['catch'](function(_0x2de82b){const _0x42501a=_0x37ac3c;logger[_0x42501a('0x94')]('[QUEUE]',JSON['stringify'](_0x2de82b));});},exports['outbound']=function(_0x43b425,_0x32c729,_0x549c91,_0x24ef05,_0x326350,_0x373d82,_0x3f240f){const _0x2c1469=_0x3b78f4;let _0x3e5ae2,_0x525b3b,_0x457d0c;_0x373d82[_0x2c1469('0x97')]=intUtil[_0x2c1469('0x1b')](_0x373d82[_0x2c1469('0x97')]),_0x373d82[_0x2c1469('0x3b')]=intUtil['stripTrailingSlash'](_0x373d82[_0x2c1469('0x3b')]);_0x3f240f&&_0x3f240f['recordingFormat']&&_0x3f240f['recordingFormat']!==_0x2c1469('0x7b')&&(logger[_0x2c1469('0x22')](_0x2c1469('0x35'),_0x2c1469('0x71')),_0x32c729[_0x2c1469('0x34')]=_0x373d82[_0x2c1469('0x3b')]+_0x2c1469('0x59')+_0x32c729['uniqueid']+_0x2c1469('0x92')+md5(_0x32c729['uniqueid']));const _0x586db8=_0x373d82['host']===_0x2c1469('0xc')?'eu':'com';return getAccessToken(_0x373d82)[_0x2c1469('0x62')](function(_0x2ed43d){const _0x52290d=_0x2c1469;return _0x457d0c=_0x2ed43d,getUser(_0x457d0c,_0x586db8,_0x373d82,_0x24ef05[_0x52290d('0x9')]);})[_0x2c1469('0x62')](function(_0x21d4fe){const _0x4eb666=_0x2c1469;return _0x3e5ae2=_0x21d4fe,logger[_0x4eb666('0x22')](_0x4eb666('0x4a'),_0x3e5ae2['id']),getEndUser(_0x457d0c,_0x586db8,_0x373d82,_0x32c729['destcalleridname'],_0x32c729[_0x4eb666('0x5a')],_0x3e5ae2,_0x549c91);})[_0x2c1469('0x62')](function(_0x59d316){const _0x43b68a=_0x2c1469;return _0x525b3b=_0x59d316,getCall(_0x457d0c,_0x586db8,_0x373d82,_0x3e5ae2,_0x525b3b,_0x549c91,_0x32c729,_0x43b68a('0x17'));})[_0x2c1469('0x62')](function(_0x3b8042){const _0x41fb2d=_0x2c1469;_0x3b8042&&(logger[_0x41fb2d('0x22')](_0x41fb2d('0x6b'),_0x3b8042['id']),logger['info'](_0x41fb2d('0x35'),_0x41fb2d('0x52')),emit(util[_0x41fb2d('0x79')]('user:%s',_0x24ef05[_0x41fb2d('0x2b')]),_0x41fb2d('0xb'),{'uri':_0x41fb2d('0x24')+_0x373d82[_0x41fb2d('0x97')]+'/crm/EntityInfo.do?module=Calls&id='+_0x3b8042['id']}));})[_0x2c1469('0x68')](function(_0x58f329){const _0x5ddc6c=_0x2c1469;logger[_0x5ddc6c('0x94')]('[OUTBOUND]',JSON[_0x5ddc6c('0x4f')](_0x58f329));});},exports[_0x3b78f4('0x5f')]=function(_0x5037d9,_0x3792f9,_0x5a93ec,_0x106d3b,_0x5e72ad,_0x54492c){const _0x1d2b99=_0x3b78f4;let _0x19ef01,_0x48ca02,_0x4f755d;_0x54492c[_0x1d2b99('0x97')]=intUtil[_0x1d2b99('0x1b')](_0x54492c[_0x1d2b99('0x97')]),_0x54492c[_0x1d2b99('0x3b')]=intUtil['stripTrailingSlash'](_0x54492c[_0x1d2b99('0x3b')]);_0x5e72ad&&_0x5e72ad[_0x1d2b99('0x80')]?(logger[_0x1d2b99('0x22')]('['+_0x3792f9[_0x1d2b99('0x89')]['toUpperCase']()+']',_0x1d2b99('0x71')),_0x3792f9['recordingURL']=_0x54492c[_0x1d2b99('0x3b')]+_0x1d2b99('0x59')+_0x3792f9['uniqueid']+_0x1d2b99('0x92')+md5(_0x3792f9[_0x1d2b99('0x7a')])):_0x3792f9['recordingURL']='';const _0xd9f335=_0x54492c[_0x1d2b99('0x97')]===_0x1d2b99('0xc')?'eu':'com';return getAccessToken(_0x54492c)[_0x1d2b99('0x62')](function(_0x4737ae){return _0x4f755d=_0x4737ae,getUser(_0x4f755d,_0xd9f335,_0x54492c);})[_0x1d2b99('0x62')](function(_0x3b4804){const _0x59f9c1=_0x1d2b99;return _0x19ef01=_0x3b4804,logger[_0x59f9c1('0x22')](_0x59f9c1('0x4a'),_0x19ef01['id']),getEndUser(_0x4f755d,_0xd9f335,_0x54492c,_0x3792f9[_0x59f9c1('0x64')],_0x3792f9[_0x59f9c1('0x23')],_0x19ef01,_0x5a93ec);})[_0x1d2b99('0x62')](function(_0x170066){return _0x48ca02=_0x170066,getCall(_0x4f755d,_0xd9f335,_0x54492c,_0x19ef01,_0x48ca02,_0x5a93ec,_0x3792f9,'Inbound');})[_0x1d2b99('0x62')](function(_0x2ea3ab){const _0x55048d=_0x1d2b99;_0x2ea3ab&&logger[_0x55048d('0x22')](_0x55048d('0x6b'),_0x2ea3ab['id']);})['catch'](function(_0x9de613){const _0xac1ebf=_0x1d2b99;logger['error']('['+_0x3792f9[_0xac1ebf('0x89')][_0xac1ebf('0x3e')]()+']',JSON[_0xac1ebf('0x4f')](_0x9de613));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/script/index.js b/server/services/ami/trigger/script/index.js index b0c8745..2d52dc7 100644 --- a/server/services/ami/trigger/script/index.js +++ b/server/services/ami/trigger/script/index.js @@ -1 +1 @@ -const a1148_0x5f1b=['data2','mustache','%s\x20\x27%s\x27\x20succeeded\x20with\x20output:\x20%s','info','format','%s\x20\x27%s\x27\x20failed\x20with\x20code\x20%d\x20and\x20error:\x20%s','Script','trigger','data3','shelljs','error','exec'];(function(_0x26a7e4,_0x5f1b55){const _0x1918cb=function(_0x59e145){while(--_0x59e145){_0x26a7e4['push'](_0x26a7e4['shift']());}};_0x1918cb(++_0x5f1b55);}(a1148_0x5f1b,0xeb));const a1148_0x1918=function(_0x26a7e4,_0x5f1b55){_0x26a7e4=_0x26a7e4-0x0;let _0x1918cb=a1148_0x5f1b[_0x26a7e4];return _0x1918cb;};const _0x1e81e1=a1148_0x1918;'use strict';const util=require('util'),sh=require(_0x1e81e1('0x2')),Mustache=require(_0x1e81e1('0x6')),logger=require('../../../../config/logger')(_0x1e81e1('0x0'));exports['exec']=function(_0x59e145,_0x40552d){const _0x1a3a77=_0x1e81e1,_0x4204c7=_0x59e145[_0x1a3a77('0x5')]?_0x59e145[_0x1a3a77('0x5')]:_0x1a3a77('0xb'),_0x229e2b=_0x59e145[_0x1a3a77('0x1')]?Mustache['render'](_0x59e145['data3'],_0x40552d):_0x40552d;sh[_0x1a3a77('0x4')](_0x229e2b,function(_0x541046,_0x30c021,_0x58f50f){const _0xf65734=_0x1a3a77;_0x541046!==0x0?logger[_0xf65734('0x3')](util[_0xf65734('0x9')](_0xf65734('0xa'),_0x4204c7,_0x229e2b,_0x541046,_0x58f50f)):logger[_0xf65734('0x8')](util[_0xf65734('0x9')](_0xf65734('0x7'),_0x4204c7,_0x229e2b,_0x30c021));});}; \ No newline at end of file +const a1148_0x4068=['mustache','format','trigger','%s\x20\x27%s\x27\x20succeeded\x20with\x20output:\x20%s','exec','data3','shelljs','Script','render','info'];(function(_0x4055c2,_0x4068b1){const _0x33234c=function(_0x52b247){while(--_0x52b247){_0x4055c2['push'](_0x4055c2['shift']());}};_0x33234c(++_0x4068b1);}(a1148_0x4068,0x1c4));const a1148_0x3323=function(_0x4055c2,_0x4068b1){_0x4055c2=_0x4055c2-0x0;let _0x33234c=a1148_0x4068[_0x4055c2];return _0x33234c;};const _0xfa7b8d=a1148_0x3323;'use strict';const util=require('util'),sh=require(_0xfa7b8d('0x4')),Mustache=require(_0xfa7b8d('0x8')),logger=require('../../../../config/logger')(_0xfa7b8d('0x0'));exports[_0xfa7b8d('0x2')]=function(_0x52b247,_0x2805f4){const _0x133b8b=_0xfa7b8d,_0x436c1e=_0x52b247['data2']?_0x52b247['data2']:_0x133b8b('0x5'),_0x5e7ac5=_0x52b247[_0x133b8b('0x3')]?Mustache[_0x133b8b('0x6')](_0x52b247['data3'],_0x2805f4):_0x2805f4;sh[_0x133b8b('0x2')](_0x5e7ac5,function(_0x16b174,_0x57c80b,_0x2a297a){const _0x1861f7=_0x133b8b;_0x16b174!==0x0?logger['error'](util['format']('%s\x20\x27%s\x27\x20failed\x20with\x20code\x20%d\x20and\x20error:\x20%s',_0x436c1e,_0x5e7ac5,_0x16b174,_0x2a297a)):logger[_0x1861f7('0x7')](util[_0x1861f7('0x9')](_0x1861f7('0x1'),_0x436c1e,_0x5e7ac5,_0x57c80b));});}; \ No newline at end of file diff --git a/server/services/ami/trigger/urlforward/index.js b/server/services/ami/trigger/urlforward/index.js index 3b74b49..641079f 100644 --- a/server/services/ami/trigger/urlforward/index.js +++ b/server/services/ami/trigger/urlforward/index.js @@ -1 +1 @@ -const a1149_0x56b1=['toUpperCase','data6','data1','message','info','error','PUT','catch','stringify','../../../../config/logger','exec','object','name','format','mustache','parse','number','data7','body\x20has\x20been\x20passed\x20to\x20URLforward\x20in\x20a\x20wrong\x20format','statusCode','trigger','%s\x20%s\x20sending\x20request\x20with\x20following\x20options:\x20%s','GET','request-promise-native','headers','data5','render','isNil','%s\x20%s\x20failed\x20with\x20status:\x20%d\x20and\x20error:\x20%s\x20%s','data2','%s\x20%s\x20succeeded\x20with\x20status:\x20%d\x20and\x20response:\x20%s','stack','body'];(function(_0x2e77f2,_0x56b16c){const _0x5e615e=function(_0x1f7f63){while(--_0x1f7f63){_0x2e77f2['push'](_0x2e77f2['shift']());}};_0x5e615e(++_0x56b16c);}(a1149_0x56b1,0x157));const a1149_0x5e61=function(_0x2e77f2,_0x56b16c){_0x2e77f2=_0x2e77f2-0x0;let _0x5e615e=a1149_0x56b1[_0x2e77f2];return _0x5e615e;};const _0x55ac8d=a1149_0x5e61;'use strict';const rp=require(_0x55ac8d('0xa')),util=require('util'),_=require('lodash'),Mustache=require(_0x55ac8d('0x1')),logger=require(_0x55ac8d('0x1d'))(_0x55ac8d('0x7'));exports[_0x55ac8d('0x1e')]=function(_0x1f7f63,_0x4c9a5a){const _0x3e39ec=_0x55ac8d;let _0x52a109,_0x377f73;const _0x2b4287={'method':_0x1f7f63['data1'][_0x3e39ec('0x14')](),'uri':Mustache[_0x3e39ec('0xd')](_0x1f7f63[_0x3e39ec('0x10')],_0x4c9a5a),'json':!![],'resolveWithFullResponse':!![],'timeout':typeof parseInt(_0x1f7f63['data5'])===_0x3e39ec('0x3')&&parseInt(_0x1f7f63['data5'])>=0x1&&parseInt(_0x1f7f63[_0x3e39ec('0xc')])<=0xa?parseInt(_0x1f7f63[_0x3e39ec('0xc')])*0x3e8:0x5*0x3e8};try{_0x2b4287[_0x3e39ec('0xb')]=_0x1f7f63[_0x3e39ec('0x15')]?JSON[_0x3e39ec('0x2')](Mustache[_0x3e39ec('0xd')](_0x1f7f63[_0x3e39ec('0x15')],_0x4c9a5a)):{};}catch(_0x4ef382){logger[_0x3e39ec('0x19')](_0x4ef382['stack']);}switch(_0x1f7f63[_0x3e39ec('0x16')]['toUpperCase']()){case _0x3e39ec('0x9'):case'DELETE':_0x52a109=null,_0x2b4287['qs']=_0x4c9a5a;break;case'POST':case _0x3e39ec('0x1a'):if(_0x1f7f63[_0x3e39ec('0x4')])try{_0x52a109=JSON[_0x3e39ec('0x2')](Mustache[_0x3e39ec('0xd')](_0x1f7f63[_0x3e39ec('0x4')],_0x4c9a5a)),_0x2b4287['body']=_0x52a109;}catch(_0x32a920){logger['error'](_0x32a920[_0x3e39ec('0x12')]),logger[_0x3e39ec('0x19')](_0x3e39ec('0x5'));}else _0x52a109=_0x4c9a5a,_0x2b4287['body']=_0x52a109;break;}logger[_0x3e39ec('0x18')](util['format'](_0x3e39ec('0x8'),_0x1f7f63[_0x3e39ec('0x16')],_0x1f7f63[_0x3e39ec('0x10')],JSON['stringify'](_0x2b4287))),rp(_0x2b4287)['then'](function(_0x10eab0){const _0x2da1d4=_0x3e39ec;_0x52a109=!_[_0x2da1d4('0xe')](_0x52a109)?',\x20request\x20body:\x20'+_0x52a109:'',_0x377f73=typeof _0x10eab0[_0x2da1d4('0x13')]===_0x2da1d4('0x1f')?JSON[_0x2da1d4('0x1c')](_0x10eab0[_0x2da1d4('0x13')]):_0x10eab0[_0x2da1d4('0x13')],logger[_0x2da1d4('0x18')](util[_0x2da1d4('0x0')](_0x2da1d4('0x11'),_0x1f7f63['data1'],_0x1f7f63[_0x2da1d4('0x10')],_0x10eab0['statusCode'],_0x377f73));})[_0x3e39ec('0x1b')](function(_0x493fb2){const _0x52477b=_0x3e39ec;logger[_0x52477b('0x19')](util[_0x52477b('0x0')](_0x52477b('0xf'),_0x1f7f63[_0x52477b('0x16')],_0x1f7f63[_0x52477b('0x10')],_0x493fb2[_0x52477b('0x6')],_0x493fb2[_0x52477b('0x20')],_0x493fb2[_0x52477b('0x17')]));});}; \ No newline at end of file +const a1149_0x3d62=['then','info','data1','util','message','render','data7','toUpperCase','parse','%s\x20%s\x20sending\x20request\x20with\x20following\x20options:\x20%s','mustache','headers','name','statusCode','../../../../config/logger','data6','data2','data5','request-promise-native','%s\x20%s\x20failed\x20with\x20status:\x20%d\x20and\x20error:\x20%s\x20%s','trigger','error','number','%s\x20%s\x20succeeded\x20with\x20status:\x20%d\x20and\x20response:\x20%s','DELETE','lodash','stack','POST','stringify',',\x20request\x20body:\x20','body\x20has\x20been\x20passed\x20to\x20URLforward\x20in\x20a\x20wrong\x20format','format','body'];(function(_0x486040,_0x3d6279){const _0x262f6d=function(_0x219635){while(--_0x219635){_0x486040['push'](_0x486040['shift']());}};_0x262f6d(++_0x3d6279);}(a1149_0x3d62,0x7d));const a1149_0x262f=function(_0x486040,_0x3d6279){_0x486040=_0x486040-0x0;let _0x262f6d=a1149_0x3d62[_0x486040];return _0x262f6d;};const _0x34e269=a1149_0x262f;'use strict';const rp=require(_0x34e269('0x19')),util=require(_0x34e269('0xa')),_=require(_0x34e269('0x20')),Mustache=require(_0x34e269('0x11')),logger=require(_0x34e269('0x15'))(_0x34e269('0x1b'));exports['exec']=function(_0x219635,_0x43f596){const _0x5e9bc3=_0x34e269;let _0x4d87bd,_0x18e9a5;const _0x1b0d5c={'method':_0x219635['data1'][_0x5e9bc3('0xe')](),'uri':Mustache[_0x5e9bc3('0xc')](_0x219635[_0x5e9bc3('0x17')],_0x43f596),'json':!![],'resolveWithFullResponse':!![],'timeout':typeof parseInt(_0x219635[_0x5e9bc3('0x18')])===_0x5e9bc3('0x1d')&&parseInt(_0x219635['data5'])>=0x1&&parseInt(_0x219635[_0x5e9bc3('0x18')])<=0xa?parseInt(_0x219635[_0x5e9bc3('0x18')])*0x3e8:0x5*0x3e8};try{_0x1b0d5c[_0x5e9bc3('0x12')]=_0x219635[_0x5e9bc3('0x16')]?JSON[_0x5e9bc3('0xf')](Mustache['render'](_0x219635[_0x5e9bc3('0x16')],_0x43f596)):{};}catch(_0x22d7db){logger[_0x5e9bc3('0x1c')](_0x22d7db[_0x5e9bc3('0x0')]);}switch(_0x219635['data1'][_0x5e9bc3('0xe')]()){case'GET':case _0x5e9bc3('0x1f'):_0x4d87bd=null,_0x1b0d5c['qs']=_0x43f596;break;case _0x5e9bc3('0x1'):case'PUT':if(_0x219635['data7'])try{_0x4d87bd=JSON[_0x5e9bc3('0xf')](Mustache[_0x5e9bc3('0xc')](_0x219635[_0x5e9bc3('0xd')],_0x43f596)),_0x1b0d5c['body']=_0x4d87bd;}catch(_0x5795d6){logger['error'](_0x5795d6['stack']),logger['error'](_0x5e9bc3('0x4'));}else _0x4d87bd=_0x43f596,_0x1b0d5c[_0x5e9bc3('0x6')]=_0x4d87bd;break;}logger['info'](util[_0x5e9bc3('0x5')](_0x5e9bc3('0x10'),_0x219635[_0x5e9bc3('0x9')],_0x219635['data2'],JSON[_0x5e9bc3('0x2')](_0x1b0d5c))),rp(_0x1b0d5c)[_0x5e9bc3('0x7')](function(_0x4a473d){const _0x4f829d=_0x5e9bc3;_0x4d87bd=!_['isNil'](_0x4d87bd)?_0x4f829d('0x3')+_0x4d87bd:'',_0x18e9a5=typeof _0x4a473d[_0x4f829d('0x6')]==='object'?JSON[_0x4f829d('0x2')](_0x4a473d[_0x4f829d('0x6')]):_0x4a473d[_0x4f829d('0x6')],logger[_0x4f829d('0x8')](util['format'](_0x4f829d('0x1e'),_0x219635[_0x4f829d('0x9')],_0x219635['data2'],_0x4a473d[_0x4f829d('0x14')],_0x18e9a5));})['catch'](function(_0xa7a96d){const _0x474cfd=_0x5e9bc3;logger[_0x474cfd('0x1c')](util[_0x474cfd('0x5')](_0x474cfd('0x1a'),_0x219635[_0x474cfd('0x9')],_0x219635[_0x474cfd('0x17')],_0xa7a96d[_0x474cfd('0x14')],_0xa7a96d[_0x474cfd('0x13')],_0xa7a96d[_0x474cfd('0xb')]));});}; \ No newline at end of file diff --git a/server/services/email/client.js b/server/services/email/client.js index ca99584..defced9 100644 --- a/server/services/email/client.js +++ b/server/services/email/client.js @@ -1 +1 @@ -const a1150_0xef09=['routing','jayson/promise','rpc','http','debug','then','error','../../config/logger','request','Request','exports','client','message'];(function(_0x7c0e54,_0xef0909){const _0x24f5cb=function(_0x1f8d6e){while(--_0x1f8d6e){_0x7c0e54['push'](_0x7c0e54['shift']());}};_0x24f5cb(++_0xef0909);}(a1150_0xef09,0x10f));const a1150_0x24f5=function(_0x7c0e54,_0xef0909){_0x7c0e54=_0x7c0e54-0x0;let _0x24f5cb=a1150_0xef09[_0x7c0e54];return _0x24f5cb;};const _0x273727=a1150_0x24f5;'use strict';const jayson=require(_0x273727('0x3')),logger=require(_0x273727('0x9'))(_0x273727('0x2')),client=jayson[_0x273727('0x0')][_0x273727('0x5')]({'port':0x2329});client[_0x273727('0xb')]=function(_0x1f8d6e,_0x4cf3dd){return new Promise(function(_0x20714f,_0x1b9d3a){const _0x228e14=a1150_0x24f5;return client[_0x228e14('0xa')](_0x1f8d6e,_0x4cf3dd)[_0x228e14('0x7')](function(_0x112db6){const _0x3efe17=_0x228e14;return logger[_0x3efe17('0x6')](_0x3efe17('0x4'),'routing',_0x1f8d6e,_0x4cf3dd,_0x112db6),_0x112db6['error']?(logger[_0x3efe17('0x8')](_0x3efe17('0x4'),_0x3efe17('0x2'),_0x1f8d6e,_0x112db6['error'][_0x3efe17('0x1')],_0x4cf3dd),_0x1b9d3a(_0x112db6[_0x3efe17('0x8')][_0x3efe17('0x1')])):_0x20714f(_0x112db6['result']);})['catch'](function(_0x18e0af){const _0x3a08f2=_0x228e14;return logger[_0x3a08f2('0x8')]('rpc',_0x3a08f2('0x2'),_0x1f8d6e,_0x18e0af,_0x4cf3dd),_0x1b9d3a(_0x18e0af);});});},module[_0x273727('0xc')]=client; \ No newline at end of file +const a1150_0x4d13=['request','result','http','client','exports','message','debug','../../config/logger','then','rpc','jayson/promise','error','routing','catch'];(function(_0x8b9e56,_0x4d130c){const _0x62a359=function(_0x77f12d){while(--_0x77f12d){_0x8b9e56['push'](_0x8b9e56['shift']());}};_0x62a359(++_0x4d130c);}(a1150_0x4d13,0x1b4));const a1150_0x62a3=function(_0x8b9e56,_0x4d130c){_0x8b9e56=_0x8b9e56-0x0;let _0x62a359=a1150_0x4d13[_0x8b9e56];return _0x62a359;};const _0x3d6b3c=a1150_0x62a3;'use strict';const jayson=require(_0x3d6b3c('0x8')),logger=require(_0x3d6b3c('0x5'))('routing'),client=jayson[_0x3d6b3c('0x1')][_0x3d6b3c('0x0')]({'port':0x2329});client['Request']=function(_0x77f12d,_0x40fc59){return new Promise(function(_0x1cb24b,_0x468cf9){const _0x19d2d8=a1150_0x62a3;return client[_0x19d2d8('0xc')](_0x77f12d,_0x40fc59)[_0x19d2d8('0x6')](function(_0x1963a1){const _0x314150=_0x19d2d8;return logger[_0x314150('0x4')]('rpc',_0x314150('0xa'),_0x77f12d,_0x40fc59,_0x1963a1),_0x1963a1[_0x314150('0x9')]?(logger[_0x314150('0x9')](_0x314150('0x7'),_0x314150('0xa'),_0x77f12d,_0x1963a1[_0x314150('0x9')][_0x314150('0x3')],_0x40fc59),_0x468cf9(_0x1963a1[_0x314150('0x9')][_0x314150('0x3')])):_0x1cb24b(_0x1963a1[_0x314150('0xd')]);})[_0x19d2d8('0xb')](function(_0x217e36){const _0x99ba0b=_0x19d2d8;return logger[_0x99ba0b('0x9')](_0x99ba0b('0x7'),'routing',_0x77f12d,_0x217e36,_0x40fc59),_0x468cf9(_0x217e36);});});},module[_0x3d6b3c('0x2')]=client; \ No newline at end of file diff --git a/server/services/email/index.js b/server/services/email/index.js index 08275a6..a7c33b8 100644 --- a/server/services/email/index.js +++ b/server/services/email/index.js @@ -1 +1 @@ -const a1151_0x27dc=['loginMailFrequency','listen','../../globals','log','./realtime','then','./lib/email','mailAccounts','catch','initMailAccounts','resolve','./rpc/mailAccount','getMailAccounts','../../mysqldb'];(function(_0x5b7e2d,_0x27dca0){const _0x4afd28=function(_0x1093c1){while(--_0x1093c1){_0x5b7e2d['push'](_0x5b7e2d['shift']());}};_0x4afd28(++_0x27dca0);}(a1151_0x27dc,0x1bd));const a1151_0x4afd=function(_0x5b7e2d,_0x27dca0){_0x5b7e2d=_0x5b7e2d-0x0;let _0x4afd28=a1151_0x27dc[_0x5b7e2d];return _0x4afd28;};const _0x47b241=a1151_0x4afd;'use strict';require(_0x47b241('0x5'));const server=require('./server'),Realtime=require(_0x47b241('0x7')),EmailChannel=require(_0x47b241('0x9')),mailAccount=require(_0x47b241('0x0')),realtime=new Realtime(),email=new EmailChannel(realtime),db=require(_0x47b241('0x2'))['db'];function initRealtime(){const _0x329e20=_0x47b241;return Promise[_0x329e20('0xd')]()[_0x329e20('0x8')](mailAccount[_0x329e20('0x1')]())[_0x329e20('0x8')](realtime[_0x329e20('0xc')]())[_0x329e20('0x8')](function(){const _0x50a9d0=_0x329e20;return email['refresh'](realtime[_0x50a9d0('0xa')]),realtime;});}function main(){const _0x12fd89=_0x47b241;return server[_0x12fd89('0x4')](realtime,email)['then'](function(){return initRealtime();})['then'](function(){const _0x2454f1=_0x12fd89;return db['Setting']['findOne']({'attributes':['id',_0x2454f1('0x3')],'raw':!![]});})[_0x12fd89('0x8')](function(_0x1093c1){const _0x12a5a1=_0x12fd89;return setInterval(initRealtime,_0x1093c1[_0x12a5a1('0x3')]*0x3e8);})[_0x12fd89('0xb')](function(_0x5c7ffd){const _0x2e72f8=_0x12fd89;console[_0x2e72f8('0x6')](_0x5c7ffd);});}main(); \ No newline at end of file +const a1151_0x543e=['Setting','then','initMailAccounts','../../mysqldb','./rpc/mailAccount','listen','loginMailFrequency','mailAccounts','./realtime','getMailAccounts','catch','./server','log','../../globals','./lib/email','refresh'];(function(_0xb90ff2,_0x543e49){const _0x2ebdc6=function(_0x333c08){while(--_0x333c08){_0xb90ff2['push'](_0xb90ff2['shift']());}};_0x2ebdc6(++_0x543e49);}(a1151_0x543e,0x129));const a1151_0x2ebd=function(_0xb90ff2,_0x543e49){_0xb90ff2=_0xb90ff2-0x0;let _0x2ebdc6=a1151_0x543e[_0xb90ff2];return _0x2ebdc6;};const _0x40619d=a1151_0x2ebd;'use strict';require(_0x40619d('0x4'));const server=require(_0x40619d('0x2')),Realtime=require(_0x40619d('0xf')),EmailChannel=require(_0x40619d('0x5')),mailAccount=require(_0x40619d('0xb')),realtime=new Realtime(),email=new EmailChannel(realtime),db=require(_0x40619d('0xa'))['db'];function initRealtime(){const _0x595b0b=_0x40619d;return Promise['resolve']()[_0x595b0b('0x8')](mailAccount[_0x595b0b('0x0')]())['then'](realtime[_0x595b0b('0x9')]())[_0x595b0b('0x8')](function(){const _0x3ab60d=_0x595b0b;return email[_0x3ab60d('0x6')](realtime[_0x3ab60d('0xe')]),realtime;});}function main(){const _0xd920c7=_0x40619d;return server[_0xd920c7('0xc')](realtime,email)['then'](function(){return initRealtime();})[_0xd920c7('0x8')](function(){const _0x53469d=_0xd920c7;return db[_0x53469d('0x7')]['findOne']({'attributes':['id',_0x53469d('0xd')],'raw':!![]});})[_0xd920c7('0x8')](function(_0x333c08){const _0x165712=_0xd920c7;return setInterval(initRealtime,_0x333c08[_0x165712('0xd')]*0x3e8);})[_0xd920c7('0x1')](function(_0x1facc5){const _0x3ca89b=_0xd920c7;console[_0x3ca89b('0x3')](_0x1facc5);});}main(); \ No newline at end of file diff --git a/server/services/email/lib/email.js b/server/services/email/lib/email.js index c4aa430..a67a4ee 100644 --- a/server/services/email/lib/email.js +++ b/server/services/email/lib/email.js @@ -1 +1 @@ -const a1152_0x3a23=['handleImapError','error','name','email','../../../config/logger','handleImapEmail','verifySmtp','disabled','notify','then','send','active','emit','messages','bind','start\x20email\x20channel','../../../rediscache','undefined','sendMail','catch','New\x20email\x20from\x20%s\x20%s\x20%s\x20to\x20%s','handleImapBox','lastName','lastSync','key','status','refresh','messageStatus','stringify','md5','verified','prototype','box','mailAccounts','imapAccounts','end','Imap','total','Smtp','handleImapEnd','../rpc/mailAccount','lodash','Mail\x20not\x20accepted\x20from\x20routing\x20%s','Mail\x20accepted\x20from\x20routing','smtp','mailAccount:update','./imap','info','isNil','verify','connected'];(function(_0x9206c0,_0x3a2326){const _0xf5fc6f=function(_0x2a71cf){while(--_0x2a71cf){_0x9206c0['push'](_0x9206c0['shift']());}};_0xf5fc6f(++_0x3a2326);}(a1152_0x3a23,0xdf));const a1152_0xf5fc=function(_0x9206c0,_0x3a2326){_0x9206c0=_0x9206c0-0x0;let _0xf5fc6f=a1152_0x3a23[_0x9206c0];return _0xf5fc6f;};const _0x4aa6ae=a1152_0xf5fc;'use strict';const _=require(_0x4aa6ae('0x16')),moment=require('moment'),md5=require(_0x4aa6ae('0xa')),logger=require(_0x4aa6ae('0x24'))('email'),{getSocket}=require(_0x4aa6ae('0x30')),io=getSocket(),EmailImap=require(_0x4aa6ae('0x1b')),EmailSmtp=require('./smtp'),mailAccount=require(_0x4aa6ae('0x15')),md5Accounts={};function EmailChannel(_0x2a71cf){const _0x410bd1=_0x4aa6ae;logger[_0x410bd1('0x1c')](_0x410bd1('0x2f')),this[_0x410bd1('0xe')]=_0x2a71cf[_0x410bd1('0xe')],this[_0x410bd1('0xf')]={},this[_0x410bd1('0x19')]=new EmailSmtp();}EmailChannel[_0x4aa6ae('0xc')]['emit']=function(_0x2f3734){const _0x20a4d7=_0x4aa6ae,_0x4800a9=this[_0x20a4d7('0xe')][_0x2f3734],_0x46b5c8={'id':_0x4800a9['id'],'name':_0x4800a9['name'],'key':_0x4800a9[_0x20a4d7('0x5')],'active':_0x4800a9[_0x20a4d7('0x2b')],'Imap':{'status':_0x4800a9[_0x20a4d7('0x11')][_0x20a4d7('0x6')],'messageStatus':_0x4800a9[_0x20a4d7('0x11')][_0x20a4d7('0x8')],'total':_0x4800a9['Imap']['total']}};_[_0x20a4d7('0x1d')](md5Accounts[_0x2f3734])&&(md5Accounts[_0x2f3734]={});const _0xf82eea=md5(JSON[_0x20a4d7('0x9')](_0x46b5c8));md5Accounts[_0x2f3734][_0x20a4d7('0xa')]!==_0xf82eea&&(md5Accounts[_0x2f3734][_0x20a4d7('0xa')]=_0xf82eea,io[_0x20a4d7('0x2c')](_0x20a4d7('0x1a'),_0x46b5c8));},EmailChannel[_0x4aa6ae('0xc')][_0x4aa6ae('0x7')]=function(_0x39a28c){const _0x565338=_0x4aa6ae;for(const _0x546aaf in _0x39a28c){if(typeof _0x39a28c[_0x546aaf]!==_0x565338('0x31')){if(_0x39a28c[_0x546aaf][_0x565338('0x11')]&&_0x39a28c[_0x546aaf][_0x565338('0x2b')]){const _0x3ae8e0=_0x39a28c[_0x546aaf][_0x565338('0x11')];typeof this[_0x565338('0xf')][_0x3ae8e0['id']]===_0x565338('0x31')&&(this[_0x565338('0xf')][_0x3ae8e0['id']]=new EmailImap(_0x3ae8e0,_0x39a28c[_0x546aaf]['email']),this[_0x565338('0xf')][_0x3ae8e0['id']]['on'](_0x565338('0xd'),this[_0x565338('0x2')][_0x565338('0x2e')](this,_0x546aaf)),this[_0x565338('0xf')][_0x3ae8e0['id']]['on'](_0x565338('0x23'),this[_0x565338('0x25')][_0x565338('0x2e')](this,_0x546aaf)),this[_0x565338('0xf')][_0x3ae8e0['id']]['on'](_0x565338('0x10'),this[_0x565338('0x14')]['bind'](this,_0x546aaf)),this['imapAccounts'][_0x3ae8e0['id']]['on'](_0x565338('0x21'),this[_0x565338('0x20')][_0x565338('0x2e')](this,_0x546aaf)));}else _[_0x565338('0x1d')](this[_0x565338('0xe')][_0x546aaf][_0x565338('0x11')])&&(this[_0x565338('0xe')][_0x546aaf][_0x565338('0x11')]={}),this[_0x565338('0xe')][_0x546aaf]['Imap'][_0x565338('0x6')]=_0x565338('0x27'),this[_0x565338('0xe')][_0x546aaf][_0x565338('0x11')]['messageStatus']='',this[_0x565338('0x2c')](_0x546aaf);}}},EmailChannel[_0x4aa6ae('0xc')][_0x4aa6ae('0x2')]=function(_0x2557a8,_0x52d9cd){const _0x2f98f3=_0x4aa6ae;if(this[_0x2f98f3('0xe')][_0x2557a8])return this[_0x2f98f3('0xe')][_0x2557a8]['Imap'][_0x2f98f3('0x6')]=_0x2f98f3('0x1f'),this[_0x2f98f3('0xe')][_0x2557a8]['Imap'][_0x2f98f3('0x8')]=_0x52d9cd[_0x2f98f3('0x22')],_0x52d9cd[_0x2f98f3('0x2d')]&&(this['mailAccounts'][_0x2557a8][_0x2f98f3('0x11')]['total']=_0x52d9cd[_0x2f98f3('0x2d')][_0x2f98f3('0x12')]),this[_0x2f98f3('0x2c')](_0x2557a8);},EmailChannel[_0x4aa6ae('0xc')][_0x4aa6ae('0x25')]=function(_0x2457fb,_0x590673){const _0x46e634=_0x4aa6ae;logger[_0x46e634('0x1c')](_0x46e634('0x1'),_0x590673['firstName'],_0x590673[_0x46e634('0x3')],_0x590673['from'],_0x2457fb);if(this[_0x46e634('0xe')][_0x2457fb])return mailAccount[_0x46e634('0x28')](_0x2457fb,_0x590673)[_0x46e634('0x29')](function(_0x398915){const _0x48330f=_0x46e634;_0x398915&&logger['info'](_0x48330f('0x18'));})['catch'](function(_0x46a461){const _0x4edfe9=_0x46e634;logger[_0x4edfe9('0x21')](_0x4edfe9('0x17'),JSON[_0x4edfe9('0x9')](_0x46a461));});},EmailChannel[_0x4aa6ae('0xc')][_0x4aa6ae('0x14')]=function(_0x4d45b2){const _0x5193f6=_0x4aa6ae;this[_0x5193f6('0xe')][_0x4d45b2]&&this['mailAccounts'][_0x4d45b2][_0x5193f6('0x11')]&&(this[_0x5193f6('0xf')][this['mailAccounts'][_0x4d45b2][_0x5193f6('0x11')]['id']]&&delete this[_0x5193f6('0xf')][this['mailAccounts'][_0x4d45b2][_0x5193f6('0x11')]['id']],this['mailAccounts'][_0x4d45b2][_0x5193f6('0x11')][_0x5193f6('0x4')]=moment(),this[_0x5193f6('0x2c')](_0x4d45b2));},EmailChannel[_0x4aa6ae('0xc')][_0x4aa6ae('0x20')]=function(_0x493b60,_0x30757){const _0x55d474=_0x4aa6ae;if(this[_0x55d474('0xe')][_0x493b60])return this[_0x55d474('0xe')][_0x493b60][_0x55d474('0x11')]['status']='error',this[_0x55d474('0xe')][_0x493b60][_0x55d474('0x11')][_0x55d474('0x8')]=_0x30757,this[_0x55d474('0x2c')](_0x493b60);},EmailChannel[_0x4aa6ae('0xc')][_0x4aa6ae('0x32')]=function(_0x71fa6b,_0x20b9f1){const _0x1aadd4=_0x4aa6ae;return this[_0x1aadd4('0x19')][_0x1aadd4('0x2a')](_0x71fa6b,_0x20b9f1);},EmailChannel['prototype'][_0x4aa6ae('0x26')]=function(_0xe4d244){const _0x40fc04=_0x4aa6ae,_0x446d72=this;if(this[_0x40fc04('0xe')][_0xe4d244['id']])return _['isNil'](this[_0x40fc04('0xe')][_0xe4d244['id']][_0x40fc04('0x13')])&&(this['mailAccounts'][_0xe4d244['id']][_0x40fc04('0x13')]={}),this[_0x40fc04('0xe')][_0xe4d244['id']][_0x40fc04('0x13')][_0x40fc04('0x4')]=moment(),new Promise(function(_0x2401b2,_0xab7465){const _0x6d35e0=_0x40fc04;return _0x446d72['smtp'][_0x6d35e0('0x1e')](_0xe4d244)[_0x6d35e0('0x29')](function(_0x4de145){const _0x236972=_0x6d35e0;_0x446d72[_0x236972('0xe')][_0xe4d244['id']]['Smtp'][_0x236972('0x6')]=_0x236972('0xb'),_0x446d72[_0x236972('0xe')][_0xe4d244['id']][_0x236972('0x13')][_0x236972('0x8')]='',_0x446d72[_0x236972('0x2c')](_0xe4d244['id']),_0x2401b2(_0x4de145);})[_0x6d35e0('0x0')](function(_0x18b113){const _0x229d6f=_0x6d35e0;_0x446d72[_0x229d6f('0xe')][_0xe4d244['id']][_0x229d6f('0x13')][_0x229d6f('0x6')]=_0x229d6f('0x21'),_0x446d72[_0x229d6f('0xe')][_0xe4d244['id']][_0x229d6f('0x13')][_0x229d6f('0x8')]=_0x18b113,_0x446d72[_0x229d6f('0x2c')](_0xe4d244['id']),_0xab7465(_0x18b113);});});return this['smtp']['verify'](_0xe4d244);},module['exports']=EmailChannel; \ No newline at end of file +const a1152_0x5dde=['exports','./imap','then','Mail\x20not\x20accepted\x20from\x20routing\x20%s','emit','refresh','../rpc/mailAccount','error','key','handleImapBox','verify','connected','verified','lodash','sendMail','stringify','../../../rediscache','mailAccounts','isNil','email','firstName','undefined','messages','catch','active','Mail\x20accepted\x20from\x20routing','handleImapEmail','../../../config/logger','start\x20email\x20channel','lastSync','Smtp','bind','end','total','imapAccounts','handleImapEnd','Imap','status','smtp','New\x20email\x20from\x20%s\x20%s\x20%s\x20to\x20%s','info','messageStatus','notify','md5','name','prototype'];(function(_0x2982d2,_0x5dde19){const _0xab9e94=function(_0x42a32d){while(--_0x42a32d){_0x2982d2['push'](_0x2982d2['shift']());}};_0xab9e94(++_0x5dde19);}(a1152_0x5dde,0x1bd));const a1152_0xab9e=function(_0x2982d2,_0x5dde19){_0x2982d2=_0x2982d2-0x0;let _0xab9e94=a1152_0x5dde[_0x2982d2];return _0xab9e94;};const _0xf869b0=a1152_0xab9e;'use strict';const _=require(_0xf869b0('0x1c')),moment=require('moment'),md5=require(_0xf869b0('0xc')),logger=require(_0xf869b0('0x2a'))(_0xf869b0('0x22')),{getSocket}=require(_0xf869b0('0x1f')),io=getSocket(),EmailImap=require(_0xf869b0('0x10')),EmailSmtp=require('./smtp'),mailAccount=require(_0xf869b0('0x15')),md5Accounts={};function EmailChannel(_0x42a32d){const _0x55d884=_0xf869b0;logger[_0x55d884('0x9')](_0x55d884('0x2b')),this['mailAccounts']=_0x42a32d[_0x55d884('0x20')],this[_0x55d884('0x3')]={},this['smtp']=new EmailSmtp();}EmailChannel[_0xf869b0('0xe')][_0xf869b0('0x13')]=function(_0x4484c1){const _0x3bb030=_0xf869b0,_0x151220=this[_0x3bb030('0x20')][_0x4484c1],_0x1bc485={'id':_0x151220['id'],'name':_0x151220['name'],'key':_0x151220[_0x3bb030('0x17')],'active':_0x151220[_0x3bb030('0x27')],'Imap':{'status':_0x151220['Imap']['status'],'messageStatus':_0x151220[_0x3bb030('0x5')][_0x3bb030('0xa')],'total':_0x151220[_0x3bb030('0x5')]['total']}};_['isNil'](md5Accounts[_0x4484c1])&&(md5Accounts[_0x4484c1]={});const _0x418fbe=md5(JSON[_0x3bb030('0x1e')](_0x1bc485));md5Accounts[_0x4484c1][_0x3bb030('0xc')]!==_0x418fbe&&(md5Accounts[_0x4484c1][_0x3bb030('0xc')]=_0x418fbe,io[_0x3bb030('0x13')]('mailAccount:update',_0x1bc485));},EmailChannel[_0xf869b0('0xe')][_0xf869b0('0x14')]=function(_0x5a0d69){const _0x277a22=_0xf869b0;for(const _0x1a006c in _0x5a0d69){if(typeof _0x5a0d69[_0x1a006c]!==_0x277a22('0x24')){if(_0x5a0d69[_0x1a006c]['Imap']&&_0x5a0d69[_0x1a006c][_0x277a22('0x27')]){const _0x4b4e67=_0x5a0d69[_0x1a006c]['Imap'];typeof this[_0x277a22('0x3')][_0x4b4e67['id']]===_0x277a22('0x24')&&(this[_0x277a22('0x3')][_0x4b4e67['id']]=new EmailImap(_0x4b4e67,_0x5a0d69[_0x1a006c][_0x277a22('0x22')]),this[_0x277a22('0x3')][_0x4b4e67['id']]['on']('box',this[_0x277a22('0x18')][_0x277a22('0x0')](this,_0x1a006c)),this[_0x277a22('0x3')][_0x4b4e67['id']]['on'](_0x277a22('0x22'),this['handleImapEmail']['bind'](this,_0x1a006c)),this[_0x277a22('0x3')][_0x4b4e67['id']]['on'](_0x277a22('0x1'),this[_0x277a22('0x4')][_0x277a22('0x0')](this,_0x1a006c)),this[_0x277a22('0x3')][_0x4b4e67['id']]['on'](_0x277a22('0x16'),this['handleImapError'][_0x277a22('0x0')](this,_0x1a006c)));}else _[_0x277a22('0x21')](this[_0x277a22('0x20')][_0x1a006c][_0x277a22('0x5')])&&(this[_0x277a22('0x20')][_0x1a006c][_0x277a22('0x5')]={}),this[_0x277a22('0x20')][_0x1a006c][_0x277a22('0x5')][_0x277a22('0x6')]='disabled',this[_0x277a22('0x20')][_0x1a006c][_0x277a22('0x5')][_0x277a22('0xa')]='',this['emit'](_0x1a006c);}}},EmailChannel[_0xf869b0('0xe')][_0xf869b0('0x18')]=function(_0x23430c,_0x153507){const _0x2987d1=_0xf869b0;if(this[_0x2987d1('0x20')][_0x23430c])return this['mailAccounts'][_0x23430c][_0x2987d1('0x5')][_0x2987d1('0x6')]=_0x2987d1('0x1a'),this[_0x2987d1('0x20')][_0x23430c][_0x2987d1('0x5')][_0x2987d1('0xa')]=_0x153507[_0x2987d1('0xd')],_0x153507[_0x2987d1('0x25')]&&(this[_0x2987d1('0x20')][_0x23430c][_0x2987d1('0x5')][_0x2987d1('0x2')]=_0x153507[_0x2987d1('0x25')][_0x2987d1('0x2')]),this[_0x2987d1('0x13')](_0x23430c);},EmailChannel[_0xf869b0('0xe')][_0xf869b0('0x29')]=function(_0x1f5a0f,_0x417277){const _0x14a3af=_0xf869b0;logger[_0x14a3af('0x9')](_0x14a3af('0x8'),_0x417277[_0x14a3af('0x23')],_0x417277['lastName'],_0x417277['from'],_0x1f5a0f);if(this[_0x14a3af('0x20')][_0x1f5a0f])return mailAccount[_0x14a3af('0xb')](_0x1f5a0f,_0x417277)[_0x14a3af('0x11')](function(_0x63733a){const _0x305de6=_0x14a3af;_0x63733a&&logger[_0x305de6('0x9')](_0x305de6('0x28'));})[_0x14a3af('0x26')](function(_0x3c0839){const _0x83d79c=_0x14a3af;logger[_0x83d79c('0x16')](_0x83d79c('0x12'),JSON[_0x83d79c('0x1e')](_0x3c0839));});},EmailChannel[_0xf869b0('0xe')][_0xf869b0('0x4')]=function(_0x28d014){const _0x4f3b41=_0xf869b0;this[_0x4f3b41('0x20')][_0x28d014]&&this[_0x4f3b41('0x20')][_0x28d014][_0x4f3b41('0x5')]&&(this[_0x4f3b41('0x3')][this[_0x4f3b41('0x20')][_0x28d014][_0x4f3b41('0x5')]['id']]&&delete this[_0x4f3b41('0x3')][this[_0x4f3b41('0x20')][_0x28d014][_0x4f3b41('0x5')]['id']],this[_0x4f3b41('0x20')][_0x28d014]['Imap'][_0x4f3b41('0x2c')]=moment(),this[_0x4f3b41('0x13')](_0x28d014));},EmailChannel[_0xf869b0('0xe')]['handleImapError']=function(_0x188c06,_0x3c9f75){const _0x4a416a=_0xf869b0;if(this[_0x4a416a('0x20')][_0x188c06])return this[_0x4a416a('0x20')][_0x188c06]['Imap']['status']=_0x4a416a('0x16'),this[_0x4a416a('0x20')][_0x188c06][_0x4a416a('0x5')]['messageStatus']=_0x3c9f75,this[_0x4a416a('0x13')](_0x188c06);},EmailChannel[_0xf869b0('0xe')][_0xf869b0('0x1d')]=function(_0x16cb2c,_0x18b255){const _0x37d238=_0xf869b0;return this[_0x37d238('0x7')]['send'](_0x16cb2c,_0x18b255);},EmailChannel[_0xf869b0('0xe')]['verifySmtp']=function(_0x4cc1b9){const _0x2c47bf=_0xf869b0,_0xdefce1=this;if(this['mailAccounts'][_0x4cc1b9['id']])return _[_0x2c47bf('0x21')](this[_0x2c47bf('0x20')][_0x4cc1b9['id']][_0x2c47bf('0x2d')])&&(this[_0x2c47bf('0x20')][_0x4cc1b9['id']][_0x2c47bf('0x2d')]={}),this[_0x2c47bf('0x20')][_0x4cc1b9['id']]['Smtp'][_0x2c47bf('0x2c')]=moment(),new Promise(function(_0xbf25f9,_0x3bd49d){const _0x2450a0=_0x2c47bf;return _0xdefce1[_0x2450a0('0x7')][_0x2450a0('0x19')](_0x4cc1b9)[_0x2450a0('0x11')](function(_0x1f6c54){const _0x293fdc=_0x2450a0;_0xdefce1[_0x293fdc('0x20')][_0x4cc1b9['id']][_0x293fdc('0x2d')][_0x293fdc('0x6')]=_0x293fdc('0x1b'),_0xdefce1['mailAccounts'][_0x4cc1b9['id']][_0x293fdc('0x2d')][_0x293fdc('0xa')]='',_0xdefce1['emit'](_0x4cc1b9['id']),_0xbf25f9(_0x1f6c54);})[_0x2450a0('0x26')](function(_0x33c732){const _0x34d0a5=_0x2450a0;_0xdefce1[_0x34d0a5('0x20')][_0x4cc1b9['id']]['Smtp']['status']=_0x34d0a5('0x16'),_0xdefce1[_0x34d0a5('0x20')][_0x4cc1b9['id']][_0x34d0a5('0x2d')][_0x34d0a5('0xa')]=_0x33c732,_0xdefce1[_0x34d0a5('0x13')](_0x4cc1b9['id']),_0x3bd49d(_0x33c732);});});return this['smtp']['verify'](_0x4cc1b9);},module[_0xf869b0('0xf')]=EmailChannel; \ No newline at end of file diff --git a/server/services/email/lib/imap.js b/server/services/email/lib/imap.js index d23b289..0c0d511 100644 --- a/server/services/email/lib/imap.js +++ b/server/services/email/lib/imap.js @@ -1 +1 @@ -const a1153_0x4f92=['parser','inherits','search','imap','handleMessageAttributes','anonymous@xcally.com','host','handleError','INBOX','handleEnd','connect','handleMessageBody','handleCloseBox','connTimeout','simpleParser','./utils','attributes','handleFetchMessage','handleFetchError','getHost','../../../config/logger','handleMessageEnd','upperFirst','tls','isNil','mailparser','box','handleReady','prototype','required','password','fetch','once','autotls','handleFetchEnd','util','end','body','readUnseen','handleOpenBox','closeBox','emit','handleSimpleParser','bind','authTimeout','Iconv','textCode','error','handleReadUnseen','message','user','stringify','account','email','undefined','lodash','events','service','ready','length','UNSEEN'];(function(_0x142f8e,_0x4f92a3){const _0x439768=function(_0x14144b){while(--_0x14144b){_0x142f8e['push'](_0x142f8e['shift']());}};_0x439768(++_0x4f92a3);}(a1153_0x4f92,0xad));const a1153_0x4397=function(_0x142f8e,_0x4f92a3){_0x142f8e=_0x142f8e-0x0;let _0x439768=a1153_0x4f92[_0x142f8e];return _0x439768;};const _0x384a4d=a1153_0x4397;'use strict';const util=require(_0x384a4d('0x2d')),Imap=require(_0x384a4d('0xd')),_=require(_0x384a4d('0x4')),simpleParser=require(_0x384a4d('0x23'))[_0x384a4d('0x18')],Iconv=require('iconv')[_0x384a4d('0x37')],EventEmitter=require(_0x384a4d('0x5'))['EventEmitter'],utils=require(_0x384a4d('0x19')),logger=require(_0x384a4d('0x1e'))(_0x384a4d('0x2'));function EmailImap(_0x14144b,_0x1c84f7){const _0x48215f=_0x384a4d;this['mailbox']=_0x48215f('0x12'),this[_0x48215f('0x1')]=this['getAccount'](_0x14144b,_0x1c84f7),this[_0x48215f('0xd')]=new Imap(this[_0x48215f('0x1')]),this[_0x48215f('0xd')][_0x48215f('0x2a')](_0x48215f('0x7'),this[_0x48215f('0x25')][_0x48215f('0x35')](this)),this[_0x48215f('0xd')][_0x48215f('0x2a')](_0x48215f('0x2e'),this[_0x48215f('0x13')][_0x48215f('0x35')](this)),this[_0x48215f('0xd')]['on']('error',this[_0x48215f('0x11')][_0x48215f('0x35')](this)),this[_0x48215f('0xd')][_0x48215f('0x14')]();}util[_0x384a4d('0xb')](EmailImap,EventEmitter),EmailImap[_0x384a4d('0x26')]['getAccount']=function(_0x1786b4,_0x47ac4d){const _0x257b01=_0x384a4d,_0x10f859={'connTimeout':_0x1786b4[_0x257b01('0x17')]?_0x1786b4[_0x257b01('0x17')]*0x3e8:0x2710,'authTimeout':_0x1786b4[_0x257b01('0x36')]?_0x1786b4['authTimeout']*0x3e8:0x1388};return _[_0x257b01('0x22')](_0x1786b4[_0x257b01('0x6')])?(_0x1786b4['authentication']&&(_0x10f859[_0x257b01('0x3c')]=_0x1786b4[_0x257b01('0x3c')],_0x10f859['password']=_0x1786b4[_0x257b01('0x28')]),_0x10f859['host']=_0x1786b4[_0x257b01('0x10')],_0x10f859['port']=_0x1786b4['port']||0x3e1,_0x1786b4[_0x257b01('0x21')]?_0x10f859[_0x257b01('0x21')]=!![]:(_0x10f859[_0x257b01('0x21')]=![],_0x10f859[_0x257b01('0x2b')]=_0x257b01('0x27'))):(_0x10f859['user']=_0x1786b4['user'],_0x10f859[_0x257b01('0x28')]=_0x1786b4[_0x257b01('0x28')],_0x10f859[_0x257b01('0x10')]=utils[_0x257b01('0x1d')](_0x1786b4[_0x257b01('0x6')]),_0x10f859['port']=0x3e1,_0x10f859[_0x257b01('0x21')]=!![]),_0x10f859[_0x257b01('0x2')]=_0x47ac4d||_0x1786b4[_0x257b01('0x3c')]||_0x257b01('0xf'),_0x10f859;},EmailImap[_0x384a4d('0x26')][_0x384a4d('0x25')]=function(){const _0x1b9a72=_0x384a4d;this[_0x1b9a72('0xd')]['openBox'](this['mailbox'],![],this[_0x1b9a72('0x31')][_0x1b9a72('0x35')](this));},EmailImap[_0x384a4d('0x26')][_0x384a4d('0x31')]=function(_0x123c66,_0x31e373){const _0x44e733=_0x384a4d;_0x123c66?this[_0x44e733('0x11')](_0x123c66,!![]):(this['emit'](_0x44e733('0x24'),_0x31e373),this[_0x44e733('0x30')]());},EmailImap[_0x384a4d('0x26')]['handleCloseBox']=function(_0x450fd0){const _0x39d1f0=_0x384a4d;_0x450fd0?this[_0x39d1f0('0x11')](_0x450fd0,!![]):this[_0x39d1f0('0xd')]['end']();},EmailImap[_0x384a4d('0x26')][_0x384a4d('0x30')]=function(){const _0x32cb65=_0x384a4d;this[_0x32cb65('0xd')][_0x32cb65('0xc')]([_0x32cb65('0x9')],this[_0x32cb65('0x3a')][_0x32cb65('0x35')](this));},EmailImap[_0x384a4d('0x26')][_0x384a4d('0x3a')]=function(_0x3c4a5e,_0x141a64){const _0x26bbf5=_0x384a4d;if(_0x3c4a5e)this[_0x26bbf5('0x11')](_0x3c4a5e,!![]);else{if(_0x141a64[_0x26bbf5('0x8')])try{const _0x4d34f8=this[_0x26bbf5('0xd')][_0x26bbf5('0x29')](_0x141a64,{'bodies':'','markSeen':!![]});_0x4d34f8['on'](_0x26bbf5('0x3b'),this[_0x26bbf5('0x1b')][_0x26bbf5('0x35')](this)),_0x4d34f8['once'](_0x26bbf5('0x39'),this['handleFetchError']['bind'](this)),_0x4d34f8[_0x26bbf5('0x2a')](_0x26bbf5('0x2e'),this[_0x26bbf5('0x2c')][_0x26bbf5('0x35')](this));}catch(_0x5d7ee6){logger[_0x26bbf5('0x39')](_0x5d7ee6);}else this[_0x26bbf5('0xd')]['closeBox'](!![],this['handleCloseBox']['bind'](this));}},EmailImap[_0x384a4d('0x26')][_0x384a4d('0x1b')]=function(_0xc982ba){const _0x50acac=_0x384a4d;_0xc982ba['on'](_0x50acac('0x2f'),this[_0x50acac('0x15')][_0x50acac('0x35')](this)),_0xc982ba['once'](_0x50acac('0x1a'),this[_0x50acac('0xe')][_0x50acac('0x35')](this)),_0xc982ba[_0x50acac('0x2a')]('end',this[_0x50acac('0x1f')][_0x50acac('0x35')](this));},EmailImap['prototype'][_0x384a4d('0x15')]=function(_0x2ca88e){simpleParser(_0x2ca88e,{'Iconv':Iconv},this['handleSimpleParser']['bind'](this));},EmailImap[_0x384a4d('0x26')][_0x384a4d('0xe')]=function(){},EmailImap[_0x384a4d('0x26')][_0x384a4d('0x1f')]=function(){},EmailImap['prototype'][_0x384a4d('0x34')]=function(_0x20b099,_0x3632d1){const _0x30c08c=_0x384a4d;if(_0x20b099)logger[_0x30c08c('0x39')](_0x20b099);else{const _0x3a8743=this;utils[_0x30c08c('0xa')](this['account'],_0x3632d1,function(_0x296f8e){const _0x1834ec=_0x30c08c;_0x3a8743[_0x1834ec('0x33')](_0x1834ec('0x2'),_0x296f8e);});}},EmailImap[_0x384a4d('0x26')][_0x384a4d('0x2c')]=function(){const _0x528c41=_0x384a4d;this[_0x528c41('0xd')][_0x528c41('0x32')](!![],this[_0x528c41('0x16')][_0x528c41('0x35')](this));},EmailImap[_0x384a4d('0x26')][_0x384a4d('0x1c')]=function(_0x262019){const _0x2dfa03=_0x384a4d;this[_0x2dfa03('0x11')](_0x262019),this[_0x2dfa03('0xd')][_0x2dfa03('0x32')](!![],this[_0x2dfa03('0x16')]['bind'](this));},EmailImap[_0x384a4d('0x26')]['handleEnd']=function(){const _0x33a629=_0x384a4d;this[_0x33a629('0x33')]('end');},EmailImap[_0x384a4d('0x26')][_0x384a4d('0x11')]=function(_0xde296a,_0x7e3f){const _0x261995=_0x384a4d;logger['error'](_0x261995('0x11'),this['account'][_0x261995('0x2')],JSON[_0x261995('0x0')](_0xde296a));let _0x16ff18='';if(_0xde296a){if(_0xde296a[_0x261995('0x38')])_0x16ff18=_0xde296a[_0x261995('0x38')];else for(const _0x59b4d5 in _0xde296a){typeof _0xde296a[_0x59b4d5]!==_0x261995('0x3')&&(_0x16ff18+=_[_0x261995('0x20')](_0x59b4d5)+':\x20'+_0xde296a[_0x59b4d5]+'\x0a');}}_0x7e3f?this[_0x261995('0xd')][_0x261995('0x2e')]():(this[_0x261995('0x33')](_0x261995('0x39'),_0x16ff18),this[_0x261995('0x33')](_0x261995('0x2e')));},module['exports']=EmailImap; \ No newline at end of file +const a1153_0x50ce=['password','mailbox','bind','autotls','mailparser','handleMessageBody','../../../config/logger','emit','simpleParser','imap','search','parser','authentication','authTimeout','readUnseen','lodash','service','tls','handleReadUnseen','handleReady','./utils','account','handleEnd','closeBox','handleSimpleParser','handleFetchError','error','Iconv','handleOpenBox','port','ready','events','iconv','handleError','end','once','attributes','handleCloseBox','prototype','getAccount','UNSEEN','required','body','host','handleFetchMessage','length','handleMessageAttributes','user','util','handleMessageEnd','INBOX','email','box','message'];(function(_0x15a947,_0x50ce4d){const _0x1e4aab=function(_0x7d86f9){while(--_0x7d86f9){_0x15a947['push'](_0x15a947['shift']());}};_0x1e4aab(++_0x50ce4d);}(a1153_0x50ce,0x10b));const a1153_0x1e4a=function(_0x15a947,_0x50ce4d){_0x15a947=_0x15a947-0x0;let _0x1e4aab=a1153_0x50ce[_0x15a947];return _0x1e4aab;};const _0x3a3a5d=a1153_0x1e4a;'use strict';const util=require(_0x3a3a5d('0x33')),Imap=require(_0x3a3a5d('0xc')),_=require(_0x3a3a5d('0x12')),simpleParser=require(_0x3a3a5d('0x7'))[_0x3a3a5d('0xb')],Iconv=require(_0x3a3a5d('0x23'))[_0x3a3a5d('0x1e')],EventEmitter=require(_0x3a3a5d('0x22'))['EventEmitter'],utils=require(_0x3a3a5d('0x17')),logger=require(_0x3a3a5d('0x9'))(_0x3a3a5d('0x0'));function EmailImap(_0x7d86f9,_0x3f3f88){const _0x866e13=_0x3a3a5d;this[_0x866e13('0x4')]=_0x866e13('0x35'),this[_0x866e13('0x18')]=this['getAccount'](_0x7d86f9,_0x3f3f88),this['imap']=new Imap(this[_0x866e13('0x18')]),this[_0x866e13('0xc')][_0x866e13('0x26')](_0x866e13('0x21'),this[_0x866e13('0x16')]['bind'](this)),this[_0x866e13('0xc')][_0x866e13('0x26')](_0x866e13('0x25'),this['handleEnd']['bind'](this)),this[_0x866e13('0xc')]['on']('error',this[_0x866e13('0x24')][_0x866e13('0x5')](this)),this['imap']['connect']();}util['inherits'](EmailImap,EventEmitter),EmailImap[_0x3a3a5d('0x29')][_0x3a3a5d('0x2a')]=function(_0x1fad7f,_0x5c371a){const _0x5a3af5=_0x3a3a5d,_0x3cedf9={'connTimeout':_0x1fad7f['connTimeout']?_0x1fad7f['connTimeout']*0x3e8:0x2710,'authTimeout':_0x1fad7f[_0x5a3af5('0x10')]?_0x1fad7f['authTimeout']*0x3e8:0x1388};return _['isNil'](_0x1fad7f[_0x5a3af5('0x13')])?(_0x1fad7f[_0x5a3af5('0xf')]&&(_0x3cedf9[_0x5a3af5('0x32')]=_0x1fad7f[_0x5a3af5('0x32')],_0x3cedf9['password']=_0x1fad7f[_0x5a3af5('0x3')]),_0x3cedf9[_0x5a3af5('0x2e')]=_0x1fad7f['host'],_0x3cedf9['port']=_0x1fad7f[_0x5a3af5('0x20')]||0x3e1,_0x1fad7f[_0x5a3af5('0x14')]?_0x3cedf9[_0x5a3af5('0x14')]=!![]:(_0x3cedf9['tls']=![],_0x3cedf9[_0x5a3af5('0x6')]=_0x5a3af5('0x2c'))):(_0x3cedf9['user']=_0x1fad7f[_0x5a3af5('0x32')],_0x3cedf9[_0x5a3af5('0x3')]=_0x1fad7f[_0x5a3af5('0x3')],_0x3cedf9[_0x5a3af5('0x2e')]=utils['getHost'](_0x1fad7f[_0x5a3af5('0x13')]),_0x3cedf9['port']=0x3e1,_0x3cedf9['tls']=!![]),_0x3cedf9[_0x5a3af5('0x0')]=_0x5c371a||_0x1fad7f[_0x5a3af5('0x32')]||'anonymous@xcally.com',_0x3cedf9;},EmailImap[_0x3a3a5d('0x29')][_0x3a3a5d('0x16')]=function(){const _0x63afed=_0x3a3a5d;this[_0x63afed('0xc')]['openBox'](this[_0x63afed('0x4')],![],this[_0x63afed('0x1f')]['bind'](this));},EmailImap[_0x3a3a5d('0x29')]['handleOpenBox']=function(_0x57a2c3,_0x53c466){const _0x361e68=_0x3a3a5d;_0x57a2c3?this[_0x361e68('0x24')](_0x57a2c3,!![]):(this['emit'](_0x361e68('0x1'),_0x53c466),this[_0x361e68('0x11')]());},EmailImap['prototype'][_0x3a3a5d('0x28')]=function(_0x26fb8e){const _0x1394bc=_0x3a3a5d;_0x26fb8e?this[_0x1394bc('0x24')](_0x26fb8e,!![]):this[_0x1394bc('0xc')][_0x1394bc('0x25')]();},EmailImap[_0x3a3a5d('0x29')]['readUnseen']=function(){const _0xb15e11=_0x3a3a5d;this[_0xb15e11('0xc')][_0xb15e11('0xd')]([_0xb15e11('0x2b')],this[_0xb15e11('0x15')][_0xb15e11('0x5')](this));},EmailImap[_0x3a3a5d('0x29')][_0x3a3a5d('0x15')]=function(_0x1e1fa0,_0x27cb55){const _0x1106ac=_0x3a3a5d;if(_0x1e1fa0)this[_0x1106ac('0x24')](_0x1e1fa0,!![]);else{if(_0x27cb55[_0x1106ac('0x30')])try{const _0x23f34c=this[_0x1106ac('0xc')]['fetch'](_0x27cb55,{'bodies':'','markSeen':!![]});_0x23f34c['on'](_0x1106ac('0x2'),this[_0x1106ac('0x2f')][_0x1106ac('0x5')](this)),_0x23f34c[_0x1106ac('0x26')](_0x1106ac('0x1d'),this[_0x1106ac('0x1c')][_0x1106ac('0x5')](this)),_0x23f34c[_0x1106ac('0x26')](_0x1106ac('0x25'),this['handleFetchEnd'][_0x1106ac('0x5')](this));}catch(_0x3f0cd8){logger['error'](_0x3f0cd8);}else this['imap'][_0x1106ac('0x1a')](!![],this[_0x1106ac('0x28')]['bind'](this));}},EmailImap['prototype'][_0x3a3a5d('0x2f')]=function(_0x266ce4){const _0x599676=_0x3a3a5d;_0x266ce4['on'](_0x599676('0x2d'),this[_0x599676('0x8')][_0x599676('0x5')](this)),_0x266ce4[_0x599676('0x26')](_0x599676('0x27'),this[_0x599676('0x31')]['bind'](this)),_0x266ce4['once']('end',this[_0x599676('0x34')][_0x599676('0x5')](this));},EmailImap['prototype'][_0x3a3a5d('0x8')]=function(_0x2ec3cb){const _0x3f457f=_0x3a3a5d;simpleParser(_0x2ec3cb,{'Iconv':Iconv},this[_0x3f457f('0x1b')]['bind'](this));},EmailImap[_0x3a3a5d('0x29')][_0x3a3a5d('0x31')]=function(){},EmailImap[_0x3a3a5d('0x29')][_0x3a3a5d('0x34')]=function(){},EmailImap[_0x3a3a5d('0x29')][_0x3a3a5d('0x1b')]=function(_0x2b4a33,_0x3aef53){const _0x3f39ff=_0x3a3a5d;if(_0x2b4a33)logger[_0x3f39ff('0x1d')](_0x2b4a33);else{const _0x427f7f=this;utils[_0x3f39ff('0xe')](this[_0x3f39ff('0x18')],_0x3aef53,function(_0x452b59){const _0x4230aa=_0x3f39ff;_0x427f7f['emit'](_0x4230aa('0x0'),_0x452b59);});}},EmailImap[_0x3a3a5d('0x29')]['handleFetchEnd']=function(){const _0x52041b=_0x3a3a5d;this[_0x52041b('0xc')]['closeBox'](!![],this[_0x52041b('0x28')][_0x52041b('0x5')](this));},EmailImap[_0x3a3a5d('0x29')][_0x3a3a5d('0x1c')]=function(_0x502538){const _0xf37761=_0x3a3a5d;this['handleError'](_0x502538),this[_0xf37761('0xc')][_0xf37761('0x1a')](!![],this[_0xf37761('0x28')][_0xf37761('0x5')](this));},EmailImap[_0x3a3a5d('0x29')][_0x3a3a5d('0x19')]=function(){const _0x3989d0=_0x3a3a5d;this[_0x3989d0('0xa')](_0x3989d0('0x25'));},EmailImap['prototype'][_0x3a3a5d('0x24')]=function(_0x5e7570,_0x297f47){const _0x1f4a86=_0x3a3a5d;logger[_0x1f4a86('0x1d')](_0x1f4a86('0x24'),this['account'][_0x1f4a86('0x0')],JSON['stringify'](_0x5e7570));let _0x2d81a7='';if(_0x5e7570){if(_0x5e7570['textCode'])_0x2d81a7=_0x5e7570['textCode'];else for(const _0x15b28c in _0x5e7570){typeof _0x5e7570[_0x15b28c]!=='undefined'&&(_0x2d81a7+=_['upperFirst'](_0x15b28c)+':\x20'+_0x5e7570[_0x15b28c]+'\x0a');}}_0x297f47?this[_0x1f4a86('0xc')]['end']():(this[_0x1f4a86('0xa')](_0x1f4a86('0x1d'),_0x2d81a7),this[_0x1f4a86('0xa')](_0x1f4a86('0x25')));},module['exports']=EmailImap; \ No newline at end of file diff --git a/server/services/email/lib/smtp.js b/server/services/email/lib/smtp.js index da872c4..4515c91 100644 --- a/server/services/email/lib/smtp.js +++ b/server/services/email/lib/smtp.js @@ -1 +1 @@ -const a1154_0x4fce=['nodemailer-plugin-inline-base64','use','exports','toString','prototype','nodemailer','createTransport','compile'];(function(_0x350f3a,_0x4fcebc){const _0x4eb1ef=function(_0x639c29){while(--_0x639c29){_0x350f3a['push'](_0x350f3a['shift']());}};_0x4eb1ef(++_0x4fcebc);}(a1154_0x4fce,0x17d));const a1154_0x4eb1=function(_0x350f3a,_0x4fcebc){_0x350f3a=_0x350f3a-0x0;let _0x4eb1ef=a1154_0x4fce[_0x350f3a];return _0x4eb1ef;};const _0x184d25=a1154_0x4eb1;'use strict';const nodemailer=require(_0x184d25('0x0')),inlineBase64=require(_0x184d25('0x3'));function EmailSmtp(){}EmailSmtp[_0x184d25('0x7')]['send']=function(_0x639c29,_0x31f08d){return new Promise(function(_0x45e784,_0x2d8e10){const _0x3d1f04=a1154_0x4eb1,_0x12a87d=nodemailer[_0x3d1f04('0x1')](_0x639c29);_0x12a87d[_0x3d1f04('0x4')](_0x3d1f04('0x2'),inlineBase64()),_0x12a87d['sendMail'](_0x31f08d,function(_0x3d083e,_0x186dfb){const _0x50e90d=_0x3d1f04;_0x3d083e?_0x2d8e10(_0x3d083e[_0x50e90d('0x6')]()):_0x45e784(_0x186dfb);});});},EmailSmtp[_0x184d25('0x7')]['verify']=function(_0x37151f){return new Promise(function(_0x2b1d6b,_0x2fb73d){const _0x3c6431=a1154_0x4eb1,_0x396b0d=nodemailer[_0x3c6431('0x1')](_0x37151f);_0x396b0d['verify'](function(_0x2d6342,_0xd9898){const _0x5553ee=_0x3c6431;_0x2d6342?_0x2fb73d(_0x2d6342[_0x5553ee('0x6')]()):_0xd9898?_0x2b1d6b(_0xd9898):_0x2fb73d('Not\x20verifired');});});},module[_0x184d25('0x5')]=EmailSmtp; \ No newline at end of file +const a1154_0xa17b=['sendMail','nodemailer','prototype','Not\x20verifired','use','exports','verify','createTransport','toString'];(function(_0x2b0839,_0xa17bab){const _0x4aa0b1=function(_0x304a81){while(--_0x304a81){_0x2b0839['push'](_0x2b0839['shift']());}};_0x4aa0b1(++_0xa17bab);}(a1154_0xa17b,0x15d));const a1154_0x4aa0=function(_0x2b0839,_0xa17bab){_0x2b0839=_0x2b0839-0x0;let _0x4aa0b1=a1154_0xa17b[_0x2b0839];return _0x4aa0b1;};const _0x3310de=a1154_0x4aa0;'use strict';const nodemailer=require(_0x3310de('0x3')),inlineBase64=require('nodemailer-plugin-inline-base64');function EmailSmtp(){}EmailSmtp[_0x3310de('0x4')]['send']=function(_0x304a81,_0x5d2258){return new Promise(function(_0x3cfaad,_0x1f032d){const _0x5a98ce=a1154_0x4aa0,_0x4069c5=nodemailer[_0x5a98ce('0x0')](_0x304a81);_0x4069c5[_0x5a98ce('0x6')]('compile',inlineBase64()),_0x4069c5[_0x5a98ce('0x2')](_0x5d2258,function(_0x31f427,_0x4cdc67){const _0x3aa074=_0x5a98ce;_0x31f427?_0x1f032d(_0x31f427[_0x3aa074('0x1')]()):_0x3cfaad(_0x4cdc67);});});},EmailSmtp[_0x3310de('0x4')][_0x3310de('0x8')]=function(_0x3686b2){return new Promise(function(_0x5f4539,_0x1f75b9){const _0x19b2ae=a1154_0x4aa0,_0x55a2a2=nodemailer['createTransport'](_0x3686b2);_0x55a2a2[_0x19b2ae('0x8')](function(_0x466484,_0x24c844){const _0x8fac27=_0x19b2ae;_0x466484?_0x1f75b9(_0x466484[_0x8fac27('0x1')]()):_0x24c844?_0x5f4539(_0x24c844):_0x1f75b9(_0x8fac27('0x5'));});});},module[_0x3310de('0x7')]=EmailSmtp; \ No newline at end of file diff --git a/server/services/email/lib/utils.js b/server/services/email/lib/utils.js index da3a767..a4354e7 100644 --- a/server/services/email/lib/utils.js +++ b/server/services/email/lib/utils.js @@ -1 +1 @@ -const a1155_0xdf92=['yahoo','split','name','textAsHtml','getHost','path','hotmail','subject','randomstring','parseBuffer','message','bcc','info','node-tnef','originTo','format','originCc','util','type','body','%s-%s','gmail','@xcally.com','replace','content','Title','application/ms-tnef','writeFileSync','imap.gmail.com','filename','attach','html','includes','messageId','contentType','head','isEmpty','outlook.office365.com','generate','files/attachments/','length','outlook365','join','root','anonymous','test','imap-mail.outlook.com','attachments','../../../config/logger','

Empty\x20message

','Attachments','Anonymous','parser','push','pop','from','slice','email','inReplyTo','attachment','BodyHTML','value','now','Data','address'];(function(_0xed7543,_0xdf92e9){const _0x41b150=function(_0x1c373a){while(--_0x1c373a){_0xed7543['push'](_0xed7543['shift']());}};_0x41b150(++_0xdf92e9);}(a1155_0xdf92,0x9d));const a1155_0x41b1=function(_0xed7543,_0xdf92e9){_0xed7543=_0xed7543-0x0;let _0x41b150=a1155_0xdf92[_0xed7543];return _0x41b150;};const _0x2fc22f=a1155_0x41b1;'use strict';const _=require('lodash'),moment=require('moment'),random=require(_0x2fc22f('0x2e')),fs=require('fs'),path=require(_0x2fc22f('0x2b')),util=require(_0x2fc22f('0x37')),tnef=require(_0x2fc22f('0x33')),logger=require(_0x2fc22f('0x15'))(_0x2fc22f('0x1e')),config=require('../../../config/environment');function getAddress(_0x1c373a){const _0x1947ee=_0x2fc22f,_0x443e24=_['head'](_0x1c373a[_0x1947ee('0x22')]);return _0x443e24&&_0x443e24['address']?_0x443e24[_0x1947ee('0x25')]:_0x1947ee('0x11')+random[_0x1947ee('0xb')](0x6)+_0x1947ee('0x3c');}function getFirstName(_0x304f8b){const _0x25e2c8=_0x2fc22f,_0x76daf8=_[_0x25e2c8('0x8')](_0x304f8b[_0x25e2c8('0x22')]);if(_0x76daf8&&_0x76daf8[_0x25e2c8('0x28')]){const _0xbd0897=_0x76daf8[_0x25e2c8('0x28')][_0x25e2c8('0x27')](/\s+/);return _0xbd0897[_0x25e2c8('0xd')]?_0xbd0897[_0x25e2c8('0x1d')](0x0,-0x1)[_0x25e2c8('0xf')]('\x20'):_0x76daf8['name'];}return _0x25e2c8('0x18');}function getLastName(_0x344231){const _0x5868f2=_0x2fc22f,_0x380e62=_['head'](_0x344231['value']);if(_0x380e62&&_0x380e62[_0x5868f2('0x28')]){const _0x529abe=_0x380e62['name'][_0x5868f2('0x27')](/\s+/);return _0x529abe[_0x5868f2('0xd')]>0x1?_0x529abe[_0x5868f2('0x1b')]():'';}return'';}function getMails(_0x360a65,_0x79ae3c){const _0x53ecbf=_0x2fc22f;let _0x39c674='';for(let _0x44a9f9=0x0;_0x44a9f9<_0x79ae3c[_0x53ecbf('0x22')]['length'];_0x44a9f9+=0x1){_0x79ae3c[_0x53ecbf('0x22')][_0x44a9f9][_0x53ecbf('0x25')]!==_0x360a65&&(!_[_0x53ecbf('0x9')](_0x39c674)&&(_0x39c674+=','),_0x39c674+=_0x79ae3c[_0x53ecbf('0x22')][_0x44a9f9][_0x53ecbf('0x28')]||_0x79ae3c['value'][_0x44a9f9][_0x53ecbf('0x25')]||'',_0x39c674+='\x20<',_0x39c674+=_0x79ae3c[_0x53ecbf('0x22')][_0x44a9f9]['address']?_0x79ae3c[_0x53ecbf('0x22')][_0x44a9f9]['address']:_0x53ecbf('0x11')+random['generate'](0x6)+_0x53ecbf('0x3c'),_0x39c674+='>');}return _0x39c674;}function parseEmail(_0x4baeb2,_0xb08489,_0x5740f8){const _0xb9d59=_0x2fc22f;if(_0xb08489[_0xb9d59('0x4')]){const _0x3047bd=/)<[^<]*)*<\/script>/gi;while(_0x3047bd[_0xb9d59('0x12')](_0xb08489['html'])){_0xb08489[_0xb9d59('0x4')]=_0xb08489[_0xb9d59('0x4')]['replace'](_0x3047bd,'');}_0x5740f8['body']=_0xb08489[_0xb9d59('0x4')];}else _0x5740f8[_0xb9d59('0x39')]=_0xb08489[_0xb9d59('0x29')];_0x5740f8[_0xb9d59('0x39')]&&(_0x5740f8['body']=_0x5740f8[_0xb9d59('0x39')][_0xb9d59('0x3d')](/Empty\x20message

','html','@xcally.com','push','attachment-','includes','join','slice','textAsHtml','../../../config/logger','anonymous','gmail','isEmpty','imap.gmail.com','content','attachments','name','length','subject','contentType','filename','yahoo','now','split','0x1?_0x25bfca[_0x3a7766('0x2d')]():'';}return'';}function getMails(_0x2fcd9d,_0x256ab5){const _0x53d4d0=_0x58f729;let _0x836fc9='';for(let _0x3fa1c0=0x0;_0x3fa1c0<_0x256ab5[_0x53d4d0('0x30')][_0x53d4d0('0x2')];_0x3fa1c0+=0x1){_0x256ab5[_0x53d4d0('0x30')][_0x3fa1c0][_0x53d4d0('0x2a')]!==_0x2fcd9d&&(!_[_0x53d4d0('0x3e')](_0x836fc9)&&(_0x836fc9+=','),_0x836fc9+=_0x256ab5['value'][_0x3fa1c0][_0x53d4d0('0x1')]||_0x256ab5[_0x53d4d0('0x30')][_0x3fa1c0]['address']||'',_0x836fc9+='\x20<',_0x836fc9+=_0x256ab5['value'][_0x3fa1c0]['address']?_0x256ab5[_0x53d4d0('0x30')][_0x3fa1c0][_0x53d4d0('0x2a')]:'anonymous'+random['generate'](0x6)+_0x53d4d0('0x34'),_0x836fc9+='>');}return _0x836fc9;}function parseEmail(_0x2907d5,_0x3aee02,_0x1859ff){const _0x4588ff=_0x58f729;if(_0x3aee02[_0x4588ff('0x33')]){const _0x2ab055=/)<[^<]*)*<\/script>/gi;while(_0x2ab055[_0x4588ff('0x2f')](_0x3aee02[_0x4588ff('0x33')])){_0x3aee02[_0x4588ff('0x33')]=_0x3aee02[_0x4588ff('0x33')][_0x4588ff('0x24')](_0x2ab055,'');}_0x1859ff[_0x4588ff('0x2e')]=_0x3aee02['html'];}else _0x1859ff[_0x4588ff('0x2e')]=_0x3aee02[_0x4588ff('0x3a')];_0x1859ff['body']&&(_0x1859ff[_0x4588ff('0x2e')]=_0x1859ff['body']['replace'](/0x0?this[_0x4dd0ed+'Capacity']>0x0&&this[_0x4dd0ed+_0x5b3d1c('0xe')]>=this[_0x4dd0ed+_0x5b3d1c('0x27')]?_0x5b3d1c('0x17'):_0x5b3d1c('0x26'):'idle';},Agent[_0x2823dc('0x16')][_0x2823dc('0x8')]=function(){const _0x340d12=_0x2823dc,_0x227840=[_0x340d12('0x1d'),_0x340d12('0x5'),'openchannel',_0x340d12('0x1b'),'sms',_0x340d12('0x9')];for(let _0x578c8b=0x0;_0x578c8b<_0x227840[_0x340d12('0xc')];_0x578c8b+=0x1){const _0x46395b=this['getChannelStatus'](_0x227840[_0x578c8b]);this[_0x227840[_0x578c8b]+'Status']!==_0x46395b&&(this[_0x227840[_0x578c8b]+_0x340d12('0x15')]=_[_0x340d12('0x2e')](moment()[_0x340d12('0x1e')]('x'))),this[_0x227840[_0x578c8b]+_0x340d12('0x1c')]=_0x46395b;}const _0x5c8ae8={'id':this['id'],'name':this[_0x340d12('0x22')],'online':this[_0x340d12('0x11')],'voicePause':this['voicePause'],'chatPause':this[_0x340d12('0xa')],'mailPause':this[_0x340d12('0x18')],'smsPause':this[_0x340d12('0x34')],'faxPause':this[_0x340d12('0x23')],'openchannelPause':this[_0x340d12('0x2')],'chatStatus':this[_0x340d12('0x35')],'chatStatusTime':this['chatStatusTime'],'chatCapacity':this[_0x340d12('0x1')],'chatCurrentCapacity':this[_0x340d12('0x2d')],'mailStatus':this[_0x340d12('0x2b')],'mailStatusTime':this[_0x340d12('0x19')],'mailCapacity':this['mailCapacity'],'mailCurrentCapacity':this[_0x340d12('0x36')],'faxStatus':this[_0x340d12('0x2c')],'faxStatusTime':this[_0x340d12('0x1f')],'faxCapacity':this[_0x340d12('0xd')],'faxCurrentCapacity':this[_0x340d12('0x30')],'smsStatus':this['smsStatus'],'smsStatusTime':this['smsStatusTime'],'smsCapacity':this[_0x340d12('0x20')],'smsCurrentCapacity':this[_0x340d12('0x12')],'whatsappStatus':this[_0x340d12('0xf')],'whatsappStatusTime':this[_0x340d12('0x37')],'whatsappCapacity':this[_0x340d12('0x21')],'whatsappCurrentCapacity':this[_0x340d12('0x6')],'openchannelStatus':this[_0x340d12('0x7')],'openchannelStatusTime':this[_0x340d12('0x38')],'openchannelCapacity':this['openchannelCapacity'],'openchannelCurrentCapacity':this[_0x340d12('0x13')],'busy':this[_0x340d12('0x32')],'busyQueue':this['busyQueue']},_0x2cf17f=md5(JSON['stringify'](_0x5c8ae8));this['md5']!==_0x2cf17f&&(this['md5']=_0x2cf17f,io[_0x340d12('0x31')](_0x340d12('0x10'),_0x5c8ae8));},module[_0x2823dc('0x3')]=Agent; \ No newline at end of file +const a1165_0x7e41=['mailPause','busyQueue','Capacity','whatsappCurrentCapacity','user:save','stringify','getChannelStatus','whatsappStatus','toNumber','voicePause','openchannel','smsPause','mailCurrentCapacity','smsStatus','unknown','format','faxPause','smsStatusTime','length','openchannelStatusTime','updateRealtime','lodash','exports','whatsappStatusTime','md5','whatsapp','smsCapacity','faxCapacity','chatStatus','working','mailCapacity','chatPause','chatStatusTime','openchannelCapacity','openchannelStatus','whatsappCapacity','../../../rediscache','smsCurrentCapacity','maxcapacity','moment','Status','chatCurrentCapacity','name','StatusTime','online','mail','openchannelCurrentCapacity','faxCurrentCapacity','faxStatus','faxStatusTime','mailStatus','prototype','busy','chatCapacity','openchannelPause','sms'];(function(_0x581050,_0x7e4128){const _0x2f536d=function(_0x2ddfca){while(--_0x2ddfca){_0x581050['push'](_0x581050['shift']());}};_0x2f536d(++_0x7e4128);}(a1165_0x7e41,0x79));const a1165_0x2f53=function(_0x581050,_0x7e4128){_0x581050=_0x581050-0x0;let _0x2f536d=a1165_0x7e41[_0x581050];return _0x2f536d;};const _0x43ce14=a1165_0x2f53;'use strict';const _=require(_0x43ce14('0xc')),moment=require(_0x43ce14('0x1e')),md5=require(_0x43ce14('0xf')),{getSocket}=require(_0x43ce14('0x1b')),io=getSocket();function Agent(_0x2ddfca){const _0x235757=_0x43ce14;this['id']=_0x2ddfca['id']||0x0,this[_0x235757('0x21')]=_0x2ddfca[_0x235757('0x21')]||'',this[_0x235757('0x23')]=_0x2ddfca[_0x235757('0x23')]||!![],this[_0x235757('0x0')]=_0x2ddfca[_0x235757('0x0')]||![],this[_0x235757('0x16')]=_0x2ddfca[_0x235757('0x16')]||![],this['mailPause']=_0x2ddfca[_0x235757('0x2f')]||![],this[_0x235757('0x7')]=_0x2ddfca[_0x235757('0x7')]||![],this['smsPause']=_0x2ddfca[_0x235757('0x2')]||![],this['openchannelPause']=_0x2ddfca[_0x235757('0x2d')]||![],this[_0x235757('0x13')]='unknown',this[_0x235757('0x17')]=0x0,this[_0x235757('0x2c')]=_0x2ddfca['chatCapacity']||0x0,this[_0x235757('0x20')]=0x0,this[_0x235757('0x29')]=_0x235757('0x5'),this['mailStatusTime']=0x0,this[_0x235757('0x15')]=_0x2ddfca[_0x235757('0x15')]||0x0,this[_0x235757('0x3')]=0x0,this[_0x235757('0x27')]=_0x235757('0x5'),this[_0x235757('0x28')]=0x0,this[_0x235757('0x12')]=_0x2ddfca['faxCapacity']||0x0,this[_0x235757('0x26')]=0x0,this[_0x235757('0x4')]=_0x235757('0x5'),this['smsStatusTime']=0x0,this[_0x235757('0x11')]=_0x2ddfca[_0x235757('0x11')]||0x0,this['smsCurrentCapacity']=0x0,this[_0x235757('0x36')]=_0x235757('0x5'),this[_0x235757('0xe')]=0x0,this[_0x235757('0x1a')]=_0x2ddfca[_0x235757('0x1a')]||0x0,this[_0x235757('0x32')]=0x0,this[_0x235757('0x19')]=_0x235757('0x5'),this['openchannelStatusTime']=0x0,this[_0x235757('0x18')]=_0x2ddfca['openchannelCapacity']||0x0,this['openchannelCurrentCapacity']=0x0,this['busy']=![],this[_0x235757('0x30')]=undefined,this[_0x235757('0xf')]='',this[_0x235757('0xb')]();}Agent[_0x43ce14('0x2a')][_0x43ce14('0x35')]=function(_0x2a53b4){const _0x5ace0c=_0x43ce14;return this[_0x2a53b4+'CurrentCapacity']>0x0?this[_0x2a53b4+_0x5ace0c('0x31')]>0x0&&this[_0x2a53b4+'CurrentCapacity']>=this[_0x2a53b4+'Capacity']?_0x5ace0c('0x1d'):_0x5ace0c('0x14'):'idle';},Agent[_0x43ce14('0x2a')][_0x43ce14('0xb')]=function(){const _0x63096c=_0x43ce14,_0x100544=[_0x63096c('0x24'),'chat',_0x63096c('0x1'),'fax',_0x63096c('0x2e'),_0x63096c('0x10')];for(let _0x320efc=0x0;_0x320efc<_0x100544[_0x63096c('0x9')];_0x320efc+=0x1){const _0x33acb1=this[_0x63096c('0x35')](_0x100544[_0x320efc]);this[_0x100544[_0x320efc]+_0x63096c('0x1f')]!==_0x33acb1&&(this[_0x100544[_0x320efc]+_0x63096c('0x22')]=_[_0x63096c('0x37')](moment()[_0x63096c('0x6')]('x'))),this[_0x100544[_0x320efc]+_0x63096c('0x1f')]=_0x33acb1;}const _0x42a6b3={'id':this['id'],'name':this[_0x63096c('0x21')],'online':this[_0x63096c('0x23')],'voicePause':this[_0x63096c('0x0')],'chatPause':this[_0x63096c('0x16')],'mailPause':this[_0x63096c('0x2f')],'smsPause':this[_0x63096c('0x2')],'faxPause':this[_0x63096c('0x7')],'openchannelPause':this[_0x63096c('0x2d')],'chatStatus':this[_0x63096c('0x13')],'chatStatusTime':this[_0x63096c('0x17')],'chatCapacity':this[_0x63096c('0x2c')],'chatCurrentCapacity':this[_0x63096c('0x20')],'mailStatus':this[_0x63096c('0x29')],'mailStatusTime':this['mailStatusTime'],'mailCapacity':this[_0x63096c('0x15')],'mailCurrentCapacity':this[_0x63096c('0x3')],'faxStatus':this['faxStatus'],'faxStatusTime':this[_0x63096c('0x28')],'faxCapacity':this[_0x63096c('0x12')],'faxCurrentCapacity':this['faxCurrentCapacity'],'smsStatus':this[_0x63096c('0x4')],'smsStatusTime':this[_0x63096c('0x8')],'smsCapacity':this[_0x63096c('0x11')],'smsCurrentCapacity':this[_0x63096c('0x1c')],'whatsappStatus':this[_0x63096c('0x36')],'whatsappStatusTime':this['whatsappStatusTime'],'whatsappCapacity':this[_0x63096c('0x1a')],'whatsappCurrentCapacity':this[_0x63096c('0x32')],'openchannelStatus':this[_0x63096c('0x19')],'openchannelStatusTime':this[_0x63096c('0xa')],'openchannelCapacity':this['openchannelCapacity'],'openchannelCurrentCapacity':this[_0x63096c('0x25')],'busy':this[_0x63096c('0x2b')],'busyQueue':this[_0x63096c('0x30')]},_0x3d5d87=md5(JSON[_0x63096c('0x34')](_0x42a6b3));this['md5']!==_0x3d5d87&&(this['md5']=_0x3d5d87,io['emit'](_0x63096c('0x33'),_0x42a6b3));},module[_0x43ce14('0xd')]=Agent; \ No newline at end of file diff --git a/server/services/routing/model/chatQueue.js b/server/services/routing/model/chatQueue.js index 1191004..0d67192 100644 --- a/server/services/routing/model/chatQueue.js +++ b/server/services/routing/model/chatQueue.js @@ -1 +1 @@ -const a1166_0x2038=['loggedIn','emit','exports','prototype','chat:queue:%s','stringify','md5','updateRealtime','_rr','Agents','online','mapAgentsId','beepall','waiting','length','name','updateRouting','available','timeout','format','paused','strategy'];(function(_0x2c12be,_0x203805){const _0x202a43=function(_0x333be0){while(--_0x333be0){_0x2c12be['push'](_0x2c12be['shift']());}};_0x202a43(++_0x203805);}(a1166_0x2038,0xd8));const a1166_0x202a=function(_0x2c12be,_0x203805){_0x2c12be=_0x2c12be-0x0;let _0x202a43=a1166_0x2038[_0x2c12be];return _0x202a43;};const _0x307d49=a1166_0x202a;'use strict';const _=require('lodash'),md5=require(_0x307d49('0xa')),util=require('util'),{getSocket}=require('../../../rediscache'),io=getSocket();function ChatQueue(_0x333be0){const _0x27357c=_0x307d49;this['id']=_0x333be0['id']||0x0,this[_0x27357c('0x13')]=_0x333be0[_0x27357c('0x13')]||'',this[_0x27357c('0x0')]=_0x333be0[_0x27357c('0x0')]||0xa,this['strategy']=_0x333be0[_0x27357c('0x3')]||_0x27357c('0x10'),this['Agents']=_0x333be0[_0x27357c('0xd')],this[_0x27357c('0xf')]={},this[_0x27357c('0x11')]=0x0,this[_0x27357c('0xa')]='',this[_0x27357c('0x14')](),this[_0x27357c('0xb')]();}ChatQueue[_0x307d49('0x7')][_0x307d49('0x14')]=function(){const _0x824941=_0x307d49,_0x413cfe=this[_0x824941('0xf')][_0x824941('0xc')];this[_0x824941('0xf')]=_['map'](this[_0x824941('0xd')],'id'),this[_0x824941('0xf')][_0x824941('0xc')]=_0x413cfe;},ChatQueue[_0x307d49('0x7')][_0x307d49('0xb')]=function(){const _0x442c5d=_0x307d49;this[_0x442c5d('0x4')]=0x0,this['paused']=0x0;for(let _0x5a960c=0x0;_0x5a960c=0x0?this['available']:0x0;const _0x2edc6c={'id':this['id'],'available':this['available'],'loggedIn':this[_0x442c5d('0x4')],'name':this[_0x442c5d('0x13')],'paused':this[_0x442c5d('0x2')],'waiting':this[_0x442c5d('0x11')]},_0x19a1f8=md5(JSON[_0x442c5d('0x9')](_0x2edc6c));this['md5']!==_0x19a1f8&&(this[_0x442c5d('0xa')]=_0x19a1f8,io['to'](util[_0x442c5d('0x1')](_0x442c5d('0x8'),_0x2edc6c['name']))[_0x442c5d('0x5')]('chat_queue:save',_0x2edc6c));},module[_0x307d49('0x6')]=ChatQueue; \ No newline at end of file +const a1166_0x4f65=['md5','paused','beepall','prototype','_rr','updateRouting','lodash','Agents','exports','loggedIn','strategy','format','waiting','emit','util','chatPause','../../../rediscache','timeout','name','available','mapAgentsId','updateRealtime'];(function(_0x488a61,_0x4f65d4){const _0xc11bea=function(_0x3ade52){while(--_0x3ade52){_0x488a61['push'](_0x488a61['shift']());}};_0xc11bea(++_0x4f65d4);}(a1166_0x4f65,0x80));const a1166_0xc11b=function(_0x488a61,_0x4f65d4){_0x488a61=_0x488a61-0x0;let _0xc11bea=a1166_0x4f65[_0x488a61];return _0xc11bea;};const _0x27c8d5=a1166_0xc11b;'use strict';const _=require(_0x27c8d5('0xa')),md5=require(_0x27c8d5('0x4')),util=require(_0x27c8d5('0x12')),{getSocket}=require(_0x27c8d5('0x14')),io=getSocket();function ChatQueue(_0x3ade52){const _0x586180=_0x27c8d5;this['id']=_0x3ade52['id']||0x0,this['name']=_0x3ade52['name']||'',this[_0x586180('0x15')]=_0x3ade52['timeout']||0xa,this[_0x586180('0xe')]=_0x3ade52[_0x586180('0xe')]||_0x586180('0x6'),this[_0x586180('0xb')]=_0x3ade52[_0x586180('0xb')],this[_0x586180('0x2')]={},this[_0x586180('0x10')]=0x0,this[_0x586180('0x4')]='',this[_0x586180('0x9')](),this[_0x586180('0x3')]();}ChatQueue[_0x27c8d5('0x7')][_0x27c8d5('0x9')]=function(){const _0x2eb7b9=_0x27c8d5,_0x245b92=this[_0x2eb7b9('0x2')][_0x2eb7b9('0x8')];this[_0x2eb7b9('0x2')]=_['map'](this[_0x2eb7b9('0xb')],'id'),this[_0x2eb7b9('0x2')][_0x2eb7b9('0x8')]=_0x245b92;},ChatQueue[_0x27c8d5('0x7')]['updateRealtime']=function(){const _0x124ccf=_0x27c8d5;this[_0x124ccf('0xd')]=0x0,this[_0x124ccf('0x5')]=0x0;for(let _0x1e0b96=0x0;_0x1e0b96=0x0?this[_0x124ccf('0x1')]:0x0;const _0x250f6e={'id':this['id'],'available':this[_0x124ccf('0x1')],'loggedIn':this[_0x124ccf('0xd')],'name':this[_0x124ccf('0x0')],'paused':this[_0x124ccf('0x5')],'waiting':this[_0x124ccf('0x10')]},_0x477baf=md5(JSON['stringify'](_0x250f6e));this[_0x124ccf('0x4')]!==_0x477baf&&(this[_0x124ccf('0x4')]=_0x477baf,io['to'](util[_0x124ccf('0xf')]('chat:queue:%s',_0x250f6e['name']))[_0x124ccf('0x11')]('chat_queue:save',_0x250f6e));},module[_0x27c8d5('0xc')]=ChatQueue; \ No newline at end of file diff --git a/server/services/routing/model/faxQueue.js b/server/services/routing/model/faxQueue.js index 7ab61c4..0637351 100644 --- a/server/services/routing/model/faxQueue.js +++ b/server/services/routing/model/faxQueue.js @@ -1 +1 @@ -const a1167_0xd5a0=['fax:queue:%s','name','prototype','map','../../../rediscache','loggedIn','format','lodash','util','strategy','waiting','mapAgentsId','length','online','Agents','paused','md5','_rr','updateRealtime','available','updateRouting','stringify','faxPause'];(function(_0x3913af,_0xd5a07c){const _0x4cec91=function(_0x266206){while(--_0x266206){_0x3913af['push'](_0x3913af['shift']());}};_0x4cec91(++_0xd5a07c);}(a1167_0xd5a0,0x1f4));const a1167_0x4cec=function(_0x3913af,_0xd5a07c){_0x3913af=_0x3913af-0x0;let _0x4cec91=a1167_0xd5a0[_0x3913af];return _0x4cec91;};const _0x171ef2=a1167_0x4cec;'use strict';const _=require(_0x171ef2('0xd')),md5=require(_0x171ef2('0x16')),util=require(_0x171ef2('0xe')),{getSocket}=require(_0x171ef2('0xa')),io=getSocket();function FaxQueue(_0x266206){const _0x1eb579=_0x171ef2;this['id']=_0x266206['id']||0x0,this['name']=_0x266206['name']||'',this['timeout']=_0x266206['timeout']||0xa,this['strategy']=_0x266206[_0x1eb579('0xf')]||'beepall',this['Agents']=_0x266206[_0x1eb579('0x14')],this['mapAgentsId']={},this[_0x1eb579('0x10')]=0x0,this[_0x1eb579('0x16')]='',this[_0x1eb579('0x3')](),this[_0x1eb579('0x1')]();}FaxQueue['prototype']['updateRouting']=function(){const _0x39b55b=_0x171ef2,_0x247604=this['mapAgentsId'][_0x39b55b('0x0')];this[_0x39b55b('0x11')]=_[_0x39b55b('0x9')](this[_0x39b55b('0x14')],'id'),this[_0x39b55b('0x11')][_0x39b55b('0x0')]=_0x247604;},FaxQueue[_0x171ef2('0x8')]['updateRealtime']=function(){const _0x7cbe24=_0x171ef2;this[_0x7cbe24('0xb')]=0x0,this[_0x7cbe24('0x15')]=0x0;for(let _0x49d19b=0x0;_0x49d19b=0x0?this[_0x7cbe24('0x2')]:0x0;const _0x13811a={'id':this['id'],'available':this[_0x7cbe24('0x2')],'loggedIn':this['loggedIn'],'name':this['name'],'paused':this['paused'],'waiting':this[_0x7cbe24('0x10')]},_0x4116a7=md5(JSON[_0x7cbe24('0x4')](_0x13811a));this[_0x7cbe24('0x16')]!==_0x4116a7&&(this[_0x7cbe24('0x16')]=_0x4116a7,io['to'](util[_0x7cbe24('0xc')](_0x7cbe24('0x6'),_0x13811a[_0x7cbe24('0x7')]))['emit']('fax_queue:save',_0x13811a));},module['exports']=FaxQueue; \ No newline at end of file +const a1167_0x1b1e=['emit','name','paused','beepall','lodash','exports','timeout','prototype','faxPause','updateRealtime','length','format','fax_queue:save','waiting','util','md5','mapAgentsId','online','updateRouting','Agents','available','strategy','loggedIn'];(function(_0x1e5b0e,_0x1b1ed6){const _0x58dd1b=function(_0x55cc2c){while(--_0x55cc2c){_0x1e5b0e['push'](_0x1e5b0e['shift']());}};_0x58dd1b(++_0x1b1ed6);}(a1167_0x1b1e,0x1aa));const a1167_0x58dd=function(_0x1e5b0e,_0x1b1ed6){_0x1e5b0e=_0x1e5b0e-0x0;let _0x58dd1b=a1167_0x1b1e[_0x1e5b0e];return _0x58dd1b;};const _0xc860fe=a1167_0x58dd;'use strict';const _=require(_0xc860fe('0xf')),md5=require('md5'),util=require(_0xc860fe('0x2')),{getSocket}=require('../../../rediscache'),io=getSocket();function FaxQueue(_0x55cc2c){const _0x4648cf=_0xc860fe;this['id']=_0x55cc2c['id']||0x0,this[_0x4648cf('0xc')]=_0x55cc2c[_0x4648cf('0xc')]||'',this['timeout']=_0x55cc2c[_0x4648cf('0x11')]||0xa,this[_0x4648cf('0x9')]=_0x55cc2c[_0x4648cf('0x9')]||_0x4648cf('0xe'),this[_0x4648cf('0x7')]=_0x55cc2c[_0x4648cf('0x7')],this[_0x4648cf('0x4')]={},this[_0x4648cf('0x1')]=0x0,this['md5']='',this[_0x4648cf('0x6')](),this[_0x4648cf('0x14')]();}FaxQueue[_0xc860fe('0x12')][_0xc860fe('0x6')]=function(){const _0x5f06d7=_0xc860fe,_0x4cebf0=this[_0x5f06d7('0x4')]['_rr'];this['mapAgentsId']=_['map'](this[_0x5f06d7('0x7')],'id'),this['mapAgentsId']['_rr']=_0x4cebf0;},FaxQueue[_0xc860fe('0x12')][_0xc860fe('0x14')]=function(){const _0x3d0bef=_0xc860fe;this[_0x3d0bef('0xa')]=0x0,this[_0x3d0bef('0xd')]=0x0;for(let _0x27cf5f=0x0;_0x27cf5f=0x0?this[_0x3d0bef('0x8')]:0x0;const _0x2c2ad5={'id':this['id'],'available':this[_0x3d0bef('0x8')],'loggedIn':this['loggedIn'],'name':this['name'],'paused':this[_0x3d0bef('0xd')],'waiting':this[_0x3d0bef('0x1')]},_0x5910f6=md5(JSON['stringify'](_0x2c2ad5));this['md5']!==_0x5910f6&&(this[_0x3d0bef('0x3')]=_0x5910f6,io['to'](util[_0x3d0bef('0x16')]('fax:queue:%s',_0x2c2ad5[_0x3d0bef('0xc')]))[_0x3d0bef('0xb')](_0x3d0bef('0x0'),_0x2c2ad5));},module[_0xc860fe('0x10')]=FaxQueue; \ No newline at end of file diff --git a/server/services/routing/model/interval.js b/server/services/routing/model/interval.js index 56d6d07..0c1e9d0 100644 --- a/server/services/routing/model/interval.js +++ b/server/services/routing/model/interval.js @@ -1 +1 @@ -var a1168_0x4b60=['name','exports'];(function(_0x3c96f9,_0x4b608f){var _0x7582f5=function(_0x8e3cec){while(--_0x8e3cec){_0x3c96f9['push'](_0x3c96f9['shift']());}};_0x7582f5(++_0x4b608f);}(a1168_0x4b60,0x143));var a1168_0x7582=function(_0x3c96f9,_0x4b608f){_0x3c96f9=_0x3c96f9-0x0;var _0x7582f5=a1168_0x4b60[_0x3c96f9];return _0x7582f5;};var _0x273239=a1168_0x7582;'use strict';function Interval(_0x8e3cec){var _0xa40161=a1168_0x7582;this['id']=_0x8e3cec['id']||0x0,this[_0xa40161('0x1')]=_0x8e3cec[_0xa40161('0x1')]||'',this['Intervals']=_0x8e3cec['Intervals']||{};}module[_0x273239('0x0')]=Interval; \ No newline at end of file +var a1168_0x2466=['name','Intervals','exports'];(function(_0x120ae9,_0x2466d2){var _0x345b9e=function(_0x2a00a3){while(--_0x2a00a3){_0x120ae9['push'](_0x120ae9['shift']());}};_0x345b9e(++_0x2466d2);}(a1168_0x2466,0xd3));var a1168_0x345b=function(_0x120ae9,_0x2466d2){_0x120ae9=_0x120ae9-0x0;var _0x345b9e=a1168_0x2466[_0x120ae9];return _0x345b9e;};var _0xd1e8d4=a1168_0x345b;'use strict';function Interval(_0x2a00a3){var _0x429eca=a1168_0x345b;this['id']=_0x2a00a3['id']||0x0,this[_0x429eca('0x2')]=_0x2a00a3[_0x429eca('0x2')]||'',this[_0x429eca('0x0')]=_0x2a00a3[_0x429eca('0x0')]||{};}module[_0xd1e8d4('0x1')]=Interval; \ No newline at end of file diff --git a/server/services/routing/model/mailQueue.js b/server/services/routing/model/mailQueue.js index c34d759..976f4d5 100644 --- a/server/services/routing/model/mailQueue.js +++ b/server/services/routing/model/mailQueue.js @@ -1 +1 @@ -const a1169_0x5980=['map','loggedIn','updateRouting','mail:queue:%s','waiting','md5','Agents','strategy','available','_rr','updateRealtime','length','beepall','emit','online','mailPause','timeout','paused','stringify','mail_queue:save','prototype','name','../../../rediscache','mapAgentsId','format'];(function(_0x43763b,_0x598048){const _0x3e6538=function(_0x140c44){while(--_0x140c44){_0x43763b['push'](_0x43763b['shift']());}};_0x3e6538(++_0x598048);}(a1169_0x5980,0x83));const a1169_0x3e65=function(_0x43763b,_0x598048){_0x43763b=_0x43763b-0x0;let _0x3e6538=a1169_0x5980[_0x43763b];return _0x3e6538;};const _0x50cbdf=a1169_0x3e65;'use strict';const _=require('lodash'),md5=require('md5'),util=require('util'),{getSocket}=require(_0x50cbdf('0x10')),io=getSocket();function MailQueue(_0x140c44){const _0x5afd02=_0x50cbdf;this['id']=_0x140c44['id']||0x0,this[_0x5afd02('0xf')]=_0x140c44[_0x5afd02('0xf')]||'',this[_0x5afd02('0xa')]=_0x140c44[_0x5afd02('0xa')]||0xa,this['strategy']=_0x140c44[_0x5afd02('0x1')]||_0x5afd02('0x6'),this[_0x5afd02('0x0')]=_0x140c44[_0x5afd02('0x0')],this['mapAgentsId']={},this['waiting']=0x0,this[_0x5afd02('0x18')]='',this['updateRouting'](),this[_0x5afd02('0x4')]();}MailQueue[_0x50cbdf('0xe')][_0x50cbdf('0x15')]=function(){const _0x12d238=_0x50cbdf,_0x18ef9c=this['mapAgentsId']['_rr'];this[_0x12d238('0x11')]=_[_0x12d238('0x13')](this[_0x12d238('0x0')],'id'),this[_0x12d238('0x11')][_0x12d238('0x3')]=_0x18ef9c;},MailQueue[_0x50cbdf('0xe')][_0x50cbdf('0x4')]=function(){const _0x21a16f=_0x50cbdf;this[_0x21a16f('0x14')]=0x0,this[_0x21a16f('0xb')]=0x0;for(let _0x203671=0x0;_0x203671=0x0?this['available']:0x0;const _0x3bd4e8={'id':this['id'],'available':this[_0x21a16f('0x2')],'loggedIn':this[_0x21a16f('0x14')],'name':this[_0x21a16f('0xf')],'paused':this[_0x21a16f('0xb')],'waiting':this[_0x21a16f('0x17')]},_0x1861f6=md5(JSON[_0x21a16f('0xc')](_0x3bd4e8));this[_0x21a16f('0x18')]!==_0x1861f6&&(this[_0x21a16f('0x18')]=_0x1861f6,io['to'](util[_0x21a16f('0x12')](_0x21a16f('0x16'),_0x3bd4e8[_0x21a16f('0xf')]))[_0x21a16f('0x7')](_0x21a16f('0xd'),_0x3bd4e8));},module['exports']=MailQueue; \ No newline at end of file +const a1169_0x3876=['length','timeout','prototype','mapAgentsId','util','waiting','updateRealtime','lodash','loggedIn','mail:queue:%s','format','available','mailPause','updateRouting','name','emit','map','../../../rediscache','exports','md5','_rr','strategy','paused','stringify','Agents'];(function(_0x117891,_0x38767c){const _0xe7a527=function(_0x2c3ea1){while(--_0x2c3ea1){_0x117891['push'](_0x117891['shift']());}};_0xe7a527(++_0x38767c);}(a1169_0x3876,0x1a9));const a1169_0xe7a5=function(_0x117891,_0x38767c){_0x117891=_0x117891-0x0;let _0xe7a527=a1169_0x3876[_0x117891];return _0xe7a527;};const _0x40f3da=a1169_0xe7a5;'use strict';const _=require(_0x40f3da('0x7')),md5=require(_0x40f3da('0x13')),util=require(_0x40f3da('0x4')),{getSocket}=require(_0x40f3da('0x11')),io=getSocket();function MailQueue(_0x2c3ea1){const _0x214d81=_0x40f3da;this['id']=_0x2c3ea1['id']||0x0,this[_0x214d81('0xe')]=_0x2c3ea1[_0x214d81('0xe')]||'',this['timeout']=_0x2c3ea1[_0x214d81('0x1')]||0xa,this[_0x214d81('0x15')]=_0x2c3ea1[_0x214d81('0x15')]||'beepall',this['Agents']=_0x2c3ea1['Agents'],this[_0x214d81('0x3')]={},this[_0x214d81('0x5')]=0x0,this[_0x214d81('0x13')]='',this['updateRouting'](),this['updateRealtime']();}MailQueue[_0x40f3da('0x2')][_0x40f3da('0xd')]=function(){const _0x11decf=_0x40f3da,_0x4b758b=this[_0x11decf('0x3')]['_rr'];this[_0x11decf('0x3')]=_[_0x11decf('0x10')](this['Agents'],'id'),this[_0x11decf('0x3')][_0x11decf('0x14')]=_0x4b758b;},MailQueue[_0x40f3da('0x2')][_0x40f3da('0x6')]=function(){const _0x117290=_0x40f3da;this[_0x117290('0x8')]=0x0,this[_0x117290('0x16')]=0x0;for(let _0x159310=0x0;_0x159310=0x0?this[_0x117290('0xb')]:0x0;const _0x5a7da5={'id':this['id'],'available':this[_0x117290('0xb')],'loggedIn':this[_0x117290('0x8')],'name':this[_0x117290('0xe')],'paused':this[_0x117290('0x16')],'waiting':this['waiting']},_0x1bf6c5=md5(JSON[_0x117290('0x17')](_0x5a7da5));this[_0x117290('0x13')]!==_0x1bf6c5&&(this[_0x117290('0x13')]=_0x1bf6c5,io['to'](util[_0x117290('0xa')](_0x117290('0x9'),_0x5a7da5[_0x117290('0xe')]))[_0x117290('0xf')]('mail_queue:save',_0x5a7da5));},module[_0x40f3da('0x12')]=MailQueue; \ No newline at end of file diff --git a/server/services/routing/model/openchannelQueue.js b/server/services/routing/model/openchannelQueue.js index 535b102..339cfa0 100644 --- a/server/services/routing/model/openchannelQueue.js +++ b/server/services/routing/model/openchannelQueue.js @@ -1 +1 @@ -const a1170_0x2fa8=['_rr','md5','length','strategy','timeout','updateRealtime','util','loggedIn','emit','openchannel_queue:save','map','Agents','mapAgentsId','../../../rediscache','prototype','available','name','waiting','openchannel:queue:%s','exports','paused'];(function(_0x46f211,_0x2fa89a){const _0x3a254b=function(_0x163b6b){while(--_0x163b6b){_0x46f211['push'](_0x46f211['shift']());}};_0x3a254b(++_0x2fa89a);}(a1170_0x2fa8,0x147));const a1170_0x3a25=function(_0x46f211,_0x2fa89a){_0x46f211=_0x46f211-0x0;let _0x3a254b=a1170_0x2fa8[_0x46f211];return _0x3a254b;};const _0xb417a6=a1170_0x3a25;'use strict';const _=require('lodash'),md5=require(_0xb417a6('0xa')),util=require(_0xb417a6('0xf')),{getSocket}=require(_0xb417a6('0x1')),io=getSocket();function OpenchannelQueue(_0x163b6b){const _0x230074=_0xb417a6;this['id']=_0x163b6b['id']||0x0,this[_0x230074('0x4')]=_0x163b6b[_0x230074('0x4')]||'',this[_0x230074('0xd')]=_0x163b6b['timeout']||0xa,this['strategy']=_0x163b6b[_0x230074('0xc')]||'beepall',this[_0x230074('0x14')]=_0x163b6b[_0x230074('0x14')],this['mapAgentsId']={},this['waiting']=0x0,this[_0x230074('0xa')]='',this['updateRouting'](),this[_0x230074('0xe')]();}OpenchannelQueue[_0xb417a6('0x2')]['updateRouting']=function(){const _0x5f2459=_0xb417a6,_0x39a9e3=this[_0x5f2459('0x0')][_0x5f2459('0x9')];this['mapAgentsId']=_[_0x5f2459('0x13')](this[_0x5f2459('0x14')],'id'),this[_0x5f2459('0x0')][_0x5f2459('0x9')]=_0x39a9e3;},OpenchannelQueue[_0xb417a6('0x2')][_0xb417a6('0xe')]=function(){const _0x4efb98=_0xb417a6;this[_0x4efb98('0x10')]=0x0,this[_0x4efb98('0x8')]=0x0;for(let _0x4e7de=0x0;_0x4e7de=0x0?this[_0x4efb98('0x3')]:0x0;const _0x2d4691={'id':this['id'],'available':this[_0x4efb98('0x3')],'loggedIn':this[_0x4efb98('0x10')],'name':this[_0x4efb98('0x4')],'paused':this[_0x4efb98('0x8')],'waiting':this[_0x4efb98('0x5')]},_0x1537b5=md5(JSON['stringify'](_0x2d4691));this[_0x4efb98('0xa')]!==_0x1537b5&&(this['md5']=_0x1537b5,io['to'](util['format'](_0x4efb98('0x6'),_0x2d4691[_0x4efb98('0x4')]))[_0x4efb98('0x11')](_0x4efb98('0x12'),_0x2d4691));},module[_0xb417a6('0x7')]=OpenchannelQueue; \ No newline at end of file +const a1170_0x2876=['length','md5','updateRouting','loggedIn','openchannel:queue:%s','map','format','available','strategy','Agents','util','updateRealtime','beepall','_rr','online','timeout','prototype','paused','waiting','mapAgentsId','name','exports','openchannelPause'];(function(_0x2bbe85,_0x287694){const _0x725f27=function(_0x25416a){while(--_0x25416a){_0x2bbe85['push'](_0x2bbe85['shift']());}};_0x725f27(++_0x287694);}(a1170_0x2876,0x15a));const a1170_0x725f=function(_0x2bbe85,_0x287694){_0x2bbe85=_0x2bbe85-0x0;let _0x725f27=a1170_0x2876[_0x2bbe85];return _0x725f27;};const _0x967d6c=a1170_0x725f;'use strict';const _=require('lodash'),md5=require(_0x967d6c('0x0')),util=require(_0x967d6c('0x9')),{getSocket}=require('../../../rediscache'),io=getSocket();function OpenchannelQueue(_0x25416a){const _0x59a1b6=_0x967d6c;this['id']=_0x25416a['id']||0x0,this[_0x59a1b6('0x13')]=_0x25416a[_0x59a1b6('0x13')]||'',this[_0x59a1b6('0xe')]=_0x25416a[_0x59a1b6('0xe')]||0xa,this['strategy']=_0x25416a[_0x59a1b6('0x7')]||_0x59a1b6('0xb'),this[_0x59a1b6('0x8')]=_0x25416a[_0x59a1b6('0x8')],this['mapAgentsId']={},this[_0x59a1b6('0x11')]=0x0,this['md5']='',this[_0x59a1b6('0x1')](),this[_0x59a1b6('0xa')]();}OpenchannelQueue['prototype'][_0x967d6c('0x1')]=function(){const _0xc7fe27=_0x967d6c,_0x53d7c8=this[_0xc7fe27('0x12')][_0xc7fe27('0xc')];this[_0xc7fe27('0x12')]=_[_0xc7fe27('0x4')](this[_0xc7fe27('0x8')],'id'),this[_0xc7fe27('0x12')][_0xc7fe27('0xc')]=_0x53d7c8;},OpenchannelQueue[_0x967d6c('0xf')]['updateRealtime']=function(){const _0x49a2d3=_0x967d6c;this['loggedIn']=0x0,this[_0x49a2d3('0x10')]=0x0;for(let _0x567798=0x0;_0x567798=0x0?this[_0x49a2d3('0x6')]:0x0;const _0x590a3c={'id':this['id'],'available':this[_0x49a2d3('0x6')],'loggedIn':this[_0x49a2d3('0x2')],'name':this[_0x49a2d3('0x13')],'paused':this['paused'],'waiting':this['waiting']},_0x23f2b7=md5(JSON['stringify'](_0x590a3c));this[_0x49a2d3('0x0')]!==_0x23f2b7&&(this['md5']=_0x23f2b7,io['to'](util[_0x49a2d3('0x5')](_0x49a2d3('0x3'),_0x590a3c[_0x49a2d3('0x13')]))['emit']('openchannel_queue:save',_0x590a3c));},module[_0x967d6c('0x14')]=OpenchannelQueue; \ No newline at end of file diff --git a/server/services/routing/model/smsQueue.js b/server/services/routing/model/smsQueue.js index b9908a8..759aef1 100644 --- a/server/services/routing/model/smsQueue.js +++ b/server/services/routing/model/smsQueue.js @@ -1 +1 @@ -const a1171_0x56c0=['../../../rediscache','loggedIn','md5','updateRouting','exports','paused','timeout','stringify','util','prototype','strategy','sms:queue:%s','emit','updateRealtime','online','name','_rr','sms_queue:save','length','map','waiting','Agents','beepall','available','lodash','mapAgentsId','smsPause'];(function(_0x23fcfe,_0x56c041){const _0x3a7145=function(_0x9ad763){while(--_0x9ad763){_0x23fcfe['push'](_0x23fcfe['shift']());}};_0x3a7145(++_0x56c041);}(a1171_0x56c0,0x149));const a1171_0x3a71=function(_0x23fcfe,_0x56c041){_0x23fcfe=_0x23fcfe-0x0;let _0x3a7145=a1171_0x56c0[_0x23fcfe];return _0x3a7145;};const _0x438da3=a1171_0x3a71;'use strict';const _=require(_0x438da3('0x13')),md5=require('md5'),util=require(_0x438da3('0x3')),{getSocket}=require(_0x438da3('0x16')),io=getSocket();function SmsQueue(_0x9ad763){const _0x24362a=_0x438da3;this['id']=_0x9ad763['id']||0x0,this['name']=_0x9ad763[_0x24362a('0xa')]||'',this[_0x24362a('0x1')]=_0x9ad763[_0x24362a('0x1')]||0xa,this[_0x24362a('0x5')]=_0x9ad763[_0x24362a('0x5')]||_0x24362a('0x11'),this[_0x24362a('0x10')]=_0x9ad763[_0x24362a('0x10')],this[_0x24362a('0x14')]={},this[_0x24362a('0xf')]=0x0,this[_0x24362a('0x18')]='',this[_0x24362a('0x19')](),this[_0x24362a('0x8')]();}SmsQueue[_0x438da3('0x4')]['updateRouting']=function(){const _0x18b683=_0x438da3,_0x2789b2=this[_0x18b683('0x14')][_0x18b683('0xb')];this[_0x18b683('0x14')]=_[_0x18b683('0xe')](this[_0x18b683('0x10')],'id'),this['mapAgentsId'][_0x18b683('0xb')]=_0x2789b2;},SmsQueue[_0x438da3('0x4')][_0x438da3('0x8')]=function(){const _0x2fcb2c=_0x438da3;this['loggedIn']=0x0,this['paused']=0x0;for(let _0x33d218=0x0;_0x33d218=0x0?this[_0x2fcb2c('0x12')]:0x0;const _0x47b419={'id':this['id'],'available':this[_0x2fcb2c('0x12')],'loggedIn':this['loggedIn'],'name':this[_0x2fcb2c('0xa')],'paused':this[_0x2fcb2c('0x0')],'waiting':this[_0x2fcb2c('0xf')]},_0x4fb095=md5(JSON[_0x2fcb2c('0x2')](_0x47b419));this['md5']!==_0x4fb095&&(this['md5']=_0x4fb095,io['to'](util['format'](_0x2fcb2c('0x6'),_0x47b419['name']))[_0x2fcb2c('0x7')](_0x2fcb2c('0xc'),_0x47b419));},module[_0x438da3('0x1a')]=SmsQueue; \ No newline at end of file +const a1171_0x3f0c=['../../../rediscache','Agents','mapAgentsId','sms:queue:%s','loggedIn','map','_rr','beepall','strategy','waiting','paused','length','sms_queue:save','online','updateRouting','updateRealtime','available','lodash','md5','timeout','emit','name','format','prototype','util'];(function(_0xa07c7e,_0x3f0c71){const _0x38173f=function(_0x39010d){while(--_0x39010d){_0xa07c7e['push'](_0xa07c7e['shift']());}};_0x38173f(++_0x3f0c71);}(a1171_0x3f0c,0x9e));const a1171_0x3817=function(_0xa07c7e,_0x3f0c71){_0xa07c7e=_0xa07c7e-0x0;let _0x38173f=a1171_0x3f0c[_0xa07c7e];return _0x38173f;};const _0x5480c0=a1171_0x3817;'use strict';const _=require(_0x5480c0('0x9')),md5=require('md5'),util=require(_0x5480c0('0x10')),{getSocket}=require(_0x5480c0('0x11')),io=getSocket();function SmsQueue(_0x39010d){const _0x562752=_0x5480c0;this['id']=_0x39010d['id']||0x0,this[_0x562752('0xd')]=_0x39010d[_0x562752('0xd')]||'',this['timeout']=_0x39010d[_0x562752('0xb')]||0xa,this[_0x562752('0x0')]=_0x39010d[_0x562752('0x0')]||_0x562752('0x18'),this[_0x562752('0x12')]=_0x39010d[_0x562752('0x12')],this[_0x562752('0x13')]={},this['waiting']=0x0,this[_0x562752('0xa')]='',this[_0x562752('0x6')](),this[_0x562752('0x7')]();}SmsQueue['prototype'][_0x5480c0('0x6')]=function(){const _0x564d2c=_0x5480c0,_0x560e9e=this[_0x564d2c('0x13')][_0x564d2c('0x17')];this['mapAgentsId']=_[_0x564d2c('0x16')](this[_0x564d2c('0x12')],'id'),this[_0x564d2c('0x13')]['_rr']=_0x560e9e;},SmsQueue[_0x5480c0('0xf')][_0x5480c0('0x7')]=function(){const _0x4633bb=_0x5480c0;this[_0x4633bb('0x15')]=0x0,this[_0x4633bb('0x2')]=0x0;for(let _0x4cc7dd=0x0;_0x4cc7dd=0x0?this[_0x4633bb('0x8')]:0x0;const _0x38af21={'id':this['id'],'available':this['available'],'loggedIn':this['loggedIn'],'name':this[_0x4633bb('0xd')],'paused':this[_0x4633bb('0x2')],'waiting':this[_0x4633bb('0x1')]},_0x1bf83b=md5(JSON['stringify'](_0x38af21));this[_0x4633bb('0xa')]!==_0x1bf83b&&(this[_0x4633bb('0xa')]=_0x1bf83b,io['to'](util[_0x4633bb('0xe')](_0x4633bb('0x14'),_0x38af21[_0x4633bb('0xd')]))[_0x4633bb('0xc')](_0x4633bb('0x4'),_0x38af21));},module['exports']=SmsQueue; \ No newline at end of file diff --git a/server/services/routing/model/whatsappQueue.js b/server/services/routing/model/whatsappQueue.js index 9d830a8..eef56f8 100644 --- a/server/services/routing/model/whatsappQueue.js +++ b/server/services/routing/model/whatsappQueue.js @@ -1 +1 @@ -const a1172_0x3f33=['length','md5','available','Agents','lodash','map','paused','stringify','loggedIn','strategy','prototype','exports','format','online','emit','timeout','updateRealtime','_rr','whatsappPause','whatsapp:queue:%s','waiting','../../../rediscache','mapAgentsId','name','updateRouting'];(function(_0x60453a,_0x3f33f3){const _0x15e849=function(_0x476623){while(--_0x476623){_0x60453a['push'](_0x60453a['shift']());}};_0x15e849(++_0x3f33f3);}(a1172_0x3f33,0x175));const a1172_0x15e8=function(_0x60453a,_0x3f33f3){_0x60453a=_0x60453a-0x0;let _0x15e849=a1172_0x3f33[_0x60453a];return _0x15e849;};const _0x3a325d=a1172_0x15e8;'use strict';const _=require(_0x3a325d('0x6')),md5=require(_0x3a325d('0x3')),util=require('util'),{getSocket}=require(_0x3a325d('0x17')),io=getSocket();function WhatsappQueue(_0x476623){const _0x215f78=_0x3a325d;this['id']=_0x476623['id']||0x0,this[_0x215f78('0x0')]=_0x476623[_0x215f78('0x0')]||'',this[_0x215f78('0x11')]=_0x476623['timeout']||0xa,this['strategy']=_0x476623[_0x215f78('0xb')]||'beepall',this[_0x215f78('0x5')]=_0x476623[_0x215f78('0x5')],this[_0x215f78('0x18')]={},this[_0x215f78('0x16')]=0x0,this[_0x215f78('0x3')]='',this[_0x215f78('0x1')](),this[_0x215f78('0x12')]();}WhatsappQueue[_0x3a325d('0xc')][_0x3a325d('0x1')]=function(){const _0x4053bb=_0x3a325d,_0x37979c=this[_0x4053bb('0x18')][_0x4053bb('0x13')];this[_0x4053bb('0x18')]=_[_0x4053bb('0x7')](this[_0x4053bb('0x5')],'id'),this[_0x4053bb('0x18')]['_rr']=_0x37979c;},WhatsappQueue[_0x3a325d('0xc')]['updateRealtime']=function(){const _0x505bd3=_0x3a325d;this[_0x505bd3('0xa')]=0x0,this[_0x505bd3('0x8')]=0x0;for(let _0x29f0ce=0x0;_0x29f0ce=0x0?this['available']:0x0;const _0x44f762={'id':this['id'],'available':this['available'],'loggedIn':this[_0x505bd3('0xa')],'name':this['name'],'paused':this[_0x505bd3('0x8')],'waiting':this[_0x505bd3('0x16')]},_0x522963=md5(JSON[_0x505bd3('0x9')](_0x44f762));this['md5']!==_0x522963&&(this[_0x505bd3('0x3')]=_0x522963,io['to'](util[_0x505bd3('0xe')](_0x505bd3('0x15'),_0x44f762[_0x505bd3('0x0')]))[_0x505bd3('0x10')]('whatsapp_queue:save',_0x44f762));},module[_0x3a325d('0xd')]=WhatsappQueue; \ No newline at end of file +const a1172_0x4392=['exports','updateRealtime','name','emit','stringify','Agents','md5','mapAgentsId','online','available','prototype','loggedIn','timeout','_rr','lodash','waiting','whatsapp_queue:save','updateRouting','paused','whatsappPause'];(function(_0x8c7bcb,_0x439207){const _0x493079=function(_0x493b68){while(--_0x493b68){_0x8c7bcb['push'](_0x8c7bcb['shift']());}};_0x493079(++_0x439207);}(a1172_0x4392,0x104));const a1172_0x4930=function(_0x8c7bcb,_0x439207){_0x8c7bcb=_0x8c7bcb-0x0;let _0x493079=a1172_0x4392[_0x8c7bcb];return _0x493079;};const _0x3b483e=a1172_0x4930;'use strict';const _=require(_0x3b483e('0xe')),md5=require(_0x3b483e('0x6')),util=require('util'),{getSocket}=require('../../../rediscache'),io=getSocket();function WhatsappQueue(_0x493b68){const _0x344615=_0x3b483e;this['id']=_0x493b68['id']||0x0,this[_0x344615('0x2')]=_0x493b68[_0x344615('0x2')]||'',this[_0x344615('0xc')]=_0x493b68[_0x344615('0xc')]||0xa,this['strategy']=_0x493b68['strategy']||'beepall',this['Agents']=_0x493b68[_0x344615('0x5')],this[_0x344615('0x7')]={},this['waiting']=0x0,this['md5']='',this[_0x344615('0x11')](),this[_0x344615('0x1')]();}WhatsappQueue[_0x3b483e('0xa')][_0x3b483e('0x11')]=function(){const _0x2aac0e=_0x3b483e,_0x384ea9=this[_0x2aac0e('0x7')][_0x2aac0e('0xd')];this[_0x2aac0e('0x7')]=_['map'](this[_0x2aac0e('0x5')],'id'),this[_0x2aac0e('0x7')][_0x2aac0e('0xd')]=_0x384ea9;},WhatsappQueue['prototype'][_0x3b483e('0x1')]=function(){const _0x3d27bf=_0x3b483e;this['loggedIn']=0x0,this[_0x3d27bf('0x12')]=0x0;for(let _0x1a8ba8=0x0;_0x1a8ba8=0x0?this[_0x3d27bf('0x9')]:0x0;const _0x454d35={'id':this['id'],'available':this['available'],'loggedIn':this['loggedIn'],'name':this[_0x3d27bf('0x2')],'paused':this[_0x3d27bf('0x12')],'waiting':this[_0x3d27bf('0xf')]},_0x3b7049=md5(JSON[_0x3d27bf('0x4')](_0x454d35));this[_0x3d27bf('0x6')]!==_0x3b7049&&(this['md5']=_0x3b7049,io['to'](util['format']('whatsapp:queue:%s',_0x454d35[_0x3d27bf('0x2')]))[_0x3d27bf('0x3')](_0x3d27bf('0x10'),_0x454d35));},module[_0x3b483e('0x0')]=WhatsappQueue; \ No newline at end of file diff --git a/server/services/routing/realtime/index.js b/server/services/routing/realtime/index.js index 309e548..1205f1a 100644 --- a/server/services/routing/realtime/index.js +++ b/server/services/routing/realtime/index.js @@ -1 +1 @@ -const a1173_0x22f3=['whatsappQueues','../model/smsQueue','mailQueuesWaitingInteractions','faxQueues','initMailQueues','openchannelQueues','prototype','initAgents','initOpenchannelQueues','length','openchannelQueuesWaitingInteractions','initFaxQueues','../model/faxQueue','../model/mailQueue','smsQueues','../model/agent','initSmsQueues','updateRouting','initIntervals','undefined','chatQueues','isUndefined','smsQueuesWaitingInteractions','updateRealtime','../model/whatsappQueue','initWhatsappQueues','mailQueues','agents','mergeFromDatabase','intervals'];(function(_0x526ccc,_0x22f390){const _0x21b2ca=function(_0x2afe37){while(--_0x2afe37){_0x526ccc['push'](_0x526ccc['shift']());}};_0x21b2ca(++_0x22f390);}(a1173_0x22f3,0x90));const a1173_0x21b2=function(_0x526ccc,_0x22f390){_0x526ccc=_0x526ccc-0x0;let _0x21b2ca=a1173_0x22f3[_0x526ccc];return _0x21b2ca;};const _0x16fe6f=a1173_0x21b2;'use strict';const _=require('lodash'),Agent=require(_0x16fe6f('0x15')),Interval=require('../model/interval'),OpenchannelQueue=require('../model/openchannelQueue'),ChatQueue=require('../model/chatQueue'),SmsQueue=require(_0x16fe6f('0x7')),MailQueue=require(_0x16fe6f('0x13')),FaxQueue=require(_0x16fe6f('0x12')),WhatsappQueue=require(_0x16fe6f('0x0')),Realtime=function(){const _0x3ff2fe=_0x16fe6f;this[_0x3ff2fe('0x3')]={},this[_0x3ff2fe('0x5')]={},this[_0x3ff2fe('0xb')]={},this[_0x3ff2fe('0x1a')]={},this[_0x3ff2fe('0x14')]={},this['mailQueues']={},this[_0x3ff2fe('0x9')]={},this[_0x3ff2fe('0x6')]={},this['chatQueuesWaitingInteractions']={},this[_0x3ff2fe('0x8')]={},this[_0x3ff2fe('0x10')]={},this[_0x3ff2fe('0x1c')]={},this['faxQueuesWaitingInteractions']={},this['whatsappQueuesWaitingInteractions']={};};function freeIsNotKey(_0x2afe37,_0x49def8,_0x1c7d1f){const _0x141e9c=_0x16fe6f,_0x5c54cb=_['mapKeys'](_0x2afe37,function(_0x1a7d35){return _0x1a7d35[_0x1c7d1f];});for(const _0x1d2b4d in _0x49def8){typeof _0x49def8[_0x1d2b4d]!==_0x141e9c('0x19')&&(!_0x5c54cb[_0x1d2b4d]&&delete _0x49def8[_0x1d2b4d]);}}Realtime[_0x16fe6f('0xc')]['mergeFromDatabase']=function(_0x15b4ad,_0x46163a){const _0x1085f3=_0x16fe6f;for(const _0x4993bc in _0x46163a){typeof _0x15b4ad[_0x4993bc]!==_0x1085f3('0x19')&&(_0x15b4ad[_0x4993bc]=_0x46163a[_0x4993bc]);}},Realtime[_0x16fe6f('0xc')][_0x16fe6f('0xd')]=function(){const _0x33eab4=this;return function(_0x3ae489){const _0x1f980b=a1173_0x21b2;if(_0x3ae489){freeIsNotKey(_0x3ae489,_0x33eab4['agents'],'id');for(let _0x4e05d8=0x0,_0x275446={};_0x4e05d8<_0x3ae489[_0x1f980b('0xf')];_0x4e05d8+=0x1){_0x275446=_0x3ae489[_0x4e05d8],_['isUndefined'](_0x33eab4['agents'][_0x275446['id']])?_0x33eab4[_0x1f980b('0x3')][_0x275446['id']]=new Agent(_0x275446):_0x33eab4[_0x1f980b('0x4')](_0x33eab4[_0x1f980b('0x3')][_0x275446['id']],_0x275446);}}return _0x33eab4[_0x1f980b('0x3')];};},Realtime[_0x16fe6f('0xc')][_0x16fe6f('0x18')]=function(){const _0x25ddc6=this;return function(_0x220c5f){const _0x260916=a1173_0x21b2;if(_0x220c5f){freeIsNotKey(_0x220c5f,_0x25ddc6['intervals'],'id');for(let _0x4edd8b=0x0,_0x6c057a={};_0x4edd8b<_0x220c5f['length'];_0x4edd8b+=0x1){_0x6c057a=_0x220c5f[_0x4edd8b],_['isUndefined'](_0x25ddc6[_0x260916('0x5')][_0x6c057a['id']])?_0x25ddc6[_0x260916('0x5')][_0x6c057a['id']]=new Interval(_0x6c057a):_0x25ddc6[_0x260916('0x4')](_0x25ddc6[_0x260916('0x5')][_0x6c057a['id']],_0x6c057a);}}return _0x25ddc6[_0x260916('0x5')];};},Realtime[_0x16fe6f('0xc')][_0x16fe6f('0xe')]=function(){const _0x34c56=this;return function(_0x1b8e01){const _0x8d112b=a1173_0x21b2;if(_0x1b8e01){freeIsNotKey(_0x1b8e01,_0x34c56[_0x8d112b('0xb')],'id');for(let _0x155901=0x0,_0x5c6b63={};_0x155901<_0x1b8e01[_0x8d112b('0xf')];_0x155901+=0x1){_0x5c6b63=_0x1b8e01[_0x155901],_[_0x8d112b('0x1b')](_0x34c56['openchannelQueues'][_0x5c6b63['id']])?_0x34c56[_0x8d112b('0xb')][_0x5c6b63['id']]=new OpenchannelQueue(_0x5c6b63):_0x34c56[_0x8d112b('0x4')](_0x34c56[_0x8d112b('0xb')][_0x5c6b63['id']],_0x5c6b63),_0x34c56['openchannelQueues'][_0x5c6b63['id']][_0x8d112b('0x17')](),_0x34c56[_0x8d112b('0xb')][_0x5c6b63['id']][_0x8d112b('0x1d')]();}}return _0x34c56[_0x8d112b('0xb')];};},Realtime[_0x16fe6f('0xc')]['initChatQueues']=function(){const _0x34c9c3=this;return function(_0x23491b){const _0x29d88d=a1173_0x21b2;if(_0x23491b){freeIsNotKey(_0x23491b,_0x34c9c3[_0x29d88d('0x1a')],'id');for(let _0x52413e=0x0,_0x4d484a={};_0x52413e<_0x23491b[_0x29d88d('0xf')];_0x52413e+=0x1){_0x4d484a=_0x23491b[_0x52413e],_['isUndefined'](_0x34c9c3[_0x29d88d('0x1a')][_0x4d484a['id']])?_0x34c9c3[_0x29d88d('0x1a')][_0x4d484a['id']]=new ChatQueue(_0x4d484a):_0x34c9c3['mergeFromDatabase'](_0x34c9c3[_0x29d88d('0x1a')][_0x4d484a['id']],_0x4d484a),_0x34c9c3[_0x29d88d('0x1a')][_0x4d484a['id']][_0x29d88d('0x17')](),_0x34c9c3[_0x29d88d('0x1a')][_0x4d484a['id']][_0x29d88d('0x1d')]();}}return _0x34c9c3[_0x29d88d('0x1a')];};},Realtime[_0x16fe6f('0xc')][_0x16fe6f('0x16')]=function(){const _0x23da56=this;return function(_0x31bb16){const _0x1e6abd=a1173_0x21b2;if(_0x31bb16){freeIsNotKey(_0x31bb16,_0x23da56[_0x1e6abd('0x14')],'id');for(let _0x744d0a=0x0,_0x25526={};_0x744d0a<_0x31bb16[_0x1e6abd('0xf')];_0x744d0a+=0x1){_0x25526=_0x31bb16[_0x744d0a],_[_0x1e6abd('0x1b')](_0x23da56['smsQueues'][_0x25526['id']])?_0x23da56[_0x1e6abd('0x14')][_0x25526['id']]=new SmsQueue(_0x25526):_0x23da56[_0x1e6abd('0x4')](_0x23da56[_0x1e6abd('0x14')][_0x25526['id']],_0x25526),_0x23da56[_0x1e6abd('0x14')][_0x25526['id']][_0x1e6abd('0x17')](),_0x23da56[_0x1e6abd('0x14')][_0x25526['id']][_0x1e6abd('0x1d')]();}}return _0x23da56[_0x1e6abd('0x14')];};},Realtime['prototype'][_0x16fe6f('0xa')]=function(){const _0x32c8ff=this;return function(_0x31a6b9){const _0x1fd869=a1173_0x21b2;if(_0x31a6b9){freeIsNotKey(_0x31a6b9,_0x32c8ff[_0x1fd869('0x2')],'id');for(let _0x2fb74d=0x0,_0x5940a6={};_0x2fb74d<_0x31a6b9[_0x1fd869('0xf')];_0x2fb74d+=0x1){_0x5940a6=_0x31a6b9[_0x2fb74d],_[_0x1fd869('0x1b')](_0x32c8ff[_0x1fd869('0x2')][_0x5940a6['id']])?_0x32c8ff['mailQueues'][_0x5940a6['id']]=new MailQueue(_0x5940a6):_0x32c8ff['mergeFromDatabase'](_0x32c8ff[_0x1fd869('0x2')][_0x5940a6['id']],_0x5940a6),_0x32c8ff[_0x1fd869('0x2')][_0x5940a6['id']][_0x1fd869('0x17')](),_0x32c8ff[_0x1fd869('0x2')][_0x5940a6['id']][_0x1fd869('0x1d')]();}}return _0x32c8ff[_0x1fd869('0x2')];};},Realtime['prototype'][_0x16fe6f('0x11')]=function(){const _0xf4a5af=this;return function(_0x55ac89){const _0x3263b7=a1173_0x21b2;if(_0x55ac89){freeIsNotKey(_0x55ac89,_0xf4a5af[_0x3263b7('0x9')],'id');for(let _0x3b13d6=0x0,_0x1d611c={};_0x3b13d6<_0x55ac89['length'];_0x3b13d6+=0x1){_0x1d611c=_0x55ac89[_0x3b13d6],_[_0x3263b7('0x1b')](_0xf4a5af[_0x3263b7('0x9')][_0x1d611c['id']])?_0xf4a5af[_0x3263b7('0x9')][_0x1d611c['id']]=new FaxQueue(_0x1d611c):_0xf4a5af[_0x3263b7('0x4')](_0xf4a5af[_0x3263b7('0x9')][_0x1d611c['id']],_0x1d611c),_0xf4a5af[_0x3263b7('0x9')][_0x1d611c['id']][_0x3263b7('0x17')](),_0xf4a5af[_0x3263b7('0x9')][_0x1d611c['id']]['updateRealtime']();}}return _0xf4a5af[_0x3263b7('0x9')];};},Realtime['prototype'][_0x16fe6f('0x1')]=function(){const _0x21af55=this;return function(_0x103969){const _0x5c3ec6=a1173_0x21b2;if(_0x103969){freeIsNotKey(_0x103969,_0x21af55['whatsappQueues'],'id');for(let _0x2e15a3=0x0,_0x3c4aeb={};_0x2e15a3<_0x103969['length'];_0x2e15a3+=0x1){_0x3c4aeb=_0x103969[_0x2e15a3],_[_0x5c3ec6('0x1b')](_0x21af55[_0x5c3ec6('0x6')][_0x3c4aeb['id']])?_0x21af55['whatsappQueues'][_0x3c4aeb['id']]=new WhatsappQueue(_0x3c4aeb):_0x21af55[_0x5c3ec6('0x4')](_0x21af55[_0x5c3ec6('0x6')][_0x3c4aeb['id']],_0x3c4aeb),_0x21af55[_0x5c3ec6('0x6')][_0x3c4aeb['id']]['updateRouting'](),_0x21af55['whatsappQueues'][_0x3c4aeb['id']][_0x5c3ec6('0x1d')]();}}return _0x21af55['whatsappQueues'];};},module['exports']=Realtime; \ No newline at end of file +const a1173_0x3c86=['../model/agent','smsQueuesWaitingInteractions','intervals','mapKeys','initSmsQueues','initMailQueues','faxQueuesWaitingInteractions','initFaxQueues','updateRealtime','mailQueues','../model/whatsappQueue','prototype','initIntervals','initAgents','undefined','exports','agents','../model/smsQueue','../model/chatQueue','initOpenchannelQueues','whatsappQueues','mergeFromDatabase','length','lodash','chatQueues','openchannelQueues','smsQueues','chatQueuesWaitingInteractions','updateRouting','whatsappQueuesWaitingInteractions','faxQueues','isUndefined','../model/faxQueue','../model/openchannelQueue'];(function(_0x2d79a7,_0x3c86c4){const _0x1c1f2b=function(_0x488f92){while(--_0x488f92){_0x2d79a7['push'](_0x2d79a7['shift']());}};_0x1c1f2b(++_0x3c86c4);}(a1173_0x3c86,0xd8));const a1173_0x1c1f=function(_0x2d79a7,_0x3c86c4){_0x2d79a7=_0x2d79a7-0x0;let _0x1c1f2b=a1173_0x3c86[_0x2d79a7];return _0x1c1f2b;};const _0x219bd3=a1173_0x1c1f;'use strict';const _=require(_0x219bd3('0xb')),Agent=require(_0x219bd3('0x16')),Interval=require('../model/interval'),OpenchannelQueue=require(_0x219bd3('0x15')),ChatQueue=require(_0x219bd3('0x6')),SmsQueue=require(_0x219bd3('0x5')),MailQueue=require('../model/mailQueue'),FaxQueue=require(_0x219bd3('0x14')),WhatsappQueue=require(_0x219bd3('0x20')),Realtime=function(){const _0x5ece4a=_0x219bd3;this['agents']={},this[_0x5ece4a('0x18')]={},this['openchannelQueues']={},this[_0x5ece4a('0xc')]={},this[_0x5ece4a('0xe')]={},this['mailQueues']={},this[_0x5ece4a('0x12')]={},this[_0x5ece4a('0x8')]={},this[_0x5ece4a('0xf')]={},this['mailQueuesWaitingInteractions']={},this['openchannelQueuesWaitingInteractions']={},this[_0x5ece4a('0x17')]={},this[_0x5ece4a('0x1c')]={},this[_0x5ece4a('0x11')]={};};function freeIsNotKey(_0x488f92,_0x408405,_0x5303c2){const _0x3a4726=_0x219bd3,_0x247ad1=_[_0x3a4726('0x19')](_0x488f92,function(_0x5af475){return _0x5af475[_0x5303c2];});for(const _0x1d8ece in _0x408405){typeof _0x408405[_0x1d8ece]!==_0x3a4726('0x2')&&(!_0x247ad1[_0x1d8ece]&&delete _0x408405[_0x1d8ece]);}}Realtime[_0x219bd3('0x21')][_0x219bd3('0x9')]=function(_0xb8bd93,_0x219e82){const _0x14782d=_0x219bd3;for(const _0x9cd0a in _0x219e82){typeof _0xb8bd93[_0x9cd0a]!==_0x14782d('0x2')&&(_0xb8bd93[_0x9cd0a]=_0x219e82[_0x9cd0a]);}},Realtime['prototype'][_0x219bd3('0x1')]=function(){const _0x36561e=this;return function(_0x4e5d94){const _0x290a2f=a1173_0x1c1f;if(_0x4e5d94){freeIsNotKey(_0x4e5d94,_0x36561e[_0x290a2f('0x4')],'id');for(let _0x28d518=0x0,_0x1fbd20={};_0x28d518<_0x4e5d94['length'];_0x28d518+=0x1){_0x1fbd20=_0x4e5d94[_0x28d518],_[_0x290a2f('0x13')](_0x36561e[_0x290a2f('0x4')][_0x1fbd20['id']])?_0x36561e[_0x290a2f('0x4')][_0x1fbd20['id']]=new Agent(_0x1fbd20):_0x36561e[_0x290a2f('0x9')](_0x36561e[_0x290a2f('0x4')][_0x1fbd20['id']],_0x1fbd20);}}return _0x36561e[_0x290a2f('0x4')];};},Realtime[_0x219bd3('0x21')][_0x219bd3('0x0')]=function(){const _0x1a113b=this;return function(_0xbdc3cb){const _0x1a573a=a1173_0x1c1f;if(_0xbdc3cb){freeIsNotKey(_0xbdc3cb,_0x1a113b[_0x1a573a('0x18')],'id');for(let _0x3d75df=0x0,_0x5f05bc={};_0x3d75df<_0xbdc3cb[_0x1a573a('0xa')];_0x3d75df+=0x1){_0x5f05bc=_0xbdc3cb[_0x3d75df],_[_0x1a573a('0x13')](_0x1a113b[_0x1a573a('0x18')][_0x5f05bc['id']])?_0x1a113b[_0x1a573a('0x18')][_0x5f05bc['id']]=new Interval(_0x5f05bc):_0x1a113b[_0x1a573a('0x9')](_0x1a113b[_0x1a573a('0x18')][_0x5f05bc['id']],_0x5f05bc);}}return _0x1a113b[_0x1a573a('0x18')];};},Realtime[_0x219bd3('0x21')][_0x219bd3('0x7')]=function(){const _0x539380=this;return function(_0x18e51f){const _0x32cdac=a1173_0x1c1f;if(_0x18e51f){freeIsNotKey(_0x18e51f,_0x539380[_0x32cdac('0xd')],'id');for(let _0x4720a3=0x0,_0x7f6430={};_0x4720a3<_0x18e51f['length'];_0x4720a3+=0x1){_0x7f6430=_0x18e51f[_0x4720a3],_['isUndefined'](_0x539380['openchannelQueues'][_0x7f6430['id']])?_0x539380[_0x32cdac('0xd')][_0x7f6430['id']]=new OpenchannelQueue(_0x7f6430):_0x539380[_0x32cdac('0x9')](_0x539380[_0x32cdac('0xd')][_0x7f6430['id']],_0x7f6430),_0x539380[_0x32cdac('0xd')][_0x7f6430['id']][_0x32cdac('0x10')](),_0x539380[_0x32cdac('0xd')][_0x7f6430['id']][_0x32cdac('0x1e')]();}}return _0x539380[_0x32cdac('0xd')];};},Realtime[_0x219bd3('0x21')]['initChatQueues']=function(){const _0x541011=this;return function(_0x3ef4f8){const _0x3c84e0=a1173_0x1c1f;if(_0x3ef4f8){freeIsNotKey(_0x3ef4f8,_0x541011[_0x3c84e0('0xc')],'id');for(let _0x391b70=0x0,_0x4d8650={};_0x391b70<_0x3ef4f8[_0x3c84e0('0xa')];_0x391b70+=0x1){_0x4d8650=_0x3ef4f8[_0x391b70],_['isUndefined'](_0x541011['chatQueues'][_0x4d8650['id']])?_0x541011[_0x3c84e0('0xc')][_0x4d8650['id']]=new ChatQueue(_0x4d8650):_0x541011['mergeFromDatabase'](_0x541011[_0x3c84e0('0xc')][_0x4d8650['id']],_0x4d8650),_0x541011[_0x3c84e0('0xc')][_0x4d8650['id']][_0x3c84e0('0x10')](),_0x541011[_0x3c84e0('0xc')][_0x4d8650['id']][_0x3c84e0('0x1e')]();}}return _0x541011[_0x3c84e0('0xc')];};},Realtime[_0x219bd3('0x21')][_0x219bd3('0x1a')]=function(){const _0x232496=this;return function(_0x26916b){const _0x5399bd=a1173_0x1c1f;if(_0x26916b){freeIsNotKey(_0x26916b,_0x232496[_0x5399bd('0xe')],'id');for(let _0x3c5943=0x0,_0x217fb9={};_0x3c5943<_0x26916b[_0x5399bd('0xa')];_0x3c5943+=0x1){_0x217fb9=_0x26916b[_0x3c5943],_[_0x5399bd('0x13')](_0x232496[_0x5399bd('0xe')][_0x217fb9['id']])?_0x232496[_0x5399bd('0xe')][_0x217fb9['id']]=new SmsQueue(_0x217fb9):_0x232496[_0x5399bd('0x9')](_0x232496[_0x5399bd('0xe')][_0x217fb9['id']],_0x217fb9),_0x232496[_0x5399bd('0xe')][_0x217fb9['id']]['updateRouting'](),_0x232496[_0x5399bd('0xe')][_0x217fb9['id']][_0x5399bd('0x1e')]();}}return _0x232496['smsQueues'];};},Realtime[_0x219bd3('0x21')][_0x219bd3('0x1b')]=function(){const _0x41cbd1=this;return function(_0x10a43f){const _0x311d58=a1173_0x1c1f;if(_0x10a43f){freeIsNotKey(_0x10a43f,_0x41cbd1[_0x311d58('0x1f')],'id');for(let _0x47270a=0x0,_0x68c66d={};_0x47270a<_0x10a43f[_0x311d58('0xa')];_0x47270a+=0x1){_0x68c66d=_0x10a43f[_0x47270a],_[_0x311d58('0x13')](_0x41cbd1[_0x311d58('0x1f')][_0x68c66d['id']])?_0x41cbd1[_0x311d58('0x1f')][_0x68c66d['id']]=new MailQueue(_0x68c66d):_0x41cbd1['mergeFromDatabase'](_0x41cbd1[_0x311d58('0x1f')][_0x68c66d['id']],_0x68c66d),_0x41cbd1[_0x311d58('0x1f')][_0x68c66d['id']][_0x311d58('0x10')](),_0x41cbd1[_0x311d58('0x1f')][_0x68c66d['id']][_0x311d58('0x1e')]();}}return _0x41cbd1[_0x311d58('0x1f')];};},Realtime[_0x219bd3('0x21')][_0x219bd3('0x1d')]=function(){const _0x330577=this;return function(_0x3d148d){const _0x3628a3=a1173_0x1c1f;if(_0x3d148d){freeIsNotKey(_0x3d148d,_0x330577[_0x3628a3('0x12')],'id');for(let _0x1dd2d=0x0,_0x16650a={};_0x1dd2d<_0x3d148d[_0x3628a3('0xa')];_0x1dd2d+=0x1){_0x16650a=_0x3d148d[_0x1dd2d],_[_0x3628a3('0x13')](_0x330577[_0x3628a3('0x12')][_0x16650a['id']])?_0x330577[_0x3628a3('0x12')][_0x16650a['id']]=new FaxQueue(_0x16650a):_0x330577[_0x3628a3('0x9')](_0x330577['faxQueues'][_0x16650a['id']],_0x16650a),_0x330577[_0x3628a3('0x12')][_0x16650a['id']][_0x3628a3('0x10')](),_0x330577[_0x3628a3('0x12')][_0x16650a['id']][_0x3628a3('0x1e')]();}}return _0x330577[_0x3628a3('0x12')];};},Realtime[_0x219bd3('0x21')]['initWhatsappQueues']=function(){const _0xf18e8b=this;return function(_0x51ed71){const _0x559e4f=a1173_0x1c1f;if(_0x51ed71){freeIsNotKey(_0x51ed71,_0xf18e8b[_0x559e4f('0x8')],'id');for(let _0x2b2707=0x0,_0x2468f7={};_0x2b2707<_0x51ed71[_0x559e4f('0xa')];_0x2b2707+=0x1){_0x2468f7=_0x51ed71[_0x2b2707],_[_0x559e4f('0x13')](_0xf18e8b[_0x559e4f('0x8')][_0x2468f7['id']])?_0xf18e8b[_0x559e4f('0x8')][_0x2468f7['id']]=new WhatsappQueue(_0x2468f7):_0xf18e8b[_0x559e4f('0x9')](_0xf18e8b[_0x559e4f('0x8')][_0x2468f7['id']],_0x2468f7),_0xf18e8b[_0x559e4f('0x8')][_0x2468f7['id']][_0x559e4f('0x10')](),_0xf18e8b[_0x559e4f('0x8')][_0x2468f7['id']][_0x559e4f('0x1e')]();}}return _0xf18e8b[_0x559e4f('0x8')];};},module[_0x219bd3('0x3')]=Realtime; \ No newline at end of file diff --git a/server/services/routing/rpc/chatInteraction.js b/server/services/routing/rpc/chatInteraction.js index e9fe464..bc03506 100644 --- a/server/services/routing/rpc/chatInteraction.js +++ b/server/services/routing/rpc/chatInteraction.js @@ -1 +1 @@ -const a1174_0x3697=['addTags','Request','UpdateChatInteraction','update','../client'];(function(_0x188457,_0x369782){const _0x2496ad=function(_0x22b20c){while(--_0x22b20c){_0x188457['push'](_0x188457['shift']());}};_0x2496ad(++_0x369782);}(a1174_0x3697,0x10a));const a1174_0x2496=function(_0x188457,_0x369782){_0x188457=_0x188457-0x0;let _0x2496ad=a1174_0x3697[_0x188457];return _0x2496ad;};const _0x57ba24=a1174_0x2496;'use strict';const client=require(_0x57ba24('0x3'));exports[_0x57ba24('0x2')]=function(_0x22b20c,_0x333990){const _0x21e1dc=_0x57ba24;return client[_0x21e1dc('0x0')](_0x21e1dc('0x1'),{'body':_0x333990,'options':{'where':{'id':_0x22b20c}},'log':'updateChatInteraction'});},exports[_0x57ba24('0x4')]=function(_0x542ebd,_0x4f3dcf){return client['Request']('AddTagsToChatInteraction',{'body':_0x4f3dcf,'options':{'where':{'id':_0x542ebd}},'log':'addTagsToChatInteraction'});}; \ No newline at end of file +const a1174_0x23e9=['addTags','Request','AddTagsToChatInteraction','addTagsToChatInteraction','UpdateChatInteraction','updateChatInteraction','../client'];(function(_0x26f965,_0x23e9b8){const _0x2cece8=function(_0x6bf84e){while(--_0x6bf84e){_0x26f965['push'](_0x26f965['shift']());}};_0x2cece8(++_0x23e9b8);}(a1174_0x23e9,0x123));const a1174_0x2cec=function(_0x26f965,_0x23e9b8){_0x26f965=_0x26f965-0x0;let _0x2cece8=a1174_0x23e9[_0x26f965];return _0x2cece8;};const _0x577415=a1174_0x2cec;'use strict';const client=require(_0x577415('0x2'));exports['update']=function(_0x6bf84e,_0x16d167){const _0x1df707=_0x577415;return client[_0x1df707('0x4')](_0x1df707('0x0'),{'body':_0x16d167,'options':{'where':{'id':_0x6bf84e}},'log':_0x1df707('0x1')});},exports[_0x577415('0x3')]=function(_0x5d9b0f,_0x4be34e){const _0x5ac58a=_0x577415;return client[_0x5ac58a('0x4')](_0x5ac58a('0x5'),{'body':_0x4be34e,'options':{'where':{'id':_0x5d9b0f}},'log':_0x5ac58a('0x6')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/chatMessage.js b/server/services/routing/rpc/chatMessage.js index d8a494c..f8b3d4f 100644 --- a/server/services/routing/rpc/chatMessage.js +++ b/server/services/routing/rpc/chatMessage.js @@ -1 +1 @@ -const a1175_0x49ea=['create','createChatMessage'];(function(_0x589d70,_0x49ea9f){const _0x48d452=function(_0x27543b){while(--_0x27543b){_0x589d70['push'](_0x589d70['shift']());}};_0x48d452(++_0x49ea9f);}(a1175_0x49ea,0x14f));const a1175_0x48d4=function(_0x589d70,_0x49ea9f){_0x589d70=_0x589d70-0x0;let _0x48d452=a1175_0x49ea[_0x589d70];return _0x48d452;};const _0x9de4e=a1175_0x48d4;'use strict';const client=require('../client');exports[_0x9de4e('0x1')]=function(_0x27543b){const _0x2e7ab6=_0x9de4e;return client['Request']('CreateChatMessage',{'body':_0x27543b,'log':_0x2e7ab6('0x0')});}; \ No newline at end of file +const a1175_0x34f5=['createChatMessage','CreateChatMessage'];(function(_0x406b1c,_0x34f5ac){const _0x3c2fcd=function(_0xa8a2ba){while(--_0xa8a2ba){_0x406b1c['push'](_0x406b1c['shift']());}};_0x3c2fcd(++_0x34f5ac);}(a1175_0x34f5,0x11d));const a1175_0x3c2f=function(_0x406b1c,_0x34f5ac){_0x406b1c=_0x406b1c-0x0;let _0x3c2fcd=a1175_0x34f5[_0x406b1c];return _0x3c2fcd;};'use strict';const client=require('../client');exports['create']=function(_0xa8a2ba){const _0x2eef05=a1175_0x3c2f;return client['Request'](_0x2eef05('0x0'),{'body':_0xa8a2ba,'log':_0x2eef05('0x1')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/chatQueue.js b/server/services/routing/rpc/chatQueue.js index 317416c..42cf44e 100644 --- a/server/services/routing/rpc/chatQueue.js +++ b/server/services/routing/rpc/chatQueue.js @@ -1 +1 @@ -const a1176_0x4d80=['GetChatQueue','getChatQueues','Request','timeout','chatPause','online'];(function(_0x5da964,_0x4d80ff){const _0x4d395e=function(_0x4a605c){while(--_0x4a605c){_0x5da964['push'](_0x5da964['shift']());}};_0x4d395e(++_0x4d80ff);}(a1176_0x4d80,0x1a5));const a1176_0x4d39=function(_0x5da964,_0x4d80ff){_0x5da964=_0x5da964-0x0;let _0x4d395e=a1176_0x4d80[_0x5da964];return _0x4d395e;};const _0x75a77a=a1176_0x4d39;'use strict';const client=require('../client');exports[_0x75a77a('0x0')]=function(){return function(){const _0x2c2475=a1176_0x4d39;return client[_0x2c2475('0x1')](_0x2c2475('0x5'),{'options':{'raw':![],'attributes':['id','name',_0x2c2475('0x2'),'strategy'],'include':[{'model':'User','as':'Agents','attributes':['id','name',_0x2c2475('0x4'),_0x2c2475('0x3')]}]},'log':_0x2c2475('0x0')});};}; \ No newline at end of file +const a1176_0x1769=['getChatQueues','GetChatQueue','../client','timeout','name','User','Request'];(function(_0x55f75f,_0x176957){const _0xa3984a=function(_0x1d7dfa){while(--_0x1d7dfa){_0x55f75f['push'](_0x55f75f['shift']());}};_0xa3984a(++_0x176957);}(a1176_0x1769,0x127));const a1176_0xa398=function(_0x55f75f,_0x176957){_0x55f75f=_0x55f75f-0x0;let _0xa3984a=a1176_0x1769[_0x55f75f];return _0xa3984a;};const _0xa1cad3=a1176_0xa398;'use strict';const client=require(_0xa1cad3('0x1'));exports[_0xa1cad3('0x6')]=function(){return function(){const _0x22a32e=a1176_0xa398;return client[_0x22a32e('0x5')](_0x22a32e('0x0'),{'options':{'raw':![],'attributes':['id',_0x22a32e('0x3'),_0x22a32e('0x2'),'strategy'],'include':[{'model':_0x22a32e('0x4'),'as':'Agents','attributes':['id',_0x22a32e('0x3'),'online','chatPause']}]},'log':_0x22a32e('0x6')});};}; \ No newline at end of file diff --git a/server/services/routing/rpc/chatQueueReport.js b/server/services/routing/rpc/chatQueueReport.js index 44e370a..d8080ce 100644 --- a/server/services/routing/rpc/chatQueueReport.js +++ b/server/services/routing/rpc/chatQueueReport.js @@ -1 +1 @@ -const a1177_0x2d46=['CreateChatQueueReport','update','create','UpdateChatQueueReport','Request','DESC','../client'];(function(_0x3e22f0,_0x2d4624){const _0xa6db50=function(_0x3cdc01){while(--_0x3cdc01){_0x3e22f0['push'](_0x3e22f0['shift']());}};_0xa6db50(++_0x2d4624);}(a1177_0x2d46,0x1e6));const a1177_0xa6db=function(_0x3e22f0,_0x2d4624){_0x3e22f0=_0x3e22f0-0x0;let _0xa6db50=a1177_0x2d46[_0x3e22f0];return _0xa6db50;};const _0x5e9f8c=a1177_0xa6db;'use strict';const client=require(_0x5e9f8c('0x3'));exports[_0x5e9f8c('0x6')]=function(_0x3cdc01){const _0x2b4e61=_0x5e9f8c;return client['Request'](_0x2b4e61('0x4'),{'body':_0x3cdc01,'log':_0x2b4e61('0x4')});},exports[_0x5e9f8c('0x5')]=function(_0x12b4d,_0x2b4d96){const _0x25a0f8=_0x5e9f8c;return client[_0x25a0f8('0x1')](_0x25a0f8('0x0'),{'body':_0x2b4d96,'options':{'where':{'uniqueid':_0x12b4d},'order':[['id',_0x25a0f8('0x2')]],'limit':0x1},'log':_0x25a0f8('0x0')});}; \ No newline at end of file +const a1177_0x2bac=['../client','CreateChatQueueReport','UpdateChatQueueReport','update','Request','DESC'];(function(_0x4e95e4,_0x2bacbe){const _0x14b4ad=function(_0x31f618){while(--_0x31f618){_0x4e95e4['push'](_0x4e95e4['shift']());}};_0x14b4ad(++_0x2bacbe);}(a1177_0x2bac,0xc3));const a1177_0x14b4=function(_0x4e95e4,_0x2bacbe){_0x4e95e4=_0x4e95e4-0x0;let _0x14b4ad=a1177_0x2bac[_0x4e95e4];return _0x14b4ad;};const _0x2ca804=a1177_0x14b4;'use strict';const client=require(_0x2ca804('0x3'));exports['create']=function(_0x31f618){const _0x4e4736=_0x2ca804;return client['Request'](_0x4e4736('0x4'),{'body':_0x31f618,'log':_0x4e4736('0x4')});},exports[_0x2ca804('0x0')]=function(_0x49566d,_0x2a3c4c){const _0x55a24a=_0x2ca804;return client[_0x55a24a('0x1')]('UpdateChatQueueReport',{'body':_0x2a3c4c,'options':{'where':{'uniqueid':_0x49566d},'order':[['id',_0x55a24a('0x2')]],'limit':0x1},'log':_0x55a24a('0x5')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/faxInteraction.js b/server/services/routing/rpc/faxInteraction.js index 319b411..fb9f73d 100644 --- a/server/services/routing/rpc/faxInteraction.js +++ b/server/services/routing/rpc/faxInteraction.js @@ -1 +1 @@ -const a1178_0x363f=['addTags','../client','updateFaxInteraction','update','addTagsToFaxInteraction','Request','AddTagsToFaxInteraction'];(function(_0x4d7256,_0x363f7d){const _0x21ba00=function(_0x2ce6bf){while(--_0x2ce6bf){_0x4d7256['push'](_0x4d7256['shift']());}};_0x21ba00(++_0x363f7d);}(a1178_0x363f,0x7c));const a1178_0x21ba=function(_0x4d7256,_0x363f7d){_0x4d7256=_0x4d7256-0x0;let _0x21ba00=a1178_0x363f[_0x4d7256];return _0x21ba00;};const _0x8a9d28=a1178_0x21ba;'use strict';const client=require(_0x8a9d28('0x3'));exports[_0x8a9d28('0x5')]=function(_0x2ce6bf,_0x1fdce5){const _0x31bb61=_0x8a9d28;return client[_0x31bb61('0x0')]('UpdateFaxInteraction',{'body':_0x1fdce5,'options':{'where':{'id':_0x2ce6bf}},'log':_0x31bb61('0x4')});},exports[_0x8a9d28('0x2')]=function(_0x5cf7a5,_0x13523a){const _0xe35c4c=_0x8a9d28;return client[_0xe35c4c('0x0')](_0xe35c4c('0x1'),{'body':_0x13523a,'options':{'where':{'id':_0x5cf7a5}},'log':_0xe35c4c('0x6')});}; \ No newline at end of file +const a1178_0x4341=['../client','AddTagsToFaxInteraction','addTags','Request','updateFaxInteraction','addTagsToFaxInteraction','update'];(function(_0x4c0ad3,_0x43417b){const _0x4185ec=function(_0x278d3e){while(--_0x278d3e){_0x4c0ad3['push'](_0x4c0ad3['shift']());}};_0x4185ec(++_0x43417b);}(a1178_0x4341,0x8e));const a1178_0x4185=function(_0x4c0ad3,_0x43417b){_0x4c0ad3=_0x4c0ad3-0x0;let _0x4185ec=a1178_0x4341[_0x4c0ad3];return _0x4185ec;};const _0x2d11e1=a1178_0x4185;'use strict';const client=require(_0x2d11e1('0x5'));exports[_0x2d11e1('0x4')]=function(_0x278d3e,_0x512a01){const _0x52c041=_0x2d11e1;return client[_0x52c041('0x1')]('UpdateFaxInteraction',{'body':_0x512a01,'options':{'where':{'id':_0x278d3e}},'log':_0x52c041('0x2')});},exports[_0x2d11e1('0x0')]=function(_0x5d7f6b,_0xbc2edc){const _0x4157f8=_0x2d11e1;return client[_0x4157f8('0x1')](_0x4157f8('0x6'),{'body':_0xbc2edc,'options':{'where':{'id':_0x5d7f6b}},'log':_0x4157f8('0x3')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/faxMessage.js b/server/services/routing/rpc/faxMessage.js index 1963c40..9bd67a4 100644 --- a/server/services/routing/rpc/faxMessage.js +++ b/server/services/routing/rpc/faxMessage.js @@ -1 +1 @@ -const a1179_0x54b2=['createFaxMessage','../client','Request'];(function(_0x3c201f,_0x54b24d){const _0x512d71=function(_0xa7ad1e){while(--_0xa7ad1e){_0x3c201f['push'](_0x3c201f['shift']());}};_0x512d71(++_0x54b24d);}(a1179_0x54b2,0x1de));const a1179_0x512d=function(_0x3c201f,_0x54b24d){_0x3c201f=_0x3c201f-0x0;let _0x512d71=a1179_0x54b2[_0x3c201f];return _0x512d71;};const _0x4b8fff=a1179_0x512d;'use strict';const client=require(_0x4b8fff('0x0'));exports['create']=function(_0xa7ad1e){const _0x1a1902=_0x4b8fff;return client[_0x1a1902('0x1')]('CreateFaxMessage',{'body':_0xa7ad1e,'log':_0x1a1902('0x2')});}; \ No newline at end of file +const a1179_0x1b1b=['CreateFaxMessage','createFaxMessage','create'];(function(_0xa2c79d,_0x1b1b86){const _0x4c7226=function(_0x4114f2){while(--_0x4114f2){_0xa2c79d['push'](_0xa2c79d['shift']());}};_0x4c7226(++_0x1b1b86);}(a1179_0x1b1b,0x163));const a1179_0x4c72=function(_0xa2c79d,_0x1b1b86){_0xa2c79d=_0xa2c79d-0x0;let _0x4c7226=a1179_0x1b1b[_0xa2c79d];return _0x4c7226;};const _0x1a7ae0=a1179_0x4c72;'use strict';const client=require('../client');exports[_0x1a7ae0('0x1')]=function(_0x4114f2){const _0x288e51=_0x1a7ae0;return client['Request'](_0x288e51('0x2'),{'body':_0x4114f2,'log':_0x288e51('0x0')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/faxQueue.js b/server/services/routing/rpc/faxQueue.js index 6d284ca..7b542f8 100644 --- a/server/services/routing/rpc/faxQueue.js +++ b/server/services/routing/rpc/faxQueue.js @@ -1 +1 @@ -const a1180_0x40cd=['name','getFaxQueues','../client','timeout','GetFaxQueue','online','Request'];(function(_0x479f3f,_0x40cdfe){const _0x216da7=function(_0x4283b7){while(--_0x4283b7){_0x479f3f['push'](_0x479f3f['shift']());}};_0x216da7(++_0x40cdfe);}(a1180_0x40cd,0x130));const a1180_0x216d=function(_0x479f3f,_0x40cdfe){_0x479f3f=_0x479f3f-0x0;let _0x216da7=a1180_0x40cd[_0x479f3f];return _0x216da7;};const _0x3e0d72=a1180_0x216d;'use strict';const client=require(_0x3e0d72('0x6'));exports[_0x3e0d72('0x5')]=function(){return function(){const _0x1af92a=a1180_0x216d;return client[_0x1af92a('0x3')](_0x1af92a('0x1'),{'options':{'raw':![],'attributes':['id',_0x1af92a('0x4'),_0x1af92a('0x0'),'strategy'],'include':[{'model':'User','as':'Agents','attributes':['id','name',_0x1af92a('0x2'),'faxPause']}]},'log':'getFaxQueues'});};}; \ No newline at end of file +const a1180_0x1cdc=['name','GetFaxQueue','getFaxQueues','User','Agents','timeout','strategy'];(function(_0x1533f3,_0x1cdc65){const _0xcd3355=function(_0x51df64){while(--_0x51df64){_0x1533f3['push'](_0x1533f3['shift']());}};_0xcd3355(++_0x1cdc65);}(a1180_0x1cdc,0x11e));const a1180_0xcd33=function(_0x1533f3,_0x1cdc65){_0x1533f3=_0x1533f3-0x0;let _0xcd3355=a1180_0x1cdc[_0x1533f3];return _0xcd3355;};const _0x551de7=a1180_0xcd33;'use strict';const client=require('../client');exports[_0x551de7('0x3')]=function(){return function(){const _0x5338c1=a1180_0xcd33;return client['Request'](_0x5338c1('0x2'),{'options':{'raw':![],'attributes':['id',_0x5338c1('0x1'),_0x5338c1('0x6'),_0x5338c1('0x0')],'include':[{'model':_0x5338c1('0x4'),'as':_0x5338c1('0x5'),'attributes':['id',_0x5338c1('0x1'),'online','faxPause']}]},'log':_0x5338c1('0x3')});};}; \ No newline at end of file diff --git a/server/services/routing/rpc/faxQueueReport.js b/server/services/routing/rpc/faxQueueReport.js index 59406f6..a812886 100644 --- a/server/services/routing/rpc/faxQueueReport.js +++ b/server/services/routing/rpc/faxQueueReport.js @@ -1 +1 @@ -const a1181_0x41d6=['create','DESC','../client','UpdateFaxQueueReport','Request'];(function(_0x4e6aee,_0x41d675){const _0x40f83f=function(_0x32d860){while(--_0x32d860){_0x4e6aee['push'](_0x4e6aee['shift']());}};_0x40f83f(++_0x41d675);}(a1181_0x41d6,0x15d));const a1181_0x40f8=function(_0x4e6aee,_0x41d675){_0x4e6aee=_0x4e6aee-0x0;let _0x40f83f=a1181_0x41d6[_0x4e6aee];return _0x40f83f;};const _0x47f3f2=a1181_0x40f8;'use strict';const client=require(_0x47f3f2('0x3'));exports[_0x47f3f2('0x1')]=function(_0x32d860){return client['Request']('CreateFaxQueueReport',{'body':_0x32d860,'log':'CreateFaxQueueReport'});},exports['update']=function(_0x290a5a,_0x4221e1){const _0x5db64b=_0x47f3f2;return client[_0x5db64b('0x0')](_0x5db64b('0x4'),{'body':_0x4221e1,'options':{'where':{'uniqueid':_0x290a5a},'order':[['id',_0x5db64b('0x2')]],'limit':0x1},'log':_0x5db64b('0x4')});}; \ No newline at end of file +const a1181_0x32d7=['../client','UpdateFaxQueueReport','update','CreateFaxQueueReport','Request','DESC','create'];(function(_0x198b65,_0x32d7f3){const _0x55f51d=function(_0x559e6e){while(--_0x559e6e){_0x198b65['push'](_0x198b65['shift']());}};_0x55f51d(++_0x32d7f3);}(a1181_0x32d7,0x15e));const a1181_0x55f5=function(_0x198b65,_0x32d7f3){_0x198b65=_0x198b65-0x0;let _0x55f51d=a1181_0x32d7[_0x198b65];return _0x55f51d;};const _0x2887ed=a1181_0x55f5;'use strict';const client=require(_0x2887ed('0x0'));exports[_0x2887ed('0x6')]=function(_0x559e6e){const _0x3f4269=_0x2887ed;return client[_0x3f4269('0x4')](_0x3f4269('0x3'),{'body':_0x559e6e,'log':_0x3f4269('0x3')});},exports[_0x2887ed('0x2')]=function(_0x3c0ae4,_0x56086a){const _0x324f17=_0x2887ed;return client[_0x324f17('0x4')]('UpdateFaxQueueReport',{'body':_0x56086a,'options':{'where':{'uniqueid':_0x3c0ae4},'order':[['id',_0x324f17('0x5')]],'limit':0x1},'log':_0x324f17('0x1')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/interval.js b/server/services/routing/rpc/interval.js index c598728..e60bbce 100644 --- a/server/services/routing/rpc/interval.js +++ b/server/services/routing/rpc/interval.js @@ -1 +1 @@ -const a1182_0x108f=['Interval','GetInterval','getIntervals','Intervals','Request','name'];(function(_0x16baa5,_0x108f80){const _0x30594c=function(_0x5d1ec7){while(--_0x5d1ec7){_0x16baa5['push'](_0x16baa5['shift']());}};_0x30594c(++_0x108f80);}(a1182_0x108f,0x19c));const a1182_0x3059=function(_0x16baa5,_0x108f80){_0x16baa5=_0x16baa5-0x0;let _0x30594c=a1182_0x108f[_0x16baa5];return _0x30594c;};const _0x55962e=a1182_0x3059;'use strict';const client=require('../client');exports[_0x55962e('0x4')]=function(){return function(){const _0x291e8d=a1182_0x3059;return client[_0x291e8d('0x0')](_0x291e8d('0x3'),{'options':{'raw':![],'where':{'IntervalId':null},'attributes':['id',_0x291e8d('0x1')],'include':[{'model':_0x291e8d('0x2'),'as':_0x291e8d('0x5'),'attributes':['id',_0x291e8d('0x1'),'interval']}]},'log':_0x291e8d('0x4')});};}; \ No newline at end of file +const a1182_0x186c=['getIntervals','interval','Request','../client','GetInterval','name'];(function(_0x4a219f,_0x186cb5){const _0x52c0c6=function(_0x1514c1){while(--_0x1514c1){_0x4a219f['push'](_0x4a219f['shift']());}};_0x52c0c6(++_0x186cb5);}(a1182_0x186c,0xc2));const a1182_0x52c0=function(_0x4a219f,_0x186cb5){_0x4a219f=_0x4a219f-0x0;let _0x52c0c6=a1182_0x186c[_0x4a219f];return _0x52c0c6;};const _0x1718f7=a1182_0x52c0;'use strict';const client=require(_0x1718f7('0x1'));exports['getIntervals']=function(){return function(){const _0x1cef52=a1182_0x52c0;return client[_0x1cef52('0x0')](_0x1cef52('0x2'),{'options':{'raw':![],'where':{'IntervalId':null},'attributes':['id',_0x1cef52('0x3')],'include':[{'model':'Interval','as':'Intervals','attributes':['id','name',_0x1cef52('0x5')]}]},'log':_0x1cef52('0x4')});};}; \ No newline at end of file diff --git a/server/services/routing/rpc/mailInteraction.js b/server/services/routing/rpc/mailInteraction.js index e161f48..0319c8a 100644 --- a/server/services/routing/rpc/mailInteraction.js +++ b/server/services/routing/rpc/mailInteraction.js @@ -1 +1 @@ -const a1183_0x2dd0=['Request','addTagsToChatInteraction','updateMailInteraction','../client','update'];(function(_0x389d95,_0x2dd0e9){const _0x1ac92a=function(_0xaac27f){while(--_0xaac27f){_0x389d95['push'](_0x389d95['shift']());}};_0x1ac92a(++_0x2dd0e9);}(a1183_0x2dd0,0x13a));const a1183_0x1ac9=function(_0x389d95,_0x2dd0e9){_0x389d95=_0x389d95-0x0;let _0x1ac92a=a1183_0x2dd0[_0x389d95];return _0x1ac92a;};const _0x55a06e=a1183_0x1ac9;'use strict';const client=require(_0x55a06e('0x4'));exports[_0x55a06e('0x0')]=function(_0xaac27f,_0x13e79e){const _0x3f987f=_0x55a06e;return client['Request']('UpdateMailInteraction',{'body':_0x13e79e,'options':{'where':{'id':_0xaac27f}},'log':_0x3f987f('0x3')});},exports['addTags']=function(_0x36e18f,_0x3137af){const _0xe3807d=_0x55a06e;return client[_0xe3807d('0x1')]('AddTagsToMailInteraction',{'body':_0x3137af,'options':{'where':{'id':_0x36e18f}},'log':_0xe3807d('0x2')});}; \ No newline at end of file +const a1183_0x1ff0=['Request','UpdateMailInteraction','../client','update','updateMailInteraction','addTags'];(function(_0x402321,_0x1ff0a9){const _0x558c0b=function(_0x3c5e40){while(--_0x3c5e40){_0x402321['push'](_0x402321['shift']());}};_0x558c0b(++_0x1ff0a9);}(a1183_0x1ff0,0x12d));const a1183_0x558c=function(_0x402321,_0x1ff0a9){_0x402321=_0x402321-0x0;let _0x558c0b=a1183_0x1ff0[_0x402321];return _0x558c0b;};const _0x369350=a1183_0x558c;'use strict';const client=require(_0x369350('0x1'));exports[_0x369350('0x2')]=function(_0x3c5e40,_0x374c0f){const _0x5c8e80=_0x369350;return client['Request'](_0x5c8e80('0x0'),{'body':_0x374c0f,'options':{'where':{'id':_0x3c5e40}},'log':_0x5c8e80('0x3')});},exports[_0x369350('0x4')]=function(_0x277e9a,_0x191d04){const _0x19cc68=_0x369350;return client[_0x19cc68('0x5')]('AddTagsToMailInteraction',{'body':_0x191d04,'options':{'where':{'id':_0x277e9a}},'log':'addTagsToChatInteraction'});}; \ No newline at end of file diff --git a/server/services/routing/rpc/mailMessage.js b/server/services/routing/rpc/mailMessage.js index 70ecfa9..1079243 100644 --- a/server/services/routing/rpc/mailMessage.js +++ b/server/services/routing/rpc/mailMessage.js @@ -1 +1 @@ -const a1184_0x3972=['Request','create','createMailMessage'];(function(_0x11175c,_0x3972df){const _0x4c7e6a=function(_0xe259ec){while(--_0xe259ec){_0x11175c['push'](_0x11175c['shift']());}};_0x4c7e6a(++_0x3972df);}(a1184_0x3972,0x16f));const a1184_0x4c7e=function(_0x11175c,_0x3972df){_0x11175c=_0x11175c-0x0;let _0x4c7e6a=a1184_0x3972[_0x11175c];return _0x4c7e6a;};const _0x31809c=a1184_0x4c7e;'use strict';const client=require('../client');exports[_0x31809c('0x0')]=function(_0xe259ec){const _0x3b35d1=_0x31809c;return client[_0x3b35d1('0x2')]('CreateMailMessage',{'body':_0xe259ec,'log':_0x3b35d1('0x1')});}; \ No newline at end of file +const a1184_0x4f65=['CreateMailMessage','createMailMessage','Request','../client','create'];(function(_0x49293a,_0x4f65b9){const _0xce956d=function(_0x95afab){while(--_0x95afab){_0x49293a['push'](_0x49293a['shift']());}};_0xce956d(++_0x4f65b9);}(a1184_0x4f65,0x16d));const a1184_0xce95=function(_0x49293a,_0x4f65b9){_0x49293a=_0x49293a-0x0;let _0xce956d=a1184_0x4f65[_0x49293a];return _0xce956d;};const _0x110cb9=a1184_0xce95;'use strict';const client=require(_0x110cb9('0x3'));exports[_0x110cb9('0x4')]=function(_0x95afab){const _0x4cc15f=_0x110cb9;return client[_0x4cc15f('0x2')](_0x4cc15f('0x0'),{'body':_0x95afab,'log':_0x4cc15f('0x1')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/mailQueue.js b/server/services/routing/rpc/mailQueue.js index 2d6b663..701cf3f 100644 --- a/server/services/routing/rpc/mailQueue.js +++ b/server/services/routing/rpc/mailQueue.js @@ -1 +1 @@ -const a1185_0x600c=['online','mailPause','Agents','User','GetMailQueue','Request','getMailQueues'];(function(_0x25f842,_0x600cc6){const _0x1a8be6=function(_0x5b11cc){while(--_0x5b11cc){_0x25f842['push'](_0x25f842['shift']());}};_0x1a8be6(++_0x600cc6);}(a1185_0x600c,0xea));const a1185_0x1a8b=function(_0x25f842,_0x600cc6){_0x25f842=_0x25f842-0x0;let _0x1a8be6=a1185_0x600c[_0x25f842];return _0x1a8be6;};'use strict';const client=require('../client');exports['getMailQueues']=function(){return function(){const _0x216b4f=a1185_0x1a8b;return client[_0x216b4f('0x2')](_0x216b4f('0x1'),{'options':{'raw':![],'attributes':['id','name','timeout','strategy'],'include':[{'model':_0x216b4f('0x0'),'as':_0x216b4f('0x6'),'attributes':['id','name',_0x216b4f('0x4'),_0x216b4f('0x5')]}]},'log':_0x216b4f('0x3')});};}; \ No newline at end of file +const a1185_0x468e=['getMailQueues','GetMailQueue','../client','strategy','name','timeout','Agents','mailPause'];(function(_0x167ced,_0x468eeb){const _0x3ab2c6=function(_0x431d95){while(--_0x431d95){_0x167ced['push'](_0x167ced['shift']());}};_0x3ab2c6(++_0x468eeb);}(a1185_0x468e,0x1d4));const a1185_0x3ab2=function(_0x167ced,_0x468eeb){_0x167ced=_0x167ced-0x0;let _0x3ab2c6=a1185_0x468e[_0x167ced];return _0x3ab2c6;};const _0x1ccaf=a1185_0x3ab2;'use strict';const client=require(_0x1ccaf('0x6'));exports[_0x1ccaf('0x4')]=function(){return function(){const _0x54d721=a1185_0x3ab2;return client['Request'](_0x54d721('0x5'),{'options':{'raw':![],'attributes':['id',_0x54d721('0x0'),_0x54d721('0x1'),_0x54d721('0x7')],'include':[{'model':'User','as':_0x54d721('0x2'),'attributes':['id',_0x54d721('0x0'),'online',_0x54d721('0x3')]}]},'log':_0x54d721('0x4')});};}; \ No newline at end of file diff --git a/server/services/routing/rpc/mailQueueReport.js b/server/services/routing/rpc/mailQueueReport.js index 647c9a3..952a88a 100644 --- a/server/services/routing/rpc/mailQueueReport.js +++ b/server/services/routing/rpc/mailQueueReport.js @@ -1 +1 @@ -const a1186_0x5d09=['update','UpdateMailQueueReport','Request','CreateMailQueueReport','DESC'];(function(_0x2c95de,_0x5d0975){const _0x583aa6=function(_0x23247e){while(--_0x23247e){_0x2c95de['push'](_0x2c95de['shift']());}};_0x583aa6(++_0x5d0975);}(a1186_0x5d09,0x106));const a1186_0x583a=function(_0x2c95de,_0x5d0975){_0x2c95de=_0x2c95de-0x0;let _0x583aa6=a1186_0x5d09[_0x2c95de];return _0x583aa6;};const _0x2671fe=a1186_0x583a;'use strict';const client=require('../client');exports['create']=function(_0x23247e){const _0x45cafe=a1186_0x583a;return client['Request'](_0x45cafe('0x1'),{'body':_0x23247e,'log':'CreateMailQueueReport'});},exports[_0x2671fe('0x3')]=function(_0x40d51a,_0x476f59){const _0xfff1e4=_0x2671fe;return client[_0xfff1e4('0x0')](_0xfff1e4('0x4'),{'body':_0x476f59,'options':{'where':{'uniqueid':_0x40d51a},'order':[['id',_0xfff1e4('0x2')]],'limit':0x1},'log':_0xfff1e4('0x4')});}; \ No newline at end of file +const a1186_0x4d51=['CreateMailQueueReport','UpdateMailQueueReport','create','DESC','Request'];(function(_0x3a4247,_0x4d5144){const _0x31a107=function(_0x22d6df){while(--_0x22d6df){_0x3a4247['push'](_0x3a4247['shift']());}};_0x31a107(++_0x4d5144);}(a1186_0x4d51,0x120));const a1186_0x31a1=function(_0x3a4247,_0x4d5144){_0x3a4247=_0x3a4247-0x0;let _0x31a107=a1186_0x4d51[_0x3a4247];return _0x31a107;};const _0x2b7cfa=a1186_0x31a1;'use strict';const client=require('../client');exports[_0x2b7cfa('0x4')]=function(_0x22d6df){const _0x38fd77=_0x2b7cfa;return client[_0x38fd77('0x1')](_0x38fd77('0x2'),{'body':_0x22d6df,'log':_0x38fd77('0x2')});},exports['update']=function(_0x4a4160,_0x5df1c4){const _0x1d8bec=_0x2b7cfa;return client[_0x1d8bec('0x1')](_0x1d8bec('0x3'),{'body':_0x5df1c4,'options':{'where':{'uniqueid':_0x4a4160},'order':[['id',_0x1d8bec('0x0')]],'limit':0x1},'log':'UpdateMailQueueReport'});}; \ No newline at end of file diff --git a/server/services/routing/rpc/openchannelInteraction.js b/server/services/routing/rpc/openchannelInteraction.js index c81320c..d372dca 100644 --- a/server/services/routing/rpc/openchannelInteraction.js +++ b/server/services/routing/rpc/openchannelInteraction.js @@ -1 +1 @@ -const a1187_0x44e4=['updateOpenchannelInteraction','../client','update','Request','UpdateOpenchannelInteraction','AddTagsToOpenchannelInteraction'];(function(_0x1d31d7,_0x44e4a3){const _0xf6a39e=function(_0x680398){while(--_0x680398){_0x1d31d7['push'](_0x1d31d7['shift']());}};_0xf6a39e(++_0x44e4a3);}(a1187_0x44e4,0x190));const a1187_0xf6a3=function(_0x1d31d7,_0x44e4a3){_0x1d31d7=_0x1d31d7-0x0;let _0xf6a39e=a1187_0x44e4[_0x1d31d7];return _0xf6a39e;};const _0x5bc0ce=a1187_0xf6a3;'use strict';const client=require(_0x5bc0ce('0x3'));exports[_0x5bc0ce('0x4')]=function(_0x680398,_0x3996a3){const _0xe2743a=_0x5bc0ce;return client['Request'](_0xe2743a('0x0'),{'body':_0x3996a3,'options':{'where':{'id':_0x680398}},'log':_0xe2743a('0x2')});},exports['addTags']=function(_0x2b7ed7,_0xa9dc86){const _0x17a33b=_0x5bc0ce;return client[_0x17a33b('0x5')](_0x17a33b('0x1'),{'body':_0xa9dc86,'options':{'where':{'id':_0x2b7ed7}},'log':'addTagsToChatInteraction'});}; \ No newline at end of file +const a1187_0x569c=['Request','addTags','UpdateOpenchannelInteraction','addTagsToChatInteraction','updateOpenchannelInteraction','AddTagsToOpenchannelInteraction'];(function(_0x44780d,_0x569c90){const _0x51a4cd=function(_0x5997ca){while(--_0x5997ca){_0x44780d['push'](_0x44780d['shift']());}};_0x51a4cd(++_0x569c90);}(a1187_0x569c,0x1ee));const a1187_0x51a4=function(_0x44780d,_0x569c90){_0x44780d=_0x44780d-0x0;let _0x51a4cd=a1187_0x569c[_0x44780d];return _0x51a4cd;};const _0x27274d=a1187_0x51a4;'use strict';const client=require('../client');exports['update']=function(_0x5997ca,_0x5ba88b){const _0x2f86d1=a1187_0x51a4;return client[_0x2f86d1('0x4')](_0x2f86d1('0x0'),{'body':_0x5ba88b,'options':{'where':{'id':_0x5997ca}},'log':_0x2f86d1('0x2')});},exports[_0x27274d('0x5')]=function(_0x404735,_0x1233d1){const _0x10c98c=_0x27274d;return client[_0x10c98c('0x4')](_0x10c98c('0x3'),{'body':_0x1233d1,'options':{'where':{'id':_0x404735}},'log':_0x10c98c('0x1')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/openchannelMessage.js b/server/services/routing/rpc/openchannelMessage.js index 1bc72e6..1544ce9 100644 --- a/server/services/routing/rpc/openchannelMessage.js +++ b/server/services/routing/rpc/openchannelMessage.js @@ -1 +1 @@ -const a1188_0x3136=['Request','create','createOpenchannelMessage'];(function(_0x537b26,_0x3136be){const _0x31ff0e=function(_0xcaf289){while(--_0xcaf289){_0x537b26['push'](_0x537b26['shift']());}};_0x31ff0e(++_0x3136be);}(a1188_0x3136,0x1e2));const a1188_0x31ff=function(_0x537b26,_0x3136be){_0x537b26=_0x537b26-0x0;let _0x31ff0e=a1188_0x3136[_0x537b26];return _0x31ff0e;};const _0x290be0=a1188_0x31ff;'use strict';const client=require('../client');exports[_0x290be0('0x2')]=function(_0xcaf289){const _0x5d2282=_0x290be0;return client[_0x5d2282('0x1')]('CreateOpenchannelMessage',{'body':_0xcaf289,'log':_0x5d2282('0x0')});}; \ No newline at end of file +const a1188_0x20af=['createOpenchannelMessage','Request','../client'];(function(_0x45ac71,_0x20affb){const _0x282b73=function(_0x4a2fbc){while(--_0x4a2fbc){_0x45ac71['push'](_0x45ac71['shift']());}};_0x282b73(++_0x20affb);}(a1188_0x20af,0x9d));const a1188_0x282b=function(_0x45ac71,_0x20affb){_0x45ac71=_0x45ac71-0x0;let _0x282b73=a1188_0x20af[_0x45ac71];return _0x282b73;};const _0x2c9bd2=a1188_0x282b;'use strict';const client=require(_0x2c9bd2('0x1'));exports['create']=function(_0x4a2fbc){const _0x503b33=_0x2c9bd2;return client[_0x503b33('0x0')]('CreateOpenchannelMessage',{'body':_0x4a2fbc,'log':_0x503b33('0x2')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/openchannelQueue.js b/server/services/routing/rpc/openchannelQueue.js index 4603c93..c510e75 100644 --- a/server/services/routing/rpc/openchannelQueue.js +++ b/server/services/routing/rpc/openchannelQueue.js @@ -1 +1 @@ -const a1189_0x20a0=['strategy','timeout','openchannelPause','name','Request','getOpenchannelQueues','Agents','../client'];(function(_0x29db8b,_0x20a068){const _0x292dca=function(_0x5ab428){while(--_0x5ab428){_0x29db8b['push'](_0x29db8b['shift']());}};_0x292dca(++_0x20a068);}(a1189_0x20a0,0x116));const a1189_0x292d=function(_0x29db8b,_0x20a068){_0x29db8b=_0x29db8b-0x0;let _0x292dca=a1189_0x20a0[_0x29db8b];return _0x292dca;};const _0x52281d=a1189_0x292d;'use strict';const client=require(_0x52281d('0x1'));exports['getOpenchannelQueues']=function(){return function(){const _0x41123e=a1189_0x292d;return client[_0x41123e('0x6')]('GetOpenchannelQueue',{'options':{'raw':![],'attributes':['id',_0x41123e('0x5'),_0x41123e('0x3'),_0x41123e('0x2')],'include':[{'model':'User','as':_0x41123e('0x0'),'attributes':['id',_0x41123e('0x5'),'online',_0x41123e('0x4')]}]},'log':_0x41123e('0x7')});};}; \ No newline at end of file +const a1189_0x5353=['Request','name','User','openchannelPause','online','getOpenchannelQueues','timeout','strategy','Agents'];(function(_0x210812,_0x535371){const _0x2f5640=function(_0x574639){while(--_0x574639){_0x210812['push'](_0x210812['shift']());}};_0x2f5640(++_0x535371);}(a1189_0x5353,0xb6));const a1189_0x2f56=function(_0x210812,_0x535371){_0x210812=_0x210812-0x0;let _0x2f5640=a1189_0x5353[_0x210812];return _0x2f5640;};'use strict';const client=require('../client');exports['getOpenchannelQueues']=function(){return function(){const _0x1a41cc=a1189_0x2f56;return client[_0x1a41cc('0x7')]('GetOpenchannelQueue',{'options':{'raw':![],'attributes':['id',_0x1a41cc('0x8'),_0x1a41cc('0x4'),_0x1a41cc('0x5')],'include':[{'model':_0x1a41cc('0x0'),'as':_0x1a41cc('0x6'),'attributes':['id',_0x1a41cc('0x8'),_0x1a41cc('0x2'),_0x1a41cc('0x1')]}]},'log':_0x1a41cc('0x3')});};}; \ No newline at end of file diff --git a/server/services/routing/rpc/openchannelQueueReport.js b/server/services/routing/rpc/openchannelQueueReport.js index 9584ab5..9eb3090 100644 --- a/server/services/routing/rpc/openchannelQueueReport.js +++ b/server/services/routing/rpc/openchannelQueueReport.js @@ -1 +1 @@ -const a1190_0xcff0=['create','CreateOpenchannelQueueReport','DESC','Request','UpdateOpenchannelQueueReport'];(function(_0x447500,_0xcff06e){const _0x5cf838=function(_0x2a011c){while(--_0x2a011c){_0x447500['push'](_0x447500['shift']());}};_0x5cf838(++_0xcff06e);}(a1190_0xcff0,0x74));const a1190_0x5cf8=function(_0x447500,_0xcff06e){_0x447500=_0x447500-0x0;let _0x5cf838=a1190_0xcff0[_0x447500];return _0x5cf838;};const _0x54b702=a1190_0x5cf8;'use strict';const client=require('../client');exports[_0x54b702('0x4')]=function(_0x2a011c){const _0x67042f=_0x54b702;return client['Request'](_0x67042f('0x0'),{'body':_0x2a011c,'log':_0x67042f('0x0')});},exports['update']=function(_0x356f5b,_0x58555e){const _0x3f87da=_0x54b702;return client[_0x3f87da('0x2')](_0x3f87da('0x3'),{'body':_0x58555e,'options':{'where':{'uniqueid':_0x356f5b},'order':[['id',_0x3f87da('0x1')]],'limit':0x1},'log':'UpdateOpenchannelQueueReport'});}; \ No newline at end of file +const a1190_0x268a=['DESC','CreateOpenchannelQueueReport','Request','UpdateOpenchannelQueueReport','create'];(function(_0x55d86b,_0x268a08){const _0x326c1e=function(_0x23eaee){while(--_0x23eaee){_0x55d86b['push'](_0x55d86b['shift']());}};_0x326c1e(++_0x268a08);}(a1190_0x268a,0x1c9));const a1190_0x326c=function(_0x55d86b,_0x268a08){_0x55d86b=_0x55d86b-0x0;let _0x326c1e=a1190_0x268a[_0x55d86b];return _0x326c1e;};const _0xe226b0=a1190_0x326c;'use strict';const client=require('../client');exports[_0xe226b0('0x2')]=function(_0x23eaee){const _0x53ee37=_0xe226b0;return client[_0x53ee37('0x0')](_0x53ee37('0x4'),{'body':_0x23eaee,'log':_0x53ee37('0x4')});},exports['update']=function(_0x5012a2,_0x3467e8){const _0x239516=_0xe226b0;return client['Request'](_0x239516('0x1'),{'body':_0x3467e8,'options':{'where':{'uniqueid':_0x5012a2},'order':[['id',_0x239516('0x3')]],'limit':0x1},'log':_0x239516('0x1')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/smsInteraction.js b/server/services/routing/rpc/smsInteraction.js index 9e0b83b..b5ada6f 100644 --- a/server/services/routing/rpc/smsInteraction.js +++ b/server/services/routing/rpc/smsInteraction.js @@ -1 +1 @@ -const a1191_0x386d=['Request','../client','update','UpdateSmsInteraction','addTagsToSmsInteraction','addTags','AddTagsToSmsInteraction'];(function(_0x56c4e6,_0x386d99){const _0x2862b9=function(_0x5e54d0){while(--_0x5e54d0){_0x56c4e6['push'](_0x56c4e6['shift']());}};_0x2862b9(++_0x386d99);}(a1191_0x386d,0x66));const a1191_0x2862=function(_0x56c4e6,_0x386d99){_0x56c4e6=_0x56c4e6-0x0;let _0x2862b9=a1191_0x386d[_0x56c4e6];return _0x2862b9;};const _0x29ad52=a1191_0x2862;'use strict';const client=require(_0x29ad52('0x4'));exports[_0x29ad52('0x5')]=function(_0x5e54d0,_0x1a52e0){const _0x4d20d7=_0x29ad52;return client[_0x4d20d7('0x3')](_0x4d20d7('0x6'),{'body':_0x1a52e0,'options':{'where':{'id':_0x5e54d0}},'log':'updateSmsInteraction'});},exports[_0x29ad52('0x1')]=function(_0x2c9d2d,_0x9547d9){const _0x3fb48e=_0x29ad52;return client[_0x3fb48e('0x3')](_0x3fb48e('0x2'),{'body':_0x9547d9,'options':{'where':{'id':_0x2c9d2d}},'log':_0x3fb48e('0x0')});}; \ No newline at end of file +const a1191_0x1f47=['updateSmsInteraction','UpdateSmsInteraction','../client','AddTagsToSmsInteraction','addTags','Request','addTagsToSmsInteraction'];(function(_0x48d4c6,_0x1f476d){const _0x49bc72=function(_0x1a4775){while(--_0x1a4775){_0x48d4c6['push'](_0x48d4c6['shift']());}};_0x49bc72(++_0x1f476d);}(a1191_0x1f47,0x145));const a1191_0x49bc=function(_0x48d4c6,_0x1f476d){_0x48d4c6=_0x48d4c6-0x0;let _0x49bc72=a1191_0x1f47[_0x48d4c6];return _0x49bc72;};const _0xa066f5=a1191_0x49bc;'use strict';const client=require(_0xa066f5('0x6'));exports['update']=function(_0x1a4775,_0x2e55a7){const _0x33c445=_0xa066f5;return client[_0x33c445('0x2')](_0x33c445('0x5'),{'body':_0x2e55a7,'options':{'where':{'id':_0x1a4775}},'log':_0x33c445('0x4')});},exports[_0xa066f5('0x1')]=function(_0x316159,_0x4aa037){const _0x130a5d=_0xa066f5;return client[_0x130a5d('0x2')](_0x130a5d('0x0'),{'body':_0x4aa037,'options':{'where':{'id':_0x316159}},'log':_0x130a5d('0x3')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/smsMessage.js b/server/services/routing/rpc/smsMessage.js index fd3f2a3..b852f6f 100644 --- a/server/services/routing/rpc/smsMessage.js +++ b/server/services/routing/rpc/smsMessage.js @@ -1 +1 @@ -const a1192_0x51ad=['create','../client','CreateSmsMessage','createSmsMessage'];(function(_0x1464a4,_0x51ad07){const _0x583757=function(_0x1be436){while(--_0x1be436){_0x1464a4['push'](_0x1464a4['shift']());}};_0x583757(++_0x51ad07);}(a1192_0x51ad,0x147));const a1192_0x5837=function(_0x1464a4,_0x51ad07){_0x1464a4=_0x1464a4-0x0;let _0x583757=a1192_0x51ad[_0x1464a4];return _0x583757;};const _0x349d9a=a1192_0x5837;'use strict';const client=require(_0x349d9a('0x2'));exports[_0x349d9a('0x1')]=function(_0x1be436){const _0xd1d91=_0x349d9a;return client['Request'](_0xd1d91('0x3'),{'body':_0x1be436,'log':_0xd1d91('0x0')});}; \ No newline at end of file +const a1192_0x1210=['CreateSmsMessage','createSmsMessage','../client'];(function(_0x141d58,_0x121092){const _0x1fcf22=function(_0x484890){while(--_0x484890){_0x141d58['push'](_0x141d58['shift']());}};_0x1fcf22(++_0x121092);}(a1192_0x1210,0x92));const a1192_0x1fcf=function(_0x141d58,_0x121092){_0x141d58=_0x141d58-0x0;let _0x1fcf22=a1192_0x1210[_0x141d58];return _0x1fcf22;};const _0x390a7e=a1192_0x1fcf;'use strict';const client=require(_0x390a7e('0x0'));exports['create']=function(_0x484890){const _0x15bf96=_0x390a7e;return client['Request'](_0x15bf96('0x1'),{'body':_0x484890,'log':_0x15bf96('0x2')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/smsQueue.js b/server/services/routing/rpc/smsQueue.js index 8c9619b..7f5119b 100644 --- a/server/services/routing/rpc/smsQueue.js +++ b/server/services/routing/rpc/smsQueue.js @@ -1 +1 @@ -const a1193_0x5a22=['../client','Request','online','getSmsQueues','GetSmsQueue','User','smsPause','strategy','Agents','name','timeout'];(function(_0x4647aa,_0x5a2231){const _0x4105ad=function(_0x2de75f){while(--_0x2de75f){_0x4647aa['push'](_0x4647aa['shift']());}};_0x4105ad(++_0x5a2231);}(a1193_0x5a22,0x7a));const a1193_0x4105=function(_0x4647aa,_0x5a2231){_0x4647aa=_0x4647aa-0x0;let _0x4105ad=a1193_0x5a22[_0x4647aa];return _0x4105ad;};const _0x4fb120=a1193_0x4105;'use strict';const client=require(_0x4fb120('0xa'));exports[_0x4fb120('0x2')]=function(){return function(){const _0x41a5fb=a1193_0x4105;return client[_0x41a5fb('0x0')](_0x41a5fb('0x3'),{'options':{'raw':![],'attributes':['id','name',_0x41a5fb('0x9'),_0x41a5fb('0x6')],'include':[{'model':_0x41a5fb('0x4'),'as':_0x41a5fb('0x7'),'attributes':['id',_0x41a5fb('0x8'),_0x41a5fb('0x1'),_0x41a5fb('0x5')]}]},'log':_0x41a5fb('0x2')});};}; \ No newline at end of file +const a1193_0x331f=['Request','name','smsPause','online','../client','User','getSmsQueues','strategy','GetSmsQueue','timeout'];(function(_0x4b620e,_0x331f62){const _0x1398c9=function(_0xf2048b){while(--_0xf2048b){_0x4b620e['push'](_0x4b620e['shift']());}};_0x1398c9(++_0x331f62);}(a1193_0x331f,0x1e7));const a1193_0x1398=function(_0x4b620e,_0x331f62){_0x4b620e=_0x4b620e-0x0;let _0x1398c9=a1193_0x331f[_0x4b620e];return _0x1398c9;};const _0xcd62f0=a1193_0x1398;'use strict';const client=require(_0xcd62f0('0x7'));exports[_0xcd62f0('0x9')]=function(){return function(){const _0x29ace5=a1193_0x1398;return client[_0x29ace5('0x3')](_0x29ace5('0x1'),{'options':{'raw':![],'attributes':['id',_0x29ace5('0x4'),_0x29ace5('0x2'),_0x29ace5('0x0')],'include':[{'model':_0x29ace5('0x8'),'as':'Agents','attributes':['id',_0x29ace5('0x4'),_0x29ace5('0x6'),_0x29ace5('0x5')]}]},'log':_0x29ace5('0x9')});};}; \ No newline at end of file diff --git a/server/services/routing/rpc/smsQueueReport.js b/server/services/routing/rpc/smsQueueReport.js index 04ab1c8..50819d7 100644 --- a/server/services/routing/rpc/smsQueueReport.js +++ b/server/services/routing/rpc/smsQueueReport.js @@ -1 +1 @@ -const a1194_0x33b1=['create','../client','UpdateSmsQueueReport','CreateSmsQueueReport','Request'];(function(_0x2bbc53,_0x33b18d){const _0x23ec79=function(_0x5b6476){while(--_0x5b6476){_0x2bbc53['push'](_0x2bbc53['shift']());}};_0x23ec79(++_0x33b18d);}(a1194_0x33b1,0x9a));const a1194_0x23ec=function(_0x2bbc53,_0x33b18d){_0x2bbc53=_0x2bbc53-0x0;let _0x23ec79=a1194_0x33b1[_0x2bbc53];return _0x23ec79;};const _0x181f2d=a1194_0x23ec;'use strict';const client=require(_0x181f2d('0x2'));exports[_0x181f2d('0x1')]=function(_0x5b6476){const _0x17b5dd=_0x181f2d;return client[_0x17b5dd('0x0')](_0x17b5dd('0x4'),{'body':_0x5b6476,'log':_0x17b5dd('0x4')});},exports['update']=function(_0x12bcfd,_0x518be1){const _0x2a56da=_0x181f2d;return client[_0x2a56da('0x0')]('UpdateSmsQueueReport',{'body':_0x518be1,'options':{'where':{'uniqueid':_0x12bcfd},'order':[['id','DESC']],'limit':0x1},'log':_0x2a56da('0x3')});}; \ No newline at end of file +const a1194_0x235e=['CreateSmsQueueReport','DESC','create','update','Request','UpdateSmsQueueReport','../client'];(function(_0xe80aac,_0x235e59){const _0x4eb5a7=function(_0x89555a){while(--_0x89555a){_0xe80aac['push'](_0xe80aac['shift']());}};_0x4eb5a7(++_0x235e59);}(a1194_0x235e,0x92));const a1194_0x4eb5=function(_0xe80aac,_0x235e59){_0xe80aac=_0xe80aac-0x0;let _0x4eb5a7=a1194_0x235e[_0xe80aac];return _0x4eb5a7;};const _0x542166=a1194_0x4eb5;'use strict';const client=require(_0x542166('0x0'));exports[_0x542166('0x3')]=function(_0x89555a){const _0x467fc5=_0x542166;return client['Request'](_0x467fc5('0x1'),{'body':_0x89555a,'log':_0x467fc5('0x1')});},exports[_0x542166('0x4')]=function(_0x486504,_0x2d8ea4){const _0x1533d8=_0x542166;return client[_0x1533d8('0x5')]('UpdateSmsQueueReport',{'body':_0x2d8ea4,'options':{'where':{'uniqueid':_0x486504},'order':[['id',_0x1533d8('0x2')]],'limit':0x1},'log':_0x1533d8('0x6')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/user.js b/server/services/routing/rpc/user.js index f0abec2..ecc1d60 100644 --- a/server/services/routing/rpc/user.js +++ b/server/services/routing/rpc/user.js @@ -1 +1 @@ -const a1195_0x361d=['chatCapacity','getAgents','faxPause','lastPauseAt','chatPause','faxCapacity','online','openchannelPause','mailCapacity','name','Request','GetUser','smsPause','mailPause','pauseType','voicePause','smsCapacity'];(function(_0x16a804,_0x361d73){const _0xd8ca4c=function(_0x5ee982){while(--_0x5ee982){_0x16a804['push'](_0x16a804['shift']());}};_0xd8ca4c(++_0x361d73);}(a1195_0x361d,0x1d9));const a1195_0xd8ca=function(_0x16a804,_0x361d73){_0x16a804=_0x16a804-0x0;let _0xd8ca4c=a1195_0x361d[_0x16a804];return _0xd8ca4c;};const _0x5b4bf2=a1195_0xd8ca;'use strict';const client=require('../client');exports[_0x5b4bf2('0x4')]=function(){return function(){const _0x5ea973=a1195_0xd8ca;return client[_0x5ea973('0xd')](_0x5ea973('0xe'),{'options':{'raw':!![],'where':{'role':'agent'},'attributes':['id',_0x5ea973('0xc'),_0x5ea973('0x9'),_0x5ea973('0x0'),_0x5ea973('0x6'),_0x5ea973('0x1'),_0x5ea973('0x7'),_0x5ea973('0x10'),_0x5ea973('0x5'),_0x5ea973('0xf'),'whatsappPause',_0x5ea973('0xa'),_0x5ea973('0x3'),_0x5ea973('0xb'),_0x5ea973('0x8'),_0x5ea973('0x2'),'whatsappCapacity','openchannelCapacity']},'log':_0x5ea973('0x4')});};}; \ No newline at end of file +const a1195_0x459c=['faxPause','openchannelPause','lastPauseAt','smsCapacity','GetUser','whatsappPause','name','mailCapacity','online','mailPause','Request','chatCapacity','../client','getAgents','voicePause'];(function(_0x349be0,_0x459caa){const _0x219f0c=function(_0x372f52){while(--_0x372f52){_0x349be0['push'](_0x349be0['shift']());}};_0x219f0c(++_0x459caa);}(a1195_0x459c,0xe4));const a1195_0x219f=function(_0x349be0,_0x459caa){_0x349be0=_0x349be0-0x0;let _0x219f0c=a1195_0x459c[_0x349be0];return _0x219f0c;};const _0x25b512=a1195_0x219f;'use strict';const client=require(_0x25b512('0x9'));exports['getAgents']=function(){return function(){const _0x446c29=a1195_0x219f;return client[_0x446c29('0x7')](_0x446c29('0x1'),{'options':{'raw':!![],'where':{'role':'agent'},'attributes':['id',_0x446c29('0x3'),_0x446c29('0x5'),'pauseType',_0x446c29('0xe'),_0x446c29('0xb'),'chatPause',_0x446c29('0x6'),_0x446c29('0xc'),'smsPause',_0x446c29('0x2'),_0x446c29('0xd'),_0x446c29('0x8'),_0x446c29('0x4'),'faxCapacity',_0x446c29('0x0'),'whatsappCapacity','openchannelCapacity']},'log':_0x446c29('0xa')});};}; \ No newline at end of file diff --git a/server/services/routing/rpc/whatsappInteraction.js b/server/services/routing/rpc/whatsappInteraction.js index 1bff9c1..768b062 100644 --- a/server/services/routing/rpc/whatsappInteraction.js +++ b/server/services/routing/rpc/whatsappInteraction.js @@ -1 +1 @@ -const a1196_0x5289=['addTags','Request','../client','updateWhatsappInteraction','UpdateWhatsappInteraction','update','addTagsToWhatsappInteraction'];(function(_0x4ad009,_0x528990){const _0x26b69a=function(_0x54743a){while(--_0x54743a){_0x4ad009['push'](_0x4ad009['shift']());}};_0x26b69a(++_0x528990);}(a1196_0x5289,0x11e));const a1196_0x26b6=function(_0x4ad009,_0x528990){_0x4ad009=_0x4ad009-0x0;let _0x26b69a=a1196_0x5289[_0x4ad009];return _0x26b69a;};const _0xff2025=a1196_0x26b6;'use strict';const client=require(_0xff2025('0x3'));exports[_0xff2025('0x6')]=function(_0x54743a,_0x3f0546){const _0x34ced4=_0xff2025;return client[_0x34ced4('0x2')](_0x34ced4('0x5'),{'body':_0x3f0546,'options':{'where':{'id':_0x54743a}},'log':_0x34ced4('0x4')});},exports[_0xff2025('0x1')]=function(_0x5bcbc9,_0x2e6b89){const _0x1e02a2=_0xff2025;return client['Request']('AddTagsToWhatsappInteraction',{'body':_0x2e6b89,'options':{'where':{'id':_0x5bcbc9}},'log':_0x1e02a2('0x0')});}; \ No newline at end of file +const a1196_0xed10=['addTags','UpdateWhatsappInteraction','updateWhatsappInteraction','../client','AddTagsToWhatsappInteraction','addTagsToWhatsappInteraction','Request','update'];(function(_0x2cc3cf,_0xed1005){const _0x500478=function(_0x55a5ea){while(--_0x55a5ea){_0x2cc3cf['push'](_0x2cc3cf['shift']());}};_0x500478(++_0xed1005);}(a1196_0xed10,0x198));const a1196_0x5004=function(_0x2cc3cf,_0xed1005){_0x2cc3cf=_0x2cc3cf-0x0;let _0x500478=a1196_0xed10[_0x2cc3cf];return _0x500478;};const _0x56b41a=a1196_0x5004;'use strict';const client=require(_0x56b41a('0x3'));exports[_0x56b41a('0x7')]=function(_0x55a5ea,_0x5ea422){const _0x589cc7=_0x56b41a;return client[_0x589cc7('0x6')](_0x589cc7('0x1'),{'body':_0x5ea422,'options':{'where':{'id':_0x55a5ea}},'log':_0x589cc7('0x2')});},exports[_0x56b41a('0x0')]=function(_0x13fa9a,_0x13d8ca){const _0x535af7=_0x56b41a;return client['Request'](_0x535af7('0x4'),{'body':_0x13d8ca,'options':{'where':{'id':_0x13fa9a}},'log':_0x535af7('0x5')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/whatsappMessage.js b/server/services/routing/rpc/whatsappMessage.js index 148240e..65ee898 100644 --- a/server/services/routing/rpc/whatsappMessage.js +++ b/server/services/routing/rpc/whatsappMessage.js @@ -1 +1 @@ -const a1197_0xa12f=['Request','../client','CreateWhatsappMessage'];(function(_0x120b9c,_0xa12f88){const _0x7c0bdd=function(_0x58f004){while(--_0x58f004){_0x120b9c['push'](_0x120b9c['shift']());}};_0x7c0bdd(++_0xa12f88);}(a1197_0xa12f,0xdc));const a1197_0x7c0b=function(_0x120b9c,_0xa12f88){_0x120b9c=_0x120b9c-0x0;let _0x7c0bdd=a1197_0xa12f[_0x120b9c];return _0x7c0bdd;};const _0x4bf921=a1197_0x7c0b;'use strict';const client=require(_0x4bf921('0x0'));exports['create']=function(_0x58f004){const _0x4a0f2f=_0x4bf921;return client[_0x4a0f2f('0x2')](_0x4a0f2f('0x1'),{'body':_0x58f004,'log':'createWhatsappMessage'});}; \ No newline at end of file +const a1197_0xec63=['Request','../client','createWhatsappMessage','CreateWhatsappMessage'];(function(_0x50bdd9,_0xec639){const _0x4a50e3=function(_0x73c858){while(--_0x73c858){_0x50bdd9['push'](_0x50bdd9['shift']());}};_0x4a50e3(++_0xec639);}(a1197_0xec63,0x75));const a1197_0x4a50=function(_0x50bdd9,_0xec639){_0x50bdd9=_0x50bdd9-0x0;let _0x4a50e3=a1197_0xec63[_0x50bdd9];return _0x4a50e3;};const _0x115e9a=a1197_0x4a50;'use strict';const client=require(_0x115e9a('0x0'));exports['create']=function(_0x73c858){const _0x3774bc=_0x115e9a;return client[_0x3774bc('0x3')](_0x3774bc('0x2'),{'body':_0x73c858,'log':_0x3774bc('0x1')});}; \ No newline at end of file diff --git a/server/services/routing/rpc/whatsappQueue.js b/server/services/routing/rpc/whatsappQueue.js index adf4006..30cb400 100644 --- a/server/services/routing/rpc/whatsappQueue.js +++ b/server/services/routing/rpc/whatsappQueue.js @@ -1 +1 @@ -const a1198_0x1530=['timeout','GetWhatsappQueue','User','getWhatsappQueues','strategy','name','whatsappPause','Request','Agents'];(function(_0x49b22c,_0x1530c4){const _0x56e526=function(_0x5812f9){while(--_0x5812f9){_0x49b22c['push'](_0x49b22c['shift']());}};_0x56e526(++_0x1530c4);}(a1198_0x1530,0x1b9));const a1198_0x56e5=function(_0x49b22c,_0x1530c4){_0x49b22c=_0x49b22c-0x0;let _0x56e526=a1198_0x1530[_0x49b22c];return _0x56e526;};const _0x38920d=a1198_0x56e5;'use strict';const client=require('../client');exports[_0x38920d('0x3')]=function(){return function(){const _0x22b3dd=a1198_0x56e5;return client[_0x22b3dd('0x7')](_0x22b3dd('0x1'),{'options':{'raw':![],'attributes':['id',_0x22b3dd('0x5'),_0x22b3dd('0x0'),_0x22b3dd('0x4')],'include':[{'model':_0x22b3dd('0x2'),'as':_0x22b3dd('0x8'),'attributes':['id',_0x22b3dd('0x5'),'online',_0x22b3dd('0x6')]}]},'log':_0x22b3dd('0x3')});};}; \ No newline at end of file +const a1198_0x49d1=['User','whatsappPause','getWhatsappQueues','name','Agents','strategy','../client','timeout','online'];(function(_0x259dfa,_0x49d177){const _0x300eb4=function(_0x1a4143){while(--_0x1a4143){_0x259dfa['push'](_0x259dfa['shift']());}};_0x300eb4(++_0x49d177);}(a1198_0x49d1,0x1e6));const a1198_0x300e=function(_0x259dfa,_0x49d177){_0x259dfa=_0x259dfa-0x0;let _0x300eb4=a1198_0x49d1[_0x259dfa];return _0x300eb4;};const _0x36b545=a1198_0x300e;'use strict';const client=require(_0x36b545('0x6'));exports[_0x36b545('0x2')]=function(){return function(){const _0x468db4=a1198_0x300e;return client['Request']('GetWhatsappQueue',{'options':{'raw':![],'attributes':['id',_0x468db4('0x3'),_0x468db4('0x7'),_0x468db4('0x5')],'include':[{'model':_0x468db4('0x0'),'as':_0x468db4('0x4'),'attributes':['id',_0x468db4('0x3'),_0x468db4('0x8'),_0x468db4('0x1')]}]},'log':'getWhatsappQueues'});};}; \ No newline at end of file diff --git a/server/services/routing/rpc/whatsappQueueReport.js b/server/services/routing/rpc/whatsappQueueReport.js index 8d749f0..3de6a3a 100644 --- a/server/services/routing/rpc/whatsappQueueReport.js +++ b/server/services/routing/rpc/whatsappQueueReport.js @@ -1 +1 @@ -const a1199_0x27c3=['DESC','update','Request','create','../client','UpdateWhatsappQueueReport','CreateWhatsappQueueReport'];(function(_0x19816e,_0x27c377){const _0x433568=function(_0x311296){while(--_0x311296){_0x19816e['push'](_0x19816e['shift']());}};_0x433568(++_0x27c377);}(a1199_0x27c3,0x1b8));const a1199_0x4335=function(_0x19816e,_0x27c377){_0x19816e=_0x19816e-0x0;let _0x433568=a1199_0x27c3[_0x19816e];return _0x433568;};const _0x13d0fc=a1199_0x4335;'use strict';const client=require(_0x13d0fc('0x5'));exports[_0x13d0fc('0x4')]=function(_0x311296){const _0x3cb21e=_0x13d0fc;return client[_0x3cb21e('0x3')](_0x3cb21e('0x0'),{'body':_0x311296,'log':_0x3cb21e('0x0')});},exports[_0x13d0fc('0x2')]=function(_0x575650,_0x45ae2e){const _0x358141=_0x13d0fc;return client[_0x358141('0x3')](_0x358141('0x6'),{'body':_0x45ae2e,'options':{'where':{'uniqueid':_0x575650},'order':[['id',_0x358141('0x1')]],'limit':0x1},'log':_0x358141('0x6')});}; \ No newline at end of file +const a1199_0xf2c3=['UpdateWhatsappQueueReport','CreateWhatsappQueueReport','Request','create','update'];(function(_0x4faa44,_0xf2c3){const _0x1d46f7=function(_0x2d140d){while(--_0x2d140d){_0x4faa44['push'](_0x4faa44['shift']());}};_0x1d46f7(++_0xf2c3);}(a1199_0xf2c3,0x1c7));const a1199_0x1d46=function(_0x4faa44,_0xf2c3){_0x4faa44=_0x4faa44-0x0;let _0x1d46f7=a1199_0xf2c3[_0x4faa44];return _0x1d46f7;};const _0x108d8a=a1199_0x1d46;'use strict';const client=require('../client');exports[_0x108d8a('0x3')]=function(_0x2d140d){const _0x1ec608=_0x108d8a;return client[_0x1ec608('0x2')](_0x1ec608('0x1'),{'body':_0x2d140d,'log':_0x1ec608('0x1')});},exports[_0x108d8a('0x4')]=function(_0x2fcbc6,_0x4e4bac){const _0x314ab8=_0x108d8a;return client['Request'](_0x314ab8('0x0'),{'body':_0x4e4bac,'options':{'where':{'uniqueid':_0x2fcbc6},'order':[['id','DESC']],'limit':0x1},'log':_0x314ab8('0x0')});}; \ No newline at end of file diff --git a/server/services/routing/server/applications/agent.js b/server/services/routing/server/applications/agent.js index c16bf5b..4e69ada 100644 --- a/server/services/routing/server/applications/agent.js +++ b/server/services/routing/server/applications/agent.js @@ -1 +1 @@ -const a1200_0x2368=['createQueue','atimeout','string','[%s][AGENT]\x20agent\x20not\x20found\x20%s','[%s][AGENT]\x20ROUTING\x20END','rules','find','agent','info','../../../../config/logger','close','log','complete','START:%s','[%s][QUEUE]\x20%s','stack','name','name\x20is\x20a\x20string\x20and\x20it\x20is\x20required','timeout','map','toLowerCase','next','routing','./strategy','[%s][AGENT]\x20ROUTING\x20STOPPED','lodash','number','util','end','validate','format','error','stop','[%s][AGENT][NAME:%s][STATUS:%s]','seq-queue','join','length','channel'];(function(_0x19c9d9,_0x2368a7){const _0x52dcb6=function(_0x198635){while(--_0x198635){_0x19c9d9['push'](_0x19c9d9['shift']());}};_0x52dcb6(++_0x2368a7);}(a1200_0x2368,0x126));const a1200_0x52dc=function(_0x19c9d9,_0x2368a7){_0x19c9d9=_0x19c9d9-0x0;let _0x52dcb6=a1200_0x2368[_0x19c9d9];return _0x52dcb6;};const _0x2e87c3=a1200_0x52dc;'use strict';const schema=require(_0x2e87c3('0x1')),_=require(_0x2e87c3('0x23')),util=require(_0x2e87c3('0x25')),seqqueue=require(_0x2e87c3('0x6')),logger=require(_0x2e87c3('0x13'))(_0x2e87c3('0x20')),strategy=require(_0x2e87c3('0x21')),queue=schema({'name':{'type':_0x2e87c3('0xc'),'required':!![],'message':_0x2e87c3('0x1b')},'timeout':{'type':_0x2e87c3('0x24'),'message':'timeout\x20is\x20a\x20number'}});function writeLog(_0x198635,_0x477e20,_0x467400){const _0x178cf6=_0x2e87c3;return logger[_0x178cf6('0x12')](util[_0x178cf6('0x2')](_0x178cf6('0x5'),_0x198635,_0x477e20['name'],_0x467400));}function handleFindAgent(_0x4b0f64){return function(_0x2c700f){const _0x59c0db=a1200_0x52dc;return _0x2c700f[_0x59c0db('0x1a')][_0x59c0db('0x1e')]()===_0x4b0f64[_0x59c0db('0x1e')]();};}exports['consequence']=function(_0x1d5156,_0x510399,_0xa3743d,_0x37fce1){return function(_0x693404){const _0x5ea99a=a1200_0x52dc;try{const _0x350b58={'name':_0x510399[0x0],'timeout':_0x510399[0x1]},_0x8c0c40=queue['validate'](_0x350b58,{'typecast':!![]});if(_0x8c0c40[_0x5ea99a('0x8')])logger[_0x5ea99a('0x3')]('[%s][AGENT]\x20%s',_0x1d5156,_[_0x5ea99a('0x1d')](_0x8c0c40,'message')[_0x5ea99a('0x7')](',\x20')),_0x693404['stop']();else{const _0x35950c=_[_0x5ea99a('0x10')](_0xa3743d['agents'],handleFindAgent(_0x350b58['name']));if(_0x35950c){const _0x571bd0=(_0x350b58[_0x5ea99a('0x1c')]||0xa)*0x3e8;let _0x3593e2;const _0x1eaef6=seqqueue[_0x5ea99a('0xa')](_0x571bd0);_0x1eaef6['id']=_0x1d5156,_0x1eaef6[_0x5ea99a('0xb')]=_0x571bd0,_0x1eaef6[_0x5ea99a('0x9')]=_0x37fce1['channel'],writeLog(_0x1d5156,_0x35950c,util['format'](_0x5ea99a('0x17'),_0x571bd0)),_0xa3743d[_0x5ea99a('0xf')][_0x1d5156]['on'](_0x5ea99a('0x0'),function(){const _0x25ce8a=_0x5ea99a;logger[_0x25ce8a('0x12')](_0x25ce8a('0x22'),_0x1d5156),clearTimeout(_0x3593e2),_0x3593e2=undefined,_0x1eaef6[_0x25ce8a('0x14')](),_0xa3743d['rules'][_0x1d5156]&&delete _0xa3743d[_0x25ce8a('0xf')][_0x1d5156],_0x693404[_0x25ce8a('0x4')]();}),_0xa3743d[_0x5ea99a('0xf')][_0x1d5156]['on'](_0x5ea99a('0x16'),function(){const _0xea2d6c=_0x5ea99a;_0xa3743d[_0xea2d6c('0xf')][_0x1d5156]&&delete _0xa3743d[_0xea2d6c('0xf')][_0x1d5156];}),_0x3593e2=setTimeout(function(){const _0x4b4e08=_0x5ea99a;logger['info'](_0x4b4e08('0xe'),_0x1d5156),clearTimeout(_0x3593e2),_0x1eaef6['close'](),_0x693404[_0x4b4e08('0x1f')]();},_0x571bd0),strategy[_0x5ea99a('0x11')](_0x1eaef6,_0x35950c,_0xa3743d,_0x37fce1);}else logger[_0x5ea99a('0x3')](_0x5ea99a('0xd'),_0x1d5156,_0x350b58[_0x5ea99a('0x1a')]),_0x693404[_0x5ea99a('0x4')]();}}catch(_0xfaef72){console[_0x5ea99a('0x15')](_0xfaef72),logger[_0x5ea99a('0x3')](_0x5ea99a('0x18'),_0x1d5156,_0xfaef72[_0x5ea99a('0x19')]),_0x693404[_0x5ea99a('0x4')]();}};}; \ No newline at end of file +const a1200_0x6680=['consequence','message','rules','join','[%s][AGENT]\x20ROUTING\x20STOPPED','[%s][QUEUE]\x20%s','end','channel','agents','validate','next','stack','log','map','error','[%s][AGENT]\x20ROUTING\x20END','routing','atimeout','name\x20is\x20a\x20string\x20and\x20it\x20is\x20required','../../../../config/logger','stop','number','lodash','[%s][AGENT]\x20%s','util','timeout\x20is\x20a\x20number','name','toLowerCase','find','close','format'];(function(_0x1e28ac,_0x668046){const _0xb79d6=function(_0x514681){while(--_0x514681){_0x1e28ac['push'](_0x1e28ac['shift']());}};_0xb79d6(++_0x668046);}(a1200_0x6680,0x191));const a1200_0xb79d=function(_0x1e28ac,_0x668046){_0x1e28ac=_0x1e28ac-0x0;let _0xb79d6=a1200_0x6680[_0x1e28ac];return _0xb79d6;};const _0x1a7b9f=a1200_0xb79d;'use strict';const schema=require(_0x1a7b9f('0xb')),_=require(_0x1a7b9f('0x18')),util=require(_0x1a7b9f('0x1a')),seqqueue=require('seq-queue'),logger=require(_0x1a7b9f('0x15'))(_0x1a7b9f('0x12')),strategy=require('./strategy'),queue=schema({'name':{'type':'string','required':!![],'message':_0x1a7b9f('0x14')},'timeout':{'type':_0x1a7b9f('0x17'),'message':_0x1a7b9f('0x1b')}});function writeLog(_0x514681,_0x236512,_0x2298d4){const _0x1944e3=_0x1a7b9f;return logger['info'](util[_0x1944e3('0x1')]('[%s][AGENT][NAME:%s][STATUS:%s]',_0x514681,_0x236512[_0x1944e3('0x1c')],_0x2298d4));}function handleFindAgent(_0x325cef){return function(_0x2578c0){const _0x5bc76c=a1200_0xb79d;return _0x2578c0['name'][_0x5bc76c('0x1d')]()===_0x325cef[_0x5bc76c('0x1d')]();};}exports[_0x1a7b9f('0x2')]=function(_0x1d4c0f,_0x4cf42a,_0x50ab0d,_0xb08964){return function(_0x3787a2){const _0x52aadd=a1200_0xb79d;try{const _0x47c881={'name':_0x4cf42a[0x0],'timeout':_0x4cf42a[0x1]},_0x409afc=queue[_0x52aadd('0xb')](_0x47c881,{'typecast':!![]});if(_0x409afc['length'])logger[_0x52aadd('0x10')](_0x52aadd('0x19'),_0x1d4c0f,_[_0x52aadd('0xf')](_0x409afc,_0x52aadd('0x3'))[_0x52aadd('0x5')](',\x20')),_0x3787a2[_0x52aadd('0x16')]();else{const _0x14c904=_[_0x52aadd('0x1e')](_0x50ab0d[_0x52aadd('0xa')],handleFindAgent(_0x47c881[_0x52aadd('0x1c')]));if(_0x14c904){const _0x40f928=(_0x47c881['timeout']||0xa)*0x3e8;let _0x5af930;const _0x237550=seqqueue['createQueue'](_0x40f928);_0x237550['id']=_0x1d4c0f,_0x237550[_0x52aadd('0x13')]=_0x40f928,_0x237550[_0x52aadd('0x9')]=_0xb08964[_0x52aadd('0x9')],writeLog(_0x1d4c0f,_0x14c904,util[_0x52aadd('0x1')]('START:%s',_0x40f928)),_0x50ab0d[_0x52aadd('0x4')][_0x1d4c0f]['on'](_0x52aadd('0x8'),function(){const _0x1c65bd=_0x52aadd;logger['info'](_0x1c65bd('0x6'),_0x1d4c0f),clearTimeout(_0x5af930),_0x5af930=undefined,_0x237550[_0x1c65bd('0x0')](),_0x50ab0d['rules'][_0x1d4c0f]&&delete _0x50ab0d['rules'][_0x1d4c0f],_0x3787a2[_0x1c65bd('0x16')]();}),_0x50ab0d[_0x52aadd('0x4')][_0x1d4c0f]['on']('complete',function(){const _0x1c4bf4=_0x52aadd;_0x50ab0d['rules'][_0x1d4c0f]&&delete _0x50ab0d[_0x1c4bf4('0x4')][_0x1d4c0f];}),_0x5af930=setTimeout(function(){const _0x194a26=_0x52aadd;logger['info'](_0x194a26('0x11'),_0x1d4c0f),clearTimeout(_0x5af930),_0x237550[_0x194a26('0x0')](),_0x3787a2[_0x194a26('0xc')]();},_0x40f928),strategy['agent'](_0x237550,_0x14c904,_0x50ab0d,_0xb08964);}else logger['error']('[%s][AGENT]\x20agent\x20not\x20found\x20%s',_0x1d4c0f,_0x47c881[_0x52aadd('0x1c')]),_0x3787a2[_0x52aadd('0x16')]();}}catch(_0x4fc8e4){console[_0x52aadd('0xe')](_0x4fc8e4),logger[_0x52aadd('0x10')](_0x52aadd('0x7'),_0x1d4c0f,_0x4fc8e4[_0x52aadd('0xd')]),_0x3787a2[_0x52aadd('0x16')]();}};}; \ No newline at end of file diff --git a/server/services/routing/server/applications/amazonlex.js b/server/services/routing/server/applications/amazonlex.js index 0662f91..4a6fd99 100644 --- a/server/services/routing/server/applications/amazonlex.js +++ b/server/services/routing/server/applications/amazonlex.js @@ -1 +1 @@ -const a1201_0x1e4d=['./utils','amazonlex','chat','InteractionId','out','Failed','upperFirst','sms','isNil','message','error','providerName','Agent\x20is\x20managing\x20the\x20interaction.\x20Go\x20to\x20next\x20application.','../../rpc/mailMessage','finally','interaction','AccountId','getMustacheRender','moment','phone','LexRuntime','then','stop','contact','[%s][AMAZONLEX]\x20%s','stringify','[%s][AMAZONLEX]\x20Welcome\x20Message\x20is\x20empty.\x20It\x20will\x20wait\x20for\x20a\x20message\x20from\x20customer!','body','create','Message','[%s][AMAZONLEX]\x20Welcome\x20Message\x20has\x20been\x20sent!','$LATEST','ChatWebsiteId','whatsapp','../../rpc/whatsappMessage','aws-sdk','catch','info','../../rpc/faxMessage','channel','consequence','../../../../config/logger','UserId','lodash','../../rpc/openchannelMessage','postText','routing','next','dialogState'];(function(_0x2679c9,_0x1e4dca){const _0x2bfd86=function(_0x1ac364){while(--_0x1ac364){_0x2679c9['push'](_0x2679c9['shift']());}};_0x2bfd86(++_0x1e4dca);}(a1201_0x1e4d,0x199));const a1201_0x2bfd=function(_0x2679c9,_0x1e4dca){_0x2679c9=_0x2679c9-0x0;let _0x2bfd86=a1201_0x1e4d[_0x2679c9];return _0x2bfd86;};const _0x5e01ca=a1201_0x2bfd;'use strict';const _=require(_0x5e01ca('0x1a')),moment=require(_0x5e01ca('0x1')),AWS=require(_0x5e01ca('0x12')),utils=require(_0x5e01ca('0x20')),logger=require(_0x5e01ca('0x18'))(_0x5e01ca('0x1d')),rpc={'chatMessage':require('../../rpc/chatMessage'),'openchannelMessage':require(_0x5e01ca('0x1b')),'mailMessage':require(_0x5e01ca('0x2d')),'smsMessage':require('../../rpc/smsMessage'),'faxMessage':require(_0x5e01ca('0x15')),'whatsappMessage':require(_0x5e01ca('0x11'))};exports[_0x5e01ca('0x17')]=function(_0x1ac364,_0x2c5231){return function(_0x5604c0){const _0x159191=a1201_0x2bfd;try{if(!_[_0x159191('0x28')](this[_0x159191('0x2f')][_0x159191('0x19')]))return logger['info'](_0x159191('0x7'),_0x1ac364,_0x159191('0x2c')),_0x5604c0[_0x159191('0x1e')]();const _0x5e6405={'ContactId':this[_0x159191('0x6')]['id'],'sentAt':moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),'direction':_0x159191('0x24')};(this[_0x159191('0x16')]===_0x159191('0x27')||this[_0x159191('0x16')]===_0x159191('0x10'))&&(_0x5e6405['phone']=this['interaction'][_0x159191('0x2')]);const _0x2fd63b=this[_0x159191('0x16')];_0x2fd63b===_0x159191('0x22')?_0x5e6405[_0x159191('0xf')]=this['account']['id']:_0x5e6405[_[_0x159191('0x26')](_0x2fd63b)+_0x159191('0x30')]=this['account']['id'];_0x5e6405[_[_0x159191('0x26')](_0x2fd63b)+_0x159191('0x23')]=this[_0x159191('0x2f')]['id'];if(this[_0x159191('0x2f')]['created']){const _0x44e3da=_0x2c5231[0x4];if(!_['isEmpty'](_0x44e3da))return _0x5e6405[_0x159191('0xa')]=utils[_0x159191('0x0')](_0x44e3da,this),rpc[_0x2fd63b+_0x159191('0xc')]['create'](_0x5e6405)[_0x159191('0x4')](function(){const _0x247439=_0x159191;logger['info'](_0x247439('0x7'),_0x1ac364,_0x5e6405['body']);})[_0x159191('0x13')](function(_0xc4bfc1){const _0x22b094=_0x159191;logger[_0x22b094('0x2a')](_0x22b094('0x7'),_0x1ac364,JSON[_0x22b094('0x8')](_0xc4bfc1));})[_0x159191('0x2e')](function(){const _0x5c550c=_0x159191;logger[_0x5c550c('0x14')](_0x5c550c('0xd'),_0x1ac364),_0x5604c0[_0x5c550c('0x5')]();});else logger['info'](_0x159191('0x9'),_0x1ac364),_0x5604c0['stop']();}else{const _0x572892=this,_0x5825db=new AWS[(_0x159191('0x3'))]({'accessKeyId':_0x2c5231[0x0],'secretAccessKey':_0x2c5231[0x1],'region':_0x2c5231[0x2]}),_0x5e84ef={'botAlias':_0x159191('0xe'),'botName':_0x2c5231[0x3],'inputText':this[_0x159191('0x29')][_0x159191('0xa')],'userId':this[_0x159191('0x16')]+':'+this['interaction']['id']['toString']()};_0x5825db[_0x159191('0x1c')](_0x5e84ef,function(_0x360d5c,_0x2e5954){const _0x218335=_0x159191;if(_0x360d5c)logger[_0x218335('0x2a')](_0x218335('0x7'),_0x1ac364,_0x360d5c[_0x218335('0x29')]),_0x5604c0[_0x218335('0x1e')]();else{if(_0x2e5954&&_0x2e5954[_0x218335('0x29')])return _0x572892['body'][_0x218335('0x21')]=_0x2e5954,_0x5e6405[_0x218335('0xa')]=_0x2e5954[_0x218335('0x29')],_0x5e6405[_0x218335('0x2b')]=_0x218335('0x21'),_0x5e6405['providerResponse']=JSON[_0x218335('0x8')](_0x2e5954),rpc[_0x2fd63b+_0x218335('0xc')][_0x218335('0xb')](_0x5e6405)[_0x218335('0x4')](function(){const _0x4cad9c=_0x218335;logger[_0x4cad9c('0x14')]('[%s][AMAZONLEX]\x20%s',_0x1ac364,_0x5e6405['body']),_0x2e5954[_0x4cad9c('0x1f')]==_0x4cad9c('0x25')?_0x5604c0['next']():_0x5604c0[_0x4cad9c('0x5')]();})[_0x218335('0x13')](function(_0x3a57b0){const _0x43a311=_0x218335;logger[_0x43a311('0x2a')](_0x43a311('0x7'),_0x1ac364,JSON[_0x43a311('0x8')](_0x3a57b0)),_0x5604c0[_0x43a311('0x1e')]();});else _0x5604c0[_0x218335('0x1e')]();}});}}catch(_0x216521){logger[_0x159191('0x2a')]('[%s][AMAZONLEX]\x20%s',_0x1ac364,JSON['stringify'](_0x216521)),_0x5604c0['stop']();}};}; \ No newline at end of file +const a1201_0x33be=['InteractionId','../../rpc/mailMessage','LexRuntime','$LATEST','../../rpc/chatMessage','toString','phone','[%s][AMAZONLEX]\x20Welcome\x20Message\x20is\x20empty.\x20It\x20will\x20wait\x20for\x20a\x20message\x20from\x20customer!','catch','finally','error','body','channel','Failed','format','moment','getMustacheRender','[%s][AMAZONLEX]\x20Welcome\x20Message\x20has\x20been\x20sent!','create','account','[%s][AMAZONLEX]\x20%s','YYYY-MM-DD\x20HH:mm:ss','Agent\x20is\x20managing\x20the\x20interaction.\x20Go\x20to\x20next\x20application.','out','message','amazonlex','then','../../rpc/smsMessage','providerName','upperFirst','chat','Message','./utils','dialogState','consequence','interaction','stop','UserId','isEmpty','../../../../config/logger','providerResponse','next','info','stringify','../../rpc/openchannelMessage','postText'];(function(_0x1ccc9b,_0x33be3e){const _0x560f0=function(_0xa4650e){while(--_0xa4650e){_0x1ccc9b['push'](_0x1ccc9b['shift']());}};_0x560f0(++_0x33be3e);}(a1201_0x33be,0x1e5));const a1201_0x560f=function(_0x1ccc9b,_0x33be3e){_0x1ccc9b=_0x1ccc9b-0x0;let _0x560f0=a1201_0x33be[_0x1ccc9b];return _0x560f0;};const _0x517867=a1201_0x560f;'use strict';const _=require('lodash'),moment=require(_0x517867('0x24')),AWS=require('aws-sdk'),utils=require(_0x517867('0x7')),logger=require(_0x517867('0xe'))('routing'),rpc={'chatMessage':require(_0x517867('0x19')),'openchannelMessage':require(_0x517867('0x13')),'mailMessage':require(_0x517867('0x16')),'smsMessage':require(_0x517867('0x2')),'faxMessage':require('../../rpc/faxMessage'),'whatsappMessage':require('../../rpc/whatsappMessage')};exports[_0x517867('0x9')]=function(_0xa4650e,_0x101359){return function(_0x3afb53){const _0x26c0b1=a1201_0x560f;try{if(!_['isNil'](this['interaction'][_0x26c0b1('0xc')]))return logger[_0x26c0b1('0x11')]('[%s][AMAZONLEX]\x20%s',_0xa4650e,_0x26c0b1('0x2b')),_0x3afb53[_0x26c0b1('0x10')]();const _0x59de52={'ContactId':this['contact']['id'],'sentAt':moment()[_0x26c0b1('0x23')](_0x26c0b1('0x2a')),'direction':_0x26c0b1('0x2c')};(this['channel']==='sms'||this['channel']==='whatsapp')&&(_0x59de52[_0x26c0b1('0x1b')]=this[_0x26c0b1('0xa')][_0x26c0b1('0x1b')]);const _0x28c132=this[_0x26c0b1('0x21')];_0x28c132===_0x26c0b1('0x5')?_0x59de52['ChatWebsiteId']=this[_0x26c0b1('0x28')]['id']:_0x59de52[_[_0x26c0b1('0x4')](_0x28c132)+'AccountId']=this[_0x26c0b1('0x28')]['id'];_0x59de52[_[_0x26c0b1('0x4')](_0x28c132)+_0x26c0b1('0x15')]=this[_0x26c0b1('0xa')]['id'];if(this[_0x26c0b1('0xa')]['created']){const _0x1e6aae=_0x101359[0x4];if(!_[_0x26c0b1('0xd')](_0x1e6aae))return _0x59de52[_0x26c0b1('0x20')]=utils[_0x26c0b1('0x25')](_0x1e6aae,this),rpc[_0x28c132+_0x26c0b1('0x6')][_0x26c0b1('0x27')](_0x59de52)[_0x26c0b1('0x1')](function(){const _0x2bc0f3=_0x26c0b1;logger['info']('[%s][AMAZONLEX]\x20%s',_0xa4650e,_0x59de52[_0x2bc0f3('0x20')]);})[_0x26c0b1('0x1d')](function(_0x2e8bae){const _0x19dd3e=_0x26c0b1;logger['error'](_0x19dd3e('0x29'),_0xa4650e,JSON[_0x19dd3e('0x12')](_0x2e8bae));})[_0x26c0b1('0x1e')](function(){const _0x4d2178=_0x26c0b1;logger[_0x4d2178('0x11')](_0x4d2178('0x26'),_0xa4650e),_0x3afb53['stop']();});else logger['info'](_0x26c0b1('0x1c'),_0xa4650e),_0x3afb53['stop']();}else{const _0x10cbf9=this,_0x32bfe7=new AWS[(_0x26c0b1('0x17'))]({'accessKeyId':_0x101359[0x0],'secretAccessKey':_0x101359[0x1],'region':_0x101359[0x2]}),_0x424b55={'botAlias':_0x26c0b1('0x18'),'botName':_0x101359[0x3],'inputText':this[_0x26c0b1('0x2d')]['body'],'userId':this['channel']+':'+this[_0x26c0b1('0xa')]['id'][_0x26c0b1('0x1a')]()};_0x32bfe7[_0x26c0b1('0x14')](_0x424b55,function(_0x529072,_0x5e4b88){const _0x1d2f7f=_0x26c0b1;if(_0x529072)logger[_0x1d2f7f('0x1f')](_0x1d2f7f('0x29'),_0xa4650e,_0x529072[_0x1d2f7f('0x2d')]),_0x3afb53['next']();else{if(_0x5e4b88&&_0x5e4b88[_0x1d2f7f('0x2d')])return _0x10cbf9[_0x1d2f7f('0x20')][_0x1d2f7f('0x0')]=_0x5e4b88,_0x59de52[_0x1d2f7f('0x20')]=_0x5e4b88[_0x1d2f7f('0x2d')],_0x59de52[_0x1d2f7f('0x3')]=_0x1d2f7f('0x0'),_0x59de52[_0x1d2f7f('0xf')]=JSON[_0x1d2f7f('0x12')](_0x5e4b88),rpc[_0x28c132+'Message'][_0x1d2f7f('0x27')](_0x59de52)[_0x1d2f7f('0x1')](function(){const _0x527929=_0x1d2f7f;logger['info'](_0x527929('0x29'),_0xa4650e,_0x59de52[_0x527929('0x20')]),_0x5e4b88[_0x527929('0x8')]==_0x527929('0x22')?_0x3afb53[_0x527929('0x10')]():_0x3afb53['stop']();})[_0x1d2f7f('0x1d')](function(_0x5eb39f){const _0x1e48ac=_0x1d2f7f;logger[_0x1e48ac('0x1f')](_0x1e48ac('0x29'),_0xa4650e,JSON[_0x1e48ac('0x12')](_0x5eb39f)),_0x3afb53['next']();});else _0x3afb53['next']();}});}}catch(_0x47df16){logger[_0x26c0b1('0x1f')]('[%s][AMAZONLEX]\x20%s',_0xa4650e,JSON[_0x26c0b1('0x12')](_0x47df16)),_0x3afb53[_0x26c0b1('0xb')]();}};}; \ No newline at end of file diff --git a/server/services/routing/server/applications/autoreply.js b/server/services/routing/server/applications/autoreply.js index 6ceba6f..a1d6a37 100644 --- a/server/services/routing/server/applications/autoreply.js +++ b/server/services/routing/server/applications/autoreply.js @@ -1 +1 @@ -const a1202_0x45df=['port','./utils','Smtp','stop','secure','../../rpc/openchannelMessage','pass','auth','InteractionId','out','service','replace','authentication','phone','isNil','error','','Re:\x20','getMustacheRender','../../rpc/mailMessage','body','stringify','',mailRpc[_0x3bf491('0x25')](_0xf76f02,_0x1b94d9)[_0x3bf491('0x26')](function(_0x2e246d){const _0x23657e=_0x3bf491;return logger[_0x23657e('0x7')](_0x23657e('0x8'),_0x48a084),_0x1b94d9['messageId']=_0x2e246d['message'][_0x23657e('0x33')],rpc[_0x482bc3+_0x23657e('0x28')][_0x23657e('0x3')](_0x1b94d9);})['then'](function(_0x41b888){const _0x35aea1=_0x3bf491;logger[_0x35aea1('0x7')](_0x35aea1('0x38'),_0x48a084,JSON[_0x35aea1('0x22')](_0x41b888));})[_0x3bf491('0x31')](function(_0x25c5b7){const _0x28f8a6=_0x3bf491;logger[_0x28f8a6('0x1c')](_0x28f8a6('0x0'),_0x48a084,JSON[_0x28f8a6('0x22')](_0x25c5b7));})[_0x3bf491('0x1')](function(){const _0x52193d=_0x3bf491;_0x12ab22[_0x52193d('0x30')]();});}else return rpc[this['channel']+'Message'][_0x3bf491('0x3')](_0x1b94d9)['then'](function(){const _0x23fa7e=_0x3bf491;logger[_0x23fa7e('0x7')](_0x23fa7e('0x38'),_0x48a084,_0x1b94d9[_0x23fa7e('0x21')]);})[_0x3bf491('0x31')](function(_0x18b5f4){const _0xfa8f77=_0x3bf491;logger[_0xfa8f77('0x1c')](_0xfa8f77('0x38'),_0x48a084,JSON[_0xfa8f77('0x22')](_0x18b5f4));})[_0x3bf491('0x1')](function(){_0x12ab22['next']();});}}catch(_0x16585f){logger[_0x3bf491('0x1c')](_0x3bf491('0x38'),_0x48a084,JSON['stringify'](_0x16585f)),_0x12ab22[_0x3bf491('0x10')]();}};}; \ No newline at end of file +const a1202_0xc9aa=['../../rpc/smsMessage','../../rpc/openchannelMessage','getMustacheRender','message','','then','contact','../../rpc/whatsappMessage','read','Smtp','Autoreply\x20already\x20sent','messageId','service','[RPC][%s][AUTOREPLY]\x20%s','finally','routing','created','host','next','consequence','subject','../../rpc/mailMessage','interaction','catch','phone','Message','lodash','stringify','html','../../rpc/faxMessage','Re:\x20','../../../../config/logger','YYYY-MM-DD\x20HH:mm:ss','[%s][AUTOREPLY]\x20SMTP\x20SENT','error','../../mailRpc','info','secure','channel','body','format','user','create',''];(function(_0x193052,_0xc9aa78){const _0x5b2ad9=function(_0x23a9b6){while(--_0x23a9b6){_0x193052['push'](_0x193052['shift']());}};_0x5b2ad9(++_0xc9aa78);}(a1202_0xc9aa,0x1a2));const a1202_0x5b2a=function(_0x193052,_0xc9aa78){_0x193052=_0x193052-0x0;let _0x5b2ad9=a1202_0xc9aa[_0x193052];return _0x5b2ad9;};const _0xc8e24a=a1202_0x5b2a;'use strict';const _=require(_0xc8e24a('0x18')),moment=require('moment'),utils=require('./utils'),logger=require(_0xc8e24a('0x1d'))(_0xc8e24a('0xd')),rpc={'chatMessage':require('../../rpc/chatMessage'),'openchannelMessage':require(_0xc8e24a('0x33')),'mailMessage':require(_0xc8e24a('0x13')),'smsMessage':require(_0xc8e24a('0x32')),'faxMessage':require(_0xc8e24a('0x1b')),'whatsappMessage':require(_0xc8e24a('0x5'))},mailRpc=require(_0xc8e24a('0x21'));exports[_0xc8e24a('0x11')]=function(_0x23a9b6,_0x5a4a5d){return function(_0x75cc1a){const _0x2e8cb3=a1202_0x5b2a;try{if(_0x5a4a5d[0x0]==='1'&&(_['isNil'](this['interaction'][_0x2e8cb3('0xe')])||!this[_0x2e8cb3('0x14')]['created']))return logger[_0x2e8cb3('0x22')](_0x2e8cb3('0x2b'),_0x23a9b6,_0x2e8cb3('0x8')),_0x75cc1a[_0x2e8cb3('0x10')]();const _0x1eef5c=this[_0x2e8cb3('0x24')],_0x2a5ef6={'body':utils[_0x2e8cb3('0x0')](_0x5a4a5d[0x1],this),'ContactId':this[_0x2e8cb3('0x4')]['id'],'sentAt':moment()[_0x2e8cb3('0x26')](_0x2e8cb3('0x1e')),'direction':'out'};this[_0x2e8cb3('0x1')]&&(_0x2a5ef6['to']=this[_0x2e8cb3('0x1')]['from']||'',_0x2a5ef6['cc']=this[_0x2e8cb3('0x1')]['cc']||'',_0x2a5ef6[_0x2e8cb3('0x2a')]=this['message']['to']||'',_0x2a5ef6[_0x2e8cb3('0x16')]=this[_0x2e8cb3('0x1')][_0x2e8cb3('0x16')]||'',_0x2a5ef6[_0x2e8cb3('0x6')]=!![],this[_0x2e8cb3('0x1')][_0x2e8cb3('0x12')]&&(_0x2a5ef6[_0x2e8cb3('0x12')]='',_0x2a5ef6['subject']+=_['startsWith'](this['message']['subject'],_0x2e8cb3('0x2d'))?'':_0x2e8cb3('0x1c'),_0x2a5ef6[_0x2e8cb3('0x12')]+=this[_0x2e8cb3('0x1')][_0x2e8cb3('0x12')]));this[_0x2e8cb3('0x24')]==='chat'?_0x2a5ef6['ChatWebsiteId']=this[_0x2e8cb3('0x2c')]['id']:_0x2a5ef6[_['upperFirst'](this['channel'])+'AccountId']=this[_0x2e8cb3('0x2c')]['id'];_0x2a5ef6[_[_0x2e8cb3('0x30')](this[_0x2e8cb3('0x24')])+'InteractionId']=this[_0x2e8cb3('0x14')]['id'];if(rpc[this[_0x2e8cb3('0x24')]+'Message']){if(this[_0x2e8cb3('0x24')]==='mail'){const _0x3d04cf={'tls':{'rejectUnauthorized':![]}};return this['account'][_0x2e8cb3('0x7')][_0x2e8cb3('0xa')]?_0x3d04cf[_0x2e8cb3('0xa')]=this[_0x2e8cb3('0x2c')]['Smtp'][_0x2e8cb3('0xa')]:(_0x3d04cf['host']=this[_0x2e8cb3('0x2c')][_0x2e8cb3('0x7')][_0x2e8cb3('0xf')],_0x3d04cf[_0x2e8cb3('0x2f')]=this[_0x2e8cb3('0x2c')]['Smtp'][_0x2e8cb3('0x2f')],_0x3d04cf[_0x2e8cb3('0x23')]=this[_0x2e8cb3('0x2c')][_0x2e8cb3('0x7')][_0x2e8cb3('0x23')]),this[_0x2e8cb3('0x2c')][_0x2e8cb3('0x7')]['authentication']&&(_0x3d04cf['auth']={'user':this[_0x2e8cb3('0x2c')][_0x2e8cb3('0x7')][_0x2e8cb3('0x27')],'pass':this[_0x2e8cb3('0x2c')][_0x2e8cb3('0x7')][_0x2e8cb3('0x2e')]}),_0x2a5ef6['inReplyTo']=this['message'][_0x2e8cb3('0x9')],_0x2a5ef6[_0x2e8cb3('0x1a')]=_0x2e8cb3('0x31')+_['replace'](_0x2a5ef6[_0x2e8cb3('0x25')],_0x2e8cb3('0x29'),'{const _0x3ec35b=_0x2ddf5a,_0x402a95=_0x2fd702&&_0x2fd702[_0x3ec35b('0x10')]&&_0x2fd702[_0x3ec35b('0x10')][_0x3ec35b('0x22')];return _0x402a95?createMessage(_0x490958,_0x3facfe,_0x9de39c,_0x2fd702[_0x3ec35b('0x10')][_0x3ec35b('0x22')]):null;})[_0x2ddf5a('0x15')](_0x4be8f2=>_0x4be8f2!==null);await Promise['all'](_0x37bc7e),_0xf712c2?_0x33c362[_0x2ddf5a('0x2b')]():_0x33c362['stop']();}}catch(_0x2221c6){logger['error']('[%s][DIALOGFLOWV2]\x20%s',_0x490958,_0x2221c6[_0x2ddf5a('0x1b')]),_0x33c362['next']();}}}catch(_0x1d3e86){logger['error'](_0x2ddf5a('0x1e'),_0x490958,JSON[_0x2ddf5a('0x2d')](_0x1d3e86)),_0x33c362[_0x2ddf5a('0xb')]();}}return _0x4a7c77;}module['exports']={'consequence':consequence}; \ No newline at end of file +const a1205_0x46bf=['allRequiredParamsPresent','contact','upperFirst','../../rpc/whatsappMessage','dialogflowV2','queryResult','Message','isNil','fulfillmentText','intentDetectionConfidence','action','Agent\x20is\x20managing\x20the\x20interaction.\x20Go\x20to\x20next\x20application.','queryText','detectIntent','intent','./utils','end_conversation','format','../../rpc/openchannelMessage','stop','fields','error','InteractionId','md5','SessionsClient','AccountId','boolValue','message','../../rpc/faxMessage','languageCode','../../rpc/chatMessage','diagnosticInfo','all','[%s][DIALOGFLOWV2]\x20Welcome\x20Message\x20is\x20empty.\x20It\x20will\x20wait\x20for\x20a\x20message\x20from\x20customer!','[%s][DIALOGFLOWV2]\x20Welcome\x20Message\x20has\x20been\x20sent!','clone','exports','chat','phone','info','channel','length','out','lodash','filter','UserId','created','displayName','stringify','YYYY-MM-DD\x20HH:mm:ss','sms','name','projectAgentSessionPath','[%s][DIALOGFLOWV2]\x20%s','whatsapp','replace','interaction','body','next'];(function(_0x4cda5d,_0x46bf81){const _0x597c88=function(_0x5b323b){while(--_0x5b323b){_0x4cda5d['push'](_0x4cda5d['shift']());}};_0x597c88(++_0x46bf81);}(a1205_0x46bf,0xb6));const a1205_0x597c=function(_0x4cda5d,_0x46bf81){_0x4cda5d=_0x4cda5d-0x0;let _0x597c88=a1205_0x46bf[_0x4cda5d];return _0x597c88;};const _0x264cb4=a1205_0x597c;'use strict';const _=require(_0x264cb4('0x26')),dialogflow=require('@google-cloud/dialogflow'),md5=require(_0x264cb4('0x12')),moment=require('moment'),logger=require('../../../../config/logger')('routing'),utils=require(_0x264cb4('0xa')),rpc={'chatMessage':require(_0x264cb4('0x19')),'openchannelMessage':require(_0x264cb4('0xd')),'mailMessage':require('../../rpc/mailMessage'),'smsMessage':require('../../rpc/smsMessage'),'faxMessage':require(_0x264cb4('0x17')),'whatsappMessage':require(_0x264cb4('0x39'))};async function createMessage(_0x5b323b,_0x48115a,_0x3822b8,_0x31cae5){const _0x1585b9=_0x264cb4,_0x19bf1f=_[_0x1585b9('0x1e')](_0x3822b8);_0x19bf1f[_0x1585b9('0x34')]=_0x31cae5;try{const _0x17aeb4=await rpc[_0x48115a+_0x1585b9('0x1')]['create'](_0x19bf1f);return logger['info'](_0x1585b9('0x30'),_0x5b323b,_0x17aeb4[_0x1585b9('0x34')]),_0x17aeb4;}catch(_0x151c90){logger[_0x1585b9('0x10')]('[%s][DIALOGFLOWV2]\x20%s',_0x5b323b,JSON[_0x1585b9('0x2b')](_0x151c90));throw _0x151c90;}}function consequence(_0xbe59c3,_0x4e5fa1){async function _0x15a736(_0x6cb2d5){const _0x311b93=a1205_0x597c;try{if(!_[_0x311b93('0x2')](this[_0x311b93('0x33')][_0x311b93('0x28')]))return logger['info']('[%s][DIALOGFLOWV2]\x20%s',_0xbe59c3,_0x311b93('0x6')),_0x6cb2d5['next']();let _0x2f21df={'ContactId':this[_0x311b93('0x37')]['id'],'sentAt':moment()[_0x311b93('0xc')](_0x311b93('0x2c')),'direction':_0x311b93('0x25')};(this[_0x311b93('0x23')]===_0x311b93('0x2d')||this[_0x311b93('0x23')]===_0x311b93('0x31'))&&(_0x2f21df['phone']=this[_0x311b93('0x33')][_0x311b93('0x21')]);const _0x25198b=this['channel'];_0x25198b===_0x311b93('0x20')?_0x2f21df['ChatWebsiteId']=this['account']['id']:_0x2f21df[_[_0x311b93('0x38')](_0x25198b)+_0x311b93('0x14')]=this['account']['id'];_0x2f21df[_[_0x311b93('0x38')](_0x25198b)+_0x311b93('0x11')]=this[_0x311b93('0x33')]['id'];if(this[_0x311b93('0x33')][_0x311b93('0x29')]){const _0x823516=_0x4e5fa1[0x4];if(!_['isEmpty'](_0x823516))try{_0x2f21df[_0x311b93('0x34')]=utils['getMustacheRender'](_0x823516,this),_0x2f21df=await rpc[_0x25198b+_0x311b93('0x1')]['create'](_0x2f21df),logger['info'](_0x311b93('0x30'),_0xbe59c3,_0x2f21df[_0x311b93('0x34')]);}catch(_0x144290){logger['error'](_0x311b93('0x30'),_0xbe59c3,JSON[_0x311b93('0x2b')](_0x144290));}finally{logger[_0x311b93('0x22')](_0x311b93('0x1d'),_0xbe59c3),_0x6cb2d5[_0x311b93('0xe')]();}else logger['info'](_0x311b93('0x1c'),_0xbe59c3),_0x6cb2d5['stop']();}else{const _0x2a4086=_0x4e5fa1[0x2][_0x311b93('0x32')](/\\n/g,'\x0a'),_0x5891f7={'credentials':{'private_key':_0x2a4086,'client_email':_0x4e5fa1[0x1]}},_0x53fb63=new dialogflow[(_0x311b93('0x13'))](_0x5891f7),_0x564c53=_0x53fb63[_0x311b93('0x2f')](_0x4e5fa1[0x0],md5(this[_0x311b93('0x33')]['id'])),_0x2ff452={'session':_0x564c53,'queryInput':{'text':{'text':this[_0x311b93('0x16')][_0x311b93('0x34')],'languageCode':_0x4e5fa1[0x3]||'en'}}};try{const _0x40a0d3=await _0x53fb63[_0x311b93('0x8')](_0x2ff452);if(_0x40a0d3&&_0x40a0d3[_0x311b93('0x24')]){this[_0x311b93('0x34')][_0x311b93('0x3a')]=_0x40a0d3;const _0x5d7f87=_0x40a0d3[0x0],_0x18dcf1=_0x5d7f87[_0x311b93('0x0')][_0x311b93('0x1a')]&&_0x5d7f87[_0x311b93('0x0')]['diagnosticInfo'][_0x311b93('0xf')]?_0x5d7f87[_0x311b93('0x0')][_0x311b93('0x1a')][_0x311b93('0xf')][_0x311b93('0xb')][_0x311b93('0x15')]:![];this[_0x311b93('0x34')]={...this[_0x311b93('0x34')],'DIALOGFLOWV2_ACTION':_0x5d7f87['queryResult'][_0x311b93('0x5')],'DIALOGFLOWV2_ALLREQUIREDPARAMSPRESENT':_0x5d7f87[_0x311b93('0x0')][_0x311b93('0x36')],'DIALOGFLOWV2_ENDCONVERSATION':_0x5d7f87['queryResult'][_0x311b93('0x1a')]&&_0x5d7f87['queryResult'][_0x311b93('0x1a')][_0x311b93('0xf')]?_0x5d7f87[_0x311b93('0x0')][_0x311b93('0x1a')][_0x311b93('0xf')][_0x311b93('0xb')][_0x311b93('0x15')]:![],'DIALOGFLOWV2_INTENTNAME':_0x5d7f87['queryResult'][_0x311b93('0x9')][_0x311b93('0x2e')],'DIALOGFLOWV2_INTENTDISPLAYNAME':_0x5d7f87[_0x311b93('0x0')]['intent'][_0x311b93('0x2a')],'DIALOGFLOWV2_LANGUAGECODE':_0x5d7f87[_0x311b93('0x0')][_0x311b93('0x18')],'DIALOGFLOWV2_QUERYTEXT':_0x5d7f87[_0x311b93('0x0')][_0x311b93('0x7')],'DIALOGFLOWV2_SCORE':_0x5d7f87[_0x311b93('0x0')][_0x311b93('0x4')]},_0x2f21df['providerName']='dialogflowV2',_0x2f21df['providerResponse']=JSON[_0x311b93('0x2b')](_0x40a0d3);const _0x5e32d2=_0x40a0d3['map'](_0x1c3d22=>{const _0xa9b4f8=_0x311b93,_0x1f2c48=_0x1c3d22&&_0x1c3d22[_0xa9b4f8('0x0')]&&_0x1c3d22[_0xa9b4f8('0x0')][_0xa9b4f8('0x3')];return _0x1f2c48?createMessage(_0xbe59c3,_0x25198b,_0x2f21df,_0x1c3d22[_0xa9b4f8('0x0')]['fulfillmentText']):null;})[_0x311b93('0x27')](_0x4b4f89=>_0x4b4f89!==null);await Promise[_0x311b93('0x1b')](_0x5e32d2),_0x18dcf1?_0x6cb2d5[_0x311b93('0x35')]():_0x6cb2d5[_0x311b93('0xe')]();}}catch(_0x5c4a44){logger[_0x311b93('0x10')]('[%s][DIALOGFLOWV2]\x20%s',_0xbe59c3,_0x5c4a44[_0x311b93('0x16')]),_0x6cb2d5[_0x311b93('0x35')]();}}}catch(_0x2edd11){logger[_0x311b93('0x10')]('[%s][DIALOGFLOWV2]\x20%s',_0xbe59c3,JSON['stringify'](_0x2edd11)),_0x6cb2d5[_0x311b93('0xe')]();}}return _0x15a736;}module[_0x264cb4('0x1f')]={'consequence':consequence}; \ No newline at end of file diff --git a/server/services/routing/server/applications/gotoif.js b/server/services/routing/server/applications/gotoif.js index 60bf8c9..0cf5b56 100644 --- a/server/services/routing/server/applications/gotoif.js +++ b/server/services/routing/server/applications/gotoif.js @@ -1 +1 @@ -const a1206_0x5307=['next','replace','length','lodash','join','number','../../../../config/logger','stringify','priorityFalse','info','priorityTrue','validate','priority\x20false\x20is\x20a\x20number','priority\x20true\x20is\x20a\x20number','condition','html-to-text','findIndex','[%s][GOTOIF]\x20priority\x20%s\x20not\x20found','condition\x20is\x20a\x20string\x20and\x20it\x20is\x20required','stop','getMustacheRender','./utils','map','[%s][GOTOIF]\x20priority\x20%s\x20found\x20at\x20index:\x20%s','error','routing','message'];(function(_0x1ecf9a,_0x530742){const _0x618f8f=function(_0x2ba80e){while(--_0x2ba80e){_0x1ecf9a['push'](_0x1ecf9a['shift']());}};_0x618f8f(++_0x530742);}(a1206_0x5307,0xcc));const a1206_0x618f=function(_0x1ecf9a,_0x530742){_0x1ecf9a=_0x1ecf9a-0x0;let _0x618f8f=a1206_0x5307[_0x1ecf9a];return _0x618f8f;};const _0x3eade9=a1206_0x618f;'use strict';const schema=require(_0x3eade9('0x17')),_=require(_0x3eade9('0xf')),{htmlToText}=require(_0x3eade9('0x0')),utils=require(_0x3eade9('0x6')),logger=require(_0x3eade9('0x12'))(_0x3eade9('0xa')),gotoif=schema({'condition':{'type':'string','required':!![],'message':_0x3eade9('0x3')},'priorityTrue':{'type':_0x3eade9('0x11'),'message':_0x3eade9('0x19')},'priorityFalse':{'type':'number','message':_0x3eade9('0x18')}});exports['consequence']=function(_0x2ba80e,_0x2f98f5){return function(_0x4c52ce){const _0x227ce7=a1206_0x618f;try{const _0x27249f={'condition':htmlToText(utils[_0x227ce7('0x5')](_0x2f98f5[0x0],this),{'wordwrap':![]})[_0x227ce7('0xd')](/<\/?[^>]+(>|$)/g,''),'priorityTrue':_0x2f98f5[0x1],'priorityFalse':_0x2f98f5[0x2]},_0x38beca=gotoif[_0x227ce7('0x17')](_0x27249f,{'typecast':!![]});if(_0x38beca[_0x227ce7('0xe')])logger[_0x227ce7('0x9')]('[%s][GOTOIF]\x20%s',_0x2ba80e,_[_0x227ce7('0x7')](_0x38beca,_0x227ce7('0xb'))[_0x227ce7('0x10')](',\x20')),_0x4c52ce[_0x227ce7('0x4')]();else try{const _0x7dd357=eval('('+_0x27249f[_0x227ce7('0x1a')]+')'),_0x3ee21a=_0x7dd357?_0x27249f[_0x227ce7('0x16')]:_0x27249f[_0x227ce7('0x14')];logger[_0x227ce7('0x15')]('[%s][GOTOIF]\x20condition\x20%s\x20is\x20%s\x20try\x20goto\x20priority\x20%s',_0x2ba80e,_0x27249f[_0x227ce7('0x1a')],_0x7dd357,_0x3ee21a||_0x227ce7('0xc'));if(_0x3ee21a){const _0x4abca6=_[_0x227ce7('0x1')](_0x4c52ce['rules'](),{'p':_0x3ee21a});_0x4abca6>=0x0?(logger[_0x227ce7('0x15')](_0x227ce7('0x8'),_0x2ba80e,_0x3ee21a||_0x227ce7('0xc'),_0x4abca6),_0x4c52ce[_0x227ce7('0xc')](_0x4abca6)):(logger[_0x227ce7('0x15')](_0x227ce7('0x2'),_0x2ba80e,_0x3ee21a||_0x227ce7('0xc')),_0x4c52ce[_0x227ce7('0x4')]());}else _0x4c52ce[_0x227ce7('0xc')]();}catch(_0x1b2f84){logger[_0x227ce7('0x9')]('[%s][GOTOIF]\x20eval\x20error:\x20%s',_0x2ba80e,_0x1b2f84[_0x227ce7('0xb')]),_0x4c52ce[_0x227ce7('0x4')]();}}catch(_0x3d64bc){logger['error']('[%s][GOTOIF]\x20%s',_0x2ba80e,JSON[_0x227ce7('0x13')](_0x3d64bc)),_0x4c52ce[_0x227ce7('0x4')]();}};}; \ No newline at end of file +const a1206_0x49ca=['replace','priority\x20true\x20is\x20a\x20number','length','error','priority\x20false\x20is\x20a\x20number','html-to-text','map','stop','lodash','condition','./utils','[%s][GOTOIF]\x20priority\x20%s\x20found\x20at\x20index:\x20%s','info','[%s][GOTOIF]\x20priority\x20%s\x20not\x20found','priorityFalse','routing','findIndex','[%s][GOTOIF]\x20condition\x20%s\x20is\x20%s\x20try\x20goto\x20priority\x20%s','next','validate','join','number','priorityTrue','[%s][GOTOIF]\x20%s','rules','getMustacheRender','message','consequence'];(function(_0x35ca61,_0x49cac2){const _0x5ed125=function(_0x105750){while(--_0x105750){_0x35ca61['push'](_0x35ca61['shift']());}};_0x5ed125(++_0x49cac2);}(a1206_0x49ca,0x166));const a1206_0x5ed1=function(_0x35ca61,_0x49cac2){_0x35ca61=_0x35ca61-0x0;let _0x5ed125=a1206_0x49ca[_0x35ca61];return _0x5ed125;};const _0x506113=a1206_0x5ed1;'use strict';const schema=require('validate'),_=require(_0x506113('0xe')),{htmlToText}=require(_0x506113('0xb')),utils=require(_0x506113('0x10')),logger=require('../../../../config/logger')(_0x506113('0x15')),gotoif=schema({'condition':{'type':'string','required':!![],'message':'condition\x20is\x20a\x20string\x20and\x20it\x20is\x20required'},'priorityTrue':{'type':_0x506113('0x1b'),'message':_0x506113('0x7')},'priorityFalse':{'type':_0x506113('0x1b'),'message':_0x506113('0xa')}});exports[_0x506113('0x5')]=function(_0x105750,_0x14c3a9){return function(_0x42cda3){const _0x42e374=a1206_0x5ed1;try{const _0xcf3013={'condition':htmlToText(utils[_0x42e374('0x3')](_0x14c3a9[0x0],this),{'wordwrap':![]})[_0x42e374('0x6')](/<\/?[^>]+(>|$)/g,''),'priorityTrue':_0x14c3a9[0x1],'priorityFalse':_0x14c3a9[0x2]},_0x534591=gotoif[_0x42e374('0x19')](_0xcf3013,{'typecast':!![]});if(_0x534591[_0x42e374('0x8')])logger[_0x42e374('0x9')](_0x42e374('0x1'),_0x105750,_[_0x42e374('0xc')](_0x534591,_0x42e374('0x4'))[_0x42e374('0x1a')](',\x20')),_0x42cda3[_0x42e374('0xd')]();else try{const _0x53a389=eval('('+_0xcf3013[_0x42e374('0xf')]+')'),_0x4218ad=_0x53a389?_0xcf3013[_0x42e374('0x0')]:_0xcf3013[_0x42e374('0x14')];logger[_0x42e374('0x12')](_0x42e374('0x17'),_0x105750,_0xcf3013[_0x42e374('0xf')],_0x53a389,_0x4218ad||'next');if(_0x4218ad){const _0x113a54=_[_0x42e374('0x16')](_0x42cda3[_0x42e374('0x2')](),{'p':_0x4218ad});_0x113a54>=0x0?(logger[_0x42e374('0x12')](_0x42e374('0x11'),_0x105750,_0x4218ad||_0x42e374('0x18'),_0x113a54),_0x42cda3[_0x42e374('0x18')](_0x113a54)):(logger['info'](_0x42e374('0x13'),_0x105750,_0x4218ad||_0x42e374('0x18')),_0x42cda3[_0x42e374('0xd')]());}else _0x42cda3[_0x42e374('0x18')]();}catch(_0x1b0014){logger[_0x42e374('0x9')]('[%s][GOTOIF]\x20eval\x20error:\x20%s',_0x105750,_0x1b0014[_0x42e374('0x4')]),_0x42cda3[_0x42e374('0xd')]();}}catch(_0x220a1d){logger[_0x42e374('0x9')](_0x42e374('0x1'),_0x105750,JSON['stringify'](_0x220a1d)),_0x42cda3[_0x42e374('0xd')]();}};}; \ No newline at end of file diff --git a/server/services/routing/server/applications/gotop.js b/server/services/routing/server/applications/gotop.js index 22315a7..e906743 100644 --- a/server/services/routing/server/applications/gotop.js +++ b/server/services/routing/server/applications/gotop.js @@ -1 +1 @@ -const a1207_0x57a6=['validate','stringify','consequence','map','stop','join','findIndex','message','[%s][GOTOP]\x20%s','error','[%s][GOTOP]\x20priority\x20%s\x20found\x20at\x20index:\x20%s','info','[%s][GOTOP]\x20priority\x20%s','next','priority','lodash','[%s][GOTOP]\x20priority\x20%s\x20not\x20found'];(function(_0x4b6cfc,_0x57a6af){const _0x49f6af=function(_0x2d9286){while(--_0x2d9286){_0x4b6cfc['push'](_0x4b6cfc['shift']());}};_0x49f6af(++_0x57a6af);}(a1207_0x57a6,0xed));const a1207_0x49f6=function(_0x4b6cfc,_0x57a6af){_0x4b6cfc=_0x4b6cfc-0x0;let _0x49f6af=a1207_0x57a6[_0x4b6cfc];return _0x49f6af;};const _0x123945=a1207_0x49f6;'use strict';const schema=require('validate'),_=require(_0x123945('0x10')),logger=require('../../../../config/logger')('routing'),gotop=schema({'priority':{'type':'number','required':!![],'message':'priority\x20is\x20a\x20number\x20and\x20it\x20is\x20required'}});exports[_0x123945('0x3')]=function(_0x2d9286,_0x4fbd44){return function(_0x319bc6){const _0x1a675a=a1207_0x49f6;try{const _0x4b8338={'priority':_0x4fbd44[0x0]},_0x37eeae=gotop[_0x1a675a('0x1')](_0x4b8338,{'typecast':!![]});if(_0x37eeae['length'])logger[_0x1a675a('0xa')](_0x1a675a('0x9'),_0x2d9286,_[_0x1a675a('0x4')](_0x37eeae,_0x1a675a('0x8'))[_0x1a675a('0x6')](',\x20')),_0x319bc6[_0x1a675a('0x5')]();else{logger[_0x1a675a('0xc')](_0x1a675a('0xd'),_0x2d9286,_0x4b8338[_0x1a675a('0xf')]);if(_0x4b8338['priority']){const _0x47b05c=_[_0x1a675a('0x7')](_0x319bc6['rules'](),{'p':_0x4b8338[_0x1a675a('0xf')]});_0x47b05c>=0x0?(logger[_0x1a675a('0xc')](_0x1a675a('0xb'),_0x2d9286,_0x4b8338[_0x1a675a('0xf')]||_0x1a675a('0xe'),_0x47b05c),_0x319bc6['next'](_0x47b05c)):(logger[_0x1a675a('0xc')](_0x1a675a('0x0'),_0x2d9286,_0x4b8338[_0x1a675a('0xf')]||_0x1a675a('0xe')),_0x319bc6[_0x1a675a('0x5')]());}else _0x319bc6[_0x1a675a('0xe')]();}}catch(_0x50918c){logger['error'](_0x1a675a('0x9'),_0x2d9286,JSON[_0x1a675a('0x2')](_0x50918c)),_0x319bc6[_0x1a675a('0x5')]();}};}; \ No newline at end of file +const a1207_0x3689=['length','validate','consequence','rules','info','map','[%s][GOTOP]\x20priority\x20%s\x20found\x20at\x20index:\x20%s','error','../../../../config/logger','[%s][GOTOP]\x20priority\x20%s','[%s][GOTOP]\x20%s','stringify','priority','stop','next','number','message'];(function(_0x1d11d8,_0x3689b5){const _0x44f372=function(_0x4b8a6f){while(--_0x4b8a6f){_0x1d11d8['push'](_0x1d11d8['shift']());}};_0x44f372(++_0x3689b5);}(a1207_0x3689,0x1db));const a1207_0x44f3=function(_0x1d11d8,_0x3689b5){_0x1d11d8=_0x1d11d8-0x0;let _0x44f372=a1207_0x3689[_0x1d11d8];return _0x44f372;};const _0xfc8774=a1207_0x44f3;'use strict';const schema=require(_0xfc8774('0x2')),_=require('lodash'),logger=require(_0xfc8774('0x9'))('routing'),gotop=schema({'priority':{'type':_0xfc8774('0x10'),'required':!![],'message':'priority\x20is\x20a\x20number\x20and\x20it\x20is\x20required'}});exports[_0xfc8774('0x3')]=function(_0x4b8a6f,_0x4d43a8){return function(_0x38da1c){const _0x463d44=a1207_0x44f3;try{const _0x5e4314={'priority':_0x4d43a8[0x0]},_0x38779c=gotop[_0x463d44('0x2')](_0x5e4314,{'typecast':!![]});if(_0x38779c[_0x463d44('0x1')])logger[_0x463d44('0x8')](_0x463d44('0xb'),_0x4b8a6f,_[_0x463d44('0x6')](_0x38779c,_0x463d44('0x0'))['join'](',\x20')),_0x38da1c[_0x463d44('0xe')]();else{logger['info'](_0x463d44('0xa'),_0x4b8a6f,_0x5e4314[_0x463d44('0xd')]);if(_0x5e4314[_0x463d44('0xd')]){const _0x2b5670=_['findIndex'](_0x38da1c[_0x463d44('0x4')](),{'p':_0x5e4314[_0x463d44('0xd')]});_0x2b5670>=0x0?(logger['info'](_0x463d44('0x7'),_0x4b8a6f,_0x5e4314[_0x463d44('0xd')]||_0x463d44('0xf'),_0x2b5670),_0x38da1c[_0x463d44('0xf')](_0x2b5670)):(logger[_0x463d44('0x5')]('[%s][GOTOP]\x20priority\x20%s\x20not\x20found',_0x4b8a6f,_0x5e4314['priority']||_0x463d44('0xf')),_0x38da1c[_0x463d44('0xe')]());}else _0x38da1c[_0x463d44('0xf')]();}}catch(_0x29b948){logger['error'](_0x463d44('0xb'),_0x4b8a6f,JSON[_0x463d44('0xc')](_0x29b948)),_0x38da1c[_0x463d44('0xe')]();}};}; \ No newline at end of file diff --git a/server/services/routing/server/applications/message.js b/server/services/routing/server/applications/message.js index ded0505..772232f 100644 --- a/server/services/routing/server/applications/message.js +++ b/server/services/routing/server/applications/message.js @@ -1 +1 @@ -const a1208_0x11b3=['lodash','InteractionId','routing','upperFirst','body','./utils','error','then','getMustacheRender','channel','contact','account','../../rpc/smsMessage','ChatWebsiteId','../../../../config/logger','Message','chat','create','../../rpc/openchannelMessage','AccountId','../../rpc/whatsappMessage','stop','stringify','[%s][MESSAGE]\x20%s'];(function(_0x2b68f0,_0x11b3f8){const _0x402d45=function(_0x20e2c6){while(--_0x20e2c6){_0x2b68f0['push'](_0x2b68f0['shift']());}};_0x402d45(++_0x11b3f8);}(a1208_0x11b3,0x8a));const a1208_0x402d=function(_0x2b68f0,_0x11b3f8){_0x2b68f0=_0x2b68f0-0x0;let _0x402d45=a1208_0x11b3[_0x2b68f0];return _0x402d45;};const _0x5cd7d0=a1208_0x402d;'use strict';const _=require(_0x5cd7d0('0x6')),utils=require(_0x5cd7d0('0xb')),logger=require(_0x5cd7d0('0x14'))(_0x5cd7d0('0x8')),rpc={'chatMessage':require('../../rpc/chatMessage'),'openchannelMessage':require(_0x5cd7d0('0x0')),'mailMessage':require('../../rpc/mailMessage'),'smsMessage':require(_0x5cd7d0('0x12')),'faxMessage':require('../../rpc/faxMessage'),'whatsappMessage':require(_0x5cd7d0('0x2'))};exports['consequence']=function(_0x20e2c6,_0x14801b){return function(_0x2a41d0){const _0x407b59=a1208_0x402d;try{const _0x39497e={'body':utils[_0x407b59('0xe')](_0x14801b[0x0],this),'ContactId':this[_0x407b59('0x10')]['id']};this[_0x407b59('0xf')]===_0x407b59('0x16')?_0x39497e[_0x407b59('0x13')]=this['account']['id']:_0x39497e[_[_0x407b59('0x9')](this[_0x407b59('0xf')])+_0x407b59('0x1')]=this[_0x407b59('0x11')]['id'];_0x39497e[_['upperFirst'](this[_0x407b59('0xf')])+_0x407b59('0x7')]=this['interaction']['id'];if(rpc[this[_0x407b59('0xf')]+_0x407b59('0x15')])return rpc[this[_0x407b59('0xf')]+_0x407b59('0x15')][_0x407b59('0x17')](_0x39497e)[_0x407b59('0xd')](function(){const _0x57fef5=_0x407b59;logger['info']('[%s][MESSAGE]\x20%s',_0x20e2c6,_0x39497e[_0x57fef5('0xa')]),_0x2a41d0['next']();})['catch'](function(_0x5611c7){const _0x577cf0=_0x407b59;logger[_0x577cf0('0xc')](_0x577cf0('0x5'),_0x20e2c6,JSON[_0x577cf0('0x4')](_0x5611c7)),_0x2a41d0[_0x577cf0('0x3')]();});}catch(_0x4d8366){logger[_0x407b59('0xc')](_0x407b59('0x5'),_0x20e2c6,JSON[_0x407b59('0x4')](_0x4d8366)),_0x2a41d0[_0x407b59('0x3')]();}};}; \ No newline at end of file +const a1208_0x4410=['channel','stop','chat','[%s][MESSAGE]\x20%s','interaction','body','Message','../../rpc/whatsappMessage','upperFirst','../../rpc/smsMessage','then','../../../../config/logger','./utils','account','error','../../rpc/faxMessage','ChatWebsiteId','contact','../../rpc/openchannelMessage','getMustacheRender','stringify','next','consequence'];(function(_0x391ecf,_0x441009){const _0x1bdeeb=function(_0x140ce2){while(--_0x140ce2){_0x391ecf['push'](_0x391ecf['shift']());}};_0x1bdeeb(++_0x441009);}(a1208_0x4410,0x1e6));const a1208_0x1bde=function(_0x391ecf,_0x441009){_0x391ecf=_0x391ecf-0x0;let _0x1bdeeb=a1208_0x4410[_0x391ecf];return _0x1bdeeb;};const _0x29badd=a1208_0x1bde;'use strict';const _=require('lodash'),utils=require(_0x29badd('0x9')),logger=require(_0x29badd('0x8'))('routing'),rpc={'chatMessage':require('../../rpc/chatMessage'),'openchannelMessage':require(_0x29badd('0xf')),'mailMessage':require('../../rpc/mailMessage'),'smsMessage':require(_0x29badd('0x6')),'faxMessage':require(_0x29badd('0xc')),'whatsappMessage':require(_0x29badd('0x4'))};exports[_0x29badd('0x13')]=function(_0x140ce2,_0x497a6c){return function(_0x4fa2bf){const _0x5d0b1b=a1208_0x1bde;try{const _0x597f74={'body':utils[_0x5d0b1b('0x10')](_0x497a6c[0x0],this),'ContactId':this[_0x5d0b1b('0xe')]['id']};this[_0x5d0b1b('0x14')]===_0x5d0b1b('0x16')?_0x597f74[_0x5d0b1b('0xd')]=this[_0x5d0b1b('0xa')]['id']:_0x597f74[_[_0x5d0b1b('0x5')](this[_0x5d0b1b('0x14')])+'AccountId']=this['account']['id'];_0x597f74[_[_0x5d0b1b('0x5')](this[_0x5d0b1b('0x14')])+'InteractionId']=this[_0x5d0b1b('0x1')]['id'];if(rpc[this[_0x5d0b1b('0x14')]+_0x5d0b1b('0x3')])return rpc[this[_0x5d0b1b('0x14')]+_0x5d0b1b('0x3')]['create'](_0x597f74)[_0x5d0b1b('0x7')](function(){const _0x167207=_0x5d0b1b;logger['info'](_0x167207('0x0'),_0x140ce2,_0x597f74[_0x167207('0x2')]),_0x4fa2bf[_0x167207('0x12')]();})['catch'](function(_0x1e3592){const _0x31a4c6=_0x5d0b1b;logger[_0x31a4c6('0xb')]('[%s][MESSAGE]\x20%s',_0x140ce2,JSON[_0x31a4c6('0x11')](_0x1e3592)),_0x4fa2bf[_0x31a4c6('0x15')]();});}catch(_0x2468a3){logger[_0x5d0b1b('0xb')](_0x5d0b1b('0x0'),_0x140ce2,JSON['stringify'](_0x2468a3)),_0x4fa2bf[_0x5d0b1b('0x15')]();}};}; \ No newline at end of file diff --git a/server/services/routing/server/applications/noop.js b/server/services/routing/server/applications/noop.js index 3050ae2..de7dcfc 100644 --- a/server/services/routing/server/applications/noop.js +++ b/server/services/routing/server/applications/noop.js @@ -1 +1 @@ -const a1209_0x115c=['getMustacheRender','info','error','../../../../config/logger','consequence','[%s][NOOP]\x20%s','stringify','stop','routing'];(function(_0x1b183c,_0x115c82){const _0x329101=function(_0x2c7687){while(--_0x2c7687){_0x1b183c['push'](_0x1b183c['shift']());}};_0x329101(++_0x115c82);}(a1209_0x115c,0x1c6));const a1209_0x3291=function(_0x1b183c,_0x115c82){_0x1b183c=_0x1b183c-0x0;let _0x329101=a1209_0x115c[_0x1b183c];return _0x329101;};const _0x9a15da=a1209_0x3291;'use strict';const utils=require('./utils'),logger=require(_0x9a15da('0x8'))(_0x9a15da('0x4'));exports[_0x9a15da('0x0')]=function(_0x2c7687,_0x135040){return function(_0x29428a){const _0x45dd27=a1209_0x3291;try{logger[_0x45dd27('0x6')](_0x45dd27('0x1'),_0x2c7687,utils[_0x45dd27('0x5')](_0x135040[0x0],this)),_0x29428a['next']();}catch(_0x535cb5){logger[_0x45dd27('0x7')]('[%s][NOOP]\x20%s',_0x2c7687,JSON[_0x45dd27('0x2')](_0x535cb5)),_0x29428a[_0x45dd27('0x3')]();}};}; \ No newline at end of file +const a1209_0x403e=['../../../../config/logger','consequence','next','error','routing','info','stringify','[%s][NOOP]\x20%s','getMustacheRender','stop'];(function(_0x49ec95,_0x403e25){const _0xc412=function(_0x2f6012){while(--_0x2f6012){_0x49ec95['push'](_0x49ec95['shift']());}};_0xc412(++_0x403e25);}(a1209_0x403e,0x71));const a1209_0xc412=function(_0x49ec95,_0x403e25){_0x49ec95=_0x49ec95-0x0;let _0xc412=a1209_0x403e[_0x49ec95];return _0xc412;};const _0x70f8a5=a1209_0xc412;'use strict';const utils=require('./utils'),logger=require(_0x70f8a5('0x7'))(_0x70f8a5('0x1'));exports[_0x70f8a5('0x8')]=function(_0x2f6012,_0x5e083f){return function(_0x475669){const _0x193ae6=a1209_0xc412;try{logger[_0x193ae6('0x2')](_0x193ae6('0x4'),_0x2f6012,utils[_0x193ae6('0x5')](_0x5e083f[0x0],this)),_0x475669[_0x193ae6('0x9')]();}catch(_0x96aeb7){logger[_0x193ae6('0x0')](_0x193ae6('0x4'),_0x2f6012,JSON[_0x193ae6('0x3')](_0x96aeb7)),_0x475669[_0x193ae6('0x6')]();}};}; \ No newline at end of file diff --git a/server/services/routing/server/applications/queue.js b/server/services/routing/server/applications/queue.js index 5529393..62809b7 100644 --- a/server/services/routing/server/applications/queue.js +++ b/server/services/routing/server/applications/queue.js @@ -1 +1 @@ -const a1210_0x2cb7=['update','stack','pick','rules','MessageId','routing','consequence','YYYY-MM-DD\x20HH:mm:ss','./strategy','AccountId','channel','[%s][QUEUE]\x20APPLICATION\x20END','message','stop','find','format','upperFirst','%s:queue:%s','join','close','../../rpc/smsQueueReport','util','QueueReport','remove','emit','toLowerCase','catch','waiting','atimeout','length','../../rpc/whatsappQueueReport','string','QueueId','[%s][QUEUE]\x20%s','chat','interaction','../../rpc/mailQueueReport','[%s][QUEUE]\x20ROUTING\x20STOPPED','%s_queue_waiting_interaction:%s','next','number','complete','timeout\x20is\x20a\x20number','name','Queues','body','error','timeout','contact','validate','InteractionId','createQueue','strategy','info','../../rpc/openchannelQueueReport','create','from','../../rpc/chatQueueReport','rrmemory','[%s][START:QUEUE][NAME:%s]','update\x20queue\x20report','list','account','../../../../rediscache','queue','name\x20is\x20a\x20string\x20and\x20it\x20is\x20required','accepted','moment'];(function(_0x2f622d,_0x2cb702){const _0x33d480=function(_0x517f5f){while(--_0x517f5f){_0x2f622d['push'](_0x2f622d['shift']());}};_0x33d480(++_0x2cb702);}(a1210_0x2cb7,0x70));const a1210_0x33d4=function(_0x2f622d,_0x2cb702){_0x2f622d=_0x2f622d-0x0;let _0x33d480=a1210_0x2cb7[_0x2f622d];return _0x33d480;};const _0x196edb=a1210_0x33d4;'use strict';const schema=require(_0x196edb('0x5')),_=require('lodash'),util=require(_0x196edb('0x2d')),seqqueue=require('seq-queue'),moment=require(_0x196edb('0x17')),logger=require('../../../../config/logger')(_0x196edb('0x1d')),strategy=require(_0x196edb('0x20')),{getSocket}=require(_0x196edb('0x13')),io=getSocket(),attributes=['id','queue_id',_0x196edb('0x12'),_0x196edb('0x14'),'from','joinAt'];function emit(_0x517f5f,_0x4e6014,_0x3e039a){const _0x54224a=_0x196edb;io['to'](_0x517f5f)[_0x54224a('0x30')](_0x4e6014,_0x3e039a);}function emitChannelQueueInteraction(_0x36eb57,_0x3dfe20,_0x812d8d,_0x822cfc,_0x547393,_0xc7bf29,_0x3777b5,_0x456d6e){const _0x1f9b1c=_0x196edb,_0x4a238b=_['clone'](_0x812d8d);_0x4a238b['queue_id']=_0x456d6e,_0x4a238b[_0x1f9b1c('0x14')]=_0x3dfe20,_0x4a238b[_0x1f9b1c('0x12')]=_0x822cfc,_0x4a238b['id']=_0x547393,_0xc7bf29?_0x3777b5[util[_0x1f9b1c('0x27')]('%sQueuesWaitingInteractions',_0x36eb57)][_0x547393]=_[_0x1f9b1c('0x1a')](_0x4a238b,attributes):delete _0x3777b5[util[_0x1f9b1c('0x27')]('%sQueuesWaitingInteractions',_0x36eb57)][_0x547393],emit(util[_0x1f9b1c('0x27')](_0x1f9b1c('0x29'),_0x36eb57,_0x3dfe20),util[_0x1f9b1c('0x27')](_0x1f9b1c('0x3e'),_0x36eb57,_0xc7bf29?'save':_0x1f9b1c('0x2f')),_[_0x1f9b1c('0x1a')](_0x4a238b,attributes));}const rpc={'openchannelQueueReport':require(_0x196edb('0xa')),'mailQueueReport':require(_0x196edb('0x3c')),'chatQueueReport':require(_0x196edb('0xd')),'smsQueueReport':require(_0x196edb('0x2c')),'faxQueueReport':require('../../rpc/faxQueueReport'),'whatsappQueueReport':require(_0x196edb('0x36'))},queue=schema({'name':{'type':_0x196edb('0x37'),'required':!![],'message':_0x196edb('0x15')},'timeout':{'type':_0x196edb('0x40'),'message':_0x196edb('0x42')}});function startRouting(_0x4b8127,_0x44f2cd,_0x2b9bda,_0x3c7e6c){const _0x43357f=_0x196edb;if(_0x4b8127&&_0x44f2cd&&_0x2b9bda){_0x44f2cd[_0x43357f('0x33')]+=0x1;const _0xcdc61b={'uniqueid':_0x4b8127,'from':_0x2b9bda[_0x43357f('0x1')]?_0x2b9bda['body'][_0x43357f('0xc')]:'','joinAt':moment()[_0x43357f('0x27')]('YYYY-MM-DD\x20HH:mm:ss'),'ContactId':_0x2b9bda[_0x43357f('0x4')]?_0x2b9bda[_0x43357f('0x4')]['id']:null,'ListId':_0x2b9bda[_0x43357f('0x11')]?_0x2b9bda[_0x43357f('0x11')]['id']:null};_0xcdc61b[_['upperFirst'](_0x2b9bda[_0x43357f('0x22')])+_0x43357f('0x38')]=_0x44f2cd['id']||null,_0xcdc61b[_[_0x43357f('0x28')](_0x2b9bda['channel'])+_0x43357f('0x6')]=_0x2b9bda[_0x43357f('0x3b')]?_0x2b9bda[_0x43357f('0x3b')]['id']:null,_0xcdc61b[_['upperFirst'](_0x2b9bda[_0x43357f('0x22')])+_0x43357f('0x1c')]=_0x2b9bda['message']?_0x2b9bda[_0x43357f('0x24')]['id']:null,_0xcdc61b[_[_0x43357f('0x28')](_0x2b9bda['channel'])+(_0x2b9bda[_0x43357f('0x22')]!==_0x43357f('0x3a')?_0x43357f('0x21'):'WebsiteId')]=_0x2b9bda['account']?_0x2b9bda[_0x43357f('0x12')]['id']:null,logger[_0x43357f('0x9')](util['format'](_0x43357f('0xf'),_0x4b8127,_0x44f2cd['name'])),emitChannelQueueInteraction(_0x2b9bda[_0x43357f('0x22')],_0x44f2cd[_0x43357f('0x43')],_0xcdc61b,_0x2b9bda[_0x43357f('0x12')][_0x43357f('0x43')],_0x2b9bda[_0x43357f('0x24')]['id'],!![],_0x3c7e6c,_0x44f2cd['id']);if(rpc[_0x2b9bda[_0x43357f('0x22')]+'QueueReport'])return rpc[_0x2b9bda[_0x43357f('0x22')]+_0x43357f('0x2e')][_0x43357f('0xb')](_0xcdc61b)[_0x43357f('0x32')](function(){const _0x50a15f=_0x43357f;logger[_0x50a15f('0x2')]('create\x20queue\x20report');});}}function stopRouting(_0x29dc68,_0x224423,_0x5365ce,_0x4b04be){const _0x40a560=_0x196edb;if(_0x29dc68&&_0x224423){_0x224423[_0x40a560('0x33')]-=0x1;const _0x1ce32a={'leaveAt':moment()['format']('YYYY-MM-DD\x20HH:mm:ss'),'acceptAt':moment()[_0x40a560('0x27')](_0x40a560('0x1f')),'reason':_0x40a560('0x16')};logger['info'](util[_0x40a560('0x27')]('[%s][STOP:QUEUE][NAME:%s]',_0x29dc68,_0x224423[_0x40a560('0x43')])),emitChannelQueueInteraction(_0x5365ce[_0x40a560('0x22')],_0x224423[_0x40a560('0x43')],_0x5365ce[_0x40a560('0x1')],_0x5365ce[_0x40a560('0x12')][_0x40a560('0x43')],_0x5365ce[_0x40a560('0x24')]['id'],![],_0x4b04be,_0x224423['id']);if(rpc[_0x5365ce[_0x40a560('0x22')]+'QueueReport'])return rpc[_0x5365ce[_0x40a560('0x22')]+'QueueReport'][_0x40a560('0x18')](_0x29dc68,_0x1ce32a)[_0x40a560('0x32')](function(){const _0x19b461=_0x40a560;logger['error'](_0x19b461('0x10'));});}}function endRouting(_0x2ff60b,_0x3801de,_0x8db1f8,_0x1879b3){const _0x40838f=_0x196edb;if(_0x2ff60b&&_0x3801de){_0x3801de[_0x40838f('0x33')]-=0x1;const _0x2c934c={'leaveAt':moment()[_0x40838f('0x27')](_0x40838f('0x1f')),'exitAt':moment()['format'](_0x40838f('0x1f')),'reason':_0x40838f('0x3')};logger[_0x40838f('0x9')](util[_0x40838f('0x27')]('[%s][END:QUEUE][NAME:%s]',_0x2ff60b,_0x3801de[_0x40838f('0x43')])),emitChannelQueueInteraction(_0x8db1f8[_0x40838f('0x22')],_0x3801de['name'],_0x8db1f8[_0x40838f('0x1')],_0x8db1f8['account'][_0x40838f('0x43')],_0x8db1f8[_0x40838f('0x24')]['id'],![],_0x1879b3);if(rpc[_0x8db1f8[_0x40838f('0x22')]+_0x40838f('0x2e')])return rpc[_0x8db1f8[_0x40838f('0x22')]+_0x40838f('0x2e')][_0x40838f('0x18')](_0x2ff60b,_0x2c934c)['catch'](function(){logger['error']('update\x20queue\x20report');});}}function handleFindQueue(_0x30ac8a){return function(_0x19ccb1){const _0x391ece=a1210_0x33d4;return _0x19ccb1[_0x391ece('0x43')][_0x391ece('0x31')]()===_0x30ac8a[_0x391ece('0x31')]();};}exports[_0x196edb('0x1e')]=function(_0x40b569,_0x24526e,_0x59cc8e,_0x257e9f){return function(_0xccb4bb){const _0x11fd22=a1210_0x33d4;try{const _0x33aab8={'name':_0x24526e[0x0],'timeout':_0x24526e[0x1]},_0x54b17f=queue[_0x11fd22('0x5')](_0x33aab8,{'typecast':!![]});if(_0x54b17f[_0x11fd22('0x35')])logger[_0x11fd22('0x2')](_0x11fd22('0x39'),_0x40b569,_['map'](_0x54b17f,_0x11fd22('0x24'))[_0x11fd22('0x2a')](',\x20')),_0xccb4bb[_0x11fd22('0x25')]();else{const _0x5dc7aa=_[_0x11fd22('0x26')](_0x59cc8e[_0x257e9f['channel']+_0x11fd22('0x0')],handleFindQueue(_0x33aab8[_0x11fd22('0x43')]));if(_0x5dc7aa){startRouting(_0x40b569,_0x5dc7aa,_0x257e9f,_0x59cc8e);const _0x1ee86c=(_0x5dc7aa['timeout']||0xa)*0x3e8;let _0x5366e2=(_0x33aab8['timeout']||0x14)*0x3e8,_0x504189;_0x1ee86c>_0x5366e2&&(_0x5366e2=_0x1ee86c);const _0x540c4d=seqqueue[_0x11fd22('0x7')](_0x1ee86c);_0x540c4d['id']=_0x40b569,_0x540c4d[_0x11fd22('0x34')]=_0x1ee86c,_0x540c4d['qtimeout']=_0x5366e2,_0x540c4d[_0x11fd22('0x22')]=_0x257e9f['channel'],_0x59cc8e[_0x11fd22('0x1b')][_0x40b569]['on']('end',function(){const _0x21ef63=_0x11fd22;logger[_0x21ef63('0x9')](_0x21ef63('0x3d'),_0x40b569),stopRouting(_0x40b569,_0x5dc7aa,_0x257e9f,_0x59cc8e),clearTimeout(_0x504189),_0x504189=undefined,_0x540c4d[_0x21ef63('0x2b')](!![]),_0x59cc8e['rules'][_0x40b569]&&delete _0x59cc8e[_0x21ef63('0x1b')][_0x40b569],_0xccb4bb[_0x21ef63('0x25')]();}),_0x59cc8e[_0x11fd22('0x1b')][_0x40b569]['on'](_0x11fd22('0x41'),function(){const _0x205dc7=_0x11fd22;_0x59cc8e['rules'][_0x40b569]&&delete _0x59cc8e[_0x205dc7('0x1b')][_0x40b569];}),_0x504189=setTimeout(function(){const _0x883e17=_0x11fd22;logger['info'](_0x883e17('0x23'),_0x40b569),endRouting(_0x40b569,_0x5dc7aa,_0x257e9f,_0x59cc8e),clearTimeout(_0x504189),_0x540c4d[_0x883e17('0x2b')](!![]),_0xccb4bb[_0x883e17('0x3f')]();},_0x5366e2);switch(_0x5dc7aa[_0x11fd22('0x8')]){case _0x11fd22('0xe'):strategy[_0x11fd22('0xe')](_0x540c4d,_0x5dc7aa,_0x59cc8e,_0x257e9f);break;default:strategy['beepall'](_0x540c4d,_0x5dc7aa,_0x59cc8e,_0x257e9f);}}else logger[_0x11fd22('0x2')]('[%s][QUEUE]\x20queue\x20not\x20found\x20%s',_0x40b569,_0x33aab8[_0x11fd22('0x43')]),_0xccb4bb[_0x11fd22('0x25')]();}}catch(_0x2541d7){console['log'](_0x2541d7),logger[_0x11fd22('0x2')](_0x11fd22('0x39'),_0x40b569,_0x2541d7[_0x11fd22('0x19')]),_0xccb4bb[_0x11fd22('0x25')]();}};}; \ No newline at end of file +const a1210_0x32d4=['catch','toLowerCase','from','message','Queues','rules','[%s][QUEUE]\x20ROUTING\x20STOPPED','seq-queue','timeout\x20is\x20a\x20number','consequence','list','../../rpc/whatsappQueueReport','error','next','update\x20queue\x20report','body','format','pick','update','queue','validate','QueueId','QueueReport','../../rpc/faxQueueReport','strategy','../../../../rediscache','close','number','[%s][QUEUE]\x20queue\x20not\x20found\x20%s','interaction','end','channel','AccountId','beepall','name','moment','createQueue','stop','lodash','%sQueuesWaitingInteractions','emit','[%s][QUEUE]\x20APPLICATION\x20END','account','routing','remove','clone','info','contact','qtimeout','%s:queue:%s','InteractionId','[%s][END:QUEUE][NAME:%s]','length','name\x20is\x20a\x20string\x20and\x20it\x20is\x20required','create\x20queue\x20report','string','MessageId','map','%s_queue_waiting_interaction:%s','find','atimeout','waiting','joinAt','../../rpc/chatQueueReport','stack','../../rpc/mailQueueReport','join','WebsiteId','complete','rrmemory','../../../../config/logger','create','YYYY-MM-DD\x20HH:mm:ss','upperFirst','queue_id','timeout'];(function(_0x527590,_0x32d453){const _0x5d97ee=function(_0x47ff74){while(--_0x47ff74){_0x527590['push'](_0x527590['shift']());}};_0x5d97ee(++_0x32d453);}(a1210_0x32d4,0x12c));const a1210_0x5d97=function(_0x527590,_0x32d453){_0x527590=_0x527590-0x0;let _0x5d97ee=a1210_0x32d4[_0x527590];return _0x5d97ee;};const _0xf11c1f=a1210_0x5d97;'use strict';const schema=require(_0xf11c1f('0x18')),_=require(_0xf11c1f('0x2a')),util=require('util'),seqqueue=require(_0xf11c1f('0xb')),moment=require(_0xf11c1f('0x27')),logger=require(_0xf11c1f('0x4a'))(_0xf11c1f('0x2f')),strategy=require('./strategy'),{getSocket}=require(_0xf11c1f('0x1d')),io=getSocket(),attributes=['id',_0xf11c1f('0x2'),_0xf11c1f('0x2e'),'queue','from',_0xf11c1f('0x42')];function emit(_0x47ff74,_0x61eda,_0x58c59e){const _0x34acf5=_0xf11c1f;io['to'](_0x47ff74)[_0x34acf5('0x2c')](_0x61eda,_0x58c59e);}function emitChannelQueueInteraction(_0x1e2a98,_0x5c7872,_0x31a39d,_0x3109a0,_0x961890,_0x3758b6,_0x1737ce,_0x1ec633){const _0x1560cd=_0xf11c1f,_0x1df486=_[_0x1560cd('0x31')](_0x31a39d);_0x1df486[_0x1560cd('0x2')]=_0x1ec633,_0x1df486[_0x1560cd('0x17')]=_0x5c7872,_0x1df486[_0x1560cd('0x2e')]=_0x3109a0,_0x1df486['id']=_0x961890,_0x3758b6?_0x1737ce[util[_0x1560cd('0x14')]('%sQueuesWaitingInteractions',_0x1e2a98)][_0x961890]=_[_0x1560cd('0x15')](_0x1df486,attributes):delete _0x1737ce[util[_0x1560cd('0x14')](_0x1560cd('0x2b'),_0x1e2a98)][_0x961890],emit(util[_0x1560cd('0x14')](_0x1560cd('0x35'),_0x1e2a98,_0x5c7872),util[_0x1560cd('0x14')](_0x1560cd('0x3e'),_0x1e2a98,_0x3758b6?'save':_0x1560cd('0x30')),_[_0x1560cd('0x15')](_0x1df486,attributes));}const rpc={'openchannelQueueReport':require('../../rpc/openchannelQueueReport'),'mailQueueReport':require(_0xf11c1f('0x45')),'chatQueueReport':require(_0xf11c1f('0x43')),'smsQueueReport':require('../../rpc/smsQueueReport'),'faxQueueReport':require(_0xf11c1f('0x1b')),'whatsappQueueReport':require(_0xf11c1f('0xf'))},queue=schema({'name':{'type':_0xf11c1f('0x3b'),'required':!![],'message':_0xf11c1f('0x39')},'timeout':{'type':_0xf11c1f('0x1f'),'message':_0xf11c1f('0xc')}});function startRouting(_0x39dc2b,_0x33f371,_0x5424ad,_0x37ac29){const _0x37f27f=_0xf11c1f;if(_0x39dc2b&&_0x33f371&&_0x5424ad){_0x33f371['waiting']+=0x1;const _0xcac6c4={'uniqueid':_0x39dc2b,'from':_0x5424ad[_0x37f27f('0x13')]?_0x5424ad[_0x37f27f('0x13')][_0x37f27f('0x6')]:'','joinAt':moment()['format'](_0x37f27f('0x0')),'ContactId':_0x5424ad[_0x37f27f('0x33')]?_0x5424ad[_0x37f27f('0x33')]['id']:null,'ListId':_0x5424ad[_0x37f27f('0xe')]?_0x5424ad[_0x37f27f('0xe')]['id']:null};_0xcac6c4[_[_0x37f27f('0x1')](_0x5424ad[_0x37f27f('0x23')])+_0x37f27f('0x19')]=_0x33f371['id']||null,_0xcac6c4[_[_0x37f27f('0x1')](_0x5424ad[_0x37f27f('0x23')])+_0x37f27f('0x36')]=_0x5424ad[_0x37f27f('0x21')]?_0x5424ad[_0x37f27f('0x21')]['id']:null,_0xcac6c4[_[_0x37f27f('0x1')](_0x5424ad[_0x37f27f('0x23')])+_0x37f27f('0x3c')]=_0x5424ad[_0x37f27f('0x7')]?_0x5424ad[_0x37f27f('0x7')]['id']:null,_0xcac6c4[_['upperFirst'](_0x5424ad[_0x37f27f('0x23')])+(_0x5424ad[_0x37f27f('0x23')]!=='chat'?_0x37f27f('0x24'):_0x37f27f('0x47'))]=_0x5424ad[_0x37f27f('0x2e')]?_0x5424ad[_0x37f27f('0x2e')]['id']:null,logger[_0x37f27f('0x32')](util['format']('[%s][START:QUEUE][NAME:%s]',_0x39dc2b,_0x33f371['name'])),emitChannelQueueInteraction(_0x5424ad['channel'],_0x33f371[_0x37f27f('0x26')],_0xcac6c4,_0x5424ad[_0x37f27f('0x2e')][_0x37f27f('0x26')],_0x5424ad[_0x37f27f('0x7')]['id'],!![],_0x37ac29,_0x33f371['id']);if(rpc[_0x5424ad['channel']+_0x37f27f('0x1a')])return rpc[_0x5424ad[_0x37f27f('0x23')]+'QueueReport'][_0x37f27f('0x4b')](_0xcac6c4)[_0x37f27f('0x4')](function(){const _0xf83a7f=_0x37f27f;logger['error'](_0xf83a7f('0x3a'));});}}function stopRouting(_0x595a51,_0x208464,_0x2ba82a,_0x3d4243){const _0x290c81=_0xf11c1f;if(_0x595a51&&_0x208464){_0x208464[_0x290c81('0x41')]-=0x1;const _0x5ad545={'leaveAt':moment()[_0x290c81('0x14')]('YYYY-MM-DD\x20HH:mm:ss'),'acceptAt':moment()[_0x290c81('0x14')]('YYYY-MM-DD\x20HH:mm:ss'),'reason':'accepted'};logger[_0x290c81('0x32')](util[_0x290c81('0x14')]('[%s][STOP:QUEUE][NAME:%s]',_0x595a51,_0x208464[_0x290c81('0x26')])),emitChannelQueueInteraction(_0x2ba82a[_0x290c81('0x23')],_0x208464['name'],_0x2ba82a[_0x290c81('0x13')],_0x2ba82a['account'][_0x290c81('0x26')],_0x2ba82a[_0x290c81('0x7')]['id'],![],_0x3d4243,_0x208464['id']);if(rpc[_0x2ba82a['channel']+_0x290c81('0x1a')])return rpc[_0x2ba82a[_0x290c81('0x23')]+_0x290c81('0x1a')][_0x290c81('0x16')](_0x595a51,_0x5ad545)[_0x290c81('0x4')](function(){const _0x1e7c86=_0x290c81;logger['error'](_0x1e7c86('0x12'));});}}function endRouting(_0x5e9033,_0x46a3f0,_0x3cf2bd,_0x4a5dd6){const _0x1e159c=_0xf11c1f;if(_0x5e9033&&_0x46a3f0){_0x46a3f0['waiting']-=0x1;const _0x38cbde={'leaveAt':moment()[_0x1e159c('0x14')](_0x1e159c('0x0')),'exitAt':moment()[_0x1e159c('0x14')]('YYYY-MM-DD\x20HH:mm:ss'),'reason':_0x1e159c('0x3')};logger[_0x1e159c('0x32')](util[_0x1e159c('0x14')](_0x1e159c('0x37'),_0x5e9033,_0x46a3f0[_0x1e159c('0x26')])),emitChannelQueueInteraction(_0x3cf2bd[_0x1e159c('0x23')],_0x46a3f0[_0x1e159c('0x26')],_0x3cf2bd[_0x1e159c('0x13')],_0x3cf2bd['account'][_0x1e159c('0x26')],_0x3cf2bd[_0x1e159c('0x7')]['id'],![],_0x4a5dd6);if(rpc[_0x3cf2bd[_0x1e159c('0x23')]+'QueueReport'])return rpc[_0x3cf2bd[_0x1e159c('0x23')]+'QueueReport']['update'](_0x5e9033,_0x38cbde)[_0x1e159c('0x4')](function(){const _0x183eda=_0x1e159c;logger[_0x183eda('0x10')](_0x183eda('0x12'));});}}function handleFindQueue(_0x5180d8){return function(_0xe4dbd7){const _0x303bf8=a1210_0x5d97;return _0xe4dbd7['name']['toLowerCase']()===_0x5180d8[_0x303bf8('0x5')]();};}exports[_0xf11c1f('0xd')]=function(_0x37c2a7,_0x1cdd54,_0x396837,_0x522260){return function(_0x2a4dba){const _0x4c7513=a1210_0x5d97;try{const _0x2cff3d={'name':_0x1cdd54[0x0],'timeout':_0x1cdd54[0x1]},_0x150336=queue[_0x4c7513('0x18')](_0x2cff3d,{'typecast':!![]});if(_0x150336[_0x4c7513('0x38')])logger[_0x4c7513('0x10')]('[%s][QUEUE]\x20%s',_0x37c2a7,_[_0x4c7513('0x3d')](_0x150336,_0x4c7513('0x7'))[_0x4c7513('0x46')](',\x20')),_0x2a4dba[_0x4c7513('0x29')]();else{const _0x33c4be=_[_0x4c7513('0x3f')](_0x396837[_0x522260[_0x4c7513('0x23')]+_0x4c7513('0x8')],handleFindQueue(_0x2cff3d[_0x4c7513('0x26')]));if(_0x33c4be){startRouting(_0x37c2a7,_0x33c4be,_0x522260,_0x396837);const _0x39d9bc=(_0x33c4be['timeout']||0xa)*0x3e8;let _0x1f1224=(_0x2cff3d[_0x4c7513('0x3')]||0x14)*0x3e8,_0x3b23a8;_0x39d9bc>_0x1f1224&&(_0x1f1224=_0x39d9bc);const _0x2612bf=seqqueue[_0x4c7513('0x28')](_0x39d9bc);_0x2612bf['id']=_0x37c2a7,_0x2612bf[_0x4c7513('0x40')]=_0x39d9bc,_0x2612bf[_0x4c7513('0x34')]=_0x1f1224,_0x2612bf[_0x4c7513('0x23')]=_0x522260[_0x4c7513('0x23')],_0x396837['rules'][_0x37c2a7]['on'](_0x4c7513('0x22'),function(){const _0x311d49=_0x4c7513;logger[_0x311d49('0x32')](_0x311d49('0xa'),_0x37c2a7),stopRouting(_0x37c2a7,_0x33c4be,_0x522260,_0x396837),clearTimeout(_0x3b23a8),_0x3b23a8=undefined,_0x2612bf[_0x311d49('0x1e')](!![]),_0x396837[_0x311d49('0x9')][_0x37c2a7]&&delete _0x396837['rules'][_0x37c2a7],_0x2a4dba[_0x311d49('0x29')]();}),_0x396837[_0x4c7513('0x9')][_0x37c2a7]['on'](_0x4c7513('0x48'),function(){const _0x1351b3=_0x4c7513;_0x396837[_0x1351b3('0x9')][_0x37c2a7]&&delete _0x396837[_0x1351b3('0x9')][_0x37c2a7];}),_0x3b23a8=setTimeout(function(){const _0x3765c1=_0x4c7513;logger['info'](_0x3765c1('0x2d'),_0x37c2a7),endRouting(_0x37c2a7,_0x33c4be,_0x522260,_0x396837),clearTimeout(_0x3b23a8),_0x2612bf[_0x3765c1('0x1e')](!![]),_0x2a4dba[_0x3765c1('0x11')]();},_0x1f1224);switch(_0x33c4be[_0x4c7513('0x1c')]){case _0x4c7513('0x49'):strategy[_0x4c7513('0x49')](_0x2612bf,_0x33c4be,_0x396837,_0x522260);break;default:strategy[_0x4c7513('0x25')](_0x2612bf,_0x33c4be,_0x396837,_0x522260);}}else logger[_0x4c7513('0x10')](_0x4c7513('0x20'),_0x37c2a7,_0x2cff3d['name']),_0x2a4dba[_0x4c7513('0x29')]();}}catch(_0x51036c){console['log'](_0x51036c),logger[_0x4c7513('0x10')]('[%s][QUEUE]\x20%s',_0x37c2a7,_0x51036c[_0x4c7513('0x44')]),_0x2a4dba['stop']();}};}; \ No newline at end of file diff --git a/server/services/routing/server/applications/strategy/agent.js b/server/services/routing/server/applications/strategy/agent.js index c045a56..96b86c3 100644 --- a/server/services/routing/server/applications/strategy/agent.js +++ b/server/services/routing/server/applications/strategy/agent.js @@ -1 +1 @@ -const a1211_0x359c=['STOP','info','notificationId','handleDrained','forcedOwnership','squeue','exports','busy','agent','showNotification',':FORCED','[%s][AGENT]\x20try\x20with\x20%s','push','lodash','[%s][AGENT]\x20timeout\x20with\x20%s','../../../../../config/logger','writeLog','routing','prototype','timeout','realtime','isNil','./util','bind','agents','hideNotification','TIMEOUT','busyQueue','[%s][AGENT]\x20agent\x20skipped,\x20unknown\x20id\x20%s','handleTimeout','drained','isAgentAvailable','channel'];(function(_0x4b71d7,_0x359c36){const _0x4bc3f3=function(_0x3e1f4a){while(--_0x3e1f4a){_0x4b71d7['push'](_0x4b71d7['shift']());}};_0x4bc3f3(++_0x359c36);}(a1211_0x359c,0x1f1));const a1211_0x4bc3=function(_0x4b71d7,_0x359c36){_0x4b71d7=_0x4b71d7-0x0;let _0x4bc3f3=a1211_0x359c[_0x4b71d7];return _0x4bc3f3;};const _0x23bee6=a1211_0x4bc3;'use strict';const _=require(_0x23bee6('0xb')),uuid=require('uuid'),util=require(_0x23bee6('0x14')),logger=require(_0x23bee6('0xd'))('routing'),Agent=function(_0x3e1f4a,_0x4922f6,_0x46a62b,_0x1a74ba){const _0x2fa228=_0x23bee6;this['notificationId']=uuid['v4'](),this[_0x2fa228('0x3')]=_0x3e1f4a,this[_0x2fa228('0x6')]=_0x4922f6,this[_0x2fa228('0x12')]=_0x46a62b,this[_0x2fa228('0xf')]=_0x1a74ba,this['squeue'][_0x2fa228('0xa')](this['handleRun']['bind'](this),this[_0x2fa228('0x1b')][_0x2fa228('0x15')](this)),this[_0x2fa228('0x3')]['on'](_0x2fa228('0x11'),this[_0x2fa228('0x1b')][_0x2fa228('0x15')](this)),this[_0x2fa228('0x3')]['on'](_0x2fa228('0x1c'),this[_0x2fa228('0x1')][_0x2fa228('0x15')](this));};Agent['prototype']['push']=function(){const _0x4ae92f=_0x23bee6;this[_0x4ae92f('0x3')][_0x4ae92f('0xa')](this['handleRun'][_0x4ae92f('0x15')](this),this[_0x4ae92f('0x1b')][_0x4ae92f('0x15')](this));},Agent[_0x23bee6('0x10')]['handleDrained']=function(){const _0xfcecd0=_0x23bee6;this[_0xfcecd0('0x1b')](!![]);},Agent['prototype']['handleRun']=function(){const _0x718df7=_0x23bee6;logger[_0x718df7('0x20')](_0x718df7('0x9'),this[_0x718df7('0x3')]['id'],this[_0x718df7('0x6')]['id']),_[_0x718df7('0x13')](this[_0x718df7('0x12')][_0x718df7('0x16')][this[_0x718df7('0x6')]['id']])?(logger[_0x718df7('0x20')](_0x718df7('0x1a'),this['squeue']['id'],this['agent']['id']),setTimeout(this['push'][_0x718df7('0x15')](this),0x3e8)):this['routing']['forcedOwnership']||util[_0x718df7('0x1d')](this['squeue']['id'],this[_0x718df7('0x12')][_0x718df7('0x16')][this[_0x718df7('0x6')]['id']],this[_0x718df7('0x3')][_0x718df7('0x1e')],![])?(this[_0x718df7('0x12')][_0x718df7('0x16')][this[_0x718df7('0x6')]['id']][_0x718df7('0x5')]=!![],this[_0x718df7('0x12')][_0x718df7('0x16')][this[_0x718df7('0x6')]['id']]['busyQueue']=undefined,util[_0x718df7('0x7')](this['notificationId'],this[_0x718df7('0x3')]['id'],this['realtime'][_0x718df7('0x16')][this[_0x718df7('0x6')]['id']],null,this[_0x718df7('0xf')]),util[_0x718df7('0xe')](this[_0x718df7('0x3')]['id'],this[_0x718df7('0x12')]['agents'][this[_0x718df7('0x6')]['id']],'RINGING'+(this['routing'][_0x718df7('0x2')]?_0x718df7('0x8'):''))):(logger[_0x718df7('0x20')]('[%s][AGENT]\x20agent\x20%s\x20is\x20not\x20available',this[_0x718df7('0x3')]['id'],this[_0x718df7('0x6')]['id']),setTimeout(this['push'][_0x718df7('0x15')](this),0x3e8));},Agent['prototype'][_0x23bee6('0x1b')]=function(_0x27ba6c){const _0x151fbc=_0x23bee6;if(_[_0x151fbc('0x13')](this['realtime'][_0x151fbc('0x16')][this[_0x151fbc('0x6')]['id']]))return logger[_0x151fbc('0x20')](_0x151fbc('0x1a'),this['squeue']['id'],this[_0x151fbc('0x6')]['id']);else logger[_0x151fbc('0x20')](_0x151fbc('0xc'),this['squeue']['id'],this[_0x151fbc('0x6')]['id']),util[_0x151fbc('0x17')](this[_0x151fbc('0x0')],this[_0x151fbc('0x3')]['id'],this[_0x151fbc('0x12')][_0x151fbc('0x16')][this[_0x151fbc('0x6')]['id']],null,this[_0x151fbc('0xf')]),this['realtime'][_0x151fbc('0x16')][this[_0x151fbc('0x6')]['id']][_0x151fbc('0x5')]=![],this['realtime'][_0x151fbc('0x16')][this[_0x151fbc('0x6')]['id']][_0x151fbc('0x19')]=undefined,util['writeLog'](this['squeue']['id'],this[_0x151fbc('0x12')][_0x151fbc('0x16')][this['agent']['id']],_0x27ba6c?_0x151fbc('0x1f'):_0x151fbc('0x18'));!_0x27ba6c&&setTimeout(this['push']['bind'](this),0x3e8);};function agent(_0xc6411d,_0x48114f,_0x18ca21,_0x1162db){return new Agent(_0xc6411d,_0x48114f,_0x18ca21,_0x1162db);}module[_0x23bee6('0x4')]=agent; \ No newline at end of file +const a1211_0x5518=['agents','showNotification','realtime','./util','notificationId',':FORCED','routing','[%s][AGENT]\x20agent\x20skipped,\x20unknown\x20id\x20%s','isAgentAvailable','info','push','handleRun','isNil','prototype','agent','forcedOwnership','hideNotification','[%s][AGENT]\x20timeout\x20with\x20%s','busy','busyQueue','handleDrained','drained','squeue','writeLog','handleTimeout','lodash','../../../../../config/logger','bind','TIMEOUT','STOP'];(function(_0x4730b0,_0x55182a){const _0x34c4e0=function(_0x4ad94d){while(--_0x4ad94d){_0x4730b0['push'](_0x4730b0['shift']());}};_0x34c4e0(++_0x55182a);}(a1211_0x5518,0xb8));const a1211_0x34c4=function(_0x4730b0,_0x55182a){_0x4730b0=_0x4730b0-0x0;let _0x34c4e0=a1211_0x5518[_0x4730b0];return _0x34c4e0;};const _0x12d8bc=a1211_0x34c4;'use strict';const _=require(_0x12d8bc('0x15')),uuid=require('uuid'),util=require(_0x12d8bc('0x1d')),logger=require(_0x12d8bc('0x16'))(_0x12d8bc('0x2')),Agent=function(_0x4ad94d,_0x3238ab,_0xc7e057,_0x2cff1a){const _0x391780=_0x12d8bc;this[_0x391780('0x0')]=uuid['v4'](),this['squeue']=_0x4ad94d,this['agent']=_0x3238ab,this[_0x391780('0x1c')]=_0xc7e057,this[_0x391780('0x2')]=_0x2cff1a,this[_0x391780('0x12')][_0x391780('0x6')](this[_0x391780('0x7')]['bind'](this),this[_0x391780('0x14')][_0x391780('0x17')](this)),this[_0x391780('0x12')]['on']('timeout',this[_0x391780('0x14')][_0x391780('0x17')](this)),this[_0x391780('0x12')]['on'](_0x391780('0x11'),this[_0x391780('0x10')]['bind'](this));};Agent['prototype'][_0x12d8bc('0x6')]=function(){const _0x1fba11=_0x12d8bc;this['squeue']['push'](this[_0x1fba11('0x7')][_0x1fba11('0x17')](this),this[_0x1fba11('0x14')][_0x1fba11('0x17')](this));},Agent['prototype'][_0x12d8bc('0x10')]=function(){this['handleTimeout'](!![]);},Agent[_0x12d8bc('0x9')]['handleRun']=function(){const _0x825f09=_0x12d8bc;logger['info']('[%s][AGENT]\x20try\x20with\x20%s',this[_0x825f09('0x12')]['id'],this[_0x825f09('0xa')]['id']),_[_0x825f09('0x8')](this[_0x825f09('0x1c')][_0x825f09('0x1a')][this['agent']['id']])?(logger[_0x825f09('0x5')](_0x825f09('0x3'),this[_0x825f09('0x12')]['id'],this['agent']['id']),setTimeout(this[_0x825f09('0x6')][_0x825f09('0x17')](this),0x3e8)):this[_0x825f09('0x2')][_0x825f09('0xb')]||util[_0x825f09('0x4')](this['squeue']['id'],this[_0x825f09('0x1c')][_0x825f09('0x1a')][this[_0x825f09('0xa')]['id']],this['squeue']['channel'],![])?(this[_0x825f09('0x1c')]['agents'][this[_0x825f09('0xa')]['id']][_0x825f09('0xe')]=!![],this[_0x825f09('0x1c')][_0x825f09('0x1a')][this[_0x825f09('0xa')]['id']][_0x825f09('0xf')]=undefined,util[_0x825f09('0x1b')](this[_0x825f09('0x0')],this[_0x825f09('0x12')]['id'],this[_0x825f09('0x1c')][_0x825f09('0x1a')][this[_0x825f09('0xa')]['id']],null,this['routing']),util[_0x825f09('0x13')](this[_0x825f09('0x12')]['id'],this[_0x825f09('0x1c')][_0x825f09('0x1a')][this[_0x825f09('0xa')]['id']],'RINGING'+(this[_0x825f09('0x2')][_0x825f09('0xb')]?_0x825f09('0x1'):''))):(logger[_0x825f09('0x5')]('[%s][AGENT]\x20agent\x20%s\x20is\x20not\x20available',this[_0x825f09('0x12')]['id'],this[_0x825f09('0xa')]['id']),setTimeout(this[_0x825f09('0x6')][_0x825f09('0x17')](this),0x3e8));},Agent[_0x12d8bc('0x9')]['handleTimeout']=function(_0x2844af){const _0x44d452=_0x12d8bc;if(_[_0x44d452('0x8')](this[_0x44d452('0x1c')][_0x44d452('0x1a')][this[_0x44d452('0xa')]['id']]))return logger[_0x44d452('0x5')](_0x44d452('0x3'),this[_0x44d452('0x12')]['id'],this[_0x44d452('0xa')]['id']);else logger['info'](_0x44d452('0xd'),this[_0x44d452('0x12')]['id'],this[_0x44d452('0xa')]['id']),util[_0x44d452('0xc')](this['notificationId'],this[_0x44d452('0x12')]['id'],this[_0x44d452('0x1c')][_0x44d452('0x1a')][this[_0x44d452('0xa')]['id']],null,this[_0x44d452('0x2')]),this[_0x44d452('0x1c')][_0x44d452('0x1a')][this[_0x44d452('0xa')]['id']]['busy']=![],this['realtime'][_0x44d452('0x1a')][this[_0x44d452('0xa')]['id']]['busyQueue']=undefined,util[_0x44d452('0x13')](this[_0x44d452('0x12')]['id'],this[_0x44d452('0x1c')][_0x44d452('0x1a')][this[_0x44d452('0xa')]['id']],_0x2844af?_0x44d452('0x19'):_0x44d452('0x18'));!_0x2844af&&setTimeout(this[_0x44d452('0x6')][_0x44d452('0x17')](this),0x3e8);};function agent(_0xb4b564,_0xe8857d,_0xf8171a,_0x5eb2e6){return new Agent(_0xb4b564,_0xe8857d,_0xf8171a,_0x5eb2e6);}module['exports']=agent; \ No newline at end of file diff --git a/server/services/routing/server/applications/strategy/beepall.js b/server/services/routing/server/applications/strategy/beepall.js index 5349ed7..39c7849 100644 --- a/server/services/routing/server/applications/strategy/beepall.js +++ b/server/services/routing/server/applications/strategy/beepall.js @@ -1 +1 @@ -const a1212_0x4707=['writeLog','lodash','TIMEOUT','busyQueue','[%s][QUEUE]\x20ALL\x20AGENTS\x20ARE\x20BUSY','length','bind','busy','uuid','queue','agents','Agents','push','info','prototype','[%s][QUEUE]\x20EMPTY','showNotification','notificationId','squeue','name','exports','hideNotification','realtime','handleRun','RINGING','routing','handleDrained','channel','isNil','../../../../../config/logger','STOP','[%s][QUEUE]\x20agent\x20skipped,\x20unknown\x20id\x20%s','handleTimeout','drained'];(function(_0x2a5fab,_0x4707b9){const _0x406b01=function(_0x28c04f){while(--_0x28c04f){_0x2a5fab['push'](_0x2a5fab['shift']());}};_0x406b01(++_0x4707b9);}(a1212_0x4707,0x175));const a1212_0x406b=function(_0x2a5fab,_0x4707b9){_0x2a5fab=_0x2a5fab-0x0;let _0x406b01=a1212_0x4707[_0x2a5fab];return _0x406b01;};const _0x292afa=a1212_0x406b;'use strict';const _=require(_0x292afa('0x2')),uuid=require(_0x292afa('0x9')),util=require('./util'),logger=require(_0x292afa('0x1e'))('routing'),Beepall=function(_0x28c04f,_0x4fb154,_0x4767b7,_0x3cc8c2){const _0x1b7aac=_0x292afa;this[_0x1b7aac('0x12')]=uuid['v4'](),this['squeue']=_0x28c04f,this['queue']=_0x4fb154,this[_0x1b7aac('0x17')]=_0x4767b7,this[_0x1b7aac('0x1a')]=_0x3cc8c2,this['squeue'][_0x1b7aac('0xd')](this[_0x1b7aac('0x18')]['bind'](this),this[_0x1b7aac('0x21')][_0x1b7aac('0x7')](this)),this[_0x1b7aac('0x13')]['on']('timeout',this['handleTimeout'][_0x1b7aac('0x7')](this)),this[_0x1b7aac('0x13')]['on'](_0x1b7aac('0x0'),this[_0x1b7aac('0x1b')]['bind'](this));};Beepall[_0x292afa('0xf')][_0x292afa('0xd')]=function(){const _0x875dac=_0x292afa;this['squeue']['push'](this[_0x875dac('0x18')]['bind'](this),this[_0x875dac('0x21')][_0x875dac('0x7')](this));},Beepall[_0x292afa('0xf')][_0x292afa('0x1b')]=function(){const _0x139a67=_0x292afa;this[_0x139a67('0x21')](!![]);},Beepall['prototype'][_0x292afa('0x18')]=function(){const _0x552406=_0x292afa;let _0x489e33=!![];if(!_[_0x552406('0x1d')](this[_0x552406('0xa')])&&!_['isNil'](this['queue'][_0x552406('0xc')])&&this[_0x552406('0xa')][_0x552406('0xc')][_0x552406('0x6')]>0x0){for(let _0x47187c=0x0,_0x58b65f;_0x47187c0x0){for(let _0x15c329=0x0,_0x225306;_0x15c3290x0&&_0x448f97[_0xb0531b+_0x382e06('0x1b')]>=_0x448f97[_0xb0531b+_0x382e06('0x0')])return writeLog(_0x111d62,_0x448f97,_0xb0531b[_0x382e06('0x21')]()+_0x382e06('0x26')),![];}return!![];},exports[_0x1248cb('0x1a')]=function(_0x5ebb47,_0xf6bc62,_0x5d60c2,_0x2534a9,_0xc73cc1){return sendNotification(!![],_0x5ebb47,_0xf6bc62,_0x5d60c2,_0x2534a9,_0xc73cc1);},exports[_0x1248cb('0x1d')]=function(_0x288395,_0x4ec2ad,_0x3afdf2,_0x5384c1,_0x1d4f1b){return sendNotification(![],_0x288395,_0x4ec2ad,_0x3afdf2,_0x5384c1,_0x1d4f1b);},exports[_0x1248cb('0x25')]=writeLog; \ No newline at end of file +const a1215_0x17e6=['[%s][QUEUE]\x20%s','error','routing','I\x20can\x27t\x20render\x20your\x20template','getMustacheRender','emit','name','notificationSound','undefined','CurrentCapacity','account','../../../../../rediscache','queue','writeLog','hideNotification','\x20interaction','message','OFFLINE','\x20MAXCAPACITY','format','notificationShake','split','Capacity','msg','toUpperCase','info','remove','../utils','user:%s','../../../../../config/logger','body','online','busy'];(function(_0x5ab24b,_0x17e66a){const _0x28e9cc=function(_0xb57c36){while(--_0xb57c36){_0x5ab24b['push'](_0x5ab24b['shift']());}};_0x28e9cc(++_0x17e66a);}(a1215_0x17e6,0xe6));const a1215_0x28e9=function(_0x5ab24b,_0x17e66a){_0x5ab24b=_0x5ab24b-0x0;let _0x28e9cc=a1215_0x17e6[_0x5ab24b];return _0x28e9cc;};const _0xb31353=a1215_0x28e9;'use strict';const util=require('util'),utils=require(_0xb31353('0x1c')),logger=require(_0xb31353('0x1e'))(_0xb31353('0x3')),{getSocket}=require(_0xb31353('0xc')),io=getSocket();function sendNotification(_0xb57c36,_0x573dbf,_0x50a78f,_0x44f41e,_0xd845da,_0x125899){const _0x30bddb=_0xb31353;io['to'](util[_0x30bddb('0x14')]('user:%s',_0x44f41e[_0x30bddb('0x7')]))[_0x30bddb('0x6')]('user:save',_0x44f41e);const _0x2e326f=_0x125899||{},_0x578b9d=_0x50a78f[_0x30bddb('0x16')]('.'),_0x1830f9={'uniqueid':_0x573dbf,'channel':_0x578b9d[0x0],'id':_0x578b9d[0x1],'title':_0x578b9d[0x0]+_0x30bddb('0x10'),'interactionId':_0x578b9d[0x2],'queue':_0xd845da?_0xd845da[_0x30bddb('0x7')]:null,'sound':_0x2e326f['account'][_0x30bddb('0x8')],'shake':_0x2e326f[_0x30bddb('0xb')][_0x30bddb('0x15')]};try{!_0x2e326f['body']&&(_0x2e326f[_0x30bddb('0x1f')]={});if(_0xd845da)_0x2e326f[_0x30bddb('0x1f')]['queue']=_0xd845da;else _0x2e326f[_0x30bddb('0x1f')][_0x30bddb('0xd')]&&delete _0x2e326f[_0x30bddb('0x1f')][_0x30bddb('0xd')];_0x1830f9[_0x30bddb('0x18')]=utils[_0x30bddb('0x5')](_0x2e326f[_0x30bddb('0xb')]['notificationTemplate'],_0x2e326f);}catch(_0x5bc51a){_0x1830f9[_0x30bddb('0x18')]=_0x30bddb('0x4'),logger[_0x30bddb('0x2')](util[_0x30bddb('0x14')](_0x30bddb('0x1'),_0x573dbf,_0x5bc51a[_0x30bddb('0x11')]));}io['to'](util[_0x30bddb('0x14')](_0x30bddb('0x1d'),_0x44f41e[_0x30bddb('0x7')]))['emit'](util[_0x30bddb('0x14')]('notification:%s',_0xb57c36?'save':_0x30bddb('0x1b')),_0x1830f9);}function writeLog(_0x35a016,_0x3d9f8f,_0x2d7270){const _0x2faa67=_0xb31353;return logger[_0x2faa67('0x1a')](util[_0x2faa67('0x14')]('[%s][QUEUE][AGENT:%s][STATUS:%s]',_0x35a016,_0x3d9f8f[_0x2faa67('0x7')],_0x2d7270));}exports['isAgentAvailable']=function(_0x2cd906,_0x557b1e,_0x1e271e,_0x2df56d){const _0xa28ff=_0xb31353;if(_0x557b1e[_0xa28ff('0x0')])return writeLog(_0x2cd906,_0x557b1e,'BUSY'),![];if(!_0x557b1e[_0xa28ff('0x20')])return writeLog(_0x2cd906,_0x557b1e,_0xa28ff('0x12')),![];if(_0x557b1e[_0x1e271e+'Pause'])return writeLog(_0x2cd906,_0x557b1e,'PAUSE'),![];if(_0x2df56d&&typeof _0x557b1e[_0x1e271e+_0xa28ff('0x17')]!==_0xa28ff('0x9')&&typeof _0x557b1e[_0x1e271e+_0xa28ff('0xa')]!==_0xa28ff('0x9')){if(_0x557b1e[_0x1e271e+_0xa28ff('0x17')]>0x0&&_0x557b1e[_0x1e271e+'CurrentCapacity']>=_0x557b1e[_0x1e271e+'Capacity'])return writeLog(_0x2cd906,_0x557b1e,_0x1e271e[_0xa28ff('0x19')]()+_0xa28ff('0x13')),![];}return!![];},exports['showNotification']=function(_0x3f8715,_0x5f2be2,_0x5641ec,_0x2ea027,_0x5f35b2){return sendNotification(!![],_0x3f8715,_0x5f2be2,_0x5641ec,_0x2ea027,_0x5f35b2);},exports[_0xb31353('0xf')]=function(_0x1437fb,_0x3538fe,_0x5e92f9,_0x4e292c,_0x21816f){return sendNotification(![],_0x1437fb,_0x3538fe,_0x5e92f9,_0x4e292c,_0x21816f);},exports[_0xb31353('0xe')]=writeLog; \ No newline at end of file diff --git a/server/services/routing/server/applications/system.js b/server/services/routing/server/applications/system.js index 27412e6..ad68334 100644 --- a/server/services/routing/server/applications/system.js +++ b/server/services/routing/server/applications/system.js @@ -1 +1 @@ -const a1216_0x3094=['[%s][SYSTEM]\x20%s','isEmpty','exec','stringify','[%s][SYSTEM]\x20commnad:\x20%s','replace','[%s][SYSTEM]\x20result\x20code:\x20%s','next','body','map','[%s][SYSTEM]\x20no\x20command\x20executed,\x20force\x20next','info','command\x20is\x20a\x20string\x20and\x20it\x20is\x20required','string','isNil','trim','../../../../config/logger','join','[%s][SYSTEM]\x20set\x20variable\x20%s:\x20%s','error','length','validate','lodash','routing','shelljs','consequence'];(function(_0x3f02df,_0x309424){const _0x3c0d43=function(_0x437777){while(--_0x437777){_0x3f02df['push'](_0x3f02df['shift']());}};_0x3c0d43(++_0x309424);}(a1216_0x3094,0x13f));const a1216_0x3c0d=function(_0x3f02df,_0x309424){_0x3f02df=_0x3f02df-0x0;let _0x3c0d43=a1216_0x3094[_0x3f02df];return _0x3c0d43;};const _0x43570f=a1216_0x3c0d;'use strict';const schema=require('validate'),sh=require(_0x43570f('0x11')),_=require(_0x43570f('0xf')),utils=require('./utils'),logger=require(_0x43570f('0x9'))(_0x43570f('0x10')),system=schema({'command':{'type':_0x43570f('0x6'),'required':!![],'message':_0x43570f('0x5')}});exports[_0x43570f('0x12')]=function(_0x437777,_0x54907b){return function(_0xb3706e){const _0x18be7c=a1216_0x3c0d;try{const _0x2a3f5={'command':_0x54907b[0x0]},_0x5338f3=system[_0x18be7c('0xe')](_0x2a3f5,{'typecast':!![]});if(_0x5338f3[_0x18be7c('0xd')])logger[_0x18be7c('0xc')]('[%s][SYSTEM]\x20%s',_0x437777,_[_0x18be7c('0x2')](_0x5338f3,'message')[_0x18be7c('0xa')](',\x20')),logger[_0x18be7c('0x4')](_0x18be7c('0x3'),_0x437777),_0xb3706e[_0x18be7c('0x0')]();else{const _0x2a4fe2=this,_0x808d43=utils['getMustacheRender'](_0x54907b[0x0],this);logger[_0x18be7c('0x4')](_0x18be7c('0x17'),_0x437777,_0x808d43),sh[_0x18be7c('0x15')](_[_0x18be7c('0x8')](_0x808d43),function(_0x4171bb,_0xf28634){const _0x22c1e8=_0x18be7c;logger[_0x22c1e8('0x4')](_0x22c1e8('0x19'),_0x437777,_0x4171bb);if(_0x4171bb==0x0){const _0x23bcb5=_0xf28634[_0x22c1e8('0x18')](/(\r\n|\n|\r)/gm,'');_[_0x22c1e8('0x7')](_0x54907b[0x1])||_[_0x22c1e8('0x14')](_0x54907b[0x1])?(logger[_0x22c1e8('0x4')]('[%s][SYSTEM]\x20no\x20variable',_0x437777),_0x2a4fe2['body'][_0x54907b[0x1]]=_0x23bcb5):(logger[_0x22c1e8('0x4')](_0x22c1e8('0xb'),_0x437777,_0x54907b[0x1],_0x23bcb5),_0x2a4fe2[_0x22c1e8('0x1')][_0x54907b[0x1]]=_0x23bcb5);}_0xb3706e['next']();});}}catch(_0x8ab643){logger[_0x18be7c('0xc')](_0x18be7c('0x13'),_0x437777,_['isObject'](_0x8ab643)?JSON[_0x18be7c('0x16')](_0x8ab643):_0x8ab643),logger[_0x18be7c('0x4')](_0x18be7c('0x3'),_0x437777),_0xb3706e['next']();}};}; \ No newline at end of file +const a1216_0x2d28=['body','validate','string','[%s][SYSTEM]\x20%s','command\x20is\x20a\x20string\x20and\x20it\x20is\x20required','[%s][SYSTEM]\x20set\x20variable\x20%s:\x20%s','info','join','isEmpty','routing','./utils','error','isObject','../../../../config/logger','[%s][SYSTEM]\x20no\x20variable','next','trim','exec','length','[%s][SYSTEM]\x20no\x20command\x20executed,\x20force\x20next','stringify','[%s][SYSTEM]\x20result\x20code:\x20%s','replace','[%s][SYSTEM]\x20commnad:\x20%s','getMustacheRender'];(function(_0x256585,_0x2d28c1){const _0x33fc0b=function(_0x36e89f){while(--_0x36e89f){_0x256585['push'](_0x256585['shift']());}};_0x33fc0b(++_0x2d28c1);}(a1216_0x2d28,0x113));const a1216_0x33fc=function(_0x256585,_0x2d28c1){_0x256585=_0x256585-0x0;let _0x33fc0b=a1216_0x2d28[_0x256585];return _0x33fc0b;};const _0x52500a=a1216_0x33fc;'use strict';const schema=require(_0x52500a('0x1')),sh=require('shelljs'),_=require('lodash'),utils=require(_0x52500a('0xa')),logger=require(_0x52500a('0xd'))(_0x52500a('0x9')),system=schema({'command':{'type':_0x52500a('0x2'),'required':!![],'message':_0x52500a('0x4')}});exports['consequence']=function(_0x36e89f,_0x14351a){return function(_0x4ff366){const _0x5150e5=a1216_0x33fc;try{const _0x10ed7c={'command':_0x14351a[0x0]},_0x316d45=system[_0x5150e5('0x1')](_0x10ed7c,{'typecast':!![]});if(_0x316d45[_0x5150e5('0x12')])logger[_0x5150e5('0xb')](_0x5150e5('0x3'),_0x36e89f,_['map'](_0x316d45,'message')[_0x5150e5('0x7')](',\x20')),logger[_0x5150e5('0x6')](_0x5150e5('0x13'),_0x36e89f),_0x4ff366[_0x5150e5('0xf')]();else{const _0x3887ec=this,_0x58d1a3=utils[_0x5150e5('0x18')](_0x14351a[0x0],this);logger[_0x5150e5('0x6')](_0x5150e5('0x17'),_0x36e89f,_0x58d1a3),sh[_0x5150e5('0x11')](_[_0x5150e5('0x10')](_0x58d1a3),function(_0x299c52,_0x640180){const _0x3e0756=_0x5150e5;logger['info'](_0x3e0756('0x15'),_0x36e89f,_0x299c52);if(_0x299c52==0x0){const _0x573c88=_0x640180[_0x3e0756('0x16')](/(\r\n|\n|\r)/gm,'');_['isNil'](_0x14351a[0x1])||_[_0x3e0756('0x8')](_0x14351a[0x1])?(logger[_0x3e0756('0x6')](_0x3e0756('0xe'),_0x36e89f),_0x3887ec[_0x3e0756('0x0')][_0x14351a[0x1]]=_0x573c88):(logger[_0x3e0756('0x6')](_0x3e0756('0x5'),_0x36e89f,_0x14351a[0x1],_0x573c88),_0x3887ec[_0x3e0756('0x0')][_0x14351a[0x1]]=_0x573c88);}_0x4ff366['next']();});}}catch(_0x4c6287){logger['error'](_0x5150e5('0x3'),_0x36e89f,_[_0x5150e5('0xc')](_0x4c6287)?JSON[_0x5150e5('0x14')](_0x4c6287):_0x4c6287),logger['info'](_0x5150e5('0x13'),_0x36e89f),_0x4ff366[_0x5150e5('0xf')]();}};}; \ No newline at end of file diff --git a/server/services/routing/server/applications/tag.js b/server/services/routing/server/applications/tag.js index caad2ff..f887d18 100644 --- a/server/services/routing/server/applications/tag.js +++ b/server/services/routing/server/applications/tag.js @@ -1 +1 @@ -const a1217_0x2e88=['../../rpc/faxInteraction','channel','routing','isObject','then','message','validate','Interaction','join','next','[%s][TAG]\x20tag\x20\x22%s\x22\x20added\x20to\x20%s\x20interaction\x20%s','consequence','info','stringify','[%s][TAG]\x20%s','error','../../rpc/whatsappInteraction','lodash','../../rpc/chatInteraction','../../../../config/logger','finally','number','addTags','interaction','../../rpc/mailInteraction','TagId\x20is\x20a\x20string\x20and\x20it\x20is\x20required','catch'];(function(_0xb08405,_0x2e8832){const _0x4cf52b=function(_0x532369){while(--_0x532369){_0xb08405['push'](_0xb08405['shift']());}};_0x4cf52b(++_0x2e8832);}(a1217_0x2e88,0x184));const a1217_0x4cf5=function(_0xb08405,_0x2e8832){_0xb08405=_0xb08405-0x0;let _0x4cf52b=a1217_0x2e88[_0xb08405];return _0x4cf52b;};const _0x58857a=a1217_0x4cf5;'use strict';const schema=require(_0x58857a('0x17')),_=require(_0x58857a('0x7')),rpc={'chatInteraction':require(_0x58857a('0x8')),'openchannelInteraction':require('../../rpc/openchannelInteraction'),'smsInteraction':require('../../rpc/smsInteraction'),'mailInteraction':require(_0x58857a('0xe')),'faxInteraction':require(_0x58857a('0x11')),'whatsappInteraction':require(_0x58857a('0x6'))},logger=require(_0x58857a('0x9'))(_0x58857a('0x13')),tag=schema({'tag':{'type':_0x58857a('0xb'),'required':!![],'message':_0x58857a('0xf')}});exports[_0x58857a('0x1')]=function(_0x532369,_0xb8614f,_0x1b0da8,_0x2ea126){return function(_0x1bc95c){const _0x3da1ad=a1217_0x4cf5;try{const _0x841576={'tag':_0xb8614f[0x0]},_0xf48d4f=tag[_0x3da1ad('0x17')](_0x841576,{'typecast':!![]});if(_0xf48d4f['length'])logger[_0x3da1ad('0x5')](_0x3da1ad('0x4'),_0x532369,_['map'](_0xf48d4f,_0x3da1ad('0x16'))[_0x3da1ad('0x19')](',\x20')),logger['info']('[%s][TAG]\x20no\x20tags\x20saved,\x20force\x20next',_0x532369),_0x1bc95c[_0x3da1ad('0x1a')]();else{const _0x99bd13={'ids':[_0xb8614f[0x0]]};rpc[_0x2ea126[_0x3da1ad('0x12')]+'Interaction']&&rpc[_0x2ea126['channel']+_0x3da1ad('0x18')][_0x3da1ad('0xc')](_0x2ea126[_0x3da1ad('0xd')]['id'],_0x99bd13)[_0x3da1ad('0x15')](function(){const _0x42ec84=_0x3da1ad;logger[_0x42ec84('0x2')](_0x42ec84('0x0'),_0x532369,_0xb8614f[0x1],_0x2ea126[_0x42ec84('0x12')],_0x2ea126[_0x42ec84('0xd')]['id']);})[_0x3da1ad('0x10')](function(_0x39f19d){const _0x158746=_0x3da1ad;logger[_0x158746('0x5')](_0x158746('0x4'),_0x532369,JSON[_0x158746('0x3')](_0x39f19d)),logger[_0x158746('0x2')]('[%s][TAG]\x20no\x20tags\x20saved,\x20force\x20next',_0x532369);})[_0x3da1ad('0xa')](function(){const _0x3df106=_0x3da1ad;_0x1bc95c[_0x3df106('0x1a')]();});}}catch(_0x2e089c){logger['error']('[%s][TAG]\x20%s',_0x532369,_[_0x3da1ad('0x14')](_0x2e089c)?JSON['stringify'](_0x2e089c):_0x2e089c),logger[_0x3da1ad('0x2')]('[%s][TAG]\x20no\x20tags\x20saved,\x20force\x20next',_0x532369),_0x1bc95c[_0x3da1ad('0x1a')]();}};}; \ No newline at end of file +const a1217_0x57a1=['join','[%s][TAG]\x20%s','addTags','../../rpc/mailInteraction','next','map','length','../../rpc/chatInteraction','[%s][TAG]\x20tag\x20\x22%s\x22\x20added\x20to\x20%s\x20interaction\x20%s','../../../../config/logger','Interaction','channel','[%s][TAG]\x20no\x20tags\x20saved,\x20force\x20next','interaction','then','stringify','error','lodash','../../rpc/faxInteraction','TagId\x20is\x20a\x20string\x20and\x20it\x20is\x20required','info','catch','validate','finally'];(function(_0xf02a92,_0x57a1d9){const _0x1d2a08=function(_0x49e83e){while(--_0x49e83e){_0xf02a92['push'](_0xf02a92['shift']());}};_0x1d2a08(++_0x57a1d9);}(a1217_0x57a1,0x146));const a1217_0x1d2a=function(_0xf02a92,_0x57a1d9){_0xf02a92=_0xf02a92-0x0;let _0x1d2a08=a1217_0x57a1[_0xf02a92];return _0x1d2a08;};const _0x3f1be8=a1217_0x1d2a;'use strict';const schema=require(_0x3f1be8('0x8')),_=require(_0x3f1be8('0x3')),rpc={'chatInteraction':require(_0x3f1be8('0x11')),'openchannelInteraction':require('../../rpc/openchannelInteraction'),'smsInteraction':require('../../rpc/smsInteraction'),'mailInteraction':require(_0x3f1be8('0xd')),'faxInteraction':require(_0x3f1be8('0x4')),'whatsappInteraction':require('../../rpc/whatsappInteraction')},logger=require(_0x3f1be8('0x13'))('routing'),tag=schema({'tag':{'type':'number','required':!![],'message':_0x3f1be8('0x5')}});exports['consequence']=function(_0x49e83e,_0x53da54,_0x599fe7,_0xd213c1){return function(_0x1bad86){const _0x4dd7d1=a1217_0x1d2a;try{const _0x1fe360={'tag':_0x53da54[0x0]},_0x49817f=tag[_0x4dd7d1('0x8')](_0x1fe360,{'typecast':!![]});if(_0x49817f[_0x4dd7d1('0x10')])logger[_0x4dd7d1('0x2')]('[%s][TAG]\x20%s',_0x49e83e,_[_0x4dd7d1('0xf')](_0x49817f,'message')[_0x4dd7d1('0xa')](',\x20')),logger[_0x4dd7d1('0x6')](_0x4dd7d1('0x16'),_0x49e83e),_0x1bad86[_0x4dd7d1('0xe')]();else{const _0x45fffe={'ids':[_0x53da54[0x0]]};rpc[_0xd213c1['channel']+_0x4dd7d1('0x14')]&&rpc[_0xd213c1[_0x4dd7d1('0x15')]+_0x4dd7d1('0x14')][_0x4dd7d1('0xc')](_0xd213c1[_0x4dd7d1('0x17')]['id'],_0x45fffe)[_0x4dd7d1('0x0')](function(){const _0x2fc5b3=_0x4dd7d1;logger[_0x2fc5b3('0x6')](_0x2fc5b3('0x12'),_0x49e83e,_0x53da54[0x1],_0xd213c1[_0x2fc5b3('0x15')],_0xd213c1['interaction']['id']);})[_0x4dd7d1('0x7')](function(_0x9d8363){const _0x1797e3=_0x4dd7d1;logger[_0x1797e3('0x2')](_0x1797e3('0xb'),_0x49e83e,JSON[_0x1797e3('0x1')](_0x9d8363)),logger[_0x1797e3('0x6')](_0x1797e3('0x16'),_0x49e83e);})[_0x4dd7d1('0x9')](function(){const _0x5a39b4=_0x4dd7d1;_0x1bad86[_0x5a39b4('0xe')]();});}}catch(_0x416bdc){logger[_0x4dd7d1('0x2')]('[%s][TAG]\x20%s',_0x49e83e,_['isObject'](_0x416bdc)?JSON[_0x4dd7d1('0x1')](_0x416bdc):_0x416bdc),logger['info'](_0x4dd7d1('0x16'),_0x49e83e),_0x1bad86[_0x4dd7d1('0xe')]();}};}; \ No newline at end of file diff --git a/server/services/routing/server/applications/utils.js b/server/services/routing/server/applications/utils.js index d29d0d9..109a38a 100644 --- a/server/services/routing/server/applications/utils.js +++ b/server/services/routing/server/applications/utils.js @@ -1 +1 @@ -const a1218_0xea67=['message','body','account','contact','render','mustache','interaction','merge'];(function(_0x3f06c1,_0xea6715){const _0x553e80=function(_0x14c3b5){while(--_0x14c3b5){_0x3f06c1['push'](_0x3f06c1['shift']());}};_0x553e80(++_0xea6715);}(a1218_0xea67,0x18b));const a1218_0x553e=function(_0x3f06c1,_0xea6715){_0x3f06c1=_0x3f06c1-0x0;let _0x553e80=a1218_0xea67[_0x3f06c1];return _0x553e80;};const _0x5ad259=a1218_0x553e;'use strict';const Mustache=require(_0x5ad259('0x2')),_=require('lodash');module['exports']={'getMustacheRender':function(_0x14c3b5,_0x2de343){const _0x336534=_0x5ad259;return Mustache[_0x336534('0x1')](_0x14c3b5,_[_0x336534('0x4')](_0x2de343[_0x336534('0x6')],{'contact':_0x2de343[_0x336534('0x0')],'message':_0x2de343[_0x336534('0x5')],'account':_0x2de343[_0x336534('0x7')],'interaction':_0x2de343[_0x336534('0x3')],'list':_0x2de343['list']}))||'';}}; \ No newline at end of file +const a1218_0x4e78=['body','lodash','merge','contact','message','mustache','exports','list','render'];(function(_0x24d76a,_0x4e7861){const _0x592321=function(_0x1701b3){while(--_0x1701b3){_0x24d76a['push'](_0x24d76a['shift']());}};_0x592321(++_0x4e7861);}(a1218_0x4e78,0x1db));const a1218_0x5923=function(_0x24d76a,_0x4e7861){_0x24d76a=_0x24d76a-0x0;let _0x592321=a1218_0x4e78[_0x24d76a];return _0x592321;};const _0x40e02d=a1218_0x5923;'use strict';const Mustache=require(_0x40e02d('0x7')),_=require(_0x40e02d('0x3'));module[_0x40e02d('0x8')]={'getMustacheRender':function(_0x1701b3,_0x28ddcd){const _0x1e9d15=_0x40e02d;return Mustache[_0x1e9d15('0x1')](_0x1701b3,_[_0x1e9d15('0x4')](_0x28ddcd[_0x1e9d15('0x2')],{'contact':_0x28ddcd[_0x1e9d15('0x5')],'message':_0x28ddcd[_0x1e9d15('0x6')],'account':_0x28ddcd['account'],'interaction':_0x28ddcd['interaction'],'list':_0x28ddcd[_0x1e9d15('0x0')]}))||'';}}; \ No newline at end of file diff --git a/server/services/routing/server/index.js b/server/services/routing/server/index.js index 11269f5..3359c73 100644 --- a/server/services/routing/server/index.js +++ b/server/services/routing/server/index.js @@ -1 +1 @@ -const a1219_0x3518=['end','openchannelQueues','../rpc/faxQueueReport','No\x20applications\x20to\x20execute','openchannelQueuesWaitingInteractions','routing\x20is\x20empty','intervals','Push\x20new\x20rule','../rpc/mailQueueReport','agent\x20not\x20found','amazonlex','error\x20update\x20queue\x20report','stringify','updateRealtime','on\x20interval','applications','autoreply','join','lodash','available','interaction','error','../rpc/chatQueueReport','whatsappQueuesWaitingInteractions','CurrentCapacity','message\x20is\x20empty','./interval','priority','interval','./applications/','IntervalId','slice','../../../config/logger','app','chatQueuesWaitingInteractions','../lib/rule-engine','QueueReport','Applications\x20executed','../rpc/whatsappQueueReport','server','loggedIn','complete','values','busyQueue','emit','util','name','mailQueues','smsQueuesWaitingInteractions','update','log','dialogflowv2','catch','Please\x20create\x20a\x20new\x20file\x20under','isNil','stack','map','length','undefined','consequence','channel','listen','matchPath','agent','agents','routing','.js','waiting','UserId','whatsappQueues','chatQueues','busy','http','execute','split','paused','rules','../rpc/smsQueueReport','info','faxQueues','Intervals','push','message','appdata','existsSync','127.0.0.1','isArray','%s.%s.%s','format','TagId','capacity'];(function(_0xb82a1d,_0x3518d6){const _0x51168e=function(_0x5491d5){while(--_0x5491d5){_0xb82a1d['push'](_0xb82a1d['shift']());}};_0x51168e(++_0x3518d6);}(a1219_0x3518,0xbc));const a1219_0x5116=function(_0xb82a1d,_0x3518d6){_0xb82a1d=_0xb82a1d-0x0;let _0x51168e=a1219_0x3518[_0xb82a1d];return _0x51168e;};const _0x34a483=a1219_0x5116;'use strict';const _=require(_0x34a483('0xc')),util=require(_0x34a483('0x27')),path=require('path'),fs=require('fs'),jayson=require('jayson/promise'),logger=require(_0x34a483('0x1a'))(_0x34a483('0x3b')),rpc={'openchannelQueueReport':require('../rpc/openchannelQueueReport'),'mailQueueReport':require(_0x34a483('0x2')),'chatQueueReport':require(_0x34a483('0x10')),'smsQueueReport':require(_0x34a483('0x47')),'faxQueueReport':require(_0x34a483('0x57')),'whatsappQueueReport':require(_0x34a483('0x20'))},RuleEngine=require(_0x34a483('0x1d'));function getId(_0x5491d5,_0x387df6,_0x143068){const _0x5277d6=_0x34a483;return util[_0x5277d6('0x52')](_0x5277d6('0x51'),_0x5491d5,_0x387df6||0x0,_0x143068||0x0);}function getIntervals(_0x39f51e,_0xc9f7d0){const _0x2beda6=_0x34a483;let _0x47b0bd=[];if(!_['isNil'](_0xc9f7d0[_0x2beda6('0x18')])&&!_[_0x2beda6('0x30')](_0x39f51e[_0xc9f7d0['IntervalId']])&&!_[_0x2beda6('0x30')](_0x39f51e[_0xc9f7d0[_0x2beda6('0x18')]][_0x2beda6('0x4a')]))_0x47b0bd=_[_0x2beda6('0x32')](_0x39f51e[_0xc9f7d0[_0x2beda6('0x18')]][_0x2beda6('0x4a')],_0x2beda6('0x16'));else!_['isNil'](_0xc9f7d0[_0x2beda6('0x16')])&&(_0x47b0bd=[_0xc9f7d0['interval']]);return _0x47b0bd;}exports[_0x34a483('0x37')]=function(_0x1f9219){const _0x5bafd8=_0x34a483;return _0x1f9219[_0x5bafd8('0x46')]={},new Promise(function(_0x37ecaf,_0x21432f){const _0x5d5ed1=_0x5bafd8,_0x3d9e7e={'Start':function(_0x544bfa){const _0x10251f=this;return new Promise(function(_0x403a2a,_0x2c3248){const _0x5b308c=a1219_0x5116;if(_0x544bfa)try{const _0xe4d0ee=[],_0x2cdce7=getId(_0x544bfa['channel'],_0x544bfa[_0x5b308c('0x4c')]?_0x544bfa[_0x5b308c('0x4c')]['id']:0x0,_0x544bfa[_0x5b308c('0xe')]?_0x544bfa[_0x5b308c('0xe')]['id']:0x0);if(_0x544bfa['applications']&&_[_0x5b308c('0x50')](_0x544bfa[_0x5b308c('0x9')])&&_0x544bfa[_0x5b308c('0x9')][_0x5b308c('0x33')]){for(let _0x3e66a7=0x0;_0x3e66a7<_0x544bfa[_0x5b308c('0x9')][_0x5b308c('0x33')];_0x3e66a7+=0x1){const _0x2fdf90=_0x544bfa[_0x5b308c('0x9')][_0x3e66a7];if(fs[_0x5b308c('0x4e')](path['join'](__dirname,_0x5b308c('0x9'),_0x2fdf90[_0x5b308c('0x1b')]+_0x5b308c('0x3c')))){let _0x30add8=[];switch(_0x2fdf90[_0x5b308c('0x1b')]['toLowerCase']()){case _0x5b308c('0xa'):{const _0x4ecd9b=_0x2fdf90[_0x5b308c('0x4d')][_0x5b308c('0x44')](',');_0x30add8[_0x5b308c('0x4b')](_0x4ecd9b[0x0]),_0x30add8[_0x5b308c('0x4b')](_0x4ecd9b[_0x5b308c('0x19')](0x1,_0x4ecd9b[_0x5b308c('0x33')])[_0x5b308c('0xb')](','));}break;case'dialogflow':{const _0x5d6ea2=_0x2fdf90['appdata'][_0x5b308c('0x44')](',');_0x30add8[_0x5b308c('0x4b')](_0x5d6ea2[0x0]),_0x30add8[_0x5b308c('0x4b')](_0x5d6ea2[0x1]),_0x30add8[_0x5b308c('0x4b')](_0x5d6ea2['slice'](0x2,_0x5d6ea2[_0x5b308c('0x33')])['join'](','));}break;case _0x5b308c('0x2d'):{const _0x2dcca4=_0x2fdf90[_0x5b308c('0x4d')][_0x5b308c('0x44')](',');_0x30add8[_0x5b308c('0x4b')](_0x2dcca4[0x0]),_0x30add8['push'](_0x2dcca4[0x1]),_0x30add8[_0x5b308c('0x4b')](_0x2dcca4[0x2]),_0x30add8[_0x5b308c('0x4b')](_0x2dcca4[0x3]),_0x30add8[_0x5b308c('0x4b')](_0x2dcca4[_0x5b308c('0x19')](0x4,_0x2dcca4[_0x5b308c('0x33')])[_0x5b308c('0xb')](','));}break;case _0x5b308c('0x4'):{const _0x241e01=_0x2fdf90[_0x5b308c('0x4d')][_0x5b308c('0x44')](',');_0x30add8[_0x5b308c('0x4b')](_0x241e01[0x0]),_0x30add8[_0x5b308c('0x4b')](_0x241e01[0x1]),_0x30add8['push'](_0x241e01[0x2]),_0x30add8[_0x5b308c('0x4b')](_0x241e01[0x3]),_0x30add8[_0x5b308c('0x4b')](_0x241e01[_0x5b308c('0x19')](0x4,_0x241e01['length'])[_0x5b308c('0xb')](','));}break;case'message':_0x30add8[_0x5b308c('0x4b')](_0x2fdf90[_0x5b308c('0x4d')]);break;case'tag':_0x30add8['push'](_0x2fdf90[_0x5b308c('0x53')]),_0x30add8['push'](_0x2fdf90[_0x5b308c('0x4d')]);break;default:_0x30add8=_[_0x5b308c('0x30')](_0x2fdf90[_0x5b308c('0x4d')])?[]:_0x2fdf90['appdata'][_0x5b308c('0x44')](',');}const _0x513589={'id':util[_0x5b308c('0x52')]('%s:%s:%s',_0x2cdce7,_0x2fdf90['id'],_0x2fdf90['app']),'condition':require(_0x5b308c('0x14'))['condition'](_0x2cdce7,getIntervals(_0x1f9219['intervals'],_0x2fdf90),_0x1f9219),'consequence':require(_0x5b308c('0x17')+_0x2fdf90['app'])[_0x5b308c('0x35')](_0x2cdce7,_0x30add8,_0x1f9219,_0x544bfa),'p':_0x2fdf90[_0x5b308c('0x15')]||0x0};logger['info'](_0x5b308c('0x1'),_0x513589['id'],_0x5b308c('0x8'),getIntervals(_0x1f9219[_0x5b308c('0x0')],_0x2fdf90)[_0x5b308c('0xb')]('\x20|\x20')),_0xe4d0ee['push'](_0x513589);}else logger[_0x5b308c('0xf')](_0x5b308c('0x2f'),path[_0x5b308c('0xb')](__dirname,_0x5b308c('0x9'),_0x2fdf90['app']+_0x5b308c('0x3c')));}return _0x1f9219[_0x5b308c('0x46')][_0x2cdce7]=new RuleEngine(_0xe4d0ee),_0x1f9219['rules'][_0x2cdce7][_0x5b308c('0x43')](_0x544bfa,function(_0x987876){const _0x3347c6=_0x5b308c;logger['info'](_0x3347c6('0x1f'),JSON[_0x3347c6('0x6')](_0x987876[_0x3347c6('0x38')])),_0x1f9219[_0x3347c6('0x46')][_0x2cdce7]&&_0x1f9219['rules'][_0x2cdce7][_0x3347c6('0x26')](_0x3347c6('0x23'));}),_0x403a2a({'code':0xc8,'message':_0x544bfa});}else return logger[_0x5b308c('0x48')](_0x5b308c('0x58')),_0x403a2a({'code':0xc8,'message':_0x544bfa});}catch(_0x2de442){return logger[_0x5b308c('0xf')](_0x2de442['stack']),_0x2c3248(_0x10251f[_0x5b308c('0xf')](0x1f4,_0x2de442));}return _0x2c3248(_0x5b308c('0x5a'));});},'AcceptMessage':function(_0x4a6f9f){const _0x31b826=this;return new Promise(function(_0x5303b6,_0x138da2){const _0x50aaa5=a1219_0x5116;if(_0x4a6f9f[_0x50aaa5('0x4c')]&&_0x4a6f9f[_0x50aaa5('0x4c')]['id'])try{const _0x495a7f=getId(_0x4a6f9f[_0x50aaa5('0x36')],_0x4a6f9f[_0x50aaa5('0x4c')]?_0x4a6f9f[_0x50aaa5('0x4c')]['id']:0x0,_0x4a6f9f[_0x50aaa5('0xe')]?_0x4a6f9f[_0x50aaa5('0xe')]['id']:0x0);return _0x1f9219[_0x50aaa5('0x46')][_0x495a7f]&&(_0x1f9219['rules'][_0x495a7f][_0x50aaa5('0x26')](_0x50aaa5('0x55')),rpc[_0x4a6f9f[_0x50aaa5('0x36')]+_0x50aaa5('0x1e')]&&rpc[_0x4a6f9f[_0x50aaa5('0x36')]+_0x50aaa5('0x1e')][_0x50aaa5('0x2b')](_0x495a7f,{'UserId':_0x4a6f9f['message'][_0x50aaa5('0x3e')]})[_0x50aaa5('0x2e')](function(){const _0x12bca9=_0x50aaa5;logger[_0x12bca9('0xf')](_0x12bca9('0x5'));})),_0x5303b6({'code':0xc8,'message':_0x4a6f9f});}catch(_0x41691e){return logger[_0x50aaa5('0xf')](_0x41691e[_0x50aaa5('0x31')]),_0x138da2(_0x31b826[_0x50aaa5('0xf')](0x1f4,_0x41691e));}return logger[_0x50aaa5('0xf')](_0x50aaa5('0x13')),_0x138da2(_0x31b826['error'](0x1f4,_0x50aaa5('0x13')));});},'RejectMessage':function(_0x5e4809){const _0x41d701=this;return new Promise(function(_0x5d155e,_0x40eacd){const _0x4c79e5=a1219_0x5116;if(_0x5e4809[_0x4c79e5('0x39')]&&_0x5e4809[_0x4c79e5('0x39')]['id'])try{return _0x1f9219[_0x4c79e5('0x3a')][_0x5e4809['agent']['id']]&&(_0x1f9219[_0x4c79e5('0x3a')][_0x5e4809[_0x4c79e5('0x39')]['id']][_0x4c79e5('0x41')]=![],_0x1f9219['agents'][_0x5e4809[_0x4c79e5('0x39')]['id']][_0x4c79e5('0x25')]=undefined),_0x5d155e({'code':0xc8,'message':_0x5e4809});}catch(_0x29f04c){return logger[_0x4c79e5('0xf')](_0x29f04c[_0x4c79e5('0x31')]),_0x40eacd(_0x41d701[_0x4c79e5('0xf')](0x1f4,_0x29f04c));}return logger['error'](_0x4c79e5('0x13')),_0x40eacd(_0x41d701[_0x4c79e5('0xf')](0x1f4,'message\x20is\x20empty'));});},'AbandonInteraction':function(_0x12bbca){const _0x45cb6d=this;return new Promise(function(_0x4c787a,_0x2574e4){const _0x33116f=a1219_0x5116;if(_0x12bbca[_0x33116f('0x36')]&&_0x12bbca['interaction']&&_0x12bbca['interaction']['id'])try{const _0x1ee7e7=getId(_0x12bbca['channel'],_0x12bbca['message']?_0x12bbca[_0x33116f('0x4c')]['id']:0x0,_0x12bbca[_0x33116f('0xe')]?_0x12bbca[_0x33116f('0xe')]['id']:0x0);return _0x1f9219[_0x33116f('0x46')][_0x1ee7e7]&&_0x1f9219[_0x33116f('0x46')][_0x1ee7e7]['emit'](_0x33116f('0x55')),_0x4c787a({'code':0xc8,'message':_0x12bbca});}catch(_0x270bf5){return logger['error'](_0x270bf5[_0x33116f('0x31')]),_0x2574e4(_0x45cb6d['error'](0x1f4,_0x270bf5));}return logger[_0x33116f('0xf')]('message\x20is\x20empty'),_0x2574e4(_0x45cb6d['error'](0x1f4,_0x33116f('0x13')));});},'AgentCapacity':function(_0x2ba9c5){const _0x53c47b=this;return new Promise(function(_0xd37752,_0x12e5ca){const _0x4e85b8=a1219_0x5116;if(typeof _0x1f9219['agents'][_0x2ba9c5['id']]!==_0x4e85b8('0x34')){for(const _0x277761 in _0x2ba9c5['capacity']){typeof _0x2ba9c5[_0x4e85b8('0x54')][_0x277761]!==_0x4e85b8('0x34')&&(typeof _0x1f9219[_0x4e85b8('0x3a')][_0x2ba9c5['id']][_0x277761+_0x4e85b8('0x12')]!==_0x4e85b8('0x34')&&(_0x1f9219[_0x4e85b8('0x3a')][_0x2ba9c5['id']][_0x277761+_0x4e85b8('0x12')]=parseInt(_0x2ba9c5[_0x4e85b8('0x54')][_0x277761],0xa)));}return _0x1f9219[_0x4e85b8('0x3a')][_0x2ba9c5['id']][_0x4e85b8('0x7')](),_0xd37752({'code':0xc8,'message':_0x1f9219[_0x4e85b8('0x3a')][_0x2ba9c5['id']]});}else return _0x12e5ca(_0x53c47b[_0x4e85b8('0xf')](0x1f4,_0x4e85b8('0x3')));});},'Agents':function(){return new Promise(function(_0x5706e9){const _0x5a818f=a1219_0x5116,_0x3ac7dd=_['values'](_0x1f9219[_0x5a818f('0x3a')]);_0x5706e9({'count':_0x3ac7dd[_0x5a818f('0x33')],'rows':_0x3ac7dd});});},'ChatQueues':function(){return new Promise(function(_0x2fafef){const _0xdcc25c=a1219_0x5116,_0x468ef9=[];for(const _0x5154a5 in _0x1f9219['chatQueues']){if(typeof _0x1f9219['chatQueues'][_0x5154a5]!=='undefined'){const _0x59e97f=_0x1f9219[_0xdcc25c('0x40')][_0x5154a5],_0x3a8306={'id':_0x59e97f['id'],'available':_0x59e97f[_0xdcc25c('0xd')],'loggedIn':_0x59e97f[_0xdcc25c('0x22')],'name':_0x59e97f[_0xdcc25c('0x28')],'paused':_0x59e97f['paused'],'waiting':_0x59e97f[_0xdcc25c('0x3d')]};_0x468ef9[_0xdcc25c('0x4b')](_0x3a8306);}}_0x2fafef({'count':_0x468ef9[_0xdcc25c('0x33')],'rows':_0x468ef9});});},'MailQueues':function(){return new Promise(function(_0x277ddc){const _0x3b8808=a1219_0x5116,_0x3ec165=[];for(const _0x358854 in _0x1f9219[_0x3b8808('0x29')]){if(typeof _0x1f9219[_0x3b8808('0x29')][_0x358854]!==_0x3b8808('0x34')){const _0x59201f=_0x1f9219[_0x3b8808('0x29')][_0x358854],_0x25b724={'id':_0x59201f['id'],'available':_0x59201f[_0x3b8808('0xd')],'loggedIn':_0x59201f[_0x3b8808('0x22')],'name':_0x59201f[_0x3b8808('0x28')],'paused':_0x59201f[_0x3b8808('0x45')],'waiting':_0x59201f[_0x3b8808('0x3d')]};_0x3ec165[_0x3b8808('0x4b')](_0x25b724);}}_0x277ddc({'count':_0x3ec165['length'],'rows':_0x3ec165});});},'OpenchannelQueues':function(){return new Promise(function(_0x416ffd){const _0x15c1a5=a1219_0x5116,_0x3914b2=[];for(const _0x2ca409 in _0x1f9219[_0x15c1a5('0x56')]){if(typeof _0x1f9219[_0x15c1a5('0x56')][_0x2ca409]!==_0x15c1a5('0x34')){const _0x27f8bb=_0x1f9219[_0x15c1a5('0x56')][_0x2ca409],_0x4234c3={'id':_0x27f8bb['id'],'available':_0x27f8bb[_0x15c1a5('0xd')],'loggedIn':_0x27f8bb[_0x15c1a5('0x22')],'name':_0x27f8bb[_0x15c1a5('0x28')],'paused':_0x27f8bb['paused'],'waiting':_0x27f8bb[_0x15c1a5('0x3d')]};_0x3914b2[_0x15c1a5('0x4b')](_0x4234c3);}}_0x416ffd({'count':_0x3914b2[_0x15c1a5('0x33')],'rows':_0x3914b2});});},'SmsQueues':function(){return new Promise(function(_0xbc353){const _0x4dedda=a1219_0x5116,_0x3206eb=[];for(const _0x223be7 in _0x1f9219['smsQueues']){if(typeof _0x1f9219['smsQueues'][_0x223be7]!==_0x4dedda('0x34')){const _0x4abfcd=_0x1f9219['smsQueues'][_0x223be7],_0x946a69={'id':_0x4abfcd['id'],'available':_0x4abfcd[_0x4dedda('0xd')],'loggedIn':_0x4abfcd[_0x4dedda('0x22')],'name':_0x4abfcd['name'],'paused':_0x4abfcd[_0x4dedda('0x45')],'waiting':_0x4abfcd['waiting']};_0x3206eb['push'](_0x946a69);}}_0xbc353({'count':_0x3206eb[_0x4dedda('0x33')],'rows':_0x3206eb});});},'FaxQueues':function(){return new Promise(function(_0x2f2a43){const _0x1f241e=a1219_0x5116,_0x8a8a5=[];for(const _0x44e213 in _0x1f9219[_0x1f241e('0x49')]){if(typeof _0x1f9219['faxQueues'][_0x44e213]!==_0x1f241e('0x34')){const _0x4fc555=_0x1f9219[_0x1f241e('0x49')][_0x44e213],_0x550517={'id':_0x4fc555['id'],'available':_0x4fc555[_0x1f241e('0xd')],'loggedIn':_0x4fc555[_0x1f241e('0x22')],'name':_0x4fc555[_0x1f241e('0x28')],'paused':_0x4fc555[_0x1f241e('0x45')],'waiting':_0x4fc555[_0x1f241e('0x3d')]};_0x8a8a5[_0x1f241e('0x4b')](_0x550517);}}_0x2f2a43({'count':_0x8a8a5[_0x1f241e('0x33')],'rows':_0x8a8a5});});},'WhatsappQueues':function(){return new Promise(function(_0x166caa){const _0x3a4596=a1219_0x5116,_0xf85027=[];for(const _0x176509 in _0x1f9219[_0x3a4596('0x3f')]){if(typeof _0x1f9219[_0x3a4596('0x3f')][_0x176509]!==_0x3a4596('0x34')){const _0xb6a494=_0x1f9219[_0x3a4596('0x3f')][_0x176509],_0x3d3380={'id':_0xb6a494['id'],'available':_0xb6a494['available'],'loggedIn':_0xb6a494[_0x3a4596('0x22')],'name':_0xb6a494['name'],'paused':_0xb6a494[_0x3a4596('0x45')],'waiting':_0xb6a494[_0x3a4596('0x3d')]};_0xf85027[_0x3a4596('0x4b')](_0x3d3380);}}_0x166caa({'count':_0xf85027[_0x3a4596('0x33')],'rows':_0xf85027});});},'ChatQueuesWaitingInteractions':function(){return new Promise(function(_0x4bbb35){const _0x59577b=a1219_0x5116,_0x6bc12e=_[_0x59577b('0x24')](_0x1f9219[_0x59577b('0x1c')]);_0x4bbb35({'count':_0x6bc12e[_0x59577b('0x33')],'rows':_0x6bc12e});});},'MailQueuesWaitingInteractions':function(){return new Promise(function(_0x5681c5){const _0x4e075f=a1219_0x5116,_0x1e202d=_[_0x4e075f('0x24')](_0x1f9219['mailQueuesWaitingInteractions']);_0x5681c5({'count':_0x1e202d['length'],'rows':_0x1e202d});});},'OpenchannelQueuesWaitingInteractions':function(){return new Promise(function(_0x96a3b0){const _0x3f68c0=a1219_0x5116,_0x716a89=_['values'](_0x1f9219[_0x3f68c0('0x59')]);_0x96a3b0({'count':_0x716a89[_0x3f68c0('0x33')],'rows':_0x716a89});});},'SmsQueuesWaitingInteractions':function(){return new Promise(function(_0x359c12){const _0x22d076=a1219_0x5116,_0x443203=_[_0x22d076('0x24')](_0x1f9219[_0x22d076('0x2a')]);_0x359c12({'count':_0x443203[_0x22d076('0x33')],'rows':_0x443203});});},'FaxQueuesWaitingInteractions':function(){return new Promise(function(_0x16bc0a){const _0x448a8a=a1219_0x5116,_0x86a144=_[_0x448a8a('0x24')](_0x1f9219['faxQueuesWaitingInteractions']);_0x16bc0a({'count':_0x86a144[_0x448a8a('0x33')],'rows':_0x86a144});});},'WhatsappQueuesWaitingInteractions':function(){return new Promise(function(_0x31d8df){const _0x5a65c7=a1219_0x5116,_0x2f2a9e=_[_0x5a65c7('0x24')](_0x1f9219[_0x5a65c7('0x11')]);_0x31d8df({'count':_0x2f2a9e[_0x5a65c7('0x33')],'rows':_0x2f2a9e});});}},_0x444748=jayson[_0x5d5ed1('0x21')](_0x3d9e7e)[_0x5d5ed1('0x42')]();_0x444748['on'](_0x5d5ed1('0xf'),function(_0x135d0a){const _0x5d6932=_0x5d5ed1;return logger[_0x5d6932('0xf')](JSON[_0x5d6932('0x6')](_0x135d0a)),_0x21432f(_0x135d0a);}),_0x444748[_0x5d5ed1('0x37')](0x232c,_0x5d5ed1('0x4f'),function(){const _0x496bdf=_0x5d5ed1;return console[_0x496bdf('0x2c')]('Routing\x20RPC\x20server\x20listening\x20on\x20127.0.0.1:%d!',0x232c),_0x37ecaf('RPC\x20listening\x20on\x20port:'+0x232c);});});}; \ No newline at end of file +const a1219_0x2163=['app','lodash','autoreply','.js','push','isNil','error','split','chatQueuesWaitingInteractions','name','CurrentCapacity','tag','interaction','stringify','\x20|\x20','intervals','chatQueues','No\x20applications\x20to\x20execute','faxQueuesWaitingInteractions','TagId','./applications/','agents','values','../lib/rule-engine','./interval','mailQueues','execute','undefined','Push\x20new\x20rule','Applications\x20executed','routing','agent\x20not\x20found','listen','map','appdata','stack','../rpc/whatsappQueueReport','QueueReport','%s.%s.%s','busyQueue','whatsappQueues','toLowerCase','info','mailQueuesWaitingInteractions','RPC\x20listening\x20on\x20port:','paused','Intervals','slice','isArray','matchPath','openchannelQueues','agent','server','end','join','priority','format','emit','condition','../rpc/faxQueueReport','../rpc/mailQueueReport','loggedIn','smsQueues','complete','log','../rpc/chatQueueReport','interval','faxQueues','openchannelQueuesWaitingInteractions','dialogflow','Routing\x20RPC\x20server\x20listening\x20on\x20127.0.0.1:%d!','amazonlex','%s:%s:%s','error\x20update\x20queue\x20report','smsQueuesWaitingInteractions','available','channel','../../../config/logger','waiting','../rpc/smsQueueReport','applications','UserId','../rpc/openchannelQueueReport','length','on\x20interval','rules','dialogflowv2','message\x20is\x20empty','message','updateRealtime','IntervalId','capacity'];(function(_0x3ed2a0,_0x21630e){const _0x55925c=function(_0x2e3c8a){while(--_0x2e3c8a){_0x3ed2a0['push'](_0x3ed2a0['shift']());}};_0x55925c(++_0x21630e);}(a1219_0x2163,0x1b2));const a1219_0x5592=function(_0x3ed2a0,_0x21630e){_0x3ed2a0=_0x3ed2a0-0x0;let _0x55925c=a1219_0x2163[_0x3ed2a0];return _0x55925c;};const _0x60439c=a1219_0x5592;'use strict';const _=require(_0x60439c('0x1b')),util=require('util'),path=require('path'),fs=require('fs'),jayson=require('jayson/promise'),logger=require(_0x60439c('0xb'))(_0x60439c('0x38')),rpc={'openchannelQueueReport':require(_0x60439c('0x10')),'mailQueueReport':require(_0x60439c('0x56')),'chatQueueReport':require(_0x60439c('0x5b')),'smsQueueReport':require(_0x60439c('0xd')),'faxQueueReport':require(_0x60439c('0x55')),'whatsappQueueReport':require(_0x60439c('0x3e'))},RuleEngine=require(_0x60439c('0x31'));function getId(_0x2e3c8a,_0x3b778e,_0x5d6319){const _0x458e39=_0x60439c;return util[_0x458e39('0x52')](_0x458e39('0x40'),_0x2e3c8a,_0x3b778e||0x0,_0x5d6319||0x0);}function getIntervals(_0x2b7a3b,_0x3918a1){const _0x5d7672=_0x60439c;let _0x4c378b=[];if(!_[_0x5d7672('0x1f')](_0x3918a1[_0x5d7672('0x18')])&&!_[_0x5d7672('0x1f')](_0x2b7a3b[_0x3918a1[_0x5d7672('0x18')]])&&!_[_0x5d7672('0x1f')](_0x2b7a3b[_0x3918a1[_0x5d7672('0x18')]][_0x5d7672('0x48')]))_0x4c378b=_[_0x5d7672('0x3b')](_0x2b7a3b[_0x3918a1[_0x5d7672('0x18')]]['Intervals'],_0x5d7672('0x0'));else!_[_0x5d7672('0x1f')](_0x3918a1['interval'])&&(_0x4c378b=[_0x3918a1['interval']]);return _0x4c378b;}exports[_0x60439c('0x3a')]=function(_0x3e534a){const _0x2d90b0=_0x60439c;return _0x3e534a[_0x2d90b0('0x13')]={},new Promise(function(_0x544ee6,_0x4adcc4){const _0x36f173=_0x2d90b0,_0xa38ef4={'Start':function(_0xefa086){const _0x2cdf97=this;return new Promise(function(_0x4b4bbf,_0x4fc316){const _0x6dc09=a1219_0x5592;if(_0xefa086)try{const _0x35b01e=[],_0x1f88ab=getId(_0xefa086[_0x6dc09('0xa')],_0xefa086['message']?_0xefa086[_0x6dc09('0x16')]['id']:0x0,_0xefa086['interaction']?_0xefa086['interaction']['id']:0x0);if(_0xefa086['applications']&&_[_0x6dc09('0x4a')](_0xefa086[_0x6dc09('0xe')])&&_0xefa086[_0x6dc09('0xe')][_0x6dc09('0x11')]){for(let _0x149d4e=0x0;_0x149d4e<_0xefa086[_0x6dc09('0xe')]['length'];_0x149d4e+=0x1){const _0x434113=_0xefa086[_0x6dc09('0xe')][_0x149d4e];if(fs['existsSync'](path[_0x6dc09('0x50')](__dirname,_0x6dc09('0xe'),_0x434113[_0x6dc09('0x1a')]+'.js'))){let _0x2afb92=[];switch(_0x434113[_0x6dc09('0x1a')][_0x6dc09('0x43')]()){case _0x6dc09('0x1c'):{const _0x2ba30d=_0x434113[_0x6dc09('0x3c')]['split'](',');_0x2afb92[_0x6dc09('0x1e')](_0x2ba30d[0x0]),_0x2afb92['push'](_0x2ba30d[_0x6dc09('0x49')](0x1,_0x2ba30d['length'])['join'](','));}break;case _0x6dc09('0x3'):{const _0x141e1c=_0x434113[_0x6dc09('0x3c')][_0x6dc09('0x21')](',');_0x2afb92[_0x6dc09('0x1e')](_0x141e1c[0x0]),_0x2afb92[_0x6dc09('0x1e')](_0x141e1c[0x1]),_0x2afb92[_0x6dc09('0x1e')](_0x141e1c[_0x6dc09('0x49')](0x2,_0x141e1c['length'])[_0x6dc09('0x50')](','));}break;case _0x6dc09('0x14'):{const _0x1de420=_0x434113[_0x6dc09('0x3c')][_0x6dc09('0x21')](',');_0x2afb92[_0x6dc09('0x1e')](_0x1de420[0x0]),_0x2afb92[_0x6dc09('0x1e')](_0x1de420[0x1]),_0x2afb92['push'](_0x1de420[0x2]),_0x2afb92['push'](_0x1de420[0x3]),_0x2afb92[_0x6dc09('0x1e')](_0x1de420[_0x6dc09('0x49')](0x4,_0x1de420[_0x6dc09('0x11')])['join'](','));}break;case _0x6dc09('0x5'):{const _0x444a62=_0x434113[_0x6dc09('0x3c')][_0x6dc09('0x21')](',');_0x2afb92['push'](_0x444a62[0x0]),_0x2afb92[_0x6dc09('0x1e')](_0x444a62[0x1]),_0x2afb92[_0x6dc09('0x1e')](_0x444a62[0x2]),_0x2afb92[_0x6dc09('0x1e')](_0x444a62[0x3]),_0x2afb92['push'](_0x444a62[_0x6dc09('0x49')](0x4,_0x444a62[_0x6dc09('0x11')])[_0x6dc09('0x50')](','));}break;case _0x6dc09('0x16'):_0x2afb92[_0x6dc09('0x1e')](_0x434113[_0x6dc09('0x3c')]);break;case _0x6dc09('0x25'):_0x2afb92[_0x6dc09('0x1e')](_0x434113[_0x6dc09('0x2d')]),_0x2afb92[_0x6dc09('0x1e')](_0x434113[_0x6dc09('0x3c')]);break;default:_0x2afb92=_[_0x6dc09('0x1f')](_0x434113[_0x6dc09('0x3c')])?[]:_0x434113[_0x6dc09('0x3c')][_0x6dc09('0x21')](',');}const _0x1d6574={'id':util[_0x6dc09('0x52')](_0x6dc09('0x6'),_0x1f88ab,_0x434113['id'],_0x434113[_0x6dc09('0x1a')]),'condition':require(_0x6dc09('0x32'))[_0x6dc09('0x54')](_0x1f88ab,getIntervals(_0x3e534a[_0x6dc09('0x29')],_0x434113),_0x3e534a),'consequence':require(_0x6dc09('0x2e')+_0x434113[_0x6dc09('0x1a')])['consequence'](_0x1f88ab,_0x2afb92,_0x3e534a,_0xefa086),'p':_0x434113[_0x6dc09('0x51')]||0x0};logger[_0x6dc09('0x44')](_0x6dc09('0x36'),_0x1d6574['id'],_0x6dc09('0x12'),getIntervals(_0x3e534a[_0x6dc09('0x29')],_0x434113)[_0x6dc09('0x50')](_0x6dc09('0x28'))),_0x35b01e['push'](_0x1d6574);}else logger[_0x6dc09('0x20')]('Please\x20create\x20a\x20new\x20file\x20under',path[_0x6dc09('0x50')](__dirname,_0x6dc09('0xe'),_0x434113[_0x6dc09('0x1a')]+_0x6dc09('0x1d')));}return _0x3e534a[_0x6dc09('0x13')][_0x1f88ab]=new RuleEngine(_0x35b01e),_0x3e534a[_0x6dc09('0x13')][_0x1f88ab][_0x6dc09('0x34')](_0xefa086,function(_0x3d796b){const _0x37b93e=_0x6dc09;logger[_0x37b93e('0x44')](_0x37b93e('0x37'),JSON[_0x37b93e('0x27')](_0x3d796b[_0x37b93e('0x4b')])),_0x3e534a[_0x37b93e('0x13')][_0x1f88ab]&&_0x3e534a[_0x37b93e('0x13')][_0x1f88ab][_0x37b93e('0x53')](_0x37b93e('0x59'));}),_0x4b4bbf({'code':0xc8,'message':_0xefa086});}else return logger[_0x6dc09('0x44')](_0x6dc09('0x2b')),_0x4b4bbf({'code':0xc8,'message':_0xefa086});}catch(_0x24161f){return logger[_0x6dc09('0x20')](_0x24161f[_0x6dc09('0x3d')]),_0x4fc316(_0x2cdf97[_0x6dc09('0x20')](0x1f4,_0x24161f));}return _0x4fc316('routing\x20is\x20empty');});},'AcceptMessage':function(_0x272bab){const _0x302252=this;return new Promise(function(_0x5a2caf,_0x39a1a9){const _0x5c89a3=a1219_0x5592;if(_0x272bab[_0x5c89a3('0x16')]&&_0x272bab[_0x5c89a3('0x16')]['id'])try{const _0x49e9bc=getId(_0x272bab[_0x5c89a3('0xa')],_0x272bab[_0x5c89a3('0x16')]?_0x272bab['message']['id']:0x0,_0x272bab[_0x5c89a3('0x26')]?_0x272bab[_0x5c89a3('0x26')]['id']:0x0);return _0x3e534a[_0x5c89a3('0x13')][_0x49e9bc]&&(_0x3e534a['rules'][_0x49e9bc][_0x5c89a3('0x53')](_0x5c89a3('0x4f')),rpc[_0x272bab[_0x5c89a3('0xa')]+'QueueReport']&&rpc[_0x272bab['channel']+_0x5c89a3('0x3f')]['update'](_0x49e9bc,{'UserId':_0x272bab[_0x5c89a3('0x16')][_0x5c89a3('0xf')]})['catch'](function(){const _0x3d7c09=_0x5c89a3;logger[_0x3d7c09('0x20')](_0x3d7c09('0x7'));})),_0x5a2caf({'code':0xc8,'message':_0x272bab});}catch(_0x17390f){return logger[_0x5c89a3('0x20')](_0x17390f[_0x5c89a3('0x3d')]),_0x39a1a9(_0x302252['error'](0x1f4,_0x17390f));}return logger['error'](_0x5c89a3('0x15')),_0x39a1a9(_0x302252[_0x5c89a3('0x20')](0x1f4,_0x5c89a3('0x15')));});},'RejectMessage':function(_0x10d0cc){const _0x4ccc00=this;return new Promise(function(_0x3dab2d,_0x13fb82){const _0x8faf43=a1219_0x5592;if(_0x10d0cc[_0x8faf43('0x4d')]&&_0x10d0cc['agent']['id'])try{return _0x3e534a['agents'][_0x10d0cc['agent']['id']]&&(_0x3e534a[_0x8faf43('0x2f')][_0x10d0cc[_0x8faf43('0x4d')]['id']]['busy']=![],_0x3e534a['agents'][_0x10d0cc['agent']['id']][_0x8faf43('0x41')]=undefined),_0x3dab2d({'code':0xc8,'message':_0x10d0cc});}catch(_0x297792){return logger[_0x8faf43('0x20')](_0x297792[_0x8faf43('0x3d')]),_0x13fb82(_0x4ccc00[_0x8faf43('0x20')](0x1f4,_0x297792));}return logger[_0x8faf43('0x20')](_0x8faf43('0x15')),_0x13fb82(_0x4ccc00[_0x8faf43('0x20')](0x1f4,_0x8faf43('0x15')));});},'AbandonInteraction':function(_0x4722fa){const _0x113576=this;return new Promise(function(_0x4fff18,_0xbbd5c1){const _0x2e93b5=a1219_0x5592;if(_0x4722fa['channel']&&_0x4722fa[_0x2e93b5('0x26')]&&_0x4722fa['interaction']['id'])try{const _0x465287=getId(_0x4722fa['channel'],_0x4722fa[_0x2e93b5('0x16')]?_0x4722fa[_0x2e93b5('0x16')]['id']:0x0,_0x4722fa[_0x2e93b5('0x26')]?_0x4722fa[_0x2e93b5('0x26')]['id']:0x0);return _0x3e534a[_0x2e93b5('0x13')][_0x465287]&&_0x3e534a[_0x2e93b5('0x13')][_0x465287]['emit'](_0x2e93b5('0x4f')),_0x4fff18({'code':0xc8,'message':_0x4722fa});}catch(_0x435ad1){return logger['error'](_0x435ad1['stack']),_0xbbd5c1(_0x113576[_0x2e93b5('0x20')](0x1f4,_0x435ad1));}return logger[_0x2e93b5('0x20')](_0x2e93b5('0x15')),_0xbbd5c1(_0x113576[_0x2e93b5('0x20')](0x1f4,_0x2e93b5('0x15')));});},'AgentCapacity':function(_0x2f2aa7){const _0xdddd5a=this;return new Promise(function(_0x135abb,_0x4817b6){const _0x5d01a4=a1219_0x5592;if(typeof _0x3e534a[_0x5d01a4('0x2f')][_0x2f2aa7['id']]!==_0x5d01a4('0x35')){for(const _0x44a39b in _0x2f2aa7[_0x5d01a4('0x19')]){typeof _0x2f2aa7[_0x5d01a4('0x19')][_0x44a39b]!==_0x5d01a4('0x35')&&(typeof _0x3e534a[_0x5d01a4('0x2f')][_0x2f2aa7['id']][_0x44a39b+_0x5d01a4('0x24')]!==_0x5d01a4('0x35')&&(_0x3e534a[_0x5d01a4('0x2f')][_0x2f2aa7['id']][_0x44a39b+_0x5d01a4('0x24')]=parseInt(_0x2f2aa7[_0x5d01a4('0x19')][_0x44a39b],0xa)));}return _0x3e534a[_0x5d01a4('0x2f')][_0x2f2aa7['id']][_0x5d01a4('0x17')](),_0x135abb({'code':0xc8,'message':_0x3e534a[_0x5d01a4('0x2f')][_0x2f2aa7['id']]});}else return _0x4817b6(_0xdddd5a[_0x5d01a4('0x20')](0x1f4,_0x5d01a4('0x39')));});},'Agents':function(){return new Promise(function(_0x46abe8){const _0x4a429d=a1219_0x5592,_0x4543e5=_[_0x4a429d('0x30')](_0x3e534a[_0x4a429d('0x2f')]);_0x46abe8({'count':_0x4543e5[_0x4a429d('0x11')],'rows':_0x4543e5});});},'ChatQueues':function(){return new Promise(function(_0x4c5a7d){const _0x472717=a1219_0x5592,_0x4adeb5=[];for(const _0x50ad31 in _0x3e534a[_0x472717('0x2a')]){if(typeof _0x3e534a[_0x472717('0x2a')][_0x50ad31]!==_0x472717('0x35')){const _0x5cd4c9=_0x3e534a[_0x472717('0x2a')][_0x50ad31],_0x33d6cd={'id':_0x5cd4c9['id'],'available':_0x5cd4c9[_0x472717('0x9')],'loggedIn':_0x5cd4c9['loggedIn'],'name':_0x5cd4c9[_0x472717('0x23')],'paused':_0x5cd4c9[_0x472717('0x47')],'waiting':_0x5cd4c9[_0x472717('0xc')]};_0x4adeb5['push'](_0x33d6cd);}}_0x4c5a7d({'count':_0x4adeb5[_0x472717('0x11')],'rows':_0x4adeb5});});},'MailQueues':function(){return new Promise(function(_0x12c1bf){const _0x20670c=a1219_0x5592,_0x5885ef=[];for(const _0x2ca206 in _0x3e534a[_0x20670c('0x33')]){if(typeof _0x3e534a['mailQueues'][_0x2ca206]!=='undefined'){const _0xa23988=_0x3e534a[_0x20670c('0x33')][_0x2ca206],_0xe2966d={'id':_0xa23988['id'],'available':_0xa23988[_0x20670c('0x9')],'loggedIn':_0xa23988[_0x20670c('0x57')],'name':_0xa23988[_0x20670c('0x23')],'paused':_0xa23988[_0x20670c('0x47')],'waiting':_0xa23988[_0x20670c('0xc')]};_0x5885ef[_0x20670c('0x1e')](_0xe2966d);}}_0x12c1bf({'count':_0x5885ef['length'],'rows':_0x5885ef});});},'OpenchannelQueues':function(){return new Promise(function(_0xa4f1d6){const _0x5524e8=a1219_0x5592,_0x13fd16=[];for(const _0x277ff2 in _0x3e534a[_0x5524e8('0x4c')]){if(typeof _0x3e534a[_0x5524e8('0x4c')][_0x277ff2]!=='undefined'){const _0x12ee95=_0x3e534a['openchannelQueues'][_0x277ff2],_0x18d597={'id':_0x12ee95['id'],'available':_0x12ee95['available'],'loggedIn':_0x12ee95['loggedIn'],'name':_0x12ee95[_0x5524e8('0x23')],'paused':_0x12ee95[_0x5524e8('0x47')],'waiting':_0x12ee95[_0x5524e8('0xc')]};_0x13fd16['push'](_0x18d597);}}_0xa4f1d6({'count':_0x13fd16['length'],'rows':_0x13fd16});});},'SmsQueues':function(){return new Promise(function(_0x56193c){const _0x5e0236=a1219_0x5592,_0x1dba25=[];for(const _0x2f5cb0 in _0x3e534a[_0x5e0236('0x58')]){if(typeof _0x3e534a[_0x5e0236('0x58')][_0x2f5cb0]!==_0x5e0236('0x35')){const _0x52e086=_0x3e534a[_0x5e0236('0x58')][_0x2f5cb0],_0x174483={'id':_0x52e086['id'],'available':_0x52e086[_0x5e0236('0x9')],'loggedIn':_0x52e086[_0x5e0236('0x57')],'name':_0x52e086[_0x5e0236('0x23')],'paused':_0x52e086[_0x5e0236('0x47')],'waiting':_0x52e086['waiting']};_0x1dba25['push'](_0x174483);}}_0x56193c({'count':_0x1dba25[_0x5e0236('0x11')],'rows':_0x1dba25});});},'FaxQueues':function(){return new Promise(function(_0x204362){const _0x3228da=a1219_0x5592,_0x50f90c=[];for(const _0x1ba1aa in _0x3e534a[_0x3228da('0x1')]){if(typeof _0x3e534a[_0x3228da('0x1')][_0x1ba1aa]!==_0x3228da('0x35')){const _0x1b71e9=_0x3e534a['faxQueues'][_0x1ba1aa],_0x3a7da0={'id':_0x1b71e9['id'],'available':_0x1b71e9['available'],'loggedIn':_0x1b71e9[_0x3228da('0x57')],'name':_0x1b71e9[_0x3228da('0x23')],'paused':_0x1b71e9[_0x3228da('0x47')],'waiting':_0x1b71e9[_0x3228da('0xc')]};_0x50f90c[_0x3228da('0x1e')](_0x3a7da0);}}_0x204362({'count':_0x50f90c['length'],'rows':_0x50f90c});});},'WhatsappQueues':function(){return new Promise(function(_0x5c218b){const _0x2af162=a1219_0x5592,_0xd9b790=[];for(const _0x325435 in _0x3e534a[_0x2af162('0x42')]){if(typeof _0x3e534a[_0x2af162('0x42')][_0x325435]!==_0x2af162('0x35')){const _0x6444af=_0x3e534a[_0x2af162('0x42')][_0x325435],_0x48f24b={'id':_0x6444af['id'],'available':_0x6444af[_0x2af162('0x9')],'loggedIn':_0x6444af['loggedIn'],'name':_0x6444af['name'],'paused':_0x6444af[_0x2af162('0x47')],'waiting':_0x6444af[_0x2af162('0xc')]};_0xd9b790[_0x2af162('0x1e')](_0x48f24b);}}_0x5c218b({'count':_0xd9b790[_0x2af162('0x11')],'rows':_0xd9b790});});},'ChatQueuesWaitingInteractions':function(){return new Promise(function(_0xaa5af2){const _0x1fb2a5=a1219_0x5592,_0x3fd7e1=_['values'](_0x3e534a[_0x1fb2a5('0x22')]);_0xaa5af2({'count':_0x3fd7e1['length'],'rows':_0x3fd7e1});});},'MailQueuesWaitingInteractions':function(){return new Promise(function(_0x2d0e05){const _0x8c7257=a1219_0x5592,_0x47f024=_[_0x8c7257('0x30')](_0x3e534a[_0x8c7257('0x45')]);_0x2d0e05({'count':_0x47f024[_0x8c7257('0x11')],'rows':_0x47f024});});},'OpenchannelQueuesWaitingInteractions':function(){return new Promise(function(_0x1c596f){const _0x5dbd34=a1219_0x5592,_0x26f914=_[_0x5dbd34('0x30')](_0x3e534a[_0x5dbd34('0x2')]);_0x1c596f({'count':_0x26f914[_0x5dbd34('0x11')],'rows':_0x26f914});});},'SmsQueuesWaitingInteractions':function(){return new Promise(function(_0xe0d0e){const _0x577054=a1219_0x5592,_0x5ba2af=_[_0x577054('0x30')](_0x3e534a[_0x577054('0x8')]);_0xe0d0e({'count':_0x5ba2af[_0x577054('0x11')],'rows':_0x5ba2af});});},'FaxQueuesWaitingInteractions':function(){return new Promise(function(_0x1836f6){const _0x11de30=a1219_0x5592,_0x5865d7=_[_0x11de30('0x30')](_0x3e534a[_0x11de30('0x2c')]);_0x1836f6({'count':_0x5865d7['length'],'rows':_0x5865d7});});},'WhatsappQueuesWaitingInteractions':function(){return new Promise(function(_0x1e5aca){const _0x356415=a1219_0x5592,_0x29363c=_[_0x356415('0x30')](_0x3e534a['whatsappQueuesWaitingInteractions']);_0x1e5aca({'count':_0x29363c[_0x356415('0x11')],'rows':_0x29363c});});}},_0x20d8eb=jayson[_0x36f173('0x4e')](_0xa38ef4)['http']();_0x20d8eb['on']('error',function(_0x428b85){const _0x586ae7=_0x36f173;return logger[_0x586ae7('0x20')](JSON[_0x586ae7('0x27')](_0x428b85)),_0x4adcc4(_0x428b85);}),_0x20d8eb[_0x36f173('0x3a')](0x232c,'127.0.0.1',function(){const _0x524309=_0x36f173;return console[_0x524309('0x5a')](_0x524309('0x4'),0x232c),_0x544ee6(_0x524309('0x46')+0x232c);});});}; \ No newline at end of file diff --git a/server/services/routing/server/interval.js b/server/services/routing/server/interval.js index 138b759..b869c87 100644 --- a/server/services/routing/server/interval.js +++ b/server/services/routing/server/interval.js @@ -1 +1 @@ -const a1220_0x4aef=['log','http','\x20|\x20','condition','message','[%s][INTERVAL]\x20ROUTING\x20STOPPED','true','iftime\x20%s','[%s][INTERVAL]\x20%s','stack','push','lodash','result','join','info','error','all','rules','length','client','then','util','jayson/promise','../../../config/logger','request','Command','indexOf','when','stop','catch','format'];(function(_0x382f3a,_0x4aef7c){const _0x3d6b8d=function(_0x57cb57){while(--_0x57cb57){_0x382f3a['push'](_0x382f3a['shift']());}};_0x3d6b8d(++_0x4aef7c);}(a1220_0x4aef,0xb3));const a1220_0x3d6b=function(_0x382f3a,_0x4aef7c){_0x382f3a=_0x382f3a-0x0;let _0x3d6b8d=a1220_0x4aef[_0x382f3a];return _0x3d6b8d;};const _0x1942a2=a1220_0x3d6b;'use strict';const util=require(_0x1942a2('0x1c')),jayson=require(_0x1942a2('0x1d')),_=require(_0x1942a2('0x12')),logger=require(_0x1942a2('0x1e'))('routing'),client=jayson[_0x1942a2('0x1a')][_0x1942a2('0x8')]({'port':0x232a});function request(_0x57cb57,_0x1afc3b){return new Promise(function(_0x3f0b0a,_0x1847cf){const _0x58712d=a1220_0x3d6b;return client[_0x58712d('0x0')](_0x57cb57,_0x1afc3b)[_0x58712d('0x1b')](function(_0x28c9f3){const _0x43918e=_0x58712d;return _0x28c9f3[_0x43918e('0x16')]?_0x1847cf(_0x28c9f3[_0x43918e('0x16')][_0x43918e('0xb')]):_0x3f0b0a(_0x28c9f3[_0x43918e('0x13')]);})[_0x58712d('0x5')](function(_0x514a64){return _0x1847cf(_0x514a64);});});}exports[_0x1942a2('0xa')]=function(_0x41f322,_0x206a0a,_0x41cf9a){return function(_0x348d83){const _0x164f1d=a1220_0x3d6b;if(_0x41cf9a[_0x164f1d('0x18')]&&!_0x41cf9a[_0x164f1d('0x18')][_0x41f322])return logger['info'](_0x164f1d('0xc'),_0x41f322),_0x348d83[_0x164f1d('0x4')]();const _0x4baf14=[];for(let _0x2de076=0x0;_0x2de076<_0x206a0a[_0x164f1d('0x19')];_0x2de076+=0x1){_0x4baf14[_0x164f1d('0x11')](request(_0x164f1d('0x1'),{'command':util[_0x164f1d('0x6')](_0x164f1d('0xe'),_0x206a0a[_0x2de076])})[_0x164f1d('0x1b')](function(_0x5ad898){const _0x1d8f3c=_0x164f1d;return _0x5ad898&&_0x5ad898[_0x1d8f3c('0xb')]&&_0x5ad898[_0x1d8f3c('0xb')][_0x1d8f3c('0x2')](_0x1d8f3c('0xd'))>=0x0?!![]:![];})[_0x164f1d('0x5')](function(){const _0x2ba49c=_0x164f1d;logger[_0x2ba49c('0x16')](_0x2ba49c('0xf'),_0x41f322,_0x206a0a[_0x2de076]);}));}Promise[_0x164f1d('0x17')](_0x4baf14)['then'](function(_0x5c4c14){const _0x428dcc=_0x164f1d,_0x2812b8=_['some'](_0x5c4c14);logger[_0x428dcc('0x15')]('[%s][INTERVAL]\x20%s\x20%s',_0x41f322,_0x206a0a[_0x428dcc('0x14')](_0x428dcc('0x9')),_0x2812b8),_0x348d83[_0x428dcc('0x3')](_0x2812b8);})[_0x164f1d('0x5')](function(_0x341c55){const _0x209df4=_0x164f1d;console[_0x209df4('0x7')](_0x341c55),logger['error']('[%s][INTERVAL]\x20%s\x20%s',_0x41f322,_0x206a0a[_0x209df4('0x14')](_0x209df4('0x9')),_0x341c55[_0x209df4('0x10')]),_0x348d83[_0x209df4('0x4')]();});};}; \ No newline at end of file +const a1220_0x40b1=['jayson/promise','[%s][INTERVAL]\x20%s\x20%s','routing','[%s][INTERVAL]\x20ROUTING\x20STOPPED','rules','push','stop','../../../config/logger','some','true','error','iftime\x20%s','stack','result','join','http','all','when','length','util','Command','catch','log','message','then','request','\x20|\x20','client','indexOf','info'];(function(_0x3298e9,_0x40b181){const _0x48e531=function(_0x87f0a1){while(--_0x87f0a1){_0x3298e9['push'](_0x3298e9['shift']());}};_0x48e531(++_0x40b181);}(a1220_0x40b1,0x130));const a1220_0x48e5=function(_0x3298e9,_0x40b181){_0x3298e9=_0x3298e9-0x0;let _0x48e531=a1220_0x40b1[_0x3298e9];return _0x48e531;};const _0x653cb2=a1220_0x48e5;'use strict';const util=require(_0x653cb2('0xf')),jayson=require(_0x653cb2('0x1a')),_=require('lodash'),logger=require(_0x653cb2('0x3'))(_0x653cb2('0x1c')),client=jayson[_0x653cb2('0x17')][_0x653cb2('0xb')]({'port':0x232a});function request(_0x87f0a1,_0xfa81b2){return new Promise(function(_0x5ee34d,_0x33c295){const _0x3598ab=a1220_0x48e5;return client[_0x3598ab('0x15')](_0x87f0a1,_0xfa81b2)['then'](function(_0x32cae9){const _0x530333=_0x3598ab;return _0x32cae9[_0x530333('0x6')]?_0x33c295(_0x32cae9[_0x530333('0x6')][_0x530333('0x13')]):_0x5ee34d(_0x32cae9[_0x530333('0x9')]);})[_0x3598ab('0x11')](function(_0x61acc2){return _0x33c295(_0x61acc2);});});}exports['condition']=function(_0x324c1a,_0x278b69,_0x357346){return function(_0x3b0947){const _0x164bcd=a1220_0x48e5;if(_0x357346[_0x164bcd('0x0')]&&!_0x357346[_0x164bcd('0x0')][_0x324c1a])return logger['info'](_0x164bcd('0x1d'),_0x324c1a),_0x3b0947[_0x164bcd('0x2')]();const _0x1a0e75=[];for(let _0x2fd2a3=0x0;_0x2fd2a3<_0x278b69[_0x164bcd('0xe')];_0x2fd2a3+=0x1){_0x1a0e75[_0x164bcd('0x1')](request(_0x164bcd('0x10'),{'command':util['format'](_0x164bcd('0x7'),_0x278b69[_0x2fd2a3])})[_0x164bcd('0x14')](function(_0x105e4b){const _0xf846e6=_0x164bcd;return _0x105e4b&&_0x105e4b[_0xf846e6('0x13')]&&_0x105e4b[_0xf846e6('0x13')][_0xf846e6('0x18')](_0xf846e6('0x5'))>=0x0?!![]:![];})[_0x164bcd('0x11')](function(){logger['error']('[%s][INTERVAL]\x20%s',_0x324c1a,_0x278b69[_0x2fd2a3]);}));}Promise[_0x164bcd('0xc')](_0x1a0e75)[_0x164bcd('0x14')](function(_0x3e6c7c){const _0x3caf3c=_0x164bcd,_0x4025c2=_[_0x3caf3c('0x4')](_0x3e6c7c);logger[_0x3caf3c('0x19')]('[%s][INTERVAL]\x20%s\x20%s',_0x324c1a,_0x278b69[_0x3caf3c('0xa')](_0x3caf3c('0x16')),_0x4025c2),_0x3b0947[_0x3caf3c('0xd')](_0x4025c2);})['catch'](function(_0x27ff8e){const _0x477e52=_0x164bcd;console[_0x477e52('0x12')](_0x27ff8e),logger['error'](_0x477e52('0x1b'),_0x324c1a,_0x278b69[_0x477e52('0xa')]('\x20|\x20'),_0x27ff8e[_0x477e52('0x8')]),_0x3b0947[_0x477e52('0x2')]();});};}; \ No newline at end of file diff --git a/server/services/xdr/agents.controller.js b/server/services/xdr/agents.controller.js index d7996eb..9bbd7ed 100644 --- a/server/services/xdr/agents.controller.js +++ b/server/services/xdr/agents.controller.js @@ -1 +1 @@ -const a1221_0x456a=['calleridnum','secondtransfereruniqueid','request','cause','queuecallerabandon','agentringnoanswerAt','timeout','ringtime','lastevent','agentcalledAt','called','blind','rejected','now','splice','agentcompleteAt','acwtime','agentconnectAt','connectedlinenum','hangup','ATTENDED','stack','agentacw','./utils','secondtransfererexten','secondtransfererlinkedid','lodash','transfereeuniqueid','transferuniqueid','forIn','push','info','extension','format','reason','calleridname','util','agententerreason','connectedlinename','acwTimeout','agentconnect','channel','holdtime','origtransfereruniqueid','AGENT|%s|%s|%s|%s|%s|%s|%s|%s','clone','error','agentringnoanswer','includes','isNil','queue','destuniqueid','transfertype','agentcomplete','uniqueid','answeredelsewheredestinationuniqueid','answered_elsewhere','abandoned','transfer','indexOf','transfertargetuniqueid','acw','getVoiceQueueByName','membername','transferexten','diffTime','blindtransfer','CreateVoiceAgentReport','complete','transfereruniqueid','type','origtransfererlinkedid','interface','agent','connect','talktime','origtransfererexten'];(function(_0x4b5664,_0x456ac0){const _0x23df9=function(_0x4cce5f){while(--_0x4cce5f){_0x4b5664['push'](_0x4b5664['shift']());}};_0x23df9(++_0x456ac0);}(a1221_0x456a,0xdf));const a1221_0x23df=function(_0x4b5664,_0x456ac0){_0x4b5664=_0x4b5664-0x0;let _0x23df9=a1221_0x456a[_0x4b5664];return _0x23df9;};const _0x3daa57=a1221_0x23df;'use strict';const _=require(_0x3daa57('0x22')),util=require(_0x3daa57('0x2c')),utils=require(_0x3daa57('0x1f')),agents={},transfers={},unanswered=[];function writeDB(_0x4cce5f,_0x7c39bb){const _0x169e50=_0x3daa57;utils[_0x169e50('0x27')](util[_0x169e50('0x29')](_0x169e50('0x34'),_0x4cce5f[_0x169e50('0x3e')],_0x4cce5f[_0x169e50('0x31')],_0x4cce5f['queue'],_0x4cce5f['membername'],_0x4cce5f[_0x169e50('0x3')],_0x4cce5f['calleridnum'],_0x4cce5f['connectedlinenum'],_0x4cce5f[_0x169e50('0x10')])),_0x4cce5f[_0x169e50('0x3a')]?utils[_0x169e50('0x46')](_0x4cce5f[_0x169e50('0x3a')])['then'](function(_0x5ca6f2){const _0x3d5ad1=_0x169e50;_0x5ca6f2&&(_0x4cce5f[_0x3d5ad1('0x1')]=_0x5ca6f2[_0x3d5ad1('0x1')],_0x4cce5f[_0x3d5ad1('0x1e')]=_0x4cce5f[_0x3d5ad1('0x3d')]?_0x5ca6f2[_0x3d5ad1('0x45')]:![],_0x4cce5f[_0x3d5ad1('0x18')]=_0x4cce5f['agentacw']?_0x5ca6f2[_0x3d5ad1('0x2f')]:0x0),utils['request'](_0x3d5ad1('0x4b'),_0x4cce5f);}):utils[_0x169e50('0xa')](_0x169e50('0x4b'),_0x4cce5f),_0x7c39bb?delete transfers[_0x4cce5f[_0x169e50('0x3e')]]:delete agents[_0x4cce5f['destuniqueid']];}exports['agentcalled']=function(_0xff4a49){const _0x45973a=_0x3daa57;try{agents[_0xff4a49['destuniqueid']]=_0xff4a49,agents[_0xff4a49[_0x45973a('0x3b')]][_0x45973a('0x11')]=utils['now'](),agents[_0xff4a49[_0x45973a('0x3b')]]['lastevent']=_0x45973a('0x12'),agents[_0xff4a49[_0x45973a('0x3b')]][_0x45973a('0x1a')]=null,agents[_0xff4a49[_0x45973a('0x3b')]]['connectedlinename']=null;}catch(_0x2037f2){utils['error'](_0x2037f2[_0x45973a('0x1d')]);}},exports['agentringnoanswer']=function(_0x455142){const _0x3ecc24=_0x3daa57;try{!_[_0x3ecc24('0x39')](agents[_0x455142[_0x3ecc24('0x3b')]])&&(agents[_0x455142[_0x3ecc24('0x3b')]][_0x3ecc24('0x37')]=!![],agents[_0x455142[_0x3ecc24('0x3b')]][_0x3ecc24('0xd')]=utils[_0x3ecc24('0x15')](),agents[_0x455142[_0x3ecc24('0x3b')]][_0x3ecc24('0x10')]=_0x3ecc24('0xe'),agents[_0x455142[_0x3ecc24('0x3b')]][_0x3ecc24('0x2a')]=_0x3ecc24('0xe'),agents[_0x455142[_0x3ecc24('0x3b')]][_0x3ecc24('0x32')]=_0x455142['ringtime']?parseInt(_0x455142['ringtime'])/0x3e8:0x0,agents[_0x455142[_0x3ecc24('0x3b')]][_0x3ecc24('0x6')]=0x0,unanswered[_0x3ecc24('0x26')](_0x455142[_0x3ecc24('0x3b')]));}catch(_0x1fa91b){utils[_0x3ecc24('0x36')](_0x1fa91b['stack']);}},exports[_0x3daa57('0xc')]=function(_0x204fcf){const _0x49f30e=_0x3daa57;try{_[_0x49f30e('0x25')](agents,function(_0x236426){const _0x500d53=_0x49f30e;_0x236426[_0x500d53('0x3e')]==_0x204fcf[_0x500d53('0x3e')]&&!_[_0x500d53('0x38')](unanswered,_0x236426['destuniqueid'])&&(_0x236426['agentringnoanswer']=!![],_0x236426['agentringnoanswerAt']=utils[_0x500d53('0x15')](),_0x236426['lastevent']='abandoned',_0x236426[_0x500d53('0x2a')]=_0x500d53('0x41'),_0x236426[_0x500d53('0x32')]=_0x204fcf[_0x500d53('0x32')],_0x236426[_0x500d53('0x6')]=0x0,writeDB(_0x236426));});}catch(_0x1a06ac){utils[_0x49f30e('0x36')](_0x1a06ac[_0x49f30e('0x1d')]);}},exports[_0x3daa57('0x30')]=function(_0x5c4dee){const _0x38170e=_0x3daa57;try{agents[_0x5c4dee[_0x38170e('0x3b')]]&&(agents[_0x5c4dee[_0x38170e('0x3b')]]['agentconnectAt']=utils[_0x38170e('0x15')](),agents[_0x5c4dee[_0x38170e('0x3b')]][_0x38170e('0x1a')]=_0x5c4dee[_0x38170e('0x1a')],agents[_0x5c4dee[_0x38170e('0x3b')]][_0x38170e('0x2e')]=_0x5c4dee[_0x38170e('0x2e')],agents[_0x5c4dee[_0x38170e('0x3b')]][_0x38170e('0x32')]=_0x5c4dee['ringtime'],agents[_0x5c4dee[_0x38170e('0x3b')]]['lastevent']=_0x38170e('0x5'),_[_0x38170e('0x25')](agents,function(_0x1b821e){const _0x10c9cc=_0x38170e;_0x1b821e[_0x10c9cc('0x3b')]!=_0x5c4dee['destuniqueid']&&_0x1b821e[_0x10c9cc('0x3e')]==_0x5c4dee['uniqueid']&&(_0x1b821e[_0x10c9cc('0x6')]=0x0,_0x1b821e[_0x10c9cc('0x32')]=_0x5c4dee[_0x10c9cc('0xf')],_0x1b821e[_0x10c9cc('0x37')]=!![],_0x1b821e[_0x10c9cc('0xd')]=utils['now'](),_0x1b821e[_0x10c9cc('0x10')]=_0x10c9cc('0x40'),_0x1b821e[_0x10c9cc('0x2a')]=_0x10c9cc('0x40'),_0x1b821e[_0x10c9cc('0x3f')]=_0x5c4dee[_0x10c9cc('0x3b')],_0x1b821e['answeredelsewheremembername']=_0x5c4dee[_0x10c9cc('0x47')],writeDB(_0x1b821e));}));}catch(_0x30606c){utils[_0x38170e('0x36')](_0x30606c[_0x38170e('0x1d')]);}},exports[_0x3daa57('0x3d')]=function(_0x13ea31){const _0x15322b=_0x3daa57;try{!_[_0x15322b('0x39')](agents[_0x13ea31[_0x15322b('0x3b')]])&&(agents[_0x13ea31[_0x15322b('0x3b')]][_0x15322b('0x3d')]=!![],agents[_0x13ea31[_0x15322b('0x3b')]][_0x15322b('0x17')]=utils['now'](),agents[_0x13ea31['destuniqueid']][_0x15322b('0x6')]=utils[_0x15322b('0x49')](agents[_0x13ea31[_0x15322b('0x3b')]]['agentcompleteAt'],agents[_0x13ea31[_0x15322b('0x3b')]][_0x15322b('0x19')]),agents[_0x13ea31[_0x15322b('0x3b')]][_0x15322b('0x2a')]=_0x13ea31[_0x15322b('0x2a')],agents[_0x13ea31[_0x15322b('0x3b')]][_0x15322b('0x10')]='complete',writeDB(agents[_0x13ea31[_0x15322b('0x3b')]]));}catch(_0x13fb80){utils[_0x15322b('0x36')](_0x13fb80[_0x15322b('0x1d')]);}},exports[_0x3daa57('0x4a')]=function(_0x3ec601){const _0xd0ab87=_0x3daa57;try{!_['isNil'](agents[_0x3ec601[_0xd0ab87('0x0')]])&&(agents[_0x3ec601['transfereruniqueid']][_0xd0ab87('0x42')]=!![],agents[_0x3ec601[_0xd0ab87('0x0')]][_0xd0ab87('0x3c')]=_0xd0ab87('0x13'),agents[_0x3ec601[_0xd0ab87('0x0')]]['transferexten']=_0x3ec601[_0xd0ab87('0x28')],agents[_0x3ec601[_0xd0ab87('0x0')]][_0xd0ab87('0x24')]=agents[_0x3ec601['transfereruniqueid']][_0xd0ab87('0x3e')]);}catch(_0x4872c6){utils[_0xd0ab87('0x36')](_0x4872c6[_0xd0ab87('0x1d')]);}},exports['attendedtransfer']=function(_0x4e2d14){const _0x2495de=_0x3daa57;try{if(_0x4e2d14[_0x2495de('0x33')]==_0x4e2d14[_0x2495de('0x2')])!_[_0x2495de('0x39')](agents[_0x4e2d14[_0x2495de('0x9')]])&&(agents[_0x4e2d14[_0x2495de('0x9')]][_0x2495de('0x42')]=!![],agents[_0x4e2d14[_0x2495de('0x9')]][_0x2495de('0x3c')]=_0x2495de('0x1c'),agents[_0x4e2d14['secondtransfereruniqueid']]['transferexten']=_0x4e2d14[_0x2495de('0x7')],agents[_0x4e2d14[_0x2495de('0x9')]][_0x2495de('0x24')]=_0x4e2d14[_0x2495de('0x33')]),_0x4e2d14[_0x2495de('0x23')]&&agents[_0x4e2d14['transfereeuniqueid']]&&(agents[_0x4e2d14['transfereeuniqueid']][_0x2495de('0x2d')]=0x1,transfers[_0x4e2d14[_0x2495de('0x23')]]=_[_0x2495de('0x35')](agents[_0x4e2d14['transfereeuniqueid']]),transfers[_0x4e2d14[_0x2495de('0x23')]][_0x2495de('0x8')]=agents[_0x4e2d14[_0x2495de('0x9')]][_0x2495de('0x8')],transfers[_0x4e2d14[_0x2495de('0x23')]]['calleridname']=agents[_0x4e2d14[_0x2495de('0x9')]][_0x2495de('0x2b')],transfers[_0x4e2d14[_0x2495de('0x23')]][_0x2495de('0x11')]=utils[_0x2495de('0x15')](),transfers[_0x4e2d14['transfereeuniqueid']][_0x2495de('0x19')]=utils[_0x2495de('0x15')](),transfers[_0x4e2d14[_0x2495de('0x23')]][_0x2495de('0x32')]=0x0,transfers[_0x4e2d14[_0x2495de('0x23')]][_0x2495de('0x2d')]=0x2);else _0x4e2d14[_0x2495de('0x9')]==_0x4e2d14[_0x2495de('0x21')]&&(!_[_0x2495de('0x39')](agents[_0x4e2d14[_0x2495de('0x33')]])&&(agents[_0x4e2d14[_0x2495de('0x33')]][_0x2495de('0x42')]=!![],agents[_0x4e2d14['origtransfereruniqueid']][_0x2495de('0x3c')]='ATTENDED',agents[_0x4e2d14[_0x2495de('0x33')]][_0x2495de('0x48')]=_0x4e2d14[_0x2495de('0x20')],agents[_0x4e2d14[_0x2495de('0x33')]][_0x2495de('0x24')]=_0x4e2d14[_0x2495de('0x9')]),_0x4e2d14[_0x2495de('0x44')]&&agents[_0x4e2d14[_0x2495de('0x44')]]&&(agents[_0x4e2d14[_0x2495de('0x44')]][_0x2495de('0x2d')]=0x1,transfers[_0x4e2d14[_0x2495de('0x44')]]=_[_0x2495de('0x35')](agents[_0x4e2d14['transfertargetuniqueid']]),transfers[_0x4e2d14[_0x2495de('0x44')]][_0x2495de('0x8')]=agents[_0x4e2d14['origtransfereruniqueid']]['calleridnum'],transfers[_0x4e2d14[_0x2495de('0x44')]][_0x2495de('0x2b')]=agents[_0x4e2d14['origtransfereruniqueid']][_0x2495de('0x2b')],transfers[_0x4e2d14[_0x2495de('0x44')]][_0x2495de('0x11')]=utils['now'](),transfers[_0x4e2d14[_0x2495de('0x44')]][_0x2495de('0x19')]=utils['now'](),transfers[_0x4e2d14[_0x2495de('0x44')]][_0x2495de('0x32')]=0x0,transfers[_0x4e2d14['transfertargetuniqueid']][_0x2495de('0x2d')]=0x2));}catch(_0x5dd337){utils[_0x2495de('0x36')](_0x5dd337[_0x2495de('0x1d')]);}},exports[_0x3daa57('0x1b')]=function(_0x9f99ce){const _0x2dd013=_0x3daa57;try{if(agents[_0x9f99ce[_0x2dd013('0x3e')]]&&agents[_0x9f99ce[_0x2dd013('0x3e')]][_0x2dd013('0x2a')]==='timeout'){_0x9f99ce[_0x2dd013('0xb')]==='21'&&(agents[_0x9f99ce['uniqueid']][_0x2dd013('0x2a')]=_0x2dd013('0x14'),agents[_0x9f99ce['uniqueid']][_0x2dd013('0x10')]=_0x2dd013('0x14'));writeDB(agents[_0x9f99ce[_0x2dd013('0x3e')]]);const _0x432923=unanswered[_0x2dd013('0x43')](_0x9f99ce[_0x2dd013('0x3e')]);if(_0x432923>-0x1)unanswered[_0x2dd013('0x16')](_0x432923,0x1);}transfers[_0x9f99ce[_0x2dd013('0x3e')]]&&(transfers[_0x9f99ce['uniqueid']]['agentcomplete']=!![],transfers[_0x9f99ce[_0x2dd013('0x3e')]][_0x2dd013('0x17')]=utils[_0x2dd013('0x15')](),transfers[_0x9f99ce['uniqueid']]['talktime']=utils[_0x2dd013('0x49')](transfers[_0x9f99ce['uniqueid']]['agentcompleteAt'],transfers[_0x9f99ce[_0x2dd013('0x3e')]][_0x2dd013('0x19')]),transfers[_0x9f99ce['uniqueid']][_0x2dd013('0x2a')]=_0x2dd013('0x4'),transfers[_0x9f99ce[_0x2dd013('0x3e')]]['lastevent']=_0x2dd013('0x4c'),writeDB(transfers[_0x9f99ce[_0x2dd013('0x3e')]],!![])),agents[_0x9f99ce['uniqueid']]&&agents[_0x9f99ce[_0x2dd013('0x3e')]]['agentconnectAt']&&(agents[_0x9f99ce[_0x2dd013('0x3e')]]['agentcomplete']=!![],agents[_0x9f99ce[_0x2dd013('0x3e')]][_0x2dd013('0x17')]=utils[_0x2dd013('0x15')](),agents[_0x9f99ce[_0x2dd013('0x3e')]]['talktime']=utils[_0x2dd013('0x49')](agents[_0x9f99ce[_0x2dd013('0x3e')]][_0x2dd013('0x17')],agents[_0x9f99ce[_0x2dd013('0x3e')]][_0x2dd013('0x19')]),agents[_0x9f99ce[_0x2dd013('0x3e')]][_0x2dd013('0x2a')]=agents[_0x9f99ce[_0x2dd013('0x3e')]][_0x2dd013('0x42')]?_0x2dd013('0x42'):_0x2dd013('0x4'),agents[_0x9f99ce[_0x2dd013('0x3e')]][_0x2dd013('0x10')]='complete',writeDB(agents[_0x9f99ce[_0x2dd013('0x3e')]]));}catch(_0x5ac4ca){utils[_0x2dd013('0x36')](_0x5ac4ca[_0x2dd013('0x1d')]);}}; \ No newline at end of file +const a1221_0x4a45=['clone','agentcalledAt','rejected','lastevent','transfertargetuniqueid','called','queuecallerabandon','blind','lodash','origtransfererlinkedid','destuniqueid','acwTimeout','complete','hangup','channel','type','format','origtransfereruniqueid','ATTENDED','agentringnoanswer','connectedlinenum','acwtime','calleridname','extension','secondtransfererlinkedid','agentacw','error','transfereruniqueid','ringtime','forIn','transferexten','answered_elsewhere','reason','agentcompleteAt','agentconnectAt','util','CreateVoiceAgentReport','stack','talktime','info','transfereeuniqueid','indexOf','membername','uniqueid','queue','then','push','agentringnoanswerAt','agententerreason','./utils','answeredelsewheremembername','blindtransfer','transfertype','request','holdtime','transferuniqueid','secondtransfereruniqueid','agentcomplete','calleridnum','now','timeout','diffTime','isNil','cause','acw','splice','connectedlinename','agentcalled'];(function(_0x2502d0,_0x4a4597){const _0x2bec82=function(_0xeb85af){while(--_0xeb85af){_0x2502d0['push'](_0x2502d0['shift']());}};_0x2bec82(++_0x4a4597);}(a1221_0x4a45,0x1b4));const a1221_0x2bec=function(_0x2502d0,_0x4a4597){_0x2502d0=_0x2502d0-0x0;let _0x2bec82=a1221_0x4a45[_0x2502d0];return _0x2bec82;};const _0x323e1c=a1221_0x2bec;'use strict';const _=require(_0x323e1c('0x30')),util=require(_0x323e1c('0x7')),utils=require(_0x323e1c('0x15')),agents={},transfers={},unanswered=[];function writeDB(_0xeb85af,_0x49aaa3){const _0xf0a5ca=_0x323e1c;utils[_0xf0a5ca('0xb')](util[_0xf0a5ca('0x38')]('AGENT|%s|%s|%s|%s|%s|%s|%s|%s',_0xeb85af['uniqueid'],_0xeb85af[_0xf0a5ca('0x36')],_0xeb85af[_0xf0a5ca('0x10')],_0xeb85af[_0xf0a5ca('0xe')],_0xeb85af['interface'],_0xeb85af['calleridnum'],_0xeb85af['connectedlinenum'],_0xeb85af[_0xf0a5ca('0x2b')])),_0xeb85af[_0xf0a5ca('0x10')]?utils['getVoiceQueueByName'](_0xeb85af[_0xf0a5ca('0x10')])[_0xf0a5ca('0x11')](function(_0x2abe88){const _0x387158=_0xf0a5ca;_0x2abe88&&(_0xeb85af[_0x387158('0x37')]=_0x2abe88['type'],_0xeb85af[_0x387158('0x41')]=_0xeb85af[_0x387158('0x1d')]?_0x2abe88[_0x387158('0x24')]:![],_0xeb85af[_0x387158('0x3d')]=_0xeb85af[_0x387158('0x41')]?_0x2abe88[_0x387158('0x33')]:0x0),utils[_0x387158('0x19')](_0x387158('0x8'),_0xeb85af);}):utils[_0xf0a5ca('0x19')](_0xf0a5ca('0x8'),_0xeb85af),_0x49aaa3?delete transfers[_0xeb85af[_0xf0a5ca('0xf')]]:delete agents[_0xeb85af['destuniqueid']];}exports[_0x323e1c('0x27')]=function(_0x390c6a){const _0x3719f6=_0x323e1c;try{agents[_0x390c6a[_0x3719f6('0x32')]]=_0x390c6a,agents[_0x390c6a[_0x3719f6('0x32')]][_0x3719f6('0x29')]=utils[_0x3719f6('0x1f')](),agents[_0x390c6a[_0x3719f6('0x32')]][_0x3719f6('0x2b')]=_0x3719f6('0x2d'),agents[_0x390c6a[_0x3719f6('0x32')]][_0x3719f6('0x3c')]=null,agents[_0x390c6a[_0x3719f6('0x32')]][_0x3719f6('0x26')]=null;}catch(_0x37b3ef){utils[_0x3719f6('0x42')](_0x37b3ef[_0x3719f6('0x9')]);}},exports['agentringnoanswer']=function(_0x716323){const _0x2f0028=_0x323e1c;try{!_[_0x2f0028('0x22')](agents[_0x716323[_0x2f0028('0x32')]])&&(agents[_0x716323[_0x2f0028('0x32')]]['agentringnoanswer']=!![],agents[_0x716323[_0x2f0028('0x32')]][_0x2f0028('0x13')]=utils['now'](),agents[_0x716323[_0x2f0028('0x32')]][_0x2f0028('0x2b')]=_0x2f0028('0x20'),agents[_0x716323[_0x2f0028('0x32')]]['reason']=_0x2f0028('0x20'),agents[_0x716323[_0x2f0028('0x32')]][_0x2f0028('0x1a')]=_0x716323[_0x2f0028('0x0')]?parseInt(_0x716323[_0x2f0028('0x0')])/0x3e8:0x0,agents[_0x716323['destuniqueid']][_0x2f0028('0xa')]=0x0,unanswered[_0x2f0028('0x12')](_0x716323[_0x2f0028('0x32')]));}catch(_0x182a1a){utils[_0x2f0028('0x42')](_0x182a1a[_0x2f0028('0x9')]);}},exports[_0x323e1c('0x2e')]=function(_0x11af33){const _0x277d14=_0x323e1c;try{_[_0x277d14('0x1')](agents,function(_0x393480){const _0x50652b=_0x277d14;_0x393480[_0x50652b('0xf')]==_0x11af33['uniqueid']&&!_['includes'](unanswered,_0x393480[_0x50652b('0x32')])&&(_0x393480[_0x50652b('0x3b')]=!![],_0x393480[_0x50652b('0x13')]=utils[_0x50652b('0x1f')](),_0x393480[_0x50652b('0x2b')]='abandoned',_0x393480[_0x50652b('0x4')]='abandoned',_0x393480[_0x50652b('0x1a')]=_0x11af33[_0x50652b('0x1a')],_0x393480[_0x50652b('0xa')]=0x0,writeDB(_0x393480));});}catch(_0x630183){utils[_0x277d14('0x42')](_0x630183[_0x277d14('0x9')]);}},exports['agentconnect']=function(_0x1d7adf){const _0x12a5b9=_0x323e1c;try{agents[_0x1d7adf[_0x12a5b9('0x32')]]&&(agents[_0x1d7adf[_0x12a5b9('0x32')]][_0x12a5b9('0x6')]=utils[_0x12a5b9('0x1f')](),agents[_0x1d7adf[_0x12a5b9('0x32')]][_0x12a5b9('0x3c')]=_0x1d7adf[_0x12a5b9('0x3c')],agents[_0x1d7adf[_0x12a5b9('0x32')]]['connectedlinename']=_0x1d7adf[_0x12a5b9('0x26')],agents[_0x1d7adf[_0x12a5b9('0x32')]][_0x12a5b9('0x1a')]=_0x1d7adf[_0x12a5b9('0x0')],agents[_0x1d7adf[_0x12a5b9('0x32')]][_0x12a5b9('0x2b')]='connect',_[_0x12a5b9('0x1')](agents,function(_0x89f41d){const _0x357f44=_0x12a5b9;_0x89f41d[_0x357f44('0x32')]!=_0x1d7adf[_0x357f44('0x32')]&&_0x89f41d[_0x357f44('0xf')]==_0x1d7adf[_0x357f44('0xf')]&&(_0x89f41d['talktime']=0x0,_0x89f41d[_0x357f44('0x1a')]=_0x1d7adf[_0x357f44('0x0')],_0x89f41d[_0x357f44('0x3b')]=!![],_0x89f41d[_0x357f44('0x13')]=utils[_0x357f44('0x1f')](),_0x89f41d[_0x357f44('0x2b')]='answered_elsewhere',_0x89f41d[_0x357f44('0x4')]=_0x357f44('0x3'),_0x89f41d['answeredelsewheredestinationuniqueid']=_0x1d7adf[_0x357f44('0x32')],_0x89f41d[_0x357f44('0x16')]=_0x1d7adf['membername'],writeDB(_0x89f41d));}));}catch(_0x113ece){utils[_0x12a5b9('0x42')](_0x113ece['stack']);}},exports[_0x323e1c('0x1d')]=function(_0x244ad7){const _0x47f8a2=_0x323e1c;try{!_[_0x47f8a2('0x22')](agents[_0x244ad7['destuniqueid']])&&(agents[_0x244ad7['destuniqueid']]['agentcomplete']=!![],agents[_0x244ad7[_0x47f8a2('0x32')]]['agentcompleteAt']=utils[_0x47f8a2('0x1f')](),agents[_0x244ad7[_0x47f8a2('0x32')]][_0x47f8a2('0xa')]=utils[_0x47f8a2('0x21')](agents[_0x244ad7[_0x47f8a2('0x32')]][_0x47f8a2('0x5')],agents[_0x244ad7[_0x47f8a2('0x32')]]['agentconnectAt']),agents[_0x244ad7['destuniqueid']][_0x47f8a2('0x4')]=_0x244ad7[_0x47f8a2('0x4')],agents[_0x244ad7['destuniqueid']][_0x47f8a2('0x2b')]=_0x47f8a2('0x34'),writeDB(agents[_0x244ad7[_0x47f8a2('0x32')]]));}catch(_0x30eea5){utils['error'](_0x30eea5['stack']);}},exports[_0x323e1c('0x17')]=function(_0x33ffd1){const _0x267f0f=_0x323e1c;try{!_[_0x267f0f('0x22')](agents[_0x33ffd1[_0x267f0f('0x43')]])&&(agents[_0x33ffd1['transfereruniqueid']]['transfer']=!![],agents[_0x33ffd1[_0x267f0f('0x43')]][_0x267f0f('0x18')]=_0x267f0f('0x2f'),agents[_0x33ffd1[_0x267f0f('0x43')]][_0x267f0f('0x2')]=_0x33ffd1[_0x267f0f('0x3f')],agents[_0x33ffd1[_0x267f0f('0x43')]][_0x267f0f('0x1b')]=agents[_0x33ffd1[_0x267f0f('0x43')]][_0x267f0f('0xf')]);}catch(_0x41e77c){utils[_0x267f0f('0x42')](_0x41e77c[_0x267f0f('0x9')]);}},exports['attendedtransfer']=function(_0x291718){const _0x18df57=_0x323e1c;try{if(_0x291718[_0x18df57('0x39')]==_0x291718[_0x18df57('0x31')])!_[_0x18df57('0x22')](agents[_0x291718[_0x18df57('0x1c')]])&&(agents[_0x291718[_0x18df57('0x1c')]]['transfer']=!![],agents[_0x291718[_0x18df57('0x1c')]][_0x18df57('0x18')]=_0x18df57('0x3a'),agents[_0x291718[_0x18df57('0x1c')]][_0x18df57('0x2')]=_0x291718['origtransfererexten'],agents[_0x291718[_0x18df57('0x1c')]][_0x18df57('0x1b')]=_0x291718[_0x18df57('0x39')]),_0x291718[_0x18df57('0xc')]&&agents[_0x291718[_0x18df57('0xc')]]&&(agents[_0x291718['transfereeuniqueid']][_0x18df57('0x14')]=0x1,transfers[_0x291718[_0x18df57('0xc')]]=_[_0x18df57('0x28')](agents[_0x291718[_0x18df57('0xc')]]),transfers[_0x291718['transfereeuniqueid']][_0x18df57('0x1e')]=agents[_0x291718[_0x18df57('0x1c')]][_0x18df57('0x1e')],transfers[_0x291718[_0x18df57('0xc')]]['calleridname']=agents[_0x291718['secondtransfereruniqueid']][_0x18df57('0x3e')],transfers[_0x291718[_0x18df57('0xc')]][_0x18df57('0x29')]=utils[_0x18df57('0x1f')](),transfers[_0x291718[_0x18df57('0xc')]][_0x18df57('0x6')]=utils['now'](),transfers[_0x291718['transfereeuniqueid']][_0x18df57('0x1a')]=0x0,transfers[_0x291718[_0x18df57('0xc')]][_0x18df57('0x14')]=0x2);else _0x291718[_0x18df57('0x1c')]==_0x291718[_0x18df57('0x40')]&&(!_[_0x18df57('0x22')](agents[_0x291718[_0x18df57('0x39')]])&&(agents[_0x291718[_0x18df57('0x39')]]['transfer']=!![],agents[_0x291718[_0x18df57('0x39')]][_0x18df57('0x18')]=_0x18df57('0x3a'),agents[_0x291718[_0x18df57('0x39')]]['transferexten']=_0x291718['secondtransfererexten'],agents[_0x291718['origtransfereruniqueid']][_0x18df57('0x1b')]=_0x291718[_0x18df57('0x1c')]),_0x291718[_0x18df57('0x2c')]&&agents[_0x291718[_0x18df57('0x2c')]]&&(agents[_0x291718[_0x18df57('0x2c')]]['agententerreason']=0x1,transfers[_0x291718[_0x18df57('0x2c')]]=_[_0x18df57('0x28')](agents[_0x291718[_0x18df57('0x2c')]]),transfers[_0x291718[_0x18df57('0x2c')]][_0x18df57('0x1e')]=agents[_0x291718['origtransfereruniqueid']][_0x18df57('0x1e')],transfers[_0x291718[_0x18df57('0x2c')]][_0x18df57('0x3e')]=agents[_0x291718[_0x18df57('0x39')]]['calleridname'],transfers[_0x291718['transfertargetuniqueid']][_0x18df57('0x29')]=utils[_0x18df57('0x1f')](),transfers[_0x291718[_0x18df57('0x2c')]][_0x18df57('0x6')]=utils[_0x18df57('0x1f')](),transfers[_0x291718[_0x18df57('0x2c')]][_0x18df57('0x1a')]=0x0,transfers[_0x291718[_0x18df57('0x2c')]][_0x18df57('0x14')]=0x2));}catch(_0x311150){utils['error'](_0x311150[_0x18df57('0x9')]);}},exports[_0x323e1c('0x35')]=function(_0x42d196){const _0x27b972=_0x323e1c;try{if(agents[_0x42d196['uniqueid']]&&agents[_0x42d196[_0x27b972('0xf')]][_0x27b972('0x4')]===_0x27b972('0x20')){_0x42d196[_0x27b972('0x23')]==='21'&&(agents[_0x42d196['uniqueid']][_0x27b972('0x4')]=_0x27b972('0x2a'),agents[_0x42d196[_0x27b972('0xf')]]['lastevent']=_0x27b972('0x2a'));writeDB(agents[_0x42d196['uniqueid']]);const _0x2a5739=unanswered[_0x27b972('0xd')](_0x42d196[_0x27b972('0xf')]);if(_0x2a5739>-0x1)unanswered[_0x27b972('0x25')](_0x2a5739,0x1);}transfers[_0x42d196[_0x27b972('0xf')]]&&(transfers[_0x42d196['uniqueid']]['agentcomplete']=!![],transfers[_0x42d196[_0x27b972('0xf')]][_0x27b972('0x5')]=utils[_0x27b972('0x1f')](),transfers[_0x42d196[_0x27b972('0xf')]][_0x27b972('0xa')]=utils[_0x27b972('0x21')](transfers[_0x42d196[_0x27b972('0xf')]][_0x27b972('0x5')],transfers[_0x42d196[_0x27b972('0xf')]][_0x27b972('0x6')]),transfers[_0x42d196[_0x27b972('0xf')]][_0x27b972('0x4')]='agent',transfers[_0x42d196[_0x27b972('0xf')]][_0x27b972('0x2b')]=_0x27b972('0x34'),writeDB(transfers[_0x42d196[_0x27b972('0xf')]],!![])),agents[_0x42d196[_0x27b972('0xf')]]&&agents[_0x42d196['uniqueid']][_0x27b972('0x6')]&&(agents[_0x42d196[_0x27b972('0xf')]][_0x27b972('0x1d')]=!![],agents[_0x42d196['uniqueid']][_0x27b972('0x5')]=utils['now'](),agents[_0x42d196[_0x27b972('0xf')]]['talktime']=utils['diffTime'](agents[_0x42d196['uniqueid']][_0x27b972('0x5')],agents[_0x42d196['uniqueid']]['agentconnectAt']),agents[_0x42d196[_0x27b972('0xf')]][_0x27b972('0x4')]=agents[_0x42d196[_0x27b972('0xf')]]['transfer']?'transfer':'agent',agents[_0x42d196['uniqueid']][_0x27b972('0x2b')]=_0x27b972('0x34'),writeDB(agents[_0x42d196[_0x27b972('0xf')]]));}catch(_0x4334ec){utils[_0x27b972('0x42')](_0x4334ec[_0x27b972('0x9')]);}}; \ No newline at end of file diff --git a/server/services/xdr/calls.controller.js b/server/services/xdr/calls.controller.js index affb2c5..bd7f720 100644 --- a/server/services/xdr/calls.controller.js +++ b/server/services/xdr/calls.controller.js @@ -1 +1 @@ -const a1222_0x17b1=['mohtime','_attended','ContactId','noop','systemanswertime','NO\x20ANSWER','FAILED','lastIndexOf','substring','varset','stack','startsWith','OutgoingSpoolFailed','newexten','answertime','endtime','accountcode','callerid','linkedid','uniqueid','billableseconds','hangup','then','transfertargetchannel','origtransfererchannel','split','sipcallid','transfer','execif','diffTime','lastapplication','xmd-originatecalleridnum','util','newchannel','BUSY','info','context','musiconholdstartAt','disposition','set','destination','duration','musiconholdstart','secondtransfererchannel','userfield','lastdata','application','UserId','value','lodash','xmd-phone','calleridnum','isNil','variable','now','xmd-queue','xmd-contactid','CALL|%s|%s|%s|%s|%s|%s|%s|%s','request','destinationchannel','format','xmd-callerid-preview','./utils','calleridname','appdata','starttime','toNumber','getUserByInternal','ANSWERED','source','xmcs-queue','localtwolinkedid','channel','error','xmd-cdrtype','type','toLowerCase','channelstate','outboundrouteid'];(function(_0x3126a9,_0x17b177){const _0x261973=function(_0x39be97){while(--_0x39be97){_0x3126a9['push'](_0x3126a9['shift']());}};_0x261973(++_0x17b177);}(a1222_0x17b1,0xc4));const a1222_0x2619=function(_0x3126a9,_0x17b177){_0x3126a9=_0x3126a9-0x0;let _0x261973=a1222_0x17b1[_0x3126a9];return _0x261973;};const _0x2b5b7a=a1222_0x2619;'use strict';const _=require(_0x2b5b7a('0xb')),util=require(_0x2b5b7a('0x49')),utils=require(_0x2b5b7a('0x18')),dispositions=[_0x2b5b7a('0x2e'),_0x2b5b7a('0x2f'),_0x2b5b7a('0x2f'),_0x2b5b7a('0x2e'),_0x2b5b7a('0x2e'),_0x2b5b7a('0x2e'),_0x2b5b7a('0x1e'),_0x2b5b7a('0x4b'),'FAILED',_0x2b5b7a('0x2f'),_0x2b5b7a('0x2f')],channels={};function writeDB(_0x39be97){const _0x2132fa=_0x2b5b7a;utils[_0x2132fa('0x4c')](util[_0x2132fa('0x16')](_0x2132fa('0x13'),_0x39be97[_0x2132fa('0x3c')],_0x39be97[_0x2132fa('0x22')],_0x39be97[_0x2132fa('0x25')],_0x39be97[_0x2132fa('0x39')],_0x39be97[_0x2132fa('0x1f')],_0x39be97[_0x2132fa('0x2')],_0x39be97[_0x2132fa('0x3a')],_0x39be97[_0x2132fa('0x0')])),_0x39be97[_0x2132fa('0x39')]?utils[_0x2132fa('0x1d')](_0x39be97[_0x2132fa('0x39')])[_0x2132fa('0x3f')](function(_0x560dc3){const _0xed1500=_0x2132fa;_0x560dc3&&(_0x39be97[_0xed1500('0x9')]=_0x560dc3['id']),utils[_0xed1500('0x14')]('CreateVoiceCallReport',_0x39be97);}):utils['request']('CreateVoiceCallReport',_0x39be97),channels[_0x39be97[_0x2132fa('0x3c')]]&&delete channels[_0x39be97[_0x2132fa('0x3c')]];}exports[_0x2b5b7a('0x4a')]=function(_0x41e651){const _0x3a74ee=_0x2b5b7a;try{_0x41e651[_0x3a74ee('0x3c')]==_0x41e651['linkedid']&&_0x41e651[_0x3a74ee('0x22')]!=_0x3a74ee('0x35')&&(channels[_0x41e651['uniqueid']]={'uniqueid':_0x41e651[_0x3a74ee('0x3c')],'accountcode':_0x41e651['accountcode'],'source':_0x41e651[_0x3a74ee('0xd')],'destination':_0x41e651['exten'],'destinationcontext':_0x41e651[_0x3a74ee('0x4d')],'channel':_0x41e651['channel'],'starttime':utils[_0x3a74ee('0x10')](),'answertime':null,'systemanswertime':null,'mohtime':0x0,'disposition':_0x3a74ee('0x2e'),'amaflags':'DOCUMENTATION'});}catch(_0x4be9ab){utils[_0x3a74ee('0x23')](_0x4be9ab[_0x3a74ee('0x33')]);}},exports['newstate']=function(_0x5b5d67){const _0x2d4d5b=_0x2b5b7a;try{if(!_[_0x2d4d5b('0xe')](channels[_0x5b5d67[_0x2d4d5b('0x3c')]])&&_0x5b5d67[_0x2d4d5b('0x27')]==0x6)_[_0x2d4d5b('0xe')](channels[_0x5b5d67[_0x2d4d5b('0x3c')]][_0x2d4d5b('0x2d')])&&(channels[_0x5b5d67[_0x2d4d5b('0x3c')]]['systemanswertime']=utils['now']());else!_[_0x2d4d5b('0xe')](channels[_0x5b5d67[_0x2d4d5b('0x3b')]])&&_0x5b5d67[_0x2d4d5b('0x27')]==0x6&&_0x5b5d67[_0x2d4d5b('0x4d')]!=_0x2d4d5b('0x44')&&(channels[_0x5b5d67[_0x2d4d5b('0x3b')]]['accountcode']=_0x5b5d67[_0x2d4d5b('0x39')],channels[_0x5b5d67[_0x2d4d5b('0x3b')]][_0x2d4d5b('0x15')]=_0x5b5d67['channel'],_[_0x2d4d5b('0xe')](channels[_0x5b5d67[_0x2d4d5b('0x3b')]][_0x2d4d5b('0x37')])&&(channels[_0x5b5d67['linkedid']]['answertime']=utils[_0x2d4d5b('0x10')]()),channels[_0x5b5d67['linkedid']]['disposition']=dispositions[_[_0x2d4d5b('0x1c')](_0x5b5d67[_0x2d4d5b('0x27')])]||_0x2d4d5b('0x1e'));}catch(_0x564a35){utils['error'](_0x564a35[_0x2d4d5b('0x33')]);}},exports[_0x2b5b7a('0x3e')]=function(_0x3a816f){const _0x1b33fd=_0x2b5b7a;try{!_[_0x1b33fd('0xe')](channels[_0x3a816f[_0x1b33fd('0x3c')]])&&(_[_0x1b33fd('0xe')](channels[_0x3a816f[_0x1b33fd('0x3c')]][_0x1b33fd('0x3a')])&&(channels[_0x3a816f[_0x1b33fd('0x3c')]][_0x1b33fd('0x3a')]=_0x3a816f[_0x1b33fd('0x19')]+'\x20<'+_0x3a816f[_0x1b33fd('0xd')]+'>'),channels[_0x3a816f[_0x1b33fd('0x3c')]][_0x1b33fd('0x38')]=utils[_0x1b33fd('0x10')](),channels[_0x3a816f[_0x1b33fd('0x3c')]][_0x1b33fd('0x3')]=utils[_0x1b33fd('0x46')](channels[_0x3a816f['uniqueid']][_0x1b33fd('0x38')],channels[_0x3a816f['uniqueid']][_0x1b33fd('0x1b')]),channels[_0x3a816f[_0x1b33fd('0x3c')]][_0x1b33fd('0x3d')]=channels[_0x3a816f[_0x1b33fd('0x3c')]][_0x1b33fd('0x37')]?utils[_0x1b33fd('0x46')](channels[_0x3a816f[_0x1b33fd('0x3c')]][_0x1b33fd('0x38')],channels[_0x3a816f[_0x1b33fd('0x3c')]][_0x1b33fd('0x37')]):0x0,writeDB(channels[_0x3a816f[_0x1b33fd('0x3c')]]));}catch(_0x538319){utils[_0x1b33fd('0x23')](_0x538319[_0x1b33fd('0x33')]);}},exports['attendedtransfer']=function(_0x9f523b){const _0x1d7157=_0x2b5b7a;try{if(!_[_0x1d7157('0xe')](channels[_0x9f523b[_0x1d7157('0x21')]])){if(channels[_0x9f523b[_0x1d7157('0x21')]][_0x1d7157('0x22')]==_0x9f523b['transfereechannel'])channels[_0x9f523b[_0x1d7157('0x21')]][_0x1d7157('0x15')]=_0x9f523b[_0x1d7157('0x5')],channels[_0x9f523b[_0x1d7157('0x21')]][_0x1d7157('0x6')]='_attended';else(channels[_0x9f523b[_0x1d7157('0x21')]][_0x1d7157('0x22')]=_0x9f523b[_0x1d7157('0x40')])&&(channels[_0x9f523b['localtwolinkedid']][_0x1d7157('0x15')]=_0x9f523b[_0x1d7157('0x41')],channels[_0x9f523b[_0x1d7157('0x21')]][_0x1d7157('0x6')]=_0x1d7157('0x2a'));}}catch(_0x24715e){utils[_0x1d7157('0x23')](_0x24715e[_0x1d7157('0x33')]);}},exports[_0x2b5b7a('0x4')]=function(_0x370b1f){const _0x561651=_0x2b5b7a;try{!_[_0x561651('0xe')](channels[_0x370b1f[_0x561651('0x3c')]])&&(channels[_0x370b1f[_0x561651('0x3c')]][_0x561651('0x4e')]=utils[_0x561651('0x10')]());}catch(_0x2b2885){utils[_0x561651('0x23')](_0x2b2885[_0x561651('0x33')]);}},exports['musiconholdstop']=function(_0x162a02){const _0x320478=_0x2b5b7a;try{!_['isNil'](channels[_0x162a02[_0x320478('0x3c')]])&&(!_[_0x320478('0xe')](channels[_0x162a02[_0x320478('0x3c')]]['musiconholdstartAt'])&&(channels[_0x162a02['uniqueid']][_0x320478('0x29')]+=utils[_0x320478('0x46')](utils[_0x320478('0x10')](),channels[_0x162a02[_0x320478('0x3c')]][_0x320478('0x4e')]),delete channels[_0x162a02[_0x320478('0x3c')]][_0x320478('0x4e')]));}catch(_0x3687c6){utils[_0x320478('0x23')](_0x3687c6[_0x320478('0x33')]);}},exports[_0x2b5b7a('0x32')]=function(_0x589aca){const _0x17adae=_0x2b5b7a;try{!_[_0x17adae('0xe')](channels[_0x589aca['uniqueid']])&&(!_[_0x17adae('0xe')](_0x589aca['variable'][_0x17adae('0x48')])&&(channels[_0x589aca[_0x17adae('0x3c')]][_0x17adae('0x1f')]=_0x589aca[_0x17adae('0xa')]),!_[_0x17adae('0xe')](_0x589aca[_0x17adae('0xf')][_0x17adae('0xc')])&&(channels[_0x589aca[_0x17adae('0x3c')]][_0x17adae('0x2')]=_0x589aca[_0x17adae('0xa')],channels[_0x589aca['uniqueid']][_0x17adae('0x3a')]='\x22'+_0x589aca[_0x17adae('0xa')]+'\x22\x20<'+_0x589aca[_0x17adae('0xa')]+'>'),(!_['isNil'](_0x589aca[_0x17adae('0xf')][_0x17adae('0x17')])||!_[_0x17adae('0xe')](_0x589aca[_0x17adae('0xf')]['xmd-callerid']))&&(channels[_0x589aca[_0x17adae('0x3c')]][_0x17adae('0x3a')]=_0x589aca[_0x17adae('0xa')]),(!_[_0x17adae('0xe')](_0x589aca[_0x17adae('0xf')][_0x17adae('0x11')])||!_[_0x17adae('0xe')](_0x589aca[_0x17adae('0xf')][_0x17adae('0x20')]))&&(channels[_0x589aca['uniqueid']][_0x17adae('0x47')]='Queue',channels[_0x589aca['uniqueid']][_0x17adae('0x7')]=_0x589aca[_0x17adae('0xa')],channels[_0x589aca['uniqueid']]['queue']=!![]),!_[_0x17adae('0xe')](_0x589aca[_0x17adae('0xf')][_0x17adae('0x12')])&&(channels[_0x589aca[_0x17adae('0x3c')]][_0x17adae('0x2b')]=_0x589aca[_0x17adae('0xa')]),!_[_0x17adae('0xe')](_0x589aca['variable'][_0x17adae('0x24')])&&(channels[_0x589aca[_0x17adae('0x3c')]]['type']=_0x589aca['value']),!_[_0x17adae('0xe')](_0x589aca['variable'][_0x17adae('0x28')])&&(channels[_0x589aca[_0x17adae('0x3c')]]['routeid']=_0x589aca['value']),!_[_0x17adae('0xe')](_0x589aca[_0x17adae('0xf')][_0x17adae('0x43')])&&(channels[_0x589aca[_0x17adae('0x3c')]][_0x17adae('0x43')]=_0x589aca[_0x17adae('0xa')]));}catch(_0x390aca){utils[_0x17adae('0x23')](_0x390aca[_0x17adae('0x33')]);}},exports[_0x2b5b7a('0x36')]=function(_0x1026d8){const _0x196d3c=_0x2b5b7a;try{if(!_[_0x196d3c('0xe')](channels[_0x1026d8[_0x196d3c('0x3c')]])){if(_0x1026d8[_0x196d3c('0x8')][_0x196d3c('0x26')]()==_0x196d3c('0x1')&&_[_0x196d3c('0x34')](_0x1026d8[_0x196d3c('0x1a')]['toLowerCase'](),'cdr')){const _0xa7cf1d=_0x1026d8[_0x196d3c('0x1a')][_0x196d3c('0x42')]('='),_0x2c1b02=_0xa7cf1d[0x0][_0x196d3c('0x31')](_0xa7cf1d[0x0][_0x196d3c('0x30')]('(')+0x1,_0xa7cf1d[0x0]['lastIndexOf'](')')),_0x4d8f41=_0xa7cf1d[0x1];channels[_0x1026d8[_0x196d3c('0x3c')]][_0x2c1b02]=_0x4d8f41;}!_['includes']([_0x196d3c('0x3e'),_0x196d3c('0x2c'),_0x196d3c('0x45'),_0x196d3c('0x1'),'gotoif'],_0x1026d8[_0x196d3c('0x8')][_0x196d3c('0x26')]())&&(channels[_0x1026d8[_0x196d3c('0x3c')]][_0x196d3c('0x47')]=_0x1026d8[_0x196d3c('0x8')],channels[_0x1026d8[_0x196d3c('0x3c')]][_0x196d3c('0x7')]=_0x1026d8[_0x196d3c('0x1a')]);}}catch(_0x4c0dd1){utils['error'](_0x4c0dd1['stack']);}}; \ No newline at end of file +const a1222_0x2539=['then','source','toNumber','linkedid','attendedtransfer','NO\x20ANSWER','request','BUSY','calleridnum','toLowerCase','value','endtime','cdr','util','xmd-callerid','xmcs-queue','billableseconds','getUserByInternal','uniqueid','transfereechannel','userfield','includes','origtransfererchannel','lastIndexOf','answertime','queue','stack','context','isNil','varset','variable','CALL|%s|%s|%s|%s|%s|%s|%s|%s','channelstate','now','xmd-contactid','destination','application','mohtime','xmd-phone','xmd-queue','set','starttime','type','substring','systemanswertime','disposition','routeid','./utils','musiconholdstartAt','sipcallid','channel','newchannel','gotoif','xmd-originatecalleridnum','localtwolinkedid','error','secondtransfererchannel','_attended','xmd-cdrtype','callerid','accountcode','UserId','appdata','transfertargetchannel','FAILED','ContactId','ANSWERED','destinationchannel','hangup','lodash','diffTime','format','startsWith','musiconholdstop','info','transfer'];(function(_0x162eb6,_0x25396c){const _0x3d0e85=function(_0x4c6de2){while(--_0x4c6de2){_0x162eb6['push'](_0x162eb6['shift']());}};_0x3d0e85(++_0x25396c);}(a1222_0x2539,0xbb));const a1222_0x3d0e=function(_0x162eb6,_0x25396c){_0x162eb6=_0x162eb6-0x0;let _0x3d0e85=a1222_0x2539[_0x162eb6];return _0x3d0e85;};const _0xaf5955=a1222_0x3d0e;'use strict';const _=require(_0xaf5955('0x22')),util=require(_0xaf5955('0x36')),utils=require(_0xaf5955('0xc')),dispositions=[_0xaf5955('0x2e'),_0xaf5955('0x1d'),_0xaf5955('0x1d'),'NO\x20ANSWER','NO\x20ANSWER',_0xaf5955('0x2e'),_0xaf5955('0x1f'),_0xaf5955('0x30'),_0xaf5955('0x1d'),_0xaf5955('0x1d'),_0xaf5955('0x1d')],channels={};function writeDB(_0x4c6de2){const _0x102d1a=_0xaf5955;utils[_0x102d1a('0x27')](util[_0x102d1a('0x24')](_0x102d1a('0x48'),_0x4c6de2[_0x102d1a('0x3b')],_0x4c6de2['channel'],_0x4c6de2[_0x102d1a('0x7')],_0x4c6de2[_0x102d1a('0x19')],_0x4c6de2['source'],_0x4c6de2[_0x102d1a('0x0')],_0x4c6de2[_0x102d1a('0x18')],_0x4c6de2[_0x102d1a('0xa')])),_0x4c6de2[_0x102d1a('0x19')]?utils[_0x102d1a('0x3a')](_0x4c6de2[_0x102d1a('0x19')])[_0x102d1a('0x29')](function(_0x1261a5){const _0x5cbe73=_0x102d1a;_0x1261a5&&(_0x4c6de2[_0x5cbe73('0x1a')]=_0x1261a5['id']),utils[_0x5cbe73('0x2f')]('CreateVoiceCallReport',_0x4c6de2);}):utils[_0x102d1a('0x2f')]('CreateVoiceCallReport',_0x4c6de2),channels[_0x4c6de2[_0x102d1a('0x3b')]]&&delete channels[_0x4c6de2[_0x102d1a('0x3b')]];}exports[_0xaf5955('0x10')]=function(_0x312c50){const _0x7f6981=_0xaf5955;try{_0x312c50[_0x7f6981('0x3b')]==_0x312c50['linkedid']&&_0x312c50[_0x7f6981('0xf')]!='OutgoingSpoolFailed'&&(channels[_0x312c50[_0x7f6981('0x3b')]]={'uniqueid':_0x312c50[_0x7f6981('0x3b')],'accountcode':_0x312c50[_0x7f6981('0x19')],'source':_0x312c50[_0x7f6981('0x31')],'destination':_0x312c50['exten'],'destinationcontext':_0x312c50[_0x7f6981('0x44')],'channel':_0x312c50['channel'],'starttime':utils[_0x7f6981('0x4a')](),'answertime':null,'systemanswertime':null,'mohtime':0x0,'disposition':_0x7f6981('0x2e'),'amaflags':'DOCUMENTATION'});}catch(_0x10e8ab){utils['error'](_0x10e8ab[_0x7f6981('0x43')]);}},exports['newstate']=function(_0x527d75){const _0x489637=_0xaf5955;try{if(!_[_0x489637('0x45')](channels[_0x527d75['uniqueid']])&&_0x527d75['channelstate']==0x6)_[_0x489637('0x45')](channels[_0x527d75[_0x489637('0x3b')]][_0x489637('0x9')])&&(channels[_0x527d75[_0x489637('0x3b')]][_0x489637('0x9')]=utils[_0x489637('0x4a')]());else!_[_0x489637('0x45')](channels[_0x527d75[_0x489637('0x2c')]])&&_0x527d75[_0x489637('0x49')]==0x6&&_0x527d75[_0x489637('0x44')]!=_0x489637('0x28')&&(channels[_0x527d75[_0x489637('0x2c')]]['accountcode']=_0x527d75['accountcode'],channels[_0x527d75[_0x489637('0x2c')]]['destinationchannel']=_0x527d75['channel'],_[_0x489637('0x45')](channels[_0x527d75[_0x489637('0x2c')]][_0x489637('0x41')])&&(channels[_0x527d75[_0x489637('0x2c')]]['answertime']=utils[_0x489637('0x4a')]()),channels[_0x527d75[_0x489637('0x2c')]][_0x489637('0xa')]=dispositions[_[_0x489637('0x2b')](_0x527d75[_0x489637('0x49')])]||_0x489637('0x1f'));}catch(_0x3caffa){utils['error'](_0x3caffa[_0x489637('0x43')]);}},exports[_0xaf5955('0x21')]=function(_0x58c54b){const _0x2528e9=_0xaf5955;try{!_[_0x2528e9('0x45')](channels[_0x58c54b[_0x2528e9('0x3b')]])&&(_[_0x2528e9('0x45')](channels[_0x58c54b[_0x2528e9('0x3b')]][_0x2528e9('0x18')])&&(channels[_0x58c54b[_0x2528e9('0x3b')]][_0x2528e9('0x18')]=_0x58c54b['calleridname']+'\x20<'+_0x58c54b['calleridnum']+'>'),channels[_0x58c54b[_0x2528e9('0x3b')]][_0x2528e9('0x34')]=utils[_0x2528e9('0x4a')](),channels[_0x58c54b[_0x2528e9('0x3b')]]['duration']=utils[_0x2528e9('0x23')](channels[_0x58c54b['uniqueid']]['endtime'],channels[_0x58c54b[_0x2528e9('0x3b')]][_0x2528e9('0x6')]),channels[_0x58c54b[_0x2528e9('0x3b')]][_0x2528e9('0x39')]=channels[_0x58c54b[_0x2528e9('0x3b')]][_0x2528e9('0x41')]?utils[_0x2528e9('0x23')](channels[_0x58c54b[_0x2528e9('0x3b')]][_0x2528e9('0x34')],channels[_0x58c54b[_0x2528e9('0x3b')]][_0x2528e9('0x41')]):0x0,writeDB(channels[_0x58c54b[_0x2528e9('0x3b')]]));}catch(_0x29b147){utils[_0x2528e9('0x14')](_0x29b147[_0x2528e9('0x43')]);}},exports[_0xaf5955('0x2d')]=function(_0x622436){const _0x23f776=_0xaf5955;try{if(!_[_0x23f776('0x45')](channels[_0x622436[_0x23f776('0x13')]])){if(channels[_0x622436['localtwolinkedid']][_0x23f776('0xf')]==_0x622436[_0x23f776('0x3c')])channels[_0x622436[_0x23f776('0x13')]][_0x23f776('0x20')]=_0x622436[_0x23f776('0x15')],channels[_0x622436[_0x23f776('0x13')]][_0x23f776('0x3d')]=_0x23f776('0x16');else(channels[_0x622436['localtwolinkedid']][_0x23f776('0xf')]=_0x622436[_0x23f776('0x1c')])&&(channels[_0x622436[_0x23f776('0x13')]][_0x23f776('0x20')]=_0x622436[_0x23f776('0x3f')],channels[_0x622436[_0x23f776('0x13')]][_0x23f776('0x3d')]=_0x23f776('0x16'));}}catch(_0x3f22fd){utils['error'](_0x3f22fd['stack']);}},exports['musiconholdstart']=function(_0x348293){const _0x40eff9=_0xaf5955;try{!_['isNil'](channels[_0x348293[_0x40eff9('0x3b')]])&&(channels[_0x348293['uniqueid']]['musiconholdstartAt']=utils[_0x40eff9('0x4a')]());}catch(_0x3ab6c2){utils[_0x40eff9('0x14')](_0x3ab6c2[_0x40eff9('0x43')]);}},exports[_0xaf5955('0x26')]=function(_0x8974ce){const _0x16bdf8=_0xaf5955;try{!_[_0x16bdf8('0x45')](channels[_0x8974ce[_0x16bdf8('0x3b')]])&&(!_[_0x16bdf8('0x45')](channels[_0x8974ce[_0x16bdf8('0x3b')]]['musiconholdstartAt'])&&(channels[_0x8974ce[_0x16bdf8('0x3b')]][_0x16bdf8('0x2')]+=utils['diffTime'](utils[_0x16bdf8('0x4a')](),channels[_0x8974ce[_0x16bdf8('0x3b')]]['musiconholdstartAt']),delete channels[_0x8974ce[_0x16bdf8('0x3b')]][_0x16bdf8('0xd')]));}catch(_0x304060){utils['error'](_0x304060['stack']);}},exports[_0xaf5955('0x46')]=function(_0x3fce5b){const _0xc45c26=_0xaf5955;try{!_['isNil'](channels[_0x3fce5b[_0xc45c26('0x3b')]])&&(!_[_0xc45c26('0x45')](_0x3fce5b[_0xc45c26('0x47')][_0xc45c26('0x12')])&&(channels[_0x3fce5b['uniqueid']][_0xc45c26('0x2a')]=_0x3fce5b[_0xc45c26('0x33')]),!_[_0xc45c26('0x45')](_0x3fce5b[_0xc45c26('0x47')][_0xc45c26('0x3')])&&(channels[_0x3fce5b[_0xc45c26('0x3b')]]['destination']=_0x3fce5b['value'],channels[_0x3fce5b['uniqueid']]['callerid']='\x22'+_0x3fce5b['value']+'\x22\x20<'+_0x3fce5b[_0xc45c26('0x33')]+'>'),(!_[_0xc45c26('0x45')](_0x3fce5b[_0xc45c26('0x47')]['xmd-callerid-preview'])||!_[_0xc45c26('0x45')](_0x3fce5b['variable'][_0xc45c26('0x37')]))&&(channels[_0x3fce5b['uniqueid']][_0xc45c26('0x18')]=_0x3fce5b['value']),(!_[_0xc45c26('0x45')](_0x3fce5b[_0xc45c26('0x47')][_0xc45c26('0x4')])||!_[_0xc45c26('0x45')](_0x3fce5b[_0xc45c26('0x47')][_0xc45c26('0x38')]))&&(channels[_0x3fce5b[_0xc45c26('0x3b')]]['lastapplication']='Queue',channels[_0x3fce5b['uniqueid']]['lastdata']=_0x3fce5b['value'],channels[_0x3fce5b[_0xc45c26('0x3b')]][_0xc45c26('0x42')]=!![]),!_[_0xc45c26('0x45')](_0x3fce5b[_0xc45c26('0x47')][_0xc45c26('0x4b')])&&(channels[_0x3fce5b[_0xc45c26('0x3b')]][_0xc45c26('0x1e')]=_0x3fce5b['value']),!_[_0xc45c26('0x45')](_0x3fce5b[_0xc45c26('0x47')][_0xc45c26('0x17')])&&(channels[_0x3fce5b[_0xc45c26('0x3b')]][_0xc45c26('0x7')]=_0x3fce5b[_0xc45c26('0x33')]),!_[_0xc45c26('0x45')](_0x3fce5b[_0xc45c26('0x47')]['outboundrouteid'])&&(channels[_0x3fce5b['uniqueid']][_0xc45c26('0xb')]=_0x3fce5b[_0xc45c26('0x33')]),!_[_0xc45c26('0x45')](_0x3fce5b[_0xc45c26('0x47')][_0xc45c26('0xe')])&&(channels[_0x3fce5b['uniqueid']][_0xc45c26('0xe')]=_0x3fce5b[_0xc45c26('0x33')]));}catch(_0x36dc52){utils[_0xc45c26('0x14')](_0x36dc52[_0xc45c26('0x43')]);}},exports['newexten']=function(_0xbed2ba){const _0x309d71=_0xaf5955;try{if(!_[_0x309d71('0x45')](channels[_0xbed2ba[_0x309d71('0x3b')]])){if(_0xbed2ba[_0x309d71('0x1')]['toLowerCase']()==_0x309d71('0x5')&&_[_0x309d71('0x25')](_0xbed2ba['appdata'][_0x309d71('0x32')](),_0x309d71('0x35'))){const _0x5a5c62=_0xbed2ba[_0x309d71('0x1b')]['split']('='),_0x558af0=_0x5a5c62[0x0][_0x309d71('0x8')](_0x5a5c62[0x0][_0x309d71('0x40')]('(')+0x1,_0x5a5c62[0x0][_0x309d71('0x40')](')')),_0x1d5622=_0x5a5c62[0x1];channels[_0xbed2ba[_0x309d71('0x3b')]][_0x558af0]=_0x1d5622;}!_[_0x309d71('0x3e')](['hangup','noop','execif',_0x309d71('0x5'),_0x309d71('0x11')],_0xbed2ba[_0x309d71('0x1')]['toLowerCase']())&&(channels[_0xbed2ba[_0x309d71('0x3b')]]['lastapplication']=_0xbed2ba[_0x309d71('0x1')],channels[_0xbed2ba[_0x309d71('0x3b')]]['lastdata']=_0xbed2ba[_0x309d71('0x1b')]);}}catch(_0x3447fe){utils[_0x309d71('0x14')](_0x3447fe['stack']);}}; \ No newline at end of file diff --git a/server/services/xdr/core.controller.js b/server/services/xdr/core.controller.js index 2e10a85..0b0a97b 100644 --- a/server/services/xdr/core.controller.js +++ b/server/services/xdr/core.controller.js @@ -1 +1 @@ -const a1223_0x3a80=['SHUTDOWN','FULLYBOOTED','error','CLOSE','shutdown','fullybooted','./utils','info'];(function(_0x53420a,_0x3a801a){const _0x4c687e=function(_0xe6106d){while(--_0xe6106d){_0x53420a['push'](_0x53420a['shift']());}};_0x4c687e(++_0x3a801a);}(a1223_0x3a80,0x12c));const a1223_0x4c68=function(_0x53420a,_0x3a801a){_0x53420a=_0x53420a-0x0;let _0x4c687e=a1223_0x3a80[_0x53420a];return _0x4c687e;};const _0xf7cac4=a1223_0x4c68;'use strict';const utils=require(_0xf7cac4('0x2'));exports['connect']=function(){utils['info']('CONNECTED');},exports[_0xf7cac4('0x0')]=function(){const _0x487508=_0xf7cac4;utils[_0x487508('0x3')](_0x487508('0x4'));},exports[_0xf7cac4('0x1')]=function(){const _0x17dd86=_0xf7cac4;utils[_0x17dd86('0x3')](_0x17dd86('0x5'));},exports[_0xf7cac4('0x6')]=function(_0xe6106d){const _0xd09b91=_0xf7cac4;utils[_0xd09b91('0x6')](_0xe6106d);},exports['close']=function(){const _0x69ba88=_0xf7cac4;utils[_0x69ba88('0x3')](_0x69ba88('0x7'));},exports['managerevent']=function(){}; \ No newline at end of file +const a1223_0x2853=['info','fullybooted','FULLYBOOTED','./utils','error','connect','CLOSE','CONNECTED','close','managerevent'];(function(_0x408896,_0x2853fb){const _0x5e4986=function(_0x38c8a8){while(--_0x38c8a8){_0x408896['push'](_0x408896['shift']());}};_0x5e4986(++_0x2853fb);}(a1223_0x2853,0x7d));const a1223_0x5e49=function(_0x408896,_0x2853fb){_0x408896=_0x408896-0x0;let _0x5e4986=a1223_0x2853[_0x408896];return _0x5e4986;};const _0x2aafb5=a1223_0x5e49;'use strict';const utils=require(_0x2aafb5('0x8'));exports[_0x2aafb5('0x0')]=function(){const _0x49a429=_0x2aafb5;utils['info'](_0x49a429('0x2'));},exports['shutdown']=function(){const _0x478ffa=_0x2aafb5;utils[_0x478ffa('0x5')]('SHUTDOWN');},exports[_0x2aafb5('0x6')]=function(){const _0xfba796=_0x2aafb5;utils[_0xfba796('0x5')](_0xfba796('0x7'));},exports[_0x2aafb5('0x9')]=function(_0x38c8a8){const _0x5f230b=_0x2aafb5;utils[_0x5f230b('0x9')](_0x38c8a8);},exports[_0x2aafb5('0x3')]=function(){const _0x4dee0a=_0x2aafb5;utils[_0x4dee0a('0x5')](_0x4dee0a('0x1'));},exports[_0x2aafb5('0x4')]=function(){}; \ No newline at end of file diff --git a/server/services/xdr/dials.controller.js b/server/services/xdr/dials.controller.js index 5439664..b219f14 100644 --- a/server/services/xdr/dials.controller.js +++ b/server/services/xdr/dials.controller.js @@ -1 +1 @@ -const a1224_0xdce2=['connectedlinenum','application','complete','format','dialstatus','now','uniqueid','diffTime','set','varset','billableseconds','called','CreateVoiceDialReport','stack','./utils','answertime','assign','channel','variable','hangup','value','split','toLowerCase','ANSWER','isNil','error','util','info','duration','starttime','holdtime','appdata','endtime','lastevent','startsWith','dialstring'];(function(_0x5e5fc2,_0xdce257){const _0x4b877b=function(_0x17ff89){while(--_0x17ff89){_0x5e5fc2['push'](_0x5e5fc2['shift']());}};_0x4b877b(++_0xdce257);}(a1224_0xdce2,0x19e));const a1224_0x4b87=function(_0x5e5fc2,_0xdce257){_0x5e5fc2=_0x5e5fc2-0x0;let _0x4b877b=a1224_0xdce2[_0x5e5fc2];return _0x4b877b;};const _0x1fdcca=a1224_0x4b87;'use strict';const _=require('lodash'),util=require(_0x1fdcca('0x8')),utils=require(_0x1fdcca('0x20')),dials={};function writeDB(_0x17ff89){const _0x3116c8=_0x1fdcca;utils[_0x3116c8('0x9')](util[_0x3116c8('0x15')]('DIAL|%s|%s|%s|%s|%s|%s',_0x17ff89[_0x3116c8('0x18')],_0x17ff89[_0x3116c8('0x23')],_0x17ff89[_0x3116c8('0x11')],_0x17ff89['calleridnum'],_0x17ff89[_0x3116c8('0x12')],_0x17ff89['dialstatus'])),utils['request'](_0x3116c8('0x1e'),_0x17ff89),delete dials[_0x17ff89[_0x3116c8('0x18')]];}exports['newexten']=function(_0x56d483){const _0x366830=_0x1fdcca;try{if(_0x56d483[_0x366830('0x13')][_0x366830('0x4')]()==_0x366830('0x1a')&&_[_0x366830('0x10')](_0x56d483[_0x366830('0xd')][_0x366830('0x4')](),'cdr(routeid)')){const _0x25f104=_0x56d483[_0x366830('0xd')][_0x366830('0x3')]('=');dials[_0x56d483[_0x366830('0x18')]]={'routeId':_0x25f104[0x1]};}}catch(_0x129467){utils[_0x366830('0x7')](_0x129467[_0x366830('0x1f')]);}},exports[_0x1fdcca('0x1b')]=function(_0x40b208){const _0x5455a2=_0x1fdcca;try{!_[_0x5455a2('0x6')](_0x40b208[_0x5455a2('0x0')]['outboundrouteid'])&&(dials[_0x40b208[_0x5455a2('0x18')]]={'routeId':_0x40b208[_0x5455a2('0x2')]});}catch(_0x134cef){utils[_0x5455a2('0x7')](_0x134cef[_0x5455a2('0x1f')]);}},exports['dialbegin']=function(_0x157b7f){const _0x390836=_0x1fdcca;try{!_[_0x390836('0x6')](dials[_0x157b7f[_0x390836('0x18')]])&&(dials[_0x157b7f['uniqueid']]=_[_0x390836('0x22')](dials[_0x157b7f[_0x390836('0x18')]],_0x157b7f),dials[_0x157b7f['uniqueid']][_0x390836('0xb')]=utils[_0x390836('0x17')](),dials[_0x157b7f[_0x390836('0x18')]][_0x390836('0xf')]=_0x390836('0x1d'));}catch(_0x2fd1a2){utils[_0x390836('0x7')](_0x2fd1a2['stack']);}},exports['dialend']=function(_0x1071fb){const _0xc44529=_0x1fdcca;try{!_[_0xc44529('0x6')](dials[_0x1071fb[_0xc44529('0x18')]])&&(dials[_0x1071fb[_0xc44529('0x18')]]['dialstatus']=_0x1071fb[_0xc44529('0x16')],_0x1071fb[_0xc44529('0x16')]==_0xc44529('0x5')&&(dials[_0x1071fb[_0xc44529('0x18')]]=_['assign'](dials[_0x1071fb[_0xc44529('0x18')]],_0x1071fb),dials[_0x1071fb[_0xc44529('0x18')]][_0xc44529('0x21')]=utils[_0xc44529('0x17')](),dials[_0x1071fb[_0xc44529('0x18')]]['lastevent']='connect'));}catch(_0x21d9fb){utils[_0xc44529('0x7')](_0x21d9fb['stack']);}},exports[_0x1fdcca('0x1')]=function(_0x46a348){const _0x20c4f6=_0x1fdcca;try{!_[_0x20c4f6('0x6')](dials[_0x46a348[_0x20c4f6('0x18')]])&&(dials[_0x46a348['uniqueid']]=_[_0x20c4f6('0x22')](dials[_0x46a348[_0x20c4f6('0x18')]],{'endtime':utils[_0x20c4f6('0x17')](),'lastevent':_0x20c4f6('0x14')}),dials[_0x46a348[_0x20c4f6('0x18')]][_0x20c4f6('0xa')]=utils[_0x20c4f6('0x19')](dials[_0x46a348[_0x20c4f6('0x18')]][_0x20c4f6('0xe')],dials[_0x46a348[_0x20c4f6('0x18')]]['starttime']),dials[_0x46a348[_0x20c4f6('0x18')]][_0x20c4f6('0xc')]=utils[_0x20c4f6('0x19')](dials[_0x46a348[_0x20c4f6('0x18')]][_0x20c4f6('0x21')]||dials[_0x46a348[_0x20c4f6('0x18')]]['endtime'],dials[_0x46a348[_0x20c4f6('0x18')]]['starttime']),dials[_0x46a348[_0x20c4f6('0x18')]][_0x20c4f6('0x1c')]=dials[_0x46a348[_0x20c4f6('0x18')]][_0x20c4f6('0x21')]?utils[_0x20c4f6('0x19')](dials[_0x46a348[_0x20c4f6('0x18')]]['endtime'],dials[_0x46a348[_0x20c4f6('0x18')]][_0x20c4f6('0x21')]):0x0,writeDB(dials[_0x46a348[_0x20c4f6('0x18')]]));}catch(_0x3fa131){utils['error'](_0x3fa131['stack']);}}; \ No newline at end of file +const a1224_0x6796=['util','holdtime','lastevent','duration','split','dialend','startsWith','connect','value','calleridnum','answertime','toLowerCase','dialbegin','endtime','CreateVoiceDialReport','starttime','ANSWER','application','error','request','lodash','set','./utils','stack','channel','complete','called','newexten','diffTime','appdata','cdr(routeid)','info','assign','dialstring','billableseconds','dialstatus','variable','connectedlinenum','now','uniqueid','isNil'];(function(_0x107026,_0x6796ac){const _0x5d9ecf=function(_0x55eab7){while(--_0x55eab7){_0x107026['push'](_0x107026['shift']());}};_0x5d9ecf(++_0x6796ac);}(a1224_0x6796,0x66));const a1224_0x5d9e=function(_0x107026,_0x6796ac){_0x107026=_0x107026-0x0;let _0x5d9ecf=a1224_0x6796[_0x107026];return _0x5d9ecf;};const _0x27d44f=a1224_0x5d9e;'use strict';const _=require(_0x27d44f('0x0')),util=require(_0x27d44f('0x15')),utils=require(_0x27d44f('0x2')),dials={};function writeDB(_0x55eab7){const _0x508e0b=_0x27d44f;utils[_0x508e0b('0xb')](util['format']('DIAL|%s|%s|%s|%s|%s|%s',_0x55eab7['uniqueid'],_0x55eab7[_0x508e0b('0x4')],_0x55eab7[_0x508e0b('0xd')],_0x55eab7[_0x508e0b('0x1e')],_0x55eab7[_0x508e0b('0x11')],_0x55eab7[_0x508e0b('0xf')])),utils[_0x508e0b('0x28')](_0x508e0b('0x23'),_0x55eab7),delete dials[_0x55eab7[_0x508e0b('0x13')]];}exports[_0x27d44f('0x7')]=function(_0x4610c){const _0x49ebf6=_0x27d44f;try{if(_0x4610c[_0x49ebf6('0x26')][_0x49ebf6('0x20')]()==_0x49ebf6('0x1')&&_[_0x49ebf6('0x1b')](_0x4610c[_0x49ebf6('0x9')][_0x49ebf6('0x20')](),_0x49ebf6('0xa'))){const _0x9c626e=_0x4610c[_0x49ebf6('0x9')][_0x49ebf6('0x19')]('=');dials[_0x4610c[_0x49ebf6('0x13')]]={'routeId':_0x9c626e[0x1]};}}catch(_0x5c1f50){utils[_0x49ebf6('0x27')](_0x5c1f50['stack']);}},exports['varset']=function(_0x22a7c){const _0x3c6d87=_0x27d44f;try{!_[_0x3c6d87('0x14')](_0x22a7c[_0x3c6d87('0x10')]['outboundrouteid'])&&(dials[_0x22a7c[_0x3c6d87('0x13')]]={'routeId':_0x22a7c[_0x3c6d87('0x1d')]});}catch(_0x42f542){utils[_0x3c6d87('0x27')](_0x42f542[_0x3c6d87('0x3')]);}},exports[_0x27d44f('0x21')]=function(_0x2ab0da){const _0x3916c0=_0x27d44f;try{!_[_0x3916c0('0x14')](dials[_0x2ab0da['uniqueid']])&&(dials[_0x2ab0da['uniqueid']]=_[_0x3916c0('0xc')](dials[_0x2ab0da[_0x3916c0('0x13')]],_0x2ab0da),dials[_0x2ab0da[_0x3916c0('0x13')]][_0x3916c0('0x24')]=utils[_0x3916c0('0x12')](),dials[_0x2ab0da[_0x3916c0('0x13')]]['lastevent']=_0x3916c0('0x6'));}catch(_0x5f345c){utils[_0x3916c0('0x27')](_0x5f345c[_0x3916c0('0x3')]);}},exports[_0x27d44f('0x1a')]=function(_0x2363e9){const _0x56ed9a=_0x27d44f;try{!_['isNil'](dials[_0x2363e9[_0x56ed9a('0x13')]])&&(dials[_0x2363e9[_0x56ed9a('0x13')]]['dialstatus']=_0x2363e9['dialstatus'],_0x2363e9[_0x56ed9a('0xf')]==_0x56ed9a('0x25')&&(dials[_0x2363e9[_0x56ed9a('0x13')]]=_[_0x56ed9a('0xc')](dials[_0x2363e9[_0x56ed9a('0x13')]],_0x2363e9),dials[_0x2363e9[_0x56ed9a('0x13')]][_0x56ed9a('0x1f')]=utils[_0x56ed9a('0x12')](),dials[_0x2363e9['uniqueid']][_0x56ed9a('0x17')]=_0x56ed9a('0x1c')));}catch(_0xf1b0bf){utils[_0x56ed9a('0x27')](_0xf1b0bf['stack']);}},exports['hangup']=function(_0x39c0a3){const _0x6337fa=_0x27d44f;try{!_[_0x6337fa('0x14')](dials[_0x39c0a3[_0x6337fa('0x13')]])&&(dials[_0x39c0a3[_0x6337fa('0x13')]]=_['assign'](dials[_0x39c0a3['uniqueid']],{'endtime':utils[_0x6337fa('0x12')](),'lastevent':_0x6337fa('0x5')}),dials[_0x39c0a3[_0x6337fa('0x13')]][_0x6337fa('0x18')]=utils[_0x6337fa('0x8')](dials[_0x39c0a3[_0x6337fa('0x13')]][_0x6337fa('0x22')],dials[_0x39c0a3[_0x6337fa('0x13')]][_0x6337fa('0x24')]),dials[_0x39c0a3[_0x6337fa('0x13')]][_0x6337fa('0x16')]=utils[_0x6337fa('0x8')](dials[_0x39c0a3['uniqueid']][_0x6337fa('0x1f')]||dials[_0x39c0a3['uniqueid']][_0x6337fa('0x22')],dials[_0x39c0a3[_0x6337fa('0x13')]][_0x6337fa('0x24')]),dials[_0x39c0a3['uniqueid']][_0x6337fa('0xe')]=dials[_0x39c0a3['uniqueid']][_0x6337fa('0x1f')]?utils['diffTime'](dials[_0x39c0a3[_0x6337fa('0x13')]]['endtime'],dials[_0x39c0a3[_0x6337fa('0x13')]]['answertime']):0x0,writeDB(dials[_0x39c0a3[_0x6337fa('0x13')]]));}catch(_0x152eb8){utils[_0x6337fa('0x27')](_0x152eb8[_0x6337fa('0x3')]);}}; \ No newline at end of file diff --git a/server/services/xdr/index.js b/server/services/xdr/index.js index c554615..929b28b 100644 --- a/server/services/xdr/index.js +++ b/server/services/xdr/index.js @@ -1 +1 @@ -const a1225_0x521b=['info','attendedtransfer','asterisk-manager','cdr','newstate','newchannel','dialbegin','./members.controller','disabled','./core.controller','musiconholdstop','hangup','blindtransfer','./calls.controller','../../globals','queuecallerleave','newexten','musiconholdstart','queuecallerjoin','agentringnoanswer','./utils','agentconnect','./queues.controller','./recordings.controller','asterisk','port','./dials.controller','close','agentcalled','username','queuecallerabandon','fullybooted','connect','../../config/environment','shutdown','varset','error','agentcomplete','xdr','keepConnected','password'];(function(_0x5c5a05,_0x521b3c){const _0xe96a41=function(_0x31fd14){while(--_0x31fd14){_0x5c5a05['push'](_0x5c5a05['shift']());}};_0xe96a41(++_0x521b3c);}(a1225_0x521b,0x163));const a1225_0xe96a=function(_0x5c5a05,_0x521b3c){_0x5c5a05=_0x5c5a05-0x0;let _0xe96a41=a1225_0x521b[_0x5c5a05];return _0xe96a41;};const _0x20bcf0=a1225_0xe96a;require(_0x20bcf0('0x1c'));const AsteriskManager=require(_0x20bcf0('0x10')),config=require(_0x20bcf0('0x6')),utils=require(_0x20bcf0('0x22')),ami=new AsteriskManager(config['asterisk'][_0x20bcf0('0x27')],config[_0x20bcf0('0x26')]['ip'],config[_0x20bcf0('0x26')][_0x20bcf0('0x2')],config[_0x20bcf0('0x26')][_0x20bcf0('0xd')],!![]);ami[_0x20bcf0('0xc')]();if(config[_0x20bcf0('0xb')]&&config[_0x20bcf0('0xb')][_0x20bcf0('0x16')])utils[_0x20bcf0('0xe')]('XDR\x20DISABLED');else{const agents=require('./agents.controller'),calls=require(_0x20bcf0('0x1b')),queues=require(_0x20bcf0('0x24')),recordings=require(_0x20bcf0('0x25')),members=require(_0x20bcf0('0x15')),dials=require(_0x20bcf0('0x28')),transfers=require('./transfers.controller'),core=require(_0x20bcf0('0x17'));ami['on']('connect',core[_0x20bcf0('0x5')]),ami['on']('shutdown',core[_0x20bcf0('0x7')]),ami['on']('fullybooted',core[_0x20bcf0('0x4')]),ami['on'](_0x20bcf0('0x9'),core[_0x20bcf0('0x9')]),ami['on'](_0x20bcf0('0x0'),core[_0x20bcf0('0x0')]),ami['on']('managerevent',core['managerevent']),ami['on']('devicestatechange',function(_0x31fd14){const _0x505f4c=_0x20bcf0;try{members['devicestatechange'](_0x31fd14);}catch(_0x3699c8){utils[_0x505f4c('0x9')](_0x3699c8);}}),ami['on'](_0x20bcf0('0x1'),function(_0x10c0eb){const _0x1b46e8=_0x20bcf0;try{agents[_0x1b46e8('0x1')](_0x10c0eb);}catch(_0x26db5b){utils['error'](_0x26db5b);}}),ami['on'](_0x20bcf0('0x21'),function(_0x386cc6){const _0x264388=_0x20bcf0;try{agents[_0x264388('0x21')](_0x386cc6);}catch(_0x1c576b){utils[_0x264388('0x9')](_0x1c576b);}}),ami['on'](_0x20bcf0('0x23'),function(_0x527882){const _0x2b360b=_0x20bcf0;try{agents[_0x2b360b('0x23')](_0x527882),queues[_0x2b360b('0x23')](_0x527882);}catch(_0x32f5ff){utils['error'](_0x32f5ff);}}),ami['on']('agentcomplete',function(_0x5c75e5){const _0x16dad3=_0x20bcf0;try{agents[_0x16dad3('0xa')](_0x5c75e5),queues['agentcomplete'](_0x5c75e5),members[_0x16dad3('0xa')](_0x5c75e5);}catch(_0x33ad06){utils[_0x16dad3('0x9')](_0x33ad06);}}),ami['on'](_0x20bcf0('0x3'),function(_0x17bc7f){const _0x33f493=_0x20bcf0;try{agents[_0x33f493('0x3')](_0x17bc7f),queues[_0x33f493('0x3')](_0x17bc7f);}catch(_0x50d457){utils[_0x33f493('0x9')](_0x50d457);}}),ami['on'](_0x20bcf0('0x20'),function(_0x22d829){const _0x541bff=_0x20bcf0;try{queues[_0x541bff('0x20')](_0x22d829),recordings['queuecallerjoin'](_0x22d829);}catch(_0x2607c3){utils[_0x541bff('0x9')](_0x2607c3);}}),ami['on'](_0x20bcf0('0x1d'),function(_0x45e905){const _0x521ba9=_0x20bcf0;try{queues[_0x521ba9('0x1d')](_0x45e905);}catch(_0x3444c6){utils[_0x521ba9('0x9')](_0x3444c6);}}),ami['on'](_0x20bcf0('0x1f'),function(_0xeb8239){const _0x4e19de=_0x20bcf0;try{queues[_0x4e19de('0x1f')](_0xeb8239),calls['musiconholdstart'](_0xeb8239);}catch(_0x46c641){utils[_0x4e19de('0x9')](_0x46c641);}}),ami['on']('musiconholdstop',function(_0x1a8ab6){const _0x3aecfe=_0x20bcf0;try{queues['musiconholdstop'](_0x1a8ab6),calls[_0x3aecfe('0x18')](_0x1a8ab6);}catch(_0x1d28c1){utils[_0x3aecfe('0x9')](_0x1d28c1);}}),ami['on'](_0x20bcf0('0x12'),function(_0x162c08){const _0xf62c70=_0x20bcf0;try{calls[_0xf62c70('0x12')](_0x162c08),recordings[_0xf62c70('0x12')](_0x162c08);}catch(_0x2f2e50){utils[_0xf62c70('0x9')](_0x2f2e50);}}),ami['on']('hangup',function(_0xbbaf89){const _0x3a4998=_0x20bcf0;try{calls['hangup'](_0xbbaf89),recordings[_0x3a4998('0x19')](_0xbbaf89),dials[_0x3a4998('0x19')](_0xbbaf89),agents['hangup'](_0xbbaf89),queues[_0x3a4998('0x19')](_0xbbaf89);}catch(_0x3fb50c){utils[_0x3a4998('0x9')](_0x3fb50c);}}),ami['on'](_0x20bcf0('0x11'),function(_0x504b82){const _0x34868c=_0x20bcf0;try{members[_0x34868c('0x11')](_0x504b82);}catch(_0x521132){utils[_0x34868c('0x9')](_0x521132);}}),ami['on']('blindtransfer',function(_0x4807b3){const _0x3d58d4=_0x20bcf0;try{queues['blindtransfer'](_0x4807b3),agents[_0x3d58d4('0x1a')](_0x4807b3),transfers['blindtransfer'](_0x4807b3);}catch(_0x12b16d){utils[_0x3d58d4('0x9')](_0x12b16d);}}),ami['on'](_0x20bcf0('0xf'),function(_0x535efa){const _0x3a7eae=_0x20bcf0;try{queues[_0x3a7eae('0xf')](_0x535efa),transfers[_0x3a7eae('0xf')](_0x535efa),agents['attendedtransfer'](_0x535efa),calls[_0x3a7eae('0xf')](_0x535efa);}catch(_0x16d1a3){utils[_0x3a7eae('0x9')](_0x16d1a3);}}),ami['on'](_0x20bcf0('0x8'),function(_0x4a168a){const _0x3166e8=_0x20bcf0;try{queues[_0x3166e8('0x8')](_0x4a168a),recordings[_0x3166e8('0x8')](_0x4a168a),calls['varset'](_0x4a168a),dials['varset'](_0x4a168a);}catch(_0x4a58db){utils[_0x3166e8('0x9')](_0x4a58db);}}),ami['on'](_0x20bcf0('0x1e'),function(_0x19676e){const _0x13dae6=_0x20bcf0;try{calls[_0x13dae6('0x1e')](_0x19676e),recordings[_0x13dae6('0x1e')](_0x19676e),dials[_0x13dae6('0x1e')](_0x19676e);}catch(_0x67c489){utils[_0x13dae6('0x9')](_0x67c489);}}),ami['on'](_0x20bcf0('0x13'),function(_0x4fb067){const _0x51fb03=_0x20bcf0;try{calls['newchannel'](_0x4fb067),recordings[_0x51fb03('0x13')](_0x4fb067);}catch(_0x44cbd4){utils[_0x51fb03('0x9')](_0x44cbd4);}}),ami['on'](_0x20bcf0('0x14'),function(_0x2f0e24){const _0x36ea86=_0x20bcf0;try{dials[_0x36ea86('0x14')](_0x2f0e24);}catch(_0x55f8df){utils[_0x36ea86('0x9')](_0x55f8df);}}),ami['on']('dialend',function(_0x1cdacc){try{dials['dialend'](_0x1cdacc);}catch(_0x22100b){utils['error'](_0x22100b);}});} \ No newline at end of file +const a1225_0x22a0=['info','cdr','agentcomplete','username','disabled','blindtransfer','queuecallerabandon','agentconnect','connect','./utils','shutdown','asterisk','./agents.controller','error','devicestatechange','./dials.controller','musiconholdstart','dialend','newstate','./members.controller','varset','../../globals','keepConnected','xdr','queuecallerleave','attendedtransfer','managerevent','../../config/environment','agentcalled','queuecallerjoin','hangup','dialbegin','port','musiconholdstop','newexten','./core.controller','agentringnoanswer','newchannel','close','fullybooted','./recordings.controller'];(function(_0x4e614a,_0x22a077){const _0x205997=function(_0x5ee8a0){while(--_0x5ee8a0){_0x4e614a['push'](_0x4e614a['shift']());}};_0x205997(++_0x22a077);}(a1225_0x22a0,0xb9));const a1225_0x2059=function(_0x4e614a,_0x22a077){_0x4e614a=_0x4e614a-0x0;let _0x205997=a1225_0x22a0[_0x4e614a];return _0x205997;};const _0x188e2a=a1225_0x2059;require(_0x188e2a('0x0'));const AsteriskManager=require('asterisk-manager'),config=require(_0x188e2a('0x6')),utils=require(_0x188e2a('0x1d')),ami=new AsteriskManager(config[_0x188e2a('0x1f')][_0x188e2a('0xb')],config[_0x188e2a('0x1f')]['ip'],config[_0x188e2a('0x1f')][_0x188e2a('0x17')],config[_0x188e2a('0x1f')]['password'],!![]);ami[_0x188e2a('0x1')]();if(config[_0x188e2a('0x2')]&&config[_0x188e2a('0x2')][_0x188e2a('0x18')])utils[_0x188e2a('0x14')]('XDR\x20DISABLED');else{const agents=require(_0x188e2a('0x20')),calls=require('./calls.controller'),queues=require('./queues.controller'),recordings=require(_0x188e2a('0x13')),members=require(_0x188e2a('0x27')),dials=require(_0x188e2a('0x23')),transfers=require('./transfers.controller'),core=require(_0x188e2a('0xe'));ami['on']('connect',core[_0x188e2a('0x1c')]),ami['on'](_0x188e2a('0x1e'),core['shutdown']),ami['on'](_0x188e2a('0x12'),core['fullybooted']),ami['on'](_0x188e2a('0x21'),core[_0x188e2a('0x21')]),ami['on']('close',core[_0x188e2a('0x11')]),ami['on'](_0x188e2a('0x5'),core[_0x188e2a('0x5')]),ami['on'](_0x188e2a('0x22'),function(_0x5ee8a0){const _0x9d9478=_0x188e2a;try{members[_0x9d9478('0x22')](_0x5ee8a0);}catch(_0x2cc31d){utils[_0x9d9478('0x21')](_0x2cc31d);}}),ami['on']('agentcalled',function(_0x50ba30){const _0x5a4547=_0x188e2a;try{agents[_0x5a4547('0x7')](_0x50ba30);}catch(_0x339d00){utils[_0x5a4547('0x21')](_0x339d00);}}),ami['on']('agentringnoanswer',function(_0x3af171){const _0x3127e9=_0x188e2a;try{agents[_0x3127e9('0xf')](_0x3af171);}catch(_0x38deb9){utils[_0x3127e9('0x21')](_0x38deb9);}}),ami['on'](_0x188e2a('0x1b'),function(_0x30e17c){const _0xdb724=_0x188e2a;try{agents[_0xdb724('0x1b')](_0x30e17c),queues[_0xdb724('0x1b')](_0x30e17c);}catch(_0xb20302){utils['error'](_0xb20302);}}),ami['on'](_0x188e2a('0x16'),function(_0xcc0ae9){const _0x361c02=_0x188e2a;try{agents[_0x361c02('0x16')](_0xcc0ae9),queues[_0x361c02('0x16')](_0xcc0ae9),members['agentcomplete'](_0xcc0ae9);}catch(_0x540486){utils[_0x361c02('0x21')](_0x540486);}}),ami['on']('queuecallerabandon',function(_0x3ac0ea){const _0x398770=_0x188e2a;try{agents[_0x398770('0x1a')](_0x3ac0ea),queues['queuecallerabandon'](_0x3ac0ea);}catch(_0x156daa){utils[_0x398770('0x21')](_0x156daa);}}),ami['on'](_0x188e2a('0x8'),function(_0x384c0d){const _0x1723d7=_0x188e2a;try{queues[_0x1723d7('0x8')](_0x384c0d),recordings['queuecallerjoin'](_0x384c0d);}catch(_0x51cd9f){utils[_0x1723d7('0x21')](_0x51cd9f);}}),ami['on'](_0x188e2a('0x3'),function(_0x47d639){const _0x39bd53=_0x188e2a;try{queues[_0x39bd53('0x3')](_0x47d639);}catch(_0x311771){utils['error'](_0x311771);}}),ami['on']('musiconholdstart',function(_0x3f9747){const _0x28fb32=_0x188e2a;try{queues[_0x28fb32('0x24')](_0x3f9747),calls[_0x28fb32('0x24')](_0x3f9747);}catch(_0x56a55c){utils[_0x28fb32('0x21')](_0x56a55c);}}),ami['on']('musiconholdstop',function(_0x3dcf41){const _0x732262=_0x188e2a;try{queues[_0x732262('0xc')](_0x3dcf41),calls[_0x732262('0xc')](_0x3dcf41);}catch(_0x5e4f81){utils['error'](_0x5e4f81);}}),ami['on'](_0x188e2a('0x26'),function(_0x1fc8b5){const _0x4f504c=_0x188e2a;try{calls['newstate'](_0x1fc8b5),recordings[_0x4f504c('0x26')](_0x1fc8b5);}catch(_0xc57d27){utils[_0x4f504c('0x21')](_0xc57d27);}}),ami['on'](_0x188e2a('0x9'),function(_0x1fbebd){const _0x17aa05=_0x188e2a;try{calls['hangup'](_0x1fbebd),recordings[_0x17aa05('0x9')](_0x1fbebd),dials['hangup'](_0x1fbebd),agents[_0x17aa05('0x9')](_0x1fbebd),queues[_0x17aa05('0x9')](_0x1fbebd);}catch(_0x2e8a21){utils[_0x17aa05('0x21')](_0x2e8a21);}}),ami['on'](_0x188e2a('0x15'),function(_0x4f89cb){const _0x389f23=_0x188e2a;try{members['cdr'](_0x4f89cb);}catch(_0x55d1c5){utils[_0x389f23('0x21')](_0x55d1c5);}}),ami['on'](_0x188e2a('0x19'),function(_0x26cfb0){const _0x282856=_0x188e2a;try{queues[_0x282856('0x19')](_0x26cfb0),agents[_0x282856('0x19')](_0x26cfb0),transfers['blindtransfer'](_0x26cfb0);}catch(_0x5d140f){utils['error'](_0x5d140f);}}),ami['on'](_0x188e2a('0x4'),function(_0x3a855c){const _0x56021d=_0x188e2a;try{queues[_0x56021d('0x4')](_0x3a855c),transfers['attendedtransfer'](_0x3a855c),agents['attendedtransfer'](_0x3a855c),calls[_0x56021d('0x4')](_0x3a855c);}catch(_0x39350e){utils['error'](_0x39350e);}}),ami['on'](_0x188e2a('0x28'),function(_0x496723){const _0x59067d=_0x188e2a;try{queues['varset'](_0x496723),recordings[_0x59067d('0x28')](_0x496723),calls[_0x59067d('0x28')](_0x496723),dials[_0x59067d('0x28')](_0x496723);}catch(_0x12f786){utils[_0x59067d('0x21')](_0x12f786);}}),ami['on'](_0x188e2a('0xd'),function(_0x393ddc){const _0x18ae1b=_0x188e2a;try{calls[_0x18ae1b('0xd')](_0x393ddc),recordings[_0x18ae1b('0xd')](_0x393ddc),dials['newexten'](_0x393ddc);}catch(_0x756bd9){utils[_0x18ae1b('0x21')](_0x756bd9);}}),ami['on'](_0x188e2a('0x10'),function(_0x3ac823){const _0x428fd0=_0x188e2a;try{calls[_0x428fd0('0x10')](_0x3ac823),recordings['newchannel'](_0x3ac823);}catch(_0x50bdb8){utils[_0x428fd0('0x21')](_0x50bdb8);}}),ami['on'](_0x188e2a('0xa'),function(_0x1785f3){const _0x128264=_0x188e2a;try{dials[_0x128264('0xa')](_0x1785f3);}catch(_0x5cf338){utils[_0x128264('0x21')](_0x5cf338);}}),ami['on'](_0x188e2a('0x25'),function(_0x577eaa){const _0x24df10=_0x188e2a;try{dials[_0x24df10('0x25')](_0x577eaa);}catch(_0x570c77){utils[_0x24df10('0x21')](_0x570c77);}});} \ No newline at end of file diff --git a/server/services/xdr/members.controller.js b/server/services/xdr/members.controller.js index 6e3e5ce..8c2160f 100644 --- a/server/services/xdr/members.controller.js +++ b/server/services/xdr/members.controller.js @@ -1 +1 @@ -const a1226_0x55f2=['isNil','queue','Queue:','lodash','cdr','getUserByInterface','./utils','request','MEMBER|%s|%s|%s|%s|%s|%s','data2','source','voice','destination','name','data3','NOT_INUSE','diffTime','assign','catch','duration','devicestatechange','channel','format','INUSE','membername','state','split','agentcomplete','internal','uniqueid','then','type','agent','getUserByName','BUSY','CreateMemberReport','device','util','Local/_attended@transfer','exitAt','destinationchannel','now','data1','interface'];(function(_0x41ece3,_0x55f2b0){const _0x2d7fa5=function(_0x3bf2ca){while(--_0x3bf2ca){_0x41ece3['push'](_0x41ece3['shift']());}};_0x2d7fa5(++_0x55f2b0);}(a1226_0x55f2,0xdb));const a1226_0x2d7f=function(_0x41ece3,_0x55f2b0){_0x41ece3=_0x41ece3-0x0;let _0x2d7fa5=a1226_0x55f2[_0x41ece3];return _0x2d7fa5;};const _0x6bedad=a1226_0x2d7f;'use strict';const _=require(_0x6bedad('0x4')),util=require(_0x6bedad('0x26')),utils=require(_0x6bedad('0x7')),members={},exclude=[_0x6bedad('0x27'),_0x6bedad('0x3')];function writeDB(_0x3bf2ca){const _0x13f235=_0x6bedad;utils['info'](util[_0x13f235('0x17')](_0x13f235('0x9'),_0x3bf2ca[_0x13f235('0x1e')],_0x3bf2ca[_0x13f235('0x0')],_0x3bf2ca['channel'],_0x3bf2ca[_0x13f235('0xa')],_0x3bf2ca[_0x13f235('0x19')],_0x3bf2ca['type'])),_0x3bf2ca[_0x13f235('0x0')]&&utils[_0x13f235('0x6')](_0x3bf2ca[_0x13f235('0x0')])['then'](function(_0x746e8f){const _0x4aa7d0=_0x13f235;_0x746e8f?(_0x3bf2ca[_0x4aa7d0('0x19')]=_0x746e8f[_0x4aa7d0('0xe')],_0x3bf2ca[_0x4aa7d0('0x1d')]=_0x746e8f['internal'],utils[_0x4aa7d0('0x8')](_0x4aa7d0('0x24'),_0x3bf2ca)):utils[_0x4aa7d0('0x22')](_0x3bf2ca['interface'][_0x4aa7d0('0x1b')]('/')[0x1])[_0x4aa7d0('0x1f')](function(_0x5559f3){const _0x5644a6=_0x4aa7d0;_0x5559f3&&(_0x3bf2ca[_0x5644a6('0x19')]=_0x5559f3['name'],_0x3bf2ca[_0x5644a6('0x1d')]=_0x5559f3[_0x5644a6('0x1d')],utils['request'](_0x5644a6('0x24'),_0x3bf2ca));});})[_0x13f235('0x13')](function(_0x5490bd){utils['error'](_0x5490bd);}),delete members[_0x3bf2ca[_0x13f235('0x0')]];}function startsWith(_0x47b55e,_0x30f8b7){return _['some'](_0x47b55e,function(_0x12f069){return _['startsWith'](_0x30f8b7,_0x12f069);});}exports[_0x6bedad('0x15')]=function(_0x5d2f57){const _0x2aaa37=_0x6bedad;switch(_0x5d2f57[_0x2aaa37('0x1a')]){case _0x2aaa37('0x18'):case _0x2aaa37('0x23'):!startsWith(exclude,_0x5d2f57[_0x2aaa37('0x25')])&&(members[_0x5d2f57[_0x2aaa37('0x25')]]={'channel':_0x2aaa37('0xc'),'interface':_0x5d2f57[_0x2aaa37('0x25')],'type':'TALKING','enterAt':utils[_0x2aaa37('0x2a')](),'role':_0x2aaa37('0x21')});break;case _0x2aaa37('0x10'):!_[_0x2aaa37('0x1')](members[_0x5d2f57[_0x2aaa37('0x25')]])&&(members[_0x5d2f57['device']]['exitAt']=utils[_0x2aaa37('0x2a')](),members[_0x5d2f57[_0x2aaa37('0x25')]][_0x2aaa37('0x14')]=utils[_0x2aaa37('0x11')](members[_0x5d2f57[_0x2aaa37('0x25')]]['exitAt'],members[_0x5d2f57[_0x2aaa37('0x25')]]['enterAt']),members[_0x5d2f57['device']][_0x2aaa37('0x1e')]&&writeDB(members[_0x5d2f57[_0x2aaa37('0x25')]]));break;default:break;}},exports[_0x6bedad('0x1c')]=function(_0x2cd60b){const _0x2c9647=_0x6bedad;!_['isNil'](members[_0x2cd60b['interface']])&&(members[_0x2cd60b[_0x2c9647('0x0')]]=_[_0x2c9647('0x12')](members[_0x2cd60b[_0x2c9647('0x0')]],{'data4':_0x2cd60b[_0x2c9647('0x2')],'uniqueid':_0x2cd60b[_0x2c9647('0x1e')]}));},exports[_0x6bedad('0x5')]=function(_0x568759){const _0x13ba51=_0x6bedad;if(_0x568759[_0x13ba51('0x16')]){const _0x3e0e5a=_0x568759[_0x13ba51('0x16')][_0x13ba51('0x1b')]('-')[0x0];!_['isNil'](members[_0x3e0e5a])&&(members[_0x3e0e5a]=_['assign'](members[_0x3e0e5a],{'data1':members[_0x3e0e5a][_0x13ba51('0x2b')]||_0x568759[_0x13ba51('0x20')],'data2':members[_0x3e0e5a][_0x13ba51('0xa')]||_0x568759[_0x13ba51('0xb')],'data3':members[_0x3e0e5a][_0x13ba51('0xf')]||_0x568759['destination'],'uniqueid':members[_0x3e0e5a][_0x13ba51('0x1e')]||_0x568759[_0x13ba51('0x1e')]}),members[_0x3e0e5a][_0x13ba51('0x28')]&&writeDB(members[_0x3e0e5a]));}if(_0x568759[_0x13ba51('0x29')]){const _0x5bef42=_0x568759[_0x13ba51('0x29')][_0x13ba51('0x1b')]('-')[0x0];!_[_0x13ba51('0x1')](members[_0x5bef42])&&(members[_0x5bef42]=_[_0x13ba51('0x12')](members[_0x5bef42],{'data1':members[_0x5bef42][_0x13ba51('0x2b')]||_0x568759[_0x13ba51('0x20')],'data2':members[_0x5bef42]['data2']||_0x568759[_0x13ba51('0xb')],'data3':members[_0x5bef42][_0x13ba51('0xf')]||_0x568759[_0x13ba51('0xd')],'uniqueid':members[_0x5bef42][_0x13ba51('0x1e')]||_0x568759[_0x13ba51('0x1e')]}),members[_0x5bef42][_0x13ba51('0x28')]&&writeDB(members[_0x5bef42]));}}; \ No newline at end of file +const a1226_0x4f98=['MEMBER|%s|%s|%s|%s|%s|%s','type','diffTime','then','destinationchannel','split','channel','CreateMemberReport','device','membername','format','data3','data2','TALKING','state','request','getUserByInterface','uniqueid','assign','error','voice','data1','cdr','agentcomplete','catch','now','interface','NOT_INUSE','Local/_attended@transfer','./utils','startsWith','INUSE','isNil','source','agent','info','destination','internal','exitAt','queue','lodash','util'];(function(_0x12c15a,_0x4f982b){const _0x5bca3f=function(_0xdd8b67){while(--_0xdd8b67){_0x12c15a['push'](_0x12c15a['shift']());}};_0x5bca3f(++_0x4f982b);}(a1226_0x4f98,0x14b));const a1226_0x5bca=function(_0x12c15a,_0x4f982b){_0x12c15a=_0x12c15a-0x0;let _0x5bca3f=a1226_0x4f98[_0x12c15a];return _0x5bca3f;};const _0x1ca3b1=a1226_0x5bca;'use strict';const _=require(_0x1ca3b1('0x3')),util=require(_0x1ca3b1('0x4')),utils=require(_0x1ca3b1('0x22')),members={},exclude=[_0x1ca3b1('0x21'),'Queue:'];function writeDB(_0xdd8b67){const _0x5b383b=_0x1ca3b1;utils[_0x5b383b('0x28')](util[_0x5b383b('0xf')](_0x5b383b('0x5'),_0xdd8b67[_0x5b383b('0x16')],_0xdd8b67['interface'],_0xdd8b67[_0x5b383b('0xb')],_0xdd8b67[_0x5b383b('0x11')],_0xdd8b67[_0x5b383b('0xe')],_0xdd8b67['type'])),_0xdd8b67[_0x5b383b('0x1f')]&&utils[_0x5b383b('0x15')](_0xdd8b67[_0x5b383b('0x1f')])[_0x5b383b('0x8')](function(_0x3da3fe){const _0x5a3a48=_0x5b383b;_0x3da3fe?(_0xdd8b67['membername']=_0x3da3fe['name'],_0xdd8b67['internal']=_0x3da3fe[_0x5a3a48('0x0')],utils[_0x5a3a48('0x14')](_0x5a3a48('0xc'),_0xdd8b67)):utils['getUserByName'](_0xdd8b67[_0x5a3a48('0x1f')][_0x5a3a48('0xa')]('/')[0x1])['then'](function(_0x44fef6){const _0xa24248=_0x5a3a48;_0x44fef6&&(_0xdd8b67[_0xa24248('0xe')]=_0x44fef6['name'],_0xdd8b67[_0xa24248('0x0')]=_0x44fef6[_0xa24248('0x0')],utils[_0xa24248('0x14')](_0xa24248('0xc'),_0xdd8b67));});})[_0x5b383b('0x1d')](function(_0x46ebc5){const _0x1115b2=_0x5b383b;utils[_0x1115b2('0x18')](_0x46ebc5);}),delete members[_0xdd8b67[_0x5b383b('0x1f')]];}function startsWith(_0x38ce58,_0x55a920){return _['some'](_0x38ce58,function(_0x1be279){const _0x2a076a=a1226_0x5bca;return _[_0x2a076a('0x23')](_0x55a920,_0x1be279);});}exports['devicestatechange']=function(_0x171d0a){const _0x73802a=_0x1ca3b1;switch(_0x171d0a[_0x73802a('0x13')]){case _0x73802a('0x24'):case'BUSY':!startsWith(exclude,_0x171d0a[_0x73802a('0xd')])&&(members[_0x171d0a['device']]={'channel':_0x73802a('0x19'),'interface':_0x171d0a[_0x73802a('0xd')],'type':_0x73802a('0x12'),'enterAt':utils['now'](),'role':_0x73802a('0x27')});break;case _0x73802a('0x20'):!_['isNil'](members[_0x171d0a[_0x73802a('0xd')]])&&(members[_0x171d0a[_0x73802a('0xd')]][_0x73802a('0x1')]=utils[_0x73802a('0x1e')](),members[_0x171d0a[_0x73802a('0xd')]]['duration']=utils[_0x73802a('0x7')](members[_0x171d0a['device']]['exitAt'],members[_0x171d0a[_0x73802a('0xd')]]['enterAt']),members[_0x171d0a[_0x73802a('0xd')]][_0x73802a('0x16')]&&writeDB(members[_0x171d0a[_0x73802a('0xd')]]));break;default:break;}},exports[_0x1ca3b1('0x1c')]=function(_0x313e3c){const _0x28d372=_0x1ca3b1;!_[_0x28d372('0x25')](members[_0x313e3c['interface']])&&(members[_0x313e3c[_0x28d372('0x1f')]]=_['assign'](members[_0x313e3c['interface']],{'data4':_0x313e3c[_0x28d372('0x2')],'uniqueid':_0x313e3c[_0x28d372('0x16')]}));},exports[_0x1ca3b1('0x1b')]=function(_0x2f193b){const _0x40c43f=_0x1ca3b1;if(_0x2f193b['channel']){const _0x2ad9d0=_0x2f193b[_0x40c43f('0xb')][_0x40c43f('0xa')]('-')[0x0];!_['isNil'](members[_0x2ad9d0])&&(members[_0x2ad9d0]=_[_0x40c43f('0x17')](members[_0x2ad9d0],{'data1':members[_0x2ad9d0][_0x40c43f('0x1a')]||_0x2f193b[_0x40c43f('0x6')],'data2':members[_0x2ad9d0][_0x40c43f('0x11')]||_0x2f193b[_0x40c43f('0x26')],'data3':members[_0x2ad9d0][_0x40c43f('0x10')]||_0x2f193b['destination'],'uniqueid':members[_0x2ad9d0][_0x40c43f('0x16')]||_0x2f193b[_0x40c43f('0x16')]}),members[_0x2ad9d0][_0x40c43f('0x1')]&&writeDB(members[_0x2ad9d0]));}if(_0x2f193b[_0x40c43f('0x9')]){const _0x8af6a9=_0x2f193b[_0x40c43f('0x9')]['split']('-')[0x0];!_[_0x40c43f('0x25')](members[_0x8af6a9])&&(members[_0x8af6a9]=_[_0x40c43f('0x17')](members[_0x8af6a9],{'data1':members[_0x8af6a9][_0x40c43f('0x1a')]||_0x2f193b['type'],'data2':members[_0x8af6a9]['data2']||_0x2f193b[_0x40c43f('0x26')],'data3':members[_0x8af6a9][_0x40c43f('0x10')]||_0x2f193b[_0x40c43f('0x29')],'uniqueid':members[_0x8af6a9][_0x40c43f('0x16')]||_0x2f193b[_0x40c43f('0x16')]}),members[_0x8af6a9]['exitAt']&&writeDB(members[_0x8af6a9]));}}; \ No newline at end of file diff --git a/server/services/xdr/queues.controller.js b/server/services/xdr/queues.controller.js index eff9ad1..b9acca1 100644 --- a/server/services/xdr/queues.controller.js +++ b/server/services/xdr/queues.controller.js @@ -1 +1 @@ -const a1227_0x2597=['queuecallercomplete','BLINDTRANSFER','connectedlinename','musiconholdstop','diffTime','./utils','COMPLETEDBY','queuecallerleaveAt','queuecallerexitreason','transferuniqueid','util','then','TRANSFER','transfereeuniqueid','BLIND','transferexten','format','isNil','transfer','queuecallerjoin','transfertype','agentconnect','now','queueposition','CreateVoiceQueueReport','transfereduniqueid','assign','transfertargetuniqueid','queuecallerexitAt','queuecallerexit','position','assigned','secondtransfererlinkedid','toUpperCase','uniqueid','type','origtransfererexten','reason','queuecallerenterreason','origtransfererlinkedid','clone','lastAssignedTo','holdtime','secondtransfererexten','queuecallerabandonAt','COMPLETEDBYAGENT','blindtransfer','destaccountcode','request','membername','queuecallerleave','count','transfereelinkedid','value','accountcode','queue','queuecallercompleteAt','extension','channel','attendedtransfer','queuecallerjoinAt','connectedlinenum','mohtime','transfertargetlinkedid','secondtransfereruniqueid','stack','variable','queuecallerabandon','ATTENDED','agentcomplete','musiconholdstartAt','queuestatus','ABANDONED','calleridname','calleridnum','ATTENDEDTRANSFER'];(function(_0xab639b,_0x25977c){const _0xba61c9=function(_0xedaaf0){while(--_0xedaaf0){_0xab639b['push'](_0xab639b['shift']());}};_0xba61c9(++_0x25977c);}(a1227_0x2597,0xb9));const a1227_0xba61=function(_0xab639b,_0x25977c){_0xab639b=_0xab639b-0x0;let _0xba61c9=a1227_0x2597[_0xab639b];return _0xba61c9;};const _0x5853d=a1227_0xba61;'use strict';const _=require('lodash'),util=require(_0x5853d('0x35')),utils=require(_0x5853d('0x30')),queues={};function writeDB(_0xedaaf0){const _0x3dbb54=_0x5853d;utils['info'](util[_0x3dbb54('0x3b')]('QUEUE|%s|%s|%s|%s|%s|%s|%s',_0xedaaf0['uniqueid'],_0xedaaf0[_0x3dbb54('0x19')],_0xedaaf0[_0x3dbb54('0x16')],_0xedaaf0[_0x3dbb54('0x8')],_0xedaaf0[_0x3dbb54('0x29')],_0xedaaf0[_0x3dbb54('0x15')],_0xedaaf0[_0x3dbb54('0x33')])),_0xedaaf0[_0x3dbb54('0x16')]?utils['getVoiceQueueByName'](_0xedaaf0[_0x3dbb54('0x16')])[_0x3dbb54('0x36')](function(_0x38222a){const _0x3ab3a2=_0x3dbb54;_0x38222a&&(_0xedaaf0[_0x3ab3a2('0x2')]=_0x38222a[_0x3ab3a2('0x2')]),utils[_0x3ab3a2('0xf')](_0x3ab3a2('0x43'),_0xedaaf0);}):utils[_0x3dbb54('0xf')](_0x3dbb54('0x43'),_0xedaaf0),_0xedaaf0['transfereduniqueid']?delete queues[_0xedaaf0[_0x3dbb54('0x44')]]:delete queues[_0xedaaf0['uniqueid']];}exports[_0x5853d('0x3e')]=function(_0x17c065){const _0x2cf3cf=_0x5853d;queues[_0x17c065[_0x2cf3cf('0x1')]]=_[_0x2cf3cf('0x45')](_0x17c065,{'originalposition':_0x17c065['position'],'queuecallerjoinAt':utils[_0x2cf3cf('0x41')](),'mohtime':0x0});},exports['hangup']=function(_0xbee70){const _0x444b64=_0x5853d;!_[_0x444b64('0x3c')](queues[_0xbee70[_0x444b64('0x1')]])&&(queues[_0xbee70['uniqueid']][_0x444b64('0x32')]?(!queues[_0xbee70[_0x444b64('0x1')]]['queuecallerabandon']&&!queues[_0xbee70['uniqueid']][_0x444b64('0x48')]&&(queues[_0xbee70[_0x444b64('0x1')]][_0x444b64('0x2b')]=!![],queues[_0xbee70['uniqueid']][_0x444b64('0x17')]=utils[_0x444b64('0x41')](),queues[_0xbee70[_0x444b64('0x1')]][_0x444b64('0x33')]=_0x444b64('0xc')),writeDB(queues[_0xbee70[_0x444b64('0x1')]])):queues[_0xbee70[_0x444b64('0x1')]]['transfereduniqueid']&&(queues[queues[_0xbee70['uniqueid']][_0x444b64('0x44')]]=queues[_0xbee70['uniqueid']],queues[queues[_0xbee70[_0x444b64('0x1')]][_0x444b64('0x44')]][_0x444b64('0x5')]=0x2,delete queues[_0xbee70[_0x444b64('0x1')]]));},exports['varset']=function(_0x885427){const _0x214133=_0x5853d;if(!_[_0x214133('0x3c')](_0x885427[_0x214133('0x21')][_0x214133('0x26')])&&_0x885427['value'][_0x214133('0x0')]()!=='CONTINUE')!_[_0x214133('0x3c')](queues[_0x885427['uniqueid']])&&(queues[_0x885427[_0x214133('0x1')]][_0x214133('0x22')]=![],queues[_0x885427[_0x214133('0x1')]]['queuecallerabandonAt']=null,queues[_0x885427[_0x214133('0x1')]][_0x214133('0x48')]=!![],queues[_0x885427[_0x214133('0x1')]][_0x214133('0x47')]=utils[_0x214133('0x41')](),queues[_0x885427[_0x214133('0x1')]]['queuecallerexitreason']=_0x885427[_0x214133('0x14')]['toUpperCase'](),writeDB(queues[_0x885427[_0x214133('0x1')]]));else!_[_0x214133('0x3c')](_0x885427['variable'][_0x214133('0x42')])&&(!_['isNil'](queues[_0x885427['uniqueid']])&&!queues[_0x885427['uniqueid']][_0x214133('0x22')]&&(queues[_0x885427[_0x214133('0x1')]][_0x214133('0x22')]=![],queues[_0x885427[_0x214133('0x1')]][_0x214133('0xb')]=null,queues[_0x885427[_0x214133('0x1')]][_0x214133('0x48')]=!![],queues[_0x885427[_0x214133('0x1')]][_0x214133('0x47')]=utils['now'](),queues[_0x885427[_0x214133('0x1')]]['queuecallerexitreason']='EXITWITHKEY'));},exports[_0x5853d('0x22')]=function(_0x4eabd7){const _0x592099=_0x5853d;!_[_0x592099('0x3c')](queues[_0x4eabd7[_0x592099('0x1')]])&&(queues[_0x4eabd7[_0x592099('0x1')]]['queuecallerexit']=![],queues[_0x4eabd7[_0x592099('0x1')]][_0x592099('0x47')]=null,queues[_0x4eabd7[_0x592099('0x1')]][_0x592099('0x22')]=!![],queues[_0x4eabd7['uniqueid']][_0x592099('0xb')]=utils[_0x592099('0x41')](),queues[_0x4eabd7[_0x592099('0x1')]][_0x592099('0x33')]=_0x592099('0x27'));},exports[_0x5853d('0x11')]=function(_0x499643){const _0x2a64ab=_0x5853d;!_['isNil'](queues[_0x499643['uniqueid']])&&(queues[_0x499643[_0x2a64ab('0x1')]]['queuecallerleave']=!![],queues[_0x499643['uniqueid']][_0x2a64ab('0x32')]=utils[_0x2a64ab('0x41')](),queues[_0x499643['uniqueid']]['holdtime']=utils[_0x2a64ab('0x2f')](queues[_0x499643[_0x2a64ab('0x1')]]['queuecallerleaveAt'],queues[_0x499643[_0x2a64ab('0x1')]][_0x2a64ab('0x1b')]),queues[_0x499643[_0x2a64ab('0x1')]][_0x2a64ab('0x49')]=_0x499643[_0x2a64ab('0x49')],queues[_0x499643[_0x2a64ab('0x1')]][_0x2a64ab('0x12')]=_0x499643[_0x2a64ab('0x12')],queues[_0x499643[_0x2a64ab('0x1')]][_0x2a64ab('0x1c')]=_0x499643['connectedlinenum'],queues[_0x499643[_0x2a64ab('0x1')]][_0x2a64ab('0x2d')]=_0x499643[_0x2a64ab('0x2d')]);},exports[_0x5853d('0x40')]=function(_0x2ec8c8){const _0x4d024b=_0x5853d;!_[_0x4d024b('0x3c')](queues[_0x2ec8c8[_0x4d024b('0x1')]])&&(queues[_0x2ec8c8[_0x4d024b('0x1')]][_0x4d024b('0x22')]=![],queues[_0x2ec8c8[_0x4d024b('0x1')]][_0x4d024b('0x22')]=![],queues[_0x2ec8c8['uniqueid']][_0x4d024b('0xb')]=null,queues[_0x2ec8c8[_0x4d024b('0x1')]]['queuecallerexit']=![],queues[_0x2ec8c8[_0x4d024b('0x1')]][_0x4d024b('0x33')]=null,queues[_0x2ec8c8[_0x4d024b('0x1')]]['queuecallerexitAt']=null,queues[_0x2ec8c8['uniqueid']][_0x4d024b('0x4a')]=!![],queues[_0x2ec8c8[_0x4d024b('0x1')]][_0x4d024b('0x15')]=_0x2ec8c8[_0x4d024b('0xe')],queues[_0x2ec8c8['uniqueid']][_0x4d024b('0x8')]=_0x2ec8c8[_0x4d024b('0x10')]);},exports[_0x5853d('0x24')]=function(_0x58f9d9){const _0x24e68e=_0x5853d;!_[_0x24e68e('0x3c')](queues[_0x58f9d9['uniqueid']])&&(queues[_0x58f9d9[_0x24e68e('0x1')]][_0x24e68e('0x32')]&&(queues[_0x58f9d9[_0x24e68e('0x1')]][_0x24e68e('0x22')]=![],queues[_0x58f9d9['uniqueid']][_0x24e68e('0x22')]=![],queues[_0x58f9d9['uniqueid']][_0x24e68e('0xb')]=null,queues[_0x58f9d9[_0x24e68e('0x1')]][_0x24e68e('0x48')]=![],queues[_0x58f9d9[_0x24e68e('0x1')]][_0x24e68e('0x47')]=null,queues[_0x58f9d9['uniqueid']][_0x24e68e('0x4a')]=!![],queues[_0x58f9d9['uniqueid']]['lastAssignedTo']=_0x58f9d9[_0x24e68e('0x10')],queues[_0x58f9d9['uniqueid']][_0x24e68e('0x2b')]=!![],queues[_0x58f9d9['uniqueid']][_0x24e68e('0x17')]=utils['now'](),_0x58f9d9[_0x24e68e('0x4')]==_0x24e68e('0x3d')?!queues[_0x58f9d9[_0x24e68e('0x1')]][_0x24e68e('0x3d')]&&(queues[_0x58f9d9['uniqueid']]['queuecallerexitreason']=_0x24e68e('0x37')):queues[_0x58f9d9[_0x24e68e('0x1')]][_0x24e68e('0x33')]=_0x24e68e('0x31')+_0x58f9d9['reason'][_0x24e68e('0x0')](),writeDB(queues[_0x58f9d9[_0x24e68e('0x1')]])));},exports[_0x5853d('0xd')]=function(_0x31e4bd){const _0x434b35=_0x5853d;!_[_0x434b35('0x3c')](queues[_0x31e4bd[_0x434b35('0x38')]])&&(queues[_0x31e4bd[_0x434b35('0x38')]][_0x434b35('0x3d')]=!![],queues[_0x31e4bd['transfereeuniqueid']]['transfertype']=_0x434b35('0x39'),queues[_0x31e4bd[_0x434b35('0x38')]][_0x434b35('0x3a')]=_0x31e4bd[_0x434b35('0x18')],queues[_0x31e4bd[_0x434b35('0x38')]][_0x434b35('0x34')]=_0x31e4bd[_0x434b35('0x38')],queues[_0x31e4bd[_0x434b35('0x38')]][_0x434b35('0x33')]=_0x434b35('0x2c'));},exports[_0x5853d('0x1a')]=function(_0x3e1e07){const _0x417d2d=_0x5853d;try{if(_0x3e1e07['origtransfereruniqueid']==_0x3e1e07['origtransfererlinkedid'])!_[_0x417d2d('0x3c')](queues[_0x3e1e07[_0x417d2d('0x4b')]])&&(queues[_0x3e1e07[_0x417d2d('0x4b')]][_0x417d2d('0x3d')]=!![],queues[_0x3e1e07[_0x417d2d('0x4b')]][_0x417d2d('0x3f')]='ATTENDED',queues[_0x3e1e07[_0x417d2d('0x4b')]][_0x417d2d('0x3a')]=_0x3e1e07[_0x417d2d('0x3')],queues[_0x3e1e07[_0x417d2d('0x4b')]][_0x417d2d('0x34')]=_0x3e1e07['origtransfereruniqueid'],queues[_0x3e1e07[_0x417d2d('0x4b')]][_0x417d2d('0x33')]=_0x417d2d('0x2a')),!_[_0x417d2d('0x3c')](queues[_0x3e1e07['origtransfererlinkedid']])&&(_0x3e1e07[_0x417d2d('0x13')]&&queues[_0x3e1e07['transfereelinkedid']]?(queues[_0x3e1e07[_0x417d2d('0x13')]][_0x417d2d('0x5')]=0x1,queues[_0x3e1e07[_0x417d2d('0x38')]]=_[_0x417d2d('0x7')](queues[_0x3e1e07[_0x417d2d('0x13')]]),queues[_0x3e1e07['transfereeuniqueid']][_0x417d2d('0x44')]=_0x3e1e07[_0x417d2d('0x46')],queues[_0x3e1e07['transfereeuniqueid']]['queuecallerenterreason']=0x2,queues[_0x3e1e07[_0x417d2d('0x38')]][_0x417d2d('0x29')]=queues[_0x3e1e07[_0x417d2d('0x4b')]]['calleridnum'],queues[_0x3e1e07[_0x417d2d('0x38')]][_0x417d2d('0x28')]=queues[_0x3e1e07[_0x417d2d('0x4b')]][_0x417d2d('0x28')],queues[_0x3e1e07[_0x417d2d('0x38')]]['queuecallerjoinAt']=utils[_0x417d2d('0x41')](),queues[_0x3e1e07[_0x417d2d('0x38')]]['queuecallerleaveAt']=utils[_0x417d2d('0x41')](),queues[_0x3e1e07[_0x417d2d('0x38')]][_0x417d2d('0x9')]=0x0,queues[_0x3e1e07[_0x417d2d('0x38')]][_0x417d2d('0x1d')]=0x0):queues[_0x3e1e07[_0x417d2d('0x6')]]['transfereduniqueid']=_0x3e1e07['secondtransfererlinkedid']);else _0x3e1e07['secondtransfereruniqueid']==_0x3e1e07[_0x417d2d('0x4b')]&&(!_[_0x417d2d('0x3c')](queues[_0x3e1e07[_0x417d2d('0x6')]])&&(queues[_0x3e1e07[_0x417d2d('0x6')]][_0x417d2d('0x3d')]=!![],queues[_0x3e1e07['origtransfererlinkedid']][_0x417d2d('0x3f')]=_0x417d2d('0x23'),queues[_0x3e1e07[_0x417d2d('0x6')]][_0x417d2d('0x3a')]=_0x3e1e07[_0x417d2d('0xa')],queues[_0x3e1e07[_0x417d2d('0x6')]][_0x417d2d('0x34')]=_0x3e1e07[_0x417d2d('0x1f')],queues[_0x3e1e07['origtransfererlinkedid']][_0x417d2d('0x33')]=_0x417d2d('0x2a')),!_[_0x417d2d('0x3c')](queues[_0x3e1e07[_0x417d2d('0x4b')]])&&(_0x3e1e07[_0x417d2d('0x1e')]&&queues[_0x3e1e07['transfertargetlinkedid']]?(queues[_0x3e1e07[_0x417d2d('0x1e')]][_0x417d2d('0x5')]=0x1,queues[_0x3e1e07[_0x417d2d('0x46')]]=_['clone'](queues[_0x3e1e07[_0x417d2d('0x1e')]]),queues[_0x3e1e07[_0x417d2d('0x46')]]['transfereduniqueid']=_0x3e1e07[_0x417d2d('0x46')],queues[_0x3e1e07[_0x417d2d('0x46')]][_0x417d2d('0x5')]=0x2,queues[_0x3e1e07['transfertargetuniqueid']]['calleridnum']=queues[_0x3e1e07[_0x417d2d('0x6')]]['calleridnum'],queues[_0x3e1e07[_0x417d2d('0x46')]][_0x417d2d('0x28')]=queues[_0x3e1e07['origtransfererlinkedid']][_0x417d2d('0x28')],queues[_0x3e1e07[_0x417d2d('0x46')]][_0x417d2d('0x1b')]=utils['now'](),queues[_0x3e1e07[_0x417d2d('0x46')]]['queuecallerleaveAt']=utils[_0x417d2d('0x41')](),queues[_0x3e1e07[_0x417d2d('0x46')]][_0x417d2d('0x9')]=0x0,queues[_0x3e1e07[_0x417d2d('0x46')]][_0x417d2d('0x1d')]=0x0):queues[_0x3e1e07['secondtransfererlinkedid']][_0x417d2d('0x44')]=_0x3e1e07[_0x417d2d('0x6')]));}catch(_0x37849b){utils['error'](_0x37849b[_0x417d2d('0x20')]);}},exports['musiconholdstart']=function(_0x41e9c6){const _0x250d28=_0x5853d;!_['isNil'](queues[_0x41e9c6['uniqueid']])&&(queues[_0x41e9c6[_0x250d28('0x1')]][_0x250d28('0x25')]=utils[_0x250d28('0x41')]());},exports[_0x5853d('0x2e')]=function(_0x5ad60d){const _0x2a89ea=_0x5853d;!_[_0x2a89ea('0x3c')](queues[_0x5ad60d[_0x2a89ea('0x1')]])&&(!_[_0x2a89ea('0x3c')](queues[_0x5ad60d[_0x2a89ea('0x1')]][_0x2a89ea('0x25')])&&(queues[_0x5ad60d[_0x2a89ea('0x1')]]['mohtime']+=utils[_0x2a89ea('0x2f')](utils[_0x2a89ea('0x41')](),queues[_0x5ad60d['uniqueid']][_0x2a89ea('0x25')]),delete queues[_0x5ad60d['uniqueid']][_0x2a89ea('0x25')]));}; \ No newline at end of file +const a1227_0x2c90=['secondtransfererlinkedid','isNil','queueposition','transfertargetuniqueid','queuecallerexitAt','agentconnect','stack','calleridname','queuestatus','connectedlinename','uniqueid','toUpperCase','type','CreateVoiceQueueReport','transfereeuniqueid','queuecallerleaveAt','assigned','queuecallerjoin','ATTENDEDTRANSFER','queuecallerexitreason','membername','queuecallerjoinAt','mohtime','clone','transferexten','extension','connectedlinenum','destaccountcode','calleridnum','transfertargetlinkedid','EXITWITHKEY','accountcode','queuecallerexit','now','getVoiceQueueByName','transfer','./utils','origtransfererlinkedid','request','util','queuecallerenterreason','TRANSFER','origtransfereruniqueid','agentcomplete','ATTENDED','count','attendedtransfer','variable','secondtransfereruniqueid','hangup','queuecallerabandon','then','error','position','secondtransfererexten','queuecallerabandonAt','origtransfererexten','transfertype','channel','transfereelinkedid','musiconholdstartAt','ABANDONED','holdtime','QUEUE|%s|%s|%s|%s|%s|%s|%s','transfereduniqueid','lastAssignedTo','value','reason','COMPLETEDBYAGENT','queue','format','diffTime','queuecallercompleteAt','COMPLETEDBY','CONTINUE'];(function(_0x2677aa,_0x2c9081){const _0x650e6=function(_0x113fe8){while(--_0x113fe8){_0x2677aa['push'](_0x2677aa['shift']());}};_0x650e6(++_0x2c9081);}(a1227_0x2c90,0xb3));const a1227_0x650e=function(_0x2677aa,_0x2c9081){_0x2677aa=_0x2677aa-0x0;let _0x650e6=a1227_0x2c90[_0x2677aa];return _0x650e6;};const _0x13da7f=a1227_0x650e;'use strict';const _=require('lodash'),util=require(_0x13da7f('0xa')),utils=require(_0x13da7f('0x7')),queues={};function writeDB(_0x113fe8){const _0x45f9b5=_0x13da7f;utils['info'](util[_0x45f9b5('0x29')](_0x45f9b5('0x22'),_0x113fe8[_0x45f9b5('0x38')],_0x113fe8[_0x45f9b5('0x1d')],_0x113fe8[_0x45f9b5('0x28')],_0x113fe8['lastAssignedTo'],_0x113fe8['calleridnum'],_0x113fe8[_0x45f9b5('0x2')],_0x113fe8['queuecallerexitreason'])),_0x113fe8[_0x45f9b5('0x28')]?utils[_0x45f9b5('0x5')](_0x113fe8['queue'])[_0x45f9b5('0x16')](function(_0x2dc4fe){const _0x442bed=_0x45f9b5;_0x2dc4fe&&(_0x113fe8[_0x442bed('0x3a')]=_0x2dc4fe['type']),utils[_0x442bed('0x9')](_0x442bed('0x3b'),_0x113fe8);}):utils['request'](_0x45f9b5('0x3b'),_0x113fe8),_0x113fe8[_0x45f9b5('0x23')]?delete queues[_0x113fe8['transfereduniqueid']]:delete queues[_0x113fe8[_0x45f9b5('0x38')]];}exports[_0x13da7f('0x3f')]=function(_0xd32390){const _0x5a92ea=_0x13da7f;queues[_0xd32390[_0x5a92ea('0x38')]]=_['assign'](_0xd32390,{'originalposition':_0xd32390[_0x5a92ea('0x18')],'queuecallerjoinAt':utils[_0x5a92ea('0x4')](),'mohtime':0x0});},exports[_0x13da7f('0x14')]=function(_0x420a50){const _0x5e3257=_0x13da7f;!_[_0x5e3257('0x2f')](queues[_0x420a50[_0x5e3257('0x38')]])&&(queues[_0x420a50['uniqueid']][_0x5e3257('0x3d')]?(!queues[_0x420a50[_0x5e3257('0x38')]]['queuecallerabandon']&&!queues[_0x420a50[_0x5e3257('0x38')]][_0x5e3257('0x3')]&&(queues[_0x420a50[_0x5e3257('0x38')]]['queuecallercomplete']=!![],queues[_0x420a50['uniqueid']][_0x5e3257('0x2b')]=utils[_0x5e3257('0x4')](),queues[_0x420a50[_0x5e3257('0x38')]]['queuecallerexitreason']=_0x5e3257('0x27')),writeDB(queues[_0x420a50[_0x5e3257('0x38')]])):queues[_0x420a50[_0x5e3257('0x38')]][_0x5e3257('0x23')]&&(queues[queues[_0x420a50[_0x5e3257('0x38')]][_0x5e3257('0x23')]]=queues[_0x420a50['uniqueid']],queues[queues[_0x420a50['uniqueid']][_0x5e3257('0x23')]][_0x5e3257('0xb')]=0x2,delete queues[_0x420a50[_0x5e3257('0x38')]]));},exports['varset']=function(_0x1e18c5){const _0x5a802a=_0x13da7f;if(!_[_0x5a802a('0x2f')](_0x1e18c5[_0x5a802a('0x12')][_0x5a802a('0x36')])&&_0x1e18c5[_0x5a802a('0x25')][_0x5a802a('0x39')]()!==_0x5a802a('0x2d'))!_[_0x5a802a('0x2f')](queues[_0x1e18c5[_0x5a802a('0x38')]])&&(queues[_0x1e18c5[_0x5a802a('0x38')]][_0x5a802a('0x15')]=![],queues[_0x1e18c5[_0x5a802a('0x38')]]['queuecallerabandonAt']=null,queues[_0x1e18c5[_0x5a802a('0x38')]][_0x5a802a('0x3')]=!![],queues[_0x1e18c5[_0x5a802a('0x38')]][_0x5a802a('0x32')]=utils['now'](),queues[_0x1e18c5[_0x5a802a('0x38')]][_0x5a802a('0x41')]=_0x1e18c5[_0x5a802a('0x25')][_0x5a802a('0x39')](),writeDB(queues[_0x1e18c5[_0x5a802a('0x38')]]));else!_[_0x5a802a('0x2f')](_0x1e18c5[_0x5a802a('0x12')][_0x5a802a('0x30')])&&(!_[_0x5a802a('0x2f')](queues[_0x1e18c5[_0x5a802a('0x38')]])&&!queues[_0x1e18c5['uniqueid']][_0x5a802a('0x15')]&&(queues[_0x1e18c5['uniqueid']][_0x5a802a('0x15')]=![],queues[_0x1e18c5['uniqueid']][_0x5a802a('0x1a')]=null,queues[_0x1e18c5[_0x5a802a('0x38')]]['queuecallerexit']=!![],queues[_0x1e18c5[_0x5a802a('0x38')]][_0x5a802a('0x32')]=utils[_0x5a802a('0x4')](),queues[_0x1e18c5['uniqueid']][_0x5a802a('0x41')]=_0x5a802a('0x1')));},exports[_0x13da7f('0x15')]=function(_0x53a9c0){const _0x2f9747=_0x13da7f;!_[_0x2f9747('0x2f')](queues[_0x53a9c0[_0x2f9747('0x38')]])&&(queues[_0x53a9c0['uniqueid']]['queuecallerexit']=![],queues[_0x53a9c0['uniqueid']][_0x2f9747('0x32')]=null,queues[_0x53a9c0['uniqueid']][_0x2f9747('0x15')]=!![],queues[_0x53a9c0[_0x2f9747('0x38')]][_0x2f9747('0x1a')]=utils['now'](),queues[_0x53a9c0[_0x2f9747('0x38')]][_0x2f9747('0x41')]=_0x2f9747('0x20'));},exports['queuecallerleave']=function(_0x251137){const _0x5ac405=_0x13da7f;!_[_0x5ac405('0x2f')](queues[_0x251137[_0x5ac405('0x38')]])&&(queues[_0x251137[_0x5ac405('0x38')]]['queuecallerleave']=!![],queues[_0x251137[_0x5ac405('0x38')]][_0x5ac405('0x3d')]=utils[_0x5ac405('0x4')](),queues[_0x251137[_0x5ac405('0x38')]][_0x5ac405('0x21')]=utils[_0x5ac405('0x2a')](queues[_0x251137['uniqueid']][_0x5ac405('0x3d')],queues[_0x251137['uniqueid']][_0x5ac405('0x43')]),queues[_0x251137['uniqueid']]['position']=_0x251137[_0x5ac405('0x18')],queues[_0x251137[_0x5ac405('0x38')]]['count']=_0x251137[_0x5ac405('0x10')],queues[_0x251137[_0x5ac405('0x38')]]['connectedlinenum']=_0x251137[_0x5ac405('0x48')],queues[_0x251137['uniqueid']]['connectedlinename']=_0x251137[_0x5ac405('0x37')]);},exports[_0x13da7f('0x33')]=function(_0x1a3815){const _0x3ff87c=_0x13da7f;!_[_0x3ff87c('0x2f')](queues[_0x1a3815[_0x3ff87c('0x38')]])&&(queues[_0x1a3815[_0x3ff87c('0x38')]][_0x3ff87c('0x15')]=![],queues[_0x1a3815['uniqueid']][_0x3ff87c('0x15')]=![],queues[_0x1a3815[_0x3ff87c('0x38')]][_0x3ff87c('0x1a')]=null,queues[_0x1a3815['uniqueid']][_0x3ff87c('0x3')]=![],queues[_0x1a3815[_0x3ff87c('0x38')]][_0x3ff87c('0x41')]=null,queues[_0x1a3815[_0x3ff87c('0x38')]]['queuecallerexitAt']=null,queues[_0x1a3815[_0x3ff87c('0x38')]][_0x3ff87c('0x3e')]=!![],queues[_0x1a3815[_0x3ff87c('0x38')]]['accountcode']=_0x1a3815[_0x3ff87c('0x49')],queues[_0x1a3815[_0x3ff87c('0x38')]][_0x3ff87c('0x24')]=_0x1a3815['membername']);},exports[_0x13da7f('0xe')]=function(_0x47b20b){const _0xb926ff=_0x13da7f;!_[_0xb926ff('0x2f')](queues[_0x47b20b[_0xb926ff('0x38')]])&&(queues[_0x47b20b[_0xb926ff('0x38')]]['queuecallerleaveAt']&&(queues[_0x47b20b[_0xb926ff('0x38')]][_0xb926ff('0x15')]=![],queues[_0x47b20b[_0xb926ff('0x38')]][_0xb926ff('0x15')]=![],queues[_0x47b20b[_0xb926ff('0x38')]][_0xb926ff('0x1a')]=null,queues[_0x47b20b['uniqueid']][_0xb926ff('0x3')]=![],queues[_0x47b20b['uniqueid']]['queuecallerexitAt']=null,queues[_0x47b20b[_0xb926ff('0x38')]]['assigned']=!![],queues[_0x47b20b['uniqueid']][_0xb926ff('0x24')]=_0x47b20b[_0xb926ff('0x42')],queues[_0x47b20b[_0xb926ff('0x38')]]['queuecallercomplete']=!![],queues[_0x47b20b[_0xb926ff('0x38')]]['queuecallercompleteAt']=utils[_0xb926ff('0x4')](),_0x47b20b[_0xb926ff('0x26')]==_0xb926ff('0x6')?!queues[_0x47b20b[_0xb926ff('0x38')]][_0xb926ff('0x6')]&&(queues[_0x47b20b[_0xb926ff('0x38')]][_0xb926ff('0x41')]=_0xb926ff('0xc')):queues[_0x47b20b['uniqueid']][_0xb926ff('0x41')]=_0xb926ff('0x2c')+_0x47b20b['reason'][_0xb926ff('0x39')](),writeDB(queues[_0x47b20b[_0xb926ff('0x38')]])));},exports['blindtransfer']=function(_0x178b18){const _0x5e77b4=_0x13da7f;!_['isNil'](queues[_0x178b18['transfereeuniqueid']])&&(queues[_0x178b18[_0x5e77b4('0x3c')]]['transfer']=!![],queues[_0x178b18[_0x5e77b4('0x3c')]]['transfertype']='BLIND',queues[_0x178b18[_0x5e77b4('0x3c')]]['transferexten']=_0x178b18[_0x5e77b4('0x47')],queues[_0x178b18['transfereeuniqueid']]['transferuniqueid']=_0x178b18[_0x5e77b4('0x3c')],queues[_0x178b18[_0x5e77b4('0x3c')]][_0x5e77b4('0x41')]='BLINDTRANSFER');},exports[_0x13da7f('0x11')]=function(_0x1c0781){const _0x4070fc=_0x13da7f;try{if(_0x1c0781[_0x4070fc('0xd')]==_0x1c0781['origtransfererlinkedid'])!_['isNil'](queues[_0x1c0781['secondtransfererlinkedid']])&&(queues[_0x1c0781[_0x4070fc('0x2e')]][_0x4070fc('0x6')]=!![],queues[_0x1c0781[_0x4070fc('0x2e')]][_0x4070fc('0x1c')]=_0x4070fc('0xf'),queues[_0x1c0781[_0x4070fc('0x2e')]][_0x4070fc('0x46')]=_0x1c0781[_0x4070fc('0x1b')],queues[_0x1c0781['secondtransfererlinkedid']]['transferuniqueid']=_0x1c0781[_0x4070fc('0xd')],queues[_0x1c0781[_0x4070fc('0x2e')]][_0x4070fc('0x41')]=_0x4070fc('0x40')),!_[_0x4070fc('0x2f')](queues[_0x1c0781[_0x4070fc('0x8')]])&&(_0x1c0781[_0x4070fc('0x1e')]&&queues[_0x1c0781['transfereelinkedid']]?(queues[_0x1c0781[_0x4070fc('0x1e')]][_0x4070fc('0xb')]=0x1,queues[_0x1c0781[_0x4070fc('0x3c')]]=_[_0x4070fc('0x45')](queues[_0x1c0781[_0x4070fc('0x1e')]]),queues[_0x1c0781[_0x4070fc('0x3c')]][_0x4070fc('0x23')]=_0x1c0781[_0x4070fc('0x31')],queues[_0x1c0781[_0x4070fc('0x3c')]]['queuecallerenterreason']=0x2,queues[_0x1c0781['transfereeuniqueid']]['calleridnum']=queues[_0x1c0781[_0x4070fc('0x2e')]][_0x4070fc('0x4a')],queues[_0x1c0781[_0x4070fc('0x3c')]][_0x4070fc('0x35')]=queues[_0x1c0781[_0x4070fc('0x2e')]]['calleridname'],queues[_0x1c0781[_0x4070fc('0x3c')]][_0x4070fc('0x43')]=utils[_0x4070fc('0x4')](),queues[_0x1c0781['transfereeuniqueid']][_0x4070fc('0x3d')]=utils['now'](),queues[_0x1c0781[_0x4070fc('0x3c')]][_0x4070fc('0x21')]=0x0,queues[_0x1c0781['transfereeuniqueid']]['mohtime']=0x0):queues[_0x1c0781[_0x4070fc('0x8')]][_0x4070fc('0x23')]=_0x1c0781[_0x4070fc('0x2e')]);else _0x1c0781[_0x4070fc('0x13')]==_0x1c0781['secondtransfererlinkedid']&&(!_[_0x4070fc('0x2f')](queues[_0x1c0781[_0x4070fc('0x8')]])&&(queues[_0x1c0781[_0x4070fc('0x8')]][_0x4070fc('0x6')]=!![],queues[_0x1c0781[_0x4070fc('0x8')]][_0x4070fc('0x1c')]=_0x4070fc('0xf'),queues[_0x1c0781['origtransfererlinkedid']]['transferexten']=_0x1c0781[_0x4070fc('0x19')],queues[_0x1c0781[_0x4070fc('0x8')]]['transferuniqueid']=_0x1c0781[_0x4070fc('0x13')],queues[_0x1c0781[_0x4070fc('0x8')]][_0x4070fc('0x41')]=_0x4070fc('0x40')),!_[_0x4070fc('0x2f')](queues[_0x1c0781[_0x4070fc('0x2e')]])&&(_0x1c0781['transfertargetlinkedid']&&queues[_0x1c0781[_0x4070fc('0x0')]]?(queues[_0x1c0781['transfertargetlinkedid']][_0x4070fc('0xb')]=0x1,queues[_0x1c0781[_0x4070fc('0x31')]]=_['clone'](queues[_0x1c0781[_0x4070fc('0x0')]]),queues[_0x1c0781[_0x4070fc('0x31')]][_0x4070fc('0x23')]=_0x1c0781[_0x4070fc('0x31')],queues[_0x1c0781['transfertargetuniqueid']][_0x4070fc('0xb')]=0x2,queues[_0x1c0781[_0x4070fc('0x31')]][_0x4070fc('0x4a')]=queues[_0x1c0781[_0x4070fc('0x8')]]['calleridnum'],queues[_0x1c0781[_0x4070fc('0x31')]][_0x4070fc('0x35')]=queues[_0x1c0781['origtransfererlinkedid']][_0x4070fc('0x35')],queues[_0x1c0781[_0x4070fc('0x31')]]['queuecallerjoinAt']=utils[_0x4070fc('0x4')](),queues[_0x1c0781[_0x4070fc('0x31')]][_0x4070fc('0x3d')]=utils['now'](),queues[_0x1c0781[_0x4070fc('0x31')]][_0x4070fc('0x21')]=0x0,queues[_0x1c0781[_0x4070fc('0x31')]][_0x4070fc('0x44')]=0x0):queues[_0x1c0781[_0x4070fc('0x2e')]][_0x4070fc('0x23')]=_0x1c0781[_0x4070fc('0x8')]));}catch(_0x549a3c){utils[_0x4070fc('0x17')](_0x549a3c[_0x4070fc('0x34')]);}},exports['musiconholdstart']=function(_0x12fd58){const _0x214ae1=_0x13da7f;!_['isNil'](queues[_0x12fd58[_0x214ae1('0x38')]])&&(queues[_0x12fd58[_0x214ae1('0x38')]][_0x214ae1('0x1f')]=utils['now']());},exports['musiconholdstop']=function(_0x28b41f){const _0x1f1a9d=_0x13da7f;!_[_0x1f1a9d('0x2f')](queues[_0x28b41f[_0x1f1a9d('0x38')]])&&(!_[_0x1f1a9d('0x2f')](queues[_0x28b41f['uniqueid']][_0x1f1a9d('0x1f')])&&(queues[_0x28b41f[_0x1f1a9d('0x38')]][_0x1f1a9d('0x44')]+=utils[_0x1f1a9d('0x2a')](utils[_0x1f1a9d('0x4')](),queues[_0x28b41f['uniqueid']][_0x1f1a9d('0x1f')]),delete queues[_0x28b41f[_0x1f1a9d('0x38')]][_0x1f1a9d('0x1f')]));}; \ No newline at end of file diff --git a/server/services/xdr/recordings.controller.js b/server/services/xdr/recordings.controller.js index 1ee4f31..2d4d218 100644 --- a/server/services/xdr/recordings.controller.js +++ b/server/services/xdr/recordings.controller.js @@ -1 +1 @@ -const a1228_0x282c=['membername','newexten','transfer','endsWith','calleridnum','application','substring','calleridname','lastIndexOf','cdr','outbound','isNil','linkedid','accountcode','variable','stack','uniqueid','monitors','CreateVoiceRecording','appdata','replace','connectedlinenum','queue','set','then','context','connectedlinename','hangup','.WAV','getUserByInternal','error','push','newstate','mixmonitor_filename','find','forEach','toLowerCase','request','channelstate','newchannel','name','exten','./utils','clone','value','queuecallerjoin','.wav49'];(function(_0x171687,_0x282c4f){const _0x34a628=function(_0x9fec6d){while(--_0x9fec6d){_0x171687['push'](_0x171687['shift']());}};_0x34a628(++_0x282c4f);}(a1228_0x282c,0x1e6));const a1228_0x34a6=function(_0x171687,_0x282c4f){_0x171687=_0x171687-0x0;let _0x34a628=a1228_0x282c[_0x171687];return _0x34a628;};const _0x257228=a1228_0x34a6;'use strict';const _=require('lodash'),utils=require(_0x257228('0x1a')),recordings={};function writeDB(_0x9fec6d){const _0x5bed04=_0x257228;utils['debug'](_0x9fec6d),_0x9fec6d[_0x5bed04('0x2c')]?utils[_0x5bed04('0xd')](_0x9fec6d[_0x5bed04('0x2c')])[_0x5bed04('0x8')](function(_0x8c4a00){const _0x172a22=_0x5bed04;_0x8c4a00&&(_0x9fec6d[_0x172a22('0x1f')]=_0x8c4a00[_0x172a22('0x18')],_0x9fec6d['UserId']=_0x8c4a00['id']),utils[_0x172a22('0x15')](_0x172a22('0x2'),_0x9fec6d);}):utils['request']('CreateVoiceRecording',_0x9fec6d);}exports[_0x257228('0x17')]=function(_0xdad67e){const _0x65baa6=_0x257228;try{_0xdad67e[_0x65baa6('0x0')]==_0xdad67e[_0x65baa6('0x2b')]&&(recordings[_0xdad67e['uniqueid']]={'uniqueid':_0xdad67e[_0x65baa6('0x0')],'accountcode':_0xdad67e['accountcode'],'exten':_0xdad67e[_0x65baa6('0x19')],'context':_0xdad67e['context'],'channel':_0xdad67e['channel'],'monitors':[]});}catch(_0x4293e4){utils[_0x65baa6('0xe')](_0x4293e4[_0x65baa6('0x2e')]);}},exports[_0x257228('0x10')]=function(_0x373e93){const _0x1da855=_0x257228;try{if(!_['isNil'](recordings[_0x373e93['uniqueid']])&&_0x373e93[_0x1da855('0x16')]==0x6){}else!_[_0x1da855('0x2a')](recordings[_0x373e93[_0x1da855('0x2b')]])&&_0x373e93[_0x1da855('0x16')]==0x6&&_0x373e93[_0x1da855('0x9')]!=_0x1da855('0x21')&&(recordings[_0x373e93[_0x1da855('0x2b')]][_0x1da855('0x2c')]=_0x373e93[_0x1da855('0x2c')]);}catch(_0x3e98e7){utils[_0x1da855('0xe')](_0x3e98e7['stack']);}},exports['varset']=function(_0x55236b){const _0xbea010=_0x257228;try{if(!_['isNil'](_0x55236b[_0xbea010('0x2d')])&&!_['isNil'](_0x55236b[_0xbea010('0x2d')][_0xbea010('0x11')])){_[_0xbea010('0x22')](_0x55236b[_0xbea010('0x1c')],'.wav49')&&(_0x55236b[_0xbea010('0x1c')]=_0x55236b[_0xbea010('0x1c')][_0xbea010('0x4')](_0xbea010('0x1e'),_0xbea010('0xc')));if(recordings[_0x55236b['linkedid']]){const _0x3ce10f=_[_0xbea010('0x12')](recordings[_0x55236b[_0xbea010('0x2b')]][_0xbea010('0x1')],{'value':_0x55236b[_0xbea010('0x1c')]});_['isNil'](_0x3ce10f)&&recordings[_0x55236b[_0xbea010('0x2b')]][_0xbea010('0x1')][_0xbea010('0xf')]({'value':_0x55236b[_0xbea010('0x1c')]});}}}catch(_0xf44770){utils[_0xbea010('0xe')](_0xf44770[_0xbea010('0x2e')]);}},exports[_0x257228('0xb')]=function(_0x5b880c){const _0xc6a37=_0x257228;try{!_['isNil'](recordings[_0x5b880c[_0xc6a37('0x0')]])&&(recordings[_0x5b880c[_0xc6a37('0x0')]][_0xc6a37('0x23')]=_0x5b880c[_0xc6a37('0x23')],recordings[_0x5b880c[_0xc6a37('0x0')]][_0xc6a37('0x26')]=_0x5b880c[_0xc6a37('0x26')],recordings[_0x5b880c[_0xc6a37('0x0')]][_0xc6a37('0x5')]=_0x5b880c['connectedlinenum'],recordings[_0x5b880c[_0xc6a37('0x0')]]['connectedlinename']=_0x5b880c[_0xc6a37('0xa')],recordings[_0x5b880c[_0xc6a37('0x0')]]['type']==_0xc6a37('0x29')&&recordings[_0x5b880c[_0xc6a37('0x0')]][_0xc6a37('0x2c')]&&(recordings[_0x5b880c[_0xc6a37('0x0')]][_0xc6a37('0x5')]=recordings[_0x5b880c[_0xc6a37('0x0')]]['accountcode'],recordings[_0x5b880c['uniqueid']][_0xc6a37('0xa')]=''),recordings[_0x5b880c['uniqueid']]['monitors'][_0xc6a37('0x13')](_0x1539ed=>{const _0x3d18a0=_0xc6a37,_0x436612=_[_0x3d18a0('0x1b')](recordings[_0x5b880c['uniqueid']]);_0x436612[_0x3d18a0('0x1c')]=_0x1539ed['value'],writeDB(_0x436612);}),delete recordings[_0x5b880c[_0xc6a37('0x0')]]);}catch(_0xc95b7){utils[_0xc6a37('0xe')](_0xc95b7[_0xc6a37('0x2e')]);}},exports[_0x257228('0x20')]=function(_0x3e7f90){const _0x2ebde0=_0x257228;try{if(!_[_0x2ebde0('0x2a')](recordings[_0x3e7f90[_0x2ebde0('0x0')]])){if(_0x3e7f90[_0x2ebde0('0x24')][_0x2ebde0('0x14')]()==_0x2ebde0('0x7')&&_['startsWith'](_0x3e7f90['appdata']['toLowerCase'](),_0x2ebde0('0x28'))){const _0x3e3ddb=_0x3e7f90[_0x2ebde0('0x3')]['split']('='),_0x503302=_0x3e3ddb[0x0][_0x2ebde0('0x25')](_0x3e3ddb[0x0][_0x2ebde0('0x27')]('(')+0x1,_0x3e3ddb[0x0]['lastIndexOf'](')')),_0x329213=_0x3e3ddb[0x1];recordings[_0x3e7f90[_0x2ebde0('0x0')]][_0x503302]=_0x329213;}}}catch(_0x1b85b1){utils[_0x2ebde0('0xe')](_0x1b85b1[_0x2ebde0('0x2e')]);}},exports[_0x257228('0x1d')]=function(_0x460060){const _0x4824cc=_0x257228;try{!_[_0x4824cc('0x2a')](recordings[_0x460060[_0x4824cc('0x0')]])&&(recordings[_0x460060[_0x4824cc('0x0')]]['queue']=_0x460060[_0x4824cc('0x6')]);}catch(_0x1ce4f8){utils[_0x4824cc('0xe')](_0x1ce4f8[_0x4824cc('0x2e')]);}}; \ No newline at end of file +const a1228_0x1653=['channelstate','request','queue','clone','stack','cdr','lastIndexOf','newchannel','varset','outbound','context','type','linkedid','endsWith','isNil','newexten','membername','split','connectedlinenum','then','substring','channel','connectedlinename','appdata','set','name','.wav49','calleridnum','.WAV','exten','UserId','accountcode','variable','monitors','toLowerCase','debug','queuecallerjoin','value','CreateVoiceRecording','error','startsWith','forEach','newstate','getUserByInternal','find','uniqueid','lodash'];(function(_0xb56713,_0x1653b0){const _0x19ef5b=function(_0x390bb1){while(--_0x390bb1){_0xb56713['push'](_0xb56713['shift']());}};_0x19ef5b(++_0x1653b0);}(a1228_0x1653,0x1a1));const a1228_0x19ef=function(_0xb56713,_0x1653b0){_0xb56713=_0xb56713-0x0;let _0x19ef5b=a1228_0x1653[_0xb56713];return _0x19ef5b;};const _0x11b36e=a1228_0x19ef;'use strict';const _=require(_0x11b36e('0x5')),utils=require('./utils'),recordings={};function writeDB(_0x390bb1){const _0x517749=_0x11b36e;utils[_0x517749('0x29')](_0x390bb1),_0x390bb1[_0x517749('0x25')]?utils[_0x517749('0x2')](_0x390bb1['accountcode'])[_0x517749('0x19')](function(_0x790cfd){const _0x3df4c9=_0x517749;_0x790cfd&&(_0x390bb1[_0x3df4c9('0x16')]=_0x790cfd[_0x3df4c9('0x1f')],_0x390bb1[_0x3df4c9('0x24')]=_0x790cfd['id']),utils[_0x3df4c9('0x7')](_0x3df4c9('0x2c'),_0x390bb1);}):utils[_0x517749('0x7')](_0x517749('0x2c'),_0x390bb1);}exports[_0x11b36e('0xd')]=function(_0x349301){const _0x445cfd=_0x11b36e;try{_0x349301[_0x445cfd('0x4')]==_0x349301['linkedid']&&(recordings[_0x349301[_0x445cfd('0x4')]]={'uniqueid':_0x349301[_0x445cfd('0x4')],'accountcode':_0x349301[_0x445cfd('0x25')],'exten':_0x349301[_0x445cfd('0x23')],'context':_0x349301['context'],'channel':_0x349301[_0x445cfd('0x1b')],'monitors':[]});}catch(_0x4bb3a1){utils[_0x445cfd('0x2d')](_0x4bb3a1['stack']);}},exports[_0x11b36e('0x1')]=function(_0x478fd9){const _0x5da841=_0x11b36e;try{if(!_[_0x5da841('0x14')](recordings[_0x478fd9[_0x5da841('0x4')]])&&_0x478fd9['channelstate']==0x6){}else!_[_0x5da841('0x14')](recordings[_0x478fd9[_0x5da841('0x12')]])&&_0x478fd9[_0x5da841('0x6')]==0x6&&_0x478fd9[_0x5da841('0x10')]!='transfer'&&(recordings[_0x478fd9[_0x5da841('0x12')]][_0x5da841('0x25')]=_0x478fd9['accountcode']);}catch(_0x36486b){utils['error'](_0x36486b[_0x5da841('0xa')]);}},exports[_0x11b36e('0xe')]=function(_0x4b93a3){const _0x5ef15a=_0x11b36e;try{if(!_[_0x5ef15a('0x14')](_0x4b93a3[_0x5ef15a('0x26')])&&!_[_0x5ef15a('0x14')](_0x4b93a3[_0x5ef15a('0x26')]['mixmonitor_filename'])){_[_0x5ef15a('0x13')](_0x4b93a3['value'],_0x5ef15a('0x20'))&&(_0x4b93a3[_0x5ef15a('0x2b')]=_0x4b93a3[_0x5ef15a('0x2b')]['replace']('.wav49',_0x5ef15a('0x22')));if(recordings[_0x4b93a3[_0x5ef15a('0x12')]]){const _0x26f3c5=_[_0x5ef15a('0x3')](recordings[_0x4b93a3[_0x5ef15a('0x12')]][_0x5ef15a('0x27')],{'value':_0x4b93a3[_0x5ef15a('0x2b')]});_[_0x5ef15a('0x14')](_0x26f3c5)&&recordings[_0x4b93a3['linkedid']][_0x5ef15a('0x27')]['push']({'value':_0x4b93a3[_0x5ef15a('0x2b')]});}}}catch(_0x1abf76){utils[_0x5ef15a('0x2d')](_0x1abf76[_0x5ef15a('0xa')]);}},exports['hangup']=function(_0x4076d4){const _0x423455=_0x11b36e;try{!_[_0x423455('0x14')](recordings[_0x4076d4[_0x423455('0x4')]])&&(recordings[_0x4076d4[_0x423455('0x4')]]['calleridnum']=_0x4076d4[_0x423455('0x21')],recordings[_0x4076d4[_0x423455('0x4')]]['calleridname']=_0x4076d4['calleridname'],recordings[_0x4076d4[_0x423455('0x4')]][_0x423455('0x18')]=_0x4076d4[_0x423455('0x18')],recordings[_0x4076d4[_0x423455('0x4')]]['connectedlinename']=_0x4076d4[_0x423455('0x1c')],recordings[_0x4076d4[_0x423455('0x4')]][_0x423455('0x11')]==_0x423455('0xf')&&recordings[_0x4076d4[_0x423455('0x4')]][_0x423455('0x25')]&&(recordings[_0x4076d4[_0x423455('0x4')]][_0x423455('0x18')]=recordings[_0x4076d4[_0x423455('0x4')]][_0x423455('0x25')],recordings[_0x4076d4[_0x423455('0x4')]][_0x423455('0x1c')]=''),recordings[_0x4076d4[_0x423455('0x4')]][_0x423455('0x27')][_0x423455('0x0')](_0xdff11b=>{const _0x4741b4=_0x423455,_0x900dc7=_[_0x4741b4('0x9')](recordings[_0x4076d4[_0x4741b4('0x4')]]);_0x900dc7[_0x4741b4('0x2b')]=_0xdff11b[_0x4741b4('0x2b')],writeDB(_0x900dc7);}),delete recordings[_0x4076d4['uniqueid']]);}catch(_0x43f423){utils[_0x423455('0x2d')](_0x43f423[_0x423455('0xa')]);}},exports[_0x11b36e('0x15')]=function(_0x24d61a){const _0x3d8813=_0x11b36e;try{if(!_[_0x3d8813('0x14')](recordings[_0x24d61a[_0x3d8813('0x4')]])){if(_0x24d61a['application'][_0x3d8813('0x28')]()==_0x3d8813('0x1e')&&_[_0x3d8813('0x2e')](_0x24d61a[_0x3d8813('0x1d')]['toLowerCase'](),_0x3d8813('0xb'))){const _0x5518b4=_0x24d61a['appdata'][_0x3d8813('0x17')]('='),_0x19c026=_0x5518b4[0x0][_0x3d8813('0x1a')](_0x5518b4[0x0][_0x3d8813('0xc')]('(')+0x1,_0x5518b4[0x0][_0x3d8813('0xc')](')')),_0xd11837=_0x5518b4[0x1];recordings[_0x24d61a['uniqueid']][_0x19c026]=_0xd11837;}}}catch(_0xd07963){utils[_0x3d8813('0x2d')](_0xd07963[_0x3d8813('0xa')]);}},exports[_0x11b36e('0x2a')]=function(_0x57482e){const _0xa3c606=_0x11b36e;try{!_[_0xa3c606('0x14')](recordings[_0x57482e[_0xa3c606('0x4')]])&&(recordings[_0x57482e[_0xa3c606('0x4')]]['queue']=_0x57482e[_0xa3c606('0x8')]);}catch(_0x1c24fe){utils[_0xa3c606('0x2d')](_0x1c24fe['stack']);}}; \ No newline at end of file diff --git a/server/services/xdr/transfers.controller.js b/server/services/xdr/transfers.controller.js index 7fd6a34..f1cd8f7 100644 --- a/server/services/xdr/transfers.controller.js +++ b/server/services/xdr/transfers.controller.js @@ -1 +1 @@ -const a1229_0x3414=['transfertargetconnectedlinenum','transfertargetexten','format','attended','attendedtransfer','blindtransfer','origtransfererexten','lodash','secondtransfererconnectedlinename','origtransfererlinkedid','stack','secondtransferercontext','transfertargetcalleridname','secondtransfererconnectedlinenum','origtransferercalleridname','transfertargetchannel','transfereechannel','transfertargetaccountcode','origtransfererchannel','origtransferercontext','type','assign','blind','transfertargetcontext','transfertargetconnectedlinename','request','transfertargetlinkedid','isNil','CreateVoiceTransferReport','error'];(function(_0x4b2699,_0x341403){const _0x296d2e=function(_0x1855d7){while(--_0x1855d7){_0x4b2699['push'](_0x4b2699['shift']());}};_0x296d2e(++_0x341403);}(a1229_0x3414,0x1c1));const a1229_0x296d=function(_0x4b2699,_0x341403){_0x4b2699=_0x4b2699-0x0;let _0x296d2e=a1229_0x3414[_0x4b2699];return _0x296d2e;};const _0x4fb228=a1229_0x296d;'use strict';const _=require(_0x4fb228('0x8')),util=require('util'),utils=require('./utils');function writeDB(_0x1855d7){const _0x3f90e8=_0x4fb228;utils['info'](util[_0x3f90e8('0x3')]('TRANSFER|%s',_0x1855d7[_0x3f90e8('0x15')])),utils[_0x3f90e8('0x1a')](_0x3f90e8('0x1d'),_0x1855d7);}exports[_0x4fb228('0x6')]=function(_0x1169d2){const _0x23c164=_0x4fb228;try{_0x1169d2[_0x23c164('0x15')]=_0x23c164('0x17'),writeDB(_0x1169d2);}catch(_0x4b6e1c){utils['error'](_0x4b6e1c[_0x23c164('0xb')]);}},exports[_0x4fb228('0x5')]=function(_0x93349f){const _0x27a63d=_0x4fb228;try{_0x93349f=_[_0x27a63d('0x16')](_0x93349f,{'transfererchannel':_0x93349f[_0x27a63d('0x13')],'transferercalleridnum':_0x93349f['origtransferercalleridnum'],'transferercalleridname':_0x93349f[_0x27a63d('0xf')],'transfererconnectedlinenum':_0x93349f[_0x27a63d('0xe')],'transfererconnectedlinename':_0x93349f[_0x27a63d('0x9')],'transfereraccountcode':_0x93349f['origtransfereraccountcode'],'transferercontext':_0x93349f[_0x27a63d('0xc')],'transfererexten':_0x93349f['secondtransfererexten'],'transfererlinkedid':_0x93349f[_0x27a63d('0xa')],'context':_0x93349f[_0x27a63d('0x14')],'extension':_0x93349f[_0x27a63d('0x7')],'type':_0x27a63d('0x4')}),_[_0x27a63d('0x1c')](_0x93349f[_0x27a63d('0x11')])&&(_0x93349f=_['assign'](_0x93349f,{'transfereechannel':_0x93349f[_0x27a63d('0x10')],'transfereecalleridnum':_0x93349f['transfertargetcalleridnum'],'transfereecalleridname':_0x93349f[_0x27a63d('0xd')],'transfereeconnectedlinenum':_0x93349f[_0x27a63d('0x1')],'transfereeconnectedlinename':_0x93349f[_0x27a63d('0x19')],'transfereeaccountcode':_0x93349f[_0x27a63d('0x12')],'transfereecontext':_0x93349f[_0x27a63d('0x18')],'transfereeexten':_0x93349f[_0x27a63d('0x2')],'transfereelinkedid':_0x93349f[_0x27a63d('0x1b')]})),writeDB(_0x93349f);}catch(_0x217341){utils[_0x27a63d('0x0')](_0x217341[_0x27a63d('0xb')]);}}; \ No newline at end of file +const a1229_0x3891=['origtransferercalleridname','./utils','lodash','format','origtransfererchannel','transfertargetcalleridname','transfertargetexten','transfertargetconnectedlinenum','stack','error','assign','transfertargetlinkedid','info','blind','transfertargetcalleridnum','origtransferercalleridnum','isNil','transfertargetchannel','request','attended','origtransfererlinkedid','TRANSFER|%s','attendedtransfer','secondtransfererconnectedlinename','secondtransfererconnectedlinenum','transfereechannel','util','type','origtransfereraccountcode','origtransferercontext'];(function(_0x4f9a8b,_0x3891c3){const _0x5caf93=function(_0x3f96e7){while(--_0x3f96e7){_0x4f9a8b['push'](_0x4f9a8b['shift']());}};_0x5caf93(++_0x3891c3);}(a1229_0x3891,0x12b));const a1229_0x5caf=function(_0x4f9a8b,_0x3891c3){_0x4f9a8b=_0x4f9a8b-0x0;let _0x5caf93=a1229_0x3891[_0x4f9a8b];return _0x5caf93;};const _0xaf0516=a1229_0x5caf;'use strict';const _=require(_0xaf0516('0x3')),util=require(_0xaf0516('0x1b')),utils=require(_0xaf0516('0x2'));function writeDB(_0x3f96e7){const _0x1d7061=_0xaf0516;utils[_0x1d7061('0xd')](util[_0x1d7061('0x4')](_0x1d7061('0x16'),_0x3f96e7['type'])),utils[_0x1d7061('0x13')]('CreateVoiceTransferReport',_0x3f96e7);}exports['blindtransfer']=function(_0x1f9244){const _0x5b894d=_0xaf0516;try{_0x1f9244[_0x5b894d('0x1c')]=_0x5b894d('0xe'),writeDB(_0x1f9244);}catch(_0x3946c9){utils['error'](_0x3946c9['stack']);}},exports[_0xaf0516('0x17')]=function(_0x3445d7){const _0x1a853c=_0xaf0516;try{_0x3445d7=_[_0x1a853c('0xb')](_0x3445d7,{'transfererchannel':_0x3445d7[_0x1a853c('0x5')],'transferercalleridnum':_0x3445d7[_0x1a853c('0x10')],'transferercalleridname':_0x3445d7[_0x1a853c('0x1')],'transfererconnectedlinenum':_0x3445d7[_0x1a853c('0x19')],'transfererconnectedlinename':_0x3445d7[_0x1a853c('0x18')],'transfereraccountcode':_0x3445d7[_0x1a853c('0x1d')],'transferercontext':_0x3445d7['secondtransferercontext'],'transfererexten':_0x3445d7['secondtransfererexten'],'transfererlinkedid':_0x3445d7[_0x1a853c('0x15')],'context':_0x3445d7[_0x1a853c('0x0')],'extension':_0x3445d7['origtransfererexten'],'type':_0x1a853c('0x14')}),_[_0x1a853c('0x11')](_0x3445d7[_0x1a853c('0x1a')])&&(_0x3445d7=_['assign'](_0x3445d7,{'transfereechannel':_0x3445d7[_0x1a853c('0x12')],'transfereecalleridnum':_0x3445d7[_0x1a853c('0xf')],'transfereecalleridname':_0x3445d7[_0x1a853c('0x6')],'transfereeconnectedlinenum':_0x3445d7[_0x1a853c('0x8')],'transfereeconnectedlinename':_0x3445d7['transfertargetconnectedlinename'],'transfereeaccountcode':_0x3445d7['transfertargetaccountcode'],'transfereecontext':_0x3445d7['transfertargetcontext'],'transfereeexten':_0x3445d7[_0x1a853c('0x7')],'transfereelinkedid':_0x3445d7[_0x1a853c('0xc')]})),writeDB(_0x3445d7);}catch(_0x14f56d){utils[_0x1a853c('0xa')](_0x14f56d[_0x1a853c('0x9')]);}}; \ No newline at end of file diff --git a/server/services/xdr/utils.js b/server/services/xdr/utils.js index 837016c..5f252cb 100644 --- a/server/services/xdr/utils.js +++ b/server/services/xdr/utils.js @@ -1 +1 @@ -const a1230_0x5e37=['subtractTime','stringify','getVoiceQueueByName','format','jayson/promise','isBefore','request','GetVoiceQueue','catch','FOUND','YYYY-MM-DD\x20HH:mm:ss','GETUSER|','GetUser','diff','length','moment','stack','diffTime','error','internal','debug','addTime','NOTFOUND','now','subtract','result','type','http','isAfter','acwTimeout','../../config/logger','seconds','interface','sumTime','then','name','getUserByName','info'];(function(_0x254545,_0x5e37c8){const _0x2b4c65=function(_0x2217b5){while(--_0x2217b5){_0x254545['push'](_0x254545['shift']());}};_0x2b4c65(++_0x5e37c8);}(a1230_0x5e37,0x16a));const a1230_0x2b4c=function(_0x254545,_0x5e37c8){_0x254545=_0x254545-0x0;let _0x2b4c65=a1230_0x5e37[_0x254545];return _0x2b4c65;};const _0x3827d9=a1230_0x2b4c;'use strict';const jayson=require(_0x3827d9('0x16')),moment=require(_0x3827d9('0x21')),client=jayson['client'][_0x3827d9('0x7')]({'port':0x2329}),logger=require(_0x3827d9('0xa'))('xdr');exports[_0x3827d9('0x11')]=function(_0x2217b5){const _0xd297f2=_0x3827d9;logger[_0xd297f2('0x11')](_0x2217b5);},exports[_0x3827d9('0x0')]=function(_0x143ab7){const _0x2f2d05=_0x3827d9;logger[_0x2f2d05('0x0')](JSON[_0x2f2d05('0x13')](_0x143ab7));},exports[_0x3827d9('0x24')]=function(_0x1c9834){const _0x5c5a59=_0x3827d9;logger[_0x5c5a59('0x24')](_0x1c9834[_0x5c5a59('0x22')]);},exports[_0x3827d9('0x18')]=function(_0x329f80,_0x43315a){const _0x224c7b=_0x3827d9;return client[_0x224c7b('0x18')](_0x329f80,{'body':_0x43315a})['then'](function(_0x8ddb47){const _0x493a61=_0x224c7b;logger['debug'](JSON[_0x493a61('0x13')](_0x8ddb47));})['catch'](function(_0x1c4bc4){const _0x4f465d=_0x224c7b;logger[_0x4f465d('0x24')](_0x1c4bc4[_0x4f465d('0x22')]);});};function getUser(_0x5a8329){const _0x3ace62=_0x3827d9;return client['request'](_0x3ace62('0x1e'),{'options':{'raw':!![],'attributes':['id',_0x3ace62('0x25'),_0x3ace62('0xf'),_0x3ace62('0xc')],'where':_0x5a8329,'limit':0x1}})[_0x3ace62('0xe')](function(_0x4bf89f){const _0x1b1b6c=_0x3ace62;return logger['info'](_0x1b1b6c('0x1d')+JSON[_0x1b1b6c('0x13')](_0x5a8329)+'|'+(_0x4bf89f[_0x1b1b6c('0x5')]['length']?'FOUND':_0x1b1b6c('0x2'))),_0x4bf89f[_0x1b1b6c('0x5')][_0x1b1b6c('0x20')]?_0x4bf89f[_0x1b1b6c('0x5')][0x0]:null;});}exports['getUserByInternal']=function(_0x5e5764){return new Promise(function(_0x24f204){const _0x4efa1a=a1230_0x2b4c;return _0x5e5764?getUser({'internal':_0x5e5764})[_0x4efa1a('0xe')](function(_0xa8bb49){return _0x24f204(_0xa8bb49);})[_0x4efa1a('0x1a')](function(_0x2e9243){return logger['error'](_0x2e9243['stack']),_0x24f204(null);}):_0x24f204(null);});},exports['getUserByInterface']=function(_0x1d7f75){return new Promise(function(_0x399550){const _0x36f77d=a1230_0x2b4c;return _0x1d7f75?getUser({'interface':_0x1d7f75})[_0x36f77d('0xe')](function(_0x530e5c){return _0x399550(_0x530e5c);})['catch'](function(_0x1b6f54){const _0x1d7475=_0x36f77d;return logger[_0x1d7475('0x24')](_0x1b6f54[_0x1d7475('0x22')]),_0x399550(null);}):_0x399550(null);});},exports[_0x3827d9('0x10')]=function(_0x27a884){return new Promise(function(_0x55eb57){const _0x315706=a1230_0x2b4c;return _0x27a884?getUser({'name':_0x27a884})['then'](function(_0x4ade25){return _0x55eb57(_0x4ade25);})[_0x315706('0x1a')](function(_0x53f4e8){const _0x193a43=_0x315706;return logger['error'](_0x53f4e8[_0x193a43('0x22')]),_0x55eb57(null);}):_0x55eb57(null);});},exports[_0x3827d9('0x14')]=function(_0xecb775){return new Promise(function(_0x1e8067){const _0x30a8b5=a1230_0x2b4c;return _0xecb775?client[_0x30a8b5('0x18')](_0x30a8b5('0x19'),{'options':{'raw':!![],'attributes':['id',_0x30a8b5('0xf'),_0x30a8b5('0x6'),'acw',_0x30a8b5('0x9')],'where':{'name':_0xecb775},'limit':0x1}})['then'](function(_0x175c6c){const _0x502705=_0x30a8b5;return logger[_0x502705('0x11')]('GETVOICEQUEUEBYNAME|'+_0xecb775+'|'+(_0x175c6c[_0x502705('0x5')][_0x502705('0x20')]?_0x502705('0x1b'):_0x502705('0x2'))),_0x1e8067(_0x175c6c['result'][_0x502705('0x20')]?_0x175c6c[_0x502705('0x5')][0x0]:null);})[_0x30a8b5('0x1a')](function(_0x2947fc){const _0x2905e2=_0x30a8b5;return logger[_0x2905e2('0x24')](_0x2947fc[_0x2905e2('0x22')]),_0x1e8067(null);}):_0x1e8067(null);});},exports[_0x3827d9('0x1')]=function(_0xd7da7d,_0x281ffb){const _0x2471f6=_0x3827d9;return moment(_0xd7da7d)['add'](_0x281ffb,_0x2471f6('0xb'))['format'](_0x2471f6('0x1c'));},exports[_0x3827d9('0x12')]=function(_0x20ea0c,_0x3b6c8f){const _0x2cd9a4=_0x3827d9;return moment(_0x20ea0c)[_0x2cd9a4('0x4')](_0x3b6c8f,_0x2cd9a4('0xb'))['format']('YYYY-MM-DD\x20HH:mm:ss');},exports[_0x3827d9('0x23')]=function(_0x105923,_0x2dd655){const _0x5362c7=_0x3827d9;return moment(_0x105923)[_0x5362c7('0x1f')](moment(_0x2dd655),'seconds');},exports[_0x3827d9('0xd')]=function(_0x20b79e,_0x99064c){return parseInt(_0x20b79e,0xa)+parseInt(_0x99064c,0xa);},exports[_0x3827d9('0x3')]=function(){const _0x37accf=_0x3827d9;return moment()[_0x37accf('0x15')](_0x37accf('0x1c'));},exports[_0x3827d9('0x8')]=function(_0x265f31,_0x3c79fb){const _0x2df0e2=_0x3827d9;return _0x3c79fb?moment(_0x265f31)[_0x2df0e2('0x8')](_0x3c79fb):!![];},exports[_0x3827d9('0x17')]=function(_0x21ea82,_0x1c6ff4){const _0x596282=_0x3827d9;if(_0x1c6ff4)return moment(_0x21ea82)[_0x596282('0x17')](_0x1c6ff4);else return _0x21ea82?!![]:![];}; \ No newline at end of file +const a1230_0x46a2=['NOTFOUND','result','isAfter','jayson/promise','acwTimeout','then','error','sumTime','stringify','seconds','now','FOUND','diff','GetVoiceQueue','length','GetUser','format','isBefore','stack','YYYY-MM-DD\x20HH:mm:ss','catch','xdr','request','addTime','add','debug','info','diffTime','subtractTime','GETVOICEQUEUEBYNAME|','type','getUserByName','name','GETUSER|'];(function(_0x171e45,_0x46a285){const _0x3e5db2=function(_0xed7bb5){while(--_0xed7bb5){_0x171e45['push'](_0x171e45['shift']());}};_0x3e5db2(++_0x46a285);}(a1230_0x46a2,0x9c));const a1230_0x3e5d=function(_0x171e45,_0x46a285){_0x171e45=_0x171e45-0x0;let _0x3e5db2=a1230_0x46a2[_0x171e45];return _0x3e5db2;};const _0x5e2caa=a1230_0x3e5d;'use strict';const jayson=require(_0x5e2caa('0x11')),moment=require('moment'),client=jayson['client']['http']({'port':0x2329}),logger=require('../../config/logger')(_0x5e2caa('0x1'));exports[_0x5e2caa('0x6')]=function(_0xed7bb5){const _0x684710=_0x5e2caa;logger[_0x684710('0x6')](_0xed7bb5);},exports[_0x5e2caa('0x5')]=function(_0x43607e){const _0x23d694=_0x5e2caa;logger[_0x23d694('0x5')](JSON[_0x23d694('0x16')](_0x43607e));},exports[_0x5e2caa('0x14')]=function(_0x12084c){const _0x5011c2=_0x5e2caa;logger[_0x5011c2('0x14')](_0x12084c['stack']);},exports['request']=function(_0x59d962,_0x52bf65){const _0x47b69a=_0x5e2caa;return client[_0x47b69a('0x2')](_0x59d962,{'body':_0x52bf65})[_0x47b69a('0x13')](function(_0x3db3f0){const _0x5cf22f=_0x47b69a;logger[_0x5cf22f('0x5')](JSON[_0x5cf22f('0x16')](_0x3db3f0));})[_0x47b69a('0x0')](function(_0xa1fe8e){const _0x852c77=_0x47b69a;logger[_0x852c77('0x14')](_0xa1fe8e[_0x852c77('0x20')]);});};function getUser(_0x4665ad){const _0x1ceaf5=_0x5e2caa;return client['request'](_0x1ceaf5('0x1d'),{'options':{'raw':!![],'attributes':['id','internal',_0x1ceaf5('0xc'),'interface'],'where':_0x4665ad,'limit':0x1}})[_0x1ceaf5('0x13')](function(_0x3c5e3a){const _0x136615=_0x1ceaf5;return logger[_0x136615('0x6')](_0x136615('0xd')+JSON[_0x136615('0x16')](_0x4665ad)+'|'+(_0x3c5e3a[_0x136615('0xf')][_0x136615('0x1c')]?'FOUND':_0x136615('0xe'))),_0x3c5e3a[_0x136615('0xf')][_0x136615('0x1c')]?_0x3c5e3a[_0x136615('0xf')][0x0]:null;});}exports['getUserByInternal']=function(_0x579336){return new Promise(function(_0x4e86aa){const _0x239ad0=a1230_0x3e5d;return _0x579336?getUser({'internal':_0x579336})['then'](function(_0x19ea92){return _0x4e86aa(_0x19ea92);})[_0x239ad0('0x0')](function(_0x4cfa55){const _0x284f32=_0x239ad0;return logger[_0x284f32('0x14')](_0x4cfa55[_0x284f32('0x20')]),_0x4e86aa(null);}):_0x4e86aa(null);});},exports['getUserByInterface']=function(_0x8e8f1f){return new Promise(function(_0x140a98){const _0x298365=a1230_0x3e5d;return _0x8e8f1f?getUser({'interface':_0x8e8f1f})[_0x298365('0x13')](function(_0x15a095){return _0x140a98(_0x15a095);})['catch'](function(_0x5147ee){const _0x40dded=_0x298365;return logger[_0x40dded('0x14')](_0x5147ee[_0x40dded('0x20')]),_0x140a98(null);}):_0x140a98(null);});},exports[_0x5e2caa('0xb')]=function(_0x15c48d){return new Promise(function(_0x303a1c){return _0x15c48d?getUser({'name':_0x15c48d})['then'](function(_0x4c6a5b){return _0x303a1c(_0x4c6a5b);})['catch'](function(_0x42849e){const _0xd8f070=a1230_0x3e5d;return logger[_0xd8f070('0x14')](_0x42849e[_0xd8f070('0x20')]),_0x303a1c(null);}):_0x303a1c(null);});},exports['getVoiceQueueByName']=function(_0x119222){return new Promise(function(_0x4acc21){const _0x13d329=a1230_0x3e5d;return _0x119222?client[_0x13d329('0x2')](_0x13d329('0x1b'),{'options':{'raw':!![],'attributes':['id','name',_0x13d329('0xa'),'acw',_0x13d329('0x12')],'where':{'name':_0x119222},'limit':0x1}})[_0x13d329('0x13')](function(_0x1043fa){const _0x38090b=_0x13d329;return logger['info'](_0x38090b('0x9')+_0x119222+'|'+(_0x1043fa[_0x38090b('0xf')][_0x38090b('0x1c')]?_0x38090b('0x19'):_0x38090b('0xe'))),_0x4acc21(_0x1043fa[_0x38090b('0xf')][_0x38090b('0x1c')]?_0x1043fa[_0x38090b('0xf')][0x0]:null);})[_0x13d329('0x0')](function(_0x7f1951){const _0x11b3b0=_0x13d329;return logger[_0x11b3b0('0x14')](_0x7f1951[_0x11b3b0('0x20')]),_0x4acc21(null);}):_0x4acc21(null);});},exports[_0x5e2caa('0x3')]=function(_0x46e794,_0x3a086e){const _0x34f80e=_0x5e2caa;return moment(_0x46e794)[_0x34f80e('0x4')](_0x3a086e,_0x34f80e('0x17'))[_0x34f80e('0x1e')](_0x34f80e('0x21'));},exports[_0x5e2caa('0x8')]=function(_0x38b9d0,_0x18db40){const _0x223df2=_0x5e2caa;return moment(_0x38b9d0)['subtract'](_0x18db40,_0x223df2('0x17'))['format']('YYYY-MM-DD\x20HH:mm:ss');},exports[_0x5e2caa('0x7')]=function(_0x46d707,_0x57ea4e){const _0x5bf3cc=_0x5e2caa;return moment(_0x46d707)[_0x5bf3cc('0x1a')](moment(_0x57ea4e),_0x5bf3cc('0x17'));},exports[_0x5e2caa('0x15')]=function(_0xfc4a5f,_0x22267f){return parseInt(_0xfc4a5f,0xa)+parseInt(_0x22267f,0xa);},exports[_0x5e2caa('0x18')]=function(){const _0x55b64c=_0x5e2caa;return moment()[_0x55b64c('0x1e')](_0x55b64c('0x21'));},exports[_0x5e2caa('0x10')]=function(_0x561a09,_0x54115b){const _0x177529=_0x5e2caa;return _0x54115b?moment(_0x561a09)[_0x177529('0x10')](_0x54115b):!![];},exports[_0x5e2caa('0x1f')]=function(_0x4348ff,_0x283301){const _0x67a6a0=_0x5e2caa;if(_0x283301)return moment(_0x4348ff)[_0x67a6a0('0x1f')](_0x283301);else return _0x4348ff?!![]:![];}; \ No newline at end of file diff --git a/server/utils/build-info.js b/server/utils/build-info.js index 2fee908..7001e1f 100644 --- a/server/utils/build-info.js +++ b/server/utils/build-info.js @@ -1 +1 @@ -const a1231_0x5851=['exports','isProduction','resolve','git-last-commit','undefined','join'];(function(_0x1566e7,_0x5851a5){const _0x46caf6=function(_0x34713f){while(--_0x34713f){_0x1566e7['push'](_0x1566e7['shift']());}};_0x46caf6(++_0x5851a5);}(a1231_0x5851,0x11e));const a1231_0x46ca=function(_0x1566e7,_0x5851a5){_0x1566e7=_0x1566e7-0x0;let _0x46caf6=a1231_0x5851[_0x1566e7];return _0x46caf6;};const _0x20f582=a1231_0x46ca,{getLastCommit}=require(_0x20f582('0x5')),{getConfigService}=require('../config/config.service'),packageJson=require('../../package.json'),cs=getConfigService();function getBuildInfo(){return new Promise((_0x34713f,_0x2b7f09)=>{getLastCommit(function(_0x34b2e1,_0xac2246){const _0x3398b1=a1231_0x46ca;if(_0x34b2e1)_0x2b7f09(_0x34b2e1);else{const {shortHash:_0x4cadc6,branch:_0xc8e3be,committedOn:_0x3212ff,tags:_0x274143}=_0xac2246;_0x34713f({'shortHash':_0x4cadc6,'branch':_0xc8e3be,'tag':_0x274143[_0x3398b1('0x1')](',\x20'),'committedOn':new Date(Number(_0x3212ff)*0x3e8),'buildDate':new Date()});}});});}function readBuildInfo(){const _0x4574b2=_0x20f582;return cs[_0x4574b2('0x3')]&&typeof packageJson['xcally']!==_0x4574b2('0x0')?Promise[_0x4574b2('0x4')](packageJson['xcally']):getBuildInfo();}module[_0x20f582('0x2')]={'getBuildInfo':getBuildInfo,'readBuildInfo':readBuildInfo}; \ No newline at end of file +const a1231_0x22d9=['git-last-commit','exports','xcally','resolve','join','isProduction','undefined','../config/config.service'];(function(_0x29b74e,_0x22d956){const _0x2281ef=function(_0x1835ec){while(--_0x1835ec){_0x29b74e['push'](_0x29b74e['shift']());}};_0x2281ef(++_0x22d956);}(a1231_0x22d9,0xe4));const a1231_0x2281=function(_0x29b74e,_0x22d956){_0x29b74e=_0x29b74e-0x0;let _0x2281ef=a1231_0x22d9[_0x29b74e];return _0x2281ef;};const _0x3a8274=a1231_0x2281,{getLastCommit}=require(_0x3a8274('0x4')),{getConfigService}=require(_0x3a8274('0x3')),packageJson=require('../../package.json'),cs=getConfigService();function getBuildInfo(){return new Promise((_0x1835ec,_0x4848c1)=>{getLastCommit(function(_0x10a1a2,_0x17d22d){const _0x4988e4=a1231_0x2281;if(_0x10a1a2)_0x4848c1(_0x10a1a2);else{const {shortHash:_0x469b6e,branch:_0x204f99,committedOn:_0x1a2cfc,tags:_0x2c0fa1}=_0x17d22d;_0x1835ec({'shortHash':_0x469b6e,'branch':_0x204f99,'tag':_0x2c0fa1[_0x4988e4('0x0')](',\x20'),'committedOn':new Date(Number(_0x1a2cfc)*0x3e8),'buildDate':new Date()});}});});}function readBuildInfo(){const _0x592bc5=_0x3a8274;return cs[_0x592bc5('0x1')]&&typeof packageJson['xcally']!==_0x592bc5('0x2')?Promise[_0x592bc5('0x7')](packageJson[_0x592bc5('0x6')]):getBuildInfo();}module[_0x3a8274('0x5')]={'getBuildInfo':getBuildInfo,'readBuildInfo':readBuildInfo}; \ No newline at end of file diff --git a/snippets/chat_v3.0.0-alpha/index.html b/snippets/chat_v3.0.0-alpha/index.html index 5477e6d..019595d 100644 --- a/snippets/chat_v3.0.0-alpha/index.html +++ b/snippets/chat_v3.0.0-alpha/index.html @@ -22,4 +22,4 @@ status != 'online' && status != 'offline' && status != 'unmanaged' - " ng-click="vm.close(); $event.stopPropagation();">
\ No newline at end of file + " ng-click="vm.close(); $event.stopPropagation();">
\ No newline at end of file